Merge "Adds support for Theme dumping via DDM." into lmp-dev
diff --git a/Android.mk b/Android.mk
index b419231..6a9da2f 100644
--- a/Android.mk
+++ b/Android.mk
@@ -150,12 +150,13 @@
 	core/java/android/hardware/ISerialManager.aidl \
 	core/java/android/hardware/display/IDisplayManager.aidl \
 	core/java/android/hardware/display/IDisplayManagerCallback.aidl \
-	core/java/android/hardware/display/IVirtualDisplayCallbacks.aidl \
+	core/java/android/hardware/display/IVirtualDisplayCallback.aidl \
 	core/java/android/hardware/hdmi/IHdmiControlCallback.aidl \
 	core/java/android/hardware/hdmi/IHdmiControlService.aidl \
 	core/java/android/hardware/hdmi/IHdmiDeviceEventListener.aidl \
 	core/java/android/hardware/hdmi/IHdmiHotplugEventListener.aidl \
 	core/java/android/hardware/hdmi/IHdmiInputChangeListener.aidl \
+	core/java/android/hardware/hdmi/IHdmiMhlVendorCommandListener.aidl \
 	core/java/android/hardware/hdmi/IHdmiRecordListener.aidl \
 	core/java/android/hardware/hdmi/IHdmiSystemAudioModeChangeListener.aidl \
 	core/java/android/hardware/hdmi/IHdmiVendorCommandListener.aidl \
@@ -203,6 +204,7 @@
 	core/java/android/os/IUserManager.aidl \
 	core/java/android/os/IVibratorService.aidl \
 	core/java/android/service/notification/INotificationListener.aidl \
+	core/java/android/service/notification/IStatusBarNotificationHolder.aidl \
 	core/java/android/service/notification/IConditionListener.aidl \
 	core/java/android/service/notification/IConditionProvider.aidl \
 	core/java/android/print/ILayoutResultCallback.aidl \
@@ -324,17 +326,10 @@
 	media/java/android/media/IRemoteVolumeObserver.aidl \
 	media/java/android/media/IRingtonePlayer.aidl \
 	media/java/android/media/IVolumeController.aidl \
-	media/java/android/media/browse/IMediaBrowserService.aidl \
-	media/java/android/media/browse/IMediaBrowserServiceCallbacks.aidl \
 	media/java/android/media/projection/IMediaProjection.aidl \
 	media/java/android/media/projection/IMediaProjectionCallback.aidl \
 	media/java/android/media/projection/IMediaProjectionManager.aidl \
-	media/java/android/media/routing/IMediaRouteService.aidl \
-	media/java/android/media/routing/IMediaRouteClientCallback.aidl \
-	media/java/android/media/routing/IMediaRouter.aidl \
-	media/java/android/media/routing/IMediaRouterDelegate.aidl \
-	media/java/android/media/routing/IMediaRouterRoutingCallback.aidl \
-	media/java/android/media/routing/IMediaRouterStateCallback.aidl \
+	media/java/android/media/projection/IMediaProjectionWatcherCallback.aidl \
 	media/java/android/media/session/IActiveSessionsListener.aidl \
 	media/java/android/media/session/ISessionController.aidl \
 	media/java/android/media/session/ISessionControllerCallback.aidl \
@@ -350,14 +345,16 @@
 	media/java/android/media/tv/ITvInputServiceCallback.aidl \
 	media/java/android/media/tv/ITvInputSession.aidl \
 	media/java/android/media/tv/ITvInputSessionCallback.aidl \
-	telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl \
-	telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl \
-	telecomm/java/com/android/internal/telecomm/IConnectionService.aidl \
-	telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl \
-	telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl \
-	telecomm/java/com/android/internal/telecomm/IInCallService.aidl \
-	telecomm/java/com/android/internal/telecomm/ITelecommService.aidl \
-	telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl \
+	media/java/android/service/media/IMediaBrowserService.aidl \
+	media/java/android/service/media/IMediaBrowserServiceCallbacks.aidl \
+	telecomm/java/com/android/internal/telecom/IVideoCallback.aidl \
+	telecomm/java/com/android/internal/telecom/IVideoProvider.aidl \
+	telecomm/java/com/android/internal/telecom/IConnectionService.aidl \
+	telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl \
+	telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl \
+	telecomm/java/com/android/internal/telecom/IInCallService.aidl \
+	telecomm/java/com/android/internal/telecom/ITelecomService.aidl \
+	telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl \
 	telephony/java/com/android/ims/internal/IImsCallSession.aidl \
 	telephony/java/com/android/ims/internal/IImsCallSessionListener.aidl \
 	telephony/java/com/android/ims/internal/IImsConfig.aidl \
@@ -380,7 +377,6 @@
 	telephony/java/com/android/internal/telephony/ISub.aidl \
 	telephony/java/com/android/internal/telephony/IMms.aidl \
 	wifi/java/android/net/wifi/IWifiManager.aidl \
-	wifi/java/android/net/wifi/passpoint/IWifiPasspointManager.aidl \
 	wifi/java/android/net/wifi/p2p/IWifiP2pManager.aidl \
 	wifi/java/android/net/wifi/IWifiScanner.aidl \
 	wifi/java/android/net/wifi/IRttManager.aidl \
@@ -494,9 +490,11 @@
 	frameworks/base/location/java/android/location/FusedBatchOptions.aidl \
 	frameworks/base/location/java/com/android/internal/location/ProviderProperties.aidl \
 	frameworks/base/location/java/com/android/internal/location/ProviderRequest.aidl \
+	frameworks/base/media/java/android/media/AudioAttributes.aidl \
+	frameworks/base/media/java/android/media/MediaDescription.aidl \
 	frameworks/base/media/java/android/media/MediaMetadata.aidl \
 	frameworks/base/media/java/android/media/Rating.aidl \
-	frameworks/base/media/java/android/media/routing/MediaRouteSelector.aidl \
+	frameworks/base/media/java/android/media/browse/MediaBrowser.aidl \
 	frameworks/base/media/java/android/media/session/MediaSession.aidl \
 	frameworks/base/media/java/android/media/session/PlaybackState.aidl \
 	frameworks/base/telephony/java/android/telephony/ServiceState.aidl \
diff --git a/CleanSpec.mk b/CleanSpec.mk
index c7cf940..28c2172 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -209,7 +209,7 @@
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework-base_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/ims-common_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework2_intermediates)
-$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework-base_intermediates/src/telecomm/java/com/android/internal/telecomm)
+$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework-base_intermediates/src/telecomm/java/com/android/internal/telecom)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework_intermediates)
 $(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/framework.* $(PRODUCT_OUT)/system/framework2.*)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework-base_intermediates)
@@ -221,6 +221,9 @@
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/services.core_intermediates)
 $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/services_intermediates)
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/bin/inputflinger $(PRODUCT_OUT)/symbols/system/bin/inputflinger)
+$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/APPS/RsFountainFbo_intermediates)
+$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/framework-base_intermediates/src/telecomm/java/com/android/internal/telecomm)
 
 # ******************************************************************
 # NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST ABOVE THIS BANNER
diff --git a/api/current.txt b/api/current.txt
index bdeae78..3ab4ce4 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -23,7 +23,6 @@
     field public static final java.lang.String BIND_DEVICE_ADMIN = "android.permission.BIND_DEVICE_ADMIN";
     field public static final java.lang.String BIND_DREAM_SERVICE = "android.permission.BIND_DREAM_SERVICE";
     field public static final java.lang.String BIND_INPUT_METHOD = "android.permission.BIND_INPUT_METHOD";
-    field public static final java.lang.String BIND_MEDIA_ROUTE_SERVICE = "android.permission.BIND_MEDIA_ROUTE_SERVICE";
     field public static final java.lang.String BIND_NFC_SERVICE = "android.permission.BIND_NFC_SERVICE";
     field public static final java.lang.String BIND_NOTIFICATION_LISTENER_SERVICE = "android.permission.BIND_NOTIFICATION_LISTENER_SERVICE";
     field public static final java.lang.String BIND_PRINT_SERVICE = "android.permission.BIND_PRINT_SERVICE";
@@ -226,34 +225,6 @@
     ctor public R.array();
     field public static final int emailAddressTypes = 17235968; // 0x1070000
     field public static final int imProtocols = 17235969; // 0x1070001
-    field public static final int l_resource_pad1 = 17236000; // 0x1070020
-    field public static final int l_resource_pad10 = 17235991; // 0x1070017
-    field public static final int l_resource_pad11 = 17235990; // 0x1070016
-    field public static final int l_resource_pad12 = 17235989; // 0x1070015
-    field public static final int l_resource_pad13 = 17235988; // 0x1070014
-    field public static final int l_resource_pad14 = 17235987; // 0x1070013
-    field public static final int l_resource_pad15 = 17235986; // 0x1070012
-    field public static final int l_resource_pad16 = 17235985; // 0x1070011
-    field public static final int l_resource_pad17 = 17235984; // 0x1070010
-    field public static final int l_resource_pad18 = 17235983; // 0x107000f
-    field public static final int l_resource_pad19 = 17235982; // 0x107000e
-    field public static final int l_resource_pad2 = 17235999; // 0x107001f
-    field public static final int l_resource_pad20 = 17235981; // 0x107000d
-    field public static final int l_resource_pad21 = 17235980; // 0x107000c
-    field public static final int l_resource_pad22 = 17235979; // 0x107000b
-    field public static final int l_resource_pad23 = 17235978; // 0x107000a
-    field public static final int l_resource_pad24 = 17235977; // 0x1070009
-    field public static final int l_resource_pad25 = 17235976; // 0x1070008
-    field public static final int l_resource_pad26 = 17235975; // 0x1070007
-    field public static final int l_resource_pad27 = 17235974; // 0x1070006
-    field public static final int l_resource_pad28 = 17235973; // 0x1070005
-    field public static final int l_resource_pad3 = 17235998; // 0x107001e
-    field public static final int l_resource_pad4 = 17235997; // 0x107001d
-    field public static final int l_resource_pad5 = 17235996; // 0x107001c
-    field public static final int l_resource_pad6 = 17235995; // 0x107001b
-    field public static final int l_resource_pad7 = 17235994; // 0x107001a
-    field public static final int l_resource_pad8 = 17235993; // 0x1070019
-    field public static final int l_resource_pad9 = 17235992; // 0x1070018
     field public static final int organizationTypes = 17235970; // 0x1070002
     field public static final int phoneTypes = 17235971; // 0x1070003
     field public static final int postalAddressTypes = 17235972; // 0x1070004
@@ -325,8 +296,9 @@
     field public static final int alphabeticShortcut = 16843235; // 0x10101e3
     field public static final int alwaysDrawnWithCache = 16842991; // 0x10100ef
     field public static final int alwaysRetainTaskState = 16843267; // 0x1010203
-    field public static final int amPmBackgroundColor = 16843942; // 0x10104a6
-    field public static final int amPmTextColor = 16843941; // 0x10104a5
+    field public static final int amPmBackgroundColor = 16843941; // 0x10104a5
+    field public static final int amPmTextColor = 16843940; // 0x10104a4
+    field public static final int ambientShadowAlpha = 16843966; // 0x10104be
     field public static final int angle = 16843168; // 0x10101a0
     field public static final int animateFirstView = 16843477; // 0x10102d5
     field public static final int animateLayoutChanges = 16843506; // 0x10102f2
@@ -405,8 +377,8 @@
     field public static final int centerY = 16843171; // 0x10101a3
     field public static final int checkBoxPreferenceStyle = 16842895; // 0x101008f
     field public static final int checkMark = 16843016; // 0x1010108
-    field public static final int checkMarkTint = 16843944; // 0x10104a8
-    field public static final int checkMarkTintMode = 16843945; // 0x10104a9
+    field public static final int checkMarkTint = 16843943; // 0x10104a7
+    field public static final int checkMarkTintMode = 16843944; // 0x10104a8
     field public static final int checkable = 16843237; // 0x10101e5
     field public static final int checkableBehavior = 16843232; // 0x10101e0
     field public static final int checkboxStyle = 16842860; // 0x101006c
@@ -458,16 +430,18 @@
     field public static final int configure = 16843357; // 0x101025d
     field public static final int constantSize = 16843158; // 0x1010196
     field public static final int content = 16843355; // 0x101025b
+    field public static final int contentAgeHint = 16843961; // 0x10104b9
     field public static final int contentAuthority = 16843408; // 0x1010290
     field public static final int contentDescription = 16843379; // 0x1010273
     field public static final int contentInsetEnd = 16843860; // 0x1010454
     field public static final int contentInsetLeft = 16843861; // 0x1010455
     field public static final int contentInsetRight = 16843862; // 0x1010456
     field public static final int contentInsetStart = 16843859; // 0x1010453
-    field public static final int controlX1 = 16843798; // 0x1010416
-    field public static final int controlX2 = 16843800; // 0x1010418
-    field public static final int controlY1 = 16843799; // 0x1010417
-    field public static final int controlY2 = 16843801; // 0x1010419
+    field public static final int controlX1 = 16843772; // 0x10103fc
+    field public static final int controlX2 = 16843774; // 0x10103fe
+    field public static final int controlY1 = 16843773; // 0x10103fd
+    field public static final int controlY2 = 16843775; // 0x10103ff
+    field public static final int country = 16843962; // 0x10104ba
     field public static final int cropToPadding = 16843043; // 0x1010123
     field public static final int cursorVisible = 16843090; // 0x1010152
     field public static final int customNavigationLayout = 16843474; // 0x10102d2
@@ -476,11 +450,11 @@
     field public static final int dashGap = 16843175; // 0x10101a7
     field public static final int dashWidth = 16843174; // 0x10101a6
     field public static final int data = 16842798; // 0x101002e
-    field public static final int datePickerDialogTheme = 16843949; // 0x10104ad
-    field public static final int datePickerMode = 16843956; // 0x10104b4
+    field public static final int datePickerDialogTheme = 16843948; // 0x10104ac
+    field public static final int datePickerMode = 16843955; // 0x10104b3
     field public static final int datePickerStyle = 16843612; // 0x101035c
     field public static final int dateTextAppearance = 16843593; // 0x1010349
-    field public static final int dayOfWeekBackgroundColor = 16843924; // 0x1010494
+    field public static final int dayOfWeekBackground = 16843924; // 0x1010494
     field public static final int dayOfWeekTextAppearance = 16843925; // 0x1010495
     field public static final int debuggable = 16842767; // 0x101000f
     field public static final int defaultValue = 16843245; // 0x10101ed
@@ -580,13 +554,14 @@
     field public static final int fastScrollOverlayPosition = 16843578; // 0x101033a
     field public static final int fastScrollPreviewBackgroundLeft = 16843575; // 0x1010337
     field public static final int fastScrollPreviewBackgroundRight = 16843576; // 0x1010338
-    field public static final int fastScrollStyle = 16843793; // 0x1010411
+    field public static final int fastScrollStyle = 16843767; // 0x10103f7
     field public static final int fastScrollTextColor = 16843609; // 0x1010359
     field public static final int fastScrollThumbDrawable = 16843574; // 0x1010336
     field public static final int fastScrollTrackDrawable = 16843577; // 0x1010339
     field public static final int fillAfter = 16843197; // 0x10101bd
+    field public static final int fillAlpha = 16843980; // 0x10104cc
     field public static final int fillBefore = 16843196; // 0x10101bc
-    field public static final int fillColor = 16843806; // 0x101041e
+    field public static final int fillColor = 16843780; // 0x1010404
     field public static final int fillEnabled = 16843343; // 0x101024f
     field public static final int fillViewport = 16843130; // 0x101017a
     field public static final int filter = 16843035; // 0x101011b
@@ -600,7 +575,7 @@
     field public static final int focusableInTouchMode = 16842971; // 0x10100db
     field public static final int focusedMonthDateColor = 16843587; // 0x1010343
     field public static final int fontFamily = 16843692; // 0x10103ac
-    field public static final int fontFeatureSettings = 16843960; // 0x10104b8
+    field public static final int fontFeatureSettings = 16843959; // 0x10104b7
     field public static final int footerDividersEnabled = 16843311; // 0x101022f
     field public static final int foreground = 16843017; // 0x1010109
     field public static final int foregroundGravity = 16843264; // 0x1010200
@@ -610,12 +585,20 @@
     field public static final int format12Hour = 16843722; // 0x10103ca
     field public static final int format24Hour = 16843723; // 0x10103cb
     field public static final int fragment = 16843491; // 0x10102e3
+    field public static final int fragmentAllowEnterTransitionOverlap = 16843976; // 0x10104c8
+    field public static final int fragmentAllowReturnTransitionOverlap = 16843977; // 0x10104c9
     field public static final int fragmentCloseEnterAnimation = 16843495; // 0x10102e7
     field public static final int fragmentCloseExitAnimation = 16843496; // 0x10102e8
+    field public static final int fragmentEnterTransition = 16843971; // 0x10104c3
+    field public static final int fragmentExitTransition = 16843970; // 0x10104c2
     field public static final int fragmentFadeEnterAnimation = 16843497; // 0x10102e9
     field public static final int fragmentFadeExitAnimation = 16843498; // 0x10102ea
     field public static final int fragmentOpenEnterAnimation = 16843493; // 0x10102e5
     field public static final int fragmentOpenExitAnimation = 16843494; // 0x10102e6
+    field public static final int fragmentReenterTransition = 16843975; // 0x10104c7
+    field public static final int fragmentReturnTransition = 16843973; // 0x10104c5
+    field public static final int fragmentSharedElementEnterTransition = 16843972; // 0x10104c4
+    field public static final int fragmentSharedElementReturnTransition = 16843974; // 0x10104c6
     field public static final int freezesText = 16843116; // 0x101016c
     field public static final int fromAlpha = 16843210; // 0x10101ca
     field public static final int fromDegrees = 16843187; // 0x10101b3
@@ -653,7 +636,6 @@
     field public static final int hasCode = 16842764; // 0x101000c
     field public static final int headerAmPmTextAppearance = 16843936; // 0x10104a0
     field public static final int headerBackground = 16843055; // 0x101012f
-    field public static final int headerBackgroundColor = 16843937; // 0x10104a1
     field public static final int headerDayOfMonthTextAppearance = 16843927; // 0x1010497
     field public static final int headerDividersEnabled = 16843310; // 0x101022e
     field public static final int headerMonthTextAppearance = 16843926; // 0x1010496
@@ -710,7 +692,7 @@
     field public static final int innerRadiusRatio = 16843163; // 0x101019b
     field public static final deprecated int inputMethod = 16843112; // 0x1010168
     field public static final int inputType = 16843296; // 0x1010220
-    field public static final int inset = 16843958; // 0x10104b6
+    field public static final int inset = 16843957; // 0x10104b5
     field public static final int insetBottom = 16843194; // 0x10101ba
     field public static final int insetLeft = 16843191; // 0x10101b7
     field public static final int insetRight = 16843192; // 0x10101b8
@@ -751,32 +733,6 @@
     field public static final int keyboardMode = 16843341; // 0x101024d
     field public static final int keycode = 16842949; // 0x10100c5
     field public static final int killAfterRestore = 16843420; // 0x101029c
-    field public static final int l_resource_pad1 = 16843792; // 0x1010410
-    field public static final int l_resource_pad10 = 16843783; // 0x1010407
-    field public static final int l_resource_pad11 = 16843782; // 0x1010406
-    field public static final int l_resource_pad12 = 16843781; // 0x1010405
-    field public static final int l_resource_pad13 = 16843780; // 0x1010404
-    field public static final int l_resource_pad14 = 16843779; // 0x1010403
-    field public static final int l_resource_pad15 = 16843778; // 0x1010402
-    field public static final int l_resource_pad16 = 16843777; // 0x1010401
-    field public static final int l_resource_pad17 = 16843776; // 0x1010400
-    field public static final int l_resource_pad18 = 16843775; // 0x10103ff
-    field public static final int l_resource_pad19 = 16843774; // 0x10103fe
-    field public static final int l_resource_pad2 = 16843791; // 0x101040f
-    field public static final int l_resource_pad20 = 16843773; // 0x10103fd
-    field public static final int l_resource_pad21 = 16843772; // 0x10103fc
-    field public static final int l_resource_pad22 = 16843771; // 0x10103fb
-    field public static final int l_resource_pad23 = 16843770; // 0x10103fa
-    field public static final int l_resource_pad24 = 16843769; // 0x10103f9
-    field public static final int l_resource_pad25 = 16843768; // 0x10103f8
-    field public static final int l_resource_pad26 = 16843767; // 0x10103f7
-    field public static final int l_resource_pad3 = 16843790; // 0x101040e
-    field public static final int l_resource_pad4 = 16843789; // 0x101040d
-    field public static final int l_resource_pad5 = 16843788; // 0x101040c
-    field public static final int l_resource_pad6 = 16843787; // 0x101040b
-    field public static final int l_resource_pad7 = 16843786; // 0x101040a
-    field public static final int l_resource_pad8 = 16843785; // 0x1010409
-    field public static final int l_resource_pad9 = 16843784; // 0x1010408
     field public static final int label = 16842753; // 0x1010001
     field public static final int labelFor = 16843718; // 0x10103c6
     field public static final int labelTextSize = 16843317; // 0x1010235
@@ -784,8 +740,8 @@
     field public static final int largeScreens = 16843398; // 0x1010286
     field public static final int largestWidthLimitDp = 16843622; // 0x1010366
     field public static final int launchMode = 16842781; // 0x101001d
-    field public static final int launchTaskBehindBackgroundAnimation = 16843921; // 0x1010491
     field public static final int launchTaskBehindSourceAnimation = 16843922; // 0x1010492
+    field public static final int launchTaskBehindTargetAnimation = 16843921; // 0x1010491
     field public static final int layerType = 16843604; // 0x1010354
     field public static final int layout = 16842994; // 0x10100f2
     field public static final int layoutAnimation = 16842988; // 0x10100ec
@@ -836,7 +792,7 @@
     field public static final int layout_x = 16843135; // 0x101017f
     field public static final int layout_y = 16843136; // 0x1010180
     field public static final int left = 16843181; // 0x10101ad
-    field public static final int letterSpacing = 16843959; // 0x10104b7
+    field public static final int letterSpacing = 16843958; // 0x10104b6
     field public static final int lineSpacingExtra = 16843287; // 0x1010217
     field public static final int lineSpacingMultiplier = 16843288; // 0x1010218
     field public static final int lines = 16843092; // 0x1010154
@@ -903,6 +859,8 @@
     field public static final int multiprocess = 16842771; // 0x1010013
     field public static final int name = 16842755; // 0x1010003
     field public static final int navigationBarColor = 16843858; // 0x1010452
+    field public static final int navigationContentDescription = 16843969; // 0x10104c1
+    field public static final int navigationIcon = 16843968; // 0x10104c0
     field public static final int navigationMode = 16843471; // 0x10102cf
     field public static final int negativeButtonText = 16843254; // 0x10101f6
     field public static final int nestedScrollingEnabled = 16843830; // 0x1010436
@@ -916,9 +874,9 @@
     field public static final int notificationTimeout = 16843651; // 0x1010383
     field public static final int numColumns = 16843032; // 0x1010118
     field public static final int numStars = 16843076; // 0x1010144
-    field public static final int numbersBackgroundColor = 16843939; // 0x10104a3
-    field public static final int numbersSelectorColor = 16843940; // 0x10104a4
-    field public static final int numbersTextColor = 16843938; // 0x10104a2
+    field public static final int numbersBackgroundColor = 16843938; // 0x10104a2
+    field public static final int numbersSelectorColor = 16843939; // 0x10104a3
+    field public static final int numbersTextColor = 16843937; // 0x10104a1
     field public static final deprecated int numeric = 16843109; // 0x1010165
     field public static final int numericShortcut = 16843236; // 0x10101e4
     field public static final int onClick = 16843375; // 0x101026f
@@ -930,6 +888,7 @@
     field public static final int orderingFromXml = 16843239; // 0x10101e7
     field public static final int orientation = 16842948; // 0x10100c4
     field public static final int outAnimation = 16843128; // 0x1010178
+    field public static final int outlineProvider = 16843960; // 0x10104b8
     field public static final int overScrollFooter = 16843459; // 0x10102c3
     field public static final int overScrollHeader = 16843458; // 0x10102c2
     field public static final int overScrollMode = 16843457; // 0x10102c1
@@ -952,9 +911,10 @@
     field public static final int parentActivityName = 16843687; // 0x10103a7
     field public static final deprecated int password = 16843100; // 0x101015c
     field public static final int path = 16842794; // 0x101002a
-    field public static final int pathData = 16843807; // 0x101041f
+    field public static final int pathData = 16843781; // 0x1010405
     field public static final int pathPattern = 16842796; // 0x101002c
     field public static final int pathPrefix = 16842795; // 0x101002b
+    field public static final int patternPathData = 16843978; // 0x10104ca
     field public static final int permission = 16842758; // 0x1010006
     field public static final int permissionFlags = 16843719; // 0x10103c7
     field public static final int permissionGroup = 16842762; // 0x101000a
@@ -972,7 +932,7 @@
     field public static final int popupKeyboard = 16843331; // 0x1010243
     field public static final int popupLayout = 16843323; // 0x101023b
     field public static final int popupMenuStyle = 16843520; // 0x1010300
-    field public static final int popupTheme = 16843946; // 0x10104aa
+    field public static final int popupTheme = 16843945; // 0x10104a9
     field public static final int popupWindowStyle = 16842870; // 0x1010076
     field public static final int port = 16842793; // 0x1010029
     field public static final int positiveButtonText = 16843253; // 0x10101f5
@@ -1026,6 +986,8 @@
     field public static final int readPermission = 16842759; // 0x1010007
     field public static final int recognitionService = 16843932; // 0x101049c
     field public static final int relinquishTaskIdentity = 16843894; // 0x1010476
+    field public static final int reparent = 16843964; // 0x10104bc
+    field public static final int reparentWithOverlay = 16843965; // 0x10104bd
     field public static final int repeatCount = 16843199; // 0x10101bf
     field public static final int repeatMode = 16843200; // 0x10101c0
     field public static final int reqFiveWayNav = 16843314; // 0x1010232
@@ -1037,7 +999,6 @@
     field public static final int required = 16843406; // 0x101028e
     field public static final int requiredAccountType = 16843734; // 0x10103d6
     field public static final int requiredForAllUsers = 16843728; // 0x10103d0
-    field public static final int requiredForProfile = 16843816; // 0x1010428
     field public static final int requiresFadingEdge = 16843685; // 0x10103a5
     field public static final int requiresSmallestWidthDp = 16843620; // 0x1010364
     field public static final int resizeMode = 16843619; // 0x1010363
@@ -1047,6 +1008,7 @@
     field public static final deprecated int restoreNeedsApplication = 16843421; // 0x101029d
     field public static final int restrictedAccountType = 16843733; // 0x10103d5
     field public static final int restrictionType = 16843923; // 0x1010493
+    field public static final int resumeWhilePausing = 16843954; // 0x10104b2
     field public static final int reversible = 16843851; // 0x101044b
     field public static final int right = 16843183; // 0x10101af
     field public static final int ringtonePreferenceStyle = 16842899; // 0x1010093
@@ -1125,7 +1087,7 @@
     field public static final int showDividers = 16843561; // 0x1010329
     field public static final int showOnLockScreen = 16843721; // 0x10103c9
     field public static final int showSilent = 16843259; // 0x10101fb
-    field public static final int showText = 16843950; // 0x10104ae
+    field public static final int showText = 16843949; // 0x10104ad
     field public static final int showWeekNumber = 16843582; // 0x101033e
     field public static final int shownWeekCount = 16843585; // 0x1010341
     field public static final int shrinkColumns = 16843082; // 0x101014a
@@ -1144,6 +1106,7 @@
     field public static final int spinnersShown = 16843595; // 0x101034b
     field public static final int splitMotionEvents = 16843503; // 0x10102ef
     field public static final int splitTrack = 16843852; // 0x101044c
+    field public static final int spotShadowAlpha = 16843967; // 0x10104bf
     field public static final int src = 16843033; // 0x1010119
     field public static final int ssp = 16843747; // 0x10103e3
     field public static final int sspPattern = 16843749; // 0x10103e5
@@ -1186,11 +1149,12 @@
     field public static final int streamType = 16843273; // 0x1010209
     field public static final int stretchColumns = 16843081; // 0x1010149
     field public static final int stretchMode = 16843030; // 0x1010116
-    field public static final int strokeColor = 16843808; // 0x1010420
-    field public static final int strokeLineCap = 16843813; // 0x1010425
-    field public static final int strokeLineJoin = 16843814; // 0x1010426
-    field public static final int strokeMiterLimit = 16843815; // 0x1010427
-    field public static final int strokeWidth = 16843809; // 0x1010421
+    field public static final int strokeAlpha = 16843979; // 0x10104cb
+    field public static final int strokeColor = 16843782; // 0x1010406
+    field public static final int strokeLineCap = 16843787; // 0x101040b
+    field public static final int strokeLineJoin = 16843788; // 0x101040c
+    field public static final int strokeMiterLimit = 16843789; // 0x101040d
+    field public static final int strokeWidth = 16843783; // 0x1010407
     field public static final int submitBackground = 16843912; // 0x1010488
     field public static final int subtitle = 16843473; // 0x10102d1
     field public static final int subtitleTextAppearance = 16843823; // 0x101042f
@@ -1313,11 +1277,11 @@
     field public static final int tileModeX = 16843895; // 0x1010477
     field public static final int tileModeY = 16843896; // 0x1010478
     field public static final int timePickerDialogTheme = 16843934; // 0x101049e
-    field public static final int timePickerMode = 16843957; // 0x10104b5
+    field public static final int timePickerMode = 16843956; // 0x10104b4
     field public static final int timePickerStyle = 16843933; // 0x101049d
     field public static final int timeZone = 16843724; // 0x10103cc
     field public static final int tint = 16843041; // 0x1010121
-    field public static final int tintMode = 16843797; // 0x1010415
+    field public static final int tintMode = 16843771; // 0x10103fb
     field public static final int title = 16843233; // 0x10101e1
     field public static final int titleCondensed = 16843234; // 0x10101e2
     field public static final int titleTextAppearance = 16843822; // 0x101042e
@@ -1330,7 +1294,7 @@
     field public static final int toXScale = 16843203; // 0x10101c3
     field public static final int toYDelta = 16843209; // 0x10101c9
     field public static final int toYScale = 16843205; // 0x10101c5
-    field public static final int toolbarStyle = 16843947; // 0x10104ab
+    field public static final int toolbarStyle = 16843946; // 0x10104aa
     field public static final int top = 16843182; // 0x10101ae
     field public static final int topBright = 16842955; // 0x10100cb
     field public static final int topDark = 16842951; // 0x10100c7
@@ -1343,18 +1307,18 @@
     field public static final int transformPivotX = 16843552; // 0x1010320
     field public static final int transformPivotY = 16843553; // 0x1010321
     field public static final int transition = 16843743; // 0x10103df
-    field public static final int transitionGroup = 16843803; // 0x101041b
-    field public static final int transitionName = 16843802; // 0x101041a
+    field public static final int transitionGroup = 16843777; // 0x1010401
+    field public static final int transitionName = 16843776; // 0x1010400
     field public static final int transitionOrdering = 16843744; // 0x10103e0
+    field public static final int transitionVisibilityMode = 16843900; // 0x101047c
     field public static final int translateX = 16843866; // 0x101045a
     field public static final int translateY = 16843867; // 0x101045b
     field public static final int translationX = 16843554; // 0x1010322
     field public static final int translationY = 16843555; // 0x1010323
-    field public static final int translationZ = 16843796; // 0x1010414
-    field public static final int trimPathEnd = 16843811; // 0x1010423
-    field public static final int trimPathOffset = 16843812; // 0x1010424
-    field public static final int trimPathStart = 16843810; // 0x1010422
-    field public static final int tvContentRatingDescription = 16843955; // 0x10104b3
+    field public static final int translationZ = 16843770; // 0x10103fa
+    field public static final int trimPathEnd = 16843785; // 0x1010409
+    field public static final int trimPathOffset = 16843786; // 0x101040a
+    field public static final int trimPathStart = 16843784; // 0x1010408
     field public static final int type = 16843169; // 0x10101a1
     field public static final int typeface = 16842902; // 0x1010096
     field public static final int uiOptions = 16843672; // 0x1010398
@@ -1379,10 +1343,9 @@
     field public static final int verticalGap = 16843328; // 0x1010240
     field public static final int verticalScrollbarPosition = 16843572; // 0x1010334
     field public static final int verticalSpacing = 16843029; // 0x1010115
-    field public static final int viewportHeight = 16843805; // 0x101041d
-    field public static final int viewportWidth = 16843804; // 0x101041c
+    field public static final int viewportHeight = 16843779; // 0x1010403
+    field public static final int viewportWidth = 16843778; // 0x1010402
     field public static final int visibility = 16842972; // 0x10100dc
-    field public static final int visibilityMode = 16843900; // 0x101047c
     field public static final int visible = 16843156; // 0x1010194
     field public static final int vmSafeMode = 16843448; // 0x10102b8
     field public static final int voiceIcon = 16843908; // 0x1010484
@@ -1411,15 +1374,16 @@
     field public static final int windowActionBar = 16843469; // 0x10102cd
     field public static final int windowActionBarOverlay = 16843492; // 0x10102e4
     field public static final int windowActionModeOverlay = 16843485; // 0x10102dd
+    field public static final int windowActivityTransitions = 16843981; // 0x10104cd
     field public static final int windowAllowEnterTransitionOverlap = 16843836; // 0x101043c
-    field public static final int windowAllowExitTransitionOverlap = 16843835; // 0x101043b
+    field public static final int windowAllowReturnTransitionOverlap = 16843835; // 0x101043b
     field public static final int windowAnimationStyle = 16842926; // 0x10100ae
     field public static final int windowBackground = 16842836; // 0x1010054
-    field public static final int windowClipToOutline = 16843948; // 0x10104ac
+    field public static final int windowClipToOutline = 16843947; // 0x10104ab
     field public static final int windowCloseOnTouchOutside = 16843611; // 0x101035b
     field public static final int windowContentOverlay = 16842841; // 0x1010059
-    field public static final int windowContentTransitionManager = 16843795; // 0x1010413
-    field public static final int windowContentTransitions = 16843794; // 0x1010412
+    field public static final int windowContentTransitionManager = 16843769; // 0x10103f9
+    field public static final int windowContentTransitions = 16843768; // 0x10103f8
     field public static final int windowDisablePreview = 16843298; // 0x1010222
     field public static final int windowDrawsSystemBarBackgrounds = 16843856; // 0x1010450
     field public static final int windowElevation = 16843920; // 0x1010490
@@ -1438,12 +1402,13 @@
     field public static final int windowNoDisplay = 16843294; // 0x101021e
     field public static final int windowNoTitle = 16842838; // 0x1010056
     field public static final int windowOverscan = 16843727; // 0x10103cf
-    field public static final int windowReenterTransition = 16843952; // 0x10104b0
-    field public static final int windowReturnTransition = 16843951; // 0x10104af
+    field public static final int windowReenterTransition = 16843951; // 0x10104af
+    field public static final int windowReturnTransition = 16843950; // 0x10104ae
     field public static final int windowSharedElementEnterTransition = 16843833; // 0x1010439
     field public static final int windowSharedElementExitTransition = 16843834; // 0x101043a
-    field public static final int windowSharedElementReenterTransition = 16843954; // 0x10104b2
-    field public static final int windowSharedElementReturnTransition = 16843953; // 0x10104b1
+    field public static final int windowSharedElementReenterTransition = 16843953; // 0x10104b1
+    field public static final int windowSharedElementReturnTransition = 16843952; // 0x10104b0
+    field public static final int windowSharedElementsUseOverlay = 16843963; // 0x10104bb
     field public static final int windowShowAnimation = 16842934; // 0x10100b6
     field public static final int windowShowWallpaper = 16843410; // 0x1010292
     field public static final int windowSoftInputMode = 16843307; // 0x101022b
@@ -1505,16 +1470,6 @@
     field public static final int app_icon_size = 17104896; // 0x1050000
     field public static final int dialog_min_width_major = 17104899; // 0x1050003
     field public static final int dialog_min_width_minor = 17104900; // 0x1050004
-    field public static final int l_resource_pad1 = 17104912; // 0x1050010
-    field public static final int l_resource_pad10 = 17104903; // 0x1050007
-    field public static final int l_resource_pad2 = 17104911; // 0x105000f
-    field public static final int l_resource_pad3 = 17104910; // 0x105000e
-    field public static final int l_resource_pad4 = 17104909; // 0x105000d
-    field public static final int l_resource_pad5 = 17104908; // 0x105000c
-    field public static final int l_resource_pad6 = 17104907; // 0x105000b
-    field public static final int l_resource_pad7 = 17104906; // 0x105000a
-    field public static final int l_resource_pad8 = 17104905; // 0x1050009
-    field public static final int l_resource_pad9 = 17104904; // 0x1050008
     field public static final int notification_large_icon_height = 17104902; // 0x1050006
     field public static final int notification_large_icon_width = 17104901; // 0x1050005
     field public static final int thumbnail_height = 17104897; // 0x1050001
@@ -1730,28 +1685,10 @@
     field public static final int inputArea = 16908318; // 0x102001e
     field public static final int inputExtractEditText = 16908325; // 0x1020025
     field public static final int keyboardView = 16908326; // 0x1020026
-    field public static final int l_resource_pad1 = 16908352; // 0x1020040
-    field public static final int l_resource_pad10 = 16908343; // 0x1020037
-    field public static final int l_resource_pad11 = 16908342; // 0x1020036
-    field public static final int l_resource_pad12 = 16908341; // 0x1020035
-    field public static final int l_resource_pad13 = 16908340; // 0x1020034
-    field public static final int l_resource_pad14 = 16908339; // 0x1020033
-    field public static final int l_resource_pad15 = 16908338; // 0x1020032
-    field public static final int l_resource_pad16 = 16908337; // 0x1020031
-    field public static final int l_resource_pad17 = 16908336; // 0x1020030
-    field public static final int l_resource_pad18 = 16908335; // 0x102002f
-    field public static final int l_resource_pad19 = 16908334; // 0x102002e
-    field public static final int l_resource_pad2 = 16908351; // 0x102003f
-    field public static final int l_resource_pad3 = 16908350; // 0x102003e
-    field public static final int l_resource_pad4 = 16908349; // 0x102003d
-    field public static final int l_resource_pad5 = 16908348; // 0x102003c
-    field public static final int l_resource_pad6 = 16908347; // 0x102003b
-    field public static final int l_resource_pad7 = 16908346; // 0x102003a
-    field public static final int l_resource_pad8 = 16908345; // 0x1020039
-    field public static final int l_resource_pad9 = 16908344; // 0x1020038
     field public static final int list = 16908298; // 0x102000a
-    field public static final int mask = 16908353; // 0x1020041
+    field public static final int mask = 16908334; // 0x102002e
     field public static final int message = 16908299; // 0x102000b
+    field public static final int navigationBarBackground = 16908336; // 0x1020030
     field public static final int paste = 16908322; // 0x1020022
     field public static final int primary = 16908300; // 0x102000c
     field public static final int progress = 16908301; // 0x102000d
@@ -1760,6 +1697,7 @@
     field public static final int selectTextMode = 16908333; // 0x102002d
     field public static final int selectedIcon = 16908302; // 0x102000e
     field public static final int startSelectingText = 16908328; // 0x1020028
+    field public static final int statusBarBackground = 16908335; // 0x102002f
     field public static final int stopSelectingText = 16908329; // 0x1020029
     field public static final int summary = 16908304; // 0x1020010
     field public static final int switchInputMethod = 16908324; // 0x1020024
@@ -1794,14 +1732,10 @@
     field public static final int decelerate_cubic = 17563651; // 0x10c0003
     field public static final int decelerate_quad = 17563649; // 0x10c0001
     field public static final int decelerate_quint = 17563653; // 0x10c0005
-    field public static final int fast_out_linear_in = 17563667; // 0x10c0013
-    field public static final int fast_out_slow_in = 17563665; // 0x10c0011
-    field public static final int l_resource_pad1 = 17563664; // 0x10c0010
-    field public static final int l_resource_pad2 = 17563663; // 0x10c000f
-    field public static final int l_resource_pad3 = 17563662; // 0x10c000e
-    field public static final int l_resource_pad4 = 17563661; // 0x10c000d
+    field public static final int fast_out_linear_in = 17563663; // 0x10c000f
+    field public static final int fast_out_slow_in = 17563661; // 0x10c000d
     field public static final int linear = 17563659; // 0x10c000b
-    field public static final int linear_out_slow_in = 17563666; // 0x10c0012
+    field public static final int linear_out_slow_in = 17563662; // 0x10c000e
     field public static final int overshoot = 17563656; // 0x10c0008
   }
 
@@ -1866,31 +1800,6 @@
     field public static final int emptyPhoneNumber = 17039366; // 0x1040006
     field public static final int httpErrorBadUrl = 17039367; // 0x1040007
     field public static final int httpErrorUnsupportedScheme = 17039368; // 0x1040008
-    field public static final int l_resource_pad1 = 17039408; // 0x1040030
-    field public static final int l_resource_pad10 = 17039399; // 0x1040027
-    field public static final int l_resource_pad11 = 17039398; // 0x1040026
-    field public static final int l_resource_pad12 = 17039397; // 0x1040025
-    field public static final int l_resource_pad13 = 17039396; // 0x1040024
-    field public static final int l_resource_pad14 = 17039395; // 0x1040023
-    field public static final int l_resource_pad15 = 17039394; // 0x1040022
-    field public static final int l_resource_pad16 = 17039393; // 0x1040021
-    field public static final int l_resource_pad17 = 17039392; // 0x1040020
-    field public static final int l_resource_pad18 = 17039391; // 0x104001f
-    field public static final int l_resource_pad19 = 17039390; // 0x104001e
-    field public static final int l_resource_pad2 = 17039407; // 0x104002f
-    field public static final int l_resource_pad20 = 17039389; // 0x104001d
-    field public static final int l_resource_pad21 = 17039388; // 0x104001c
-    field public static final int l_resource_pad22 = 17039387; // 0x104001b
-    field public static final int l_resource_pad23 = 17039386; // 0x104001a
-    field public static final int l_resource_pad24 = 17039385; // 0x1040019
-    field public static final int l_resource_pad25 = 17039384; // 0x1040018
-    field public static final int l_resource_pad3 = 17039406; // 0x104002e
-    field public static final int l_resource_pad4 = 17039405; // 0x104002d
-    field public static final int l_resource_pad5 = 17039404; // 0x104002c
-    field public static final int l_resource_pad6 = 17039403; // 0x104002b
-    field public static final int l_resource_pad7 = 17039402; // 0x104002a
-    field public static final int l_resource_pad8 = 17039401; // 0x1040029
-    field public static final int l_resource_pad9 = 17039400; // 0x1040028
     field public static final int no = 17039369; // 0x1040009
     field public static final int ok = 17039370; // 0x104000a
     field public static final int paste = 17039371; // 0x104000b
@@ -2003,52 +1912,60 @@
     field public static final int TextAppearance_Inverse = 16973887; // 0x103003f
     field public static final int TextAppearance_Large = 16973890; // 0x1030042
     field public static final int TextAppearance_Large_Inverse = 16973891; // 0x1030043
-    field public static final int TextAppearance_Material = 16974350; // 0x103020e
-    field public static final int TextAppearance_Material_Body1 = 16974552; // 0x10302d8
-    field public static final int TextAppearance_Material_Body2 = 16974551; // 0x10302d7
-    field public static final int TextAppearance_Material_Button = 16974555; // 0x10302db
-    field public static final int TextAppearance_Material_Caption = 16974553; // 0x10302d9
-    field public static final int TextAppearance_Material_DialogWindowTitle = 16974351; // 0x103020f
-    field public static final int TextAppearance_Material_Display1 = 16974547; // 0x10302d3
-    field public static final int TextAppearance_Material_Display2 = 16974546; // 0x10302d2
-    field public static final int TextAppearance_Material_Display3 = 16974545; // 0x10302d1
-    field public static final int TextAppearance_Material_Display4 = 16974544; // 0x10302d0
-    field public static final int TextAppearance_Material_Headline = 16974548; // 0x10302d4
-    field public static final int TextAppearance_Material_Inverse = 16974352; // 0x1030210
-    field public static final int TextAppearance_Material_Large = 16974353; // 0x1030211
-    field public static final int TextAppearance_Material_Large_Inverse = 16974354; // 0x1030212
-    field public static final int TextAppearance_Material_Medium = 16974355; // 0x1030213
-    field public static final int TextAppearance_Material_Medium_Inverse = 16974356; // 0x1030214
-    field public static final int TextAppearance_Material_Menu = 16974554; // 0x10302da
-    field public static final int TextAppearance_Material_SearchResult_Subtitle = 16974357; // 0x1030215
-    field public static final int TextAppearance_Material_SearchResult_Title = 16974358; // 0x1030216
-    field public static final int TextAppearance_Material_Small = 16974359; // 0x1030217
-    field public static final int TextAppearance_Material_Small_Inverse = 16974360; // 0x1030218
-    field public static final int TextAppearance_Material_Subhead = 16974550; // 0x10302d6
-    field public static final int TextAppearance_Material_Title = 16974549; // 0x10302d5
-    field public static final int TextAppearance_Material_Widget = 16974362; // 0x103021a
-    field public static final int TextAppearance_Material_Widget_ActionBar_Menu = 16974363; // 0x103021b
-    field public static final int TextAppearance_Material_Widget_ActionBar_Subtitle = 16974364; // 0x103021c
-    field public static final int TextAppearance_Material_Widget_ActionBar_Subtitle_Inverse = 16974365; // 0x103021d
-    field public static final int TextAppearance_Material_Widget_ActionBar_Title = 16974366; // 0x103021e
-    field public static final int TextAppearance_Material_Widget_ActionBar_Title_Inverse = 16974367; // 0x103021f
-    field public static final int TextAppearance_Material_Widget_ActionMode_Subtitle = 16974368; // 0x1030220
-    field public static final int TextAppearance_Material_Widget_ActionMode_Subtitle_Inverse = 16974369; // 0x1030221
-    field public static final int TextAppearance_Material_Widget_ActionMode_Title = 16974370; // 0x1030222
-    field public static final int TextAppearance_Material_Widget_ActionMode_Title_Inverse = 16974371; // 0x1030223
-    field public static final int TextAppearance_Material_Widget_Button = 16974372; // 0x1030224
-    field public static final int TextAppearance_Material_Widget_DropDownHint = 16974373; // 0x1030225
-    field public static final int TextAppearance_Material_Widget_DropDownItem = 16974374; // 0x1030226
-    field public static final int TextAppearance_Material_Widget_EditText = 16974375; // 0x1030227
-    field public static final int TextAppearance_Material_Widget_IconMenu_Item = 16974376; // 0x1030228
-    field public static final int TextAppearance_Material_Widget_PopupMenu = 16974377; // 0x1030229
-    field public static final int TextAppearance_Material_Widget_PopupMenu_Large = 16974378; // 0x103022a
-    field public static final int TextAppearance_Material_Widget_PopupMenu_Small = 16974379; // 0x103022b
-    field public static final int TextAppearance_Material_Widget_TabWidget = 16974380; // 0x103022c
-    field public static final int TextAppearance_Material_Widget_TextView = 16974381; // 0x103022d
-    field public static final int TextAppearance_Material_Widget_TextView_PopupMenu = 16974382; // 0x103022e
-    field public static final int TextAppearance_Material_Widget_TextView_SpinnerItem = 16974383; // 0x103022f
-    field public static final int TextAppearance_Material_WindowTitle = 16974361; // 0x1030219
+    field public static final int TextAppearance_Material = 16974317; // 0x10301ed
+    field public static final int TextAppearance_Material_Body1 = 16974320; // 0x10301f0
+    field public static final int TextAppearance_Material_Body2 = 16974319; // 0x10301ef
+    field public static final int TextAppearance_Material_Button = 16974318; // 0x10301ee
+    field public static final int TextAppearance_Material_Caption = 16974321; // 0x10301f1
+    field public static final int TextAppearance_Material_DialogWindowTitle = 16974322; // 0x10301f2
+    field public static final int TextAppearance_Material_Display1 = 16974326; // 0x10301f6
+    field public static final int TextAppearance_Material_Display2 = 16974325; // 0x10301f5
+    field public static final int TextAppearance_Material_Display3 = 16974324; // 0x10301f4
+    field public static final int TextAppearance_Material_Display4 = 16974323; // 0x10301f3
+    field public static final int TextAppearance_Material_Headline = 16974327; // 0x10301f7
+    field public static final int TextAppearance_Material_Inverse = 16974328; // 0x10301f8
+    field public static final int TextAppearance_Material_Large = 16974329; // 0x10301f9
+    field public static final int TextAppearance_Material_Large_Inverse = 16974330; // 0x10301fa
+    field public static final int TextAppearance_Material_Medium = 16974331; // 0x10301fb
+    field public static final int TextAppearance_Material_Medium_Inverse = 16974332; // 0x10301fc
+    field public static final int TextAppearance_Material_Menu = 16974333; // 0x10301fd
+    field public static final int TextAppearance_Material_Notification = 16974334; // 0x10301fe
+    field public static final int TextAppearance_Material_Notification_Emphasis = 16974335; // 0x10301ff
+    field public static final int TextAppearance_Material_Notification_Info = 16974336; // 0x1030200
+    field public static final int TextAppearance_Material_Notification_Line2 = 16974337; // 0x1030201
+    field public static final int TextAppearance_Material_Notification_Time = 16974338; // 0x1030202
+    field public static final int TextAppearance_Material_Notification_Title = 16974339; // 0x1030203
+    field public static final int TextAppearance_Material_SearchResult_Subtitle = 16974340; // 0x1030204
+    field public static final int TextAppearance_Material_SearchResult_Title = 16974341; // 0x1030205
+    field public static final int TextAppearance_Material_Small = 16974342; // 0x1030206
+    field public static final int TextAppearance_Material_Small_Inverse = 16974343; // 0x1030207
+    field public static final int TextAppearance_Material_Subhead = 16974344; // 0x1030208
+    field public static final int TextAppearance_Material_Title = 16974345; // 0x1030209
+    field public static final int TextAppearance_Material_Widget = 16974347; // 0x103020b
+    field public static final int TextAppearance_Material_Widget_ActionBar_Menu = 16974348; // 0x103020c
+    field public static final int TextAppearance_Material_Widget_ActionBar_Subtitle = 16974349; // 0x103020d
+    field public static final int TextAppearance_Material_Widget_ActionBar_Subtitle_Inverse = 16974350; // 0x103020e
+    field public static final int TextAppearance_Material_Widget_ActionBar_Title = 16974351; // 0x103020f
+    field public static final int TextAppearance_Material_Widget_ActionBar_Title_Inverse = 16974352; // 0x1030210
+    field public static final int TextAppearance_Material_Widget_ActionMode_Subtitle = 16974353; // 0x1030211
+    field public static final int TextAppearance_Material_Widget_ActionMode_Subtitle_Inverse = 16974354; // 0x1030212
+    field public static final int TextAppearance_Material_Widget_ActionMode_Title = 16974355; // 0x1030213
+    field public static final int TextAppearance_Material_Widget_ActionMode_Title_Inverse = 16974356; // 0x1030214
+    field public static final int TextAppearance_Material_Widget_Button = 16974357; // 0x1030215
+    field public static final int TextAppearance_Material_Widget_DropDownHint = 16974358; // 0x1030216
+    field public static final int TextAppearance_Material_Widget_DropDownItem = 16974359; // 0x1030217
+    field public static final int TextAppearance_Material_Widget_EditText = 16974360; // 0x1030218
+    field public static final int TextAppearance_Material_Widget_IconMenu_Item = 16974361; // 0x1030219
+    field public static final int TextAppearance_Material_Widget_PopupMenu = 16974362; // 0x103021a
+    field public static final int TextAppearance_Material_Widget_PopupMenu_Large = 16974363; // 0x103021b
+    field public static final int TextAppearance_Material_Widget_PopupMenu_Small = 16974364; // 0x103021c
+    field public static final int TextAppearance_Material_Widget_TabWidget = 16974365; // 0x103021d
+    field public static final int TextAppearance_Material_Widget_TextView = 16974366; // 0x103021e
+    field public static final int TextAppearance_Material_Widget_TextView_PopupMenu = 16974367; // 0x103021f
+    field public static final int TextAppearance_Material_Widget_TextView_SpinnerItem = 16974368; // 0x1030220
+    field public static final int TextAppearance_Material_Widget_Toolbar_Subtitle = 16974369; // 0x1030221
+    field public static final int TextAppearance_Material_Widget_Toolbar_Title = 16974370; // 0x1030222
+    field public static final int TextAppearance_Material_WindowTitle = 16974346; // 0x103020a
     field public static final int TextAppearance_Medium = 16973892; // 0x1030044
     field public static final int TextAppearance_Medium_Inverse = 16973893; // 0x1030045
     field public static final int TextAppearance_Small = 16973894; // 0x1030046
@@ -2056,13 +1973,6 @@
     field public static final int TextAppearance_StatusBar_EventContent = 16973927; // 0x1030067
     field public static final int TextAppearance_StatusBar_EventContent_Title = 16973928; // 0x1030068
     field public static final int TextAppearance_StatusBar_Icon = 16973926; // 0x1030066
-    field public static final int TextAppearance_StatusBar_Material = 16974559; // 0x10302df
-    field public static final int TextAppearance_StatusBar_Material_EventContent = 16974560; // 0x10302e0
-    field public static final int TextAppearance_StatusBar_Material_EventContent_Emphasis = 16974565; // 0x10302e5
-    field public static final int TextAppearance_StatusBar_Material_EventContent_Info = 16974563; // 0x10302e3
-    field public static final int TextAppearance_StatusBar_Material_EventContent_Line2 = 16974562; // 0x10302e2
-    field public static final int TextAppearance_StatusBar_Material_EventContent_Time = 16974564; // 0x10302e4
-    field public static final int TextAppearance_StatusBar_Material_EventContent_Title = 16974561; // 0x10302e1
     field public static final int TextAppearance_StatusBar_Title = 16973925; // 0x1030065
     field public static final int TextAppearance_SuggestionHighlight = 16974104; // 0x1030118
     field public static final int TextAppearance_Theme = 16973888; // 0x1030040
@@ -2081,12 +1991,12 @@
     field public static final int TextAppearance_Widget_TextView_SpinnerItem = 16973906; // 0x1030052
     field public static final int TextAppearance_WindowTitle = 16973907; // 0x1030053
     field public static final int Theme = 16973829; // 0x1030005
-    field public static final int ThemeOverlay = 16974416; // 0x1030250
-    field public static final int ThemeOverlay_Material = 16974417; // 0x1030251
-    field public static final int ThemeOverlay_Material_ActionBar = 16974418; // 0x1030252
-    field public static final int ThemeOverlay_Material_Dark = 16974420; // 0x1030254
-    field public static final int ThemeOverlay_Material_Dark_ActionBar = 16974421; // 0x1030255
-    field public static final int ThemeOverlay_Material_Light = 16974419; // 0x1030253
+    field public static final int ThemeOverlay = 16974407; // 0x1030247
+    field public static final int ThemeOverlay_Material = 16974408; // 0x1030248
+    field public static final int ThemeOverlay_Material_ActionBar = 16974409; // 0x1030249
+    field public static final int ThemeOverlay_Material_Dark = 16974411; // 0x103024b
+    field public static final int ThemeOverlay_Material_Dark_ActionBar = 16974412; // 0x103024c
+    field public static final int ThemeOverlay_Material_Light = 16974410; // 0x103024a
     field public static final int Theme_Black = 16973832; // 0x1030008
     field public static final int Theme_Black_NoTitleBar = 16973833; // 0x1030009
     field public static final int Theme_Black_NoTitleBar_Fullscreen = 16973834; // 0x103000a
@@ -2116,7 +2026,7 @@
     field public static final int Theme_DeviceDefault_NoActionBar_Overscan = 16974303; // 0x10301df
     field public static final int Theme_DeviceDefault_NoActionBar_TranslucentDecor = 16974307; // 0x10301e3
     field public static final int Theme_DeviceDefault_Panel = 16974138; // 0x103013a
-    field public static final int Theme_DeviceDefault_Settings = 16974384; // 0x1030230
+    field public static final int Theme_DeviceDefault_Settings = 16974371; // 0x1030223
     field public static final int Theme_DeviceDefault_Wallpaper = 16974140; // 0x103013c
     field public static final int Theme_DeviceDefault_Wallpaper_NoTitleBar = 16974141; // 0x103013d
     field public static final int Theme_Dialog = 16973835; // 0x103000b
@@ -2154,37 +2064,41 @@
     field public static final int Theme_Light_NoTitleBar_Fullscreen = 16973838; // 0x103000e
     field public static final int Theme_Light_Panel = 16973914; // 0x103005a
     field public static final int Theme_Light_WallpaperSettings = 16973922; // 0x1030062
-    field public static final int Theme_Material = 16974385; // 0x1030231
-    field public static final int Theme_Material_Dialog = 16974386; // 0x1030232
-    field public static final int Theme_Material_DialogWhenLarge = 16974390; // 0x1030236
-    field public static final int Theme_Material_DialogWhenLarge_NoActionBar = 16974391; // 0x1030237
-    field public static final int Theme_Material_Dialog_MinWidth = 16974387; // 0x1030233
-    field public static final int Theme_Material_Dialog_NoActionBar = 16974388; // 0x1030234
-    field public static final int Theme_Material_Dialog_NoActionBar_MinWidth = 16974389; // 0x1030235
-    field public static final int Theme_Material_InputMethod = 16974392; // 0x1030238
-    field public static final int Theme_Material_Light = 16974402; // 0x1030242
-    field public static final int Theme_Material_Light_DarkActionBar = 16974403; // 0x1030243
-    field public static final int Theme_Material_Light_Dialog = 16974404; // 0x1030244
-    field public static final int Theme_Material_Light_DialogWhenLarge = 16974408; // 0x1030248
-    field public static final int Theme_Material_Light_DialogWhenLarge_NoActionBar = 16974409; // 0x1030249
-    field public static final int Theme_Material_Light_Dialog_MinWidth = 16974405; // 0x1030245
-    field public static final int Theme_Material_Light_Dialog_NoActionBar = 16974406; // 0x1030246
-    field public static final int Theme_Material_Light_Dialog_NoActionBar_MinWidth = 16974407; // 0x1030247
-    field public static final int Theme_Material_Light_NoActionBar = 16974410; // 0x103024a
-    field public static final int Theme_Material_Light_NoActionBar_Fullscreen = 16974411; // 0x103024b
-    field public static final int Theme_Material_Light_NoActionBar_Overscan = 16974412; // 0x103024c
-    field public static final int Theme_Material_Light_NoActionBar_TranslucentDecor = 16974413; // 0x103024d
-    field public static final int Theme_Material_Light_Panel = 16974414; // 0x103024e
-    field public static final int Theme_Material_Light_Voice = 16974415; // 0x103024f
-    field public static final int Theme_Material_NoActionBar = 16974393; // 0x1030239
-    field public static final int Theme_Material_NoActionBar_Fullscreen = 16974394; // 0x103023a
-    field public static final int Theme_Material_NoActionBar_Overscan = 16974395; // 0x103023b
-    field public static final int Theme_Material_NoActionBar_TranslucentDecor = 16974396; // 0x103023c
-    field public static final int Theme_Material_Panel = 16974397; // 0x103023d
-    field public static final int Theme_Material_Settings = 16974398; // 0x103023e
-    field public static final int Theme_Material_Voice = 16974399; // 0x103023f
-    field public static final int Theme_Material_Wallpaper = 16974400; // 0x1030240
-    field public static final int Theme_Material_Wallpaper_NoTitleBar = 16974401; // 0x1030241
+    field public static final int Theme_Material = 16974372; // 0x1030224
+    field public static final int Theme_Material_Dialog = 16974373; // 0x1030225
+    field public static final int Theme_Material_DialogWhenLarge = 16974379; // 0x103022b
+    field public static final int Theme_Material_DialogWhenLarge_NoActionBar = 16974380; // 0x103022c
+    field public static final int Theme_Material_Dialog_Alert = 16974374; // 0x1030226
+    field public static final int Theme_Material_Dialog_MinWidth = 16974375; // 0x1030227
+    field public static final int Theme_Material_Dialog_NoActionBar = 16974376; // 0x1030228
+    field public static final int Theme_Material_Dialog_NoActionBar_MinWidth = 16974377; // 0x1030229
+    field public static final int Theme_Material_Dialog_Presentation = 16974378; // 0x103022a
+    field public static final int Theme_Material_InputMethod = 16974381; // 0x103022d
+    field public static final int Theme_Material_Light = 16974391; // 0x1030237
+    field public static final int Theme_Material_Light_DarkActionBar = 16974392; // 0x1030238
+    field public static final int Theme_Material_Light_Dialog = 16974393; // 0x1030239
+    field public static final int Theme_Material_Light_DialogWhenLarge = 16974399; // 0x103023f
+    field public static final int Theme_Material_Light_DialogWhenLarge_NoActionBar = 16974400; // 0x1030240
+    field public static final int Theme_Material_Light_Dialog_Alert = 16974394; // 0x103023a
+    field public static final int Theme_Material_Light_Dialog_MinWidth = 16974395; // 0x103023b
+    field public static final int Theme_Material_Light_Dialog_NoActionBar = 16974396; // 0x103023c
+    field public static final int Theme_Material_Light_Dialog_NoActionBar_MinWidth = 16974397; // 0x103023d
+    field public static final int Theme_Material_Light_Dialog_Presentation = 16974398; // 0x103023e
+    field public static final int Theme_Material_Light_NoActionBar = 16974401; // 0x1030241
+    field public static final int Theme_Material_Light_NoActionBar_Fullscreen = 16974402; // 0x1030242
+    field public static final int Theme_Material_Light_NoActionBar_Overscan = 16974403; // 0x1030243
+    field public static final int Theme_Material_Light_NoActionBar_TranslucentDecor = 16974404; // 0x1030244
+    field public static final int Theme_Material_Light_Panel = 16974405; // 0x1030245
+    field public static final int Theme_Material_Light_Voice = 16974406; // 0x1030246
+    field public static final int Theme_Material_NoActionBar = 16974382; // 0x103022e
+    field public static final int Theme_Material_NoActionBar_Fullscreen = 16974383; // 0x103022f
+    field public static final int Theme_Material_NoActionBar_Overscan = 16974384; // 0x1030230
+    field public static final int Theme_Material_NoActionBar_TranslucentDecor = 16974385; // 0x1030231
+    field public static final int Theme_Material_Panel = 16974386; // 0x1030232
+    field public static final int Theme_Material_Settings = 16974387; // 0x1030233
+    field public static final int Theme_Material_Voice = 16974388; // 0x1030234
+    field public static final int Theme_Material_Wallpaper = 16974389; // 0x1030235
+    field public static final int Theme_Material_Wallpaper_NoTitleBar = 16974390; // 0x1030236
     field public static final int Theme_NoDisplay = 16973909; // 0x1030055
     field public static final int Theme_NoTitleBar = 16973830; // 0x1030006
     field public static final int Theme_NoTitleBar_Fullscreen = 16973831; // 0x1030007
@@ -2246,7 +2160,7 @@
     field public static final int Widget_DeviceDefault_DropDownItem_Spinner = 16974178; // 0x1030162
     field public static final int Widget_DeviceDefault_EditText = 16974154; // 0x103014a
     field public static final int Widget_DeviceDefault_ExpandableListView = 16974155; // 0x103014b
-    field public static final int Widget_DeviceDefault_FastScroll = 16974346; // 0x103020a
+    field public static final int Widget_DeviceDefault_FastScroll = 16974313; // 0x10301e9
     field public static final int Widget_DeviceDefault_GridView = 16974156; // 0x103014c
     field public static final int Widget_DeviceDefault_HorizontalScrollView = 16974171; // 0x103015b
     field public static final int Widget_DeviceDefault_ImageButton = 16974157; // 0x103014d
@@ -2280,7 +2194,7 @@
     field public static final int Widget_DeviceDefault_Light_DropDownItem_Spinner = 16974233; // 0x1030199
     field public static final int Widget_DeviceDefault_Light_EditText = 16974206; // 0x103017e
     field public static final int Widget_DeviceDefault_Light_ExpandableListView = 16974207; // 0x103017f
-    field public static final int Widget_DeviceDefault_Light_FastScroll = 16974348; // 0x103020c
+    field public static final int Widget_DeviceDefault_Light_FastScroll = 16974315; // 0x10301eb
     field public static final int Widget_DeviceDefault_Light_GridView = 16974208; // 0x1030180
     field public static final int Widget_DeviceDefault_Light_HorizontalScrollView = 16974226; // 0x1030192
     field public static final int Widget_DeviceDefault_Light_ImageButton = 16974209; // 0x1030181
@@ -2304,7 +2218,7 @@
     field public static final int Widget_DeviceDefault_Light_ScrollView = 16974225; // 0x1030191
     field public static final int Widget_DeviceDefault_Light_SeekBar = 16974220; // 0x103018c
     field public static final int Widget_DeviceDefault_Light_Spinner = 16974227; // 0x1030193
-    field public static final int Widget_DeviceDefault_Light_StackView = 16974349; // 0x103020d
+    field public static final int Widget_DeviceDefault_Light_StackView = 16974316; // 0x10301ec
     field public static final int Widget_DeviceDefault_Light_Tab = 16974237; // 0x103019d
     field public static final int Widget_DeviceDefault_Light_TabWidget = 16974229; // 0x1030195
     field public static final int Widget_DeviceDefault_Light_TextView = 16974202; // 0x103017a
@@ -2328,7 +2242,7 @@
     field public static final int Widget_DeviceDefault_ScrollView = 16974170; // 0x103015a
     field public static final int Widget_DeviceDefault_SeekBar = 16974165; // 0x1030155
     field public static final int Widget_DeviceDefault_Spinner = 16974172; // 0x103015c
-    field public static final int Widget_DeviceDefault_StackView = 16974347; // 0x103020b
+    field public static final int Widget_DeviceDefault_StackView = 16974314; // 0x10301ea
     field public static final int Widget_DeviceDefault_Tab = 16974189; // 0x103016d
     field public static final int Widget_DeviceDefault_TabWidget = 16974174; // 0x103015e
     field public static final int Widget_DeviceDefault_TextView = 16974150; // 0x1030146
@@ -2339,7 +2253,7 @@
     field public static final int Widget_DropDownItem_Spinner = 16973868; // 0x103002c
     field public static final int Widget_EditText = 16973859; // 0x1030023
     field public static final int Widget_ExpandableListView = 16973860; // 0x1030024
-    field public static final int Widget_FastScroll = 16974337; // 0x1030201
+    field public static final int Widget_FastScroll = 16974309; // 0x10301e5
     field public static final int Widget_FragmentBreadCrumbs = 16973961; // 0x1030089
     field public static final int Widget_Gallery = 16973877; // 0x1030035
     field public static final int Widget_GridView = 16973874; // 0x1030032
@@ -2371,7 +2285,6 @@
     field public static final int Widget_Holo_DropDownItem_Spinner = 16973995; // 0x10300ab
     field public static final int Widget_Holo_EditText = 16973971; // 0x1030093
     field public static final int Widget_Holo_ExpandableListView = 16973972; // 0x1030094
-    field public static final int Widget_Holo_FastScroll = 16974341; // 0x1030205
     field public static final int Widget_Holo_GridView = 16973973; // 0x1030095
     field public static final int Widget_Holo_HorizontalScrollView = 16973988; // 0x10300a4
     field public static final int Widget_Holo_ImageButton = 16973974; // 0x1030096
@@ -2392,7 +2305,6 @@
     field public static final int Widget_Holo_Light_ActionMode_Inverse = 16974119; // 0x1030127
     field public static final int Widget_Holo_Light_AutoCompleteTextView = 16974011; // 0x10300bb
     field public static final int Widget_Holo_Light_Button = 16974006; // 0x10300b6
-    field public static final int Widget_Holo_Light_Button_Borderless = 16974343; // 0x1030207
     field public static final int Widget_Holo_Light_Button_Borderless_Small = 16974107; // 0x103011b
     field public static final int Widget_Holo_Light_Button_Inset = 16974008; // 0x10300b8
     field public static final int Widget_Holo_Light_Button_Small = 16974007; // 0x10300b7
@@ -2406,7 +2318,6 @@
     field public static final int Widget_Holo_Light_DropDownItem_Spinner = 16974041; // 0x10300d9
     field public static final int Widget_Holo_Light_EditText = 16974014; // 0x10300be
     field public static final int Widget_Holo_Light_ExpandableListView = 16974015; // 0x10300bf
-    field public static final int Widget_Holo_Light_FastScroll = 16974344; // 0x1030208
     field public static final int Widget_Holo_Light_GridView = 16974016; // 0x10300c0
     field public static final int Widget_Holo_Light_HorizontalScrollView = 16974034; // 0x10300d2
     field public static final int Widget_Holo_Light_ImageButton = 16974017; // 0x10300c1
@@ -2430,7 +2341,6 @@
     field public static final int Widget_Holo_Light_ScrollView = 16974033; // 0x10300d1
     field public static final int Widget_Holo_Light_SeekBar = 16974028; // 0x10300cc
     field public static final int Widget_Holo_Light_Spinner = 16974035; // 0x10300d3
-    field public static final int Widget_Holo_Light_StackView = 16974345; // 0x1030209
     field public static final int Widget_Holo_Light_Tab = 16974052; // 0x10300e4
     field public static final int Widget_Holo_Light_TabWidget = 16974037; // 0x10300d5
     field public static final int Widget_Holo_Light_TextView = 16974010; // 0x10300ba
@@ -2454,7 +2364,6 @@
     field public static final int Widget_Holo_ScrollView = 16973987; // 0x10300a3
     field public static final int Widget_Holo_SeekBar = 16973982; // 0x103009e
     field public static final int Widget_Holo_Spinner = 16973989; // 0x10300a5
-    field public static final int Widget_Holo_StackView = 16974342; // 0x1030206
     field public static final int Widget_Holo_Tab = 16974051; // 0x10300e3
     field public static final int Widget_Holo_TabWidget = 16973991; // 0x10300a7
     field public static final int Widget_Holo_TextView = 16973967; // 0x103008f
@@ -2469,132 +2378,137 @@
     field public static final int Widget_ListView_DropDown = 16973872; // 0x1030030
     field public static final int Widget_ListView_Menu = 16973873; // 0x1030031
     field public static final int Widget_ListView_White = 16973871; // 0x103002f
-    field public static final int Widget_Material = 16974422; // 0x1030256
-    field public static final int Widget_Material_ActionBar = 16974423; // 0x1030257
-    field public static final int Widget_Material_ActionBar_Solid = 16974424; // 0x1030258
-    field public static final int Widget_Material_ActionBar_TabBar = 16974425; // 0x1030259
-    field public static final int Widget_Material_ActionBar_TabText = 16974426; // 0x103025a
-    field public static final int Widget_Material_ActionBar_TabView = 16974427; // 0x103025b
-    field public static final int Widget_Material_ActionButton = 16974428; // 0x103025c
-    field public static final int Widget_Material_ActionButton_CloseMode = 16974429; // 0x103025d
-    field public static final int Widget_Material_ActionButton_Overflow = 16974430; // 0x103025e
-    field public static final int Widget_Material_ActionMode = 16974431; // 0x103025f
-    field public static final int Widget_Material_AutoCompleteTextView = 16974432; // 0x1030260
-    field public static final int Widget_Material_Button = 16974433; // 0x1030261
-    field public static final int Widget_Material_ButtonBar = 16974439; // 0x1030267
-    field public static final int Widget_Material_ButtonBar_AlertDialog = 16974440; // 0x1030268
-    field public static final int Widget_Material_Button_Borderless = 16974434; // 0x1030262
-    field public static final int Widget_Material_Button_Borderless_Colored = 16974556; // 0x10302dc
-    field public static final int Widget_Material_Button_Borderless_Small = 16974435; // 0x1030263
-    field public static final int Widget_Material_Button_Inset = 16974436; // 0x1030264
-    field public static final int Widget_Material_Button_Small = 16974437; // 0x1030265
-    field public static final int Widget_Material_Button_Toggle = 16974438; // 0x1030266
-    field public static final int Widget_Material_CalendarView = 16974441; // 0x1030269
-    field public static final int Widget_Material_CheckedTextView = 16974442; // 0x103026a
-    field public static final int Widget_Material_CompoundButton_CheckBox = 16974443; // 0x103026b
-    field public static final int Widget_Material_CompoundButton_RadioButton = 16974444; // 0x103026c
-    field public static final int Widget_Material_CompoundButton_Star = 16974445; // 0x103026d
-    field public static final int Widget_Material_DatePicker = 16974446; // 0x103026e
-    field public static final int Widget_Material_DropDownItem = 16974447; // 0x103026f
-    field public static final int Widget_Material_DropDownItem_Spinner = 16974448; // 0x1030270
-    field public static final int Widget_Material_EditText = 16974449; // 0x1030271
-    field public static final int Widget_Material_ExpandableListView = 16974450; // 0x1030272
-    field public static final int Widget_Material_FastScroll = 16974451; // 0x1030273
-    field public static final int Widget_Material_GridView = 16974452; // 0x1030274
-    field public static final int Widget_Material_HorizontalScrollView = 16974453; // 0x1030275
-    field public static final int Widget_Material_ImageButton = 16974454; // 0x1030276
-    field public static final int Widget_Material_Light = 16974483; // 0x1030293
-    field public static final int Widget_Material_Light_ActionBar = 16974484; // 0x1030294
-    field public static final int Widget_Material_Light_ActionBar_Solid = 16974485; // 0x1030295
-    field public static final int Widget_Material_Light_ActionBar_TabBar = 16974486; // 0x1030296
-    field public static final int Widget_Material_Light_ActionBar_TabText = 16974487; // 0x1030297
-    field public static final int Widget_Material_Light_ActionBar_TabView = 16974488; // 0x1030298
-    field public static final int Widget_Material_Light_ActionButton = 16974489; // 0x1030299
-    field public static final int Widget_Material_Light_ActionButton_CloseMode = 16974490; // 0x103029a
-    field public static final int Widget_Material_Light_ActionButton_Overflow = 16974491; // 0x103029b
-    field public static final int Widget_Material_Light_ActionMode = 16974492; // 0x103029c
-    field public static final int Widget_Material_Light_AutoCompleteTextView = 16974493; // 0x103029d
-    field public static final int Widget_Material_Light_Button = 16974494; // 0x103029e
-    field public static final int Widget_Material_Light_ButtonBar = 16974500; // 0x10302a4
-    field public static final int Widget_Material_Light_ButtonBar_AlertDialog = 16974501; // 0x10302a5
-    field public static final int Widget_Material_Light_Button_Borderless = 16974495; // 0x103029f
-    field public static final int Widget_Material_Light_Button_Borderless_Colored = 16974557; // 0x10302dd
-    field public static final int Widget_Material_Light_Button_Borderless_Small = 16974496; // 0x10302a0
-    field public static final int Widget_Material_Light_Button_Inset = 16974497; // 0x10302a1
-    field public static final int Widget_Material_Light_Button_Small = 16974498; // 0x10302a2
-    field public static final int Widget_Material_Light_Button_Toggle = 16974499; // 0x10302a3
-    field public static final int Widget_Material_Light_CalendarView = 16974502; // 0x10302a6
-    field public static final int Widget_Material_Light_CheckedTextView = 16974503; // 0x10302a7
-    field public static final int Widget_Material_Light_CompoundButton_CheckBox = 16974504; // 0x10302a8
-    field public static final int Widget_Material_Light_CompoundButton_RadioButton = 16974505; // 0x10302a9
-    field public static final int Widget_Material_Light_CompoundButton_Star = 16974506; // 0x10302aa
-    field public static final int Widget_Material_Light_DropDownItem = 16974507; // 0x10302ab
-    field public static final int Widget_Material_Light_DropDownItem_Spinner = 16974508; // 0x10302ac
-    field public static final int Widget_Material_Light_EditText = 16974509; // 0x10302ad
-    field public static final int Widget_Material_Light_ExpandableListView = 16974510; // 0x10302ae
-    field public static final int Widget_Material_Light_FastScroll = 16974511; // 0x10302af
-    field public static final int Widget_Material_Light_GridView = 16974512; // 0x10302b0
-    field public static final int Widget_Material_Light_HorizontalScrollView = 16974513; // 0x10302b1
-    field public static final int Widget_Material_Light_ImageButton = 16974514; // 0x10302b2
-    field public static final int Widget_Material_Light_ListPopupWindow = 16974515; // 0x10302b3
-    field public static final int Widget_Material_Light_ListView = 16974516; // 0x10302b4
-    field public static final int Widget_Material_Light_ListView_DropDown = 16974517; // 0x10302b5
-    field public static final int Widget_Material_Light_MediaRouteButton = 16974518; // 0x10302b6
-    field public static final int Widget_Material_Light_PopupMenu = 16974519; // 0x10302b7
-    field public static final int Widget_Material_Light_PopupMenu_Overflow = 16974520; // 0x10302b8
-    field public static final int Widget_Material_Light_PopupWindow = 16974521; // 0x10302b9
-    field public static final int Widget_Material_Light_ProgressBar = 16974522; // 0x10302ba
-    field public static final int Widget_Material_Light_ProgressBar_Horizontal = 16974523; // 0x10302bb
-    field public static final int Widget_Material_Light_ProgressBar_Inverse = 16974524; // 0x10302bc
-    field public static final int Widget_Material_Light_ProgressBar_Large = 16974525; // 0x10302bd
-    field public static final int Widget_Material_Light_ProgressBar_Large_Inverse = 16974526; // 0x10302be
-    field public static final int Widget_Material_Light_ProgressBar_Small = 16974527; // 0x10302bf
-    field public static final int Widget_Material_Light_ProgressBar_Small_Inverse = 16974528; // 0x10302c0
-    field public static final int Widget_Material_Light_ProgressBar_Small_Title = 16974529; // 0x10302c1
-    field public static final int Widget_Material_Light_RatingBar = 16974530; // 0x10302c2
-    field public static final int Widget_Material_Light_RatingBar_Indicator = 16974531; // 0x10302c3
-    field public static final int Widget_Material_Light_RatingBar_Small = 16974532; // 0x10302c4
-    field public static final int Widget_Material_Light_ScrollView = 16974533; // 0x10302c5
-    field public static final int Widget_Material_Light_SeekBar = 16974534; // 0x10302c6
-    field public static final int Widget_Material_Light_SegmentedButton = 16974535; // 0x10302c7
-    field public static final int Widget_Material_Light_Spinner = 16974537; // 0x10302c9
-    field public static final int Widget_Material_Light_Spinner_Form = 16974567; // 0x10302e7
-    field public static final int Widget_Material_Light_StackView = 16974536; // 0x10302c8
-    field public static final int Widget_Material_Light_Tab = 16974538; // 0x10302ca
-    field public static final int Widget_Material_Light_TabWidget = 16974539; // 0x10302cb
-    field public static final int Widget_Material_Light_TextView = 16974540; // 0x10302cc
-    field public static final int Widget_Material_Light_TextView_SpinnerItem = 16974541; // 0x10302cd
+    field public static final int Widget_Material = 16974413; // 0x103024d
+    field public static final int Widget_Material_ActionBar = 16974414; // 0x103024e
+    field public static final int Widget_Material_ActionBar_Solid = 16974415; // 0x103024f
+    field public static final int Widget_Material_ActionBar_TabBar = 16974416; // 0x1030250
+    field public static final int Widget_Material_ActionBar_TabText = 16974417; // 0x1030251
+    field public static final int Widget_Material_ActionBar_TabView = 16974418; // 0x1030252
+    field public static final int Widget_Material_ActionButton = 16974419; // 0x1030253
+    field public static final int Widget_Material_ActionButton_CloseMode = 16974420; // 0x1030254
+    field public static final int Widget_Material_ActionButton_Overflow = 16974421; // 0x1030255
+    field public static final int Widget_Material_ActionMode = 16974422; // 0x1030256
+    field public static final int Widget_Material_AutoCompleteTextView = 16974423; // 0x1030257
+    field public static final int Widget_Material_Button = 16974424; // 0x1030258
+    field public static final int Widget_Material_ButtonBar = 16974431; // 0x103025f
+    field public static final int Widget_Material_ButtonBar_AlertDialog = 16974432; // 0x1030260
+    field public static final int Widget_Material_Button_Borderless = 16974425; // 0x1030259
+    field public static final int Widget_Material_Button_Borderless_Colored = 16974426; // 0x103025a
+    field public static final int Widget_Material_Button_Borderless_Small = 16974427; // 0x103025b
+    field public static final int Widget_Material_Button_Inset = 16974428; // 0x103025c
+    field public static final int Widget_Material_Button_Small = 16974429; // 0x103025d
+    field public static final int Widget_Material_Button_Toggle = 16974430; // 0x103025e
+    field public static final int Widget_Material_CalendarView = 16974433; // 0x1030261
+    field public static final int Widget_Material_CheckedTextView = 16974434; // 0x1030262
+    field public static final int Widget_Material_CompoundButton_CheckBox = 16974435; // 0x1030263
+    field public static final int Widget_Material_CompoundButton_RadioButton = 16974436; // 0x1030264
+    field public static final int Widget_Material_CompoundButton_Star = 16974437; // 0x1030265
+    field public static final int Widget_Material_DatePicker = 16974438; // 0x1030266
+    field public static final int Widget_Material_DropDownItem = 16974439; // 0x1030267
+    field public static final int Widget_Material_DropDownItem_Spinner = 16974440; // 0x1030268
+    field public static final int Widget_Material_EditText = 16974441; // 0x1030269
+    field public static final int Widget_Material_ExpandableListView = 16974442; // 0x103026a
+    field public static final int Widget_Material_FastScroll = 16974443; // 0x103026b
+    field public static final int Widget_Material_GridView = 16974444; // 0x103026c
+    field public static final int Widget_Material_HorizontalScrollView = 16974445; // 0x103026d
+    field public static final int Widget_Material_ImageButton = 16974446; // 0x103026e
+    field public static final int Widget_Material_Light = 16974478; // 0x103028e
+    field public static final int Widget_Material_Light_ActionBar = 16974479; // 0x103028f
+    field public static final int Widget_Material_Light_ActionBar_Solid = 16974480; // 0x1030290
+    field public static final int Widget_Material_Light_ActionBar_TabBar = 16974481; // 0x1030291
+    field public static final int Widget_Material_Light_ActionBar_TabText = 16974482; // 0x1030292
+    field public static final int Widget_Material_Light_ActionBar_TabView = 16974483; // 0x1030293
+    field public static final int Widget_Material_Light_ActionButton = 16974484; // 0x1030294
+    field public static final int Widget_Material_Light_ActionButton_CloseMode = 16974485; // 0x1030295
+    field public static final int Widget_Material_Light_ActionButton_Overflow = 16974486; // 0x1030296
+    field public static final int Widget_Material_Light_ActionMode = 16974487; // 0x1030297
+    field public static final int Widget_Material_Light_AutoCompleteTextView = 16974488; // 0x1030298
+    field public static final int Widget_Material_Light_Button = 16974489; // 0x1030299
+    field public static final int Widget_Material_Light_ButtonBar = 16974496; // 0x10302a0
+    field public static final int Widget_Material_Light_ButtonBar_AlertDialog = 16974497; // 0x10302a1
+    field public static final int Widget_Material_Light_Button_Borderless = 16974490; // 0x103029a
+    field public static final int Widget_Material_Light_Button_Borderless_Colored = 16974491; // 0x103029b
+    field public static final int Widget_Material_Light_Button_Borderless_Small = 16974492; // 0x103029c
+    field public static final int Widget_Material_Light_Button_Inset = 16974493; // 0x103029d
+    field public static final int Widget_Material_Light_Button_Small = 16974494; // 0x103029e
+    field public static final int Widget_Material_Light_Button_Toggle = 16974495; // 0x103029f
+    field public static final int Widget_Material_Light_CalendarView = 16974498; // 0x10302a2
+    field public static final int Widget_Material_Light_CheckedTextView = 16974499; // 0x10302a3
+    field public static final int Widget_Material_Light_CompoundButton_CheckBox = 16974500; // 0x10302a4
+    field public static final int Widget_Material_Light_CompoundButton_RadioButton = 16974501; // 0x10302a5
+    field public static final int Widget_Material_Light_CompoundButton_Star = 16974502; // 0x10302a6
+    field public static final int Widget_Material_Light_DatePicker = 16974503; // 0x10302a7
+    field public static final int Widget_Material_Light_DropDownItem = 16974504; // 0x10302a8
+    field public static final int Widget_Material_Light_DropDownItem_Spinner = 16974505; // 0x10302a9
+    field public static final int Widget_Material_Light_EditText = 16974506; // 0x10302aa
+    field public static final int Widget_Material_Light_ExpandableListView = 16974507; // 0x10302ab
+    field public static final int Widget_Material_Light_FastScroll = 16974508; // 0x10302ac
+    field public static final int Widget_Material_Light_GridView = 16974509; // 0x10302ad
+    field public static final int Widget_Material_Light_HorizontalScrollView = 16974510; // 0x10302ae
+    field public static final int Widget_Material_Light_ImageButton = 16974511; // 0x10302af
+    field public static final int Widget_Material_Light_ListPopupWindow = 16974512; // 0x10302b0
+    field public static final int Widget_Material_Light_ListView = 16974513; // 0x10302b1
+    field public static final int Widget_Material_Light_ListView_DropDown = 16974514; // 0x10302b2
+    field public static final int Widget_Material_Light_MediaRouteButton = 16974515; // 0x10302b3
+    field public static final int Widget_Material_Light_PopupMenu = 16974516; // 0x10302b4
+    field public static final int Widget_Material_Light_PopupMenu_Overflow = 16974517; // 0x10302b5
+    field public static final int Widget_Material_Light_PopupWindow = 16974518; // 0x10302b6
+    field public static final int Widget_Material_Light_ProgressBar = 16974519; // 0x10302b7
+    field public static final int Widget_Material_Light_ProgressBar_Horizontal = 16974520; // 0x10302b8
+    field public static final int Widget_Material_Light_ProgressBar_Inverse = 16974521; // 0x10302b9
+    field public static final int Widget_Material_Light_ProgressBar_Large = 16974522; // 0x10302ba
+    field public static final int Widget_Material_Light_ProgressBar_Large_Inverse = 16974523; // 0x10302bb
+    field public static final int Widget_Material_Light_ProgressBar_Small = 16974524; // 0x10302bc
+    field public static final int Widget_Material_Light_ProgressBar_Small_Inverse = 16974525; // 0x10302bd
+    field public static final int Widget_Material_Light_ProgressBar_Small_Title = 16974526; // 0x10302be
+    field public static final int Widget_Material_Light_RatingBar = 16974527; // 0x10302bf
+    field public static final int Widget_Material_Light_RatingBar_Indicator = 16974528; // 0x10302c0
+    field public static final int Widget_Material_Light_RatingBar_Small = 16974529; // 0x10302c1
+    field public static final int Widget_Material_Light_ScrollView = 16974530; // 0x10302c2
+    field public static final int Widget_Material_Light_SearchView = 16974531; // 0x10302c3
+    field public static final int Widget_Material_Light_SeekBar = 16974532; // 0x10302c4
+    field public static final int Widget_Material_Light_SegmentedButton = 16974533; // 0x10302c5
+    field public static final int Widget_Material_Light_Spinner = 16974535; // 0x10302c7
+    field public static final int Widget_Material_Light_Spinner_Underlined = 16974536; // 0x10302c8
+    field public static final int Widget_Material_Light_StackView = 16974534; // 0x10302c6
+    field public static final int Widget_Material_Light_Tab = 16974537; // 0x10302c9
+    field public static final int Widget_Material_Light_TabWidget = 16974538; // 0x10302ca
+    field public static final int Widget_Material_Light_TextView = 16974539; // 0x10302cb
+    field public static final int Widget_Material_Light_TextView_SpinnerItem = 16974540; // 0x10302cc
+    field public static final int Widget_Material_Light_TimePicker = 16974541; // 0x10302cd
     field public static final int Widget_Material_Light_WebTextView = 16974542; // 0x10302ce
     field public static final int Widget_Material_Light_WebView = 16974543; // 0x10302cf
-    field public static final int Widget_Material_ListPopupWindow = 16974455; // 0x1030277
-    field public static final int Widget_Material_ListView = 16974456; // 0x1030278
-    field public static final int Widget_Material_ListView_DropDown = 16974457; // 0x1030279
-    field public static final int Widget_Material_MediaRouteButton = 16974458; // 0x103027a
-    field public static final int Widget_Material_PopupMenu = 16974459; // 0x103027b
-    field public static final int Widget_Material_PopupMenu_Overflow = 16974460; // 0x103027c
-    field public static final int Widget_Material_PopupWindow = 16974461; // 0x103027d
-    field public static final int Widget_Material_ProgressBar = 16974462; // 0x103027e
-    field public static final int Widget_Material_ProgressBar_Horizontal = 16974463; // 0x103027f
-    field public static final int Widget_Material_ProgressBar_Large = 16974464; // 0x1030280
-    field public static final int Widget_Material_ProgressBar_Small = 16974465; // 0x1030281
-    field public static final int Widget_Material_ProgressBar_Small_Title = 16974466; // 0x1030282
-    field public static final int Widget_Material_RatingBar = 16974467; // 0x1030283
-    field public static final int Widget_Material_RatingBar_Indicator = 16974468; // 0x1030284
-    field public static final int Widget_Material_RatingBar_Small = 16974469; // 0x1030285
-    field public static final int Widget_Material_ScrollView = 16974470; // 0x1030286
-    field public static final int Widget_Material_SeekBar = 16974471; // 0x1030287
-    field public static final int Widget_Material_SegmentedButton = 16974472; // 0x1030288
-    field public static final int Widget_Material_Spinner = 16974474; // 0x103028a
-    field public static final int Widget_Material_Spinner_Form = 16974566; // 0x10302e6
-    field public static final int Widget_Material_StackView = 16974473; // 0x1030289
-    field public static final int Widget_Material_Tab = 16974475; // 0x103028b
-    field public static final int Widget_Material_TabWidget = 16974476; // 0x103028c
-    field public static final int Widget_Material_TextView = 16974477; // 0x103028d
-    field public static final int Widget_Material_TextView_SpinnerItem = 16974478; // 0x103028e
-    field public static final int Widget_Material_Toolbar = 16974479; // 0x103028f
-    field public static final int Widget_Material_Toolbar_Button_Navigation = 16974480; // 0x1030290
-    field public static final int Widget_Material_WebTextView = 16974481; // 0x1030291
-    field public static final int Widget_Material_WebView = 16974482; // 0x1030292
+    field public static final int Widget_Material_ListPopupWindow = 16974447; // 0x103026f
+    field public static final int Widget_Material_ListView = 16974448; // 0x1030270
+    field public static final int Widget_Material_ListView_DropDown = 16974449; // 0x1030271
+    field public static final int Widget_Material_MediaRouteButton = 16974450; // 0x1030272
+    field public static final int Widget_Material_PopupMenu = 16974451; // 0x1030273
+    field public static final int Widget_Material_PopupMenu_Overflow = 16974452; // 0x1030274
+    field public static final int Widget_Material_PopupWindow = 16974453; // 0x1030275
+    field public static final int Widget_Material_ProgressBar = 16974454; // 0x1030276
+    field public static final int Widget_Material_ProgressBar_Horizontal = 16974455; // 0x1030277
+    field public static final int Widget_Material_ProgressBar_Large = 16974456; // 0x1030278
+    field public static final int Widget_Material_ProgressBar_Small = 16974457; // 0x1030279
+    field public static final int Widget_Material_ProgressBar_Small_Title = 16974458; // 0x103027a
+    field public static final int Widget_Material_RatingBar = 16974459; // 0x103027b
+    field public static final int Widget_Material_RatingBar_Indicator = 16974460; // 0x103027c
+    field public static final int Widget_Material_RatingBar_Small = 16974461; // 0x103027d
+    field public static final int Widget_Material_ScrollView = 16974462; // 0x103027e
+    field public static final int Widget_Material_SearchView = 16974463; // 0x103027f
+    field public static final int Widget_Material_SeekBar = 16974464; // 0x1030280
+    field public static final int Widget_Material_SegmentedButton = 16974465; // 0x1030281
+    field public static final int Widget_Material_Spinner = 16974467; // 0x1030283
+    field public static final int Widget_Material_Spinner_Underlined = 16974468; // 0x1030284
+    field public static final int Widget_Material_StackView = 16974466; // 0x1030282
+    field public static final int Widget_Material_Tab = 16974469; // 0x1030285
+    field public static final int Widget_Material_TabWidget = 16974470; // 0x1030286
+    field public static final int Widget_Material_TextView = 16974471; // 0x1030287
+    field public static final int Widget_Material_TextView_SpinnerItem = 16974472; // 0x1030288
+    field public static final int Widget_Material_TimePicker = 16974473; // 0x1030289
+    field public static final int Widget_Material_Toolbar = 16974474; // 0x103028a
+    field public static final int Widget_Material_Toolbar_Button_Navigation = 16974475; // 0x103028b
+    field public static final int Widget_Material_WebTextView = 16974476; // 0x103028c
+    field public static final int Widget_Material_WebView = 16974477; // 0x103028d
     field public static final int Widget_PopupMenu = 16973958; // 0x1030086
     field public static final int Widget_PopupWindow = 16973878; // 0x1030036
     field public static final int Widget_ProgressBar = 16973852; // 0x103001c
@@ -2609,42 +2523,14 @@
     field public static final int Widget_SeekBar = 16973856; // 0x1030020
     field public static final int Widget_Spinner = 16973864; // 0x1030028
     field public static final int Widget_Spinner_DropDown = 16973955; // 0x1030083
-    field public static final int Widget_StackView = 16974338; // 0x1030202
+    field public static final int Widget_StackView = 16974310; // 0x10301e6
     field public static final int Widget_TabWidget = 16973876; // 0x1030034
     field public static final int Widget_TextView = 16973858; // 0x1030022
     field public static final int Widget_TextView_PopupMenu = 16973865; // 0x1030029
     field public static final int Widget_TextView_SpinnerItem = 16973866; // 0x103002a
-    field public static final int Widget_Toolbar = 16974339; // 0x1030203
-    field public static final int Widget_Toolbar_Button_Navigation = 16974340; // 0x1030204
+    field public static final int Widget_Toolbar = 16974311; // 0x10301e7
+    field public static final int Widget_Toolbar_Button_Navigation = 16974312; // 0x10301e8
     field public static final int Widget_WebView = 16973875; // 0x1030033
-    field public static final int l_resource_pad1 = 16974336; // 0x1030200
-    field public static final int l_resource_pad10 = 16974327; // 0x10301f7
-    field public static final int l_resource_pad11 = 16974326; // 0x10301f6
-    field public static final int l_resource_pad12 = 16974325; // 0x10301f5
-    field public static final int l_resource_pad13 = 16974324; // 0x10301f4
-    field public static final int l_resource_pad14 = 16974323; // 0x10301f3
-    field public static final int l_resource_pad15 = 16974322; // 0x10301f2
-    field public static final int l_resource_pad16 = 16974321; // 0x10301f1
-    field public static final int l_resource_pad17 = 16974320; // 0x10301f0
-    field public static final int l_resource_pad18 = 16974319; // 0x10301ef
-    field public static final int l_resource_pad19 = 16974318; // 0x10301ee
-    field public static final int l_resource_pad2 = 16974335; // 0x10301ff
-    field public static final int l_resource_pad20 = 16974317; // 0x10301ed
-    field public static final int l_resource_pad21 = 16974316; // 0x10301ec
-    field public static final int l_resource_pad22 = 16974315; // 0x10301eb
-    field public static final int l_resource_pad23 = 16974314; // 0x10301ea
-    field public static final int l_resource_pad24 = 16974313; // 0x10301e9
-    field public static final int l_resource_pad25 = 16974312; // 0x10301e8
-    field public static final int l_resource_pad26 = 16974311; // 0x10301e7
-    field public static final int l_resource_pad27 = 16974310; // 0x10301e6
-    field public static final int l_resource_pad28 = 16974309; // 0x10301e5
-    field public static final int l_resource_pad3 = 16974334; // 0x10301fe
-    field public static final int l_resource_pad4 = 16974333; // 0x10301fd
-    field public static final int l_resource_pad5 = 16974332; // 0x10301fc
-    field public static final int l_resource_pad6 = 16974331; // 0x10301fb
-    field public static final int l_resource_pad7 = 16974330; // 0x10301fa
-    field public static final int l_resource_pad8 = 16974329; // 0x10301f9
-    field public static final int l_resource_pad9 = 16974328; // 0x10301f8
   }
 
   public static final class R.transition {
@@ -3415,7 +3301,6 @@
     method public int getTaskId();
     method public final java.lang.CharSequence getTitle();
     method public final int getTitleColor();
-    method public android.app.VoiceInteractor getVoiceInteractor();
     method public final int getVolumeControlStream();
     method public android.view.Window getWindow();
     method public android.view.WindowManager getWindowManager();
@@ -3427,14 +3312,13 @@
     method public boolean isFinishing();
     method public boolean isImmersive();
     method public boolean isTaskRoot();
-    method public boolean isVoiceInteraction();
     method public final deprecated android.database.Cursor managedQuery(android.net.Uri, java.lang.String[], java.lang.String, java.lang.String[], java.lang.String);
     method public boolean moveTaskToBack(boolean);
     method public boolean navigateUpTo(android.content.Intent);
     method public boolean navigateUpToFromChild(android.app.Activity, android.content.Intent);
     method public void onActionModeFinished(android.view.ActionMode);
     method public void onActionModeStarted(android.view.ActionMode);
-    method protected void onActivityReenter(int, android.content.Intent);
+    method public void onActivityReenter(int, android.content.Intent);
     method protected void onActivityResult(int, int, android.content.Intent);
     method public void onAttachFragment(android.app.Fragment);
     method public void onAttachedToWindow();
@@ -3445,7 +3329,7 @@
     method public boolean onContextItemSelected(android.view.MenuItem);
     method public void onContextMenuClosed(android.view.Menu);
     method protected void onCreate(android.os.Bundle);
-    method protected void onCreate(android.os.Bundle, android.os.PersistableBundle);
+    method public void onCreate(android.os.Bundle, android.os.PersistableBundle);
     method public void onCreateContextMenu(android.view.ContextMenu, android.view.View, android.view.ContextMenu.ContextMenuInfo);
     method public java.lang.CharSequence onCreateDescription();
     method protected deprecated android.app.Dialog onCreateDialog(int);
@@ -3477,7 +3361,7 @@
     method public void onPanelClosed(int, android.view.Menu);
     method protected void onPause();
     method protected void onPostCreate(android.os.Bundle);
-    method protected void onPostCreate(android.os.Bundle, android.os.PersistableBundle);
+    method public void onPostCreate(android.os.Bundle, android.os.PersistableBundle);
     method protected void onPostResume();
     method protected deprecated void onPrepareDialog(int, android.app.Dialog);
     method protected deprecated void onPrepareDialog(int, android.app.Dialog, android.os.Bundle);
@@ -3487,11 +3371,11 @@
     method public void onProvideAssistData(android.os.Bundle);
     method protected void onRestart();
     method protected void onRestoreInstanceState(android.os.Bundle);
-    method protected void onRestoreInstanceState(android.os.Bundle, android.os.PersistableBundle);
+    method public void onRestoreInstanceState(android.os.Bundle, android.os.PersistableBundle);
     method protected void onResume();
     method public deprecated java.lang.Object onRetainNonConfigurationInstance();
     method protected void onSaveInstanceState(android.os.Bundle);
-    method protected void onSaveInstanceState(android.os.Bundle, android.os.PersistableBundle);
+    method public void onSaveInstanceState(android.os.Bundle, android.os.PersistableBundle);
     method public boolean onSearchRequested();
     method protected void onStart();
     method protected void onStop();
@@ -3501,7 +3385,7 @@
     method public void onTrimMemory(int);
     method public void onUserInteraction();
     method protected void onUserLeaveHint();
-    method public void onVisibleBehindCancelled();
+    method public void onVisibleBehindCanceled();
     method public void onWindowAttributesChanged(android.view.WindowManager.LayoutParams);
     method public void onWindowFocusChanged(boolean);
     method public android.view.ActionMode onWindowStartingActionMode(android.view.ActionMode.Callback);
@@ -3511,6 +3395,7 @@
     method public void postponeEnterTransition();
     method public void recreate();
     method public void registerForContextMenu(android.view.View);
+    method public boolean releaseInstance();
     method public final deprecated void removeDialog(int);
     method public void reportFullyDrawn();
     method public boolean requestVisibleBehind(boolean);
@@ -3522,8 +3407,8 @@
     method public void setContentView(android.view.View);
     method public void setContentView(android.view.View, android.view.ViewGroup.LayoutParams);
     method public final void setDefaultKeyMode(int);
-    method public void setEnterSharedElementListener(android.app.SharedElementListener);
-    method public void setExitSharedElementListener(android.app.SharedElementListener);
+    method public void setEnterSharedElementCallback(android.app.SharedElementCallback);
+    method public void setExitSharedElementCallback(android.app.SharedElementCallback);
     method public final void setFeatureDrawable(int, android.graphics.drawable.Drawable);
     method public final void setFeatureDrawableAlpha(int, int);
     method public final void setFeatureDrawableResource(int, int);
@@ -3592,8 +3477,10 @@
   }
 
   public class ActivityManager {
+    method public int addAppTask(android.app.Activity, android.content.Intent, android.app.ActivityManager.TaskDescription, android.graphics.Bitmap);
     method public boolean clearApplicationUserData();
     method public void dumpPackageState(java.io.FileDescriptor, java.lang.String);
+    method public android.util.Size getAppTaskThumbnailSize();
     method public java.util.List<android.app.ActivityManager.AppTask> getAppTasks();
     method public android.content.pm.ConfigurationInfo getDeviceConfigurationInfo();
     method public int getLargeMemoryClass();
@@ -3627,6 +3514,9 @@
   public static class ActivityManager.AppTask {
     method public void finishAndRemoveTask();
     method public android.app.ActivityManager.RecentTaskInfo getTaskInfo();
+    method public void moveToFront();
+    method public void setExcludeFromRecents(boolean);
+    method public void startActivity(android.content.Context, android.content.Intent, android.os.Bundle);
   }
 
   public static class ActivityManager.MemoryInfo implements android.os.Parcelable {
@@ -3763,10 +3653,10 @@
 
   public class ActivityOptions {
     method public static android.app.ActivityOptions makeCustomAnimation(android.content.Context, int, int);
-    method public static android.app.ActivityOptions makeLaunchTaskBehindAnimation();
     method public static android.app.ActivityOptions makeScaleUpAnimation(android.view.View, int, int, int, int);
     method public static android.app.ActivityOptions makeSceneTransitionAnimation(android.app.Activity, android.view.View, java.lang.String);
     method public static android.app.ActivityOptions makeSceneTransitionAnimation(android.app.Activity, android.util.Pair<android.view.View, java.lang.String>...);
+    method public static android.app.ActivityOptions makeTaskLaunchBehind();
     method public static android.app.ActivityOptions makeThumbnailScaleUpAnimation(android.view.View, android.graphics.Bitmap, int, int);
     method public android.os.Bundle toBundle();
     method public void update(android.app.ActivityOptions);
@@ -3895,6 +3785,7 @@
     field public static final int MODE_IGNORED = 1; // 0x1
     field public static final java.lang.String OPSTR_COARSE_LOCATION = "android:coarse_location";
     field public static final java.lang.String OPSTR_FINE_LOCATION = "android:fine_location";
+    field public static final java.lang.String OPSTR_GET_USAGE_STATS = "android:get_usage_stats";
     field public static final java.lang.String OPSTR_MONITOR_HIGH_POWER_LOCATION = "android:monitor_location_high_power";
     field public static final java.lang.String OPSTR_MONITOR_LOCATION = "android:monitor_location";
   }
@@ -4223,14 +4114,22 @@
     method public void dump(java.lang.String, java.io.FileDescriptor, java.io.PrintWriter, java.lang.String[]);
     method public final boolean equals(java.lang.Object);
     method public final android.app.Activity getActivity();
+    method public boolean getAllowEnterTransitionOverlap();
+    method public boolean getAllowReturnTransitionOverlap();
     method public final android.os.Bundle getArguments();
     method public final android.app.FragmentManager getChildFragmentManager();
+    method public android.transition.Transition getEnterTransition();
+    method public android.transition.Transition getExitTransition();
     method public final android.app.FragmentManager getFragmentManager();
     method public final int getId();
     method public android.app.LoaderManager getLoaderManager();
     method public final android.app.Fragment getParentFragment();
+    method public android.transition.Transition getReenterTransition();
     method public final android.content.res.Resources getResources();
     method public final boolean getRetainInstance();
+    method public android.transition.Transition getReturnTransition();
+    method public android.transition.Transition getSharedElementEnterTransition();
+    method public android.transition.Transition getSharedElementReturnTransition();
     method public final java.lang.String getString(int);
     method public final java.lang.String getString(int, java.lang.Object...);
     method public final java.lang.String getTag();
@@ -4279,11 +4178,21 @@
     method public void onViewCreated(android.view.View, android.os.Bundle);
     method public void onViewStateRestored(android.os.Bundle);
     method public void registerForContextMenu(android.view.View);
+    method public void setAllowEnterTransitionOverlap(boolean);
+    method public void setAllowReturnTransitionOverlap(boolean);
     method public void setArguments(android.os.Bundle);
+    method public void setEnterSharedElementCallback(android.app.SharedElementCallback);
+    method public void setEnterTransition(android.transition.Transition);
+    method public void setExitSharedElementCallback(android.app.SharedElementCallback);
+    method public void setExitTransition(android.transition.Transition);
     method public void setHasOptionsMenu(boolean);
     method public void setInitialSavedState(android.app.Fragment.SavedState);
     method public void setMenuVisibility(boolean);
+    method public void setReenterTransition(android.transition.Transition);
     method public void setRetainInstance(boolean);
+    method public void setReturnTransition(android.transition.Transition);
+    method public void setSharedElementEnterTransition(android.transition.Transition);
+    method public void setSharedElementReturnTransition(android.transition.Transition);
     method public void setTargetFragment(android.app.Fragment, int);
     method public void setUserVisibleHint(boolean);
     method public void startActivity(android.content.Intent);
@@ -4364,6 +4273,7 @@
     method public abstract android.app.FragmentTransaction add(android.app.Fragment, java.lang.String);
     method public abstract android.app.FragmentTransaction add(int, android.app.Fragment);
     method public abstract android.app.FragmentTransaction add(int, android.app.Fragment, java.lang.String);
+    method public abstract android.app.FragmentTransaction addSharedElement(android.view.View, java.lang.String);
     method public abstract android.app.FragmentTransaction addToBackStack(java.lang.String);
     method public abstract android.app.FragmentTransaction attach(android.app.Fragment);
     method public abstract int commit();
@@ -4382,9 +4292,6 @@
     method public abstract android.app.FragmentTransaction setBreadCrumbTitle(java.lang.CharSequence);
     method public abstract android.app.FragmentTransaction setCustomAnimations(int, int);
     method public abstract android.app.FragmentTransaction setCustomAnimations(int, int, int, int);
-    method public abstract android.app.FragmentTransaction setCustomTransition(int, int);
-    method public abstract android.app.FragmentTransaction setSharedElement(android.view.View, java.lang.String);
-    method public abstract android.app.FragmentTransaction setSharedElements(android.util.Pair<android.view.View, java.lang.String>...);
     method public abstract android.app.FragmentTransaction setTransition(int);
     method public abstract android.app.FragmentTransaction setTransitionStyle(int);
     method public abstract android.app.FragmentTransaction show(android.app.Fragment);
@@ -4491,8 +4398,8 @@
   }
 
   public class KeyguardManager {
+    method public android.content.Intent createConfirmDeviceCredentialIntent(java.lang.CharSequence, java.lang.CharSequence);
     method public deprecated void exitKeyguardSecurely(android.app.KeyguardManager.OnKeyguardExitResult);
-    method public android.content.Intent getConfirmDeviceCredentialIntent(java.lang.CharSequence, java.lang.CharSequence);
     method public boolean inKeyguardRestrictedInputMode();
     method public boolean isKeyguardLocked();
     method public boolean isKeyguardSecure();
@@ -5147,14 +5054,14 @@
     field public static final int START_STICKY_COMPATIBILITY = 0; // 0x0
   }
 
-  public abstract class SharedElementListener {
-    ctor public SharedElementListener();
-    method public android.os.Parcelable captureSharedElementSnapshot(android.view.View, android.graphics.Matrix, android.graphics.RectF);
-    method public android.view.View createSnapshotView(android.content.Context, android.os.Parcelable);
-    method public void handleRejectedSharedElements(java.util.List<android.view.View>);
-    method public void remapSharedElements(java.util.List<java.lang.String>, java.util.Map<java.lang.String, android.view.View>);
-    method public void setSharedElementEnd(java.util.List<java.lang.String>, java.util.List<android.view.View>, java.util.List<android.view.View>);
-    method public void setSharedElementStart(java.util.List<java.lang.String>, java.util.List<android.view.View>, java.util.List<android.view.View>);
+  public abstract class SharedElementCallback {
+    ctor public SharedElementCallback();
+    method public android.os.Parcelable onCaptureSharedElementSnapshot(android.view.View, android.graphics.Matrix, android.graphics.RectF);
+    method public android.view.View onCreateSnapshotView(android.content.Context, android.os.Parcelable);
+    method public void onMapSharedElements(java.util.List<java.lang.String>, java.util.Map<java.lang.String, android.view.View>);
+    method public void onRejectSharedElements(java.util.List<android.view.View>);
+    method public void onSharedElementEnd(java.util.List<java.lang.String>, java.util.List<android.view.View>, java.util.List<android.view.View>);
+    method public void onSharedElementStart(java.util.List<java.lang.String>, java.util.List<android.view.View>, java.util.List<android.view.View>);
   }
 
   public deprecated class TabActivity extends android.app.ActivityGroup {
@@ -5246,41 +5153,6 @@
     field public static final int MODE_NIGHT_YES = 2; // 0x2
   }
 
-  public class VoiceInteractor {
-    method public boolean submitRequest(android.app.VoiceInteractor.Request);
-    method public boolean[] supportsCommands(java.lang.String[]);
-  }
-
-  public static class VoiceInteractor.AbortVoiceRequest extends android.app.VoiceInteractor.Request {
-    ctor public VoiceInteractor.AbortVoiceRequest(java.lang.CharSequence, android.os.Bundle);
-    method public void onAbortResult(android.os.Bundle);
-  }
-
-  public static class VoiceInteractor.CommandRequest extends android.app.VoiceInteractor.Request {
-    ctor public VoiceInteractor.CommandRequest(java.lang.String, android.os.Bundle);
-    method public void onCommandResult(android.os.Bundle);
-  }
-
-  public static class VoiceInteractor.CompleteVoiceRequest extends android.app.VoiceInteractor.Request {
-    ctor public VoiceInteractor.CompleteVoiceRequest(java.lang.CharSequence, android.os.Bundle);
-    method public void onCompleteResult(android.os.Bundle);
-  }
-
-  public static class VoiceInteractor.ConfirmationRequest extends android.app.VoiceInteractor.Request {
-    ctor public VoiceInteractor.ConfirmationRequest(java.lang.CharSequence, android.os.Bundle);
-    method public void onConfirmationResult(boolean, android.os.Bundle);
-  }
-
-  public static abstract class VoiceInteractor.Request {
-    ctor public VoiceInteractor.Request();
-    method public void cancel();
-    method public android.app.Activity getActivity();
-    method public android.content.Context getContext();
-    method public void onAttached(android.app.Activity);
-    method public void onCancel();
-    method public void onDetached();
-  }
-
   public final class WallpaperInfo implements android.os.Parcelable {
     ctor public WallpaperInfo(android.content.Context, android.content.pm.ResolveInfo) throws java.io.IOException, org.xmlpull.v1.XmlPullParserException;
     method public int describeContents();
@@ -5381,13 +5253,13 @@
     field public static final java.lang.String ACTION_DEVICE_ADMIN_DISABLED = "android.app.action.DEVICE_ADMIN_DISABLED";
     field public static final java.lang.String ACTION_DEVICE_ADMIN_DISABLE_REQUESTED = "android.app.action.DEVICE_ADMIN_DISABLE_REQUESTED";
     field public static final java.lang.String ACTION_DEVICE_ADMIN_ENABLED = "android.app.action.DEVICE_ADMIN_ENABLED";
-    field public static final java.lang.String ACTION_LOCK_TASK_ENTERING = "android.app.action.ACTION_LOCK_TASK_ENTERING";
-    field public static final java.lang.String ACTION_LOCK_TASK_EXITING = "android.app.action.ACTION_LOCK_TASK_EXITING";
+    field public static final java.lang.String ACTION_LOCK_TASK_ENTERING = "android.app.action.LOCK_TASK_ENTERING";
+    field public static final java.lang.String ACTION_LOCK_TASK_EXITING = "android.app.action.LOCK_TASK_EXITING";
     field public static final java.lang.String ACTION_PASSWORD_CHANGED = "android.app.action.ACTION_PASSWORD_CHANGED";
     field public static final java.lang.String ACTION_PASSWORD_EXPIRING = "android.app.action.ACTION_PASSWORD_EXPIRING";
     field public static final java.lang.String ACTION_PASSWORD_FAILED = "android.app.action.ACTION_PASSWORD_FAILED";
     field public static final java.lang.String ACTION_PASSWORD_SUCCEEDED = "android.app.action.ACTION_PASSWORD_SUCCEEDED";
-    field public static final java.lang.String ACTION_PROFILE_PROVISIONING_COMPLETE = "android.app.action.ACTION_PROFILE_PROVISIONING_COMPLETE";
+    field public static final java.lang.String ACTION_PROFILE_PROVISIONING_COMPLETE = "android.app.action.PROFILE_PROVISIONING_COMPLETE";
     field public static final java.lang.String DEVICE_ADMIN_META_DATA = "android.app.device_admin";
     field public static final java.lang.String EXTRA_DISABLE_WARNING = "android.app.extra.DISABLE_WARNING";
     field public static final java.lang.String EXTRA_LOCK_TASK_PACKAGE = "android.app.extra.LOCK_TASK_PACKAGE";
@@ -5409,12 +5281,12 @@
     method public java.lang.String[] getAccountTypesWithManagementDisabled();
     method public java.util.List<android.content.ComponentName> getActiveAdmins();
     method public android.os.Bundle getApplicationRestrictions(android.content.ComponentName, java.lang.String);
-    method public boolean getBlockUninstall(android.content.ComponentName, java.lang.String);
+    method public boolean getAutoTimeRequired();
     method public boolean getCameraDisabled(android.content.ComponentName);
     method public boolean getCrossProfileCallerIdDisabled(android.content.ComponentName);
     method public java.util.List<java.lang.String> getCrossProfileWidgetProviders(android.content.ComponentName);
     method public int getCurrentFailedPasswordAttempts();
-    method public java.util.List<byte[]> getInstalledCaCerts();
+    method public java.util.List<byte[]> getInstalledCaCerts(android.content.ComponentName);
     method public int getKeyguardDisabledFeatures(android.content.ComponentName);
     method public int getMaximumFailedPasswordsForWipe(android.content.ComponentName);
     method public long getMaximumTimeToLock(android.content.ComponentName);
@@ -5430,13 +5302,15 @@
     method public int getPasswordMinimumSymbols(android.content.ComponentName);
     method public int getPasswordMinimumUpperCase(android.content.ComponentName);
     method public int getPasswordQuality(android.content.ComponentName);
+    method public java.util.List<java.lang.String> getPermittedAccessibilityServices(android.content.ComponentName);
+    method public java.util.List<java.lang.String> getPermittedInputMethods(android.content.ComponentName);
     method public boolean getScreenCaptureDisabled(android.content.ComponentName);
     method public boolean getStorageEncryption(android.content.ComponentName);
     method public int getStorageEncryptionStatus();
-    method public java.util.List<java.lang.String> getTrustAgentFeaturesEnabled(android.content.ComponentName, android.content.ComponentName);
-    method public boolean hasCaCertInstalled(byte[]);
+    method public boolean hasCaCertInstalled(android.content.ComponentName, byte[]);
     method public boolean hasGrantedPolicy(android.content.ComponentName, int);
     method public boolean installCaCert(android.content.ComponentName, byte[]);
+    method public boolean installKeyPair(android.content.ComponentName, java.security.PrivateKey, java.security.cert.Certificate, java.lang.String);
     method public boolean isActivePasswordSufficient();
     method public boolean isAdminActive(android.content.ComponentName);
     method public boolean isApplicationHidden(android.content.ComponentName, java.lang.String);
@@ -5444,6 +5318,7 @@
     method public boolean isLockTaskPermitted(java.lang.String);
     method public boolean isMasterVolumeMuted(android.content.ComponentName);
     method public boolean isProfileOwnerApp(java.lang.String);
+    method public boolean isUninstallBlocked(android.content.ComponentName, java.lang.String);
     method public void lockNow();
     method public void removeActiveAdmin(android.content.ComponentName);
     method public boolean removeCrossProfileWidgetProvider(android.content.ComponentName, java.lang.String);
@@ -5452,8 +5327,7 @@
     method public void setAccountManagementDisabled(android.content.ComponentName, java.lang.String, boolean);
     method public boolean setApplicationHidden(android.content.ComponentName, java.lang.String, boolean);
     method public void setApplicationRestrictions(android.content.ComponentName, java.lang.String, android.os.Bundle);
-    method public int setApplicationsHidden(android.content.ComponentName, android.content.Intent, boolean);
-    method public void setBlockUninstall(android.content.ComponentName, java.lang.String, boolean);
+    method public void setAutoTimeRequired(android.content.ComponentName, boolean);
     method public void setCameraDisabled(android.content.ComponentName, boolean);
     method public void setCrossProfileCallerIdDisabled(android.content.ComponentName, boolean);
     method public void setGlobalSetting(android.content.ComponentName, java.lang.String, java.lang.String);
@@ -5472,6 +5346,8 @@
     method public void setPasswordMinimumSymbols(android.content.ComponentName, int);
     method public void setPasswordMinimumUpperCase(android.content.ComponentName, int);
     method public void setPasswordQuality(android.content.ComponentName, int);
+    method public boolean setPermittedAccessibilityServices(android.content.ComponentName, java.util.List<java.lang.String>);
+    method public boolean setPermittedInputMethods(android.content.ComponentName, java.util.List<java.lang.String>);
     method public void setProfileEnabled(android.content.ComponentName);
     method public void setProfileName(android.content.ComponentName, java.lang.String);
     method public void setRecommendedGlobalProxy(android.content.ComponentName, android.net.ProxyInfo);
@@ -5479,13 +5355,13 @@
     method public void setScreenCaptureDisabled(android.content.ComponentName, boolean);
     method public void setSecureSetting(android.content.ComponentName, java.lang.String, java.lang.String);
     method public int setStorageEncryption(android.content.ComponentName, boolean);
-    method public void setTrustAgentFeaturesEnabled(android.content.ComponentName, android.content.ComponentName, java.util.List<java.lang.String>);
+    method public void setUninstallBlocked(android.content.ComponentName, java.lang.String, boolean);
     method public boolean switchUser(android.content.ComponentName, android.os.UserHandle);
     method public void uninstallAllUserCaCerts(android.content.ComponentName);
     method public void uninstallCaCert(android.content.ComponentName, byte[]);
     method public void wipeData(int);
     field public static final java.lang.String ACTION_ADD_DEVICE_ADMIN = "android.app.action.ADD_DEVICE_ADMIN";
-    field public static final java.lang.String ACTION_PROVISION_MANAGED_PROFILE = "android.app.action.ACTION_PROVISION_MANAGED_PROFILE";
+    field public static final java.lang.String ACTION_PROVISION_MANAGED_PROFILE = "android.app.action.PROVISION_MANAGED_PROFILE";
     field public static final java.lang.String ACTION_SET_NEW_PASSWORD = "android.app.action.SET_NEW_PASSWORD";
     field public static final java.lang.String ACTION_START_ENCRYPTION = "android.app.action.START_ENCRYPTION";
     field public static final int ENCRYPTION_STATUS_ACTIVATING = 2; // 0x2
@@ -5494,25 +5370,25 @@
     field public static final int ENCRYPTION_STATUS_UNSUPPORTED = 0; // 0x0
     field public static final java.lang.String EXTRA_ADD_EXPLANATION = "android.app.extra.ADD_EXPLANATION";
     field public static final java.lang.String EXTRA_DEVICE_ADMIN = "android.app.extra.DEVICE_ADMIN";
-    field public static final java.lang.String EXTRA_PROVISIONING_DEFAULT_MANAGED_PROFILE_NAME = "android.app.extra.defaultManagedProfileName";
-    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_CHECKSUM = "android.app.extra.deviceAdminPackageChecksum";
-    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_COOKIE_HEADER = "android.app.extra.deviceAdminPackageDownloadCookieHeader";
-    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION = "android.app.extra.deviceAdminPackageDownloadLocation";
-    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME = "android.app.extra.deviceAdminPackageName";
-    field public static final java.lang.String EXTRA_PROVISIONING_EMAIL_ADDRESS = "android.app.extra.ManagedProfileEmailAddress";
-    field public static final java.lang.String EXTRA_PROVISIONING_LOCALE = "android.app.extra.locale";
-    field public static final java.lang.String EXTRA_PROVISIONING_LOCAL_TIME = "android.app.extra.localTime";
-    field public static final java.lang.String EXTRA_PROVISIONING_TIME_ZONE = "android.app.extra.timeZone";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_HIDDEN = "android.app.extra.wifiHidden";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PAC_URL = "android.app.extra.wifiPacUrl";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PASSWORD = "android.app.extra.wifiPassword";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_BYPASS = "android.app.extra.wifiProxyBypassHosts";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_HOST = "android.app.extra.wifiProxyHost";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_PORT = "android.app.extra.wifiProxyPort";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_SECURITY_TYPE = "android.app.extra.wifiSecurityType";
-    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_SSID = "android.app.extra.wifiSsid";
-    field public static int FLAG_MANAGED_CAN_ACCESS_PARENT;
-    field public static int FLAG_PARENT_CAN_ACCESS_MANAGED;
+    field public static final java.lang.String EXTRA_PROVISIONING_ADMIN_EXTRAS_BUNDLE = "android.app.extra.PROVISIONING_ADMIN_EXTRAS_BUNDLE";
+    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_CHECKSUM = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_CHECKSUM";
+    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_COOKIE_HEADER = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_COOKIE_HEADER";
+    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION";
+    field public static final java.lang.String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME";
+    field public static final java.lang.String EXTRA_PROVISIONING_EMAIL_ADDRESS = "android.app.extra.PROVISIONING_EMAIL_ADDRESS";
+    field public static final java.lang.String EXTRA_PROVISIONING_LOCALE = "android.app.extra.PROVISIONING_LOCALE";
+    field public static final java.lang.String EXTRA_PROVISIONING_LOCAL_TIME = "android.app.extra.PROVISIONING_LOCAL_TIME";
+    field public static final java.lang.String EXTRA_PROVISIONING_TIME_ZONE = "android.app.extra.PROVISIONING_TIME_ZONE";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_HIDDEN = "android.app.extra.PROVISIONING_WIFI_HIDDEN";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PAC_URL = "android.app.extra.PROVISIONING_WIFI_PAC_URL";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PASSWORD = "android.app.extra.PROVISIONING_WIFI_PASSWORD";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_BYPASS = "android.app.extra.PROVISIONING_WIFI_PROXY_BYPASS";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_HOST = "android.app.extra.PROVISIONING_WIFI_PROXY_HOST";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_PROXY_PORT = "android.app.extra.PROVISIONING_WIFI_PROXY_PORT";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_SECURITY_TYPE = "android.app.extra.PROVISIONING_WIFI_SECURITY_TYPE";
+    field public static final java.lang.String EXTRA_PROVISIONING_WIFI_SSID = "android.app.extra.PROVISIONING_WIFI_SSID";
+    field public static final int FLAG_MANAGED_CAN_ACCESS_PARENT = 2; // 0x2
+    field public static final int FLAG_PARENT_CAN_ACCESS_MANAGED = 1; // 0x1
     field public static final int KEYGUARD_DISABLE_FEATURES_ALL = 2147483647; // 0x7fffffff
     field public static final int KEYGUARD_DISABLE_FEATURES_NONE = 0; // 0x0
     field public static final int KEYGUARD_DISABLE_FINGERPRINT = 32; // 0x20
@@ -5521,6 +5397,7 @@
     field public static final int KEYGUARD_DISABLE_TRUST_AGENTS = 16; // 0x10
     field public static final int KEYGUARD_DISABLE_UNREDACTED_NOTIFICATIONS = 8; // 0x8
     field public static final int KEYGUARD_DISABLE_WIDGETS_ALL = 1; // 0x1
+    field public static final java.lang.String MIME_TYPE_PROVISIONING_NFC = "application/com.android.managedprovisioning";
     field public static final int PASSWORD_QUALITY_ALPHABETIC = 262144; // 0x40000
     field public static final int PASSWORD_QUALITY_ALPHANUMERIC = 327680; // 0x50000
     field public static final int PASSWORD_QUALITY_BIOMETRIC_WEAK = 32768; // 0x8000
@@ -5529,7 +5406,6 @@
     field public static final int PASSWORD_QUALITY_NUMERIC_COMPLEX = 196608; // 0x30000
     field public static final int PASSWORD_QUALITY_SOMETHING = 65536; // 0x10000
     field public static final int PASSWORD_QUALITY_UNSPECIFIED = 0; // 0x0
-    field public static final java.lang.String PROVISIONING_NFC_MIME_TYPE = "application/com.android.managedprovisioning";
     field public static final int RESET_PASSWORD_REQUIRE_ENTRY = 1; // 0x1
     field public static final int WIPE_EXTERNAL_STORAGE = 1; // 0x1
   }
@@ -5630,19 +5506,21 @@
     method public long getIntervalMillis();
     method public long getMaxExecutionDelayMillis();
     method public long getMinLatencyMillis();
-    method public int getNetworkCapabilities();
+    method public int getNetworkType();
     method public android.content.ComponentName getService();
     method public boolean isPeriodic();
     method public boolean isPersisted();
     method public boolean isRequireCharging();
     method public boolean isRequireDeviceIdle();
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final int BACKOFF_POLICY_EXPONENTIAL = 1; // 0x1
+    field public static final int BACKOFF_POLICY_LINEAR = 0; // 0x0
     field public static final android.os.Parcelable.Creator CREATOR;
-  }
-
-  public static abstract interface JobInfo.BackoffPolicy {
-    field public static final int EXPONENTIAL = 1; // 0x1
-    field public static final int LINEAR = 0; // 0x0
+    field public static final long DEFAULT_INITIAL_BACKOFF_MILLIS = 30000L; // 0x7530L
+    field public static final long MAX_BACKOFF_DELAY_MILLIS = 18000000L; // 0x112a880L
+    field public static final int NETWORK_TYPE_ANY = 1; // 0x1
+    field public static final int NETWORK_TYPE_NONE = 0; // 0x0
+    field public static final int NETWORK_TYPE_UNMETERED = 2; // 0x2
   }
 
   public static final class JobInfo.Builder {
@@ -5650,25 +5528,20 @@
     method public android.app.job.JobInfo build();
     method public android.app.job.JobInfo.Builder setBackoffCriteria(long, int);
     method public android.app.job.JobInfo.Builder setExtras(android.os.PersistableBundle);
-    method public android.app.job.JobInfo.Builder setIsPersisted(boolean);
     method public android.app.job.JobInfo.Builder setMinimumLatency(long);
     method public android.app.job.JobInfo.Builder setOverrideDeadline(long);
     method public android.app.job.JobInfo.Builder setPeriodic(long);
-    method public android.app.job.JobInfo.Builder setRequiredNetworkCapabilities(int);
+    method public android.app.job.JobInfo.Builder setPersisted(boolean);
+    method public android.app.job.JobInfo.Builder setRequiredNetworkType(int);
     method public android.app.job.JobInfo.Builder setRequiresCharging(boolean);
     method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean);
   }
 
-  public static abstract interface JobInfo.NetworkType {
-    field public static final int ANY = 1; // 0x1
-    field public static final int NONE = 0; // 0x0
-    field public static final int UNMETERED = 2; // 0x2
-  }
-
   public class JobParameters implements android.os.Parcelable {
     method public int describeContents();
     method public android.os.PersistableBundle getExtras();
     method public int getJobId();
+    method public boolean isOverrideDeadlineExpired();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
@@ -5696,6 +5569,19 @@
 
 package android.app.usage {
 
+  public final class ConfigurationStats implements android.os.Parcelable {
+    ctor public ConfigurationStats(android.app.usage.ConfigurationStats);
+    method public int describeContents();
+    method public int getActivationCount();
+    method public android.content.res.Configuration getConfiguration();
+    method public long getFirstTimeStamp();
+    method public long getLastTimeActive();
+    method public long getLastTimeStamp();
+    method public long getTotalTimeActive();
+    method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
+  }
+
   public final class UsageEvents implements android.os.Parcelable {
     method public int describeContents();
     method public boolean getNextEvent(android.app.usage.UsageEvents.Event);
@@ -5707,9 +5593,12 @@
 
   public static final class UsageEvents.Event {
     ctor public UsageEvents.Event();
-    method public android.content.ComponentName getComponent();
+    method public java.lang.String getClassName();
+    method public android.content.res.Configuration getConfiguration();
     method public int getEventType();
+    method public java.lang.String getPackageName();
     method public long getTimeStamp();
+    field public static final int CONFIGURATION_CHANGE = 5; // 0x5
     field public static final int MOVE_TO_BACKGROUND = 2; // 0x2
     field public static final int MOVE_TO_FOREGROUND = 1; // 0x1
     field public static final int NONE = 0; // 0x0
@@ -5729,7 +5618,8 @@
   }
 
   public final class UsageStatsManager {
-    method public android.util.ArrayMap<java.lang.String, android.app.usage.UsageStats> queryAndAggregateUsageStats(long, long);
+    method public java.util.Map<java.lang.String, android.app.usage.UsageStats> queryAndAggregateUsageStats(long, long);
+    method public java.util.List<android.app.usage.ConfigurationStats> queryConfigurations(int, long, long);
     method public android.app.usage.UsageEvents queryEvents(long, long);
     method public java.util.List<android.app.usage.UsageStats> queryUsageStats(int, long, long);
     field public static final int INTERVAL_BEST = 4; // 0x4
@@ -5848,7 +5738,7 @@
     field public static final int RESIZE_VERTICAL = 2; // 0x2
     field public static final int WIDGET_CATEGORY_HOME_SCREEN = 1; // 0x1
     field public static final int WIDGET_CATEGORY_KEYGUARD = 2; // 0x2
-    field public static final int WIDGET_CATEGORY_RECENTS = 4; // 0x4
+    field public static final int WIDGET_CATEGORY_SEARCHBOX = 4; // 0x4
     field public int autoAdvanceViewId;
     field public android.content.ComponentName configure;
     field public int icon;
@@ -6319,7 +6209,6 @@
     method public deprecated void abortReliableWrite(android.bluetooth.BluetoothDevice);
     method public boolean beginReliableWrite();
     method public void close();
-    method public boolean configureMTU(int);
     method public boolean connect();
     method public void disconnect();
     method public boolean discoverServices();
@@ -6333,14 +6222,15 @@
     method public boolean readCharacteristic(android.bluetooth.BluetoothGattCharacteristic);
     method public boolean readDescriptor(android.bluetooth.BluetoothGattDescriptor);
     method public boolean readRemoteRssi();
-    method public boolean requestConnectionParameterUpdate(int);
+    method public boolean requestConnectionPriority(int);
+    method public boolean requestMtu(int);
     method public boolean setCharacteristicNotification(android.bluetooth.BluetoothGattCharacteristic, boolean);
     method public boolean writeCharacteristic(android.bluetooth.BluetoothGattCharacteristic);
     method public boolean writeDescriptor(android.bluetooth.BluetoothGattDescriptor);
-    field public static final int GATT_CONNECTION_BALANCED = 0; // 0x0
+    field public static final int CONNECTION_PRIORITY_BALANCED = 0; // 0x0
+    field public static final int CONNECTION_PRIORITY_HIGH = 1; // 0x1
+    field public static final int CONNECTION_PRIORITY_LOW_POWER = 2; // 0x2
     field public static final int GATT_CONNECTION_CONGESTED = 143; // 0x8f
-    field public static final int GATT_CONNECTION_HIGH_PRIORITY = 1; // 0x1
-    field public static final int GATT_CONNECTION_LOW_POWER = 2; // 0x2
     field public static final int GATT_FAILURE = 257; // 0x101
     field public static final int GATT_INSUFFICIENT_AUTHENTICATION = 5; // 0x5
     field public static final int GATT_INSUFFICIENT_ENCRYPTION = 15; // 0xf
@@ -6357,11 +6247,10 @@
     method public void onCharacteristicChanged(android.bluetooth.BluetoothGatt, android.bluetooth.BluetoothGattCharacteristic);
     method public void onCharacteristicRead(android.bluetooth.BluetoothGatt, android.bluetooth.BluetoothGattCharacteristic, int);
     method public void onCharacteristicWrite(android.bluetooth.BluetoothGatt, android.bluetooth.BluetoothGattCharacteristic, int);
-    method public void onConfigureMTU(android.bluetooth.BluetoothGatt, int, int);
-    method public void onConnectionCongested(android.bluetooth.BluetoothGatt, boolean);
     method public void onConnectionStateChange(android.bluetooth.BluetoothGatt, int, int);
     method public void onDescriptorRead(android.bluetooth.BluetoothGatt, android.bluetooth.BluetoothGattDescriptor, int);
     method public void onDescriptorWrite(android.bluetooth.BluetoothGatt, android.bluetooth.BluetoothGattDescriptor, int);
+    method public void onMtuChanged(android.bluetooth.BluetoothGatt, int, int);
     method public void onReadRemoteRssi(android.bluetooth.BluetoothGatt, int, int);
     method public void onReliableWriteCompleted(android.bluetooth.BluetoothGatt, int);
     method public void onServicesDiscovered(android.bluetooth.BluetoothGatt, int);
@@ -6457,7 +6346,6 @@
     ctor public BluetoothGattServerCallback();
     method public void onCharacteristicReadRequest(android.bluetooth.BluetoothDevice, int, int, android.bluetooth.BluetoothGattCharacteristic);
     method public void onCharacteristicWriteRequest(android.bluetooth.BluetoothDevice, int, android.bluetooth.BluetoothGattCharacteristic, boolean, boolean, int, byte[]);
-    method public void onConnectionCongested(android.bluetooth.BluetoothDevice, boolean);
     method public void onConnectionStateChange(android.bluetooth.BluetoothDevice, int, int);
     method public void onDescriptorReadRequest(android.bluetooth.BluetoothDevice, int, int, android.bluetooth.BluetoothGattDescriptor);
     method public void onDescriptorWriteRequest(android.bluetooth.BluetoothDevice, int, android.bluetooth.BluetoothGattDescriptor, boolean, boolean, int, byte[]);
@@ -6614,6 +6502,7 @@
     method public java.util.Map<android.os.ParcelUuid, byte[]> getServiceData();
     method public java.util.List<android.os.ParcelUuid> getServiceUuids();
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public static final class AdvertiseData.Builder {
@@ -6628,10 +6517,10 @@
 
   public final class AdvertiseSettings implements android.os.Parcelable {
     method public int describeContents();
-    method public boolean getIsConnectable();
     method public int getMode();
     method public int getTimeout();
     method public int getTxPowerLevel();
+    method public boolean isConnectable();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final int ADVERTISE_MODE_BALANCED = 1; // 0x1
     field public static final int ADVERTISE_MODE_LOW_LATENCY = 2; // 0x2
@@ -6640,13 +6529,14 @@
     field public static final int ADVERTISE_TX_POWER_LOW = 1; // 0x1
     field public static final int ADVERTISE_TX_POWER_MEDIUM = 2; // 0x2
     field public static final int ADVERTISE_TX_POWER_ULTRA_LOW = 0; // 0x0
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public static final class AdvertiseSettings.Builder {
     ctor public AdvertiseSettings.Builder();
     method public android.bluetooth.le.AdvertiseSettings build();
     method public android.bluetooth.le.AdvertiseSettings.Builder setAdvertiseMode(int);
-    method public android.bluetooth.le.AdvertiseSettings.Builder setIsConnectable(boolean);
+    method public android.bluetooth.le.AdvertiseSettings.Builder setConnectable(boolean);
     method public android.bluetooth.le.AdvertiseSettings.Builder setTimeout(int);
     method public android.bluetooth.le.AdvertiseSettings.Builder setTxPowerLevel(int);
   }
@@ -6689,6 +6579,7 @@
     method public android.os.ParcelUuid getServiceUuidMask();
     method public boolean matches(android.bluetooth.le.ScanResult);
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public static final class ScanFilter.Builder {
@@ -6724,6 +6615,7 @@
     method public android.bluetooth.le.ScanRecord getScanRecord();
     method public long getTimestampNanos();
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public final class ScanSettings implements android.os.Parcelable {
@@ -6734,19 +6626,16 @@
     method public int getScanResultType();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final int CALLBACK_TYPE_ALL_MATCHES = 1; // 0x1
-    field public static final int CALLBACK_TYPE_FIRST_MATCH = 2; // 0x2
-    field public static final int CALLBACK_TYPE_MATCH_LOST = 4; // 0x4
+    field public static final android.os.Parcelable.Creator CREATOR;
     field public static final int SCAN_MODE_BALANCED = 1; // 0x1
     field public static final int SCAN_MODE_LOW_LATENCY = 2; // 0x2
     field public static final int SCAN_MODE_LOW_POWER = 0; // 0x0
-    field public static final int SCAN_RESULT_TYPE_FULL = 0; // 0x0
   }
 
   public static final class ScanSettings.Builder {
     ctor public ScanSettings.Builder();
     method public android.bluetooth.le.ScanSettings build();
-    method public android.bluetooth.le.ScanSettings.Builder setCallbackType(int);
-    method public android.bluetooth.le.ScanSettings.Builder setReportDelayMillis(long);
+    method public android.bluetooth.le.ScanSettings.Builder setReportDelay(long);
     method public android.bluetooth.le.ScanSettings.Builder setScanMode(int);
   }
 
@@ -6754,12 +6643,6 @@
 
 package android.content {
 
-  public abstract class AbstractRestrictionsProvider extends android.content.BroadcastReceiver {
-    ctor public AbstractRestrictionsProvider();
-    method public void onReceive(android.content.Context, android.content.Intent);
-    method public abstract void requestPermission(android.content.Context, java.lang.String, java.lang.String, java.lang.String, android.os.PersistableBundle);
-  }
-
   public abstract class AbstractThreadedSyncAdapter {
     ctor public AbstractThreadedSyncAdapter(android.content.Context, boolean);
     ctor public AbstractThreadedSyncAdapter(android.content.Context, boolean, boolean);
@@ -7135,6 +7018,7 @@
     field public static final java.lang.String ANY_CURSOR_ITEM_TYPE = "vnd.android.cursor.item/*";
     field public static final java.lang.String CURSOR_DIR_BASE_TYPE = "vnd.android.cursor.dir";
     field public static final java.lang.String CURSOR_ITEM_BASE_TYPE = "vnd.android.cursor.item";
+    field public static final java.lang.String EXTRA_SIZE = "android.content.extra.SIZE";
     field public static final java.lang.String SCHEME_ANDROID_RESOURCE = "android.resource";
     field public static final java.lang.String SCHEME_CONTENT = "content";
     field public static final java.lang.String SCHEME_FILE = "file";
@@ -7272,8 +7156,8 @@
     method public void registerComponentCallbacks(android.content.ComponentCallbacks);
     method public abstract android.content.Intent registerReceiver(android.content.BroadcastReceiver, android.content.IntentFilter);
     method public abstract android.content.Intent registerReceiver(android.content.BroadcastReceiver, android.content.IntentFilter, java.lang.String, android.os.Handler);
-    method public abstract void removeStickyBroadcast(android.content.Intent);
-    method public abstract void removeStickyBroadcastAsUser(android.content.Intent, android.os.UserHandle);
+    method public abstract deprecated void removeStickyBroadcast(android.content.Intent);
+    method public abstract deprecated void removeStickyBroadcastAsUser(android.content.Intent, android.os.UserHandle);
     method public abstract void revokeUriPermission(android.net.Uri, int);
     method public abstract void sendBroadcast(android.content.Intent);
     method public abstract void sendBroadcast(android.content.Intent, java.lang.String);
@@ -7282,10 +7166,10 @@
     method public abstract void sendOrderedBroadcast(android.content.Intent, java.lang.String);
     method public abstract void sendOrderedBroadcast(android.content.Intent, java.lang.String, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
     method public abstract void sendOrderedBroadcastAsUser(android.content.Intent, android.os.UserHandle, java.lang.String, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
-    method public abstract void sendStickyBroadcast(android.content.Intent);
-    method public abstract void sendStickyBroadcastAsUser(android.content.Intent, android.os.UserHandle);
-    method public abstract void sendStickyOrderedBroadcast(android.content.Intent, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
-    method public abstract void sendStickyOrderedBroadcastAsUser(android.content.Intent, android.os.UserHandle, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
+    method public abstract deprecated void sendStickyBroadcast(android.content.Intent);
+    method public abstract deprecated void sendStickyBroadcastAsUser(android.content.Intent, android.os.UserHandle);
+    method public abstract deprecated void sendStickyOrderedBroadcast(android.content.Intent, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
+    method public abstract deprecated void sendStickyOrderedBroadcastAsUser(android.content.Intent, android.os.UserHandle, android.content.BroadcastReceiver, android.os.Handler, int, java.lang.String, android.os.Bundle);
     method public abstract void setTheme(int);
     method public abstract deprecated void setWallpaper(android.graphics.Bitmap) throws java.io.IOException;
     method public abstract deprecated void setWallpaper(java.io.InputStream) throws java.io.IOException;
@@ -7330,7 +7214,6 @@
     field public static final java.lang.String DISPLAY_SERVICE = "display";
     field public static final java.lang.String DOWNLOAD_SERVICE = "download";
     field public static final java.lang.String DROPBOX_SERVICE = "dropbox";
-    field public static final java.lang.String FINGERPRINT_SERVICE = "fingerprint";
     field public static final java.lang.String INPUT_METHOD_SERVICE = "input_method";
     field public static final java.lang.String INPUT_SERVICE = "input";
     field public static final java.lang.String JOB_SCHEDULER_SERVICE = "jobscheduler";
@@ -7350,14 +7233,13 @@
     field public static final java.lang.String NFC_SERVICE = "nfc";
     field public static final java.lang.String NOTIFICATION_SERVICE = "notification";
     field public static final java.lang.String NSD_SERVICE = "servicediscovery";
-    field public static final java.lang.String PHONE_SERVICE = "phone_service";
     field public static final java.lang.String POWER_SERVICE = "power";
     field public static final java.lang.String PRINT_SERVICE = "print";
     field public static final java.lang.String RESTRICTIONS_SERVICE = "restrictions";
     field public static final java.lang.String SEARCH_SERVICE = "search";
     field public static final java.lang.String SENSOR_SERVICE = "sensor";
     field public static final java.lang.String STORAGE_SERVICE = "storage";
-    field public static final java.lang.String TELECOMM_SERVICE = "telecomm";
+    field public static final java.lang.String TELECOM_SERVICE = "telecom";
     field public static final java.lang.String TELEPHONY_SERVICE = "phone";
     field public static final java.lang.String TEXT_SERVICES_MANAGER_SERVICE = "textservices";
     field public static final java.lang.String TV_INPUT_SERVICE = "tv_input";
@@ -7703,7 +7585,6 @@
     field public static final java.lang.String ACTION_GET_RESTRICTION_ENTRIES = "android.intent.action.GET_RESTRICTION_ENTRIES";
     field public static final java.lang.String ACTION_GTALK_SERVICE_CONNECTED = "android.intent.action.GTALK_CONNECTED";
     field public static final java.lang.String ACTION_GTALK_SERVICE_DISCONNECTED = "android.intent.action.GTALK_DISCONNECTED";
-    field public static final java.lang.String ACTION_HDMI_AUDIO_PLUG = "android.intent.action.HDMI_AUDIO_PLUG";
     field public static final java.lang.String ACTION_HEADSET_PLUG = "android.intent.action.HEADSET_PLUG";
     field public static final java.lang.String ACTION_INPUT_METHOD_CHANGED = "android.intent.action.INPUT_METHOD_CHANGED";
     field public static final java.lang.String ACTION_INSERT = "android.intent.action.INSERT";
@@ -7812,12 +7693,12 @@
     field public static final java.lang.String CATEGORY_TAB = "android.intent.category.TAB";
     field public static final java.lang.String CATEGORY_TEST = "android.intent.category.TEST";
     field public static final java.lang.String CATEGORY_UNIT_TEST = "android.intent.category.UNIT_TEST";
-    field public static final java.lang.String CATEGORY_VOICE = "android.intent.category.VOICE";
     field public static final android.os.Parcelable.Creator CREATOR;
     field public static final java.lang.String EXTRA_ALARM_COUNT = "android.intent.extra.ALARM_COUNT";
     field public static final java.lang.String EXTRA_ALLOW_MULTIPLE = "android.intent.extra.ALLOW_MULTIPLE";
     field public static final deprecated java.lang.String EXTRA_ALLOW_REPLACE = "android.intent.extra.ALLOW_REPLACE";
     field public static final java.lang.String EXTRA_ASSIST_CONTEXT = "android.intent.extra.ASSIST_CONTEXT";
+    field public static final java.lang.String EXTRA_ASSIST_INPUT_HINT_KEYBOARD = "android.intent.extra.ASSIST_INPUT_HINT_KEYBOARD";
     field public static final java.lang.String EXTRA_ASSIST_PACKAGE = "android.intent.extra.ASSIST_PACKAGE";
     field public static final java.lang.String EXTRA_BCC = "android.intent.extra.BCC";
     field public static final java.lang.String EXTRA_BUG_REPORT = "android.intent.extra.BUG_REPORT";
@@ -7864,7 +7745,7 @@
     field public static final java.lang.String EXTRA_TEXT = "android.intent.extra.TEXT";
     field public static final java.lang.String EXTRA_TITLE = "android.intent.extra.TITLE";
     field public static final java.lang.String EXTRA_UID = "android.intent.extra.UID";
-    field public static final java.lang.String EXTRA_USER = "android.intent.extra.user";
+    field public static final java.lang.String EXTRA_USER = "android.intent.extra.USER";
     field public static final int FILL_IN_ACTION = 1; // 0x1
     field public static final int FILL_IN_CATEGORIES = 4; // 0x4
     field public static final int FILL_IN_CLIP_DATA = 128; // 0x80
@@ -8147,8 +8028,8 @@
   }
 
   public class RestrictionsManager {
+    method public android.content.Intent createLocalApprovalIntent();
     method public android.os.Bundle getApplicationRestrictions();
-    method public android.content.Intent getLocalApprovalIntent();
     method public java.util.List<android.content.RestrictionEntry> getManifestRestrictions(java.lang.String);
     method public boolean hasRestrictionsProvider();
     method public void notifyPermissionResponse(java.lang.String, android.os.PersistableBundle);
@@ -8390,6 +8271,7 @@
     field public static final int FLAG_MULTIPROCESS = 1; // 0x1
     field public static final int FLAG_NO_HISTORY = 128; // 0x80
     field public static final int FLAG_RELINQUISH_TASK_IDENTITY = 4096; // 0x1000
+    field public static final int FLAG_RESUME_WHILE_PAUSING = 16384; // 0x4000
     field public static final int FLAG_SINGLE_USER = 1073741824; // 0x40000000
     field public static final int FLAG_STATE_NOT_NEEDED = 16; // 0x10
     field public static final int LAUNCH_MULTIPLE = 0; // 0x0
@@ -8567,9 +8449,6 @@
     field public java.lang.String targetPackage;
   }
 
-  public class KeySet {
-  }
-
   public class LabeledIntent extends android.content.Intent {
     ctor public LabeledIntent(android.content.Intent, java.lang.String, int, int);
     ctor public LabeledIntent(android.content.Intent, java.lang.String, java.lang.CharSequence, int);
@@ -8596,19 +8475,19 @@
   }
 
   public class LauncherApps {
-    method public void addOnAppsChangedCallback(android.content.pm.LauncherApps.OnAppsChangedCallback);
-    method public void addOnAppsChangedCallback(android.content.pm.LauncherApps.OnAppsChangedCallback, android.os.Handler);
     method public java.util.List<android.content.pm.LauncherActivityInfo> getActivityList(java.lang.String, android.os.UserHandle);
-    method public boolean isActivityEnabledForProfile(android.content.ComponentName, android.os.UserHandle);
-    method public boolean isPackageEnabledForProfile(java.lang.String, android.os.UserHandle);
-    method public void removeOnAppsChangedCallback(android.content.pm.LauncherApps.OnAppsChangedCallback);
+    method public boolean isActivityEnabled(android.content.ComponentName, android.os.UserHandle);
+    method public boolean isPackageEnabled(java.lang.String, android.os.UserHandle);
+    method public void registerCallback(android.content.pm.LauncherApps.Callback);
+    method public void registerCallback(android.content.pm.LauncherApps.Callback, android.os.Handler);
     method public android.content.pm.LauncherActivityInfo resolveActivity(android.content.Intent, android.os.UserHandle);
-    method public void showAppDetailsForProfile(android.content.ComponentName, android.os.UserHandle, android.graphics.Rect, android.os.Bundle);
-    method public void startActivityForProfile(android.content.ComponentName, android.os.UserHandle, android.graphics.Rect, android.os.Bundle);
+    method public void startAppDetailsActivity(android.content.ComponentName, android.os.UserHandle, android.graphics.Rect, android.os.Bundle);
+    method public void startMainActivity(android.content.ComponentName, android.os.UserHandle, android.graphics.Rect, android.os.Bundle);
+    method public void unregisterCallback(android.content.pm.LauncherApps.Callback);
   }
 
-  public static abstract class LauncherApps.OnAppsChangedCallback {
-    ctor public LauncherApps.OnAppsChangedCallback();
+  public static abstract class LauncherApps.Callback {
+    ctor public LauncherApps.Callback();
     method public abstract void onPackageAdded(java.lang.String, android.os.UserHandle);
     method public abstract void onPackageChanged(java.lang.String, android.os.UserHandle);
     method public abstract void onPackageRemoved(java.lang.String, android.os.UserHandle);
@@ -8652,29 +8531,34 @@
   }
 
   public class PackageInstaller {
-    method public void addSessionCallback(android.content.pm.PackageInstaller.SessionCallback);
-    method public void addSessionCallback(android.content.pm.PackageInstaller.SessionCallback, android.os.Handler);
+    method public void abandonSession(int);
     method public int createSession(android.content.pm.PackageInstaller.SessionParams) throws java.io.IOException;
     method public java.util.List<android.content.pm.PackageInstaller.SessionInfo> getAllSessions();
     method public java.util.List<android.content.pm.PackageInstaller.SessionInfo> getMySessions();
     method public android.content.pm.PackageInstaller.SessionInfo getSessionInfo(int);
-    method public android.content.pm.PackageInstaller.Session openSession(int);
-    method public void removeSessionCallback(android.content.pm.PackageInstaller.SessionCallback);
+    method public android.content.pm.PackageInstaller.Session openSession(int) throws java.io.IOException;
+    method public void registerSessionCallback(android.content.pm.PackageInstaller.SessionCallback);
+    method public void registerSessionCallback(android.content.pm.PackageInstaller.SessionCallback, android.os.Handler);
     method public void uninstall(java.lang.String, android.content.IntentSender);
+    method public void unregisterSessionCallback(android.content.pm.PackageInstaller.SessionCallback);
+    method public void updateSessionAppIcon(int, android.graphics.Bitmap);
+    method public void updateSessionAppLabel(int, java.lang.CharSequence);
     field public static final java.lang.String ACTION_SESSION_DETAILS = "android.content.pm.action.SESSION_DETAILS";
-    field public static final java.lang.String EXTRA_PACKAGE_NAMES = "android.content.pm.extra.PACKAGE_NAMES";
+    field public static final java.lang.String EXTRA_OTHER_PACKAGE_NAME = "android.content.pm.extra.OTHER_PACKAGE_NAME";
+    field public static final java.lang.String EXTRA_PACKAGE_NAME = "android.content.pm.extra.PACKAGE_NAME";
     field public static final java.lang.String EXTRA_SESSION_ID = "android.content.pm.extra.SESSION_ID";
     field public static final java.lang.String EXTRA_STATUS = "android.content.pm.extra.STATUS";
     field public static final java.lang.String EXTRA_STATUS_MESSAGE = "android.content.pm.extra.STATUS_MESSAGE";
+    field public static final java.lang.String EXTRA_STORAGE_PATH = "android.content.pm.extra.STORAGE_PATH";
     field public static final int STATUS_FAILURE = 1; // 0x1
-    field public static final int STATUS_FAILURE_ABORTED = 2; // 0x2
-    field public static final int STATUS_FAILURE_BLOCKED = 1; // 0x1
-    field public static final int STATUS_FAILURE_CONFLICT = 4; // 0x4
-    field public static final int STATUS_FAILURE_INCOMPATIBLE = 6; // 0x6
-    field public static final int STATUS_FAILURE_INVALID = 3; // 0x3
-    field public static final int STATUS_FAILURE_STORAGE = 5; // 0x5
+    field public static final int STATUS_FAILURE_ABORTED = 3; // 0x3
+    field public static final int STATUS_FAILURE_BLOCKED = 2; // 0x2
+    field public static final int STATUS_FAILURE_CONFLICT = 5; // 0x5
+    field public static final int STATUS_FAILURE_INCOMPATIBLE = 7; // 0x7
+    field public static final int STATUS_FAILURE_INVALID = 4; // 0x4
+    field public static final int STATUS_FAILURE_STORAGE = 6; // 0x6
+    field public static final int STATUS_PENDING_USER_ACTION = -1; // 0xffffffff
     field public static final int STATUS_SUCCESS = 0; // 0x0
-    field public static final int STATUS_USER_ACTION_REQUIRED = -1; // 0xffffffff
   }
 
   public static class PackageInstaller.Session implements java.io.Closeable {
@@ -8682,31 +8566,31 @@
     method public void close();
     method public void commit(android.content.IntentSender);
     method public void fsync(java.io.OutputStream) throws java.io.IOException;
-    method public java.lang.String[] getNames();
+    method public java.lang.String[] getNames() throws java.io.IOException;
     method public java.io.InputStream openRead(java.lang.String) throws java.io.IOException;
     method public java.io.OutputStream openWrite(java.lang.String, long, long) throws java.io.IOException;
-    method public void setProgress(float);
+    method public void setStagingProgress(float);
   }
 
   public static abstract class PackageInstaller.SessionCallback {
     ctor public PackageInstaller.SessionCallback();
-    method public abstract void onClosed(int);
+    method public abstract void onActiveChanged(int, boolean);
+    method public abstract void onBadgingChanged(int);
     method public abstract void onCreated(int);
     method public abstract void onFinished(int, boolean);
-    method public abstract void onOpened(int);
     method public abstract void onProgressChanged(int, float);
   }
 
   public static class PackageInstaller.SessionInfo implements android.os.Parcelable {
+    method public android.content.Intent createDetailsIntent();
     method public int describeContents();
     method public android.graphics.Bitmap getAppIcon();
     method public java.lang.CharSequence getAppLabel();
     method public java.lang.String getAppPackageName();
-    method public android.content.Intent getDetailsIntent();
     method public java.lang.String getInstallerPackageName();
     method public float getProgress();
     method public int getSessionId();
-    method public boolean isOpen();
+    method public boolean isActive();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
@@ -8791,7 +8675,6 @@
     method public abstract java.util.List<android.content.pm.PackageInfo> getInstalledPackages(int);
     method public abstract java.lang.String getInstallerPackageName(java.lang.String);
     method public abstract android.content.pm.InstrumentationInfo getInstrumentationInfo(android.content.ComponentName, int) throws android.content.pm.PackageManager.NameNotFoundException;
-    method public abstract android.content.pm.KeySet getKeySetByAlias(java.lang.String, java.lang.String);
     method public abstract android.content.Intent getLaunchIntentForPackage(java.lang.String);
     method public abstract android.content.Intent getLeanbackLaunchIntentForPackage(java.lang.String);
     method public abstract java.lang.String getNameForUid(int);
@@ -8811,15 +8694,15 @@
     method public abstract android.content.res.Resources getResourcesForApplication(android.content.pm.ApplicationInfo) throws android.content.pm.PackageManager.NameNotFoundException;
     method public abstract android.content.res.Resources getResourcesForApplication(java.lang.String) throws android.content.pm.PackageManager.NameNotFoundException;
     method public abstract android.content.pm.ServiceInfo getServiceInfo(android.content.ComponentName, int) throws android.content.pm.PackageManager.NameNotFoundException;
-    method public abstract android.content.pm.KeySet getSigningKeySet(java.lang.String);
     method public abstract android.content.pm.FeatureInfo[] getSystemAvailableFeatures();
     method public abstract java.lang.String[] getSystemSharedLibraryNames();
     method public abstract java.lang.CharSequence getText(java.lang.String, int, android.content.pm.ApplicationInfo);
+    method public abstract android.graphics.drawable.Drawable getUserBadgedDrawableForDensity(android.graphics.drawable.Drawable, android.os.UserHandle, android.graphics.Rect, int);
+    method public abstract android.graphics.drawable.Drawable getUserBadgedIcon(android.graphics.drawable.Drawable, android.os.UserHandle);
+    method public abstract java.lang.CharSequence getUserBadgedLabel(java.lang.CharSequence, android.os.UserHandle);
     method public abstract android.content.res.XmlResourceParser getXml(java.lang.String, int, android.content.pm.ApplicationInfo);
     method public abstract boolean hasSystemFeature(java.lang.String);
     method public abstract boolean isSafeMode();
-    method public abstract boolean isSignedBy(java.lang.String, android.content.pm.KeySet);
-    method public abstract boolean isSignedByExactly(java.lang.String, android.content.pm.KeySet);
     method public abstract java.util.List<android.content.pm.ResolveInfo> queryBroadcastReceivers(android.content.Intent, int);
     method public abstract java.util.List<android.content.pm.ProviderInfo> queryContentProviders(java.lang.String, int, int);
     method public abstract java.util.List<android.content.pm.InstrumentationInfo> queryInstrumentation(java.lang.String, int);
@@ -8847,6 +8730,7 @@
     field public static final java.lang.String EXTRA_VERIFICATION_RESULT = "android.content.pm.extra.VERIFICATION_RESULT";
     field public static final java.lang.String FEATURE_APP_WIDGETS = "android.software.app_widgets";
     field public static final java.lang.String FEATURE_AUDIO_LOW_LATENCY = "android.hardware.audio.low_latency";
+    field public static final java.lang.String FEATURE_AUDIO_OUTPUT = "android.hardware.audio.output";
     field public static final java.lang.String FEATURE_BACKUP = "android.software.backup";
     field public static final java.lang.String FEATURE_BLUETOOTH = "android.hardware.bluetooth";
     field public static final java.lang.String FEATURE_BLUETOOTH_LE = "android.hardware.bluetooth_le";
@@ -8860,19 +8744,22 @@
     field public static final java.lang.String FEATURE_CAMERA_FLASH = "android.hardware.camera.flash";
     field public static final java.lang.String FEATURE_CAMERA_FRONT = "android.hardware.camera.front";
     field public static final java.lang.String FEATURE_CAMERA_LEVEL_FULL = "android.hardware.camera.level.full";
+    field public static final java.lang.String FEATURE_CONNECTION_SERVICE = "android.software.connectionservice";
     field public static final java.lang.String FEATURE_CONSUMER_IR = "android.hardware.consumerir";
     field public static final java.lang.String FEATURE_DEVICE_ADMIN = "android.software.device_admin";
     field public static final java.lang.String FEATURE_FAKETOUCH = "android.hardware.faketouch";
     field public static final java.lang.String FEATURE_FAKETOUCH_MULTITOUCH_DISTINCT = "android.hardware.faketouch.multitouch.distinct";
     field public static final java.lang.String FEATURE_FAKETOUCH_MULTITOUCH_JAZZHAND = "android.hardware.faketouch.multitouch.jazzhand";
+    field public static final java.lang.String FEATURE_GAMEPAD = "android.hardware.gamepad";
     field public static final java.lang.String FEATURE_HOME_SCREEN = "android.software.home_screen";
     field public static final java.lang.String FEATURE_INPUT_METHODS = "android.software.input_methods";
     field public static final java.lang.String FEATURE_LEANBACK = "android.software.leanback";
+    field public static final java.lang.String FEATURE_LIVE_TV = "android.software.live_tv";
     field public static final java.lang.String FEATURE_LIVE_WALLPAPER = "android.software.live_wallpaper";
     field public static final java.lang.String FEATURE_LOCATION = "android.hardware.location";
     field public static final java.lang.String FEATURE_LOCATION_GPS = "android.hardware.location.gps";
     field public static final java.lang.String FEATURE_LOCATION_NETWORK = "android.hardware.location.network";
-    field public static final java.lang.String FEATURE_MANAGED_PROFILES = "android.software.managed_profiles";
+    field public static final java.lang.String FEATURE_MANAGED_USERS = "android.software.managed_users";
     field public static final java.lang.String FEATURE_MICROPHONE = "android.hardware.microphone";
     field public static final java.lang.String FEATURE_NFC = "android.hardware.nfc";
     field public static final java.lang.String FEATURE_NFC_HOST_CARD_EMULATION = "android.hardware.nfc.hce";
@@ -8880,12 +8767,14 @@
     field public static final java.lang.String FEATURE_PRINTING = "android.software.print";
     field public static final java.lang.String FEATURE_SCREEN_LANDSCAPE = "android.hardware.screen.landscape";
     field public static final java.lang.String FEATURE_SCREEN_PORTRAIT = "android.hardware.screen.portrait";
+    field public static final java.lang.String FEATURE_SECURELY_REMOVES_USERS = "android.software.securely_removes_users";
     field public static final java.lang.String FEATURE_SENSOR_ACCELEROMETER = "android.hardware.sensor.accelerometer";
     field public static final java.lang.String FEATURE_SENSOR_AMBIENT_TEMPERATURE = "android.hardware.sensor.ambient_temperature";
     field public static final java.lang.String FEATURE_SENSOR_BAROMETER = "android.hardware.sensor.barometer";
     field public static final java.lang.String FEATURE_SENSOR_COMPASS = "android.hardware.sensor.compass";
     field public static final java.lang.String FEATURE_SENSOR_GYROSCOPE = "android.hardware.sensor.gyroscope";
     field public static final java.lang.String FEATURE_SENSOR_HEART_RATE = "android.hardware.sensor.heartrate";
+    field public static final java.lang.String FEATURE_SENSOR_HEART_RATE_ECG = "android.hardware.sensor.heartrate.ecg";
     field public static final java.lang.String FEATURE_SENSOR_LIGHT = "android.hardware.sensor.light";
     field public static final java.lang.String FEATURE_SENSOR_PROXIMITY = "android.hardware.sensor.proximity";
     field public static final java.lang.String FEATURE_SENSOR_RELATIVE_HUMIDITY = "android.hardware.sensor.relative_humidity";
@@ -8903,6 +8792,7 @@
     field public static final java.lang.String FEATURE_TOUCHSCREEN_MULTITOUCH_JAZZHAND = "android.hardware.touchscreen.multitouch.jazzhand";
     field public static final java.lang.String FEATURE_USB_ACCESSORY = "android.hardware.usb.accessory";
     field public static final java.lang.String FEATURE_USB_HOST = "android.hardware.usb.host";
+    field public static final java.lang.String FEATURE_VERIFIED_BOOT = "android.software.verified_boot";
     field public static final java.lang.String FEATURE_WATCH = "android.hardware.type.watch";
     field public static final java.lang.String FEATURE_WEBVIEW = "android.software.webview";
     field public static final java.lang.String FEATURE_WIFI = "android.hardware.wifi";
@@ -11407,8 +11297,6 @@
     ctor public PorterDuffColorFilter(int, android.graphics.PorterDuff.Mode);
     method public int getColor();
     method public android.graphics.PorterDuff.Mode getMode();
-    method public void setColor(int);
-    method public void setMode(android.graphics.PorterDuff.Mode);
   }
 
   public class PorterDuffXfermode extends android.graphics.Xfermode {
@@ -12639,27 +12527,27 @@
   public abstract class CameraCaptureSession implements java.lang.AutoCloseable {
     ctor public CameraCaptureSession();
     method public abstract void abortCaptures() throws android.hardware.camera2.CameraAccessException;
-    method public abstract int capture(android.hardware.camera2.CaptureRequest, android.hardware.camera2.CameraCaptureSession.CaptureListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
-    method public abstract int captureBurst(java.util.List<android.hardware.camera2.CaptureRequest>, android.hardware.camera2.CameraCaptureSession.CaptureListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public abstract int capture(android.hardware.camera2.CaptureRequest, android.hardware.camera2.CameraCaptureSession.CaptureCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public abstract int captureBurst(java.util.List<android.hardware.camera2.CaptureRequest>, android.hardware.camera2.CameraCaptureSession.CaptureCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
     method public abstract void close();
     method public abstract android.hardware.camera2.CameraDevice getDevice();
-    method public abstract int setRepeatingBurst(java.util.List<android.hardware.camera2.CaptureRequest>, android.hardware.camera2.CameraCaptureSession.CaptureListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
-    method public abstract int setRepeatingRequest(android.hardware.camera2.CaptureRequest, android.hardware.camera2.CameraCaptureSession.CaptureListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public abstract int setRepeatingBurst(java.util.List<android.hardware.camera2.CaptureRequest>, android.hardware.camera2.CameraCaptureSession.CaptureCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public abstract int setRepeatingRequest(android.hardware.camera2.CaptureRequest, android.hardware.camera2.CameraCaptureSession.CaptureCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
     method public abstract void stopRepeating() throws android.hardware.camera2.CameraAccessException;
   }
 
-  public static abstract class CameraCaptureSession.CaptureListener {
-    ctor public CameraCaptureSession.CaptureListener();
+  public static abstract class CameraCaptureSession.CaptureCallback {
+    ctor public CameraCaptureSession.CaptureCallback();
     method public void onCaptureCompleted(android.hardware.camera2.CameraCaptureSession, android.hardware.camera2.CaptureRequest, android.hardware.camera2.TotalCaptureResult);
     method public void onCaptureFailed(android.hardware.camera2.CameraCaptureSession, android.hardware.camera2.CaptureRequest, android.hardware.camera2.CaptureFailure);
     method public void onCaptureProgressed(android.hardware.camera2.CameraCaptureSession, android.hardware.camera2.CaptureRequest, android.hardware.camera2.CaptureResult);
     method public void onCaptureSequenceAborted(android.hardware.camera2.CameraCaptureSession, int);
     method public void onCaptureSequenceCompleted(android.hardware.camera2.CameraCaptureSession, int, long);
-    method public void onCaptureStarted(android.hardware.camera2.CameraCaptureSession, android.hardware.camera2.CaptureRequest, long);
+    method public void onCaptureStarted(android.hardware.camera2.CameraCaptureSession, android.hardware.camera2.CaptureRequest, long, long);
   }
 
-  public static abstract class CameraCaptureSession.StateListener {
-    ctor public CameraCaptureSession.StateListener();
+  public static abstract class CameraCaptureSession.StateCallback {
+    ctor public CameraCaptureSession.StateCallback();
     method public void onActive(android.hardware.camera2.CameraCaptureSession);
     method public void onClosed(android.hardware.camera2.CameraCaptureSession);
     method public abstract void onConfigureFailed(android.hardware.camera2.CameraCaptureSession);
@@ -12671,7 +12559,7 @@
     method public T get(android.hardware.camera2.CameraCharacteristics.Key<T>);
     method public java.util.List<android.hardware.camera2.CaptureRequest.Key<?>> getAvailableCaptureRequestKeys();
     method public java.util.List<android.hardware.camera2.CaptureResult.Key<?>> getAvailableCaptureResultKeys();
-    field public static final android.hardware.camera2.CameraCharacteristics.Key COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES;
+    field public static final android.hardware.camera2.CameraCharacteristics.Key COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES;
     field public static final android.hardware.camera2.CameraCharacteristics.Key CONTROL_AE_AVAILABLE_ANTIBANDING_MODES;
     field public static final android.hardware.camera2.CameraCharacteristics.Key CONTROL_AE_AVAILABLE_MODES;
     field public static final android.hardware.camera2.CameraCharacteristics.Key CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES;
@@ -12746,7 +12634,7 @@
   public abstract class CameraDevice implements java.lang.AutoCloseable {
     method public abstract void close();
     method public abstract android.hardware.camera2.CaptureRequest.Builder createCaptureRequest(int) throws android.hardware.camera2.CameraAccessException;
-    method public abstract void createCaptureSession(java.util.List<android.view.Surface>, android.hardware.camera2.CameraCaptureSession.StateListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public abstract void createCaptureSession(java.util.List<android.view.Surface>, android.hardware.camera2.CameraCaptureSession.StateCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
     method public abstract java.lang.String getId();
     field public static final int TEMPLATE_MANUAL = 6; // 0x6
     field public static final int TEMPLATE_PREVIEW = 1; // 0x1
@@ -12756,8 +12644,8 @@
     field public static final int TEMPLATE_ZERO_SHUTTER_LAG = 5; // 0x5
   }
 
-  public static abstract class CameraDevice.StateListener {
-    ctor public CameraDevice.StateListener();
+  public static abstract class CameraDevice.StateCallback {
+    ctor public CameraDevice.StateCallback();
     method public void onClosed(android.hardware.camera2.CameraDevice);
     method public abstract void onDisconnected(android.hardware.camera2.CameraDevice);
     method public abstract void onError(android.hardware.camera2.CameraDevice, int);
@@ -12770,24 +12658,24 @@
   }
 
   public final class CameraManager {
-    method public void addAvailabilityListener(android.hardware.camera2.CameraManager.AvailabilityListener, android.os.Handler);
     method public android.hardware.camera2.CameraCharacteristics getCameraCharacteristics(java.lang.String) throws android.hardware.camera2.CameraAccessException;
     method public java.lang.String[] getCameraIdList() throws android.hardware.camera2.CameraAccessException;
-    method public void openCamera(java.lang.String, android.hardware.camera2.CameraDevice.StateListener, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
-    method public void removeAvailabilityListener(android.hardware.camera2.CameraManager.AvailabilityListener);
+    method public void openCamera(java.lang.String, android.hardware.camera2.CameraDevice.StateCallback, android.os.Handler) throws android.hardware.camera2.CameraAccessException;
+    method public void registerAvailabilityCallback(android.hardware.camera2.CameraManager.AvailabilityCallback, android.os.Handler);
+    method public void unregisterAvailabilityCallback(android.hardware.camera2.CameraManager.AvailabilityCallback);
   }
 
-  public static abstract class CameraManager.AvailabilityListener {
-    ctor public CameraManager.AvailabilityListener();
+  public static abstract class CameraManager.AvailabilityCallback {
+    ctor public CameraManager.AvailabilityCallback();
     method public void onCameraAvailable(java.lang.String);
     method public void onCameraUnavailable(java.lang.String);
   }
 
   public abstract class CameraMetadata {
     method public java.util.List<TKey> getKeys();
-    field public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_FAST = 1; // 0x1
-    field public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_HIGH_QUALITY = 2; // 0x2
-    field public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_OFF = 0; // 0x0
+    field public static final int COLOR_CORRECTION_ABERRATION_MODE_FAST = 1; // 0x1
+    field public static final int COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY = 2; // 0x2
+    field public static final int COLOR_CORRECTION_ABERRATION_MODE_OFF = 0; // 0x0
     field public static final int COLOR_CORRECTION_MODE_FAST = 1; // 0x1
     field public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2; // 0x2
     field public static final int COLOR_CORRECTION_MODE_TRANSFORM_MATRIX = 0; // 0x0
@@ -12963,7 +12851,7 @@
   }
 
   public class CaptureFailure {
-    method public int getFrameNumber();
+    method public long getFrameNumber();
     method public int getReason();
     method public android.hardware.camera2.CaptureRequest getRequest();
     method public int getSequenceId();
@@ -12978,7 +12866,7 @@
     method public java.lang.Object getTag();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.hardware.camera2.CaptureRequest.Key BLACK_LEVEL_LOCK;
-    field public static final android.hardware.camera2.CaptureRequest.Key COLOR_CORRECTION_ABERRATION_CORRECTION_MODE;
+    field public static final android.hardware.camera2.CaptureRequest.Key COLOR_CORRECTION_ABERRATION_MODE;
     field public static final android.hardware.camera2.CaptureRequest.Key COLOR_CORRECTION_GAINS;
     field public static final android.hardware.camera2.CaptureRequest.Key COLOR_CORRECTION_MODE;
     field public static final android.hardware.camera2.CaptureRequest.Key COLOR_CORRECTION_TRANSFORM;
@@ -13050,7 +12938,7 @@
     method public android.hardware.camera2.CaptureRequest getRequest();
     method public int getSequenceId();
     field public static final android.hardware.camera2.CaptureResult.Key BLACK_LEVEL_LOCK;
-    field public static final android.hardware.camera2.CaptureResult.Key COLOR_CORRECTION_ABERRATION_CORRECTION_MODE;
+    field public static final android.hardware.camera2.CaptureResult.Key COLOR_CORRECTION_ABERRATION_MODE;
     field public static final android.hardware.camera2.CaptureResult.Key COLOR_CORRECTION_GAINS;
     field public static final android.hardware.camera2.CaptureResult.Key COLOR_CORRECTION_MODE;
     field public static final android.hardware.camera2.CaptureResult.Key COLOR_CORRECTION_TRANSFORM;
@@ -13249,7 +13137,7 @@
 
   public final class DisplayManager {
     method public android.hardware.display.VirtualDisplay createVirtualDisplay(java.lang.String, int, int, int, android.view.Surface, int);
-    method public android.hardware.display.VirtualDisplay createVirtualDisplay(java.lang.String, int, int, int, android.view.Surface, int, android.hardware.display.VirtualDisplay.Callbacks, android.os.Handler);
+    method public android.hardware.display.VirtualDisplay createVirtualDisplay(java.lang.String, int, int, int, android.view.Surface, int, android.hardware.display.VirtualDisplay.Callback, android.os.Handler);
     method public android.view.Display getDisplay(int);
     method public android.view.Display[] getDisplays();
     method public android.view.Display[] getDisplays(java.lang.String);
@@ -13277,11 +13165,11 @@
     method public void setSurface(android.view.Surface);
   }
 
-  public static abstract class VirtualDisplay.Callbacks {
-    ctor public VirtualDisplay.Callbacks();
-    method public void onDisplayPaused();
-    method public void onDisplayResumed();
-    method public void onDisplayStopped();
+  public static abstract class VirtualDisplay.Callback {
+    ctor public VirtualDisplay.Callback();
+    method public void onPaused();
+    method public void onResumed();
+    method public void onStopped();
   }
 
 }
@@ -13305,85 +13193,6 @@
 
 }
 
-package android.hardware.location {
-
-  public final class GeofenceHardware {
-    method public boolean addGeofence(int, int, android.hardware.location.GeofenceHardwareRequest, android.hardware.location.GeofenceHardwareCallback);
-    method public int[] getMonitoringTypes();
-    method public int getStatusOfMonitoringType(int);
-    method public boolean pauseGeofence(int, int);
-    method public boolean registerForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback);
-    method public boolean removeGeofence(int, int);
-    method public boolean resumeGeofence(int, int, int);
-    method public boolean unregisterForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback);
-    field public static final int GEOFENCE_ENTERED = 1; // 0x1
-    field public static final int GEOFENCE_ERROR_ID_EXISTS = 2; // 0x2
-    field public static final int GEOFENCE_ERROR_ID_UNKNOWN = 3; // 0x3
-    field public static final int GEOFENCE_ERROR_INSUFFICIENT_MEMORY = 6; // 0x6
-    field public static final int GEOFENCE_ERROR_INVALID_TRANSITION = 4; // 0x4
-    field public static final int GEOFENCE_ERROR_TOO_MANY_GEOFENCES = 1; // 0x1
-    field public static final int GEOFENCE_EXITED = 2; // 0x2
-    field public static final int GEOFENCE_FAILURE = 5; // 0x5
-    field public static final int GEOFENCE_SUCCESS = 0; // 0x0
-    field public static final int GEOFENCE_UNCERTAIN = 4; // 0x4
-    field public static final int MONITORING_TYPE_FUSED_HARDWARE = 1; // 0x1
-    field public static final int MONITORING_TYPE_GPS_HARDWARE = 0; // 0x0
-    field public static final int MONITOR_CURRENTLY_AVAILABLE = 0; // 0x0
-    field public static final int MONITOR_CURRENTLY_UNAVAILABLE = 1; // 0x1
-    field public static final int MONITOR_UNSUPPORTED = 2; // 0x2
-    field public static final int SOURCE_TECHNOLOGY_BLUETOOTH = 16; // 0x10
-    field public static final int SOURCE_TECHNOLOGY_CELL = 8; // 0x8
-    field public static final int SOURCE_TECHNOLOGY_GNSS = 1; // 0x1
-    field public static final int SOURCE_TECHNOLOGY_SENSORS = 4; // 0x4
-    field public static final int SOURCE_TECHNOLOGY_WIFI = 2; // 0x2
-  }
-
-  public abstract class GeofenceHardwareCallback {
-    ctor public GeofenceHardwareCallback();
-    method public void onGeofenceAdd(int, int);
-    method public void onGeofencePause(int, int);
-    method public void onGeofenceRemove(int, int);
-    method public void onGeofenceResume(int, int);
-    method public void onGeofenceTransition(int, int, android.location.Location, long, int);
-  }
-
-  public abstract class GeofenceHardwareMonitorCallback {
-    ctor public GeofenceHardwareMonitorCallback();
-    method public deprecated void onMonitoringSystemChange(int, boolean, android.location.Location);
-    method public void onMonitoringSystemChange(android.hardware.location.GeofenceHardwareMonitorEvent);
-  }
-
-  public class GeofenceHardwareMonitorEvent implements android.os.Parcelable {
-    ctor public GeofenceHardwareMonitorEvent(int, int, int, android.location.Location);
-    method public int describeContents();
-    method public android.location.Location getLocation();
-    method public int getMonitoringStatus();
-    method public int getMonitoringType();
-    method public int getSourceTechnologies();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-  }
-
-  public final class GeofenceHardwareRequest {
-    ctor public GeofenceHardwareRequest();
-    method public static android.hardware.location.GeofenceHardwareRequest createCircularGeofence(double, double, double);
-    method public int getLastTransition();
-    method public double getLatitude();
-    method public double getLongitude();
-    method public int getMonitorTransitions();
-    method public int getNotificationResponsiveness();
-    method public double getRadius();
-    method public int getSourceTechnologies();
-    method public int getUnknownTimer();
-    method public void setLastTransition(int);
-    method public void setMonitorTransitions(int);
-    method public void setNotificationResponsiveness(int);
-    method public void setSourceTechnologies(int);
-    method public void setUnknownTimer(int);
-  }
-
-}
-
 package android.hardware.usb {
 
   public class UsbAccessory implements android.os.Parcelable {
@@ -13635,7 +13444,7 @@
     method public void onStartInput(android.view.inputmethod.EditorInfo, boolean);
     method public void onStartInputView(android.view.inputmethod.EditorInfo, boolean);
     method public void onUnbindInput();
-    method public void onUpdateCursor(android.graphics.Rect);
+    method public deprecated void onUpdateCursor(android.graphics.Rect);
     method public void onUpdateCursorAnchorInfo(android.view.inputmethod.CursorAnchorInfo);
     method public void onUpdateExtractedText(int, android.view.inputmethod.ExtractedText);
     method public void onUpdateExtractingViews(android.view.inputmethod.EditorInfo);
@@ -14066,7 +13875,7 @@
     ctor public SettingInjectorService(java.lang.String);
     method public final android.os.IBinder onBind(android.content.Intent);
     method protected abstract boolean onGetEnabled();
-    method protected deprecated java.lang.String onGetSummary();
+    method protected abstract deprecated java.lang.String onGetSummary();
     method public final void onStart(android.content.Intent, int);
     method public final int onStartCommand(android.content.Intent, int, int);
     field public static final java.lang.String ACTION_INJECTED_SETTING_CHANGED = "android.location.InjectedSettingChanged";
@@ -14096,7 +13905,9 @@
     field public static final int CONTENT_TYPE_SONIFICATION = 4; // 0x4
     field public static final int CONTENT_TYPE_SPEECH = 1; // 0x1
     field public static final int CONTENT_TYPE_UNKNOWN = 0; // 0x0
+    field public static final android.os.Parcelable.Creator CREATOR;
     field public static final int FLAG_AUDIBILITY_ENFORCED = 1; // 0x1
+    field public static final int FLAG_HW_AV_SYNC = 16; // 0x10
     field public static final int USAGE_ALARM = 4; // 0x4
     field public static final int USAGE_ASSISTANCE_ACCESSIBILITY = 11; // 0xb
     field public static final int USAGE_ASSISTANCE_NAVIGATION_GUIDANCE = 12; // 0xc
@@ -14124,29 +13935,6 @@
     method public android.media.AudioAttributes.Builder setUsage(int);
   }
 
-  public class AudioDevice {
-    field public static final int DEVICE_TYPE_AUX_LINE = 19; // 0x13
-    field public static final int DEVICE_TYPE_BLUETOOTH_A2DP = 8; // 0x8
-    field public static final int DEVICE_TYPE_BLUETOOTH_SCO = 7; // 0x7
-    field public static final int DEVICE_TYPE_BUILTIN_EARPIECE = 1; // 0x1
-    field public static final int DEVICE_TYPE_BUILTIN_MIC = 15; // 0xf
-    field public static final int DEVICE_TYPE_BUILTIN_SPEAKER = 2; // 0x2
-    field public static final int DEVICE_TYPE_DOCK = 13; // 0xd
-    field public static final int DEVICE_TYPE_FM = 14; // 0xe
-    field public static final int DEVICE_TYPE_FM_TUNER = 16; // 0x10
-    field public static final int DEVICE_TYPE_HDMI = 9; // 0x9
-    field public static final int DEVICE_TYPE_HDMI_ARC = 10; // 0xa
-    field public static final int DEVICE_TYPE_LINE_ANALOG = 5; // 0x5
-    field public static final int DEVICE_TYPE_LINE_DIGITAL = 6; // 0x6
-    field public static final int DEVICE_TYPE_TELEPHONY = 18; // 0x12
-    field public static final int DEVICE_TYPE_TV_TUNER = 17; // 0x11
-    field public static final int DEVICE_TYPE_UNKNOWN = 0; // 0x0
-    field public static final int DEVICE_TYPE_USB_ACCESSORY = 12; // 0xc
-    field public static final int DEVICE_TYPE_USB_DEVICE = 11; // 0xb
-    field public static final int DEVICE_TYPE_WIRED_HEADPHONES = 4; // 0x4
-    field public static final int DEVICE_TYPE_WIRED_HEADSET = 3; // 0x3
-  }
-
   public class AudioFormat {
     method public int getChannelMask();
     method public int getEncoding();
@@ -14262,6 +14050,8 @@
     method public deprecated void unregisterRemoteControlClient(android.media.RemoteControlClient);
     method public deprecated void unregisterRemoteController(android.media.RemoteController);
     field public static final java.lang.String ACTION_AUDIO_BECOMING_NOISY = "android.media.AUDIO_BECOMING_NOISY";
+    field public static final java.lang.String ACTION_HDMI_AUDIO_PLUG = "android.media.action.HDMI_AUDIO_PLUG";
+    field public static final java.lang.String ACTION_HEADSET_PLUG = "android.intent.action.HEADSET_PLUG";
     field public static final deprecated java.lang.String ACTION_SCO_AUDIO_STATE_CHANGED = "android.media.SCO_AUDIO_STATE_CHANGED";
     field public static final java.lang.String ACTION_SCO_AUDIO_STATE_UPDATED = "android.media.ACTION_SCO_AUDIO_STATE_UPDATED";
     field public static final int ADJUST_LOWER = -1; // 0xffffffff
@@ -14279,6 +14069,9 @@
     field public static final int AUDIO_SESSION_ID_GENERATE = 0; // 0x0
     field public static final int ERROR = -1; // 0xffffffff
     field public static final int ERROR_DEAD_OBJECT = -6; // 0xfffffffa
+    field public static final java.lang.String EXTRA_AUDIO_PLUG_STATE = "android.media.extra.AUDIO_PLUG_STATE";
+    field public static final java.lang.String EXTRA_ENCODINGS = "android.media.extra.ENCODINGS";
+    field public static final java.lang.String EXTRA_MAX_CHANNEL_COUNT = "android.media.extra.MAX_CHANNEL_COUNT";
     field public static final java.lang.String EXTRA_RINGER_MODE = "android.media.EXTRA_RINGER_MODE";
     field public static final java.lang.String EXTRA_SCO_AUDIO_PREVIOUS_STATE = "android.media.extra.SCO_AUDIO_PREVIOUS_STATE";
     field public static final java.lang.String EXTRA_SCO_AUDIO_STATE = "android.media.extra.SCO_AUDIO_STATE";
@@ -14465,6 +14258,7 @@
     field public static final int QUALITY_CIF = 3; // 0x3
     field public static final int QUALITY_HIGH = 1; // 0x1
     field public static final int QUALITY_HIGH_SPEED_1080P = 2004; // 0x7d4
+    field public static final int QUALITY_HIGH_SPEED_2160P = 2005; // 0x7d5
     field public static final int QUALITY_HIGH_SPEED_480P = 2002; // 0x7d2
     field public static final int QUALITY_HIGH_SPEED_720P = 2003; // 0x7d3
     field public static final int QUALITY_HIGH_SPEED_HIGH = 2001; // 0x7d1
@@ -14578,7 +14372,6 @@
     method public abstract long getTimestamp();
     method public abstract int getWidth();
     method public void setCropRect(android.graphics.Rect);
-    field protected android.graphics.Rect mCropRect;
   }
 
   public static abstract class Image.Plane {
@@ -14710,8 +14503,7 @@
   }
 
   public static final class MediaCodec.CodecException extends java.lang.IllegalStateException {
-    ctor public MediaCodec.CodecException(int, int, java.lang.String);
-    method public int getErrorCode();
+    method public java.lang.String getDiagnosticInfo();
     method public boolean isRecoverable();
     method public boolean isTransient();
   }
@@ -14719,6 +14511,7 @@
   public static final class MediaCodec.CryptoException extends java.lang.RuntimeException {
     ctor public MediaCodec.CryptoException(int, java.lang.String);
     method public int getErrorCode();
+    field public static final int ERROR_INSUFFICIENT_OUTPUT_PROTECTION = 4; // 0x4
     field public static final int ERROR_KEY_EXPIRED = 2; // 0x2
     field public static final int ERROR_NO_KEY = 1; // 0x1
     field public static final int ERROR_RESOURCE_BUSY = 3; // 0x3
@@ -14742,14 +14535,22 @@
     method public final boolean isEncoder();
   }
 
+  public static final class MediaCodecInfo.AudioCapabilities {
+    method public android.util.Range<java.lang.Integer> getBitrateRange();
+    method public int getMaxInputChannelCount();
+    method public android.util.Range<java.lang.Integer>[] getSupportedSampleRateRanges();
+    method public int[] getSupportedSampleRates();
+    method public boolean isSampleRateSupported(int);
+  }
+
   public static final class MediaCodecInfo.CodecCapabilities {
     ctor public MediaCodecInfo.CodecCapabilities();
-    method public static final android.media.MediaCodecInfo.CodecCapabilities CreateFromProfileLevel(java.lang.String, int, int);
-    method public final android.media.MediaCodecInfo.CodecCapabilities.AudioCapabilities getAudioCapabilities();
-    method public final android.media.MediaFormat getDefaultFormat();
-    method public final android.media.MediaCodecInfo.CodecCapabilities.EncoderCapabilities getEncoderCapabilities();
-    method public final java.lang.String getMime();
-    method public final android.media.MediaCodecInfo.CodecCapabilities.VideoCapabilities getVideoCapabilities();
+    method public static android.media.MediaCodecInfo.CodecCapabilities createFromProfileLevel(java.lang.String, int, int);
+    method public android.media.MediaCodecInfo.AudioCapabilities getAudioCapabilities();
+    method public android.media.MediaFormat getDefaultFormat();
+    method public android.media.MediaCodecInfo.EncoderCapabilities getEncoderCapabilities();
+    method public java.lang.String getMimeType();
+    method public android.media.MediaCodecInfo.VideoCapabilities getVideoCapabilities();
     method public final boolean isFeatureRequired(java.lang.String);
     method public final boolean isFeatureSupported(java.lang.String);
     method public final boolean isFormatSupported(android.media.MediaFormat);
@@ -14807,39 +14608,6 @@
     field public android.media.MediaCodecInfo.CodecProfileLevel[] profileLevels;
   }
 
-  public static final class MediaCodecInfo.CodecCapabilities.AudioCapabilities extends android.media.MediaCodecInfo.CodecCapabilities.BaseCapabilities {
-    method public final int getMaxInputChannelCount();
-    method public final android.util.Range<java.lang.Integer>[] getSupportedSampleRateRanges();
-    method public final int[] getSupportedSampleRates();
-    method public final boolean isSampleRateSupported(int);
-  }
-
-  public static class MediaCodecInfo.CodecCapabilities.BaseCapabilities {
-    method public final android.util.Range<java.lang.Integer> getBitrateRange();
-  }
-
-  public static final class MediaCodecInfo.CodecCapabilities.EncoderCapabilities {
-    method public final android.util.Range<java.lang.Integer> getComplexityRange();
-    method public final android.util.Range<java.lang.Integer> getQualityRange();
-    method public final boolean isBitrateModeSupported(int);
-    field public static final int BITRATE_MODE_CBR = 2; // 0x2
-    field public static final int BITRATE_MODE_CQ = 0; // 0x0
-    field public static final int BITRATE_MODE_VBR = 1; // 0x1
-  }
-
-  public static final class MediaCodecInfo.CodecCapabilities.VideoCapabilities extends android.media.MediaCodecInfo.CodecCapabilities.BaseCapabilities {
-    method public final boolean areSizeAndRateSupported(int, int, double);
-    method public final int getHeightAlignment();
-    method public final android.util.Range<java.lang.Integer> getSupportedFrameRates();
-    method public final android.util.Range<java.lang.Double> getSupportedFrameRatesFor(int, int);
-    method public final android.util.Range<java.lang.Integer> getSupportedHeights();
-    method public final android.util.Range<java.lang.Integer> getSupportedHeightsFor(int);
-    method public final android.util.Range<java.lang.Integer> getSupportedWidths();
-    method public final android.util.Range<java.lang.Integer> getSupportedWidthsFor(int);
-    method public final int getWidthAlignment();
-    method public final boolean isSizeSupported(int, int);
-  }
-
   public static final class MediaCodecInfo.CodecProfileLevel {
     ctor public MediaCodecInfo.CodecProfileLevel();
     field public static final int AACObjectELD = 39; // 0x27
@@ -14954,12 +14722,34 @@
     field public int profile;
   }
 
+  public static final class MediaCodecInfo.EncoderCapabilities {
+    method public android.util.Range<java.lang.Integer> getComplexityRange();
+    method public boolean isBitrateModeSupported(int);
+    field public static final int BITRATE_MODE_CBR = 2; // 0x2
+    field public static final int BITRATE_MODE_CQ = 0; // 0x0
+    field public static final int BITRATE_MODE_VBR = 1; // 0x1
+  }
+
+  public static final class MediaCodecInfo.VideoCapabilities {
+    method public boolean areSizeAndRateSupported(int, int, double);
+    method public android.util.Range<java.lang.Integer> getBitrateRange();
+    method public int getHeightAlignment();
+    method public android.util.Range<java.lang.Integer> getSupportedFrameRates();
+    method public android.util.Range<java.lang.Double> getSupportedFrameRatesFor(int, int);
+    method public android.util.Range<java.lang.Integer> getSupportedHeights();
+    method public android.util.Range<java.lang.Integer> getSupportedHeightsFor(int);
+    method public android.util.Range<java.lang.Integer> getSupportedWidths();
+    method public android.util.Range<java.lang.Integer> getSupportedWidthsFor(int);
+    method public int getWidthAlignment();
+    method public boolean isSizeSupported(int, int);
+  }
+
   public final class MediaCodecList {
     ctor public MediaCodecList(int);
     method public final java.lang.String findDecoderForFormat(android.media.MediaFormat);
     method public final java.lang.String findEncoderForFormat(android.media.MediaFormat);
-    method public static final int getCodecCount();
-    method public static final android.media.MediaCodecInfo getCodecInfoAt(int);
+    method public static final deprecated int getCodecCount();
+    method public static final deprecated android.media.MediaCodecInfo getCodecInfoAt(int);
     method public final android.media.MediaCodecInfo[] getCodecInfos();
     field public static final int ALL_CODECS = 1; // 0x1
     field public static final int REGULAR_CODECS = 0; // 0x0
@@ -14976,6 +14766,31 @@
     ctor public MediaCryptoException(java.lang.String);
   }
 
+  public class MediaDescription implements android.os.Parcelable {
+    method public int describeContents();
+    method public java.lang.CharSequence getDescription();
+    method public android.os.Bundle getExtras();
+    method public android.graphics.Bitmap getIconBitmap();
+    method public android.net.Uri getIconUri();
+    method public java.lang.String getMediaId();
+    method public java.lang.CharSequence getSubtitle();
+    method public java.lang.CharSequence getTitle();
+    method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
+  }
+
+  public static class MediaDescription.Builder {
+    ctor public MediaDescription.Builder();
+    method public android.media.MediaDescription build();
+    method public android.media.MediaDescription.Builder setDescription(java.lang.CharSequence);
+    method public android.media.MediaDescription.Builder setExtras(android.os.Bundle);
+    method public android.media.MediaDescription.Builder setIconBitmap(android.graphics.Bitmap);
+    method public android.media.MediaDescription.Builder setIconUri(android.net.Uri);
+    method public android.media.MediaDescription.Builder setMediaId(java.lang.String);
+    method public android.media.MediaDescription.Builder setSubtitle(java.lang.CharSequence);
+    method public android.media.MediaDescription.Builder setTitle(java.lang.CharSequence);
+  }
+
   public final class MediaDrm {
     ctor public MediaDrm(java.util.UUID) throws android.media.UnsupportedSchemeException;
     method public void closeSession(byte[]);
@@ -15026,7 +14841,7 @@
 
   public static final class MediaDrm.MediaDrmStateException extends java.lang.IllegalStateException {
     ctor public MediaDrm.MediaDrmStateException(int, java.lang.String);
-    method public int getErrorCode();
+    method public java.lang.String getDiagnosticInfo();
   }
 
   public static abstract interface MediaDrm.OnEventListener {
@@ -15078,11 +14893,13 @@
     method public static final android.media.MediaFormat createSubtitleFormat(java.lang.String, java.lang.String);
     method public static final android.media.MediaFormat createVideoFormat(java.lang.String, int, int);
     method public final java.nio.ByteBuffer getByteBuffer(java.lang.String);
+    method public boolean getFeatureEnabled(java.lang.String);
     method public final float getFloat(java.lang.String);
     method public final int getInteger(java.lang.String);
     method public final long getLong(java.lang.String);
     method public final java.lang.String getString(java.lang.String);
     method public final void setByteBuffer(java.lang.String, java.nio.ByteBuffer);
+    method public void setFeatureEnabled(java.lang.String, boolean);
     method public final void setFloat(java.lang.String, float);
     method public final void setInteger(java.lang.String, int);
     method public final void setLong(java.lang.String, long);
@@ -15104,7 +14921,6 @@
     field public static final java.lang.String KEY_COLOR_FORMAT = "color-format";
     field public static final java.lang.String KEY_COMPLEXITY = "complexity";
     field public static final java.lang.String KEY_DURATION = "durationUs";
-    field public static final java.lang.String KEY_FEATURE_ = "feature-";
     field public static final java.lang.String KEY_FLAC_COMPRESSION_LEVEL = "flac-compression-level";
     field public static final java.lang.String KEY_FRAME_RATE = "frame-rate";
     field public static final java.lang.String KEY_HEIGHT = "height";
@@ -15120,7 +14936,6 @@
     field public static final java.lang.String KEY_MIME = "mime";
     field public static final java.lang.String KEY_PROFILE = "profile";
     field public static final java.lang.String KEY_PUSH_BLANK_BUFFERS_ON_STOP = "push-blank-buffers-on-shutdown";
-    field public static final java.lang.String KEY_QUALITY = "quality";
     field public static final java.lang.String KEY_REPEAT_PREVIOUS_FRAME_AFTER = "repeat-previous-frame-after";
     field public static final java.lang.String KEY_SAMPLE_RATE = "sample-rate";
     field public static final java.lang.String KEY_TEMPORAL_LAYERING = "ts-schema";
@@ -15154,7 +14969,7 @@
     method public boolean containsKey(java.lang.String);
     method public int describeContents();
     method public android.graphics.Bitmap getBitmap(java.lang.String);
-    method public android.media.MediaMetadata.Description getDescription();
+    method public android.media.MediaDescription getDescription();
     method public long getLong(java.lang.String);
     method public android.media.Rating getRating(java.lang.String);
     method public java.lang.String getString(java.lang.String);
@@ -15182,6 +14997,7 @@
     field public static final java.lang.String METADATA_KEY_DISPLAY_TITLE = "android.media.metadata.DISPLAY_TITLE";
     field public static final java.lang.String METADATA_KEY_DURATION = "android.media.metadata.DURATION";
     field public static final java.lang.String METADATA_KEY_GENRE = "android.media.metadata.GENRE";
+    field public static final java.lang.String METADATA_KEY_MEDIA_ID = "android.media.metadata.MEDIA_ID";
     field public static final java.lang.String METADATA_KEY_NUM_TRACKS = "android.media.metadata.NUM_TRACKS";
     field public static final java.lang.String METADATA_KEY_RATING = "android.media.metadata.RATING";
     field public static final java.lang.String METADATA_KEY_TITLE = "android.media.metadata.TITLE";
@@ -15202,14 +15018,6 @@
     method public android.media.MediaMetadata.Builder putText(java.lang.String, java.lang.CharSequence);
   }
 
-  public final class MediaMetadata.Description {
-    method public java.lang.CharSequence getDescription();
-    method public android.graphics.Bitmap getIcon();
-    method public android.net.Uri getIconUri();
-    method public java.lang.CharSequence getSubtitle();
-    method public java.lang.CharSequence getTitle();
-  }
-
   public abstract deprecated class MediaMetadataEditor {
     method public synchronized void addEditableKey(int);
     method public abstract void apply();
@@ -15760,6 +15568,7 @@
   }
 
   public class Ringtone {
+    method public android.media.AudioAttributes getAudioAttributes();
     method public deprecated int getStreamType();
     method public java.lang.String getTitle(android.content.Context);
     method public boolean isPlaying();
@@ -15968,13 +15777,13 @@
   }
 
   public abstract class VolumeProvider {
-    ctor public VolumeProvider(int, int);
+    ctor public VolumeProvider(int, int, int);
+    method public final int getCurrentVolume();
     method public final int getMaxVolume();
     method public final int getVolumeControl();
-    method public final void notifyVolumeChanged();
     method public void onAdjustVolume(int);
-    method public abstract int onGetCurrentVolume();
     method public void onSetVolumeTo(int);
+    method public final void setCurrentVolume(int);
     field public static final int VOLUME_CONTROL_ABSOLUTE = 2; // 0x2
     field public static final int VOLUME_CONTROL_FIXED = 0; // 0x0
     field public static final int VOLUME_CONTROL_RELATIVE = 1; // 0x1
@@ -16218,12 +16027,16 @@
     method public short getRoundedStrength() throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
     method public boolean getSpeakerAngles(int, int, int[]) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
     method public boolean getStrengthSupported();
-    method public int getVirtualizationMode() throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
+    method public int getVirtualizationMode() throws java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
     method public void setParameterListener(android.media.audiofx.Virtualizer.OnParameterChangeListener);
     method public void setProperties(android.media.audiofx.Virtualizer.Settings) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
     method public void setStrength(short) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException, java.lang.UnsupportedOperationException;
     field public static final int PARAM_STRENGTH = 1; // 0x1
     field public static final int PARAM_STRENGTH_SUPPORTED = 0; // 0x0
+    field public static final int VIRTUALIZATION_MODE_AUTO = 1; // 0x1
+    field public static final int VIRTUALIZATION_MODE_BINAURAL = 2; // 0x2
+    field public static final int VIRTUALIZATION_MODE_OFF = 0; // 0x0
+    field public static final int VIRTUALIZATION_MODE_TRANSAURAL = 3; // 0x3
   }
 
   public static abstract interface Virtualizer.OnParameterChangeListener {
@@ -16291,13 +16104,12 @@
     method public void connect();
     method public void disconnect();
     method public android.os.Bundle getExtras();
-    method public android.net.Uri getRoot();
+    method public java.lang.String getRoot();
     method public android.content.ComponentName getServiceComponent();
     method public android.media.session.MediaSession.Token getSessionToken();
     method public boolean isConnected();
-    method public void loadIcon(android.net.Uri, int, int, android.media.browse.MediaBrowser.IconCallback);
-    method public void subscribe(android.net.Uri, android.media.browse.MediaBrowser.SubscriptionCallback);
-    method public void unsubscribe(android.net.Uri);
+    method public void subscribe(java.lang.String, android.media.browse.MediaBrowser.SubscriptionCallback);
+    method public void unsubscribe(java.lang.String);
   }
 
   public static class MediaBrowser.ConnectionCallback {
@@ -16307,27 +16119,12 @@
     method public void onConnectionSuspended();
   }
 
-  public static abstract class MediaBrowser.IconCallback {
-    ctor public MediaBrowser.IconCallback();
-    method public void onError(android.net.Uri);
-    method public void onIconLoaded(android.net.Uri, android.graphics.Bitmap);
-  }
-
-  public static abstract class MediaBrowser.SubscriptionCallback {
-    ctor public MediaBrowser.SubscriptionCallback();
-    method public void onChildrenLoaded(android.net.Uri, java.util.List<android.media.browse.MediaBrowserItem>);
-    method public void onError(android.net.Uri);
-  }
-
-  public final class MediaBrowserItem implements android.os.Parcelable {
+  public static class MediaBrowser.MediaItem implements android.os.Parcelable {
+    ctor public MediaBrowser.MediaItem(android.media.MediaDescription, int);
     method public int describeContents();
-    method public android.os.Bundle getExtras();
+    method public android.media.MediaDescription getDescription();
     method public int getFlags();
-    method public int getIconResourceId();
-    method public android.net.Uri getIconUri();
-    method public java.lang.CharSequence getSummary();
-    method public java.lang.CharSequence getTitle();
-    method public android.net.Uri getUri();
+    method public java.lang.String getMediaId();
     method public boolean isBrowsable();
     method public boolean isPlayable();
     method public void writeToParcel(android.os.Parcel, int);
@@ -16336,37 +16133,10 @@
     field public static final int FLAG_PLAYABLE = 2; // 0x2
   }
 
-  public static final class MediaBrowserItem.Builder {
-    ctor public MediaBrowserItem.Builder(android.net.Uri, int, java.lang.CharSequence);
-    method public android.media.browse.MediaBrowserItem build();
-    method public android.media.browse.MediaBrowserItem.Builder setExtras(android.os.Bundle);
-    method public android.media.browse.MediaBrowserItem.Builder setIconResourceId(int);
-    method public android.media.browse.MediaBrowserItem.Builder setIconUri(android.net.Uri);
-    method public android.media.browse.MediaBrowserItem.Builder setSummary(java.lang.CharSequence);
-  }
-
-  public abstract class MediaBrowserService extends android.app.Service {
-    ctor public MediaBrowserService();
-    method public void dump(java.io.FileDescriptor, java.io.PrintWriter, java.lang.String[]);
-    method public android.media.session.MediaSession.Token getSessionToken();
-    method public void notifyChildrenChanged(android.net.Uri);
-    method public android.os.IBinder onBind(android.content.Intent);
-    method public abstract android.media.browse.MediaBrowserService.BrowserRoot onGetRoot(java.lang.String, int, android.os.Bundle);
-    method public abstract void onLoadChildren(android.net.Uri, android.media.browse.MediaBrowserService.Result<java.util.List<android.media.browse.MediaBrowserItem>>);
-    method public abstract void onLoadIcon(android.net.Uri, int, int, android.media.browse.MediaBrowserService.Result<android.graphics.Bitmap>);
-    method public void setSessionToken(android.media.session.MediaSession.Token);
-    field public static final java.lang.String SERVICE_ACTION = "android.media.browse.MediaBrowserService";
-  }
-
-  public static final class MediaBrowserService.BrowserRoot {
-    ctor public MediaBrowserService.BrowserRoot(android.net.Uri, android.os.Bundle);
-    method public android.os.Bundle getExtras();
-    method public android.net.Uri getRootUri();
-  }
-
-  public class MediaBrowserService.Result {
-    method public void detach();
-    method public void sendResult(T);
+  public static abstract class MediaBrowser.SubscriptionCallback {
+    ctor public MediaBrowser.SubscriptionCallback();
+    method public void onChildrenLoaded(java.lang.String, java.util.List<android.media.browse.MediaBrowser.MediaItem>);
+    method public void onError(java.lang.String);
   }
 
 }
@@ -16429,10 +16199,10 @@
 package android.media.projection {
 
   public final class MediaProjection {
-    method public void addCallback(android.media.projection.MediaProjection.Callback, android.os.Handler);
-    method public android.hardware.display.VirtualDisplay createVirtualDisplay(java.lang.String, int, int, int, int, android.view.Surface, android.hardware.display.VirtualDisplay.Callbacks, android.os.Handler);
-    method public void removeCallback(android.media.projection.MediaProjection.Callback);
+    method public android.hardware.display.VirtualDisplay createVirtualDisplay(java.lang.String, int, int, int, int, android.view.Surface, android.hardware.display.VirtualDisplay.Callback, android.os.Handler);
+    method public void registerCallback(android.media.projection.MediaProjection.Callback, android.os.Handler);
     method public void stop();
+    method public void unregisterCallback(android.media.projection.MediaProjection.Callback);
   }
 
   public static abstract class MediaProjection.Callback {
@@ -16441,244 +16211,8 @@
   }
 
   public final class MediaProjectionManager {
+    method public android.content.Intent createScreenCaptureIntent();
     method public android.media.projection.MediaProjection getMediaProjection(int, android.content.Intent);
-    method public android.content.Intent getScreenCaptureIntent();
-  }
-
-}
-
-package android.media.routing {
-
-  public final class MediaRouteSelector implements android.os.Parcelable {
-    method public boolean containsProtocol(java.lang.Class<?>);
-    method public boolean containsProtocol(java.lang.String);
-    method public int describeContents();
-    method public android.os.Bundle getExtras();
-    method public int getOptionalFeatures();
-    method public java.util.List<java.lang.String> getOptionalProtocols();
-    method public int getRequiredFeatures();
-    method public java.util.List<java.lang.String> getRequiredProtocols();
-    method public java.lang.String getServicePackageName();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-  }
-
-  public static final class MediaRouteSelector.Builder {
-    ctor public MediaRouteSelector.Builder();
-    method public android.media.routing.MediaRouteSelector.Builder addOptionalProtocol(java.lang.Class<?>);
-    method public android.media.routing.MediaRouteSelector.Builder addOptionalProtocol(java.lang.String);
-    method public android.media.routing.MediaRouteSelector.Builder addRequiredProtocol(java.lang.Class<?>);
-    method public android.media.routing.MediaRouteSelector.Builder addRequiredProtocol(java.lang.String);
-    method public android.media.routing.MediaRouteSelector build();
-    method public android.media.routing.MediaRouteSelector.Builder setExtras(android.os.Bundle);
-    method public android.media.routing.MediaRouteSelector.Builder setOptionalFeatures(int);
-    method public android.media.routing.MediaRouteSelector.Builder setRequiredFeatures(int);
-    method public android.media.routing.MediaRouteSelector.Builder setServicePackageName(java.lang.String);
-  }
-
-  public abstract class MediaRouteService extends android.app.Service {
-    ctor public MediaRouteService();
-    method public android.media.routing.MediaRouter.ServiceMetadata getServiceMetadata();
-    method public android.os.IBinder onBind(android.content.Intent);
-    method public abstract android.media.routing.MediaRouteService.ClientSession onCreateClientSession(android.media.routing.MediaRouteService.ClientInfo);
-    field public static final java.lang.String SERVICE_INTERFACE = "android.media.routing.MediaRouteService";
-  }
-
-  public static final class MediaRouteService.ClientInfo {
-    method public java.lang.String getPackageName();
-    method public int getUid();
-  }
-
-  public static abstract class MediaRouteService.ClientSession {
-    ctor public MediaRouteService.ClientSession();
-    method public abstract boolean onConnect(android.media.routing.MediaRouter.ConnectionRequest, android.media.routing.MediaRouteService.ConnectionCallback);
-    method public abstract void onDisconnect();
-    method public void onPauseStream();
-    method public void onRelease();
-    method public void onResumeStream();
-    method public abstract boolean onStartDiscovery(android.media.routing.MediaRouter.DiscoveryRequest, android.media.routing.MediaRouteService.DiscoveryCallback);
-    method public abstract void onStopDiscovery();
-  }
-
-  public final class MediaRouteService.ConnectionCallback {
-    method public void onConnected(android.media.routing.MediaRouter.ConnectionInfo);
-    method public void onConnectionFailed(int, java.lang.CharSequence, android.os.Bundle);
-    method public void onDisconnected();
-  }
-
-  public final class MediaRouteService.DiscoveryCallback {
-    method public void onDestinationFound(android.media.routing.MediaRouter.DestinationInfo, java.util.List<android.media.routing.MediaRouter.RouteInfo>);
-    method public void onDestinationLost(android.media.routing.MediaRouter.DestinationInfo);
-    method public void onDiscoveryFailed(int, java.lang.CharSequence, android.os.Bundle);
-  }
-
-  public final class MediaRouter {
-    ctor public MediaRouter(android.content.Context);
-    method public void addSelector(android.media.routing.MediaRouteSelector);
-    method public void clearSelectors();
-    method public android.media.routing.MediaRouter.Delegate createDelegate();
-    method public android.media.routing.MediaRouter.ConnectionInfo getConnection();
-    method public int getConnectionState();
-    method public java.util.List<android.media.routing.MediaRouter.DestinationInfo> getDiscoveredDestinations();
-    method public java.util.List<android.media.routing.MediaRouter.RouteInfo> getDiscoveredRoutes(android.media.routing.MediaRouter.DestinationInfo);
-    method public int getDiscoveryState();
-    method public android.media.AudioAttributes getPreferredAudioAttributes();
-    method public android.view.Display getPreferredPresentationDisplay();
-    method public android.media.VolumeProvider getPreferredVolumeProvider();
-    method public android.media.routing.MediaRouter.DestinationInfo getSelectedDestination();
-    method public android.media.routing.MediaRouter.RouteInfo getSelectedRoute();
-    method public java.util.List<android.media.routing.MediaRouteSelector> getSelectors();
-    method public boolean isReleased();
-    method public void pauseStream();
-    method public void release();
-    method public void removeSelector(android.media.routing.MediaRouteSelector);
-    method public void resumeStream();
-    method public void setRoutingCallback(android.media.routing.MediaRouter.RoutingCallback, android.os.Handler);
-    field public static final int CONNECTION_ERROR_ABORTED = 1; // 0x1
-    field public static final int CONNECTION_ERROR_BARGED = 7; // 0x7
-    field public static final int CONNECTION_ERROR_BROKEN = 6; // 0x6
-    field public static final int CONNECTION_ERROR_BUSY = 4; // 0x4
-    field public static final int CONNECTION_ERROR_TIMEOUT = 5; // 0x5
-    field public static final int CONNECTION_ERROR_UNAUTHORIZED = 2; // 0x2
-    field public static final int CONNECTION_ERROR_UNKNOWN = 0; // 0x0
-    field public static final int CONNECTION_ERROR_UNREACHABLE = 3; // 0x3
-    field public static final int CONNECTION_FLAG_BARGE = 1; // 0x1
-    field public static final int CONNECTION_STATE_CONNECTED = 2; // 0x2
-    field public static final int CONNECTION_STATE_CONNECTING = 1; // 0x1
-    field public static final int CONNECTION_STATE_DISCONNECTED = 0; // 0x0
-    field public static final int DISCONNECTION_REASON_APPLICATION_REQUEST = 0; // 0x0
-    field public static final int DISCONNECTION_REASON_ERROR = 2; // 0x2
-    field public static final int DISCONNECTION_REASON_USER_REQUEST = 1; // 0x1
-    field public static final int DISCOVERY_ERROR_ABORTED = 1; // 0x1
-    field public static final int DISCOVERY_ERROR_NO_CONNECTIVITY = 2; // 0x2
-    field public static final int DISCOVERY_ERROR_UNKNOWN = 0; // 0x0
-    field public static final int DISCOVERY_FLAG_BACKGROUND = 1; // 0x1
-    field public static final int DISCOVERY_STATE_STARTED = 1; // 0x1
-    field public static final int DISCOVERY_STATE_STOPPED = 0; // 0x0
-    field public static final int ROUTE_FEATURE_LIVE_AUDIO = 1; // 0x1
-    field public static final int ROUTE_FEATURE_LIVE_VIDEO = 2; // 0x2
-  }
-
-  public static final class MediaRouter.ConnectionInfo {
-    method public android.media.AudioAttributes getAudioAttributes();
-    method public android.os.Bundle getExtras();
-    method public int getFeatures();
-    method public android.view.Display getPresentationDisplay();
-    method public android.os.IBinder getProtocolBinder(java.lang.String);
-    method public android.os.IBinder getProtocolBinder(int);
-    method public T getProtocolObject(java.lang.Class<T>);
-    method public java.util.List<java.lang.String> getProtocols();
-    method public android.media.routing.MediaRouter.RouteInfo getRoute();
-    method public android.media.VolumeProvider getVolumeProvider();
-  }
-
-  public static final class MediaRouter.ConnectionInfo.Builder {
-    ctor public MediaRouter.ConnectionInfo.Builder(android.media.routing.MediaRouter.RouteInfo);
-    method public android.media.routing.MediaRouter.ConnectionInfo build();
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setAudioAttributes(android.media.AudioAttributes);
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setExtras(android.os.Bundle);
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setPresentationDisplay(android.view.Display);
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setProtocolBinder(java.lang.String, android.os.IBinder);
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setProtocolStub(java.lang.Class<?>, android.os.IInterface);
-    method public android.media.routing.MediaRouter.ConnectionInfo.Builder setVolumeProvider(android.media.VolumeProvider);
-  }
-
-  public static final class MediaRouter.ConnectionRequest {
-    method public android.os.Bundle getExtras();
-    method public int getFlags();
-    method public android.media.routing.MediaRouter.RouteInfo getRoute();
-    method public void setExtras(android.os.Bundle);
-    method public void setFlags(int);
-    method public void setRoute(android.media.routing.MediaRouter.RouteInfo);
-  }
-
-  public static final class MediaRouter.Delegate {
-    ctor public MediaRouter.Delegate();
-    method public void addStateCallback(android.media.routing.MediaRouter.StateCallback, android.os.Handler);
-    method public void connect(android.media.routing.MediaRouter.DestinationInfo, int);
-    method public void disconnect(int);
-    method public int getConnectionState();
-    method public java.util.List<android.media.routing.MediaRouter.DestinationInfo> getDiscoveredDestinations();
-    method public int getDiscoveryState();
-    method public android.media.routing.MediaRouter.DestinationInfo getSelectedDestination();
-    method public boolean isReleased();
-    method public void removeStateCallback(android.media.routing.MediaRouter.StateCallback);
-    method public void startDiscovery(int);
-    method public void stopDiscovery();
-  }
-
-  public static final class MediaRouter.DestinationInfo {
-    method public java.lang.CharSequence getDescription();
-    method public android.os.Bundle getExtras();
-    method public int getIconResourceId();
-    method public java.lang.String getId();
-    method public java.lang.CharSequence getName();
-    method public android.media.routing.MediaRouter.ServiceMetadata getServiceMetadata();
-    method public android.graphics.drawable.Drawable loadIcon(android.content.pm.PackageManager);
-  }
-
-  public static final class MediaRouter.DestinationInfo.Builder {
-    ctor public MediaRouter.DestinationInfo.Builder(java.lang.String, android.media.routing.MediaRouter.ServiceMetadata, java.lang.CharSequence);
-    method public android.media.routing.MediaRouter.DestinationInfo build();
-    method public android.media.routing.MediaRouter.DestinationInfo.Builder setDescription(java.lang.CharSequence);
-    method public android.media.routing.MediaRouter.DestinationInfo.Builder setExtras(android.os.Bundle);
-    method public android.media.routing.MediaRouter.DestinationInfo.Builder setIconResourceId(int);
-  }
-
-  public static final class MediaRouter.DiscoveryRequest {
-    method public int getFlags();
-    method public java.util.List<android.media.routing.MediaRouteSelector> getSelectors();
-    method public void setFlags(int);
-    method public void setSelectors(java.util.List<android.media.routing.MediaRouteSelector>);
-  }
-
-  public static final class MediaRouter.RouteInfo {
-    method public android.media.routing.MediaRouter.DestinationInfo getDestination();
-    method public android.os.Bundle getExtras();
-    method public int getFeatures();
-    method public java.lang.String getId();
-    method public java.util.List<java.lang.String> getProtocols();
-    method public android.media.routing.MediaRouteSelector getSelector();
-  }
-
-  public static final class MediaRouter.RouteInfo.Builder {
-    ctor public MediaRouter.RouteInfo.Builder(java.lang.String, android.media.routing.MediaRouter.DestinationInfo, android.media.routing.MediaRouteSelector);
-    method public android.media.routing.MediaRouter.RouteInfo.Builder addProtocol(java.lang.Class<T>);
-    method public android.media.routing.MediaRouter.RouteInfo.Builder addProtocol(java.lang.String);
-    method public android.media.routing.MediaRouter.RouteInfo build();
-    method public android.media.routing.MediaRouter.RouteInfo.Builder setExtras(android.os.Bundle);
-    method public android.media.routing.MediaRouter.RouteInfo.Builder setFeatures(int);
-  }
-
-  public static abstract class MediaRouter.RoutingCallback extends android.media.routing.MediaRouter.StateCallback {
-    ctor public MediaRouter.RoutingCallback();
-    method public boolean onPrepareConnectionRequest(android.media.routing.MediaRouter.ConnectionRequest, android.media.routing.MediaRouter.DestinationInfo, java.util.List<android.media.routing.MediaRouter.RouteInfo>);
-    method public boolean onPrepareDiscoveryRequest(android.media.routing.MediaRouter.DiscoveryRequest, java.util.List<android.media.routing.MediaRouteSelector>);
-  }
-
-  public static final class MediaRouter.ServiceMetadata {
-    method public android.content.ComponentName getComponentName();
-    method public android.graphics.drawable.Drawable getIcon(android.content.pm.PackageManager);
-    method public java.lang.CharSequence getLabel(android.content.pm.PackageManager);
-    method public java.lang.String getPackageName();
-    method public android.content.pm.ServiceInfo getService();
-  }
-
-  public static abstract class MediaRouter.StateCallback {
-    ctor public MediaRouter.StateCallback();
-    method public void onConnected();
-    method public void onConnecting();
-    method public void onConnectionFailed(int, java.lang.CharSequence, android.os.Bundle);
-    method public void onConnectionStateChanged(int);
-    method public void onDestinationFound(android.media.routing.MediaRouter.DestinationInfo);
-    method public void onDestinationLost(android.media.routing.MediaRouter.DestinationInfo);
-    method public void onDisconnected();
-    method public void onDiscoveryFailed(int, java.lang.CharSequence, android.os.Bundle);
-    method public void onDiscoveryStarted();
-    method public void onDiscoveryStateChanged(int);
-    method public void onDiscoveryStopped();
-    method public void onReleased();
-    method public void onSelectedDestinationChanged(android.media.routing.MediaRouter.DestinationInfo);
   }
 
 }
@@ -16687,46 +16221,55 @@
 
   public final class MediaController {
     ctor public MediaController(android.content.Context, android.media.session.MediaSession.Token);
-    method public void addCallback(android.media.session.MediaController.Callback);
-    method public void addCallback(android.media.session.MediaController.Callback, android.os.Handler);
     method public void adjustVolume(int, int);
-    method public android.media.routing.MediaRouter.Delegate createMediaRouterDelegate();
     method public boolean dispatchMediaButtonEvent(android.view.KeyEvent);
     method public android.os.Bundle getExtras();
     method public long getFlags();
-    method public android.app.PendingIntent getLaunchActivity();
     method public android.media.MediaMetadata getMetadata();
     method public java.lang.String getPackageName();
+    method public android.media.session.MediaController.PlaybackInfo getPlaybackInfo();
     method public android.media.session.PlaybackState getPlaybackState();
-    method public java.util.List<android.media.session.MediaSession.Track> getQueue();
+    method public java.util.List<android.media.session.MediaSession.QueueItem> getQueue();
     method public java.lang.CharSequence getQueueTitle();
     method public int getRatingType();
+    method public android.app.PendingIntent getSessionActivity();
     method public android.media.session.MediaSession.Token getSessionToken();
     method public android.media.session.MediaController.TransportControls getTransportControls();
-    method public android.media.session.MediaController.VolumeInfo getVolumeInfo();
-    method public void removeCallback(android.media.session.MediaController.Callback);
+    method public void registerCallback(android.media.session.MediaController.Callback);
+    method public void registerCallback(android.media.session.MediaController.Callback, android.os.Handler);
     method public void sendCommand(java.lang.String, android.os.Bundle, android.os.ResultReceiver);
     method public void setVolumeTo(int, int);
+    method public void unregisterCallback(android.media.session.MediaController.Callback);
   }
 
   public static abstract class MediaController.Callback {
     ctor public MediaController.Callback();
+    method public void onAudioInfoChanged(android.media.session.MediaController.PlaybackInfo);
     method public void onExtrasChanged(android.os.Bundle);
     method public void onMetadataChanged(android.media.MediaMetadata);
     method public void onPlaybackStateChanged(android.media.session.PlaybackState);
-    method public void onQueueChanged(java.util.List<android.media.session.MediaSession.Track>);
+    method public void onQueueChanged(java.util.List<android.media.session.MediaSession.QueueItem>);
     method public void onQueueTitleChanged(java.lang.CharSequence);
     method public void onSessionDestroyed();
     method public void onSessionEvent(java.lang.String, android.os.Bundle);
-    method public void onVolumeInfoChanged(android.media.session.MediaController.VolumeInfo);
+  }
+
+  public static final class MediaController.PlaybackInfo {
+    method public android.media.AudioAttributes getAudioAttributes();
+    method public int getCurrentVolume();
+    method public int getMaxVolume();
+    method public int getPlaybackType();
+    method public int getVolumeControl();
+    field public static final int PLAYBACK_TYPE_LOCAL = 1; // 0x1
+    field public static final int PLAYBACK_TYPE_REMOTE = 2; // 0x2
   }
 
   public final class MediaController.TransportControls {
     method public void fastForward();
     method public void pause();
     method public void play();
+    method public void playFromMediaId(java.lang.String, android.os.Bundle);
     method public void playFromSearch(java.lang.String, android.os.Bundle);
-    method public void playUri(android.net.Uri, android.os.Bundle);
     method public void rewind();
     method public void seekTo(long);
     method public void sendCustomAction(android.media.session.PlaybackState.CustomAction, android.os.Bundle);
@@ -16734,18 +16277,10 @@
     method public void setRating(android.media.Rating);
     method public void skipToNext();
     method public void skipToPrevious();
-    method public void skipToTrack(long);
+    method public void skipToQueueItem(long);
     method public void stop();
   }
 
-  public static final class MediaController.VolumeInfo {
-    method public android.media.AudioAttributes getAudioAttributes();
-    method public int getCurrentVolume();
-    method public int getMaxVolume();
-    method public int getVolumeControl();
-    method public int getVolumeType();
-  }
-
   public final class MediaSession {
     ctor public MediaSession(android.content.Context, java.lang.String);
     method public android.media.session.MediaController getController();
@@ -16758,19 +16293,16 @@
     method public void setCallback(android.media.session.MediaSession.Callback, android.os.Handler);
     method public void setExtras(android.os.Bundle);
     method public void setFlags(int);
-    method public void setLaunchActivity(android.app.PendingIntent);
     method public void setMediaButtonReceiver(android.app.PendingIntent);
-    method public void setMediaRouter(android.media.routing.MediaRouter);
     method public void setMetadata(android.media.MediaMetadata);
     method public void setPlaybackState(android.media.session.PlaybackState);
     method public void setPlaybackToLocal(android.media.AudioAttributes);
     method public void setPlaybackToRemote(android.media.VolumeProvider);
-    method public void setQueue(java.util.List<android.media.session.MediaSession.Track>);
+    method public void setQueue(java.util.List<android.media.session.MediaSession.QueueItem>);
     method public void setQueueTitle(java.lang.CharSequence);
+    method public void setSessionActivity(android.app.PendingIntent);
     field public static final int FLAG_HANDLES_MEDIA_BUTTONS = 1; // 0x1
     field public static final int FLAG_HANDLES_TRANSPORT_CONTROLS = 2; // 0x2
-    field public static final int PLAYBACK_TYPE_LOCAL = 1; // 0x1
-    field public static final int PLAYBACK_TYPE_REMOTE = 2; // 0x2
   }
 
   public static abstract class MediaSession.Callback {
@@ -16781,55 +16313,49 @@
     method public boolean onMediaButtonEvent(android.content.Intent);
     method public void onPause();
     method public void onPlay();
+    method public void onPlayFromMediaId(java.lang.String, android.os.Bundle);
     method public void onPlayFromSearch(java.lang.String, android.os.Bundle);
-    method public void onPlayUri(android.net.Uri, android.os.Bundle);
     method public void onRewind();
     method public void onSeekTo(long);
     method public void onSetRating(android.media.Rating);
     method public void onSkipToNext();
     method public void onSkipToPrevious();
-    method public void onSkipToTrack(long);
+    method public void onSkipToQueueItem(long);
     method public void onStop();
   }
 
+  public static final class MediaSession.QueueItem implements android.os.Parcelable {
+    ctor public MediaSession.QueueItem(android.media.MediaDescription, long);
+    method public int describeContents();
+    method public android.media.MediaDescription getDescription();
+    method public long getQueueId();
+    method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
+    field public static final int UNKNOWN_ID = -1; // 0xffffffff
+  }
+
   public static final class MediaSession.Token implements android.os.Parcelable {
     method public int describeContents();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
-  public static final class MediaSession.Track implements android.os.Parcelable {
-    method public int describeContents();
-    method public android.os.Bundle getExtras();
-    method public long getId();
-    method public android.media.MediaMetadata getMetadata();
-    method public android.net.Uri getUri();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-    field public static final int UNKNOWN_ID = -1; // 0xffffffff
-  }
-
-  public static final class MediaSession.Track.Builder {
-    ctor public MediaSession.Track.Builder(android.media.MediaMetadata, long, android.net.Uri);
-    method public android.media.session.MediaSession.Track build();
-    method public android.media.session.MediaSession.Track.Builder setExtras(android.os.Bundle);
-  }
-
   public final class MediaSessionManager {
-    method public void addActiveSessionsListener(android.media.session.MediaSessionManager.SessionListener, android.content.ComponentName);
+    method public void addOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener, android.content.ComponentName);
+    method public void addOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener, android.content.ComponentName, android.os.Handler);
     method public java.util.List<android.media.session.MediaController> getActiveSessions(android.content.ComponentName);
-    method public void removeActiveSessionsListener(android.media.session.MediaSessionManager.SessionListener);
+    method public void removeOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener);
   }
 
-  public static abstract class MediaSessionManager.SessionListener {
-    ctor public MediaSessionManager.SessionListener(android.content.Context);
+  public static abstract interface MediaSessionManager.OnActiveSessionsChangedListener {
     method public abstract void onActiveSessionsChanged(java.util.List<android.media.session.MediaController>);
   }
 
   public final class PlaybackState implements android.os.Parcelable {
     method public int describeContents();
     method public long getActions();
-    method public long getBufferPosition();
+    method public long getActiveQueueItemId();
+    method public long getBufferedPosition();
     method public java.util.List<android.media.session.PlaybackState.CustomAction> getCustomActions();
     method public java.lang.CharSequence getErrorMessage();
     method public long getLastPositionUpdateTime();
@@ -16840,15 +16366,15 @@
     field public static final long ACTION_FAST_FORWARD = 64L; // 0x40L
     field public static final long ACTION_PAUSE = 2L; // 0x2L
     field public static final long ACTION_PLAY = 4L; // 0x4L
+    field public static final long ACTION_PLAY_FROM_MEDIA_ID = 1024L; // 0x400L
     field public static final long ACTION_PLAY_FROM_SEARCH = 2048L; // 0x800L
     field public static final long ACTION_PLAY_PAUSE = 512L; // 0x200L
-    field public static final long ACTION_PLAY_URI = 1024L; // 0x400L
     field public static final long ACTION_REWIND = 8L; // 0x8L
     field public static final long ACTION_SEEK_TO = 256L; // 0x100L
     field public static final long ACTION_SET_RATING = 128L; // 0x80L
     field public static final long ACTION_SKIP_TO_NEXT = 32L; // 0x20L
     field public static final long ACTION_SKIP_TO_PREVIOUS = 16L; // 0x10L
-    field public static final long ACTION_SKIP_TO_TRACK = 4096L; // 0x1000L
+    field public static final long ACTION_SKIP_TO_QUEUE_ITEM = 4096L; // 0x1000L
     field public static final long ACTION_STOP = 1L; // 0x1L
     field public static final android.os.Parcelable.Creator CREATOR;
     field public static final long PLAYBACK_POSITION_UNKNOWN = -1L; // 0xffffffffffffffffL
@@ -16862,6 +16388,7 @@
     field public static final int STATE_REWINDING = 5; // 0x5
     field public static final int STATE_SKIPPING_TO_NEXT = 10; // 0xa
     field public static final int STATE_SKIPPING_TO_PREVIOUS = 9; // 0x9
+    field public static final int STATE_SKIPPING_TO_QUEUE_ITEM = 11; // 0xb
     field public static final int STATE_STOPPED = 1; // 0x1
   }
 
@@ -16872,8 +16399,8 @@
     method public android.media.session.PlaybackState.Builder addCustomAction(android.media.session.PlaybackState.CustomAction);
     method public android.media.session.PlaybackState build();
     method public android.media.session.PlaybackState.Builder setActions(long);
-    method public android.media.session.PlaybackState.Builder setActiveTrack(long);
-    method public android.media.session.PlaybackState.Builder setBufferPosition(long);
+    method public android.media.session.PlaybackState.Builder setActiveQueueItemId(long);
+    method public android.media.session.PlaybackState.Builder setBufferedPosition(long);
     method public android.media.session.PlaybackState.Builder setErrorMessage(java.lang.CharSequence);
     method public android.media.session.PlaybackState.Builder setState(int, long, float, long);
     method public android.media.session.PlaybackState.Builder setState(int, long, float);
@@ -17038,10 +16565,10 @@
   }
 
   public final class TvInputInfo implements android.os.Parcelable {
+    method public android.content.Intent createSettingsIntent();
+    method public android.content.Intent createSetupIntent();
     method public int describeContents();
     method public java.lang.String getId();
-    method public android.content.Intent getIntentForSettingsActivity();
-    method public android.content.Intent getIntentForSetupActivity();
     method public java.lang.String getParentId();
     method public android.content.pm.ServiceInfo getServiceInfo();
     method public int getType();
@@ -17049,7 +16576,8 @@
     method public android.graphics.drawable.Drawable loadIcon(android.content.Context);
     method public java.lang.CharSequence loadLabel(android.content.Context);
     method public void writeToParcel(android.os.Parcel, int);
-    field public static final java.lang.String EXTRA_INPUT_ID = "inputId";
+    field public static final android.os.Parcelable.Creator CREATOR;
+    field public static final java.lang.String EXTRA_INPUT_ID = "android.media.tv.extra.INPUT_ID";
     field public static final int TYPE_COMPONENT = 1004; // 0x3ec
     field public static final int TYPE_COMPOSITE = 1001; // 0x3e9
     field public static final int TYPE_DISPLAY_PORT = 1008; // 0x3f0
@@ -17068,21 +16596,23 @@
     method public java.util.List<android.media.tv.TvInputInfo> getTvInputList();
     method public boolean isParentalControlsEnabled();
     method public boolean isRatingBlocked(android.media.tv.TvContentRating);
-    method public void registerListener(android.media.tv.TvInputManager.TvInputListener, android.os.Handler);
-    method public void unregisterListener(android.media.tv.TvInputManager.TvInputListener);
+    method public void registerCallback(android.media.tv.TvInputManager.TvInputCallback, android.os.Handler);
+    method public void unregisterCallback(android.media.tv.TvInputManager.TvInputCallback);
     field public static final java.lang.String ACTION_BLOCKED_RATINGS_CHANGED = "android.media.tv.action.BLOCKED_RATINGS_CHANGED";
     field public static final java.lang.String ACTION_PARENTAL_CONTROLS_ENABLED_CHANGED = "android.media.tv.action.PARENTAL_CONTROLS_ENABLED_CHANGED";
+    field public static final java.lang.String ACTION_QUERY_CONTENT_RATING_SYSTEMS = "android.media.tv.action.QUERY_CONTENT_RATING_SYSTEMS";
     field public static final int INPUT_STATE_CONNECTED = 0; // 0x0
     field public static final int INPUT_STATE_CONNECTED_STANDBY = 1; // 0x1
     field public static final int INPUT_STATE_DISCONNECTED = 2; // 0x2
+    field public static final java.lang.String META_DATA_CONTENT_RATING_SYSTEMS = "android.media.tv.metadata.CONTENT_RATING_SYSTEMS";
     field public static final int VIDEO_UNAVAILABLE_REASON_BUFFERING = 3; // 0x3
     field public static final int VIDEO_UNAVAILABLE_REASON_TUNING = 1; // 0x1
     field public static final int VIDEO_UNAVAILABLE_REASON_UNKNOWN = 0; // 0x0
     field public static final int VIDEO_UNAVAILABLE_REASON_WEAK_SIGNAL = 2; // 0x2
   }
 
-  public static abstract class TvInputManager.TvInputListener {
-    ctor public TvInputManager.TvInputListener();
+  public static abstract class TvInputManager.TvInputCallback {
+    ctor public TvInputManager.TvInputCallback();
     method public void onInputAdded(java.lang.String);
     method public void onInputRemoved(java.lang.String);
     method public void onInputStateChanged(java.lang.String, int);
@@ -17140,6 +16670,7 @@
     method public final java.lang.String getId();
     method public final java.lang.String getLanguage();
     method public final int getType();
+    method public final float getVideoFrameRate();
     method public final int getVideoHeight();
     method public final int getVideoWidth();
     method public void writeToParcel(android.os.Parcel, int);
@@ -17156,6 +16687,7 @@
     method public final android.media.tv.TvTrackInfo.Builder setAudioSampleRate(int);
     method public final android.media.tv.TvTrackInfo.Builder setExtra(android.os.Bundle);
     method public final android.media.tv.TvTrackInfo.Builder setLanguage(java.lang.String);
+    method public final android.media.tv.TvTrackInfo.Builder setVideoFrameRate(float);
     method public final android.media.tv.TvTrackInfo.Builder setVideoHeight(int);
     method public final android.media.tv.TvTrackInfo.Builder setVideoWidth(int);
   }
@@ -17171,25 +16703,24 @@
     method public boolean onUnhandledInputEvent(android.view.InputEvent);
     method public void reset();
     method public void selectTrack(int, java.lang.String);
+    method public void setCallback(android.media.tv.TvView.TvInputCallback);
     method public void setCaptionEnabled(boolean);
     method public void setOnUnhandledInputEventListener(android.media.tv.TvView.OnUnhandledInputEventListener);
     method public void setStreamVolume(float);
-    method public void setTvInputListener(android.media.tv.TvView.TvInputListener);
     method public void tune(java.lang.String, android.net.Uri);
-    field public static final int ERROR_INPUT_DISCONNECTED = 1; // 0x1
-    field public static final int ERROR_INPUT_NOT_CONNECTED = 0; // 0x0
   }
 
   public static abstract interface TvView.OnUnhandledInputEventListener {
     method public abstract boolean onUnhandledInputEvent(android.view.InputEvent);
   }
 
-  public static abstract class TvView.TvInputListener {
-    ctor public TvView.TvInputListener();
+  public static abstract class TvView.TvInputCallback {
+    ctor public TvView.TvInputCallback();
     method public void onChannelRetuned(java.lang.String, android.net.Uri);
+    method public void onConnectionFailed(java.lang.String);
     method public void onContentAllowed(java.lang.String);
     method public void onContentBlocked(java.lang.String, android.media.tv.TvContentRating);
-    method public void onError(java.lang.String, int);
+    method public void onDisconnected(java.lang.String);
     method public void onTrackSelected(java.lang.String, int, java.lang.String);
     method public void onTracksChanged(java.lang.String, java.util.List<android.media.tv.TvTrackInfo>);
     method public void onVideoAvailable(java.lang.String);
@@ -17329,6 +16860,7 @@
 package android.net {
 
   public class ConnectivityManager {
+    method public void addDefaultNetworkActiveListener(android.net.ConnectivityManager.OnNetworkActiveListener);
     method public android.net.NetworkInfo getActiveNetworkInfo();
     method public android.net.NetworkInfo[] getAllNetworkInfo();
     method public android.net.Network[] getAllNetworks();
@@ -17342,8 +16874,8 @@
     method public boolean isActiveNetworkMetered();
     method public boolean isDefaultNetworkActive();
     method public static boolean isNetworkTypeValid(int);
-    method public void registerDefaultNetworkActiveListener(android.net.ConnectivityManager.OnNetworkActiveListener);
     method public void registerNetworkCallback(android.net.NetworkRequest, android.net.ConnectivityManager.NetworkCallback);
+    method public void removeDefaultNetworkActiveListener(android.net.ConnectivityManager.OnNetworkActiveListener);
     method public void reportBadNetwork(android.net.Network);
     method public void requestNetwork(android.net.NetworkRequest, android.net.ConnectivityManager.NetworkCallback);
     method public deprecated boolean requestRouteToHost(int, int);
@@ -17351,18 +16883,12 @@
     method public static boolean setProcessDefaultNetwork(android.net.Network);
     method public deprecated int startUsingNetworkFeature(int, java.lang.String);
     method public deprecated int stopUsingNetworkFeature(int, java.lang.String);
-    method public void unregisterDefaultNetworkActiveListener(android.net.ConnectivityManager.OnNetworkActiveListener);
     method public void unregisterNetworkCallback(android.net.ConnectivityManager.NetworkCallback);
     field public static final deprecated java.lang.String ACTION_BACKGROUND_DATA_SETTING_CHANGED = "android.net.conn.BACKGROUND_DATA_SETTING_CHANGED";
-    field public static final java.lang.String ACTION_CAPTIVE_PORTAL_DETECTED = "android.net.conn.CAPTIVE_PORTAL_DETECTED";
-    field public static final java.lang.String ACTION_CAPTIVE_PORTAL_SIGN_IN = "android.net.conn.CAPTIVE_PORTAL_SIGN_IN";
-    field public static final int CAPTIVE_PORTAL_DISCONNECT = 2; // 0x2
-    field public static final int CAPTIVE_PORTAL_SIGNED_IN = 1; // 0x1
     field public static final java.lang.String CONNECTIVITY_ACTION = "android.net.conn.CONNECTIVITY_CHANGE";
     field public static final deprecated int DEFAULT_NETWORK_PREFERENCE = 1; // 0x1
     field public static final java.lang.String EXTRA_EXTRA_INFO = "extraInfo";
     field public static final java.lang.String EXTRA_IS_FAILOVER = "isFailover";
-    field public static final java.lang.String EXTRA_NETWORK = "network";
     field public static final deprecated java.lang.String EXTRA_NETWORK_INFO = "networkInfo";
     field public static final java.lang.String EXTRA_NETWORK_TYPE = "networkType";
     field public static final java.lang.String EXTRA_NO_CONNECTIVITY = "noConnectivity";
@@ -17430,6 +16956,7 @@
     method public int getPrefixLength();
     method public int getScope();
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public final class LinkProperties implements android.os.Parcelable {
@@ -17513,20 +17040,16 @@
   }
 
   public class Network implements android.os.Parcelable {
+    method public void bindSocket(java.net.Socket) throws java.io.IOException;
     method public int describeContents();
     method public java.net.InetAddress[] getAllByName(java.lang.String) throws java.net.UnknownHostException;
-    method public java.net.URL getBoundURL(java.net.URL) throws java.net.MalformedURLException;
     method public java.net.InetAddress getByName(java.lang.String) throws java.net.UnknownHostException;
     method public javax.net.SocketFactory getSocketFactory();
-    method public static void setNetworkBoundURLFactory(android.net.NetworkBoundURLFactory);
+    method public java.net.URLConnection openConnection(java.net.URL) throws java.io.IOException;
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
-  public abstract interface NetworkBoundURLFactory {
-    method public abstract java.net.URL getBoundURL(android.net.Network, java.net.URL) throws java.net.MalformedURLException;
-  }
-
   public final class NetworkCapabilities implements android.os.Parcelable {
     ctor public NetworkCapabilities(android.net.NetworkCapabilities);
     method public int describeContents();
@@ -17646,6 +17169,7 @@
     method public android.net.Uri getPacFileUrl();
     method public int getPort();
     method public void writeToParcel(android.os.Parcel, int);
+    field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public abstract class PskKeyManager {
@@ -17867,14 +17391,12 @@
 
   public class VpnService extends android.app.Service {
     ctor public VpnService();
-    method public boolean addAddress(java.net.InetAddress, int);
     method public android.os.IBinder onBind(android.content.Intent);
     method public void onRevoke();
     method public static android.content.Intent prepare(android.content.Context);
     method public boolean protect(int);
     method public boolean protect(java.net.Socket);
     method public boolean protect(java.net.DatagramSocket);
-    method public boolean removeAddress(java.net.InetAddress, int);
     field public static final java.lang.String SERVICE_INTERFACE = "android.net.VpnService";
   }
 
@@ -18293,7 +17815,6 @@
     field public java.lang.String capabilities;
     field public int frequency;
     field public int level;
-    field public android.net.wifi.passpoint.WifiPasspointInfo passpoint;
     field public long timestamp;
   }
 
@@ -18318,23 +17839,6 @@
     enum_constant public static final android.net.wifi.SupplicantState UNINITIALIZED;
   }
 
-  public class WifiAdapter implements android.os.Parcelable {
-    method public int describeContents();
-    method public java.lang.String getName();
-    method public boolean is5GHzBandSupported();
-    method public boolean isDeviceToApRttSupported();
-    method public boolean isDeviceToDeviceRttSupported();
-    method public boolean isEnhancedPowerReportingSupported();
-    method public boolean isOffChannelTdlsSupported();
-    method public boolean isP2pSupported();
-    method public boolean isPasspointSupported();
-    method public boolean isPortableHotspotSupported();
-    method public boolean isPreferredNetworkOffloadSupported();
-    method public boolean isTdlsSupported();
-    method public boolean isWifiScannerSupported();
-    method public void writeToParcel(android.os.Parcel, int);
-  }
-
   public class WifiConfiguration implements android.os.Parcelable {
     ctor public WifiConfiguration();
     method public int describeContents();
@@ -18468,7 +17972,7 @@
   public class WifiManager {
     method public int addNetwork(android.net.wifi.WifiConfiguration);
     method public static int calculateSignalLevel(int, int);
-    method public void cancelWps(android.net.wifi.WifiManager.ActionListener);
+    method public void cancelWps(android.net.wifi.WifiManager.WpsCallback);
     method public static int compareSignalLevel(int, int);
     method public android.net.wifi.WifiManager.MulticastLock createMulticastLock(java.lang.String);
     method public android.net.wifi.WifiManager.WifiLock createWifiLock(int, java.lang.String);
@@ -18476,13 +17980,18 @@
     method public boolean disableNetwork(int);
     method public boolean disconnect();
     method public boolean enableNetwork(int, boolean);
-    method public java.util.List<android.net.wifi.WifiAdapter> getAdapters();
     method public java.util.List<android.net.wifi.WifiConfiguration> getConfiguredNetworks();
     method public android.net.wifi.WifiInfo getConnectionInfo();
     method public android.net.DhcpInfo getDhcpInfo();
     method public java.util.List<android.net.wifi.ScanResult> getScanResults();
     method public int getWifiState();
+    method public boolean is5GHzBandSupported();
+    method public boolean isDeviceToApRttSupported();
+    method public boolean isEnhancedPowerReportingSupported();
+    method public boolean isP2pSupported();
+    method public boolean isPreferredNetworkOffloadSupported();
     method public boolean isScanAlwaysAvailable();
+    method public boolean isTdlsSupported();
     method public boolean isWifiEnabled();
     method public boolean pingSupplicant();
     method public boolean reassociate();
@@ -18493,12 +18002,10 @@
     method public void setTdlsEnabledWithMacAddress(java.lang.String, boolean);
     method public boolean setWifiEnabled(boolean);
     method public boolean startScan();
-    method public void startWps(android.net.wifi.WpsInfo, android.net.wifi.WifiManager.WpsListener);
+    method public void startWps(android.net.wifi.WpsInfo, android.net.wifi.WifiManager.WpsCallback);
     method public int updateNetwork(android.net.wifi.WifiConfiguration);
     field public static final java.lang.String ACTION_PICK_WIFI_NETWORK = "android.net.wifi.PICK_WIFI_NETWORK";
     field public static final java.lang.String ACTION_REQUEST_SCAN_ALWAYS_AVAILABLE = "android.net.wifi.action.REQUEST_SCAN_ALWAYS_AVAILABLE";
-    field public static final int BUSY = 2; // 0x2
-    field public static final int ERROR = 0; // 0x0
     field public static final int ERROR_AUTHENTICATING = 1; // 0x1
     field public static final java.lang.String EXTRA_BSSID = "bssid";
     field public static final java.lang.String EXTRA_NETWORK_INFO = "networkInfo";
@@ -18509,8 +18016,6 @@
     field public static final java.lang.String EXTRA_SUPPLICANT_ERROR = "supplicantError";
     field public static final java.lang.String EXTRA_WIFI_INFO = "wifiInfo";
     field public static final java.lang.String EXTRA_WIFI_STATE = "wifi_state";
-    field public static final int INVALID_ARGS = 8; // 0x8
-    field public static final int IN_PROGRESS = 1; // 0x1
     field public static final java.lang.String NETWORK_IDS_CHANGED_ACTION = "android.net.wifi.NETWORK_IDS_CHANGED";
     field public static final java.lang.String NETWORK_STATE_CHANGED_ACTION = "android.net.wifi.STATE_CHANGE";
     field public static final java.lang.String RSSI_CHANGED_ACTION = "android.net.wifi.RSSI_CHANGED";
@@ -18533,11 +18038,6 @@
     field public static final int WPS_WEP_PROHIBITED = 4; // 0x4
   }
 
-  public static abstract interface WifiManager.ActionListener {
-    method public abstract void onFailure(int);
-    method public abstract void onSuccess();
-  }
-
   public class WifiManager.MulticastLock {
     method public void acquire();
     method public boolean isHeld();
@@ -18553,10 +18053,11 @@
     method public void setWorkSource(android.os.WorkSource);
   }
 
-  public static abstract interface WifiManager.WpsListener {
-    method public abstract void onCompletion();
-    method public abstract void onFailure(int);
-    method public abstract void onStartSuccess(java.lang.String);
+  public static abstract class WifiManager.WpsCallback {
+    ctor public WifiManager.WpsCallback();
+    method public abstract void onFailed(int);
+    method public abstract void onStarted(java.lang.String);
+    method public abstract void onSucceeded();
   }
 
   public class WpsInfo implements android.os.Parcelable {
@@ -18772,213 +18273,6 @@
 
 }
 
-package android.net.wifi.passpoint {
-
-  public abstract interface IWifiPasspointManager implements android.os.IInterface {
-    method public abstract boolean addCredential(android.net.wifi.passpoint.WifiPasspointCredential) throws android.os.RemoteException;
-    method public abstract java.util.List<android.net.wifi.passpoint.WifiPasspointCredential> getCredentials() throws android.os.RemoteException;
-    method public abstract android.os.Messenger getMessenger() throws android.os.RemoteException;
-    method public abstract int getPasspointState() throws android.os.RemoteException;
-    method public abstract boolean removeCredential(android.net.wifi.passpoint.WifiPasspointCredential) throws android.os.RemoteException;
-    method public abstract java.util.List<android.net.wifi.passpoint.WifiPasspointPolicy> requestCredentialMatch(java.util.List<android.net.wifi.ScanResult>) throws android.os.RemoteException;
-    method public abstract boolean updateCredential(android.net.wifi.passpoint.WifiPasspointCredential) throws android.os.RemoteException;
-  }
-
-  public class WifiPasspointCredential implements android.os.Parcelable {
-    ctor public WifiPasspointCredential(java.lang.String, java.lang.String, android.net.wifi.WifiEnterpriseConfig);
-    method public int describeContents();
-    method public android.net.wifi.WifiEnterpriseConfig getEnterpriseConfig();
-    method public java.lang.String getHomeSpFqdn();
-    method public java.lang.String getRealm();
-    method public void setEnterpriseConfig(android.net.wifi.WifiEnterpriseConfig);
-    method public void setHomeFqdn(java.lang.String);
-    method public void setRealm(java.lang.String);
-    method public void writeToParcel(android.os.Parcel, int);
-  }
-
-  public class WifiPasspointInfo implements android.os.Parcelable {
-    ctor public WifiPasspointInfo();
-    method public int describeContents();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final int ANQP_CAPABILITY = 1; // 0x1
-    field public static final int CELLULAR_NETWORK = 64; // 0x40
-    field public static final int CONNECTION_CAPABILITY = 2048; // 0x800
-    field public static final int DOMAIN_NAME = 128; // 0x80
-    field public static final int HOTSPOT_CAPABILITY = 256; // 0x100
-    field public static final int IP_ADDR_TYPE_AVAILABILITY = 16; // 0x10
-    field public static final int NAI_REALM = 32; // 0x20
-    field public static final int NETWORK_AUTH_TYPE = 4; // 0x4
-    field public static final int OPERATOR_FRIENDLY_NAME = 512; // 0x200
-    field public static final int OSU_PROVIDER = 4096; // 0x1000
-    field public static final int PRESET_ALL = 8191; // 0x1fff
-    field public static final int PRESET_CRED_MATCH = 481; // 0x1e1
-    field public static final int ROAMING_CONSORTIUM = 8; // 0x8
-    field public static final int VENUE_NAME = 2; // 0x2
-    field public static final int WAN_METRICS = 1024; // 0x400
-    field public java.lang.String bssid;
-    field public java.util.List cellularNetworkList;
-    field public java.util.List connectionCapabilityList;
-    field public java.util.List domainNameList;
-    field public android.net.wifi.passpoint.WifiPasspointInfo.IpAddressType ipAddrTypeAvailability;
-    field public java.util.List naiRealmList;
-    field public java.util.List networkAuthTypeList;
-    field public java.lang.String operatorFriendlyName;
-    field public java.util.List osuProviderList;
-    field public java.util.List roamingConsortiumList;
-    field public java.lang.String venueName;
-    field public android.net.wifi.passpoint.WifiPasspointInfo.WanMetrics wanMetrics;
-  }
-
-  public static class WifiPasspointInfo.CellularNetwork {
-    ctor public WifiPasspointInfo.CellularNetwork();
-    field public java.lang.String mcc;
-    field public java.lang.String mnc;
-  }
-
-  public static class WifiPasspointInfo.IpAddressType {
-    ctor public WifiPasspointInfo.IpAddressType();
-    method public int getIpv4Availability();
-    method public int getIpv6Availability();
-    field public static final int IPV4_DOUBLE_NAT = 4; // 0x4
-    field public static final int IPV4_NOT_AVAILABLE = 0; // 0x0
-    field public static final int IPV4_PORT_RESTRICTED = 2; // 0x2
-    field public static final int IPV4_PORT_RESTRICTED_DOUBLE_NAT = 6; // 0x6
-    field public static final int IPV4_PORT_RESTRICTED_SINGLE_NAT = 5; // 0x5
-    field public static final int IPV4_PORT_UNKNOWN = 7; // 0x7
-    field public static final int IPV4_PUBLIC = 1; // 0x1
-    field public static final int IPV4_SINGLE_NAT = 3; // 0x3
-    field public static final int IPV6_AVAILABLE = 1; // 0x1
-    field public static final int IPV6_NOT_AVAILABLE = 0; // 0x0
-    field public static final int IPV6_UNKNOWN = 2; // 0x2
-    field public int availability;
-  }
-
-  public static class WifiPasspointInfo.IpProtoPort {
-    ctor public WifiPasspointInfo.IpProtoPort();
-    field public static final int STATUS_CLOSED = 0; // 0x0
-    field public static final int STATUS_OPEN = 1; // 0x1
-    field public static final int STATUS_UNKNOWN = 2; // 0x2
-    field public int port;
-    field public int proto;
-    field public int status;
-  }
-
-  public static class WifiPasspointInfo.NaiRealm {
-    ctor public WifiPasspointInfo.NaiRealm();
-    field public static final int ENCODING_RFC4282 = 0; // 0x0
-    field public static final int ENCODING_UTF8 = 1; // 0x1
-    field public int encoding;
-    field public java.lang.String realm;
-  }
-
-  public static class WifiPasspointInfo.NetworkAuthType {
-    ctor public WifiPasspointInfo.NetworkAuthType();
-    field public static final int TYPE_DNS_REDIRECTION = 3; // 0x3
-    field public static final int TYPE_HTTP_REDIRECTION = 2; // 0x2
-    field public static final int TYPE_ONLINE_ENROLLMENT = 1; // 0x1
-    field public static final int TYPE_TERMS_AND_CONDITION = 0; // 0x0
-    field public java.lang.String redirectUrl;
-    field public int type;
-  }
-
-  public static class WifiPasspointInfo.WanMetrics {
-    ctor public WifiPasspointInfo.WanMetrics();
-    method public boolean getAtCapacity();
-    method public int getLinkStatus();
-    method public boolean getSymmetricLink();
-    field public static final int STATUS_DOWN = 2; // 0x2
-    field public static final int STATUS_RESERVED = 0; // 0x0
-    field public static final int STATUS_TEST = 3; // 0x3
-    field public static final int STATUS_UP = 1; // 0x1
-    field public int downlinkLoad;
-    field public long downlinkSpeed;
-    field public int lmd;
-    field public int uplinkLoad;
-    field public long uplinkSpeed;
-    field public int wanInfo;
-  }
-
-  public class WifiPasspointManager {
-    ctor public WifiPasspointManager(android.content.Context, android.net.wifi.passpoint.IWifiPasspointManager);
-    method public android.os.Messenger getMessenger();
-    method public android.net.wifi.passpoint.WifiPasspointManager.Channel initialize(android.content.Context, android.os.Looper, android.net.wifi.passpoint.WifiPasspointManager.ChannelListener);
-    method public void requestAnqpInfo(android.net.wifi.passpoint.WifiPasspointManager.Channel, java.util.List<android.net.wifi.ScanResult>, int, android.net.wifi.passpoint.WifiPasspointManager.ActionListener);
-    field public static final java.lang.String PASSPOINT_CRED_CHANGED_ACTION = "android.net.wifi.passpoint.CRED_CHANGE";
-    field public static final java.lang.String PASSPOINT_OSU_AVAILABLE_ACTION = "android.net.wifi.passpoint.OSU_AVAILABLE";
-    field public static final int PASSPOINT_STATE_ACCESS = 3; // 0x3
-    field public static final java.lang.String PASSPOINT_STATE_CHANGED_ACTION = "android.net.wifi.passpoint.STATE_CHANGE";
-    field public static final int PASSPOINT_STATE_DISABLED = 1; // 0x1
-    field public static final int PASSPOINT_STATE_DISCOVERY = 2; // 0x2
-    field public static final int PASSPOINT_STATE_PROVISION = 4; // 0x4
-    field public static final int PASSPOINT_STATE_UNKNOWN = 0; // 0x0
-    field public static final java.lang.String PASSPOINT_USER_REM_REQ_ACTION = "android.net.wifi.passpoint.USER_REM_REQ";
-    field public static final java.lang.String PROTOCOL_DM = "OMA-DM-ClientInitiated";
-    field public static final java.lang.String PROTOCOL_SOAP = "SPP-ClientInitiated";
-    field public static final int REASON_BUSY = 2; // 0x2
-    field public static final int REASON_ERROR = 0; // 0x0
-    field public static final int REASON_INVALID_PARAMETER = 3; // 0x3
-    field public static final int REASON_NOT_TRUSTED = 4; // 0x4
-    field public static final int REASON_WIFI_DISABLED = 1; // 0x1
-    field public static final int REQUEST_ANQP_INFO = 163841; // 0x28001
-    field public static final int REQUEST_ANQP_INFO_FAILED = 163842; // 0x28002
-    field public static final int REQUEST_ANQP_INFO_SUCCEEDED = 163843; // 0x28003
-    field public static final int REQUEST_OSU_ICON = 163844; // 0x28004
-    field public static final int REQUEST_OSU_ICON_FAILED = 163845; // 0x28005
-    field public static final int REQUEST_OSU_ICON_SUCCEEDED = 163846; // 0x28006
-    field public static final int START_OSU = 163847; // 0x28007
-    field public static final int START_OSU_BROWSER = 163848; // 0x28008
-    field public static final int START_OSU_FAILED = 163849; // 0x28009
-    field public static final int START_OSU_SUCCEEDED = 163850; // 0x2800a
-  }
-
-  public static abstract interface WifiPasspointManager.ActionListener {
-    method public abstract void onFailure(int);
-    method public abstract void onSuccess();
-  }
-
-  public static class WifiPasspointManager.Channel {
-  }
-
-  public static abstract interface WifiPasspointManager.ChannelListener {
-    method public abstract void onChannelDisconnected();
-  }
-
-  public static class WifiPasspointManager.ParcelableString implements android.os.Parcelable {
-    ctor public WifiPasspointManager.ParcelableString();
-    method public int describeContents();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-    field public java.lang.String string;
-  }
-
-  public class WifiPasspointOsuProvider implements android.os.Parcelable {
-    method public int describeContents();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-    field public java.lang.String friendlyName;
-    field public java.lang.Object icon;
-    field public java.lang.String iconFileName;
-    field public int iconHeight;
-    field public java.lang.String iconType;
-    field public int iconWidth;
-    field public java.lang.String osuNai;
-    field public java.lang.String osuService;
-    field public java.lang.String ssid;
-  }
-
-  public class WifiPasspointPolicy implements android.os.Parcelable {
-    method public android.net.wifi.WifiConfiguration createWifiConfiguration();
-    method public int describeContents();
-    method public java.lang.String getBssid();
-    method public android.net.wifi.passpoint.WifiPasspointCredential getCredential();
-    method public int getCredentialPriority();
-    method public int getRoamingPriority();
-    method public java.lang.String getSsid();
-    method public void writeToParcel(android.os.Parcel, int);
-  }
-
-}
-
 package android.nfc {
 
   public class FormatException extends java.lang.Exception {
@@ -19045,7 +18339,6 @@
     method public boolean invokeBeam(android.app.Activity);
     method public boolean isEnabled();
     method public boolean isNdefPushEnabled();
-    method public boolean registerLockscreenDispatch(android.nfc.NfcAdapter.NfcLockscreenDispatch, java.lang.String[]);
     method public void setBeamPushUris(android.net.Uri[], android.app.Activity);
     method public void setBeamPushUrisCallback(android.nfc.NfcAdapter.CreateBeamUrisCallback, android.app.Activity);
     method public void setNdefPushMessage(android.nfc.NdefMessage, android.app.Activity, android.app.Activity...);
@@ -19081,10 +18374,6 @@
     method public abstract android.nfc.NdefMessage createNdefMessage(android.nfc.NfcEvent);
   }
 
-  public static abstract interface NfcAdapter.NfcLockscreenDispatch {
-    method public abstract boolean onTagDetected(android.nfc.Tag);
-  }
-
   public static abstract interface NfcAdapter.OnNdefPushCompleteCallback {
     method public abstract void onNdefPushComplete(android.nfc.NfcEvent);
   }
@@ -22119,7 +21408,7 @@
     field public static final int JELLY_BEAN_MR2 = 18; // 0x12
     field public static final int KITKAT = 19; // 0x13
     field public static final int KITKAT_WATCH = 20; // 0x14
-    field public static final int L = 10000; // 0x2710
+    field public static final int L = 21; // 0x15
   }
 
   public final class Bundle extends android.os.BaseBundle implements java.lang.Cloneable android.os.Parcelable {
@@ -22157,6 +21446,8 @@
     method public short getShort(java.lang.String);
     method public short getShort(java.lang.String, short);
     method public short[] getShortArray(java.lang.String);
+    method public android.util.Size getSize(java.lang.String);
+    method public android.util.SizeF getSizeF(java.lang.String);
     method public android.util.SparseArray<T> getSparseParcelableArray(java.lang.String);
     method public java.util.ArrayList<java.lang.String> getStringArrayList(java.lang.String);
     method public boolean hasFileDescriptors();
@@ -22181,6 +21472,8 @@
     method public void putSerializable(java.lang.String, java.io.Serializable);
     method public void putShort(java.lang.String, short);
     method public void putShortArray(java.lang.String, short[]);
+    method public void putSize(java.lang.String, android.util.Size);
+    method public void putSizeF(java.lang.String, android.util.SizeF);
     method public void putSparseParcelableArray(java.lang.String, android.util.SparseArray<? extends android.os.Parcelable>);
     method public void putStringArrayList(java.lang.String, java.util.ArrayList<java.lang.String>);
     method public void readFromParcel(android.os.Parcel);
@@ -22632,6 +21925,8 @@
     method public final android.os.PersistableBundle readPersistableBundle();
     method public final android.os.PersistableBundle readPersistableBundle(java.lang.ClassLoader);
     method public final java.io.Serializable readSerializable();
+    method public final android.util.Size readSize();
+    method public final android.util.SizeF readSizeF();
     method public final android.util.SparseArray readSparseArray(java.lang.ClassLoader);
     method public final android.util.SparseBooleanArray readSparseBooleanArray();
     method public final java.lang.String readString();
@@ -22673,6 +21968,8 @@
     method public final void writeParcelableArray(T[], int);
     method public final void writePersistableBundle(android.os.PersistableBundle);
     method public final void writeSerializable(java.io.Serializable);
+    method public final void writeSize(android.util.Size);
+    method public final void writeSizeF(android.util.SizeF);
     method public final void writeSparseArray(android.util.SparseArray<java.lang.Object>);
     method public final void writeSparseBooleanArray(android.util.SparseBooleanArray);
     method public final void writeString(java.lang.String);
@@ -22796,19 +22093,19 @@
   }
 
   public final class PowerManager {
-    method public void goToSleep(long);
     method public boolean isInteractive();
     method public boolean isPowerSaveMode();
     method public deprecated boolean isScreenOn();
+    method public boolean isWakeLockLevelSupported(int);
     method public android.os.PowerManager.WakeLock newWakeLock(int, java.lang.String);
     method public void reboot(java.lang.String);
-    method public void userActivity(long, boolean);
-    method public void wakeUp(long);
     field public static final int ACQUIRE_CAUSES_WAKEUP = 268435456; // 0x10000000
     field public static final java.lang.String ACTION_POWER_SAVE_MODE_CHANGED = "android.os.action.POWER_SAVE_MODE_CHANGED";
     field public static final deprecated int FULL_WAKE_LOCK = 26; // 0x1a
     field public static final int ON_AFTER_RELEASE = 536870912; // 0x20000000
     field public static final int PARTIAL_WAKE_LOCK = 1; // 0x1
+    field public static final int PROXIMITY_SCREEN_OFF_WAKE_LOCK = 32; // 0x20
+    field public static final int RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY = 1; // 0x1
     field public static final deprecated int SCREEN_BRIGHT_WAKE_LOCK = 10; // 0xa
     field public static final deprecated int SCREEN_DIM_WAKE_LOCK = 6; // 0x6
   }
@@ -22818,6 +22115,7 @@
     method public void acquire(long);
     method public boolean isHeld();
     method public void release();
+    method public void release(int);
     method public void setReferenceCounted(boolean);
     method public void setWorkSource(android.os.WorkSource);
   }
@@ -23011,9 +22309,6 @@
 
   public class UserManager {
     method public android.os.Bundle getApplicationRestrictions(java.lang.String);
-    method public android.graphics.drawable.Drawable getBadgedDrawableForUser(android.graphics.drawable.Drawable, android.os.UserHandle, android.graphics.Rect, int);
-    method public android.graphics.drawable.Drawable getBadgedIconForUser(android.graphics.drawable.Drawable, android.os.UserHandle);
-    method public java.lang.CharSequence getBadgedLabelForUser(java.lang.CharSequence, android.os.UserHandle);
     method public long getSerialNumberForUser(android.os.UserHandle);
     method public int getUserCount();
     method public android.os.UserHandle getUserForSerialNumber(long);
@@ -23047,6 +22342,7 @@
     field public static final java.lang.String DISALLOW_INSTALL_UNKNOWN_SOURCES = "no_install_unknown_sources";
     field public static final java.lang.String DISALLOW_MODIFY_ACCOUNTS = "no_modify_accounts";
     field public static final java.lang.String DISALLOW_MOUNT_PHYSICAL_MEDIA = "no_physical_media";
+    field public static final java.lang.String DISALLOW_OUTGOING_BEAM = "no_outgoing_beam";
     field public static final java.lang.String DISALLOW_OUTGOING_CALLS = "no_outgoing_calls";
     field public static final java.lang.String DISALLOW_REMOVE_USER = "no_remove_user";
     field public static final java.lang.String DISALLOW_SHARE_LOCATION = "no_share_location";
@@ -23105,17 +22401,6 @@
 
 }
 
-package android.phone {
-
-  public final class PhoneManager {
-    method public void cancelMissedCallsNotification();
-    method public boolean handlePinMmi(java.lang.String);
-    method public boolean isInAPhoneCall();
-    method public void showCallScreen(boolean);
-  }
-
-}
-
 package android.preference {
 
   public class CheckBoxPreference extends android.preference.TwoStatePreference {
@@ -24252,9 +23537,8 @@
     field public static final java.lang.String DATE = "date";
     field public static final java.lang.String DEFAULT_SORT_ORDER = "date DESC";
     field public static final java.lang.String DURATION = "duration";
-    field public static final java.lang.String EXTRA_CALL_TYPE_FILTER = "extra_call_type_filter";
+    field public static final java.lang.String EXTRA_CALL_TYPE_FILTER = "android.provider.extra.CALL_TYPE_FILTER";
     field public static final java.lang.String FEATURES = "features";
-    field public static final int FEATURES_NONE = 0; // 0x0
     field public static final int FEATURES_VIDEO = 1; // 0x1
     field public static final java.lang.String GEOCODED_LOCATION = "geocoded_location";
     field public static final int INCOMING_TYPE = 1; // 0x1
@@ -24616,11 +23900,11 @@
 
   public static final class ContactsContract.CommonDataKinds.Callable implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     ctor public ContactsContract.CommonDataKinds.Callable();
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final android.net.Uri CONTENT_FILTER_URI;
     field public static final android.net.Uri CONTENT_URI;
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
   }
 
   protected static abstract interface ContactsContract.CommonDataKinds.CommonColumns implements android.provider.ContactsContract.CommonDataKinds.BaseTypes {
@@ -24631,11 +23915,11 @@
 
   public static final class ContactsContract.CommonDataKinds.Contactables implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     ctor public ContactsContract.CommonDataKinds.Contactables();
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final android.net.Uri CONTENT_FILTER_URI;
     field public static final android.net.Uri CONTENT_URI;
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String VISIBLE_CONTACTS_ONLY = "visible_contacts_only";
   }
 
@@ -24643,15 +23927,15 @@
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
     field public static final java.lang.String ADDRESS = "data1";
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final android.net.Uri CONTENT_FILTER_URI;
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/email_v2";
     field public static final android.net.Uri CONTENT_LOOKUP_URI;
     field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/email_v2";
     field public static final android.net.Uri CONTENT_URI;
     field public static final java.lang.String DISPLAY_NAME = "data4";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final int TYPE_HOME = 1; // 0x1
     field public static final int TYPE_MOBILE = 4; // 0x4
     field public static final int TYPE_OTHER = 3; // 0x3
@@ -24661,10 +23945,10 @@
   public static final class ContactsContract.CommonDataKinds.Event implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static int getTypeResource(java.lang.Integer);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/contact_event";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String START_DATE = "data1";
     field public static final int TYPE_ANNIVERSARY = 1; // 0x1
     field public static final int TYPE_BIRTHDAY = 3; // 0x3
@@ -24672,19 +23956,19 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.GroupMembership implements android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/group_membership";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String GROUP_ROW_ID = "data1";
     field public static final java.lang.String GROUP_SOURCE_ID = "group_sourceid";
   }
 
   public static final class ContactsContract.CommonDataKinds.Identity implements android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/identity";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String IDENTITY = "data1";
     field public static final java.lang.String NAMESPACE = "data2";
   }
@@ -24694,11 +23978,11 @@
     method public static final int getProtocolLabelResource(int);
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/im";
     field public static final java.lang.String CUSTOM_PROTOCOL = "data6";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String PROTOCOL = "data5";
     field public static final int PROTOCOL_AIM = 0; // 0x0
     field public static final int PROTOCOL_CUSTOM = -1; // 0xffffffff
@@ -24716,10 +24000,10 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.Nickname implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/nickname";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String NAME = "data1";
     field public static final int TYPE_DEFAULT = 1; // 0x1
     field public static final int TYPE_INITIALS = 5; // 0x5
@@ -24730,22 +24014,22 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.Note implements android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/note";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String NOTE = "data1";
   }
 
   public static final class ContactsContract.CommonDataKinds.Organization implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String COMPANY = "data1";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/organization";
     field public static final java.lang.String DEPARTMENT = "data5";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String JOB_DESCRIPTION = "data6";
     field public static final java.lang.String OFFICE_LOCATION = "data9";
     field public static final java.lang.String PHONETIC_NAME = "data8";
@@ -24758,13 +24042,13 @@
   public static final class ContactsContract.CommonDataKinds.Phone implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final android.net.Uri CONTENT_FILTER_URI;
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/phone_v2";
     field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/phone_v2";
     field public static final android.net.Uri CONTENT_URI;
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String NORMALIZED_NUMBER = "data4";
     field public static final java.lang.String NUMBER = "data1";
     field public static final java.lang.String SEARCH_DISPLAY_NAME_KEY = "search_display_name";
@@ -24792,10 +24076,10 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.Photo implements android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/photo";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String PHOTO = "data15";
     field public static final java.lang.String PHOTO_FILE_ID = "data14";
   }
@@ -24803,10 +24087,10 @@
   public static final class ContactsContract.CommonDataKinds.Relation implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/relation";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String NAME = "data1";
     field public static final int TYPE_ASSISTANT = 1; // 0x1
     field public static final int TYPE_BROTHER = 2; // 0x2
@@ -24827,10 +24111,10 @@
   public static final class ContactsContract.CommonDataKinds.SipAddress implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/sip_address";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String SIP_ADDRESS = "data1";
     field public static final int TYPE_HOME = 1; // 0x1
     field public static final int TYPE_OTHER = 3; // 0x3
@@ -24838,11 +24122,11 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.StructuredName implements android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/name";
     field public static final java.lang.String DISPLAY_NAME = "data1";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String FAMILY_NAME = "data3";
     field public static final java.lang.String FULL_NAME_STYLE = "data10";
     field public static final java.lang.String GIVEN_NAME = "data2";
@@ -24857,14 +24141,14 @@
   public static final class ContactsContract.CommonDataKinds.StructuredPostal implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
     method public static final java.lang.CharSequence getTypeLabel(android.content.res.Resources, int, java.lang.CharSequence);
     method public static final int getTypeLabelResource(int);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CITY = "data7";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/postal-address_v2";
     field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/postal-address_v2";
     field public static final android.net.Uri CONTENT_URI;
     field public static final java.lang.String COUNTRY = "data10";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String FORMATTED_ADDRESS = "data1";
     field public static final java.lang.String NEIGHBORHOOD = "data6";
     field public static final java.lang.String POBOX = "data5";
@@ -24877,10 +24161,10 @@
   }
 
   public static final class ContactsContract.CommonDataKinds.Website implements android.provider.ContactsContract.CommonDataKinds.CommonColumns android.provider.ContactsContract.DataColumnsWithJoins {
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/website";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final int TYPE_BLOG = 2; // 0x2
     field public static final int TYPE_FTP = 6; // 0x6
     field public static final int TYPE_HOME = 4; // 0x4
@@ -24923,12 +24207,11 @@
   public static class ContactsContract.Contacts implements android.provider.BaseColumns android.provider.ContactsContract.ContactNameColumns android.provider.ContactsContract.ContactOptionsColumns android.provider.ContactsContract.ContactStatusColumns android.provider.ContactsContract.ContactsColumns {
     method public static android.net.Uri getLookupUri(android.content.ContentResolver, android.net.Uri);
     method public static android.net.Uri getLookupUri(long, java.lang.String);
-    method public static boolean isCorpContactId(long);
+    method public static boolean isEnterpriseContactId(long);
     method public static android.net.Uri lookupContact(android.content.ContentResolver, android.net.Uri);
     method public static deprecated void markAsContacted(android.content.ContentResolver, long);
     method public static java.io.InputStream openContactPhotoInputStream(android.content.ContentResolver, android.net.Uri, boolean);
     method public static java.io.InputStream openContactPhotoInputStream(android.content.ContentResolver, android.net.Uri);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final android.net.Uri CONTENT_FILTER_URI;
     field public static final android.net.Uri CONTENT_FREQUENT_URI;
     field public static final android.net.Uri CONTENT_GROUP_URI;
@@ -24941,8 +24224,9 @@
     field public static final android.net.Uri CONTENT_URI;
     field public static final java.lang.String CONTENT_VCARD_TYPE = "text/x-vcard";
     field public static final android.net.Uri CONTENT_VCARD_URI;
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
   }
 
   public static final class ContactsContract.Contacts.AggregationSuggestions implements android.provider.BaseColumns android.provider.ContactsContract.ContactOptionsColumns android.provider.ContactsContract.ContactStatusColumns android.provider.ContactsContract.ContactsColumns {
@@ -24987,11 +24271,11 @@
 
   public static final class ContactsContract.Data implements android.provider.ContactsContract.DataColumnsWithJoins {
     method public static android.net.Uri getContactLookupUri(android.content.ContentResolver, android.net.Uri);
-    field public static final java.lang.String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
     field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/data";
     field public static final android.net.Uri CONTENT_URI;
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
-    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX = "android.provider.extra.ADDRESS_BOOK_INDEX";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
+    field public static final java.lang.String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
     field public static final java.lang.String VISIBLE_CONTACTS_ONLY = "visible_contacts_only";
   }
 
@@ -25197,6 +24481,7 @@
 
   public static final class ContactsContract.PinnedPositions {
     ctor public ContactsContract.PinnedPositions();
+    method public static void pin(android.content.ContentResolver, long, int);
     method public static void undemote(android.content.ContentResolver, long);
     field public static final int DEMOTED = -1; // 0xffffffff
     field public static final int UNPINNED = 0; // 0x0
@@ -25234,8 +24519,8 @@
     ctor public ContactsContract.QuickContact();
     method public static void showQuickContact(android.content.Context, android.view.View, android.net.Uri, int, java.lang.String[]);
     method public static void showQuickContact(android.content.Context, android.graphics.Rect, android.net.Uri, int, java.lang.String[]);
-    field public static final java.lang.String ACTION_QUICK_CONTACT = "com.android.contacts.action.QUICK_CONTACT";
-    field public static final java.lang.String EXTRA_EXCLUDE_MIMES = "exclude_mimes";
+    field public static final java.lang.String ACTION_QUICK_CONTACT = "android.provider.action.QUICK_CONTACT";
+    field public static final java.lang.String EXTRA_EXCLUDE_MIMES = "android.provider.extra.EXCLUDE_MIMES";
     field public static final int MODE_LARGE = 3; // 0x3
     field public static final int MODE_MEDIUM = 2; // 0x2
     field public static final int MODE_SMALL = 1; // 0x1
@@ -25276,7 +24561,6 @@
     field public static final java.lang.String CONTACT_ID = "contact_id";
     field public static final java.lang.String DATA_SET = "data_set";
     field public static final java.lang.String DELETED = "deleted";
-    field public static final java.lang.String NAME_VERIFIED = "name_verified";
     field public static final java.lang.String RAW_CONTACT_IS_READ_ONLY = "raw_contact_is_read_only";
     field public static final java.lang.String RAW_CONTACT_IS_USER_PROFILE = "raw_contact_is_user_profile";
   }
@@ -25886,14 +25170,12 @@
     field public static final java.lang.String ACTION_SYNC_SETTINGS = "android.settings.SYNC_SETTINGS";
     field public static final java.lang.String ACTION_USAGE_ACCESS_SETTINGS = "android.settings.USAGE_ACCESS_SETTINGS";
     field public static final java.lang.String ACTION_USER_DICTIONARY_SETTINGS = "android.settings.USER_DICTIONARY_SETTINGS";
-    field public static final java.lang.String ACTION_VOICE_CONTROL_AIRPLANE_MODE = "android.settings.VOICE_CONTROL_AIRPLANE_MODE";
     field public static final java.lang.String ACTION_VOICE_INPUT_SETTINGS = "android.settings.VOICE_INPUT_SETTINGS";
     field public static final java.lang.String ACTION_WIFI_IP_SETTINGS = "android.settings.WIFI_IP_SETTINGS";
     field public static final java.lang.String ACTION_WIFI_SETTINGS = "android.settings.WIFI_SETTINGS";
     field public static final java.lang.String ACTION_WIRELESS_SETTINGS = "android.settings.WIRELESS_SETTINGS";
     field public static final java.lang.String AUTHORITY = "settings";
     field public static final java.lang.String EXTRA_ACCOUNT_TYPES = "account_types";
-    field public static final java.lang.String EXTRA_AIRPLANE_MODE_ENABLED = "airplane_mode_enabled";
     field public static final java.lang.String EXTRA_AUTHORITIES = "authorities";
     field public static final java.lang.String EXTRA_INPUT_METHOD_ID = "input_method_id";
   }
@@ -26309,6 +25591,8 @@
   public static final class Telephony.Mms.Intents {
     field public static final java.lang.String CONTENT_CHANGED_ACTION = "android.intent.action.CONTENT_CHANGED";
     field public static final java.lang.String DELETED_CONTENTS = "deleted_contents";
+    field public static final java.lang.String EXTRA_MMS_CONTENT_URI = "android.provider.Telephony.extra.MMS_CONTENT_URI";
+    field public static final java.lang.String EXTRA_MMS_LOCATION_URL = "android.provider.Telephony.extra.MMS_LOCATION_URL";
     field public static final java.lang.String MMS_DOWNLOAD_ACTION = "android.provider.Telephony.MMS_DOWNLOAD";
     field public static final java.lang.String MMS_SEND_ACTION = "android.provider.Telephony.MMS_SEND";
   }
@@ -27613,47 +26897,29 @@
 
 }
 
-package android.service.fingerprint {
+package android.service.media {
 
-  public class FingerprintManager {
-    method public void enroll(long);
-    method public void enrollCancel();
-    method public boolean enrolledAndEnabled();
-    method public void remove(int);
-    method public void startListening(android.service.fingerprint.FingerprintManagerReceiver);
-    method public void stopListening();
-    field public static final int FINGERPRINT_ACQUIRED = 1; // 0x1
-    field public static final int FINGERPRINT_ACQUIRED_GOOD = 0; // 0x0
-    field public static final int FINGERPRINT_ACQUIRED_IMAGER_DIRTY = 4; // 0x4
-    field public static final int FINGERPRINT_ACQUIRED_INSUFFICIENT = 2; // 0x2
-    field public static final int FINGERPRINT_ACQUIRED_PARTIAL = 1; // 0x1
-    field public static final int FINGERPRINT_ACQUIRED_TOO_FAST = 16; // 0x10
-    field public static final int FINGERPRINT_ACQUIRED_TOO_SLOW = 8; // 0x8
-    field public static final int FINGERPRINT_ERROR = -1; // 0xffffffff
-    field public static final int FINGERPRINT_ERROR_HW_UNAVAILABLE = 1; // 0x1
-    field public static final int FINGERPRINT_ERROR_NO_RECEIVER = -10; // 0xfffffff6
-    field public static final int FINGERPRINT_ERROR_NO_SPACE = 4; // 0x4
-    field public static final int FINGERPRINT_ERROR_TIMEOUT = 3; // 0x3
-    field public static final int FINGERPRINT_ERROR_UNABLE_TO_PROCESS = 2; // 0x2
-    field public static final int FINGERPRINT_PROCESSED = 2; // 0x2
-    field public static final int FINGERPRINT_TEMPLATE_ENROLLING = 3; // 0x3
-    field public static final int FINGERPRINT_TEMPLATE_REMOVED = 4; // 0x4
+  public abstract class MediaBrowserService extends android.app.Service {
+    ctor public MediaBrowserService();
+    method public void dump(java.io.FileDescriptor, java.io.PrintWriter, java.lang.String[]);
+    method public android.media.session.MediaSession.Token getSessionToken();
+    method public void notifyChildrenChanged(java.lang.String);
+    method public android.os.IBinder onBind(android.content.Intent);
+    method public abstract android.service.media.MediaBrowserService.BrowserRoot onGetRoot(java.lang.String, int, android.os.Bundle);
+    method public abstract void onLoadChildren(java.lang.String, android.service.media.MediaBrowserService.Result<java.util.List<android.media.browse.MediaBrowser.MediaItem>>);
+    method public void setSessionToken(android.media.session.MediaSession.Token);
+    field public static final java.lang.String SERVICE_INTERFACE = "android.media.browse.MediaBrowserService";
   }
 
-  public class FingerprintManagerReceiver {
-    ctor public FingerprintManagerReceiver();
-    method public void onAcquired(int);
-    method public void onEnrollResult(int, int);
-    method public void onError(int);
-    method public void onProcessed(int);
-    method public void onRemoved(int);
+  public static final class MediaBrowserService.BrowserRoot {
+    ctor public MediaBrowserService.BrowserRoot(java.lang.String, android.os.Bundle);
+    method public android.os.Bundle getExtras();
+    method public java.lang.String getRootId();
   }
 
-  public class FingerprintUtils {
-    ctor public FingerprintUtils();
-    method public static void addFingerprintIdForUser(int, android.content.ContentResolver, int);
-    method public static int[] getFingerprintIdsForUser(android.content.ContentResolver, int);
-    method public static boolean removeFingerprintIdForUser(int, android.content.ContentResolver, int);
+  public class MediaBrowserService.Result {
+    method public void detach();
+    method public void sendResult(T);
   }
 
 }
@@ -27667,9 +26933,12 @@
     method public final void cancelNotification(java.lang.String);
     method public final void cancelNotifications(java.lang.String[]);
     method public android.service.notification.StatusBarNotification[] getActiveNotifications();
+    method public android.service.notification.StatusBarNotification[] getActiveNotifications(java.lang.String[]);
+    method public final int getCurrentInterruptionFilter();
     method public final int getCurrentListenerHints();
     method public android.service.notification.NotificationListenerService.RankingMap getCurrentRanking();
     method public android.os.IBinder onBind(android.content.Intent);
+    method public void onInterruptionFilterChanged(int);
     method public void onListenerConnected();
     method public void onListenerHintsChanged(int);
     method public void onNotificationPosted(android.service.notification.StatusBarNotification);
@@ -27677,13 +26946,12 @@
     method public void onNotificationRankingUpdate(android.service.notification.NotificationListenerService.RankingMap);
     method public void onNotificationRemoved(android.service.notification.StatusBarNotification);
     method public void onNotificationRemoved(android.service.notification.StatusBarNotification, android.service.notification.NotificationListenerService.RankingMap);
+    method public final void requestInterruptionFilter(int);
     method public final void requestListenerHints(int);
-    field public static final int HINTS_NONE = 0; // 0x0
-    field public static final int HINT_HOST_DISABLE_EFFECTS = 4; // 0x4
-    field public static final int HINT_HOST_INTERRUPTION_LEVEL_ALL = 1; // 0x1
-    field public static final int HINT_HOST_INTERRUPTION_LEVEL_NONE = 3; // 0x3
-    field public static final int HINT_HOST_INTERRUPTION_LEVEL_PRIORITY = 2; // 0x2
-    field public static final int HOST_INTERRUPTION_LEVEL_MASK = 3; // 0x3
+    field public static final int HINT_HOST_DISABLE_EFFECTS = 1; // 0x1
+    field public static final int INTERRUPTION_FILTER_ALL = 1; // 0x1
+    field public static final int INTERRUPTION_FILTER_NONE = 3; // 0x3
+    field public static final int INTERRUPTION_FILTER_PRIORITY = 2; // 0x2
     field public static final java.lang.String SERVICE_INTERFACE = "android.service.notification.NotificationListenerService";
   }
 
@@ -27692,7 +26960,7 @@
     method public java.lang.String getKey();
     method public int getRank();
     method public boolean isAmbient();
-    method public boolean meetsInterruptionFilter();
+    method public boolean matchesInterruptionFilter();
   }
 
   public static class NotificationListenerService.RankingMap implements android.os.Parcelable {
@@ -27725,6 +26993,16 @@
 
 }
 
+package android.service.restrictions {
+
+  public abstract class RestrictionsReceiver extends android.content.BroadcastReceiver {
+    ctor public RestrictionsReceiver();
+    method public void onReceive(android.content.Context, android.content.Intent);
+    method public abstract void onRequestPermission(android.content.Context, java.lang.String, java.lang.String, java.lang.String, android.os.PersistableBundle);
+  }
+
+}
+
 package android.service.textservice {
 
   public abstract class SpellCheckerService extends android.app.Service {
@@ -27751,16 +27029,14 @@
 package android.service.voice {
 
   public class AlwaysOnHotwordDetector {
-    method public android.content.Intent getManageIntent(int);
+    method public android.content.Intent createEnrollIntent();
+    method public android.content.Intent createReEnrollIntent();
+    method public android.content.Intent createUnEnrollIntent();
     method public int getSupportedRecognitionModes();
     method public boolean startRecognition(int);
     method public boolean stopRecognition();
-    field public static final int MANAGE_ACTION_ENROLL = 0; // 0x0
-    field public static final int MANAGE_ACTION_RE_ENROLL = 1; // 0x1
-    field public static final int MANAGE_ACTION_UN_ENROLL = 2; // 0x2
     field public static final int RECOGNITION_FLAG_ALLOW_MULTIPLE_TRIGGERS = 2; // 0x2
     field public static final int RECOGNITION_FLAG_CAPTURE_TRIGGER_AUDIO = 1; // 0x1
-    field public static final int RECOGNITION_FLAG_NONE = 0; // 0x0
     field public static final int RECOGNITION_MODE_USER_IDENTIFICATION = 2; // 0x2
     field public static final int RECOGNITION_MODE_VOICE_TRIGGER = 1; // 0x1
     field public static final int STATE_HARDWARE_UNAVAILABLE = -2; // 0xfffffffe
@@ -27769,7 +27045,8 @@
     field public static final int STATE_KEYPHRASE_UNSUPPORTED = -1; // 0xffffffff
   }
 
-  public static abstract interface AlwaysOnHotwordDetector.Callback {
+  public static abstract class AlwaysOnHotwordDetector.Callback {
+    ctor public AlwaysOnHotwordDetector.Callback();
     method public abstract void onAvailabilityChanged(int);
     method public abstract void onDetected(android.service.voice.AlwaysOnHotwordDetector.EventPayload);
     method public abstract void onError();
@@ -27784,7 +27061,7 @@
 
   public class VoiceInteractionService extends android.app.Service {
     ctor public VoiceInteractionService();
-    method public final android.service.voice.AlwaysOnHotwordDetector createAlwaysOnHotwordDetector(java.lang.String, java.lang.String, android.service.voice.AlwaysOnHotwordDetector.Callback);
+    method public final android.service.voice.AlwaysOnHotwordDetector createAlwaysOnHotwordDetector(java.lang.String, java.util.Locale, android.service.voice.AlwaysOnHotwordDetector.Callback);
     method public static boolean isActiveService(android.content.Context, android.content.ComponentName);
     method public android.os.IBinder onBind(android.content.Intent);
     method public void onReady();
@@ -27798,52 +27075,14 @@
     ctor public VoiceInteractionSession(android.content.Context);
     ctor public VoiceInteractionSession(android.content.Context, android.os.Handler);
     method public void finish();
-    method public android.view.LayoutInflater getLayoutInflater();
-    method public android.app.Dialog getWindow();
-    method public void hideWindow();
-    method public void onAbortVoice(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.CharSequence, android.os.Bundle);
-    method public void onBackPressed();
-    method public abstract void onCancel(android.service.voice.VoiceInteractionSession.Request);
     method public void onCloseSystemDialogs();
-    method public abstract void onCommand(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.String, android.os.Bundle);
-    method public void onCompleteVoice(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.CharSequence, android.os.Bundle);
-    method public void onComputeInsets(android.service.voice.VoiceInteractionSession.Insets);
-    method public abstract void onConfirm(android.service.voice.VoiceInteractionSession.Caller, android.service.voice.VoiceInteractionSession.Request, java.lang.CharSequence, android.os.Bundle);
     method public void onCreate(android.os.Bundle);
-    method public android.view.View onCreateContentView();
     method public void onDestroy();
-    method public boolean[] onGetSupportedCommands(android.service.voice.VoiceInteractionSession.Caller, java.lang.String[]);
     method public boolean onKeyDown(int, android.view.KeyEvent);
     method public boolean onKeyLongPress(int, android.view.KeyEvent);
     method public boolean onKeyMultiple(int, int, android.view.KeyEvent);
     method public boolean onKeyUp(int, android.view.KeyEvent);
-    method public void onTaskFinished(android.content.Intent, int);
-    method public void onTaskStarted(android.content.Intent, int);
     method public void setContentView(android.view.View);
-    method public void setTheme(int);
-    method public void showWindow();
-    method public void startVoiceActivity(android.content.Intent);
-  }
-
-  public static class VoiceInteractionSession.Caller {
-  }
-
-  public static final class VoiceInteractionSession.Insets {
-    ctor public VoiceInteractionSession.Insets();
-    field public static final int TOUCHABLE_INSETS_CONTENT = 1; // 0x1
-    field public static final int TOUCHABLE_INSETS_FRAME = 0; // 0x0
-    field public static final int TOUCHABLE_INSETS_REGION = 3; // 0x3
-    field public final android.graphics.Rect contentInsets;
-    field public int touchableInsets;
-    field public final android.graphics.Region touchableRegion;
-  }
-
-  public static class VoiceInteractionSession.Request {
-    method public void sendAbortVoiceResult(android.os.Bundle);
-    method public void sendCancelResult();
-    method public void sendCommandResult(boolean, android.os.Bundle);
-    method public void sendCompleteVoiceResult(android.os.Bundle);
-    method public void sendConfirmResult(boolean, android.os.Bundle);
   }
 
   public abstract class VoiceInteractionSessionService extends android.app.Service {
@@ -27872,6 +27111,7 @@
     method public android.view.SurfaceHolder getSurfaceHolder();
     method public boolean isPreview();
     method public boolean isVisible();
+    method public void onApplyWindowInsets(android.view.WindowInsets);
     method public android.os.Bundle onCommand(java.lang.String, int, int, int, android.os.Bundle, boolean);
     method public void onCreate(android.view.SurfaceHolder);
     method public void onDesiredSizeChanged(int, int);
@@ -28025,11 +27265,12 @@
     ctor public TextToSpeech(android.content.Context, android.speech.tts.TextToSpeech.OnInitListener);
     ctor public TextToSpeech(android.content.Context, android.speech.tts.TextToSpeech.OnInitListener, java.lang.String);
     method public int addEarcon(java.lang.String, java.lang.String, int);
-    method public int addEarcon(java.lang.String, java.lang.String);
+    method public deprecated int addEarcon(java.lang.String, java.lang.String);
+    method public int addEarcon(java.lang.String, java.io.File);
     method public int addSpeech(java.lang.String, java.lang.String, int);
     method public int addSpeech(java.lang.CharSequence, java.lang.String, int);
     method public int addSpeech(java.lang.String, java.lang.String);
-    method public int addSpeech(java.lang.CharSequence, java.lang.String);
+    method public int addSpeech(java.lang.CharSequence, java.io.File);
     method public deprecated boolean areDefaultsEnforced();
     method public java.util.Set<java.util.Locale> getAvailableLanguages();
     method public java.lang.String getDefaultEngine();
@@ -28043,7 +27284,7 @@
     method public java.util.Set<android.speech.tts.Voice> getVoices();
     method public int isLanguageAvailable(java.util.Locale);
     method public boolean isSpeaking();
-    method public int playEarcon(java.lang.String, int, java.util.HashMap<java.lang.String, java.lang.String>, java.lang.String);
+    method public int playEarcon(java.lang.String, int, android.os.Bundle, java.lang.String);
     method public deprecated int playEarcon(java.lang.String, int, java.util.HashMap<java.lang.String, java.lang.String>);
     method public int playSilence(long, int, java.util.HashMap<java.lang.String, java.lang.String>, java.lang.String);
     method public deprecated int playSilence(long, int, java.util.HashMap<java.lang.String, java.lang.String>);
@@ -28056,10 +27297,10 @@
     method public int setSpeechRate(float);
     method public int setVoice(android.speech.tts.Voice);
     method public void shutdown();
-    method public int speak(java.lang.CharSequence, int, java.util.HashMap<java.lang.String, java.lang.String>, java.lang.String);
+    method public int speak(java.lang.CharSequence, int, android.os.Bundle, java.lang.String);
     method public deprecated int speak(java.lang.String, int, java.util.HashMap<java.lang.String, java.lang.String>);
     method public int stop();
-    method public int synthesizeToFile(java.lang.CharSequence, java.util.HashMap<java.lang.String, java.lang.String>, java.lang.String, java.lang.String);
+    method public int synthesizeToFile(java.lang.CharSequence, android.os.Bundle, java.io.File, java.lang.String);
     method public deprecated int synthesizeToFile(java.lang.String, java.util.HashMap<java.lang.String, java.lang.String>, java.lang.String);
     field public static final java.lang.String ACTION_TTS_QUEUE_PROCESSING_COMPLETED = "android.speech.tts.TTS_QUEUE_PROCESSING_COMPLETED";
     field public static final int ERROR = -1; // 0xffffffff
@@ -28132,15 +27373,15 @@
 
   public abstract class TextToSpeechService extends android.app.Service {
     ctor public TextToSpeechService();
-    method protected int isValidVoiceName(java.lang.String);
     method public android.os.IBinder onBind(android.content.Intent);
     method protected java.lang.String onGetDefaultVoiceNameFor(java.lang.String, java.lang.String, java.lang.String);
     method protected java.util.Set<java.lang.String> onGetFeaturesForLanguage(java.lang.String, java.lang.String, java.lang.String);
     method protected abstract java.lang.String[] onGetLanguage();
-    method protected java.util.List<android.speech.tts.Voice> onGetVoices();
+    method public java.util.List<android.speech.tts.Voice> onGetVoices();
     method protected abstract int onIsLanguageAvailable(java.lang.String, java.lang.String, java.lang.String);
+    method public int onIsValidVoiceName(java.lang.String);
     method protected abstract int onLoadLanguage(java.lang.String, java.lang.String, java.lang.String);
-    method protected int onLoadVoice(java.lang.String);
+    method public int onLoadVoice(java.lang.String);
     method protected abstract void onStop();
     method protected abstract void onSynthesizeText(android.speech.tts.SynthesisRequest, android.speech.tts.SynthesisCallback);
   }
@@ -28161,7 +27402,7 @@
     method public java.util.Locale getLocale();
     method public java.lang.String getName();
     method public int getQuality();
-    method public boolean getRequiresNetworkConnection();
+    method public boolean isNetworkConnectionRequired();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final int LATENCY_HIGH = 400; // 0x190
     field public static final int LATENCY_LOW = 200; // 0xc8
@@ -28810,197 +28051,199 @@
 
 }
 
-package android.telecomm {
+package android.telecom {
 
   public final class AudioState implements android.os.Parcelable {
+    ctor public AudioState(boolean, int, int);
+    ctor public AudioState(android.telecom.AudioState);
     method public int describeContents();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
-    field public static int ROUTE_ALL;
-    field public static int ROUTE_BLUETOOTH;
-    field public static int ROUTE_EARPIECE;
-    field public static int ROUTE_SPEAKER;
-    field public static int ROUTE_WIRED_HEADSET;
-    field public static int ROUTE_WIRED_OR_EARPIECE;
+    field public static final int ROUTE_BLUETOOTH = 2; // 0x2
+    field public static final int ROUTE_EARPIECE = 1; // 0x1
+    field public static final int ROUTE_SPEAKER = 8; // 0x8
+    field public static final int ROUTE_WIRED_HEADSET = 4; // 0x4
+    field public static final int ROUTE_WIRED_OR_EARPIECE = 5; // 0x5
     field public final boolean isMuted;
     field public final int route;
     field public final int supportedRouteMask;
   }
 
-  public final class CameraCapabilities implements android.os.Parcelable {
-    ctor public CameraCapabilities(boolean, float, int, int);
-    method public int describeContents();
-    method public int getHeight();
-    method public float getMaxZoom();
-    method public int getWidth();
-    method public boolean isZoomSupported();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
+  public abstract class Conference {
+    ctor public Conference(android.telecom.PhoneAccountHandle);
+    method public final boolean addConnection(android.telecom.Connection);
+    method public final void destroy();
+    method public final android.telecom.AudioState getAudioState();
+    method public final int getCapabilities();
+    method public final java.util.List<android.telecom.Connection> getConnections();
+    method public final android.telecom.PhoneAccountHandle getPhoneAccountHandle();
+    method public final int getState();
+    method public void onAudioStateChanged(android.telecom.AudioState);
+    method public void onDisconnect();
+    method public void onHold();
+    method public void onMerge();
+    method public void onPlayDtmfTone(char);
+    method public void onSeparate(android.telecom.Connection);
+    method public void onStopDtmfTone();
+    method public void onSwap();
+    method public void onUnhold();
+    method public final void removeConnection(android.telecom.Connection);
+    method public final void setActive();
+    method public final void setCapabilities(int);
+    method public final void setDisconnected(android.telecom.DisconnectCause);
+    method public final void setOnHold();
   }
 
   public abstract class Connection {
     ctor public Connection();
-    method public static android.telecomm.Connection createCanceledConnection();
-    method public static android.telecomm.Connection createFailedConnection(int, java.lang.String);
+    method public static android.telecom.Connection createCanceledConnection();
+    method public static android.telecom.Connection createFailedConnection(android.telecom.DisconnectCause);
     method public final void destroy();
+    method public final android.net.Uri getAddress();
+    method public final int getAddressPresentation();
     method public final boolean getAudioModeIsVoip();
-    method public final android.telecomm.AudioState getAudioState();
+    method public final android.telecom.AudioState getAudioState();
     method public final int getCallCapabilities();
     method public final java.lang.String getCallerDisplayName();
     method public final int getCallerDisplayNamePresentation();
-    method public final java.util.List<android.telecomm.Connection> getChildConnections();
-    method public final java.util.List<android.telecomm.Connection> getConferenceableConnections();
-    method public final int getFailureCode();
-    method public final java.lang.String getFailureMessage();
-    method public final android.net.Uri getHandle();
-    method public final int getHandlePresentation();
-    method public final android.telecomm.Connection getParentConnection();
+    method public final android.telecom.Conference getConference();
+    method public final java.util.List<android.telecom.Connection> getConferenceableConnections();
+    method public final android.telecom.DisconnectCause getDisconnectCause();
     method public final int getState();
-    method public final android.telecomm.StatusHints getStatusHints();
-    method public final android.telecomm.Connection.VideoProvider getVideoProvider();
-    method public final int getVideoState();
-    method public final boolean isConferenceConnection();
-    method public final boolean isRequestingRingback();
+    method public final android.telecom.StatusHints getStatusHints();
+    method public final boolean isRingbackRequested();
     method public void onAbort();
-    method public void onAnswer(int);
-    method public void onChildrenChanged(java.util.List<android.telecomm.Connection>);
-    method public void onConferenceWith(android.telecomm.Connection);
+    method public void onAnswer();
+    method public void onAudioStateChanged(android.telecom.AudioState);
+    method public void onConferenceWith(android.telecom.Connection);
     method public void onDisconnect();
     method public void onHold();
-    method public void onPhoneAccountClicked();
     method public void onPlayDtmfTone(char);
     method public void onPostDialContinue(boolean);
     method public void onReject();
     method public void onSeparate();
-    method public void onSetAudioState(android.telecomm.AudioState);
-    method public void onSetState(int);
+    method public void onStateChanged(int);
     method public void onStopDtmfTone();
     method public void onUnhold();
     method public final void setActive();
+    method public final void setAddress(android.net.Uri, int);
     method public final void setAudioModeIsVoip(boolean);
     method public final void setCallCapabilities(int);
     method public final void setCallerDisplayName(java.lang.String, int);
-    method public final void setCanceled();
-    method public final void setConferenceableConnections(java.util.List<android.telecomm.Connection>);
+    method public final void setConferenceableConnections(java.util.List<android.telecom.Connection>);
+    method public final void setConnectionService(android.telecom.ConnectionService);
     method public final void setDialing();
-    method public final void setDisconnected(int, java.lang.String);
-    method public final void setFailed(int, java.lang.String);
-    method public final void setHandle(android.net.Uri, int);
+    method public final void setDisconnected(android.telecom.DisconnectCause);
     method public final void setInitialized();
     method public final void setInitializing();
     method public final void setOnHold();
-    method public final void setParentConnection(android.telecomm.Connection);
     method public final void setPostDialWait(java.lang.String);
-    method public final void setRequestingRingback(boolean);
+    method public final void setRingbackRequested(boolean);
     method public final void setRinging();
-    method public final void setStatusHints(android.telecomm.StatusHints);
-    method public final void setVideoProvider(android.telecomm.Connection.VideoProvider);
-    method public final void setVideoState(int);
-    method public final void startActivityFromInCall(android.app.PendingIntent);
+    method public final void setStatusHints(android.telecom.StatusHints);
     method public static java.lang.String stateToString(int);
     field public static final int STATE_ACTIVE = 4; // 0x4
-    field public static final int STATE_CANCELED = 8; // 0x8
     field public static final int STATE_DIALING = 3; // 0x3
     field public static final int STATE_DISCONNECTED = 6; // 0x6
-    field public static final int STATE_FAILED = 7; // 0x7
     field public static final int STATE_HOLDING = 5; // 0x5
     field public static final int STATE_INITIALIZING = 0; // 0x0
     field public static final int STATE_NEW = 1; // 0x1
     field public static final int STATE_RINGING = 2; // 0x2
   }
 
-  public static abstract class Connection.VideoProvider {
-    ctor public Connection.VideoProvider();
-    method public void changeCallDataUsage(int);
-    method public void changeCameraCapabilities(android.telecomm.CameraCapabilities);
-    method public void changePeerDimensions(int, int);
-    method public void handleCallSessionEvent(int);
-    method public abstract void onRequestCallDataUsage();
-    method public abstract void onRequestCameraCapabilities();
-    method public abstract void onSendSessionModifyRequest(android.telecomm.VideoProfile);
-    method public abstract void onSendSessionModifyResponse(android.telecomm.VideoProfile);
-    method public abstract void onSetCamera(java.lang.String);
-    method public abstract void onSetDeviceOrientation(int);
-    method public abstract void onSetDisplaySurface(android.view.Surface);
-    method public abstract void onSetPauseImage(java.lang.String);
-    method public abstract void onSetPreviewSurface(android.view.Surface);
-    method public abstract void onSetZoom(float);
-    method public void receiveSessionModifyRequest(android.telecomm.VideoProfile);
-    method public void receiveSessionModifyResponse(int, android.telecomm.VideoProfile, android.telecomm.VideoProfile);
-    field public static final int SESSION_EVENT_CAMERA_FAILURE = 5; // 0x5
-    field public static final int SESSION_EVENT_CAMERA_READY = 6; // 0x6
-    field public static final int SESSION_EVENT_RX_PAUSE = 1; // 0x1
-    field public static final int SESSION_EVENT_RX_RESUME = 2; // 0x2
-    field public static final int SESSION_EVENT_TX_START = 3; // 0x3
-    field public static final int SESSION_EVENT_TX_STOP = 4; // 0x4
-    field public static final int SESSION_MODIFY_REQUEST_FAIL = 2; // 0x2
-    field public static final int SESSION_MODIFY_REQUEST_INVALID = 3; // 0x3
-    field public static final int SESSION_MODIFY_REQUEST_SUCCESS = 1; // 0x1
-  }
-
   public final class ConnectionRequest implements android.os.Parcelable {
-    ctor public ConnectionRequest(android.telecomm.PhoneAccountHandle, android.net.Uri, int, android.os.Bundle, int);
+    ctor public ConnectionRequest(android.telecom.PhoneAccountHandle, android.net.Uri, android.os.Bundle);
     method public int describeContents();
-    method public android.telecomm.PhoneAccountHandle getAccountHandle();
+    method public android.telecom.PhoneAccountHandle getAccountHandle();
+    method public android.net.Uri getAddress();
     method public android.os.Bundle getExtras();
-    method public android.net.Uri getHandle();
-    method public int getHandlePresentation();
-    method public int getVideoState();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public abstract class ConnectionService extends android.app.Service {
     ctor public ConnectionService();
-    method public final android.telecomm.RemoteConnection createRemoteIncomingConnection(android.telecomm.PhoneAccountHandle, android.telecomm.ConnectionRequest);
-    method public final android.telecomm.RemoteConnection createRemoteOutgoingConnection(android.telecomm.PhoneAccountHandle, android.telecomm.ConnectionRequest);
-    method public final java.util.Collection<android.telecomm.Connection> getAllConnections();
+    method public final void addConference(android.telecom.Conference);
+    method public final void conferenceRemoteConnections(android.telecom.RemoteConnection, android.telecom.RemoteConnection);
+    method public final android.telecom.RemoteConnection createRemoteIncomingConnection(android.telecom.PhoneAccountHandle, android.telecom.ConnectionRequest);
+    method public final android.telecom.RemoteConnection createRemoteOutgoingConnection(android.telecom.PhoneAccountHandle, android.telecom.ConnectionRequest);
+    method public final java.util.Collection<android.telecom.Connection> getAllConnections();
     method public final android.os.IBinder onBind(android.content.Intent);
-    method public void onConnectionAdded(android.telecomm.Connection);
-    method public void onConnectionRemoved(android.telecomm.Connection);
-    method public void onCreateConferenceConnection(java.lang.String, android.telecomm.Connection, android.telecomm.Response<java.lang.String, android.telecomm.Connection>);
-    method public android.telecomm.Connection onCreateIncomingConnection(android.telecomm.PhoneAccountHandle, android.telecomm.ConnectionRequest);
-    method public android.telecomm.Connection onCreateOutgoingConnection(android.telecomm.PhoneAccountHandle, android.telecomm.ConnectionRequest);
-    field public static final java.lang.String SERVICE_INTERFACE = "android.telecomm.ConnectionService";
+    method public void onConference(android.telecom.Connection, android.telecom.Connection);
+    method public android.telecom.Connection onCreateIncomingConnection(android.telecom.PhoneAccountHandle, android.telecom.ConnectionRequest);
+    method public android.telecom.Connection onCreateOutgoingConnection(android.telecom.PhoneAccountHandle, android.telecom.ConnectionRequest);
+    method public void onRemoteConferenceAdded(android.telecom.RemoteConference);
+    field public static final java.lang.String SERVICE_INTERFACE = "android.telecom.ConnectionService";
+  }
+
+  public final class DisconnectCause implements android.os.Parcelable {
+    ctor public DisconnectCause(int);
+    ctor public DisconnectCause(int, java.lang.String);
+    ctor public DisconnectCause(int, java.lang.CharSequence, java.lang.CharSequence, java.lang.String, int);
+    method public int describeContents();
+    method public int getCode();
+    method public java.lang.CharSequence getDescription();
+    method public java.lang.CharSequence getLabel();
+    method public java.lang.String getReason();
+    method public int getTone();
+    method public void writeToParcel(android.os.Parcel, int);
+    field public static final int BUSY = 7; // 0x7
+    field public static final int CANCELED = 4; // 0x4
+    field public static final android.os.Parcelable.Creator CREATOR;
+    field public static final int ERROR = 1; // 0x1
+    field public static final int LOCAL = 2; // 0x2
+    field public static final int MISSED = 5; // 0x5
+    field public static final int OTHER = 9; // 0x9
+    field public static final int REJECTED = 6; // 0x6
+    field public static final int REMOTE = 3; // 0x3
+    field public static final int RESTRICTED = 8; // 0x8
+    field public static final int UNKNOWN = 0; // 0x0
   }
 
   public class GatewayInfo implements android.os.Parcelable {
     method public int describeContents();
-    method public android.net.Uri getGatewayHandle();
+    method public android.net.Uri getGatewayAddress();
     method public java.lang.String getGatewayProviderPackageName();
-    method public android.net.Uri getOriginalHandle();
+    method public android.net.Uri getOriginalAddress();
     method public boolean isEmpty();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
   public class PhoneAccount implements android.os.Parcelable {
-    method public static android.telecomm.PhoneAccount.Builder builder();
+    method public static android.telecom.PhoneAccount.Builder builder(android.telecom.PhoneAccountHandle, java.lang.CharSequence);
     method public int describeContents();
-    method public android.telecomm.PhoneAccountHandle getAccountHandle();
+    method public android.telecom.PhoneAccountHandle getAccountHandle();
+    method public android.net.Uri getAddress();
     method public int getCapabilities();
-    method public android.net.Uri getHandle();
     method public android.graphics.drawable.Drawable getIcon(android.content.Context);
     method public int getIconResId();
     method public java.lang.CharSequence getLabel();
     method public java.lang.CharSequence getShortDescription();
-    method public java.lang.String getSubscriptionNumber();
+    method public android.net.Uri getSubscriptionAddress();
+    method public java.util.List<java.lang.String> getSupportedUriSchemes();
+    method public boolean hasCapabilities(int);
+    method public boolean supportsUriScheme(java.lang.String);
     method public void writeToParcel(android.os.Parcel, int);
     field public static final int CAPABILITY_CONNECTION_MANAGER = 1; // 0x1
+    field public static final int CAPABILITY_PLACE_EMERGENCY_CALLS = 16; // 0x10
     field public static final int CAPABILITY_SIM_SUBSCRIPTION = 4; // 0x4
-    field public static final int CAPABILITY_VIDEO_CALLING = 8; // 0x8
     field public static final android.os.Parcelable.Creator CREATOR;
+    field public static final java.lang.String SCHEME_SIP = "sip";
+    field public static final java.lang.String SCHEME_TEL = "tel";
+    field public static final java.lang.String SCHEME_VOICEMAIL = "voicemail";
   }
 
   public static class PhoneAccount.Builder {
-    method public android.telecomm.PhoneAccount build();
-    method public android.telecomm.PhoneAccount.Builder withAccountHandle(android.telecomm.PhoneAccountHandle);
-    method public android.telecomm.PhoneAccount.Builder withCapabilities(int);
-    method public android.telecomm.PhoneAccount.Builder withHandle(android.net.Uri);
-    method public android.telecomm.PhoneAccount.Builder withIconResId(int);
-    method public android.telecomm.PhoneAccount.Builder withLabel(java.lang.CharSequence);
-    method public android.telecomm.PhoneAccount.Builder withShortDescription(java.lang.CharSequence);
-    method public android.telecomm.PhoneAccount.Builder withSubscriptionNumber(java.lang.String);
+    ctor public PhoneAccount.Builder(android.telecom.PhoneAccountHandle, java.lang.CharSequence);
+    ctor public PhoneAccount.Builder(android.telecom.PhoneAccount);
+    method public android.telecom.PhoneAccount build();
+    method public android.telecom.PhoneAccount.Builder setAddress(android.net.Uri);
+    method public android.telecom.PhoneAccount.Builder setCapabilities(int);
+    method public android.telecom.PhoneAccount.Builder setIconResId(int);
+    method public android.telecom.PhoneAccount.Builder setShortDescription(java.lang.CharSequence);
+    method public android.telecom.PhoneAccount.Builder setSubscriptionAddress(android.net.Uri);
+    method public android.telecom.PhoneAccount.Builder setSupportedUriSchemes(java.util.List<java.lang.String>);
   }
 
   public class PhoneAccountHandle implements android.os.Parcelable {
@@ -29015,143 +28258,129 @@
   public final class PhoneCapabilities {
     method public static java.lang.String toString(int);
     field public static final int ADD_CALL = 16; // 0x10
-    field public static final int ALL = 3327; // 0xcff
-    field public static final int GENERIC_CONFERENCE = 128; // 0x80
+    field public static final int ALL = 12543; // 0x30ff
+    field public static final int DISCONNECT_FROM_CONFERENCE = 8192; // 0x2000
     field public static final int HOLD = 1; // 0x1
-    field public static final int MERGE_CALLS = 4; // 0x4
+    field public static final int MANAGE_CONFERENCE = 128; // 0x80
+    field public static final int MERGE_CONFERENCE = 4; // 0x4
     field public static final int MUTE = 64; // 0x40
     field public static final int RESPOND_VIA_TEXT = 32; // 0x20
-    field public static final int SUPPORTS_VT_LOCAL = 256; // 0x100
-    field public static final int SUPPORTS_VT_REMOTE = 512; // 0x200
+    field public static final int SEPARATE_FROM_CONFERENCE = 4096; // 0x1000
     field public static final int SUPPORT_HOLD = 2; // 0x2
-    field public static final int SWAP_CALLS = 8; // 0x8
-    field public static final int VoLTE = 1024; // 0x400
-    field public static final int VoWIFI = 2048; // 0x800
+    field public static final int SWAP_CONFERENCE = 8; // 0x8
   }
 
-  public class PropertyPresentation {
-    ctor public PropertyPresentation();
-    field public static final int ALLOWED = 1; // 0x1
-    field public static final int PAYPHONE = 4; // 0x4
-    field public static final int RESTRICTED = 2; // 0x2
-    field public static final int UNKNOWN = 3; // 0x3
+  public final class RemoteConference {
+    method public void disconnect();
+    method public final int getCallCapabilities();
+    method public final java.util.List<android.telecom.RemoteConnection> getConnections();
+    method public android.telecom.DisconnectCause getDisconnectCause();
+    method public final int getState();
+    method public void hold();
+    method public void playDtmfTone(char);
+    method public final void registerCallback(android.telecom.RemoteConference.Callback);
+    method public void separate(android.telecom.RemoteConnection);
+    method public void setAudioState(android.telecom.AudioState);
+    method public void stopDtmfTone();
+    method public void unhold();
+    method public final void unregisterCallback(android.telecom.RemoteConference.Callback);
+  }
+
+  public static abstract class RemoteConference.Callback {
+    ctor public RemoteConference.Callback();
+    method public void onCapabilitiesChanged(android.telecom.RemoteConference, int);
+    method public void onConnectionAdded(android.telecom.RemoteConference, android.telecom.RemoteConnection);
+    method public void onConnectionRemoved(android.telecom.RemoteConference, android.telecom.RemoteConnection);
+    method public void onDestroyed(android.telecom.RemoteConference);
+    method public void onDisconnected(android.telecom.RemoteConference, android.telecom.DisconnectCause);
+    method public void onStateChanged(android.telecom.RemoteConference, int, int);
   }
 
   public final class RemoteConnection {
     method public void abort();
-    method public void addListener(android.telecomm.RemoteConnection.Listener);
-    method public void answer(int);
+    method public void answer();
     method public void disconnect();
-    method public boolean getAudioModeIsVoip();
+    method public android.net.Uri getAddress();
+    method public int getAddressPresentation();
     method public int getCallCapabilities();
-    method public java.lang.String getCallerDisplayName();
+    method public java.lang.CharSequence getCallerDisplayName();
     method public int getCallerDisplayNamePresentation();
-    method public java.util.List<android.telecomm.RemoteConnection> getChildren();
-    method public int getDisconnectCauseCode();
-    method public java.lang.String getDisconnectCauseMessage();
-    method public int getFailureCode();
-    method public java.lang.String getFailureMessage();
-    method public android.net.Uri getHandle();
-    method public int getHandlePresentation();
-    method public android.telecomm.RemoteConnection getParent();
+    method public android.telecom.RemoteConference getConference();
+    method public java.util.List<android.telecom.RemoteConnection> getConferenceableConnections();
+    method public android.telecom.DisconnectCause getDisconnectCause();
     method public int getState();
-    method public android.telecomm.StatusHints getStatusHints();
-    method public int getVideoState();
+    method public android.telecom.StatusHints getStatusHints();
     method public void hold();
-    method public boolean isRequestingRingback();
+    method public boolean isRingbackRequested();
+    method public boolean isVoipAudioMode();
     method public void playDtmfTone(char);
     method public void postDialContinue(boolean);
+    method public void registerCallback(android.telecom.RemoteConnection.Callback);
     method public void reject();
-    method public void removeListener(android.telecomm.RemoteConnection.Listener);
-    method public void setAudioState(android.telecomm.AudioState);
+    method public void setAudioState(android.telecom.AudioState);
     method public void stopDtmfTone();
     method public void unhold();
+    method public void unregisterCallback(android.telecom.RemoteConnection.Callback);
   }
 
-  public static abstract class RemoteConnection.Listener {
-    ctor public RemoteConnection.Listener();
-    method public void onAudioModeIsVoipChanged(android.telecomm.RemoteConnection, boolean);
-    method public void onCallCapabilitiesChanged(android.telecomm.RemoteConnection, int);
-    method public void onCallerDisplayNameChanged(android.telecomm.RemoteConnection, java.lang.String, int);
-    method public void onChildrenChanged(android.telecomm.RemoteConnection, java.util.List<android.telecomm.RemoteConnection>);
-    method public void onConferenceableConnectionsChanged(android.telecomm.RemoteConnection, java.util.List<android.telecomm.RemoteConnection>);
-    method public void onDestroyed(android.telecomm.RemoteConnection);
-    method public void onDisconnected(android.telecomm.RemoteConnection, int, java.lang.String);
-    method public void onHandleChanged(android.telecomm.RemoteConnection, android.net.Uri, int);
-    method public void onParentChanged(android.telecomm.RemoteConnection, android.telecomm.RemoteConnection);
-    method public void onPostDialWait(android.telecomm.RemoteConnection, java.lang.String);
-    method public void onRequestingRingback(android.telecomm.RemoteConnection, boolean);
-    method public void onStartActivityFromInCall(android.telecomm.RemoteConnection, android.app.PendingIntent);
-    method public void onStateChanged(android.telecomm.RemoteConnection, int);
-    method public void onStatusHintsChanged(android.telecomm.RemoteConnection, android.telecomm.StatusHints);
-    method public void onVideoStateChanged(android.telecomm.RemoteConnection, int);
-  }
-
-  public abstract interface Response {
-    method public abstract void onError(IN, int, java.lang.String);
-    method public abstract void onResult(IN, OUT...);
+  public static abstract class RemoteConnection.Callback {
+    ctor public RemoteConnection.Callback();
+    method public void onAddressChanged(android.telecom.RemoteConnection, android.net.Uri, int);
+    method public void onCallCapabilitiesChanged(android.telecom.RemoteConnection, int);
+    method public void onCallerDisplayNameChanged(android.telecom.RemoteConnection, java.lang.String, int);
+    method public void onConferenceChanged(android.telecom.RemoteConnection, android.telecom.RemoteConference);
+    method public void onConferenceableConnectionsChanged(android.telecom.RemoteConnection, java.util.List<android.telecom.RemoteConnection>);
+    method public void onDestroyed(android.telecom.RemoteConnection);
+    method public void onDisconnected(android.telecom.RemoteConnection, android.telecom.DisconnectCause);
+    method public void onPostDialWait(android.telecom.RemoteConnection, java.lang.String);
+    method public void onRingbackRequested(android.telecom.RemoteConnection, boolean);
+    method public void onStateChanged(android.telecom.RemoteConnection, int);
+    method public void onStatusHintsChanged(android.telecom.RemoteConnection, android.telecom.StatusHints);
+    method public void onVoipAudioChanged(android.telecom.RemoteConnection, boolean);
   }
 
   public final class StatusHints implements android.os.Parcelable {
     ctor public StatusHints(android.content.ComponentName, java.lang.CharSequence, int, android.os.Bundle);
     method public int describeContents();
-    method public android.content.ComponentName getComponentName();
     method public android.os.Bundle getExtras();
     method public android.graphics.drawable.Drawable getIcon(android.content.Context);
     method public int getIconResId();
     method public java.lang.CharSequence getLabel();
+    method public android.content.ComponentName getPackageName();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
-  public class TelecommManager {
-    method public void addNewIncomingCall(android.telecomm.PhoneAccountHandle, android.os.Bundle);
-    method public void clearAccounts(java.lang.String);
-    method public android.telecomm.PhoneAccountHandle getDefaultOutgoingPhoneAccount();
-    method public java.util.List<android.telecomm.PhoneAccountHandle> getEnabledPhoneAccounts();
-    method public android.telecomm.PhoneAccount getPhoneAccount(android.telecomm.PhoneAccountHandle);
-    method public boolean hasMultipleEnabledAccounts();
-    method public void registerPhoneAccount(android.telecomm.PhoneAccount);
-    method public void unregisterPhoneAccount(android.telecomm.PhoneAccountHandle);
-    field public static final java.lang.String ACTION_CONNECTION_SERVICE_CONFIGURE = "android.intent.action.CONNECTION_SERVICE_CONFIGURE";
-    field public static final java.lang.String ACTION_SHOW_CALL_SETTINGS = "android.telecomm.intent.action.SHOW_CALL_SETTINGS";
+  public class TelecomManager {
+    method public void addNewIncomingCall(android.telecom.PhoneAccountHandle, android.os.Bundle);
+    method public void cancelMissedCallsNotification();
+    method public void clearAccounts();
+    method public android.telecom.PhoneAccountHandle getConnectionManager();
+    method public android.telecom.PhoneAccount getPhoneAccount(android.telecom.PhoneAccountHandle);
+    method public java.util.List<android.telecom.PhoneAccountHandle> getPhoneAccountsForPackage();
+    method public boolean handleMmi(java.lang.String);
+    method public boolean hasMultipleCallCapableAccounts();
+    method public boolean isInCall();
+    method public void registerPhoneAccount(android.telecom.PhoneAccount);
+    method public void showInCallScreen(boolean);
+    method public void unregisterPhoneAccount(android.telecom.PhoneAccountHandle);
+    field public static final java.lang.String ACTION_CHANGE_PHONE_ACCOUNTS = "android.telecom.action.CHANGE_PHONE_ACCOUNTS";
+    field public static final java.lang.String ACTION_CONNECTION_SERVICE_CONFIGURE = "android.telecom.action.CONNECTION_SERVICE_CONFIGURE";
+    field public static final java.lang.String ACTION_SHOW_CALL_SETTINGS = "android.telecom.action.SHOW_CALL_SETTINGS";
     field public static final char DTMF_CHARACTER_PAUSE = 44; // 0x002c ','
     field public static final char DTMF_CHARACTER_WAIT = 59; // 0x003b ';'
-    field public static final java.lang.String EXTRA_CALL_BACK_NUMBER = "android.telecomm.extra.CALL_BACK_NUMBER";
-    field public static final java.lang.String EXTRA_CALL_DISCONNECT_CAUSE = "android.telecomm.extra.CALL_DISCONNECT_CAUSE";
-    field public static final java.lang.String EXTRA_CALL_DISCONNECT_MESSAGE = "android.telecomm.extra.CALL_DISCONNECT_MESSAGE";
-    field public static final java.lang.String EXTRA_CONNECTION_SERVICE = "android.telecomm.extra.CONNECTION_SERVICE";
-    field public static final java.lang.String EXTRA_PHONE_ACCOUNT_HANDLE = "android.intent.extra.PHONE_ACCOUNT_HANDLE";
-    field public static final java.lang.String EXTRA_START_CALL_WITH_SPEAKERPHONE = "android.intent.extra.START_CALL_WITH_SPEAKERPHONE";
-    field public static final java.lang.String EXTRA_START_CALL_WITH_VIDEO_STATE = "android.intent.extra.START_CALL_WITH_VIDEO_STATE";
-  }
-
-  public class VideoProfile implements android.os.Parcelable {
-    ctor public VideoProfile(int);
-    ctor public VideoProfile(int, int);
-    method public int describeContents();
-    method public int getQuality();
-    method public int getVideoState();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-    field public static final int QUALITY_DEFAULT = 4; // 0x4
-    field public static final int QUALITY_HIGH = 1; // 0x1
-    field public static final int QUALITY_LOW = 3; // 0x3
-    field public static final int QUALITY_MEDIUM = 2; // 0x2
-  }
-
-  public static class VideoProfile.VideoState {
-    ctor public VideoProfile.VideoState();
-    method public static boolean isAudioOnly(int);
-    method public static boolean isBidirectional(int);
-    method public static boolean isPaused(int);
-    method public static boolean isReceptionEnabled(int);
-    method public static boolean isTransmissionEnabled(int);
-    field public static final int AUDIO_ONLY = 0; // 0x0
-    field public static final int BIDIRECTIONAL = 3; // 0x3
-    field public static final int PAUSED = 4; // 0x4
-    field public static final int RX_ENABLED = 2; // 0x2
-    field public static final int TX_ENABLED = 1; // 0x1
+    field public static final java.lang.String EXTRA_CALL_BACK_NUMBER = "android.telecom.extra.CALL_BACK_NUMBER";
+    field public static final java.lang.String EXTRA_CALL_DISCONNECT_CAUSE = "android.telecom.extra.CALL_DISCONNECT_CAUSE";
+    field public static final java.lang.String EXTRA_CALL_DISCONNECT_MESSAGE = "android.telecom.extra.CALL_DISCONNECT_MESSAGE";
+    field public static final java.lang.String EXTRA_CONNECTION_SERVICE = "android.telecom.extra.CONNECTION_SERVICE";
+    field public static final java.lang.String EXTRA_PHONE_ACCOUNT_HANDLE = "android.telecom.extra.PHONE_ACCOUNT_HANDLE";
+    field public static final java.lang.String EXTRA_START_CALL_WITH_SPEAKERPHONE = "android.telecom.extra.START_CALL_WITH_SPEAKERPHONE";
+    field public static final java.lang.String GATEWAY_ORIGINAL_ADDRESS = "android.telecom.extra.GATEWAY_ORIGINAL_ADDRESS";
+    field public static final java.lang.String GATEWAY_PROVIDER_PACKAGE = "android.telecom.extra.GATEWAY_PROVIDER_PACKAGE";
+    field public static final int PRESENTATION_ALLOWED = 1; // 0x1
+    field public static final int PRESENTATION_PAYPHONE = 4; // 0x4
+    field public static final int PRESENTATION_RESTRICTED = 2; // 0x2
+    field public static final int PRESENTATION_UNKNOWN = 3; // 0x3
   }
 
 }
@@ -29304,57 +28533,6 @@
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
-  public class DisconnectCause {
-    method public static java.lang.String toString(int);
-    field public static final int BUSY = 4; // 0x4
-    field public static final int CALL_BARRED = 20; // 0x14
-    field public static final int CDMA_ACCESS_BLOCKED = 35; // 0x23
-    field public static final int CDMA_ACCESS_FAILURE = 32; // 0x20
-    field public static final int CDMA_CALL_LOST = 41; // 0x29
-    field public static final int CDMA_DROP = 27; // 0x1b
-    field public static final int CDMA_INTERCEPT = 28; // 0x1c
-    field public static final int CDMA_LOCKED_UNTIL_POWER_CYCLE = 26; // 0x1a
-    field public static final int CDMA_NOT_EMERGENCY = 34; // 0x22
-    field public static final int CDMA_PREEMPTED = 33; // 0x21
-    field public static final int CDMA_REORDER = 29; // 0x1d
-    field public static final int CDMA_RETRY_ORDER = 31; // 0x1f
-    field public static final int CDMA_SO_REJECT = 30; // 0x1e
-    field public static final int CONGESTION = 5; // 0x5
-    field public static final int CS_RESTRICTED = 22; // 0x16
-    field public static final int CS_RESTRICTED_EMERGENCY = 24; // 0x18
-    field public static final int CS_RESTRICTED_NORMAL = 23; // 0x17
-    field public static final int DIALED_MMI = 39; // 0x27
-    field public static final int EMERGENCY_ONLY = 37; // 0x25
-    field public static final int ERROR_UNSPECIFIED = 36; // 0x24
-    field public static final int FDN_BLOCKED = 21; // 0x15
-    field public static final int ICC_ERROR = 19; // 0x13
-    field public static final int INCOMING_MISSED = 1; // 0x1
-    field public static final int INCOMING_REJECTED = 16; // 0x10
-    field public static final int INVALID_CREDENTIALS = 10; // 0xa
-    field public static final int INVALID_NUMBER = 7; // 0x7
-    field public static final int LIMIT_EXCEEDED = 15; // 0xf
-    field public static final int LOCAL = 3; // 0x3
-    field public static final int LOST_SIGNAL = 14; // 0xe
-    field public static final int MAXIMUM_VALID_VALUE = 44; // 0x2c
-    field public static final int MINIMUM_VALID_VALUE = 0; // 0x0
-    field public static final int MMI = 6; // 0x6
-    field public static final int NORMAL = 2; // 0x2
-    field public static final int NOT_DISCONNECTED = 0; // 0x0
-    field public static final int NOT_VALID = -1; // 0xffffffff
-    field public static final int NO_PHONE_NUMBER_SUPPLIED = 38; // 0x26
-    field public static final int NUMBER_UNREACHABLE = 8; // 0x8
-    field public static final int OUTGOING_CANCELED = 44; // 0x2c
-    field public static final int OUTGOING_FAILURE = 43; // 0x2b
-    field public static final int OUT_OF_NETWORK = 11; // 0xb
-    field public static final int OUT_OF_SERVICE = 18; // 0x12
-    field public static final int POWER_OFF = 17; // 0x11
-    field public static final int SERVER_ERROR = 12; // 0xc
-    field public static final int SERVER_UNREACHABLE = 9; // 0x9
-    field public static final int TIMED_OUT = 13; // 0xd
-    field public static final int UNOBTAINABLE_NUMBER = 25; // 0x19
-    field public static final int VOICEMAIL_NUMBER_MISSING = 40; // 0x28
-  }
-
   public class IccOpenLogicalChannelResponse implements android.os.Parcelable {
     method public int describeContents();
     method public int getChannel();
@@ -29362,49 +28540,11 @@
     method public int getStatus();
     method public void writeToParcel(android.os.Parcel, int);
     field public static final android.os.Parcelable.Creator CREATOR;
-    field public static int INVALID_CHANNEL;
-    field public static int MISSING_RESOURCE;
-    field public static int NO_ERROR;
-    field public static int NO_SUCH_ELEMENT;
-    field public static int UNKNOWN_ERROR;
-  }
-
-  public class MessagingConfigurationManager {
-    method public boolean getCarrierConfigBoolean(java.lang.String, boolean);
-    method public boolean getCarrierConfigBoolean(long, java.lang.String, boolean);
-    method public int getCarrierConfigInt(java.lang.String, int);
-    method public int getCarrierConfigInt(long, java.lang.String, int);
-    method public java.lang.String getCarrierConfigString(java.lang.String, java.lang.String);
-    method public java.lang.String getCarrierConfigString(long, java.lang.String, java.lang.String);
-    method public static android.telephony.MessagingConfigurationManager getDefault();
-    field public static final java.lang.String CONF_ALIAS_ENABLED = "aliasEnabled";
-    field public static final java.lang.String CONF_ALIAS_MAX_CHARS = "aliasMaxChars";
-    field public static final java.lang.String CONF_ALIAS_MIN_CHARS = "aliasMinChars";
-    field public static final java.lang.String CONF_ALLOW_ATTACH_AUDIO = "allowAttachAudio";
-    field public static final java.lang.String CONF_APPEND_TRANSACTION_ID = "enabledTransID";
-    field public static final java.lang.String CONF_EMAIL_GATEWAY_NUMBER = "emailGatewayNumber";
-    field public static final java.lang.String CONF_HTTP_PARAMS = "httpParams";
-    field public static final java.lang.String CONF_HTTP_SOCKET_TIMEOUT = "httpSocketTimeout";
-    field public static final java.lang.String CONF_MAX_IMAGE_HEIGHT = "maxImageHeight";
-    field public static final java.lang.String CONF_MAX_IMAGE_WIDTH = "maxImageWidth";
-    field public static final java.lang.String CONF_MAX_MESSAGE_SIZE = "maxMessageSize";
-    field public static final java.lang.String CONF_MESSAGE_TEXT_MAX_SIZE = "maxMessageTextSize";
-    field public static final java.lang.String CONF_MMS_DELIVERY_REPORT_ENABLED = "enableMMSDeliveryReports";
-    field public static final java.lang.String CONF_MMS_ENABLED = "enabledMMS";
-    field public static final java.lang.String CONF_MMS_READ_REPORT_ENABLED = "enableMMSReadReports";
-    field public static final java.lang.String CONF_MULTIPART_SMS_ENABLED = "enableMultipartSMS";
-    field public static final java.lang.String CONF_NAI_SUFFIX = "naiSuffix";
-    field public static final java.lang.String CONF_NOTIFY_WAP_MMSC_ENABLED = "enabledNotifyWapMMSC";
-    field public static final java.lang.String CONF_RECIPIENT_LIMIT = "recipientLimit";
-    field public static final java.lang.String CONF_SEND_MULTIPART_SMS_AS_SEPARATE_MESSAGES = "sendMultipartSmsAsSeparateMessages";
-    field public static final java.lang.String CONF_SMS_DELIVERY_REPORT_ENABLED = "enableSMSDeliveryReports";
-    field public static final java.lang.String CONF_SMS_TO_MMS_TEXT_LENGTH_THRESHOLD = "smsToMmsTextLengthThreshold";
-    field public static final java.lang.String CONF_SMS_TO_MMS_TEXT_THRESHOLD = "smsToMmsTextThreshold";
-    field public static final java.lang.String CONF_SUBJECT_MAX_LENGTH = "maxSubjectLength";
-    field public static final java.lang.String CONF_SUPPORT_MMS_CONTENT_DISPOSITION = "supportMmsContentDisposition";
-    field public static final java.lang.String CONF_UA_PROF_TAG_NAME = "uaProfTagName";
-    field public static final java.lang.String CONF_UA_PROF_URL = "uaProfUrl";
-    field public static final java.lang.String CONF_USER_AGENT = "userAgent";
+    field public static final int INVALID_CHANNEL = -1; // 0xffffffff
+    field public static final int STATUS_MISSING_RESOURCE = 2; // 0x2
+    field public static final int STATUS_NO_ERROR = 1; // 0x1
+    field public static final int STATUS_NO_SUCH_ELEMENT = 3; // 0x3
+    field public static final int STATUS_UNKNOWN_ERROR = 4; // 0x4
   }
 
   public class NeighboringCellInfo implements android.os.Parcelable {
@@ -29549,48 +28689,59 @@
   }
 
   public final class SmsManager {
-    method public android.net.Uri addMultimediaMessageDraft(byte[]);
-    method public android.net.Uri addTextMessageDraft(java.lang.String, java.lang.String);
-    method public boolean archiveStoredConversation(long, boolean);
-    method public boolean deleteStoredConversation(long);
-    method public boolean deleteStoredMessage(android.net.Uri);
     method public java.util.ArrayList<java.lang.String> divideMessage(java.lang.String);
-    method public void downloadMultimediaMessage(java.lang.String, android.content.ContentValues, android.app.PendingIntent);
-    method public void downloadMultimediaMessage(long, java.lang.String, android.content.ContentValues, android.app.PendingIntent);
-    method public boolean getAutoPersisting();
+    method public void downloadMultimediaMessage(android.content.Context, java.lang.String, android.net.Uri, android.os.Bundle, android.app.PendingIntent);
+    method public android.os.Bundle getCarrierConfigValues();
     method public static android.telephony.SmsManager getDefault();
-    method public android.net.Uri importMultimediaMessage(byte[], java.lang.String, long, boolean, boolean);
-    method public android.net.Uri importTextMessage(java.lang.String, int, java.lang.String, long, boolean, boolean);
     method public void injectSmsPdu(byte[], java.lang.String, android.app.PendingIntent);
     method public void sendDataMessage(java.lang.String, java.lang.String, short, byte[], android.app.PendingIntent, android.app.PendingIntent);
-    method public void sendMultimediaMessage(byte[], java.lang.String, android.content.ContentValues, android.app.PendingIntent);
-    method public void sendMultimediaMessage(long, byte[], java.lang.String, android.content.ContentValues, android.app.PendingIntent);
+    method public void sendMultimediaMessage(android.content.Context, android.net.Uri, java.lang.String, android.os.Bundle, android.app.PendingIntent);
     method public void sendMultipartTextMessage(java.lang.String, java.lang.String, java.util.ArrayList<java.lang.String>, java.util.ArrayList<android.app.PendingIntent>, java.util.ArrayList<android.app.PendingIntent>);
-    method public void sendStoredMultimediaMessage(android.net.Uri, android.content.ContentValues, android.app.PendingIntent);
-    method public void sendStoredMultimediaMessage(long, android.net.Uri, android.content.ContentValues, android.app.PendingIntent);
-    method public void sendStoredMultipartTextMessage(android.net.Uri, java.lang.String, java.util.ArrayList<android.app.PendingIntent>, java.util.ArrayList<android.app.PendingIntent>);
-    method public void sendStoredMultipartTextMessage(long, android.net.Uri, java.lang.String, java.util.ArrayList<android.app.PendingIntent>, java.util.ArrayList<android.app.PendingIntent>);
-    method public void sendStoredTextMessage(android.net.Uri, java.lang.String, android.app.PendingIntent, android.app.PendingIntent);
-    method public void sendStoredTextMessage(long, android.net.Uri, java.lang.String, android.app.PendingIntent, android.app.PendingIntent);
     method public void sendTextMessage(java.lang.String, java.lang.String, java.lang.String, android.app.PendingIntent, android.app.PendingIntent);
-    method public void setAutoPersisting(boolean);
-    method public void updateMmsDownloadStatus(int, byte[]);
-    method public void updateMmsSendStatus(int, boolean);
+    method public void updateMmsDownloadStatus(android.content.Context, int, int, android.net.Uri);
+    method public void updateMmsSendStatus(android.content.Context, int, byte[], int, android.net.Uri);
     method public void updateSmsSendStatus(int, boolean);
-    method public boolean updateStoredMessageStatus(android.net.Uri, android.content.ContentValues);
-    field public static final java.lang.String MESSAGE_STATUS_READ = "read";
-    field public static final java.lang.String MESSAGE_STATUS_SEEN = "seen";
+    field public static final java.lang.String EXTRA_MMS_DATA = "android.telephony.extra.MMS_DATA";
+    field public static final java.lang.String MMS_CONFIG_ALIAS_ENABLED = "aliasEnabled";
+    field public static final java.lang.String MMS_CONFIG_ALIAS_MAX_CHARS = "aliasMaxChars";
+    field public static final java.lang.String MMS_CONFIG_ALIAS_MIN_CHARS = "aliasMinChars";
+    field public static final java.lang.String MMS_CONFIG_ALLOW_ATTACH_AUDIO = "allowAttachAudio";
+    field public static final java.lang.String MMS_CONFIG_APPEND_TRANSACTION_ID = "enabledTransID";
+    field public static final java.lang.String MMS_CONFIG_EMAIL_GATEWAY_NUMBER = "emailGatewayNumber";
+    field public static final java.lang.String MMS_CONFIG_GROUP_MMS_ENABLED = "enableGroupMms";
+    field public static final java.lang.String MMS_CONFIG_HTTP_PARAMS = "httpParams";
+    field public static final java.lang.String MMS_CONFIG_HTTP_SOCKET_TIMEOUT = "httpSocketTimeout";
+    field public static final java.lang.String MMS_CONFIG_MAX_IMAGE_HEIGHT = "maxImageHeight";
+    field public static final java.lang.String MMS_CONFIG_MAX_IMAGE_WIDTH = "maxImageWidth";
+    field public static final java.lang.String MMS_CONFIG_MAX_MESSAGE_SIZE = "maxMessageSize";
+    field public static final java.lang.String MMS_CONFIG_MESSAGE_TEXT_MAX_SIZE = "maxMessageTextSize";
+    field public static final java.lang.String MMS_CONFIG_MMS_DELIVERY_REPORT_ENABLED = "enableMMSDeliveryReports";
+    field public static final java.lang.String MMS_CONFIG_MMS_ENABLED = "enabledMMS";
+    field public static final java.lang.String MMS_CONFIG_MMS_READ_REPORT_ENABLED = "enableMMSReadReports";
+    field public static final java.lang.String MMS_CONFIG_MULTIPART_SMS_ENABLED = "enableMultipartSMS";
+    field public static final java.lang.String MMS_CONFIG_NAI_SUFFIX = "naiSuffix";
+    field public static final java.lang.String MMS_CONFIG_NOTIFY_WAP_MMSC_ENABLED = "enabledNotifyWapMMSC";
+    field public static final java.lang.String MMS_CONFIG_RECIPIENT_LIMIT = "recipientLimit";
+    field public static final java.lang.String MMS_CONFIG_SEND_MULTIPART_SMS_AS_SEPARATE_MESSAGES = "sendMultipartSmsAsSeparateMessages";
+    field public static final java.lang.String MMS_CONFIG_SMS_DELIVERY_REPORT_ENABLED = "enableSMSDeliveryReports";
+    field public static final java.lang.String MMS_CONFIG_SMS_TO_MMS_TEXT_LENGTH_THRESHOLD = "smsToMmsTextLengthThreshold";
+    field public static final java.lang.String MMS_CONFIG_SMS_TO_MMS_TEXT_THRESHOLD = "smsToMmsTextThreshold";
+    field public static final java.lang.String MMS_CONFIG_SUBJECT_MAX_LENGTH = "maxSubjectLength";
+    field public static final java.lang.String MMS_CONFIG_SUPPORT_MMS_CONTENT_DISPOSITION = "supportMmsContentDisposition";
+    field public static final java.lang.String MMS_CONFIG_UA_PROF_TAG_NAME = "uaProfTagName";
+    field public static final java.lang.String MMS_CONFIG_UA_PROF_URL = "uaProfUrl";
+    field public static final java.lang.String MMS_CONFIG_USER_AGENT = "userAgent";
+    field public static final int MMS_ERROR_CONFIGURATION_ERROR = 7; // 0x7
     field public static final int MMS_ERROR_HTTP_FAILURE = 4; // 0x4
     field public static final int MMS_ERROR_INVALID_APN = 2; // 0x2
+    field public static final int MMS_ERROR_IO_ERROR = 5; // 0x5
+    field public static final int MMS_ERROR_RETRY = 6; // 0x6
     field public static final int MMS_ERROR_UNABLE_CONNECT_MMS = 3; // 0x3
     field public static final int MMS_ERROR_UNSPECIFIED = 1; // 0x1
-    field public static final java.lang.String MMS_EXTRA_DATA = "data";
     field public static final int RESULT_ERROR_GENERIC_FAILURE = 1; // 0x1
     field public static final int RESULT_ERROR_NO_SERVICE = 4; // 0x4
     field public static final int RESULT_ERROR_NULL_PDU = 3; // 0x3
     field public static final int RESULT_ERROR_RADIO_OFF = 2; // 0x2
-    field public static final int SMS_TYPE_INCOMING = 0; // 0x0
-    field public static final int SMS_TYPE_OUTGOING = 1; // 0x1
     field public static final int STATUS_ON_ICC_FREE = 0; // 0x0
     field public static final int STATUS_ON_ICC_READ = 1; // 0x1
     field public static final int STATUS_ON_ICC_SENT = 5; // 0x5
@@ -29657,10 +28808,7 @@
   }
 
   public class TelephonyManager {
-    method public void enableSimplifiedNetworkSettings(boolean);
-    method public void enableSimplifiedNetworkSettings(long, boolean);
     method public java.util.List<android.telephony.CellInfo> getAllCellInfo();
-    method public int getCalculatedPreferredNetworkType();
     method public int getCallState();
     method public android.telephony.CellLocation getCellLocation();
     method public int getDataActivity();
@@ -29677,20 +28825,18 @@
     method public java.lang.String getNetworkOperatorName();
     method public int getNetworkType();
     method public int getPhoneType();
-    method public int getPreferredNetworkType();
     method public java.lang.String getSimCountryIso();
     method public java.lang.String getSimOperator();
     method public java.lang.String getSimOperatorName();
     method public java.lang.String getSimSerialNumber();
     method public int getSimState();
-    method public boolean getSimplifiedNetworkSettingsEnabled();
-    method public boolean getSimplifiedNetworkSettingsEnabled(long);
     method public java.lang.String getSubscriberId();
     method public java.lang.String getVoiceMailAlphaTag();
     method public java.lang.String getVoiceMailNumber();
     method public int hasCarrierPrivileges();
     method public boolean hasIccCard();
     method public boolean iccCloseLogicalChannel(int);
+    method public byte[] iccExchangeSimIO(int, int, int, int, int, java.lang.String);
     method public android.telephony.IccOpenLogicalChannelResponse iccOpenLogicalChannel(java.lang.String);
     method public java.lang.String iccTransmitApduBasicChannel(int, int, int, int, int, java.lang.String);
     method public java.lang.String iccTransmitApduLogicalChannel(int, int, int, int, int, int, java.lang.String);
@@ -29698,11 +28844,9 @@
     method public boolean isSmsCapable();
     method public void listen(android.telephony.PhoneStateListener, int);
     method public java.lang.String sendEnvelopeWithStatus(java.lang.String);
-    method public boolean setCdmaSubscription(int);
+    method public boolean setGlobalPreferredNetworkType();
     method public void setLine1NumberForDisplay(java.lang.String, java.lang.String);
-    method public void setLine1NumberForDisplay(long, java.lang.String, java.lang.String);
-    method public boolean setOperatorBrandOverride(java.lang.String, java.lang.String);
-    method public boolean setPreferredNetworkType(int);
+    method public boolean setOperatorBrandOverride(java.lang.String);
     field public static final java.lang.String ACTION_PHONE_STATE_CHANGED = "android.intent.action.PHONE_STATE";
     field public static final java.lang.String ACTION_RESPOND_VIA_MESSAGE = "android.intent.action.RESPOND_VIA_MESSAGE";
     field public static final int CALL_STATE_IDLE = 0; // 0x0
@@ -30376,7 +29520,6 @@
     method public java.util.List<android.content.pm.PackageInfo> getInstalledPackages(int);
     method public java.lang.String getInstallerPackageName(java.lang.String);
     method public android.content.pm.InstrumentationInfo getInstrumentationInfo(android.content.ComponentName, int) throws android.content.pm.PackageManager.NameNotFoundException;
-    method public android.content.pm.KeySet getKeySetByAlias(java.lang.String, java.lang.String);
     method public android.content.Intent getLaunchIntentForPackage(java.lang.String);
     method public android.content.Intent getLeanbackLaunchIntentForPackage(java.lang.String);
     method public java.lang.String getNameForUid(int);
@@ -30395,15 +29538,15 @@
     method public android.content.res.Resources getResourcesForApplication(android.content.pm.ApplicationInfo);
     method public android.content.res.Resources getResourcesForApplication(java.lang.String) throws android.content.pm.PackageManager.NameNotFoundException;
     method public android.content.pm.ServiceInfo getServiceInfo(android.content.ComponentName, int) throws android.content.pm.PackageManager.NameNotFoundException;
-    method public android.content.pm.KeySet getSigningKeySet(java.lang.String);
     method public android.content.pm.FeatureInfo[] getSystemAvailableFeatures();
     method public java.lang.String[] getSystemSharedLibraryNames();
     method public java.lang.CharSequence getText(java.lang.String, int, android.content.pm.ApplicationInfo);
+    method public android.graphics.drawable.Drawable getUserBadgedDrawableForDensity(android.graphics.drawable.Drawable, android.os.UserHandle, android.graphics.Rect, int);
+    method public android.graphics.drawable.Drawable getUserBadgedIcon(android.graphics.drawable.Drawable, android.os.UserHandle);
+    method public java.lang.CharSequence getUserBadgedLabel(java.lang.CharSequence, android.os.UserHandle);
     method public android.content.res.XmlResourceParser getXml(java.lang.String, int, android.content.pm.ApplicationInfo);
     method public boolean hasSystemFeature(java.lang.String);
     method public boolean isSafeMode();
-    method public boolean isSignedBy(java.lang.String, android.content.pm.KeySet);
-    method public boolean isSignedByExactly(java.lang.String, android.content.pm.KeySet);
     method public java.util.List<android.content.pm.ResolveInfo> queryBroadcastReceivers(android.content.Intent, int);
     method public java.util.List<android.content.pm.ProviderInfo> queryContentProviders(java.lang.String, int, int);
     method public java.util.List<android.content.pm.InstrumentationInfo> queryInstrumentation(java.lang.String, int);
@@ -31820,7 +30963,7 @@
     field public static final java.lang.String CASE_GENITIVE = "android.genitive";
     field public static final java.lang.String CASE_INSTRUMENTAL = "android.instrumental";
     field public static final java.lang.String CASE_LOCATIVE = "android.locative";
-    field public static final java.lang.String CASE_NOMINATIVE = "android.nomative";
+    field public static final java.lang.String CASE_NOMINATIVE = "android.nominative";
     field public static final java.lang.String CASE_VOCATIVE = "android.vocative";
     field public static final java.lang.String GENDER_FEMALE = "android.female";
     field public static final java.lang.String GENDER_MALE = "android.male";
@@ -32110,7 +31253,7 @@
     ctor public ChangeBounds(android.content.Context, android.util.AttributeSet);
     method public void captureEndValues(android.transition.TransitionValues);
     method public void captureStartValues(android.transition.TransitionValues);
-    method public void setReparent(boolean);
+    method public deprecated void setReparent(boolean);
     method public void setResizeClip(boolean);
   }
 
@@ -32133,6 +31276,10 @@
     ctor public ChangeTransform(android.content.Context, android.util.AttributeSet);
     method public void captureEndValues(android.transition.TransitionValues);
     method public void captureStartValues(android.transition.TransitionValues);
+    method public boolean getReparent();
+    method public boolean getReparentWithOverlay();
+    method public void setReparent(boolean);
+    method public void setReparentWithOverlay(boolean);
   }
 
   public class CircularPropagation extends android.transition.VisibilityPropagation {
@@ -32160,13 +31307,13 @@
     method public abstract android.graphics.Path getPath(float, float, float, float);
   }
 
-  public class PatternMotion extends android.transition.PathMotion {
-    ctor public PatternMotion();
-    ctor public PatternMotion(android.content.Context, android.util.AttributeSet);
-    ctor public PatternMotion(android.graphics.Path);
+  public class PatternPathMotion extends android.transition.PathMotion {
+    ctor public PatternPathMotion();
+    ctor public PatternPathMotion(android.content.Context, android.util.AttributeSet);
+    ctor public PatternPathMotion(android.graphics.Path);
     method public android.graphics.Path getPath(float, float, float, float);
-    method public android.graphics.Path getPattern();
-    method public void setPattern(android.graphics.Path);
+    method public android.graphics.Path getPatternPath();
+    method public void setPatternPath(android.graphics.Path);
   }
 
   public final class Scene {
@@ -32292,6 +31439,8 @@
     method public void captureEndValues(android.transition.TransitionValues);
     method public void captureStartValues(android.transition.TransitionValues);
     method public int getOrdering();
+    method public android.transition.Transition getTransitionAt(int);
+    method public int getTransitionCount();
     method public android.transition.TransitionSet removeTransition(android.transition.Transition);
     method public android.transition.TransitionSet setOrdering(int);
     field public static final int ORDERING_SEQUENTIAL = 1; // 0x1
@@ -32358,6 +31507,7 @@
     method public void ensureCapacity(int);
     method public java.util.Set<java.util.Map.Entry<K, V>> entrySet();
     method public V get(java.lang.Object);
+    method public int indexOfKey(java.lang.Object);
     method public boolean isEmpty();
     method public K keyAt(int);
     method public java.util.Set<K> keySet();
@@ -32808,6 +31958,7 @@
     ctor public SizeF(float, float);
     method public float getHeight();
     method public float getWidth();
+    method public static android.util.SizeF parseSizeF(java.lang.String) throws java.lang.NumberFormatException;
   }
 
   public class SparseArray implements java.lang.Cloneable {
@@ -33157,8 +32308,6 @@
     method public final long getRefreshPeriodNano();
     method public final long getStartTimeNano();
     field public static final long UNDEFINED_TIME_NANO = -1L; // 0xffffffffffffffffL
-    field protected long[] mFramesPresentedTimeNano;
-    field protected long mRefreshPeriodNano;
   }
 
   public class GestureDetector {
@@ -33580,6 +32729,7 @@
     field public static final int KEYCODE_GUIDE = 172; // 0xac
     field public static final int KEYCODE_H = 36; // 0x24
     field public static final int KEYCODE_HEADSETHOOK = 79; // 0x4f
+    field public static final int KEYCODE_HELP = 259; // 0x103
     field public static final int KEYCODE_HENKAN = 214; // 0xd6
     field public static final int KEYCODE_HOME = 3; // 0x3
     field public static final int KEYCODE_I = 37; // 0x25
@@ -33680,12 +32830,40 @@
     field public static final int KEYCODE_T = 48; // 0x30
     field public static final int KEYCODE_TAB = 61; // 0x3d
     field public static final int KEYCODE_TV = 170; // 0xaa
+    field public static final int KEYCODE_TV_ANTENNA_CABLE = 242; // 0xf2
+    field public static final int KEYCODE_TV_AUDIO_DESCRIPTION = 252; // 0xfc
+    field public static final int KEYCODE_TV_AUDIO_DESCRIPTION_MIX_DOWN = 254; // 0xfe
+    field public static final int KEYCODE_TV_AUDIO_DESCRIPTION_MIX_UP = 253; // 0xfd
+    field public static final int KEYCODE_TV_CONTENTS_MENU = 256; // 0x100
     field public static final int KEYCODE_TV_DATA_SERVICE = 230; // 0xe6
     field public static final int KEYCODE_TV_INPUT = 178; // 0xb2
+    field public static final int KEYCODE_TV_INPUT_COMPONENT_1 = 249; // 0xf9
+    field public static final int KEYCODE_TV_INPUT_COMPONENT_2 = 250; // 0xfa
+    field public static final int KEYCODE_TV_INPUT_COMPOSITE_1 = 247; // 0xf7
+    field public static final int KEYCODE_TV_INPUT_COMPOSITE_2 = 248; // 0xf8
+    field public static final int KEYCODE_TV_INPUT_HDMI_1 = 243; // 0xf3
+    field public static final int KEYCODE_TV_INPUT_HDMI_2 = 244; // 0xf4
+    field public static final int KEYCODE_TV_INPUT_HDMI_3 = 245; // 0xf5
+    field public static final int KEYCODE_TV_INPUT_HDMI_4 = 246; // 0xf6
+    field public static final int KEYCODE_TV_INPUT_VGA_1 = 251; // 0xfb
+    field public static final int KEYCODE_TV_MEDIA_CONTEXT_MENU = 257; // 0x101
+    field public static final int KEYCODE_TV_NETWORK = 241; // 0xf1
+    field public static final int KEYCODE_TV_NUMBER_ENTRY = 234; // 0xea
     field public static final int KEYCODE_TV_POWER = 177; // 0xb1
+    field public static final int KEYCODE_TV_RADIO_SERVICE = 232; // 0xe8
+    field public static final int KEYCODE_TV_SATELLITE = 237; // 0xed
+    field public static final int KEYCODE_TV_SATELLITE_BS = 238; // 0xee
+    field public static final int KEYCODE_TV_SATELLITE_CS = 239; // 0xef
+    field public static final int KEYCODE_TV_SATELLITE_SERVICE = 240; // 0xf0
+    field public static final int KEYCODE_TV_TELETEXT = 233; // 0xe9
+    field public static final int KEYCODE_TV_TERRESTRIAL_ANALOG = 235; // 0xeb
+    field public static final int KEYCODE_TV_TERRESTRIAL_DIGITAL = 236; // 0xec
+    field public static final int KEYCODE_TV_TIMER_PROGRAMMING = 258; // 0x102
+    field public static final int KEYCODE_TV_ZOOM_MODE = 255; // 0xff
     field public static final int KEYCODE_U = 49; // 0x31
     field public static final int KEYCODE_UNKNOWN = 0; // 0x0
     field public static final int KEYCODE_V = 50; // 0x32
+    field public static final int KEYCODE_VOICE_ASSIST = 231; // 0xe7
     field public static final int KEYCODE_VOLUME_DOWN = 25; // 0x19
     field public static final int KEYCODE_VOLUME_MUTE = 164; // 0xa4
     field public static final int KEYCODE_VOLUME_UP = 24; // 0x18
@@ -34300,6 +33478,7 @@
     method protected int computeHorizontalScrollOffset();
     method protected int computeHorizontalScrollRange();
     method public void computeScroll();
+    method public android.view.WindowInsets computeSystemWindowInsets(android.view.WindowInsets, android.graphics.Rect);
     method protected int computeVerticalScrollExtent();
     method protected int computeVerticalScrollOffset();
     method protected int computeVerticalScrollRange();
@@ -34484,8 +33663,6 @@
     method public boolean hasTransientState();
     method public boolean hasWindowFocus();
     method public static android.view.View inflate(android.content.Context, int, android.view.ViewGroup);
-    method protected void initializeFadingEdge(android.content.res.TypedArray);
-    method protected void initializeScrollbars(android.content.res.TypedArray);
     method public void invalidate(android.graphics.Rect);
     method public void invalidate(int, int, int, int);
     method public void invalidate();
@@ -34962,7 +34139,7 @@
   }
 
   public final class ViewAnimationUtils {
-    method public static final android.animation.Animator createCircularReveal(android.view.View, int, int, float, float);
+    method public static android.animation.Animator createCircularReveal(android.view.View, int, int, float, float);
   }
 
   public class ViewConfiguration {
@@ -35242,6 +34419,8 @@
     ctor public ViewOutlineProvider();
     method public abstract void getOutline(android.view.View, android.graphics.Outline);
     field public static final android.view.ViewOutlineProvider BACKGROUND;
+    field public static final android.view.ViewOutlineProvider BOUNDS;
+    field public static final android.view.ViewOutlineProvider PADDED_BOUNDS;
   }
 
   public class ViewOverlay {
@@ -35419,7 +34598,7 @@
     method public abstract void closePanel(int);
     method public android.view.View findViewById(int);
     method public boolean getAllowEnterTransitionOverlap();
-    method public boolean getAllowExitTransitionOverlap();
+    method public boolean getAllowReturnTransitionOverlap();
     method public final android.view.WindowManager.LayoutParams getAttributes();
     method public final android.view.Window.Callback getCallback();
     method public final android.view.Window getContainer();
@@ -35441,6 +34620,7 @@
     method public android.transition.Transition getSharedElementExitTransition();
     method public android.transition.Transition getSharedElementReenterTransition();
     method public android.transition.Transition getSharedElementReturnTransition();
+    method public boolean getSharedElementsUseOverlay();
     method public abstract int getStatusBarColor();
     method public long getTransitionBackgroundFadeDuration();
     method public android.transition.TransitionManager getTransitionManager();
@@ -35467,7 +34647,7 @@
     method public abstract void restoreHierarchyState(android.os.Bundle);
     method public abstract android.os.Bundle saveHierarchyState();
     method public void setAllowEnterTransitionOverlap(boolean);
-    method public void setAllowExitTransitionOverlap(boolean);
+    method public void setAllowReturnTransitionOverlap(boolean);
     method public void setAttributes(android.view.WindowManager.LayoutParams);
     method public abstract void setBackgroundDrawable(android.graphics.drawable.Drawable);
     method public void setBackgroundDrawableResource(int);
@@ -35502,6 +34682,7 @@
     method public void setSharedElementExitTransition(android.transition.Transition);
     method public void setSharedElementReenterTransition(android.transition.Transition);
     method public void setSharedElementReturnTransition(android.transition.Transition);
+    method public void setSharedElementsUseOverlay(boolean);
     method public void setSoftInputMode(int);
     method public abstract void setStatusBarColor(int);
     method public abstract void setTitle(java.lang.CharSequence);
@@ -35528,6 +34709,7 @@
     field public static final int FEATURE_ACTION_BAR = 8; // 0x8
     field public static final int FEATURE_ACTION_BAR_OVERLAY = 9; // 0x9
     field public static final int FEATURE_ACTION_MODE_OVERLAY = 10; // 0xa
+    field public static final int FEATURE_ACTIVITY_TRANSITIONS = 13; // 0xd
     field public static final int FEATURE_CONTENT_TRANSITIONS = 12; // 0xc
     field public static final int FEATURE_CONTEXT_MENU = 6; // 0x6
     field public static final int FEATURE_CUSTOM_TITLE = 7; // 0x7
@@ -35606,16 +34788,23 @@
 
   public final class WindowInsets {
     ctor public WindowInsets(android.view.WindowInsets);
+    method public android.view.WindowInsets consumeStableInsets();
     method public android.view.WindowInsets consumeSystemWindowInsets();
+    method public int getStableInsetBottom();
+    method public int getStableInsetLeft();
+    method public int getStableInsetRight();
+    method public int getStableInsetTop();
     method public int getSystemWindowInsetBottom();
     method public int getSystemWindowInsetLeft();
     method public int getSystemWindowInsetRight();
     method public int getSystemWindowInsetTop();
     method public boolean hasInsets();
+    method public boolean hasStableInsets();
     method public boolean hasSystemWindowInsets();
     method public boolean isConsumed();
     method public boolean isRound();
     method public android.view.WindowInsets replaceSystemWindowInsets(int, int, int, int);
+    method public android.view.WindowInsets replaceSystemWindowInsets(android.graphics.Rect);
   }
 
   public abstract interface WindowManager implements android.view.ViewManager {
@@ -36131,6 +35320,7 @@
     method public android.view.accessibility.AccessibilityWindowInfo getParent();
     method public android.view.accessibility.AccessibilityNodeInfo getRoot();
     method public int getType();
+    method public boolean isAccessibilityFocused();
     method public boolean isActive();
     method public boolean isFocused();
     method public static android.view.accessibility.AccessibilityWindowInfo obtain();
@@ -36482,7 +35672,7 @@
     method public boolean performPrivateCommand(java.lang.String, android.os.Bundle);
     method public static final void removeComposingSpans(android.text.Spannable);
     method public boolean reportFullscreenMode(boolean);
-    method public int requestCursorAnchorInfo(android.view.inputmethod.CursorAnchorInfoRequest);
+    method public boolean requestCursorUpdates(int);
     method public boolean sendKeyEvent(android.view.KeyEvent);
     method public boolean setComposingRegion(int, int);
     method public static void setComposingSpans(android.text.Spannable);
@@ -36515,58 +35705,36 @@
   public final class CursorAnchorInfo implements android.os.Parcelable {
     ctor public CursorAnchorInfo(android.os.Parcel);
     method public int describeContents();
-    method public android.graphics.RectF getCharacterRect(int);
-    method public int getCharacterRectFlags(int);
+    method public android.graphics.RectF getCharacterBounds(int);
+    method public int getCharacterBoundsFlags(int);
     method public java.lang.CharSequence getComposingText();
     method public int getComposingTextStart();
     method public float getInsertionMarkerBaseline();
     method public float getInsertionMarkerBottom();
+    method public int getInsertionMarkerFlags();
     method public float getInsertionMarkerHorizontal();
     method public float getInsertionMarkerTop();
     method public android.graphics.Matrix getMatrix();
     method public int getSelectionEnd();
     method public int getSelectionStart();
-    method public boolean isInsertionMarkerClipped();
     method public void writeToParcel(android.os.Parcel, int);
-    field public static final int CHARACTER_RECT_TYPE_FULLY_VISIBLE = 1; // 0x1
-    field public static final int CHARACTER_RECT_TYPE_INVISIBLE = 3; // 0x3
-    field public static final int CHARACTER_RECT_TYPE_MASK = 15; // 0xf
-    field public static final int CHARACTER_RECT_TYPE_NOT_FEASIBLE = 4; // 0x4
-    field public static final int CHARACTER_RECT_TYPE_PARTIALLY_VISIBLE = 2; // 0x2
-    field public static final int CHARACTER_RECT_TYPE_UNSPECIFIED = 0; // 0x0
     field public static final android.os.Parcelable.Creator CREATOR;
+    field public static final int FLAG_HAS_INVISIBLE_REGION = 2; // 0x2
+    field public static final int FLAG_HAS_VISIBLE_REGION = 1; // 0x1
+    field public static final int FLAG_IS_RTL = 4; // 0x4
   }
 
   public static final class CursorAnchorInfo.Builder {
     ctor public CursorAnchorInfo.Builder();
-    method public android.view.inputmethod.CursorAnchorInfo.Builder addCharacterRect(int, float, float, float, float, int);
+    method public android.view.inputmethod.CursorAnchorInfo.Builder addCharacterBounds(int, float, float, float, float, int);
     method public android.view.inputmethod.CursorAnchorInfo build();
     method public void reset();
     method public android.view.inputmethod.CursorAnchorInfo.Builder setComposingText(int, java.lang.CharSequence);
-    method public android.view.inputmethod.CursorAnchorInfo.Builder setInsertionMarkerLocation(float, float, float, float, boolean);
+    method public android.view.inputmethod.CursorAnchorInfo.Builder setInsertionMarkerLocation(float, float, float, float, int);
     method public android.view.inputmethod.CursorAnchorInfo.Builder setMatrix(android.graphics.Matrix);
     method public android.view.inputmethod.CursorAnchorInfo.Builder setSelectionRange(int, int);
   }
 
-  public final class CursorAnchorInfoRequest implements android.os.Parcelable {
-    ctor public CursorAnchorInfoRequest(int, int);
-    ctor public CursorAnchorInfoRequest(android.os.Parcel);
-    method public int describeContents();
-    method public int getRequestFlags();
-    method public int getRequestType();
-    method public void writeToParcel(android.os.Parcel, int);
-    field public static final android.os.Parcelable.Creator CREATOR;
-    field public static final int FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE = 2; // 0x2
-    field public static final int FLAG_CURSOR_ANCHOR_INFO_MONITOR = 1; // 0x1
-    field public static final int FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES = 2; // 0x2
-    field public static final int FLAG_CURSOR_RECT_MONITOR = 1; // 0x1
-    field public static final int FLAG_CURSOR_RECT_WITH_VIEW_MATRIX = 4; // 0x4
-    field public static final int RESULT_NOT_HANDLED = 0; // 0x0
-    field public static final int RESULT_SCHEDULED = 1; // 0x1
-    field public static final int TYPE_CURSOR_ANCHOR_INFO = 1; // 0x1
-    field public static final int TYPE_CURSOR_RECT = 2; // 0x2
-  }
-
   public class EditorInfo implements android.text.InputType android.os.Parcelable {
     ctor public EditorInfo();
     method public int describeContents();
@@ -36664,11 +35832,13 @@
     method public abstract boolean performEditorAction(int);
     method public abstract boolean performPrivateCommand(java.lang.String, android.os.Bundle);
     method public abstract boolean reportFullscreenMode(boolean);
-    method public abstract int requestCursorAnchorInfo(android.view.inputmethod.CursorAnchorInfoRequest);
+    method public abstract boolean requestCursorUpdates(int);
     method public abstract boolean sendKeyEvent(android.view.KeyEvent);
     method public abstract boolean setComposingRegion(int, int);
     method public abstract boolean setComposingText(java.lang.CharSequence, int);
     method public abstract boolean setSelection(int, int);
+    field public static final int CURSOR_UPDATE_IMMEDIATE = 1; // 0x1
+    field public static final int CURSOR_UPDATE_MONITOR = 2; // 0x2
     field public static final int GET_EXTRACTED_TEXT_MONITOR = 1; // 0x1
     field public static final int GET_TEXT_WITH_STYLES = 1; // 0x1
   }
@@ -36692,7 +35862,7 @@
     method public boolean performEditorAction(int);
     method public boolean performPrivateCommand(java.lang.String, android.os.Bundle);
     method public boolean reportFullscreenMode(boolean);
-    method public int requestCursorAnchorInfo(android.view.inputmethod.CursorAnchorInfoRequest);
+    method public boolean requestCursorUpdates(int);
     method public boolean sendKeyEvent(android.view.KeyEvent);
     method public boolean setComposingRegion(int, int);
     method public boolean setComposingText(java.lang.CharSequence, int);
@@ -36758,7 +35928,7 @@
     method public boolean isActive(android.view.View);
     method public boolean isActive();
     method public boolean isFullscreenMode();
-    method public boolean isWatchingCursor(android.view.View);
+    method public deprecated boolean isWatchingCursor(android.view.View);
     method public void restartInput(android.view.View);
     method public void sendAppPrivateCommand(android.view.View, java.lang.String, android.os.Bundle);
     method public void setAdditionalInputMethodSubtypes(java.lang.String, android.view.inputmethod.InputMethodSubtype[]);
@@ -36776,7 +35946,7 @@
     method public boolean switchToNextInputMethod(android.os.IBinder, boolean);
     method public void toggleSoftInput(int, int);
     method public void toggleSoftInputFromWindow(android.os.IBinder, int, int);
-    method public void updateCursor(android.view.View, int, int, int, int);
+    method public deprecated void updateCursor(android.view.View, int, int, int, int);
     method public void updateCursorAnchorInfo(android.view.View, android.view.inputmethod.CursorAnchorInfo);
     method public void updateExtractedText(android.view.View, int, android.view.inputmethod.ExtractedText);
     method public void updateSelection(android.view.View, int, int, int, int);
@@ -36974,7 +36144,7 @@
 
   public class CookieManager {
     method public synchronized boolean acceptCookie();
-    method public synchronized boolean acceptThirdPartyCookies(android.webkit.WebView);
+    method public boolean acceptThirdPartyCookies(android.webkit.WebView);
     method public static boolean allowFileSchemeCookies();
     method public void flush();
     method public java.lang.String getCookie(java.lang.String);
@@ -37142,22 +36312,16 @@
 
   public static abstract class WebChromeClient.FileChooserParams {
     ctor public WebChromeClient.FileChooserParams();
+    method public abstract android.content.Intent createIntent();
     method public abstract java.lang.String[] getAcceptTypes();
-    method public abstract java.lang.String getDefaultFilename();
+    method public abstract java.lang.String getFilenameHint();
     method public abstract int getMode();
     method public abstract java.lang.CharSequence getTitle();
-    method public abstract android.webkit.WebChromeClient.UploadHelper getUploadHelper();
     method public abstract boolean isCaptureEnabled();
-    field public static final int OPEN = 0; // 0x0
-    field public static final int OPEN_FOLDER = 2; // 0x2
-    field public static final int OPEN_MULTIPLE = 1; // 0x1
-    field public static final int SAVE = 3; // 0x3
-  }
-
-  public static abstract class WebChromeClient.UploadHelper {
-    ctor public WebChromeClient.UploadHelper();
-    method public abstract android.content.Intent buildIntent();
-    method public abstract android.net.Uri[] parseResult(int, android.content.Intent);
+    method public static android.net.Uri[] parseResult(int, android.content.Intent);
+    field public static final int MODE_OPEN = 0; // 0x0
+    field public static final int MODE_OPEN_MULTIPLE = 1; // 0x1
+    field public static final int MODE_SAVE = 3; // 0x3
   }
 
   public class WebHistoryItem implements java.lang.Cloneable {
@@ -37185,7 +36349,7 @@
     method public abstract java.lang.String getMethod();
     method public abstract java.util.Map<java.lang.String, java.lang.String> getRequestHeaders();
     method public abstract android.net.Uri getUrl();
-    method public abstract boolean hasUserGestureInsecure();
+    method public abstract boolean hasGesture();
     method public abstract boolean isForMainFrame();
   }
 
@@ -37442,7 +36606,6 @@
     method public deprecated void onGlobalFocusChanged(android.view.View, android.view.View);
     method public void onPause();
     method public void onResume();
-    method public static void optOutDataReductionProxy();
     method public boolean overlayHorizontalScrollbar();
     method public boolean overlayVerticalScrollbar();
     method public boolean pageDown(boolean);
@@ -37474,7 +36637,7 @@
     method public void setWebViewClient(android.webkit.WebViewClient);
     method public deprecated boolean showFindDialog(java.lang.String, boolean);
     method public void stopLoading();
-    method public boolean zoomBy(float);
+    method public void zoomBy(float);
     method public boolean zoomIn();
     method public boolean zoomOut();
     field public static final java.lang.String SCHEME_GEO = "geo:0,0?q=";
@@ -38200,6 +37363,7 @@
     method public android.widget.CalendarView getCalendarView();
     method public boolean getCalendarViewShown();
     method public int getDayOfMonth();
+    method public int getFirstDayOfWeek();
     method public long getMaxDate();
     method public long getMinDate();
     method public int getMonth();
@@ -38207,6 +37371,7 @@
     method public int getYear();
     method public void init(int, int, int, android.widget.DatePicker.OnDateChangedListener);
     method public void setCalendarViewShown(boolean);
+    method public void setFirstDayOfWeek(int);
     method public void setMaxDate(long);
     method public void setMinDate(long);
     method public void setSpinnersShown(boolean);
@@ -39781,9 +38946,7 @@
     method public float getShadowRadius();
     method public final boolean getShowSoftInputOnFocus();
     method public java.lang.CharSequence getText();
-    method public static int getTextColor(android.content.Context, android.content.res.TypedArray, int);
     method public final android.content.res.ColorStateList getTextColors();
-    method public static android.content.res.ColorStateList getTextColors(android.content.Context, android.content.res.TypedArray);
     method public java.util.Locale getTextLocale();
     method public float getTextScaleX();
     method public float getTextSize();
@@ -40065,6 +39228,7 @@
     method public void setOnPreparedListener(android.media.MediaPlayer.OnPreparedListener);
     method public void setVideoPath(java.lang.String);
     method public void setVideoURI(android.net.Uri);
+    method public void setVideoURI(android.net.Uri, java.util.Map<java.lang.String, java.lang.String>);
     method public void start();
     method public void stopPlayback();
     method public void suspend();
@@ -40159,22 +39323,6 @@
 
 }
 
-package com.android.internal.telecomm {
-
-  public abstract interface RemoteServiceCallback implements android.os.IInterface {
-    method public abstract void onError() throws android.os.RemoteException;
-    method public abstract void onResult(java.util.List<android.content.ComponentName>, java.util.List<android.os.IBinder>) throws android.os.RemoteException;
-  }
-
-  public static abstract class RemoteServiceCallback.Stub extends android.os.Binder implements com.android.internal.telecomm.RemoteServiceCallback {
-    ctor public RemoteServiceCallback.Stub();
-    method public android.os.IBinder asBinder();
-    method public static com.android.internal.telecomm.RemoteServiceCallback asInterface(android.os.IBinder);
-    method public boolean onTransact(int, android.os.Parcel, android.os.Parcel, int) throws android.os.RemoteException;
-  }
-
-}
-
 package com.android.internal.util {
 
   public abstract interface Predicate {
diff --git a/api/removed.txt b/api/removed.txt
index 465a18d..8972679 100644
--- a/api/removed.txt
+++ b/api/removed.txt
@@ -6,11 +6,41 @@
 
 }
 
+package android.os {
+
+  public final class PowerManager {
+    method public void goToSleep(long);
+    method public deprecated void userActivity(long, boolean);
+    method public void wakeUp(long);
+  }
+
+  public class UserManager {
+    method public android.graphics.drawable.Drawable getBadgedDrawableForUser(android.graphics.drawable.Drawable, android.os.UserHandle, android.graphics.Rect, int);
+    method public android.graphics.drawable.Drawable getBadgedIconForUser(android.graphics.drawable.Drawable, android.os.UserHandle);
+    method public java.lang.CharSequence getBadgedLabelForUser(java.lang.CharSequence, android.os.UserHandle);
+  }
+
+}
+
 package android.view {
 
+  public class View implements android.view.accessibility.AccessibilityEventSource android.graphics.drawable.Drawable.Callback android.view.KeyEvent.Callback {
+    method protected void initializeFadingEdge(android.content.res.TypedArray);
+    method protected void initializeScrollbars(android.content.res.TypedArray);
+  }
+
   public static class WindowManager.LayoutParams extends android.view.ViewGroup.LayoutParams implements android.os.Parcelable {
     field public static final int TYPE_KEYGUARD = 2004; // 0x7d4
   }
 
 }
 
+package android.widget {
+
+  public class TextView extends android.view.View implements android.view.ViewTreeObserver.OnPreDrawListener {
+    method public static int getTextColor(android.content.Context, android.content.res.TypedArray, int);
+    method public static android.content.res.ColorStateList getTextColors(android.content.Context, android.content.res.TypedArray);
+  }
+
+}
+
diff --git a/cmds/am/src/com/android/commands/am/Am.java b/cmds/am/src/com/android/commands/am/Am.java
index fa59e4b..5ba7d50 100644
--- a/cmds/am/src/com/android/commands/am/Am.java
+++ b/cmds/am/src/com/android/commands/am/Am.java
@@ -26,11 +26,17 @@
 import android.app.IActivityManager;
 import android.app.IInstrumentationWatcher;
 import android.app.Instrumentation;
+import android.app.ProfilerInfo;
 import android.app.UiAutomationConnection;
+import android.app.usage.ConfigurationStats;
+import android.app.usage.IUsageStatsManager;
+import android.app.usage.UsageStatsManager;
 import android.content.ComponentName;
+import android.content.Context;
 import android.content.IIntentReceiver;
 import android.content.Intent;
 import android.content.pm.IPackageManager;
+import android.content.pm.ParceledListSlice;
 import android.content.pm.ResolveInfo;
 import android.content.res.Configuration;
 import android.graphics.Rect;
@@ -42,10 +48,12 @@
 import android.os.ParcelFileDescriptor;
 import android.os.RemoteException;
 import android.os.ServiceManager;
+import android.os.SystemClock;
 import android.os.SystemProperties;
 import android.os.UserHandle;
 import android.text.TextUtils;
 import android.util.AndroidException;
+import android.util.ArrayMap;
 import android.view.IWindowManager;
 import android.view.View;
 
@@ -60,6 +68,9 @@
 import java.io.InputStreamReader;
 import java.io.PrintStream;
 import java.net.URISyntaxException;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
 import java.util.HashSet;
 import java.util.List;
 
@@ -76,6 +87,8 @@
     private String mReceiverPermission;
 
     private String mProfileFile;
+    private int mSamplingInterval;
+    private boolean mAutoStop;
 
     /**
      * Command-line entry point.
@@ -91,7 +104,7 @@
         out.println(
                 "usage: am [subcommand] [options]\n" +
                 "usage: am start [-D] [-W] [-P <FILE>] [--start-profiler <FILE>]\n" +
-                "               [--R COUNT] [-S] [--opengl-trace]\n" +
+                "               [--sampling INTERVAL] [-R COUNT] [-S] [--opengl-trace]\n" +
                 "               [--user <USER_ID> | current] <INTENT>\n" +
                 "       am startservice [--user <USER_ID> | current] <INTENT>\n" +
                 "       am stopservice [--user <USER_ID> | current] <INTENT>\n" +
@@ -133,6 +146,8 @@
                 "    -D: enable debugging\n" +
                 "    -W: wait for launch to complete\n" +
                 "    --start-profiler <FILE>: start profiler and send results to <FILE>\n" +
+                "    --sampling INTERVAL: use sample profiling with INTERVAL microseconds\n" +
+                "        between samples (use with --start-profiler)\n" +
                 "    -P <FILE>: like above, but profiling stops when app goes idle\n" +
                 "    -R: repeat the activity launch <COUNT> times.  Prior to each repeat,\n" +
                 "        the top activity will be finished.\n" +
@@ -360,6 +375,8 @@
         mStopOption = false;
         mRepeat = 0;
         mProfileFile = null;
+        mSamplingInterval = 0;
+        mAutoStop = false;
         mUserId = defUser;
         Uri data = null;
         String type = null;
@@ -526,10 +543,12 @@
                 mWaitOption = true;
             } else if (opt.equals("-P")) {
                 mProfileFile = nextArgRequired();
-                mStartFlags |= ActivityManager.START_FLAG_AUTO_STOP_PROFILER;
+                mAutoStop = true;
             } else if (opt.equals("--start-profiler")) {
                 mProfileFile = nextArgRequired();
-                mStartFlags &= ~ActivityManager.START_FLAG_AUTO_STOP_PROFILER;
+                mAutoStop = false;
+            } else if (opt.equals("--sampling")) {
+                mSamplingInterval = Integer.parseInt(nextArgRequired());
             } else if (opt.equals("-R")) {
                 mRepeat = Integer.parseInt(nextArgRequired());
             } else if (opt.equals("-S")) {
@@ -685,12 +704,13 @@
                 mAm.forceStopPackage(packageName, mUserId);
                 Thread.sleep(250);
             }
-    
+
             System.out.println("Starting: " + intent);
             intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-    
+
             ParcelFileDescriptor fd = null;
-    
+            ProfilerInfo profilerInfo = null;
+
             if (mProfileFile != null) {
                 try {
                     fd = ParcelFileDescriptor.open(
@@ -702,18 +722,21 @@
                     System.err.println("Error: Unable to open file: " + mProfileFile);
                     return;
                 }
+                profilerInfo = new ProfilerInfo(mProfileFile, fd, mSamplingInterval, mAutoStop);
             }
 
             IActivityManager.WaitResult result = null;
             int res;
+            final long startTime = SystemClock.uptimeMillis();
             if (mWaitOption) {
                 result = mAm.startActivityAndWait(null, null, intent, mimeType,
-                            null, null, 0, mStartFlags, mProfileFile, fd, null, mUserId);
+                            null, null, 0, mStartFlags, profilerInfo, null, mUserId);
                 res = result.result;
             } else {
                 res = mAm.startActivityAsUser(null, null, intent, mimeType,
-                        null, null, 0, mStartFlags, mProfileFile, fd, null, mUserId);
+                        null, null, 0, mStartFlags, profilerInfo, null, mUserId);
             }
+            final long endTime = SystemClock.uptimeMillis();
             PrintStream out = mWaitOption ? System.out : System.err;
             boolean launched = false;
             switch (res) {
@@ -791,6 +814,7 @@
                 if (result.totalTime >= 0) {
                     System.out.println("TotalTime: " + result.totalTime);
                 }
+                System.out.println("WaitTime: " + (endTime-startTime));
                 System.out.println("Complete");
             }
             mRepeat--;
@@ -835,7 +859,7 @@
     }
 
     private void sendBroadcast() throws Exception {
-        Intent intent = makeIntent(UserHandle.USER_ALL);
+        Intent intent = makeIntent(UserHandle.USER_CURRENT);
         IntentReceiver receiver = new IntentReceiver();
         System.out.println("Broadcasting: " + intent);
         mAm.broadcastIntent(null, intent, null, receiver, 0, null, null, mReceiverPermission,
@@ -942,7 +966,7 @@
             SystemProperties.set("dalvik.vm.extra-opts", props);
         }
     }
-    
+
     private void runProfile() throws Exception {
         String profileFile = null;
         boolean start = false;
@@ -996,6 +1020,7 @@
         }
 
         ParcelFileDescriptor fd = null;
+        ProfilerInfo profilerInfo = null;
 
         if (start) {
             profileFile = nextArgRequired();
@@ -1009,6 +1034,7 @@
                 System.err.println("Error: Unable to open file: " + profileFile);
                 return;
             }
+            profilerInfo = new ProfilerInfo(profileFile, fd, 0, false);
         }
 
         try {
@@ -1022,7 +1048,7 @@
             } else if (start) {
                 //removeWallOption();
             }
-            if (!mAm.profileControl(process, userId, start, profileFile, fd, profileType)) {
+            if (!mAm.profileControl(process, userId, start, profilerInfo, profileType)) {
                 wall = false;
                 throw new AndroidException("PROFILE FAILED on process " + process);
             }
@@ -1709,7 +1735,64 @@
         }
     }
 
+    private List<Configuration> getRecentConfigurations(int days) {
+        IUsageStatsManager usm = IUsageStatsManager.Stub.asInterface(ServiceManager.getService(
+                    Context.USAGE_STATS_SERVICE));
+        final long now = System.currentTimeMillis();
+        final long nDaysAgo = now - (days * 24 * 60 * 60 * 1000);
+        try {
+            @SuppressWarnings("unchecked")
+            ParceledListSlice<ConfigurationStats> configStatsSlice = usm.queryConfigurationStats(
+                    UsageStatsManager.INTERVAL_BEST, nDaysAgo, now, "com.android.shell");
+            if (configStatsSlice == null) {
+                return Collections.emptyList();
+            }
+
+            final ArrayMap<Configuration, Integer> recentConfigs = new ArrayMap<>();
+            final List<ConfigurationStats> configStatsList = configStatsSlice.getList();
+            final int configStatsListSize = configStatsList.size();
+            for (int i = 0; i < configStatsListSize; i++) {
+                final ConfigurationStats stats = configStatsList.get(i);
+                final int indexOfKey = recentConfigs.indexOfKey(stats.getConfiguration());
+                if (indexOfKey < 0) {
+                    recentConfigs.put(stats.getConfiguration(), stats.getActivationCount());
+                } else {
+                    recentConfigs.setValueAt(indexOfKey,
+                            recentConfigs.valueAt(indexOfKey) + stats.getActivationCount());
+                }
+            }
+
+            final Comparator<Configuration> comparator = new Comparator<Configuration>() {
+                @Override
+                public int compare(Configuration a, Configuration b) {
+                    return recentConfigs.get(b).compareTo(recentConfigs.get(a));
+                }
+            };
+
+            ArrayList<Configuration> configs = new ArrayList<>(recentConfigs.size());
+            configs.addAll(recentConfigs.keySet());
+            Collections.sort(configs, comparator);
+            return configs;
+
+        } catch (RemoteException e) {
+            return Collections.emptyList();
+        }
+    }
+
     private void runGetConfig() throws Exception {
+        int days = 14;
+        String option = nextOption();
+        if (option != null) {
+            if (!option.equals("--days")) {
+                throw new IllegalArgumentException("unrecognized option " + option);
+            }
+
+            days = Integer.parseInt(nextArgRequired());
+            if (days <= 0) {
+                throw new IllegalArgumentException("--days must be a positive integer");
+            }
+        }
+
         try {
             Configuration config = mAm.getConfiguration();
             if (config == null) {
@@ -1720,6 +1803,17 @@
             System.out.println("config: " + Configuration.resourceQualifierString(config));
             System.out.println("abi: " + TextUtils.join(",", Build.SUPPORTED_ABIS));
 
+            final List<Configuration> recentConfigs = getRecentConfigurations(days);
+            final int recentConfigSize = recentConfigs.size();
+            if (recentConfigSize > 0) {
+                System.out.println("recentConfigs:");
+            }
+
+            for (int i = 0; i < recentConfigSize; i++) {
+                System.out.println("  config: " + Configuration.resourceQualifierString(
+                        recentConfigs.get(i)));
+            }
+
         } catch (RemoteException e) {
         }
     }
diff --git a/cmds/app_process/app_main.cpp b/cmds/app_process/app_main.cpp
index 74ccbc2..1bb28c3 100644
--- a/cmds/app_process/app_main.cpp
+++ b/cmds/app_process/app_main.cpp
@@ -133,8 +133,7 @@
     // names if the zygote command line decreases in size.
     uintptr_t start = reinterpret_cast<uintptr_t>(argv[0]);
     uintptr_t end = reinterpret_cast<uintptr_t>(argv[argc - 1]);
-    end += strlen(argv[argc - 1]);
-
+    end += strlen(argv[argc - 1]) + 1;
     return (end - start);
 }
 
@@ -161,17 +160,17 @@
     LOG_ALWAYS_FATAL_IF((numChars >= PATH_MAX || numChars < 0),
             "Error constructing dalvik cache : %s", strerror(errno));
 
-    int result = mkdir(dalvikCacheDir, 0771);
+    int result = mkdir(dalvikCacheDir, 0711);
     LOG_ALWAYS_FATAL_IF((result < 0 && errno != EEXIST),
             "Error creating cache dir %s : %s", dalvikCacheDir, strerror(errno));
 
     // We always perform these steps because the directory might
     // already exist, with wider permissions and a different owner
     // than we'd like.
-    result = chown(dalvikCacheDir, AID_SYSTEM, AID_SYSTEM);
+    result = chown(dalvikCacheDir, AID_ROOT, AID_ROOT);
     LOG_ALWAYS_FATAL_IF((result < 0), "Error changing dalvik-cache ownership : %s", strerror(errno));
 
-    result = chmod(dalvikCacheDir, 0771);
+    result = chmod(dalvikCacheDir, 0711);
     LOG_ALWAYS_FATAL_IF((result < 0),
             "Error changing dalvik-cache permissions : %s", strerror(errno));
 }
@@ -220,15 +219,27 @@
     //
     // For zygote starts, all remaining arguments are passed to the zygote.
     // main function.
+    //
+    // Note that we must copy argument string values since we will rewrite the
+    // entire argument block when we apply the nice name to argv0.
 
-
-    int i = runtime.addVmArguments(argc, argv);
+    int i;
+    for (i = 0; i < argc; i++) {
+        if (argv[i][0] != '-') {
+            break;
+        }
+        if (argv[i][1] == '-' && argv[i][2] == 0) {
+            ++i; // Skip --.
+            break;
+        }
+        runtime.addOption(strdup(argv[i]));
+    }
 
     // Parse runtime arguments.  Stop at first unrecognized option.
     bool zygote = false;
     bool startSystemServer = false;
     bool application = false;
-    const char* niceName = NULL;
+    String8 niceName;
     String8 className;
 
     ++i;  // Skip unused "parent dir" argument.
@@ -242,7 +253,7 @@
         } else if (strcmp(arg, "--application") == 0) {
             application = true;
         } else if (strncmp(arg, "--nice-name=", 12) == 0) {
-            niceName = arg + 12;
+            niceName.setTo(arg + 12);
         } else if (strncmp(arg, "--", 2) != 0) {
             className.setTo(arg);
             break;
@@ -287,9 +298,9 @@
         }
     }
 
-    if (niceName && *niceName) {
-        runtime.setArgv0(niceName);
-        set_process_name(niceName);
+    if (!niceName.isEmpty()) {
+        runtime.setArgv0(niceName.string());
+        set_process_name(niceName.string());
     }
 
     if (zygote) {
diff --git a/cmds/appops/Android.mk b/cmds/appops/Android.mk
new file mode 100644
index 0000000..1e15204
--- /dev/null
+++ b/cmds/appops/Android.mk
@@ -0,0 +1,16 @@
+# Copyright 2014 The Android Open Source Project
+
+LOCAL_PATH:= $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_SRC_FILES := $(call all-subdir-java-files)
+LOCAL_MODULE := appops
+include $(BUILD_JAVA_LIBRARY)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := appops
+LOCAL_SRC_FILES := appops
+LOCAL_MODULE_CLASS := EXECUTABLES
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_PREBUILT)
+
diff --git a/cmds/appops/MODULE_LICENSE_APACHE2 b/cmds/appops/MODULE_LICENSE_APACHE2
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/cmds/appops/MODULE_LICENSE_APACHE2
diff --git a/cmds/appops/NOTICE b/cmds/appops/NOTICE
new file mode 100644
index 0000000..06a9081
--- /dev/null
+++ b/cmds/appops/NOTICE
@@ -0,0 +1,190 @@
+
+   Copyright (c) 2005-2014, 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.
+
+   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.
+
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
diff --git a/cmds/appops/appops b/cmds/appops/appops
new file mode 100755
index 0000000..407e551
--- /dev/null
+++ b/cmds/appops/appops
@@ -0,0 +1,5 @@
+# Script to start "appwidget" on the device, which has a very rudimentary shell.
+base=/system
+export CLASSPATH=$base/framework/appops.jar
+exec app_process $base/bin com.android.commands.appops.AppOpsCommand "$@"
+
diff --git a/cmds/appops/src/com/android/commands/appops/AppOpsCommand.java b/cmds/appops/src/com/android/commands/appops/AppOpsCommand.java
new file mode 100644
index 0000000..c414f58
--- /dev/null
+++ b/cmds/appops/src/com/android/commands/appops/AppOpsCommand.java
@@ -0,0 +1,137 @@
+/*
+** Copyright 2014, 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.commands.appops;
+
+import android.app.ActivityManager;
+import android.app.ActivityThread;
+import android.app.AppOpsManager;
+import android.content.Context;
+import android.content.pm.IPackageManager;
+import android.os.ServiceManager;
+import android.os.UserHandle;
+
+import com.android.internal.app.IAppOpsService;
+import com.android.internal.os.BaseCommand;
+
+import java.io.PrintStream;
+
+/**
+ * This class is a command line utility for manipulating AppOps permissions.
+ */
+public class AppOpsCommand extends BaseCommand {
+
+    public static void main(String[] args) {
+        new AppOpsCommand().run(args);
+    }
+
+    @Override
+    public void onShowUsage(PrintStream out) {
+        out.println("usage: adb shell appops set <PACKAGE> <OP> "
+                + "<allow|ignore|deny|default> [--user <USER_ID>]\n"
+                + "  <PACKAGE> an Android package name.\n"
+                + "  <OP>      an AppOps operation.\n"
+                + "  <USER_ID> the user id under which the package is installed. If --user is not\n"
+                + "            specified, the current user is assumed.\n");
+    }
+
+    private static final String COMMAND_SET = "set";
+
+    @Override
+    public void onRun() throws Exception {
+        String command = nextArgRequired();
+        switch (command) {
+            case COMMAND_SET:
+                runSet();
+                break;
+
+            default:
+                throw new IllegalArgumentException("Unknown command '" + command + "'.");
+        }
+    }
+
+    private static final String ARGUMENT_USER = "--user";
+
+    // Modes
+    private static final String MODE_ALLOW = "allow";
+    private static final String MODE_DENY = "deny";
+    private static final String MODE_IGNORE = "ignore";
+    private static final String MODE_DEFAULT = "default";
+
+    private void runSet() throws Exception {
+        String packageName = null;
+        String op = null;
+        String mode = null;
+        int userId = UserHandle.USER_CURRENT;
+        for (String argument; (argument = nextArg()) != null;) {
+            if (ARGUMENT_USER.equals(argument)) {
+                userId = Integer.parseInt(nextArgRequired());
+            } else {
+                if (packageName == null) {
+                    packageName = argument;
+                } else if (op == null) {
+                    op = argument;
+                } else if (mode == null) {
+                    mode = argument;
+                } else {
+                    throw new IllegalArgumentException("Unsupported argument: " + argument);
+                }
+            }
+        }
+
+        if (packageName == null) {
+            throw new IllegalArgumentException("Package name not specified.");
+        } else if (op == null) {
+            throw new IllegalArgumentException("Operation not specified.");
+        } else if (mode == null) {
+            throw new IllegalArgumentException("Mode not specified.");
+        }
+
+        final int opInt = AppOpsManager.strOpToOp(op);
+        final int modeInt;
+        switch (mode) {
+            case MODE_ALLOW:
+                modeInt = AppOpsManager.MODE_ALLOWED;
+                break;
+            case MODE_DENY:
+                modeInt = AppOpsManager.MODE_ERRORED;
+                break;
+            case MODE_IGNORE:
+                modeInt = AppOpsManager.MODE_IGNORED;
+                break;
+            case MODE_DEFAULT:
+                modeInt = AppOpsManager.MODE_DEFAULT;
+                break;
+            default:
+                throw new IllegalArgumentException("Mode is invalid.");
+        }
+
+        // Parsing complete, let's execute the command.
+
+        if (userId == UserHandle.USER_CURRENT) {
+            userId = ActivityManager.getCurrentUser();
+        }
+
+        final IPackageManager pm = ActivityThread.getPackageManager();
+        final IAppOpsService appOpsService = IAppOpsService.Stub.asInterface(
+                ServiceManager.getService(Context.APP_OPS_SERVICE));
+        final int uid = pm.getPackageUid(packageName, userId);
+        if (uid < 0) {
+            throw new Exception("No UID for " + packageName + " for user " + userId);
+        }
+        appOpsService.setMode(opInt, uid, packageName, modeInt);
+    }
+}
diff --git a/cmds/dpm/Android.mk b/cmds/dpm/Android.mk
new file mode 100644
index 0000000..9f5aee4
--- /dev/null
+++ b/cmds/dpm/Android.mk
@@ -0,0 +1,15 @@
+# Copyright 2014 The Android Open Source Project
+#
+LOCAL_PATH:= $(call my-dir)
+
+include $(CLEAR_VARS)
+LOCAL_SRC_FILES := $(call all-subdir-java-files)
+LOCAL_MODULE := dpm
+include $(BUILD_JAVA_LIBRARY)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := dpm
+LOCAL_SRC_FILES := dpm
+LOCAL_MODULE_CLASS := EXECUTABLES
+LOCAL_MODULE_TAGS := optional
+include $(BUILD_PREBUILT)
diff --git a/cmds/dpm/MODULE_LICENSE_APACHE2 b/cmds/dpm/MODULE_LICENSE_APACHE2
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/cmds/dpm/MODULE_LICENSE_APACHE2
diff --git a/cmds/dpm/NOTICE b/cmds/dpm/NOTICE
new file mode 100644
index 0000000..316b4eb
--- /dev/null
+++ b/cmds/dpm/NOTICE
@@ -0,0 +1,190 @@
+
+   Copyright (c) 2014, 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.
+
+   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.
+
+
+                                 Apache License
+                           Version 2.0, January 2004
+                        http://www.apache.org/licenses/
+
+   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+   1. Definitions.
+
+      "License" shall mean the terms and conditions for use, reproduction,
+      and distribution as defined by Sections 1 through 9 of this document.
+
+      "Licensor" shall mean the copyright owner or entity authorized by
+      the copyright owner that is granting the License.
+
+      "Legal Entity" shall mean the union of the acting entity and all
+      other entities that control, are controlled by, or are under common
+      control with that entity. For the purposes of this definition,
+      "control" means (i) the power, direct or indirect, to cause the
+      direction or management of such entity, whether by contract or
+      otherwise, or (ii) ownership of fifty percent (50%) or more of the
+      outstanding shares, or (iii) beneficial ownership of such entity.
+
+      "You" (or "Your") shall mean an individual or Legal Entity
+      exercising permissions granted by this License.
+
+      "Source" form shall mean the preferred form for making modifications,
+      including but not limited to software source code, documentation
+      source, and configuration files.
+
+      "Object" form shall mean any form resulting from mechanical
+      transformation or translation of a Source form, including but
+      not limited to compiled object code, generated documentation,
+      and conversions to other media types.
+
+      "Work" shall mean the work of authorship, whether in Source or
+      Object form, made available under the License, as indicated by a
+      copyright notice that is included in or attached to the work
+      (an example is provided in the Appendix below).
+
+      "Derivative Works" shall mean any work, whether in Source or Object
+      form, that is based on (or derived from) the Work and for which the
+      editorial revisions, annotations, elaborations, or other modifications
+      represent, as a whole, an original work of authorship. For the purposes
+      of this License, Derivative Works shall not include works that remain
+      separable from, or merely link (or bind by name) to the interfaces of,
+      the Work and Derivative Works thereof.
+
+      "Contribution" shall mean any work of authorship, including
+      the original version of the Work and any modifications or additions
+      to that Work or Derivative Works thereof, that is intentionally
+      submitted to Licensor for inclusion in the Work by the copyright owner
+      or by an individual or Legal Entity authorized to submit on behalf of
+      the copyright owner. For the purposes of this definition, "submitted"
+      means any form of electronic, verbal, or written communication sent
+      to the Licensor or its representatives, including but not limited to
+      communication on electronic mailing lists, source code control systems,
+      and issue tracking systems that are managed by, or on behalf of, the
+      Licensor for the purpose of discussing and improving the Work, but
+      excluding communication that is conspicuously marked or otherwise
+      designated in writing by the copyright owner as "Not a Contribution."
+
+      "Contributor" shall mean Licensor and any individual or Legal Entity
+      on behalf of whom a Contribution has been received by Licensor and
+      subsequently incorporated within the Work.
+
+   2. Grant of Copyright License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      copyright license to reproduce, prepare Derivative Works of,
+      publicly display, publicly perform, sublicense, and distribute the
+      Work and such Derivative Works in Source or Object form.
+
+   3. Grant of Patent License. Subject to the terms and conditions of
+      this License, each Contributor hereby grants to You a perpetual,
+      worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+      (except as stated in this section) patent license to make, have made,
+      use, offer to sell, sell, import, and otherwise transfer the Work,
+      where such license applies only to those patent claims licensable
+      by such Contributor that are necessarily infringed by their
+      Contribution(s) alone or by combination of their Contribution(s)
+      with the Work to which such Contribution(s) was submitted. If You
+      institute patent litigation against any entity (including a
+      cross-claim or counterclaim in a lawsuit) alleging that the Work
+      or a Contribution incorporated within the Work constitutes direct
+      or contributory patent infringement, then any patent licenses
+      granted to You under this License for that Work shall terminate
+      as of the date such litigation is filed.
+
+   4. Redistribution. You may reproduce and distribute copies of the
+      Work or Derivative Works thereof in any medium, with or without
+      modifications, and in Source or Object form, provided that You
+      meet the following conditions:
+
+      (a) You must give any other recipients of the Work or
+          Derivative Works a copy of this License; and
+
+      (b) You must cause any modified files to carry prominent notices
+          stating that You changed the files; and
+
+      (c) You must retain, in the Source form of any Derivative Works
+          that You distribute, all copyright, patent, trademark, and
+          attribution notices from the Source form of the Work,
+          excluding those notices that do not pertain to any part of
+          the Derivative Works; and
+
+      (d) If the Work includes a "NOTICE" text file as part of its
+          distribution, then any Derivative Works that You distribute must
+          include a readable copy of the attribution notices contained
+          within such NOTICE file, excluding those notices that do not
+          pertain to any part of the Derivative Works, in at least one
+          of the following places: within a NOTICE text file distributed
+          as part of the Derivative Works; within the Source form or
+          documentation, if provided along with the Derivative Works; or,
+          within a display generated by the Derivative Works, if and
+          wherever such third-party notices normally appear. The contents
+          of the NOTICE file are for informational purposes only and
+          do not modify the License. You may add Your own attribution
+          notices within Derivative Works that You distribute, alongside
+          or as an addendum to the NOTICE text from the Work, provided
+          that such additional attribution notices cannot be construed
+          as modifying the License.
+
+      You may add Your own copyright statement to Your modifications and
+      may provide additional or different license terms and conditions
+      for use, reproduction, or distribution of Your modifications, or
+      for any such Derivative Works as a whole, provided Your use,
+      reproduction, and distribution of the Work otherwise complies with
+      the conditions stated in this License.
+
+   5. Submission of Contributions. Unless You explicitly state otherwise,
+      any Contribution intentionally submitted for inclusion in the Work
+      by You to the Licensor shall be under the terms and conditions of
+      this License, without any additional terms or conditions.
+      Notwithstanding the above, nothing herein shall supersede or modify
+      the terms of any separate license agreement you may have executed
+      with Licensor regarding such Contributions.
+
+   6. Trademarks. This License does not grant permission to use the trade
+      names, trademarks, service marks, or product names of the Licensor,
+      except as required for reasonable and customary use in describing the
+      origin of the Work and reproducing the content of the NOTICE file.
+
+   7. Disclaimer of Warranty. Unless required by applicable law or
+      agreed to in writing, Licensor provides the Work (and each
+      Contributor provides its Contributions) on an "AS IS" BASIS,
+      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+      implied, including, without limitation, any warranties or conditions
+      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+      PARTICULAR PURPOSE. You are solely responsible for determining the
+      appropriateness of using or redistributing the Work and assume any
+      risks associated with Your exercise of permissions under this License.
+
+   8. Limitation of Liability. In no event and under no legal theory,
+      whether in tort (including negligence), contract, or otherwise,
+      unless required by applicable law (such as deliberate and grossly
+      negligent acts) or agreed to in writing, shall any Contributor be
+      liable to You for damages, including any direct, indirect, special,
+      incidental, or consequential damages of any character arising as a
+      result of this License or out of the use or inability to use the
+      Work (including but not limited to damages for loss of goodwill,
+      work stoppage, computer failure or malfunction, or any and all
+      other commercial damages or losses), even if such Contributor
+      has been advised of the possibility of such damages.
+
+   9. Accepting Warranty or Additional Liability. While redistributing
+      the Work or Derivative Works thereof, You may choose to offer,
+      and charge a fee for, acceptance of support, warranty, indemnity,
+      or other liability obligations and/or rights consistent with this
+      License. However, in accepting such obligations, You may act only
+      on Your own behalf and on Your sole responsibility, not on behalf
+      of any other Contributor, and only if You agree to indemnify,
+      defend, and hold each Contributor harmless for any liability
+      incurred by, or claims asserted against, such Contributor by reason
+      of your accepting any such warranty or additional liability.
+
+   END OF TERMS AND CONDITIONS
+
diff --git a/cmds/dpm/dpm b/cmds/dpm/dpm
new file mode 100755
index 0000000..c2e5cbb
--- /dev/null
+++ b/cmds/dpm/dpm
@@ -0,0 +1,6 @@
+# Script to start "dpm" on the device
+#
+base=/system
+export CLASSPATH=$base/framework/dpm.jar
+exec app_process $base/bin com.android.commands.dpm.Dpm "$@"
+
diff --git a/cmds/dpm/src/com/android/commands/dpm/Dpm.java b/cmds/dpm/src/com/android/commands/dpm/Dpm.java
new file mode 100644
index 0000000..3b9a785
--- /dev/null
+++ b/cmds/dpm/src/com/android/commands/dpm/Dpm.java
@@ -0,0 +1,135 @@
+/*
+ * Copyright (C) 2014 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.commands.dpm;
+
+import android.app.admin.IDevicePolicyManager;
+import android.content.ComponentName;
+import android.content.Context;
+import android.os.RemoteException;
+import android.os.ServiceManager;
+import android.os.UserHandle;
+
+import com.android.internal.os.BaseCommand;
+
+import java.io.PrintStream;
+
+public final class Dpm extends BaseCommand {
+
+    /**
+     * Command-line entry point.
+     *
+     * @param args The command-line arguments
+     */
+    public static void main(String[] args) {
+      (new Dpm()).run(args);
+    }
+
+    private static final String COMMAND_SET_DEVICE_OWNER = "set-device-owner";
+    private static final String COMMAND_SET_PROFILE_OWNER = "set-profile-owner";
+
+    private IDevicePolicyManager mDevicePolicyManager;
+
+    @Override
+    public void onShowUsage(PrintStream out) {
+        out.println(
+                "usage: dpm [subcommand] [options]\n" +
+                "usage: dpm set-device-owner <COMPONENT>\n" +
+                "usage: dpm set-profile-owner <COMPONENT> <USER_ID>\n" +
+                "\n" +
+                "dpm set-device-owner: Sets the given component as active admin, and its\n" +
+                "  package as device owner.\n" +
+                "\n" +
+                "dpm set-profile-owner: Sets the given component as active admin and profile" +
+                "  owner for an existing user.\n");
+    }
+
+    @Override
+    public void onRun() throws Exception {
+        mDevicePolicyManager = IDevicePolicyManager.Stub.asInterface(
+                ServiceManager.getService(Context.DEVICE_POLICY_SERVICE));
+        if (mDevicePolicyManager == null) {
+            showError("Error: Could not access the Device Policy Manager. Is the system running?");
+            return;
+        }
+
+        String command = nextArgRequired();
+        switch (command) {
+            case COMMAND_SET_DEVICE_OWNER:
+                runSetDeviceOwner();
+                break;
+            case COMMAND_SET_PROFILE_OWNER:
+                runSetProfileOwner();
+                break;
+            default:
+                throw new IllegalArgumentException ("unknown command '" + command + "'");
+        }
+    }
+
+    private void runSetDeviceOwner() throws RemoteException {
+        ComponentName component = parseComponentName(nextArgRequired());
+        mDevicePolicyManager.setActiveAdmin(component, true /*refreshing*/, UserHandle.USER_OWNER);
+
+        String packageName = component.getPackageName();
+        try {
+            if (!mDevicePolicyManager.setDeviceOwner(packageName, null /*ownerName*/)) {
+                throw new RuntimeException(
+                        "Can't set package " + packageName + " as device owner.");
+            }
+        } catch (Exception e) {
+            // Need to remove the admin that we just added.
+            mDevicePolicyManager.removeActiveAdmin(component, UserHandle.USER_OWNER);
+            throw e;
+        }
+        System.out.println("Success: Device owner set to package " + packageName);
+        System.out.println("Active admin set to component " + component.toShortString());
+    }
+
+    private void runSetProfileOwner() throws RemoteException {
+        ComponentName component = parseComponentName(nextArgRequired());
+        int userId = parseInt(nextArgRequired());
+        mDevicePolicyManager.setActiveAdmin(component, true /*refreshing*/, userId);
+
+        try {
+            if (!mDevicePolicyManager.setProfileOwner(component, "" /*ownerName*/, userId)) {
+                throw new RuntimeException("Can't set component " + component.toShortString() +
+                        " as profile owner for user " + userId);
+            }
+        } catch (Exception e) {
+            // Need to remove the admin that we just added.
+            mDevicePolicyManager.removeActiveAdmin(component, userId);
+            throw e;
+        }
+        System.out.println("Success: Active admin and profile owner set to "
+                + component.toShortString() + " for user " + userId);
+    }
+
+    private ComponentName parseComponentName(String component) {
+        ComponentName cn = ComponentName.unflattenFromString(component);
+        if (cn == null) {
+            throw new IllegalArgumentException ("Invalid component " + component);
+        }
+        return cn;
+    }
+
+    private int parseInt(String argument) {
+        try {
+            return Integer.parseInt(argument);
+        } catch (NumberFormatException e) {
+            throw new IllegalArgumentException ("Invalid integer argument '" + argument + "'", e);
+        }
+    }
+}
\ No newline at end of file
diff --git a/cmds/pm/src/com/android/commands/pm/Pm.java b/cmds/pm/src/com/android/commands/pm/Pm.java
index 46d8ade..5e9d8f7 100644
--- a/cmds/pm/src/com/android/commands/pm/Pm.java
+++ b/cmds/pm/src/com/android/commands/pm/Pm.java
@@ -865,7 +865,8 @@
     }
 
     private void runInstall() {
-        int installFlags = PackageManager.INSTALL_ALL_USERS;
+        int installFlags = 0;
+        int userId = UserHandle.USER_ALL;
         String installerPackageName = null;
 
         String opt;
@@ -909,12 +910,19 @@
                 }
             } else if (opt.equals("--abi")) {
                 abi = checkAbiArgument(nextOptionData());
+            } else if (opt.equals("--user")) {
+                userId = Integer.parseInt(nextOptionData());
             } else {
                 System.err.println("Error: Unknown option: " + opt);
                 return;
             }
         }
 
+        if (userId == UserHandle.USER_ALL) {
+            userId = UserHandle.USER_OWNER;
+            installFlags |= PackageManager.INSTALL_ALL_USERS;
+        }
+
         final Uri verificationURI;
         final Uri originatingURI;
         final Uri referrerURI;
@@ -953,8 +961,8 @@
             VerificationParams verificationParams = new VerificationParams(verificationURI,
                     originatingURI, referrerURI, VerificationParams.NO_UID, null);
 
-            mPm.installPackage(apkFilePath, obs.getBinder(), installFlags, installerPackageName,
-                    verificationParams, abi);
+            mPm.installPackageAsUser(apkFilePath, obs.getBinder(), installFlags,
+                    installerPackageName, verificationParams, abi, userId);
 
             synchronized (obs) {
                 while (!obs.finished) {
@@ -978,10 +986,10 @@
     }
 
     private void runInstallCreate() throws RemoteException {
+        int userId = UserHandle.USER_ALL;
         String installerPackageName = null;
 
         final SessionParams params = new SessionParams(SessionParams.MODE_FULL_INSTALL);
-        params.installFlags = PackageManager.INSTALL_ALL_USERS;
 
         String opt;
         while ((opt = nextOption()) != null) {
@@ -1002,19 +1010,33 @@
                 params.installFlags |= PackageManager.INSTALL_INTERNAL;
             } else if (opt.equals("-d")) {
                 params.installFlags |= PackageManager.INSTALL_ALLOW_DOWNGRADE;
+            } else if (opt.equals("--originating-uri")) {
+                params.originatingUri = Uri.parse(nextOptionData());
+            } else if (opt.equals("--referrer")) {
+                params.referrerUri = Uri.parse(nextOptionData());
             } else if (opt.equals("-p")) {
                 params.mode = SessionParams.MODE_INHERIT_EXISTING;
+                params.appPackageName = nextOptionData();
+                if (params.appPackageName == null) {
+                    throw new IllegalArgumentException("Missing inherit package name");
+                }
             } else if (opt.equals("-S")) {
                 params.setSize(Long.parseLong(nextOptionData()));
             } else if (opt.equals("--abi")) {
                 params.abiOverride = checkAbiArgument(nextOptionData());
+            } else if (opt.equals("--user")) {
+                userId = Integer.parseInt(nextOptionData());
             } else {
                 throw new IllegalArgumentException("Unknown option " + opt);
             }
         }
 
-        final int sessionId = mInstaller.createSession(params, installerPackageName,
-                UserHandle.USER_OWNER);
+        if (userId == UserHandle.USER_ALL) {
+            userId = UserHandle.USER_OWNER;
+            params.installFlags |= PackageManager.INSTALL_ALL_USERS;
+        }
+
+        final int sessionId = mInstaller.createSession(params, installerPackageName, userId);
 
         // NOTE: adb depends on parsing this string
         System.out.println("Success: created install session [" + sessionId + "]");
@@ -1168,10 +1190,6 @@
             if (userId < 0) {
                 info = mUm.createUser(name, flags);
             } else {
-                if (Process.myUid() != 0) {
-                    System.err.println("Error: not running as root.");
-                    return;
-                }
                 info = mUm.createProfileForUser(name, flags, userId);
             }
             if (info != null) {
@@ -1681,7 +1699,7 @@
 
         public Intent getResult() {
             try {
-                return mResult.poll(30, TimeUnit.SECONDS);
+                return mResult.take();
             } catch (InterruptedException e) {
                 throw new RuntimeException(e);
             }
diff --git a/core/java/android/accessibilityservice/IAccessibilityServiceConnection.aidl b/core/java/android/accessibilityservice/IAccessibilityServiceConnection.aidl
index 5f7a17d..27a03b6 100644
--- a/core/java/android/accessibilityservice/IAccessibilityServiceConnection.aidl
+++ b/core/java/android/accessibilityservice/IAccessibilityServiceConnection.aidl
@@ -54,6 +54,10 @@
         int action, in Bundle arguments, int interactionId,
         IAccessibilityInteractionConnectionCallback callback, long threadId);
 
+    boolean computeClickPointInScreen(int accessibilityWindowId, long accessibilityNodeId,
+        int interactionId, IAccessibilityInteractionConnectionCallback callback,
+        long threadId);
+
     AccessibilityWindowInfo getWindow(int windowId);
 
     List<AccessibilityWindowInfo> getWindows();
diff --git a/core/java/android/animation/Animator.java b/core/java/android/animation/Animator.java
index 5f80ed7..3720c81 100644
--- a/core/java/android/animation/Animator.java
+++ b/core/java/android/animation/Animator.java
@@ -370,6 +370,7 @@
      * @hide
      */
     public void reverse() {
+        throw new IllegalStateException("Reverse is not supported");
     }
 
     /**
diff --git a/core/java/android/animation/AnimatorInflater.java b/core/java/android/animation/AnimatorInflater.java
index e57be83..25417ed 100644
--- a/core/java/android/animation/AnimatorInflater.java
+++ b/core/java/android/animation/AnimatorInflater.java
@@ -92,21 +92,27 @@
      */
     public static Animator loadAnimator(Resources resources, Theme theme, int id)
             throws NotFoundException {
+        return loadAnimator(resources, theme, id, 1);
+    }
+
+    /** @hide */
+    public static Animator loadAnimator(Resources resources, Theme theme, int id,
+            float pathErrorScale) throws NotFoundException {
 
         XmlResourceParser parser = null;
         try {
             parser = resources.getAnimation(id);
-            return createAnimatorFromXml(resources, theme, parser);
+            return createAnimatorFromXml(resources, theme, parser, pathErrorScale);
         } catch (XmlPullParserException ex) {
             Resources.NotFoundException rnf =
                     new Resources.NotFoundException("Can't load animation resource ID #0x" +
-                    Integer.toHexString(id));
+                            Integer.toHexString(id));
             rnf.initCause(ex);
             throw rnf;
         } catch (IOException ex) {
             Resources.NotFoundException rnf =
                     new Resources.NotFoundException("Can't load animation resource ID #0x" +
-                    Integer.toHexString(id));
+                            Integer.toHexString(id));
             rnf.initCause(ex);
             throw rnf;
         } finally {
@@ -177,7 +183,7 @@
                         }
                         if (animator == null) {
                             animator = createAnimatorFromXml(context.getResources(),
-                                    context.getTheme(), parser);
+                                    context.getTheme(), parser, 1f);
                         }
 
                         if (animator == null) {
@@ -248,9 +254,11 @@
      * @param arrayAnimator Incoming typed array for Animator's attributes.
      * @param arrayObjectAnimator Incoming typed array for Object Animator's
      *            attributes.
+     * @param pixelSize The relative pixel size, used to calculate the
+     *                  maximum error for path animations.
      */
     private static void parseAnimatorFromTypeArray(ValueAnimator anim,
-            TypedArray arrayAnimator, TypedArray arrayObjectAnimator) {
+            TypedArray arrayAnimator, TypedArray arrayObjectAnimator, float pixelSize) {
         long duration = arrayAnimator.getInt(R.styleable.Animator_duration, 300);
 
         long startDelay = arrayAnimator.getInt(R.styleable.Animator_startOffset, 0);
@@ -303,7 +311,7 @@
         }
 
         if (arrayObjectAnimator != null) {
-            setupObjectAnimator(anim, arrayObjectAnimator, getFloats);
+            setupObjectAnimator(anim, arrayObjectAnimator, getFloats, pixelSize);
         }
     }
 
@@ -351,9 +359,11 @@
      * @param anim The target Animator which will be updated.
      * @param arrayObjectAnimator TypedArray for the ObjectAnimator.
      * @param getFloats True if the value type is float.
+     * @param pixelSize The relative pixel size, used to calculate the
+     *                  maximum error for path animations.
      */
     private static void setupObjectAnimator(ValueAnimator anim, TypedArray arrayObjectAnimator,
-            boolean getFloats) {
+            boolean getFloats, float pixelSize) {
         ObjectAnimator oa = (ObjectAnimator) anim;
         String pathData = arrayObjectAnimator.getString(R.styleable.PropertyAnimator_pathData);
 
@@ -370,14 +380,24 @@
                         + " propertyXName or propertyYName is needed for PathData");
             } else {
                 Path path = PathParser.createPathFromPathData(pathData);
-                Keyframe[][] keyframes = PropertyValuesHolder.createKeyframes(path, !getFloats);
+                float error = 0.5f * pixelSize; // max half a pixel error
+                PathKeyframes keyframeSet = KeyframeSet.ofPath(path, error);
+                Keyframes xKeyframes;
+                Keyframes yKeyframes;
+                if (getFloats) {
+                    xKeyframes = keyframeSet.createXFloatKeyframes();
+                    yKeyframes = keyframeSet.createYFloatKeyframes();
+                } else {
+                    xKeyframes = keyframeSet.createXIntKeyframes();
+                    yKeyframes = keyframeSet.createYIntKeyframes();
+                }
                 PropertyValuesHolder x = null;
                 PropertyValuesHolder y = null;
                 if (propertyXName != null) {
-                    x = PropertyValuesHolder.ofKeyframe(propertyXName, keyframes[0]);
+                    x = PropertyValuesHolder.ofKeyframes(propertyXName, xKeyframes);
                 }
                 if (propertyYName != null) {
-                    y = PropertyValuesHolder.ofKeyframe(propertyYName, keyframes[1]);
+                    y = PropertyValuesHolder.ofKeyframes(propertyYName, yKeyframes);
                 }
                 if (x == null) {
                     oa.setValues(y);
@@ -478,13 +498,15 @@
         }
     }
 
-    private static Animator createAnimatorFromXml(Resources res, Theme theme, XmlPullParser parser)
+    private static Animator createAnimatorFromXml(Resources res, Theme theme, XmlPullParser parser,
+            float pixelSize)
             throws XmlPullParserException, IOException {
-        return createAnimatorFromXml(res, theme, parser, Xml.asAttributeSet(parser), null, 0);
+        return createAnimatorFromXml(res, theme, parser, Xml.asAttributeSet(parser), null, 0,
+                pixelSize);
     }
 
     private static Animator createAnimatorFromXml(Resources res, Theme theme, XmlPullParser parser,
-            AttributeSet attrs, AnimatorSet parent, int sequenceOrdering)
+            AttributeSet attrs, AnimatorSet parent, int sequenceOrdering, float pixelSize)
             throws XmlPullParserException, IOException {
 
         Animator anim = null;
@@ -504,9 +526,9 @@
             String name = parser.getName();
 
             if (name.equals("objectAnimator")) {
-                anim = loadObjectAnimator(res, theme, attrs);
+                anim = loadObjectAnimator(res, theme, attrs, pixelSize);
             } else if (name.equals("animator")) {
-                anim = loadAnimator(res, theme, attrs, null);
+                anim = loadAnimator(res, theme, attrs, null, pixelSize);
             } else if (name.equals("set")) {
                 anim = new AnimatorSet();
                 TypedArray a;
@@ -517,7 +539,8 @@
                 }
                 int ordering = a.getInt(R.styleable.AnimatorSet_ordering,
                         TOGETHER);
-                createAnimatorFromXml(res, theme, parser, attrs, (AnimatorSet) anim, ordering);
+                createAnimatorFromXml(res, theme, parser, attrs, (AnimatorSet) anim, ordering,
+                        pixelSize);
                 a.recycle();
             } else {
                 throw new RuntimeException("Unknown animator name: " + parser.getName());
@@ -547,11 +570,11 @@
 
     }
 
-    private static ObjectAnimator loadObjectAnimator(Resources res, Theme theme, AttributeSet attrs)
-            throws NotFoundException {
+    private static ObjectAnimator loadObjectAnimator(Resources res, Theme theme, AttributeSet attrs,
+            float pathErrorScale) throws NotFoundException {
         ObjectAnimator anim = new ObjectAnimator();
 
-        loadAnimator(res, theme, attrs, anim);
+        loadAnimator(res, theme, attrs, anim, pathErrorScale);
 
         return anim;
     }
@@ -566,7 +589,7 @@
      *            ObjectAnimator
      */
     private static ValueAnimator loadAnimator(Resources res, Theme theme,
-            AttributeSet attrs, ValueAnimator anim)
+            AttributeSet attrs, ValueAnimator anim, float pathErrorScale)
             throws NotFoundException {
 
         TypedArray arrayAnimator = null;
@@ -592,7 +615,7 @@
             anim = new ValueAnimator();
         }
 
-        parseAnimatorFromTypeArray(anim, arrayAnimator, arrayObjectAnimator);
+        parseAnimatorFromTypeArray(anim, arrayAnimator, arrayObjectAnimator, pathErrorScale);
 
         final int resID =
                 arrayAnimator.getResourceId(R.styleable.Animator_interpolator, 0);
diff --git a/core/java/android/animation/AnimatorSet.java b/core/java/android/animation/AnimatorSet.java
index 9156eeb..0aa8fdd 100644
--- a/core/java/android/animation/AnimatorSet.java
+++ b/core/java/android/animation/AnimatorSet.java
@@ -504,6 +504,10 @@
         mStarted = true;
         mPaused = false;
 
+        for (Node node : mNodes) {
+            node.animation.setAllowRunningAsynchronously(false);
+        }
+
         if (mDuration >= 0) {
             // If the duration was set on this AnimatorSet, pass it along to all child animations
             for (Node node : mNodes) {
@@ -632,6 +636,7 @@
         anim.mNodes = new ArrayList<Node>();
         anim.mSortedNodes = new ArrayList<Node>();
         anim.mReversible = mReversible;
+        anim.mSetListener = null;
 
         // Walk through the old nodes list, cloning each node and adding it to the new nodemap.
         // One problem is that the old node dependencies point to nodes in the old AnimatorSet.
diff --git a/core/java/android/animation/FloatKeyframeSet.java b/core/java/android/animation/FloatKeyframeSet.java
index 2d87e13..12e5862 100644
--- a/core/java/android/animation/FloatKeyframeSet.java
+++ b/core/java/android/animation/FloatKeyframeSet.java
@@ -30,7 +30,7 @@
  * TypeEvaluator set for the animation, so that values can be calculated without autoboxing to the
  * Object equivalents of these primitive types.</p>
  */
-class FloatKeyframeSet extends KeyframeSet {
+class FloatKeyframeSet extends KeyframeSet implements Keyframes.FloatKeyframes {
     private float firstValue;
     private float lastValue;
     private float deltaValue;
@@ -58,10 +58,11 @@
     }
 
     @Override
-    void invalidateCache() {
+    public void invalidateCache() {
         firstTime = true;
     }
 
+    @Override
     public float getFloatValue(float fraction) {
         if (mNumKeyframes == 2) {
             if (firstTime) {
@@ -135,5 +136,9 @@
         return ((Number)mKeyframes.get(mNumKeyframes - 1).getValue()).floatValue();
     }
 
+    @Override
+    public Class getType() {
+        return Float.class;
+    }
 }
 
diff --git a/core/java/android/animation/IntKeyframeSet.java b/core/java/android/animation/IntKeyframeSet.java
index ce47e2b..7a5b0ec 100644
--- a/core/java/android/animation/IntKeyframeSet.java
+++ b/core/java/android/animation/IntKeyframeSet.java
@@ -30,7 +30,7 @@
  * TypeEvaluator set for the animation, so that values can be calculated without autoboxing to the
  * Object equivalents of these primitive types.</p>
  */
-class IntKeyframeSet extends KeyframeSet {
+class IntKeyframeSet extends KeyframeSet implements Keyframes.IntKeyframes {
     private int firstValue;
     private int lastValue;
     private int deltaValue;
@@ -58,10 +58,11 @@
     }
 
     @Override
-    void invalidateCache() {
+    public void invalidateCache() {
         firstTime = true;
     }
 
+    @Override
     public int getIntValue(float fraction) {
         if (mNumKeyframes == 2) {
             if (firstTime) {
@@ -134,5 +135,9 @@
         return ((Number)mKeyframes.get(mNumKeyframes - 1).getValue()).intValue();
     }
 
+    @Override
+    public Class getType() {
+        return Integer.class;
+    }
 }
 
diff --git a/core/java/android/animation/KeyframeSet.java b/core/java/android/animation/KeyframeSet.java
index a3db3a1..8d15db2 100644
--- a/core/java/android/animation/KeyframeSet.java
+++ b/core/java/android/animation/KeyframeSet.java
@@ -21,6 +21,7 @@
 import android.animation.Keyframe.IntKeyframe;
 import android.animation.Keyframe.FloatKeyframe;
 import android.animation.Keyframe.ObjectKeyframe;
+import android.graphics.Path;
 import android.util.Log;
 
 /**
@@ -28,7 +29,7 @@
  * values between those keyframes for a given animation. The class internal to the animation
  * package because it is an implementation detail of how Keyframes are stored and used.
  */
-class KeyframeSet {
+class KeyframeSet implements Keyframes {
 
     int mNumKeyframes;
 
@@ -52,7 +53,12 @@
      * If subclass has variables that it calculates based on the Keyframes, it should reset them
      * when this method is called because Keyframe contents might have changed.
      */
-    void invalidateCache() {
+    @Override
+    public void invalidateCache() {
+    }
+
+    public ArrayList<Keyframe> getKeyframes() {
+        return mKeyframes;
     }
 
     public static KeyframeSet ofInt(int... values) {
@@ -144,6 +150,14 @@
         return new KeyframeSet(keyframes);
     }
 
+    public static PathKeyframes ofPath(Path path) {
+        return new PathKeyframes(path);
+    }
+
+    public static PathKeyframes ofPath(Path path, float error) {
+        return new PathKeyframes(path, error);
+    }
+
     /**
      * Sets the TypeEvaluator to be used when calculating animated values. This object
      * is required only for KeyframeSets that are not either IntKeyframeSet or FloatKeyframeSet,
@@ -157,6 +171,11 @@
     }
 
     @Override
+    public Class getType() {
+        return mFirstKeyframe.getType();
+    }
+
+    @Override
     public KeyframeSet clone() {
         ArrayList<Keyframe> keyframes = mKeyframes;
         int numKeyframes = mKeyframes.size();
diff --git a/core/java/android/animation/Keyframes.java b/core/java/android/animation/Keyframes.java
new file mode 100644
index 0000000..6611c6c
--- /dev/null
+++ b/core/java/android/animation/Keyframes.java
@@ -0,0 +1,94 @@
+/*
+ * Copyright (C) 2014 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 android.animation;
+
+import java.util.ArrayList;
+
+/**
+ * This interface abstracts a collection of Keyframe objects and is called by
+ * ValueAnimator to calculate values between those keyframes for a given animation.
+ */
+interface Keyframes extends Cloneable {
+
+    /**
+     * Sets the TypeEvaluator to be used when calculating animated values. This object
+     * is required only for Keyframes that are not either IntKeyframes or FloatKeyframes,
+     * both of which assume their own evaluator to speed up calculations with those primitive
+     * types.
+     *
+     * @param evaluator The TypeEvaluator to be used to calculate animated values.
+     */
+    void setEvaluator(TypeEvaluator evaluator);
+
+    /**
+     * @return The value type contained by the contained Keyframes.
+     */
+    Class getType();
+
+    /**
+     * Gets the animated value, given the elapsed fraction of the animation (interpolated by the
+     * animation's interpolator) and the evaluator used to calculate in-between values. This
+     * function maps the input fraction to the appropriate keyframe interval and a fraction
+     * between them and returns the interpolated value. Note that the input fraction may fall
+     * outside the [0-1] bounds, if the animation's interpolator made that happen (e.g., a
+     * spring interpolation that might send the fraction past 1.0). We handle this situation by
+     * just using the two keyframes at the appropriate end when the value is outside those bounds.
+     *
+     * @param fraction The elapsed fraction of the animation
+     * @return The animated value.
+     */
+    Object getValue(float fraction);
+
+    /**
+     * If subclass has variables that it calculates based on the Keyframes, it should reset them
+     * when this method is called because Keyframe contents might have changed.
+     */
+    void invalidateCache();
+
+    /**
+     * @return A list of all Keyframes contained by this. This may return null if this is
+     * not made up of Keyframes.
+     */
+    ArrayList<Keyframe> getKeyframes();
+
+    Keyframes clone();
+
+    /**
+     * A specialization of Keyframes that has integer primitive value calculation.
+     */
+    public interface IntKeyframes extends Keyframes {
+
+        /**
+         * Works like {@link #getValue(float)}, but returning a primitive.
+         * @param fraction The elapsed fraction of the animation
+         * @return The animated value.
+         */
+        int getIntValue(float fraction);
+    }
+
+    /**
+     * A specialization of Keyframes that has float primitive value calculation.
+     */
+    public interface FloatKeyframes extends Keyframes {
+
+        /**
+         * Works like {@link #getValue(float)}, but returning a primitive.
+         * @param fraction The elapsed fraction of the animation
+         * @return The animated value.
+         */
+        float getFloatValue(float fraction);
+    }
+}
diff --git a/core/java/android/animation/LayoutTransition.java b/core/java/android/animation/LayoutTransition.java
index 188408d..5790682 100644
--- a/core/java/android/animation/LayoutTransition.java
+++ b/core/java/android/animation/LayoutTransition.java
@@ -899,11 +899,15 @@
                     PropertyValuesHolder[] oldValues = valueAnim.getValues();
                     for (int i = 0; i < oldValues.length; ++i) {
                         PropertyValuesHolder pvh = oldValues[i];
-                        KeyframeSet keyframeSet = pvh.mKeyframeSet;
-                        if (keyframeSet.mFirstKeyframe == null ||
-                                keyframeSet.mLastKeyframe == null ||
-                                !keyframeSet.mFirstKeyframe.getValue().equals(
-                                keyframeSet.mLastKeyframe.getValue())) {
+                        if (pvh.mKeyframes instanceof KeyframeSet) {
+                            KeyframeSet keyframeSet = (KeyframeSet) pvh.mKeyframes;
+                            if (keyframeSet.mFirstKeyframe == null ||
+                                    keyframeSet.mLastKeyframe == null ||
+                                    !keyframeSet.mFirstKeyframe.getValue().equals(
+                                            keyframeSet.mLastKeyframe.getValue())) {
+                                valuesDiffer = true;
+                            }
+                        } else if (!pvh.mKeyframes.getValue(0).equals(pvh.mKeyframes.getValue(1))) {
                             valuesDiffer = true;
                         }
                     }
diff --git a/core/java/android/animation/ObjectAnimator.java b/core/java/android/animation/ObjectAnimator.java
index a4ac73f..500634c 100644
--- a/core/java/android/animation/ObjectAnimator.java
+++ b/core/java/android/animation/ObjectAnimator.java
@@ -239,9 +239,11 @@
      */
     public static ObjectAnimator ofInt(Object target, String xPropertyName, String yPropertyName,
             Path path) {
-        Keyframe[][] keyframes = PropertyValuesHolder.createKeyframes(path, true);
-        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframe(xPropertyName, keyframes[0]);
-        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframe(yPropertyName, keyframes[1]);
+        PathKeyframes keyframes = KeyframeSet.ofPath(path);
+        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframes(xPropertyName,
+                keyframes.createXIntKeyframes());
+        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframes(yPropertyName,
+                keyframes.createYIntKeyframes());
         return ofPropertyValuesHolder(target, x, y);
     }
 
@@ -278,9 +280,11 @@
      */
     public static <T> ObjectAnimator ofInt(T target, Property<T, Integer> xProperty,
             Property<T, Integer> yProperty, Path path) {
-        Keyframe[][] keyframes = PropertyValuesHolder.createKeyframes(path, true);
-        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframe(xProperty, keyframes[0]);
-        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframe(yProperty, keyframes[1]);
+        PathKeyframes keyframes = KeyframeSet.ofPath(path);
+        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframes(xProperty,
+                keyframes.createXIntKeyframes());
+        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframes(yProperty,
+                keyframes.createYIntKeyframes());
         return ofPropertyValuesHolder(target, x, y);
     }
 
@@ -429,9 +433,11 @@
      */
     public static ObjectAnimator ofFloat(Object target, String xPropertyName, String yPropertyName,
             Path path) {
-        Keyframe[][] keyframes = PropertyValuesHolder.createKeyframes(path, false);
-        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframe(xPropertyName, keyframes[0]);
-        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframe(yPropertyName, keyframes[1]);
+        PathKeyframes keyframes = KeyframeSet.ofPath(path);
+        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframes(xPropertyName,
+                keyframes.createXFloatKeyframes());
+        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframes(yPropertyName,
+                keyframes.createYFloatKeyframes());
         return ofPropertyValuesHolder(target, x, y);
     }
 
@@ -469,9 +475,11 @@
      */
     public static <T> ObjectAnimator ofFloat(T target, Property<T, Float> xProperty,
             Property<T, Float> yProperty, Path path) {
-        Keyframe[][] keyframes = PropertyValuesHolder.createKeyframes(path, false);
-        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframe(xProperty, keyframes[0]);
-        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframe(yProperty, keyframes[1]);
+        PathKeyframes keyframes = KeyframeSet.ofPath(path);
+        PropertyValuesHolder x = PropertyValuesHolder.ofKeyframes(xProperty,
+                keyframes.createXFloatKeyframes());
+        PropertyValuesHolder y = PropertyValuesHolder.ofKeyframes(yProperty,
+                keyframes.createYFloatKeyframes());
         return ofPropertyValuesHolder(target, x, y);
     }
 
@@ -652,6 +660,10 @@
      * uses a type other than <code>PointF</code>, <code>converter</code> can be used to change
      * from <code>PointF</code> to the type associated with the <code>Property</code>.
      *
+     * <p>The PointF passed to <code>converter</code> or <code>property</code>, if
+     * <code>converter</code> is <code>null</code>, is reused on each animation frame and should
+     * not be stored by the setter or TypeConverter.</p>
+     *
      * @param target The object whose property is to be animated.
      * @param property The property being animated. Should not be null.
      * @param converter Converts a PointF to the type associated with the setter. May be
@@ -809,10 +821,9 @@
             Log.d(LOG_TAG, "Anim target, duration: " + getTarget() + ", " + getDuration());
             for (int i = 0; i < mValues.length; ++i) {
                 PropertyValuesHolder pvh = mValues[i];
-                ArrayList<Keyframe> keyframes = pvh.mKeyframeSet.mKeyframes;
                 Log.d(LOG_TAG, "   Values[" + i + "]: " +
-                    pvh.getPropertyName() + ", " + keyframes.get(0).getValue() + ", " +
-                    keyframes.get(pvh.mKeyframeSet.mNumKeyframes - 1).getValue());
+                    pvh.getPropertyName() + ", " + pvh.mKeyframes.getValue(0) + ", " +
+                    pvh.mKeyframes.getValue(1));
             }
         }
         super.start();
diff --git a/core/java/android/animation/PathKeyframes.java b/core/java/android/animation/PathKeyframes.java
new file mode 100644
index 0000000..2a47b68
--- /dev/null
+++ b/core/java/android/animation/PathKeyframes.java
@@ -0,0 +1,258 @@
+/*
+ * Copyright (C) 2014 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 android.animation;
+
+import android.graphics.Path;
+import android.graphics.PointF;
+
+import java.util.ArrayList;
+
+/**
+ * PathKeyframes relies on approximating the Path as a series of line segments.
+ * The line segments are recursively divided until there is less than 1/2 pixel error
+ * between the lines and the curve. Each point of the line segment is converted
+ * to a Keyframe and a linear interpolation between Keyframes creates a good approximation
+ * of the curve.
+ * <p>
+ * PathKeyframes is optimized to reduce the number of objects created when there are
+ * many keyframes for a curve.
+ * </p>
+ * <p>
+ * Typically, the returned type is a PointF, but the individual components can be extracted
+ * as either an IntKeyframes or FloatKeyframes.
+ * </p>
+ */
+class PathKeyframes implements Keyframes {
+    private static final int FRACTION_OFFSET = 0;
+    private static final int X_OFFSET = 1;
+    private static final int Y_OFFSET = 2;
+    private static final int NUM_COMPONENTS = 3;
+    private static final ArrayList<Keyframe> EMPTY_KEYFRAMES = new ArrayList<Keyframe>();
+
+    private PointF mTempPointF = new PointF();
+    private float[] mKeyframeData;
+
+    public PathKeyframes(Path path) {
+        this(path, 0.5f);
+    }
+
+    public PathKeyframes(Path path, float error) {
+        if (path == null || path.isEmpty()) {
+            throw new IllegalArgumentException("The path must not be null or empty");
+        }
+        mKeyframeData = path.approximate(error);
+    }
+
+    @Override
+    public ArrayList<Keyframe> getKeyframes() {
+        return EMPTY_KEYFRAMES;
+    }
+
+    @Override
+    public Object getValue(float fraction) {
+        int numPoints = mKeyframeData.length / 3;
+        if (fraction < 0) {
+            return interpolateInRange(fraction, 0, 1);
+        } else if (fraction > 1) {
+            return interpolateInRange(fraction, numPoints - 2, numPoints - 1);
+        } else if (fraction == 0) {
+            return pointForIndex(0);
+        } else if (fraction == 1) {
+            return pointForIndex(numPoints - 1);
+        } else {
+            // Binary search for the correct section
+            int low = 0;
+            int high = numPoints - 1;
+
+            while (low <= high) {
+                int mid = (low + high) / 2;
+                float midFraction = mKeyframeData[(mid * NUM_COMPONENTS) + FRACTION_OFFSET];
+
+                if (fraction < midFraction) {
+                    high = mid - 1;
+                } else if (fraction > midFraction) {
+                    low = mid + 1;
+                } else {
+                    return pointForIndex(mid);
+                }
+            }
+
+            // now high is below the fraction and low is above the fraction
+            return interpolateInRange(fraction, high, low);
+        }
+    }
+
+    private PointF interpolateInRange(float fraction, int startIndex, int endIndex) {
+        int startBase = (startIndex * NUM_COMPONENTS);
+        int endBase = (endIndex * NUM_COMPONENTS);
+
+        float startFraction = mKeyframeData[startBase + FRACTION_OFFSET];
+        float endFraction = mKeyframeData[endBase + FRACTION_OFFSET];
+
+        float intervalFraction = (fraction - startFraction)/(endFraction - startFraction);
+
+        float startX = mKeyframeData[startBase + X_OFFSET];
+        float endX = mKeyframeData[endBase + X_OFFSET];
+        float startY = mKeyframeData[startBase + Y_OFFSET];
+        float endY = mKeyframeData[endBase + Y_OFFSET];
+
+        float x = interpolate(intervalFraction, startX, endX);
+        float y = interpolate(intervalFraction, startY, endY);
+
+        mTempPointF.set(x, y);
+        return mTempPointF;
+    }
+
+    @Override
+    public void invalidateCache() {
+    }
+
+    @Override
+    public void setEvaluator(TypeEvaluator evaluator) {
+    }
+
+    @Override
+    public Class getType() {
+        return PointF.class;
+    }
+
+    @Override
+    public Keyframes clone() {
+        Keyframes clone = null;
+        try {
+            clone = (Keyframes) super.clone();
+        } catch (CloneNotSupportedException e) {}
+        return clone;
+    }
+
+    private PointF pointForIndex(int index) {
+        int base = (index * NUM_COMPONENTS);
+        int xOffset = base + X_OFFSET;
+        int yOffset = base + Y_OFFSET;
+        mTempPointF.set(mKeyframeData[xOffset], mKeyframeData[yOffset]);
+        return mTempPointF;
+    }
+
+    private static float interpolate(float fraction, float startValue, float endValue) {
+        float diff = endValue - startValue;
+        return startValue + (diff * fraction);
+    }
+
+    /**
+     * Returns a FloatKeyframes for the X component of the Path.
+     * @return a FloatKeyframes for the X component of the Path.
+     */
+    public FloatKeyframes createXFloatKeyframes() {
+        return new FloatKeyframesBase() {
+            @Override
+            public float getFloatValue(float fraction) {
+                PointF pointF = (PointF) PathKeyframes.this.getValue(fraction);
+                return pointF.x;
+            }
+        };
+    }
+
+    /**
+     * Returns a FloatKeyframes for the Y component of the Path.
+     * @return a FloatKeyframes for the Y component of the Path.
+     */
+    public FloatKeyframes createYFloatKeyframes() {
+        return new FloatKeyframesBase() {
+            @Override
+            public float getFloatValue(float fraction) {
+                PointF pointF = (PointF) PathKeyframes.this.getValue(fraction);
+                return pointF.y;
+            }
+        };
+    }
+
+    /**
+     * Returns an IntKeyframes for the X component of the Path.
+     * @return an IntKeyframes for the X component of the Path.
+     */
+    public IntKeyframes createXIntKeyframes() {
+        return new IntKeyframesBase() {
+            @Override
+            public int getIntValue(float fraction) {
+                PointF pointF = (PointF) PathKeyframes.this.getValue(fraction);
+                return Math.round(pointF.x);
+            }
+        };
+    }
+
+    /**
+     * Returns an IntKeyframeSet for the Y component of the Path.
+     * @return an IntKeyframeSet for the Y component of the Path.
+     */
+    public IntKeyframes createYIntKeyframes() {
+        return new IntKeyframesBase() {
+            @Override
+            public int getIntValue(float fraction) {
+                PointF pointF = (PointF) PathKeyframes.this.getValue(fraction);
+                return Math.round(pointF.y);
+            }
+        };
+    }
+
+    private abstract static class SimpleKeyframes implements Keyframes {
+        @Override
+        public void setEvaluator(TypeEvaluator evaluator) {
+        }
+
+        @Override
+        public void invalidateCache() {
+        }
+
+        @Override
+        public ArrayList<Keyframe> getKeyframes() {
+            return EMPTY_KEYFRAMES;
+        }
+
+        @Override
+        public Keyframes clone() {
+            Keyframes clone = null;
+            try {
+                clone = (Keyframes) super.clone();
+            } catch (CloneNotSupportedException e) {}
+            return clone;
+        }
+    }
+
+    private abstract static class IntKeyframesBase extends SimpleKeyframes implements IntKeyframes {
+        @Override
+        public Class getType() {
+            return Integer.class;
+        }
+
+        @Override
+        public Object getValue(float fraction) {
+            return getIntValue(fraction);
+        }
+    }
+
+    private abstract static class FloatKeyframesBase extends SimpleKeyframes
+            implements FloatKeyframes {
+        @Override
+        public Class getType() {
+            return Float.class;
+        }
+
+        @Override
+        public Object getValue(float fraction) {
+            return getFloatValue(fraction);
+        }
+    }
+}
diff --git a/core/java/android/animation/PropertyValuesHolder.java b/core/java/android/animation/PropertyValuesHolder.java
index 73b83ef..d372933 100644
--- a/core/java/android/animation/PropertyValuesHolder.java
+++ b/core/java/android/animation/PropertyValuesHolder.java
@@ -18,7 +18,6 @@
 
 import android.graphics.Path;
 import android.graphics.PointF;
-import android.util.FloatMath;
 import android.util.FloatProperty;
 import android.util.IntProperty;
 import android.util.Log;
@@ -26,6 +25,7 @@
 
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
+import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.concurrent.locks.ReentrantReadWriteLock;
 
@@ -75,7 +75,7 @@
     /**
      * The set of keyframes (time/value pairs) that define this animation.
      */
-    KeyframeSet mKeyframeSet = null;
+    Keyframes mKeyframes = null;
 
 
     // type evaluators for the primitive types handled by this implementation
@@ -219,11 +219,9 @@
      * @see ObjectAnimator#ofPropertyValuesHolder(Object, PropertyValuesHolder...)
      */
     public static PropertyValuesHolder ofMultiInt(String propertyName, Path path) {
-        Keyframe[] keyframes = createKeyframes(path);
-        KeyframeSet keyframeSet = KeyframeSet.ofKeyframe(keyframes);
-        TypeEvaluator<PointF> evaluator = new PointFEvaluator(new PointF());
+        Keyframes keyframes = KeyframeSet.ofPath(path);
         PointFToIntArray converter = new PointFToIntArray();
-        return new MultiIntValuesHolder(propertyName, converter, evaluator, keyframeSet);
+        return new MultiIntValuesHolder(propertyName, converter, null, keyframes);
     }
 
     /**
@@ -339,11 +337,9 @@
      * @see ObjectAnimator#ofPropertyValuesHolder(Object, PropertyValuesHolder...)
      */
     public static PropertyValuesHolder ofMultiFloat(String propertyName, Path path) {
-        Keyframe[] keyframes = createKeyframes(path);
-        KeyframeSet keyframeSet = KeyframeSet.ofKeyframe(keyframes);
-        TypeEvaluator<PointF> evaluator = new PointFEvaluator(new PointF());
+        Keyframes keyframes = KeyframeSet.ofPath(path);
         PointFToFloatArray converter = new PointFToFloatArray();
-        return new MultiFloatValuesHolder(propertyName, converter, evaluator, keyframeSet);
+        return new MultiFloatValuesHolder(propertyName, converter, null, keyframes);
     }
 
     /**
@@ -415,6 +411,10 @@
      * <code>TypeConverter</code> to convert from <code>PointF</code> to the target
      * type.
      *
+     * <p>The PointF passed to <code>converter</code> or <code>property</code>, if
+     * <code>converter</code> is <code>null</code>, is reused on each animation frame and should
+     * not be stored by the setter or TypeConverter.</p>
+     *
      * @param propertyName The name of the property being animated.
      * @param converter Converts a PointF to the type associated with the setter. May be
      *                  null if conversion is unnecessary.
@@ -423,9 +423,9 @@
      */
     public static PropertyValuesHolder ofObject(String propertyName,
             TypeConverter<PointF, ?> converter, Path path) {
-        Keyframe[] keyframes = createKeyframes(path);
-        PropertyValuesHolder pvh = ofKeyframe(propertyName, keyframes);
-        pvh.setEvaluator(new PointFEvaluator(new PointF()));
+        PropertyValuesHolder pvh = new PropertyValuesHolder(propertyName);
+        pvh.mKeyframes = KeyframeSet.ofPath(path);
+        pvh.mValueType = PointF.class;
         pvh.setConverter(converter);
         return pvh;
     }
@@ -484,6 +484,10 @@
      * <code>TypeConverter</code> to convert from <code>PointF</code> to the target
      * type.
      *
+     * <p>The PointF passed to <code>converter</code> or <code>property</code>, if
+     * <code>converter</code> is <code>null</code>, is reused on each animation frame and should
+     * not be stored by the setter or TypeConverter.</p>
+     *
      * @param property The property being animated. Should not be null.
      * @param converter Converts a PointF to the type associated with the setter. May be
      *                  null if conversion is unnecessary.
@@ -492,9 +496,9 @@
      */
     public static <V> PropertyValuesHolder ofObject(Property<?, V> property,
             TypeConverter<PointF, V> converter, Path path) {
-        Keyframe[] keyframes = createKeyframes(path);
-        PropertyValuesHolder pvh = ofKeyframe(property, keyframes);
-        pvh.setEvaluator(new PointFEvaluator(new PointF()));
+        PropertyValuesHolder pvh = new PropertyValuesHolder(property);
+        pvh.mKeyframes = KeyframeSet.ofPath(path);
+        pvh.mValueType = PointF.class;
         pvh.setConverter(converter);
         return pvh;
     }
@@ -520,17 +524,7 @@
      */
     public static PropertyValuesHolder ofKeyframe(String propertyName, Keyframe... values) {
         KeyframeSet keyframeSet = KeyframeSet.ofKeyframe(values);
-        if (keyframeSet instanceof IntKeyframeSet) {
-            return new IntPropertyValuesHolder(propertyName, (IntKeyframeSet) keyframeSet);
-        } else if (keyframeSet instanceof FloatKeyframeSet) {
-            return new FloatPropertyValuesHolder(propertyName, (FloatKeyframeSet) keyframeSet);
-        }
-        else {
-            PropertyValuesHolder pvh = new PropertyValuesHolder(propertyName);
-            pvh.mKeyframeSet = keyframeSet;
-            pvh.mValueType = ((Keyframe)values[0]).getType();
-            return pvh;
-        }
+        return ofKeyframes(propertyName, keyframeSet);
     }
 
     /**
@@ -551,15 +545,32 @@
      */
     public static PropertyValuesHolder ofKeyframe(Property property, Keyframe... values) {
         KeyframeSet keyframeSet = KeyframeSet.ofKeyframe(values);
-        if (keyframeSet instanceof IntKeyframeSet) {
-            return new IntPropertyValuesHolder(property, (IntKeyframeSet) keyframeSet);
-        } else if (keyframeSet instanceof FloatKeyframeSet) {
-            return new FloatPropertyValuesHolder(property, (FloatKeyframeSet) keyframeSet);
+        return ofKeyframes(property, keyframeSet);
+    }
+
+    static PropertyValuesHolder ofKeyframes(String propertyName, Keyframes keyframes) {
+        if (keyframes instanceof Keyframes.IntKeyframes) {
+            return new IntPropertyValuesHolder(propertyName, (Keyframes.IntKeyframes) keyframes);
+        } else if (keyframes instanceof Keyframes.FloatKeyframes) {
+            return new FloatPropertyValuesHolder(propertyName,
+                    (Keyframes.FloatKeyframes) keyframes);
+        } else {
+            PropertyValuesHolder pvh = new PropertyValuesHolder(propertyName);
+            pvh.mKeyframes = keyframes;
+            pvh.mValueType = keyframes.getType();
+            return pvh;
         }
-        else {
+    }
+
+    static PropertyValuesHolder ofKeyframes(Property property, Keyframes keyframes) {
+        if (keyframes instanceof Keyframes.IntKeyframes) {
+            return new IntPropertyValuesHolder(property, (Keyframes.IntKeyframes) keyframes);
+        } else if (keyframes instanceof Keyframes.FloatKeyframes) {
+            return new FloatPropertyValuesHolder(property, (Keyframes.FloatKeyframes) keyframes);
+        } else {
             PropertyValuesHolder pvh = new PropertyValuesHolder(property);
-            pvh.mKeyframeSet = keyframeSet;
-            pvh.mValueType = ((Keyframe)values[0]).getType();
+            pvh.mKeyframes = keyframes;
+            pvh.mValueType = keyframes.getType();
             return pvh;
         }
     }
@@ -579,7 +590,7 @@
      */
     public void setIntValues(int... values) {
         mValueType = int.class;
-        mKeyframeSet = KeyframeSet.ofInt(values);
+        mKeyframes = KeyframeSet.ofInt(values);
     }
 
     /**
@@ -597,7 +608,7 @@
      */
     public void setFloatValues(float... values) {
         mValueType = float.class;
-        mKeyframeSet = KeyframeSet.ofFloat(values);
+        mKeyframes = KeyframeSet.ofFloat(values);
     }
 
     /**
@@ -612,7 +623,7 @@
         for (int i = 0; i < numKeyframes; ++i) {
             keyframes[i] = (Keyframe)values[i];
         }
-        mKeyframeSet = new KeyframeSet(keyframes);
+        mKeyframes = new KeyframeSet(keyframes);
     }
 
     /**
@@ -630,9 +641,9 @@
      */
     public void setObjectValues(Object... values) {
         mValueType = values[0].getClass();
-        mKeyframeSet = KeyframeSet.ofObject(values);
+        mKeyframes = KeyframeSet.ofObject(values);
         if (mEvaluator != null) {
-            mKeyframeSet.setEvaluator(mEvaluator);
+            mKeyframes.setEvaluator(mEvaluator);
         }
     }
 
@@ -775,12 +786,15 @@
      * @param target The object on which the setter (and possibly getter) exist.
      */
     void setupSetterAndGetter(Object target) {
-        mKeyframeSet.invalidateCache();
+        mKeyframes.invalidateCache();
         if (mProperty != null) {
             // check to make sure that mProperty is on the class of target
             try {
                 Object testValue = null;
-                for (Keyframe kf : mKeyframeSet.mKeyframes) {
+                ArrayList<Keyframe> keyframes = mKeyframes.getKeyframes();
+                int keyframeCount = keyframes == null ? 0 : keyframes.size();
+                for (int i = 0; i < keyframeCount; i++) {
+                    Keyframe kf = keyframes.get(i);
                     if (!kf.hasValue() || kf.valueWasSetOnStart()) {
                         if (testValue == null) {
                             testValue = convertBack(mProperty.get(target));
@@ -800,7 +814,10 @@
         if (mSetter == null) {
             setupSetter(targetClass);
         }
-        for (Keyframe kf : mKeyframeSet.mKeyframes) {
+        ArrayList<Keyframe> keyframes = mKeyframes.getKeyframes();
+        int keyframeCount = keyframes == null ? 0 : keyframes.size();
+        for (int i = 0; i < keyframeCount; i++) {
+            Keyframe kf = keyframes.get(i);
             if (!kf.hasValue() || kf.valueWasSetOnStart()) {
                 if (mGetter == null) {
                     setupGetter(targetClass);
@@ -873,7 +890,10 @@
      * @param target The object which holds the start values that should be set.
      */
     void setupStartValue(Object target) {
-        setupValue(target, mKeyframeSet.mKeyframes.get(0));
+        ArrayList<Keyframe> keyframes = mKeyframes.getKeyframes();
+        if (!keyframes.isEmpty()) {
+            setupValue(target, keyframes.get(0));
+        }
     }
 
     /**
@@ -885,7 +905,10 @@
      * @param target The object which holds the start values that should be set.
      */
     void setupEndValue(Object target) {
-        setupValue(target, mKeyframeSet.mKeyframes.get(mKeyframeSet.mKeyframes.size() - 1));
+        ArrayList<Keyframe> keyframes = mKeyframes.getKeyframes();
+        if (!keyframes.isEmpty()) {
+            setupValue(target, keyframes.get(keyframes.size() - 1));
+        }
     }
 
     @Override
@@ -894,7 +917,7 @@
             PropertyValuesHolder newPVH = (PropertyValuesHolder) super.clone();
             newPVH.mPropertyName = mPropertyName;
             newPVH.mProperty = mProperty;
-            newPVH.mKeyframeSet = mKeyframeSet.clone();
+            newPVH.mKeyframes = mKeyframes.clone();
             newPVH.mEvaluator = mEvaluator;
             return newPVH;
         } catch (CloneNotSupportedException e) {
@@ -941,7 +964,7 @@
         if (mEvaluator != null) {
             // KeyframeSet knows how to evaluate the common types - only give it a custom
             // evaluator if one has been set on this class
-            mKeyframeSet.setEvaluator(mEvaluator);
+            mKeyframes.setEvaluator(mEvaluator);
         }
     }
 
@@ -957,7 +980,7 @@
      */
     public void setEvaluator(TypeEvaluator evaluator) {
         mEvaluator = evaluator;
-        mKeyframeSet.setEvaluator(evaluator);
+        mKeyframes.setEvaluator(evaluator);
     }
 
     /**
@@ -967,7 +990,7 @@
      * @param fraction The elapsed, interpolated fraction of the animation.
      */
     void calculateValue(float fraction) {
-        Object value = mKeyframeSet.getValue(fraction);
+        Object value = mKeyframes.getValue(fraction);
         mAnimatedValue = mConverter == null ? value : mConverter.convert(value);
     }
 
@@ -1025,7 +1048,7 @@
 
     @Override
     public String toString() {
-        return mPropertyName + ": " + mKeyframeSet.toString();
+        return mPropertyName + ": " + mKeyframes.toString();
     }
 
     /**
@@ -1059,21 +1082,21 @@
         long mJniSetter;
         private IntProperty mIntProperty;
 
-        IntKeyframeSet mIntKeyframeSet;
+        Keyframes.IntKeyframes mIntKeyframes;
         int mIntAnimatedValue;
 
-        public IntPropertyValuesHolder(String propertyName, IntKeyframeSet keyframeSet) {
+        public IntPropertyValuesHolder(String propertyName, Keyframes.IntKeyframes keyframes) {
             super(propertyName);
             mValueType = int.class;
-            mKeyframeSet = keyframeSet;
-            mIntKeyframeSet = (IntKeyframeSet) mKeyframeSet;
+            mKeyframes = keyframes;
+            mIntKeyframes = keyframes;
         }
 
-        public IntPropertyValuesHolder(Property property, IntKeyframeSet keyframeSet) {
+        public IntPropertyValuesHolder(Property property, Keyframes.IntKeyframes keyframes) {
             super(property);
             mValueType = int.class;
-            mKeyframeSet = keyframeSet;
-            mIntKeyframeSet = (IntKeyframeSet) mKeyframeSet;
+            mKeyframes = keyframes;
+            mIntKeyframes = keyframes;
             if (property instanceof  IntProperty) {
                 mIntProperty = (IntProperty) mProperty;
             }
@@ -1095,12 +1118,12 @@
         @Override
         public void setIntValues(int... values) {
             super.setIntValues(values);
-            mIntKeyframeSet = (IntKeyframeSet) mKeyframeSet;
+            mIntKeyframes = (Keyframes.IntKeyframes) mKeyframes;
         }
 
         @Override
         void calculateValue(float fraction) {
-            mIntAnimatedValue = mIntKeyframeSet.getIntValue(fraction);
+            mIntAnimatedValue = mIntKeyframes.getIntValue(fraction);
         }
 
         @Override
@@ -1111,7 +1134,7 @@
         @Override
         public IntPropertyValuesHolder clone() {
             IntPropertyValuesHolder newPVH = (IntPropertyValuesHolder) super.clone();
-            newPVH.mIntKeyframeSet = (IntKeyframeSet) newPVH.mKeyframeSet;
+            newPVH.mIntKeyframes = (Keyframes.IntKeyframes) newPVH.mKeyframes;
             return newPVH;
         }
 
@@ -1196,21 +1219,21 @@
         long mJniSetter;
         private FloatProperty mFloatProperty;
 
-        FloatKeyframeSet mFloatKeyframeSet;
+        Keyframes.FloatKeyframes mFloatKeyframes;
         float mFloatAnimatedValue;
 
-        public FloatPropertyValuesHolder(String propertyName, FloatKeyframeSet keyframeSet) {
+        public FloatPropertyValuesHolder(String propertyName, Keyframes.FloatKeyframes keyframes) {
             super(propertyName);
             mValueType = float.class;
-            mKeyframeSet = keyframeSet;
-            mFloatKeyframeSet = (FloatKeyframeSet) mKeyframeSet;
+            mKeyframes = keyframes;
+            mFloatKeyframes = keyframes;
         }
 
-        public FloatPropertyValuesHolder(Property property, FloatKeyframeSet keyframeSet) {
+        public FloatPropertyValuesHolder(Property property, Keyframes.FloatKeyframes keyframes) {
             super(property);
             mValueType = float.class;
-            mKeyframeSet = keyframeSet;
-            mFloatKeyframeSet = (FloatKeyframeSet) mKeyframeSet;
+            mKeyframes = keyframes;
+            mFloatKeyframes = keyframes;
             if (property instanceof FloatProperty) {
                 mFloatProperty = (FloatProperty) mProperty;
             }
@@ -1232,12 +1255,12 @@
         @Override
         public void setFloatValues(float... values) {
             super.setFloatValues(values);
-            mFloatKeyframeSet = (FloatKeyframeSet) mKeyframeSet;
+            mFloatKeyframes = (Keyframes.FloatKeyframes) mKeyframes;
         }
 
         @Override
         void calculateValue(float fraction) {
-            mFloatAnimatedValue = mFloatKeyframeSet.getFloatValue(fraction);
+            mFloatAnimatedValue = mFloatKeyframes.getFloatValue(fraction);
         }
 
         @Override
@@ -1248,7 +1271,7 @@
         @Override
         public FloatPropertyValuesHolder clone() {
             FloatPropertyValuesHolder newPVH = (FloatPropertyValuesHolder) super.clone();
-            newPVH.mFloatKeyframeSet = (FloatKeyframeSet) newPVH.mKeyframeSet;
+            newPVH.mFloatKeyframes = (Keyframes.FloatKeyframes) newPVH.mKeyframes;
             return newPVH;
         }
 
@@ -1340,10 +1363,10 @@
         }
 
         public MultiFloatValuesHolder(String propertyName, TypeConverter converter,
-                TypeEvaluator evaluator, KeyframeSet keyframeSet) {
+                TypeEvaluator evaluator, Keyframes keyframes) {
             super(propertyName);
             setConverter(converter);
-            mKeyframeSet = keyframeSet;
+            mKeyframes = keyframes;
             setEvaluator(evaluator);
         }
 
@@ -1443,10 +1466,10 @@
         }
 
         public MultiIntValuesHolder(String propertyName, TypeConverter converter,
-                TypeEvaluator evaluator, KeyframeSet keyframeSet) {
+                TypeEvaluator evaluator, Keyframes keyframes) {
             super(propertyName);
             setConverter(converter);
-            mKeyframeSet = keyframeSet;
+            mKeyframes = keyframes;
             setEvaluator(evaluator);
         }
 
@@ -1532,77 +1555,6 @@
         }
     }
 
-    /* Path interpolation relies on approximating the Path as a series of line segments.
-       The line segments are recursively divided until there is less than 1/2 pixel error
-       between the lines and the curve. Each point of the line segment is converted
-       to a Keyframe and a linear interpolation between Keyframes creates a good approximation
-       of the curve.
-
-       The fraction for each Keyframe is the length along the Path to the point, divided by
-       the total Path length. Two points may have the same fraction in the case of a move
-       command causing a disjoint Path.
-
-       The value for each Keyframe is either the point as a PointF or one of the x or y
-       coordinates as an int or float. In the latter case, two Keyframes are generated for
-       each point that have the same fraction. */
-
-    /**
-     * Returns separate Keyframes arrays for the x and y coordinates along a Path. If
-     * isInt is true, the Keyframes will be IntKeyframes, otherwise they will be FloatKeyframes.
-     * The element at index 0 are the x coordinate Keyframes and element at index 1 are the
-     * y coordinate Keyframes. The returned values can be linearly interpolated and get less
-     * than 1/2 pixel error.
-     */
-    static Keyframe[][] createKeyframes(Path path, boolean isInt) {
-        if (path == null || path.isEmpty()) {
-            throw new IllegalArgumentException("The path must not be null or empty");
-        }
-        float[] pointComponents = path.approximate(0.5f);
-
-        int numPoints = pointComponents.length / 3;
-
-        Keyframe[][] keyframes = new Keyframe[2][];
-        keyframes[0] = new Keyframe[numPoints];
-        keyframes[1] = new Keyframe[numPoints];
-        int componentIndex = 0;
-        for (int i = 0; i < numPoints; i++) {
-            float fraction = pointComponents[componentIndex++];
-            float x = pointComponents[componentIndex++];
-            float y = pointComponents[componentIndex++];
-            if (isInt) {
-                keyframes[0][i] = Keyframe.ofInt(fraction, Math.round(x));
-                keyframes[1][i] = Keyframe.ofInt(fraction, Math.round(y));
-            } else {
-                keyframes[0][i] = Keyframe.ofFloat(fraction, x);
-                keyframes[1][i] = Keyframe.ofFloat(fraction, y);
-            }
-        }
-        return keyframes;
-    }
-
-    /**
-     * Returns PointF Keyframes for a Path. The resulting points can be linearly interpolated
-     * with less than 1/2 pixel in error.
-     */
-    private static Keyframe[] createKeyframes(Path path) {
-        if (path == null || path.isEmpty()) {
-            throw new IllegalArgumentException("The path must not be null or empty");
-        }
-        float[] pointComponents = path.approximate(0.5f);
-
-        int numPoints = pointComponents.length / 3;
-
-        Keyframe[] keyframes = new Keyframe[numPoints];
-        int componentIndex = 0;
-        for (int i = 0; i < numPoints; i++) {
-            float fraction = pointComponents[componentIndex++];
-            float x = pointComponents[componentIndex++];
-            float y = pointComponents[componentIndex++];
-            keyframes[i] = Keyframe.ofObject(fraction, new PointF(x, y));
-        }
-        return keyframes;
-    }
-
     /**
      * Convert from PointF to float[] for multi-float setters along a Path.
      */
diff --git a/core/java/android/animation/RevealAnimator.java b/core/java/android/animation/RevealAnimator.java
index e363a77..0f85f49 100644
--- a/core/java/android/animation/RevealAnimator.java
+++ b/core/java/android/animation/RevealAnimator.java
@@ -26,148 +26,21 @@
  *
  * @hide
  */
-public class RevealAnimator extends ValueAnimator {
+public class RevealAnimator extends RenderNodeAnimator {
 
     private View mClipView;
-    private int mX, mY;
-    private float mStartRadius, mEndRadius;
-    private float mDelta;
-    private boolean mMayRunAsync;
-
-    // If this is null, we are running on the UI thread driven by the base
-    // ValueAnimator class. If this is not null, forward requests on to this
-    // Animator instead.
-    private RenderNodeAnimator mRtAnimator;
 
     public RevealAnimator(View clipView, int x, int y,
             float startRadius, float endRadius) {
+        super(x, y, startRadius, endRadius);
         mClipView = clipView;
-        mStartRadius = startRadius;
-        mEndRadius = endRadius;
-        mDelta = endRadius - startRadius;
-        mX = x;
-        mY = y;
-        super.setValues(PropertyValuesHolder.ofFloat("radius", startRadius, endRadius));
+        setTarget(mClipView);
     }
 
     @Override
-    void animateValue(float fraction) {
-        super.animateValue(fraction);
-        fraction = getAnimatedFraction();
-        float radius = mStartRadius + (mDelta * fraction);
-        mClipView.setRevealClip(true, mX, mY, radius);
-    }
-
-    @Override
-    protected void endAnimation(AnimationHandler handler) {
+    protected void onFinished() {
         mClipView.setRevealClip(false, 0, 0, 0);
-        super.endAnimation(handler);
+        super.onFinished();
     }
 
-    @Override
-    public void setAllowRunningAsynchronously(boolean mayRunAsync) {
-        mMayRunAsync = mayRunAsync;
-    }
-
-    private boolean canRunAsync() {
-        if (!mMayRunAsync) {
-            return false;
-        }
-        if (mUpdateListeners != null && mUpdateListeners.size() > 0) {
-            return false;
-        }
-        // TODO: Have RNA support this
-        if (getRepeatCount() != 0) {
-            return false;
-        }
-        return true;
-    }
-
-    @Override
-    public void start() {
-        if (mRtAnimator != null) {
-            mRtAnimator.end();
-            mRtAnimator = null;
-        }
-        if (canRunAsync()) {
-            mRtAnimator = new RenderNodeAnimator(mX, mY, mStartRadius, mEndRadius);
-            mRtAnimator.setDuration(getDuration());
-            mRtAnimator.setInterpolator(getInterpolator());
-            mRtAnimator.setTarget(mClipView);
-            // TODO: Listeners
-            mRtAnimator.start();
-        } else {
-            super.start();
-        }
-    }
-
-    @Override
-    public void cancel() {
-        if (mRtAnimator != null) {
-            mRtAnimator.cancel();
-        } else {
-            super.cancel();
-        }
-    }
-
-    @Override
-    public void end() {
-        if (mRtAnimator != null) {
-            mRtAnimator.end();
-        } else {
-            super.end();
-        }
-    }
-
-    @Override
-    public void resume() {
-        if (mRtAnimator != null) {
-            // TODO: Support? Reject?
-        } else {
-            super.resume();
-        }
-    }
-
-    @Override
-    public void pause() {
-        if (mRtAnimator != null) {
-            // TODO: see resume()
-        } else {
-            super.pause();
-        }
-    }
-
-    @Override
-    public boolean isRunning() {
-        if (mRtAnimator != null) {
-            return mRtAnimator.isRunning();
-        } else {
-            return super.isRunning();
-        }
-    }
-
-    @Override
-    public boolean isStarted() {
-        if (mRtAnimator != null) {
-            return mRtAnimator.isStarted();
-        } else {
-            return super.isStarted();
-        }
-    }
-
-    @Override
-    public void reverse() {
-        if (mRtAnimator != null) {
-            // TODO support
-        } else {
-            super.reverse();
-        }
-    }
-
-    @Override
-    public RevealAnimator clone() {
-        RevealAnimator anim = (RevealAnimator) super.clone();
-        anim.mRtAnimator = null;
-        return anim;
-    }
 }
diff --git a/core/java/android/app/ActionBar.java b/core/java/android/app/ActionBar.java
index b74c824..014a7af 100644
--- a/core/java/android/app/ActionBar.java
+++ b/core/java/android/app/ActionBar.java
@@ -1061,6 +1061,10 @@
         return false;
     }
 
+    /** @hide */
+    public void setWindowTitle(CharSequence title) {
+    }
+
     /**
      * Listener interface for ActionBar navigation events.
      *
diff --git a/core/java/android/app/Activity.java b/core/java/android/app/Activity.java
index 21c8b75..701ab1d 100644
--- a/core/java/android/app/Activity.java
+++ b/core/java/android/app/Activity.java
@@ -54,7 +54,6 @@
 import android.graphics.drawable.Drawable;
 import android.media.AudioManager;
 import android.media.session.MediaController;
-import android.media.session.MediaSession;
 import android.net.Uri;
 import android.os.Build;
 import android.os.Bundle;
@@ -789,8 +788,8 @@
     final Handler mHandler = new Handler();
 
     ActivityTransitionState mActivityTransitionState = new ActivityTransitionState();
-    SharedElementListener mEnterTransitionListener = SharedElementListener.NULL_LISTENER;
-    SharedElementListener mExitTransitionListener = SharedElementListener.NULL_LISTENER;
+    SharedElementCallback mEnterTransitionListener = SharedElementCallback.NULL_CALLBACK;
+    SharedElementCallback mExitTransitionListener = SharedElementCallback.NULL_CALLBACK;
 
     /** Return the intent that started this activity. */
     public Intent getIntent() {
@@ -956,7 +955,7 @@
      * @see #onRestoreInstanceState
      * @see #onPostCreate
      */
-    protected void onCreate(@Nullable Bundle savedInstanceState,
+    public void onCreate(@Nullable Bundle savedInstanceState,
             @Nullable PersistableBundle persistentState) {
         onCreate(savedInstanceState);
     }
@@ -1041,7 +1040,7 @@
      * @see #onResume
      * @see #onSaveInstanceState
      */
-    protected void onRestoreInstanceState(Bundle savedInstanceState,
+    public void onRestoreInstanceState(Bundle savedInstanceState,
             PersistableBundle persistentState) {
         if (savedInstanceState != null) {
             onRestoreInstanceState(savedInstanceState);
@@ -1131,7 +1130,7 @@
      *
      * @see #onCreate
      */
-    protected void onPostCreate(@Nullable Bundle savedInstanceState,
+    public void onPostCreate(@Nullable Bundle savedInstanceState,
             @Nullable PersistableBundle persistentState) {
         onPostCreate(savedInstanceState);
     }
@@ -1237,18 +1236,22 @@
     }
 
     /**
+     * @hide
      * Check whether this activity is running as part of a voice interaction with the user.
      * If true, it should perform its interaction with the user through the
      * {@link VoiceInteractor} returned by {@link #getVoiceInteractor}.
      */
+    @SystemApi
     public boolean isVoiceInteraction() {
         return mVoiceInteractor != null;
     }
 
     /**
+     * @hide
      * Retrieve the active {@link VoiceInteractor} that the user is going through to
      * interact with this activity.
      */
+    @SystemApi
     public VoiceInteractor getVoiceInteractor() {
         return mVoiceInteractor;
     }
@@ -1377,7 +1380,7 @@
      * @see #onRestoreInstanceState(Bundle, PersistableBundle)
      * @see #onPause
      */
-    protected void onSaveInstanceState(Bundle outState, PersistableBundle outPersistentState) {
+    public void onSaveInstanceState(Bundle outState, PersistableBundle outPersistentState) {
         onSaveInstanceState(outState);
     }
 
@@ -2095,7 +2098,9 @@
                     "by the window decor. Do not request Window.FEATURE_ACTION_BAR and set " +
                     "android:windowActionBar to false in your theme to use a Toolbar instead.");
         }
-        mActionBar = new ToolbarActionBar(toolbar, getTitle(), this);
+        ToolbarActionBar tbab = new ToolbarActionBar(toolbar, getTitle(), this);
+        mActionBar = tbab;
+        mWindow.setCallback(tbab.getWrappedWindowCallback());
         mActionBar.invalidateOptionsMenu();
     }
 
@@ -3820,6 +3825,29 @@
     }
 
     /**
+     * Start a new activity as if it was started by the activity that started our
+     * current activity.  This is for the resolver and chooser activities, which operate
+     * as intermediaries that dispatch their intent to the target the user selects -- to
+     * do this, they must perform all security checks including permission grants as if
+     * their launch had come from the original activity.
+     * @hide
+     */
+    public void startActivityAsCaller(Intent intent, @Nullable Bundle options) {
+        if (mParent != null) {
+            throw new RuntimeException("Can't be called from a child");
+        }
+        Instrumentation.ActivityResult ar =
+                mInstrumentation.execStartActivityAsCaller(
+                        this, mMainThread.getApplicationThread(), mToken, this,
+                        intent, -1, options);
+        if (ar != null) {
+            mMainThread.sendActivityResult(
+                mToken, mEmbeddedID, -1, ar.getResultCode(),
+                ar.getResultData());
+        }
+    }
+
+    /**
      * Same as calling {@link #startIntentSenderForResult(IntentSender, int,
      * Intent, int, int, int, Bundle)} with no options.
      *
@@ -4121,10 +4149,9 @@
                 intent.prepareToLeaveProcess();
                 result = ActivityManagerNative.getDefault()
                     .startActivity(mMainThread.getApplicationThread(), getBasePackageName(),
-                            intent, intent.resolveTypeIfNeeded(getContentResolver()),
-                            mToken, mEmbeddedID, requestCode,
-                            ActivityManager.START_FLAG_ONLY_IF_NEEDED, null, null,
-                            options);
+                            intent, intent.resolveTypeIfNeeded(getContentResolver()), mToken,
+                            mEmbeddedID, requestCode, ActivityManager.START_FLAG_ONLY_IF_NEEDED,
+                            null, options);
             } catch (RemoteException e) {
                 // Empty
             }
@@ -4680,6 +4707,26 @@
     }
 
     /**
+     * Ask that the local app instance of this activity be released to free up its memory.
+     * This is asking for the activity to be destroyed, but does <b>not</b> finish the activity --
+     * a new instance of the activity will later be re-created if needed due to the user
+     * navigating back to it.
+     *
+     * @return Returns true if the activity was in a state that it has started the process
+     * of destroying its current instance; returns false if for any reason this could not
+     * be done: it is currently visible to the user, it is already being destroyed, it is
+     * being finished, it hasn't yet saved its state, etc.
+     */
+    public boolean releaseInstance() {
+        try {
+            return ActivityManagerNative.getDefault().releaseActivityInstance(mToken);
+        } catch (RemoteException e) {
+            // Empty
+        }
+        return false;
+    }
+
+    /**
      * Called when an activity you launched exits, giving you the requestCode
      * you started it with, the resultCode it returned, and any additional
      * data from it.  The <var>resultCode</var> will be
@@ -4709,7 +4756,7 @@
      * Activity through a returning activity transition, giving you the resultCode
      * and any additional data from it. This method will only be called if the activity
      * set a result code other than {@link #RESULT_CANCELED} and it supports activity
-     * transitions with {@link Window#FEATURE_CONTENT_TRANSITIONS}.
+     * transitions with {@link Window#FEATURE_ACTIVITY_TRANSITIONS}.
      *
      * <p>The purpose of this function is to let the called Activity send a hint about
      * its state so that this underlying Activity can prepare to be exposed. A call to
@@ -4722,7 +4769,7 @@
      * @param data An Intent, which can return result data to the caller
      *               (various data can be attached to Intent "extras").
      */
-    protected void onActivityReenter(int resultCode, Intent data) {
+    public void onActivityReenter(int resultCode, Intent data) {
     }
 
     /**
@@ -4995,6 +5042,9 @@
                     win.setTitleColor(color);
                 }
             }
+            if (mActionBar != null) {
+                mActionBar.setWindowTitle(title);
+            }
         }
     }
 
@@ -5360,6 +5410,7 @@
             mTranslucentCallback = callback;
             mChangeCanvasToTranslucent =
                     ActivityManagerNative.getDefault().convertToTranslucent(mToken, options);
+            WindowManagerGlobal.getInstance().changeCanvasOpacity(mToken, false);
             drawComplete = true;
         } catch (RemoteException e) {
             // Make callback return as though it timed out.
@@ -5413,7 +5464,7 @@
      * this method anytime before a return from {@link #onPause()}. If this call is successful
      * then the activity will remain visible when {@link #onPause()} is called, and can continue to
      * play media in the background, but it must stop playing and release resources prior to or
-     * within the call to {@link #onVisibleBehindCancelled()}. If this call returns false, the 
+     * within the call to {@link #onVisibleBehindCanceled()}. If this call returns false, the 
      * activity will not be visible in the background, and must release any media resources 
      * immediately.
      *
@@ -5429,10 +5480,10 @@
      * @return the resulting visibiity state. If true the activity may remain visible beyond
      *      {@link #onPause()}. If false then the activity may not count on being visible behind
      *      other translucent activities, and must stop any media playback and release resources.
-     *      Returning false may occur in lieu of a call to onVisibleBehindCancelled() so the return
+     *      Returning false may occur in lieu of a call to onVisibleBehindCanceled() so the return
      *      value must be checked.
      *
-     * @see #onVisibleBehindCancelled()
+     * @see #onVisibleBehindCanceled()
      * @see #onBackgroundVisibleBehindChanged(boolean)
      */
     public boolean requestVisibleBehind(boolean visible) {
@@ -5452,7 +5503,7 @@
     /**
      * Called when a translucent activity over this activity is becoming opaque or another
      * activity is being launched. Activities that override this method must call
-     * <code>super.onVisibleBehindCancelled()</code> or a SuperNotCalledException will be thrown.
+     * <code>super.onVisibleBehindCanceled()</code> or a SuperNotCalledException will be thrown.
      *
      * <p>When this method is called the activity has 500 msec to release any resources it may be
      * using while visible in the background.
@@ -5463,7 +5514,7 @@
      * @see #requestVisibleBehind(boolean)
      * @see #onBackgroundVisibleBehindChanged(boolean)
      */
-    public void onVisibleBehindCancelled() {
+    public void onVisibleBehindCanceled() {
         mCalled = true;
     }
 
@@ -5475,7 +5526,7 @@
      * {@link #requestVisibleBehind(boolean)}, false otherwise.
      *
      * @see #requestVisibleBehind(boolean)
-     * @see #onVisibleBehindCancelled()
+     * @see #onVisibleBehindCanceled()
      * @see #onBackgroundVisibleBehindChanged(boolean)
      * @hide
      */
@@ -5498,7 +5549,7 @@
      * @param visible true if a background activity is visible, false otherwise.
      *
      * @see #requestVisibleBehind(boolean)
-     * @see #onVisibleBehindCancelled()
+     * @see #onVisibleBehindCanceled()
      * @hide
      */
     @SystemApi
@@ -5613,8 +5664,8 @@
             if (info.taskAffinity == null) {
                 return false;
             }
-            return !ActivityManagerNative.getDefault()
-                    .targetTaskAffinityMatchesActivity(mToken, info.taskAffinity);
+            return ActivityManagerNative.getDefault()
+                    .shouldUpRecreateTask(mToken, info.taskAffinity);
         } catch (RemoteException e) {
             return false;
         } catch (NameNotFoundException e) {
@@ -5728,33 +5779,33 @@
 
     /**
      * When {@link android.app.ActivityOptions#makeSceneTransitionAnimation(Activity,
-     * android.view.View, String)} was used to start an Activity, <var>listener</var>
+     * android.view.View, String)} was used to start an Activity, <var>callback</var>
      * will be called to handle shared elements on the <i>launched</i> Activity. This requires
-     * {@link Window#FEATURE_CONTENT_TRANSITIONS}.
+     * {@link Window#FEATURE_ACTIVITY_TRANSITIONS}.
      *
-     * @param listener Used to manipulate shared element transitions on the launched Activity.
+     * @param callback Used to manipulate shared element transitions on the launched Activity.
      */
-    public void setEnterSharedElementListener(SharedElementListener listener) {
-        if (listener == null) {
-            listener = SharedElementListener.NULL_LISTENER;
+    public void setEnterSharedElementCallback(SharedElementCallback callback) {
+        if (callback == null) {
+            callback = SharedElementCallback.NULL_CALLBACK;
         }
-        mEnterTransitionListener = listener;
+        mEnterTransitionListener = callback;
     }
 
     /**
      * When {@link android.app.ActivityOptions#makeSceneTransitionAnimation(Activity,
-     * android.view.View, String)} was used to start an Activity, <var>listener</var>
+     * android.view.View, String)} was used to start an Activity, <var>callback</var>
      * will be called to handle shared elements on the <i>launching</i> Activity. Most
      * calls will only come when returning from the started Activity.
-     * This requires {@link Window#FEATURE_CONTENT_TRANSITIONS}.
+     * This requires {@link Window#FEATURE_ACTIVITY_TRANSITIONS}.
      *
-     * @param listener Used to manipulate shared element transitions on the launching Activity.
+     * @param callback Used to manipulate shared element transitions on the launching Activity.
      */
-    public void setExitSharedElementListener(SharedElementListener listener) {
-        if (listener == null) {
-            listener = SharedElementListener.NULL_LISTENER;
+    public void setExitSharedElementCallback(SharedElementCallback callback) {
+        if (callback == null) {
+            callback = SharedElementCallback.NULL_CALLBACK;
         }
-        mExitTransitionListener = listener;
+        mExitTransitionListener = callback;
     }
 
     /**
diff --git a/core/java/android/app/ActivityManager.java b/core/java/android/app/ActivityManager.java
index 4b022ff..9486a72 100644
--- a/core/java/android/app/ActivityManager.java
+++ b/core/java/android/app/ActivityManager.java
@@ -16,9 +16,16 @@
 
 package android.app;
 
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.annotation.SystemApi;
+import android.graphics.Canvas;
+import android.graphics.Matrix;
+import android.graphics.Point;
 import android.os.BatteryStats;
 import android.os.IBinder;
 import android.os.ParcelFileDescriptor;
+
 import com.android.internal.app.ProcessStats;
 import com.android.internal.os.TransferPipe;
 import com.android.internal.util.FastPrintWriter;
@@ -47,16 +54,14 @@
 import android.os.UserHandle;
 import android.text.TextUtils;
 import android.util.DisplayMetrics;
-import android.util.Log;
+import android.util.Size;
 import android.util.Slog;
 
 import java.io.FileDescriptor;
 import java.io.FileOutputStream;
 import java.io.PrintWriter;
 import java.util.ArrayList;
-import java.util.HashMap;
 import java.util.List;
-import java.util.Map;
 
 /**
  * Interact with the overall activities running in the system.
@@ -65,6 +70,8 @@
     private static String TAG = "ActivityManager";
     private static boolean localLOGV = false;
 
+    private static int gMaxRecentTasks = -1;
+
     private final Context mContext;
     private final Handler mHandler;
 
@@ -191,13 +198,6 @@
     public static final int START_FLAG_OPENGL_TRACES = 1<<2;
 
     /**
-     * Flag for IActivityManaqer.startActivity: if the app is being
-     * launched for profiling, automatically stop the profiler once done.
-     * @hide
-     */
-    public static final int START_FLAG_AUTO_STOP_PROFILER = 1<<3;
-
-    /**
      * Result for IActivityManaqer.broadcastIntent: success!
      * @hide
      */
@@ -297,6 +297,8 @@
     /** @hide Process is being cached for later use and is empty. */
     public static final int PROCESS_STATE_CACHED_EMPTY = 13;
 
+    Point mAppTaskThumbnailSize;
+
     /*package*/ ActivityManager(Context context, Handler handler) {
         mContext = context;
         mHandler = handler;
@@ -445,7 +447,7 @@
         // Really brain dead right now -- just take this from the configured
         // vm heap size, and assume it is in megabytes and thus ends with "m".
         String vmHeapSize = SystemProperties.get("dalvik.vm.heapsize", "16m");
-        return Integer.parseInt(vmHeapSize.substring(0, vmHeapSize.length()-1));
+        return Integer.parseInt(vmHeapSize.substring(0, vmHeapSize.length() - 1));
     }
 
     /**
@@ -476,6 +478,33 @@
     }
 
     /**
+     * Return the maximum number of recents entries that we will maintain and show.
+     * @hide
+     */
+    static public int getMaxRecentTasksStatic() {
+        if (gMaxRecentTasks < 0) {
+            return gMaxRecentTasks = isLowRamDeviceStatic() ? 50 : 100;
+        }
+        return gMaxRecentTasks;
+    }
+
+    /**
+     * Return the default limit on the number of recents that an app can make.
+     * @hide
+     */
+    static public int getDefaultAppRecentsLimitStatic() {
+        return getMaxRecentTasksStatic() / 6;
+    }
+
+    /**
+     * Return the maximum limit on the number of recents that an app can make.
+     * @hide
+     */
+    static public int getMaxAppRecentsLimitStatic() {
+        return getMaxRecentTasksStatic() / 2;
+    }
+
+    /**
      * Information you can set and retrieve about the current activity within the recent task list.
      */
     public static class TaskDescription implements Parcelable {
@@ -792,6 +821,12 @@
     public static final int RECENT_INCLUDE_PROFILES = 0x0004;
 
     /**
+     * Ignores all tasks that are on the home stack.
+     * @hide
+     */
+    public static final int RECENT_IGNORE_HOME_STACK_TASKS = 0x0008;
+
+    /**
      * <p></p>Return a list of the tasks that the user has recently launched, with
      * the most recent being first and older ones after in order.
      *
@@ -981,7 +1016,7 @@
         ArrayList<AppTask> tasks = new ArrayList<AppTask>();
         List<IAppTask> appTasks;
         try {
-            appTasks = ActivityManagerNative.getDefault().getAppTasks();
+            appTasks = ActivityManagerNative.getDefault().getAppTasks(mContext.getPackageName());
         } catch (RemoteException e) {
             // System dead, we will be dead too soon!
             return null;
@@ -994,6 +1029,92 @@
     }
 
     /**
+     * Return the current design dimensions for {@link AppTask} thumbnails, for use
+     * with {@link #addAppTask}.
+     */
+    public Size getAppTaskThumbnailSize() {
+        synchronized (this) {
+            ensureAppTaskThumbnailSizeLocked();
+            return new Size(mAppTaskThumbnailSize.x, mAppTaskThumbnailSize.y);
+        }
+    }
+
+    private void ensureAppTaskThumbnailSizeLocked() {
+        if (mAppTaskThumbnailSize == null) {
+            try {
+                mAppTaskThumbnailSize = ActivityManagerNative.getDefault().getAppTaskThumbnailSize();
+            } catch (RemoteException e) {
+                throw new IllegalStateException("System dead?", e);
+            }
+        }
+    }
+
+    /**
+     * Add a new {@link AppTask} for the calling application.  This will create a new
+     * recents entry that is added to the <b>end</b> of all existing recents.
+     *
+     * @param activity The activity that is adding the entry.   This is used to help determine
+     * the context that the new recents entry will be in.
+     * @param intent The Intent that describes the recents entry.  This is the same Intent that
+     * you would have used to launch the activity for it.  In generally you will want to set
+     * both {@link Intent#FLAG_ACTIVITY_NEW_DOCUMENT} and
+     * {@link Intent#FLAG_ACTIVITY_RETAIN_IN_RECENTS}; the latter is required since this recents
+     * entry will exist without an activity, so it doesn't make sense to not retain it when
+     * its activity disappears.  The given Intent here also must have an explicit ComponentName
+     * set on it.
+     * @param description Optional additional description information.
+     * @param thumbnail Thumbnail to use for the recents entry.  Should be the size given by
+     * {@link #getAppTaskThumbnailSize()}.  If the bitmap is not that exact size, it will be
+     * recreated in your process, probably in a way you don't like, before the recents entry
+     * is added.
+     *
+     * @return Returns the task id of the newly added app task, or -1 if the add failed.  The
+     * most likely cause of failure is that there is no more room for more tasks for your app.
+     */
+    public int addAppTask(@NonNull Activity activity, @NonNull Intent intent,
+            @Nullable TaskDescription description, @NonNull Bitmap thumbnail) {
+        Point size;
+        synchronized (this) {
+            ensureAppTaskThumbnailSizeLocked();
+            size = mAppTaskThumbnailSize;
+        }
+        final int tw = thumbnail.getWidth();
+        final int th = thumbnail.getHeight();
+        if (tw != size.x || th != size.y) {
+            Bitmap bm = Bitmap.createBitmap(size.x, size.y, thumbnail.getConfig());
+
+            // Use ScaleType.CENTER_CROP, except we leave the top edge at the top.
+            float scale;
+            float dx = 0, dy = 0;
+            if (tw * size.x > size.y * th) {
+                scale = (float) size.x / (float) th;
+                dx = (size.y - tw * scale) * 0.5f;
+            } else {
+                scale = (float) size.y / (float) tw;
+                dy = (size.x - th * scale) * 0.5f;
+            }
+            Matrix matrix = new Matrix();
+            matrix.setScale(scale, scale);
+            matrix.postTranslate((int) (dx + 0.5f), 0);
+
+            Canvas canvas = new Canvas(bm);
+            canvas.drawBitmap(thumbnail, matrix, null);
+            canvas.setBitmap(null);
+
+            thumbnail = bm;
+        }
+        if (description == null) {
+            description = new TaskDescription();
+        }
+        try {
+            return ActivityManagerNative.getDefault().addAppTask(activity.getActivityToken(),
+                    intent, description, thumbnail);
+        } catch (RemoteException e) {
+            throw new IllegalStateException("System dead?", e);
+        }
+    }
+
+    /**
      * Return a list of the tasks that are currently running, with
      * the most recent being first and older ones after in order.  Note that
      * "running" does not mean any of the task's code is currently loaded or
@@ -1084,13 +1205,13 @@
         public void writeToParcel(Parcel dest, int flags) {
             if (mainThumbnail != null) {
                 dest.writeInt(1);
-                mainThumbnail.writeToParcel(dest, 0);
+                mainThumbnail.writeToParcel(dest, flags);
             } else {
                 dest.writeInt(0);
             }
             if (thumbnailFileDescriptor != null) {
                 dest.writeInt(1);
-                thumbnailFileDescriptor.writeToParcel(dest, 0);
+                thumbnailFileDescriptor.writeToParcel(dest, flags);
             } else {
                 dest.writeInt(0);
             }
@@ -2345,7 +2466,11 @@
         }
     }
 
-    /** @hide */
+    /**
+     * Gets the userId of the current foreground user. Requires system permissions.
+     * @hide
+     */
+    @SystemApi
     public static int getCurrentUser() {
         UserInfo ui;
         try {
@@ -2514,5 +2639,61 @@
                 return null;
             }
         }
+
+        /**
+         * Bring this task to the foreground.  If it contains activities, they will be
+         * brought to the foreground with it and their instances re-created if needed.
+         * If it doesn't contain activities, the root activity of the task will be
+         * re-launched.
+         */
+        public void moveToFront() {
+            try {
+                mAppTaskImpl.moveToFront();
+            } catch (RemoteException e) {
+                Slog.e(TAG, "Invalid AppTask", e);
+            }
+        }
+
+        /**
+         * Start an activity in this task.  Brings the task to the foreground.  If this task
+         * is not currently active (that is, its id < 0), then a new activity for the given
+         * Intent will be launched as the root of the task and the task brought to the
+         * foreground.  Otherwise, if this task is currently active and the Intent does not specify
+         * an activity to launch in a new task, then a new activity for the given Intent will
+         * be launched on top of the task and the task brought to the foreground.  If this
+         * task is currently active and the Intent specifies {@link Intent#FLAG_ACTIVITY_NEW_TASK}
+         * or would otherwise be launched in to a new task, then the activity not launched but
+         * this task be brought to the foreground and a new intent delivered to the top
+         * activity if appropriate.
+         *
+         * <p>In other words, you generally want to use an Intent here that does not specify
+         * {@link Intent#FLAG_ACTIVITY_NEW_TASK} or {@link Intent#FLAG_ACTIVITY_NEW_DOCUMENT},
+         * and let the system do the right thing.</p>
+         *
+         * @param intent The Intent describing the new activity to be launched on the task.
+         * @param options Optional launch options.
+         *
+         * @see Activity#startActivity(android.content.Intent, android.os.Bundle)
+         */
+        public void startActivity(Context context, Intent intent, Bundle options) {
+            ActivityThread thread = ActivityThread.currentActivityThread();
+            thread.getInstrumentation().execStartActivityFromAppTask(context,
+                    thread.getApplicationThread(), mAppTaskImpl, intent, options);
+        }
+
+        /**
+         * Modify the {@link Intent#FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS} flag in the root
+         * Intent of this AppTask.
+         *
+         * @param exclude If true, {@link Intent#FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS} will
+         * be set; otherwise, it will be cleared.
+         */
+        public void setExcludeFromRecents(boolean exclude) {
+            try {
+                mAppTaskImpl.setExcludeFromRecents(exclude);
+            } catch (RemoteException e) {
+                Slog.e(TAG, "Invalid AppTask", e);
+            }
+        }
     }
 }
diff --git a/core/java/android/app/ActivityManagerNative.java b/core/java/android/app/ActivityManagerNative.java
index 31cb4d6..677fcef 100644
--- a/core/java/android/app/ActivityManagerNative.java
+++ b/core/java/android/app/ActivityManagerNative.java
@@ -17,6 +17,7 @@
 package android.app;
 
 import android.app.ActivityManager.StackInfo;
+import android.app.ProfilerInfo;
 import android.content.ComponentName;
 import android.content.IIntentReceiver;
 import android.content.IIntentSender;
@@ -30,6 +31,8 @@
 import android.content.pm.ParceledListSlice;
 import android.content.pm.UserInfo;
 import android.content.res.Configuration;
+import android.graphics.Bitmap;
+import android.graphics.Point;
 import android.graphics.Rect;
 import android.net.Uri;
 import android.os.Binder;
@@ -130,14 +133,12 @@
             String resultWho = data.readString();
             int requestCode = data.readInt();
             int startFlags = data.readInt();
-            String profileFile = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? data.readFileDescriptor() : null;
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
             Bundle options = data.readInt() != 0
                     ? Bundle.CREATOR.createFromParcel(data) : null;
             int result = startActivity(app, callingPackage, intent, resolvedType,
-                    resultTo, resultWho, requestCode, startFlags,
-                    profileFile, profileFd, options);
+                    resultTo, resultWho, requestCode, startFlags, profilerInfo, options);
             reply.writeNoException();
             reply.writeInt(result);
             return true;
@@ -155,15 +156,36 @@
             String resultWho = data.readString();
             int requestCode = data.readInt();
             int startFlags = data.readInt();
-            String profileFile = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
             Bundle options = data.readInt() != 0
                     ? Bundle.CREATOR.createFromParcel(data) : null;
             int userId = data.readInt();
             int result = startActivityAsUser(app, callingPackage, intent, resolvedType,
-                    resultTo, resultWho, requestCode, startFlags,
-                    profileFile, profileFd, options, userId);
+                    resultTo, resultWho, requestCode, startFlags, profilerInfo, options, userId);
+            reply.writeNoException();
+            reply.writeInt(result);
+            return true;
+        }
+
+        case START_ACTIVITY_AS_CALLER_TRANSACTION:
+        {
+            data.enforceInterface(IActivityManager.descriptor);
+            IBinder b = data.readStrongBinder();
+            IApplicationThread app = ApplicationThreadNative.asInterface(b);
+            String callingPackage = data.readString();
+            Intent intent = Intent.CREATOR.createFromParcel(data);
+            String resolvedType = data.readString();
+            IBinder resultTo = data.readStrongBinder();
+            String resultWho = data.readString();
+            int requestCode = data.readInt();
+            int startFlags = data.readInt();
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
+            Bundle options = data.readInt() != 0
+                    ? Bundle.CREATOR.createFromParcel(data) : null;
+            int result = startActivityAsCaller(app, callingPackage, intent, resolvedType,
+                    resultTo, resultWho, requestCode, startFlags, profilerInfo, options);
             reply.writeNoException();
             reply.writeInt(result);
             return true;
@@ -181,15 +203,13 @@
             String resultWho = data.readString();
             int requestCode = data.readInt();
             int startFlags = data.readInt();
-            String profileFile = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
             Bundle options = data.readInt() != 0
                     ? Bundle.CREATOR.createFromParcel(data) : null;
             int userId = data.readInt();
             WaitResult result = startActivityAndWait(app, callingPackage, intent, resolvedType,
-                    resultTo, resultWho, requestCode, startFlags,
-                    profileFile, profileFd, options, userId);
+                    resultTo, resultWho, requestCode, startFlags, profilerInfo, options, userId);
             reply.writeNoException();
             result.writeToParcel(reply, 0);
             return true;
@@ -257,15 +277,13 @@
             IVoiceInteractor interactor = IVoiceInteractor.Stub.asInterface(
                     data.readStrongBinder());
             int startFlags = data.readInt();
-            String profileFile = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
             Bundle options = data.readInt() != 0
                     ? Bundle.CREATOR.createFromParcel(data) : null;
             int userId = data.readInt();
-            int result = startVoiceActivity(callingPackage, callingPid, callingUid,
-                    intent, resolvedType, session, interactor, startFlags,
-                    profileFile, profileFd, options, userId);
+            int result = startVoiceActivity(callingPackage, callingPid, callingUid, intent,
+                    resolvedType, session, interactor, startFlags, profilerInfo, options, userId);
             reply.writeNoException();
             reply.writeInt(result);
             return true;
@@ -338,6 +356,23 @@
             return true;
         }
 
+        case RELEASE_ACTIVITY_INSTANCE_TRANSACTION: {
+            data.enforceInterface(IActivityManager.descriptor);
+            IBinder token = data.readStrongBinder();
+            boolean res = releaseActivityInstance(token);
+            reply.writeNoException();
+            reply.writeInt(res ? 1 : 0);
+            return true;
+        }
+
+        case RELEASE_SOME_ACTIVITIES_TRANSACTION: {
+            data.enforceInterface(IActivityManager.descriptor);
+            IApplicationThread app = ApplicationThreadNative.asInterface(data.readStrongBinder());
+            releaseSomeActivities(app);
+            reply.writeNoException();
+            return true;
+        }
+
         case WILL_ACTIVITY_BE_VISIBLE_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             IBinder token = data.readStrongBinder();
@@ -474,8 +509,7 @@
         case ACTIVITY_PAUSED_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             IBinder token = data.readStrongBinder();
-            PersistableBundle persistentState = data.readPersistableBundle();
-            activityPaused(token, persistentState);
+            activityPaused(token);
             reply.writeNoException();
             return true;
         }
@@ -527,7 +561,8 @@
 
         case GET_APP_TASKS_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
-            List<IAppTask> list = getAppTasks();
+            String callingPackage = data.readString();
+            List<IAppTask> list = getAppTasks(callingPackage);
             reply.writeNoException();
             int N = list != null ? list.size() : -1;
             reply.writeInt(N);
@@ -539,6 +574,27 @@
             return true;
         }
 
+        case ADD_APP_TASK_TRANSACTION: {
+            data.enforceInterface(IActivityManager.descriptor);
+            IBinder activityToken = data.readStrongBinder();
+            Intent intent = Intent.CREATOR.createFromParcel(data);
+            ActivityManager.TaskDescription descr
+                    = ActivityManager.TaskDescription.CREATOR.createFromParcel(data);
+            Bitmap thumbnail = Bitmap.CREATOR.createFromParcel(data);
+            int res = addAppTask(activityToken, intent, descr, thumbnail);
+            reply.writeNoException();
+            reply.writeInt(res);
+            return true;
+        }
+
+        case GET_APP_TASK_THUMBNAIL_SIZE_TRANSACTION: {
+            data.enforceInterface(IActivityManager.descriptor);
+            Point size = getAppTaskThumbnailSize();
+            reply.writeNoException();
+            size.writeToParcel(reply, 0);
+            return true;
+        }
+
         case GET_TASKS_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             int maxNum = data.readInt();
@@ -1335,8 +1391,9 @@
             data.enforceInterface(IActivityManager.descriptor);
             IBinder app = data.readStrongBinder();
             String tag = data.readString();
+            boolean system = data.readInt() != 0;
             ApplicationErrorReport.CrashInfo ci = new ApplicationErrorReport.CrashInfo(data);
-            boolean res = handleApplicationWtf(app, tag, ci);
+            boolean res = handleApplicationWtf(app, tag, system, ci);
             reply.writeNoException();
             reply.writeInt(res ? 1 : 0);
             return true;
@@ -1402,22 +1459,21 @@
             config.writeToParcel(reply, 0);
             return true;
         }
-        
+
         case PROFILE_CONTROL_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             String process = data.readString();
             int userId = data.readInt();
             boolean start = data.readInt() != 0;
             int profileType = data.readInt();
-            String path = data.readString();
-            ParcelFileDescriptor fd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
-            boolean res = profileControl(process, userId, start, path, fd, profileType);
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
+            boolean res = profileControl(process, userId, start, profilerInfo, profileType);
             reply.writeNoException();
             reply.writeInt(res ? 1 : 0);
             return true;
         }
-        
+
         case SHUTDOWN_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             boolean res = shutdown(data.readInt());
@@ -1949,11 +2005,11 @@
             return true;
         }
 
-        case TARGET_TASK_AFFINITY_MATCHES_ACTIVITY_TRANSACTION: {
+        case SHOULD_UP_RECREATE_TASK_TRANSACTION: {
             data.enforceInterface(IActivityManager.descriptor);
             IBinder token = data.readStrongBinder();
             String destAffinity = data.readString();
-            boolean res = targetTaskAffinityMatchesActivity(token, destAffinity);
+            boolean res = shouldUpRecreateTask(token, destAffinity);
             reply.writeNoException();
             reply.writeInt(res ? 1 : 0);
             return true;
@@ -2239,6 +2295,13 @@
             reply.writeNoException();
             return true;
         }
+
+        case BOOT_ANIMATION_COMPLETE_TRANSACTION: {
+            data.enforceInterface(IActivityManager.descriptor);
+            bootAnimationComplete();
+            reply.writeNoException();
+            return true;
+        }
         }
 
         return super.onTransact(code, data, reply, flags);
@@ -2277,8 +2340,7 @@
 
     public int startActivity(IApplicationThread caller, String callingPackage, Intent intent,
             String resolvedType, IBinder resultTo, String resultWho, int requestCode,
-            int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options) throws RemoteException {
+            int startFlags, ProfilerInfo profilerInfo, Bundle options) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
@@ -2290,10 +2352,9 @@
         data.writeString(resultWho);
         data.writeInt(requestCode);
         data.writeInt(startFlags);
-        data.writeString(profileFile);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -2313,8 +2374,8 @@
 
     public int startActivityAsUser(IApplicationThread caller, String callingPackage, Intent intent,
             String resolvedType, IBinder resultTo, String resultWho, int requestCode,
-            int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException {
+            int startFlags, ProfilerInfo profilerInfo, Bundle options,
+            int userId) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
@@ -2326,10 +2387,9 @@
         data.writeString(resultWho);
         data.writeInt(requestCode);
         data.writeInt(startFlags);
-        data.writeString(profileFile);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -2347,10 +2407,9 @@
         data.recycle();
         return result;
     }
-    public WaitResult startActivityAndWait(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo, String resultWho,
-            int requestCode, int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException {
+    public int startActivityAsCaller(IApplicationThread caller, String callingPackage,
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, ProfilerInfo profilerInfo, Bundle options) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
@@ -2362,10 +2421,43 @@
         data.writeString(resultWho);
         data.writeInt(requestCode);
         data.writeInt(startFlags);
-        data.writeString(profileFile);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+        } else {
+            data.writeInt(0);
+        }
+        if (options != null) {
+            data.writeInt(1);
+            options.writeToParcel(data, 0);
+        } else {
+            data.writeInt(0);
+        }
+        mRemote.transact(START_ACTIVITY_AS_CALLER_TRANSACTION, data, reply, 0);
+        reply.readException();
+        int result = reply.readInt();
+        reply.recycle();
+        data.recycle();
+        return result;
+    }
+    public WaitResult startActivityAndWait(IApplicationThread caller, String callingPackage,
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho,
+            int requestCode, int startFlags, ProfilerInfo profilerInfo, Bundle options,
+            int userId) throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        data.writeStrongBinder(caller != null ? caller.asBinder() : null);
+        data.writeString(callingPackage);
+        intent.writeToParcel(data, 0);
+        data.writeString(resolvedType);
+        data.writeStrongBinder(resultTo);
+        data.writeString(resultWho);
+        data.writeInt(requestCode);
+        data.writeInt(startFlags);
+        if (profilerInfo != null) {
+            data.writeInt(1);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -2449,8 +2541,8 @@
     }
     public int startVoiceActivity(String callingPackage, int callingPid, int callingUid,
             Intent intent, String resolvedType, IVoiceInteractionSession session,
-            IVoiceInteractor interactor, int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException {
+            IVoiceInteractor interactor, int startFlags, ProfilerInfo profilerInfo,
+            Bundle options, int userId) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
@@ -2462,10 +2554,9 @@
         data.writeStrongBinder(session.asBinder());
         data.writeStrongBinder(interactor.asBinder());
         data.writeInt(startFlags);
-        data.writeString(profileFile);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -2577,6 +2668,28 @@
         data.recycle();
         reply.recycle();
     }
+    public boolean releaseActivityInstance(IBinder token) throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        data.writeStrongBinder(token);
+        mRemote.transact(RELEASE_ACTIVITY_INSTANCE_TRANSACTION, data, reply, 0);
+        reply.readException();
+        boolean res = reply.readInt() != 0;
+        data.recycle();
+        reply.recycle();
+        return res;
+    }
+    public void releaseSomeActivities(IApplicationThread app) throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        data.writeStrongBinder(app.asBinder());
+        mRemote.transact(RELEASE_SOME_ACTIVITIES_TRANSACTION, data, reply, 0);
+        reply.readException();
+        data.recycle();
+        reply.recycle();
+    }
     public boolean willActivityBeVisible(IBinder token) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
@@ -2722,13 +2835,12 @@
         data.recycle();
         reply.recycle();
     }
-    public void activityPaused(IBinder token, PersistableBundle persistentState) throws RemoteException
+    public void activityPaused(IBinder token) throws RemoteException
     {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
         data.writeStrongBinder(token);
-        data.writePersistableBundle(persistentState);
         mRemote.transact(ACTIVITY_PAUSED_TRANSACTION, data, reply, 0);
         reply.readException();
         data.recycle();
@@ -2797,10 +2909,11 @@
         reply.recycle();
         return res;
     }
-    public List<IAppTask> getAppTasks() throws RemoteException {
+    public List<IAppTask> getAppTasks(String callingPackage) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
+        data.writeString(callingPackage);
         mRemote.transact(GET_APP_TASKS_TRANSACTION, data, reply, 0);
         reply.readException();
         ArrayList<IAppTask> list = null;
@@ -2817,6 +2930,33 @@
         reply.recycle();
         return list;
     }
+    public int addAppTask(IBinder activityToken, Intent intent,
+            ActivityManager.TaskDescription description, Bitmap thumbnail) throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        data.writeStrongBinder(activityToken);
+        intent.writeToParcel(data, 0);
+        description.writeToParcel(data, 0);
+        thumbnail.writeToParcel(data, 0);
+        mRemote.transact(ADD_APP_TASK_TRANSACTION, data, reply, 0);
+        reply.readException();
+        int res = reply.readInt();
+        data.recycle();
+        reply.recycle();
+        return res;
+    }
+    public Point getAppTaskThumbnailSize() throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        mRemote.transact(GET_APP_TASK_THUMBNAIL_SIZE_TRANSACTION, data, reply, 0);
+        reply.readException();
+        Point size = Point.CREATOR.createFromParcel(reply);
+        data.recycle();
+        reply.recycle();
+        return size;
+    }
     public List getTasks(int maxNum, int flags) throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
@@ -3935,7 +4075,7 @@
         data.recycle();
     }
 
-    public boolean handleApplicationWtf(IBinder app, String tag,
+    public boolean handleApplicationWtf(IBinder app, String tag, boolean system,
             ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException
     {
         Parcel data = Parcel.obtain();
@@ -3943,6 +4083,7 @@
         data.writeInterfaceToken(IActivityManager.descriptor);
         data.writeStrongBinder(app);
         data.writeString(tag);
+        data.writeInt(system ? 1 : 0);
         crashInfo.writeToParcel(data, 0);
         mRemote.transact(HANDLE_APPLICATION_WTF_TRANSACTION, data, reply, 0);
         reply.readException();
@@ -4038,9 +4179,9 @@
         data.recycle();
         return res;
     }
-    
+
     public boolean profileControl(String process, int userId, boolean start,
-            String path, ParcelFileDescriptor fd, int profileType) throws RemoteException
+            ProfilerInfo profilerInfo, int profileType) throws RemoteException
     {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
@@ -4049,10 +4190,9 @@
         data.writeInt(userId);
         data.writeInt(start ? 1 : 0);
         data.writeInt(profileType);
-        data.writeString(path);
-        if (fd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            fd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -4063,7 +4203,7 @@
         data.recycle();
         return res;
     }
-    
+
     public boolean shutdown(int timeout) throws RemoteException
     {
         Parcel data = Parcel.obtain();
@@ -4748,14 +4888,14 @@
         reply.recycle();
     }
 
-    public boolean targetTaskAffinityMatchesActivity(IBinder token, String destAffinity)
+    public boolean shouldUpRecreateTask(IBinder token, String destAffinity)
             throws RemoteException {
         Parcel data = Parcel.obtain();
         Parcel reply = Parcel.obtain();
         data.writeInterfaceToken(IActivityManager.descriptor);
         data.writeStrongBinder(token);
         data.writeString(destAffinity);
-        mRemote.transact(TARGET_TASK_AFFINITY_MATCHES_ACTIVITY_TRANSACTION, data, reply, 0);
+        mRemote.transact(SHOULD_UP_RECREATE_TASK_TRANSACTION, data, reply, 0);
         reply.readException();
         boolean result = reply.readInt() != 0;
         data.recycle();
@@ -5168,5 +5308,16 @@
         reply.recycle();
     }
 
+    @Override
+    public void bootAnimationComplete() throws RemoteException {
+        Parcel data = Parcel.obtain();
+        Parcel reply = Parcel.obtain();
+        data.writeInterfaceToken(IActivityManager.descriptor);
+        mRemote.transact(BOOT_ANIMATION_COMPLETE_TRANSACTION, data, reply, 0);
+        reply.readException();
+        data.recycle();
+        reply.recycle();
+    }
+
     private IBinder mRemote;
 }
diff --git a/core/java/android/app/ActivityOptions.java b/core/java/android/app/ActivityOptions.java
index 4c02314..cd6a4f5 100644
--- a/core/java/android/app/ActivityOptions.java
+++ b/core/java/android/app/ActivityOptions.java
@@ -84,13 +84,13 @@
      * Initial width of the animation.
      * @hide
      */
-    public static final String KEY_ANIM_START_WIDTH = "android:animStartWidth";
+    public static final String KEY_ANIM_WIDTH = "android:animWidth";
 
     /**
      * Initial height of the animation.
      * @hide
      */
-    public static final String KEY_ANIM_START_HEIGHT = "android:animStartHeight";
+    public static final String KEY_ANIM_HEIGHT = "android:animHeight";
 
     /**
      * Callback for when animation is started.
@@ -128,6 +128,10 @@
     public static final int ANIM_DEFAULT = 6;
     /** @hide */
     public static final int ANIM_LAUNCH_TASK_BEHIND = 7;
+    /** @hide */
+    public static final int ANIM_THUMBNAIL_ASPECT_SCALE_UP = 8;
+    /** @hide */
+    public static final int ANIM_THUMBNAIL_ASPECT_SCALE_DOWN = 9;
 
     private String mPackageName;
     private int mAnimationType = ANIM_NONE;
@@ -136,8 +140,8 @@
     private Bitmap mThumbnail;
     private int mStartX;
     private int mStartY;
-    private int mStartWidth;
-    private int mStartHeight;
+    private int mWidth;
+    private int mHeight;
     private IRemoteCallback mAnimationStartedListener;
     private ResultReceiver mTransitionReceiver;
     private boolean mIsReturning;
@@ -234,13 +238,13 @@
      * defines the coordinate space for <var>startX</var> and <var>startY</var>.
      * @param startX The x starting location of the new activity, relative to <var>source</var>.
      * @param startY The y starting location of the activity, relative to <var>source</var>.
-     * @param startWidth The initial width of the new activity.
-     * @param startHeight The initial height of the new activity.
+     * @param width The initial width of the new activity.
+     * @param height The initial height of the new activity.
      * @return Returns a new ActivityOptions object that you can use to
      * supply these options as the options Bundle when starting an activity.
      */
     public static ActivityOptions makeScaleUpAnimation(View source,
-            int startX, int startY, int startWidth, int startHeight) {
+            int startX, int startY, int width, int height) {
         ActivityOptions opts = new ActivityOptions();
         opts.mPackageName = source.getContext().getPackageName();
         opts.mAnimationType = ANIM_SCALE_UP;
@@ -248,8 +252,8 @@
         source.getLocationOnScreen(pts);
         opts.mStartX = pts[0] + startX;
         opts.mStartY = pts[1] + startY;
-        opts.mStartWidth = startWidth;
-        opts.mStartHeight = startHeight;
+        opts.mWidth = width;
+        opts.mHeight = height;
         return opts;
     }
 
@@ -338,13 +342,79 @@
     }
 
     /**
+     * Create an ActivityOptions specifying an animation where the new activity
+     * window and a thumbnail is aspect-scaled to a new location.
+     *
+     * @param source The View that this thumbnail is animating from.  This
+     * defines the coordinate space for <var>startX</var> and <var>startY</var>.
+     * @param thumbnail The bitmap that will be shown as the initial thumbnail
+     * of the animation.
+     * @param startX The x starting location of the bitmap, relative to <var>source</var>.
+     * @param startY The y starting location of the bitmap, relative to <var>source</var>.
+     * @param listener Optional OnAnimationStartedListener to find out when the
+     * requested animation has started running.  If for some reason the animation
+     * is not executed, the callback will happen immediately.
+     * @return Returns a new ActivityOptions object that you can use to
+     * supply these options as the options Bundle when starting an activity.
+     * @hide
+     */
+    public static ActivityOptions makeThumbnailAspectScaleUpAnimation(View source,
+            Bitmap thumbnail, int startX, int startY, int targetWidth, int targetHeight,
+            OnAnimationStartedListener listener) {
+        return makeAspectScaledThumbnailAnimation(source, thumbnail, startX, startY,
+                targetWidth, targetHeight, listener, true);
+    }
+
+    /**
+     * Create an ActivityOptions specifying an animation where the new activity
+     * window and a thumbnail is aspect-scaled to a new location.
+     *
+     * @param source The View that this thumbnail is animating to.  This
+     * defines the coordinate space for <var>startX</var> and <var>startY</var>.
+     * @param thumbnail The bitmap that will be shown as the final thumbnail
+     * of the animation.
+     * @param startX The x end location of the bitmap, relative to <var>source</var>.
+     * @param startY The y end location of the bitmap, relative to <var>source</var>.
+     * @param listener Optional OnAnimationStartedListener to find out when the
+     * requested animation has started running.  If for some reason the animation
+     * is not executed, the callback will happen immediately.
+     * @return Returns a new ActivityOptions object that you can use to
+     * supply these options as the options Bundle when starting an activity.
+     * @hide
+     */
+    public static ActivityOptions makeThumbnailAspectScaleDownAnimation(View source,
+            Bitmap thumbnail, int startX, int startY, int targetWidth, int targetHeight,
+            OnAnimationStartedListener listener) {
+        return makeAspectScaledThumbnailAnimation(source, thumbnail, startX, startY,
+                targetWidth, targetHeight, listener, false);
+    }
+
+    private static ActivityOptions makeAspectScaledThumbnailAnimation(View source, Bitmap thumbnail,
+            int startX, int startY, int targetWidth, int targetHeight,
+            OnAnimationStartedListener listener, boolean scaleUp) {
+        ActivityOptions opts = new ActivityOptions();
+        opts.mPackageName = source.getContext().getPackageName();
+        opts.mAnimationType = scaleUp ? ANIM_THUMBNAIL_ASPECT_SCALE_UP :
+                ANIM_THUMBNAIL_ASPECT_SCALE_DOWN;
+        opts.mThumbnail = thumbnail;
+        int[] pts = new int[2];
+        source.getLocationOnScreen(pts);
+        opts.mStartX = pts[0] + startX;
+        opts.mStartY = pts[1] + startY;
+        opts.mWidth = targetWidth;
+        opts.mHeight = targetHeight;
+        opts.setOnAnimationStartedListener(source.getHandler(), listener);
+        return opts;
+    }
+
+    /**
      * Create an ActivityOptions to transition between Activities using cross-Activity scene
      * animations. This method carries the position of one shared element to the started Activity.
      * The position of <code>sharedElement</code> will be used as the epicenter for the
      * exit Transition. The position of the shared element in the launched Activity will be the
      * epicenter of its entering Transition.
      *
-     * <p>This requires {@link android.view.Window#FEATURE_CONTENT_TRANSITIONS} to be
+     * <p>This requires {@link android.view.Window#FEATURE_ACTIVITY_TRANSITIONS} to be
      * enabled on the calling Activity to cause an exit transition. The same must be in
      * the called Activity to get an entering transition.</p>
      * @param activity The Activity whose window contains the shared elements.
@@ -368,7 +438,7 @@
      * will be used as the epicenter for the exit Transition. The position of the associated
      * shared element in the launched Activity will be the epicenter of its entering Transition.
      *
-     * <p>This requires {@link android.view.Window#FEATURE_CONTENT_TRANSITIONS} to be
+     * <p>This requires {@link android.view.Window#FEATURE_ACTIVITY_TRANSITIONS} to be
      * enabled on the calling Activity to cause an exit transition. The same must be in
      * the called Activity to get an entering transition.</p>
      * @param activity The Activity whose window contains the shared elements.
@@ -383,7 +453,7 @@
     public static ActivityOptions makeSceneTransitionAnimation(Activity activity,
             Pair<View, String>... sharedElements) {
         ActivityOptions opts = new ActivityOptions();
-        if (!activity.getWindow().hasFeature(Window.FEATURE_CONTENT_TRANSITIONS)) {
+        if (!activity.getWindow().hasFeature(Window.FEATURE_ACTIVITY_TRANSITIONS)) {
             opts.mAnimationType = ANIM_DEFAULT;
             return opts;
         }
@@ -444,7 +514,7 @@
      * android.R.styleable#AndroidManifestActivity_launchMode launchMode} values of
      * <code>singleInstance</code> or <code>singleTask</code>.
      */
-    public static ActivityOptions makeLaunchTaskBehindAnimation() {
+    public static ActivityOptions makeTaskLaunchBehind() {
         final ActivityOptions opts = new ActivityOptions();
         opts.mAnimationType = ANIM_LAUNCH_TASK_BEHIND;
         return opts;
@@ -473,15 +543,19 @@
             case ANIM_SCALE_UP:
                 mStartX = opts.getInt(KEY_ANIM_START_X, 0);
                 mStartY = opts.getInt(KEY_ANIM_START_Y, 0);
-                mStartWidth = opts.getInt(KEY_ANIM_START_WIDTH, 0);
-                mStartHeight = opts.getInt(KEY_ANIM_START_HEIGHT, 0);
+                mWidth = opts.getInt(KEY_ANIM_WIDTH, 0);
+                mHeight = opts.getInt(KEY_ANIM_HEIGHT, 0);
                 break;
 
             case ANIM_THUMBNAIL_SCALE_UP:
             case ANIM_THUMBNAIL_SCALE_DOWN:
-                mThumbnail = (Bitmap)opts.getParcelable(KEY_ANIM_THUMBNAIL);
+            case ANIM_THUMBNAIL_ASPECT_SCALE_UP:
+            case ANIM_THUMBNAIL_ASPECT_SCALE_DOWN:
+                mThumbnail = (Bitmap) opts.getParcelable(KEY_ANIM_THUMBNAIL);
                 mStartX = opts.getInt(KEY_ANIM_START_X, 0);
                 mStartY = opts.getInt(KEY_ANIM_START_Y, 0);
+                mWidth = opts.getInt(KEY_ANIM_WIDTH, 0);
+                mHeight = opts.getInt(KEY_ANIM_HEIGHT, 0);
                 mAnimationStartedListener = IRemoteCallback.Stub.asInterface(
                         opts.getBinder(KEY_ANIM_START_LISTENER));
                 break;
@@ -533,13 +607,13 @@
     }
 
     /** @hide */
-    public int getStartWidth() {
-        return mStartWidth;
+    public int getWidth() {
+        return mWidth;
     }
 
     /** @hide */
-    public int getStartHeight() {
-        return mStartHeight;
+    public int getHeight() {
+        return mHeight;
     }
 
     /** @hide */
@@ -618,8 +692,8 @@
             case ANIM_SCALE_UP:
                 mStartX = otherOptions.mStartX;
                 mStartY = otherOptions.mStartY;
-                mStartWidth = otherOptions.mStartWidth;
-                mStartHeight = otherOptions.mStartHeight;
+                mWidth = otherOptions.mWidth;
+                mHeight = otherOptions.mHeight;
                 if (mAnimationStartedListener != null) {
                     try {
                         mAnimationStartedListener.sendResult(null);
@@ -630,9 +704,13 @@
                 break;
             case ANIM_THUMBNAIL_SCALE_UP:
             case ANIM_THUMBNAIL_SCALE_DOWN:
+            case ANIM_THUMBNAIL_ASPECT_SCALE_UP:
+            case ANIM_THUMBNAIL_ASPECT_SCALE_DOWN:
                 mThumbnail = otherOptions.mThumbnail;
                 mStartX = otherOptions.mStartX;
                 mStartY = otherOptions.mStartY;
+                mWidth = otherOptions.mWidth;
+                mHeight = otherOptions.mHeight;
                 if (mAnimationStartedListener != null) {
                     try {
                         mAnimationStartedListener.sendResult(null);
@@ -681,14 +759,18 @@
             case ANIM_SCALE_UP:
                 b.putInt(KEY_ANIM_START_X, mStartX);
                 b.putInt(KEY_ANIM_START_Y, mStartY);
-                b.putInt(KEY_ANIM_START_WIDTH, mStartWidth);
-                b.putInt(KEY_ANIM_START_HEIGHT, mStartHeight);
+                b.putInt(KEY_ANIM_WIDTH, mWidth);
+                b.putInt(KEY_ANIM_HEIGHT, mHeight);
                 break;
             case ANIM_THUMBNAIL_SCALE_UP:
             case ANIM_THUMBNAIL_SCALE_DOWN:
+            case ANIM_THUMBNAIL_ASPECT_SCALE_UP:
+            case ANIM_THUMBNAIL_ASPECT_SCALE_DOWN:
                 b.putParcelable(KEY_ANIM_THUMBNAIL, mThumbnail);
                 b.putInt(KEY_ANIM_START_X, mStartX);
                 b.putInt(KEY_ANIM_START_Y, mStartY);
+                b.putInt(KEY_ANIM_WIDTH, mWidth);
+                b.putInt(KEY_ANIM_HEIGHT, mHeight);
                 b.putBinder(KEY_ANIM_START_LISTENER, mAnimationStartedListener
                         != null ? mAnimationStartedListener.asBinder() : null);
                 break;
diff --git a/core/java/android/app/ActivityThread.java b/core/java/android/app/ActivityThread.java
index 2136209..7d0d27f 100644
--- a/core/java/android/app/ActivityThread.java
+++ b/core/java/android/app/ActivityThread.java
@@ -102,8 +102,6 @@
 import com.android.org.conscrypt.TrustedCertificateStore;
 import com.google.android.collect.Lists;
 
-import dalvik.system.VMRuntime;
-
 import java.io.File;
 import java.io.FileDescriptor;
 import java.io.FileOutputStream;
@@ -124,8 +122,9 @@
 import libcore.io.DropBox;
 import libcore.io.EventLogger;
 import libcore.io.IoUtils;
-
+import libcore.net.event.NetworkEventDispatcher;
 import dalvik.system.CloseGuard;
+import dalvik.system.VMDebug;
 import dalvik.system.VMRuntime;
 
 final class RemoteServiceException extends AndroidRuntimeException {
@@ -201,6 +200,7 @@
     String mInstrumentedLibDir = null;
     boolean mSystemThread = false;
     boolean mJitEnabled = false;
+    boolean mSomeActivitiesChanged = false;
 
     // These can be accessed by multiple threads; mPackages is the lock.
     // XXX For now we keep around information about all packages we have
@@ -283,9 +283,7 @@
         Configuration createdConfig;
         ActivityClientRecord nextIdle;
 
-        String profileFile;
-        ParcelFileDescriptor profileFd;
-        boolean autoStopProfiler;
+        ProfilerInfo profilerInfo;
 
         ActivityInfo activityInfo;
         CompatibilityInfo compatInfo;
@@ -437,9 +435,7 @@
         CompatibilityInfo compatInfo;
 
         /** Initial values for {@link Profiler}. */
-        String initProfileFile;
-        ParcelFileDescriptor initProfileFd;
-        boolean initAutoStopProfiler;
+        ProfilerInfo initProfilerInfo;
 
         public String toString() {
             return "AppBindData{appInfo=" + appInfo + "}";
@@ -449,10 +445,12 @@
     static final class Profiler {
         String profileFile;
         ParcelFileDescriptor profileFd;
+        int samplingInterval;
         boolean autoStopProfiler;
         boolean profiling;
         boolean handlingProfiling;
-        public void setProfiler(String file, ParcelFileDescriptor fd) {
+        public void setProfiler(ProfilerInfo profilerInfo) {
+            ParcelFileDescriptor fd = profilerInfo.profileFd;
             if (profiling) {
                 if (fd != null) {
                     try {
@@ -470,16 +468,18 @@
                     // Ignore
                 }
             }
-            profileFile = file;
+            profileFile = profilerInfo.profileFile;
             profileFd = fd;
+            samplingInterval = profilerInfo.samplingInterval;
+            autoStopProfiler = profilerInfo.autoStopProfiler;
         }
         public void startProfiling() {
             if (profileFd == null || profiling) {
                 return;
             }
             try {
-                Debug.startMethodTracing(profileFile, profileFd.getFileDescriptor(),
-                        8 * 1024 * 1024, 0);
+                VMDebug.startMethodTracing(profileFile, profileFd.getFileDescriptor(),
+                        8 * 1024 * 1024, 0, samplingInterval != 0, samplingInterval);
                 profiling = true;
             } catch (RuntimeException e) {
                 Slog.w(TAG, "Profiling failed on path " + profileFile);
@@ -528,11 +528,6 @@
         String who;
     }
 
-    static final class ProfilerControlData {
-        String path;
-        ParcelFileDescriptor fd;
-    }
-
     static final class DumpHeapData {
         String path;
         ParcelFileDescriptor fd;
@@ -568,11 +563,11 @@
         }
 
         public final void schedulePauseActivity(IBinder token, boolean finished,
-                boolean userLeaving, int configChanges) {
+                boolean userLeaving, int configChanges, boolean dontReport) {
             sendMessage(
                     finished ? H.PAUSE_ACTIVITY_FINISHING : H.PAUSE_ACTIVITY,
                     token,
-                    (userLeaving ? 1 : 0),
+                    (userLeaving ? 1 : 0) | (dontReport ? 2 : 0),
                     configChanges);
         }
 
@@ -613,7 +608,7 @@
                 IVoiceInteractor voiceInteractor, int procState, Bundle state,
                 PersistableBundle persistentState, List<ResultInfo> pendingResults,
                 List<Intent> pendingNewIntents, boolean notResumed, boolean isForward,
-                String profileName, ParcelFileDescriptor profileFd, boolean autoStopProfiler) {
+                ProfilerInfo profilerInfo) {
 
             updateProcessState(procState, false);
 
@@ -634,9 +629,7 @@
             r.startsNotResumed = notResumed;
             r.isForward = isForward;
 
-            r.profileFile = profileName;
-            r.profileFd = profileFd;
-            r.autoStopProfiler = autoStopProfiler;
+            r.profilerInfo = profilerInfo;
 
             updatePendingConfiguration(curConfig);
 
@@ -743,11 +736,10 @@
             sendMessage(H.STOP_SERVICE, token);
         }
 
-        public final void bindApplication(String processName,
-                ApplicationInfo appInfo, List<ProviderInfo> providers,
-                ComponentName instrumentationName, String profileFile,
-                ParcelFileDescriptor profileFd, boolean autoStopProfiler,
-                Bundle instrumentationArgs, IInstrumentationWatcher instrumentationWatcher,
+        public final void bindApplication(String processName, ApplicationInfo appInfo,
+                List<ProviderInfo> providers, ComponentName instrumentationName,
+                ProfilerInfo profilerInfo, Bundle instrumentationArgs,
+                IInstrumentationWatcher instrumentationWatcher,
                 IUiAutomationConnection instrumentationUiConnection, int debugMode,
                 boolean enableOpenGlTrace, boolean isRestrictedBackupMode, boolean persistent,
                 Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services,
@@ -811,9 +803,7 @@
             data.persistent = persistent;
             data.config = config;
             data.compatInfo = compatInfo;
-            data.initProfileFile = profileFile;
-            data.initProfileFd = profileFd;
-            data.initAutoStopProfiler = false;
+            data.initProfilerInfo = profilerInfo;
             sendMessage(H.BIND_APPLICATION, data);
         }
 
@@ -837,6 +827,9 @@
         public void clearDnsCache() {
             // a non-standard API to get this to libcore
             InetAddress.clearDnsCache();
+            // Allow libcore to perform the necessary actions as it sees fit upon a network
+            // configuration change.
+            NetworkEventDispatcher.getInstance().onNetworkConfigurationChanged();
         }
 
         public void setHttpProxy(String host, String port, String exclList, Uri pacFileUrl) {
@@ -879,12 +872,8 @@
             sendMessage(H.ACTIVITY_CONFIGURATION_CHANGED, token);
         }
 
-        public void profilerControl(boolean start, String path, ParcelFileDescriptor fd,
-                int profileType) {
-            ProfilerControlData pcd = new ProfilerControlData();
-            pcd.path = path;
-            pcd.fd = fd;
-            sendMessage(H.PROFILER_CONTROL, pcd, start ? 1 : 0, profileType);
+        public void profilerControl(boolean start, ProfilerInfo profilerInfo, int profileType) {
+            sendMessage(H.PROFILER_CONTROL, profilerInfo, start ? 1 : 0, profileType);
         }
 
         public void dumpHeap(boolean managed, String path, ParcelFileDescriptor fd) {
@@ -1297,13 +1286,15 @@
                 } break;
                 case PAUSE_ACTIVITY:
                     Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "activityPause");
-                    handlePauseActivity((IBinder)msg.obj, false, msg.arg1 != 0, msg.arg2);
+                    handlePauseActivity((IBinder)msg.obj, false, (msg.arg1&1) != 0, msg.arg2,
+                            (msg.arg1&2) != 0);
                     maybeSnapshot();
                     Trace.traceEnd(Trace.TRACE_TAG_ACTIVITY_MANAGER);
                     break;
                 case PAUSE_ACTIVITY_FINISHING:
                     Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "activityPause");
-                    handlePauseActivity((IBinder)msg.obj, true, msg.arg1 != 0, msg.arg2);
+                    handlePauseActivity((IBinder)msg.obj, true, (msg.arg1&1) != 0, msg.arg2,
+                            (msg.arg1&1) != 0);
                     Trace.traceEnd(Trace.TRACE_TAG_ACTIVITY_MANAGER);
                     break;
                 case STOP_ACTIVITY_SHOW:
@@ -1418,7 +1409,7 @@
                     Trace.traceEnd(Trace.TRACE_TAG_ACTIVITY_MANAGER);
                     break;
                 case PROFILER_CONTROL:
-                    handleProfilerControl(msg.arg1 != 0, (ProfilerControlData)msg.obj, msg.arg2);
+                    handleProfilerControl(msg.arg1 != 0, (ProfilerInfo)msg.obj, msg.arg2);
                     break;
                 case CREATE_BACKUP_AGENT:
                     Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "backupCreateAgent");
@@ -1952,7 +1943,7 @@
         if (dumpFullInfo) {
             printRow(pw, HEAP_FULL_COLUMN, "", "Pss", "Pss", "Shared", "Private",
                     "Shared", "Private", "Swapped", "Heap", "Heap", "Heap");
-            printRow(pw, HEAP_FULL_COLUMN, "", "Total", "Clean", "Dirty", "Dirty",
+            printRow(pw, HEAP_FULL_COLUMN, "", "Total", "Clean", "Dirty", "",
                     "Clean", "Clean", "Dirty", "Size", "Alloc", "Free");
             printRow(pw, HEAP_FULL_COLUMN, "", "------", "------", "------", "------",
                     "------", "------", "------", "------", "------", "------");
@@ -2353,11 +2344,11 @@
         // If we are getting ready to gc after going to the background, well
         // we are back active so skip it.
         unscheduleGcIdler();
+        mSomeActivitiesChanged = true;
 
-        if (r.profileFd != null) {
-            mProfiler.setProfiler(r.profileFile, r.profileFd);
+        if (r.profilerInfo != null) {
+            mProfiler.setProfiler(r.profilerInfo);
             mProfiler.startProfiling();
-            mProfiler.autoStopProfiler = r.autoStopProfiler;
         }
 
         // Make sure we are running with the most recent config.
@@ -2495,14 +2486,15 @@
     public void handleCancelVisibleBehind(IBinder token) {
         ActivityClientRecord r = mActivities.get(token);
         if (r != null) {
+            mSomeActivitiesChanged = true;
             final Activity activity = r.activity;
             if (activity.mVisibleBehind) {
                 activity.mCalled = false;
-                activity.onVisibleBehindCancelled();
+                activity.onVisibleBehindCanceled();
                 // Tick, tick, tick. The activity has 500 msec to return or it will be destroyed.
                 if (!activity.mCalled) {
                     throw new SuperNotCalledException("Activity " + activity.getLocalClassName() +
-                            " did not call through to super.onVisibleBehindCancelled()");
+                            " did not call through to super.onVisibleBehindCanceled()");
                 }
                 activity.mVisibleBehind = false;
             }
@@ -2984,6 +2976,7 @@
         // If we are getting ready to gc after going to the background, well
         // we are back active so skip it.
         unscheduleGcIdler();
+        mSomeActivitiesChanged = true;
 
         // TODO Push resumeArgs into the activity for consideration
         ActivityClientRecord r = performResumeActivity(token, clearHide);
@@ -3154,7 +3147,7 @@
     }
 
     private void handlePauseActivity(IBinder token, boolean finished,
-            boolean userLeaving, int configChanges) {
+            boolean userLeaving, int configChanges, boolean dontReport) {
         ActivityClientRecord r = mActivities.get(token);
         if (r != null) {
             //Slog.v(TAG, "userLeaving=" + userLeaving + " handling pause of " + r);
@@ -3171,10 +3164,13 @@
             }
 
             // Tell the activity manager we have paused.
-            try {
-                ActivityManagerNative.getDefault().activityPaused(token, r.persistentState);
-            } catch (RemoteException ex) {
+            if (!dontReport) {
+                try {
+                    ActivityManagerNative.getDefault().activityPaused(token);
+                } catch (RemoteException ex) {
+                }
             }
+            mSomeActivitiesChanged = true;
         }
     }
 
@@ -3413,6 +3409,7 @@
         info.state = r.state;
         info.persistentState = r.persistentState;
         mH.post(info);
+        mSomeActivitiesChanged = true;
     }
 
     final void performRestartActivity(IBinder token) {
@@ -3446,6 +3443,7 @@
                 TAG, "Handle window " + r + " visibility: " + show);
             updateVisibility(r, show);
         }
+        mSomeActivitiesChanged = true;
     }
 
     private void handleSleeping(IBinder token, boolean sleeping) {
@@ -3743,6 +3741,7 @@
                 // If the system process has died, it's game over for everyone.
             }
         }
+        mSomeActivitiesChanged = true;
     }
 
     public final void requestRelaunchActivity(IBinder token,
@@ -3805,6 +3804,7 @@
         // If we are getting ready to gc after going to the background, well
         // we are back active so skip it.
         unscheduleGcIdler();
+        mSomeActivitiesChanged = true;
 
         Configuration changedConfig = null;
         int configChanges = 0;
@@ -4107,24 +4107,25 @@
         performConfigurationChanged(r.activity, mCompatConfiguration);
 
         freeTextLayoutCachesIfNeeded(r.activity.mCurrentConfig.diff(mCompatConfiguration));
+
+        mSomeActivitiesChanged = true;
     }
 
-    final void handleProfilerControl(boolean start, ProfilerControlData pcd, int profileType) {
+    final void handleProfilerControl(boolean start, ProfilerInfo profilerInfo, int profileType) {
         if (start) {
             try {
                 switch (profileType) {
-                    default:                        
-                        mProfiler.setProfiler(pcd.path, pcd.fd);
-                        mProfiler.autoStopProfiler = false;
+                    default:
+                        mProfiler.setProfiler(profilerInfo);
                         mProfiler.startProfiling();
                         break;
                 }
             } catch (RuntimeException e) {
-                Slog.w(TAG, "Profiling failed on path " + pcd.path
+                Slog.w(TAG, "Profiling failed on path " + profilerInfo.profileFile
                         + " -- can the process access this path?");
             } finally {
                 try {
-                    pcd.fd.close();
+                    profilerInfo.profileFd.close();
                 } catch (IOException e) {
                     Slog.w(TAG, "Failure closing profile fd", e);
                 }
@@ -4256,9 +4257,12 @@
         mCompatConfiguration = new Configuration(data.config);
 
         mProfiler = new Profiler();
-        mProfiler.profileFile = data.initProfileFile;
-        mProfiler.profileFd = data.initProfileFd;
-        mProfiler.autoStopProfiler = data.initAutoStopProfiler;
+        if (data.initProfilerInfo != null) {
+            mProfiler.profileFile = data.initProfilerInfo.profileFile;
+            mProfiler.profileFd = data.initProfilerInfo.profileFd;
+            mProfiler.samplingInterval = data.initProfilerInfo.samplingInterval;
+            mProfiler.autoStopProfiler = data.initProfilerInfo.autoStopProfiler;
+        }
 
         // send up app name; do this *before* waiting for debugger
         Process.setArgV0(data.processName);
@@ -4273,7 +4277,7 @@
                 HardwareRenderer.disable(false);
             }
         }
-        
+
         if (mProfiler.profileFd != null) {
             mProfiler.startProfiling();
         }
@@ -4286,6 +4290,8 @@
             AsyncTask.setDefaultExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
         }
 
+        Message.updateCheckRecycle(data.appInfo.targetSdkVersion);
+
         /*
          * Before spawning a new process, reset the time zone to be the system time zone.
          * This needs to be done because the system time zone could have changed after the
@@ -5045,25 +5051,44 @@
             android.ddm.DdmHandleAppName.setAppName("<pre-initialized>",
                                                     UserHandle.myUserId());
             RuntimeInit.setApplicationObject(mAppThread.asBinder());
-            IActivityManager mgr = ActivityManagerNative.getDefault();
+            final IActivityManager mgr = ActivityManagerNative.getDefault();
             try {
                 mgr.attachApplication(mAppThread);
             } catch (RemoteException ex) {
                 // Ignore
             }
+            // Watch for getting close to heap limit.
+            BinderInternal.addGcWatcher(new Runnable() {
+                @Override public void run() {
+                    if (!mSomeActivitiesChanged) {
+                        return;
+                    }
+                    Runtime runtime = Runtime.getRuntime();
+                    long dalvikMax = runtime.maxMemory();
+                    long dalvikUsed = runtime.totalMemory() - runtime.freeMemory();
+                    if (dalvikUsed > ((3*dalvikMax)/4)) {
+                        if (DEBUG_MEMORY_TRIM) Slog.d(TAG, "Dalvik max=" + (dalvikMax/1024)
+                                + " total=" + (runtime.totalMemory()/1024)
+                                + " used=" + (dalvikUsed/1024));
+                        mSomeActivitiesChanged = false;
+                        try {
+                            mgr.releaseSomeActivities(mAppThread);
+                        } catch (RemoteException e) {
+                        }
+                    }
+                }
+            });
         } else {
             // Don't set application object here -- if the system crashes,
             // we can't display an alert, we just want to die die die.
             android.ddm.DdmHandleAppName.setAppName("system_process",
-                                                    UserHandle.myUserId());
+                    UserHandle.myUserId());
             try {
                 mInstrumentation = new Instrumentation();
                 ContextImpl context = ContextImpl.createAppContext(
                         this, getSystemContext().mPackageInfo);
-                Application app = Instrumentation.newApplication(Application.class, context);
-                mAllApplications.add(app);
-                mInitialApplication = app;
-                app.onCreate();
+                mInitialApplication = context.mPackageInfo.makeApplication(true, null);
+                mInitialApplication.onCreate();
             } catch (Exception e) {
                 throw new RuntimeException(
                         "Unable to instantiate Application():" + e.toString(), e);
diff --git a/core/java/android/app/ActivityTransitionCoordinator.java b/core/java/android/app/ActivityTransitionCoordinator.java
index 7d2f677..137f77d 100644
--- a/core/java/android/app/ActivityTransitionCoordinator.java
+++ b/core/java/android/app/ActivityTransitionCoordinator.java
@@ -196,8 +196,8 @@
     final protected ArrayList<String> mAllSharedElementNames;
     final protected ArrayList<View> mSharedElements = new ArrayList<View>();
     final protected ArrayList<String> mSharedElementNames = new ArrayList<String>();
-    final protected ArrayList<View> mTransitioningViews = new ArrayList<View>();
-    protected SharedElementListener mListener;
+    protected ArrayList<View> mTransitioningViews = new ArrayList<View>();
+    protected SharedElementCallback mListener;
     protected ResultReceiver mResultReceiver;
     final private FixedEpicenterCallback mEpicenterCallback = new FixedEpicenterCallback();
     final protected boolean mIsReturning;
@@ -205,10 +205,11 @@
     private boolean mIsStartingTransition;
     private ArrayList<GhostViewListeners> mGhostViewListeners =
             new ArrayList<GhostViewListeners>();
+    private ArrayMap<View, Float> mOriginalAlphas = new ArrayMap<View, Float>();
 
     public ActivityTransitionCoordinator(Window window,
             ArrayList<String> allSharedElementNames,
-            SharedElementListener listener, boolean isReturning) {
+            SharedElementCallback listener, boolean isReturning) {
         super(new Handler());
         mWindow = window;
         mListener = listener;
@@ -217,20 +218,30 @@
     }
 
     protected void viewsReady(ArrayMap<String, View> sharedElements) {
-        setSharedElements(sharedElements);
-        if (getViewsTransition() != null) {
-            getDecor().captureTransitioningViews(mTransitioningViews);
+        sharedElements.retainAll(mAllSharedElementNames);
+        mListener.onMapSharedElements(mAllSharedElementNames, sharedElements);
+        mSharedElementNames.addAll(sharedElements.keySet());
+        mSharedElements.addAll(sharedElements.values());
+        if (getViewsTransition() != null && mTransitioningViews != null) {
+            ViewGroup decorView = getDecor();
+            if (decorView != null) {
+                decorView.captureTransitioningViews(mTransitioningViews);
+            }
             mTransitioningViews.removeAll(mSharedElements);
         }
         setEpicenter();
     }
 
     protected void stripOffscreenViews() {
+        if (mTransitioningViews == null) {
+            return;
+        }
         Rect r = new Rect();
         for (int i = mTransitioningViews.size() - 1; i >= 0; i--) {
             View view = mTransitioningViews.get(i);
             if (!view.getGlobalVisibleRect(r)) {
                 mTransitioningViews.remove(i);
+                showView(view, true);
             }
         }
     }
@@ -248,9 +259,11 @@
      */
     protected void setEpicenter() {
         View epicenter = null;
-        if (!mAllSharedElementNames.isEmpty() && !mSharedElementNames.isEmpty() &&
-                mAllSharedElementNames.get(0).equals(mSharedElementNames.get(0))) {
-            epicenter = mSharedElements.get(0);
+        if (!mAllSharedElementNames.isEmpty() && !mSharedElementNames.isEmpty()) {
+            int index = mSharedElementNames.indexOf(mAllSharedElementNames.get(0));
+            if (index >= 0) {
+                epicenter = mSharedElements.get(index);
+            }
         }
         setEpicenter(epicenter);
     }
@@ -339,32 +352,19 @@
     protected ArrayMap<String, View> mapSharedElements(ArrayList<String> accepted,
             ArrayList<View> localViews) {
         ArrayMap<String, View> sharedElements = new ArrayMap<String, View>();
-        if (!mAllSharedElementNames.isEmpty()) {
-            if (accepted != null) {
-                for (int i = 0; i < accepted.size(); i++) {
-                    sharedElements.put(accepted.get(i), localViews.get(i));
-                }
-            } else {
-                getDecor().findNamedViews(sharedElements);
+        if (accepted != null) {
+            for (int i = 0; i < accepted.size(); i++) {
+                sharedElements.put(accepted.get(i), localViews.get(i));
+            }
+        } else {
+            ViewGroup decorView = getDecor();
+            if (decorView != null) {
+                decorView.findNamedViews(sharedElements);
             }
         }
         return sharedElements;
     }
 
-    private void setSharedElements(ArrayMap<String, View> sharedElements) {
-        sharedElements.retainAll(mAllSharedElementNames);
-        mListener.remapSharedElements(mAllSharedElementNames, sharedElements);
-        sharedElements.retainAll(mAllSharedElementNames);
-        for (int i = 0; i < mAllSharedElementNames.size(); i++) {
-            String name = mAllSharedElementNames.get(i);
-            View sharedElement = sharedElements.get(name);
-            if (sharedElement != null) {
-                mSharedElementNames.add(name);
-                mSharedElements.add(sharedElement);
-            }
-        }
-    }
-
     protected void setResultReceiver(ResultReceiver resultReceiver) {
         mResultReceiver = resultReceiver;
     }
@@ -471,25 +471,28 @@
                         tempMatrix, tempRect, null);
             }
         }
-        mListener.setSharedElementStart(mSharedElementNames, mSharedElements, snapshots);
+        mListener.onSharedElementStart(mSharedElementNames, mSharedElements, snapshots);
         return originalImageState;
     }
 
     protected void notifySharedElementEnd(ArrayList<View> snapshots) {
-        mListener.setSharedElementEnd(mSharedElementNames, mSharedElements, snapshots);
+        mListener.onSharedElementEnd(mSharedElementNames, mSharedElements, snapshots);
     }
 
     protected void scheduleSetSharedElementEnd(final ArrayList<View> snapshots) {
-        getDecor().getViewTreeObserver().addOnPreDrawListener(
-                new ViewTreeObserver.OnPreDrawListener() {
-                    @Override
-                    public boolean onPreDraw() {
-                        getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
-                        notifySharedElementEnd(snapshots);
-                        return true;
+        final View decorView = getDecor();
+        if (decorView != null) {
+            decorView.getViewTreeObserver().addOnPreDrawListener(
+                    new ViewTreeObserver.OnPreDrawListener() {
+                        @Override
+                        public boolean onPreDraw() {
+                            decorView.getViewTreeObserver().removeOnPreDrawListener(this);
+                            notifySharedElementEnd(snapshots);
+                            return true;
+                        }
                     }
-                }
-        );
+            );
+        }
     }
 
     private static SharedElementOriginalState getOldSharedElementState(View view, String name,
@@ -532,14 +535,17 @@
         ArrayList<View> snapshots = new ArrayList<View>(numSharedElements);
         Context context = getWindow().getContext();
         int[] decorLoc = new int[2];
-        getDecor().getLocationOnScreen(decorLoc);
+        ViewGroup decorView = getDecor();
+        if (decorView != null) {
+            decorView.getLocationOnScreen(decorLoc);
+        }
         for (String name: names) {
             Bundle sharedElementBundle = state.getBundle(name);
             if (sharedElementBundle != null) {
                 Parcelable parcelable = sharedElementBundle.getParcelable(KEY_SNAPSHOT);
                 View snapshot = null;
                 if (parcelable != null) {
-                    snapshot = mListener.createSnapshotView(context, parcelable);
+                    snapshot = mListener.onCreateSnapshotView(context, parcelable);
                 }
                 if (snapshot != null) {
                     setSharedElementState(snapshot, name, state, null, null, decorLoc);
@@ -589,7 +595,8 @@
         // Clear the state so that we can't hold any references accidentally and leak memory.
         mWindow = null;
         mSharedElements.clear();
-        mTransitioningViews.clear();
+        mTransitioningViews = null;
+        mOriginalAlphas.clear();
         mResultReceiver = null;
         mPendingTransition = null;
         mListener = null;
@@ -599,10 +606,31 @@
         return getWindow().getTransitionBackgroundFadeDuration();
     }
 
-    protected static void setTransitionAlpha(ArrayList<View> views, float alpha) {
+    protected void hideViews(ArrayList<View> views) {
         int count = views.size();
         for (int i = 0; i < count; i++) {
-            views.get(i).setTransitionAlpha(alpha);
+            View view = views.get(i);
+            if (!mOriginalAlphas.containsKey(view)) {
+                mOriginalAlphas.put(view, view.getAlpha());
+            }
+            view.setAlpha(0f);
+        }
+    }
+
+    protected void showViews(ArrayList<View> views, boolean setTransitionAlpha) {
+        int count = views.size();
+        for (int i = 0; i < count; i++) {
+            showView(views.get(i), setTransitionAlpha);
+        }
+    }
+
+    private void showView(View view, boolean setTransitionAlpha) {
+        Float alpha = mOriginalAlphas.remove(view);
+        if (alpha != null) {
+            view.setAlpha(alpha);
+        }
+        if (setTransitionAlpha) {
+            view.setTransitionAlpha(1f);
         }
     }
 
@@ -631,7 +659,7 @@
         sharedElementBundle.putFloat(KEY_TRANSLATION_Z, view.getTranslationZ());
         sharedElementBundle.putFloat(KEY_ELEVATION, view.getElevation());
 
-        Parcelable bitmap = mListener.captureSharedElementSnapshot(view, tempMatrix, tempBounds);
+        Parcelable bitmap = mListener.onCaptureSharedElementSnapshot(view, tempMatrix, tempBounds);
         if (bitmap != null) {
             sharedElementBundle.putParcelable(KEY_SNAPSHOT, bitmap);
         }
@@ -665,6 +693,9 @@
     }
 
     protected void moveSharedElementsToOverlay() {
+        if (!mWindow.getSharedElementsUseOverlay()) {
+            return;
+        }
         int numSharedElements = mSharedElements.size();
         ViewGroup decor = getDecor();
         if (decor != null) {
@@ -674,8 +705,7 @@
                 GhostView.addGhost(view, decor);
                 ViewGroup parent = (ViewGroup) view.getParent();
                 if (moveWithParent && !isInTransitionGroup(parent, decor)) {
-                    GhostViewListeners listener =
-                            new GhostViewListeners(view, decor);
+                    GhostViewListeners listener = new GhostViewListeners(view, parent, decor);
                     parent.getViewTreeObserver().addOnPreDrawListener(listener);
                     mGhostViewListeners.add(listener);
                 }
@@ -700,6 +730,17 @@
     }
 
     protected void moveSharedElementsFromOverlay() {
+        int numListeners = mGhostViewListeners.size();
+        for (int i = 0; i < numListeners; i++) {
+            GhostViewListeners listener = mGhostViewListeners.get(i);
+            ViewGroup parent = (ViewGroup) listener.getView().getParent();
+            parent.getViewTreeObserver().removeOnPreDrawListener(listener);
+        }
+        mGhostViewListeners.clear();
+
+        if (mWindow == null || !mWindow.getSharedElementsUseOverlay()) {
+            return;
+        }
         ViewGroup decor = getDecor();
         if (decor != null) {
             ViewGroupOverlay overlay = decor.getOverlay();
@@ -709,13 +750,6 @@
                 GhostView.removeGhost(sharedElement);
             }
         }
-        int numListeners = mGhostViewListeners.size();
-        for (int i = 0; i < numListeners; i++) {
-            GhostViewListeners listener = mGhostViewListeners.get(i);
-            ViewGroup parent = (ViewGroup) listener.getView().getParent();
-            parent.getViewTreeObserver().removeOnPreDrawListener(listener);
-        }
-        mGhostViewListeners.clear();
     }
 
     protected void setGhostVisibility(int visibility) {
@@ -729,15 +763,18 @@
     }
 
     protected void scheduleGhostVisibilityChange(final int visibility) {
-        getDecor().getViewTreeObserver()
-                .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
-                    @Override
-                    public boolean onPreDraw() {
-                        getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
-                        setGhostVisibility(visibility);
-                        return true;
-                    }
-                });
+        final View decorView = getDecor();
+        if (decorView != null) {
+            decorView.getViewTreeObserver()
+                    .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
+                        @Override
+                        public boolean onPreDraw() {
+                            decorView.getViewTreeObserver().removeOnPreDrawListener(this);
+                            setGhostVisibility(visibility);
+                            return true;
+                        }
+                    });
+        }
     }
 
     protected class ContinueTransitionListener extends Transition.TransitionListenerAdapter {
@@ -775,10 +812,12 @@
     private static class GhostViewListeners implements ViewTreeObserver.OnPreDrawListener {
         private View mView;
         private ViewGroup mDecor;
+        private View mParent;
         private Matrix mMatrix = new Matrix();
 
-        public GhostViewListeners(View view, ViewGroup decor) {
+        public GhostViewListeners(View view, View parent, ViewGroup decor) {
             mView = view;
+            mParent = parent;
             mDecor = decor;
         }
 
@@ -788,10 +827,9 @@
 
         @Override
         public boolean onPreDraw() {
-            ViewGroup parent = ((ViewGroup) mView.getParent());
             GhostView ghostView = GhostView.getGhost(mView);
             if (ghostView == null) {
-                parent.getViewTreeObserver().removeOnPreDrawListener(this);
+                mParent.getViewTreeObserver().removeOnPreDrawListener(this);
             } else {
                 GhostView.calculateMatrix(mView, mDecor, mMatrix);
                 ghostView.setMatrix(mMatrix);
diff --git a/core/java/android/app/ActivityTransitionState.java b/core/java/android/app/ActivityTransitionState.java
index 613e248..bc2e6ca 100644
--- a/core/java/android/app/ActivityTransitionState.java
+++ b/core/java/android/app/ActivityTransitionState.java
@@ -144,13 +144,14 @@
     }
 
     public void setEnterActivityOptions(Activity activity, ActivityOptions options) {
-        if (activity.getWindow().hasFeature(Window.FEATURE_CONTENT_TRANSITIONS)
+        if (activity.getWindow().hasFeature(Window.FEATURE_ACTIVITY_TRANSITIONS)
                 && options != null && mEnterActivityOptions == null
                 && mEnterTransitionCoordinator == null
                 && options.getAnimationType() == ActivityOptions.ANIM_SCENE_TRANSITION) {
             mEnterActivityOptions = options;
             mIsEnterTriggered = false;
             if (mEnterActivityOptions.isReturning()) {
+                restoreExitedViews();
                 int result = mEnterActivityOptions.getResultCode();
                 if (result != 0) {
                     activity.onActivityReenter(result, mEnterActivityOptions.getResultData());
@@ -271,7 +272,7 @@
     }
 
     public void startExitOutTransition(Activity activity, Bundle options) {
-        if (!activity.getWindow().hasFeature(Window.FEATURE_CONTENT_TRANSITIONS)) {
+        if (!activity.getWindow().hasFeature(Window.FEATURE_ACTIVITY_TRANSITIONS)) {
             return;
         }
         ActivityOptions activityOptions = new ActivityOptions(options);
diff --git a/core/java/android/app/AlarmManager.java b/core/java/android/app/AlarmManager.java
index a64e0ed..2c596e5 100644
--- a/core/java/android/app/AlarmManager.java
+++ b/core/java/android/app/AlarmManager.java
@@ -17,6 +17,7 @@
 package android.app;
 
 import android.annotation.SdkConstant;
+import android.annotation.SystemApi;
 import android.content.Context;
 import android.content.Intent;
 import android.os.Build;
@@ -385,6 +386,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public void set(int type, long triggerAtMillis, long windowMillis, long intervalMillis,
             PendingIntent operation, WorkSource workSource) {
         setImpl(type, triggerAtMillis, windowMillis, intervalMillis, operation, workSource, null);
diff --git a/core/java/android/app/AppOpsManager.java b/core/java/android/app/AppOpsManager.java
index a6b3608..ba9c9d6 100644
--- a/core/java/android/app/AppOpsManager.java
+++ b/core/java/android/app/AppOpsManager.java
@@ -16,25 +16,25 @@
 
 package android.app;
 
-import android.Manifest;
+import android.annotation.SystemApi;
+import android.app.usage.UsageStatsManager;
+import android.content.Context;
 import android.media.AudioAttributes.AttributeUsage;
 import android.os.Binder;
 import android.os.IBinder;
-import android.os.UserManager;
-import android.util.ArrayMap;
-
-import com.android.internal.app.IAppOpsService;
-import com.android.internal.app.IAppOpsCallback;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-
-import android.content.Context;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.os.Process;
 import android.os.RemoteException;
+import android.os.UserManager;
+import android.util.ArrayMap;
+
+import com.android.internal.app.IAppOpsCallback;
+import com.android.internal.app.IAppOpsService;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
 
 /**
  * API for interacting with "application operation" tracking.
@@ -203,8 +203,10 @@
     public static final int OP_TOAST_WINDOW = 45;
     /** @hide Capture the device's display contents and/or audio */
     public static final int OP_PROJECT_MEDIA = 46;
+    /** @hide Activate a VPN connection without user intervention. */
+    public static final int OP_ACTIVATE_VPN = 47;
     /** @hide */
-    public static final int _NUM_OP = 47;
+    public static final int _NUM_OP = 48;
 
     /** Access to coarse location information. */
     public static final String OPSTR_COARSE_LOCATION =
@@ -218,6 +220,12 @@
     /** Continually monitoring location data with a relatively high power request. */
     public static final String OPSTR_MONITOR_HIGH_POWER_LOCATION
             = "android:monitor_location_high_power";
+    /** Access to {@link android.app.usage.UsageStatsManager}. */
+    public static final String OPSTR_GET_USAGE_STATS
+            = "android:get_usage_stats";
+    /** Activate a VPN connection without user intervention. @hide */
+    @SystemApi
+    public static final String OPSTR_ACTIVATE_VPN = "android:activate_vpn";
 
     /**
      * This maps each operation to the operation that serves as the
@@ -275,6 +283,7 @@
             OP_MUTE_MICROPHONE,
             OP_TOAST_WINDOW,
             OP_PROJECT_MEDIA,
+            OP_ACTIVATE_VPN,
     };
 
     /**
@@ -325,10 +334,11 @@
             null,
             OPSTR_MONITOR_LOCATION,
             OPSTR_MONITOR_HIGH_POWER_LOCATION,
+            OPSTR_GET_USAGE_STATS,
             null,
             null,
             null,
-            null,
+            OPSTR_ACTIVATE_VPN,
     };
 
     /**
@@ -383,6 +393,7 @@
             "MUTE_MICROPHONE",
             "TOAST_WINDOW",
             "PROJECT_MEDIA",
+            "ACTIVATE_VPN",
     };
 
     /**
@@ -437,6 +448,7 @@
             null, // no permission for muting/unmuting microphone
             null, // no permission for displaying toasts
             null, // no permission for projecting media
+            null, // no permission for activating vpn
     };
 
     /**
@@ -492,6 +504,7 @@
             UserManager.DISALLOW_UNMUTE_MICROPHONE, // MUTE_MICROPHONE
             UserManager.DISALLOW_CREATE_WINDOWS, // TOAST_WINDOW
             null, //PROJECT_MEDIA
+            UserManager.DISALLOW_CONFIG_VPN, // ACTIVATE_VPN
     };
 
     /**
@@ -546,6 +559,7 @@
             false, //MUTE_MICROPHONE
             true, //TOAST_WINDOW
             false, //PROJECT_MEDIA
+            false, //ACTIVATE_VPN
     };
 
     /**
@@ -599,6 +613,7 @@
             AppOpsManager.MODE_ALLOWED,
             AppOpsManager.MODE_ALLOWED,
             AppOpsManager.MODE_IGNORED, // OP_PROJECT_MEDIA
+            AppOpsManager.MODE_IGNORED, // OP_ACTIVATE_VPN
     };
 
     /**
@@ -656,6 +671,7 @@
             false,
             false,
             false,
+            false,
     };
 
     private static HashMap<String, Integer> sOpStrToOp = new HashMap<String, Integer>();
@@ -1046,7 +1062,10 @@
         return packageName + " from uid " + uid + " not allowed to perform " + sOpNames[op];
     }
 
-    private int strOpToOp(String op) {
+    /**
+     * {@hide}
+     */
+    public static int strOpToOp(String op) {
         Integer val = sOpStrToOp.get(op);
         if (val == null) {
             throw new IllegalArgumentException("Unknown operation string: " + op);
diff --git a/core/java/android/app/ApplicationPackageManager.java b/core/java/android/app/ApplicationPackageManager.java
index b2812e3..68606836 100644
--- a/core/java/android/app/ApplicationPackageManager.java
+++ b/core/java/android/app/ApplicationPackageManager.java
@@ -45,14 +45,17 @@
 import android.content.pm.ProviderInfo;
 import android.content.pm.ResolveInfo;
 import android.content.pm.ServiceInfo;
+import android.content.pm.UserInfo;
 import android.content.pm.VerificationParams;
 import android.content.pm.VerifierDeviceIdentity;
 import android.content.res.Resources;
 import android.content.res.XmlResourceParser;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Rect;
 import android.graphics.drawable.BitmapDrawable;
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
-import android.os.IBinder;
 import android.os.Process;
 import android.os.RemoteException;
 import android.os.UserHandle;
@@ -63,6 +66,7 @@
 
 import com.android.internal.annotations.GuardedBy;
 import com.android.internal.util.Preconditions;
+import com.android.internal.util.UserIcons;
 
 import dalvik.system.VMRuntime;
 
@@ -749,10 +753,10 @@
             putCachedIcon(name, dr);
             return dr;
         } catch (NameNotFoundException e) {
-            Log.w("PackageManager", "Failure retrieving resources for"
+            Log.w("PackageManager", "Failure retrieving resources for "
                   + appInfo.packageName);
         } catch (Resources.NotFoundException e) {
-            Log.w("PackageManager", "Failure retrieving resources for"
+            Log.w("PackageManager", "Failure retrieving resources for "
                   + appInfo.packageName + ": " + e.getMessage());
         } catch (RuntimeException e) {
             // If an exception was thrown, fall through to return
@@ -864,6 +868,49 @@
         return getApplicationLogo(getApplicationInfo(packageName, 0));
     }
 
+    @Override
+    public Drawable getUserBadgedIcon(Drawable icon, UserHandle user) {
+        final int badgeResId = getBadgeResIdForUser(user.getIdentifier());
+        if (badgeResId == 0) {
+            return icon;
+        }
+        Drawable badgeIcon = getDrawable("system", badgeResId, null);
+        return getBadgedDrawable(icon, badgeIcon, null, true);
+    }
+
+    @Override
+    public Drawable getUserBadgedDrawableForDensity(Drawable drawable, UserHandle user,
+            Rect badgeLocation, int badgeDensity) {
+        Drawable badgeDrawable = getUserBadgeForDensity(user, badgeDensity);
+        if (badgeDrawable == null) {
+            return drawable;
+        }
+        return getBadgedDrawable(drawable, badgeDrawable, badgeLocation, true);
+    }
+
+    @Override
+    public Drawable getUserBadgeForDensity(UserHandle user, int density) {
+        UserInfo userInfo = getUserIfProfile(user.getIdentifier());
+        if (userInfo != null && userInfo.isManagedProfile()) {
+            if (density <= 0) {
+                density = mContext.getResources().getDisplayMetrics().densityDpi;
+            }
+            return Resources.getSystem().getDrawableForDensity(
+                    com.android.internal.R.drawable.ic_corp_badge, density);
+        }
+        return null;
+    }
+
+    @Override
+    public CharSequence getUserBadgedLabel(CharSequence label, UserHandle user) {
+        UserInfo userInfo = getUserIfProfile(user.getIdentifier());
+        if (userInfo != null && userInfo.isManagedProfile()) {
+            return Resources.getSystem().getString(
+                    com.android.internal.R.string.managed_profile_label_badge, label);
+        }
+        return label;
+    }
+
     @Override public Resources getResourcesForActivity(
         ComponentName activityName) throws NameNotFoundException {
         return getResourcesForApplication(
@@ -1100,7 +1147,7 @@
             putCachedString(name, text);
             return text;
         } catch (NameNotFoundException e) {
-            Log.w("PackageManager", "Failure retrieving resources for"
+            Log.w("PackageManager", "Failure retrieving resources for "
                   + appInfo.packageName);
         } catch (RuntimeException e) {
             // If an exception was thrown, fall through to return
@@ -1494,57 +1541,52 @@
         return false;
     }
 
+    /** @hide */
     @Override
     public KeySet getKeySetByAlias(String packageName, String alias) {
         Preconditions.checkNotNull(packageName);
         Preconditions.checkNotNull(alias);
-        IBinder keySetToken;
+        KeySet ks;
         try {
-            keySetToken = mPM.getKeySetByAlias(packageName, alias);
+            ks = mPM.getKeySetByAlias(packageName, alias);
         } catch (RemoteException e) {
             return null;
         }
-        if (keySetToken == null) {
-            return null;
-        }
-        return new KeySet(keySetToken);
+        return ks;
     }
 
+    /** @hide */
     @Override
     public KeySet getSigningKeySet(String packageName) {
         Preconditions.checkNotNull(packageName);
-        IBinder keySetToken;
+        KeySet ks;
         try {
-            keySetToken = mPM.getSigningKeySet(packageName);
+            ks = mPM.getSigningKeySet(packageName);
         } catch (RemoteException e) {
             return null;
         }
-        if (keySetToken == null) {
-            return null;
-        }
-        return new KeySet(keySetToken);
+        return ks;
     }
 
-
+    /** @hide */
     @Override
     public boolean isSignedBy(String packageName, KeySet ks) {
         Preconditions.checkNotNull(packageName);
         Preconditions.checkNotNull(ks);
-        IBinder keySetToken = ks.getToken();
         try {
-            return mPM.isPackageSignedByKeySet(packageName, keySetToken);
+            return mPM.isPackageSignedByKeySet(packageName, ks);
         } catch (RemoteException e) {
             return false;
         }
     }
 
+    /** @hide */
     @Override
     public boolean isSignedByExactly(String packageName, KeySet ks) {
         Preconditions.checkNotNull(packageName);
         Preconditions.checkNotNull(ks);
-        IBinder keySetToken = ks.getToken();
         try {
-            return mPM.isPackageSignedByKeySetExactly(packageName, keySetToken);
+            return mPM.isPackageSignedByKeySetExactly(packageName, ks);
         } catch (RemoteException e) {
             return false;
         }
@@ -1604,30 +1646,6 @@
     /**
      * @hide
      */
-    public void addCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId) {
-        try {
-            mPM.addCrossProfileIntentsForPackage(packageName, sourceUserId, targetUserId);
-        } catch (RemoteException e) {
-            // Should never happen!
-        }
-    }
-
-    /**
-     * @hide
-     */
-    public void removeCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId) {
-        try {
-            mPM.removeCrossProfileIntentsForPackage(packageName, sourceUserId, targetUserId);
-        } catch (RemoteException e) {
-            // Should never happen!
-        }
-    }
-
-    /**
-     * @hide
-     */
     @Override
     public void clearCrossProfileIntentFilters(int sourceUserId) {
         try {
@@ -1643,14 +1661,92 @@
      */
     public Drawable loadItemIcon(PackageItemInfo itemInfo, ApplicationInfo appInfo) {
         if (itemInfo.showUserIcon != UserHandle.USER_NULL) {
-            return new BitmapDrawable(getUserManager().getUserIcon(itemInfo.showUserIcon));
+            Bitmap bitmap = getUserManager().getUserIcon(itemInfo.showUserIcon);
+            if (bitmap == null) {
+                return UserIcons.getDefaultUserIcon(itemInfo.showUserIcon, /* light= */ false);
+            }
+            return new BitmapDrawable(bitmap);
         }
-        Drawable dr = getDrawable(itemInfo.packageName, itemInfo.icon, appInfo);
+        Drawable dr = null;
+        if (itemInfo.packageName != null) {
+            dr = getDrawable(itemInfo.packageName, itemInfo.icon, appInfo);
+        }
         if (dr == null) {
             dr = itemInfo.loadDefaultIcon(this);
         }
-        return getUserManager().getBadgedDrawableForUser(dr,
-                new UserHandle(mContext.getUserId()));
+        return getUserBadgedIcon(dr, new UserHandle(mContext.getUserId()));
+    }
+
+    private Drawable getBadgedDrawable(Drawable drawable, Drawable badgeDrawable,
+            Rect badgeLocation, boolean tryBadgeInPlace) {
+        final int badgedWidth = drawable.getIntrinsicWidth();
+        final int badgedHeight = drawable.getIntrinsicHeight();
+        final boolean canBadgeInPlace = tryBadgeInPlace
+                && (drawable instanceof BitmapDrawable)
+                && ((BitmapDrawable) drawable).getBitmap().isMutable();
+
+        final Bitmap bitmap;
+        if (canBadgeInPlace) {
+            bitmap = ((BitmapDrawable) drawable).getBitmap();
+        } else {
+            bitmap = Bitmap.createBitmap(badgedWidth, badgedHeight, Bitmap.Config.ARGB_8888);
+        }
+        Canvas canvas = new Canvas(bitmap);
+
+        if (!canBadgeInPlace) {
+            drawable.setBounds(0, 0, badgedWidth, badgedHeight);
+            drawable.draw(canvas);
+        }
+
+        if (badgeLocation != null) {
+            if (badgeLocation.left < 0 || badgeLocation.top < 0
+                    || badgeLocation.width() > badgedWidth || badgeLocation.height() > badgedHeight) {
+                throw new IllegalArgumentException("Badge location " + badgeLocation
+                        + " not in badged drawable bounds "
+                        + new Rect(0, 0, badgedWidth, badgedHeight));
+            }
+            badgeDrawable.setBounds(0, 0, badgeLocation.width(), badgeLocation.height());
+
+            canvas.save();
+            canvas.translate(badgeLocation.left, badgeLocation.top);
+            badgeDrawable.draw(canvas);
+            canvas.restore();
+        } else {
+            badgeDrawable.setBounds(0, 0, badgedWidth, badgedHeight);
+            badgeDrawable.draw(canvas);
+        }
+
+        if (!canBadgeInPlace) {
+            BitmapDrawable mergedDrawable = new BitmapDrawable(mContext.getResources(), bitmap);
+
+            if (drawable instanceof BitmapDrawable) {
+                BitmapDrawable bitmapDrawable = (BitmapDrawable) drawable;
+                mergedDrawable.setTargetDensity(bitmapDrawable.getBitmap().getDensity());
+            }
+
+            return mergedDrawable;
+        }
+
+        return drawable;
+    }
+
+    private int getBadgeResIdForUser(int userHandle) {
+        // Return the framework-provided badge.
+        UserInfo userInfo = getUserIfProfile(userHandle);
+        if (userInfo != null && userInfo.isManagedProfile()) {
+            return com.android.internal.R.drawable.ic_corp_icon_badge;
+        }
+        return 0;
+    }
+
+    private UserInfo getUserIfProfile(int userHandle) {
+        List<UserInfo> userProfiles = getUserManager().getProfiles(UserHandle.myUserId());
+        for (UserInfo user : userProfiles) {
+            if (user.id == userHandle) {
+                return user;
+            }
+        }
+        return null;
     }
 
     private final ContextImpl mContext;
diff --git a/core/java/android/app/ApplicationThreadNative.java b/core/java/android/app/ApplicationThreadNative.java
index 52b69e1..0123e16 100644
--- a/core/java/android/app/ApplicationThreadNative.java
+++ b/core/java/android/app/ApplicationThreadNative.java
@@ -78,7 +78,8 @@
             boolean finished = data.readInt() != 0;
             boolean userLeaving = data.readInt() != 0;
             int configChanges = data.readInt();
-            schedulePauseActivity(b, finished, userLeaving, configChanges);
+            boolean dontReport = data.readInt() != 0;
+            schedulePauseActivity(b, finished, userLeaving, configChanges, dontReport);
             return true;
         }
 
@@ -129,7 +130,7 @@
             scheduleSendResult(b, ri);
             return true;
         }
-        
+
         case SCHEDULE_LAUNCH_ACTIVITY_TRANSACTION:
         {
             data.enforceInterface(IApplicationThread.descriptor);
@@ -148,17 +149,13 @@
             List<Intent> pi = data.createTypedArrayList(Intent.CREATOR);
             boolean notResumed = data.readInt() != 0;
             boolean isForward = data.readInt() != 0;
-            String profileName = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
-            boolean autoStopProfiler = data.readInt() != 0;
-            scheduleLaunchActivity(intent, b, ident, info, curConfig, compatInfo,
-                    voiceInteractor, procState, state, persistentState,
-                    ri, pi, notResumed, isForward, profileName, profileFd,
-                    autoStopProfiler);
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
+            scheduleLaunchActivity(intent, b, ident, info, curConfig, compatInfo, voiceInteractor,
+                    procState, state, persistentState, ri, pi, notResumed, isForward, profilerInfo);
             return true;
         }
-        
+
         case SCHEDULE_RELAUNCH_ACTIVITY_TRANSACTION:
         {
             data.enforceInterface(IApplicationThread.descriptor);
@@ -274,10 +271,8 @@
                 data.createTypedArrayList(ProviderInfo.CREATOR);
             ComponentName testName = (data.readInt() != 0)
                 ? new ComponentName(data) : null;
-            String profileName = data.readString();
-            ParcelFileDescriptor profileFd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
-            boolean autoStopProfiler = data.readInt() != 0;
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
             Bundle testArgs = data.readBundle();
             IBinder binder = data.readStrongBinder();
             IInstrumentationWatcher testWatcher = IInstrumentationWatcher.Stub.asInterface(binder);
@@ -292,11 +287,9 @@
             CompatibilityInfo compatInfo = CompatibilityInfo.CREATOR.createFromParcel(data);
             HashMap<String, IBinder> services = data.readHashMap(null);
             Bundle coreSettings = data.readBundle();
-            bindApplication(packageName, info,
-                            providers, testName, profileName, profileFd, autoStopProfiler,
-                            testArgs, testWatcher, uiAutomationConnection, testMode,
-                            openGlTrace, restrictedBackupMode, persistent, config, compatInfo,
-                            services, coreSettings);
+            bindApplication(packageName, info, providers, testName, profilerInfo, testArgs,
+                    testWatcher, uiAutomationConnection, testMode, openGlTrace,
+                    restrictedBackupMode, persistent, config, compatInfo, services, coreSettings);
             return true;
         }
 
@@ -403,7 +396,7 @@
             scheduleLowMemory();
             return true;
         }
-        
+
         case SCHEDULE_ACTIVITY_CONFIGURATION_CHANGED_TRANSACTION:
         {
             data.enforceInterface(IApplicationThread.descriptor);
@@ -411,19 +404,18 @@
             scheduleActivityConfigurationChanged(b);
             return true;
         }
-        
+
         case PROFILER_CONTROL_TRANSACTION:
         {
             data.enforceInterface(IApplicationThread.descriptor);
             boolean start = data.readInt() != 0;
             int profileType = data.readInt();
-            String path = data.readString();
-            ParcelFileDescriptor fd = data.readInt() != 0
-                    ? ParcelFileDescriptor.CREATOR.createFromParcel(data) : null;
-            profilerControl(start, path, fd, profileType);
+            ProfilerInfo profilerInfo = data.readInt() != 0
+                    ? ProfilerInfo.CREATOR.createFromParcel(data) : null;
+            profilerControl(start, profilerInfo, profileType);
             return true;
         }
-        
+
         case SET_SCHEDULING_GROUP_TRANSACTION:
         {
             data.enforceInterface(IApplicationThread.descriptor);
@@ -698,13 +690,14 @@
     }
     
     public final void schedulePauseActivity(IBinder token, boolean finished,
-            boolean userLeaving, int configChanges) throws RemoteException {
+            boolean userLeaving, int configChanges, boolean dontReport) throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
         data.writeStrongBinder(token);
         data.writeInt(finished ? 1 : 0);
         data.writeInt(userLeaving ? 1 :0);
         data.writeInt(configChanges);
+        data.writeInt(dontReport ? 1 : 0);
         mRemote.transact(SCHEDULE_PAUSE_ACTIVITY_TRANSACTION, data, null,
                 IBinder.FLAG_ONEWAY);
         data.recycle();
@@ -774,8 +767,7 @@
             IVoiceInteractor voiceInteractor, int procState, Bundle state,
             PersistableBundle persistentState, List<ResultInfo> pendingResults,
             List<Intent> pendingNewIntents, boolean notResumed, boolean isForward,
-            String profileName, ParcelFileDescriptor profileFd, boolean autoStopProfiler)
-            throws RemoteException {
+            ProfilerInfo profilerInfo) throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
         intent.writeToParcel(data, 0);
@@ -792,14 +784,12 @@
         data.writeTypedList(pendingNewIntents);
         data.writeInt(notResumed ? 1 : 0);
         data.writeInt(isForward ? 1 : 0);
-        data.writeString(profileName);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
-        data.writeInt(autoStopProfiler ? 1 : 0);
         mRemote.transact(SCHEDULE_LAUNCH_ACTIVITY_TRANSACTION, data, null,
                 IBinder.FLAG_ONEWAY);
         data.recycle();
@@ -959,9 +949,8 @@
     }
 
     public final void bindApplication(String packageName, ApplicationInfo info,
-            List<ProviderInfo> providers, ComponentName testName, String profileName,
-            ParcelFileDescriptor profileFd, boolean autoStopProfiler, Bundle testArgs,
-            IInstrumentationWatcher testWatcher,
+            List<ProviderInfo> providers, ComponentName testName, ProfilerInfo profilerInfo,
+            Bundle testArgs, IInstrumentationWatcher testWatcher,
             IUiAutomationConnection uiAutomationConnection, int debugMode,
             boolean openGlTrace, boolean restrictedBackupMode, boolean persistent,
             Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services,
@@ -977,14 +966,12 @@
             data.writeInt(1);
             testName.writeToParcel(data, 0);
         }
-        data.writeString(profileName);
-        if (profileFd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            profileFd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
-        data.writeInt(autoStopProfiler ? 1 : 0);
         data.writeBundle(testArgs);
         data.writeStrongInterface(testWatcher);
         data.writeStrongInterface(uiAutomationConnection);
@@ -1111,7 +1098,7 @@
                 IBinder.FLAG_ONEWAY);
         data.recycle();
     }
-    
+
     public final void scheduleActivityConfigurationChanged(
             IBinder token) throws RemoteException {
         Parcel data = Parcel.obtain();
@@ -1121,17 +1108,16 @@
                 IBinder.FLAG_ONEWAY);
         data.recycle();
     }
-    
-    public void profilerControl(boolean start, String path,
-            ParcelFileDescriptor fd, int profileType) throws RemoteException {
+
+    public void profilerControl(boolean start, ProfilerInfo profilerInfo, int profileType)
+            throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
         data.writeInt(start ? 1 : 0);
         data.writeInt(profileType);
-        data.writeString(path);
-        if (fd != null) {
+        if (profilerInfo != null) {
             data.writeInt(1);
-            fd.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
+            profilerInfo.writeToParcel(data, Parcelable.PARCELABLE_WRITE_RETURN_VALUE);
         } else {
             data.writeInt(0);
         }
@@ -1139,7 +1125,7 @@
                 IBinder.FLAG_ONEWAY);
         data.recycle();
     }
-    
+
     public void setSchedulingGroup(int group) throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
@@ -1148,7 +1134,7 @@
                 IBinder.FLAG_ONEWAY);
         data.recycle();
     }
-    
+
     public void dispatchPackageBroadcast(int cmd, String[] packages) throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
@@ -1157,9 +1143,8 @@
         mRemote.transact(DISPATCH_PACKAGE_BROADCAST_TRANSACTION, data, null,
                 IBinder.FLAG_ONEWAY);
         data.recycle();
-        
     }
-    
+
     public void scheduleCrash(String msg) throws RemoteException {
         Parcel data = Parcel.obtain();
         data.writeInterfaceToken(IApplicationThread.descriptor);
@@ -1167,7 +1152,6 @@
         mRemote.transact(SCHEDULE_CRASH_TRANSACTION, data, null,
                 IBinder.FLAG_ONEWAY);
         data.recycle();
-        
     }
 
     public void dumpHeap(boolean managed, String path,
diff --git a/core/java/android/app/BackStackRecord.java b/core/java/android/app/BackStackRecord.java
index 4433a3a..832e1e3 100644
--- a/core/java/android/app/BackStackRecord.java
+++ b/core/java/android/app/BackStackRecord.java
@@ -23,27 +23,26 @@
 import android.os.Parcelable;
 import android.text.TextUtils;
 import android.transition.Transition;
-import android.transition.TransitionInflater;
 import android.transition.TransitionManager;
 import android.transition.TransitionSet;
+import android.transition.TransitionUtils;
 import android.util.ArrayMap;
 import android.util.Log;
 import android.util.LogWriter;
 import android.util.Pair;
+import android.util.SparseArray;
 import android.view.View;
 import android.view.ViewGroup;
+import android.view.ViewTreeObserver;
 
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.util.ArrayList;
-import java.util.Collection;
 
 final class BackStackState implements Parcelable {
     final int[] mOps;
     final int mTransition;
     final int mTransitionStyle;
-    final int mCustomTransition;
-    final int mSceneRoot;
     final String mName;
     final int mIndex;
     final int mBreadCrumbTitleRes;
@@ -96,8 +95,6 @@
         mBreadCrumbTitleText = bse.mBreadCrumbTitleText;
         mBreadCrumbShortTitleRes = bse.mBreadCrumbShortTitleRes;
         mBreadCrumbShortTitleText = bse.mBreadCrumbShortTitleText;
-        mCustomTransition = bse.mCustomTransition;
-        mSceneRoot = bse.mSceneRoot;
         mSharedElementSourceNames = bse.mSharedElementSourceNames;
         mSharedElementTargetNames = bse.mSharedElementTargetNames;
     }
@@ -112,8 +109,6 @@
         mBreadCrumbTitleText = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
         mBreadCrumbShortTitleRes = in.readInt();
         mBreadCrumbShortTitleText = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(in);
-        mCustomTransition = in.readInt();
-        mSceneRoot = in.readInt();
         mSharedElementSourceNames = in.createStringArrayList();
         mSharedElementTargetNames = in.createStringArrayList();
     }
@@ -164,8 +159,6 @@
         bse.mBreadCrumbTitleText = mBreadCrumbTitleText;
         bse.mBreadCrumbShortTitleRes = mBreadCrumbShortTitleRes;
         bse.mBreadCrumbShortTitleText = mBreadCrumbShortTitleText;
-        bse.mCustomTransition = mCustomTransition;
-        bse.mSceneRoot = mSceneRoot;
         bse.mSharedElementSourceNames = mSharedElementSourceNames;
         bse.mSharedElementTargetNames = mSharedElementTargetNames;
         bse.bumpBackStackNesting(1);
@@ -186,8 +179,6 @@
         TextUtils.writeToParcel(mBreadCrumbTitleText, dest, 0);
         dest.writeInt(mBreadCrumbShortTitleRes);
         TextUtils.writeToParcel(mBreadCrumbShortTitleText, dest, 0);
-        dest.writeInt(mCustomTransition);
-        dest.writeInt(mSceneRoot);
         dest.writeStringList(mSharedElementSourceNames);
         dest.writeStringList(mSharedElementTargetNames);
     }
@@ -254,8 +245,6 @@
     int mBreadCrumbShortTitleRes;
     CharSequence mBreadCrumbShortTitleText;
 
-    int mCustomTransition;
-    int mSceneRoot;
     ArrayList<String> mSharedElementSourceNames;
     ArrayList<String> mSharedElementTargetNames;
 
@@ -573,12 +562,22 @@
     }
 
     @Override
-    public FragmentTransaction setCustomTransition(int sceneRootId, int transitionId) {
-        mSceneRoot = sceneRootId;
-        mCustomTransition = transitionId;
+    public FragmentTransaction addSharedElement(View sharedElement, String name) {
+        String transitionName = sharedElement.getTransitionName();
+        if (transitionName == null) {
+            throw new IllegalArgumentException("Unique transitionNames are required for all" +
+                    " sharedElements");
+        }
+        if (mSharedElementSourceNames == null) {
+            mSharedElementSourceNames = new ArrayList<String>();
+            mSharedElementTargetNames = new ArrayList<String>();
+        }
+        mSharedElementSourceNames.add(transitionName);
+        mSharedElementTargetNames.add(name);
         return this;
     }
 
+    /** TODO: remove this */
     @Override
     public FragmentTransaction setSharedElement(View sharedElement, String name) {
         String transitionName = sharedElement.getTransitionName();
@@ -594,6 +593,7 @@
         return this;
     }
 
+    /** TODO: remove this */
     @Override
     public FragmentTransaction setSharedElements(Pair<View, String>... sharedElements) {
         if (sharedElements == null || sharedElements.length == 0) {
@@ -742,8 +742,10 @@
 
         bumpBackStackNesting(1);
 
-        TransitionState state = beginTransition(mSharedElementSourceNames,
-                mSharedElementTargetNames);
+        SparseArray<Fragment> firstOutFragments = new SparseArray<Fragment>();
+        SparseArray<Fragment> lastInFragments = new SparseArray<Fragment>();
+        calculateFragments(firstOutFragments, lastInFragments);
+        beginTransition(firstOutFragments, lastInFragments, false);
 
         Op op = mHead;
         while (op != null) {
@@ -834,141 +836,606 @@
         if (mAddToBackStack) {
             mManager.addBackStackState(this);
         }
+    }
 
-        if (state != null) {
-            updateTransitionEndState(state, mSharedElementTargetNames);
+    private static void setFirstOut(SparseArray<Fragment> fragments, Fragment fragment) {
+        if (fragment != null) {
+            int containerId = fragment.mContainerId;
+            if (containerId != 0 && !fragment.isHidden() && fragment.isAdded() &&
+                    fragment.getView() != null && fragments.get(containerId) == null) {
+                fragments.put(containerId, fragment);
+            }
         }
     }
 
-    private TransitionState beginTransition(ArrayList<String> sourceNames,
-            ArrayList<String> targetNames) {
-        if (mCustomTransition <= 0 || mSceneRoot <= 0) {
-            return null;
+    private void setLastIn(SparseArray<Fragment> fragments, Fragment fragment) {
+        if (fragment != null) {
+            int containerId = fragment.mContainerId;
+            if (containerId != 0) {
+                fragments.put(containerId, fragment);
+            }
         }
-        View rootView = mManager.mContainer.findViewById(mSceneRoot);
-        if (!(rootView instanceof ViewGroup)) {
-            throw new IllegalArgumentException("SceneRoot is not a ViewGroup");
-        }
-        TransitionState state = new TransitionState();
-        // get Transition scene root and create Transitions
-        state.sceneRoot = (ViewGroup) rootView;
-        state.sceneRoot.captureTransitioningViews(state.transitioningViews);
+    }
 
-        state.exitTransition = TransitionInflater.from(mManager.mActivity)
-                .inflateTransition(mCustomTransition);
-        state.sharedElementTransition = TransitionInflater.from(mManager.mActivity)
-                .inflateTransition(mCustomTransition);
-        state.enterTransition = TransitionInflater.from(mManager.mActivity)
-                .inflateTransition(mCustomTransition);
+    /**
+     * Finds the first removed fragment and last added fragments when going forward.
+     * If none of the fragments have transitions, then both lists will be empty.
+     *
+     * @param firstOutFragments The list of first fragments to be removed, keyed on the
+     *                          container ID. This list will be modified by the method.
+     * @param lastInFragments The list of last fragments to be added, keyed on the
+     *                        container ID. This list will be modified by the method.
+     */
+    private void calculateFragments(SparseArray<Fragment> firstOutFragments,
+            SparseArray<Fragment> lastInFragments) {
+        Op op = mHead;
+        while (op != null) {
+            switch (op.cmd) {
+                case OP_ADD:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+                case OP_REPLACE: {
+                    Fragment f = op.fragment;
+                    if (mManager.mAdded != null) {
+                        for (int i = 0; i < mManager.mAdded.size(); i++) {
+                            Fragment old = mManager.mAdded.get(i);
+                            if (f == null || old.mContainerId == f.mContainerId) {
+                                if (old == f) {
+                                    f = null;
+                                } else {
+                                    setFirstOut(firstOutFragments, old);
+                                }
+                            }
+                        }
+                    }
+                    setLastIn(lastInFragments, f);
+                    break;
+                }
+                case OP_REMOVE:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_HIDE:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_SHOW:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+                case OP_DETACH:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_ATTACH:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+            }
+
+            op = op.next;
+        }
+    }
+
+    /**
+     * Finds the first removed fragment and last added fragments when popping the back stack.
+     * If none of the fragments have transitions, then both lists will be empty.
+     *
+     * @param firstOutFragments The list of first fragments to be removed, keyed on the
+     *                          container ID. This list will be modified by the method.
+     * @param lastInFragments The list of last fragments to be added, keyed on the
+     *                        container ID. This list will be modified by the method.
+     */
+    public void calculateBackFragments(SparseArray<Fragment> firstOutFragments,
+            SparseArray<Fragment> lastInFragments) {
+        Op op = mHead;
+        while (op != null) {
+            switch (op.cmd) {
+                case OP_ADD:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_REPLACE:
+                    if (op.removed != null) {
+                        for (int i = op.removed.size() - 1; i >= 0; i--) {
+                            setLastIn(lastInFragments, op.removed.get(i));
+                        }
+                    }
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_REMOVE:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+                case OP_HIDE:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+                case OP_SHOW:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+                case OP_DETACH:
+                    setLastIn(lastInFragments, op.fragment);
+                    break;
+                case OP_ATTACH:
+                    setFirstOut(firstOutFragments, op.fragment);
+                    break;
+            }
+
+            op = op.next;
+        }
+    }
+
+    /**
+     * When custom fragment transitions are used, this sets up the state for each transition
+     * and begins the transition. A different transition is started for each fragment container
+     * and consists of up to 3 different transitions: the exit transition, a shared element
+     * transition and an enter transition.
+     *
+     * <p>The exit transition operates against the leaf nodes of the first fragment
+     * with a view that was removed. If no such fragment was removed, then no exit
+     * transition is executed. The exit transition comes from the outgoing fragment.</p>
+     *
+     * <p>The enter transition operates against the last fragment that was added. If
+     * that fragment does not have a view or no fragment was added, then no enter
+     * transition is executed. The enter transition comes from the incoming fragment.</p>
+     *
+     * <p>The shared element transition operates against all views and comes either
+     * from the outgoing fragment or the incoming fragment, depending on whether this
+     * is going forward or popping the back stack. When going forward, the incoming
+     * fragment's enter shared element transition is used, but when going back, the
+     * outgoing fragment's return shared element transition is used. Shared element
+     * transitions only operate if there is both an incoming and outgoing fragment.</p>
+     *
+     * @param firstOutFragments The list of first fragments to be removed, keyed on the
+     *                          container ID.
+     * @param lastInFragments The list of last fragments to be added, keyed on the
+     *                        container ID.
+     * @param isBack true if this is popping the back stack or false if this is a
+     *               forward operation.
+     * @return The TransitionState used to complete the operation of the transition
+     * in {@link #setNameOverrides(android.app.BackStackRecord.TransitionState, java.util.ArrayList,
+     * java.util.ArrayList)}.
+     */
+    private TransitionState beginTransition(SparseArray<Fragment> firstOutFragments,
+            SparseArray<Fragment> lastInFragments, boolean isBack) {
+        TransitionState state = new TransitionState();
+
         // Adding a non-existent target view makes sure that the transitions don't target
         // any views by default. They'll only target the views we tell add. If we don't
         // add any, then no views will be targeted.
-        View nonExistentView = new View(mManager.mActivity);
-        state.enterTransition.addTarget(nonExistentView);
-        state.exitTransition.addTarget(nonExistentView);
-        state.sharedElementTransition.addTarget(nonExistentView);
+        state.nonExistentView = new View(mManager.mActivity);
 
-        setSharedElementEpicenter(state.enterTransition, state);
-
-        state.excludingTransition = new TransitionSet()
-                .addTransition(state.exitTransition)
-                .addTransition(state.enterTransition);
-
-        if (sourceNames != null) {
-            // Map shared elements.
-            state.sceneRoot.findNamedViews(state.namedViews);
-            state.namedViews.retainAll(sourceNames);
-            View epicenterView = state.namedViews.get(sourceNames.get(0));
-            if (epicenterView != null) {
-                // The epicenter is only the first shared element.
-                setEpicenter(state.exitTransition, epicenterView);
-                setEpicenter(state.sharedElementTransition, epicenterView);
-            }
-            state.transitioningViews.removeAll(state.namedViews.values());
-            state.excludingTransition.addTransition(state.sharedElementTransition);
-            addTransitioningViews(state.sharedElementTransition, state.namedViews.values());
+        // Go over all leaving fragments.
+        for (int i = 0; i < firstOutFragments.size(); i++) {
+            int containerId = firstOutFragments.keyAt(i);
+            configureTransitions(containerId, state, isBack, firstOutFragments,
+                    lastInFragments);
         }
 
-        // Adds the (maybe) exiting views, not including the shared element.
-        // If some stay, that's ok.
-        addTransitioningViews(state.exitTransition, state.transitioningViews);
-
-        // Prepare for shared element name mapping. This could be chained in the case
-        // of popping several back stack states.
-        state.excludingTransition.setNameOverrides(new ArrayMap<String, String>());
-        setNameOverrides(state, sourceNames, targetNames);
-
-        // Don't include any subtree in the views that are hidden when capturing the
-        // view hierarchy transitions. They should be as if not there.
-        excludeHiddenFragments(state, true);
-
-        TransitionManager.beginDelayedTransition(state.sceneRoot, state.excludingTransition);
+        // Now go over all entering fragments that didn't have a leaving fragment.
+        for (int i = 0; i < lastInFragments.size(); i++) {
+            int containerId = lastInFragments.keyAt(i);
+            if (firstOutFragments.get(containerId) == null) {
+                configureTransitions(containerId, state, isBack, firstOutFragments,
+                        lastInFragments);
+            }
+        }
         return state;
     }
 
-    private void updateTransitionEndState(TransitionState state, ArrayList<String> names) {
-        // Find all views that are entering.
-        ArrayList<View> enteringViews = new ArrayList<View>();
-        state.sceneRoot.captureTransitioningViews(enteringViews);
-        enteringViews.removeAll(state.transitioningViews);
+    private static Transition cloneTransition(Transition transition) {
+        if (transition != null) {
+            transition = transition.clone();
+        }
+        return transition;
+    }
 
-        if (names != null) {
-            // find all shared elements.
-            state.namedViews.clear();
-            state.sceneRoot.findNamedViews(state.namedViews);
-            state.namedViews.retainAll(names);
-            if (!state.namedViews.isEmpty()) {
-                enteringViews.removeAll(state.namedViews.values());
-                addTransitioningViews(state.sharedElementTransition, state.namedViews.values());
-                // now we know the epicenter of the entering transition.
-                state.mEnteringEpicenterView = state.namedViews.get(names.get(0));
+    private static Transition getEnterTransition(Fragment inFragment, boolean isBack) {
+        if (inFragment == null) {
+            return null;
+        }
+        return cloneTransition(isBack ? inFragment.getReenterTransition() :
+                inFragment.getEnterTransition());
+    }
+
+    private static Transition getExitTransition(Fragment outFragment, boolean isBack) {
+        if (outFragment == null) {
+            return null;
+        }
+        return cloneTransition(isBack ? outFragment.getReturnTransition() :
+                outFragment.getExitTransition());
+    }
+
+    private static Transition getSharedElementTransition(Fragment inFragment, Fragment outFragment,
+            boolean isBack) {
+        if (inFragment == null || outFragment == null) {
+            return null;
+        }
+        return cloneTransition(isBack ? outFragment.getSharedElementReturnTransition() :
+                inFragment.getSharedElementEnterTransition());
+    }
+
+    private static ArrayList<View> captureExitingViews(Transition exitTransition,
+            Fragment outFragment, ArrayMap<String, View> namedViews) {
+        ArrayList<View> viewList = null;
+        if (exitTransition != null) {
+            viewList = new ArrayList<View>();
+            View root = outFragment.getView();
+            root.captureTransitioningViews(viewList);
+            if (namedViews != null) {
+                viewList.removeAll(namedViews.values());
+            }
+            addTargets(exitTransition, viewList);
+        }
+        return viewList;
+    }
+
+    private ArrayMap<String, View> remapSharedElements(TransitionState state, Fragment outFragment,
+            boolean isBack) {
+        ArrayMap<String, View> namedViews = new ArrayMap<String, View>();
+        if (mSharedElementSourceNames != null) {
+            outFragment.getView().findNamedViews(namedViews);
+            if (isBack) {
+                namedViews.retainAll(mSharedElementTargetNames);
+            } else {
+                namedViews = remapNames(mSharedElementSourceNames, mSharedElementTargetNames,
+                        namedViews);
             }
         }
 
-        // Add all entering views to the enter transition.
-        addTransitioningViews(state.enterTransition, enteringViews);
-
-        // Don't allow capturing state for the newly-hidden fragments.
-        excludeHiddenFragments(state, false);
-
-        // Allow capturing state for the newly-shown fragments
-        includeVisibleFragments(state.excludingTransition);
-    }
-
-    private void addTransitioningViews(Transition transition, Collection<View> views) {
-        if (views.isEmpty()) {
-            // Add a view so that we can modify the valid views at the end of the
-            // fragment transaction.
-            transition.addTarget(new View(mManager.mActivity));
+        if (isBack) {
+            outFragment.mEnterTransitionCallback.onMapSharedElements(
+                    mSharedElementTargetNames, namedViews);
+            setBackNameOverrides(state, namedViews, false);
         } else {
-            for (View view : views) {
-                transition.addTarget(view);
+            outFragment.mExitTransitionCallback.onMapSharedElements(
+                    mSharedElementTargetNames, namedViews);
+            setNameOverrides(state, namedViews, false);
+        }
+
+        return namedViews;
+    }
+
+    /**
+     * Prepares the enter transition by adding a non-existent view to the transition's target list
+     * and setting it epicenter callback. By adding a non-existent view to the target list,
+     * we can prevent any view from being targeted at the beginning of the transition.
+     * We will add to the views before the end state of the transition is captured so that the
+     * views will appear. At the start of the transition, we clear the list of targets so that
+     * we can restore the state of the transition and use it again.
+     *
+     * <p>The shared element transition maps its shared elements immediately prior to
+     * capturing the final state of the Transition.</p>
+     */
+    private ArrayList<View> addTransitionTargets(final TransitionState state,
+            final Transition enterTransition, final Transition sharedElementTransition,
+            final Transition overallTransition, final View container,
+            final Fragment inFragment, final Fragment outFragment,
+            final ArrayList<View> hiddenFragmentViews, final boolean isBack) {
+        if (enterTransition == null && sharedElementTransition == null &&
+                overallTransition == null) {
+            return null;
+        }
+        final ArrayList<View> enteringViews = new ArrayList<View>();
+        container.getViewTreeObserver().addOnPreDrawListener(
+                new ViewTreeObserver.OnPreDrawListener() {
+                    @Override
+                    public boolean onPreDraw() {
+                        container.getViewTreeObserver().removeOnPreDrawListener(this);
+
+                        // Don't include any newly-hidden fragments in the transition.
+                        excludeHiddenFragments(hiddenFragmentViews, inFragment.mContainerId,
+                                overallTransition);
+
+                        ArrayMap<String, View> namedViews = null;
+                        if (sharedElementTransition != null) {
+                            namedViews = mapSharedElementsIn(state, isBack, inFragment);
+
+                            setEpicenterIn(namedViews, state);
+
+                            callSharedElementEnd(state, inFragment, outFragment, isBack,
+                                    namedViews);
+                        }
+
+                        if (enterTransition != null) {
+                            View view = inFragment.getView();
+                            if (view != null) {
+                                view.captureTransitioningViews(enteringViews);
+                                if (namedViews != null) {
+                                    enteringViews.removeAll(namedViews.values());
+                                }
+                                addTargets(enterTransition, enteringViews);
+                            }
+                            setSharedElementEpicenter(enterTransition, state);
+                        }
+                        return true;
+                    }
+                });
+        return enteringViews;
+    }
+
+    private void callSharedElementEnd(TransitionState state, Fragment inFragment,
+            Fragment outFragment, boolean isBack, ArrayMap<String, View> namedViews) {
+        SharedElementCallback sharedElementCallback = isBack ?
+                outFragment.mEnterTransitionCallback :
+                inFragment.mEnterTransitionCallback;
+        ArrayList<String> names = new ArrayList<String>(namedViews.keySet());
+        ArrayList<View> views = new ArrayList<View>(namedViews.values());
+        sharedElementCallback.onSharedElementEnd(names, views, null);
+    }
+
+    private void setEpicenterIn(ArrayMap<String, View> namedViews, TransitionState state) {
+        if (mSharedElementTargetNames != null && !namedViews.isEmpty()) {
+            // now we know the epicenter of the entering transition.
+            View epicenter = namedViews
+                    .get(mSharedElementTargetNames.get(0));
+            if (epicenter != null) {
+                state.enteringEpicenterView = epicenter;
             }
         }
     }
 
-    private void excludeHiddenFragments(TransitionState state, boolean forceExclude) {
-        if (mManager.mAdded != null) {
-            for (int i = 0; i < mManager.mAdded.size(); i++) {
-                Fragment fragment = mManager.mAdded.get(i);
-                if (fragment.mView != null && fragment.mHidden
-                        && (forceExclude || !state.hiddenViews.contains(fragment.mView))) {
-                    state.excludingTransition.excludeTarget(fragment.mView, true);
-                    state.hiddenViews.add(fragment.mView);
+    private ArrayMap<String, View> mapSharedElementsIn(TransitionState state,
+            boolean isBack, Fragment inFragment) {
+        // Now map the shared elements in the incoming fragment
+        ArrayMap<String, View> namedViews = mapEnteringSharedElements(state, inFragment, isBack);
+
+        // remap shared elements and set the name mapping used
+        // in the shared element transition.
+        if (isBack) {
+            inFragment.mExitTransitionCallback.onMapSharedElements(
+                    mSharedElementTargetNames, namedViews);
+            setBackNameOverrides(state, namedViews, true);
+        } else {
+            inFragment.mEnterTransitionCallback.onMapSharedElements(
+                    mSharedElementTargetNames, namedViews);
+            setNameOverrides(state, namedViews, true);
+        }
+        return namedViews;
+    }
+
+    private static Transition mergeTransitions(Transition enterTransition,
+            Transition exitTransition, Transition sharedElementTransition, Fragment inFragment,
+            boolean isBack) {
+        boolean overlap = true;
+        if (enterTransition != null && exitTransition != null) {
+            overlap = isBack ? inFragment.getAllowReturnTransitionOverlap() :
+                    inFragment.getAllowEnterTransitionOverlap();
+        }
+
+        // Wrap the transitions. Explicit targets like in enter and exit will cause the
+        // views to be targeted regardless of excluded views. If that happens, then the
+        // excluded fragments views (hidden fragments) will still be in the transition.
+
+        Transition transition;
+        if (overlap) {
+            // Regular transition -- do it all together
+            transition = TransitionUtils.mergeTransitions(enterTransition, exitTransition,
+                    sharedElementTransition);
+            if (!(transition instanceof TransitionSet)) {
+                transition = new TransitionSet().addTransition(transition);
+            }
+        } else {
+            // First do exit, then enter, but allow shared element transition to happen
+            // during both.
+            Transition staggered = null;
+            if (exitTransition != null && enterTransition != null) {
+                staggered = new TransitionSet()
+                        .addTransition(exitTransition)
+                        .addTransition(enterTransition)
+                        .setOrdering(TransitionSet.ORDERING_SEQUENTIAL);
+            } else if (exitTransition != null) {
+                staggered = exitTransition;
+            } else if (enterTransition != null) {
+                staggered = enterTransition;
+            }
+            if (sharedElementTransition != null) {
+                TransitionSet together = new TransitionSet();
+                if (staggered != null) {
+                    together.addTransition(staggered);
+                }
+                together.addTransition(sharedElementTransition);
+                transition = together;
+            } else {
+                transition = staggered;
+            }
+        }
+        return transition;
+    }
+
+    /**
+     * Configures custom transitions for a specific fragment container.
+     *
+     * @param containerId The container ID of the fragments to configure the transition for.
+     * @param state The Transition State keeping track of the executing transitions.
+     * @param firstOutFragments The list of first fragments to be removed, keyed on the
+     *                          container ID.
+     * @param lastInFragments The list of last fragments to be added, keyed on the
+     *                        container ID.
+     * @param isBack true if this is popping the back stack or false if this is a
+     *               forward operation.
+     */
+    private void configureTransitions(int containerId, TransitionState state, boolean isBack,
+            SparseArray<Fragment> firstOutFragments, SparseArray<Fragment> lastInFragments) {
+        ViewGroup sceneRoot = (ViewGroup) mManager.mContainer.findViewById(containerId);
+        if (sceneRoot != null) {
+            Fragment inFragment = lastInFragments.get(containerId);
+            Fragment outFragment = firstOutFragments.get(containerId);
+
+            Transition enterTransition = getEnterTransition(inFragment, isBack);
+            Transition sharedElementTransition = getSharedElementTransition(inFragment, outFragment,
+                    isBack);
+            Transition exitTransition = getExitTransition(outFragment, isBack);
+
+            if (enterTransition == null && sharedElementTransition == null &&
+                    exitTransition == null) {
+                return; // no transitions!
+            }
+            if (enterTransition != null) {
+                enterTransition.addTarget(state.nonExistentView);
+            }
+            ArrayMap<String, View> namedViews = null;
+            if (sharedElementTransition != null) {
+                namedViews = remapSharedElements(state, outFragment, isBack);
+
+                // Notify the start of the transition.
+                SharedElementCallback callback = isBack ?
+                        outFragment.mEnterTransitionCallback :
+                        inFragment.mEnterTransitionCallback;
+                ArrayList<String> names = new ArrayList<String>(namedViews.keySet());
+                ArrayList<View> views = new ArrayList<View>(namedViews.values());
+                callback.onSharedElementStart(names, views, null);
+            }
+
+            ArrayList<View> exitingViews = captureExitingViews(exitTransition, outFragment,
+                    namedViews);
+            if (exitingViews == null || exitingViews.isEmpty()) {
+                exitTransition = null;
+            }
+
+            // Set the epicenter of the exit transition
+            if (mSharedElementTargetNames != null && namedViews != null) {
+                View epicenterView = namedViews.get(mSharedElementTargetNames.get(0));
+                if (epicenterView != null) {
+                    if (exitTransition != null) {
+                        setEpicenter(exitTransition, epicenterView);
+                    }
+                    if (sharedElementTransition != null) {
+                        setEpicenter(sharedElementTransition, epicenterView);
+                    }
+                }
+            }
+
+            Transition transition = mergeTransitions(enterTransition, exitTransition,
+                    sharedElementTransition, inFragment, isBack);
+
+            if (transition != null) {
+                ArrayList<View> hiddenFragments = new ArrayList<View>();
+                ArrayList<View> enteringViews = addTransitionTargets(state, enterTransition,
+                        sharedElementTransition, transition, sceneRoot, inFragment, outFragment,
+                        hiddenFragments, isBack);
+
+                transition.setNameOverrides(state.nameOverrides);
+                // We want to exclude hidden views later, so we need a non-null list in the
+                // transition now.
+                transition.excludeTarget(state.nonExistentView, true);
+                // Now exclude all currently hidden fragments.
+                excludeHiddenFragments(hiddenFragments, containerId, transition);
+                TransitionManager.beginDelayedTransition(sceneRoot, transition);
+                // Remove the view targeting after the transition starts
+                removeTargetedViewsFromTransitions(sceneRoot, state.nonExistentView,
+                        enterTransition, enteringViews, exitTransition, exitingViews,
+                        transition, hiddenFragments);
+            }
+        }
+    }
+
+    /**
+     * After the transition has started, remove all targets that we added to the transitions
+     * so that the transitions are left in a clean state.
+     */
+    private void removeTargetedViewsFromTransitions(
+            final ViewGroup sceneRoot, final View nonExistingView,
+            final Transition enterTransition, final ArrayList<View> enteringViews,
+            final Transition exitTransition, final ArrayList<View> exitingViews,
+            final Transition overallTransition, final ArrayList<View> hiddenViews) {
+        if (enterTransition != null || exitTransition != null) {
+            sceneRoot.getViewTreeObserver().addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
+                @Override
+                public boolean onPreDraw() {
+                    sceneRoot.getViewTreeObserver().removeOnPreDrawListener(this);
+                    if (enterTransition != null) {
+                        enterTransition.removeTarget(nonExistingView);
+                        removeTargets(enterTransition, enteringViews);
+                    }
+                    if (exitTransition != null) {
+                        removeTargets(exitTransition, exitingViews);
+                    }
+                    int numViews = hiddenViews.size();
+                    for (int i = 0; i < numViews; i++) {
+                        overallTransition.excludeTarget(hiddenViews.get(i), false);
+                    }
+                    overallTransition.excludeTarget(nonExistingView, false);
+                    return true;
+                }
+            });
+        }
+    }
+
+    private static void removeTargets(Transition transition, ArrayList<View> views) {
+        int numViews = views.size();
+        for (int i = 0; i < numViews; i++) {
+            transition.removeTarget(views.get(i));
+        }
+    }
+
+    private static void addTargets(Transition transition, ArrayList<View> views) {
+        int numViews = views.size();
+        for (int i = 0; i < numViews; i++) {
+            transition.addTarget(views.get(i));
+        }
+    }
+
+    /**
+     * Remaps a name-to-View map, substituting different names for keys.
+     *
+     * @param inMap A list of keys found in the map, in the order in toGoInMap
+     * @param toGoInMap A list of keys to use for the new map, in the order of inMap
+     * @param namedViews The current mapping
+     * @return a new Map after it has been mapped with the new names as keys.
+     */
+    private static ArrayMap<String, View> remapNames(ArrayList<String> inMap,
+            ArrayList<String> toGoInMap, ArrayMap<String, View> namedViews) {
+        ArrayMap<String, View> remappedViews = new ArrayMap<String, View>();
+        if (!namedViews.isEmpty()) {
+            int numKeys = inMap.size();
+            for (int i = 0; i < numKeys; i++) {
+                View view = namedViews.get(inMap.get(i));
+
+                if (view != null) {
+                    remappedViews.put(toGoInMap.get(i), view);
                 }
             }
         }
-        if (forceExclude && state.hiddenViews.isEmpty()) {
-            state.excludingTransition.excludeTarget(new View(mManager.mActivity), true);
-        }
+        return remappedViews;
     }
 
-    private void includeVisibleFragments(Transition transition) {
+    /**
+     * Maps shared elements to views in the entering fragment.
+     *
+     * @param state The transition State as returned from {@link #beginTransition(
+     * android.util.SparseArray, android.util.SparseArray, boolean)}.
+     * @param inFragment The last fragment to be added.
+     * @param isBack true if this is popping the back stack or false if this is a
+     *               forward operation.
+     */
+    private ArrayMap<String, View> mapEnteringSharedElements(TransitionState state,
+            Fragment inFragment, boolean isBack) {
+        ArrayMap<String, View> namedViews = new ArrayMap<String, View>();
+        View root = inFragment.getView();
+        if (root != null) {
+            if (mSharedElementSourceNames != null) {
+                root.findNamedViews(namedViews);
+                if (isBack) {
+                    namedViews = remapNames(mSharedElementSourceNames,
+                            mSharedElementTargetNames, namedViews);
+                } else {
+                    namedViews.retainAll(mSharedElementTargetNames);
+                }
+            }
+        }
+        return namedViews;
+    }
+
+    private void excludeHiddenFragments(final ArrayList<View> hiddenFragmentViews, int containerId,
+            Transition transition) {
         if (mManager.mAdded != null) {
             for (int i = 0; i < mManager.mAdded.size(); i++) {
                 Fragment fragment = mManager.mAdded.get(i);
-                if (fragment.mView != null && !fragment.mHidden) {
-                    transition.excludeTarget(fragment.mView, false);
+                if (fragment.mView != null && fragment.mContainer != null &&
+                        fragment.mContainerId == containerId) {
+                    if (fragment.mHidden) {
+                        if (!hiddenFragmentViews.contains(fragment.mView)) {
+                            transition.excludeTarget(fragment.mView, true);
+                            hiddenFragmentViews.add(fragment.mView);
+                        }
+                    } else {
+                        transition.excludeTarget(fragment.mView, false);
+                        hiddenFragmentViews.remove(fragment.mView);
+                    }
                 }
             }
         }
@@ -992,16 +1459,17 @@
 
             @Override
             public Rect onGetEpicenter(Transition transition) {
-                if (mEpicenter == null && state.mEnteringEpicenterView != null) {
+                if (mEpicenter == null && state.enteringEpicenterView != null) {
                     mEpicenter = new Rect();
-                    state.mEnteringEpicenterView.getBoundsOnScreen(mEpicenter);
+                    state.enteringEpicenterView.getBoundsOnScreen(mEpicenter);
                 }
                 return mEpicenter;
             }
         });
     }
 
-    public TransitionState popFromBackStack(boolean doStateMove, TransitionState state) {
+    public TransitionState popFromBackStack(boolean doStateMove, TransitionState state,
+            SparseArray<Fragment> firstOutFragments, SparseArray<Fragment> lastInFragments) {
         if (FragmentManagerImpl.DEBUG) {
             Log.v(TAG, "popFromBackStack: " + this);
             LogWriter logw = new LogWriter(Log.VERBOSE, TAG);
@@ -1011,8 +1479,10 @@
         }
 
         if (state == null) {
-            state = beginTransition(mSharedElementTargetNames, mSharedElementSourceNames);
-        } else {
+            if (firstOutFragments.size() != 0 || lastInFragments.size() != 0) {
+                state = beginTransition(firstOutFragments, lastInFragments, true);
+            }
+        } else if (!doStateMove) {
             setNameOverrides(state, mSharedElementTargetNames, mSharedElementSourceNames);
         }
 
@@ -1091,10 +1561,7 @@
         if (doStateMove) {
             mManager.moveToState(mManager.mCurState,
                     FragmentManagerImpl.reverseTransit(mTransition), mTransitionStyle, true);
-            if (state != null) {
-                updateTransitionEndState(state, mSharedElementSourceNames);
-                state = null;
-            }
+            state = null;
         }
 
         if (mIndex >= 0) {
@@ -1104,15 +1571,17 @@
         return state;
     }
 
-    private static void setNameOverride(Transition transition, String source, String target) {
-        ArrayMap<String, String> overrides = transition.getNameOverrides();
-        for (int index = 0; index < overrides.size(); index++) {
-            if (source.equals(overrides.valueAt(index))) {
-                overrides.setValueAt(index, target);
-                return;
+    private static void setNameOverride(ArrayMap<String, String> overrides,
+            String source, String target) {
+        if (source != null && target != null && !source.equals(target)) {
+            for (int index = 0; index < overrides.size(); index++) {
+                if (source.equals(overrides.valueAt(index))) {
+                    overrides.setValueAt(index, target);
+                    return;
+                }
             }
+            overrides.put(source, target);
         }
-        overrides.put(source, target);
     }
 
     private static void setNameOverrides(TransitionState state, ArrayList<String> sourceNames,
@@ -1121,7 +1590,39 @@
             for (int i = 0; i < sourceNames.size(); i++) {
                 String source = sourceNames.get(i);
                 String target = targetNames.get(i);
-                setNameOverride(state.excludingTransition, source, target);
+                setNameOverride(state.nameOverrides, source, target);
+            }
+        }
+    }
+
+    private void setBackNameOverrides(TransitionState state, ArrayMap<String, View> namedViews,
+            boolean isEnd) {
+        int count = mSharedElementTargetNames.size();
+        for (int i = 0; i < count; i++) {
+            String source = mSharedElementSourceNames.get(i);
+            String originalTarget = mSharedElementTargetNames.get(i);
+            View view = namedViews.get(originalTarget);
+            if (view != null) {
+                String target = view.getTransitionName();
+                if (isEnd) {
+                    setNameOverride(state.nameOverrides, source, target);
+                } else {
+                    setNameOverride(state.nameOverrides, target, source);
+                }
+            }
+        }
+    }
+
+    private void setNameOverrides(TransitionState state, ArrayMap<String, View> namedViews,
+            boolean isEnd) {
+        int count = namedViews.size();
+        for (int i = 0; i < count; i++) {
+            String source = namedViews.keyAt(i);
+            String target = namedViews.valueAt(i).getTransitionName();
+            if (isEnd) {
+                setNameOverride(state.nameOverrides, source, target);
+            } else {
+                setNameOverride(state.nameOverrides, target, source);
             }
         }
     }
@@ -1143,14 +1644,8 @@
     }
 
     public class TransitionState {
-        public ArrayList<View> hiddenViews = new ArrayList<View>();
-        public ArrayList<View> transitioningViews = new ArrayList<View>();
-        public ArrayMap<String, View> namedViews = new ArrayMap<String, View>();
-        public Transition exitTransition;
-        public Transition sharedElementTransition;
-        public Transition enterTransition;
-        public TransitionSet excludingTransition;
-        public ViewGroup sceneRoot;
-        public View mEnteringEpicenterView;
+        public ArrayMap<String, String> nameOverrides = new ArrayMap<String, String>();
+        public View enteringEpicenterView;
+        public View nonExistentView;
     }
 }
diff --git a/core/java/android/app/ContextImpl.java b/core/java/android/app/ContextImpl.java
index da343ac..e9340eb 100644
--- a/core/java/android/app/ContextImpl.java
+++ b/core/java/android/app/ContextImpl.java
@@ -92,8 +92,6 @@
 import android.net.nsd.NsdManager;
 import android.net.wifi.IWifiManager;
 import android.net.wifi.WifiManager;
-import android.net.wifi.passpoint.IWifiPasspointManager;
-import android.net.wifi.passpoint.WifiPasspointManager;
 import android.net.wifi.p2p.IWifiP2pManager;
 import android.net.wifi.p2p.WifiP2pManager;
 import android.net.wifi.IWifiScanner;
@@ -122,12 +120,11 @@
 import android.os.UserManager;
 import android.os.storage.IMountService;
 import android.os.storage.StorageManager;
-import android.phone.PhoneManager;
 import android.print.IPrintManager;
 import android.print.PrintManager;
 import android.service.fingerprint.IFingerprintService;
 import android.service.fingerprint.FingerprintManager;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.telephony.TelephonyManager;
 import android.content.ClipboardManager;
 import android.util.AndroidRuntimeException;
@@ -151,7 +148,7 @@
 import com.android.internal.annotations.GuardedBy;
 import com.android.internal.app.IAppOpsService;
 import com.android.internal.os.IDropBoxManagerService;
-import com.android.internal.telecomm.ITelecommService;
+import com.android.internal.telecom.ITelecomService;
 
 import java.io.File;
 import java.io.FileInputStream;
@@ -565,14 +562,9 @@
                     return new TelephonyManager(ctx.getOuterContext());
                 }});
 
-        registerService(TELECOMM_SERVICE, new ServiceFetcher() {
+        registerService(TELECOM_SERVICE, new ServiceFetcher() {
                 public Object createService(ContextImpl ctx) {
-                    return new TelecommManager(ctx.getOuterContext());
-                }});
-
-        registerService(PHONE_SERVICE, new ServiceFetcher() {
-                public Object createService(ContextImpl ctx) {
-                    return new PhoneManager(ctx.getOuterContext());
+                    return new TelecomManager(ctx.getOuterContext());
                 }});
 
         registerService(UI_MODE_SERVICE, new ServiceFetcher() {
@@ -606,13 +598,6 @@
                     return new WifiManager(ctx.getOuterContext(), service);
                 }});
 
-        registerService(WIFI_PASSPOINT_SERVICE, new ServiceFetcher() {
-                public Object createService(ContextImpl ctx) {
-                    IBinder b = ServiceManager.getService(WIFI_PASSPOINT_SERVICE);
-                    IWifiPasspointManager service = IWifiPasspointManager.Stub.asInterface(b);
-                    return new WifiPasspointManager(ctx.getOuterContext(), service);
-                }});
-
         registerService(WIFI_P2P_SERVICE, new ServiceFetcher() {
                 public Object createService(ContextImpl ctx) {
                     IBinder b = ServiceManager.getService(WIFI_P2P_SERVICE);
@@ -1262,7 +1247,7 @@
             ActivityManagerNative.getDefault().startActivityAsUser(
                 mMainThread.getApplicationThread(), getBasePackageName(), intent,
                 intent.resolveTypeIfNeeded(getContentResolver()),
-                null, null, 0, Intent.FLAG_ACTIVITY_NEW_TASK, null, null, options,
+                null, null, 0, Intent.FLAG_ACTIVITY_NEW_TASK, null, options,
                 user.getIdentifier());
         } catch (RemoteException re) {
         }
@@ -2252,7 +2237,6 @@
         mUser = user;
 
         mPackageInfo = packageInfo;
-        mContentResolver = new ApplicationContentResolver(this, mainThread, user);
         mResourcesManager = ResourcesManager.getInstance();
         mDisplay = display;
         mOverrideConfiguration = overrideConfiguration;
@@ -2299,6 +2283,8 @@
                 mOpPackageName = mBasePackageName;
             }
         }
+
+        mContentResolver = new ApplicationContentResolver(this, mainThread, user);
     }
 
     void installSystemApplicationInfo(ApplicationInfo info, ClassLoader classLoader) {
diff --git a/core/java/android/app/DatePickerDialog.java b/core/java/android/app/DatePickerDialog.java
index 1e556d6..f79d32b 100644
--- a/core/java/android/app/DatePickerDialog.java
+++ b/core/java/android/app/DatePickerDialog.java
@@ -135,6 +135,9 @@
                             mDatePicker.getMonth(), mDatePicker.getDayOfMonth());
                 }
                 break;
+            case BUTTON_NEGATIVE:
+                cancel();
+                break;
         }
     }
 
diff --git a/core/java/android/app/EnterTransitionCoordinator.java b/core/java/android/app/EnterTransitionCoordinator.java
index 75ecbd9..16a3575 100644
--- a/core/java/android/app/EnterTransitionCoordinator.java
+++ b/core/java/android/app/EnterTransitionCoordinator.java
@@ -21,8 +21,6 @@
 import android.graphics.Matrix;
 import android.graphics.drawable.Drawable;
 import android.os.Bundle;
-import android.os.Handler;
-import android.os.Message;
 import android.os.ResultReceiver;
 import android.text.TextUtils;
 import android.transition.Transition;
@@ -71,16 +69,19 @@
         Bundle resultReceiverBundle = new Bundle();
         resultReceiverBundle.putParcelable(KEY_REMOTE_RECEIVER, this);
         mResultReceiver.send(MSG_SET_REMOTE_RECEIVER, resultReceiverBundle);
-        getDecor().getViewTreeObserver().addOnPreDrawListener(
-                new ViewTreeObserver.OnPreDrawListener() {
-                    @Override
-                    public boolean onPreDraw() {
-                        if (mIsReadyForTransition) {
-                            getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
+        final View decorView = getDecor();
+        if (decorView != null) {
+            decorView.getViewTreeObserver().addOnPreDrawListener(
+                    new ViewTreeObserver.OnPreDrawListener() {
+                        @Override
+                        public boolean onPreDraw() {
+                            if (mIsReadyForTransition) {
+                                decorView.getViewTreeObserver().removeOnPreDrawListener(this);
+                            }
+                            return mIsReadyForTransition;
                         }
-                        return mIsReadyForTransition;
-                    }
-                });
+                    });
+        }
     }
 
     public void viewInstancesReady(ArrayList<String> accepted, ArrayList<String> localNames,
@@ -113,9 +114,9 @@
     protected void viewsReady(ArrayMap<String, View> sharedElements) {
         super.viewsReady(sharedElements);
         mIsReadyForTransition = true;
-        setTransitionAlpha(mSharedElements, 0);
-        if (getViewsTransition() != null) {
-            setTransitionAlpha(mTransitioningViews, 0);
+        hideViews(mSharedElements);
+        if (getViewsTransition() != null && mTransitioningViews != null) {
+            hideViews(mTransitioningViews);
         }
         if (mIsReturning) {
             sendSharedElementDestination();
@@ -137,11 +138,12 @@
         if (sharedElements.isEmpty() || !sharedElements.valueAt(0).isLayoutRequested()) {
             viewsReady(sharedElements);
         } else {
-            sharedElements.valueAt(0).getViewTreeObserver()
+            final View sharedElement = sharedElements.valueAt(0);
+            sharedElement.getViewTreeObserver()
                     .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
                 @Override
                 public boolean onPreDraw() {
-                    sharedElements.valueAt(0).getViewTreeObserver().removeOnPreDrawListener(this);
+                    sharedElement.getViewTreeObserver().removeOnPreDrawListener(this);
                     viewsReady(sharedElements);
                     return true;
                 }
@@ -152,7 +154,10 @@
     private ArrayMap<String, View> mapNamedElements(ArrayList<String> accepted,
             ArrayList<String> localNames) {
         ArrayMap<String, View> sharedElements = new ArrayMap<String, View>();
-        getDecor().findNamedViews(sharedElements);
+        ViewGroup decorView = getDecor();
+        if (decorView != null) {
+            decorView.findNamedViews(sharedElements);
+        }
         if (accepted != null) {
             for (int i = 0; i < localNames.size(); i++) {
                 String localName = localNames.get(i);
@@ -170,10 +175,13 @@
 
     private void sendSharedElementDestination() {
         boolean allReady;
-        if (allowOverlappingTransitions()) {
+        final View decorView = getDecor();
+        if (allowOverlappingTransitions() && getEnterViewsTransition() != null) {
             allReady = false;
+        } else if (decorView == null) {
+            allReady = true;
         } else {
-            allReady = !getDecor().isLayoutRequested();
+            allReady = !decorView.isLayoutRequested();
             if (allReady) {
                 for (int i = 0; i < mSharedElements.size(); i++) {
                     if (mSharedElements.get(i).isLayoutRequested()) {
@@ -188,16 +196,18 @@
             setSharedElementMatrices();
             moveSharedElementsToOverlay();
             mResultReceiver.send(MSG_SHARED_ELEMENT_DESTINATION, state);
-        } else {
-            getDecor().getViewTreeObserver()
+        } else if (decorView != null) {
+            decorView.getViewTreeObserver()
                     .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
                         @Override
                         public boolean onPreDraw() {
-                            getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
-                            Bundle state = captureSharedElementState();
-                            setSharedElementMatrices();
-                            moveSharedElementsToOverlay();
-                            mResultReceiver.send(MSG_SHARED_ELEMENT_DESTINATION, state);
+                            decorView.getViewTreeObserver().removeOnPreDrawListener(this);
+                            if (mResultReceiver != null) {
+                                Bundle state = captureSharedElementState();
+                                setSharedElementMatrices();
+                                moveSharedElementsToOverlay();
+                                mResultReceiver.send(MSG_SHARED_ELEMENT_DESTINATION, state);
+                            }
                             return true;
                         }
                     });
@@ -207,7 +217,7 @@
         }
     }
 
-    private static SharedElementListener getListener(Activity activity, boolean isReturning) {
+    private static SharedElementCallback getListener(Activity activity, boolean isReturning) {
         return isReturning ? activity.mExitTransitionListener : activity.mEnterTransitionListener;
     }
 
@@ -238,8 +248,8 @@
         if (!mIsCanceled) {
             mIsCanceled = true;
             if (getViewsTransition() == null || mIsViewsTransitionStarted) {
-                setTransitionAlpha(mSharedElements, 1);
-            } else {
+                showViews(mSharedElements, true);
+            } else if (mTransitioningViews != null) {
                 mTransitioningViews.addAll(mSharedElements);
             }
             mSharedElementNames.clear();
@@ -288,17 +298,21 @@
     }
 
     private void startSharedElementTransition(Bundle sharedElementState) {
+        ViewGroup decorView = getDecor();
+        if (decorView == null) {
+            return;
+        }
         // Remove rejected shared elements
         ArrayList<String> rejectedNames = new ArrayList<String>(mAllSharedElementNames);
         rejectedNames.removeAll(mSharedElementNames);
         ArrayList<View> rejectedSnapshots = createSnapshots(sharedElementState, rejectedNames);
-        mListener.handleRejectedSharedElements(rejectedSnapshots);
+        mListener.onRejectSharedElements(rejectedSnapshots);
         startRejectedAnimations(rejectedSnapshots);
 
         // Now start shared element transition
         ArrayList<View> sharedElementSnapshots = createSnapshots(sharedElementState,
                 mSharedElementNames);
-        setTransitionAlpha(mSharedElements, 1);
+        showViews(mSharedElements, true);
         scheduleSetSharedElementEnd(sharedElementSnapshots);
         ArrayList<SharedElementOriginalState> originalImageViewState =
                 setSharedElementState(sharedElementState, sharedElementSnapshots);
@@ -308,7 +322,8 @@
         boolean startSharedElementTransition = true;
         setGhostVisibility(View.INVISIBLE);
         scheduleGhostVisibilityChange(View.INVISIBLE);
-        Transition transition = beginTransition(startEnterTransition, startSharedElementTransition);
+        Transition transition = beginTransition(decorView, startEnterTransition,
+                startSharedElementTransition);
         scheduleGhostVisibilityChange(View.VISIBLE);
         setGhostVisibility(View.VISIBLE);
 
@@ -321,13 +336,17 @@
         if (mResultReceiver != null) {
             // We can't trust that the view will disappear on the same frame that the shared
             // element appears here. Assure that we get at least 2 frames for double-buffering.
-            getDecor().postOnAnimation(new Runnable() {
+            decorView.postOnAnimation(new Runnable() {
                 int mAnimations;
+
                 @Override
                 public void run() {
                     if (mAnimations++ < MIN_ANIMATION_FRAMES) {
-                        getDecor().postOnAnimation(this);
-                    } else {
+                        View decorView = getDecor();
+                        if (decorView != null) {
+                            decorView.postOnAnimation(this);
+                        }
+                    } else if (mResultReceiver != null) {
                         mResultReceiver.send(MSG_HIDE_SHARED_ELEMENTS, null);
                         mResultReceiver = null; // all done sending messages.
                     }
@@ -342,21 +361,24 @@
         }
         final Bundle sharedElementState = mSharedElementsBundle;
         mSharedElementsBundle = null;
-        getDecor().getViewTreeObserver()
-                .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
-                    @Override
-                    public boolean onPreDraw() {
-                        getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
-                        startTransition(new Runnable() {
-                            @Override
-                            public void run() {
-                                startSharedElementTransition(sharedElementState);
-                            }
-                        });
-                        return false;
-                    }
-                });
-        getDecor().invalidate();
+        final View decorView = getDecor();
+        if (decorView != null) {
+            decorView.getViewTreeObserver()
+                    .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
+                        @Override
+                        public boolean onPreDraw() {
+                            decorView.getViewTreeObserver().removeOnPreDrawListener(this);
+                            startTransition(new Runnable() {
+                                @Override
+                                public void run() {
+                                    startSharedElementTransition(sharedElementState);
+                                }
+                            });
+                            return false;
+                        }
+                    });
+            decorView.invalidate();
+        }
     }
 
     private void requestLayoutForSharedElements() {
@@ -366,7 +388,7 @@
         }
     }
 
-    private Transition beginTransition(boolean startEnterTransition,
+    private Transition beginTransition(ViewGroup decorView, boolean startEnterTransition,
             boolean startSharedElementTransition) {
         Transition sharedElementTransition = null;
         if (startSharedElementTransition) {
@@ -394,7 +416,7 @@
         Transition viewsTransition = null;
         if (startEnterTransition) {
             mIsViewsTransitionStarted = true;
-            if (!mTransitioningViews.isEmpty()) {
+            if (mTransitioningViews != null && !mTransitioningViews.isEmpty()) {
                 viewsTransition = configureTransition(getViewsTransition(), true);
                 if (viewsTransition != null && !mIsReturning) {
                     stripOffscreenViews();
@@ -404,11 +426,14 @@
                 viewTransitionComplete();
             } else {
                 viewsTransition.forceVisibility(View.INVISIBLE, true);
+                final ArrayList<View> transitioningViews = mTransitioningViews;
                 viewsTransition.addListener(new ContinueTransitionListener() {
                     @Override
                     public void onTransitionStart(Transition transition) {
                         mEnterViewsTransition = transition;
-                        setTransitionAlpha(mTransitioningViews, 1);
+                        if (transitioningViews != null) {
+                            showViews(transitioningViews, false);
+                        }
                         super.onTransitionStart(transition);
                     }
 
@@ -426,10 +451,11 @@
         Transition transition = mergeTransitions(sharedElementTransition, viewsTransition);
         if (transition != null) {
             transition.addListener(new ContinueTransitionListener());
-            TransitionManager.beginDelayedTransition(getDecor(), transition);
+            TransitionManager.beginDelayedTransition(decorView, transition);
             if (startSharedElementTransition && !mSharedElementNames.isEmpty()) {
                 mSharedElements.get(0).invalidate();
-            } else if (startEnterTransition && !mTransitioningViews.isEmpty()) {
+            } else if (startEnterTransition && mTransitioningViews != null &&
+                    !mTransitioningViews.isEmpty()) {
                 mTransitioningViews.get(0).invalidate();
             }
         } else {
@@ -460,10 +486,12 @@
     }
 
     private void startEnterTransition(Transition transition) {
-        if (!mIsReturning) {
-            Drawable background = getDecor().getBackground();
+        ViewGroup decorView = getDecor();
+        if (!mIsReturning && decorView != null) {
+            Drawable background = decorView.getBackground();
             if (background != null) {
                 background = background.mutate();
+                getWindow().setBackgroundDrawable(background);
                 mBackgroundAnimator = ObjectAnimator.ofInt(background, "alpha", 255);
                 mBackgroundAnimator.setDuration(getFadeDuration());
                 mBackgroundAnimator.addListener(new AnimatorListenerAdapter() {
@@ -531,25 +559,28 @@
         if (rejectedSnapshots == null || rejectedSnapshots.isEmpty()) {
             return;
         }
-        ViewGroupOverlay overlay = getDecor().getOverlay();
-        ObjectAnimator animator = null;
-        int numRejected = rejectedSnapshots.size();
-        for (int i = 0; i < numRejected; i++) {
-            View snapshot = rejectedSnapshots.get(i);
-            overlay.add(snapshot);
-            animator = ObjectAnimator.ofFloat(snapshot, View.ALPHA, 1, 0);
-            animator.start();
-        }
-        animator.addListener(new AnimatorListenerAdapter() {
-            @Override
-            public void onAnimationEnd(Animator animation) {
-                ViewGroupOverlay overlay = getDecor().getOverlay();
-                int numRejected = rejectedSnapshots.size();
-                for (int i = 0; i < numRejected; i++) {
-                    overlay.remove(rejectedSnapshots.get(i));
-                }
+        final ViewGroup decorView = getDecor();
+        if (decorView != null) {
+            ViewGroupOverlay overlay = decorView.getOverlay();
+            ObjectAnimator animator = null;
+            int numRejected = rejectedSnapshots.size();
+            for (int i = 0; i < numRejected; i++) {
+                View snapshot = rejectedSnapshots.get(i);
+                overlay.add(snapshot);
+                animator = ObjectAnimator.ofFloat(snapshot, View.ALPHA, 1, 0);
+                animator.start();
             }
-        });
+            animator.addListener(new AnimatorListenerAdapter() {
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    ViewGroupOverlay overlay = decorView.getOverlay();
+                    int numRejected = rejectedSnapshots.size();
+                    for (int i = 0; i < numRejected; i++) {
+                        overlay.remove(rejectedSnapshots.get(i));
+                    }
+                }
+            });
+        }
     }
 
     protected void onRemoteExitTransitionComplete() {
@@ -564,9 +595,12 @@
             public void run() {
                 boolean startEnterTransition = true;
                 boolean startSharedElementTransition = false;
-                Transition transition = beginTransition(startEnterTransition,
-                        startSharedElementTransition);
-                startEnterTransition(transition);
+                ViewGroup decorView = getDecor();
+                if (decorView != null) {
+                    Transition transition = beginTransition(decorView, startEnterTransition,
+                            startSharedElementTransition);
+                    startEnterTransition(transition);
+                }
             }
         });
     }
diff --git a/core/java/android/app/ExitTransitionCoordinator.java b/core/java/android/app/ExitTransitionCoordinator.java
index 43b9ea8..812dfdb 100644
--- a/core/java/android/app/ExitTransitionCoordinator.java
+++ b/core/java/android/app/ExitTransitionCoordinator.java
@@ -19,6 +19,7 @@
 import android.animation.AnimatorListenerAdapter;
 import android.animation.ObjectAnimator;
 import android.content.Intent;
+import android.graphics.Color;
 import android.graphics.Matrix;
 import android.graphics.RectF;
 import android.graphics.drawable.ColorDrawable;
@@ -78,7 +79,7 @@
         mActivity = activity;
     }
 
-    private static SharedElementListener getListener(Activity activity, boolean isReturning) {
+    private static SharedElementCallback getListener(Activity activity, boolean isReturning) {
         return isReturning ? activity.mEnterTransitionListener : activity.mExitTransitionListener;
     }
 
@@ -125,24 +126,30 @@
     }
 
     public void resetViews() {
-        setTransitionAlpha(mTransitioningViews, 1);
-        setTransitionAlpha(mSharedElements, 1);
+        if (mTransitioningViews != null) {
+            showViews(mTransitioningViews, true);
+        }
+        showViews(mSharedElements, true);
         mIsHidden = true;
-        if (!mIsReturning && getDecor() != null) {
-            getDecor().suppressLayout(false);
+        ViewGroup decorView = getDecor();
+        if (!mIsReturning && decorView != null) {
+            decorView.suppressLayout(false);
         }
         moveSharedElementsFromOverlay();
         clearState();
     }
 
     private void sharedElementExitBack() {
-        if (getDecor() != null) {
-            getDecor().suppressLayout(true);
+        final ViewGroup decorView = getDecor();
+        if (decorView != null) {
+            decorView.suppressLayout(true);
         }
-        if (!mSharedElements.isEmpty() && getSharedElementTransition() != null) {
+        if (decorView != null && mExitSharedElementBundle != null &&
+                !mExitSharedElementBundle.isEmpty() &&
+                !mSharedElements.isEmpty() && getSharedElementTransition() != null) {
             startTransition(new Runnable() {
                 public void run() {
-                    startSharedElementExit();
+                    startSharedElementExit(decorView);
                 }
             });
         } else {
@@ -150,7 +157,7 @@
         }
     }
 
-    private void startSharedElementExit() {
+    private void startSharedElementExit(final ViewGroup decorView) {
         Transition transition = getSharedElementExitTransition();
         transition.addListener(new Transition.TransitionListenerAdapter() {
             @Override
@@ -163,27 +170,28 @@
         });
         final ArrayList<View> sharedElementSnapshots = createSnapshots(mExitSharedElementBundle,
                 mSharedElementNames);
-        getDecor().getViewTreeObserver()
+        decorView.getViewTreeObserver()
                 .addOnPreDrawListener(new ViewTreeObserver.OnPreDrawListener() {
                     @Override
                     public boolean onPreDraw() {
-                        getDecor().getViewTreeObserver().removeOnPreDrawListener(this);
+                        decorView.getViewTreeObserver().removeOnPreDrawListener(this);
                         setSharedElementState(mExitSharedElementBundle, sharedElementSnapshots);
                         return true;
                     }
                 });
         setGhostVisibility(View.INVISIBLE);
         scheduleGhostVisibilityChange(View.INVISIBLE);
-        TransitionManager.beginDelayedTransition(getDecor(), transition);
+        mListener.onSharedElementEnd(mSharedElementNames, mSharedElements, sharedElementSnapshots);
+        TransitionManager.beginDelayedTransition(decorView, transition);
         scheduleGhostVisibilityChange(View.VISIBLE);
         setGhostVisibility(View.VISIBLE);
-        getDecor().invalidate();
+        decorView.invalidate();
     }
 
     private void hideSharedElements() {
         moveSharedElementsFromOverlay();
         if (!mIsHidden) {
-            setTransitionAlpha(mSharedElements, 0);
+            hideViews(mSharedElements);
         }
         mSharedElementsHidden = true;
         finishIfNecessary();
@@ -192,8 +200,9 @@
     public void startExit() {
         if (!mIsExitStarted) {
             mIsExitStarted = true;
-            if (getDecor() != null) {
-                getDecor().suppressLayout(true);
+            ViewGroup decorView = getDecor();
+            if (decorView != null) {
+                decorView.suppressLayout(true);
             }
             moveSharedElementsToOverlay();
             startTransition(new Runnable() {
@@ -208,8 +217,9 @@
     public void startExit(int resultCode, Intent data) {
         if (!mIsExitStarted) {
             mIsExitStarted = true;
-            if (getDecor() != null) {
-                getDecor().suppressLayout(true);
+            ViewGroup decorView = getDecor();
+            if (decorView != null) {
+                decorView.suppressLayout(true);
             }
             mHandler = new Handler() {
                 @Override
@@ -220,11 +230,8 @@
             };
             delayCancel();
             moveSharedElementsToOverlay();
-            if (getDecor().getBackground() == null) {
-                ColorDrawable black = new ColorDrawable(0xFF000000);
-                black.setAlpha(0);
-                getWindow().setBackgroundDrawable(black);
-                black.setAlpha(255);
+            if (decorView != null && decorView.getBackground() == null) {
+                getWindow().setBackgroundDrawable(new ColorDrawable(Color.BLACK));
             }
             ActivityOptions options = ActivityOptions.makeSceneTransitionAnimation(mActivity, this,
                     mAllSharedElementNames, resultCode, data);
@@ -247,8 +254,9 @@
 
     private void startExitTransition() {
         Transition transition = getExitTransition();
-        if (transition != null) {
-            TransitionManager.beginDelayedTransition(getDecor(), transition);
+        ViewGroup decorView = getDecor();
+        if (transition != null && decorView != null && mTransitioningViews != null) {
+            TransitionManager.beginDelayedTransition(decorView, transition);
             mTransitioningViews.get(0).invalidate();
         } else {
             transitionStarted();
@@ -260,6 +268,8 @@
             ViewGroup decor = getDecor();
             Drawable background;
             if (decor != null && (background = decor.getBackground()) != null) {
+                background = background.mutate();
+                getWindow().setBackgroundDrawable(background);
                 mBackgroundAnimator = ObjectAnimator.ofInt(background, "alpha", 0);
                 mBackgroundAnimator.addListener(new AnimatorListenerAdapter() {
                     @Override
@@ -281,19 +291,20 @@
 
     private Transition getExitTransition() {
         Transition viewsTransition = null;
-        if (!mTransitioningViews.isEmpty()) {
+        if (mTransitioningViews != null && !mTransitioningViews.isEmpty()) {
             viewsTransition = configureTransition(getViewsTransition(), true);
         }
         if (viewsTransition == null) {
             exitTransitionComplete();
         } else {
+            final ArrayList<View> transitioningViews = mTransitioningViews;
             viewsTransition.addListener(new ContinueTransitionListener() {
                 @Override
                 public void onTransitionEnd(Transition transition) {
                     transition.removeListener(this);
                     exitTransitionComplete();
-                    if (mIsHidden) {
-                        setTransitionAlpha(mTransitioningViews, 1);
+                    if (mIsHidden && transitioningViews != null) {
+                        showViews(transitioningViews, true);
                     }
                     if (mSharedElementBundle != null) {
                         delayCancel();
@@ -320,7 +331,7 @@
                     transition.removeListener(this);
                     sharedElementTransitionComplete();
                     if (mIsHidden) {
-                        setTransitionAlpha(mSharedElements, 1);
+                        showViews(mSharedElements, true);
                     }
                 }
             });
@@ -334,13 +345,14 @@
         Transition viewsTransition = getExitTransition();
 
         Transition transition = mergeTransitions(sharedElementTransition, viewsTransition);
-        if (transition != null) {
+        ViewGroup decorView = getDecor();
+        if (transition != null && decorView != null) {
             setGhostVisibility(View.INVISIBLE);
             scheduleGhostVisibilityChange(View.INVISIBLE);
-            TransitionManager.beginDelayedTransition(getDecor(), transition);
+            TransitionManager.beginDelayedTransition(decorView, transition);
             scheduleGhostVisibilityChange(View.VISIBLE);
             setGhostVisibility(View.VISIBLE);
-            getDecor().invalidate();
+            decorView.invalidate();
         } else {
             transitionStarted();
         }
@@ -389,8 +401,9 @@
                 mExitNotified = true;
                 mResultReceiver.send(MSG_EXIT_TRANSITION_COMPLETE, null);
                 mResultReceiver = null; // done talking
-                if (!mIsReturning && getDecor() != null) {
-                    getDecor().suppressLayout(false);
+                ViewGroup decorView = getDecor();
+                if (!mIsReturning && decorView != null) {
+                    decorView.suppressLayout(false);
                 }
                 finishIfNecessary();
             }
diff --git a/core/java/android/app/Fragment.java b/core/java/android/app/Fragment.java
index 2ff3d57..a95abab 100644
--- a/core/java/android/app/Fragment.java
+++ b/core/java/android/app/Fragment.java
@@ -23,10 +23,14 @@
 import android.content.Intent;
 import android.content.res.Configuration;
 import android.content.res.Resources;
+import android.content.res.TypedArray;
 import android.os.Build;
 import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
+import android.transition.Transition;
+import android.transition.TransitionInflater;
+import android.transition.TransitionSet;
 import android.util.AndroidRuntimeException;
 import android.util.ArrayMap;
 import android.util.AttributeSet;
@@ -58,11 +62,11 @@
     final boolean mRetainInstance;
     final boolean mDetached;
     final Bundle mArguments;
-    
+
     Bundle mSavedFragmentState;
-    
+
     Fragment mInstance;
-    
+
     public FragmentState(Fragment frag) {
         mClassName = frag.getClass().getName();
         mIndex = frag.mIndex;
@@ -74,7 +78,7 @@
         mDetached = frag.mDetached;
         mArguments = frag.mArguments;
     }
-    
+
     public FragmentState(Parcel in) {
         mClassName = in.readString();
         mIndex = in.readInt();
@@ -87,18 +91,18 @@
         mArguments = in.readBundle();
         mSavedFragmentState = in.readBundle();
     }
-    
+
     public Fragment instantiate(Activity activity, Fragment parent) {
         if (mInstance != null) {
             return mInstance;
         }
-        
+
         if (mArguments != null) {
             mArguments.setClassLoader(activity.getClassLoader());
         }
-        
+
         mInstance = Fragment.instantiate(activity, mClassName, mArguments);
-        
+
         if (mSavedFragmentState != null) {
             mSavedFragmentState.setClassLoader(activity.getClassLoader());
             mInstance.mSavedFragmentState = mSavedFragmentState;
@@ -117,7 +121,7 @@
 
         return mInstance;
     }
-    
+
     public int describeContents() {
         return 0;
     }
@@ -134,13 +138,13 @@
         dest.writeBundle(mArguments);
         dest.writeBundle(mSavedFragmentState);
     }
-    
+
     public static final Parcelable.Creator<FragmentState> CREATOR
             = new Parcelable.Creator<FragmentState>() {
         public FragmentState createFromParcel(Parcel in) {
             return new FragmentState(in);
         }
-        
+
         public FragmentState[] newArray(int size) {
             return new FragmentState[size];
         }
@@ -162,11 +166,12 @@
  * activity: if the activity is stopped, no fragments inside of it can be
  * started; when the activity is destroyed, all fragments will be destroyed.
  *
- * <p>All subclasses of Fragment must include a public empty constructor.
+ * <p>All subclasses of Fragment must include a public no-argument constructor.
  * The framework will often re-instantiate a fragment class when needed,
  * in particular during state restore, and needs to be able to find this
- * constructor to instantiate it.  If the empty constructor is not available,
- * a runtime exception will occur in some cases during state restore.
+ * constructor to instantiate it.  If the no-argument constructor is not
+ * available, a runtime exception will occur in some cases during state
+ * restore.
  *
  * <p>Topics covered here:
  * <ol>
@@ -299,17 +304,17 @@
  * how you can determine if a fragment placed in a container is no longer
  * running in a layout with that container and avoid creating its view hierarchy
  * in that case.)
- * 
+ *
  * <p>The attributes of the &lt;fragment&gt; tag are used to control the
  * LayoutParams provided when attaching the fragment's view to the parent
  * container.  They can also be parsed by the fragment in {@link #onInflate}
  * as parameters.
- * 
+ *
  * <p>The fragment being instantiated must have some kind of unique identifier
  * so that it can be re-associated with a previous instance if the parent
  * activity needs to be destroyed and recreated.  This can be provided these
  * ways:
- * 
+ *
  * <ul>
  * <li>If nothing is explicitly supplied, the view ID of the container will
  * be used.
@@ -318,7 +323,7 @@
  * <li><code>android:id</code> can be used in &lt;fragment&gt; to provide
  * a specific identifier for the fragment.
  * </ul>
- * 
+ *
  * <a name="BackStack"></a>
  * <h3>Back Stack</h3>
  *
@@ -347,7 +352,7 @@
 public class Fragment implements ComponentCallbacks2, OnCreateContextMenuListener {
     private static final ArrayMap<String, Class<?>> sClassMap =
             new ArrayMap<String, Class<?>>();
-    
+
     static final int INVALID_STATE = -1;   // Invalid state used as a null value.
     static final int INITIALIZING = 0;     // Not yet created.
     static final int CREATED = 1;          // Created.
@@ -355,9 +360,11 @@
     static final int STOPPED = 3;          // Fully created, not started.
     static final int STARTED = 4;          // Created and started, not resumed.
     static final int RESUMED = 5;          // Created started and resumed.
-    
+
+    private static final Transition USE_DEFAULT_TRANSITION = new TransitionSet();
+
     int mState = INITIALIZING;
-    
+
     // Non-null if the fragment's view hierarchy is currently animating away,
     // meaning we need to wait a bit on completely destroying it.  This is the
     // animation that is running.
@@ -370,13 +377,13 @@
     // When instantiated from saved state, this is the saved state.
     Bundle mSavedFragmentState;
     SparseArray<Parcelable> mSavedViewState;
-    
+
     // Index into active fragment array.
     int mIndex = -1;
-    
+
     // Internal unique name for this fragment;
     String mWho;
-    
+
     // Construction arguments;
     Bundle mArguments;
 
@@ -391,25 +398,25 @@
 
     // True if the fragment is in the list of added fragments.
     boolean mAdded;
-    
+
     // If set this fragment is being removed from its activity.
     boolean mRemoving;
 
     // True if the fragment is in the resumed state.
     boolean mResumed;
-    
+
     // Set to true if this fragment was instantiated from a layout file.
     boolean mFromLayout;
-    
+
     // Set to true when the view has actually been inflated in its layout.
     boolean mInLayout;
 
     // True if this fragment has been restored from previously saved state.
     boolean mRestored;
-    
+
     // Number of active back stack entries this fragment is in.
     int mBackStackNesting;
-    
+
     // The fragment manager we are associated with.  Set as soon as the
     // fragment is used in a transaction; cleared after it has been removed
     // from all transactions.
@@ -428,29 +435,29 @@
     // was dynamically added to the view hierarchy, or the ID supplied in
     // layout.
     int mFragmentId;
-    
+
     // When a fragment is being dynamically added to the view hierarchy, this
     // is the identifier of the parent container it is being added to.
     int mContainerId;
-    
+
     // The optional named tag for this fragment -- usually used to find
     // fragments that are not part of the layout.
     String mTag;
-    
+
     // Set to true when the app has requested that this fragment be hidden
     // from the user.
     boolean mHidden;
-    
+
     // Set to true when the app has requested that this fragment be detached.
     boolean mDetached;
 
     // If set this fragment would like its instance retained across
     // configuration changes.
     boolean mRetainInstance;
-    
+
     // If set this fragment is being retained across the current config change.
     boolean mRetaining;
-    
+
     // If set this fragment has menu items to contribute.
     boolean mHasMenu;
 
@@ -459,16 +466,16 @@
 
     // Used to verify that subclasses call through to super class.
     boolean mCalled;
-    
+
     // If app has requested a specific animation, this is the one to use.
     int mNextAnim;
-    
+
     // The parent container of the fragment after dynamically added to UI.
     ViewGroup mContainer;
-    
+
     // The View generated for this fragment.
     View mView;
-    
+
     // Whether this fragment should defer starting until after other fragments
     // have been started and their loaders are finished.
     boolean mDeferStart;
@@ -479,7 +486,19 @@
     LoaderManagerImpl mLoaderManager;
     boolean mLoadersStarted;
     boolean mCheckedForLoaderManager;
-    
+
+    private Transition mEnterTransition = null;
+    private Transition mReturnTransition = USE_DEFAULT_TRANSITION;
+    private Transition mExitTransition = null;
+    private Transition mReenterTransition = USE_DEFAULT_TRANSITION;
+    private Transition mSharedElementEnterTransition = null;
+    private Transition mSharedElementReturnTransition = USE_DEFAULT_TRANSITION;
+    private Boolean mAllowReturnTransitionOverlap;
+    private Boolean mAllowEnterTransitionOverlap;
+
+    SharedElementCallback mEnterTransitionCallback = SharedElementCallback.NULL_CALLBACK;
+    SharedElementCallback mExitTransitionCallback = SharedElementCallback.NULL_CALLBACK;
+
     /**
      * State information that has been retrieved from a fragment instance
      * through {@link FragmentManager#saveFragmentInstanceState(Fragment)
@@ -543,7 +562,7 @@
      * will not be called when the fragment is re-instantiated; instead,
      * arguments can be supplied by the caller with {@link #setArguments}
      * and later retrieved by the Fragment with {@link #getArguments}.
-     * 
+     *
      * <p>Applications should generally not implement a constructor.  The
      * first place application code an run where the fragment is ready to
      * be used is in {@link #onAttach(Activity)}, the point where the fragment
@@ -609,7 +628,7 @@
                     + " empty constructor that is public", e);
         }
     }
-    
+
     final void restoreViewState(Bundle savedInstanceState) {
         if (mSavedViewState != null) {
             mView.restoreHierarchyState(mSavedViewState);
@@ -649,7 +668,7 @@
     @Override final public int hashCode() {
         return super.hashCode();
     }
-    
+
     @Override
     public String toString() {
         StringBuilder sb = new StringBuilder(128);
@@ -669,7 +688,7 @@
         sb.append('}');
         return sb.toString();
     }
-    
+
     /**
      * Return the identifier this fragment is known by.  This is either
      * the android:id value supplied in a layout or the container view ID
@@ -678,14 +697,14 @@
     final public int getId() {
         return mFragmentId;
     }
-    
+
     /**
      * Get the tag name of the fragment, if specified.
      */
     final public String getTag() {
         return mTag;
     }
-    
+
     /**
      * Supply the construction arguments for this fragment.  This can only
      * be called before the fragment has been attached to its activity; that
@@ -760,7 +779,7 @@
     final public Activity getActivity() {
         return mActivity;
     }
-    
+
     /**
      * Return <code>getActivity().getResources()</code>.
      */
@@ -770,7 +789,7 @@
         }
         return mActivity.getResources();
     }
-    
+
     /**
      * Return a localized, styled CharSequence from the application's package's
      * default string table.
@@ -870,7 +889,7 @@
     final public boolean isRemoving() {
         return mRemoving;
     }
-    
+
     /**
      * Return true if the layout is included as part of an activity view
      * hierarchy via the &lt;fragment&gt; tag.  This will always be true when
@@ -889,7 +908,7 @@
     final public boolean isResumed() {
         return mResumed;
     }
-    
+
     /**
      * Return true if the fragment is currently visible to the user.  This means
      * it: (1) has been added, (2) has its view attached to the window, and 
@@ -899,7 +918,7 @@
         return isAdded() && !isHidden() && mView != null
                 && mView.getWindowToken() != null && mView.getVisibility() == View.VISIBLE;
     }
-    
+
     /**
      * Return true if the fragment has been hidden.  By default fragments
      * are shown.  You can find out about changes to this state with
@@ -910,7 +929,7 @@
     final public boolean isHidden() {
         return mHidden;
     }
-    
+
     /**
      * Called when the hidden state (as returned by {@link #isHidden()} of
      * the fragment has changed.  Fragments start out not hidden; this will
@@ -920,7 +939,7 @@
      */
     public void onHiddenChanged(boolean hidden) {
     }
-    
+
     /**
      * Control whether a fragment instance is retained across Activity
      * re-creation (such as from a configuration change).  This can only
@@ -942,16 +961,16 @@
         }
         mRetainInstance = retain;
     }
-    
+
     final public boolean getRetainInstance() {
         return mRetainInstance;
     }
-    
+
     /**
      * Report that this fragment would like to participate in populating
      * the options menu by receiving a call to {@link #onCreateOptionsMenu}
      * and related methods.
-     * 
+     *
      * @param hasMenu If true, the fragment has menu items to contribute.
      */
     public void setHasOptionsMenu(boolean hasMenu) {
@@ -1034,7 +1053,7 @@
     public void startActivity(Intent intent) {
         startActivity(intent, null);
     }
-    
+
     /**
      * Call {@link Activity#startActivity(Intent, Bundle)} from the fragment's
      * containing Activity.
@@ -1081,13 +1100,13 @@
             mActivity.startActivityFromFragment(this, intent, requestCode, options);
         }
     }
-    
+
     /**
      * Receive the result from a previous call to
      * {@link #startActivityForResult(Intent, int)}.  This follows the
      * related Activity API as described there in
      * {@link Activity#onActivityResult(int, int, Intent)}.
-     * 
+     *
      * @param requestCode The integer request code originally supplied to
      *                    startActivityForResult(), allowing you to identify who this
      *                    result came from.
@@ -1098,7 +1117,7 @@
      */
     public void onActivityResult(int requestCode, int resultCode, Intent data) {
     }
-    
+
     /**
      * @hide Hack so that DialogFragment can make its Dialog before creating
      * its views, and the view construction can use the dialog's context for
@@ -1115,7 +1134,7 @@
             return mActivity.getLayoutInflater();
         }
     }
-    
+
     /**
      * @deprecated Use {@link #onInflate(Activity, AttributeSet, Bundle)} instead.
      */
@@ -1131,7 +1150,7 @@
      * tag in a layout file.  Note this is <em>before</em> the fragment's
      * {@link #onAttach(Activity)} has been called; all you should do here is
      * parse the attributes and save them away.
-     * 
+     *
      * <p>This is called every time the fragment is inflated, even if it is
      * being inflated into a new instance with saved state.  It typically makes
      * sense to re-parse the parameters each time, to allow them to change with
@@ -1169,8 +1188,33 @@
     public void onInflate(Activity activity, AttributeSet attrs, Bundle savedInstanceState) {
         onInflate(attrs, savedInstanceState);
         mCalled = true;
+
+        TypedArray a = activity.obtainStyledAttributes(attrs,
+                com.android.internal.R.styleable.Fragment);
+        mEnterTransition = loadTransition(activity, a, mEnterTransition, null,
+                com.android.internal.R.styleable.Fragment_fragmentEnterTransition);
+        mReturnTransition = loadTransition(activity, a, mReturnTransition, USE_DEFAULT_TRANSITION,
+                com.android.internal.R.styleable.Fragment_fragmentReturnTransition);
+        mExitTransition = loadTransition(activity, a, mExitTransition, null,
+                com.android.internal.R.styleable.Fragment_fragmentExitTransition);
+        mReenterTransition = loadTransition(activity, a, mReenterTransition, USE_DEFAULT_TRANSITION,
+                com.android.internal.R.styleable.Fragment_fragmentReenterTransition);
+        mSharedElementEnterTransition = loadTransition(activity, a, mSharedElementEnterTransition,
+                null, com.android.internal.R.styleable.Fragment_fragmentSharedElementEnterTransition);
+        mSharedElementReturnTransition = loadTransition(activity, a, mSharedElementReturnTransition,
+                USE_DEFAULT_TRANSITION,
+                com.android.internal.R.styleable.Fragment_fragmentSharedElementReturnTransition);
+        if (mAllowEnterTransitionOverlap == null) {
+            mAllowEnterTransitionOverlap = a.getBoolean(
+                    com.android.internal.R.styleable.Fragment_fragmentAllowEnterTransitionOverlap, true);
+        }
+        if (mAllowReturnTransitionOverlap == null) {
+            mAllowReturnTransitionOverlap = a.getBoolean(
+                    com.android.internal.R.styleable.Fragment_fragmentAllowReturnTransitionOverlap, true);
+        }
+        a.recycle();
     }
-    
+
     /**
      * Called when a fragment is first attached to its activity.
      * {@link #onCreate(Bundle)} will be called after this.
@@ -1178,25 +1222,25 @@
     public void onAttach(Activity activity) {
         mCalled = true;
     }
-    
+
     /**
      * Called when a fragment loads an animation.
      */
     public Animator onCreateAnimator(int transit, boolean enter, int nextAnim) {
         return null;
     }
-    
+
     /**
      * Called to do initial creation of a fragment.  This is called after
      * {@link #onAttach(Activity)} and before
      * {@link #onCreateView(LayoutInflater, ViewGroup, Bundle)}.
-     * 
+     *
      * <p>Note that this can be called while the fragment's activity is
      * still in the process of being created.  As such, you can not rely
      * on things like the activity's content view hierarchy being initialized
      * at this point.  If you want to do work once the activity itself is
      * created, see {@link #onActivityCreated(Bundle)}.
-     * 
+     *
      * @param savedInstanceState If the fragment is being re-created from
      * a previous saved state, this is the state.
      */
@@ -1209,10 +1253,10 @@
      * This is optional, and non-graphical fragments can return null (which
      * is the default implementation).  This will be called between
      * {@link #onCreate(Bundle)} and {@link #onActivityCreated(Bundle)}.
-     * 
+     *
      * <p>If you return a View from here, you will later be called in
      * {@link #onDestroyView} when the view is being released.
-     * 
+     *
      * @param inflater The LayoutInflater object that can be used to inflate
      * any views in the fragment,
      * @param container If non-null, this is the parent view that the fragment's
@@ -1220,7 +1264,7 @@
      * but this can be used to generate the LayoutParams of the view.
      * @param savedInstanceState If non-null, this fragment is being re-constructed
      * from a previous saved state as given here.
-     * 
+     *
      * @return Return the View for the fragment's UI, or null.
      */
     @Nullable
@@ -1241,18 +1285,18 @@
      */
     public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
     }
-    
+
     /**
      * Get the root view for the fragment's layout (the one returned by {@link #onCreateView}),
      * if provided.
-     * 
+     *
      * @return The fragment's root view, or null if it has no layout.
      */
     @Nullable
     public View getView() {
         return mView;
     }
-    
+
     /**
      * Called when the fragment's activity has been created and this
      * fragment's view hierarchy instantiated.  It can be used to do final
@@ -1292,7 +1336,7 @@
      */
     public void onStart() {
         mCalled = true;
-        
+
         if (!mLoadersStarted) {
             mLoadersStarted = true;
             if (!mCheckedForLoaderManager) {
@@ -1304,7 +1348,7 @@
             }
         }
     }
-    
+
     /**
      * Called when the fragment is visible to the user and actively running.
      * This is generally
@@ -1314,7 +1358,7 @@
     public void onResume() {
         mCalled = true;
     }
-    
+
     /**
      * Called to ask the fragment to save its current dynamic state, so it
      * can later be reconstructed in a new instance of its process is
@@ -1336,11 +1380,11 @@
      */
     public void onSaveInstanceState(Bundle outState) {
     }
-    
+
     public void onConfigurationChanged(Configuration newConfig) {
         mCalled = true;
     }
-    
+
     /**
      * Called when the Fragment is no longer resumed.  This is generally
      * tied to {@link Activity#onPause() Activity.onPause} of the containing
@@ -1349,7 +1393,7 @@
     public void onPause() {
         mCalled = true;
     }
-    
+
     /**
      * Called when the Fragment is no longer started.  This is generally
      * tied to {@link Activity#onStop() Activity.onStop} of the containing
@@ -1358,11 +1402,11 @@
     public void onStop() {
         mCalled = true;
     }
-    
+
     public void onLowMemory() {
         mCalled = true;
     }
-    
+
     public void onTrimMemory(int level) {
         mCalled = true;
     }
@@ -1379,7 +1423,7 @@
     public void onDestroyView() {
         mCalled = true;
     }
-    
+
     /**
      * Called when the fragment is no longer in use.  This is called
      * after {@link #onStop()} and before {@link #onDetach()}.
@@ -1434,16 +1478,16 @@
     public void onDetach() {
         mCalled = true;
     }
-    
+
     /**
      * Initialize the contents of the Activity's standard options menu.  You
      * should place your menu items in to <var>menu</var>.  For this method
      * to be called, you must have first called {@link #setHasOptionsMenu}.  See
      * {@link Activity#onCreateOptionsMenu(Menu) Activity.onCreateOptionsMenu}
      * for more information.
-     * 
+     *
      * @param menu The options menu in which you place your items.
-     * 
+     *
      * @see #setHasOptionsMenu
      * @see #onPrepareOptionsMenu
      * @see #onOptionsItemSelected
@@ -1458,10 +1502,10 @@
      * dynamically modify the contents.  See
      * {@link Activity#onPrepareOptionsMenu(Menu) Activity.onPrepareOptionsMenu}
      * for more information.
-     * 
+     *
      * @param menu The options menu as last shown or first initialized by
      *             onCreateOptionsMenu().
-     * 
+     *
      * @see #setHasOptionsMenu
      * @see #onCreateOptionsMenu
      */
@@ -1477,7 +1521,7 @@
      */
     public void onDestroyOptionsMenu() {
     }
-    
+
     /**
      * This hook is called whenever an item in your options menu is selected.
      * The default implementation simply returns false to have the normal
@@ -1485,15 +1529,15 @@
      * its Handler as appropriate).  You can use this method for any items
      * for which you would like to do processing without those other
      * facilities.
-     * 
+     *
      * <p>Derived classes should call through to the base class for it to
      * perform the default menu handling.
-     * 
+     *
      * @param item The menu item that was selected.
-     * 
+     *
      * @return boolean Return false to allow normal menu processing to
      *         proceed, true to consume it here.
-     * 
+     *
      * @see #onCreateOptionsMenu
      */
     public boolean onOptionsItemSelected(MenuItem item) {
@@ -1503,13 +1547,13 @@
     /**
      * This hook is called whenever the options menu is being closed (either by the user canceling
      * the menu with the back/menu button, or when an item is selected).
-     *  
+     *
      * @param menu The options menu as last shown or first initialized by
      *             onCreateOptionsMenu().
      */
     public void onOptionsMenuClosed(Menu menu) {
     }
-    
+
     /**
      * Called when a context menu for the {@code view} is about to be shown.
      * Unlike {@link #onCreateOptionsMenu}, this will be called every
@@ -1537,25 +1581,25 @@
      * {@link OnCreateContextMenuListener} on the view to this fragment, so
      * {@link #onCreateContextMenu(ContextMenu, View, ContextMenuInfo)} will be
      * called when it is time to show the context menu.
-     * 
+     *
      * @see #unregisterForContextMenu(View)
      * @param view The view that should show a context menu.
      */
     public void registerForContextMenu(View view) {
         view.setOnCreateContextMenuListener(this);
     }
-    
+
     /**
      * Prevents a context menu to be shown for the given view. This method will
      * remove the {@link OnCreateContextMenuListener} on the view.
-     * 
+     *
      * @see #registerForContextMenu(View)
      * @param view The view that should stop showing a context menu.
      */
     public void unregisterForContextMenu(View view) {
         view.setOnCreateContextMenuListener(null);
     }
-    
+
     /**
      * This hook is called whenever an item in a context menu is selected. The
      * default implementation simply returns false to have the normal processing
@@ -1568,7 +1612,7 @@
      * <p>
      * Derived classes should call through to the base class for it to perform
      * the default menu handling.
-     * 
+     *
      * @param item The context menu item that was selected.
      * @return boolean Return false to allow normal context menu processing to
      *         proceed, true to consume it here.
@@ -1576,7 +1620,298 @@
     public boolean onContextItemSelected(MenuItem item) {
         return false;
     }
-    
+
+    /**
+     * When custom transitions are used with Fragments, the enter transition callback
+     * is called when this Fragment is attached or detached when not popping the back stack.
+     *
+     * @param callback Used to manipulate the shared element transitions on this Fragment
+     *                 when added not as a pop from the back stack.
+     */
+    public void setEnterSharedElementCallback(SharedElementCallback callback) {
+        if (callback == null) {
+            callback = SharedElementCallback.NULL_CALLBACK;
+        }
+        mEnterTransitionCallback = callback;
+    }
+
+    /**
+     * @hide
+     */
+    public void setEnterSharedElementTransitionCallback(SharedElementCallback callback) {
+        setEnterSharedElementCallback(callback);
+    }
+
+    /**
+     * When custom transitions are used with Fragments, the exit transition callback
+     * is called when this Fragment is attached or detached when popping the back stack.
+     *
+     * @param callback Used to manipulate the shared element transitions on this Fragment
+     *                 when added as a pop from the back stack.
+     */
+    public void setExitSharedElementCallback(SharedElementCallback callback) {
+        if (callback == null) {
+            callback = SharedElementCallback.NULL_CALLBACK;
+        }
+        mExitTransitionCallback = callback;
+    }
+
+    /**
+     * @hide
+     */
+    public void setExitSharedElementTransitionCallback(SharedElementCallback callback) {
+        setExitSharedElementCallback(callback);
+    }
+
+    /**
+     * Sets the Transition that will be used to move Views into the initial scene. The entering
+     * Views will be those that are regular Views or ViewGroups that have
+     * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as entering is governed by changing visibility from
+     * {@link View#INVISIBLE} to {@link View#VISIBLE}. If <code>transition</code> is null,
+     * entering Views will remain unaffected.
+     *
+     * @param transition The Transition to use to move Views into the initial Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentEnterTransition
+     */
+    public void setEnterTransition(Transition transition) {
+        mEnterTransition = transition;
+    }
+
+    /**
+     * Returns the Transition that will be used to move Views into the initial scene. The entering
+     * Views will be those that are regular Views or ViewGroups that have
+     * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as entering is governed by changing visibility from
+     * {@link View#INVISIBLE} to {@link View#VISIBLE}.
+     *
+     * @return the Transition to use to move Views into the initial Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentEnterTransition
+     */
+    public Transition getEnterTransition() {
+        return mEnterTransition;
+    }
+
+    /**
+     * Sets the Transition that will be used to move Views out of the scene when the Fragment is
+     * preparing to be removed, hidden, or detached because of popping the back stack. The exiting
+     * Views will be those that are regular Views or ViewGroups that have
+     * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as entering is governed by changing visibility from
+     * {@link View#VISIBLE} to {@link View#INVISIBLE}. If <code>transition</code> is null,
+     * entering Views will remain unaffected. If nothing is set, the default will be to
+     * use the same value as set in {@link #setEnterTransition(android.transition.Transition)}.
+     *
+     * @param transition The Transition to use to move Views out of the Scene when the Fragment
+     *                   is preparing to close.
+     * @attr ref android.R.styleable#Fragment_fragmentExitTransition
+     */
+    public void setReturnTransition(Transition transition) {
+        mReturnTransition = transition;
+    }
+
+    /**
+     * Returns the Transition that will be used to move Views out of the scene when the Fragment is
+     * preparing to be removed, hidden, or detached because of popping the back stack. The exiting
+     * Views will be those that are regular Views or ViewGroups that have
+     * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as entering is governed by changing visibility from
+     * {@link View#VISIBLE} to {@link View#INVISIBLE}. If <code>transition</code> is null,
+     * entering Views will remain unaffected.
+     *
+     * @return the Transition to use to move Views out of the Scene when the Fragment
+     *         is preparing to close.
+     * @attr ref android.R.styleable#Fragment_fragmentExitTransition
+     */
+    public Transition getReturnTransition() {
+        return mReturnTransition == USE_DEFAULT_TRANSITION ? getEnterTransition()
+                : mReturnTransition;
+    }
+
+    /**
+     * Sets the Transition that will be used to move Views out of the scene when the
+     * fragment is removed, hidden, or detached when not popping the back stack.
+     * The exiting Views will be those that are regular Views or ViewGroups that
+     * have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as exiting is governed by changing visibility
+     * from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null, the views will
+     * remain unaffected.
+     *
+     * @param transition The Transition to use to move Views out of the Scene when the Fragment
+     *                   is being closed not due to popping the back stack.
+     * @attr ref android.R.styleable#Fragment_fragmentExitTransition
+     */
+    public void setExitTransition(Transition transition) {
+        mExitTransition = transition;
+    }
+
+    /**
+     * Returns the Transition that will be used to move Views out of the scene when the
+     * fragment is removed, hidden, or detached when not popping the back stack.
+     * The exiting Views will be those that are regular Views or ViewGroups that
+     * have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
+     * {@link android.transition.Visibility} as exiting is governed by changing visibility
+     * from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null, the views will
+     * remain unaffected.
+     *
+     * @return the Transition to use to move Views out of the Scene when the Fragment
+     *         is being closed not due to popping the back stack.
+     * @attr ref android.R.styleable#Fragment_fragmentExitTransition
+     */
+    public Transition getExitTransition() {
+        return mExitTransition;
+    }
+
+    /**
+     * Sets the Transition that will be used to move Views in to the scene when returning due
+     * to popping a back stack. The entering Views will be those that are regular Views
+     * or ViewGroups that have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions
+     * will extend {@link android.transition.Visibility} as exiting is governed by changing
+     * visibility from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null,
+     * the views will remain unaffected. If nothing is set, the default will be to use the same
+     * transition as {@link #setExitTransition(android.transition.Transition)}.
+     *
+     * @param transition The Transition to use to move Views into the scene when reentering from a
+     *                   previously-started Activity.
+     * @attr ref android.R.styleable#Fragment_fragmentReenterTransition
+     */
+    public void setReenterTransition(Transition transition) {
+        mReenterTransition = transition;
+    }
+
+    /**
+     * Returns the Transition that will be used to move Views in to the scene when returning due
+     * to popping a back stack. The entering Views will be those that are regular Views
+     * or ViewGroups that have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions
+     * will extend {@link android.transition.Visibility} as exiting is governed by changing
+     * visibility from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null,
+     * the views will remain unaffected. If nothing is set, the default will be to use the same
+     * transition as {@link #setExitTransition(android.transition.Transition)}.
+     *
+     * @return the Transition to use to move Views into the scene when reentering from a
+     *                   previously-started Activity.
+     * @attr ref android.R.styleable#Fragment_fragmentReenterTransition
+     */
+    public Transition getReenterTransition() {
+        return mReenterTransition == USE_DEFAULT_TRANSITION ? getExitTransition()
+                : mReenterTransition;
+    }
+
+    /**
+     * Sets the Transition that will be used for shared elements transferred into the content
+     * Scene. Typical Transitions will affect size and location, such as
+     * {@link android.transition.ChangeBounds}. A null
+     * value will cause transferred shared elements to blink to the final position.
+     *
+     * @param transition The Transition to use for shared elements transferred into the content
+     *                   Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentSharedElementEnterTransition
+     */
+    public void setSharedElementEnterTransition(Transition transition) {
+        mSharedElementEnterTransition = transition;
+    }
+
+    /**
+     * Returns the Transition that will be used for shared elements transferred into the content
+     * Scene. Typical Transitions will affect size and location, such as
+     * {@link android.transition.ChangeBounds}. A null
+     * value will cause transferred shared elements to blink to the final position.
+     *
+     * @return The Transition to use for shared elements transferred into the content
+     *                   Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentSharedElementEnterTransition
+     */
+    public Transition getSharedElementEnterTransition() {
+        return mSharedElementEnterTransition;
+    }
+
+    /**
+     * Sets the Transition that will be used for shared elements transferred back during a
+     * pop of the back stack. This Transition acts in the leaving Fragment.
+     * Typical Transitions will affect size and location, such as
+     * {@link android.transition.ChangeBounds}. A null
+     * value will cause transferred shared elements to blink to the final position.
+     * If no value is set, the default will be to use the same value as
+     * {@link #setSharedElementEnterTransition(android.transition.Transition)}.
+     *
+     * @param transition The Transition to use for shared elements transferred out of the content
+     *                   Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentSharedElementReturnTransition
+     */
+    public void setSharedElementReturnTransition(Transition transition) {
+        mSharedElementReturnTransition = transition;
+    }
+
+    /**
+     * Return the Transition that will be used for shared elements transferred back during a
+     * pop of the back stack. This Transition acts in the leaving Fragment.
+     * Typical Transitions will affect size and location, such as
+     * {@link android.transition.ChangeBounds}. A null
+     * value will cause transferred shared elements to blink to the final position.
+     * If no value is set, the default will be to use the same value as
+     * {@link #setSharedElementEnterTransition(android.transition.Transition)}.
+     *
+     * @return The Transition to use for shared elements transferred out of the content
+     *                   Scene.
+     * @attr ref android.R.styleable#Fragment_fragmentSharedElementReturnTransition
+     */
+    public Transition getSharedElementReturnTransition() {
+        return mSharedElementReturnTransition == USE_DEFAULT_TRANSITION ?
+                getSharedElementEnterTransition() : mSharedElementReturnTransition;
+    }
+
+    /**
+     * Sets whether the the exit transition and enter transition overlap or not.
+     * When true, the enter transition will start as soon as possible. When false, the
+     * enter transition will wait until the exit transition completes before starting.
+     *
+     * @param allow true to start the enter transition when possible or false to
+     *              wait until the exiting transition completes.
+     * @attr ref android.R.styleable#Fragment_fragmentAllowEnterTransitionOverlap
+     */
+    public void setAllowEnterTransitionOverlap(boolean allow) {
+        mAllowEnterTransitionOverlap = allow;
+    }
+
+    /**
+     * Returns whether the the exit transition and enter transition overlap or not.
+     * When true, the enter transition will start as soon as possible. When false, the
+     * enter transition will wait until the exit transition completes before starting.
+     *
+     * @return true when the enter transition should start as soon as possible or false to
+     * when it should wait until the exiting transition completes.
+     * @attr ref android.R.styleable#Fragment_fragmentAllowEnterTransitionOverlap
+     */
+    public boolean getAllowEnterTransitionOverlap() {
+        return (mAllowEnterTransitionOverlap == null) ? true : mAllowEnterTransitionOverlap;
+    }
+
+    /**
+     * Sets whether the the return transition and reenter transition overlap or not.
+     * When true, the reenter transition will start as soon as possible. When false, the
+     * reenter transition will wait until the return transition completes before starting.
+     *
+     * @param allow true to start the reenter transition when possible or false to wait until the
+     *              return transition completes.
+     * @attr ref android.R.styleable#Fragment_fragmentAllowReturnTransitionOverlap
+     */
+    public void setAllowReturnTransitionOverlap(boolean allow) {
+        mAllowReturnTransitionOverlap = allow;
+    }
+
+    /**
+     * Returns whether the the return transition and reenter transition overlap or not.
+     * When true, the reenter transition will start as soon as possible. When false, the
+     * reenter transition will wait until the return transition completes before starting.
+     *
+     * @return true to start the reenter transition when possible or false to wait until the
+     *         return transition completes.
+     * @attr ref android.R.styleable#Fragment_fragmentAllowReturnTransitionOverlap
+     */
+    public boolean getAllowReturnTransitionOverlap() {
+        return (mAllowReturnTransitionOverlap == null) ? true : mAllowReturnTransitionOverlap;
+    }
+
     /**
      * Print the Fragments's state into the given stream.
      *
@@ -1588,53 +1923,53 @@
      */
     public void dump(String prefix, FileDescriptor fd, PrintWriter writer, String[] args) {
         writer.print(prefix); writer.print("mFragmentId=#");
-                writer.print(Integer.toHexString(mFragmentId));
-                writer.print(" mContainerId=#");
-                writer.print(Integer.toHexString(mContainerId));
-                writer.print(" mTag="); writer.println(mTag);
+        writer.print(Integer.toHexString(mFragmentId));
+        writer.print(" mContainerId=#");
+        writer.print(Integer.toHexString(mContainerId));
+        writer.print(" mTag="); writer.println(mTag);
         writer.print(prefix); writer.print("mState="); writer.print(mState);
-                writer.print(" mIndex="); writer.print(mIndex);
-                writer.print(" mWho="); writer.print(mWho);
-                writer.print(" mBackStackNesting="); writer.println(mBackStackNesting);
+        writer.print(" mIndex="); writer.print(mIndex);
+        writer.print(" mWho="); writer.print(mWho);
+        writer.print(" mBackStackNesting="); writer.println(mBackStackNesting);
         writer.print(prefix); writer.print("mAdded="); writer.print(mAdded);
-                writer.print(" mRemoving="); writer.print(mRemoving);
-                writer.print(" mResumed="); writer.print(mResumed);
-                writer.print(" mFromLayout="); writer.print(mFromLayout);
-                writer.print(" mInLayout="); writer.println(mInLayout);
+        writer.print(" mRemoving="); writer.print(mRemoving);
+        writer.print(" mResumed="); writer.print(mResumed);
+        writer.print(" mFromLayout="); writer.print(mFromLayout);
+        writer.print(" mInLayout="); writer.println(mInLayout);
         writer.print(prefix); writer.print("mHidden="); writer.print(mHidden);
-                writer.print(" mDetached="); writer.print(mDetached);
-                writer.print(" mMenuVisible="); writer.print(mMenuVisible);
-                writer.print(" mHasMenu="); writer.println(mHasMenu);
+        writer.print(" mDetached="); writer.print(mDetached);
+        writer.print(" mMenuVisible="); writer.print(mMenuVisible);
+        writer.print(" mHasMenu="); writer.println(mHasMenu);
         writer.print(prefix); writer.print("mRetainInstance="); writer.print(mRetainInstance);
-                writer.print(" mRetaining="); writer.print(mRetaining);
-                writer.print(" mUserVisibleHint="); writer.println(mUserVisibleHint);
+        writer.print(" mRetaining="); writer.print(mRetaining);
+        writer.print(" mUserVisibleHint="); writer.println(mUserVisibleHint);
         if (mFragmentManager != null) {
             writer.print(prefix); writer.print("mFragmentManager=");
-                    writer.println(mFragmentManager);
+            writer.println(mFragmentManager);
         }
         if (mActivity != null) {
             writer.print(prefix); writer.print("mActivity=");
-                    writer.println(mActivity);
+            writer.println(mActivity);
         }
         if (mParentFragment != null) {
             writer.print(prefix); writer.print("mParentFragment=");
-                    writer.println(mParentFragment);
+            writer.println(mParentFragment);
         }
         if (mArguments != null) {
             writer.print(prefix); writer.print("mArguments="); writer.println(mArguments);
         }
         if (mSavedFragmentState != null) {
             writer.print(prefix); writer.print("mSavedFragmentState=");
-                    writer.println(mSavedFragmentState);
+            writer.println(mSavedFragmentState);
         }
         if (mSavedViewState != null) {
             writer.print(prefix); writer.print("mSavedViewState=");
-                    writer.println(mSavedViewState);
+            writer.println(mSavedViewState);
         }
         if (mTarget != null) {
             writer.print(prefix); writer.print("mTarget="); writer.print(mTarget);
-                    writer.print(" mTargetRequestCode=");
-                    writer.println(mTargetRequestCode);
+            writer.print(" mTargetRequestCode=");
+            writer.println(mTargetRequestCode);
         }
         if (mNextAnim != 0) {
             writer.print(prefix); writer.print("mNextAnim="); writer.println(mNextAnim);
@@ -1648,7 +1983,7 @@
         if (mAnimatingAway != null) {
             writer.print(prefix); writer.print("mAnimatingAway="); writer.println(mAnimatingAway);
             writer.print(prefix); writer.print("mStateAfterAnimating=");
-                    writer.println(mStateAfterAnimating);
+            writer.println(mStateAfterAnimating);
         }
         if (mLoaderManager != null) {
             writer.print(prefix); writer.println("Loader Manager:");
@@ -1886,7 +2221,7 @@
             throw new SuperNotCalledException("Fragment " + this
                     + " did not call through to super.onStop()");
         }
-        
+
         if (mLoadersStarted) {
             mLoadersStarted = false;
             if (!mCheckedForLoaderManager) {
@@ -1929,4 +2264,23 @@
                     + " did not call through to super.onDestroy()");
         }
     }
+
+    private static Transition loadTransition(Context context, TypedArray typedArray,
+            Transition currentValue, Transition defaultValue, int id) {
+        if (currentValue != defaultValue) {
+            return currentValue;
+        }
+        int transitionId = typedArray.getResourceId(id, 0);
+        Transition transition = defaultValue;
+        if (transitionId != 0 && transitionId != com.android.internal.R.transition.no_transition) {
+            TransitionInflater inflater = TransitionInflater.from(context);
+            transition = inflater.inflateTransition(transitionId);
+            if (transition instanceof TransitionSet &&
+                    ((TransitionSet)transition).getTransitionCount() == 0) {
+                transition = null;
+            }
+        }
+        return transition;
+    }
+
 }
diff --git a/core/java/android/app/FragmentManager.java b/core/java/android/app/FragmentManager.java
index 1df1d42..ef69fdd 100644
--- a/core/java/android/app/FragmentManager.java
+++ b/core/java/android/app/FragmentManager.java
@@ -1497,7 +1497,10 @@
                 return false;
             }
             final BackStackRecord bss = mBackStack.remove(last);
-            bss.popFromBackStack(true, null);
+            SparseArray<Fragment> firstOutFragments = new SparseArray<Fragment>();
+            SparseArray<Fragment> lastInFragments = new SparseArray<Fragment>();
+            bss.calculateBackFragments(firstOutFragments, lastInFragments);
+            bss.popFromBackStack(true, null, firstOutFragments, lastInFragments);
             reportBackStackChanged();
         } else {
             int index = -1;
@@ -1541,10 +1544,16 @@
                 states.add(mBackStack.remove(i));
             }
             final int LAST = states.size()-1;
+            SparseArray<Fragment> firstOutFragments = new SparseArray<Fragment>();
+            SparseArray<Fragment> lastInFragments = new SparseArray<Fragment>();
+            for (int i=0; i<=LAST; i++) {
+                states.get(i).calculateBackFragments(firstOutFragments, lastInFragments);
+            }
             BackStackRecord.TransitionState state = null;
             for (int i=0; i<=LAST; i++) {
                 if (DEBUG) Log.v(TAG, "Popping back stack state: " + states.get(i));
-                state = states.get(i).popFromBackStack(i == LAST, state);
+                state = states.get(i).popFromBackStack(i == LAST, state,
+                        firstOutFragments, lastInFragments);
             }
             reportBackStackChanged();
         }
diff --git a/core/java/android/app/FragmentTransaction.java b/core/java/android/app/FragmentTransaction.java
index 0adc835..25cd3cc 100644
--- a/core/java/android/app/FragmentTransaction.java
+++ b/core/java/android/app/FragmentTransaction.java
@@ -172,32 +172,32 @@
     public abstract FragmentTransaction setTransition(int transit);
 
     /**
-     * Set a {@link android.transition.Transition} resource id to use with this transaction.
-     * <var>transitionId</var> will be played for fragments when going forward and when popping
-     * the back stack.
-     * @param sceneRootId The ID of the element acting as the scene root for the transition.
-     *                    This should be a ViewGroup containing all Fragments in the transaction.
-     * @param transitionId The resource ID for the Transition used during the Fragment transaction.
+     * TODO: remove from API
+     * @hide
      */
-    public abstract FragmentTransaction setCustomTransition(int sceneRootId, int transitionId);
+    public FragmentTransaction setCustomTransition(int sceneRootId, int transitionId) {
+        return this;
+    }
 
     /**
-     * Used with {@link #setCustomTransition(int, int)} to map a View from a removed or hidden
-     * Fragment to a View from a shown or added Fragment.
-     * <var>sharedElement</var> must have a unique transitionName in the View hierarchy.
+     * Used with to map a View from a removed or hidden Fragment to a View from a shown
+     * or added Fragment.
      * @param sharedElement A View in a disappearing Fragment to match with a View in an
      *                      appearing Fragment.
      * @param name The transitionName for a View in an appearing Fragment to match to the shared
      *             element.
      */
+    public abstract FragmentTransaction addSharedElement(View sharedElement, String name);
+
+    /**
+     * TODO: remove from API
+     * @hide
+     */
     public abstract FragmentTransaction setSharedElement(View sharedElement, String name);
 
     /**
-     * Used with {@link #setCustomTransition(int, int)} to map multiple Views from removed or hidden
-     * Fragments to a Views from a shown or added Fragments. Views in
-     * <var>sharedElements</var> must have unique transitionNames in the View hierarchy.
-     * @param sharedElements Pairs of Views in disappearing Fragments to transitionNames in
-     *                       appearing Fragments.
+     * TODO: remove from API
+     * @hide
      */
     public abstract FragmentTransaction setSharedElements(Pair<View, String>... sharedElements);
 
diff --git a/core/java/android/app/IActivityManager.java b/core/java/android/app/IActivityManager.java
index 2dbc4ea..8fa1fd53 100644
--- a/core/java/android/app/IActivityManager.java
+++ b/core/java/android/app/IActivityManager.java
@@ -36,6 +36,7 @@
 import android.content.pm.UserInfo;
 import android.content.res.Configuration;
 import android.graphics.Bitmap;
+import android.graphics.Point;
 import android.graphics.Rect;
 import android.net.Uri;
 import android.os.Bundle;
@@ -60,18 +61,19 @@
  * {@hide}
  */
 public interface IActivityManager extends IInterface {
-    public int startActivity(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo, String resultWho,
-            int requestCode, int flags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options) throws RemoteException;
-    public int startActivityAsUser(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo, String resultWho,
-            int requestCode, int flags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException;
+    public int startActivity(IApplicationThread caller, String callingPackage, Intent intent,
+            String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags,
+            ProfilerInfo profilerInfo, Bundle options) throws RemoteException;
+    public int startActivityAsUser(IApplicationThread caller, String callingPackage, Intent intent,
+            String resolvedType, IBinder resultTo, String resultWho, int requestCode, int flags,
+            ProfilerInfo profilerInfo, Bundle options, int userId) throws RemoteException;
+    public int startActivityAsCaller(IApplicationThread caller, String callingPackage,
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int flags, ProfilerInfo profilerInfo, Bundle options) throws RemoteException;
     public WaitResult startActivityAndWait(IApplicationThread caller, String callingPackage,
             Intent intent, String resolvedType, IBinder resultTo, String resultWho,
-            int requestCode, int flags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException;
+            int requestCode, int flags, ProfilerInfo profilerInfo, Bundle options,
+            int userId) throws RemoteException;
     public int startActivityWithConfig(IApplicationThread caller, String callingPackage,
             Intent intent, String resolvedType, IBinder resultTo, String resultWho,
             int requestCode, int startFlags, Configuration newConfig,
@@ -82,8 +84,8 @@
             int flagsMask, int flagsValues, Bundle options) throws RemoteException;
     public int startVoiceActivity(String callingPackage, int callingPid, int callingUid,
             Intent intent, String resolvedType, IVoiceInteractionSession session,
-            IVoiceInteractor interactor, int flags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) throws RemoteException;
+            IVoiceInteractor interactor, int flags, ProfilerInfo profilerInfo, Bundle options,
+            int userId) throws RemoteException;
     public boolean startNextMatchingActivity(IBinder callingActivity,
             Intent intent, Bundle options) throws RemoteException;
     public int startActivityFromRecents(int taskId, Bundle options) throws RemoteException;
@@ -92,6 +94,8 @@
     public void finishSubActivity(IBinder token, String resultWho, int requestCode) throws RemoteException;
     public boolean finishActivityAffinity(IBinder token) throws RemoteException;
     public void finishVoiceTask(IVoiceInteractionSession session) throws RemoteException;
+    public boolean releaseActivityInstance(IBinder token) throws RemoteException;
+    public void releaseSomeActivities(IApplicationThread app) throws RemoteException;
     public boolean willActivityBeVisible(IBinder token) throws RemoteException;
     public Intent registerReceiver(IApplicationThread caller, String callerPackage,
             IIntentReceiver receiver, IntentFilter filter,
@@ -107,14 +111,17 @@
     public void activityResumed(IBinder token) throws RemoteException;
     public void activityIdle(IBinder token, Configuration config,
             boolean stopProfiling) throws RemoteException;
-    public void activityPaused(IBinder token, PersistableBundle persistentState) throws RemoteException;
+    public void activityPaused(IBinder token) throws RemoteException;
     public void activityStopped(IBinder token, Bundle state,
             PersistableBundle persistentState, CharSequence description) throws RemoteException;
     public void activitySlept(IBinder token) throws RemoteException;
     public void activityDestroyed(IBinder token) throws RemoteException;
     public String getCallingPackage(IBinder token) throws RemoteException;
     public ComponentName getCallingActivity(IBinder token) throws RemoteException;
-    public List<IAppTask> getAppTasks() throws RemoteException;
+    public List<IAppTask> getAppTasks(String callingPackage) throws RemoteException;
+    public int addAppTask(IBinder activityToken, Intent intent,
+            ActivityManager.TaskDescription description, Bitmap thumbnail) throws RemoteException;
+    public Point getAppTaskThumbnailSize() throws RemoteException;
     public List<RunningTaskInfo> getTasks(int maxNum, int flags) throws RemoteException;
     public List<ActivityManager.RecentTaskInfo> getRecentTasks(int maxNum,
             int flags, int userId) throws RemoteException;
@@ -259,7 +266,7 @@
     // Special low-level communication with activity manager.
     public void handleApplicationCrash(IBinder app,
             ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException;
-    public boolean handleApplicationWtf(IBinder app, String tag,
+    public boolean handleApplicationWtf(IBinder app, String tag, boolean system,
             ApplicationErrorReport.CrashInfo crashInfo) throws RemoteException;
 
     // A StrictMode violation to be handled.  The violationMask is a
@@ -286,13 +293,13 @@
             throws RemoteException;
     // Get device configuration
     public ConfigurationInfo getDeviceConfigurationInfo() throws RemoteException;
-    
+
     // Turn on/off profiling in a particular process.
     public boolean profileControl(String process, int userId, boolean start,
-            String path, ParcelFileDescriptor fd, int profileType) throws RemoteException;
-    
+            ProfilerInfo profilerInfo, int profileType) throws RemoteException;
+
     public boolean shutdown(int timeout) throws RemoteException;
-    
+
     public void stopAppSwitches() throws RemoteException;
     public void resumeAppSwitches() throws RemoteException;
 
@@ -320,6 +327,8 @@
     public void notifyActivityDrawn(IBinder token) throws RemoteException;
     public ActivityOptions getActivityOptions(IBinder token) throws RemoteException;
 
+    public void bootAnimationComplete() throws RemoteException;
+
     public void setImmersive(IBinder token, boolean immersive) throws RemoteException;
     public boolean isImmersive(IBinder token) throws RemoteException;
     public boolean isTopActivityImmersive() throws RemoteException;
@@ -385,7 +394,7 @@
 
     public void keyguardWaitingForActivityDrawn() throws RemoteException;
 
-    public boolean targetTaskAffinityMatchesActivity(IBinder token, String destAffinity)
+    public boolean shouldUpRecreateTask(IBinder token, String destAffinity)
             throws RemoteException;
 
     public boolean navigateUpTo(IBinder token, Intent target, int resultCode, Intent resultData)
@@ -694,7 +703,7 @@
     int GET_MY_MEMORY_STATE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+142;
     int KILL_PROCESSES_BELOW_FOREGROUND_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+143;
     int GET_CURRENT_USER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+144;
-    int TARGET_TASK_AFFINITY_MATCHES_ACTIVITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+145;
+    int SHOULD_UP_RECREATE_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+145;
     int NAVIGATE_UP_TO_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+146;
     int SET_LOCK_SCREEN_SHOWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+147;
     int FINISH_ACTIVITY_AFFINITY_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+148;
@@ -760,4 +769,10 @@
     int START_ACTIVITY_FROM_RECENTS_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION + 229;
     int NOTIFY_ENTER_ANIMATION_COMPLETE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+230;
     int KEYGUARD_WAITING_FOR_ACTIVITY_DRAWN_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+231;
+    int START_ACTIVITY_AS_CALLER_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+232;
+    int ADD_APP_TASK_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+233;
+    int GET_APP_TASK_THUMBNAIL_SIZE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+234;
+    int RELEASE_ACTIVITY_INSTANCE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+235;
+    int RELEASE_SOME_ACTIVITIES_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+236;
+    int BOOT_ANIMATION_COMPLETE_TRANSACTION = IBinder.FIRST_CALL_TRANSACTION+237;
 }
diff --git a/core/java/android/app/IAppTask.aidl b/core/java/android/app/IAppTask.aidl
index 268b4dd..37fead9 100644
--- a/core/java/android/app/IAppTask.aidl
+++ b/core/java/android/app/IAppTask.aidl
@@ -17,9 +17,15 @@
 package android.app;
 
 import android.app.ActivityManager;
+import android.content.Intent;
+import android.os.Bundle;
 
 /** @hide */
 interface IAppTask {
     void finishAndRemoveTask();
     ActivityManager.RecentTaskInfo getTaskInfo();
+    void moveToFront();
+    int startActivity(IBinder whoThread, String callingPackage,
+            in Intent intent, String resolvedType, in Bundle options);
+    void setExcludeFromRecents(boolean exclude);
 }
diff --git a/core/java/android/app/IApplicationThread.java b/core/java/android/app/IApplicationThread.java
index 01b6fdf..f53075c 100644
--- a/core/java/android/app/IApplicationThread.java
+++ b/core/java/android/app/IApplicationThread.java
@@ -49,7 +49,7 @@
  */
 public interface IApplicationThread extends IInterface {
     void schedulePauseActivity(IBinder token, boolean finished, boolean userLeaving,
-            int configChanges) throws RemoteException;
+            int configChanges, boolean dontReport) throws RemoteException;
     void scheduleStopActivity(IBinder token, boolean showWindow,
             int configChanges) throws RemoteException;
     void scheduleWindowVisibility(IBinder token, boolean showWindow) throws RemoteException;
@@ -62,8 +62,7 @@
             IVoiceInteractor voiceInteractor, int procState, Bundle state,
             PersistableBundle persistentState, List<ResultInfo> pendingResults,
             List<Intent> pendingNewIntents, boolean notResumed, boolean isForward,
-            String profileName, ParcelFileDescriptor profileFd, boolean autoStopProfiler)
-            throws RemoteException;
+            ProfilerInfo profilerInfo) throws RemoteException;
     void scheduleRelaunchActivity(IBinder token, List<ResultInfo> pendingResults,
             List<Intent> pendingNewIntents, int configChanges,
             boolean notResumed, Configuration config) throws RemoteException;
@@ -94,10 +93,9 @@
     static final int DEBUG_ON = 1;
     static final int DEBUG_WAIT = 2;
     void bindApplication(String packageName, ApplicationInfo info, List<ProviderInfo> providers,
-            ComponentName testName, String profileName, ParcelFileDescriptor profileFd,
-            boolean autoStopProfiler, Bundle testArguments, IInstrumentationWatcher testWatcher,
-            IUiAutomationConnection uiAutomationConnection, int debugMode,
-            boolean openGlTrace, boolean restrictedBackupMode, boolean persistent,
+            ComponentName testName, ProfilerInfo profilerInfo, Bundle testArguments,
+            IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection,
+            int debugMode, boolean openGlTrace, boolean restrictedBackupMode, boolean persistent,
             Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services,
             Bundle coreSettings) throws RemoteException;
     void scheduleExit() throws RemoteException;
@@ -117,7 +115,7 @@
             boolean sticky, int sendingUser, int processState) throws RemoteException;
     void scheduleLowMemory() throws RemoteException;
     void scheduleActivityConfigurationChanged(IBinder token) throws RemoteException;
-    void profilerControl(boolean start, String path, ParcelFileDescriptor fd, int profileType)
+    void profilerControl(boolean start, ProfilerInfo profilerInfo, int profileType)
             throws RemoteException;
     void dumpHeap(boolean managed, String path, ParcelFileDescriptor fd)
             throws RemoteException;
diff --git a/core/java/android/app/INotificationManager.aidl b/core/java/android/app/INotificationManager.aidl
index e8f6818..bdcff38 100644
--- a/core/java/android/app/INotificationManager.aidl
+++ b/core/java/android/app/INotificationManager.aidl
@@ -23,6 +23,7 @@
 import android.content.Intent;
 import android.content.pm.ParceledListSlice;
 import android.net.Uri;
+import android.os.Bundle;
 import android.service.notification.Condition;
 import android.service.notification.IConditionListener;
 import android.service.notification.IConditionProvider;
@@ -47,6 +48,9 @@
     void setPackagePriority(String pkg, int uid, int priority);
     int getPackagePriority(String pkg, int uid);
 
+    void setPackageVisibilityOverride(String pkg, int uid, int visibility);
+    int getPackageVisibilityOverride(String pkg, int uid);
+
     // TODO: Remove this when callers have been migrated to the equivalent
     // INotificationListener method.
     StatusBarNotification[] getActiveNotifications(String callingPkg);
@@ -58,9 +62,15 @@
     void cancelNotificationFromListener(in INotificationListener token, String pkg, String tag, int id);
     void cancelNotificationsFromListener(in INotificationListener token, in String[] keys);
 
-    ParceledListSlice getActiveNotificationsFromListener(in INotificationListener token);
+    ParceledListSlice getActiveNotificationsFromListener(in INotificationListener token, in String[] keys, int trim);
     void requestHintsFromListener(in INotificationListener token, int hints);
     int getHintsFromListener(in INotificationListener token);
+    void requestInterruptionFilterFromListener(in INotificationListener token, int interruptionFilter);
+    int getInterruptionFilterFromListener(in INotificationListener token);
+    void setOnNotificationPostedTrimFromListener(in INotificationListener token, int trim);
+
+    ComponentName getEffectsSuppressor();
+    boolean matchesCallFilter(in Bundle extras);
 
     ZenModeConfig getZenModeConfig();
     boolean setZenModeConfig(in ZenModeConfig config);
@@ -69,4 +79,4 @@
     oneway void setZenModeCondition(in Condition condition);
     oneway void setAutomaticZenModeConditions(in Uri[] conditionIds);
     Condition[] getAutomaticZenModeConditions();
-}
\ No newline at end of file
+}
diff --git a/core/java/android/app/IWallpaperManager.aidl b/core/java/android/app/IWallpaperManager.aidl
index 181eb63..3b5900b 100644
--- a/core/java/android/app/IWallpaperManager.aidl
+++ b/core/java/android/app/IWallpaperManager.aidl
@@ -16,6 +16,7 @@
 
 package android.app;
 
+import android.graphics.Rect;
 import android.os.Bundle;
 import android.os.ParcelFileDescriptor;
 import android.app.IWallpaperManagerCallback;
@@ -73,6 +74,11 @@
     int getHeightHint();
 
     /**
+     * Sets extra padding that we would like the wallpaper to have outside of the display.
+     */
+    void setDisplayPadding(in Rect padding);
+
+    /**
      * Returns the name of the wallpaper. Private API.
      */
     String getName();
diff --git a/core/java/android/app/Instrumentation.java b/core/java/android/app/Instrumentation.java
index c583998..ba3a234 100644
--- a/core/java/android/app/Instrumentation.java
+++ b/core/java/android/app/Instrumentation.java
@@ -1481,7 +1481,7 @@
                 .startActivity(whoThread, who.getBasePackageName(), intent,
                         intent.resolveTypeIfNeeded(who.getContentResolver()),
                         token, target != null ? target.mEmbeddedID : null,
-                        requestCode, 0, null, null, options);
+                        requestCode, 0, null, options);
             checkStartActivityResult(result, intent);
         } catch (RemoteException e) {
         }
@@ -1598,7 +1598,7 @@
                 .startActivity(whoThread, who.getBasePackageName(), intent,
                         intent.resolveTypeIfNeeded(who.getContentResolver()),
                         token, target != null ? target.mWho : null,
-                        requestCode, 0, null, null, options);
+                        requestCode, 0, null, options);
             checkStartActivityResult(result, intent);
         } catch (RemoteException e) {
         }
@@ -1658,13 +1658,84 @@
                 .startActivityAsUser(whoThread, who.getBasePackageName(), intent,
                         intent.resolveTypeIfNeeded(who.getContentResolver()),
                         token, target != null ? target.mEmbeddedID : null,
-                        requestCode, 0, null, null, options, user.getIdentifier());
+                        requestCode, 0, null, options, user.getIdentifier());
             checkStartActivityResult(result, intent);
         } catch (RemoteException e) {
         }
         return null;
     }
 
+    /**
+     * Special version!
+     * @hide
+     */
+    public ActivityResult execStartActivityAsCaller(
+            Context who, IBinder contextThread, IBinder token, Activity target,
+            Intent intent, int requestCode, Bundle options) {
+        IApplicationThread whoThread = (IApplicationThread) contextThread;
+        if (mActivityMonitors != null) {
+            synchronized (mSync) {
+                final int N = mActivityMonitors.size();
+                for (int i=0; i<N; i++) {
+                    final ActivityMonitor am = mActivityMonitors.get(i);
+                    if (am.match(who, null, intent)) {
+                        am.mHits++;
+                        if (am.isBlocking()) {
+                            return requestCode >= 0 ? am.getResult() : null;
+                        }
+                        break;
+                    }
+                }
+            }
+        }
+        try {
+            intent.migrateExtraStreamToClipData();
+            intent.prepareToLeaveProcess();
+            int result = ActivityManagerNative.getDefault()
+                .startActivityAsCaller(whoThread, who.getBasePackageName(), intent,
+                        intent.resolveTypeIfNeeded(who.getContentResolver()),
+                        token, target != null ? target.mEmbeddedID : null,
+                        requestCode, 0, null, options);
+            checkStartActivityResult(result, intent);
+        } catch (RemoteException e) {
+        }
+        return null;
+    }
+
+    /**
+     * Special version!
+     * @hide
+     */
+    public void execStartActivityFromAppTask(
+            Context who, IBinder contextThread, IAppTask appTask,
+            Intent intent, Bundle options) {
+        IApplicationThread whoThread = (IApplicationThread) contextThread;
+        if (mActivityMonitors != null) {
+            synchronized (mSync) {
+                final int N = mActivityMonitors.size();
+                for (int i=0; i<N; i++) {
+                    final ActivityMonitor am = mActivityMonitors.get(i);
+                    if (am.match(who, null, intent)) {
+                        am.mHits++;
+                        if (am.isBlocking()) {
+                            return;
+                        }
+                        break;
+                    }
+                }
+            }
+        }
+        try {
+            intent.migrateExtraStreamToClipData();
+            intent.prepareToLeaveProcess();
+            int result = appTask.startActivity(whoThread.asBinder(), who.getBasePackageName(),
+                    intent, intent.resolveTypeIfNeeded(who.getContentResolver()), options);
+            checkStartActivityResult(result, intent);
+        } catch (RemoteException e) {
+        }
+        return;
+    }
+
     /*package*/ final void init(ActivityThread thread,
             Context instrContext, Context appContext, ComponentName component, 
             IInstrumentationWatcher watcher, IUiAutomationConnection uiAutomationConnection) {
diff --git a/core/java/android/app/KeyguardManager.java b/core/java/android/app/KeyguardManager.java
index 50e3a10..cc9aed8 100644
--- a/core/java/android/app/KeyguardManager.java
+++ b/core/java/android/app/KeyguardManager.java
@@ -63,7 +63,7 @@
      *
      * @return the intent for launching the activity or null if no password is required.
      **/
-    public Intent getConfirmDeviceCredentialIntent(CharSequence title, CharSequence description) {
+    public Intent createConfirmDeviceCredentialIntent(CharSequence title, CharSequence description) {
         if (!isKeyguardSecure()) return null;
         Intent intent = new Intent(ACTION_CONFIRM_DEVICE_CREDENTIAL);
         intent.putExtra(EXTRA_TITLE, title);
diff --git a/core/java/android/app/LoadedApk.java b/core/java/android/app/LoadedApk.java
index e0c7816..d143b86 100644
--- a/core/java/android/app/LoadedApk.java
+++ b/core/java/android/app/LoadedApk.java
@@ -51,8 +51,8 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.lang.ref.WeakReference;
-import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.Collections;
@@ -594,55 +594,6 @@
         return app;
     }
 
-    private void rewriteIntField(Field field, int packageId) throws IllegalAccessException {
-        int requiredModifiers = Modifier.STATIC | Modifier.PUBLIC;
-        int bannedModifiers = Modifier.FINAL;
-
-        int mod = field.getModifiers();
-        if ((mod & requiredModifiers) != requiredModifiers ||
-                (mod & bannedModifiers) != 0) {
-            throw new IllegalArgumentException("Field " + field.getName() +
-                    " is not rewritable");
-        }
-
-        if (field.getType() != int.class && field.getType() != Integer.class) {
-            throw new IllegalArgumentException("Field " + field.getName() +
-                    " is not an integer");
-        }
-
-        try {
-            int resId = field.getInt(null);
-            field.setInt(null, (resId & 0x00ffffff) | (packageId << 24));
-        } catch (IllegalAccessException e) {
-            // This should not occur (we check above if we can write to it)
-            throw new IllegalArgumentException(e);
-        }
-    }
-
-    private void rewriteIntArrayField(Field field, int packageId) {
-        int requiredModifiers = Modifier.STATIC | Modifier.PUBLIC;
-
-        if ((field.getModifiers() & requiredModifiers) != requiredModifiers) {
-            throw new IllegalArgumentException("Field " + field.getName() +
-                    " is not rewritable");
-        }
-
-        if (field.getType() != int[].class) {
-            throw new IllegalArgumentException("Field " + field.getName() +
-                    " is not an integer array");
-        }
-
-        try {
-            int[] array = (int[]) field.get(null);
-            for (int i = 0; i < array.length; i++) {
-                array[i] = (array[i] & 0x00ffffff) | (packageId << 24);
-            }
-        } catch (IllegalAccessException e) {
-            // This should not occur (we check above if we can write to it)
-            throw new IllegalArgumentException(e);
-        }
-    }
-
     private void rewriteRValues(ClassLoader cl, String packageName, int id) {
         final Class<?> rClazz;
         try {
@@ -650,35 +601,30 @@
         } catch (ClassNotFoundException e) {
             // This is not necessarily an error, as some packages do not ship with resources
             // (or they do not need rewriting).
-            Log.i(TAG, "Could not find R class for package '" + packageName + "'");
+            Log.i(TAG, "No resource references to update in package " + packageName);
             return;
         }
 
+        final Method callback;
         try {
-            Class<?>[] declaredClasses = rClazz.getDeclaredClasses();
-            for (Class<?> clazz : declaredClasses) {
-                try {
-                    if (clazz.getSimpleName().equals("styleable")) {
-                        for (Field field : clazz.getDeclaredFields()) {
-                            if (field.getType() == int[].class) {
-                                rewriteIntArrayField(field, id);
-                            }
-                        }
-
-                    } else {
-                        for (Field field : clazz.getDeclaredFields()) {
-                            rewriteIntField(field, id);
-                        }
-                    }
-                } catch (Exception e) {
-                    throw new IllegalArgumentException("Failed to rewrite R values for " +
-                            clazz.getName(), e);
-                }
-            }
-
-        } catch (Exception e) {
-            throw new IllegalArgumentException("Failed to rewrite R values", e);
+            callback = rClazz.getMethod("onResourcesLoaded", int.class);
+        } catch (NoSuchMethodException e) {
+            // No rewriting to be done.
+            return;
         }
+
+        Throwable cause;
+        try {
+            callback.invoke(null, id);
+            return;
+        } catch (IllegalAccessException e) {
+            cause = e;
+        } catch (InvocationTargetException e) {
+            cause = e.getCause();
+        }
+
+        throw new RuntimeException("Failed to rewrite resource references for " + packageName,
+                cause);
     }
 
     public void removeContextRegistrations(Context context,
diff --git a/core/java/android/app/Notification.java b/core/java/android/app/Notification.java
index 5f58839..31b39eb 100644
--- a/core/java/android/app/Notification.java
+++ b/core/java/android/app/Notification.java
@@ -21,8 +21,8 @@
 import android.annotation.SdkConstant.SdkConstantType;
 import android.content.Context;
 import android.content.Intent;
+import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager.NameNotFoundException;
-import android.content.res.Resources;
 import android.graphics.Bitmap;
 import android.graphics.Canvas;
 import android.graphics.PorterDuff;
@@ -32,14 +32,15 @@
 import android.media.session.MediaSession;
 import android.net.Uri;
 import android.os.BadParcelableException;
+import android.os.Build;
 import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.os.SystemClock;
 import android.os.UserHandle;
-import android.os.UserManager;
 import android.text.TextUtils;
 import android.util.Log;
+import android.util.MathUtils;
 import android.util.TypedValue;
 import android.view.Gravity;
 import android.view.View;
@@ -128,6 +129,14 @@
     public static final int DEFAULT_LIGHTS = 4;
 
     /**
+     * Maximum length of CharSequences accepted by Builder and friends.
+     *
+     * <p>
+     * Avoids spamming the system with overly large strings such as full e-mails.
+     */
+    private static final int MAX_CHARSEQUENCE_LENGTH = 5 * 1024;
+
+    /**
      * A timestamp related to this notification, in milliseconds since the epoch.
      *
      * Default value: {@link System#currentTimeMillis() Now}.
@@ -536,8 +545,26 @@
      */
     public int visibility;
 
+    /**
+     * Notification visibility: Show this notification in its entirety on all lockscreens.
+     *
+     * {@see #visibility}
+     */
     public static final int VISIBILITY_PUBLIC = 1;
+
+    /**
+     * Notification visibility: Show this notification on all lockscreens, but conceal sensitive or
+     * private information on secure lockscreens.
+     *
+     * {@see #visibility}
+     */
     public static final int VISIBILITY_PRIVATE = 0;
+
+    /**
+     * Notification visibility: Do not reveal any part of this notification on a secure lockscreen.
+     *
+     * {@see #visibility}
+     */
     public static final int VISIBILITY_SECRET = -1;
 
     /**
@@ -1422,6 +1449,9 @@
             extras.remove(Notification.EXTRA_LARGE_ICON);
             extras.remove(Notification.EXTRA_LARGE_ICON_BIG);
             extras.remove(Notification.EXTRA_PICTURE);
+            extras.remove(Notification.EXTRA_BIG_TEXT);
+            // Prevent light notifications from being rebuilt.
+            extras.remove(Builder.EXTRA_NEEDS_REBUILD);
         }
     }
 
@@ -1431,6 +1461,10 @@
      * @hide
      */
     public static CharSequence safeCharSequence(CharSequence cs) {
+        if (cs == null) return cs;
+        if (cs.length() > MAX_CHARSEQUENCE_LENGTH) {
+            cs = cs.subSequence(0, MAX_CHARSEQUENCE_LENGTH);
+        }
         if (cs instanceof Parcelable) {
             Log.e(TAG, "warning: " + cs.getClass().getCanonicalName()
                     + " instance is a custom Parcelable and not allowed in Notification");
@@ -1607,6 +1641,7 @@
         builder.setPriority(this.priority);
         builder.setTicker(this.tickerText);
         builder.setNumber(this.number);
+        builder.setColor(this.color);
         builder.mFlags = this.flags;
         builder.setSound(this.sound, this.audioStreamType);
         builder.setDefaults(this.defaults);
@@ -1754,6 +1789,7 @@
      */
     public static class Builder {
         private static final int MAX_ACTION_BUTTONS = 3;
+        private static final float LARGE_TEXT_SCALE = 1.3f;
 
         /**
          * @hide
@@ -1795,10 +1831,12 @@
                 = "android.rebuild.hudViewActionCount";
 
         /**
-         * The package name of the context used to create the notification via a Builder.
+         * The ApplicationInfo of the package that created the notification, used to create
+         * a context to rebuild the notification via a Builder.
+         * @hide
          */
-        private static final String EXTRA_REBUILD_CONTEXT_PACKAGE =
-                "android.rebuild.contextPackage";
+        private static final String EXTRA_REBUILD_CONTEXT_APPLICATION_INFO =
+                "android.rebuild.applicationInfo";
 
         // Whether to enable stripping (at post time) & rebuilding (at listener receive time) of
         // memory intensive resources.
@@ -1864,6 +1902,15 @@
         private Notification mRebuildNotification = null;
 
         /**
+         * Whether the build notification has three lines. This is used to make the top padding for
+         * both the contracted and expanded layout consistent.
+         *
+         * <p>
+         * This field is only valid during the build phase.
+         */
+        private boolean mHasThreeLines;
+
+        /**
          * Constructs a new Builder with the defaults:
          *
 
@@ -1901,7 +1948,8 @@
             mPriority = PRIORITY_DEFAULT;
             mPeople = new ArrayList<String>();
 
-            mColorUtil = NotificationColorUtil.getInstance();
+            mColorUtil = context.getApplicationInfo().targetSdkVersion < Build.VERSION_CODES.L ?
+                    NotificationColorUtil.getInstance(mContext) : null;
         }
 
         /**
@@ -2559,54 +2607,102 @@
             return this;
         }
 
-        private Bitmap getProfileBadge() {
+        private Drawable getProfileBadgeDrawable() {
             // Note: This assumes that the current user can read the profile badge of the
             // originating user.
-            UserManager userManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
-            Drawable badge = userManager.getBadgeForUser(new UserHandle(mOriginatingUserId), 0);
+            return mContext.getPackageManager().getUserBadgeForDensity(
+                    new UserHandle(mOriginatingUserId), 0);
+        }
+
+        private Bitmap getProfileBadge() {
+            Drawable badge = getProfileBadgeDrawable();
             if (badge == null) {
                 return null;
             }
-            final int width = badge.getIntrinsicWidth();
-            final int height = badge.getIntrinsicHeight();
-            Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
+            final int size = mContext.getResources().getDimensionPixelSize(
+                    R.dimen.notification_badge_size);
+            Bitmap bitmap = Bitmap.createBitmap(size, size, Bitmap.Config.ARGB_8888);
             Canvas canvas = new Canvas(bitmap);
-            badge.setBounds(0, 0, width, height);
+            badge.setBounds(0, 0, size, size);
             badge.draw(canvas);
             return bitmap;
         }
 
-        private RemoteViews applyStandardTemplate(int resId, boolean fitIn1U) {
-            final boolean largeFontScale
-                    = mContext.getResources().getConfiguration().fontScale >= 1.25f;
+        private boolean addProfileBadge(RemoteViews contentView, int resId) {
+            Bitmap profileBadge = getProfileBadge();
 
-            Bitmap profileIcon = getProfileBadge();
-            RemoteViews contentView = new BuilderRemoteViews(mContext.getPackageName(),
-                    mOriginatingUserId, resId);
+            contentView.setViewVisibility(R.id.profile_badge_large_template, View.GONE);
+            contentView.setViewVisibility(R.id.profile_badge_line2, View.GONE);
+            contentView.setViewVisibility(R.id.profile_badge_line3, View.GONE);
 
-            if (largeFontScale) {
-                // Make a little extra room for the bigger text.
-                final int margin = (int) mContext.getResources()
-                        .getDimensionPixelSize(R.dimen.notification_large_font_vert_pad);
-                contentView.setViewPadding(R.id.line1, 0, margin, 0, 0);
-                contentView.setViewPadding(R.id.line3, 0, 0, 0, margin);
+            if (profileBadge != null) {
+                contentView.setImageViewBitmap(resId, profileBadge);
+                contentView.setViewVisibility(resId, View.VISIBLE);
+
+                // Make sure Line 3 is visible. As badge will be here if there
+                // is no text to display.
+                if (resId == R.id.profile_badge_line3) {
+                    contentView.setViewVisibility(R.id.line3, View.VISIBLE);
+                }
+                return true;
             }
+            return false;
+        }
+
+        private void shrinkLine3Text(RemoteViews contentView) {
+            float subTextSize = mContext.getResources().getDimensionPixelSize(
+                    R.dimen.notification_subtext_size);
+            contentView.setTextViewTextSize(R.id.text, TypedValue.COMPLEX_UNIT_PX, subTextSize);
+        }
+
+        private void unshrinkLine3Text(RemoteViews contentView) {
+            float regularTextSize = mContext.getResources().getDimensionPixelSize(
+                    com.android.internal.R.dimen.notification_text_size);
+            contentView.setTextViewTextSize(R.id.text, TypedValue.COMPLEX_UNIT_PX, regularTextSize);
+        }
+
+        private void resetStandardTemplate(RemoteViews contentView) {
+            removeLargeIconBackground(contentView);
+            contentView.setViewPadding(R.id.icon, 0, 0, 0, 0);
+            contentView.setImageViewResource(R.id.icon, 0);
+            contentView.setInt(R.id.icon, "setBackgroundResource", 0);
+            contentView.setViewVisibility(R.id.right_icon, View.GONE);
+            contentView.setInt(R.id.right_icon, "setBackgroundResource", 0);
+            contentView.setImageViewResource(R.id.right_icon, 0);
+            contentView.setImageViewResource(R.id.icon, 0);
+            contentView.setTextViewText(R.id.title, null);
+            contentView.setTextViewText(R.id.text, null);
+            unshrinkLine3Text(contentView);
+            contentView.setTextViewText(R.id.text2, null);
+            contentView.setViewVisibility(R.id.text2, View.GONE);
+            contentView.setViewVisibility(R.id.info, View.GONE);
+            contentView.setViewVisibility(R.id.time, View.GONE);
+            contentView.setViewVisibility(R.id.line3, View.GONE);
+            contentView.setViewVisibility(R.id.overflow_divider, View.GONE);
+            contentView.setViewVisibility(R.id.progress, View.GONE);
+            contentView.setViewVisibility(R.id.chronometer, View.GONE);
+            contentView.setViewVisibility(R.id.time, View.GONE);
+        }
+
+        private RemoteViews applyStandardTemplate(int resId) {
+            return applyStandardTemplate(resId, true /* hasProgress */);
+        }
+
+        /**
+         * @param hasProgress whether the progress bar should be shown and set
+         */
+        private RemoteViews applyStandardTemplate(int resId, boolean hasProgress) {
+            RemoteViews contentView = new BuilderRemoteViews(mContext.getApplicationInfo(), resId);
+
+            resetStandardTemplate(contentView);
 
             boolean showLine3 = false;
             boolean showLine2 = false;
+            boolean contentTextInLine2 = false;
 
-            if (mPriority < PRIORITY_LOW) {
-                // TODO: Low priority presentation
-            }
-            if (profileIcon != null) {
-                contentView.setImageViewBitmap(R.id.profile_icon, profileIcon);
-                contentView.setViewVisibility(R.id.profile_icon, View.VISIBLE);
-            } else {
-                contentView.setViewVisibility(R.id.profile_icon, View.GONE);
-            }
             if (mLargeIcon != null) {
                 contentView.setImageViewBitmap(R.id.icon, mLargeIcon);
-                processLargeIcon(mLargeIcon, contentView);
+                processLargeLegacyIcon(mLargeIcon, contentView);
                 contentView.setImageViewResource(R.id.right_icon, mSmallIcon);
                 contentView.setViewVisibility(R.id.right_icon, View.VISIBLE);
                 processSmallRightIcon(mSmallIcon, contentView);
@@ -2650,33 +2746,28 @@
                     contentView.setTextViewText(R.id.text2, processLegacyText(mContentText));
                     contentView.setViewVisibility(R.id.text2, View.VISIBLE);
                     showLine2 = true;
+                    contentTextInLine2 = true;
                 } else {
                     contentView.setViewVisibility(R.id.text2, View.GONE);
                 }
             } else {
                 contentView.setViewVisibility(R.id.text2, View.GONE);
-                if (mProgressMax != 0 || mProgressIndeterminate) {
+                if (hasProgress && (mProgressMax != 0 || mProgressIndeterminate)) {
+                    contentView.setViewVisibility(R.id.progress, View.VISIBLE);
                     contentView.setProgressBar(
                             R.id.progress, mProgressMax, mProgress, mProgressIndeterminate);
-                    contentView.setViewVisibility(R.id.progress, View.VISIBLE);
                     showLine2 = true;
                 } else {
                     contentView.setViewVisibility(R.id.progress, View.GONE);
                 }
             }
             if (showLine2) {
-                if (fitIn1U) {
-                    // need to shrink all the type to make sure everything fits
-                    final Resources res = mContext.getResources();
-                    final float subTextSize = res.getDimensionPixelSize(
-                            R.dimen.notification_subtext_size);
-                    contentView.setTextViewTextSize(R.id.text, TypedValue.COMPLEX_UNIT_PX, subTextSize);
-                }
-                // vertical centering
-                contentView.setViewPadding(R.id.line1, 0, 0, 0, 0);
+
+                // need to shrink all the type to make sure everything fits
+                shrinkLine3Text(contentView);
             }
 
-            if (mWhen != 0 && mShowWhen) {
+            if (showsTimeOrChronometer()) {
                 if (mUseChronometer) {
                     contentView.setViewVisibility(R.id.chronometer, View.VISIBLE);
                     contentView.setLong(R.id.chronometer, "setBase",
@@ -2686,24 +2777,90 @@
                     contentView.setViewVisibility(R.id.time, View.VISIBLE);
                     contentView.setLong(R.id.time, "setTime", mWhen);
                 }
-            } else {
-                contentView.setViewVisibility(R.id.time, View.GONE);
             }
 
+            // Adjust padding depending on line count and font size.
+            contentView.setViewPadding(R.id.line1, 0, calculateTopPadding(mContext,
+                    mHasThreeLines, mContext.getResources().getConfiguration().fontScale),
+                    0, 0);
+
+            // We want to add badge to first line of text.
+            boolean addedBadge = addProfileBadge(contentView,
+                    contentTextInLine2 ? R.id.profile_badge_line2 : R.id.profile_badge_line3);
+            // If we added the badge to line 3 then we should show line 3.
+            if (addedBadge && !contentTextInLine2) {
+                showLine3 = true;
+            }
+
+            // Note getStandardView may hide line 3 again.
             contentView.setViewVisibility(R.id.line3, showLine3 ? View.VISIBLE : View.GONE);
             contentView.setViewVisibility(R.id.overflow_divider, showLine3 ? View.VISIBLE : View.GONE);
             return contentView;
         }
 
+        /**
+         * @return true if the built notification will show the time or the chronometer; false
+         *         otherwise
+         */
+        private boolean showsTimeOrChronometer() {
+            return mWhen != 0 && mShowWhen;
+        }
+
+        /**
+         * Logic to find out whether the notification is going to have three lines in the contracted
+         * layout. This is used to adjust the top padding.
+         *
+         * @return true if the notification is going to have three lines; false if the notification
+         *         is going to have one or two lines
+         */
+        private boolean hasThreeLines() {
+            boolean contentTextInLine2 = mSubText != null && mContentText != null;
+            boolean hasProgress = mStyle == null || mStyle.hasProgress();
+            // If we have content text in line 2, badge goes into line 2, or line 3 otherwise
+            boolean badgeInLine3 = getProfileBadgeDrawable() != null && !contentTextInLine2;
+            boolean hasLine3 = mContentText != null || mContentInfo != null || mNumber > 0
+                    || badgeInLine3;
+            boolean hasLine2 = (mSubText != null && mContentText != null) ||
+                    (hasProgress && mSubText == null
+                            && (mProgressMax != 0 || mProgressIndeterminate));
+            return hasLine2 && hasLine3;
+        }
+
+        /**
+         * @hide
+         */
+        public static int calculateTopPadding(Context ctx, boolean hasThreeLines,
+                float fontScale) {
+            int padding = ctx.getResources().getDimensionPixelSize(hasThreeLines
+                    ? R.dimen.notification_top_pad_narrow
+                    : R.dimen.notification_top_pad);
+            int largePadding = ctx.getResources().getDimensionPixelSize(hasThreeLines
+                    ? R.dimen.notification_top_pad_large_text_narrow
+                    : R.dimen.notification_top_pad_large_text);
+            float largeFactor = (MathUtils.constrain(fontScale, 1.0f, LARGE_TEXT_SCALE) - 1f)
+                    / (LARGE_TEXT_SCALE - 1f);
+
+            // Linearly interpolate the padding between large and normal with the font scale ranging
+            // from 1f to LARGE_TEXT_SCALE
+            return Math.round((1 - largeFactor) * padding + largeFactor * largePadding);
+        }
+
+        private void resetStandardTemplateWithActions(RemoteViews big) {
+            big.setViewVisibility(R.id.actions, View.GONE);
+            big.setViewVisibility(R.id.action_divider, View.GONE);
+            big.removeAllViews(R.id.actions);
+        }
+
         private RemoteViews applyStandardTemplateWithActions(int layoutId) {
-            RemoteViews big = applyStandardTemplate(layoutId, false);
+            RemoteViews big = applyStandardTemplate(layoutId);
+
+            resetStandardTemplateWithActions(big);
 
             int N = mActions.size();
             if (N > 0) {
                 big.setViewVisibility(R.id.actions, View.VISIBLE);
                 big.setViewVisibility(R.id.action_divider, View.VISIBLE);
                 if (N>MAX_ACTION_BUTTONS) N=MAX_ACTION_BUTTONS;
-                big.removeAllViews(R.id.actions);
                 for (int i=0; i<N; i++) {
                     final RemoteViews button = generateActionButton(mActions.get(i));
                     big.addView(R.id.actions, button);
@@ -2716,7 +2873,7 @@
             if (mContentView != null) {
                 return mContentView;
             } else {
-                return applyStandardTemplate(getBaseLayoutResource(), true); // no more special large_icon flavor
+                return applyStandardTemplate(getBaseLayoutResource());
             }
         }
 
@@ -2764,13 +2921,10 @@
         }
 
         private void processLegacyAction(Action action, RemoteViews button) {
-            if (isLegacy()) {
-                if (mColorUtil.isGrayscale(mContext, action.icon)) {
-                    button.setTextViewCompoundDrawablesRelativeColorFilter(R.id.action0, 0,
-                            mContext.getResources().getColor(
-                                    R.color.notification_action_legacy_color_filter),
-                            PorterDuff.Mode.MULTIPLY);
-                }
+            if (!isLegacy() || mColorUtil.isGrayscaleIcon(mContext, action.icon)) {
+                button.setTextViewCompoundDrawablesRelativeColorFilter(R.id.action0, 0,
+                        mContext.getResources().getColor(R.color.notification_action_color_filter),
+                        PorterDuff.Mode.MULTIPLY);
             }
         }
 
@@ -2786,7 +2940,7 @@
          * Apply any necessary background to smallIcons being used in the largeIcon spot.
          */
         private void processSmallIconAsLarge(int largeIconId, RemoteViews contentView) {
-            if (!isLegacy() || mColorUtil.isGrayscale(mContext, largeIconId)) {
+            if (!isLegacy() || mColorUtil.isGrayscaleIcon(mContext, largeIconId)) {
                 applyLargeIconBackground(contentView);
             }
         }
@@ -2796,8 +2950,8 @@
          * if it's grayscale).
          */
         // TODO: also check bounds, transparency, that sort of thing.
-        private void processLargeIcon(Bitmap largeIcon, RemoteViews contentView) {
-            if (!isLegacy() || mColorUtil.isGrayscale(largeIcon)) {
+        private void processLargeLegacyIcon(Bitmap largeIcon, RemoteViews contentView) {
+            if (isLegacy() && mColorUtil.isGrayscaleIcon(largeIcon)) {
                 applyLargeIconBackground(contentView);
             } else {
                 removeLargeIconBackground(contentView);
@@ -2809,7 +2963,7 @@
          */
         private void applyLargeIconBackground(RemoteViews contentView) {
             contentView.setInt(R.id.icon, "setBackgroundResource",
-                    R.drawable.notification_icon_legacy_bg_inset);
+                    R.drawable.notification_icon_legacy_bg);
 
             contentView.setDrawableParameters(
                     R.id.icon,
@@ -2818,6 +2972,10 @@
                     resolveColor(),
                     PorterDuff.Mode.SRC_ATOP,
                     -1);
+
+            int padding = mContext.getResources().getDimensionPixelSize(
+                    R.dimen.notification_large_icon_circle_padding);
+            contentView.setViewPadding(R.id.icon, padding, padding, padding, padding);
         }
 
         private void removeLargeIconBackground(RemoteViews contentView) {
@@ -2829,7 +2987,7 @@
          */
         private void processSmallRightIcon(int smallIconDrawableId,
                 RemoteViews contentView) {
-            if (!isLegacy() || mColorUtil.isGrayscale(mContext, smallIconDrawableId)) {
+            if (!isLegacy() || mColorUtil.isGrayscaleIcon(mContext, smallIconDrawableId)) {
                 contentView.setDrawableParameters(R.id.right_icon, false, -1,
                         0xFFFFFFFF,
                         PorterDuff.Mode.SRC_ATOP, -1);
@@ -2925,7 +3083,8 @@
         public void populateExtras(Bundle extras) {
             // Store original information used in the construction of this object
             extras.putInt(EXTRA_ORIGINATING_USERID, mOriginatingUserId);
-            extras.putString(EXTRA_REBUILD_CONTEXT_PACKAGE, mContext.getPackageName());
+            extras.putParcelable(EXTRA_REBUILD_CONTEXT_APPLICATION_INFO,
+                    mContext.getApplicationInfo());
             extras.putCharSequence(EXTRA_TITLE, mContentTitle);
             extras.putCharSequence(EXTRA_TEXT, mContentText);
             extras.putCharSequence(EXTRA_SUB_TEXT, mSubText);
@@ -3013,13 +3172,14 @@
             extras.remove(EXTRA_NEEDS_REBUILD);
 
             // Re-create notification context so we can access app resources.
-            String packageName = extras.getString(EXTRA_REBUILD_CONTEXT_PACKAGE);
+            ApplicationInfo applicationInfo = extras.getParcelable(
+                    EXTRA_REBUILD_CONTEXT_APPLICATION_INFO);
             Context builderContext;
             try {
-                builderContext = context.createPackageContext(packageName,
+                builderContext = context.createApplicationContext(applicationInfo,
                         Context.CONTEXT_RESTRICTED);
             } catch (NameNotFoundException e) {
-                Log.e(TAG, "Package name " + packageName + " not found");
+                Log.e(TAG, "ApplicationInfo " + applicationInfo + " not found");
                 builderContext = context;  // try with our context
             }
 
@@ -3040,6 +3200,7 @@
             if (mRebuildNotification == null) {
                 throw new IllegalStateException("rebuild() only valid when in 'rebuild' mode.");
             }
+            mHasThreeLines = hasThreeLines();
 
             Bundle extras = mRebuildNotification.extras;
 
@@ -3072,6 +3233,7 @@
             }
             extras.remove(EXTRA_REBUILD_HEADS_UP_CONTENT_VIEW);
 
+            mHasThreeLines = false;
             return mRebuildNotification;
         }
 
@@ -3186,6 +3348,7 @@
          */
         public Notification build() {
             mOriginatingUserId = mContext.getUserId();
+            mHasThreeLines = hasThreeLines();
 
             Notification n = buildUnstyled();
 
@@ -3207,6 +3370,7 @@
                 mStyle.addExtras(n.extras);
             }
 
+            mHasThreeLines = false;
             return n;
         }
 
@@ -3233,7 +3397,7 @@
         }
 
         private int getBigTextLayoutResource() {
-            return getBigBaseLayoutResource();
+            return R.layout.notification_template_material_big_text;
         }
 
         private int getInboxLayoutResource() {
@@ -3255,8 +3419,16 @@
      */
     public static abstract class Style {
         private CharSequence mBigContentTitle;
-        private CharSequence mSummaryText = null;
-        private boolean mSummaryTextSet = false;
+
+        /**
+         * @hide
+         */
+        protected CharSequence mSummaryText = null;
+
+        /**
+         * @hide
+         */
+        protected boolean mSummaryTextSet = false;
 
         protected Builder mBuilder;
 
@@ -3319,6 +3491,8 @@
                 contentView.setViewVisibility(R.id.overflow_divider, View.VISIBLE);
                 contentView.setViewVisibility(R.id.line3, View.VISIBLE);
             } else {
+                // Clear text in case we use the line to show the profile badge.
+                contentView.setTextViewText(R.id.text, "");
                 contentView.setViewVisibility(R.id.overflow_divider, View.GONE);
                 contentView.setViewVisibility(R.id.line3, View.GONE);
             }
@@ -3327,6 +3501,19 @@
         }
 
         /**
+         * Changes the padding of the first line such that the big and small content view have the
+         * same top padding.
+         *
+         * @hide
+         */
+        protected void applyTopPadding(RemoteViews contentView) {
+            int topPadding = Builder.calculateTopPadding(mBuilder.mContext,
+                    mBuilder.mHasThreeLines,
+                    mBuilder.mContext.getResources().getConfiguration().fontScale);
+            contentView.setViewPadding(R.id.line1, 0, topPadding, 0, 0);
+        }
+
+        /**
          * @hide
          */
         public void addExtras(Bundle extras) {
@@ -3394,6 +3581,15 @@
             checkBuilder();
             return mBuilder.build();
         }
+
+        /**
+         * @hide
+         * @return true if the style positions the progress bar on the second line; false if the
+         *         style hides the progress bar
+         */
+        protected boolean hasProgress() {
+            return true;
+        }
     }
 
     /**
@@ -3464,6 +3660,11 @@
 
             contentView.setImageViewBitmap(R.id.big_picture, mPicture);
 
+            applyTopPadding(contentView);
+
+            boolean twoTextLines = mBuilder.mSubText != null && mBuilder.mContentText != null;
+            mBuilder.addProfileBadge(contentView,
+                    twoTextLines ? R.id.profile_badge_line2 : R.id.profile_badge_line3);
             return contentView;
         }
 
@@ -3519,6 +3720,11 @@
      * @see Notification#bigContentView
      */
     public static class BigTextStyle extends Style {
+
+        private static final int MAX_LINES = 13;
+        private static final int LINES_CONSUMED_BY_ACTIONS = 3;
+        private static final int LINES_CONSUMED_BY_SUMMARY = 2;
+
         private CharSequence mBigText;
 
         public BigTextStyle() {
@@ -3574,8 +3780,6 @@
         }
 
         private RemoteViews makeBigContentView() {
-            // Remove the content text so line3 only shows if you have a summary
-            final boolean hadThreeLines = (mBuilder.mContentText != null && mBuilder.mSubText != null);
 
             // Nasty
             CharSequence oldBuilderContentText = mBuilder.mContentText;
@@ -3585,18 +3789,38 @@
 
             mBuilder.mContentText = oldBuilderContentText;
 
-            if (hadThreeLines) {
-                // vertical centering
-                contentView.setViewPadding(R.id.line1, 0, 0, 0, 0);
-            }
-
             contentView.setTextViewText(R.id.big_text, mBuilder.processLegacyText(mBigText));
             contentView.setViewVisibility(R.id.big_text, View.VISIBLE);
+            contentView.setInt(R.id.big_text, "setMaxLines", calculateMaxLines());
             contentView.setViewVisibility(R.id.text2, View.GONE);
 
+            applyTopPadding(contentView);
+
+            mBuilder.shrinkLine3Text(contentView);
+
+            mBuilder.addProfileBadge(contentView, R.id.profile_badge_large_template);
+
             return contentView;
         }
 
+        private int calculateMaxLines() {
+            int lineCount = MAX_LINES;
+            boolean hasActions = mBuilder.mActions.size() > 0;
+            boolean hasSummary = (mSummaryTextSet ? mSummaryText : mBuilder.mSubText) != null;
+            if (hasActions) {
+                lineCount -= LINES_CONSUMED_BY_ACTIONS;
+            }
+            if (hasSummary) {
+                lineCount -= LINES_CONSUMED_BY_SUMMARY;
+            }
+
+            // If we have less top padding at the top, we can fit less lines.
+            if (!mBuilder.mHasThreeLines) {
+                lineCount--;
+            }
+            return lineCount;
+        }
+
         /**
          * @hide
          */
@@ -3705,13 +3929,20 @@
                 contentView.setViewVisibility(rowId, View.GONE);
             }
 
-
+            final boolean largeText =
+                    mBuilder.mContext.getResources().getConfiguration().fontScale > 1f;
+            final float subTextSize = mBuilder.mContext.getResources().getDimensionPixelSize(
+                    R.dimen.notification_subtext_size);
             int i=0;
             while (i < mTexts.size() && i < rowIds.length) {
                 CharSequence str = mTexts.get(i);
                 if (str != null && !str.equals("")) {
                     contentView.setViewVisibility(rowIds[i], View.VISIBLE);
                     contentView.setTextViewText(rowIds[i], mBuilder.processLegacyText(str));
+                    if (largeText) {
+                        contentView.setTextViewTextSize(rowIds[i], TypedValue.COMPLEX_UNIT_PX,
+                                subTextSize);
+                    }
                 }
                 i++;
             }
@@ -3722,6 +3953,12 @@
             contentView.setViewVisibility(R.id.inbox_more,
                     mTexts.size() > rowIds.length ? View.VISIBLE : View.GONE);
 
+            applyTopPadding(contentView);
+
+            mBuilder.shrinkLine3Text(contentView);
+
+            mBuilder.addProfileBadge(contentView, R.id.profile_badge_large_template);
+
             return contentView;
         }
 
@@ -3774,7 +4011,7 @@
      * @see Notification#bigContentView
      */
     public static class MediaStyle extends Style {
-        static final int MAX_MEDIA_BUTTONS_IN_COMPACT = 2;
+        static final int MAX_MEDIA_BUTTONS_IN_COMPACT = 3;
         static final int MAX_MEDIA_BUTTONS = 5;
 
         private int[] mActionsToShowInCompact = null;
@@ -3788,8 +4025,10 @@
         }
 
         /**
-         * Request up to 2 actions (by index in the order of addition) to be shown in the compact
+         * Request up to 3 actions (by index in the order of addition) to be shown in the compact
          * notification view.
+         *
+         * @param actions the indices of the actions to show in the compact notification view
          */
         public MediaStyle setShowActionsInCompactView(int...actions) {
             mActionsToShowInCompact = actions;
@@ -3866,6 +4105,9 @@
             RemoteViews button = new RemoteViews(mBuilder.mContext.getPackageName(),
                     R.layout.notification_material_media_action);
             button.setImageViewResource(R.id.action0, action.icon);
+            button.setDrawableParameters(R.id.action0, false, -1,
+                    0xFFFFFFFF,
+                    PorterDuff.Mode.SRC_ATOP, -1);
             if (!tombstone) {
                 button.setOnClickPendingIntent(R.id.action0, action.actionIntent);
             }
@@ -3875,14 +4117,14 @@
 
         private RemoteViews makeMediaContentView() {
             RemoteViews view = mBuilder.applyStandardTemplate(
-                    R.layout.notification_template_material_media, true /* 1U */);
+                    R.layout.notification_template_material_media, false /* hasProgress */);
 
             final int numActions = mBuilder.mActions.size();
             final int N = mActionsToShowInCompact == null
                     ? 0
                     : Math.min(mActionsToShowInCompact.length, MAX_MEDIA_BUTTONS_IN_COMPACT);
             if (N > 0) {
-                view.removeAllViews(R.id.actions);
+                view.removeAllViews(com.android.internal.R.id.media_actions);
                 for (int i = 0; i < N; i++) {
                     if (i >= numActions) {
                         throw new IllegalArgumentException(String.format(
@@ -3892,26 +4134,73 @@
 
                     final Action action = mBuilder.mActions.get(mActionsToShowInCompact[i]);
                     final RemoteViews button = generateMediaActionButton(action);
-                    view.addView(R.id.actions, button);
+                    view.addView(com.android.internal.R.id.media_actions, button);
                 }
             }
+            styleText(view);
+            hideRightIcon(view);
             return view;
         }
 
         private RemoteViews makeMediaBigContentView() {
-            RemoteViews big = mBuilder.applyStandardTemplate(
-                    R.layout.notification_template_material_big_media, false);
+            final int actionCount = Math.min(mBuilder.mActions.size(), MAX_MEDIA_BUTTONS);
+            RemoteViews big = mBuilder.applyStandardTemplate(getBigLayoutResource(actionCount),
+                    false /* hasProgress */);
 
-            final int N = Math.min(mBuilder.mActions.size(), MAX_MEDIA_BUTTONS);
-            if (N > 0) {
-                big.removeAllViews(R.id.actions);
-                for (int i=0; i<N; i++) {
+            if (actionCount > 0) {
+                big.removeAllViews(com.android.internal.R.id.media_actions);
+                for (int i = 0; i < actionCount; i++) {
                     final RemoteViews button = generateMediaActionButton(mBuilder.mActions.get(i));
-                    big.addView(R.id.actions, button);
+                    big.addView(com.android.internal.R.id.media_actions, button);
                 }
             }
+            styleText(big);
+            hideRightIcon(big);
+            applyTopPadding(big);
+            big.setViewVisibility(android.R.id.progress, View.GONE);
             return big;
         }
+
+        private int getBigLayoutResource(int actionCount) {
+            if (actionCount <= 3) {
+                return R.layout.notification_template_material_big_media_narrow;
+            } else {
+                return R.layout.notification_template_material_big_media;
+            }
+        }
+
+        private void hideRightIcon(RemoteViews contentView) {
+            contentView.setViewVisibility(R.id.right_icon, View.GONE);
+        }
+
+        /**
+         * Applies the special text colors for media notifications to all text views.
+         */
+        private void styleText(RemoteViews contentView) {
+            int primaryColor = mBuilder.mContext.getResources().getColor(
+                    R.color.notification_media_primary_color);
+            int secondaryColor = mBuilder.mContext.getResources().getColor(
+                    R.color.notification_media_secondary_color);
+            contentView.setTextColor(R.id.title, primaryColor);
+            if (mBuilder.showsTimeOrChronometer()) {
+                if (mBuilder.mUseChronometer) {
+                    contentView.setTextColor(R.id.chronometer, secondaryColor);
+                } else {
+                    contentView.setTextColor(R.id.time, secondaryColor);
+                }
+            }
+            contentView.setTextColor(R.id.text2, secondaryColor);
+            contentView.setTextColor(R.id.text, secondaryColor);
+            contentView.setTextColor(R.id.info, secondaryColor);
+        }
+
+        /**
+         * @hide
+         */
+        @Override
+        protected boolean hasProgress() {
+            return false;
+        }
     }
 
     // When adding a new Style subclass here, don't forget to update
@@ -4590,8 +4879,8 @@
             super(parcel);
         }
 
-        public BuilderRemoteViews(String packageName, int userId, int layoutId) {
-            super(packageName, userId, layoutId);
+        public BuilderRemoteViews(ApplicationInfo appInfo, int layoutId) {
+            super(appInfo, layoutId);
         }
 
         @Override
diff --git a/core/java/android/app/NotificationManager.java b/core/java/android/app/NotificationManager.java
index bd9363d..7dc1ad64 100644
--- a/core/java/android/app/NotificationManager.java
+++ b/core/java/android/app/NotificationManager.java
@@ -16,8 +16,11 @@
 
 package android.app;
 
+import android.annotation.SdkConstant;
 import android.app.Notification.Builder;
+import android.content.ComponentName;
 import android.content.Context;
+import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
 import android.os.RemoteException;
@@ -72,6 +75,16 @@
     private static String TAG = "NotificationManager";
     private static boolean localLOGV = false;
 
+    /**
+     * Intent that is broadcast when the state of {@link #getEffectsSuppressor()} changes.
+     * This broadcast is only sent to registered receivers.
+     *
+     * @hide
+     */
+    @SdkConstant(SdkConstant.SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_EFFECTS_SUPPRESSOR_CHANGED
+            = "android.os.action.ACTION_EFFECTS_SUPPRESSOR_CHANGED";
+
     private static INotificationManager sService;
 
     /** @hide */
@@ -227,5 +240,29 @@
         }
     }
 
+    /**
+     * @hide
+     */
+    public ComponentName getEffectsSuppressor() {
+        INotificationManager service = getService();
+        try {
+            return service.getEffectsSuppressor();
+        } catch (RemoteException e) {
+            return null;
+        }
+    }
+
+    /**
+     * @hide
+     */
+    public boolean matchesCallFilter(Bundle extras) {
+        INotificationManager service = getService();
+        try {
+            return service.matchesCallFilter(extras);
+        } catch (RemoteException e) {
+            return false;
+        }
+    }
+
     private Context mContext;
 }
diff --git a/core/java/android/app/ProfilerInfo.java b/core/java/android/app/ProfilerInfo.java
new file mode 100644
index 0000000..cea7c3c
--- /dev/null
+++ b/core/java/android/app/ProfilerInfo.java
@@ -0,0 +1,86 @@
+/*
+ * Copyright (C) 2014 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 android.app;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.os.ParcelFileDescriptor;
+
+/**
+ * System private API for passing profiler settings.
+ *
+ * {@hide}
+ */
+public class ProfilerInfo implements Parcelable {
+
+    /* Name of profile output file. */
+    public final String profileFile;
+
+    /* File descriptor for profile output file, can be null. */
+    public ParcelFileDescriptor profileFd;
+
+    /* Indicates sample profiling when nonzero, interval in microseconds. */
+    public final int samplingInterval;
+
+    /* Automatically stop the profiler when the app goes idle. */
+    public final boolean autoStopProfiler;
+
+    public ProfilerInfo(String filename, ParcelFileDescriptor fd, int interval, boolean autoStop) {
+        profileFile = filename;
+        profileFd = fd;
+        samplingInterval = interval;
+        autoStopProfiler = autoStop;
+    }
+
+    public int describeContents() {
+        if (profileFd != null) {
+            return profileFd.describeContents();
+        } else {
+            return 0;
+        }
+    }
+
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeString(profileFile);
+        if (profileFd != null) {
+            out.writeInt(1);
+            profileFd.writeToParcel(out, flags);
+        } else {
+            out.writeInt(0);
+        }
+        out.writeInt(samplingInterval);
+        out.writeInt(autoStopProfiler ? 1 : 0);
+    }
+
+    public static final Parcelable.Creator<ProfilerInfo> CREATOR =
+            new Parcelable.Creator<ProfilerInfo>() {
+        public ProfilerInfo createFromParcel(Parcel in) {
+            return new ProfilerInfo(in);
+        }
+
+        public ProfilerInfo[] newArray(int size) {
+            return new ProfilerInfo[size];
+        }
+    };
+
+    private ProfilerInfo(Parcel in) {
+        profileFile = in.readString();
+        profileFd = in.readInt() != 0 ? ParcelFileDescriptor.CREATOR.createFromParcel(in) : null;
+        samplingInterval = in.readInt();
+        autoStopProfiler = in.readInt() != 0;
+    }
+}
diff --git a/core/java/android/app/ResourcesManager.java b/core/java/android/app/ResourcesManager.java
index 3c13115..1691d8e 100644
--- a/core/java/android/app/ResourcesManager.java
+++ b/core/java/android/app/ResourcesManager.java
@@ -178,8 +178,13 @@
         //}
 
         AssetManager assets = new AssetManager();
-        if (assets.addAssetPath(resDir) == 0) {
-            return null;
+        // resDir can be null if the 'android' package is creating a new Resources object.
+        // This is fine, since each AssetManager automatically loads the 'android' package
+        // already.
+        if (resDir != null) {
+            if (assets.addAssetPath(resDir) == 0) {
+                return null;
+            }
         }
 
         if (splitResDirs != null) {
diff --git a/core/java/android/app/SharedElementCallback.java b/core/java/android/app/SharedElementCallback.java
new file mode 100644
index 0000000..060bbe6
--- /dev/null
+++ b/core/java/android/app/SharedElementCallback.java
@@ -0,0 +1,180 @@
+/*
+ * Copyright (C) 2014 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 android.app;
+
+import android.content.Context;
+import android.content.res.Resources;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Matrix;
+import android.graphics.RectF;
+import android.graphics.drawable.BitmapDrawable;
+import android.os.Parcelable;
+import android.transition.TransitionUtils;
+import android.view.View;
+
+import java.util.List;
+import java.util.Map;
+
+/**
+ * Listener provided in
+ * {@link Activity#setEnterSharedElementCallback(SharedElementCallback)} and
+ * {@link Activity#setExitSharedElementCallback(SharedElementCallback)} as well as
+ * {@link Fragment#setEnterSharedElementCallback(SharedElementCallback)} and
+ * {@link Fragment#setExitSharedElementCallback(SharedElementCallback)}
+ * to monitor the Shared element transitions. The events can be used to customize Activity
+ * and Fragment Transition behavior.
+ */
+public abstract class SharedElementCallback {
+    private Matrix mTempMatrix;
+
+    static final SharedElementCallback NULL_CALLBACK = new SharedElementCallback() {
+    };
+
+    /**
+     * Called immediately after the start state is set for the shared element.
+     * The shared element will start at the size and position of the shared element
+     * in the launching Activity or Fragment.
+     *
+     * @param sharedElementNames The names of the shared elements that were accepted into
+     *                           the View hierarchy.
+     * @param sharedElements The shared elements that are part of the View hierarchy.
+     * @param sharedElementSnapshots The Views containing snap shots of the shared element
+     *                               from the launching Window. These elements will not
+     *                               be part of the scene, but will be positioned relative
+     *                               to the Window decor View. This list is null for Fragment
+     *                               Transitions.
+     */
+    public void onSharedElementStart(List<String> sharedElementNames,
+            List<View> sharedElements, List<View> sharedElementSnapshots) {}
+
+    /**
+     * Called after the end state is set for the shared element, but before the end state
+     * is captured by the shared element transition.
+     * <p>
+     *     Any customization done in
+     *     {@link #onSharedElementStart(java.util.List, java.util.List, java.util.List)}
+     *     may need to be modified to the final state of the shared element if it is not
+     *     automatically corrected by layout. For example, rotation or scale will not
+     *     be affected by layout and if changed in {@link #onSharedElementStart(java.util.List,
+     *     java.util.List, java.util.List)}, it will also have to be set here again to correct
+     *     the end state.
+     * </p>
+     *
+     * @param sharedElementNames The names of the shared elements that were accepted into
+     *                           the View hierarchy.
+     * @param sharedElements The shared elements that are part of the View hierarchy.
+     * @param sharedElementSnapshots The Views containing snap shots of the shared element
+     *                               from the launching Window. These elements will not
+     *                               be part of the scene, but will be positioned relative
+     *                               to the Window decor View. This list will be null for
+     *                               Fragment Transitions.
+     */
+    public void onSharedElementEnd(List<String> sharedElementNames,
+            List<View> sharedElements, List<View> sharedElementSnapshots) {}
+
+    /**
+     * Called after {@link #onMapSharedElements(java.util.List, java.util.Map)} when
+     * transferring shared elements in. Any shared elements that have no mapping will be in
+     * <var>rejectedSharedElements</var>. The elements remaining in
+     * <var>rejectedSharedElements</var> will be transitioned out of the Scene. If a
+     * View is removed from <var>rejectedSharedElements</var>, it must be handled by the
+     * <code>SharedElementCallback</code>.
+     * <p>
+     * Views in rejectedSharedElements will have their position and size set to the
+     * position of the calling shared element, relative to the Window decor View and contain
+     * snapshots of the View from the calling Activity or Fragment. This
+     * view may be safely added to the decor View's overlay to remain in position.
+     * </p>
+     * <p>This method is not called for Fragment Transitions. All rejected shared elements
+     * will be handled by the exit transition.</p>
+     *
+     * @param rejectedSharedElements Views containing visual information of shared elements
+     *                               that are not part of the entering scene. These Views
+     *                               are positioned relative to the Window decor View. A
+     *                               View removed from this list will not be transitioned
+     *                               automatically.
+     */
+    public void onRejectSharedElements(List<View> rejectedSharedElements) {}
+
+    /**
+     * Lets the SharedElementCallback adjust the mapping of shared element names to
+     * Views.
+     *
+     * @param names The names of all shared elements transferred from the calling Activity
+     *              or Fragment in the order they were provided.
+     * @param sharedElements The mapping of shared element names to Views. The best guess
+     *                       will be filled into sharedElements based on the transitionNames.
+     */
+    public void onMapSharedElements(List<String> names, Map<String, View> sharedElements) {}
+
+    /**
+     * Creates a snapshot of a shared element to be used by the remote Activity and reconstituted
+     * with {@link #onCreateSnapshotView(android.content.Context, android.os.Parcelable)}. A
+     * null return value will mean that the remote Activity will have a null snapshot View in
+     * {@link #onSharedElementStart(java.util.List, java.util.List, java.util.List)} and
+     * {@link #onSharedElementEnd(java.util.List, java.util.List, java.util.List)}.
+     *
+     * <p>This is not called for Fragment Transitions.</p>
+     *
+     * @param sharedElement The shared element View to create a snapshot for.
+     * @param viewToGlobalMatrix A matrix containing a transform from the view to the screen
+     *                           coordinates.
+     * @param screenBounds The bounds of shared element in screen coordinate space. This is
+     *                     the bounds of the view with the viewToGlobalMatrix applied.
+     * @return A snapshot to send to the remote Activity to be reconstituted with
+     * {@link #onCreateSnapshotView(android.content.Context, android.os.Parcelable)} and passed
+     * into {@link #onSharedElementStart(java.util.List, java.util.List, java.util.List)} and
+     * {@link #onSharedElementEnd(java.util.List, java.util.List, java.util.List)}.
+     */
+    public Parcelable onCaptureSharedElementSnapshot(View sharedElement, Matrix viewToGlobalMatrix,
+            RectF screenBounds) {
+        if (mTempMatrix == null) {
+            mTempMatrix = new Matrix(viewToGlobalMatrix);
+        } else {
+            mTempMatrix.set(viewToGlobalMatrix);
+        }
+        return TransitionUtils.createViewBitmap(sharedElement, mTempMatrix, screenBounds);
+    }
+
+    /**
+     * Reconstitutes a snapshot View from a Parcelable returned in
+     * {@link #onCaptureSharedElementSnapshot(android.view.View, android.graphics.Matrix,
+     * android.graphics.RectF)} to be used in {@link #onSharedElementStart(java.util.List,
+     * java.util.List, java.util.List)} and {@link #onSharedElementEnd(java.util.List,
+     * java.util.List, java.util.List)}. The returned View will be sized and positioned after
+     * this call so that it is ready to be added to the decor View's overlay.
+     *
+     * <p>This is not called for Fragment Transitions.</p>
+     *
+     * @param context The Context used to create the snapshot View.
+     * @param snapshot The Parcelable returned by {@link #onCaptureSharedElementSnapshot(
+     * android.view.View, android.graphics.Matrix, android.graphics.RectF)}.
+     * @return A View to be sent in {@link #onSharedElementStart(java.util.List, java.util.List,
+     * java.util.List)} and {@link #onSharedElementEnd(java.util.List, java.util.List,
+     * java.util.List)}. A null value will produce a null snapshot value for those two methods.
+     */
+    public View onCreateSnapshotView(Context context, Parcelable snapshot) {
+        View view = null;
+        if (snapshot instanceof Bitmap) {
+            Bitmap bitmap = (Bitmap) snapshot;
+            view = new View(context);
+            Resources resources = context.getResources();
+            view.setBackground(new BitmapDrawable(resources, bitmap));
+        }
+        return view;
+    }
+}
diff --git a/core/java/android/app/SharedElementListener.java b/core/java/android/app/SharedElementListener.java
deleted file mode 100644
index f36d05f..0000000
--- a/core/java/android/app/SharedElementListener.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.app;
-
-import android.content.Context;
-import android.content.res.Resources;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Matrix;
-import android.graphics.RectF;
-import android.graphics.drawable.BitmapDrawable;
-import android.graphics.drawable.ColorDrawable;
-import android.os.Parcelable;
-import android.view.View;
-
-import java.util.List;
-import java.util.Map;
-
-/**
- * Listener provided in
- * {@link Activity#setEnterSharedElementListener(SharedElementListener)} and
- * {@link Activity#setExitSharedElementListener(SharedElementListener)}
- * to monitor the Activity transitions. The events can be used to customize Activity
- * Transition behavior.
- */
-public abstract class SharedElementListener {
-    private Matrix mTempMatrix;
-
-    static final SharedElementListener NULL_LISTENER = new SharedElementListener() {
-    };
-
-    /**
-     * Called to allow the listener to customize the start state of the shared element when
-     * transferring in shared element state.
-     * <p>
-     *     The shared element will start at the size and position of the shared element
-     *     in the launching Activity or Fragment. It will also transfer ImageView scaleType
-     *     and imageMatrix if the shared elements in the calling and called Activities are
-     *     ImageViews. Some applications may want to make additional changes, such as
-     *     changing the clip bounds, scaling, or rotation if the shared element end state
-     *     does not map well to the start state.
-     * </p>
-     *
-     * @param sharedElementNames The names of the shared elements that were accepted into
-     *                           the View hierarchy.
-     * @param sharedElements The shared elements that are part of the View hierarchy.
-     * @param sharedElementSnapshots The Views containing snap shots of the shared element
-     *                               from the launching Window. These elements will not
-     *                               be part of the scene, but will be positioned relative
-     *                               to the Window decor View.
-     */
-    public void setSharedElementStart(List<String> sharedElementNames,
-            List<View> sharedElements, List<View> sharedElementSnapshots) {}
-
-    /**
-     * Called to allow the listener to customize the end state of the shared element when
-     * transferring in shared element state.
-     * <p>
-     *     Any customization done in
-     *     {@link #setSharedElementStart(java.util.List, java.util.List, java.util.List)}
-     *     may need to be modified to the final state of the shared element if it is not
-     *     automatically corrected by layout. For example, rotation or scale will not
-     *     be affected by layout and if changed in {@link #setSharedElementStart(java.util.List,
-     *     java.util.List, java.util.List)}, it will also have to be set here again to correct
-     *     the end state.
-     * </p>
-     *
-     * @param sharedElementNames The names of the shared elements that were accepted into
-     *                           the View hierarchy.
-     * @param sharedElements The shared elements that are part of the View hierarchy.
-     * @param sharedElementSnapshots The Views containing snap shots of the shared element
-     *                               from the launching Window. These elements will not
-     *                               be part of the scene, but will be positioned relative
-     *                               to the Window decor View.
-     */
-    public void setSharedElementEnd(List<String> sharedElementNames,
-            List<View> sharedElements, List<View> sharedElementSnapshots) {}
-
-    /**
-     * Called after {@link #remapSharedElements(java.util.List, java.util.Map)} when
-     * transferring shared elements in. Any shared elements that have no mapping will be in
-     * <var>rejectedSharedElements</var>. The elements remaining in
-     * <var>rejectedSharedElements</var> will be transitioned out of the Scene. If a
-     * View is removed from <var>rejectedSharedElements</var>, it must be handled by the
-     * <code>SharedElementListener</code>.
-     * <p>
-     * Views in rejectedSharedElements will have their position and size set to the
-     * position of the calling shared element, relative to the Window decor View and contain
-     * snapshots of the View from the calling Activity or Fragment. This
-     * view may be safely added to the decor View's overlay to remain in position.
-     * </p>
-     *
-     * @param rejectedSharedElements Views containing visual information of shared elements
-     *                               that are not part of the entering scene. These Views
-     *                               are positioned relative to the Window decor View. A
-     *                               View removed from this list will not be transitioned
-     *                               automatically.
-     */
-    public void handleRejectedSharedElements(List<View> rejectedSharedElements) {}
-
-    /**
-     * Lets the ActivityTransitionListener adjust the mapping of shared element names to
-     * Views.
-     *
-     * @param names The names of all shared elements transferred from the calling Activity
-     *              to the started Activity.
-     * @param sharedElements The mapping of shared element names to Views. The best guess
-     *                       will be filled into sharedElements based on the transitionNames.
-     */
-    public void remapSharedElements(List<String> names, Map<String, View> sharedElements) {}
-
-    /**
-     * Creates a snapshot of a shared element to be used by the remote Activity and reconstituted
-     * with {@link #createSnapshotView(android.content.Context, android.os.Parcelable)}. A
-     * null return value will mean that the remote Activity will have a null snapshot View in
-     * {@link #setSharedElementStart(java.util.List, java.util.List, java.util.List)} and
-     * {@link #setSharedElementEnd(java.util.List, java.util.List, java.util.List)}.
-     *
-     * @param sharedElement The shared element View to create a snapshot for.
-     * @param viewToGlobalMatrix A matrix containing a transform from the view to the screen
-     *                           coordinates.
-     * @param screenBounds The bounds of shared element in screen coordinate space. This is
-     *                     the bounds of the view with the viewToGlobalMatrix applied.
-     * @return A snapshot to send to the remote Activity to be reconstituted with
-     * {@link #createSnapshotView(android.content.Context, android.os.Parcelable)} and passed
-     * into {@link #setSharedElementStart(java.util.List, java.util.List, java.util.List)} and
-     * {@link #setSharedElementEnd(java.util.List, java.util.List, java.util.List)}.
-     */
-    public Parcelable captureSharedElementSnapshot(View sharedElement, Matrix viewToGlobalMatrix,
-            RectF screenBounds) {
-        int bitmapWidth = Math.round(screenBounds.width());
-        int bitmapHeight = Math.round(screenBounds.height());
-        Bitmap bitmap = null;
-        if (bitmapWidth > 0 && bitmapHeight > 0) {
-            if (mTempMatrix == null) {
-                mTempMatrix = new Matrix();
-            }
-            mTempMatrix.set(viewToGlobalMatrix);
-            mTempMatrix.postTranslate(-screenBounds.left, -screenBounds.top);
-            bitmap = Bitmap.createBitmap(bitmapWidth, bitmapHeight, Bitmap.Config.ARGB_8888);
-            Canvas canvas = new Canvas(bitmap);
-            canvas.concat(mTempMatrix);
-            sharedElement.draw(canvas);
-        }
-        return bitmap;
-    }
-
-    /**
-     * Reconstitutes a snapshot View from a Parcelable returned in
-     * {@link #captureSharedElementSnapshot(android.view.View, android.graphics.Matrix,
-     * android.graphics.RectF)} to be used in {@link #setSharedElementStart(java.util.List,
-     * java.util.List, java.util.List)} and {@link #setSharedElementEnd(java.util.List,
-     * java.util.List, java.util.List)}. The returned View will be sized and positioned after
-     * this call so that it is ready to be added to the decor View's overlay.
-     *
-     * @param context The Context used to create the snapshot View.
-     * @param snapshot The Parcelable returned by {@link #captureSharedElementSnapshot(
-     * android.view.View, android.graphics.Matrix, android.graphics.RectF)}.
-     * @return A View to be sent in {@link #setSharedElementStart(java.util.List, java.util.List,
-     * java.util.List)} and {@link #setSharedElementEnd(java.util.List, java.util.List,
-     * java.util.List)}. A null value will produce a null snapshot value for those two methods.
-     */
-    public View createSnapshotView(Context context, Parcelable snapshot) {
-        View view = null;
-        if (snapshot instanceof Bitmap) {
-            Bitmap bitmap = (Bitmap) snapshot;
-            view = new View(context);
-            Resources resources = context.getResources();
-            view.setBackground(new BitmapDrawable(resources, bitmap));
-        }
-        return view;
-    }
-}
diff --git a/core/java/android/app/TimePickerDialog.java b/core/java/android/app/TimePickerDialog.java
index 697c5d8..6454367 100644
--- a/core/java/android/app/TimePickerDialog.java
+++ b/core/java/android/app/TimePickerDialog.java
@@ -110,6 +110,7 @@
         setView(view);
         setButton(BUTTON_POSITIVE, themeContext.getString(R.string.ok), this);
         setButton(BUTTON_NEGATIVE, themeContext.getString(R.string.cancel), this);
+        setButtonPanelLayoutHint(LAYOUT_HINT_SIDE);
 
         mTimePicker = (TimePicker) view.findViewById(R.id.timePicker);
         mTimePicker.setIs24HourView(mIs24HourView);
diff --git a/core/java/android/app/VoiceInteractor.java b/core/java/android/app/VoiceInteractor.java
index dcdfd78..723cb9b 100644
--- a/core/java/android/app/VoiceInteractor.java
+++ b/core/java/android/app/VoiceInteractor.java
@@ -16,6 +16,7 @@
 
 package android.app;
 
+import android.annotation.SystemApi;
 import android.content.Context;
 import android.os.Bundle;
 import android.os.IBinder;
@@ -33,6 +34,7 @@
 import java.util.ArrayList;
 
 /**
+ * @hide
  * Interface for an {@link Activity} to interact with the user through voice.  Use
  * {@link android.app.Activity#getVoiceInteractor() Activity.getVoiceInteractor}
  * to retrieve the interface, if the activity is currently involved in a voice interaction.
@@ -54,6 +56,7 @@
  * request, rather than holding on to the activity instance yourself, either explicitly
  * or implicitly through a non-static inner class.
  */
+@SystemApi
 public class VoiceInteractor {
     static final String TAG = "VoiceInteractor";
     static final boolean DEBUG = true;
diff --git a/core/java/android/app/WallpaperManager.java b/core/java/android/app/WallpaperManager.java
index 48ff5b6..8bfe6d3 100644
--- a/core/java/android/app/WallpaperManager.java
+++ b/core/java/android/app/WallpaperManager.java
@@ -16,6 +16,7 @@
 
 package android.app;
 
+import android.annotation.SystemApi;
 import android.content.ComponentName;
 import android.content.ContentResolver;
 import android.content.Context;
@@ -951,6 +952,48 @@
     }
 
     /**
+     * Specify extra padding that the wallpaper should have outside of the display.
+     * That is, the given padding supplies additional pixels the wallpaper should extend
+     * outside of the display itself.
+     * @param padding The number of pixels the wallpaper should extend beyond the display,
+     * on its left, top, right, and bottom sides.
+     * @hide
+     */
+    @SystemApi
+    public void setDisplayPadding(Rect padding) {
+        try {
+            if (sGlobals.mService == null) {
+                Log.w(TAG, "WallpaperService not running");
+            } else {
+                sGlobals.mService.setDisplayPadding(padding);
+            }
+        } catch (RemoteException e) {
+            // Ignore
+        }
+    }
+
+    /**
+     * Apply a raw offset to the wallpaper window.  Should only be used in
+     * combination with {@link #setDisplayPadding(android.graphics.Rect)} when you
+     * have ensured that the wallpaper will extend outside of the display area so that
+     * it can be moved without leaving part of the display uncovered.
+     * @param x The offset, in pixels, to apply to the left edge.
+     * @param y The offset, in pixels, to apply to the top edge.
+     * @hide
+     */
+    @SystemApi
+    public void setDisplayOffset(IBinder windowToken, int x, int y) {
+        try {
+            //Log.v(TAG, "Sending new wallpaper display offsets from app...");
+            WindowManagerGlobal.getWindowSession().setWallpaperDisplayOffset(
+                    windowToken, x, y);
+            //Log.v(TAG, "...app returning after sending display offset!");
+        } catch (RemoteException e) {
+            // Ignore.
+        }
+    }
+
+    /**
      * Set the position of the current wallpaper within any larger space, when
      * that wallpaper is visible behind the given window.  The X and Y offsets
      * are floating point numbers ranging from 0 to 1, representing where the
diff --git a/core/java/android/app/admin/DeviceAdminReceiver.java b/core/java/android/app/admin/DeviceAdminReceiver.java
index 15def09..e9cce51 100644
--- a/core/java/android/app/admin/DeviceAdminReceiver.java
+++ b/core/java/android/app/admin/DeviceAdminReceiver.java
@@ -177,7 +177,7 @@
      */
     @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
     public static final String ACTION_LOCK_TASK_ENTERING
-            = "android.app.action.ACTION_LOCK_TASK_ENTERING";
+            = "android.app.action.LOCK_TASK_ENTERING";
 
     /**
      * Action sent to a device administrator to notify that the device is exiting
@@ -190,7 +190,7 @@
      */
     @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
     public static final String ACTION_LOCK_TASK_EXITING
-            = "android.app.action.ACTION_LOCK_TASK_EXITING";
+            = "android.app.action.LOCK_TASK_EXITING";
 
     /**
      * A boolean describing whether the device is currently entering or exiting
@@ -221,7 +221,7 @@
      */
     @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
     public static final String ACTION_PROFILE_PROVISIONING_COMPLETE =
-            "android.app.action.ACTION_PROFILE_PROVISIONING_COMPLETE";
+            "android.app.action.PROFILE_PROVISIONING_COMPLETE";
 
     /**
      * Name under which a DevicePolicy component publishes information
diff --git a/core/java/android/app/admin/DevicePolicyManager.java b/core/java/android/app/admin/DevicePolicyManager.java
index f3f0c4d..13ed8d1 100644
--- a/core/java/android/app/admin/DevicePolicyManager.java
+++ b/core/java/android/app/admin/DevicePolicyManager.java
@@ -21,7 +21,6 @@
 import android.annotation.SystemApi;
 import android.app.Activity;
 import android.app.admin.IDevicePolicyManager;
-import android.content.AbstractRestrictionsProvider;
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
@@ -39,6 +38,8 @@
 import android.os.UserHandle;
 import android.os.UserManager;
 import android.provider.Settings;
+import android.security.Credentials;
+import android.service.restrictions.RestrictionsReceiver;
 import android.util.Log;
 
 import com.android.org.conscrypt.TrustedCertificateStore;
@@ -49,13 +50,14 @@
 import java.io.IOException;
 import java.net.InetSocketAddress;
 import java.net.Proxy;
+import java.security.PrivateKey;
+import java.security.cert.Certificate;
 import java.security.cert.CertificateException;
 import java.security.cert.CertificateFactory;
 import java.security.cert.X509Certificate;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
-import java.util.Set;
 
 /**
  * Public interface for managing policies enforced on a device.  Most clients
@@ -98,8 +100,7 @@
      * Provisioning adds a managed profile and sets the mdm as the profile owner who has full
      * control over the profile
      *
-     * <p>This intent must contain the extras {@link #EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME}
-     * {@link #EXTRA_PROVISIONING_DEFAULT_MANAGED_PROFILE_NAME} and {@link #EXTRA_DEVICE_ADMIN}.
+     * <p>This intent must contain the extra {@link #EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME}.
      *
      * <p> When managed provisioning has completed, an intent of the type
      * {@link DeviceAdminReceiver#ACTION_PROFILE_PROVISIONING_COMPLETE} is broadcasted to the
@@ -113,7 +114,20 @@
      */
     @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
     public static final String ACTION_PROVISION_MANAGED_PROFILE
-        = "android.app.action.ACTION_PROVISION_MANAGED_PROFILE";
+        = "android.app.action.PROVISION_MANAGED_PROFILE";
+
+    /**
+     * A {@link android.os.Parcelable} extra of type {@link android.os.PersistableBundle} that allows
+     * a mobile device management application that starts managed profile provisioning to pass data
+     * to itself on the managed profile when provisioning completes. The mobile device management
+     * application sends this extra in an intent with the action
+     * {@link #ACTION_PROVISION_MANAGED_PROFILE} and receives it in
+     * {@link DeviceAdminReceiver#onProfileProvisioningComplete} via an intent with the action
+     * {@link DeviceAdminReceiver#ACTION_PROFILE_PROVISIONING_COMPLETE}. The bundle is not changed
+     * during the managed profile provisioning.
+     */
+    public static final String EXTRA_PROVISIONING_ADMIN_EXTRAS_BUNDLE =
+            "android.app.extra.PROVISIONING_ADMIN_EXTRAS_BUNDLE";
 
     /**
      * A String extra holding the package name of the mobile device management application that
@@ -124,25 +138,18 @@
      * application that started provisioning. The package will be set as profile owner in that case.
      *
      * <p>This package is set as device owner when device owner provisioning is started by an Nfc
-     * message containing an Nfc record with MIME type {@link #PROVISIONING_NFC_MIME_TYPE}.
+     * message containing an Nfc record with MIME type {@link #MIME_TYPE_PROVISIONING_NFC}.
      */
     public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME
-        = "android.app.extra.deviceAdminPackageName";
-
-    /**
-     * A String extra holding the default name of the profile that is created during managed profile
-     * provisioning.
-     *
-     * <p>Use with {@link #ACTION_PROVISION_MANAGED_PROFILE}
-     */
-    public static final String EXTRA_PROVISIONING_DEFAULT_MANAGED_PROFILE_NAME
-        = "android.app.extra.defaultManagedProfileName";
+        = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_NAME";
 
     /**
      * A String extra that, holds the email address of the account which a managed profile is
      * created for. Used with {@link #ACTION_PROVISION_MANAGED_PROFILE} and
      * {@link DeviceAdminReceiver#ACTION_PROFILE_PROVISIONING_COMPLETE}.
      *
+     * <p> This extra is part of the {@link #EXTRA_PROVISIONING_ADMIN_EXTRAS_BUNDLE}.
+     *
      * <p> If the {@link #ACTION_PROVISION_MANAGED_PROFILE} intent that starts managed provisioning
      * contains this extra, it is forwarded in the
      * {@link DeviceAdminReceiver#ACTION_PROFILE_PROVISIONING_COMPLETE} intent to the mobile
@@ -150,137 +157,137 @@
      * It is usually used to avoid that the user has to enter their email address twice.
      */
     public static final String EXTRA_PROVISIONING_EMAIL_ADDRESS
-        = "android.app.extra.ManagedProfileEmailAddress";
+        = "android.app.extra.PROVISIONING_EMAIL_ADDRESS";
 
     /**
      * A String extra holding the time zone {@link android.app.AlarmManager} that the device
      * will be set to.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_TIME_ZONE
-        = "android.app.extra.timeZone";
+        = "android.app.extra.PROVISIONING_TIME_ZONE";
 
     /**
-     * A Long extra holding the local time {@link android.app.AlarmManager} that the device
-     * will be set to.
+     * A Long extra holding the wall clock time (in milliseconds) to be set on the device's
+     * {@link android.app.AlarmManager}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_LOCAL_TIME
-        = "android.app.extra.localTime";
+        = "android.app.extra.PROVISIONING_LOCAL_TIME";
 
     /**
      * A String extra holding the {@link java.util.Locale} that the device will be set to.
      * Format: xx_yy, where xx is the language code, and yy the country code.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_LOCALE
-        = "android.app.extra.locale";
+        = "android.app.extra.PROVISIONING_LOCALE";
 
     /**
      * A String extra holding the ssid of the wifi network that should be used during nfc device
      * owner provisioning for downloading the mobile device management application.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_SSID
-        = "android.app.extra.wifiSsid";
+        = "android.app.extra.PROVISIONING_WIFI_SSID";
 
     /**
      * A boolean extra indicating whether the wifi network in {@link #EXTRA_PROVISIONING_WIFI_SSID}
      * is hidden or not.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_HIDDEN
-        = "android.app.extra.wifiHidden";
+        = "android.app.extra.PROVISIONING_WIFI_HIDDEN";
 
     /**
      * A String extra indicating the security type of the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_SECURITY_TYPE
-        = "android.app.extra.wifiSecurityType";
+        = "android.app.extra.PROVISIONING_WIFI_SECURITY_TYPE";
 
     /**
      * A String extra holding the password of the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_PASSWORD
-        = "android.app.extra.wifiPassword";
+        = "android.app.extra.PROVISIONING_WIFI_PASSWORD";
 
     /**
      * A String extra holding the proxy host for the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_PROXY_HOST
-        = "android.app.extra.wifiProxyHost";
+        = "android.app.extra.PROVISIONING_WIFI_PROXY_HOST";
 
     /**
      * An int extra holding the proxy port for the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_PROXY_PORT
-        = "android.app.extra.wifiProxyPort";
+        = "android.app.extra.PROVISIONING_WIFI_PROXY_PORT";
 
     /**
      * A String extra holding the proxy bypass for the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_PROXY_BYPASS
-        = "android.app.extra.wifiProxyBypassHosts";
+        = "android.app.extra.PROVISIONING_WIFI_PROXY_BYPASS";
 
     /**
      * A String extra holding the proxy auto-config (PAC) URL for the wifi network in
      * {@link #EXTRA_PROVISIONING_WIFI_SSID}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_WIFI_PAC_URL
-        = "android.app.extra.wifiPacUrl";
+        = "android.app.extra.PROVISIONING_WIFI_PAC_URL";
 
     /**
      * A String extra holding a url that specifies the download location of the device admin
      * package. When not provided it is assumed that the device admin package is already installed.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION
-        = "android.app.extra.deviceAdminPackageDownloadLocation";
+        = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION";
 
     /**
      * A String extra holding a http cookie header which should be used in the http request to the
      * url specified in {@link #EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_LOCATION}.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_COOKIE_HEADER
-        = "android.app.extra.deviceAdminPackageDownloadCookieHeader";
+        = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_DOWNLOAD_COOKIE_HEADER";
 
     /**
      * A String extra holding the SHA-1 checksum of the file at download location specified in
@@ -288,11 +295,11 @@
      * the file at the download location an error will be shown to the user and the user will be
      * asked to factory reset the device.
      *
-     * <p>Use in an Nfc record with {@link #PROVISIONING_NFC_MIME_TYPE} that starts device owner
+     * <p>Use in an Nfc record with {@link #MIME_TYPE_PROVISIONING_NFC} that starts device owner
      * provisioning via an Nfc bump.
      */
     public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_CHECKSUM
-        = "android.app.extra.deviceAdminPackageChecksum";
+        = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_CHECKSUM";
 
     /**
      * This MIME type is used for starting the Device Owner provisioning.
@@ -336,7 +343,7 @@
      * <p>Input: Nothing.</p>
      * <p>Output: Nothing</p>
      */
-    public static final String PROVISIONING_NFC_MIME_TYPE
+    public static final String MIME_TYPE_PROVISIONING_NFC
         = "application/com.android.managedprovisioning";
 
     /**
@@ -435,13 +442,13 @@
      * Flag used by {@link #addCrossProfileIntentFilter} to allow access of certain intents from a
      * managed profile to its parent.
      */
-    public static int FLAG_PARENT_CAN_ACCESS_MANAGED = 0x0001;
+    public static final int FLAG_PARENT_CAN_ACCESS_MANAGED = 0x0001;
 
     /**
      * Flag used by {@link #addCrossProfileIntentFilter} to allow access of certain intents from the
      * parent to its managed profile.
      */
-    public static int FLAG_MANAGED_CAN_ACCESS_PARENT = 0x0002;
+    public static final int FLAG_MANAGED_CAN_ACCESS_PARENT = 0x0002;
 
     /**
      * Return true if the given administrator component is currently
@@ -1374,6 +1381,8 @@
      * and its profiles or a particular one.
      * @param admin The name of the admin component to check, or null to aggregate
      * all admins.
+     * @return time in milliseconds for the given admin or the minimum value (strictest) of
+     * all admins if admin is null. Returns 0 if there are no restrictions.
      */
     public long getMaximumTimeToLock(ComponentName admin) {
         return getMaximumTimeToLock(admin, UserHandle.myUserId());
@@ -1772,16 +1781,24 @@
      * If a user has installed any certificates by other means than device policy these will be
      * included too.
      *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @return a List of byte[] arrays, each encoding one user CA certificate.
      */
-    public List<byte[]> getInstalledCaCerts() {
-        final TrustedCertificateStore certStore = new TrustedCertificateStore();
+    public List<byte[]> getInstalledCaCerts(ComponentName admin) {
         List<byte[]> certs = new ArrayList<byte[]>();
-        for (String alias : certStore.userAliases()) {
+        if (mService != null) {
             try {
-                certs.add(certStore.getCertificate(alias).getEncoded());
-            } catch (CertificateException ce) {
-                Log.w(TAG, "Could not encode certificate: " + alias, ce);
+                mService.enforceCanManageCaCerts(admin);
+                final TrustedCertificateStore certStore = new TrustedCertificateStore();
+                for (String alias : certStore.userAliases()) {
+                    try {
+                        certs.add(certStore.getCertificate(alias).getEncoded());
+                    } catch (CertificateException ce) {
+                        Log.w(TAG, "Could not encode certificate: " + alias, ce);
+                    }
+                }
+            } catch (RemoteException re) {
+                Log.w(TAG, "Failed talking with device policy service", re);
             }
         }
         return certs;
@@ -1808,13 +1825,45 @@
     /**
      * Returns whether this certificate is installed as a trusted CA.
      *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param certBuffer encoded form of the certificate to look up.
      */
-    public boolean hasCaCertInstalled(byte[] certBuffer) {
+    public boolean hasCaCertInstalled(ComponentName admin, byte[] certBuffer) {
+        if (mService != null) {
+            try {
+                mService.enforceCanManageCaCerts(admin);
+                return getCaCertAlias(certBuffer) != null;
+            } catch (RemoteException re) {
+                Log.w(TAG, "Failed talking with device policy service", re);
+            } catch (CertificateException ce) {
+                Log.w(TAG, "Could not parse certificate", ce);
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Called by a device or profile owner to install a certificate and private key pair. The
+     * keypair will be visible to all apps within the profile.
+     *
+     * @param who Which {@link DeviceAdminReceiver} this request is associated with.
+     * @param privKey The private key to install.
+     * @param cert The certificate to install.
+     * @param alias The private key alias under which to install the certificate. If a certificate
+     * with that alias already exists, it will be overwritten.
+     * @return {@code true} if the keys were installed, {@code false} otherwise.
+     */
+    public boolean installKeyPair(ComponentName who, PrivateKey privKey, Certificate cert,
+            String alias) {
         try {
-            return getCaCertAlias(certBuffer) != null;
-        } catch (CertificateException ce) {
-            Log.w(TAG, "Could not parse certificate", ce);
+            final byte[] pemCert = Credentials.convertToPem(cert);
+            return mService.installKeyPair(who, privKey.getEncoded(), pemCert, alias);
+        } catch (CertificateException e) {
+            Log.w(TAG, "Error encoding certificate", e);
+        } catch (IOException e) {
+            Log.w(TAG, "Error writing certificate", e);
+        } catch (RemoteException e) {
+            Log.w(TAG, "Failed talking with device policy service", e);
         }
         return false;
     }
@@ -1875,12 +1924,16 @@
     }
 
     /**
-     * Called by a device/profile owner to set whether the screen capture is disabled.
+     * Called by a device/profile owner to set whether the screen capture is disabled. Disabling
+     * screen capture also prevents the content from being shown on display devices that do not have
+     * a secure video output. See {@link android.view.Display#FLAG_SECURE} for more details about
+     * secure surfaces and secure displays.
      *
      * <p>The calling device admin must be a device or profile owner. If it is not, a
      * security exception will be thrown.
      *
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @param disabled Whether screen capture is disabled or not.
      */
     public void setScreenCaptureDisabled(ComponentName admin, boolean disabled) {
         if (mService != null) {
@@ -1915,6 +1968,42 @@
     }
 
     /**
+     * Called by a device owner to set whether auto time is required. If auto time is
+     * required the user cannot set the date and time, but has to use network date and time.
+     *
+     * <p>Note: if auto time is required the user can still manually set the time zone.
+     *
+     * <p>The calling device admin must be a device owner. If it is not, a security exception will
+     * be thrown.
+     *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @param required Whether auto time is set required or not.
+     */
+    public void setAutoTimeRequired(ComponentName admin, boolean required) {
+        if (mService != null) {
+            try {
+                mService.setAutoTimeRequired(admin, UserHandle.myUserId(), required);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+    }
+
+    /**
+     * @return true if auto time is required.
+     */
+    public boolean getAutoTimeRequired() {
+        if (mService != null) {
+            try {
+                return mService.getAutoTimeRequired();
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return false;
+    }
+
+    /**
      * Called by an application that is administering the device to disable keyguard customizations,
      * such as widgets. After setting this, keyguard features will be disabled according to the
      * provided feature list.
@@ -2157,6 +2246,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public String getDeviceOwner() {
         if (mService != null) {
             try {
@@ -2365,6 +2455,7 @@
      * owner has been set for that user.
      * @throws IllegalArgumentException if the userId is invalid.
      */
+    @SystemApi
     public ComponentName getProfileOwner() throws IllegalArgumentException {
         return getProfileOwnerAsUser(Process.myUserHandle().getIdentifier());
     }
@@ -2406,6 +2497,27 @@
     }
 
     /**
+     * @hide
+     * @param user The user for whom to fetch the profile owner name, if any.
+     * @return the human readable name of the organisation associated with this profile owner or
+     *         null if one is not set.
+     * @throws IllegalArgumentException if the userId is invalid.
+     */
+    @SystemApi
+    public String getProfileOwnerNameAsUser(int userId) throws IllegalArgumentException {
+        if (mService != null) {
+            try {
+                return mService.getProfileOwnerName(userId);
+            } catch (RemoteException re) {
+                Log.w(TAG, "Failed to get profile owner");
+                throw new IllegalArgumentException(
+                        "Requested profile owner for invalid userId", re);
+            }
+        }
+        return null;
+    }
+
+    /**
      * Called by a profile owner or device owner to add a default intent handler activity for
      * intents that match a certain intent filter. This activity will remain the default intent
      * handler even if the set of potential event handlers for the intent filter changes and if
@@ -2498,6 +2610,7 @@
      * @param agent Which component to enable features for.
      * @param features List of features to enable. Consult specific TrustAgent documentation for
      * the feature list.
+     * @hide
      */
     public void setTrustAgentFeaturesEnabled(ComponentName admin, ComponentName agent,
             List<String> features) {
@@ -2518,6 +2631,7 @@
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param agent Which component to get enabled features for.
      * @return List of enabled features.
+     * @hide
      */
     public List<String> getTrustAgentFeaturesEnabled(ComponentName admin, ComponentName agent) {
         if (mService != null) {
@@ -2622,6 +2736,161 @@
     }
 
     /**
+     * Called by a profile or device owner to set the permitted accessibility services. When
+     * set by a device owner or profile owner the restriction applies to all profiles of the
+     * user the device owner or profile owner is an admin for.
+     *
+     * By default the user can use any accessiblity service. When zero or more packages have
+     * been added, accessiblity services that are not in the list and not part of the system
+     * can not be enabled by the user.
+     *
+     * <p> Calling with a null value for the list disables the restriction so that all services
+     * can be used, calling with an empty list only allows the builtin system's services.
+     *
+     * <p> System accesibility services are always available to the user the list can't modify
+     * this.
+     *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @param packageNames List of accessibility service package names.
+     *
+     * @return true if setting the restriction succeeded. It fail if there is
+     * one or more non-system accessibility services enabled, that are not in the list.
+     */
+    public boolean setPermittedAccessibilityServices(ComponentName admin,
+            List<String> packageNames) {
+        if (mService != null) {
+            try {
+                return mService.setPermittedAccessibilityServices(admin, packageNames);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Returns the list of permitted accessibility services set by this device or profile owner.
+     *
+     * <p>An empty list means no accessibility services except system services are allowed.
+     * Null means all accessibility services are allowed.
+     *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @return List of accessiblity service package names.
+     */
+    public List<String> getPermittedAccessibilityServices(ComponentName admin) {
+        if (mService != null) {
+            try {
+                return mService.getPermittedAccessibilityServices(admin);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Returns the list of accessibility services permitted by the device or profiles
+     * owners of this user.
+     *
+     * <p>Null means all accessibility services are allowed, if a non-null list is returned
+     * it will contain the intersection of the permitted lists for any device or profile
+     * owners that apply to this user. It will also include any system accessibility services.
+     *
+     * @param userId which user to check for.
+     * @return List of accessiblity service package names.
+     * @hide
+     */
+     @SystemApi
+     public List<String> getPermittedAccessibilityServices(int userId) {
+        if (mService != null) {
+            try {
+                return mService.getPermittedAccessibilityServicesForUser(userId);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return null;
+     }
+
+    /**
+     * Called by a profile or device owner to set the permitted input methods services. When
+     * set by a device owner or profile owner the restriction applies to all profiles of the
+     * user the device owner or profile owner is an admin for.
+     *
+     * By default the user can use any input method. When zero or more packages have
+     * been added, input method that are not in the list and not part of the system
+     * can not be enabled by the user.
+     *
+     * This method will fail if it is called for a admin that is not for the foreground user
+     * or a profile of the foreground user.
+     *
+     * <p> Calling with a null value for the list disables the restriction so that all input methods
+     * can be used, calling with an empty list disables all but the system's own input methods.
+     *
+     * <p> System input methods are always available to the user this method can't modify this.
+     *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @param packageNames List of input method package names.
+     * @return true if setting the restriction succeeded. It will fail if there is
+     *     one or more input method enabled, that are not in the list or user if the foreground
+     *     user.
+     */
+    public boolean setPermittedInputMethods(ComponentName admin, List<String> packageNames) {
+        if (mService != null) {
+            try {
+                return mService.setPermittedInputMethods(admin, packageNames);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return false;
+    }
+
+
+    /**
+     * Returns the list of permitted input methods set by this device or profile owner.
+     *
+     * <p>An empty list means no input methods except system input methods are allowed.
+     * Null means all input methods are allowed.
+     *
+     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
+     * @return List of input method package names.
+     */
+    public List<String> getPermittedInputMethods(ComponentName admin) {
+        if (mService != null) {
+            try {
+                return mService.getPermittedInputMethods(admin);
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Returns the list of input methods permitted by the device or profiles
+     * owners of the current user.
+     *
+     * <p>Null means all input methods are allowed, if a non-null list is returned
+     * it will contain the intersection of the permitted lists for any device or profile
+     * owners that apply to this user. It will also include any system input methods.
+     *
+     * @return List of input method package names.
+     * @hide
+     */
+    @SystemApi
+    public List<String> getPermittedInputMethodsForCurrentUser() {
+        if (mService != null) {
+            try {
+                return mService.getPermittedInputMethodsForCurrentUser();
+            } catch (RemoteException e) {
+                Log.w(TAG, "Failed talking with device policy service", e);
+            }
+        }
+        return null;
+    }
+
+    /**
      * Called by a device owner to create a user with the specified name. The UserHandle returned
      * by this method should not be persisted as user handles are recycled as users are removed and
      * created. If you need to persist an identifier for this user, use
@@ -2802,28 +3071,6 @@
     }
 
     /**
-     * Called by profile or device owner to hide or unhide currently installed packages. This
-     * should only be called by a profile or device owner running within a managed profile.
-     *
-     * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
-     * @param intent An intent matching the app(s) to be updated. All apps that resolve for this
-     *               intent will be updated in the current profile.
-     * @param hidden {@code true} if the packages should be hidden, {@code false} if they should
-     *                 be unhidden.
-     * @return int The number of activities that matched the intent and were updated.
-     */
-    public int setApplicationsHidden(ComponentName admin, Intent intent, boolean hidden) {
-        if (mService != null) {
-            try {
-                return mService.setApplicationsHidden(admin, intent, hidden);
-            } catch (RemoteException e) {
-                Log.w(TAG, "Failed talking with device policy service", e);
-            }
-        }
-        return 0;
-    }
-
-    /**
      * Called by device or profile owner to determine if a package is hidden.
      *
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
@@ -2996,6 +3243,20 @@
     /**
      * Called by device owners to update {@link Settings.Global} settings. Validation that the value
      * of the setting is in the correct form for the setting type should be performed by the caller.
+     * <p>The settings that can be updated with this method are:
+     * <ul>
+     * <li>{@link Settings.Global#ADB_ENABLED}</li>
+     * <li>{@link Settings.Global#AUTO_TIME}</li>
+     * <li>{@link Settings.Global#AUTO_TIME_ZONE}</li>
+     * <li>{@link Settings.Global#BLUETOOTH_ON}</li>
+     * <li>{@link Settings.Global#DATA_ROAMING}</li>
+     * <li>{@link Settings.Global#DEVELOPMENT_SETTINGS_ENABLED}</li>
+     * <li>{@link Settings.Global#MODE_RINGER}</li>
+     * <li>{@link Settings.Global#NETWORK_PREFERENCE}</li>
+     * <li>{@link Settings.Global#USB_MASS_STORAGE_ENABLED}</li>
+     * <li>{@link Settings.Global#WIFI_ON}</li>
+     * <li>{@link Settings.Global#WIFI_SLEEP_POLICY}</li>
+     * </ul>
      *
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param setting The name of the setting to update.
@@ -3015,7 +3276,15 @@
      * Called by profile or device owners to update {@link Settings.Secure} settings. Validation
      * that the value of the setting is in the correct form for the setting type should be performed
      * by the caller.
-     *
+     * <p>The settings that can be updated by a profile or device owner with this method are:
+     * <ul>
+     * <li>{@link Settings.Secure#DEFAULT_INPUT_METHOD}</li>
+     * <li>{@link Settings.Secure#SKIP_FIRST_USE_HINTS}</li>
+     * </ul>
+     * <p>A device owner can additionally update the following settings:
+     * <ul>
+     * <li>{@link Settings.Secure#LOCATION_MODE}</li>
+     * </ul>
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param setting The name of the setting to update.
      * @param value The value to update the setting to.
@@ -3037,7 +3306,7 @@
      * Only a profile owner can designate the restrictions provider.
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param provider The component name of the service that implements
-     * {@link AbstractRestrictionsProvider}. If this param is null,
+     * {@link RestrictionsReceiver}. If this param is null,
      * it removes the restrictions provider previously assigned.
      */
     public void setRestrictionsProvider(ComponentName admin, ComponentName provider) {
@@ -3089,12 +3358,13 @@
      *
      * @param admin Which {@link DeviceAdminReceiver} this request is associated with.
      * @param packageName package to change.
-     * @param blockUninstall true if the user shouldn't be able to uninstall the package.
+     * @param uninstallBlocked true if the user shouldn't be able to uninstall the package.
      */
-    public void setBlockUninstall(ComponentName admin, String packageName, boolean blockUninstall) {
+    public void setUninstallBlocked(ComponentName admin, String packageName,
+            boolean uninstallBlocked) {
         if (mService != null) {
             try {
-                mService.setBlockUninstall(admin, packageName, blockUninstall);
+                mService.setUninstallBlocked(admin, packageName, uninstallBlocked);
             } catch (RemoteException re) {
                 Log.w(TAG, "Failed to call block uninstall on device policy service");
             }
@@ -3109,10 +3379,10 @@
      * @param packageName package to check.
      * @return true if the user shouldn't be able to uninstall the package.
      */
-    public boolean getBlockUninstall(ComponentName admin, String packageName) {
+    public boolean isUninstallBlocked(ComponentName admin, String packageName) {
         if (mService != null) {
             try {
-                return mService.getBlockUninstall(admin, packageName);
+                return mService.isUninstallBlocked(admin, packageName);
             } catch (RemoteException re) {
                 Log.w(TAG, "Failed to call block uninstall on device policy service");
             }
diff --git a/core/java/android/app/admin/DevicePolicyManagerInternal.java b/core/java/android/app/admin/DevicePolicyManagerInternal.java
index edd8199..a1f1d92 100644
--- a/core/java/android/app/admin/DevicePolicyManagerInternal.java
+++ b/core/java/android/app/admin/DevicePolicyManagerInternal.java
@@ -26,6 +26,22 @@
 public abstract class DevicePolicyManagerInternal {
 
     /**
+     * Listener for changes in the white-listed packages to show cross-profile
+     * widgets.
+     */
+    public interface OnCrossProfileWidgetProvidersChangeListener {
+
+        /**
+         * Called when the white-listed packages to show cross-profile widgets
+         * have changed for a given user.
+         *
+         * @param profileId The profile for which the white-listed packages changed.
+         * @param packages The white-listed packages.
+         */
+        public void onCrossProfileWidgetProvidersChanged(int profileId, List<String> packages);
+    }
+
+    /**
      * Gets the packages whose widget providers are white-listed to be
      * available in the parent user.
      *
@@ -35,4 +51,13 @@
      *    profile.
      */
     public abstract List<String> getCrossProfileWidgetProviders(int profileId);
+
+    /**
+     * Adds a listener for changes in the white-listed packages to show
+     * cross-profile app widgets.
+     *
+     * @param listener The listener to add.
+     */
+    public abstract void addOnCrossProfileWidgetProvidersChangeListener(
+            OnCrossProfileWidgetProvidersChangeListener listener);
 }
diff --git a/core/java/android/app/admin/IDevicePolicyManager.aidl b/core/java/android/app/admin/IDevicePolicyManager.aidl
index 324b963..c8e1780 100644
--- a/core/java/android/app/admin/IDevicePolicyManager.aidl
+++ b/core/java/android/app/admin/IDevicePolicyManager.aidl
@@ -24,6 +24,7 @@
 import android.os.Bundle;
 import android.os.RemoteCallback;
 import android.os.UserHandle;
+import java.util.List;
 
 /**
  * Internal IPC interface to the device policy service.
@@ -123,6 +124,9 @@
 
     boolean installCaCert(in ComponentName admin, in byte[] certBuffer);
     void uninstallCaCert(in ComponentName admin, in String alias);
+    void enforceCanManageCaCerts(in ComponentName admin);
+
+    boolean installKeyPair(in ComponentName who, in byte[] privKeyBuffer, in byte[] certBuffer, String alias);
 
     void addPersistentPreferredActivity(in ComponentName admin, in IntentFilter filter, in ComponentName activity);
     void clearPackagePersistentPreferredActivities(in ComponentName admin, String packageName);
@@ -137,8 +141,15 @@
     void addCrossProfileIntentFilter(in ComponentName admin, in IntentFilter filter, int flags);
     void clearCrossProfileIntentFilters(in ComponentName admin);
 
+    boolean setPermittedAccessibilityServices(in ComponentName admin,in List packageList);
+    List getPermittedAccessibilityServices(in ComponentName admin);
+    List getPermittedAccessibilityServicesForUser(int userId);
+
+    boolean setPermittedInputMethods(in ComponentName admin,in List packageList);
+    List getPermittedInputMethods(in ComponentName admin);
+    List getPermittedInputMethodsForCurrentUser();
+
     boolean setApplicationHidden(in ComponentName admin, in String packageName, boolean hidden);
-    int setApplicationsHidden(in ComponentName admin, in Intent intent, boolean hidden);
     boolean isApplicationHidden(in ComponentName admin, in String packageName);
 
     UserHandle createUser(in ComponentName who, in String name);
@@ -165,8 +176,8 @@
 
     void notifyLockTaskModeChanged(boolean isEnabled, String pkg, int userId);
 
-    void setBlockUninstall(in ComponentName admin, in String packageName, boolean blockUninstall);
-    boolean getBlockUninstall(in ComponentName admin, in String packageName);
+    void setUninstallBlocked(in ComponentName admin, in String packageName, boolean uninstallBlocked);
+    boolean isUninstallBlocked(in ComponentName admin, in String packageName);
 
     void setCrossProfileCallerIdDisabled(in ComponentName who, boolean disabled);
     boolean getCrossProfileCallerIdDisabled(in ComponentName who);
@@ -178,4 +189,7 @@
     boolean addCrossProfileWidgetProvider(in ComponentName admin, String packageName);
     boolean removeCrossProfileWidgetProvider(in ComponentName admin, String packageName);
     List<String> getCrossProfileWidgetProviders(in ComponentName admin);
+
+    void setAutoTimeRequired(in ComponentName who, int userHandle, boolean required);
+    boolean getAutoTimeRequired();
 }
diff --git a/core/java/android/app/backup/BackupDataInput.java b/core/java/android/app/backup/BackupDataInput.java
index 03205fb..26f9e3e 100644
--- a/core/java/android/app/backup/BackupDataInput.java
+++ b/core/java/android/app/backup/BackupDataInput.java
@@ -16,6 +16,8 @@
 
 package android.app.backup;
 
+import android.annotation.SystemApi;
+
 import java.io.FileDescriptor;
 import java.io.IOException;
 
@@ -70,6 +72,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public BackupDataInput(FileDescriptor fd) {
         if (fd == null) throw new NullPointerException();
         mBackupReader = ctor(fd);
@@ -79,6 +82,7 @@
     }
 
     /** @hide */
+    @Override
     protected void finalize() throws Throwable {
         try {
             dtor(mBackupReader);
@@ -174,7 +178,7 @@
      * for further processing.  This allows a {@link android.app.backup.BackupAgent} to
      * efficiently discard obsolete or otherwise uninteresting records during the
      * restore operation.
-     * 
+     *
      * @throws IOException if an error occurred when trying to read the restore data stream
      */
     public void skipEntityData() throws IOException {
diff --git a/core/java/android/app/backup/BackupDataOutput.java b/core/java/android/app/backup/BackupDataOutput.java
index fc5fb3d..048a4bb 100644
--- a/core/java/android/app/backup/BackupDataOutput.java
+++ b/core/java/android/app/backup/BackupDataOutput.java
@@ -16,6 +16,7 @@
 
 package android.app.backup;
 
+import android.annotation.SystemApi;
 import android.os.ParcelFileDescriptor;
 import android.os.Process;
 
@@ -66,6 +67,7 @@
     long mBackupWriter;
 
     /** @hide */
+    @SystemApi
     public BackupDataOutput(FileDescriptor fd) {
         if (fd == null) throw new NullPointerException();
         mBackupWriter = ctor(fd);
@@ -115,6 +117,7 @@
     }
 
     /** @hide */
+    @Override
     protected void finalize() throws Throwable {
         try {
             dtor(mBackupWriter);
diff --git a/core/java/android/app/backup/BackupHelper.java b/core/java/android/app/backup/BackupHelper.java
index e3f0d54..7cbbbc3 100644
--- a/core/java/android/app/backup/BackupHelper.java
+++ b/core/java/android/app/backup/BackupHelper.java
@@ -37,10 +37,9 @@
  */
 public interface BackupHelper {
     /**
-     * Based on <code>oldState</code>, determine which of the files from the
-     * application's data directory need to be backed up, write them to
-     * <code>data</code>, and fill in <code>newState</code> with the state as it
-     * exists now.
+     * Based on <code>oldState</code>, determine what application content
+     * needs to be backed up, write it to <code>data</code>, and fill in
+     * <code>newState</code> with the complete state as it exists now.
      * <p>
      * Implementing this method is much like implementing
      * {@link BackupAgent#onBackup(ParcelFileDescriptor, BackupDataOutput, ParcelFileDescriptor)
diff --git a/core/java/android/app/backup/BackupManager.java b/core/java/android/app/backup/BackupManager.java
index 1bb4eba..9151a16 100644
--- a/core/java/android/app/backup/BackupManager.java
+++ b/core/java/android/app/backup/BackupManager.java
@@ -218,6 +218,7 @@
      */
     @SystemApi
     public boolean isBackupEnabled() {
+        checkServiceBinder();
         if (sService != null) {
             try {
                 return sService.isBackupEnabled();
diff --git a/core/java/android/app/backup/BackupTransport.java b/core/java/android/app/backup/BackupTransport.java
index 6cfabf0..70bb5e4 100644
--- a/core/java/android/app/backup/BackupTransport.java
+++ b/core/java/android/app/backup/BackupTransport.java
@@ -51,7 +51,7 @@
     public static final int AGENT_UNKNOWN = -1004;
 
     IBackupTransport mBinderImpl = new TransportImpl();
-    /** @hide */
+
     public IBinder getBinder() {
         return mBinderImpl.asBinder();
     }
diff --git a/core/java/android/app/backup/WallpaperBackupHelper.java b/core/java/android/app/backup/WallpaperBackupHelper.java
index 9e8ab2c..0567500 100644
--- a/core/java/android/app/backup/WallpaperBackupHelper.java
+++ b/core/java/android/app/backup/WallpaperBackupHelper.java
@@ -141,13 +141,13 @@
                     if (widthRatio > 0 && widthRatio < 1.33
                             && heightRatio > 0 && heightRatio < 1.33) {
                         // sufficiently close to our resolution; go ahead and use it
-                        if (DEBUG) Slog.d(TAG, "wallpaper dimension match; using");
+                        Slog.d(TAG, "Applying restored wallpaper image.");
                         f.renameTo(new File(WALLPAPER_IMAGE));
                         // TODO: spin a service to copy the restored image to sd/usb storage,
                         // since it does not exist anywhere other than the private wallpaper
                         // file.
                     } else {
-                        if (DEBUG) Slog.d(TAG, "dimensions too far off: wr=" + widthRatio
+                        Slog.i(TAG, "Dimensions too far off; using default wallpaper. wr=" + widthRatio
                                 + " hr=" + heightRatio);
                         f.delete();
                     }
diff --git a/core/java/android/app/job/IJobService.aidl b/core/java/android/app/job/IJobService.aidl
index 63f8b81..7f55d29 100644
--- a/core/java/android/app/job/IJobService.aidl
+++ b/core/java/android/app/job/IJobService.aidl
@@ -27,6 +27,6 @@
 oneway interface IJobService {
     /** Begin execution of application's job. */
     void startJob(in JobParameters jobParams);
-    /** Stop execution of application's task. */
+    /** Stop execution of application's job. */
     void stopJob(in JobParameters jobParams);
 }
diff --git a/core/java/android/app/job/JobInfo.java b/core/java/android/app/job/JobInfo.java
index 936e205..0d9e778 100644
--- a/core/java/android/app/job/JobInfo.java
+++ b/core/java/android/app/job/JobInfo.java
@@ -17,7 +17,6 @@
 package android.app.job;
 
 import android.content.ComponentName;
-import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.os.PersistableBundle;
@@ -26,42 +25,50 @@
  * Container of data passed to the {@link android.app.job.JobScheduler} fully encapsulating the
  * parameters required to schedule work against the calling application. These are constructed
  * using the {@link JobInfo.Builder}.
+ * You must specify at least one sort of constraint on the JobInfo object that you are creating.
+ * The goal here is to provide the scheduler with high-level semantics about the work you want to
+ * accomplish. Doing otherwise with throw an exception in your app.
  */
 public class JobInfo implements Parcelable {
-    public interface NetworkType {
-        /** Default. */
-        public final int NONE = 0;
-        /** This job requires network connectivity. */
-        public final int ANY = 1;
-        /** This job requires network connectivity that is unmetered. */
-        public final int UNMETERED = 2;
-    }
+    /** Default. */
+    public static final int NETWORK_TYPE_NONE = 0;
+    /** This job requires network connectivity. */
+    public static final int NETWORK_TYPE_ANY = 1;
+    /** This job requires network connectivity that is unmetered. */
+    public static final int NETWORK_TYPE_UNMETERED = 2;
 
     /**
      * Amount of backoff a job has initially by default, in milliseconds.
-     * @hide.
      */
-    public static final long DEFAULT_INITIAL_BACKOFF_MILLIS = 5000L;
+    public static final long DEFAULT_INITIAL_BACKOFF_MILLIS = 30000L;  // 30 seconds.
+
+    /**
+     * Maximum backoff we allow for a job, in milliseconds.
+     */
+    public static final long MAX_BACKOFF_DELAY_MILLIS = 5 * 60 * 60 * 1000;  // 5 hours.
+
+    /**
+     * Linearly back-off a failed job. See
+     * {@link android.app.job.JobInfo.Builder#setBackoffCriteria(long, int)}
+     * retry_time(current_time, num_failures) =
+     *     current_time + initial_backoff_millis * num_failures, num_failures >= 1
+     */
+    public static final int BACKOFF_POLICY_LINEAR = 0;
+
+    /**
+     * Exponentially back-off a failed job. See
+     * {@link android.app.job.JobInfo.Builder#setBackoffCriteria(long, int)}
+     *
+     * retry_time(current_time, num_failures) =
+     *     current_time + initial_backoff_millis * 2 ^ (num_failures - 1), num_failures >= 1
+     */
+    public static final int BACKOFF_POLICY_EXPONENTIAL = 1;
 
     /**
      * Default type of backoff.
      * @hide
      */
-    public static final int DEFAULT_BACKOFF_POLICY = BackoffPolicy.EXPONENTIAL;
-    /**
-     * Maximum backoff we allow for a job, in milliseconds.
-     * @hide
-     */
-    public static final long MAX_BACKOFF_DELAY_MILLIS = 24 * 60 * 60 * 1000;  // 24 hours.
-
-    /**
-     * Linear: retry_time(failure_time, t) = failure_time + initial_retry_delay * t, t >= 1
-     * Expon: retry_time(failure_time, t) = failure_time + initial_retry_delay ^ t, t >= 1
-     */
-    public interface BackoffPolicy {
-        public final int LINEAR = 0;
-        public final int EXPONENTIAL = 1;
-    }
+    public static final int DEFAULT_BACKOFF_POLICY = BACKOFF_POLICY_EXPONENTIAL;
 
     private final int jobId;
     private final PersistableBundle extras;
@@ -70,7 +77,7 @@
     private final boolean requireDeviceIdle;
     private final boolean hasEarlyConstraint;
     private final boolean hasLateConstraint;
-    private final int networkCapabilities;
+    private final int networkType;
     private final long minLatencyMillis;
     private final long maxExecutionDelayMillis;
     private final boolean isPeriodic;
@@ -115,10 +122,12 @@
     }
 
     /**
-     * See {@link android.app.job.JobInfo.NetworkType} for a description of this value.
+     * One of {@link android.app.job.JobInfo#NETWORK_TYPE_ANY},
+     * {@link android.app.job.JobInfo#NETWORK_TYPE_NONE}, or
+     * {@link android.app.job.JobInfo#NETWORK_TYPE_UNMETERED}.
      */
-    public int getNetworkCapabilities() {
-        return networkCapabilities;
+    public int getNetworkType() {
+        return networkType;
     }
 
     /**
@@ -169,8 +178,9 @@
     }
 
     /**
-     * See {@link android.app.job.JobInfo.BackoffPolicy} for an explanation of the values this field
-     * can take. This defaults to exponential.
+     * One of either {@link android.app.job.JobInfo#BACKOFF_POLICY_EXPONENTIAL}, or
+     * {@link android.app.job.JobInfo#BACKOFF_POLICY_LINEAR}, depending on which criteria you set
+     * when creating this job.
      */
     public int getBackoffPolicy() {
         return backoffPolicy;
@@ -200,7 +210,7 @@
         service = in.readParcelable(null);
         requireCharging = in.readInt() == 1;
         requireDeviceIdle = in.readInt() == 1;
-        networkCapabilities = in.readInt();
+        networkType = in.readInt();
         minLatencyMillis = in.readLong();
         maxExecutionDelayMillis = in.readLong();
         isPeriodic = in.readInt() == 1;
@@ -218,7 +228,7 @@
         service = b.mJobService;
         requireCharging = b.mRequiresCharging;
         requireDeviceIdle = b.mRequiresDeviceIdle;
-        networkCapabilities = b.mNetworkCapabilities;
+        networkType = b.mNetworkType;
         minLatencyMillis = b.mMinLatencyMillis;
         maxExecutionDelayMillis = b.mMaxExecutionDelayMillis;
         isPeriodic = b.mIsPeriodic;
@@ -242,7 +252,7 @@
         out.writeParcelable(service, flags);
         out.writeInt(requireCharging ? 1 : 0);
         out.writeInt(requireDeviceIdle ? 1 : 0);
-        out.writeInt(networkCapabilities);
+        out.writeInt(networkType);
         out.writeLong(minLatencyMillis);
         out.writeLong(maxExecutionDelayMillis);
         out.writeInt(isPeriodic ? 1 : 0);
@@ -279,7 +289,7 @@
         // Requirements.
         private boolean mRequiresCharging;
         private boolean mRequiresDeviceIdle;
-        private int mNetworkCapabilities;
+        private int mNetworkType;
         private boolean mIsPersisted;
         // One-off parameters.
         private long mMinLatencyMillis;
@@ -317,15 +327,15 @@
         }
 
         /**
-         * Set some description of the kind of network capabilities you would like to have. This
-         * will be a parameter defined in {@link android.app.job.JobInfo.NetworkType}.
-         * Not calling this function means the network is not necessary.
+         * Set some description of the kind of network type your job needs to have.
+         * Not calling this function means the network is not necessary, as the default is
+         * {@link #NETWORK_TYPE_NONE}.
          * Bear in mind that calling this function defines network as a strict requirement for your
-         * job if the network requested is not available your job will never run. See
+         * job. If the network requested is not available your job will never run. See
          * {@link #setOverrideDeadline(long)} to change this behaviour.
          */
-        public Builder setRequiredNetworkCapabilities(int networkCapabilities) {
-            mNetworkCapabilities = networkCapabilities;
+        public Builder setRequiredNetworkType(int networkType) {
+            mNetworkType = networkType;
             return this;
         }
 
@@ -398,8 +408,8 @@
 
         /**
          * Set up the back-off/retry policy.
-         * This defaults to some respectable values: {5 seconds, Exponential}. We cap back-off at
-         * 1hr.
+         * This defaults to some respectable values: {30 seconds, Exponential}. We cap back-off at
+         * 5hrs.
          * Note that trying to set a backoff criteria for a job with
          * {@link #setRequiresDeviceIdle(boolean)} will throw an exception when you call build().
          * This is because back-off typically does not make sense for these types of jobs. See
@@ -408,7 +418,8 @@
          * mode.
          * @param initialBackoffMillis Millisecond time interval to wait initially when job has
          *                             failed.
-         * @param backoffPolicy is one of {@link BackoffPolicy}
+         * @param backoffPolicy is one of {@link #BACKOFF_POLICY_LINEAR} or
+         * {@link #BACKOFF_POLICY_EXPONENTIAL}
          */
         public Builder setBackoffCriteria(long initialBackoffMillis, int backoffPolicy) {
             mBackoffPolicySet = true;
@@ -425,7 +436,7 @@
          * @param isPersisted True to indicate that the job will be written to disk and loaded at
          *                    boot.
          */
-        public Builder setIsPersisted(boolean isPersisted) {
+        public Builder setPersisted(boolean isPersisted) {
             mIsPersisted = isPersisted;
             return this;
         }
@@ -434,6 +445,12 @@
          * @return The job object to hand to the JobScheduler. This object is immutable.
          */
         public JobInfo build() {
+            // Allow jobs with no constraints - What am I, a database?
+            if (!mHasEarlyConstraint && !mHasLateConstraint && !mRequiresCharging &&
+                    !mRequiresDeviceIdle && mNetworkType == NETWORK_TYPE_NONE) {
+                throw new IllegalArgumentException("You're trying to build a job with no " +
+                        "constraints, this is not allowed.");
+            }
             mExtras = new PersistableBundle(mExtras);  // Make our own copy.
             // Check that a deadline was not set on a periodic job.
             if (mIsPeriodic && (mMaxExecutionDelayMillis != 0L)) {
diff --git a/core/java/android/app/job/JobParameters.java b/core/java/android/app/job/JobParameters.java
index 724856a..62734f2 100644
--- a/core/java/android/app/job/JobParameters.java
+++ b/core/java/android/app/job/JobParameters.java
@@ -32,12 +32,15 @@
     private final int jobId;
     private final PersistableBundle extras;
     private final IBinder callback;
+    private final boolean overrideDeadlineExpired;
 
     /** @hide */
-    public JobParameters(int jobId, PersistableBundle extras, IBinder callback) {
+    public JobParameters(IBinder callback, int jobId, PersistableBundle extras,
+                         boolean overrideDeadlineExpired) {
         this.jobId = jobId;
         this.extras = extras;
         this.callback = callback;
+        this.overrideDeadlineExpired = overrideDeadlineExpired;
     }
 
     /**
@@ -56,6 +59,16 @@
         return extras;
     }
 
+    /**
+     * For jobs with {@link android.app.job.JobInfo.Builder#setOverrideDeadline(long)} set, this
+     * provides an easy way to tell whether the job is being executed due to the deadline
+     * expiring. Note: If the job is running because its deadline expired, it implies that its
+     * constraints will not be met.
+     */
+    public boolean isOverrideDeadlineExpired() {
+        return overrideDeadlineExpired;
+    }
+
     /** @hide */
     public IJobCallback getCallback() {
         return IJobCallback.Stub.asInterface(callback);
@@ -65,6 +78,7 @@
         jobId = in.readInt();
         extras = in.readPersistableBundle();
         callback = in.readStrongBinder();
+        overrideDeadlineExpired = in.readInt() == 1;
     }
 
     @Override
@@ -77,6 +91,7 @@
         dest.writeInt(jobId);
         dest.writePersistableBundle(extras);
         dest.writeStrongBinder(callback);
+        dest.writeInt(overrideDeadlineExpired ? 1 : 0);
     }
 
     public static final Creator<JobParameters> CREATOR = new Creator<JobParameters>() {
diff --git a/core/java/android/app/job/JobScheduler.java b/core/java/android/app/job/JobScheduler.java
index 7fe192c..89efeb2 100644
--- a/core/java/android/app/job/JobScheduler.java
+++ b/core/java/android/app/job/JobScheduler.java
@@ -21,8 +21,24 @@
 import android.content.Context;
 
 /**
- * Class for scheduling various types of jobs with the scheduling framework on the device.
- *
+ * This is an API for scheduling various types of jobs against the framework that will be executed
+ * in your application's own process.
+ * <p>
+ * See {@link android.app.job.JobInfo} for more description of the types of jobs that can be run
+ * and how to construct them. You will construct these JobInfo objects and pass them to the
+ * JobScheduler with {@link #schedule(JobInfo)}. When the criteria declared are met, the
+ * system will execute this job on your application's {@link android.app.job.JobService}.
+ * You identify which JobService is meant to execute the logic for your job when you create the
+ * JobInfo with
+ * {@link android.app.job.JobInfo.Builder#JobInfo.Builder(int,android.content.ComponentName)}.
+ * </p>
+ * <p>
+ * The framework will be intelligent about when you receive your callbacks, and attempt to batch
+ * and defer them as much as possible. Typically if you don't specify a deadline on your job, it
+ * can be run at any moment depending on the current state of the JobScheduler's internal queue,
+ * however it might be deferred as long as until the next time the device is connected to a power
+ * source.
+ * </p>
  * <p>You do not
  * instantiate this class directly; instead, retrieve it through
  * {@link android.content.Context#getSystemService
diff --git a/core/java/android/app/job/JobService.java b/core/java/android/app/job/JobService.java
index eea0268..940a530 100644
--- a/core/java/android/app/job/JobService.java
+++ b/core/java/android/app/job/JobService.java
@@ -17,9 +17,6 @@
 package android.app.job;
 
 import android.app.Service;
-import android.app.job.IJobCallback;
-import android.app.job.IJobService;
-import android.app.job.IJobService.Stub;
 import android.content.Intent;
 import android.os.Handler;
 import android.os.IBinder;
@@ -218,7 +215,7 @@
      *
      * <p>This will happen if the requirements specified at schedule time are no longer met. For
      * example you may have requested WiFi with
-     * {@link android.app.job.JobInfo.Builder#setRequiredNetworkCapabilities(int)}, yet while your
+     * {@link android.app.job.JobInfo.Builder#setRequiredNetworkType(int)}, yet while your
      * job was executing the user toggled WiFi. Another example is if you had specified
      * {@link android.app.job.JobInfo.Builder#setRequiresDeviceIdle(boolean)}, and the phone left its
      * idle maintenance window. You are solely responsible for the behaviour of your application
@@ -248,8 +245,8 @@
      *
      * @param params Parameters specifying system-provided info about this job, this was given to
      *               your application in {@link #onStartJob(JobParameters)}.
-     * @param needsReschedule True if this job is complete, false if you want the JobManager to
-     *                        reschedule you.
+     * @param needsReschedule True if this job should be rescheduled according to the back-off
+     *                        criteria specified at schedule-time. False otherwise.
      */
     public final void jobFinished(JobParameters params, boolean needsReschedule) {
         ensureHandler();
diff --git a/core/java/android/app/usage/ConfigurationStats.java b/core/java/android/app/usage/ConfigurationStats.java
new file mode 100644
index 0000000..080216c
--- /dev/null
+++ b/core/java/android/app/usage/ConfigurationStats.java
@@ -0,0 +1,161 @@
+/**
+ * Copyright (C) 2014 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 android.app.usage;
+
+import android.content.res.Configuration;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Represents the usage statistics of a device {@link android.content.res.Configuration} for a
+ * specific time range.
+ */
+public final class ConfigurationStats implements Parcelable {
+
+    /**
+     * {@hide}
+     */
+    public Configuration mConfiguration;
+
+    /**
+     * {@hide}
+     */
+    public long mBeginTimeStamp;
+
+    /**
+     * {@hide}
+     */
+    public long mEndTimeStamp;
+
+    /**
+     * {@hide}
+     */
+    public long mLastTimeActive;
+
+    /**
+     * {@hide}
+     */
+    public long mTotalTimeActive;
+
+    /**
+     * {@hide}
+     */
+    public int mActivationCount;
+
+    /**
+     * {@hide}
+     */
+    public ConfigurationStats() {
+    }
+
+    public ConfigurationStats(ConfigurationStats stats) {
+        mConfiguration = stats.mConfiguration;
+        mBeginTimeStamp = stats.mBeginTimeStamp;
+        mEndTimeStamp = stats.mEndTimeStamp;
+        mLastTimeActive = stats.mLastTimeActive;
+        mTotalTimeActive = stats.mTotalTimeActive;
+        mActivationCount = stats.mActivationCount;
+    }
+
+    public Configuration getConfiguration() {
+        return mConfiguration;
+    }
+
+    /**
+     * Get the beginning of the time range this {@link ConfigurationStats} represents,
+     * measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
+     */
+    public long getFirstTimeStamp() {
+        return mBeginTimeStamp;
+    }
+
+    /**
+     * Get the end of the time range this {@link ConfigurationStats} represents,
+     * measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
+     */
+    public long getLastTimeStamp() {
+        return mEndTimeStamp;
+    }
+
+    /**
+     * Get the last time this configuration was active, measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
+     */
+    public long getLastTimeActive() {
+        return mLastTimeActive;
+    }
+
+    /**
+     * Get the total time this configuration was active, measured in milliseconds.
+     */
+    public long getTotalTimeActive() {
+        return mTotalTimeActive;
+    }
+
+    /**
+     * Get the number of times this configuration was active.
+     */
+    public int getActivationCount() {
+        return mActivationCount;
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel dest, int flags) {
+        if (mConfiguration != null) {
+            dest.writeInt(1);
+            mConfiguration.writeToParcel(dest, flags);
+        } else {
+            dest.writeInt(0);
+        }
+
+        dest.writeLong(mBeginTimeStamp);
+        dest.writeLong(mEndTimeStamp);
+        dest.writeLong(mLastTimeActive);
+        dest.writeLong(mTotalTimeActive);
+        dest.writeInt(mActivationCount);
+    }
+
+    public static final Creator<ConfigurationStats> CREATOR = new Creator<ConfigurationStats>() {
+        @Override
+        public ConfigurationStats createFromParcel(Parcel source) {
+            ConfigurationStats stats = new ConfigurationStats();
+            if (source.readInt() != 0) {
+                stats.mConfiguration = Configuration.CREATOR.createFromParcel(source);
+            }
+            stats.mBeginTimeStamp = source.readLong();
+            stats.mEndTimeStamp = source.readLong();
+            stats.mLastTimeActive = source.readLong();
+            stats.mTotalTimeActive = source.readLong();
+            stats.mActivationCount = source.readInt();
+            return stats;
+        }
+
+        @Override
+        public ConfigurationStats[] newArray(int size) {
+            return new ConfigurationStats[size];
+        }
+    };
+}
diff --git a/core/java/android/app/usage/IUsageStatsManager.aidl b/core/java/android/app/usage/IUsageStatsManager.aidl
index 3b09888..4ed1489 100644
--- a/core/java/android/app/usage/IUsageStatsManager.aidl
+++ b/core/java/android/app/usage/IUsageStatsManager.aidl
@@ -27,5 +27,7 @@
 interface IUsageStatsManager {
     ParceledListSlice queryUsageStats(int bucketType, long beginTime, long endTime,
             String callingPackage);
+    ParceledListSlice queryConfigurationStats(int bucketType, long beginTime, long endTime,
+            String callingPackage);
     UsageEvents queryEvents(long beginTime, long endTime, String callingPackage);
 }
diff --git a/core/java/android/app/usage/UsageEvents.java b/core/java/android/app/usage/UsageEvents.java
index d1ebc5f..1a947ec 100644
--- a/core/java/android/app/usage/UsageEvents.java
+++ b/core/java/android/app/usage/UsageEvents.java
@@ -16,6 +16,7 @@
 package android.app.usage;
 
 import android.content.ComponentName;
+import android.content.res.Configuration;
 import android.os.Parcel;
 import android.os.Parcelable;
 
@@ -63,9 +64,19 @@
         public static final int CONTINUE_PREVIOUS_DAY = 4;
 
         /**
+         * An event type denoting that the device configuration has changed.
+         */
+        public static final int CONFIGURATION_CHANGE = 5;
+
+        /**
          * {@hide}
          */
-        public ComponentName mComponent;
+        public String mPackage;
+
+        /**
+         * {@hide}
+         */
+        public String mClass;
 
         /**
          * {@hide}
@@ -78,14 +89,38 @@
         public int mEventType;
 
         /**
-         * The component this event represents.
+         * Only present for {@link #CONFIGURATION_CHANGE} event types.
+         * {@hide}
+         */
+        public Configuration mConfiguration;
+
+        /**
+         * TODO(adamlesinski): Removed before release.
+         * {@hide}
          */
         public ComponentName getComponent() {
-            return mComponent;
+            return new ComponentName(mPackage, mClass);
         }
 
         /**
-         * The time at which this event occurred.
+         * The package name of the source of this event.
+         */
+        public String getPackageName() {
+            return mPackage;
+        }
+
+        /**
+         * The class name of the source of this event. This may be null for
+         * certain events.
+         */
+        public String getClassName() {
+            return mClass;
+        }
+
+        /**
+         * The time at which this event occurred, measured in milliseconds since the epoch.
+         * <p/>
+         * See {@link System#currentTimeMillis()}.
          */
         public long getTimeStamp() {
             return mTimeStamp;
@@ -100,6 +135,14 @@
         public int getEventType() {
             return mEventType;
         }
+
+        /**
+         * Returns a {@link Configuration} for this event if the event is of type
+         * {@link #CONFIGURATION_CHANGE}, otherwise it returns null.
+         */
+        public Configuration getConfiguration() {
+            return mConfiguration;
+        }
     }
 
     // Only used when creating the resulting events. Not used for reading/unparceling.
@@ -115,7 +158,7 @@
      * In order to save space, since ComponentNames will be duplicated everywhere,
      * we use a map and index into it.
      */
-    private ComponentName[] mComponentNameTable;
+    private String[] mStringPool;
 
     /**
      * Construct the iterator from a parcel.
@@ -125,7 +168,7 @@
         mEventCount = in.readInt();
         mIndex = in.readInt();
         if (mEventCount > 0) {
-            mComponentNameTable = in.createTypedArray(ComponentName.CREATOR);
+            mStringPool = in.createStringArray();
 
             final int listByteLength = in.readInt();
             final int positionInParcel = in.readInt();
@@ -149,8 +192,8 @@
      * Construct the iterator in preparation for writing it to a parcel.
      * {@hide}
      */
-    public UsageEvents(List<Event> events, ComponentName[] nameTable) {
-        mComponentNameTable = nameTable;
+    public UsageEvents(List<Event> events, String[] stringPool) {
+        mStringPool = stringPool;
         mEventCount = events.size();
         mEventsToWrite = events;
     }
@@ -178,12 +221,9 @@
             return false;
         }
 
-        final int index = mParcel.readInt();
-        eventOut.mComponent = mComponentNameTable[index];
-        eventOut.mEventType = mParcel.readInt();
-        eventOut.mTimeStamp = mParcel.readLong();
-        mIndex++;
+        readEventFromParcel(mParcel, eventOut);
 
+        mIndex++;
         if (mIndex >= mEventCount) {
             mParcel.recycle();
             mParcel = null;
@@ -201,6 +241,69 @@
         }
     }
 
+    private int findStringIndex(String str) {
+        final int index = Arrays.binarySearch(mStringPool, str);
+        if (index < 0) {
+            throw new IllegalStateException("String '" + str + "' is not in the string pool");
+        }
+        return index;
+    }
+
+    /**
+     * Writes a single event to the parcel. Modify this when updating {@link Event}.
+     */
+    private void writeEventToParcel(Event event, Parcel p, int flags) {
+        final int packageIndex;
+        if (event.mPackage != null) {
+            packageIndex = findStringIndex(event.mPackage);
+        } else {
+            packageIndex = -1;
+        }
+
+        final int classIndex;
+        if (event.mClass != null) {
+            classIndex = findStringIndex(event.mClass);
+        } else {
+            classIndex = -1;
+        }
+        p.writeInt(packageIndex);
+        p.writeInt(classIndex);
+        p.writeInt(event.mEventType);
+        p.writeLong(event.mTimeStamp);
+
+        if (event.mEventType == Event.CONFIGURATION_CHANGE) {
+            event.mConfiguration.writeToParcel(p, flags);
+        }
+    }
+
+    /**
+     * Reads a single event from the parcel. Modify this when updating {@link Event}.
+     */
+    private void readEventFromParcel(Parcel p, Event eventOut) {
+        final int packageIndex = p.readInt();
+        if (packageIndex >= 0) {
+            eventOut.mPackage = mStringPool[packageIndex];
+        } else {
+            eventOut.mPackage = null;
+        }
+
+        final int classIndex = p.readInt();
+        if (classIndex >= 0) {
+            eventOut.mClass = mStringPool[classIndex];
+        } else {
+            eventOut.mClass = null;
+        }
+        eventOut.mEventType = p.readInt();
+        eventOut.mTimeStamp = p.readLong();
+
+        // Extract the configuration for configuration change events.
+        if (eventOut.mEventType == Event.CONFIGURATION_CHANGE) {
+            eventOut.mConfiguration = Configuration.CREATOR.createFromParcel(p);
+        } else {
+            eventOut.mConfiguration = null;
+        }
+    }
+
     @Override
     public int describeContents() {
         return 0;
@@ -211,7 +314,7 @@
         dest.writeInt(mEventCount);
         dest.writeInt(mIndex);
         if (mEventCount > 0) {
-            dest.writeTypedArray(mComponentNameTable, flags);
+            dest.writeStringArray(mStringPool);
 
             if (mEventsToWrite != null) {
                 // Write out the events
@@ -220,16 +323,9 @@
                     p.setDataPosition(0);
                     for (int i = 0; i < mEventCount; i++) {
                         final Event event = mEventsToWrite.get(i);
-
-                        int index = Arrays.binarySearch(mComponentNameTable, event.getComponent());
-                        if (index < 0) {
-                            throw new IllegalStateException(event.getComponent().toShortString() +
-                                    " is not in the component name table");
-                        }
-                        p.writeInt(index);
-                        p.writeInt(event.getEventType());
-                        p.writeLong(event.getTimeStamp());
+                        writeEventToParcel(event, p, flags);
                     }
+
                     final int listByteLength = p.dataPosition();
 
                     // Write the total length of the data.
diff --git a/core/java/android/app/usage/UsageStats.java b/core/java/android/app/usage/UsageStats.java
index e47a802..abfc435 100644
--- a/core/java/android/app/usage/UsageStats.java
+++ b/core/java/android/app/usage/UsageStats.java
@@ -81,28 +81,36 @@
     }
 
     /**
-     * Get the beginning of the time range this {@link android.app.usage.UsageStats} represents.
+     * Get the beginning of the time range this {@link android.app.usage.UsageStats} represents,
+     * measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
      */
     public long getFirstTimeStamp() {
         return mBeginTimeStamp;
     }
 
     /**
-     * Get the end of the time range this {@link android.app.usage.UsageStats} represents.
+     * Get the end of the time range this {@link android.app.usage.UsageStats} represents,
+     * measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
      */
     public long getLastTimeStamp() {
         return mEndTimeStamp;
     }
 
     /**
-     * Get the last time this package was used.
+     * Get the last time this package was used, measured in milliseconds since the epoch.
+     * <p/>
+     * See {@link System#currentTimeMillis()}.
      */
     public long getLastTimeUsed() {
         return mLastTimeUsed;
     }
 
     /**
-     * Get the total time this package spent in the foreground.
+     * Get the total time this package spent in the foreground, measured in milliseconds.
      */
     public long getTotalTimeInForeground() {
         return mTotalTimeInForeground;
diff --git a/core/java/android/app/usage/UsageStatsManager.java b/core/java/android/app/usage/UsageStatsManager.java
index f9b8928..bc6099a 100644
--- a/core/java/android/app/usage/UsageStatsManager.java
+++ b/core/java/android/app/usage/UsageStatsManager.java
@@ -23,6 +23,7 @@
 
 import java.util.Collections;
 import java.util.List;
+import java.util.Map;
 
 /**
  * Provides access to device usage history and statistics. Usage data is aggregated into
@@ -124,9 +125,9 @@
      * @see #INTERVAL_YEARLY
      * @see #INTERVAL_BEST
      */
-    @SuppressWarnings("unchecked")
     public List<UsageStats> queryUsageStats(int intervalType, long beginTime, long endTime) {
         try {
+            @SuppressWarnings("unchecked")
             ParceledListSlice<UsageStats> slice = mService.queryUsageStats(intervalType, beginTime,
                     endTime, mContext.getOpPackageName());
             if (slice != null) {
@@ -135,7 +136,32 @@
         } catch (RemoteException e) {
             // fallthrough and return null.
         }
-        return Collections.EMPTY_LIST;
+        return Collections.emptyList();
+    }
+
+    /**
+     * Gets the hardware configurations the device was in for the given time range, aggregated by
+     * the specified interval. The results are ordered as in
+     * {@link #queryUsageStats(int, long, long)}.
+     *
+     * @param intervalType The time interval by which the stats are aggregated.
+     * @param beginTime The inclusive beginning of the range of stats to include in the results.
+     * @param endTime The exclusive end of the range of stats to include in the results.
+     * @return A list of {@link ConfigurationStats} or null if none are available.
+     */
+    public List<ConfigurationStats> queryConfigurations(int intervalType, long beginTime,
+            long endTime) {
+        try {
+            @SuppressWarnings("unchecked")
+            ParceledListSlice<ConfigurationStats> slice = mService.queryConfigurationStats(
+                    intervalType, beginTime, endTime, mContext.getOpPackageName());
+            if (slice != null) {
+                return slice.getList();
+            }
+        } catch (RemoteException e) {
+            // fallthrough and return the empty list.
+        }
+        return Collections.emptyList();
     }
 
     /**
@@ -149,7 +175,6 @@
      * @param endTime The exclusive end of the range of events to include in the results.
      * @return A {@link UsageEvents}.
      */
-    @SuppressWarnings("unchecked")
     public UsageEvents queryEvents(long beginTime, long endTime) {
         try {
             UsageEvents iter = mService.queryEvents(beginTime, endTime,
@@ -170,15 +195,13 @@
      *
      * @param beginTime The inclusive beginning of the range of stats to include in the results.
      * @param endTime The exclusive end of the range of stats to include in the results.
-     * @return An {@link android.util.ArrayMap} keyed by package name or null if no stats are
+     * @return A {@link java.util.Map} keyed by package name, or null if no stats are
      *         available.
      */
-    public ArrayMap<String, UsageStats> queryAndAggregateUsageStats(long beginTime, long endTime) {
+    public Map<String, UsageStats> queryAndAggregateUsageStats(long beginTime, long endTime) {
         List<UsageStats> stats = queryUsageStats(INTERVAL_BEST, beginTime, endTime);
         if (stats.isEmpty()) {
-            @SuppressWarnings("unchecked")
-            ArrayMap<String, UsageStats> emptyStats = ArrayMap.EMPTY;
-            return emptyStats;
+            return Collections.emptyMap();
         }
 
         ArrayMap<String, UsageStats> aggregatedStats = new ArrayMap<>();
diff --git a/core/java/android/app/usage/UsageStatsManagerInternal.java b/core/java/android/app/usage/UsageStatsManagerInternal.java
index 119d705..083a48a 100644
--- a/core/java/android/app/usage/UsageStatsManagerInternal.java
+++ b/core/java/android/app/usage/UsageStatsManagerInternal.java
@@ -17,6 +17,7 @@
 package android.app.usage;
 
 import android.content.ComponentName;
+import android.content.res.Configuration;
 
 /**
  * UsageStatsManager local system service interface.
@@ -28,14 +29,19 @@
     /**
      * Reports an event to the UsageStatsManager.
      *
-     * @param component The component for which this event ocurred.
+     * @param component The component for which this event occurred.
      * @param userId The user id to which the component belongs to.
-     * @param timeStamp The time at which this event ocurred.
-     * @param eventType The event that occured. Valid values can be found at
+     * @param eventType The event that occurred. Valid values can be found at
      * {@link UsageEvents}
      */
-    public abstract void reportEvent(ComponentName component, int userId,
-            long timeStamp, int eventType);
+    public abstract void reportEvent(ComponentName component, int userId, int eventType);
+
+    /**
+     * Reports a configuration change to the UsageStatsManager.
+     *
+     * @param config The new device configuration.
+     */
+    public abstract void reportConfigurationChange(Configuration config, int userId);
 
     /**
      * Prepares the UsageStatsService for shutdown.
diff --git a/core/java/android/appwidget/AppWidgetHost.java b/core/java/android/appwidget/AppWidgetHost.java
index 69716e5..24c6793 100644
--- a/core/java/android/appwidget/AppWidgetHost.java
+++ b/core/java/android/appwidget/AppWidgetHost.java
@@ -24,7 +24,6 @@
 import android.app.Activity;
 import android.content.ActivityNotFoundException;
 import android.content.Context;
-import android.content.Intent;
 import android.content.IntentSender;
 import android.os.Binder;
 import android.os.Bundle;
@@ -155,7 +154,7 @@
         int[] updatedIds;
         ArrayList<RemoteViews> updatedViews = new ArrayList<RemoteViews>();
         try {
-            updatedIds = sService.startListening(mCallbacks, mContext.getPackageName(), mHostId,
+            updatedIds = sService.startListening(mCallbacks, mContext.getOpPackageName(), mHostId,
                     updatedViews);
         }
         catch (RemoteException e) {
@@ -174,7 +173,7 @@
      */
     public void stopListening() {
         try {
-            sService.stopListening(mContext.getPackageName(), mHostId);
+            sService.stopListening(mContext.getOpPackageName(), mHostId);
         }
         catch (RemoteException e) {
             throw new RuntimeException("system server dead?", e);
@@ -192,7 +191,7 @@
      */
     public int allocateAppWidgetId() {
         try {
-            return sService.allocateAppWidgetId(mContext.getPackageName(), mHostId);
+            return sService.allocateAppWidgetId(mContext.getOpPackageName(), mHostId);
         }
         catch (RemoteException e) {
             throw new RuntimeException("system server dead?", e);
@@ -222,7 +221,7 @@
             int appWidgetId, int intentFlags, int requestCode, @Nullable Bundle options) {
         try {
             IntentSender intentSender = sService.createAppWidgetConfigIntentSender(
-                    mContext.getPackageName(), appWidgetId, intentFlags);
+                    mContext.getOpPackageName(), appWidgetId, intentFlags);
             if (intentSender != null) {
                 activity.startIntentSenderForResult(intentSender, requestCode, null, 0, 0, 0,
                         options);
@@ -246,7 +245,7 @@
             if (sService == null) {
                 bindService();
             }
-            return sService.getAppWidgetIdsForHost(mContext.getPackageName(), mHostId);
+            return sService.getAppWidgetIdsForHost(mContext.getOpPackageName(), mHostId);
         } catch (RemoteException e) {
             throw new RuntimeException("system server dead?", e);
         }
@@ -263,7 +262,7 @@
         synchronized (mViews) {
             mViews.remove(appWidgetId);
             try {
-                sService.deleteAppWidgetId(mContext.getPackageName(), appWidgetId);
+                sService.deleteAppWidgetId(mContext.getOpPackageName(), appWidgetId);
             }
             catch (RemoteException e) {
                 throw new RuntimeException("system server dead?", e);
@@ -281,7 +280,7 @@
      */
     public void deleteHost() {
         try {
-            sService.deleteHost(mContext.getPackageName(), mHostId);
+            sService.deleteHost(mContext.getOpPackageName(), mHostId);
         }
         catch (RemoteException e) {
             throw new RuntimeException("system server dead?", e);
@@ -319,7 +318,7 @@
         }
         RemoteViews views;
         try {
-            views = sService.getAppWidgetViews(mContext.getPackageName(), appWidgetId);
+            views = sService.getAppWidgetViews(mContext.getOpPackageName(), appWidgetId);
         } catch (RemoteException e) {
             throw new RuntimeException("system server dead?", e);
         }
diff --git a/core/java/android/appwidget/AppWidgetManager.java b/core/java/android/appwidget/AppWidgetManager.java
index 086eb7d..00248cc 100644
--- a/core/java/android/appwidget/AppWidgetManager.java
+++ b/core/java/android/appwidget/AppWidgetManager.java
@@ -188,7 +188,7 @@
      * this widget. Can have the value {@link
      * AppWidgetProviderInfo#WIDGET_CATEGORY_HOME_SCREEN} or {@link
      * AppWidgetProviderInfo#WIDGET_CATEGORY_KEYGUARD} or {@link
-     * AppWidgetProviderInfo#WIDGET_CATEGORY_RECENTS}.
+     * AppWidgetProviderInfo#WIDGET_CATEGORY_SEARCHBOX}.
      */
     public static final String OPTION_APPWIDGET_HOST_CATEGORY = "appWidgetCategory";
 
@@ -441,7 +441,7 @@
      * @hide
      */
     public AppWidgetManager(Context context, IAppWidgetService service) {
-        mPackageName = context.getPackageName();
+        mPackageName = context.getOpPackageName();
         mService = service;
         mDisplayMetrics = context.getResources().getDisplayMetrics();
     }
diff --git a/core/java/android/appwidget/AppWidgetProviderInfo.java b/core/java/android/appwidget/AppWidgetProviderInfo.java
index 02f70c8..b4d79b4 100644
--- a/core/java/android/appwidget/AppWidgetProviderInfo.java
+++ b/core/java/android/appwidget/AppWidgetProviderInfo.java
@@ -61,9 +61,9 @@
     public static final int WIDGET_CATEGORY_KEYGUARD = 2;
 
     /**
-     * Indicates that the widget can be displayed within recents.
+     * Indicates that the widget can be displayed within a space reserved for the search box.
      */
-    public static final int WIDGET_CATEGORY_RECENTS = 4;
+    public static final int WIDGET_CATEGORY_SEARCHBOX = 4;
 
     /**
      * Identity of this AppWidget component.  This component should be a {@link
diff --git a/core/java/android/bluetooth/BluetoothDevice.java b/core/java/android/bluetooth/BluetoothDevice.java
index 860512b..5e50b69 100644
--- a/core/java/android/bluetooth/BluetoothDevice.java
+++ b/core/java/android/bluetooth/BluetoothDevice.java
@@ -517,6 +517,27 @@
      */
     public static final String EXTRA_UUID = "android.bluetooth.device.extra.UUID";
 
+    /**
+     * For {@link #getPhonebookAccessPermission}, {@link #setPhonebookAccessPermission},
+     * {@link #getMessageAccessPermission} and {@link #setMessageAccessPermission}.
+     * @hide
+     */
+    public static final int ACCESS_UNKNOWN = 0;
+
+    /**
+     * For {@link #getPhonebookAccessPermission}, {@link #setPhonebookAccessPermission},
+     * {@link #getMessageAccessPermission} and {@link #setMessageAccessPermission}.
+     * @hide
+     */
+    public static final int ACCESS_ALLOWED = 1;
+
+    /**
+     * For {@link #getPhonebookAccessPermission}, {@link #setPhonebookAccessPermission},
+     * {@link #getMessageAccessPermission} and {@link #setMessageAccessPermission}.
+     * @hide
+     */
+    public static final int ACCESS_REJECTED = 2;
+
      /**
       * No preferrence of physical transport for GATT connections to remote dual-mode devices
       * @hide
@@ -952,39 +973,6 @@
     }
 
     /**
-     * Get trust state of a remote device.
-     * <p>Requires {@link android.Manifest.permission#BLUETOOTH}.
-     * @hide
-     */
-    public boolean getTrustState() {
-        //TODO(BT)
-        /*
-        try {
-            return sService.getTrustState(this);
-        } catch (RemoteException e) {
-            Log.e(TAG, "", e);
-        }*/
-        return false;
-    }
-
-    /**
-     * Set trust state for a remote device.
-     * <p>Requires {@link android.Manifest.permission#BLUETOOTH_ADMIN}.
-     * @param value the trust state value (true or false)
-     * @hide
-     */
-    public boolean setTrust(boolean value) {
-        //TODO(BT)
-        /*
-        try {
-            return sService.setTrust(this, value);
-        } catch (RemoteException e) {
-            Log.e(TAG, "", e);
-        }*/
-        return false;
-    }
-
-    /**
      * Returns the supported features (UUIDs) of the remote device.
      *
      * <p>This method does not start a service discovery procedure to retrieve the UUIDs
@@ -1135,6 +1123,82 @@
     }
 
     /**
+     * Requires {@link android.Manifest.permission#BLUETOOTH}.
+     * @return Whether the phonebook access is allowed to this device. Can be
+     *         {@link #ACCESS_UNKNOWN}, {@link #ACCESS_ALLOWED} or {@link #ACCESS_REJECTED}.
+     * @hide
+     */
+    public int getPhonebookAccessPermission() {
+        if (sService == null) {
+            return ACCESS_UNKNOWN;
+        }
+        try {
+            return sService.getPhonebookAccessPermission(this);
+        } catch (RemoteException e) {
+            Log.e(TAG, "", e);
+        }
+        return ACCESS_UNKNOWN;
+    }
+
+    /**
+     * Sets whether the phonebook access is allowed to this device.
+     * <p>Requires {@link android.Manifest.permission#BLUETOOTH_PRIVILEGED}.
+     * @param value Can be {@link #ACCESS_UNKNOWN}, {@link #ACCESS_ALLOWED} or
+     *              {@link #ACCESS_REJECTED}.
+     * @return Whether the value has been successfully set.
+     * @hide
+     */
+    public boolean setPhonebookAccessPermission(int value) {
+        if (sService == null) {
+            return false;
+        }
+        try {
+            return sService.setPhonebookAccessPermission(this, value);
+        } catch (RemoteException e) {
+            Log.e(TAG, "", e);
+        }
+        return false;
+    }
+
+    /**
+     * Requires {@link android.Manifest.permission#BLUETOOTH}.
+     * @return Whether the message access is allowed to this device. Can be
+     *         {@link #ACCESS_UNKNOWN}, {@link #ACCESS_ALLOWED} or {@link #ACCESS_REJECTED}.
+     * @hide
+     */
+    public int getMessageAccessPermission() {
+        if (sService == null) {
+            return ACCESS_UNKNOWN;
+        }
+        try {
+            return sService.getMessageAccessPermission(this);
+        } catch (RemoteException e) {
+            Log.e(TAG, "", e);
+        }
+        return ACCESS_UNKNOWN;
+    }
+
+    /**
+     * Sets whether the message access is allowed to this device.
+     * <p>Requires {@link android.Manifest.permission#BLUETOOTH_PRIVILEGED}.
+     * @param value Can be {@link #ACCESS_UNKNOWN}, {@link #ACCESS_ALLOWED} or
+     *              {@link #ACCESS_REJECTED}.
+     * @return Whether the value has been successfully set.
+     * @hide
+     */
+    public boolean setMessageAccessPermission(int value) {
+        if (sService == null) {
+            return false;
+        }
+        try {
+            return sService.setMessageAccessPermission(this, value);
+        } catch (RemoteException e) {
+            Log.e(TAG, "", e);
+        }
+        return false;
+    }
+
+    /**
      * Create an RFCOMM {@link BluetoothSocket} ready to start a secure
      * outgoing connection to this remote device on given channel.
      * <p>The remote device will be authenticated and communication on this
@@ -1343,5 +1407,4 @@
         } catch (RemoteException e) {Log.e(TAG, "", e);}
         return null;
     }
-
 }
diff --git a/core/java/android/bluetooth/BluetoothGatt.java b/core/java/android/bluetooth/BluetoothGatt.java
index 59d7956..2276229 100644
--- a/core/java/android/bluetooth/BluetoothGatt.java
+++ b/core/java/android/bluetooth/BluetoothGatt.java
@@ -51,6 +51,7 @@
     private int mConnState;
     private final Object mStateLock = new Object();
     private Boolean mDeviceBusy = false;
+    private Boolean mIsCongested = false;
     private int mTransport;
 
     private static final int CONN_STATE_IDLE = 0;
@@ -96,19 +97,19 @@
      * Bluetooth SIG. This is the default value if no connection parameter update
      * is requested.
      */
-    public static final int GATT_CONNECTION_BALANCED = 0;
+    public static final int CONNECTION_PRIORITY_BALANCED = 0;
 
     /**
      * Connection paramter update - Request a high priority, low latency connection.
      * An application should only request high priority connection paramters to transfer
      * large amounts of data over LE quickly. Once the transfer is complete, the application
-     * should request {@link BluetoothGatt#GATT_CONNECTION_BALANCED} connectoin parameters
+     * should request {@link BluetoothGatt#CONNECTION_PRIORITY_BALANCED} connectoin parameters
      * to reduce energy use.
      */
-    public static final int GATT_CONNECTION_HIGH_PRIORITY = 1;
+    public static final int CONNECTION_PRIORITY_HIGH = 1;
 
     /** Connection paramter update - Request low power, reduced data rate connection parameters. */
-    public static final int GATT_CONNECTION_LOW_POWER = 2;
+    public static final int CONNECTION_PRIORITY_LOW_POWER = 2;
 
     /**
      * No authentication required.
@@ -601,7 +602,7 @@
                     return;
                 }
                 try {
-                    mCallback.onConfigureMTU(BluetoothGatt.this, mtu, status);
+                    mCallback.onMtuChanged(BluetoothGatt.this, mtu, status);
                 } catch (Exception ex) {
                     Log.w(TAG, "Unhandled exception in callback", ex);
                 }
@@ -616,7 +617,7 @@
                         + " congested=" + congested);
                 if (!address.equals(mDevice.getAddress())) return;
                 try {
-                    mCallback.onConnectionCongested(BluetoothGatt.this, congested);
+                    mIsCongested = congested;
                 } catch (Exception ex) {
                     Log.w(TAG, "Unhandled exception in callback", ex);
                 }
@@ -1239,20 +1240,20 @@
     }
 
     /**
-     * Configure the MTU used for a given connection.
+     * Request an MTU size used for a given connection.
      *
      * <p>When performing a write request operation (write without response),
      * the data sent is truncated to the MTU size. This function may be used
-     * to request a larget MTU size to be able to send more data at once.
+     * to request a larger MTU size to be able to send more data at once.
      *
-     * <p>A {@link BluetoothGattCallback#onConfigureMTU} callback will indicate
+     * <p>A {@link BluetoothGattCallback#onMtuChanged} callback will indicate
      * whether this operation was successful.
      *
      * <p>Requires {@link android.Manifest.permission#BLUETOOTH} permission.
      *
      * @return true, if the new MTU value has been requested successfully
      */
-    public boolean configureMTU(int mtu) {
+    public boolean requestMtu(int mtu) {
         if (DBG) Log.d(TAG, "configureMTU() - device: " + mDevice.getAddress()
                             + " mtu: " + mtu);
         if (mService == null || mClientIf == 0) return false;
@@ -1274,19 +1275,19 @@
      * remote device.
      *
      * @param connectionPriority Request a specific connection priority. Must be one of
-     *          {@link BluetoothGatt#GATT_CONNECTION_BALANCED},
-     *          {@link BluetoothGatt#GATT_CONNECTION_HIGH_PRIORITY}
-     *          or {@link BluetoothGatt#GATT_CONNECTION_LOW_POWER}.
+     *          {@link BluetoothGatt#CONNECTION_PRIORITY_BALANCED},
+     *          {@link BluetoothGatt#CONNECTION_PRIORITY_HIGH}
+     *          or {@link BluetoothGatt#CONNECTION_PRIORITY_LOW_POWER}.
      * @throws IllegalArgumentException If the parameters are outside of their
      *                                  specified range.
      */
-    public boolean requestConnectionParameterUpdate(int connectionPriority) {
-        if (connectionPriority < GATT_CONNECTION_BALANCED ||
-            connectionPriority > GATT_CONNECTION_LOW_POWER) {
+    public boolean requestConnectionPriority(int connectionPriority) {
+        if (connectionPriority < CONNECTION_PRIORITY_BALANCED ||
+            connectionPriority > CONNECTION_PRIORITY_LOW_POWER) {
             throw new IllegalArgumentException("connectionPriority not within valid range");
         }
 
-        if (DBG) Log.d(TAG, "requestConnectionParameterUpdate() - params: " + connectionPriority);
+        if (DBG) Log.d(TAG, "requestConnectionPriority() - params: " + connectionPriority);
         if (mService == null || mClientIf == 0) return false;
 
         try {
diff --git a/core/java/android/bluetooth/BluetoothGattCallback.java b/core/java/android/bluetooth/BluetoothGattCallback.java
index 5817d68..a915620 100644
--- a/core/java/android/bluetooth/BluetoothGattCallback.java
+++ b/core/java/android/bluetooth/BluetoothGattCallback.java
@@ -143,27 +143,13 @@
      * Callback indicating the MTU for a given device connection has changed.
      *
      * This callback is triggered in response to the
-     * {@link BluetoothGatt#configureMTU} function, or in response to a connection
+     * {@link BluetoothGatt#requestMtu} function, or in response to a connection
      * event.
      *
-     * @param gatt GATT client invoked {@link BluetoothGatt#configureMTU}
+     * @param gatt GATT client invoked {@link BluetoothGatt#requestMtu}
      * @param mtu The new MTU size
      * @param status {@link BluetoothGatt#GATT_SUCCESS} if the MTU has been changed successfully
      */
-    public void onConfigureMTU(BluetoothGatt gatt, int mtu, int status) {
-    }
-
-    /**
-     * Callback indicating that a remote device connection congestestion status has changed.
-     *
-     * An application should refrain from sending additional data to a remote device when
-     * a callback is received with the congested flag set to true. Once the congestion status
-     * is cleared up, the application will receive an additional callback with the congested
-     * flag set to false.
-     *
-     * @param gatt The GATT client associated with the remote device
-     * @param congested true, if the connection is currently congested
-     */
-    public void onConnectionCongested(BluetoothGatt gatt, boolean congested) {
+    public void onMtuChanged(BluetoothGatt gatt, int mtu, int status) {
     }
 }
diff --git a/core/java/android/bluetooth/BluetoothGattServer.java b/core/java/android/bluetooth/BluetoothGattServer.java
index c8df60e..a7f117b 100644
--- a/core/java/android/bluetooth/BluetoothGattServer.java
+++ b/core/java/android/bluetooth/BluetoothGattServer.java
@@ -48,6 +48,7 @@
     private BluetoothAdapter mAdapter;
     private IBluetoothGatt mService;
     private BluetoothGattServerCallback mCallback;
+    private Boolean mIsCongested = false;
 
     private Object mServerIfLock = new Object();
     private int mServerIf;
@@ -297,7 +298,7 @@
                 if (device == null) return;
 
                 try {
-                    mCallback.onConnectionCongested(device, congested);
+                    mIsCongested = congested;
                 } catch (Exception ex) {
                     Log.w(TAG, "Unhandled exception in callback", ex);
                 }
diff --git a/core/java/android/bluetooth/BluetoothGattServerCallback.java b/core/java/android/bluetooth/BluetoothGattServerCallback.java
index 3a1b38ee..1dd06f2 100644
--- a/core/java/android/bluetooth/BluetoothGattServerCallback.java
+++ b/core/java/android/bluetooth/BluetoothGattServerCallback.java
@@ -141,22 +141,8 @@
      * notifications.
      *
      * @param device The remote device the notification has been sent to
-     * @param status 0 if the operation was successful
+     * @param status {@link BluetoothGatt#GATT_SUCCESS} if the operation was successful
      */
     public void onNotificationSent(BluetoothDevice device, int status) {
     }
-
-    /**
-     * Callback indicating that a remote device connection congestestion status has changed.
-     *
-     * An application should refrain from sending additional data (notifications, indications
-     * etc.) to a remote device when a callback is received with the congested flag set
-     * to true. Once the congestion status is cleared up, the application will receive an
-     * additional callback with the congested flag set to false.
-     *
-     * @param device The remote device that triggered the congestion state change
-     * @param congested true, if the connection is currently congested
-     */
-    public void onConnectionCongested(BluetoothDevice device, boolean congested) {
-    }
 }
diff --git a/core/java/android/bluetooth/BluetoothSocket.java b/core/java/android/bluetooth/BluetoothSocket.java
index b98e5ae..36997e5 100644
--- a/core/java/android/bluetooth/BluetoothSocket.java
+++ b/core/java/android/bluetooth/BluetoothSocket.java
@@ -375,6 +375,14 @@
             } // else ASSERT(mPort == channel)
             ret = 0;
         } catch (IOException e) {
+            if (mPfd != null) {
+                try {
+                    mPfd.close();
+                } catch (IOException e1) {
+                    Log.e(TAG, "bindListen, close mPfd: " + e1);
+                }
+                mPfd = null;
+            }
             Log.e(TAG, "bindListen, fail to get port number, exception: " + e);
             return -1;
         }
diff --git a/core/java/android/bluetooth/IBluetooth.aidl b/core/java/android/bluetooth/IBluetooth.aidl
index 19c600c..cf2a343 100644
--- a/core/java/android/bluetooth/IBluetooth.aidl
+++ b/core/java/android/bluetooth/IBluetooth.aidl
@@ -75,6 +75,11 @@
     passkey);
     boolean setPairingConfirmation(in BluetoothDevice device, boolean accept);
 
+    int getPhonebookAccessPermission(in BluetoothDevice device);
+    boolean setPhonebookAccessPermission(in BluetoothDevice device, int value);
+    int getMessageAccessPermission(in BluetoothDevice device);
+    boolean setMessageAccessPermission(in BluetoothDevice device, int value);
+
     void sendConnectionStateChange(in BluetoothDevice device, int profile, int state, int prevState);
 
     void registerCallback(in IBluetoothCallback callback);
diff --git a/core/java/android/bluetooth/le/AdvertiseData.java b/core/java/android/bluetooth/le/AdvertiseData.java
index 843cd84..ff0db9a 100644
--- a/core/java/android/bluetooth/le/AdvertiseData.java
+++ b/core/java/android/bluetooth/le/AdvertiseData.java
@@ -119,8 +119,8 @@
         }
         AdvertiseData other = (AdvertiseData) obj;
         return Objects.equals(mServiceUuids, other.mServiceUuids) &&
-                Utils.equals(mManufacturerSpecificData, other.mManufacturerSpecificData) &&
-                Utils.equals(mServiceData, other.mServiceData) &&
+                BluetoothLeUtils.equals(mManufacturerSpecificData, other.mManufacturerSpecificData) &&
+                BluetoothLeUtils.equals(mServiceData, other.mServiceData) &&
                         mIncludeDeviceName == other.mIncludeDeviceName &&
                         mIncludeTxPowerLevel == other.mIncludeTxPowerLevel;
     }
@@ -128,8 +128,8 @@
     @Override
     public String toString() {
         return "AdvertiseData [mServiceUuids=" + mServiceUuids + ", mManufacturerSpecificData="
-                + Utils.toString(mManufacturerSpecificData) + ", mServiceData="
-                + Utils.toString(mServiceData)
+                + BluetoothLeUtils.toString(mManufacturerSpecificData) + ", mServiceData="
+                + BluetoothLeUtils.toString(mServiceData)
                 + ", mIncludeTxPowerLevel=" + mIncludeTxPowerLevel + ", mIncludeDeviceName="
                 + mIncludeDeviceName + "]";
     }
@@ -172,9 +172,6 @@
         dest.writeByte((byte) (getIncludeDeviceName() ? 1 : 0));
     }
 
-    /**
-     * @hide
-     */
     public static final Parcelable.Creator<AdvertiseData> CREATOR =
             new Creator<AdvertiseData>() {
             @Override
diff --git a/core/java/android/bluetooth/le/AdvertiseSettings.java b/core/java/android/bluetooth/le/AdvertiseSettings.java
index 71d7b5b..62c68a4 100644
--- a/core/java/android/bluetooth/le/AdvertiseSettings.java
+++ b/core/java/android/bluetooth/le/AdvertiseSettings.java
@@ -66,13 +66,13 @@
     public static final int ADVERTISE_TX_POWER_HIGH = 3;
 
     /**
-     * The maximimum limited advertisement duration as specified by the Bluetooth SIG
+     * The maximum limited advertisement duration as specified by the Bluetooth SIG
      */
-    private static final int LIMITED_ADVERTISING_MAX_DURATION = 180;
+    private static final int LIMITED_ADVERTISING_MAX_MILLIS = 180 * 1000;
 
     private final int mAdvertiseMode;
     private final int mAdvertiseTxPowerLevel;
-    private final int mAdvertiseTimeoutSeconds;
+    private final int mAdvertiseTimeoutMillis;
     private final boolean mAdvertiseConnectable;
 
     private AdvertiseSettings(int advertiseMode, int advertiseTxPowerLevel,
@@ -80,14 +80,14 @@
         mAdvertiseMode = advertiseMode;
         mAdvertiseTxPowerLevel = advertiseTxPowerLevel;
         mAdvertiseConnectable = advertiseConnectable;
-        mAdvertiseTimeoutSeconds = advertiseTimeout;
+        mAdvertiseTimeoutMillis = advertiseTimeout;
     }
 
     private AdvertiseSettings(Parcel in) {
         mAdvertiseMode = in.readInt();
         mAdvertiseTxPowerLevel = in.readInt();
         mAdvertiseConnectable = in.readInt() != 0 ? true : false;
-        mAdvertiseTimeoutSeconds = in.readInt();
+        mAdvertiseTimeoutMillis = in.readInt();
     }
 
     /**
@@ -107,15 +107,15 @@
     /**
      * Returns whether the advertisement will indicate connectable.
      */
-    public boolean getIsConnectable() {
+    public boolean isConnectable() {
         return mAdvertiseConnectable;
     }
 
     /**
-     * Returns the advertising time limit in seconds.
+     * Returns the advertising time limit in milliseconds.
      */
     public int getTimeout() {
-        return mAdvertiseTimeoutSeconds;
+        return mAdvertiseTimeoutMillis;
     }
 
     @Override
@@ -123,7 +123,7 @@
         return "Settings [mAdvertiseMode=" + mAdvertiseMode
              + ", mAdvertiseTxPowerLevel=" + mAdvertiseTxPowerLevel
              + ", mAdvertiseConnectable=" + mAdvertiseConnectable
-             + ", mAdvertiseTimeoutSeconds=" + mAdvertiseTimeoutSeconds + "]";
+             + ", mAdvertiseTimeoutMillis=" + mAdvertiseTimeoutMillis + "]";
     }
 
     @Override
@@ -136,12 +136,9 @@
         dest.writeInt(mAdvertiseMode);
         dest.writeInt(mAdvertiseTxPowerLevel);
         dest.writeInt(mAdvertiseConnectable ? 1 : 0);
-        dest.writeInt(mAdvertiseTimeoutSeconds);
+        dest.writeInt(mAdvertiseTimeoutMillis);
     }
 
-    /**
-     * @hide
-     */
     public static final Parcelable.Creator<AdvertiseSettings> CREATOR =
             new Creator<AdvertiseSettings>() {
             @Override
@@ -161,7 +158,7 @@
     public static final class Builder {
         private int mMode = ADVERTISE_MODE_LOW_POWER;
         private int mTxPowerLevel = ADVERTISE_TX_POWER_MEDIUM;
-        private int mTimeoutSeconds = 0;
+        private int mTimeoutMillis = 0;
         private boolean mConnectable = true;
 
         /**
@@ -204,26 +201,26 @@
         /**
          * Set whether the advertisement type should be connectable or non-connectable.
          *
-         * @param isConnectable Controls whether the advertisment type will be connectable (true)
+         * @param connectable Controls whether the advertisment type will be connectable (true)
          *                    or non-connectable (false).
          */
-        public Builder setIsConnectable(boolean isConnectable) {
-            mConnectable = isConnectable;
+        public Builder setConnectable(boolean connectable) {
+            mConnectable = connectable;
             return this;
         }
 
         /**
          * Limit advertising to a given amount of time.
-         * @param timeoutSeconds Advertising time limit. May not exceed 180 seconds.
+         * @param timeoutMillis Advertising time limit. May not exceed 180000 milliseconds.
          *                       A value of 0 will disable the time limit.
-         * @throws IllegalArgumentException If the provided timeout is over 180s.
+         * @throws IllegalArgumentException If the provided timeout is over 180000 ms.
          */
-        public Builder setTimeout(int timeoutSeconds) {
-            if (timeoutSeconds < 0 || timeoutSeconds > LIMITED_ADVERTISING_MAX_DURATION) {
-                throw new IllegalArgumentException("timeoutSeconds invalid (must be 0-"
-                                    + LIMITED_ADVERTISING_MAX_DURATION + " seconds)");
+        public Builder setTimeout(int timeoutMillis) {
+            if (timeoutMillis < 0 || timeoutMillis > LIMITED_ADVERTISING_MAX_MILLIS) {
+                throw new IllegalArgumentException("timeoutMillis invalid (must be 0-"
+                                    + LIMITED_ADVERTISING_MAX_MILLIS + " milliseconds)");
             }
-            mTimeoutSeconds = timeoutSeconds;
+            mTimeoutMillis = timeoutMillis;
             return this;
         }
 
@@ -231,7 +228,7 @@
          * Build the {@link AdvertiseSettings} object.
          */
         public AdvertiseSettings build() {
-            return new AdvertiseSettings(mMode, mTxPowerLevel, mConnectable, mTimeoutSeconds);
+            return new AdvertiseSettings(mMode, mTxPowerLevel, mConnectable, mTimeoutMillis);
         }
     }
 }
diff --git a/core/java/android/bluetooth/le/BluetoothLeAdvertiser.java b/core/java/android/bluetooth/le/BluetoothLeAdvertiser.java
index f6315ac..d468508 100644
--- a/core/java/android/bluetooth/le/BluetoothLeAdvertiser.java
+++ b/core/java/android/bluetooth/le/BluetoothLeAdvertiser.java
@@ -21,7 +21,6 @@
 import android.bluetooth.BluetoothGattCallbackWrapper;
 import android.bluetooth.BluetoothUuid;
 import android.bluetooth.IBluetoothGatt;
-import android.bluetooth.IBluetoothGattCallback;
 import android.bluetooth.IBluetoothManager;
 import android.os.Handler;
 import android.os.Looper;
@@ -30,7 +29,6 @@
 import android.util.Log;
 
 import java.util.HashMap;
-import java.util.List;
 import java.util.Map;
 import java.util.UUID;
 
@@ -108,41 +106,37 @@
     public void startAdvertising(AdvertiseSettings settings,
             AdvertiseData advertiseData, AdvertiseData scanResponse,
             final AdvertiseCallback callback) {
-        checkAdapterState();
-        if (callback == null) {
-            throw new IllegalArgumentException("callback cannot be null");
-        }
-        if (totalBytes(advertiseData) > MAX_ADVERTISING_DATA_BYTES ||
-                totalBytes(scanResponse) > MAX_ADVERTISING_DATA_BYTES) {
-            postCallbackFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_DATA_TOO_LARGE);
-            return;
-        }
-        if (mLeAdvertisers.containsKey(callback)) {
-            postCallbackFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_ALREADY_STARTED);
-            return;
-        }
-        IBluetoothGatt gatt;
-        try {
-            gatt = mBluetoothManager.getBluetoothGatt();
-        } catch (RemoteException e) {
-            Log.e(TAG, "Failed to get Bluetooth gatt - ", e);
-            postCallbackFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR);
-            return;
-        }
-        if (!mBluetoothAdapter.isMultipleAdvertisementSupported()) {
-            postCallbackFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_FEATURE_UNSUPPORTED);
-            return;
-        }
-        AdvertiseCallbackWrapper wrapper = new AdvertiseCallbackWrapper(callback, advertiseData,
-                scanResponse, settings, gatt);
-        UUID uuid = UUID.randomUUID();
-        try {
-            gatt.registerClient(new ParcelUuid(uuid), wrapper);
-            if (wrapper.advertiseStarted()) {
-                mLeAdvertisers.put(callback, wrapper);
+        synchronized (mLeAdvertisers) {
+            BluetoothLeUtils.checkAdapterStateOn(mBluetoothAdapter);
+            if (callback == null) {
+                throw new IllegalArgumentException("callback cannot be null");
             }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Failed to stop advertising", e);
+            if (!mBluetoothAdapter.isMultipleAdvertisementSupported()) {
+                postStartFailure(callback,
+                        AdvertiseCallback.ADVERTISE_FAILED_FEATURE_UNSUPPORTED);
+                return;
+            }
+            if (totalBytes(advertiseData) > MAX_ADVERTISING_DATA_BYTES ||
+                    totalBytes(scanResponse) > MAX_ADVERTISING_DATA_BYTES) {
+                postStartFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_DATA_TOO_LARGE);
+                return;
+            }
+            if (mLeAdvertisers.containsKey(callback)) {
+                postStartFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_ALREADY_STARTED);
+                return;
+            }
+
+            IBluetoothGatt gatt;
+            try {
+                gatt = mBluetoothManager.getBluetoothGatt();
+            } catch (RemoteException e) {
+                Log.e(TAG, "Failed to get Bluetooth gatt - ", e);
+                postStartFailure(callback, AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR);
+                return;
+            }
+            AdvertiseCallbackWrapper wrapper = new AdvertiseCallbackWrapper(callback, advertiseData,
+                    scanResponse, settings, gatt);
+            wrapper.startRegisteration();
         }
     }
 
@@ -155,23 +149,14 @@
      * @param callback {@link AdvertiseCallback} identifies the advertising instance to stop.
      */
     public void stopAdvertising(final AdvertiseCallback callback) {
-        checkAdapterState();
-        if (callback == null) {
-            throw new IllegalArgumentException("callback cannot be null");
-        }
-        AdvertiseCallbackWrapper wrapper = mLeAdvertisers.get(callback);
-        if (wrapper == null)
-            return;
-        try {
-            IBluetoothGatt gatt = mBluetoothManager.getBluetoothGatt();
-            if (gatt != null)
-                gatt.stopMultiAdvertising(wrapper.mClientIf);
-
-            if (wrapper.advertiseStopped()) {
-                mLeAdvertisers.remove(callback);
+        synchronized (mLeAdvertisers) {
+            BluetoothLeUtils.checkAdapterStateOn(mBluetoothAdapter);
+            if (callback == null) {
+                throw new IllegalArgumentException("callback cannot be null");
             }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Failed to stop advertising", e);
+            AdvertiseCallbackWrapper wrapper = mLeAdvertisers.get(callback);
+            if (wrapper == null) return;
+            wrapper.stopAdvertising();
         }
     }
 
@@ -186,9 +171,7 @@
 
     // Compute the size of the advertise data.
     private int totalBytes(AdvertiseData data) {
-        if (data == null) {
-            return 0;
-        }
+        if (data == null) return 0;
         int size = FLAGS_FIELD_BYTES; // flags field is always set.
         if (data.getServiceUuids() != null) {
             int num16BitUuids = 0;
@@ -243,7 +226,7 @@
     /**
      * Bluetooth GATT interface callbacks for advertising.
      */
-    private static class AdvertiseCallbackWrapper extends BluetoothGattCallbackWrapper {
+    private class AdvertiseCallbackWrapper extends BluetoothGattCallbackWrapper {
         private static final int LE_CALLBACK_TIMEOUT_MILLIS = 2000;
         private final AdvertiseCallback mAdvertiseCallback;
         private final AdvertiseData mAdvertisement;
@@ -269,30 +252,49 @@
             mClientIf = 0;
         }
 
-        public boolean advertiseStarted() {
-            boolean started = false;
+        public void startRegisteration() {
             synchronized (this) {
-                if (mClientIf == -1) {
-                    return false;
-                }
+                if (mClientIf == -1) return;
+
                 try {
+                    UUID uuid = UUID.randomUUID();
+                    mBluetoothGatt.registerClient(new ParcelUuid(uuid), this);
                     wait(LE_CALLBACK_TIMEOUT_MILLIS);
-                } catch (InterruptedException e) {
-                    Log.e(TAG, "Callback reg wait interrupted: ", e);
+                } catch (InterruptedException | RemoteException e) {
+                    Log.e(TAG, "Failed to start registeration", e);
                 }
-                started = (mClientIf > 0 && mIsAdvertising);
+                if (mClientIf > 0 && mIsAdvertising) {
+                    mLeAdvertisers.put(mAdvertiseCallback, this);
+                } else if (mClientIf <= 0) {
+                    // Post internal error if registration failed.
+                    postStartFailure(mAdvertiseCallback,
+                            AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR);
+                } else {
+                    // Unregister application if it's already registered but advertise failed.
+                    try {
+                        mBluetoothGatt.unregisterClient(mClientIf);
+                        mClientIf = -1;
+                    } catch (RemoteException e) {
+                        Log.e(TAG, "remote exception when unregistering", e);
+                    }
+                }
             }
-            return started;
         }
 
-        public boolean advertiseStopped() {
+        public void stopAdvertising() {
             synchronized (this) {
                 try {
+                    mBluetoothGatt.stopMultiAdvertising(mClientIf);
                     wait(LE_CALLBACK_TIMEOUT_MILLIS);
-                } catch (InterruptedException e) {
-                    Log.e(TAG, "Callback reg wait interrupted: " + e);
+                } catch (InterruptedException | RemoteException e) {
+                    Log.e(TAG, "Failed to stop advertising", e);
                 }
-                return !mIsAdvertising;
+                // Advertise callback should have been removed from LeAdvertisers when
+                // onMultiAdvertiseCallback was called. In case onMultiAdvertiseCallback is never
+                // invoked and wait timeout expires, remove callback here.
+                if (mLeAdvertisers.containsKey(mAdvertiseCallback)) {
+                    mLeAdvertisers.remove(mAdvertiseCallback);
+                }
             }
         }
 
@@ -308,16 +310,14 @@
                     try {
                         mBluetoothGatt.startMultiAdvertising(mClientIf, mAdvertisement,
                                 mScanResponse, mSettings);
+                        return;
                     } catch (RemoteException e) {
-                        Log.e(TAG, "fail to start le advertise: " + e);
-                        mClientIf = -1;
-                        notifyAll();
+                        Log.e(TAG, "failed to start advertising", e);
                     }
-                } else {
-                    // registration failed
-                    mClientIf = -1;
-                    notifyAll();
                 }
+                // Registration failed.
+                mClientIf = -1;
+                notifyAll();
             }
         }
 
@@ -328,11 +328,11 @@
                 if (isStart) {
                     if (status == AdvertiseCallback.ADVERTISE_SUCCESS) {
                         // Start success
-                        mAdvertiseCallback.onStartSuccess(settings);
                         mIsAdvertising = true;
+                        postStartSuccess(mAdvertiseCallback, settings);
                     } else {
                         // Start failure.
-                        mAdvertiseCallback.onStartFailure(status);
+                        postStartFailure(mAdvertiseCallback, status);
                     }
                 } else {
                     // unregister client for stop.
@@ -340,6 +340,7 @@
                         mBluetoothGatt.unregisterClient(mClientIf);
                         mClientIf = -1;
                         mIsAdvertising = false;
+                        mLeAdvertisers.remove(mAdvertiseCallback);
                     } catch (RemoteException e) {
                         Log.e(TAG, "remote exception when unregistering", e);
                     }
@@ -350,19 +351,23 @@
         }
     }
 
-    // TODO: move this api to a common util class.
-    private void checkAdapterState() {
-        if (mBluetoothAdapter.getState() != mBluetoothAdapter.STATE_ON) {
-            throw new IllegalStateException("BT Adapter is not turned ON");
-        }
-    }
-
-    private void postCallbackFailure(final AdvertiseCallback callback, final int error) {
+    private void postStartFailure(final AdvertiseCallback callback, final int error) {
         mHandler.post(new Runnable() {
-                @Override
+            @Override
             public void run() {
                 callback.onStartFailure(error);
             }
         });
     }
+
+    private void postStartSuccess(final AdvertiseCallback callback,
+            final AdvertiseSettings settings) {
+        mHandler.post(new Runnable() {
+
+            @Override
+            public void run() {
+                callback.onStartSuccess(settings);
+            }
+        });
+    }
 }
diff --git a/core/java/android/bluetooth/le/BluetoothLeScanner.java b/core/java/android/bluetooth/le/BluetoothLeScanner.java
index 988cea5..a57c3ca 100644
--- a/core/java/android/bluetooth/le/BluetoothLeScanner.java
+++ b/core/java/android/bluetooth/le/BluetoothLeScanner.java
@@ -80,11 +80,10 @@
      * @throws IllegalArgumentException If {@code callback} is null.
      */
     public void startScan(final ScanCallback callback) {
-        checkAdapterState();
         if (callback == null) {
             throw new IllegalArgumentException("callback is null");
         }
-        this.startScan(null, new ScanSettings.Builder().build(), callback);
+        startScan(null, new ScanSettings.Builder().build(), callback);
     }
 
     /**
@@ -104,7 +103,7 @@
 
     private void startScan(List<ScanFilter> filters, ScanSettings settings,
             final ScanCallback callback, List<List<ResultStorageDescriptor>> resultStorages) {
-        checkAdapterState();
+        BluetoothLeUtils.checkAdapterStateOn(mBluetoothAdapter);
         if (settings == null || callback == null) {
             throw new IllegalArgumentException("settings or callback is null");
         }
@@ -130,20 +129,7 @@
             }
             BleScanCallbackWrapper wrapper = new BleScanCallbackWrapper(gatt, filters,
                     settings, callback, resultStorages);
-            try {
-                UUID uuid = UUID.randomUUID();
-                gatt.registerClient(new ParcelUuid(uuid), wrapper);
-                if (wrapper.scanStarted()) {
-                    mLeScanClients.put(callback, wrapper);
-                } else {
-                    postCallbackError(callback,
-                            ScanCallback.SCAN_FAILED_APPLICATION_REGISTRATION_FAILED);
-                    return;
-                }
-            } catch (RemoteException e) {
-                Log.e(TAG, "GATT service exception when starting scan", e);
-                postCallbackError(callback, ScanCallback.SCAN_FAILED_INTERNAL_ERROR);
-            }
+            wrapper.startRegisteration();
         }
     }
 
@@ -155,12 +141,11 @@
      * @param callback
      */
     public void stopScan(ScanCallback callback) {
-        checkAdapterState();
+        BluetoothLeUtils.checkAdapterStateOn(mBluetoothAdapter);
         synchronized (mLeScanClients) {
             BleScanCallbackWrapper wrapper = mLeScanClients.remove(callback);
             if (wrapper == null) {
-                if (DBG)
-                    Log.d(TAG, "could not find callback wrapper");
+                if (DBG) Log.d(TAG, "could not find callback wrapper");
                 return;
             }
             wrapper.stopLeScan();
@@ -176,7 +161,7 @@
      *            used to start scan.
      */
     public void flushPendingScanResults(ScanCallback callback) {
-        checkAdapterState();
+        BluetoothLeUtils.checkAdapterStateOn(mBluetoothAdapter);
         if (callback == null) {
             throw new IllegalArgumentException("callback cannot be null!");
         }
@@ -220,8 +205,8 @@
     /**
      * Bluetooth GATT interface callbacks
      */
-    private static class BleScanCallbackWrapper extends BluetoothGattCallbackWrapper {
-        private static final int REGISTRATION_CALLBACK_TIMEOUT_SECONDS = 5;
+    private class BleScanCallbackWrapper extends BluetoothGattCallbackWrapper {
+        private static final int REGISTRATION_CALLBACK_TIMEOUT_MILLIS = 2000;
 
         private final ScanCallback mScanCallback;
         private final List<ScanFilter> mFilters;
@@ -245,18 +230,25 @@
             mResultStorages = resultStorages;
         }
 
-        public boolean scanStarted() {
+        public void startRegisteration() {
             synchronized (this) {
-                if (mClientIf == -1) {
-                    return false;
-                }
+                // Scan stopped.
+                if (mClientIf == -1) return;
                 try {
-                    wait(REGISTRATION_CALLBACK_TIMEOUT_SECONDS);
-                } catch (InterruptedException e) {
-                    Log.e(TAG, "Callback reg wait interrupted: " + e);
+                    UUID uuid = UUID.randomUUID();
+                    mBluetoothGatt.registerClient(new ParcelUuid(uuid), this);
+                    wait(REGISTRATION_CALLBACK_TIMEOUT_MILLIS);
+                } catch (InterruptedException | RemoteException e) {
+                    Log.e(TAG, "application registeration exception", e);
+                    postCallbackError(mScanCallback, ScanCallback.SCAN_FAILED_INTERNAL_ERROR);
+                }
+                if (mClientIf > 0) {
+                    mLeScanClients.put(mScanCallback, this);
+                } else {
+                    postCallbackError(mScanCallback,
+                            ScanCallback.SCAN_FAILED_APPLICATION_REGISTRATION_FAILED);
                 }
             }
-            return mClientIf > 0;
         }
 
         public void stopLeScan() {
@@ -272,7 +264,6 @@
                     Log.e(TAG, "Failed to stop scan and unregister", e);
                 }
                 mClientIf = -1;
-                notifyAll();
             }
         }
 
@@ -297,11 +288,9 @@
         public void onClientRegistered(int status, int clientIf) {
             Log.d(TAG, "onClientRegistered() - status=" + status +
                     " clientIf=" + clientIf);
-
             synchronized (this) {
                 if (mClientIf == -1) {
-                    if (DBG)
-                        Log.d(TAG, "onClientRegistered LE scan canceled");
+                    if (DBG) Log.d(TAG, "onClientRegistered LE scan canceled");
                 }
 
                 if (status == BluetoothGatt.GATT_SUCCESS) {
@@ -328,17 +317,15 @@
          */
         @Override
         public void onScanResult(final ScanResult scanResult) {
-            if (DBG)
-                Log.d(TAG, "onScanResult() - " + scanResult.toString());
+            if (DBG) Log.d(TAG, "onScanResult() - " + scanResult.toString());
 
             // Check null in case the scan has been stopped
             synchronized (this) {
-                if (mClientIf <= 0)
-                    return;
+                if (mClientIf <= 0) return;
             }
             Handler handler = new Handler(Looper.getMainLooper());
             handler.post(new Runnable() {
-                    @Override
+                @Override
                 public void run() {
                     mScanCallback.onScanResult(ScanSettings.CALLBACK_TYPE_ALL_MATCHES, scanResult);
                 }
@@ -350,7 +337,7 @@
         public void onBatchScanResults(final List<ScanResult> results) {
             Handler handler = new Handler(Looper.getMainLooper());
             handler.post(new Runnable() {
-                    @Override
+                @Override
                 public void run() {
                     mScanCallback.onBatchScanResults(results);
                 }
@@ -385,16 +372,9 @@
         }
     }
 
-    // TODO: move this api to a common util class.
-    private void checkAdapterState() {
-        if (mBluetoothAdapter.getState() != mBluetoothAdapter.STATE_ON) {
-            throw new IllegalStateException("BT Adapter is not turned ON");
-        }
-    }
-
     private void postCallbackError(final ScanCallback callback, final int errorCode) {
         mHandler.post(new Runnable() {
-                @Override
+            @Override
             public void run() {
                 callback.onScanFailed(errorCode);
             }
diff --git a/core/java/android/bluetooth/le/BluetoothLeUtils.java b/core/java/android/bluetooth/le/BluetoothLeUtils.java
new file mode 100644
index 0000000..4916bd9
--- /dev/null
+++ b/core/java/android/bluetooth/le/BluetoothLeUtils.java
@@ -0,0 +1,140 @@
+/*
+ * Copyright (C) 2014 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 android.bluetooth.le;
+
+import android.bluetooth.BluetoothAdapter;
+import android.util.SparseArray;
+
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Set;
+
+/**
+ * Helper class for Bluetooth LE utils.
+ *
+ * @hide
+ */
+public class BluetoothLeUtils {
+
+    /**
+     * Returns a string composed from a {@link SparseArray}.
+     */
+    static String toString(SparseArray<byte[]> array) {
+        if (array == null) {
+            return "null";
+        }
+        if (array.size() == 0) {
+            return "{}";
+        }
+        StringBuilder buffer = new StringBuilder();
+        buffer.append('{');
+        for (int i = 0; i < array.size(); ++i) {
+            buffer.append(array.keyAt(i)).append("=").append(Arrays.toString(array.valueAt(i)));
+        }
+        buffer.append('}');
+        return buffer.toString();
+    }
+
+    /**
+     * Returns a string composed from a {@link Map}.
+     */
+    static <T> String toString(Map<T, byte[]> map) {
+        if (map == null) {
+            return "null";
+        }
+        if (map.isEmpty()) {
+            return "{}";
+        }
+        StringBuilder buffer = new StringBuilder();
+        buffer.append('{');
+        Iterator<Map.Entry<T, byte[]>> it = map.entrySet().iterator();
+        while (it.hasNext()) {
+            Map.Entry<T, byte[]> entry = it.next();
+            Object key = entry.getKey();
+            buffer.append(key).append("=").append(Arrays.toString(map.get(key)));
+            if (it.hasNext()) {
+                buffer.append(", ");
+            }
+        }
+        buffer.append('}');
+        return buffer.toString();
+    }
+
+    /**
+     * Check whether two {@link SparseArray} equal.
+     */
+    static boolean equals(SparseArray<byte[]> array, SparseArray<byte[]> otherArray) {
+        if (array == otherArray) {
+            return true;
+        }
+        if (array == null || otherArray == null) {
+            return false;
+        }
+        if (array.size() != otherArray.size()) {
+            return false;
+        }
+
+        // Keys are guaranteed in ascending order when indices are in ascending order.
+        for (int i = 0; i < array.size(); ++i) {
+            if (array.keyAt(i) != otherArray.keyAt(i) ||
+                    !Arrays.equals(array.valueAt(i), otherArray.valueAt(i))) {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * Check whether two {@link Map} equal.
+     */
+    static <T> boolean equals(Map<T, byte[]> map, Map<T, byte[]> otherMap) {
+        if (map == otherMap) {
+            return true;
+        }
+        if (map == null || otherMap == null) {
+            return false;
+        }
+        if (map.size() != otherMap.size()) {
+            return false;
+        }
+        Set<T> keys = map.keySet();
+        if (!keys.equals(otherMap.keySet())) {
+            return false;
+        }
+        for (T key : keys) {
+            if (!Objects.deepEquals(map.get(key), otherMap.get(key))) {
+                return false;
+            }
+        }
+        return true;
+    }
+
+    /**
+     * Ensure Bluetooth is turned on.
+     *
+     * @throws IllegalStateException If {@code adapter} is null or Bluetooth state is not
+     *             {@link BluetoothAdapter#STATE_ON}.
+     */
+    static void checkAdapterStateOn(BluetoothAdapter adapter) {
+        if (adapter == null || adapter.getState() != BluetoothAdapter.STATE_ON) {
+            throw new IllegalStateException("BT Adapter is not turned ON");
+        }
+    }
+
+}
diff --git a/core/java/android/bluetooth/le/ScanCallback.java b/core/java/android/bluetooth/le/ScanCallback.java
index 5b37384..05782a8 100644
--- a/core/java/android/bluetooth/le/ScanCallback.java
+++ b/core/java/android/bluetooth/le/ScanCallback.java
@@ -47,8 +47,8 @@
     /**
      * Callback when a BLE advertisement has been found.
      *
-     * @param callbackType Determines if this callback was triggered because of first match, a lost
-     *            match indication or a regular scan result.
+     * @param callbackType Determines how this callback was triggered. Currently could only be
+     *            {@link ScanSettings#CALLBACK_TYPE_ALL_MATCHES}.
      * @param result A Bluetooth LE scan result.
      */
     public void onScanResult(int callbackType, ScanResult result) {
@@ -64,6 +64,7 @@
 
     /**
      * Callback when scan could not be started.
+     *
      * @param errorCode Error code (one of SCAN_FAILED_*) for scan failure.
      */
     public void onScanFailed(int errorCode) {
diff --git a/core/java/android/bluetooth/le/ScanFilter.java b/core/java/android/bluetooth/le/ScanFilter.java
index d1b93d2..5025218 100644
--- a/core/java/android/bluetooth/le/ScanFilter.java
+++ b/core/java/android/bluetooth/le/ScanFilter.java
@@ -138,8 +138,6 @@
 
     /**
      * A {@link android.os.Parcelable.Creator} to create {@link ScanFilter} from parcel.
-     *
-     * @hide
      */
     public static final Creator<ScanFilter>
             CREATOR = new Creator<ScanFilter>() {
diff --git a/core/java/android/bluetooth/le/ScanRecord.java b/core/java/android/bluetooth/le/ScanRecord.java
index 2f3d06f..f802e8d 100644
--- a/core/java/android/bluetooth/le/ScanRecord.java
+++ b/core/java/android/bluetooth/le/ScanRecord.java
@@ -268,8 +268,8 @@
     @Override
     public String toString() {
         return "ScanRecord [mAdvertiseFlags=" + mAdvertiseFlags + ", mServiceUuids=" + mServiceUuids
-                + ", mManufacturerSpecificData=" + Utils.toString(mManufacturerSpecificData)
-                + ", mServiceData=" + Utils.toString(mServiceData)
+                + ", mManufacturerSpecificData=" + BluetoothLeUtils.toString(mManufacturerSpecificData)
+                + ", mServiceData=" + BluetoothLeUtils.toString(mServiceData)
                 + ", mTxPowerLevel=" + mTxPowerLevel + ", mDeviceName=" + mDeviceName + "]";
     }
 
diff --git a/core/java/android/bluetooth/le/ScanResult.java b/core/java/android/bluetooth/le/ScanResult.java
index a0bdaff..2fdfe7f 100644
--- a/core/java/android/bluetooth/le/ScanResult.java
+++ b/core/java/android/bluetooth/le/ScanResult.java
@@ -149,9 +149,6 @@
                 + mTimestampNanos + '}';
     }
 
-    /**
-     * @hide
-     */
     public static final Parcelable.Creator<ScanResult> CREATOR = new Creator<ScanResult>() {
             @Override
         public ScanResult createFromParcel(Parcel source) {
diff --git a/core/java/android/bluetooth/le/ScanSettings.java b/core/java/android/bluetooth/le/ScanSettings.java
index b2ee6a8..7eae439 100644
--- a/core/java/android/bluetooth/le/ScanSettings.java
+++ b/core/java/android/bluetooth/le/ScanSettings.java
@@ -52,19 +52,28 @@
     /**
      * A result callback is only triggered for the first advertisement packet received that matches
      * the filter criteria.
+     *
+     * @hide
      */
+    @SystemApi
     public static final int CALLBACK_TYPE_FIRST_MATCH = 2;
 
     /**
      * Receive a callback when advertisements are no longer received from a device that has been
      * previously reported by a first match callback.
+     *
+     * @hide
      */
+    @SystemApi
     public static final int CALLBACK_TYPE_MATCH_LOST = 4;
 
     /**
      * Request full scan results which contain the device, rssi, advertising data, scan response as
      * well as the scan timestamp.
+     *
+     * @hide
      */
+    @SystemApi
     public static final int SCAN_RESULT_TYPE_FULL = 0;
 
     /**
@@ -137,9 +146,6 @@
         return 0;
     }
 
-    /**
-     * @hide
-     */
     public static final Parcelable.Creator<ScanSettings>
             CREATOR = new Creator<ScanSettings>() {
                     @Override
@@ -183,7 +189,9 @@
          *
          * @param callbackType The callback type flags for the scan.
          * @throws IllegalArgumentException If the {@code callbackType} is invalid.
+         * @hide
          */
+        @SystemApi
         public Builder setCallbackType(int callbackType) {
 
             if (!isValidCallbackType(callbackType)) {
@@ -226,14 +234,14 @@
         /**
          * Set report delay timestamp for Bluetooth LE scan.
          *
-         * @param reportDelayMillis Set to 0 to be notified of results immediately. Values &gt; 0
-         *            causes the scan results to be queued up and delivered after the requested
-         *            delay or when the internal buffers fill up.
+         * @param reportDelayMillis Delay of report in milliseconds. Set to 0 to be notified of
+         *            results immediately. Values &gt; 0 causes the scan results to be queued up and
+         *            delivered after the requested delay or when the internal buffers fill up.
          * @throws IllegalArgumentException If {@code reportDelayMillis} &lt; 0.
          */
-        public Builder setReportDelayMillis(long reportDelayMillis) {
+        public Builder setReportDelay(long reportDelayMillis) {
             if (reportDelayMillis < 0) {
-                throw new IllegalArgumentException("reportDelayMillis must be > 0");
+                throw new IllegalArgumentException("reportDelay must be > 0");
             }
             mReportDelayMillis = reportDelayMillis;
             return this;
diff --git a/core/java/android/bluetooth/le/Utils.java b/core/java/android/bluetooth/le/Utils.java
deleted file mode 100644
index ccdae69..0000000
--- a/core/java/android/bluetooth/le/Utils.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.bluetooth.le;
-
-import android.util.SparseArray;
-
-import java.util.Arrays;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Objects;
-import java.util.Set;
-
-/**
- * Helper class for Bluetooth LE utils.
- *
- * @hide
- */
-public class Utils {
-
-    /**
-     * Returns a string composed from a {@link SparseArray}.
-     */
-    static String toString(SparseArray<byte[]> array) {
-        if (array == null) {
-            return "null";
-        }
-        if (array.size() == 0) {
-            return "{}";
-        }
-        StringBuilder buffer = new StringBuilder();
-        buffer.append('{');
-        for (int i = 0; i < array.size(); ++i) {
-            buffer.append(array.keyAt(i)).append("=").append(Arrays.toString(array.valueAt(i)));
-        }
-        buffer.append('}');
-        return buffer.toString();
-    }
-
-    /**
-     * Returns a string composed from a {@link Map}.
-     */
-    static <T> String toString(Map<T, byte[]> map) {
-        if (map == null) {
-            return "null";
-        }
-        if (map.isEmpty()) {
-            return "{}";
-        }
-        StringBuilder buffer = new StringBuilder();
-        buffer.append('{');
-        Iterator<Map.Entry<T, byte[]>> it = map.entrySet().iterator();
-        while (it.hasNext()) {
-            Map.Entry<T, byte[]> entry = it.next();
-            Object key = entry.getKey();
-            buffer.append(key).append("=").append(Arrays.toString(map.get(key)));
-            if (it.hasNext()) {
-                buffer.append(", ");
-            }
-        }
-        buffer.append('}');
-        return buffer.toString();
-    }
-
-    /**
-     * Check whether two {@link SparseArray} equal.
-     */
-    static boolean equals(SparseArray<byte[]> array, SparseArray<byte[]> otherArray) {
-        if (array == otherArray) {
-            return true;
-        }
-        if (array == null || otherArray == null) {
-            return false;
-        }
-        if (array.size() != otherArray.size()) {
-            return false;
-        }
-
-        // Keys are guaranteed in ascending order when indices are in ascending order.
-        for (int i = 0; i < array.size(); ++i) {
-            if (array.keyAt(i) != otherArray.keyAt(i) ||
-                    !Arrays.equals(array.valueAt(i), otherArray.valueAt(i))) {
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /**
-     * Check whether two {@link Map} equal.
-     */
-    static <T> boolean equals(Map<T, byte[]> map, Map<T, byte[]> otherMap) {
-        if (map == otherMap) {
-            return true;
-        }
-        if (map == null || otherMap == null) {
-            return false;
-        }
-        if (map.size() != otherMap.size()) {
-            return false;
-        }
-        Set<T> keys = map.keySet();
-        if (!keys.equals(otherMap.keySet())) {
-            return false;
-        }
-        for (T key : keys) {
-            if (!Objects.deepEquals(map.get(key), otherMap.get(key))) {
-                return false;
-            }
-        }
-        return true;
-    }
-}
diff --git a/core/java/android/content/AbstractRestrictionsProvider.java b/core/java/android/content/AbstractRestrictionsProvider.java
deleted file mode 100644
index 2b40870..0000000
--- a/core/java/android/content/AbstractRestrictionsProvider.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.content;
-
-import android.app.admin.DevicePolicyManager;
-import android.os.IBinder;
-import android.os.PersistableBundle;
-
-/**
- * Abstract implementation of a Restrictions Provider BroadcastReceiver. To implement a
- * Restrictions Provider, extend from this class and implement the abstract methods.
- * Export this receiver in the manifest. A profile owner device admin can then register this
- * component as a Restrictions Provider using
- * {@link DevicePolicyManager#setRestrictionsProvider(ComponentName, ComponentName)}.
- * <p>
- * The function of a Restrictions Provider is to transport permission requests from apps on this
- * device to an administrator (most likely on a remote device or computer) and deliver back
- * responses. The response should be sent back to the app via
- * {@link RestrictionsManager#notifyPermissionResponse(String, PersistableBundle)}.
- *
- * @see RestrictionsManager
- */
-public abstract class AbstractRestrictionsProvider extends BroadcastReceiver {
-
-    private static final String TAG = "AbstractRestrictionsProvider";
-
-    /**
-     * An asynchronous permission request made by an application for an operation that requires
-     * authorization by a local or remote administrator other than the user. The Restrictions
-     * Provider should transfer the request to the administrator and deliver back a response, when
-     * available. The calling application is aware that the response could take an indefinite
-     * amount of time.
-     * <p>
-     * If the request bundle contains the key {@link RestrictionsManager#REQUEST_KEY_NEW_REQUEST},
-     * then a new request must be sent. Otherwise the provider can look up any previous response
-     * to the same requestId and return the cached response.
-     *
-     * @param packageName the application requesting permission.
-     * @param requestType the type of request, which determines the content and presentation of
-     * the request data.
-     * @param request the request data bundle containing at a minimum a request id.
-     *
-     * @see RestrictionsManager#REQUEST_TYPE_APPROVAL
-     * @see RestrictionsManager#REQUEST_TYPE_LOCAL_APPROVAL
-     * @see RestrictionsManager#REQUEST_KEY_ID
-     */
-    public abstract void requestPermission(Context context,
-            String packageName, String requestType, String requestId, PersistableBundle request);
-
-    /**
-     * Intercept standard Restrictions Provider broadcasts.  Implementations
-     * should not override this method; it is better to implement the
-     * convenience callbacks for each action.
-     */
-    @Override
-    public void onReceive(Context context, Intent intent) {
-        String action = intent.getAction();
-
-        if (RestrictionsManager.ACTION_REQUEST_PERMISSION.equals(action)) {
-            String packageName = intent.getStringExtra(RestrictionsManager.EXTRA_PACKAGE_NAME);
-            String requestType = intent.getStringExtra(RestrictionsManager.EXTRA_REQUEST_TYPE);
-            String requestId = intent.getStringExtra(RestrictionsManager.EXTRA_REQUEST_ID);
-            PersistableBundle request = (PersistableBundle)
-                    intent.getParcelableExtra(RestrictionsManager.EXTRA_REQUEST_BUNDLE);
-            requestPermission(context, packageName, requestType, requestId, request);
-        }
-    }
-}
diff --git a/core/java/android/content/ContentProvider.java b/core/java/android/content/ContentProvider.java
index fde8b2e..2853c58 100644
--- a/core/java/android/content/ContentProvider.java
+++ b/core/java/android/content/ContentProvider.java
@@ -639,12 +639,14 @@
      * @param authorities the semi-colon separated authorities of the ContentProvider.
      */
     protected final void setAuthorities(String authorities) {
-        if (authorities.indexOf(';') == -1) {
-            mAuthority = authorities;
-            mAuthorities = null;
-        } else {
-            mAuthority = null;
-            mAuthorities = authorities.split(";");
+        if (authorities != null) {
+            if (authorities.indexOf(';') == -1) {
+                mAuthority = authorities;
+                mAuthorities = null;
+            } else {
+                mAuthority = null;
+                mAuthorities = authorities.split(";");
+            }
         }
     }
 
@@ -653,9 +655,11 @@
         if (mAuthority != null) {
             return mAuthority.equals(authority);
         }
-        int length = mAuthorities.length;
-        for (int i = 0; i < length; i++) {
-            if (mAuthorities[i].equals(authority)) return true;
+        if (mAuthorities != null) {
+            int length = mAuthorities.length;
+            for (int i = 0; i < length; i++) {
+                if (mAuthorities[i].equals(authority)) return true;
+            }
         }
         return false;
     }
diff --git a/core/java/android/content/ContentResolver.java b/core/java/android/content/ContentResolver.java
index 0ca800f..a09fee9 100644
--- a/core/java/android/content/ContentResolver.java
+++ b/core/java/android/content/ContentResolver.java
@@ -27,6 +27,7 @@
 import android.database.CrossProcessCursorWrapper;
 import android.database.Cursor;
 import android.database.IContentObserver;
+import android.graphics.Point;
 import android.net.Uri;
 import android.os.Bundle;
 import android.os.CancellationSignal;
@@ -161,6 +162,17 @@
     public static final String SCHEME_FILE = "file";
 
     /**
+     * An extra {@link Point} describing the optimal size for a requested image
+     * resource, in pixels. If a provider has multiple sizes of the image, it
+     * should return the image closest to this size.
+     *
+     * @see #openTypedAssetFileDescriptor(Uri, String, Bundle)
+     * @see #openTypedAssetFileDescriptor(Uri, String, Bundle,
+     *      CancellationSignal)
+     */
+    public static final String EXTRA_SIZE = "android.content.extra.SIZE";
+
+    /**
      * This is the Android platform's base MIME type for a content: URI
      * containing a Cursor of a single item.  Applications should use this
      * as the base type along with their own sub-type of their content: URIs
@@ -1612,7 +1624,7 @@
      * @see #requestSync(android.accounts.Account, String, android.os.Bundle)
      */
     public void notifyChange(Uri uri, ContentObserver observer, boolean syncToNetwork) {
-        notifyChange(uri, observer, syncToNetwork, UserHandle.getCallingUserId());
+        notifyChange(uri, observer, syncToNetwork, UserHandle.myUserId());
     }
 
     /**
@@ -1751,7 +1763,7 @@
      * @param extras any extras to pass to the SyncAdapter.
      */
     public static void requestSync(Account account, String authority, Bundle extras) {
-        requestSyncAsUser(account, authority, UserHandle.getCallingUserId(), extras);
+        requestSyncAsUser(account, authority, UserHandle.myUserId(), extras);
     }
 
     /**
@@ -1926,7 +1938,7 @@
      * @param sync true if the provider should be synced when tickles are received for it
      */
     public static void setSyncAutomatically(Account account, String authority, boolean sync) {
-        setSyncAutomaticallyAsUser(account, authority, sync, UserHandle.getCallingUserId());
+        setSyncAutomaticallyAsUser(account, authority, sync, UserHandle.myUserId());
     }
 
     /**
@@ -2153,7 +2165,7 @@
      * @param sync the master auto-sync setting that applies to all the providers and accounts
      */
     public static void setMasterSyncAutomatically(boolean sync) {
-        setMasterSyncAutomaticallyAsUser(sync, UserHandle.getCallingUserId());
+        setMasterSyncAutomaticallyAsUser(sync, UserHandle.myUserId());
     }
 
     /**
@@ -2285,7 +2297,7 @@
      * @return true if there is a pending sync with the matching account and authority
      */
     public static boolean isSyncPending(Account account, String authority) {
-        return isSyncPendingAsUser(account, authority, UserHandle.getCallingUserId());
+        return isSyncPendingAsUser(account, authority, UserHandle.myUserId());
     }
 
     /**
diff --git a/core/java/android/content/Context.java b/core/java/android/content/Context.java
index a13a928..158a40c 100644
--- a/core/java/android/content/Context.java
+++ b/core/java/android/content/Context.java
@@ -1486,8 +1486,6 @@
      * @see #sendBroadcast(Intent)
      * @see #sendBroadcast(Intent, String)
      * @see #sendOrderedBroadcast(Intent, String)
-     * @see #sendStickyBroadcast(Intent)
-     * @see #sendStickyOrderedBroadcast(Intent, BroadcastReceiver, Handler, int, String, Bundle)
      * @see android.content.BroadcastReceiver
      * @see #registerReceiver
      * @see android.app.Activity#RESULT_OK
@@ -1584,7 +1582,7 @@
             @Nullable  Bundle initialExtras);
 
     /**
-     * Perform a {@link #sendBroadcast(Intent)} that is "sticky," meaning the
+     * <p>Perform a {@link #sendBroadcast(Intent)} that is "sticky," meaning the
      * Intent you are sending stays around after the broadcast is complete,
      * so that others can quickly retrieve that data through the return
      * value of {@link #registerReceiver(BroadcastReceiver, IntentFilter)}.  In
@@ -1595,6 +1593,12 @@
      * permission in order to use this API.  If you do not hold that
      * permission, {@link SecurityException} will be thrown.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent to broadcast; all receivers matching this
      * Intent will receive the broadcast, and the Intent will be held to
      * be re-broadcast to future receivers.
@@ -1602,10 +1606,11 @@
      * @see #sendBroadcast(Intent)
      * @see #sendStickyOrderedBroadcast(Intent, BroadcastReceiver, Handler, int, String, Bundle)
      */
+    @Deprecated
     public abstract void sendStickyBroadcast(Intent intent);
 
     /**
-     * Version of {@link #sendStickyBroadcast} that allows you to
+     * <p>Version of {@link #sendStickyBroadcast} that allows you to
      * receive data back from the broadcast.  This is accomplished by
      * supplying your own BroadcastReceiver when calling, which will be
      * treated as a final receiver at the end of the broadcast -- its
@@ -1622,6 +1627,12 @@
      *
      * <p>See {@link BroadcastReceiver} for more information on Intent broadcasts.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent to broadcast; all receivers matching this
      *               Intent will receive the broadcast.
      * @param resultReceiver Your own BroadcastReceiver to treat as the final
@@ -1644,31 +1655,45 @@
      * @see #registerReceiver
      * @see android.app.Activity#RESULT_OK
      */
+    @Deprecated
     public abstract void sendStickyOrderedBroadcast(Intent intent,
             BroadcastReceiver resultReceiver,
             @Nullable Handler scheduler, int initialCode, @Nullable String initialData,
             @Nullable Bundle initialExtras);
 
     /**
-     * Remove the data previously sent with {@link #sendStickyBroadcast},
+     * <p>Remove the data previously sent with {@link #sendStickyBroadcast},
      * so that it is as if the sticky broadcast had never happened.
      *
      * <p>You must hold the {@link android.Manifest.permission#BROADCAST_STICKY}
      * permission in order to use this API.  If you do not hold that
      * permission, {@link SecurityException} will be thrown.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent that was previously broadcast.
      *
      * @see #sendStickyBroadcast
      */
+    @Deprecated
     public abstract void removeStickyBroadcast(Intent intent);
 
     /**
-     * Version of {@link #sendStickyBroadcast(Intent)} that allows you to specify the
+     * <p>Version of {@link #sendStickyBroadcast(Intent)} that allows you to specify the
      * user the broadcast will be sent to.  This is not available to applications
      * that are not pre-installed on the system image.  Using it requires holding
      * the INTERACT_ACROSS_USERS permission.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent to broadcast; all receivers matching this
      * Intent will receive the broadcast, and the Intent will be held to
      * be re-broadcast to future receivers.
@@ -1676,10 +1701,11 @@
      *
      * @see #sendBroadcast(Intent)
      */
+    @Deprecated
     public abstract void sendStickyBroadcastAsUser(Intent intent, UserHandle user);
 
     /**
-     * Version of
+     * <p>Version of
      * {@link #sendStickyOrderedBroadcast(Intent, BroadcastReceiver, Handler, int, String, Bundle)}
      * that allows you to specify the
      * user the broadcast will be sent to.  This is not available to applications
@@ -1688,6 +1714,12 @@
      *
      * <p>See {@link BroadcastReceiver} for more information on Intent broadcasts.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent to broadcast; all receivers matching this
      *               Intent will receive the broadcast.
      * @param user UserHandle to send the intent to.
@@ -1705,13 +1737,14 @@
      *
      * @see #sendStickyOrderedBroadcast(Intent, BroadcastReceiver, Handler, int, String, Bundle)
      */
+    @Deprecated
     public abstract void sendStickyOrderedBroadcastAsUser(Intent intent,
             UserHandle user, BroadcastReceiver resultReceiver,
             @Nullable Handler scheduler, int initialCode, @Nullable String initialData,
             @Nullable Bundle initialExtras);
 
     /**
-     * Version of {@link #removeStickyBroadcast(Intent)} that allows you to specify the
+     * <p>Version of {@link #removeStickyBroadcast(Intent)} that allows you to specify the
      * user the broadcast will be sent to.  This is not available to applications
      * that are not pre-installed on the system image.  Using it requires holding
      * the INTERACT_ACROSS_USERS permission.
@@ -1720,11 +1753,18 @@
      * permission in order to use this API.  If you do not hold that
      * permission, {@link SecurityException} will be thrown.
      *
+     * @deprecated Sticky broadcasts should not be used.  They provide no security (anyone
+     * can access them), no protection (anyone can modify them), and many other problems.
+     * The recommended pattern is to use a non-sticky broadcast to report that <em>something</em>
+     * has changed, with another mechanism for apps to retrieve the current value whenever
+     * desired.
+     *
      * @param intent The Intent that was previously broadcast.
      * @param user UserHandle to remove the sticky broadcast from.
      *
      * @see #sendStickyBroadcastAsUser
      */
+    @Deprecated
     public abstract void removeStickyBroadcastAsUser(Intent intent, UserHandle user);
 
     /**
@@ -1997,6 +2037,7 @@
      * argument for use by system server and other multi-user aware code.
      * @hide
      */
+    @SystemApi
     public boolean bindServiceAsUser(Intent service, ServiceConnection conn, int flags, UserHandle user) {
         throw new RuntimeException("Not implemented. Must override in a subclass.");
     }
@@ -2074,7 +2115,7 @@
             AUDIO_SERVICE,
             MEDIA_ROUTER_SERVICE,
             TELEPHONY_SERVICE,
-            TELECOMM_SERVICE,
+            TELECOM_SERVICE,
             CLIPBOARD_SERVICE,
             INPUT_METHOD_SERVICE,
             TEXT_SERVICES_MANAGER_SERVICE,
@@ -2203,8 +2244,6 @@
      * @see android.media.MediaRouter
      * @see #TELEPHONY_SERVICE
      * @see android.telephony.TelephonyManager
-     * @see #PHONE_SERVICE
-     * @see android.phone.PhoneManager
      * @see #INPUT_METHOD_SERVICE
      * @see android.view.inputmethod.InputMethodManager
      * @see #UI_MODE_SERVICE
@@ -2514,6 +2553,7 @@
      *
      * @see #getSystemService
      * @see android.app.FingerprintManager
+     * @hide
      */
     public static final String FINGERPRINT_SERVICE = "fingerprint";
 
@@ -2548,23 +2588,13 @@
 
     /**
      * Use with {@link #getSystemService} to retrieve a
-     * {@link android.telecomm.TelecommManager} to manage telecomm-related features
+     * {@link android.telecom.TelecomManager} to manage telecom-related features
      * of the device.
      *
      * @see #getSystemService
-     * @see android.telecomm.TelecommManager
+     * @see android.telecom.TelecomManager
      */
-    public static final String TELECOMM_SERVICE = "telecomm";
-
-    /**
-     * Use with {@link #getSystemService} to retrieve a
-     * {@link android.phone.PhoneManager} to manage phone-related features
-     * of the device.
-     *
-     * @see #getSystemService
-     * @see android.phone.PhoneManager
-     */
-    public static final String PHONE_SERVICE = "phone_service";  // "phone" used by telephony.
+    public static final String TELECOM_SERVICE = "telecom";
 
     /**
      * Use with {@link #getSystemService} to retrieve a
@@ -3033,6 +3063,14 @@
      * "content://foo".  It will not remove any prefix grants that exist at a
      * higher level.
      *
+     * <p>Prior to {@link android.os.Build.VERSION_CODES#L}, if you did not have
+     * regular permission access to a Uri, but had received access to it through
+     * a specific Uri permission grant, you could not revoke that grant with this
+     * function and a {@link SecurityException} would be thrown.  As of
+     * {@link android.os.Build.VERSION_CODES#L}, this function will not throw a security exception,
+     * but will remove whatever permission grants to the Uri had been given to the app
+     * (or none).</p>
+     *
      * @param uri The Uri you would like to revoke access to.
      * @param modeFlags The desired access modes.  Any combination of
      * {@link Intent#FLAG_GRANT_READ_URI_PERMISSION
diff --git a/core/java/android/content/IRestrictionsManager.aidl b/core/java/android/content/IRestrictionsManager.aidl
index 495ac2e..db9146f 100644
--- a/core/java/android/content/IRestrictionsManager.aidl
+++ b/core/java/android/content/IRestrictionsManager.aidl
@@ -30,5 +30,5 @@
     void requestPermission(in String packageName, in String requestType, in String requestId,
             in PersistableBundle requestData);
     void notifyPermissionResponse(in String packageName, in PersistableBundle response);
-    Intent getLocalApprovalIntent();
+    Intent createLocalApprovalIntent();
 }
diff --git a/core/java/android/content/Intent.java b/core/java/android/content/Intent.java
index 61e105b..ff9f6ab 100644
--- a/core/java/android/content/Intent.java
+++ b/core/java/android/content/Intent.java
@@ -1213,6 +1213,13 @@
             = "android.intent.extra.ASSIST_CONTEXT";
 
     /**
+     * An optional field on {@link #ACTION_ASSIST} suggesting that the user will likely use a
+     * keyboard as the primary input device for assistance.
+     */
+    public static final String EXTRA_ASSIST_INPUT_HINT_KEYBOARD =
+            "android.intent.extra.ASSIST_INPUT_HINT_KEYBOARD";
+
+    /**
      * Activity Action: List all available applications
      * <p>Input: Nothing.
      * <p>Output: nothing.
@@ -2216,104 +2223,14 @@
     /**
      * Broadcast Action: Wired Headset plugged in or unplugged.
      *
-     * You <em>cannot</em> receive this through components declared
-     * in manifests, only by explicitly registering for it with
-     * {@link Context#registerReceiver(BroadcastReceiver, IntentFilter)
-     * Context.registerReceiver()}.
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>name</em> - Headset type, human readable string </li>
-     *   <li><em>microphone</em> - 1 if headset has a microphone, 0 otherwise </li>
-     * </ul>
-     * </ul>
+     * Same as {@link android.media.AudioManager#ACTION_HEADSET_PLUG}, to be consulted for value
+     *   and documentation.
+     * <p>If the minimum SDK version of your application is
+     * {@link android.os.Build.VERSION_CODES#L}, it is recommended to refer
+     * to the <code>AudioManager</code> constant in your receiver registration code instead.
      */
     @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_HEADSET_PLUG =
-            "android.intent.action.HEADSET_PLUG";
-
-    /**
-     * Broadcast Action: An analog audio speaker/headset plugged in or unplugged.
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>name</em> - Headset type, human readable string </li>
-     * </ul>
-     * </ul>
-     * @hide
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_ANALOG_AUDIO_DOCK_PLUG =
-            "android.intent.action.ANALOG_AUDIO_DOCK_PLUG";
-
-    /**
-     * Broadcast Action: A digital audio speaker/headset plugged in or unplugged.
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>name</em> - Headset type, human readable string </li>
-     * </ul>
-     * </ul>
-     * @hide
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_DIGITAL_AUDIO_DOCK_PLUG =
-            "android.intent.action.DIGITAL_AUDIO_DOCK_PLUG";
-
-    /**
-     * Broadcast Action: A sticky broadcast indicating an HMDI cable was plugged or unplugged
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>name</em> - HDMI cable, human readable string </li>
-     *   <li><em>maxChannelCount</em> - the maximum number of output channels supported by the
-     *       connected HDMI device, only available when <i>state</i> is 1.</li>
-     *   <li><em>encodings</em> - an array of formats supported by the connected HDMI device,
-     *       only available when <i>state</i> is 1. Encoding values are defined in
-     *       {@link android.media.AudioFormat} (for instance see
-     *       {@link android.media.AudioFormat#ENCODING_PCM_16BIT}). Use
-     *       {@link #getIntArrayExtra(String)} to retrieve the encoding values.</li>
-     * </ul>
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_HDMI_AUDIO_PLUG =
-            "android.intent.action.HDMI_AUDIO_PLUG";
-
-    /**
-     * Broadcast Action: A USB audio accessory was plugged in or unplugged.
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>card</em> - ALSA card number (integer) </li>
-     *   <li><em>device</em> - ALSA device number (integer) </li>
-     * </ul>
-     * </ul>
-     * @hide
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_USB_AUDIO_ACCESSORY_PLUG =
-            "android.intent.action.USB_AUDIO_ACCESSORY_PLUG";
-
-    /**
-     * Broadcast Action: A USB audio device was plugged in or unplugged.
-     *
-     * <p>The intent will have the following extra values:
-     * <ul>
-     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
-     *   <li><em>card</em> - ALSA card number (integer) </li>
-     *   <li><em>device</em> - ALSA device number (integer) </li>
-     * </ul>
-     * </ul>
-     * @hide
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_USB_AUDIO_DEVICE_PLUG =
-            "android.intent.action.USB_AUDIO_DEVICE_PLUG";
+    public static final String ACTION_HEADSET_PLUG = android.media.AudioManager.ACTION_HEADSET_PLUG;
 
     /**
      * <p>Broadcast Action: The user has switched on advanced settings in the settings app:</p>
@@ -2833,12 +2750,14 @@
     @SdkConstant(SdkConstantType.INTENT_CATEGORY)
     public static final String CATEGORY_BROWSABLE = "android.intent.category.BROWSABLE";
     /**
+     * @hide
      * Categories for activities that can participate in voice interaction.
      * An activity that supports this category must be prepared to run with
      * no UI shown at all (though in some case it may have a UI shown), and
      * rely on {@link android.app.VoiceInteractor} to interact with the user.
      */
     @SdkConstant(SdkConstantType.INTENT_CATEGORY)
+    @SystemApi
     public static final String CATEGORY_VOICE = "android.intent.category.VOICE";
     /**
      * Set if the activity should be considered as an alternative action to
@@ -3451,7 +3370,7 @@
      * profiles - {@link #ACTION_MANAGED_PROFILE_ADDED} and {@link #ACTION_MANAGED_PROFILE_REMOVED}.
      */
     public static final String EXTRA_USER =
-            "android.intent.extra.user";
+            "android.intent.extra.USER";
 
     /**
      * Extra used in the response from a BroadcastReceiver that handles
diff --git a/core/java/android/content/RestrictionsManager.java b/core/java/android/content/RestrictionsManager.java
index c1226c0..21a6a0d 100644
--- a/core/java/android/content/RestrictionsManager.java
+++ b/core/java/android/content/RestrictionsManager.java
@@ -26,6 +26,7 @@
 import android.os.Bundle;
 import android.os.PersistableBundle;
 import android.os.RemoteException;
+import android.service.restrictions.RestrictionsReceiver;
 import android.util.AttributeSet;
 import android.util.Log;
 import android.util.Xml;
@@ -107,7 +108,7 @@
  * </pre>
  *
  * @see RestrictionEntry
- * @see AbstractRestrictionsProvider
+ * @see RestrictionsReceiver
  * @see DevicePolicyManager#setRestrictionsProvider(ComponentName, ComponentName)
  * @see DevicePolicyManager#setApplicationRestrictions(ComponentName, String, Bundle)
  */
@@ -154,7 +155,7 @@
      * The intent must contain {@link #EXTRA_REQUEST_BUNDLE} as an extra and the bundle must
      * contain at least {@link #REQUEST_KEY_MESSAGE} for the activity to display.
      * <p>
-     * @see #getLocalApprovalIntent()
+     * @see #createLocalApprovalIntent()
      */
     public static final String ACTION_REQUEST_LOCAL_APPROVAL =
             "android.content.action.REQUEST_LOCAL_APPROVAL";
@@ -472,10 +473,10 @@
         }
     }
 
-    public Intent getLocalApprovalIntent() {
+    public Intent createLocalApprovalIntent() {
         try {
             if (mService != null) {
-                return mService.getLocalApprovalIntent();
+                return mService.createLocalApprovalIntent();
             }
         } catch (RemoteException re) {
             Log.w(TAG, "Couldn't reach service");
diff --git a/core/java/android/content/pm/ActivityInfo.java b/core/java/android/content/pm/ActivityInfo.java
index dbf49c5..641f843e 100644
--- a/core/java/android/content/pm/ActivityInfo.java
+++ b/core/java/android/content/pm/ActivityInfo.java
@@ -255,16 +255,22 @@
      * Bit in {@link #flags}: If set, a task rooted at this activity will have its
      * baseIntent replaced by the activity immediately above this. Each activity may further
      * relinquish its identity to the activity above it using this flag. Set from the
-     * android.R.attr#relinquishTaskIdentity attribute.
+     * {@link android.R.attr#relinquishTaskIdentity} attribute.
      */
     public static final int FLAG_RELINQUISH_TASK_IDENTITY = 0x1000;
     /**
      * Bit in {@link #flags} indicating that tasks started with this activity are to be
      * removed from the recent list of tasks when the last activity in the task is finished.
-     * {@link android.R.attr#autoRemoveFromRecents}
+     * Corresponds to {@link android.R.attr#autoRemoveFromRecents}
      */
     public static final int FLAG_AUTO_REMOVE_FROM_RECENTS = 0x2000;
     /**
+     * Bit in {@link #flags} indicating that this activity can start is creation/resume
+     * while the previous activity is still pausing.  Corresponds to
+     * {@link android.R.attr#resumeWhilePausing}
+     */
+    public static final int FLAG_RESUME_WHILE_PAUSING = 0x4000;
+    /**
      * @hide Bit in {@link #flags}: If set, this component will only be seen
      * by the primary user.  Only works with broadcast receivers.  Set from the
      * android.R.attr#primaryUserOnly attribute.
@@ -651,6 +657,7 @@
         softInputMode = orig.softInputMode;
         uiOptions = orig.uiOptions;
         parentActivityName = orig.parentActivityName;
+        maxRecents = orig.maxRecents;
     }
     
     /**
@@ -722,6 +729,7 @@
         dest.writeInt(uiOptions);
         dest.writeString(parentActivityName);
         dest.writeInt(persistableMode);
+        dest.writeInt(maxRecents);
     }
 
     public static final Parcelable.Creator<ActivityInfo> CREATOR
@@ -748,5 +756,6 @@
         uiOptions = source.readInt();
         parentActivityName = source.readString();
         persistableMode = source.readInt();
+        maxRecents = source.readInt();
     }
 }
diff --git a/core/java/android/content/pm/IPackageInstaller.aidl b/core/java/android/content/pm/IPackageInstaller.aidl
index 97be8f0..6daefc8 100644
--- a/core/java/android/content/pm/IPackageInstaller.aidl
+++ b/core/java/android/content/pm/IPackageInstaller.aidl
@@ -22,12 +22,21 @@
 import android.content.pm.PackageInstaller;
 import android.content.IntentSender;
 
+import android.graphics.Bitmap;
+
 /** {@hide} */
 interface IPackageInstaller {
     int createSession(in PackageInstaller.SessionParams params, String installerPackageName, int userId);
+
+    void updateSessionAppIcon(int sessionId, in Bitmap appIcon);
+    void updateSessionAppLabel(int sessionId, String appLabel);
+
+    void abandonSession(int sessionId);
+
     IPackageInstallerSession openSession(int sessionId);
 
     PackageInstaller.SessionInfo getSessionInfo(int sessionId);
+
     List<PackageInstaller.SessionInfo> getAllSessions(int userId);
     List<PackageInstaller.SessionInfo> getMySessions(String installerPackageName, int userId);
 
diff --git a/core/java/android/content/pm/IPackageInstallerCallback.aidl b/core/java/android/content/pm/IPackageInstallerCallback.aidl
index 39ae1a0..974eb1e 100644
--- a/core/java/android/content/pm/IPackageInstallerCallback.aidl
+++ b/core/java/android/content/pm/IPackageInstallerCallback.aidl
@@ -19,8 +19,8 @@
 /** {@hide} */
 oneway interface IPackageInstallerCallback {
     void onSessionCreated(int sessionId);
-    void onSessionOpened(int sessionId);
+    void onSessionBadgingChanged(int sessionId);
+    void onSessionActiveChanged(int sessionId, boolean active);
     void onSessionProgressChanged(int sessionId, float progress);
-    void onSessionClosed(int sessionId);
     void onSessionFinished(int sessionId, boolean success);
 }
diff --git a/core/java/android/content/pm/IPackageManager.aidl b/core/java/android/content/pm/IPackageManager.aidl
index 44478d4..6d9c58b 100644
--- a/core/java/android/content/pm/IPackageManager.aidl
+++ b/core/java/android/content/pm/IPackageManager.aidl
@@ -32,6 +32,7 @@
 import android.content.pm.IPackageMoveObserver;
 import android.content.pm.IPackageStatsObserver;
 import android.content.pm.InstrumentationInfo;
+import android.content.pm.KeySet;
 import android.content.pm.PackageInfo;
 import android.content.pm.ManifestDigest;
 import android.content.pm.PackageCleanItem;
@@ -198,6 +199,14 @@
             in VerificationParams verificationParams,
             in String packageAbiOverride);
 
+    void installPackageAsUser(in String originPath,
+            in IPackageInstallObserver2 observer,
+            int flags,
+            in String installerPackageName,
+            in VerificationParams verificationParams,
+            in String packageAbiOverride,
+            int userId);
+
     void finishPackageInstall(int token);
 
     void setInstallerPackageName(in String targetPackage, in String installerPackageName);
@@ -250,12 +259,6 @@
     void addCrossProfileIntentFilter(in IntentFilter intentFilter, String ownerPackage,
             int ownerUserId, int sourceUserId, int targetUserId, int flags);
 
-    void addCrossProfileIntentsForPackage(in String packageName, int sourceUserId,
-            int targetUserId);
-
-    void removeCrossProfileIntentsForPackage(String packageName, int sourceUserId,
-            int targetUserId);
-
     void clearCrossProfileIntentFilters(int sourceUserId, String ownerPackage, int ownerUserId);
 
     /**
@@ -446,8 +449,8 @@
     boolean setBlockUninstallForUser(String packageName, boolean blockUninstall, int userId);
     boolean getBlockUninstallForUser(String packageName, int userId);
 
-    IBinder getKeySetByAlias(String packageName, String alias);
-    IBinder getSigningKeySet(String packageName);
-    boolean isPackageSignedByKeySet(String packageName, IBinder ks);
-    boolean isPackageSignedByKeySetExactly(String packageName, IBinder ks);
+    KeySet getKeySetByAlias(String packageName, String alias);
+    KeySet getSigningKeySet(String packageName);
+    boolean isPackageSignedByKeySet(String packageName, in KeySet ks);
+    boolean isPackageSignedByKeySetExactly(String packageName, in KeySet ks);
 }
diff --git a/core/java/android/content/pm/KeySet.aidl b/core/java/android/content/pm/KeySet.aidl
new file mode 100644
index 0000000..493d288
--- /dev/null
+++ b/core/java/android/content/pm/KeySet.aidl
@@ -0,0 +1,19 @@
+/**
+ * Copyright (c) 2014, 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 android.content.pm;
+
+parcelable KeySet;
\ No newline at end of file
diff --git a/core/java/android/content/pm/KeySet.java b/core/java/android/content/pm/KeySet.java
index fcdaa18..643db7e 100644
--- a/core/java/android/content/pm/KeySet.java
+++ b/core/java/android/content/pm/KeySet.java
@@ -17,13 +17,16 @@
 package android.content.pm;
 
 import android.os.IBinder;
+import android.os.Parcel;
+import android.os.Parcelable;
 
 /**
  * Represents a {@code KeySet} that has been declared in the AndroidManifest.xml
  * file for the application.  A {@code KeySet} can be used explicitly to
  * represent a trust relationship with other applications on the device.
+ * @hide
  */
-public class KeySet {
+public class KeySet implements Parcelable {
 
     private IBinder token;
 
@@ -40,6 +43,7 @@
         return token;
     }
 
+    /** @hide */
     @Override
     public boolean equals(Object o) {
         if (o instanceof KeySet) {
@@ -48,4 +52,58 @@
         }
         return false;
     }
+
+    /** @hide */
+    @Override
+    public int hashCode() {
+        return token.hashCode();
+    }
+
+    /**
+     * Implement Parcelable
+     * @hide
+     */
+    public static final Parcelable.Creator<KeySet> CREATOR
+            = new Parcelable.Creator<KeySet>() {
+
+        /**
+         * Create a KeySet from a Parcel
+         *
+         * @param in The parcel containing the KeySet
+         */
+        public KeySet createFromParcel(Parcel source) {
+            return readFromParcel(source);
+        }
+
+        /**
+         * Create an array of null KeySets
+         */
+        public KeySet[] newArray(int size) {
+            return new KeySet[size];
+        }
+    };
+
+    /**
+     * @hide
+     */
+    private static KeySet readFromParcel(Parcel in) {
+        IBinder token = in.readStrongBinder();
+        return new KeySet(token);
+    }
+
+    /**
+     * @hide
+     */
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeStrongBinder(token);
+    }
+
+    /**
+     * @hide
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
 }
\ No newline at end of file
diff --git a/core/java/android/content/pm/LauncherActivityInfo.java b/core/java/android/content/pm/LauncherActivityInfo.java
index 0cff08b..ee23fcd 100644
--- a/core/java/android/content/pm/LauncherActivityInfo.java
+++ b/core/java/android/content/pm/LauncherActivityInfo.java
@@ -18,16 +18,10 @@
 
 import android.content.ComponentName;
 import android.content.Context;
-import android.content.Intent;
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.res.Resources;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Bitmap.Config;
 import android.graphics.drawable.BitmapDrawable;
 import android.graphics.drawable.Drawable;
-import android.os.Bundle;
-import android.os.RemoteException;
 import android.os.UserHandle;
 import android.os.UserManager;
 import android.util.DisplayMetrics;
@@ -39,11 +33,9 @@
  * and badged icon for the activity.
  */
 public class LauncherActivityInfo {
-    private static final boolean DEBUG = false;
     private static final String TAG = "LauncherActivityInfo";
 
     private final PackageManager mPm;
-    private final UserManager mUm;
 
     private ActivityInfo mActivityInfo;
     private ComponentName mComponentName;
@@ -68,7 +60,6 @@
 
     LauncherActivityInfo(Context context) {
         mPm = context.getPackageManager();
-        mUm = UserManager.get(context);
     }
 
     /**
@@ -179,7 +170,7 @@
         }
 
         if (originalIcon instanceof BitmapDrawable) {
-            return mUm.getBadgedIconForUser(originalIcon, mUser);
+            return mPm.getUserBadgedIcon(originalIcon, mUser);
         } else {
             Log.e(TAG, "Unable to create badged icon for " + mActivityInfo);
         }
diff --git a/core/java/android/content/pm/LauncherApps.java b/core/java/android/content/pm/LauncherApps.java
index 268919c..5ee0b67 100644
--- a/core/java/android/content/pm/LauncherApps.java
+++ b/core/java/android/content/pm/LauncherApps.java
@@ -64,7 +64,7 @@
     /**
      * Callbacks for package changes to this and related managed profiles.
      */
-    public static abstract class OnAppsChangedCallback {
+    public static abstract class Callback {
         /**
          * Indicates that a package was removed from the specified profile.
          *
@@ -207,17 +207,17 @@
     }
 
     /**
-     * Starts an activity in the specified profile.
+     * Starts a Main activity in the specified profile.
      *
      * @param component The ComponentName of the activity to launch
      * @param user The UserHandle of the profile
      * @param sourceBounds The Rect containing the source bounds of the clicked icon
      * @param opts Options to pass to startActivity
      */
-    public void startActivityForProfile(ComponentName component, UserHandle user, Rect sourceBounds,
+    public void startMainActivity(ComponentName component, UserHandle user, Rect sourceBounds,
             Bundle opts) {
         if (DEBUG) {
-            Log.i(TAG, "StartActivityForProfile " + component + " " + user.getIdentifier());
+            Log.i(TAG, "StartMainActivity " + component + " " + user.getIdentifier());
         }
         try {
             mService.startActivityAsUser(component, sourceBounds, opts, user);
@@ -235,7 +235,7 @@
      * @param sourceBounds The Rect containing the source bounds of the clicked icon
      * @param opts Options to pass to startActivity
      */
-    public void showAppDetailsForProfile(ComponentName component, UserHandle user,
+    public void startAppDetailsActivity(ComponentName component, UserHandle user,
             Rect sourceBounds, Bundle opts) {
         try {
             mService.showAppDetailsAsUser(component, sourceBounds, opts, user);
@@ -252,7 +252,7 @@
      *
      * @return true if the package exists and is enabled.
      */
-    public boolean isPackageEnabledForProfile(String packageName, UserHandle user) {
+    public boolean isPackageEnabled(String packageName, UserHandle user) {
         try {
             return mService.isPackageEnabled(packageName, user);
         } catch (RemoteException re) {
@@ -268,7 +268,7 @@
      *
      * @return true if the activity exists and is enabled.
      */
-    public boolean isActivityEnabledForProfile(ComponentName component, UserHandle user) {
+    public boolean isActivityEnabled(ComponentName component, UserHandle user) {
         try {
             return mService.isActivityEnabled(component, user);
         } catch (RemoteException re) {
@@ -278,21 +278,21 @@
 
 
     /**
-     * Adds a callback for changes to packages in current and managed profiles.
+     * Registers a callback for changes to packages in current and managed profiles.
      *
-     * @param callback The callback to add.
+     * @param callback The callback to register.
      */
-    public void addOnAppsChangedCallback(OnAppsChangedCallback callback) {
-        addOnAppsChangedCallback(callback, null);
+    public void registerCallback(Callback callback) {
+        registerCallback(callback, null);
     }
 
     /**
-     * Adds a callback for changes to packages in current and managed profiles.
+     * Registers a callback for changes to packages in current and managed profiles.
      *
-     * @param callback The callback to add.
+     * @param callback The callback to register.
      * @param handler that should be used to post callbacks on, may be null.
      */
-    public void addOnAppsChangedCallback(OnAppsChangedCallback callback, Handler handler) {
+    public void registerCallback(Callback callback, Handler handler) {
         synchronized (this) {
             if (callback != null && !mCallbacks.contains(callback)) {
                 boolean addedFirstCallback = mCallbacks.size() == 0;
@@ -308,12 +308,12 @@
     }
 
     /**
-     * Removes a callback that was previously added.
+     * Unregisters a callback that was previously registered.
      *
-     * @param callback The callback to remove.
-     * @see #addOnAppsChangedListener(OnAppsChangedCallback)
+     * @param callback The callback to unregister.
+     * @see #registerCallback(Callback)
      */
-    public void removeOnAppsChangedCallback(OnAppsChangedCallback callback) {
+    public void unregisterCallback(Callback callback) {
         synchronized (this) {
             removeCallbackLocked(callback);
             if (mCallbacks.size() == 0) {
@@ -325,7 +325,7 @@
         }
     }
 
-    private void removeCallbackLocked(OnAppsChangedCallback callback) {
+    private void removeCallbackLocked(Callback callback) {
         if (callback == null) {
             throw new IllegalArgumentException("Callback cannot be null");
         }
@@ -338,7 +338,7 @@
         }
     }
 
-    private void addCallbackLocked(OnAppsChangedCallback callback, Handler handler) {
+    private void addCallbackLocked(Callback callback, Handler handler) {
         // Remove if already present.
         removeCallbackLocked(callback);
         if (handler == null) {
@@ -421,7 +421,7 @@
         private static final int MSG_AVAILABLE = 4;
         private static final int MSG_UNAVAILABLE = 5;
 
-        private OnAppsChangedCallback mCallback;
+        private LauncherApps.Callback mCallback;
 
         private static class CallbackInfo {
             String[] packageNames;
@@ -430,7 +430,7 @@
             UserHandle user;
         }
 
-        public CallbackMessageHandler(Looper looper, OnAppsChangedCallback callback) {
+        public CallbackMessageHandler(Looper looper, LauncherApps.Callback callback) {
             super(looper, null, true);
             mCallback = callback;
         }
@@ -499,4 +499,20 @@
             obtainMessage(MSG_UNAVAILABLE, info).sendToTarget();
         }
     }
+
+    /**
+     * TODO Remove after 2014-09-22
+     * @hide
+     */
+    public void addCallback(Callback callback) {
+        registerCallback(callback);
+    }
+
+    /**
+     * TODO Remove after 2014-09-22
+     * @hide
+     */
+    public void removeCallback(Callback callback) {
+        unregisterCallback(callback);
+    }
 }
diff --git a/core/java/android/content/pm/PackageInfo.java b/core/java/android/content/pm/PackageInfo.java
index a0e3c4a..765b2a9 100644
--- a/core/java/android/content/pm/PackageInfo.java
+++ b/core/java/android/content/pm/PackageInfo.java
@@ -227,19 +227,6 @@
     public static final int INSTALL_LOCATION_PREFER_EXTERNAL = 2;
 
     /**
-     * Flag for {@link #requiredForProfile}
-     * The application will always be installed for a restricted profile.
-     * @hide
-     */
-    public static final int RESTRICTED_PROFILE = 1;
-    /**
-     * Flag for {@link #requiredForProfile}
-     * The application will always be installed for a managed profile.
-     * @hide
-     */
-    public static final int MANAGED_PROFILE = 2;
-
-    /**
      * The install location requested by the package. From the
      * {@link android.R.attr#installLocation} attribute, one of
      * {@link #INSTALL_LOCATION_AUTO}, {@link #INSTALL_LOCATION_INTERNAL_ONLY},
@@ -247,12 +234,6 @@
      */
     public int installLocation = INSTALL_LOCATION_INTERNAL_ONLY;
 
-    /**
-     * Defines which profiles this app is required for.
-     * @hide
-     */
-    public int requiredForProfile;
-
     /** @hide */
     public boolean requiredForAllUsers;
 
@@ -313,7 +294,6 @@
         dest.writeTypedArray(featureGroups, parcelableFlags);
         dest.writeInt(installLocation);
         dest.writeInt(requiredForAllUsers ? 1 : 0);
-        dest.writeInt(requiredForProfile);
         dest.writeString(restrictedAccountType);
         dest.writeString(requiredAccountType);
         dest.writeString(overlayTarget);
@@ -358,7 +338,6 @@
         featureGroups = source.createTypedArray(FeatureGroupInfo.CREATOR);
         installLocation = source.readInt();
         requiredForAllUsers = source.readInt() != 0;
-        requiredForProfile = source.readInt();
         restrictedAccountType = source.readString();
         requiredAccountType = source.readString();
         overlayTarget = source.readString();
diff --git a/core/java/android/content/pm/PackageInstaller.java b/core/java/android/content/pm/PackageInstaller.java
index aa4ea45..db8fac2 100644
--- a/core/java/android/content/pm/PackageInstaller.java
+++ b/core/java/android/content/pm/PackageInstaller.java
@@ -45,6 +45,7 @@
 import java.io.OutputStream;
 import java.security.MessageDigest;
 import java.util.ArrayList;
+import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
 
@@ -81,11 +82,13 @@
      * may surface actions such as pause, resume, or cancel.
      * <p>
      * This should always be scoped to the installer package that owns the
-     * session. Clients should use {@link SessionInfo#getDetailsIntent()} to
+     * session. Clients should use {@link SessionInfo#createDetailsIntent()} to
      * build this intent correctly.
      * <p>
      * In some cases, a matching Activity may not exist, so ensure you safeguard
      * against this.
+     * <p>
+     * The session to show details for is defined in {@link #EXTRA_SESSION_ID}.
      */
     @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
     public static final String ACTION_SESSION_DETAILS = "android.content.pm.action.SESSION_DETAILS";
@@ -95,20 +98,60 @@
             ACTION_CONFIRM_PERMISSIONS = "android.content.pm.action.CONFIRM_PERMISSIONS";
 
     /**
-     * An integer session ID.
+     * An integer session ID that an operation is working with.
      *
-     * @see #ACTION_SESSION_DETAILS
+     * @see Intent#getIntExtra(String, int)
      */
     public static final String EXTRA_SESSION_ID = "android.content.pm.extra.SESSION_ID";
 
+    /**
+     * Package name that an operation is working with.
+     *
+     * @see Intent#getStringExtra(String)
+     */
+    public static final String EXTRA_PACKAGE_NAME = "android.content.pm.extra.PACKAGE_NAME";
+
+    /**
+     * Current status of an operation. Will be one of
+     * {@link #STATUS_PENDING_USER_ACTION}, {@link #STATUS_SUCCESS},
+     * {@link #STATUS_FAILURE}, {@link #STATUS_FAILURE_ABORTED},
+     * {@link #STATUS_FAILURE_BLOCKED}, {@link #STATUS_FAILURE_CONFLICT},
+     * {@link #STATUS_FAILURE_INCOMPATIBLE}, {@link #STATUS_FAILURE_INVALID}, or
+     * {@link #STATUS_FAILURE_STORAGE}.
+     * <p>
+     * More information about a status may be available through additional
+     * extras; see the individual status documentation for details.
+     *
+     * @see Intent#getIntExtra(String, int)
+     */
     public static final String EXTRA_STATUS = "android.content.pm.extra.STATUS";
+
+    /**
+     * Detailed string representation of the status, including raw details that
+     * are useful for debugging.
+     *
+     * @see Intent#getStringExtra(String)
+     */
     public static final String EXTRA_STATUS_MESSAGE = "android.content.pm.extra.STATUS_MESSAGE";
 
     /**
-     * List of package names that are relevant to a status.
+     * Another package name relevant to a status. This is typically the package
+     * responsible for causing an operation failure.
      *
-     * @see Intent#getStringArrayExtra(String)
+     * @see Intent#getStringExtra(String)
      */
+    public static final String
+            EXTRA_OTHER_PACKAGE_NAME = "android.content.pm.extra.OTHER_PACKAGE_NAME";
+
+    /**
+     * Storage path relevant to a status.
+     *
+     * @see Intent#getStringExtra(String)
+     */
+    public static final String EXTRA_STORAGE_PATH = "android.content.pm.extra.STORAGE_PATH";
+
+    /** {@hide} */
+    @Deprecated
     public static final String EXTRA_PACKAGE_NAMES = "android.content.pm.extra.PACKAGE_NAMES";
 
     /** {@hide} */
@@ -129,7 +172,7 @@
      *
      * @see Intent#getParcelableExtra(String)
      */
-    public static final int STATUS_USER_ACTION_REQUIRED = -1;
+    public static final int STATUS_PENDING_USER_ACTION = -1;
 
     /**
      * The operation succeeded.
@@ -149,10 +192,14 @@
      * The operation failed because it was blocked. For example, a device policy
      * may be blocking the operation, a package verifier may have blocked the
      * operation, or the app may be required for core system operation.
+     * <p>
+     * The result may also contain {@link #EXTRA_OTHER_PACKAGE_NAME} with the
+     * specific package blocking the install.
      *
      * @see #EXTRA_STATUS_MESSAGE
+     * @see #EXTRA_OTHER_PACKAGE_NAME
      */
-    public static final int STATUS_FAILURE_BLOCKED = 1;
+    public static final int STATUS_FAILURE_BLOCKED = 2;
 
     /**
      * The operation failed because it was actively aborted. For example, the
@@ -161,7 +208,7 @@
      *
      * @see #EXTRA_STATUS_MESSAGE
      */
-    public static final int STATUS_FAILURE_ABORTED = 2;
+    public static final int STATUS_FAILURE_ABORTED = 3;
 
     /**
      * The operation failed because one or more of the APKs was invalid. For
@@ -170,7 +217,7 @@
      *
      * @see #EXTRA_STATUS_MESSAGE
      */
-    public static final int STATUS_FAILURE_INVALID = 3;
+    public static final int STATUS_FAILURE_INVALID = 4;
 
     /**
      * The operation failed because it conflicts (or is inconsistent with) with
@@ -178,21 +225,26 @@
      * permission, incompatible certificates, etc. The user may be able to
      * uninstall another app to fix the issue.
      * <p>
-     * The result may also contain {@link #EXTRA_PACKAGE_NAMES} with the
-     * specific packages identified as the cause of the conflict.
+     * The result may also contain {@link #EXTRA_OTHER_PACKAGE_NAME} with the
+     * specific package identified as the cause of the conflict.
      *
      * @see #EXTRA_STATUS_MESSAGE
+     * @see #EXTRA_OTHER_PACKAGE_NAME
      */
-    public static final int STATUS_FAILURE_CONFLICT = 4;
+    public static final int STATUS_FAILURE_CONFLICT = 5;
 
     /**
      * The operation failed because of storage issues. For example, the device
      * may be running low on space, or external media may be unavailable. The
      * user may be able to help free space or insert different external media.
+     * <p>
+     * The result may also contain {@link #EXTRA_STORAGE_PATH} with the path to
+     * the storage device that caused the failure.
      *
      * @see #EXTRA_STATUS_MESSAGE
+     * @see #EXTRA_STORAGE_PATH
      */
-    public static final int STATUS_FAILURE_STORAGE = 5;
+    public static final int STATUS_FAILURE_STORAGE = 6;
 
     /**
      * The operation failed because it is fundamentally incompatible with this
@@ -202,7 +254,7 @@
      *
      * @see #EXTRA_STATUS_MESSAGE
      */
-    public static final int STATUS_FAILURE_INCOMPATIBLE = 6;
+    public static final int STATUS_FAILURE_INCOMPATIBLE = 7;
 
     private final Context mContext;
     private final PackageManager mPm;
@@ -233,6 +285,9 @@
      *
      * @throws IOException if parameters were unsatisfiable, such as lack of
      *             disk space or unavailable media.
+     * @throws SecurityException when installation services are unavailable,
+     *             such as when called from a restricted user.
+     * @throws IllegalArgumentException when {@link SessionParams} is invalid.
      * @return positive, non-zero unique ID that represents the created session.
      *         This ID remains consistent across device reboots until the
      *         session is finalized. IDs are not reused during a given boot.
@@ -251,18 +306,78 @@
     /**
      * Open an existing session to actively perform work. To succeed, the caller
      * must be the owner of the install session.
+     *
+     * @throws IOException if parameters were unsatisfiable, such as lack of
+     *             disk space or unavailable media.
+     * @throws SecurityException when the caller does not own the session, or
+     *             the session is invalid.
      */
-    public @NonNull Session openSession(int sessionId) {
+    public @NonNull Session openSession(int sessionId) throws IOException {
         try {
             return new Session(mInstaller.openSession(sessionId));
+        } catch (RuntimeException e) {
+            ExceptionUtils.maybeUnwrapIOException(e);
+            throw e;
         } catch (RemoteException e) {
             throw e.rethrowAsRuntimeException();
         }
     }
 
     /**
-     * Return details for a specific session. To succeed, the caller must either
-     * own this session, or be the current home app.
+     * Update the icon representing the app being installed in a specific
+     * session. This should be roughly
+     * {@link ActivityManager#getLauncherLargeIconSize()} in both dimensions.
+     *
+     * @throws SecurityException when the caller does not own the session, or
+     *             the session is invalid.
+     */
+    public void updateSessionAppIcon(int sessionId, @Nullable Bitmap appIcon) {
+        try {
+            mInstaller.updateSessionAppIcon(sessionId, appIcon);
+        } catch (RemoteException e) {
+            throw e.rethrowAsRuntimeException();
+        }
+    }
+
+    /**
+     * Update the label representing the app being installed in a specific
+     * session.
+     *
+     * @throws SecurityException when the caller does not own the session, or
+     *             the session is invalid.
+     */
+    public void updateSessionAppLabel(int sessionId, @Nullable CharSequence appLabel) {
+        try {
+            final String val = (appLabel != null) ? appLabel.toString() : null;
+            mInstaller.updateSessionAppLabel(sessionId, val);
+        } catch (RemoteException e) {
+            throw e.rethrowAsRuntimeException();
+        }
+    }
+
+    /**
+     * Completely abandon the given session, destroying all staged data and
+     * rendering it invalid. Abandoned sessions will be reported to
+     * {@link SessionCallback} listeners as failures. This is equivalent to
+     * opening the session and calling {@link Session#abandon()}.
+     *
+     * @throws SecurityException when the caller does not own the session, or
+     *             the session is invalid.
+     */
+    public void abandonSession(int sessionId) {
+        try {
+            mInstaller.abandonSession(sessionId);
+        } catch (RemoteException e) {
+            throw e.rethrowAsRuntimeException();
+        }
+    }
+
+    /**
+     * Return details for a specific session. No special permissions are
+     * required to retrieve these details.
+     *
+     * @return details for the requested session, or {@code null} if the session
+     *         does not exist.
      */
     public @Nullable SessionInfo getSessionInfo(int sessionId) {
         try {
@@ -273,10 +388,16 @@
     }
 
     /**
-     * Return list of all active install sessions, regardless of the installer.
-     * To succeed, the caller must be the current home app.
+     * Return list of all known install sessions, regardless of the installer.
      */
     public @NonNull List<SessionInfo> getAllSessions() {
+        final ApplicationInfo info = mContext.getApplicationInfo();
+        if ("com.google.android.googlequicksearchbox".equals(info.packageName)
+                && info.versionCode <= 300400110) {
+            Log.d(TAG, "Ignoring callback request from old prebuilt");
+            return Collections.EMPTY_LIST;
+        }
+
         try {
             return mInstaller.getAllSessions(mUserId);
         } catch (RemoteException e) {
@@ -285,7 +406,7 @@
     }
 
     /**
-     * Return list of all install sessions owned by the calling app.
+     * Return list of all known install sessions owned by the calling app.
      */
     public @NonNull List<SessionInfo> getMySessions() {
         try {
@@ -339,27 +460,38 @@
         public abstract void onCreated(int sessionId);
 
         /**
-         * Session has been opened. A session is usually opened when the
-         * installer is actively writing data.
+         * Badging details for an existing session has changed. For example, the
+         * app icon or label has been updated.
          */
-        public abstract void onOpened(int sessionId);
+        public abstract void onBadgingChanged(int sessionId);
+
+        /**
+         * Active state for session has been changed.
+         * <p>
+         * A session is considered active whenever there is ongoing forward
+         * progress being made, such as the installer holding an open
+         * {@link Session} instance while streaming data into place, or the
+         * system optimizing code as the result of
+         * {@link Session#commit(IntentSender)}.
+         * <p>
+         * If the installer closes the {@link Session} without committing, the
+         * session is considered inactive until the installer opens the session
+         * again.
+         */
+        public abstract void onActiveChanged(int sessionId, boolean active);
 
         /**
          * Progress for given session has been updated.
          * <p>
          * Note that this progress may not directly correspond to the value
-         * reported by {@link PackageInstaller.Session#setProgress(float)}, as
-         * the system may carve out a portion of the overall progress to
-         * represent its own internal installation work.
+         * reported by
+         * {@link PackageInstaller.Session#setStagingProgress(float)}, as the
+         * system may carve out a portion of the overall progress to represent
+         * its own internal installation work.
          */
         public abstract void onProgressChanged(int sessionId, float progress);
 
         /**
-         * Session has been closed.
-         */
-        public abstract void onClosed(int sessionId);
-
-        /**
          * Session has completely finished, either with success or failure.
          */
         public abstract void onFinished(int sessionId, boolean success);
@@ -369,9 +501,9 @@
     private static class SessionCallbackDelegate extends IPackageInstallerCallback.Stub implements
             Handler.Callback {
         private static final int MSG_SESSION_CREATED = 1;
-        private static final int MSG_SESSION_OPENED = 2;
-        private static final int MSG_SESSION_PROGRESS_CHANGED = 3;
-        private static final int MSG_SESSION_CLOSED = 4;
+        private static final int MSG_SESSION_BADGING_CHANGED = 2;
+        private static final int MSG_SESSION_ACTIVE_CHANGED = 3;
+        private static final int MSG_SESSION_PROGRESS_CHANGED = 4;
         private static final int MSG_SESSION_FINISHED = 5;
 
         final SessionCallback mCallback;
@@ -384,21 +516,23 @@
 
         @Override
         public boolean handleMessage(Message msg) {
+            final int sessionId = msg.arg1;
             switch (msg.what) {
                 case MSG_SESSION_CREATED:
-                    mCallback.onCreated(msg.arg1);
+                    mCallback.onCreated(sessionId);
                     return true;
-                case MSG_SESSION_OPENED:
-                    mCallback.onOpened(msg.arg1);
+                case MSG_SESSION_BADGING_CHANGED:
+                    mCallback.onBadgingChanged(sessionId);
+                    return true;
+                case MSG_SESSION_ACTIVE_CHANGED:
+                    final boolean active = msg.arg2 != 0;
+                    mCallback.onActiveChanged(sessionId, active);
                     return true;
                 case MSG_SESSION_PROGRESS_CHANGED:
-                    mCallback.onProgressChanged(msg.arg1, (float) msg.obj);
-                    return true;
-                case MSG_SESSION_CLOSED:
-                    mCallback.onClosed(msg.arg1);
+                    mCallback.onProgressChanged(sessionId, (float) msg.obj);
                     return true;
                 case MSG_SESSION_FINISHED:
-                    mCallback.onFinished(msg.arg1, msg.arg2 != 0);
+                    mCallback.onFinished(sessionId, msg.arg2 != 0);
                     return true;
             }
             return false;
@@ -410,8 +544,14 @@
         }
 
         @Override
-        public void onSessionOpened(int sessionId) {
-            mHandler.obtainMessage(MSG_SESSION_OPENED, sessionId, 0).sendToTarget();
+        public void onSessionBadgingChanged(int sessionId) {
+            mHandler.obtainMessage(MSG_SESSION_BADGING_CHANGED, sessionId, 0).sendToTarget();
+        }
+
+        @Override
+        public void onSessionActiveChanged(int sessionId, boolean active) {
+            mHandler.obtainMessage(MSG_SESSION_ACTIVE_CHANGED, sessionId, active ? 1 : 0)
+                    .sendToTarget();
         }
 
         @Override
@@ -421,37 +561,44 @@
         }
 
         @Override
-        public void onSessionClosed(int sessionId) {
-            mHandler.obtainMessage(MSG_SESSION_CLOSED, sessionId, 0).sendToTarget();
-        }
-
-        @Override
         public void onSessionFinished(int sessionId, boolean success) {
             mHandler.obtainMessage(MSG_SESSION_FINISHED, sessionId, success ? 1 : 0)
                     .sendToTarget();
         }
     }
 
-    /**
-     * Register to watch for session lifecycle events. To succeed, the caller
-     * must be the current home app.
-     */
+    /** {@hide} */
+    @Deprecated
     public void addSessionCallback(@NonNull SessionCallback callback) {
-        addSessionCallback(callback, new Handler());
+        registerSessionCallback(callback);
     }
 
     /**
-     * Register to watch for session lifecycle events. To succeed, the caller
-     * must be the current home app.
+     * Register to watch for session lifecycle events. No special permissions
+     * are required to watch for these events.
+     */
+    public void registerSessionCallback(@NonNull SessionCallback callback) {
+        registerSessionCallback(callback, new Handler());
+    }
+
+    /** {@hide} */
+    @Deprecated
+    public void addSessionCallback(@NonNull SessionCallback callback, @NonNull Handler handler) {
+        registerSessionCallback(callback, handler);
+    }
+
+    /**
+     * Register to watch for session lifecycle events. No special permissions
+     * are required to watch for these events.
      *
      * @param handler to dispatch callback events through, otherwise uses
      *            calling thread.
      */
-    public void addSessionCallback(@NonNull SessionCallback callback, @NonNull Handler handler) {
+    public void registerSessionCallback(@NonNull SessionCallback callback, @NonNull Handler handler) {
         // TODO: remove this temporary guard once we have new prebuilts
         final ApplicationInfo info = mContext.getApplicationInfo();
         if ("com.google.android.googlequicksearchbox".equals(info.packageName)
-                && info.versionCode <= 300400070) {
+                && info.versionCode <= 300400110) {
             Log.d(TAG, "Ignoring callback request from old prebuilt");
             return;
         }
@@ -468,10 +615,16 @@
         }
     }
 
-    /**
-     * Unregister an existing callback.
-     */
+    /** {@hide} */
+    @Deprecated
     public void removeSessionCallback(@NonNull SessionCallback callback) {
+        unregisterSessionCallback(callback);
+    }
+
+    /**
+     * Unregister a previously registered callback.
+     */
+    public void unregisterSessionCallback(@NonNull SessionCallback callback) {
         synchronized (mDelegates) {
             for (Iterator<SessionCallbackDelegate> i = mDelegates.iterator(); i.hasNext();) {
                 final SessionCallbackDelegate delegate = i.next();
@@ -507,10 +660,22 @@
             mSession = session;
         }
 
-        /**
-         * Set current progress. Valid values are anywhere between 0 and 1.
-         */
+        /** {@hide} */
+        @Deprecated
         public void setProgress(float progress) {
+            setStagingProgress(progress);
+        }
+
+        /**
+         * Set current progress of staging this session. Valid values are
+         * anywhere between 0 and 1.
+         * <p>
+         * Note that this progress may not directly correspond to the value
+         * reported by {@link SessionCallback#onProgressChanged(int, float)}, as
+         * the system may carve out a portion of the overall progress to
+         * represent its own internal installation work.
+         */
+        public void setStagingProgress(float progress) {
             try {
                 mSession.setClientProgress(progress);
             } catch (RemoteException e) {
@@ -550,13 +715,19 @@
          *            start at the beginning of the file.
          * @param lengthBytes total size of the file being written, used to
          *            preallocate the underlying disk space, or -1 if unknown.
+         *            The system may clear various caches as needed to allocate
+         *            this space.
+         * @throws IOException if trouble opening the file for writing, such as
+         *             lack of disk space or unavailable media.
+         * @throws SecurityException if called after the session has been
+         *             committed or abandoned.
          */
         public @NonNull OutputStream openWrite(@NonNull String name, long offsetBytes,
                 long lengthBytes) throws IOException {
             try {
                 final ParcelFileDescriptor clientSocket = mSession.openWrite(name,
                         offsetBytes, lengthBytes);
-                return new FileBridge.FileBridgeOutputStream(clientSocket.getFileDescriptor());
+                return new FileBridge.FileBridgeOutputStream(clientSocket);
             } catch (RuntimeException e) {
                 ExceptionUtils.maybeUnwrapIOException(e);
                 throw e;
@@ -583,10 +754,16 @@
          * <p>
          * This returns all names which have been previously written through
          * {@link #openWrite(String, long, long)} as part of this session.
+         *
+         * @throws SecurityException if called after the session has been
+         *             committed or abandoned.
          */
-        public @NonNull String[] getNames() {
+        public @NonNull String[] getNames() throws IOException {
             try {
                 return mSession.getNames();
+            } catch (RuntimeException e) {
+                ExceptionUtils.maybeUnwrapIOException(e);
+                throw e;
             } catch (RemoteException e) {
                 throw e.rethrowAsRuntimeException();
             }
@@ -599,6 +776,9 @@
          * through {@link #openWrite(String, long, long)} as part of this
          * session. For example, this stream may be used to calculate a
          * {@link MessageDigest} of a written APK before committing.
+         *
+         * @throws SecurityException if called after the session has been
+         *             committed or abandoned.
          */
         public @NonNull InputStream openRead(@NonNull String name) throws IOException {
             try {
@@ -620,6 +800,9 @@
          * Once this method is called, no additional mutations may be performed
          * on the session. If the device reboots before the session has been
          * finalized, you may commit the session again.
+         *
+         * @throws SecurityException if streams opened through
+         *             {@link #openWrite(String, long, long)} are still open.
          */
         public void commit(@NonNull IntentSender statusReceiver) {
             try {
@@ -644,7 +827,9 @@
 
         /**
          * Completely abandon this session, destroying all staged data and
-         * rendering it invalid.
+         * rendering it invalid. Abandoned sessions will be reported to
+         * {@link SessionCallback} listeners as failures. This is equivalent to
+         * opening the session and calling {@link Session#abandon()}.
          */
         public void abandon() {
             try {
@@ -798,6 +983,18 @@
         }
 
         /** {@hide} */
+        public void setInstallFlagsInternal() {
+            installFlags |= PackageManager.INSTALL_INTERNAL;
+            installFlags &= ~PackageManager.INSTALL_EXTERNAL;
+        }
+
+        /** {@hide} */
+        public void setInstallFlagsExternal() {
+            installFlags |= PackageManager.INSTALL_EXTERNAL;
+            installFlags &= ~PackageManager.INSTALL_INTERNAL;
+        }
+
+        /** {@hide} */
         public void dump(IndentingPrintWriter pw) {
             pw.printPair("mode", mode);
             pw.printHexPair("installFlags", installFlags);
@@ -861,7 +1058,7 @@
         /** {@hide} */
         public boolean sealed;
         /** {@hide} */
-        public boolean open;
+        public boolean active;
 
         /** {@hide} */
         public int mode;
@@ -885,7 +1082,7 @@
             resolvedBaseCodePath = source.readString();
             progress = source.readFloat();
             sealed = source.readInt() != 0;
-            open = source.readInt() != 0;
+            active = source.readInt() != 0;
 
             mode = source.readInt();
             sizeBytes = source.readLong();
@@ -911,20 +1108,37 @@
         /**
          * Return current overall progress of this session, between 0 and 1.
          * <p>
-         * Note that this progress may not directly correspond to the value reported
-         * by {@link PackageInstaller.Session#setProgress(float)}, as the system may
-         * carve out a portion of the overall progress to represent its own internal
-         * installation work.
+         * Note that this progress may not directly correspond to the value
+         * reported by
+         * {@link PackageInstaller.Session#setStagingProgress(float)}, as the
+         * system may carve out a portion of the overall progress to represent
+         * its own internal installation work.
          */
         public float getProgress() {
             return progress;
         }
 
         /**
-         * Return if this session is currently open.
+         * Return if this session is currently active.
+         * <p>
+         * A session is considered active whenever there is ongoing forward
+         * progress being made, such as the installer holding an open
+         * {@link Session} instance while streaming data into place, or the
+         * system optimizing code as the result of
+         * {@link Session#commit(IntentSender)}.
+         * <p>
+         * If the installer closes the {@link Session} without committing, the
+         * session is considered inactive until the installer opens the session
+         * again.
          */
+        public boolean isActive() {
+            return active;
+        }
+
+        /** {@hide} */
+        @Deprecated
         public boolean isOpen() {
-            return open;
+            return isActive();
         }
 
         /**
@@ -960,7 +1174,7 @@
          *
          * @see PackageInstaller#ACTION_SESSION_DETAILS
          */
-        public @Nullable Intent getDetailsIntent() {
+        public @Nullable Intent createDetailsIntent() {
             final Intent intent = new Intent(PackageInstaller.ACTION_SESSION_DETAILS);
             intent.putExtra(PackageInstaller.EXTRA_SESSION_ID, sessionId);
             intent.setPackage(installerPackageName);
@@ -968,6 +1182,12 @@
             return intent;
         }
 
+        /** {@hide} */
+        @Deprecated
+        public @Nullable Intent getDetailsIntent() {
+            return createDetailsIntent();
+        }
+
         @Override
         public int describeContents() {
             return 0;
@@ -980,7 +1200,7 @@
             dest.writeString(resolvedBaseCodePath);
             dest.writeFloat(progress);
             dest.writeInt(sealed ? 1 : 0);
-            dest.writeInt(open ? 1 : 0);
+            dest.writeInt(active ? 1 : 0);
 
             dest.writeInt(mode);
             dest.writeLong(sizeBytes);
diff --git a/core/java/android/content/pm/PackageManager.java b/core/java/android/content/pm/PackageManager.java
index 56b7164..e519163 100644
--- a/core/java/android/content/pm/PackageManager.java
+++ b/core/java/android/content/pm/PackageManager.java
@@ -23,6 +23,7 @@
 import android.annotation.SystemApi;
 import android.app.PackageDeleteObserver;
 import android.app.PackageInstallObserver;
+import android.app.admin.DevicePolicyManager;
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
@@ -31,6 +32,7 @@
 import android.content.pm.PackageParser.PackageParserException;
 import android.content.res.Resources;
 import android.content.res.XmlResourceParser;
+import android.graphics.Rect;
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
 import android.os.Bundle;
@@ -200,12 +202,6 @@
     public static final int MATCH_DEFAULT_ONLY   = 0x00010000;
 
     /**
-     * Resolution and querying flag: do not resolve intents cross-profile.
-     * @hide
-     */
-    public static final int NO_CROSS_PROFILE = 0x00020000;
-
-    /**
      * Flag for {@link addCrossProfileIntentFilter}: if this flag is set:
      * when resolving an intent that matches the {@link CrossProfileIntentFilter}, the current
      * profile will be skipped.
@@ -975,6 +971,14 @@
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and
+     * {@link #hasSystemFeature}: The device includes at least one form of audio
+     * output, such as speakers, audio jack or streaming over bluetooth
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_AUDIO_OUTPUT = "android.hardware.audio.output";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and
      * {@link #hasSystemFeature}: The device is capable of communicating with
      * other devices via Bluetooth.
      */
@@ -1217,6 +1221,14 @@
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and
+     * {@link #hasSystemFeature}: The heart rate sensor on this device is an Electrocargiogram.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_SENSOR_HEART_RATE_ECG =
+            "android.hardware.sensor.heartrate.ecg";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and
      * {@link #hasSystemFeature}: The device includes a relative humidity sensor.
      */
     @SdkConstant(SdkConstantType.FEATURE)
@@ -1284,12 +1296,18 @@
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and
+     * {@link #hasSystemFeature}: The Connection Service API is enabled on the device.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_CONNECTION_SERVICE = "android.software.connectionservice";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and
      * {@link #hasSystemFeature}: The device's display has a touch screen.
      */
     @SdkConstant(SdkConstantType.FEATURE)
     public static final String FEATURE_TOUCHSCREEN = "android.hardware.touchscreen";
 
-
     /**
      * Feature for {@link #getSystemAvailableFeatures} and
      * {@link #hasSystemFeature}: The device's touch screen supports
@@ -1448,6 +1466,15 @@
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and
+     * {@link #hasSystemFeature}: The device supports live TV and can display
+     * contents from TV inputs implemented with the
+     * {@link android.media.tv.TvInputService} API.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_LIVE_TV = "android.software.live_tv";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and
      * {@link #hasSystemFeature}: The device supports WiFi (802.11) networking.
      */
     @SdkConstant(SdkConstantType.FEATURE)
@@ -1498,10 +1525,33 @@
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and {@link #hasSystemFeature}:
-     * The device supports managed profiles for enterprise users.
+     * The device supports creating secondary users and managed profiles via
+     * {@link DevicePolicyManager}.
      */
     @SdkConstant(SdkConstantType.FEATURE)
-    public static final String FEATURE_MANAGED_PROFILES = "android.software.managed_profiles";
+    public static final String FEATURE_MANAGED_USERS = "android.software.managed_users";
+
+    /**
+     * @hide
+     * TODO: Remove after dependencies updated b/17392243
+     */
+    public static final String FEATURE_MANAGED_PROFILES = "android.software.managed_users";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and {@link #hasSystemFeature}:
+     * The device supports verified boot.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_VERIFIED_BOOT = "android.software.verified_boot";
+
+    /**
+     * Feature for {@link #getSystemAvailableFeatures} and {@link #hasSystemFeature}:
+     * The device supports secure removal of users. When a user is deleted the data associated
+     * with that user is securely deleted and no longer available.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_SECURELY_REMOVES_USERS
+            = "android.software.securely_removes_users";
 
     /**
      * Feature for {@link #getSystemAvailableFeatures} and {@link #hasSystemFeature}:
@@ -1528,6 +1578,15 @@
     public static final String FEATURE_HDMI_CEC = "android.hardware.hdmi.cec";
 
     /**
+     * Feature for {@link #getSystemAvailableFeatures} and {@link #hasSystemFeature}:
+     * The device has all of the inputs necessary to be considered a compatible game controller, or
+     * includes a compatible game controller in the box.
+     */
+    @SdkConstant(SdkConstantType.FEATURE)
+    public static final String FEATURE_GAMEPAD = "android.hardware.gamepad";
+
+
+    /**
      * Action to external storage service to clean out removed apps.
      * @hide
      */
@@ -1701,7 +1760,7 @@
      * @return A fully-qualified {@link Intent} that can be used to launch the
      * main activity in the package. Returns <code>null</code> if the package
      * does not contain such an activity, or if <em>packageName</em> is not
-     * recognized. 
+     * recognized.
      */
     public abstract Intent getLaunchIntentForPackage(String packageName);
 
@@ -2405,7 +2464,6 @@
      * @see #MATCH_DEFAULT_ONLY
      * @see #GET_INTENT_FILTERS
      * @see #GET_RESOLVED_FILTER
-     * @see #NO_CROSS_PROFILE
      * @hide
      */
     public abstract List<ResolveInfo> queryIntentActivitiesAsUser(Intent intent,
@@ -2865,6 +2923,79 @@
             throws NameNotFoundException;
 
     /**
+     * If the target user is a managed profile of the calling user or the caller
+     * is itself a managed profile, then this returns a badged copy of the given
+     * icon to be able to distinguish it from the original icon. For badging an
+     * arbitrary drawable use {@link #getUserBadgedDrawableForDensity(
+     * android.graphics.drawable.Drawable, UserHandle, android.graphics.Rect, int)}.
+     * <p>
+     * If the original drawable is a BitmapDrawable and the backing bitmap is
+     * mutable as per {@link android.graphics.Bitmap#isMutable()}, the badging
+     * is performed in place and the original drawable is returned.
+     * </p>
+     *
+     * @param icon The icon to badge.
+     * @param user The target user.
+     * @return A drawable that combines the original icon and a badge as
+     *         determined by the system.
+     */
+    public abstract Drawable getUserBadgedIcon(Drawable icon, UserHandle user);
+
+    /**
+     * If the target user is a managed profile of the calling user or the caller
+     * is itself a managed profile, then this returns a badged copy of the given
+     * drawable allowing the user to distinguish it from the original drawable.
+     * The caller can specify the location in the bounds of the drawable to be
+     * badged where the badge should be applied as well as the density of the
+     * badge to be used.
+     * <p>
+     * If the original drawable is a BitmapDrawable and the backing bitmap is
+     * mutable as per {@link android.graphics.Bitmap#isMutable()}, the bading
+     * is performed in place and the original drawable is returned.
+     * </p>
+     *
+     * @param drawable The drawable to badge.
+     * @param user The target user.
+     * @param badgeLocation Where in the bounds of the badged drawable to place
+     *         the badge. If not provided, the badge is applied on top of the entire
+     *         drawable being badged.
+     * @param badgeDensity The optional desired density for the badge as per
+     *         {@link android.util.DisplayMetrics#densityDpi}. If not provided,
+     *         the density of the display is used.
+     * @return A drawable that combines the original drawable and a badge as
+     *         determined by the system.
+     */
+    public abstract Drawable getUserBadgedDrawableForDensity(Drawable drawable,
+            UserHandle user, Rect badgeLocation, int badgeDensity);
+
+    /**
+     * If the target user is a managed profile of the calling user or the caller
+     * is itself a managed profile, then this returns a drawable to use as a small
+     * icon to include in a view to distinguish it from the original icon.
+     *
+     * @param user The target user.
+     * @param density The optional desired density for the badge as per
+     *         {@link android.util.DisplayMetrics#densityDpi}. If not provided
+     *         the density of the current display is used.
+     * @return the drawable or null if no drawable is required.
+     * @hide
+     */
+    public abstract Drawable getUserBadgeForDensity(UserHandle user, int density);
+
+    /**
+     * If the target user is a managed profile of the calling user or the caller
+     * is itself a managed profile, then this returns a copy of the label with
+     * badging for accessibility services like talkback. E.g. passing in "Email"
+     * and it might return "Work Email" for Email in the work profile.
+     *
+     * @param label The label to change.
+     * @param user The target user.
+     * @return A label that combines the original label and a badge as
+     *         determined by the system.
+     */
+    public abstract CharSequence getUserBadgedLabel(CharSequence label, UserHandle user);
+
+    /**
      * Retrieve text from a package.  This is a low-level API used by
      * the various package manager info structures (such as
      * {@link ComponentInfo} to implement retrieval of their associated
@@ -3681,10 +3812,13 @@
      *
      * @param alias The alias for a given {@link KeySet} as defined in the
      *        application's AndroidManifest.xml.
+     * @hide
      */
     public abstract KeySet getKeySetByAlias(String packageName, String alias);
 
-    /** Return the signing {@link KeySet} for this application. */
+    /** Return the signing {@link KeySet} for this application.
+     * @hide
+     */
     public abstract KeySet getSigningKeySet(String packageName);
 
     /**
@@ -3692,6 +3826,7 @@
      * of the keys specified by the {@link KeySet} ks.  This will return true if
      * the package has been signed by additional keys (a superset) as well.
      * Compare to {@link #isSignedByExactly(String packageName, KeySet ks)}.
+     * @hide
      */
     public abstract boolean isSignedBy(String packageName, KeySet ks);
 
@@ -3699,6 +3834,7 @@
      * Return whether the package denoted by packageName has been signed by all
      * of, and only, the keys specified by the {@link KeySet} ks. Compare to
      * {@link #isSignedBy(String packageName, KeySet ks)}.
+     * @hide
      */
     public abstract boolean isSignedByExactly(String packageName, KeySet ks);
 
@@ -3771,22 +3907,6 @@
     public abstract void clearCrossProfileIntentFilters(int sourceUserId);
 
     /**
-     * Forwards all intents for {@link packageName} for user {@link sourceUserId} to user
-     * {@link targetUserId}.
-     * @hide
-     */
-    public abstract void addCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId);
-
-    /**
-     * Removes all intents for {@link packageName} for user {@link sourceUserId} to user
-     * {@link targetUserId}.
-     * @hide
-     */
-    public abstract void removeCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId);
-
-    /**
      * @hide
      */
     public abstract Drawable loadItemIcon(PackageItemInfo itemInfo, ApplicationInfo appInfo);
diff --git a/core/java/android/content/pm/PackageParser.java b/core/java/android/content/pm/PackageParser.java
index cddefb5..ffde7ce 100644
--- a/core/java/android/content/pm/PackageParser.java
+++ b/core/java/android/content/pm/PackageParser.java
@@ -25,6 +25,7 @@
 import static android.content.pm.PackageManager.INSTALL_PARSE_FAILED_NO_CERTIFICATES;
 import static android.content.pm.PackageManager.INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION;
 
+import android.app.ActivityManager;
 import android.content.ComponentName;
 import android.content.Intent;
 import android.content.IntentFilter;
@@ -264,7 +265,7 @@
         public final boolean coreApp;
         public final boolean multiArch;
 
-        private PackageLite(String codePath, ApkLite baseApk, String[] splitNames,
+        public PackageLite(String codePath, ApkLite baseApk, String[] splitNames,
                 String[] splitCodePaths) {
             this.packageName = baseApk.packageName;
             this.versionCode = baseApk.versionCode;
@@ -354,7 +355,11 @@
     }
 
     public static final boolean isApkFile(File file) {
-        return file.getName().endsWith(".apk");
+        return isApkPath(file.getName());
+    }
+
+    private static boolean isApkPath(String path) {
+        return path.endsWith(".apk");
     }
 
     /*
@@ -413,7 +418,6 @@
         if ((pi.applicationInfo.flags&ApplicationInfo.FLAG_SYSTEM) != 0
                 || (pi.applicationInfo.flags&ApplicationInfo.FLAG_UPDATED_SYSTEM_APP) != 0) {
             pi.requiredForAllUsers = p.mRequiredForAllUsers;
-            pi.requiredForProfile = p.mRequiredForProfile;
         }
         pi.restrictedAccountType = p.mRestrictedAccountType;
         pi.requiredAccountType = p.mRequiredAccountType;
@@ -597,7 +601,7 @@
     public final static int PARSE_ON_SDCARD = 1<<5;
     public final static int PARSE_IS_SYSTEM_DIR = 1<<6;
     public final static int PARSE_IS_PRIVILEGED = 1<<7;
-    public final static int PARSE_GET_SIGNATURES = 1<<8;
+    public final static int PARSE_COLLECT_CERTIFICATES = 1<<8;
     public final static int PARSE_TRUSTED_OVERLAY = 1<<9;
 
     private static final Comparator<String> sSplitNameComparator = new SplitNameComparator();
@@ -755,26 +759,41 @@
                     "Not a coreApp: " + packageDir);
         }
 
-        final File baseApk = new File(lite.baseCodePath);
-        final Package pkg = parseBaseApk(baseApk, flags);
-        if (pkg == null) {
-            throw new PackageParserException(INSTALL_PARSE_FAILED_NOT_APK,
-                    "Failed to parse base APK: " + baseApk);
-        }
+        final AssetManager assets = new AssetManager();
+        try {
+            // Load the base and all splits into the AssetManager
+            // so that resources can be overriden when parsing the manifests.
+            loadApkIntoAssetManager(assets, lite.baseCodePath, flags);
 
-        if (!ArrayUtils.isEmpty(lite.splitNames)) {
-            final int num = lite.splitNames.length;
-            pkg.splitNames = lite.splitNames;
-            pkg.splitCodePaths = lite.splitCodePaths;
-            pkg.splitFlags = new int[num];
-
-            for (int i = 0; i < num; i++) {
-                parseSplitApk(pkg, i, flags);
+            if (!ArrayUtils.isEmpty(lite.splitCodePaths)) {
+                for (String path : lite.splitCodePaths) {
+                    loadApkIntoAssetManager(assets, path, flags);
+                }
             }
-        }
 
-        pkg.codePath = packageDir.getAbsolutePath();
-        return pkg;
+            final File baseApk = new File(lite.baseCodePath);
+            final Package pkg = parseBaseApk(baseApk, assets, flags);
+            if (pkg == null) {
+                throw new PackageParserException(INSTALL_PARSE_FAILED_NOT_APK,
+                        "Failed to parse base APK: " + baseApk);
+            }
+
+            if (!ArrayUtils.isEmpty(lite.splitNames)) {
+                final int num = lite.splitNames.length;
+                pkg.splitNames = lite.splitNames;
+                pkg.splitCodePaths = lite.splitCodePaths;
+                pkg.splitFlags = new int[num];
+
+                for (int i = 0; i < num; i++) {
+                    parseSplitApk(pkg, i, assets, flags);
+                }
+            }
+
+            pkg.codePath = packageDir.getAbsolutePath();
+            return pkg;
+        } finally {
+            IoUtils.closeQuietly(assets);
+        }
     }
 
     /**
@@ -797,35 +816,48 @@
             }
         }
 
-        final Package pkg = parseBaseApk(apkFile, flags);
-        pkg.codePath = apkFile.getAbsolutePath();
-        return pkg;
+        final AssetManager assets = new AssetManager();
+        try {
+            final Package pkg = parseBaseApk(apkFile, assets, flags);
+            pkg.codePath = apkFile.getAbsolutePath();
+            return pkg;
+        } finally {
+            IoUtils.closeQuietly(assets);
+        }
     }
 
-    private Package parseBaseApk(File apkFile, int flags) throws PackageParserException {
+    private static int loadApkIntoAssetManager(AssetManager assets, String apkPath, int flags)
+            throws PackageParserException {
+        if ((flags & PARSE_MUST_BE_APK) != 0 && !isApkPath(apkPath)) {
+            throw new PackageParserException(INSTALL_PARSE_FAILED_NOT_APK,
+                    "Invalid package file: " + apkPath);
+        }
+
+        // The AssetManager guarantees uniqueness for asset paths, so if this asset path
+        // already exists in the AssetManager, addAssetPath will only return the cookie
+        // assigned to it.
+        int cookie = assets.addAssetPath(apkPath);
+        if (cookie == 0) {
+            throw new PackageParserException(INSTALL_PARSE_FAILED_BAD_MANIFEST,
+                    "Failed adding asset path: " + apkPath);
+        }
+        return cookie;
+    }
+
+    private Package parseBaseApk(File apkFile, AssetManager assets, int flags)
+            throws PackageParserException {
         final String apkPath = apkFile.getAbsolutePath();
 
         mParseError = PackageManager.INSTALL_SUCCEEDED;
         mArchiveSourcePath = apkFile.getAbsolutePath();
 
-        if ((flags & PARSE_MUST_BE_APK) != 0 && !isApkFile(apkFile)) {
-            throw new PackageParserException(INSTALL_PARSE_FAILED_NOT_APK,
-                    "Invalid package file: " + apkPath);
-        }
-
         if (DEBUG_JAR) Slog.d(TAG, "Scanning base APK: " + apkPath);
 
-        AssetManager assets = null;
+        final int cookie = loadApkIntoAssetManager(assets, apkPath, flags);
+
         Resources res = null;
         XmlResourceParser parser = null;
         try {
-            assets = new AssetManager();
-            int cookie = assets.addAssetPath(apkPath);
-            if (cookie == 0) {
-                throw new PackageParserException(INSTALL_PARSE_FAILED_BAD_MANIFEST,
-                        "Failed adding asset path: " + apkPath);
-            }
-
             res = new Resources(assets, mMetrics, null);
             assets.setConfiguration(0, 0, null, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
                     Build.VERSION.RESOURCES_SDK_INT);
@@ -850,11 +882,10 @@
                     "Failed to read manifest from " + apkPath, e);
         } finally {
             IoUtils.closeQuietly(parser);
-            IoUtils.closeQuietly(assets);
         }
     }
 
-    private void parseSplitApk(Package pkg, int splitIndex, int flags)
+    private void parseSplitApk(Package pkg, int splitIndex, AssetManager assets, int flags)
             throws PackageParserException {
         final String apkPath = pkg.splitCodePaths[splitIndex];
         final File apkFile = new File(apkPath);
@@ -862,24 +893,13 @@
         mParseError = PackageManager.INSTALL_SUCCEEDED;
         mArchiveSourcePath = apkPath;
 
-        if ((flags & PARSE_MUST_BE_APK) != 0 && !isApkFile(apkFile)) {
-            throw new PackageParserException(INSTALL_PARSE_FAILED_NOT_APK,
-                    "Invalid package file: " + apkPath);
-        }
-
         if (DEBUG_JAR) Slog.d(TAG, "Scanning split APK: " + apkPath);
 
-        AssetManager assets = null;
+        final int cookie = loadApkIntoAssetManager(assets, apkPath, flags);
+
         Resources res = null;
         XmlResourceParser parser = null;
         try {
-            assets = new AssetManager();
-            int cookie = assets.addAssetPath(apkPath);
-            if (cookie == 0) {
-                throw new PackageParserException(INSTALL_PARSE_FAILED_BAD_MANIFEST,
-                        "Failed adding asset path: " + apkPath);
-            }
-
             res = new Resources(assets, mMetrics, null);
             assets.setConfiguration(0, 0, null, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
                     Build.VERSION.RESOURCES_SDK_INT);
@@ -899,7 +919,6 @@
                     "Failed to read manifest from " + apkPath, e);
         } finally {
             IoUtils.closeQuietly(parser);
-            IoUtils.closeQuietly(assets);
         }
     }
 
@@ -1080,42 +1099,17 @@
                     }
                 }
             }
-        } catch (GeneralSecurityException | IOException | RuntimeException e) {
+        } catch (GeneralSecurityException e) {
             throw new PackageParserException(INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING,
                     "Failed to collect certificates from " + apkPath, e);
+        } catch (IOException | RuntimeException e) {
+            throw new PackageParserException(INSTALL_PARSE_FAILED_NO_CERTIFICATES,
+                    "Failed to collect certificates from " + apkPath, e);
         } finally {
             closeQuietly(jarFile);
         }
     }
 
-    /**
-     * Only collect certificates on the manifest; does not validate signatures
-     * across remainder of package.
-     */
-    private static Signature[] collectManifestCertificates(File apkFile)
-            throws PackageParserException {
-        final String apkPath = apkFile.getAbsolutePath();
-        try {
-            final StrictJarFile jarFile = new StrictJarFile(apkPath);
-            try {
-                final ZipEntry jarEntry = jarFile.findEntry(ANDROID_MANIFEST_FILENAME);
-                if (jarEntry == null) {
-                    throw new PackageParserException(INSTALL_PARSE_FAILED_MANIFEST_MALFORMED,
-                            "Package " + apkPath + " has no manifest");
-                }
-
-                final Certificate[][] certs = loadCertificates(jarFile, jarEntry);
-                return convertToSignatures(certs);
-
-            } finally {
-                jarFile.close();
-            }
-        } catch (GeneralSecurityException | IOException | RuntimeException e) {
-            throw new PackageParserException(INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING,
-                    "Failed to collect certificates from " + apkPath, e);
-        }
-    }
-
     private static Signature[] convertToSignatures(Certificate[][] certs)
             throws CertificateEncodingException {
         final Signature[] res = new Signature[certs.length];
@@ -1130,7 +1124,8 @@
      * file, including package name, split name, and install location.
      *
      * @param apkFile path to a single APK
-     * @param flags optional parse flags, such as {@link #PARSE_GET_SIGNATURES}
+     * @param flags optional parse flags, such as
+     *            {@link #PARSE_COLLECT_CERTIFICATES}
      */
     public static ApkLite parseApkLite(File apkFile, int flags)
             throws PackageParserException {
@@ -1155,11 +1150,12 @@
             final Resources res = new Resources(assets, metrics, null);
             parser = assets.openXmlResourceParser(cookie, ANDROID_MANIFEST_FILENAME);
 
-            // Only collect certificates on the manifest; does not validate
-            // signatures across remainder of package.
             final Signature[] signatures;
-            if ((flags & PARSE_GET_SIGNATURES) != 0) {
-                signatures = collectManifestCertificates(apkFile);
+            if ((flags & PARSE_COLLECT_CERTIFICATES) != 0) {
+                // TODO: factor signature related items out of Package object
+                final Package tempPkg = new Package(null);
+                collectCertificates(tempPkg, apkFile, 0);
+                signatures = tempPkg.mSignatures;
             } else {
                 signatures = null;
             }
@@ -2477,8 +2473,6 @@
                 false)) {
             owner.mRequiredForAllUsers = true;
         }
-        owner.mRequiredForProfile = sa.getInt(
-                com.android.internal.R.styleable.AndroidManifestApplication_requiredForProfile, 0);
 
         String restrictedAccountType = sa.getString(com.android.internal.R.styleable
                 .AndroidManifestApplication_restrictedAccountType);
@@ -3087,7 +3081,7 @@
                     ActivityInfo.DOCUMENT_LAUNCH_NONE);
             a.info.maxRecents = sa.getInt(
                     com.android.internal.R.styleable.AndroidManifestActivity_maxRecents,
-                    15);
+                    ActivityManager.getDefaultAppRecentsLimitStatic());
             a.info.screenOrientation = sa.getInt(
                     com.android.internal.R.styleable.AndroidManifestActivity_screenOrientation,
                     ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED);
@@ -3119,6 +3113,12 @@
                     false)) {
                 a.info.flags |= ActivityInfo.FLAG_RELINQUISH_TASK_IDENTITY;
             }
+
+            if (sa.getBoolean(
+                    com.android.internal.R.styleable.AndroidManifestActivity_resumeWhilePausing,
+                    false)) {
+                a.info.flags |= ActivityInfo.FLAG_RESUME_WHILE_PAUSING;
+            }
         } else {
             a.info.launchMode = ActivityInfo.LAUNCH_MULTIPLE;
             a.info.configChanges = 0;
@@ -3308,7 +3308,8 @@
         info.softInputMode = target.info.softInputMode;
         info.uiOptions = target.info.uiOptions;
         info.parentActivityName = target.info.parentActivityName;
-        
+        info.maxRecents = target.info.maxRecents;
+
         Activity a = new Activity(mParseActivityAliasArgs, info);
         if (outError[0] != null) {
             sa.recycle();
@@ -4269,9 +4270,6 @@
         /* An app that's required for all users and cannot be uninstalled for a user */
         public boolean mRequiredForAllUsers;
 
-        /* For which types of profile this app is required */
-        public int mRequiredForProfile;
-
         /* The restricted account authenticator type that is used by this application */
         public String mRestrictedAccountType;
 
diff --git a/core/java/android/content/pm/UserInfo.java b/core/java/android/content/pm/UserInfo.java
index c0383a3..c03be32 100644
--- a/core/java/android/content/pm/UserInfo.java
+++ b/core/java/android/content/pm/UserInfo.java
@@ -89,6 +89,7 @@
 
     /** User is only partially created. */
     public boolean partial;
+    public boolean guestToRemove;
 
     public UserInfo(int id, String name, int flags) {
         this(id, name, null, flags);
@@ -147,6 +148,7 @@
         lastLoggedInTime = orig.lastLoggedInTime;
         partial = orig.partial;
         profileGroupId = orig.profileGroupId;
+        guestToRemove = orig.guestToRemove;
     }
 
     public UserHandle getUserHandle() {
@@ -172,6 +174,7 @@
         dest.writeLong(lastLoggedInTime);
         dest.writeInt(partial ? 1 : 0);
         dest.writeInt(profileGroupId);
+        dest.writeInt(guestToRemove ? 1 : 0);
     }
 
     public static final Parcelable.Creator<UserInfo> CREATOR
@@ -194,5 +197,6 @@
         lastLoggedInTime = source.readLong();
         partial = source.readInt() != 0;
         profileGroupId = source.readInt();
+        guestToRemove = source.readInt() != 0;
     }
 }
diff --git a/core/java/android/content/res/Configuration.java b/core/java/android/content/res/Configuration.java
index a83bd4a..27bbb24 100644
--- a/core/java/android/content/res/Configuration.java
+++ b/core/java/android/content/res/Configuration.java
@@ -16,6 +16,12 @@
 
 package android.content.res;
 
+import com.android.internal.util.XmlUtils;
+
+import org.xmlpull.v1.XmlPullParser;
+import org.xmlpull.v1.XmlPullParserException;
+import org.xmlpull.v1.XmlSerializer;
+
 import android.content.pm.ActivityInfo;
 import android.os.Build;
 import android.os.Parcel;
@@ -23,7 +29,7 @@
 import android.text.TextUtils;
 import android.view.View;
 
-import java.text.Format;
+import java.io.IOException;
 import java.util.ArrayList;
 import java.util.Locale;
 
@@ -533,6 +539,18 @@
     public static final int DENSITY_DPI_UNDEFINED = 0;
 
     /**
+     * Value for {@link #densityDpi} for resources that scale to any density (vector drawables).
+     * {@hide}
+     */
+    public static final int DENSITY_DPI_ANY = 0xfffe;
+
+    /**
+     * Value for {@link #densityDpi} for resources that are not meant to be scaled.
+     * {@hide}
+     */
+    public static final int DENSITY_DPI_NONE = 0xffff;
+
+    /**
      * The target screen density being rendered to,
      * corresponding to
      * <a href="{@docRoot}guide/topics/resources/providing-resources.html#DensityQualifier">density</a>
@@ -1341,8 +1359,6 @@
      * Returns a string representation of the configuration that can be parsed
      * by build tools (like AAPT).
      *
-     *
-     *
      * @hide
      */
     public static String resourceQualifierString(Configuration config) {
@@ -1453,7 +1469,7 @@
         }
 
         switch (config.densityDpi) {
-            case 0:
+            case DENSITY_DPI_UNDEFINED:
                 break;
             case 120:
                 parts.add("ldpi");
@@ -1470,6 +1486,17 @@
             case 320:
                 parts.add("xhdpi");
                 break;
+            case 480:
+                parts.add("xxhdpi");
+                break;
+            case 640:
+                parts.add("xxxhdpi");
+                break;
+            case DENSITY_DPI_ANY:
+                parts.add("anydpi");
+                break;
+            case DENSITY_DPI_NONE:
+                parts.add("nodpi");
             default:
                 parts.add(config.densityDpi + "dpi");
                 break;
@@ -1542,7 +1569,232 @@
                 break;
         }
 
-        parts.add("v" + Build.VERSION.SDK_INT);
+        parts.add("v" + Build.VERSION.RESOURCES_SDK_INT);
         return TextUtils.join("-", parts);
     }
+
+    /**
+     * Generate a delta Configuration between <code>base</code> and <code>change</code>. The
+     * resulting delta can be used with {@link #updateFrom(Configuration)}.
+     * <p />
+     * Caveat: If the any of the Configuration's members becomes undefined, then
+     * {@link #updateFrom(Configuration)} will treat it as a no-op and not update that member.
+     *
+     * This is fine for device configurations as no member is ever undefined.
+     * {@hide}
+     */
+    public static Configuration generateDelta(Configuration base, Configuration change) {
+        final Configuration delta = new Configuration();
+        if (base.fontScale != change.fontScale) {
+            delta.fontScale = change.fontScale;
+        }
+
+        if (base.mcc != change.mcc) {
+            delta.mcc = change.mcc;
+        }
+
+        if (base.mnc != change.mnc) {
+            delta.mnc = change.mnc;
+        }
+
+        if ((base.locale == null && change.locale != null) ||
+                (base.locale != null && !base.locale.equals(change.locale)))  {
+            delta.locale = change.locale;
+        }
+
+        if (base.touchscreen != change.touchscreen) {
+            delta.touchscreen = change.touchscreen;
+        }
+
+        if (base.keyboard != change.keyboard) {
+            delta.keyboard = change.keyboard;
+        }
+
+        if (base.keyboardHidden != change.keyboardHidden) {
+            delta.keyboardHidden = change.keyboardHidden;
+        }
+
+        if (base.navigation != change.navigation) {
+            delta.navigation = change.navigation;
+        }
+
+        if (base.navigationHidden != change.navigationHidden) {
+            delta.navigationHidden = change.navigationHidden;
+        }
+
+        if (base.orientation != change.orientation) {
+            delta.orientation = change.orientation;
+        }
+
+        if ((base.screenLayout & SCREENLAYOUT_SIZE_MASK) !=
+                (change.screenLayout & SCREENLAYOUT_SIZE_MASK)) {
+            delta.screenLayout |= change.screenLayout & SCREENLAYOUT_SIZE_MASK;
+        }
+
+        if ((base.screenLayout & SCREENLAYOUT_LAYOUTDIR_MASK) !=
+                (change.screenLayout & SCREENLAYOUT_LAYOUTDIR_MASK)) {
+            delta.screenLayout |= change.screenLayout & SCREENLAYOUT_LAYOUTDIR_MASK;
+        }
+
+        if ((base.screenLayout & SCREENLAYOUT_LONG_MASK) !=
+                (change.screenLayout & SCREENLAYOUT_LONG_MASK)) {
+            delta.screenLayout |= change.screenLayout & SCREENLAYOUT_LONG_MASK;
+        }
+
+        if ((base.uiMode & UI_MODE_TYPE_MASK) != (change.uiMode & UI_MODE_TYPE_MASK)) {
+            delta.uiMode |= change.uiMode & UI_MODE_TYPE_MASK;
+        }
+
+        if ((base.uiMode & UI_MODE_NIGHT_MASK) != (change.uiMode & UI_MODE_NIGHT_MASK)) {
+            delta.uiMode |= change.uiMode & UI_MODE_NIGHT_MASK;
+        }
+
+        if (base.screenWidthDp != change.screenWidthDp) {
+            delta.screenWidthDp = change.screenWidthDp;
+        }
+
+        if (base.screenHeightDp != change.screenHeightDp) {
+            delta.screenHeightDp = change.screenHeightDp;
+        }
+
+        if (base.smallestScreenWidthDp != change.smallestScreenWidthDp) {
+            delta.smallestScreenWidthDp = change.smallestScreenWidthDp;
+        }
+
+        if (base.densityDpi != change.densityDpi) {
+            delta.densityDpi = change.densityDpi;
+        }
+        return delta;
+    }
+
+    private static final String XML_ATTR_FONT_SCALE = "fs";
+    private static final String XML_ATTR_MCC = "mcc";
+    private static final String XML_ATTR_MNC = "mnc";
+    private static final String XML_ATTR_LOCALE = "locale";
+    private static final String XML_ATTR_TOUCHSCREEN = "touch";
+    private static final String XML_ATTR_KEYBOARD = "key";
+    private static final String XML_ATTR_KEYBOARD_HIDDEN = "keyHid";
+    private static final String XML_ATTR_HARD_KEYBOARD_HIDDEN = "hardKeyHid";
+    private static final String XML_ATTR_NAVIGATION = "nav";
+    private static final String XML_ATTR_NAVIGATION_HIDDEN = "navHid";
+    private static final String XML_ATTR_ORIENTATION = "ori";
+    private static final String XML_ATTR_SCREEN_LAYOUT = "scrLay";
+    private static final String XML_ATTR_UI_MODE = "ui";
+    private static final String XML_ATTR_SCREEN_WIDTH = "width";
+    private static final String XML_ATTR_SCREEN_HEIGHT = "height";
+    private static final String XML_ATTR_SMALLEST_WIDTH = "sw";
+    private static final String XML_ATTR_DENSITY = "density";
+
+    /**
+     * Reads the attributes corresponding to Configuration member fields from the Xml parser.
+     * The parser is expected to be on a tag which has Configuration attributes.
+     *
+     * @param parser The Xml parser from which to read attributes.
+     * @param configOut The Configuration to populate from the Xml attributes.
+     * {@hide}
+     */
+    public static void readXmlAttrs(XmlPullParser parser, Configuration configOut)
+            throws XmlPullParserException, IOException {
+        configOut.fontScale = Float.intBitsToFloat(
+                XmlUtils.readIntAttribute(parser, XML_ATTR_FONT_SCALE, 0));
+        configOut.mcc = XmlUtils.readIntAttribute(parser, XML_ATTR_MCC, 0);
+        configOut.mnc = XmlUtils.readIntAttribute(parser, XML_ATTR_MNC, 0);
+
+        final String localeStr = XmlUtils.readStringAttribute(parser, XML_ATTR_LOCALE);
+        if (localeStr != null) {
+            configOut.locale = Locale.forLanguageTag(localeStr);
+        }
+
+        configOut.touchscreen = XmlUtils.readIntAttribute(parser, XML_ATTR_TOUCHSCREEN,
+                TOUCHSCREEN_UNDEFINED);
+        configOut.keyboard = XmlUtils.readIntAttribute(parser, XML_ATTR_KEYBOARD,
+                KEYBOARD_UNDEFINED);
+        configOut.keyboardHidden = XmlUtils.readIntAttribute(parser, XML_ATTR_KEYBOARD_HIDDEN,
+                KEYBOARDHIDDEN_UNDEFINED);
+        configOut.hardKeyboardHidden =
+                XmlUtils.readIntAttribute(parser, XML_ATTR_HARD_KEYBOARD_HIDDEN,
+                        HARDKEYBOARDHIDDEN_UNDEFINED);
+        configOut.navigation = XmlUtils.readIntAttribute(parser, XML_ATTR_NAVIGATION,
+                NAVIGATION_UNDEFINED);
+        configOut.navigationHidden = XmlUtils.readIntAttribute(parser, XML_ATTR_NAVIGATION_HIDDEN,
+                NAVIGATIONHIDDEN_UNDEFINED);
+        configOut.orientation = XmlUtils.readIntAttribute(parser, XML_ATTR_ORIENTATION,
+                ORIENTATION_UNDEFINED);
+        configOut.screenLayout = XmlUtils.readIntAttribute(parser, XML_ATTR_SCREEN_LAYOUT,
+                SCREENLAYOUT_UNDEFINED);
+        configOut.uiMode = XmlUtils.readIntAttribute(parser, XML_ATTR_UI_MODE, 0);
+        configOut.screenWidthDp = XmlUtils.readIntAttribute(parser, XML_ATTR_SCREEN_WIDTH,
+                SCREEN_WIDTH_DP_UNDEFINED);
+        configOut.screenHeightDp = XmlUtils.readIntAttribute(parser, XML_ATTR_SCREEN_HEIGHT,
+                SCREEN_HEIGHT_DP_UNDEFINED);
+        configOut.smallestScreenWidthDp =
+                XmlUtils.readIntAttribute(parser, XML_ATTR_SMALLEST_WIDTH,
+                        SMALLEST_SCREEN_WIDTH_DP_UNDEFINED);
+        configOut.densityDpi = XmlUtils.readIntAttribute(parser, XML_ATTR_DENSITY,
+                DENSITY_DPI_UNDEFINED);
+    }
+
+
+    /**
+     * Writes the Configuration's member fields as attributes into the XmlSerializer.
+     * The serializer is expected to have already started a tag so that attributes can be
+     * immediately written.
+     *
+     * @param xml The serializer to which to write the attributes.
+     * @param config The Configuration whose member fields to write.
+     * {@hide}
+     */
+    public static void writeXmlAttrs(XmlSerializer xml, Configuration config) throws IOException {
+        XmlUtils.writeIntAttribute(xml, XML_ATTR_FONT_SCALE,
+                Float.floatToIntBits(config.fontScale));
+        if (config.mcc != 0) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_MCC, config.mcc);
+        }
+        if (config.mnc != 0) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_MNC, config.mnc);
+        }
+        if (config.locale != null) {
+            XmlUtils.writeStringAttribute(xml, XML_ATTR_LOCALE, config.locale.toLanguageTag());
+        }
+        if (config.touchscreen != TOUCHSCREEN_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_TOUCHSCREEN, config.touchscreen);
+        }
+        if (config.keyboard != KEYBOARD_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_KEYBOARD, config.keyboard);
+        }
+        if (config.keyboardHidden != KEYBOARDHIDDEN_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_KEYBOARD_HIDDEN, config.keyboardHidden);
+        }
+        if (config.hardKeyboardHidden != HARDKEYBOARDHIDDEN_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_HARD_KEYBOARD_HIDDEN,
+                    config.hardKeyboardHidden);
+        }
+        if (config.navigation != NAVIGATION_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_NAVIGATION, config.navigation);
+        }
+        if (config.navigationHidden != NAVIGATIONHIDDEN_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_NAVIGATION_HIDDEN, config.navigationHidden);
+        }
+        if (config.orientation != ORIENTATION_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_ORIENTATION, config.orientation);
+        }
+        if (config.screenLayout != SCREENLAYOUT_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_SCREEN_LAYOUT, config.screenLayout);
+        }
+        if (config.uiMode != 0) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_UI_MODE, config.uiMode);
+        }
+        if (config.screenWidthDp != SCREEN_WIDTH_DP_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_SCREEN_WIDTH, config.screenWidthDp);
+        }
+        if (config.screenHeightDp != SCREEN_HEIGHT_DP_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_SCREEN_HEIGHT, config.screenHeightDp);
+        }
+        if (config.smallestScreenWidthDp != SMALLEST_SCREEN_WIDTH_DP_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_SMALLEST_WIDTH, config.smallestScreenWidthDp);
+        }
+        if (config.densityDpi != DENSITY_DPI_UNDEFINED) {
+            XmlUtils.writeIntAttribute(xml, XML_ATTR_DENSITY, config.densityDpi);
+        }
+    }
 }
diff --git a/core/java/android/content/res/Resources.java b/core/java/android/content/res/Resources.java
index cabe228..7f276c2 100644
--- a/core/java/android/content/res/Resources.java
+++ b/core/java/android/content/res/Resources.java
@@ -16,6 +16,7 @@
 
 package android.content.res;
 
+import android.util.Pools.SynchronizedPool;
 import android.view.ViewDebug;
 import com.android.internal.util.XmlUtils;
 
@@ -96,6 +97,9 @@
     private static final LongSparseArray<ColorStateList> sPreloadedColorStateLists
             = new LongSparseArray<ColorStateList>();
 
+    // Pool of TypedArrays targeted to this Resources object.
+    final SynchronizedPool<TypedArray> mTypedArrayPool = new SynchronizedPool<TypedArray>(5);
+
     // Used by BridgeResources in layoutlib
     static Resources mSystem = null;
 
@@ -121,9 +125,10 @@
     private final int[] mCachedXmlBlockIds = { 0, 0, 0, 0 };
     private final XmlBlock[] mCachedXmlBlocks = new XmlBlock[4];
 
-    private final AssetManager mAssets;
+    final AssetManager mAssets;
+    final DisplayMetrics mMetrics = new DisplayMetrics();
+
     private final Configuration mConfiguration = new Configuration();
-    private final DisplayMetrics mMetrics = new DisplayMetrics();
     private NativePluralRules mPluralRule;
 
     private CompatibilityInfo mCompatibilityInfo = CompatibilityInfo.DEFAULT_COMPATIBILITY_INFO;
diff --git a/core/java/android/content/res/ResourcesKey.java b/core/java/android/content/res/ResourcesKey.java
index 53e0f2c..e0f1b3a 100644
--- a/core/java/android/content/res/ResourcesKey.java
+++ b/core/java/android/content/res/ResourcesKey.java
@@ -62,8 +62,12 @@
             return false;
         }
         ResourcesKey peer = (ResourcesKey) obj;
-        if (!mResDir.equals(peer.mResDir)) {
-            return false;
+        if (mResDir != peer.mResDir) {
+            if (mResDir == null || peer.mResDir == null) {
+                return false;
+            } else if (!mResDir.equals(peer.mResDir)) {
+                return false;
+            }
         }
         if (mDisplayId != peer.mDisplayId) {
             return false;
diff --git a/core/java/android/content/res/TypedArray.java b/core/java/android/content/res/TypedArray.java
index 8607bbc..186623a 100644
--- a/core/java/android/content/res/TypedArray.java
+++ b/core/java/android/content/res/TypedArray.java
@@ -20,7 +20,6 @@
 import android.util.AttributeSet;
 import android.util.DisplayMetrics;
 import android.util.Log;
-import android.util.Pools.SynchronizedPool;
 import android.util.TypedValue;
 
 import com.android.internal.util.XmlUtils;
@@ -37,15 +36,11 @@
  * the positions of the attributes given to obtainStyledAttributes.
  */
 public class TypedArray {
-    private static final SynchronizedPool<TypedArray> mPool = new SynchronizedPool<TypedArray>(5);
 
     static TypedArray obtain(Resources res, int len) {
-        final TypedArray attrs = mPool.acquire();
+        final TypedArray attrs = res.mTypedArrayPool.acquire();
         if (attrs != null) {
             attrs.mLength = len;
-            attrs.mResources = res;
-            attrs.mMetrics = res.getDisplayMetrics();
-            attrs.mAssets = res.getAssets();
             attrs.mRecycled = false;
 
             final int fullLen = len * AssetManager.STYLE_NUM_ENTRIES;
@@ -63,9 +58,10 @@
                 new int[1+len], len);
     }
 
-    private Resources mResources;
-    private DisplayMetrics mMetrics;
-    private AssetManager mAssets;
+    private final Resources mResources;
+    private final DisplayMetrics mMetrics;
+    private final AssetManager mAssets;
+
     private boolean mRecycled;
 
     /*package*/ XmlBlock.Parser mXml;
@@ -872,17 +868,12 @@
         }
 
         mRecycled = true;
-        mResources = null;
-        mMetrics = null;
-        mAssets = null;
 
         // These may have been set by the client.
         mXml = null;
         mTheme = null;
 
-        synchronized (mPool) {
-            mPool.release(this);
-        }
+        mResources.mTypedArrayPool.release(this);
     }
 
     /**
@@ -984,8 +975,8 @@
 
     /*package*/ TypedArray(Resources resources, int[] data, int[] indices, int len) {
         mResources = resources;
-        mMetrics = mResources.getDisplayMetrics();
-        mAssets = mResources.getAssets();
+        mMetrics = mResources.mMetrics;
+        mAssets = mResources.mAssets;
         mData = data;
         mIndices = indices;
         mLength = len;
diff --git a/core/java/android/database/ContentObserver.java b/core/java/android/database/ContentObserver.java
index e4fbc28..5f01e30 100644
--- a/core/java/android/database/ContentObserver.java
+++ b/core/java/android/database/ContentObserver.java
@@ -18,6 +18,7 @@
 
 import android.net.Uri;
 import android.os.Handler;
+import android.os.UserHandle;
 
 /**
  * Receives call backs for changes to content.
@@ -130,6 +131,21 @@
     }
 
     /**
+     * Dispatches a change notification to the observer. Includes the changed
+     * content Uri when available and also the user whose content changed.
+     *
+     * @param selfChange True if this is a self-change notification.
+     * @param uri The Uri of the changed content, or null if unknown.
+     * @param userId The user whose content changed. Can be either a specific
+     *         user or {@link UserHandle#USER_ALL}.
+     *
+     * @hide
+     */
+    public void onChange(boolean selfChange, Uri uri, int userId) {
+        onChange(selfChange, uri);
+    }
+
+    /**
      * Dispatches a change notification to the observer.
      * <p>
      * If a {@link Handler} was supplied to the {@link ContentObserver} constructor,
@@ -159,25 +175,45 @@
      * @param uri The Uri of the changed content, or null if unknown.
      */
     public final void dispatchChange(boolean selfChange, Uri uri) {
+        dispatchChange(selfChange, uri, UserHandle.getCallingUserId());
+    }
+
+    /**
+     * Dispatches a change notification to the observer. Includes the changed
+     * content Uri when available and also the user whose content changed.
+     * <p>
+     * If a {@link Handler} was supplied to the {@link ContentObserver} constructor,
+     * then a call to the {@link #onChange} method is posted to the handler's message queue.
+     * Otherwise, the {@link #onChange} method is invoked immediately on this thread.
+     * </p>
+     *
+     * @param selfChange True if this is a self-change notification.
+     * @param uri The Uri of the changed content, or null if unknown.
+     * @param userId The user whose content changed.
+     */
+    private void dispatchChange(boolean selfChange, Uri uri, int userId) {
         if (mHandler == null) {
-            onChange(selfChange, uri);
+            onChange(selfChange, uri, userId);
         } else {
-            mHandler.post(new NotificationRunnable(selfChange, uri));
+            mHandler.post(new NotificationRunnable(selfChange, uri, userId));
         }
     }
 
+
     private final class NotificationRunnable implements Runnable {
         private final boolean mSelfChange;
         private final Uri mUri;
+        private final int mUserId;
 
-        public NotificationRunnable(boolean selfChange, Uri uri) {
+        public NotificationRunnable(boolean selfChange, Uri uri, int userId) {
             mSelfChange = selfChange;
             mUri = uri;
+            mUserId = userId;
         }
 
         @Override
         public void run() {
-            ContentObserver.this.onChange(mSelfChange, mUri);
+            ContentObserver.this.onChange(mSelfChange, mUri, mUserId);
         }
     }
 
@@ -189,10 +225,10 @@
         }
 
         @Override
-        public void onChange(boolean selfChange, Uri uri) {
+        public void onChange(boolean selfChange, Uri uri, int userId) {
             ContentObserver contentObserver = mContentObserver;
             if (contentObserver != null) {
-                contentObserver.dispatchChange(selfChange, uri);
+                contentObserver.dispatchChange(selfChange, uri, userId);
             }
         }
 
diff --git a/core/java/android/database/CursorToBulkCursorAdaptor.java b/core/java/android/database/CursorToBulkCursorAdaptor.java
index 7dcfae2..02eddf2 100644
--- a/core/java/android/database/CursorToBulkCursorAdaptor.java
+++ b/core/java/android/database/CursorToBulkCursorAdaptor.java
@@ -17,9 +17,7 @@
 package android.database;
 
 import android.net.Uri;
-import android.os.Bundle;
-import android.os.IBinder;
-import android.os.RemoteException;
+import android.os.*;
 
 
 /**
@@ -33,7 +31,7 @@
  *
  * {@hide}
  */
-public final class CursorToBulkCursorAdaptor extends BulkCursorNative 
+public final class CursorToBulkCursorAdaptor extends BulkCursorNative
         implements IBinder.DeathRecipient {
     private static final String TAG = "Cursor";
 
@@ -66,7 +64,7 @@
                 // Do nothing, the far side is dead
             }
         }
-        
+
         public boolean unlinkToDeath(DeathRecipient recipient) {
             return mRemote.asBinder().unlinkToDeath(recipient, 0);
         }
@@ -80,7 +78,7 @@
         @Override
         public void onChange(boolean selfChange, Uri uri) {
             try {
-                mRemote.onChange(selfChange, uri);
+                mRemote.onChange(selfChange, uri, android.os.Process.myUid());
             } catch (RemoteException ex) {
                 // Do nothing, the far side is dead
             }
diff --git a/core/java/android/database/IContentObserver.aidl b/core/java/android/database/IContentObserver.aidl
index 13aff05..22dc9fe 100644
--- a/core/java/android/database/IContentObserver.aidl
+++ b/core/java/android/database/IContentObserver.aidl
@@ -2,16 +2,16 @@
 **
 ** Copyright 2007, 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 
+** 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 
+**     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 
+** 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.
 */
 
@@ -29,5 +29,5 @@
      * observed. selfUpdate is true if the update was caused by a call to
      * commit on the cursor that is being observed.
      */
-    oneway void onChange(boolean selfUpdate, in Uri uri);
+    oneway void onChange(boolean selfUpdate, in Uri uri, int userId);
 }
diff --git a/core/java/android/hardware/Camera.java b/core/java/android/hardware/Camera.java
index eadfa73..310ab76 100644
--- a/core/java/android/hardware/Camera.java
+++ b/core/java/android/hardware/Camera.java
@@ -1558,6 +1558,26 @@
         return _enableShutterSound(enabled);
     }
 
+    /**
+     * Disable the shutter sound unconditionally.
+     *
+     * <p>
+     * This is only guaranteed to work for legacy cameras
+     * (i.e. initialized with {@link #cameraInitUnspecified}). Trying to call this on
+     * a regular camera will force a conditional check in the camera service.
+     * </p>
+     *
+     * @return {@code true} if the shutter sound state was successfully
+     *         changed. {@code false} if the shutter sound state could not be
+     *         changed. {@code true} is also returned if shutter sound playback
+     *         is already set to the requested state.
+     *
+     * @hide
+     */
+    public final boolean disableShutterSound() {
+        return _enableShutterSound(/*enabled*/false);
+    }
+
     private native final boolean _enableShutterSound(boolean enabled);
 
     /**
diff --git a/core/java/android/hardware/Sensor.java b/core/java/android/hardware/Sensor.java
index d60a2c2..f514e42 100644
--- a/core/java/android/hardware/Sensor.java
+++ b/core/java/android/hardware/Sensor.java
@@ -348,7 +348,7 @@
      * A sensor of this type returns the number of steps taken by the user since the last reboot
      * while activated. The value is returned as a float (with the fractional part set to zero) and
      * is reset to zero only on a system reboot. The timestamp of the event is set to the time when
-     * the first step for that event was taken. This sensor is implemented in hardware and is
+     * the last step for that event was taken. This sensor is implemented in hardware and is
      * expected to be low power.
      * <p>
      * See {@link android.hardware.SensorEvent#values SensorEvent.values} for more details.
@@ -737,12 +737,11 @@
     }
 
     /**
-     * This value is defined only for continuous mode sensors. It is the delay between two
-     * sensor events corresponding to the lowest frequency that this sensor supports. When
-     * lower frequencies are requested through registerListener() the events will be generated
-     * at this frequency instead. It can be used to estimate when the batch FIFO may be full.
-     * Older devices may set this value to zero. Ignore this value in case it is negative
-     * or zero.
+     * This value is defined only for continuous and on-change sensors. It is the delay between two
+     * sensor events corresponding to the lowest frequency that this sensor supports. When lower
+     * frequencies are requested through registerListener() the events will be generated at this
+     * frequency instead. It can be used to estimate when the batch FIFO may be full. Older devices
+     * may set this value to zero. Ignore this value in case it is negative or zero.
      *
      * @return The max delay for this sensor in microseconds.
      */
diff --git a/core/java/android/hardware/camera2/CameraAccessException.java b/core/java/android/hardware/camera2/CameraAccessException.java
index ca71e81..91ef6ca 100644
--- a/core/java/android/hardware/camera2/CameraAccessException.java
+++ b/core/java/android/hardware/camera2/CameraAccessException.java
@@ -61,7 +61,7 @@
      *
      * <p>The camera has failed to open or has failed at a later time
      * as a result of some non-user interaction. Refer to
-     * {@link CameraDevice.StateListener#onError} for the exact
+     * {@link CameraDevice.StateCallback#onError} for the exact
      * nature of the error.</p>
      *
      * <p>No further calls to the camera will succeed. Clean up
diff --git a/core/java/android/hardware/camera2/CameraCaptureSession.java b/core/java/android/hardware/camera2/CameraCaptureSession.java
index fc2141f..ce83028 100644
--- a/core/java/android/hardware/camera2/CameraCaptureSession.java
+++ b/core/java/android/hardware/camera2/CameraCaptureSession.java
@@ -32,18 +32,18 @@
  * sending images to the desired targets. Therefore the setup is done asynchronously, and
  * {@link CameraDevice#createCaptureSession createCaptureSession} will send the ready-to-use
  * CameraCaptureSession to the provided listener's
- * {@link CameraCaptureSession.StateListener#onConfigured onConfigured} callback. If configuration
+ * {@link CameraCaptureSession.StateCallback#onConfigured onConfigured} callback. If configuration
  * cannot be completed, then the
- * {@link CameraCaptureSession.StateListener#onConfigureFailed onConfigureFailed} is called, and the
+ * {@link CameraCaptureSession.StateCallback#onConfigureFailed onConfigureFailed} is called, and the
  * session will not become active.</p>
  *<!--
  * <p>Any capture requests (repeating or non-repeating) submitted before the session is ready will
  * be queued up and will begin capture once the session becomes ready. In case the session cannot be
- * configured and {@link StateListener#onConfigureFailed onConfigureFailed} is called, all queued
+ * configured and {@link StateCallback#onConfigureFailed onConfigureFailed} is called, all queued
  * capture requests are discarded.</p>
  *-->
  * <p>If a new session is created by the camera device, then the previous session is closed, and its
- * associated {@link StateListener#onClosed onClosed} callback will be invoked.  All
+ * associated {@link StateCallback#onClosed onClosed} callback will be invoked.  All
  * of the session methods will throw an IllegalStateException if called once the session is
  * closed.</p>
  *
@@ -86,7 +86,7 @@
      * looper}.
      *
      * @return int A unique capture sequence ID used by
-     *             {@link CaptureListener#onCaptureSequenceCompleted}.
+     *             {@link CaptureCallback#onCaptureSequenceCompleted}.
      *
      * @throws CameraAccessException if the camera device is no longer connected or has
      *                               encountered a fatal error
@@ -103,7 +103,7 @@
      * @see #setRepeatingBurst
      * @see #abortCaptures
      */
-    public abstract int capture(CaptureRequest request, CaptureListener listener, Handler handler)
+    public abstract int capture(CaptureRequest request, CaptureCallback listener, Handler handler)
             throws CameraAccessException;
 
     /**
@@ -131,7 +131,7 @@
      * looper}.
      *
      * @return int A unique capture sequence ID used by
-     *             {@link CaptureListener#onCaptureSequenceCompleted}.
+     *             {@link CaptureCallback#onCaptureSequenceCompleted}.
      *
      * @throws CameraAccessException if the camera device is no longer connected or has
      *                               encountered a fatal error
@@ -147,7 +147,7 @@
      * @see #setRepeatingBurst
      * @see #abortCaptures
      */
-    public abstract int captureBurst(List<CaptureRequest> requests, CaptureListener listener,
+    public abstract int captureBurst(List<CaptureRequest> requests, CaptureCallback listener,
             Handler handler) throws CameraAccessException;
 
     /**
@@ -185,7 +185,7 @@
      * looper}.
      *
      * @return int A unique capture sequence ID used by
-     *             {@link CaptureListener#onCaptureSequenceCompleted}.
+     *             {@link CaptureCallback#onCaptureSequenceCompleted}.
      *
      * @throws CameraAccessException if the camera device is no longer connected or has
      *                               encountered a fatal error
@@ -203,7 +203,7 @@
      * @see #stopRepeating
      * @see #abortCaptures
      */
-    public abstract int setRepeatingRequest(CaptureRequest request, CaptureListener listener,
+    public abstract int setRepeatingRequest(CaptureRequest request, CaptureCallback listener,
             Handler handler) throws CameraAccessException;
 
     /**
@@ -245,7 +245,7 @@
      * looper}.
      *
      * @return int A unique capture sequence ID used by
-     *             {@link CaptureListener#onCaptureSequenceCompleted}.
+     *             {@link CaptureCallback#onCaptureSequenceCompleted}.
      *
      * @throws CameraAccessException if the camera device is no longer connected or has
      *                               encountered a fatal error
@@ -263,7 +263,7 @@
      * @see #stopRepeating
      * @see #abortCaptures
      */
-    public abstract int setRepeatingBurst(List<CaptureRequest> requests, CaptureListener listener,
+    public abstract int setRepeatingBurst(List<CaptureRequest> requests, CaptureCallback listener,
             Handler handler) throws CameraAccessException;
 
     /**
@@ -274,7 +274,7 @@
      *
      * <p>Any currently in-flight captures will still complete, as will any burst that is
      * mid-capture. To ensure that the device has finished processing all of its capture requests
-     * and is in ready state, wait for the {@link StateListener#onReady} callback after
+     * and is in ready state, wait for the {@link StateCallback#onReady} callback after
      * calling this method.</p>
      *
      * @throws CameraAccessException if the camera device is no longer connected or has
@@ -285,7 +285,7 @@
      *
      * @see #setRepeatingRequest
      * @see #setRepeatingBurst
-     * @see StateListener#onIdle
+     * @see StateCallback#onIdle
      */
     public abstract void stopRepeating() throws CameraAccessException;
 
@@ -293,15 +293,15 @@
      * Discard all captures currently pending and in-progress as fast as possible.
      *
      * <p>The camera device will discard all of its current work as fast as possible. Some in-flight
-     * captures may complete successfully and call {@link CaptureListener#onCaptureCompleted}, while
-     * others will trigger their {@link CaptureListener#onCaptureFailed} callbacks. If a repeating
+     * captures may complete successfully and call {@link CaptureCallback#onCaptureCompleted}, while
+     * others will trigger their {@link CaptureCallback#onCaptureFailed} callbacks. If a repeating
      * request or a repeating burst is set, it will be cleared.</p>
      *
      * <p>This method is the fastest way to switch the camera device to a new session with
      * {@link CameraDevice#createCaptureSession}, at the cost of discarding in-progress work. It
      * must be called before the new session is created. Once all pending requests are either
-     * completed or thrown away, the {@link StateListener#onReady} callback will be called,
-     * if the session has not been closed. Otherwise, the {@link StateListener#onClosed}
+     * completed or thrown away, the {@link StateCallback#onReady} callback will be called,
+     * if the session has not been closed. Otherwise, the {@link StateCallback#onClosed}
      * callback will be fired when a new session is created by the camera device.</p>
      *
      * <p>Cancelling will introduce at least a brief pause in the stream of data from the camera
@@ -332,7 +332,7 @@
      *
      * <p>Note that creating a new capture session with {@link CameraDevice#createCaptureSession}
      * will close any existing capture session automatically, and call the older session listener's
-     * {@link StateListener#onClosed} callback. Using {@link CameraDevice#createCaptureSession}
+     * {@link StateCallback#onClosed} callback. Using {@link CameraDevice#createCaptureSession}
      * directly without closing is the recommended approach for quickly switching to a new session,
      * since unchanged target outputs can be reused more efficiently.</p>
      *
@@ -340,7 +340,7 @@
      * repeating requests or bursts are stopped (as if {@link #stopRepeating()} was called).
      * However, any in-progress capture requests submitted to the session will be completed as
      * normal; once all captures have completed and the session has been torn down,
-     * {@link StateListener#onClosed} will be called.</p>
+     * {@link StateCallback#onClosed} will be called.</p>
      *
      * <p>Closing a session is idempotent; closing more than once has no effect.</p>
      */
@@ -348,10 +348,10 @@
     public abstract void close();
 
     /**
-     * A listener for tracking the state of a camera capture session.
+     * A callback object for receiving updates about the state of a camera capture session.
      *
      */
-    public static abstract class StateListener {
+    public static abstract class StateCallback {
 
         /**
          * This method is called when the camera device has finished configuring itself, and the
@@ -439,10 +439,17 @@
     }
 
     /**
-     * <p>A listener for tracking the progress of a {@link CaptureRequest}
-     * submitted to the camera device.</p>
+     * Temporary for migrating to Callback naming
+     * @hide
+     */
+    public static abstract class StateListener extends StateCallback {
+    }
+
+    /**
+     * <p>A callback object for tracking the progress of a {@link CaptureRequest} submitted to the
+     * camera device.</p>
      *
-     * <p>This listener is called when a request triggers a capture to start,
+     * <p>This callback is invoked when a request triggers a capture to start,
      * and when the capture is complete. In case on an error capturing an image,
      * the error method is triggered instead of the completion method.</p>
      *
@@ -451,7 +458,7 @@
      * @see #setRepeatingRequest
      * @see #setRepeatingBurst
      */
-    public static abstract class CaptureListener {
+    public static abstract class CaptureCallback {
 
         /**
          * This constant is used to indicate that no images were captured for
@@ -476,7 +483,9 @@
          * and in the buffers sent to each output Surface. These buffer
          * timestamps are accessible through, for example,
          * {@link android.media.Image#getTimestamp() Image.getTimestamp()} or
-         * {@link android.graphics.SurfaceTexture#getTimestamp()}.</p>
+         * {@link android.graphics.SurfaceTexture#getTimestamp()}.
+         * The frame number included is equal to the frame number that will be included in
+         * {@link CaptureResult#getFrameNumber}.</p>
          *
          * <p>For the simplest way to play a shutter sound camera shutter or a
          * video recording start/stop sound, see the
@@ -487,10 +496,21 @@
          * @param session the session returned by {@link CameraDevice#createCaptureSession}
          * @param request the request for the capture that just begun
          * @param timestamp the timestamp at start of capture, in nanoseconds.
+         * @param frameNumber the frame number for this capture
          *
          * @see android.media.MediaActionSound
          */
         public void onCaptureStarted(CameraCaptureSession session,
+                CaptureRequest request, long timestamp, long frameNumber) {
+            // Temporary trampoline for API change transition
+            onCaptureStarted(session, request, timestamp);
+        }
+
+        /**
+         * Temporary for API change transition
+         * @hide
+         */
+        public void onCaptureStarted(CameraCaptureSession session,
                 CaptureRequest request, long timestamp) {
             // default empty implementation
         }
@@ -625,7 +645,7 @@
         }
 
         /**
-         * This method is called independently of the others in CaptureListener,
+         * This method is called independently of the others in CaptureCallback,
          * when a capture sequence finishes and all {@link CaptureResult}
          * or {@link CaptureFailure} for it have been returned via this listener.
          *
@@ -655,7 +675,7 @@
         }
 
         /**
-         * This method is called independently of the others in CaptureListener,
+         * This method is called independently of the others in CaptureCallback,
          * when a capture sequence aborts before any {@link CaptureResult}
          * or {@link CaptureFailure} for it have been returned via this listener.
          *
@@ -684,4 +704,11 @@
         }
     }
 
+    /**
+     * Temporary for migrating to Callback naming
+     * @hide
+     */
+    public static abstract class CaptureListener extends CaptureCallback {
+    }
+
 }
diff --git a/core/java/android/hardware/camera2/CameraCharacteristics.java b/core/java/android/hardware/camera2/CameraCharacteristics.java
index 4e7f9dd..c525348 100644
--- a/core/java/android/hardware/camera2/CameraCharacteristics.java
+++ b/core/java/android/hardware/camera2/CameraCharacteristics.java
@@ -313,18 +313,18 @@
 
     /**
      * <p>The set of aberration correction modes supported by this camera device.</p>
-     * <p>This metadata lists the valid modes for {@link CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE android.colorCorrection.aberrationCorrectionMode}.
+     * <p>This metadata lists the valid modes for {@link CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE android.colorCorrection.aberrationMode}.
      * If no aberration correction modes are available for a device, this list will solely include
      * OFF mode.</p>
      * <p>For FULL capability device ({@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL android.info.supportedHardwareLevel} <code>==</code> FULL), OFF must be
      * included.</p>
      *
-     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
+     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
      * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
      */
     @PublicKey
-    public static final Key<int[]> COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES =
-            new Key<int[]>("android.colorCorrection.availableAberrationCorrectionModes", int[].class);
+    public static final Key<int[]> COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES =
+            new Key<int[]>("android.colorCorrection.availableAberrationModes", int[].class);
 
     /**
      * <p>The set of auto-exposure antibanding modes that are
diff --git a/core/java/android/hardware/camera2/CameraDevice.java b/core/java/android/hardware/camera2/CameraDevice.java
index 6a9d565..0bb742c 100644
--- a/core/java/android/hardware/camera2/CameraDevice.java
+++ b/core/java/android/hardware/camera2/CameraDevice.java
@@ -199,8 +199,8 @@
      * <p>It can take several hundred milliseconds for the session's configuration to complete,
      * since camera hardware may need to be powered on or reconfigured. Once the configuration is
      * complete and the session is ready to actually capture data, the provided
-     * {@link CameraCaptureSession.StateListener}'s
-     * {@link CameraCaptureSession.StateListener#onConfigured} callback will be called.</p>
+     * {@link CameraCaptureSession.StateCallback}'s
+     * {@link CameraCaptureSession.StateCallback#onConfigured} callback will be called.</p>
      *
      * <p>If a prior CameraCaptureSession already exists when a new one is created, the previous
      * session is closed. Any in-progress capture requests made on the prior session will be
@@ -216,14 +216,136 @@
      * <p>Configuring a session with an empty or null list will close the current session, if
      * any. This can be used to release the current session's target surfaces for another use.</p>
      *
+     * <p>While any of the sizes from {@link StreamConfigurationMap#getOutputSizes} can be used when
+     * a single output stream is configured, a given camera device may not be able to support all
+     * combination of sizes, formats, and targets when multiple outputs are configured at once.  The
+     * tables below list the maximum guaranteed resolutions for combinations of streams and targets,
+     * given the capabilities of the camera device.</p>
+     *
+     * <p>If an application tries to create a session using a set of targets that exceed the limits
+     * described in the below tables, one of three possibilities may occur. First, the session may
+     * be successfully created and work normally. Second, the session may be successfully created,
+     * but the camera device won't meet the frame rate guarantees as described in
+     * {@link StreamConfigurationMap#getOutputMinFrameDuration}. Or third, if the output set
+     * cannot be used at all, session creation will fail entirely, with
+     * {@link CameraCaptureSession.StateListener#onConfigureFailed} being invoked.</p>
+     *
+     * <p>For the type column, {@code PRIV} refers to any target whose available sizes are found
+     * using {@link StreamConfigurationMap#getOutputSizes(Class)} with no direct application-visible
+     * format, {@code YUV} refers to a target Surface using the
+     * {@link android.graphics.ImageFormat#YUV_420_888} format, {@code JPEG} refers to the
+     * {@link android.graphics.ImageFormat#JPEG} format, and {@code RAW} refers to the
+     * {@link android.graphics.ImageFormat#RAW_SENSOR} format.</p>
+     *
+     * <p>For the maximum size column, {@code PREVIEW} refers to the best size match to the
+     * device's screen resolution, or to 1080p ({@code 1920x1080}), whichever is
+     * smaller. {@code RECORD} refers to the camera device's maximum supported recording resolution,
+     * as determined by {@link android.media.CamcorderProfile}. And {@code MAXIMUM} refers to the
+     * camera device's maximum output resolution for that format or target from
+     * {@link StreamConfigurationMap#getOutputSizes}.</p>
+     *
+     * <p>To use these tables, determine the number and the formats/targets of outputs needed, and
+     * find the row(s) of the table with those targets. The sizes indicate the maximum set of sizes
+     * that can be used; it is guaranteed that for those targets, the listed sizes and anything
+     * smaller from the list given by {@link StreamConfigurationMap#getOutputSizes} can be
+     * successfully used to create a session.  For example, if a row indicates that a 8 megapixel
+     * (MP) YUV_420_888 output can be used together with a 2 MP {@code PRIV} output, then a session
+     * can be created with targets {@code [8 MP YUV, 2 MP PRIV]} or targets {@code [2 MP YUV, 2 MP
+     * PRIV]}; but a session with targets {@code [8 MP YUV, 4 MP PRIV]}, targets {@code [4 MP YUV, 4
+     * MP PRIV]}, or targets {@code [8 MP PRIV, 2 MP YUV]} would not be guaranteed to work, unless
+     * some other row of the table lists such a combination.</p>
+     *
+     * <style scoped>
+     *  #rb { border-right-width: thick; }
+     * </style>
+     * <p>Legacy devices ({@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL}
+     * {@code == }{@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY LEGACY}) support at
+     * least the following stream combinations:
+     *
+     * <table>
+     * <tr><th colspan="7">LEGACY-level guaranteed configurations</th></tr>
+     * <tr> <th colspan="2" id="rb">Target 1</th> <th colspan="2" id="rb">Target 2</th>  <th colspan="2" id="rb">Target 3</th> <th rowspan="2">Sample use case(s)</th> </tr>
+     * <tr> <th>Type</th><th id="rb">Max size</th> <th>Type</th><th id="rb">Max size</th> <th>Type</th><th id="rb">Max size</th></tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td colspan="2" id="rb"></td> <td>Simple preview, GPU video processing, or no-preview video recording.</td> </tr>
+     * <tr> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td colspan="2" id="rb"></td> <td>No-viewfinder still image capture.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td colspan="2" id="rb"></td> <td>In-application video/image processing.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>Standard still imaging.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>In-app processing plus still capture.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td colspan="2" id="rb"></td> <td>Standard recording.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td colspan="2" id="rb"></td> <td>Preview plus in-app processing.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>Still capture plus in-app processing.</td> </tr>
+     * </table><br>
+     * </p>
+     *
+     * <p>Limited-capability ({@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL}
+     * {@code == }{@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED LIMITED}) devices
+     * support at least the following stream combinations in addition to those for
+     * {@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY LEGACY} devices:
+     *
+     * <table>
+     * <tr><th colspan="7">LIMITED-level additional guaranteed configurations</th></tr>
+     * <tr><th colspan="2" id="rb">Target 1</th><th colspan="2" id="rb">Target 2</th><th colspan="2" id="rb">Target 3</th> <th rowspan="2">Sample use case(s)</th> </tr>
+     * <tr><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th></tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code RECORD }</td> <td colspan="2" id="rb"></td> <td>High-resolution video recording with preview.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code RECORD }</td> <td colspan="2" id="rb"></td> <td>High-resolution in-app video processing with preview.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code RECORD }</td> <td colspan="2" id="rb"></td> <td>Two-input in-app video processing.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code RECORD }</td> <td>{@code JPEG}</td><td id="rb">{@code RECORD }</td> <td>High-resolution recording with video snapshot.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code RECORD }</td> <td>{@code JPEG}</td><td id="rb">{@code RECORD }</td> <td>High-resolution in-app processing with video snapshot.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>Two-input in-app processing with still capture.</td> </tr>
+     * </table><br>
+     * </p>
+     *
+     * <p>FULL-capability ({@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL}
+     * {@code == }{@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_FULL FULL}) devices
+     * support at least the following stream combinations in addition to those for
+     * {@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED LIMITED} devices:
+     *
+     * <table>
+     * <tr><th colspan="7">FULL-capability additional guaranteed configurations</th></tr>
+     * <tr><th colspan="2" id="rb">Target 1</th><th colspan="2" id="rb">Target 2</th><th colspan="2" id="rb">Target 3</th> <th rowspan="2">Sample use case(s)</th> </tr>
+     * <tr><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>Maximum-resolution GPU processing with preview.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>Maximum-resolution in-app processing with preview.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>Maximum-resolution two-input in-app processsing.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>Video recording with maximum-size video snapshot</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code 640x480}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code MAXIMUM}</td> <td>Standard video recording plus maximum-resolution in-app processing.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code 640x480}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code MAXIMUM}</td> <td>Preview plus two-input maximum-resolution in-app processing.</td> </tr>
+     * </table><br>
+     * </p>
+     *
+     * <p>RAW-capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES} includes
+     * {@link CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_RAW RAW}) devices additionally support
+     * at least the following stream combinations on both
+     * {@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_FULL FULL} and
+     * {@link CameraMetadata#INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED LIMITED} devices:
+     *
+     * <table>
+     * <tr><th colspan="7">RAW-capability additional guaranteed configurations</th></tr>
+     * <tr><th colspan="2" id="rb">Target 1</th><th colspan="2" id="rb">Target 2</th><th colspan="2" id="rb">Target 3</th> <th rowspan="2">Sample use case(s)</th> </tr>
+     * <tr><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th><th>Type</th><th id="rb">Max size</th> </tr>
+     * <tr> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td colspan="2" id="rb"></td> <td>No-preview DNG capture.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>Standard DNG capture.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td colspan="2" id="rb"></td> <td>In-app processing plus DNG capture.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td>Video recording with DNG capture.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td>Preview with in-app processing and DNG capture.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td>Two-input in-app processing plus DNG capture.</td> </tr>
+     * <tr> <td>{@code PRIV}</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td>Still capture with simultaneous JPEG and DNG.</td> </tr>
+     * <tr> <td>{@code YUV }</td><td id="rb">{@code PREVIEW}</td> <td>{@code JPEG}</td><td id="rb">{@code MAXIMUM}</td> <td>{@code RAW }</td><td id="rb">{@code MAXIMUM}</td> <td>In-app processing with simultaneous JPEG and DNG.</td> </tr>
+     * </table><br>
+     * </p>
+     *
+     * <p>Since the capabilities of camera devices vary greatly, a given camera device may support
+     * target combinations with sizes outside of these guarantees, but this can only be tested for
+     * by attempting to create a session with such targets.</p>
+     *
      * @param outputs The new set of Surfaces that should be made available as
      *                targets for captured image data.
-     * @param listener The listener to notify about the status of the new capture session.
-     * @param handler The handler on which the listener should be invoked, or {@code null} to use
+     * @param callback The callback to notify about the status of the new capture session.
+     * @param handler The handler on which the callback should be invoked, or {@code null} to use
      *                the current thread's {@link android.os.Looper looper}.
      *
      * @throws IllegalArgumentException if the set of output Surfaces do not meet the requirements,
-     *                                  the listener is null, or the handler is null but the current
+     *                                  the callback is null, or the handler is null but the current
      *                                  thread has no looper.
      * @throws CameraAccessException if the camera device is no longer connected or has
      *                               encountered a fatal error
@@ -235,7 +357,7 @@
      * @see StreamConfigurationMap#getOutputSizes(Class)
      */
     public abstract void createCaptureSession(List<Surface> outputs,
-            CameraCaptureSession.StateListener listener, Handler handler)
+            CameraCaptureSession.StateCallback callback, Handler handler)
             throws CameraAccessException;
 
     /**
@@ -271,10 +393,10 @@
      *
      * <p>Immediately after this call, all calls to the camera device or active session interface
      * will throw a {@link IllegalStateException}, except for calls to close(). Once the device has
-     * fully shut down, the {@link StateListener#onClosed} callback will be called, and the camera
+     * fully shut down, the {@link StateCallback#onClosed} callback will be called, and the camera
      * is free to be re-opened.</p>
      *
-     * <p>Immediately after this call, besides the final {@link StateListener#onClosed} calls, no
+     * <p>Immediately after this call, besides the final {@link StateCallback#onClosed} calls, no
      * further callbacks from the device or the active session will occur, and any remaining
      * submitted capture requests will be discarded, as if
      * {@link CameraCaptureSession#abortCaptures} had been called, except that no success or failure
@@ -285,24 +407,24 @@
     public abstract void close();
 
     /**
-     * A listener for notifications about the state of a camera
-     * device.
+     * A callback objects for receiving updates about the state of a camera device.
      *
-     * <p>A listener must be provided to the {@link CameraManager#openCamera}
-     * method to open a camera device.</p>
+     * <p>A callback instance must be provided to the {@link CameraManager#openCamera} method to
+     * open a camera device.</p>
      *
-     * <p>These events include notifications about the device completing startup (
+     * <p>These state updates include notifications about the device completing startup (
      * allowing for {@link #createCaptureSession} to be called), about device
      * disconnection or closure, and about unexpected device errors.</p>
      *
      * <p>Events about the progress of specific {@link CaptureRequest CaptureRequests} are provided
-     * through a {@link CameraCaptureSession.CaptureListener} given to the
+     * through a {@link CameraCaptureSession.CaptureCallback} given to the
      * {@link CameraCaptureSession#capture}, {@link CameraCaptureSession#captureBurst},
-     * {@link CameraCaptureSession#setRepeatingRequest}, or {@link CameraCaptureSession#setRepeatingBurst} methods.
+     * {@link CameraCaptureSession#setRepeatingRequest}, or
+     * {@link CameraCaptureSession#setRepeatingBurst} methods.
      *
      * @see CameraManager#openCamera
      */
-    public static abstract class StateListener {
+    public static abstract class StateCallback {
        /**
          * An error code that can be reported by {@link #onError}
          * indicating that the camera device is in use already.
@@ -408,7 +530,7 @@
          * of a removable camera device; or the camera being needed for a
          * higher-priority use case.</p>
          *
-         * <p>There may still be capture listener callbacks that are called
+         * <p>There may still be capture callbacks that are invoked
          * after this method is called, or new image buffers that are delivered
          * to active outputs.</p>
          *
@@ -417,7 +539,7 @@
          *
          * <p>You should clean up the camera with {@link CameraDevice#close} after
          * this happens, as it is not recoverable until opening the camera again
-         * after it becomes {@link CameraManager.AvailabilityListener#onCameraAvailable available}.
+         * after it becomes {@link CameraManager.AvailabilityCallback#onCameraAvailable available}.
          * </p>
          *
          * @param camera the device that has been disconnected
@@ -436,7 +558,7 @@
          * {@link CameraAccessException#CAMERA_ERROR CAMERA_ERROR} reason.
          * </p>
          *
-         * <p>There may still be capture completion or camera stream listeners
+         * <p>There may still be capture completion or camera stream callbacks
          * that will be called after this error is received.</p>
          *
          * <p>You should clean up the camera with {@link CameraDevice#close} after
@@ -444,7 +566,7 @@
          *
          * @param camera The device reporting the error
          * @param error The error code, one of the
-         *     {@code StateListener.ERROR_*} values.
+         *     {@code StateCallback.ERROR_*} values.
          *
          * @see #ERROR_CAMERA_DEVICE
          * @see #ERROR_CAMERA_SERVICE
@@ -455,6 +577,13 @@
     }
 
     /**
+     * Temporary for migrating to Callback naming
+     * @hide
+     */
+    public static abstract class StateListener extends StateCallback {
+    }
+
+    /**
      * To be inherited by android.hardware.camera2.* code only.
      * @hide
      */
diff --git a/core/java/android/hardware/camera2/CameraManager.java b/core/java/android/hardware/camera2/CameraManager.java
index a4a1559..9a9e4c2 100644
--- a/core/java/android/hardware/camera2/CameraManager.java
+++ b/core/java/android/hardware/camera2/CameraManager.java
@@ -69,8 +69,8 @@
 
     private ArrayList<String> mDeviceIdList;
 
-    private final ArrayMap<AvailabilityListener, Handler> mListenerMap =
-            new ArrayMap<AvailabilityListener, Handler>();
+    private final ArrayMap<AvailabilityCallback, Handler> mCallbackMap =
+            new ArrayMap<AvailabilityCallback, Handler>();
 
     private final Context mContext;
     private final Object mLock = new Object();
@@ -108,19 +108,19 @@
     }
 
     /**
-     * Register a listener to be notified about camera device availability.
+     * Register a callback to be notified about camera device availability.
      *
-     * <p>Registering the same listener again will replace the handler with the
+     * <p>Registering the same callback again will replace the handler with the
      * new one provided.</p>
      *
-     * <p>The first time a listener is registered, it is immediately called
+     * <p>The first time a callback is registered, it is immediately called
      * with the availability status of all currently known camera devices.</p>
      *
-     * @param listener The new listener to send camera availability notices to
-     * @param handler The handler on which the listener should be invoked, or
+     * @param callback the new callback to send camera availability notices to
+     * @param handler The handler on which the callback should be invoked, or
      * {@code null} to use the current thread's {@link android.os.Looper looper}.
      */
-    public void addAvailabilityListener(AvailabilityListener listener, Handler handler) {
+    public void registerAvailabilityCallback(AvailabilityCallback callback, Handler handler) {
         if (handler == null) {
             Looper looper = Looper.myLooper();
             if (looper == null) {
@@ -131,25 +131,25 @@
         }
 
         synchronized (mLock) {
-            Handler oldHandler = mListenerMap.put(listener, handler);
-            // For new listeners, provide initial availability information
+            Handler oldHandler = mCallbackMap.put(callback, handler);
+            // For new callbacks, provide initial availability information
             if (oldHandler == null) {
-                mServiceListener.updateListenerLocked(listener, handler);
+                mServiceListener.updateCallbackLocked(callback, handler);
             }
         }
     }
 
     /**
-     * Remove a previously-added listener; the listener will no longer receive
-     * connection and disconnection callbacks.
+     * Remove a previously-added callback; the callback will no longer receive connection and
+     * disconnection callbacks.
      *
-     * <p>Removing a listener that isn't registered has no effect.</p>
+     * <p>Removing a callback that isn't registered has no effect.</p>
      *
-     * @param listener The listener to remove from the notification list
+     * @param callback The callback to remove from the notification list
      */
-    public void removeAvailabilityListener(AvailabilityListener listener) {
+    public void unregisterAvailabilityCallback(AvailabilityCallback callback) {
         synchronized (mLock) {
-            mListenerMap.remove(listener);
+            mCallbackMap.remove(callback);
         }
     }
 
@@ -228,8 +228,8 @@
      * Helper for openning a connection to a camera with the given ID.
      *
      * @param cameraId The unique identifier of the camera device to open
-     * @param listener The listener for the camera. Must not be null.
-     * @param handler  The handler to call the listener on. Must not be null.
+     * @param callback The callback for the camera. Must not be null.
+     * @param handler  The handler to invoke the callback on. Must not be null.
      *
      * @throws CameraAccessException if the camera is disabled by device policy,
      * or too many camera devices are already open, or the cameraId does not match
@@ -237,14 +237,14 @@
      *
      * @throws SecurityException if the application does not have permission to
      * access the camera
-     * @throws IllegalArgumentException if listener or handler is null.
+     * @throws IllegalArgumentException if callback or handler is null.
      * @return A handle to the newly-created camera device.
      *
      * @see #getCameraIdList
      * @see android.app.admin.DevicePolicyManager#setCameraDisabled
      */
     private CameraDevice openCameraDeviceUserAsync(String cameraId,
-            CameraDevice.StateListener listener, Handler handler)
+            CameraDevice.StateCallback callback, Handler handler)
             throws CameraAccessException {
         CameraCharacteristics characteristics = getCameraCharacteristics(cameraId);
         CameraDevice device = null;
@@ -257,7 +257,7 @@
                 android.hardware.camera2.impl.CameraDeviceImpl deviceImpl =
                         new android.hardware.camera2.impl.CameraDeviceImpl(
                                 cameraId,
-                                listener,
+                                callback,
                                 handler,
                                 characteristics);
 
@@ -313,7 +313,7 @@
                     throw ce.asChecked();
                 }
 
-                // TODO: factor out listener to be non-nested, then move setter to constructor
+                // TODO: factor out callback to be non-nested, then move setter to constructor
                 // For now, calling setRemoteDevice will fire initial
                 // onOpened/onUnconfigured callbacks.
                 deviceImpl.setRemoteDevice(cameraUser);
@@ -337,7 +337,7 @@
      * is disconnected between the calls to {@link #getCameraIdList} and
      * {@link #openCamera}.</p>
      *
-     * <p>Once the camera is successfully opened, {@link CameraDevice.StateListener#onOpened} will
+     * <p>Once the camera is successfully opened, {@link CameraDevice.StateCallback#onOpened} will
      * be invoked with the newly opened {@link CameraDevice}. The camera device can then be set up
      * for operation by calling {@link CameraDevice#createCaptureSession} and
      * {@link CameraDevice#createCaptureRequest}</p>
@@ -345,31 +345,31 @@
      * <!--
      * <p>Since the camera device will be opened asynchronously, any asynchronous operations done
      * on the returned CameraDevice instance will be queued up until the device startup has
-     * completed and the listener's {@link CameraDevice.StateListener#onOpened onOpened} method is
+     * completed and the callback's {@link CameraDevice.StateCallback#onOpened onOpened} method is
      * called. The pending operations are then processed in order.</p>
      * -->
      * <p>If the camera becomes disconnected during initialization
      * after this function call returns,
-     * {@link CameraDevice.StateListener#onDisconnected} with a
+     * {@link CameraDevice.StateCallback#onDisconnected} with a
      * {@link CameraDevice} in the disconnected state (and
-     * {@link CameraDevice.StateListener#onOpened} will be skipped).</p>
+     * {@link CameraDevice.StateCallback#onOpened} will be skipped).</p>
      *
-     * <p>If opening the camera device fails, then the device listener's
-     * {@link CameraDevice.StateListener#onError onError} method will be called, and subsequent
+     * <p>If opening the camera device fails, then the device callback's
+     * {@link CameraDevice.StateCallback#onError onError} method will be called, and subsequent
      * calls on the camera device will throw a {@link CameraAccessException}.</p>
      *
      * @param cameraId
      *             The unique identifier of the camera device to open
-     * @param listener
-     *             The listener which is invoked once the camera is opened
+     * @param callback
+     *             The callback which is invoked once the camera is opened
      * @param handler
-     *             The handler on which the listener should be invoked, or
+     *             The handler on which the callback should be invoked, or
      *             {@code null} to use the current thread's {@link android.os.Looper looper}.
      *
      * @throws CameraAccessException if the camera is disabled by device policy,
      * or the camera has become or was disconnected.
      *
-     * @throws IllegalArgumentException if cameraId or the listener was null,
+     * @throws IllegalArgumentException if cameraId or the callback was null,
      * or the cameraId does not match any currently or previously available
      * camera device.
      *
@@ -379,14 +379,14 @@
      * @see #getCameraIdList
      * @see android.app.admin.DevicePolicyManager#setCameraDisabled
      */
-    public void openCamera(String cameraId, final CameraDevice.StateListener listener,
+    public void openCamera(String cameraId, final CameraDevice.StateCallback callback,
             Handler handler)
             throws CameraAccessException {
 
         if (cameraId == null) {
             throw new IllegalArgumentException("cameraId was null");
-        } else if (listener == null) {
-            throw new IllegalArgumentException("listener was null");
+        } else if (callback == null) {
+            throw new IllegalArgumentException("callback was null");
         } else if (handler == null) {
             if (Looper.myLooper() != null) {
                 handler = new Handler();
@@ -396,11 +396,11 @@
             }
         }
 
-        openCameraDeviceUserAsync(cameraId, listener, handler);
+        openCameraDeviceUserAsync(cameraId, callback, handler);
     }
 
     /**
-     * A listener for camera devices becoming available or
+     * A callback for camera devices becoming available or
      * unavailable to open.
      *
      * <p>Cameras become available when they are no longer in use, or when a new
@@ -408,13 +408,13 @@
      * application or service starts using a camera, or when a removable camera
      * is disconnected.</p>
      *
-     * <p>Extend this listener and pass an instance of the subclass to
-     * {@link CameraManager#addAvailabilityListener} to be notified of such availability
+     * <p>Extend this callback and pass an instance of the subclass to
+     * {@link CameraManager#registerAvailabilityCallback} to be notified of such availability
      * changes.</p>
      *
-     * @see addAvailabilityListener
+     * @see registerAvailabilityCallback
      */
-    public static abstract class AvailabilityListener {
+    public static abstract class AvailabilityCallback {
 
         /**
          * A new camera has become available to use.
@@ -432,7 +432,7 @@
          *
          * <p>If an application had an active CameraDevice instance for the
          * now-disconnected camera, that application will receive a
-         * {@link CameraDevice.StateListener#onDisconnected disconnection error}.</p>
+         * {@link CameraDevice.StateCallback#onDisconnected disconnection error}.</p>
          *
          * <p>The default implementation of this method does nothing.</p>
          *
@@ -444,6 +444,13 @@
     }
 
     /**
+     * Temporary for migrating to Callback naming
+     * @hide
+     */
+    public static abstract class AvailabilityListener extends AvailabilityCallback {
+    }
+
+    /**
      * Return or create the list of currently connected camera devices.
      *
      * <p>In case of errors connecting to the camera service, will return an empty list.</p>
@@ -707,14 +714,14 @@
             }
         }
 
-        private void postSingleUpdate(final AvailabilityListener listener, final Handler handler,
+        private void postSingleUpdate(final AvailabilityCallback callback, final Handler handler,
                 final String id, final int status) {
             if (isAvailable(status)) {
                 handler.post(
                     new Runnable() {
                         @Override
                         public void run() {
-                            listener.onCameraAvailable(id);
+                            callback.onCameraAvailable(id);
                         }
                     });
             } else {
@@ -722,7 +729,7 @@
                     new Runnable() {
                         @Override
                         public void run() {
-                            listener.onCameraUnavailable(id);
+                            callback.onCameraUnavailable(id);
                         }
                     });
             }
@@ -732,11 +739,11 @@
          * Send the state of all known cameras to the provided listener, to initialize
          * the listener's knowledge of camera state.
          */
-        public void updateListenerLocked(AvailabilityListener listener, Handler handler) {
+        public void updateCallbackLocked(AvailabilityCallback callback, Handler handler) {
             for (int i = 0; i < mDeviceStatus.size(); i++) {
                 String id = mDeviceStatus.keyAt(i);
                 Integer status = mDeviceStatus.valueAt(i);
-                postSingleUpdate(listener, handler, id, status);
+                postSingleUpdate(callback, handler, id, status);
             }
         }
 
@@ -795,12 +802,12 @@
                 return;
             }
 
-            final int listenerCount = mListenerMap.size();
-            for (int i = 0; i < listenerCount; i++) {
-                Handler handler = mListenerMap.valueAt(i);
-                final AvailabilityListener listener = mListenerMap.keyAt(i);
+            final int callbackCount = mCallbackMap.size();
+            for (int i = 0; i < callbackCount; i++) {
+                Handler handler = mCallbackMap.valueAt(i);
+                final AvailabilityCallback callback = mCallbackMap.keyAt(i);
 
-                postSingleUpdate(listener, handler, id, status);
+                postSingleUpdate(callback, handler, id, status);
             }
         } // onStatusChangedLocked
 
diff --git a/core/java/android/hardware/camera2/CameraMetadata.java b/core/java/android/hardware/camera2/CameraMetadata.java
index 9bdfe8b..a57b361 100644
--- a/core/java/android/hardware/camera2/CameraMetadata.java
+++ b/core/java/android/hardware/camera2/CameraMetadata.java
@@ -386,8 +386,8 @@
      * </ul>
      * </li>
      * <li>Manual aberration correction control (if aberration correction is supported)<ul>
-     * <li>{@link CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE android.colorCorrection.aberrationCorrectionMode}</li>
-     * <li>{@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES android.colorCorrection.availableAberrationCorrectionModes}</li>
+     * <li>{@link CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE android.colorCorrection.aberrationMode}</li>
+     * <li>{@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES android.colorCorrection.availableAberrationModes}</li>
      * </ul>
      * </li>
      * </ul>
@@ -396,8 +396,8 @@
      * <p>A given camera device may also support additional post-processing
      * controls, but this capability only covers the above list of controls.</p>
      *
-     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
-     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES
+     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
+     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES
      * @see CaptureRequest#COLOR_CORRECTION_GAINS
      * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
      * @see CaptureRequest#SHADING_MODE
@@ -739,28 +739,28 @@
     public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2;
 
     //
-    // Enumeration values for CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
+    // Enumeration values for CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
     //
 
     /**
      * <p>No aberration correction is applied.</p>
-     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
+     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
      */
-    public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_OFF = 0;
+    public static final int COLOR_CORRECTION_ABERRATION_MODE_OFF = 0;
 
     /**
      * <p>Aberration correction will not slow down capture rate
      * relative to sensor raw output.</p>
-     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
+     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
      */
-    public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_FAST = 1;
+    public static final int COLOR_CORRECTION_ABERRATION_MODE_FAST = 1;
 
     /**
      * <p>Aberration correction operates at improved quality but reduced
      * capture rate (relative to sensor raw output).</p>
-     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE
+     * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
      */
-    public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_HIGH_QUALITY = 2;
+    public static final int COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY = 2;
 
     //
     // Enumeration values for CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
@@ -1213,7 +1213,8 @@
      * image while recording video) use case.</p>
      * <p>The camera device should take the highest-quality image
      * possible (given the other settings) without disrupting the
-     * frame rate of video recording.  </p>
+     * frame rate of video recording.<br />
+     * </p>
      * @see CaptureRequest#CONTROL_CAPTURE_INTENT
      */
     public static final int CONTROL_CAPTURE_INTENT_VIDEO_SNAPSHOT = 4;
@@ -1574,6 +1575,13 @@
      */
     public static final int CONTROL_SCENE_MODE_HIGH_SPEED_VIDEO = 17;
 
+    /**
+     * <p>Turn on custom high dynamic range (HDR) mode.</p>
+     * @see CaptureRequest#CONTROL_SCENE_MODE
+     * @hide
+     */
+    public static final int CONTROL_SCENE_MODE_HDR = 18;
+
     //
     // Enumeration values for CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
     //
diff --git a/core/java/android/hardware/camera2/CaptureFailure.java b/core/java/android/hardware/camera2/CaptureFailure.java
index 2c505e5..c168ff1 100644
--- a/core/java/android/hardware/camera2/CaptureFailure.java
+++ b/core/java/android/hardware/camera2/CaptureFailure.java
@@ -47,13 +47,13 @@
     private final int mReason;
     private final boolean mDropped;
     private final int mSequenceId;
-    private final int mFrameNumber;
+    private final long mFrameNumber;
 
     /**
      * @hide
      */
     public CaptureFailure(CaptureRequest request, int reason, boolean dropped, int sequenceId,
-            int frameNumber) {
+            long frameNumber) {
         mRequest = request;
         mReason = reason;
         mDropped = dropped;
@@ -65,12 +65,12 @@
      * Get the request associated with this failed capture.
      *
      * <p>Whenever a request is unsuccessfully captured, with
-     * {@link CameraCaptureSession.CaptureListener#onCaptureFailed},
+     * {@link CameraCaptureSession.CaptureCallback#onCaptureFailed},
      * the {@code failed capture}'s {@code getRequest()} will return that {@code request}.
      * </p>
      *
      * <p>In particular,
-     * <code><pre>cameraDevice.capture(someRequest, new CaptureListener() {
+     * <code><pre>cameraDevice.capture(someRequest, new CaptureCallback() {
      *     {@literal @}Override
      *     void onCaptureFailed(CaptureRequest myRequest, CaptureFailure myFailure) {
      *         assert(myFailure.getRequest.equals(myRequest) == true);
@@ -95,9 +95,9 @@
      * for every new result or failure; and the scope is the lifetime of the
      * {@link CameraDevice}.</p>
      *
-     * @return int frame number
+     * @return long frame number
      */
-    public int getFrameNumber() {
+    public long getFrameNumber() {
         return mFrameNumber;
     }
 
@@ -135,7 +135,7 @@
      *
      * @return int The ID for the sequence of requests that this capture failure is the result of
      *
-     * @see CameraDevice.CaptureListener#onCaptureSequenceCompleted
+     * @see CameraDevice.CaptureCallback#onCaptureSequenceCompleted
      */
     public int getSequenceId() {
         return mSequenceId;
diff --git a/core/java/android/hardware/camera2/CaptureRequest.java b/core/java/android/hardware/camera2/CaptureRequest.java
index 97077e6..93eb3de 100644
--- a/core/java/android/hardware/camera2/CaptureRequest.java
+++ b/core/java/android/hardware/camera2/CaptureRequest.java
@@ -245,7 +245,7 @@
      * <p>This tag is not used for anything by the camera device, but can be
      * used by an application to easily identify a CaptureRequest when it is
      * returned by
-     * {@link CameraCaptureSession.CaptureListener#onCaptureCompleted CaptureListener.onCaptureCompleted}
+     * {@link CameraCaptureSession.CaptureCallback#onCaptureCompleted CaptureCallback.onCaptureCompleted}
      * </p>
      *
      * @return the last tag Object set on this request, or {@code null} if
@@ -435,7 +435,7 @@
          * <p>This tag is not used for anything by the camera device, but can be
          * used by an application to easily identify a CaptureRequest when it is
          * returned by
-         * {@link CameraCaptureSession.CaptureListener#onCaptureCompleted CaptureListener.onCaptureCompleted}
+         * {@link CameraCaptureSession.CaptureCallback#onCaptureCompleted CaptureCallback.onCaptureCompleted}
          *
          * @param tag an arbitrary Object to store with this request
          * @see CaptureRequest#getTag
@@ -569,7 +569,7 @@
     /**
      * <p>Mode of operation for the chromatic aberration correction algorithm.</p>
      * <p>This must be set to a valid mode from
-     * {@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES android.colorCorrection.availableAberrationCorrectionModes}.</p>
+     * {@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES android.colorCorrection.availableAberrationModes}.</p>
      * <p>Chromatic (color) aberration is caused by the fact that different wavelengths of light
      * can not focus on the same point after exiting from the lens. This metadata defines
      * the high level control of chromatic aberration correction algorithm, which aims to
@@ -581,14 +581,14 @@
      * capture rate. FAST means the camera device will not slow down capture rate when
      * applying aberration correction.</p>
      *
-     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_OFF
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_FAST
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_HIGH_QUALITY
+     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_OFF
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_FAST
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY
      */
     @PublicKey
-    public static final Key<Integer> COLOR_CORRECTION_ABERRATION_CORRECTION_MODE =
-            new Key<Integer>("android.colorCorrection.aberrationCorrectionMode", int.class);
+    public static final Key<Integer> COLOR_CORRECTION_ABERRATION_MODE =
+            new Key<Integer>("android.colorCorrection.aberrationMode", int.class);
 
     /**
      * <p>The desired setting for the camera device's auto-exposure
@@ -731,6 +731,8 @@
     /**
      * <p>List of areas to use for
      * metering.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AE android.control.maxRegionsAe} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -746,7 +748,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AE
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
@@ -820,6 +824,8 @@
     /**
      * <p>List of areas to use for focus
      * estimation.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AF android.control.maxRegionsAf} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -835,7 +841,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AF
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
@@ -921,6 +929,8 @@
     /**
      * <p>List of areas to use for illuminant
      * estimation.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AWB android.control.maxRegionsAwb} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -936,7 +946,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AWB
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
diff --git a/core/java/android/hardware/camera2/CaptureResult.java b/core/java/android/hardware/camera2/CaptureResult.java
index 63dff55..01276a2 100644
--- a/core/java/android/hardware/camera2/CaptureResult.java
+++ b/core/java/android/hardware/camera2/CaptureResult.java
@@ -268,13 +268,13 @@
      * Get the request associated with this result.
      *
      * <p>Whenever a request has been fully or partially captured, with
-     * {@link CameraCaptureSession.CaptureListener#onCaptureCompleted} or
-     * {@link CameraCaptureSession.CaptureListener#onCaptureProgressed}, the {@code result}'s
+     * {@link CameraCaptureSession.CaptureCallback#onCaptureCompleted} or
+     * {@link CameraCaptureSession.CaptureCallback#onCaptureProgressed}, the {@code result}'s
      * {@code getRequest()} will return that {@code request}.
      * </p>
      *
      * <p>For example,
-     * <code><pre>cameraDevice.capture(someRequest, new CaptureListener() {
+     * <code><pre>cameraDevice.capture(someRequest, new CaptureCallback() {
      *     {@literal @}Override
      *     void onCaptureCompleted(CaptureRequest myRequest, CaptureResult myResult) {
      *         assert(myResult.getRequest.equals(myRequest) == true);
@@ -314,8 +314,8 @@
      *
      * @return int The ID for the sequence of requests that this capture result is a part of
      *
-     * @see CameraDevice.CaptureListener#onCaptureSequenceCompleted
-     * @see CameraDevice.CaptureListener#onCaptureSequenceAborted
+     * @see CameraDevice.CaptureCallback#onCaptureSequenceCompleted
+     * @see CameraDevice.CaptureCallback#onCaptureSequenceAborted
      */
     public int getSequenceId() {
         return mSequenceId;
@@ -420,7 +420,7 @@
     /**
      * <p>Mode of operation for the chromatic aberration correction algorithm.</p>
      * <p>This must be set to a valid mode from
-     * {@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES android.colorCorrection.availableAberrationCorrectionModes}.</p>
+     * {@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES android.colorCorrection.availableAberrationModes}.</p>
      * <p>Chromatic (color) aberration is caused by the fact that different wavelengths of light
      * can not focus on the same point after exiting from the lens. This metadata defines
      * the high level control of chromatic aberration correction algorithm, which aims to
@@ -432,14 +432,14 @@
      * capture rate. FAST means the camera device will not slow down capture rate when
      * applying aberration correction.</p>
      *
-     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_OFF
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_FAST
-     * @see #COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_HIGH_QUALITY
+     * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_OFF
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_FAST
+     * @see #COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY
      */
     @PublicKey
-    public static final Key<Integer> COLOR_CORRECTION_ABERRATION_CORRECTION_MODE =
-            new Key<Integer>("android.colorCorrection.aberrationCorrectionMode", int.class);
+    public static final Key<Integer> COLOR_CORRECTION_ABERRATION_MODE =
+            new Key<Integer>("android.colorCorrection.aberrationMode", int.class);
 
     /**
      * <p>The desired setting for the camera device's auto-exposure
@@ -582,6 +582,8 @@
     /**
      * <p>List of areas to use for
      * metering.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AE android.control.maxRegionsAe} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -597,7 +599,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AE
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
@@ -870,6 +874,8 @@
     /**
      * <p>List of areas to use for focus
      * estimation.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AF android.control.maxRegionsAf} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -885,7 +891,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AF
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
@@ -1369,6 +1377,8 @@
     /**
      * <p>List of areas to use for illuminant
      * estimation.</p>
+     * <p>Optional. Not available if {@link CameraCharacteristics#CONTROL_MAX_REGIONS_AWB android.control.maxRegionsAwb} is 0.
+     * Otherwise will always be present.</p>
      * <p>The coordinate system is based on the active pixel array,
      * with (0,0) being the top-left pixel in the active pixel array, and
      * ({@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.width - 1,
@@ -1384,7 +1394,9 @@
      * outside the used {@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion} returned in capture result metadata,
      * the camera device will ignore the sections outside the region and output the
      * used sections in the result metadata.</p>
+     * <p><b>Optional</b> - This value may be {@code null} on some devices.</p>
      *
+     * @see CameraCharacteristics#CONTROL_MAX_REGIONS_AWB
      * @see CaptureRequest#SCALER_CROP_REGION
      * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
      */
diff --git a/core/java/android/hardware/camera2/ICameraDeviceCallbacks.aidl b/core/java/android/hardware/camera2/ICameraDeviceCallbacks.aidl
index caabed3..ca0935c 100644
--- a/core/java/android/hardware/camera2/ICameraDeviceCallbacks.aidl
+++ b/core/java/android/hardware/camera2/ICameraDeviceCallbacks.aidl
@@ -26,8 +26,8 @@
      * Keep up-to-date with frameworks/av/include/camera/camera2/ICameraDeviceCallbacks.h
      */
 
-    oneway void onCameraError(int errorCode, in CaptureResultExtras resultExtras);
-    oneway void onCameraIdle();
+    oneway void onDeviceError(int errorCode, in CaptureResultExtras resultExtras);
+    oneway void onDeviceIdle();
     oneway void onCaptureStarted(in CaptureResultExtras resultExtras, long timestamp);
     oneway void onResultReceived(in CameraMetadataNative result,
                                  in CaptureResultExtras resultExtras);
diff --git a/core/java/android/hardware/camera2/TotalCaptureResult.java b/core/java/android/hardware/camera2/TotalCaptureResult.java
index ec4bc7d..6f7dd78 100644
--- a/core/java/android/hardware/camera2/TotalCaptureResult.java
+++ b/core/java/android/hardware/camera2/TotalCaptureResult.java
@@ -19,6 +19,7 @@
 import android.hardware.camera2.impl.CameraMetadataNative;
 import android.hardware.camera2.impl.CaptureResultExtras;
 
+import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 
@@ -44,17 +45,27 @@
  *
  * <p>{@link TotalCaptureResult} objects are immutable.</p>
  *
- * @see CameraDevice.CaptureListener#onCaptureCompleted
+ * @see CameraDevice.CaptureCallback#onCaptureCompleted
  */
 public final class TotalCaptureResult extends CaptureResult {
 
+    private final List<CaptureResult> mPartialResults;
+
     /**
-     * Takes ownership of the passed-in properties object
+     * Takes ownership of the passed-in camera metadata and the partial results
+     *
+     * @param partials a list of partial results; {@code null} will be substituted for an empty list
      * @hide
      */
     public TotalCaptureResult(CameraMetadataNative results, CaptureRequest parent,
-            CaptureResultExtras extras) {
+            CaptureResultExtras extras, List<CaptureResult> partials) {
         super(results, parent, extras);
+
+        if (partials == null) {
+            mPartialResults = new ArrayList<>();
+        } else {
+            mPartialResults = partials;
+        }
     }
 
     /**
@@ -65,6 +76,8 @@
      */
     public TotalCaptureResult(CameraMetadataNative results, int sequenceId) {
         super(results, sequenceId);
+
+        mPartialResults = new ArrayList<>();
     }
 
     /**
@@ -73,14 +86,13 @@
      * <p>The list is returned is unmodifiable; attempting to modify it will result in a
      * {@code UnsupportedOperationException} being thrown.</p>
      *
-     * <p>The list size will be inclusive between {@code 1} and
-     * {@link CameraCharacteristics#REQUEST_PARTIAL_RESULT_COUNT}, in ascending order
-     * of when {@link CameraCaptureSession.CaptureListener#onCaptureProgressed} was invoked.</p>
+     * <p>The list size will be inclusive between {@code 0} and
+     * {@link CameraCharacteristics#REQUEST_PARTIAL_RESULT_COUNT}, with elements in ascending order
+     * of when {@link CameraCaptureSession.CaptureCallback#onCaptureProgressed} was invoked.</p>
      *
      * @return unmodifiable list of partial results
      */
     public List<CaptureResult> getPartialResults() {
-        // TODO
-        return Collections.unmodifiableList(null);
+        return Collections.unmodifiableList(mPartialResults);
     }
 }
diff --git a/core/java/android/hardware/camera2/dispatch/MethodNameInvoker.java b/core/java/android/hardware/camera2/dispatch/MethodNameInvoker.java
index 02c3d87..c66a3a4 100644
--- a/core/java/android/hardware/camera2/dispatch/MethodNameInvoker.java
+++ b/core/java/android/hardware/camera2/dispatch/MethodNameInvoker.java
@@ -48,7 +48,8 @@
     /**
      * Invoke a method by its name.
      *
-     * <p>If more than one method exists in {@code targetClass}, the first method will be used.</p>
+     * <p>If more than one method exists in {@code targetClass}, the first method with the right
+     * number of arguments will be used, and later calls will all use that method.</p>
      *
      * @param methodName
      *          The name of the method, which will be matched 1:1 to the destination method
@@ -68,8 +69,9 @@
         Method targetMethod = mMethods.get(methodName);
         if (targetMethod == null) {
             for (Method method : mTargetClass.getMethods()) {
-                // TODO future: match by # of params and types of params if possible
-                if (method.getName().equals(methodName)) {
+                // TODO future: match types of params if possible
+                if (method.getName().equals(methodName) &&
+                        (params.length == method.getParameterTypes().length) ) {
                     targetMethod = method;
                     mMethods.put(methodName, targetMethod);
                     break;
diff --git a/core/java/android/hardware/camera2/impl/CallbackProxies.java b/core/java/android/hardware/camera2/impl/CallbackProxies.java
new file mode 100644
index 0000000..f0217ac
--- /dev/null
+++ b/core/java/android/hardware/camera2/impl/CallbackProxies.java
@@ -0,0 +1,183 @@
+/*
+ * Copyright (C) 2014 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 android.hardware.camera2.impl;
+
+import android.hardware.camera2.CameraCaptureSession;
+import android.hardware.camera2.CameraDevice;
+import android.hardware.camera2.CaptureFailure;
+import android.hardware.camera2.CaptureRequest;
+import android.hardware.camera2.CaptureResult;
+import android.hardware.camera2.TotalCaptureResult;
+import android.hardware.camera2.dispatch.Dispatchable;
+import android.hardware.camera2.dispatch.MethodNameInvoker;
+
+import static com.android.internal.util.Preconditions.*;
+
+/**
+ * Proxy out invocations to the camera2 API callbacks into a {@link Dispatchable}.
+ *
+ * <p>Since abstract classes do not support Java's dynamic {@code Proxy}, we have to
+ * to use our own proxy mechanism.</p>
+ */
+public class CallbackProxies {
+
+    // TODO: replace with codegen
+
+    public static class DeviceStateCallbackProxy extends CameraDeviceImpl.StateCallbackKK {
+        private final MethodNameInvoker<CameraDeviceImpl.StateCallbackKK> mProxy;
+
+        public DeviceStateCallbackProxy(
+                Dispatchable<CameraDeviceImpl.StateCallbackKK> dispatchTarget) {
+            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
+            mProxy = new MethodNameInvoker<>(dispatchTarget, CameraDeviceImpl.StateCallbackKK.class);
+        }
+
+        @Override
+        public void onOpened(CameraDevice camera) {
+            mProxy.invoke("onOpened", camera);
+        }
+
+        @Override
+        public void onDisconnected(CameraDevice camera) {
+            mProxy.invoke("onDisconnected", camera);
+        }
+
+        @Override
+        public void onError(CameraDevice camera, int error) {
+            mProxy.invoke("onError", camera, error);
+        }
+
+        @Override
+        public void onUnconfigured(CameraDevice camera) {
+            mProxy.invoke("onUnconfigured", camera);
+        }
+
+        @Override
+        public void onActive(CameraDevice camera) {
+            mProxy.invoke("onActive", camera);
+        }
+
+        @Override
+        public void onBusy(CameraDevice camera) {
+            mProxy.invoke("onBusy", camera);
+        }
+
+        @Override
+        public void onClosed(CameraDevice camera) {
+            mProxy.invoke("onClosed", camera);
+        }
+
+        @Override
+        public void onIdle(CameraDevice camera) {
+            mProxy.invoke("onIdle", camera);
+        }
+    }
+
+    @SuppressWarnings("deprecation")
+    public static class DeviceCaptureCallbackProxy extends CameraDeviceImpl.CaptureCallback {
+        private final MethodNameInvoker<CameraDeviceImpl.CaptureCallback> mProxy;
+
+        public DeviceCaptureCallbackProxy(
+                Dispatchable<CameraDeviceImpl.CaptureCallback> dispatchTarget) {
+            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
+            mProxy = new MethodNameInvoker<>(dispatchTarget, CameraDeviceImpl.CaptureCallback.class);
+        }
+
+        @Override
+        public void onCaptureStarted(CameraDevice camera,
+                CaptureRequest request, long timestamp, long frameNumber) {
+            mProxy.invoke("onCaptureStarted", camera, request, timestamp, frameNumber);
+        }
+
+        @Override
+        public void onCapturePartial(CameraDevice camera,
+                CaptureRequest request, CaptureResult result) {
+            mProxy.invoke("onCapturePartial", camera, request, result);
+        }
+
+        @Override
+        public void onCaptureProgressed(CameraDevice camera,
+                CaptureRequest request, CaptureResult partialResult) {
+            mProxy.invoke("onCaptureProgressed", camera, request, partialResult);
+        }
+
+        @Override
+        public void onCaptureCompleted(CameraDevice camera,
+                CaptureRequest request, TotalCaptureResult result) {
+            mProxy.invoke("onCaptureCompleted", camera, request, result);
+        }
+
+        @Override
+        public void onCaptureFailed(CameraDevice camera,
+                CaptureRequest request, CaptureFailure failure) {
+            mProxy.invoke("onCaptureFailed", camera, request, failure);
+        }
+
+        @Override
+        public void onCaptureSequenceCompleted(CameraDevice camera,
+                int sequenceId, long frameNumber) {
+            mProxy.invoke("onCaptureSequenceCompleted", camera, sequenceId, frameNumber);
+        }
+
+        @Override
+        public void onCaptureSequenceAborted(CameraDevice camera,
+                int sequenceId) {
+            mProxy.invoke("onCaptureSequenceAborted", camera, sequenceId);
+        }
+    }
+
+    public static class SessionStateCallbackProxy
+            extends CameraCaptureSession.StateCallback {
+        private final MethodNameInvoker<CameraCaptureSession.StateCallback> mProxy;
+
+        public SessionStateCallbackProxy(
+                Dispatchable<CameraCaptureSession.StateCallback> dispatchTarget) {
+            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
+            mProxy = new MethodNameInvoker<>(dispatchTarget,
+                    CameraCaptureSession.StateCallback.class);
+        }
+
+        @Override
+        public void onConfigured(CameraCaptureSession session) {
+            mProxy.invoke("onConfigured", session);
+        }
+
+
+        @Override
+        public void onConfigureFailed(CameraCaptureSession session) {
+            mProxy.invoke("onConfigureFailed", session);
+        }
+
+        @Override
+        public void onReady(CameraCaptureSession session) {
+            mProxy.invoke("onReady", session);
+        }
+
+        @Override
+        public void onActive(CameraCaptureSession session) {
+            mProxy.invoke("onActive", session);
+        }
+
+        @Override
+        public void onClosed(CameraCaptureSession session) {
+            mProxy.invoke("onClosed", session);
+        }
+    }
+
+    private CallbackProxies() {
+        throw new AssertionError();
+    }
+}
diff --git a/core/java/android/hardware/camera2/impl/CameraCaptureSessionImpl.java b/core/java/android/hardware/camera2/impl/CameraCaptureSessionImpl.java
index a15028c..b9507d7 100644
--- a/core/java/android/hardware/camera2/impl/CameraCaptureSessionImpl.java
+++ b/core/java/android/hardware/camera2/impl/CameraCaptureSessionImpl.java
@@ -42,14 +42,18 @@
     private static final String TAG = "CameraCaptureSession";
     private static final boolean VERBOSE = Log.isLoggable(TAG, Log.VERBOSE);
 
+    /** Simple integer ID for session for debugging */
+    private final int mId;
+    private final String mIdString;
+
     /** User-specified set of surfaces used as the configuration outputs */
     private final List<Surface> mOutputs;
     /**
-     * User-specified state listener, used for outgoing events; calls to this object will be
+     * User-specified state callback, used for outgoing events; calls to this object will be
      * automatically {@link Handler#post(Runnable) posted} to {@code mStateHandler}.
      */
-    private final CameraCaptureSession.StateListener mStateListener;
-    /** User-specified state handler used for outgoing state listener events */
+    private final CameraCaptureSession.StateCallback mStateCallback;
+    /** User-specified state handler used for outgoing state callback events */
     private final Handler mStateHandler;
 
     /** Internal camera device; used to translate calls into existing deprecated API */
@@ -68,11 +72,13 @@
 
     /** This session is closed; all further calls will throw ISE */
     private boolean mClosed = false;
+    /** This session failed to be configured successfully */
+    private final boolean mConfigureSuccess;
     /** Do not unconfigure if this is set; another session will overwrite configuration */
     private boolean mSkipUnconfigure = false;
 
     /** Is the session in the process of aborting? Pay attention to BUSY->IDLE transitions. */
-    private boolean mAborting;
+    private volatile boolean mAborting;
 
     /**
      * Create a new CameraCaptureSession.
@@ -81,29 +87,32 @@
      * There must be no pending actions
      * (e.g. no pending captures, no repeating requests, no flush).</p>
      */
-    CameraCaptureSessionImpl(List<Surface> outputs,
-            CameraCaptureSession.StateListener listener, Handler stateHandler,
+    CameraCaptureSessionImpl(int id, List<Surface> outputs,
+            CameraCaptureSession.StateCallback callback, Handler stateHandler,
             android.hardware.camera2.impl.CameraDeviceImpl deviceImpl,
             Handler deviceStateHandler, boolean configureSuccess) {
         if (outputs == null || outputs.isEmpty()) {
             throw new IllegalArgumentException("outputs must be a non-null, non-empty list");
-        } else if (listener == null) {
-            throw new IllegalArgumentException("listener must not be null");
+        } else if (callback == null) {
+            throw new IllegalArgumentException("callback must not be null");
         }
 
+        mId = id;
+        mIdString = String.format("Session %d: ", mId);
+
         // TODO: extra verification of outputs
         mOutputs = outputs;
         mStateHandler = checkHandler(stateHandler);
-        mStateListener = createUserStateListenerProxy(mStateHandler, listener);
+        mStateCallback = createUserStateCallbackProxy(mStateHandler, callback);
 
         mDeviceHandler = checkNotNull(deviceStateHandler, "deviceStateHandler must not be null");
         mDeviceImpl = checkNotNull(deviceImpl, "deviceImpl must not be null");
 
         /*
-         * Use the same handler as the device's StateListener for all the internal coming events
+         * Use the same handler as the device's StateCallback for all the internal coming events
          *
-         * This ensures total ordering between CameraDevice.StateListener and
-         * CameraDeviceImpl.CaptureListener events.
+         * This ensures total ordering between CameraDevice.StateCallback and
+         * CameraDeviceImpl.CaptureCallback events.
          */
         mSequenceDrainer = new TaskDrainer<>(mDeviceHandler, new SequenceDrainListener(),
                 /*name*/"seq");
@@ -117,12 +126,14 @@
         // CameraDevice should call configureOutputs and have it finish before constructing us
 
         if (configureSuccess) {
-            mStateListener.onConfigured(this);
-            if (VERBOSE) Log.v(TAG, "ctor - Created session successfully");
+            mStateCallback.onConfigured(this);
+            if (VERBOSE) Log.v(TAG, mIdString + "Created session successfully");
+            mConfigureSuccess = true;
         } else {
-            mStateListener.onConfigureFailed(this);
+            mStateCallback.onConfigureFailed(this);
             mClosed = true; // do not fire any other callbacks, do not allow any other work
-            Log.e(TAG, "Failed to create capture session; configuration failed");
+            Log.e(TAG, mIdString + "Failed to create capture session; configuration failed");
+            mConfigureSuccess = false;
         }
     }
 
@@ -132,28 +143,27 @@
     }
 
     @Override
-    public synchronized int capture(CaptureRequest request, CaptureListener listener,
+    public synchronized int capture(CaptureRequest request, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         if (request == null) {
             throw new IllegalArgumentException("request must not be null");
         }
 
         checkNotClosed();
-        checkLegalToCapture();
 
-        handler = checkHandler(handler, listener);
+        handler = checkHandler(handler, callback);
 
         if (VERBOSE) {
-            Log.v(TAG, "capture - request " + request + ", listener " + listener + " handler" +
-                    " " + handler);
+            Log.v(TAG, mIdString + "capture - request " + request + ", callback " + callback +
+                    " handler " + handler);
         }
 
         return addPendingSequence(mDeviceImpl.capture(request,
-                createCaptureListenerProxy(handler, listener), mDeviceHandler));
+                createCaptureCallbackProxy(handler, callback), mDeviceHandler));
     }
 
     @Override
-    public synchronized int captureBurst(List<CaptureRequest> requests, CaptureListener listener,
+    public synchronized int captureBurst(List<CaptureRequest> requests, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         if (requests == null) {
             throw new IllegalArgumentException("requests must not be null");
@@ -162,44 +172,42 @@
         }
 
         checkNotClosed();
-        checkLegalToCapture();
 
-        handler = checkHandler(handler, listener);
+        handler = checkHandler(handler, callback);
 
         if (VERBOSE) {
             CaptureRequest[] requestArray = requests.toArray(new CaptureRequest[0]);
-            Log.v(TAG, "captureBurst - requests " + Arrays.toString(requestArray) + ", listener " +
-                    listener + " handler" + "" + handler);
+            Log.v(TAG, mIdString + "captureBurst - requests " + Arrays.toString(requestArray) +
+                    ", callback " + callback + " handler " + handler);
         }
 
         return addPendingSequence(mDeviceImpl.captureBurst(requests,
-                createCaptureListenerProxy(handler, listener), mDeviceHandler));
+                createCaptureCallbackProxy(handler, callback), mDeviceHandler));
     }
 
     @Override
-    public synchronized int setRepeatingRequest(CaptureRequest request, CaptureListener listener,
+    public synchronized int setRepeatingRequest(CaptureRequest request, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         if (request == null) {
             throw new IllegalArgumentException("request must not be null");
         }
 
         checkNotClosed();
-        checkLegalToCapture();
 
-        handler = checkHandler(handler, listener);
+        handler = checkHandler(handler, callback);
 
         if (VERBOSE) {
-            Log.v(TAG, "setRepeatingRequest - request " + request + ", listener " + listener +
-                    " handler" + " " + handler);
+            Log.v(TAG, mIdString + "setRepeatingRequest - request " + request + ", callback " +
+                    callback + " handler" + " " + handler);
         }
 
         return addPendingSequence(mDeviceImpl.setRepeatingRequest(request,
-                createCaptureListenerProxy(handler, listener), mDeviceHandler));
+                createCaptureCallbackProxy(handler, callback), mDeviceHandler));
     }
 
     @Override
     public synchronized int setRepeatingBurst(List<CaptureRequest> requests,
-            CaptureListener listener, Handler handler) throws CameraAccessException {
+            CaptureCallback callback, Handler handler) throws CameraAccessException {
         if (requests == null) {
             throw new IllegalArgumentException("requests must not be null");
         } else if (requests.isEmpty()) {
@@ -207,18 +215,17 @@
         }
 
         checkNotClosed();
-        checkLegalToCapture();
 
-        handler = checkHandler(handler, listener);
+        handler = checkHandler(handler, callback);
 
         if (VERBOSE) {
             CaptureRequest[] requestArray = requests.toArray(new CaptureRequest[0]);
-            Log.v(TAG, "setRepeatingBurst - requests " + Arrays.toString(requestArray) +
-                    ", listener " + listener + " handler" + "" + handler);
+            Log.v(TAG, mIdString + "setRepeatingBurst - requests " + Arrays.toString(requestArray) +
+                    ", callback " + callback + " handler" + "" + handler);
         }
 
         return addPendingSequence(mDeviceImpl.setRepeatingBurst(requests,
-                createCaptureListenerProxy(handler, listener), mDeviceHandler));
+                createCaptureCallbackProxy(handler, callback), mDeviceHandler));
     }
 
     @Override
@@ -226,7 +233,7 @@
         checkNotClosed();
 
         if (VERBOSE) {
-            Log.v(TAG, "stopRepeating");
+            Log.v(TAG, mIdString + "stopRepeating");
         }
 
         mDeviceImpl.stopRepeating();
@@ -237,11 +244,11 @@
         checkNotClosed();
 
         if (VERBOSE) {
-            Log.v(TAG, "abortCaptures");
+            Log.v(TAG, mIdString + "abortCaptures");
         }
 
         if (mAborting) {
-            Log.w(TAG, "abortCaptures - Session is already aborting; doing nothing");
+            Log.w(TAG, mIdString + "abortCaptures - Session is already aborting; doing nothing");
             return;
         }
 
@@ -279,15 +286,15 @@
          * but this would introduce nondeterministic behavior.
          */
 
-        if (VERBOSE) Log.v(TAG, "replaceSessionClose");
+        if (VERBOSE) Log.v(TAG, mIdString + "replaceSessionClose");
 
         // Set up fast shutdown. Possible alternative paths:
         // - This session is active, so close() below starts the shutdown drain
         // - This session is mid-shutdown drain, and hasn't yet reached the idle drain listener.
         // - This session is already closed and has executed the idle drain listener, and
-        //   configureOutputs(null) has already been called.
+        //   configureOutputsChecked(null) has already been called.
         //
-        // Do not call configureOutputs(null) going forward, since it would race with the
+        // Do not call configureOutputsChecked(null) going forward, since it would race with the
         // configuration for the new session. If it was already called, then we don't care, since it
         // won't get called again.
         mSkipUnconfigure = true;
@@ -299,11 +306,11 @@
     public synchronized void close() {
 
         if (mClosed) {
-            if (VERBOSE) Log.v(TAG, "close - reentering");
+            if (VERBOSE) Log.v(TAG, mIdString + "close - reentering");
             return;
         }
 
-        if (VERBOSE) Log.v(TAG, "close - first time");
+        if (VERBOSE) Log.v(TAG, mIdString + "close - first time");
 
         mClosed = true;
 
@@ -321,18 +328,18 @@
             mDeviceImpl.stopRepeating();
         } catch (IllegalStateException e) {
             // OK: Camera device may already be closed, nothing else to do
-            Log.w(TAG, "The camera device was already closed: ", e);
+            Log.w(TAG, mIdString + "The camera device was already closed: ", e);
 
             // TODO: Fire onClosed anytime we get the device onClosed or the ISE?
             // or just suppress the ISE only and rely onClosed.
             // Also skip any of the draining work if this is already closed.
 
-            // Short-circuit; queue listener immediately and return
-            mStateListener.onClosed(this);
+            // Short-circuit; queue callback immediately and return
+            mStateCallback.onClosed(this);
             return;
         } catch (CameraAccessException e) {
             // OK: close does not throw checked exceptions.
-            Log.e(TAG, "Exception while stopping repeating: ", e);
+            Log.e(TAG, mIdString + "Exception while stopping repeating: ", e);
 
             // TODO: call onError instead of onClosed if this happens
         }
@@ -342,30 +349,44 @@
     }
 
     /**
-     * Post calls into a CameraCaptureSession.StateListener to the user-specified {@code handler}.
+     * Whether currently in mid-abort.
+     *
+     * <p>This is used by the implementation to set the capture failure
+     * reason, in lieu of more accurate error codes from the camera service.
+     * Unsynchronized to avoid deadlocks between simultaneous session->device,
+     * device->session calls.</p>
+     *
+     * <p>Package-private.</p>
      */
-    private StateListener createUserStateListenerProxy(Handler handler, StateListener listener) {
-        InvokeDispatcher<StateListener> userListenerSink = new InvokeDispatcher<>(listener);
-        HandlerDispatcher<StateListener> handlerPassthrough =
-                new HandlerDispatcher<>(userListenerSink, handler);
+    boolean isAborting() {
+        return mAborting;
+    }
 
-        return new ListenerProxies.SessionStateListenerProxy(handlerPassthrough);
+    /**
+     * Post calls into a CameraCaptureSession.StateCallback to the user-specified {@code handler}.
+     */
+    private StateCallback createUserStateCallbackProxy(Handler handler, StateCallback callback) {
+        InvokeDispatcher<StateCallback> userCallbackSink = new InvokeDispatcher<>(callback);
+        HandlerDispatcher<StateCallback> handlerPassthrough =
+                new HandlerDispatcher<>(userCallbackSink, handler);
+
+        return new CallbackProxies.SessionStateCallbackProxy(handlerPassthrough);
     }
 
     /**
      * Forward callbacks from
-     * CameraDeviceImpl.CaptureListener to the CameraCaptureSession.CaptureListener.
+     * CameraDeviceImpl.CaptureCallback to the CameraCaptureSession.CaptureCallback.
      *
      * <p>In particular, all calls are automatically split to go both to our own
-     * internal listener, and to the user-specified listener (by transparently posting
+     * internal callback, and to the user-specified callback (by transparently posting
      * to the user-specified handler).</p>
      *
      * <p>When a capture sequence finishes, update the pending checked sequences set.</p>
      */
     @SuppressWarnings("deprecation")
-    private CameraDeviceImpl.CaptureListener createCaptureListenerProxy(
-            Handler handler, CaptureListener listener) {
-        CameraDeviceImpl.CaptureListener localListener = new CameraDeviceImpl.CaptureListener() {
+    private CameraDeviceImpl.CaptureCallback createCaptureCallbackProxy(
+            Handler handler, CaptureCallback callback) {
+        CameraDeviceImpl.CaptureCallback localCallback = new CameraDeviceImpl.CaptureCallback() {
             @Override
             public void onCaptureSequenceCompleted(CameraDevice camera,
                     int sequenceId, long frameNumber) {
@@ -380,43 +401,43 @@
         };
 
         /*
-         * Split the calls from the device listener into local listener and the following chain:
+         * Split the calls from the device callback into local callback and the following chain:
          * - replace the first CameraDevice arg with a CameraCaptureSession
-         * - duck type from device listener to session listener
+         * - duck type from device callback to session callback
          * - then forward the call to a handler
-         * - then finally invoke the destination method on the session listener object
+         * - then finally invoke the destination method on the session callback object
          */
-        if (listener == null) {
-            // OK: API allows the user to not specify a listener, and the handler may
+        if (callback == null) {
+            // OK: API allows the user to not specify a callback, and the handler may
             // also be null in that case. Collapse whole dispatch chain to only call the local
-            // listener
-            return localListener;
+            // callback
+            return localCallback;
         }
 
-        InvokeDispatcher<CameraDeviceImpl.CaptureListener> localSink =
-                new InvokeDispatcher<>(localListener);
+        InvokeDispatcher<CameraDeviceImpl.CaptureCallback> localSink =
+                new InvokeDispatcher<>(localCallback);
 
-        InvokeDispatcher<CaptureListener> userListenerSink =
-                new InvokeDispatcher<>(listener);
-        HandlerDispatcher<CaptureListener> handlerPassthrough =
-                new HandlerDispatcher<>(userListenerSink, handler);
-        DuckTypingDispatcher<CameraDeviceImpl.CaptureListener, CaptureListener> duckToSession
-                = new DuckTypingDispatcher<>(handlerPassthrough, CaptureListener.class);
-        ArgumentReplacingDispatcher<CameraDeviceImpl.CaptureListener, CameraCaptureSessionImpl>
+        InvokeDispatcher<CaptureCallback> userCallbackSink =
+                new InvokeDispatcher<>(callback);
+        HandlerDispatcher<CaptureCallback> handlerPassthrough =
+                new HandlerDispatcher<>(userCallbackSink, handler);
+        DuckTypingDispatcher<CameraDeviceImpl.CaptureCallback, CaptureCallback> duckToSession
+                = new DuckTypingDispatcher<>(handlerPassthrough, CaptureCallback.class);
+        ArgumentReplacingDispatcher<CameraDeviceImpl.CaptureCallback, CameraCaptureSessionImpl>
                 replaceDeviceWithSession = new ArgumentReplacingDispatcher<>(duckToSession,
                         /*argumentIndex*/0, this);
 
-        BroadcastDispatcher<CameraDeviceImpl.CaptureListener> broadcaster =
-                new BroadcastDispatcher<CameraDeviceImpl.CaptureListener>(
+        BroadcastDispatcher<CameraDeviceImpl.CaptureCallback> broadcaster =
+                new BroadcastDispatcher<CameraDeviceImpl.CaptureCallback>(
                     replaceDeviceWithSession,
                     localSink);
 
-        return new ListenerProxies.DeviceCaptureListenerProxy(broadcaster);
+        return new CallbackProxies.DeviceCaptureCallbackProxy(broadcaster);
     }
 
     /**
      *
-     * Create an internal state listener, to be invoked on the mDeviceHandler
+     * Create an internal state callback, to be invoked on the mDeviceHandler
      *
      * <p>It has a few behaviors:
      * <ul>
@@ -425,10 +446,10 @@
      * </ul>
      * </p>
      * */
-    CameraDeviceImpl.StateListenerKK getDeviceStateListener() {
+    CameraDeviceImpl.StateCallbackKK getDeviceStateCallback() {
         final CameraCaptureSession session = this;
 
-        return new CameraDeviceImpl.StateListenerKK() {
+        return new CameraDeviceImpl.StateCallbackKK() {
             private boolean mBusy = false;
             private boolean mActive = false;
 
@@ -439,13 +460,14 @@
 
             @Override
             public void onDisconnected(CameraDevice camera) {
+                if (VERBOSE) Log.v(TAG, mIdString + "onDisconnected");
                 close();
             }
 
             @Override
             public void onError(CameraDevice camera, int error) {
-                // TODO: Handle errors somehow.
-                Log.wtf(TAG, "Got device error " + error);
+                // Should not be reached, handled by device code
+                Log.wtf(TAG, mIdString + "Got device error " + error);
             }
 
             @Override
@@ -453,12 +475,15 @@
                 mIdleDrainer.taskStarted();
                 mActive = true;
 
-                mStateListener.onActive(session);
+                if (VERBOSE) Log.v(TAG, mIdString + "onActive");
+                mStateCallback.onActive(session);
             }
 
             @Override
             public void onIdle(CameraDevice camera) {
                 boolean isAborting;
+                if (VERBOSE) Log.v(TAG, mIdString + "onIdle");
+
                 synchronized (session) {
                     isAborting = mAborting;
                 }
@@ -489,7 +514,7 @@
                 mBusy = false;
                 mActive = false;
 
-                mStateListener.onReady(session);
+                mStateCallback.onReady(session);
             }
 
             @Override
@@ -498,15 +523,30 @@
 
                 // TODO: Queue captures during abort instead of failing them
                 // since the app won't be able to distinguish the two actives
-                Log.w(TAG, "Device is now busy; do not submit new captures (TODO: allow this)");
-                mStateListener.onActive(session);
+                // Don't signal the application since there's no clean mapping here
+                if (VERBOSE) Log.v(TAG, mIdString + "onBusy");
             }
 
             @Override
             public void onUnconfigured(CameraDevice camera) {
+                if (VERBOSE) Log.v(TAG, mIdString + "onUnconfigured");
                 synchronized (session) {
-                    // Ignore #onUnconfigured before #close is called
-                    if (mClosed) {
+                    // Ignore #onUnconfigured before #close is called.
+                    //
+                    // Normally, this is reached when this session is closed and no immediate other
+                    // activity happens for the camera, in which case the camera is configured to
+                    // null streams by this session and the UnconfigureDrainer task is started.
+                    // However, we can also end up here if
+                    //
+                    // 1) Session is closed
+                    // 2) New session is created before this session finishes closing, setting
+                    //    mSkipUnconfigure and therefore this session does not configure null or
+                    //    start the UnconfigureDrainer task.
+                    // 3) And then the new session fails to be created, so onUnconfigured fires
+                    //    _anyway_.
+                    // In this second case, need to not finish a task that was never started, so
+                    // guard with mSkipUnconfigure
+                    if (mClosed && mConfigureSuccess && !mSkipUnconfigure) {
                         mUnconfigureDrainer.taskFinished();
                     }
                 }
@@ -524,13 +564,6 @@
         }
     }
 
-    private void checkLegalToCapture() {
-        if (mAborting) {
-            throw new IllegalStateException(
-                    "Session is aborting captures; new captures are not permitted");
-        }
-    }
-
     private void checkNotClosed() {
         if (mClosed) {
             throw new IllegalStateException(
@@ -573,6 +606,7 @@
              * If the camera is already "IDLE" and no aborts are pending,
              * then the drain immediately finishes.
              */
+            if (VERBOSE) Log.v(TAG, mIdString + "onSequenceDrained");
             mAbortDrainer.beginDrain();
         }
     }
@@ -580,6 +614,7 @@
     private class AbortDrainListener implements TaskDrainer.DrainListener {
         @Override
         public void onDrained() {
+            if (VERBOSE) Log.v(TAG, mIdString + "onAbortDrained");
             synchronized (CameraCaptureSessionImpl.this) {
                 /*
                  * Any queued aborts have now completed.
@@ -597,6 +632,7 @@
     private class IdleDrainListener implements TaskDrainer.DrainListener {
         @Override
         public void onDrained() {
+            if (VERBOSE) Log.v(TAG, mIdString + "onIdleDrained");
             synchronized (CameraCaptureSessionImpl.this) {
                 /*
                  * The device is now IDLE, and has settled. It will not transition to
@@ -606,12 +642,12 @@
                  *
                  * This operation is idempotent; a session will not be closed twice.
                  */
-                if (VERBOSE) Log.v(TAG, "Session drain complete, skip unconfigure: " +
+                if (VERBOSE) Log.v(TAG, mIdString + "Session drain complete, skip unconfigure: " +
                         mSkipUnconfigure);
 
                 // Fast path: A new capture session has replaced this one; don't unconfigure.
                 if (mSkipUnconfigure) {
-                    mStateListener.onClosed(CameraCaptureSessionImpl.this);
+                    mStateCallback.onClosed(CameraCaptureSessionImpl.this);
                     return;
                 }
 
@@ -619,10 +655,10 @@
 
                 try {
                     mUnconfigureDrainer.taskStarted();
-                    mDeviceImpl.configureOutputs(null); // begin transition to unconfigured state
+                    mDeviceImpl.configureOutputsChecked(null); // begin transition to unconfigured
                 } catch (CameraAccessException e) {
                     // OK: do not throw checked exceptions.
-                    Log.e(TAG, "Exception while configuring outputs: ", e);
+                    Log.e(TAG, mIdString + "Exception while configuring outputs: ", e);
 
                     // TODO: call onError instead of onClosed if this happens
                 }
@@ -634,10 +670,12 @@
 
     private class UnconfigureDrainListener implements TaskDrainer.DrainListener {
         @Override
+
         public void onDrained() {
+            if (VERBOSE) Log.v(TAG, mIdString + "onUnconfigureDrained");
             synchronized (CameraCaptureSessionImpl.this) {
                 // The device has finished unconfiguring. It's now fully closed.
-                mStateListener.onClosed(CameraCaptureSessionImpl.this);
+                mStateCallback.onClosed(CameraCaptureSessionImpl.this);
             }
         }
     }
diff --git a/core/java/android/hardware/camera2/impl/CameraDeviceImpl.java b/core/java/android/hardware/camera2/impl/CameraDeviceImpl.java
index 71eb0e9..1dc5533 100644
--- a/core/java/android/hardware/camera2/impl/CameraDeviceImpl.java
+++ b/core/java/android/hardware/camera2/impl/CameraDeviceImpl.java
@@ -41,6 +41,7 @@
 
 import java.util.AbstractMap.SimpleEntry;
 import java.util.ArrayList;
+import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
@@ -63,17 +64,17 @@
     private final Object mInterfaceLock = new Object();
     private final CameraDeviceCallbacks mCallbacks = new CameraDeviceCallbacks();
 
-    private final StateListener mDeviceListener;
-    private volatile StateListenerKK mSessionStateListener;
+    private final StateCallback mDeviceCallback;
+    private volatile StateCallbackKK mSessionStateCallback;
     private final Handler mDeviceHandler;
 
     private volatile boolean mClosing = false;
     private boolean mInError = false;
     private boolean mIdle = true;
 
-    /** map request IDs to listener/request data */
-    private final SparseArray<CaptureListenerHolder> mCaptureListenerMap =
-            new SparseArray<CaptureListenerHolder>();
+    /** map request IDs to callback/request data */
+    private final SparseArray<CaptureCallbackHolder> mCaptureCallbackMap =
+            new SparseArray<CaptureCallbackHolder>();
 
     private int mRepeatingRequestId = REQUEST_ID_NONE;
     private final ArrayList<Integer> mRepeatingRequestIdDeletedList = new ArrayList<Integer>();
@@ -98,6 +99,7 @@
     private final FrameNumberTracker mFrameNumberTracker = new FrameNumberTracker();
 
     private CameraCaptureSessionImpl mCurrentSession;
+    private int mNextSessionId = 0;
 
     // Runnables for all state transitions, except error, which needs the
     // error code argument
@@ -105,30 +107,30 @@
     private final Runnable mCallOnOpened = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onOpened(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onOpened(CameraDeviceImpl.this);
             }
-            mDeviceListener.onOpened(CameraDeviceImpl.this);
+            mDeviceCallback.onOpened(CameraDeviceImpl.this);
         }
     };
 
     private final Runnable mCallOnUnconfigured = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onUnconfigured(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onUnconfigured(CameraDeviceImpl.this);
             }
         }
     };
@@ -136,14 +138,14 @@
     private final Runnable mCallOnActive = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onActive(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onActive(CameraDeviceImpl.this);
             }
         }
     };
@@ -151,14 +153,14 @@
     private final Runnable mCallOnBusy = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onBusy(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onBusy(CameraDeviceImpl.this);
             }
         }
     };
@@ -171,14 +173,14 @@
             if (mClosedOnce) {
                 throw new AssertionError("Don't post #onClosed more than once");
             }
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onClosed(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onClosed(CameraDeviceImpl.this);
             }
-            mDeviceListener.onClosed(CameraDeviceImpl.this);
+            mDeviceCallback.onClosed(CameraDeviceImpl.this);
             mClosedOnce = true;
         }
     };
@@ -186,14 +188,14 @@
     private final Runnable mCallOnIdle = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onIdle(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onIdle(CameraDeviceImpl.this);
             }
         }
     };
@@ -201,26 +203,26 @@
     private final Runnable mCallOnDisconnected = new Runnable() {
         @Override
         public void run() {
-            StateListenerKK sessionListener = null;
+            StateCallbackKK sessionCallback = null;
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                sessionListener = mSessionStateListener;
+                sessionCallback = mSessionStateCallback;
             }
-            if (sessionListener != null) {
-                sessionListener.onDisconnected(CameraDeviceImpl.this);
+            if (sessionCallback != null) {
+                sessionCallback.onDisconnected(CameraDeviceImpl.this);
             }
-            mDeviceListener.onDisconnected(CameraDeviceImpl.this);
+            mDeviceCallback.onDisconnected(CameraDeviceImpl.this);
         }
     };
 
-    public CameraDeviceImpl(String cameraId, StateListener listener, Handler handler,
+    public CameraDeviceImpl(String cameraId, StateCallback callback, Handler handler,
                         CameraCharacteristics characteristics) {
-        if (cameraId == null || listener == null || handler == null || characteristics == null) {
+        if (cameraId == null || callback == null || handler == null || characteristics == null) {
             throw new IllegalArgumentException("Null argument given");
         }
         mCameraId = cameraId;
-        mDeviceListener = listener;
+        mDeviceCallback = callback;
         mDeviceHandler = handler;
         mCharacteristics = characteristics;
 
@@ -262,28 +264,28 @@
     /**
      * Call to indicate failed connection to a remote camera device.
      *
-     * <p>This places the camera device in the error state and informs the listener.
+     * <p>This places the camera device in the error state and informs the callback.
      * Use in place of setRemoteDevice() when startup fails.</p>
      */
     public void setRemoteFailure(final CameraRuntimeException failure) {
-        int failureCode = StateListener.ERROR_CAMERA_DEVICE;
+        int failureCode = StateCallback.ERROR_CAMERA_DEVICE;
         boolean failureIsError = true;
 
         switch (failure.getReason()) {
             case CameraAccessException.CAMERA_IN_USE:
-                failureCode = StateListener.ERROR_CAMERA_IN_USE;
+                failureCode = StateCallback.ERROR_CAMERA_IN_USE;
                 break;
             case CameraAccessException.MAX_CAMERAS_IN_USE:
-                failureCode = StateListener.ERROR_MAX_CAMERAS_IN_USE;
+                failureCode = StateCallback.ERROR_MAX_CAMERAS_IN_USE;
                 break;
             case CameraAccessException.CAMERA_DISABLED:
-                failureCode = StateListener.ERROR_CAMERA_DISABLED;
+                failureCode = StateCallback.ERROR_CAMERA_DISABLED;
                 break;
             case CameraAccessException.CAMERA_DISCONNECTED:
                 failureIsError = false;
                 break;
             case CameraAccessException.CAMERA_ERROR:
-                failureCode = StateListener.ERROR_CAMERA_DEVICE;
+                failureCode = StateCallback.ERROR_CAMERA_DEVICE;
                 break;
             default:
                 Log.wtf(TAG, "Unknown failure in opening camera device: " + failure.getReason());
@@ -297,9 +299,9 @@
                 @Override
                 public void run() {
                     if (isError) {
-                        mDeviceListener.onError(CameraDeviceImpl.this, code);
+                        mDeviceCallback.onError(CameraDeviceImpl.this, code);
                     } else {
-                        mDeviceListener.onDisconnected(CameraDeviceImpl.this);
+                        mDeviceCallback.onDisconnected(CameraDeviceImpl.this);
                     }
                 }
             });
@@ -312,10 +314,33 @@
     }
 
     public void configureOutputs(List<Surface> outputs) throws CameraAccessException {
+        // Leave this here for backwards compatibility with older code using this directly
+        configureOutputsChecked(outputs);
+    }
+
+    /**
+     * Attempt to configure the outputs; the device goes to idle and then configures the
+     * new outputs if possible.
+     *
+     * <p>The configuration may gracefully fail, if there are too many outputs, if the formats
+     * are not supported, or if the sizes for that format is not supported. In this case this
+     * function will return {@code false} and the unconfigured callback will be fired.</p>
+     *
+     * <p>If the configuration succeeds (with 1 or more outputs), then the idle callback is fired.
+     * Unconfiguring the device always fires the idle callback.</p>
+     *
+     * @param outputs a list of one or more surfaces, or {@code null} to unconfigure
+     * @return whether or not the configuration was successful
+     *
+     * @throws CameraAccessException if there were any unexpected problems during configuration
+     */
+    public boolean configureOutputsChecked(List<Surface> outputs) throws CameraAccessException {
         // Treat a null input the same an empty list
         if (outputs == null) {
             outputs = new ArrayList<Surface>();
         }
+        boolean success = false;
+
         synchronized(mInterfaceLock) {
             checkIfCameraClosedOrInError();
 
@@ -355,7 +380,17 @@
                     mConfiguredOutputs.put(streamId, s);
                 }
 
-                mRemoteDevice.endConfigure();
+                try {
+                    mRemoteDevice.endConfigure();
+                }
+                catch (IllegalArgumentException e) {
+                    // OK. camera service can reject stream config if it's not supported by HAL
+                    // This is only the result of a programmer misusing the camera2 api.
+                    Log.w(TAG, "Stream configuration failed");
+                    return false;
+                }
+
+                success = true;
             } catch (CameraRuntimeException e) {
                 if (e.getReason() == CAMERA_IN_USE) {
                     throw new IllegalStateException("The camera is currently busy." +
@@ -365,20 +400,23 @@
                 throw e.asChecked();
             } catch (RemoteException e) {
                 // impossible
-                return;
-            }
-
-            if (outputs.size() > 0) {
-                mDeviceHandler.post(mCallOnIdle);
-            } else {
-                mDeviceHandler.post(mCallOnUnconfigured);
+                return false;
+            } finally {
+                if (success && outputs.size() > 0) {
+                    mDeviceHandler.post(mCallOnIdle);
+                } else {
+                    // Always return to the 'unconfigured' state if we didn't hit a fatal error
+                    mDeviceHandler.post(mCallOnUnconfigured);
+                }
             }
         }
+
+        return success;
     }
 
     @Override
     public void createCaptureSession(List<Surface> outputs,
-            CameraCaptureSession.StateListener listener, Handler handler)
+            CameraCaptureSession.StateCallback callback, Handler handler)
             throws CameraAccessException {
         synchronized(mInterfaceLock) {
             if (DEBUG) {
@@ -397,7 +435,7 @@
             boolean configureSuccess = true;
             CameraAccessException pendingException = null;
             try {
-                configureOutputs(outputs); // and then block until IDLE
+                configureSuccess = configureOutputsChecked(outputs); // and then block until IDLE
             } catch (CameraAccessException e) {
                 configureSuccess = false;
                 pendingException = e;
@@ -408,7 +446,8 @@
 
             // Fire onConfigured if configureOutputs succeeded, fire onConfigureFailed otherwise.
             CameraCaptureSessionImpl newSession =
-                    new CameraCaptureSessionImpl(outputs, listener, handler, this, mDeviceHandler,
+                    new CameraCaptureSessionImpl(mNextSessionId++,
+                            outputs, callback, handler, this, mDeviceHandler,
                             configureSuccess);
 
             // TODO: wait until current session closes, then create the new session
@@ -418,16 +457,16 @@
                 throw pendingException;
             }
 
-            mSessionStateListener = mCurrentSession.getDeviceStateListener();
+            mSessionStateCallback = mCurrentSession.getDeviceStateCallback();
         }
     }
 
     /**
      * For use by backwards-compatibility code only.
      */
-    public void setSessionListener(StateListenerKK sessionListener) {
+    public void setSessionListener(StateCallbackKK sessionCallback) {
         synchronized(mInterfaceLock) {
-            mSessionStateListener = sessionListener;
+            mSessionStateCallback = sessionCallback;
         }
     }
 
@@ -455,22 +494,22 @@
         }
     }
 
-    public int capture(CaptureRequest request, CaptureListener listener, Handler handler)
+    public int capture(CaptureRequest request, CaptureCallback callback, Handler handler)
             throws CameraAccessException {
         if (DEBUG) {
             Log.d(TAG, "calling capture");
         }
         List<CaptureRequest> requestList = new ArrayList<CaptureRequest>();
         requestList.add(request);
-        return submitCaptureRequest(requestList, listener, handler, /*streaming*/false);
+        return submitCaptureRequest(requestList, callback, handler, /*streaming*/false);
     }
 
-    public int captureBurst(List<CaptureRequest> requests, CaptureListener listener,
+    public int captureBurst(List<CaptureRequest> requests, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         if (requests == null || requests.isEmpty()) {
             throw new IllegalArgumentException("At least one request must be given");
         }
-        return submitCaptureRequest(requests, listener, handler, /*streaming*/false);
+        return submitCaptureRequest(requests, callback, handler, /*streaming*/false);
     }
 
     /**
@@ -490,12 +529,12 @@
             final int requestId, final long lastFrameNumber) {
         // lastFrameNumber being equal to NO_FRAMES_CAPTURED means that the request
         // was never sent to HAL. Should trigger onCaptureSequenceAborted immediately.
-        if (lastFrameNumber == CaptureListener.NO_FRAMES_CAPTURED) {
-            final CaptureListenerHolder holder;
-            int index = mCaptureListenerMap.indexOfKey(requestId);
-            holder = (index >= 0) ? mCaptureListenerMap.valueAt(index) : null;
+        if (lastFrameNumber == CaptureCallback.NO_FRAMES_CAPTURED) {
+            final CaptureCallbackHolder holder;
+            int index = mCaptureCallbackMap.indexOfKey(requestId);
+            holder = (index >= 0) ? mCaptureCallbackMap.valueAt(index) : null;
             if (holder != null) {
-                mCaptureListenerMap.removeAt(index);
+                mCaptureCallbackMap.removeAt(index);
                 if (DEBUG) {
                     Log.v(TAG, String.format(
                             "remove holder for requestId %d, "
@@ -523,7 +562,7 @@
                                     || lastFrameNumber > Integer.MAX_VALUE) {
                                 throw new AssertionError(lastFrameNumber + " cannot be cast to int");
                             }
-                            holder.getListener().onCaptureSequenceAborted(
+                            holder.getCallback().onCaptureSequenceAborted(
                                     CameraDeviceImpl.this,
                                     requestId);
                         }
@@ -532,22 +571,25 @@
                 holder.getHandler().post(resultDispatch);
             } else {
                 Log.w(TAG, String.format(
-                        "did not register listener to request %d",
+                        "did not register callback to request %d",
                         requestId));
             }
         } else {
             mFrameNumberRequestPairs.add(
                     new SimpleEntry<Long, Integer>(lastFrameNumber,
                             requestId));
+            // It is possible that the last frame has already arrived, so we need to check
+            // for sequence completion right away
+            checkAndFireSequenceComplete();
         }
     }
 
-    private int submitCaptureRequest(List<CaptureRequest> requestList, CaptureListener listener,
+    private int submitCaptureRequest(List<CaptureRequest> requestList, CaptureCallback callback,
             Handler handler, boolean repeating) throws CameraAccessException {
 
         // Need a valid handler, or current thread needs to have a looper, if
-        // listener is valid
-        handler = checkHandler(handler, listener);
+        // callback is valid
+        handler = checkHandler(handler, callback);
 
         // Make sure that there all requests have at least 1 surface; all surfaces are non-null
         for (CaptureRequest request : requestList) {
@@ -585,8 +627,8 @@
                 return -1;
             }
 
-            if (listener != null) {
-                mCaptureListenerMap.put(requestId, new CaptureListenerHolder(listener,
+            if (callback != null) {
+                mCaptureCallbackMap.put(requestId, new CaptureCallbackHolder(callback,
                         requestList, handler, repeating));
             } else {
                 if (DEBUG) {
@@ -615,19 +657,19 @@
         }
     }
 
-    public int setRepeatingRequest(CaptureRequest request, CaptureListener listener,
+    public int setRepeatingRequest(CaptureRequest request, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         List<CaptureRequest> requestList = new ArrayList<CaptureRequest>();
         requestList.add(request);
-        return submitCaptureRequest(requestList, listener, handler, /*streaming*/true);
+        return submitCaptureRequest(requestList, callback, handler, /*streaming*/true);
     }
 
-    public int setRepeatingBurst(List<CaptureRequest> requests, CaptureListener listener,
+    public int setRepeatingBurst(List<CaptureRequest> requests, CaptureCallback callback,
             Handler handler) throws CameraAccessException {
         if (requests == null || requests.isEmpty()) {
             throw new IllegalArgumentException("At least one request must be given");
         }
-        return submitCaptureRequest(requests, listener, handler, /*streaming*/true);
+        return submitCaptureRequest(requests, callback, handler, /*streaming*/true);
     }
 
     public void stopRepeating() throws CameraAccessException {
@@ -640,7 +682,7 @@
                 mRepeatingRequestId = REQUEST_ID_NONE;
 
                 // Queue for deletion after in-flight requests finish
-                if (mCaptureListenerMap.get(requestId) != null) {
+                if (mCaptureCallbackMap.get(requestId) != null) {
                     mRepeatingRequestIdDeletedList.add(requestId);
                 }
 
@@ -685,6 +727,13 @@
             checkIfCameraClosedOrInError();
 
             mDeviceHandler.post(mCallOnBusy);
+
+            // If already idle, just do a busy->idle transition immediately, don't actually
+            // flush.
+            if (mIdle) {
+                mDeviceHandler.post(mCallOnIdle);
+                return;
+            }
             try {
                 LongParcelable lastFrameNumberRef = new LongParcelable();
                 mRemoteDevice.flush(/*out*/lastFrameNumberRef);
@@ -738,11 +787,11 @@
     }
 
     /**
-     * <p>A listener for tracking the progress of a {@link CaptureRequest}
+     * <p>A callback for tracking the progress of a {@link CaptureRequest}
      * submitted to the camera device.</p>
      *
      */
-    public static abstract class CaptureListener {
+    public static abstract class CaptureCallback {
 
         /**
          * This constant is used to indicate that no images were captured for
@@ -759,7 +808,7 @@
          * @see android.media.MediaActionSound
          */
         public void onCaptureStarted(CameraDevice camera,
-                CaptureRequest request, long timestamp) {
+                CaptureRequest request, long timestamp, long frameNumber) {
             // default empty implementation
         }
 
@@ -804,9 +853,9 @@
         }
 
         /**
-         * This method is called independently of the others in CaptureListener,
+         * This method is called independently of the others in CaptureCallback,
          * when a capture sequence finishes and all {@link CaptureResult}
-         * or {@link CaptureFailure} for it have been returned via this listener.
+         * or {@link CaptureFailure} for it have been returned via this callback.
          */
         public void onCaptureSequenceCompleted(CameraDevice camera,
                 int sequenceId, long frameNumber) {
@@ -814,9 +863,9 @@
         }
 
         /**
-         * This method is called independently of the others in CaptureListener,
+         * This method is called independently of the others in CaptureCallback,
          * when a capture sequence aborts before any {@link CaptureResult}
-         * or {@link CaptureFailure} for it have been returned via this listener.
+         * or {@link CaptureFailure} for it have been returned via this callback.
          */
         public void onCaptureSequenceAborted(CameraDevice camera,
                 int sequenceId) {
@@ -825,10 +874,10 @@
     }
 
     /**
-     * A listener for notifications about the state of a camera device, adding in the callbacks that
+     * A callback for notifications about the state of a camera device, adding in the callbacks that
      * were part of the earlier KK API design, but now only used internally.
      */
-    public static abstract class StateListenerKK extends StateListener {
+    public static abstract class StateCallbackKK extends StateCallback {
         /**
          * The method called when a camera device has no outputs configured.
          *
@@ -864,31 +913,31 @@
         }
     }
 
-    static class CaptureListenerHolder {
+    static class CaptureCallbackHolder {
 
         private final boolean mRepeating;
-        private final CaptureListener mListener;
+        private final CaptureCallback mCallback;
         private final List<CaptureRequest> mRequestList;
         private final Handler mHandler;
 
-        CaptureListenerHolder(CaptureListener listener, List<CaptureRequest> requestList,
+        CaptureCallbackHolder(CaptureCallback callback, List<CaptureRequest> requestList,
                 Handler handler, boolean repeating) {
-            if (listener == null || handler == null) {
+            if (callback == null || handler == null) {
                 throw new UnsupportedOperationException(
-                    "Must have a valid handler and a valid listener");
+                    "Must have a valid handler and a valid callback");
             }
             mRepeating = repeating;
             mHandler = handler;
             mRequestList = new ArrayList<CaptureRequest>(requestList);
-            mListener = listener;
+            mCallback = callback;
         }
 
         public boolean isRepeating() {
             return mRepeating;
         }
 
-        public CaptureListener getListener() {
-            return mListener;
+        public CaptureCallback getCallback() {
+            return mCallback;
         }
 
         public CaptureRequest getRequest(int subsequenceId) {
@@ -924,6 +973,8 @@
 
         private long mCompletedFrameNumber = -1;
         private final TreeSet<Long> mFutureErrorSet = new TreeSet<Long>();
+        /** Map frame numbers to list of partial results */
+        private final HashMap<Long, List<CaptureResult>> mPartialResults = new HashMap<>();
 
         private void update() {
             Iterator<Long> iter = mFutureErrorSet.iterator();
@@ -940,8 +991,8 @@
 
         /**
          * This function is called every time when a result or an error is received.
-         * @param frameNumber: the frame number corresponding to the result or error
-         * @param isError: true if it is an error, false if it is not an error
+         * @param frameNumber the frame number corresponding to the result or error
+         * @param isError true if it is an error, false if it is not an error
          */
         public void updateTracker(long frameNumber, boolean isError) {
             if (isError) {
@@ -957,12 +1008,63 @@
                     Log.e(TAG, String.format(
                             "result frame number %d comes out of order, should be %d + 1",
                             frameNumber, mCompletedFrameNumber));
+                    // Continue on to set the completed frame number to this frame anyway,
+                    // to be robust to lower-level errors and allow for clean shutdowns.
                 }
-                mCompletedFrameNumber++;
+                mCompletedFrameNumber = frameNumber;
             }
             update();
         }
 
+        /**
+         * This function is called every time a result has been completed.
+         *
+         * <p>It keeps a track of all the partial results already created for a particular
+         * frame number.</p>
+         *
+         * @param frameNumber the frame number corresponding to the result
+         * @param result the total or partial result
+         * @param partial {@true} if the result is partial, {@code false} if total
+         */
+        public void updateTracker(long frameNumber, CaptureResult result, boolean partial) {
+
+            if (!partial) {
+                // Update the total result's frame status as being successful
+                updateTracker(frameNumber, /*isError*/false);
+                // Don't keep a list of total results, we don't need to track them
+                return;
+            }
+
+            if (result == null) {
+                // Do not record blank results; this also means there will be no total result
+                // so it doesn't matter that the partials were not recorded
+                return;
+            }
+
+            // Partial results must be aggregated in-order for that frame number
+            List<CaptureResult> partials = mPartialResults.get(frameNumber);
+            if (partials == null) {
+                partials = new ArrayList<>();
+                mPartialResults.put(frameNumber, partials);
+            }
+
+            partials.add(result);
+        }
+
+        /**
+         * Attempt to pop off all of the partial results seen so far for the {@code frameNumber}.
+         *
+         * <p>Once popped-off, the partial results are forgotten (unless {@code updateTracker}
+         * is called again with new partials for that frame number).</p>
+         *
+         * @param frameNumber the frame number corresponding to the result
+         * @return a list of partial results for that frame with at least 1 element,
+         *         or {@code null} if there were no partials recorded for that frame
+         */
+        public List<CaptureResult> popPartialResults(long frameNumber) {
+            return mPartialResults.remove(frameNumber);
+        }
+
         public long getCompletedFrameNumber() {
             return mCompletedFrameNumber;
         }
@@ -976,20 +1078,20 @@
             final SimpleEntry<Long, Integer> frameNumberRequestPair = iter.next();
             if (frameNumberRequestPair.getKey() <= completedFrameNumber) {
 
-                // remove request from mCaptureListenerMap
+                // remove request from mCaptureCallbackMap
                 final int requestId = frameNumberRequestPair.getValue();
-                final CaptureListenerHolder holder;
+                final CaptureCallbackHolder holder;
                 synchronized(mInterfaceLock) {
                     if (mRemoteDevice == null) {
                         Log.w(TAG, "Camera closed while checking sequences");
                         return;
                     }
 
-                    int index = mCaptureListenerMap.indexOfKey(requestId);
-                    holder = (index >= 0) ? mCaptureListenerMap.valueAt(index)
+                    int index = mCaptureCallbackMap.indexOfKey(requestId);
+                    holder = (index >= 0) ? mCaptureCallbackMap.valueAt(index)
                             : null;
                     if (holder != null) {
-                        mCaptureListenerMap.removeAt(index);
+                        mCaptureCallbackMap.removeAt(index);
                         if (DEBUG) {
                             Log.v(TAG, String.format(
                                     "remove holder for requestId %d, "
@@ -1019,7 +1121,7 @@
                                     throw new AssertionError(lastFrameNumber
                                             + " cannot be cast to int");
                                 }
-                                holder.getListener().onCaptureSequenceCompleted(
+                                holder.getCallback().onCaptureSequenceCompleted(
                                     CameraDeviceImpl.this,
                                     requestId,
                                     lastFrameNumber);
@@ -1051,63 +1153,81 @@
 
         /**
          * Camera has encountered a device-level error
-         * Matches CameraDevice.StateListener#ERROR_CAMERA_DEVICE
+         * Matches CameraDevice.StateCallback#ERROR_CAMERA_DEVICE
          */
         static final int ERROR_CAMERA_DEVICE = 1;
 
         /**
          * Camera has encountered a service-level error
-         * Matches CameraDevice.StateListener#ERROR_CAMERA_SERVICE
+         * Matches CameraDevice.StateCallback#ERROR_CAMERA_SERVICE
          */
         static final int ERROR_CAMERA_SERVICE = 2;
 
+        /**
+         * Camera has encountered an error processing a single request.
+         */
+        static final int ERROR_CAMERA_REQUEST = 3;
+
+        /**
+         * Camera has encountered an error producing metadata for a single capture
+         */
+        static final int ERROR_CAMERA_RESULT = 4;
+
+        /**
+         * Camera has encountered an error producing an image buffer for a single capture
+         */
+        static final int ERROR_CAMERA_BUFFER = 5;
+
         @Override
         public IBinder asBinder() {
             return this;
         }
 
         @Override
-        public void onCameraError(final int errorCode, CaptureResultExtras resultExtras) {
-            Runnable r = null;
+        public void onDeviceError(final int errorCode, CaptureResultExtras resultExtras) {
+            if (DEBUG) {
+                Log.d(TAG, String.format(
+                    "Device error received, code %d, frame number %d, request ID %d, subseq ID %d",
+                    errorCode, resultExtras.getFrameNumber(), resultExtras.getRequestId(),
+                    resultExtras.getSubsequenceId()));
+            }
 
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) {
                     return; // Camera already closed
                 }
 
-                mInError = true;
                 switch (errorCode) {
                     case ERROR_CAMERA_DISCONNECTED:
-                        r = mCallOnDisconnected;
+                        CameraDeviceImpl.this.mDeviceHandler.post(mCallOnDisconnected);
                         break;
                     default:
                         Log.e(TAG, "Unknown error from camera device: " + errorCode);
                         // no break
                     case ERROR_CAMERA_DEVICE:
                     case ERROR_CAMERA_SERVICE:
-                        r = new Runnable() {
+                        mInError = true;
+                        Runnable r = new Runnable() {
                             @Override
                             public void run() {
                                 if (!CameraDeviceImpl.this.isClosed()) {
-                                    mDeviceListener.onError(CameraDeviceImpl.this, errorCode);
+                                    mDeviceCallback.onError(CameraDeviceImpl.this, errorCode);
                                 }
                             }
                         };
+                        CameraDeviceImpl.this.mDeviceHandler.post(r);
+                        break;
+                    case ERROR_CAMERA_REQUEST:
+                    case ERROR_CAMERA_RESULT:
+                    case ERROR_CAMERA_BUFFER:
+                        onCaptureErrorLocked(errorCode, resultExtras);
                         break;
                 }
-                CameraDeviceImpl.this.mDeviceHandler.post(r);
-
-                // Fire onCaptureSequenceCompleted
-                if (DEBUG) {
-                    Log.v(TAG, String.format("got error frame %d", resultExtras.getFrameNumber()));
-                }
-                mFrameNumberTracker.updateTracker(resultExtras.getFrameNumber(), /*error*/true);
-                checkAndFireSequenceComplete();
             }
         }
 
         @Override
-        public void onCameraIdle() {
+        public void onDeviceIdle() {
             if (DEBUG) {
                 Log.d(TAG, "Camera now idle");
             }
@@ -1124,16 +1244,18 @@
         @Override
         public void onCaptureStarted(final CaptureResultExtras resultExtras, final long timestamp) {
             int requestId = resultExtras.getRequestId();
+            final long frameNumber = resultExtras.getFrameNumber();
+
             if (DEBUG) {
-                Log.d(TAG, "Capture started for id " + requestId);
+                Log.d(TAG, "Capture started for id " + requestId + " frame number " + frameNumber);
             }
-            final CaptureListenerHolder holder;
+            final CaptureCallbackHolder holder;
 
             synchronized(mInterfaceLock) {
                 if (mRemoteDevice == null) return; // Camera already closed
 
-                // Get the listener for this frame ID, if there is one
-                holder = CameraDeviceImpl.this.mCaptureListenerMap.get(requestId);
+                // Get the callback for this frame ID, if there is one
+                holder = CameraDeviceImpl.this.mCaptureCallbackMap.get(requestId);
 
                 if (holder == null) {
                     return;
@@ -1147,10 +1269,10 @@
                         @Override
                         public void run() {
                             if (!CameraDeviceImpl.this.isClosed()) {
-                                holder.getListener().onCaptureStarted(
+                                holder.getCallback().onCaptureStarted(
                                     CameraDeviceImpl.this,
                                     holder.getRequest(resultExtras.getSubsequenceId()),
-                                    timestamp);
+                                    timestamp, frameNumber);
                             }
                         }
                     });
@@ -1177,25 +1299,22 @@
                 result.set(CameraCharacteristics.LENS_INFO_SHADING_MAP_SIZE,
                         getCharacteristics().get(CameraCharacteristics.LENS_INFO_SHADING_MAP_SIZE));
 
-                final CaptureListenerHolder holder =
-                        CameraDeviceImpl.this.mCaptureListenerMap.get(requestId);
+                final CaptureCallbackHolder holder =
+                        CameraDeviceImpl.this.mCaptureCallbackMap.get(requestId);
 
                 boolean isPartialResult =
                         (resultExtras.getPartialResultCount() < mTotalPartialCount);
 
-                // Update tracker (increment counter) when it's not a partial result.
-                if (!isPartialResult) {
-                    mFrameNumberTracker.updateTracker(frameNumber,
-                            /*error*/false);
-                }
-
-                // Check if we have a listener for this
+                // Check if we have a callback for this
                 if (holder == null) {
                     if (DEBUG) {
                         Log.d(TAG,
                                 "holder is null, early return at frame "
                                         + frameNumber);
                     }
+
+                    mFrameNumberTracker.updateTracker(frameNumber, /*result*/null, isPartialResult);
+
                     return;
                 }
 
@@ -1205,14 +1324,17 @@
                                 "camera is closed, early return at frame "
                                         + frameNumber);
                     }
+
+                    mFrameNumberTracker.updateTracker(frameNumber, /*result*/null, isPartialResult);
                     return;
                 }
 
                 final CaptureRequest request = holder.getRequest(resultExtras.getSubsequenceId());
 
-
                 Runnable resultDispatch = null;
 
+                CaptureResult finalResult;
+
                 // Either send a partial result or the final capture completed result
                 if (isPartialResult) {
                     final CaptureResult resultAsCapture =
@@ -1223,42 +1345,108 @@
                         @Override
                         public void run() {
                             if (!CameraDeviceImpl.this.isClosed()){
-                                holder.getListener().onCaptureProgressed(
+                                holder.getCallback().onCaptureProgressed(
                                     CameraDeviceImpl.this,
                                     request,
                                     resultAsCapture);
                             }
                         }
                     };
+
+                    finalResult = resultAsCapture;
                 } else {
+                    List<CaptureResult> partialResults =
+                            mFrameNumberTracker.popPartialResults(frameNumber);
+
                     final TotalCaptureResult resultAsCapture =
-                            new TotalCaptureResult(result, request, resultExtras);
+                            new TotalCaptureResult(result, request, resultExtras, partialResults);
 
                     // Final capture result
                     resultDispatch = new Runnable() {
                         @Override
                         public void run() {
                             if (!CameraDeviceImpl.this.isClosed()){
-                                holder.getListener().onCaptureCompleted(
+                                holder.getCallback().onCaptureCompleted(
                                     CameraDeviceImpl.this,
                                     request,
                                     resultAsCapture);
                             }
                         }
                     };
+
+                    finalResult = resultAsCapture;
                 }
 
                 holder.getHandler().post(resultDispatch);
 
+                // Collect the partials for a total result; or mark the frame as totally completed
+                mFrameNumberTracker.updateTracker(frameNumber, finalResult, isPartialResult);
+
                 // Fire onCaptureSequenceCompleted
                 if (!isPartialResult) {
                     checkAndFireSequenceComplete();
                 }
-
             }
         }
 
-    }
+        /**
+         * Called by onDeviceError for handling single-capture failures.
+         */
+        private void onCaptureErrorLocked(int errorCode, CaptureResultExtras resultExtras) {
+
+            final int requestId = resultExtras.getRequestId();
+            final int subsequenceId = resultExtras.getSubsequenceId();
+            final long frameNumber = resultExtras.getFrameNumber();
+            final CaptureCallbackHolder holder =
+                    CameraDeviceImpl.this.mCaptureCallbackMap.get(requestId);
+
+            final CaptureRequest request = holder.getRequest(subsequenceId);
+
+            // No way to report buffer errors right now
+            if (errorCode == ERROR_CAMERA_BUFFER) {
+                Log.e(TAG, String.format("Lost output buffer reported for frame %d", frameNumber));
+                return;
+            }
+
+            boolean mayHaveBuffers = (errorCode == ERROR_CAMERA_RESULT);
+
+            // This is only approximate - exact handling needs the camera service and HAL to
+            // disambiguate between request failures to due abort and due to real errors.
+            // For now, assume that if the session believes we're mid-abort, then the error
+            // is due to abort.
+            int reason = (mCurrentSession != null && mCurrentSession.isAborting()) ?
+                    CaptureFailure.REASON_FLUSHED :
+                    CaptureFailure.REASON_ERROR;
+
+            final CaptureFailure failure = new CaptureFailure(
+                request,
+                reason,
+                /*dropped*/ mayHaveBuffers,
+                requestId,
+                frameNumber);
+
+            Runnable failureDispatch = new Runnable() {
+                @Override
+                public void run() {
+                    if (!CameraDeviceImpl.this.isClosed()){
+                        holder.getCallback().onCaptureFailed(
+                            CameraDeviceImpl.this,
+                            request,
+                            failure);
+                    }
+                }
+            };
+            holder.getHandler().post(failureDispatch);
+
+            // Fire onCaptureSequenceCompleted if appropriate
+            if (DEBUG) {
+                Log.v(TAG, String.format("got error frame %d", frameNumber));
+            }
+            mFrameNumberTracker.updateTracker(frameNumber, /*error*/true);
+            checkAndFireSequenceComplete();
+        }
+
+    } // public class CameraDeviceCallbacks
 
     /**
      * Default handler management.
@@ -1281,12 +1469,12 @@
     }
 
     /**
-     * Default handler management, conditional on there being a listener.
+     * Default handler management, conditional on there being a callback.
      *
-     * <p>If the listener isn't null, check the handler, otherwise pass it through.</p>
+     * <p>If the callback isn't null, check the handler, otherwise pass it through.</p>
      */
-    static <T> Handler checkHandler(Handler handler, T listener) {
-        if (listener != null) {
+    static <T> Handler checkHandler(Handler handler, T callback) {
+        if (callback != null) {
             return checkHandler(handler);
         }
         return handler;
diff --git a/core/java/android/hardware/camera2/impl/CameraMetadataNative.java b/core/java/android/hardware/camera2/impl/CameraMetadataNative.java
index febb015..f47ce79 100644
--- a/core/java/android/hardware/camera2/impl/CameraMetadataNative.java
+++ b/core/java/android/hardware/camera2/impl/CameraMetadataNative.java
@@ -67,7 +67,6 @@
 import java.nio.ByteOrder;
 import java.util.ArrayList;
 import java.util.HashMap;
-import java.util.List;
 
 /**
  * Implementation of camera metadata marshal/unmarshal across Binder to
@@ -655,6 +654,15 @@
 
     private Face[] getFaces() {
         Integer faceDetectMode = get(CaptureResult.STATISTICS_FACE_DETECT_MODE);
+        byte[] faceScores = get(CaptureResult.STATISTICS_FACE_SCORES);
+        Rect[] faceRectangles = get(CaptureResult.STATISTICS_FACE_RECTANGLES);
+        int[] faceIds = get(CaptureResult.STATISTICS_FACE_IDS);
+        int[] faceLandmarks = get(CaptureResult.STATISTICS_FACE_LANDMARKS);
+
+        if (areValuesAllNull(faceDetectMode, faceScores, faceRectangles, faceIds, faceLandmarks)) {
+            return null;
+        }
+
         if (faceDetectMode == null) {
             Log.w(TAG, "Face detect mode metadata is null, assuming the mode is SIMPLE");
             faceDetectMode = CaptureResult.STATISTICS_FACE_DETECT_MODE_SIMPLE;
@@ -670,8 +678,6 @@
         }
 
         // Face scores and rectangles are required by SIMPLE and FULL mode.
-        byte[] faceScores = get(CaptureResult.STATISTICS_FACE_SCORES);
-        Rect[] faceRectangles = get(CaptureResult.STATISTICS_FACE_RECTANGLES);
         if (faceScores == null || faceRectangles == null) {
             Log.w(TAG, "Expect face scores and rectangles to be non-null");
             return new Face[0];
@@ -683,8 +689,6 @@
         // To be safe, make number of faces is the minimal of all face info metadata length.
         int numFaces = Math.min(faceScores.length, faceRectangles.length);
         // Face id and landmarks are only required by FULL mode.
-        int[] faceIds = get(CaptureResult.STATISTICS_FACE_IDS);
-        int[] faceLandmarks = get(CaptureResult.STATISTICS_FACE_LANDMARKS);
         if (faceDetectMode == CaptureResult.STATISTICS_FACE_DETECT_MODE_FULL) {
             if (faceIds == null || faceLandmarks == null) {
                 Log.w(TAG, "Expect face ids and landmarks to be non-null for FULL mode," +
@@ -755,22 +759,32 @@
 
     private LensShadingMap getLensShadingMap() {
         float[] lsmArray = getBase(CaptureResult.STATISTICS_LENS_SHADING_MAP);
+        Size s = get(CameraCharacteristics.LENS_INFO_SHADING_MAP_SIZE);
+
+        // Do not warn if lsmArray is null while s is not. This is valid.
         if (lsmArray == null) {
-            Log.w(TAG, "getLensShadingMap - Lens shading map was null.");
             return null;
         }
-        Size s = get(CameraCharacteristics.LENS_INFO_SHADING_MAP_SIZE);
+
+        if (s == null) {
+            Log.w(TAG, "getLensShadingMap - Lens shading map size was null.");
+            return null;
+        }
+
         LensShadingMap map = new LensShadingMap(lsmArray, s.getHeight(), s.getWidth());
         return map;
     }
 
     private Location getGpsLocation() {
         String processingMethod = get(CaptureResult.JPEG_GPS_PROCESSING_METHOD);
-        Location l = new Location(translateProcessToLocationProvider(processingMethod));
-
         double[] coords = get(CaptureResult.JPEG_GPS_COORDINATES);
         Long timeStamp = get(CaptureResult.JPEG_GPS_TIMESTAMP);
 
+        if (areValuesAllNull(processingMethod, coords, timeStamp)) {
+            return null;
+        }
+
+        Location l = new Location(translateProcessToLocationProvider(processingMethod));
         if (timeStamp != null) {
             l.setTime(timeStamp);
         } else {
@@ -873,7 +887,13 @@
         float[] red = getBase(CaptureRequest.TONEMAP_CURVE_RED);
         float[] green = getBase(CaptureRequest.TONEMAP_CURVE_GREEN);
         float[] blue = getBase(CaptureRequest.TONEMAP_CURVE_BLUE);
+
+        if (areValuesAllNull(red, green, blue)) {
+            return null;
+        }
+
         if (red == null || green == null || blue == null) {
+            Log.w(TAG, "getTonemapCurve - missing tone curve components");
             return null;
         }
         TonemapCurve tc = new TonemapCurve(red, green, blue);
@@ -1208,6 +1228,18 @@
         }
     }
 
+    /** Check if input arguments are all {@code null}.
+     *
+     * @param objs Input arguments for null check
+     * @return {@code true} if input arguments are all {@code null}, otherwise {@code false}
+     */
+    private static boolean areValuesAllNull(Object... objs) {
+        for (Object o : objs) {
+            if (o != null) return false;
+        }
+        return true;
+    }
+
     static {
         /*
          * We use a class initializer to allow the native code to cache some field offsets
diff --git a/core/java/android/hardware/camera2/impl/ListenerProxies.java b/core/java/android/hardware/camera2/impl/ListenerProxies.java
deleted file mode 100644
index f44f9ad..0000000
--- a/core/java/android/hardware/camera2/impl/ListenerProxies.java
+++ /dev/null
@@ -1,183 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.hardware.camera2.impl;
-
-import android.hardware.camera2.CameraCaptureSession;
-import android.hardware.camera2.CameraDevice;
-import android.hardware.camera2.CaptureFailure;
-import android.hardware.camera2.CaptureRequest;
-import android.hardware.camera2.CaptureResult;
-import android.hardware.camera2.TotalCaptureResult;
-import android.hardware.camera2.dispatch.Dispatchable;
-import android.hardware.camera2.dispatch.MethodNameInvoker;
-
-import static com.android.internal.util.Preconditions.*;
-
-/**
- * Proxy out invocations to the camera2 API listeners into a {@link Dispatchable}.
- *
- * <p>Since abstract classes do not support Java's dynamic {@code Proxy}, we have to
- * to use our own proxy mechanism.</p>
- */
-public class ListenerProxies {
-
-    // TODO: replace with codegen
-
-    public static class DeviceStateListenerProxy extends CameraDeviceImpl.StateListenerKK {
-        private final MethodNameInvoker<CameraDeviceImpl.StateListenerKK> mProxy;
-
-        public DeviceStateListenerProxy(
-                Dispatchable<CameraDeviceImpl.StateListenerKK> dispatchTarget) {
-            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
-            mProxy = new MethodNameInvoker<>(dispatchTarget, CameraDeviceImpl.StateListenerKK.class);
-        }
-
-        @Override
-        public void onOpened(CameraDevice camera) {
-            mProxy.invoke("onOpened", camera);
-        }
-
-        @Override
-        public void onDisconnected(CameraDevice camera) {
-            mProxy.invoke("onDisconnected", camera);
-        }
-
-        @Override
-        public void onError(CameraDevice camera, int error) {
-            mProxy.invoke("onError", camera, error);
-        }
-
-        @Override
-        public void onUnconfigured(CameraDevice camera) {
-            mProxy.invoke("onUnconfigured", camera);
-        }
-
-        @Override
-        public void onActive(CameraDevice camera) {
-            mProxy.invoke("onActive", camera);
-        }
-
-        @Override
-        public void onBusy(CameraDevice camera) {
-            mProxy.invoke("onBusy", camera);
-        }
-
-        @Override
-        public void onClosed(CameraDevice camera) {
-            mProxy.invoke("onClosed", camera);
-        }
-
-        @Override
-        public void onIdle(CameraDevice camera) {
-            mProxy.invoke("onIdle", camera);
-        }
-    }
-
-    @SuppressWarnings("deprecation")
-    public static class DeviceCaptureListenerProxy extends CameraDeviceImpl.CaptureListener {
-        private final MethodNameInvoker<CameraDeviceImpl.CaptureListener> mProxy;
-
-        public DeviceCaptureListenerProxy(
-                Dispatchable<CameraDeviceImpl.CaptureListener> dispatchTarget) {
-            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
-            mProxy = new MethodNameInvoker<>(dispatchTarget, CameraDeviceImpl.CaptureListener.class);
-        }
-
-        @Override
-        public void onCaptureStarted(CameraDevice camera,
-                CaptureRequest request, long timestamp) {
-            mProxy.invoke("onCaptureStarted", camera, request, timestamp);
-        }
-
-        @Override
-        public void onCapturePartial(CameraDevice camera,
-                CaptureRequest request, CaptureResult result) {
-            mProxy.invoke("onCapturePartial", camera, request, result);
-        }
-
-        @Override
-        public void onCaptureProgressed(CameraDevice camera,
-                CaptureRequest request, CaptureResult partialResult) {
-            mProxy.invoke("onCaptureProgressed", camera, request, partialResult);
-        }
-
-        @Override
-        public void onCaptureCompleted(CameraDevice camera,
-                CaptureRequest request, TotalCaptureResult result) {
-            mProxy.invoke("onCaptureCompleted", camera, request, result);
-        }
-
-        @Override
-        public void onCaptureFailed(CameraDevice camera,
-                CaptureRequest request, CaptureFailure failure) {
-            mProxy.invoke("onCaptureFailed", camera, request, failure);
-        }
-
-        @Override
-        public void onCaptureSequenceCompleted(CameraDevice camera,
-                int sequenceId, long frameNumber) {
-            mProxy.invoke("onCaptureSequenceCompleted", camera, sequenceId, frameNumber);
-        }
-
-        @Override
-        public void onCaptureSequenceAborted(CameraDevice camera,
-                int sequenceId) {
-            mProxy.invoke("onCaptureSequenceAborted", camera, sequenceId);
-        }
-    }
-
-    public static class SessionStateListenerProxy
-            extends CameraCaptureSession.StateListener {
-        private final MethodNameInvoker<CameraCaptureSession.StateListener> mProxy;
-
-        public SessionStateListenerProxy(
-                Dispatchable<CameraCaptureSession.StateListener> dispatchTarget) {
-            dispatchTarget = checkNotNull(dispatchTarget, "dispatchTarget must not be null");
-            mProxy = new MethodNameInvoker<>(dispatchTarget,
-                    CameraCaptureSession.StateListener.class);
-        }
-
-        @Override
-        public void onConfigured(CameraCaptureSession session) {
-            mProxy.invoke("onConfigured", session);
-        }
-
-
-        @Override
-        public void onConfigureFailed(CameraCaptureSession session) {
-            mProxy.invoke("onConfigureFailed", session);
-        }
-
-        @Override
-        public void onReady(CameraCaptureSession session) {
-            mProxy.invoke("onReady", session);
-        }
-
-        @Override
-        public void onActive(CameraCaptureSession session) {
-            mProxy.invoke("onActive", session);
-        }
-
-        @Override
-        public void onClosed(CameraCaptureSession session) {
-            mProxy.invoke("onClosed", session);
-        }
-    }
-
-    private ListenerProxies() {
-        throw new AssertionError();
-    }
-}
diff --git a/core/java/android/hardware/camera2/legacy/CameraDeviceUserShim.java b/core/java/android/hardware/camera2/legacy/CameraDeviceUserShim.java
index c68d8c3..410934e 100644
--- a/core/java/android/hardware/camera2/legacy/CameraDeviceUserShim.java
+++ b/core/java/android/hardware/camera2/legacy/CameraDeviceUserShim.java
@@ -56,6 +56,7 @@
  * Keep up to date with ICameraDeviceUser.aidl.
  * </p>
  */
+@SuppressWarnings("deprecation")
 public class CameraDeviceUserShim implements ICameraDeviceUser {
     private static final String TAG = "CameraDeviceUserShim";
 
@@ -210,7 +211,7 @@
         }
 
         @Override
-        public void onCameraError(final int errorCode, final CaptureResultExtras resultExtras) {
+        public void onDeviceError(final int errorCode, final CaptureResultExtras resultExtras) {
             Message msg = getHandler().obtainMessage(CAMERA_ERROR,
                 /*arg1*/ errorCode, /*arg2*/ 0,
                 /*obj*/ resultExtras);
@@ -218,7 +219,7 @@
         }
 
         @Override
-        public void onCameraIdle() {
+        public void onDeviceIdle() {
             Message msg = getHandler().obtainMessage(CAMERA_IDLE);
             getHandler().sendMessage(msg);
         }
@@ -259,17 +260,18 @@
                 super(l);
             }
 
+            @Override
             public void handleMessage(Message msg) {
                 try {
                     switch (msg.what) {
                         case CAMERA_ERROR: {
                             int errorCode = msg.arg1;
                             CaptureResultExtras resultExtras = (CaptureResultExtras) msg.obj;
-                            mCallbacks.onCameraError(errorCode, resultExtras);
+                            mCallbacks.onDeviceError(errorCode, resultExtras);
                             break;
                         }
                         case CAMERA_IDLE:
-                            mCallbacks.onCameraIdle();
+                            mCallbacks.onDeviceIdle();
                             break;
                         case CAPTURE_STARTED: {
                             long timestamp = msg.arg2 & 0xFFFFFFFFL;
@@ -320,6 +322,9 @@
         // Check errors old HAL initialization
         CameraBinderDecorator.throwOnError(initErrors);
 
+        // Disable shutter sounds (this will work unconditionally) for api2 clients
+        legacyCamera.disableShutterSound();
+
         CameraInfo info = new CameraInfo();
         Camera.getCameraInfo(cameraId, info);
 
diff --git a/core/java/android/hardware/camera2/legacy/GLThreadManager.java b/core/java/android/hardware/camera2/legacy/GLThreadManager.java
index 06521cf..2c584ef 100644
--- a/core/java/android/hardware/camera2/legacy/GLThreadManager.java
+++ b/core/java/android/hardware/camera2/legacy/GLThreadManager.java
@@ -121,9 +121,10 @@
      * Create a new GL thread and renderer.
      *
      * @param cameraId the camera id for this thread.
+     * @param facing direction the camera is facing.
      */
-    public GLThreadManager(int cameraId) {
-        mTextureRenderer = new SurfaceTextureRenderer();
+    public GLThreadManager(int cameraId, int facing) {
+        mTextureRenderer = new SurfaceTextureRenderer(facing);
         TAG = String.format("CameraDeviceGLThread-%d", cameraId);
         mGLHandlerThread = new RequestHandlerThread(TAG, mGLHandlerCb);
     }
diff --git a/core/java/android/hardware/camera2/legacy/LegacyCameraDevice.java b/core/java/android/hardware/camera2/legacy/LegacyCameraDevice.java
index 1cf7797..ffc55f1 100644
--- a/core/java/android/hardware/camera2/legacy/LegacyCameraDevice.java
+++ b/core/java/android/hardware/camera2/legacy/LegacyCameraDevice.java
@@ -97,7 +97,7 @@
                         Log.d(TAG, "doing onError callback.");
                     }
                     try {
-                        mDeviceCallbacks.onCameraError(errorCode, extras);
+                        mDeviceCallbacks.onDeviceError(errorCode, extras);
                     } catch (RemoteException e) {
                         throw new IllegalStateException(
                                 "Received remote exception during onCameraError callback: ", e);
@@ -125,7 +125,7 @@
                         Log.d(TAG, "doing onIdle callback.");
                     }
                     try {
-                        mDeviceCallbacks.onCameraIdle();
+                        mDeviceCallbacks.onDeviceIdle();
                     } catch (RemoteException e) {
                         throw new IllegalStateException(
                                 "Received remote exception during onCameraIdle callback: ", e);
diff --git a/core/java/android/hardware/camera2/legacy/LegacyFocusStateMapper.java b/core/java/android/hardware/camera2/legacy/LegacyFocusStateMapper.java
index d0a3a3f..d5ec71a 100644
--- a/core/java/android/hardware/camera2/legacy/LegacyFocusStateMapper.java
+++ b/core/java/android/hardware/camera2/legacy/LegacyFocusStateMapper.java
@@ -114,21 +114,24 @@
                 currentAfRun = mAfRun;
             }
 
-            mCamera.setAutoFocusMoveCallback(new Camera.AutoFocusMoveCallback() {
+            Camera.AutoFocusMoveCallback afMoveCallback = new Camera.AutoFocusMoveCallback() {
                 @Override
                 public void onAutoFocusMoving(boolean start, Camera camera) {
                     synchronized (mLock) {
                         int latestAfRun = mAfRun;
 
                         if (VERBOSE) {
-                            Log.v(TAG, "onAutoFocusMoving - start " + start + " latest AF run " +
-                                    latestAfRun + ", last AF run " + currentAfRun);
+                            Log.v(TAG,
+                                    "onAutoFocusMoving - start " + start + " latest AF run " +
+                                            latestAfRun + ", last AF run " + currentAfRun
+                            );
                         }
 
                         if (currentAfRun != latestAfRun) {
                             Log.d(TAG,
                                     "onAutoFocusMoving - ignoring move callbacks from old af run"
-                                            + currentAfRun);
+                                            + currentAfRun
+                            );
                             return;
                         }
 
@@ -151,9 +154,19 @@
                         mAfState = newAfState;
                     }
                 }
-            });
+            };
+
+            // Only set move callback if we can call autofocus.
+            switch (afMode) {
+                case Parameters.FOCUS_MODE_AUTO:
+                case Parameters.FOCUS_MODE_MACRO:
+                case Parameters.FOCUS_MODE_CONTINUOUS_PICTURE:
+                case Parameters.FOCUS_MODE_CONTINUOUS_VIDEO:
+                    mCamera.setAutoFocusMoveCallback(afMoveCallback);
+            }
         }
 
+
         // AF Locking
         switch (afTrigger) {
             case CONTROL_AF_TRIGGER_START:
@@ -167,6 +180,7 @@
                     case Parameters.FOCUS_MODE_CONTINUOUS_PICTURE:
                     case Parameters.FOCUS_MODE_CONTINUOUS_VIDEO:
                         afStateAfterStart = CONTROL_AF_STATE_PASSIVE_SCAN;
+                        break;
                     default:
                         // EDOF, INFINITY
                         afStateAfterStart = CONTROL_AF_STATE_INACTIVE;
@@ -183,6 +197,11 @@
                             "new AF run is " + currentAfRun);
                 }
 
+                // Avoid calling autofocus unless we are in a state that supports calling this.
+                if (afStateAfterStart == CONTROL_AF_STATE_INACTIVE) {
+                    break;
+                }
+
                 mCamera.autoFocus(new Camera.AutoFocusCallback() {
                     @Override
                     public void onAutoFocus(boolean success, Camera camera) {
diff --git a/core/java/android/hardware/camera2/legacy/LegacyMetadataMapper.java b/core/java/android/hardware/camera2/legacy/LegacyMetadataMapper.java
index fbe26e5..c36b63a 100644
--- a/core/java/android/hardware/camera2/legacy/LegacyMetadataMapper.java
+++ b/core/java/android/hardware/camera2/legacy/LegacyMetadataMapper.java
@@ -165,6 +165,12 @@
 
     private static void mapCharacteristicsFromParameters(CameraMetadataNative m,
             Camera.Parameters p) {
+
+        /*
+         * colorCorrection.*
+         */
+        m.set(COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES,
+                new int[] { COLOR_CORRECTION_ABERRATION_MODE_FAST });
         /*
          * control.ae*
          */
@@ -196,6 +202,12 @@
         mapJpeg(m, p);
 
         /*
+         * noiseReduction.*
+         */
+        m.set(NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES,
+                new int[] { NOISE_REDUCTION_MODE_FAST });
+
+        /*
          * scaler.*
          */
         mapScaler(m, p);
@@ -626,6 +638,7 @@
             // Note: We only list public keys. Native HALs should list ALL keys regardless of visibility.
 
             Key<?> availableKeys[] = new Key<?>[] {
+                    CameraCharacteristics.COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES     ,
                     CameraCharacteristics.CONTROL_AE_AVAILABLE_ANTIBANDING_MODES          ,
                     CameraCharacteristics.CONTROL_AE_AVAILABLE_MODES                      ,
                     CameraCharacteristics.CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES          ,
@@ -642,6 +655,7 @@
                     CameraCharacteristics.JPEG_AVAILABLE_THUMBNAIL_SIZES                  ,
                     CameraCharacteristics.LENS_FACING                                     ,
                     CameraCharacteristics.LENS_INFO_AVAILABLE_FOCAL_LENGTHS               ,
+                    CameraCharacteristics.NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES ,
                     CameraCharacteristics.REQUEST_AVAILABLE_CAPABILITIES                  ,
                     CameraCharacteristics.REQUEST_MAX_NUM_OUTPUT_STREAMS                  ,
                     CameraCharacteristics.REQUEST_PARTIAL_RESULT_COUNT                    ,
@@ -653,6 +667,7 @@
                     CameraCharacteristics.SENSOR_INFO_ACTIVE_ARRAY_SIZE                   ,
                     CameraCharacteristics.SENSOR_INFO_PHYSICAL_SIZE                       ,
                     CameraCharacteristics.SENSOR_INFO_PIXEL_ARRAY_SIZE                    ,
+                    CameraCharacteristics.SENSOR_INFO_TIMESTAMP_SOURCE                    ,
                     CameraCharacteristics.SENSOR_ORIENTATION                              ,
                     CameraCharacteristics.STATISTICS_INFO_AVAILABLE_FACE_DETECT_MODES     ,
                     CameraCharacteristics.STATISTICS_INFO_MAX_FACE_COUNT                  ,
@@ -675,15 +690,14 @@
          * request.availableRequestKeys
          */
         {
-            CaptureRequest.Key<?> availableKeys[] = new CaptureRequest.Key<?>[] {
+            CaptureRequest.Key<?> defaultAvailableKeys[] = new CaptureRequest.Key<?>[] {
+                    CaptureRequest.COLOR_CORRECTION_ABERRATION_MODE,
                     CaptureRequest.CONTROL_AE_ANTIBANDING_MODE,
                     CaptureRequest.CONTROL_AE_EXPOSURE_COMPENSATION,
                     CaptureRequest.CONTROL_AE_LOCK,
                     CaptureRequest.CONTROL_AE_MODE,
-                    CaptureRequest.CONTROL_AE_REGIONS,
                     CaptureRequest.CONTROL_AE_TARGET_FPS_RANGE,
                     CaptureRequest.CONTROL_AF_MODE,
-                    CaptureRequest.CONTROL_AF_REGIONS,
                     CaptureRequest.CONTROL_AF_TRIGGER,
                     CaptureRequest.CONTROL_AWB_LOCK,
                     CaptureRequest.CONTROL_AWB_MODE,
@@ -701,24 +715,37 @@
                     CaptureRequest.JPEG_THUMBNAIL_QUALITY,
                     CaptureRequest.JPEG_THUMBNAIL_SIZE,
                     CaptureRequest.LENS_FOCAL_LENGTH,
+                    CaptureRequest.NOISE_REDUCTION_MODE,
                     CaptureRequest.SCALER_CROP_REGION,
                     CaptureRequest.STATISTICS_FACE_DETECT_MODE,
             };
-            m.set(REQUEST_AVAILABLE_REQUEST_KEYS, getTagsForKeys(availableKeys));
+            ArrayList<CaptureRequest.Key<?>> availableKeys =
+                    new ArrayList<CaptureRequest.Key<?>>(Arrays.asList(defaultAvailableKeys));
+
+            if (p.getMaxNumMeteringAreas() > 0) {
+                availableKeys.add(CaptureRequest.CONTROL_AE_REGIONS);
+            }
+            if (p.getMaxNumFocusAreas() > 0) {
+                availableKeys.add(CaptureRequest.CONTROL_AF_REGIONS);
+            }
+
+            CaptureRequest.Key<?> availableRequestKeys[] =
+                    new CaptureRequest.Key<?>[availableKeys.size()];
+            availableKeys.toArray(availableRequestKeys);
+            m.set(REQUEST_AVAILABLE_REQUEST_KEYS, getTagsForKeys(availableRequestKeys));
         }
 
         /*
          * request.availableResultKeys
          */
         {
-            CaptureResult.Key<?> availableKeys[] = new CaptureResult.Key<?>[] {
+            CaptureResult.Key<?> defaultAvailableKeys[] = new CaptureResult.Key<?>[] {
+                    CaptureResult.COLOR_CORRECTION_ABERRATION_MODE                 ,
                     CaptureResult.CONTROL_AE_ANTIBANDING_MODE                      ,
                     CaptureResult.CONTROL_AE_EXPOSURE_COMPENSATION                 ,
                     CaptureResult.CONTROL_AE_LOCK                                  ,
                     CaptureResult.CONTROL_AE_MODE                                  ,
-                    CaptureResult.CONTROL_AE_REGIONS                               ,
                     CaptureResult.CONTROL_AF_MODE                                  ,
-                    CaptureResult.CONTROL_AF_REGIONS                               ,
                     CaptureResult.CONTROL_AF_STATE                                 ,
                     CaptureResult.CONTROL_AWB_MODE                                 ,
                     CaptureResult.CONTROL_AWB_LOCK                                 ,
@@ -731,13 +758,27 @@
                     CaptureResult.JPEG_QUALITY                                     ,
                     CaptureResult.JPEG_THUMBNAIL_QUALITY                           ,
                     CaptureResult.LENS_FOCAL_LENGTH                                ,
+                    CaptureResult.NOISE_REDUCTION_MODE                             ,
                     CaptureResult.REQUEST_PIPELINE_DEPTH                           ,
                     CaptureResult.SCALER_CROP_REGION                               ,
                     CaptureResult.SENSOR_TIMESTAMP                                 ,
                     CaptureResult.STATISTICS_FACE_DETECT_MODE                      ,
 //                    CaptureResult.STATISTICS_FACES                                 ,
             };
-            m.set(REQUEST_AVAILABLE_RESULT_KEYS, getTagsForKeys(availableKeys));
+            List<CaptureResult.Key<?>> availableKeys =
+                    new ArrayList<CaptureResult.Key<?>>(Arrays.asList(defaultAvailableKeys));
+
+            if (p.getMaxNumMeteringAreas() > 0) {
+                availableKeys.add(CaptureResult.CONTROL_AE_REGIONS);
+            }
+            if (p.getMaxNumFocusAreas() > 0) {
+                availableKeys.add(CaptureResult.CONTROL_AF_REGIONS);
+            }
+
+            CaptureResult.Key<?> availableResultKeys[] =
+                    new CaptureResult.Key<?>[availableKeys.size()];
+            availableKeys.toArray(availableResultKeys);
+            m.set(REQUEST_AVAILABLE_RESULT_KEYS, getTagsForKeys(availableResultKeys));
         }
 
         /*
@@ -822,6 +863,13 @@
 
             m.set(SENSOR_INFO_PHYSICAL_SIZE, new SizeF(width, height)); // in mm
         }
+
+        /*
+         * sensor.info.timestampSource
+         */
+        {
+            m.set(SENSOR_INFO_TIMESTAMP_SOURCE, SENSOR_INFO_TIMESTAMP_SOURCE_UNKNOWN);
+        }
     }
 
     private static void mapStatistics(CameraMetadataNative m, Parameters p) {
@@ -882,6 +930,7 @@
         Parameters.SCENE_MODE_PARTY,
         Parameters.SCENE_MODE_CANDLELIGHT,
         Parameters.SCENE_MODE_BARCODE,
+        Parameters.SCENE_MODE_HDR,
     };
 
     private final static int[] sSceneModes = {
@@ -901,6 +950,7 @@
         CameraCharacteristics.CONTROL_SCENE_MODE_PARTY,
         CameraCharacteristics.CONTROL_SCENE_MODE_CANDLELIGHT,
         CameraCharacteristics.CONTROL_SCENE_MODE_BARCODE,
+        CameraCharacteristics.CONTROL_SCENE_MODE_HDR,
     };
 
     static int convertSceneModeFromLegacy(String mode) {
@@ -1207,6 +1257,9 @@
             m.set(CaptureRequest.CONTROL_AE_TARGET_FPS_RANGE, bestRange);
         }
 
+        // control.sceneMode -- DISABLED is always available
+        m.set(CaptureRequest.CONTROL_SCENE_MODE, CONTROL_SCENE_MODE_DISABLED);
+
         /*
          * statistics.*
          */
diff --git a/core/java/android/hardware/camera2/legacy/LegacyRequestMapper.java b/core/java/android/hardware/camera2/legacy/LegacyRequestMapper.java
index 4c4ad0d..7c6475d 100644
--- a/core/java/android/hardware/camera2/legacy/LegacyRequestMapper.java
+++ b/core/java/android/hardware/camera2/legacy/LegacyRequestMapper.java
@@ -45,6 +45,7 @@
     private static final String TAG = "LegacyRequestMapper";
     private static final boolean VERBOSE = Log.isLoggable(TAG, Log.VERBOSE);
 
+    /** Default quality for android.jpeg.quality, android.jpeg.thumbnailQuality */
     private static final byte DEFAULT_JPEG_QUALITY = 85;
 
     /**
@@ -80,6 +81,20 @@
             }
         }
 
+        /*
+         * colorCorrection.*
+         */
+        // colorCorrection.aberrationMode
+        {
+            int aberrationMode = ParamsUtils.getOrDefault(request,
+                    COLOR_CORRECTION_ABERRATION_MODE,
+                    /*defaultValue*/COLOR_CORRECTION_ABERRATION_MODE_FAST);
+
+            if (aberrationMode != COLOR_CORRECTION_ABERRATION_MODE_FAST) {
+                Log.w(TAG, "convertRequestToMetadata - Ignoring unsupported " +
+                        "colorCorrection.aberrationMode = " + aberrationMode);
+            }
+        }
 
         /*
          * control.ae*
@@ -122,7 +137,10 @@
                         activeArray, zoomData, aeRegions, maxNumMeteringAreas,
                         /*regionName*/"AE");
 
-                params.setMeteringAreas(meteringAreaList);
+                // WAR: for b/17252693, some devices can't handle params.setFocusAreas(null).
+                if (maxNumMeteringAreas > 0) {
+                    params.setMeteringAreas(meteringAreaList);
+                }
             }
 
             // afRegions
@@ -133,7 +151,10 @@
                         activeArray, zoomData, afRegions, maxNumFocusAreas,
                         /*regionName*/"AF");
 
-                params.setFocusAreas(focusAreaList);
+                // WAR: for b/17252693, some devices can't handle params.setFocusAreas(null).
+                if (maxNumFocusAreas > 0) {
+                    params.setFocusAreas(focusAreaList);
+                }
             }
         }
 
@@ -390,8 +411,8 @@
 
         // jpeg.thumbnailQuality
         {
-            params.setJpegQuality(0xFF & ParamsUtils.getOrDefault(request, JPEG_THUMBNAIL_QUALITY,
-                    DEFAULT_JPEG_QUALITY));
+            params.setJpegThumbnailQuality(0xFF & ParamsUtils.getOrDefault(request,
+                    JPEG_THUMBNAIL_QUALITY, DEFAULT_JPEG_QUALITY));
         }
 
         // jpeg.thumbnailSize
@@ -413,6 +434,21 @@
                 }
             }
         }
+
+        /*
+         * noiseReduction.*
+         */
+        // noiseReduction.mode
+        {
+            int mode = ParamsUtils.getOrDefault(request,
+                    NOISE_REDUCTION_MODE,
+                    /*defaultValue*/NOISE_REDUCTION_MODE_FAST);
+
+            if (mode != NOISE_REDUCTION_MODE_FAST) {
+                Log.w(TAG, "convertRequestToMetadata - Ignoring unsupported " +
+                        "noiseReduction.mode = " + mode);
+            }
+        }
     }
 
     private static boolean checkForCompleteGpsData(Location location) {
diff --git a/core/java/android/hardware/camera2/legacy/LegacyResultMapper.java b/core/java/android/hardware/camera2/legacy/LegacyResultMapper.java
index 090a822..bad1d28 100644
--- a/core/java/android/hardware/camera2/legacy/LegacyResultMapper.java
+++ b/core/java/android/hardware/camera2/legacy/LegacyResultMapper.java
@@ -28,14 +28,12 @@
 import android.hardware.camera2.params.MeteringRectangle;
 import android.hardware.camera2.utils.ListUtils;
 import android.hardware.camera2.utils.ParamsUtils;
-import android.location.Location;
 import android.util.Log;
 import android.util.Size;
 
 import java.util.ArrayList;
 import java.util.List;
 
-import static com.android.internal.util.Preconditions.*;
 import static android.hardware.camera2.CaptureResult.*;
 
 /**
@@ -73,7 +71,7 @@
             result = new CameraMetadataNative(mCachedResult);
             cached = true;
         } else {
-            result = convertResultMetadata(legacyRequest, timestamp);
+            result = convertResultMetadata(legacyRequest);
             cached = false;
 
             // Always cache a *copy* of the metadata result,
@@ -106,12 +104,9 @@
      * Generate capture result metadata from the legacy camera request.
      *
      * @param legacyRequest a non-{@code null} legacy request containing the latest parameters
-     * @param timestamp the timestamp to use for this result in nanoseconds.
-     *
      * @return a {@link CameraMetadataNative} object containing result metadata.
      */
-    private static CameraMetadataNative convertResultMetadata(LegacyRequest legacyRequest,
-                                                      long timestamp) {
+    private static CameraMetadataNative convertResultMetadata(LegacyRequest legacyRequest) {
         CameraCharacteristics characteristics = legacyRequest.characteristics;
         CaptureRequest request = legacyRequest.captureRequest;
         Size previewSize = legacyRequest.previewSize;
@@ -125,6 +120,15 @@
                 request.get(CaptureRequest.SCALER_CROP_REGION), previewSize, params);
 
         /*
+         * colorCorrection
+         */
+        // colorCorrection.aberrationMode
+        {
+            // Always hardcoded to FAST
+            result.set(COLOR_CORRECTION_ABERRATION_MODE, COLOR_CORRECTION_ABERRATION_MODE_FAST);
+        }
+
+        /*
          * control
          */
 
@@ -274,7 +278,12 @@
             Log.w(TAG, "Null thumbnail size received from parameters.");
         }
 
-        // TODO: Remaining result metadata tags conversions.
+        /*
+         * noiseReduction.*
+         */
+        // noiseReduction.mode
+        result.set(NOISE_REDUCTION_MODE, NOISE_REDUCTION_MODE_FAST);
+
         return result;
     }
 
@@ -322,7 +331,7 @@
         }
 
         // control.aeRegions
-        {
+        if (p.getMaxNumMeteringAreas() > 0) {
             if (VERBOSE) {
                 String meteringAreas = p.get("metering-areas");
                 Log.v(TAG, "mapAe - parameter dump; metering-areas: " + meteringAreas);
@@ -342,7 +351,7 @@
         m.set(CaptureResult.CONTROL_AF_MODE, convertLegacyAfMode(p.getFocusMode()));
 
         // control.afRegions
-        {
+        if (p.getMaxNumFocusAreas() > 0) {
             if (VERBOSE) {
                 String focusAreas = p.get("focus-areas");
                 Log.v(TAG, "mapAe - parameter dump; focus-areas: " + focusAreas);
diff --git a/core/java/android/hardware/camera2/legacy/RequestThreadManager.java b/core/java/android/hardware/camera2/legacy/RequestThreadManager.java
index eb8debb..e6da670 100644
--- a/core/java/android/hardware/camera2/legacy/RequestThreadManager.java
+++ b/core/java/android/hardware/camera2/legacy/RequestThreadManager.java
@@ -374,6 +374,9 @@
             }
 
             mIntermediateBufferSize = bestPreviewDimen;
+            mParams.setPreviewSize(mIntermediateBufferSize.getWidth(),
+                    mIntermediateBufferSize.getHeight());
+
             if (DEBUG) {
                 Log.d(TAG, "Intermediate buffer selected with dimens: " +
                         bestPreviewDimen.toString());
@@ -399,7 +402,7 @@
 
         // TODO: Detect and optimize single-output paths here to skip stream teeing.
         if (mGLThreadManager == null) {
-            mGLThreadManager = new GLThreadManager(mCameraId);
+            mGLThreadManager = new GLThreadManager(mCameraId, facing);
             mGLThreadManager.start();
         }
         mGLThreadManager.waitUntilStarted();
diff --git a/core/java/android/hardware/camera2/legacy/SurfaceTextureRenderer.java b/core/java/android/hardware/camera2/legacy/SurfaceTextureRenderer.java
index b1b0f9b..a35883c 100644
--- a/core/java/android/hardware/camera2/legacy/SurfaceTextureRenderer.java
+++ b/core/java/android/hardware/camera2/legacy/SurfaceTextureRenderer.java
@@ -18,6 +18,7 @@
 import android.graphics.ImageFormat;
 import android.graphics.RectF;
 import android.graphics.SurfaceTexture;
+import android.hardware.camera2.CameraCharacteristics;
 import android.os.Environment;
 import android.opengl.EGL14;
 import android.opengl.EGLConfig;
@@ -80,7 +81,18 @@
     private static final int TRIANGLE_VERTICES_DATA_STRIDE_BYTES = 5 * FLOAT_SIZE_BYTES;
     private static final int TRIANGLE_VERTICES_DATA_POS_OFFSET = 0;
     private static final int TRIANGLE_VERTICES_DATA_UV_OFFSET = 3;
-    private final float[] mTriangleVerticesData = {
+
+    // Sampling is mirrored across the vertical axis to undo horizontal flip from the front camera
+    private static final float[] sFrontCameraTriangleVertices = {
+            // X, Y, Z, U, V
+            -1.0f, -1.0f, 0, 1.f, 0.f,
+            1.0f, -1.0f, 0, 0.f, 0.f,
+            -1.0f,  1.0f, 0, 1.f, 1.f,
+            1.0f,  1.0f, 0, 0.f, 1.f,
+    };
+
+    // Sampling is 1:1 for a straight copy for the back camera
+    private static final float[] sBackCameraTriangleVertices = {
             // X, Y, Z, U, V
             -1.0f, -1.0f, 0, 0.f, 0.f,
             1.0f, -1.0f, 0, 1.f, 0.f,
@@ -135,10 +147,16 @@
     private PerfMeasurement mPerfMeasurer = null;
     private static final String LEGACY_PERF_PROPERTY = "persist.camera.legacy_perf";
 
-    public SurfaceTextureRenderer() {
-        mTriangleVertices = ByteBuffer.allocateDirect(mTriangleVerticesData.length *
-                FLOAT_SIZE_BYTES).order(ByteOrder.nativeOrder()).asFloatBuffer();
-        mTriangleVertices.put(mTriangleVerticesData).position(0);
+    public SurfaceTextureRenderer(int facing) {
+        if (facing == CameraCharacteristics.LENS_FACING_BACK) {
+            mTriangleVertices = ByteBuffer.allocateDirect(sBackCameraTriangleVertices.length *
+                    FLOAT_SIZE_BYTES).order(ByteOrder.nativeOrder()).asFloatBuffer();
+            mTriangleVertices.put(sBackCameraTriangleVertices).position(0);
+        } else {
+            mTriangleVertices = ByteBuffer.allocateDirect(sFrontCameraTriangleVertices.length *
+                    FLOAT_SIZE_BYTES).order(ByteOrder.nativeOrder()).asFloatBuffer();
+            mTriangleVertices.put(sFrontCameraTriangleVertices).position(0);
+        }
         Matrix.setIdentityM(mSTMatrix, 0);
     }
 
diff --git a/core/java/android/hardware/camera2/params/ColorSpaceTransform.java b/core/java/android/hardware/camera2/params/ColorSpaceTransform.java
index b4289db2..1e1c4b1 100644
--- a/core/java/android/hardware/camera2/params/ColorSpaceTransform.java
+++ b/core/java/android/hardware/camera2/params/ColorSpaceTransform.java
@@ -225,7 +225,18 @@
         }
         if (obj instanceof ColorSpaceTransform) {
             final ColorSpaceTransform other = (ColorSpaceTransform) obj;
-            return Arrays.equals(mElements, other.mElements);
+            for (int i = 0, j = 0; i < COUNT; ++i, j += RATIONAL_SIZE) {
+                int numerator = mElements[j + OFFSET_NUMERATOR];
+                int denominator = mElements[j + OFFSET_DENOMINATOR];
+                int numeratorOther = other.mElements[j + OFFSET_NUMERATOR];
+                int denominatorOther = other.mElements[j + OFFSET_DENOMINATOR];
+                Rational r = new Rational(numerator, denominator);
+                Rational rOther = new Rational(numeratorOther, denominatorOther);
+                if (!r.equals(rOther)) {
+                    return false;
+                }
+            }
+            return true;
         }
         return false;
     }
@@ -238,5 +249,51 @@
         return HashCodeHelpers.hashCode(mElements);
     }
 
+    /**
+     * Return the color space transform as a string representation.
+     *
+     *  <p> Example:
+     * {@code "ColorSpaceTransform([1/1, 0/1, 0/1], [0/1, 1/1, 0/1], [0/1, 0/1, 1/1])"} is an
+     * identity transform. Elements are printed in row major order. </p>
+     *
+     * @return string representation of color space transform
+     */
+    @Override
+    public String toString() {
+        return String.format("ColorSpaceTransform%s", toShortString());
+    }
+
+    /**
+     * Return the color space transform as a compact string representation.
+     *
+     *  <p> Example:
+     * {@code "([1/1, 0/1, 0/1], [0/1, 1/1, 0/1], [0/1, 0/1, 1/1])"} is an identity transform.
+     * Elements are printed in row major order. </p>
+     *
+     * @return compact string representation of color space transform
+     */
+    private String toShortString() {
+        StringBuilder sb = new StringBuilder("(");
+        for (int row = 0, i = 0; row < ROWS; row++) {
+            sb.append("[");
+            for (int col = 0; col < COLUMNS; col++, i += RATIONAL_SIZE) {
+                int numerator = mElements[i + OFFSET_NUMERATOR];
+                int denominator = mElements[i + OFFSET_DENOMINATOR];
+                sb.append(numerator);
+                sb.append("/");
+                sb.append(denominator);
+                if (col < COLUMNS - 1) {
+                    sb.append(", ");
+                }
+            }
+            sb.append("]");
+            if (row < ROWS - 1) {
+                sb.append(", ");
+            }
+        }
+        sb.append(")");
+        return sb.toString();
+    }
+
     private final int[] mElements;
-};
+}
diff --git a/core/java/android/hardware/camera2/params/RggbChannelVector.java b/core/java/android/hardware/camera2/params/RggbChannelVector.java
index cf3e1de..e08ec55d 100644
--- a/core/java/android/hardware/camera2/params/RggbChannelVector.java
+++ b/core/java/android/hardware/camera2/params/RggbChannelVector.java
@@ -190,6 +190,32 @@
                 Float.floatToIntBits(mBlue);
     }
 
+    /**
+     * Return the RggbChannelVector as a string representation.
+     *
+     * <p> {@code "RggbChannelVector{R:%f, G_even:%f, G_odd:%f, B:%f}"}, where each
+     * {@code %f} respectively represents one of the the four color channels. </p>
+     *
+     * @return string representation of {@link RggbChannelVector}
+     */
+    @Override
+    public String toString() {
+        return String.format("RggbChannelVector%s", toShortString());
+    }
+
+    /**
+     * Return the RggbChannelVector as a string in compact form.
+     *
+     * <p> {@code "{R:%f, G_even:%f, G_odd:%f, B:%f}"}, where each {@code %f}
+     * respectively represents one of the the four color channels. </p>
+     *
+     * @return compact string representation of {@link RggbChannelVector}
+     */
+    private String toShortString() {
+        return String.format("{R:%f, G_even:%f, G_odd:%f, B:%f}",
+                mRed, mGreenEven, mGreenOdd, mBlue);
+    }
+
     private final float mRed;
     private final float mGreenEven;
     private final float mGreenOdd;
diff --git a/core/java/android/hardware/camera2/params/StreamConfigurationMap.java b/core/java/android/hardware/camera2/params/StreamConfigurationMap.java
index 2e6b9ae..5d226e3 100644
--- a/core/java/android/hardware/camera2/params/StreamConfigurationMap.java
+++ b/core/java/android/hardware/camera2/params/StreamConfigurationMap.java
@@ -142,7 +142,7 @@
      * or in {@link PixelFormat} (and there is no possibility of collision).</p>
      *
      * <p>Formats listed in this array are guaranteed to return true if queried with
-     * {@link #isOutputSupportedFor(int).</p>
+     * {@link #isOutputSupportedFor(int)}.</p>
      *
      * @return an array of integer format
      *
@@ -339,6 +339,11 @@
      * @see #isOutputSupportedFor(Class)
      */
     public <T> Size[] getOutputSizes(Class<T> klass) {
+        // Image reader is "supported", but never for implementation-defined formats; return empty
+        if (android.media.ImageReader.class.isAssignableFrom(klass)) {
+            return new Size[0];
+        }
+
         if (isOutputSupportedFor(klass) == false) {
             return null;
         }
diff --git a/core/java/android/hardware/camera2/params/TonemapCurve.java b/core/java/android/hardware/camera2/params/TonemapCurve.java
index 481d67a..398a7e9 100644
--- a/core/java/android/hardware/camera2/params/TonemapCurve.java
+++ b/core/java/android/hardware/camera2/params/TonemapCurve.java
@@ -81,7 +81,8 @@
      * <p>Values are stored as a contiguous array of {@code (Pin, Pout)} points.</p>
      *
      * <p>All parameters may have independent length but should have at most
-     * {@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS} * {@value #POINT_SIZE} elements.</p>
+     * {@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS} * {@value #POINT_SIZE} elements and
+     * at least 2 * {@value #POINT_SIZE} elements.</p>
      *
      * <p>All sub-elements must be in the inclusive range of
      * [{@value #LEVEL_BLACK}, {@value #LEVEL_WHITE}].</p>
@@ -110,6 +111,10 @@
         checkArgumentArrayLengthDivisibleBy(green, POINT_SIZE, "green");
         checkArgumentArrayLengthDivisibleBy(blue, POINT_SIZE, "blue");
 
+        checkArgumentArrayLengthNoLessThan(red, MIN_CURVE_LENGTH, "red");
+        checkArgumentArrayLengthNoLessThan(green, MIN_CURVE_LENGTH, "green");
+        checkArgumentArrayLengthNoLessThan(blue, MIN_CURVE_LENGTH, "blue");
+
         checkArrayElementsInRange(red, LEVEL_BLACK, LEVEL_WHITE, "red");
         checkArrayElementsInRange(green, LEVEL_BLACK, LEVEL_WHITE, "green");
         checkArrayElementsInRange(blue, LEVEL_BLACK, LEVEL_WHITE, "blue");
@@ -140,6 +145,14 @@
         return colorChannel;
     }
 
+    private static void checkArgumentArrayLengthNoLessThan(float[] array, int minLength,
+            String arrayName) {
+        if (array.length < minLength) {
+            throw new IllegalArgumentException(arrayName + " size must be at least "
+                    + minLength);
+        }
+    }
+
     /**
      * Get the number of points stored in this tonemap curve for the specified color channel.
      *
@@ -270,6 +283,47 @@
         return mHashCode;
     }
 
+    /**
+     * Return the TonemapCurve as a string representation.
+     *
+     * <p> {@code "TonemapCurve{R:[(%f, %f), (%f, %f) ... (%f, %f)], G:[(%f, %f), (%f, %f) ...
+     * (%f, %f)], B:[(%f, %f), (%f, %f) ... (%f, %f)]}"},
+     * where each {@code (%f, %f)} respectively represents one point of the corresponding
+     * tonemap curve. </p>
+     *
+     * @return string representation of {@link TonemapCurve}
+     */
+    @Override
+    public String toString() {
+        StringBuilder sb = new StringBuilder("TonemapCurve{");
+        sb.append("R:");
+        sb.append(curveToString(CHANNEL_RED));
+        sb.append(", G:");
+        sb.append(curveToString(CHANNEL_GREEN));
+        sb.append(", B:");
+        sb.append(curveToString(CHANNEL_BLUE));
+        sb.append("}");
+        return sb.toString();
+    }
+
+    private String curveToString(int colorChannel) {
+        checkArgumentColorChannel(colorChannel);
+        StringBuilder sb = new StringBuilder("[");
+        float[] curve = getCurve(colorChannel);
+        int pointCount = curve.length / POINT_SIZE;
+        for (int i = 0, j = 0; i < pointCount; i++, j += 2) {
+            sb.append("(");
+            sb.append(curve[j]);
+            sb.append(", ");
+            sb.append(curve[j+1]);
+            sb.append("), ");
+        }
+        // trim extra ", " at the end. Guaranteed to work because pointCount >= 2
+        sb.setLength(sb.length() - 2);
+        sb.append("]");
+        return sb.toString();
+    }
+
     private float[] getCurve(int colorChannel) {
         switch (colorChannel) {
             case CHANNEL_RED:
@@ -285,6 +339,8 @@
 
     private final static int OFFSET_POINT_IN = 0;
     private final static int OFFSET_POINT_OUT = 1;
+    private final static int TONEMAP_MIN_CURVE_POINTS = 2;
+    private final static int MIN_CURVE_LENGTH = TONEMAP_MIN_CURVE_POINTS * POINT_SIZE;
 
     private final float[] mRed;
     private final float[] mGreen;
@@ -292,4 +348,4 @@
 
     private int mHashCode;
     private boolean mHashCalculated = false;
-};
+}
diff --git a/core/java/android/hardware/camera2/utils/CameraBinderDecorator.java b/core/java/android/hardware/camera2/utils/CameraBinderDecorator.java
index 83ebadd..d461bca 100644
--- a/core/java/android/hardware/camera2/utils/CameraBinderDecorator.java
+++ b/core/java/android/hardware/camera2/utils/CameraBinderDecorator.java
@@ -19,6 +19,7 @@
 import static android.hardware.camera2.CameraAccessException.CAMERA_DISABLED;
 import static android.hardware.camera2.CameraAccessException.CAMERA_DISCONNECTED;
 import static android.hardware.camera2.CameraAccessException.CAMERA_IN_USE;
+import static android.hardware.camera2.CameraAccessException.CAMERA_ERROR;
 import static android.hardware.camera2.CameraAccessException.MAX_CAMERAS_IN_USE;
 import static android.hardware.camera2.CameraAccessException.CAMERA_DEPRECATED_HAL;
 
@@ -41,6 +42,7 @@
     public static final int BAD_VALUE = -22;
     public static final int DEAD_OBJECT = -32;
     public static final int INVALID_OPERATION = -38;
+    public static final int TIMED_OUT = -110;
 
     /**
      * TODO: add as error codes in Errors.h
@@ -112,6 +114,9 @@
                 throw new IllegalArgumentException("Bad argument passed to camera service");
             case DEAD_OBJECT:
                 throw new CameraRuntimeException(CAMERA_DISCONNECTED);
+            case TIMED_OUT:
+                throw new CameraRuntimeException(CAMERA_ERROR,
+                        "Operation timed out in camera service");
             case EACCES:
                 throw new CameraRuntimeException(CAMERA_DISABLED);
             case EBUSY:
@@ -123,7 +128,7 @@
             case EOPNOTSUPP:
                 throw new CameraRuntimeException(CAMERA_DEPRECATED_HAL);
             case INVALID_OPERATION:
-                throw new IllegalStateException(
+                throw new CameraRuntimeException(CAMERA_ERROR,
                         "Illegal state encountered in camera service.");
         }
 
diff --git a/core/java/android/hardware/display/DisplayManager.java b/core/java/android/hardware/display/DisplayManager.java
index 51b7229..b077e06 100644
--- a/core/java/android/hardware/display/DisplayManager.java
+++ b/core/java/android/hardware/display/DisplayManager.java
@@ -472,7 +472,7 @@
     /**
      * Creates a virtual display.
      *
-     * @see #createVirtualDisplay(String, int, int, int, Surface, int, VirtualDisplay.Callbacks)
+     * @see #createVirtualDisplay(String, int, int, int, Surface, int, VirtualDisplay.Callback)
      */
     public VirtualDisplay createVirtualDisplay(@NonNull String name,
             int width, int height, int densityDpi, @Nullable Surface surface, int flags) {
@@ -513,7 +513,7 @@
      * {@link #VIRTUAL_DISPLAY_FLAG_PUBLIC}, {@link #VIRTUAL_DISPLAY_FLAG_PRESENTATION},
      * {@link #VIRTUAL_DISPLAY_FLAG_SECURE}, {@link #VIRTUAL_DISPLAY_FLAG_OWN_CONTENT_ONLY},
      * or {@link #VIRTUAL_DISPLAY_FLAG_AUTO_MIRROR}.
-     * @param callbacks Callbacks to call when the state of the {@link VirtualDisplay} changes
+     * @param callback Callback to call when the state of the {@link VirtualDisplay} changes
      * @param handler The handler on which the listener should be invoked, or null
      * if the listener should be invoked on the calling thread's looper.
      * @return The newly created virtual display, or null if the application could
@@ -524,17 +524,17 @@
      */
     public VirtualDisplay createVirtualDisplay(@NonNull String name,
             int width, int height, int densityDpi, @Nullable Surface surface, int flags,
-            @Nullable VirtualDisplay.Callbacks callbacks, @Nullable Handler handler) {
+            @Nullable VirtualDisplay.Callback callback, @Nullable Handler handler) {
         return createVirtualDisplay(null,
-                name, width, height, densityDpi, surface, flags, callbacks, handler);
+                name, width, height, densityDpi, surface, flags, callback, handler);
     }
 
     /** @hide */
     public VirtualDisplay createVirtualDisplay(@Nullable MediaProjection projection,
             @NonNull String name, int width, int height, int densityDpi, @Nullable Surface surface,
-            int flags, @Nullable VirtualDisplay.Callbacks callbacks, @Nullable Handler handler) {
+            int flags, @Nullable VirtualDisplay.Callback callback, @Nullable Handler handler) {
         return mGlobal.createVirtualDisplay(mContext, projection,
-                name, width, height, densityDpi, surface, flags, callbacks, handler);
+                name, width, height, densityDpi, surface, flags, callback, handler);
     }
 
     /**
diff --git a/core/java/android/hardware/display/DisplayManagerGlobal.java b/core/java/android/hardware/display/DisplayManagerGlobal.java
index 8b44f3b..0051ef5 100644
--- a/core/java/android/hardware/display/DisplayManagerGlobal.java
+++ b/core/java/android/hardware/display/DisplayManagerGlobal.java
@@ -372,7 +372,7 @@
 
     public VirtualDisplay createVirtualDisplay(Context context, MediaProjection projection,
             String name, int width, int height, int densityDpi, Surface surface, int flags,
-            VirtualDisplay.Callbacks callbacks, Handler handler) {
+            VirtualDisplay.Callback callback, Handler handler) {
         if (TextUtils.isEmpty(name)) {
             throw new IllegalArgumentException("name must be non-null and non-empty");
         }
@@ -381,7 +381,7 @@
                     + "greater than 0");
         }
 
-        VirtualDisplayCallbacks callbackWrapper = new VirtualDisplayCallbacks(callbacks, handler);
+        VirtualDisplayCallback callbackWrapper = new VirtualDisplayCallback(callback, handler);
         IMediaProjection projectionToken = projection != null ? projection.getProjection() : null;
         int displayId;
         try {
@@ -408,7 +408,7 @@
         return new VirtualDisplay(this, display, callbackWrapper, surface);
     }
 
-    public void setVirtualDisplaySurface(IVirtualDisplayCallbacks token, Surface surface) {
+    public void setVirtualDisplaySurface(IVirtualDisplayCallback token, Surface surface) {
         try {
             mDm.setVirtualDisplaySurface(token, surface);
         } catch (RemoteException ex) {
@@ -416,7 +416,7 @@
         }
     }
 
-    public void resizeVirtualDisplay(IVirtualDisplayCallbacks token,
+    public void resizeVirtualDisplay(IVirtualDisplayCallback token,
             int width, int height, int densityDpi) {
         try {
             mDm.resizeVirtualDisplay(token, width, height, densityDpi);
@@ -425,7 +425,7 @@
         }
     }
 
-    public void releaseVirtualDisplay(IVirtualDisplayCallbacks token) {
+    public void releaseVirtualDisplay(IVirtualDisplayCallback token) {
         try {
             mDm.releaseVirtualDisplay(token);
         } catch (RemoteException ex) {
@@ -476,61 +476,61 @@
         }
     }
 
-    private final static class VirtualDisplayCallbacks extends IVirtualDisplayCallbacks.Stub {
-        private VirtualDisplayCallbacksDelegate mDelegate;
+    private final static class VirtualDisplayCallback extends IVirtualDisplayCallback.Stub {
+        private VirtualDisplayCallbackDelegate mDelegate;
 
-        public VirtualDisplayCallbacks(VirtualDisplay.Callbacks callbacks, Handler handler) {
-            if (callbacks != null) {
-                mDelegate = new VirtualDisplayCallbacksDelegate(callbacks, handler);
+        public VirtualDisplayCallback(VirtualDisplay.Callback callback, Handler handler) {
+            if (callback != null) {
+                mDelegate = new VirtualDisplayCallbackDelegate(callback, handler);
             }
         }
 
         @Override // Binder call
-        public void onDisplayPaused() {
+        public void onPaused() {
             if (mDelegate != null) {
-                mDelegate.sendEmptyMessage(VirtualDisplayCallbacksDelegate.MSG_DISPLAY_PAUSED);
+                mDelegate.sendEmptyMessage(VirtualDisplayCallbackDelegate.MSG_DISPLAY_PAUSED);
             }
         }
 
         @Override // Binder call
-        public void onDisplayResumed() {
+        public void onResumed() {
             if (mDelegate != null) {
-                mDelegate.sendEmptyMessage(VirtualDisplayCallbacksDelegate.MSG_DISPLAY_RESUMED);
+                mDelegate.sendEmptyMessage(VirtualDisplayCallbackDelegate.MSG_DISPLAY_RESUMED);
             }
         }
 
         @Override // Binder call
-        public void onDisplayStopped() {
+        public void onStopped() {
             if (mDelegate != null) {
-                mDelegate.sendEmptyMessage(VirtualDisplayCallbacksDelegate.MSG_DISPLAY_STOPPED);
+                mDelegate.sendEmptyMessage(VirtualDisplayCallbackDelegate.MSG_DISPLAY_STOPPED);
             }
         }
     }
 
-    private final static class VirtualDisplayCallbacksDelegate extends Handler {
+    private final static class VirtualDisplayCallbackDelegate extends Handler {
         public static final int MSG_DISPLAY_PAUSED = 0;
         public static final int MSG_DISPLAY_RESUMED = 1;
         public static final int MSG_DISPLAY_STOPPED = 2;
 
-        private final VirtualDisplay.Callbacks mCallbacks;
+        private final VirtualDisplay.Callback mCallback;
 
-        public VirtualDisplayCallbacksDelegate(VirtualDisplay.Callbacks callbacks,
+        public VirtualDisplayCallbackDelegate(VirtualDisplay.Callback callback,
                 Handler handler) {
             super(handler != null ? handler.getLooper() : Looper.myLooper(), null, true /*async*/);
-            mCallbacks = callbacks;
+            mCallback = callback;
         }
 
         @Override
         public void handleMessage(Message msg) {
             switch (msg.what) {
                 case MSG_DISPLAY_PAUSED:
-                    mCallbacks.onDisplayPaused();
+                    mCallback.onPaused();
                     break;
                 case MSG_DISPLAY_RESUMED:
-                    mCallbacks.onDisplayResumed();
+                    mCallback.onResumed();
                     break;
                 case MSG_DISPLAY_STOPPED:
-                    mCallbacks.onDisplayStopped();
+                    mCallback.onStopped();
                     break;
             }
         }
diff --git a/core/java/android/hardware/display/IDisplayManager.aidl b/core/java/android/hardware/display/IDisplayManager.aidl
index cfaa5a0..4486dd4 100644
--- a/core/java/android/hardware/display/IDisplayManager.aidl
+++ b/core/java/android/hardware/display/IDisplayManager.aidl
@@ -17,7 +17,7 @@
 package android.hardware.display;
 
 import android.hardware.display.IDisplayManagerCallback;
-import android.hardware.display.IVirtualDisplayCallbacks;
+import android.hardware.display.IVirtualDisplayCallback;
 import android.hardware.display.WifiDisplay;
 import android.hardware.display.WifiDisplayStatus;
 import android.media.projection.IMediaProjection;
@@ -61,17 +61,17 @@
 
     // Requires CAPTURE_VIDEO_OUTPUT, CAPTURE_SECURE_VIDEO_OUTPUT, or an appropriate
     // MediaProjection token for certain combinations of flags.
-    int createVirtualDisplay(in IVirtualDisplayCallbacks callbacks,
+    int createVirtualDisplay(in IVirtualDisplayCallback callback,
             in IMediaProjection projectionToken, String packageName, String name,
             int width, int height, int densityDpi, in Surface surface, int flags);
 
     // No permissions required, but must be same Uid as the creator.
-    void resizeVirtualDisplay(in IVirtualDisplayCallbacks token,
+    void resizeVirtualDisplay(in IVirtualDisplayCallback token,
             int width, int height, int densityDpi);
 
     // No permissions required but must be same Uid as the creator.
-    void setVirtualDisplaySurface(in IVirtualDisplayCallbacks token, in Surface surface);
+    void setVirtualDisplaySurface(in IVirtualDisplayCallback token, in Surface surface);
 
     // No permissions required but must be same Uid as the creator.
-    void releaseVirtualDisplay(in IVirtualDisplayCallbacks token);
+    void releaseVirtualDisplay(in IVirtualDisplayCallback token);
 }
diff --git a/core/java/android/hardware/display/IVirtualDisplayCallback.aidl b/core/java/android/hardware/display/IVirtualDisplayCallback.aidl
new file mode 100644
index 0000000..c3490d1
--- /dev/null
+++ b/core/java/android/hardware/display/IVirtualDisplayCallback.aidl
@@ -0,0 +1,41 @@
+/*
+ * Copyright (C) 2014 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 android.hardware.display;
+
+/** @hide */
+oneway interface IVirtualDisplayCallback {
+    /**
+     * Called when the virtual display video projection has been
+     * paused by the system or when the surface has been detached
+     * by the application by calling setSurface(null).
+     * The surface will not receive any more buffers while paused.
+     */
+    void onPaused();
+
+    /**
+     * Called when the virtual display video projection has been
+     * resumed after having been paused.
+     */
+    void onResumed();
+
+    /**
+     * Called when the virtual display video projection has been
+     * stopped by the system.  It will no longer receive frames
+     * and it will never be resumed.  It is still the responsibility
+     * of the application to release() the virtual display.
+     */
+    void onStopped();
+}
diff --git a/core/java/android/hardware/display/IVirtualDisplayCallbacks.aidl b/core/java/android/hardware/display/IVirtualDisplayCallbacks.aidl
deleted file mode 100644
index a1cdc01..0000000
--- a/core/java/android/hardware/display/IVirtualDisplayCallbacks.aidl
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.hardware.display;
-
-/** @hide */
-oneway interface IVirtualDisplayCallbacks {
-    /**
-     * Called when the virtual display video projection has been
-     * paused by the system or when the surface has been detached
-     * by the application by calling setSurface(null).
-     * The surface will not receive any more buffers while paused.
-     */
-    void onDisplayPaused();
-
-    /**
-     * Called when the virtual display video projection has been
-     * resumed after having been paused.
-     */
-    void onDisplayResumed();
-
-    /**
-     * Called when the virtual display video projection has been
-     * stopped by the system.  It will no longer receive frames
-     * and it will never be resumed.  It is still the responsibility
-     * of the application to release() the virtual display.
-     */
-    void onDisplayStopped();
-}
diff --git a/core/java/android/hardware/display/VirtualDisplay.java b/core/java/android/hardware/display/VirtualDisplay.java
index 1dd6978..4ddf10f 100644
--- a/core/java/android/hardware/display/VirtualDisplay.java
+++ b/core/java/android/hardware/display/VirtualDisplay.java
@@ -35,11 +35,11 @@
 public final class VirtualDisplay {
     private final DisplayManagerGlobal mGlobal;
     private final Display mDisplay;
-    private IVirtualDisplayCallbacks mToken;
+    private IVirtualDisplayCallback mToken;
     private Surface mSurface;
 
     VirtualDisplay(DisplayManagerGlobal global, Display display,
-            IVirtualDisplayCallbacks token, Surface surface) {
+            IVirtualDisplayCallback token, Surface surface) {
         mGlobal = global;
         mDisplay = display;
         mToken = token;
@@ -114,20 +114,20 @@
     /**
      * Interface for receiving information about a {@link VirtualDisplay}'s state changes.
      */
-    public static abstract class Callbacks {
+    public static abstract class Callback {
         /**
          * Called when the virtual display video projection has been
          * paused by the system or when the surface has been detached
          * by the application by calling setSurface(null).
          * The surface will not receive any more buffers while paused.
          */
-         public void onDisplayPaused() { }
+         public void onPaused() { }
 
         /**
          * Called when the virtual display video projection has been
          * resumed after having been paused.
          */
-         public void onDisplayResumed() { }
+         public void onResumed() { }
 
         /**
          * Called when the virtual display video projection has been
@@ -135,6 +135,6 @@
          * and it will never be resumed.  It is still the responsibility
          * of the application to release() the virtual display.
          */
-        public void onDisplayStopped() { }
+        public void onStopped() { }
     }
 }
diff --git a/core/java/android/hardware/hdmi/HdmiClient.java b/core/java/android/hardware/hdmi/HdmiClient.java
index f95ed0f..aba90e4 100644
--- a/core/java/android/hardware/hdmi/HdmiClient.java
+++ b/core/java/android/hardware/hdmi/HdmiClient.java
@@ -50,7 +50,7 @@
         try {
             mService.sendKeyEvent(getDeviceType(), keyCode, isPressed);
         } catch (RemoteException e) {
-            Log.e(TAG, "queryDisplayStatus threw exception ", e);
+            Log.e(TAG, "sendKeyEvent threw exception ", e);
         }
     }
 
diff --git a/core/java/android/hardware/hdmi/HdmiControlManager.java b/core/java/android/hardware/hdmi/HdmiControlManager.java
index 3c61e39..30f3576 100644
--- a/core/java/android/hardware/hdmi/HdmiControlManager.java
+++ b/core/java/android/hardware/hdmi/HdmiControlManager.java
@@ -48,11 +48,36 @@
     @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
     public static final String ACTION_OSD_MESSAGE = "android.hardware.hdmi.action.OSD_MESSAGE";
 
+    // --- Messages for ACTION_OSD_MESSAGE ---
+    /**
+     * Message that ARC enabled device is connected to invalid port (non-ARC port).
+     */
+    public static final int OSD_MESSAGE_ARC_CONNECTED_INVALID_PORT = 1;
+
+    /**
+     * Message used by TV to receive volume status from Audio Receiver. It should check volume value
+     * that is retrieved from extra value with the key {@link #EXTRA_MESSAGE_EXTRAM_PARAM1}. If the
+     * value is in range of [0,100], it is current volume of Audio Receiver. And there is another
+     * value, {@link #AVR_VOLUME_MUTED}, which is used to inform volume mute.
+     */
+    public static final int OSD_MESSAGE_AVR_VOLUME_CHANGED = 2;
+
     /**
      * Used as an extra field in the intent {@link #ACTION_OSD_MESSAGE}. Contains the ID of
      * the message to display on screen.
      */
     public static final String EXTRA_MESSAGE_ID = "android.hardware.hdmi.extra.MESSAGE_ID";
+    /**
+     * Used as an extra field in the intent {@link #ACTION_OSD_MESSAGE}. Contains the extra value
+     * of the message.
+     */
+    public static final String EXTRA_MESSAGE_EXTRAM_PARAM1 =
+            "android.hardware.hdmi.extra.MESSAGE_EXTRA_PARAM1";
+
+    /**
+     * Volume value for mute state.
+     */
+    public static final int AVR_VOLUME_MUTED = 101;
 
     public static final int POWER_STATUS_UNKNOWN = -1;
     public static final int POWER_STATUS_ON = 0;
diff --git a/core/java/android/hardware/hdmi/HdmiDeviceInfo.java b/core/java/android/hardware/hdmi/HdmiDeviceInfo.java
index 97da3a2..7abea36 100644
--- a/core/java/android/hardware/hdmi/HdmiDeviceInfo.java
+++ b/core/java/android/hardware/hdmi/HdmiDeviceInfo.java
@@ -230,7 +230,7 @@
         mDeviceType = DEVICE_RESERVED;
         mVendorId = 0;
         mDevicePowerStatus = HdmiControlManager.POWER_STATUS_UNKNOWN;
-        mDisplayName = "MHL";
+        mDisplayName = "Mobile";
 
         mDeviceId = adopterId;
         mAdopterId = deviceId;
@@ -416,7 +416,8 @@
         switch (mHdmiDeviceType) {
             case HDMI_DEVICE_TYPE_CEC:
                 s.append("CEC: ");
-                s.append("logical_address: ").append(mLogicalAddress).append(" ");
+                s.append("logical_address: ").append(String.format("0x%02X", mLogicalAddress));
+                s.append(" ");
                 s.append("device_type: ").append(mDeviceType).append(" ");
                 s.append("vendor_id: ").append(mVendorId).append(" ");
                 s.append("display_name: ").append(mDisplayName).append(" ");
@@ -424,8 +425,8 @@
                 break;
             case HDMI_DEVICE_TYPE_MHL:
                 s.append("MHL: ");
-                s.append("device_id: ").append(mDeviceId).append(" ");
-                s.append("adopter_id: ").append(mAdopterId).append(" ");
+                s.append("device_id: ").append(String.format("0x%04X", mDeviceId)).append(" ");
+                s.append("adopter_id: ").append(String.format("0x%04X", mAdopterId)).append(" ");
                 break;
 
             case HDMI_DEVICE_TYPE_HARDWARE:
@@ -434,7 +435,8 @@
             default:
                 return "";
         }
-        s.append("physical_address: ").append(String.format("0x04X", mPhysicalAddress)).append(" ");
+        s.append("physical_address: ").append(String.format("0x%04X", mPhysicalAddress));
+        s.append(" ");
         s.append("port_id: ").append(mPortId);
         return s.toString();
     }
diff --git a/core/java/android/hardware/hdmi/HdmiPortInfo.java b/core/java/android/hardware/hdmi/HdmiPortInfo.java
index 85e7531..2ec6126 100644
--- a/core/java/android/hardware/hdmi/HdmiPortInfo.java
+++ b/core/java/android/hardware/hdmi/HdmiPortInfo.java
@@ -166,7 +166,7 @@
     public String toString() {
         StringBuffer s = new StringBuffer();
         s.append("port_id: ").append(mId).append(", ");
-        s.append("address: ").append(mAddress).append(", ");
+        s.append("address: ").append(String.format("0x%04x", mAddress)).append(", ");
         s.append("cec: ").append(mCecSupported).append(", ");
         s.append("arc: ").append(mArcSupported).append(", ");
         s.append("mhl: ").append(mMhlSupported);
diff --git a/core/java/android/hardware/hdmi/HdmiTvClient.java b/core/java/android/hardware/hdmi/HdmiTvClient.java
index 354c05e..9d92fd9 100644
--- a/core/java/android/hardware/hdmi/HdmiTvClient.java
+++ b/core/java/android/hardware/hdmi/HdmiTvClient.java
@@ -35,6 +35,11 @@
 public final class HdmiTvClient extends HdmiClient {
     private static final String TAG = "HdmiTvClient";
 
+    /**
+     * Size of MHL register for vendor command
+     */
+    public static final int VENDOR_DATA_SIZE = 16;
+
     HdmiTvClient(IHdmiControlService service) {
         super(service);
     }
@@ -80,6 +85,15 @@
         }
     }
 
+    private static IHdmiControlCallback getCallbackWrapper(final SelectCallback callback) {
+        return new IHdmiControlCallback.Stub() {
+            @Override
+            public void onComplete(int result) {
+                callback.onComplete(result);
+            }
+        };
+    }
+
     /**
      * Select a HDMI port to be a new route path.
      *
@@ -126,6 +140,15 @@
         }
     }
 
+    private static IHdmiInputChangeListener getListenerWrapper(final InputChangeListener listener) {
+        return new IHdmiInputChangeListener.Stub() {
+            @Override
+            public void onChanged(HdmiDeviceInfo info) {
+                listener.onChanged(info);
+            }
+        };
+    }
+
     /**
      * Set system audio volume
      *
@@ -170,6 +193,38 @@
         }
     }
 
+    private static IHdmiRecordListener getListenerWrapper(final HdmiRecordListener callback) {
+        return new IHdmiRecordListener.Stub() {
+            @Override
+            public byte[] getOneTouchRecordSource(int recorderAddress) {
+                HdmiRecordSources.RecordSource source =
+                        callback.getOneTouchRecordSource(recorderAddress);
+                if (source == null) {
+                    return EmptyArray.BYTE;
+                }
+                byte[] data = new byte[source.getDataSize(true)];
+                source.toByteArray(true, data, 0);
+                return data;
+            }
+
+            @Override
+            public void onOneTouchRecordResult(int result) {
+                callback.onOneTouchRecordResult(result);
+            }
+
+            @Override
+            public void onTimerRecordingResult(int result) {
+                callback.onTimerRecordingResult(
+                        HdmiRecordListener.TimerStatusData.parseFrom(result));
+            }
+
+            @Override
+            public void onClearTimerRecordingResult(int result) {
+                callback.onClearTimerRecordingResult(result);
+            }
+        };
+    }
+
     /**
      * Start one touch recording with the given recorder address and recorder source.
      * <p>
@@ -276,53 +331,63 @@
         }
     }
 
-    private static IHdmiControlCallback getCallbackWrapper(final SelectCallback callback) {
-        return new IHdmiControlCallback.Stub() {
+    /**
+     * Interface used to get incoming MHL vendor command.
+     */
+    public interface HdmiMhlVendorCommandListener {
+        void onReceived(int portId, int offset, int length, byte[] data);
+    }
+
+    /**
+     * Set {@link HdmiMhlVendorCommandListener} to get incoming MHL vendor command.
+     *
+     * @param listener to receive incoming MHL vendor command
+     */
+    public void setHdmiMhlVendorCommandListener(HdmiMhlVendorCommandListener listener) {
+        if (listener == null) {
+            throw new IllegalArgumentException("listener must not be null.");
+        }
+        try {
+            mService.addHdmiMhlVendorCommandListener(getListenerWrapper(listener));
+        } catch (RemoteException e) {
+            Log.e(TAG, "failed to set hdmi mhl vendor command listener: ", e);
+        }
+    }
+
+    private IHdmiMhlVendorCommandListener getListenerWrapper(
+            final HdmiMhlVendorCommandListener listener) {
+        return new IHdmiMhlVendorCommandListener.Stub() {
             @Override
-            public void onComplete(int result) {
-                callback.onComplete(result);
+            public void onReceived(int portId, int offset, int length, byte[] data) {
+                listener.onReceived(portId, offset, length, data);
             }
         };
     }
 
-    private static IHdmiInputChangeListener getListenerWrapper(final InputChangeListener listener) {
-        return new IHdmiInputChangeListener.Stub() {
-            @Override
-            public void onChanged(HdmiDeviceInfo info) {
-                listener.onChanged(info);
-            }
-        };
-    }
+    /**
+     * Send MHL vendor command to the device connected to a port of the given portId.
+     *
+     * @param portId id of port to send MHL vendor command
+     * @param offset offset in the in given data
+     * @param length length of data. offset + length should be bound to length of data.
+     * @param data container for vendor command data. It should be 16 bytes.
+     * @throws IllegalArgumentException if the given parameters are invalid
+     */
+    public void sendMhlVendorCommand(int portId, int offset, int length, byte[] data) {
+        if (data == null || data.length != VENDOR_DATA_SIZE) {
+            throw new IllegalArgumentException("Invalid vendor command data.");
+        }
+        if (offset < 0 || offset >= VENDOR_DATA_SIZE) {
+            throw new IllegalArgumentException("Invalid offset:" + offset);
+        }
+        if (length < 0 || offset + length > VENDOR_DATA_SIZE) {
+            throw new IllegalArgumentException("Invalid length:" + length);
+        }
 
-    private static IHdmiRecordListener getListenerWrapper(final HdmiRecordListener callback) {
-        return new IHdmiRecordListener.Stub() {
-            @Override
-            public byte[] getOneTouchRecordSource(int recorderAddress) {
-                HdmiRecordSources.RecordSource source =
-                        callback.getOneTouchRecordSource(recorderAddress);
-                if (source == null) {
-                    return EmptyArray.BYTE;
-                }
-                byte[] data = new byte[source.getDataSize(true)];
-                source.toByteArray(true, data, 0);
-                return data;
-            }
-
-            @Override
-            public void onOneTouchRecordResult(int result) {
-                callback.onOneTouchRecordResult(result);
-            }
-
-            @Override
-            public void onTimerRecordingResult(int result) {
-                callback.onTimerRecordingResult(
-                        HdmiRecordListener.TimerStatusData.parseFrom(result));
-            }
-
-            @Override
-            public void onClearTimerRecordingResult(int result) {
-                callback.onClearTimerRecordingResult(result);
-            }
-        };
+        try {
+            mService.sendMhlVendorCommand(portId, offset, length, data);
+        } catch (RemoteException e) {
+            Log.e(TAG, "failed to send vendor command: ", e);
+        }
     }
 }
diff --git a/core/java/android/hardware/hdmi/IHdmiControlService.aidl b/core/java/android/hardware/hdmi/IHdmiControlService.aidl
index 17f290b..4866a9a 100644
--- a/core/java/android/hardware/hdmi/IHdmiControlService.aidl
+++ b/core/java/android/hardware/hdmi/IHdmiControlService.aidl
@@ -22,6 +22,7 @@
 import android.hardware.hdmi.IHdmiDeviceEventListener;
 import android.hardware.hdmi.IHdmiHotplugEventListener;
 import android.hardware.hdmi.IHdmiInputChangeListener;
+import android.hardware.hdmi.IHdmiMhlVendorCommandListener;
 import android.hardware.hdmi.IHdmiRecordListener;
 import android.hardware.hdmi.IHdmiSystemAudioModeChangeListener;
 import android.hardware.hdmi.IHdmiVendorCommandListener;
@@ -61,9 +62,12 @@
     void sendVendorCommand(int deviceType, int targetAddress, in byte[] params,
             boolean hasVendorId);
     void addVendorCommandListener(IHdmiVendorCommandListener listener, int deviceType);
+    void sendStandby(int deviceType, int deviceId);
     void setHdmiRecordListener(IHdmiRecordListener callback);
     void startOneTouchRecord(int recorderAddress, in byte[] recordSource);
     void stopOneTouchRecord(int recorderAddress);
     void startTimerRecording(int recorderAddress, int sourceType, in byte[] recordSource);
     void clearTimerRecording(int recorderAddress, int sourceType, in byte[] recordSource);
+    void sendMhlVendorCommand(int portId, int offset, int length, in byte[] data);
+    void addHdmiMhlVendorCommandListener(IHdmiMhlVendorCommandListener listener);
 }
diff --git a/core/java/android/hardware/hdmi/IHdmiMhlVendorCommandListener.aidl b/core/java/android/hardware/hdmi/IHdmiMhlVendorCommandListener.aidl
new file mode 100644
index 0000000..4696677
--- /dev/null
+++ b/core/java/android/hardware/hdmi/IHdmiMhlVendorCommandListener.aidl
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2014 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 android.hardware.hdmi;
+
+ /**
+ * Callback interface definition for MHL client to get the vendor command.
+ *
+ * @hide
+ */
+ oneway interface IHdmiMhlVendorCommandListener {
+      void onReceived(int portId, int offset, int length, in byte[] data);
+ }
diff --git a/core/java/android/hardware/location/GeofenceHardware.java b/core/java/android/hardware/location/GeofenceHardware.java
index 2d82cba..7dd105a 100644
--- a/core/java/android/hardware/location/GeofenceHardware.java
+++ b/core/java/android/hardware/location/GeofenceHardware.java
@@ -15,6 +15,7 @@
  */
 package android.hardware.location;
 
+import android.annotation.SystemApi;
 import android.location.Location;
 import android.os.Build;
 import android.os.RemoteException;
@@ -43,7 +44,10 @@
  * an appropriate transition would be triggered. The "reasonably confident" parameter
  * depends on the hardware system and the positioning algorithms used.
  * For instance, {@link #MONITORING_TYPE_GPS_HARDWARE} uses 95% as a confidence level.
+ *
+ * @hide
  */
+@SystemApi
 public final class GeofenceHardware {
     private IGeofenceHardware mService;
 
@@ -162,9 +166,7 @@
     private HashMap<GeofenceHardwareMonitorCallback, GeofenceHardwareMonitorCallbackWrapper>
             mMonitorCallbacks = new HashMap<GeofenceHardwareMonitorCallback,
                     GeofenceHardwareMonitorCallbackWrapper>();
-    /**
-     * @hide
-     */
+
     public GeofenceHardware(IGeofenceHardware service) {
         mService = service;
     }
diff --git a/core/java/android/hardware/location/GeofenceHardwareCallback.java b/core/java/android/hardware/location/GeofenceHardwareCallback.java
index 6cad3da..a2a7ed0 100644
--- a/core/java/android/hardware/location/GeofenceHardwareCallback.java
+++ b/core/java/android/hardware/location/GeofenceHardwareCallback.java
@@ -16,11 +16,15 @@
 
 package android.hardware.location;
 
+import android.annotation.SystemApi;
 import android.location.Location;
 
 /**
  * The callback class associated with the APIs in {@link GeofenceHardware}
+ *
+ * @hide
  */
+@SystemApi
 public abstract class GeofenceHardwareCallback {
     /**
      * The callback called when there is a transition to report for the specific
diff --git a/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java b/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java
index f927027..d7daa10 100644
--- a/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java
+++ b/core/java/android/hardware/location/GeofenceHardwareMonitorCallback.java
@@ -16,12 +16,16 @@
 
 package android.hardware.location;
 
+import android.annotation.SystemApi;
 import android.location.Location;
 
 /**
  * The callback class associated with the status change of hardware monitors
  * in {@link GeofenceHardware}
+ *
+ * @hide
  */
+@SystemApi
 public abstract class GeofenceHardwareMonitorCallback {
     /**
      * The callback called when the state of a monitoring system changes.
diff --git a/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java b/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java
index 9c460d2..7079237 100644
--- a/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java
+++ b/core/java/android/hardware/location/GeofenceHardwareMonitorEvent.java
@@ -16,13 +16,17 @@
 
 package android.hardware.location;
 
+import android.annotation.SystemApi;
 import android.location.Location;
 import android.os.Parcel;
 import android.os.Parcelable;
 
 /**
  * A class that represents an event for each change in the state of a monitoring system.
+ *
+ * @hide
  */
+@SystemApi
 public class GeofenceHardwareMonitorEvent implements Parcelable {
     private final int mMonitoringType;
     private final int mMonitoringStatus;
diff --git a/core/java/android/hardware/location/GeofenceHardwareRequest.java b/core/java/android/hardware/location/GeofenceHardwareRequest.java
index 887c4ad..68545a8 100644
--- a/core/java/android/hardware/location/GeofenceHardwareRequest.java
+++ b/core/java/android/hardware/location/GeofenceHardwareRequest.java
@@ -16,12 +16,16 @@
 
 package android.hardware.location;
 
+import android.annotation.SystemApi;
+
 /**
  * This class represents the characteristics of the geofence.
  *
  * <p> Use this in conjunction with {@link GeofenceHardware} APIs.
+ *
+ * @hide
  */
-
+@SystemApi
 public final class GeofenceHardwareRequest {
     static final int GEOFENCE_TYPE_CIRCLE = 0;
     private int mType;
diff --git a/core/java/android/hardware/soundtrigger/KeyphraseEnrollmentInfo.java b/core/java/android/hardware/soundtrigger/KeyphraseEnrollmentInfo.java
index 0dbde6b..518a874 100644
--- a/core/java/android/hardware/soundtrigger/KeyphraseEnrollmentInfo.java
+++ b/core/java/android/hardware/soundtrigger/KeyphraseEnrollmentInfo.java
@@ -25,6 +25,8 @@
 import android.content.res.TypedArray;
 import android.content.res.XmlResourceParser;
 import android.service.voice.AlwaysOnHotwordDetector;
+import android.text.TextUtils;
+import android.util.ArraySet;
 import android.util.AttributeSet;
 import android.util.Slog;
 import android.util.Xml;
@@ -35,6 +37,7 @@
 import java.io.IOException;
 import java.util.Arrays;
 import java.util.List;
+import java.util.Locale;
 
 /**
  * Enrollment information about the different available keyphrases.
@@ -74,6 +77,7 @@
             "com.android.intent.extra.VOICE_KEYPHRASE_HINT_TEXT";
     /**
      * Intent extra: The voice locale to use while managing the keyphrase.
+     * This is a BCP-47 language tag.
      */
     public static final String EXTRA_VOICE_KEYPHRASE_LOCALE =
             "com.android.intent.extra.VOICE_KEYPHRASE_LOCALE";
@@ -151,33 +155,8 @@
 
             TypedArray array = res.obtainAttributes(attrs,
                     com.android.internal.R.styleable.VoiceEnrollmentApplication);
-            int searchKeyphraseId = array.getInt(
-                    com.android.internal.R.styleable.VoiceEnrollmentApplication_searchKeyphraseId,
-                    -1);
-            if (searchKeyphraseId != -1) {
-                String searchKeyphrase = array.getString(com.android.internal.R.styleable
-                        .VoiceEnrollmentApplication_searchKeyphrase);
-                if (searchKeyphrase == null) {
-                    searchKeyphrase = "";
-                }
-                String searchKeyphraseSupportedLocales =
-                        array.getString(com.android.internal.R.styleable
-                                .VoiceEnrollmentApplication_searchKeyphraseSupportedLocales);
-                String[] supportedLocales = new String[0];
-                // Get all the supported locales from the comma-delimted string.
-                if (searchKeyphraseSupportedLocales != null
-                        && !searchKeyphraseSupportedLocales.isEmpty()) {
-                    supportedLocales = searchKeyphraseSupportedLocales.split(",");
-                }
-                int recognitionModes = array.getInt(com.android.internal.R.styleable
-                        .VoiceEnrollmentApplication_searchKeyphraseRecognitionFlags, 0);
-                mKeyphrases = new KeyphraseMetadata[1];
-                mKeyphrases[0] = new KeyphraseMetadata(
-                        searchKeyphraseId, searchKeyphrase, supportedLocales, recognitionModes);
-            } else {
-                mParseError = "searchKeyphraseId not specified in meta-data";
-                return;
-            }
+            initializeKeyphrasesFromTypedArray(array);
+            array.recycle();
         } catch (XmlPullParserException e) {
             mParseError = "Error parsing keyphrase enrollment meta-data: " + e;
             Slog.w(TAG, "error parsing keyphrase enrollment meta-data", e);
@@ -195,6 +174,65 @@
         }
     }
 
+    private void initializeKeyphrasesFromTypedArray(TypedArray array) {
+        // Get the keyphrase ID.
+        int searchKeyphraseId = array.getInt(
+                com.android.internal.R.styleable.VoiceEnrollmentApplication_searchKeyphraseId, -1);
+        if (searchKeyphraseId <= 0) {
+            mParseError = "No valid searchKeyphraseId specified in meta-data";
+            Slog.w(TAG, mParseError);
+            return;
+        }
+
+        // Get the keyphrase text.
+        String searchKeyphrase = array.getString(
+                com.android.internal.R.styleable.VoiceEnrollmentApplication_searchKeyphrase);
+        if (searchKeyphrase == null) {
+            mParseError = "No valid searchKeyphrase specified in meta-data";
+            Slog.w(TAG, mParseError);
+            return;
+        }
+
+        // Get the supported locales.
+        String searchKeyphraseSupportedLocales = array.getString(
+                com.android.internal.R.styleable
+                        .VoiceEnrollmentApplication_searchKeyphraseSupportedLocales);
+        if (searchKeyphraseSupportedLocales == null) {
+            mParseError = "No valid searchKeyphraseSupportedLocales specified in meta-data";
+            Slog.w(TAG, mParseError);
+            return;
+        }
+        ArraySet<Locale> locales = new ArraySet<>();
+        // Try adding locales if the locale string is non-empty.
+        if (!TextUtils.isEmpty(searchKeyphraseSupportedLocales)) {
+            try {
+                String[] supportedLocalesDelimited = searchKeyphraseSupportedLocales.split(",");
+                for (int i = 0; i < supportedLocalesDelimited.length; i++) {
+                    locales.add(Locale.forLanguageTag(supportedLocalesDelimited[i]));
+                }
+            } catch (Exception ex) {
+                // We catch a generic exception here because we don't want the system service
+                // to be affected by a malformed metadata because invalid locales were specified
+                // by the system application.
+                mParseError = "Error reading searchKeyphraseSupportedLocales from meta-data";
+                Slog.w(TAG, mParseError, ex);
+                return;
+            }
+        }
+
+        // Get the supported recognition modes.
+        int recognitionModes = array.getInt(com.android.internal.R.styleable
+                .VoiceEnrollmentApplication_searchKeyphraseRecognitionFlags, -1);
+        if (recognitionModes < 0) {
+            mParseError = "No valid searchKeyphraseRecognitionFlags specified in meta-data";
+            Slog.w(TAG, mParseError);
+            return;
+        }
+        mKeyphrases = new KeyphraseMetadata[1];
+        mKeyphrases[0] = new KeyphraseMetadata(searchKeyphraseId, searchKeyphrase, locales,
+                recognitionModes);
+    }
+
     public String getParseError() {
         return mParseError;
     }
@@ -217,11 +255,10 @@
      *        or {@link AlwaysOnHotwordDetector#MANAGE_ACTION_UN_ENROLL}
      * @param keyphrase The keyphrase that the user needs to be enrolled to.
      * @param locale The locale for which the enrollment needs to be performed.
-     *        This is a Java locale, for example "en_US".
      * @return An {@link Intent} to manage the keyphrase. This can be null if managing the
      *         given keyphrase/locale combination isn't possible.
      */
-    public Intent getManageKeyphraseIntent(int action, String keyphrase, String locale) {
+    public Intent getManageKeyphraseIntent(int action, String keyphrase, Locale locale) {
         if (mEnrollmentPackage == null || mEnrollmentPackage.isEmpty()) {
             Slog.w(TAG, "No enrollment application exists");
             return null;
@@ -231,7 +268,7 @@
             Intent intent = new Intent(ACTION_MANAGE_VOICE_KEYPHRASES)
                     .setPackage(mEnrollmentPackage)
                     .putExtra(EXTRA_VOICE_KEYPHRASE_HINT_TEXT, keyphrase)
-                    .putExtra(EXTRA_VOICE_KEYPHRASE_LOCALE, locale)
+                    .putExtra(EXTRA_VOICE_KEYPHRASE_LOCALE, locale.toLanguageTag())
                     .putExtra(EXTRA_VOICE_KEYPHRASE_ACTION, action);
             return intent;
         }
@@ -248,7 +285,7 @@
      * @return The metadata, if the enrollment client supports the given keyphrase
      *         and locale, null otherwise.
      */
-    public KeyphraseMetadata getKeyphraseMetadata(String keyphrase, String locale) {
+    public KeyphraseMetadata getKeyphraseMetadata(String keyphrase, Locale locale) {
         if (mKeyphrases == null || mKeyphrases.length == 0) {
             Slog.w(TAG, "Enrollment application doesn't support keyphrases");
             return null;
diff --git a/core/java/android/hardware/soundtrigger/KeyphraseMetadata.java b/core/java/android/hardware/soundtrigger/KeyphraseMetadata.java
index 38305f9..ed8c296 100644
--- a/core/java/android/hardware/soundtrigger/KeyphraseMetadata.java
+++ b/core/java/android/hardware/soundtrigger/KeyphraseMetadata.java
@@ -18,6 +18,8 @@
 
 import android.util.ArraySet;
 
+import java.util.Locale;
+
 /**
  * A Voice Keyphrase metadata read from the enrollment application.
  *
@@ -26,17 +28,14 @@
 public class KeyphraseMetadata {
     public final int id;
     public final String keyphrase;
-    public final ArraySet<String> supportedLocales;
+    public final ArraySet<Locale> supportedLocales;
     public final int recognitionModeFlags;
 
-    public KeyphraseMetadata(int id, String keyphrase, String[] supportedLocales,
+    public KeyphraseMetadata(int id, String keyphrase, ArraySet<Locale> supportedLocales,
             int recognitionModeFlags) {
         this.id = id;
         this.keyphrase = keyphrase;
-        this.supportedLocales = new ArraySet<String>(supportedLocales.length);
-        for (String locale : supportedLocales) {
-            this.supportedLocales.add(locale);
-        }
+        this.supportedLocales = supportedLocales;
         this.recognitionModeFlags = recognitionModeFlags;
     }
 
@@ -56,7 +55,7 @@
     /**
      * @return Indicates if we support the given locale.
      */
-    public boolean supportsLocale(String locale) {
+    public boolean supportsLocale(Locale locale) {
         return supportedLocales.isEmpty() || supportedLocales.contains(locale);
     }
 }
diff --git a/core/java/android/hardware/soundtrigger/SoundTrigger.java b/core/java/android/hardware/soundtrigger/SoundTrigger.java
index 7a49eb5..746ead2 100644
--- a/core/java/android/hardware/soundtrigger/SoundTrigger.java
+++ b/core/java/android/hardware/soundtrigger/SoundTrigger.java
@@ -480,7 +480,7 @@
             int capturePreambleMs = in.readInt();
             boolean triggerInData = in.readByte() == 1;
             AudioFormat captureFormat = null;
-            if (triggerInData) {
+            if (in.readByte() == 1) {
                 int sampleRate = in.readInt();
                 int encoding = in.readInt();
                 int channelMask = in.readInt();
@@ -508,7 +508,8 @@
             dest.writeInt(captureSession);
             dest.writeInt(captureDelayMs);
             dest.writeInt(capturePreambleMs);
-            if (triggerInData && (captureFormat != null)) {
+            dest.writeByte((byte) (triggerInData ? 1 : 0));
+            if (captureFormat != null) {
                 dest.writeByte((byte)1);
                 dest.writeInt(captureFormat.getSampleRate());
                 dest.writeInt(captureFormat.getEncoding());
@@ -872,7 +873,7 @@
             int capturePreambleMs = in.readInt();
             boolean triggerInData = in.readByte() == 1;
             AudioFormat captureFormat = null;
-            if (triggerInData) {
+            if (in.readByte() == 1) {
                 int sampleRate = in.readInt();
                 int encoding = in.readInt();
                 int channelMask = in.readInt();
@@ -898,7 +899,8 @@
             dest.writeInt(captureSession);
             dest.writeInt(captureDelayMs);
             dest.writeInt(capturePreambleMs);
-            if (triggerInData && (captureFormat != null)) {
+            dest.writeByte((byte) (triggerInData ? 1 : 0));
+            if (captureFormat != null) {
                 dest.writeByte((byte)1);
                 dest.writeInt(captureFormat.getSampleRate());
                 dest.writeInt(captureFormat.getEncoding());
diff --git a/core/java/android/inputmethodservice/InputMethodService.java b/core/java/android/inputmethodservice/InputMethodService.java
index ba811b7..2eb42a7 100644
--- a/core/java/android/inputmethodservice/InputMethodService.java
+++ b/core/java/android/inputmethodservice/InputMethodService.java
@@ -53,7 +53,6 @@
 import android.view.animation.AnimationUtils;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CursorAnchorInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.ExtractedText;
 import android.view.inputmethod.ExtractedTextRequest;
@@ -1711,13 +1710,12 @@
     }
 
     /**
-     * Called when the application has reported a new location of its text cursor.  This is only
-     * called if explicitly requested by the input method.  The default implementation does nothing.
-     * @param newCursor The new cursor position, in screen coordinates if the input method calls
-     * {@link InputConnection#requestCursorAnchorInfo(CursorAnchorInfoRequest)} with
-     * {@link CursorAnchorInfoRequest#FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES}. Otherwise,
-     * this is in local coordinates.
+     * Called when the application has reported a new location of its text
+     * cursor.  This is only called if explicitly requested by the input method.
+     * The default implementation does nothing.
+     * @deprecated Use {#link onUpdateCursorAnchorInfo(CursorAnchorInfo)} instead.
      */
+    @Deprecated
     public void onUpdateCursor(Rect newCursor) {
         // Intentionally empty
     }
diff --git a/core/java/android/net/ConnectivityManager.java b/core/java/android/net/ConnectivityManager.java
index 30be4da..e3cbef5 100644
--- a/core/java/android/net/ConnectivityManager.java
+++ b/core/java/android/net/ConnectivityManager.java
@@ -48,6 +48,8 @@
 import java.util.concurrent.atomic.AtomicInteger;
 import java.util.HashMap;
 
+import libcore.net.event.NetworkEventDispatcher;
+
 /**
  * Class that answers queries about the state of network connectivity. It also
  * notifies applications when network connectivity changes. Get an instance
@@ -284,98 +286,6 @@
     public static final String EXTRA_IS_CAPTIVE_PORTAL = "captivePortal";
 
     /**
-     * Broadcast Action: A connection has been established to a new network
-     * but a captive portal has been detected preventing internet connectivity.
-     * This broadcast is sent out prior to providing the user with a
-     * notification allowing them to sign into the network, as such it should
-     * only be used by apps that can automatically and silently (without user
-     * interaction) log into specific captive portals.  It should not be used
-     * by apps that prompt the user to sign in, as the user has not yet
-     * indicated they want to proceed with signing in.
-     * The new network is not the default network so it can only be accessed via
-     * the {@link Network} extra {@link #EXTRA_NETWORK}.
-     * This is an ordered broadcast and so it is perfectly acceptable for
-     * multiple receivers to in turn consider whether they are best suited to
-     * address the captive portal.
-     * A receiver should abort the broadcast if they are sure they are the
-     * appropriate handler of the captive portal.  If the broadcast is aborted,
-     * the result code must be set to one of the following:
-     * <ul>
-     *   <li>{@link #CAPTIVE_PORTAL_SIGNED_IN} The receiver has signed into the
-     *       captive portal.  After being verified to provide internet
-     *       connectivity, this network will be made the default (assuming
-     *       it is preferred over all other active networks).
-     *   </li>
-     *   <li>{@link #CAPTIVE_PORTAL_DISCONNECT} The receiver is familiar with
-     *       this captive portal and knows sign-in is impossible or the user
-     *       has indicated they do not want to pursue sign-in.  No other apps
-     *       will be given the option of signing in to the network.
-     *   </li>
-     * </ul>
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_CAPTIVE_PORTAL_DETECTED =
-            "android.net.conn.CAPTIVE_PORTAL_DETECTED";
-
-    /**
-     * Broadcast Action: A connection has been established to a new network,
-     * a captive portal has been detected preventing internet connectivity,
-     * the user was notified, and elected to sign into the captive portal.
-     * It may be used by apps that prompt the user to sign in.
-     * The new network is not the default network so it can only be accessed via
-     * the {@link Network} extra {@link #EXTRA_NETWORK}.
-     * This is an ordered broadcast and so it is perfectly acceptable for
-     * multiple receivers to in turn consider whether they are best suited to
-     * address the captive portal.
-     * A receiver should abort the broadcast if they are sure they are the
-     * appropriate handler of the captive portal.  If the broadcast is aborted,
-     * the result code must be set to one of the following:
-     * <ul>
-     *   <li>{@link #CAPTIVE_PORTAL_SIGNED_IN} The receiver has signed into the
-     *       captive portal.  After being verified to provide internet
-     *       connectivity, this network will be made the default (assuming
-     *       it is preferred over all other active networks).
-     *   </li>
-     *   <li>{@link #CAPTIVE_PORTAL_DISCONNECT} The user has indicated they do
-     *       not want to pursue sign-in.  No other apps will be given the
-     *       option of signing in to the network.
-     *   </li>
-     * </ul>
-     */
-    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
-    public static final String ACTION_CAPTIVE_PORTAL_SIGN_IN =
-            "android.net.conn.CAPTIVE_PORTAL_SIGN_IN";
-
-    /**
-     * The lookup key for a {@link Network} object passed along with a
-     * {@link #ACTION_CAPTIVE_PORTAL_DETECTED} or
-     * {@link #ACTION_CAPTIVE_PORTAL_SIGN_IN} intent.  This network is not the
-     * default network and must be accessed using this {@link Network} object.
-     * Retrieve with {@link android.content.Intent#getParcelableExtra(String)}.
-     */
-    public static final String EXTRA_NETWORK = "network";
-
-    /**
-     * Specified as a result code of a {@link #ACTION_CAPTIVE_PORTAL_DETECTED} or
-     * {@link #ACTION_CAPTIVE_PORTAL_SIGN_IN} receiver to indicate
-     * the receiver has signed into the
-     * captive portal.  After being verified to provide internet
-     * connectivity, this network will be made the default (assuming
-     * it is preferred over all other active networks).
-     */
-    public static final int CAPTIVE_PORTAL_SIGNED_IN = 1;
-
-    /**
-     * Specified as a result code of a {@link #ACTION_CAPTIVE_PORTAL_DETECTED} or
-     * {@link #ACTION_CAPTIVE_PORTAL_SIGN_IN} receiver to indicate
-     * the receiver is familiar with
-     * this captive portal and knows sign-in is impossible or the user
-     * has indicated they do not want to pursue sign-in.  No other apps will
-     * be given the option of signing in to the network.
-     */
-    public static final int CAPTIVE_PORTAL_DISCONNECT = 2;
-
-    /**
      * The absence of a connection type.
      * @hide
      */
@@ -777,6 +687,23 @@
     }
 
     /**
+     * Returns the {@link Network} object currently serving a given type, or
+     * null if the given type is not connected.
+     *
+     * <p>This method requires the caller to hold the permission
+     * {@link android.Manifest.permission#ACCESS_NETWORK_STATE}.
+     *
+     * @hide
+     */
+    public Network getNetworkForType(int networkType) {
+        try {
+            return mService.getNetworkForType(networkType);
+        } catch (RemoteException e) {
+            return null;
+        }
+    }
+
+    /**
      * Returns an array of all {@link Network} currently tracked by the
      * framework.
      *
@@ -1373,7 +1300,7 @@
     }
 
     /**
-     * Callback for use with {@link ConnectivityManager#registerDefaultNetworkActiveListener}
+     * Callback for use with {@link ConnectivityManager#addDefaultNetworkActiveListener}
      * to find out when the system default network has gone in to a high power state.
      */
     public interface OnNetworkActiveListener {
@@ -1415,7 +1342,7 @@
      *
      * @param l The listener to be told when the network is active.
      */
-    public void registerDefaultNetworkActiveListener(final OnNetworkActiveListener l) {
+    public void addDefaultNetworkActiveListener(final OnNetworkActiveListener l) {
         INetworkActivityListener rl = new INetworkActivityListener.Stub() {
             @Override
             public void onNetworkActive() throws RemoteException {
@@ -1432,11 +1359,11 @@
 
     /**
      * Remove network active listener previously registered with
-     * {@link #registerDefaultNetworkActiveListener}.
+     * {@link #addDefaultNetworkActiveListener}.
      *
      * @param l Previously registered listener.
      */
-    public void unregisterDefaultNetworkActiveListener(OnNetworkActiveListener l) {
+    public void removeDefaultNetworkActiveListener(OnNetworkActiveListener l) {
         INetworkActivityListener rl = mNetworkActivityListeners.get(l);
         if (rl == null) {
             throw new IllegalArgumentException("Listener not registered: " + l);
@@ -1475,6 +1402,20 @@
         return (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE);
     }
 
+    /** {@hide */
+    public static final void enforceTetherChangePermission(Context context) {
+        if (context.getResources().getStringArray(
+                com.android.internal.R.array.config_mobile_hotspot_provision_app).length == 2) {
+            // Have a provisioning app - must only let system apps (which check this app)
+            // turn on tethering
+            context.enforceCallingOrSelfPermission(
+                    android.Manifest.permission.CONNECTIVITY_INTERNAL, "ConnectivityService");
+        } else {
+            context.enforceCallingOrSelfPermission(
+                    android.Manifest.permission.CHANGE_NETWORK_STATE, "ConnectivityService");
+        }
+    }
+
     /**
      * Get the set of tetherable, available interfaces.  This list is limited by
      * device configuration and current interface existence.
@@ -2542,7 +2483,20 @@
      * @return {@code true} on success, {@code false} if the {@link Network} is no longer valid.
      */
     public static boolean setProcessDefaultNetwork(Network network) {
-        return NetworkUtils.bindProcessToNetwork(network == null ? NETID_UNSET : network.netId);
+        int netId = (network == null) ? NETID_UNSET : network.netId;
+        if (netId == NetworkUtils.getNetworkBoundToProcess()) {
+            return true;
+        }
+        if (NetworkUtils.bindProcessToNetwork(netId)) {
+            // Must flush DNS cache as new network may have different DNS resolutions.
+            InetAddress.clearDnsCache();
+            // Must flush socket pool as idle sockets will be bound to previous network and may
+            // cause subsequent fetches to be performed on old network.
+            NetworkEventDispatcher.getInstance().onNetworkConfigurationChanged();
+            return true;
+        } else {
+            return false;
+        }
     }
 
     /**
diff --git a/core/java/android/net/DhcpResults.java b/core/java/android/net/DhcpResults.java
index 49a307e..71df60a 100644
--- a/core/java/android/net/DhcpResults.java
+++ b/core/java/android/net/DhcpResults.java
@@ -16,13 +16,15 @@
 
 package android.net;
 
+import android.net.NetworkUtils;
 import android.os.Parcelable;
 import android.os.Parcel;
 import android.text.TextUtils;
 import android.util.Log;
 
 import java.net.InetAddress;
-import java.net.UnknownHostException;
+import java.net.Inet4Address;
+import java.util.Objects;
 
 /**
  * A simple object for retrieving the results of a DHCP request.
@@ -30,38 +32,34 @@
  * TODO - remove when DhcpInfo is deprecated.  Move the remaining api to LinkProperties.
  * @hide
  */
-public class DhcpResults implements Parcelable {
+public class DhcpResults extends StaticIpConfiguration {
     private static final String TAG = "DhcpResults";
 
-    public final LinkProperties linkProperties;
-
     public InetAddress serverAddress;
 
-    /**
-     * Vendor specific information (from RFC 2132).
-     */
+    /** Vendor specific information (from RFC 2132). */
     public String vendorInfo;
 
     public int leaseDuration;
 
     public DhcpResults() {
-        linkProperties = new LinkProperties();
+        super();
+    }
+
+    public DhcpResults(StaticIpConfiguration source) {
+        super(source);
     }
 
     /** copy constructor */
     public DhcpResults(DhcpResults source) {
-        if (source != null) {
-            linkProperties = new LinkProperties(source.linkProperties);
-            serverAddress = source.serverAddress;
-            leaseDuration = source.leaseDuration;
-            vendorInfo = source.vendorInfo;
-        } else {
-            linkProperties = new LinkProperties();
-        }
-    }
+        super(source);
 
-    public DhcpResults(LinkProperties lp) {
-        linkProperties = new LinkProperties(lp);
+        if (source != null) {
+            // All these are immutable, so no need to make copies.
+            serverAddress = source.serverAddress;
+            vendorInfo = source.vendorInfo;
+            leaseDuration = source.leaseDuration;
+        }
     }
 
     /**
@@ -70,14 +68,10 @@
      * being empty.
      */
     public void updateFromDhcpRequest(DhcpResults orig) {
-        if (orig == null || orig.linkProperties == null) return;
-        if (linkProperties.getRoutes().size() == 0) {
-            for (RouteInfo r : orig.linkProperties.getRoutes()) linkProperties.addRoute(r);
-        }
-        if (linkProperties.getDnsServers().size() == 0) {
-            for (InetAddress d : orig.linkProperties.getDnsServers()) {
-                linkProperties.addDnsServer(d);
-            }
+        if (orig == null) return;
+        if (gateway == null) gateway = orig.gateway;
+        if (dnsServers.size() == 0) {
+            dnsServers.addAll(orig.dnsServers);
         }
     }
 
@@ -94,15 +88,14 @@
     }
 
     public void clear() {
-        linkProperties.clear();
-        serverAddress = null;
+        super.clear();
         vendorInfo = null;
         leaseDuration = 0;
     }
 
     @Override
     public String toString() {
-        StringBuffer str = new StringBuffer(linkProperties.toString());
+        StringBuffer str = new StringBuffer(super.toString());
 
         str.append(" DHCP server ").append(serverAddress);
         str.append(" Vendor info ").append(vendorInfo);
@@ -119,58 +112,19 @@
 
         DhcpResults target = (DhcpResults)obj;
 
-        if (linkProperties == null) {
-            if (target.linkProperties != null) return false;
-        } else if (!linkProperties.equals(target.linkProperties)) return false;
-        if (serverAddress == null) {
-            if (target.serverAddress != null) return false;
-        } else if (!serverAddress.equals(target.serverAddress)) return false;
-        if (vendorInfo == null) {
-            if (target.vendorInfo != null) return false;
-        } else if (!vendorInfo.equals(target.vendorInfo)) return false;
-        if (leaseDuration != target.leaseDuration) return false;
-
-        return true;
-    }
-
-    /** Implement the Parcelable interface */
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Implement the Parcelable interface */
-    public void writeToParcel(Parcel dest, int flags) {
-        linkProperties.writeToParcel(dest, flags);
-
-        dest.writeInt(leaseDuration);
-
-        if (serverAddress != null) {
-            dest.writeByte((byte)1);
-            dest.writeByteArray(serverAddress.getAddress());
-        } else {
-            dest.writeByte((byte)0);
-        }
-
-        dest.writeString(vendorInfo);
+        return super.equals((StaticIpConfiguration) obj) &&
+                Objects.equals(serverAddress, target.serverAddress) &&
+                Objects.equals(vendorInfo, target.vendorInfo) &&
+                leaseDuration == target.leaseDuration;
     }
 
     /** Implement the Parcelable interface */
     public static final Creator<DhcpResults> CREATOR =
         new Creator<DhcpResults>() {
             public DhcpResults createFromParcel(Parcel in) {
-                DhcpResults prop = new DhcpResults((LinkProperties)in.readParcelable(null));
-
-                prop.leaseDuration = in.readInt();
-
-                if (in.readByte() == 1) {
-                    try {
-                        prop.serverAddress = InetAddress.getByAddress(in.createByteArray());
-                    } catch (UnknownHostException e) {}
-                }
-
-                prop.vendorInfo = in.readString();
-
-                return prop;
+                DhcpResults dhcpResults = new DhcpResults();
+                readFromParcel(dhcpResults, in);
+                return dhcpResults;
             }
 
             public DhcpResults[] newArray(int size) {
@@ -178,33 +132,39 @@
             }
         };
 
-    // Utils for jni population - false on success
-    public void setInterfaceName(String interfaceName) {
-        linkProperties.setInterfaceName(interfaceName);
+    /** Implement the Parcelable interface */
+    public void writeToParcel(Parcel dest, int flags) {
+        super.writeToParcel(dest, flags);
+        dest.writeInt(leaseDuration);
+        NetworkUtils.parcelInetAddress(dest, serverAddress, flags);
+        dest.writeString(vendorInfo);
     }
 
-    public boolean addLinkAddress(String addrString, int prefixLength) {
-        InetAddress addr;
+    private static void readFromParcel(DhcpResults dhcpResults, Parcel in) {
+        StaticIpConfiguration.readFromParcel(dhcpResults, in);
+        dhcpResults.leaseDuration = in.readInt();
+        dhcpResults.serverAddress = NetworkUtils.unparcelInetAddress(in);
+        dhcpResults.vendorInfo = in.readString();
+    }
+
+    // Utils for jni population - false on success
+    // Not part of the superclass because they're only used by the JNI iterface to the DHCP daemon.
+    public boolean setIpAddress(String addrString, int prefixLength) {
         try {
-            addr = NetworkUtils.numericToInetAddress(addrString);
-        } catch (IllegalArgumentException e) {
-            Log.e(TAG, "addLinkAddress failed with addrString " + addrString);
+            Inet4Address addr = (Inet4Address) NetworkUtils.numericToInetAddress(addrString);
+            ipAddress = new LinkAddress(addr, prefixLength);
+        } catch (IllegalArgumentException|ClassCastException e) {
+            Log.e(TAG, "setIpAddress failed with addrString " + addrString + "/" + prefixLength);
             return true;
         }
-
-        LinkAddress linkAddress = new LinkAddress(addr, prefixLength);
-        linkProperties.addLinkAddress(linkAddress);
-
-        RouteInfo routeInfo = new RouteInfo(linkAddress);
-        linkProperties.addRoute(routeInfo);
         return false;
     }
 
-    public boolean addGateway(String addrString) {
+    public boolean setGateway(String addrString) {
         try {
-            linkProperties.addRoute(new RouteInfo(NetworkUtils.numericToInetAddress(addrString)));
+            gateway = NetworkUtils.numericToInetAddress(addrString);
         } catch (IllegalArgumentException e) {
-            Log.e(TAG, "addGateway failed with addrString " + addrString);
+            Log.e(TAG, "setGateway failed with addrString " + addrString);
             return true;
         }
         return false;
@@ -213,7 +173,7 @@
     public boolean addDns(String addrString) {
         if (TextUtils.isEmpty(addrString) == false) {
             try {
-                linkProperties.addDnsServer(NetworkUtils.numericToInetAddress(addrString));
+                dnsServers.add(NetworkUtils.numericToInetAddress(addrString));
             } catch (IllegalArgumentException e) {
                 Log.e(TAG, "addDns failed with addrString " + addrString);
                 return true;
@@ -241,6 +201,6 @@
     }
 
     public void setDomains(String domains) {
-        linkProperties.setDomains(domains);
+        domains = domains;
     }
 }
diff --git a/core/java/android/net/EthernetManager.java b/core/java/android/net/EthernetManager.java
index 608ca28..d965f27 100644
--- a/core/java/android/net/EthernetManager.java
+++ b/core/java/android/net/EthernetManager.java
@@ -21,7 +21,6 @@
 import android.net.IpConfiguration;
 import android.net.IpConfiguration.IpAssignment;
 import android.net.IpConfiguration.ProxySettings;
-import android.net.LinkProperties;
 import android.os.RemoteException;
 
 /**
@@ -52,16 +51,12 @@
      */
     public IpConfiguration getConfiguration() {
         if (mService == null) {
-            return new IpConfiguration(IpAssignment.UNASSIGNED,
-                                       ProxySettings.UNASSIGNED,
-                                       new LinkProperties());
+            return new IpConfiguration();
         }
         try {
             return mService.getConfiguration();
         } catch (RemoteException e) {
-            return new IpConfiguration(IpAssignment.UNASSIGNED,
-                                       ProxySettings.UNASSIGNED,
-                                       new LinkProperties());
+            return new IpConfiguration();
         }
     }
 
diff --git a/core/java/android/net/IConnectivityManager.aidl b/core/java/android/net/IConnectivityManager.aidl
index 0814e0f..974c4cd 100644
--- a/core/java/android/net/IConnectivityManager.aidl
+++ b/core/java/android/net/IConnectivityManager.aidl
@@ -48,6 +48,7 @@
     NetworkInfo getNetworkInfo(int networkType);
     NetworkInfo getNetworkInfoForNetwork(in Network network);
     NetworkInfo[] getAllNetworkInfo();
+    Network getNetworkForType(int networkType);
     Network[] getAllNetworks();
 
     NetworkInfo getProvisioningOrActiveNetworkInfo();
@@ -108,6 +109,8 @@
 
     boolean prepareVpn(String oldPackage, String newPackage);
 
+    void setVpnPackageAuthorization(boolean authorized);
+
     ParcelFileDescriptor establishVpn(in VpnConfig config);
 
     VpnConfig getVpnConfig();
diff --git a/core/java/android/net/IpConfiguration.java b/core/java/android/net/IpConfiguration.java
index 4730bab..fe69f296 100644
--- a/core/java/android/net/IpConfiguration.java
+++ b/core/java/android/net/IpConfiguration.java
@@ -16,7 +16,7 @@
 
 package android.net;
 
-import android.net.LinkProperties;
+import android.net.StaticIpConfiguration;
 import android.os.Parcel;
 import android.os.Parcelable;
 
@@ -31,7 +31,7 @@
 
     public enum IpAssignment {
         /* Use statically configured IP settings. Configuration can be accessed
-         * with linkProperties */
+         * with staticIpConfiguration */
         STATIC,
         /* Use dynamically configured IP settigns */
         DHCP,
@@ -42,12 +42,14 @@
 
     public IpAssignment ipAssignment;
 
+    public StaticIpConfiguration staticIpConfiguration;
+
     public enum ProxySettings {
         /* No proxy is to be used. Any existing proxy settings
          * should be cleared. */
         NONE,
         /* Use statically configured proxy. Configuration can be accessed
-         * with linkProperties */
+         * with httpProxy. */
         STATIC,
         /* no proxy details are assigned, this is used to indicate
          * that any existing proxy settings should be retained */
@@ -59,30 +61,69 @@
 
     public ProxySettings proxySettings;
 
-    public LinkProperties linkProperties;
+    public ProxyInfo httpProxy;
 
-    public IpConfiguration(IpConfiguration source) {
-        if (source != null) {
-            ipAssignment = source.ipAssignment;
-            proxySettings = source.proxySettings;
-            linkProperties = new LinkProperties(source.linkProperties);
-        } else {
-            ipAssignment = IpAssignment.UNASSIGNED;
-            proxySettings = ProxySettings.UNASSIGNED;
-            linkProperties = new LinkProperties();
-        }
+    private void init(IpAssignment ipAssignment,
+                      ProxySettings proxySettings,
+                      StaticIpConfiguration staticIpConfiguration,
+                      ProxyInfo httpProxy) {
+        this.ipAssignment = ipAssignment;
+        this.proxySettings = proxySettings;
+        this.staticIpConfiguration = (staticIpConfiguration == null) ?
+                null : new StaticIpConfiguration(staticIpConfiguration);
+        this.httpProxy = (httpProxy == null) ?
+                null : new ProxyInfo(httpProxy);
     }
 
     public IpConfiguration() {
-         this(null);
+        init(IpAssignment.UNASSIGNED, ProxySettings.UNASSIGNED, null, null);
     }
 
     public IpConfiguration(IpAssignment ipAssignment,
                            ProxySettings proxySettings,
-                           LinkProperties linkProperties) {
+                           StaticIpConfiguration staticIpConfiguration,
+                           ProxyInfo httpProxy) {
+        init(ipAssignment, proxySettings, staticIpConfiguration, httpProxy);
+    }
+
+    public IpConfiguration(IpConfiguration source) {
+        this();
+        if (source != null) {
+            init(source.ipAssignment, source.proxySettings,
+                 source.staticIpConfiguration, source.httpProxy);
+        }
+    }
+
+    public IpAssignment getIpAssignment() {
+        return ipAssignment;
+    }
+
+    public void setIpAssignment(IpAssignment ipAssignment) {
         this.ipAssignment = ipAssignment;
+    }
+
+    public StaticIpConfiguration getStaticIpConfiguration() {
+        return staticIpConfiguration;
+    }
+
+    public void setStaticIpConfiguration(StaticIpConfiguration staticIpConfiguration) {
+        this.staticIpConfiguration = staticIpConfiguration;
+    }
+
+    public ProxySettings getProxySettings() {
+        return proxySettings;
+    }
+
+    public void setProxySettings(ProxySettings proxySettings) {
         this.proxySettings = proxySettings;
-        this.linkProperties = new LinkProperties(linkProperties);
+    }
+
+    public ProxyInfo getHttpProxy() {
+        return httpProxy;
+    }
+
+    public void setHttpProxy(ProxyInfo httpProxy) {
+        this.httpProxy = httpProxy;
     }
 
     @Override
@@ -90,10 +131,16 @@
         StringBuilder sbuf = new StringBuilder();
         sbuf.append("IP assignment: " + ipAssignment.toString());
         sbuf.append("\n");
+        if (staticIpConfiguration != null) {
+            sbuf.append("Static configuration: " + staticIpConfiguration.toString());
+            sbuf.append("\n");
+        }
         sbuf.append("Proxy settings: " + proxySettings.toString());
         sbuf.append("\n");
-        sbuf.append(linkProperties.toString());
-        sbuf.append("\n");
+        if (httpProxy != null) {
+            sbuf.append("HTTP proxy: " + httpProxy.toString());
+            sbuf.append("\n");
+        }
 
         return sbuf.toString();
     }
@@ -111,14 +158,16 @@
         IpConfiguration other = (IpConfiguration) o;
         return this.ipAssignment == other.ipAssignment &&
                 this.proxySettings == other.proxySettings &&
-                Objects.equals(this.linkProperties, other.linkProperties);
+                Objects.equals(this.staticIpConfiguration, other.staticIpConfiguration) &&
+                Objects.equals(this.httpProxy, other.httpProxy);
     }
 
     @Override
     public int hashCode() {
-        return 13 + (linkProperties != null ? linkProperties.hashCode() : 0) +
+        return 13 + (staticIpConfiguration != null ? staticIpConfiguration.hashCode() : 0) +
                17 * ipAssignment.ordinal() +
-               47 * proxySettings.ordinal();
+               47 * proxySettings.ordinal() +
+               83 * httpProxy.hashCode();
     }
 
     /** Implement the Parcelable interface */
@@ -130,7 +179,8 @@
     public void writeToParcel(Parcel dest, int flags) {
         dest.writeString(ipAssignment.name());
         dest.writeString(proxySettings.name());
-        dest.writeParcelable(linkProperties, flags);
+        dest.writeParcelable(staticIpConfiguration, flags);
+        dest.writeParcelable(httpProxy, flags);
     }
 
     /** Implement the Parcelable interface */
@@ -140,7 +190,8 @@
                 IpConfiguration config = new IpConfiguration();
                 config.ipAssignment = IpAssignment.valueOf(in.readString());
                 config.proxySettings = ProxySettings.valueOf(in.readString());
-                config.linkProperties = in.readParcelable(null);
+                config.staticIpConfiguration = in.readParcelable(null);
+                config.httpProxy = in.readParcelable(null);
                 return config;
             }
 
diff --git a/core/java/android/net/LinkAddress.java b/core/java/android/net/LinkAddress.java
index f9a25f9..c387055 100644
--- a/core/java/android/net/LinkAddress.java
+++ b/core/java/android/net/LinkAddress.java
@@ -274,7 +274,6 @@
 
     /**
      * Implement the Parcelable interface.
-     * @hide
      */
     public int describeContents() {
         return 0;
@@ -282,7 +281,6 @@
 
     /**
      * Implement the Parcelable interface.
-     * @hide
      */
     public void writeToParcel(Parcel dest, int flags) {
         dest.writeByteArray(address.getAddress());
@@ -293,7 +291,6 @@
 
     /**
      * Implement the Parcelable interface.
-     * @hide
      */
     public static final Creator<LinkAddress> CREATOR =
         new Creator<LinkAddress>() {
diff --git a/core/java/android/net/Network.java b/core/java/android/net/Network.java
index 0de3f26..58f0fc0 100644
--- a/core/java/android/net/Network.java
+++ b/core/java/android/net/Network.java
@@ -16,10 +16,10 @@
 
 package android.net;
 
-import android.net.NetworkBoundURLFactory;
 import android.net.NetworkUtils;
 import android.os.Parcelable;
 import android.os.Parcel;
+import android.system.ErrnoException;
 
 import java.io.IOException;
 import java.net.InetAddress;
@@ -30,11 +30,15 @@
 import java.net.SocketException;
 import java.net.UnknownHostException;
 import java.net.URL;
+import java.net.URLConnection;
 import java.net.URLStreamHandler;
 import java.util.concurrent.atomic.AtomicReference;
 import javax.net.SocketFactory;
 
+import com.android.okhttp.ConnectionPool;
 import com.android.okhttp.HostResolver;
+import com.android.okhttp.HttpHandler;
+import com.android.okhttp.HttpsHandler;
 import com.android.okhttp.OkHttpClient;
 
 /**
@@ -54,11 +58,25 @@
     public final int netId;
 
     // Objects used to perform per-network operations such as getSocketFactory
-    // and getBoundURL, and a lock to protect access to them.
+    // and openConnection, and a lock to protect access to them.
     private volatile NetworkBoundSocketFactory mNetworkBoundSocketFactory = null;
-    private volatile OkHttpClient mOkHttpClient = null;
+    // mLock should be used to control write access to mConnectionPool and mHostResolver.
+    // maybeInitHttpClient() must be called prior to reading either variable.
+    private volatile ConnectionPool mConnectionPool = null;
+    private volatile HostResolver mHostResolver = null;
     private Object mLock = new Object();
 
+    // Default connection pool values. These are evaluated at startup, just
+    // like the OkHttp code. Also like the OkHttp code, we will throw parse
+    // exceptions at class loading time if the properties are set but are not
+    // valid integers.
+    private static final boolean httpKeepAlive =
+            Boolean.parseBoolean(System.getProperty("http.keepAlive", "true"));
+    private static final int httpMaxConnections =
+            httpKeepAlive ? Integer.parseInt(System.getProperty("http.maxConnections", "5")) : 0;
+    private static final long httpKeepAliveDurationMs =
+            Long.parseLong(System.getProperty("http.keepAliveDuration", "300000"));  // 5 minutes.
+
     /**
      * @hide
      */
@@ -157,12 +175,7 @@
         @Override
         public Socket createSocket() throws IOException {
             Socket socket = new Socket();
-            // Query a property of the underlying socket to ensure the underlying
-            // socket exists so a file descriptor is available to bind to a network.
-            socket.getReuseAddress();
-            if (!NetworkUtils.bindSocketToNetwork(socket.getFileDescriptor$().getInt$(), mNetId)) {
-                throw new SocketException("Failed to bind socket to network.");
-            }
+            bindSocket(socket);
             return socket;
         }
     }
@@ -187,73 +200,87 @@
         return mNetworkBoundSocketFactory;
     }
 
-    /** The default NetworkBoundURLFactory, used if setNetworkBoundURLFactory is never called. */
-    private static final NetworkBoundURLFactory DEFAULT_URL_FACTORY = new NetworkBoundURLFactory() {
-        public URL getBoundURL(final Network network, URL url) throws MalformedURLException {
-            if (network.mOkHttpClient == null) {
-                synchronized (network.mLock) {
-                    if (network.mOkHttpClient == null) {
-                        HostResolver hostResolver = new HostResolver() {
-                            @Override
-                            public InetAddress[] getAllByName(String host)
-                                    throws UnknownHostException {
-                                return network.getAllByName(host);
-                            }
-                        };
-                        network.mOkHttpClient = new OkHttpClient()
-                                .setSocketFactory(network.getSocketFactory())
-                                .setHostResolver(hostResolver);
+    // TODO: This creates a connection pool and host resolver for
+    // every Network object, instead of one for every NetId. This is
+    // suboptimal, because an app could potentially have more than one
+    // Network object for the same NetId, causing increased memory footprint
+    // and performance penalties due to lack of connection reuse (connection
+    // setup time, congestion window growth time, etc.).
+    //
+    // Instead, investigate only having one connection pool and host resolver
+    // for every NetId, perhaps by using a static HashMap of NetIds to
+    // connection pools and host resolvers. The tricky part is deciding when
+    // to remove a map entry; a WeakHashMap shouldn't be used because whether
+    // a Network is referenced doesn't correlate with whether a new Network
+    // will be instantiated in the near future with the same NetID. A good
+    // solution would involve purging empty (or when all connections are timed
+    // out) ConnectionPools.
+    private void maybeInitHttpClient() {
+        synchronized (mLock) {
+            if (mHostResolver == null) {
+                mHostResolver = new HostResolver() {
+                    @Override
+                    public InetAddress[] getAllByName(String host) throws UnknownHostException {
+                        return Network.this.getAllByName(host);
                     }
-                }
+                };
             }
-
-            String protocol = url.getProtocol();
-            URLStreamHandler handler = network.mOkHttpClient.createURLStreamHandler(protocol);
-            if (handler == null) {
-                // OkHttpClient only supports HTTP and HTTPS and returns a null URLStreamHandler if
-                // passed another protocol.
-                throw new MalformedURLException("Invalid URL or unrecognized protocol " + protocol);
+            if (mConnectionPool == null) {
+                mConnectionPool = new ConnectionPool(httpMaxConnections,
+                        httpKeepAliveDurationMs);
             }
-            return new URL(url, "", handler);
         }
-    };
-
-    private static AtomicReference<NetworkBoundURLFactory> sNetworkBoundURLFactory =
-            new AtomicReference <NetworkBoundURLFactory>(DEFAULT_URL_FACTORY);
-
-    /**
-     * Returns a {@link URL} based on the given URL but bound to this {@code Network},
-     * such that opening the URL will send all network traffic on this Network.
-     *
-     * Note that if this {@code Network} ever disconnects, any URL object generated by this method
-     * in the past or future will cease to work.
-     *
-     * The returned URL may have a {@link URLStreamHandler} explicitly set, which may not be the
-     * handler generated by the factory set with {@link java.net.URL#setURLStreamHandlerFactory}. To
-     * affect the {@code URLStreamHandler}s of URLs returned by this method, call
-     * {@link #setNetworkBoundURLFactory}.
-     *
-     * Because the returned URLs may have an explicit {@code URLStreamHandler} set, using them as a
-     * context when constructing other URLs and explicitly specifying a {@code URLStreamHandler} may
-     * result in URLs that are no longer bound to the same {@code Network}.
-     *
-     * The default implementation only supports {@code HTTP} and {@code HTTPS} URLs.
-     *
-     * @return a {@link URL} bound to this {@code Network}.
-     */
-    public URL getBoundURL(URL url) throws MalformedURLException {
-        return sNetworkBoundURLFactory.get().getBoundURL(this, url);
     }
 
     /**
-     * Sets the {@link NetworkBoundURLFactory} to be used by future {@link #getBoundURL} calls.
-     * If {@code null}, clears any factory that was previously specified.
+     * Opens the specified {@link URL} on this {@code Network}, such that all traffic will be sent
+     * on this Network. The URL protocol must be {@code HTTP} or {@code HTTPS}.
+     *
+     * @return a {@code URLConnection} to the resource referred to by this URL.
+     * @throws MalformedURLException if the URL protocol is not HTTP or HTTPS.
+     * @throws IOException if an error occurs while opening the connection.
+     * @see java.net.URL#openConnection()
      */
-    public static void setNetworkBoundURLFactory(NetworkBoundURLFactory factory) {
-        if (factory == null) {
-            factory = DEFAULT_URL_FACTORY;
+    public URLConnection openConnection(URL url) throws IOException {
+        maybeInitHttpClient();
+        String protocol = url.getProtocol();
+        OkHttpClient client;
+        // TODO: HttpHandler creates OkHttpClients that share the default ResponseCache.
+        // Could this cause unexpected behavior?
+        // TODO: Should the network's proxy be specified?
+        if (protocol.equals("http")) {
+            client = HttpHandler.createHttpOkHttpClient(null /* proxy */);
+        } else if (protocol.equals("https")) {
+            client = HttpsHandler.createHttpsOkHttpClient(null /* proxy */);
+        } else {
+            // OkHttpClient only supports HTTP and HTTPS and returns a null URLStreamHandler if
+            // passed another protocol.
+            throw new MalformedURLException("Invalid URL or unrecognized protocol " + protocol);
         }
-        sNetworkBoundURLFactory.set(factory);
+        return client.setSocketFactory(getSocketFactory())
+                .setHostResolver(mHostResolver)
+                .setConnectionPool(mConnectionPool)
+                .open(url);
+    }
+
+    /**
+     * Binds the specified {@link Socket} to this {@code Network}. All data traffic on the socket
+     * will be sent on this {@code Network}, irrespective of any process-wide network binding set by
+     * {@link ConnectivityManager#setProcessDefaultNetwork}. The socket must not be connected.
+     */
+    public void bindSocket(Socket socket) throws IOException {
+        if (socket.isConnected()) {
+            throw new SocketException("Socket is connected");
+        }
+        // Query a property of the underlying socket to ensure the underlying
+        // socket exists so a file descriptor is available to bind to a network.
+        socket.getReuseAddress();
+        int err = NetworkUtils.bindSocketToNetwork(socket.getFileDescriptor$().getInt$(), netId);
+        if (err != 0) {
+            // bindSocketToNetwork returns negative errno.
+            throw new ErrnoException("Binding socket to network " + netId, -err)
+                    .rethrowAsSocketException();
+        }
     }
 
     // implement the Parcelable interface
diff --git a/core/java/android/net/NetworkAgent.java b/core/java/android/net/NetworkAgent.java
index 22da90e..b83198d 100644
--- a/core/java/android/net/NetworkAgent.java
+++ b/core/java/android/net/NetworkAgent.java
@@ -45,7 +45,7 @@
     private volatile AsyncChannel mAsyncChannel;
     private final String LOG_TAG;
     private static final boolean DBG = true;
-    private static final boolean VDBG = true;
+    private static final boolean VDBG = false;
     private final Context mContext;
     private final ArrayList<Message>mPreConnectedQueue = new ArrayList<Message>();
 
@@ -120,6 +120,25 @@
      */
     public static final int EVENT_UNBLOCK_ADDRESS_FAMILY = BASE + 8;
 
+    /**
+     * Sent by ConnectivitySerice to the NetworkAgent to inform the agent of the
+     * networks status - whether we could use the network or could not, due to
+     * either a bad network configuration (no internet link) or captive portal.
+     *
+     * arg1 = either {@code VALID_NETWORK} or {@code INVALID_NETWORK}
+     */
+    public static final int CMD_REPORT_NETWORK_STATUS = BASE + 9;
+
+    public static final int VALID_NETWORK = 1;
+    public static final int INVALID_NETWORK = 2;
+
+     /**
+     * Sent by the NetworkAgent to ConnectivityService to indicate this network was
+     * explicitly selected.  This should be sent before the NetworkInfo is marked
+     * CONNECTED so it can be given special treatment at that time.
+     */
+    public static final int EVENT_SET_EXPLICITLY_SELECTED = BASE + 10;
+
     public NetworkAgent(Looper looper, Context context, String logTag, NetworkInfo ni,
             NetworkCapabilities nc, LinkProperties lp, int score) {
         this(looper, context, logTag, ni, nc, lp, score, null);
@@ -134,7 +153,7 @@
             throw new IllegalArgumentException();
         }
 
-        if (DBG) log("Registering NetworkAgent");
+        if (VDBG) log("Registering NetworkAgent");
         ConnectivityManager cm = (ConnectivityManager)mContext.getSystemService(
                 Context.CONNECTIVITY_SERVICE);
         cm.registerNetworkAgent(new Messenger(this), new NetworkInfo(ni),
@@ -148,7 +167,7 @@
                 if (mAsyncChannel != null) {
                     log("Received new connection while already connected!");
                 } else {
-                    if (DBG) log("NetworkAgent fully connected");
+                    if (VDBG) log("NetworkAgent fully connected");
                     AsyncChannel ac = new AsyncChannel();
                     ac.connected(null, this, msg.replyTo);
                     ac.replyToMessage(msg, AsyncChannel.CMD_CHANNEL_FULLY_CONNECTED,
@@ -164,7 +183,7 @@
                 break;
             }
             case AsyncChannel.CMD_CHANNEL_DISCONNECT: {
-                if (DBG) log("CMD_CHANNEL_DISCONNECT");
+                if (VDBG) log("CMD_CHANNEL_DISCONNECT");
                 if (mAsyncChannel != null) mAsyncChannel.disconnect();
                 break;
             }
@@ -181,6 +200,14 @@
                 log("Unhandled Message " + msg);
                 break;
             }
+            case CMD_REPORT_NETWORK_STATUS: {
+                if (VDBG) {
+                    log("CMD_REPORT_NETWORK_STATUS(" +
+                            (msg.arg1 == VALID_NETWORK ? "VALID)" : "INVALID)"));
+                }
+                networkStatus(msg.arg1);
+                break;
+            }
         }
     }
 
@@ -223,6 +250,9 @@
      * Called by the bearer code when it has a new score for this network.
      */
     public void sendNetworkScore(int score) {
+        if (score < 0) {
+            throw new IllegalArgumentException("Score must be >= 0");
+        }
         queueOrSendMessage(EVENT_NETWORK_SCORE_CHANGED, new Integer(score));
     }
 
@@ -258,6 +288,15 @@
     }
 
     /**
+     * Called by the bearer to indicate this network was manually selected by the user.
+     * This should be called before the NetworkInfo is marked CONNECTED so that this
+     * Network can be given special treatment at that time.
+     */
+    public void explicitlySelected() {
+        queueOrSendMessage(EVENT_SET_EXPLICITLY_SELECTED, 0);
+    }
+
+    /**
      * Called when ConnectivityService has indicated they no longer want this network.
      * The parent factory should (previously) have received indication of the change
      * as well, either canceling NetworkRequests or altering their score such that this
@@ -265,6 +304,24 @@
      */
     abstract protected void unwanted();
 
+    /**
+     * Called when the system determines the usefulness of this network.
+     *
+     * Networks claiming internet connectivity will have their internet
+     * connectivity verified.
+     *
+     * Currently there are two possible values:
+     * {@code VALID_NETWORK} if the system is happy with the connection,
+     * {@code INVALID_NETWORK} if the system is not happy.
+     * TODO - add indications of captive portal-ness and related success/failure,
+     * ie, CAPTIVE_SUCCESS_NETWORK, CAPTIVE_NETWORK for successful login and detection
+     *
+     * This may be called multiple times as the network status changes and may
+     * generate false negatives if we lose ip connectivity before the link is torn down.
+     */
+    protected void networkStatus(int status) {
+    }
+
     protected void log(String s) {
         Log.d(LOG_TAG, "NetworkAgent: " + s);
     }
diff --git a/core/java/android/net/NetworkBoundURLFactory.java b/core/java/android/net/NetworkBoundURLFactory.java
deleted file mode 100644
index 356100e..0000000
--- a/core/java/android/net/NetworkBoundURLFactory.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-
-/**
- * An interface that describes a factory for network-specific {@link URL} objects.
- */
-public interface NetworkBoundURLFactory {
-    /**
-     * Returns a {@link URL} based on the given URL but bound to the specified {@code Network},
-     * such that opening the URL will send all network traffic on the specified Network.
-     *
-     * @return a {@link URL} bound to this {@code Network}.
-     * @throws MalformedURLException if the URL was not valid, or this factory cannot handle the
-     *         specified URL (e.g., if it does not support the protocol of the URL).
-     */
-    public URL getBoundURL(Network network, URL url) throws MalformedURLException;
-}
diff --git a/core/java/android/net/NetworkFactory.java b/core/java/android/net/NetworkFactory.java
index a20e8e7..6ddd8b3 100644
--- a/core/java/android/net/NetworkFactory.java
+++ b/core/java/android/net/NetworkFactory.java
@@ -46,6 +46,7 @@
  **/
 public class NetworkFactory extends Handler {
     private static final boolean DBG = true;
+    private static final boolean VDBG = false;
 
     private static final int BASE = Protocol.BASE_NETWORK_FACTORY;
     /**
@@ -164,13 +165,14 @@
     private void handleAddRequest(NetworkRequest request, int score) {
         NetworkRequestInfo n = mNetworkRequests.get(request.requestId);
         if (n == null) {
+            if (DBG) log("got request " + request + " with score " + score);
             n = new NetworkRequestInfo(request, score);
             mNetworkRequests.put(n.request.requestId, n);
         } else {
+            if (VDBG) log("new score " + score + " for exisiting request " + request);
             n.score = score;
         }
-        if (DBG) log("got request " + request + " with score " + score);
-        if (DBG) log("  my score=" + mScore + ", my filter=" + mCapabilityFilter);
+        if (VDBG) log("  my score=" + mScore + ", my filter=" + mCapabilityFilter);
 
         evalRequest(n);
     }
diff --git a/core/java/android/net/NetworkInfo.java b/core/java/android/net/NetworkInfo.java
index d279412..393637e 100644
--- a/core/java/android/net/NetworkInfo.java
+++ b/core/java/android/net/NetworkInfo.java
@@ -128,14 +128,6 @@
     private boolean mIsAvailable;
 
     /**
-     * @param type network type
-     * @deprecated
-     * @hide because this constructor was only meant for internal use (and
-     * has now been superseded by the package-private constructor below).
-     */
-    public NetworkInfo(int type) {}
-
-    /**
      * @hide
      */
     public NetworkInfo(int type, int subtype, String typeName, String subtypeName) {
@@ -419,8 +411,7 @@
 
     /**
      * Report the extra information about the network state, if any was
-     * provided by the lower networking layers.,
-     * if one is available.
+     * provided by the lower networking layers.
      * @return the extra information, or null if not available
      */
     public String getExtraInfo() {
diff --git a/core/java/android/net/NetworkMisc.java b/core/java/android/net/NetworkMisc.java
index 34f6cf4..5d2a43d 100644
--- a/core/java/android/net/NetworkMisc.java
+++ b/core/java/android/net/NetworkMisc.java
@@ -25,12 +25,32 @@
  * @hide
  */
 public class NetworkMisc implements Parcelable {
+
     /**
      * If the {@link Network} is a VPN, whether apps are allowed to bypass the VPN. This is set by
      * a {@link VpnService} and used by {@link ConnectivityService} when creating a VPN.
      */
     public boolean allowBypass;
 
+    /**
+     * Set if the network was manually/explicitly connected to by the user either from settings
+     * or a 3rd party app.  For example, turning on cell data is not explicit but tapping on a wifi
+     * ap in the wifi settings to trigger a connection is explicit.  A 3rd party app asking to
+     * connect to a particular access point is also explicit, though this may change in the future
+     * as we want apps to use the multinetwork apis.
+     */
+    public boolean explicitlySelected;
+
+    public NetworkMisc() {
+    }
+
+    public NetworkMisc(NetworkMisc nm) {
+        if (nm != null) {
+            allowBypass = nm.allowBypass;
+            explicitlySelected = nm.explicitlySelected;
+        }
+    }
+
     @Override
     public int describeContents() {
         return 0;
@@ -39,6 +59,7 @@
     @Override
     public void writeToParcel(Parcel out, int flags) {
         out.writeInt(allowBypass ? 1 : 0);
+        out.writeInt(explicitlySelected ? 1 : 0);
     }
 
     public static final Creator<NetworkMisc> CREATOR = new Creator<NetworkMisc>() {
@@ -46,6 +67,7 @@
         public NetworkMisc createFromParcel(Parcel in) {
             NetworkMisc networkMisc = new NetworkMisc();
             networkMisc.allowBypass = in.readInt() != 0;
+            networkMisc.explicitlySelected = in.readInt() != 0;
             return networkMisc;
         }
 
diff --git a/core/java/android/net/NetworkRequest.java b/core/java/android/net/NetworkRequest.java
index 83bdfaa..5a09b46 100644
--- a/core/java/android/net/NetworkRequest.java
+++ b/core/java/android/net/NetworkRequest.java
@@ -52,6 +52,9 @@
      * @hide
      */
     public NetworkRequest(NetworkCapabilities nc, int legacyType, int rId) {
+        if (nc == null) {
+            throw new NullPointerException();
+        }
         requestId = rId;
         networkCapabilities = nc;
         this.legacyType = legacyType;
diff --git a/core/java/android/net/NetworkStats.java b/core/java/android/net/NetworkStats.java
index 54d43d3..ea5dfd1 100644
--- a/core/java/android/net/NetworkStats.java
+++ b/core/java/android/net/NetworkStats.java
@@ -24,6 +24,8 @@
 import com.android.internal.annotations.VisibleForTesting;
 import com.android.internal.util.ArrayUtils;
 
+import libcore.util.EmptyArray;
+
 import java.io.CharArrayWriter;
 import java.io.PrintWriter;
 import java.util.Arrays;
@@ -169,6 +171,15 @@
         } else {
             // Special case for use by NetworkStatsFactory to start out *really* empty.
             this.capacity = 0;
+            this.iface = EmptyArray.STRING;
+            this.uid = EmptyArray.INT;
+            this.set = EmptyArray.INT;
+            this.tag = EmptyArray.INT;
+            this.rxBytes = EmptyArray.LONG;
+            this.rxPackets = EmptyArray.LONG;
+            this.txBytes = EmptyArray.LONG;
+            this.txPackets = EmptyArray.LONG;
+            this.operations = EmptyArray.LONG;
         }
     }
 
diff --git a/core/java/android/net/NetworkUtils.java b/core/java/android/net/NetworkUtils.java
index 663aa15..d2a2997 100644
--- a/core/java/android/net/NetworkUtils.java
+++ b/core/java/android/net/NetworkUtils.java
@@ -23,6 +23,7 @@
 import java.util.Collection;
 import java.util.Locale;
 
+import android.os.Parcel;
 import android.util.Log;
 import android.util.Pair;
 
@@ -127,8 +128,9 @@
     /**
      * Explicitly binds {@code socketfd} to the network designated by {@code netId}.  This
      * overrides any binding via {@link #bindProcessToNetwork}.
+     * @return 0 on success or negative errno on failure.
      */
-    public native static boolean bindSocketToNetwork(int socketfd, int netId);
+    public native static int bindSocketToNetwork(int socketfd, int netId);
 
     /**
      * Protect {@code socketfd} from VPN connections.  After protecting, data sent through
@@ -203,6 +205,32 @@
     }
 
     /**
+     * Writes an InetAddress to a parcel. The address may be null. This is likely faster than
+     * calling writeSerializable.
+     */
+    protected static void parcelInetAddress(Parcel parcel, InetAddress address, int flags) {
+        byte[] addressArray = (address != null) ? address.getAddress() : null;
+        parcel.writeByteArray(addressArray);
+    }
+
+    /**
+     * Reads an InetAddress from a parcel. Returns null if the address that was written was null
+     * or if the data is invalid.
+     */
+    protected static InetAddress unparcelInetAddress(Parcel in) {
+        byte[] addressArray = in.createByteArray();
+        if (addressArray == null) {
+            return null;
+        }
+        try {
+            return InetAddress.getByAddress(addressArray);
+        } catch (UnknownHostException e) {
+            return null;
+        }
+    }
+
+
+    /**
      *  Masks a raw IP address byte array with the specified prefix length.
      */
     public static void maskRawAddress(byte[] array, int prefixLength) {
diff --git a/core/java/android/net/PacProxySelector.java b/core/java/android/net/PacProxySelector.java
index 8a2c2b6..8626d08 100644
--- a/core/java/android/net/PacProxySelector.java
+++ b/core/java/android/net/PacProxySelector.java
@@ -39,6 +39,9 @@
 public class PacProxySelector extends ProxySelector {
     private static final String TAG = "PacProxySelector";
     public static final String PROXY_SERVICE = "com.android.net.IProxyService";
+    private static final String SOCKS = "SOCKS ";
+    private static final String PROXY = "PROXY ";
+
     private IProxyService mProxyService;
     private final List<Proxy> mDefaultList;
 
@@ -88,16 +91,16 @@
             String trimmed = s.trim();
             if (trimmed.equals("DIRECT")) {
                 ret.add(java.net.Proxy.NO_PROXY);
-            } else if (trimmed.startsWith("PROXY ")) {
-                String[] hostPort = trimmed.substring(6).split(":");
-                String host = hostPort[0];
-                int port;
-                try {
-                    port = Integer.parseInt(hostPort[1]);
-                } catch (Exception e) {
-                    port = 8080;
+            } else if (trimmed.startsWith(PROXY)) {
+                Proxy proxy = proxyFromHostPort(Type.HTTP, trimmed.substring(PROXY.length()));
+                if (proxy != null) {
+                    ret.add(proxy);
                 }
-                ret.add(new Proxy(Type.HTTP, InetSocketAddress.createUnresolved(host, port)));
+            } else if (trimmed.startsWith(SOCKS)) {
+                Proxy proxy = proxyFromHostPort(Type.SOCKS, trimmed.substring(SOCKS.length()));
+                if (proxy != null) {
+                    ret.add(proxy);
+                }
             }
         }
         if (ret.size() == 0) {
@@ -106,6 +109,18 @@
         return ret;
     }
 
+    private static Proxy proxyFromHostPort(Proxy.Type type, String hostPortString) {
+        try {
+            String[] hostPort = hostPortString.split(":");
+            String host = hostPort[0];
+            int port = Integer.parseInt(hostPort[1]);
+            return new Proxy(type, InetSocketAddress.createUnresolved(host, port));
+        } catch (NumberFormatException|ArrayIndexOutOfBoundsException e) {
+            Log.d(TAG, "Unable to parse proxy " + hostPortString + " " + e);
+            return null;
+        }
+    }
+
     @Override
     public void connectFailed(URI uri, SocketAddress address, IOException failure) {
 
diff --git a/core/java/android/net/ProxyInfo.java b/core/java/android/net/ProxyInfo.java
index 7ea6bae..1534e2c 100644
--- a/core/java/android/net/ProxyInfo.java
+++ b/core/java/android/net/ProxyInfo.java
@@ -334,10 +334,6 @@
         dest.writeStringArray(mParsedExclusionList);
     }
 
-    /**
-     * Implement the Parcelable interface.
-     * @hide
-     */
     public static final Creator<ProxyInfo> CREATOR =
         new Creator<ProxyInfo>() {
             public ProxyInfo createFromParcel(Parcel in) {
diff --git a/core/java/android/net/StaticIpConfiguration.java b/core/java/android/net/StaticIpConfiguration.java
new file mode 100644
index 0000000..5a273cf
--- /dev/null
+++ b/core/java/android/net/StaticIpConfiguration.java
@@ -0,0 +1,194 @@
+/*
+ * Copyright (C) 2014 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 android.net;
+
+import android.net.LinkAddress;
+import android.os.Parcelable;
+import android.os.Parcel;
+
+import java.net.InetAddress;
+import java.net.UnknownHostException;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Objects;
+
+/**
+ * Class that describes static IP configuration.
+ *
+ * This class is different from LinkProperties because it represents
+ * configuration intent. The general contract is that if we can represent
+ * a configuration here, then we should be able to configure it on a network.
+ * The intent is that it closely match the UI we have for configuring networks.
+ *
+ * In contrast, LinkProperties represents current state. It is much more
+ * expressive. For example, it supports multiple IP addresses, multiple routes,
+ * stacked interfaces, and so on. Because LinkProperties is so expressive,
+ * using it to represent configuration intent as well as current state causes
+ * problems. For example, we could unknowingly save a configuration that we are
+ * not in fact capable of applying, or we could save a configuration that the
+ * UI cannot display, which has the potential for malicious code to hide
+ * hostile or unexpected configuration from the user: see, for example,
+ * http://b/12663469 and http://b/16893413 .
+ *
+ * @hide
+ */
+public class StaticIpConfiguration implements Parcelable {
+    public LinkAddress ipAddress;
+    public InetAddress gateway;
+    public final ArrayList<InetAddress> dnsServers;
+    public String domains;
+
+    public StaticIpConfiguration() {
+        dnsServers = new ArrayList<InetAddress>();
+    }
+
+    public StaticIpConfiguration(StaticIpConfiguration source) {
+        this();
+        if (source != null) {
+            // All of these except dnsServers are immutable, so no need to make copies.
+            ipAddress = source.ipAddress;
+            gateway = source.gateway;
+            dnsServers.addAll(source.dnsServers);
+            domains = source.domains;
+        }
+    }
+
+    public void clear() {
+        ipAddress = null;
+        gateway = null;
+        dnsServers.clear();
+        domains = null;
+    }
+
+    /**
+     * Returns the network routes specified by this object. Will typically include a
+     * directly-connected route for the IP address's local subnet and a default route.
+     */
+    public List<RouteInfo> getRoutes(String iface) {
+        List<RouteInfo> routes = new ArrayList<RouteInfo>(2);
+        if (ipAddress != null) {
+            routes.add(new RouteInfo(ipAddress, null, iface));
+        }
+        if (gateway != null) {
+            routes.add(new RouteInfo((LinkAddress) null, gateway, iface));
+        }
+        return routes;
+    }
+
+    /**
+     * Returns a LinkProperties object expressing the data in this object. Note that the information
+     * contained in the LinkProperties will not be a complete picture of the link's configuration,
+     * because any configuration information that is obtained dynamically by the network (e.g.,
+     * IPv6 configuration) will not be included.
+     */
+    public LinkProperties toLinkProperties(String iface) {
+        LinkProperties lp = new LinkProperties();
+        lp.setInterfaceName(iface);
+        if (ipAddress != null) {
+            lp.addLinkAddress(ipAddress);
+        }
+        for (RouteInfo route : getRoutes(iface)) {
+            lp.addRoute(route);
+        }
+        for (InetAddress dns : dnsServers) {
+            lp.addDnsServer(dns);
+        }
+        return lp;
+    }
+
+    public String toString() {
+        StringBuffer str = new StringBuffer();
+
+        str.append("IP address ");
+        if (ipAddress != null ) str.append(ipAddress).append(" ");
+
+        str.append("Gateway ");
+        if (gateway != null) str.append(gateway.getHostAddress()).append(" ");
+
+        str.append(" DNS servers: [");
+        for (InetAddress dnsServer : dnsServers) {
+            str.append(" ").append(dnsServer.getHostAddress());
+        }
+
+        str.append(" ] Domains");
+        if (domains != null) str.append(domains);
+        return str.toString();
+    }
+
+    public int hashCode() {
+        int result = 13;
+        result = 47 * result + (ipAddress == null ? 0 : ipAddress.hashCode());
+        result = 47 * result + (gateway == null ? 0 : gateway.hashCode());
+        result = 47 * result + (domains == null ? 0 : domains.hashCode());
+        result = 47 * result + dnsServers.hashCode();
+        return result;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (this == obj) return true;
+
+        if (!(obj instanceof StaticIpConfiguration)) return false;
+
+        StaticIpConfiguration other = (StaticIpConfiguration) obj;
+
+        return other != null &&
+                Objects.equals(ipAddress, other.ipAddress) &&
+                Objects.equals(gateway, other.gateway) &&
+                dnsServers.equals(other.dnsServers) &&
+                Objects.equals(domains, other.domains);
+    }
+
+    /** Implement the Parcelable interface */
+    public static Creator<StaticIpConfiguration> CREATOR =
+        new Creator<StaticIpConfiguration>() {
+            public StaticIpConfiguration createFromParcel(Parcel in) {
+                StaticIpConfiguration s = new StaticIpConfiguration();
+                readFromParcel(s, in);
+                return s;
+            }
+
+            public StaticIpConfiguration[] newArray(int size) {
+                return new StaticIpConfiguration[size];
+            }
+        };
+
+    /** Implement the Parcelable interface */
+    public int describeContents() {
+        return 0;
+    }
+
+    /** Implement the Parcelable interface */
+    public void writeToParcel(Parcel dest, int flags) {
+        dest.writeParcelable(ipAddress, flags);
+        NetworkUtils.parcelInetAddress(dest, gateway, flags);
+        dest.writeInt(dnsServers.size());
+        for (InetAddress dnsServer : dnsServers) {
+            NetworkUtils.parcelInetAddress(dest, dnsServer, flags);
+        }
+    }
+
+    protected static void readFromParcel(StaticIpConfiguration s, Parcel in) {
+        s.ipAddress = in.readParcelable(null);
+        s.gateway = NetworkUtils.unparcelInetAddress(in);
+        s.dnsServers.clear();
+        int size = in.readInt();
+        for (int i = 0; i < size; i++) {
+            s.dnsServers.add(NetworkUtils.unparcelInetAddress(in));
+        }
+    }
+}
diff --git a/core/java/android/net/VpnService.java b/core/java/android/net/VpnService.java
index 99bccd0..c848993 100644
--- a/core/java/android/net/VpnService.java
+++ b/core/java/android/net/VpnService.java
@@ -24,6 +24,7 @@
 import android.app.Service;
 import android.content.Context;
 import android.content.Intent;
+import android.content.pm.IPackageManager;
 import android.content.pm.PackageManager;
 import android.net.NetworkUtils;
 import android.os.Binder;
@@ -32,6 +33,7 @@
 import android.os.ParcelFileDescriptor;
 import android.os.RemoteException;
 import android.os.ServiceManager;
+import android.os.UserHandle;
 
 import com.android.internal.net.VpnConfig;
 
@@ -60,7 +62,8 @@
  * conflict with each other. The system takes several actions to address
  * these issues. Here are some key points:
  * <ul>
- *   <li>User action is required to create a VPN connection.</li>
+ *   <li>User action is required the first time an application creates a VPN
+ *       connection.</li>
  *   <li>There can be only one VPN connection running at the same time. The
  *       existing interface is deactivated when a new one is created.</li>
  *   <li>A system-managed notification is shown during the lifetime of a
@@ -80,8 +83,8 @@
  * other methods in this class, and the right can be revoked at any time.
  * Here are the general steps to create a VPN connection:
  * <ol>
- *   <li>When the user press the button to connect, call {@link #prepare}
- *       and launch the returned intent.</li>
+ *   <li>When the user presses the button to connect, call {@link #prepare}
+ *       and launch the returned intent, if non-null.</li>
  *   <li>When the application becomes prepared, start the service.</li>
  *   <li>Create a tunnel to the remote server and negotiate the network
  *       parameters for the VPN connection.</li>
@@ -128,7 +131,8 @@
 
     /**
      * Prepare to establish a VPN connection. This method returns {@code null}
-     * if the VPN application is already prepared. Otherwise, it returns an
+     * if the VPN application is already prepared or if the user has previously
+     * consented to the VPN application. Otherwise, it returns an
      * {@link Intent} to a system activity. The application should launch the
      * activity using {@link Activity#startActivityForResult} to get itself
      * prepared. The activity may pop up a dialog to require user action, and
@@ -142,6 +146,10 @@
      * it becomes prepared again, subsequent calls to other methods in this
      * class will fail.
      *
+     * <p>The user may disable the VPN at any time while it is activated, in
+     * which case this method will return an intent the next time it is
+     * executed to obtain the user's consent again.
+     *
      * @see #onRevoke
      */
     public static Intent prepare(Context context) {
@@ -210,6 +218,8 @@
      *
      * @return {@code true} on success.
      * @see Builder#addAddress
+     *
+     * @hide
      */
     public boolean addAddress(InetAddress address, int prefixLength) {
         check(address, prefixLength);
@@ -238,6 +248,8 @@
      * @param prefixLength The prefix length of the address.
      *
      * @return {@code true} on success.
+     *
+     * @hide
      */
     public boolean removeAddress(InetAddress address, int prefixLength) {
         check(address, prefixLength);
@@ -518,12 +530,23 @@
             return this;
         }
 
+        private void verifyApp(String packageName) throws PackageManager.NameNotFoundException {
+            IPackageManager pm = IPackageManager.Stub.asInterface(
+                    ServiceManager.getService("package"));
+            try {
+                pm.getApplicationInfo(packageName, 0, UserHandle.getCallingUserId());
+            } catch (RemoteException e) {
+                throw new IllegalStateException(e);
+            }
+        }
+
         /**
          * Adds an application that's allowed to access the VPN connection.
          *
          * If this method is called at least once, only applications added through this method (and
          * no others) are allowed access. Else (if this method is never called), all applications
-         * are allowed by default.
+         * are allowed by default.  If some applications are added, other, un-added applications
+         * will use networking as if the VPN wasn't running.
          *
          * A {@link Builder} may have only a set of allowed applications OR a set of disallowed
          * ones, but not both. Calling this method after {@link #addDisallowedApplication} has
@@ -540,7 +563,14 @@
          */
         public Builder addAllowedApplication(String packageName)
                 throws PackageManager.NameNotFoundException {
-            // TODO
+            if (mConfig.disallowedApplications != null) {
+                throw new UnsupportedOperationException("addDisallowedApplication already called");
+            }
+            verifyApp(packageName);
+            if (mConfig.allowedApplications == null) {
+                mConfig.allowedApplications = new ArrayList<String>();
+            }
+            mConfig.allowedApplications.add(packageName);
             return this;
         }
 
@@ -548,7 +578,7 @@
          * Adds an application that's denied access to the VPN connection.
          *
          * By default, all applications are allowed access, except for those denied through this
-         * method.
+         * method.  Denied applications will use networking as if the VPN wasn't running.
          *
          * A {@link Builder} may have only a set of allowed applications OR a set of disallowed
          * ones, but not both. Calling this method after {@link #addAllowedApplication} has already
@@ -565,7 +595,14 @@
          */
         public Builder addDisallowedApplication(String packageName)
                 throws PackageManager.NameNotFoundException {
-            // TODO
+            if (mConfig.allowedApplications != null) {
+                throw new UnsupportedOperationException("addAllowedApplication already called");
+            }
+            verifyApp(packageName);
+            if (mConfig.disallowedApplications == null) {
+                mConfig.disallowedApplications = new ArrayList<String>();
+            }
+            mConfig.disallowedApplications.add(packageName);
             return this;
         }
 
diff --git a/core/java/android/nfc/INfcAdapter.aidl b/core/java/android/nfc/INfcAdapter.aidl
index 5815fa6..9129121 100644
--- a/core/java/android/nfc/INfcAdapter.aidl
+++ b/core/java/android/nfc/INfcAdapter.aidl
@@ -45,6 +45,8 @@
     boolean enableNdefPush();
     boolean disableNdefPush();
     boolean isNdefPushEnabled();
+    void pausePolling(int timeoutInMs);
+    void resumePolling();
 
     void setForegroundDispatch(in PendingIntent intent,
             in IntentFilter[] filters, in TechListParcel techLists);
@@ -57,7 +59,6 @@
     void setReaderMode (IBinder b, IAppCallback callback, int flags, in Bundle extras);
     void setP2pModes(int initatorModes, int targetModes);
 
-    void registerLockscreenDispatch(INfcLockscreenDispatch lockscreenDispatch, in int[] techList);
     void addNfcUnlockHandler(INfcUnlockHandler unlockHandler, in int[] techList);
     void removeNfcUnlockHandler(INfcUnlockHandler unlockHandler);
 }
diff --git a/core/java/android/nfc/INfcCardEmulation.aidl b/core/java/android/nfc/INfcCardEmulation.aidl
index 521f4fd..d1b132c 100644
--- a/core/java/android/nfc/INfcCardEmulation.aidl
+++ b/core/java/android/nfc/INfcCardEmulation.aidl
@@ -36,4 +36,5 @@
     List<ApduServiceInfo> getServices(int userHandle, in String category);
     boolean setPreferredService(in ComponentName service);
     boolean unsetPreferredService();
+    boolean supportsAidPrefixRegistration();
 }
diff --git a/core/java/android/nfc/NfcAdapter.java b/core/java/android/nfc/NfcAdapter.java
index 6bd5a32..300301b 100644
--- a/core/java/android/nfc/NfcAdapter.java
+++ b/core/java/android/nfc/NfcAdapter.java
@@ -384,16 +384,6 @@
         public Uri[] createBeamUris(NfcEvent event);
     }
 
-
-    /**
-     * A callback to be invoked when an application has registered for receiving
-     * tags at the lockscreen.
-     */
-    public interface NfcLockscreenDispatch {
-        public boolean onTagDetected(Tag tag);
-    }
-
-
     /**
      * A callback to be invoked when an application has registered as a
      * handler to unlock the device given an NFC tag at the lockscreen.
@@ -712,6 +702,33 @@
     }
 
     /**
+     * Pauses polling for a {@code timeoutInMs} millis. If polling must be resumed before timeout,
+     * use {@link #resumePolling()}.
+     * @hide
+     */
+    public void pausePolling(int timeoutInMs) {
+        try {
+            sService.pausePolling(timeoutInMs);
+        } catch (RemoteException e) {
+            attemptDeadServiceRecovery(e);
+        }
+    }
+
+    /**
+     * Resumes default polling for the current device state if polling is paused. Calling
+     * this while polling is not paused is a no-op.
+     *
+     * @hide
+     */
+    public void resumePolling() {
+        try {
+            sService.resumePolling();
+        } catch (RemoteException e) {
+            attemptDeadServiceRecovery(e);
+        }
+    }
+
+    /**
      * Set one or more {@link Uri}s to send using Android Beam (TM). Every
      * Uri you provide must have either scheme 'file' or scheme 'content'.
      *
@@ -1468,26 +1485,6 @@
         }
     }
 
-    public boolean registerLockscreenDispatch(final NfcLockscreenDispatch lockscreenDispatch,
-                                           String[] techList) {
-        try {
-            sService.registerLockscreenDispatch(new INfcLockscreenDispatch.Stub() {
-                @Override
-                public boolean onTagDetected(Tag tag) throws RemoteException {
-                    return lockscreenDispatch.onTagDetected(tag);
-                }
-            }, Tag.getTechCodesFromStrings(techList));
-        } catch (RemoteException e) {
-            attemptDeadServiceRecovery(e);
-            return false;
-        } catch (IllegalArgumentException e) {
-            Log.e(TAG, "Unable to register LockscreenDispatch", e);
-            return false;
-        }
-
-        return true;
-    }
-
     /**
      * Registers a new NFC unlock handler with the NFC service.
      *
diff --git a/core/java/android/nfc/cardemulation/AidGroup.java b/core/java/android/nfc/cardemulation/AidGroup.java
index 6af7b7e..4407c9d 100644
--- a/core/java/android/nfc/cardemulation/AidGroup.java
+++ b/core/java/android/nfc/cardemulation/AidGroup.java
@@ -15,10 +15,6 @@
 /**
  * The AidGroup class represents a group of Application Identifiers (AIDs).
  *
- * <p>An instance of this object can be used with
- * {@link CardEmulation#registerAidsForService(android.content.ComponentName, String, java.util.List)}
- * to tell the OS which AIDs are handled by your HCE- or SE-based service.
- *
  * <p>The format of AIDs is defined in the ISO/IEC 7816-4 specification. This class
  * requires the AIDs to be input as a hexadecimal string, with an even amount of
  * hexadecimal characters, e.g. "F014811481".
@@ -60,7 +56,10 @@
         } else {
             this.category = CardEmulation.CATEGORY_OTHER;
         }
-        this.aids = aids;
+        this.aids = new ArrayList<String>(aids.size());
+        for (String aid : aids) {
+            this.aids.add(aid.toUpperCase());
+        }
         this.description = null;
     }
 
@@ -78,7 +77,7 @@
     }
 
     /**
-     * @return the list of  AIDs in this group
+     * @return the list of AIDs in this group
      */
     public List<String> getAids() {
         return aids;
@@ -144,7 +143,7 @@
                     if (inGroup) {
                         String aid = parser.getAttributeValue(null, "value");
                         if (aid != null) {
-                            aids.add(aid);
+                            aids.add(aid.toUpperCase());
                         }
                     } else {
                         Log.d(TAG, "Ignoring <aid> tag while not in group");
diff --git a/core/java/android/nfc/cardemulation/ApduServiceInfo.java b/core/java/android/nfc/cardemulation/ApduServiceInfo.java
index 0df87c1..00b2ee3 100644
--- a/core/java/android/nfc/cardemulation/ApduServiceInfo.java
+++ b/core/java/android/nfc/cardemulation/ApduServiceInfo.java
@@ -224,6 +224,20 @@
                         Log.e(TAG, "Ignoring invalid or duplicate aid: " + aid);
                     }
                     a.recycle();
+                } else if (eventType == XmlPullParser.START_TAG &&
+                        "aid-prefix-filter".equals(tagName) && currentGroup != null) {
+                    final TypedArray a = res.obtainAttributes(attrs,
+                            com.android.internal.R.styleable.AidFilter);
+                    String aid = a.getString(com.android.internal.R.styleable.AidFilter_name).
+                            toUpperCase();
+                    // Add wildcard char to indicate prefix
+                    aid = aid.concat("*");
+                    if (CardEmulation.isValidAid(aid) && !currentGroup.aids.contains(aid)) {
+                        currentGroup.aids.add(aid);
+                    } else {
+                        Log.e(TAG, "Ignoring invalid or duplicate aid: " + aid);
+                    }
+                    a.recycle();
                 }
             }
         } catch (NameNotFoundException e) {
@@ -297,7 +311,7 @@
     public String getCategoryForAid(String aid) {
         ArrayList<AidGroup> groups = getAidGroups();
         for (AidGroup group : groups) {
-            if (group.aids.contains(aid)) {
+            if (group.aids.contains(aid.toUpperCase())) {
                 return group.category;
             }
         }
@@ -411,7 +425,7 @@
         public ApduServiceInfo createFromParcel(Parcel source) {
             ResolveInfo info = ResolveInfo.CREATOR.createFromParcel(source);
             String description = source.readString();
-            boolean onHost = (source.readInt() != 0) ? true : false;
+            boolean onHost = source.readInt() != 0;
             ArrayList<AidGroup> staticAidGroups = new ArrayList<AidGroup>();
             int numStaticGroups = source.readInt();
             if (numStaticGroups > 0) {
@@ -422,7 +436,7 @@
             if (numDynamicGroups > 0) {
                 source.readTypedList(dynamicAidGroups, AidGroup.CREATOR);
             }
-            boolean requiresUnlock = (source.readInt() != 0) ? true : false;
+            boolean requiresUnlock = source.readInt() != 0;
             int bannerResource = source.readInt();
             int uid = source.readInt();
             return new ApduServiceInfo(info, onHost, description, staticAidGroups,
diff --git a/core/java/android/nfc/cardemulation/CardEmulation.java b/core/java/android/nfc/cardemulation/CardEmulation.java
index 0e0c255..64c2bc2 100644
--- a/core/java/android/nfc/cardemulation/CardEmulation.java
+++ b/core/java/android/nfc/cardemulation/CardEmulation.java
@@ -515,8 +515,21 @@
      * @return whether AID prefix registering is supported on this device.
      */
     public boolean supportsAidPrefixRegistration() {
-        // TODO
-        return false;
+        try {
+            return sService.supportsAidPrefixRegistration();
+        } catch (RemoteException e) {
+            recoverService();
+            if (sService == null) {
+                Log.e(TAG, "Failed to recover CardEmulationService.");
+                return false;
+            }
+            try {
+                return sService.supportsAidPrefixRegistration();
+            } catch (RemoteException ee) {
+                Log.e(TAG, "Failed to reach CardEmulationService.");
+                return false;
+            }
+        }
     }
 
     /**
diff --git a/core/java/android/os/BatteryStats.java b/core/java/android/os/BatteryStats.java
index be46bc7..461469c 100644
--- a/core/java/android/os/BatteryStats.java
+++ b/core/java/android/os/BatteryStats.java
@@ -1667,7 +1667,7 @@
      */
     public abstract long[] getChargeStepDurationsArray();
 
-    public abstract Map<String, ? extends LongCounter> getWakeupReasonStats();
+    public abstract Map<String, ? extends Timer> getWakeupReasonStats();
 
     public abstract Map<String, ? extends Timer> getKernelWakelockStats();
 
@@ -2045,11 +2045,15 @@
                             sb.toString());
                 }
             }
-            Map<String, ? extends LongCounter> wakeupReasons = getWakeupReasonStats();
+            Map<String, ? extends Timer> wakeupReasons = getWakeupReasonStats();
             if (wakeupReasons.size() > 0) {
-                for (Map.Entry<String, ? extends LongCounter> ent : wakeupReasons.entrySet()) {
+                for (Map.Entry<String, ? extends Timer> ent : wakeupReasons.entrySet()) {
+                    // Not doing the regular wake lock formatting to remain compatible
+                    // with the old checkin format.
+                    long totalTimeMicros = ent.getValue().getTotalTimeLocked(rawRealtime, which);
+                    int count = ent.getValue().getCountLocked(which);
                     dumpLine(pw, 0 /* uid */, category, WAKEUP_REASON_DATA,
-                            "\"" + ent.getKey() + "\"", ent.getValue().getCountLocked(which));
+                            "\"" + ent.getKey() + "\"", (totalTimeMicros + 500) / 1000, count);
                 }
             }
         }
@@ -2921,14 +2925,14 @@
                 pw.println();
             }
 
-            Map<String, ? extends LongCounter> wakeupReasons = getWakeupReasonStats();
+            Map<String, ? extends Timer> wakeupReasons = getWakeupReasonStats();
             if (wakeupReasons.size() > 0) {
                 pw.print(prefix); pw.println("  All wakeup reasons:");
                 final ArrayList<TimerEntry> reasons = new ArrayList<TimerEntry>();
-                for (Map.Entry<String, ? extends LongCounter> ent : wakeupReasons.entrySet()) {
-                    BatteryStats.LongCounter counter = ent.getValue();
-                    reasons.add(new TimerEntry(ent.getKey(), 0, null,
-                            ent.getValue().getCountLocked(which)));
+                for (Map.Entry<String, ? extends Timer> ent : wakeupReasons.entrySet()) {
+                    Timer timer = ent.getValue();
+                    reasons.add(new TimerEntry(ent.getKey(), 0, timer,
+                            timer.getCountLocked(which)));
                 }
                 Collections.sort(reasons, timerComparator);
                 for (int i=0; i<reasons.size(); i++) {
@@ -2938,9 +2942,8 @@
                     sb.append(prefix);
                     sb.append("  Wakeup reason ");
                     sb.append(timer.mName);
-                    sb.append(": ");
-                    formatTimeMs(sb, timer.mTime);
-                    sb.append("realtime");
+                    printWakeLock(sb, timer.mTimer, rawRealtime, null, which, ": ");
+                    sb.append(" realtime");
                     pw.println(sb.toString());
                 }
                 pw.println();
@@ -3065,7 +3068,7 @@
                             "partial", which, linePrefix);
                     linePrefix = printWakeLock(sb, wl.getWakeTime(WAKE_TYPE_WINDOW), rawRealtime,
                             "window", which, linePrefix);
-                    if (!linePrefix.equals(": ")) {
+                    if (true || !linePrefix.equals(": ")) {
                         sb.append(" realtime");
                         // Only print out wake locks that were held
                         pw.println(sb.toString());
@@ -3138,7 +3141,7 @@
             }
 
             Map<String, ? extends Timer> jobs = u.getJobStats();
-            if (syncs.size() > 0) {
+            if (jobs.size() > 0) {
                 for (Map.Entry<String, ? extends Timer> ent : jobs.entrySet()) {
                     Timer timer = ent.getValue();
                     // Convert from microseconds to milliseconds with rounding
@@ -3952,7 +3955,7 @@
         prepareForDumpLocked();
 
         dumpLine(pw, 0 /* uid */, "i" /* category */, VERSION_DATA,
-                "10", getParcelVersion(), getStartPlatformVersion(), getEndPlatformVersion());
+                "11", getParcelVersion(), getStartPlatformVersion(), getEndPlatformVersion());
 
         long now = getHistoryBaseTime() + SystemClock.elapsedRealtime();
 
diff --git a/core/java/android/os/Build.java b/core/java/android/os/Build.java
index b0e0b49..1e0dc53 100644
--- a/core/java/android/os/Build.java
+++ b/core/java/android/os/Build.java
@@ -541,7 +541,7 @@
          * Intent.</li>
          * </ul>
          */
-        public static final int L = CUR_DEVELOPMENT;
+        public static final int L = 21;
     }
     
     /** The type of build, like "user" or "eng". */
diff --git a/core/java/android/os/Bundle.java b/core/java/android/os/Bundle.java
index 3252d19..a9aa570 100644
--- a/core/java/android/os/Bundle.java
+++ b/core/java/android/os/Bundle.java
@@ -17,6 +17,8 @@
 package android.os;
 
 import android.util.ArrayMap;
+import android.util.Size;
+import android.util.SizeF;
 import android.util.SparseArray;
 
 import java.io.Serializable;
@@ -335,6 +337,30 @@
     }
 
     /**
+     * Inserts a Size value into the mapping of this Bundle, replacing
+     * any existing value for the given key.  Either key or value may be null.
+     *
+     * @param key a String, or null
+     * @param value a Size object, or null
+     */
+    public void putSize(String key, Size value) {
+        unparcel();
+        mMap.put(key, value);
+    }
+
+    /**
+     * Inserts a SizeF value into the mapping of this Bundle, replacing
+     * any existing value for the given key.  Either key or value may be null.
+     *
+     * @param key a String, or null
+     * @param value a SizeF object, or null
+     */
+    public void putSizeF(String key, SizeF value) {
+        unparcel();
+        mMap.put(key, value);
+    }
+
+    /**
      * Inserts an array of Parcelable values into the mapping of this Bundle,
      * replacing any existing value for the given key.  Either key or value may
      * be null.
@@ -712,6 +738,44 @@
      * value is explicitly associated with the key.
      *
      * @param key a String, or null
+     * @return a Size value, or null
+     */
+    public Size getSize(String key) {
+        unparcel();
+        final Object o = mMap.get(key);
+        try {
+            return (Size) o;
+        } catch (ClassCastException e) {
+            typeWarning(key, o, "Size", e);
+            return null;
+        }
+    }
+
+    /**
+     * Returns the value associated with the given key, or null if
+     * no mapping of the desired type exists for the given key or a null
+     * value is explicitly associated with the key.
+     *
+     * @param key a String, or null
+     * @return a Size value, or null
+     */
+    public SizeF getSizeF(String key) {
+        unparcel();
+        final Object o = mMap.get(key);
+        try {
+            return (SizeF) o;
+        } catch (ClassCastException e) {
+            typeWarning(key, o, "SizeF", e);
+            return null;
+        }
+    }
+
+    /**
+     * Returns the value associated with the given key, or null if
+     * no mapping of the desired type exists for the given key or a null
+     * value is explicitly associated with the key.
+     *
+     * @param key a String, or null
      * @return a Bundle value, or null
      */
     public Bundle getBundle(String key) {
diff --git a/core/java/android/os/FileBridge.java b/core/java/android/os/FileBridge.java
index 1e1ad9e..0acf24b 100644
--- a/core/java/android/os/FileBridge.java
+++ b/core/java/android/os/FileBridge.java
@@ -75,6 +75,13 @@
         return mClosed;
     }
 
+    public void forceClose() {
+        IoUtils.closeQuietly(mTarget);
+        IoUtils.closeQuietly(mServer);
+        IoUtils.closeQuietly(mClient);
+        mClosed = true;
+    }
+
     public void setTargetFile(FileDescriptor target) {
         mTarget = target;
     }
@@ -89,12 +96,15 @@
         try {
             while (IoBridge.read(mServer, temp, 0, MSG_LENGTH) == MSG_LENGTH) {
                 final int cmd = Memory.peekInt(temp, 0, ByteOrder.BIG_ENDIAN);
-
                 if (cmd == CMD_WRITE) {
                     // Shuttle data into local file
                     int len = Memory.peekInt(temp, 4, ByteOrder.BIG_ENDIAN);
                     while (len > 0) {
                         int n = IoBridge.read(mServer, temp, 0, Math.min(temp.length, len));
+                        if (n == -1) {
+                            throw new IOException(
+                                    "Unexpected EOF; still expected " + len + " bytes");
+                        }
                         IoBridge.write(mTarget, temp, 0, n);
                         len -= n;
                     }
@@ -114,23 +124,25 @@
                 }
             }
 
-        } catch (ErrnoException e) {
-            Log.e(TAG, "Failed during bridge: ", e);
-        } catch (IOException e) {
-            Log.e(TAG, "Failed during bridge: ", e);
+        } catch (ErrnoException | IOException e) {
+            Log.wtf(TAG, "Failed during bridge", e);
         } finally {
-            IoUtils.closeQuietly(mTarget);
-            IoUtils.closeQuietly(mServer);
-            IoUtils.closeQuietly(mClient);
-            mClosed = true;
+            forceClose();
         }
     }
 
     public static class FileBridgeOutputStream extends OutputStream {
+        private final ParcelFileDescriptor mClientPfd;
         private final FileDescriptor mClient;
         private final byte[] mTemp = new byte[MSG_LENGTH];
 
+        public FileBridgeOutputStream(ParcelFileDescriptor clientPfd) {
+            mClientPfd = clientPfd;
+            mClient = clientPfd.getFileDescriptor();
+        }
+
         public FileBridgeOutputStream(FileDescriptor client) {
+            mClientPfd = null;
             mClient = client;
         }
 
@@ -140,6 +152,7 @@
                 writeCommandAndBlock(CMD_CLOSE, "close()");
             } finally {
                 IoBridge.closeAndSignalBlockedThreads(mClient);
+                IoUtils.closeQuietly(mClientPfd);
             }
         }
 
diff --git a/core/java/android/os/INetworkManagementService.aidl b/core/java/android/os/INetworkManagementService.aidl
index 6d4a302..b3e28ea 100644
--- a/core/java/android/os/INetworkManagementService.aidl
+++ b/core/java/android/os/INetworkManagementService.aidl
@@ -19,6 +19,7 @@
 
 import android.net.InterfaceConfiguration;
 import android.net.INetworkManagementEventObserver;
+import android.net.Network;
 import android.net.NetworkStats;
 import android.net.RouteInfo;
 import android.net.UidRange;
@@ -164,10 +165,10 @@
     /**
      * Sets the list of DNS forwarders (in order of priority)
      */
-    void setDnsForwarders(in String[] dns);
+    void setDnsForwarders(in Network network, in String[] dns);
 
     /**
-     * Returns the list of DNS fowarders (in order of priority)
+     * Returns the list of DNS forwarders (in order of priority)
      */
     String[] getDnsForwarders();
 
diff --git a/core/java/android/os/IPowerManager.aidl b/core/java/android/os/IPowerManager.aidl
index 658180b..182dbee 100644
--- a/core/java/android/os/IPowerManager.aidl
+++ b/core/java/android/os/IPowerManager.aidl
@@ -42,6 +42,7 @@
     void nap(long time);
     boolean isInteractive();
     boolean isPowerSaveMode();
+    boolean setPowerSaveMode(boolean mode);
 
     void reboot(boolean confirm, String reason, boolean wait);
     void shutdown(boolean confirm, boolean wait);
diff --git a/core/java/android/os/IUserManager.aidl b/core/java/android/os/IUserManager.aidl
index 713fcd8..b5295fb 100644
--- a/core/java/android/os/IUserManager.aidl
+++ b/core/java/android/os/IUserManager.aidl
@@ -41,6 +41,7 @@
     int getUserSerialNumber(int userHandle);
     int getUserHandle(int userSerialNumber);
     Bundle getUserRestrictions(int userHandle);
+    boolean hasUserRestriction(in String restrictionKey, int userHandle);
     void setUserRestrictions(in Bundle restrictions, int userHandle);
     void setApplicationRestrictions(in String packageName, in Bundle restrictions,
             int userHandle);
@@ -52,4 +53,5 @@
     void removeRestrictions();
     void setDefaultGuestRestrictions(in Bundle restrictions);
     Bundle getDefaultGuestRestrictions();
+    boolean markGuestForDeletion(int userHandle);
 }
diff --git a/core/java/android/os/Message.java b/core/java/android/os/Message.java
index 1a5811c..b6b70cc 100644
--- a/core/java/android/os/Message.java
+++ b/core/java/android/os/Message.java
@@ -113,6 +113,8 @@
 
     private static final int MAX_POOL_SIZE = 50;
 
+    private static boolean gCheckRecycle = true;
+
     /**
      * Return a new Message instance from the global pool. Allows us to
      * avoid allocating new objects in many cases.
@@ -256,6 +258,13 @@
         return m;
     }
 
+    /** @hide */
+    public static void updateCheckRecycle(int targetSdkVersion) {
+        if (targetSdkVersion < Build.VERSION_CODES.L) {
+            gCheckRecycle = false;
+        }
+    }
+
     /**
      * Return a Message instance to the global pool.
      * <p>
@@ -266,8 +275,11 @@
      */
     public void recycle() {
         if (isInUse()) {
-            throw new IllegalStateException("This message cannot be recycled because it "
-                    + "is still in use.");
+            if (gCheckRecycle) {
+                throw new IllegalStateException("This message cannot be recycled because it "
+                        + "is still in use.");
+            }
+            return;
         }
         recycleUnchecked();
     }
diff --git a/core/java/android/os/Parcel.java b/core/java/android/os/Parcel.java
index 645d510..5230128 100644
--- a/core/java/android/os/Parcel.java
+++ b/core/java/android/os/Parcel.java
@@ -19,6 +19,8 @@
 import android.text.TextUtils;
 import android.util.ArrayMap;
 import android.util.Log;
+import android.util.Size;
+import android.util.SizeF;
 import android.util.SparseArray;
 import android.util.SparseBooleanArray;
 
@@ -224,6 +226,8 @@
     private static final int VAL_BOOLEANARRAY = 23;
     private static final int VAL_CHARSEQUENCEARRAY = 24;
     private static final int VAL_PERSISTABLEBUNDLE = 25;
+    private static final int VAL_SIZE = 26;
+    private static final int VAL_SIZEF = 27;
 
     // The initial int32 in a Binder call's reply Parcel header:
     private static final int EX_SECURITY = -1;
@@ -232,6 +236,7 @@
     private static final int EX_NULL_POINTER = -4;
     private static final int EX_ILLEGAL_STATE = -5;
     private static final int EX_NETWORK_MAIN_THREAD = -6;
+    private static final int EX_UNSUPPORTED_OPERATION = -7;
     private static final int EX_HAS_REPLY_HEADER = -128;  // special; see below
 
     private static native int nativeDataSize(long nativePtr);
@@ -672,6 +677,24 @@
     }
 
     /**
+     * Flatten a Size into the parcel at the current dataPosition(),
+     * growing dataCapacity() if needed.
+     */
+    public final void writeSize(Size val) {
+        writeInt(val.getWidth());
+        writeInt(val.getHeight());
+    }
+
+    /**
+     * Flatten a SizeF into the parcel at the current dataPosition(),
+     * growing dataCapacity() if needed.
+     */
+    public final void writeSizeF(SizeF val) {
+        writeFloat(val.getWidth());
+        writeFloat(val.getHeight());
+    }
+
+    /**
      * Flatten a List into the parcel at the current dataPosition(), growing
      * dataCapacity() if needed.  The List values are written using
      * {@link #writeValue} and must follow the specification there.
@@ -1293,6 +1316,12 @@
         } else if (v instanceof PersistableBundle) {
             writeInt(VAL_PERSISTABLEBUNDLE);
             writePersistableBundle((PersistableBundle) v);
+        } else if (v instanceof Size) {
+            writeInt(VAL_SIZE);
+            writeSize((Size) v);
+        } else if (v instanceof SizeF) {
+            writeInt(VAL_SIZEF);
+            writeSizeF((SizeF) v);
         } else {
             Class<?> clazz = v.getClass();
             if (clazz.isArray() && clazz.getComponentType() == Object.class) {
@@ -1399,6 +1428,8 @@
             code = EX_ILLEGAL_STATE;
         } else if (e instanceof NetworkOnMainThreadException) {
             code = EX_NETWORK_MAIN_THREAD;
+        } else if (e instanceof UnsupportedOperationException) {
+            code = EX_UNSUPPORTED_OPERATION;
         }
         writeInt(code);
         StrictMode.clearGatheredViolations();
@@ -1517,6 +1548,8 @@
                 throw new IllegalStateException(msg);
             case EX_NETWORK_MAIN_THREAD:
                 throw new NetworkOnMainThreadException();
+            case EX_UNSUPPORTED_OPERATION:
+                throw new UnsupportedOperationException(msg);
         }
         throw new RuntimeException("Unknown exception code: " + code
                 + " msg " + msg);
@@ -1699,6 +1732,24 @@
     }
 
     /**
+     * Read a Size from the parcel at the current dataPosition().
+     */
+    public final Size readSize() {
+        final int width = readInt();
+        final int height = readInt();
+        return new Size(width, height);
+    }
+
+    /**
+     * Read a SizeF from the parcel at the current dataPosition().
+     */
+    public final SizeF readSizeF() {
+        final float width = readFloat();
+        final float height = readFloat();
+        return new SizeF(width, height);
+    }
+
+    /**
      * Read and return a byte[] object from the parcel.
      */
     public final byte[] createByteArray() {
@@ -2160,6 +2211,12 @@
         case VAL_PERSISTABLEBUNDLE:
             return readPersistableBundle(loader);
 
+        case VAL_SIZE:
+            return readSize();
+
+        case VAL_SIZEF:
+            return readSizeF();
+
         default:
             int off = dataPosition() - 4;
             throw new RuntimeException(
diff --git a/core/java/android/os/PowerManager.java b/core/java/android/os/PowerManager.java
index 75f8279..3b6ce53 100644
--- a/core/java/android/os/PowerManager.java
+++ b/core/java/android/os/PowerManager.java
@@ -17,6 +17,7 @@
 package android.os;
 
 import android.annotation.SdkConstant;
+import android.annotation.SystemApi;
 import android.content.Context;
 import android.util.Log;
 
@@ -186,8 +187,6 @@
      * </p><p>
      * Cannot be used with {@link #ACQUIRE_CAUSES_WAKEUP}.
      * </p>
-     *
-     * {@hide}
      */
     public static final int PROXIMITY_SCREEN_OFF_WAKE_LOCK = 0x00000020;
 
@@ -197,6 +196,8 @@
      * <p>
      * This is used by the dream manager to implement doze mode.  It currently
      * has no effect unless the power manager is in the dozing state.
+     * </p><p>
+     * Requires the {@link android.Manifest.permission#DEVICE_POWER} permission.
      * </p>
      *
      * {@hide}
@@ -243,13 +244,11 @@
     public static final int UNIMPORTANT_FOR_LOGGING = 0x40000000;
 
     /**
-     * Flag for {@link WakeLock#release release(int)} to defer releasing a
-     * {@link #PROXIMITY_SCREEN_OFF_WAKE_LOCK} wake lock until the proximity sensor returns
-     * a negative value.
-     *
-     * {@hide}
+     * Flag for {@link WakeLock#release WakeLock.release(int)}: Defer releasing a
+     * {@link #PROXIMITY_SCREEN_OFF_WAKE_LOCK} wake lock until the proximity sensor
+     * indicates that an object is not in close proximity.
      */
-    public static final int WAIT_FOR_PROXIMITY_NEGATIVE = 1;
+    public static final int RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY = 1;
 
     /**
      * Brightness value for fully on.
@@ -276,28 +275,44 @@
      * User activity event type: Unspecified event type.
      * @hide
      */
+    @SystemApi
     public static final int USER_ACTIVITY_EVENT_OTHER = 0;
 
     /**
      * User activity event type: Button or key pressed or released.
      * @hide
      */
+    @SystemApi
     public static final int USER_ACTIVITY_EVENT_BUTTON = 1;
 
     /**
      * User activity event type: Touch down, move or up.
      * @hide
      */
+    @SystemApi
     public static final int USER_ACTIVITY_EVENT_TOUCH = 2;
 
     /**
-     * User activity flag: Do not restart the user activity timeout or brighten
-     * the display in response to user activity if it is already dimmed.
+     * User activity flag: If already dimmed, extend the dim timeout
+     * but do not brighten.  This flag is useful for keeping the screen on
+     * a little longer without causing a visible change such as when
+     * the power key is pressed.
      * @hide
      */
+    @SystemApi
     public static final int USER_ACTIVITY_FLAG_NO_CHANGE_LIGHTS = 1 << 0;
 
     /**
+     * User activity flag: Note the user activity as usual but do not
+     * reset the user activity timeout.  This flag is useful for applying
+     * user activity power hints when interacting with the device indirectly
+     * on a secondary screen while allowing the primary screen to go to sleep.
+     * @hide
+     */
+    @SystemApi
+    public static final int USER_ACTIVITY_FLAG_INDIRECT = 1 << 1;
+
+    /**
      * Go to sleep reason code: Going to sleep due by application request.
      * @hide
      */
@@ -335,6 +350,12 @@
     public static final int GO_TO_SLEEP_REASON_HDMI = 5;
 
     /**
+     * Go to sleep flag: Skip dozing state and directly go to full sleep.
+     * @hide
+     */
+    public static final int GO_TO_SLEEP_FLAG_NO_DOZE = 1 << 0;
+
+    /**
      * The value to pass as the 'reason' argument to reboot() to
      * reboot into recovery mode (for applying system updates, doing
      * factory resets, etc.).
@@ -347,12 +368,6 @@
      */
     public static final String REBOOT_RECOVERY = "recovery";
     
-    /**
-     * Go to sleep flag: Skip dozing state and directly go to full sleep.
-     * @hide
-     */
-    public static final int GO_TO_SLEEP_FLAG_NO_DOZE = 1 << 0;
-
     final Context mContext;
     final IPowerManager mService;
     final Handler mHandler;
@@ -456,6 +471,7 @@
      * @see #FULL_WAKE_LOCK
      * @see #SCREEN_DIM_WAKE_LOCK
      * @see #SCREEN_BRIGHT_WAKE_LOCK
+     * @see #PROXIMITY_SCREEN_OFF_WAKE_LOCK
      * @see #ACQUIRE_CAUSES_WAKEUP
      * @see #ON_AFTER_RELEASE
      */
@@ -505,11 +521,44 @@
      *
      * @see #wakeUp
      * @see #goToSleep
+     *
+     * @removed Requires signature or system permission.
+     * @deprecated Use {@link #userActivity(long, int, int)}.
      */
+    @Deprecated
     public void userActivity(long when, boolean noChangeLights) {
+        userActivity(when, USER_ACTIVITY_EVENT_OTHER,
+                noChangeLights ? USER_ACTIVITY_FLAG_NO_CHANGE_LIGHTS : 0);
+    }
+
+    /**
+     * Notifies the power manager that user activity happened.
+     * <p>
+     * Resets the auto-off timer and brightens the screen if the device
+     * is not asleep.  This is what happens normally when a key or the touch
+     * screen is pressed or when some other user activity occurs.
+     * This method does not wake up the device if it has been put to sleep.
+     * </p><p>
+     * Requires the {@link android.Manifest.permission#DEVICE_POWER} or
+     * {@link android.Manifest.permission#USER_ACTIVITY} permission.
+     * </p>
+     *
+     * @param when The time of the user activity, in the {@link SystemClock#uptimeMillis()}
+     * time base.  This timestamp is used to correctly order the user activity request with
+     * other power management functions.  It should be set
+     * to the timestamp of the input event that caused the user activity.
+     * @param event The user activity event.
+     * @param flags Optional user activity flags.
+     *
+     * @see #wakeUp
+     * @see #goToSleep
+     *
+     * @hide Requires signature or system permission.
+     */
+    @SystemApi
+    public void userActivity(long when, int event, int flags) {
         try {
-            mService.userActivity(when, USER_ACTIVITY_EVENT_OTHER,
-                    noChangeLights ? USER_ACTIVITY_FLAG_NO_CHANGE_LIGHTS : 0);
+            mService.userActivity(when, event, flags);
         } catch (RemoteException e) {
         }
     }
@@ -530,13 +579,33 @@
      *
      * @see #userActivity
      * @see #wakeUp
+     *
+     * @removed Requires signature permission.
      */
     public void goToSleep(long time) {
         goToSleep(time, GO_TO_SLEEP_REASON_APPLICATION, 0);
     }
 
     /**
-     * @hide
+     * Forces the device to go to sleep.
+     * <p>
+     * Overrides all the wake locks that are held.
+     * This is what happens when the power key is pressed to turn off the screen.
+     * </p><p>
+     * Requires the {@link android.Manifest.permission#DEVICE_POWER} permission.
+     * </p>
+     *
+     * @param time The time when the request to go to sleep was issued, in the
+     * {@link SystemClock#uptimeMillis()} time base.  This timestamp is used to correctly
+     * order the go to sleep request with other power management functions.  It should be set
+     * to the timestamp of the input event that caused the request to go to sleep.
+     * @param reason The reason the device is going to sleep.
+     * @param flags Optional flags to apply when going to sleep.
+     *
+     * @see #userActivity
+     * @see #wakeUp
+     *
+     * @hide Requires signature permission.
      */
     public void goToSleep(long time, int reason, int flags) {
         try {
@@ -561,6 +630,8 @@
      *
      * @see #userActivity
      * @see #goToSleep
+     *
+     * @removed Requires signature permission.
      */
     public void wakeUp(long time) {
         try {
@@ -588,7 +659,7 @@
      * @see #wakeUp
      * @see #goToSleep
      *
-     * @hide
+     * @hide Requires signature permission.
      */
     public void nap(long time) {
         try {
@@ -605,7 +676,7 @@
      *
      * @param brightness The brightness value from 0 to 255.
      *
-     * {@hide}
+     * @hide Requires signature permission.
      */
     public void setBacklightBrightness(int brightness) {
         try {
@@ -619,8 +690,6 @@
      *
      * @param level The wake lock level to check.
      * @return True if the specified wake lock level is supported.
-     *
-     * {@hide}
      */
     public boolean isWakeLockLevelSupported(int level) {
         try {
@@ -727,6 +796,23 @@
     }
 
     /**
+     * Set the current power save mode.
+     *
+     * @return True if the set was allowed.
+     *
+     * @see #isPowerSaveMode()
+     *
+     * @hide
+     */
+    public boolean setPowerSaveMode(boolean mode) {
+        try {
+            return mService.setPowerSaveMode(mode);
+        } catch (RemoteException e) {
+            return false;
+        }
+    }
+
+    /**
      * Intent that is broadcast when the state of {@link #isPowerSaveMode()} changes.
      * This broadcast is only sent to registered receivers.
      */
@@ -892,9 +978,8 @@
          * </p>
          *
          * @param flags Combination of flag values to modify the release behavior.
-         * Currently only {@link #WAIT_FOR_PROXIMITY_NEGATIVE} is supported.
-         *
-         * {@hide}
+         * Currently only {@link #RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY} is supported.
+         * Passing 0 is equivalent to calling {@link #release()}.
          */
         public void release(int flags) {
             synchronized (mToken) {
diff --git a/core/java/android/os/Process.java b/core/java/android/os/Process.java
index c3ac012..b2ebc31 100644
--- a/core/java/android/os/Process.java
+++ b/core/java/android/os/Process.java
@@ -468,6 +468,7 @@
      * @param targetSdkVersion The target SDK version for the app.
      * @param seInfo null-ok SELinux information for the new process.
      * @param abi non-null the ABI this app should be started with.
+     * @param instructionSet null-ok the instruction set to use.
      * @param zygoteArgs Additional arguments to supply to the zygote process.
      * 
      * @return An object that describes the result of the attempt to start the process.
@@ -482,11 +483,12 @@
                                   int targetSdkVersion,
                                   String seInfo,
                                   String abi,
+                                  String instructionSet,
                                   String[] zygoteArgs) {
         try {
             return startViaZygote(processClass, niceName, uid, gid, gids,
                     debugFlags, mountExternal, targetSdkVersion, seInfo,
-                    abi, zygoteArgs);
+                    abi, instructionSet, zygoteArgs);
         } catch (ZygoteStartFailedEx ex) {
             Log.e(LOG_TAG,
                     "Starting VM process through Zygote failed");
@@ -589,6 +591,7 @@
      * @param targetSdkVersion The target SDK version for the app.
      * @param seInfo null-ok SELinux information for the new process.
      * @param abi the ABI the process should use.
+     * @param instructionSet null-ok the instruction set to use.
      * @param extraArgs Additional arguments to supply to the zygote process.
      * @return An object that describes the result of the attempt to start the process.
      * @throws ZygoteStartFailedEx if process start failed for any reason
@@ -601,6 +604,7 @@
                                   int targetSdkVersion,
                                   String seInfo,
                                   String abi,
+                                  String instructionSet,
                                   String[] extraArgs)
                                   throws ZygoteStartFailedEx {
         synchronized(Process.class) {
@@ -660,6 +664,10 @@
                 argsForZygote.add("--seinfo=" + seInfo);
             }
 
+            if (instructionSet != null) {
+                argsForZygote.add("--instruction-set=" + instructionSet);
+            }
+
             argsForZygote.add(processClass);
 
             if (extraArgs != null) {
diff --git a/core/java/android/os/UserHandle.java b/core/java/android/os/UserHandle.java
index 5ce9d5c..0ff5f6a 100644
--- a/core/java/android/os/UserHandle.java
+++ b/core/java/android/os/UserHandle.java
@@ -234,6 +234,7 @@
      * @return user id of the current process
      * @hide
      */
+    @SystemApi
     public static final int myUserId() {
         return getUserId(Process.myUid());
     }
@@ -253,7 +254,11 @@
         mHandle = h;
     }
 
-    /** @hide */
+    /**
+     * Returns the userId stored in this UserHandle.
+     * @hide
+     */
+    @SystemApi
     public int getIdentifier() {
         return mHandle;
     }
diff --git a/core/java/android/os/UserManager.java b/core/java/android/os/UserManager.java
index 9d1a7bc..82016c3 100644
--- a/core/java/android/os/UserManager.java
+++ b/core/java/android/os/UserManager.java
@@ -15,16 +15,15 @@
  */
 package android.os;
 
+import android.annotation.SystemApi;
 import android.app.ActivityManager;
 import android.app.ActivityManagerNative;
 import android.content.Context;
+import android.content.pm.PackageManager;
 import android.content.pm.UserInfo;
 import android.content.res.Resources;
 import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.Bitmap.Config;
 import android.graphics.Rect;
-import android.graphics.drawable.BitmapDrawable;
 import android.graphics.drawable.Drawable;
 import android.provider.Settings;
 import android.util.Log;
@@ -45,191 +44,208 @@
     private final Context mContext;
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from adding and removing
-     * accounts.
+     * Specifies if a user is disallowed from adding and removing accounts.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_MODIFY_ACCOUNTS = "no_modify_accounts";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from changing Wi-Fi
-     * access points.
-     * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies if a user is disallowed from changing Wi-Fi
+     * access points. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_WIFI = "no_config_wifi";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from installing applications.
+     * Specifies if a user is disallowed from installing applications.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_INSTALL_APPS = "no_install_apps";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from uninstalling applications.
+     * Specifies if a user is disallowed from uninstalling applications.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_UNINSTALL_APPS = "no_uninstall_apps";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from toggling location sharing.
+     * Specifies if a user is disallowed from toggling location sharing.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_SHARE_LOCATION = "no_share_location";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from enabling the
+     * Specifies if a user is disallowed from enabling the
      * "Unknown Sources" setting, that allows installation of apps from unknown sources.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_INSTALL_UNKNOWN_SOURCES = "no_install_unknown_sources";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring bluetooth.
+     * Specifies if a user is disallowed from configuring bluetooth.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_BLUETOOTH = "no_config_bluetooth";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from transferring files over
-     * USB. The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies if a user is disallowed from transferring files over
+     * USB. This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_USB_FILE_TRANSFER = "no_usb_file_transfer";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring user
+     * Specifies if a user is disallowed from configuring user
      * credentials. The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_CREDENTIALS = "no_config_credentials";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from removing itself and other
-     * users.
-     * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies if a user is disallowed from removing itself and other
+     * users. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_REMOVE_USER = "no_remove_user";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from enabling or
+     * Specifies if a user is disallowed from enabling or
      * accessing debugging features. The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_DEBUGGING_FEATURES = "no_debugging_features";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring VPN.
+     * Specifies if a user is disallowed from configuring VPN.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_VPN = "no_config_vpn";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring Tethering
-     * & portable hotspots. The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies if a user is disallowed from configuring Tethering
+     * & portable hotspots. This can only be set by device owners. The default value is
+     * <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_TETHERING = "no_config_tethering";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from factory resetting
-     * from Settings.
-     * The default value is <code>false</code>.
-     * <p>
+     * Specifies if a user is disallowed from factory resetting
+     * from Settings. This can only be set by device owners. The default value is
+     * <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_FACTORY_RESET = "no_factory_reset";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from adding new users and
-     * profiles. The default value is <code>false</code>.
-     * <p>
-     * Type: Boolean
+     * Specifies if a user is disallowed from adding new users and
+     * profiles. This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_ADD_USER = "no_add_user";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from disabling application
+     * Specifies if a user is disallowed from disabling application
      * verification. The default value is <code>false</code>.
-     * <p>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String ENSURE_VERIFY_APPS = "ensure_verify_apps";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring cell
-     * broadcasts. The default value is <code>false</code>.
-     * <p>
-     * Type: Boolean
+     * Specifies if a user is disallowed from configuring cell
+     * broadcasts. This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_CELL_BROADCASTS = "no_config_cell_broadcasts";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from configuring mobile
-     * networks. The default value is <code>false</code>.
-     * <p>
-     * Type: Boolean
+     * Specifies if a user is disallowed from configuring mobile
+     * networks. This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CONFIG_MOBILE_NETWORKS = "no_config_mobile_networks";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from modifying
+     * Specifies if a user is disallowed from modifying
      * applications in Settings or launchers. The following actions will not be allowed when this
      * restriction is enabled:
      * <li>uninstalling apps</li>
@@ -240,69 +256,75 @@
      * <li>clearing app defaults</li>
      * <p>
      * The default value is <code>false</code>.
-     * <p>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_APPS_CONTROL = "no_control_apps";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from mounting
-     * physical external media. The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies if a user is disallowed from mounting
+     * physical external media. This can only be set by device owners. The default value is
+     * <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_MOUNT_PHYSICAL_MEDIA = "no_physical_media";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from adjusting microphone
-     * volume.
+     * Specifies if a user is disallowed from adjusting microphone
+     * volume. If set, the microphone will be muted. This can only be set by device owners.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_UNMUTE_MICROPHONE = "no_unmute_microphone";
 
     /**
-     * Key for user restrictions. Specifies if a user is disallowed from adjusting the master
-     * volume.
+     * Specifies if a user is disallowed from adjusting the master
+     * volume. If set, the master volume will be muted. This can only be set by device owners.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_ADJUST_VOLUME = "no_adjust_volume";
 
     /**
-     * Key for user restrictions. Specifies that the user is not allowed to make outgoing
+     * Specifies that the user is not allowed to make outgoing
      * phone calls. Emergency calls are still permitted.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_OUTGOING_CALLS = "no_outgoing_calls";
 
     /**
-     * Key for user restrictions. Specifies that the user is not allowed to send or receive
-     * SMS messages.
-     * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * Specifies that the user is not allowed to send or receive
+     * SMS messages. This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_SMS = "no_sms";
 
     /**
-     * Key for user restrictions. Specifies that windows besides app windows should not be
+     * Specifies that windows besides app windows should not be
      * created. This will block the creation of the following types of windows.
      * <li>{@link LayoutParams#TYPE_TOAST}</li>
      * <li>{@link LayoutParams#TYPE_PHONE}</li>
@@ -311,26 +333,39 @@
      * <li>{@link LayoutParams#TYPE_SYSTEM_ERROR}</li>
      * <li>{@link LayoutParams#TYPE_SYSTEM_OVERLAY}</li>
      *
-     * <p>The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     * <p>This can only be set by device owners. The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CREATE_WINDOWS = "no_create_windows";
 
     /**
-     * Key for user restrictions. Specifies if what is copied in the clipboard of this profile can
+     * Specifies if what is copied in the clipboard of this profile can
      * be pasted in related profiles. Does not restrict if the clipboard of related profiles can be
      * pasted in this profile.
      * The default value is <code>false</code>.
-     * <p/>
-     * Type: Boolean
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
      * @see #setUserRestrictions(Bundle)
      * @see #getUserRestrictions()
      */
     public static final String DISALLOW_CROSS_PROFILE_COPY_PASTE = "no_cross_profile_copy_paste";
 
+    /**
+     * Specifies if the user is not allowed to use NFC to beam out data from apps.
+     * The default value is <code>false</code>.
+     *
+     * <p/>Key for user restrictions.
+     * <p/>Type: Boolean
+     * @see #setUserRestrictions(Bundle)
+     * @see #getUserRestrictions()
+     */
+    public static final String DISALLOW_OUTGOING_BEAM = "no_outgoing_beam";
+
     /** @hide */
     public static final int PIN_VERIFICATION_FAILED_INCORRECT = -3;
     /** @hide */
@@ -396,7 +431,8 @@
      * @return whether the user making this call is a goat
      */
     public boolean isUserAGoat() {
-        return false;
+        return mContext.getPackageManager()
+                .isPackageAvailable("com.coffeestainstudios.goatsimulator");
     }
 
     /**
@@ -425,6 +461,19 @@
     }
 
     /**
+     * Checks if the calling app is running in a managed profile.
+     * Requires {@link android.Manifest.permission#MANAGE_USERS} permission.
+     *
+     * @return whether the caller is in a managed profile.
+     * @hide
+     */
+    @SystemApi
+    public boolean isManagedProfile() {
+        UserInfo user = getUserInfo(UserHandle.myUserId());
+        return user != null ? user.isManagedProfile() : false;
+    }
+
+    /**
      * Return whether the given user is actively running.  This means that
      * the user is in the "started" state, not "stopped" -- it is currently
      * allowed to run code through scheduled alarms, receiving broadcasts,
@@ -583,7 +632,13 @@
      * @param userHandle the UserHandle of the user for whom to retrieve the restrictions.
      */
     public boolean hasUserRestriction(String restrictionKey, UserHandle userHandle) {
-        return getUserRestrictions(userHandle).getBoolean(restrictionKey, false);
+        try {
+            return mService.hasUserRestriction(restrictionKey,
+                    userHandle.getIdentifier());
+        } catch (RemoteException re) {
+            Log.w(TAG, "Could not check user restrictions", re);
+            return false;
+        }
     }
 
     /**
@@ -647,6 +702,7 @@
             try {
                 Bundle guestRestrictions = mService.getDefaultGuestRestrictions();
                 guestRestrictions.putBoolean(DISALLOW_SMS, true);
+                guestRestrictions.putBoolean(DISALLOW_INSTALL_UNKNOWN_SOURCES, true);
                 mService.setUserRestrictions(guestRestrictions, guest.id);
             } catch (RemoteException re) {
                 Log.w(TAG, "Could not update guest restrictions");
@@ -677,6 +733,22 @@
     }
 
     /**
+     * @hide
+     * Marks the guest user for deletion to allow a new guest to be created before deleting
+     * the current user who is a guest.
+     * @param userHandle
+     * @return
+     */
+    public boolean markGuestForDeletion(int userHandle) {
+        try {
+            return mService.markGuestForDeletion(userHandle);
+        } catch (RemoteException re) {
+            Log.w(TAG, "Could not mark guest for deletion", re);
+            return false;
+        }
+    }
+
+    /**
      * Sets the user as enabled, if such an user exists.
      * Requires {@link android.Manifest.permission#MANAGE_USERS} permission.
      * Note that the default is true, it's only that managed profiles might not be enabled.
@@ -808,46 +880,10 @@
      * @param user The target user.
      * @return A drawable that combines the original icon and a badge as
      *         determined by the system.
+     * @removed
      */
     public Drawable getBadgedIconForUser(Drawable icon, UserHandle user) {
-        final int badgeResId = getBadgeResIdForUser(user.getIdentifier());
-        if (badgeResId == 0) {
-            return icon;
-        }
-        Drawable badgeIcon = mContext.getPackageManager()
-                .getDrawable("system", badgeResId, null);
-        return getBadgedDrawable(icon, badgeIcon, null, true);
-    }
-
-    /**
-     * If the target user is a managed profile of the calling user or the caller
-     * is itself a managed profile, then this returns a badged copy of the given
-     * icon to be able to distinguish it from the original icon.
-     * <p>
-     * If the original drawable is not a BitmapDrawable, then the original
-     * drawable is returned.
-     * </p>
-     *
-     * @param icon The icon to badge.
-     * @param user The target user.
-     * @return A drawable that combines the original icon and a badge as
-     *         determined by the system.
-     *
-     * @deprecation Use {@link #getBadgedIconForUser(
-     *     android.graphics.drawable.Drawable, UserHandle)}
-     *
-     * @hide
-     */
-    @Deprecated
-    public Drawable getBadgedDrawableForUser(Drawable icon, UserHandle user) {
-        int badgeResId = getBadgeResIdForUser(user.getIdentifier());
-        if (badgeResId == 0) {
-            return icon;
-        } else {
-            Drawable badgeIcon = mContext.getPackageManager()
-                    .getDrawable("system", badgeResId, null);
-            return getBadgedDrawable(icon, badgeIcon, null, false);
-        }
+        return mContext.getPackageManager().getUserBadgedIcon(icon, user);
     }
 
     /**
@@ -873,14 +909,12 @@
      *         the density of the display is used.
      * @return A drawable that combines the original drawable and a badge as
      *         determined by the system.
+     * @removed
      */
     public Drawable getBadgedDrawableForUser(Drawable badgedDrawable, UserHandle user,
             Rect badgeLocation, int badgeDensity) {
-        Drawable badgeDrawable = getBadgeForUser(user, badgeDensity);
-        if (badgeDrawable == null) {
-            return badgedDrawable;
-        }
-        return getBadgedDrawable(badgedDrawable, badgeDrawable, badgeLocation, true);
+        return mContext.getPackageManager().getUserBadgedDrawableForDensity(badgedDrawable, user,
+                badgeLocation, badgeDensity);
     }
 
     /**
@@ -893,114 +927,10 @@
      * @param user The target user.
      * @return A label that combines the original label and a badge as
      *         determined by the system.
+     * @removed
      */
     public CharSequence getBadgedLabelForUser(CharSequence label, UserHandle user) {
-        UserInfo userInfo = getUserIfProfile(user.getIdentifier());
-        if (userInfo != null && userInfo.isManagedProfile()) {
-            return Resources.getSystem().getString(
-                    R.string.managed_profile_label_badge, label);
-        }
-        return label;
-    }
-
-    /**
-     * If the target user is a managed profile of the calling user or the caller
-     * is itself a managed profile, then this returns a drawable to use as a small
-     * icon to include in a view to distinguish it from the original icon.
-     *
-     * @param user The target user.
-     * @param density The optional desired density for the badge as per
-     *         {@link android.util.DisplayMetrics#densityDpi}. If not provided
-     *         the density of the current display is used.
-     * @return the drawable or null if no drawable is required.
-     * @hide
-     */
-    public Drawable getBadgeForUser(UserHandle user, int density) {
-        UserInfo userInfo = getUserIfProfile(user.getIdentifier());
-        if (userInfo != null && userInfo.isManagedProfile()) {
-            if (density <= 0) {
-                density = mContext.getResources().getDisplayMetrics().densityDpi;
-            }
-            return Resources.getSystem().getDrawableForDensity(
-                    com.android.internal.R.drawable.ic_corp_badge, density);
-        }
-        return null;
-    }
-
-    private int getBadgeResIdForUser(int userHandle) {
-        // Return the framework-provided badge.
-        UserInfo userInfo = getUserIfProfile(userHandle);
-        if (userInfo != null && userInfo.isManagedProfile()) {
-            return com.android.internal.R.drawable.ic_corp_icon_badge;
-        }
-        return 0;
-    }
-
-    /**
-     * @return UserInfo for userHandle if it exists and is a profile of the current
-     *         user or null.
-     */
-    private UserInfo getUserIfProfile(int userHandle) {
-        List<UserInfo> userProfiles = getProfiles(getUserHandle());
-        for (UserInfo user : userProfiles) {
-            if (user.id == userHandle) {
-                return user;
-            }
-        }
-        return null;
-    }
-
-    private Drawable getBadgedDrawable(Drawable badgedDrawable, Drawable badgeDrawable,
-            Rect badgeLocation, boolean tryBadgeInPlace) {
-        final int badgedWidth = badgedDrawable.getIntrinsicWidth();
-        final int badgedHeight = badgedDrawable.getIntrinsicHeight();
-        final boolean canBadgeInPlace = tryBadgeInPlace
-                && (badgedDrawable instanceof BitmapDrawable)
-                && ((BitmapDrawable) badgedDrawable).getBitmap().isMutable();
-
-        final Bitmap bitmap;
-        if (canBadgeInPlace) {
-            bitmap = ((BitmapDrawable) badgedDrawable).getBitmap();
-        } else {
-            bitmap = Bitmap.createBitmap(badgedWidth, badgedHeight, Config.ARGB_8888);
-        }
-        Canvas canvas = new Canvas(bitmap);
-
-        if (!canBadgeInPlace) {
-            badgedDrawable.setBounds(0, 0, badgedWidth, badgedHeight);
-            badgedDrawable.draw(canvas);
-        }
-
-        if (badgeLocation != null) {
-            if (badgeLocation.left < 0 || badgeLocation.top < 0
-                    || badgeLocation.right > badgedWidth || badgeLocation.bottom > badgedHeight) {
-                throw new IllegalArgumentException("Badge location " + badgeLocation
-                        + " not in badged drawable bounds "
-                        + new Rect(0, 0, badgedWidth, badgedHeight));
-            }
-            badgeDrawable.setBounds(0, 0, badgeLocation.width(), badgeLocation.height());
-
-            canvas.save();
-            canvas.translate(badgeLocation.left, badgeLocation.top);
-            badgeDrawable.draw(canvas);
-            canvas.restore();
-        } else {
-            badgeDrawable.setBounds(0, 0, badgedWidth, badgedHeight);
-            badgeDrawable.draw(canvas);
-        }
-
-        if (!canBadgeInPlace) {
-            BitmapDrawable mergedDrawable = new BitmapDrawable(mContext.getResources(), bitmap);
-
-            if (badgedDrawable instanceof BitmapDrawable) {
-                BitmapDrawable bitmapDrawable = (BitmapDrawable) badgedDrawable;
-                mergedDrawable.setTargetDensity(bitmapDrawable.getBitmap().getDensity());
-            }
-
-            return mergedDrawable;
-        }
-
-        return badgedDrawable;
+        return mContext.getPackageManager().getUserBadgedLabel(label, user);
     }
 
     /**
@@ -1070,6 +1000,7 @@
      * Returns a file descriptor for the user's photo. PNG data can be read from this file.
      * @param userHandle the user whose photo we want to read.
      * @return a {@link Bitmap} of the user's photo, or null if there's no photo.
+     * @see com.android.internal.util.UserIcons#getDefaultUserIcon for a default.
      * @hide
      */
     public Bitmap getUserIcon(int userHandle) {
diff --git a/core/java/android/os/storage/IMountService.java b/core/java/android/os/storage/IMountService.java
index 939cda9..cf407f4 100644
--- a/core/java/android/os/storage/IMountService.java
+++ b/core/java/android/os/storage/IMountService.java
@@ -321,7 +321,7 @@
              * Mount a secure container with the specified key and owner UID.
              * Returns an int consistent with MountServiceResultCode
              */
-            public int mountSecureContainer(String id, String key, int ownerUid)
+            public int mountSecureContainer(String id, String key, int ownerUid, boolean readOnly)
                     throws RemoteException {
                 Parcel _data = Parcel.obtain();
                 Parcel _reply = Parcel.obtain();
@@ -331,6 +331,7 @@
                     _data.writeString(id);
                     _data.writeString(key);
                     _data.writeInt(ownerUid);
+                    _data.writeInt(readOnly ? 1 : 0);
                     mRemote.transact(Stub.TRANSACTION_mountSecureContainer, _data, _reply, 0);
                     _reply.readException();
                     _result = _reply.readInt();
@@ -834,6 +835,27 @@
                 }
                 return _result;
             }
+
+            @Override
+            public int resizeSecureContainer(String id, int sizeMb, String key)
+                    throws RemoteException {
+                Parcel _data = Parcel.obtain();
+                Parcel _reply = Parcel.obtain();
+                int _result;
+                try {
+                    _data.writeInterfaceToken(DESCRIPTOR);
+                    _data.writeString(id);
+                    _data.writeInt(sizeMb);
+                    _data.writeString(key);
+                    mRemote.transact(Stub.TRANSACTION_resizeSecureContainer, _data, _reply, 0);
+                    _reply.readException();
+                    _result = _reply.readInt();
+                } finally {
+                    _reply.recycle();
+                    _data.recycle();
+                }
+                return _result;
+            }
         }
 
         private static final String DESCRIPTOR = "IMountService";
@@ -918,6 +940,8 @@
 
         static final int TRANSACTION_getField = IBinder.FIRST_CALL_TRANSACTION + 39;
 
+        static final int TRANSACTION_resizeSecureContainer = IBinder.FIRST_CALL_TRANSACTION + 40;
+
         /**
          * Cast an IBinder object into an IMountService interface, generating a
          * proxy if needed.
@@ -1082,7 +1106,9 @@
                     key = data.readString();
                     int ownerUid;
                     ownerUid = data.readInt();
-                    int resultCode = mountSecureContainer(id, key, ownerUid);
+                    boolean readOnly;
+                    readOnly = data.readInt() != 0;
+                    int resultCode = mountSecureContainer(id, key, ownerUid, readOnly);
                     reply.writeNoException();
                     reply.writeInt(resultCode);
                     return true;
@@ -1308,6 +1334,19 @@
                     reply.writeString(contents);
                     return true;
                 }
+                case TRANSACTION_resizeSecureContainer: {
+                    data.enforceInterface(DESCRIPTOR);
+                    String id;
+                    id = data.readString();
+                    int sizeMb;
+                    sizeMb = data.readInt();
+                    String key;
+                    key = data.readString();
+                    int resultCode = resizeSecureContainer(id, sizeMb, key);
+                    reply.writeNoException();
+                    reply.writeInt(resultCode);
+                    return true;
+                }
             }
             return super.onTransact(code, data, reply, flags);
         }
@@ -1405,7 +1444,8 @@
      * Mount a secure container with the specified key and owner UID. Returns an
      * int consistent with MountServiceResultCode
      */
-    public int mountSecureContainer(String id, String key, int ownerUid) throws RemoteException;
+    public int mountSecureContainer(String id, String key, int ownerUid, boolean readOnly)
+            throws RemoteException;
 
     /**
      * Mount external storage at given mount point. Returns an int consistent
@@ -1478,10 +1518,14 @@
     static final int ENCRYPTION_STATE_NONE = 1;
     /** The volume has been encrypted succesfully. */
     static final int ENCRYPTION_STATE_OK = 0;
-    /** The volume is in a bad state. */
+    /** The volume is in a bad state.*/
     static final int ENCRYPTION_STATE_ERROR_UNKNOWN = -1;
-    /** The volume is in a bad state - partially encrypted. Data is likely irrecoverable. */
+    /** Encryption is incomplete */
     static final int ENCRYPTION_STATE_ERROR_INCOMPLETE = -2;
+    /** Encryption is incomplete and irrecoverable */
+    static final int ENCRYPTION_STATE_ERROR_INCONSISTENT = -3;
+    /** Underlying data is corrupt */
+    static final int ENCRYPTION_STATE_ERROR_CORRUPT = -4;
 
     /**
      * Determines the encryption state of the volume.
@@ -1571,4 +1615,6 @@
      * @return contents of field
      */
     public String getField(String field) throws RemoteException;
+
+    public int resizeSecureContainer(String id, int sizeMb, String key) throws RemoteException;
 }
diff --git a/core/java/android/os/storage/StorageManager.java b/core/java/android/os/storage/StorageManager.java
index 68b91cb..4cdafe1 100644
--- a/core/java/android/os/storage/StorageManager.java
+++ b/core/java/android/os/storage/StorageManager.java
@@ -619,6 +619,16 @@
     private static final long DEFAULT_FULL_THRESHOLD_BYTES = MB_IN_BYTES;
 
     /**
+     * Return the number of available bytes until the given path is considered
+     * running low on storage.
+     *
+     * @hide
+     */
+    public long getStorageBytesUntilLow(File path) {
+        return path.getUsableSpace() - getStorageFullBytes(path);
+    }
+
+    /**
      * Return the number of available bytes at which the given path is
      * considered running low on storage.
      *
diff --git a/core/java/android/preference/CheckBoxPreference.java b/core/java/android/preference/CheckBoxPreference.java
index 1ce98b8..fee3f0f1 100644
--- a/core/java/android/preference/CheckBoxPreference.java
+++ b/core/java/android/preference/CheckBoxPreference.java
@@ -66,7 +66,6 @@
         View checkboxView = view.findViewById(com.android.internal.R.id.checkbox);
         if (checkboxView != null && checkboxView instanceof Checkable) {
             ((Checkable) checkboxView).setChecked(mChecked);
-            sendAccessibilityEvent(checkboxView);
         }
 
         syncSummaryView(view);
diff --git a/core/java/android/preference/SwitchPreference.java b/core/java/android/preference/SwitchPreference.java
index 46be928..53b5aad 100644
--- a/core/java/android/preference/SwitchPreference.java
+++ b/core/java/android/preference/SwitchPreference.java
@@ -130,8 +130,6 @@
 
             ((Checkable) checkableView).setChecked(mChecked);
 
-            sendAccessibilityEvent(checkableView);
-
             if (checkableView instanceof Switch) {
                 final Switch switchView = (Switch) checkableView;
                 switchView.setTextOn(mSwitchOn);
diff --git a/core/java/android/preference/TwoStatePreference.java b/core/java/android/preference/TwoStatePreference.java
index 6f8be1f..3823b27 100644
--- a/core/java/android/preference/TwoStatePreference.java
+++ b/core/java/android/preference/TwoStatePreference.java
@@ -24,8 +24,6 @@
 import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.view.View;
-import android.view.accessibility.AccessibilityEvent;
-import android.view.accessibility.AccessibilityManager;
 import android.widget.TextView;
 
 /**
@@ -39,7 +37,6 @@
     private CharSequence mSummaryOff;
     boolean mChecked;
     private boolean mCheckedSet;
-    private boolean mSendClickAccessibilityEvent;
     private boolean mDisableDependentsState;
 
     public TwoStatePreference(
@@ -63,15 +60,10 @@
     protected void onClick() {
         super.onClick();
 
-        boolean newValue = !isChecked();
-
-        mSendClickAccessibilityEvent = true;
-
-        if (!callChangeListener(newValue)) {
-            return;
+        final boolean newValue = !isChecked();
+        if (callChangeListener(newValue)) {
+            setChecked(newValue);
         }
-
-        setChecked(newValue);
     }
 
     /**
@@ -196,21 +188,6 @@
                 : (Boolean) defaultValue);
     }
 
-    void sendAccessibilityEvent(View view) {
-        // Since the view is still not attached we create, populate,
-        // and send the event directly since we do not know when it
-        // will be attached and posting commands is not as clean.
-        AccessibilityManager accessibilityManager = AccessibilityManager.getInstance(getContext());
-        if (mSendClickAccessibilityEvent && accessibilityManager.isEnabled()) {
-            AccessibilityEvent event = AccessibilityEvent.obtain();
-            event.setEventType(AccessibilityEvent.TYPE_VIEW_CLICKED);
-            view.onInitializeAccessibilityEvent(event);
-            view.dispatchPopulateAccessibilityEvent(event);
-            accessibilityManager.sendAccessibilityEvent(event);
-        }
-        mSendClickAccessibilityEvent = false;
-    }
-
     /**
      * Sync a summary view contained within view's subhierarchy with the correct summary text.
      * @param view View where a summary should be located
diff --git a/core/java/android/print/PrintManager.java b/core/java/android/print/PrintManager.java
index 9361286..bf8ac65 100644
--- a/core/java/android/print/PrintManager.java
+++ b/core/java/android/print/PrintManager.java
@@ -535,7 +535,7 @@
                 destroyed = isDestroyedLocked();
             }
 
-            if (destroyed) {
+            if (destroyed && observer != null) {
                 try {
                     observer.onDestroy();
                 } catch (RemoteException re) {
diff --git a/core/java/android/provider/CallLog.java b/core/java/android/provider/CallLog.java
index 8db99a5..c8d0fd5 100644
--- a/core/java/android/provider/CallLog.java
+++ b/core/java/android/provider/CallLog.java
@@ -24,13 +24,17 @@
 import android.content.Intent;
 import android.content.pm.UserInfo;
 import android.database.Cursor;
+import android.location.Country;
+import android.location.CountryDetector;
 import android.net.Uri;
 import android.os.UserHandle;
 import android.os.UserManager;
 import android.provider.ContactsContract.CommonDataKinds.Callable;
 import android.provider.ContactsContract.CommonDataKinds.Phone;
+import android.provider.ContactsContract.Data;
 import android.provider.ContactsContract.DataUsageFeedback;
-import android.telecomm.PhoneAccountHandle;
+import android.telecom.PhoneAccountHandle;
+import android.telephony.PhoneNumberUtils;
 import android.text.TextUtils;
 
 import com.android.internal.telephony.CallerInfo;
@@ -112,7 +116,8 @@
          * </pre>
          * </p>
          */
-        public static final String EXTRA_CALL_TYPE_FILTER = "extra_call_type_filter";
+        public static final String EXTRA_CALL_TYPE_FILTER =
+                "android.provider.extra.CALL_TYPE_FILTER";
 
         /**
          * Content uri used to access call log entries, including voicemail records. You must have
@@ -162,8 +167,6 @@
          */
         public static final String FEATURES = "features";
 
-        /** Call had no associated features (e.g. voice-only). */
-        public static final int FEATURES_NONE = 0x0;
         /** Call had video. */
         public static final int FEATURES_VIDEO = 0x1;
 
@@ -345,6 +348,22 @@
         public static final String PHONE_ACCOUNT_ID = "subscription_id";
 
         /**
+         * The identifier of a account that is unique to a specified component. Equivalent value
+         * to {@link #PHONE_ACCOUNT_ID}. For ContactsProvider internal use only.
+         * <P>Type: INTEGER</P>
+         *
+         * @hide
+         */
+        public static final String SUB_ID = "sub_id";
+
+        /**
+         * If a successful call is made that is longer than this duration, update the phone number
+         * in the ContactsProvider with the normalized version of the number, based on the user's
+         * current country code.
+         */
+        private static final int MIN_DURATION_FOR_NORMALIZED_NUMBER_UPDATE_MS = 1000 * 10;
+
+        /**
          * Adds a call to the call log.
          *
          * @param ci the CallerInfo object to get the target contact from.  Can be null
@@ -484,12 +503,13 @@
                 if (cursor != null) {
                     try {
                         if (cursor.getCount() > 0 && cursor.moveToFirst()) {
-                            final Uri feedbackUri = DataUsageFeedback.FEEDBACK_URI.buildUpon()
-                                    .appendPath(cursor.getString(0))
-                                    .appendQueryParameter(DataUsageFeedback.USAGE_TYPE,
-                                                DataUsageFeedback.USAGE_TYPE_CALL)
-                                    .build();
-                            resolver.update(feedbackUri, new ContentValues(), null, null);
+                            final String dataId = cursor.getString(0);
+                            updateDataUsageStatForData(resolver, dataId);
+                            if (duration >= MIN_DURATION_FOR_NORMALIZED_NUMBER_UPDATE_MS
+                                    && callType == Calls.OUTGOING_TYPE
+                                    && TextUtils.isEmpty(ci.normalizedNumber)) {
+                                updateNormalizedNumber(context, resolver, dataId, number);
+                            }
                         }
                     } finally {
                         cursor.close();
@@ -562,5 +582,53 @@
                     + " LIMIT -1 OFFSET 500)", null);
             return result;
         }
+
+        private static void updateDataUsageStatForData(ContentResolver resolver, String dataId) {
+            final Uri feedbackUri = DataUsageFeedback.FEEDBACK_URI.buildUpon()
+                    .appendPath(dataId)
+                    .appendQueryParameter(DataUsageFeedback.USAGE_TYPE,
+                                DataUsageFeedback.USAGE_TYPE_CALL)
+                    .build();
+            resolver.update(feedbackUri, new ContentValues(), null, null);
+        }
+
+        /**
+         * Update the normalized phone number for the given dataId in the ContactsProvider, based
+         * on the user's current country.
+         */
+        private static void updateNormalizedNumber(Context context, ContentResolver resolver,
+                String dataId, String number) {
+            if (TextUtils.isEmpty(number) || TextUtils.isEmpty(dataId)) {
+                return;
+            }
+
+            final String countryIso = getCurrentCountryIso(context);
+            if (TextUtils.isEmpty(countryIso)) {
+                return;
+            }
+
+            final String normalizedNumber = PhoneNumberUtils.formatNumberToE164(number,
+                    getCurrentCountryIso(context));
+            if (TextUtils.isEmpty(normalizedNumber)) {
+                return;
+            }
+
+            final ContentValues values = new ContentValues();
+            values.put(Phone.NORMALIZED_NUMBER, normalizedNumber);
+            resolver.update(Data.CONTENT_URI, values, Data._ID + "=?", new String[] {dataId});
+        }
+
+        private static String getCurrentCountryIso(Context context) {
+            String countryIso = null;
+            final CountryDetector detector = (CountryDetector) context.getSystemService(
+                    Context.COUNTRY_DETECTOR);
+            if (detector != null) {
+                final Country country = detector.detectCountry();
+                if (country != null) {
+                    countryIso = country.getCountryIso();
+                }
+            }
+            return countryIso;
+        }
     }
 }
diff --git a/core/java/android/provider/ContactsContract.java b/core/java/android/provider/ContactsContract.java
index 4f35b16..18a9eb1 100644
--- a/core/java/android/provider/ContactsContract.java
+++ b/core/java/android/provider/ContactsContract.java
@@ -36,7 +36,6 @@
 import android.database.DatabaseUtils;
 import android.graphics.Rect;
 import android.net.Uri;
-import android.net.Uri.Builder;
 import android.os.RemoteException;
 import android.text.TextUtils;
 import android.util.DisplayMetrics;
@@ -1126,7 +1125,7 @@
          * import android.provider.ContactsContract.Contacts;
          *
          * Uri uri = Contacts.CONTENT_URI.buildUpon()
-         *          .appendQueryParameter(Contacts.ADDRESS_BOOK_INDEX_EXTRAS, "true")
+         *          .appendQueryParameter(Contacts.EXTRA_ADDRESS_BOOK_INDEX, "true")
          *          .build();
          * Cursor cursor = getContentResolver().query(uri,
          *          new String[] {Contacts.DISPLAY_NAME},
@@ -1141,21 +1140,24 @@
          * </pre>
          * </p>
          */
-        public static final String ADDRESS_BOOK_INDEX_EXTRAS = "address_book_index_extras";
+        public static final String EXTRA_ADDRESS_BOOK_INDEX =
+                "android.provider.extra.ADDRESS_BOOK_INDEX";
 
         /**
          * The array of address book index titles, which are returned in the
          * same order as the data in the cursor.
          * <p>TYPE: String[]</p>
          */
-        public static final String EXTRA_ADDRESS_BOOK_INDEX_TITLES = "address_book_index_titles";
+        public static final String EXTRA_ADDRESS_BOOK_INDEX_TITLES =
+                "android.provider.extra.ADDRESS_BOOK_INDEX_TITLES";
 
         /**
          * The array of group counts for the corresponding group.  Contains the same number
          * of elements as the EXTRA_ADDRESS_BOOK_INDEX_TITLES array.
          * <p>TYPE: int[]</p>
          */
-        public static final String EXTRA_ADDRESS_BOOK_INDEX_COUNTS = "address_book_index_counts";
+        public static final String EXTRA_ADDRESS_BOOK_INDEX_COUNTS =
+                "android.provider.extra.ADDRESS_BOOK_INDEX_COUNTS";
     }
 
     /**
@@ -1622,15 +1624,15 @@
          *
          * @hide
          */
-        public static long CORP_CONTACT_ID_BASE = 1000000000; // slightly smaller than 2 ** 30
+        public static long ENTERPRISE_CONTACT_ID_BASE = 1000000000; // slightly smaller than 2 ** 30
 
         /**
-         * Return TRUE if a contact ID is from the contacts provider on the corp profile.
+         * Return TRUE if a contact ID is from the contacts provider on the enterprise profile.
          *
          * {@link PhoneLookup#ENTERPRISE_CONTENT_FILTER_URI} may return such a contact.
          */
-        public static boolean isCorpContactId(long contactId) {
-            return (contactId >= CORP_CONTACT_ID_BASE) && (contactId < Profile.MIN_ID);
+        public static boolean isEnterpriseContactId(long contactId) {
+            return (contactId >= ENTERPRISE_CONTACT_ID_BASE) && (contactId < Profile.MIN_ID);
         }
 
         /**
@@ -2229,6 +2231,11 @@
          * type.  For applications that need to be aware of the data set, this can
          * be used instead of account type to distinguish sets of data.  This is
          * never intended to be used for specifying accounts.
+         * <p>
+         * This column does *not* escape forward slashes in the account type or the data set.
+         * If this is an issue, consider using
+         * {@link ContactsContract.RawContacts#ACCOUNT_TYPE} and
+         * {@link ContactsContract.RawContacts#DATA_SET} directly.
          */
         public static final String ACCOUNT_TYPE_AND_DATA_SET = "account_type_and_data_set";
 
@@ -2272,6 +2279,8 @@
          * The default value is "0"
          * </p>
          * <p>Type: INTEGER</p>
+         *
+         * @hide
          */
         public static final String NAME_VERIFIED = "name_verified";
 
@@ -5023,7 +5032,8 @@
          *     </li>
          *     <li>
          *     Corp contacts will get artificial {@link #_ID}s.  In order to tell whether a contact
-         *     is from the corp profile, use {@link ContactsContract.Contacts#isCorpContactId(long)}.
+         *     is from the corp profile, use
+         *     {@link ContactsContract.Contacts#isEnterpriseContactId(long)}.
          *     </li>
          * </ul>
          * <p>
@@ -8066,6 +8076,21 @@
         }
 
         /**
+         * Pins a contact at a provided position, or unpins a contact.
+         *
+         * @param contentResolver to perform the pinning operation on.
+         * @param pinnedPosition the position to pin the contact at. To unpin a contact, use
+         *         {@link PinnedPositions#UNPINNED}.
+         */
+        public static void pin(
+                ContentResolver contentResolver, long contactId, int pinnedPosition) {
+            final Uri uri = Uri.withAppendedPath(Contacts.CONTENT_URI, String.valueOf(contactId));
+            final ContentValues values = new ContentValues();
+            values.put(Contacts.PINNED, pinnedPosition);
+            contentResolver.update(uri, values, null, null);
+        }
+
+        /**
          * Default value for the pinned position of an unpinned contact.
          */
         public static final int UNPINNED = 0;
@@ -8089,7 +8114,7 @@
          * for the provided {@link Contacts} entry.
          */
         public static final String ACTION_QUICK_CONTACT =
-                "com.android.contacts.action.QUICK_CONTACT";
+                "android.provider.action.QUICK_CONTACT";
 
         /**
          * Extra used to specify pivot dialog location in screen coordinates.
@@ -8097,19 +8122,19 @@
          * @hide
          */
         @Deprecated
-        public static final String EXTRA_TARGET_RECT = "target_rect";
+        public static final String EXTRA_TARGET_RECT = "android.provider.extra.TARGET_RECT";
 
         /**
          * Extra used to specify size of pivot dialog.
          * @hide
          */
-        public static final String EXTRA_MODE = "mode";
+        public static final String EXTRA_MODE = "android.provider.extra.MODE";
 
         /**
          * Extra used to indicate a list of specific MIME-types to exclude and not display in the
          * QuickContacts dialog. Stored as a {@link String} array.
          */
-        public static final String EXTRA_EXCLUDE_MIMES = "exclude_mimes";
+        public static final String EXTRA_EXCLUDE_MIMES = "android.provider.extra.EXCLUDE_MIMES";
 
         /**
          * Small QuickContact mode, usually presented with minimal actions.
diff --git a/core/java/android/provider/DocumentsContract.java b/core/java/android/provider/DocumentsContract.java
index 327fe4a..9a0858a 100644
--- a/core/java/android/provider/DocumentsContract.java
+++ b/core/java/android/provider/DocumentsContract.java
@@ -511,8 +511,6 @@
     public static final String METHOD_DELETE_DOCUMENT = "android:deleteDocument";
 
     /** {@hide} */
-    public static final String EXTRA_THUMBNAIL_SIZE = "thumbnail_size";
-    /** {@hide} */
     public static final String EXTRA_URI = "uri";
 
     private static final String PATH_ROOT = "root";
@@ -819,7 +817,7 @@
             ContentProviderClient client, Uri documentUri, Point size, CancellationSignal signal)
             throws RemoteException, IOException {
         final Bundle openOpts = new Bundle();
-        openOpts.putParcelable(DocumentsContract.EXTRA_THUMBNAIL_SIZE, size);
+        openOpts.putParcelable(ContentResolver.EXTRA_SIZE, size);
 
         AssetFileDescriptor afd = null;
         Bitmap bitmap = null;
diff --git a/core/java/android/provider/DocumentsProvider.java b/core/java/android/provider/DocumentsProvider.java
index 021fff4..270d786 100644
--- a/core/java/android/provider/DocumentsProvider.java
+++ b/core/java/android/provider/DocumentsProvider.java
@@ -16,7 +16,6 @@
 
 package android.provider;
 
-import static android.provider.DocumentsContract.EXTRA_THUMBNAIL_SIZE;
 import static android.provider.DocumentsContract.METHOD_CREATE_DOCUMENT;
 import static android.provider.DocumentsContract.METHOD_DELETE_DOCUMENT;
 import static android.provider.DocumentsContract.METHOD_RENAME_DOCUMENT;
@@ -763,8 +762,8 @@
     public final AssetFileDescriptor openTypedAssetFile(Uri uri, String mimeTypeFilter, Bundle opts)
             throws FileNotFoundException {
         enforceTree(uri);
-        if (opts != null && opts.containsKey(EXTRA_THUMBNAIL_SIZE)) {
-            final Point sizeHint = opts.getParcelable(EXTRA_THUMBNAIL_SIZE);
+        if (opts != null && opts.containsKey(ContentResolver.EXTRA_SIZE)) {
+            final Point sizeHint = opts.getParcelable(ContentResolver.EXTRA_SIZE);
             return openDocumentThumbnail(getDocumentId(uri), sizeHint, null);
         } else {
             return super.openTypedAssetFile(uri, mimeTypeFilter, opts);
@@ -781,8 +780,8 @@
             Uri uri, String mimeTypeFilter, Bundle opts, CancellationSignal signal)
             throws FileNotFoundException {
         enforceTree(uri);
-        if (opts != null && opts.containsKey(EXTRA_THUMBNAIL_SIZE)) {
-            final Point sizeHint = opts.getParcelable(EXTRA_THUMBNAIL_SIZE);
+        if (opts != null && opts.containsKey(ContentResolver.EXTRA_SIZE)) {
+            final Point sizeHint = opts.getParcelable(ContentResolver.EXTRA_SIZE);
             return openDocumentThumbnail(getDocumentId(uri), sizeHint, signal);
         } else {
             return super.openTypedAssetFile(uri, mimeTypeFilter, opts, signal);
diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java
index 9e0e618..440b1ec 100644
--- a/core/java/android/provider/Settings.java
+++ b/core/java/android/provider/Settings.java
@@ -18,6 +18,7 @@
 
 import android.annotation.SdkConstant;
 import android.annotation.SdkConstant.SdkConstantType;
+import android.annotation.SystemApi;
 import android.app.SearchManager;
 import android.app.WallpaperManager;
 import android.content.ComponentName;
@@ -131,6 +132,7 @@
             "android.settings.AIRPLANE_MODE_SETTINGS";
 
     /**
+     * @hide
      * Activity Action: Modify Airplane mode settings using the users voice.
      * <p>
      * In some cases, a matching Activity may not exist, so ensure you safeguard against this.
@@ -152,6 +154,7 @@
      * Output: Nothing.
      */
     @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+    @SystemApi
     public static final String ACTION_VOICE_CONTROL_AIRPLANE_MODE =
             "android.settings.VOICE_CONTROL_AIRPLANE_MODE";
 
@@ -305,7 +308,7 @@
 
     /**
      * Activity Action: Show settings to allow configuration of
-     * {@link android.media.routing.MediaRouteService media route providers}.
+     * cast endpoints.
      * <p>
      * In some cases, a matching Activity may not exist, so ensure you
      * safeguard against this.
@@ -904,6 +907,15 @@
     public static final String ACTION_APP_NOTIFICATION_SETTINGS
             = "android.settings.APP_NOTIFICATION_SETTINGS";
 
+    /**
+     * Activity Action: Show notification redaction settings.
+     *
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
+    public static final String ACTION_APP_NOTIFICATION_REDACTION
+            = "android.settings.ACTION_APP_NOTIFICATION_REDACTION";
+
     /** @hide */ public static final String EXTRA_APP_UID = "app_uid";
     /** @hide */ public static final String EXTRA_APP_PACKAGE = "app_package";
 
@@ -966,11 +978,13 @@
     public static final String EXTRA_INPUT_METHOD_ID = "input_method_id";
 
     /**
+     * @hide
      * Activity Extra: Enable or disable Airplane Mode.
      * <p>
      * This can be passed as an extra field to the {@link #ACTION_VOICE_CONTROL_AIRPLANE_MODE}
      * intent as a boolean.
      */
+    @SystemApi
     public static final String EXTRA_AIRPLANE_MODE_ENABLED = "airplane_mode_enabled";
 
     private static final String JID_RESOURCE_PREFIX = "android";
@@ -2113,6 +2127,13 @@
         public static final String VOLUME_MASTER_MUTE = "volume_master_mute";
 
         /**
+         * Microphone mute (int 1 = mute, 0 = not muted).
+         *
+         * @hide
+         */
+        public static final String MICROPHONE_MUTE = "microphone_mute";
+
+        /**
          * Whether the notifications should use the ring volume (value of 1) or
          * a separate notification volume (value of 0). In most cases, users
          * will have this enabled so the notification and ringer volumes will be
@@ -2545,7 +2566,6 @@
          * Call Preference String.
          * "SIP_ALWAYS" : Always use SIP with network access
          * "SIP_ADDRESS_ONLY" : Only if destination is a SIP address
-         * "SIP_ASK_ME_EACH_TIME" : Always ask me each time
          * @hide
          */
         public static final String SIP_CALL_OPTIONS = "sip_call_options";
@@ -2563,9 +2583,13 @@
         public static final String SIP_ADDRESS_ONLY = "SIP_ADDRESS_ONLY";
 
         /**
-         * One of the sip call options: Always ask me each time.
+         * @deprecated Use SIP_ALWAYS or SIP_ADDRESS_ONLY instead.  Formerly used to indicate that
+         * the user should be prompted each time a call is made whether it should be placed using
+         * SIP.  The {@link com.android.providers.settings.DatabaseHelper} replaces this with
+         * SIP_ADDRESS_ONLY.
          * @hide
          */
+        @Deprecated
         public static final String SIP_ASK_ME_EACH_TIME = "SIP_ASK_ME_EACH_TIME";
 
         /**
@@ -2674,6 +2698,9 @@
          */
         public static final String[] CLONE_TO_MANAGED_PROFILE = {
             DATE_FORMAT,
+            HAPTIC_FEEDBACK_ENABLED,
+            SOUND_EFFECTS_ENABLED,
+            TEXT_SHOW_PASSWORD,
             TIME_12_24
         };
 
@@ -3123,6 +3150,11 @@
         /** @hide */
         public static boolean putStringForUser(ContentResolver resolver, String name, String value,
                 int userHandle) {
+            if (LOCATION_MODE.equals(name)) {
+                // HACK ALERT: temporary hack to work around b/10491283.
+                // TODO: once b/10491283 fixed, remove this hack
+                return setLocationModeForUser(resolver, Integer.parseInt(value), userHandle);
+            }
             if (MOVED_TO_GLOBAL.contains(name)) {
                 Log.w(TAG, "Setting " + name + " has moved from android.provider.Settings.System"
                         + " to android.provider.Settings.Global");
@@ -3238,11 +3270,6 @@
         /** @hide */
         public static boolean putIntForUser(ContentResolver cr, String name, int value,
                 int userHandle) {
-            if (LOCATION_MODE.equals(name)) {
-                // HACK ALERT: temporary hack to work around b/10491283.
-                // TODO: once b/10491283 fixed, remove this hack
-                return setLocationModeForUser(cr, value, userHandle);
-            }
             return putStringForUser(cr, name, Integer.toString(value), userHandle);
         }
 
@@ -3546,6 +3573,13 @@
         public static final String DISABLED_SYSTEM_INPUT_METHODS = "disabled_system_input_methods";
 
         /**
+         * Whether to show the IME when a hard keyboard is connected. This is a boolean that
+         * determines if the IME should be shown when a hard keyboard is attached.
+         * @hide
+         */
+        public static final String SHOW_IME_WITH_HARD_KEYBOARD = "show_ime_with_hard_keyboard";
+
+        /**
          * Host name and port for global http proxy. Uses ':' seperator for
          * between host and port.
          *
@@ -3697,6 +3731,21 @@
                 "lock_screen_allow_private_notifications";
 
         /**
+         * Set by the system to track if the user needs to see the call to action for
+         * the lockscreen notification policy.
+         * @hide
+         */
+        public static final String SHOW_NOTE_ABOUT_NOTIFICATION_HIDING =
+                "show_note_about_notification_hiding";
+
+        /**
+         * Set to 1 by the system after trust agents have been initialized.
+         * @hide
+         */
+        public static final String TRUST_AGENTS_INITIALIZED =
+                "trust_agents_initialized";
+
+        /**
          * The Logging ID (a unique 64-bit value) as a hex string.
          * Used as a pseudonymous identifier for logging.
          * @deprecated This identifier is poorly initialized and has
@@ -4730,17 +4779,16 @@
 
         /**
          * List of TV inputs that are currently hidden. This is a string
-         * containing the IDs of all hidden TV inputs. Each ID is separated by ':'.
-         *
+         * containing the IDs of all hidden TV inputs. Each ID is encoded by
+         * {@link android.net.Uri#encode(String)} and separated by ':'.
          * @hide
          */
         public static final String TV_INPUT_HIDDEN_INPUTS = "tv_input_hidden_inputs";
 
         /**
          * List of custom TV input labels. This is a string containing <TV input id, custom name>
-         * pairs. Each pair is separated by ':' and TV input id and custom name are separated by
-         * ','.
-         *
+         * pairs. TV input id and custom name are encoded by {@link android.net.Uri#encode(String)}
+         * and separated by ','. Each pair is separated by ':'.
          * @hide
          */
         public static final String TV_INPUT_CUSTOM_LABELS = "tv_input_custom_labels";
@@ -6311,8 +6359,7 @@
          * processes as soon as they are no longer needed.  If 0, the normal
          * extended lifetime is used.
          */
-        public static final String ALWAYS_FINISH_ACTIVITIES =
-                "always_finish_activities";
+        public static final String ALWAYS_FINISH_ACTIVITIES = "always_finish_activities";
 
         /**
          * Use Dock audio output for media:
diff --git a/core/java/android/security/IKeystoreService.java b/core/java/android/security/IKeystoreService.java
index f8bf45b..7e9aba0 100644
--- a/core/java/android/security/IKeystoreService.java
+++ b/core/java/android/security/IKeystoreService.java
@@ -478,6 +478,59 @@
                 }
                 return _result;
             }
+
+            public int reset_uid(int uid) throws RemoteException {
+                Parcel _data = Parcel.obtain();
+                Parcel _reply = Parcel.obtain();
+                int _result;
+                try {
+                    _data.writeInterfaceToken(DESCRIPTOR);
+                    _data.writeInt(uid);
+                    mRemote.transact(Stub.TRANSACTION_reset_uid, _data, _reply, 0);
+                    _reply.readException();
+                    _result = _reply.readInt();
+                } finally {
+                    _reply.recycle();
+                    _data.recycle();
+                }
+                return _result;
+            }
+
+            public int sync_uid(int srcUid, int dstUid) throws RemoteException {
+                Parcel _data = Parcel.obtain();
+                Parcel _reply = Parcel.obtain();
+                int _result;
+                try {
+                    _data.writeInterfaceToken(DESCRIPTOR);
+                    _data.writeInt(srcUid);
+                    _data.writeInt(dstUid);
+                    mRemote.transact(Stub.TRANSACTION_sync_uid, _data, _reply, 0);
+                    _reply.readException();
+                    _result = _reply.readInt();
+                } finally {
+                    _reply.recycle();
+                    _data.recycle();
+                }
+                return _result;
+            }
+
+            public int password_uid(String password, int uid) throws RemoteException {
+                Parcel _data = Parcel.obtain();
+                Parcel _reply = Parcel.obtain();
+                int _result;
+                try {
+                    _data.writeInterfaceToken(DESCRIPTOR);
+                    _data.writeString(password);
+                    _data.writeInt(uid);
+                    mRemote.transact(Stub.TRANSACTION_password_uid, _data, _reply, 0);
+                    _reply.readException();
+                    _result = _reply.readInt();
+                } finally {
+                    _reply.recycle();
+                    _data.recycle();
+                }
+                return _result;
+            }
         }
 
         private static final String DESCRIPTOR = "android.security.keystore";
@@ -505,6 +558,9 @@
         static final int TRANSACTION_duplicate = IBinder.FIRST_CALL_TRANSACTION + 20;
         static final int TRANSACTION_is_hardware_backed = IBinder.FIRST_CALL_TRANSACTION + 21;
         static final int TRANSACTION_clear_uid = IBinder.FIRST_CALL_TRANSACTION + 22;
+        static final int TRANSACTION_reset_uid = IBinder.FIRST_CALL_TRANSACTION + 23;
+        static final int TRANSACTION_sync_uid = IBinder.FIRST_CALL_TRANSACTION + 24;
+        static final int TRANSACTION_password_uid = IBinder.FIRST_CALL_TRANSACTION + 25;
 
         /**
          * Cast an IBinder object into an IKeystoreService interface, generating
@@ -597,4 +653,10 @@
     public int is_hardware_backed(String string) throws RemoteException;
 
     public int clear_uid(long uid) throws RemoteException;
+
+    public int reset_uid(int uid) throws RemoteException;
+
+    public int sync_uid(int sourceUid, int targetUid) throws RemoteException;
+
+    public int password_uid(String password, int uid) throws RemoteException;
 }
diff --git a/core/java/android/service/dreams/DreamService.java b/core/java/android/service/dreams/DreamService.java
index 7e04ae8..92647f0 100644
--- a/core/java/android/service/dreams/DreamService.java
+++ b/core/java/android/service/dreams/DreamService.java
@@ -29,7 +29,6 @@
 import android.os.IBinder;
 import android.os.PowerManager;
 import android.os.RemoteException;
-import android.os.RemoteException;
 import android.os.ServiceManager;
 import android.util.Slog;
 import android.view.ActionMode;
diff --git a/core/java/android/service/fingerprint/FingerprintManager.java b/core/java/android/service/fingerprint/FingerprintManager.java
index 5fd597b..178cc8b 100644
--- a/core/java/android/service/fingerprint/FingerprintManager.java
+++ b/core/java/android/service/fingerprint/FingerprintManager.java
@@ -33,6 +33,7 @@
 
 /**
  * A class that coordinates access to the fingerprint hardware.
+ * @hide
  */
 
 public class FingerprintManager {
diff --git a/core/java/android/service/fingerprint/FingerprintManagerReceiver.java b/core/java/android/service/fingerprint/FingerprintManagerReceiver.java
index e5193f5..85677ba 100644
--- a/core/java/android/service/fingerprint/FingerprintManagerReceiver.java
+++ b/core/java/android/service/fingerprint/FingerprintManagerReceiver.java
@@ -15,6 +15,9 @@
  * limitations under the License.
  */
 
+/**
+ * @hide
+ */
 public class FingerprintManagerReceiver {
     /**
      * Fingerprint enrollment progress update. Enrollment is considered complete if
diff --git a/core/java/android/service/fingerprint/FingerprintUtils.java b/core/java/android/service/fingerprint/FingerprintUtils.java
index f4b5526..a4caf8e 100644
--- a/core/java/android/service/fingerprint/FingerprintUtils.java
+++ b/core/java/android/service/fingerprint/FingerprintUtils.java
@@ -23,6 +23,10 @@
 
 import java.util.Arrays;
 
+/**
+ * Utility class for dealing with fingerprints and fingerprint settings.
+ * @hide
+ */
 public
 class FingerprintUtils {
     private static final boolean DEBUG = true;
diff --git a/core/java/android/service/notification/Condition.java b/core/java/android/service/notification/Condition.java
index aa724f0..3a91d1a 100644
--- a/core/java/android/service/notification/Condition.java
+++ b/core/java/android/service/notification/Condition.java
@@ -16,6 +16,7 @@
 
 package android.service.notification;
 
+import android.annotation.SystemApi;
 import android.content.Context;
 import android.net.Uri;
 import android.os.Parcel;
@@ -28,6 +29,7 @@
  *
  * @hide
  */
+@SystemApi
 public class Condition implements Parcelable {
 
     public static final String SCHEME = "condition";
diff --git a/core/java/android/service/notification/ConditionProviderService.java b/core/java/android/service/notification/ConditionProviderService.java
index 326412f..03ee726 100644
--- a/core/java/android/service/notification/ConditionProviderService.java
+++ b/core/java/android/service/notification/ConditionProviderService.java
@@ -17,6 +17,7 @@
 package android.service.notification;
 
 import android.annotation.SdkConstant;
+import android.annotation.SystemApi;
 import android.app.INotificationManager;
 import android.app.Service;
 import android.content.Context;
@@ -44,6 +45,7 @@
  *
  * @hide
  */
+@SystemApi
 public abstract class ConditionProviderService extends Service {
     private final String TAG = ConditionProviderService.class.getSimpleName()
             + "[" + getClass().getSimpleName() + "]";
diff --git a/core/java/android/service/notification/INotificationListener.aidl b/core/java/android/service/notification/INotificationListener.aidl
index 93b2d3b..e6bf6ba 100644
--- a/core/java/android/service/notification/INotificationListener.aidl
+++ b/core/java/android/service/notification/INotificationListener.aidl
@@ -16,6 +16,7 @@
 
 package android.service.notification;
 
+import android.service.notification.IStatusBarNotificationHolder;
 import android.service.notification.StatusBarNotification;
 import android.service.notification.NotificationRankingUpdate;
 
@@ -23,10 +24,11 @@
 oneway interface INotificationListener
 {
     void onListenerConnected(in NotificationRankingUpdate update);
-    void onNotificationPosted(in StatusBarNotification notification,
+    void onNotificationPosted(in IStatusBarNotificationHolder notificationHolder,
             in NotificationRankingUpdate update);
-    void onNotificationRemoved(in StatusBarNotification notification,
+    void onNotificationRemoved(in IStatusBarNotificationHolder notificationHolder,
             in NotificationRankingUpdate update);
     void onNotificationRankingUpdate(in NotificationRankingUpdate update);
     void onListenerHintsChanged(int hints);
-}
\ No newline at end of file
+    void onInterruptionFilterChanged(int interruptionFilter);
+}
diff --git a/core/java/android/service/notification/IStatusBarNotificationHolder.aidl b/core/java/android/service/notification/IStatusBarNotificationHolder.aidl
new file mode 100644
index 0000000..c25cdb2
--- /dev/null
+++ b/core/java/android/service/notification/IStatusBarNotificationHolder.aidl
@@ -0,0 +1,25 @@
+/**
+ * Copyright (c) 2014, 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 android.service.notification;
+
+import android.service.notification.StatusBarNotification;
+
+/** @hide */
+interface IStatusBarNotificationHolder {
+    /** Fetch the held StatusBarNotification. This method should only be called once per Holder */
+    StatusBarNotification get();
+}
diff --git a/core/java/android/service/notification/NotificationListenerService.java b/core/java/android/service/notification/NotificationListenerService.java
index 119f7f6..b22fd9c 100644
--- a/core/java/android/service/notification/NotificationListenerService.java
+++ b/core/java/android/service/notification/NotificationListenerService.java
@@ -26,6 +26,7 @@
 import android.content.Context;
 import android.content.Intent;
 import android.content.pm.ParceledListSlice;
+import android.os.Bundle;
 import android.os.IBinder;
 import android.os.Parcel;
 import android.os.Parcelable;
@@ -58,26 +59,56 @@
     private final String TAG = NotificationListenerService.class.getSimpleName()
             + "[" + getClass().getSimpleName() + "]";
 
-    /** {@link #getCurrentListenerHints() Listener hints} constant - default state. */
-    public static final int HINTS_NONE = 0;
+    /**
+     * {@link #getCurrentInterruptionFilter() Interruption filter} constant -
+     *     Normal interruption filter.
+     */
+    public static final int INTERRUPTION_FILTER_ALL = 1;
 
-    /** Bitmask range for {@link #getCurrentListenerHints() Listener hints} host interruption level
-     * constants.  */
-    public static final int HOST_INTERRUPTION_LEVEL_MASK = 0x3;
+    /**
+     * {@link #getCurrentInterruptionFilter() Interruption filter} constant -
+     *     Priority interruption filter.
+     */
+    public static final int INTERRUPTION_FILTER_PRIORITY = 2;
 
-    /** {@link #getCurrentListenerHints() Listener hints} constant - Normal interruption level. */
-    public static final int HINT_HOST_INTERRUPTION_LEVEL_ALL = 1;
-
-    /** {@link #getCurrentListenerHints() Listener hints} constant - Priority interruption level. */
-    public static final int HINT_HOST_INTERRUPTION_LEVEL_PRIORITY = 2;
-
-    /** {@link #getCurrentListenerHints() Listener hints} constant - No interruptions level. */
-    public static final int HINT_HOST_INTERRUPTION_LEVEL_NONE = 3;
+    /**
+     * {@link #getCurrentInterruptionFilter() Interruption filter} constant -
+     *     No interruptions filter.
+     */
+    public static final int INTERRUPTION_FILTER_NONE = 3;
 
     /** {@link #getCurrentListenerHints() Listener hints} constant - the primary device UI
      * should disable notification sound, vibrating and other visual or aural effects.
-     * This does not change the interruption level, only the effects. **/
-    public static final int HINT_HOST_DISABLE_EFFECTS = 1 << 2;
+     * This does not change the interruption filter, only the effects. **/
+    public static final int HINT_HOST_DISABLE_EFFECTS = 1;
+
+    /**
+     * The full trim of the StatusBarNotification including all its features.
+     *
+     * @hide
+     */
+    @SystemApi
+    public static final int TRIM_FULL = 0;
+
+    /**
+     * A light trim of the StatusBarNotification excluding the following features:
+     *
+     * <ol>
+     *     <li>{@link Notification#tickerView tickerView}</li>
+     *     <li>{@link Notification#contentView contentView}</li>
+     *     <li>{@link Notification#largeIcon largeIcon}</li>
+     *     <li>{@link Notification#bigContentView bigContentView}</li>
+     *     <li>{@link Notification#headsUpContentView headsUpContentView}</li>
+     *     <li>{@link Notification#EXTRA_LARGE_ICON extras[EXTRA_LARGE_ICON]}</li>
+     *     <li>{@link Notification#EXTRA_LARGE_ICON_BIG extras[EXTRA_LARGE_ICON_BIG]}</li>
+     *     <li>{@link Notification#EXTRA_PICTURE extras[EXTRA_PICTURE]}</li>
+     *     <li>{@link Notification#EXTRA_BIG_TEXT extras[EXTRA_BIG_TEXT]}</li>
+     * </ol>
+     *
+     * @hide
+     */
+    @SystemApi
+    public static final int TRIM_LIGHT = 1;
 
     private INotificationListenerWrapper mWrapper = null;
     private RankingMap mRankingMap;
@@ -197,6 +228,17 @@
         // optional
     }
 
+    /**
+     * Implement this method to be notified when the
+     * {@link #getCurrentInterruptionFilter() interruption filter} changed.
+     *
+     * @param interruptionFilter The current
+     *     {@link #getCurrentInterruptionFilter() interruption filter}.
+     */
+    public void onInterruptionFilterChanged(int interruptionFilter) {
+        // optional
+    }
+
     private final INotificationManager getNotificationInterface() {
         if (mNoMan == null) {
             mNoMan = INotificationManager.Stub.asInterface(
@@ -301,16 +343,87 @@
     }
 
     /**
+     * Sets the notification trim that will be received via {@link #onNotificationPosted}.
+     *
+     * <p>
+     * Setting a trim other than {@link #TRIM_FULL} enables listeners that don't need access to the
+     * full notification features right away to reduce their memory footprint. Full notifications
+     * can be requested on-demand via {@link #getActiveNotifications(int)}.
+     *
+     * <p>
+     * Set to {@link #TRIM_FULL} initially.
+     *
+     * @hide
+     *
+     * @param trim trim of the notifications to be passed via {@link #onNotificationPosted}.
+     *             See <code>TRIM_*</code> constants.
+     */
+    @SystemApi
+    public final void setOnNotificationPostedTrim(int trim) {
+        if (!isBound()) return;
+        try {
+            getNotificationInterface().setOnNotificationPostedTrimFromListener(mWrapper, trim);
+        } catch (RemoteException ex) {
+            Log.v(TAG, "Unable to contact notification manager", ex);
+        }
+    }
+
+    /**
      * Request the list of outstanding notifications (that is, those that are visible to the
      * current user). Useful when you don't know what's already been posted.
      *
      * @return An array of active notifications, sorted in natural order.
      */
     public StatusBarNotification[] getActiveNotifications() {
-        if (!isBound()) return null;
+        return getActiveNotifications(null, TRIM_FULL);
+    }
+
+    /**
+     * Request the list of outstanding notifications (that is, those that are visible to the
+     * current user). Useful when you don't know what's already been posted.
+     *
+     * @hide
+     *
+     * @param trim trim of the notifications to be returned. See <code>TRIM_*</code> constants.
+     * @return An array of active notifications, sorted in natural order.
+     */
+    @SystemApi
+    public StatusBarNotification[] getActiveNotifications(int trim) {
+        return getActiveNotifications(null, trim);
+    }
+
+    /**
+     * Request one or more notifications by key. Useful if you have been keeping track of
+     * notifications but didn't want to retain the bits, and now need to go back and extract
+     * more data out of those notifications.
+     *
+     * @param keys the keys of the notifications to request
+     * @return An array of notifications corresponding to the requested keys, in the
+     * same order as the key list.
+     */
+    public StatusBarNotification[] getActiveNotifications(String[] keys) {
+        return getActiveNotifications(keys, TRIM_FULL);
+    }
+
+    /**
+     * Request one or more notifications by key. Useful if you have been keeping track of
+     * notifications but didn't want to retain the bits, and now need to go back and extract
+     * more data out of those notifications.
+     *
+     * @hide
+     *
+     * @param keys the keys of the notifications to request
+     * @param trim trim of the notifications to be returned. See <code>TRIM_*</code> constants.
+     * @return An array of notifications corresponding to the requested keys, in the
+     * same order as the key list.
+     */
+    @SystemApi
+    public StatusBarNotification[] getActiveNotifications(String[] keys, int trim) {
+        if (!isBound())
+            return null;
         try {
-            ParceledListSlice<StatusBarNotification> parceledList =
-                    getNotificationInterface().getActiveNotificationsFromListener(mWrapper);
+            ParceledListSlice<StatusBarNotification> parceledList = getNotificationInterface()
+                    .getActiveNotificationsFromListener(mWrapper, keys, trim);
             List<StatusBarNotification> list = parceledList.getList();
 
             int N = list.size();
@@ -333,15 +446,42 @@
      * shared across all listeners or a feature the notification host does not support or refuses
      * to grant.
      *
-     * @return One or more of the HINT_ constants.
+     * @return Zero or more of the HINT_ constants.
      */
     public final int getCurrentListenerHints() {
-        if (!isBound()) return HINTS_NONE;
+        if (!isBound()) return 0;
         try {
             return getNotificationInterface().getHintsFromListener(mWrapper);
         } catch (android.os.RemoteException ex) {
             Log.v(TAG, "Unable to contact notification manager", ex);
-            return HINTS_NONE;
+            return 0;
+        }
+    }
+
+    /**
+     * Gets the current notification interruption filter active on the host.
+     *
+     * <p>
+     * The interruption filter defines which notifications are allowed to interrupt the user
+     * (e.g. via sound &amp; vibration) and is applied globally. Listeners can find out whether
+     * a specific notification matched the interruption filter via
+     * {@link Ranking#matchesInterruptionFilter()}.
+     * <p>
+     * The current filter may differ from the previously requested filter if the notification host
+     * does not support or refuses to apply the requested filter, or if another component changed
+     * the filter in the meantime.
+     * <p>
+     * Listen for updates using {@link #onInterruptionFilterChanged(int)}.
+     *
+     * @return One of the INTERRUPTION_FILTER_ constants, or 0 on errors.
+     */
+    public final int getCurrentInterruptionFilter() {
+        if (!isBound()) return 0;
+        try {
+            return getNotificationInterface().getHintsFromListener(mWrapper);
+        } catch (android.os.RemoteException ex) {
+            Log.v(TAG, "Unable to contact notification manager", ex);
+            return 0;
         }
     }
 
@@ -349,7 +489,7 @@
      * Sets the desired {@link #getCurrentListenerHints() listener hints}.
      *
      * <p>
-     * This is merely a request, the host may or not choose to take action depending
+     * This is merely a request, the host may or may not choose to take action depending
      * on other listener requests or other global state.
      * <p>
      * Listen for updates using {@link #onListenerHintsChanged(int)}.
@@ -366,6 +506,27 @@
     }
 
     /**
+     * Sets the desired {@link #getCurrentInterruptionFilter() interruption filter}.
+     *
+     * <p>
+     * This is merely a request, the host may or may not choose to apply the requested
+     * interruption filter depending on other listener requests or other global state.
+     * <p>
+     * Listen for updates using {@link #onInterruptionFilterChanged(int)}.
+     *
+     * @param interruptionFilter One of the INTERRUPTION_FILTER_ constants.
+     */
+    public final void requestInterruptionFilter(int interruptionFilter) {
+        if (!isBound()) return;
+        try {
+            getNotificationInterface()
+                    .requestInterruptionFilterFromListener(mWrapper, interruptionFilter);
+        } catch (android.os.RemoteException ex) {
+            Log.v(TAG, "Unable to contact notification manager", ex);
+        }
+    }
+
+    /**
      * Returns current ranking information.
      *
      * <p>
@@ -442,8 +603,15 @@
 
     private class INotificationListenerWrapper extends INotificationListener.Stub {
         @Override
-        public void onNotificationPosted(StatusBarNotification sbn,
+        public void onNotificationPosted(IStatusBarNotificationHolder sbnHolder,
                 NotificationRankingUpdate update) {
+            StatusBarNotification sbn;
+            try {
+                sbn = sbnHolder.get();
+            } catch (RemoteException e) {
+                Log.w(TAG, "onNotificationPosted: Error receiving StatusBarNotification", e);
+                return;
+            }
             Notification.Builder.rebuild(getContext(), sbn.getNotification());
 
             // protect subclass from concurrent modifications of (@link mNotificationKeys}.
@@ -457,8 +625,15 @@
             }
         }
         @Override
-        public void onNotificationRemoved(StatusBarNotification sbn,
+        public void onNotificationRemoved(IStatusBarNotificationHolder sbnHolder,
                 NotificationRankingUpdate update) {
+            StatusBarNotification sbn;
+            try {
+                sbn = sbnHolder.get();
+            } catch (RemoteException e) {
+                Log.w(TAG, "onNotificationRemoved: Error receiving StatusBarNotification", e);
+                return;
+            }
             // protect subclass from concurrent modifications of (@link mNotificationKeys}.
             synchronized (mWrapper) {
                 applyUpdate(update);
@@ -502,6 +677,15 @@
                 Log.w(TAG, "Error running onListenerHintsChanged", t);
             }
         }
+
+        @Override
+        public void onInterruptionFilterChanged(int interruptionFilter) throws RemoteException {
+            try {
+                NotificationListenerService.this.onInterruptionFilterChanged(interruptionFilter);
+            } catch (Throwable t) {
+                Log.w(TAG, "Error running onInterruptionFilterChanged", t);
+            }
+        }
     }
 
     private void applyUpdate(NotificationRankingUpdate update) {
@@ -524,10 +708,15 @@
      * current {@link RankingMap}.
      */
     public static class Ranking {
+        /** Value signifying that the user has not expressed a per-app visibility override value.
+         * @hide */
+        public static final int VISIBILITY_NO_OVERRIDE = -1000;
+
         private String mKey;
         private int mRank = -1;
         private boolean mIsAmbient;
-        private boolean mMeetsInterruptionFilter;
+        private boolean mMatchesInterruptionFilter;
+        private int mVisibilityOverride;
 
         public Ranking() {}
 
@@ -557,19 +746,32 @@
         }
 
         /**
-         * Returns whether the notification meets the user's interruption
+         * Returns the user specificed visibility for the package that posted
+         * this notification, or
+         * {@link NotificationListenerService.Ranking#VISIBILITY_NO_OVERRIDE} if
+         * no such preference has been expressed.
+         * @hide
+         */
+        public int getVisibilityOverride() {
+            return mVisibilityOverride;
+        }
+
+
+        /**
+         * Returns whether the notification matches the user's interruption
          * filter.
          */
-        public boolean meetsInterruptionFilter() {
-            return mMeetsInterruptionFilter;
+        public boolean matchesInterruptionFilter() {
+            return mMatchesInterruptionFilter;
         }
 
         private void populate(String key, int rank, boolean isAmbient,
-                boolean meetsInterruptionFilter) {
+                boolean matchesInterruptionFilter, int visibilityOverride) {
             mKey = key;
             mRank = rank;
             mIsAmbient = isAmbient;
-            mMeetsInterruptionFilter = meetsInterruptionFilter;
+            mMatchesInterruptionFilter = matchesInterruptionFilter;
+            mVisibilityOverride = visibilityOverride;
         }
     }
 
@@ -585,6 +787,7 @@
         private final NotificationRankingUpdate mRankingUpdate;
         private ArrayMap<String,Integer> mRanks;
         private ArraySet<Object> mIntercepted;
+        private ArrayMap<String, Integer> mVisibilityOverrides;
 
         private RankingMap(NotificationRankingUpdate rankingUpdate) {
             mRankingUpdate = rankingUpdate;
@@ -609,7 +812,8 @@
          */
         public boolean getRanking(String key, Ranking outRanking) {
             int rank = getRank(key);
-            outRanking.populate(key, rank, isAmbient(key), !isIntercepted(key));
+            outRanking.populate(key, rank, isAmbient(key), !isIntercepted(key),
+                    getVisibilityOverride(key));
             return rank >= 0;
         }
 
@@ -641,6 +845,19 @@
             return mIntercepted.contains(key);
         }
 
+        private int getVisibilityOverride(String key) {
+            synchronized (this) {
+                if (mVisibilityOverrides == null) {
+                    buildVisibilityOverridesLocked();
+                }
+            }
+            Integer overide = mVisibilityOverrides.get(key);
+            if (overide == null) {
+                return Ranking.VISIBILITY_NO_OVERRIDE;
+            }
+            return overide.intValue();
+        }
+
         // Locked by 'this'
         private void buildRanksLocked() {
             String[] orderedKeys = mRankingUpdate.getOrderedKeys();
@@ -658,6 +875,15 @@
             Collections.addAll(mIntercepted, dndInterceptedKeys);
         }
 
+        // Locked by 'this'
+        private void buildVisibilityOverridesLocked() {
+            Bundle visibilityBundle = mRankingUpdate.getVisibilityOverrides();
+            mVisibilityOverrides = new ArrayMap<>(visibilityBundle.size());
+            for (String key: visibilityBundle.keySet()) {
+               mVisibilityOverrides.put(key, visibilityBundle.getInt(key));
+            }
+        }
+
         // ----------- Parcelable
 
         @Override
diff --git a/core/java/android/service/notification/NotificationRankingUpdate.java b/core/java/android/service/notification/NotificationRankingUpdate.java
index 26af38b..6fba900 100644
--- a/core/java/android/service/notification/NotificationRankingUpdate.java
+++ b/core/java/android/service/notification/NotificationRankingUpdate.java
@@ -15,6 +15,7 @@
  */
 package android.service.notification;
 
+import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
 
@@ -26,18 +27,21 @@
     private final String[] mKeys;
     private final String[] mInterceptedKeys;
     private final int mFirstAmbientIndex;
+    private final Bundle mVisibilityOverrides;
 
     public NotificationRankingUpdate(String[] keys, String[] interceptedKeys,
-                                     int firstAmbientIndex) {
+            Bundle visibilityOverrides, int firstAmbientIndex) {
         mKeys = keys;
         mFirstAmbientIndex = firstAmbientIndex;
         mInterceptedKeys = interceptedKeys;
+        mVisibilityOverrides = visibilityOverrides;
     }
 
     public NotificationRankingUpdate(Parcel in) {
         mKeys = in.readStringArray();
         mFirstAmbientIndex = in.readInt();
         mInterceptedKeys = in.readStringArray();
+        mVisibilityOverrides = in.readBundle();
     }
 
     @Override
@@ -50,6 +54,7 @@
         out.writeStringArray(mKeys);
         out.writeInt(mFirstAmbientIndex);
         out.writeStringArray(mInterceptedKeys);
+        out.writeBundle(mVisibilityOverrides);
     }
 
     public static final Parcelable.Creator<NotificationRankingUpdate> CREATOR
@@ -74,4 +79,8 @@
     public String[] getInterceptedKeys() {
         return mInterceptedKeys;
     }
+
+    public Bundle getVisibilityOverrides() {
+        return mVisibilityOverrides;
+    }
 }
diff --git a/core/java/android/service/notification/ZenModeConfig.java b/core/java/android/service/notification/ZenModeConfig.java
index 872f911..9cbedab 100644
--- a/core/java/android/service/notification/ZenModeConfig.java
+++ b/core/java/android/service/notification/ZenModeConfig.java
@@ -17,6 +17,7 @@
 package android.service.notification;
 
 import android.content.ComponentName;
+import android.content.res.Resources;
 import android.net.Uri;
 import android.os.Parcel;
 import android.os.Parcelable;
@@ -55,6 +56,11 @@
     public static final int[] WEEKNIGHT_DAYS = { Calendar.SUNDAY, Calendar.MONDAY, Calendar.TUESDAY,
             Calendar.WEDNESDAY, Calendar.THURSDAY };
 
+    public static final int[] MINUTE_BUCKETS = new int[] { 15, 30, 45, 60, 120, 180, 240, 480 };
+    private static final int SECONDS_MS = 1000;
+    private static final int MINUTES_MS = 60 * SECONDS_MS;
+    private static final int ZERO_VALUE_MS = 20 * SECONDS_MS;
+
     private static final int XML_VERSION = 1;
     private static final String ZEN_TAG = "zen";
     private static final String ZEN_ATT_VERSION = "version";
@@ -445,6 +451,23 @@
         return downtime;
     }
 
+    public static Condition toTimeCondition(int minutesFromNow) {
+        final long now = System.currentTimeMillis();
+        final long millis = minutesFromNow == 0 ? ZERO_VALUE_MS : minutesFromNow * MINUTES_MS;
+        return toTimeCondition(now + millis, minutesFromNow);
+    }
+
+    public static Condition toTimeCondition(long time, int minutes) {
+        final int num = minutes < 60 ? minutes : Math.round(minutes / 60f);
+        final int resId = minutes < 60
+                ? com.android.internal.R.plurals.zen_mode_duration_minutes
+                : com.android.internal.R.plurals.zen_mode_duration_hours;
+        final String caption = Resources.getSystem().getQuantityString(resId, num, num);
+        final Uri id = toCountdownConditionId(time);
+        return new Condition(id, caption, "", "", 0, Condition.STATE_TRUE,
+                Condition.FLAG_RELEVANT_NOW);
+    }
+
     // For built-in conditions
     private static final String SYSTEM_AUTHORITY = "android";
 
diff --git a/core/java/android/service/restrictions/RestrictionsReceiver.java b/core/java/android/service/restrictions/RestrictionsReceiver.java
new file mode 100644
index 0000000..7c6e1f6
--- /dev/null
+++ b/core/java/android/service/restrictions/RestrictionsReceiver.java
@@ -0,0 +1,86 @@
+/*
+ * Copyright (C) 2014 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 android.service.restrictions;
+
+import android.app.admin.DevicePolicyManager;
+import android.content.BroadcastReceiver;
+import android.content.Context;
+import android.content.Intent;
+import android.content.RestrictionsManager;
+import android.os.IBinder;
+import android.os.PersistableBundle;
+
+/**
+ * Abstract implementation of a Restrictions Provider BroadcastReceiver. To implement a
+ * Restrictions Provider, extend from this class and implement the abstract methods.
+ * Export this receiver in the manifest. A profile owner device admin can then register this
+ * component as a Restrictions Provider using
+ * {@link DevicePolicyManager#setRestrictionsProvider(ComponentName, ComponentName)}.
+ * <p>
+ * The function of a Restrictions Provider is to transport permission requests from apps on this
+ * device to an administrator (most likely on a remote device or computer) and deliver back
+ * responses. The response should be sent back to the app via
+ * {@link RestrictionsManager#notifyPermissionResponse(String, PersistableBundle)}.
+ *
+ * @see RestrictionsManager
+ */
+public abstract class RestrictionsReceiver extends BroadcastReceiver {
+
+    private static final String TAG = "RestrictionsReceiver";
+
+    /**
+     * An asynchronous permission request made by an application for an operation that requires
+     * authorization by a local or remote administrator other than the user. The Restrictions
+     * Provider should transfer the request to the administrator and deliver back a response, when
+     * available. The calling application is aware that the response could take an indefinite
+     * amount of time.
+     * <p>
+     * If the request bundle contains the key {@link RestrictionsManager#REQUEST_KEY_NEW_REQUEST},
+     * then a new request must be sent. Otherwise the provider can look up any previous response
+     * to the same requestId and return the cached response.
+     *
+     * @param packageName the application requesting permission.
+     * @param requestType the type of request, which determines the content and presentation of
+     * the request data.
+     * @param request the request data bundle containing at a minimum a request id.
+     *
+     * @see RestrictionsManager#REQUEST_TYPE_APPROVAL
+     * @see RestrictionsManager#REQUEST_TYPE_LOCAL_APPROVAL
+     * @see RestrictionsManager#REQUEST_KEY_ID
+     */
+    public abstract void onRequestPermission(Context context,
+            String packageName, String requestType, String requestId, PersistableBundle request);
+
+    /**
+     * Intercept standard Restrictions Provider broadcasts.  Implementations
+     * should not override this method; it is better to implement the
+     * convenience callbacks for each action.
+     */
+    @Override
+    public void onReceive(Context context, Intent intent) {
+        String action = intent.getAction();
+
+        if (RestrictionsManager.ACTION_REQUEST_PERMISSION.equals(action)) {
+            String packageName = intent.getStringExtra(RestrictionsManager.EXTRA_PACKAGE_NAME);
+            String requestType = intent.getStringExtra(RestrictionsManager.EXTRA_REQUEST_TYPE);
+            String requestId = intent.getStringExtra(RestrictionsManager.EXTRA_REQUEST_ID);
+            PersistableBundle request = (PersistableBundle)
+                    intent.getParcelableExtra(RestrictionsManager.EXTRA_REQUEST_BUNDLE);
+            onRequestPermission(context, packageName, requestType, requestId, request);
+        }
+    }
+}
diff --git a/core/java/android/service/trust/ITrustAgentService.aidl b/core/java/android/service/trust/ITrustAgentService.aidl
index 637d080..bd80a3f 100644
--- a/core/java/android/service/trust/ITrustAgentService.aidl
+++ b/core/java/android/service/trust/ITrustAgentService.aidl
@@ -24,6 +24,7 @@
  */
 interface ITrustAgentService {
     oneway void onUnlockAttempt(boolean successful);
+    oneway void onTrustTimeout();
     oneway void setCallback(ITrustAgentServiceCallback callback);
     oneway void setTrustAgentFeaturesEnabled(in Bundle options, IBinder token);
 }
diff --git a/core/java/android/service/trust/TrustAgentService.java b/core/java/android/service/trust/TrustAgentService.java
index 5fe9194..3ef5b37 100644
--- a/core/java/android/service/trust/TrustAgentService.java
+++ b/core/java/android/service/trust/TrustAgentService.java
@@ -30,6 +30,7 @@
 import android.os.IBinder;
 import android.os.Message;
 import android.os.RemoteException;
+import android.os.SystemClock;
 import android.util.Log;
 import android.util.Slog;
 
@@ -37,7 +38,10 @@
  * A service that notifies the system about whether it believes the environment of the device
  * to be trusted.
  *
- * <p>Trust agents may only be provided by the platform.</p>
+ * <p>Trust agents may only be provided by the platform. It is expected that there is only
+ * one trust agent installed on the platform. In the event there is more than one,
+ * either trust agent can enable trust.
+ * </p>
  *
  * <p>To extend this class, you must declare the service in your manifest file with
  * the {@link android.Manifest.permission#BIND_TRUST_AGENT} permission
@@ -85,11 +89,13 @@
     /**
      * A white list of features that the given trust agent should support when otherwise disabled
      * by device policy.
+     * @hide
      */
     public static final String KEY_FEATURES = "trust_agent_features";
 
     private static final int MSG_UNLOCK_ATTEMPT = 1;
     private static final int MSG_SET_TRUST_AGENT_FEATURES_ENABLED = 2;
+    private static final int MSG_TRUST_TIMEOUT = 3;
 
     private ITrustAgentServiceCallback mCallback;
 
@@ -118,6 +124,9 @@
                         onError("calling onSetTrustAgentFeaturesEnabledCompleted()");
                     }
                     break;
+                case MSG_TRUST_TIMEOUT:
+                    onTrustTimeout();
+                    break;
             }
         }
     };
@@ -139,21 +148,32 @@
     }
 
     /**
-     * Called when the user attempted to authenticate on the device.
+     * Called after the user attempts to authenticate in keyguard with their device credentials,
+     * such as pin, pattern or password.
      *
-     * @param successful true if the attempt succeeded
+     * @param successful true if the user successfully completed the challenge.
      */
     public void onUnlockAttempt(boolean successful) {
     }
 
+    /**
+     * Called when the timeout provided by the agent expires.  Note that this may be called earlier
+     * than requested by the agent if the trust timeout is adjusted by the system or
+     * {@link DevicePolicyManager}.  The agent is expected to re-evaluate the trust state and only
+     * call {@link #grantTrust(CharSequence, long, boolean)} if the trust state should be
+     * continued.
+     */
+    public void onTrustTimeout() {
+    }
+
     private void onError(String msg) {
         Slog.v(TAG, "Remote exception while " + msg);
     }
 
     /**
-     * Called when device policy wants to restrict features in the TrustAgent in response to
+     * Called when device policy wants to restrict features in the agent in response to
      * {@link DevicePolicyManager#setTrustAgentFeaturesEnabled(ComponentName, ComponentName, java.util.List) }.
-     * TrustAgents that support this feature should overload this method and return 'true'.
+     * Agents that support this feature should overload this method and return 'true'.
      *
      * The list of options can be obtained by calling
      * options.getStringArrayList({@link #KEY_FEATURES}). Presence of a feature string in the list
@@ -165,6 +185,7 @@
      *
      * @param options Option feature bundle.
      * @return true if the {@link TrustAgentService} supports this feature.
+     * @hide
      */
     public boolean onSetTrustAgentFeaturesEnabled(Bundle options) {
         return false;
@@ -174,10 +195,19 @@
      * Call to grant trust on the device.
      *
      * @param message describes why the device is trusted, e.g. "Trusted by location".
-     * @param durationMs amount of time in milliseconds to keep the device in a trusted state. Trust
-     *                   for this agent will automatically be revoked when the timeout expires.
-     * @param initiatedByUser indicates that the user has explicitly initiated an action that proves
-     *                        the user is about to use the device.
+     * @param durationMs amount of time in milliseconds to keep the device in a trusted state.
+     *    Trust for this agent will automatically be revoked when the timeout expires unless
+     *    extended by a subsequent call to this function. The timeout is measured from the
+     *    invocation of this function as dictated by {@link SystemClock#elapsedRealtime())}.
+     *    For security reasons, the value should be no larger than necessary.
+     *    The value may be adjusted by the system as necessary to comply with a policy controlled
+     *    by the system or {@link DevicePolicyManager} restrictions. See {@link #onTrustTimeout()}
+     *    for determining when trust expires.
+     * @param initiatedByUser this is a hint to the system that trust is being granted as the
+     *    direct result of user action - such as solving a security challenge. The hint is used
+     *    by the system to optimize the experience. Behavior may vary by device and release, so
+     *    one should only set this parameter if it meets the above criteria rather than relying on
+     *    the behavior of any particular device or release.
      * @throws IllegalStateException if the agent is not currently managing trust.
      */
     public final void grantTrust(
@@ -254,13 +284,17 @@
     }
 
     private final class TrustAgentServiceWrapper extends ITrustAgentService.Stub {
-        @Override
+        @Override /* Binder API */
         public void onUnlockAttempt(boolean successful) {
-            mHandler.obtainMessage(MSG_UNLOCK_ATTEMPT, successful ? 1 : 0, 0)
-                    .sendToTarget();
+            mHandler.obtainMessage(MSG_UNLOCK_ATTEMPT, successful ? 1 : 0, 0).sendToTarget();
         }
 
-        @Override
+        @Override /* Binder API */
+        public void onTrustTimeout() {
+            mHandler.sendEmptyMessage(MSG_TRUST_TIMEOUT);
+        }
+
+        @Override /* Binder API */
         public void setCallback(ITrustAgentServiceCallback callback) {
             synchronized (mLock) {
                 mCallback = callback;
@@ -280,7 +314,7 @@
             }
         }
 
-        @Override
+        @Override /* Binder API */
         public void setTrustAgentFeaturesEnabled(Bundle features, IBinder token) {
             Message msg = mHandler.obtainMessage(MSG_SET_TRUST_AGENT_FEATURES_ENABLED, token);
             msg.setData(features);
diff --git a/core/java/android/service/voice/AlwaysOnHotwordDetector.java b/core/java/android/service/voice/AlwaysOnHotwordDetector.java
index 15e66a0..ac7d539 100644
--- a/core/java/android/service/voice/AlwaysOnHotwordDetector.java
+++ b/core/java/android/service/voice/AlwaysOnHotwordDetector.java
@@ -19,6 +19,7 @@
 import android.annotation.IntDef;
 import android.annotation.NonNull;
 import android.annotation.Nullable;
+import android.app.Activity;
 import android.content.Intent;
 import android.hardware.soundtrigger.IRecognitionStatusCallback;
 import android.hardware.soundtrigger.KeyphraseEnrollmentInfo;
@@ -39,10 +40,10 @@
 
 import com.android.internal.app.IVoiceInteractionManagerService;
 
-import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.lang.annotation.Retention;
 import java.lang.annotation.RetentionPolicy;
+import java.util.Locale;
 
 /**
  * A class that lets a VoiceInteractionService implementation interact with
@@ -84,20 +85,31 @@
     private static final int STATE_NOT_READY = 0;
 
     // Keyphrase management actions. Used in getManageIntent() ----//
-    /** @hide */
     @Retention(RetentionPolicy.SOURCE)
     @IntDef(value = {
                 MANAGE_ACTION_ENROLL,
                 MANAGE_ACTION_RE_ENROLL,
                 MANAGE_ACTION_UN_ENROLL
             })
-    public @interface ManageActions {}
+    private @interface ManageActions {}
 
-    /** Indicates that we need to enroll. */
+    /**
+     * Indicates that we need to enroll.
+     *
+     * @hide
+     */
     public static final int MANAGE_ACTION_ENROLL = 0;
-    /** Indicates that we need to re-enroll. */
+    /**
+     * Indicates that we need to re-enroll.
+     *
+     * @hide
+     */
     public static final int MANAGE_ACTION_RE_ENROLL = 1;
-    /** Indicates that we need to un-enroll. */
+    /**
+     * Indicates that we need to un-enroll.
+     *
+     * @hide
+     */
     public static final int MANAGE_ACTION_UN_ENROLL = 2;
 
     //-- Flags for startRecognition    ----//
@@ -111,7 +123,11 @@
             })
     public @interface RecognitionFlags {}
 
-    /** Empty flag for {@link #startRecognition(int)}. */
+    /**
+     * Empty flag for {@link #startRecognition(int)}.
+     *
+     * @hide
+     */
     public static final int RECOGNITION_FLAG_NONE = 0;
     /**
      * Recognition flag for {@link #startRecognition(int)} that indicates
@@ -154,8 +170,7 @@
             = SoundTrigger.RECOGNITION_MODE_USER_IDENTIFICATION;
 
     static final String TAG = "AlwaysOnHotwordDetector";
-    // TODO: Set to false.
-    static final boolean DBG = true;
+    static final boolean DBG = false;
 
     private static final int STATUS_ERROR = SoundTrigger.STATUS_ERROR;
     private static final int STATUS_OK = SoundTrigger.STATUS_OK;
@@ -167,7 +182,7 @@
     private static final int MSG_DETECTION_RESUME = 5;
 
     private final String mText;
-    private final String mLocale;
+    private final Locale mLocale;
     /**
      * The metadata of the Keyphrase, derived from the enrollment application.
      * This may be null if this keyphrase isn't supported by the enrollment application.
@@ -264,7 +279,7 @@
     /**
      * Callbacks for always-on hotword detection.
      */
-    public interface Callback {
+    public static abstract class Callback {
         /**
          * Called when the hotword availability changes.
          * This indicates a change in the availability of recognition for the given keyphrase.
@@ -278,7 +293,7 @@
          * @see AlwaysOnHotwordDetector#STATE_KEYPHRASE_UNENROLLED
          * @see AlwaysOnHotwordDetector#STATE_KEYPHRASE_ENROLLED
          */
-        void onAvailabilityChanged(int status);
+        public abstract void onAvailabilityChanged(int status);
         /**
          * Called when the keyphrase is spoken.
          * This implicitly stops listening for the keyphrase once it's detected.
@@ -289,23 +304,23 @@
          *        This may contain the trigger audio, if requested when calling
          *        {@link AlwaysOnHotwordDetector#startRecognition(int)}.
          */
-        void onDetected(@NonNull EventPayload eventPayload);
+        public abstract void onDetected(@NonNull EventPayload eventPayload);
         /**
          * Called when the detection fails due to an error.
          */
-        void onError();
+        public abstract void onError();
         /**
          * Called when the recognition is paused temporarily for some reason.
          * This is an informational callback, and the clients shouldn't be doing anything here
          * except showing an indication on their UI if they have to.
          */
-        void onRecognitionPaused();
+        public abstract void onRecognitionPaused();
         /**
          * Called when the recognition is resumed after it was temporarily paused.
          * This is an informational callback, and the clients shouldn't be doing anything here
          * except showing an indication on their UI if they have to.
          */
-        void onRecognitionResumed();
+        public abstract void onRecognitionResumed();
     }
 
     /**
@@ -317,7 +332,7 @@
      *
      * @hide
      */
-    public AlwaysOnHotwordDetector(String text, String locale, Callback callback,
+    public AlwaysOnHotwordDetector(String text, Locale locale, Callback callback,
             KeyphraseEnrollmentInfo keyphraseEnrollmentInfo,
             IVoiceInteractionService voiceInteractionService,
             IVoiceInteractionManagerService modelManagementService) {
@@ -372,10 +387,10 @@
     /**
      * Starts recognition for the associated keyphrase.
      *
+     * @see #RECOGNITION_FLAG_CAPTURE_TRIGGER_AUDIO
+     * @see #RECOGNITION_FLAG_ALLOW_MULTIPLE_TRIGGERS
+     *
      * @param recognitionFlags The flags to control the recognition properties.
-     *        The allowed flags are {@link #RECOGNITION_FLAG_NONE},
-     *        {@link #RECOGNITION_FLAG_CAPTURE_TRIGGER_AUDIO} and
-     *        {@link #RECOGNITION_FLAG_ALLOW_MULTIPLE_TRIGGERS}.
      * @return Indicates whether the call succeeded or not.
      * @throws UnsupportedOperationException if the recognition isn't supported.
      *         Callers should only call this method after a supported state callback on
@@ -430,12 +445,13 @@
     }
 
     /**
-     * Gets an intent to manage the associated keyphrase.
+     * Creates an intent to start the enrollment for the associated keyphrase.
+     * This intent must be invoked using {@link Activity#startActivityForResult(Intent, int)}.
+     * Starting re-enrollment is only valid if the keyphrase is un-enrolled,
+     * i.e. {@link #STATE_KEYPHRASE_UNENROLLED},
+     * otherwise {@link #createReEnrollIntent()} should be preferred.
      *
-     * @param action The manage action that needs to be performed.
-     *        One of {@link #MANAGE_ACTION_ENROLL}, {@link #MANAGE_ACTION_RE_ENROLL} or
-     *        {@link #MANAGE_ACTION_UN_ENROLL}.
-     * @return An {@link Intent} to manage the given keyphrase.
+     * @return An {@link Intent} to start enrollment for the given keyphrase.
      * @throws UnsupportedOperationException if managing they keyphrase isn't supported.
      *         Callers should only call this method after a supported state callback on
      *         {@link Callback#onAvailabilityChanged(int)} to avoid this exception.
@@ -443,10 +459,52 @@
      *         This may happen if another detector has been instantiated or the
      *         {@link VoiceInteractionService} hosting this detector has been shut down.
      */
-    public Intent getManageIntent(@ManageActions int action) {
-        if (DBG) Slog.d(TAG, "getManageIntent(" + action + ")");
+    public Intent createEnrollIntent() {
+        if (DBG) Slog.d(TAG, "createEnrollIntent");
         synchronized (mLock) {
-            return getManageIntentLocked(action);
+            return getManageIntentLocked(MANAGE_ACTION_ENROLL);
+        }
+    }
+
+    /**
+     * Creates an intent to start the un-enrollment for the associated keyphrase.
+     * This intent must be invoked using {@link Activity#startActivityForResult(Intent, int)}.
+     * Starting re-enrollment is only valid if the keyphrase is already enrolled,
+     * i.e. {@link #STATE_KEYPHRASE_ENROLLED}, otherwise invoking this may result in an error.
+     *
+     * @return An {@link Intent} to start un-enrollment for the given keyphrase.
+     * @throws UnsupportedOperationException if managing they keyphrase isn't supported.
+     *         Callers should only call this method after a supported state callback on
+     *         {@link Callback#onAvailabilityChanged(int)} to avoid this exception.
+     * @throws IllegalStateException if the detector is in an invalid state.
+     *         This may happen if another detector has been instantiated or the
+     *         {@link VoiceInteractionService} hosting this detector has been shut down.
+     */
+    public Intent createUnEnrollIntent() {
+        if (DBG) Slog.d(TAG, "createUnEnrollIntent");
+        synchronized (mLock) {
+            return getManageIntentLocked(MANAGE_ACTION_UN_ENROLL);
+        }
+    }
+
+    /**
+     * Creates an intent to start the re-enrollment for the associated keyphrase.
+     * This intent must be invoked using {@link Activity#startActivityForResult(Intent, int)}.
+     * Starting re-enrollment is only valid if the keyphrase is already enrolled,
+     * i.e. {@link #STATE_KEYPHRASE_ENROLLED}, otherwise invoking this may result in an error.
+     *
+     * @return An {@link Intent} to start re-enrollment for the given keyphrase.
+     * @throws UnsupportedOperationException if managing they keyphrase isn't supported.
+     *         Callers should only call this method after a supported state callback on
+     *         {@link Callback#onAvailabilityChanged(int)} to avoid this exception.
+     * @throws IllegalStateException if the detector is in an invalid state.
+     *         This may happen if another detector has been instantiated or the
+     *         {@link VoiceInteractionService} hosting this detector has been shut down.
+     */
+    public Intent createReEnrollIntent() {
+        if (DBG) Slog.d(TAG, "createReEnrollIntent");
+        synchronized (mLock) {
+            return getManageIntentLocked(MANAGE_ACTION_RE_ENROLL);
         }
     }
 
@@ -462,12 +520,6 @@
                     "Managing the given keyphrase is not supported");
         }
 
-        if (action != MANAGE_ACTION_ENROLL
-                && action != MANAGE_ACTION_RE_ENROLL
-                && action != MANAGE_ACTION_UN_ENROLL) {
-            throw new IllegalArgumentException("Invalid action specified " + action);
-        }
-
         return mKeyphraseEnrollmentInfo.getManageKeyphraseIntent(action, mText, mLocale);
     }
 
@@ -491,8 +543,6 @@
      */
     void onSoundModelsChanged() {
         synchronized (mLock) {
-            // FIXME: This should stop the recognition if it was using an enrolled sound model
-            // that's no longer available.
             if (mAvailability == STATE_INVALID
                     || mAvailability == STATE_HARDWARE_UNAVAILABLE
                     || mAvailability == STATE_KEYPHRASE_UNSUPPORTED) {
@@ -500,6 +550,13 @@
                 return;
             }
 
+            // Stop the recognition before proceeding.
+            // This is done because we want to stop the recognition on an older model if it changed
+            // or was deleted.
+            // The availability change callback should ensure that the client starts recognition
+            // again if needed.
+            stopRecognitionLocked();
+
             // Execute a refresh availability task - which should then notify of a change.
             new RefreshAvailabiltyTask().execute();
         }
@@ -517,7 +574,7 @@
         int code = STATUS_ERROR;
         try {
             code = mModelManagementService.startRecognition(mVoiceInteractionService,
-                    mKeyphraseMetadata.id, mInternalCallback,
+                    mKeyphraseMetadata.id, mLocale.toLanguageTag(), mInternalCallback,
                     new RecognitionConfig(captureTriggerAudio, allowMultipleTriggers,
                             recognitionExtra, null /* additional data */));
         } catch (RemoteException e) {
@@ -632,7 +689,7 @@
             if (availability == STATE_NOT_READY
                     || availability == STATE_KEYPHRASE_UNENROLLED
                     || availability == STATE_KEYPHRASE_ENROLLED) {
-                enrolled = internalGetIsEnrolled(mKeyphraseMetadata.id);
+                enrolled = internalGetIsEnrolled(mKeyphraseMetadata.id, mLocale);
                 if (!enrolled) {
                     availability = STATE_KEYPHRASE_UNENROLLED;
                 } else {
@@ -683,10 +740,10 @@
         /**
          * @return The corresponding {@link KeyphraseSoundModel} or null if none is found.
          */
-        private boolean internalGetIsEnrolled(int keyphraseId) {
+        private boolean internalGetIsEnrolled(int keyphraseId, Locale locale) {
             try {
                 return mModelManagementService.isEnrolledForKeyphrase(
-                        mVoiceInteractionService, keyphraseId);
+                        mVoiceInteractionService, keyphraseId, locale.toLanguageTag());
             } catch (RemoteException e) {
                 Slog.w(TAG, "RemoteException in listRegisteredKeyphraseSoundModels!", e);
             }
diff --git a/core/java/android/service/voice/VoiceInteractionService.java b/core/java/android/service/voice/VoiceInteractionService.java
index b2003568..0cde4f2 100644
--- a/core/java/android/service/voice/VoiceInteractionService.java
+++ b/core/java/android/service/voice/VoiceInteractionService.java
@@ -35,20 +35,20 @@
 
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
+import java.util.Locale;
 
 
 /**
  * Top-level service of the current global voice interactor, which is providing
- * support for hotwording, the back-end of a {@link android.app.VoiceInteractor}, etc.
+ * support for hotwording etc.
  * The current VoiceInteractionService that has been selected by the user is kept
  * always running by the system, to allow it to do things like listen for hotwords
- * in the background to instigate voice interactions.
+ * in the background.
  *
  * <p>Because this service is always running, it should be kept as lightweight as
  * possible.  Heavy-weight operations (including showing UI) should be implemented
- * in the associated {@link android.service.voice.VoiceInteractionSessionService} when
- * an actual voice interaction is taking place, and that service should run in a
- * separate process from this one.
+ * in the associated {@link android.service.voice.VoiceInteractionSessionService}
+ * that only runs while the operation is active.
  */
 public class VoiceInteractionService extends Service {
     /**
@@ -163,7 +163,7 @@
      * Called during service initialization to tell you when the system is ready
      * to receive interaction from it. You should generally do initialization here
      * rather than in {@link #onCreate()}. Methods such as {@link #startSession(Bundle)} and
-     * {@link #createAlwaysOnHotwordDetector(String, String, android.service.voice.AlwaysOnHotwordDetector.Callback)}
+     * {@link #createAlwaysOnHotwordDetector(String, Locale, android.service.voice.AlwaysOnHotwordDetector.Callback)}
      * will not be operational until this point.
      */
     public void onReady() {
@@ -207,12 +207,11 @@
      *
      * @param keyphrase The keyphrase that's being used, for example "Hello Android".
      * @param locale The locale for which the enrollment needs to be performed.
-     *        This is a Java locale, for example "en_US".
      * @param callback The callback to notify of detection events.
      * @return An always-on hotword detector for the given keyphrase and locale.
      */
     public final AlwaysOnHotwordDetector createAlwaysOnHotwordDetector(
-            String keyphrase, String locale, AlwaysOnHotwordDetector.Callback callback) {
+            String keyphrase, Locale locale, AlwaysOnHotwordDetector.Callback callback) {
         if (mSystemService == null) {
             throw new IllegalStateException("Not available until onReady() is called");
         }
diff --git a/core/java/android/service/voice/VoiceInteractionSession.java b/core/java/android/service/voice/VoiceInteractionSession.java
index 19d14bf..749f813 100644
--- a/core/java/android/service/voice/VoiceInteractionSession.java
+++ b/core/java/android/service/voice/VoiceInteractionSession.java
@@ -16,6 +16,7 @@
 
 package android.service.voice;
 
+import android.annotation.SystemApi;
 import android.app.Dialog;
 import android.app.Instrumentation;
 import android.content.Context;
@@ -53,15 +54,7 @@
 import static android.view.ViewGroup.LayoutParams.WRAP_CONTENT;
 
 /**
- * An active voice interaction session, providing a facility for the implementation
- * to interact with the user in the voice interaction layer.  This interface is no shown
- * by default, but you can request that it be shown with {@link #showWindow()}, which
- * will result in a later call to {@link #onCreateContentView()} in which the UI can be
- * built
- *
- * <p>A voice interaction session can be self-contained, ultimately calling {@link #finish}
- * when done.  It can also initiate voice interactions with applications by calling
- * {@link #startVoiceActivity}</p>.
+ * An active interaction session, started by a {@link VoiceInteractionService}.
  */
 public abstract class VoiceInteractionSession implements KeyEvent.Callback {
     static final String TAG = "VoiceInteractionSession";
@@ -175,6 +168,10 @@
         }
     };
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public static class Request {
         final IVoiceInteractorRequest mInterface = new IVoiceInteractorRequest.Stub() {
             @Override
@@ -258,6 +255,10 @@
         }
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public static class Caller {
         final String packageName;
         final int uid;
@@ -353,8 +354,10 @@
     final MyCallbacks mCallbacks = new MyCallbacks();
 
     /**
+     * @hide
      * Information about where interesting parts of the input method UI appear.
      */
+    @SystemApi
     public static final class Insets {
         /**
          * This is the part of the UI that is the main content.  It is
@@ -474,6 +477,10 @@
         mContentFrame = (FrameLayout)mRootView.findViewById(android.R.id.content);
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public void showWindow() {
         if (DEBUG) Log.v(TAG, "Showing window: mWindowAdded=" + mWindowAdded
                 + " mWindowVisible=" + mWindowVisible);
@@ -502,6 +509,10 @@
         }
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public void hideWindow() {
         if (mWindowVisible) {
             mWindow.hide();
@@ -510,11 +521,13 @@
     }
 
     /**
+     * @hide
      * You can call this to customize the theme used by your IME's window.
      * This must be set before {@link #onCreate}, so you
      * will typically call it in your constructor with the resource ID
      * of your custom theme.
      */
+    @SystemApi
     public void setTheme(int theme) {
         if (mWindow != null) {
             throw new IllegalStateException("Must be called before onCreate()");
@@ -523,6 +536,7 @@
     }
 
     /**
+     * @hide
      * Ask that a new activity be started for voice interaction.  This will create a
      * new dedicated task in the activity manager for this voice interaction session;
      * this means that {@link Intent#FLAG_ACTIVITY_NEW_TASK Intent.FLAG_ACTIVITY_NEW_TASK}
@@ -543,6 +557,7 @@
      * always have {@link Intent#CATEGORY_VOICE Intent.CATEGORY_VOICE} added to it, since
      * this is part of a voice interaction.
      */
+    @SystemApi
     public void startVoiceActivity(Intent intent) {
         if (mToken == null) {
             throw new IllegalStateException("Can't call before onCreate()");
@@ -558,15 +573,19 @@
     }
 
     /**
+     * @hide
      * Convenience for inflating views.
      */
+    @SystemApi
     public LayoutInflater getLayoutInflater() {
         return mInflater;
     }
 
     /**
+     * @hide
      * Retrieve the window being used to show the session's UI.
      */
+    @SystemApi
     public Dialog getWindow() {
         return mWindow;
     }
@@ -612,8 +631,10 @@
     }
 
     /**
+     * @hide
      * Hook in which to create the session's UI.
      */
+    @SystemApi
     public View onCreateContentView() {
         return null;
     }
@@ -626,22 +647,42 @@
 
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public boolean onKeyDown(int keyCode, KeyEvent event) {
         return false;
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public boolean onKeyLongPress(int keyCode, KeyEvent event) {
         return false;
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public boolean onKeyUp(int keyCode, KeyEvent event) {
         return false;
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public boolean onKeyMultiple(int keyCode, int count, KeyEvent event) {
         return false;
     }
 
+    /**
+     * @hide
+     */
+    @SystemApi
     public void onBackPressed() {
         finish();
     }
@@ -656,12 +697,14 @@
     }
 
     /**
+     * @hide
      * Compute the interesting insets into your UI.  The default implementation
      * uses the entire window frame as the insets.  The default touchable
      * insets are {@link Insets#TOUCHABLE_INSETS_FRAME}.
      *
      * @param outInsets Fill in with the current UI insets.
      */
+    @SystemApi
     public void onComputeInsets(Insets outInsets) {
         int[] loc = mTmpLocation;
         View decor = getWindow().getWindow().getDecorView();
@@ -675,6 +718,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Called when a task initiated by {@link #startVoiceActivity(android.content.Intent)}
      * has actually started.
      *
@@ -686,6 +731,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Called when the last activity of a task initiated by
      * {@link #startVoiceActivity(android.content.Intent)} has finished.  The default
      * implementation calls {@link #finish()} on the assumption that this represents
@@ -701,6 +748,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Request to query for what extended commands the session supports.
      *
      * @param caller Who is making the request.
@@ -715,6 +764,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Request to confirm with the user before proceeding with an unrecoverable operation,
      * corresponding to a {@link android.app.VoiceInteractor.ConfirmationRequest
      * VoiceInteractor.ConfirmationRequest}.
@@ -730,6 +781,8 @@
             Bundle extras);
 
     /**
+     * @hide
+     * @SystemApi
      * Request to complete the voice interaction session because the voice activity successfully
      * completed its interaction using voice.  Corresponds to
      * {@link android.app.VoiceInteractor.CompleteVoiceRequest
@@ -751,6 +804,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Request to abort the voice interaction session because the voice activity can not
      * complete its interaction using voice.  Corresponds to
      * {@link android.app.VoiceInteractor.AbortVoiceRequest
@@ -769,6 +824,8 @@
     }
 
     /**
+     * @hide
+     * @SystemApi
      * Process an arbitrary extended command from the caller,
      * corresponding to a {@link android.app.VoiceInteractor.CommandRequest
      * VoiceInteractor.CommandRequest}.
@@ -783,6 +840,8 @@
     public abstract void onCommand(Caller caller, Request request, String command, Bundle extras);
 
     /**
+     * @hide
+     * @SystemApi
      * Called when the {@link android.app.VoiceInteractor} has asked to cancel a {@link Request}
      * that was previously delivered to {@link #onConfirm} or {@link #onCommand}.
      *
diff --git a/core/java/android/service/wallpaper/IWallpaperEngine.aidl b/core/java/android/service/wallpaper/IWallpaperEngine.aidl
index faccde2..de527e9 100644
--- a/core/java/android/service/wallpaper/IWallpaperEngine.aidl
+++ b/core/java/android/service/wallpaper/IWallpaperEngine.aidl
@@ -16,6 +16,7 @@
 
 package android.service.wallpaper;
 
+import android.graphics.Rect;
 import android.view.MotionEvent;
 import android.os.Bundle;
 
@@ -24,6 +25,7 @@
  */
 oneway interface IWallpaperEngine {
     void setDesiredSize(int width, int height);
+    void setDisplayPadding(in Rect padding);
     void setVisibility(boolean visible);
     void dispatchPointer(in MotionEvent event);
     void dispatchWallpaperCommand(String action, int x, int y,
diff --git a/core/java/android/service/wallpaper/IWallpaperService.aidl b/core/java/android/service/wallpaper/IWallpaperService.aidl
index bc7a1d7..5fd0157 100644
--- a/core/java/android/service/wallpaper/IWallpaperService.aidl
+++ b/core/java/android/service/wallpaper/IWallpaperService.aidl
@@ -16,6 +16,7 @@
 
 package android.service.wallpaper;
 
+import android.graphics.Rect;
 import android.service.wallpaper.IWallpaperConnection;
 
 /**
@@ -24,5 +25,5 @@
 oneway interface IWallpaperService {
     void attach(IWallpaperConnection connection,
     		IBinder windowToken, int windowType, boolean isPreview,
-    		int reqWidth, int reqHeight);
+    		int reqWidth, int reqHeight, in Rect padding);
 }
diff --git a/core/java/android/service/wallpaper/WallpaperService.java b/core/java/android/service/wallpaper/WallpaperService.java
index f3c26c8..26e9a30 100644
--- a/core/java/android/service/wallpaper/WallpaperService.java
+++ b/core/java/android/service/wallpaper/WallpaperService.java
@@ -16,6 +16,14 @@
 
 package android.service.wallpaper;
 
+import android.content.res.TypedArray;
+import android.os.Build;
+import android.os.SystemProperties;
+import android.util.DisplayMetrics;
+import android.util.TypedValue;
+import android.view.ViewRootImpl;
+import android.view.WindowInsets;
+import com.android.internal.R;
 import com.android.internal.os.HandlerCaller;
 import com.android.internal.view.BaseIWindow;
 import com.android.internal.view.BaseSurfaceHolder;
@@ -56,6 +64,8 @@
 import java.io.PrintWriter;
 import java.util.ArrayList;
 
+import static android.view.WindowManager.LayoutParams.FLAG_FULLSCREEN;
+
 /**
  * A wallpaper service is responsible for showing a live wallpaper behind
  * applications that would like to sit on top of it.  This service object
@@ -90,7 +100,8 @@
     private static final int DO_ATTACH = 10;
     private static final int DO_DETACH = 20;
     private static final int DO_SET_DESIRED_SIZE = 30;
-    
+    private static final int DO_SET_DISPLAY_PADDING = 40;
+
     private static final int MSG_UPDATE_SURFACE = 10000;
     private static final int MSG_VISIBILITY_CHANGED = 10010;
     private static final int MSG_WALLPAPER_OFFSETS = 10020;
@@ -150,13 +161,23 @@
                 WindowManager.LayoutParams.PRIVATE_FLAG_WANTS_OFFSET_NOTIFICATIONS;
         int mCurWindowFlags = mWindowFlags;
         int mCurWindowPrivateFlags = mWindowPrivateFlags;
+        TypedValue mOutsetBottom;
         final Rect mVisibleInsets = new Rect();
         final Rect mWinFrame = new Rect();
         final Rect mOverscanInsets = new Rect();
         final Rect mContentInsets = new Rect();
         final Rect mStableInsets = new Rect();
+        final Rect mDispatchedOverscanInsets = new Rect();
+        final Rect mDispatchedContentInsets = new Rect();
+        final Rect mDispatchedStableInsets = new Rect();
+        final Rect mFinalSystemInsets = new Rect();
+        final Rect mFinalStableInsets = new Rect();
         final Configuration mConfiguration = new Configuration();
-        
+
+        private boolean mIsEmulator;
+        private boolean mIsCircularEmulator;
+        private boolean mWindowIsRound;
+
         final WindowManager.LayoutParams mLayout
                 = new WindowManager.LayoutParams();
         IWindowSession mSession;
@@ -406,7 +427,7 @@
          */
         public void onCreate(SurfaceHolder surfaceHolder) {
         }
-        
+
         /**
          * Called right before the engine is going away.  After this the
          * surface will be destroyed and this Engine object is no longer
@@ -414,7 +435,7 @@
          */
         public void onDestroy() {
         }
-        
+
         /**
          * Called to inform you of the wallpaper becoming visible or
          * hidden.  <em>It is very important that a wallpaper only use
@@ -422,7 +443,17 @@
          */
         public void onVisibilityChanged(boolean visible) {
         }
-        
+
+        /**
+         * Called with the current insets that are in effect for the wallpaper.
+         * This gives you the part of the overall wallpaper surface that will
+         * generally be visible to the user (ignoring position offsets applied to it).
+         *
+         * @param insets Insets to apply.
+         */
+        public void onApplyWindowInsets(WindowInsets insets) {
+        }
+
         /**
          * Called as the user performs touch-screen interaction with the
          * window that is currently showing this wallpaper.  Note that the
@@ -432,7 +463,7 @@
          */
         public void onTouchEvent(MotionEvent event) {
         }
-        
+
         /**
          * Called to inform you of the wallpaper's offsets changing
          * within its contain, corresponding to the container's
@@ -443,7 +474,7 @@
                 float xOffsetStep, float yOffsetStep,
                 int xPixelOffset, int yPixelOffset) {
         }
-        
+
         /**
          * Process a command that was sent to the wallpaper with
          * {@link WallpaperManager#sendWallpaperCommand}.
@@ -465,14 +496,14 @@
                 Bundle extras, boolean resultRequested) {
             return null;
         }
-        
+
         /**
          * Called when an application has changed the desired virtual size of
          * the wallpaper.
          */
         public void onDesiredSizeChanged(int desiredWidth, int desiredHeight) {
         }
-        
+
         /**
          * Convenience for {@link SurfaceHolder.Callback#surfaceChanged
          * SurfaceHolder.Callback.surfaceChanged()}.
@@ -561,16 +592,20 @@
             if (mDestroyed) {
                 Log.w(TAG, "Ignoring updateSurface: destroyed");
             }
-            
+
+            boolean fixedSize = false;
             int myWidth = mSurfaceHolder.getRequestedWidth();
             if (myWidth <= 0) myWidth = ViewGroup.LayoutParams.MATCH_PARENT;
+            else fixedSize = true;
             int myHeight = mSurfaceHolder.getRequestedHeight();
             if (myHeight <= 0) myHeight = ViewGroup.LayoutParams.MATCH_PARENT;
-            
+            else fixedSize = true;
+
             final boolean creating = !mCreated;
             final boolean surfaceCreating = !mSurfaceCreated;
             final boolean formatChanged = mFormat != mSurfaceHolder.getRequestedFormat();
             boolean sizeChanged = mWidth != myWidth || mHeight != myHeight;
+            boolean insetsChanged = !mCreated;
             final boolean typeChanged = mType != mSurfaceHolder.getRequestedType();
             final boolean flagsChanged = mCurWindowFlags != mWindowFlags ||
                     mCurWindowPrivateFlags != mWindowPrivateFlags;
@@ -607,6 +642,32 @@
                     mLayout.token = mWindowToken;
 
                     if (!mCreated) {
+                        // Retrieve watch round and outset info
+                        final WindowManager windowService = (WindowManager)getSystemService(
+                                Context.WINDOW_SERVICE);
+                        TypedArray windowStyle = obtainStyledAttributes(
+                                com.android.internal.R.styleable.Window);
+                        final Display display = windowService.getDefaultDisplay();
+                        final boolean shouldUseBottomOutset =
+                                display.getDisplayId() == Display.DEFAULT_DISPLAY;
+                        if (shouldUseBottomOutset && windowStyle.hasValue(
+                                R.styleable.Window_windowOutsetBottom)) {
+                            if (mOutsetBottom == null) mOutsetBottom = new TypedValue();
+                            windowStyle.getValue(R.styleable.Window_windowOutsetBottom,
+                                    mOutsetBottom);
+                        } else {
+                            mOutsetBottom = null;
+                        }
+                        mWindowIsRound = getResources().getBoolean(
+                                com.android.internal.R.bool.config_windowIsRound);
+                        windowStyle.recycle();
+
+                        // detect emulator
+                        mIsEmulator = Build.HARDWARE.contains("goldfish");
+                        mIsCircularEmulator = SystemProperties.getBoolean(
+                                ViewRootImpl.PROPERTY_EMULATOR_CIRCULAR, false);
+
+                        // Add window
                         mLayout.type = mIWallpaperEngine.mWindowType;
                         mLayout.gravity = Gravity.START|Gravity.TOP;
                         mLayout.setTitle(WallpaperService.this.getClass().getName());
@@ -627,6 +688,11 @@
                     mSurfaceHolder.mSurfaceLock.lock();
                     mDrawingAllowed = true;
 
+                    if (!fixedSize) {
+                        mLayout.surfaceInsets.set(mIWallpaperEngine.mDisplayPadding);
+                    } else {
+                        mLayout.surfaceInsets.set(0, 0, 0, 0);
+                    }
                     final int relayoutResult = mSession.relayout(
                         mWindow, mWindow.mSeq, mLayout, mWidth, mHeight,
                             View.VISIBLE, 0, mWinFrame, mOverscanInsets, mContentInsets,
@@ -636,16 +702,39 @@
                             + ", frame=" + mWinFrame);
                     
                     int w = mWinFrame.width();
+                    int h = mWinFrame.height();
+
+                    if (!fixedSize) {
+                        final Rect padding = mIWallpaperEngine.mDisplayPadding;
+                        w += padding.left + padding.right;
+                        h += padding.top + padding.bottom;
+                        mOverscanInsets.left += padding.left;
+                        mOverscanInsets.top += padding.top;
+                        mOverscanInsets.right += padding.right;
+                        mOverscanInsets.bottom += padding.bottom;
+                        mContentInsets.left += padding.left;
+                        mContentInsets.top += padding.top;
+                        mContentInsets.right += padding.right;
+                        mContentInsets.bottom += padding.bottom;
+                        mStableInsets.left += padding.left;
+                        mStableInsets.top += padding.top;
+                        mStableInsets.right += padding.right;
+                        mStableInsets.bottom += padding.bottom;
+                    }
+
                     if (mCurWidth != w) {
                         sizeChanged = true;
                         mCurWidth = w;
                     }
-                    int h = mWinFrame.height();
                     if (mCurHeight != h) {
                         sizeChanged = true;
                         mCurHeight = h;
                     }
 
+                    insetsChanged |= !mDispatchedOverscanInsets.equals(mOverscanInsets);
+                    insetsChanged |= !mDispatchedContentInsets.equals(mContentInsets);
+                    insetsChanged |= !mDispatchedStableInsets.equals(mStableInsets);
+
                     mSurfaceHolder.setSurfaceFrameSize(w, h);
                     mSurfaceHolder.mSurfaceLock.unlock();
 
@@ -702,6 +791,25 @@
                             }
                         }
 
+                        if (insetsChanged) {
+                            mDispatchedOverscanInsets.set(mOverscanInsets);
+                            mDispatchedContentInsets.set(mContentInsets);
+                            mDispatchedStableInsets.set(mStableInsets);
+                            final boolean isRound = (mIsEmulator && mIsCircularEmulator)
+                                    || mWindowIsRound;
+                            mFinalSystemInsets.set(mDispatchedOverscanInsets);
+                            mFinalStableInsets.set(mDispatchedStableInsets);
+                            if (mOutsetBottom != null) {
+                                final DisplayMetrics metrics = getResources().getDisplayMetrics();
+                                mFinalSystemInsets.bottom =
+                                        ( (int) mOutsetBottom.getDimension(metrics) )
+                                        + mIWallpaperEngine.mDisplayPadding.bottom;
+                            }
+                            WindowInsets insets = new WindowInsets(mFinalSystemInsets,
+                                    null, mFinalStableInsets, isRound);
+                            onApplyWindowInsets(insets);
+                        }
+
                         if (redrawNeeded) {
                             onSurfaceRedrawNeeded(mSurfaceHolder);
                             SurfaceHolder.Callback callbacks[] = mSurfaceHolder.getCallbacks();
@@ -781,7 +889,7 @@
             mReportedVisible = false;
             updateSurface(false, false, false);
         }
-        
+
         void doDesiredSizeChanged(int desiredWidth, int desiredHeight) {
             if (!mDestroyed) {
                 if (DEBUG) Log.v(TAG, "onDesiredSizeChanged("
@@ -792,14 +900,24 @@
                 doOffsetsChanged(true);
             }
         }
-        
+
+        void doDisplayPaddingChanged(Rect padding) {
+            if (!mDestroyed) {
+                if (DEBUG) Log.v(TAG, "onDisplayPaddingChanged(" + padding + "): " + this);
+                if (!mIWallpaperEngine.mDisplayPadding.equals(padding)) {
+                    mIWallpaperEngine.mDisplayPadding.set(padding);
+                    updateSurface(true, false, false);
+                }
+            }
+        }
+
         void doVisibilityChanged(boolean visible) {
             if (!mDestroyed) {
                 mVisible = visible;
                 reportVisibility();
             }
         }
-        
+
         void reportVisibility() {
             if (!mDestroyed) {
                 boolean visible = mVisible && mScreenOn;
@@ -956,12 +1074,13 @@
         boolean mShownReported;
         int mReqWidth;
         int mReqHeight;
-        
+        final Rect mDisplayPadding = new Rect();
+
         Engine mEngine;
-        
+
         IWallpaperEngineWrapper(WallpaperService context,
                 IWallpaperConnection conn, IBinder windowToken,
-                int windowType, boolean isPreview, int reqWidth, int reqHeight) {
+                int windowType, boolean isPreview, int reqWidth, int reqHeight, Rect padding) {
             mCaller = new HandlerCaller(context, context.getMainLooper(), this, true);
             mConnection = conn;
             mWindowToken = windowToken;
@@ -969,16 +1088,22 @@
             mIsPreview = isPreview;
             mReqWidth = reqWidth;
             mReqHeight = reqHeight;
+            mDisplayPadding.set(padding);
             
             Message msg = mCaller.obtainMessage(DO_ATTACH);
             mCaller.sendMessage(msg);
         }
-        
+
         public void setDesiredSize(int width, int height) {
             Message msg = mCaller.obtainMessageII(DO_SET_DESIRED_SIZE, width, height);
             mCaller.sendMessage(msg);
         }
-        
+
+        public void setDisplayPadding(Rect padding) {
+            Message msg = mCaller.obtainMessageO(DO_SET_DISPLAY_PADDING, padding);
+            mCaller.sendMessage(msg);
+        }
+
         public void setVisibility(boolean visible) {
             Message msg = mCaller.obtainMessageI(MSG_VISIBILITY_CHANGED,
                     visible ? 1 : 0);
@@ -1041,6 +1166,9 @@
                     mEngine.doDesiredSizeChanged(message.arg1, message.arg2);
                     return;
                 }
+                case DO_SET_DISPLAY_PADDING: {
+                    mEngine.doDisplayPaddingChanged((Rect) message.obj);
+                }
                 case MSG_UPDATE_SURFACE:
                     mEngine.updateSurface(true, false, false);
                     break;
@@ -1102,9 +1230,9 @@
 
         @Override
         public void attach(IWallpaperConnection conn, IBinder windowToken,
-                int windowType, boolean isPreview, int reqWidth, int reqHeight) {
+                int windowType, boolean isPreview, int reqWidth, int reqHeight, Rect padding) {
             new IWallpaperEngineWrapper(mTarget, conn, windowToken,
-                    windowType, isPreview, reqWidth, reqHeight);
+                    windowType, isPreview, reqWidth, reqHeight, padding);
         }
     }
 
diff --git a/core/java/android/speech/tts/TextToSpeech.java b/core/java/android/speech/tts/TextToSpeech.java
index 7245975..9be220e 100644
--- a/core/java/android/speech/tts/TextToSpeech.java
+++ b/core/java/android/speech/tts/TextToSpeech.java
@@ -46,7 +46,6 @@
 import java.util.Map;
 import java.util.MissingResourceException;
 import java.util.Set;
-import java.util.TreeSet;
 
 /**
  *
@@ -578,7 +577,7 @@
          *
          * @deprecated Starting from API level 20, to select network synthesis, call
          * ({@link TextToSpeech#getVoices()}, find a suitable network voice
-         * ({@link Voice#getRequiresNetworkConnection()}) and pass it
+         * ({@link Voice#isNetworkConnectionRequired()}) and pass it
          * to {@link TextToSpeech#setVoice(Voice)}).
          */
         @Deprecated
@@ -596,7 +595,7 @@
 
          * @deprecated Starting from API level 20, to select embedded synthesis, call
          * ({@link TextToSpeech#getVoices()}, find a suitable embedded voice
-         * ({@link Voice#getRequiresNetworkConnection()}) and pass it
+         * ({@link Voice#isNetworkConnectionRequired()}) and pass it
          * to {@link TextToSpeech#setVoice(Voice)}).
          */
         @Deprecated
@@ -957,20 +956,18 @@
      *
      * @param text
      *            The string of text. Example: <code>"south_south_east"</code>
-     * @param filename
-     *            The full path to the sound file (for example:
-     *            "/sdcard/mysounds/hello.wav")
+     * @param file
+     *            File object pointing to the sound file.
      *
      * @return Code indicating success or failure. See {@link #ERROR} and {@link #SUCCESS}.
      */
-    public int addSpeech(CharSequence text, String filename) {
+    public int addSpeech(CharSequence text, File file) {
         synchronized (mStartLock) {
-            mUtterances.put(text, Uri.parse(filename));
+            mUtterances.put(text, Uri.fromFile(file));
             return SUCCESS;
         }
     }
 
-
     /**
      * Adds a mapping between a string of text and a sound resource in a
      * package. Use this to add custom earcons.
@@ -1017,7 +1014,11 @@
      *            "/sdcard/mysounds/tick.wav")
      *
      * @return Code indicating success or failure. See {@link #ERROR} and {@link #SUCCESS}.
+     *
+     * @deprecated As of API level 20, replaced by
+     *         {@link #addEarcon(String, File)}.
      */
+    @Deprecated
     public int addEarcon(String earcon, String filename) {
         synchronized(mStartLock) {
             mEarcons.put(earcon, Uri.parse(filename));
@@ -1025,6 +1026,27 @@
         }
     }
 
+    /**
+     * Adds a mapping between a string of text and a sound file.
+     * Use this to add custom earcons.
+     *
+     * @see #playEarcon(String, int, HashMap)
+     *
+     * @param earcon
+     *            The name of the earcon.
+     *            Example: <code>"[tick]"</code>
+     * @param file
+     *            File object pointing to the sound file.
+     *
+     * @return Code indicating success or failure. See {@link #ERROR} and {@link #SUCCESS}.
+     */
+    public int addEarcon(String earcon, File file) {
+        synchronized(mStartLock) {
+            mEarcons.put(earcon, Uri.fromFile(file));
+            return SUCCESS;
+        }
+    }
+
     private Uri makeResourceUri(String packageName, int resourceId) {
         return new Uri.Builder()
                 .scheme(ContentResolver.SCHEME_ANDROID_RESOURCE)
@@ -1061,7 +1083,7 @@
      */
     public int speak(final CharSequence text,
                      final int queueMode,
-                     final HashMap<String, String> params,
+                     final Bundle params,
                      final String utteranceId) {
         return runAction(new Action<Integer>() {
             @Override
@@ -1103,11 +1125,11 @@
      *
      * @return {@link #ERROR} or {@link #SUCCESS} of <b>queuing</b> the speak operation.
      * @deprecated As of API level 20, replaced by
-     *         {@link #speak(CharSequence, int, HashMap, String)}.
+     *         {@link #speak(CharSequence, int, Bundle, String)}.
      */
     @Deprecated
     public int speak(final String text, final int queueMode, final HashMap<String, String> params) {
-        return speak(text, queueMode, params,
+        return speak(text, queueMode, convertParamsHashMaptoBundle(params),
                      params == null ? null : params.get(Engine.KEY_PARAM_UTTERANCE_ID));
     }
 
@@ -1135,7 +1157,7 @@
      * @return {@link #ERROR} or {@link #SUCCESS} of <b>queuing</b> the playEarcon operation.
      */
     public int playEarcon(final String earcon, final int queueMode,
-            final HashMap<String, String> params, final String utteranceId) {
+            final Bundle params, final String utteranceId) {
         return runAction(new Action<Integer>() {
             @Override
             public Integer run(ITextToSpeechService service) throws RemoteException {
@@ -1173,12 +1195,12 @@
      *
      * @return {@link #ERROR} or {@link #SUCCESS} of <b>queuing</b> the playEarcon operation.
      * @deprecated As of API level 20, replaced by
-     *         {@link #playEarcon(String, int, HashMap, String)}.
+     *         {@link #playEarcon(String, int, Bundle, String)}.
      */
     @Deprecated
     public int playEarcon(final String earcon, final int queueMode,
             final HashMap<String, String> params) {
-        return playEarcon(earcon, queueMode, params,
+        return playEarcon(earcon, queueMode, convertParamsHashMaptoBundle(params),
                           params == null ? null : params.get(Engine.KEY_PARAM_UTTERANCE_ID));
     }
 
@@ -1544,10 +1566,10 @@
             @Override
             public Set<Locale> run(ITextToSpeechService service) throws RemoteException {
                 List<Voice> voices = service.getVoices();
-                if (voices != null) {
-                    return new TreeSet<Locale>();
+                if (voices == null) {
+                    return new HashSet<Locale>();
                 }
-                TreeSet<Locale> locales = new TreeSet<Locale>();
+                HashSet<Locale> locales = new HashSet<Locale>();
                 for (Voice voice : voices) {
                     locales.add(voice.getLocale());
                 }
@@ -1570,7 +1592,7 @@
             @Override
             public Set<Voice> run(ITextToSpeechService service) throws RemoteException {
                 List<Voice> voices = service.getVoices();
-                return (voices != null)  ? new TreeSet<Voice>(voices) : new TreeSet<Voice>();
+                return (voices != null)  ? new HashSet<Voice>(voices) : new HashSet<Voice>();
             }
         }, null, "getVoices");
     }
@@ -1757,22 +1779,20 @@
      *            must be prefixed by the name of the engine they are intended for. For example
      *            the keys "com.svox.pico_foo" and "com.svox.pico:bar" will be passed to the
      *            engine named "com.svox.pico" if it is being used.
-     * @param filename Absolute file filename to write the generated audio data to.It should be
-     *            something like "/sdcard/myappsounds/mysound.wav".
+     * @param file File to write the generated audio data to.
      * @param utteranceId An unique identifier for this request.
      * @return {@link #ERROR} or {@link #SUCCESS} of <b>queuing</b> the synthesizeToFile operation.
      */
-    public int synthesizeToFile(final CharSequence text, final HashMap<String, String> params,
-            final String filename, final String utteranceId) {
+    public int synthesizeToFile(final CharSequence text, final Bundle params,
+            final File file, final String utteranceId) {
         return runAction(new Action<Integer>() {
             @Override
             public Integer run(ITextToSpeechService service) throws RemoteException {
                 ParcelFileDescriptor fileDescriptor;
                 int returnValue;
                 try {
-                    File file = new File(filename);
                     if(file.exists() && !file.canWrite()) {
-                        Log.e(TAG, "Can't write to " + filename);
+                        Log.e(TAG, "Can't write to " + file);
                         return ERROR;
                     }
                     fileDescriptor = ParcelFileDescriptor.open(file,
@@ -1784,10 +1804,10 @@
                     fileDescriptor.close();
                     return returnValue;
                 } catch (FileNotFoundException e) {
-                    Log.e(TAG, "Opening file " + filename + " failed", e);
+                    Log.e(TAG, "Opening file " + file + " failed", e);
                     return ERROR;
                 } catch (IOException e) {
-                    Log.e(TAG, "Closing file " + filename + " failed", e);
+                    Log.e(TAG, "Closing file " + file + " failed", e);
                     return ERROR;
                 }
             }
@@ -1817,16 +1837,18 @@
      *
      * @return {@link #ERROR} or {@link #SUCCESS} of <b>queuing</b> the synthesizeToFile operation.
      * @deprecated As of API level 20, replaced by
-     *         {@link #synthesizeToFile(CharSequence, HashMap, String, String)}.
+     *         {@link #synthesizeToFile(CharSequence, Bundle, File, String)}.
      */
+    @Deprecated
     public int synthesizeToFile(final String text, final HashMap<String, String> params,
             final String filename) {
-        return synthesizeToFile(text, params, filename, params.get(Engine.KEY_PARAM_UTTERANCE_ID));
+        return synthesizeToFile(text, convertParamsHashMaptoBundle(params),
+                new File(filename), params.get(Engine.KEY_PARAM_UTTERANCE_ID));
     }
 
-    private Bundle getParams(HashMap<String, String> params) {
+    private Bundle convertParamsHashMaptoBundle(HashMap<String, String> params) {
         if (params != null && !params.isEmpty()) {
-            Bundle bundle = new Bundle(mParams);
+            Bundle bundle = new Bundle();
             copyIntParam(bundle, params, Engine.KEY_PARAM_STREAM);
             copyIntParam(bundle, params, Engine.KEY_PARAM_SESSION_ID);
             copyStringParam(bundle, params, Engine.KEY_PARAM_UTTERANCE_ID);
@@ -1852,11 +1874,85 @@
             }
 
             return bundle;
+        }
+        return null;
+    }
+
+    private Bundle getParams(Bundle params) {
+        if (params != null && !params.isEmpty()) {
+            Bundle bundle = new Bundle(mParams);
+            bundle.putAll(params);
+
+            verifyIntegerBundleParam(bundle, Engine.KEY_PARAM_STREAM);
+            verifyIntegerBundleParam(bundle, Engine.KEY_PARAM_SESSION_ID);
+            verifyStringBundleParam(bundle, Engine.KEY_PARAM_UTTERANCE_ID);
+            verifyFloatBundleParam(bundle, Engine.KEY_PARAM_VOLUME);
+            verifyFloatBundleParam(bundle, Engine.KEY_PARAM_PAN);
+
+            // Copy feature strings defined by the framework.
+            verifyBooleanBundleParam(bundle, Engine.KEY_FEATURE_NETWORK_SYNTHESIS);
+            verifyBooleanBundleParam(bundle, Engine.KEY_FEATURE_EMBEDDED_SYNTHESIS);
+            verifyIntegerBundleParam(bundle, Engine.KEY_FEATURE_NETWORK_TIMEOUT_MS);
+            verifyIntegerBundleParam(bundle, Engine.KEY_FEATURE_NETWORK_RETRIES_COUNT);
+
+            return bundle;
         } else {
             return mParams;
         }
     }
 
+    private static boolean verifyIntegerBundleParam(Bundle bundle, String key) {
+        if (bundle.containsKey(key)) {
+            if (!(bundle.get(key) instanceof Integer ||
+                    bundle.get(key) instanceof Long)) {
+                bundle.remove(key);
+                Log.w(TAG, "Synthesis request paramter " + key + " containst value "
+                        + " with invalid type. Should be an Integer or a Long");
+                return false;
+            }
+        }
+        return true;
+    }
+
+    private static boolean verifyStringBundleParam(Bundle bundle, String key) {
+        if (bundle.containsKey(key)) {
+            if (!(bundle.get(key) instanceof String)) {
+                bundle.remove(key);
+                Log.w(TAG, "Synthesis request paramter " + key + " containst value "
+                        + " with invalid type. Should be a String");
+                return false;
+            }
+        }
+        return true;
+    }
+
+    private static boolean verifyBooleanBundleParam(Bundle bundle, String key) {
+        if (bundle.containsKey(key)) {
+            if (!(bundle.get(key) instanceof Boolean ||
+                    bundle.get(key) instanceof String)) {
+                bundle.remove(key);
+                Log.w(TAG, "Synthesis request paramter " + key + " containst value "
+                        + " with invalid type. Should be a Boolean or String");
+                return false;
+            }
+        }
+        return true;
+    }
+
+
+    private static boolean verifyFloatBundleParam(Bundle bundle, String key) {
+        if (bundle.containsKey(key)) {
+            if (!(bundle.get(key) instanceof Float ||
+                    bundle.get(key) instanceof Double)) {
+                bundle.remove(key);
+                Log.w(TAG, "Synthesis request paramter " + key + " containst value "
+                        + " with invalid type. Should be a Float or a Double");
+                return false;
+            }
+        }
+        return true;
+    }
+
     private void copyStringParam(Bundle bundle, HashMap<String, String> params, String key) {
         String value = params.get(key);
         if (value != null) {
diff --git a/core/java/android/speech/tts/TextToSpeechService.java b/core/java/android/speech/tts/TextToSpeechService.java
index 4fea109..d00a433 100644
--- a/core/java/android/speech/tts/TextToSpeechService.java
+++ b/core/java/android/speech/tts/TextToSpeechService.java
@@ -84,7 +84,7 @@
  * the following methods:
  * <ul>
  * <li>{@link #onGetVoices()}</li>
- * <li>{@link #isValidVoiceName(String)}</li>
+ * <li>{@link #onIsValidVoiceName(String)}</li>
  * <li>{@link #onLoadVoice(String)}</li>
  * <li>{@link #onGetDefaultVoiceNameFor(String, String, String)}</li>
  * </ul>
@@ -278,7 +278,7 @@
      *
      * @return A list of voices supported.
      */
-    protected List<Voice> onGetVoices() {
+    public List<Voice> onGetVoices() {
         // Enumerate all locales and check if they are available
         ArrayList<Voice> voices = new ArrayList<Voice>();
         for (Locale locale : Locale.getAvailableLocales()) {
@@ -335,7 +335,7 @@
         }
         Locale properLocale = TtsEngines.normalizeTTSLocale(iso3Locale);
         String voiceName = properLocale.toLanguageTag();
-        if (isValidVoiceName(voiceName) == TextToSpeech.SUCCESS) {
+        if (onIsValidVoiceName(voiceName) == TextToSpeech.SUCCESS) {
             return voiceName;
         } else {
             return null;
@@ -357,7 +357,7 @@
      * @param voiceName Name of the voice.
      * @return {@link TextToSpeech#ERROR} or {@link TextToSpeech#SUCCESS}.
      */
-    protected int onLoadVoice(String voiceName) {
+    public int onLoadVoice(String voiceName) {
         Locale locale = Locale.forLanguageTag(voiceName);
         if (locale == null) {
             return TextToSpeech.ERROR;
@@ -388,7 +388,7 @@
      * @param voiceName Name of the voice.
      * @return {@link TextToSpeech#ERROR} or {@link TextToSpeech#SUCCESS}.
      */
-    protected int isValidVoiceName(String voiceName) {
+    public int onIsValidVoiceName(String voiceName) {
         Locale locale = Locale.forLanguageTag(voiceName);
         if (locale == null) {
             return TextToSpeech.ERROR;
@@ -1275,7 +1275,7 @@
             if (!checkNonNull(voiceName)) {
                 return TextToSpeech.ERROR;
             }
-            int retVal = isValidVoiceName(voiceName);
+            int retVal = onIsValidVoiceName(voiceName);
 
             if (retVal == TextToSpeech.SUCCESS) {
                 SpeechItem item = new LoadVoiceItem(caller, Binder.getCallingUid(),
diff --git a/core/java/android/speech/tts/Voice.java b/core/java/android/speech/tts/Voice.java
index a97141c..a1fa51d 100644
--- a/core/java/android/speech/tts/Voice.java
+++ b/core/java/android/speech/tts/Voice.java
@@ -162,7 +162,7 @@
     /**
      * @return Does the Voice require a network connection to work.
      */
-    public boolean getRequiresNetworkConnection() {
+    public boolean isNetworkConnectionRequired() {
         return mRequiresNetworkConnection;
     }
 
diff --git a/core/java/android/text/Layout.java b/core/java/android/text/Layout.java
index 7dce348..2b53c48 100644
--- a/core/java/android/text/Layout.java
+++ b/core/java/android/text/Layout.java
@@ -727,10 +727,9 @@
         int[] runs = dirs.mDirections;
         int lineStart = getLineStart(line);
         for (int i = 0; i < runs.length; i += 2) {
-            int start = lineStart + (runs[i] & RUN_LENGTH_MASK);
-            // No need to test the end as an offset after the last run should return the value
-            // corresponding of the last run
-            if (offset >= start) {
+            int start = lineStart + runs[i];
+            int limit = start + (runs[i+1] & RUN_LENGTH_MASK);
+            if (offset >= start && offset < limit) {
                 int level = (runs[i+1] >>> RUN_LEVEL_SHIFT) & RUN_LEVEL_MASK;
                 return ((level & 1) != 0);
             }
diff --git a/core/java/android/text/Selection.java b/core/java/android/text/Selection.java
index 679e2cc..3222dbf 100644
--- a/core/java/android/text/Selection.java
+++ b/core/java/android/text/Selection.java
@@ -116,7 +116,8 @@
 
     /**
      * Move the cursor to the buffer offset physically above the current
-     * offset, or return false if the cursor is already on the top line.
+     * offset, to the beginning if it is on the top line but not at the
+     * start, or return false if the cursor is already on the top line.
      */
     public static boolean moveUp(Spannable text, Layout layout) {
         int start = getSelectionStart(text);
@@ -149,6 +150,9 @@
 
                 setSelection(text, move);
                 return true;
+            } else if (end != 0) {
+                setSelection(text, 0);
+                return true;
             }
         }
 
@@ -157,7 +161,9 @@
 
     /**
      * Move the cursor to the buffer offset physically below the current
-     * offset, or return false if the cursor is already on the bottom line.
+     * offset, to the end of the buffer if it is on the bottom line but
+     * not at the end, or return false if the cursor is already at the
+     * end of the buffer.
      */
     public static boolean moveDown(Spannable text, Layout layout) {
         int start = getSelectionStart(text);
@@ -190,6 +196,9 @@
 
                 setSelection(text, move);
                 return true;
+            } else if (end != text.length()) {
+                setSelection(text, text.length());
+                return true;
             }
         }
 
diff --git a/core/java/android/text/StaticLayout.java b/core/java/android/text/StaticLayout.java
index aecf488..e82057c 100644
--- a/core/java/android/text/StaticLayout.java
+++ b/core/java/android/text/StaticLayout.java
@@ -262,6 +262,8 @@
             int fit = paraStart;
             float fitWidth = w;
             int fitAscent = 0, fitDescent = 0, fitTop = 0, fitBottom = 0;
+            // same as fitWidth but not including any trailing whitespace
+            float fitWidthGraphing = w;
 
             boolean hasTabOrEmoji = false;
             boolean hasTab = false;
@@ -346,6 +348,9 @@
 
                     if (w <= width || isSpaceOrTab) {
                         fitWidth = w;
+                        if (!isSpaceOrTab) {
+                            fitWidthGraphing = w;
+                        }
                         fit = j + 1;
 
                         if (fmTop < fitTop)
@@ -365,7 +370,7 @@
                                 breakOpp[breakOppIndex] == j - paraStart + 1;
 
                         if (isLineBreak) {
-                            okWidth = w;
+                            okWidth = fitWidthGraphing;
                             ok = j + 1;
 
                             if (fitTop < okTop)
@@ -426,6 +431,7 @@
                         j = here - 1; // restart j-span loop from here, compensating for the j++
                         ok = fit = here;
                         w = 0;
+                        fitWidthGraphing = w;
                         fitAscent = fitDescent = fitTop = fitBottom = 0;
                         okAscent = okDescent = okTop = okBottom = 0;
 
@@ -842,7 +848,7 @@
     void prepare() {
         mMeasured = MeasuredText.obtain();
     }
-    
+
     void finish() {
         mMeasured = MeasuredText.recycle(mMeasured);
     }
diff --git a/core/java/android/text/format/TimeFormatter.java b/core/java/android/text/format/TimeFormatter.java
index ec79b36..3a63805 100644
--- a/core/java/android/text/format/TimeFormatter.java
+++ b/core/java/android/text/format/TimeFormatter.java
@@ -22,8 +22,7 @@
 
 import android.content.res.Resources;
 
-import java.nio.ByteBuffer;
-import java.nio.charset.StandardCharsets;
+import java.nio.CharBuffer;
 import java.util.Formatter;
 import java.util.Locale;
 import java.util.TimeZone;
@@ -31,15 +30,13 @@
 import libcore.util.ZoneInfo;
 
 /**
- * Formatting logic for {@link Time}. Contains a port of Bionic's broken strftime_tz to Java. The
- * main issue with this implementation is the treatment of characters as ASCII, despite returning
- * localized (UTF-16) strings from the LocaleData.
+ * Formatting logic for {@link Time}. Contains a port of Bionic's broken strftime_tz to Java.
  *
  * <p>This class is not thread safe.
  */
 class TimeFormatter {
-    // An arbitrary value outside the range representable by a byte / ASCII character code.
-    private static final int FORCE_LOWER_CASE = 0x100;
+    // An arbitrary value outside the range representable by a char.
+    private static final int FORCE_LOWER_CASE = -1;
 
     private static final int SECSPERMIN = 60;
     private static final int MINSPERHOUR = 60;
@@ -62,10 +59,9 @@
     private final String dateTimeFormat;
     private final String timeOnlyFormat;
     private final String dateOnlyFormat;
-    private final Locale locale;
 
     private StringBuilder outputBuilder;
-    private Formatter outputFormatter;
+    private Formatter numberFormatter;
 
     public TimeFormatter() {
         synchronized (TimeFormatter.class) {
@@ -84,7 +80,6 @@
             this.dateTimeFormat = sDateTimeFormat;
             this.timeOnlyFormat = sTimeOnlyFormat;
             this.dateOnlyFormat = sDateOnlyFormat;
-            this.locale = locale;
             localeData = sLocaleData;
         }
     }
@@ -97,19 +92,21 @@
             StringBuilder stringBuilder = new StringBuilder();
 
             outputBuilder = stringBuilder;
-            outputFormatter = new Formatter(stringBuilder, locale);
+            // This uses the US locale because number localization is handled separately (see below)
+            // and locale sensitive strings are output directly using outputBuilder.
+            numberFormatter = new Formatter(stringBuilder, Locale.US);
 
             formatInternal(pattern, wallTime, zoneInfo);
             String result = stringBuilder.toString();
             // This behavior is the source of a bug since some formats are defined as being
-            // in ASCII. Generally localization is very broken.
+            // in ASCII and not localized.
             if (localeData.zeroDigit != '0') {
                 result = localizeDigits(result);
             }
             return result;
         } finally {
             outputBuilder = null;
-            outputFormatter = null;
+            numberFormatter = null;
         }
     }
 
@@ -132,38 +129,30 @@
      * {@link #outputBuilder}.
      */
     private void formatInternal(String pattern, ZoneInfo.WallTime wallTime, ZoneInfo zoneInfo) {
-        // Convert to ASCII bytes to be compatible with old implementation behavior.
-        byte[] bytes = pattern.getBytes(StandardCharsets.US_ASCII);
-        if (bytes.length == 0) {
-            return;
-        }
-
-        ByteBuffer formatBuffer = ByteBuffer.wrap(bytes);
+        CharBuffer formatBuffer = CharBuffer.wrap(pattern);
         while (formatBuffer.remaining() > 0) {
-            boolean outputCurrentByte = true;
-            char currentByteAsChar = convertToChar(formatBuffer.get(formatBuffer.position()));
-            if (currentByteAsChar == '%') {
-                outputCurrentByte = handleToken(formatBuffer, wallTime, zoneInfo);
+            boolean outputCurrentChar = true;
+            char currentChar = formatBuffer.get(formatBuffer.position());
+            if (currentChar == '%') {
+                outputCurrentChar = handleToken(formatBuffer, wallTime, zoneInfo);
             }
-            if (outputCurrentByte) {
-                currentByteAsChar = convertToChar(formatBuffer.get(formatBuffer.position()));
-                outputBuilder.append(currentByteAsChar);
+            if (outputCurrentChar) {
+                outputBuilder.append(formatBuffer.get(formatBuffer.position()));
             }
-
             formatBuffer.position(formatBuffer.position() + 1);
         }
     }
 
-    private boolean handleToken(ByteBuffer formatBuffer, ZoneInfo.WallTime wallTime,
+    private boolean handleToken(CharBuffer formatBuffer, ZoneInfo.WallTime wallTime,
             ZoneInfo zoneInfo) {
 
-        // The byte at formatBuffer.position() is expected to be '%' at this point.
+        // The char at formatBuffer.position() is expected to be '%' at this point.
         int modifier = 0;
         while (formatBuffer.remaining() > 1) {
-            // Increment the position then get the new current byte.
+            // Increment the position then get the new current char.
             formatBuffer.position(formatBuffer.position() + 1);
-            char currentByteAsChar = convertToChar(formatBuffer.get(formatBuffer.position()));
-            switch (currentByteAsChar) {
+            char currentChar = formatBuffer.get(formatBuffer.position());
+            switch (currentChar) {
                 case 'A':
                     modifyAndAppend((wallTime.getWeekDay() < 0
                                     || wallTime.getWeekDay() >= DAYSPERWEEK)
@@ -206,7 +195,7 @@
                     formatInternal("%m/%d/%y", wallTime, zoneInfo);
                     return false;
                 case 'd':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             wallTime.getMonthDay());
                     return false;
                 case 'E':
@@ -218,46 +207,46 @@
                 case '0':
                 case '^':
                 case '#':
-                    modifier = currentByteAsChar;
+                    modifier = currentChar;
                     continue;
                 case 'e':
-                    outputFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"),
                             wallTime.getMonthDay());
                     return false;
                 case 'F':
                     formatInternal("%Y-%m-%d", wallTime, zoneInfo);
                     return false;
                 case 'H':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             wallTime.getHour());
                     return false;
                 case 'I':
                     int hour = (wallTime.getHour() % 12 != 0) ? (wallTime.getHour() % 12) : 12;
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), hour);
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), hour);
                     return false;
                 case 'j':
                     int yearDay = wallTime.getYearDay() + 1;
-                    outputFormatter.format(getFormat(modifier, "%03d", "%3d", "%d", "%03d"),
+                    numberFormatter.format(getFormat(modifier, "%03d", "%3d", "%d", "%03d"),
                             yearDay);
                     return false;
                 case 'k':
-                    outputFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"),
                             wallTime.getHour());
                     return false;
                 case 'l':
                     int n2 = (wallTime.getHour() % 12 != 0) ? (wallTime.getHour() % 12) : 12;
-                    outputFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"), n2);
+                    numberFormatter.format(getFormat(modifier, "%2d", "%2d", "%d", "%02d"), n2);
                     return false;
                 case 'M':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             wallTime.getMinute());
                     return false;
                 case 'm':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             wallTime.getMonth() + 1);
                     return false;
                 case 'n':
-                    modifyAndAppend("\n", modifier);
+                    outputBuilder.append('\n');
                     return false;
                 case 'p':
                     modifyAndAppend((wallTime.getHour() >= (HOURSPERDAY / 2)) ? localeData.amPm[1]
@@ -274,27 +263,27 @@
                     formatInternal("%I:%M:%S %p", wallTime, zoneInfo);
                     return false;
                 case 'S':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             wallTime.getSecond());
                     return false;
                 case 's':
                     int timeInSeconds = wallTime.mktime(zoneInfo);
-                    modifyAndAppend(Integer.toString(timeInSeconds), modifier);
+                    outputBuilder.append(Integer.toString(timeInSeconds));
                     return false;
                 case 'T':
                     formatInternal("%H:%M:%S", wallTime, zoneInfo);
                     return false;
                 case 't':
-                    modifyAndAppend("\t", modifier);
+                    outputBuilder.append('\t');
                     return false;
                 case 'U':
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"),
                             (wallTime.getYearDay() + DAYSPERWEEK - wallTime.getWeekDay())
                                     / DAYSPERWEEK);
                     return false;
                 case 'u':
                     int day = (wallTime.getWeekDay() == 0) ? DAYSPERWEEK : wallTime.getWeekDay();
-                    outputFormatter.format("%d", day);
+                    numberFormatter.format("%d", day);
                     return false;
                 case 'V':   /* ISO 8601 week number */
                 case 'G':   /* ISO 8601 year (four digits) */
@@ -326,9 +315,9 @@
                         --year;
                         yday += isLeap(year) ? DAYSPERLYEAR : DAYSPERNYEAR;
                     }
-                    if (currentByteAsChar == 'V') {
-                        outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), w);
-                    } else if (currentByteAsChar == 'g') {
+                    if (currentChar == 'V') {
+                        numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), w);
+                    } else if (currentChar == 'g') {
                         outputYear(year, false, true, modifier);
                     } else {
                         outputYear(year, true, true, modifier);
@@ -342,10 +331,10 @@
                     int n = (wallTime.getYearDay() + DAYSPERWEEK - (
                                     wallTime.getWeekDay() != 0 ? (wallTime.getWeekDay() - 1)
                                             : (DAYSPERWEEK - 1))) / DAYSPERWEEK;
-                    outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), n);
+                    numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), n);
                     return false;
                 case 'w':
-                    outputFormatter.format("%d", wallTime.getWeekDay());
+                    numberFormatter.format("%d", wallTime.getWeekDay());
                     return false;
                 case 'X':
                     formatInternal(timeOnlyFormat, wallTime, zoneInfo);
@@ -371,17 +360,17 @@
                         return false;
                     }
                     int diff = wallTime.getGmtOffset();
-                    String sign;
+                    char sign;
                     if (diff < 0) {
-                        sign = "-";
+                        sign = '-';
                         diff = -diff;
                     } else {
-                        sign = "+";
+                        sign = '+';
                     }
-                    modifyAndAppend(sign, modifier);
+                    outputBuilder.append(sign);
                     diff /= SECSPERMIN;
                     diff = (diff / MINSPERHOUR) * 100 + (diff % MINSPERHOUR);
-                    outputFormatter.format(getFormat(modifier, "%04d", "%4d", "%d", "%04d"), diff);
+                    numberFormatter.format(getFormat(modifier, "%04d", "%4d", "%d", "%04d"), diff);
                     return false;
                 }
                 case '+':
@@ -422,7 +411,6 @@
                 break;
             default:
                 outputBuilder.append(str);
-
         }
     }
 
@@ -443,14 +431,14 @@
         }
         if (outputTop) {
             if (lead == 0 && trail < 0) {
-                modifyAndAppend("-0", modifier);
+                outputBuilder.append("-0");
             } else {
-                outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), lead);
+                numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), lead);
             }
         }
         if (outputBottom) {
             int n = ((trail < 0) ? -trail : trail);
-            outputFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), n);
+            numberFormatter.format(getFormat(modifier, "%02d", "%2d", "%d", "%02d"), n);
         }
     }
 
@@ -472,24 +460,24 @@
     }
 
     /**
-     * A broken implementation of {@link Character#isUpperCase(char)} that assumes ASCII in order to
-     * be compatible with the old native implementation.
+     * A broken implementation of {@link Character#isUpperCase(char)} that assumes ASCII codes in
+     * order to be compatible with the old native implementation.
      */
     private static boolean brokenIsUpper(char toCheck) {
         return toCheck >= 'A' && toCheck <= 'Z';
     }
 
     /**
-     * A broken implementation of {@link Character#isLowerCase(char)} that assumes ASCII in order to
-     * be compatible with the old native implementation.
+     * A broken implementation of {@link Character#isLowerCase(char)} that assumes ASCII codes in
+     * order to be compatible with the old native implementation.
      */
     private static boolean brokenIsLower(char toCheck) {
         return toCheck >= 'a' && toCheck <= 'z';
     }
 
     /**
-     * A broken implementation of {@link Character#toLowerCase(char)} that assumes ASCII in order to
-     * be compatible with the old native implementation.
+     * A broken implementation of {@link Character#toLowerCase(char)} that assumes ASCII codes in
+     * order to be compatible with the old native implementation.
      */
     private static char brokenToLower(char input) {
         if (input >= 'A' && input <= 'Z') {
@@ -499,8 +487,8 @@
     }
 
     /**
-     * A broken implementation of {@link Character#toUpperCase(char)} that assumes ASCII in order to
-     * be compatible with the old native implementation.
+     * A broken implementation of {@link Character#toUpperCase(char)} that assumes ASCII codes in
+     * order to be compatible with the old native implementation.
      */
     private static char brokenToUpper(char input) {
         if (input >= 'a' && input <= 'z') {
@@ -509,11 +497,4 @@
         return input;
     }
 
-    /**
-     * Safely convert a byte containing an ASCII character to a char, even for character codes
-     * > 127.
-     */
-    private static char convertToChar(byte b) {
-        return (char) (b & 0xFF);
-    }
 }
diff --git a/core/java/android/text/style/TtsSpan.java b/core/java/android/text/style/TtsSpan.java
index cb447fd..342a183 100644
--- a/core/java/android/text/style/TtsSpan.java
+++ b/core/java/android/text/style/TtsSpan.java
@@ -26,10 +26,14 @@
 
 /**
  * A span that supplies additional meta-data for the associated text intended
- * for text-to-speech engines.  If the text is being processed by a
+ * for text-to-speech engines. If the text is being processed by a
  * text-to-speech engine, the engine may use the data in this span in addition
  * to or instead of its associated text.
  *
+ * Each instance of a TtsSpan has a type, for example {@link #TYPE_DATE}
+ * or {@link #TYPE_MEASURE}. And a list of arguments, provided as
+ * key-value pairs in a bundle.
+ *
  * The inner classes are there for convenience and provide builders for each
  * TtsSpan type.
  */
@@ -39,7 +43,7 @@
 
     /**
      * This span type can be used to add morphosyntactic features to the text it
-     * spans over, or synthesize a something else than the spanned text.  Use
+     * spans over, or synthesize a something else than the spanned text. Use
      * the argument {@link #ARG_TEXT} to set a different text.
      * Accepts the arguments {@link #ARG_GENDER},
      * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
@@ -48,7 +52,7 @@
     public static final String TYPE_TEXT = "android.type.text";
 
     /**
-     * The text associated with this span is a cardinal.  Must include the
+     * The text associated with this span is a cardinal. Must include the
      * number to be synthesized with {@link #ARG_NUMBER}.
      * Also accepts the arguments {@link #ARG_GENDER},
      * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
@@ -108,12 +112,12 @@
     public static final String TYPE_TIME = "android.type.time";
 
     /**
-     * The text associated with this span is a date. All arguments are optional,
-     * but at least one has to be provided: {@link #ARG_WEEKDAY},
-     * {@link #ARG_DAY}, {@link #ARG_MONTH} and {@link #ARG_YEAR}.
-     * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * The text associated with this span is a date. At least one of the
+     * arguments {@link #ARG_MONTH} and {@link #ARG_YEAR} has to be provided.
+     * The argument {@link #ARG_DAY} is optional if {@link #ARG_MONTH} is set.
+     * The argument {@link #ARG_WEEKDAY} is optional if {@link #ARG_DAY} is set.
+     * Also accepts the arguments {@link #ARG_GENDER}, {@link #ARG_ANIMACY},
+     * {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_DATE = "android.type.date";
 
@@ -121,13 +125,11 @@
      * The text associated with this span is a telephone number. The argument
      * {@link #ARG_NUMBER_PARTS} is required. {@link #ARG_COUNTRY_CODE} and
      * {@link #ARG_EXTENSION} are optional.
-     * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * Also accepts the arguments {@link #ARG_GENDER}, {@link #ARG_ANIMACY},
+     * {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_TELEPHONE = "android.type.telephone";
 
-
     /**
      * The text associated with this span is a URI (can be used for URLs and
      * email addresses). The full schema for URLs, which email addresses can
@@ -138,9 +140,8 @@
      * {@link #ARG_PROTOCOL}, {@link #ARG_USERNAME}, {@link #ARG_PASSWORD},
      * {@link #ARG_DOMAIN}, {@link #ARG_PORT}, {@link #ARG_PATH},
      * {@link #ARG_QUERY_STRING} and {@link #ARG_FRAGMENT_ID}.
-     * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * Also accepts the arguments {@link #ARG_GENDER}, {@link #ARG_ANIMACY},
+     * {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_ELECTRONIC = "android.type.electronic";
 
@@ -149,18 +150,16 @@
      * with the same arguments as {@link #TYPE_DECIMAL}.
      * {@link #ARG_CURRENCY} is used to set the currency. {@link #ARG_QUANTITY}
      * is optional.
-     * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * Also accepts the arguments {@link #ARG_GENDER}, {@link #ARG_ANIMACY},
+     * {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_MONEY = "android.type.money";
 
     /**
      * The text associated with this span is a series of digits that have to be
-     * read sequentially. {@link #ARG_DIGITS} is required.
-     * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * read sequentially. The digits can be set with {@link #ARG_DIGITS}.
+     * Also accepts the arguments {@link #ARG_GENDER}, {@link #ARG_ANIMACY},
+     * {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_DIGITS = "android.type.digits";
 
@@ -169,13 +168,12 @@
      * be read verbatim. The engine will attempt to ready out any character like
      * punctuation but excluding whitespace. {@link #ARG_VERBATIM} is required.
      * Also accepts the arguments {@link #ARG_GENDER},
-     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and
-     * {@link #ARG_CASE}.
+     * {@link #ARG_ANIMACY}, {@link #ARG_MULTIPLICITY} and {@link #ARG_CASE}.
      */
     public static final String TYPE_VERBATIM = "android.type.verbatim";
 
     /**
-     * String argument supplying gender information.  Can be any of
+     * String argument supplying gender information. Can be any of
      * {@link #GENDER_NEUTRAL}, {@link #GENDER_MALE} and
      * {@link #GENDER_FEMALE}.
      */
@@ -186,7 +184,7 @@
     public static final String GENDER_FEMALE = "android.female";
 
     /**
-     * String argument supplying animacy information.  Can be
+     * String argument supplying animacy information. Can be
      * {@link #ANIMACY_ANIMATE} or
      * {@link #ANIMACY_INANIMATE}
      */
@@ -196,9 +194,8 @@
     public static final String ANIMACY_INANIMATE = "android.inanimate";
 
     /**
-     * String argument supplying multiplicity information.  Can be any of
-     * {@link #MULTIPLICITY_SINGLE},
-     * {@link #MULTIPLICITY_DUAL} and
+     * String argument supplying multiplicity information. Can be any of
+     * {@link #MULTIPLICITY_SINGLE}, {@link #MULTIPLICITY_DUAL} and
      * {@link #MULTIPLICITY_PLURAL}
      */
     public static final String ARG_MULTIPLICITY = "android.arg.multiplicity";
@@ -208,16 +205,14 @@
     public static final String MULTIPLICITY_PLURAL = "android.plural";
 
     /**
-     * String argument supplying case information.  Can be any of
-     * {@link #CASE_NOMINATIVE}, {@link #CASE_ACCUSATIVE},
-     * {@link #CASE_DATIVE}, {@link #CASE_ABLATIVE},
-     * {@link #CASE_GENITIVE}, {@link #CASE_VOCATIVE},
-     * {@link #CASE_LOCATIVE} and
-     * {@link #CASE_INSTRUMENTAL}
+     * String argument supplying case information. Can be any of
+     * {@link #CASE_NOMINATIVE}, {@link #CASE_ACCUSATIVE}, {@link #CASE_DATIVE},
+     * {@link #CASE_ABLATIVE}, {@link #CASE_GENITIVE}, {@link #CASE_VOCATIVE},
+     * {@link #CASE_LOCATIVE} and {@link #CASE_INSTRUMENTAL}
      */
     public static final String ARG_CASE = "android.arg.case";
 
-    public static final String CASE_NOMINATIVE = "android.nomative";
+    public static final String CASE_NOMINATIVE = "android.nominative";
     public static final String CASE_ACCUSATIVE = "android.accusative";
     public static final String CASE_DATIVE = "android.dative";
     public static final String CASE_ABLATIVE = "android.ablative";
@@ -227,14 +222,14 @@
     public static final String CASE_INSTRUMENTAL = "android.instrumental";
 
     /**
-     * String supplying the text to be synthesized.  The synthesizer is free
+     * String supplying the text to be synthesized. The synthesizer is free
      * to decide how to interpret the text.
      * Can be used with {@link #TYPE_TEXT}.
      */
     public static final String ARG_TEXT = "android.arg.text";
 
     /**
-     * Argument used to specify a whole number.  The value can be a string of
+     * Argument used to specify a whole number. The value can be a string of
      * digits of any size optionally prefixed with a - or +.
      * Can be used with {@link #TYPE_CARDINAL} and {@link #TYPE_ORDINAL}.
      */
@@ -293,7 +288,7 @@
      * specified in English singular form. Prefixes may be used. Engines will do
      * their best to pronounce them correctly in the language used. Engines are
      * expected to at least support the most common ones like "meter", "second",
-     * "degree celcius" and "degree fahrenheit" with some common prefixes like
+     * "degree celsius" and "degree fahrenheit" with some common prefixes like
      * "milli" and "kilo".
      * Can be used with {@link #TYPE_MEASURE}.
      */
@@ -589,8 +584,8 @@
 
         /**
          * Sets the gender information for this instance.
-         * @param gender Can any of {@link TtsSpan#GENDER_NEUTRAL},
-         *     {@link TtsSpan#GENDER_MALE} and {@link TtsSpan#GENDER_FEMALE}.
+         * @param gender Can any of {@link #GENDER_NEUTRAL},
+         *     {@link #GENDER_MALE} and {@link #GENDER_FEMALE}.
          * @return This instance.
          */
         public C setGender(String gender) {
@@ -599,8 +594,8 @@
 
         /**
          * Sets the animacy information for this instance.
-         * @param animacy Can be any of {@link TtsSpan#ANIMACY_ANIMATE} and
-         *     {@link TtsSpan#ANIMACY_INANIMATE}.
+         * @param animacy Can be any of {@link #ANIMACY_ANIMATE} and
+         *     {@link #ANIMACY_INANIMATE}.
          * @return This instance.
          */
         public C setAnimacy(String animacy) {
@@ -610,9 +605,8 @@
         /**
          * Sets the multiplicity information for this instance.
          * @param multiplicity Can be any of
-         *     {@link TtsSpan#MULTIPLICITY_SINGLE},
-         *     {@link TtsSpan#MULTIPLICITY_DUAL} and
-         *     {@link TtsSpan#MULTIPLICITY_PLURAL}.
+         *     {@link #MULTIPLICITY_SINGLE}, {@link #MULTIPLICITY_DUAL} and
+         *     {@link #MULTIPLICITY_PLURAL}.
          * @return This instance.
          */
         public C setMultiplicity(String multiplicity) {
@@ -621,11 +615,11 @@
 
         /**
          * Sets the grammatical case information for this instance.
-         * @param grammaticalCase Can be any of {@link TtsSpan#CASE_NOMINATIVE},
-         *     {@link TtsSpan#CASE_ACCUSATIVE}, {@link TtsSpan#CASE_DATIVE},
-         *     {@link TtsSpan#CASE_ABLATIVE}, {@link TtsSpan#CASE_GENITIVE},
-         *     {@link TtsSpan#CASE_VOCATIVE}, {@link TtsSpan#CASE_LOCATIVE} and
-         *     {@link TtsSpan#CASE_INSTRUMENTAL}.
+         * @param grammaticalCase Can be any of {@link #CASE_NOMINATIVE},
+         *     {@link #CASE_ACCUSATIVE}, {@link #CASE_DATIVE},
+         *     {@link #CASE_ABLATIVE}, {@link #CASE_GENITIVE},
+         *     {@link #CASE_VOCATIVE}, {@link #CASE_LOCATIVE} and
+         *     {@link #CASE_INSTRUMENTAL}.
          * @return This instance.
          */
         public C setCase(String grammaticalCase) {
@@ -634,20 +628,20 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_TEXT}.
+     * A builder for TtsSpans of type {@link #TYPE_TEXT}.
      */
     public static class TextBuilder extends SemioticClassBuilder<TextBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_TEXT}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_TEXT}.
          */
         public TextBuilder() {
             super(TtsSpan.TYPE_TEXT);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_TEXT} and sets the
-         * {@link TtsSpan#ARG_TEXT} argument.
+         * Creates a TtsSpan of type {@link #TYPE_TEXT} and sets the
+         * {@link #ARG_TEXT} argument.
          * @param text The text to be synthesized.
          * @see #setText(String)
          */
@@ -657,8 +651,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_TEXT} argument, the text to be
-         * synthesized.
+         * Sets the {@link #ARG_TEXT} argument, the text to be synthesized.
          * @param text The string that will be synthesized.
          * @return This instance.
          */
@@ -668,22 +661,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_CARDINAL}.
+     * A builder for TtsSpans of type {@link #TYPE_CARDINAL}.
      */
     public static class CardinalBuilder
             extends SemioticClassBuilder<CardinalBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type
-         * {@link TtsSpan#TYPE_CARDINAL}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_CARDINAL}.
          */
         public CardinalBuilder() {
             super(TtsSpan.TYPE_CARDINAL);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_CARDINAL} and sets the
-         * {@link TtsSpan#ARG_NUMBER} argument.
+         * Creates a TtsSpan of type {@link #TYPE_CARDINAL} and sets the
+         * {@link #ARG_NUMBER} argument.
          * @param number The number to synthesize.
          * @see #setNumber(long)
          */
@@ -693,8 +685,8 @@
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_CARDINAL} and sets the
-         * {@link TtsSpan#ARG_NUMBER} argument.
+         * Creates a TtsSpan of type {@link #TYPE_CARDINAL} and sets the
+         * {@link #ARG_NUMBER} argument.
          * @param number The number to synthesize.
          * @see #setNumber(String)
          */
@@ -705,7 +697,7 @@
 
         /**
          * Convenience method that converts the number to a String and set it to
-         * the value for {@link TtsSpan#ARG_NUMBER}.
+         * the value for {@link #ARG_NUMBER}.
          * @param number The number that will be synthesized.
          * @return This instance.
          */
@@ -714,7 +706,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMBER} argument.
+         * Sets the {@link #ARG_NUMBER} argument.
          * @param number A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -725,21 +717,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan#TYPE_ORDINAL}.
+     * A builder for TtsSpans of type {@link #TYPE_ORDINAL}.
      */
     public static class OrdinalBuilder
             extends SemioticClassBuilder<OrdinalBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_ORDINAL}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_ORDINAL}.
          */
         public OrdinalBuilder() {
             super(TtsSpan.TYPE_ORDINAL);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_ORDINAL} and sets the
-         * {@link TtsSpan#ARG_NUMBER} argument.
+         * Creates a TtsSpan of type {@link #TYPE_ORDINAL} and sets the
+         * {@link #ARG_NUMBER} argument.
          * @param number The ordinal number to synthesize.
          * @see #setNumber(long)
          */
@@ -749,8 +741,8 @@
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_ORDINAL} and sets the
-         * {@link TtsSpan#ARG_NUMBER} argument.
+         * Creates a TtsSpan of type {@link #TYPE_ORDINAL} and sets the
+         * {@link #ARG_NUMBER} argument.
          * @param number The number to synthesize.
          * @see #setNumber(String)
          */
@@ -761,7 +753,7 @@
 
         /**
          * Convenience method that converts the number to a String and sets it
-         * to the value for {@link TtsSpan#ARG_NUMBER}.
+         * to the value for {@link #ARG_NUMBER}.
          * @param number The ordinal number that will be synthesized.
          * @return This instance.
          */
@@ -770,7 +762,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMBER} argument.
+         * Sets the {@link #ARG_NUMBER} argument.
          * @param number A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -781,22 +773,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan#TYPE_DECIMAL}.
+     * A builder for TtsSpans of type {@link #TYPE_DECIMAL}.
      */
     public static class DecimalBuilder
             extends SemioticClassBuilder<DecimalBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_DECIMAL}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_DECIMAL}.
          */
         public DecimalBuilder() {
             super(TtsSpan.TYPE_DECIMAL);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_DECIMAL} and sets the
-         * {@link TtsSpan#ARG_INTEGER_PART} and
-         * {@link TtsSpan#ARG_FRACTIONAL_PART} arguments.
+         * Creates a TtsSpan of type {@link #TYPE_DECIMAL} and sets the
+         * {@link #ARG_INTEGER_PART} and {@link #ARG_FRACTIONAL_PART} arguments.
          * @see {@link #setArgumentsFromDouble(double, int, int)
          */
         public DecimalBuilder(double number,
@@ -809,9 +800,8 @@
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_DECIMAL} and sets the
-         * {@link TtsSpan#ARG_INTEGER_PART} and
-         * {@link TtsSpan#ARG_FRACTIONAL_PART} arguments.
+         * Creates a TtsSpan of type {@link #TYPE_DECIMAL} and sets the
+         * {@link #ARG_INTEGER_PART} and {@link #ARG_FRACTIONAL_PART} arguments.
          */
         public DecimalBuilder(String integerPart, String fractionalPart) {
             this();
@@ -821,8 +811,8 @@
 
         /**
          * Convenience method takes a double and a maximum number of fractional
-         * digits, it sets the {@link TtsSpan#ARG_INTEGER_PART} and
-         * {@link TtsSpan#ARG_FRACTIONAL_PART} arguments.
+         * digits, it sets the {@link #ARG_INTEGER_PART} and
+         * {@link #ARG_FRACTIONAL_PART} arguments.
          * @param number The number to be synthesized.
          * @param minimumFractionDigits The minimum number of fraction digits
          *     that are pronounced.
@@ -856,7 +846,7 @@
 
         /**
          * Convenience method that converts the number to a String and sets it
-         * to the value for {@link TtsSpan#ARG_INTEGER_PART}.
+         * to the value for {@link #ARG_INTEGER_PART}.
          * @param integerPart The integer part of the decimal.
          * @return This instance.
          */
@@ -865,7 +855,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_INTEGER_PART} argument.
+         * Sets the {@link #ARG_INTEGER_PART} argument.
          * @param integerPart A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -875,7 +865,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_FRACTIONAL_PART} argument.
+         * Sets the {@link #ARG_FRACTIONAL_PART} argument.
          * @param fractionalPart A non-empty string of digits.
          * @return This instance.
          */
@@ -886,23 +876,22 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan#TYPE_FRACTION}.
+     * A builder for TtsSpans of type {@link #TYPE_FRACTION}.
      */
     public static class FractionBuilder
             extends SemioticClassBuilder<FractionBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type
-         * {@link TtsSpan#TYPE_FRACTION}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_FRACTION}.
          */
         public FractionBuilder() {
             super(TtsSpan.TYPE_FRACTION);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_FRACTION} and sets the
-         * {@link TtsSpan#ARG_INTEGER_PART}, {@link TtsSpan#ARG_NUMERATOR}, and
-         * {@link TtsSpan#ARG_DENOMINATOR} arguments.
+         * Creates a TtsSpan of type {@link #TYPE_FRACTION} and sets the
+         * {@link #ARG_INTEGER_PART}, {@link #ARG_NUMERATOR}, and
+         * {@link #ARG_DENOMINATOR} arguments.
          */
         public FractionBuilder(long integerPart,
                                long numerator,
@@ -913,10 +902,9 @@
             setDenominator(denominator);
         }
 
-
         /**
          * Convenience method that converts the integer to a String and sets the
-         * argument {@link TtsSpan#ARG_NUMBER}.
+         * argument {@link #ARG_NUMBER}.
          * @param integerPart The integer part.
          * @return This instance.
          */
@@ -925,7 +913,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_INTEGER_PART} argument.
+         * Sets the {@link #ARG_INTEGER_PART} argument.
          * @param integerPart A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -936,7 +924,7 @@
 
         /**
          * Convenience method that converts the numerator to a String and sets
-         * the argument {@link TtsSpan#ARG_NUMERATOR}.
+         * the argument {@link #ARG_NUMERATOR}.
          * @param numerator The numerator.
          * @return This instance.
          */
@@ -945,7 +933,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMERATOR} argument.
+         * Sets the {@link #ARG_NUMERATOR} argument.
          * @param numerator A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -956,7 +944,7 @@
 
         /**
          * Convenience method that converts the denominator to a String and sets
-         * the argument {@link TtsSpan#ARG_DENOMINATOR}.
+         * the argument {@link #ARG_DENOMINATOR}.
          * @param denominator The denominator.
          * @return This instance.
          */
@@ -965,7 +953,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_DENOMINATOR} argument.
+         * Sets the {@link #ARG_DENOMINATOR} argument.
          * @param denominator A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -976,13 +964,13 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_MEASURE}.
+     * A builder for TtsSpans of type {@link #TYPE_MEASURE}.
      */
     public static class MeasureBuilder
             extends SemioticClassBuilder<MeasureBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_MEASURE}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_MEASURE}.
          */
         public MeasureBuilder() {
             super(TtsSpan.TYPE_MEASURE);
@@ -990,7 +978,7 @@
 
         /**
          * Convenience method that converts the number to a String and set it to
-         * the value for {@link TtsSpan#ARG_NUMBER}.
+         * the value for {@link #ARG_NUMBER}.
          * @param number The amount of the measure.
          * @return This instance.
          */
@@ -999,7 +987,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMBER} argument.
+         * Sets the {@link #ARG_NUMBER} argument.
          * @param number A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -1010,7 +998,7 @@
 
         /**
          * Convenience method that converts the integer part to a String and set
-         * it to the value for {@link TtsSpan#ARG_INTEGER_PART}.
+         * it to the value for {@link #ARG_INTEGER_PART}.
          * @param integerPart The integer part of a decimal or fraction.
          * @return This instance.
          */
@@ -1019,7 +1007,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_INTEGER_PART} argument.
+         * Sets the {@link #ARG_INTEGER_PART} argument.
          * @param integerPart The integer part of a decimal or fraction; a
          * non-empty string of digits with an optional
          *     leading + or -.
@@ -1030,10 +1018,9 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_FRACTIONAL_PART} argument.
+         * Sets the {@link #ARG_FRACTIONAL_PART} argument.
          * @param fractionalPart The fractional part of a decimal; a non-empty
-         * string of digits with an optional
-         *     leading + or -.
+         *     string of digits with an optional leading + or -.
          * @return This instance.
          */
         public MeasureBuilder setFractionalPart(String fractionalPart) {
@@ -1043,7 +1030,7 @@
 
         /**
          * Convenience method that converts the numerator to a String and set it
-         * to the value for {@link TtsSpan#ARG_NUMERATOR}.
+         * to the value for {@link #ARG_NUMERATOR}.
          * @param numerator The numerator of a fraction.
          * @return This instance.
          */
@@ -1052,7 +1039,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMERATOR} argument.
+         * Sets the {@link #ARG_NUMERATOR} argument.
          * @param numerator The numerator of a fraction; a non-empty string of
          *     digits with an optional leading + or -.
          * @return This instance.
@@ -1063,7 +1050,7 @@
 
         /**
          * Convenience method that converts the denominator to a String and set
-         * it to the value for {@link TtsSpan#ARG_DENOMINATOR}.
+         * it to the value for {@link #ARG_DENOMINATOR}.
          * @param denominator The denominator of a fraction.
          * @return This instance.
          */
@@ -1072,7 +1059,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_DENOMINATOR} argument.
+         * Sets the {@link #ARG_DENOMINATOR} argument.
          * @param denominator The denominator of a fraction; a non-empty string
          *     of digits with an optional leading + or -.
          * @return This instance.
@@ -1082,7 +1069,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_UNIT} argument.
+         * Sets the {@link #ARG_UNIT} argument.
          * @param unit The unit of the measure.
          * @return This instance.
          * @see {@link TtsSpan.ARG_UNIT}
@@ -1093,22 +1080,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_TIME}.
+     * A builder for TtsSpans of type {@link #TYPE_TIME}.
      */
     public static class TimeBuilder
             extends SemioticClassBuilder<TimeBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_TIME}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_TIME}.
          */
         public TimeBuilder() {
             super(TtsSpan.TYPE_TIME);
         }
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_TIME} and
-         * sets the {@link TtsSpan#ARG_HOURS} and {@link TtsSpan#ARG_MINUTES}
-         * arguments.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_TIME} and
+         * sets the {@link #ARG_HOURS} and {@link #ARG_MINUTES} arguments.
          */
         public TimeBuilder(int hours, int minutes) {
             this();
@@ -1117,22 +1103,21 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_HOURS} argument.
-         * @param hours The value to be set for hours. See
-         * {@link TtsSpan#ARG_HOURS}.
+         * Sets the {@link #ARG_HOURS} argument.
+         * @param hours The value to be set for hours. See {@link #ARG_HOURS}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_HOURS}
+         * @see {@link #ARG_HOURS}
          */
         public TimeBuilder setHours(int hours) {
             return setIntArgument(TtsSpan.ARG_HOURS, hours);
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_MINUTES} argument.
+         * Sets the {@link #ARG_MINUTES} argument.
          * @param minutes The value to be set for minutes. See
-         * {@link TtsSpan#ARG_MINUTES}.
+         *     {@link #ARG_MINUTES}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_MINUTES}
+         * @see {@link #ARG_MINUTES}
          */
         public TimeBuilder setMinutes(int minutes) {
             return setIntArgument(TtsSpan.ARG_MINUTES, minutes);
@@ -1140,24 +1125,23 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_DATE}.
+     * A builder for TtsSpans of type {@link #TYPE_DATE}.
      */
     public static class DateBuilder
             extends SemioticClassBuilder<DateBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_DATE}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_DATE}.
          */
         public DateBuilder() {
             super(TtsSpan.TYPE_DATE);
         }
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_TIME} and
-         * possibly sets the {@link TtsSpan#ARG_WEEKDAY},
-         * {@link TtsSpan#ARG_DAY}, {@link TtsSpan#ARG_MONTH} and
-         * {@link TtsSpan#ARG_YEAR} arguments. Pass null to any argument to
-         * leave it unset.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_TIME} and
+         * possibly sets the {@link #ARG_WEEKDAY}, {@link #ARG_DAY},
+         * {@link #ARG_MONTH} and {@link #ARG_YEAR} arguments. Pass null to any
+         * argument to leave it unset.
          */
         public DateBuilder(Integer weekday,
                            Integer day,
@@ -1179,44 +1163,41 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_WEEKDAY} argument.
+         * Sets the {@link #ARG_WEEKDAY} argument.
          * @param weekday The value to be set for weekday. See
-         * {@link TtsSpan#ARG_WEEKDAY}.
+         *     {@link #ARG_WEEKDAY}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_WEEKDAY}
+         * @see {@link #ARG_WEEKDAY}
          */
         public DateBuilder setWeekday(int weekday) {
             return setIntArgument(TtsSpan.ARG_WEEKDAY, weekday);
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_DAY} argument.
-         * @param day The value to be set for day. See
-         * {@link TtsSpan#ARG_DAY}.
+         * Sets the {@link #ARG_DAY} argument.
+         * @param day The value to be set for day. See {@link #ARG_DAY}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_DAY}
+         * @see {@link #ARG_DAY}
          */
         public DateBuilder setDay(int day) {
             return setIntArgument(TtsSpan.ARG_DAY, day);
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_MONTH} argument.
-         * @param month The value to be set for month. See
-         * {@link TtsSpan#ARG_MONTH}.
+         * Sets the {@link #ARG_MONTH} argument.
+         * @param month The value to be set for month. See {@link #ARG_MONTH}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_MONTH}
+         * @see {@link #ARG_MONTH}
          */
         public DateBuilder setMonth(int month) {
             return setIntArgument(TtsSpan.ARG_MONTH, month);
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_YEAR} argument.
-         * @param year The value to be set for year. See
-         * {@link TtsSpan#ARG_YEAR}.
+         * Sets the {@link #ARG_YEAR} argument.
+         * @param year The value to be set for year. See {@link #ARG_YEAR}.
          * @return This instance.
-         * @see {@link TtsSpan#ARG_YEAR}
+         * @see {@link #ARG_YEAR}
          */
         public DateBuilder setYear(int year) {
             return setIntArgument(TtsSpan.ARG_YEAR, year);
@@ -1224,13 +1205,13 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_MONEY}.
+     * A builder for TtsSpans of type {@link #TYPE_MONEY}.
      */
     public static class MoneyBuilder
             extends SemioticClassBuilder<MoneyBuilder> {
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_MONEY}.
+         * Creates a TtsSpan of type {@link #TYPE_MONEY}.
          */
         public MoneyBuilder() {
             super(TtsSpan.TYPE_MONEY);
@@ -1238,7 +1219,7 @@
 
         /**
          * Convenience method that converts the number to a String and set it to
-         * the value for {@link TtsSpan#ARG_INTEGER_PART}.
+         * the value for {@link #ARG_INTEGER_PART}.
          * @param integerPart The integer part of the amount.
          * @return This instance.
          */
@@ -1247,7 +1228,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_INTEGER_PART} argument.
+         * Sets the {@link #ARG_INTEGER_PART} argument.
          * @param integerPart A non-empty string of digits with an optional
          *     leading + or -.
          * @return This instance.
@@ -1257,7 +1238,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_FRACTIONAL_PART} argument.
+         * Sets the {@link #ARG_FRACTIONAL_PART} argument.
          * @param fractionalPart Can be a string of digits of any size.
          * @return This instance.
          */
@@ -1266,7 +1247,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_CURRENCY} argument.
+         * Sets the {@link #ARG_CURRENCY} argument.
          * @param currency Should be a ISO4217 currency code, e.g. "USD".
          * @return This instance.
          */
@@ -1275,7 +1256,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_QUANTITY} argument.
+         * Sets the {@link #ARG_QUANTITY} argument.
          * @param quantity
          * @return This instance.
          */
@@ -1285,21 +1266,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_TELEPHONE}.
+     * A builder for TtsSpans of type {@link #TYPE_TELEPHONE}.
      */
     public static class TelephoneBuilder
             extends SemioticClassBuilder<TelephoneBuilder> {
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_TELEPHONE}.
+         * Creates a TtsSpan of type {@link #TYPE_TELEPHONE}.
          */
         public TelephoneBuilder() {
             super(TtsSpan.TYPE_TELEPHONE);
         }
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_TELEPHONE} and sets the
-         * {@link TtsSpan#ARG_NUMBER_PARTS} argument.
+         * Creates a TtsSpan of type {@link #TYPE_TELEPHONE} and sets the
+         * {@link #ARG_NUMBER_PARTS} argument.
          */
         public TelephoneBuilder(String numberParts) {
             this();
@@ -1307,7 +1288,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_COUNTRY_CODE} argument.
+         * Sets the {@link #ARG_COUNTRY_CODE} argument.
          * @param countryCode The country code can be a series of digits
          * optionally prefixed with a "+".
          * @return This instance.
@@ -1317,7 +1298,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_NUMBER_PARTS} argument.
+         * Sets the {@link #ARG_NUMBER_PARTS} argument.
          * @param numberParts The main telephone number. Can be a series of
          *     digits and letters separated by spaces, "/", "-" or ".".
          * @return This instance.
@@ -1327,7 +1308,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_EXTENSION} argument.
+         * Sets the {@link #ARG_EXTENSION} argument.
          * @param extension The extension can be a series of digits.
          * @return This instance.
          */
@@ -1337,20 +1318,20 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_ELECTRONIC}.
+     * A builder for TtsSpans of type {@link #TYPE_ELECTRONIC}.
      */
     public static class ElectronicBuilder
             extends SemioticClassBuilder<ElectronicBuilder> {
 
         /**
-         * Creates a TtsSpan of type {@link TtsSpan#TYPE_ELECTRONIC}.
+         * Creates a TtsSpan of type {@link #TYPE_ELECTRONIC}.
          */
         public ElectronicBuilder() {
             super(TtsSpan.TYPE_ELECTRONIC);
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_USERNAME} and {@link TtsSpan#ARG_DOMAIN}
+         * Sets the {@link #ARG_USERNAME} and {@link #ARG_DOMAIN}
          *     arguments, representing an email address.
          * @param username The part before the @ in the email address.
          * @param domain The part after the @ in the email address.
@@ -1362,7 +1343,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_PROTOCOL} argument.
+         * Sets the {@link #ARG_PROTOCOL} argument.
          * @param protocol The protocol of the URI. Examples are "http" and
          *     "ftp".
          * @return This instance.
@@ -1372,7 +1353,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_USERNAME} argument.
+         * Sets the {@link #ARG_USERNAME} argument.
          * @return This instance.
          */
         public ElectronicBuilder setUsername(String username) {
@@ -1380,7 +1361,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_PASSWORD} argument.
+         * Sets the {@link #ARG_PASSWORD} argument.
          * @return This instance.
          */
         public ElectronicBuilder setPassword(String password) {
@@ -1388,7 +1369,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_DOMAIN} argument.
+         * Sets the {@link #ARG_DOMAIN} argument.
          * @param domain The domain, for example "source.android.com".
          * @return This instance.
          */
@@ -1397,7 +1378,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_PORT} argument.
+         * Sets the {@link #ARG_PORT} argument.
          * @return This instance.
          */
         public ElectronicBuilder setPort(int port) {
@@ -1405,7 +1386,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_PATH} argument.
+         * Sets the {@link #ARG_PATH} argument.
          * @param path For example "source/index.html".
          * @return This instance.
          */
@@ -1414,7 +1395,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_QUERY_STRING} argument.
+         * Sets the {@link #ARG_QUERY_STRING} argument.
          * @param queryString For example "arg=value&argtwo=value".
          * @return This instance.
          */
@@ -1423,7 +1404,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_FRAGMENT_ID} argument.
+         * Sets the {@link #ARG_FRAGMENT_ID} argument.
          * @return This instance.
          */
         public ElectronicBuilder setFragmentId(String fragmentId) {
@@ -1432,22 +1413,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_DIGITS}.
+     * A builder for TtsSpans of type {@link #TYPE_DIGITS}.
      */
     public static class DigitsBuilder
             extends SemioticClassBuilder<DigitsBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type
-         * {@link TtsSpan#TYPE_VERBATIM}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_DIGITS}.
          */
         public DigitsBuilder() {
             super(TtsSpan.TYPE_DIGITS);
         }
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_DIGITS}
-         * and sets the {@link TtsSpan#ARG_DIGITS} argument.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_DIGITS}
+         * and sets the {@link #ARG_DIGITS} argument.
          */
         public DigitsBuilder(String digits) {
             this();
@@ -1455,7 +1435,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_DIGITS} argument.
+         * Sets the {@link #ARG_DIGITS} argument.
          * @param digits A string of digits.
          * @return This instance.
          */
@@ -1465,22 +1445,21 @@
     }
 
     /**
-     * A builder for TtsSpans of type {@link TtsSpan #TYPE_VERBATIM}.
+     * A builder for TtsSpans of type {@link #TYPE_VERBATIM}.
      */
     public static class VerbatimBuilder
             extends SemioticClassBuilder<VerbatimBuilder> {
 
         /**
-         * Creates a builder for a TtsSpan of type
-         * {@link TtsSpan#TYPE_VERBATIM}.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_VERBATIM}.
          */
         public VerbatimBuilder() {
             super(TtsSpan.TYPE_VERBATIM);
         }
 
         /**
-         * Creates a builder for a TtsSpan of type {@link TtsSpan#TYPE_VERBATIM}
-         * and sets the {@link TtsSpan#ARG_VERBATIM} argument.
+         * Creates a builder for a TtsSpan of type {@link #TYPE_VERBATIM}
+         * and sets the {@link #ARG_VERBATIM} argument.
          */
         public VerbatimBuilder(String verbatim) {
             this();
@@ -1488,7 +1467,7 @@
         }
 
         /**
-         * Sets the {@link TtsSpan#ARG_VERBATIM} argument.
+         * Sets the {@link #ARG_VERBATIM} argument.
          * @param verbatim A string of characters that will be read verbatim,
          *     except whitespace.
          * @return This instance.
diff --git a/core/java/android/transition/ArcMotion.java b/core/java/android/transition/ArcMotion.java
index a27063d..f95fb49 100644
--- a/core/java/android/transition/ArcMotion.java
+++ b/core/java/android/transition/ArcMotion.java
@@ -41,9 +41,9 @@
  * {@code
  * &lt;changeBounds>
  *   &lt;arcMotion android:minimumHorizontalAngle="15"
- *     android:minimumVerticalAngle="0" android:maximumAngle="90"/>
- * &lt;/changeBounds>
- * }
+ *              android:minimumVerticalAngle="0"
+ *              android:maximumAngle="90"/>
+ * &lt;/changeBounds>}
  * </pre>
  */
 public class ArcMotion extends PathMotion {
diff --git a/core/java/android/transition/ChangeBounds.java b/core/java/android/transition/ChangeBounds.java
index efcbdb3..eb17429 100644
--- a/core/java/android/transition/ChangeBounds.java
+++ b/core/java/android/transition/ChangeBounds.java
@@ -16,13 +16,11 @@
 
 package android.transition;
 
-import android.animation.TypeConverter;
 import android.content.Context;
 import android.graphics.PointF;
 
 import android.animation.Animator;
 import android.animation.AnimatorListenerAdapter;
-import android.animation.AnimatorSet;
 import android.animation.ObjectAnimator;
 import android.animation.PropertyValuesHolder;
 import android.animation.RectEvaluator;
@@ -33,6 +31,7 @@
 import android.graphics.drawable.BitmapDrawable;
 import android.graphics.drawable.Drawable;
 import android.util.AttributeSet;
+import android.util.IntProperty;
 import android.util.Property;
 import android.view.View;
 import android.view.ViewGroup;
@@ -109,6 +108,8 @@
      *
      * @param reparent true if the transition should track the parent
      * container of target views and animate parent changes.
+     * @deprecated Use {@link android.transition.ChangeTransform} to handle
+     * transitions between different parents.
      */
     public void setReparent(boolean reparent) {
         mReparent = reparent;
@@ -119,9 +120,11 @@
         values.values.put(PROPNAME_BOUNDS, new Rect(view.getLeft(), view.getTop(),
                 view.getRight(), view.getBottom()));
         values.values.put(PROPNAME_PARENT, values.view.getParent());
-        values.view.getLocationInWindow(tempLocation);
-        values.values.put(PROPNAME_WINDOW_X, tempLocation[0]);
-        values.values.put(PROPNAME_WINDOW_Y, tempLocation[1]);
+        if (mReparent) {
+            values.view.getLocationInWindow(tempLocation);
+            values.values.put(PROPNAME_WINDOW_X, tempLocation[0]);
+            values.values.put(PROPNAME_WINDOW_Y, tempLocation[1]);
+        }
     }
 
     @Override
@@ -134,6 +137,19 @@
         captureValues(transitionValues);
     }
 
+    private boolean parentMatches(View startParent, View endParent) {
+        boolean parentMatches = true;
+        if (mReparent) {
+            TransitionValues endValues = getMatchedTransitionValues(startParent, true);
+            if (endValues == null) {
+                parentMatches = startParent == endParent;
+            } else {
+                parentMatches = endParent == endValues.view;
+            }
+        }
+        return parentMatches;
+    }
+
     @Override
     public Animator createAnimator(final ViewGroup sceneRoot, TransitionValues startValues,
             TransitionValues endValues) {
@@ -148,13 +164,7 @@
             return null;
         }
         final View view = endValues.view;
-        boolean parentsEqual = (startParent == endParent) ||
-                (startParent.getId() == endParent.getId());
-        // TODO: Might want reparenting to be separate/subclass transition, or at least
-        // triggered by a property on ChangeBounds. Otherwise, we're forcing the requirement that
-        // all parents in layouts have IDs to avoid layout-inflation resulting in a side-effect
-        // of reparenting the views.
-        if (!mReparent || parentsEqual) {
+        if (parentMatches(startParent, endParent)) {
             Rect startBounds = (Rect) startValues.values.get(PROPNAME_BOUNDS);
             Rect endBounds = (Rect) endValues.values.get(PROPNAME_BOUNDS);
             int startLeft = startBounds.left;
@@ -176,25 +186,36 @@
             }
             if (numChanges > 0) {
                 if (!mResizeClip) {
-                    if (startLeft != endLeft) view.setLeft(startLeft);
-                    if (startTop != endTop) view.setTop(startTop);
-                    if (startRight != endRight) view.setRight(startRight);
-                    if (startBottom != endBottom) view.setBottom(startBottom);
-                    ObjectAnimator topLeftAnimator = null;
-                    if (startLeft != endLeft || startTop != endTop) {
-                        Path topLeftPath = getPathMotion().getPath(startLeft, startTop,
-                                endLeft, endTop);
-                        topLeftAnimator = ObjectAnimator.ofInt(view, "left", "top", topLeftPath);
+                    Animator anim;
+                    if (startWidth == endWidth && startHeight == endHeight) {
+                        view.offsetLeftAndRight(startLeft - view.getLeft());
+                        view.offsetTopAndBottom(startTop - view.getTop());
+                        Path positionPath = getPathMotion().getPath(0, 0, endLeft - startLeft,
+                                endTop - startTop);
+                        anim = ObjectAnimator.ofInt(view, new HorizontalOffsetProperty(),
+                                new VerticalOffsetProperty(), positionPath);
+                    } else {
+                        if (startLeft != endLeft) view.setLeft(startLeft);
+                        if (startTop != endTop) view.setTop(startTop);
+                        if (startRight != endRight) view.setRight(startRight);
+                        if (startBottom != endBottom) view.setBottom(startBottom);
+                        ObjectAnimator topLeftAnimator = null;
+                        if (startLeft != endLeft || startTop != endTop) {
+                            Path topLeftPath = getPathMotion().getPath(startLeft, startTop,
+                                    endLeft, endTop);
+                            topLeftAnimator = ObjectAnimator
+                                    .ofInt(view, "left", "top", topLeftPath);
+                        }
+                        ObjectAnimator bottomRightAnimator = null;
+                        if (startRight != endRight || startBottom != endBottom) {
+                            Path bottomRightPath = getPathMotion().getPath(startRight, startBottom,
+                                    endRight, endBottom);
+                            bottomRightAnimator = ObjectAnimator.ofInt(view, "right", "bottom",
+                                    bottomRightPath);
+                        }
+                        anim = TransitionUtils.mergeAnimators(topLeftAnimator,
+                                bottomRightAnimator);
                     }
-                    ObjectAnimator bottomRightAnimator = null;
-                    if (startRight != endRight || startBottom != endBottom) {
-                        Path bottomRightPath = getPathMotion().getPath(startRight, startBottom,
-                                endRight, endBottom);
-                        bottomRightAnimator = ObjectAnimator.ofInt(view, "right", "bottom",
-                                bottomRightPath);
-                    }
-                    Animator anim = TransitionUtils.mergeAnimators(topLeftAnimator,
-                            bottomRightAnimator);
                     if (view.getParent() instanceof ViewGroup) {
                         final ViewGroup parent = (ViewGroup) view.getParent();
                         parent.suppressLayout(true);
@@ -332,4 +353,48 @@
         }
         return null;
     }
+
+    private abstract static class OffsetProperty extends IntProperty<View> {
+        int mPreviousValue;
+
+        public OffsetProperty(String name) {
+            super(name);
+        }
+
+        @Override
+        public void setValue(View view, int value) {
+            int offset = value - mPreviousValue;
+            offsetBy(view, offset);
+            mPreviousValue = value;
+        }
+
+        @Override
+        public Integer get(View object) {
+            return null;
+        }
+
+        protected abstract void offsetBy(View view, int by);
+    }
+
+    private static class HorizontalOffsetProperty extends OffsetProperty {
+        public HorizontalOffsetProperty() {
+            super("offsetLeftAndRight");
+        }
+
+        @Override
+        protected void offsetBy(View view, int by) {
+            view.offsetLeftAndRight(by);
+        }
+    }
+
+    private static class VerticalOffsetProperty extends OffsetProperty {
+        public VerticalOffsetProperty() {
+            super("offsetTopAndBottom");
+        }
+
+        @Override
+        protected void offsetBy(View view, int by) {
+            view.offsetTopAndBottom(by);
+        }
+    }
 }
diff --git a/core/java/android/transition/ChangeImageTransform.java b/core/java/android/transition/ChangeImageTransform.java
index 2b26756..d7a9120 100644
--- a/core/java/android/transition/ChangeImageTransform.java
+++ b/core/java/android/transition/ChangeImageTransform.java
@@ -16,7 +16,6 @@
 package android.transition;
 
 import android.animation.Animator;
-import android.animation.AnimatorListenerAdapter;
 import android.animation.ObjectAnimator;
 import android.animation.TypeEvaluator;
 import android.content.Context;
@@ -182,6 +181,7 @@
             if (endMatrix == null) {
                 endMatrix = Matrix.IDENTITY_MATRIX;
             }
+            ANIMATED_TRANSFORM_PROPERTY.set(imageView, startMatrix);
             animator = createMatrixAnimator(imageView, startMatrix, endMatrix);
         }
         return animator;
@@ -195,28 +195,6 @@
     private ObjectAnimator createMatrixAnimator(final ImageView imageView, Matrix startMatrix,
             final Matrix endMatrix) {
         return ObjectAnimator.ofObject(imageView, ANIMATED_TRANSFORM_PROPERTY,
-                new MatrixEvaluator(), startMatrix, endMatrix);
+                new TransitionUtils.MatrixEvaluator(), startMatrix, endMatrix);
     }
-
-    private static class MatrixEvaluator implements TypeEvaluator<Matrix> {
-
-        float[] mTempStartValues = new float[9];
-
-        float[] mTempEndValues = new float[9];
-
-        Matrix mTempMatrix = new Matrix();
-
-        @Override
-        public Matrix evaluate(float fraction, Matrix startValue, Matrix endValue) {
-            startValue.getValues(mTempStartValues);
-            endValue.getValues(mTempEndValues);
-            for (int i = 0; i < 9; i++) {
-                float diff = mTempEndValues[i] - mTempStartValues[i];
-                mTempEndValues[i] = mTempStartValues[i] + (fraction * diff);
-            }
-            mTempMatrix.setValues(mTempEndValues);
-            return mTempMatrix;
-        }
-    }
-
 }
diff --git a/core/java/android/transition/ChangeTransform.java b/core/java/android/transition/ChangeTransform.java
index e9be3b9..1b8d57c 100644
--- a/core/java/android/transition/ChangeTransform.java
+++ b/core/java/android/transition/ChangeTransform.java
@@ -16,72 +16,142 @@
 package android.transition;
 
 import android.animation.Animator;
-import android.animation.FloatArrayEvaluator;
+import android.animation.AnimatorListenerAdapter;
 import android.animation.ObjectAnimator;
+import android.animation.ValueAnimator;
 import android.content.Context;
+import android.content.res.TypedArray;
+import android.graphics.Matrix;
 import android.util.AttributeSet;
-import android.util.FloatProperty;
 import android.util.Property;
+import android.view.GhostView;
 import android.view.View;
 import android.view.ViewGroup;
+import com.android.internal.R;
 
 /**
  * This Transition captures scale and rotation for Views before and after the
  * scene change and animates those changes during the transition.
  *
- * <p>ChangeTransform does not work when the pivot changes between scenes, so either the
- * pivot must be set to prevent automatic pivot adjustment or the View's size must be unchanged.</p>
+ * A change in parent is handled as well by capturing the transforms from
+ * the parent before and after the scene change and animating those during the
+ * transition.
  */
 public class ChangeTransform extends Transition {
 
     private static final String TAG = "ChangeTransform";
 
-    private static final String PROPNAME_SCALE_X = "android:changeTransform:scaleX";
-    private static final String PROPNAME_SCALE_Y = "android:changeTransform:scaleY";
-    private static final String PROPNAME_ROTATION_X = "android:changeTransform:rotationX";
-    private static final String PROPNAME_ROTATION_Y = "android:changeTransform:rotationY";
-    private static final String PROPNAME_ROTATION_Z = "android:changeTransform:rotationZ";
-    private static final String PROPNAME_PIVOT_X = "android:changeTransform:pivotX";
-    private static final String PROPNAME_PIVOT_Y = "android:changeTransform:pivotY";
+    private static final String PROPNAME_MATRIX = "android:changeTransform:matrix";
+    private static final String PROPNAME_TRANSFORMS = "android:changeTransform:transforms";
+    private static final String PROPNAME_PARENT = "android:changeTransform:parent";
+    private static final String PROPNAME_PARENT_MATRIX = "android:changeTransform:parentMatrix";
+    private static final String PROPNAME_INTERMEDIATE_PARENT_MATRIX =
+            "android:changeTransform:intermediateParentMatrix";
+    private static final String PROPNAME_INTERMEDIATE_MATRIX =
+            "android:changeTransform:intermediateMatrix";
 
     private static final String[] sTransitionProperties = {
-            PROPNAME_SCALE_X,
-            PROPNAME_SCALE_Y,
-            PROPNAME_ROTATION_X,
-            PROPNAME_ROTATION_Y,
-            PROPNAME_ROTATION_Z,
+            PROPNAME_MATRIX,
+            PROPNAME_TRANSFORMS,
+            PROPNAME_PARENT_MATRIX,
     };
 
-    private static final FloatProperty<View>[] sChangedProperties = new FloatProperty[] {
-            (FloatProperty) View.SCALE_X,
-            (FloatProperty) View.SCALE_Y,
-            (FloatProperty) View.ROTATION_X,
-            (FloatProperty) View.ROTATION_Y,
-            (FloatProperty) View.ROTATION,
-    };
-
-    private static Property<View, float[]> TRANSFORMS = new Property<View, float[]>(float[].class,
-            "transforms") {
-        @Override
-        public float[] get(View object) {
-            return null;
-        }
-
-        @Override
-        public void set(View view, float[] values) {
-            for (int i = 0; i < values.length; i++) {
-                float value = values[i];
-                if (!Float.isNaN(value)) {
-                    sChangedProperties[i].setValue(view, value);
+    private static final Property<View, Matrix> ANIMATION_MATRIX_PROPERTY =
+            new Property<View, Matrix>(Matrix.class, "animationMatrix") {
+                @Override
+                public Matrix get(View object) {
+                    return null;
                 }
-            }
-        }
-    };
+
+                @Override
+                public void set(View object, Matrix value) {
+                    object.setAnimationMatrix(value);
+                }
+            };
+
+    private boolean mUseOverlay = true;
+    private boolean mReparent = true;
+    private Matrix mTempMatrix = new Matrix();
 
     public ChangeTransform() {}
 
     public ChangeTransform(Context context, AttributeSet attrs) {
         super(context, attrs);
+        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ChangeTransform);
+        mUseOverlay = a.getBoolean(R.styleable.ChangeTransform_reparentWithOverlay, true);
+        mReparent = a.getBoolean(R.styleable.ChangeTransform_reparent, true);
+        a.recycle();
+    }
+
+    /**
+     * Returns whether changes to parent should use an overlay or not. When the parent
+     * change doesn't use an overlay, it affects the transforms of the child. The
+     * default value is <code>true</code>.
+     *
+     * <p>Note: when Overlays are not used when a parent changes, a view can be clipped when
+     * it moves outside the bounds of its parent. Setting
+     * {@link android.view.ViewGroup#setClipChildren(boolean)} and
+     * {@link android.view.ViewGroup#setClipToPadding(boolean)} can help. Also, when
+     * Overlays are not used and the parent is animating its location, the position of the
+     * child view will be relative to its parent's final position, so it may appear to "jump"
+     * at the beginning.</p>
+     *
+     * @return <code>true</code> when a changed parent should execute the transition
+     * inside the scene root's overlay or <code>false</code> if a parent change only
+     * affects the transform of the transitioning view.
+     * @attr ref android.R.styleable#ChangeTransform_reparentWithOverlay
+     */
+    public boolean getReparentWithOverlay() {
+        return mUseOverlay;
+    }
+
+    /**
+     * Sets whether changes to parent should use an overlay or not. When the parent
+     * change doesn't use an overlay, it affects the transforms of the child. The
+     * default value is <code>true</code>.
+     *
+     * <p>Note: when Overlays are not used when a parent changes, a view can be clipped when
+     * it moves outside the bounds of its parent. Setting
+     * {@link android.view.ViewGroup#setClipChildren(boolean)} and
+     * {@link android.view.ViewGroup#setClipToPadding(boolean)} can help. Also, when
+     * Overlays are not used and the parent is animating its location, the position of the
+     * child view will be relative to its parent's final position, so it may appear to "jump"
+     * at the beginning.</p>
+     *
+     * @return <code>true</code> when a changed parent should execute the transition
+     * inside the scene root's overlay or <code>false</code> if a parent change only
+     * affects the transform of the transitioning view.
+     * @attr ref android.R.styleable#ChangeTransform_reparentWithOverlay
+     */
+    public void setReparentWithOverlay(boolean reparentWithOverlay) {
+        mUseOverlay = reparentWithOverlay;
+    }
+
+    /**
+     * Returns whether parent changes will be tracked by the ChangeTransform. If parent
+     * changes are tracked, then the transform will adjust to the transforms of the
+     * different parents. If they aren't tracked, only the transforms of the transitioning
+     * view will be tracked. Default is true.
+     *
+     * @return whether parent changes will be tracked by the ChangeTransform.
+     * @attr ref android.R.styleable#ChangeTransform_reparent
+     */
+    public boolean getReparent() {
+        return mReparent;
+    }
+
+    /**
+     * Sets whether parent changes will be tracked by the ChangeTransform. If parent
+     * changes are tracked, then the transform will adjust to the transforms of the
+     * different parents. If they aren't tracked, only the transforms of the transitioning
+     * view will be tracked. Default is true.
+     *
+     * @param reparent Set to true to track parent changes or false to only track changes
+     *                 of the transitioning view without considering the parent change.
+     * @attr ref android.R.styleable#ChangeTransform_reparent
+     */
+    public void setReparent(boolean reparent) {
+        mReparent = reparent;
     }
 
     @Override
@@ -89,19 +159,33 @@
         return sTransitionProperties;
     }
 
-    private void captureValues(TransitionValues values) {
-        View view = values.view;
+    private void captureValues(TransitionValues transitionValues) {
+        View view = transitionValues.view;
         if (view.getVisibility() == View.GONE) {
             return;
         }
-
-        values.values.put(PROPNAME_SCALE_X, view.getScaleX());
-        values.values.put(PROPNAME_SCALE_Y, view.getScaleY());
-        values.values.put(PROPNAME_PIVOT_X, view.getPivotX());
-        values.values.put(PROPNAME_PIVOT_Y, view.getPivotY());
-        values.values.put(PROPNAME_ROTATION_X, view.getRotationX());
-        values.values.put(PROPNAME_ROTATION_Y, view.getRotationY());
-        values.values.put(PROPNAME_ROTATION_Z, view.getRotation());
+        transitionValues.values.put(PROPNAME_PARENT, view.getParent());
+        Transforms transforms = new Transforms(view);
+        transitionValues.values.put(PROPNAME_TRANSFORMS, transforms);
+        Matrix matrix = view.getMatrix();
+        if (matrix == null || matrix.isIdentity()) {
+            matrix = null;
+        } else {
+            matrix = new Matrix(matrix);
+        }
+        transitionValues.values.put(PROPNAME_MATRIX, matrix);
+        if (mReparent) {
+            Matrix parentMatrix = new Matrix();
+            ViewGroup parent = (ViewGroup) view.getParent();
+            parent.transformMatrixToGlobal(parentMatrix);
+            parentMatrix.preTranslate(-parent.getScrollX(), -parent.getScrollY());
+            transitionValues.values.put(PROPNAME_PARENT_MATRIX, parentMatrix);
+            transitionValues.values.put(PROPNAME_INTERMEDIATE_MATRIX,
+                    view.getTag(R.id.transitionTransform));
+            transitionValues.values.put(PROPNAME_INTERMEDIATE_PARENT_MATRIX,
+                    view.getTag(R.id.parentMatrix));
+        }
+        return;
     }
 
     @Override
@@ -115,57 +199,256 @@
     }
 
     @Override
-    public Animator createAnimator(final ViewGroup sceneRoot, TransitionValues startValues,
+    public Animator createAnimator(ViewGroup sceneRoot, TransitionValues startValues,
             TransitionValues endValues) {
-        if (startValues == null || endValues == null
-                || !startValues.values.containsKey(PROPNAME_SCALE_X)
-                || !endValues.values.containsKey(PROPNAME_SCALE_X)
-                || !isPivotSame(startValues, endValues)
-                || !isChanged(startValues, endValues)) {
+        if (startValues == null || endValues == null ||
+                !startValues.values.containsKey(PROPNAME_PARENT) ||
+                !endValues.values.containsKey(PROPNAME_PARENT)) {
             return null;
         }
 
-        float[] start = createValues(startValues);
-        float[] end = createValues(endValues);
-        for (int i = 0; i < start.length; i++) {
-            if (start[i] == end[i]) {
-                start[i] = Float.NaN;
-                end[i] = Float.NaN;
-            } else {
-                sChangedProperties[i].setValue(endValues.view, start[i]);
+        ViewGroup startParent = (ViewGroup) startValues.values.get(PROPNAME_PARENT);
+        ViewGroup endParent = (ViewGroup) endValues.values.get(PROPNAME_PARENT);
+        boolean handleParentChange = mReparent && !parentsMatch(startParent, endParent);
+
+        Matrix startMatrix = (Matrix) startValues.values.get(PROPNAME_INTERMEDIATE_MATRIX);
+        if (startMatrix != null) {
+            startValues.values.put(PROPNAME_MATRIX, startMatrix);
+        }
+
+        Matrix startParentMatrix = (Matrix)
+                startValues.values.get(PROPNAME_INTERMEDIATE_PARENT_MATRIX);
+        if (startParentMatrix != null) {
+            startValues.values.put(PROPNAME_PARENT_MATRIX, startParentMatrix);
+        }
+
+        // First handle the parent change:
+        if (handleParentChange) {
+            setMatricesForParent(startValues, endValues);
+        }
+
+        // Next handle the normal matrix transform:
+        ObjectAnimator transformAnimator = createTransformAnimator(startValues, endValues);
+
+        if (handleParentChange && transformAnimator != null && mUseOverlay) {
+            createGhostView(sceneRoot, startValues, endValues);
+        }
+
+        return transformAnimator;
+    }
+
+    private ObjectAnimator createTransformAnimator(TransitionValues startValues,
+            TransitionValues endValues) {
+        Matrix startMatrix = (Matrix) startValues.values.get(PROPNAME_MATRIX);
+        Matrix endMatrix = (Matrix) endValues.values.get(PROPNAME_MATRIX);
+
+        if (startMatrix == null) {
+            startMatrix = Matrix.IDENTITY_MATRIX;
+        }
+
+        if (endMatrix == null) {
+            endMatrix = Matrix.IDENTITY_MATRIX;
+        }
+
+        if (startMatrix.equals(endMatrix)) {
+            return null;
+        }
+
+        final Transforms transforms = (Transforms) endValues.values.get(PROPNAME_TRANSFORMS);
+
+        // clear the transform properties so that we can use the animation matrix instead
+        final View view = endValues.view;
+        setIdentityTransforms(view);
+
+        ObjectAnimator animator = ObjectAnimator.ofObject(view, ANIMATION_MATRIX_PROPERTY,
+                new TransitionUtils.MatrixEvaluator(), startMatrix, endMatrix);
+
+        final Matrix finalEndMatrix = endMatrix;
+
+        AnimatorListenerAdapter listener = new AnimatorListenerAdapter() {
+            private boolean mIsCanceled;
+            private Matrix mTempMatrix = new Matrix();
+
+            @Override
+            public void onAnimationCancel(Animator animation) {
+                mIsCanceled = true;
+            }
+
+            @Override
+            public void onAnimationEnd(Animator animation) {
+                if (!mIsCanceled) {
+                    setCurrentMatrix(finalEndMatrix);
+                }
+                ANIMATION_MATRIX_PROPERTY.set(view, null);
+                transforms.restore(view);
+            }
+
+            @Override
+            public void onAnimationPause(Animator animation) {
+                ValueAnimator animator = (ValueAnimator) animation;
+                Matrix currentMatrix = (Matrix) animator.getAnimatedValue();
+                setCurrentMatrix(currentMatrix);
+            }
+
+            @Override
+            public void onAnimationResume(Animator animation) {
+                setIdentityTransforms(view);
+            }
+
+            private void setCurrentMatrix(Matrix currentMatrix) {
+                mTempMatrix.set(currentMatrix);
+                view.setTagInternal(R.id.transitionTransform, mTempMatrix);
+                transforms.restore(view);
+            }
+        };
+
+        animator.addListener(listener);
+        animator.addPauseListener(listener);
+        return animator;
+    }
+
+    private boolean parentsMatch(ViewGroup startParent, ViewGroup endParent) {
+        boolean parentsMatch = false;
+        if (!isValidTarget(startParent) || !isValidTarget(endParent)) {
+            parentsMatch = startParent == endParent;
+        } else {
+            TransitionValues endValues = getMatchedTransitionValues(startParent, true);
+            if (endValues != null) {
+                parentsMatch = endParent == endValues.view;
             }
         }
-        FloatArrayEvaluator evaluator = new FloatArrayEvaluator(new float[start.length]);
-        return ObjectAnimator.ofObject(endValues.view, TRANSFORMS, evaluator, start, end);
+        return parentsMatch;
     }
 
-    private static float[] createValues(TransitionValues transitionValues) {
-        float[] values = new float[sChangedProperties.length];
-        for (int i = 0; i < values.length; i++) {
-            values[i] = (Float) transitionValues.values.get(sTransitionProperties[i]);
+    private void createGhostView(final ViewGroup sceneRoot, TransitionValues startValues,
+            TransitionValues endValues) {
+        View view = endValues.view;
+
+        Matrix endMatrix = (Matrix) endValues.values.get(PROPNAME_PARENT_MATRIX);
+        Matrix localEndMatrix = new Matrix(endMatrix);
+        sceneRoot.transformMatrixToLocal(localEndMatrix);
+
+        GhostView ghostView = GhostView.addGhost(view, sceneRoot, localEndMatrix);
+
+        Transition outerTransition = this;
+        while (outerTransition.mParent != null) {
+            outerTransition = outerTransition.mParent;
         }
-        return values;
+        GhostListener listener = new GhostListener(view, ghostView, endMatrix);
+        outerTransition.addListener(listener);
+
+        if (startValues.view != endValues.view) {
+            startValues.view.setTransitionAlpha(0);
+        }
+        view.setTransitionAlpha(1);
     }
 
-    private static boolean isPivotSame(TransitionValues startValues, TransitionValues endValues) {
-        float startPivotX = (Float) startValues.values.get(PROPNAME_PIVOT_X);
-        float startPivotY = (Float) startValues.values.get(PROPNAME_PIVOT_Y);
-        float endPivotX = (Float) endValues.values.get(PROPNAME_PIVOT_X);
-        float endPivotY = (Float) endValues.values.get(PROPNAME_PIVOT_Y);
+    private void setMatricesForParent(TransitionValues startValues, TransitionValues endValues) {
+        Matrix endParentMatrix = (Matrix) endValues.values.get(PROPNAME_PARENT_MATRIX);
+        endValues.view.setTagInternal(R.id.parentMatrix, endParentMatrix);
 
-        // We don't support pivot changes, because they could be automatically set
-        // and we can't end the state in an automatic state.
-        return startPivotX == endPivotX && startPivotY == endPivotY;
+        Matrix toLocal = mTempMatrix;
+        toLocal.reset();
+        endParentMatrix.invert(toLocal);
+
+        Matrix startLocal = (Matrix) startValues.values.get(PROPNAME_MATRIX);
+        if (startLocal == null) {
+            startLocal = new Matrix();
+            startValues.values.put(PROPNAME_MATRIX, startLocal);
+        }
+
+        Matrix startParentMatrix = (Matrix) startValues.values.get(PROPNAME_PARENT_MATRIX);
+        startLocal.postConcat(startParentMatrix);
+        startLocal.postConcat(toLocal);
     }
 
-    private static boolean isChanged(TransitionValues startValues, TransitionValues endValues) {
-        for (int i = 0; i < sChangedProperties.length; i++) {
-            Object start = startValues.values.get(sTransitionProperties[i]);
-            Object end = endValues.values.get(sTransitionProperties[i]);
-            if (!start.equals(end)) {
-                return true;
+    private static void setIdentityTransforms(View view) {
+        setTransforms(view, 0, 0, 0, 1, 1, 0, 0, 0);
+    }
+
+    private static void setTransforms(View view, float translationX, float translationY,
+            float translationZ, float scaleX, float scaleY, float rotationX,
+            float rotationY, float rotationZ) {
+        view.setTranslationX(translationX);
+        view.setTranslationY(translationY);
+        view.setTranslationZ(translationZ);
+        view.setScaleX(scaleX);
+        view.setScaleY(scaleY);
+        view.setRotationX(rotationX);
+        view.setRotationY(rotationY);
+        view.setRotation(rotationZ);
+    }
+
+    private static class Transforms {
+        public final float translationX;
+        public final float translationY;
+        public final float translationZ;
+        public final float scaleX;
+        public final float scaleY;
+        public final float rotationX;
+        public final float rotationY;
+        public final float rotationZ;
+
+        public Transforms(View view) {
+            translationX = view.getTranslationX();
+            translationY = view.getTranslationY();
+            translationZ = view.getTranslationZ();
+            scaleX = view.getScaleX();
+            scaleY = view.getScaleY();
+            rotationX = view.getRotationX();
+            rotationY = view.getRotationY();
+            rotationZ = view.getRotation();
+        }
+
+        public void restore(View view) {
+            setTransforms(view, translationX, translationY, translationZ, scaleX, scaleY,
+                    rotationX, rotationY, rotationZ);
+        }
+
+        @Override
+        public boolean equals(Object that) {
+            if (!(that instanceof Transforms)) {
+                return false;
             }
+            Transforms thatTransform = (Transforms) that;
+            return thatTransform.translationX == translationX &&
+                    thatTransform.translationY == translationY &&
+                    thatTransform.translationZ == translationZ &&
+                    thatTransform.scaleX == scaleX &&
+                    thatTransform.scaleY == scaleY &&
+                    thatTransform.rotationX == rotationX &&
+                    thatTransform.rotationY == rotationY &&
+                    thatTransform.rotationZ == rotationZ;
         }
-        return false;
+    }
+
+    private static class GhostListener extends Transition.TransitionListenerAdapter {
+        private View mView;
+        private GhostView mGhostView;
+	private Matrix mEndMatrix;
+
+        public GhostListener(View view, GhostView ghostView, Matrix endMatrix) {
+            mView = view;
+            mGhostView = ghostView;
+            mEndMatrix = endMatrix;
+        }
+
+        @Override
+        public void onTransitionEnd(Transition transition) {
+            transition.removeListener(this);
+            GhostView.removeGhost(mView);
+            mView.setTagInternal(R.id.transitionTransform, null);
+            mView.setTagInternal(R.id.parentMatrix, null);
+        }
+
+        @Override
+        public void onTransitionPause(Transition transition) {
+            mGhostView.setVisibility(View.INVISIBLE);
+        }
+
+        @Override
+        public void onTransitionResume(Transition transition) {
+            mGhostView.setVisibility(View.VISIBLE);
+        }
     }
 }
diff --git a/core/java/android/transition/Fade.java b/core/java/android/transition/Fade.java
index 1f9d093..e7857c0 100644
--- a/core/java/android/transition/Fade.java
+++ b/core/java/android/transition/Fade.java
@@ -145,12 +145,21 @@
         private final View mView;
         private boolean mCanceled = false;
         private float mPausedAlpha = -1;
+        private boolean mLayerTypeChanged = false;
 
         public FadeAnimatorListener(View view) {
             mView = view;
         }
 
         @Override
+        public void onAnimationStart(Animator animator) {
+            if (mView.hasOverlappingRendering() && mView.getLayerType() == View.LAYER_TYPE_NONE) {
+                mLayerTypeChanged = true;
+                mView.setLayerType(View.LAYER_TYPE_HARDWARE, null);
+            }
+        }
+
+        @Override
         public void onAnimationCancel(Animator animator) {
             mCanceled = true;
             if (mPausedAlpha >= 0) {
@@ -163,6 +172,9 @@
             if (!mCanceled) {
                 mView.setTransitionAlpha(1);
             }
+            if (mLayerTypeChanged) {
+                mView.setLayerType(View.LAYER_TYPE_NONE, null);
+            }
         }
 
         @Override
diff --git a/core/java/android/transition/PatternMotion.java b/core/java/android/transition/PatternMotion.java
deleted file mode 100644
index e4045b4..0000000
--- a/core/java/android/transition/PatternMotion.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.transition;
-
-import com.android.internal.R;
-
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.graphics.Matrix;
-import android.graphics.Path;
-import android.graphics.PathMeasure;
-import android.util.AttributeSet;
-import android.util.FloatMath;
-import android.util.PathParser;
-
-/**
- * A PathMotion that takes a Path pattern and applies it to the separation between two points.
- * The starting point of the Path will be moved to the origin and the end point will be scaled
- * and rotated so that it matches with the target end point.
- * <p>This may be used in XML as an element inside a transition.</p>
- * <pre>
- * {@code
- * &lt;changeBounds>
- *     &lt;patternMotion android:pathData="M0 0 L0 100 L100 100"/>
- * &lt;/changeBounds>
- * }
- * </pre>
- */
-public class PatternMotion extends PathMotion {
-
-    private Path mOriginalPattern;
-
-    private final Path mPattern = new Path();
-
-    private final Matrix mTempMatrix = new Matrix();
-
-    /**
-     * Constructs a PatternMotion with a straight-line pattern.
-     */
-    public PatternMotion() {
-        mPattern.lineTo(1, 0);
-        mOriginalPattern = mPattern;
-    }
-
-    public PatternMotion(Context context, AttributeSet attrs) {
-        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.PatternMotion);
-        try {
-            String pathData = a.getString(R.styleable.PatternMotion_pathData);
-            if (pathData == null) {
-                throw new RuntimeException("pathData must be supplied for patternMotion");
-            }
-            Path pattern = PathParser.createPathFromPathData(pathData);
-            setPattern(pattern);
-        } finally {
-            a.recycle();
-        }
-
-    }
-
-    /**
-     * Creates a PatternMotion with the Path defining a pattern of motion between two coordinates.
-     * The pattern will be translated, rotated, and scaled to fit between the start and end points.
-     * The pattern must not be empty and must have the end point differ from the start point.
-     *
-     * @param pattern A Path to be used as a pattern for two-dimensional motion.
-     */
-    public PatternMotion(Path pattern) {
-        setPattern(pattern);
-    }
-
-    /**
-     * Returns the Path defining a pattern of motion between two coordinates.
-     * The pattern will be translated, rotated, and scaled to fit between the start and end points.
-     * The pattern must not be empty and must have the end point differ from the start point.
-     *
-     * @return the Path defining a pattern of motion between two coordinates.
-     * @attr ref android.R.styleable#PatternMotion_pathData
-     */
-    public Path getPattern() {
-        return mOriginalPattern;
-    }
-
-    /**
-     * Sets the Path defining a pattern of motion between two coordinates.
-     * The pattern will be translated, rotated, and scaled to fit between the start and end points.
-     * The pattern must not be empty and must have the end point differ from the start point.
-     *
-     * @param pattern A Path to be used as a pattern for two-dimensional motion.
-     * @attr ref android.R.styleable#PatternMotion_pathData
-     */
-    public void setPattern(Path pattern) {
-        PathMeasure pathMeasure = new PathMeasure(pattern, false);
-        float length = pathMeasure.getLength();
-        float[] pos = new float[2];
-        pathMeasure.getPosTan(length, pos, null);
-        float endX = pos[0];
-        float endY = pos[1];
-        pathMeasure.getPosTan(0, pos, null);
-        float startX = pos[0];
-        float startY = pos[1];
-
-        if (startX == endX && startY == endY) {
-            throw new IllegalArgumentException("pattern must not end at the starting point");
-        }
-
-        mTempMatrix.setTranslate(-startX, -startY);
-        float dx = endX - startX;
-        float dy = endY - startY;
-        float distance = distance(dx, dy);
-        float scale = 1 / distance;
-        mTempMatrix.postScale(scale, scale);
-        double angle = Math.atan2(dy, dx);
-        mTempMatrix.postRotate((float) Math.toDegrees(-angle));
-        pattern.transform(mTempMatrix, mPattern);
-        mOriginalPattern = pattern;
-    }
-
-    @Override
-    public Path getPath(float startX, float startY, float endX, float endY) {
-        float dx = endX - startX;
-        float dy = endY - startY;
-        float length = distance(dx, dy);
-        double angle = Math.atan2(dy, dx);
-
-        mTempMatrix.setScale(length, length);
-        mTempMatrix.postRotate((float) Math.toDegrees(angle));
-        mTempMatrix.postTranslate(startX, startY);
-        Path path = new Path();
-        mPattern.transform(mTempMatrix, path);
-        return path;
-    }
-
-    private static float distance(float x, float y) {
-        return FloatMath.sqrt((x * x) + (y * y));
-    }
-}
diff --git a/core/java/android/transition/PatternPathMotion.java b/core/java/android/transition/PatternPathMotion.java
new file mode 100644
index 0000000..a609df6
--- /dev/null
+++ b/core/java/android/transition/PatternPathMotion.java
@@ -0,0 +1,149 @@
+/*
+ * Copyright (C) 2014 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 android.transition;
+
+import com.android.internal.R;
+
+import android.content.Context;
+import android.content.res.TypedArray;
+import android.graphics.Matrix;
+import android.graphics.Path;
+import android.graphics.PathMeasure;
+import android.util.AttributeSet;
+import android.util.FloatMath;
+import android.util.PathParser;
+
+/**
+ * A PathMotion that takes a Path pattern and applies it to the separation between two points.
+ * The starting point of the Path will be moved to the origin and the end point will be scaled
+ * and rotated so that it matches with the target end point.
+ * <p>This may be used in XML as an element inside a transition.</p>
+ * <pre>
+ * {@code
+ * &lt;changeBounds>
+ *     &lt;patternPathMotion android:patternPathData="M0 0 L0 100 L100 100"/>
+ * &lt;/changeBounds>}
+ * </pre>
+ */
+public class PatternPathMotion extends PathMotion {
+
+    private Path mOriginalPatternPath;
+
+    private final Path mPatternPath = new Path();
+
+    private final Matrix mTempMatrix = new Matrix();
+
+    /**
+     * Constructs a PatternPathMotion with a straight-line pattern.
+     */
+    public PatternPathMotion() {
+        mPatternPath.lineTo(1, 0);
+        mOriginalPatternPath = mPatternPath;
+    }
+
+    public PatternPathMotion(Context context, AttributeSet attrs) {
+        TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.PatternPathMotion);
+        try {
+            String pathData = a.getString(R.styleable.PatternPathMotion_patternPathData);
+            if (pathData == null) {
+                throw new RuntimeException("pathData must be supplied for patternPathMotion");
+            }
+            Path pattern = PathParser.createPathFromPathData(pathData);
+            setPatternPath(pattern);
+        } finally {
+            a.recycle();
+        }
+
+    }
+
+    /**
+     * Creates a PatternPathMotion with the Path defining a pattern of motion between two
+     * coordinates. The pattern will be translated, rotated, and scaled to fit between the start
+     * and end points. The pattern must not be empty and must have the end point differ from the
+     * start point.
+     *
+     * @param patternPath A Path to be used as a pattern for two-dimensional motion.
+     */
+    public PatternPathMotion(Path patternPath) {
+        setPatternPath(patternPath);
+    }
+
+    /**
+     * Returns the Path defining a pattern of motion between two coordinates.
+     * The pattern will be translated, rotated, and scaled to fit between the start and end points.
+     * The pattern must not be empty and must have the end point differ from the start point.
+     *
+     * @return the Path defining a pattern of motion between two coordinates.
+     * @attr ref android.R.styleable#PatternPathMotion_patternPathData
+     */
+    public Path getPatternPath() {
+        return mOriginalPatternPath;
+    }
+
+    /**
+     * Sets the Path defining a pattern of motion between two coordinates.
+     * The pattern will be translated, rotated, and scaled to fit between the start and end points.
+     * The pattern must not be empty and must have the end point differ from the start point.
+     *
+     * @param patternPath A Path to be used as a pattern for two-dimensional motion.
+     * @attr ref android.R.styleable#PatternPathMotion_patternPathData
+     */
+    public void setPatternPath(Path patternPath) {
+        PathMeasure pathMeasure = new PathMeasure(patternPath, false);
+        float length = pathMeasure.getLength();
+        float[] pos = new float[2];
+        pathMeasure.getPosTan(length, pos, null);
+        float endX = pos[0];
+        float endY = pos[1];
+        pathMeasure.getPosTan(0, pos, null);
+        float startX = pos[0];
+        float startY = pos[1];
+
+        if (startX == endX && startY == endY) {
+            throw new IllegalArgumentException("pattern must not end at the starting point");
+        }
+
+        mTempMatrix.setTranslate(-startX, -startY);
+        float dx = endX - startX;
+        float dy = endY - startY;
+        float distance = distance(dx, dy);
+        float scale = 1 / distance;
+        mTempMatrix.postScale(scale, scale);
+        double angle = Math.atan2(dy, dx);
+        mTempMatrix.postRotate((float) Math.toDegrees(-angle));
+        patternPath.transform(mTempMatrix, mPatternPath);
+        mOriginalPatternPath = patternPath;
+    }
+
+    @Override
+    public Path getPath(float startX, float startY, float endX, float endY) {
+        float dx = endX - startX;
+        float dy = endY - startY;
+        float length = distance(dx, dy);
+        double angle = Math.atan2(dy, dx);
+
+        mTempMatrix.setScale(length, length);
+        mTempMatrix.postRotate((float) Math.toDegrees(angle));
+        mTempMatrix.postTranslate(startX, startY);
+        Path path = new Path();
+        mPatternPath.transform(mTempMatrix, path);
+        return path;
+    }
+
+    private static float distance(float x, float y) {
+        return FloatMath.sqrt((x * x) + (y * y));
+    }
+}
diff --git a/core/java/android/transition/Transition.java b/core/java/android/transition/Transition.java
index 2fa8d2a..b677888 100644
--- a/core/java/android/transition/Transition.java
+++ b/core/java/android/transition/Transition.java
@@ -112,8 +112,8 @@
  *
  * Further information on XML resource descriptions for transitions can be found for
  * {@link android.R.styleable#Transition}, {@link android.R.styleable#TransitionSet},
- * {@link android.R.styleable#TransitionTarget}, {@link android.R.styleable#Fade}, and
- * {@link android.R.styleable#Slide}.
+ * {@link android.R.styleable#TransitionTarget}, {@link android.R.styleable#Fade},
+ * {@link android.R.styleable#Slide}, and {@link android.R.styleable#ChangeTransform}.
  *
  */
 public abstract class Transition implements Cloneable {
@@ -192,6 +192,8 @@
     private TransitionValuesMaps mEndValues = new TransitionValuesMaps();
     TransitionSet mParent = null;
     private int[] mMatchOrder = DEFAULT_MATCH_ORDER;
+    ArrayList<TransitionValues> mStartValuesList; // only valid after playTransition starts
+    ArrayList<TransitionValues> mEndValuesList; // only valid after playTransitions starts
 
     // Per-animator information used for later canceling when future transitions overlap
     private static ThreadLocal<ArrayMap<Animator, AnimationInfo>> sRunningAnimators =
@@ -518,32 +520,28 @@
     }
 
     /**
-     * Match start/end values by View instance. Adds matched values to startValuesList
-     * and endValuesList and removes them from unmatchedStart and unmatchedEnd.
+     * Match start/end values by View instance. Adds matched values to mStartValuesList
+     * and mEndValuesList and removes them from unmatchedStart and unmatchedEnd.
      */
-    private void matchInstances(ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList,
-            ArrayMap<View, TransitionValues> unmatchedStart,
+    private void matchInstances(ArrayMap<View, TransitionValues> unmatchedStart,
             ArrayMap<View, TransitionValues> unmatchedEnd) {
         for (int i = unmatchedStart.size() - 1; i >= 0; i--) {
             View view = unmatchedStart.keyAt(i);
             TransitionValues end = unmatchedEnd.remove(view);
             if (end != null) {
                 TransitionValues start = unmatchedStart.removeAt(i);
-                startValuesList.add(start);
-                endValuesList.add(end);
+                mStartValuesList.add(start);
+                mEndValuesList.add(end);
             }
         }
     }
 
     /**
-     * Match start/end values by Adapter item ID. Adds matched values to startValuesList
-     * and endValuesList and removes them from unmatchedStart and unmatchedEnd, using
+     * Match start/end values by Adapter item ID. Adds matched values to mStartValuesList
+     * and mEndValuesList and removes them from unmatchedStart and unmatchedEnd, using
      * startItemIds and endItemIds as a guide for which Views have unique item IDs.
      */
-    private void matchItemIds(ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList,
-            ArrayMap<View, TransitionValues> unmatchedStart,
+    private void matchItemIds(ArrayMap<View, TransitionValues> unmatchedStart,
             ArrayMap<View, TransitionValues> unmatchedEnd,
             LongSparseArray<View> startItemIds, LongSparseArray<View> endItemIds) {
         int numStartIds = startItemIds.size();
@@ -555,8 +553,8 @@
                     TransitionValues startValues = unmatchedStart.get(startView);
                     TransitionValues endValues = unmatchedEnd.get(endView);
                     if (startValues != null && endValues != null) {
-                        startValuesList.add(startValues);
-                        endValuesList.add(endValues);
+                        mStartValuesList.add(startValues);
+                        mEndValuesList.add(endValues);
                         unmatchedStart.remove(startView);
                         unmatchedEnd.remove(endView);
                     }
@@ -566,13 +564,11 @@
     }
 
     /**
-     * Match start/end values by Adapter view ID. Adds matched values to startValuesList
-     * and endValuesList and removes them from unmatchedStart and unmatchedEnd, using
+     * Match start/end values by Adapter view ID. Adds matched values to mStartValuesList
+     * and mEndValuesList and removes them from unmatchedStart and unmatchedEnd, using
      * startIds and endIds as a guide for which Views have unique IDs.
      */
-    private void matchIds(ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList,
-            ArrayMap<View, TransitionValues> unmatchedStart,
+    private void matchIds(ArrayMap<View, TransitionValues> unmatchedStart,
             ArrayMap<View, TransitionValues> unmatchedEnd,
             SparseArray<View> startIds, SparseArray<View> endIds) {
         int numStartIds = startIds.size();
@@ -584,8 +580,8 @@
                     TransitionValues startValues = unmatchedStart.get(startView);
                     TransitionValues endValues = unmatchedEnd.get(endView);
                     if (startValues != null && endValues != null) {
-                        startValuesList.add(startValues);
-                        endValuesList.add(endValues);
+                        mStartValuesList.add(startValues);
+                        mEndValuesList.add(endValues);
                         unmatchedStart.remove(startView);
                         unmatchedEnd.remove(endView);
                     }
@@ -595,13 +591,11 @@
     }
 
     /**
-     * Match start/end values by Adapter transitionName. Adds matched values to startValuesList
-     * and endValuesList and removes them from unmatchedStart and unmatchedEnd, using
+     * Match start/end values by Adapter transitionName. Adds matched values to mStartValuesList
+     * and mEndValuesList and removes them from unmatchedStart and unmatchedEnd, using
      * startNames and endNames as a guide for which Views have unique transitionNames.
      */
-    private void matchNames(ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList,
-            ArrayMap<View, TransitionValues> unmatchedStart,
+    private void matchNames(ArrayMap<View, TransitionValues> unmatchedStart,
             ArrayMap<View, TransitionValues> unmatchedEnd,
             ArrayMap<String, View> startNames, ArrayMap<String, View> endNames) {
         int numStartNames = startNames.size();
@@ -613,8 +607,8 @@
                     TransitionValues startValues = unmatchedStart.get(startView);
                     TransitionValues endValues = unmatchedEnd.get(endView);
                     if (startValues != null && endValues != null) {
-                        startValuesList.add(startValues);
-                        endValuesList.add(endValues);
+                        mStartValuesList.add(startValues);
+                        mEndValuesList.add(endValues);
                         unmatchedStart.remove(startView);
                         unmatchedEnd.remove(endView);
                     }
@@ -624,30 +618,26 @@
     }
 
     /**
-     * Adds all values from unmatchedStart and unmatchedEnd to startValuesList and endValuesList,
+     * Adds all values from unmatchedStart and unmatchedEnd to mStartValuesList and mEndValuesList,
      * assuming that there is no match between values in the list.
      */
-    private void addUnmatched(ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList,
-            ArrayMap<View, TransitionValues> unmatchedStart,
+    private void addUnmatched(ArrayMap<View, TransitionValues> unmatchedStart,
             ArrayMap<View, TransitionValues> unmatchedEnd) {
         // Views that only exist in the start Scene
         for (int i = 0; i < unmatchedStart.size(); i++) {
-            startValuesList.add(unmatchedStart.valueAt(i));
-            endValuesList.add(null);
+            mStartValuesList.add(unmatchedStart.valueAt(i));
+            mEndValuesList.add(null);
         }
 
         // Views that only exist in the end Scene
         for (int i = 0; i < unmatchedEnd.size(); i++) {
-            endValuesList.add(unmatchedEnd.valueAt(i));
-            startValuesList.add(null);
+            mEndValuesList.add(unmatchedEnd.valueAt(i));
+            mStartValuesList.add(null);
         }
     }
 
     private void matchStartAndEnd(TransitionValuesMaps startValues,
-            TransitionValuesMaps endValues,
-            ArrayList<TransitionValues> startValuesList,
-            ArrayList<TransitionValues> endValuesList) {
+            TransitionValuesMaps endValues) {
         ArrayMap<View, TransitionValues> unmatchedStart =
                 new ArrayMap<View, TransitionValues>(startValues.viewValues);
         ArrayMap<View, TransitionValues> unmatchedEnd =
@@ -656,23 +646,23 @@
         for (int i = 0; i < mMatchOrder.length; i++) {
             switch (mMatchOrder[i]) {
                 case MATCH_INSTANCE:
-                    matchInstances(startValuesList, endValuesList, unmatchedStart, unmatchedEnd);
+                    matchInstances(unmatchedStart, unmatchedEnd);
                     break;
                 case MATCH_NAME:
-                    matchNames(startValuesList, endValuesList, unmatchedStart, unmatchedEnd,
+                    matchNames(unmatchedStart, unmatchedEnd,
                             startValues.nameValues, endValues.nameValues);
                     break;
                 case MATCH_ID:
-                    matchIds(startValuesList, endValuesList, unmatchedStart, unmatchedEnd,
+                    matchIds(unmatchedStart, unmatchedEnd,
                             startValues.idValues, endValues.idValues);
                     break;
                 case MATCH_ITEM_ID:
-                    matchItemIds(startValuesList, endValuesList, unmatchedStart, unmatchedEnd,
+                    matchItemIds(unmatchedStart, unmatchedEnd,
                             startValues.itemIdValues, endValues.itemIdValues);
                     break;
             }
         }
-        addUnmatched(startValuesList, endValuesList, unmatchedStart, unmatchedEnd);
+        addUnmatched(unmatchedStart, unmatchedEnd);
     }
 
     /**
@@ -687,26 +677,31 @@
      * @hide
      */
     protected void createAnimators(ViewGroup sceneRoot, TransitionValuesMaps startValues,
-            TransitionValuesMaps endValues) {
+            TransitionValuesMaps endValues, ArrayList<TransitionValues> startValuesList,
+            ArrayList<TransitionValues> endValuesList) {
         if (DBG) {
             Log.d(LOG_TAG, "createAnimators() for " + this);
         }
-        ArrayList<TransitionValues> startValuesList = new ArrayList<TransitionValues>();
-        ArrayList<TransitionValues> endValuesList = new ArrayList<TransitionValues>();
-        matchStartAndEnd(startValues, endValues, startValuesList, endValuesList);
-
         ArrayMap<Animator, AnimationInfo> runningAnimators = getRunningAnimators();
         long minStartDelay = Long.MAX_VALUE;
         int minAnimator = mAnimators.size();
         SparseLongArray startDelays = new SparseLongArray();
-        for (int i = 0; i < startValuesList.size(); ++i) {
+        int startValuesListCount = startValuesList.size();
+        for (int i = 0; i < startValuesListCount; ++i) {
             TransitionValues start = startValuesList.get(i);
             TransitionValues end = endValuesList.get(i);
-            // Only bother trying to animate with valid values that differ between start/end
-            boolean isInvalidStart = start != null && !isValidTarget(start.view);
-            boolean isInvalidEnd = end != null && !isValidTarget(end.view);
-            boolean isChanged = start != end && (start == null || !start.equals(end));
-            if (isChanged && !isInvalidStart && !isInvalidEnd) {
+            if (start != null && !start.targetedTransitions.contains(this)) {
+                start = null;
+            }
+            if (end != null && !end.targetedTransitions.contains(this)) {
+                end = null;
+            }
+            if (start == null && end == null) {
+                continue;
+            }
+            // Only bother trying to animate with values that differ between start/end
+            boolean isChanged = start == null || end == null || areValuesChanged(start, end);
+            if (isChanged) {
                 if (DBG) {
                     View view = (end != null) ? end.view : start.view;
                     Log.d(LOG_TAG, "  differing start/end values for view " + view);
@@ -1427,6 +1422,7 @@
                     } else {
                         captureEndValues(values);
                     }
+                    values.targetedTransitions.add(this);
                     capturePropagationValues(values);
                     if (start) {
                         addViewValues(mStartValues, view, values);
@@ -1444,6 +1440,7 @@
                 } else {
                     captureEndValues(values);
                 }
+                values.targetedTransitions.add(this);
                 capturePropagationValues(values);
                 if (start) {
                     mStartValues.viewValues.put(view, values);
@@ -1523,11 +1520,13 @@
             mStartValues.idValues.clear();
             mStartValues.itemIdValues.clear();
             mStartValues.nameValues.clear();
+            mStartValuesList = null;
         } else {
             mEndValues.viewValues.clear();
             mEndValues.idValues.clear();
             mEndValues.itemIdValues.clear();
             mEndValues.nameValues.clear();
+            mEndValuesList = null;
         }
     }
 
@@ -1568,6 +1567,7 @@
             } else {
                 captureEndValues(values);
             }
+            values.targetedTransitions.add(this);
             capturePropagationValues(values);
             if (start) {
                 addViewValues(mStartValues, view, values);
@@ -1613,6 +1613,45 @@
     }
 
     /**
+     * Find the matched start or end value for a given View. This is only valid
+     * after playTransition starts. For example, it will be valid in
+     * {@link #createAnimator(android.view.ViewGroup, TransitionValues, TransitionValues)}, but not
+     * in {@link #captureStartValues(TransitionValues)}.
+     *
+     * @param view The view to find the match for.
+     * @param viewInStart Is View from the start values or end values.
+     * @return The matching TransitionValues for view in either start or end values, depending
+     * on viewInStart or null if there is no match for the given view.
+     */
+    TransitionValues getMatchedTransitionValues(View view, boolean viewInStart) {
+        if (mParent != null) {
+            return mParent.getMatchedTransitionValues(view, viewInStart);
+        }
+        ArrayList<TransitionValues> lookIn = viewInStart ? mStartValuesList : mEndValuesList;
+        if (lookIn == null) {
+            return null;
+        }
+        int count = lookIn.size();
+        int index = -1;
+        for (int i = 0; i < count; i++) {
+            TransitionValues values = lookIn.get(i);
+            if (values == null) {
+                return null;
+            }
+            if (values.view == view) {
+                index = i;
+                break;
+            }
+        }
+        TransitionValues values = null;
+        if (index >= 0) {
+            ArrayList<TransitionValues> matchIn = viewInStart ? mEndValuesList : mStartValuesList;
+            values = matchIn.get(index);
+        }
+        return values;
+    }
+
+    /**
      * Pauses this transition, sending out calls to {@link
      * TransitionListener#onTransitionPause(Transition)} to all listeners
      * and pausing all running animators started by this transition.
@@ -1627,7 +1666,7 @@
                 WindowId windowId = sceneRoot.getWindowId();
                 for (int i = numOldAnims - 1; i >= 0; i--) {
                     AnimationInfo info = runningAnimators.valueAt(i);
-                    if (info.view != null && windowId.equals(info.windowId)) {
+                    if (info.view != null && windowId != null && windowId.equals(info.windowId)) {
                         Animator anim = runningAnimators.keyAt(i);
                         anim.pause();
                     }
@@ -1660,7 +1699,7 @@
                 WindowId windowId = sceneRoot.getWindowId();
                 for (int i = numOldAnims - 1; i >= 0; i--) {
                     AnimationInfo info = runningAnimators.valueAt(i);
-                    if (info.view != null && windowId.equals(info.windowId)) {
+                    if (info.view != null && windowId != null && windowId.equals(info.windowId)) {
                         Animator anim = runningAnimators.keyAt(i);
                         anim.resume();
                     }
@@ -1684,6 +1723,10 @@
      * runAnimations() to actually start the animations.
      */
     void playTransition(ViewGroup sceneRoot) {
+        mStartValuesList = new ArrayList<TransitionValues>();
+        mEndValuesList = new ArrayList<TransitionValues>();
+        matchStartAndEnd(mStartValues, mEndValues);
+
         ArrayMap<Animator, AnimationInfo> runningAnimators = getRunningAnimators();
         int numOldAnims = runningAnimators.size();
         WindowId windowId = sceneRoot.getWindowId();
@@ -1694,8 +1737,10 @@
                 if (oldInfo != null && oldInfo.view != null && oldInfo.windowId == windowId) {
                     TransitionValues oldValues = oldInfo.values;
                     View oldView = oldInfo.view;
-                    TransitionValues newValues = mEndValues.viewValues.get(oldView);
-                    boolean cancel = oldInfo.transition.areValuesChanged(oldValues, newValues);
+                    TransitionValues startValues = getTransitionValues(oldView, true);
+                    TransitionValues endValues = getMatchedTransitionValues(oldView, true);
+                    boolean cancel = (startValues != null || endValues != null) &&
+                            oldInfo.transition.areValuesChanged(oldValues, endValues);
                     if (cancel) {
                         if (anim.isRunning() || anim.isStarted()) {
                             if (DBG) {
@@ -1713,7 +1758,7 @@
             }
         }
 
-        createAnimators(sceneRoot, mStartValues, mEndValues);
+        createAnimators(sceneRoot, mStartValues, mEndValues, mStartValuesList, mEndValuesList);
         runAnimators();
     }
 
@@ -1722,24 +1767,50 @@
         // if oldValues null, then transition didn't care to stash values,
         // and won't get canceled
         if (oldValues != null && newValues != null) {
-            for (String key : oldValues.values.keySet()) {
-                Object oldValue = oldValues.values.get(key);
-                Object newValue = newValues.values.get(key);
-                if (oldValue != null && newValue != null &&
-                        !oldValue.equals(newValue)) {
-                    valuesChanged = true;
-                    if (DBG) {
-                        Log.d(LOG_TAG, "Transition.playTransition: " +
-                                "oldValue != newValue for " + key +
-                                ": old, new = " + oldValue + ", " + newValue);
+            String[] properties = getTransitionProperties();
+            if (properties != null) {
+                int count = properties.length;
+                for (int i = 0; i < count; i++) {
+                    if (isValueChanged(oldValues, newValues, properties[i])) {
+                        valuesChanged = true;
+                        break;
                     }
-                    break;
+                }
+            } else {
+                for (String key : oldValues.values.keySet()) {
+                    if (isValueChanged(oldValues, newValues, key)) {
+                        valuesChanged = true;
+                        break;
+                    }
                 }
             }
         }
         return valuesChanged;
     }
 
+    private static boolean isValueChanged(TransitionValues oldValues, TransitionValues newValues,
+            String key) {
+        Object oldValue = oldValues.values.get(key);
+        Object newValue = newValues.values.get(key);
+        boolean changed;
+        if (oldValue == null && newValue == null) {
+            // both are null
+            changed = false;
+        } else if (oldValue == null || newValue == null) {
+            // one is null
+            changed = true;
+        } else {
+            // neither is null
+            changed = !oldValue.equals(newValue);
+        }
+        if (DBG && changed) {
+            Log.d(LOG_TAG, "Transition.playTransition: " +
+                    "oldValue != newValue for " + key +
+                    ": old, new = " + oldValue + ", " + newValue);
+        }
+        return changed;
+    }
+
     /**
      * This is a utility method used by subclasses to handle standard parts of
      * setting up and running an Animator: it sets the {@link #getDuration()
@@ -1940,8 +2011,33 @@
      *     by extending PathMotion and implementing
      *     {@link android.transition.PathMotion#getPath(float, float, float, float)}.
      * </p>
+     * <p>
+     *     When describing in XML, use a nested XML tag for the path motion. It can be one of
+     *     the built-in tags <code>arcMotion</code> or <code>patternPathMotion</code> or it can
+     *     be a custom PathMotion using <code>pathMotion</code> with the <code>class</code>
+     *     attributed with the fully-described class name. For example:</p>
+     * <pre>
+     * {@code
+     * &lt;changeBounds>
+     *     &lt;pathMotion class="my.app.transition.MyPathMotion"/>
+     * &lt;/changeBounds>
+     * }
+     * </pre>
+     * <p>or</p>
+     * <pre>
+     * {@code
+     * &lt;changeBounds>
+     *   &lt;arcMotion android:minimumHorizontalAngle="15"
+     *     android:minimumVerticalAngle="0" android:maximumAngle="90"/>
+     * &lt;/changeBounds>
+     * }
+     * </pre>
+     *
      * @param pathMotion Algorithm object to use for determining how to interpolate in two
      *                   dimensions. If null, a straight-path algorithm will be used.
+     * @see android.transition.ArcMotion
+     * @see PatternPathMotion
+     * @see android.transition.PathMotion
      */
     public void setPathMotion(PathMotion pathMotion) {
         if (pathMotion == null) {
@@ -1955,7 +2051,31 @@
      * Returns the algorithm object used to interpolate along two dimensions. This is typically
      * used to determine the View motion between two points.
      *
+     * <p>
+     *     When describing in XML, use a nested XML tag for the path motion. It can be one of
+     *     the built-in tags <code>arcMotion</code> or <code>patternPathMotion</code> or it can
+     *     be a custom PathMotion using <code>pathMotion</code> with the <code>class</code>
+     *     attributed with the fully-described class name. For example:</p>
+     * <pre>
+     * {@code
+     * &lt;changeBounds>
+     *     &lt;pathMotion class="my.app.transition.MyPathMotion"/>
+     * &lt;/changeBounds>}
+     * </pre>
+     * <p>or</p>
+     * <pre>
+     * {@code
+     * &lt;changeBounds>
+     *   &lt;arcMotion android:minimumHorizontalAngle="15"
+     *              android:minimumVerticalAngle="0"
+     *              android:maximumAngle="90"/>
+     * &lt;/changeBounds>}
+     * </pre>
+     *
      * @return The algorithm object used to interpolate along two dimensions.
+     * @see android.transition.ArcMotion
+     * @see PatternPathMotion
+     * @see android.transition.PathMotion
      */
     public PathMotion getPathMotion() {
         return mPathMotion;
@@ -2055,6 +2175,8 @@
             clone.mAnimators = new ArrayList<Animator>();
             clone.mStartValues = new TransitionValuesMaps();
             clone.mEndValues = new TransitionValuesMaps();
+            clone.mStartValuesList = null;
+            clone.mEndValuesList = null;
         } catch (CloneNotSupportedException e) {}
 
         return clone;
diff --git a/core/java/android/transition/TransitionInflater.java b/core/java/android/transition/TransitionInflater.java
index 760ffe1..9009d6a 100644
--- a/core/java/android/transition/TransitionInflater.java
+++ b/core/java/android/transition/TransitionInflater.java
@@ -171,8 +171,8 @@
                 parent.setPathMotion(new ArcMotion(mContext, attrs));
             } else if ("pathMotion".equals(name)) {
                 parent.setPathMotion((PathMotion)createCustom(attrs, PathMotion.class, "pathMotion"));
-            } else if ("patternMotion".equals(name)) {
-                parent.setPathMotion(new PatternMotion(mContext, attrs));
+            } else if ("patternPathMotion".equals(name)) {
+                parent.setPathMotion(new PatternPathMotion(mContext, attrs));
             } else {
                 throw new RuntimeException("Unknown scene name: " + parser.getName());
             }
diff --git a/core/java/android/transition/TransitionManager.java b/core/java/android/transition/TransitionManager.java
index ce3cc2f..7bd6287 100644
--- a/core/java/android/transition/TransitionManager.java
+++ b/core/java/android/transition/TransitionManager.java
@@ -182,11 +182,15 @@
 
         final ViewGroup sceneRoot = scene.getSceneRoot();
 
-        Transition transitionClone = transition.clone();
-        transitionClone.setSceneRoot(sceneRoot);
+        Transition transitionClone = null;
+        if (transition != null) {
+            transitionClone = transition.clone();
+            transitionClone.setSceneRoot(sceneRoot);
+        }
 
         Scene oldScene = Scene.getCurrentScene(sceneRoot);
-        if (oldScene != null && oldScene.isCreatedFromLayoutResource()) {
+        if (oldScene != null && transitionClone != null &&
+                oldScene.isCreatedFromLayoutResource()) {
             transitionClone.setCanRemoveViews(true);
         }
 
diff --git a/core/java/android/transition/TransitionSet.java b/core/java/android/transition/TransitionSet.java
index 83c60af..09d2c69 100644
--- a/core/java/android/transition/TransitionSet.java
+++ b/core/java/android/transition/TransitionSet.java
@@ -151,6 +151,31 @@
     }
 
     /**
+     * Returns the number of child transitions in the TransitionSet.
+     *
+     * @return The number of child transitions in the TransitionSet.
+     * @see #addTransition(Transition)
+     * @see #getTransitionAt(int)
+     */
+    public int getTransitionCount() {
+        return mTransitions.size();
+    }
+
+    /**
+     * Returns the child Transition at the specified position in the TransitionSet.
+     *
+     * @param index The position of the Transition to retrieve.
+     * @see #addTransition(Transition)
+     * @see #getTransitionCount()
+     */
+    public Transition getTransitionAt(int index) {
+        if (index < 0 || index >= mTransitions.size()) {
+            return null;
+        }
+        return mTransitions.get(index);
+    }
+
+    /**
      * Setting a non-negative duration on a TransitionSet causes all of the child
      * transitions (current and future) to inherit this duration.
      *
@@ -361,30 +386,25 @@
      */
     @Override
     protected void createAnimators(ViewGroup sceneRoot, TransitionValuesMaps startValues,
-            TransitionValuesMaps endValues) {
-        startValues = removeExcludes(startValues);
-        endValues = removeExcludes(endValues);
-        for (Transition childTransition : mTransitions) {
-            childTransition.createAnimators(sceneRoot, startValues, endValues);
-        }
-    }
-
-    private TransitionValuesMaps removeExcludes(TransitionValuesMaps values) {
-        if (mTargetIds.isEmpty() && mTargetIdExcludes == null && mTargetTypeExcludes == null
-                && mTargetNames == null && mTargetTypes == null
-                && mTargetExcludes == null && mTargetNameExcludes == null
-                && mTargets.isEmpty()) {
-            return values;
-        }
-        TransitionValuesMaps included = new TransitionValuesMaps();
-        int numValues = values.viewValues.size();
-        for (int i = 0; i < numValues; i++) {
-            View view = values.viewValues.keyAt(i);
-            if (isValidTarget(view)) {
-                addViewValues(included, view, values.viewValues.valueAt(i));
+            TransitionValuesMaps endValues, ArrayList<TransitionValues> startValuesList,
+            ArrayList<TransitionValues> endValuesList) {
+        long startDelay = getStartDelay();
+        int numTransitions = mTransitions.size();
+        for (int i = 0; i < numTransitions; i++) {
+            Transition childTransition = mTransitions.get(i);
+            // We only set the start delay on the first transition if we are playing
+            // the transitions sequentially.
+            if (startDelay > 0 && (mPlayTogether || i == 0)) {
+                long childStartDelay = childTransition.getStartDelay();
+                if (childStartDelay > 0) {
+                    childTransition.setStartDelay(startDelay + childStartDelay);
+                } else {
+                    childTransition.setStartDelay(startDelay);
+                }
             }
+            childTransition.createAnimators(sceneRoot, startValues, endValues, startValuesList,
+                    endValuesList);
         }
-        return included;
     }
 
     /**
@@ -392,11 +412,17 @@
      */
     @Override
     protected void runAnimators() {
+        if (mTransitions.isEmpty()) {
+            start();
+            end();
+            return;
+        }
         setupStartEndListeners();
+        int numTransitions = mTransitions.size();
         if (!mPlayTogether) {
             // Setup sequence with listeners
             // TODO: Need to add listeners in such a way that we can remove them later if canceled
-            for (int i = 1; i < mTransitions.size(); ++i) {
+            for (int i = 1; i < numTransitions; ++i) {
                 Transition previousTransition = mTransitions.get(i - 1);
                 final Transition nextTransition = mTransitions.get(i);
                 previousTransition.addListener(new TransitionListenerAdapter() {
@@ -412,8 +438,8 @@
                 firstTransition.runAnimators();
             }
         } else {
-            for (Transition childTransition : mTransitions) {
-                childTransition.runAnimators();
+            for (int i = 0; i < numTransitions; ++i) {
+                mTransitions.get(i).runAnimators();
             }
         }
     }
@@ -424,6 +450,7 @@
             for (Transition childTransition : mTransitions) {
                 if (childTransition.isValidTarget(transitionValues.view)) {
                     childTransition.captureStartValues(transitionValues);
+                    transitionValues.targetedTransitions.add(childTransition);
                 }
             }
         }
@@ -435,6 +462,7 @@
             for (Transition childTransition : mTransitions) {
                 if (childTransition.isValidTarget(transitionValues.view)) {
                     childTransition.captureEndValues(transitionValues);
+                    transitionValues.targetedTransitions.add(childTransition);
                 }
             }
         }
diff --git a/core/java/android/transition/TransitionUtils.java b/core/java/android/transition/TransitionUtils.java
index 931d46a..03423ff 100644
--- a/core/java/android/transition/TransitionUtils.java
+++ b/core/java/android/transition/TransitionUtils.java
@@ -18,6 +18,15 @@
 
 import android.animation.Animator;
 import android.animation.AnimatorSet;
+import android.animation.TypeEvaluator;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Matrix;
+import android.graphics.RectF;
+import android.graphics.drawable.BitmapDrawable;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.ImageView;
 
 /**
  * Static utility methods for Transitions.
@@ -25,6 +34,7 @@
  * @hide
  */
 public class TransitionUtils {
+    private static int MAX_IMAGE_SIZE = (1024 * 1024);
 
     static Animator mergeAnimators(Animator animator1, Animator animator2) {
         if (animator1 == null) {
@@ -37,4 +47,116 @@
             return animatorSet;
         }
     }
+
+    public static Transition mergeTransitions(Transition... transitions) {
+        int count = 0;
+        int nonNullIndex = -1;
+        for (int i = 0; i < transitions.length; i++) {
+            if (transitions[i] != null) {
+                count++;
+                nonNullIndex = i;
+            }
+        }
+
+        if (count == 0) {
+            return null;
+        }
+
+        if (count == 1) {
+            return transitions[nonNullIndex];
+        }
+
+        TransitionSet transitionSet = new TransitionSet();
+        for (int i = 0; i < transitions.length; i++) {
+            if (transitions[i] != null) {
+                transitionSet.addTransition(transitions[i]);
+            }
+        }
+        return transitionSet;
+    }
+
+    /**
+     * Creates a View using the bitmap copy of <code>view</code>. If <code>view</code> is large,
+     * the copy will use a scaled bitmap of the given view.
+     *
+     * @param sceneRoot The ViewGroup in which the view copy will be displayed.
+     * @param view The view to create a copy of.
+     * @param parent The parent of view.
+     */
+    public static View copyViewImage(ViewGroup sceneRoot, View view, View parent) {
+        Matrix matrix = new Matrix();
+        matrix.setTranslate(-parent.getScrollX(), -parent.getScrollY());
+        view.transformMatrixToGlobal(matrix);
+        sceneRoot.transformMatrixToLocal(matrix);
+        RectF bounds = new RectF(0, 0, view.getWidth(), view.getHeight());
+        matrix.mapRect(bounds);
+        int left = Math.round(bounds.left);
+        int top = Math.round(bounds.top);
+        int right = Math.round(bounds.right);
+        int bottom = Math.round(bounds.bottom);
+
+        ImageView copy = new ImageView(view.getContext());
+        copy.setScaleType(ImageView.ScaleType.CENTER_CROP);
+        Bitmap bitmap = createViewBitmap(view, matrix, bounds);
+        if (bitmap != null) {
+            copy.setImageBitmap(bitmap);
+        }
+        int widthSpec = View.MeasureSpec.makeMeasureSpec(right - left, View.MeasureSpec.EXACTLY);
+        int heightSpec = View.MeasureSpec.makeMeasureSpec(bottom - top, View.MeasureSpec.EXACTLY);
+        copy.measure(widthSpec, heightSpec);
+        copy.layout(left, top, right, bottom);
+        return copy;
+    }
+
+    /**
+     * Creates a Bitmap of the given view, using the Matrix matrix to transform to the local
+     * coordinates. <code>matrix</code> will be modified during the bitmap creation.
+     *
+     * <p>If the bitmap is large, it will be scaled uniformly down to at most 1MB size.</p>
+     * @param view The view to create a bitmap for.
+     * @param matrix The matrix converting the view local coordinates to the coordinates that
+     *               the bitmap will be displayed in. <code>matrix</code> will be modified before
+     *               returning.
+     * @param bounds The bounds of the bitmap in the destination coordinate system (where the
+     *               view should be presented. Typically, this is matrix.mapRect(viewBounds);
+     * @return A bitmap of the given view or null if bounds has no width or height.
+     */
+    public static Bitmap createViewBitmap(View view, Matrix matrix, RectF bounds) {
+        Bitmap bitmap = null;
+        int bitmapWidth = Math.round(bounds.width());
+        int bitmapHeight = Math.round(bounds.height());
+        if (bitmapWidth > 0 && bitmapHeight > 0) {
+            float scale = Math.min(1f, ((float)MAX_IMAGE_SIZE) / (bitmapWidth * bitmapHeight));
+            bitmapWidth *= scale;
+            bitmapHeight *= scale;
+            matrix.postTranslate(-bounds.left, -bounds.top);
+            matrix.postScale(scale, scale);
+            bitmap = Bitmap.createBitmap(bitmapWidth, bitmapHeight, Bitmap.Config.ARGB_8888);
+            Canvas canvas = new Canvas(bitmap);
+            canvas.concat(matrix);
+            view.draw(canvas);
+        }
+        return bitmap;
+    }
+
+    public static class MatrixEvaluator implements TypeEvaluator<Matrix> {
+
+        float[] mTempStartValues = new float[9];
+
+        float[] mTempEndValues = new float[9];
+
+        Matrix mTempMatrix = new Matrix();
+
+        @Override
+        public Matrix evaluate(float fraction, Matrix startValue, Matrix endValue) {
+            startValue.getValues(mTempStartValues);
+            endValue.getValues(mTempEndValues);
+            for (int i = 0; i < 9; i++) {
+                float diff = mTempEndValues[i] - mTempStartValues[i];
+                mTempEndValues[i] = mTempStartValues[i] + (fraction * diff);
+            }
+            mTempMatrix.setValues(mTempEndValues);
+            return mTempMatrix;
+        }
+    }
 }
diff --git a/core/java/android/transition/TransitionValues.java b/core/java/android/transition/TransitionValues.java
index 8989f89..11f2962 100644
--- a/core/java/android/transition/TransitionValues.java
+++ b/core/java/android/transition/TransitionValues.java
@@ -20,6 +20,7 @@
 import android.view.View;
 import android.view.ViewGroup;
 
+import java.util.ArrayList;
 import java.util.Map;
 
 /**
@@ -52,6 +53,11 @@
      */
     public final Map<String, Object> values = new ArrayMap<String, Object>();
 
+    /**
+     * The Transitions that targeted this view.
+     */
+    final ArrayList<Transition> targetedTransitions = new ArrayList<Transition>();
+
     @Override
     public boolean equals(Object other) {
         if (other instanceof TransitionValues) {
diff --git a/core/java/android/transition/Visibility.java b/core/java/android/transition/Visibility.java
index 79dbb49..f58291f 100644
--- a/core/java/android/transition/Visibility.java
+++ b/core/java/android/transition/Visibility.java
@@ -63,8 +63,6 @@
 
     private static final String[] sTransitionProperties = {
             PROPNAME_VISIBILITY,
-            PROPNAME_PARENT,
-            PROPNAME_SCREEN_LOCATION,
     };
 
     private static class VisibilityInfo {
@@ -86,7 +84,7 @@
     public Visibility(Context context, AttributeSet attrs) {
         super(context, attrs);
         TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.VisibilityTransition);
-        int mode = a.getInt(R.styleable.VisibilityTransition_visibilityMode, 0);
+        int mode = a.getInt(R.styleable.VisibilityTransition_transitionVisibilityMode, 0);
         a.recycle();
         if (mode != 0) {
             setMode(mode);
@@ -99,7 +97,7 @@
      *
      * @param mode The behavior supported by this transition, a combination of
      *             {@link #MODE_IN} and {@link #MODE_OUT}.
-     * @attr ref android.R.styleable#VisibilityTransition_visibilityMode
+     * @attr ref android.R.styleable#VisibilityTransition_transitionVisibilityMode
      */
     public void setMode(int mode) {
         if ((mode & ~(MODE_IN | MODE_OUT)) != 0) {
@@ -113,7 +111,7 @@
      *
      * Returns whether appearing and/or disappearing Views are supported. A combination of
      *         {@link #MODE_IN} and {@link #MODE_OUT}.
-     * @attr ref android.R.styleable#VisibilityTransition_visibilityMode
+     * @attr ref android.R.styleable#VisibilityTransition_transitionVisibilityMode
      */
     public int getMode() {
         return mMode;
@@ -226,11 +224,10 @@
                     }
                 }
             }
-        }
-        if (startValues == null) {
+        } else if (startValues == null && visInfo.endVisibility == View.VISIBLE) {
             visInfo.fadeIn = true;
             visInfo.visibilityChange = true;
-        } else if (endValues == null) {
+        } else if (endValues == null && visInfo.startVisibility == View.VISIBLE) {
             visInfo.fadeIn = false;
             visInfo.visibilityChange = true;
         }
@@ -279,6 +276,18 @@
         if ((mMode & MODE_IN) != MODE_IN || endValues == null) {
             return null;
         }
+        if (startValues == null) {
+            VisibilityInfo parentVisibilityInfo = null;
+            View endParent = (View) endValues.view.getParent();
+            TransitionValues startParentValues = getMatchedTransitionValues(endParent,
+                                                                            false);
+            TransitionValues endParentValues = getTransitionValues(endParent, false);
+            parentVisibilityInfo =
+                getVisibilityChangeInfo(startParentValues, endParentValues);
+            if (parentVisibilityInfo.visibilityChange) {
+                return null;
+            }
+        }
         return onAppear(sceneRoot, endValues.view, startValues, endValues);
     }
 
@@ -360,12 +369,14 @@
                     overlayView = startView;
                 } else if (startView.getParent() instanceof View) {
                     View startParent = (View) startView.getParent();
-                    if (!isValidTarget(startParent)) {
-                        if (startView.isAttachedToWindow()) {
-                            overlayView = copyViewImage(startView);
-                        } else {
-                            overlayView = startView;
-                        }
+                    TransitionValues startParentValues = getTransitionValues(startParent, true);
+                    TransitionValues endParentValues = getMatchedTransitionValues(startParent,
+                            true);
+                    VisibilityInfo parentVisibilityInfo =
+                            getVisibilityChangeInfo(startParentValues, endParentValues);
+                    if (!parentVisibilityInfo.visibilityChange) {
+                        overlayView = TransitionUtils.copyViewImage(sceneRoot, startView,
+                                startParent);
                     } else if (startParent.getParent() == null) {
                         int id = startParent.getId();
                         if (id != View.NO_ID && sceneRoot.findViewById(id) != null
@@ -471,26 +482,6 @@
         return null;
     }
 
-    private View copyViewImage(View view) {
-        int width = view.getWidth();
-        int height = view.getHeight();
-        if (width <= 0 || height <= 0) {
-            return null;
-        }
-        Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
-        Canvas canvas = new Canvas(bitmap);
-        view.draw(canvas);
-        final BitmapDrawable drawable = new BitmapDrawable(bitmap);
-
-        View overlayView = new View(view.getContext());
-        overlayView.setBackground(drawable);
-        int widthSpec = View.MeasureSpec.makeMeasureSpec(width, View.MeasureSpec.EXACTLY);
-        int heightSpec = View.MeasureSpec.makeMeasureSpec(height, View.MeasureSpec.EXACTLY);
-        overlayView.measure(widthSpec, heightSpec);
-        overlayView.layout(0, 0, width, height);
-        return overlayView;
-    }
-
     @Override
     boolean areValuesChanged(TransitionValues oldValues, TransitionValues newValues) {
         VisibilityInfo changeInfo = getVisibilityChangeInfo(oldValues, newValues);
diff --git a/core/java/android/util/ArrayMap.java b/core/java/android/util/ArrayMap.java
index 3889cb6..7c9861f 100644
--- a/core/java/android/util/ArrayMap.java
+++ b/core/java/android/util/ArrayMap.java
@@ -323,7 +323,17 @@
      */
     @Override
     public boolean containsKey(Object key) {
-        return key == null ? (indexOfNull() >= 0) : (indexOf(key, key.hashCode()) >= 0);
+        return indexOfKey(key) >= 0;
+    }
+
+    /**
+     * Returns the index of a key in the set.
+     *
+     * @param key The key to search for.
+     * @return Returns the index of the key if it exists, else a negative integer.
+     */
+    public int indexOfKey(Object key) {
+        return key == null ? indexOfNull() : indexOf(key, key.hashCode());
     }
 
     int indexOfValue(Object value) {
@@ -365,7 +375,7 @@
      */
     @Override
     public V get(Object key) {
-        final int index = key == null ? indexOfNull() : indexOf(key, key.hashCode());
+        final int index = indexOfKey(key);
         return index >= 0 ? (V)mArray[(index<<1)+1] : null;
     }
 
@@ -561,7 +571,7 @@
      */
     @Override
     public V remove(Object key) {
-        int index = key == null ? indexOfNull() : indexOf(key, key.hashCode());
+        final int index = indexOfKey(key);
         if (index >= 0) {
             return removeAt(index);
         }
@@ -747,7 +757,7 @@
 
                 @Override
                 protected int colIndexOfKey(Object key) {
-                    return key == null ? indexOfNull() : indexOf(key, key.hashCode());
+                    return indexOfKey(key);
                 }
 
                 @Override
diff --git a/core/java/android/util/ArraySet.java b/core/java/android/util/ArraySet.java
index 8f7aefd..423e48b 100644
--- a/core/java/android/util/ArraySet.java
+++ b/core/java/android/util/ArraySet.java
@@ -291,7 +291,17 @@
      */
     @Override
     public boolean contains(Object key) {
-        return key == null ? (indexOfNull() >= 0) : (indexOf(key, key.hashCode()) >= 0);
+        return indexOf(key) >= 0;
+    }
+
+    /**
+     * Returns the index of a value in the set.
+     *
+     * @param key The value to search for.
+     * @return Returns the index of the value if it exists, else a negative integer.
+     */
+    public int indexOf(Object key) {
+        return key == null ? indexOfNull() : indexOf(key, key.hashCode());
     }
 
     /**
@@ -396,7 +406,7 @@
      */
     @Override
     public boolean remove(Object object) {
-        int index = object == null ? indexOfNull() : indexOf(object, object.hashCode());
+        final int index = indexOf(object);
         if (index >= 0) {
             removeAt(index);
             return true;
@@ -586,12 +596,12 @@
 
                 @Override
                 protected int colIndexOfKey(Object key) {
-                    return key == null ? indexOfNull() : indexOf(key, key.hashCode());
+                    return indexOf(key);
                 }
 
                 @Override
                 protected int colIndexOfValue(Object value) {
-                    return value == null ? indexOfNull() : indexOf(value, value.hashCode());
+                    return indexOf(value);
                 }
 
                 @Override
diff --git a/core/java/android/util/Log.java b/core/java/android/util/Log.java
index 2b81072..a9b3571 100644
--- a/core/java/android/util/Log.java
+++ b/core/java/android/util/Log.java
@@ -96,12 +96,12 @@
      * @hide
      */
     public interface TerribleFailureHandler {
-        void onTerribleFailure(String tag, TerribleFailure what);
+        void onTerribleFailure(String tag, TerribleFailure what, boolean system);
     }
 
     private static TerribleFailureHandler sWtfHandler = new TerribleFailureHandler() {
-            public void onTerribleFailure(String tag, TerribleFailure what) {
-                RuntimeInit.wtf(tag, what);
+            public void onTerribleFailure(String tag, TerribleFailure what, boolean system) {
+                RuntimeInit.wtf(tag, what, system);
             }
         };
 
@@ -253,7 +253,7 @@
      * @param msg The message you would like logged.
      */
     public static int wtf(String tag, String msg) {
-        return wtf(LOG_ID_MAIN, tag, msg, null, false);
+        return wtf(LOG_ID_MAIN, tag, msg, null, false, false);
     }
 
     /**
@@ -262,7 +262,7 @@
      * @hide
      */
     public static int wtfStack(String tag, String msg) {
-        return wtf(LOG_ID_MAIN, tag, msg, null, true);
+        return wtf(LOG_ID_MAIN, tag, msg, null, true, false);
     }
 
     /**
@@ -272,7 +272,7 @@
      * @param tr An exception to log.
      */
     public static int wtf(String tag, Throwable tr) {
-        return wtf(LOG_ID_MAIN, tag, tr.getMessage(), tr, false);
+        return wtf(LOG_ID_MAIN, tag, tr.getMessage(), tr, false, false);
     }
 
     /**
@@ -283,14 +283,15 @@
      * @param tr An exception to log.  May be null.
      */
     public static int wtf(String tag, String msg, Throwable tr) {
-        return wtf(LOG_ID_MAIN, tag, msg, tr, false);
+        return wtf(LOG_ID_MAIN, tag, msg, tr, false, false);
     }
 
-    static int wtf(int logId, String tag, String msg, Throwable tr, boolean localStack) {
+    static int wtf(int logId, String tag, String msg, Throwable tr, boolean localStack,
+            boolean system) {
         TerribleFailure what = new TerribleFailure(msg, tr);
         int bytes = println_native(logId, ASSERT, tag, msg + '\n'
                 + getStackTraceString(localStack ? what : tr));
-        sWtfHandler.onTerribleFailure(tag, what);
+        sWtfHandler.onTerribleFailure(tag, what, system);
         return bytes;
     }
 
diff --git a/core/java/android/util/Size.java b/core/java/android/util/Size.java
index d58f778..62df564 100644
--- a/core/java/android/util/Size.java
+++ b/core/java/android/util/Size.java
@@ -16,7 +16,7 @@
 
 package android.util;
 
-import static com.android.internal.util.Preconditions.*;
+import static com.android.internal.util.Preconditions.checkNotNull;
 
 /**
  * Immutable class for describing width and height dimensions in pixels.
@@ -149,4 +149,4 @@
 
     private final int mWidth;
     private final int mHeight;
-};
+}
diff --git a/core/java/android/util/SizeF.java b/core/java/android/util/SizeF.java
index 0a8b4ed..2edc4a7f 100644
--- a/core/java/android/util/SizeF.java
+++ b/core/java/android/util/SizeF.java
@@ -16,7 +16,8 @@
 
 package android.util;
 
-import static com.android.internal.util.Preconditions.*;
+import static com.android.internal.util.Preconditions.checkNotNull;
+import static com.android.internal.util.Preconditions.checkArgumentFinite;
 
 /**
  * Immutable class for describing width and height dimensions in some arbitrary
@@ -95,6 +96,61 @@
         return mWidth + "x" + mHeight;
     }
 
+    private static NumberFormatException invalidSizeF(String s) {
+        throw new NumberFormatException("Invalid SizeF: \"" + s + "\"");
+    }
+
+    /**
+     * Parses the specified string as a size value.
+     * <p>
+     * The ASCII characters {@code \}{@code u002a} ('*') and
+     * {@code \}{@code u0078} ('x') are recognized as separators between
+     * the width and height.</p>
+     * <p>
+     * For any {@code SizeF s}: {@code SizeF.parseSizeF(s.toString()).equals(s)}.
+     * However, the method also handles sizes expressed in the
+     * following forms:</p>
+     * <p>
+     * "<i>width</i>{@code x}<i>height</i>" or
+     * "<i>width</i>{@code *}<i>height</i>" {@code => new SizeF(width, height)},
+     * where <i>width</i> and <i>height</i> are string floats potentially
+     * containing a sign, such as "-10.3", "+7" or "5.2", but not containing
+     * an {@code 'x'} (such as a float in hexadecimal string format).</p>
+     *
+     * <pre>{@code
+     * SizeF.parseSizeF("3.2*+6").equals(new SizeF(3.2f, 6.0f)) == true
+     * SizeF.parseSizeF("-3x-6").equals(new SizeF(-3.0f, -6.0f)) == true
+     * SizeF.parseSizeF("4 by 3") => throws NumberFormatException
+     * }</pre>
+     *
+     * @param string the string representation of a size value.
+     * @return the size value represented by {@code string}.
+     *
+     * @throws NumberFormatException if {@code string} cannot be parsed
+     * as a size value.
+     * @throws NullPointerException if {@code string} was {@code null}
+     */
+    public static SizeF parseSizeF(String string)
+            throws NumberFormatException {
+        checkNotNull(string, "string must not be null");
+
+        int sep_ix = string.indexOf('*');
+        if (sep_ix < 0) {
+            sep_ix = string.indexOf('x');
+        }
+        if (sep_ix < 0) {
+            throw invalidSizeF(string);
+        }
+        try {
+            return new SizeF(Float.parseFloat(string.substring(0, sep_ix)),
+                    Float.parseFloat(string.substring(sep_ix + 1)));
+        } catch (NumberFormatException e) {
+            throw invalidSizeF(string);
+        } catch (IllegalArgumentException e) {
+            throw invalidSizeF(string);
+        }
+    }
+
     /**
      * {@inheritDoc}
      */
@@ -105,4 +161,4 @@
 
     private final float mWidth;
     private final float mHeight;
-};
+}
diff --git a/core/java/android/util/Slog.java b/core/java/android/util/Slog.java
index b25d80f..7a5fd50 100644
--- a/core/java/android/util/Slog.java
+++ b/core/java/android/util/Slog.java
@@ -74,19 +74,19 @@
     }
 
     public static int wtf(String tag, String msg) {
-        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, null, false);
+        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, null, false, true);
     }
 
     public static int wtfStack(String tag, String msg) {
-        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, null, true);
+        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, null, true, true);
     }
 
     public static int wtf(String tag, Throwable tr) {
-        return Log.wtf(Log.LOG_ID_SYSTEM, tag, tr.getMessage(), tr, false);
+        return Log.wtf(Log.LOG_ID_SYSTEM, tag, tr.getMessage(), tr, false, true);
     }
 
     public static int wtf(String tag, String msg, Throwable tr) {
-        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, tr, false);
+        return Log.wtf(Log.LOG_ID_SYSTEM, tag, msg, tr, false, true);
     }
 
     public static int println(int priority, String tag, String msg) {
diff --git a/core/java/android/util/Spline.java b/core/java/android/util/Spline.java
index ed027eb..41a2e5d 100644
--- a/core/java/android/util/Spline.java
+++ b/core/java/android/util/Spline.java
@@ -20,15 +20,34 @@
  * Performs spline interpolation given a set of control points.
  * @hide
  */
-public final class Spline {
-    private final float[] mX;
-    private final float[] mY;
-    private final float[] mM;
+public abstract class Spline {
 
-    private Spline(float[] x, float[] y, float[] m) {
-        mX = x;
-        mY = y;
-        mM = m;
+    /**
+     * Interpolates the value of Y = f(X) for given X.
+     * Clamps X to the domain of the spline.
+     *
+     * @param x The X value.
+     * @return The interpolated Y = f(X) value.
+     */
+    public abstract float interpolate(float x);
+
+    /**
+     * Creates an appropriate spline based on the properties of the control points.
+     *
+     * If the control points are monotonic then the resulting spline will preserve that and
+     * otherwise optimize for error bounds.
+     */
+    public static Spline createSpline(float[] x, float[] y) {
+        if (!isStrictlyIncreasing(x)) {
+            throw new IllegalArgumentException("The control points must all have strictly "
+                    + "increasing X values.");
+        }
+
+        if (isMonotonic(y)) {
+            return createMonotoneCubicSpline(x, y);
+        } else {
+            return createLinearSpline(x, y);
+        }
     }
 
     /**
@@ -50,107 +69,229 @@
      * @throws IllegalArgumentException if the control points are not monotonic.
      */
     public static Spline createMonotoneCubicSpline(float[] x, float[] y) {
-        if (x == null || y == null || x.length != y.length || x.length < 2) {
-            throw new IllegalArgumentException("There must be at least two control "
-                    + "points and the arrays must be of equal length.");
-        }
-
-        final int n = x.length;
-        float[] d = new float[n - 1]; // could optimize this out
-        float[] m = new float[n];
-
-        // Compute slopes of secant lines between successive points.
-        for (int i = 0; i < n - 1; i++) {
-            float h = x[i + 1] - x[i];
-            if (h <= 0f) {
-                throw new IllegalArgumentException("The control points must all "
-                        + "have strictly increasing X values.");
-            }
-            d[i] = (y[i + 1] - y[i]) / h;
-        }
-
-        // Initialize the tangents as the average of the secants.
-        m[0] = d[0];
-        for (int i = 1; i < n - 1; i++) {
-            m[i] = (d[i - 1] + d[i]) * 0.5f;
-        }
-        m[n - 1] = d[n - 2];
-
-        // Update the tangents to preserve monotonicity.
-        for (int i = 0; i < n - 1; i++) {
-            if (d[i] == 0f) { // successive Y values are equal
-                m[i] = 0f;
-                m[i + 1] = 0f;
-            } else {
-                float a = m[i] / d[i];
-                float b = m[i + 1] / d[i];
-                if (a < 0f || b < 0f) {
-                    throw new IllegalArgumentException("The control points must have "
-                            + "monotonic Y values.");
-                }
-                float h = FloatMath.hypot(a, b);
-                if (h > 9f) {
-                    float t = 3f / h;
-                    m[i] = t * a * d[i];
-                    m[i + 1] = t * b * d[i];
-                }
-            }
-        }
-        return new Spline(x, y, m);
+        return new MonotoneCubicSpline(x, y);
     }
 
     /**
-     * Interpolates the value of Y = f(X) for given X.
-     * Clamps X to the domain of the spline.
+     * Creates a linear spline from a given set of control points.
      *
-     * @param x The X value.
-     * @return The interpolated Y = f(X) value.
+     * Like a monotone cubic spline, the interpolated curve will be monotonic if the control points
+     * are monotonic.
+     *
+     * @param x The X component of the control points, strictly increasing.
+     * @param y The Y component of the control points.
+     * @return
+     *
+     * @throws IllegalArgumentException if the X or Y arrays are null, have
+     * different lengths or have fewer than 2 values.
+     * @throws IllegalArgumentException if the X components of the control points are not strictly
+     * increasing.
      */
-    public float interpolate(float x) {
-        // Handle the boundary cases.
-        final int n = mX.length;
-        if (Float.isNaN(x)) {
-            return x;
-        }
-        if (x <= mX[0]) {
-            return mY[0];
-        }
-        if (x >= mX[n - 1]) {
-            return mY[n - 1];
-        }
-
-        // Find the index 'i' of the last point with smaller X.
-        // We know this will be within the spline due to the boundary tests.
-        int i = 0;
-        while (x >= mX[i + 1]) {
-            i += 1;
-            if (x == mX[i]) {
-                return mY[i];
-            }
-        }
-
-        // Perform cubic Hermite spline interpolation.
-        float h = mX[i + 1] - mX[i];
-        float t = (x - mX[i]) / h;
-        return (mY[i] * (1 + 2 * t) + h * mM[i] * t) * (1 - t) * (1 - t)
-                + (mY[i + 1] * (3 - 2 * t) + h * mM[i + 1] * (t - 1)) * t * t;
+    public static Spline createLinearSpline(float[] x, float[] y) {
+        return new LinearSpline(x, y);
     }
 
-    // For debugging.
-    @Override
-    public String toString() {
-        StringBuilder str = new StringBuilder();
-        final int n = mX.length;
-        str.append("[");
-        for (int i = 0; i < n; i++) {
-            if (i != 0) {
-                str.append(", ");
-            }
-            str.append("(").append(mX[i]);
-            str.append(", ").append(mY[i]);
-            str.append(": ").append(mM[i]).append(")");
+    private static boolean isStrictlyIncreasing(float[] x) {
+        if (x == null || x.length < 2) {
+            throw new IllegalArgumentException("There must be at least two control points.");
         }
-        str.append("]");
-        return str.toString();
+        float prev = x[0];
+        for (int i = 1; i < x.length; i++) {
+            float curr = x[i];
+            if (curr <= prev) {
+                return false;
+            }
+            prev = curr;
+        }
+        return true;
+    }
+
+    private static boolean isMonotonic(float[] x) {
+        if (x == null || x.length < 2) {
+            throw new IllegalArgumentException("There must be at least two control points.");
+        }
+        float prev = x[0];
+        for (int i = 1; i < x.length; i++) {
+            float curr = x[i];
+            if (curr < prev) {
+                return false;
+            }
+            prev = curr;
+        }
+        return true;
+    }
+
+    public static class MonotoneCubicSpline extends Spline {
+        private float[] mX;
+        private float[] mY;
+        private float[] mM;
+
+        public MonotoneCubicSpline(float[] x, float[] y) {
+            if (x == null || y == null || x.length != y.length || x.length < 2) {
+                throw new IllegalArgumentException("There must be at least two control "
+                        + "points and the arrays must be of equal length.");
+            }
+
+            final int n = x.length;
+            float[] d = new float[n - 1]; // could optimize this out
+            float[] m = new float[n];
+
+            // Compute slopes of secant lines between successive points.
+            for (int i = 0; i < n - 1; i++) {
+                float h = x[i + 1] - x[i];
+                if (h <= 0f) {
+                    throw new IllegalArgumentException("The control points must all "
+                            + "have strictly increasing X values.");
+                }
+                d[i] = (y[i + 1] - y[i]) / h;
+            }
+
+            // Initialize the tangents as the average of the secants.
+            m[0] = d[0];
+            for (int i = 1; i < n - 1; i++) {
+                m[i] = (d[i - 1] + d[i]) * 0.5f;
+            }
+            m[n - 1] = d[n - 2];
+
+            // Update the tangents to preserve monotonicity.
+            for (int i = 0; i < n - 1; i++) {
+                if (d[i] == 0f) { // successive Y values are equal
+                    m[i] = 0f;
+                    m[i + 1] = 0f;
+                } else {
+                    float a = m[i] / d[i];
+                    float b = m[i + 1] / d[i];
+                    if (a < 0f || b < 0f) {
+                        throw new IllegalArgumentException("The control points must have "
+                                + "monotonic Y values.");
+                    }
+                    float h = FloatMath.hypot(a, b);
+                    if (h > 9f) {
+                        float t = 3f / h;
+                        m[i] = t * a * d[i];
+                        m[i + 1] = t * b * d[i];
+                    }
+                }
+            }
+
+            mX = x;
+            mY = y;
+            mM = m;
+        }
+
+        @Override
+        public float interpolate(float x) {
+            // Handle the boundary cases.
+            final int n = mX.length;
+            if (Float.isNaN(x)) {
+                return x;
+            }
+            if (x <= mX[0]) {
+                return mY[0];
+            }
+            if (x >= mX[n - 1]) {
+                return mY[n - 1];
+            }
+
+            // Find the index 'i' of the last point with smaller X.
+            // We know this will be within the spline due to the boundary tests.
+            int i = 0;
+            while (x >= mX[i + 1]) {
+                i += 1;
+                if (x == mX[i]) {
+                    return mY[i];
+                }
+            }
+
+            // Perform cubic Hermite spline interpolation.
+            float h = mX[i + 1] - mX[i];
+            float t = (x - mX[i]) / h;
+            return (mY[i] * (1 + 2 * t) + h * mM[i] * t) * (1 - t) * (1 - t)
+                    + (mY[i + 1] * (3 - 2 * t) + h * mM[i + 1] * (t - 1)) * t * t;
+        }
+
+        // For debugging.
+        @Override
+        public String toString() {
+            StringBuilder str = new StringBuilder();
+            final int n = mX.length;
+            str.append("MonotoneCubicSpline{[");
+            for (int i = 0; i < n; i++) {
+                if (i != 0) {
+                    str.append(", ");
+                }
+                str.append("(").append(mX[i]);
+                str.append(", ").append(mY[i]);
+                str.append(": ").append(mM[i]).append(")");
+            }
+            str.append("]}");
+            return str.toString();
+        }
+    }
+
+    public static class LinearSpline extends Spline {
+        private final float[] mX;
+        private final float[] mY;
+        private final float[] mM;
+
+        public LinearSpline(float[] x, float[] y) {
+            if (x == null || y == null || x.length != y.length || x.length < 2) {
+                throw new IllegalArgumentException("There must be at least two control "
+                        + "points and the arrays must be of equal length.");
+            }
+            final int N = x.length;
+            mM = new float[N-1];
+            for (int i = 0; i < N-1; i++) {
+                mM[i] = (y[i+1] - y[i]) / (x[i+1] - x[i]);
+            }
+            mX = x;
+            mY = y;
+        }
+
+        @Override
+        public float interpolate(float x) {
+            // Handle the boundary cases.
+            final int n = mX.length;
+            if (Float.isNaN(x)) {
+                return x;
+            }
+            if (x <= mX[0]) {
+                return mY[0];
+            }
+            if (x >= mX[n - 1]) {
+                return mY[n - 1];
+            }
+
+            // Find the index 'i' of the last point with smaller X.
+            // We know this will be within the spline due to the boundary tests.
+            int i = 0;
+            while (x >= mX[i + 1]) {
+                i += 1;
+                if (x == mX[i]) {
+                    return mY[i];
+                }
+            }
+            return mY[i] + mM[i] * (x - mX[i]);
+        }
+
+        @Override
+        public String toString() {
+            StringBuilder str = new StringBuilder();
+            final int n = mX.length;
+            str.append("LinearSpline{[");
+            for (int i = 0; i < n; i++) {
+                if (i != 0) {
+                    str.append(", ");
+                }
+                str.append("(").append(mX[i]);
+                str.append(", ").append(mY[i]);
+                if (i < n-1) {
+                    str.append(": ").append(mM[i]);
+                }
+                str.append(")");
+            }
+            str.append("]}");
+            return str.toString();
+        }
     }
 }
diff --git a/core/java/android/view/AccessibilityInteractionController.java b/core/java/android/view/AccessibilityInteractionController.java
index 477c994..a283b91 100644
--- a/core/java/android/view/AccessibilityInteractionController.java
+++ b/core/java/android/view/AccessibilityInteractionController.java
@@ -18,7 +18,7 @@
 
 import android.graphics.Point;
 import android.graphics.Rect;
-import android.os.Build;
+import android.graphics.Region;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.Looper;
@@ -96,11 +96,11 @@
     }
 
     public void findAccessibilityNodeInfoByAccessibilityIdClientThread(
-            long accessibilityNodeId, int interactionId,
+            long accessibilityNodeId, Region interactiveRegion, int interactionId,
             IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
             long interrogatingTid, MagnificationSpec spec) {
         Message message = mHandler.obtainMessage();
-        message.what = PrivateHandler.MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_ACCESSIBILITY_ID;
+        message.what = PrivateHandler.MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_ACCESSIBILITY_ID;
         message.arg1 = flags;
 
         SomeArgs args = SomeArgs.obtain();
@@ -109,6 +109,7 @@
         args.argi3 = interactionId;
         args.arg1 = callback;
         args.arg2 = spec;
+        args.arg3 = interactiveRegion;
         message.obj = args;
 
         // If the interrogation is performed by the same thread as the main UI
@@ -133,6 +134,7 @@
         final IAccessibilityInteractionConnectionCallback callback =
             (IAccessibilityInteractionConnectionCallback) args.arg1;
         final MagnificationSpec spec = (MagnificationSpec) args.arg2;
+        final Region interactiveRegion = (Region) args.arg3;
 
         args.recycle();
 
@@ -159,6 +161,7 @@
                 if (spec != null) {
                     spec.recycle();
                 }
+                adjustIsVisibleToUserIfNeeded(infos, interactiveRegion);
                 callback.setFindAccessibilityNodeInfosResult(infos, interactionId);
                 infos.clear();
             } catch (RemoteException re) {
@@ -168,10 +171,11 @@
     }
 
     public void findAccessibilityNodeInfosByViewIdClientThread(long accessibilityNodeId,
-            String viewId, int interactionId, IAccessibilityInteractionConnectionCallback callback,
-            int flags, int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
+            String viewId, Region interactiveRegion, int interactionId,
+            IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
+            long interrogatingTid, MagnificationSpec spec) {
         Message message = mHandler.obtainMessage();
-        message.what = PrivateHandler.MSG_FIND_ACCESSIBLITY_NODE_INFOS_BY_VIEW_ID;
+        message.what = PrivateHandler.MSG_FIND_ACCESSIBILITY_NODE_INFOS_BY_VIEW_ID;
         message.arg1 = flags;
         message.arg2 = AccessibilityNodeInfo.getAccessibilityViewId(accessibilityNodeId);
 
@@ -180,6 +184,7 @@
         args.arg1 = callback;
         args.arg2 = spec;
         args.arg3 = viewId;
+        args.arg4 = interactiveRegion;
 
         message.obj = args;
 
@@ -205,6 +210,7 @@
             (IAccessibilityInteractionConnectionCallback) args.arg1;
         final MagnificationSpec spec = (MagnificationSpec) args.arg2;
         final String viewId = (String) args.arg3;
+        final Region interactiveRegion = (Region) args.arg4;
 
         args.recycle();
 
@@ -241,6 +247,7 @@
                 if (spec != null) {
                     spec.recycle();
                 }
+                adjustIsVisibleToUserIfNeeded(infos, interactiveRegion);
                 callback.setFindAccessibilityNodeInfosResult(infos, interactionId);
             } catch (RemoteException re) {
                 /* ignore - the other side will time out */
@@ -249,10 +256,11 @@
     }
 
     public void findAccessibilityNodeInfosByTextClientThread(long accessibilityNodeId,
-            String text, int interactionId, IAccessibilityInteractionConnectionCallback callback,
-            int flags, int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
+            String text, Region interactiveRegion, int interactionId,
+            IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
+            long interrogatingTid, MagnificationSpec spec) {
         Message message = mHandler.obtainMessage();
-        message.what = PrivateHandler.MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_TEXT;
+        message.what = PrivateHandler.MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_TEXT;
         message.arg1 = flags;
 
         SomeArgs args = SomeArgs.obtain();
@@ -262,6 +270,7 @@
         args.argi1 = AccessibilityNodeInfo.getAccessibilityViewId(accessibilityNodeId);
         args.argi2 = AccessibilityNodeInfo.getVirtualDescendantId(accessibilityNodeId);
         args.argi3 = interactionId;
+        args.arg4 = interactiveRegion;
         message.obj = args;
 
         // If the interrogation is performed by the same thread as the main UI
@@ -287,6 +296,7 @@
         final int accessibilityViewId = args.argi1;
         final int virtualDescendantId = args.argi2;
         final int interactionId = args.argi3;
+        final Region interactiveRegion = (Region) args.arg4;
         args.recycle();
 
         List<AccessibilityNodeInfo> infos = null;
@@ -347,6 +357,7 @@
                 if (spec != null) {
                     spec.recycle();
                 }
+                adjustIsVisibleToUserIfNeeded(infos, interactiveRegion);
                 callback.setFindAccessibilityNodeInfosResult(infos, interactionId);
             } catch (RemoteException re) {
                 /* ignore - the other side will time out */
@@ -354,7 +365,8 @@
         }
     }
 
-    public void findFocusClientThread(long accessibilityNodeId, int focusType, int interactionId,
+    public void findFocusClientThread(long accessibilityNodeId, int focusType,
+            Region interactiveRegion, int interactionId,
             IAccessibilityInteractionConnectionCallback callback, int flags, int interogatingPid,
             long interrogatingTid, MagnificationSpec spec) {
         Message message = mHandler.obtainMessage();
@@ -368,6 +380,7 @@
         args.argi3 = AccessibilityNodeInfo.getVirtualDescendantId(accessibilityNodeId);
         args.arg1 = callback;
         args.arg2 = spec;
+        args.arg3 = interactiveRegion;
 
         message.obj = args;
 
@@ -394,6 +407,7 @@
         final IAccessibilityInteractionConnectionCallback callback =
             (IAccessibilityInteractionConnectionCallback) args.arg1;
         final MagnificationSpec spec = (MagnificationSpec) args.arg2;
+        final Region interactiveRegion = (Region) args.arg3;
         args.recycle();
 
         AccessibilityNodeInfo focused = null;
@@ -457,6 +471,7 @@
                 if (spec != null) {
                     spec.recycle();
                 }
+                adjustIsVisibleToUserIfNeeded(focused, interactiveRegion);
                 callback.setFindAccessibilityNodeInfoResult(focused, interactionId);
             } catch (RemoteException re) {
                 /* ignore - the other side will time out */
@@ -464,7 +479,8 @@
         }
     }
 
-    public void focusSearchClientThread(long accessibilityNodeId, int direction, int interactionId,
+    public void focusSearchClientThread(long accessibilityNodeId, int direction,
+            Region interactiveRegion, int interactionId,
             IAccessibilityInteractionConnectionCallback callback, int flags, int interogatingPid,
             long interrogatingTid, MagnificationSpec spec) {
         Message message = mHandler.obtainMessage();
@@ -477,6 +493,7 @@
         args.argi3 = interactionId;
         args.arg1 = callback;
         args.arg2 = spec;
+        args.arg3 = interactiveRegion;
 
         message.obj = args;
 
@@ -502,6 +519,7 @@
         final IAccessibilityInteractionConnectionCallback callback =
             (IAccessibilityInteractionConnectionCallback) args.arg1;
         final MagnificationSpec spec = (MagnificationSpec) args.arg2;
+        final Region interactiveRegion = (Region) args.arg3;
 
         args.recycle();
 
@@ -530,6 +548,7 @@
                 if (spec != null) {
                     spec.recycle();
                 }
+                adjustIsVisibleToUserIfNeeded(next, interactiveRegion);
                 callback.setFindAccessibilityNodeInfoResult(next, interactionId);
             } catch (RemoteException re) {
                 /* ignore - the other side will time out */
@@ -617,6 +636,95 @@
         }
     }
 
+    public void computeClickPointInScreenClientThread(long accessibilityNodeId,
+            Region interactiveRegion, int interactionId,
+            IAccessibilityInteractionConnectionCallback callback, int interrogatingPid,
+            long interrogatingTid, MagnificationSpec spec) {
+        Message message = mHandler.obtainMessage();
+        message.what = PrivateHandler.MSG_COMPUTE_CLICK_POINT_IN_SCREEN;
+
+        SomeArgs args = SomeArgs.obtain();
+        args.argi1 = AccessibilityNodeInfo.getAccessibilityViewId(accessibilityNodeId);
+        args.argi2 = AccessibilityNodeInfo.getVirtualDescendantId(accessibilityNodeId);
+        args.argi3 = interactionId;
+        args.arg1 = callback;
+        args.arg2 = spec;
+        args.arg3 = interactiveRegion;
+
+        message.obj = args;
+
+        // If the interrogation is performed by the same thread as the main UI
+        // thread in this process, set the message as a static reference so
+        // after this call completes the same thread but in the interrogating
+        // client can handle the message to generate the result.
+        if (interrogatingPid == mMyProcessId && interrogatingTid == mMyLooperThreadId) {
+            AccessibilityInteractionClient.getInstanceForThread(
+                    interrogatingTid).setSameThreadMessage(message);
+        } else {
+            mHandler.sendMessage(message);
+        }
+    }
+
+    private void computeClickPointInScreenUiThread(Message message) {
+        SomeArgs args = (SomeArgs) message.obj;
+        final int accessibilityViewId = args.argi1;
+        final int virtualDescendantId = args.argi2;
+        final int interactionId = args.argi3;
+        final IAccessibilityInteractionConnectionCallback callback =
+                (IAccessibilityInteractionConnectionCallback) args.arg1;
+        final MagnificationSpec spec = (MagnificationSpec) args.arg2;
+        final Region interactiveRegion = (Region) args.arg3;
+        args.recycle();
+
+        boolean succeeded = false;
+        Point point = mTempPoint;
+        try {
+            if (mViewRootImpl.mView == null || mViewRootImpl.mAttachInfo == null) {
+                return;
+            }
+            View target = null;
+            if (accessibilityViewId != AccessibilityNodeInfo.UNDEFINED_ITEM_ID) {
+                target = findViewByAccessibilityId(accessibilityViewId);
+            } else {
+                target = mViewRootImpl.mView;
+            }
+            if (target != null && isShown(target)) {
+                AccessibilityNodeProvider provider = target.getAccessibilityNodeProvider();
+                if (provider != null) {
+                    // For virtual views just use the center of the bounds in screen.
+                    AccessibilityNodeInfo node = null;
+                    if (virtualDescendantId != AccessibilityNodeInfo.UNDEFINED_ITEM_ID) {
+                        node = provider.createAccessibilityNodeInfo(virtualDescendantId);
+                    } else {
+                        node = provider.createAccessibilityNodeInfo(
+                                AccessibilityNodeProvider.HOST_VIEW_ID);
+                    }
+                    if (node != null) {
+                        succeeded = true;
+                        Rect boundsInScreen = mTempRect;
+                        node.getBoundsInScreen(boundsInScreen);
+                        point.set(boundsInScreen.centerX(), boundsInScreen.centerY());
+                    }
+                } else if (virtualDescendantId == AccessibilityNodeInfo.UNDEFINED_ITEM_ID) {
+                    // For a real view, ask the view to compute the click point.
+                    succeeded = target.computeClickPointInScreenForAccessibility(
+                            interactiveRegion, point);
+                }
+            }
+        } finally {
+            try {
+                Point result = null;
+                if (succeeded) {
+                    applyAppScaleAndMagnificationSpecIfNeeded(point, spec);
+                    result = point;
+                }
+                callback.setComputeClickPointInScreenActionResult(result, interactionId);
+            } catch (RemoteException re) {
+                /* ignore - the other side will time out */
+            }
+        }
+    }
+
     private View findViewByAccessibilityId(int accessibilityId) {
         View root = mViewRootImpl.mView;
         if (root == null) {
@@ -644,6 +752,50 @@
         }
     }
 
+    private void adjustIsVisibleToUserIfNeeded(List<AccessibilityNodeInfo> infos,
+            Region interactiveRegion) {
+        if (interactiveRegion == null || infos == null) {
+            return;
+        }
+        final int infoCount = infos.size();
+        for (int i = 0; i < infoCount; i++) {
+            AccessibilityNodeInfo info = infos.get(i);
+            adjustIsVisibleToUserIfNeeded(info, interactiveRegion);
+        }
+    }
+
+    private void adjustIsVisibleToUserIfNeeded(AccessibilityNodeInfo info,
+            Region interactiveRegion) {
+        if (interactiveRegion == null || info == null) {
+            return;
+        }
+        Rect boundsInScreen = mTempRect;
+        info.getBoundsInScreen(boundsInScreen);
+        if (interactiveRegion.quickReject(boundsInScreen)) {
+            info.setVisibleToUser(false);
+        }
+    }
+
+    private void applyAppScaleAndMagnificationSpecIfNeeded(Point point,
+            MagnificationSpec spec) {
+        final float applicationScale = mViewRootImpl.mAttachInfo.mApplicationScale;
+        if (!shouldApplyAppScaleAndMagnificationSpec(applicationScale, spec)) {
+            return;
+        }
+
+        if (applicationScale != 1.0f) {
+            point.x *= applicationScale;
+            point.y *= applicationScale;
+        }
+
+        if (spec != null) {
+            point.x *= spec.scale;
+            point.y *= spec.scale;
+            point.x += (int) spec.offsetX;
+            point.y += (int) spec.offsetY;
+        }
+    }
+
     private void applyAppScaleAndMagnificationSpecIfNeeded(AccessibilityNodeInfo info,
             MagnificationSpec spec) {
         if (info == null) {
@@ -1036,11 +1188,12 @@
 
     private class PrivateHandler extends Handler {
         private final static int MSG_PERFORM_ACCESSIBILITY_ACTION = 1;
-        private final static int MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_ACCESSIBILITY_ID = 2;
-        private final static int MSG_FIND_ACCESSIBLITY_NODE_INFOS_BY_VIEW_ID = 3;
-        private final static int MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_TEXT = 4;
+        private final static int MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_ACCESSIBILITY_ID = 2;
+        private final static int MSG_FIND_ACCESSIBILITY_NODE_INFOS_BY_VIEW_ID = 3;
+        private final static int MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_TEXT = 4;
         private final static int MSG_FIND_FOCUS = 5;
         private final static int MSG_FOCUS_SEARCH = 6;
+        private final static int MSG_COMPUTE_CLICK_POINT_IN_SCREEN = 7;
 
         public PrivateHandler(Looper looper) {
             super(looper);
@@ -1052,16 +1205,18 @@
             switch (type) {
                 case MSG_PERFORM_ACCESSIBILITY_ACTION:
                     return "MSG_PERFORM_ACCESSIBILITY_ACTION";
-                case MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_ACCESSIBILITY_ID:
-                    return "MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_ACCESSIBILITY_ID";
-                case MSG_FIND_ACCESSIBLITY_NODE_INFOS_BY_VIEW_ID:
-                    return "MSG_FIND_ACCESSIBLITY_NODE_INFOS_BY_VIEW_ID";
-                case MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_TEXT:
-                    return "MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_TEXT";
+                case MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_ACCESSIBILITY_ID:
+                    return "MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_ACCESSIBILITY_ID";
+                case MSG_FIND_ACCESSIBILITY_NODE_INFOS_BY_VIEW_ID:
+                    return "MSG_FIND_ACCESSIBILITY_NODE_INFOS_BY_VIEW_ID";
+                case MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_TEXT:
+                    return "MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_TEXT";
                 case MSG_FIND_FOCUS:
                     return "MSG_FIND_FOCUS";
                 case MSG_FOCUS_SEARCH:
                     return "MSG_FOCUS_SEARCH";
+                case MSG_COMPUTE_CLICK_POINT_IN_SCREEN:
+                    return "MSG_COMPUTE_CLICK_POINT_IN_SCREEN";
                 default:
                     throw new IllegalArgumentException("Unknown message type: " + type);
             }
@@ -1071,16 +1226,16 @@
         public void handleMessage(Message message) {
             final int type = message.what;
             switch (type) {
-                case MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_ACCESSIBILITY_ID: {
+                case MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_ACCESSIBILITY_ID: {
                     findAccessibilityNodeInfoByAccessibilityIdUiThread(message);
                 } break;
                 case MSG_PERFORM_ACCESSIBILITY_ACTION: {
                     perfromAccessibilityActionUiThread(message);
                 } break;
-                case MSG_FIND_ACCESSIBLITY_NODE_INFOS_BY_VIEW_ID: {
+                case MSG_FIND_ACCESSIBILITY_NODE_INFOS_BY_VIEW_ID: {
                     findAccessibilityNodeInfosByViewIdUiThread(message);
                 } break;
-                case MSG_FIND_ACCESSIBLITY_NODE_INFO_BY_TEXT: {
+                case MSG_FIND_ACCESSIBILITY_NODE_INFO_BY_TEXT: {
                     findAccessibilityNodeInfosByTextUiThread(message);
                 } break;
                 case MSG_FIND_FOCUS: {
@@ -1089,6 +1244,9 @@
                 case MSG_FOCUS_SEARCH: {
                     focusSearchUiThread(message);
                 } break;
+                case MSG_COMPUTE_CLICK_POINT_IN_SCREEN: {
+                    computeClickPointInScreenUiThread(message);
+                } break;
                 default:
                     throw new IllegalArgumentException("Unknown message type: " + type);
             }
diff --git a/core/java/android/view/FrameStats.java b/core/java/android/view/FrameStats.java
index 541b336..b3ac1db 100644
--- a/core/java/android/view/FrameStats.java
+++ b/core/java/android/view/FrameStats.java
@@ -28,7 +28,10 @@
      */
     public static final long UNDEFINED_TIME_NANO = -1;
 
+    /** @hide */
     protected long mRefreshPeriodNano;
+
+    /** @hide */
     protected long[] mFramesPresentedTimeNano;
 
     /**
diff --git a/core/java/android/view/GLES20Canvas.java b/core/java/android/view/GLES20Canvas.java
index a410aa9..1b57c24 100644
--- a/core/java/android/view/GLES20Canvas.java
+++ b/core/java/android/view/GLES20Canvas.java
@@ -179,6 +179,18 @@
     private static native void nSetHighContrastText(long renderer, boolean highContrastText);
 
     @Override
+    public void insertReorderBarrier() {
+        nInsertReorderBarrier(mRenderer, true);
+    }
+
+    @Override
+    public void insertInorderBarrier() {
+        nInsertReorderBarrier(mRenderer, false);
+    }
+
+    private static native void nInsertReorderBarrier(long renderer, boolean enableReorder);
+
+    @Override
     public int onPreDraw(Rect dirty) {
         if (dirty != null) {
             return nPrepareDirty(mRenderer, dirty.left, dirty.top, dirty.right, dirty.bottom,
@@ -713,6 +725,19 @@
             long propCy, long propRadius, long propPaint);
 
     @Override
+    public void drawRoundRect(CanvasProperty<Float> left, CanvasProperty<Float> top,
+            CanvasProperty<Float> right, CanvasProperty<Float> bottom, CanvasProperty<Float> rx,
+            CanvasProperty<Float> ry, CanvasProperty<Paint> paint) {
+        nDrawRoundRect(mRenderer, left.getNativeContainer(), top.getNativeContainer(),
+                right.getNativeContainer(), bottom.getNativeContainer(),
+                rx.getNativeContainer(), ry.getNativeContainer(),
+                paint.getNativeContainer());
+    }
+
+    private static native void nDrawRoundRect(long renderer, long propLeft, long propTop,
+            long propRight, long propBottom, long propRx, long propRy, long propPaint);
+
+    @Override
     public void drawColor(int color) {
         drawColor(color, PorterDuff.Mode.SRC_OVER);
     }
@@ -788,28 +813,6 @@
     }
 
     @Override
-    public void drawPicture(Picture picture, Rect dst) {
-        save();
-        translate(dst.left, dst.top);
-        if (picture.getWidth() > 0 && picture.getHeight() > 0) {
-            scale(dst.width() / picture.getWidth(), dst.height() / picture.getHeight());
-        }
-        drawPicture(picture);
-        restore();
-    }
-
-    @Override
-    public void drawPicture(Picture picture, RectF dst) {
-        save();
-        translate(dst.left, dst.top);
-        if (picture.getWidth() > 0 && picture.getHeight() > 0) {
-            scale(dst.width() / picture.getWidth(), dst.height() / picture.getHeight());
-        }
-        drawPicture(picture);
-        restore();
-    }
-
-    @Override
     public void drawPoint(float x, float y, Paint paint) {
         float[] point = getPointStorage();
         point[0] = x;
diff --git a/core/java/android/view/GhostView.java b/core/java/android/view/GhostView.java
index 3cbaf60..e4500eb 100644
--- a/core/java/android/view/GhostView.java
+++ b/core/java/android/view/GhostView.java
@@ -48,7 +48,9 @@
             mView.mRecreateDisplayList = true;
             RenderNode renderNode = mView.getDisplayList();
             if (renderNode.isValid()) {
+                hwCanvas.insertReorderBarrier(); // enable shadow for this rendernode
                 hwCanvas.drawRenderNode(renderNode);
+                hwCanvas.insertInorderBarrier(); // re-disable reordering/shadows
             }
         }
     }
diff --git a/core/java/android/view/HardwareCanvas.java b/core/java/android/view/HardwareCanvas.java
index c172969..e3eee71 100644
--- a/core/java/android/view/HardwareCanvas.java
+++ b/core/java/android/view/HardwareCanvas.java
@@ -113,6 +113,11 @@
     public abstract void drawCircle(CanvasProperty<Float> cx, CanvasProperty<Float> cy,
             CanvasProperty<Float> radius, CanvasProperty<Paint> paint);
 
+    public abstract void drawRoundRect(CanvasProperty<Float> left, CanvasProperty<Float> top,
+            CanvasProperty<Float> right, CanvasProperty<Float> bottom,
+            CanvasProperty<Float> rx, CanvasProperty<Float> ry,
+            CanvasProperty<Paint> paint);
+
     public static void setProperty(String name, String value) {
         GLES20Canvas.setProperty(name, value);
     }
diff --git a/core/java/android/view/HardwareRenderer.java b/core/java/android/view/HardwareRenderer.java
index 8c9b819..edb3798 100644
--- a/core/java/android/view/HardwareRenderer.java
+++ b/core/java/android/view/HardwareRenderer.java
@@ -349,6 +349,8 @@
      */
     abstract HardwareLayer createTextureLayer();
 
+    abstract void buildLayer(RenderNode node);
+
     abstract boolean copyLayerInto(HardwareLayer layer, Bitmap bitmap);
 
     /**
@@ -483,4 +485,6 @@
      * Called by {@link ViewRootImpl} when a new performTraverals is scheduled.
      */
     abstract void notifyFramePending();
+
+    abstract void registerAnimatingRenderNode(RenderNode animator);
 }
diff --git a/core/java/android/view/IWindowManager.aidl b/core/java/android/view/IWindowManager.aidl
index 7deb9c8..6aa86c7 100644
--- a/core/java/android/view/IWindowManager.aidl
+++ b/core/java/android/view/IWindowManager.aidl
@@ -93,6 +93,9 @@
             int startHeight);
     void overridePendingAppTransitionThumb(in Bitmap srcThumb, int startX, int startY,
             IRemoteCallback startedCallback, boolean scaleUp);
+    void overridePendingAppTransitionAspectScaledThumb(in Bitmap srcThumb, int startX,
+            int startY, int targetWidth, int targetHeight, IRemoteCallback startedCallback,
+            boolean scaleUp);
     void executeAppTransition();
     void setAppStartingWindow(IBinder token, String pkg, int theme,
             in CompatibilityInfo compatInfo, CharSequence nonLocalizedLabel, int labelRes,
diff --git a/core/java/android/view/IWindowSession.aidl b/core/java/android/view/IWindowSession.aidl
index 0f3f182..037ed28 100644
--- a/core/java/android/view/IWindowSession.aidl
+++ b/core/java/android/view/IWindowSession.aidl
@@ -177,6 +177,11 @@
 
     void wallpaperOffsetsComplete(IBinder window);
 
+    /**
+     * Apply a raw offset to the wallpaper service when shown behind this window.
+     */
+    void setWallpaperDisplayOffset(IBinder windowToken, int x, int y);
+
     Bundle sendWallpaperCommand(IBinder window, String action, int x, int y,
             int z, in Bundle extras, boolean sync);
 
diff --git a/core/java/android/view/KeyEvent.java b/core/java/android/view/KeyEvent.java
index 681717c..0701b53 100644
--- a/core/java/android/view/KeyEvent.java
+++ b/core/java/android/view/KeyEvent.java
@@ -657,11 +657,103 @@
     /** Key code constant: TV data service key.
      * Displays data services like weather, sports. */
     public static final int KEYCODE_TV_DATA_SERVICE = 230;
+    /** Key code constant: Voice Assist key.
+     * Launches the global voice assist activity. Not delivered to applications. */
+    public static final int KEYCODE_VOICE_ASSIST = 231;
+    /** Key code constant: Radio key.
+     * Toggles TV service / Radio service. */
+    public static final int KEYCODE_TV_RADIO_SERVICE = 232;
+    /** Key code constant: Teletext key.
+     * Displays Teletext service. */
+    public static final int KEYCODE_TV_TELETEXT = 233;
+    /** Key code constant: Number entry key.
+     * Initiates to enter multi-digit channel nubmber when each digit key is assigned
+     * for selecting separate channel. Corresponds to Number Entry Mode (0x1D) of CEC
+     * User Control Code. */
+    public static final int KEYCODE_TV_NUMBER_ENTRY = 234;
+    /** Key code constant: Analog Terrestrial key.
+     * Switches to analog terrestrial broadcast service. */
+    public static final int KEYCODE_TV_TERRESTRIAL_ANALOG = 235;
+    /** Key code constant: Digital Terrestrial key.
+     * Switches to digital terrestrial broadcast service. */
+    public static final int KEYCODE_TV_TERRESTRIAL_DIGITAL = 236;
+    /** Key code constant: Satellite key.
+     * Switches to digital satellite broadcast service. */
+    public static final int KEYCODE_TV_SATELLITE = 237;
+    /** Key code constant: BS key.
+     * Switches to BS digital satellite broadcasting service available in Japan. */
+    public static final int KEYCODE_TV_SATELLITE_BS = 238;
+    /** Key code constant: CS key.
+     * Switches to CS digital satellite broadcasting service available in Japan. */
+    public static final int KEYCODE_TV_SATELLITE_CS = 239;
+    /** Key code constant: BS/CS key.
+     * Toggles between BS and CS digital satellite services. */
+    public static final int KEYCODE_TV_SATELLITE_SERVICE = 240;
+    /** Key code constant: Toggle Network key.
+     * Toggles selecting broacast services. */
+    public static final int KEYCODE_TV_NETWORK = 241;
+    /** Key code constant: Antenna/Cable key.
+     * Toggles broadcast input source between antenna and cable. */
+    public static final int KEYCODE_TV_ANTENNA_CABLE = 242;
+    /** Key code constant: HDMI #1 key.
+     * Switches to HDMI input #1. */
+    public static final int KEYCODE_TV_INPUT_HDMI_1 = 243;
+    /** Key code constant: HDMI #2 key.
+     * Switches to HDMI input #2. */
+    public static final int KEYCODE_TV_INPUT_HDMI_2 = 244;
+    /** Key code constant: HDMI #3 key.
+     * Switches to HDMI input #3. */
+    public static final int KEYCODE_TV_INPUT_HDMI_3 = 245;
+    /** Key code constant: HDMI #4 key.
+     * Switches to HDMI input #4. */
+    public static final int KEYCODE_TV_INPUT_HDMI_4 = 246;
+    /** Key code constant: Composite #1 key.
+     * Switches to composite video input #1. */
+    public static final int KEYCODE_TV_INPUT_COMPOSITE_1 = 247;
+    /** Key code constant: Composite #2 key.
+     * Switches to composite video input #2. */
+    public static final int KEYCODE_TV_INPUT_COMPOSITE_2 = 248;
+    /** Key code constant: Component #1 key.
+     * Switches to component video input #1. */
+    public static final int KEYCODE_TV_INPUT_COMPONENT_1 = 249;
+    /** Key code constant: Component #2 key.
+     * Switches to component video input #2. */
+    public static final int KEYCODE_TV_INPUT_COMPONENT_2 = 250;
+    /** Key code constant: VGA #1 key.
+     * Switches to VGA (analog RGB) input #1. */
+    public static final int KEYCODE_TV_INPUT_VGA_1 = 251;
+    /** Key code constant: Audio description key.
+     * Toggles audio description off / on. */
+    public static final int KEYCODE_TV_AUDIO_DESCRIPTION = 252;
+    /** Key code constant: Audio description mixing volume up key.
+     * Louden audio description volume as compared with normal audio volume. */
+    public static final int KEYCODE_TV_AUDIO_DESCRIPTION_MIX_UP = 253;
+    /** Key code constant: Audio description mixing volume down key.
+     * Lessen audio description volume as compared with normal audio volume. */
+    public static final int KEYCODE_TV_AUDIO_DESCRIPTION_MIX_DOWN = 254;
+    /** Key code constant: Zoom mode key.
+     * Changes Zoom mode (Normal, Full, Zoom, Wide-zoom, etc.) */
+    public static final int KEYCODE_TV_ZOOM_MODE = 255;
+    /** Key code constant: Contents menu key.
+     * Goes to the title list. Corresponds to Contents Menu (0x0B) of CEC User Control
+     * Code */
+    public static final int KEYCODE_TV_CONTENTS_MENU = 256;
+    /** Key code constant: Media context menu key.
+     * Goes to the context menu of media contents. Corresponds to Media Context-sensitive
+     * Menu (0x11) of CEC User Control Code. */
+    public static final int KEYCODE_TV_MEDIA_CONTEXT_MENU = 257;
+    /** Key code constant: Timer programming key.
+     * Goes to the timer recording menu. Corresponds to Timer Programming (0x54) of
+     * CEC User Control Code. */
+    public static final int KEYCODE_TV_TIMER_PROGRAMMING = 258;
+    /** Key code constant: Help key. */
+    public static final int KEYCODE_HELP = 259;
 
-    private static final int LAST_KEYCODE = KEYCODE_TV_DATA_SERVICE;
+    private static final int LAST_KEYCODE = KEYCODE_HELP;
 
     // NOTE: If you add a new keycode here you must also add it to:
     //  isSystem()
+    //  isWakeKey()
     //  frameworks/native/include/android/keycodes.h
     //  frameworks/native/include/input/InputEventLabels.h
     //  frameworks/base/core/res/res/values/attrs.xml
diff --git a/core/java/android/view/MenuItem.java b/core/java/android/view/MenuItem.java
index 2dfbcb5..e706c9c 100644
--- a/core/java/android/view/MenuItem.java
+++ b/core/java/android/view/MenuItem.java
@@ -258,8 +258,8 @@
     /**
      * Change both the numeric and alphabetic shortcut associated with this
      * item. Note that the shortcut will be triggered when the key that
-     * generates the given character is pressed alone or along with with the alt
-     * key. Also note that case is not significant and that alphabetic shortcut
+     * generates the given character is pressed along with the ctrl key.
+     * Also note that case is not significant and that alphabetic shortcut
      * characters will be displayed in lower case.
      * <p>
      * See {@link Menu} for the menu types that support shortcuts.
@@ -293,9 +293,9 @@
     /**
      * Change the alphabetic shortcut associated with this item. The shortcut
      * will be triggered when the key that generates the given character is
-     * pressed alone or along with with the alt key. Case is not significant and
-     * shortcut characters will be displayed in lower case. Note that menu items
-     * with the characters '\b' or '\n' as shortcuts will get triggered by the
+     * pressed along with the ctrl key. Case is not significant and shortcut
+     * characters will be displayed in lower case. Note that menu items with
+     * the characters '\b' or '\n' as shortcuts will get triggered by the
      * Delete key or Carriage Return key, respectively.
      * <p>
      * See {@link Menu} for the menu types that support shortcuts.
@@ -596,4 +596,4 @@
      * @return This menu item instance for call chaining
      */
     public MenuItem setOnActionExpandListener(OnActionExpandListener listener);
-}
\ No newline at end of file
+}
diff --git a/core/java/android/view/PointerIcon.java b/core/java/android/view/PointerIcon.java
index 063a08d..7dcad68 100644
--- a/core/java/android/view/PointerIcon.java
+++ b/core/java/android/view/PointerIcon.java
@@ -149,9 +149,9 @@
      * Creates a custom pointer from the given bitmap and hotspot information.
      *
      * @param bitmap The bitmap for the icon.
-     * @param hotspotX The X offset of the pointer icon hotspot in the bitmap.
+     * @param hotSpotX The X offset of the pointer icon hotspot in the bitmap.
      *        Must be within the [0, bitmap.getWidth()) range.
-     * @param hotspotY The Y offset of the pointer icon hotspot in the bitmap.
+     * @param hotSpotY The Y offset of the pointer icon hotspot in the bitmap.
      *        Must be within the [0, bitmap.getHeight()) range.
      * @return A pointer icon for this bitmap.
      *
@@ -374,18 +374,18 @@
     }
 
     private void loadResource(Context context, Resources resources, int resourceId) {
-        XmlResourceParser parser = resources.getXml(resourceId);
+        final XmlResourceParser parser = resources.getXml(resourceId);
         final int bitmapRes;
         final float hotSpotX;
         final float hotSpotY;
         try {
             XmlUtils.beginDocument(parser, "pointer-icon");
 
-            TypedArray a = resources.obtainAttributes(
+            final TypedArray a = resources.obtainAttributes(
                     parser, com.android.internal.R.styleable.PointerIcon);
             bitmapRes = a.getResourceId(com.android.internal.R.styleable.PointerIcon_bitmap, 0);
-            hotSpotX = a.getFloat(com.android.internal.R.styleable.PointerIcon_hotSpotX, 0);
-            hotSpotY = a.getFloat(com.android.internal.R.styleable.PointerIcon_hotSpotY, 0);
+            hotSpotX = a.getDimension(com.android.internal.R.styleable.PointerIcon_hotSpotX, 0);
+            hotSpotY = a.getDimension(com.android.internal.R.styleable.PointerIcon_hotSpotY, 0);
             a.recycle();
         } catch (Exception ex) {
             throw new IllegalArgumentException("Exception parsing pointer icon resource.", ex);
diff --git a/core/java/android/view/RenderNode.java b/core/java/android/view/RenderNode.java
index 099f153..47f72a8 100644
--- a/core/java/android/view/RenderNode.java
+++ b/core/java/android/view/RenderNode.java
@@ -167,10 +167,13 @@
     public static final int STATUS_DREW = 0x4;
 
     private boolean mValid;
-    private final long mNativeRenderNode;
+    // Do not access directly unless you are ThreadedRenderer
+    final long mNativeRenderNode;
+    private final View mOwningView;
 
-    private RenderNode(String name) {
+    private RenderNode(String name, View owningView) {
         mNativeRenderNode = nCreate(name);
+        mOwningView = owningView;
     }
 
     /**
@@ -178,6 +181,7 @@
      */
     private RenderNode(long nativePtr) {
         mNativeRenderNode = nativePtr;
+        mOwningView = null;
     }
 
     /**
@@ -188,8 +192,8 @@
      *
      * @return A new RenderNode.
      */
-    public static RenderNode create(String name) {
-        return new RenderNode(name);
+    public static RenderNode create(String name, @Nullable View owningView) {
+        return new RenderNode(name, owningView);
     }
 
     /**
@@ -363,6 +367,10 @@
         throw new IllegalArgumentException("Unrecognized outline?");
     }
 
+    public boolean hasShadow() {
+        return nHasShadow(mNativeRenderNode);
+    }
+
     /**
      * Enables or disables clipping to the outline.
      *
@@ -805,7 +813,15 @@
     ///////////////////////////////////////////////////////////////////////////
 
     public void addAnimator(RenderNodeAnimator animator) {
+        if (mOwningView == null || mOwningView.mAttachInfo == null) {
+            throw new IllegalStateException("Cannot start this animator on a detached view!");
+        }
         nAddAnimator(mNativeRenderNode, animator.getNativeAnimator());
+        mOwningView.mAttachInfo.mViewRootImpl.registerAnimatingRenderNode(this);
+    }
+
+    public void endAllAnimators() {
+        nEndAllAnimators(mNativeRenderNode);
     }
 
     ///////////////////////////////////////////////////////////////////////////
@@ -849,6 +865,7 @@
             float alpha);
     private static native boolean nSetOutlineEmpty(long renderNode);
     private static native boolean nSetOutlineNone(long renderNode);
+    private static native boolean nHasShadow(long renderNode);
     private static native boolean nSetClipToOutline(long renderNode, boolean clipToOutline);
     private static native boolean nSetRevealClip(long renderNode,
             boolean shouldClip, float x, float y, float radius);
@@ -891,6 +908,7 @@
     ///////////////////////////////////////////////////////////////////////////
 
     private static native void nAddAnimator(long renderNode, long animatorPtr);
+    private static native void nEndAllAnimators(long renderNode);
 
     ///////////////////////////////////////////////////////////////////////////
     // Finalization
diff --git a/core/java/android/view/RenderNodeAnimator.java b/core/java/android/view/RenderNodeAnimator.java
index c7f16e0..debf45d 100644
--- a/core/java/android/view/RenderNodeAnimator.java
+++ b/core/java/android/view/RenderNodeAnimator.java
@@ -29,7 +29,6 @@
 import com.android.internal.view.animation.HasNativeInterpolator;
 import com.android.internal.view.animation.NativeInterpolatorFactory;
 
-import java.lang.ref.WeakReference;
 import java.util.ArrayList;
 
 /**
@@ -88,11 +87,22 @@
     private float mFinalValue;
     private TimeInterpolator mInterpolator;
 
-    private boolean mStarted = false;
-    private boolean mFinished = false;
+    private static final int STATE_PREPARE = 0;
+    private static final int STATE_DELAYED = 1;
+    private static final int STATE_RUNNING = 2;
+    private static final int STATE_FINISHED = 3;
+    private int mState = STATE_PREPARE;
 
     private long mUnscaledDuration = 300;
     private long mUnscaledStartDelay = 0;
+    // If this is true, we will run any start delays on the UI thread. This is
+    // the safe default, and is necessary to ensure start listeners fire at
+    // the correct time. Animators created by RippleDrawable (the
+    // CanvasProperty<> ones) do not have this expectation, and as such will
+    // set this to false so that the renderthread handles the startdelay instead
+    private final boolean mUiThreadHandlesDelay;
+    private long mStartDelay = 0;
+    private long mStartTime;
 
     public static int mapViewPropertyToRenderProperty(int viewProperty) {
         return sViewPropertyAnimatorMap.get(viewProperty);
@@ -101,14 +111,14 @@
     public RenderNodeAnimator(int property, float finalValue) {
         mRenderProperty = property;
         mFinalValue = finalValue;
-        init(nCreateAnimator(new WeakReference<RenderNodeAnimator>(this),
-                property, finalValue));
+        mUiThreadHandlesDelay = true;
+        init(nCreateAnimator(property, finalValue));
     }
 
     public RenderNodeAnimator(CanvasProperty<Float> property, float finalValue) {
         init(nCreateCanvasPropertyFloatAnimator(
-                new WeakReference<RenderNodeAnimator>(this),
                 property.getNativeContainer(), finalValue));
+        mUiThreadHandlesDelay = false;
     }
 
     /**
@@ -121,13 +131,13 @@
      */
     public RenderNodeAnimator(CanvasProperty<Paint> property, int paintField, float finalValue) {
         init(nCreateCanvasPropertyPaintAnimator(
-                new WeakReference<RenderNodeAnimator>(this),
                 property.getNativeContainer(), paintField, finalValue));
+        mUiThreadHandlesDelay = false;
     }
 
     public RenderNodeAnimator(int x, int y, float startRadius, float endRadius) {
-        init(nCreateRevealAnimator(new WeakReference<RenderNodeAnimator>(this),
-                x, y, startRadius, endRadius));
+        init(nCreateRevealAnimator(x, y, startRadius, endRadius));
+        mUiThreadHandlesDelay = true;
     }
 
     private void init(long ptr) {
@@ -135,7 +145,7 @@
     }
 
     private void checkMutable() {
-        if (mStarted) {
+        if (mState != STATE_PREPARE) {
             throw new IllegalStateException("Animator has already started, cannot change it now!");
         }
     }
@@ -163,13 +173,24 @@
             throw new IllegalStateException("Missing target!");
         }
 
-        if (mStarted) {
+        if (mState != STATE_PREPARE) {
             throw new IllegalStateException("Already started!");
         }
 
-        mStarted = true;
+        mState = STATE_DELAYED;
         applyInterpolator();
-        nStart(mNativePtr.get());
+
+        if (mStartDelay <= 0 || !mUiThreadHandlesDelay) {
+            nSetStartDelay(mNativePtr.get(), mStartDelay);
+            doStart();
+        } else {
+            getHelper().addDelayedAnimation(this);
+        }
+    }
+
+    private void doStart() {
+        mState = STATE_RUNNING;
+        nStart(mNativePtr.get(), this);
 
         // Alpha is a special snowflake that has the canonical value stored
         // in mTransformationInfo instead of in RenderNode, so we need to update
@@ -180,11 +201,7 @@
             mViewTarget.mTransformationInfo.mAlpha = mFinalValue;
         }
 
-        final ArrayList<AnimatorListener> listeners = getListeners();
-        final int numListeners = listeners == null ? 0 : listeners.size();
-        for (int i = 0; i < numListeners; i++) {
-            listeners.get(i).onAnimationStart(this);
-        }
+        notifyStartListeners();
 
         if (mViewTarget != null) {
             // Kick off a frame to start the process
@@ -192,22 +209,39 @@
         }
     }
 
+    private void notifyStartListeners() {
+        final ArrayList<AnimatorListener> listeners = cloneListeners();
+        final int numListeners = listeners == null ? 0 : listeners.size();
+        for (int i = 0; i < numListeners; i++) {
+            listeners.get(i).onAnimationStart(this);
+        }
+    }
+
     @Override
     public void cancel() {
-        if (!mFinished) {
+        if (mState != STATE_FINISHED) {
+            if (mState == STATE_DELAYED) {
+                getHelper().removeDelayedAnimation(this);
+                notifyStartListeners();
+            }
             nEnd(mNativePtr.get());
 
-            final ArrayList<AnimatorListener> listeners = getListeners();
+            final ArrayList<AnimatorListener> listeners = cloneListeners();
             final int numListeners = listeners == null ? 0 : listeners.size();
             for (int i = 0; i < numListeners; i++) {
                 listeners.get(i).onAnimationCancel(this);
             }
+
+            if (mViewTarget != null) {
+                // Kick off a frame to flush the state change
+                mViewTarget.invalidateViewProperty(true, false);
+            }
         }
     }
 
     @Override
     public void end() {
-        if (!mFinished) {
+        if (mState != STATE_FINISHED) {
             nEnd(mNativePtr.get());
         }
     }
@@ -224,24 +258,21 @@
 
     public void setTarget(View view) {
         mViewTarget = view;
-        mTarget = view.mRenderNode;
-        mTarget.addAnimator(this);
+        setTarget(mViewTarget.mRenderNode);
     }
 
     public void setTarget(Canvas canvas) {
         if (!(canvas instanceof GLES20RecordingCanvas)) {
             throw new IllegalArgumentException("Not a GLES20RecordingCanvas");
         }
-
         final GLES20RecordingCanvas recordingCanvas = (GLES20RecordingCanvas) canvas;
         setTarget(recordingCanvas.mNode);
     }
 
-    public void setTarget(RenderNode node) {
+    private void setTarget(RenderNode node) {
         if (mTarget != null) {
             throw new IllegalStateException("Target already set!");
         }
-        mViewTarget = null;
         mTarget = node;
         mTarget.addAnimator(this);
     }
@@ -258,7 +289,7 @@
             throw new IllegalArgumentException("startDelay must be positive; " + startDelay);
         }
         mUnscaledStartDelay = startDelay;
-        nSetStartDelay(mNativePtr.get(), (long) (startDelay * ValueAnimator.getDurationScale()));
+        mStartDelay = (long) (ValueAnimator.getDurationScale() * startDelay);
     }
 
     @Override
@@ -284,12 +315,12 @@
 
     @Override
     public boolean isRunning() {
-        return mStarted && !mFinished;
+        return mState == STATE_DELAYED || mState == STATE_RUNNING;
     }
 
     @Override
     public boolean isStarted() {
-        return mStarted;
+        return mState != STATE_PREPARE;
     }
 
     @Override
@@ -303,44 +334,146 @@
         return mInterpolator;
     }
 
-    private void onFinished() {
-        mFinished = true;
+    protected void onFinished() {
+        if (mState == STATE_DELAYED) {
+            getHelper().removeDelayedAnimation(this);
+            notifyStartListeners();
+        }
+        mState = STATE_FINISHED;
 
-        final ArrayList<AnimatorListener> listeners = getListeners();
+        final ArrayList<AnimatorListener> listeners = cloneListeners();
         final int numListeners = listeners == null ? 0 : listeners.size();
         for (int i = 0; i < numListeners; i++) {
             listeners.get(i).onAnimationEnd(this);
         }
+
+        // Release the native object, as it has a global reference to us. This
+        // breaks the cyclic reference chain, and allows this object to be
+        // GC'd
+        mNativePtr.release();
+        mNativePtr = null;
+    }
+
+    @SuppressWarnings("unchecked")
+    private ArrayList<AnimatorListener> cloneListeners() {
+        ArrayList<AnimatorListener> listeners = getListeners();
+        if (listeners != null) {
+            listeners = (ArrayList<AnimatorListener>) listeners.clone();
+        }
+        return listeners;
     }
 
     long getNativeAnimator() {
         return mNativePtr.get();
     }
 
-    // Called by native
-    private static void callOnFinished(WeakReference<RenderNodeAnimator> weakThis) {
-        RenderNodeAnimator animator = weakThis.get();
-        if (animator != null) {
-            animator.onFinished();
+    /**
+     * @return true if the animator was started, false if still delayed
+     */
+    private boolean processDelayed(long frameTimeMs) {
+        if (mStartTime == 0) {
+            mStartTime = frameTimeMs;
+        } else if ((frameTimeMs - mStartTime) >= mStartDelay) {
+            doStart();
+            return true;
+        }
+        return false;
+    }
+
+    private static DelayedAnimationHelper getHelper() {
+        DelayedAnimationHelper helper = sAnimationHelper.get();
+        if (helper == null) {
+            helper = new DelayedAnimationHelper();
+            sAnimationHelper.set(helper);
+        }
+        return helper;
+    }
+
+    private static ThreadLocal<DelayedAnimationHelper> sAnimationHelper =
+            new ThreadLocal<DelayedAnimationHelper>();
+
+    private static class DelayedAnimationHelper implements Runnable {
+
+        private ArrayList<RenderNodeAnimator> mDelayedAnims = new ArrayList<RenderNodeAnimator>();
+        private final Choreographer mChoreographer;
+        private boolean mCallbackScheduled;
+
+        public DelayedAnimationHelper() {
+            mChoreographer = Choreographer.getInstance();
+        }
+
+        public void addDelayedAnimation(RenderNodeAnimator animator) {
+            mDelayedAnims.add(animator);
+            scheduleCallback();
+        }
+
+        public void removeDelayedAnimation(RenderNodeAnimator animator) {
+            mDelayedAnims.remove(animator);
+        }
+
+        private void scheduleCallback() {
+            if (!mCallbackScheduled) {
+                mCallbackScheduled = true;
+                mChoreographer.postCallback(Choreographer.CALLBACK_ANIMATION, this, null);
+            }
+        }
+
+        @Override
+        public void run() {
+            long frameTimeMs = mChoreographer.getFrameTime();
+            mCallbackScheduled = false;
+
+            int end = 0;
+            for (int i = 0; i < mDelayedAnims.size(); i++) {
+                RenderNodeAnimator animator = mDelayedAnims.get(i);
+                if (!animator.processDelayed(frameTimeMs)) {
+                    if (end != i) {
+                        mDelayedAnims.set(end, animator);
+                    }
+                    end++;
+                }
+            }
+            while (mDelayedAnims.size() > end) {
+                mDelayedAnims.remove(mDelayedAnims.size() - 1);
+            }
+
+            if (mDelayedAnims.size() > 0) {
+                scheduleCallback();
+            }
         }
     }
 
-    private static native long nCreateAnimator(WeakReference<RenderNodeAnimator> weakThis,
-            int property, float finalValue);
-    private static native long nCreateCanvasPropertyFloatAnimator(WeakReference<RenderNodeAnimator> weakThis,
+    // Called by native
+    private static void callOnFinished(RenderNodeAnimator animator) {
+        animator.onFinished();
+    }
+
+    @Override
+    public Animator clone() {
+        throw new IllegalStateException("Cannot clone this animator");
+    }
+
+    @Override
+    public void setAllowRunningAsynchronously(boolean mayRunAsync) {
+        checkMutable();
+        nSetAllowRunningAsync(mNativePtr.get(), mayRunAsync);
+    }
+
+    private static native long nCreateAnimator(int property, float finalValue);
+    private static native long nCreateCanvasPropertyFloatAnimator(
             long canvasProperty, float finalValue);
-    private static native long nCreateCanvasPropertyPaintAnimator(WeakReference<RenderNodeAnimator> weakThis,
+    private static native long nCreateCanvasPropertyPaintAnimator(
             long canvasProperty, int paintField, float finalValue);
-    private static native long nCreateRevealAnimator(WeakReference<RenderNodeAnimator> weakThis,
+    private static native long nCreateRevealAnimator(
             int x, int y, float startRadius, float endRadius);
 
     private static native void nSetStartValue(long nativePtr, float startValue);
     private static native void nSetDuration(long nativePtr, long duration);
     private static native long nGetDuration(long nativePtr);
     private static native void nSetStartDelay(long nativePtr, long startDelay);
-    private static native long nGetStartDelay(long nativePtr);
     private static native void nSetInterpolator(long animPtr, long interpolatorPtr);
+    private static native void nSetAllowRunningAsync(long animPtr, boolean mayRunAsync);
 
-    private static native void nStart(long animPtr);
+    private static native void nStart(long animPtr, RenderNodeAnimator finishListener);
     private static native void nEnd(long animPtr);
 }
diff --git a/core/java/android/view/RenderNodeAnimatorCompat.java b/core/java/android/view/RenderNodeAnimatorCompat.java
deleted file mode 100644
index 8103f47..0000000
--- a/core/java/android/view/RenderNodeAnimatorCompat.java
+++ /dev/null
@@ -1,151 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.view;
-
-import android.animation.ValueAnimator;
-
-import java.util.ArrayList;
-
-/**
- * This class provides compatibility for things like start listeners &
- * start delays for use by ViewPropertyAnimator and ObjectAnimator
- * @hide
- */
-public class RenderNodeAnimatorCompat extends RenderNodeAnimator {
-
-    private long mUnscaledStartDelay = 0;
-    private long mStartDelay = 0;
-    private long mStartTime;
-    private boolean mCanceled;
-    private boolean mStarted;
-
-    public RenderNodeAnimatorCompat(int property, float finalValue) {
-        super(property, finalValue);
-    }
-
-    @Override
-    public void setStartDelay(long startDelay) {
-        mUnscaledStartDelay = startDelay;
-        mStartDelay = (long) (ValueAnimator.getDurationScale() * startDelay);
-    }
-
-    @Override
-    public long getStartDelay() {
-        return mUnscaledStartDelay;
-    }
-
-    @Override
-    public void start() {
-        mStarted = true;
-        if (mStartDelay <= 0) {
-            doStart();
-        } else {
-            getHelper().addDelayedAnimation(this);
-        }
-    }
-
-    @Override
-    public boolean isStarted() {
-        return mStarted;
-    }
-
-    private void doStart() {
-        if (!mCanceled) {
-            super.start();
-        }
-    }
-
-    @Override
-    public void cancel() {
-        mCanceled = true;
-        super.cancel();
-    }
-
-    /**
-     * @return true if the animator was started, false if still delayed
-     */
-    private boolean processDelayed(long frameTimeMs) {
-        if (mCanceled) return true;
-
-        if (mStartTime == 0) {
-            mStartTime = frameTimeMs;
-        } else if ((frameTimeMs - mStartTime) >= mStartDelay) {
-            doStart();
-            return true;
-        }
-        return false;
-    }
-
-    private static AnimationHelper getHelper() {
-        AnimationHelper helper = sAnimationHelper.get();
-        if (helper == null) {
-            helper = new AnimationHelper();
-            sAnimationHelper.set(helper);
-        }
-        return helper;
-    }
-
-    private static ThreadLocal<AnimationHelper> sAnimationHelper =
-            new ThreadLocal<AnimationHelper>();
-
-    private static class AnimationHelper implements Runnable {
-
-        private ArrayList<RenderNodeAnimatorCompat> mDelayedAnims = new ArrayList<RenderNodeAnimatorCompat>();
-        private final Choreographer mChoreographer;
-        private boolean mCallbackScheduled;
-
-        public AnimationHelper() {
-            mChoreographer = Choreographer.getInstance();
-        }
-
-        public void addDelayedAnimation(RenderNodeAnimatorCompat animator) {
-            mDelayedAnims.add(animator);
-            scheduleCallback();
-        }
-
-        private void scheduleCallback() {
-            if (!mCallbackScheduled) {
-                mCallbackScheduled = true;
-                mChoreographer.postCallback(Choreographer.CALLBACK_ANIMATION, this, null);
-            }
-        }
-
-        @Override
-        public void run() {
-            long frameTimeMs = mChoreographer.getFrameTime();
-            mCallbackScheduled = false;
-
-            int end = 0;
-            for (int i = 0; i < mDelayedAnims.size(); i++) {
-                RenderNodeAnimatorCompat animator = mDelayedAnims.get(i);
-                if (!animator.processDelayed(frameTimeMs)) {
-                    if (end != i) {
-                        mDelayedAnims.set(end, animator);
-                    }
-                    end++;
-                }
-            }
-            while (mDelayedAnims.size() > end) {
-                mDelayedAnims.remove(mDelayedAnims.size() - 1);
-            }
-
-            if (mDelayedAnims.size() > 0) {
-                scheduleCallback();
-            }
-        }
-    }
-}
diff --git a/core/java/android/view/SurfaceControl.java b/core/java/android/view/SurfaceControl.java
index 1e28e33..4074529 100644
--- a/core/java/android/view/SurfaceControl.java
+++ b/core/java/android/view/SurfaceControl.java
@@ -39,7 +39,7 @@
 
     private static native Bitmap nativeScreenshot(IBinder displayToken,
             Rect sourceCrop, int width, int height, int minLayer, int maxLayer,
-            boolean allLayers, boolean useIdentityTransform);
+            boolean allLayers, boolean useIdentityTransform, int rotation);
     private static native void nativeScreenshot(IBinder displayToken, Surface consumer,
             Rect sourceCrop, int width, int height, int minLayer, int maxLayer,
             boolean allLayers, boolean useIdentityTransform);
@@ -688,17 +688,23 @@
      * @param useIdentityTransform Replace whatever transformation (rotation,
      * scaling, translation) the surface layers are currently using with the
      * identity transformation while taking the screenshot.
+     * @param rotation Apply a custom clockwise rotation to the screenshot, i.e.
+     * Surface.ROTATION_0,90,180,270. Surfaceflinger will always take
+     * screenshots in its native portrait orientation by default, so this is
+     * useful for returning screenshots that are independent of device
+     * orientation.
      * @return Returns a Bitmap containing the screen contents, or null
      * if an error occurs. Make sure to call Bitmap.recycle() as soon as
      * possible, once its content is not needed anymore.
      */
     public static Bitmap screenshot(Rect sourceCrop, int width, int height,
-            int minLayer, int maxLayer, boolean useIdentityTransform) {
+            int minLayer, int maxLayer, boolean useIdentityTransform,
+            int rotation) {
         // TODO: should take the display as a parameter
         IBinder displayToken = SurfaceControl.getBuiltInDisplay(
                 SurfaceControl.BUILT_IN_DISPLAY_ID_MAIN);
         return nativeScreenshot(displayToken, sourceCrop, width, height,
-                minLayer, maxLayer, false, useIdentityTransform);
+                minLayer, maxLayer, false, useIdentityTransform, rotation);
     }
 
     /**
@@ -717,7 +723,8 @@
         // TODO: should take the display as a parameter
         IBinder displayToken = SurfaceControl.getBuiltInDisplay(
                 SurfaceControl.BUILT_IN_DISPLAY_ID_MAIN);
-        return nativeScreenshot(displayToken, new Rect(), width, height, 0, 0, true, false);
+        return nativeScreenshot(displayToken, new Rect(), width, height, 0, 0, true,
+                false, Surface.ROTATION_0);
     }
 
     private static void screenshot(IBinder display, Surface consumer, Rect sourceCrop,
diff --git a/core/java/android/view/ThreadedRenderer.java b/core/java/android/view/ThreadedRenderer.java
index f9333d5..5d2822d 100644
--- a/core/java/android/view/ThreadedRenderer.java
+++ b/core/java/android/view/ThreadedRenderer.java
@@ -99,15 +99,13 @@
     private boolean mRootNodeNeedsUpdate;
 
     ThreadedRenderer(Context context, boolean translucent) {
-        final TypedArray a = context.obtainStyledAttributes(
-                null, R.styleable.Lighting, R.attr.lightingStyle, 0);
+        final TypedArray a = context.obtainStyledAttributes(null, R.styleable.Lighting, 0, 0);
         mLightY = a.getDimension(R.styleable.Lighting_lightY, 0);
         mLightZ = a.getDimension(R.styleable.Lighting_lightZ, 0);
         mLightRadius = a.getDimension(R.styleable.Lighting_lightRadius, 0);
-        mAmbientShadowAlpha = Math.round(
-                255 * a.getFloat(R.styleable.Lighting_ambientShadowAlpha, 0));
-        mSpotShadowAlpha = Math.round(
-                255 * a.getFloat(R.styleable.Lighting_spotShadowAlpha, 0));
+        mAmbientShadowAlpha =
+                (int) (255 * a.getFloat(R.styleable.Lighting_ambientShadowAlpha, 0) + 0.5f);
+        mSpotShadowAlpha = (int) (255 * a.getFloat(R.styleable.Lighting_spotShadowAlpha, 0) + 0.5f);
         a.recycle();
 
         long rootNodePtr = nCreateRootRenderNode();
@@ -128,7 +126,7 @@
     void destroy() {
         mInitialized = false;
         updateEnabledState(null);
-        nDestroyCanvasAndSurface(mNativeProxy);
+        nDestroy(mNativeProxy);
     }
 
     private void updateEnabledState(Surface surface) {
@@ -279,7 +277,11 @@
                 final int saveCount = canvas.save();
                 canvas.translate(mInsetLeft, mInsetTop);
                 callbacks.onHardwarePreDraw(canvas);
+
+                canvas.insertReorderBarrier();
                 canvas.drawRenderNode(view.getDisplayList());
+                canvas.insertInorderBarrier();
+
                 callbacks.onHardwarePostDraw(canvas);
                 canvas.restoreToCount(saveCount);
                 mRootNodeNeedsUpdate = false;
@@ -314,6 +316,20 @@
 
         attachInfo.mIgnoreDirtyState = false;
 
+        // register animating rendernodes which started animating prior to renderer
+        // creation, which is typical for animators started prior to first draw
+        if (attachInfo.mPendingAnimatingRenderNodes != null) {
+            final int count = attachInfo.mPendingAnimatingRenderNodes.size();
+            for (int i = 0; i < count; i++) {
+                registerAnimatingRenderNode(
+                        attachInfo.mPendingAnimatingRenderNodes.get(i));
+            }
+            attachInfo.mPendingAnimatingRenderNodes.clear();
+            // We don't need this anymore as subsequent calls to
+            // ViewRootImpl#attachRenderNodeAnimator will go directly to us.
+            attachInfo.mPendingAnimatingRenderNodes = null;
+        }
+
         int syncResult = nSyncAndDrawFrame(mNativeProxy, frameTimeNanos,
                 recordDuration, view.getResources().getDisplayMetrics().density);
         if ((syncResult & SYNC_INVALIDATE_REQUIRED) != 0) {
@@ -332,6 +348,11 @@
     }
 
     @Override
+    void buildLayer(RenderNode node) {
+        nBuildLayer(mNativeProxy, node.getNativeDisplayList());
+    }
+
+    @Override
     boolean copyLayerInto(final HardwareLayer layer, final Bitmap bitmap) {
         return nCopyLayerInto(mNativeProxy,
                 layer.getDeferredLayerUpdater(), bitmap.mNativeBitmap);
@@ -367,6 +388,11 @@
     }
 
     @Override
+    void registerAnimatingRenderNode(RenderNode animator) {
+        nRegisterAnimatingRenderNode(mRootNode.mNativeRenderNode, animator.mNativeRenderNode);
+    }
+
+    @Override
     protected void finalize() throws Throwable {
         try {
             nDeleteProxy(mNativeProxy);
@@ -462,12 +488,14 @@
     private static native void nSetOpaque(long nativeProxy, boolean opaque);
     private static native int nSyncAndDrawFrame(long nativeProxy,
             long frameTimeNanos, long recordDuration, float density);
-    private static native void nDestroyCanvasAndSurface(long nativeProxy);
+    private static native void nDestroy(long nativeProxy);
+    private static native void nRegisterAnimatingRenderNode(long rootRenderNode, long animatingNode);
 
     private static native void nInvokeFunctor(long functor, boolean waitForCompletion);
 
     private static native long nCreateDisplayListLayer(long nativeProxy, int width, int height);
     private static native long nCreateTextureLayer(long nativeProxy);
+    private static native void nBuildLayer(long nativeProxy, long node);
     private static native boolean nCopyLayerInto(long nativeProxy, long layer, long bitmap);
     private static native void nPushLayerUpdate(long nativeProxy, long layer);
     private static native void nCancelLayerUpdate(long nativeProxy, long layer);
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index cec7e63..83dfe85 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -35,6 +35,8 @@
 import android.graphics.Matrix;
 import android.graphics.Outline;
 import android.graphics.Paint;
+import android.graphics.Path;
+import android.graphics.PathMeasure;
 import android.graphics.PixelFormat;
 import android.graphics.Point;
 import android.graphics.PorterDuff;
@@ -444,16 +446,19 @@
  * <a name="Drawing"></a>
  * <h3>Drawing</h3>
  * <p>
- * Drawing is handled by walking the tree and rendering each view that
- * intersects the invalid region. Because the tree is traversed in-order,
- * this means that parents will draw before (i.e., behind) their children, with
- * siblings drawn in the order they appear in the tree.
- * If you set a background drawable for a View, then the View will draw it for you
- * before calling back to its <code>onDraw()</code> method.
+ * Drawing is handled by walking the tree and recording the drawing commands of
+ * any View that needs to update. After this, the drawing commands of the
+ * entire tree are issued to screen, clipped to the newly damaged area.
  * </p>
  *
  * <p>
- * Note that the framework will not draw views that are not in the invalid region.
+ * The tree is largely recorded and drawn in order, with parents drawn before
+ * (i.e., behind) their children, with siblings drawn in the order they appear
+ * in the tree. If you set a background drawable for a View, then the View will
+ * draw it before calling back to its <code>onDraw()</code> method. The child
+ * drawing order can be overridden with
+ * {@link ViewGroup#setChildrenDrawingOrderEnabled(boolean) custom child drawing order}
+ * in a ViewGroup, and with {@link #setZ(float)} custom Z values} set on Views.
  * </p>
  *
  * <p>
@@ -2395,6 +2400,12 @@
      */
     static final int PFLAG3_NESTED_SCROLLING_ENABLED = 0x80;
 
+    /**
+     * Flag indicating that outline was invalidated and should be rebuilt the next time
+     * the DisplayList is updated.
+     */
+    static final int PFLAG3_OUTLINE_INVALID = 0x100;
+
     /* End of masks for mPrivateFlags3 */
 
     static final int DRAG_MASK = PFLAG2_DRAG_CAN_ACCEPT | PFLAG2_DRAG_HOVERED;
@@ -3182,9 +3193,7 @@
 
     @ViewDebug.ExportedProperty(deepExport = true, prefix = "bg_")
     private Drawable mBackground;
-    private ColorStateList mBackgroundTintList = null;
-    private PorterDuff.Mode mBackgroundTintMode = PorterDuff.Mode.SRC_ATOP;
-    private boolean mHasBackgroundTint = false;
+    private TintInfo mBackgroundTint;
 
     /**
      * RenderNode used for backgrounds.
@@ -3200,6 +3209,13 @@
 
     private String mTransitionName;
 
+    private static class TintInfo {
+        ColorStateList mTintList;
+        PorterDuff.Mode mTintMode;
+        boolean mHasTintMode;
+        boolean mHasTintList;
+    }
+
     static class ListenerInfo {
         /**
          * Listener used to dispatch focus change events.
@@ -3565,7 +3581,7 @@
         setOverScrollMode(OVER_SCROLL_IF_CONTENT_SCROLLS);
         mUserPaddingStart = UNDEFINED_PADDING;
         mUserPaddingEnd = UNDEFINED_PADDING;
-        mRenderNode = RenderNode.create(getClass().getName());
+        mRenderNode = RenderNode.create(getClass().getName(), this);
 
         if (!sCompatibilityDone && context != null) {
             final int targetSdkVersion = context.getApplicationInfo().targetSdkVersion;
@@ -4039,13 +4055,25 @@
                     break;
                 case R.styleable.View_backgroundTint:
                     // This will get applied later during setBackground().
-                    mBackgroundTintList = a.getColorStateList(R.styleable.View_backgroundTint);
-                    mHasBackgroundTint = true;
+                    if (mBackgroundTint == null) {
+                        mBackgroundTint = new TintInfo();
+                    }
+                    mBackgroundTint.mTintList = a.getColorStateList(
+                            R.styleable.View_backgroundTint);
+                    mBackgroundTint.mHasTintList = true;
                     break;
                 case R.styleable.View_backgroundTintMode:
                     // This will get applied later during setBackground().
-                    mBackgroundTintMode = Drawable.parseTintMode(a.getInt(
-                            R.styleable.View_backgroundTintMode, -1), mBackgroundTintMode);
+                    if (mBackgroundTint == null) {
+                        mBackgroundTint = new TintInfo();
+                    }
+                    mBackgroundTint.mTintMode = Drawable.parseTintMode(a.getInt(
+                            R.styleable.View_backgroundTintMode, -1), null);
+                    mBackgroundTint.mHasTintMode = true;
+                    break;
+                case R.styleable.View_outlineProvider:
+                    setOutlineProviderFromAttribute(a.getInt(R.styleable.View_outlineProvider,
+                            PROVIDER_BACKGROUND));
                     break;
             }
         }
@@ -4157,7 +4185,7 @@
      */
     View() {
         mResources = null;
-        mRenderNode = RenderNode.create(getClass().getName());
+        mRenderNode = RenderNode.create(getClass().getName(), this);
     }
 
     private static SparseArray<String> getAttributeMap() {
@@ -4290,6 +4318,8 @@
      * </p>
      *
      * @param a the styled attributes set to initialize the fading edges from
+     *
+     * @removed
      */
     protected void initializeFadingEdge(TypedArray a) {
         // This method probably shouldn't have been included in the SDK to begin with.
@@ -4430,6 +4460,8 @@
      * </p>
      *
      * @param a the styled attributes set to initialize the scrollbars from
+     *
+     * @removed
      */
     protected void initializeScrollbars(TypedArray a) {
         // It's not safe to use this method from apps. The parameter 'a' must have been obtained
@@ -4904,36 +4936,11 @@
             }
 
             onFocusChanged(true, direction, previouslyFocusedRect);
-            manageFocusHotspot(true, oldFocus);
             refreshDrawableState();
         }
     }
 
     /**
-     * Forwards focus information to the background drawable, if necessary. When
-     * the view is gaining focus, <code>v</code> is the previous focus holder.
-     * When the view is losing focus, <code>v</code> is the next focus holder.
-     *
-     * @param focused whether this view is focused
-     * @param v previous or the next focus holder, or null if none
-     */
-    private void manageFocusHotspot(boolean focused, View v) {
-        final Rect r = new Rect();
-        if (v != null && mAttachInfo != null) {
-            v.getHotspotBounds(r);
-            final int[] location = mAttachInfo.mTmpLocation;
-            getLocationOnScreen(location);
-            r.offset(-location[0], -location[1]);
-        } else {
-            r.set(0, 0, mRight - mLeft, mBottom - mTop);
-        }
-
-        final float x = r.exactCenterX();
-        final float y = r.exactCenterY();
-        drawableHotspotChanged(x, y);
-    }
-
-    /**
      * Populates <code>outRect</code> with the hotspot bounds. By default,
      * the hotspot bounds are identical to the screen bounds.
      *
@@ -5056,8 +5063,6 @@
             }
 
             onFocusChanged(false, 0, null);
-
-            manageFocusHotspot(false, focused);
             refreshDrawableState();
 
             if (propagate && (!refocus || !rootViewRequestFocus())) {
@@ -5751,6 +5756,136 @@
     }
 
     /**
+     * Computes a point on which a sequence of a down/up event can be sent to
+     * trigger clicking this view. This method is for the exclusive use by the
+     * accessibility layer to determine where to send a click event in explore
+     * by touch mode.
+     *
+     * @param interactiveRegion The interactive portion of this window.
+     * @param outPoint The point to populate.
+     * @return True of such a point exists.
+     */
+    boolean computeClickPointInScreenForAccessibility(Region interactiveRegion,
+            Point outPoint) {
+        // Since the interactive portion of the view is a region but as a view
+        // may have a transformation matrix which cannot be applied to a
+        // region we compute the view bounds rectangle and all interactive
+        // predecessor's and sibling's (siblings of predecessors included)
+        // rectangles that intersect the view bounds. At the
+        // end if the view was partially covered by another interactive
+        // view we compute the view's interactive region and pick a point
+        // on its boundary path as regions do not offer APIs to get inner
+        // points. Note that the the code is optimized to fail early and
+        // avoid unnecessary allocations plus computations.
+
+        // The current approach has edge cases that may produce false
+        // positives or false negatives. For example, a portion of the
+        // view may be covered by an interactive descendant of a
+        // predecessor, which we do not compute. Also a view may be handling
+        // raw touch events instead registering click listeners, which
+        // we cannot compute. Despite these limitations this approach will
+        // work most of the time and it is a huge improvement over just
+        // blindly sending the down and up events in the center of the
+        // view.
+
+        // Cannot click on an unattached view.
+        if (mAttachInfo == null) {
+            return false;
+        }
+
+        // Attached to an invisible window means this view is not visible.
+        if (mAttachInfo.mWindowVisibility != View.VISIBLE) {
+            return false;
+        }
+
+        RectF bounds = mAttachInfo.mTmpTransformRect;
+        bounds.set(0, 0, getWidth(), getHeight());
+        List<RectF> intersections = mAttachInfo.mTmpRectList;
+        intersections.clear();
+
+        if (mParent instanceof ViewGroup) {
+            ViewGroup parentGroup = (ViewGroup) mParent;
+            if (!parentGroup.translateBoundsAndIntersectionsInWindowCoordinates(
+                    this, bounds, intersections)) {
+                intersections.clear();
+                return false;
+            }
+        }
+
+        // Take into account the window location.
+        final int dx = mAttachInfo.mWindowLeft;
+        final int dy = mAttachInfo.mWindowTop;
+        bounds.offset(dx, dy);
+        offsetRects(intersections, dx, dy);
+
+        if (intersections.isEmpty() && interactiveRegion == null) {
+            outPoint.set((int) bounds.centerX(), (int) bounds.centerY());
+        } else {
+            // This view is partially covered by other views, then compute
+            // the not covered region and pick a point on its boundary.
+            Region region = new Region();
+            region.set((int) bounds.left, (int) bounds.top,
+                    (int) bounds.right, (int) bounds.bottom);
+
+            final int intersectionCount = intersections.size();
+            for (int i = intersectionCount - 1; i >= 0; i--) {
+                RectF intersection = intersections.remove(i);
+                region.op((int) intersection.left, (int) intersection.top,
+                        (int) intersection.right, (int) intersection.bottom,
+                        Region.Op.DIFFERENCE);
+            }
+
+            // If the view is completely covered, done.
+            if (region.isEmpty()) {
+                return false;
+            }
+
+            // Take into account the interactive portion of the window
+            // as the rest is covered by other windows. If no such a region
+            // then the whole window is interactive.
+            if (interactiveRegion != null) {
+                region.op(interactiveRegion, Region.Op.INTERSECT);
+            }
+
+            // If the view is completely covered, done.
+            if (region.isEmpty()) {
+                return false;
+            }
+
+            // Try a shortcut here.
+            if (region.isRect()) {
+                Rect regionBounds = mAttachInfo.mTmpInvalRect;
+                region.getBounds(regionBounds);
+                outPoint.set(regionBounds.centerX(), regionBounds.centerY());
+                return true;
+            }
+
+            // Get the a point on the region boundary path.
+            Path path = region.getBoundaryPath();
+            PathMeasure pathMeasure = new PathMeasure(path, false);
+            final float[] coordinates = mAttachInfo.mTmpTransformLocation;
+
+            // Without loss of generality pick a point.
+            final float point = pathMeasure.getLength() * 0.01f;
+            if (!pathMeasure.getPosTan(point, coordinates, null)) {
+                return false;
+            }
+
+            outPoint.set(Math.round(coordinates[0]), Math.round(coordinates[1]));
+        }
+
+        return true;
+    }
+
+    static void offsetRects(List<RectF> rects, float offsetX, float offsetY) {
+        final int rectCount = rects.size();
+        for (int i = 0; i < rectCount; i++) {
+            RectF intersection = rects.get(i);
+            intersection.offset(offsetX, offsetY);
+        }
+    }
+
+    /**
      * Returns the delegate for implementing accessibility support via
      * composition. For more details see {@link AccessibilityDelegate}.
      *
@@ -6409,6 +6544,28 @@
     }
 
     /**
+     * Compute insets that should be consumed by this view and the ones that should propagate
+     * to those under it.
+     *
+     * @param in Insets currently being processed by this View, likely received as a parameter
+     *           to {@link #onApplyWindowInsets(WindowInsets)}.
+     * @param outLocalInsets A Rect that will receive the insets that should be consumed
+     *                       by this view
+     * @return Insets that should be passed along to views under this one
+     */
+    public WindowInsets computeSystemWindowInsets(WindowInsets in, Rect outLocalInsets) {
+        if ((mViewFlags & OPTIONAL_FITS_SYSTEM_WINDOWS) == 0
+                || mAttachInfo == null
+                || (mAttachInfo.mSystemUiVisibility & SYSTEM_UI_LAYOUT_FLAGS) == 0) {
+            outLocalInsets.set(in.getSystemWindowInsets());
+            return in.consumeSystemWindowInsets();
+        } else {
+            outLocalInsets.set(0, 0, 0, 0);
+            return in;
+        }
+    }
+
+    /**
      * Sets whether or not this view should account for system screen decorations
      * such as the status bar and inset its content; that is, controlling whether
      * the default implementation of {@link #fitSystemWindows(Rect)} will be
@@ -10244,6 +10401,7 @@
      *
      * @return true if the content in this view might overlap, false otherwise.
      */
+    @ViewDebug.ExportedProperty(category = "drawing")
     public boolean hasOverlappingRendering() {
         return true;
     }
@@ -10789,6 +10947,15 @@
         }
     }
 
+    /** @hide */
+    public void setAnimationMatrix(Matrix matrix) {
+        invalidateViewProperty(true, false);
+        mRenderNode.setAnimationMatrix(matrix);
+        invalidateViewProperty(false, true);
+
+        invalidateParentIfNeededAndWasQuickRejected();
+    }
+
     /**
      * Returns the current StateListAnimator if exists.
      *
@@ -10824,14 +10991,6 @@
     }
 
     /**
-     * Deprecated, pending removal
-     *
-     * @hide
-     */
-    @Deprecated
-    public void setOutline(@Nullable Outline outline) {}
-
-    /**
      * Returns whether the Outline should be used to clip the contents of the View.
      * <p>
      * Note that this flag will only be respected if the View's Outline returns true from
@@ -10847,6 +11006,12 @@
     /**
      * Sets whether the View's Outline should be used to clip the contents of the View.
      * <p>
+     * Only a single non-rectangular clip can be applied on a View at any time.
+     * Circular clips from a {@link ViewAnimationUtils#createCircularReveal(View, int, int, float, float)
+     * circular reveal} animation take priority over Outline clipping, and
+     * child Outline clipping takes priority over Outline clipping done by a
+     * parent.
+     * <p>
      * Note that this flag will only be respected if the View's Outline returns true from
      * {@link Outline#canClip()}.
      *
@@ -10860,6 +11025,28 @@
         }
     }
 
+    // correspond to the enum values of View_outlineProvider
+    private static final int PROVIDER_BACKGROUND = 0;
+    private static final int PROVIDER_NONE = 1;
+    private static final int PROVIDER_BOUNDS = 2;
+    private static final int PROVIDER_PADDED_BOUNDS = 3;
+    private void setOutlineProviderFromAttribute(int providerInt) {
+        switch (providerInt) {
+            case PROVIDER_BACKGROUND:
+                setOutlineProvider(ViewOutlineProvider.BACKGROUND);
+                break;
+            case PROVIDER_NONE:
+                setOutlineProvider(null);
+                break;
+            case PROVIDER_BOUNDS:
+                setOutlineProvider(ViewOutlineProvider.BOUNDS);
+                break;
+            case PROVIDER_PADDED_BOUNDS:
+                setOutlineProvider(ViewOutlineProvider.PADDED_BOUNDS);
+                break;
+        }
+    }
+
     /**
      * Sets the {@link ViewOutlineProvider} of the view, which generates the Outline that defines
      * the shape of the shadow it casts, and enables outline clipping.
@@ -10898,6 +11085,22 @@
      * @see #setOutlineProvider(ViewOutlineProvider)
      */
     public void invalidateOutline() {
+        mPrivateFlags3 |= PFLAG3_OUTLINE_INVALID;
+
+        notifySubtreeAccessibilityStateChangedIfNeeded();
+        invalidateViewProperty(false, false);
+    }
+
+    /**
+     * Internal version of {@link #invalidateOutline()} which invalidates the
+     * outline without invalidating the view itself. This is intended to be called from
+     * within methods in the View class itself which are the result of the view being
+     * invalidated already. For example, when we are drawing the background of a View,
+     * we invalidate the outline in case it changed in the meantime, but we do not
+     * need to invalidate the view because we're already drawing the background as part
+     * of drawing the view in response to an earlier invalidation of the view.
+     */
+    private void rebuildOutline() {
         // Unattached views ignore this signal, and outline is recomputed in onAttachedToWindow()
         if (mAttachInfo == null) return;
 
@@ -10912,11 +11115,19 @@
             mOutlineProvider.getOutline(this, outline);
             mRenderNode.setOutline(outline);
         }
-
-        notifySubtreeAccessibilityStateChangedIfNeeded();
-        invalidateViewProperty(false, false);
     }
 
+    /**
+     * HierarchyViewer only
+     *
+     * @hide
+     */
+    @ViewDebug.ExportedProperty(category = "drawing")
+    public boolean hasShadow() {
+        return mRenderNode.hasShadow();
+    }
+
+
     /** @hide */
     public void setRevealClip(boolean shouldClip, float x, float y, float radius) {
         mRenderNode.setRevealClip(shouldClip, x, y, radius);
@@ -12744,7 +12955,8 @@
 
         resetSubtreeAccessibilityStateChanged();
 
-        invalidateOutline();
+        // rebuild, since Outline not maintained while View is detached
+        rebuildOutline();
 
         if (isFocused()) {
             InputMethodManager imm = InputMethodManager.peekInstance();
@@ -13072,6 +13284,10 @@
         removeSendViewScrolledAccessibilityEventCallback();
         stopNestedScroll();
 
+        // Anything that started animating right before detach should already
+        // be in its final state when re-attached.
+        jumpDrawablesToCurrentState();
+
         destroyDrawingCache();
 
         cleanupDraw();
@@ -13640,11 +13856,10 @@
 
         switch (mLayerType) {
             case LAYER_TYPE_HARDWARE:
-                // The only part of a hardware layer we can build in response to
-                // this call is to ensure the display list is up to date.
-                // The actual rendering of the display list into the layer must
-                // be done at playback time
                 updateDisplayListIfDirty();
+                if (attachInfo.mHardwareRenderer != null && mRenderNode.isValid()) {
+                    attachInfo.mHardwareRenderer.buildLayer(mRenderNode);
+                }
                 break;
             case LAYER_TYPE_SOFTWARE:
                 buildDrawingCache(true);
@@ -13831,6 +14046,7 @@
                     } else {
                         draw(canvas);
                     }
+                    drawAccessibilityFocus(canvas);
                 }
             } finally {
                 renderNode.end(canvas);
@@ -14125,6 +14341,7 @@
             } else {
                 draw(canvas);
             }
+            drawAccessibilityFocus(canvas);
 
             canvas.restoreToCount(restoreCount);
             canvas.setBitmap(null);
@@ -14199,6 +14416,7 @@
         } else {
             draw(canvas);
         }
+        drawAccessibilityFocus(canvas);
 
         mPrivateFlags = flags;
 
@@ -14458,6 +14676,10 @@
      */
     void setDisplayListProperties(RenderNode renderNode) {
         if (renderNode != null) {
+            if ((mPrivateFlags3 & PFLAG3_OUTLINE_INVALID) != 0) {
+                rebuildOutline();
+                mPrivateFlags3 &= ~PFLAG3_OUTLINE_INVALID;
+            }
             renderNode.setHasOverlappingRendering(hasOverlappingRendering());
             if (mParent instanceof ViewGroup) {
                 renderNode.setClipToBounds(
@@ -14792,9 +15014,13 @@
                     if ((mPrivateFlags & PFLAG_SKIP_DRAW) == PFLAG_SKIP_DRAW) {
                         mPrivateFlags &= ~PFLAG_DIRTY_MASK;
                         dispatchDraw(canvas);
+                        if (mOverlay != null && !mOverlay.isEmpty()) {
+                            mOverlay.getOverlayView().draw(canvas);
+                        }
                     } else {
                         draw(canvas);
                     }
+                    drawAccessibilityFocus(canvas);
                 } else {
                     mPrivateFlags &= ~PFLAG_DIRTY_MASK;
                     ((HardwareCanvas) canvas).drawRenderNode(renderNode, null, flags);
@@ -15046,6 +15272,50 @@
     }
 
     /**
+     * Draws the accessibility focus rect onto the specified canvas.
+     *
+     * @param canvas Canvas on which to draw the focus rect
+     */
+    private void drawAccessibilityFocus(Canvas canvas) {
+        if (mAttachInfo == null) {
+            return;
+        }
+
+        final Rect bounds = mAttachInfo.mTmpInvalRect;
+        final ViewRootImpl viewRoot = getViewRootImpl();
+        if (viewRoot == null || viewRoot.getAccessibilityFocusedHost() != this) {
+            return;
+        }
+
+        final AccessibilityManager manager = AccessibilityManager.getInstance(mContext);
+        if (!manager.isEnabled() || !manager.isTouchExplorationEnabled()) {
+            return;
+        }
+
+        final Drawable drawable = viewRoot.getAccessibilityFocusedDrawable();
+        if (drawable == null) {
+            return;
+        }
+
+        final AccessibilityNodeInfo virtualView = viewRoot.getAccessibilityFocusedVirtualView();
+        if (virtualView != null) {
+            virtualView.getBoundsInScreen(bounds);
+            final int[] offset = mAttachInfo.mTmpLocation;
+            getLocationOnScreen(offset);
+            bounds.offset(-offset[0], -offset[1]);
+        } else {
+            bounds.set(0, 0, mRight - mLeft, mBottom - mTop);
+        }
+
+        canvas.save();
+        canvas.translate(mScrollX, mScrollY);
+        canvas.clipRect(bounds, Region.Op.REPLACE);
+        drawable.setBounds(bounds);
+        drawable.draw(canvas);
+        canvas.restore();
+    }
+
+    /**
      * Draws the background onto the specified canvas.
      *
      * @param canvas Canvas on which to draw the background
@@ -15059,7 +15329,7 @@
         if (mBackgroundSizeChanged) {
             background.setBounds(0, 0,  mRight - mLeft, mBottom - mTop);
             mBackgroundSizeChanged = false;
-            invalidateOutline();
+            mPrivateFlags3 |= PFLAG3_OUTLINE_INVALID;
         }
 
         // Attempt to use a display list if requested.
@@ -15104,9 +15374,9 @@
      * @param renderNode Existing RenderNode, or {@code null}
      * @return A valid display list for the specified drawable
      */
-    private static RenderNode getDrawableRenderNode(Drawable drawable, RenderNode renderNode) {
+    private RenderNode getDrawableRenderNode(Drawable drawable, RenderNode renderNode) {
         if (renderNode == null) {
-            renderNode = RenderNode.create(drawable.getClass().getName());
+            renderNode = RenderNode.create(drawable.getClass().getName(), this);
         }
 
         final Rect bounds = drawable.getBounds();
@@ -15434,7 +15704,7 @@
             mOverlay.getOverlayView().setRight(newWidth);
             mOverlay.getOverlayView().setBottom(newHeight);
         }
-        invalidateOutline();
+        mPrivateFlags3 |= PFLAG3_OUTLINE_INVALID;
     }
 
     /**
@@ -15471,7 +15741,7 @@
             invalidate(dirty.left + scrollX, dirty.top + scrollY,
                     dirty.right + scrollX, dirty.bottom + scrollY);
 
-            invalidateOutline();
+            mPrivateFlags3 |= PFLAG3_OUTLINE_INVALID;
         }
     }
 
@@ -15977,7 +16247,7 @@
 
     /**
      * Applies a tint to the background drawable. Does not modify the current tint
-     * mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setBackground(Drawable)} will automatically
      * mutate the drawable and apply the specified tint and tint mode using
@@ -15990,26 +16260,31 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setBackgroundTintList(@Nullable ColorStateList tint) {
-        mBackgroundTintList = tint;
-        mHasBackgroundTint = true;
+        if (mBackgroundTint == null) {
+            mBackgroundTint = new TintInfo();
+        }
+        mBackgroundTint.mTintList = tint;
+        mBackgroundTint.mHasTintList = true;
 
         applyBackgroundTint();
     }
 
     /**
+     * Return the tint applied to the background drawable, if specified.
+     *
      * @return the tint applied to the background drawable
      * @attr ref android.R.styleable#View_backgroundTint
      * @see #setBackgroundTintList(ColorStateList)
      */
     @Nullable
     public ColorStateList getBackgroundTintList() {
-        return mBackgroundTintList;
+        return mBackgroundTint != null ? mBackgroundTint.mTintList : null;
     }
 
     /**
      * Specifies the blending mode used to apply the tint specified by
-     * {@link #setBackgroundTintList(ColorStateList)}} to the background drawable.
-     * The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * {@link #setBackgroundTintList(ColorStateList)}} to the background
+     * drawable. The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -16018,26 +16293,43 @@
      * @see Drawable#setTintMode(PorterDuff.Mode)
      */
     public void setBackgroundTintMode(@Nullable PorterDuff.Mode tintMode) {
-        mBackgroundTintMode = tintMode;
+        if (mBackgroundTint == null) {
+            mBackgroundTint = new TintInfo();
+        }
+        mBackgroundTint.mTintMode = tintMode;
+        mBackgroundTint.mHasTintMode = true;
 
         applyBackgroundTint();
     }
 
     /**
-     * @return the blending mode used to apply the tint to the background drawable
+     * Return the blending mode used to apply the tint to the background
+     * drawable, if specified.
+     *
+     * @return the blending mode used to apply the tint to the background
+     *         drawable
      * @attr ref android.R.styleable#View_backgroundTintMode
      * @see #setBackgroundTintMode(PorterDuff.Mode)
      */
     @Nullable
     public PorterDuff.Mode getBackgroundTintMode() {
-        return mBackgroundTintMode;
+        return mBackgroundTint != null ? mBackgroundTint.mTintMode : null;
     }
 
     private void applyBackgroundTint() {
-        if (mBackground != null && mHasBackgroundTint) {
-            mBackground = mBackground.mutate();
-            mBackground.setTintList(mBackgroundTintList);
-            mBackground.setTintMode(mBackgroundTintMode);
+        if (mBackground != null && mBackgroundTint != null) {
+            final TintInfo tintInfo = mBackgroundTint;
+            if (tintInfo.mHasTintList || tintInfo.mHasTintMode) {
+                mBackground = mBackground.mutate();
+
+                if (tintInfo.mHasTintList) {
+                    mBackground.setTintList(tintInfo.mTintList);
+                }
+
+                if (tintInfo.mHasTintMode) {
+                    mBackground.setTintMode(tintInfo.mTintMode);
+                }
+            }
         }
     }
 
@@ -19832,6 +20124,7 @@
         boolean mHardwareAccelerated;
         boolean mHardwareAccelerationRequested;
         HardwareRenderer mHardwareRenderer;
+        List<RenderNode> mPendingAnimatingRenderNodes;
 
         /**
          * The state of the display to which the window is attached, as reported
@@ -20078,6 +20371,16 @@
         final RectF mTmpTransformRect = new RectF();
 
         /**
+         * Temporary for use in computing hit areas with transformed views
+         */
+        final RectF mTmpTransformRect1 = new RectF();
+
+        /**
+         * Temporary list of rectanges.
+         */
+        final List<RectF> mTmpRectList = new ArrayList<>();
+
+        /**
          * Temporary for use in transforming invalidation rect
          */
         final Matrix mTmpMatrix = new Matrix();
@@ -20612,6 +20915,7 @@
             if (mPosted) {
                 return;
             }
+
             final long timeSinceLastMillis = SystemClock.uptimeMillis() - mLastEventTimeMillis;
             final long minEventIntevalMillis =
                     ViewConfiguration.getSendRecurringAccessibilityEventsInterval();
@@ -20620,7 +20924,6 @@
                 run();
             } else {
                 postDelayed(this, minEventIntevalMillis - timeSinceLastMillis);
-                mPosted = true;
                 mPostedWithDelay = true;
             }
         }
diff --git a/core/java/android/view/ViewAnimationUtils.java b/core/java/android/view/ViewAnimationUtils.java
index ea3efb1..001cd01 100644
--- a/core/java/android/view/ViewAnimationUtils.java
+++ b/core/java/android/view/ViewAnimationUtils.java
@@ -26,9 +26,16 @@
 public final class ViewAnimationUtils {
     private ViewAnimationUtils() {}
     /**
-     * Returns a ValueAnimator which can animate a clipping circle.
-     *
+     * Returns an Animator which can animate a clipping circle.
+     * <p>
      * Any shadow cast by the View will respect the circular clip from this animator.
+     * <p>
+     * Only a single non-rectangular clip can be applied on a View at any time.
+     * Views clipped by a circular reveal animation take priority over
+     * {@link View#setClipToOutline(boolean) View Outline clipping}.
+     * <p>
+     * Note that the animation returned here is a one-shot animation. It cannot
+     * be re-used, and once started it cannot be paused or resumed.
      *
      * @param view The View will be clipped to the animating circle.
      * @param centerX The x coordinate of the center of the animating circle.
@@ -36,7 +43,7 @@
      * @param startRadius The starting radius of the animating circle.
      * @param endRadius The ending radius of the animating circle.
      */
-    public static final Animator createCircularReveal(View view,
+    public static Animator createCircularReveal(View view,
             int centerX,  int centerY, float startRadius, float endRadius) {
         return new RevealAnimator(view, centerX, centerY, startRadius, endRadius);
     }
diff --git a/core/java/android/view/ViewGroup.java b/core/java/android/view/ViewGroup.java
index 19dd583..4e1db90 100644
--- a/core/java/android/view/ViewGroup.java
+++ b/core/java/android/view/ViewGroup.java
@@ -771,6 +771,112 @@
     }
 
     /**
+     * Translates the given bounds and intersections from child coordinates to
+     * local coordinates. In case any interactive sibling of the calling child
+     * covers the latter, a new intersections is added to the intersection list.
+     * This method is for the exclusive use by the accessibility layer to compute
+     * a point where a sequence of down and up events would click on a view.
+     *
+     * @param child The child making the call.
+     * @param bounds The bounds to translate in child coordinates.
+     * @param intersections The intersections of interactive views covering the child.
+     * @return True if the bounds and intersections were computed, false otherwise.
+     */
+    boolean translateBoundsAndIntersectionsInWindowCoordinates(View child,
+            RectF bounds, List<RectF> intersections) {
+        // Not attached, done.
+        if (mAttachInfo == null) {
+            return false;
+        }
+
+        if (getAlpha() <= 0 || getTransitionAlpha() <= 0 ||
+                getVisibility() != VISIBLE) {
+            // Cannot click on a view with an invisible predecessor.
+            return false;
+        }
+
+        // Compensate for the child transformation.
+        if (!child.hasIdentityMatrix()) {
+            Matrix matrix = child.getMatrix();
+            matrix.mapRect(bounds);
+            final int intersectionCount = intersections.size();
+            for (int i = 0; i < intersectionCount; i++) {
+                RectF intersection = intersections.get(i);
+                matrix.mapRect(intersection);
+            }
+        }
+
+        // Translate the bounds from child to parent coordinates.
+        final int dx = child.mLeft - mScrollX;
+        final int dy = child.mTop - mScrollY;
+        bounds.offset(dx, dy);
+        offsetRects(intersections, dx, dy);
+
+        // If the bounds do not intersect our bounds, done.
+        if (!bounds.intersects(0, 0, getWidth(), getHeight())) {
+            return false;
+        }
+
+        // Check whether any clickable siblings cover the child
+        // view and if so keep track of the intersections. Also
+        // respect Z ordering when iterating over children.
+        ArrayList<View> orderedList = buildOrderedChildList();
+        final boolean useCustomOrder = orderedList == null
+                && isChildrenDrawingOrderEnabled();
+
+        final int childCount = mChildrenCount;
+        for (int i = childCount - 1; i >= 0; i--) {
+            final int childIndex = useCustomOrder
+                    ? getChildDrawingOrder(childCount, i) : i;
+            final View sibling = (orderedList == null)
+                    ? mChildren[childIndex] : orderedList.get(childIndex);
+
+            // We care only about siblings over the child.
+            if (sibling == child) {
+                break;
+            }
+
+            // If sibling is not interactive we do not care.
+            if (!sibling.isClickable() && !sibling.isLongClickable()) {
+                continue;
+            }
+
+            // Compute the sibling bounds in its coordinates.
+            RectF siblingBounds = mAttachInfo.mTmpTransformRect1;
+            siblingBounds.set(0, 0, sibling.getWidth(), sibling.getHeight());
+
+            // Take into account the sibling transformation matrix.
+            if (!sibling.hasIdentityMatrix()) {
+                sibling.getMatrix().mapRect(siblingBounds);
+            }
+
+            // Offset the sibling to our coordinates.
+            final int siblingDx = sibling.mLeft - mScrollX;
+            final int siblingDy = sibling.mTop - mScrollY;
+            siblingBounds.offset(siblingDx, siblingDy);
+
+            // Compute the intersection between the child and the sibling.
+            if (siblingBounds.intersect(bounds)) {
+                // If an interactive sibling completely covers the child, done.
+                if (siblingBounds.equals(bounds)) {
+                    return false;
+                }
+                // Keep track of the intersection rectangle.
+                RectF intersection = new RectF(siblingBounds);
+                intersections.add(intersection);
+            }
+        }
+
+        if (mParent instanceof ViewGroup) {
+            ViewGroup parentGroup = (ViewGroup) mParent;
+            return parentGroup.translateBoundsAndIntersectionsInWindowCoordinates(
+                    this, bounds, intersections);
+        }
+
+        return true;
+    }
+
+    /**
      * Called when a child view has changed whether or not it is tracking transient state.
      */
     public void childHasTransientStateChanged(View child, boolean childHasTransientState) {
@@ -3072,7 +3178,7 @@
         boolean more = false;
         final long drawingTime = getDrawingTime();
 
-
+        if (usingRenderNodeProperties) canvas.insertReorderBarrier();
         // Only use the preordered list if not HW accelerated, since the HW pipeline will do the
         // draw reordering internally
         final ArrayList<View> preorderedList = usingRenderNodeProperties
@@ -3099,6 +3205,7 @@
                 more |= drawChild(canvas, child, drawingTime);
             }
         }
+        if (usingRenderNodeProperties) canvas.insertInorderBarrier();
 
         if (debugDraw()) {
             onDebugDraw(canvas);
@@ -3300,6 +3407,7 @@
      * @return True if the group's children will be clipped to their bounds,
      * false otherwise.
      */
+    @ViewDebug.ExportedProperty(category = "drawing")
     public boolean getClipChildren() {
         return ((mGroupFlags & FLAG_CLIP_CHILDREN) != 0);
     }
@@ -3348,6 +3456,7 @@
      *
      * @attr ref android.R.styleable#ViewGroup_clipToPadding
      */
+    @ViewDebug.ExportedProperty(category = "drawing")
     public boolean getClipToPadding() {
         return hasBooleanFlag(FLAG_CLIP_TO_PADDING);
     }
@@ -5033,6 +5142,9 @@
     /**
      * Tells the ViewGroup whether to draw its children in the order defined by the method
      * {@link #getChildDrawingOrder(int, int)}.
+     * <p>
+     * Note that {@link View#getZ() Z} reordering, done by {@link #dispatchDraw(Canvas)},
+     * will override custom child ordering done via this method.
      *
      * @param enabled true if the order of the children when drawing is determined by
      *        {@link #getChildDrawingOrder(int, int)}, false otherwise
@@ -5718,6 +5830,28 @@
     }
 
     @Override
+    public void drawableHotspotChanged(float x, float y) {
+        super.drawableHotspotChanged(x, y);
+
+        if ((mGroupFlags & FLAG_NOTIFY_CHILDREN_ON_DRAWABLE_STATE_CHANGE) != 0) {
+            if ((mGroupFlags & FLAG_ADD_STATES_FROM_CHILDREN) != 0) {
+                throw new IllegalStateException("addStateFromChildren cannot be enabled if a"
+                        + " child has duplicateParentState set to true");
+            }
+
+            final View[] children = mChildren;
+            final int count = mChildrenCount;
+
+            for (int i = 0; i < count; i++) {
+                final View child = children[i];
+                if ((child.mViewFlags & DUPLICATE_PARENT_STATE) != 0) {
+                    child.drawableHotspotChanged(x, y);
+                }
+            }
+        }
+    }
+
+    @Override
     protected int[] onCreateDrawableState(int extraSpace) {
         if ((mGroupFlags & FLAG_ADD_STATES_FROM_CHILDREN) == 0) {
             return super.onCreateDrawableState(extraSpace);
@@ -7021,27 +7155,23 @@
             if (another == null) {
                 return 1;
             }
-            if (getClass() != another.getClass()) {
-                return 1;
-            }
-            final int topDiference = mLocation.top - another.mLocation.top;
-            if (topDiference != 0) {
-                return topDiference;
-            }
-            // LTR
+            // We are ordering left-to-right, top-to-bottom.
             if (mLayoutDirection == LAYOUT_DIRECTION_LTR) {
                 final int leftDifference = mLocation.left - another.mLocation.left;
-                // First more to the left than second.
                 if (leftDifference != 0) {
                     return leftDifference;
                 }
             } else { // RTL
                 final int rightDifference = mLocation.right - another.mLocation.right;
-                // First more to the right than second.
                 if (rightDifference != 0) {
                     return -rightDifference;
                 }
             }
+            // We are ordering left-to-right, top-to-bottom.
+            final int topDifference = mLocation.top - another.mLocation.top;
+            if (topDifference != 0) {
+                return topDifference;
+            }
             // Break tie by height.
             final int heightDiference = mLocation.height() - another.mLocation.height();
             if (heightDiference != 0) {
diff --git a/core/java/android/view/ViewOutlineProvider.java b/core/java/android/view/ViewOutlineProvider.java
index 170c5d8..a1a02f6 100644
--- a/core/java/android/view/ViewOutlineProvider.java
+++ b/core/java/android/view/ViewOutlineProvider.java
@@ -44,6 +44,35 @@
     };
 
     /**
+     * Maintains the outline of the View to match its rectangular bounds,
+     * at <code>1.0f</code> alpha.
+     *
+     * This can be used to enable Views that are opaque but lacking a background cast a shadow.
+     */
+    public static final ViewOutlineProvider BOUNDS = new ViewOutlineProvider() {
+        @Override
+        public void getOutline(View view, Outline outline) {
+            outline.setRect(0, 0, view.getWidth(), view.getHeight());
+        }
+    };
+
+    /**
+     * Maintains the outline of the View to match its rectangular padded bounds,
+     * at <code>1.0f</code> alpha.
+     *
+     * This can be used to enable Views that are opaque but lacking a background cast a shadow.
+     */
+    public static final ViewOutlineProvider PADDED_BOUNDS = new ViewOutlineProvider() {
+        @Override
+        public void getOutline(View view, Outline outline) {
+            outline.setRect(view.getPaddingLeft(),
+                    view.getPaddingTop(),
+                    view.getWidth() - view.getPaddingRight(),
+                    view.getHeight() - view.getPaddingBottom());
+        }
+    };
+
+    /**
      * Called to get the provider to populate the Outline.
      *
      * This method will be called by a View when its owned Drawables are invalidated, when the
diff --git a/core/java/android/view/ViewPropertyAnimator.java b/core/java/android/view/ViewPropertyAnimator.java
index bae0cfb..b73b9fa 100644
--- a/core/java/android/view/ViewPropertyAnimator.java
+++ b/core/java/android/view/ViewPropertyAnimator.java
@@ -430,6 +430,10 @@
             }
         }
         mPendingAnimations.clear();
+        mPendingSetupAction = null;
+        mPendingCleanupAction = null;
+        mPendingOnStartAction = null;
+        mPendingOnEndAction = null;
         mView.removeCallbacks(mAnimationStarter);
         if (mRTBackend != null) {
             mRTBackend.cancelAll();
diff --git a/core/java/android/view/ViewPropertyAnimatorRT.java b/core/java/android/view/ViewPropertyAnimatorRT.java
index 20f5182..de96887 100644
--- a/core/java/android/view/ViewPropertyAnimatorRT.java
+++ b/core/java/android/view/ViewPropertyAnimatorRT.java
@@ -81,7 +81,7 @@
             int property = RenderNodeAnimator.mapViewPropertyToRenderProperty(holder.mNameConstant);
 
             final float finalValue = holder.mFromValue + holder.mDeltaValue;
-            RenderNodeAnimator animator = new RenderNodeAnimatorCompat(property, finalValue);
+            RenderNodeAnimator animator = new RenderNodeAnimator(property, finalValue);
             animator.setStartDelay(startDelay);
             animator.setDuration(duration);
             animator.setInterpolator(interpolator);
diff --git a/core/java/android/view/ViewRootImpl.java b/core/java/android/view/ViewRootImpl.java
index 92e0245..43ab4ef 100644
--- a/core/java/android/view/ViewRootImpl.java
+++ b/core/java/android/view/ViewRootImpl.java
@@ -121,7 +121,7 @@
     private static final String PROPERTY_MEDIA_DISABLED = "config.disable_media";
 
     // property used by emulator to determine display shape
-    private static final String PROPERTY_EMULATOR_CIRCULAR = "ro.emulator.circular";
+    public static final String PROPERTY_EMULATOR_CIRCULAR = "ro.emulator.circular";
 
     /**
      * Maximum time we allow the user to roll the trackball enough to generate
@@ -333,6 +333,8 @@
     private boolean mRemoved;
 
     private boolean mIsEmulator;
+    private boolean mIsCircularEmulator;
+    private final boolean mWindowIsRound;
 
     /**
      * Consistency verifier for debugging purposes.
@@ -388,6 +390,8 @@
         mChoreographer = Choreographer.getInstance();
         mDisplayManager = (DisplayManager)context.getSystemService(Context.DISPLAY_SERVICE);
         loadSystemProperties();
+        mWindowIsRound = context.getResources().getBoolean(
+                com.android.internal.R.bool.config_windowIsRound);
     }
 
     public static void addFirstDrawHandler(Runnable callback) {
@@ -671,6 +675,17 @@
         ThreadedRenderer.invokeFunctor(functor, waitForCompletion);
     }
 
+    public void registerAnimatingRenderNode(RenderNode animator) {
+        if (mAttachInfo.mHardwareRenderer != null) {
+            mAttachInfo.mHardwareRenderer.registerAnimatingRenderNode(animator);
+        } else {
+            if (mAttachInfo.mPendingAnimatingRenderNodes == null) {
+                mAttachInfo.mPendingAnimatingRenderNodes = new ArrayList<RenderNode>();
+            }
+            mAttachInfo.mPendingAnimatingRenderNodes.add(animator);
+        }
+    }
+
     private void enableHardwareAcceleration(WindowManager.LayoutParams attrs) {
         mAttachInfo.mHardwareAccelerated = false;
         mAttachInfo.mHardwareAccelerationRequested = false;
@@ -1183,14 +1198,7 @@
     void dispatchApplyInsets(View host) {
         mDispatchContentInsets.set(mAttachInfo.mContentInsets);
         mDispatchStableInsets.set(mAttachInfo.mStableInsets);
-        boolean isRound = false;
-        if ((mWindowAttributes.flags & WindowManager.LayoutParams.FLAG_LAYOUT_IN_OVERSCAN) != 0
-                && mDisplay.getDisplayId() == 0) {
-            // we're fullscreen and not hosted in an ActivityView
-            isRound = (mIsEmulator && SystemProperties.getBoolean(PROPERTY_EMULATOR_CIRCULAR, false))
-                    || mContext.getResources().getBoolean(
-                            com.android.internal.R.bool.config_windowIsRound);
-        }
+        final boolean isRound = (mIsEmulator && mIsCircularEmulator) || mWindowIsRound;
         host.dispatchApplyWindowInsets(new WindowInsets(
                 mDispatchContentInsets, null /* windowDecorInsets */,
                 mDispatchStableInsets, isRound));
@@ -2244,7 +2252,6 @@
             canvas.drawHardwareLayer(mResizeBuffer, mHardwareXOffset, mHardwareYOffset,
                     mResizePaint);
         }
-        drawAccessibilityFocusedDrawableIfNeeded(canvas);
     }
 
     /**
@@ -2330,6 +2337,16 @@
             Trace.traceEnd(Trace.TRACE_TAG_VIEW);
         }
 
+        // For whatever reason we didn't create a HardwareRenderer, end any
+        // hardware animations that are now dangling
+        if (mAttachInfo.mPendingAnimatingRenderNodes != null) {
+            final int count = mAttachInfo.mPendingAnimatingRenderNodes.size();
+            for (int i = 0; i < count; i++) {
+                mAttachInfo.mPendingAnimatingRenderNodes.get(i).endAllAnimators();
+            }
+            mAttachInfo.mPendingAnimatingRenderNodes.clear();
+        }
+
         if (mReportNextDraw) {
             mReportNextDraw = false;
             if (mAttachInfo.mHardwareRenderer != null) {
@@ -2462,25 +2479,9 @@
                 if (mHardwareYOffset != yOffset || mHardwareXOffset != xOffset) {
                     mHardwareYOffset = yOffset;
                     mHardwareXOffset = xOffset;
-                    invalidateRoot = true;
-                }
-                mResizeAlpha = resizeAlpha;
-
-                if (!invalidateRoot) {
-                    // If accessibility focus moved, invalidate the root.
-                    final Drawable drawable = mAttachInfo.mAccessibilityFocusDrawable;
-                    if (drawable != null) {
-                        final Rect bounds = mAttachInfo.mTmpInvalRect;
-                        if (getAccessibilityFocusedRect(bounds)
-                                && !bounds.equals(drawable.getBounds())) {
-                            invalidateRoot = true;
-                        }
-                    }
-                }
-
-                if (invalidateRoot) {
                     mAttachInfo.mHardwareRenderer.invalidateRoot();
                 }
+                mResizeAlpha = resizeAlpha;
 
                 dirty.setEmpty();
 
@@ -2600,8 +2601,6 @@
                 attachInfo.mSetIgnoreDirtyState = false;
 
                 mView.draw(canvas);
-
-                drawAccessibilityFocusedDrawableIfNeeded(canvas);
             } finally {
                 if (!attachInfo.mSetIgnoreDirtyState) {
                     // Only clear the flag if it was not set during the mView.draw() call
@@ -2625,54 +2624,7 @@
         return true;
     }
 
-    /**
-     * We want to draw a highlight around the current accessibility focused.
-     * Since adding a style for all possible view is not a viable option we
-     * have this specialized drawing method.
-     *
-     * Note: We are doing this here to be able to draw the highlight for
-     *       virtual views in addition to real ones.
-     *
-     * @param canvas The canvas on which to draw.
-     */
-    private void drawAccessibilityFocusedDrawableIfNeeded(Canvas canvas) {
-        final Rect bounds = mAttachInfo.mTmpInvalRect;
-        if (getAccessibilityFocusedRect(bounds)) {
-            final Drawable drawable = getAccessibilityFocusedDrawable();
-            if (drawable != null) {
-                drawable.setBounds(bounds);
-                drawable.draw(canvas);
-            }
-        }
-    }
-
-    private boolean getAccessibilityFocusedRect(Rect bounds) {
-        final AccessibilityManager manager = AccessibilityManager.getInstance(mView.mContext);
-        if (!manager.isEnabled() || !manager.isTouchExplorationEnabled()) {
-            return false;
-        }
-
-        final View host = mAccessibilityFocusedHost;
-        if (host == null || host.mAttachInfo == null) {
-            return false;
-        }
-
-        final AccessibilityNodeProvider provider = host.getAccessibilityNodeProvider();
-        if (provider == null) {
-            host.getBoundsOnScreen(bounds);
-        } else if (mAccessibilityFocusedVirtualView != null) {
-            mAccessibilityFocusedVirtualView.getBoundsInScreen(bounds);
-        } else {
-            return false;
-        }
-
-        final AttachInfo attachInfo = mAttachInfo;
-        bounds.offset(-attachInfo.mWindowLeft, -attachInfo.mWindowTop);
-        bounds.intersect(0, 0, attachInfo.mViewRootImpl.mWidth, attachInfo.mViewRootImpl.mHeight);
-        return true;
-    }
-
-    private Drawable getAccessibilityFocusedDrawable() {
+    Drawable getAccessibilityFocusedDrawable() {
         // Lazily load the accessibility focus drawable.
         if (mAttachInfo.mAccessibilityFocusDrawable == null) {
             final TypedValue value = new TypedValue();
@@ -5497,6 +5449,8 @@
 
                 // detect emulator
                 mIsEmulator = Build.HARDWARE.contains("goldfish");
+                mIsCircularEmulator =
+                        SystemProperties.getBoolean(PROPERTY_EMULATOR_CIRCULAR, false);
             }
         });
     }
@@ -6157,6 +6111,33 @@
                     }
                 }
             } break;
+
+
+            case AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED: {
+                if (mAccessibilityFocusedHost != null && mAccessibilityFocusedVirtualView != null) {
+                    // We care only for changes rooted in the focused host.
+                    final long eventSourceId = event.getSourceNodeId();
+                    final int hostViewId = AccessibilityNodeInfo.getAccessibilityViewId(
+                            eventSourceId);
+                    if (hostViewId != mAccessibilityFocusedHost.getAccessibilityViewId()) {
+                        break;
+                    }
+
+                    // We only care about changes that may change the virtual focused view bounds.
+                    final int changes = event.getContentChangeTypes();
+                    if ((changes & AccessibilityEvent.CONTENT_CHANGE_TYPE_SUBTREE) != 0
+                            || changes == AccessibilityEvent.CONTENT_CHANGE_TYPE_UNDEFINED) {
+                        AccessibilityNodeProvider provider = mAccessibilityFocusedHost
+                                .getAccessibilityNodeProvider();
+                        if (provider != null) {
+                            final int virtualChildId = AccessibilityNodeInfo.getVirtualDescendantId(
+                                    mAccessibilityFocusedVirtualView.getSourceNodeId());
+                            mAccessibilityFocusedVirtualView = provider.createAccessibilityNodeInfo(
+                                    virtualChildId);
+                        }
+                    }
+                }
+            } break;
         }
         mAccessibilityManager.sendAccessibilityEvent(event);
         return true;
@@ -6675,14 +6656,15 @@
 
         @Override
         public void findAccessibilityNodeInfoByAccessibilityId(long accessibilityNodeId,
-                int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
+                Region interactiveRegion, int interactionId,
+                IAccessibilityInteractionConnectionCallback callback, int flags,
                 int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
                     .findAccessibilityNodeInfoByAccessibilityIdClientThread(accessibilityNodeId,
-                            interactionId, callback, flags, interrogatingPid, interrogatingTid,
-                            spec);
+                            interactiveRegion, interactionId, callback, flags, interrogatingPid,
+                            interrogatingTid, spec);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
@@ -6697,12 +6679,12 @@
         public void performAccessibilityAction(long accessibilityNodeId, int action,
                 Bundle arguments, int interactionId,
                 IAccessibilityInteractionConnectionCallback callback, int flags,
-                int interogatingPid, long interrogatingTid) {
+                int interrogatingPid, long interrogatingTid) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
                     .performAccessibilityActionClientThread(accessibilityNodeId, action, arguments,
-                            interactionId, callback, flags, interogatingPid, interrogatingTid);
+                            interactionId, callback, flags, interrogatingPid, interrogatingTid);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
@@ -6714,16 +6696,36 @@
         }
 
         @Override
+        public void computeClickPointInScreen(long accessibilityNodeId, Region interactiveRegion,
+                int interactionId, IAccessibilityInteractionConnectionCallback callback,
+                int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
+            ViewRootImpl viewRootImpl = mViewRootImpl.get();
+            if (viewRootImpl != null && viewRootImpl.mView != null) {
+                viewRootImpl.getAccessibilityInteractionController()
+                        .computeClickPointInScreenClientThread(accessibilityNodeId,
+                                interactiveRegion, interactionId, callback, interrogatingPid,
+                                interrogatingTid, spec);
+            } else {
+                // We cannot make the call and notify the caller so it does not wait.
+                try {
+                    callback.setComputeClickPointInScreenActionResult(null, interactionId);
+                } catch (RemoteException re) {
+                    /* best effort - ignore */
+                }
+            }
+        }
+
+        @Override
         public void findAccessibilityNodeInfosByViewId(long accessibilityNodeId,
-                String viewId, int interactionId,
+                String viewId, Region interactiveRegion, int interactionId,
                 IAccessibilityInteractionConnectionCallback callback, int flags,
                 int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
                     .findAccessibilityNodeInfosByViewIdClientThread(accessibilityNodeId,
-                            viewId, interactionId, callback, flags, interrogatingPid,
-                            interrogatingTid, spec);
+                            viewId, interactiveRegion, interactionId, callback, flags,
+                            interrogatingPid, interrogatingTid, spec);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
@@ -6736,14 +6738,15 @@
 
         @Override
         public void findAccessibilityNodeInfosByText(long accessibilityNodeId, String text,
-                int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
+                Region interactiveRegion, int interactionId,
+                IAccessibilityInteractionConnectionCallback callback, int flags,
                 int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
                     .findAccessibilityNodeInfosByTextClientThread(accessibilityNodeId, text,
-                            interactionId, callback, flags, interrogatingPid, interrogatingTid,
-                            spec);
+                            interactiveRegion, interactionId, callback, flags, interrogatingPid,
+                            interrogatingTid, spec);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
@@ -6755,14 +6758,15 @@
         }
 
         @Override
-        public void findFocus(long accessibilityNodeId, int focusType, int interactionId,
-                IAccessibilityInteractionConnectionCallback callback, int flags,
+        public void findFocus(long accessibilityNodeId, int focusType, Region interactiveRegion,
+                int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
                 int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
-                    .findFocusClientThread(accessibilityNodeId, focusType, interactionId, callback,
-                            flags, interrogatingPid, interrogatingTid, spec);
+                    .findFocusClientThread(accessibilityNodeId, focusType, interactiveRegion,
+                            interactionId, callback, flags, interrogatingPid, interrogatingTid,
+                            spec);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
@@ -6774,14 +6778,15 @@
         }
 
         @Override
-        public void focusSearch(long accessibilityNodeId, int direction, int interactionId,
-                IAccessibilityInteractionConnectionCallback callback, int flags,
+        public void focusSearch(long accessibilityNodeId, int direction, Region interactiveRegion,
+                int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
                 int interrogatingPid, long interrogatingTid, MagnificationSpec spec) {
             ViewRootImpl viewRootImpl = mViewRootImpl.get();
             if (viewRootImpl != null && viewRootImpl.mView != null) {
                 viewRootImpl.getAccessibilityInteractionController()
-                    .focusSearchClientThread(accessibilityNodeId, direction, interactionId,
-                            callback, flags, interrogatingPid, interrogatingTid, spec);
+                    .focusSearchClientThread(accessibilityNodeId, direction, interactiveRegion,
+                            interactionId, callback, flags, interrogatingPid, interrogatingTid,
+                            spec);
             } else {
                 // We cannot make the call and notify the caller so it does not wait.
                 try {
diff --git a/core/java/android/view/Window.java b/core/java/android/view/Window.java
index e7b3152..63ab7d2 100644
--- a/core/java/android/view/Window.java
+++ b/core/java/android/view/Window.java
@@ -111,10 +111,19 @@
     public static final int FEATURE_CONTENT_TRANSITIONS = 12;
 
     /**
+     * Enables Activities to run Activity Transitions either through sending or receiving
+     * ActivityOptions bundle created with
+     * {@link android.app.ActivityOptions#makeSceneTransitionAnimation(android.app.Activity,
+     * android.util.Pair[])} or {@link android.app.ActivityOptions#makeSceneTransitionAnimation(
+     * android.app.Activity, View, String)}.
+     */
+    public static final int FEATURE_ACTIVITY_TRANSITIONS = 13;
+
+    /**
      * Max value used as a feature ID
      * @hide
      */
-    public static final int FEATURE_MAX = FEATURE_CONTENT_TRANSITIONS;
+    public static final int FEATURE_MAX = FEATURE_ACTIVITY_TRANSITIONS;
 
     /** Flag for setting the progress bar's visibility to VISIBLE */
     public static final int PROGRESS_VISIBILITY_ON = -1;
@@ -1304,12 +1313,22 @@
     public abstract int getVolumeControlStream();
 
     /**
+     * Sets a {@link MediaController} to send media keys and volume changes to.
+     * If set, this should be preferred for all media keys and volume requests
+     * sent to this window.
+     *
+     * @param controller The controller for the session which should receive
+     *            media keys and volume changes.
      * @see android.app.Activity#setMediaController(android.media.session.MediaController)
      */
     public void setMediaController(MediaController controller) {
     }
 
     /**
+     * Gets the {@link MediaController} that was previously set.
+     *
+     * @return The controller which should receive events.
+     * @see #setMediaController(android.media.session.MediaController)
      * @see android.app.Activity#getMediaController()
      */
     public MediaController getMediaController() {
@@ -1420,7 +1439,9 @@
      * {@link android.transition.Visibility} as entering is governed by changing visibility from
      * {@link View#INVISIBLE} to {@link View#VISIBLE}. If <code>transition</code> is null,
      * entering Views will remain unaffected.
+     *
      * @param transition The Transition to use to move Views into the initial Scene.
+     * @attr ref android.R.styleable#Window_windowEnterTransition
      */
     public void setEnterTransition(Transition transition) {}
 
@@ -1434,8 +1455,10 @@
      * {@link View#VISIBLE} to {@link View#INVISIBLE}. If <code>transition</code> is null,
      * entering Views will remain unaffected. If nothing is set, the default will be to
      * use the same value as set in {@link #setEnterTransition(android.transition.Transition)}.
+     *
      * @param transition The Transition to use to move Views out of the Scene when the Window
      *                   is preparing to close.
+     * @attr ref android.R.styleable#Window_windowReturnTransition
      */
     public void setReturnTransition(Transition transition) {}
 
@@ -1445,9 +1468,11 @@
      * have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
      * {@link android.transition.Visibility} as exiting is governed by changing visibility
      * from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null, the views will
-     * remain unaffected. Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * remain unaffected. Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use to move Views out of the scene when calling a
      *                   new Activity.
+     * @attr ref android.R.styleable#Window_windowExitTransition
      */
     public void setExitTransition(Transition transition) {}
 
@@ -1459,9 +1484,11 @@
      * visibility from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null,
      * the views will remain unaffected. If nothing is set, the default will be to use the same
      * transition as {@link #setExitTransition(android.transition.Transition)}.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use to move Views into the scene when reentering from a
      *                   previously-started Activity.
+     * @attr ref android.R.styleable#Window_windowReenterTransition
      */
     public void setReenterTransition(Transition transition) {}
 
@@ -1471,9 +1498,10 @@
      * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
      * {@link android.transition.Visibility} as entering is governed by changing visibility from
      * {@link View#INVISIBLE} to {@link View#VISIBLE}. If <code>transition</code> is null,
-     * entering Views will remain unaffected.  Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * entering Views will remain unaffected.  Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
      *
      * @return the Transition to use to move Views into the initial Scene.
+     * @attr ref android.R.styleable#Window_windowEnterTransition
      */
     public Transition getEnterTransition() { return null; }
 
@@ -1485,8 +1513,10 @@
      * {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
      * {@link android.transition.Visibility} as entering is governed by changing visibility from
      * {@link View#VISIBLE} to {@link View#INVISIBLE}.
+     *
      * @return The Transition to use to move Views out of the Scene when the Window
      *         is preparing to close.
+     * @attr ref android.R.styleable#Window_windowReturnTransition
      */
     public Transition getReturnTransition() { return null; }
 
@@ -1496,9 +1526,11 @@
      * have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions will extend
      * {@link android.transition.Visibility} as exiting is governed by changing visibility
      * from {@link View#VISIBLE} to {@link View#INVISIBLE}. If transition is null, the views will
-     * remain unaffected. Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * remain unaffected. Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @return the Transition to use to move Views out of the scene when calling a
      * new Activity.
+     * @attr ref android.R.styleable#Window_windowExitTransition
      */
     public Transition getExitTransition() { return null; }
 
@@ -1508,9 +1540,11 @@
      * or ViewGroups that have {@link ViewGroup#isTransitionGroup} return true. Typical Transitions
      * will extend {@link android.transition.Visibility} as exiting is governed by changing
      * visibility from {@link View#VISIBLE} to {@link View#INVISIBLE}.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @return The Transition to use to move Views into the scene when reentering from a
      *         previously-started Activity.
+     * @attr ref android.R.styleable#Window_windowReenterTransition
      */
     public Transition getReenterTransition() { return null; }
 
@@ -1519,9 +1553,11 @@
      * Scene. Typical Transitions will affect size and location, such as
      * {@link android.transition.ChangeBounds}. A null
      * value will cause transferred shared elements to blink to the final position.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use for shared elements transferred into the content
      *                   Scene.
+     * @attr ref android.R.styleable#Window_windowSharedElementEnterTransition
      */
     public void setSharedElementEnterTransition(Transition transition) {}
 
@@ -1532,23 +1568,29 @@
      * value will cause transferred shared elements to blink to the final position.
      * If no value is set, the default will be to use the same value as
      * {@link #setSharedElementEnterTransition(android.transition.Transition)}.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use for shared elements transferred out of the content
      *                   Scene.
+     * @attr ref android.R.styleable#Window_windowSharedElementReturnTransition
      */
     public void setSharedElementReturnTransition(Transition transition) {}
 
     /**
      * Returns the Transition that will be used for shared elements transferred into the content
-     * Scene. Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Scene. Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @return Transition to use for sharend elements transferred into the content Scene.
+     * @attr ref android.R.styleable#Window_windowSharedElementEnterTransition
      */
     public Transition getSharedElementEnterTransition() { return null; }
 
     /**
      * Returns the Transition that will be used for shared elements transferred back to a
-     * calling Activity. Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * calling Activity. Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @return Transition to use for sharend elements transferred into the content Scene.
+     * @attr ref android.R.styleable#Window_windowSharedElementReturnTransition
      */
     public Transition getSharedElementReturnTransition() { return null; }
 
@@ -1557,9 +1599,11 @@
      * before the shared elements are transferred to the called Activity. If the shared elements
      * must animate during the exit transition, this Transition should be used. Upon completion,
      * the shared elements may be transferred to the started Activity.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use for shared elements in the launching Window
      *                   prior to transferring to the launched Activity's Window.
+     * @attr ref android.R.styleable#Window_windowSharedElementExitTransition
      */
     public void setSharedElementExitTransition(Transition transition) {}
 
@@ -1568,29 +1612,33 @@
      * Activity after it has returned the shared element to it start location. If no value
      * is set, this will default to
      * {@link #setSharedElementExitTransition(android.transition.Transition)}.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
+     *
      * @param transition The Transition to use for shared elements in the launching Window
      *                   after the shared element has returned to the Window.
+     * @attr ref android.R.styleable#Window_windowSharedElementReenterTransition
      */
     public void setSharedElementReenterTransition(Transition transition) {}
 
     /**
      * Returns the Transition to use for shared elements in the launching Window prior
      * to transferring to the launched Activity's Window.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
      *
      * @return the Transition to use for shared elements in the launching Window prior
      * to transferring to the launched Activity's Window.
+     * @attr ref android.R.styleable#Window_windowSharedElementExitTransition
      */
     public Transition getSharedElementExitTransition() { return null; }
 
     /**
      * Returns the Transition that will be used for shared elements reentering from a started
      * Activity after it has returned the shared element to it start location.
-     * Requires {@link #FEATURE_CONTENT_TRANSITIONS}.
+     * Requires {@link #FEATURE_ACTIVITY_TRANSITIONS}.
      *
      * @return the Transition that will be used for shared elements reentering from a started
      * Activity after it has returned the shared element to it start location.
+     * @attr ref android.R.styleable#Window_windowSharedElementReenterTransition
      */
     public Transition getSharedElementReenterTransition() { return null; }
 
@@ -1600,8 +1648,10 @@
      * transition of the calling Activity. When true, the transition will start as soon as possible.
      * When false, the transition will wait until the remote exiting transition completes before
      * starting.
+     *
      * @param allow true to start the enter transition when possible or false to
      *              wait until the exiting transition completes.
+     * @attr ref android.R.styleable#Window_windowAllowEnterTransitionOverlap
      */
     public void setAllowEnterTransitionOverlap(boolean allow) {}
 
@@ -1611,8 +1661,10 @@
      * transition of the calling Activity. When true, the transition will start as soon as possible.
      * When false, the transition will wait until the remote exiting transition completes before
      * starting.
+     *
      * @return true when the enter transition should start as soon as possible or false to
      * when it should wait until the exiting transition completes.
+     * @attr ref android.R.styleable#Window_windowAllowEnterTransitionOverlap
      */
     public boolean getAllowEnterTransitionOverlap() { return true; }
 
@@ -1622,10 +1674,20 @@
      * transition of the called Activity when reentering after if finishes. When true,
      * the transition will start as soon as possible. When false, the transition will wait
      * until the called Activity's exiting transition completes before starting.
+     *
      * @param allow true to start the transition when possible or false to wait until the
      *              called Activity's exiting transition completes.
+     * @attr ref android.R.styleable#Window_windowAllowReturnTransitionOverlap
      */
-    public void setAllowExitTransitionOverlap(boolean allow) {}
+    public void setAllowReturnTransitionOverlap(boolean allow) {}
+
+    /**
+     * TODO: remove this.
+     * @hide
+     */
+    public void setAllowExitTransitionOverlap(boolean allow) {
+        setAllowReturnTransitionOverlap(allow);
+    }
 
     /**
      * Returns how the transition set in
@@ -1633,19 +1695,29 @@
      * transition of the called Activity when reentering after if finishes. When true,
      * the transition will start as soon as possible. When false, the transition will wait
      * until the called Activity's exiting transition completes before starting.
+     *
      * @return true when the transition should start when possible or false when it should wait
      * until the called Activity's exiting transition completes.
+     * @attr ref android.R.styleable#Window_windowAllowReturnTransitionOverlap
      */
-    public boolean getAllowExitTransitionOverlap() { return true; }
+    public boolean getAllowReturnTransitionOverlap() { return true; }
+
+    /**
+     * TODO: remove this.
+     * @hide
+     */
+    public boolean getAllowExitTransitionOverlap() { return getAllowReturnTransitionOverlap(); }
 
     /**
      * Returns the duration, in milliseconds, of the window background fade
      * when transitioning into or away from an Activity when called with an Activity Transition.
      * <p>When executing the enter transition, the background starts transparent
-     * and fades in. This requires {@link #FEATURE_CONTENT_TRANSITIONS}. The default is
+     * and fades in. This requires {@link #FEATURE_ACTIVITY_TRANSITIONS}. The default is
      * 300 milliseconds.</p>
+     *
      * @return The duration of the window background fade to opaque during enter transition.
      * @see #getEnterTransition()
+     * @attr ref android.R.styleable#Window_windowTransitionBackgroundFadeDuration
      */
     public long getTransitionBackgroundFadeDuration() { return 0; }
 
@@ -1653,15 +1725,40 @@
      * Sets the duration, in milliseconds, of the window background fade
      * when transitioning into or away from an Activity when called with an Activity Transition.
      * <p>When executing the enter transition, the background starts transparent
-     * and fades in. This requires {@link #FEATURE_CONTENT_TRANSITIONS}. The default is
+     * and fades in. This requires {@link #FEATURE_ACTIVITY_TRANSITIONS}. The default is
      * 300 milliseconds.</p>
+     *
      * @param fadeDurationMillis The duration of the window background fade to or from opaque
      *                           during enter transition.
      * @see #setEnterTransition(android.transition.Transition)
+     * @attr ref android.R.styleable#Window_windowTransitionBackgroundFadeDuration
      */
     public void setTransitionBackgroundFadeDuration(long fadeDurationMillis) { }
 
     /**
+     * Returns <code>true</code> when shared elements should use an Overlay during
+     * shared element transitions or <code>false</code> when they should animate as
+     * part of the normal View hierarchy. The default value is true.
+     *
+     * @return <code>true</code> when shared elements should use an Overlay during
+     * shared element transitions or <code>false</code> when they should animate as
+     * part of the normal View hierarchy.
+     * @attr ref android.R.styleable#Window_windowSharedElementsUseOverlay
+     */
+    public boolean getSharedElementsUseOverlay() { return true; }
+
+    /**
+     * Sets whether or not shared elements should use an Overlay during shared element transitions.
+     * The default value is true.
+     *
+     * @param sharedElementsUseOverlay <code>true</code> indicates that shared elements should
+     *                                 be transitioned with an Overlay or <code>false</code>
+     *                                 to transition within the normal View hierarchy.
+     * @attr ref android.R.styleable#Window_windowSharedElementsUseOverlay
+     */
+    public void setSharedElementsUseOverlay(boolean sharedElementsUseOverlay) { }
+
+    /**
      * @return the color of the status bar.
      */
     public abstract int getStatusBarColor();
diff --git a/core/java/android/view/WindowCallbackWrapper.java b/core/java/android/view/WindowCallbackWrapper.java
new file mode 100644
index 0000000..35a6a76
--- /dev/null
+++ b/core/java/android/view/WindowCallbackWrapper.java
@@ -0,0 +1,144 @@
+/*
+ * Copyright (C) 2014 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 android.view;
+
+import android.view.accessibility.AccessibilityEvent;
+
+/**
+ * A simple decorator stub for Window.Callback that passes through any calls
+ * to the wrapped instance as a base implementation. Call super.foo() to call into
+ * the wrapped callback for any subclasses.
+ *
+ * @hide for internal use
+ */
+public class WindowCallbackWrapper implements Window.Callback {
+    private Window.Callback mWrapped;
+
+    public WindowCallbackWrapper(Window.Callback wrapped) {
+        if (wrapped == null) {
+            throw new IllegalArgumentException("Window callback may not be null");
+        }
+        mWrapped = wrapped;
+    }
+
+    @Override
+    public boolean dispatchKeyEvent(KeyEvent event) {
+        return mWrapped.dispatchKeyEvent(event);
+    }
+
+    @Override
+    public boolean dispatchKeyShortcutEvent(KeyEvent event) {
+        return mWrapped.dispatchKeyShortcutEvent(event);
+    }
+
+    @Override
+    public boolean dispatchTouchEvent(MotionEvent event) {
+        return mWrapped.dispatchTouchEvent(event);
+    }
+
+    @Override
+    public boolean dispatchTrackballEvent(MotionEvent event) {
+        return mWrapped.dispatchTrackballEvent(event);
+    }
+
+    @Override
+    public boolean dispatchGenericMotionEvent(MotionEvent event) {
+        return mWrapped.dispatchGenericMotionEvent(event);
+    }
+
+    @Override
+    public boolean dispatchPopulateAccessibilityEvent(AccessibilityEvent event) {
+        return mWrapped.dispatchPopulateAccessibilityEvent(event);
+    }
+
+    @Override
+    public View onCreatePanelView(int featureId) {
+        return mWrapped.onCreatePanelView(featureId);
+    }
+
+    @Override
+    public boolean onCreatePanelMenu(int featureId, Menu menu) {
+        return mWrapped.onCreatePanelMenu(featureId, menu);
+    }
+
+    @Override
+    public boolean onPreparePanel(int featureId, View view, Menu menu) {
+        return mWrapped.onPreparePanel(featureId, view, menu);
+    }
+
+    @Override
+    public boolean onMenuOpened(int featureId, Menu menu) {
+        return mWrapped.onMenuOpened(featureId, menu);
+    }
+
+    @Override
+    public boolean onMenuItemSelected(int featureId, MenuItem item) {
+        return mWrapped.onMenuItemSelected(featureId, item);
+    }
+
+    @Override
+    public void onWindowAttributesChanged(WindowManager.LayoutParams attrs) {
+        mWrapped.onWindowAttributesChanged(attrs);
+    }
+
+    @Override
+    public void onContentChanged() {
+        mWrapped.onContentChanged();
+    }
+
+    @Override
+    public void onWindowFocusChanged(boolean hasFocus) {
+        mWrapped.onWindowFocusChanged(hasFocus);
+    }
+
+    @Override
+    public void onAttachedToWindow() {
+        mWrapped.onAttachedToWindow();
+    }
+
+    @Override
+    public void onDetachedFromWindow() {
+        mWrapped.onDetachedFromWindow();
+    }
+
+    @Override
+    public void onPanelClosed(int featureId, Menu menu) {
+        mWrapped.onPanelClosed(featureId, menu);
+    }
+
+    @Override
+    public boolean onSearchRequested() {
+        return mWrapped.onSearchRequested();
+    }
+
+    @Override
+    public ActionMode onWindowStartingActionMode(ActionMode.Callback callback) {
+        return mWrapped.onWindowStartingActionMode(callback);
+    }
+
+    @Override
+    public void onActionModeStarted(ActionMode mode) {
+        mWrapped.onActionModeStarted(mode);
+    }
+
+    @Override
+    public void onActionModeFinished(ActionMode mode) {
+        mWrapped.onActionModeFinished(mode);
+    }
+}
+
diff --git a/core/java/android/view/WindowInsets.java b/core/java/android/view/WindowInsets.java
index 571a8f0..9e0719d 100644
--- a/core/java/android/view/WindowInsets.java
+++ b/core/java/android/view/WindowInsets.java
@@ -316,7 +316,6 @@
                     top ? 0 : mSystemWindowInsets.top,
                     right ? 0 : mSystemWindowInsets.right,
                     bottom ? 0 : mSystemWindowInsets.bottom);
-            result.mSystemWindowInsetsConsumed = !hasSystemWindowInsets();
             return result;
         }
         return this;
@@ -336,7 +335,20 @@
             int right, int bottom) {
         final WindowInsets result = new WindowInsets(this);
         result.mSystemWindowInsets = new Rect(left, top, right, bottom);
-        result.mSystemWindowInsetsConsumed = !hasSystemWindowInsets();
+        return result;
+    }
+
+    /**
+     * Returns a copy of this WindowInsets with selected system window insets replaced
+     * with new values.
+     *
+     * @param systemWindowInsets New system window insets. Each field is the inset in pixels
+     *                           for that edge
+     * @return A modified copy of this WindowInsets
+     */
+    public WindowInsets replaceSystemWindowInsets(Rect systemWindowInsets) {
+        final WindowInsets result = new WindowInsets(this);
+        result.mSystemWindowInsets = new Rect(systemWindowInsets);
         return result;
     }
 
@@ -361,7 +373,6 @@
                     top ? 0 : mWindowDecorInsets.top,
                     right ? 0 : mWindowDecorInsets.right,
                     bottom ? 0 : mWindowDecorInsets.bottom);
-            result.mWindowDecorInsetsConsumed = !hasWindowDecorInsets();
             return result;
         }
         return this;
@@ -373,40 +384,79 @@
     public WindowInsets replaceWindowDecorInsets(int left, int top, int right, int bottom) {
         final WindowInsets result = new WindowInsets(this);
         result.mWindowDecorInsets = new Rect(left, top, right, bottom);
-        result.mWindowDecorInsetsConsumed = !hasWindowDecorInsets();
         return result;
     }
 
     /**
-     * @hide
+     * Returns the top stable inset in pixels.
+     *
+     * <p>The stable inset represents the area of a full-screen window that <b>may</b> be
+     * partially or fully obscured by the system UI elements.  This value does not change
+     * based on the visibility state of those elements; for example, if the status bar is
+     * normally shown, but temporarily hidden, the stable inset will still provide the inset
+     * associated with the status bar being shown.</p>
+     *
+     * @return The top stable inset
      */
     public int getStableInsetTop() {
         return mStableInsets.top;
     }
 
     /**
-     * @hide
+     * Returns the left stable inset in pixels.
+     *
+     * <p>The stable inset represents the area of a full-screen window that <b>may</b> be
+     * partially or fully obscured by the system UI elements.  This value does not change
+     * based on the visibility state of those elements; for example, if the status bar is
+     * normally shown, but temporarily hidden, the stable inset will still provide the inset
+     * associated with the status bar being shown.</p>
+     *
+     * @return The left stable inset
      */
     public int getStableInsetLeft() {
         return mStableInsets.left;
     }
 
     /**
-     * @hide
+     * Returns the right stable inset in pixels.
+     *
+     * <p>The stable inset represents the area of a full-screen window that <b>may</b> be
+     * partially or fully obscured by the system UI elements.  This value does not change
+     * based on the visibility state of those elements; for example, if the status bar is
+     * normally shown, but temporarily hidden, the stable inset will still provide the inset
+     * associated with the status bar being shown.</p>
+     *
+     * @return The right stable inset
      */
     public int getStableInsetRight() {
         return mStableInsets.right;
     }
 
     /**
-     * @hide
+     * Returns the bottom stable inset in pixels.
+     *
+     * <p>The stable inset represents the area of a full-screen window that <b>may</b> be
+     * partially or fully obscured by the system UI elements.  This value does not change
+     * based on the visibility state of those elements; for example, if the status bar is
+     * normally shown, but temporarily hidden, the stable inset will still provide the inset
+     * associated with the status bar being shown.</p>
+     *
+     * @return The bottom stable inset
      */
     public int getStableInsetBottom() {
         return mStableInsets.bottom;
     }
 
     /**
-     * @hide
+     * Returns true if this WindowInsets has nonzero stable insets.
+     *
+     * <p>The stable inset represents the area of a full-screen window that <b>may</b> be
+     * partially or fully obscured by the system UI elements.  This value does not change
+     * based on the visibility state of those elements; for example, if the status bar is
+     * normally shown, but temporarily hidden, the stable inset will still provide the inset
+     * associated with the status bar being shown.</p>
+     *
+     * @return true if any of the stable inset values are nonzero
      */
     public boolean hasStableInsets() {
         return mStableInsets.top != 0 || mStableInsets.left != 0 || mStableInsets.right != 0
@@ -414,7 +464,9 @@
     }
 
     /**
-     * @hide
+     * Returns a copy of this WindowInsets with the stable insets fully consumed.
+     *
+     * @return A modified copy of this WindowInsets
      */
     public WindowInsets consumeStableInsets() {
         final WindowInsets result = new WindowInsets(this);
diff --git a/core/java/android/view/WindowManagerPolicy.java b/core/java/android/view/WindowManagerPolicy.java
index 053fdd0..fec7550 100644
--- a/core/java/android/view/WindowManagerPolicy.java
+++ b/core/java/android/view/WindowManagerPolicy.java
@@ -379,6 +379,10 @@
         public static final int LID_CLOSED = 0;
         public static final int LID_OPEN = 1;
 
+        public static final int CAMERA_LENS_COVER_ABSENT = -1;
+        public static final int CAMERA_LENS_UNCOVERED = 0;
+        public static final int CAMERA_LENS_COVERED = 1;
+
         /**
          * Ask the window manager to re-evaluate the system UI flags.
          */
@@ -399,6 +403,11 @@
         public int getLidState();
 
         /**
+         * Returns a code that descripbes whether the camera lens is covered or not.
+         */
+        public int getCameraLensCoverState();
+
+        /**
          * Switch the keyboard layout for the given device.
          * Direction should be +1 or -1 to go to the next or previous keyboard layout.
          */
@@ -629,6 +638,11 @@
     public boolean canBeForceHidden(WindowState win, WindowManager.LayoutParams attrs);
 
     /**
+     * Return the window that is hiding the keyguard, if such a thing exists.
+     */
+    public WindowState getWinShowWhenLockedLw();
+
+    /**
      * Called when the system would like to show a UI to indicate that an
      * application is starting.  You can use this to add a
      * APPLICATION_STARTING_TYPE window with the given appToken to the window
@@ -761,7 +775,8 @@
     public int interceptKeyBeforeQueueing(KeyEvent event, int policyFlags);
 
     /**
-     * Called from the input reader thread before a motion is enqueued when the screen is off.
+     * Called from the input reader thread before a motion is enqueued when the device is in a
+     * non-interactive state.
      *
      * <p>There are some actions that need to be handled here because they
      * affect the power state of the device, for example, waking on motions.
@@ -771,7 +786,7 @@
      *
      * @return Actions flags: may be {@link #ACTION_PASS_TO_USER}.
      */
-    public int interceptWakeMotionBeforeQueueing(long whenNanos, int policyFlags);
+    public int interceptMotionBeforeQueueingNonInteractive(long whenNanos, int policyFlags);
 
     /**
      * Called from the input dispatcher thread before a key is dispatched to a window.
@@ -951,7 +966,14 @@
      * @param lidOpen True if the lid is now open.
      */
     public void notifyLidSwitchChanged(long whenNanos, boolean lidOpen);
-    
+
+    /**
+     * Tell the policy that the camera lens has been covered or uncovered.
+     * @param whenNanos The time when the change occurred in uptime nanoseconds.
+     * @param lensCovered True if the lens is covered.
+     */
+    public void notifyCameraLensCoverSwitchChanged(long whenNanos, boolean lensCovered);
+
     /**
      * Tell the policy if anyone is requesting that keyguard not come on.
      *
diff --git a/core/java/android/view/accessibility/AccessibilityCache.java b/core/java/android/view/accessibility/AccessibilityCache.java
index ca6437a..ead757e 100644
--- a/core/java/android/view/accessibility/AccessibilityCache.java
+++ b/core/java/android/view/accessibility/AccessibilityCache.java
@@ -54,7 +54,12 @@
             if (DEBUG) {
                 Log.i(LOG_TAG, "Caching window: " + window.getId());
             }
-            mWindowCache.put(window.getId(), window);
+            final int windowId = window.getId();
+            AccessibilityWindowInfo oldWindow = mWindowCache.get(windowId);
+            if (oldWindow != null) {
+                oldWindow.recycle();
+            }
+            mWindowCache.put(windowId, AccessibilityWindowInfo.obtain(window));
         }
     }
 
@@ -183,14 +188,13 @@
                     sortedWindows.put(window.getLayer(), window);
                 }
 
-                List<AccessibilityWindowInfo> windows = new ArrayList<>();
+                List<AccessibilityWindowInfo> windows = new ArrayList<>(windowCount);
                 for (int i = windowCount - 1; i >= 0; i--) {
                     AccessibilityWindowInfo window = sortedWindows.valueAt(i);
                     windows.add(AccessibilityWindowInfo.obtain(window));
+                    sortedWindows.removeAt(i);
                 }
 
-                sortedWindows.clear();
-
                 return windows;
             }
             return null;
diff --git a/core/java/android/view/accessibility/AccessibilityInteractionClient.java b/core/java/android/view/accessibility/AccessibilityInteractionClient.java
index db78ec5..374f7e0 100644
--- a/core/java/android/view/accessibility/AccessibilityInteractionClient.java
+++ b/core/java/android/view/accessibility/AccessibilityInteractionClient.java
@@ -17,6 +17,7 @@
 package android.view.accessibility;
 
 import android.accessibilityservice.IAccessibilityServiceConnection;
+import android.graphics.Point;
 import android.os.Binder;
 import android.os.Build;
 import android.os.Bundle;
@@ -98,6 +99,8 @@
 
     private boolean mPerformAccessibilityActionResult;
 
+    private Point mComputeClickPointResult;
+
     private Message mSameThreadMessage;
 
     private static final SparseArray<IAccessibilityServiceConnection> sConnectionCache =
@@ -519,6 +522,43 @@
         return false;
     }
 
+    /**
+     * Computes a point in screen coordinates where sending a down/up events would
+     * perform a click on an {@link AccessibilityNodeInfo}.
+     *
+     * @param connectionId The id of a connection for interacting with the system.
+     * @param accessibilityWindowId A unique window id. Use
+     *     {@link android.view.accessibility.AccessibilityNodeInfo#ACTIVE_WINDOW_ID}
+     *     to query the currently active window.
+     * @param accessibilityNodeId A unique view id or virtual descendant id from
+     *     where to start the search. Use
+     *     {@link android.view.accessibility.AccessibilityNodeInfo#ROOT_NODE_ID}
+     *     to start from the root.
+     * @return Point the click point of null if no such point.
+     */
+    public Point computeClickPointInScreen(int connectionId, int accessibilityWindowId,
+            long accessibilityNodeId) {
+        try {
+            IAccessibilityServiceConnection connection = getConnection(connectionId);
+            if (connection != null) {
+                final int interactionId = mInteractionIdCounter.getAndIncrement();
+                final boolean success = connection.computeClickPointInScreen(
+                        accessibilityWindowId, accessibilityNodeId,
+                        interactionId, this, Thread.currentThread().getId());
+                if (success) {
+                    return getComputeClickPointInScreenResultAndClear(interactionId);
+                }
+            } else {
+                if (DEBUG) {
+                    Log.w(LOG_TAG, "No connection for connection id: " + connectionId);
+                }
+            }
+        } catch (RemoteException re) {
+            Log.w(LOG_TAG, "Error while calling remote computeClickPointInScreen", re);
+        }
+        return null;
+    }
+
     public void clearCache() {
         sAccessibilityCache.clear();
     }
@@ -634,6 +674,34 @@
     }
 
     /**
+     * Gets the result of a request to compute a point in screen for clicking on a node.
+     *
+     * @param interactionId The interaction id to match the result with the request.
+     * @return The point or null if no such point.
+     */
+    private Point getComputeClickPointInScreenResultAndClear(int interactionId) {
+        synchronized (mInstanceLock) {
+            final boolean success = waitForResultTimedLocked(interactionId);
+            Point result = success ? mComputeClickPointResult : null;
+            clearResultLocked();
+            return result;
+        }
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    public void setComputeClickPointInScreenActionResult(Point point, int interactionId) {
+        synchronized (mInstanceLock) {
+            if (interactionId > mInteractionId) {
+                mComputeClickPointResult = point;
+                mInteractionId = interactionId;
+            }
+            mInstanceLock.notifyAll();
+        }
+    }
+
+    /**
      * Clears the result state.
      */
     private void clearResultLocked() {
@@ -641,6 +709,7 @@
         mFindAccessibilityNodeInfoResult = null;
         mFindAccessibilityNodeInfosResult = null;
         mPerformAccessibilityActionResult = false;
+        mComputeClickPointResult = null;
     }
 
     /**
diff --git a/core/java/android/view/accessibility/AccessibilityWindowInfo.java b/core/java/android/view/accessibility/AccessibilityWindowInfo.java
index 80b5c50..ad55f5f 100644
--- a/core/java/android/view/accessibility/AccessibilityWindowInfo.java
+++ b/core/java/android/view/accessibility/AccessibilityWindowInfo.java
@@ -55,6 +55,7 @@
 
     private static final int BOOLEAN_PROPERTY_ACTIVE = 1 << 0;
     private static final int BOOLEAN_PROPERTY_FOCUSED = 1 << 1;
+    private static final int BOOLEAN_PROPERTY_ACCESSIBLITY_FOCUSED = 1 << 2;
 
     // Housekeeping.
     private static final int MAX_POOL_SIZE = 10;
@@ -258,6 +259,26 @@
     }
 
     /**
+     * Gets if this window has accessibility focus.
+     *
+     * @return Whether has accessibility focus.
+     */
+    public boolean isAccessibilityFocused() {
+        return getBooleanProperty(BOOLEAN_PROPERTY_ACCESSIBLITY_FOCUSED);
+    }
+
+    /**
+     * Sets if this window has accessibility focus.
+     *
+     * @param Whether has accessibility focus.
+     *
+     * @hide
+     */
+    public void setAccessibilityFocused(boolean focused) {
+        setBooleanProperty(BOOLEAN_PROPERTY_ACCESSIBLITY_FOCUSED, focused);
+    }
+
+    /**
      * Gets the number of child windows.
      *
      * @return The child count.
diff --git a/core/java/android/view/accessibility/CaptioningManager.java b/core/java/android/view/accessibility/CaptioningManager.java
index 334ff43..382a266 100644
--- a/core/java/android/view/accessibility/CaptioningManager.java
+++ b/core/java/android/view/accessibility/CaptioningManager.java
@@ -330,15 +330,30 @@
          */
         public final String mRawTypeface;
 
+        private final boolean mHasForegroundColor;
+        private final boolean mHasBackgroundColor;
+        private final boolean mHasEdgeType;
+        private final boolean mHasEdgeColor;
+        private final boolean mHasWindowColor;
+
+        /** Lazily-created typeface based on the raw typeface string. */
         private Typeface mParsedTypeface;
 
         private CaptionStyle(int foregroundColor, int backgroundColor, int edgeType, int edgeColor,
                 int windowColor, String rawTypeface) {
-            this.foregroundColor = foregroundColor;
-            this.backgroundColor = backgroundColor;
-            this.edgeType = edgeType;
-            this.edgeColor = edgeColor;
-            this.windowColor = windowColor;
+            mHasForegroundColor = foregroundColor != COLOR_UNSPECIFIED;
+            mHasBackgroundColor = backgroundColor != COLOR_UNSPECIFIED;
+            mHasEdgeType = edgeType != EDGE_TYPE_UNSPECIFIED;
+            mHasEdgeColor = edgeColor != COLOR_UNSPECIFIED;
+            mHasWindowColor = windowColor != COLOR_UNSPECIFIED;
+
+            // Always use valid colors, even when no override is specified, to
+            // ensure backwards compatibility with apps targeting KitKat MR2.
+            this.foregroundColor = mHasForegroundColor ? foregroundColor : Color.WHITE;
+            this.backgroundColor = mHasBackgroundColor ? backgroundColor : Color.BLACK;
+            this.edgeType = mHasEdgeType ? edgeType : EDGE_TYPE_NONE;
+            this.edgeColor = mHasEdgeColor ? edgeColor : Color.BLACK;
+            this.windowColor = mHasWindowColor ? windowColor : COLOR_NONE_OPAQUE;
 
             mRawTypeface = rawTypeface;
         }
@@ -375,7 +390,7 @@
          *         otherwise
          */
         public boolean hasBackgroundColor() {
-            return backgroundColor != COLOR_UNSPECIFIED;
+            return mHasBackgroundColor;
         }
 
         /**
@@ -384,7 +399,7 @@
          *         otherwise
          */
         public boolean hasForegroundColor() {
-            return foregroundColor != COLOR_UNSPECIFIED;
+            return mHasForegroundColor;
         }
 
         /**
@@ -393,7 +408,7 @@
          *         otherwise
          */
         public boolean hasEdgeType() {
-            return edgeType != EDGE_TYPE_UNSPECIFIED;
+            return mHasEdgeType;
         }
 
         /**
@@ -402,7 +417,7 @@
          *         otherwise
          */
         public boolean hasEdgeColor() {
-            return edgeColor != COLOR_UNSPECIFIED;
+            return mHasEdgeColor;
         }
 
         /**
@@ -411,7 +426,7 @@
          *         otherwise
          */
         public boolean hasWindowColor() {
-            return windowColor != COLOR_UNSPECIFIED;
+            return mHasWindowColor;
         }
 
         /**
diff --git a/core/java/android/view/accessibility/IAccessibilityInteractionConnection.aidl b/core/java/android/view/accessibility/IAccessibilityInteractionConnection.aidl
index 8d15472..66a3f46 100644
--- a/core/java/android/view/accessibility/IAccessibilityInteractionConnection.aidl
+++ b/core/java/android/view/accessibility/IAccessibilityInteractionConnection.aidl
@@ -16,6 +16,8 @@
 
 package android.view.accessibility;
 
+import android.graphics.Region;
+import android.graphics.Point;
 import android.os.Bundle;
 import android.view.MagnificationSpec;
 import android.view.accessibility.AccessibilityNodeInfo;
@@ -29,27 +31,31 @@
  */
 oneway interface IAccessibilityInteractionConnection {
 
-    void findAccessibilityNodeInfoByAccessibilityId(long accessibilityNodeId, int interactionId,
-        IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
-        long interrogatingTid, in MagnificationSpec spec);
-
-    void findAccessibilityNodeInfosByViewId(long accessibilityNodeId, String viewId,
+    void findAccessibilityNodeInfoByAccessibilityId(long accessibilityNodeId, in Region bounds,
         int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
         int interrogatingPid, long interrogatingTid, in MagnificationSpec spec);
 
-    void findAccessibilityNodeInfosByText(long accessibilityNodeId, String text, int interactionId,
+    void findAccessibilityNodeInfosByViewId(long accessibilityNodeId, String viewId,
+        in Region bounds, int interactionId, IAccessibilityInteractionConnectionCallback callback,
+        int flags, int interrogatingPid, long interrogatingTid, in MagnificationSpec spec);
+
+    void findAccessibilityNodeInfosByText(long accessibilityNodeId, String text, in Region bounds,
+        int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
+        int interrogatingPid, long interrogatingTid, in MagnificationSpec spec);
+
+    void findFocus(long accessibilityNodeId, int focusType, in Region bounds, int interactionId,
         IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
         long interrogatingTid, in MagnificationSpec spec);
 
-    void findFocus(long accessibilityNodeId, int focusType, int interactionId,
-        IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
-        long interrogatingTid, in MagnificationSpec spec);
-
-    void focusSearch(long accessibilityNodeId, int direction, int interactionId,
+    void focusSearch(long accessibilityNodeId, int direction, in Region bounds, int interactionId,
         IAccessibilityInteractionConnectionCallback callback, int flags, int interrogatingPid,
         long interrogatingTid, in MagnificationSpec spec);
 
     void performAccessibilityAction(long accessibilityNodeId, int action, in Bundle arguments,
         int interactionId, IAccessibilityInteractionConnectionCallback callback, int flags,
         int interrogatingPid, long interrogatingTid);
+
+    void computeClickPointInScreen(long accessibilityNodeId, in Region bounds, int interactionId,
+        IAccessibilityInteractionConnectionCallback callback, int interrogatingPid,
+        long interrogatingTid, in MagnificationSpec spec);
 }
diff --git a/core/java/android/view/accessibility/IAccessibilityInteractionConnectionCallback.aidl b/core/java/android/view/accessibility/IAccessibilityInteractionConnectionCallback.aidl
index c1a3ab7..f480216 100644
--- a/core/java/android/view/accessibility/IAccessibilityInteractionConnectionCallback.aidl
+++ b/core/java/android/view/accessibility/IAccessibilityInteractionConnectionCallback.aidl
@@ -16,6 +16,7 @@
 
 package android.view.accessibility;
 
+import android.graphics.Point;
 import android.view.accessibility.AccessibilityNodeInfo;
 import java.util.List;
 
@@ -51,4 +52,12 @@
      * @param interactionId The interaction id to match the result with the request.
      */
     void setPerformAccessibilityActionResult(boolean succeeded, int interactionId);
+
+    /**
+     * Sets the result of a request to compute a point for clicking in a view.
+     *
+     * @param point The point of null if no such point.
+     * @param interactionId The interaction id to match the result with the request.
+     */
+    void setComputeClickPointInScreenActionResult(in Point point, int interactionId);
 }
diff --git a/core/java/android/view/inputmethod/BaseInputConnection.java b/core/java/android/view/inputmethod/BaseInputConnection.java
index 8cae27b..ba5d6c2 100644
--- a/core/java/android/view/inputmethod/BaseInputConnection.java
+++ b/core/java/android/view/inputmethod/BaseInputConnection.java
@@ -429,25 +429,10 @@
     }
 
     /**
-     * The default implementation is responsible for handling
-     * {@link CursorAnchorInfoRequest#TYPE_CURSOR_RECT}. In fact, for derived classes, calling
-     * {@code super.requestCursorAnchorInfo(request)} is the only way to handle
-     * {@link CursorAnchorInfoRequest#TYPE_CURSOR_RECT}.
+     * The default implementation does nothing.
      */
-    public int requestCursorAnchorInfo(CursorAnchorInfoRequest request) {
-        // This implementation supports TYPE_CURSOR_RECT only.
-        if (request == null ||
-                request.getRequestType() != CursorAnchorInfoRequest.TYPE_CURSOR_RECT) {
-            return CursorAnchorInfoRequest.RESULT_NOT_HANDLED;
-        }
-        if (mIMM == null) {
-            // In this case, TYPE_CURSOR_RECT is not handled.
-            // TODO: Return some notification code for the input method that indicates
-            // Cursor rect information is temporarily unavailable.
-            return CursorAnchorInfoRequest.RESULT_NOT_HANDLED;
-        }
-        mIMM.setCursorRectMonitorMode(request.getRequestFlags());
-        return CursorAnchorInfoRequest.RESULT_SCHEDULED;
+    public boolean requestCursorUpdates(int cursorUpdateMode) {
+        return false;
     }
 
     /**
diff --git a/core/java/android/view/inputmethod/CursorAnchorInfo.java b/core/java/android/view/inputmethod/CursorAnchorInfo.java
index 730b7f6..fd73432 100644
--- a/core/java/android/view/inputmethod/CursorAnchorInfo.java
+++ b/core/java/android/view/inputmethod/CursorAnchorInfo.java
@@ -35,9 +35,21 @@
  * actually inserted.</p>
  */
 public final class CursorAnchorInfo implements Parcelable {
+    /**
+     * The index of the first character of the selected text (inclusive). {@code -1} when there is
+     * no text selection.
+     */
     private final int mSelectionStart;
+    /**
+     * The index of the first character of the selected text (exclusive). {@code -1} when there is
+     * no text selection.
+     */
     private final int mSelectionEnd;
 
+    /**
+     * The index of the first character of the composing text (inclusive). {@code -1} when there is
+     * no composing text.
+     */
     private final int mComposingTextStart;
     /**
      * The text, tracked as a composing region.
@@ -45,9 +57,9 @@
     private final CharSequence mComposingText;
 
     /**
-     * {@code True} if the insertion marker is partially or entirely clipped by other UI elements.
+     * Flags of the insertion marker. See {@link #FLAG_HAS_VISIBLE_REGION} for example.
      */
-    private final boolean mInsertionMarkerClipped;
+    private final int mInsertionMarkerFlags;
     /**
      * Horizontal position of the insertion marker, in the local coordinates that will be
      * transformed with the transformation matrix when rendered on the screen. This should be
@@ -82,7 +94,7 @@
      * Java chars, in the local coordinates that will be transformed with the transformation matrix
      * when rendered on the screen.
      */
-    private final SparseRectFArray mCharacterRects;
+    private final SparseRectFArray mCharacterBoundsArray;
 
     /**
      * Transformation matrix that is applied to any positional information of this class to
@@ -90,41 +102,35 @@
      */
     private final Matrix mMatrix;
 
-    public static final int CHARACTER_RECT_TYPE_MASK = 0x0f;
     /**
-     * Type for {@link #CHARACTER_RECT_TYPE_MASK}: the editor did not specify any type of this
-     * character. Editor authors should not use this flag.
+     * Flag for {@link #getInsertionMarkerFlags()} and {@link #getCharacterBoundsFlags(int)}: the
+     * insertion marker or character bounds have at least one visible region.
      */
-    public static final int CHARACTER_RECT_TYPE_UNSPECIFIED = 0;
+    public static final int FLAG_HAS_VISIBLE_REGION = 0x01;
+
     /**
-     * Type for {@link #CHARACTER_RECT_TYPE_MASK}: the character is entirely visible.
+     * Flag for {@link #getInsertionMarkerFlags()} and {@link #getCharacterBoundsFlags(int)}: the
+     * insertion marker or character bounds have at least one invisible (clipped) region.
      */
-    public static final int CHARACTER_RECT_TYPE_FULLY_VISIBLE = 1;
+    public static final int FLAG_HAS_INVISIBLE_REGION = 0x02;
+
     /**
-     * Type for {@link #CHARACTER_RECT_TYPE_MASK}: some area of the character is invisible.
+     * Flag for {@link #getInsertionMarkerFlags()} and {@link #getCharacterBoundsFlags(int)}: the
+     * insertion marker or character bounds is placed at right-to-left (RTL) character.
      */
-    public static final int CHARACTER_RECT_TYPE_PARTIALLY_VISIBLE = 2;
-    /**
-     * Type for {@link #CHARACTER_RECT_TYPE_MASK}: the character is entirely invisible.
-     */
-    public static final int CHARACTER_RECT_TYPE_INVISIBLE = 3;
-    /**
-     * Type for {@link #CHARACTER_RECT_TYPE_MASK}: the editor gave up to calculate the rectangle
-     * for this character. Input method authors should ignore the returned rectangle.
-     */
-    public static final int CHARACTER_RECT_TYPE_NOT_FEASIBLE = 4;
+    public static final int FLAG_IS_RTL = 0x04;
 
     public CursorAnchorInfo(final Parcel source) {
         mSelectionStart = source.readInt();
         mSelectionEnd = source.readInt();
         mComposingTextStart = source.readInt();
         mComposingText = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(source);
-        mInsertionMarkerClipped = (source.readInt() != 0);
+        mInsertionMarkerFlags = source.readInt();
         mInsertionMarkerHorizontal = source.readFloat();
         mInsertionMarkerTop = source.readFloat();
         mInsertionMarkerBaseline = source.readFloat();
         mInsertionMarkerBottom = source.readFloat();
-        mCharacterRects = source.readParcelable(SparseRectFArray.class.getClassLoader());
+        mCharacterBoundsArray = source.readParcelable(SparseRectFArray.class.getClassLoader());
         mMatrix = new Matrix();
         mMatrix.setValues(source.createFloatArray());
     }
@@ -141,12 +147,12 @@
         dest.writeInt(mSelectionEnd);
         dest.writeInt(mComposingTextStart);
         TextUtils.writeToParcel(mComposingText, dest, flags);
-        dest.writeInt(mInsertionMarkerClipped ? 1 : 0);
+        dest.writeInt(mInsertionMarkerFlags);
         dest.writeFloat(mInsertionMarkerHorizontal);
         dest.writeFloat(mInsertionMarkerTop);
         dest.writeFloat(mInsertionMarkerBaseline);
         dest.writeFloat(mInsertionMarkerBottom);
-        dest.writeParcelable(mCharacterRects, flags);
+        dest.writeParcelable(mCharacterBoundsArray, flags);
         final float[] matrixArray = new float[9];
         mMatrix.getValues(matrixArray);
         dest.writeFloatArray(matrixArray);
@@ -154,18 +160,17 @@
 
     @Override
     public int hashCode(){
-        // TODO: Improve the hash function.
         final float floatHash = mInsertionMarkerHorizontal + mInsertionMarkerTop
                 + mInsertionMarkerBaseline + mInsertionMarkerBottom;
         int hash = floatHash > 0 ? (int) floatHash : (int)(-floatHash);
         hash *= 31;
-        hash += (mInsertionMarkerClipped ? 2 : 1);
+        hash += mInsertionMarkerFlags;
         hash *= 31;
         hash += mSelectionStart + mSelectionEnd + mComposingTextStart;
         hash *= 31;
         hash += Objects.hashCode(mComposingText);
         hash *= 31;
-        hash += Objects.hashCode(mCharacterRects);
+        hash += Objects.hashCode(mCharacterBoundsArray);
         hash *= 31;
         hash += Objects.hashCode(mMatrix);
         return hash;
@@ -204,17 +209,14 @@
                 || !Objects.equals(mComposingText, that.mComposingText)) {
             return false;
         }
-        if (mInsertionMarkerClipped != that.mInsertionMarkerClipped
+        if (mInsertionMarkerFlags != that.mInsertionMarkerFlags
                 || !areSameFloatImpl(mInsertionMarkerHorizontal, that.mInsertionMarkerHorizontal)
                 || !areSameFloatImpl(mInsertionMarkerTop, that.mInsertionMarkerTop)
                 || !areSameFloatImpl(mInsertionMarkerBaseline, that.mInsertionMarkerBaseline)
                 || !areSameFloatImpl(mInsertionMarkerBottom, that.mInsertionMarkerBottom)) {
             return false;
         }
-        if (!Objects.equals(mComposingTextStart, that.mComposingTextStart)) {
-            return false;
-        }
-        if (!Objects.equals(mCharacterRects, that.mCharacterRects)) {
+        if (!Objects.equals(mCharacterBoundsArray, that.mCharacterBoundsArray)) {
             return false;
         }
         if (!Objects.equals(mMatrix, that.mMatrix)) {
@@ -228,12 +230,12 @@
         return "SelectionInfo{mSelection=" + mSelectionStart + "," + mSelectionEnd
                 + " mComposingTextStart=" + mComposingTextStart
                 + " mComposingText=" + Objects.toString(mComposingText)
-                + " mInsertionMarkerClipped=" + mInsertionMarkerClipped
+                + " mInsertionMarkerFlags=" + mInsertionMarkerFlags
                 + " mInsertionMarkerHorizontal=" + mInsertionMarkerHorizontal
                 + " mInsertionMarkerTop=" + mInsertionMarkerTop
                 + " mInsertionMarkerBaseline=" + mInsertionMarkerBaseline
                 + " mInsertionMarkerBottom=" + mInsertionMarkerBottom
-                + " mCharacterRects=" + Objects.toString(mCharacterRects)
+                + " mCharacterBoundsArray=" + Objects.toString(mCharacterBoundsArray)
                 + " mMatrix=" + Objects.toString(mMatrix)
                 + "}";
     }
@@ -242,6 +244,19 @@
      * Builder for {@link CursorAnchorInfo}. This class is not designed to be thread-safe.
      */
     public static final class Builder {
+        private int mSelectionStart = -1;
+        private int mSelectionEnd = -1;
+        private int mComposingTextStart = -1;
+        private CharSequence mComposingText = null;
+        private float mInsertionMarkerHorizontal = Float.NaN;
+        private float mInsertionMarkerTop = Float.NaN;
+        private float mInsertionMarkerBaseline = Float.NaN;
+        private float mInsertionMarkerBottom = Float.NaN;
+        private int mInsertionMarkerFlags = 0;
+        private SparseRectFArrayBuilder mCharacterBoundsArrayBuilder = null;
+        private final Matrix mMatrix = new Matrix(Matrix.IDENTITY_MATRIX);
+        private boolean mMatrixInitialized = false;
+
         /**
          * Sets the text range of the selection. Calling this can be skipped if there is no
          * selection.
@@ -251,8 +266,6 @@
             mSelectionEnd = newEnd;
             return this;
         }
-        private int mSelectionStart = -1;
-        private int mSelectionEnd = -1;
 
         /**
          * Sets the text range of the composing text. Calling this can be skipped if there is
@@ -271,8 +284,6 @@
             }
             return this;
         }
-        private int mComposingTextStart = -1;
-        private CharSequence mComposingText = null;
 
         /**
          * Sets the location of the text insertion point (zero width cursor) as a rectangle in
@@ -291,62 +302,46 @@
          * @param lineBottom vertical position of the insertion marker, in the local coordinates
          * that will be transformed with the transformation matrix when rendered on the screen. This
          * should be calculated or compatible with {@link Layout#getLineBottom(int)}.
-         * @param clipped {@code true} is the insertion marker is partially or entierly clipped by
-         * other UI elements.
+         * @param flags flags of the insertion marker. See {@link #FLAG_HAS_VISIBLE_REGION} for
+         * example.
          */
         public Builder setInsertionMarkerLocation(final float horizontalPosition,
                 final float lineTop, final float lineBaseline, final float lineBottom,
-                final boolean clipped){
+                final int flags){
             mInsertionMarkerHorizontal = horizontalPosition;
             mInsertionMarkerTop = lineTop;
             mInsertionMarkerBaseline = lineBaseline;
             mInsertionMarkerBottom = lineBottom;
-            mInsertionMarkerClipped = clipped;
+            mInsertionMarkerFlags = flags;
             return this;
         }
-        private float mInsertionMarkerHorizontal = Float.NaN;
-        private float mInsertionMarkerTop = Float.NaN;
-        private float mInsertionMarkerBaseline = Float.NaN;
-        private float mInsertionMarkerBottom = Float.NaN;
-        private boolean mInsertionMarkerClipped = false;
 
         /**
          * Adds the bounding box of the character specified with the index.
          *
          * @param index index of the character in Java chars units. Must be specified in
          * ascending order across successive calls.
-         * @param leadingEdgeX x coordinate of the leading edge of the character in local
-         * coordinates, that is, left edge for LTR text and right edge for RTL text.
-         * @param leadingEdgeY y coordinate of the leading edge of the character in local
-         * coordinates.
-         * @param trailingEdgeX x coordinate of the trailing edge of the character in local
-         * coordinates, that is, right edge for LTR text and left edge for RTL text.
-         * @param trailingEdgeY y coordinate of the trailing edge of the character in local
-         * coordinates.
-         * @param flags type and flags for this character. See
-         * {@link #CHARACTER_RECT_TYPE_FULLY_VISIBLE} for example.
+         * @param left x coordinate of the left edge of the character in local coordinates.
+         * @param top y coordinate of the top edge of the character in local coordinates.
+         * @param right x coordinate of the right edge of the character in local coordinates.
+         * @param bottom y coordinate of the bottom edge of the character in local coordinates.
+         * @param flags flags for this character bounds. See {@link #FLAG_HAS_VISIBLE_REGION},
+         * {@link #FLAG_HAS_INVISIBLE_REGION} and {@link #FLAG_IS_RTL}. These flags must be
+         * specified when necessary.
          * @throws IllegalArgumentException If the index is a negative value, or not greater than
          * all of the previously called indices.
          */
-        public Builder addCharacterRect(final int index, final float leadingEdgeX,
-                final float leadingEdgeY, final float trailingEdgeX, final float trailingEdgeY,
-                final int flags) {
+        public Builder addCharacterBounds(final int index, final float left, final float top,
+                final float right, final float bottom, final int flags) {
             if (index < 0) {
                 throw new IllegalArgumentException("index must not be a negative integer.");
             }
-            final int type = flags & CHARACTER_RECT_TYPE_MASK;
-            if (type == CHARACTER_RECT_TYPE_UNSPECIFIED) {
-                throw new IllegalArgumentException("Type except for "
-                        + "CHARACTER_RECT_TYPE_UNSPECIFIED must be specified.");
+            if (mCharacterBoundsArrayBuilder == null) {
+                mCharacterBoundsArrayBuilder = new SparseRectFArrayBuilder();
             }
-            if (mCharacterRectBuilder == null) {
-                mCharacterRectBuilder = new SparseRectFArrayBuilder();
-            }
-            mCharacterRectBuilder.append(index, leadingEdgeX, leadingEdgeY, trailingEdgeX,
-                    trailingEdgeY, flags);
+            mCharacterBoundsArrayBuilder.append(index, left, top, right, bottom, flags);
             return this;
         }
-        private SparseRectFArrayBuilder mCharacterRectBuilder = null;
 
         /**
          * Sets the matrix that transforms local coordinates into screen coordinates.
@@ -358,8 +353,6 @@
             mMatrixInitialized = true;
             return this;
         }
-        private final Matrix mMatrix = new Matrix(Matrix.IDENTITY_MATRIX);
-        private boolean mMatrixInitialized = false;
 
         /**
          * @return {@link CursorAnchorInfo} using parameters in this {@link Builder}.
@@ -368,13 +361,15 @@
          */
         public CursorAnchorInfo build() {
             if (!mMatrixInitialized) {
-                // Coordinate transformation matrix is mandatory when positional parameters are
-                // specified.
-                if ((mCharacterRectBuilder != null && !mCharacterRectBuilder.isEmpty()) ||
-                        !Float.isNaN(mInsertionMarkerHorizontal) ||
-                        !Float.isNaN(mInsertionMarkerTop) ||
-                        !Float.isNaN(mInsertionMarkerBaseline) ||
-                        !Float.isNaN(mInsertionMarkerBottom)) {
+                // Coordinate transformation matrix is mandatory when at least one positional
+                // parameter is specified.
+                final boolean hasCharacterBounds = (mCharacterBoundsArrayBuilder != null
+                        && !mCharacterBoundsArrayBuilder.isEmpty());
+                if (hasCharacterBounds
+                        || !Float.isNaN(mInsertionMarkerHorizontal)
+                        || !Float.isNaN(mInsertionMarkerTop)
+                        || !Float.isNaN(mInsertionMarkerBaseline)
+                        || !Float.isNaN(mInsertionMarkerBottom)) {
                     throw new IllegalArgumentException("Coordinate transformation matrix is " +
                             "required when positional parameters are specified.");
                 }
@@ -391,15 +386,15 @@
             mSelectionEnd = -1;
             mComposingTextStart = -1;
             mComposingText = null;
-            mInsertionMarkerClipped = false;
+            mInsertionMarkerFlags = 0;
             mInsertionMarkerHorizontal = Float.NaN;
             mInsertionMarkerTop = Float.NaN;
             mInsertionMarkerBaseline = Float.NaN;
             mInsertionMarkerBottom = Float.NaN;
             mMatrix.set(Matrix.IDENTITY_MATRIX);
             mMatrixInitialized = false;
-            if (mCharacterRectBuilder != null) {
-                mCharacterRectBuilder.reset();
+            if (mCharacterBoundsArrayBuilder != null) {
+                mCharacterBoundsArrayBuilder.reset();
             }
         }
     }
@@ -409,13 +404,13 @@
         mSelectionEnd = builder.mSelectionEnd;
         mComposingTextStart = builder.mComposingTextStart;
         mComposingText = builder.mComposingText;
-        mInsertionMarkerClipped = builder.mInsertionMarkerClipped;
+        mInsertionMarkerFlags = builder.mInsertionMarkerFlags;
         mInsertionMarkerHorizontal = builder.mInsertionMarkerHorizontal;
         mInsertionMarkerTop = builder.mInsertionMarkerTop;
         mInsertionMarkerBaseline = builder.mInsertionMarkerBaseline;
         mInsertionMarkerBottom = builder.mInsertionMarkerBottom;
-        mCharacterRects = builder.mCharacterRectBuilder != null ?
-                builder.mCharacterRectBuilder.build() : null;
+        mCharacterBoundsArray = builder.mCharacterBoundsArrayBuilder != null ?
+                builder.mCharacterBoundsArrayBuilder.build() : null;
         mMatrix = new Matrix(builder.mMatrix);
     }
 
@@ -452,11 +447,11 @@
     }
 
     /**
-     * Returns the visibility of the insertion marker.
-     * @return {@code true} if the insertion marker is partially or entirely clipped.
+     * Returns the flag of the insertion marker.
+     * @return the flag of the insertion marker. {@code 0} if no flag is specified.
      */
-    public boolean isInsertionMarkerClipped() {
-        return mInsertionMarkerClipped;
+    public int getInsertionMarkerFlags() {
+        return mInsertionMarkerFlags;
     }
 
     /**
@@ -504,38 +499,26 @@
     /**
      * Returns a new instance of {@link RectF} that indicates the location of the character
      * specified with the index.
-     * <p>
-     * Note that coordinates are not necessarily contiguous or even monotonous, especially when
-     * RTL text and LTR text are mixed.
-     * </p>
      * @param index index of the character in a Java chars.
-     * @return a new instance of {@link RectF} that represents the location of the character in
-     * local coordinates. null if the character is invisible or the application did not provide
-     * the location. Note that the {@code left} field can be greater than the {@code right} field
-     * if the character is in RTL text. Returns {@code null} if no location information is
-     * available.
+     * @return the character bounds in local coordinates as a new instance of {@link RectF}.
      */
-    // TODO: Prepare a document about the expected behavior for surrogate pairs, combining
-    // characters, and non-graphical chars.
-    public RectF getCharacterRect(final int index) {
-        if (mCharacterRects == null) {
+    public RectF getCharacterBounds(final int index) {
+        if (mCharacterBoundsArray == null) {
             return null;
         }
-        return mCharacterRects.get(index);
+        return mCharacterBoundsArray.get(index);
     }
 
     /**
-     * Returns the flags associated with the character specified with the index.
+     * Returns the flags associated with the character bounds specified with the index.
      * @param index index of the character in a Java chars.
-     * @return {@link #CHARACTER_RECT_TYPE_UNSPECIFIED} if no flag is specified.
+     * @return {@code 0} if no flag is specified.
      */
-    // TODO: Prepare a document about the expected behavior for surrogate pairs, combining
-    // characters, and non-graphical chars.
-    public int getCharacterRectFlags(final int index) {
-        if (mCharacterRects == null) {
-            return CHARACTER_RECT_TYPE_UNSPECIFIED;
+    public int getCharacterBoundsFlags(final int index) {
+        if (mCharacterBoundsArray == null) {
+            return 0;
         }
-        return mCharacterRects.getFlags(index, CHARACTER_RECT_TYPE_UNSPECIFIED);
+        return mCharacterBoundsArray.getFlags(index, 0);
     }
 
     /**
diff --git a/core/java/android/view/inputmethod/CursorAnchorInfoRequest.aidl b/core/java/android/view/inputmethod/CursorAnchorInfoRequest.aidl
deleted file mode 100644
index 41ef7cc6..0000000
--- a/core/java/android/view/inputmethod/CursorAnchorInfoRequest.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.view.inputmethod;
-
-parcelable CursorAnchorInfoRequest;
diff --git a/core/java/android/view/inputmethod/CursorAnchorInfoRequest.java b/core/java/android/view/inputmethod/CursorAnchorInfoRequest.java
deleted file mode 100644
index e4c94f2..0000000
--- a/core/java/android/view/inputmethod/CursorAnchorInfoRequest.java
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.view.inputmethod;
-
-import android.inputmethodservice.InputMethodService;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.view.View;
-
-/**
- * Used to enable or disable event notification for
- * {@link InputMethodService#onUpdateCursorAnchorInfo(CursorAnchorInfo)}. This class is also used to
- * enable {@link InputMethodService#onUpdateCursor(android.graphics.Rect)} for existing editors
- * that have not supported {@link InputMethodService#onUpdateCursorAnchorInfo(CursorAnchorInfo)}.
- */
-public final class CursorAnchorInfoRequest implements Parcelable {
-    private final int mRequestType;
-    private final int mRequestFlags;
-
-    /**
-     * Not handled by the editor.
-     */
-    public static final int RESULT_NOT_HANDLED = 0x00;
-    /**
-     * Request is scheduled in the editor task queue.
-     */
-    public static final int RESULT_SCHEDULED = 0x01;
-
-    /**
-     * The request is for {@link InputMethodService#onUpdateCursorAnchorInfo(CursorAnchorInfo)}.
-     * This mechanism is powerful enough to retrieve fine-grained positional information of
-     * characters in the editor.
-     */
-    public static final int TYPE_CURSOR_ANCHOR_INFO = 0x01;
-    /**
-     * The editor is requested to call
-     * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)}
-     * whenever cursor/anchor position is changed. To disable monitoring, call
-     * {@link InputConnection#requestCursorAnchorInfo(CursorAnchorInfoRequest)} again with
-     * {@link #TYPE_CURSOR_ANCHOR_INFO} and this flag off.
-     * <p>
-     * This flag can be used together with {@link #FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE}.
-     * </p>
-     */
-    public static final int FLAG_CURSOR_ANCHOR_INFO_MONITOR = 0x01;
-    /**
-     * The editor is requested to call
-     * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)} at
-     * once, as soon as possible, regardless of cursor/anchor position changes. This flag can be
-     * used together with {@link #FLAG_CURSOR_ANCHOR_INFO_MONITOR}.
-     */
-    public static final int FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE = 0x02;
-
-    /**
-     * The request is for {@link InputMethodService#onUpdateCursor(android.graphics.Rect)}. This
-     * mechanism has been available since API Level 3 (CUPCAKE) but only the cursor rectangle can
-     * be retrieved with this mechanism.
-     */
-    public static final int TYPE_CURSOR_RECT = 0x02;
-    /**
-     * The editor is requested to call
-     * {@link InputMethodManager#updateCursor(android.view.View, int, int, int, int)}
-     * whenever the cursor position is changed. To disable monitoring, call
-     * {@link InputConnection#requestCursorAnchorInfo(CursorAnchorInfoRequest)} again with
-     * {@link #TYPE_CURSOR_RECT} and this flag off.
-     * <p>
-     * This flag can be used together with {@link #FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES}.
-     * </p>
-     */
-    public static final int FLAG_CURSOR_RECT_MONITOR = 0x01;
-    /**
-     * {@link InputMethodManager#updateCursor(android.view.View, int, int, int, int)} should be
-     * called back in screen coordinates. To receive cursor position in local coordinates, call
-     * {@link InputConnection#requestCursorAnchorInfo(CursorAnchorInfoRequest)} again with
-     * {@link #TYPE_CURSOR_RECT} and this flag off.
-     */
-    public static final int FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES = 0x02;
-    /**
-     * {@link InputMethodManager#updateCursor(android.view.View, int, int, int, int)} should be
-     * called back in screen coordinates after coordinate conversion with {@link View#getMatrix()}.
-     * To disable coordinate conversion with {@link View#getMatrix()} again, call
-     * {@link InputConnection#requestCursorAnchorInfo(CursorAnchorInfoRequest)} with
-     * {@link #TYPE_CURSOR_RECT} and this flag off.
-     *
-     * <p>
-     * The flag is ignored if {@link #FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES} is off.
-     * </p>
-     */
-    public static final int FLAG_CURSOR_RECT_WITH_VIEW_MATRIX = 0x04;
-
-    /**
-     * Constructs the object with request type and type-specific flags.
-     *
-     * @param requestType the type of this request. Currently {@link #TYPE_CURSOR_ANCHOR_INFO} or
-     * {@link #TYPE_CURSOR_RECT} is supported.
-     * @param requestFlags the flags for the given request type.
-     */
-    public CursorAnchorInfoRequest(int requestType, int requestFlags) {
-        mRequestType = requestType;
-        mRequestFlags = requestFlags;
-    }
-
-    /**
-     * Used to make this class parcelable.
-     *
-     * @param source the parcel from which the object is unmarshalled.
-     */
-    public CursorAnchorInfoRequest(Parcel source) {
-        mRequestType = source.readInt();
-        mRequestFlags = source.readInt();
-    }
-
-    /**
-     * @return the type of this request.
-     */
-    public int getRequestType() {
-        return mRequestType;
-    }
-
-    /**
-     * @return the flags that are specific to the type of this request.
-     */
-    public int getRequestFlags() {
-        return mRequestFlags;
-    }
-
-    /**
-     * Used to package this object into a {@link Parcel}.
-     *
-     * @param dest The {@link Parcel} to be written.
-     * @param flags The flags used for parceling.
-     */
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeInt(mRequestType);
-        dest.writeInt(mRequestFlags);
-    }
-
-    @Override
-    public int hashCode(){
-        return mRequestType * 31 + mRequestFlags;
-    }
-
-    @Override
-    public boolean equals(Object obj){
-        if (obj == null) {
-            return false;
-        }
-        if (this == obj) {
-            return true;
-        }
-        if (!(obj instanceof CursorAnchorInfoRequest)) {
-            return false;
-        }
-        final CursorAnchorInfoRequest that = (CursorAnchorInfoRequest) obj;
-        if (hashCode() != that.hashCode()) {
-            return false;
-        }
-        return mRequestType != that.mRequestType && mRequestFlags == that.mRequestFlags;
-    }
-
-    @Override
-    public String toString() {
-        return "CursorAnchorInfoRequest{mRequestType=" + mRequestType
-                + " mRequestFlags=" + mRequestFlags
-                + "}";
-    }
-
-    /**
-     * Used to make this class parcelable.
-     */
-    public static final Parcelable.Creator<CursorAnchorInfoRequest> CREATOR =
-            new Parcelable.Creator<CursorAnchorInfoRequest>() {
-        @Override
-        public CursorAnchorInfoRequest createFromParcel(Parcel source) {
-            return new CursorAnchorInfoRequest(source);
-        }
-
-        @Override
-        public CursorAnchorInfoRequest[] newArray(int size) {
-            return new CursorAnchorInfoRequest[size];
-        }
-    };
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-}
diff --git a/core/java/android/view/inputmethod/InputConnection.java b/core/java/android/view/inputmethod/InputConnection.java
index dff91dc..c51d8a7 100644
--- a/core/java/android/view/inputmethod/InputConnection.java
+++ b/core/java/android/view/inputmethod/InputConnection.java
@@ -725,13 +725,35 @@
     public boolean performPrivateCommand(String action, Bundle data);
 
     /**
-     * Called by the IME to ask the editor for calling back
+     * The editor is requested to call
+     * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)} at
+     * once, as soon as possible, regardless of cursor/anchor position changes. This flag can be
+     * used together with {@link #CURSOR_UPDATE_MONITOR}.
+     */
+    public static final int CURSOR_UPDATE_IMMEDIATE = 1 << 0;
+
+    /**
+     * The editor is requested to call
+     * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)}
+     * whenever cursor/anchor position is changed. To disable monitoring, call
+     * {@link InputConnection#requestCursorUpdates(int)} again with this flag off.
+     * <p>
+     * This flag can be used together with {@link #CURSOR_UPDATE_IMMEDIATE}.
+     * </p>
+     */
+    public static final int CURSOR_UPDATE_MONITOR = 1 << 1;
+
+    /**
+     * Called by the input method to ask the editor for calling back
      * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)} to
      * notify cursor/anchor locations.
      *
-     * @param request the details of the request.
-     * @return a result code that depends on {@link CursorAnchorInfoRequest#getRequestType()}. See
-     * {@link CursorAnchorInfoRequest} for details.
+     * @param cursorUpdateMode {@link #CURSOR_UPDATE_IMMEDIATE} and/or
+     * {@link #CURSOR_UPDATE_MONITOR}. Pass {@code 0} to disable the effect of
+     * {@link #CURSOR_UPDATE_MONITOR}.
+     * @return {@code true} if the request is scheduled. {@code false} to indicate that when the
+     * application will not call
+     * {@link InputMethodManager#updateCursorAnchorInfo(android.view.View, CursorAnchorInfo)}.
      */
-    public int requestCursorAnchorInfo(CursorAnchorInfoRequest request);
+    public boolean requestCursorUpdates(int cursorUpdateMode);
 }
diff --git a/core/java/android/view/inputmethod/InputConnectionWrapper.java b/core/java/android/view/inputmethod/InputConnectionWrapper.java
index c831d7c..231aa07 100644
--- a/core/java/android/view/inputmethod/InputConnectionWrapper.java
+++ b/core/java/android/view/inputmethod/InputConnectionWrapper.java
@@ -126,7 +126,7 @@
         return mTarget.performPrivateCommand(action, data);
     }
 
-    public int requestCursorAnchorInfo(CursorAnchorInfoRequest request) {
-        return mTarget.requestCursorAnchorInfo(request);
+    public boolean requestCursorUpdates(int cursorUpdateMode) {
+        return mTarget.requestCursorUpdates(cursorUpdateMode);
     }
- }
+}
diff --git a/core/java/android/view/inputmethod/InputMethodInfo.java b/core/java/android/view/inputmethod/InputMethodInfo.java
index bc2d7ec..0a8e4b9 100644
--- a/core/java/android/view/inputmethod/InputMethodInfo.java
+++ b/core/java/android/view/inputmethod/InputMethodInfo.java
@@ -416,6 +416,9 @@
             return true;
         }
         try {
+            if (getIsDefaultResourceId() == 0) {
+                return false;
+            }
             final Resources res = context.createPackageContext(getPackageName(), 0).getResources();
             return res.getBoolean(getIsDefaultResourceId());
         } catch (NameNotFoundException e) {
diff --git a/core/java/android/view/inputmethod/InputMethodManager.java b/core/java/android/view/inputmethod/InputMethodManager.java
index eec3570..b56378f 100644
--- a/core/java/android/view/inputmethod/InputMethodManager.java
+++ b/core/java/android/view/inputmethod/InputMethodManager.java
@@ -313,9 +313,8 @@
     CompletionInfo[] mCompletions;
     
     // Cursor position on the screen.
-    Rect mNextCursorRect = new Rect();
+    Rect mTmpCursorRect = new Rect();
     Rect mCursorRect = new Rect();
-    RectF mTempRectF = new RectF();
     int mCursorSelStart;
     int mCursorSelEnd;
     int mCursorCandStart;
@@ -372,28 +371,12 @@
     InputChannel mCurChannel;
     ImeInputEventSender mCurSender;
 
-    private static final int CURSOR_RECT_MONITOR_MODE_NONE = 0x0;
-
-    private static final int CURSOR_RECT_MONITOR_FLAG_MASK =
-            CursorAnchorInfoRequest.FLAG_CURSOR_RECT_MONITOR |
-            CursorAnchorInfoRequest.FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES |
-            CursorAnchorInfoRequest.FLAG_CURSOR_RECT_WITH_VIEW_MATRIX;
-
-    private static final int CURSOR_ANCHOR_INFO_MONITOR_MODE_NONE = 0x0;
-
-    private static final int CURSOR_ANCHOR_INFO_MONITOR_FLAG_MASK =
-            CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_MONITOR |
-            CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE;
-
-    /**
-     * The monitor mode for {@link #updateCursor(View, int, int, int, int)}.
-     */
-    private int mCursorRectMonitorMode = CURSOR_RECT_MONITOR_MODE_NONE;
+    private static final int REQUEST_UPDATE_CURSOR_ANCHOR_INFO_NONE = 0x0;
 
     /**
      * The monitor mode for {@link #updateCursorAnchorInfo(View, CursorAnchorInfo)}.
      */
-    private int mCursorAnchorInfoMonitorMode = CURSOR_ANCHOR_INFO_MONITOR_MODE_NONE;
+    private int mRequestUpdateCursorAnchorInfoMonitorMode = REQUEST_UPDATE_CURSOR_ANCHOR_INFO_NONE;
 
     final Pool<PendingEvent> mPendingEventPool = new SimplePool<PendingEvent>(20);
     final SparseArray<PendingEvent> mPendingEvents = new SparseArray<PendingEvent>(20);
@@ -446,8 +429,8 @@
                             return;
                         }
 
-                        mCursorAnchorInfoMonitorMode = CURSOR_ANCHOR_INFO_MONITOR_MODE_NONE;
-                        mCursorRectMonitorMode = CURSOR_RECT_MONITOR_MODE_NONE;
+                        mRequestUpdateCursorAnchorInfoMonitorMode =
+                                REQUEST_UPDATE_CURSOR_ANCHOR_INFO_NONE;
 
                         setInputChannelLocked(res.channel);
                         mCurMethod = res.method;
@@ -1540,59 +1523,49 @@
     }
 
     /**
-     * Returns true if the current input method wants to watch the location
+     * Return true if the current input method wants to watch the location
      * of the input editor's cursor in its window.
-     */
-    public boolean isWatchingCursor(View view) {
-        if (!isActive(view)) {
-            return false;
-        }
-        synchronized (mH) {
-            return (mCursorRectMonitorMode & CursorAnchorInfoRequest.FLAG_CURSOR_RECT_MONITOR) != 0;
-        }
-    }
-
-    /**
-     * Updates the result of {@link #isWatchingCursor(View)}.
      *
-     * @hide
+     * @deprecated Use {@link InputConnection#requestCursorUpdates(int)} instead.
      */
-    public void setCursorRectMonitorMode(int flags) {
-        synchronized (mH) {
-            mCursorRectMonitorMode = (CURSOR_RECT_MONITOR_FLAG_MASK & flags);
-        }
+    @Deprecated
+    public boolean isWatchingCursor(View view) {
+        return false;
     }
 
     /**
-     * Returns true if the current input method wants to be notified when cursor/anchor location
+     * Return true if the current input method wants to be notified when cursor/anchor location
      * is changed.
      *
      * @hide
      */
     public boolean isCursorAnchorInfoEnabled() {
         synchronized (mH) {
-            final boolean isImmediate = (mCursorAnchorInfoMonitorMode &
-                    CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE) != 0;
-            final boolean isMonitoring = (mCursorAnchorInfoMonitorMode &
-                    CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_MONITOR) != 0;
+            final boolean isImmediate = (mRequestUpdateCursorAnchorInfoMonitorMode &
+                    InputConnection.CURSOR_UPDATE_IMMEDIATE) != 0;
+            final boolean isMonitoring = (mRequestUpdateCursorAnchorInfoMonitorMode &
+                    InputConnection.CURSOR_UPDATE_MONITOR) != 0;
             return isImmediate || isMonitoring;
         }
     }
 
     /**
-     * Updates the result of {@link #isWatchingCursor(View)}.
+     * Set the requested mode for {@link #updateCursorAnchorInfo(View, CursorAnchorInfo)}.
      *
      * @hide
      */
-    public void setCursorAnchorInfoMonitorMode(int flags) {
+    public void setUpdateCursorAnchorInfoMode(int flags) {
         synchronized (mH) {
-            mCursorAnchorInfoMonitorMode = (CURSOR_ANCHOR_INFO_MONITOR_FLAG_MASK & flags);
+            mRequestUpdateCursorAnchorInfoMonitorMode = flags;
         }
     }
 
     /**
      * Report the current cursor location in its window.
+     *
+     * @deprecated Use {@link #updateCursorAnchorInfo(View, CursorAnchorInfo)} instead.
      */
+    @Deprecated
     public void updateCursor(View view, int left, int top, int right, int bottom) {
         checkFocus();
         synchronized (mH) {
@@ -1601,33 +1574,15 @@
                     || mCurrentTextBoxAttribute == null || mCurMethod == null) {
                 return;
             }
-            if (DEBUG) Log.d(TAG, "updateCursor");
-            final boolean usesScreenCoordinates = (mCursorRectMonitorMode &
-                    CursorAnchorInfoRequest.FLAG_CURSOR_RECT_IN_SCREEN_COORDINATES) != 0;
-            if (usesScreenCoordinates) {
-                view.getLocationOnScreen(mViewTopLeft);
-                final Matrix viewMatrix = view.getMatrix();
-                final boolean usesViewMatrix = (viewMatrix != null) && ((mCursorRectMonitorMode &
-                        CursorAnchorInfoRequest.FLAG_CURSOR_RECT_WITH_VIEW_MATRIX) != 0);
-                if (usesViewMatrix) {
-                    mTempRectF.set(left, top, right, bottom);
-                    mViewToScreenMatrix.set(viewMatrix);
-                    mViewToScreenMatrix.postTranslate(mViewTopLeft[0], mViewTopLeft[1]);
-                    mViewToScreenMatrix.mapRect(mTempRectF);
-                    mNextCursorRect.set((int)mTempRectF.left, (int)mTempRectF.top,
-                            (int)mTempRectF.right, (int)mTempRectF.bottom);
-                } else {
-                    mNextCursorRect.set(left + mViewTopLeft[0], top + mViewTopLeft[1],
-                            right + mViewTopLeft[0], bottom + mViewTopLeft[1]);
-                }
-            } else {
-                mNextCursorRect.set(left, top, right, bottom);
-            }
-            if (!Objects.equals(mCursorRect, mNextCursorRect)) {
-                if (DEBUG) Log.v(TAG, "CURSOR CHANGE: " + mNextCursorRect);
+
+            mTmpCursorRect.set(left, top, right, bottom);
+            if (!mCursorRect.equals(mTmpCursorRect)) {
+                if (DEBUG) Log.d(TAG, "updateCursor");
+
                 try {
-                    mCurMethod.updateCursor(mNextCursorRect);
-                    mCursorRect.set(mNextCursorRect);
+                    if (DEBUG) Log.v(TAG, "CURSOR CHANGE: " + mCurMethod);
+                    mCurMethod.updateCursor(mTmpCursorRect);
+                    mCursorRect.set(mTmpCursorRect);
                 } catch (RemoteException e) {
                     Log.w(TAG, "IME died: " + mCurId, e);
                 }
@@ -1652,8 +1607,8 @@
             }
             // If immediate bit is set, we will call updateCursorAnchorInfo() even when the data has
             // not been changed from the previous call.
-            final boolean isImmediate = (mCursorAnchorInfoMonitorMode &
-                    CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE) != 0;
+            final boolean isImmediate = (mRequestUpdateCursorAnchorInfoMonitorMode &
+                    InputConnection.CURSOR_UPDATE_IMMEDIATE) != 0;
             if (!isImmediate && Objects.equals(mCursorAnchorInfo, cursorAnchorInfo)) {
                 // TODO: Consider always emitting this message once we have addressed redundant
                 // calls of this method from android.widget.Editor.
@@ -1668,8 +1623,8 @@
                 mCurMethod.updateCursorAnchorInfo(cursorAnchorInfo);
                 mCursorAnchorInfo = cursorAnchorInfo;
                 // Clear immediate bit (if any).
-                mCursorAnchorInfoMonitorMode &=
-                        ~CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE;
+                mRequestUpdateCursorAnchorInfoMonitorMode &=
+                        ~InputConnection.CURSOR_UPDATE_IMMEDIATE;
             } catch (RemoteException e) {
                 Log.w(TAG, "IME died: " + mCurId, e);
             }
diff --git a/core/java/android/view/inputmethod/InputMethodSubtype.java b/core/java/android/view/inputmethod/InputMethodSubtype.java
index e7ada27..1671faa 100644
--- a/core/java/android/view/inputmethod/InputMethodSubtype.java
+++ b/core/java/android/view/inputmethod/InputMethodSubtype.java
@@ -211,18 +211,6 @@
      }
 
     /**
-     * Constructor with no subtype ID specified, overridesImplicitlyEnabledSubtype not specified.
-     * Arguments for this constructor have the same meanings as
-     * {@link InputMethodSubtype#InputMethodSubtype(int, int, String, String, String, boolean,
-     * boolean, int)} except "id" and "overridesImplicitlyEnabledSubtype".
-     * @hide
-     */
-    public InputMethodSubtype(int nameId, int iconId, String locale, String mode, String extraValue,
-            boolean isAuxiliary) {
-        this(nameId, iconId, locale, mode, extraValue, isAuxiliary, false);
-    }
-
-    /**
      * Constructor with no subtype ID specified.
      * @deprecated use {@link InputMethodSubtypeBuilder} instead.
      * Arguments for this constructor have the same meanings as
diff --git a/core/java/android/webkit/CookieManager.java b/core/java/android/webkit/CookieManager.java
index 7c30d2a..de7d2d0 100644
--- a/core/java/android/webkit/CookieManager.java
+++ b/core/java/android/webkit/CookieManager.java
@@ -98,7 +98,7 @@
      * @param webview the {@link WebView} instance to get the cookie policy for
      * @return true if the {@link WebView} accepts third party cookies
      */
-    public synchronized boolean acceptThirdPartyCookies(WebView webview) {
+    public boolean acceptThirdPartyCookies(WebView webview) {
         throw new MustOverrideException();
     }
 
diff --git a/core/java/android/webkit/PermissionRequest.java b/core/java/android/webkit/PermissionRequest.java
index 862e8c2..6ad639c 100644
--- a/core/java/android/webkit/PermissionRequest.java
+++ b/core/java/android/webkit/PermissionRequest.java
@@ -19,8 +19,10 @@
 import android.net.Uri;
 
 /**
- * This interface defines a permission request and is used when web content
- * requests access to protected resources.
+ * This class defines a permission request and is used when web content
+ * requests access to protected resources. The permission request related events
+ * are delivered via {@link WebChromeClient#onPermissionRequest} and
+ * {@link WebChromeClient#onPermissionRequestCanceled}.
  *
  * Either {@link #grant(String[]) grant()} or {@link #deny()} must be called in UI
  * thread to respond to the request.
diff --git a/core/java/android/webkit/WebChromeClient.java b/core/java/android/webkit/WebChromeClient.java
index 35c9598..46a7fd0 100644
--- a/core/java/android/webkit/WebChromeClient.java
+++ b/core/java/android/webkit/WebChromeClient.java
@@ -416,57 +416,33 @@
     }
 
     /**
-     * UploadHelper simplifies file upload operations by providing helper methods that
-     * would handle most common file picker/media capture requests. The application
-     * can use the helper to build an intent to start a file picker, and then parse
-     * the result returned by the activity.
-     *
-     * How to use:
-     * 1. Create a helper using {@link FileChooserParams#getUploadHelper}
-     * 2. Build an intent using {@link UploadHelper#buildIntent}
-     * 3. Fire the intent using {@link android.app.Activity#startActivityForResult}.
-     * 4. Check for ActivityNotFoundException and take a user friendly action if thrown.
-     * 5. Listen the result using {@link android.app.Activity#onActivityResult}
-     * 6. Parse the result using {@link UploadHelper#parseResult}
-     * 7. Send the result using filePathCallback of {@link WebChromeClient#onShowFileChooser}
+     * Parameters used in the {@link #onShowFileChooser} method.
      */
-    public static abstract class UploadHelper {
-        /**
-         * Returns an intent that would start a file picker for file selection/media capture.
-         */
-        public abstract Intent buildIntent();
+    public static abstract class FileChooserParams {
+        /** Open single file. Requires that the file exists before allowing the user to pick it. */
+        public static final int MODE_OPEN = 0;
+        /** Like Open but allows multiple files to be selected. */
+        public static final int MODE_OPEN_MULTIPLE = 1;
+        /** Like Open but allows a folder to be selected. The implementation should enumerate
+            all files selected by this operation.
+            This feature is not supported at the moment.
+            @hide */
+        public static final int MODE_OPEN_FOLDER = 2;
+        /**  Allows picking a nonexistent file and saving it. */
+        public static final int MODE_SAVE = 3;
 
         /**
-         * Parses the result returned by the file picker activity.
+         * Parse the result returned by the file picker activity. This method should be used with
+         * {@link #createIntent}. Refer to {@link #createIntent} for how to use it.
          *
          * @param resultCode the integer result code returned by the file picker activity.
          * @param data the intent returned by the file picker activity.
          * @return the Uris of selected file(s) or null if the resultCode indicates
          *         activity canceled or any other error.
          */
-        public abstract Uri[] parseResult(int resultCode, Intent data);
-    }
-
-    /**
-     * Parameters used in the {@link #onShowFileChooser} method.
-     */
-    public static abstract class FileChooserParams {
-        /** Open single file. Requires that the file exists before allowing the user to pick it. */
-        public static final int OPEN = 0;
-        /** Like Open but allows multiple files to be selected. */
-        public static final int OPEN_MULTIPLE = 1;
-        /** Like Open but allows a folder to be selected. The implementation should enumerate
-            all files selected by this operation. */
-        public static final int OPEN_FOLDER = 2;
-        /**  Allows picking a nonexistent file and saving it. */
-        public static final int SAVE = 3;
-
-        /**
-         * Returns a helper to simplify choosing and uploading files. The helper builds a default
-         * intent that the application can send using startActivityForResult and processes the
-         * results.
-         */
-        public abstract UploadHelper getUploadHelper();
+        public static Uri[] parseResult(int resultCode, Intent data) {
+            return WebViewFactory.getProvider().getStatics().parseFileChooserResult(resultCode, data);
+        }
 
         /**
          * Returns file chooser mode.
@@ -474,7 +450,8 @@
         public abstract int getMode();
 
         /**
-         * Returns an array of acceptable MIME types. The array will be empty if no
+         * Returns an array of acceptable MIME types. The returned MIME type
+         * could be partial such as audio/*. The array will be empty if no
          * acceptable types are specified.
          */
         public abstract String[] getAcceptTypes();
@@ -494,10 +471,31 @@
         public abstract CharSequence getTitle();
 
         /**
-         * The file path of a default selection if specified, or null.
+         * The file name of a default selection if specified, or null.
          */
-        public abstract String getDefaultFilename();
-    };
+        public abstract String getFilenameHint();
+
+        /**
+         * Creates an intent that would start a file picker for file selection.
+         * The Intent supports choosing files from simple file sources available
+         * on the device. Some advanced sources (for example, live media capture)
+         * may not be supported and applications wishing to support these sources
+         * or more advanced file operations should build their own Intent.
+         *
+         * <pre>
+         * How to use:
+         * 1. Build an intent using {@link #createIntent}
+         * 2. Fire the intent using {@link android.app.Activity#startActivityForResult}.
+         * 3. Check for ActivityNotFoundException and take a user friendly action if thrown.
+         * 4. Listen the result using {@link android.app.Activity#onActivityResult}
+         * 5. Parse the result using {@link #parseResult} only if media capture was not requested.
+         * 6. Send the result using filePathCallback of {@link WebChromeClient#onShowFileChooser}
+         * </pre>
+         *
+         * @return an Intent that supports basic file chooser sources.
+         */
+        public abstract Intent createIntent();
+    }
 
     /**
      * Tell the client to open a file chooser.
diff --git a/core/java/android/webkit/WebResourceRequest.java b/core/java/android/webkit/WebResourceRequest.java
index dc7c808..2185658de3 100644
--- a/core/java/android/webkit/WebResourceRequest.java
+++ b/core/java/android/webkit/WebResourceRequest.java
@@ -41,15 +41,11 @@
     boolean isForMainFrame();
 
     /**
-     * Gets whether a gesture was associated with the request.
-     * <p>
-     * <strong>IMPORTANT:</strong>
-     * This should not be used to implement any form of security. It is possible for the content
-     * to spoof this.
+     * Gets whether a gesture (such as a click) was associated with the request.
      *
      * @return whether a gesture was associated with the request.
      */
-    boolean hasUserGestureInsecure();
+    boolean hasGesture();
 
     /**
      * Gets the method associated with the request, for example "GET".
diff --git a/core/java/android/webkit/WebView.java b/core/java/android/webkit/WebView.java
index 1b0cb3d..081bfdf 100644
--- a/core/java/android/webkit/WebView.java
+++ b/core/java/android/webkit/WebView.java
@@ -1624,10 +1624,18 @@
     }
 
     /**
-     * Enable drawing the entire HTML document at a significant performance
-     * cost. Call this to enable drawing and capturing HTML content outside of
-     * the WebView's viewport. This should be called before any WebViews are
-     * created.
+     * For apps targeting the L release, WebView has a new default behavior that reduces
+     * memory footprint and increases performance by intelligently choosing
+     * the portion of the HTML document that needs to be drawn. These
+     * optimizations are transparent to the developers. However, under certain
+     * circumstances, an App developer may want to disable them:
+     * 1. When an app uses {@link #onDraw} to do own drawing and accesses portions
+     * of the page that is way outside the visible portion of the page.
+     * 2. When an app uses {@link #capturePicture} to capture a very large HTML document.
+     * Note that capturePicture is a deprecated API.
+     *
+     * Enabling drawing the entire HTML document has a significant performance
+     * cost. This method should be called before any WebViews are created.
      */
     public static void enableSlowWholeDocumentDraw() {
         getFactory().getStatics().enableSlowWholeDocumentDraw();
@@ -1802,21 +1810,6 @@
     }
 
     /**
-     * Sets whether the application wants to opt out from using the Data Reduction Proxy
-     * service.
-     * Data reduction proxy can only be enabled by the user and will almost always be
-     * transparent to the application. In rare cases where using the proxy interferes
-     * with the app, the application developer can use this API to opt out from using the
-     * proxy. Note that this may increase network bandwidth usage.
-     *
-     * See <a href=http://developer.chrome.com/multidevice/data-compression>
-     * Data Compression Proxy</a>
-     */
-    public static void optOutDataReductionProxy() {
-        getFactory().getStatics().optOutDataReductionProxy();
-    }
-
-    /**
      * Gets the list of currently loaded plugins.
      *
      * @return the list of currently loaded plugins
@@ -1946,16 +1939,14 @@
      *
      * @param zoomFactor the zoom factor to apply. The zoom factor will be clamped to the Webview's
      * zoom limits. This value must be in the range 0.01 to 100.0 inclusive.
-     *
-     * @return false if no zoom changes, true otherwise.
      */
-    public boolean zoomBy(float zoomFactor) {
+    public void zoomBy(float zoomFactor) {
         checkThread();
         if (zoomFactor < 0.01)
             throw new IllegalArgumentException("zoomFactor must be greater than 0.01.");
         if (zoomFactor > 100.0)
             throw new IllegalArgumentException("zoomFactor must be less than 100.");
-        return mProvider.zoomBy(zoomFactor);
+        mProvider.zoomBy(zoomFactor);
     }
 
     /**
diff --git a/core/java/android/webkit/WebViewFactoryProvider.java b/core/java/android/webkit/WebViewFactoryProvider.java
index 48f3ca3..d37d217 100644
--- a/core/java/android/webkit/WebViewFactoryProvider.java
+++ b/core/java/android/webkit/WebViewFactoryProvider.java
@@ -17,6 +17,8 @@
 package android.webkit;
 
 import android.content.Context;
+import android.content.Intent;
+import android.net.Uri;
 
 /**
  * This is the main entry-point into the WebView back end implementations, which the WebView
@@ -61,15 +63,15 @@
 
         /**
          * Implements the API method:
-         * {@link android.webkit.WebView#optOutDataReductionProxy() }
-         */
-        void optOutDataReductionProxy();
-
-        /**
-         * Implements the API method:
          * {@link android.webkit.WebView#setSlowWholeDocumentDrawEnabled(boolean) }
          */
         void enableSlowWholeDocumentDraw();
+
+        /**
+         * Implement the API method
+         * {@link android.webkit.WebChromeClient.FileChooserParams#parseResult(int, Intent)}
+         */
+        Uri[] parseFileChooserResult(int resultCode, Intent intent);
     }
 
     Statics getStatics();
diff --git a/core/java/android/widget/AbsListView.java b/core/java/android/widget/AbsListView.java
index 60ef693..af53ec8 100644
--- a/core/java/android/widget/AbsListView.java
+++ b/core/java/android/widget/AbsListView.java
@@ -65,7 +65,6 @@
 import android.view.inputmethod.BaseInputConnection;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CorrectionInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.ExtractedText;
 import android.view.inputmethod.ExtractedTextRequest;
@@ -3324,10 +3323,11 @@
         if (mLastY == Integer.MIN_VALUE) {
             rawDeltaY -= mMotionCorrection;
         }
-        if (dispatchNestedPreScroll(0, -rawDeltaY, mScrollConsumed, mScrollOffset)) {
+        if (dispatchNestedPreScroll(0, mLastY != Integer.MIN_VALUE ? mLastY - y : -rawDeltaY,
+                mScrollConsumed, mScrollOffset)) {
             rawDeltaY += mScrollConsumed[1];
-            scrollOffsetCorrection -= mScrollOffset[1];
-            scrollConsumedCorrection -= mScrollConsumed[1];
+            scrollOffsetCorrection = -mScrollOffset[1];
+            scrollConsumedCorrection = mScrollConsumed[1];
             if (vtev != null) {
                 vtev.offsetLocation(0, mScrollOffset[1]);
             }
@@ -3438,7 +3438,7 @@
                             }
                         }
                     }
-                    mMotionY = y + scrollOffsetCorrection;
+                    mMotionY = y + lastYCorrection + scrollOffsetCorrection;
                 }
                 mLastY = y + lastYCorrection + scrollOffsetCorrection;
             }
@@ -3506,10 +3506,10 @@
                     mMotionCorrection = 0;
                     View motionView = getChildAt(motionPosition - mFirstPosition);
                     mMotionViewOriginalTop = motionView != null ? motionView.getTop() : 0;
-                    mMotionY = y;
+                    mMotionY =  y + scrollOffsetCorrection;
                     mMotionPosition = motionPosition;
                 }
-                mLastY = y;
+                mLastY = y + lastYCorrection + scrollOffsetCorrection;
                 mDirection = newDirection;
             }
         }
@@ -3877,7 +3877,7 @@
                         if (mPositionScroller != null) {
                             mPositionScroller.stop();
                         }
-                        if (flingVelocity) {
+                        if (flingVelocity && !dispatchNestedPreFling(0, -initialVelocity)) {
                             dispatchNestedFling(0, -initialVelocity, false);
                         }
                     }
@@ -4002,14 +4002,15 @@
      * <p>Applications can use this method to manually initiate a fling as if the user
      * initiated it via touch interaction.</p>
      *
-     * @param velocityY Vertical velocity in pixels per second
+     * @param velocityY Vertical velocity in pixels per second. Note that this is velocity of
+     *                  content, not velocity of a touch that initiated the fling.
      */
     public void fling(int velocityY) {
         if (mFlingRunnable == null) {
             mFlingRunnable = new FlingRunnable();
         }
         reportScrollStateChange(OnScrollListener.SCROLL_STATE_FLING);
-        mFlingRunnable.start(-velocityY);
+        mFlingRunnable.start(velocityY);
     }
 
     @Override
@@ -5718,8 +5719,8 @@
         }
 
         @Override
-        public int requestCursorAnchorInfo(CursorAnchorInfoRequest request) {
-            return getTarget().requestCursorAnchorInfo(request);
+        public boolean requestCursorUpdates(int cursorUpdateMode) {
+            return getTarget().requestCursorUpdates(cursorUpdateMode);
         }
     }
 
diff --git a/core/java/android/widget/AbsSeekBar.java b/core/java/android/widget/AbsSeekBar.java
index 39cd7e3..b2cfdf7 100644
--- a/core/java/android/widget/AbsSeekBar.java
+++ b/core/java/android/widget/AbsSeekBar.java
@@ -42,8 +42,9 @@
 
     private Drawable mThumb;
     private ColorStateList mThumbTintList = null;
-    private PorterDuff.Mode mThumbTintMode = PorterDuff.Mode.SRC_ATOP;
+    private PorterDuff.Mode mThumbTintMode = null;
     private boolean mHasThumbTint = false;
+    private boolean mHasThumbTintMode = false;
 
     private int mThumbOffset;
     private boolean mSplitTrack;
@@ -96,14 +97,15 @@
         final Drawable thumb = a.getDrawable(com.android.internal.R.styleable.SeekBar_thumb);
         setThumb(thumb);
 
-        mThumbTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.SeekBar_thumbTintMode, -1), mThumbTintMode);
+        if (a.hasValue(R.styleable.SeekBar_thumbTintMode)) {
+            mThumbTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.SeekBar_thumbTintMode, -1), mThumbTintMode);
+            mHasThumbTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.SeekBar_thumbTint)) {
             mThumbTintList = a.getColorStateList(R.styleable.SeekBar_thumbTint);
             mHasThumbTint = true;
-
-            applyThumbTint();
         }
 
         // Guess thumb offset if thumb != null, but allow layout to override.
@@ -119,6 +121,8 @@
         mDisabledAlpha = a.getFloat(com.android.internal.R.styleable.Theme_disabledAlpha, 0.5f);
         a.recycle();
 
+        applyThumbTint();
+
         mScaledTouchSlop = ViewConfiguration.get(context).getScaledTouchSlop();
     }
 
@@ -189,7 +193,7 @@
 
     /**
      * Applies a tint to the thumb drawable. Does not modify the current tint
-     * mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setThumb(Drawable)} will automatically
      * mutate the drawable and apply the specified tint and tint mode using
@@ -209,6 +213,8 @@
     }
 
     /**
+     * Returns the tint applied to the thumb drawable, if specified.
+     *
      * @return the tint applied to the thumb drawable
      * @attr ref android.R.styleable#SeekBar_thumbTint
      * @see #setThumbTintList(ColorStateList)
@@ -221,7 +227,7 @@
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setThumbTintList(ColorStateList)}} to the thumb drawable. The
-     * default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -232,11 +238,15 @@
      */
     public void setThumbTintMode(@Nullable PorterDuff.Mode tintMode) {
         mThumbTintMode = tintMode;
+        mHasThumbTintMode = true;
 
         applyThumbTint();
     }
 
     /**
+     * Returns the blending mode used to apply the tint to the thumb drawable,
+     * if specified.
+     *
      * @return the blending mode used to apply the tint to the thumb drawable
      * @attr ref android.R.styleable#SeekBar_thumbTintMode
      * @see #setThumbTintMode(PorterDuff.Mode)
@@ -247,10 +257,16 @@
     }
 
     private void applyThumbTint() {
-        if (mThumb != null && mHasThumbTint) {
+        if (mThumb != null && (mHasThumbTint || mHasThumbTintMode)) {
             mThumb = mThumb.mutate();
-            mThumb.setTintList(mThumbTintList);
-            mThumb.setTintMode(mThumbTintMode);
+
+            if (mHasThumbTint) {
+                mThumb.setTintList(mThumbTintList);
+            }
+
+            if (mHasThumbTintMode) {
+                mThumb.setTintMode(mThumbTintMode);
+            }
         }
     }
 
diff --git a/core/java/android/widget/ActionMenuPresenter.java b/core/java/android/widget/ActionMenuPresenter.java
index 7123b9a..d779124 100644
--- a/core/java/android/widget/ActionMenuPresenter.java
+++ b/core/java/android/widget/ActionMenuPresenter.java
@@ -19,6 +19,9 @@
 import android.content.Context;
 import android.content.res.Configuration;
 import android.content.res.Resources;
+import android.graphics.Matrix;
+import android.graphics.Rect;
+import android.graphics.drawable.Drawable;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.util.SparseBooleanArray;
@@ -580,6 +583,8 @@
     }
 
     private class OverflowMenuButton extends ImageButton implements ActionMenuView.ActionMenuChildView {
+        private final float[] mTempPts = new float[2];
+
         public OverflowMenuButton(Context context) {
             super(context, null, com.android.internal.R.attr.actionOverflowButtonStyle);
 
@@ -645,6 +650,24 @@
             super.onInitializeAccessibilityNodeInfo(info);
             info.setCanOpenPopup(true);
         }
+
+        @Override
+        protected boolean setFrame(int l, int t, int r, int b) {
+            final boolean changed = super.setFrame(l, t, r, b);
+
+            // Set up the hotspot bounds to be centered on the image.
+            final Drawable d = getDrawable();
+            final Drawable bg = getBackground();
+            if (d != null && bg != null) {
+                final float[] pts = mTempPts;
+                pts[0] = d.getBounds().centerX();
+                getImageMatrix().mapPoints(pts);
+                final int offset =  (int) pts[0] - getWidth() / 2;
+                bg.setHotspotBounds(offset, 0, getWidth() + offset, getHeight());
+            }
+
+            return changed;
+        }
     }
 
     private class OverflowPopup extends MenuPopupHelper {
diff --git a/core/java/android/widget/ActionMenuView.java b/core/java/android/widget/ActionMenuView.java
index 96abf51..7198e52 100644
--- a/core/java/android/widget/ActionMenuView.java
+++ b/core/java/android/widget/ActionMenuView.java
@@ -29,6 +29,7 @@
 import com.android.internal.view.menu.ActionMenuItemView;
 import com.android.internal.view.menu.MenuBuilder;
 import com.android.internal.view.menu.MenuItemImpl;
+import com.android.internal.view.menu.MenuPresenter;
 import com.android.internal.view.menu.MenuView;
 
 /**
@@ -53,6 +54,8 @@
 
     private boolean mReserveOverflow;
     private ActionMenuPresenter mPresenter;
+    private MenuPresenter.Callback mActionMenuPresenterCallback;
+    private MenuBuilder.Callback mMenuBuilderCallback;
     private boolean mFormatItems;
     private int mFormatItemsWidth;
     private int mMinCellSize;
@@ -608,7 +611,9 @@
             mMenu = new MenuBuilder(context);
             mMenu.setCallback(new MenuBuilderCallback());
             mPresenter = new ActionMenuPresenter(context);
-            mPresenter.setCallback(new ActionMenuPresenterCallback());
+            mPresenter.setReserveOverflow(true);
+            mPresenter.setCallback(mActionMenuPresenterCallback != null
+                    ? mActionMenuPresenterCallback : new ActionMenuPresenterCallback());
             mMenu.addMenuPresenter(mPresenter, mPopupContext);
             mPresenter.setMenuView(this);
         }
@@ -617,6 +622,15 @@
     }
 
     /**
+     * Must be called before the first call to getMenu()
+     * @hide
+     */
+    public void setMenuCallbacks(MenuPresenter.Callback pcb, MenuBuilder.Callback mcb) {
+        mActionMenuPresenterCallback = pcb;
+        mMenuBuilderCallback = mcb;
+    }
+
+    /**
      * Returns the current menu or null if one has not yet been configured.
      * @hide Internal use only for action bar integration
      */
@@ -719,6 +733,9 @@
 
         @Override
         public void onMenuModeChange(MenuBuilder menu) {
+            if (mMenuBuilderCallback != null) {
+                mMenuBuilderCallback.onMenuModeChange(menu);
+            }
         }
     }
 
diff --git a/core/java/android/widget/AdapterView.java b/core/java/android/widget/AdapterView.java
index 1da22ca..b9f891c 100644
--- a/core/java/android/widget/AdapterView.java
+++ b/core/java/android/widget/AdapterView.java
@@ -297,10 +297,10 @@
     public boolean performItemClick(View view, int position, long id) {
         if (mOnItemClickListener != null) {
             playSoundEffect(SoundEffectConstants.CLICK);
+            mOnItemClickListener.onItemClick(this, view, position, id);
             if (view != null) {
                 view.sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_CLICKED);
             }
-            mOnItemClickListener.onItemClick(this, view, position, id);
             return true;
         }
 
diff --git a/core/java/android/widget/AutoCompleteTextView.java b/core/java/android/widget/AutoCompleteTextView.java
index eb232fd..3b16aba 100644
--- a/core/java/android/widget/AutoCompleteTextView.java
+++ b/core/java/android/widget/AutoCompleteTextView.java
@@ -35,9 +35,8 @@
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.InputMethodManager;
-
 import com.android.internal.R;
-
+import java.lang.ref.WeakReference;
 
 /**
  * <p>An editable text view that shows completion suggestions automatically
@@ -85,8 +84,8 @@
  * @attr ref android.R.styleable#AutoCompleteTextView_dropDownAnchor
  * @attr ref android.R.styleable#AutoCompleteTextView_dropDownWidth
  * @attr ref android.R.styleable#AutoCompleteTextView_dropDownHeight
- * @attr ref android.R.styleable#AutoCompleteTextView_dropDownVerticalOffset
- * @attr ref android.R.styleable#AutoCompleteTextView_dropDownHorizontalOffset
+ * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
+ * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
  */
 public class AutoCompleteTextView extends EditText implements Filter.FilterListener {
     static final boolean DEBUG = false;
@@ -130,7 +129,7 @@
     }
 
     public AutoCompleteTextView(Context context, AttributeSet attrs) {
-        this(context, attrs, com.android.internal.R.attr.autoCompleteTextViewStyle);
+        this(context, attrs, R.attr.autoCompleteTextViewStyle);
     }
 
     public AutoCompleteTextView(Context context, AttributeSet attrs, int defStyleAttr) {
@@ -141,23 +140,17 @@
             Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
         super(context, attrs, defStyleAttr, defStyleRes);
 
-        mPopup = new ListPopupWindow(context, attrs,
-                com.android.internal.R.attr.autoCompleteTextViewStyle);
+        mPopup = new ListPopupWindow(context, attrs, defStyleAttr, defStyleRes);
         mPopup.setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_ADJUST_RESIZE);
         mPopup.setPromptPosition(ListPopupWindow.POSITION_PROMPT_BELOW);
 
-        final TypedArray a = context.obtainStyledAttributes(attrs,
-                com.android.internal.R.styleable.AutoCompleteTextView, defStyleAttr, defStyleRes);
+        final TypedArray a = context.obtainStyledAttributes(
+                attrs, R.styleable.AutoCompleteTextView, defStyleAttr, defStyleRes);
 
-        mThreshold = a.getInt(
-                R.styleable.AutoCompleteTextView_completionThreshold, 2);
+        mThreshold = a.getInt(R.styleable.AutoCompleteTextView_completionThreshold, 2);
 
         mPopup.setListSelector(a.getDrawable(R.styleable.AutoCompleteTextView_dropDownSelector));
-        mPopup.setVerticalOffset((int)
-                a.getDimension(R.styleable.AutoCompleteTextView_dropDownVerticalOffset, 0.0f));
-        mPopup.setHorizontalOffset((int)
-                a.getDimension(R.styleable.AutoCompleteTextView_dropDownHorizontalOffset, 0.0f));
-        
+
         // Get the anchor's id now, but the view won't be ready, so wait to actually get the
         // view and store it in mDropDownAnchorView lazily in getDropDownAnchorView later.
         // Defaults to NO_ID, in which case the getDropDownAnchorView method will simply return
@@ -167,11 +160,9 @@
         
         // For dropdown width, the developer can specify a specific width, or MATCH_PARENT
         // (for full screen width) or WRAP_CONTENT (to match the width of the anchored view).
-        mPopup.setWidth(a.getLayoutDimension(
-                R.styleable.AutoCompleteTextView_dropDownWidth,
+        mPopup.setWidth(a.getLayoutDimension(R.styleable.AutoCompleteTextView_dropDownWidth,
                 ViewGroup.LayoutParams.WRAP_CONTENT));
-        mPopup.setHeight(a.getLayoutDimension(
-                R.styleable.AutoCompleteTextView_dropDownHeight,
+        mPopup.setHeight(a.getLayoutDimension(R.styleable.AutoCompleteTextView_dropDownHeight,
                 ViewGroup.LayoutParams.WRAP_CONTENT));
 
         mHintResource = a.getResourceId(R.styleable.AutoCompleteTextView_completionHintView,
@@ -373,6 +364,8 @@
      * <p>Sets the vertical offset used for the auto-complete drop-down list.</p>
      * 
      * @param offset the vertical offset
+     *
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
      */
     public void setDropDownVerticalOffset(int offset) {
         mPopup.setVerticalOffset(offset);
@@ -382,6 +375,8 @@
      * <p>Gets the vertical offset used for the auto-complete drop-down list.</p>
      * 
      * @return the vertical offset
+     *
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
      */
     public int getDropDownVerticalOffset() {
         return mPopup.getVerticalOffset();
@@ -391,6 +386,8 @@
      * <p>Sets the horizontal offset used for the auto-complete drop-down list.</p>
      * 
      * @param offset the horizontal offset
+     *
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
      */
     public void setDropDownHorizontalOffset(int offset) {
         mPopup.setHorizontalOffset(offset);
@@ -400,6 +397,8 @@
      * <p>Gets the horizontal offset used for the auto-complete drop-down list.</p>
      * 
      * @return the horizontal offset
+     *
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
      */
     public int getDropDownHorizontalOffset() {
         return mPopup.getHorizontalOffset();
@@ -629,7 +628,7 @@
      */
     public <T extends ListAdapter & Filterable> void setAdapter(T adapter) {
         if (mObserver == null) {
-            mObserver = new PopupDataSetObserver();
+            mObserver = new PopupDataSetObserver(this);
         } else if (mAdapter != null) {
             mAdapter.unregisterDataSetObserver(mObserver);
         }
@@ -1255,25 +1254,44 @@
         }
     }
 
-    private class PopupDataSetObserver extends DataSetObserver {
+    /**
+     * Static inner listener that keeps a WeakReference to the actual AutoCompleteTextView.
+     * <p>
+     * This way, if adapter has a longer life span than the View, we won't leak the View, instead
+     * we will just leak a small Observer with 1 field.
+     */
+    private static class PopupDataSetObserver extends DataSetObserver {
+        private final WeakReference<AutoCompleteTextView> mViewReference;
+
+        private PopupDataSetObserver(AutoCompleteTextView view) {
+            mViewReference = new WeakReference<AutoCompleteTextView>(view);
+        }
+
         @Override
         public void onChanged() {
-            if (mAdapter != null) {
+            final AutoCompleteTextView textView = mViewReference.get();
+            if (textView != null && textView.mAdapter != null) {
                 // If the popup is not showing already, showing it will cause
                 // the list of data set observers attached to the adapter to
                 // change. We can't do it from here, because we are in the middle
                 // of iterating through the list of observers.
-                post(new Runnable() {
-                    public void run() {
-                        final ListAdapter adapter = mAdapter;
-                        if (adapter != null) {
-                            // This will re-layout, thus resetting mDataChanged, so that the
-                            // listView click listener stays responsive
-                            updateDropDownForFilter(adapter.getCount());
-                        }
-                    }
-                });
+                textView.post(updateRunnable);
             }
         }
+
+        private final Runnable updateRunnable = new Runnable() {
+            @Override
+            public void run() {
+                final AutoCompleteTextView textView = mViewReference.get();
+                if (textView == null) {
+                    return;
+                }
+                final ListAdapter adapter = textView.mAdapter;
+                if (adapter == null) {
+                    return;
+                }
+                textView.updateDropDownForFilter(adapter.getCount());
+            }
+        };
     }
 }
diff --git a/core/java/android/widget/CheckedTextView.java b/core/java/android/widget/CheckedTextView.java
index 29a6a7d..eb8e8aa 100644
--- a/core/java/android/widget/CheckedTextView.java
+++ b/core/java/android/widget/CheckedTextView.java
@@ -48,8 +48,9 @@
     private int mCheckMarkResource;
     private Drawable mCheckMarkDrawable;
     private ColorStateList mCheckMarkTintList = null;
-    private PorterDuff.Mode mCheckMarkTintMode = PorterDuff.Mode.SRC_ATOP;
+    private PorterDuff.Mode mCheckMarkTintMode = null;
     private boolean mHasCheckMarkTint = false;
+    private boolean mHasCheckMarkTintMode = false;
 
     private int mBasePadding;
     private int mCheckMarkWidth;
@@ -79,27 +80,30 @@
         final TypedArray a = context.obtainStyledAttributes(
                 attrs, R.styleable.CheckedTextView, defStyleAttr, defStyleRes);
 
-        Drawable d = a.getDrawable(R.styleable.CheckedTextView_checkMark);
+        final Drawable d = a.getDrawable(R.styleable.CheckedTextView_checkMark);
         if (d != null) {
             setCheckMarkDrawable(d);
         }
 
-        mCheckMarkTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.CheckedTextView_checkMarkTintMode, -1), mCheckMarkTintMode);
+        if (a.hasValue(R.styleable.CheckedTextView_checkMarkTintMode)) {
+            mCheckMarkTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.CheckedTextView_checkMarkTintMode, -1), mCheckMarkTintMode);
+            mHasCheckMarkTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.CheckedTextView_checkMarkTint)) {
             mCheckMarkTintList = a.getColorStateList(R.styleable.CheckedTextView_checkMarkTint);
             mHasCheckMarkTint = true;
-
-            applyCheckMarkTint();
         }
 
         mCheckMarkGravity = a.getInt(R.styleable.CheckedTextView_checkMarkGravity, Gravity.END);
 
-        boolean checked = a.getBoolean(R.styleable.CheckedTextView_checked, false);
+        final boolean checked = a.getBoolean(R.styleable.CheckedTextView_checked, false);
         setChecked(checked);
 
         a.recycle();
+
+        applyCheckMarkTint();
     }
 
     public void toggle() {
@@ -188,7 +192,7 @@
 
     /**
      * Applies a tint to the check mark drawable. Does not modify the
-     * current tint mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * current tint mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setCheckMarkDrawable(Drawable)} will
      * automatically mutate the drawable and apply the specified tint and
@@ -209,6 +213,8 @@
     }
 
     /**
+     * Returns the tint applied to the check mark drawable, if specified.
+     *
      * @return the tint applied to the check mark drawable
      * @attr ref android.R.styleable#CheckedTextView_checkMarkTint
      * @see #setCheckMarkTintList(ColorStateList)
@@ -221,7 +227,7 @@
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setCheckMarkTintList(ColorStateList)} to the check mark
-     * drawable. The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * drawable. The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -231,12 +237,17 @@
      */
     public void setCheckMarkTintMode(@Nullable PorterDuff.Mode tintMode) {
         mCheckMarkTintMode = tintMode;
+        mHasCheckMarkTintMode = true;
 
         applyCheckMarkTint();
     }
 
     /**
-     * @return the blending mode used to apply the tint to the check mark drawable
+     * Returns the blending mode used to apply the tint to the check mark
+     * drawable, if specified.
+     *
+     * @return the blending mode used to apply the tint to the check mark
+     *         drawable
      * @attr ref android.R.styleable#CheckedTextView_checkMarkTintMode
      * @see #setCheckMarkTintMode(PorterDuff.Mode)
      */
@@ -246,10 +257,16 @@
     }
 
     private void applyCheckMarkTint() {
-        if (mCheckMarkDrawable != null && mHasCheckMarkTint) {
+        if (mCheckMarkDrawable != null && (mHasCheckMarkTint || mHasCheckMarkTintMode)) {
             mCheckMarkDrawable = mCheckMarkDrawable.mutate();
-            mCheckMarkDrawable.setTintList(mCheckMarkTintList);
-            mCheckMarkDrawable.setTintMode(mCheckMarkTintMode);
+
+            if (mHasCheckMarkTint) {
+                mCheckMarkDrawable.setTintList(mCheckMarkTintList);
+            }
+
+            if (mHasCheckMarkTintMode) {
+                mCheckMarkDrawable.setTintMode(mCheckMarkTintMode);
+            }
         }
     }
 
diff --git a/core/java/android/widget/CompoundButton.java b/core/java/android/widget/CompoundButton.java
index c1d8cb3..2ccd18d 100644
--- a/core/java/android/widget/CompoundButton.java
+++ b/core/java/android/widget/CompoundButton.java
@@ -54,8 +54,9 @@
 
     private Drawable mButtonDrawable;
     private ColorStateList mButtonTintList = null;
-    private PorterDuff.Mode mButtonTintMode = PorterDuff.Mode.SRC_ATOP;
+    private PorterDuff.Mode mButtonTintMode = null;
     private boolean mHasButtonTint = false;
+    private boolean mHasButtonTintMode = false;
 
     private OnCheckedChangeListener mOnCheckedChangeListener;
     private OnCheckedChangeListener mOnCheckedChangeWidgetListener;
@@ -87,14 +88,15 @@
             setButtonDrawable(d);
         }
 
-        mButtonTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.CompoundButton_buttonTintMode, -1), mButtonTintMode);
+        if (a.hasValue(R.styleable.CompoundButton_buttonTintMode)) {
+            mButtonTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.CompoundButton_buttonTintMode, -1), mButtonTintMode);
+            mHasButtonTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.CompoundButton_buttonTint)) {
             mButtonTintList = a.getColorStateList(R.styleable.CompoundButton_buttonTint);
             mHasButtonTint = true;
-
-            applyButtonTint();
         }
 
         final boolean checked = a.getBoolean(
@@ -102,6 +104,8 @@
         setChecked(checked);
 
         a.recycle();
+
+        applyButtonTint();
     }
 
     public void toggle() {
@@ -240,7 +244,7 @@
 
     /**
      * Applies a tint to the button drawable. Does not modify the current tint
-     * mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setButtonDrawable(Drawable)} will
      * automatically mutate the drawable and apply the specified tint and tint
@@ -273,7 +277,7 @@
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setButtonTintList(ColorStateList)}} to the button drawable. The
-     * default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -283,6 +287,7 @@
      */
     public void setButtonTintMode(@Nullable PorterDuff.Mode tintMode) {
         mButtonTintMode = tintMode;
+        mHasButtonTintMode = true;
 
         applyButtonTint();
     }
@@ -298,10 +303,16 @@
     }
 
     private void applyButtonTint() {
-        if (mButtonDrawable != null && mHasButtonTint) {
+        if (mButtonDrawable != null && (mHasButtonTint || mHasButtonTintMode)) {
             mButtonDrawable = mButtonDrawable.mutate();
-            mButtonDrawable.setTintList(mButtonTintList);
-            mButtonDrawable.setTintMode(mButtonTintMode);
+
+            if (mHasButtonTint) {
+                mButtonDrawable.setTintList(mButtonTintList);
+            }
+
+            if (mHasButtonTintMode) {
+                mButtonDrawable.setTintMode(mButtonTintMode);
+            }
         }
     }
 
diff --git a/core/java/android/widget/DatePicker.java b/core/java/android/widget/DatePicker.java
index 26c1f96..3e4eb02 100644
--- a/core/java/android/widget/DatePicker.java
+++ b/core/java/android/widget/DatePicker.java
@@ -71,9 +71,9 @@
  * @attr ref android.R.styleable#DatePicker_minDate
  * @attr ref android.R.styleable#DatePicker_spinnersShown
  * @attr ref android.R.styleable#DatePicker_calendarViewShown
- * @attr ref android.R.styleable#DatePicker_dayOfWeekBackgroundColor
+ * @attr ref android.R.styleable#DatePicker_dayOfWeekBackground
  * @attr ref android.R.styleable#DatePicker_dayOfWeekTextAppearance
- * @attr ref android.R.styleable#DatePicker_headerBackgroundColor
+ * @attr ref android.R.styleable#DatePicker_headerBackground
  * @attr ref android.R.styleable#DatePicker_headerMonthTextAppearance
  * @attr ref android.R.styleable#DatePicker_headerDayOfMonthTextAppearance
  * @attr ref android.R.styleable#DatePicker_headerYearTextAppearance
@@ -125,6 +125,7 @@
         final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.DatePicker,
                 defStyleAttr, defStyleRes);
         final int mode = a.getInt(R.styleable.DatePicker_datePickerMode, MODE_SPINNER);
+        final int firstDayOfWeek = a.getInt(R.styleable.DatePicker_firstDayOfWeek, 0);
         a.recycle();
 
         switch (mode) {
@@ -136,6 +137,10 @@
                 mDelegate = createSpinnerUIDelegate(context, attrs, defStyleAttr, defStyleRes);
                 break;
         }
+
+        if (firstDayOfWeek != 0) {
+            setFirstDayOfWeek(firstDayOfWeek);
+        }
     }
 
     private DatePickerDelegate createSpinnerUIDelegate(Context context, AttributeSet attrs,
@@ -300,6 +305,47 @@
     }
 
     /**
+     * Sets the first day of week.
+     *
+     * @param firstDayOfWeek The first day of the week conforming to the
+     *            {@link CalendarView} APIs.
+     * @see Calendar#SUNDAY
+     * @see Calendar#MONDAY
+     * @see Calendar#TUESDAY
+     * @see Calendar#WEDNESDAY
+     * @see Calendar#THURSDAY
+     * @see Calendar#FRIDAY
+     * @see Calendar#SATURDAY
+     *
+     * @attr ref android.R.styleable#DatePicker_firstDayOfWeek
+     */
+    public void setFirstDayOfWeek(int firstDayOfWeek) {
+        if (firstDayOfWeek < Calendar.SUNDAY || firstDayOfWeek > Calendar.SATURDAY) {
+            throw new IllegalArgumentException("firstDayOfWeek must be between 1 and 7");
+        }
+        mDelegate.setFirstDayOfWeek(firstDayOfWeek);
+    }
+
+    /**
+     * Gets the first day of week.
+     *
+     * @return The first day of the week conforming to the {@link CalendarView}
+     *         APIs.
+     * @see Calendar#SUNDAY
+     * @see Calendar#MONDAY
+     * @see Calendar#TUESDAY
+     * @see Calendar#WEDNESDAY
+     * @see Calendar#THURSDAY
+     * @see Calendar#FRIDAY
+     * @see Calendar#SATURDAY
+     *
+     * @attr ref android.R.styleable#DatePicker_firstDayOfWeek
+     */
+    public int getFirstDayOfWeek() {
+        return mDelegate.getFirstDayOfWeek();
+    }
+
+    /**
      * Gets whether the {@link CalendarView} is shown.
      *
      * @return True if the calendar view is shown.
@@ -315,7 +361,7 @@
      * @return The calendar view.
      * @see #getCalendarViewShown()
      */
-    public CalendarView getCalendarView () {
+    public CalendarView getCalendarView() {
         return mDelegate.getCalendarView();
     }
 
@@ -346,10 +392,9 @@
         mDelegate.setSpinnersShown(shown);
     }
 
-    // Override so we are in complete control of save / restore for this widget.
     @Override
     protected void dispatchRestoreInstanceState(SparseArray<Parcelable> container) {
-        mDelegate.dispatchRestoreInstanceState(container);
+        dispatchThawSelfOnly(container);
     }
 
     @Override
@@ -360,7 +405,7 @@
 
     @Override
     protected void onRestoreInstanceState(Parcelable state) {
-        SavedState ss = (SavedState) state;
+        BaseSavedState ss = (BaseSavedState) state;
         super.onRestoreInstanceState(ss.getSuperState());
         mDelegate.onRestoreInstanceState(ss);
     }
@@ -382,6 +427,9 @@
         int getMonth();
         int getDayOfMonth();
 
+        void setFirstDayOfWeek(int firstDayOfWeek);
+        int getFirstDayOfWeek();
+
         void setMinDate(long minDate);
         Calendar getMinDate();
 
@@ -403,7 +451,6 @@
 
         void onConfigurationChanged(Configuration newConfig);
 
-        void dispatchRestoreInstanceState(SparseArray<Parcelable> container);
         Parcelable onSaveInstanceState(Parcelable superState);
         void onRestoreInstanceState(Parcelable state);
 
@@ -699,6 +746,16 @@
         }
 
         @Override
+        public void setFirstDayOfWeek(int firstDayOfWeek) {
+            mCalendarView.setFirstDayOfWeek(firstDayOfWeek);
+        }
+
+        @Override
+        public int getFirstDayOfWeek() {
+            return mCalendarView.getFirstDayOfWeek();
+        }
+
+        @Override
         public void setMinDate(long minDate) {
             mTempDate.setTimeInMillis(minDate);
             if (mTempDate.get(Calendar.YEAR) == mMinDate.get(Calendar.YEAR)
@@ -789,11 +846,6 @@
         }
 
         @Override
-        public void dispatchRestoreInstanceState(SparseArray<Parcelable> container) {
-            mDelegator.dispatchThawSelfOnly(container);
-        }
-
-        @Override
         public Parcelable onSaveInstanceState(Parcelable superState) {
             return new SavedState(superState, getYear(), getMonth(), getDayOfMonth());
         }
diff --git a/core/java/android/widget/DatePickerCalendarDelegate.java b/core/java/android/widget/DatePickerCalendarDelegate.java
index f4a478a..e71b383 100644
--- a/core/java/android/widget/DatePickerCalendarDelegate.java
+++ b/core/java/android/widget/DatePickerCalendarDelegate.java
@@ -16,15 +16,12 @@
 
 package android.widget;
 
-import android.animation.Keyframe;
-import android.animation.ObjectAnimator;
-import android.animation.PropertyValuesHolder;
 import android.content.Context;
 import android.content.res.ColorStateList;
 import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.content.res.TypedArray;
-import android.graphics.Color;
+import android.graphics.drawable.Drawable;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.text.format.DateFormat;
@@ -52,6 +49,7 @@
  */
 class DatePickerCalendarDelegate extends DatePicker.AbstractDatePickerDelegate implements
         View.OnClickListener, DatePickerController {
+    private static final int USE_LOCALE = 0;
 
     private static final int UNINITIALIZED = -1;
     private static final int MONTH_AND_DAY_VIEW = 0;
@@ -60,10 +58,7 @@
     private static final int DEFAULT_START_YEAR = 1900;
     private static final int DEFAULT_END_YEAR = 2100;
 
-    private static final int PULSE_ANIMATOR_DURATION = 544;
-
     private static final int ANIMATION_DURATION = 300;
-    private static final int ANIMATION_DELAY = 650;
 
     private static final int MONTH_INDEX = 0;
     private static final int DAY_INDEX = 1;
@@ -73,8 +68,13 @@
     private SimpleDateFormat mDayFormat = new SimpleDateFormat("d", Locale.getDefault());
 
     private TextView mDayOfWeekView;
-    private LinearLayout mDateLayout;
+
+    /** Layout that contains the current month, day, and year. */
+    private LinearLayout mMonthDayYearLayout;
+
+    /** Clickable layout that contains the current day and year. */
     private LinearLayout mMonthAndDayLayout;
+
     private TextView mHeaderMonthTextView;
     private TextView mHeaderDayOfMonthTextView;
     private TextView mHeaderYearTextView;
@@ -93,8 +93,6 @@
 
     private DatePicker.OnDateChangedListener mDateChangedListener;
 
-    private boolean mDelayAnimation = true;
-
     private int mCurrentView = UNINITIALIZED;
 
     private Calendar mCurrentDate;
@@ -102,6 +100,8 @@
     private Calendar mMinDate;
     private Calendar mMaxDate;
 
+    private int mFirstDayOfWeek = USE_LOCALE;
+
     private HashSet<OnDateChangedListener> mListeners = new HashSet<OnDateChangedListener>();
 
     public DatePickerCalendarDelegate(DatePicker delegator, Context context, AttributeSet attrs,
@@ -112,7 +112,6 @@
         mMinDate = getCalendarForLocale(mMinDate, locale);
         mMaxDate = getCalendarForLocale(mMaxDate, locale);
         mTempDate = getCalendarForLocale(mMaxDate, locale);
-
         mCurrentDate = getCalendarForLocale(mCurrentDate, locale);
 
         mMinDate.set(DEFAULT_START_YEAR, 1, 1);
@@ -129,7 +128,12 @@
         mDelegator.addView(mainView);
 
         mDayOfWeekView = (TextView) mainView.findViewById(R.id.date_picker_header);
-        mDateLayout = (LinearLayout) mainView.findViewById(R.id.day_picker_selector_layout);
+
+        // Layout that contains the current date and day name header.
+        final LinearLayout dateLayout = (LinearLayout) mainView.findViewById(
+                R.id.day_picker_selector_layout);
+        mMonthDayYearLayout = (LinearLayout) mainView.findViewById(
+                R.id.date_picker_month_day_year_layout);
         mMonthAndDayLayout = (LinearLayout) mainView.findViewById(
                 R.id.date_picker_month_and_day_layout);
         mMonthAndDayLayout.setOnClickListener(this);
@@ -148,16 +152,12 @@
             mDayOfWeekView.setTextAppearance(context, dayOfWeekTextAppearanceResId);
         }
 
-        final int dayOfWeekBackgroundColor = a.getColor(
-                R.styleable.DatePicker_dayOfWeekBackgroundColor, Color.TRANSPARENT);
-        mDayOfWeekView.setBackgroundColor(dayOfWeekBackgroundColor);
+        mDayOfWeekView.setBackground(a.getDrawable(R.styleable.DatePicker_dayOfWeekBackground));
+
+        dateLayout.setBackground(a.getDrawable(R.styleable.DatePicker_headerBackground));
 
         final int headerSelectedTextColor = a.getColor(
                 R.styleable.DatePicker_headerSelectedTextColor, defaultHighlightColor);
-        final int headerBackgroundColor = a.getColor(R.styleable.DatePicker_headerBackgroundColor,
-                Color.TRANSPARENT);
-        mDateLayout.setBackgroundColor(headerBackgroundColor);
-
         final int monthTextAppearanceResId = a.getResourceId(
                 R.styleable.DatePicker_headerMonthTextAppearance, -1);
         if (monthTextAppearanceResId != -1) {
@@ -189,6 +189,10 @@
         mYearPickerView = new YearPickerView(mContext);
         mYearPickerView.init(this);
 
+        final int yearSelectedCircleColor = a.getColor(R.styleable.DatePicker_yearListSelectorColor,
+                defaultHighlightColor);
+        mYearPickerView.setYearSelectedCircleColor(yearSelectedCircleColor);
+
         final ColorStateList calendarTextColor = a.getColorStateList(
                 R.styleable.DatePicker_calendarTextColor);
         final int calendarSelectedTextColor = a.getColor(
@@ -205,10 +209,12 @@
         mAnimator.addView(mDayPickerView);
         mAnimator.addView(mYearPickerView);
         mAnimator.setDateMillis(mCurrentDate.getTimeInMillis());
-        Animation animation = new AlphaAnimation(0.0f, 1.0f);
+
+        final Animation animation = new AlphaAnimation(0.0f, 1.0f);
         animation.setDuration(ANIMATION_DURATION);
         mAnimator.setInAnimation(animation);
-        Animation animation2 = new AlphaAnimation(1.0f, 0.0f);
+
+        final Animation animation2 = new AlphaAnimation(1.0f, 0.0f);
         animation2.setDuration(ANIMATION_DURATION);
         mAnimator.setOutAnimation(animation2);
 
@@ -276,30 +282,28 @@
             mDayOfWeekView.setText(mCurrentDate.getDisplayName(Calendar.DAY_OF_WEEK, Calendar.LONG,
                     Locale.getDefault()));
         }
-        final String bestDateTimePattern =
-                DateFormat.getBestDateTimePattern(mCurrentLocale, "yMMMd");
 
         // Compute indices of Month, Day and Year views
-        int[] viewIndices = getMonthDayYearIndexes(bestDateTimePattern);
+        final String bestDateTimePattern =
+                DateFormat.getBestDateTimePattern(mCurrentLocale, "yMMMd");
+        final int[] viewIndices = getMonthDayYearIndexes(bestDateTimePattern);
 
-        // Restart from a clean state
-        mMonthAndDayLayout.removeAllViews();
-        mDateLayout.removeView(mHeaderYearTextView);
-
-        // Position the Year View at the correct location
+        // Position the Year and MonthAndDay views within the header.
+        mMonthDayYearLayout.removeAllViews();
         if (viewIndices[YEAR_INDEX] == 0) {
-            mDateLayout.addView(mHeaderYearTextView, 1);
+            mMonthDayYearLayout.addView(mHeaderYearTextView);
+            mMonthDayYearLayout.addView(mMonthAndDayLayout);
         } else {
-            mDateLayout.addView(mHeaderYearTextView, 2);
+            mMonthDayYearLayout.addView(mMonthAndDayLayout);
+            mMonthDayYearLayout.addView(mHeaderYearTextView);
         }
 
-        // Position Day and Month Views
+        // Position Day and Month views within the MonthAndDay view.
+        mMonthAndDayLayout.removeAllViews();
         if (viewIndices[MONTH_INDEX] > viewIndices[DAY_INDEX]) {
-            // Day View is first
             mMonthAndDayLayout.addView(mHeaderDayOfMonthTextView);
             mMonthAndDayLayout.addView(mHeaderMonthTextView);
         } else {
-            // Month View is first
             mMonthAndDayLayout.addView(mHeaderMonthTextView);
             mMonthAndDayLayout.addView(mHeaderDayOfMonthTextView);
         }
@@ -329,12 +333,6 @@
 
         switch (viewIndex) {
             case MONTH_AND_DAY_VIEW:
-                ObjectAnimator pulseAnimator = getPulseAnimator(mMonthAndDayLayout, 0.9f,
-                        1.05f);
-                if (mDelayAnimation) {
-                    pulseAnimator.setStartDelay(ANIMATION_DELAY);
-                    mDelayAnimation = false;
-                }
                 mDayPickerView.onDateChanged();
                 if (mCurrentView != viewIndex) {
                     mMonthAndDayLayout.setSelected(true);
@@ -342,19 +340,13 @@
                     mAnimator.setDisplayedChild(MONTH_AND_DAY_VIEW);
                     mCurrentView = viewIndex;
                 }
-                pulseAnimator.start();
 
-                int flags = DateUtils.FORMAT_SHOW_DATE;
-                String dayString = DateUtils.formatDateTime(mContext, millis, flags);
+                final int flags = DateUtils.FORMAT_SHOW_DATE;
+                final String dayString = DateUtils.formatDateTime(mContext, millis, flags);
                 mAnimator.setContentDescription(mDayPickerDescription + ": " + dayString);
                 mAnimator.announceForAccessibility(mSelectDay);
                 break;
             case YEAR_VIEW:
-                pulseAnimator = getPulseAnimator(mHeaderYearTextView, 0.85f, 1.1f);
-                if (mDelayAnimation) {
-                    pulseAnimator.setStartDelay(ANIMATION_DELAY);
-                    mDelayAnimation = false;
-                }
                 mYearPickerView.onDateChanged();
                 if (mCurrentView != viewIndex) {
                     mMonthAndDayLayout.setSelected(false);
@@ -362,9 +354,8 @@
                     mAnimator.setDisplayedChild(YEAR_VIEW);
                     mCurrentView = viewIndex;
                 }
-                pulseAnimator.start();
 
-                CharSequence yearString = mYearFormat.format(millis);
+                final CharSequence yearString = mYearFormat.format(millis);
                 mAnimator.setContentDescription(mYearPickerDescription + ": " + yearString);
                 mAnimator.announceForAccessibility(mSelectYear);
                 break;
@@ -386,7 +377,9 @@
         mCurrentDate.set(Calendar.YEAR, year);
         mCurrentDate.set(Calendar.MONTH, month);
         mCurrentDate.set(Calendar.DAY_OF_MONTH, dayOfMonth);
-        mDateChangedListener.onDateChanged(mDelegator, year, month, dayOfMonth);
+        if (mDateChangedListener != null) {
+            mDateChangedListener.onDateChanged(mDelegator, year, month, dayOfMonth);
+        }
         updateDisplay(false);
     }
 
@@ -448,7 +441,15 @@
     }
 
     @Override
+    public void setFirstDayOfWeek(int firstDayOfWeek) {
+        mFirstDayOfWeek = firstDayOfWeek;
+    }
+
+    @Override
     public int getFirstDayOfWeek() {
+        if (mFirstDayOfWeek != USE_LOCALE) {
+            return mFirstDayOfWeek;
+        }
         return mCurrentDate.getFirstDayOfWeek();
     }
 
@@ -528,11 +529,6 @@
     }
 
     @Override
-    public void dispatchRestoreInstanceState(SparseArray<Parcelable> container) {
-        // Nothing to do
-    }
-
-    @Override
     public Parcelable onSaveInstanceState(Parcelable superState) {
         final int year = mCurrentDate.get(Calendar.YEAR);
         final int month = mCurrentDate.get(Calendar.MONTH);
@@ -556,7 +552,7 @@
     public void onRestoreInstanceState(Parcelable state) {
         SavedState ss = (SavedState) state;
 
-        mCurrentDate.set(ss.getSelectedDay(), ss.getSelectedMonth(), ss.getSelectedYear());
+        mCurrentDate.set(ss.getSelectedYear(), ss.getSelectedMonth(), ss.getSelectedDay());
         mCurrentView = ss.getCurrentView();
         mMinDate.setTimeInMillis(ss.getMinDate());
         mMaxDate.setTimeInMillis(ss.getMaxDate());
@@ -787,25 +783,4 @@
             }
         };
     }
-
-    /**
-     * Render an animator to pulsate a view in place.
-     * @param labelToAnimate the view to pulsate.
-     * @return The animator object. Use .start() to begin.
-     */
-    public static ObjectAnimator getPulseAnimator(View labelToAnimate, float decreaseRatio,
-                                                  float increaseRatio) {
-        Keyframe k0 = Keyframe.ofFloat(0f, 1f);
-        Keyframe k1 = Keyframe.ofFloat(0.275f, decreaseRatio);
-        Keyframe k2 = Keyframe.ofFloat(0.69f, increaseRatio);
-        Keyframe k3 = Keyframe.ofFloat(1f, 1f);
-
-        PropertyValuesHolder scaleX = PropertyValuesHolder.ofKeyframe(View.SCALE_X, k0, k1, k2, k3);
-        PropertyValuesHolder scaleY = PropertyValuesHolder.ofKeyframe(View.SCALE_Y, k0, k1, k2, k3);
-        ObjectAnimator pulseAnimator =
-                ObjectAnimator.ofPropertyValuesHolder(labelToAnimate, scaleX, scaleY);
-        pulseAnimator.setDuration(PULSE_ANIMATOR_DURATION);
-
-        return pulseAnimator;
-    }
 }
diff --git a/core/java/android/widget/DatePickerController.java b/core/java/android/widget/DatePickerController.java
index 6a074da..059709d 100644
--- a/core/java/android/widget/DatePickerController.java
+++ b/core/java/android/widget/DatePickerController.java
@@ -35,6 +35,7 @@
 
     Calendar getSelectedDay();
 
+    void setFirstDayOfWeek(int firstDayOfWeek);
     int getFirstDayOfWeek();
 
     int getMinYear();
diff --git a/core/java/android/widget/DayPickerView.java b/core/java/android/widget/DayPickerView.java
index c44bd46..ca4095e 100644
--- a/core/java/android/widget/DayPickerView.java
+++ b/core/java/android/widget/DayPickerView.java
@@ -73,11 +73,6 @@
 
     private ScrollStateRunnable mScrollStateChangedRunnable = new ScrollStateRunnable(this);
 
-    public DayPickerView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        init();
-    }
-
     public DayPickerView(Context context, DatePickerController controller) {
         super(context);
         init();
diff --git a/core/java/android/widget/EdgeEffect.java b/core/java/android/widget/EdgeEffect.java
index 57b8dcb..033b99a 100644
--- a/core/java/android/widget/EdgeEffect.java
+++ b/core/java/android/widget/EdgeEffect.java
@@ -52,12 +52,15 @@
     private static final String TAG = "EdgeEffect";
 
     // Time it will take the effect to fully recede in ms
-    private static final int RECEDE_TIME = 1000;
+    private static final int RECEDE_TIME = 600;
 
     // Time it will take before a pulled glow begins receding in ms
     private static final int PULL_TIME = 167;
 
-    private static final float MAX_ALPHA = 1.f;
+    // Time it will take in ms for a pulled glow to decay to partial strength before release
+    private static final int PULL_DECAY_TIME = 2000;
+
+    private static final float MAX_ALPHA = 0.5f;
 
     private static final float MAX_GLOW_SCALE = 2.f;
 
@@ -93,12 +96,9 @@
     private static final int STATE_RECEDE = 3;
     private static final int STATE_PULL_DECAY = 4;
 
-    // How much dragging should effect the height of the glow image.
-    // Number determined by user testing.
-    private static final int PULL_DISTANCE_GLOW_FACTOR = 7;
-    private static final float PULL_DISTANCE_ALPHA_GLOW_FACTOR = 1.1f;
+    private static final float PULL_DISTANCE_ALPHA_GLOW_FACTOR = 0.8f;
 
-    private static final int VELOCITY_GLOW_FACTOR = 12;
+    private static final int VELOCITY_GLOW_FACTOR = 6;
 
     private int mState = STATE_IDLE;
 
@@ -107,7 +107,7 @@
     private final Rect mBounds = new Rect();
     private final Paint mPaint = new Paint();
     private float mRadius;
-    private float mBaseGlowHeight;
+    private float mBaseGlowScale;
     private float mDisplacement = 0.5f;
     private float mTargetDisplacement = 0.5f;
 
@@ -138,8 +138,12 @@
         final float r = width * 0.75f / SIN;
         final float y = COS * r;
         final float h = r - y;
+        final float or = height * 0.75f / SIN;
+        final float oy = COS * or;
+        final float oh = or - oy;
+
         mRadius = r;
-        mBaseGlowHeight = h;
+        mBaseGlowScale = h > 0 ? Math.min(oh / h, 1.f) : 1.f;
 
         mBounds.set(mBounds.left, mBounds.top, width, (int) Math.min(height, h));
     }
@@ -319,13 +323,14 @@
         final float centerX = mBounds.centerX();
         final float centerY = mBounds.height() - mRadius;
 
-        canvas.scale(1.f, Math.min(mGlowScaleY, 1.f), centerX, 0);
+        canvas.scale(1.f, Math.min(mGlowScaleY, 1.f) * mBaseGlowScale, centerX, 0);
 
         final float displacement = Math.max(0, Math.min(mDisplacement, 1.f)) - 0.5f;
         float translateX = mBounds.width() * displacement / 2;
 
         canvas.clipRect(mBounds);
         canvas.translate(translateX, 0);
+        mPaint.setAlpha((int) (0xff * mGlowAlpha));
         canvas.drawCircle(centerX, centerY, mRadius, mPaint);
         canvas.restoreToCount(count);
 
@@ -372,7 +377,16 @@
                     mGlowScaleYFinish = 0.f;
                     break;
                 case STATE_PULL:
-                    // Hold in this state until explicitly released.
+                    mState = STATE_PULL_DECAY;
+                    mStartTime = AnimationUtils.currentAnimationTimeMillis();
+                    mDuration = PULL_DECAY_TIME;
+
+                    mGlowAlphaStart = mGlowAlpha;
+                    mGlowScaleYStart = mGlowScaleY;
+
+                    // After pull, the glow should fade to nothing.
+                    mGlowAlphaFinish = 0.f;
+                    mGlowScaleYFinish = 0.f;
                     break;
                 case STATE_PULL_DECAY:
                     mState = STATE_RECEDE;
diff --git a/core/java/android/widget/Editor.java b/core/java/android/widget/Editor.java
index b37ee06..128a06c 100644
--- a/core/java/android/widget/Editor.java
+++ b/core/java/android/widget/Editor.java
@@ -147,7 +147,7 @@
         boolean isDirty;
         public TextDisplayList(String name) {
             isDirty = true;
-            displayList = RenderNode.create(name);
+            displayList = RenderNode.create(name, null);
         }
         boolean needsRecord() { return isDirty || !displayList.isValid(); }
     }
@@ -1298,25 +1298,6 @@
                         reported = reportExtractedText();
                     }
                 }
-
-                if (imm.isWatchingCursor(mTextView) && highlight != null) {
-                    highlight.computeBounds(ims.mTmpRectF, true);
-                    ims.mTmpOffset[0] = ims.mTmpOffset[1] = 0;
-
-                    canvas.getMatrix().mapPoints(ims.mTmpOffset);
-                    ims.mTmpRectF.offset(ims.mTmpOffset[0], ims.mTmpOffset[1]);
-
-                    ims.mTmpRectF.offset(0, cursorOffsetVertical);
-
-                    ims.mCursorRectInWindow.set((int)(ims.mTmpRectF.left + 0.5),
-                            (int)(ims.mTmpRectF.top + 0.5),
-                            (int)(ims.mTmpRectF.right + 0.5),
-                            (int)(ims.mTmpRectF.bottom + 0.5));
-
-                    imm.updateCursor(mTextView,
-                            ims.mCursorRectInWindow.left, ims.mCursorRectInWindow.top,
-                            ims.mCursorRectInWindow.right, ims.mCursorRectInWindow.bottom);
-                }
             }
         }
 
@@ -1879,9 +1860,8 @@
         }
 
         final int originalLength = mTextView.getText().length();
-        long minMax = mTextView.prepareSpacesAroundPaste(offset, offset, content);
-        int min = TextUtils.unpackRangeStartFromLong(minMax);
-        int max = TextUtils.unpackRangeEndFromLong(minMax);
+        int min = offset;
+        int max = offset;
 
         Selection.setSelection((Spannable) mTextView.getText(), max);
         mTextView.replaceText_internal(min, max, content);
@@ -3079,48 +3059,69 @@
                     final CharSequence composingText = text.subSequence(composingTextStart,
                             composingTextEnd);
                     builder.setComposingText(composingTextStart, composingText);
-                }
-                // TODO: Optimize this loop by caching the result.
-                for (int offset = composingTextStart; offset < composingTextEnd; offset++) {
-                    if (offset < 0) {
-                        continue;
+
+                    final int minLine = layout.getLineForOffset(composingTextStart);
+                    final int maxLine = layout.getLineForOffset(composingTextEnd - 1);
+                    for (int line = minLine; line <= maxLine; ++line) {
+                        final int lineStart = layout.getLineStart(line);
+                        final int lineEnd = layout.getLineEnd(line);
+                        final int offsetStart = Math.max(lineStart, composingTextStart);
+                        final int offsetEnd = Math.min(lineEnd, composingTextEnd);
+                        final boolean ltrLine =
+                                layout.getParagraphDirection(line) == Layout.DIR_LEFT_TO_RIGHT;
+                        final float[] widths = new float[offsetEnd - offsetStart];
+                        layout.getPaint().getTextWidths(text, offsetStart, offsetEnd, widths);
+                        final float top = layout.getLineTop(line);
+                        final float bottom = layout.getLineBottom(line);
+                        for (int offset = offsetStart; offset < offsetEnd; ++offset) {
+                            final float charWidth = widths[offset - offsetStart];
+                            final boolean isRtl = layout.isRtlCharAt(offset);
+                            final float primary = layout.getPrimaryHorizontal(offset);
+                            final float secondary = layout.getSecondaryHorizontal(offset);
+                            // TODO: This doesn't work perfectly for text with custom styles and
+                            // TAB chars.
+                            final float left;
+                            final float right;
+                            if (ltrLine) {
+                                if (isRtl) {
+                                    left = secondary - charWidth;
+                                    right = secondary;
+                                } else {
+                                    left = primary;
+                                    right = primary + charWidth;
+                                }
+                            } else {
+                                if (!isRtl) {
+                                    left = secondary;
+                                    right = secondary + charWidth;
+                                } else {
+                                    left = primary - charWidth;
+                                    right = primary;
+                                }
+                            }
+                            // TODO: Check top-right and bottom-left as well.
+                            final float localLeft = left + viewportToContentHorizontalOffset;
+                            final float localRight = right + viewportToContentHorizontalOffset;
+                            final float localTop = top + viewportToContentVerticalOffset;
+                            final float localBottom = bottom + viewportToContentVerticalOffset;
+                            final boolean isTopLeftVisible = isPositionVisible(localLeft, localTop);
+                            final boolean isBottomRightVisible =
+                                    isPositionVisible(localRight, localBottom);
+                            int characterBoundsFlags = 0;
+                            if (isTopLeftVisible || isBottomRightVisible) {
+                                characterBoundsFlags |= CursorAnchorInfo.FLAG_HAS_VISIBLE_REGION;
+                            }
+                            if (!isTopLeftVisible || !isTopLeftVisible) {
+                                characterBoundsFlags |= CursorAnchorInfo.FLAG_HAS_INVISIBLE_REGION;
+                            }
+                            if (isRtl) {
+                                characterBoundsFlags |= CursorAnchorInfo.FLAG_IS_RTL;
+                            }
+                            // Here offset is the index in Java chars.
+                            builder.addCharacterBounds(offset, localLeft, localTop, localRight,
+                                    localBottom, characterBoundsFlags);
+                        }
                     }
-                    final boolean isRtl = layout.isRtlCharAt(offset);
-                    final int line = layout.getLineForOffset(offset);
-                    final int nextCharIndex = offset + 1;
-                    final float localLeadingEdgeX = layout.getPrimaryHorizontal(offset);
-                    final float localTrailingEdgeX;
-                    if (nextCharIndex != layout.getLineEnd(line)) {
-                        localTrailingEdgeX = layout.getPrimaryHorizontal(nextCharIndex);
-                    } else if (isRtl) {
-                        localTrailingEdgeX = layout.getLineLeft(line);
-                    } else {
-                        localTrailingEdgeX = layout.getLineRight(line);
-                    }
-                    final float leadingEdgeX = localLeadingEdgeX
-                            + viewportToContentHorizontalOffset;
-                    final float trailingEdgeX = localTrailingEdgeX
-                            + viewportToContentHorizontalOffset;
-                    final float top = layout.getLineTop(line) + viewportToContentVerticalOffset;
-                    final float bottom = layout.getLineBottom(line)
-                            + viewportToContentVerticalOffset;
-                    // TODO: Check right-top and left-bottom as well.
-                    final boolean isLeadingEdgeTopVisible = isPositionVisible(leadingEdgeX, top);
-                    final boolean isTrailingEdgeBottomVisible =
-                            isPositionVisible(trailingEdgeX, bottom);
-                    final int characterRectFlags;
-                    if (isLeadingEdgeTopVisible && isTrailingEdgeBottomVisible) {
-                        characterRectFlags = CursorAnchorInfo.CHARACTER_RECT_TYPE_FULLY_VISIBLE;
-                    } else if (isLeadingEdgeTopVisible || isTrailingEdgeBottomVisible) {
-                        characterRectFlags = CursorAnchorInfo.CHARACTER_RECT_TYPE_PARTIALLY_VISIBLE;
-                    } else {
-                        characterRectFlags = CursorAnchorInfo.CHARACTER_RECT_TYPE_INVISIBLE;
-                    }
-                    // Here offset is the index in Java chars.
-                    // TODO: We must have a well-defined specification. For example, how
-                    // surrogate pairs and composition letters are handled must be documented.
-                    builder.addCharacterRect(offset, leadingEdgeX, top, trailingEdgeX, bottom,
-                            characterRectFlags);
                 }
             }
 
@@ -3136,11 +3137,22 @@
                         + viewportToContentVerticalOffset;
                 final float insertionMarkerBottom = layout.getLineBottom(line)
                         + viewportToContentVerticalOffset;
-                // Take TextView's padding and scroll into account.
-                final boolean isClipped = !isPositionVisible(insertionMarkerX, insertionMarkerTop)
-                        || !isPositionVisible(insertionMarkerX, insertionMarkerBottom);
+                final boolean isTopVisible =
+                        isPositionVisible(insertionMarkerX, insertionMarkerTop);
+                final boolean isBottomVisible =
+                        isPositionVisible(insertionMarkerX, insertionMarkerBottom);
+                int insertionMarkerFlags = 0;
+                if (isTopVisible || isBottomVisible) {
+                    insertionMarkerFlags |= CursorAnchorInfo.FLAG_HAS_VISIBLE_REGION;
+                }
+                if (!isTopVisible || !isBottomVisible) {
+                    insertionMarkerFlags |= CursorAnchorInfo.FLAG_HAS_INVISIBLE_REGION;
+                }
+                if (layout.isRtlCharAt(offset)) {
+                    insertionMarkerFlags |= CursorAnchorInfo.FLAG_IS_RTL;
+                }
                 builder.setInsertionMarkerLocation(insertionMarkerX, insertionMarkerTop,
-                        insertionMarkerBaseline, insertionMarkerBottom, isClipped);
+                        insertionMarkerBaseline, insertionMarkerBottom, insertionMarkerFlags);
             }
 
             imm.updateCursorAnchorInfo(mTextView, builder.build());
@@ -3158,6 +3170,7 @@
         // Offset from touch position to mPosition
         private float mTouchToWindowOffsetX, mTouchToWindowOffsetY;
         protected int mHotspotX;
+        protected int mHorizontalGravity;
         // Offsets the hotspot point up, so that cursor is not hidden by the finger when moving up
         private float mTouchOffsetY;
         // Where the touch position should be on the handle to ensure a maximum cursor visibility
@@ -3172,6 +3185,8 @@
         private boolean mPositionHasChanged = true;
         // Used to delay the appearance of the action popup window
         private Runnable mActionPopupShower;
+        // Minimum touch target size for handles
+        private int mMinSize;
 
         public HandleView(Drawable drawableLtr, Drawable drawableRtl) {
             super(mTextView.getContext());
@@ -3184,10 +3199,12 @@
 
             mDrawableLtr = drawableLtr;
             mDrawableRtl = drawableRtl;
+            mMinSize = mTextView.getContext().getResources().getDimensionPixelSize(
+                    com.android.internal.R.dimen.text_handle_min_size);
 
             updateDrawable();
 
-            final int handleHeight = mDrawable.getIntrinsicHeight();
+            final int handleHeight = getPreferredHeight();
             mTouchOffsetY = -0.3f * handleHeight;
             mIdealVerticalOffset = 0.7f * handleHeight;
         }
@@ -3197,9 +3214,11 @@
             final boolean isRtlCharAtOffset = mTextView.getLayout().isRtlCharAt(offset);
             mDrawable = isRtlCharAtOffset ? mDrawableRtl : mDrawableLtr;
             mHotspotX = getHotspotX(mDrawable, isRtlCharAtOffset);
+            mHorizontalGravity = getHorizontalGravity(isRtlCharAtOffset);
         }
 
         protected abstract int getHotspotX(Drawable drawable, boolean isRtlRun);
+        protected abstract int getHorizontalGravity(boolean isRtlRun);
 
         // Touch-up filter: number of previous positions remembered
         private static final int HISTORY_SIZE = 5;
@@ -3244,7 +3263,15 @@
 
         @Override
         protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-            setMeasuredDimension(mDrawable.getIntrinsicWidth(), mDrawable.getIntrinsicHeight());
+            setMeasuredDimension(getPreferredWidth(), getPreferredHeight());
+        }
+
+        private int getPreferredWidth() {
+            return Math.max(mDrawable.getIntrinsicWidth(), mMinSize);
+        }
+
+        private int getPreferredHeight() {
+            return Math.max(mDrawable.getIntrinsicHeight(), mMinSize);
         }
 
         public void show() {
@@ -3336,7 +3363,8 @@
                 }
                 final int line = layout.getLineForOffset(offset);
 
-                mPositionX = (int) (layout.getPrimaryHorizontal(offset) - 0.5f - mHotspotX);
+                mPositionX = (int) (layout.getPrimaryHorizontal(offset) - 0.5f - mHotspotX -
+                        getHorizontalOffset() + getCursorOffset());
                 mPositionY = layout.getLineBottom(line);
 
                 // Take TextView's padding and scroll into account.
@@ -3385,10 +3413,36 @@
 
         @Override
         protected void onDraw(Canvas c) {
-            mDrawable.setBounds(0, 0, mRight - mLeft, mBottom - mTop);
+            final int drawWidth = mDrawable.getIntrinsicWidth();
+            final int left = getHorizontalOffset();
+
+            mDrawable.setBounds(left, 0, left + drawWidth, mDrawable.getIntrinsicHeight());
             mDrawable.draw(c);
         }
 
+        private int getHorizontalOffset() {
+            final int width = getPreferredWidth();
+            final int drawWidth = mDrawable.getIntrinsicWidth();
+            final int left;
+            switch (mHorizontalGravity) {
+                case Gravity.LEFT:
+                    left = 0;
+                    break;
+                default:
+                case Gravity.CENTER:
+                    left = (width - drawWidth) / 2;
+                    break;
+                case Gravity.RIGHT:
+                    left = width - drawWidth;
+                    break;
+            }
+            return left;
+        }
+
+        protected int getCursorOffset() {
+            return 0;
+        }
+
         @Override
         public boolean onTouchEvent(MotionEvent ev) {
             switch (ev.getActionMasked()) {
@@ -3508,6 +3562,22 @@
         }
 
         @Override
+        protected int getHorizontalGravity(boolean isRtlRun) {
+            return Gravity.CENTER_HORIZONTAL;
+        }
+
+        @Override
+        protected int getCursorOffset() {
+            int offset = super.getCursorOffset();
+            final Drawable cursor = mCursorCount > 0 ? mCursorDrawable[0] : null;
+            if (cursor != null) {
+                cursor.getPadding(mTempRect);
+                offset += (cursor.getIntrinsicWidth() - mTempRect.left - mTempRect.right) / 2;
+            }
+            return offset;
+        }
+
+        @Override
         public boolean onTouchEvent(MotionEvent ev) {
             final boolean result = super.onTouchEvent(ev);
 
@@ -3594,6 +3664,11 @@
         }
 
         @Override
+        protected int getHorizontalGravity(boolean isRtlRun) {
+            return isRtlRun ? Gravity.RIGHT : Gravity.LEFT;
+        }
+
+        @Override
         public int getCurrentCursorOffset() {
             return mTextView.getSelectionStart();
         }
@@ -3637,6 +3712,11 @@
         }
 
         @Override
+        protected int getHorizontalGravity(boolean isRtlRun) {
+            return isRtlRun ? Gravity.LEFT : Gravity.RIGHT;
+        }
+
+        @Override
         public int getCurrentCursorOffset() {
             return mTextView.getSelectionEnd();
         }
@@ -4068,7 +4148,6 @@
 
     static class InputMethodState {
         Rect mCursorRectInWindow = new Rect();
-        RectF mTmpRectF = new RectF();
         float[] mTmpOffset = new float[2];
         ExtractedTextRequest mExtractedTextRequest;
         final ExtractedText mExtractedText = new ExtractedText();
diff --git a/core/java/android/widget/FastScroller.java b/core/java/android/widget/FastScroller.java
index c0961fd..06b7a93 100644
--- a/core/java/android/widget/FastScroller.java
+++ b/core/java/android/widget/FastScroller.java
@@ -79,6 +79,7 @@
     // Positions for preview image and text.
     private static final int OVERLAY_FLOATING = 0;
     private static final int OVERLAY_AT_THUMB = 1;
+    private static final int OVERLAY_ABOVE_THUMB = 2;
 
     // Indices for mPreviewResId.
     private static final int PREVIEW_LEFT = 0;
@@ -189,8 +190,9 @@
     /**
      * Position for the preview image and text. One of:
      * <ul>
-     * <li>{@link #OVERLAY_AT_THUMB}
      * <li>{@link #OVERLAY_FLOATING}
+     * <li>{@link #OVERLAY_AT_THUMB}
+     * <li>{@link #OVERLAY_ABOVE_THUMB}
      * </ul>
      */
     private int mOverlayPosition;
@@ -310,8 +312,10 @@
         final int textMinSize = Math.max(0, mPreviewMinHeight);
         mPrimaryText.setMinimumWidth(textMinSize);
         mPrimaryText.setMinimumHeight(textMinSize);
+        mPrimaryText.setIncludeFontPadding(false);
         mSecondaryText.setMinimumWidth(textMinSize);
         mSecondaryText.setMinimumHeight(textMinSize);
+        mSecondaryText.setIncludeFontPadding(false);
 
         refreshDrawablePressedState();
     }
@@ -595,10 +599,10 @@
         margins.right = mPreviewImage.getPaddingRight();
         margins.bottom = mPreviewImage.getPaddingBottom();
 
-        if (mOverlayPosition == OVERLAY_AT_THUMB) {
-            measureViewToSide(v, mThumbImage, margins, out);
-        } else {
+        if (mOverlayPosition == OVERLAY_FLOATING) {
             measureFloating(v, margins, out);
+        } else {
+            measureViewToSide(v, mThumbImage, margins, out);
         }
     }
 
@@ -1147,11 +1151,23 @@
         final float thumbMiddle = position * range + offset;
         thumbImage.setTranslationY(thumbMiddle - thumbImage.getHeight() / 2);
 
-        final float previewPos = mOverlayPosition == OVERLAY_AT_THUMB ? thumbMiddle : 0;
-
-        // Center the preview on the thumb, constrained to the list bounds.
         final View previewImage = mPreviewImage;
         final float previewHalfHeight = previewImage.getHeight() / 2f;
+        final float previewPos;
+        switch (mOverlayPosition) {
+            case OVERLAY_AT_THUMB:
+                previewPos = thumbMiddle;
+                break;
+            case OVERLAY_ABOVE_THUMB:
+                previewPos = thumbMiddle - previewHalfHeight;
+                break;
+            case OVERLAY_FLOATING:
+            default:
+                previewPos = 0;
+                break;
+        }
+
+        // Center the preview on the thumb, constrained to the list bounds.
         final float minP = top + previewHalfHeight;
         final float maxP = bottom - previewHalfHeight;
         final float previewMiddle = MathUtils.constrain(previewPos, minP, maxP);
diff --git a/core/java/android/widget/FrameLayout.java b/core/java/android/widget/FrameLayout.java
index 4fb7e62..235e79f 100644
--- a/core/java/android/widget/FrameLayout.java
+++ b/core/java/android/widget/FrameLayout.java
@@ -68,8 +68,9 @@
     @ViewDebug.ExportedProperty(category = "drawing")
     private Drawable mForeground;
     private ColorStateList mForegroundTintList = null;
-    private PorterDuff.Mode mForegroundTintMode = PorterDuff.Mode.SRC_ATOP;
+    private PorterDuff.Mode mForegroundTintMode = null;
     private boolean mHasForegroundTint = false;
+    private boolean mHasForegroundTintMode = false;
 
     @ViewDebug.ExportedProperty(category = "padding")
     private int mForegroundPaddingLeft = 0;
@@ -127,20 +128,22 @@
             setMeasureAllChildren(true);
         }
 
-        mForegroundTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.FrameLayout_foregroundTintMode, -1), mForegroundTintMode);
+        if (a.hasValue(R.styleable.FrameLayout_foregroundTintMode)) {
+            mForegroundTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.FrameLayout_foregroundTintMode, -1), mForegroundTintMode);
+            mHasForegroundTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.FrameLayout_foregroundTint)) {
             mForegroundTintList = a.getColorStateList(R.styleable.FrameLayout_foregroundTint);
             mHasForegroundTint = true;
-
-            applyForegroundTint();
         }
 
-        mForegroundInPadding = a.getBoolean(
-                com.android.internal.R.styleable.FrameLayout_foregroundInsidePadding, true);
+        mForegroundInPadding = a.getBoolean(R.styleable.FrameLayout_foregroundInsidePadding, true);
 
         a.recycle();
+
+        applyForegroundTint();
     }
 
     /**
@@ -302,7 +305,7 @@
 
     /**
      * Applies a tint to the foreground drawable. Does not modify the current
-     * tint mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * tint mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setForeground(Drawable)} will automatically
      * mutate the drawable and apply the specified tint and tint mode using
@@ -334,7 +337,7 @@
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setForegroundTintList(ColorStateList)}} to the foreground drawable.
-     * The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -344,6 +347,7 @@
      */
     public void setForegroundTintMode(@Nullable PorterDuff.Mode tintMode) {
         mForegroundTintMode = tintMode;
+        mHasForegroundTintMode = true;
 
         applyForegroundTint();
     }
@@ -360,10 +364,16 @@
     }
 
     private void applyForegroundTint() {
-        if (mForeground != null && mHasForegroundTint) {
+        if (mForeground != null && (mHasForegroundTint || mHasForegroundTintMode)) {
             mForeground = mForeground.mutate();
-            mForeground.setTintList(mForegroundTintList);
-            mForeground.setTintMode(mForegroundTintMode);
+
+            if (mHasForegroundTint) {
+                mForeground.setTintList(mForegroundTintList);
+            }
+
+            if (mHasForegroundTintMode) {
+                mForeground.setTintMode(mForegroundTintMode);
+            }
         }
     }
 
diff --git a/core/java/android/widget/GridView.java b/core/java/android/widget/GridView.java
index d263625..efd6fc0 100644
--- a/core/java/android/widget/GridView.java
+++ b/core/java/android/widget/GridView.java
@@ -2356,7 +2356,7 @@
         final int rowsCount = getCount() / columnsCount;
         final int selectionMode = getSelectionModeForAccessibility();
         final CollectionInfo collectionInfo = CollectionInfo.obtain(
-                columnsCount, rowsCount, false, selectionMode);
+                rowsCount, columnsCount, false, selectionMode);
         info.setCollectionInfo(collectionInfo);
     }
 
@@ -2385,7 +2385,7 @@
         final boolean isHeading = lp != null && lp.viewType != ITEM_VIEW_TYPE_HEADER_OR_FOOTER;
         final boolean isSelected = isItemChecked(position);
         final CollectionItemInfo itemInfo = CollectionItemInfo.obtain(
-                column, 1, row, 1, isHeading, isSelected);
+                row, 1, column, 1, isHeading, isSelected);
         info.setCollectionItemInfo(itemInfo);
     }
 }
diff --git a/core/java/android/widget/ImageView.java b/core/java/android/widget/ImageView.java
index 6a15078..f90a9fe 100644
--- a/core/java/android/widget/ImageView.java
+++ b/core/java/android/widget/ImageView.java
@@ -87,9 +87,10 @@
     private boolean mColorMod = false;
 
     private Drawable mDrawable = null;
-    private ColorStateList mDrawableTint = null;
-    private PorterDuff.Mode mDrawableTintMode = PorterDuff.Mode.SRC_ATOP;
+    private ColorStateList mDrawableTintList = null;
+    private PorterDuff.Mode mDrawableTintMode = null;
     private boolean mHasDrawableTint = false;
+    private boolean mHasDrawableTintMode = false;
 
     private int[] mState = null;
     private boolean mMergeState = false;
@@ -168,16 +169,24 @@
             setScaleType(sScaleTypeArray[index]);
         }
 
-        mDrawableTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.ImageView_tintMode, -1), mDrawableTintMode);
-
         if (a.hasValue(R.styleable.ImageView_tint)) {
-            mDrawableTint = a.getColorStateList(R.styleable.ImageView_tint);
+            mDrawableTintList = a.getColorStateList(R.styleable.ImageView_tint);
             mHasDrawableTint = true;
 
-            applyImageTint();
+            // Prior to L, this attribute would always set a color filter with
+            // blending mode SRC_ATOP. Preserve that default behavior.
+            mDrawableTintMode = PorterDuff.Mode.SRC_ATOP;
+            mHasDrawableTintMode = true;
         }
 
+        if (a.hasValue(R.styleable.ImageView_tintMode)) {
+            mDrawableTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.ImageView_tintMode, -1), mDrawableTintMode);
+            mHasDrawableTintMode = true;
+        }
+
+        applyImageTint();
+
         final int alpha = a.getInt(com.android.internal.R.styleable.ImageView_drawableAlpha, 255);
         if (alpha != 255) {
             setAlpha(alpha);
@@ -450,7 +459,7 @@
 
     /**
      * Applies a tint to the image drawable. Does not modify the current tint
-     * mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setImageDrawable(Drawable)} will automatically
      * mutate the drawable and apply the specified tint and tint mode using
@@ -463,7 +472,7 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setImageTintList(@Nullable ColorStateList tint) {
-        mDrawableTint = tint;
+        mDrawableTintList = tint;
         mHasDrawableTint = true;
 
         applyImageTint();
@@ -476,13 +485,13 @@
      */
     @Nullable
     public ColorStateList getImageTintList() {
-        return mDrawableTint;
+        return mDrawableTintList;
     }
 
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setImageTintList(ColorStateList)}} to the image drawable. The default
-     * mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -492,6 +501,7 @@
      */
     public void setImageTintMode(@Nullable PorterDuff.Mode tintMode) {
         mDrawableTintMode = tintMode;
+        mHasDrawableTintMode = true;
 
         applyImageTint();
     }
@@ -507,10 +517,16 @@
     }
 
     private void applyImageTint() {
-        if (mDrawable != null && mHasDrawableTint) {
+        if (mDrawable != null && (mHasDrawableTint || mHasDrawableTintMode)) {
             mDrawable = mDrawable.mutate();
-            mDrawable.setTintList(mDrawableTint);
-            mDrawable.setTintMode(mDrawableTintMode);
+
+            if (mHasDrawableTint) {
+                mDrawable.setTintList(mDrawableTintList);
+            }
+
+            if (mHasDrawableTintMode) {
+                mDrawable.setTintMode(mDrawableTintMode);
+            }
         }
     }
 
diff --git a/core/java/android/widget/ListPopupWindow.java b/core/java/android/widget/ListPopupWindow.java
index 6a514ba..3c186e3 100644
--- a/core/java/android/widget/ListPopupWindow.java
+++ b/core/java/android/widget/ListPopupWindow.java
@@ -20,6 +20,7 @@
 import android.animation.AnimatorListenerAdapter;
 import android.animation.ObjectAnimator;
 import android.content.Context;
+import android.content.res.TypedArray;
 import android.database.DataSetObserver;
 import android.graphics.Rect;
 import android.graphics.drawable.Drawable;
@@ -40,6 +41,7 @@
 import android.view.ViewParent;
 import android.view.animation.AccelerateDecelerateInterpolator;
 
+import com.android.internal.R;
 import com.android.internal.widget.AutoScrollHelper.AbsListViewAutoScroller;
 
 import java.util.Locale;
@@ -208,6 +210,18 @@
      */
     public ListPopupWindow(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
         mContext = context;
+
+        final TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.ListPopupWindow,
+                defStyleAttr, defStyleRes);
+        mDropDownHorizontalOffset = a.getDimensionPixelOffset(
+                R.styleable.ListPopupWindow_dropDownHorizontalOffset, 0);
+        mDropDownVerticalOffset = a.getDimensionPixelOffset(
+                R.styleable.ListPopupWindow_dropDownVerticalOffset, 0);
+        if (mDropDownVerticalOffset != 0) {
+            mDropDownVerticalOffsetSet = true;
+        }
+        a.recycle();
+
         mPopup = new PopupWindow(context, attrs, defStyleAttr, defStyleRes);
         mPopup.setInputMethodMode(PopupWindow.INPUT_METHOD_NEEDED);
         // Set the default layout direction to match the default locale one
diff --git a/core/java/android/widget/ListView.java b/core/java/android/widget/ListView.java
index 1368cd3..2e9858c 100644
--- a/core/java/android/widget/ListView.java
+++ b/core/java/android/widget/ListView.java
@@ -3882,9 +3882,10 @@
         super.onInitializeAccessibilityNodeInfo(info);
         info.setClassName(ListView.class.getName());
 
-        final int count = getCount();
+        final int rowsCount = getCount();
         final int selectionMode = getSelectionModeForAccessibility();
-        final CollectionInfo collectionInfo = CollectionInfo.obtain(1, count, false, selectionMode);
+        final CollectionInfo collectionInfo = CollectionInfo.obtain(
+                rowsCount, 1, false, selectionMode);
         info.setCollectionInfo(collectionInfo);
     }
 
@@ -3897,7 +3898,7 @@
         final boolean isHeading = lp != null && lp.viewType != ITEM_VIEW_TYPE_HEADER_OR_FOOTER;
         final boolean isSelected = isItemChecked(position);
         final CollectionItemInfo itemInfo = CollectionItemInfo.obtain(
-                0, 1, position, 1, isHeading, isSelected);
+                position, 1, 0, 1, isHeading, isSelected);
         info.setCollectionItemInfo(itemInfo);
     }
 }
diff --git a/core/java/android/widget/ProgressBar.java b/core/java/android/widget/ProgressBar.java
index c0fa6e5..e9298c2 100644
--- a/core/java/android/widget/ProgressBar.java
+++ b/core/java/android/widget/ProgressBar.java
@@ -216,25 +216,10 @@
     private boolean mHasAnimation;
 
     private Drawable mIndeterminateDrawable;
-    private ColorStateList mIndeterminateTintList = null;
-    private PorterDuff.Mode mIndeterminateTintMode = PorterDuff.Mode.SRC_ATOP;
-    private boolean mHasIndeterminateTint = false;
-
     private Drawable mProgressDrawable;
-
-    private ColorStateList mProgressTintList = null;
-    private PorterDuff.Mode mProgressTintMode = PorterDuff.Mode.SRC_ATOP;
-    private boolean mHasProgressTint = false;
-
-    private ColorStateList mProgressBackgroundTintList = null;
-    private PorterDuff.Mode mProgressBackgroundTintMode = PorterDuff.Mode.SRC_ATOP;
-    private boolean mHasProgressBackgroundTint = false;
-
-    private ColorStateList mSecondaryProgressTintList = null;
-    private PorterDuff.Mode mSecondaryProgressTintMode = PorterDuff.Mode.SRC_ATOP;
-    private boolean mHasSecondaryProgressTint = false;
-
     private Drawable mCurrentDrawable;
+    private ProgressTintInfo mProgressTintInfo;
+
     Bitmap mSampleTile;
     private boolean mNoInvalidate;
     private Interpolator mInterpolator;
@@ -328,55 +313,83 @@
 
         mMirrorForRtl = a.getBoolean(R.styleable.ProgressBar_mirrorForRtl, mMirrorForRtl);
 
-        mProgressTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.ProgressBar_progressBackgroundTintMode, -1), mProgressTintMode);
+        if (a.hasValue(R.styleable.ProgressBar_progressTintMode)) {
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mProgressTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.ProgressBar_progressBackgroundTintMode, -1), null);
+            mProgressTintInfo.mHasProgressTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.ProgressBar_progressTint)) {
-            mProgressTintList = a.getColorStateList(
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mProgressTintList = a.getColorStateList(
                     R.styleable.ProgressBar_progressTint);
-            mHasProgressTint = true;
-
-            applyProgressLayerTint(R.id.progress, mProgressTintList,
-                    mProgressTintMode, true);
+            mProgressTintInfo.mHasProgressTint = true;
         }
 
-        mProgressBackgroundTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.ProgressBar_progressTintMode, -1), mProgressBackgroundTintMode);
+        if (a.hasValue(R.styleable.ProgressBar_progressBackgroundTintMode)) {
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mProgressBackgroundTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.ProgressBar_progressTintMode, -1), null);
+            mProgressTintInfo.mHasProgressBackgroundTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.ProgressBar_progressBackgroundTint)) {
-            mProgressBackgroundTintList = a.getColorStateList(
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mProgressBackgroundTintList = a.getColorStateList(
                     R.styleable.ProgressBar_progressBackgroundTint);
-            mHasProgressBackgroundTint = true;
-
-            applyProgressLayerTint(R.id.background, mProgressBackgroundTintList,
-                    mProgressBackgroundTintMode, false);
+            mProgressTintInfo.mHasProgressBackgroundTint = true;
         }
 
-        mSecondaryProgressTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.ProgressBar_secondaryProgressTintMode, -1), mSecondaryProgressTintMode);
+        if (a.hasValue(R.styleable.ProgressBar_secondaryProgressTintMode)) {
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mSecondaryProgressTintMode = Drawable.parseTintMode(
+                    a.getInt(R.styleable.ProgressBar_secondaryProgressTintMode, -1), null);
+            mProgressTintInfo.mHasSecondaryProgressTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.ProgressBar_secondaryProgressTint)) {
-            mSecondaryProgressTintList = a.getColorStateList(
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mSecondaryProgressTintList = a.getColorStateList(
                     R.styleable.ProgressBar_secondaryProgressTint);
-            mHasSecondaryProgressTint = true;
-
-            applyProgressLayerTint(R.id.secondaryProgress, mSecondaryProgressTintList,
-                    mSecondaryProgressTintMode, false);
+            mProgressTintInfo.mHasSecondaryProgressTint = true;
         }
 
-        mIndeterminateTintMode = Drawable.parseTintMode(a.getInt(
-                R.styleable.ProgressBar_indeterminateTintMode, -1), mIndeterminateTintMode);
+        if (a.hasValue(R.styleable.ProgressBar_indeterminateTint)) {
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mIndeterminateTintMode = Drawable.parseTintMode(a.getInt(
+                    R.styleable.ProgressBar_indeterminateTintMode, -1), null);
+            mProgressTintInfo.mHasIndeterminateTintMode = true;
+        }
 
         if (a.hasValue(R.styleable.ProgressBar_indeterminateTint)) {
-            mIndeterminateTintList = a.getColorStateList(
+            if (mProgressTintInfo == null) {
+                mProgressTintInfo = new ProgressTintInfo();
+            }
+            mProgressTintInfo.mIndeterminateTintList = a.getColorStateList(
                     R.styleable.ProgressBar_indeterminateTint);
-            mHasIndeterminateTint = true;
-
-            applyIndeterminateTint();
+            mProgressTintInfo.mHasIndeterminateTint = true;
         }
 
         a.recycle();
 
+        applyProgressTints();
+        applyIndeterminateTint();
+
         // If not explicitly specified this view is important for accessibility.
         if (getImportantForAccessibility() == View.IMPORTANT_FOR_ACCESSIBILITY_AUTO) {
             setImportantForAccessibility(View.IMPORTANT_FOR_ACCESSIBILITY_YES);
@@ -578,7 +591,7 @@
 
     /**
      * Applies a tint to the indeterminate drawable. Does not modify the
-     * current tint mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * current tint mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * Subsequent calls to {@link #setIndeterminateDrawable(Drawable)} will
      * automatically mutate the drawable and apply the specified tint and
@@ -592,8 +605,11 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setIndeterminateTintList(@Nullable ColorStateList tint) {
-        mIndeterminateTintList = tint;
-        mHasIndeterminateTint = true;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mIndeterminateTintList = tint;
+        mProgressTintInfo.mHasIndeterminateTint = true;
 
         applyIndeterminateTint();
     }
@@ -605,13 +621,13 @@
      */
     @Nullable
     public ColorStateList getIndeterminateTintList() {
-        return mIndeterminateTintList;
+        return mProgressTintInfo != null ? mProgressTintInfo.mIndeterminateTintList : null;
     }
 
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setIndeterminateTintList(ColorStateList)} to the indeterminate
-     * drawable. The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * drawable. The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -620,26 +636,43 @@
      * @see Drawable#setTintMode(PorterDuff.Mode)
      */
     public void setIndeterminateTintMode(@Nullable PorterDuff.Mode tintMode) {
-        mIndeterminateTintMode = tintMode;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mIndeterminateTintMode = tintMode;
+        mProgressTintInfo.mHasIndeterminateTintMode = true;
 
         applyIndeterminateTint();
     }
 
     /**
-     * @return the blending mode used to apply the tint to the indeterminate drawable
+     * Returns the blending mode used to apply the tint to the indeterminate
+     * drawable, if specified.
+     *
+     * @return the blending mode used to apply the tint to the indeterminate
+     *         drawable
      * @attr ref android.R.styleable#ProgressBar_indeterminateTintMode
      * @see #setIndeterminateTintMode(PorterDuff.Mode)
      */
     @Nullable
     public PorterDuff.Mode getIndeterminateTintMode() {
-        return mIndeterminateTintMode;
+        return mProgressTintInfo != null ? mProgressTintInfo.mIndeterminateTintMode : null;
     }
 
     private void applyIndeterminateTint() {
-        if (mIndeterminateDrawable != null && mHasIndeterminateTint) {
-            mIndeterminateDrawable = mIndeterminateDrawable.mutate();
-            mIndeterminateDrawable.setTintList(mIndeterminateTintList);
-            mIndeterminateDrawable.setTintMode(mIndeterminateTintMode);
+        if (mIndeterminateDrawable != null && mProgressTintInfo != null) {
+            final ProgressTintInfo tintInfo = mProgressTintInfo;
+            if (tintInfo.mHasIndeterminateTint || tintInfo.mHasIndeterminateTintMode) {
+                mIndeterminateDrawable = mIndeterminateDrawable.mutate();
+
+                if (tintInfo.mHasIndeterminateTint) {
+                    mIndeterminateDrawable.setTintList(tintInfo.mIndeterminateTintList);
+                }
+
+                if (tintInfo.mHasIndeterminateTintMode) {
+                    mIndeterminateDrawable.setTintMode(tintInfo.mIndeterminateTintMode);
+                }
+            }
         }
     }
 
@@ -705,20 +738,7 @@
                     requestLayout();
                 }
 
-                if (mHasProgressTint) {
-                    applyProgressLayerTint(R.id.progress, mProgressTintList,
-                            mProgressTintMode, true);
-                }
-
-                if (mHasProgressBackgroundTint) {
-                    applyProgressLayerTint(R.id.background, mProgressBackgroundTintList,
-                            mProgressBackgroundTintMode, false);
-                }
-
-                if (mHasSecondaryProgressTint) {
-                    applyProgressLayerTint(R.id.secondaryProgress, mSecondaryProgressTintList,
-                            mSecondaryProgressTintMode, false);
-                }
+                applyProgressTints();
             }
 
             if (!mIndeterminate) {
@@ -735,9 +755,77 @@
     }
 
     /**
+     * Applies the progress tints in order of increasing specificity.
+     */
+    private void applyProgressTints() {
+        if (mProgressDrawable != null && mProgressTintInfo != null) {
+            applyPrimaryProgressTint();
+            applyProgressBackgroundTint();
+            applySecondaryProgressTint();
+        }
+    }
+
+    /**
+     * Should only be called if we've already verified that mProgressDrawable
+     * and mProgressTintInfo are non-null.
+     */
+    private void applyPrimaryProgressTint() {
+        if (mProgressTintInfo.mHasProgressTint
+                || mProgressTintInfo.mHasProgressTintMode) {
+            final Drawable target = getTintTarget(R.id.progress, true);
+            if (target != null) {
+                if (mProgressTintInfo.mHasProgressTint) {
+                    target.setTintList(mProgressTintInfo.mProgressTintList);
+                }
+                if (mProgressTintInfo.mHasProgressTintMode) {
+                    target.setTintMode(mProgressTintInfo.mProgressTintMode);
+                }
+            }
+        }
+    }
+
+    /**
+     * Should only be called if we've already verified that mProgressDrawable
+     * and mProgressTintInfo are non-null.
+     */
+    private void applyProgressBackgroundTint() {
+        if (mProgressTintInfo.mHasProgressBackgroundTint
+                || mProgressTintInfo.mHasProgressBackgroundTintMode) {
+            final Drawable target = getTintTarget(R.id.background, false);
+            if (target != null) {
+                if (mProgressTintInfo.mHasProgressBackgroundTint) {
+                    target.setTintList(mProgressTintInfo.mProgressBackgroundTintList);
+                }
+                if (mProgressTintInfo.mHasProgressBackgroundTintMode) {
+                    target.setTintMode(mProgressTintInfo.mProgressBackgroundTintMode);
+                }
+            }
+        }
+    }
+
+    /**
+     * Should only be called if we've already verified that mProgressDrawable
+     * and mProgressTintInfo are non-null.
+     */
+    private void applySecondaryProgressTint() {
+        if (mProgressTintInfo.mHasSecondaryProgressTint
+                || mProgressTintInfo.mHasSecondaryProgressTintMode) {
+            final Drawable target = getTintTarget(R.id.secondaryProgress, false);
+            if (target != null) {
+                if (mProgressTintInfo.mHasSecondaryProgressTint) {
+                    target.setTintList(mProgressTintInfo.mSecondaryProgressTintList);
+                }
+                if (mProgressTintInfo.mHasSecondaryProgressTintMode) {
+                    target.setTintMode(mProgressTintInfo.mSecondaryProgressTintMode);
+                }
+            }
+        }
+    }
+
+    /**
      * Applies a tint to the progress indicator, if one exists, or to the
      * entire progress drawable otherwise. Does not modify the current tint
-     * mode, which is {@link PorterDuff.Mode#SRC_ATOP} by default.
+     * mode, which is {@link PorterDuff.Mode#SRC_IN} by default.
      * <p>
      * The progress indicator should be specified as a layer with
      * id {@link android.R.id#progress} in a {@link LayerDrawable}
@@ -755,26 +843,33 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setProgressTintList(@Nullable ColorStateList tint) {
-        mProgressTintList = tint;
-        mHasProgressTint = true;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mProgressTintList = tint;
+        mProgressTintInfo.mHasProgressTint = true;
 
-        applyProgressLayerTint(R.id.progress, tint, mProgressTintMode, true);
+        if (mProgressDrawable != null) {
+            applyPrimaryProgressTint();
+        }
     }
 
     /**
+     * Returns the tint applied to the progress drawable, if specified.
+     *
      * @return the tint applied to the progress drawable
      * @attr ref android.R.styleable#ProgressBar_progressTint
      * @see #setProgressTintList(ColorStateList)
      */
     @Nullable
     public ColorStateList getProgressTintList() {
-        return mProgressTintList;
+        return mProgressTintInfo != null ? mProgressTintInfo.mProgressTintList : null;
     }
 
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setProgressTintList(ColorStateList)}} to the progress
-     * indicator. The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * indicator. The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -783,19 +878,29 @@
      * @see Drawable#setTintMode(PorterDuff.Mode)
      */
     public void setProgressTintMode(@Nullable PorterDuff.Mode tintMode) {
-        mProgressTintMode = tintMode;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mProgressTintMode = tintMode;
+        mProgressTintInfo.mHasProgressTintMode = true;
 
-        applyProgressLayerTint(R.id.progress, mProgressTintList, tintMode, true);
+        if (mProgressDrawable != null) {
+            applyPrimaryProgressTint();
+        }
     }
 
     /**
-     * @return the blending mode used to apply the tint to the progress drawable
+     * Returns the blending mode used to apply the tint to the progress
+     * drawable, if specified.
+     *
+     * @return the blending mode used to apply the tint to the progress
+     *         drawable
      * @attr ref android.R.styleable#ProgressBar_progressTintMode
      * @see #setProgressTintMode(PorterDuff.Mode)
      */
     @Nullable
     public PorterDuff.Mode getProgressTintMode() {
-        return mProgressTintMode;
+        return mProgressTintInfo != null ? mProgressTintInfo.mProgressTintMode : null;
     }
 
     /**
@@ -819,26 +924,33 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setProgressBackgroundTintList(@Nullable ColorStateList tint) {
-        mProgressBackgroundTintList = tint;
-        mHasProgressBackgroundTint = true;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mProgressBackgroundTintList = tint;
+        mProgressTintInfo.mHasProgressBackgroundTint = true;
 
-        applyProgressLayerTint(R.id.background, tint, mProgressBackgroundTintMode, false);
+        if (mProgressDrawable != null) {
+            applyProgressBackgroundTint();
+        }
     }
 
     /**
+     * Returns the tint applied to the progress background, if specified.
+     *
      * @return the tint applied to the progress background
      * @attr ref android.R.styleable#ProgressBar_progressBackgroundTint
      * @see #setProgressBackgroundTintList(ColorStateList)
      */
     @Nullable
     public ColorStateList getProgressBackgroundTintList() {
-        return mProgressBackgroundTintList;
+        return mProgressTintInfo != null ? mProgressTintInfo.mProgressBackgroundTintList : null;
     }
 
     /**
      * Specifies the blending mode used to apply the tint specified by
      * {@link #setProgressBackgroundTintList(ColorStateList)}} to the progress
-     * background. The default mode is {@link PorterDuff.Mode#SRC_ATOP}.
+     * background. The default mode is {@link PorterDuff.Mode#SRC_IN}.
      *
      * @param tintMode the blending mode used to apply the tint, may be
      *                 {@code null} to clear tint
@@ -847,9 +959,15 @@
      * @see Drawable#setTintMode(PorterDuff.Mode)
      */
     public void setProgressBackgroundTintMode(@Nullable PorterDuff.Mode tintMode) {
-        mProgressBackgroundTintMode = tintMode;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mProgressBackgroundTintMode = tintMode;
+        mProgressTintInfo.mHasProgressBackgroundTintMode = true;
 
-        applyProgressLayerTint(R.id.background, mProgressBackgroundTintList, tintMode, false);
+        if (mProgressDrawable != null) {
+            applyProgressBackgroundTint();
+        }
     }
 
     /**
@@ -860,7 +978,7 @@
      */
     @Nullable
     public PorterDuff.Mode getProgressBackgroundTintMode() {
-        return mProgressBackgroundTintMode;
+        return mProgressTintInfo != null ? mProgressTintInfo.mProgressBackgroundTintMode : null;
     }
 
     /**
@@ -884,20 +1002,28 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setSecondaryProgressTintList(@Nullable ColorStateList tint) {
-        mSecondaryProgressTintList = tint;
-        mHasSecondaryProgressTint = true;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mSecondaryProgressTintList = tint;
+        mProgressTintInfo.mHasSecondaryProgressTint = true;
 
-        applyProgressLayerTint(R.id.secondaryProgress, tint, mSecondaryProgressTintMode, false);
+        if (mProgressDrawable != null) {
+            applySecondaryProgressTint();
+        }
     }
 
     /**
+     * Returns the tint applied to the secondary progress drawable, if
+     * specified.
+     *
      * @return the tint applied to the secondary progress drawable
      * @attr ref android.R.styleable#ProgressBar_secondaryProgressTint
      * @see #setSecondaryProgressTintList(ColorStateList)
      */
     @Nullable
     public ColorStateList getSecondaryProgressTintList() {
-        return mSecondaryProgressTintList;
+        return mProgressTintInfo != null ? mProgressTintInfo.mSecondaryProgressTintList : null;
     }
 
     /**
@@ -913,12 +1039,21 @@
      * @see Drawable#setTintMode(PorterDuff.Mode)
      */
     public void setSecondaryProgressTintMode(@Nullable PorterDuff.Mode tintMode) {
-        mSecondaryProgressTintMode = tintMode;
+        if (mProgressTintInfo == null) {
+            mProgressTintInfo = new ProgressTintInfo();
+        }
+        mProgressTintInfo.mSecondaryProgressTintMode = tintMode;
+        mProgressTintInfo.mHasSecondaryProgressTintMode = true;
 
-        applyProgressLayerTint(R.id.secondaryProgress, mSecondaryProgressTintList, tintMode, false);
+        if (mProgressDrawable != null) {
+            applySecondaryProgressTint();
+        }
     }
 
     /**
+     * Returns the blending mode used to apply the tint to the secondary
+     * progress drawable, if specified.
+     *
      * @return the blending mode used to apply the tint to the secondary
      *         progress drawable
      * @attr ref android.R.styleable#ProgressBar_secondaryProgressTintMode
@@ -926,16 +1061,25 @@
      */
     @Nullable
     public PorterDuff.Mode getSecondaryProgressTintMode() {
-        return mSecondaryProgressTintMode;
+        return mProgressTintInfo != null ? mProgressTintInfo.mSecondaryProgressTintMode : null;
     }
 
-    private void applyProgressLayerTint(int layerId, @Nullable ColorStateList tint,
-            @Nullable PorterDuff.Mode tintMode, boolean shouldFallback) {
+    /**
+     * Returns the drawable to which a tint or tint mode should be applied.
+     *
+     * @param layerId id of the layer to modify
+     * @param shouldFallback whether the base drawable should be returned
+     *                       if the id does not exist
+     * @return the drawable to modify
+     */
+    @Nullable
+    private Drawable getTintTarget(int layerId, boolean shouldFallback) {
+        Drawable layer = null;
+
         final Drawable d = mProgressDrawable;
         if (d != null) {
             mProgressDrawable = d.mutate();
 
-            Drawable layer = null;
             if (d instanceof LayerDrawable) {
                 layer = ((LayerDrawable) d).findDrawableByLayerId(layerId);
             }
@@ -943,12 +1087,9 @@
             if (shouldFallback && layer == null) {
                 layer = d;
             }
-
-            if (layer != null) {
-                layer.setTintList(tint);
-                layer.setTintMode(tintMode);
-            }
         }
+
+        return layer;
     }
 
     /**
@@ -1748,4 +1889,26 @@
             sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_SELECTED);
         }
     }
+
+    private static class ProgressTintInfo {
+        ColorStateList mIndeterminateTintList;
+        PorterDuff.Mode mIndeterminateTintMode;
+        boolean mHasIndeterminateTint;
+        boolean mHasIndeterminateTintMode;
+
+        ColorStateList mProgressTintList;
+        PorterDuff.Mode mProgressTintMode;
+        boolean mHasProgressTint;
+        boolean mHasProgressTintMode;
+
+        ColorStateList mProgressBackgroundTintList;
+        PorterDuff.Mode mProgressBackgroundTintMode;
+        boolean mHasProgressBackgroundTint;
+        boolean mHasProgressBackgroundTintMode;
+
+        ColorStateList mSecondaryProgressTintList;
+        PorterDuff.Mode mSecondaryProgressTintMode;
+        boolean mHasSecondaryProgressTint;
+        boolean mHasSecondaryProgressTintMode;
+    }
 }
diff --git a/core/java/android/widget/RadialTimePickerView.java b/core/java/android/widget/RadialTimePickerView.java
index adca4cc..0460282 100644
--- a/core/java/android/widget/RadialTimePickerView.java
+++ b/core/java/android/widget/RadialTimePickerView.java
@@ -137,6 +137,11 @@
 
     private boolean mIs24HourMode;
     private boolean mShowHours;
+
+    /**
+     * When in 24-hour mode, indicates that the current hour is between
+     * 1 and 12 (inclusive).
+     */
     private boolean mIsOnInnerCircle;
 
     private int mXCenter;
@@ -458,6 +463,7 @@
         a.recycle();
 
         setOnTouchListener(this);
+        setClickable(true);
 
         // Initial values
         final Calendar calendar = Calendar.getInstance(Locale.getDefault());
@@ -512,49 +518,53 @@
         mListener = listener;
     }
 
+    /**
+     * Sets the current hour in 24-hour time.
+     *
+     * @param hour the current hour between 0 and 23 (inclusive)
+     */
     public void setCurrentHour(int hour) {
         final int degrees = (hour % 12) * DEGREES_FOR_ONE_HOUR;
         mSelectionDegrees[HOURS] = degrees;
         mSelectionDegrees[HOURS_INNER] = degrees;
-        mAmOrPm = ((hour % 24) < 12) ? AM : PM;
+
+        // 0 is 12 AM (midnight) and 12 is 12 PM (noon).
+        mAmOrPm = (hour == 0 || (hour % 24) < 12) ? AM : PM;
+
         if (mIs24HourMode) {
-            mIsOnInnerCircle = (mAmOrPm == AM);
+            // Inner circle is 1 through 12.
+            mIsOnInnerCircle = hour >= 1 && hour <= 12;
         } else {
             mIsOnInnerCircle = false;
         }
+
         initData();
         updateLayoutData();
         invalidate();
     }
 
-    // Return hours in 0-23 range
+    /**
+     * Returns the current hour in 24-hour time.
+     *
+     * @return the current hour between 0 and 23 (inclusive)
+     */
     public int getCurrentHour() {
-        int hours =
-                mSelectionDegrees[mIsOnInnerCircle ? HOURS_INNER : HOURS] / DEGREES_FOR_ONE_HOUR;
+        int hour = (mSelectionDegrees[mIsOnInnerCircle ?
+                HOURS_INNER : HOURS] / DEGREES_FOR_ONE_HOUR) % 12;
         if (mIs24HourMode) {
-            if (mIsOnInnerCircle) {
-                hours = hours % 12;
-                if (hours == 0) {
-                    hours = 12;
-                }
-            } else {
-                if (hours != 0) {
-                    hours += 12;
-                }
+            // Convert the 12-hour value into 24-hour time based on where the
+            // selector is positioned.
+            if (mIsOnInnerCircle && hour == 0) {
+                // Inner circle is 1 through 12.
+                hour = 12;
+            } else if (hour != 0) {
+                // Outer circle is 13 through 23 and 0.
+                hour += 12;
             }
-        } else {
-            hours = hours % 12;
-            if (hours == 0) {
-                if (mAmOrPm == PM) {
-                    hours = 12;
-                }
-            } else {
-                if (mAmOrPm == PM) {
-                    hours += 12;
-                }
-            }
+        } else if (mAmOrPm == PM) {
+            hour += 12;
         }
-        return hours;
+        return hour;
     }
 
     public void setCurrentMinute(int minute) {
@@ -612,9 +622,9 @@
             mMinutesTexts[i] = String.format("%02d", MINUTES_NUMBERS[i]);
         }
 
-        String[] amPmTexts = new DateFormatSymbols().getAmPmStrings();
-        mAmPmText[AM] = amPmTexts[0];
-        mAmPmText[PM] = amPmTexts[1];
+        String[] amPmStrings = TimePickerClockDelegate.getAmPmStrings(mContext);
+        mAmPmText[AM] = amPmStrings[0];
+        mAmPmText[PM] = amPmStrings[1];
     }
 
     private void initData() {
diff --git a/core/java/android/widget/RelativeLayout.java b/core/java/android/widget/RelativeLayout.java
index 4dd7e07..23f911c 100644
--- a/core/java/android/widget/RelativeLayout.java
+++ b/core/java/android/widget/RelativeLayout.java
@@ -1501,7 +1501,7 @@
                     mRules[ALIGN_PARENT_START] = 0;
                 }
 
-                if (mRules[ALIGN_PARENT_RIGHT] == 0) {
+                if (mRules[ALIGN_PARENT_END] != 0) {
                     if (mRules[ALIGN_PARENT_RIGHT] == 0) {
                         // "right" rule is not defined but "end" rule is: use the "end" rule as the
                         // "right" rule
diff --git a/core/java/android/widget/RemoteViews.java b/core/java/android/widget/RemoteViews.java
index 8aef304..90e9c69 100644
--- a/core/java/android/widget/RemoteViews.java
+++ b/core/java/android/widget/RemoteViews.java
@@ -22,11 +22,13 @@
 import android.app.PendingIntent;
 import android.appwidget.AppWidgetHostView;
 import android.content.Context;
+import android.content.ContextWrapper;
 import android.content.Intent;
 import android.content.IntentSender;
 import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.res.Configuration;
+import android.content.res.Resources;
 import android.graphics.Bitmap;
 import android.graphics.PorterDuff;
 import android.graphics.Rect;
@@ -864,7 +866,7 @@
                 if (alpha != -1) {
                     targetDrawable.setAlpha(alpha);
                 }
-                if (colorFilter != -1 && filterMode != null) {
+                if (filterMode != null) {
                     targetDrawable.setColorFilter(colorFilter, filterMode);
                 }
                 if (level != -1) {
@@ -1653,8 +1655,10 @@
      *
      * @param application The application whose content is shown by the views.
      * @param layoutId The id of the layout resource.
+     *
+     * @hide
      */
-    private RemoteViews(ApplicationInfo application, int layoutId) {
+    protected RemoteViews(ApplicationInfo application, int layoutId) {
         mApplication = application;
         mLayoutId = layoutId;
         mBitmapCache = new BitmapCache();
@@ -2189,8 +2193,8 @@
      * @param alpha Specify an alpha value for the drawable, or -1 to leave
      *            unchanged.
      * @param colorFilter Specify a color for a
-     *            {@link android.graphics.ColorFilter} for this drawable, or -1
-     *            to leave unchanged.
+     *            {@link android.graphics.ColorFilter} for this drawable. This will be ignored if
+     *            {@code mode} is {@code null}.
      * @param mode Specify a PorterDuff mode for this drawable, or null to leave
      *            unchanged.
      * @param level Specify the level for the drawable, or -1 to leave
@@ -2515,15 +2519,29 @@
         RemoteViews rvToApply = getRemoteViewsToApply(context);
 
         View result;
-
-        Context c = prepareContext(context);
+        // RemoteViews may be built by an application installed in another
+        // user. So build a context that loads resources from that user but
+        // still returns the current users userId so settings like data / time formats
+        // are loaded without requiring cross user persmissions.
+        final Context contextForResources = getContextForResources(context);
+        Context inflationContext = new ContextWrapper(context) {
+            @Override
+            public Resources getResources() {
+                return contextForResources.getResources();
+            }
+            @Override
+            public Resources.Theme getTheme() {
+                return contextForResources.getTheme();
+            }
+        };
 
         LayoutInflater inflater = (LayoutInflater)
-                c.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
+                context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
 
-        inflater = inflater.cloneInContext(c);
+        // Clone inflater so we load resources from correct context and
+        // we don't add a filter to the static version returned by getSystemService.
+        inflater = inflater.cloneInContext(inflationContext);
         inflater.setFilter(this);
-
         result = inflater.inflate(rvToApply.getLayoutId(), parent, false);
 
         rvToApply.performApply(result, parent, handler);
@@ -2557,7 +2575,6 @@
             }
         }
 
-        prepareContext(context);
         rvToApply.performApply(v, (ViewGroup) v.getParent(), handler);
     }
 
@@ -2572,7 +2589,7 @@
         }
     }
 
-    private Context prepareContext(Context context) {
+    private Context getContextForResources(Context context) {
         if (mApplication != null) {
             if (context.getUserId() == UserHandle.getUserId(mApplication.uid)
                     && context.getPackageName().equals(mApplication.packageName)) {
@@ -2656,7 +2673,7 @@
         if (UserHandle.getUserId(applicationInfo.uid) != userId
                 || !applicationInfo.packageName.equals(packageName)) {
             try {
-                Context context = application.getApplicationContext().createPackageContextAsUser(
+                Context context = application.getBaseContext().createPackageContextAsUser(
                         packageName, 0, new UserHandle(userId));
                 applicationInfo = context.getApplicationInfo();
             } catch (NameNotFoundException nnfe) {
diff --git a/core/java/android/widget/RemoteViewsAdapter.java b/core/java/android/widget/RemoteViewsAdapter.java
index 5d21e0b..56bdb9b 100644
--- a/core/java/android/widget/RemoteViewsAdapter.java
+++ b/core/java/android/widget/RemoteViewsAdapter.java
@@ -157,7 +157,7 @@
                     RemoteViewsAdapter adapter;
                     final AppWidgetManager mgr = AppWidgetManager.getInstance(context);
                     if ((adapter = mAdapter.get()) != null) {
-                        mgr.bindRemoteViewsService(context.getPackageName(), appWidgetId,
+                        mgr.bindRemoteViewsService(context.getOpPackageName(), appWidgetId,
                                 intent, asBinder());
                     } else {
                         Slog.w(TAG, "bind: adapter was null");
@@ -176,7 +176,7 @@
                 RemoteViewsAdapter adapter;
                 final AppWidgetManager mgr = AppWidgetManager.getInstance(context);
                 if ((adapter = mAdapter.get()) != null) {
-                    mgr.unbindRemoteViewsService(context.getPackageName(), appWidgetId, intent);
+                    mgr.unbindRemoteViewsService(context.getOpPackageName(), appWidgetId, intent);
                 } else {
                     Slog.w(TAG, "unbind: adapter was null");
                 }
diff --git a/core/java/android/widget/SearchView.java b/core/java/android/widget/SearchView.java
index 0a3c7ff..dfdf606 100644
--- a/core/java/android/widget/SearchView.java
+++ b/core/java/android/widget/SearchView.java
@@ -262,7 +262,7 @@
                 attrs, R.styleable.SearchView, defStyleAttr, defStyleRes);
         final LayoutInflater inflater = (LayoutInflater) context.getSystemService(
                 Context.LAYOUT_INFLATER_SERVICE);
-        final int layoutResId = a.getResourceId(R.styleable.SearchView_layout, 0);
+        final int layoutResId = a.getResourceId(R.styleable.SearchView_layout, R.layout.search_view);
         inflater.inflate(layoutResId, this, true);
 
         mQueryTextView = (SearchAutoComplete) findViewById(R.id.search_src_text);
@@ -288,7 +288,8 @@
         mSearchHintIcon.setImageDrawable(a.getDrawable(R.styleable.SearchView_searchIcon));
 
         // Extract dropdown layout resource IDs for later use.
-        mSuggestionRowLayout = a.getResourceId(R.styleable.SearchView_suggestionRowLayout, 0);
+        mSuggestionRowLayout = a.getResourceId(R.styleable.SearchView_suggestionRowLayout,
+                R.layout.search_dropdown_item_icons_2line);
         mSuggestionCommitIconResId = a.getResourceId(R.styleable.SearchView_commitIcon, 0);
 
         mSearchButton.setOnClickListener(mOnClickListener);
@@ -334,6 +335,10 @@
             setInputType(inputType);
         }
 
+        boolean focusable = true;
+        focusable = a.getBoolean(R.styleable.SearchView_focusable, focusable);
+        setFocusable(focusable);
+
         a.recycle();
 
         // Save voice intent for later queries/launching
diff --git a/core/java/android/widget/SimpleMonthView.java b/core/java/android/widget/SimpleMonthView.java
index a0d9475..a76241e 100644
--- a/core/java/android/widget/SimpleMonthView.java
+++ b/core/java/android/widget/SimpleMonthView.java
@@ -18,6 +18,7 @@
 
 import android.content.Context;
 import android.content.res.ColorStateList;
+import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.graphics.Canvas;
 import android.graphics.Paint;
@@ -30,6 +31,7 @@
 import android.text.format.DateUtils;
 import android.text.format.Time;
 import android.util.AttributeSet;
+import android.util.MathUtils;
 import android.view.MotionEvent;
 import android.view.View;
 import android.view.accessibility.AccessibilityEvent;
@@ -38,6 +40,7 @@
 import com.android.internal.R;
 import com.android.internal.widget.ExploreByTouchHelper;
 
+import java.text.SimpleDateFormat;
 import java.util.Calendar;
 import java.util.Formatter;
 import java.util.List;
@@ -72,6 +75,9 @@
     // used for scaling to the device density
     private static float mScale = 0;
 
+    /** Single-letter (when available) formatter for the day of week label. */
+    private SimpleDateFormat mDayFormatter = new SimpleDateFormat("EEEEE", Locale.getDefault());
+
     // affects the padding on the sides of this view
     private int mPadding = 0;
 
@@ -181,6 +187,13 @@
         initView();
     }
 
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+
+        mDayFormatter = new SimpleDateFormat("EEEEE", newConfig.locale);
+    }
+
     void setTextColor(ColorStateList colors) {
         final Resources res = getContext().getResources();
 
@@ -288,7 +301,11 @@
     }
 
     private static boolean isValidDayOfWeek(int day) {
-        return (day >= Time.SUNDAY && day <= Time.SATURDAY);
+        return day >= Calendar.SUNDAY && day <= Calendar.SATURDAY;
+    }
+
+    private static boolean isValidMonth(int month) {
+        return month >= Calendar.JANUARY && month <= Calendar.DECEMBER;
     }
 
     /**
@@ -300,8 +317,8 @@
      * @param selectedDay the selected day of the month, or -1 for no selection.
      * @param month the month.
      * @param year the year.
-     * @param weekStart which day the week should start on. {@link Time#SUNDAY} through
-     *        {@link Time#SATURDAY}.
+     * @param weekStart which day the week should start on. {@link Calendar#SUNDAY} through
+     *        {@link Calendar#SATURDAY}.
      * @param enabledDayStart the first enabled day.
      * @param enabledDayEnd the last enabled day.
      */
@@ -313,7 +330,7 @@
 
         mSelectedDay = selectedDay;
 
-        if (month >= Calendar.JANUARY && month <= Calendar.DECEMBER) {
+        if (isValidMonth(month)) {
             mMonth = month;
         }
         mYear = year;
@@ -426,16 +443,16 @@
     }
 
     private void drawWeekDayLabels(Canvas canvas) {
-        int y = mMonthHeaderSize - (mMonthDayLabelTextSize / 2);
-        int dayWidthHalf = (mWidth - mPadding * 2) / (mNumDays * 2);
+        final int y = mMonthHeaderSize - (mMonthDayLabelTextSize / 2);
+        final int dayWidthHalf = (mWidth - mPadding * 2) / (mNumDays * 2);
 
         for (int i = 0; i < mNumDays; i++) {
-            int calendarDay = (i + mWeekStart) % mNumDays;
-            int x = (2 * i + 1) * dayWidthHalf + mPadding;
+            final int calendarDay = (i + mWeekStart) % mNumDays;
             mDayLabelCalendar.set(Calendar.DAY_OF_WEEK, calendarDay);
-            canvas.drawText("" + mDayLabelCalendar.getDisplayName(Calendar.DAY_OF_WEEK,
-                    Calendar.SHORT, Locale.getDefault()).toUpperCase(Locale.getDefault()).charAt(0),
-                    x, y, mMonthDayLabelPaint);
+
+            final String dayLabel = mDayFormatter.format(mDayLabelCalendar.getTime());
+            final int x = (2 * i + 1) * dayWidthHalf + mPadding;
+            canvas.drawText(dayLabel, x, y, mMonthDayLabelPaint);
         }
     }
 
diff --git a/core/java/android/widget/Spinner.java b/core/java/android/widget/Spinner.java
index 9914800..98d52ff 100644
--- a/core/java/android/widget/Spinner.java
+++ b/core/java/android/widget/Spinner.java
@@ -49,14 +49,14 @@
  *
  * <p>See the <a href="{@docRoot}guide/topics/ui/controls/spinner.html">Spinners</a> guide.</p>
  *
- * @attr ref android.R.styleable#Spinner_dropDownHorizontalOffset
  * @attr ref android.R.styleable#Spinner_dropDownSelector
- * @attr ref android.R.styleable#Spinner_dropDownVerticalOffset
  * @attr ref android.R.styleable#Spinner_dropDownWidth
  * @attr ref android.R.styleable#Spinner_gravity
  * @attr ref android.R.styleable#Spinner_popupBackground
  * @attr ref android.R.styleable#Spinner_prompt
  * @attr ref android.R.styleable#Spinner_spinnerMode
+ * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
+ * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
  */
 @Widget
 public class Spinner extends AbsSpinner implements OnClickListener {
@@ -209,17 +209,6 @@
                     ViewGroup.LayoutParams.WRAP_CONTENT);
             popup.setBackgroundDrawable(a.getDrawable(
                     com.android.internal.R.styleable.Spinner_popupBackground));
-            final int verticalOffset = a.getDimensionPixelOffset(
-                    com.android.internal.R.styleable.Spinner_dropDownVerticalOffset, 0);
-            if (verticalOffset != 0) {
-                popup.setVerticalOffset(verticalOffset);
-            }
-
-            final int horizontalOffset = a.getDimensionPixelOffset(
-                    com.android.internal.R.styleable.Spinner_dropDownHorizontalOffset, 0);
-            if (horizontalOffset != 0) {
-                popup.setHorizontalOffset(horizontalOffset);
-            }
 
             mPopup = popup;
             mForwardingListener = new ForwardingListener(this) {
@@ -303,7 +292,7 @@
      *
      * @param pixels Vertical offset in pixels
      *
-     * @attr ref android.R.styleable#Spinner_dropDownVerticalOffset
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
      */
     public void setDropDownVerticalOffset(int pixels) {
         mPopup.setVerticalOffset(pixels);
@@ -315,7 +304,7 @@
      *
      * @return Vertical offset in pixels
      *
-     * @attr ref android.R.styleable#Spinner_dropDownVerticalOffset
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownVerticalOffset
      */
     public int getDropDownVerticalOffset() {
         return mPopup.getVerticalOffset();
@@ -327,7 +316,7 @@
      *
      * @param pixels Horizontal offset in pixels
      *
-     * @attr ref android.R.styleable#Spinner_dropDownHorizontalOffset
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
      */
     public void setDropDownHorizontalOffset(int pixels) {
         mPopup.setHorizontalOffset(pixels);
@@ -339,7 +328,7 @@
      *
      * @return Horizontal offset in pixels
      *
-     * @attr ref android.R.styleable#Spinner_dropDownHorizontalOffset
+     * @attr ref android.R.styleable#ListPopupWindow_dropDownHorizontalOffset
      */
     public int getDropDownHorizontalOffset() {
         return mPopup.getHorizontalOffset();
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index a82fa65..a80d70a 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -17,6 +17,7 @@
 package android.widget;
 
 import android.R;
+import android.annotation.NonNull;
 import android.annotation.Nullable;
 import android.content.ClipData;
 import android.content.ClipboardManager;
@@ -1861,6 +1862,10 @@
             return getCompoundPaddingTop();
         }
 
+        if (mLayout == null) {
+            assumeLayout();
+        }
+
         if (mLayout.getLineCount() <= mMaximum) {
             return getCompoundPaddingTop();
         }
@@ -1894,6 +1899,10 @@
             return getCompoundPaddingBottom();
         }
 
+        if (mLayout == null) {
+            assumeLayout();
+        }
+
         if (mLayout.getLineCount() <= mMaximum) {
             return getCompoundPaddingBottom();
         }
@@ -1968,23 +1977,34 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the left of, above,
-     * to the right of, and below the text.  Use null if you do not
-     * want a Drawable there.  The Drawables must already have had
+     * Sets the Drawables (if any) to appear to the left of, above, to the
+     * right of, and below the text. Use {@code null} if you do not want a
+     * Drawable there. The Drawables must already have had
      * {@link Drawable#setBounds} called.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawablesRelative} or related methods.
      *
      * @attr ref android.R.styleable#TextView_drawableLeft
      * @attr ref android.R.styleable#TextView_drawableTop
      * @attr ref android.R.styleable#TextView_drawableRight
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
-    public void setCompoundDrawables(Drawable left, Drawable top,
-                                     Drawable right, Drawable bottom) {
+    public void setCompoundDrawables(@Nullable Drawable left, @Nullable Drawable top,
+            @Nullable Drawable right, @Nullable Drawable bottom) {
         Drawables dr = mDrawables;
 
-        final boolean drawables = left != null || top != null
-                || right != null || bottom != null;
+        // We're switching to absolute, discard relative.
+        if (dr != null) {
+            if (dr.mDrawableStart != null) dr.mDrawableStart.setCallback(null);
+            dr.mDrawableStart = null;
+            if (dr.mDrawableEnd != null) dr.mDrawableEnd.setCallback(null);
+            dr.mDrawableEnd = null;
+            dr.mDrawableSizeStart = dr.mDrawableHeightStart = 0;
+            dr.mDrawableSizeEnd = dr.mDrawableHeightEnd = 0;
+        }
 
+        final boolean drawables = left != null || top != null || right != null || bottom != null;
         if (!drawables) {
             // Clearing drawables...  can we free the data structure?
             if (dr != null) {
@@ -2093,10 +2113,12 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the left of, above,
-     * to the right of, and below the text.  Use 0 if you do not
-     * want a Drawable there. The Drawables' bounds will be set to
-     * their intrinsic bounds.
+     * Sets the Drawables (if any) to appear to the left of, above, to the
+     * right of, and below the text. Use 0 if you do not want a Drawable there.
+     * The Drawables' bounds will be set to their intrinsic bounds.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawablesRelative} or related methods.
      *
      * @param left Resource identifier of the left Drawable.
      * @param top Resource identifier of the top Drawable.
@@ -2118,18 +2140,21 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the left of, above,
-     * to the right of, and below the text.  Use null if you do not
-     * want a Drawable there. The Drawables' bounds will be set to
-     * their intrinsic bounds.
+     * Sets the Drawables (if any) to appear to the left of, above, to the
+     * right of, and below the text. Use {@code null} if you do not want a
+     * Drawable there. The Drawables' bounds will be set to their intrinsic
+     * bounds.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawablesRelative} or related methods.
      *
      * @attr ref android.R.styleable#TextView_drawableLeft
      * @attr ref android.R.styleable#TextView_drawableTop
      * @attr ref android.R.styleable#TextView_drawableRight
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
-    public void setCompoundDrawablesWithIntrinsicBounds(Drawable left, Drawable top,
-            Drawable right, Drawable bottom) {
+    public void setCompoundDrawablesWithIntrinsicBounds(@Nullable Drawable left,
+            @Nullable Drawable top, @Nullable Drawable right, @Nullable Drawable bottom) {
 
         if (left != null) {
             left.setBounds(0, 0, left.getIntrinsicWidth(), left.getIntrinsicHeight());
@@ -2147,20 +2172,33 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the start of, above,
-     * to the end of, and below the text.  Use null if you do not
-     * want a Drawable there.  The Drawables must already have had
-     * {@link Drawable#setBounds} called.
+     * Sets the Drawables (if any) to appear to the start of, above, to the end
+     * of, and below the text. Use {@code null} if you do not want a Drawable
+     * there. The Drawables must already have had {@link Drawable#setBounds}
+     * called.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawables} or related methods.
      *
      * @attr ref android.R.styleable#TextView_drawableStart
      * @attr ref android.R.styleable#TextView_drawableTop
      * @attr ref android.R.styleable#TextView_drawableEnd
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
-    public void setCompoundDrawablesRelative(Drawable start, Drawable top,
-                                     Drawable end, Drawable bottom) {
+    public void setCompoundDrawablesRelative(@Nullable Drawable start, @Nullable Drawable top,
+            @Nullable Drawable end, @Nullable Drawable bottom) {
         Drawables dr = mDrawables;
 
+        // We're switching to relative, discard absolute.
+        if (dr != null) {
+            if (dr.mDrawableLeft != null) dr.mDrawableLeft.setCallback(null);
+            dr.mDrawableLeft = dr.mDrawableLeftInitial = null;
+            if (dr.mDrawableRight != null) dr.mDrawableRight.setCallback(null);
+            dr.mDrawableRight = dr.mDrawableRightInitial = null;
+            dr.mDrawableSizeLeft = dr.mDrawableHeightLeft = 0;
+            dr.mDrawableSizeRight = dr.mDrawableHeightRight = 0;
+        }
+
         final boolean drawables = start != null || top != null
                 || end != null || bottom != null;
 
@@ -2266,10 +2304,12 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the start of, above,
-     * to the end of, and below the text.  Use 0 if you do not
-     * want a Drawable there. The Drawables' bounds will be set to
-     * their intrinsic bounds.
+     * Sets the Drawables (if any) to appear to the start of, above, to the end
+     * of, and below the text. Use 0 if you do not want a Drawable there. The
+     * Drawables' bounds will be set to their intrinsic bounds.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawables} or related methods.
      *
      * @param start Resource identifier of the start Drawable.
      * @param top Resource identifier of the top Drawable.
@@ -2293,18 +2333,20 @@
     }
 
     /**
-     * Sets the Drawables (if any) to appear to the start of, above,
-     * to the end of, and below the text.  Use null if you do not
-     * want a Drawable there. The Drawables' bounds will be set to
-     * their intrinsic bounds.
+     * Sets the Drawables (if any) to appear to the start of, above, to the end
+     * of, and below the text. Use {@code null} if you do not want a Drawable
+     * there. The Drawables' bounds will be set to their intrinsic bounds.
+     * <p>
+     * Calling this method will overwrite any Drawables previously set using
+     * {@link #setCompoundDrawables} or related methods.
      *
      * @attr ref android.R.styleable#TextView_drawableStart
      * @attr ref android.R.styleable#TextView_drawableTop
      * @attr ref android.R.styleable#TextView_drawableEnd
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
-    public void setCompoundDrawablesRelativeWithIntrinsicBounds(Drawable start, Drawable top,
-            Drawable end, Drawable bottom) {
+    public void setCompoundDrawablesRelativeWithIntrinsicBounds(@Nullable Drawable start,
+            @Nullable Drawable top, @Nullable Drawable end, @Nullable Drawable bottom) {
 
         if (start != null) {
             start.setBounds(0, 0, start.getIntrinsicWidth(), start.getIntrinsicHeight());
@@ -2329,6 +2371,7 @@
      * @attr ref android.R.styleable#TextView_drawableRight
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
+    @NonNull
     public Drawable[] getCompoundDrawables() {
         final Drawables dr = mDrawables;
         if (dr != null) {
@@ -2348,6 +2391,7 @@
      * @attr ref android.R.styleable#TextView_drawableEnd
      * @attr ref android.R.styleable#TextView_drawableBottom
      */
+    @NonNull
     public Drawable[] getCompoundDrawablesRelative() {
         final Drawables dr = mDrawables;
         if (dr != null) {
@@ -2867,8 +2911,15 @@
     }
 
     /**
-     * Gives the text a shadow of the specified radius and color, the specified
-     * distance from its normal position.
+     * Gives the text a shadow of the specified blur radius and color, the specified
+     * distance from its drawn position.
+     * <p>
+     * The text shadow produced does not interact with the properties on view
+     * that are responsible for real time shadows,
+     * {@link View#getElevation() elevation} and
+     * {@link View#getTranslationZ() translationZ}.
+     *
+     * @see Paint#setShadowLayer(float, float, float, int)
      *
      * @attr ref android.R.styleable#TextView_shadowColor
      * @attr ref android.R.styleable#TextView_shadowDx
@@ -5712,8 +5763,6 @@
         }
 
         if (mEditor != null && mEditor.mKeyListener != null) {
-            resetErrorChangedFlag();
-
             boolean doDown = true;
             if (otherEvent != null) {
                 try {
@@ -7630,6 +7679,7 @@
                 list.get(i).afterTextChanged(text);
             }
         }
+        hideErrorIfUnchanged();
     }
 
     void updateAfterEdit() {
@@ -7669,7 +7719,7 @@
             }
             ims.mChangedDelta += after-before;
         }
-
+        resetErrorChangedFlag();
         sendOnTextChanged(buffer, start, before, after);
         onTextChanged(buffer, start, before, after);
     }
@@ -8128,8 +8178,15 @@
      * Returns the TextView_textColor attribute from the TypedArray, if set, or
      * the TextAppearance_textColor from the TextView_textAppearance attribute,
      * if TextView_textColor was not set directly.
+     *
+     * @removed
      */
     public static ColorStateList getTextColors(Context context, TypedArray attrs) {
+        if (attrs == null) {
+            // Preserve behavior prior to removal of this API.
+            throw new NullPointerException();
+        }
+
         // It's not safe to use this method from apps. The parameter 'attrs'
         // must have been obtained using the TextView filter array which is not
         // available to the SDK. As such, we grab a default TypedArray with the
@@ -8155,6 +8212,8 @@
      * AttributeSet, if set, or the default color from the
      * TextAppearance_textColor from the TextView_textAppearance attribute, if
      * TextView_textColor was not set directly.
+     *
+     * @removed
      */
     public static int getTextColor(Context context, TypedArray attrs, int def) {
         final ColorStateList colors = getTextColors(context, attrs);
@@ -8409,6 +8468,33 @@
     @Override
     public boolean performAccessibilityAction(int action, Bundle arguments) {
         switch (action) {
+            case AccessibilityNodeInfo.ACTION_CLICK: {
+                boolean handled = false;
+
+                // Simulate View.onTouchEvent for an ACTION_UP event.
+                if (isClickable() || isLongClickable()) {
+                    if (isFocusable() && !isFocused()) {
+                        requestFocus();
+                    }
+
+                    performClick();
+                    handled = true;
+                }
+
+                // Simulate TextView.onTouchEvent for an ACTION_UP event.
+                if ((mMovement != null || onCheckIsTextEditor()) && isEnabled()
+                        && mText instanceof Spannable && mLayout != null
+                        && (isTextEditable() || isTextSelectable()) && isFocused()) {
+                    // Show the IME, except when selecting in read-only text.
+                    final InputMethodManager imm = InputMethodManager.peekInstance();
+                    viewClicked(imm);
+                    if (!isTextSelectable() && mEditor.mShowSoftInputOnFocus && imm != null) {
+                        handled |= imm.showSoftInput(this, 0);
+                    }
+                }
+
+                return handled;
+            }
             case AccessibilityNodeInfo.ACTION_COPY: {
                 if (isFocused() && canCopy()) {
                     if (onTextContextMenuItem(ID_COPY)) {
@@ -8713,57 +8799,6 @@
     }
 
     /**
-     * Prepare text so that there are not zero or two spaces at beginning and end of region defined
-     * by [min, max] when replacing this region by paste.
-     * Note that if there were two spaces (or more) at that position before, they are kept. We just
-     * make sure we do not add an extra one from the paste content.
-     */
-    long prepareSpacesAroundPaste(int min, int max, CharSequence paste) {
-        if (paste.length() > 0) {
-            if (min > 0) {
-                final char charBefore = mTransformed.charAt(min - 1);
-                final char charAfter = paste.charAt(0);
-
-                if (Character.isSpaceChar(charBefore) && Character.isSpaceChar(charAfter)) {
-                    // Two spaces at beginning of paste: remove one
-                    final int originalLength = mText.length();
-                    deleteText_internal(min - 1, min);
-                    // Due to filters, there is no guarantee that exactly one character was
-                    // removed: count instead.
-                    final int delta = mText.length() - originalLength;
-                    min += delta;
-                    max += delta;
-                } else if (!Character.isSpaceChar(charBefore) && charBefore != '\n' &&
-                        !Character.isSpaceChar(charAfter) && charAfter != '\n') {
-                    // No space at beginning of paste: add one
-                    final int originalLength = mText.length();
-                    replaceText_internal(min, min, " ");
-                    // Taking possible filters into account as above.
-                    final int delta = mText.length() - originalLength;
-                    min += delta;
-                    max += delta;
-                }
-            }
-
-            if (max < mText.length()) {
-                final char charBefore = paste.charAt(paste.length() - 1);
-                final char charAfter = mTransformed.charAt(max);
-
-                if (Character.isSpaceChar(charBefore) && Character.isSpaceChar(charAfter)) {
-                    // Two spaces at end of paste: remove one
-                    deleteText_internal(max, max + 1);
-                } else if (!Character.isSpaceChar(charBefore) && charBefore != '\n' &&
-                        !Character.isSpaceChar(charAfter) && charAfter != '\n') {
-                    // No space at end of paste: add one
-                    replaceText_internal(max, max, " ");
-                }
-            }
-        }
-
-        return TextUtils.packRangeInLong(min, max);
-    }
-
-    /**
      * Paste clipboard content between min and max positions.
      */
     private void paste(int min, int max) {
@@ -8776,9 +8811,6 @@
                 CharSequence paste = clip.getItemAt(i).coerceToStyledText(getContext());
                 if (paste != null) {
                     if (!didFirst) {
-                        long minMax = prepareSpacesAroundPaste(min, max, paste);
-                        min = TextUtils.unpackRangeStartFromLong(minMax);
-                        max = TextUtils.unpackRangeEndFromLong(minMax);
                         Selection.setSelection((Spannable) mText, max);
                         ((Editable) mText).replace(min, max, paste);
                         didFirst = true;
diff --git a/core/java/android/widget/TimePickerClockDelegate.java b/core/java/android/widget/TimePickerClockDelegate.java
index 376e5b4..8917f39 100644
--- a/core/java/android/widget/TimePickerClockDelegate.java
+++ b/core/java/android/widget/TimePickerClockDelegate.java
@@ -18,7 +18,6 @@
 
 import android.content.Context;
 import android.content.res.Configuration;
-import android.content.res.Resources;
 import android.content.res.TypedArray;
 import android.os.Parcel;
 import android.os.Parcelable;
@@ -34,9 +33,12 @@
 import android.view.inputmethod.InputMethodManager;
 import com.android.internal.R;
 
+import java.text.DateFormatSymbols;
 import java.util.Calendar;
 import java.util.Locale;
 
+import libcore.icu.LocaleData;
+
 import static android.view.View.IMPORTANT_FOR_ACCESSIBILITY_AUTO;
 import static android.view.View.IMPORTANT_FOR_ACCESSIBILITY_YES;
 
@@ -73,16 +75,6 @@
     private boolean mHourWithTwoDigit;
     private char mHourFormat;
 
-    /**
-     * A no-op callback used in the constructor to avoid null checks later in
-     * the code.
-     */
-    private static final TimePicker.OnTimeChangedListener NO_OP_CHANGE_LISTENER =
-            new TimePicker.OnTimeChangedListener() {
-                public void onTimeChanged(TimePicker view, int hourOfDay, int minute) {
-                }
-            };
-
     public TimePickerClockDelegate(TimePicker delegator, Context context, AttributeSet attrs,
             int defStyleAttr, int defStyleRes) {
         super(delegator, context);
@@ -153,14 +145,11 @@
         mMinuteSpinnerInput = (EditText) mMinuteSpinner.findViewById(R.id.numberpicker_input);
         mMinuteSpinnerInput.setImeOptions(EditorInfo.IME_ACTION_NEXT);
 
-            /* Get the localized am/pm strings and use them in the spinner */
-        final Resources res = context.getResources();
-        final String amText = res.getString(R.string.time_picker_am_label);
-        final String pmText = res.getString(R.string.time_picker_pm_label);
-        mAmPmStrings = new String[] {amText, pmText};
+        // Get the localized am/pm strings and use them in the spinner.
+        mAmPmStrings = getAmPmStrings(context);
 
         // am/pm
-        View amPmView = mDelegator.findViewById(R.id.amPm);
+        final View amPmView = mDelegator.findViewById(R.id.amPm);
         if (amPmView instanceof Button) {
             mAmPmSpinner = null;
             mAmPmSpinnerInput = null;
@@ -216,8 +205,6 @@
         updateMinuteControl();
         updateAmPmControl();
 
-        setOnTimeChangedListener(NO_OP_CHANGE_LISTENER);
-
         // set to current time
         setCurrentHour(mTempCalendar.get(Calendar.HOUR_OF_DAY));
         setCurrentMinute(mTempCalendar.get(Calendar.MINUTE));
@@ -613,5 +600,12 @@
             }
         };
     }
-}
 
+    public static String[] getAmPmStrings(Context context) {
+        String[] result = new String[2];
+        LocaleData d = LocaleData.get(context.getResources().getConfiguration().locale);
+        result[0] = d.amPm[0].length() > 2 ? d.narrowAm : d.amPm[0];
+        result[1] = d.amPm[1].length() > 2 ? d.narrowPm : d.amPm[1];
+        return result;
+    }
+}
diff --git a/core/java/android/widget/TimePickerSpinnerDelegate.java b/core/java/android/widget/TimePickerSpinnerDelegate.java
index 9a50250..73e05e8 100644
--- a/core/java/android/widget/TimePickerSpinnerDelegate.java
+++ b/core/java/android/widget/TimePickerSpinnerDelegate.java
@@ -16,15 +16,11 @@
 
 package android.widget;
 
-import android.animation.Keyframe;
-import android.animation.ObjectAnimator;
-import android.animation.PropertyValuesHolder;
 import android.content.Context;
 import android.content.res.ColorStateList;
 import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.content.res.TypedArray;
-import android.graphics.Color;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.text.TextUtils;
@@ -73,12 +69,7 @@
 
     private static final int HOURS_IN_HALF_DAY = 12;
 
-    // Delay in ms before starting the pulse animation
-    private static final int PULSE_ANIMATOR_DELAY = 300;
-
-    // Duration in ms of the pulse animation
-    private static final int PULSE_ANIMATOR_DURATION = 544;
-
+    private View mHeaderView;
     private TextView mHourView;
     private TextView mMinuteView;
     private TextView mAmPmTextView;
@@ -98,7 +89,6 @@
     private String mDoublePlaceholderText;
     private String mDeletedKeyFormat;
     private boolean mInKbMode;
-    private boolean mIsTimeValid = true;
     private ArrayList<Integer> mTypedTimes = new ArrayList<Integer>();
     private Node mLegalTimesTree;
     private int mAmKeyCode;
@@ -127,8 +117,10 @@
         mSelectHours = res.getString(R.string.select_hours);
         mMinutePickerDescription = res.getString(R.string.minute_picker_description);
         mSelectMinutes = res.getString(R.string.select_minutes);
-        mAmText = res.getString(R.string.time_picker_am_label);
-        mPmText = res.getString(R.string.time_picker_pm_label);
+
+        String[] amPmStrings = TimePickerClockDelegate.getAmPmStrings(context);
+        mAmText = amPmStrings[0];
+        mPmText = amPmStrings[1];
 
         final int layoutResourceId = a.getResourceId(R.styleable.TimePicker_internalLayout,
                 R.layout.time_picker_holo);
@@ -163,11 +155,8 @@
             mAmPmTextView.setTextAppearance(context, headerAmPmTextAppearance);
         }
 
-        final int headerBackgroundColor = a.getColor(
-                R.styleable.TimePicker_headerBackgroundColor, Color.TRANSPARENT);
-        if (headerBackgroundColor != Color.TRANSPARENT) {
-            mainView.findViewById(R.id.time_header).setBackgroundColor(headerBackgroundColor);
-        }
+        mHeaderView = mainView.findViewById(R.id.time_header);
+        mHeaderView.setBackground(a.getDrawable(R.styleable.TimePicker_headerBackground));
 
         a.recycle();
 
@@ -201,26 +190,23 @@
     }
 
     private void setupListeners() {
-        KeyboardListener keyboardListener = new KeyboardListener();
-        mDelegator.setOnKeyListener(keyboardListener);
+        mHeaderView.setOnKeyListener(mKeyListener);
+        mHeaderView.setOnFocusChangeListener(mFocusListener);
+        mHeaderView.setFocusable(true);
 
-        mHourView.setOnKeyListener(keyboardListener);
-        mMinuteView.setOnKeyListener(keyboardListener);
-        mAmPmTextView.setOnKeyListener(keyboardListener);
         mRadialTimePickerView.setOnValueSelectedListener(this);
-        mRadialTimePickerView.setOnKeyListener(keyboardListener);
 
         mHourView.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View v) {
-                setCurrentItemShowing(HOUR_INDEX, true, false, true);
+                setCurrentItemShowing(HOUR_INDEX, true, true);
                 tryVibrate();
             }
         });
         mMinuteView.setOnClickListener(new View.OnClickListener() {
             @Override
             public void onClick(View v) {
-                setCurrentItemShowing(MINUTE_INDEX, true, false, true);
+                setCurrentItemShowing(MINUTE_INDEX, true, true);
                 tryVibrate();
             }
         });
@@ -243,7 +229,7 @@
 
     private void updateRadialPicker(int index) {
         mRadialTimePickerView.initialize(mInitialHourOfDay, mInitialMinute, mIs24HourView);
-        setCurrentItemShowing(index, false, true, true);
+        setCurrentItemShowing(index, false, true);
     }
 
     private int computeMaxWidthOfNumbers(int max) {
@@ -631,7 +617,7 @@
             updateHeaderHour(newValue, false);
             String announcement = String.format("%d", newValue);
             if (mAllowAutoAdvance && autoAdvance) {
-                setCurrentItemShowing(MINUTE_INDEX, true, true, false);
+                setCurrentItemShowing(MINUTE_INDEX, true, false);
                 announcement += ". " + mSelectMinutes;
             } else {
                 mRadialTimePickerView.setContentDescription(
@@ -648,7 +634,7 @@
             if (!isTypedTimeFullyLegal()) {
                 mTypedTimes.clear();
             }
-            finishKbMode(true);
+            finishKbMode();
         }
     }
 
@@ -751,11 +737,9 @@
     /**
      * Show either Hours or Minutes.
      */
-    private void setCurrentItemShowing(int index, boolean animateCircle, boolean delayLabelAnimate,
-                                       boolean announce) {
+    private void setCurrentItemShowing(int index, boolean animateCircle, boolean announce) {
         mRadialTimePickerView.setCurrentItemShowing(index, animateCircle);
 
-        TextView labelToAnimate;
         if (index == HOUR_INDEX) {
             int hours = mRadialTimePickerView.getCurrentHour();
             if (!mIs24HourView) {
@@ -765,24 +749,16 @@
             if (announce) {
                 mRadialTimePickerView.announceForAccessibility(mSelectHours);
             }
-            labelToAnimate = mHourView;
         } else {
             int minutes = mRadialTimePickerView.getCurrentMinute();
             mRadialTimePickerView.setContentDescription(mMinutePickerDescription + ": " + minutes);
             if (announce) {
                 mRadialTimePickerView.announceForAccessibility(mSelectMinutes);
             }
-            labelToAnimate = mMinuteView;
         }
 
         mHourView.setSelected(index == HOUR_INDEX);
         mMinuteView.setSelected(index == MINUTE_INDEX);
-
-        ObjectAnimator pulseAnimator = getPulseAnimator(labelToAnimate, 0.85f, 1.1f);
-        if (delayLabelAnimate) {
-            pulseAnimator.setStartDelay(PULSE_ANIMATOR_DELAY);
-        }
-        pulseAnimator.start();
     }
 
     /**
@@ -793,27 +769,7 @@
      * @return true if the key was successfully processed, false otherwise.
      */
     private boolean processKeyUp(int keyCode) {
-        if (keyCode == KeyEvent.KEYCODE_ESCAPE || keyCode == KeyEvent.KEYCODE_TAB) {
-            if(mInKbMode) {
-                if (isTypedTimeFullyLegal()) {
-                    finishKbMode(true);
-                }
-                return true;
-            }
-        } else if (keyCode == KeyEvent.KEYCODE_ENTER) {
-            if (mInKbMode) {
-                if (!isTypedTimeFullyLegal()) {
-                    return true;
-                }
-                finishKbMode(false);
-            }
-            if (mOnTimeChangedListener != null) {
-                mOnTimeChangedListener.onTimeChanged(mDelegator,
-                        mRadialTimePickerView.getCurrentHour(),
-                        mRadialTimePickerView.getCurrentMinute());
-            }
-            return true;
-        } else if (keyCode == KeyEvent.KEYCODE_DEL) {
+        if (keyCode == KeyEvent.KEYCODE_DEL) {
             if (mInKbMode) {
                 if (!mTypedTimes.isEmpty()) {
                     int deleted = deleteLastTypedKey();
@@ -942,9 +898,8 @@
 
     /**
      * Get out of keyboard mode. If there is nothing in typedTimes, revert to TimePicker's time.
-     * @param updateDisplays If true, update the displays with the relevant time.
      */
-    private void finishKbMode(boolean updateDisplays) {
+    private void finishKbMode() {
         mInKbMode = false;
         if (!mTypedTimes.isEmpty()) {
             int values[] = getEnteredTime(null);
@@ -955,10 +910,8 @@
             }
             mTypedTimes.clear();
         }
-        if (updateDisplays) {
-            updateDisplay(false);
-            mRadialTimePickerView.setInputEnabled(true);
-        }
+        updateDisplay(false);
+        mRadialTimePickerView.setInputEnabled(true);
     }
 
     /**
@@ -978,7 +931,7 @@
             if (!mIs24HourView) {
                 updateAmPmDisplay(hour < 12 ? AM : PM);
             }
-            setCurrentItemShowing(mRadialTimePickerView.getCurrentItemShowing(), true, true, true);
+            setCurrentItemShowing(mRadialTimePickerView.getCurrentItemShowing(), true, true);
             onValidationChanged(true);
         } else {
             boolean[] enteredZeros = {false, false};
@@ -1278,7 +1231,7 @@
         }
     }
 
-    private class KeyboardListener implements View.OnKeyListener {
+    private final View.OnKeyListener mKeyListener = new View.OnKeyListener() {
         @Override
         public boolean onKey(View v, int keyCode, KeyEvent event) {
             if (event.getAction() == KeyEvent.ACTION_UP) {
@@ -1286,27 +1239,20 @@
             }
             return false;
         }
-    }
+    };
 
-    /**
-     * Render an animator to pulsate a view in place.
-     *
-     * @param labelToAnimate the view to pulsate.
-     * @return The animator object. Use .start() to begin.
-     */
-    private static ObjectAnimator getPulseAnimator(View labelToAnimate, float decreaseRatio,
-            float increaseRatio) {
-        final Keyframe k0 = Keyframe.ofFloat(0f, 1f);
-        final Keyframe k1 = Keyframe.ofFloat(0.275f, decreaseRatio);
-        final Keyframe k2 = Keyframe.ofFloat(0.69f, increaseRatio);
-        final Keyframe k3 = Keyframe.ofFloat(1f, 1f);
+    private final View.OnFocusChangeListener mFocusListener = new View.OnFocusChangeListener() {
+        @Override
+        public void onFocusChange(View v, boolean hasFocus) {
+            if (!hasFocus && mInKbMode && isTypedTimeFullyLegal()) {
+                finishKbMode();
 
-        PropertyValuesHolder scaleX = PropertyValuesHolder.ofKeyframe(View.SCALE_X, k0, k1, k2, k3);
-        PropertyValuesHolder scaleY = PropertyValuesHolder.ofKeyframe(View.SCALE_Y, k0, k1, k2, k3);
-        ObjectAnimator pulseAnimator =
-                ObjectAnimator.ofPropertyValuesHolder(labelToAnimate, scaleX, scaleY);
-        pulseAnimator.setDuration(PULSE_ANIMATOR_DURATION);
-
-        return pulseAnimator;
-    }
+                if (mOnTimeChangedListener != null) {
+                    mOnTimeChangedListener.onTimeChanged(mDelegator,
+                            mRadialTimePickerView.getCurrentHour(),
+                            mRadialTimePickerView.getCurrentMinute());
+                }
+            }
+        }
+    };
 }
diff --git a/core/java/android/widget/Toast.java b/core/java/android/widget/Toast.java
index bf5e49b9..dd165ae 100644
--- a/core/java/android/widget/Toast.java
+++ b/core/java/android/widget/Toast.java
@@ -113,7 +113,7 @@
         }
 
         INotificationManager service = getService();
-        String pkg = mContext.getPackageName();
+        String pkg = mContext.getOpPackageName();
         TN tn = mTN;
         tn.mNextView = mNextView;
 
@@ -387,6 +387,7 @@
                 handleHide();
                 mView = mNextView;
                 Context context = mView.getContext().getApplicationContext();
+                String packageName = mView.getContext().getOpPackageName();
                 if (context == null) {
                     context = mView.getContext();
                 }
@@ -406,6 +407,7 @@
                 mParams.y = mY;
                 mParams.verticalMargin = mVerticalMargin;
                 mParams.horizontalMargin = mHorizontalMargin;
+                mParams.packageName = packageName;
                 if (mView.getParent() != null) {
                     if (localLOGV) Log.v(TAG, "REMOVE! " + mView + " in " + this);
                     mWM.removeView(mView);
diff --git a/core/java/android/widget/Toolbar.java b/core/java/android/widget/Toolbar.java
index 0b15eb6..1ce19ce 100644
--- a/core/java/android/widget/Toolbar.java
+++ b/core/java/android/widget/Toolbar.java
@@ -33,6 +33,7 @@
 import android.view.Menu;
 import android.view.MenuInflater;
 import android.view.MenuItem;
+import android.view.MotionEvent;
 import android.view.View;
 import android.view.ViewGroup;
 
@@ -132,6 +133,8 @@
     private int mTitleTextColor;
     private int mSubtitleTextColor;
 
+    private boolean mEatingTouch;
+
     // Clear me after use.
     private final ArrayList<View> mTempViews = new ArrayList<View>();
 
@@ -153,9 +156,17 @@
     private ToolbarWidgetWrapper mWrapper;
     private ActionMenuPresenter mOuterActionMenuPresenter;
     private ExpandedActionViewMenuPresenter mExpandedMenuPresenter;
+    private MenuPresenter.Callback mActionMenuPresenterCallback;
+    private MenuBuilder.Callback mMenuBuilderCallback;
 
     private boolean mCollapsible;
 
+    private final Runnable mShowOverflowMenuRunnable = new Runnable() {
+        @Override public void run() {
+            showOverflowMenu();
+        }
+    };
+
     public Toolbar(Context context) {
         this(context, null);
     }
@@ -238,6 +249,17 @@
         // Set the default context, since setPopupTheme() may be a no-op.
         mPopupContext = mContext;
         setPopupTheme(a.getResourceId(R.styleable.Toolbar_popupTheme, 0));
+
+        final Drawable navIcon = a.getDrawable(R.styleable.Toolbar_navigationIcon);
+        if (navIcon != null) {
+            setNavigationIcon(navIcon);
+        }
+
+        final CharSequence navDesc = a.getText(
+                R.styleable.Toolbar_navigationContentDescription);
+        if (!TextUtils.isEmpty(navDesc)) {
+            setNavigationContentDescription(navDesc);
+        }
         a.recycle();
     }
 
@@ -404,6 +426,7 @@
             ensureLogoView();
             if (mLogoView.getParent() == null) {
                 addSystemView(mLogoView);
+                updateChildVisibilityForExpandedActionView(mLogoView);
             }
         } else if (mLogoView != null && mLogoView.getParent() != null) {
             removeView(mLogoView);
@@ -545,6 +568,7 @@
             }
             if (mTitleTextView.getParent() == null) {
                 addSystemView(mTitleTextView);
+                updateChildVisibilityForExpandedActionView(mTitleTextView);
             }
         } else if (mTitleTextView != null && mTitleTextView.getParent() != null) {
             removeView(mTitleTextView);
@@ -598,6 +622,7 @@
             }
             if (mSubtitleTextView.getParent() == null) {
                 addSystemView(mSubtitleTextView);
+                updateChildVisibilityForExpandedActionView(mSubtitleTextView);
             }
         } else if (mSubtitleTextView != null && mSubtitleTextView.getParent() != null) {
             removeView(mSubtitleTextView);
@@ -660,6 +685,8 @@
      * as screen readers or tooltips.
      *
      * @return The navigation button's content description
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationContentDescription
      */
     @Nullable
     public CharSequence getNavigationContentDescription() {
@@ -673,6 +700,8 @@
      *
      * @param resId Resource ID of a content description string to set, or 0 to
      *              clear the description
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationContentDescription
      */
     public void setNavigationContentDescription(int resId) {
         setNavigationContentDescription(resId != 0 ? getContext().getText(resId) : null);
@@ -685,6 +714,8 @@
      *
      * @param description Content description to set, or <code>null</code> to
      *                    clear the content description
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationContentDescription
      */
     public void setNavigationContentDescription(@Nullable CharSequence description) {
         if (!TextUtils.isEmpty(description)) {
@@ -706,6 +737,8 @@
      * tooltips.</p>
      *
      * @param resId Resource ID of a drawable to set
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationIcon
      */
     public void setNavigationIcon(int resId) {
         setNavigationIcon(getContext().getDrawable(resId));
@@ -722,12 +755,15 @@
      * tooltips.</p>
      *
      * @param icon Drawable to set, may be null to clear the icon
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationIcon
      */
     public void setNavigationIcon(@Nullable Drawable icon) {
         if (icon != null) {
             ensureNavButtonView();
             if (mNavButtonView.getParent() == null) {
                 addSystemView(mNavButtonView);
+                updateChildVisibilityForExpandedActionView(mNavButtonView);
             }
         } else if (mNavButtonView != null && mNavButtonView.getParent() != null) {
             removeView(mNavButtonView);
@@ -741,6 +777,8 @@
      * Return the current drawable used as the navigation icon.
      *
      * @return The navigation icon drawable
+     *
+     * @attr ref android.R.styleable#Toolbar_navigationIcon
      */
     @Nullable
     public Drawable getNavigationIcon() {
@@ -792,6 +830,7 @@
             mMenuView = new ActionMenuView(getContext());
             mMenuView.setPopupTheme(mPopupTheme);
             mMenuView.setOnMenuItemClickListener(mMenuViewItemClickListener);
+            mMenuView.setMenuCallbacks(mActionMenuPresenterCallback, mMenuBuilderCallback);
             final LayoutParams lp = generateDefaultLayoutParams();
             lp.gravity = Gravity.END | (mButtonGravity & Gravity.VERTICAL_GRAVITY_MASK);
             mMenuView.setLayoutParams(lp);
@@ -970,8 +1009,15 @@
     }
 
     private void addSystemView(View v) {
-        final LayoutParams lp = new LayoutParams(LayoutParams.WRAP_CONTENT,
-                LayoutParams.WRAP_CONTENT);
+        final ViewGroup.LayoutParams vlp = v.getLayoutParams();
+        final LayoutParams lp;
+        if (vlp == null) {
+            lp = generateDefaultLayoutParams();
+        } else if (!checkLayoutParams(vlp)) {
+            lp = generateLayoutParams(vlp);
+        } else {
+            lp = (LayoutParams) vlp;
+        }
         lp.mViewType = LayoutParams.SYSTEM;
         addView(v, lp);
     }
@@ -979,6 +1025,13 @@
     @Override
     protected Parcelable onSaveInstanceState() {
         SavedState state = new SavedState(super.onSaveInstanceState());
+
+        if (mExpandedMenuPresenter != null && mExpandedMenuPresenter.mCurrentExpandedItem != null) {
+            state.expandedMenuItemId = mExpandedMenuPresenter.mCurrentExpandedItem.getItemId();
+        }
+
+        state.isOverflowOpen = isOverflowMenuShowing();
+
         return state;
     }
 
@@ -986,6 +1039,55 @@
     protected void onRestoreInstanceState(Parcelable state) {
         final SavedState ss = (SavedState) state;
         super.onRestoreInstanceState(ss.getSuperState());
+
+        final Menu menu = mMenuView != null ? mMenuView.peekMenu() : null;
+        if (ss.expandedMenuItemId != 0 && mExpandedMenuPresenter != null && menu != null) {
+            final MenuItem item = menu.findItem(ss.expandedMenuItemId);
+            if (item != null) {
+                item.expandActionView();
+            }
+        }
+
+        if (ss.isOverflowOpen) {
+            postShowOverflowMenu();
+        }
+    }
+
+    private void postShowOverflowMenu() {
+        removeCallbacks(mShowOverflowMenuRunnable);
+        post(mShowOverflowMenuRunnable);
+    }
+
+    @Override
+    protected void onDetachedFromWindow() {
+        super.onDetachedFromWindow();
+        removeCallbacks(mShowOverflowMenuRunnable);
+    }
+
+    @Override
+    public boolean onTouchEvent(MotionEvent ev) {
+        // Toolbars always eat touch events, but should still respect the touch event dispatch
+        // contract. If the normal View implementation doesn't want the events, we'll just silently
+        // eat the rest of the gesture without reporting the events to the default implementation
+        // since that's what it expects.
+
+        final int action = ev.getActionMasked();
+        if (action == MotionEvent.ACTION_DOWN) {
+            mEatingTouch = false;
+        }
+
+        if (!mEatingTouch) {
+            final boolean handled = super.onTouchEvent(ev);
+            if (action == MotionEvent.ACTION_DOWN && !handled) {
+                mEatingTouch = true;
+            }
+        }
+
+        if (action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_CANCEL) {
+            mEatingTouch = false;
+        }
+
+        return true;
     }
 
     /**
@@ -1213,27 +1315,36 @@
         final int[] collapsingMargins = mTempMargins;
         collapsingMargins[0] = collapsingMargins[1] = 0;
 
+        // Align views within the minimum toolbar height, if set.
+        final int alignmentHeight = getMinimumHeight();
+
         if (shouldLayout(mNavButtonView)) {
             if (isRtl) {
-                right = layoutChildRight(mNavButtonView, right, collapsingMargins);
+                right = layoutChildRight(mNavButtonView, right, collapsingMargins,
+                        alignmentHeight);
             } else {
-                left = layoutChildLeft(mNavButtonView, left, collapsingMargins);
+                left = layoutChildLeft(mNavButtonView, left, collapsingMargins,
+                        alignmentHeight);
             }
         }
 
         if (shouldLayout(mCollapseButtonView)) {
             if (isRtl) {
-                right = layoutChildRight(mCollapseButtonView, right, collapsingMargins);
+                right = layoutChildRight(mCollapseButtonView, right, collapsingMargins,
+                        alignmentHeight);
             } else {
-                left = layoutChildLeft(mCollapseButtonView, left, collapsingMargins);
+                left = layoutChildLeft(mCollapseButtonView, left, collapsingMargins,
+                        alignmentHeight);
             }
         }
 
         if (shouldLayout(mMenuView)) {
             if (isRtl) {
-                left = layoutChildLeft(mMenuView, left, collapsingMargins);
+                left = layoutChildLeft(mMenuView, left, collapsingMargins,
+                        alignmentHeight);
             } else {
-                right = layoutChildRight(mMenuView, right, collapsingMargins);
+                right = layoutChildRight(mMenuView, right, collapsingMargins,
+                        alignmentHeight);
             }
         }
 
@@ -1244,17 +1355,21 @@
 
         if (shouldLayout(mExpandedActionView)) {
             if (isRtl) {
-                right = layoutChildRight(mExpandedActionView, right, collapsingMargins);
+                right = layoutChildRight(mExpandedActionView, right, collapsingMargins,
+                        alignmentHeight);
             } else {
-                left = layoutChildLeft(mExpandedActionView, left, collapsingMargins);
+                left = layoutChildLeft(mExpandedActionView, left, collapsingMargins,
+                        alignmentHeight);
             }
         }
 
         if (shouldLayout(mLogoView)) {
             if (isRtl) {
-                right = layoutChildRight(mLogoView, right, collapsingMargins);
+                right = layoutChildRight(mLogoView, right, collapsingMargins,
+                        alignmentHeight);
             } else {
-                left = layoutChildLeft(mLogoView, left, collapsingMargins);
+                left = layoutChildLeft(mLogoView, left, collapsingMargins,
+                        alignmentHeight);
             }
         }
 
@@ -1276,6 +1391,8 @@
             final View bottomChild = layoutSubtitle ? mSubtitleTextView : mTitleTextView;
             final LayoutParams toplp = (LayoutParams) topChild.getLayoutParams();
             final LayoutParams bottomlp = (LayoutParams) bottomChild.getLayoutParams();
+            final boolean titleHasWidth = layoutTitle && mTitleTextView.getMeasuredWidth() > 0
+                    || layoutSubtitle && mSubtitleTextView.getMeasuredWidth() > 0;
 
             switch (mGravity & Gravity.VERTICAL_GRAVITY_MASK) {
                 case Gravity.TOP:
@@ -1303,7 +1420,7 @@
                     break;
             }
             if (isRtl) {
-                final int rd = mTitleMarginStart - collapsingMargins[1];
+                final int rd = (titleHasWidth ? mTitleMarginStart : 0) - collapsingMargins[1];
                 right -= Math.max(0, rd);
                 collapsingMargins[1] = Math.max(0, -rd);
                 int titleRight = right;
@@ -1326,9 +1443,11 @@
                     subtitleRight = subtitleRight - mTitleMarginEnd;
                     titleTop = subtitleBottom + lp.bottomMargin;
                 }
-                right = Math.min(titleRight, subtitleRight);
+                if (titleHasWidth) {
+                    right = Math.min(titleRight, subtitleRight);
+                }
             } else {
-                final int ld = mTitleMarginStart - collapsingMargins[0];
+                final int ld = (titleHasWidth ? mTitleMarginStart : 0) - collapsingMargins[0];
                 left += Math.max(0, ld);
                 collapsingMargins[0] = Math.max(0, -ld);
                 int titleLeft = left;
@@ -1351,7 +1470,9 @@
                     subtitleLeft = subtitleRight + mTitleMarginEnd;
                     titleTop = subtitleBottom + lp.bottomMargin;
                 }
-                left = Math.max(titleLeft, subtitleLeft);
+                if (titleHasWidth) {
+                    left = Math.max(titleLeft, subtitleLeft);
+                }
             }
         }
 
@@ -1361,13 +1482,15 @@
         addCustomViewsWithGravity(mTempViews, Gravity.LEFT);
         final int leftViewsCount = mTempViews.size();
         for (int i = 0; i < leftViewsCount; i++) {
-            left = layoutChildLeft(mTempViews.get(i), left, collapsingMargins);
+            left = layoutChildLeft(mTempViews.get(i), left, collapsingMargins,
+                    alignmentHeight);
         }
 
         addCustomViewsWithGravity(mTempViews, Gravity.RIGHT);
         final int rightViewsCount = mTempViews.size();
         for (int i = 0; i < rightViewsCount; i++) {
-            right = layoutChildRight(mTempViews.get(i), right, collapsingMargins);
+            right = layoutChildRight(mTempViews.get(i), right, collapsingMargins,
+                    alignmentHeight);
         }
 
         // Centered views try to center with respect to the whole bar, but views pinned
@@ -1386,8 +1509,10 @@
 
         final int centerViewsCount = mTempViews.size();
         for (int i = 0; i < centerViewsCount; i++) {
-            centerLeft = layoutChildLeft(mTempViews.get(i), centerLeft, collapsingMargins);
+            centerLeft = layoutChildLeft(mTempViews.get(i), centerLeft, collapsingMargins,
+                    alignmentHeight);
         }
+
         mTempViews.clear();
     }
 
@@ -1410,46 +1535,49 @@
         return width;
     }
 
-    private int layoutChildLeft(View child, int left, int[] collapsingMargins) {
+    private int layoutChildLeft(View child, int left, int[] collapsingMargins,
+            int alignmentHeight) {
         final LayoutParams lp = (LayoutParams) child.getLayoutParams();
         final int l = lp.leftMargin - collapsingMargins[0];
         left += Math.max(0, l);
         collapsingMargins[0] = Math.max(0, -l);
-        final int top = getChildTop(child);
+        final int top = getChildTop(child, alignmentHeight);
         final int childWidth = child.getMeasuredWidth();
         child.layout(left, top, left + childWidth, top + child.getMeasuredHeight());
         left += childWidth + lp.rightMargin;
         return left;
     }
 
-    private int layoutChildRight(View child, int right, int[] collapsingMargins) {
+    private int layoutChildRight(View child, int right, int[] collapsingMargins,
+            int alignmentHeight) {
         final LayoutParams lp = (LayoutParams) child.getLayoutParams();
         final int r = lp.rightMargin - collapsingMargins[1];
         right -= Math.max(0, r);
         collapsingMargins[1] = Math.max(0, -r);
-        final int top = getChildTop(child);
+        final int top = getChildTop(child, alignmentHeight);
         final int childWidth = child.getMeasuredWidth();
         child.layout(right - childWidth, top, right, top + child.getMeasuredHeight());
         right -= childWidth + lp.leftMargin;
         return right;
     }
 
-    private int getChildTop(View child) {
+    private int getChildTop(View child, int alignmentHeight) {
         final LayoutParams lp = (LayoutParams) child.getLayoutParams();
+        final int childHeight = child.getMeasuredHeight();
+        final int alignmentOffset = alignmentHeight > 0 ? (childHeight - alignmentHeight) / 2 : 0;
         switch (getChildVerticalGravity(lp.gravity)) {
             case Gravity.TOP:
-                return getPaddingTop();
+                return getPaddingTop() - alignmentOffset;
 
             case Gravity.BOTTOM:
-                return getHeight() - getPaddingBottom() -
-                        child.getMeasuredHeight() - lp.bottomMargin;
+                return getHeight() - getPaddingBottom() - childHeight
+                        - lp.bottomMargin - alignmentOffset;
 
             default:
             case Gravity.CENTER_VERTICAL:
                 final int paddingTop = getPaddingTop();
                 final int paddingBottom = getPaddingBottom();
                 final int height = getHeight();
-                final int childHeight = child.getMeasuredHeight();
                 final int space = height - paddingTop - paddingBottom;
                 int spaceAbove = (space - childHeight) / 2;
                 if (spaceAbove < lp.topMargin) {
@@ -1591,6 +1719,13 @@
         }
     }
 
+    private void updateChildVisibilityForExpandedActionView(View child) {
+        final LayoutParams lp = (LayoutParams) child.getLayoutParams();
+        if (lp.mViewType != LayoutParams.EXPANDED && child != mMenuView) {
+            child.setVisibility(mExpandedActionView != null ? GONE : VISIBLE);
+        }
+    }
+
     /**
      * Force the toolbar to collapse to zero-height during measurement if
      * it could be considered "empty" (no visible elements with nonzero measured size)
@@ -1602,6 +1737,15 @@
     }
 
     /**
+     * Must be called before the menu is accessed
+     * @hide
+     */
+    public void setMenuCallbacks(MenuPresenter.Callback pcb, MenuBuilder.Callback mcb) {
+        mActionMenuPresenterCallback = pcb;
+        mMenuBuilderCallback = mcb;
+    }
+
+    /**
      * Interface responsible for receiving menu item click events if the items themselves
      * do not have individual item click listeners.
      */
@@ -1673,8 +1817,13 @@
     }
 
     static class SavedState extends BaseSavedState {
+        public int expandedMenuItemId;
+        public boolean isOverflowOpen;
+
         public SavedState(Parcel source) {
             super(source);
+            expandedMenuItemId = source.readInt();
+            isOverflowOpen = source.readInt() != 0;
         }
 
         public SavedState(Parcelable superState) {
@@ -1684,6 +1833,8 @@
         @Override
         public void writeToParcel(Parcel out, int flags) {
             super.writeToParcel(out, flags);
+            out.writeInt(expandedMenuItemId);
+            out.writeInt(isOverflowOpen ? 1 : 0);
         }
 
         public static final Creator<SavedState> CREATOR = new Creator<SavedState>() {
diff --git a/core/java/android/widget/VideoView.java b/core/java/android/widget/VideoView.java
index 8ee0a1b..572cca2 100644
--- a/core/java/android/widget/VideoView.java
+++ b/core/java/android/widget/VideoView.java
@@ -230,16 +230,33 @@
         mTargetState  = STATE_IDLE;
     }
 
+    /**
+     * Sets video path.
+     *
+     * @param path the path of the video.
+     */
     public void setVideoPath(String path) {
         setVideoURI(Uri.parse(path));
     }
 
+    /**
+     * Sets video URI.
+     *
+     * @param uri the URI of the video.
+     */
     public void setVideoURI(Uri uri) {
         setVideoURI(uri, null);
     }
 
     /**
-     * @hide
+     * Sets video URI using specific headers.
+     *
+     * @param uri     the URI of the video.
+     * @param headers the headers for the URI request.
+     *                Note that the cross domain redirection is allowed by default, but that can be
+     *                changed with key/value pairs through the headers parameter with
+     *                "android-allow-cross-domain-redirect" as the key and "0" or "1" as the value
+     *                to disallow or allow cross domain redirection.
      */
     public void setVideoURI(Uri uri, Map<String, String> headers) {
         mUri = uri;
diff --git a/core/java/android/widget/YearPickerView.java b/core/java/android/widget/YearPickerView.java
index 94c21dc..2bf07f9 100644
--- a/core/java/android/widget/YearPickerView.java
+++ b/core/java/android/widget/YearPickerView.java
@@ -70,15 +70,6 @@
                 R.dimen.datepicker_year_picker_padding_top);
         setPadding(0, paddingTop, 0, 0);
 
-        // Use Theme attributes if possible
-        final TypedArray a = context.obtainStyledAttributes(
-                attrs, R.styleable.DatePicker, defStyleAttr, defStyleRes);
-        final int colorResId = a.getResourceId(R.styleable.DatePicker_yearListSelectorColor,
-                R.color.datepicker_default_circle_background_color_holo_light);
-        mYearSelectedCircleColor = res.getColor(colorResId);
-
-        a.recycle();
-
         setOnItemClickListener(this);
         setDividerHeight(0);
     }
diff --git a/core/java/com/android/internal/app/AlertController.java b/core/java/com/android/internal/app/AlertController.java
index c409520..0183e45 100644
--- a/core/java/com/android/internal/app/AlertController.java
+++ b/core/java/com/android/internal/app/AlertController.java
@@ -63,63 +63,46 @@
     private final Context mContext;
     private final DialogInterface mDialogInterface;
     private final Window mWindow;
-    
+
     private CharSequence mTitle;
-
     private CharSequence mMessage;
-
     private ListView mListView;
-    
     private View mView;
 
     private int mViewLayoutResId;
 
     private int mViewSpacingLeft;
-    
     private int mViewSpacingTop;
-    
     private int mViewSpacingRight;
-    
     private int mViewSpacingBottom;
-    
     private boolean mViewSpacingSpecified = false;
-    
+
     private Button mButtonPositive;
-
     private CharSequence mButtonPositiveText;
-
     private Message mButtonPositiveMessage;
 
     private Button mButtonNegative;
-
     private CharSequence mButtonNegativeText;
-
     private Message mButtonNegativeMessage;
 
     private Button mButtonNeutral;
-
     private CharSequence mButtonNeutralText;
-
     private Message mButtonNeutralMessage;
 
     private ScrollView mScrollView;
-    
+
     private int mIconId = 0;
-    
     private Drawable mIcon;
-    
+
     private ImageView mIconView;
-    
     private TextView mTitleView;
-
     private TextView mMessageView;
-
     private View mCustomTitleView;
-    
+
     private boolean mForceInverseBackground;
-    
+
     private ListAdapter mAdapter;
-    
+
     private int mCheckedItem = -1;
 
     private int mAlertDialogLayout;
@@ -130,7 +113,7 @@
     private int mListItemLayout;
 
     private int mButtonPanelLayoutHint = AlertDialog.LAYOUT_HINT_NONE;
-    
+
     private Handler mHandler;
 
     private final View.OnClickListener mButtonHandler = new View.OnClickListener() {
@@ -160,7 +143,7 @@
     private static final class ButtonHandler extends Handler {
         // Button clicks have Message.what as the BUTTON{1,2,3} constant
         private static final int MSG_DISMISS_DIALOG = 1;
-        
+
         private WeakReference<DialogInterface> mDialog;
 
         public ButtonHandler(DialogInterface dialog) {
@@ -170,13 +153,13 @@
         @Override
         public void handleMessage(Message msg) {
             switch (msg.what) {
-                
+
                 case DialogInterface.BUTTON_POSITIVE:
                 case DialogInterface.BUTTON_NEGATIVE:
                 case DialogInterface.BUTTON_NEUTRAL:
                     ((DialogInterface.OnClickListener) msg.obj).onClick(mDialog.get(), msg.what);
                     break;
-                    
+
                 case MSG_DISMISS_DIALOG:
                     ((DialogInterface) msg.obj).dismiss();
             }
@@ -220,16 +203,16 @@
 
         a.recycle();
     }
-    
+
     static boolean canTextInput(View v) {
         if (v.onCheckIsTextEditor()) {
             return true;
         }
-        
+
         if (!(v instanceof ViewGroup)) {
             return false;
         }
-        
+
         ViewGroup vg = (ViewGroup)v;
         int i = vg.getChildCount();
         while (i > 0) {
@@ -239,10 +222,10 @@
                 return true;
             }
         }
-        
+
         return false;
     }
-    
+
     public void installContent() {
         /* We use a custom title so never request a window title */
         mWindow.requestFeature(Window.FEATURE_NO_TITLE);
@@ -262,7 +245,7 @@
         // TODO: use layout hint side for long messages/lists
         return mAlertDialogLayout;
     }
-    
+
     public void setTitle(CharSequence title) {
         mTitle = title;
         if (mTitleView != null) {
@@ -276,7 +259,7 @@
     public void setCustomTitle(View customTitleView) {
         mCustomTitleView = customTitleView;
     }
-    
+
     public void setMessage(CharSequence message) {
         mMessage = message;
         if (mMessageView != null) {
@@ -301,7 +284,7 @@
         mViewLayoutResId = 0;
         mViewSpacingSpecified = false;
     }
-    
+
     /**
      * Set the view to display in the dialog along with the spacing around that view
      */
@@ -326,7 +309,7 @@
     /**
      * Sets a click listener or a message to be sent when the button is clicked.
      * You only need to pass one of {@code listener} or {@code msg}.
-     * 
+     *
      * @param whichButton Which button, can be one of
      *            {@link DialogInterface#BUTTON_POSITIVE},
      *            {@link DialogInterface#BUTTON_NEGATIVE}, or
@@ -341,24 +324,24 @@
         if (msg == null && listener != null) {
             msg = mHandler.obtainMessage(whichButton, listener);
         }
-        
+
         switch (whichButton) {
 
             case DialogInterface.BUTTON_POSITIVE:
                 mButtonPositiveText = text;
                 mButtonPositiveMessage = msg;
                 break;
-                
+
             case DialogInterface.BUTTON_NEGATIVE:
                 mButtonNegativeText = text;
                 mButtonNegativeMessage = msg;
                 break;
-                
+
             case DialogInterface.BUTTON_NEUTRAL:
                 mButtonNeutralText = text;
                 mButtonNeutralMessage = msg;
                 break;
-                
+
             default:
                 throw new IllegalArgumentException("Button does not exist");
         }
@@ -416,11 +399,11 @@
     public void setInverseBackgroundForced(boolean forceInverseBackground) {
         mForceInverseBackground = forceInverseBackground;
     }
-    
+
     public ListView getListView() {
         return mListView;
     }
-    
+
     public Button getButton(int whichButton) {
         switch (whichButton) {
             case DialogInterface.BUTTON_POSITIVE:
@@ -433,7 +416,7 @@
                 return null;
         }
     }
-    
+
     @SuppressWarnings({"UnusedDeclaration"})
     public boolean onKeyDown(int keyCode, KeyEvent event) {
         return mScrollView != null && mScrollView.executeKeyEvent(event);
@@ -469,15 +452,19 @@
         final LinearLayout contentPanel = (LinearLayout) mWindow.findViewById(R.id.contentPanel);
         setupContent(contentPanel);
         final boolean hasButtons = setupButtons();
-        
+
         final LinearLayout topPanel = (LinearLayout) mWindow.findViewById(R.id.topPanel);
         final TypedArray a = mContext.obtainStyledAttributes(
                 null, R.styleable.AlertDialog, R.attr.alertDialogStyle, 0);
         final boolean hasTitle = setupTitle(topPanel);
-            
+
         final View buttonPanel = mWindow.findViewById(R.id.buttonPanel);
         if (!hasButtons) {
             buttonPanel.setVisibility(View.GONE);
+            final View spacer = mWindow.findViewById(R.id.textSpacerNoButtons);
+            if (spacer != null) {
+                spacer.setVisibility(View.VISIBLE);
+            }
             mWindow.setCloseOnTouchOutsideIfNotSet(true);
         }
 
@@ -536,14 +523,14 @@
 
     private boolean setupTitle(LinearLayout topPanel) {
         boolean hasTitle = true;
-        
+
         if (mCustomTitleView != null) {
             // Add the custom title view directly to the topPanel layout
             LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(
                     LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT);
-            
+
             topPanel.addView(mCustomTitleView, 0, lp);
-            
+
             // Hide the title template
             View titleTemplate = mWindow.findViewById(R.id.title_template);
             titleTemplate.setVisibility(View.GONE);
@@ -587,19 +574,19 @@
     private void setupContent(LinearLayout contentPanel) {
         mScrollView = (ScrollView) mWindow.findViewById(R.id.scrollView);
         mScrollView.setFocusable(false);
-        
+
         // Special case for users that only want to display a String
         mMessageView = (TextView) mWindow.findViewById(R.id.message);
         if (mMessageView == null) {
             return;
         }
-        
+
         if (mMessage != null) {
             mMessageView.setText(mMessage);
         } else {
             mMessageView.setVisibility(View.GONE);
             mScrollView.removeView(mMessageView);
-            
+
             if (mListView != null) {
                 contentPanel.removeView(mWindow.findViewById(R.id.scrollView));
                 contentPanel.addView(mListView,
@@ -664,7 +651,7 @@
                 centerButton(mButtonNeutral);
             }
         }
-        
+
         return whichButtons != 0;
     }
 
@@ -694,7 +681,12 @@
         int centerBright = 0;
         int bottomBright = 0;
         int bottomMedium = 0;
-        if (mContext.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.KITKAT) {
+
+        // If the needsDefaultBackgrounds attribute is set, we know we're
+        // inheriting from a framework style.
+        final boolean needsDefaultBackgrounds = a.getBoolean(
+                R.styleable.AlertDialog_needsDefaultBackgrounds, true);
+        if (needsDefaultBackgrounds) {
             fullDark = R.drawable.popup_full_dark;
             topDark = R.drawable.popup_top_dark;
             centerDark = R.drawable.popup_center_dark;
@@ -705,12 +697,12 @@
             bottomBright = R.drawable.popup_bottom_bright;
             bottomMedium = R.drawable.popup_bottom_medium;
         }
+
         topBright = a.getResourceId(R.styleable.AlertDialog_topBright, topBright);
         topDark = a.getResourceId(R.styleable.AlertDialog_topDark, topDark);
         centerBright = a.getResourceId(R.styleable.AlertDialog_centerBright, centerBright);
         centerDark = a.getResourceId(R.styleable.AlertDialog_centerDark, centerDark);
 
-
         /* We now set the background of all of the sections of the alert.
          * First collect together each section that is being displayed along
          * with whether it is on a light or dark background, then run through
@@ -789,31 +781,6 @@
             }
         }
 
-        /* TODO: uncomment section below. The logic for this should be if 
-         * it's a Contextual menu being displayed AND only a Cancel button 
-         * is shown then do this.
-         */
-//        if (hasButtons && (mListView != null)) {
-            
-            /* Yet another *special* case. If there is a ListView with buttons
-             * don't put the buttons on the bottom but instead put them in the
-             * footer of the ListView this will allow more items to be
-             * displayed.
-             */
-            
-            /*
-            contentPanel.setBackgroundResource(bottomBright);
-            buttonPanel.setBackgroundResource(centerMedium);
-            ViewGroup parent = (ViewGroup) mWindow.findViewById(R.id.parentPanel);
-            parent.removeView(buttonPanel);
-            AbsListView.LayoutParams params = new AbsListView.LayoutParams(
-                    AbsListView.LayoutParams.MATCH_PARENT, 
-                    AbsListView.LayoutParams.MATCH_PARENT);
-            buttonPanel.setLayoutParams(params);
-            mListView.addFooterView(buttonPanel);
-            */
-//        }
-
         final ListView listView = mListView;
         if (listView != null && mAdapter != null) {
             listView.setAdapter(mAdapter);
@@ -854,7 +821,7 @@
     public static class AlertParams {
         public final Context mContext;
         public final LayoutInflater mInflater;
-        
+
         public int mIconId = 0;
         public Drawable mIcon;
         public int mIconAttrId = 0;
@@ -899,20 +866,20 @@
          * will be bound to an adapter.
          */
         public interface OnPrepareListViewListener {
-            
+
             /**
              * Called before the ListView is bound to an adapter.
              * @param listView The ListView that will be shown in the dialog.
              */
             void onPrepareListView(ListView listView);
         }
-        
+
         public AlertParams(Context context) {
             mContext = context;
             mCancelable = true;
             mInflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
         }
-    
+
         public void apply(AlertController dialog) {
             if (mCustomTitleView != null) {
                 dialog.setCustomTitle(mCustomTitleView);
@@ -972,12 +939,12 @@
             }
             */
         }
-        
+
         private void createListView(final AlertController dialog) {
             final RecycleListView listView = (RecycleListView)
                     mInflater.inflate(dialog.mListLayout, null);
             ListAdapter adapter;
-            
+
             if (mIsMultiChoice) {
                 if (mCursor == null) {
                     adapter = new ArrayAdapter<CharSequence>(
@@ -1012,37 +979,37 @@
                             listView.setItemChecked(cursor.getPosition(),
                                     cursor.getInt(mIsCheckedIndex) == 1);
                         }
-    
+
                         @Override
                         public View newView(Context context, Cursor cursor, ViewGroup parent) {
                             return mInflater.inflate(dialog.mMultiChoiceItemLayout,
                                     parent, false);
                         }
-                        
+
                     };
                 }
             } else {
-                int layout = mIsSingleChoice 
+                int layout = mIsSingleChoice
                         ? dialog.mSingleChoiceItemLayout : dialog.mListItemLayout;
                 if (mCursor == null) {
                     adapter = (mAdapter != null) ? mAdapter
                             : new CheckedItemAdapter(mContext, layout, R.id.text1, mItems);
                 } else {
-                    adapter = new SimpleCursorAdapter(mContext, layout, 
+                    adapter = new SimpleCursorAdapter(mContext, layout,
                             mCursor, new String[]{mLabelColumn}, new int[]{R.id.text1});
                 }
             }
-            
+
             if (mOnPrepareListViewListener != null) {
                 mOnPrepareListViewListener.onPrepareListView(listView);
             }
-            
+
             /* Don't directly set the adapter on the ListView as we might
              * want to add a footer to the ListView later.
              */
             dialog.mAdapter = adapter;
             dialog.mCheckedItem = mCheckedItem;
-            
+
             if (mOnClickListener != null) {
                 listView.setOnItemClickListener(new OnItemClickListener() {
                     @Override
@@ -1065,12 +1032,12 @@
                     }
                 });
             }
-            
+
             // Attach a given OnItemSelectedListener to the ListView
             if (mOnItemSelectedListener != null) {
                 listView.setOnItemSelectedListener(mOnItemSelectedListener);
             }
-            
+
             if (mIsSingleChoice) {
                 listView.setChoiceMode(ListView.CHOICE_MODE_SINGLE);
             } else if (mIsMultiChoice) {
diff --git a/core/java/com/android/internal/app/ChooserActivity.java b/core/java/com/android/internal/app/ChooserActivity.java
index cd922a1..5267811 100644
--- a/core/java/com/android/internal/app/ChooserActivity.java
+++ b/core/java/com/android/internal/app/ChooserActivity.java
@@ -60,6 +60,7 @@
                 initialIntents[i] = in;
             }
         }
+        setSafeForwardingMode(true);
         super.onCreate(savedInstanceState, target, title, defaultTitleRes, initialIntents,
                 null, false);
     }
diff --git a/core/java/com/android/internal/app/IMediaContainerService.aidl b/core/java/com/android/internal/app/IMediaContainerService.aidl
index 7a3ffdf..81ea191 100644
--- a/core/java/com/android/internal/app/IMediaContainerService.aidl
+++ b/core/java/com/android/internal/app/IMediaContainerService.aidl
@@ -25,10 +25,7 @@
             boolean isExternal, boolean isForwardLocked, String abiOverride);
     int copyPackage(String packagePath, in IParcelFileDescriptorFactory target);
 
-    PackageInfoLite getMinimalPackageInfo(String packagePath, int flags, long threshold,
-            String abiOverride);
-    boolean checkInternalFreeStorage(String packagePath, boolean isForwardLocked, long threshold);
-    boolean checkExternalFreeStorage(String packagePath, boolean isForwardLocked, String abiOverride);
+    PackageInfoLite getMinimalPackageInfo(String packagePath, int flags, String abiOverride);
     ObbInfo getObbInfo(String filename);
     long calculateDirectorySize(String directory);
     /** Return file system stats: [0] is total bytes, [1] is available bytes */
diff --git a/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl b/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl
index 22ec4be..5a10524 100644
--- a/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl
+++ b/core/java/com/android/internal/app/IVoiceInteractionManagerService.aidl
@@ -33,32 +33,44 @@
     void finish(IBinder token);
 
     /**
-     * Lists the registered Sound model for keyphrase detection.
-     * May be null if no matching sound models exist.
+     * Gets the registered Sound model for keyphrase detection for the current user.
+     * May be null if no matching sound model exists.
+     *
+     * @param keyphraseId The unique identifier for the keyphrase.
+     * @param bcp47Locale The BCP47 language tag  for the keyphrase's locale.
      */
-    SoundTrigger.KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId);
+    SoundTrigger.KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId, in String bcp47Locale);
     /**
-     * Updates the given keyphrase sound model. Adds the model if it doesn't exist currently.
+     * Add/Update the given keyphrase sound model.
      */
     int updateKeyphraseSoundModel(in SoundTrigger.KeyphraseSoundModel model);
     /**
-     * Deletes the given keyphrase sound model.
+     * Deletes the given keyphrase sound model for the current user.
+     *
+     * @param keyphraseId The unique identifier for the keyphrase.
+     * @param bcp47Locale The BCP47 language tag  for the keyphrase's locale.
      */
-    int deleteKeyphraseSoundModel(int keyphraseId);
+    int deleteKeyphraseSoundModel(int keyphraseId, in String bcp47Locale);
 
     /**
-     * Indicates if there's a keyphrase sound model available for the given keyphrase ID.
-     */
-    boolean isEnrolledForKeyphrase(IVoiceInteractionService service, int keyphraseId);
-    /**
      * Gets the properties of the DSP hardware on this device, null if not present.
      */
     SoundTrigger.ModuleProperties getDspModuleProperties(in IVoiceInteractionService service);
     /**
+     * Indicates if there's a keyphrase sound model available for the given keyphrase ID.
+     * This performs the check for the current user.
+     *
+     * @param service The current VoiceInteractionService.
+     * @param keyphraseId The unique identifier for the keyphrase.
+     * @param bcp47Locale The BCP47 language tag  for the keyphrase's locale.
+     */
+    boolean isEnrolledForKeyphrase(IVoiceInteractionService service, int keyphraseId,
+            String bcp47Locale);
+    /**
      * Starts a recognition for the given keyphrase.
      */
     int startRecognition(in IVoiceInteractionService service, int keyphraseId,
-            in IRecognitionStatusCallback callback,
+            in String bcp47Locale, in IRecognitionStatusCallback callback,
             in SoundTrigger.RecognitionConfig recognitionConfig);
     /**
      * Stops a recognition for the given keyphrase.
diff --git a/core/java/com/android/internal/app/IntentForwarderActivity.java b/core/java/com/android/internal/app/IntentForwarderActivity.java
index af38b3e..d9493752 100644
--- a/core/java/com/android/internal/app/IntentForwarderActivity.java
+++ b/core/java/com/android/internal/app/IntentForwarderActivity.java
@@ -76,17 +76,19 @@
         }
         Intent newIntent = new Intent(intentReceived);
         newIntent.setComponent(null);
+        // Apps should not be allowed to target a specific package in the target user.
+        newIntent.setPackage(null);
         newIntent.addFlags(Intent.FLAG_ACTIVITY_FORWARD_RESULT
                 |Intent.FLAG_ACTIVITY_PREVIOUS_IS_TOP);
         int callingUserId = getUserId();
         IPackageManager ipm = AppGlobals.getPackageManager();
         String resolvedType = newIntent.resolveTypeIfNeeded(getContentResolver());
         boolean canForward = false;
+        Intent selector = newIntent.getSelector();
+        if (selector == null) {
+            selector = newIntent;
+        }
         try {
-            Intent selector = newIntent.getSelector();
-            if (selector == null) {
-                selector = newIntent;
-            }
             canForward = ipm.canForwardTo(selector, resolvedType, callingUserId,
                     userDest.getIdentifier());
         } catch (RemoteException e) {
diff --git a/core/java/com/android/internal/app/LocalePicker.java b/core/java/com/android/internal/app/LocalePicker.java
index 229df8f..1f0bb76 100644
--- a/core/java/com/android/internal/app/LocalePicker.java
+++ b/core/java/com/android/internal/app/LocalePicker.java
@@ -27,6 +27,7 @@
 import android.content.res.Resources;
 import android.os.Bundle;
 import android.os.RemoteException;
+import android.provider.Settings;
 import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
@@ -50,10 +51,6 @@
         public void onLocaleSelected(Locale locale);
     }
 
-    protected boolean isInDeveloperMode() {
-        return false;
-    }
-
     LocaleSelectionListener mListener;  // default to null
 
     public static class LocaleInfo implements Comparable<LocaleInfo> {
@@ -86,40 +83,17 @@
         }
     }
 
-    /**
-     * Constructs an Adapter object containing Locale information. Content is sorted by
-     * {@link LocaleInfo#label}.
-     */
-    public static ArrayAdapter<LocaleInfo> constructAdapter(Context context) {
-        return constructAdapter(context, false /* disable pesudolocales */);
-    }
-
-    public static ArrayAdapter<LocaleInfo> constructAdapter(Context context,
-                                                            final boolean isInDeveloperMode) {
-        return constructAdapter(context, R.layout.locale_picker_item, R.id.locale,
-                isInDeveloperMode);
-    }
-
-    public static ArrayAdapter<LocaleInfo> constructAdapter(Context context,
-            final int layoutId, final int fieldId) {
-        return constructAdapter(context, layoutId, fieldId, false /* disable pseudolocales */);
-    }
-
     public static List<LocaleInfo> getAllAssetLocales(Context context, boolean isInDeveloperMode) {
         final Resources resources = context.getResources();
 
         final String[] locales = Resources.getSystem().getAssets().getLocales();
         List<String> localeList = new ArrayList<String>(locales.length);
         Collections.addAll(localeList, locales);
-        if (isInDeveloperMode) {
-            if (!localeList.contains("zz_ZZ")) {
-                localeList.add("zz_ZZ");
-            }
-            /** - TODO: Enable when zz_ZY Pseudolocale is complete
-             *  if (!localeList.contains("zz_ZY")) {
-             *      localeList.add("zz_ZY");
-             *	}
-             */
+
+        // Don't show the pseudolocales unless we're in developer mode. http://b/17190407.
+        if (!isInDeveloperMode) {
+            localeList.remove("ar-XB");
+            localeList.remove("en-XA");
         }
 
         Collections.sort(localeList);
@@ -160,14 +134,7 @@
                     localeInfos.add(new LocaleInfo(toTitleCase(
                             getDisplayName(l, specialLocaleCodes, specialLocaleNames)), l));
                 } else {
-                    String displayName;
-                    if (locale.equals("zz_ZZ")) {
-                        displayName = "[Developer] Accented English";
-                    } else if (locale.equals("zz_ZY")) {
-                        displayName = "[Developer] Fake Bi-Directional";
-                    } else {
-                        displayName = toTitleCase(l.getDisplayLanguage(l));
-                    }
+                    String displayName = toTitleCase(l.getDisplayLanguage(l));
                     if (DEBUG) {
                         Log.v(TAG, "adding "+displayName);
                     }
@@ -180,8 +147,18 @@
         return localeInfos;
     }
 
+    /**
+     * Constructs an Adapter object containing Locale information. Content is sorted by
+     * {@link LocaleInfo#label}.
+     */
+    public static ArrayAdapter<LocaleInfo> constructAdapter(Context context) {
+        return constructAdapter(context, R.layout.locale_picker_item, R.id.locale);
+    }
+
     public static ArrayAdapter<LocaleInfo> constructAdapter(Context context,
-            final int layoutId, final int fieldId, final boolean isInDeveloperMode) {
+            final int layoutId, final int fieldId) {
+        boolean isInDeveloperMode = Settings.Global.getInt(context.getContentResolver(),
+                Settings.Global.DEVELOPMENT_SETTINGS_ENABLED, 0) != 0;
         final List<LocaleInfo> localeInfos = getAllAssetLocales(context, isInDeveloperMode);
 
         final LayoutInflater inflater =
@@ -232,8 +209,7 @@
     @Override
     public void onActivityCreated(final Bundle savedInstanceState) {
         super.onActivityCreated(savedInstanceState);
-        final ArrayAdapter<LocaleInfo> adapter = constructAdapter(getActivity(),
-                isInDeveloperMode());
+        final ArrayAdapter<LocaleInfo> adapter = constructAdapter(getActivity());
         setListAdapter(adapter);
     }
 
diff --git a/core/java/com/android/internal/app/ResolverActivity.java b/core/java/com/android/internal/app/ResolverActivity.java
index b1727fa..22600de 100644
--- a/core/java/com/android/internal/app/ResolverActivity.java
+++ b/core/java/com/android/internal/app/ResolverActivity.java
@@ -17,10 +17,13 @@
 package com.android.internal.app;
 
 import android.app.Activity;
+import android.app.ActivityThread;
 import android.app.usage.UsageStats;
 import android.app.usage.UsageStatsManager;
 import android.os.AsyncTask;
-import android.util.ArrayMap;
+import android.provider.Settings;
+import android.text.TextUtils;
+import android.util.Slog;
 import android.widget.AbsListView;
 import android.widget.GridView;
 import com.android.internal.R;
@@ -69,6 +72,7 @@
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Map;
 import java.util.Set;
 
 /**
@@ -83,9 +87,10 @@
     private int mLaunchedFromUid;
     private ResolveListAdapter mAdapter;
     private PackageManager mPm;
+    private boolean mSafeForwardingMode;
     private boolean mAlwaysUseOption;
     private boolean mShowExtended;
-    private GridView mGridView;
+    private ListView mListView;
     private Button mAlwaysButton;
     private Button mOnceButton;
     private int mIconDpi;
@@ -95,7 +100,7 @@
     private boolean mResolvingHome = false;
 
     private UsageStatsManager mUsm;
-    private ArrayMap<String, UsageStats> mStats;
+    private Map<String, UsageStats> mStats;
     private static final long USAGE_STATS_PERIOD = 1000 * 60 * 60 * 24 * 14;
 
     private boolean mRegistered;
@@ -175,6 +180,8 @@
             titleResource = 0;
         }
 
+        setSafeForwardingMode(true);
+
         onCreate(savedInstanceState, intent,
                 titleResource != 0 ? getResources().getText(titleResource) : null, titleResource,
                 null, null, true);
@@ -221,10 +228,13 @@
                 mLaunchedFromUid, alwaysUseOption);
 
         final int layoutId;
+        final boolean useHeader;
         if (mAdapter.hasFilteredItem()) {
             layoutId = R.layout.resolver_list_with_default;
             alwaysUseOption = false;
+            useHeader = true;
         } else {
+            useHeader = false;
             layoutId = R.layout.resolver_list;
         }
         mAlwaysUseOption = alwaysUseOption;
@@ -236,18 +246,21 @@
             return;
         } else if (count > 1) {
             setContentView(layoutId);
-            mGridView = (GridView) findViewById(R.id.resolver_list);
-            mGridView.setAdapter(mAdapter);
-            mGridView.setOnItemClickListener(this);
-            mGridView.setOnItemLongClickListener(new ItemLongClickListener());
+            mListView = (ListView) findViewById(R.id.resolver_list);
+            mListView.setAdapter(mAdapter);
+            mListView.setOnItemClickListener(this);
+            mListView.setOnItemLongClickListener(new ItemLongClickListener());
 
             if (alwaysUseOption) {
-                mGridView.setChoiceMode(ListView.CHOICE_MODE_SINGLE);
+                mListView.setChoiceMode(ListView.CHOICE_MODE_SINGLE);
             }
 
-            resizeGrid();
+            if (useHeader) {
+                mListView.addHeaderView(LayoutInflater.from(this).inflate(
+                        R.layout.resolver_different_item_header, mListView, false));
+            }
         } else if (count == 1) {
-            startActivity(mAdapter.intentForPosition(0, false));
+            safelyStartActivity(mAdapter.intentForPosition(0, false));
             mPackageMonitor.unregister();
             mRegistered = false;
             finish();
@@ -258,8 +271,8 @@
             final TextView empty = (TextView) findViewById(R.id.empty);
             empty.setVisibility(View.VISIBLE);
 
-            mGridView = (GridView) findViewById(R.id.resolver_list);
-            mGridView.setVisibility(View.GONE);
+            mListView = (ListView) findViewById(R.id.resolver_list);
+            mListView.setVisibility(View.GONE);
         }
 
         final ResolverDrawerLayout rdl = (ResolverDrawerLayout) findViewById(R.id.contentPanel);
@@ -272,12 +285,15 @@
             });
         }
 
-        final TextView titleView = (TextView) findViewById(R.id.title);
-        if (titleView != null) {
-            if (title == null) {
-                title = getTitleForAction(intent.getAction(), defaultTitleRes);
+        if (title == null) {
+            title = getTitleForAction(intent.getAction(), defaultTitleRes);
+        }
+        if (!TextUtils.isEmpty(title)) {
+            final TextView titleView = (TextView) findViewById(R.id.title);
+            if (titleView != null) {
+                titleView.setText(title);
             }
-            titleView.setText(title);
+            setTitle(title);
         }
 
         final ImageView iconView = (ImageView) findViewById(R.id.icon);
@@ -303,6 +319,22 @@
         }
     }
 
+    /**
+     * Turn on launch mode that is safe to use when forwarding intents received from
+     * applications and running in system processes.  This mode uses Activity.startActivityAsCaller
+     * instead of the normal Activity.startActivity for launching the activity selected
+     * by the user.
+     *
+     * <p>This mode is set to true by default if the activity is initialized through
+     * {@link #onCreate(android.os.Bundle)}.  If a subclass calls one of the other onCreate
+     * methods, it is set to false by default.  You must set it before calling one of the
+     * more detailed onCreate methods, so that it will be set correctly in the case where
+     * there is only one intent to resolve and it is thus started immediately.</p>
+     */
+    public void setSafeForwardingMode(boolean safeForwarding) {
+        mSafeForwardingMode = safeForwarding;
+    }
+
     protected CharSequence getTitleForAction(String action, int defaultTitleRes) {
         final ActionTitle title = ActionTitle.forAction(action);
         final boolean named = mAdapter.hasFilteredItem();
@@ -314,11 +346,6 @@
         }
     }
 
-    void resizeGrid() {
-        final int itemCount = mAdapter.getCount();
-        mGridView.setNumColumns(Math.min(itemCount, mMaxColumns));
-    }
-
     void dismiss() {
         if (!isFinishing()) {
             finish();
@@ -393,19 +420,24 @@
     protected void onRestoreInstanceState(Bundle savedInstanceState) {
         super.onRestoreInstanceState(savedInstanceState);
         if (mAlwaysUseOption) {
-            final int checkedPos = mGridView.getCheckedItemPosition();
+            final int checkedPos = mListView.getCheckedItemPosition();
             final boolean hasValidSelection = checkedPos != ListView.INVALID_POSITION;
             mLastSelected = checkedPos;
             setAlwaysButtonEnabled(hasValidSelection, checkedPos, true);
             mOnceButton.setEnabled(hasValidSelection);
             if (hasValidSelection) {
-                mGridView.setSelection(checkedPos);
+                mListView.setSelection(checkedPos);
             }
         }
     }
 
     @Override
     public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
+        position -= mListView.getHeaderViewsCount();
+        if (position < 0) {
+            // Header views don't count.
+            return;
+        }
         ResolveInfo resolveInfo = mAdapter.resolveInfoForPosition(position, true);
         if (mResolvingHome && hasManagedProfile()
                 && !supportsManagedProfiles(resolveInfo)) {
@@ -415,13 +447,13 @@
                     Toast.LENGTH_LONG).show();
             return;
         }
-        final int checkedPos = mGridView.getCheckedItemPosition();
+        final int checkedPos = mListView.getCheckedItemPosition();
         final boolean hasValidSelection = checkedPos != ListView.INVALID_POSITION;
         if (mAlwaysUseOption && (!hasValidSelection || mLastSelected != checkedPos)) {
             setAlwaysButtonEnabled(hasValidSelection, checkedPos, true);
             mOnceButton.setEnabled(hasValidSelection);
             if (hasValidSelection) {
-                mGridView.smoothScrollToPosition(checkedPos);
+                mListView.smoothScrollToPosition(checkedPos);
             }
             mLastSelected = checkedPos;
         } else {
@@ -459,8 +491,7 @@
     }
 
     private boolean versionNumberAtLeastL(int versionNumber) {
-        // TODO: remove "|| true" once the build code for L is fixed.
-        return versionNumber >= Build.VERSION_CODES.L || true;
+        return versionNumber >= Build.VERSION_CODES.L;
     }
 
     private void setAlwaysButtonEnabled(boolean hasValidSelection, int checkedPos,
@@ -478,7 +509,7 @@
     public void onButtonClick(View v) {
         final int id = v.getId();
         startSelected(mAlwaysUseOption ?
-                mGridView.getCheckedItemPosition() : mAdapter.getFilteredPosition(),
+                mListView.getCheckedItemPosition() : mAdapter.getFilteredPosition(),
                 id == R.id.button_always,
                 mAlwaysUseOption);
         dismiss();
@@ -605,12 +636,33 @@
         }
 
         if (intent != null) {
+            safelyStartActivity(intent);
+        }
+    }
+
+    public void safelyStartActivity(Intent intent) {
+        if (!mSafeForwardingMode) {
             startActivity(intent);
+            return;
+        }
+        try {
+            startActivityAsCaller(intent, null);
+        } catch (RuntimeException e) {
+            String launchedFromPackage;
+            try {
+                launchedFromPackage = ActivityManagerNative.getDefault().getLaunchedFromPackage(
+                        getActivityToken());
+            } catch (RemoteException e2) {
+                launchedFromPackage = "??";
+            }
+            Slog.wtf(TAG, "Unable to launch as uid " + mLaunchedFromUid
+                    + " package " + launchedFromPackage + ", while running in "
+                    + ActivityThread.currentProcessName(), e);
         }
     }
 
     void showAppDetails(ResolveInfo ri) {
-        Intent in = new Intent().setAction("android.settings.APPLICATION_DETAILS_SETTINGS")
+        Intent in = new Intent().setAction(Settings.ACTION_APPLICATION_DETAILS_SETTINGS)
                 .setData(Uri.fromParts("package", ri.activityInfo.packageName, null))
                 .addFlags(Intent.FLAG_ACTIVITY_CLEAR_WHEN_TASK_RESET);
         startActivity(in);
@@ -667,8 +719,6 @@
             if (newItemCount == 0) {
                 // We no longer have any items...  just finish the activity.
                 finish();
-            } else if (newItemCount != oldItemCount) {
-                resizeGrid();
             }
         }
 
@@ -910,19 +960,13 @@
         }
 
         public View getView(int position, View convertView, ViewGroup parent) {
-            View view;
-            if (convertView == null) {
+            View view = convertView;
+            if (view == null) {
                 view = mInflater.inflate(
                         com.android.internal.R.layout.resolve_list_item, parent, false);
 
                 final ViewHolder holder = new ViewHolder(view);
                 view.setTag(holder);
-
-                // Fix the icon size even if we have different sized resources
-                ViewGroup.LayoutParams lp = holder.icon.getLayoutParams();
-                lp.width = lp.height = mIconSize;
-            } else {
-                view = convertView;
             }
             bindView(view, getItem(position));
             return view;
@@ -960,6 +1004,11 @@
 
         @Override
         public boolean onItemLongClick(AdapterView<?> parent, View view, int position, long id) {
+            position -= mListView.getHeaderViewsCount();
+            if (position < 0) {
+                // Header views don't count.
+                return false;
+            }
             ResolveInfo ri = mAdapter.resolveInfoForPosition(position, true);
             showAppDetails(ri);
             return true;
diff --git a/core/java/com/android/internal/app/ToolbarActionBar.java b/core/java/com/android/internal/app/ToolbarActionBar.java
index 96d7192..4410f25 100644
--- a/core/java/com/android/internal/app/ToolbarActionBar.java
+++ b/core/java/com/android/internal/app/ToolbarActionBar.java
@@ -29,9 +29,11 @@
 import android.view.MenuItem;
 import android.view.View;
 import android.view.Window;
+import android.view.WindowCallbackWrapper;
 import android.widget.SpinnerAdapter;
 import android.widget.Toolbar;
 import com.android.internal.view.menu.MenuBuilder;
+import com.android.internal.view.menu.MenuPresenter;
 import com.android.internal.widget.DecorToolbar;
 import com.android.internal.widget.ToolbarWidgetWrapper;
 
@@ -40,7 +42,9 @@
 public class ToolbarActionBar extends ActionBar {
     private Toolbar mToolbar;
     private DecorToolbar mDecorToolbar;
+    private boolean mToolbarMenuPrepared;
     private Window.Callback mWindowCallback;
+    private boolean mMenuCallbackSet;
 
     private boolean mLastMenuVisibility;
     private ArrayList<OnMenuVisibilityListener> mMenuVisibilityListeners =
@@ -64,12 +68,16 @@
     public ToolbarActionBar(Toolbar toolbar, CharSequence title, Window.Callback windowCallback) {
         mToolbar = toolbar;
         mDecorToolbar = new ToolbarWidgetWrapper(toolbar, false);
-        mWindowCallback = windowCallback;
+        mWindowCallback = new ToolbarCallbackWrapper(windowCallback);
         mDecorToolbar.setWindowCallback(mWindowCallback);
         toolbar.setOnMenuItemClickListener(mMenuClicker);
         mDecorToolbar.setWindowTitle(title);
     }
 
+    public Window.Callback getWrappedWindowCallback() {
+        return mWindowCallback;
+    }
+
     @Override
     public void setCustomView(View view) {
         setCustomView(view, new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
@@ -154,7 +162,7 @@
 
     @Override
     public void setHomeActionContentDescription(CharSequence description) {
-        mToolbar.setNavigationContentDescription(description);
+        mDecorToolbar.setNavigationContentDescription(description);
     }
 
     @Override
@@ -164,7 +172,7 @@
 
     @Override
     public void setHomeActionContentDescription(int resId) {
-        mToolbar.setNavigationContentDescription(resId);
+        mDecorToolbar.setNavigationContentDescription(resId);
     }
 
     @Override
@@ -220,6 +228,11 @@
     }
 
     @Override
+    public void setWindowTitle(CharSequence title) {
+        mDecorToolbar.setWindowTitle(title);
+    }
+
+    @Override
     public void setSubtitle(CharSequence subtitle) {
         mDecorToolbar.setSubtitle(subtitle);
     }
@@ -236,8 +249,8 @@
 
     @Override
     public void setDisplayOptions(@DisplayOptions int options, @DisplayOptions int mask) {
-        mDecorToolbar.setDisplayOptions((options & mask) |
-                mDecorToolbar.getDisplayOptions() & ~mask);
+        final int currentOptions = mDecorToolbar.getDisplayOptions();
+        mDecorToolbar.setDisplayOptions(options & mask | currentOptions & ~mask);
     }
 
     @Override
@@ -420,6 +433,10 @@
     }
 
     void populateOptionsMenu() {
+        if (!mMenuCallbackSet) {
+            mToolbar.setMenuCallbacks(new ActionMenuPresenterCallback(), new MenuBuilderCallback());
+            mMenuCallbackSet = true;
+        }
         final Menu menu = mToolbar.getMenu();
         final MenuBuilder mb = menu instanceof MenuBuilder ? (MenuBuilder) menu : null;
         if (mb != null) {
@@ -465,4 +482,67 @@
             mMenuVisibilityListeners.get(i).onMenuVisibilityChanged(isVisible);
         }
     }
+
+    private class ToolbarCallbackWrapper extends WindowCallbackWrapper {
+        public ToolbarCallbackWrapper(Window.Callback wrapped) {
+            super(wrapped);
+        }
+
+        @Override
+        public boolean onPreparePanel(int featureId, View view, Menu menu) {
+            final boolean result = super.onPreparePanel(featureId, view, menu);
+            if (result && !mToolbarMenuPrepared) {
+                mDecorToolbar.setMenuPrepared();
+                mToolbarMenuPrepared = true;
+            }
+            return result;
+        }
+    }
+
+    private final class ActionMenuPresenterCallback implements MenuPresenter.Callback {
+        private boolean mClosingActionMenu;
+
+        @Override
+        public boolean onOpenSubMenu(MenuBuilder subMenu) {
+            if (mWindowCallback != null) {
+                mWindowCallback.onMenuOpened(Window.FEATURE_ACTION_BAR, subMenu);
+                return true;
+            }
+            return false;
+        }
+
+        @Override
+        public void onCloseMenu(MenuBuilder menu, boolean allMenusAreClosing) {
+            if (mClosingActionMenu) {
+                return;
+            }
+
+            mClosingActionMenu = true;
+            mToolbar.dismissPopupMenus();
+            if (mWindowCallback != null) {
+                mWindowCallback.onPanelClosed(Window.FEATURE_ACTION_BAR, menu);
+            }
+            mClosingActionMenu = false;
+        }
+    }
+
+    private final class MenuBuilderCallback implements MenuBuilder.Callback {
+
+        @Override
+        public boolean onMenuItemSelected(MenuBuilder menu, MenuItem item) {
+            return false;
+        }
+
+        @Override
+        public void onMenuModeChange(MenuBuilder menu) {
+            if (mWindowCallback != null) {
+                if (mToolbar.isOverflowMenuShowing()) {
+                    mWindowCallback.onPanelClosed(Window.FEATURE_ACTION_BAR, menu);
+                } else if (mWindowCallback.onPreparePanel(Window.FEATURE_OPTIONS_PANEL,
+                        null, menu)) {
+                    mWindowCallback.onMenuOpened(Window.FEATURE_ACTION_BAR, menu);
+                }
+            }
+        }
+    }
 }
diff --git a/core/java/com/android/internal/app/WindowDecorActionBar.java b/core/java/com/android/internal/app/WindowDecorActionBar.java
index b5ff0cc..2377c22 100644
--- a/core/java/com/android/internal/app/WindowDecorActionBar.java
+++ b/core/java/com/android/internal/app/WindowDecorActionBar.java
@@ -431,6 +431,11 @@
         mDecorToolbar.setTitle(title);
     }
 
+    @Override
+    public void setWindowTitle(CharSequence title) {
+        mDecorToolbar.setWindowTitle(title);
+    }
+
     public void setSubtitle(CharSequence subtitle) {
         mDecorToolbar.setSubtitle(subtitle);
     }
@@ -861,14 +866,7 @@
 
         mDecorToolbar.animateToVisibility(toActionMode ? View.GONE : View.VISIBLE);
         mContextView.animateToVisibility(toActionMode ? View.VISIBLE : View.GONE);
-        if (mTabScrollView != null && !mDecorToolbar.hasEmbeddedTabs() &&
-                isCollapsed(mDecorToolbar.getViewGroup())) {
-            mTabScrollView.animateToVisibility(toActionMode ? View.GONE : View.VISIBLE);
-        }
-    }
-
-    private boolean isCollapsed(View view) {
-        return view == null || view.getVisibility() == View.GONE || view.getMeasuredHeight() == 0;
+        // mTabScrollView's visibility is not affected by action mode.
     }
 
     public Context getThemedContext() {
@@ -925,6 +923,15 @@
     public void onContentScrollStopped() {
     }
 
+    @Override
+    public boolean collapseActionView() {
+        if (mDecorToolbar != null && mDecorToolbar.hasExpandedActionView()) {
+            mDecorToolbar.collapseActionView();
+            return true;
+        }
+        return false;
+    }
+
     /**
      * @hide 
      */
diff --git a/core/java/com/android/internal/content/NativeLibraryHelper.java b/core/java/com/android/internal/content/NativeLibraryHelper.java
index d76d0d4..02f675c 100644
--- a/core/java/com/android/internal/content/NativeLibraryHelper.java
+++ b/core/java/com/android/internal/content/NativeLibraryHelper.java
@@ -19,15 +19,26 @@
 import static android.content.pm.PackageManager.INSTALL_FAILED_NO_MATCHING_ABIS;
 import static android.content.pm.PackageManager.INSTALL_SUCCEEDED;
 import static android.content.pm.PackageManager.NO_NATIVE_LIBRARIES;
+import static android.system.OsConstants.S_IRGRP;
+import static android.system.OsConstants.S_IROTH;
+import static android.system.OsConstants.S_IRWXU;
+import static android.system.OsConstants.S_IXGRP;
+import static android.system.OsConstants.S_IXOTH;
 
+import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager;
 import android.content.pm.PackageParser;
 import android.content.pm.PackageParser.Package;
 import android.content.pm.PackageParser.PackageLite;
 import android.content.pm.PackageParser.PackageParserException;
+import android.os.Build;
+import android.os.SELinux;
+import android.system.ErrnoException;
+import android.system.Os;
 import android.util.Slog;
 
 import dalvik.system.CloseGuard;
+import dalvik.system.VMRuntime;
 
 import java.io.Closeable;
 import java.io.File;
@@ -41,9 +52,15 @@
  */
 public class NativeLibraryHelper {
     private static final String TAG = "NativeHelper";
-
     private static final boolean DEBUG_NATIVE = false;
 
+    public static final String LIB_DIR_NAME = "lib";
+    public static final String LIB64_DIR_NAME = "lib64";
+
+    // Special value for {@code PackageParser.Package#cpuAbiOverride} to indicate
+    // that the cpuAbiOverride must be clear.
+    public static final String CLEAR_ABI_OVERRIDE = "-";
+
     /**
      * A handle to an opened package, consisting of one or more APKs. Used as
      * input to the various NativeLibraryHelper methods. Allows us to scan and
@@ -56,6 +73,7 @@
         private volatile boolean mClosed;
 
         final long[] apkHandles;
+        final boolean multiArch;
 
         public static Handle create(File packageFile) throws IOException {
             try {
@@ -67,14 +85,15 @@
         }
 
         public static Handle create(Package pkg) throws IOException {
-            return create(pkg.getAllCodePaths());
+            return create(pkg.getAllCodePaths(),
+                    (pkg.applicationInfo.flags & ApplicationInfo.FLAG_MULTIARCH) != 0);
         }
 
         public static Handle create(PackageLite lite) throws IOException {
-            return create(lite.getAllCodePaths());
+            return create(lite.getAllCodePaths(), lite.multiArch);
         }
 
-        private static Handle create(List<String> codePaths) throws IOException {
+        private static Handle create(List<String> codePaths, boolean multiArch) throws IOException {
             final int size = codePaths.size();
             final long[] apkHandles = new long[size];
             for (int i = 0; i < size; i++) {
@@ -89,11 +108,12 @@
                 }
             }
 
-            return new Handle(apkHandles);
+            return new Handle(apkHandles, multiArch);
         }
 
-        Handle(long[] apkHandles) {
+        Handle(long[] apkHandles, boolean multiArch) {
             this.apkHandles = apkHandles;
+            this.multiArch = multiArch;
             mGuard.open("close");
         }
 
@@ -126,27 +146,17 @@
 
     private static native long nativeSumNativeBinaries(long handle, String cpuAbi);
 
-    /**
-     * Sums the size of native binaries in an APK for a given ABI.
-     *
-     * @return size of all native binary files in bytes
-     */
-    public static long sumNativeBinariesLI(Handle handle, String[] abis) {
+    private native static int nativeCopyNativeBinaries(long handle,
+            String sharedLibraryPath, String abiToCopy);
+
+    private static long sumNativeBinaries(Handle handle, String abi) {
         long sum = 0;
         for (long apkHandle : handle.apkHandles) {
-            // NOTE: For a given APK handle, we parse the central directory precisely
-            // once, but prefix matching of entries requires a CD traversal, which can
-            // take a while (even if it needs no additional I/O).
-            for (String abi : abis) {
-                sum += nativeSumNativeBinaries(apkHandle, abi);
-            }
+            sum += nativeSumNativeBinaries(apkHandle, abi);
         }
         return sum;
     }
 
-    private native static int nativeCopyNativeBinaries(long handle,
-            String sharedLibraryPath, String abiToCopy);
-
     /**
      * Copies native binaries to a shared library directory.
      *
@@ -155,8 +165,7 @@
      * @return {@link PackageManager#INSTALL_SUCCEEDED} if successful or another
      *         error code from that class if not
      */
-    public static int copyNativeBinariesIfNeededLI(Handle handle, File sharedLibraryDir,
-            String abi) {
+    public static int copyNativeBinaries(Handle handle, File sharedLibraryDir, String abi) {
         for (long apkHandle : handle.apkHandles) {
             int res = nativeCopyNativeBinaries(apkHandle, sharedLibraryDir.getPath(), abi);
             if (res != INSTALL_SUCCEEDED) {
@@ -244,9 +253,171 @@
         }
     }
 
+    private static void createNativeLibrarySubdir(File path) throws IOException {
+        if (!path.isDirectory()) {
+            path.delete();
+
+            if (!path.mkdir()) {
+                throw new IOException("Cannot create " + path.getPath());
+            }
+
+            try {
+                Os.chmod(path.getPath(), S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH);
+            } catch (ErrnoException e) {
+                throw new IOException("Cannot chmod native library directory "
+                        + path.getPath(), e);
+            }
+        } else if (!SELinux.restorecon(path)) {
+            throw new IOException("Cannot set SELinux context for " + path.getPath());
+        }
+    }
+
+    private static long sumNativeBinariesForSupportedAbi(Handle handle, String[] abiList) {
+        int abi = findSupportedAbi(handle, abiList);
+        if (abi >= 0) {
+            return sumNativeBinaries(handle, abiList[abi]);
+        } else {
+            return 0;
+        }
+    }
+
+    public static int copyNativeBinariesForSupportedAbi(Handle handle, File libraryRoot,
+            String[] abiList, boolean useIsaSubdir) throws IOException {
+        createNativeLibrarySubdir(libraryRoot);
+
+        /*
+         * If this is an internal application or our nativeLibraryPath points to
+         * the app-lib directory, unpack the libraries if necessary.
+         */
+        int abi = findSupportedAbi(handle, abiList);
+        if (abi >= 0) {
+            /*
+             * If we have a matching instruction set, construct a subdir under the native
+             * library root that corresponds to this instruction set.
+             */
+            final String instructionSet = VMRuntime.getInstructionSet(abiList[abi]);
+            final File subDir;
+            if (useIsaSubdir) {
+                final File isaSubdir = new File(libraryRoot, instructionSet);
+                createNativeLibrarySubdir(isaSubdir);
+                subDir = isaSubdir;
+            } else {
+                subDir = libraryRoot;
+            }
+
+            int copyRet = copyNativeBinaries(handle, subDir, abiList[abi]);
+            if (copyRet != PackageManager.INSTALL_SUCCEEDED) {
+                return copyRet;
+            }
+        }
+
+        return abi;
+    }
+
+    public static int copyNativeBinariesWithOverride(Handle handle, File libraryRoot,
+            String abiOverride) {
+        try {
+            if (handle.multiArch) {
+                // Warn if we've set an abiOverride for multi-lib packages..
+                // By definition, we need to copy both 32 and 64 bit libraries for
+                // such packages.
+                if (abiOverride != null && !CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
+                    Slog.w(TAG, "Ignoring abiOverride for multi arch application.");
+                }
+
+                int copyRet = PackageManager.NO_NATIVE_LIBRARIES;
+                if (Build.SUPPORTED_32_BIT_ABIS.length > 0) {
+                    copyRet = copyNativeBinariesForSupportedAbi(handle, libraryRoot,
+                            Build.SUPPORTED_32_BIT_ABIS, true /* use isa specific subdirs */);
+                    if (copyRet < 0 && copyRet != PackageManager.NO_NATIVE_LIBRARIES &&
+                            copyRet != PackageManager.INSTALL_FAILED_NO_MATCHING_ABIS) {
+                        Slog.w(TAG, "Failure copying 32 bit native libraries; copyRet=" +copyRet);
+                        return copyRet;
+                    }
+                }
+
+                if (Build.SUPPORTED_64_BIT_ABIS.length > 0) {
+                    copyRet = copyNativeBinariesForSupportedAbi(handle, libraryRoot,
+                            Build.SUPPORTED_64_BIT_ABIS, true /* use isa specific subdirs */);
+                    if (copyRet < 0 && copyRet != PackageManager.NO_NATIVE_LIBRARIES &&
+                            copyRet != PackageManager.INSTALL_FAILED_NO_MATCHING_ABIS) {
+                        Slog.w(TAG, "Failure copying 64 bit native libraries; copyRet=" +copyRet);
+                        return copyRet;
+                    }
+                }
+            } else {
+                String cpuAbiOverride = null;
+                if (CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
+                    cpuAbiOverride = null;
+                } else if (abiOverride != null) {
+                    cpuAbiOverride = abiOverride;
+                }
+
+                String[] abiList = (cpuAbiOverride != null) ?
+                        new String[] { cpuAbiOverride } : Build.SUPPORTED_ABIS;
+                if (Build.SUPPORTED_64_BIT_ABIS.length > 0 && cpuAbiOverride == null &&
+                        hasRenderscriptBitcode(handle)) {
+                    abiList = Build.SUPPORTED_32_BIT_ABIS;
+                }
+
+                int copyRet = copyNativeBinariesForSupportedAbi(handle, libraryRoot, abiList,
+                        true /* use isa specific subdirs */);
+                if (copyRet < 0 && copyRet != PackageManager.NO_NATIVE_LIBRARIES) {
+                    Slog.w(TAG, "Failure copying native libraries [errorCode=" + copyRet + "]");
+                    return copyRet;
+                }
+            }
+
+            return PackageManager.INSTALL_SUCCEEDED;
+        } catch (IOException e) {
+            Slog.e(TAG, "Copying native libraries failed", e);
+            return PackageManager.INSTALL_FAILED_INTERNAL_ERROR;
+        }
+    }
+
+    public static long sumNativeBinariesWithOverride(Handle handle, String abiOverride)
+            throws IOException {
+        long sum = 0;
+        if (handle.multiArch) {
+            // Warn if we've set an abiOverride for multi-lib packages..
+            // By definition, we need to copy both 32 and 64 bit libraries for
+            // such packages.
+            if (abiOverride != null && !CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
+                Slog.w(TAG, "Ignoring abiOverride for multi arch application.");
+            }
+
+            if (Build.SUPPORTED_32_BIT_ABIS.length > 0) {
+                sum += sumNativeBinariesForSupportedAbi(handle, Build.SUPPORTED_32_BIT_ABIS);
+            }
+
+            if (Build.SUPPORTED_64_BIT_ABIS.length > 0) {
+                sum += sumNativeBinariesForSupportedAbi(handle, Build.SUPPORTED_64_BIT_ABIS);
+            }
+        } else {
+            String cpuAbiOverride = null;
+            if (CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
+                cpuAbiOverride = null;
+            } else if (abiOverride != null) {
+                cpuAbiOverride = abiOverride;
+            }
+
+            String[] abiList = (cpuAbiOverride != null) ?
+                    new String[] { cpuAbiOverride } : Build.SUPPORTED_ABIS;
+            if (Build.SUPPORTED_64_BIT_ABIS.length > 0 && cpuAbiOverride == null &&
+                    hasRenderscriptBitcode(handle)) {
+                abiList = Build.SUPPORTED_32_BIT_ABIS;
+            }
+
+            sum += sumNativeBinariesForSupportedAbi(handle, abiList);
+        }
+        return sum;
+    }
+
     // We don't care about the other return values for now.
     private static final int BITCODE_PRESENT = 1;
 
+    private static native int hasRenderscriptBitcode(long apkHandle);
+
     public static boolean hasRenderscriptBitcode(Handle handle) throws IOException {
         for (long apkHandle : handle.apkHandles) {
             final int res = hasRenderscriptBitcode(apkHandle);
@@ -258,6 +429,4 @@
         }
         return false;
     }
-
-    private static native int hasRenderscriptBitcode(long apkHandle);
 }
diff --git a/core/java/com/android/internal/content/PackageHelper.java b/core/java/com/android/internal/content/PackageHelper.java
index eff6684..7bdb4be 100644
--- a/core/java/com/android/internal/content/PackageHelper.java
+++ b/core/java/com/android/internal/content/PackageHelper.java
@@ -16,14 +16,28 @@
 
 package com.android.internal.content;
 
+import static android.net.TrafficStats.MB_IN_BYTES;
+
+import android.content.Context;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.PackageInfo;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
+import android.content.pm.PackageParser.PackageLite;
+import android.os.Environment;
+import android.os.Environment.UserEnvironment;
 import android.os.FileUtils;
 import android.os.IBinder;
 import android.os.RemoteException;
 import android.os.ServiceManager;
+import android.os.UserHandle;
 import android.os.storage.IMountService;
+import android.os.storage.StorageManager;
 import android.os.storage.StorageResultCode;
 import android.util.Log;
 
+import libcore.io.IoUtils;
+
 import java.io.File;
 import java.io.FileOutputStream;
 import java.io.IOException;
@@ -33,8 +47,6 @@
 import java.util.zip.ZipFile;
 import java.util.zip.ZipOutputStream;
 
-import libcore.io.IoUtils;
-
 /**
  * Constants used internally between the PackageManager
  * and media container service transports.
@@ -68,9 +80,10 @@
         }
     }
 
-    public static String createSdDir(int sizeMb, String cid, String sdEncKey, int uid,
+    public static String createSdDir(long sizeBytes, String cid, String sdEncKey, int uid,
             boolean isExternal) {
-        // Create mount point via MountService
+        // Round up to nearest MB, plus another MB for filesystem overhead
+        final int sizeMb = (int) ((sizeBytes + MB_IN_BYTES) / MB_IN_BYTES) + 1;
         try {
             IMountService mountService = getMountService();
 
@@ -93,19 +106,39 @@
         return null;
     }
 
-   public static String mountSdDir(String cid, String key, int ownerUid) {
-    try {
-        int rc = getMountService().mountSecureContainer(cid, key, ownerUid);
-        if (rc != StorageResultCode.OperationSucceeded) {
-            Log.i(TAG, "Failed to mount container " + cid + " rc : " + rc);
-            return null;
+    public static boolean resizeSdDir(long sizeBytes, String cid, String sdEncKey) {
+        // Round up to nearest MB, plus another MB for filesystem overhead
+        final int sizeMb = (int) ((sizeBytes + MB_IN_BYTES) / MB_IN_BYTES) + 1;
+        try {
+            IMountService mountService = getMountService();
+            int rc = mountService.resizeSecureContainer(cid, sizeMb, sdEncKey);
+            if (rc == StorageResultCode.OperationSucceeded) {
+                return true;
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "MountService running?");
         }
-        return getMountService().getSecureContainerPath(cid);
-    } catch (RemoteException e) {
-        Log.e(TAG, "MountService running?");
+        Log.e(TAG, "Failed to create secure container " + cid);
+        return false;
     }
-    return null;
-   }
+
+    public static String mountSdDir(String cid, String key, int ownerUid) {
+        return mountSdDir(cid, key, ownerUid, true);
+    }
+
+    public static String mountSdDir(String cid, String key, int ownerUid, boolean readOnly) {
+        try {
+            int rc = getMountService().mountSecureContainer(cid, key, ownerUid, readOnly);
+            if (rc != StorageResultCode.OperationSucceeded) {
+                Log.i(TAG, "Failed to mount container " + cid + " rc : " + rc);
+                return null;
+            }
+            return getMountService().getSecureContainerPath(cid);
+        } catch (RemoteException e) {
+            Log.e(TAG, "MountService running?");
+        }
+        return null;
+    }
 
    public static boolean unMountSdDir(String cid) {
     try {
@@ -210,7 +243,7 @@
     /**
      * Extract public files for the single given APK.
      */
-    public static int extractPublicFiles(String apkPath, File publicZipFile)
+    public static long extractPublicFiles(File apkFile, File publicZipFile)
             throws IOException {
         final FileOutputStream fstr;
         final ZipOutputStream publicZipOutStream;
@@ -221,12 +254,13 @@
         } else {
             fstr = new FileOutputStream(publicZipFile);
             publicZipOutStream = new ZipOutputStream(fstr);
+            Log.d(TAG, "Extracting " + apkFile + " to " + publicZipFile);
         }
 
-        int size = 0;
+        long size = 0L;
 
         try {
-            final ZipFile privateZip = new ZipFile(apkPath);
+            final ZipFile privateZip = new ZipFile(apkFile.getAbsolutePath());
             try {
                 // Copy manifest, resources.arsc and res directory to public zip
                 for (final ZipEntry zipEntry : Collections.list(privateZip.entries())) {
@@ -298,4 +332,137 @@
         }
         return false;
     }
+
+    /**
+     * Given a requested {@link PackageInfo#installLocation} and calculated
+     * install size, pick the actual location to install the app.
+     */
+    public static int resolveInstallLocation(Context context, String packageName,
+            int installLocation, long sizeBytes, int installFlags) {
+        ApplicationInfo existingInfo = null;
+        try {
+            existingInfo = context.getPackageManager().getApplicationInfo(packageName,
+                    PackageManager.GET_UNINSTALLED_PACKAGES);
+        } catch (NameNotFoundException ignored) {
+        }
+
+        final int prefer;
+        final boolean checkBoth;
+        if ((installFlags & PackageManager.INSTALL_INTERNAL) != 0) {
+            prefer = RECOMMEND_INSTALL_INTERNAL;
+            checkBoth = false;
+        } else if ((installFlags & PackageManager.INSTALL_EXTERNAL) != 0) {
+            prefer = RECOMMEND_INSTALL_EXTERNAL;
+            checkBoth = false;
+        } else if (installLocation == PackageInfo.INSTALL_LOCATION_INTERNAL_ONLY) {
+            prefer = RECOMMEND_INSTALL_INTERNAL;
+            checkBoth = false;
+        } else if (installLocation == PackageInfo.INSTALL_LOCATION_PREFER_EXTERNAL) {
+            prefer = RECOMMEND_INSTALL_EXTERNAL;
+            checkBoth = true;
+        } else if (installLocation == PackageInfo.INSTALL_LOCATION_AUTO) {
+            // When app is already installed, prefer same medium
+            if (existingInfo != null) {
+                if ((existingInfo.flags & ApplicationInfo.FLAG_EXTERNAL_STORAGE) != 0) {
+                    prefer = RECOMMEND_INSTALL_EXTERNAL;
+                } else {
+                    prefer = RECOMMEND_INSTALL_INTERNAL;
+                }
+            } else {
+                prefer = RECOMMEND_INSTALL_INTERNAL;
+            }
+            checkBoth = true;
+        } else {
+            prefer = RECOMMEND_INSTALL_INTERNAL;
+            checkBoth = false;
+        }
+
+        final boolean emulated = Environment.isExternalStorageEmulated();
+        final StorageManager storage = StorageManager.from(context);
+
+        boolean fitsOnInternal = false;
+        if (checkBoth || prefer == RECOMMEND_INSTALL_INTERNAL) {
+            final File target = Environment.getDataDirectory();
+            fitsOnInternal = (sizeBytes <= storage.getStorageBytesUntilLow(target));
+        }
+
+        boolean fitsOnExternal = false;
+        if (!emulated && (checkBoth || prefer == RECOMMEND_INSTALL_EXTERNAL)) {
+            final File target = new UserEnvironment(UserHandle.USER_OWNER)
+                    .getExternalStorageDirectory();
+            // External is only an option when size is known
+            if (sizeBytes > 0) {
+                fitsOnExternal = (sizeBytes <= storage.getStorageBytesUntilLow(target));
+            }
+        }
+
+        if (prefer == RECOMMEND_INSTALL_INTERNAL) {
+            if (fitsOnInternal) {
+                return PackageHelper.RECOMMEND_INSTALL_INTERNAL;
+            }
+        } else if (!emulated && prefer == RECOMMEND_INSTALL_EXTERNAL) {
+            if (fitsOnExternal) {
+                return PackageHelper.RECOMMEND_INSTALL_EXTERNAL;
+            }
+        }
+
+        if (checkBoth) {
+            if (fitsOnInternal) {
+                return PackageHelper.RECOMMEND_INSTALL_INTERNAL;
+            } else if (!emulated && fitsOnExternal) {
+                return PackageHelper.RECOMMEND_INSTALL_EXTERNAL;
+            }
+        }
+
+        /*
+         * If they requested to be on the external media by default, return that
+         * the media was unavailable. Otherwise, indicate there was insufficient
+         * storage space available.
+         */
+        if (!emulated && (checkBoth || prefer == RECOMMEND_INSTALL_EXTERNAL)
+                && !Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState())) {
+            return PackageHelper.RECOMMEND_MEDIA_UNAVAILABLE;
+        } else {
+            return PackageHelper.RECOMMEND_FAILED_INSUFFICIENT_STORAGE;
+        }
+    }
+
+    public static long calculateInstalledSize(PackageLite pkg, boolean isForwardLocked,
+            String abiOverride) throws IOException {
+        NativeLibraryHelper.Handle handle = null;
+        try {
+            handle = NativeLibraryHelper.Handle.create(pkg);
+            return calculateInstalledSize(pkg, handle, isForwardLocked, abiOverride);
+        } finally {
+            IoUtils.closeQuietly(handle);
+        }
+    }
+
+    public static long calculateInstalledSize(PackageLite pkg, NativeLibraryHelper.Handle handle,
+            boolean isForwardLocked, String abiOverride) throws IOException {
+        long sizeBytes = 0;
+
+        // Include raw APKs, and possibly unpacked resources
+        for (String codePath : pkg.getAllCodePaths()) {
+            final File codeFile = new File(codePath);
+            sizeBytes += codeFile.length();
+
+            if (isForwardLocked) {
+                sizeBytes += PackageHelper.extractPublicFiles(codeFile, null);
+            }
+        }
+
+        // Include all relevant native code
+        sizeBytes += NativeLibraryHelper.sumNativeBinariesWithOverride(handle, abiOverride);
+
+        return sizeBytes;
+    }
+
+    public static String replaceEnd(String str, String before, String after) {
+        if (!str.endsWith(before)) {
+            throw new IllegalArgumentException(
+                    "Expected " + str + " to end with " + before);
+        }
+        return str.substring(0, str.length() - before.length()) + after;
+    }
 }
diff --git a/core/java/com/android/internal/inputmethod/InputMethodUtils.java b/core/java/com/android/internal/inputmethod/InputMethodUtils.java
index d801571..8f8ce95 100644
--- a/core/java/com/android/internal/inputmethod/InputMethodUtils.java
+++ b/core/java/com/android/internal/inputmethod/InputMethodUtils.java
@@ -44,6 +44,7 @@
 public class InputMethodUtils {
     public static final boolean DEBUG = false;
     public static final int NOT_A_SUBTYPE_ID = -1;
+    public static final String SUBTYPE_MODE_ANY = null;
     public static final String SUBTYPE_MODE_KEYBOARD = "keyboard";
     public static final String SUBTYPE_MODE_VOICE = "voice";
     private static final String TAG = "InputMethodUtils";
@@ -52,6 +53,17 @@
     private static final String TAG_ENABLED_WHEN_DEFAULT_IS_NOT_ASCII_CAPABLE =
             "EnabledWhenDefaultIsNotAsciiCapable";
     private static final String TAG_ASCII_CAPABLE = "AsciiCapable";
+    /**
+     * Used in {@link #getFallbackLocaleForDefaultIme(ArrayList, Context)} to find the fallback IMEs
+     * that are mainly used until the system becomes ready. Note that {@link Locale} in this array
+     * is checked with {@link Locale#equals(Object)}, which means that {@code Locale.ENGLISH}
+     * doesn't automatically match {@code Locale("en", "IN")}.
+     */
+    private static final Locale[] SEARCH_ORDER_OF_FALLBACK_LOCALES = {
+        Locale.ENGLISH, // "en"
+        Locale.US, // "en_US"
+        Locale.UK, // "en_GB"
+    };
 
     private InputMethodUtils() {
         // This utility class is not publicly instantiable.
@@ -101,6 +113,11 @@
                 & ApplicationInfo.FLAG_SYSTEM) != 0;
     }
 
+    /**
+     * @deprecated Use {@link Locale} returned from
+     * {@link #getFallbackLocaleForDefaultIme(ArrayList)} instead.
+     */
+    @Deprecated
     public static boolean isSystemImeThatHasEnglishKeyboardSubtype(InputMethodInfo imi) {
         if (!isSystemIme(imi)) {
             return false;
@@ -108,7 +125,22 @@
         return containsSubtypeOf(imi, ENGLISH_LOCALE.getLanguage(), SUBTYPE_MODE_KEYBOARD);
     }
 
-    private static boolean isSystemAuxilialyImeThatHashAutomaticSubtype(InputMethodInfo imi) {
+    public static Locale getFallbackLocaleForDefaultIme(final ArrayList<InputMethodInfo> imis,
+            final Context context) {
+        for (final Locale fallbackLocale : SEARCH_ORDER_OF_FALLBACK_LOCALES) {
+            for (int i = 0; i < imis.size(); ++i) {
+                final InputMethodInfo imi = imis.get(i);
+                if (isSystemIme(imi) && imi.isDefault(context) &&
+                        containsSubtypeOf(imi, fallbackLocale, false /* ignoreCountry */,
+                                SUBTYPE_MODE_KEYBOARD)) {
+                    return fallbackLocale;
+                }
+            }
+        }
+        return null;
+    }
+
+    private static boolean isSystemAuxilialyImeThatHasAutomaticSubtype(InputMethodInfo imi) {
         if (!isSystemIme(imi)) {
             return false;
         }
@@ -125,32 +157,108 @@
         return false;
     }
 
+    public static Locale getSystemLocaleFromContext(final Context context) {
+        try {
+            return context.getResources().getConfiguration().locale;
+        } catch (Resources.NotFoundException ex) {
+            return null;
+        }
+    }
+
     public static ArrayList<InputMethodInfo> getDefaultEnabledImes(
             Context context, boolean isSystemReady, ArrayList<InputMethodInfo> imis) {
-        final ArrayList<InputMethodInfo> retval = new ArrayList<InputMethodInfo>();
-        boolean auxilialyImeAdded = false;
+        // OK to store null in fallbackLocale because isImeThatHasSubtypeOf() is null-tolerant.
+        final Locale fallbackLocale = getFallbackLocaleForDefaultIme(imis, context);
+
+        if (!isSystemReady) {
+            final ArrayList<InputMethodInfo> retval = new ArrayList<>();
+            for (int i = 0; i < imis.size(); ++i) {
+                final InputMethodInfo imi = imis.get(i);
+                // TODO: We should check isAsciiCapable instead of relying on fallbackLocale.
+                if (isSystemIme(imi) && imi.isDefault(context) &&
+                        isImeThatHasSubtypeOf(imi, fallbackLocale, false /* ignoreCountry */,
+                                SUBTYPE_MODE_KEYBOARD)) {
+                    retval.add(imi);
+                }
+            }
+            return retval;
+        }
+
+        // OK to store null in fallbackLocale because isImeThatHasSubtypeOf() is null-tolerant.
+        final Locale systemLocale = getSystemLocaleFromContext(context);
+        // TODO: Use LinkedHashSet to simplify the code.
+        final ArrayList<InputMethodInfo> retval = new ArrayList<>();
+        boolean systemLocaleKeyboardImeFound = false;
+
+        // First, try to find IMEs with taking the system locale country into consideration.
         for (int i = 0; i < imis.size(); ++i) {
             final InputMethodInfo imi = imis.get(i);
-            if (isDefaultEnabledIme(isSystemReady, imi, context)) {
+            if (!isSystemIme(imi) || !imi.isDefault(context)) {
+                continue;
+            }
+            final boolean isSystemLocaleKeyboardIme = isImeThatHasSubtypeOf(imi, systemLocale,
+                    false /* ignoreCountry */, SUBTYPE_MODE_KEYBOARD);
+            // TODO: We should check isAsciiCapable instead of relying on fallbackLocale.
+            // TODO: Use LinkedHashSet to simplify the code.
+            if (isSystemLocaleKeyboardIme ||
+                    isImeThatHasSubtypeOf(imi, fallbackLocale, false /* ignoreCountry */,
+                            SUBTYPE_MODE_ANY)) {
                 retval.add(imi);
-                if (imi.isAuxiliaryIme()) {
-                    auxilialyImeAdded = true;
+            }
+            systemLocaleKeyboardImeFound |= isSystemLocaleKeyboardIme;
+        }
+
+        // System locale country doesn't match any IMEs, try to find IMEs in a country-agnostic
+        // way.
+        if (!systemLocaleKeyboardImeFound) {
+            for (int i = 0; i < imis.size(); ++i) {
+                final InputMethodInfo imi = imis.get(i);
+                if (!isSystemIme(imi) || !imi.isDefault(context)) {
+                    continue;
+                }
+                if (isImeThatHasSubtypeOf(imi, fallbackLocale, false /* ignoreCountry */,
+                        SUBTYPE_MODE_KEYBOARD)) {
+                    // IMEs that have fallback locale are already added in the previous loop. We
+                    // don't need to add them again here.
+                    // TODO: Use LinkedHashSet to simplify the code.
+                    continue;
+                }
+                if (isImeThatHasSubtypeOf(imi, systemLocale, true /* ignoreCountry */,
+                        SUBTYPE_MODE_ANY)) {
+                    retval.add(imi);
                 }
             }
         }
-        if (auxilialyImeAdded) {
-            return retval;
+
+        // If one or more auxiliary input methods are available, OK to stop populating the list.
+        for (int i = 0; i < retval.size(); ++i) {
+            if (retval.get(i).isAuxiliaryIme()) {
+                return retval;
+            }
         }
         for (int i = 0; i < imis.size(); ++i) {
             final InputMethodInfo imi = imis.get(i);
-            if (isSystemAuxilialyImeThatHashAutomaticSubtype(imi)) {
+            if (isSystemAuxilialyImeThatHasAutomaticSubtype(imi)) {
                 retval.add(imi);
             }
         }
         return retval;
     }
 
-    // TODO: Rename isSystemDefaultImeThatHasCurrentLanguageSubtype
+    public static boolean isImeThatHasSubtypeOf(final InputMethodInfo imi,
+            final Locale locale, final boolean ignoreCountry, final String mode) {
+        if (locale == null) {
+            return false;
+        }
+        return containsSubtypeOf(imi, locale, ignoreCountry, mode);
+    }
+
+    /**
+     * @deprecated Use {@link #isSystemIme(InputMethodInfo)} and
+     * {@link InputMethodInfo#isDefault(Context)} and
+     * {@link #isImeThatHasSubtypeOf(InputMethodInfo, Locale, boolean, String))} instead.
+     */
+    @Deprecated
     public static boolean isValidSystemDefaultIme(
             boolean isSystemReady, InputMethodInfo imi, Context context) {
         if (!isSystemReady) {
@@ -163,7 +271,7 @@
             try {
                 if (imi.isDefault(context) && containsSubtypeOf(
                         imi, context.getResources().getConfiguration().locale.getLanguage(),
-                        null /* mode */)) {
+                        SUBTYPE_MODE_ANY)) {
                     return true;
                 }
             } catch (Resources.NotFoundException ex) {
@@ -175,22 +283,47 @@
         return false;
     }
 
-    public static boolean isDefaultEnabledIme(
-            boolean isSystemReady, InputMethodInfo imi, Context context) {
-        return isValidSystemDefaultIme(isSystemReady, imi, context)
-                || isSystemImeThatHasEnglishKeyboardSubtype(imi);
+    public static boolean containsSubtypeOf(final InputMethodInfo imi,
+            final Locale locale, final boolean ignoreCountry, final String mode) {
+        final int N = imi.getSubtypeCount();
+        for (int i = 0; i < N; ++i) {
+            final InputMethodSubtype subtype = imi.getSubtypeAt(i);
+            if (ignoreCountry) {
+                final Locale subtypeLocale = new Locale(getLanguageFromLocaleString(
+                        subtype.getLocale()));
+                if (!subtypeLocale.getLanguage().equals(locale.getLanguage())) {
+                    continue;
+                }
+            } else {
+                // TODO: Use {@link Locale#toLanguageTag()} and
+                // {@link Locale#forLanguageTag(languageTag)} instead.
+                if (!TextUtils.equals(subtype.getLocale(), locale.toString())) {
+                    continue;
+                }
+            }
+            if (mode == SUBTYPE_MODE_ANY || TextUtils.isEmpty(mode) ||
+                    mode.equalsIgnoreCase(subtype.getMode())) {
+                return true;
+            }
+        }
+        return false;
     }
 
+    /**
+     * @deprecated Use {@link #containsSubtypeOf(InputMethodInfo, Locale, boolean, String)} instead.
+     */
+    @Deprecated
     public static boolean containsSubtypeOf(InputMethodInfo imi, String language, String mode) {
         final int N = imi.getSubtypeCount();
         for (int i = 0; i < N; ++i) {
-            if (!imi.getSubtypeAt(i).getLocale().startsWith(language)) {
+            final InputMethodSubtype subtype = imi.getSubtypeAt(i);
+            if (!subtype.getLocale().startsWith(language)) {
                 continue;
             }
-            if(!TextUtils.isEmpty(mode) && !imi.getSubtypeAt(i).getMode().equalsIgnoreCase(mode)) {
-                continue;
+            if (mode == SUBTYPE_MODE_ANY || TextUtils.isEmpty(mode) ||
+                    mode.equalsIgnoreCase(subtype.getMode())) {
+                return true;
             }
-            return true;
         }
         return false;
     }
@@ -217,27 +350,26 @@
         return subtypes;
     }
 
-    public static InputMethodInfo getMostApplicableDefaultIME(
-            List<InputMethodInfo> enabledImes) {
-        if (enabledImes != null && enabledImes.size() > 0) {
-            // We'd prefer to fall back on a system IME, since that is safer.
-            int i = enabledImes.size();
-            int firstFoundSystemIme = -1;
-            while (i > 0) {
-                i--;
-                final InputMethodInfo imi = enabledImes.get(i);
-                if (InputMethodUtils.isSystemImeThatHasEnglishKeyboardSubtype(imi)
-                        && !imi.isAuxiliaryIme()) {
-                    return imi;
-                }
-                if (firstFoundSystemIme < 0 && InputMethodUtils.isSystemIme(imi)
-                        && !imi.isAuxiliaryIme()) {
-                    firstFoundSystemIme = i;
-                }
-            }
-            return enabledImes.get(Math.max(firstFoundSystemIme, 0));
+    public static InputMethodInfo getMostApplicableDefaultIME(List<InputMethodInfo> enabledImes) {
+        if (enabledImes == null || enabledImes.isEmpty()) {
+            return null;
         }
-        return null;
+        // We'd prefer to fall back on a system IME, since that is safer.
+        int i = enabledImes.size();
+        int firstFoundSystemIme = -1;
+        while (i > 0) {
+            i--;
+            final InputMethodInfo imi = enabledImes.get(i);
+            if (InputMethodUtils.isSystemImeThatHasEnglishKeyboardSubtype(imi)
+                    && !imi.isAuxiliaryIme()) {
+                return imi;
+            }
+            if (firstFoundSystemIme < 0 && InputMethodUtils.isSystemIme(imi)
+                    && !imi.isAuxiliaryIme()) {
+                firstFoundSystemIme = i;
+            }
+        }
+        return enabledImes.get(Math.max(firstFoundSystemIme, 0));
     }
 
     public static boolean isValidSubtypeId(InputMethodInfo imi, int subtypeHashCode) {
@@ -344,6 +476,7 @@
 
     /**
      * Returns the language component of a given locale string.
+     * TODO: Use {@link Locale#toLanguageTag()} and {@link Locale#forLanguageTag(languageTag)}
      */
     public static String getLanguageFromLocaleString(String locale) {
         final int idx = locale.indexOf('_');
@@ -974,6 +1107,16 @@
             }
         }
 
+        public boolean isShowImeWithHardKeyboardEnabled() {
+                return Settings.Secure.getIntForUser(mResolver,
+                        Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD, 0, mCurrentUserId) == 1;
+        }
+
+        public void setShowImeWithHardKeyboard(boolean show) {
+            Settings.Secure.putIntForUser(mResolver, Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD,
+                    show ? 1 : 0, mCurrentUserId);
+        }
+
         public int getCurrentUserId() {
             return mCurrentUserId;
         }
diff --git a/core/java/com/android/internal/net/VpnConfig.java b/core/java/com/android/internal/net/VpnConfig.java
index 0099269..3d016be 100644
--- a/core/java/com/android/internal/net/VpnConfig.java
+++ b/core/java/com/android/internal/net/VpnConfig.java
@@ -20,17 +20,20 @@
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
+import android.content.pm.ResolveInfo;
 import android.content.res.Resources;
+import android.net.LinkAddress;
+import android.net.RouteInfo;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.os.UserHandle;
-import android.net.RouteInfo;
-import android.net.LinkAddress;
 
 import java.net.Inet4Address;
 import java.net.InetAddress;
-import java.util.List;
 import java.util.ArrayList;
+import java.util.List;
 
 /**
  * A simple container used to carry information in VpnBuilder, VpnDialogs,
@@ -55,6 +58,7 @@
         return intent;
     }
 
+    /** NOTE: This should only be used for legacy VPN. */
     public static PendingIntent getIntentForStatusPanel(Context context) {
         Intent intent = new Intent();
         intent.setClassName(DIALOGS_PACKAGE, DIALOGS_PACKAGE + ".ManageDialog");
@@ -63,6 +67,21 @@
         return PendingIntent.getActivityAsUser(context, 0, intent, 0, null, UserHandle.CURRENT);
     }
 
+    public static CharSequence getVpnLabel(Context context, String packageName)
+            throws NameNotFoundException {
+        PackageManager pm = context.getPackageManager();
+        Intent intent = new Intent(SERVICE_INTERFACE);
+        intent.setPackage(packageName);
+        List<ResolveInfo> services = pm.queryIntentServices(intent, 0 /* flags */);
+        if (services != null && services.size() == 1) {
+            // This app contains exactly one VPN service. Call loadLabel, which will attempt to
+            // load the service's label, and fall back to the app label if none is present.
+            return services.get(0).loadLabel(pm);
+        } else {
+            return pm.getApplicationInfo(packageName, 0).loadLabel(pm);
+        }
+    }
+
     public String user;
     public String interfaze;
     public String session;
@@ -71,6 +90,8 @@
     public List<RouteInfo> routes = new ArrayList<RouteInfo>();
     public List<String> dnsServers;
     public List<String> searchDomains;
+    public List<String> allowedApplications;
+    public List<String> disallowedApplications;
     public PendingIntent configureIntent;
     public long startTime = -1;
     public boolean legacy;
@@ -132,6 +153,8 @@
         out.writeTypedList(routes);
         out.writeStringList(dnsServers);
         out.writeStringList(searchDomains);
+        out.writeStringList(allowedApplications);
+        out.writeStringList(disallowedApplications);
         out.writeParcelable(configureIntent, flags);
         out.writeLong(startTime);
         out.writeInt(legacy ? 1 : 0);
@@ -154,6 +177,8 @@
             in.readTypedList(config.routes, RouteInfo.CREATOR);
             config.dnsServers = in.createStringArrayList();
             config.searchDomains = in.createStringArrayList();
+            config.allowedApplications = in.createStringArrayList();
+            config.disallowedApplications = in.createStringArrayList();
             config.configureIntent = in.readParcelable(null);
             config.startTime = in.readLong();
             config.legacy = in.readInt() != 0;
diff --git a/core/java/com/android/internal/os/BatteryStatsHelper.java b/core/java/com/android/internal/os/BatteryStatsHelper.java
index ee406bd..eae4427 100644
--- a/core/java/com/android/internal/os/BatteryStatsHelper.java
+++ b/core/java/com/android/internal/os/BatteryStatsHelper.java
@@ -993,6 +993,6 @@
         } catch (RemoteException e) {
             Log.w(TAG, "RemoteException:", e);
         }
-        return null;
+        return new BatteryStatsImpl();
     }
 }
diff --git a/core/java/com/android/internal/os/BatteryStatsImpl.java b/core/java/com/android/internal/os/BatteryStatsImpl.java
index 6c9766e..81705be 100644
--- a/core/java/com/android/internal/os/BatteryStatsImpl.java
+++ b/core/java/com/android/internal/os/BatteryStatsImpl.java
@@ -94,7 +94,7 @@
     private static final int MAGIC = 0xBA757475; // 'BATSTATS'
 
     // Current on-disk Parcel version
-    private static final int VERSION = 113 + (USE_OLD_HISTORY ? 1000 : 0);
+    private static final int VERSION = 114 + (USE_OLD_HISTORY ? 1000 : 0);
 
     // Maximum number of items we will record in the history.
     private static final int MAX_HISTORY_ITEMS = 2000;
@@ -105,7 +105,7 @@
     // The maximum number of names wakelocks we will keep track of
     // per uid; once the limit is reached, we batch the remaining wakelocks
     // in to one common name.
-    private static final int MAX_WAKELOCKS_PER_UID = 50;
+    private static final int MAX_WAKELOCKS_PER_UID = 100;
 
     private static int sNumSpeedSteps;
 
@@ -237,6 +237,9 @@
     String mStartPlatformVersion;
     String mEndPlatformVersion;
 
+    long mLastRecordedClockTime;
+    long mLastRecordedClockRealtime;
+
     long mUptime;
     long mUptimeStart;
     long mRealtime;
@@ -385,10 +388,9 @@
 
     String mLastWakeupReason = null;
     long mLastWakeupUptimeMs = 0;
-    private final HashMap<String, LongSamplingCounter> mWakeupReasonStats =
-            new HashMap<String, LongSamplingCounter>();
+    private final HashMap<String, SamplingTimer> mWakeupReasonStats = new HashMap<>();
 
-    public Map<String, ? extends LongCounter> getWakeupReasonStats() {
+    public Map<String, ? extends Timer> getWakeupReasonStats() {
         return mWakeupReasonStats;
     }
 
@@ -1131,6 +1133,10 @@
             mCurrentReportedCount = count;
         }
 
+        public void addCurrentReportedCount(int delta) {
+            updateCurrentReportedCount(mCurrentReportedCount + delta);
+        }
+
         public void updateCurrentReportedTotalTime(long totalTime) {
             if (mTimeBaseRunning && mUnpluggedReportedTotalTime == 0) {
                 // Updating the reported value for the first time.
@@ -1141,6 +1147,10 @@
             mCurrentReportedTotalTime = totalTime;
         }
 
+        public void addCurrentReportedTotalTime(long delta) {
+            updateCurrentReportedTotalTime(mCurrentReportedTotalTime + delta);
+        }
+
         public void onTimeStarted(long elapsedRealtime, long baseUptime, long baseRealtime) {
             super.onTimeStarted(elapsedRealtime, baseUptime, baseRealtime);
             if (mTrackingReportedValues) {
@@ -1688,13 +1698,13 @@
      * Get the wakeup reason counter, and create a new one if one
      * doesn't already exist.
      */
-    public LongSamplingCounter getWakeupReasonCounterLocked(String name) {
-        LongSamplingCounter counter = mWakeupReasonStats.get(name);
-        if (counter == null) {
-            counter = new LongSamplingCounter(mOnBatteryScreenOffTimeBase);
-            mWakeupReasonStats.put(name, counter);
+    public SamplingTimer getWakeupReasonTimerLocked(String name) {
+        SamplingTimer timer = mWakeupReasonStats.get(name);
+        if (timer == null) {
+            timer = new SamplingTimer(mOnBatteryTimeBase, true);
+            mWakeupReasonStats.put(name, timer);
         }
-        return counter;
+        return timer;
     }
 
     private final Map<String, KernelWakelockStats> readKernelWakelockStats() {
@@ -2264,6 +2274,8 @@
         if (dataSize == 0) {
             // The history is currently empty; we need it to start with a time stamp.
             cur.currentTime = System.currentTimeMillis();
+            mLastRecordedClockTime = cur.currentTime;
+            mLastRecordedClockRealtime = elapsedRealtimeMs;
             addHistoryBufferLocked(elapsedRealtimeMs, uptimeMs, HistoryItem.CMD_RESET, cur);
         }
         addHistoryBufferLocked(elapsedRealtimeMs, uptimeMs, HistoryItem.CMD_UPDATE, cur);
@@ -2432,6 +2444,8 @@
         mNumHistoryTagChars = 0;
         mHistoryBufferLastPos = -1;
         mHistoryOverflow = false;
+        mLastRecordedClockTime = 0;
+        mLastRecordedClockRealtime = 0;
     }
 
     public void updateTimeBasesLocked(boolean unplugged, boolean screenOff, long uptime,
@@ -2487,6 +2501,28 @@
         addHistoryEventLocked(elapsedRealtime, uptime, code, name, uid);
     }
 
+    public void noteCurrentTimeChangedLocked() {
+        final long currentTime = System.currentTimeMillis();
+        final long elapsedRealtime = SystemClock.elapsedRealtime();
+        final long uptime = SystemClock.uptimeMillis();
+        if (isStartClockTimeValid()) {
+            // Has the time changed sufficiently that it is really worth recording?
+            if (mLastRecordedClockTime != 0) {
+                long expectedClockTime = mLastRecordedClockTime
+                        + (elapsedRealtime - mLastRecordedClockRealtime);
+                if (currentTime >= (expectedClockTime-500)
+                        && currentTime <= (expectedClockTime+500)) {
+                    // Not sufficiently changed, skip!
+                    return;
+                }
+            }
+        }
+        recordCurrentTimeChangeLocked(currentTime, elapsedRealtime, uptime);
+        if (isStartClockTimeValid()) {
+            mStartClockTime = currentTime;
+        }
+    }
+
     public void noteProcessStartLocked(String name, int uid) {
         uid = mapUid(uid);
         if (isOnBattery()) {
@@ -2743,8 +2779,9 @@
     void aggregateLastWakeupUptimeLocked(long uptimeMs) {
         if (mLastWakeupReason != null) {
             long deltaUptime = uptimeMs - mLastWakeupUptimeMs;
-            LongSamplingCounter timer = getWakeupReasonCounterLocked(mLastWakeupReason);
-            timer.addCountLocked(deltaUptime);
+            SamplingTimer timer = getWakeupReasonTimerLocked(mLastWakeupReason);
+            timer.addCurrentReportedCount(1);
+            timer.addCurrentReportedTotalTime(deltaUptime * 1000); // time is in microseconds
             mLastWakeupReason = null;
         }
     }
@@ -2752,7 +2789,7 @@
     public void noteWakeupReasonLocked(String reason) {
         final long elapsedRealtime = SystemClock.elapsedRealtime();
         final long uptime = SystemClock.uptimeMillis();
-        if (DEBUG_HISTORY) Slog.v(TAG, "Wakeup reason reason \"" + reason +"\": "
+        if (DEBUG_HISTORY) Slog.v(TAG, "Wakeup reason \"" + reason +"\": "
                 + Integer.toHexString(mHistoryCur.states));
         aggregateLastWakeupUptimeLocked(uptime);
         mHistoryCur.wakeReasonTag = mHistoryCur.localWakeReasonTag;
@@ -4060,7 +4097,20 @@
         }
     }
 
+    boolean isStartClockTimeValid() {
+        return mStartClockTime > 365*24*60*60*1000L;
+    }
+
     @Override public long getStartClockTime() {
+        if (!isStartClockTimeValid()) {
+            // If the last clock time we got was very small, then we hadn't had a real
+            // time yet, so try to get it again.
+            mStartClockTime = System.currentTimeMillis();
+            if (isStartClockTimeValid()) {
+                recordCurrentTimeChangeLocked(mStartClockTime, SystemClock.elapsedRealtime(),
+                        SystemClock.uptimeMillis());
+            }
+        }
         return mStartClockTime;
     }
 
@@ -6170,7 +6220,7 @@
         }
 
         public void noteStartJobLocked(String name, long elapsedRealtimeMs) {
-            StopwatchTimer t = mJobStats.stopObject(name);
+            StopwatchTimer t = mJobStats.startObject(name);
             if (t != null) {
                 t.startRunningLocked(elapsedRealtimeMs);
             }
@@ -6613,8 +6663,8 @@
         }
 
         if (mWakeupReasonStats.size() > 0) {
-            for (LongSamplingCounter timer : mWakeupReasonStats.values()) {
-                mOnBatteryScreenOffTimeBase.remove(timer);
+            for (SamplingTimer timer : mWakeupReasonStats.values()) {
+                mOnBatteryTimeBase.remove(timer);
             }
             mWakeupReasonStats.clear();
         }
@@ -6790,6 +6840,8 @@
             boolean reset) {
         mRecordingHistory = true;
         mHistoryCur.currentTime = System.currentTimeMillis();
+        mLastRecordedClockTime = mHistoryCur.currentTime;
+        mLastRecordedClockRealtime = elapsedRealtimeMs;
         addHistoryBufferLocked(elapsedRealtimeMs, uptimeMs,
                 reset ? HistoryItem.CMD_RESET : HistoryItem.CMD_CURRENT_TIME,
                 mHistoryCur);
@@ -6799,6 +6851,18 @@
         }
     }
 
+    private void recordCurrentTimeChangeLocked(final long currentTime, final long elapsedRealtimeMs,
+            final long uptimeMs) {
+        if (mRecordingHistory) {
+            mHistoryCur.currentTime = currentTime;
+            mLastRecordedClockTime = currentTime;
+            mLastRecordedClockRealtime = elapsedRealtimeMs;
+            addHistoryBufferLocked(elapsedRealtimeMs, uptimeMs, HistoryItem.CMD_CURRENT_TIME,
+                    mHistoryCur);
+            mHistoryCur.currentTime = 0;
+        }
+    }
+
     // This should probably be exposed in the API, though it's not critical
     private static final int BATTERY_PLUGGED_NONE = 0;
 
@@ -7815,7 +7879,7 @@
         for (int iwr = 0; iwr < NWR; iwr++) {
             if (in.readInt() != 0) {
                 String reasonName = in.readString();
-                getWakeupReasonCounterLocked(reasonName).readSummaryFromParcelLocked(in);
+                getWakeupReasonTimerLocked(reasonName).readSummaryFromParcelLocked(in);
             }
         }
 
@@ -8004,6 +8068,10 @@
     public void writeSummaryToParcel(Parcel out, boolean inclHistory) {
         pullPendingStateUpdatesLocked();
 
+        // Pull the clock time.  This may update the time and make a new history entry
+        // if we had originally pulled a time before the RTC was set.
+        long startClockTime = getStartClockTime();
+
         final long NOW_SYS = SystemClock.uptimeMillis() * 1000;
         final long NOWREAL_SYS = SystemClock.elapsedRealtime() * 1000;
 
@@ -8014,7 +8082,7 @@
         out.writeInt(mStartCount);
         out.writeLong(computeUptime(NOW_SYS, STATS_SINCE_CHARGED));
         out.writeLong(computeRealtime(NOWREAL_SYS, STATS_SINCE_CHARGED));
-        out.writeLong(mStartClockTime);
+        out.writeLong(startClockTime);
         out.writeString(mStartPlatformVersion);
         out.writeString(mEndPlatformVersion);
         mOnBatteryTimeBase.writeSummaryToParcel(out, NOW_SYS, NOWREAL_SYS);
@@ -8085,12 +8153,12 @@
         }
 
         out.writeInt(mWakeupReasonStats.size());
-        for (Map.Entry<String, LongSamplingCounter> ent : mWakeupReasonStats.entrySet()) {
-            LongSamplingCounter counter = ent.getValue();
-            if (counter != null) {
+        for (Map.Entry<String, SamplingTimer> ent : mWakeupReasonStats.entrySet()) {
+            SamplingTimer timer = ent.getValue();
+            if (timer != null) {
                 out.writeInt(1);
                 out.writeString(ent.getKey());
-                counter.writeSummaryFromParcelLocked(out);
+                timer.writeSummaryFromParcelLocked(out, NOWREAL_SYS);
             } else {
                 out.writeInt(0);
             }
@@ -8401,7 +8469,7 @@
         for (int ikw = 0; ikw < NKW; ikw++) {
             if (in.readInt() != 0) {
                 String wakelockName = in.readString();
-                SamplingTimer kwlt = new SamplingTimer(mOnBatteryTimeBase, in);
+                SamplingTimer kwlt = new SamplingTimer(mOnBatteryScreenOffTimeBase, in);
                 mKernelWakelockStats.put(wakelockName, kwlt);
             }
         }
@@ -8411,9 +8479,8 @@
         for (int iwr = 0; iwr < NWR; iwr++) {
             if (in.readInt() != 0) {
                 String reasonName = in.readString();
-                LongSamplingCounter counter = new LongSamplingCounter(mOnBatteryScreenOffTimeBase,
-                        in);
-                mWakeupReasonStats.put(reasonName, counter);
+                SamplingTimer timer = new SamplingTimer(mOnBatteryTimeBase, in);
+                mWakeupReasonStats.put(reasonName, timer);
             }
         }
 
@@ -8453,6 +8520,10 @@
         // Need to update with current kernel wake lock counts.
         pullPendingStateUpdatesLocked();
 
+        // Pull the clock time.  This may update the time and make a new history entry
+        // if we had originally pulled a time before the RTC was set.
+        long startClockTime = getStartClockTime();
+
         final long uSecUptime = SystemClock.uptimeMillis() * 1000;
         final long uSecRealtime = SystemClock.elapsedRealtime() * 1000;
         final long batteryRealtime = mOnBatteryTimeBase.getRealtime(uSecRealtime);
@@ -8463,7 +8534,7 @@
         writeHistory(out, true, false);
 
         out.writeInt(mStartCount);
-        out.writeLong(mStartClockTime);
+        out.writeLong(startClockTime);
         out.writeString(mStartPlatformVersion);
         out.writeString(mEndPlatformVersion);
         out.writeLong(mUptime);
@@ -8544,12 +8615,12 @@
                 }
             }
             out.writeInt(mWakeupReasonStats.size());
-            for (Map.Entry<String, LongSamplingCounter> ent : mWakeupReasonStats.entrySet()) {
-                LongSamplingCounter counter = ent.getValue();
-                if (counter != null) {
+            for (Map.Entry<String, SamplingTimer> ent : mWakeupReasonStats.entrySet()) {
+                SamplingTimer timer = ent.getValue();
+                if (timer != null) {
                     out.writeInt(1);
                     out.writeString(ent.getKey());
-                    counter.writeToParcel(out);
+                    timer.writeToParcel(out, uSecRealtime);
                 } else {
                     out.writeInt(0);
                 }
@@ -8588,6 +8659,10 @@
     public void prepareForDumpLocked() {
         // Need to retrieve current kernel wake lock stats before printing.
         pullPendingStateUpdatesLocked();
+
+        // Pull the clock time.  This may update the time and make a new history entry
+        // if we had originally pulled a time before the RTC was set.
+        getStartClockTime();
     }
 
     public void dumpLocked(Context context, PrintWriter pw, int flags, int reqUid, long histStart) {
diff --git a/core/java/com/android/internal/os/BinderInternal.java b/core/java/com/android/internal/os/BinderInternal.java
index 3b0f0f4..240d9df 100644
--- a/core/java/com/android/internal/os/BinderInternal.java
+++ b/core/java/com/android/internal/os/BinderInternal.java
@@ -21,6 +21,7 @@
 import android.util.EventLog;
 
 import java.lang.ref.WeakReference;
+import java.util.ArrayList;
 
 /**
  * Private and debugging Binder APIs.
@@ -28,19 +29,35 @@
  * @see IBinder
  */
 public class BinderInternal {
-    static WeakReference<GcWatcher> mGcWatcher
+    static WeakReference<GcWatcher> sGcWatcher
             = new WeakReference<GcWatcher>(new GcWatcher());
-    static long mLastGcTime;
-    
+    static ArrayList<Runnable> sGcWatchers = new ArrayList<>();
+    static Runnable[] sTmpWatchers = new Runnable[1];
+    static long sLastGcTime;
+
     static final class GcWatcher {
         @Override
         protected void finalize() throws Throwable {
             handleGc();
-            mLastGcTime = SystemClock.uptimeMillis();
-            mGcWatcher = new WeakReference<GcWatcher>(new GcWatcher());
+            sLastGcTime = SystemClock.uptimeMillis();
+            synchronized (sGcWatchers) {
+                sTmpWatchers = sGcWatchers.toArray(sTmpWatchers);
+            }
+            for (int i=0; i<sTmpWatchers.length; i++) {
+                if (sTmpWatchers[i] != null) {
+                    sTmpWatchers[i].run();
+                }
+            }
+            sGcWatcher = new WeakReference<GcWatcher>(new GcWatcher());
         }
     }
-    
+
+    public static void addGcWatcher(Runnable watcher) {
+        synchronized (sGcWatchers) {
+            sGcWatchers.add(watcher);
+        }
+    }
+
     /**
      * Add the calling thread to the IPC thread pool.  This function does
      * not return until the current process is exiting.
@@ -58,7 +75,7 @@
      * SystemClock.uptimeMillis()} of the last garbage collection.
      */
     public static long getLastGcTime() {
-        return mLastGcTime;
+        return sLastGcTime;
     }
 
     /**
diff --git a/core/java/com/android/internal/os/InstallerConnection.java b/core/java/com/android/internal/os/InstallerConnection.java
index e3f229f..2f30ebc 100644
--- a/core/java/com/android/internal/os/InstallerConnection.java
+++ b/core/java/com/android/internal/os/InstallerConnection.java
@@ -91,26 +91,40 @@
     }
 
     public int dexopt(String apkPath, int uid, boolean isPublic, String instructionSet) {
+        return dexopt(apkPath, uid, isPublic, "*", instructionSet, false);
+    }
+
+    public int dexopt(String apkPath, int uid, boolean isPublic, String pkgName,
+            String instructionSet, boolean vmSafeMode) {
         StringBuilder builder = new StringBuilder("dexopt");
         builder.append(' ');
         builder.append(apkPath);
         builder.append(' ');
         builder.append(uid);
         builder.append(isPublic ? " 1" : " 0");
-        builder.append(" *");         // No pkgName arg present
+        builder.append(' ');
+        builder.append(pkgName);
         builder.append(' ');
         builder.append(instructionSet);
+        builder.append(' ');
+        builder.append(vmSafeMode ? " 1" : " 0");
         return execute(builder.toString());
     }
 
     public int patchoat(String apkPath, int uid, boolean isPublic, String instructionSet) {
+        return patchoat(apkPath, uid, isPublic, "*", instructionSet);
+    }
+
+    public int patchoat(String apkPath, int uid, boolean isPublic, String pkgName,
+            String instructionSet) {
         StringBuilder builder = new StringBuilder("patchoat");
         builder.append(' ');
         builder.append(apkPath);
         builder.append(' ');
         builder.append(uid);
         builder.append(isPublic ? " 1" : " 0");
-        builder.append(" *");         // No pkgName arg present
+        builder.append(' ');
+        builder.append(pkgName);
         builder.append(' ');
         builder.append(instructionSet);
         return execute(builder.toString());
diff --git a/core/java/com/android/internal/os/ProcessCpuTracker.java b/core/java/com/android/internal/os/ProcessCpuTracker.java
index e58d68f..86f580d 100644
--- a/core/java/com/android/internal/os/ProcessCpuTracker.java
+++ b/core/java/com/android/internal/os/ProcessCpuTracker.java
@@ -64,7 +64,9 @@
 
     /** Stores user time and system time in 100ths of a second. */
     private final long[] mProcessStatsData = new long[4];
-    /** Stores user time and system time in 100ths of a second. */
+
+    /** Stores user time and system time in 100ths of a second.  Used for
+     * public API to retrieve CPU use for a process.  Must lock while in use. */
     private final long[] mSinglePidStatsData = new long[4];
 
     private static final int[] PROCESS_FULL_STATS_FORMAT = new int[] {
@@ -533,18 +535,20 @@
 
     /**
      * Returns the total time (in clock ticks, or 1/100 sec) spent executing in
-     * both user and system code.
+     * both user and system code.  Safe to call without lock held.
      */
     public long getCpuTimeForPid(int pid) {
-        final String statFile = "/proc/" + pid + "/stat";
-        final long[] statsData = mSinglePidStatsData;
-        if (Process.readProcFile(statFile, PROCESS_STATS_FORMAT,
-                null, statsData, null)) {
-            long time = statsData[PROCESS_STAT_UTIME]
-                    + statsData[PROCESS_STAT_STIME];
-            return time;
+        synchronized (mSinglePidStatsData) {
+            final String statFile = "/proc/" + pid + "/stat";
+            final long[] statsData = mSinglePidStatsData;
+            if (Process.readProcFile(statFile, PROCESS_STATS_FORMAT,
+                    null, statsData, null)) {
+                long time = statsData[PROCESS_STAT_UTIME]
+                        + statsData[PROCESS_STAT_STIME];
+                return time;
+            }
+            return 0;
         }
-        return 0;
     }
 
     /**
diff --git a/core/java/com/android/internal/os/RuntimeInit.java b/core/java/com/android/internal/os/RuntimeInit.java
index d35fce4..29ccb6a 100644
--- a/core/java/com/android/internal/os/RuntimeInit.java
+++ b/core/java/com/android/internal/os/RuntimeInit.java
@@ -338,10 +338,10 @@
      * @param tag to record with the error
      * @param t exception describing the error site and conditions
      */
-    public static void wtf(String tag, Throwable t) {
+    public static void wtf(String tag, Throwable t, boolean system) {
         try {
             if (ActivityManagerNative.getDefault().handleApplicationWtf(
-                    mApplicationObject, tag, new ApplicationErrorReport.CrashInfo(t))) {
+                    mApplicationObject, tag, system, new ApplicationErrorReport.CrashInfo(t))) {
                 // The Activity Manager has already written us off -- now exit.
                 Process.killProcess(Process.myPid());
                 System.exit(10);
diff --git a/core/java/com/android/internal/os/TransferPipe.java b/core/java/com/android/internal/os/TransferPipe.java
index 068d914..e76b395 100644
--- a/core/java/com/android/internal/os/TransferPipe.java
+++ b/core/java/com/android/internal/os/TransferPipe.java
@@ -174,15 +174,27 @@
     }
 
     public void kill() {
-        closeFd(0);
-        closeFd(1);
+        synchronized (this) {
+            closeFd(0);
+            closeFd(1);
+        }
     }
 
     @Override
     public void run() {
         final byte[] buffer = new byte[1024];
-        final FileInputStream fis = new FileInputStream(getReadFd().getFileDescriptor());
-        final FileOutputStream fos = new FileOutputStream(mOutFd);
+        final FileInputStream fis;
+        final FileOutputStream fos;
+
+        synchronized (this) {
+            ParcelFileDescriptor readFd = getReadFd();
+            if (readFd == null) {
+                Slog.w(TAG, "Pipe has been closed...");
+                return;
+            }
+            fis = new FileInputStream(readFd.getFileDescriptor());
+            fos = new FileOutputStream(mOutFd);
+        }
 
         if (DEBUG) Slog.i(TAG, "Ready to read pipe...");
         byte[] bufferPrefix = null;
diff --git a/core/java/com/android/internal/os/Zygote.java b/core/java/com/android/internal/os/Zygote.java
index 54c532a..c579a15 100644
--- a/core/java/com/android/internal/os/Zygote.java
+++ b/core/java/com/android/internal/os/Zygote.java
@@ -20,9 +20,12 @@
 import dalvik.system.ZygoteHooks;
 import android.system.ErrnoException;
 import android.system.Os;
+import android.os.SystemClock;
+import android.util.Slog;
 
 /** @hide */
 public final class Zygote {
+    private static final String TAG = "Zygote";
     /*
     * Bit values for "debugFlags" argument.  The definitions are duplicated
     * in the native code.
@@ -75,21 +78,41 @@
      * file descriptor numbers that are to be closed by the child
      * (and replaced by /dev/null) after forking.  An integer value
      * of -1 in any entry in the array means "ignore this one".
+     * @param instructionSet null-ok the instruction set to use.
      *
      * @return 0 if this is the child, pid of the child
      * if this is the parent, or -1 on error.
      */
     public static int forkAndSpecialize(int uid, int gid, int[] gids, int debugFlags,
-          int[][] rlimits, int mountExternal, String seInfo, String niceName, int[] fdsToClose) {
+          int[][] rlimits, int mountExternal, String seInfo, String niceName, int[] fdsToClose,
+          String instructionSet) {
+        long startTime = SystemClock.elapsedRealtime();
         VM_HOOKS.preFork();
+        checkTime(startTime, "Zygote.preFork");
         int pid = nativeForkAndSpecialize(
-                  uid, gid, gids, debugFlags, rlimits, mountExternal, seInfo, niceName, fdsToClose);
+                  uid, gid, gids, debugFlags, rlimits, mountExternal, seInfo, niceName, fdsToClose,
+                  instructionSet);
+        checkTime(startTime, "Zygote.nativeForkAndSpecialize");
         VM_HOOKS.postForkCommon();
+        checkTime(startTime, "Zygote.postForkCommon");
         return pid;
     }
 
     native private static int nativeForkAndSpecialize(int uid, int gid, int[] gids,int debugFlags,
-          int[][] rlimits, int mountExternal, String seInfo, String niceName, int[] fdsToClose);
+          int[][] rlimits, int mountExternal, String seInfo, String niceName, int[] fdsToClose,
+          String instructionSet);
+
+    /**
+     * Temporary hack: check time since start time and log if over a fixed threshold.
+     *
+     */
+    private static void checkTime(long startTime, String where) {
+        long now = SystemClock.elapsedRealtime();
+        if ((now-startTime) > 1000) {
+            // If we are taking more than a second, log about it.
+            Slog.w(TAG, "Slow operation: " + (now-startTime) + "ms so far, now at " + where);
+        }
+    }
 
     /**
      * Special method to start the system server process. In addition to the
@@ -126,8 +149,10 @@
     native private static int nativeForkSystemServer(int uid, int gid, int[] gids, int debugFlags,
             int[][] rlimits, long permittedCapabilities, long effectiveCapabilities);
 
-    private static void callPostForkChildHooks(int debugFlags) {
-        VM_HOOKS.postForkChild(debugFlags);
+    private static void callPostForkChildHooks(int debugFlags, String instructionSet) {
+        long startTime = SystemClock.elapsedRealtime();
+        VM_HOOKS.postForkChild(debugFlags, instructionSet);
+        checkTime(startTime, "Zygote.callPostForkChildHooks");
     }
 
 
diff --git a/core/java/com/android/internal/os/ZygoteConnection.java b/core/java/com/android/internal/os/ZygoteConnection.java
index 43ebb3d..fb50b25 100644
--- a/core/java/com/android/internal/os/ZygoteConnection.java
+++ b/core/java/com/android/internal/os/ZygoteConnection.java
@@ -37,6 +37,8 @@
 import java.nio.charset.StandardCharsets;
 import java.util.ArrayList;
 import libcore.io.IoUtils;
+import android.os.SystemClock;
+import android.util.Slog;
 
 /**
  * A connection that can make spawn requests.
@@ -103,11 +105,23 @@
     }
 
     /**
+     * Temporary hack: check time since start time and log if over a fixed threshold.
+     *
+     */
+    private void checkTime(long startTime, String where) {
+        long now = SystemClock.elapsedRealtime();
+        if ((now-startTime) > 1000) {
+            // If we are taking more than a second, log about it.
+            Slog.w(TAG, "Slow operation: " + (now-startTime) + "ms so far, now at " + where);
+        }
+    }
+
+    /**
      * Returns the file descriptor of the associated socket.
      *
      * @return null-ok; file descriptor
      */
-    FileDescriptor getFileDesciptor() {
+    FileDescriptor getFileDescriptor() {
         return mSocket.getFileDescriptor();
     }
 
@@ -131,6 +145,8 @@
         Arguments parsedArgs = null;
         FileDescriptor[] descriptors;
 
+        long startTime = SystemClock.elapsedRealtime();
+
         try {
             args = readArgumentList();
             descriptors = mSocket.getAncillaryFileDescriptors();
@@ -140,6 +156,7 @@
             return true;
         }
 
+        checkTime(startTime, "zygoteConnection.runOnce: readArgumentList");
         if (args == null) {
             // EOF reached.
             closeSocket();
@@ -171,14 +188,19 @@
                         ", effective=0x" + Long.toHexString(parsedArgs.effectiveCapabilities));
             }
 
+
             applyUidSecurityPolicy(parsedArgs, peer, peerSecurityContext);
             applyRlimitSecurityPolicy(parsedArgs, peer, peerSecurityContext);
             applyInvokeWithSecurityPolicy(parsedArgs, peer, peerSecurityContext);
             applyseInfoSecurityPolicy(parsedArgs, peer, peerSecurityContext);
 
+            checkTime(startTime, "zygoteConnection.runOnce: apply security policies");
+
             applyDebuggerSystemProperty(parsedArgs);
             applyInvokeWithSystemProperty(parsedArgs);
 
+            checkTime(startTime, "zygoteConnection.runOnce: apply security policies");
+
             int[][] rlimits = null;
 
             if (parsedArgs.rlimits != null) {
@@ -220,9 +242,11 @@
 
             fd = null;
 
+            checkTime(startTime, "zygoteConnection.runOnce: preForkAndSpecialize");
             pid = Zygote.forkAndSpecialize(parsedArgs.uid, parsedArgs.gid, parsedArgs.gids,
                     parsedArgs.debugFlags, rlimits, parsedArgs.mountExternal, parsedArgs.seInfo,
-                    parsedArgs.niceName, fdsToClose);
+                    parsedArgs.niceName, fdsToClose, parsedArgs.instructionSet);
+            checkTime(startTime, "zygoteConnection.runOnce: postForkAndSpecialize");
         } catch (IOException ex) {
             logAndPrintError(newStderr, "Exception creating pipe", ex);
         } catch (ErrnoException ex) {
@@ -311,6 +335,7 @@
      *      [--] &lt;args for RuntimeInit &gt;
      *   <li> If <code>--runtime-init</code> is absent:
      *      [--] &lt;classname&gt; [args...]
+     *   <li> --instruction-set=<i>instruction-set-string</i> which instruction set to use/emulate.
      * </ul>
      */
     static class Arguments {
@@ -374,6 +399,11 @@
         boolean abiListQuery;
 
         /**
+         * The instruction set to use, or null when not important.
+         */
+        String instructionSet;
+
+        /**
          * Constructs instance and parses args
          * @param args zygote command-line args
          * @throws IllegalArgumentException
@@ -528,6 +558,8 @@
                     mountExternal = Zygote.MOUNT_EXTERNAL_MULTIUSER_ALL;
                 } else if (arg.equals("--query-abi-list")) {
                     abiListQuery = true;
+                } else if (arg.startsWith("--instruction-set=")) {
+                    instructionSet = arg.substring(arg.indexOf('=') + 1);
                 } else {
                     break;
                 }
diff --git a/core/java/com/android/internal/os/ZygoteInit.java b/core/java/com/android/internal/os/ZygoteInit.java
index 051de6e..40c9ed2 100644
--- a/core/java/com/android/internal/os/ZygoteInit.java
+++ b/core/java/com/android/internal/os/ZygoteInit.java
@@ -254,12 +254,20 @@
         preloadClasses();
         preloadResources();
         preloadOpenGL();
+        preloadSharedLibraries();
         // Ask the WebViewFactory to do any initialization that must run in the zygote process,
         // for memory sharing purposes.
         WebViewFactory.prepareWebViewInZygote();
         Log.d(TAG, "end preload");
     }
 
+    private static void preloadSharedLibraries() {
+        Log.i(TAG, "Preloading shared libraries...");
+        System.loadLibrary("android");
+        System.loadLibrary("compiler_rt");
+        System.loadLibrary("jnigraphics");
+    }
+
     private static void preloadOpenGL() {
         if (!SystemProperties.getBoolean(PROPERTY_DISABLE_OPENGL_PRELOADING, false)) {
             EGL14.eglGetDisplay(EGL14.EGL_DEFAULT_DISPLAY);
@@ -770,7 +778,7 @@
             } else if (index == 0) {
                 ZygoteConnection newPeer = acceptCommandPeer(abiList);
                 peers.add(newPeer);
-                fds.add(newPeer.getFileDesciptor());
+                fds.add(newPeer.getFileDescriptor());
             } else {
                 boolean done;
                 done = peers.get(index).runOnce();
diff --git a/core/java/com/android/internal/util/ArrayUtils.java b/core/java/com/android/internal/util/ArrayUtils.java
index 3ed4d51..8e786da 100644
--- a/core/java/com/android/internal/util/ArrayUtils.java
+++ b/core/java/com/android/internal/util/ArrayUtils.java
@@ -107,7 +107,7 @@
             return (T[]) EmptyArray.OBJECT;
         }
 
-        int bucket = ((System.identityHashCode(kind) / 8) & 0x7FFFFFFF) % CACHE_SIZE;
+        int bucket = (kind.hashCode() & 0x7FFFFFFF) % CACHE_SIZE;
         Object cache = sCache[bucket];
 
         if (cache == null || cache.getClass().getComponentType() != kind) {
diff --git a/core/java/com/android/internal/util/ImageUtils.java b/core/java/com/android/internal/util/ImageUtils.java
index a5ce6e0ca..c153904 100644
--- a/core/java/com/android/internal/util/ImageUtils.java
+++ b/core/java/com/android/internal/util/ImageUtils.java
@@ -17,6 +17,10 @@
 package com.android.internal.util;
 
 import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Matrix;
+import android.graphics.Paint;
+import android.graphics.PorterDuff;
 
 /**
  * Utility class for image analysis and processing.
@@ -31,17 +35,49 @@
     // Alpha amount for which values below are considered transparent.
     private static final int ALPHA_TOLERANCE = 50;
 
+    // Size of the smaller bitmap we're actually going to scan.
+    private static final int COMPACT_BITMAP_SIZE = 64; // pixels
+
     private int[] mTempBuffer;
+    private Bitmap mTempCompactBitmap;
+    private Canvas mTempCompactBitmapCanvas;
+    private Paint mTempCompactBitmapPaint;
+    private final Matrix mTempMatrix = new Matrix();
 
     /**
      * Checks whether a bitmap is grayscale. Grayscale here means "very close to a perfect
      * gray".
+     *
+     * Instead of scanning every pixel in the bitmap, we first resize the bitmap to no more than
+     * COMPACT_BITMAP_SIZE^2 pixels using filtering. The hope is that any non-gray color elements
+     * will survive the squeezing process, contaminating the result with color.
      */
     public boolean isGrayscale(Bitmap bitmap) {
-        final int height = bitmap.getHeight();
-        final int width = bitmap.getWidth();
-        int size = height*width;
+        int height = bitmap.getHeight();
+        int width = bitmap.getWidth();
 
+        // shrink to a more manageable (yet hopefully no more or less colorful) size
+        if (height > COMPACT_BITMAP_SIZE || width > COMPACT_BITMAP_SIZE) {
+            if (mTempCompactBitmap == null) {
+                mTempCompactBitmap = Bitmap.createBitmap(
+                        COMPACT_BITMAP_SIZE, COMPACT_BITMAP_SIZE, Bitmap.Config.ARGB_8888
+                );
+                mTempCompactBitmapCanvas = new Canvas(mTempCompactBitmap);
+                mTempCompactBitmapPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
+                mTempCompactBitmapPaint.setFilterBitmap(true);
+            }
+            mTempMatrix.reset();
+            mTempMatrix.setScale(
+                    (float) COMPACT_BITMAP_SIZE / width,
+                    (float) COMPACT_BITMAP_SIZE / height,
+                    0, 0);
+            mTempCompactBitmapCanvas.drawColor(0, PorterDuff.Mode.SRC); // select all, erase
+            mTempCompactBitmapCanvas.drawBitmap(bitmap, mTempMatrix, mTempCompactBitmapPaint);
+            bitmap = mTempCompactBitmap;
+            width = height = COMPACT_BITMAP_SIZE;
+        }
+
+        final int size = height*width;
         ensureBufferSize(size);
         bitmap.getPixels(mTempBuffer, 0, width, 0, 0, width, height);
         for (int i = 0; i < size; i++) {
diff --git a/core/java/com/android/internal/util/NotificationColorUtil.java b/core/java/com/android/internal/util/NotificationColorUtil.java
index 665055c..3249ea3 100644
--- a/core/java/com/android/internal/util/NotificationColorUtil.java
+++ b/core/java/com/android/internal/util/NotificationColorUtil.java
@@ -50,23 +50,36 @@
     private final WeakHashMap<Bitmap, Pair<Boolean, Integer>> mGrayscaleBitmapCache =
             new WeakHashMap<Bitmap, Pair<Boolean, Integer>>();
 
-    public static NotificationColorUtil getInstance() {
+    private final int mGrayscaleIconMaxSize; // @dimen/notification_large_icon_width (64dp)
+
+    public static NotificationColorUtil getInstance(Context context) {
         synchronized (sLock) {
             if (sInstance == null) {
-                sInstance = new NotificationColorUtil();
+                sInstance = new NotificationColorUtil(context);
             }
             return sInstance;
         }
     }
 
+    private NotificationColorUtil(Context context) {
+        mGrayscaleIconMaxSize = context.getResources().getDimensionPixelSize(
+                com.android.internal.R.dimen.notification_large_icon_width);
+    }
+
     /**
-     * Checks whether a bitmap is grayscale. Grayscale here means "very close to a perfect
-     * gray".
+     * Checks whether a Bitmap is a small grayscale icon.
+     * Grayscale here means "very close to a perfect gray"; icon means "no larger than 64dp".
      *
      * @param bitmap The bitmap to test.
-     * @return Whether the bitmap is grayscale.
+     * @return True if the bitmap is grayscale; false if it is color or too large to examine.
      */
-    public boolean isGrayscale(Bitmap bitmap) {
+    public boolean isGrayscaleIcon(Bitmap bitmap) {
+        // quick test: reject large bitmaps
+        if (bitmap.getWidth() > mGrayscaleIconMaxSize
+                || bitmap.getHeight() > mGrayscaleIconMaxSize) {
+            return false;
+        }
+
         synchronized (sLock) {
             Pair<Boolean, Integer> cached = mGrayscaleBitmapCache.get(bitmap);
             if (cached != null) {
@@ -92,22 +105,22 @@
     }
 
     /**
-     * Checks whether a drawable is grayscale. Grayscale here means "very close to a perfect
-     * gray".
+     * Checks whether a Drawable is a small grayscale icon.
+     * Grayscale here means "very close to a perfect gray"; icon means "no larger than 64dp".
      *
      * @param d The drawable to test.
-     * @return Whether the drawable is grayscale.
+     * @return True if the bitmap is grayscale; false if it is color or too large to examine.
      */
-    public boolean isGrayscale(Drawable d) {
+    public boolean isGrayscaleIcon(Drawable d) {
         if (d == null) {
             return false;
         } else if (d instanceof BitmapDrawable) {
             BitmapDrawable bd = (BitmapDrawable) d;
-            return bd.getBitmap() != null && isGrayscale(bd.getBitmap());
+            return bd.getBitmap() != null && isGrayscaleIcon(bd.getBitmap());
         } else if (d instanceof AnimationDrawable) {
             AnimationDrawable ad = (AnimationDrawable) d;
             int count = ad.getNumberOfFrames();
-            return count > 0 && isGrayscale(ad.getFrame(0));
+            return count > 0 && isGrayscaleIcon(ad.getFrame(0));
         } else if (d instanceof VectorDrawable) {
             // We just assume you're doing the right thing if using vectors
             return true;
@@ -117,16 +130,16 @@
     }
 
     /**
-     * Checks whether a drawable with a resoure id is grayscale. Grayscale here means "very close
-     * to a perfect gray".
+     * Checks whether a drawable with a resoure id is a small grayscale icon.
+     * Grayscale here means "very close to a perfect gray"; icon means "no larger than 64dp".
      *
      * @param context The context to load the drawable from.
-     * @return Whether the drawable is grayscale.
+     * @return True if the bitmap is grayscale; false if it is color or too large to examine.
      */
-    public boolean isGrayscale(Context context, int drawableResId) {
+    public boolean isGrayscaleIcon(Context context, int drawableResId) {
         if (drawableResId != 0) {
             try {
-                return isGrayscale(context.getDrawable(drawableResId));
+                return isGrayscaleIcon(context.getDrawable(drawableResId));
             } catch (Resources.NotFoundException ex) {
                 Log.e(TAG, "Drawable not found: " + drawableResId);
                 return false;
diff --git a/core/java/com/android/internal/util/ParcelableString.java b/core/java/com/android/internal/util/ParcelableString.java
new file mode 100644
index 0000000..6bd856f
--- /dev/null
+++ b/core/java/com/android/internal/util/ParcelableString.java
@@ -0,0 +1,52 @@
+/*
+ * Copyright 2014, 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.internal.util;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Helper class to adapt a simple String to cases where a Parcelable is expected.
+ * @hide
+ */
+public class ParcelableString implements Parcelable {
+    public String string;
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeString(string);
+    }
+
+    public static final Parcelable.Creator<ParcelableString> CREATOR =
+            new Parcelable.Creator<ParcelableString>() {
+                @Override
+                public ParcelableString createFromParcel(Parcel in) {
+                    ParcelableString ret = new ParcelableString();
+                    ret.string = in.readString();
+                    return ret;
+                }
+                @Override
+                public ParcelableString[] newArray(int size) {
+                    return new ParcelableString[size];
+                }
+    };
+}
\ No newline at end of file
diff --git a/core/java/com/android/internal/util/UserIcons.java b/core/java/com/android/internal/util/UserIcons.java
new file mode 100644
index 0000000..e1e9d5e
--- /dev/null
+++ b/core/java/com/android/internal/util/UserIcons.java
@@ -0,0 +1,75 @@
+/*
+ * Copyright (C) 2014 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.internal.util;
+
+import android.content.res.Resources;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.PorterDuff.Mode;
+import android.graphics.drawable.Drawable;
+import android.os.UserHandle;
+
+import com.android.internal.R;
+
+/**
+ * Helper class that generates default user icons.
+ */
+public class UserIcons {
+
+    private static final int[] USER_ICON_COLORS = {
+        R.color.user_icon_1,
+        R.color.user_icon_2,
+        R.color.user_icon_3,
+        R.color.user_icon_4,
+        R.color.user_icon_5,
+        R.color.user_icon_6,
+        R.color.user_icon_7,
+        R.color.user_icon_8
+    };
+
+    /**
+     * Converts a given drawable to a bitmap.
+     */
+    public static Bitmap convertToBitmap(Drawable icon) {
+        if (icon == null) {
+            return null;
+        }
+        Bitmap bitmap = Bitmap.createBitmap(icon.getIntrinsicWidth(), icon.getIntrinsicHeight(),
+                Bitmap.Config.ARGB_8888);
+        icon.draw(new Canvas(bitmap));
+        return bitmap;
+    }
+
+    /**
+     * Returns a default user icon for the given user.
+     *
+     * Note that for guest users, you should pass in {@code UserHandle.USER_NULL}.
+     * @param userId the user id or {@code UserHandle.USER_NULL} for a non-user specific icon
+     * @param light whether we want a light icon (suitable for a dark background)
+     */
+    public static Drawable getDefaultUserIcon(int userId, boolean light) {
+        int colorResId = light ? R.color.user_icon_default_white : R.color.user_icon_default_gray;
+        if (userId != UserHandle.USER_NULL) {
+            // Return colored icon instead
+            colorResId = USER_ICON_COLORS[userId % USER_ICON_COLORS.length];
+        }
+        Drawable icon = Resources.getSystem().getDrawable(R.drawable.ic_account_circle).mutate();
+        icon.setColorFilter(Resources.getSystem().getColor(colorResId), Mode.SRC_IN);
+        icon.setBounds(0, 0, icon.getIntrinsicWidth(), icon.getIntrinsicHeight());
+        return icon;
+    }
+}
diff --git a/core/java/com/android/internal/util/XmlUtils.java b/core/java/com/android/internal/util/XmlUtils.java
index 7db70ba..45d790b 100644
--- a/core/java/com/android/internal/util/XmlUtils.java
+++ b/core/java/com/android/internal/util/XmlUtils.java
@@ -1440,6 +1440,16 @@
         return Boolean.parseBoolean(value);
     }
 
+    public static boolean readBooleanAttribute(XmlPullParser in, String name,
+            boolean defaultValue) {
+        final String value = in.getAttributeValue(null, name);
+        if (value == null) {
+            return defaultValue;
+        } else {
+            return Boolean.parseBoolean(value);
+        }
+    }
+
     public static void writeBooleanAttribute(XmlSerializer out, String name, boolean value)
             throws IOException {
         out.attribute(null, name, Boolean.toString(value));
diff --git a/core/java/com/android/internal/view/IInputConnectionWrapper.java b/core/java/com/android/internal/view/IInputConnectionWrapper.java
index 897381d..e19b2b6 100644
--- a/core/java/com/android/internal/view/IInputConnectionWrapper.java
+++ b/core/java/com/android/internal/view/IInputConnectionWrapper.java
@@ -25,7 +25,6 @@
 import android.view.KeyEvent;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CorrectionInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.ExtractedTextRequest;
 import android.view.inputmethod.InputConnection;
 
@@ -55,7 +54,7 @@
     private static final int DO_REPORT_FULLSCREEN_MODE = 100;
     private static final int DO_PERFORM_PRIVATE_COMMAND = 120;
     private static final int DO_CLEAR_META_KEY_STATES = 130;
-    private static final int DO_REQUEST_CURSOR_ANCHOR_INFO = 140;
+    private static final int DO_REQUEST_UPDATE_CURSOR_ANCHOR_INFO = 140;
 
     private WeakReference<InputConnection> mInputConnection;
 
@@ -177,9 +176,10 @@
         dispatchMessage(obtainMessageOO(DO_PERFORM_PRIVATE_COMMAND, action, data));
     }
 
-    public void requestCursorAnchorInfo(CursorAnchorInfoRequest request, int seq,
+    public void requestUpdateCursorAnchorInfo(int cursorUpdateMode, int seq,
             IInputContextCallback callback) {
-        dispatchMessage(obtainMessageOSC(DO_REQUEST_CURSOR_ANCHOR_INFO, request, seq, callback));
+        dispatchMessage(obtainMessageISC(DO_REQUEST_UPDATE_CURSOR_ANCHOR_INFO, cursorUpdateMode,
+                seq, callback));
     }
 
     void dispatchMessage(Message msg) {
@@ -427,18 +427,17 @@
                         (Bundle)args.arg2);
                 return;
             }
-            case DO_REQUEST_CURSOR_ANCHOR_INFO: {
+            case DO_REQUEST_UPDATE_CURSOR_ANCHOR_INFO: {
                 SomeArgs args = (SomeArgs)msg.obj;
                 try {
                     InputConnection ic = mInputConnection.get();
                     if (ic == null || !isActive()) {
                         Log.w(TAG, "requestCursorAnchorInfo on inactive InputConnection");
-                        args.callback.setRequestCursorAnchorInfoResult(0, args.seq);
+                        args.callback.setRequestUpdateCursorAnchorInfoResult(false, args.seq);
                         return;
                     }
-                    args.callback.setRequestCursorAnchorInfoResult(
-                            ic.requestCursorAnchorInfo((CursorAnchorInfoRequest)args.arg1),
-                            args.seq);
+                    args.callback.setRequestUpdateCursorAnchorInfoResult(
+                            ic.requestCursorUpdates(msg.arg1), args.seq);
                 } catch (RemoteException e) {
                     Log.w(TAG, "Got RemoteException calling requestCursorAnchorInfo", e);
                 }
diff --git a/core/java/com/android/internal/view/IInputContext.aidl b/core/java/com/android/internal/view/IInputContext.aidl
index c06596a..fd2b513 100644
--- a/core/java/com/android/internal/view/IInputContext.aidl
+++ b/core/java/com/android/internal/view/IInputContext.aidl
@@ -20,7 +20,6 @@
 import android.view.KeyEvent;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CorrectionInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.ExtractedTextRequest;
 
 import com.android.internal.view.IInputContextCallback;
@@ -74,6 +73,6 @@
 
     void getSelectedText(int flags, int seq, IInputContextCallback callback);
 
-    void requestCursorAnchorInfo(in CursorAnchorInfoRequest request, int seq,
+    void requestUpdateCursorAnchorInfo(in int cursorUpdateMode, int seq,
             IInputContextCallback callback);
 }
diff --git a/core/java/com/android/internal/view/IInputContextCallback.aidl b/core/java/com/android/internal/view/IInputContextCallback.aidl
index ab2fbdc..54ea306 100644
--- a/core/java/com/android/internal/view/IInputContextCallback.aidl
+++ b/core/java/com/android/internal/view/IInputContextCallback.aidl
@@ -27,5 +27,5 @@
     void setCursorCapsMode(int capsMode, int seq);
     void setExtractedText(in ExtractedText extractedText, int seq);
     void setSelectedText(CharSequence selectedText, int seq);
-    void setRequestCursorAnchorInfoResult(int result, int seq);
+    void setRequestUpdateCursorAnchorInfoResult(boolean result, int seq);
 }
diff --git a/core/java/com/android/internal/view/InputConnectionWrapper.java b/core/java/com/android/internal/view/InputConnectionWrapper.java
index 8535a98..7dc927f 100644
--- a/core/java/com/android/internal/view/InputConnectionWrapper.java
+++ b/core/java/com/android/internal/view/InputConnectionWrapper.java
@@ -23,7 +23,6 @@
 import android.view.KeyEvent;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CorrectionInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.ExtractedText;
 import android.view.inputmethod.ExtractedTextRequest;
 import android.view.inputmethod.InputConnection;
@@ -41,7 +40,7 @@
         public CharSequence mSelectedText;
         public ExtractedText mExtractedText;
         public int mCursorCapsMode;
-        public int mCursorAnchorInfoRequestResult;
+        public boolean mRequestUpdateCursorAnchorInfoResult;
         
         // A 'pool' of one InputContextCallback.  Each ICW request will attempt to gain
         // exclusive access to this object.
@@ -155,10 +154,10 @@
             }
         }
 
-        public void setRequestCursorAnchorInfoResult(int result, int seq) {
+        public void setRequestUpdateCursorAnchorInfoResult(boolean result, int seq) {
             synchronized (this) {
                 if (seq == mSeq) {
-                    mCursorAnchorInfoRequestResult = result;
+                    mRequestUpdateCursorAnchorInfoResult = result;
                     mHaveValue = true;
                     notifyAll();
                 } else {
@@ -429,21 +428,21 @@
         }
     }
 
-    public int requestCursorAnchorInfo(CursorAnchorInfoRequest request) {
-        int value = CursorAnchorInfoRequest.RESULT_NOT_HANDLED;
+    public boolean requestCursorUpdates(int cursorUpdateMode) {
+        boolean result = false;
         try {
             InputContextCallback callback = InputContextCallback.getInstance();
-            mIInputContext.requestCursorAnchorInfo(request, callback.mSeq, callback);
+            mIInputContext.requestUpdateCursorAnchorInfo(cursorUpdateMode, callback.mSeq, callback);
             synchronized (callback) {
                 callback.waitForResultLocked();
                 if (callback.mHaveValue) {
-                    value = callback.mCursorAnchorInfoRequestResult;
+                    result = callback.mRequestUpdateCursorAnchorInfoResult;
                 }
             }
             callback.dispose();
         } catch (RemoteException e) {
-            return CursorAnchorInfoRequest.RESULT_NOT_HANDLED;
+            return false;
         }
-        return value;
+        return result;
     }
 }
diff --git a/core/java/com/android/internal/view/menu/ActionMenuItemView.java b/core/java/com/android/internal/view/menu/ActionMenuItemView.java
index 891baea..7eec392 100644
--- a/core/java/com/android/internal/view/menu/ActionMenuItemView.java
+++ b/core/java/com/android/internal/view/menu/ActionMenuItemView.java
@@ -265,13 +265,15 @@
         final int width = getWidth();
         final int height = getHeight();
         final int midy = screenPos[1] + height / 2;
-        final int screenWidth = context.getResources().getDisplayMetrics().widthPixels;
-
+        int referenceX = screenPos[0] + width / 2;
+        if (v.getLayoutDirection() == View.LAYOUT_DIRECTION_LTR) {
+            final int screenWidth = context.getResources().getDisplayMetrics().widthPixels;
+            referenceX = screenWidth - referenceX; // mirror
+        }
         Toast cheatSheet = Toast.makeText(context, mItemData.getTitle(), Toast.LENGTH_SHORT);
         if (midy < displayFrame.height()) {
             // Show along the top; follow action buttons
-            cheatSheet.setGravity(Gravity.TOP | Gravity.END,
-                    screenWidth - screenPos[0] - width / 2, height);
+            cheatSheet.setGravity(Gravity.TOP | Gravity.END, referenceX, height);
         } else {
             // Show along the bottom center
             cheatSheet.setGravity(Gravity.BOTTOM | Gravity.CENTER_HORIZONTAL, 0, height);
diff --git a/core/java/com/android/internal/widget/ActionBarContainer.java b/core/java/com/android/internal/widget/ActionBarContainer.java
index 254f602..847a47d 100644
--- a/core/java/com/android/internal/widget/ActionBarContainer.java
+++ b/core/java/com/android/internal/widget/ActionBarContainer.java
@@ -22,6 +22,7 @@
 import android.graphics.Canvas;
 import android.graphics.ColorFilter;
 import android.graphics.Outline;
+import android.graphics.PixelFormat;
 import android.graphics.drawable.Drawable;
 import android.util.AttributeSet;
 import android.view.ActionMode;
@@ -39,6 +40,7 @@
     private boolean mIsTransitioning;
     private View mTabContainer;
     private View mActionBarView;
+    private View mActionContextView;
 
     private Drawable mBackground;
     private Drawable mStackedBackground;
@@ -79,6 +81,7 @@
     public void onFinishInflate() {
         super.onFinishInflate();
         mActionBarView = findViewById(com.android.internal.R.id.action_bar);
+        mActionContextView = findViewById(com.android.internal.R.id.action_context_bar);
     }
 
     public void setPrimaryBackground(Drawable bg) {
@@ -257,6 +260,11 @@
         return view == null || view.getVisibility() == GONE || view.getMeasuredHeight() == 0;
     }
 
+    private int getMeasuredHeightWithMargins(View view) {
+        final LayoutParams lp = (LayoutParams) view.getLayoutParams();
+        return view.getMeasuredHeight() + lp.topMargin + lp.bottomMargin;
+    }
+
     @Override
     public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
         if (mActionBarView == null &&
@@ -268,18 +276,23 @@
 
         if (mActionBarView == null) return;
 
-        final LayoutParams lp = (LayoutParams) mActionBarView.getLayoutParams();
-        final int actionBarViewHeight = isCollapsed(mActionBarView) ? 0 :
-                mActionBarView.getMeasuredHeight() + lp.topMargin + lp.bottomMargin;
-
         if (mTabContainer != null && mTabContainer.getVisibility() != GONE) {
-            final int mode = MeasureSpec.getMode(heightMeasureSpec);
-            if (mode == MeasureSpec.AT_MOST) {
-                final int maxHeight = MeasureSpec.getSize(heightMeasureSpec);
-                setMeasuredDimension(getMeasuredWidth(),
-                        Math.min(actionBarViewHeight + mTabContainer.getMeasuredHeight(),
-                                maxHeight));
+            int nonTabMaxHeight = 0;
+            final int childCount = getChildCount();
+            for (int i = 0; i < childCount; i++) {
+                final View child = getChildAt(i);
+                if (child == mTabContainer) {
+                    continue;
+                }
+                nonTabMaxHeight = Math.max(nonTabMaxHeight, isCollapsed(child) ? 0 :
+                        getMeasuredHeightWithMargins(child));
             }
+            final int mode = MeasureSpec.getMode(heightMeasureSpec);
+            final int maxHeight = mode == MeasureSpec.AT_MOST ?
+                    MeasureSpec.getSize(heightMeasureSpec) : Integer.MAX_VALUE;
+            setMeasuredDimension(getMeasuredWidth(),
+                    Math.min(nonTabMaxHeight + getMeasuredHeightWithMargins(mTabContainer),
+                            maxHeight));
         }
     }
 
@@ -292,8 +305,10 @@
 
         if (tabContainer != null && tabContainer.getVisibility() != GONE) {
             final int containerHeight = getMeasuredHeight();
+            final LayoutParams lp = (LayoutParams) tabContainer.getLayoutParams();
             final int tabHeight = tabContainer.getMeasuredHeight();
-            tabContainer.layout(l, containerHeight - tabHeight, r, containerHeight);
+            tabContainer.layout(l, containerHeight - tabHeight - lp.bottomMargin, r,
+                    containerHeight - lp.bottomMargin);
         }
 
         boolean needsInvalidate = false;
@@ -304,8 +319,16 @@
             }
         } else {
             if (mBackground != null) {
-                mBackground.setBounds(mActionBarView.getLeft(), mActionBarView.getTop(),
-                        mActionBarView.getRight(), mActionBarView.getBottom());
+                if (mActionBarView.getVisibility() == View.VISIBLE) {
+                    mBackground.setBounds(mActionBarView.getLeft(), mActionBarView.getTop(),
+                            mActionBarView.getRight(), mActionBarView.getBottom());
+                } else if (mActionContextView != null &&
+                        mActionContextView.getVisibility() == View.VISIBLE) {
+                    mBackground.setBounds(mActionContextView.getLeft(), mActionContextView.getTop(),
+                            mActionContextView.getRight(), mActionContextView.getBottom());
+                } else {
+                    mBackground.setBounds(0, 0, 0, 0);
+                }
                 needsInvalidate = true;
             }
             mIsStacked = hasTabs;
@@ -366,7 +389,23 @@
 
         @Override
         public int getOpacity() {
-            return 0;
+            if (mIsSplit) {
+                if (mSplitBackground != null
+                        && mSplitBackground.getOpacity() == PixelFormat.OPAQUE) {
+                    return PixelFormat.OPAQUE;
+                }
+            } else {
+                if (mIsStacked && (mStackedBackground == null
+                        || mStackedBackground.getOpacity() != PixelFormat.OPAQUE)) {
+                    return PixelFormat.UNKNOWN;
+                }
+                if (!isCollapsed(mActionBarView) && mBackground != null
+                        && mBackground.getOpacity() == PixelFormat.OPAQUE) {
+                    return PixelFormat.OPAQUE;
+                }
+            }
+
+            return PixelFormat.UNKNOWN;
         }
     }
 }
diff --git a/core/java/com/android/internal/widget/ActionBarContextView.java b/core/java/com/android/internal/widget/ActionBarContextView.java
index c7ac815..062a9b1 100644
--- a/core/java/com/android/internal/widget/ActionBarContextView.java
+++ b/core/java/com/android/internal/widget/ActionBarContextView.java
@@ -59,6 +59,7 @@
     private int mSubtitleStyleRes;
     private Drawable mSplitBackground;
     private boolean mTitleOptional;
+    private int mCloseItemLayout;
 
     private Animator mCurrentAnimation;
     private boolean mAnimateInOnLayout;
@@ -99,6 +100,10 @@
         mSplitBackground = a.getDrawable(
                 com.android.internal.R.styleable.ActionMode_backgroundSplit);
 
+        mCloseItemLayout = a.getResourceId(
+                com.android.internal.R.styleable.ActionMode_closeItemLayout,
+                R.layout.action_mode_close_item);
+
         a.recycle();
     }
 
@@ -120,7 +125,7 @@
                         LayoutParams.MATCH_PARENT);
                 if (!split) {
                     mMenuView = (ActionMenuView) mActionMenuPresenter.getMenuView(this);
-                    mMenuView.setBackgroundDrawable(null);
+                    mMenuView.setBackground(null);
                     final ViewGroup oldParent = (ViewGroup) mMenuView.getParent();
                     if (oldParent != null) oldParent.removeView(mMenuView);
                     addView(mMenuView, layoutParams);
@@ -134,7 +139,7 @@
                     layoutParams.width = LayoutParams.MATCH_PARENT;
                     layoutParams.height = mContentHeight;
                     mMenuView = (ActionMenuView) mActionMenuPresenter.getMenuView(this);
-                    mMenuView.setBackgroundDrawable(mSplitBackground);
+                    mMenuView.setBackground(mSplitBackground);
                     final ViewGroup oldParent = (ViewGroup) mMenuView.getParent();
                     if (oldParent != null) oldParent.removeView(mMenuView);
                     mSplitView.addView(mMenuView, layoutParams);
@@ -211,7 +216,7 @@
     public void initForMode(final ActionMode mode) {
         if (mClose == null) {
             LayoutInflater inflater = LayoutInflater.from(mContext);
-            mClose = inflater.inflate(R.layout.action_mode_close_item, this, false);
+            mClose = inflater.inflate(mCloseItemLayout, this, false);
             addView(mClose);
         } else if (mClose.getParent() == null) {
             addView(mClose);
diff --git a/core/java/com/android/internal/widget/ActionBarOverlayLayout.java b/core/java/com/android/internal/widget/ActionBarOverlayLayout.java
index 5709f659..cca48d3 100644
--- a/core/java/com/android/internal/widget/ActionBarOverlayLayout.java
+++ b/core/java/com/android/internal/widget/ActionBarOverlayLayout.java
@@ -184,8 +184,6 @@
                 Build.VERSION_CODES.KITKAT;
 
         mFlingEstimator = new OverScroller(context);
-
-        setFocusableInTouchMode(true);
     }
 
     @Override
@@ -661,27 +659,6 @@
     }
 
     @Override
-    public boolean dispatchKeyEvent(KeyEvent event) {
-        if (super.dispatchKeyEvent(event)) {
-            return true;
-        }
-
-        if (event.getKeyCode() == KeyEvent.KEYCODE_BACK) {
-            final int action = event.getAction();
-
-            // Collapse any expanded action views.
-            if (mDecorToolbar != null && mDecorToolbar.hasExpandedActionView()) {
-                if (action == KeyEvent.ACTION_UP) {
-                    mDecorToolbar.collapseActionView();
-                }
-                return true;
-            }
-        }
-
-        return false;
-    }
-
-    @Override
     public void setWindowCallback(Window.Callback cb) {
         pullChildren();
         mDecorToolbar.setWindowCallback(cb);
diff --git a/core/java/com/android/internal/widget/ActionBarView.java b/core/java/com/android/internal/widget/ActionBarView.java
index e53af69..fb44e58 100644
--- a/core/java/com/android/internal/widget/ActionBarView.java
+++ b/core/java/com/android/internal/widget/ActionBarView.java
@@ -135,6 +135,7 @@
 
     private ExpandedActionViewMenuPresenter mExpandedMenuPresenter;
     View mExpandedActionView;
+    private int mDefaultUpDescription = R.string.action_bar_up_description;
 
     Window.Callback mWindowCallback;
 
@@ -187,7 +188,7 @@
         mExpandedHomeLayout.setShowUp(true);
         mExpandedHomeLayout.setOnClickListener(mExpandedActionViewUpListener);
         mExpandedHomeLayout.setContentDescription(getResources().getText(
-                R.string.action_bar_up_description));
+                mDefaultUpDescription));
 
         // This needs to highlight/be focusable on its own.
         // TODO: Clean up the handoff between expanded/normal.
@@ -579,7 +580,7 @@
             homeDesc = mHomeDescription;
         } else {
             if ((mDisplayOptions & ActionBar.DISPLAY_HOME_AS_UP) != 0) {
-                homeDesc = mContext.getResources().getText(R.string.action_bar_up_description);
+                homeDesc = mContext.getResources().getText(mDefaultUpDescription);
             } else {
                 homeDesc = mContext.getResources().getText(R.string.action_bar_home_description);
             }
@@ -1330,6 +1331,15 @@
         updateHomeAccessibility(mUpGoerFive.isEnabled());
     }
 
+    @Override
+    public void setDefaultNavigationContentDescription(int defaultNavigationContentDescription) {
+        if (mDefaultUpDescription == defaultNavigationContentDescription) {
+            return;
+        }
+        mDefaultUpDescription = defaultNavigationContentDescription;
+        updateHomeAccessibility(mUpGoerFive.isEnabled());
+    }
+
     static class SavedState extends BaseSavedState {
         int expandedMenuItemId;
         boolean isOverflowOpen;
diff --git a/core/java/com/android/internal/widget/BackgroundFallback.java b/core/java/com/android/internal/widget/BackgroundFallback.java
new file mode 100644
index 0000000..4adba4d
--- /dev/null
+++ b/core/java/com/android/internal/widget/BackgroundFallback.java
@@ -0,0 +1,101 @@
+/*
+ * Copyright (C) 2014 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.internal.widget;
+
+import android.graphics.Canvas;
+import android.graphics.PixelFormat;
+import android.graphics.drawable.Drawable;
+import android.view.View;
+import android.view.ViewGroup;
+
+/**
+ * Helper class for drawing a fallback background in framework decor layouts.
+ * Useful for when an app has not set a window background but we're asked to draw
+ * an uncovered area.
+ */
+public class BackgroundFallback {
+    private Drawable mBackgroundFallback;
+
+    public void setDrawable(Drawable d) {
+        mBackgroundFallback = d;
+    }
+
+    public boolean hasFallback() {
+        return mBackgroundFallback != null;
+    }
+
+    public void draw(ViewGroup root, Canvas c, View content) {
+        if (!hasFallback()) {
+            return;
+        }
+
+        // Draw the fallback in the padding.
+        final int width = root.getWidth();
+        final int height = root.getHeight();
+        int left = width;
+        int top = height;
+        int right = 0;
+        int bottom = 0;
+
+        final int childCount = root.getChildCount();
+        for (int i = 0; i < childCount; i++) {
+            final View child = root.getChildAt(i);
+            final Drawable childBg = child.getBackground();
+            if (child == content) {
+                // We always count the content view container unless it has no background
+                // and no children.
+                if (childBg == null && child instanceof ViewGroup &&
+                        ((ViewGroup) child).getChildCount() == 0) {
+                    continue;
+                }
+            } else if (child.getVisibility() != View.VISIBLE || childBg == null ||
+                    childBg.getOpacity() != PixelFormat.OPAQUE) {
+                // Potentially translucent or invisible children don't count, and we assume
+                // the content view will cover the whole area if we're in a background
+                // fallback situation.
+                continue;
+            }
+            left = Math.min(left, child.getLeft());
+            top = Math.min(top, child.getTop());
+            right = Math.max(right, child.getRight());
+            bottom = Math.max(bottom, child.getBottom());
+        }
+
+        if (left >= right || top >= bottom) {
+            // No valid area to draw in.
+            return;
+        }
+
+        if (top > 0) {
+            mBackgroundFallback.setBounds(0, 0, width, top);
+            mBackgroundFallback.draw(c);
+        }
+        if (left > 0) {
+            mBackgroundFallback.setBounds(0, top, left, height);
+            mBackgroundFallback.draw(c);
+        }
+        if (right < width) {
+            mBackgroundFallback.setBounds(right, top, width, height);
+            mBackgroundFallback.draw(c);
+        }
+        if (bottom < height) {
+            mBackgroundFallback.setBounds(left, bottom, right, height);
+            mBackgroundFallback.draw(c);
+        }
+    }
+}
diff --git a/core/java/com/android/internal/widget/DecorContentParent.java b/core/java/com/android/internal/widget/DecorContentParent.java
index 4fa370a..ac524f9 100644
--- a/core/java/com/android/internal/widget/DecorContentParent.java
+++ b/core/java/com/android/internal/widget/DecorContentParent.java
@@ -49,5 +49,4 @@
     void saveToolbarHierarchyState(SparseArray<Parcelable> toolbarStates);
     void restoreToolbarHierarchyState(SparseArray<Parcelable> toolbarStates);
     void dismissPopups();
-
 }
diff --git a/core/java/com/android/internal/widget/DecorToolbar.java b/core/java/com/android/internal/widget/DecorToolbar.java
index 5281045..fee3015 100644
--- a/core/java/com/android/internal/widget/DecorToolbar.java
+++ b/core/java/com/android/internal/widget/DecorToolbar.java
@@ -89,6 +89,7 @@
     void setNavigationIcon(int resId);
     void setNavigationContentDescription(CharSequence description);
     void setNavigationContentDescription(int resId);
+    void setDefaultNavigationContentDescription(int defaultNavigationContentDescription);
     void saveHierarchyState(SparseArray<Parcelable> toolbarStates);
     void restoreHierarchyState(SparseArray<Parcelable> toolbarStates);
 }
diff --git a/core/java/com/android/internal/widget/EditableInputConnection.java b/core/java/com/android/internal/widget/EditableInputConnection.java
index bfe0090..f211ff2 100644
--- a/core/java/com/android/internal/widget/EditableInputConnection.java
+++ b/core/java/com/android/internal/widget/EditableInputConnection.java
@@ -25,9 +25,9 @@
 import android.view.inputmethod.BaseInputConnection;
 import android.view.inputmethod.CompletionInfo;
 import android.view.inputmethod.CorrectionInfo;
-import android.view.inputmethod.CursorAnchorInfoRequest;
 import android.view.inputmethod.ExtractedText;
 import android.view.inputmethod.ExtractedTextRequest;
+import android.view.inputmethod.InputConnection;
 import android.widget.TextView;
 
 public class EditableInputConnection extends BaseInputConnection {
@@ -188,24 +188,31 @@
     }
 
     @Override
-    public int requestCursorAnchorInfo(CursorAnchorInfoRequest request) {
-        if (DEBUG) Log.v(TAG, "requestCursorAnchorInfo " + request);
+    public boolean requestCursorUpdates(int cursorUpdateMode) {
+        if (DEBUG) Log.v(TAG, "requestUpdateCursorAnchorInfo " + cursorUpdateMode);
 
-        // This implementation supports TYPE_CURSOR_ANCHOR_INFO only. Other events will be
-        // delegated to the super class.
-        if (request == null ||
-                request.getRequestType() != CursorAnchorInfoRequest.TYPE_CURSOR_ANCHOR_INFO) {
-            return super.requestCursorAnchorInfo(request);
+        // It is possible that any other bit is used as a valid flag in a future release.
+        // We should reject the entire request in such a case.
+        final int KNOWN_FLAGS_MASK = InputConnection.CURSOR_UPDATE_IMMEDIATE |
+                InputConnection.CURSOR_UPDATE_MONITOR;
+        final int unknownFlags = cursorUpdateMode & ~KNOWN_FLAGS_MASK;
+        if (unknownFlags != 0) {
+            if (DEBUG) {
+                Log.d(TAG, "Rejecting requestUpdateCursorAnchorInfo due to unknown flags." +
+                        " cursorUpdateMode=" + cursorUpdateMode +
+                        " unknownFlags=" + unknownFlags);
+            }
+            return false;
         }
+
         if (mIMM == null) {
             // In this case, TYPE_CURSOR_ANCHOR_INFO is not handled.
-            // TODO: Return some notification code for the input method that indicates
+            // TODO: Return some notification code rather than false to indicate method that
             // CursorAnchorInfo is temporarily unavailable.
-            return CursorAnchorInfoRequest.RESULT_NOT_HANDLED;
+            return false;
         }
-        final int flags = request.getRequestFlags();
-        mIMM.setCursorAnchorInfoMonitorMode(flags);
-        if ((flags & CursorAnchorInfoRequest.FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE) != 0) {
+        mIMM.setUpdateCursorAnchorInfoMode(cursorUpdateMode);
+        if ((cursorUpdateMode & InputConnection.CURSOR_UPDATE_IMMEDIATE) != 0) {
             if (mTextView == null) {
                 // In this case, FLAG_CURSOR_ANCHOR_INFO_IMMEDIATE is silently ignored.
                 // TODO: Return some notification code for the input method that indicates
@@ -220,6 +227,6 @@
                 mTextView.requestLayout();
             }
         }
-        return CursorAnchorInfoRequest.RESULT_SCHEDULED;
+        return true;
     }
 }
diff --git a/core/java/com/android/internal/widget/LockPatternUtils.java b/core/java/com/android/internal/widget/LockPatternUtils.java
index ece3e9d..7160724 100644
--- a/core/java/com/android/internal/widget/LockPatternUtils.java
+++ b/core/java/com/android/internal/widget/LockPatternUtils.java
@@ -27,15 +27,17 @@
 import android.content.Context;
 import android.content.Intent;
 import android.content.pm.PackageManager;
+import android.content.pm.UserInfo;
 import android.os.IBinder;
 import android.os.RemoteException;
 import android.os.ServiceManager;
 import android.os.SystemClock;
 import android.os.UserHandle;
+import android.os.UserManager;
 import android.os.storage.IMountService;
 import android.os.storage.StorageManager;
-import android.phone.PhoneManager;
 import android.provider.Settings;
+import android.telecom.TelecomManager;
 import android.text.TextUtils;
 import android.util.Log;
 import android.view.IWindowManager;
@@ -479,6 +481,7 @@
         saveLockPattern(null);
         setLong(PASSWORD_TYPE_KEY, DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED);
         setLong(PASSWORD_TYPE_ALTERNATE_KEY, DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED);
+        onAfterChangingPassword();
     }
 
     /**
@@ -498,7 +501,19 @@
      * @return true if lock screen is can be disabled
      */
     public boolean isLockScreenDisabled() {
-        return !isSecure() && getLong(DISABLE_LOCKSCREEN_KEY, 0) != 0;
+        if (!isSecure() && getLong(DISABLE_LOCKSCREEN_KEY, 0) != 0) {
+            // Check if the number of switchable users forces the lockscreen.
+            final List<UserInfo> users = UserManager.get(mContext).getUsers(true);
+            final int userCount = users.size();
+            int switchableUsers = 0;
+            for (int i = 0; i < userCount; i++) {
+                if (users.get(i).supportsSwitchTo()) {
+                    switchableUsers++;
+                }
+            }
+            return switchableUsers < 2;
+        }
+        return false;
     }
 
     /**
@@ -565,6 +580,7 @@
                 dpm.setActivePasswordState(DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, 0, 0,
                         0, 0, 0, 0, 0, userId);
             }
+            onAfterChangingPassword();
         } catch (RemoteException re) {
             Log.e(TAG, "Couldn't save lock pattern " + re);
         }
@@ -765,7 +781,9 @@
                 if (userHandle == UserHandle.USER_OWNER) {
                     // Update the encryption password.
                     int type = computedQuality == DevicePolicyManager.PASSWORD_QUALITY_NUMERIC
-                        ? StorageManager.CRYPT_TYPE_PIN : StorageManager.CRYPT_TYPE_PASSWORD;
+                        || computedQuality == DevicePolicyManager.PASSWORD_QUALITY_NUMERIC_COMPLEX
+                        ? StorageManager.CRYPT_TYPE_PIN
+                        : StorageManager.CRYPT_TYPE_PASSWORD;
                     updateEncryptionPassword(type, password);
                 }
 
@@ -844,6 +862,7 @@
                         DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, 0, 0, 0, 0, 0, 0, 0,
                         userHandle);
             }
+            onAfterChangingPassword();
         } catch (RemoteException re) {
             // Cant do much
             Log.e(TAG, "Unable to save lock password " + re);
@@ -857,14 +876,23 @@
      * @return stored password quality
      */
     public int getKeyguardStoredPasswordQuality() {
-        int quality =
-                (int) getLong(PASSWORD_TYPE_KEY, DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED);
+        return getKeyguardStoredPasswordQuality(getCurrentOrCallingUserId());
+    }
+
+    /**
+     * Retrieves the quality mode for {@param userHandle}.
+     * {@see DevicePolicyManager#getPasswordQuality(android.content.ComponentName)}
+     *
+     * @return stored password quality
+     */
+    public int getKeyguardStoredPasswordQuality(int userHandle) {
+        int quality = (int) getLong(PASSWORD_TYPE_KEY,
+                DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, userHandle);
         // If the user has chosen to use weak biometric sensor, then return the backup locking
         // method and treat biometric as a special case.
         if (quality == DevicePolicyManager.PASSWORD_QUALITY_BIOMETRIC_WEAK) {
-            quality =
-                (int) getLong(PASSWORD_TYPE_ALTERNATE_KEY,
-                        DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED);
+            quality = (int) getLong(PASSWORD_TYPE_ALTERNATE_KEY,
+                        DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED, userHandle);
         }
         return quality;
     }
@@ -1093,6 +1121,25 @@
      */
     public void setVisiblePatternEnabled(boolean enabled) {
         setBoolean(Settings.Secure.LOCK_PATTERN_VISIBLE, enabled);
+
+        // Update for crypto if owner
+        int userId = getCurrentOrCallingUserId();
+        if (userId != UserHandle.USER_OWNER) {
+            return;
+        }
+
+        IBinder service = ServiceManager.getService("mount");
+        if (service == null) {
+            Log.e(TAG, "Could not find the mount service to update the user info");
+            return;
+        }
+
+        IMountService mountService = IMountService.Stub.asInterface(service);
+        try {
+            mountService.setField("PatternVisible", enabled ? "1" : "0");
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error changing pattern visible state", e);
+        }
     }
 
     /**
@@ -1416,7 +1463,7 @@
         }
 
         int textId;
-        if (getPhoneManager().isInAPhoneCall()) {
+        if (isInCall()) {
             // show "return to call" text and show phone icon
             textId = R.string.lockscreen_return_to_call;
             int phoneCallIcon = showIcon ? R.drawable.stat_sys_phone_call : 0;
@@ -1434,11 +1481,18 @@
      * on various lockscreens.
      */
     public void resumeCall() {
-        getPhoneManager().showCallScreen(false);
+        getTelecommManager().showInCallScreen(false);
     }
 
-    private PhoneManager getPhoneManager() {
-        return (PhoneManager) mContext.getSystemService(Context.PHONE_SERVICE);
+    /**
+     * @return {@code true} if there is a call currently in progress, {@code false} otherwise.
+     */
+    public boolean isInCall() {
+        return getTelecommManager().isInCall();
+    }
+
+    private TelecomManager getTelecommManager() {
+        return (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
     }
 
     private void finishBiometricWeak() {
@@ -1542,4 +1596,8 @@
     public void requireCredentialEntry(int userId) {
         getTrustManager().reportRequireCredentialEntry(userId);
     }
+
+    private void onAfterChangingPassword() {
+        getTrustManager().reportEnabledTrustAgentsChanged(getCurrentOrCallingUserId());
+    }
 }
diff --git a/core/java/com/android/internal/widget/ResolverDrawerLayout.java b/core/java/com/android/internal/widget/ResolverDrawerLayout.java
index e53f9dd..375822f 100644
--- a/core/java/com/android/internal/widget/ResolverDrawerLayout.java
+++ b/core/java/com/android/internal/widget/ResolverDrawerLayout.java
@@ -20,15 +20,15 @@
 import android.content.Context;
 import android.content.res.TypedArray;
 import android.graphics.Rect;
+import android.os.Parcel;
+import android.os.Parcelable;
 import android.util.AttributeSet;
 import android.util.Log;
-import android.view.Gravity;
 import android.view.MotionEvent;
 import android.view.VelocityTracker;
 import android.view.View;
 import android.view.ViewConfiguration;
 import android.view.ViewGroup;
-
 import android.view.ViewParent;
 import android.view.ViewTreeObserver;
 import android.view.animation.AnimationUtils;
@@ -68,6 +68,7 @@
 
     private boolean mIsDragging;
     private boolean mOpenOnClick;
+    private boolean mOpenOnLayout;
     private final int mTouchSlop;
     private final float mMinFlingVelocity;
     private final OverScroller mScroller;
@@ -202,6 +203,8 @@
     public boolean onTouchEvent(MotionEvent ev) {
         final int action = ev.getActionMasked();
 
+        mVelocityTracker.addMovement(ev);
+
         boolean handled = false;
         switch (action) {
             case MotionEvent.ACTION_DOWN: {
@@ -288,6 +291,10 @@
             break;
 
             case MotionEvent.ACTION_CANCEL: {
+                if (mIsDragging) {
+                    smoothScrollTo(
+                            mCollapseOffset < mCollapsibleHeight / 2 ? 0 : mCollapsibleHeight, 0);
+                }
                 resetTouch();
                 return true;
             }
@@ -498,28 +505,39 @@
     @Override
     public void onStopNestedScroll(View child) {
         super.onStopNestedScroll(child);
-        smoothScrollTo(mCollapseOffset < mCollapsibleHeight / 2 ? 0 : mCollapsibleHeight, 0);
+        if (mScroller.isFinished()) {
+            smoothScrollTo(mCollapseOffset < mCollapsibleHeight / 2 ? 0 : mCollapsibleHeight, 0);
+        }
     }
 
     @Override
     public void onNestedScroll(View target, int dxConsumed, int dyConsumed,
             int dxUnconsumed, int dyUnconsumed) {
-        if (dyUnconsumed > 0) {
+        if (dyUnconsumed < 0) {
             performDrag(-dyUnconsumed);
         }
     }
 
     @Override
     public void onNestedPreScroll(View target, int dx, int dy, int[] consumed) {
-        if (dy < 0) {
-            consumed[1] = (int) performDrag(-dy);
+        if (dy > 0) {
+            consumed[1] = (int) -performDrag(-dy);
         }
     }
 
     @Override
+    public boolean onNestedPreFling(View target, float velocityX, float velocityY) {
+        if (velocityY > mMinFlingVelocity && mCollapseOffset != 0) {
+            smoothScrollTo(0, velocityY);
+            return true;
+        }
+        return false;
+    }
+
+    @Override
     public boolean onNestedFling(View target, float velocityX, float velocityY, boolean consumed) {
         if (!consumed && Math.abs(velocityY) > mMinFlingVelocity) {
-            smoothScrollTo(velocityY < 0 ? 0 : mCollapsibleHeight, velocityY);
+            smoothScrollTo(velocityY > 0 ? 0 : mCollapsibleHeight, velocityY);
             return true;
         }
         return false;
@@ -571,8 +589,8 @@
         if (isLaidOut()) {
             mCollapseOffset = Math.min(mCollapseOffset, mCollapsibleHeight);
         } else {
-            // Start out collapsed at first
-            mCollapseOffset = mCollapsibleHeight;
+            // Start out collapsed at first unless we restored state for otherwise
+            mCollapseOffset = mOpenOnLayout ? 0 : mCollapsibleHeight;
         }
 
         mTopOffset = Math.max(0, heightSize - heightUsed) + (int) mCollapseOffset;
@@ -634,6 +652,20 @@
         return new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.WRAP_CONTENT);
     }
 
+    @Override
+    protected Parcelable onSaveInstanceState() {
+        final SavedState ss = new SavedState(super.onSaveInstanceState());
+        ss.open = mCollapsibleHeight > 0 && mCollapseOffset == 0;
+        return ss;
+    }
+
+    @Override
+    protected void onRestoreInstanceState(Parcelable state) {
+        final SavedState ss = (SavedState) state;
+        super.onRestoreInstanceState(ss.getSuperState());
+        mOpenOnLayout = ss.open;
+    }
+
     public static class LayoutParams extends MarginLayoutParams {
         public boolean alwaysShow;
         public boolean ignoreOffset;
@@ -670,4 +702,36 @@
             super(source);
         }
     }
+
+    static class SavedState extends BaseSavedState {
+        boolean open;
+
+        SavedState(Parcelable superState) {
+            super(superState);
+        }
+
+        private SavedState(Parcel in) {
+            super(in);
+            open = in.readInt() != 0;
+        }
+
+        @Override
+        public void writeToParcel(Parcel out, int flags) {
+            super.writeToParcel(out, flags);
+            out.writeInt(open ? 1 : 0);
+        }
+
+        public static final Parcelable.Creator<SavedState> CREATOR =
+                new Parcelable.Creator<SavedState>() {
+            @Override
+            public SavedState createFromParcel(Parcel in) {
+                return new SavedState(in);
+            }
+
+            @Override
+            public SavedState[] newArray(int size) {
+                return new SavedState[size];
+            }
+        };
+    }
 }
diff --git a/core/java/com/android/internal/widget/ToolbarWidgetWrapper.java b/core/java/com/android/internal/widget/ToolbarWidgetWrapper.java
index 5da5ae9..478c8f2 100644
--- a/core/java/com/android/internal/widget/ToolbarWidgetWrapper.java
+++ b/core/java/com/android/internal/widget/ToolbarWidgetWrapper.java
@@ -76,19 +76,26 @@
     private boolean mTitleSet;
     private CharSequence mTitle;
     private CharSequence mSubtitle;
+    private CharSequence mHomeDescription;
 
     private Window.Callback mWindowCallback;
     private boolean mMenuPrepared;
     private ActionMenuPresenter mActionMenuPresenter;
 
     private int mNavigationMode = ActionBar.NAVIGATION_MODE_STANDARD;
+    private int mDefaultNavigationContentDescription = 0;
 
     public ToolbarWidgetWrapper(Toolbar toolbar, boolean style) {
+        this(toolbar, style, R.string.action_bar_up_description);
+    }
+
+    public ToolbarWidgetWrapper(Toolbar toolbar, boolean style,
+            int defaultNavigationContentDescription) {
         mToolbar = toolbar;
 
         mTitle = toolbar.getTitle();
         mSubtitle = toolbar.getSubtitle();
-        mTitleSet = !TextUtils.isEmpty(mTitle);
+        mTitleSet = mTitle != null;
 
         if (style) {
             final TypedArray a = toolbar.getContext().obtainStyledAttributes(null,
@@ -162,12 +169,12 @@
             }
 
             a.recycle();
+        } else {
+            mDisplayOpts = detectDisplayOptions();
         }
 
-        if (TextUtils.isEmpty(mToolbar.getNavigationContentDescription())) {
-            mToolbar.setNavigationContentDescription(
-                    getContext().getResources().getText(R.string.action_bar_up_description));
-        }
+        setDefaultNavigationContentDescription(defaultNavigationContentDescription);
+        mHomeDescription = mToolbar.getNavigationContentDescription();
 
         mToolbar.setNavigationOnClickListener(new View.OnClickListener() {
             final ActionMenuItem mNavItem = new ActionMenuItem(mToolbar.getContext(),
@@ -182,6 +189,26 @@
     }
 
     @Override
+    public void setDefaultNavigationContentDescription(int defaultNavigationContentDescription) {
+        if (defaultNavigationContentDescription == mDefaultNavigationContentDescription) {
+            return;
+        }
+        mDefaultNavigationContentDescription = defaultNavigationContentDescription;
+        if (TextUtils.isEmpty(mToolbar.getNavigationContentDescription())) {
+            setNavigationContentDescription(mDefaultNavigationContentDescription);
+        }
+    }
+
+    private int detectDisplayOptions() {
+        int opts = ActionBar.DISPLAY_SHOW_TITLE | ActionBar.DISPLAY_SHOW_HOME |
+                ActionBar.DISPLAY_USE_LOGO;
+        if (mToolbar.getNavigationIcon() != null) {
+            opts |= ActionBar.DISPLAY_HOME_AS_UP;
+        }
+        return opts;
+    }
+
+    @Override
     public ViewGroup getViewGroup() {
         return mToolbar;
     }
@@ -384,6 +411,7 @@
             if ((changed & ActionBar.DISPLAY_HOME_AS_UP) != 0) {
                 if ((newOpts & ActionBar.DISPLAY_HOME_AS_UP) != 0) {
                     mToolbar.setNavigationIcon(mNavIcon);
+                    updateHomeAccessibility();
                 } else {
                     mToolbar.setNavigationIcon(null);
                 }
@@ -550,7 +578,7 @@
     @Override
     public void animateToVisibility(int visibility) {
         if (visibility == View.GONE) {
-            mToolbar.animate().translationY(mToolbar.getHeight()).alpha(0)
+            mToolbar.animate().alpha(0)
                     .setListener(new AnimatorListenerAdapter() {
                         private boolean mCanceled = false;
                         @Override
@@ -566,7 +594,7 @@
                         }
                     });
         } else if (visibility == View.VISIBLE) {
-            mToolbar.animate().translationY(0).alpha(1)
+            mToolbar.animate().alpha(1)
                     .setListener(new AnimatorListenerAdapter() {
                         @Override
                         public void onAnimationStart(Animator animation) {
@@ -591,12 +619,23 @@
 
     @Override
     public void setNavigationContentDescription(CharSequence description) {
-        mToolbar.setNavigationContentDescription(description);
+        mHomeDescription = description;
+        updateHomeAccessibility();
     }
 
     @Override
     public void setNavigationContentDescription(int resId) {
-        mToolbar.setNavigationContentDescription(resId);
+        setNavigationContentDescription(resId == 0 ? null : getContext().getString(resId));
+    }
+
+    private void updateHomeAccessibility() {
+        if ((mDisplayOpts & ActionBar.DISPLAY_HOME_AS_UP) != 0) {
+            if (TextUtils.isEmpty(mHomeDescription)) {
+                mToolbar.setNavigationContentDescription(mDefaultNavigationContentDescription);
+            } else {
+                mToolbar.setNavigationContentDescription(mHomeDescription);
+            }
+        }
     }
 
     @Override
diff --git a/core/java/com/android/server/BootReceiver.java b/core/java/com/android/server/BootReceiver.java
index 7249985..468d7f1 100644
--- a/core/java/com/android/server/BootReceiver.java
+++ b/core/java/com/android/server/BootReceiver.java
@@ -123,8 +123,15 @@
         }
 
         if (SystemProperties.getLong("ro.runtime.firstboot", 0) == 0) {
-            String now = Long.toString(System.currentTimeMillis());
-            SystemProperties.set("ro.runtime.firstboot", now);
+            if ("encrypted".equals(SystemProperties.get("ro.crypto.state"))
+                && "trigger_restart_min_framework".equals(SystemProperties.get("vold.decrypt"))){
+                // Encrypted, first boot to get PIN/pattern/password so data is tmpfs
+                // Don't set ro.runtime.firstboot so that we will do this again
+                // when data is properly mounted
+            } else {
+                String now = Long.toString(System.currentTimeMillis());
+                SystemProperties.set("ro.runtime.firstboot", now);
+            }
             if (db != null) db.addText("SYSTEM_BOOT", headers);
 
             // Negative sizes mean to take the *tail* of the file (see FileUtils.readTextFile())
diff --git a/services/backup/java/com/android/server/backup/SystemBackupAgent.java b/core/java/com/android/server/backup/SystemBackupAgent.java
similarity index 100%
rename from services/backup/java/com/android/server/backup/SystemBackupAgent.java
rename to core/java/com/android/server/backup/SystemBackupAgent.java
diff --git a/core/jni/Android.mk b/core/jni/Android.mk
index 2106d38..dbaa4b8 100644
--- a/core/jni/Android.mk
+++ b/core/jni/Android.mk
@@ -129,6 +129,7 @@
 	android/graphics/Xfermode.cpp \
 	android/graphics/YuvToJpegEncoder.cpp \
 	android/graphics/pdf/PdfDocument.cpp \
+	android/graphics/pdf/PdfEditor.cpp \
 	android/graphics/pdf/PdfRenderer.cpp \
 	android_media_AudioRecord.cpp \
 	android_media_AudioSystem.cpp \
diff --git a/core/jni/AndroidRuntime.cpp b/core/jni/AndroidRuntime.cpp
index 79b8542..1573106 100644
--- a/core/jni/AndroidRuntime.cpp
+++ b/core/jni/AndroidRuntime.cpp
@@ -126,6 +126,7 @@
 extern int register_android_graphics_SurfaceTexture(JNIEnv* env);
 extern int register_android_graphics_Xfermode(JNIEnv* env);
 extern int register_android_graphics_pdf_PdfDocument(JNIEnv* env);
+extern int register_android_graphics_pdf_PdfEditor(JNIEnv* env);
 extern int register_android_graphics_pdf_PdfRenderer(JNIEnv* env);
 extern int register_android_view_DisplayEventReceiver(JNIEnv* env);
 extern int register_android_view_RenderNode(JNIEnv* env);
@@ -270,6 +271,7 @@
 }
 
 void AndroidRuntime::setArgv0(const char* argv0) {
+    memset(mArgBlockStart, 0, mArgBlockLength);
     strlcpy(mArgBlockStart, argv0, mArgBlockLength);
 }
 
@@ -344,28 +346,6 @@
     return state && state->getStrictModePolicy() != 0;
 }
 
-
-/**
- * Add VM arguments to the to-be-executed VM
- * Stops at first non '-' argument (also stops at an argument of '--')
- * Returns the number of args consumed
- */
-int AndroidRuntime::addVmArguments(int argc, const char* const argv[])
-{
-    int i;
-
-    for (i = 0; i<argc; i++) {
-        if (argv[i][0] != '-') {
-            return i;
-        }
-        if (argv[i][1] == '-' && argv[i][2] == 0) {
-            return i+1;
-        }
-        addOption(argv[i]);
-    }
-    return i;
-}
-
 static int hasDir(const char* dir)
 {
     struct stat s;
@@ -879,9 +859,17 @@
         parseRuntimeOption("dalvik.vm.profile.max-stack-depth",
                            profileMaxStackDepth,
                            "-Xprofile-max-stack-depth:");
-    }
 
-    parseRuntimeOption("dalvik.vm.native.bridge", nativeBridgeLibrary, "-XX:NativeBridge=");
+        // Native bridge library. "0" means that native bridge is disabled.
+        property_get("ro.dalvik.vm.native.bridge", propBuf, "");
+        if (propBuf[0] == '\0') {
+            ALOGW("ro.dalvik.vm.native.bridge is not expected to be empty");
+        } else if (strcmp(propBuf, "0") != 0) {
+            snprintf(nativeBridgeLibrary, sizeof("-XX:NativeBridge=") + PROPERTY_VALUE_MAX,
+                     "-XX:NativeBridge=%s", propBuf);
+            addOption(nativeBridgeLibrary);
+        }
+    }
 
     initArgs.version = JNI_VERSION_1_4;
     initArgs.options = mOptions.editArray();
@@ -1297,6 +1285,7 @@
     REG_JNI(register_android_graphics_Xfermode),
     REG_JNI(register_android_graphics_YuvImage),
     REG_JNI(register_android_graphics_pdf_PdfDocument),
+    REG_JNI(register_android_graphics_pdf_PdfEditor),
     REG_JNI(register_android_graphics_pdf_PdfRenderer),
 
     REG_JNI(register_android_database_CursorWindow),
diff --git a/core/jni/android/graphics/BitmapFactory.cpp b/core/jni/android/graphics/BitmapFactory.cpp
index 2ce1b15..8ea28ec 100644
--- a/core/jni/android/graphics/BitmapFactory.cpp
+++ b/core/jni/android/graphics/BitmapFactory.cpp
@@ -18,6 +18,7 @@
 #include <android_runtime/AndroidRuntime.h>
 #include <androidfw/Asset.h>
 #include <androidfw/ResourceTypes.h>
+#include <cutils/compiler.h>
 #include <netinet/in.h>
 #include <stdio.h>
 #include <sys/mman.h>
@@ -87,27 +88,39 @@
     return options != NULL && env->GetBooleanField(options, gOptions_justBoundsFieldID);
 }
 
-static void scaleNinePatchChunk(android::Res_png_9patch* chunk, float scale) {
+static void scaleDivRange(int32_t* divs, int count, float scale, int maxValue) {
+    for (int i = 0; i < count; i++) {
+        divs[i] = int32_t(divs[i] * scale + 0.5f);
+        if (i > 0 && divs[i] == divs[i - 1]) {
+            divs[i]++; // avoid collisions
+        }
+    }
+
+    if (CC_UNLIKELY(divs[count - 1] > maxValue)) {
+        // if the collision avoidance above put some divs outside the bounds of the bitmap,
+        // slide outer stretchable divs inward to stay within bounds
+        int highestAvailable = maxValue;
+        for (int i = count - 1; i >= 0; i--) {
+            divs[i] = highestAvailable;
+            if (i > 0 && divs[i] <= divs[i-1]){
+                // keep shifting
+                highestAvailable = divs[i] - 1;
+            } else {
+                break;
+            }
+        }
+    }
+}
+
+static void scaleNinePatchChunk(android::Res_png_9patch* chunk, float scale,
+        int scaledWidth, int scaledHeight) {
     chunk->paddingLeft = int(chunk->paddingLeft * scale + 0.5f);
     chunk->paddingTop = int(chunk->paddingTop * scale + 0.5f);
     chunk->paddingRight = int(chunk->paddingRight * scale + 0.5f);
     chunk->paddingBottom = int(chunk->paddingBottom * scale + 0.5f);
 
-    int32_t* xDivs = chunk->getXDivs();
-    for (int i = 0; i < chunk->numXDivs; i++) {
-        xDivs[i] = int32_t(xDivs[i] * scale + 0.5f);
-        if (i > 0 && xDivs[i] == xDivs[i - 1]) {
-            xDivs[i]++;
-        }
-    }
-
-    int32_t* yDivs = chunk->getYDivs();
-    for (int i = 0; i < chunk->numYDivs; i++) {
-        yDivs[i] = int32_t(yDivs[i] * scale + 0.5f);
-        if (i > 0 && yDivs[i] == yDivs[i - 1]) {
-            yDivs[i]++;
-        }
-    }
+    scaleDivRange(chunk->getXDivs(), chunk->numXDivs, scale, scaledWidth);
+    scaleDivRange(chunk->getYDivs(), chunk->numYDivs, scale, scaledHeight);
 }
 
 static SkColorType colorTypeForScaledOutput(SkColorType colorType) {
@@ -330,7 +343,7 @@
     jbyteArray ninePatchChunk = NULL;
     if (peeker.mPatch != NULL) {
         if (willScale) {
-            scaleNinePatchChunk(peeker.mPatch, scale);
+            scaleNinePatchChunk(peeker.mPatch, scale, scaledWidth, scaledHeight);
         }
 
         size_t ninePatchArraySize = peeker.mPatch->serializedSize();
@@ -354,6 +367,9 @@
                 peeker.mOpticalInsets[0], peeker.mOpticalInsets[1], peeker.mOpticalInsets[2], peeker.mOpticalInsets[3],
                 peeker.mOutlineInsets[0], peeker.mOutlineInsets[1], peeker.mOutlineInsets[2], peeker.mOutlineInsets[3],
                 peeker.mOutlineRadius, peeker.mOutlineAlpha, scale);
+        if (ninePatchInsets == NULL) {
+            return nullObjectReturn("nine patch insets == null");
+        }
         if (javaBitmap != NULL) {
             env->SetObjectField(javaBitmap, gBitmap_ninePatchInsetsFieldID, ninePatchInsets);
         }
diff --git a/core/jni/android/graphics/FontFamily.cpp b/core/jni/android/graphics/FontFamily.cpp
index 1d465b3..bfb30b7 100644
--- a/core/jni/android/graphics/FontFamily.cpp
+++ b/core/jni/android/graphics/FontFamily.cpp
@@ -62,10 +62,26 @@
         ALOGE("addFont failed to create font %s", str.c_str());
         return false;
     }
-    FontFamily* fontFamily = (FontFamily*)familyPtr;
+    FontFamily* fontFamily = reinterpret_cast<FontFamily*>(familyPtr);
     return addSkTypeface(fontFamily, face);
 }
 
+static jboolean FontFamily_addFontWeightStyle(JNIEnv* env, jobject clazz, jlong familyPtr,
+        jstring path, jint weight, jboolean isItalic) {
+    NPE_CHECK_RETURN_ZERO(env, path);
+    ScopedUtfChars str(env, path);
+    SkTypeface* face = SkTypeface::CreateFromFile(str.c_str());
+    if (face == NULL) {
+        ALOGE("addFont failed to create font %s", str.c_str());
+        return false;
+    }
+    FontFamily* fontFamily = reinterpret_cast<FontFamily*>(familyPtr);
+    MinikinFont* minikinFont = new MinikinFontSkia(face);
+    fontFamily->addFont(minikinFont, FontStyle(weight / 100, isItalic));
+    minikinFont->Unref();
+    return true;
+}
+
 static jboolean FontFamily_addFontFromAsset(JNIEnv* env, jobject, jlong familyPtr,
         jobject jassetMgr, jstring jpath) {
     NPE_CHECK_RETURN_ZERO(env, jassetMgr);
@@ -92,17 +108,18 @@
         ALOGE("addFontFromAsset failed to create font %s", str.c_str());
         return false;
     }
-    FontFamily* fontFamily = (FontFamily*)familyPtr;
+    FontFamily* fontFamily = reinterpret_cast<FontFamily*>(familyPtr);
     return addSkTypeface(fontFamily, face);
 }
 
 ///////////////////////////////////////////////////////////////////////////////
 
 static JNINativeMethod gFontFamilyMethods[] = {
-    { "nCreateFamily",            "(Ljava/lang/String;I)J", (void*)FontFamily_create },
-    { "nUnrefFamily",             "(J)V", (void*)FontFamily_unref },
-    { "nAddFont",                 "(JLjava/lang/String;)Z", (void*)FontFamily_addFont },
-    { "nAddFontFromAsset",        "(JLandroid/content/res/AssetManager;Ljava/lang/String;)Z",
+    { "nCreateFamily",         "(Ljava/lang/String;I)J", (void*)FontFamily_create },
+    { "nUnrefFamily",          "(J)V", (void*)FontFamily_unref },
+    { "nAddFont",              "(JLjava/lang/String;)Z", (void*)FontFamily_addFont },
+    { "nAddFontWeightStyle",   "(JLjava/lang/String;IZ)Z", (void*)FontFamily_addFontWeightStyle },
+    { "nAddFontFromAsset",     "(JLandroid/content/res/AssetManager;Ljava/lang/String;)Z",
                                            (void*)FontFamily_addFontFromAsset },
 };
 
diff --git a/core/jni/android/graphics/Graphics.cpp b/core/jni/android/graphics/Graphics.cpp
index 7c41c2e..d7b75db 100644
--- a/core/jni/android/graphics/Graphics.cpp
+++ b/core/jni/android/graphics/Graphics.cpp
@@ -419,6 +419,7 @@
 {
     SkASSERT(bitmap);
     SkASSERT(bitmap->pixelRef());
+    SkASSERT(!env->ExceptionCheck());
     bool isMutable = bitmapCreateFlags & kBitmapCreateFlag_Mutable;
     bool isPremultiplied = bitmapCreateFlags & kBitmapCreateFlag_Premultiplied;
 
diff --git a/core/jni/android/graphics/MinikinSkia.cpp b/core/jni/android/graphics/MinikinSkia.cpp
index ae29014..4649b07 100644
--- a/core/jni/android/graphics/MinikinSkia.cpp
+++ b/core/jni/android/graphics/MinikinSkia.cpp
@@ -39,7 +39,7 @@
     uint16_t glyph16;
     paint.textToGlyphs(&codepoint, sizeof(codepoint), &glyph16);
     *glyph  = glyph16;
-    return !!glyph;
+    return !!glyph16;
 }
 
 static void MinikinFontSkia_SetSkiaPaint(const MinikinFont* font, SkPaint* skPaint, const MinikinPaint& paint) {
diff --git a/core/jni/android/graphics/PaintImpl.cpp b/core/jni/android/graphics/PaintImpl.cpp
index e1b539e..fac669b 100644
--- a/core/jni/android/graphics/PaintImpl.cpp
+++ b/core/jni/android/graphics/PaintImpl.cpp
@@ -27,7 +27,8 @@
 }
 
 Paint::Paint(const Paint& paint) : SkPaint(paint),
-        mLetterSpacing(0), mFontFeatureSettings(), mTextLocale(), mFontVariant(VARIANT_DEFAULT) {
+        mLetterSpacing(paint.mLetterSpacing), mFontFeatureSettings(paint.mFontFeatureSettings),
+        mTextLocale(paint.mTextLocale), mFontVariant(paint.mFontVariant) {
 }
 
 Paint::~Paint() {
diff --git a/core/jni/android/graphics/Path.cpp b/core/jni/android/graphics/Path.cpp
index 6ef1d2c..9d3e74b 100644
--- a/core/jni/android/graphics/Path.cpp
+++ b/core/jni/android/graphics/Path.cpp
@@ -435,19 +435,32 @@
         std::vector<float> lengths;
         float errorSquared = acceptableError * acceptableError;
 
-        while ((verb = pathIter.next(points)) != SkPath::kDone_Verb) {
+        while ((verb = pathIter.next(points, false)) != SkPath::kDone_Verb) {
             createVerbSegments(verb, points, segmentPoints, lengths, errorSquared);
         }
 
         if (segmentPoints.empty()) {
-            return NULL;
+            int numVerbs = path->countVerbs();
+            if (numVerbs == 1) {
+                addMove(segmentPoints, lengths, path->getPoint(0));
+            } else {
+                // Invalid or empty path. Fall back to point(0,0)
+                addMove(segmentPoints, lengths, SkPoint());
+            }
+        }
+
+        float totalLength = lengths.back();
+        if (totalLength == 0) {
+            // Lone Move instructions should still be able to animate at the same value.
+            segmentPoints.push_back(segmentPoints.back());
+            lengths.push_back(1);
+            totalLength = 1;
         }
 
         size_t numPoints = segmentPoints.size();
         size_t approximationArraySize = numPoints * 3;
 
         float* approximation = new float[approximationArraySize];
-        float totalLength = lengths.back();
 
         int approximationIndex = 0;
         for (size_t i = 0; i < numPoints; i++) {
diff --git a/core/jni/android/graphics/Shader.cpp b/core/jni/android/graphics/Shader.cpp
index fbb243a..6146fff 100644
--- a/core/jni/android/graphics/Shader.cpp
+++ b/core/jni/android/graphics/Shader.cpp
@@ -54,26 +54,20 @@
 {
     SkShader* shader = reinterpret_cast<SkShader*>(shaderHandle);
     SkSafeUnref(shader);
-    SkShader* shaderWithLM = reinterpret_cast<SkShader*>(shaderWithLMHandle);
-    SkSafeUnref(shaderWithLM);
 }
 
-static jlong Shader_setLocalMatrix(JNIEnv* env, jobject o, jlong shaderHandle,
-        jlong oldLocalMatrixShaderHandle, jlong matrixHandle)
+static void Shader_setLocalMatrix(JNIEnv* env, jobject o, jlong shaderHandle, jlong matrixHandle)
 {
-    // The old shader with local matrix is no longer needed, so unref it.
-    SkSafeUnref(reinterpret_cast<SkShader*>(oldLocalMatrixShaderHandle));
-
     SkShader* shader       = reinterpret_cast<SkShader*>(shaderHandle);
     const SkMatrix* matrix = reinterpret_cast<SkMatrix*>(matrixHandle);
     if (shader) {
-        if (NULL == matrix) {
-            matrix = &SkMatrix::I();
+        if (matrix) {
+            shader->setLocalMatrix(*matrix);
+        } else {
+            shader->resetLocalMatrix();
         }
-        SkShader* newShader = SkShader::CreateLocalMatrixShader(shader, *matrix);
-        shader = newShader;
+        shader->setGenerationID(shader->getGenerationID() + 1);
     }
-    return reinterpret_cast<jlong>(shader);
 }
 
 ///////////////////////////////////////////////////////////////////////////////////////////////
@@ -243,8 +237,8 @@
 };
 
 static JNINativeMethod gShaderMethods[] = {
-    { "nativeDestructor",        "(JJ)V",    (void*)Shader_destructor        },
-    { "nativeSetLocalMatrix",    "(JJJ)J",   (void*)Shader_setLocalMatrix    }
+    { "nativeDestructor",        "(J)V",    (void*)Shader_destructor        },
+    { "nativeSetLocalMatrix",    "(JJ)V",   (void*)Shader_setLocalMatrix    }
 };
 
 static JNINativeMethod gBitmapShaderMethods[] = {
diff --git a/core/jni/android/graphics/Typeface.cpp b/core/jni/android/graphics/Typeface.cpp
index cf4e838..2029658 100644
--- a/core/jni/android/graphics/Typeface.cpp
+++ b/core/jni/android/graphics/Typeface.cpp
@@ -41,6 +41,12 @@
     return reinterpret_cast<jlong>(face);
 }
 
+static jlong Typeface_createWeightAlias(JNIEnv* env, jobject, jlong familyHandle, jint weight) {
+    TypefaceImpl* family = reinterpret_cast<TypefaceImpl*>(familyHandle);
+    TypefaceImpl* face = TypefaceImpl_createWeightAlias(family, weight);
+    return reinterpret_cast<jlong>(face);
+}
+
 static void Typeface_unref(JNIEnv* env, jobject obj, jlong faceHandle) {
     TypefaceImpl* face = reinterpret_cast<TypefaceImpl*>(faceHandle);
     TypefaceImpl_unref(face);
@@ -65,6 +71,7 @@
 
 static JNINativeMethod gTypefaceMethods[] = {
     { "nativeCreateFromTypeface", "(JI)J", (void*)Typeface_createFromTypeface },
+    { "nativeCreateWeightAlias",  "(JI)J", (void*)Typeface_createWeightAlias },
     { "nativeUnref",              "(J)V",  (void*)Typeface_unref },
     { "nativeGetStyle",           "(J)I",  (void*)Typeface_getStyle },
     { "nativeCreateFromArray",    "([J)J",
diff --git a/core/jni/android/graphics/TypefaceImpl.cpp b/core/jni/android/graphics/TypefaceImpl.cpp
index 9ce6de1..7afbeb2 100644
--- a/core/jni/android/graphics/TypefaceImpl.cpp
+++ b/core/jni/android/graphics/TypefaceImpl.cpp
@@ -39,14 +39,17 @@
 
 namespace android {
 
-// Any weight greater than or equal to this is considered "bold" for
-// legacy API.
-static const int kBoldThreshold = 6;
-
-static FontStyle styleFromSkiaStyle(SkTypeface::Style skiaStyle) {
-    int weight = (skiaStyle & SkTypeface::kBold) != 0 ? 7 : 4;
-    bool italic = (skiaStyle & SkTypeface::kItalic) != 0;
-    return FontStyle(weight, italic);
+// Resolve the 1..9 weight based on base weight and bold flag
+static void resolveStyle(TypefaceImpl* typeface) {
+    int weight = typeface->fBaseWeight / 100;
+    if (typeface->fSkiaStyle & SkTypeface::kBold) {
+        weight += 3;
+    }
+    if (weight > 9) {
+        weight = 9;
+    }
+    bool italic = (typeface->fSkiaStyle & SkTypeface::kItalic) != 0;
+    typeface->fStyle = FontStyle(weight, italic);
 }
 
 TypefaceImpl* gDefaultTypeface = NULL;
@@ -90,7 +93,9 @@
         // default so we can make progress before that happens.
         gDefaultTypeface = new TypefaceImpl;
         gDefaultTypeface->fFontCollection = makeFontCollection();
-        gDefaultTypeface->fStyle = FontStyle();
+        gDefaultTypeface->fSkiaStyle = SkTypeface::kNormal;
+        gDefaultTypeface->fBaseWeight = 400;
+        resolveStyle(gDefaultTypeface);
     }
 }
 
@@ -109,25 +114,23 @@
     if (result != 0) {
         result->fFontCollection = resolvedFace->fFontCollection;
         result->fFontCollection->Ref();
-        result->fStyle = styleFromSkiaStyle(style);
+        result->fSkiaStyle = style;
+        result->fBaseWeight = resolvedFace->fBaseWeight;
+        resolveStyle(result);
     }
     return result;
 }
 
-static TypefaceImpl* createFromSkTypeface(SkTypeface* typeface) {
-    if (typeface == NULL) {
-        return NULL;
-    }
-    MinikinFont* minikinFont = new MinikinFontSkia(typeface);
-    std::vector<FontFamily *> typefaces;
-    FontFamily* family = new FontFamily();
-    family->addFont(minikinFont);
-    minikinFont->Unref();
-    typefaces.push_back(family);
+TypefaceImpl* TypefaceImpl_createWeightAlias(TypefaceImpl* src, int weight) {
+    TypefaceImpl* resolvedFace = TypefaceImpl_resolveDefault(src);
     TypefaceImpl* result = new TypefaceImpl;
-    result->fFontCollection = new FontCollection(typefaces);
-    family->Unref();
-    result->fStyle = FontStyle();  // TODO: improve
+    if (result != 0) {
+        result->fFontCollection = resolvedFace->fFontCollection;
+        result->fFontCollection->Ref();
+        result->fSkiaStyle = resolvedFace->fSkiaStyle;
+        result->fBaseWeight = weight;
+        resolveStyle(result);
+    }
     return result;
 }
 
@@ -141,7 +144,7 @@
     result->fFontCollection = new FontCollection(familyVec);
     if (size == 0) {
         ALOGW("createFromFamilies creating empty collection");
-        result->fStyle = FontStyle();
+        result->fSkiaStyle = SkTypeface::kNormal;
     } else {
         const FontStyle defaultStyle;
         FontFamily* firstFamily = reinterpret_cast<FontFamily*>(families[0]);
@@ -150,11 +153,13 @@
             SkTypeface* skTypeface = reinterpret_cast<MinikinFontSkia*>(mf)->GetSkTypeface();
             // TODO: probably better to query more precise style from family, will be important
             // when we open up API to access 100..900 weights
-            result->fStyle = styleFromSkiaStyle(skTypeface->style());
+            result->fSkiaStyle = skTypeface->style();
         } else {
-            result->fStyle = defaultStyle;
+            result->fSkiaStyle = SkTypeface::kNormal;
         }
     }
+    result->fBaseWeight = 400;
+    resolveStyle(result);
     return result;
 }
 
@@ -166,12 +171,7 @@
 }
 
 int TypefaceImpl_getStyle(TypefaceImpl* face) {
-    FontStyle style = face->fStyle;
-    int result = style.getItalic() ? SkTypeface::kItalic : 0;
-    if (style.getWeight() >= kBoldThreshold) {
-        result |= SkTypeface::kBold;
-    }
-    return result;
+    return face->fSkiaStyle;
 }
 
 void TypefaceImpl_setDefault(TypefaceImpl* face) {
diff --git a/core/jni/android/graphics/TypefaceImpl.h b/core/jni/android/graphics/TypefaceImpl.h
index 12b3403..d129f621 100644
--- a/core/jni/android/graphics/TypefaceImpl.h
+++ b/core/jni/android/graphics/TypefaceImpl.h
@@ -28,6 +28,13 @@
 
 struct TypefaceImpl {
     FontCollection *fFontCollection;
+
+    // style used for constructing and querying Typeface objects
+    SkTypeface::Style fSkiaStyle;
+    // base weight in CSS-style units, 100..900
+    int fBaseWeight;
+
+    // resolved style actually used for rendering
     FontStyle fStyle;
 };
 
@@ -41,6 +48,8 @@
 
 TypefaceImpl* TypefaceImpl_createFromTypeface(TypefaceImpl* src, SkTypeface::Style style);
 
+TypefaceImpl* TypefaceImpl_createWeightAlias(TypefaceImpl* src, int baseweight);
+
 // When we remove the USE_MINIKIN ifdef, probably a good idea to move the casting
 // (from jlong to FontFamily*) to the caller in Typeface.cpp.
 TypefaceImpl* TypefaceImpl_createFromFamilies(const jlong* families, size_t size);
diff --git a/core/jni/android/graphics/pdf/PdfEditor.cpp b/core/jni/android/graphics/pdf/PdfEditor.cpp
new file mode 100644
index 0000000..5f60c9e
--- /dev/null
+++ b/core/jni/android/graphics/pdf/PdfEditor.cpp
@@ -0,0 +1,161 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#include "jni.h"
+#include "JNIHelp.h"
+#include "fpdfview.h"
+#include "fpdfedit.h"
+#include "fpdfsave.h"
+
+#include <android_runtime/AndroidRuntime.h>
+#include <vector>
+#include <utils/Log.h>
+#include <unistd.h>
+#include <sys/types.h>
+#include <unistd.h>
+
+namespace android {
+
+static Mutex sLock;
+
+static int sUnmatchedInitRequestCount = 0;
+
+static void initializeLibraryIfNeeded() {
+    Mutex::Autolock _l(sLock);
+    if (sUnmatchedInitRequestCount == 0) {
+        FPDF_InitLibrary(NULL);
+    }
+    sUnmatchedInitRequestCount++;
+}
+
+static void destroyLibraryIfNeeded() {
+    Mutex::Autolock _l(sLock);
+    sUnmatchedInitRequestCount--;
+    if (sUnmatchedInitRequestCount == 0) {
+       FPDF_DestroyLibrary();
+    }
+}
+
+static int getBlock(void* param, unsigned long position, unsigned char* outBuffer,
+        unsigned long size) {
+    const int fd = reinterpret_cast<intptr_t>(param);
+    const int readCount = pread(fd, outBuffer, size, position);
+    if (readCount < 0) {
+        ALOGE("Cannot read from file descriptor. Error:%d", errno);
+        return 0;
+    }
+    return 1;
+}
+
+static jlong nativeOpen(JNIEnv* env, jclass thiz, jint fd, jlong size) {
+    initializeLibraryIfNeeded();
+
+    FPDF_FILEACCESS loader;
+    loader.m_FileLen = size;
+    loader.m_Param = reinterpret_cast<void*>(intptr_t(fd));
+    loader.m_GetBlock = &getBlock;
+
+    FPDF_DOCUMENT document = FPDF_LoadCustomDocument(&loader, NULL);
+
+    if (!document) {
+        const long error = FPDF_GetLastError();
+        jniThrowException(env, "java/io/IOException",
+                "cannot create document. Error:" + error);
+        destroyLibraryIfNeeded();
+        return -1;
+    }
+
+    return reinterpret_cast<jlong>(document);
+}
+
+static void nativeClose(JNIEnv* env, jclass thiz, jlong documentPtr) {
+    FPDF_DOCUMENT document = reinterpret_cast<FPDF_DOCUMENT>(documentPtr);
+    FPDF_CloseDocument(document);
+    destroyLibraryIfNeeded();
+}
+
+static jint nativeGetPageCount(JNIEnv* env, jclass thiz, jlong documentPtr) {
+    FPDF_DOCUMENT document = reinterpret_cast<FPDF_DOCUMENT>(documentPtr);
+    return FPDF_GetPageCount(document);
+}
+
+static jint nativeRemovePage(JNIEnv* env, jclass thiz, jlong documentPtr, jint pageIndex) {
+    FPDF_DOCUMENT document = reinterpret_cast<FPDF_DOCUMENT>(documentPtr);
+    FPDFPage_Delete(document, pageIndex);
+    return FPDF_GetPageCount(document);
+}
+
+struct PdfToFdWriter : FPDF_FILEWRITE {
+    int dstFd;
+};
+
+static bool writeAllBytes(const int fd, const void* buffer, const size_t byteCount) {
+    char* writeBuffer = static_cast<char*>(const_cast<void*>(buffer));
+    size_t remainingBytes = byteCount;
+    while (remainingBytes > 0) {
+        ssize_t writtenByteCount = write(fd, writeBuffer, remainingBytes);
+        if (writtenByteCount == -1) {
+            if (errno == EINTR) {
+                continue;
+            }
+            __android_log_print(ANDROID_LOG_ERROR, LOG_TAG,
+                    "Error writing to buffer: %d", errno);
+            return false;
+        }
+        remainingBytes -= writtenByteCount;
+        writeBuffer += writtenByteCount;
+    }
+    return true;
+}
+
+static int writeBlock(FPDF_FILEWRITE* owner, const void* buffer, unsigned long size) {
+    const PdfToFdWriter* writer = reinterpret_cast<PdfToFdWriter*>(owner);
+    const bool success = writeAllBytes(writer->dstFd, buffer, size);
+    if (success < 0) {
+        ALOGE("Cannot write to file descriptor. Error:%d", errno);
+        return 0;
+    }
+    return 1;
+}
+
+static void nativeWrite(JNIEnv* env, jclass thiz, jlong documentPtr, jint fd) {
+    FPDF_DOCUMENT document = reinterpret_cast<FPDF_DOCUMENT>(documentPtr);
+    PdfToFdWriter writer;
+    writer.dstFd = fd;
+    writer.WriteBlock = &writeBlock;
+    const bool success = FPDF_SaveAsCopy(document, &writer, FPDF_NO_INCREMENTAL);
+    if (!success) {
+        jniThrowException(env, "java/io/IOException",
+                "cannot write to fd. Error:" + errno);
+        destroyLibraryIfNeeded();
+    }
+}
+
+static JNINativeMethod gPdfEditor_Methods[] = {
+    {"nativeOpen", "(IJ)J", (void*) nativeOpen},
+    {"nativeClose", "(J)V", (void*) nativeClose},
+    {"nativeGetPageCount", "(J)I", (void*) nativeGetPageCount},
+    {"nativeRemovePage", "(JI)I", (void*) nativeRemovePage},
+    {"nativeWrite", "(JI)V", (void*) nativeWrite}
+};
+
+int register_android_graphics_pdf_PdfEditor(JNIEnv* env) {
+    return android::AndroidRuntime::registerNativeMethods(
+            env, "android/graphics/pdf/PdfEditor", gPdfEditor_Methods,
+            NELEM(gPdfEditor_Methods));
+};
+
+};
diff --git a/core/jni/android_ddm_DdmHandleNativeHeap.cpp b/core/jni/android_ddm_DdmHandleNativeHeap.cpp
index f5eaf94..9b96320 100644
--- a/core/jni/android_ddm_DdmHandleNativeHeap.cpp
+++ b/core/jni/android_ddm_DdmHandleNativeHeap.cpp
@@ -35,7 +35,15 @@
 
 extern "C" void free_malloc_leak_info(uint8_t* info);
 
+#define DDMS_HEADER_SIGNATURE 0x812345dd
+#define DDMS_VERSION 2
+
 struct Header {
+#if defined(__LP64__)
+    uint32_t signature;
+    uint16_t version;
+    uint16_t pointerSize;
+#endif
     size_t mapSize;
     size_t allocSize;
     size_t allocInfoSize;
@@ -77,6 +85,12 @@
     ALOGD("*** mapSize: %d allocSize: %d allocInfoSize: %d totalMemory: %d",
           header.mapSize, header.allocSize, header.allocInfoSize, header.totalMemory);
 
+#if defined(__LP64__)
+    header.signature = DDMS_HEADER_SIGNATURE;
+    header.version = DDMS_VERSION;
+    header.pointerSize = sizeof(void*);
+#endif
+
     jbyteArray array = env->NewByteArray(sizeof(Header) + header.mapSize + header.allocSize);
     if (array != NULL) {
         env->SetByteArrayRegion(array, 0,
diff --git a/core/jni/android_hardware_SoundTrigger.cpp b/core/jni/android_hardware_SoundTrigger.cpp
index f0d7a35..7b33bc2 100644
--- a/core/jni/android_hardware_SoundTrigger.cpp
+++ b/core/jni/android_hardware_SoundTrigger.cpp
@@ -211,7 +211,7 @@
     }
 
     jobject jAudioFormat = NULL;
-    if (event->trigger_in_data) {
+    if (event->trigger_in_data || event->capture_available) {
         jAudioFormat = env->NewObject(gAudioFormatClass,
                                     gAudioFormatCstor,
                                     audioFormatFromNative(event->audio_config.format),
diff --git a/core/jni/android_hardware_camera2_DngCreator.cpp b/core/jni/android_hardware_camera2_DngCreator.cpp
index a728455..31c7b9f 100644
--- a/core/jni/android_hardware_camera2_DngCreator.cpp
+++ b/core/jni/android_hardware_camera2_DngCreator.cpp
@@ -653,6 +653,119 @@
     return OK;
 }
 
+/**
+ * Write CFA pattern for given CFA enum into cfaOut.  cfaOut must have length >= 4.
+ * Returns OK on success, or a negative error code if the CFA enum was invalid.
+ */
+static status_t convertCFA(uint8_t cfaEnum, /*out*/uint8_t* cfaOut) {
+    camera_metadata_enum_android_sensor_info_color_filter_arrangement_t cfa =
+            static_cast<camera_metadata_enum_android_sensor_info_color_filter_arrangement_t>(
+            cfaEnum);
+    switch(cfa) {
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB: {
+            cfaOut[0] = 0;
+            cfaOut[1] = 1;
+            cfaOut[2] = 1;
+            cfaOut[3] = 2;
+            break;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG: {
+            cfaOut[0] = 1;
+            cfaOut[1] = 0;
+            cfaOut[2] = 2;
+            cfaOut[3] = 1;
+            break;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG: {
+            cfaOut[0] = 1;
+            cfaOut[1] = 2;
+            cfaOut[2] = 0;
+            cfaOut[3] = 1;
+            break;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR: {
+            cfaOut[0] = 2;
+            cfaOut[1] = 1;
+            cfaOut[2] = 1;
+            cfaOut[3] = 0;
+            break;
+        }
+        default: {
+            return BAD_VALUE;
+        }
+    }
+    return OK;
+}
+
+/**
+ * Convert the CFA layout enum to an OpcodeListBuilder::CfaLayout enum, defaults to
+ * RGGB for an unknown enum.
+ */
+static OpcodeListBuilder::CfaLayout convertCFAEnumToOpcodeLayout(uint8_t cfaEnum) {
+    camera_metadata_enum_android_sensor_info_color_filter_arrangement_t cfa =
+            static_cast<camera_metadata_enum_android_sensor_info_color_filter_arrangement_t>(
+            cfaEnum);
+    switch(cfa) {
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB: {
+            return OpcodeListBuilder::CFA_RGGB;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG: {
+            return OpcodeListBuilder::CFA_GRBG;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG: {
+            return OpcodeListBuilder::CFA_GBRG;
+        }
+        case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR: {
+            return OpcodeListBuilder::CFA_BGGR;
+        }
+        default: {
+            return OpcodeListBuilder::CFA_RGGB;
+        }
+    }
+}
+
+/**
+ * For each color plane, find the corresponding noise profile coefficients given in the
+ * per-channel noise profile.  If multiple channels in the CFA correspond to a color in the color
+ * plane, this method takes the pair of noise profile coefficients with the higher S coefficient.
+ *
+ * perChannelNoiseProfile - numChannels * 2 noise profile coefficients.
+ * cfa - numChannels color channels corresponding to each of the per-channel noise profile
+ *       coefficients.
+ * numChannels - the number of noise profile coefficient pairs and color channels given in
+ *       the perChannelNoiseProfile and cfa arguments, respectively.
+ * planeColors - the color planes in the noise profile output.
+ * numPlanes - the number of planes in planeColors and pairs of coefficients in noiseProfile.
+ * noiseProfile - 2 * numPlanes doubles containing numPlanes pairs of noise profile coefficients.
+ *
+ * returns OK, or a negative error code on failure.
+ */
+static status_t generateNoiseProfile(const double* perChannelNoiseProfile, uint8_t* cfa,
+        size_t numChannels, const uint8_t* planeColors, size_t numPlanes,
+        /*out*/double* noiseProfile) {
+
+    for (size_t p = 0; p < numPlanes; ++p) {
+        size_t S = p * 2;
+        size_t O = p * 2 + 1;
+
+        noiseProfile[S] = 0;
+        noiseProfile[O] = 0;
+        bool uninitialized = true;
+        for (size_t c = 0; c < numChannels; ++c) {
+            if (cfa[c] == planeColors[p] && perChannelNoiseProfile[c * 2] > noiseProfile[S]) {
+                noiseProfile[S] = perChannelNoiseProfile[c * 2];
+                noiseProfile[O] = perChannelNoiseProfile[c * 2 + 1];
+                uninitialized = false;
+            }
+        }
+        if (uninitialized) {
+            ALOGE("%s: No valid NoiseProfile coefficients for color plane %u", __FUNCTION__, p);
+            return BAD_VALUE;
+        }
+    }
+    return OK;
+}
+
 // ----------------------------------------------------------------------------
 extern "C" {
 
@@ -745,6 +858,8 @@
     uint32_t imageHeight = 0;
 
     OpcodeListBuilder::CfaLayout opcodeCfaLayout = OpcodeListBuilder::CFA_RGGB;
+    uint8_t cfaPlaneColor[3] = {0, 1, 2};
+    uint8_t cfaEnum = -1;
 
     // TODO: Greensplit.
     // TODO: Add remaining non-essential tags
@@ -841,49 +956,23 @@
         camera_metadata_entry entry =
                         characteristics.find(ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT);
         BAIL_IF_EMPTY(entry, env, TAG_CFAPATTERN, writer);
-        camera_metadata_enum_android_sensor_info_color_filter_arrangement_t cfa =
-                static_cast<camera_metadata_enum_android_sensor_info_color_filter_arrangement_t>(
-                entry.data.u8[0]);
-        switch(cfa) {
-            case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB: {
-                uint8_t cfa[4] = {0, 1, 1, 2};
-                BAIL_IF_INVALID(writer->addEntry(TAG_CFAPATTERN, 4, cfa, TIFF_IFD_0),
-                                                env, TAG_CFAPATTERN, writer);
-                opcodeCfaLayout = OpcodeListBuilder::CFA_RGGB;
-                break;
-            }
-            case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG: {
-                uint8_t cfa[4] = {1, 0, 2, 1};
-                BAIL_IF_INVALID(writer->addEntry(TAG_CFAPATTERN, 4, cfa, TIFF_IFD_0),
-                                                env, TAG_CFAPATTERN, writer);
-                opcodeCfaLayout = OpcodeListBuilder::CFA_GRBG;
-                break;
-            }
-            case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG: {
-                uint8_t cfa[4] = {1, 2, 0, 1};
-                BAIL_IF_INVALID(writer->addEntry(TAG_CFAPATTERN, 4, cfa, TIFF_IFD_0),
-                                                env, TAG_CFAPATTERN, writer);
-                opcodeCfaLayout = OpcodeListBuilder::CFA_GBRG;
-                break;
-            }
-            case ANDROID_SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR: {
-                uint8_t cfa[4] = {2, 1, 1, 0};
-                BAIL_IF_INVALID(writer->addEntry(TAG_CFAPATTERN, 4, cfa, TIFF_IFD_0),
-                                env, TAG_CFAPATTERN, writer);
-                opcodeCfaLayout = OpcodeListBuilder::CFA_BGGR;
-                break;
-            }
-            default: {
-                jniThrowExceptionFmt(env, "java/lang/IllegalStateException",
-                            "Invalid metadata for tag %d", TAG_CFAPATTERN);
-                return;
-            }
+
+        const int cfaLength = 4;
+        cfaEnum = entry.data.u8[0];
+        uint8_t cfa[cfaLength];
+        if ((err = convertCFA(cfaEnum, /*out*/cfa)) != OK) {
+            jniThrowExceptionFmt(env, "java/lang/IllegalStateException",
+                        "Invalid metadata for tag %d", TAG_CFAPATTERN);
         }
+
+        BAIL_IF_INVALID(writer->addEntry(TAG_CFAPATTERN, cfaLength, cfa, TIFF_IFD_0), env,
+                TAG_CFAPATTERN, writer);
+
+        opcodeCfaLayout = convertCFAEnumToOpcodeLayout(cfaEnum);
     }
 
     {
         // Set CFA plane color
-        uint8_t cfaPlaneColor[3] = {0, 1, 2};
         BAIL_IF_INVALID(writer->addEntry(TAG_CFAPLANECOLOR, 3, cfaPlaneColor, TIFF_IFD_0),
                 env, TAG_CFAPLANECOLOR, writer);
     }
@@ -1298,10 +1387,33 @@
         camera_metadata_entry entry =
             results.find(ANDROID_SENSOR_NOISE_PROFILE);
 
+        const status_t numPlaneColors = 3;
+        const status_t numCfaChannels = 4;
+
+        uint8_t cfaOut[numCfaChannels];
+        if ((err = convertCFA(cfaEnum, /*out*/cfaOut)) != OK) {
+            jniThrowException(env, "java/lang/IllegalArgumentException",
+                    "Invalid CFA from camera characteristics");
+            return;
+        }
+
+        double noiseProfile[numPlaneColors * 2];
+
         if (entry.count > 0) {
-            BAIL_IF_INVALID(writer->addEntry(TAG_NOISEPROFILE, entry.count,
-                    entry.data.d, TIFF_IFD_0), env,
-                    TAG_NOISEPROFILE, writer);
+            if (entry.count != numCfaChannels * 2) {
+                ALOGW("%s: Invalid entry count %u for noise profile returned in characteristics,"
+                        " no noise profile tag written...", __FUNCTION__, entry.count);
+            } else {
+                if ((err = generateNoiseProfile(entry.data.d, cfaOut, numCfaChannels,
+                        cfaPlaneColor, numPlaneColors, /*out*/ noiseProfile)) == OK) {
+
+                    BAIL_IF_INVALID(writer->addEntry(TAG_NOISEPROFILE, numPlaneColors * 2,
+                            noiseProfile, TIFF_IFD_0), env, TAG_NOISEPROFILE, writer);
+                } else {
+                    ALOGW("%s: Error converting coefficients for noise profile, no noise profile"
+                            " tag written...", __FUNCTION__);
+                }
+            }
         } else {
             ALOGW("%s: No noise profile found in result metadata.  Image quality may be reduced.",
                     __FUNCTION__);
diff --git a/core/jni/android_net_NetUtils.cpp b/core/jni/android_net_NetUtils.cpp
index 32cf286..8b9f574 100644
--- a/core/jni/android_net_NetUtils.cpp
+++ b/core/jni/android_net_NetUtils.cpp
@@ -69,9 +69,8 @@
  */
 static struct fieldIds {
     jmethodID clear;
-    jmethodID setInterfaceName;
-    jmethodID addLinkAddress;
-    jmethodID addGateway;
+    jmethodID setIpAddress;
+    jmethodID setGateway;
     jmethodID addDns;
     jmethodID setDomains;
     jmethodID setServerAddress;
@@ -130,21 +129,16 @@
     if (result == 0) {
         env->CallVoidMethod(dhcpResults, dhcpResultsFieldIds.clear);
 
-        // set mIfaceName
-        // dhcpResults->setInterfaceName(ifname)
-        env->CallVoidMethod(dhcpResults, dhcpResultsFieldIds.setInterfaceName, ifname);
-
         // set the linkAddress
         // dhcpResults->addLinkAddress(inetAddress, prefixLength)
-        result = env->CallBooleanMethod(dhcpResults, dhcpResultsFieldIds.addLinkAddress,
+        result = env->CallBooleanMethod(dhcpResults, dhcpResultsFieldIds.setIpAddress,
                 env->NewStringUTF(ipaddr), prefixLength);
     }
 
     if (result == 0) {
         // set the gateway
-        // dhcpResults->addGateway(gateway)
         result = env->CallBooleanMethod(dhcpResults,
-                dhcpResultsFieldIds.addGateway, env->NewStringUTF(gateway));
+                dhcpResultsFieldIds.setGateway, env->NewStringUTF(gateway));
     }
 
     if (result == 0) {
@@ -242,10 +236,10 @@
     return (jboolean) !setNetworkForResolv(netId);
 }
 
-static jboolean android_net_utils_bindSocketToNetwork(JNIEnv *env, jobject thiz, jint socket,
+static jint android_net_utils_bindSocketToNetwork(JNIEnv *env, jobject thiz, jint socket,
         jint netId)
 {
-    return (jboolean) !setNetworkForSocket(netId, socket);
+    return setNetworkForSocket(netId, socket);
 }
 
 static jboolean android_net_utils_protectFromVpn(JNIEnv *env, jobject thiz, jint socket)
@@ -269,7 +263,7 @@
     { "bindProcessToNetwork", "(I)Z", (void*) android_net_utils_bindProcessToNetwork },
     { "getNetworkBoundToProcess", "()I", (void*) android_net_utils_getNetworkBoundToProcess },
     { "bindProcessToNetworkForHostResolution", "(I)Z", (void*) android_net_utils_bindProcessToNetworkForHostResolution },
-    { "bindSocketToNetwork", "(II)Z", (void*) android_net_utils_bindSocketToNetwork },
+    { "bindSocketToNetwork", "(II)I", (void*) android_net_utils_bindSocketToNetwork },
     { "protectFromVpn", "(I)Z", (void*)android_net_utils_protectFromVpn },
 };
 
@@ -279,12 +273,10 @@
     LOG_FATAL_IF(dhcpResultsClass == NULL, "Unable to find class android/net/DhcpResults");
     dhcpResultsFieldIds.clear =
             env->GetMethodID(dhcpResultsClass, "clear", "()V");
-    dhcpResultsFieldIds.setInterfaceName =
-            env->GetMethodID(dhcpResultsClass, "setInterfaceName", "(Ljava/lang/String;)V");
-    dhcpResultsFieldIds.addLinkAddress =
-            env->GetMethodID(dhcpResultsClass, "addLinkAddress", "(Ljava/lang/String;I)Z");
-    dhcpResultsFieldIds.addGateway =
-            env->GetMethodID(dhcpResultsClass, "addGateway", "(Ljava/lang/String;)Z");
+    dhcpResultsFieldIds.setIpAddress =
+            env->GetMethodID(dhcpResultsClass, "setIpAddress", "(Ljava/lang/String;I)Z");
+    dhcpResultsFieldIds.setGateway =
+            env->GetMethodID(dhcpResultsClass, "setGateway", "(Ljava/lang/String;)Z");
     dhcpResultsFieldIds.addDns =
             env->GetMethodID(dhcpResultsClass, "addDns", "(Ljava/lang/String;)Z");
     dhcpResultsFieldIds.setDomains =
diff --git a/core/jni/android_util_AssetManager.cpp b/core/jni/android_util_AssetManager.cpp
index 396f3ec..4859ee6 100644
--- a/core/jni/android_util_AssetManager.cpp
+++ b/core/jni/android_util_AssetManager.cpp
@@ -2051,6 +2051,8 @@
         (void*) android_content_AssetManager_dumpTheme },
     { "applyStyle","(JIIJ[I[I[I)Z",
         (void*) android_content_AssetManager_applyStyle },
+    { "resolveAttrs","(JII[I[I[I[I)Z",
+        (void*) android_content_AssetManager_resolveAttrs },
     { "retrieveAttributes","(J[I[I[I)Z",
         (void*) android_content_AssetManager_retrieveAttributes },
     { "getArraySize","(I)I",
diff --git a/core/jni/android_view_GLES20Canvas.cpp b/core/jni/android_view_GLES20Canvas.cpp
index afcfaf6..2e2b23f 100644
--- a/core/jni/android_view_GLES20Canvas.cpp
+++ b/core/jni/android_view_GLES20Canvas.cpp
@@ -104,6 +104,12 @@
     renderer->setHighContrastText(highContrastText);
 }
 
+static void android_view_GLES20Canvas_insertReorderBarrier(JNIEnv* env, jobject clazz,
+        jlong rendererPtr, jboolean reorderEnable) {
+    DisplayListRenderer* renderer = reinterpret_cast<DisplayListRenderer*>(rendererPtr);
+    renderer->insertReorderBarrier(reorderEnable);
+}
+
 static int android_view_GLES20Canvas_prepare(JNIEnv* env, jobject clazz,
         jlong rendererPtr, jboolean opaque) {
     DisplayListRenderer* renderer = reinterpret_cast<DisplayListRenderer*>(rendererPtr);
@@ -474,6 +480,20 @@
     renderer->drawRoundRect(left, top, right, bottom, rx, ry, paint);
 }
 
+static void android_view_GLES20Canvas_drawRoundRectProps(JNIEnv* env, jobject clazz,
+        jlong rendererPtr, jlong leftPropPtr, jlong topPropPtr, jlong rightPropPtr,
+        jlong bottomPropPtr, jlong rxPropPtr, jlong ryPropPtr, jlong paintPropPtr) {
+    DisplayListRenderer* renderer = reinterpret_cast<DisplayListRenderer*>(rendererPtr);
+    CanvasPropertyPrimitive* leftProp = reinterpret_cast<CanvasPropertyPrimitive*>(leftPropPtr);
+    CanvasPropertyPrimitive* topProp = reinterpret_cast<CanvasPropertyPrimitive*>(topPropPtr);
+    CanvasPropertyPrimitive* rightProp = reinterpret_cast<CanvasPropertyPrimitive*>(rightPropPtr);
+    CanvasPropertyPrimitive* bottomProp = reinterpret_cast<CanvasPropertyPrimitive*>(bottomPropPtr);
+    CanvasPropertyPrimitive* rxProp = reinterpret_cast<CanvasPropertyPrimitive*>(rxPropPtr);
+    CanvasPropertyPrimitive* ryProp = reinterpret_cast<CanvasPropertyPrimitive*>(ryPropPtr);
+    CanvasPropertyPaint* paintProp = reinterpret_cast<CanvasPropertyPaint*>(paintPropPtr);
+    renderer->drawRoundRect(leftProp, topProp, rightProp, bottomProp, rxProp, ryProp, paintProp);
+}
+
 static void android_view_GLES20Canvas_drawCircle(JNIEnv* env, jobject clazz,
         jlong rendererPtr, jfloat x, jfloat y, jfloat radius, jlong paintPtr) {
     DisplayListRenderer* renderer = reinterpret_cast<DisplayListRenderer*>(rendererPtr);
@@ -859,6 +879,7 @@
     { "nDestroyRenderer",   "(J)V",            (void*) android_view_GLES20Canvas_destroyRenderer },
     { "nSetViewport",       "(JII)V",          (void*) android_view_GLES20Canvas_setViewport },
     { "nSetHighContrastText","(JZ)V",          (void*) android_view_GLES20Canvas_setHighContrastText },
+    { "nInsertReorderBarrier","(JZ)V",         (void*) android_view_GLES20Canvas_insertReorderBarrier },
     { "nPrepare",           "(JZ)I",           (void*) android_view_GLES20Canvas_prepare },
     { "nPrepareDirty",      "(JIIIIZ)I",       (void*) android_view_GLES20Canvas_prepareDirty },
     { "nFinish",            "(J)V",            (void*) android_view_GLES20Canvas_finish },
@@ -905,6 +926,7 @@
     { "nDrawRect",          "(JFFFFJ)V",       (void*) android_view_GLES20Canvas_drawRect },
     { "nDrawRects",         "(JJJ)V",          (void*) android_view_GLES20Canvas_drawRegionAsRects },
     { "nDrawRoundRect",     "(JFFFFFFJ)V",     (void*) android_view_GLES20Canvas_drawRoundRect },
+    { "nDrawRoundRect",     "(JJJJJJJJ)V",     (void*) android_view_GLES20Canvas_drawRoundRectProps },
     { "nDrawCircle",        "(JFFFJ)V",        (void*) android_view_GLES20Canvas_drawCircle },
     { "nDrawCircle",        "(JJJJJ)V",        (void*) android_view_GLES20Canvas_drawCircleProps },
     { "nDrawOval",          "(JFFFFJ)V",       (void*) android_view_GLES20Canvas_drawOval },
diff --git a/core/jni/android_view_RenderNode.cpp b/core/jni/android_view_RenderNode.cpp
index 1e9d722..050037e 100644
--- a/core/jni/android_view_RenderNode.cpp
+++ b/core/jni/android_view_RenderNode.cpp
@@ -173,6 +173,12 @@
     return true;
 }
 
+static jboolean android_view_RenderNode_hasShadow(JNIEnv* env,
+        jobject clazz, jlong renderNodePtr) {
+    RenderNode* renderNode = reinterpret_cast<RenderNode*>(renderNodePtr);
+    return renderNode->stagingProperties().hasShadow();
+}
+
 static jboolean android_view_RenderNode_setClipToOutline(JNIEnv* env,
         jobject clazz, jlong renderNodePtr, jboolean clipToOutline) {
     RenderNode* renderNode = reinterpret_cast<RenderNode*>(renderNodePtr);
@@ -455,6 +461,12 @@
     renderNode->addAnimator(animator);
 }
 
+static void android_view_RenderNode_endAllAnimators(JNIEnv* env, jobject clazz,
+        jlong renderNodePtr) {
+    RenderNode* renderNode = reinterpret_cast<RenderNode*>(renderNodePtr);
+    renderNode->animators().endAllStagingAnimators();
+}
+
 #endif // USE_OPENGL_RENDERER
 
 // ----------------------------------------------------------------------------
@@ -485,6 +497,7 @@
     { "nSetOutlineConvexPath", "(JJF)Z", (void*) android_view_RenderNode_setOutlineConvexPath },
     { "nSetOutlineEmpty",      "(J)Z",   (void*) android_view_RenderNode_setOutlineEmpty },
     { "nSetOutlineNone",       "(J)Z",   (void*) android_view_RenderNode_setOutlineNone },
+    { "nHasShadow",            "(J)Z",   (void*) android_view_RenderNode_hasShadow },
     { "nSetClipToOutline",     "(JZ)Z",  (void*) android_view_RenderNode_setClipToOutline },
     { "nSetRevealClip",        "(JZFFF)Z", (void*) android_view_RenderNode_setRevealClip },
 
@@ -534,6 +547,7 @@
     { "nGetPivotY",                "(J)F",  (void*) android_view_RenderNode_getPivotY },
 
     { "nAddAnimator",              "(JJ)V", (void*) android_view_RenderNode_addAnimator },
+    { "nEndAllAnimators",          "(J)V", (void*) android_view_RenderNode_endAllAnimators },
 #endif
 };
 
diff --git a/core/jni/android_view_RenderNodeAnimator.cpp b/core/jni/android_view_RenderNodeAnimator.cpp
index 767534f..84b7913 100644
--- a/core/jni/android_view_RenderNodeAnimator.cpp
+++ b/core/jni/android_view_RenderNodeAnimator.cpp
@@ -51,28 +51,36 @@
     // cyclic-references-of-doom. If you think "I know, just use NewWeakGlobalRef!"
     // then you end up with basically a PhantomReference, which is totally not
     // what we want.
-    AnimationListenerBridge(JNIEnv* env, jobject weakThis) {
-        mWeakThis = env->NewGlobalRef(weakThis);
+    AnimationListenerBridge(JNIEnv* env, jobject finishListener) {
+        mFinishListener = env->NewGlobalRef(finishListener);
         env->GetJavaVM(&mJvm);
     }
 
     virtual ~AnimationListenerBridge() {
-        JNIEnv* env = getEnv(mJvm);
-        env->DeleteGlobalRef(mWeakThis);
-        mWeakThis = NULL;
+        if (mFinishListener) {
+            onAnimationFinished(NULL);
+        }
     }
 
     virtual void onAnimationFinished(BaseRenderNodeAnimator*) {
+        LOG_ALWAYS_FATAL_IF(!mFinishListener, "Finished listener twice?");
         JNIEnv* env = getEnv(mJvm);
         env->CallStaticVoidMethod(
                 gRenderNodeAnimatorClassInfo.clazz,
                 gRenderNodeAnimatorClassInfo.callOnFinished,
-                mWeakThis);
+                mFinishListener);
+        releaseJavaObject();
     }
 
 private:
+    void releaseJavaObject() {
+        JNIEnv* env = getEnv(mJvm);
+        env->DeleteGlobalRef(mFinishListener);
+        mFinishListener = NULL;
+    }
+
     JavaVM* mJvm;
-    jobject mWeakThis;
+    jobject mFinishListener;
 };
 
 static inline RenderPropertyAnimator::RenderProperty toRenderProperty(jint property) {
@@ -88,38 +96,33 @@
     return static_cast<CanvasPropertyPaintAnimator::PaintField>(field);
 }
 
-static jlong createAnimator(JNIEnv* env, jobject clazz, jobject weakThis,
+static jlong createAnimator(JNIEnv* env, jobject clazz,
         jint propertyRaw, jfloat finalValue) {
     RenderPropertyAnimator::RenderProperty property = toRenderProperty(propertyRaw);
-
     BaseRenderNodeAnimator* animator = new RenderPropertyAnimator(property, finalValue);
-    animator->setListener(new AnimationListenerBridge(env, weakThis));
     return reinterpret_cast<jlong>( animator );
 }
 
 static jlong createCanvasPropertyFloatAnimator(JNIEnv* env, jobject clazz,
-        jobject weakThis, jlong canvasPropertyPtr, jfloat finalValue) {
+        jlong canvasPropertyPtr, jfloat finalValue) {
     CanvasPropertyPrimitive* canvasProperty = reinterpret_cast<CanvasPropertyPrimitive*>(canvasPropertyPtr);
     BaseRenderNodeAnimator* animator = new CanvasPropertyPrimitiveAnimator(canvasProperty, finalValue);
-    animator->setListener(new AnimationListenerBridge(env, weakThis));
     return reinterpret_cast<jlong>( animator );
 }
 
 static jlong createCanvasPropertyPaintAnimator(JNIEnv* env, jobject clazz,
-        jobject weakThis, jlong canvasPropertyPtr, jint paintFieldRaw,
+        jlong canvasPropertyPtr, jint paintFieldRaw,
         jfloat finalValue) {
     CanvasPropertyPaint* canvasProperty = reinterpret_cast<CanvasPropertyPaint*>(canvasPropertyPtr);
     CanvasPropertyPaintAnimator::PaintField paintField = toPaintField(paintFieldRaw);
     BaseRenderNodeAnimator* animator = new CanvasPropertyPaintAnimator(
             canvasProperty, paintField, finalValue);
-    animator->setListener(new AnimationListenerBridge(env, weakThis));
     return reinterpret_cast<jlong>( animator );
 }
 
-static jlong createRevealAnimator(JNIEnv* env, jobject clazz, jobject weakThis,
+static jlong createRevealAnimator(JNIEnv* env, jobject clazz,
         jint centerX, jint centerY, jfloat startRadius, jfloat endRadius) {
     BaseRenderNodeAnimator* animator = new RevealAnimator(centerX, centerY, startRadius, endRadius);
-    animator->setListener(new AnimationListenerBridge(env, weakThis));
     return reinterpret_cast<jlong>( animator );
 }
 
@@ -156,8 +159,16 @@
     animator->setInterpolator(interpolator);
 }
 
-static void start(JNIEnv* env, jobject clazz, jlong animatorPtr) {
+static void setAllowRunningAsync(JNIEnv* env, jobject clazz, jlong animatorPtr, jboolean mayRunAsync) {
     BaseRenderNodeAnimator* animator = reinterpret_cast<BaseRenderNodeAnimator*>(animatorPtr);
+    animator->setAllowRunningAsync(mayRunAsync);
+}
+
+static void start(JNIEnv* env, jobject clazz, jlong animatorPtr, jobject finishListener) {
+    BaseRenderNodeAnimator* animator = reinterpret_cast<BaseRenderNodeAnimator*>(animatorPtr);
+    if (finishListener) {
+        animator->setListener(new AnimationListenerBridge(env, finishListener));
+    }
     animator->start();
 }
 
@@ -176,17 +187,17 @@
 
 static JNINativeMethod gMethods[] = {
 #ifdef USE_OPENGL_RENDERER
-    { "nCreateAnimator", "(Ljava/lang/ref/WeakReference;IF)J", (void*) createAnimator },
-    { "nCreateCanvasPropertyFloatAnimator", "(Ljava/lang/ref/WeakReference;JF)J", (void*) createCanvasPropertyFloatAnimator },
-    { "nCreateCanvasPropertyPaintAnimator", "(Ljava/lang/ref/WeakReference;JIF)J", (void*) createCanvasPropertyPaintAnimator },
-    { "nCreateRevealAnimator", "(Ljava/lang/ref/WeakReference;IIFF)J", (void*) createRevealAnimator },
+    { "nCreateAnimator", "(IF)J", (void*) createAnimator },
+    { "nCreateCanvasPropertyFloatAnimator", "(JF)J", (void*) createCanvasPropertyFloatAnimator },
+    { "nCreateCanvasPropertyPaintAnimator", "(JIF)J", (void*) createCanvasPropertyPaintAnimator },
+    { "nCreateRevealAnimator", "(IIFF)J", (void*) createRevealAnimator },
     { "nSetStartValue", "(JF)V", (void*) setStartValue },
     { "nSetDuration", "(JJ)V", (void*) setDuration },
     { "nGetDuration", "(J)J", (void*) getDuration },
     { "nSetStartDelay", "(JJ)V", (void*) setStartDelay },
-    { "nGetStartDelay", "(J)J", (void*) getStartDelay },
     { "nSetInterpolator", "(JJ)V", (void*) setInterpolator },
-    { "nStart", "(J)V", (void*) start },
+    { "nSetAllowRunningAsync", "(JZ)V", (void*) setAllowRunningAsync },
+    { "nStart", "(JLandroid/view/RenderNodeAnimator;)V", (void*) start },
     { "nEnd", "(J)V", (void*) end },
 #endif
 };
@@ -204,7 +215,7 @@
     gRenderNodeAnimatorClassInfo.clazz = jclass(env->NewGlobalRef(gRenderNodeAnimatorClassInfo.clazz));
 
     GET_STATIC_METHOD_ID(gRenderNodeAnimatorClassInfo.callOnFinished, gRenderNodeAnimatorClassInfo.clazz,
-            "callOnFinished", "(Ljava/lang/ref/WeakReference;)V");
+            "callOnFinished", "(Landroid/view/RenderNodeAnimator;)V");
 
     return AndroidRuntime::registerNativeMethods(env, kClassPathName, gMethods, NELEM(gMethods));
 }
diff --git a/core/jni/android_view_SurfaceControl.cpp b/core/jni/android_view_SurfaceControl.cpp
index 3fb084a..06c22ae 100644
--- a/core/jni/android_view_SurfaceControl.cpp
+++ b/core/jni/android_view_SurfaceControl.cpp
@@ -117,7 +117,8 @@
 
 static jobject nativeScreenshotBitmap(JNIEnv* env, jclass clazz,
         jobject displayTokenObj, jobject sourceCropObj, jint width, jint height,
-        jint minLayer, jint maxLayer, bool allLayers, bool useIdentityTransform) {
+        jint minLayer, jint maxLayer, bool allLayers, bool useIdentityTransform,
+        int rotation) {
     sp<IBinder> displayToken = ibinderForJavaObject(env, displayTokenObj);
     if (displayToken == NULL) {
         return NULL;
@@ -131,17 +132,13 @@
 
     SkAutoTDelete<ScreenshotClient> screenshot(new ScreenshotClient());
     status_t res;
-    if (width > 0 && height > 0) {
-        if (allLayers) {
-            res = screenshot->update(displayToken, sourceCrop, width, height,
-                    useIdentityTransform);
-        } else {
-            res = screenshot->update(displayToken, sourceCrop, width, height,
-                    minLayer, maxLayer, useIdentityTransform);
-        }
-    } else {
-        res = screenshot->update(displayToken, sourceCrop, useIdentityTransform);
+    if (allLayers) {
+        minLayer = 0;
+        maxLayer = -1UL;
     }
+
+    res = screenshot->update(displayToken, sourceCrop, width, height,
+        minLayer, maxLayer, useIdentityTransform, static_cast<uint32_t>(rotation));
     if (res != NO_ERROR) {
         return NULL;
     }
@@ -180,7 +177,8 @@
         // takes ownership of ScreenshotClient
         SkMallocPixelRef* pixels = SkMallocPixelRef::NewWithProc(screenshotInfo,
                 (size_t) rowBytes, NULL, (void*) screenshot->getPixels(), &DeleteScreenshot,
-                (void*) (screenshot.detach()));
+                (void*) (screenshot.get()));
+        screenshot.detach();
         pixels->setImmutable();
         bitmap->setPixelRef(pixels)->unref();
         bitmap->lockPixels();
@@ -587,7 +585,7 @@
             (void*)nativeRelease },
     {"nativeDestroy", "(J)V",
             (void*)nativeDestroy },
-    {"nativeScreenshot", "(Landroid/os/IBinder;Landroid/graphics/Rect;IIIIZZ)Landroid/graphics/Bitmap;",
+    {"nativeScreenshot", "(Landroid/os/IBinder;Landroid/graphics/Rect;IIIIZZI)Landroid/graphics/Bitmap;",
             (void*)nativeScreenshotBitmap },
     {"nativeScreenshot", "(Landroid/os/IBinder;Landroid/view/Surface;Landroid/graphics/Rect;IIIIZZ)V",
             (void*)nativeScreenshot },
diff --git a/core/jni/android_view_ThreadedRenderer.cpp b/core/jni/android_view_ThreadedRenderer.cpp
index d183d8e..a8edb77 100644
--- a/core/jni/android_view_ThreadedRenderer.cpp
+++ b/core/jni/android_view_ThreadedRenderer.cpp
@@ -33,6 +33,8 @@
 #include "android_view_GraphicBuffer.h"
 
 #include <Animator.h>
+#include <AnimationContext.h>
+#include <IContextFactory.h>
 #include <RenderNode.h>
 #include <renderthread/CanvasContext.h>
 #include <renderthread/RenderProxy.h>
@@ -103,7 +105,7 @@
     std::string mMessage;
 };
 
-class RootRenderNode : public RenderNode, AnimationHook, ErrorHandler {
+class RootRenderNode : public RenderNode, ErrorHandler {
 public:
     RootRenderNode(JNIEnv* env) : RenderNode() {
         mLooper = Looper::getForThread();
@@ -114,34 +116,94 @@
 
     virtual ~RootRenderNode() {}
 
-    virtual void callOnFinished(BaseRenderNodeAnimator* animator, AnimationListener* listener) {
-        OnFinishedEvent event(animator, listener);
-        mOnFinishedEvents.push_back(event);
-    }
-
     virtual void onError(const std::string& message) {
         mLooper->sendMessage(new RenderingException(mVm, message), 0);
     }
 
     virtual void prepareTree(TreeInfo& info) {
-        info.animationHook = this;
         info.errorHandler = this;
         RenderNode::prepareTree(info);
-        info.animationHook = NULL;
         info.errorHandler = NULL;
+    }
 
-        // post all the finished stuff
-        if (mOnFinishedEvents.size()) {
-            sp<InvokeAnimationListeners> message
-                    = new InvokeAnimationListeners(mOnFinishedEvents);
-            mLooper->sendMessage(message, 0);
+    void sendMessage(const sp<MessageHandler>& handler) {
+        mLooper->sendMessage(handler, 0);
+    }
+
+    void attachAnimatingNode(RenderNode* animatingNode) {
+        mPendingAnimatingRenderNodes.push_back(animatingNode);
+    }
+
+    void doAttachAnimatingNodes(AnimationContext* context) {
+        for (size_t i = 0; i < mPendingAnimatingRenderNodes.size(); i++) {
+            RenderNode* node = mPendingAnimatingRenderNodes[i].get();
+            context->addAnimatingRenderNode(*node);
         }
+        mPendingAnimatingRenderNodes.clear();
     }
 
 private:
     sp<Looper> mLooper;
-    std::vector<OnFinishedEvent> mOnFinishedEvents;
     JavaVM* mVm;
+    std::vector< sp<RenderNode> > mPendingAnimatingRenderNodes;
+};
+
+class AnimationContextBridge : public AnimationContext {
+public:
+    AnimationContextBridge(renderthread::TimeLord& clock, RootRenderNode* rootNode)
+            : AnimationContext(clock), mRootNode(rootNode) {
+    }
+
+    virtual ~AnimationContextBridge() {}
+
+    // Marks the start of a frame, which will update the frame time and move all
+    // next frame animations into the current frame
+    virtual void startFrame(TreeInfo::TraversalMode mode) {
+        if (mode == TreeInfo::MODE_FULL) {
+            mRootNode->doAttachAnimatingNodes(this);
+        }
+        AnimationContext::startFrame(mode);
+    }
+
+    // Runs any animations still left in mCurrentFrameAnimations
+    virtual void runRemainingAnimations(TreeInfo& info) {
+        AnimationContext::runRemainingAnimations(info);
+        postOnFinishedEvents();
+    }
+
+    virtual void callOnFinished(BaseRenderNodeAnimator* animator, AnimationListener* listener) {
+        OnFinishedEvent event(animator, listener);
+        mOnFinishedEvents.push_back(event);
+    }
+
+    virtual void destroy() {
+        AnimationContext::destroy();
+        postOnFinishedEvents();
+    }
+
+private:
+    sp<RootRenderNode> mRootNode;
+    std::vector<OnFinishedEvent> mOnFinishedEvents;
+
+    void postOnFinishedEvents() {
+        if (mOnFinishedEvents.size()) {
+            sp<InvokeAnimationListeners> message
+                    = new InvokeAnimationListeners(mOnFinishedEvents);
+            mRootNode->sendMessage(message);
+        }
+    }
+};
+
+class ContextFactoryImpl : public IContextFactory {
+public:
+    ContextFactoryImpl(RootRenderNode* rootNode) : mRootNode(rootNode) {}
+
+    virtual AnimationContext* createAnimationContext(renderthread::TimeLord& clock) {
+        return new AnimationContextBridge(clock, mRootNode);
+    }
+
+private:
+    RootRenderNode* mRootNode;
 };
 
 static void android_view_ThreadedRenderer_setAtlas(JNIEnv* env, jobject clazz,
@@ -168,8 +230,9 @@
 
 static jlong android_view_ThreadedRenderer_createProxy(JNIEnv* env, jobject clazz,
         jboolean translucent, jlong rootRenderNodePtr) {
-    RenderNode* rootRenderNode = reinterpret_cast<RenderNode*>(rootRenderNodePtr);
-    return (jlong) new RenderProxy(translucent, rootRenderNode);
+    RootRenderNode* rootRenderNode = reinterpret_cast<RootRenderNode*>(rootRenderNodePtr);
+    ContextFactoryImpl factory(rootRenderNode);
+    return (jlong) new RenderProxy(translucent, rootRenderNode, &factory);
 }
 
 static void android_view_ThreadedRenderer_deleteProxy(JNIEnv* env, jobject clazz,
@@ -238,10 +301,17 @@
     return proxy->syncAndDrawFrame(frameTimeNanos, recordDuration, density);
 }
 
-static void android_view_ThreadedRenderer_destroyCanvasAndSurface(JNIEnv* env, jobject clazz,
+static void android_view_ThreadedRenderer_destroy(JNIEnv* env, jobject clazz,
         jlong proxyPtr) {
     RenderProxy* proxy = reinterpret_cast<RenderProxy*>(proxyPtr);
-    proxy->destroyCanvasAndSurface();
+    proxy->destroy();
+}
+
+static void android_view_ThreadedRenderer_registerAnimatingRenderNode(JNIEnv* env, jobject clazz,
+        jlong rootNodePtr, jlong animatingNodePtr) {
+    RootRenderNode* rootRenderNode = reinterpret_cast<RootRenderNode*>(rootNodePtr);
+    RenderNode* animatingNode = reinterpret_cast<RenderNode*>(animatingNodePtr);
+    rootRenderNode->attachAnimatingNode(animatingNode);
 }
 
 static void android_view_ThreadedRenderer_invokeFunctor(JNIEnv* env, jobject clazz,
@@ -264,6 +334,13 @@
     return reinterpret_cast<jlong>(layer);
 }
 
+static void android_view_ThreadedRenderer_buildLayer(JNIEnv* env, jobject clazz,
+        jlong proxyPtr, jlong nodePtr) {
+    RenderProxy* proxy = reinterpret_cast<RenderProxy*>(proxyPtr);
+    RenderNode* node = reinterpret_cast<RenderNode*>(nodePtr);
+    proxy->buildLayer(node);
+}
+
 static jboolean android_view_ThreadedRenderer_copyLayerInto(JNIEnv* env, jobject clazz,
         jlong proxyPtr, jlong layerPtr, jlong bitmapPtr) {
     RenderProxy* proxy = reinterpret_cast<RenderProxy*>(proxyPtr);
@@ -363,10 +440,12 @@
     { "nSetup", "(JIIFFFFII)V", (void*) android_view_ThreadedRenderer_setup },
     { "nSetOpaque", "(JZ)V", (void*) android_view_ThreadedRenderer_setOpaque },
     { "nSyncAndDrawFrame", "(JJJF)I", (void*) android_view_ThreadedRenderer_syncAndDrawFrame },
-    { "nDestroyCanvasAndSurface", "(J)V", (void*) android_view_ThreadedRenderer_destroyCanvasAndSurface },
+    { "nDestroy", "(J)V", (void*) android_view_ThreadedRenderer_destroy },
+    { "nRegisterAnimatingRenderNode", "(JJ)V", (void*) android_view_ThreadedRenderer_registerAnimatingRenderNode },
     { "nInvokeFunctor", "(JZ)V", (void*) android_view_ThreadedRenderer_invokeFunctor },
     { "nCreateDisplayListLayer", "(JII)J", (void*) android_view_ThreadedRenderer_createDisplayListLayer },
     { "nCreateTextureLayer", "(J)J", (void*) android_view_ThreadedRenderer_createTextureLayer },
+    { "nBuildLayer", "(JJ)V", (void*) android_view_ThreadedRenderer_buildLayer },
     { "nCopyLayerInto", "(JJJ)Z", (void*) android_view_ThreadedRenderer_copyLayerInto },
     { "nPushLayerUpdate", "(JJ)V", (void*) android_view_ThreadedRenderer_pushLayerUpdate },
     { "nCancelLayerUpdate", "(JJ)V", (void*) android_view_ThreadedRenderer_cancelLayerUpdate },
diff --git a/core/jni/com_android_internal_net_NetworkStatsFactory.cpp b/core/jni/com_android_internal_net_NetworkStatsFactory.cpp
index c84a466..2e2d0c7 100644
--- a/core/jni/com_android_internal_net_NetworkStatsFactory.cpp
+++ b/core/jni/com_android_internal_net_NetworkStatsFactory.cpp
@@ -175,17 +175,23 @@
                 continue;
             }
         }
-        // Skip whitespace.
-        while (*pos == ' ') {
-            pos++;
-        }
-        // Next field is tag.
-        rawTag = strtoll(pos, &endPos, 16);
-        //ALOGI("Index #%d: %s", idx, buffer);
-        if (pos == endPos) {
-            ALOGE("bad tag: %s", pos);
-            fclose(fp);
-            return -1;
+
+        // Ignore whitespace
+        while (*pos == ' ') pos++;
+
+        // Find end of tag field
+        endPos = pos;
+        while (*endPos != ' ') endPos++;
+
+        // Three digit field is always 0x0, otherwise parse
+        if (endPos - pos == 3) {
+            rawTag = 0;
+        } else {
+            if (sscanf(pos, "%llx", &rawTag) != 1) {
+                ALOGE("bad tag: %s", pos);
+                fclose(fp);
+                return -1;
+            }
         }
         s.tag = rawTag >> 32;
         if (limitTag != -1 && s.tag != limitTag) {
@@ -193,10 +199,10 @@
             continue;
         }
         pos = endPos;
-        // Skip whitespace.
-        while (*pos == ' ') {
-            pos++;
-        }
+
+        // Ignore whitespace
+        while (*pos == ' ') pos++;
+
         // Parse remaining fields.
         if (sscanf(pos, "%u %u %llu %llu %llu %llu",
                 &s.uid, &s.set, &s.rxBytes, &s.rxPackets,
diff --git a/core/jni/com_android_internal_os_Zygote.cpp b/core/jni/com_android_internal_os_Zygote.cpp
index 1f7acec..451d97a 100644
--- a/core/jni/com_android_internal_os_Zygote.cpp
+++ b/core/jni/com_android_internal_os_Zygote.cpp
@@ -43,6 +43,7 @@
 #include <utils/String8.h>
 #include <selinux/android.h>
 #include <processgroup/processgroup.h>
+#include <inttypes.h>
 
 #include "android_runtime/AndroidRuntime.h"
 #include "JNIHelp.h"
@@ -398,14 +399,33 @@
   }
 }
 
+  // Temporary timing check.
+uint64_t MsTime() {
+  timespec now;
+  clock_gettime(CLOCK_MONOTONIC, &now);
+  return static_cast<uint64_t>(now.tv_sec) * UINT64_C(1000) + now.tv_nsec / UINT64_C(1000000);
+}
+
+
+void ckTime(uint64_t start, const char* where) {
+  uint64_t now = MsTime();
+  if ((now-start) > 1000) {
+    // If we are taking more than a second, log about it.
+    ALOGW("Slow operation: %"PRIu64" ms in %s", (uint64_t)(now-start), where);
+  }
+}
+
 // Utility routine to fork zygote and specialize the child process.
 static pid_t ForkAndSpecializeCommon(JNIEnv* env, uid_t uid, gid_t gid, jintArray javaGids,
                                      jint debug_flags, jobjectArray javaRlimits,
                                      jlong permittedCapabilities, jlong effectiveCapabilities,
                                      jint mount_external,
                                      jstring java_se_info, jstring java_se_name,
-                                     bool is_system_server, jintArray fdsToClose) {
+                                     bool is_system_server, jintArray fdsToClose,
+                                     jstring instructionSet) {
+  uint64_t start = MsTime();
   SetSigChldHandler();
+  ckTime(start, "ForkAndSpecializeCommon:SetSigChldHandler");
 
   pid_t pid = fork();
 
@@ -413,9 +433,12 @@
     // The child process.
     gMallocLeakZygoteChild = 1;
 
+
     // Clean up any descriptors which must be closed immediately
     DetachDescriptors(env, fdsToClose);
 
+    ckTime(start, "ForkAndSpecializeCommon:Fork and detach");
+
     // Keep capabilities across UID change, unless we're staying root.
     if (uid != 0) {
       EnableKeepCapabilities(env);
@@ -518,7 +541,11 @@
 
     UnsetSigChldHandler();
 
-    env->CallStaticVoidMethod(gZygoteClass, gCallPostForkChildHooks, debug_flags);
+    ckTime(start, "ForkAndSpecializeCommon:child process setup");
+
+    env->CallStaticVoidMethod(gZygoteClass, gCallPostForkChildHooks, debug_flags,
+                              is_system_server ? NULL : instructionSet);
+    ckTime(start, "ForkAndSpecializeCommon:PostForkChildHooks returns");
     if (env->ExceptionCheck()) {
       ALOGE("Error calling post fork hooks.");
       RuntimeAbort(env);
@@ -536,7 +563,7 @@
         JNIEnv* env, jclass, jint uid, jint gid, jintArray gids,
         jint debug_flags, jobjectArray rlimits,
         jint mount_external, jstring se_info, jstring se_name,
-        jintArray fdsToClose) {
+        jintArray fdsToClose, jstring instructionSet) {
     // Grant CAP_WAKE_ALARM to the Bluetooth process.
     jlong capabilities = 0;
     if (uid == AID_BLUETOOTH) {
@@ -545,7 +572,7 @@
 
     return ForkAndSpecializeCommon(env, uid, gid, gids, debug_flags,
             rlimits, capabilities, capabilities, mount_external, se_info,
-            se_name, false, fdsToClose);
+            se_name, false, fdsToClose, instructionSet);
 }
 
 static jint com_android_internal_os_Zygote_nativeForkSystemServer(
@@ -555,7 +582,7 @@
   pid_t pid = ForkAndSpecializeCommon(env, uid, gid, gids,
                                       debug_flags, rlimits,
                                       permittedCapabilities, effectiveCapabilities,
-                                      MOUNT_EXTERNAL_NONE, NULL, NULL, true, NULL);
+                                      MOUNT_EXTERNAL_NONE, NULL, NULL, true, NULL, NULL);
   if (pid > 0) {
       // The zygote process checks whether the child process has died or not.
       ALOGI("System server process %d has been created", pid);
@@ -573,7 +600,8 @@
 }
 
 static JNINativeMethod gMethods[] = {
-    { "nativeForkAndSpecialize", "(II[II[[IILjava/lang/String;Ljava/lang/String;[I)I",
+    { "nativeForkAndSpecialize",
+      "(II[II[[IILjava/lang/String;Ljava/lang/String;[ILjava/lang/String;)I",
       (void *) com_android_internal_os_Zygote_nativeForkAndSpecialize },
     { "nativeForkSystemServer", "(II[II[[IJJ)I",
       (void *) com_android_internal_os_Zygote_nativeForkSystemServer }
@@ -584,7 +612,8 @@
   if (gZygoteClass == NULL) {
     RuntimeAbort(env);
   }
-  gCallPostForkChildHooks = env->GetStaticMethodID(gZygoteClass, "callPostForkChildHooks", "(I)V");
+  gCallPostForkChildHooks = env->GetStaticMethodID(gZygoteClass, "callPostForkChildHooks",
+                                                   "(ILjava/lang/String;)V");
 
   return AndroidRuntime::registerNativeMethods(env, "com/android/internal/os/Zygote",
       gMethods, NELEM(gMethods));
diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml
index aee3090..03a5e23 100644
--- a/core/res/AndroidManifest.xml
+++ b/core/res/AndroidManifest.xml
@@ -182,11 +182,11 @@
     <protected-broadcast android:name="android.hardware.usb.action.USB_DEVICE_DETACHED" />
 
     <protected-broadcast android:name="android.intent.action.HEADSET_PLUG" />
-    <protected-broadcast android:name="android.intent.action.ANALOG_AUDIO_DOCK_PLUG" />
-    <protected-broadcast android:name="android.intent.action.DIGITAL_AUDIO_DOCK_PLUG" />
-    <protected-broadcast android:name="android.intent.action.HDMI_AUDIO_PLUG" />
-    <protected-broadcast android:name="android.intent.action.USB_AUDIO_ACCESSORY_PLUG" />
-    <protected-broadcast android:name="android.intent.action.USB_AUDIO_DEVICE_PLUG" />
+    <protected-broadcast android:name="android.media.action.ANALOG_AUDIO_DOCK_PLUG" />
+    <protected-broadcast android:name="android.media.action.DIGITAL_AUDIO_DOCK_PLUG" />
+    <protected-broadcast android:name="android.media.action.HDMI_AUDIO_PLUG" />
+    <protected-broadcast android:name="android.media.action.USB_AUDIO_ACCESSORY_PLUG" />
+    <protected-broadcast android:name="android.media.action.USB_AUDIO_DEVICE_PLUG" />
 
     <protected-broadcast android:name="android.media.AUDIO_BECOMING_NOISY" />
     <protected-broadcast android:name="android.media.RINGER_MODE_CHANGED" />
@@ -864,7 +864,8 @@
         android:description="@string/permdesc_bluetoothAdmin"
         android:label="@string/permlab_bluetoothAdmin" />
 
-    <!-- @SystemApi Allows applications to pair bluetooth devices without user interaction.
+    <!-- @SystemApi Allows applications to pair bluetooth devices without user interaction, and to
+         allow or disallow phonebook access or message access.
          This is not available to third party applications. -->
     <permission android:name="android.permission.BLUETOOTH_PRIVILEGED"
         android:permissionGroup="android.permission-group.BLUETOOTH_NETWORK"
@@ -1249,13 +1250,13 @@
         android:description="@string/permdesc_use_sip"
         android:label="@string/permlab_use_sip" />
 
-    <!-- @SystemApi Allows an application to request CallHandlerService implementations.
+    <!-- @SystemApi Allows an application to bind to InCallService implementations.
          @hide -->
-    <permission android:name="android.permission.BIND_CALL_SERVICE"
+    <permission android:name="android.permission.BIND_INCALL_SERVICE"
         android:permissionGroup="android.permission-group.PHONE_CALLS"
         android:protectionLevel="system|signature"
-        android:description="@string/permdesc_bind_call_service"
-        android:label="@string/permlab_bind_call_service" />
+        android:description="@string/permdesc_bind_incall_service"
+        android:label="@string/permlab_bind_incall_service" />
 
     <!-- @SystemApi Allows an application to bind to ConnectionService implementations.
          @hide -->
@@ -1265,6 +1266,14 @@
                 android:description="@string/permdesc_bind_connection_service"
                 android:label="@string/permlab_bind_connection_service" />
 
+    <!-- @SystemApi Allows an application to control the in-call experience.
+         @hide -->
+    <permission android:name="android.permission.CONTROL_INCALL_EXPERIENCE"
+                android:permissionGroup="android.permission-group.PHONE_CALLS"
+                android:protectionLevel="system|signature"
+                android:description="@string/permdesc_control_incall_experience"
+                android:label="@string/permlab_control_incall_experience" />
+
     <!-- ================================== -->
     <!-- Permissions for sdcard interaction -->
     <!-- ================================== -->
@@ -2200,15 +2209,7 @@
     <permission android:name="android.permission.MODIFY_PARENTAL_CONTROLS"
         android:label="@string/permlab_modifyParentalControls"
         android:description="@string/permdesc_modifyParentalControls"
-        android:protectionLevel="signature" />
-
-    <!-- Must be required by a {@link android.media.routing.MediaRouteService}
-         to ensure that only the system can interact with it.
-         @hide -->
-    <permission android:name="android.permission.BIND_ROUTE_PROVIDER"
-        android:label="@string/permlab_bindRouteProvider"
-        android:description="@string/permdesc_bindRouteProvider"
-        android:protectionLevel="signature" />
+        android:protectionLevel="signature|system" />
 
     <!-- Must be required by device administration receiver, to ensure that only the
          system can interact with it. -->
@@ -2408,6 +2409,13 @@
         android:description="@string/permdesc_devicePower"
         android:protectionLevel="signature" />
 
+   <!-- Allows access to the PowerManager.userActivity function.
+   <p>Not for use by third-party applications. @hide @SystemApi -->
+    <permission android:name="android.permission.USER_ACTIVITY"
+        android:label="@string/permlab_userActivity"
+        android:description="@string/permdesc_userActivity"
+        android:protectionLevel="signature|system" />
+
    <!-- @hide Allows low-level access to tun tap driver -->
     <permission android:name="android.permission.NET_TUNNELING"
         android:permissionGroup="android.permission-group.SYSTEM_TOOLS"
@@ -2495,7 +2503,7 @@
     <permission android:name="android.permission.PACKAGE_USAGE_STATS"
         android:label="@string/permlab_pkgUsageStats"
         android:description="@string/permdesc_pkgUsageStats"
-        android:protectionLevel="signature|system|development|appop" />
+        android:protectionLevel="signature|development|appop" />
     <uses-permission android:name="android.permission.PACKAGE_USAGE_STATS" />
 
     <!-- @SystemApi Allows an application to collect battery statistics -->
@@ -2766,7 +2774,7 @@
         android:description="@string/permdesc_bindNotificationListenerService"
         android:protectionLevel="signature" />
 
-    <!-- Must be required by an {@link
+    <!-- @SystemApi Must be required by a {@link
          android.service.notification.ConditionProviderService},
          to ensure that only the system can bind to it.
          @hide -->
@@ -2775,13 +2783,6 @@
         android:description="@string/permdesc_bindConditionProviderService"
         android:protectionLevel="signature" />
 
-    <!-- Must be required by a {@link android.media.routing.MediaRouteService},
-         to ensure that only the system can bind to it. -->
-    <permission android:name="android.permission.BIND_MEDIA_ROUTE_SERVICE"
-        android:label="@string/permlab_bindMediaRouteService"
-        android:description="@string/permdesc_bindMediaRouteService"
-        android:protectionLevel="signature" />
-
     <!-- Must be required by an {@link android.service.dreams.DreamService},
          to ensure that only the system can bind to it. -->
     <permission android:name="android.permission.BIND_DREAM_SERVICE"
@@ -2811,11 +2812,11 @@
         android:description="@string/permdesc_accessDrmCertificates"
         android:protectionLevel="signature|system" />
 
-    <!-- Api Allows an application to create media projection sessions.
+    <!-- Api Allows an application to manage media projection sessions.
          @hide This is not a third-party API (intended for system apps). -->
-    <permission android:name="android.permission.CREATE_MEDIA_PROJECTION"
-        android:label="@string/permlab_createMediaProjection"
-        android:description="@string/permdesc_createMediaProjection"
+    <permission android:name="android.permission.MANAGE_MEDIA_PROJECTION"
+        android:label="@string/permlab_manageMediaProjection"
+        android:description="@string/permdesc_manageMediaProjection"
         android:protectionLevel="signature" />
 
     <!-- @SystemApi Allows an application to read install sessions
@@ -2876,7 +2877,7 @@
                 android:label="@string/managed_profile_label">
         </activity-alias>
         <activity android:name="com.android.internal.app.HeavyWeightSwitcherActivity"
-                android:theme="@style/Theme.Holo.Dialog"
+                android:theme="@style/Theme.Material.Dialog"
                 android:label="@string/heavy_weight_switcher_title"
                 android:finishOnCloseSystemDialogs="true"
                 android:excludeFromRecents="true"
diff --git a/core/res/res/anim/launch_task_behind_background.xml b/core/res/res/anim/launch_task_behind_target.xml
similarity index 100%
rename from core/res/res/anim/launch_task_behind_background.xml
rename to core/res/res/anim/launch_task_behind_target.xml
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml b/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml
new file mode 100644
index 0000000..96a9d45
--- /dev/null
+++ b/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android" >
+    <objectAnimator
+        android:duration="2000"
+        android:propertyXName="translateX"
+        android:pathData="M -522.59998,0 c 48.89972,0 166.02656,0 301.21729,0 c 197.58128,0 420.9827,0 420.9827,0 "
+        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect1_translatex"
+        android:repeatCount="infinite" />
+    <objectAnimator
+        android:duration="2000"
+        android:propertyYName="scaleX"
+        android:pathData="M 0 0.1 L 1 0.826849212646 L 2 0.1"
+        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect1_scalex"
+        android:repeatCount="infinite" />
+</set>
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect2.xml b/core/res/res/anim/progress_indeterminate_horizontal_rect2.xml
new file mode 100644
index 0000000..32759fa
--- /dev/null
+++ b/core/res/res/anim/progress_indeterminate_horizontal_rect2.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android" >
+    <objectAnimator
+        android:duration="2000"
+        android:propertyXName="translateX"
+        android:pathData="M -197.60001,0 c 14.28182,0 85.07782,0 135.54689,0 c 54.26191,0 90.42461,0 168.24331,0 c 144.72154,0 316.40982,0 316.40982,0 "
+        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect2_translatex"
+        android:repeatCount="infinite" />
+    <objectAnimator
+        android:duration="2000"
+        android:propertyYName="scaleX"
+        android:pathData="M 0.0,0.1 L 1.0,0.571379510698 L 2.0,0.909950256348 L 3.0,0.1"
+        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect2_scalex"
+        android:repeatCount="infinite" />
+</set>
diff --git a/core/res/res/color/btn_default_material_dark.xml b/core/res/res/color/btn_default_material_dark.xml
index 7c904cd..9be1417 100644
--- a/core/res/res/color/btn_default_material_dark.xml
+++ b/core/res/res/color/btn_default_material_dark.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/button_material_dark"/>
+          android:alpha="@dimen/disabled_alpha_material_dark"
+          android:color="@color/button_material_dark"/>
     <item android:color="@color/button_material_dark"/>
 </selector>
diff --git a/core/res/res/color/btn_default_material_light.xml b/core/res/res/color/btn_default_material_light.xml
index 738f9ad..af5afe6 100644
--- a/core/res/res/color/btn_default_material_light.xml
+++ b/core/res/res/color/btn_default_material_light.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/button_material_light"/>
+          android:alpha="@dimen/disabled_alpha_material_light"
+          android:color="@color/button_material_light"/>
     <item android:color="@color/button_material_light"/>
 </selector>
diff --git a/core/res/res/color/primary_text_disable_only_material_dark.xml b/core/res/res/color/primary_text_disable_only_material_dark.xml
index cdae790..a6296c96 100644
--- a/core/res/res/color/primary_text_disable_only_material_dark.xml
+++ b/core/res/res/color/primary_text_disable_only_material_dark.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/bright_foreground_material_dark"/>
+          android:alpha="@dimen/disabled_alpha_material_dark"
+          android:color="@color/bright_foreground_material_dark"/>
     <item android:color="@color/bright_foreground_material_dark"/>
 </selector>
diff --git a/core/res/res/color/primary_text_disable_only_material_light.xml b/core/res/res/color/primary_text_disable_only_material_light.xml
index 0bf14d0..b781844 100644
--- a/core/res/res/color/primary_text_disable_only_material_light.xml
+++ b/core/res/res/color/primary_text_disable_only_material_light.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/bright_foreground_material_light"/>
+          android:alpha="@dimen/disabled_alpha_material_light"
+          android:color="@color/bright_foreground_material_light"/>
     <item android:color="@color/bright_foreground_material_light"/>
 </selector>
diff --git a/core/res/res/color/primary_text_material_dark.xml b/core/res/res/color/primary_text_material_dark.xml
index 6ad837b..690f0ec 100644
--- a/core/res/res/color/primary_text_material_dark.xml
+++ b/core/res/res/color/primary_text_material_dark.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/primary_text_default_material_dark"/>
+          android:alpha="@dimen/disabled_alpha_material_dark"
+          android:color="@color/primary_text_default_material_dark"/>
     <item android:color="@color/primary_text_default_material_dark"/>
 </selector>
diff --git a/core/res/res/color/primary_text_material_light.xml b/core/res/res/color/primary_text_material_light.xml
index 4c19e12..634ad94 100644
--- a/core/res/res/color/primary_text_material_light.xml
+++ b/core/res/res/color/primary_text_material_light.xml
@@ -16,7 +16,7 @@
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:state_enabled="false"
-        android:alpha="@dimen/disabled_alpha_material"
-        android:color="@color/primary_text_default_material_light"/>
+          android:alpha="@dimen/disabled_alpha_material_light"
+          android:color="@color/primary_text_default_material_light"/>
     <item android:color="@color/primary_text_default_material_light"/>
 </selector>
diff --git a/core/res/res/color/secondary_text_material_dark.xml b/core/res/res/color/secondary_text_material_dark.xml
new file mode 100644
index 0000000..5bddf96
--- /dev/null
+++ b/core/res/res/color/secondary_text_material_dark.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2008 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_enabled="false"
+          android:alpha="@dimen/disabled_alpha_material_dark"
+          android:color="@color/secondary_text_default_material_dark"/>
+    <item android:color="@color/secondary_text_default_material_dark"/>
+</selector>
diff --git a/core/res/res/color/secondary_text_material_light.xml b/core/res/res/color/secondary_text_material_light.xml
new file mode 100644
index 0000000..3c354cb
--- /dev/null
+++ b/core/res/res/color/secondary_text_material_light.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2008 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_enabled="false"
+          android:alpha="@dimen/disabled_alpha_material_light"
+          android:color="@color/secondary_text_default_material_light"/>
+    <item android:color="@color/secondary_text_default_material_light"/>
+</selector>
diff --git a/core/res/res/color/switch_thumb_material_dark.xml b/core/res/res/color/switch_thumb_material_dark.xml
new file mode 100644
index 0000000..8fede70
--- /dev/null
+++ b/core/res/res/color/switch_thumb_material_dark.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_enabled="false" android:color="@color/switch_thumb_disabled_material_dark"/>
+    <item android:color="@color/switch_thumb_normal_material_dark"/>
+</selector>
diff --git a/core/res/res/color/switch_thumb_material_light.xml b/core/res/res/color/switch_thumb_material_light.xml
new file mode 100644
index 0000000..1a34b74
--- /dev/null
+++ b/core/res/res/color/switch_thumb_material_light.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_enabled="false" android:color="@color/switch_thumb_disabled_material_light"/>
+    <item android:color="@color/switch_thumb_normal_material_light"/>
+</selector>
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00001.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00001.9.png
index 9076900..c31194e 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00001.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00002.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00002.9.png
index 3c72bf8..52ed6b2 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00002.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00003.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00003.9.png
index d31e113..7b7cde586 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00003.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00004.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00004.9.png
index d0c693e..859642a 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00004.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00005.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00005.9.png
index dfa19b4..5b71dda 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00005.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00006.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00006.9.png
index 151f205..378d82d 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00006.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00007.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00007.9.png
index ad3ee2c..43c995a 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00007.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00008.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00008.9.png
index 43d66d7..c937837 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00008.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00009.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00009.9.png
index 13e4f8b..a60a127 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00009.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00010.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00010.9.png
index a09b6b2..db0bf2d 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00010.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00011.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00011.9.png
index be02e53..4a6adbe 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00011.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00012.9.png b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00012.9.png
index 655d387..98983ef 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00012.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_off_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00001.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00001.9.png
index e870a0a..8e7b62f 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00001.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00002.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00002.9.png
index 1d8f805..479a26e 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00002.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00003.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00003.9.png
index d348871..77d3130 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00003.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00004.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00004.9.png
index 941e91e..cfe684f 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00004.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00005.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00005.9.png
index adee78d..4a64a36 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00005.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00006.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00006.9.png
index e6b4ca3..29591ff 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00006.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00007.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00007.9.png
index 6c2bc0d..cf7cf49 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00007.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00008.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00008.9.png
index 763833c..2a2a9af 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00008.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00009.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00009.9.png
index 9a87fbc..1f7fe5f 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00009.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00010.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00010.9.png
index 6ccf70b..f5d7093 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00010.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00011.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00011.9.png
index d1c14a5..3878386 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00011.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00012.9.png b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00012.9.png
index c2290f0..adcb9e9 100644
--- a/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00012.9.png
+++ b/core/res/res/drawable-hdpi/btn_switch_to_on_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-hdpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index 6c36eae..0000000
--- a/core/res/res/drawable-hdpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_corp_icon.png b/core/res/res/drawable-hdpi/ic_corp_icon.png
index 829962c..06c5135 100644
--- a/core/res/res/drawable-hdpi/ic_corp_icon.png
+++ b/core/res/res/drawable-hdpi/ic_corp_icon.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_dialog_alert_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_dialog_alert_mtrl_alpha.png
deleted file mode 100644
index 95cfb32..0000000
--- a/core/res/res/drawable-hdpi/ic_dialog_alert_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_go_search_api_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_go_search_api_mtrl_alpha.png
deleted file mode 100644
index aa23c59..0000000
--- a/core/res/res/drawable-hdpi/ic_go_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_copy_mtrl_am_alpha.png b/core/res/res/drawable-hdpi/ic_menu_copy_mtrl_am_alpha.png
deleted file mode 100644
index d6d1f2f..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_copy_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_cut_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_menu_cut_mtrl_alpha.png
deleted file mode 100644
index ec8db6f..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_cut_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_moreoverflow_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_menu_moreoverflow_mtrl_alpha.png
deleted file mode 100644
index 1ba1295..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_moreoverflow_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_paste_mtrl_am_alpha.png b/core/res/res/drawable-hdpi/ic_menu_paste_mtrl_am_alpha.png
deleted file mode 100644
index bf44722..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_paste_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_selectall_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_menu_selectall_mtrl_alpha.png
deleted file mode 100644
index 8539741..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_selectall_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_menu_share_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_menu_share_mtrl_alpha.png
deleted file mode 100644
index 0eacedd..0000000
--- a/core/res/res/drawable-hdpi/ic_menu_share_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_search_api_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_search_api_mtrl_alpha.png
deleted file mode 100644
index f7382d3..0000000
--- a/core/res/res/drawable-hdpi/ic_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/ic_voice_search_api_mtrl_alpha.png b/core/res/res/drawable-hdpi/ic_voice_search_api_mtrl_alpha.png
deleted file mode 100644
index 25b8935..0000000
--- a/core/res/res/drawable-hdpi/ic_voice_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-hdpi/list_divider_mtrl_alpha.9.png b/core/res/res/drawable-hdpi/list_divider_mtrl_alpha.9.png
index 77845df..2fa6d7e 100644
--- a/core/res/res/drawable-hdpi/list_divider_mtrl_alpha.9.png
+++ b/core/res/res/drawable-hdpi/list_divider_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/pointer_arrow_icon.xml b/core/res/res/drawable-hdpi/pointer_arrow_icon.xml
deleted file mode 100644
index a4cce5c..0000000
--- a/core/res/res/drawable-hdpi/pointer_arrow_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_arrow"
-    android:hotSpotX="9"
-    android:hotSpotY="9" />
diff --git a/core/res/res/drawable-hdpi/pointer_spot_anchor.png b/core/res/res/drawable-hdpi/pointer_spot_anchor.png
index d7aca36..bdb5311 100644
--- a/core/res/res/drawable-hdpi/pointer_spot_anchor.png
+++ b/core/res/res/drawable-hdpi/pointer_spot_anchor.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/pointer_spot_anchor_icon.xml b/core/res/res/drawable-hdpi/pointer_spot_anchor_icon.xml
deleted file mode 100644
index 2222b8e..0000000
--- a/core/res/res/drawable-hdpi/pointer_spot_anchor_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_anchor"
-    android:hotSpotX="33"
-    android:hotSpotY="33" />
diff --git a/core/res/res/drawable-hdpi/pointer_spot_hover.png b/core/res/res/drawable-hdpi/pointer_spot_hover.png
index 5041aa3..e7f2a0c 100644
--- a/core/res/res/drawable-hdpi/pointer_spot_hover.png
+++ b/core/res/res/drawable-hdpi/pointer_spot_hover.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/pointer_spot_hover_icon.xml b/core/res/res/drawable-hdpi/pointer_spot_hover_icon.xml
deleted file mode 100644
index dc62a69..0000000
--- a/core/res/res/drawable-hdpi/pointer_spot_hover_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_hover"
-    android:hotSpotX="33"
-    android:hotSpotY="33" />
diff --git a/core/res/res/drawable-hdpi/pointer_spot_touch.png b/core/res/res/drawable-hdpi/pointer_spot_touch.png
index 64a42a1..0326f91 100644
--- a/core/res/res/drawable-hdpi/pointer_spot_touch.png
+++ b/core/res/res/drawable-hdpi/pointer_spot_touch.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/pointer_spot_touch_icon.xml b/core/res/res/drawable-hdpi/pointer_spot_touch_icon.xml
deleted file mode 100644
index 4bffee6..0000000
--- a/core/res/res/drawable-hdpi/pointer_spot_touch_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_touch"
-    android:hotSpotX="24"
-    android:hotSpotY="24" />
diff --git a/core/res/res/drawable-hdpi/spinner_textfield_activated_mtrl_alpha.9.png b/core/res/res/drawable-hdpi/spinner_textfield_activated_mtrl_alpha.9.png
index 8af9ceb4..5e67395 100644
--- a/core/res/res/drawable-hdpi/spinner_textfield_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-hdpi/spinner_textfield_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/spinner_textfield_default_mtrl_alpha.9.png b/core/res/res/drawable-hdpi/spinner_textfield_default_mtrl_alpha.9.png
index 81c78c6..9c2ee13 100644
--- a/core/res/res/drawable-hdpi/spinner_textfield_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-hdpi/spinner_textfield_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_search_activated_mtrl_alpha.9.png b/core/res/res/drawable-hdpi/textfield_search_activated_mtrl_alpha.9.png
index 7bcebcd..ce577e5 100644
--- a/core/res/res/drawable-hdpi/textfield_search_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-hdpi/textfield_search_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/textfield_search_default_mtrl_alpha.9.png b/core/res/res/drawable-hdpi/textfield_search_default_mtrl_alpha.9.png
index eb1d945..7c305ab 100644
--- a/core/res/res/drawable-hdpi/textfield_search_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-hdpi/textfield_search_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-hdpi/title_bar_shadow.9.png b/core/res/res/drawable-hdpi/title_bar_shadow.9.png
deleted file mode 100644
index e6dab63..0000000
--- a/core/res/res/drawable-hdpi/title_bar_shadow.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-ldpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index 96e86b6..0000000
--- a/core/res/res/drawable-ldpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_dialog_alert_mtrl_alpha.png b/core/res/res/drawable-ldpi/ic_dialog_alert_mtrl_alpha.png
deleted file mode 100644
index f604e8b..0000000
--- a/core/res/res/drawable-ldpi/ic_dialog_alert_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_copy_mtrl_am_alpha.png b/core/res/res/drawable-ldpi/ic_menu_copy_mtrl_am_alpha.png
deleted file mode 100644
index 565280b..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_copy_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_cut_mtrl_alpha.png b/core/res/res/drawable-ldpi/ic_menu_cut_mtrl_alpha.png
deleted file mode 100644
index dbedece..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_cut_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_moreoverflow_mtrl_alpha.png b/core/res/res/drawable-ldpi/ic_menu_moreoverflow_mtrl_alpha.png
deleted file mode 100644
index d47f81e..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_moreoverflow_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_paste_mtrl_am_alpha.png b/core/res/res/drawable-ldpi/ic_menu_paste_mtrl_am_alpha.png
deleted file mode 100644
index 430141b..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_paste_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_selectall_mtrl_alpha.png b/core/res/res/drawable-ldpi/ic_menu_selectall_mtrl_alpha.png
deleted file mode 100644
index 7b520bc..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_selectall_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/ic_menu_share_mtrl_alpha.png b/core/res/res/drawable-ldpi/ic_menu_share_mtrl_alpha.png
deleted file mode 100644
index db1e146..0000000
--- a/core/res/res/drawable-ldpi/ic_menu_share_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-ldpi/list_divider_mtrl_alpha.9.png b/core/res/res/drawable-ldpi/list_divider_mtrl_alpha.9.png
index 77845df..941d0d7 100644
--- a/core/res/res/drawable-ldpi/list_divider_mtrl_alpha.9.png
+++ b/core/res/res/drawable-ldpi/list_divider_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00001.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00001.9.png
index 0238898..36ed954 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00001.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00002.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00002.9.png
index ada1be9..863eee1 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00002.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00003.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00003.9.png
index 82aec64..63e93a8 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00003.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00004.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00004.9.png
index 1c6ea9f..85c851d 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00004.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00005.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00005.9.png
index ac11400..8637636 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00005.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00006.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00006.9.png
index 2025972..2945c29 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00006.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00007.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00007.9.png
index 7420fd8..678a6c8 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00007.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00008.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00008.9.png
index 1f40832..238a6f1 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00008.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00009.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00009.9.png
index cf58e44..4a342a6 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00009.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00010.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00010.9.png
index 930a280..5842b19 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00010.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00011.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00011.9.png
index ed9bc37..3e1bd2d 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00011.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00012.9.png b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00012.9.png
index cddb5b0..73ed10b 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00012.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_off_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00001.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00001.9.png
index bc1f979..03d3dfb 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00001.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00002.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00002.9.png
index e6fdbcc..25085ce 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00002.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00003.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00003.9.png
index 3d60b43..9e4d2f3 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00003.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00004.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00004.9.png
index b9afdc2..ab5bd1e 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00004.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00005.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00005.9.png
index c3c8bf2..f5297ce 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00005.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00006.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00006.9.png
index 1c7e5e1..1ad56e9 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00006.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00007.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00007.9.png
index 6329b73..4bad055 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00007.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00008.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00008.9.png
index 424202c..d908034 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00008.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00009.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00009.9.png
index 313beca..8ed4fb4 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00009.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00010.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00010.9.png
index f18d86a..61d3ced 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00010.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00011.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00011.9.png
index 8ab48c0..dec2a82 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00011.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00012.9.png b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00012.9.png
index fbc2c16..6635830 100644
--- a/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00012.9.png
+++ b/core/res/res/drawable-mdpi/btn_switch_to_on_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-mdpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index 6674351..0000000
--- a/core/res/res/drawable-mdpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_corp_icon.png b/core/res/res/drawable-mdpi/ic_corp_icon.png
index 44eb2d5..79372b2 100644
--- a/core/res/res/drawable-mdpi/ic_corp_icon.png
+++ b/core/res/res/drawable-mdpi/ic_corp_icon.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_dialog_alert_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_dialog_alert_mtrl_alpha.png
deleted file mode 100644
index 8a882f9..0000000
--- a/core/res/res/drawable-mdpi/ic_dialog_alert_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_go_search_api_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_go_search_api_mtrl_alpha.png
deleted file mode 100644
index b5f6176..0000000
--- a/core/res/res/drawable-mdpi/ic_go_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_copy_mtrl_am_alpha.png b/core/res/res/drawable-mdpi/ic_menu_copy_mtrl_am_alpha.png
deleted file mode 100644
index 3fae32d..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_copy_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_cut_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_menu_cut_mtrl_alpha.png
deleted file mode 100644
index 61ff631..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_cut_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_moreoverflow_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_menu_moreoverflow_mtrl_alpha.png
deleted file mode 100644
index 8415096..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_moreoverflow_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_paste_mtrl_am_alpha.png b/core/res/res/drawable-mdpi/ic_menu_paste_mtrl_am_alpha.png
deleted file mode 100644
index 112c268..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_paste_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_selectall_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_menu_selectall_mtrl_alpha.png
deleted file mode 100644
index 6414956..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_selectall_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_menu_share_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_menu_share_mtrl_alpha.png
deleted file mode 100644
index e0d5ac4..0000000
--- a/core/res/res/drawable-mdpi/ic_menu_share_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_search_api_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_search_api_mtrl_alpha.png
deleted file mode 100644
index 0fb57b2..0000000
--- a/core/res/res/drawable-mdpi/ic_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/ic_voice_search_api_mtrl_alpha.png b/core/res/res/drawable-mdpi/ic_voice_search_api_mtrl_alpha.png
deleted file mode 100644
index 3f1eee3..0000000
--- a/core/res/res/drawable-mdpi/ic_voice_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-mdpi/list_divider_mtrl_alpha.9.png b/core/res/res/drawable-mdpi/list_divider_mtrl_alpha.9.png
index 77845df..070bdbf 100644
--- a/core/res/res/drawable-mdpi/list_divider_mtrl_alpha.9.png
+++ b/core/res/res/drawable-mdpi/list_divider_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/pointer_arrow_icon.xml b/core/res/res/drawable-mdpi/pointer_arrow_icon.xml
deleted file mode 100644
index 2f5676f..0000000
--- a/core/res/res/drawable-mdpi/pointer_arrow_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_arrow"
-    android:hotSpotX="6"
-    android:hotSpotY="6" />
diff --git a/core/res/res/drawable-mdpi/pointer_spot_anchor.png b/core/res/res/drawable-mdpi/pointer_spot_anchor.png
index d7aca36..4e282e7 100644
--- a/core/res/res/drawable-mdpi/pointer_spot_anchor.png
+++ b/core/res/res/drawable-mdpi/pointer_spot_anchor.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/pointer_spot_anchor_icon.xml b/core/res/res/drawable-mdpi/pointer_spot_anchor_icon.xml
deleted file mode 100644
index 2222b8e..0000000
--- a/core/res/res/drawable-mdpi/pointer_spot_anchor_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_anchor"
-    android:hotSpotX="33"
-    android:hotSpotY="33" />
diff --git a/core/res/res/drawable-mdpi/pointer_spot_hover.png b/core/res/res/drawable-mdpi/pointer_spot_hover.png
index 5041aa3..67d0b06 100644
--- a/core/res/res/drawable-mdpi/pointer_spot_hover.png
+++ b/core/res/res/drawable-mdpi/pointer_spot_hover.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/pointer_spot_hover_icon.xml b/core/res/res/drawable-mdpi/pointer_spot_hover_icon.xml
deleted file mode 100644
index dc62a69..0000000
--- a/core/res/res/drawable-mdpi/pointer_spot_hover_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_hover"
-    android:hotSpotX="33"
-    android:hotSpotY="33" />
diff --git a/core/res/res/drawable-mdpi/pointer_spot_touch.png b/core/res/res/drawable-mdpi/pointer_spot_touch.png
index 64a42a1..45dc5c0 100644
--- a/core/res/res/drawable-mdpi/pointer_spot_touch.png
+++ b/core/res/res/drawable-mdpi/pointer_spot_touch.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/pointer_spot_touch_icon.xml b/core/res/res/drawable-mdpi/pointer_spot_touch_icon.xml
deleted file mode 100644
index 4bffee6..0000000
--- a/core/res/res/drawable-mdpi/pointer_spot_touch_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_spot_touch"
-    android:hotSpotX="24"
-    android:hotSpotY="24" />
diff --git a/core/res/res/drawable-mdpi/spinner_textfield_activated_mtrl_alpha.9.png b/core/res/res/drawable-mdpi/spinner_textfield_activated_mtrl_alpha.9.png
index 22992c0..cb8f78a 100644
--- a/core/res/res/drawable-mdpi/spinner_textfield_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-mdpi/spinner_textfield_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/spinner_textfield_default_mtrl_alpha.9.png b/core/res/res/drawable-mdpi/spinner_textfield_default_mtrl_alpha.9.png
index f44a2c2..64d4c81 100644
--- a/core/res/res/drawable-mdpi/spinner_textfield_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-mdpi/spinner_textfield_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_search_activated_mtrl_alpha.9.png b/core/res/res/drawable-mdpi/textfield_search_activated_mtrl_alpha.9.png
index ef4ebc0..d7faacf 100644
--- a/core/res/res/drawable-mdpi/textfield_search_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-mdpi/textfield_search_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/textfield_search_default_mtrl_alpha.9.png b/core/res/res/drawable-mdpi/textfield_search_default_mtrl_alpha.9.png
index 9ddbcf5..0a36039 100644
--- a/core/res/res/drawable-mdpi/textfield_search_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-mdpi/textfield_search_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-mdpi/title_bar_shadow.9.png b/core/res/res/drawable-mdpi/title_bar_shadow.9.png
deleted file mode 100644
index dbcefee..0000000
--- a/core/res/res/drawable-mdpi/title_bar_shadow.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00001.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00001.9.png
index 265aeb7..df73ef7 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00001.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00002.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00002.9.png
index 2f036ad..baf52ed 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00002.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00003.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00003.9.png
index bb26440..c8f3b1c 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00003.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00004.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00004.9.png
index 1b70047..fe715cf 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00004.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00005.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00005.9.png
index b544b98..8e66e11 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00005.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00006.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00006.9.png
index c461f3d..537496e 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00006.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00007.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00007.9.png
index f57da14..2722a98 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00007.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00008.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00008.9.png
index 22c6fbc..81fad09 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00008.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00009.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00009.9.png
index cd21ac9..cda20c8 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00009.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00010.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00010.9.png
index a38dc87..a61ad4b 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00010.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00011.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00011.9.png
index d84a342..d6e8e4c 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00011.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00012.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00012.9.png
index b82a2eb..785168e 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00012.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_off_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00001.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00001.9.png
index 6a33ebf..8a648b8 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00001.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00002.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00002.9.png
index dafc250..03063d4 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00002.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00003.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00003.9.png
index 27df6ff..6159dec 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00003.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00004.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00004.9.png
index cb4121c..6f1c96c 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00004.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00005.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00005.9.png
index c5cbb75..2eaff46 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00005.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00006.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00006.9.png
index c69ef41..c4d9db8 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00006.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00007.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00007.9.png
index aff03d1..f276f16 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00007.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00008.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00008.9.png
index fb56ae6..cf9133e 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00008.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00009.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00009.9.png
index 88b9d28..8f1a6a8 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00009.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00010.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00010.9.png
index 8451958..5080c46 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00010.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00011.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00011.9.png
index 6f57654..5e39408 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00011.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00012.9.png b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00012.9.png
index 21bfc28..435ce21 100644
--- a/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00012.9.png
+++ b/core/res/res/drawable-xhdpi/btn_switch_to_on_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-xhdpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index 27bdcb7..0000000
--- a/core/res/res/drawable-xhdpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_corp_icon.png b/core/res/res/drawable-xhdpi/ic_corp_icon.png
index 04faf00..3626c7d 100644
--- a/core/res/res/drawable-xhdpi/ic_corp_icon.png
+++ b/core/res/res/drawable-xhdpi/ic_corp_icon.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_dialog_alert_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_dialog_alert_mtrl_alpha.png
deleted file mode 100644
index 2229bf3..0000000
--- a/core/res/res/drawable-xhdpi/ic_dialog_alert_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_go_search_api_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_go_search_api_mtrl_alpha.png
deleted file mode 100644
index bd80981..0000000
--- a/core/res/res/drawable-xhdpi/ic_go_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_copy_mtrl_am_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_copy_mtrl_am_alpha.png
deleted file mode 100644
index b690d7c..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_copy_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_cut_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_cut_mtrl_alpha.png
deleted file mode 100644
index 10c2067..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_cut_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_moreoverflow_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_moreoverflow_mtrl_alpha.png
deleted file mode 100644
index f91b718..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_moreoverflow_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_paste_mtrl_am_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_paste_mtrl_am_alpha.png
deleted file mode 100644
index 4024627..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_paste_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_selectall_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_selectall_mtrl_alpha.png
deleted file mode 100644
index f7c0261..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_selectall_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_menu_share_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_menu_share_mtrl_alpha.png
deleted file mode 100644
index 7accf52..0000000
--- a/core/res/res/drawable-xhdpi/ic_menu_share_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_search_api_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_search_api_mtrl_alpha.png
deleted file mode 100644
index 05cfab7..0000000
--- a/core/res/res/drawable-xhdpi/ic_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/ic_voice_search_api_mtrl_alpha.png b/core/res/res/drawable-xhdpi/ic_voice_search_api_mtrl_alpha.png
deleted file mode 100644
index c1c23d04..0000000
--- a/core/res/res/drawable-xhdpi/ic_voice_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/list_divider_mtrl_alpha.9.png b/core/res/res/drawable-xhdpi/list_divider_mtrl_alpha.9.png
index 77845df..0d2836d 100644
--- a/core/res/res/drawable-xhdpi/list_divider_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xhdpi/list_divider_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/pointer_arrow_icon.xml b/core/res/res/drawable-xhdpi/pointer_arrow_icon.xml
deleted file mode 100644
index 2fbe45a..0000000
--- a/core/res/res/drawable-xhdpi/pointer_arrow_icon.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
-    android:bitmap="@drawable/pointer_arrow"
-    android:hotSpotX="12"
-    android:hotSpotY="12" />
diff --git a/core/res/res/drawable-xhdpi/pointer_spot_anchor.png b/core/res/res/drawable-xhdpi/pointer_spot_anchor.png
index ad41c97..fa9226e 100644
--- a/core/res/res/drawable-xhdpi/pointer_spot_anchor.png
+++ b/core/res/res/drawable-xhdpi/pointer_spot_anchor.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/pointer_spot_hover.png b/core/res/res/drawable-xhdpi/pointer_spot_hover.png
index e9b98f6..f09a778 100644
--- a/core/res/res/drawable-xhdpi/pointer_spot_hover.png
+++ b/core/res/res/drawable-xhdpi/pointer_spot_hover.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/pointer_spot_touch.png b/core/res/res/drawable-xhdpi/pointer_spot_touch.png
index e10d998..53d7a20 100644
--- a/core/res/res/drawable-xhdpi/pointer_spot_touch.png
+++ b/core/res/res/drawable-xhdpi/pointer_spot_touch.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/spinner_textfield_activated_mtrl_alpha.9.png b/core/res/res/drawable-xhdpi/spinner_textfield_activated_mtrl_alpha.9.png
index 2d79d59..8e7862f 100644
--- a/core/res/res/drawable-xhdpi/spinner_textfield_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xhdpi/spinner_textfield_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/spinner_textfield_default_mtrl_alpha.9.png b/core/res/res/drawable-xhdpi/spinner_textfield_default_mtrl_alpha.9.png
index 36f9753..95cb83f 100644
--- a/core/res/res/drawable-xhdpi/spinner_textfield_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xhdpi/spinner_textfield_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/textfield_search_activated_mtrl_alpha.9.png b/core/res/res/drawable-xhdpi/textfield_search_activated_mtrl_alpha.9.png
index 1a2546f..33c1035 100644
--- a/core/res/res/drawable-xhdpi/textfield_search_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xhdpi/textfield_search_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/textfield_search_default_mtrl_alpha.9.png b/core/res/res/drawable-xhdpi/textfield_search_default_mtrl_alpha.9.png
index 500ec33..0226f84 100644
--- a/core/res/res/drawable-xhdpi/textfield_search_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xhdpi/textfield_search_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xhdpi/title_bar_shadow.9.png b/core/res/res/drawable-xhdpi/title_bar_shadow.9.png
deleted file mode 100644
index 45b5456..0000000
--- a/core/res/res/drawable-xhdpi/title_bar_shadow.9.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00001.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00001.9.png
index c30cb5a..1eca9a9 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00001.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00002.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00002.9.png
index eaba558..5427211 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00002.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00003.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00003.9.png
index 17c18c9..43c06ab 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00003.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00004.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00004.9.png
index 0fce07a..6db3f1e 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00004.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00005.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00005.9.png
index c29b837..53b3a62 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00005.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00006.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00006.9.png
index ae56a41..7add520 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00006.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00007.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00007.9.png
index 85290ac..a4d57de 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00007.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00008.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00008.9.png
index 1e8513b..4b3a023 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00008.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00009.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00009.9.png
index 8810a12..a4caa65 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00009.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00010.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00010.9.png
index 717207f..2ab46c0 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00010.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00011.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00011.9.png
index db046f3..5c06e44 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00011.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00012.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00012.9.png
index c5c07a4..60d8c11 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00012.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_off_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00001.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00001.9.png
index c9bdf1f..b149e47 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00001.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00002.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00002.9.png
index 6bfd943..6a12a1f 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00002.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00003.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00003.9.png
index a1d3fbb..2803c7c 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00003.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00004.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00004.9.png
index 40c3a5b..032f6ea 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00004.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00005.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00005.9.png
index 26b8736..ea83c35 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00005.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00006.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00006.9.png
index 88c027e..2801f29 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00006.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00007.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00007.9.png
index 02567c6..66b89b3 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00007.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00008.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00008.9.png
index 037d3bf..1f8770c 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00008.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00009.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00009.9.png
index 0252769..0d6a95b 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00009.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00010.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00010.9.png
index 3ae501d..8e602db 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00010.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00011.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00011.9.png
index ecf2831..3143c1f 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00011.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00012.9.png b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00012.9.png
index 0877749..00fb83e 100644
--- a/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00012.9.png
+++ b/core/res/res/drawable-xxhdpi/btn_switch_to_on_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-xxhdpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index c2d6a54..0000000
--- a/core/res/res/drawable-xxhdpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_corp_icon.png b/core/res/res/drawable-xxhdpi/ic_corp_icon.png
index 68400ea..d33319f 100644
--- a/core/res/res/drawable-xxhdpi/ic_corp_icon.png
+++ b/core/res/res/drawable-xxhdpi/ic_corp_icon.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_dialog_alert_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_dialog_alert_mtrl_alpha.png
deleted file mode 100644
index 10e0756..0000000
--- a/core/res/res/drawable-xxhdpi/ic_dialog_alert_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_go_search_api_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_go_search_api_mtrl_alpha.png
deleted file mode 100644
index 8e1ab5b..0000000
--- a/core/res/res/drawable-xxhdpi/ic_go_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_lockscreen_ime.png b/core/res/res/drawable-xxhdpi/ic_lockscreen_ime.png
deleted file mode 100644
index cb5d2fa..0000000
--- a/core/res/res/drawable-xxhdpi/ic_lockscreen_ime.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_copy_mtrl_am_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_copy_mtrl_am_alpha.png
deleted file mode 100644
index 7c3a58b..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_copy_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_cut_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_cut_mtrl_alpha.png
deleted file mode 100644
index 2200642..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_cut_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_moreoverflow_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_moreoverflow_mtrl_alpha.png
deleted file mode 100644
index ff1759b..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_moreoverflow_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_paste_mtrl_am_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_paste_mtrl_am_alpha.png
deleted file mode 100644
index 28c0ae0..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_paste_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_selectall_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_selectall_mtrl_alpha.png
deleted file mode 100644
index 6430d45..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_selectall_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_menu_share_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_menu_share_mtrl_alpha.png
deleted file mode 100644
index 66f7d16..0000000
--- a/core/res/res/drawable-xxhdpi/ic_menu_share_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_search_api_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_search_api_mtrl_alpha.png
deleted file mode 100644
index 6f60bd3..0000000
--- a/core/res/res/drawable-xxhdpi/ic_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/ic_voice_search_api_mtrl_alpha.png b/core/res/res/drawable-xxhdpi/ic_voice_search_api_mtrl_alpha.png
deleted file mode 100644
index d95f1d0..0000000
--- a/core/res/res/drawable-xxhdpi/ic_voice_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/list_divider_mtrl_alpha.9.png b/core/res/res/drawable-xxhdpi/list_divider_mtrl_alpha.9.png
index 0fafd1a..b8ac46d 100644
--- a/core/res/res/drawable-xxhdpi/list_divider_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxhdpi/list_divider_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/spinner_textfield_activated_mtrl_alpha.9.png b/core/res/res/drawable-xxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
index 9c0b19e..eb495c6 100644
--- a/core/res/res/drawable-xxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/spinner_textfield_default_mtrl_alpha.9.png b/core/res/res/drawable-xxhdpi/spinner_textfield_default_mtrl_alpha.9.png
index 0edb4b8..c2268af 100644
--- a/core/res/res/drawable-xxhdpi/spinner_textfield_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxhdpi/spinner_textfield_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/textfield_search_activated_mtrl_alpha.9.png b/core/res/res/drawable-xxhdpi/textfield_search_activated_mtrl_alpha.9.png
index cd5b00f..b6efff3 100644
--- a/core/res/res/drawable-xxhdpi/textfield_search_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxhdpi/textfield_search_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxhdpi/textfield_search_default_mtrl_alpha.9.png b/core/res/res/drawable-xxhdpi/textfield_search_default_mtrl_alpha.9.png
index 5ee867c..2b253fb 100644
--- a/core/res/res/drawable-xxhdpi/textfield_search_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxhdpi/textfield_search_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00001.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00001.9.png
index bc21279..786f493 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00001.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00002.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00002.9.png
index b57b592..c6e1ac1f 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00002.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00003.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00003.9.png
index 0fb9277..2a65baa 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00003.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00004.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00004.9.png
index 340722d..efce521 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00004.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00005.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00005.9.png
index 8554a76..5566524 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00005.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00006.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00006.9.png
index a05e335..ee676a6 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00006.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00007.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00007.9.png
index a5ded14..e0bb175 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00007.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00008.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00008.9.png
index 0300a49..de9eada 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00008.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00009.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00009.9.png
index 37dd7ce..3c59ad8 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00009.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00010.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00010.9.png
index 6bc549a..d524098 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00010.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00011.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00011.9.png
index b026d5d..7c08d71 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00011.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00012.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00012.9.png
index 89238dc..017c2e1 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00012.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_off_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00001.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00001.9.png
index 1d309fe..d3f2a9a 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00001.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00001.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00002.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00002.9.png
index 2e58fa9..cb75295a 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00002.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00002.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00003.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00003.9.png
index 2ebe7a7..445644e 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00003.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00003.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00004.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00004.9.png
index 04bab76..5819f90 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00004.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00004.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00005.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00005.9.png
index 3497e48..91cb90f 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00005.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00005.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00006.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00006.9.png
index 42333b4..cf6147c 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00006.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00006.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00007.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00007.9.png
index 732e175..75fca7c 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00007.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00007.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00008.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00008.9.png
index 12eddd8..b71a0b4 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00008.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00008.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00009.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00009.9.png
index 95cbc61..edb7671 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00009.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00009.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00010.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00010.9.png
index 105ec07..5e0be17 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00010.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00010.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00011.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00011.9.png
index fac253a..b727eda 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00011.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00011.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00012.9.png b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00012.9.png
index 1b8d11c..a3caefb 100644
--- a/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00012.9.png
+++ b/core/res/res/drawable-xxxhdpi/btn_switch_to_on_mtrl_00012.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/ic_ab_back_mtrl_am_alpha.png b/core/res/res/drawable-xxxhdpi/ic_ab_back_mtrl_am_alpha.png
deleted file mode 100644
index 70c2040..0000000
--- a/core/res/res/drawable-xxxhdpi/ic_ab_back_mtrl_am_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/ic_corp_icon.png b/core/res/res/drawable-xxxhdpi/ic_corp_icon.png
new file mode 100644
index 0000000..359e210
--- /dev/null
+++ b/core/res/res/drawable-xxxhdpi/ic_corp_icon.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/ic_search_api_mtrl_alpha.png b/core/res/res/drawable-xxxhdpi/ic_search_api_mtrl_alpha.png
deleted file mode 100644
index c873e9b..0000000
--- a/core/res/res/drawable-xxxhdpi/ic_search_api_mtrl_alpha.png
+++ /dev/null
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/spinner_textfield_activated_mtrl_alpha.9.png b/core/res/res/drawable-xxxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
index 78c5ebd..fbcd7d4 100644
--- a/core/res/res/drawable-xxxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxxhdpi/spinner_textfield_activated_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable-xxxhdpi/spinner_textfield_default_mtrl_alpha.9.png b/core/res/res/drawable-xxxhdpi/spinner_textfield_default_mtrl_alpha.9.png
index 36974b7..ebc9bf7 100644
--- a/core/res/res/drawable-xxxhdpi/spinner_textfield_default_mtrl_alpha.9.png
+++ b/core/res/res/drawable-xxxhdpi/spinner_textfield_default_mtrl_alpha.9.png
Binary files differ
diff --git a/core/res/res/drawable/btn_borderless_material.xml b/core/res/res/drawable/btn_borderless_material.xml
index 47cc455..08e1060 100644
--- a/core/res/res/drawable/btn_borderless_material.xml
+++ b/core/res/res/drawable/btn_borderless_material.xml
@@ -14,13 +14,8 @@
      limitations under the License.
 -->
 
-<inset xmlns:android="http://schemas.android.com/apk/res/android"
-       android:insetLeft="@dimen/control_inset_material"
-       android:insetTop="@dimen/control_inset_material"
-       android:insetBottom="@dimen/control_inset_material"
-       android:insetRight="@dimen/control_inset_material">
-    <ripple android:color="?attr/colorControlHighlight">
-        <item android:id="@id/mask"
-              android:drawable="@drawable/btn_default_mtrl_shape" />
-    </ripple>
-</inset>
+<ripple xmlns:android="http://schemas.android.com/apk/res/android"
+        android:color="?attr/colorControlHighlight">
+    <item android:id="@id/mask"
+          android:drawable="@drawable/btn_default_mtrl_shape" />
+</ripple>
diff --git a/core/res/res/drawable/btn_default_material.xml b/core/res/res/drawable/btn_default_material.xml
index b04d4fb..ed2b5aa 100644
--- a/core/res/res/drawable/btn_default_material.xml
+++ b/core/res/res/drawable/btn_default_material.xml
@@ -14,12 +14,7 @@
      limitations under the License.
 -->
 
-<inset xmlns:android="http://schemas.android.com/apk/res/android"
-       android:insetLeft="@dimen/control_inset_material"
-       android:insetTop="@dimen/control_inset_material"
-       android:insetBottom="@dimen/control_inset_material"
-       android:insetRight="@dimen/control_inset_material">
-    <ripple android:color="?attr/colorControlHighlight">
-        <item android:drawable="@drawable/btn_default_mtrl_shape" />
-    </ripple>
-</inset>
+<ripple xmlns:android="http://schemas.android.com/apk/res/android"
+        android:color="?attr/colorControlHighlight">
+    <item android:drawable="@drawable/btn_default_mtrl_shape" />
+</ripple>
diff --git a/core/res/res/drawable/btn_default_mtrl_shape.xml b/core/res/res/drawable/btn_default_mtrl_shape.xml
index 9235c76..6d0f7f8 100644
--- a/core/res/res/drawable/btn_default_mtrl_shape.xml
+++ b/core/res/res/drawable/btn_default_mtrl_shape.xml
@@ -15,12 +15,18 @@
 -->
 
 <!-- Used as the canonical button shape. -->
-<shape xmlns:android="http://schemas.android.com/apk/res/android"
-       android:shape="rectangle">
-    <corners android:radius="@dimen/control_corner_material" />
-    <solid android:color="?attr/colorButtonNormal" />
-    <padding android:top="@dimen/control_padding_material"
-             android:bottom="@dimen/control_padding_material"
-             android:left="@dimen/control_padding_material"
-             android:right="@dimen/control_padding_material" />
-</shape>
+
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+       android:insetLeft="@dimen/button_inset_horizontal_material"
+       android:insetTop="@dimen/button_inset_vertical_material"
+       android:insetRight="@dimen/button_inset_horizontal_material"
+       android:insetBottom="@dimen/button_inset_vertical_material">
+    <shape android:shape="rectangle">
+        <corners android:radius="@dimen/control_corner_material" />
+        <solid android:color="?attr/colorButtonNormal" />
+        <padding android:left="@dimen/button_padding_horizontal_material"
+                 android:top="@dimen/button_padding_vertical_material"
+                 android:right="@dimen/button_padding_horizontal_material"
+                 android:bottom="@dimen/button_padding_vertical_material" />
+    </shape>
+</inset>
diff --git a/core/res/res/drawable/btn_toggle_material.xml b/core/res/res/drawable/btn_toggle_material.xml
index a9951e7..f91d4cc 100644
--- a/core/res/res/drawable/btn_toggle_material.xml
+++ b/core/res/res/drawable/btn_toggle_material.xml
@@ -15,10 +15,10 @@
 -->
 
 <inset xmlns:android="http://schemas.android.com/apk/res/android"
-       android:insetLeft="@dimen/control_inset_material"
-       android:insetTop="@dimen/control_inset_material"
-       android:insetBottom="@dimen/control_inset_material"
-       android:insetRight="@dimen/control_inset_material">
+       android:insetLeft="@dimen/button_inset_horizontal_material"
+       android:insetTop="@dimen/button_inset_vertical_material"
+       android:insetRight="@dimen/button_inset_horizontal_material"
+       android:insetBottom="@dimen/button_inset_vertical_material">
     <layer-list android:paddingMode="stack">
         <item>
             <ripple android:color="?attr/colorControlHighlight">
@@ -28,10 +28,10 @@
                         <corners android:topLeftRadius="@dimen/control_corner_material"
                                  android:topRightRadius="@dimen/control_corner_material"/>
                         <solid android:color="?attr/colorButtonNormal" />
-                        <padding android:top="@dimen/control_padding_material"
-                                 android:bottom="@dimen/control_padding_material"
-                                 android:left="@dimen/control_padding_material"
-                                 android:right="@dimen/control_padding_material" />
+                        <padding android:left="@dimen/button_padding_horizontal_material"
+                                 android:top="@dimen/button_padding_vertical_material"
+                                 android:right="@dimen/button_padding_horizontal_material"
+                                 android:bottom="@dimen/button_padding_vertical_material" />
                     </shape>
                 </item>
             </ripple>
diff --git a/core/res/res/drawable/edit_text_material.xml b/core/res/res/drawable/edit_text_material.xml
index eaf5e45..bbc7301 100644
--- a/core/res/res/drawable/edit_text_material.xml
+++ b/core/res/res/drawable/edit_text_material.xml
@@ -15,10 +15,7 @@
 -->
 
 <inset xmlns:android="http://schemas.android.com/apk/res/android"
-    android:insetLeft="@dimen/control_inset_material"
-    android:insetTop="@dimen/control_inset_material"
-    android:insetBottom="@dimen/control_inset_material"
-    android:insetRight="@dimen/control_inset_material">
+        android:inset="@dimen/control_inset_material">
     <ripple android:color="?attr/colorControlActivated">
         <item>
             <selector>
diff --git a/core/res/res/drawable/emulator_circular_window_overlay.xml b/core/res/res/drawable/emulator_circular_window_overlay.xml
new file mode 100644
index 0000000..7616b37
--- /dev/null
+++ b/core/res/res/drawable/emulator_circular_window_overlay.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<!-- Default to an empty shape drawable -->
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+       android:shape="rectangle">
+</shape>
diff --git a/core/res/res/drawable/fastscroll_label_left_material.xml b/core/res/res/drawable/fastscroll_label_left_material.xml
new file mode 100644
index 0000000..430d1b0
--- /dev/null
+++ b/core/res/res/drawable/fastscroll_label_left_material.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <corners
+        android:topLeftRadius="44dp"
+        android:topRightRadius="44dp"
+        android:bottomRightRadius="44dp" />
+    <padding
+        android:paddingLeft="22dp"
+        android:paddingRight="22dp" />
+    <solid android:color="?attr/colorControlActivated" />
+</shape>
diff --git a/core/res/res/drawable/fastscroll_label_right_material.xml b/core/res/res/drawable/fastscroll_label_right_material.xml
new file mode 100644
index 0000000..6e61397
--- /dev/null
+++ b/core/res/res/drawable/fastscroll_label_right_material.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle">
+    <corners
+        android:topLeftRadius="44dp"
+        android:topRightRadius="44dp"
+        android:bottomLeftRadius="44dp" />
+    <padding
+        android:paddingLeft="22dp"
+        android:paddingRight="22dp" />
+    <solid android:color="?attr/colorControlActivated" />
+</shape>
diff --git a/core/res/res/drawable/ic_ab_back_material.xml b/core/res/res/drawable/ic_ab_back_material.xml
index 37455d4..72d7981 100644
--- a/core/res/res/drawable/ic_ab_back_material.xml
+++ b/core/res/res/drawable/ic_ab_back_material.xml
@@ -1,20 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_ab_back_mtrl_am_alpha"
-    android:autoMirrored="true"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:autoMirrored="true"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M20.000000,11.000000L7.800000,11.000000l5.600000,-5.600000L12.000000,4.000000l-8.000000,8.000000l8.000000,8.000000l1.400000,-1.400000L7.800000,13.000000L20.000000,13.000000L20.000000,11.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_account_circle.xml b/core/res/res/drawable/ic_account_circle.xml
new file mode 100644
index 0000000..a8c5b8c
--- /dev/null
+++ b/core/res/res/drawable/ic_account_circle.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:pathData="M24,0C10.8,0 0,10.8 0,24s10.8,24 24,24s24,-10.8 24,-24S37.200001,0 24,0zM24,7.2c3.96,0 7.2,3.24 7.2,7.2s-3.24,7.2 -7.2,7.2s-7.2,-3.24 -7.2,-7.2S20.040001,7.2 24,7.2zM24,41.279999c-6,0 -11.28,-3.12 -14.4,-7.68c0.12,-4.8 9.6,-7.44 14.4,-7.44s14.28,2.64 14.4,7.44C35.279999,38.16 30,41.279999 24,41.279999z"
+        android:fillColor="#FFFFFFFF"/>
+</vector>
diff --git a/core/res/res/drawable/ic_cab_done_material.xml b/core/res/res/drawable/ic_cab_done_material.xml
deleted file mode 100644
index a370288..0000000
--- a/core/res/res/drawable/ic_cab_done_material.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 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.
--->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_cab_done_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
diff --git a/core/res/res/drawable/ic_corp_badge.xml b/core/res/res/drawable/ic_corp_badge.xml
index e185fc4..3a66507 100644
--- a/core/res/res/drawable/ic_corp_badge.xml
+++ b/core/res/res/drawable/ic_corp_badge.xml
@@ -14,27 +14,23 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20.0dp"
-        android:height="20.0dp"
-        android:viewportWidth="20.0"
-        android:viewportHeight="20.0">
-
+        android:width="19.0dp"
+        android:height="19.0dp"
+        android:viewportWidth="19.0"
+        android:viewportHeight="19.0">
     <path
-        android:pathData="M10.0,10.0m-10.0,0.0a10.0,10.0 0.0,1.0 1.0,20.0 0.0a10.0,10.0 0.0,1.0 1.0,-20.0 0.0"
+        android:pathData="M9.5,9.5m-9.5,0a9.5,9.5 0,1 1,19 0a9.5,9.5 0,1 1,-19 0"
         android:fillColor="#FF5722"/>
     <path
-        android:pathData="M11.139,12.149l-0.001,0.0L8.996,12.149l0.0,-0.571L4.738,11.578l-0.002,2.198c0.0,0.589 0.477,1.066 1.066,1.066l8.535,0.0c0.589,0.0 1.066,-0.477 1.066,-1.066l0.0,-2.198l-4.264,0.0L11.139,12.149z"
+        android:pathData="M13.741,6.286l-1.53,0L12.211,5.247l-1.039,-1.039L8.025,4.208L6.986,5.247l0,1.039L5.429,6.286c-0.574,0 -1.034,0.465 -1.034,1.039L4.39,13.039c0.0,0.574 0.465,1.039 1.039,1.039l8.312,0c0.574,0 1.039,-0.465 1.039,-1.039L14.780001,7.325C14.78,6.751 14.316,6.286 13.741,6.286zM11.173,6.286L8.025,6.286L8.025,5.247l3.147,0L11.172,6.286z"
         android:fillColor="#FFFFFF"/>
     <path
-        android:pathData="M8.996,10.006l2.143,0.0l0.0,0.52l4.442,0.0L15.580999,7.909c0.0,-0.589 -0.477,-1.066 -1.066,-1.066l-1.877,0.0L7.544,6.843L5.606,6.843c-0.589,0.0 -1.061,0.477 -1.061,1.066l-0.003,2.617l4.453,0.0L8.996,10.006L8.996,10.006z"
+        android:pathData="M15.172,7.039c0.0,-0.58 -0.501,-1.05 -1.12,-1.05L5.113,5.989c-0.619,0 -1.115,0.47 -1.115,1.05l0.002,2.193c0,0.618 0.5,1.118 1.118,1.118l8.931,0c0.618,0 1.118,-0.5 1.118,-1.118L15.172,7.039z"
         android:fillColor="#FFFFFF"/>
     <path
-        android:pathData="M3.367,3.456 h13.016 v13.016 h-13.016z"
-        android:fillColor="#00000000"/>
+        android:pathData="M3.5,9.812l12,0l0,1l-12,0z"
+        android:fillColor="#FF5722"/>
     <path
-        android:pathData="M7.368,5.263l5.263,0.0l0.0,1.053l-5.263,0.0z"
-        android:fillColor="#FFFFFF"/>
-    <path
-        android:pathData="M8.996,12.149l2.1419992,0.0 0.0010004044,0.0 0.0,-0.5699997 -2.1429996,0.0z"
-        android:fillColor="#00000000"/>
+        android:pathData="M8.567,9.467l2.037,0l0,2.037l-2.037,0z"
+        android:fillColor="#FF5722"/>
 </vector>
diff --git a/core/res/res/drawable/ic_corp_icon_badge.xml b/core/res/res/drawable/ic_corp_icon_badge.xml
index 834ae68..538dade 100644
--- a/core/res/res/drawable/ic_corp_icon_badge.xml
+++ b/core/res/res/drawable/ic_corp_icon_badge.xml
@@ -18,32 +18,27 @@
         android:height="64.0dp"
         android:viewportWidth="64.0"
         android:viewportHeight="64.0">
-
     <path
-        android:fillColor="#33000000"
-        android:pathData="M49.062,50.0m-14.0,0.0a14.0,14.0 0.0,1.0 1.0,28.0 0.0a14.0,14.0 0.0,1.0 1.0,-28.0 0.0"/>
+        android:fillColor="#FF000000"
+        android:pathData="M49.062,50.0m-14.0,0.0a14.0,14.0 0.0,1.0 1.0,28.0 0.0a14.0,14.0 0.0,1.0 1.0,-28.0 0.0"
+        android:fillAlpha="0.2"/>
     <path
-        android:fillColor="#33000000"
-        android:pathData="M49.0,49.5m-14.0,0.0a14.0,14.0 0.0,1.0 1.0,28.0 0.0a14.0,14.0 0.0,1.0 1.0,-28.0 0.0"/>
+        android:fillColor="#FF000000"
+        android:pathData="M49.0,49.5m-14.0,0.0a14.0,14.0 0.0,1.0 1.0,28.0 0.0a14.0,14.0 0.0,1.0 1.0,-28.0 0.0"
+        android:fillAlpha="0.2"/>
     <path
         android:pathData="M49.0,49.0m-14.0,0.0a14.0,14.0 0.0,1.0 1.0,28.0 0.0a14.0,14.0 0.0,1.0 1.0,-28.0 0.0"
         android:fillColor="#FF5722"/>
     <path
-        android:pathData="M50.594,52.009l-3.0,0.0L47.594,51.0l-5.961,0.0l-0.003,3.289c0.0,0.826 0.668,1.494 1.494,1.494l11.948,0.0c0.826,0.0 1.494,-0.668 1.494,-1.494L56.566006,51.0l-5.972,0.0C50.594,51.0 50.594,52.009 50.594,52.009z"
+        android:pathData="M55.801,43.688l-2.837,-0.001l0.0,-1.137l-1.587,-1.588l-4.72,-0.001l-1.588,1.587l0.0,1.137l-2.867,-0.001c-0.94,0.0 -1.691,0.76 -1.691,1.699L40.5,48.654c0.0,0.94 0.76,1.7 1.699,1.7l5.255,0.001l0.0,-1.271l0.225,0.0l2.589,0.0l0.225,0.0l0.0,1.271l5.303,0.001c0.939,0.0 1.7,-0.76 1.7,-1.699l0.002,-3.269C57.5,44.449 56.74,43.689 55.801,43.688zM51.377,43.687l-4.72,-0.001l0.0,-1.137l4.72,0.001L51.377,43.687z"
         android:fillColor="#FFFFFF"/>
     <path
-        android:pathData="M47.594,49.009l3.0,0.0L50.594,50.0l6.22,0.0l0.0,-3.925c0.0,-0.826 -0.668,-1.494 -1.494,-1.494l-2.627,0.0l-7.131,-0.001l-2.713,0.0c-0.826,0.0 -1.486,0.668 -1.486,1.494L41.359,50.0l6.235,0.0L47.594,49.009z"
+        android:pathData="M50.494,52.012l-3.04,0.0l0.0,-0.901l-6.417,0.0l0.0,3.172c0.0,0.94 0.741,1.7 1.68,1.7l12.464,0.003c0.939,0.0 1.702,-0.76 1.703,-1.699l0.0,-3.176l-6.39,0.0L50.494,52.012z"
         android:fillColor="#FFFFFF"/>
     <path
-        android:pathData="M39.714,39.838 h18.221 v18.221 h-18.221z"
+        android:pathData="M40.726,40.726 h16.13 v16.13 h-16.13z"
         android:fillColor="#00000000"/>
     <path
-        android:pathData="M47.594,49.009 h3.0 v0.991 h-3.0z"
+        android:pathData="M46.657,42.55 h4.72 v1.137 h-4.72z"
         android:fillColor="#00000000"/>
-    <path
-        android:pathData="M47.594,51.0 h3.0 v1.009 h-3.0z"
-        android:fillColor="#00000000"/>
-    <path
-        android:pathData="M46.0,43.0l6.0,0.0l0.0,1.0l-6.0,0.0z"
-        android:fillColor="#FFFFFF"/>
 </vector>
diff --git a/core/res/res/drawable/ic_corp_statusbar_icon.xml b/core/res/res/drawable/ic_corp_statusbar_icon.xml
new file mode 100644
index 0000000..e742c0b
--- /dev/null
+++ b/core/res/res/drawable/ic_corp_statusbar_icon.xml
@@ -0,0 +1,30 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M20.801,5.981L17.13,5.98l0.001,-1.471l-2.053,-2.055L8.969,2.453L6.915,4.506L6.914,5.977L3.203,5.976c-1.216,0.0 -2.189,0.983 -2.189,2.199L1.0,12.406c0.0,1.216 0.983,2.2 2.199,2.2L10.0,14.608l0.0,-1.644l0.291,0.0l3.351,0.0l0.291,0.0l0.0,1.645l6.863,0.002c1.216,0.0 2.2,-0.983 2.2,-2.199L23.0,8.181C23.0,6.965 22.017,5.981 20.801,5.981zM15.076,5.979L8.968,5.978l0.001,-1.471l6.108,0.001L15.076,5.979z"
+        android:fillColor="#FFFFFF"/>
+    <path
+        android:pathData="M13.911,16.646L9.978,16.646L9.978,15.48L1.673,15.48l0.0,4.105c0.0,1.216 0.959,2.2 2.175,2.2l16.13,0.004c1.216,0.0 2.203,-0.983 2.203,-2.199l0.0,-4.11l-8.27,0.0L13.910999,16.646z"
+        android:fillColor="#FFFFFF"/>
+    <path
+        android:pathData="M23.657,6.55 h4.72 v1.137 h-4.72z"
+        android:fillColor="#00000000"/>
+</vector>
diff --git a/core/res/res/drawable/ic_dialog_alert_material.xml b/core/res/res/drawable/ic_dialog_alert_material.xml
index 41e1ab1..3bb4d2c 100644
--- a/core/res/res/drawable/ic_dialog_alert_material.xml
+++ b/core/res/res/drawable/ic_dialog_alert_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_dialog_alert_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M1.000000,21.000000l22.000000,0.000000L12.000000,2.000000L1.000000,21.000000zM13.000000,18.000000l-2.000000,0.000000l0.000000,-2.000000l2.000000,0.000000L13.000000,18.000000zM13.000000,14.000000l-2.000000,0.000000l0.000000,-4.000000l2.000000,0.000000L13.000000,14.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_go_search_api_material.xml b/core/res/res/drawable/ic_go_search_api_material.xml
index 03f6cd5..21c7249 100644
--- a/core/res/res/drawable/ic_go_search_api_material.xml
+++ b/core/res/res/drawable/ic_go_search_api_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_go_search_api_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M10.000000,6.000000l-1.400000,1.400000 4.599999,4.600000 -4.599999,4.600000 1.400000,1.400000 6.000000,-6.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_lock_bugreport.xml b/core/res/res/drawable/ic_lock_bugreport.xml
index 8540eee..b0c32e0 100644
--- a/core/res/res/drawable/ic_lock_bugreport.xml
+++ b/core/res/res/drawable/ic_lock_bugreport.xml
@@ -17,9 +17,9 @@
         android:width="32dp"
         android:height="32dp"
         android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
-
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
     <path
-        android:fillColor="?attr/colorControlNormal"
+        android:fillColor="@color/white"
         android:pathData="M20.0,8.0l-2.8,0.0c-0.5,-0.8 -1.1,-1.5 -1.8,-2.0L17.0,4.4L15.6,3.0l-2.2,2.2C13.0,5.1 12.5,5.0 12.0,5.0s-1.0,0.1 -1.4,0.2L8.4,3.0L7.0,4.4L8.6,6.0C7.9,6.5 7.3,7.2 6.8,8.0L4.0,8.0l0.0,2.0l2.1,0.0C6.0,10.3 6.0,10.7 6.0,11.0l0.0,1.0L4.0,12.0l0.0,2.0l2.0,0.0l0.0,1.0c0.0,0.3 0.0,0.7 0.1,1.0L4.0,16.0l0.0,2.0l2.8,0.0c1.0,1.8 3.0,3.0 5.2,3.0s4.2,-1.2 5.2,-3.0L20.0,18.0l0.0,-2.0l-2.1,0.0c0.1,-0.3 0.1,-0.7 0.1,-1.0l0.0,-1.0l2.0,0.0l0.0,-2.0l-2.0,0.0l0.0,-1.0c0.0,-0.3 0.0,-0.7 -0.1,-1.0L20.0,10.0L20.0,8.0zM14.0,16.0l-4.0,0.0l0.0,-2.0l4.0,0.0L14.0,16.0zM14.0,12.0l-4.0,0.0l0.0,-2.0l4.0,0.0L14.0,12.0z"/>
 </vector>
diff --git a/core/res/res/drawable/ic_menu_copy_material.xml b/core/res/res/drawable/ic_menu_copy_material.xml
index 877b5ff..da3912b 100644
--- a/core/res/res/drawable/ic_menu_copy_material.xml
+++ b/core/res/res/drawable/ic_menu_copy_material.xml
@@ -1,20 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_copy_mtrl_am_alpha"
-    android:tint="?attr/colorControlNormal"
-    android:autoMirrored="true" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:autoMirrored="true"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M16.000000,1.000000L4.000000,1.000000C2.900000,1.000000 2.000000,1.900000 2.000000,3.000000l0.000000,14.000000l2.000000,0.000000L4.000000,3.000000l12.000000,0.000000L16.000000,1.000000zM19.000000,5.000000L8.000000,5.000000C6.900000,5.000000 6.000000,5.900000 6.000000,7.000000l0.000000,14.000000c0.000000,1.100000 0.900000,2.000000 2.000000,2.000000l11.000000,0.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L21.000000,7.000000C21.000000,5.900000 20.100000,5.000000 19.000000,5.000000zM19.000000,21.000000L8.000000,21.000000L8.000000,7.000000l11.000000,0.000000L19.000000,21.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_menu_cut_material.xml b/core/res/res/drawable/ic_menu_cut_material.xml
index ff8d6e6..54db72a 100644
--- a/core/res/res/drawable/ic_menu_cut_material.xml
+++ b/core/res/res/drawable/ic_menu_cut_material.xml
@@ -1,19 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_cut_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:autoMirrored="true"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M10.000000,6.000000c0.000000,-2.200000 -1.800000,-4.000000 -4.000000,-4.000000S2.000000,3.800000 2.000000,6.000000c0.000000,2.200000 1.800000,4.000000 4.000000,4.000000c0.600000,0.000000 1.100000,-0.100000 1.600000,-0.400000L10.000000,12.000000l-2.400000,2.400000C7.100000,14.100000 6.600000,14.000000 6.000000,14.000000c-2.200000,0.000000 -4.000000,1.800000 -4.000000,4.000000c0.000000,2.200000 1.800000,4.000000 4.000000,4.000000s4.000000,-1.800000 4.000000,-4.000000c0.000000,-0.600000 -0.100000,-1.100000 -0.400000,-1.600000L12.000000,14.000000l7.000000,7.000000l4.000000,0.000000L9.600000,7.600000C9.900000,7.100000 10.000000,6.600000 10.000000,6.000000zM6.000000,8.000000C4.900000,8.000000 4.000000,7.100000 4.000000,6.000000s0.900000,-2.000000 2.000000,-2.000000c1.100000,0.000000 2.000000,0.900000 2.000000,2.000000S7.100000,8.000000 6.000000,8.000000zM6.000000,20.000000c-1.100000,0.000000 -2.000000,-0.900000 -2.000000,-2.000000s0.900000,-2.000000 2.000000,-2.000000c1.100000,0.000000 2.000000,0.900000 2.000000,2.000000S7.100000,20.000000 6.000000,20.000000zM12.000000,11.500000c0.300000,0.000000 0.500000,0.200000 0.500000,0.500000c0.000000,0.300000 -0.200000,0.500000 -0.500000,0.500000c-0.300000,0.000000 -0.500000,-0.200000 -0.500000,-0.500000C11.500000,11.700000 11.700000,11.500000 12.000000,11.500000zM23.000000,3.000000l-4.000000,0.000000l-6.000000,6.000000l2.000000,2.000000L23.000000,3.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_menu_moreoverflow_material.xml b/core/res/res/drawable/ic_menu_moreoverflow_material.xml
index 16d4f0c..c128570 100644
--- a/core/res/res/drawable/ic_menu_moreoverflow_material.xml
+++ b/core/res/res/drawable/ic_menu_moreoverflow_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_moreoverflow_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M12.000000,8.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000s-0.900000,-2.000000 -2.000000,-2.000000c-1.100000,0.000000 -2.000000,0.900000 -2.000000,2.000000S10.900000,8.000000 12.000000,8.000000zM12.000000,10.000000c-1.100000,0.000000 -2.000000,0.900000 -2.000000,2.000000s0.900000,2.000000 2.000000,2.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000S13.100000,10.000000 12.000000,10.000000zM12.000000,16.000000c-1.100000,0.000000 -2.000000,0.900000 -2.000000,2.000000s0.900000,2.000000 2.000000,2.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000S13.100000,16.000000 12.000000,16.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_menu_paste_material.xml b/core/res/res/drawable/ic_menu_paste_material.xml
index f7bbbf9..5f847cb 100644
--- a/core/res/res/drawable/ic_menu_paste_material.xml
+++ b/core/res/res/drawable/ic_menu_paste_material.xml
@@ -1,20 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_paste_mtrl_am_alpha"
-    android:tint="?attr/colorControlNormal"
-    android:autoMirrored="true" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:autoMirrored="true"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M19.000000,2.000000l-4.200000,0.000000c-0.400000,-1.200000 -1.500000,-2.000000 -2.800000,-2.000000c-1.300000,0.000000 -2.400000,0.800000 -2.800000,2.000000L5.000000,2.000000C3.900000,2.000000 3.000000,2.900000 3.000000,4.000000l0.000000,16.000000c0.000000,1.100000 0.900000,2.000000 2.000000,2.000000l14.000000,0.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L21.000000,4.000000C21.000000,2.900000 20.100000,2.000000 19.000000,2.000000zM12.000000,2.000000c0.600000,0.000000 1.000000,0.400000 1.000000,1.000000s-0.400000,1.000000 -1.000000,1.000000c-0.600000,0.000000 -1.000000,-0.400000 -1.000000,-1.000000S11.400000,2.000000 12.000000,2.000000zM19.000000,20.000000L5.000000,20.000000L5.000000,4.000000l2.000000,0.000000l0.000000,3.000000l10.000000,0.000000L17.000000,4.000000l2.000000,0.000000L19.000000,20.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_menu_selectall_material.xml b/core/res/res/drawable/ic_menu_selectall_material.xml
index a431dd5..11e63fd 100644
--- a/core/res/res/drawable/ic_menu_selectall_material.xml
+++ b/core/res/res/drawable/ic_menu_selectall_material.xml
@@ -1,19 +1,26 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_selectall_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:autoMirrored="true"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M3.000000,5.000000l2.000000,0.000000L5.000000,3.000000C3.900000,3.000000 3.000000,3.900000 3.000000,5.000000zM3.000000,13.000000l2.000000,0.000000l0.000000,-2.000000L3.000000,11.000000L3.000000,13.000000zM7.000000,21.000000l2.000000,0.000000l0.000000,-2.000000L7.000000,19.000000L7.000000,21.000000zM3.000000,9.000000l2.000000,0.000000L5.000000,7.000000L3.000000,7.000000L3.000000,9.000000zM13.000000,3.000000l-2.000000,0.000000l0.000000,2.000000l2.000000,0.000000L13.000000,3.000000zM19.000000,3.000000l0.000000,2.000000l2.000000,0.000000C21.000000,3.900000 20.100000,3.000000 19.000000,3.000000zM5.000000,21.000000l0.000000,-2.000000L3.000000,19.000000C3.000000,20.100000 3.900000,21.000000 5.000000,21.000000zM3.000000,17.000000l2.000000,0.000000l0.000000,-2.000000L3.000000,15.000000L3.000000,17.000000zM9.000000,3.000000L7.000000,3.000000l0.000000,2.000000l2.000000,0.000000L9.000000,3.000000zM11.000000,21.000000l2.000000,0.000000l0.000000,-2.000000l-2.000000,0.000000L11.000000,21.000000zM19.000000,13.000000l2.000000,0.000000l0.000000,-2.000000l-2.000000,0.000000L19.000000,13.000000zM19.000000,21.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000l-2.000000,0.000000L19.000000,21.000000zM19.000000,9.000000l2.000000,0.000000L21.000000,7.000000l-2.000000,0.000000L19.000000,9.000000zM19.000000,17.000000l2.000000,0.000000l0.000000,-2.000000l-2.000000,0.000000L19.000000,17.000000zM15.000000,21.000000l2.000000,0.000000l0.000000,-2.000000l-2.000000,0.000000L15.000000,21.000000zM15.000000,5.000000l2.000000,0.000000L17.000000,3.000000l-2.000000,0.000000L15.000000,5.000000zM7.000000,17.000000l10.000000,0.000000L17.000000,7.000000L7.000000,7.000000L7.000000,17.000000zM9.000000,9.000000l6.000000,0.000000l0.000000,6.000000L9.000000,15.000000L9.000000,9.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_menu_share_material.xml b/core/res/res/drawable/ic_menu_share_material.xml
index d9153af..b7c238f 100644
--- a/core/res/res/drawable/ic_menu_share_material.xml
+++ b/core/res/res/drawable/ic_menu_share_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_share_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M18.000000,16.100000c-0.800000,0.000000 -1.500000,0.300000 -2.000000,0.800000l-7.100000,-4.200000C9.000000,12.500000 9.000000,12.200000 9.000000,12.000000s0.000000,-0.500000 -0.100000,-0.700000L16.000000,7.200000C16.500000,7.700000 17.200001,8.000000 18.000000,8.000000c1.700000,0.000000 3.000000,-1.300000 3.000000,-3.000000s-1.300000,-3.000000 -3.000000,-3.000000s-3.000000,1.300000 -3.000000,3.000000c0.000000,0.200000 0.000000,0.500000 0.100000,0.700000L8.000000,9.800000C7.500000,9.300000 6.800000,9.000000 6.000000,9.000000c-1.700000,0.000000 -2.900000,1.200000 -2.900000,2.900000s1.300000,3.000000 3.000000,3.000000c0.800000,0.000000 1.500000,-0.300000 2.000000,-0.800000l7.100000,4.200000c-0.100000,0.300000 -0.100000,0.500000 -0.100000,0.700000c0.000000,1.600000 1.300000,2.900000 2.900000,2.900000s2.900000,-1.300000 2.900000,-2.900000S19.600000,16.100000 18.000000,16.100000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_search_api_material.xml b/core/res/res/drawable/ic_search_api_material.xml
index bc18398..ac1aae3 100644
--- a/core/res/res/drawable/ic_search_api_material.xml
+++ b/core/res/res/drawable/ic_search_api_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_search_api_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M15.500000,14.000000l-0.800000,0.000000l-0.300000,-0.300000c1.000000,-1.100000 1.600000,-2.600000 1.600000,-4.200000C16.000000,5.900000 13.100000,3.000000 9.500000,3.000000C5.900000,3.000000 3.000000,5.900000 3.000000,9.500000S5.900000,16.000000 9.500000,16.000000c1.600000,0.000000 3.100000,-0.600000 4.200000,-1.600000l0.300000,0.300000l0.000000,0.800000l5.000000,5.000000l1.500000,-1.500000L15.500000,14.000000zM9.500000,14.000000C7.000000,14.000000 5.000000,12.000000 5.000000,9.500000S7.000000,5.000000 9.500000,5.000000C12.000000,5.000000 14.000000,7.000000 14.000000,9.500000S12.000000,14.000000 9.500000,14.000000z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/ic_voice_search_api_material.xml b/core/res/res/drawable/ic_voice_search_api_material.xml
index 05488fb..8c1e803 100644
--- a/core/res/res/drawable/ic_voice_search_api_material.xml
+++ b/core/res/res/drawable/ic_voice_search_api_material.xml
@@ -1,19 +1,25 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 The Android Open Source Project
+<!--
+Copyright (C) 2014 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
+   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
+         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.
+    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.
 -->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_voice_search_api_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24dp"
+        android:height="24dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0"
+        android:tint="?attr/colorControlNormal">
+    <path
+        android:pathData="M12.000000,14.000000c1.700000,0.000000 3.000000,-1.300000 3.000000,-3.000000l0.000000,-6.000000c0.000000,-1.700000 -1.300000,-3.000000 -3.000000,-3.000000c-1.700000,0.000000 -3.000000,1.300000 -3.000000,3.000000l0.000000,6.000000C9.000000,12.700000 10.300000,14.000000 12.000000,14.000000zM17.299999,11.000000c0.000000,3.000000 -2.500000,5.100000 -5.300000,5.100000c-2.800000,0.000000 -5.300000,-2.100000 -5.300000,-5.100000L5.000000,11.000000c0.000000,3.400000 2.700000,6.200000 6.000000,6.700000L11.000000,21.000000l2.000000,0.000000l0.000000,-3.300000c3.300000,-0.500000 6.000000,-3.300000 6.000000,-6.700000L17.299999,11.000001z"
+        android:fillColor="@color/white"/>
+</vector>
diff --git a/core/res/res/drawable/list_divider_material.xml b/core/res/res/drawable/list_divider_material.xml
index bf24933..7ff212a 100644
--- a/core/res/res/drawable/list_divider_material.xml
+++ b/core/res/res/drawable/list_divider_material.xml
@@ -16,4 +16,5 @@
 
 <nine-patch xmlns:android="http://schemas.android.com/apk/res/android"
     android:src="@drawable/list_divider_mtrl_alpha"
-    android:tint="?attr/colorControlNormal" />
+    android:tint="?attr/colorForeground"
+    android:alpha="0.16" />
diff --git a/core/res/res/drawable/notification_icon_legacy_bg_inset.xml b/core/res/res/drawable/notification_icon_legacy_bg_inset.xml
deleted file mode 100644
index 96c5573..0000000
--- a/core/res/res/drawable/notification_icon_legacy_bg_inset.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-  ~ Copyright (C) 2014 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
-  -->
-
-<inset xmlns:android="http://schemas.android.com/apk/res/android"
-       android:drawable="@drawable/notification_icon_legacy_bg" android:insetBottom="8dp"
-       android:insetLeft="8dp" android:insetRight="8dp" android:insetTop="8dp"
-       android:visible="true"/>
diff --git a/core/res/res/drawable/notification_material_action_background.xml b/core/res/res/drawable/notification_material_action_background.xml
new file mode 100644
index 0000000..ff6f69d
--- /dev/null
+++ b/core/res/res/drawable/notification_material_action_background.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<ripple xmlns:android="http://schemas.android.com/apk/res/android"
+        android:color="@color/ripple_material_light">
+    <item android:id="@id/mask"
+          android:drawable="@drawable/btn_default_mtrl_shape" />
+</ripple>
+
diff --git a/core/res/res/drawable/notification_material_media_action_background.xml b/core/res/res/drawable/notification_material_media_action_background.xml
new file mode 100644
index 0000000..8e559d5
--- /dev/null
+++ b/core/res/res/drawable/notification_material_media_action_background.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<ripple xmlns:android="http://schemas.android.com/apk/res/android"
+    android:color="@color/ripple_material_dark" />
diff --git a/core/res/res/drawable/notification_material_media_progress.xml b/core/res/res/drawable/notification_material_media_progress.xml
deleted file mode 100644
index 74d871b..0000000
--- a/core/res/res/drawable/notification_material_media_progress.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 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.
--->
-
-<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:id="@id/background" android:drawable="@color/transparent">
-    </item>
-    <item android:id="@id/secondaryProgress">
-        <scale android:scaleWidth="100%"
-            android:drawable="@color/notification_media_progress" />
-    </item>
-    <item android:id="@id/progress">
-        <scale android:scaleWidth="100%"
-            android:drawable="@color/notification_media_progress" />
-    </item>
-</layer-list>
diff --git a/core/res/res/drawable/pointer_arrow_icon.xml b/core/res/res/drawable/pointer_arrow_icon.xml
new file mode 100644
index 0000000..8f7d658
--- /dev/null
+++ b/core/res/res/drawable/pointer_arrow_icon.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
+    android:bitmap="@drawable/pointer_arrow"
+    android:hotSpotX="6dp"
+    android:hotSpotY="6dp" />
diff --git a/core/res/res/drawable/pointer_spot_anchor_icon.xml b/core/res/res/drawable/pointer_spot_anchor_icon.xml
new file mode 100644
index 0000000..73c0c11
--- /dev/null
+++ b/core/res/res/drawable/pointer_spot_anchor_icon.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
+    android:bitmap="@drawable/pointer_spot_anchor"
+    android:hotSpotX="22dp"
+    android:hotSpotY="22dp" />
diff --git a/core/res/res/drawable/pointer_spot_hover_icon.xml b/core/res/res/drawable/pointer_spot_hover_icon.xml
new file mode 100644
index 0000000..1d7440b
--- /dev/null
+++ b/core/res/res/drawable/pointer_spot_hover_icon.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
+    android:bitmap="@drawable/pointer_spot_hover"
+    android:hotSpotX="22dp"
+    android:hotSpotY="22dp" />
diff --git a/core/res/res/drawable/pointer_spot_touch_icon.xml b/core/res/res/drawable/pointer_spot_touch_icon.xml
new file mode 100644
index 0000000..f4f0639
--- /dev/null
+++ b/core/res/res/drawable/pointer_spot_touch_icon.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<pointer-icon xmlns:android="http://schemas.android.com/apk/res/android"
+    android:bitmap="@drawable/pointer_spot_touch"
+    android:hotSpotX="16dp"
+    android:hotSpotY="16dp" />
diff --git a/core/res/res/drawable/progress_horizontal_material.xml b/core/res/res/drawable/progress_horizontal_material.xml
index d7440a9..6b64337 100644
--- a/core/res/res/drawable/progress_horizontal_material.xml
+++ b/core/res/res/drawable/progress_horizontal_material.xml
@@ -17,13 +17,14 @@
 <layer-list xmlns:android="http://schemas.android.com/apk/res/android">
     <item android:id="@id/background">
         <nine-patch android:src="@drawable/progress_mtrl_alpha"
-            android:tint="?attr/colorControlNormal" />
+            android:tint="?attr/colorControlNormal"
+            android:alpha="?attr/disabledAlpha" />
     </item>
     <item android:id="@id/secondaryProgress">
         <scale android:scaleWidth="100%">
             <nine-patch android:src="@drawable/progress_mtrl_alpha"
                 android:tint="?attr/colorControlActivated"
-                android:alpha="0.5" />
+                android:alpha="?attr/disabledAlpha" />
         </scale>
     </item>
     <item android:id="@id/progress">
diff --git a/core/res/res/drawable/progress_indeterminate_horizontal_material.xml b/core/res/res/drawable/progress_indeterminate_horizontal_material.xml
index 4fc68ce..9ffe1ea 100644
--- a/core/res/res/drawable/progress_indeterminate_horizontal_material.xml
+++ b/core/res/res/drawable/progress_indeterminate_horizontal_material.xml
@@ -1,6 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright (C) 2014 The Android Open Source Project
+<!-- Copyright (C) 2014 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.
@@ -14,20 +13,13 @@
      See the License for the specific language governing permissions and
      limitations under the License.
 -->
+
 <animated-vector xmlns:android="http://schemas.android.com/apk/res/android"
     android:drawable="@drawable/vector_drawable_progress_indeterminate_horizontal" >
-
     <target
-        android:name="path1"
-        android:animation="@anim/progress_indeterminate_horizontal_rect1_translate" />
+        android:name="rect2_grp"
+        android:animation="@anim/progress_indeterminate_horizontal_rect2" />
     <target
-        android:name="path1"
-        android:animation="@anim/progress_indeterminate_horizontal_rect1_scale" />
-
-    <target
-        android:name="path2"
-        android:animation="@anim/progress_indeterminate_horizontal_rect2_translate" />
-    <target
-        android:name="path2"
-        android:animation="@anim/progress_indeterminate_horizontal_rect2_scale" />
+        android:name="rect1_grp"
+        android:animation="@anim/progress_indeterminate_horizontal_rect1" />
 </animated-vector>
diff --git a/core/res/res/drawable/spinner_textfield_background_material.xml b/core/res/res/drawable/spinner_textfield_background_material.xml
index f818baf..5bdff4a 100644
--- a/core/res/res/drawable/spinner_textfield_background_material.xml
+++ b/core/res/res/drawable/spinner_textfield_background_material.xml
@@ -14,18 +14,20 @@
      limitations under the License.
 -->
 
-<selector xmlns:android="http://schemas.android.com/apk/res/android"
-    android:autoMirrored="true">
-    <item android:state_checked="true">
-        <nine-patch android:src="@drawable/spinner_textfield_activated_mtrl_alpha"
-            android:tint="?attr/colorControlActivated" />
-    </item>
-    <item android:state_pressed="true">
-        <nine-patch android:src="@drawable/spinner_textfield_activated_mtrl_alpha"
-            android:tint="?attr/colorControlActivated" />
-    </item>
-    <item>
-        <nine-patch android:src="@drawable/spinner_textfield_default_mtrl_alpha"
-            android:tint="?attr/colorControlNormal" />
-    </item>
-</selector>
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+       android:inset="@dimen/control_inset_material">
+    <selector android:autoMirrored="true">
+        <item android:state_checked="true">
+            <nine-patch android:src="@drawable/spinner_textfield_activated_mtrl_alpha"
+                android:tint="?attr/colorControlActivated" />
+        </item>
+        <item android:state_pressed="true">
+            <nine-patch android:src="@drawable/spinner_textfield_activated_mtrl_alpha"
+                android:tint="?attr/colorControlActivated" />
+        </item>
+        <item>
+            <nine-patch android:src="@drawable/spinner_textfield_default_mtrl_alpha"
+                android:tint="?attr/colorControlNormal" />
+        </item>
+    </selector>
+</inset>
diff --git a/core/res/res/drawable/stat_notify_disabled_data.xml b/core/res/res/drawable/stat_notify_disabled_data.xml
index 2f6ffaf..9089d08 100644
--- a/core/res/res/drawable/stat_notify_disabled_data.xml
+++ b/core/res/res/drawable/stat_notify_disabled_data.xml
@@ -18,17 +18,7 @@
         android:height="24dp"
         android:viewportWidth="48.0"
         android:viewportHeight="48.0">
-
     <path
         android:fillColor="#FFFFFFFF"
-        android:pathData="M40.709,4.5l-6.604,7.337 0.0,16.601 6.604,6.604z"/>
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M32.305,13.838l-6.0629997,6.7370005 6.0629997,6.0629997z"/>
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M15.498,40.5l0.0,-7.9869995 -7.205,7.9869995z"/>
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M10.265,9.72l-2.5460005,2.545 9.971001,9.971 3.7139988,3.7140007 -4.105999,4.5619984 0.0,9.988001 6.6019993,0.0 0.0,-12.054001 1.8029995,1.8030014 0.0,10.250999 6.602001,0.0 0.0,-3.6479988 1.7999992,1.7999992 1.8479996,1.8479996 4.670002,4.669998 2.5459976,-2.5459976z"/>
+        android:pathData="M26.000000,4.100000l0.000000,6.100000c6.800000,1.000000 12.000000,6.800000 12.000000,13.800000c0.000000,1.800000 -0.400000,3.500000 -1.000000,5.100000l5.200000,3.100000c1.100000,-2.500000 1.800000,-5.200000 1.800000,-8.100000C44.000000,13.600000 36.099998,5.100000 26.000000,4.100000zM24.000000,38.000000c-7.700000,0.000000 -14.000000,-6.300000 -14.000000,-14.000000c0.000000,-7.100000 5.200000,-12.900000 12.000000,-13.800000L22.000000,4.100000C11.900000,5.100000 4.000000,13.600000 4.000000,24.000000c0.000000,11.000000 8.900000,20.000000 20.000000,20.000000c6.600000,0.000000 12.500000,-3.200000 16.100000,-8.200000l-5.200000,-3.100000C32.299999,36.000000 28.400000,38.000000 24.000000,38.000000z"/>
 </vector>
diff --git a/core/res/res/drawable/stat_sys_tether_wifi.xml b/core/res/res/drawable/stat_sys_tether_wifi.xml
index a816db8..4396962 100644
--- a/core/res/res/drawable/stat_sys_tether_wifi.xml
+++ b/core/res/res/drawable/stat_sys_tether_wifi.xml
@@ -14,11 +14,12 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="26.0dp"
+        android:width="24.0dp"
         android:height="24.0dp"
-        android:viewportWidth="26.0"
-        android:viewportHeight="24.0">
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+
     <path
         android:fillColor="#FFFFFFFF"
-        android:pathData="M13.000000,22.000000L25.600000,6.500000C25.100000,6.100000 20.299999,2.100000 13.000000,2.100000S0.900000,6.100000 0.400000,6.500000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000z"/>
+        android:pathData="M24.000000,22.000000c-2.200000,0.000000 -4.000000,1.800000 -4.000000,4.000000c0.000000,2.200000 1.800000,4.000000 4.000000,4.000000c2.200000,0.000000 4.000000,-1.800000 4.000000,-4.000000C28.000000,23.799999 26.200001,22.000000 24.000000,22.000000zM36.000000,26.000000c0.000000,-6.600000 -5.400000,-12.000000 -12.000000,-12.000000c-6.600000,0.000000 -12.000000,5.400000 -12.000000,12.000000c0.000000,4.400000 2.400000,8.300000 6.000000,10.400000l2.000000,-3.500000c-2.400000,-1.400000 -4.000000,-3.900000 -4.000000,-6.900000c0.000000,-4.400000 3.600000,-8.000000 8.000000,-8.000000s8.000000,3.600000 8.000000,8.000000c0.000000,3.000000 -1.600000,5.500000 -4.000000,6.900000l2.000000,3.500000C33.599998,34.299999 36.000000,30.400000 36.000000,26.000000zM24.000000,6.000000C13.000000,6.000000 4.000000,15.000000 4.000000,26.000000c0.000000,7.400000 4.000000,13.800000 10.000000,17.299999l2.000000,-3.500000c-4.800000,-2.800000 -8.000000,-7.900000 -8.000000,-13.800000c0.000000,-8.800000 7.200000,-16.000000 16.000000,-16.000000s16.000000,7.200000 16.000000,16.000000c0.000000,5.900000 -3.200000,11.100000 -8.000000,13.800000l2.000000,3.500000c6.000000,-3.500000 10.000000,-9.900000 10.000000,-17.299999C44.000000,15.000000 35.000000,6.000000 24.000000,6.000000z"/>
 </vector>
diff --git a/core/res/res/drawable/switch_thumb_material_anim.xml b/core/res/res/drawable/switch_thumb_material_anim.xml
index 30bc8882..0d4d78e 100644
--- a/core/res/res/drawable/switch_thumb_material_anim.xml
+++ b/core/res/res/drawable/switch_thumb_material_anim.xml
@@ -16,22 +16,12 @@
 
 <animated-selector xmlns:android="http://schemas.android.com/apk/res/android"
     android:constantSize="true">
-    <item
-        android:state_enabled="false"
-        android:state_checked="true">
-        <nine-patch
-            android:src="@drawable/btn_switch_to_on_mtrl_00012"
-            android:gravity="center"
-            android:tintMode="multiply"
-            android:tint="?attr/colorControlActivated"
-            android:alpha="?attr/disabledAlpha" />
-    </item>
-    <item android:state_enabled="false">
+    <item android:state_enabled="false" android:id="@+id/off">
         <nine-patch
             android:src="@drawable/btn_switch_to_on_mtrl_00001"
             android:gravity="center"
             android:tintMode="multiply"
-            android:tint="?attr/colorButtonNormal" />
+            android:tint="?attr/colorSwitchThumbNormal" />
     </item>
     <item
         android:state_checked="true"
@@ -47,29 +37,29 @@
             android:src="@drawable/btn_switch_to_on_mtrl_00001"
             android:gravity="center"
             android:tintMode="multiply"
-            android:tint="?attr/colorButtonNormal" />
+            android:tint="?attr/colorSwitchThumbNormal" />
     </item>
     <transition
         android:fromId="@+id/off"
         android:toId="@+id/on">
         <animation-list>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00001" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00001" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00002" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00002" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00003" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00003" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00004" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00004" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00005" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00005" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00006" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00006" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
                 <nine-patch android:src="@drawable/btn_switch_to_on_mtrl_00007" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorControlActivated" />
@@ -112,22 +102,22 @@
                 <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00006" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorControlActivated" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00007" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00007" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00008" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00008" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00009" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00009" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00010" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00010" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00011" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00011" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
             <item android:duration="15">
-                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00012" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorButtonNormal" />
+                <nine-patch android:src="@drawable/btn_switch_to_off_mtrl_00012" android:gravity="center" android:tintMode="multiply" android:tint="?attr/colorSwitchThumbNormal" />
             </item>
         </animation-list>
     </transition>
diff --git a/core/res/res/drawable/switch_track_material.xml b/core/res/res/drawable/switch_track_material.xml
index 0728055..1ec2f88 100644
--- a/core/res/res/drawable/switch_track_material.xml
+++ b/core/res/res/drawable/switch_track_material.xml
@@ -15,10 +15,10 @@
 -->
 
 <selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_enabled="false" android:state_checked="true">
+    <item android:state_enabled="false">
         <nine-patch android:src="@drawable/switch_track_mtrl_alpha"
-            android:tint="?attr/colorControlActivated"
-            android:alpha="0.2" />
+            android:tint="?attr/colorForeground"
+            android:alpha="0.1" />
     </item>
     <item android:state_checked="true">
         <nine-patch android:src="@drawable/switch_track_mtrl_alpha"
@@ -27,7 +27,7 @@
     </item>
     <item>
         <nine-patch android:src="@drawable/switch_track_mtrl_alpha"
-            android:tint="?attr/colorButtonNormal"
+            android:tint="?attr/colorForeground"
             android:alpha="0.3" />
     </item>
 </selector>
diff --git a/core/res/res/drawable/time_picker_header_material.xml b/core/res/res/drawable/time_picker_header_material.xml
new file mode 100644
index 0000000..cdb92b6
--- /dev/null
+++ b/core/res/res/drawable/time_picker_header_material.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<ripple xmlns:android="http://schemas.android.com/apk/res/android"
+    android:color="?attr/colorControlHighlight">
+    <item>
+        <color android:color="?attr/colorAccent" />
+    </item>
+</ripple>
diff --git a/core/res/res/drawable/title_bar_shadow.xml b/core/res/res/drawable/title_bar_shadow.xml
new file mode 100644
index 0000000..37b0b8f
--- /dev/null
+++ b/core/res/res/drawable/title_bar_shadow.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<shape xmlns:android="http://schemas.android.com/apk/res/android">
+    <gradient
+        android:startColor="#44000000"
+        android:centerColor="#1C000000"
+        android:endColor="#00000000"
+        android:centerY="0.3"
+        android:centerX="0.5"
+        android:angle="270"/>
+</shape>
\ No newline at end of file
diff --git a/core/res/res/drawable/vector_drawable_progress_bar_large.xml b/core/res/res/drawable/vector_drawable_progress_bar_large.xml
index 3bf3cd7..023f5cc 100644
--- a/core/res/res/drawable/vector_drawable_progress_bar_large.xml
+++ b/core/res/res/drawable/vector_drawable_progress_bar_large.xml
@@ -28,7 +28,7 @@
             android:fillColor="#00000000"
             android:pathData="M0, 0 m 0, -19 a 19,19 0 1,1 0,38 a 19,19 0 1,1 0,-38"
             android:strokeColor="?attr/colorControlActivated"
-            android:strokeLineCap="round"
+            android:strokeLineCap="square"
             android:strokeLineJoin="miter"
             android:strokeWidth="4"
             android:trimPathEnd="0"
diff --git a/core/res/res/drawable/vector_drawable_progress_bar_medium.xml b/core/res/res/drawable/vector_drawable_progress_bar_medium.xml
index 62f9225..e72097e 100644
--- a/core/res/res/drawable/vector_drawable_progress_bar_medium.xml
+++ b/core/res/res/drawable/vector_drawable_progress_bar_medium.xml
@@ -28,7 +28,7 @@
             android:fillColor="#00000000"
             android:pathData="M0, 0 m 0, -19 a 19,19 0 1,1 0,38 a 19,19 0 1,1 0,-38"
             android:strokeColor="?attr/colorControlActivated"
-            android:strokeLineCap="round"
+            android:strokeLineCap="square"
             android:strokeLineJoin="miter"
             android:strokeWidth="4"
             android:trimPathEnd="0"
diff --git a/core/res/res/drawable/vector_drawable_progress_bar_small.xml b/core/res/res/drawable/vector_drawable_progress_bar_small.xml
index 1352cfc..875e7a3 100644
--- a/core/res/res/drawable/vector_drawable_progress_bar_small.xml
+++ b/core/res/res/drawable/vector_drawable_progress_bar_small.xml
@@ -28,7 +28,7 @@
             android:fillColor="#00000000"
             android:pathData="M0, 0 m 0, -19 a 19,19 0 1,1 0,38 a 19,19 0 1,1 0,-38"
             android:strokeColor="?attr/colorControlActivated"
-            android:strokeLineCap="round"
+            android:strokeLineCap="square"
             android:strokeLineJoin="miter"
             android:strokeWidth="4"
             android:trimPathEnd="0"
diff --git a/core/res/res/drawable/vector_drawable_progress_indeterminate_horizontal.xml b/core/res/res/drawable/vector_drawable_progress_indeterminate_horizontal.xml
index 0cc7202..aa75a7a 100644
--- a/core/res/res/drawable/vector_drawable_progress_indeterminate_horizontal.xml
+++ b/core/res/res/drawable/vector_drawable_progress_indeterminate_horizontal.xml
@@ -1,5 +1,5 @@
-<!--
- Copyright (C) 2014 The Android Open Source Project
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
@@ -13,48 +13,38 @@
      See the License for the specific language governing permissions and
      limitations under the License.
 -->
-<!--
- Copyright (C) 2014 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.
--->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-    android:height="4dp"
-    android:viewportHeight="4"
-    android:viewportWidth="360"
-    android:width="360dp" >
-
+    android:height="10dp"
+    android:width="360dp"
+    android:viewportHeight="10"
+    android:viewportWidth="360" >
     <group
-        android:name="linear_indeterminate"
-        android:translateX="180.0"
-        android:translateY="0.0" >
+        android:name="progress_group"
+        android:translateX="180"
+        android:translateY="5" >
+        <path
+            android:name="background_track"
+            android:pathData="M -180.0,-1.0 l 360.0,0 l 0,2.0 l -360.0,0 Z"
+            android:fillColor="?attr/colorControlActivated"
+            android:fillAlpha="0.1"/>
         <group
-            android:name="path1"
-            android:scaleX="0.1"
-            android:translateX="-522.59" >
-            <path
-                android:name="rect1"
-                android:fillColor="?attr/colorControlActivated"
-                android:pathData="m 0 1.6 l 288 0 l 0 0.8 l -288 0 z" />
-        </group>
-        <group
-            android:name="path2"
-            android:scaleX="0.1"
-            android:translateX="-197.6" >
+            android:name="rect2_grp"
+            android:translateX="-197.60001"
+            android:scaleX="0.1" >
             <path
                 android:name="rect2"
-                android:fillColor="?attr/colorControlActivated"
-                android:pathData="m 0 1.6 l 288 0 l 0 0.8 l -288 0 z" />
+                android:pathData="M -144.0,-1.0 l 288.0,0 l 0,2.0 l -288.0,0 Z"
+                android:fillColor="?attr/colorControlActivated" />
+        </group>
+        <group
+            android:name="rect1_grp"
+            android:translateX="-522.59998"
+            android:scaleX="0.1" >
+            <path
+                android:name="rect1"
+                android:pathData="M -144.0,-1.0 l 288.0,0 l 0,2.0 l -288.0,0 Z"
+                android:fillColor="?attr/colorControlActivated" />
         </group>
     </group>
-</vector>
\ No newline at end of file
+</vector>
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_scalex.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_scalex.xml
new file mode 100644
index 0000000..4349d7d
--- /dev/null
+++ b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_scalex.xml
@@ -0,0 +1,17 @@
+<!-- Copyright (C) 2014 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.
+-->
+
+<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
+    android:pathData="M 0 0 L 0.3665 0 C 0.47252618112021,0.062409910275 0.61541608570164,0.5 0.68325,0.5 C 0.75475061236836,0.5 0.75725829093844,0.814510098964 1.0,1.0" />
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_translatex.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_translatex.xml
new file mode 100644
index 0000000..c33f709
--- /dev/null
+++ b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_translatex.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
+    android:pathData="M 0.0,0.0 L 0.2 0 C 0.3958333333336,0.0 0.474845090492,0.206797621729 0.5916666666664,0.417082932942 C 0.7151610251224,0.639379624869 0.81625,0.974556908664 1.0,1.0 " />
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_scalex.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_scalex.xml
new file mode 100644
index 0000000..c36411d
--- /dev/null
+++ b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_scalex.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
+    android:pathData="M 0,0 C 0.06834272400867,0.01992566661414 0.19220331656133,0.15855429260523 0.33333333333333,0.34926160892842 C 0.38410433133433,0.41477913453861 0.54945792615267,0.68136029463551 0.66666666666667,0.68279962777002 C 0.752586273196,0.68179620963216 0.737253971954,0.878896194318 1,1" />
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_translatex.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_translatex.xml
new file mode 100644
index 0000000..6c04204
--- /dev/null
+++ b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_translatex.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
+    android:pathData="M 0.0,0.0 C 0.0375,0.0 0.128764607715,0.0895380946618 0.25,0.218553507947 C 0.322410320025,0.295610602487 0.436666666667,0.417591408114 0.483333333333,0.489826169306 C 0.69,0.80972296795 0.793333333333,0.950016125212 1.0,1.0 " />
diff --git a/core/res/res/layout-land/time_picker_holo.xml b/core/res/res/layout-land/time_picker_holo.xml
index 3b3d63c..ce90a5b 100644
--- a/core/res/res/layout-land/time_picker_holo.xml
+++ b/core/res/res/layout-land/time_picker_holo.xml
@@ -18,30 +18,28 @@
 -->
 
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-        android:layout_width="match_parent"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:orientation="horizontal"
+    android:layout_marginLeft="@dimen/timepicker_minimum_margin_sides"
+    android:layout_marginRight="@dimen/timepicker_minimum_margin_sides"
+    android:layout_marginTop="@dimen/timepicker_minimum_margin_top_bottom"
+    android:layout_marginBottom="@dimen/timepicker_minimum_margin_top_bottom">
+    <FrameLayout
+        android:layout_width="0dp"
         android:layout_height="match_parent"
-        android:orientation="horizontal"
-        android:focusable="true"
-        android:layout_marginLeft="@dimen/timepicker_minimum_margin_sides"
-        android:layout_marginRight="@dimen/timepicker_minimum_margin_sides"
-        android:layout_marginTop="@dimen/timepicker_minimum_margin_top_bottom"
-        android:layout_marginBottom="@dimen/timepicker_minimum_margin_top_bottom">
-    <LinearLayout
-            android:layout_width="@dimen/timepicker_left_side_width"
-            android:layout_height="match_parent"
-            android:orientation="vertical">
+        android:layout_weight="1"
+        android:minWidth="@dimen/timepicker_left_side_width"
+        android:orientation="vertical">
         <include
-                layout="@layout/time_header_label"
-                android:layout_width="match_parent"
-                android:layout_height="0dip"
-                android:layout_weight="1"
-                android:layout_gravity="center" />
-    </LinearLayout>
+            layout="@layout/time_header_label"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:layout_gravity="center" />
+    </FrameLayout>
     <android.widget.RadialTimePickerView
         android:id="@+id/radial_picker"
         android:layout_width="@dimen/timepicker_radial_picker_dimen"
         android:layout_height="match_parent"
-        android:layout_gravity="center"
-        android:focusable="true"
-        android:focusableInTouchMode="true" />
+        android:layout_gravity="center" />
 </LinearLayout>
diff --git a/core/res/res/layout-sw600dp/date_picker_holo.xml b/core/res/res/layout-sw600dp/date_picker_holo.xml
deleted file mode 100644
index e5c886b..0000000
--- a/core/res/res/layout-sw600dp/date_picker_holo.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-     Copyright (C) 2011 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.
--->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:layout_width="wrap_content"
-              android:layout_height="match_parent"
-              android:gravity="center"
-              android:orientation="vertical" >
-
-    <include
-        layout="@layout/date_picker_selected_date"
-        android:layout_width="wrap_content"
-        android:layout_height="@dimen/datepicker_selected_calendar_layout_height" />
-
-    <include layout="@layout/date_picker_view_animator" />
-
-</LinearLayout>
diff --git a/core/res/res/layout/action_menu_item_layout.xml b/core/res/res/layout/action_menu_item_layout.xml
index 04d1f7b..6961f8d 100644
--- a/core/res/res/layout/action_menu_item_layout.xml
+++ b/core/res/res/layout/action_menu_item_layout.xml
@@ -25,5 +25,4 @@
     android:paddingStart="8dip"
     android:paddingEnd="8dip"
     android:textAppearance="?attr/actionMenuTextAppearance"
-    android:textColor="?attr/actionMenuTextColor"
-    style="?android:attr/actionButtonStyle" />
+    style="?attr/actionButtonStyle" />
diff --git a/core/res/res/layout/action_mode_close_item_material.xml b/core/res/res/layout/action_mode_close_item_material.xml
new file mode 100644
index 0000000..89a1797
--- /dev/null
+++ b/core/res/res/layout/action_mode_close_item_material.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2011 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.
+-->
+
+<ImageButton xmlns:android="http://schemas.android.com/apk/res/android"
+        android:id="@+id/action_mode_close_button"
+        android:focusable="true"
+        android:clickable="true"
+        android:paddingStart="8dip"
+        android:src="?android:attr/actionModeCloseDrawable"
+        android:contentDescription="@string/action_mode_done"
+        style="?android:attr/actionModeCloseButtonStyle"
+        android:layout_width="wrap_content"
+        android:layout_height="match_parent"
+        android:layout_marginEnd="16dip" />
diff --git a/core/res/res/layout/alert_dialog_leanback_button_panel_right.xml b/core/res/res/layout/alert_dialog_leanback_button_panel_right.xml
deleted file mode 100644
index 829d5aa..0000000
--- a/core/res/res/layout/alert_dialog_leanback_button_panel_right.xml
+++ /dev/null
@@ -1,134 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-     Copyright (C) 2014 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.
--->
-
-<LinearLayout
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/parentPanel"
-    android:layout_width="match_parent"
-    android:layout_height="wrap_content"
-    android:orientation="horizontal"
-    android:background="@drawable/dialog_background_material"
-    android:translationZ="@dimen/floating_window_z"
-    android:layout_marginLeft="@dimen/leanback_alert_dialog_horizontal_margin"
-    android:layout_marginTop="@dimen/leanback_alert_dialog_vertical_margin"
-    android:layout_marginRight="@dimen/leanback_alert_dialog_horizontal_margin"
-    android:layout_marginBottom="@dimen/leanback_alert_dialog_vertical_margin">
-
-   <LinearLayout
-       android:id="@+id/leftPanel"
-       android:layout_width="0dp"
-       android:layout_weight="1"
-       android:layout_height="wrap_content"
-       android:orientation="vertical">
-
-    <LinearLayout android:id="@+id/topPanel"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:orientation="vertical">
-        <LinearLayout android:id="@+id/title_template"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:orientation="horizontal"
-            android:gravity="center_vertical|start"
-            android:paddingStart="16dip"
-            android:paddingEnd="16dip"
-            android:paddingTop="16dip">
-            <ImageView android:id="@+id/icon"
-                android:layout_width="32dip"
-                android:layout_height="32dip"
-                android:layout_marginEnd="8dip"
-                android:scaleType="fitCenter"
-                android:src="@null" />
-            <TextView android:id="@+id/alertTitle"
-                style="?attr/windowTitleStyle"
-                android:singleLine="true"
-                android:ellipsize="end"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:textAlignment="viewStart" />
-        </LinearLayout>
-        <!-- If the client uses a customTitle, it will be added here. -->
-    </LinearLayout>
-
-    <LinearLayout android:id="@+id/contentPanel"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:orientation="vertical"
-        android:minHeight="64dp">
-        <ScrollView android:id="@+id/scrollView"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:clipToPadding="false">
-            <TextView android:id="@+id/message"
-                style="?attr/textAppearanceMedium"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:paddingStart="16dip"
-                android:paddingEnd="16dip"
-                android:paddingTop="16dip"
-		android:paddingBottom="16dip" />
-        </ScrollView>
-    </LinearLayout>
-
-    <FrameLayout android:id="@+id/customPanel"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:minHeight="64dp">
-        <FrameLayout android:id="@+android:id/custom"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content" />
-    </FrameLayout>
-    </LinearLayout>
-
-    <LinearLayout android:id="@+id/buttonPanel"
-        android:layout_width="wrap_content"
-android:background="#ffffff"
-        android:layout_height="wrap_content"
-	android:layout_gravity="center_vertical"
-        android:minHeight="@dimen/alert_dialog_button_bar_height"
-        android:orientation="vertical"
-        android:gravity="end"
-        android:padding="16dip">
-        <LinearLayout
-            style="?attr/buttonBarStyle"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layoutDirection="locale"
-	    android:orientation="vertical">
-            <Button android:id="@+id/button3"
-                style="?attr/buttonBarButtonStyle"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-            <Button android:id="@+id/button2"
-                style="?attr/buttonBarButtonStyle"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-            <Button android:id="@+id/button1"
-                style="?attr/buttonBarButtonStyle"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-        </LinearLayout>
-     </LinearLayout>
-</LinearLayout>
diff --git a/core/res/res/layout/alert_dialog_leanback_button_panel_side.xml b/core/res/res/layout/alert_dialog_leanback_button_panel_side.xml
new file mode 100644
index 0000000..c6e8b3b
--- /dev/null
+++ b/core/res/res/layout/alert_dialog_leanback_button_panel_side.xml
@@ -0,0 +1,126 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+     Copyright (C) 2014 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.
+-->
+
+<LinearLayout
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@+id/parentPanel"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:orientation="horizontal">
+
+   <LinearLayout
+       android:id="@+id/leftPanel"
+       android:layout_width="0dp"
+       android:layout_weight="1"
+       android:layout_height="wrap_content"
+       android:orientation="vertical">
+
+    <LinearLayout android:id="@+id/topPanel"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:orientation="vertical">
+        <LinearLayout android:id="@+id/title_template"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="horizontal"
+            android:gravity="center_vertical|start"
+            android:paddingStart="16dip"
+            android:paddingEnd="16dip"
+            android:paddingTop="16dip"
+            android:paddingBottom="8dip">
+            <ImageView android:id="@+id/icon"
+                android:layout_width="32dip"
+                android:layout_height="32dip"
+                android:layout_marginEnd="8dip"
+                android:scaleType="fitCenter"
+                android:src="@null" />
+            <com.android.internal.widget.DialogTitle android:id="@+id/alertTitle"
+                style="?attr/windowTitleStyle"
+                android:singleLine="true"
+                android:ellipsize="end"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:textAlignment="viewStart" />
+        </LinearLayout>
+        <!-- If the client uses a customTitle, it will be added here. -->
+    </LinearLayout>
+
+    <LinearLayout android:id="@+id/contentPanel"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_weight="1"
+        android:orientation="vertical"
+        android:minHeight="64dp">
+        <ScrollView android:id="@+id/scrollView"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:clipToPadding="false">
+            <TextView android:id="@+id/message"
+                style="?attr/textAppearanceMedium"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:paddingStart="16dip"
+                android:paddingEnd="16dip"
+                android:paddingTop="16dip"
+                android:paddingBottom="16dip" />
+        </ScrollView>
+    </LinearLayout>
+
+    <FrameLayout android:id="@+id/customPanel"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_weight="1"
+        android:minHeight="64dp">
+        <FrameLayout android:id="@+id/custom"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content" />
+    </FrameLayout>
+    </LinearLayout>
+
+    <LinearLayout android:id="@+id/buttonPanel"
+        style="?attr/buttonBarStyle"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_gravity="center_vertical"
+        android:orientation="vertical"
+        android:gravity="end">
+        <LinearLayout
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layoutDirection="locale"
+            android:orientation="vertical">
+            <Button android:id="@+id/button3"
+                style="?attr/buttonBarNeutralButtonStyle"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:maxLines="2"
+                android:minHeight="@dimen/alert_dialog_button_bar_height" />
+            <Button android:id="@+id/button2"
+                style="?attr/buttonBarNegativeButtonStyle"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:maxLines="2"
+                android:minHeight="@dimen/alert_dialog_button_bar_height" />
+            <Button android:id="@+id/button1"
+                style="?attr/buttonBarPositiveButtonStyle"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:maxLines="2"
+                android:minHeight="@dimen/alert_dialog_button_bar_height" />
+        </LinearLayout>
+     </LinearLayout>
+</LinearLayout>
diff --git a/core/res/res/layout/alert_dialog_material.xml b/core/res/res/layout/alert_dialog_material.xml
index c3f9c76..54a1061 100644
--- a/core/res/res/layout/alert_dialog_material.xml
+++ b/core/res/res/layout/alert_dialog_material.xml
@@ -31,10 +31,9 @@
             android:layout_height="wrap_content"
             android:orientation="horizontal"
             android:gravity="center_vertical|start"
-            android:paddingStart="16dip"
-            android:paddingEnd="16dip"
-            android:paddingTop="16dip"
-            android:paddingBottom="8dip">
+            android:paddingStart="@dimen/alert_dialog_padding_material"
+            android:paddingEnd="@dimen/alert_dialog_padding_material"
+            android:paddingTop="@dimen/alert_dialog_padding_top_material">
             <ImageView android:id="@+id/icon"
                 android:layout_width="32dip"
                 android:layout_height="32dip"
@@ -62,14 +61,22 @@
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:clipToPadding="false">
-            <TextView android:id="@+id/message"
-                style="?attr/textAppearanceMedium"
+            <LinearLayout
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
-                android:paddingStart="16dip"
-                android:paddingEnd="16dip"
-                android:paddingTop="16dip"
-                android:paddingBottom="16dip" />
+                android:orientation="vertical">
+                <TextView android:id="@+id/message"
+                          style="?attr/textAppearanceMedium"
+                          android:layout_width="match_parent"
+                          android:layout_height="wrap_content"
+                          android:paddingStart="@dimen/alert_dialog_padding_material"
+                          android:paddingTop="@dimen/alert_dialog_padding_top_material"
+                          android:paddingEnd="@dimen/alert_dialog_padding_material" />
+                <Space android:id="@+id/textSpacerNoButtons"
+                       android:visibility="gone"
+                       android:layout_width="0dp"
+                       android:layout_height="@dimen/alert_dialog_padding_top_material" />
+            </LinearLayout>
         </ScrollView>
     </LinearLayout>
 
@@ -87,35 +94,28 @@
         style="?attr/buttonBarStyle"
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
-        android:orientation="vertical"
-        android:gravity="end">
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layoutDirection="locale">
-            <Button android:id="@+id/button3"
-                style="?attr/buttonBarNeutralButtonStyle"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-            <Space
-                android:layout_width="0dp"
-                android:layout_height="0dp"
-                android:layout_weight="1"
-                android:visibility="invisible" />
-            <Button android:id="@+id/button2"
-                style="?attr/buttonBarNegativeButtonStyle"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-            <Button android:id="@+id/button1"
-                style="?attr/buttonBarPositiveButtonStyle"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:maxLines="2"
-                android:minHeight="@dimen/alert_dialog_button_bar_height" />
-        </LinearLayout>
-     </LinearLayout>
+        android:layoutDirection="locale"
+        android:orientation="horizontal"
+        android:paddingStart="12dp"
+        android:paddingEnd="12dp"
+        android:paddingTop="8dp"
+        android:paddingBottom="8dp">
+        <Button android:id="@+id/button3"
+            style="?attr/buttonBarNeutralButtonStyle"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content" />
+        <Space
+            android:layout_width="0dp"
+            android:layout_height="0dp"
+            android:layout_weight="1"
+            android:visibility="invisible" />
+        <Button android:id="@+id/button2"
+            style="?attr/buttonBarNegativeButtonStyle"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content" />
+        <Button android:id="@+id/button1"
+            style="?attr/buttonBarPositiveButtonStyle"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content" />
+    </LinearLayout>
 </LinearLayout>
diff --git a/core/res/res/layout/alert_dialog_progress_material.xml b/core/res/res/layout/alert_dialog_progress_material.xml
index b9d0814..d005a44 100644
--- a/core/res/res/layout/alert_dialog_progress_material.xml
+++ b/core/res/res/layout/alert_dialog_progress_material.xml
@@ -17,32 +17,27 @@
 
 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="wrap_content"
-    android:layout_height="match_parent">
-    <ProgressBar android:id="@+id/progress"
-        style="?android:attr/progressBarStyleHorizontal"
+    android:layout_height="match_parent"
+    android:paddingStart="@dimen/alert_dialog_padding_material"
+    android:paddingTop="@dimen/alert_dialog_padding_top_material"
+    android:paddingEnd="@dimen/alert_dialog_padding_material"
+    android:paddingBottom="@dimen/alert_dialog_padding_top_material">
+    <ProgressBar
+        android:id="@+id/progress"
+        style="?attr/progressBarStyleHorizontal"
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
-        android:layout_marginTop="16dip"
-        android:layout_marginBottom="1dip"
-        android:layout_marginStart="16dip"
-        android:layout_marginEnd="16dip"
         android:layout_centerHorizontal="true" />
     <TextView
         android:id="@+id/progress_percent"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:paddingBottom="16dip"
-        android:layout_marginStart="16dip"
-        android:layout_marginEnd="16dip"
         android:layout_alignParentStart="true"
         android:layout_below="@id/progress" />
     <TextView
         android:id="@+id/progress_number"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:paddingBottom="16dip"
-        android:layout_marginStart="16dip"
-        android:layout_marginEnd="16dip"
         android:layout_alignParentEnd="true"
         android:layout_below="@id/progress" />
 </RelativeLayout>
diff --git a/core/res/res/layout/date_picker_selected_date.xml b/core/res/res/layout/date_picker_selected_date.xml
index 23ae08f..d212cb0 100644
--- a/core/res/res/layout/date_picker_selected_date.xml
+++ b/core/res/res/layout/date_picker_selected_date.xml
@@ -32,37 +32,42 @@
         android:layout_marginBottom="8dp" />
 
     <LinearLayout
-        android:id="@+id/date_picker_month_and_day_layout"
+        android:id="@+id/date_picker_month_day_year_layout"
         android:layout_width="match_parent"
         android:layout_height="0dp"
         android:layout_weight="1"
-        android:layout_gravity="center"
-        android:clickable="true"
-        android:orientation="vertical">
+        android:orientation="vertical"
+        android:gravity="center">
 
-        <TextView
-            android:id="@+id/date_picker_month"
+        <LinearLayout
+            android:id="@+id/date_picker_month_and_day_layout"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:duplicateParentState="true"
-            android:gravity="center_horizontal|bottom" />
+            android:clickable="true"
+            android:orientation="vertical">
+
+            <TextView
+                android:id="@+id/date_picker_month"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:duplicateParentState="true"
+                android:gravity="center" />
+
+            <TextView
+                android:id="@+id/date_picker_day"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:layout_marginTop="-10dip"
+                android:layout_marginBottom="-10dip"
+                android:duplicateParentState="true"
+                android:gravity="center" />
+        </LinearLayout>
 
         <TextView
-            android:id="@+id/date_picker_day"
+            android:id="@+id/date_picker_year"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:layout_gravity="center"
-            android:layout_marginBottom="-10dip"
-            android:layout_marginTop="-10dip"
-            android:duplicateParentState="true"
             android:gravity="center" />
     </LinearLayout>
 
-    <TextView
-        android:id="@+id/date_picker_year"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_gravity="center"
-        android:gravity="center_horizontal|top" />
-
 </LinearLayout>
diff --git a/core/res/res/layout/dialog_custom_title_material.xml b/core/res/res/layout/dialog_custom_title_material.xml
index 550b72e..248a05e 100644
--- a/core/res/res/layout/dialog_custom_title_material.xml
+++ b/core/res/res/layout/dialog_custom_title_material.xml
@@ -23,17 +23,17 @@
     android:fitsSystemWindows="true">
     <FrameLayout android:id="@android:id/title_container"
         android:layout_width="match_parent"
-        android:layout_height="?android:attr/windowTitleSize"
+        android:layout_height="?attr/windowTitleSize"
         android:layout_weight="0"
         android:gravity="center_vertical|start"
-        style="?android:attr/windowTitleBackgroundStyle" />
+        style="?attr/windowTitleBackgroundStyle" />
     <FrameLayout
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:layout_weight="1"
         android:orientation="vertical"
-        android:foreground="?android:attr/windowContentOverlay">
-        <FrameLayout android:id="@android:id/content"
+        android:foreground="?attr/windowContentOverlay">
+        <FrameLayout android:id="@id/content"
             android:layout_width="match_parent"
             android:layout_height="match_parent" />
     </FrameLayout>
diff --git a/core/res/res/layout/dialog_title_icons_material.xml b/core/res/res/layout/dialog_title_icons_material.xml
index 28e20d9..21396da 100644
--- a/core/res/res/layout/dialog_title_icons_material.xml
+++ b/core/res/res/layout/dialog_title_icons_material.xml
@@ -28,16 +28,16 @@
         android:layout_height="wrap_content"
         android:orientation="horizontal"
         android:gravity="center_vertical"
-        android:paddingStart="16dip"
-        android:paddingEnd="16dip"
-        android:paddingTop="16dip">
+        android:paddingStart="@dimen/alert_dialog_padding_material"
+        android:paddingEnd="@dimen/alert_dialog_padding_material"
+        android:paddingTop="@dimen/alert_dialog_padding_material">
         <ImageView android:id="@+id/left_icon"
             android:layout_width="32dip"
             android:layout_height="32dip"
             android:scaleType="fitCenter"
             android:layout_marginEnd="8dip" />
-        <TextView android:id="@android:id/title"
-            style="?android:attr/windowTitleStyle"
+        <TextView android:id="@id/title"
+            style="?attr/windowTitleStyle"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:layout_weight="0" />
@@ -52,8 +52,8 @@
         android:layout_width="match_parent" android:layout_height="wrap_content"
         android:layout_weight="1"
         android:orientation="vertical"
-        android:foreground="?android:attr/windowContentOverlay">
-        <FrameLayout android:id="@android:id/content"
+        android:foreground="?attr/windowContentOverlay">
+        <FrameLayout android:id="@id/content"
             android:layout_width="match_parent"
             android:layout_height="match_parent" />
     </FrameLayout>
diff --git a/core/res/res/layout/dialog_title_material.xml b/core/res/res/layout/dialog_title_material.xml
index 918c8f1..fcf6164 100644
--- a/core/res/res/layout/dialog_title_material.xml
+++ b/core/res/res/layout/dialog_title_material.xml
@@ -29,15 +29,15 @@
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:textAlignment="viewStart"
-        android:paddingStart="16dip"
-        android:paddingEnd="16dip"
-        android:paddingTop="16dip" />
+        android:paddingStart="@dimen/alert_dialog_padding_material"
+        android:paddingEnd="@dimen/alert_dialog_padding_material"
+        android:paddingTop="@dimen/alert_dialog_padding_top_material" />
     <FrameLayout
         android:layout_width="match_parent" android:layout_height="wrap_content"
         android:layout_weight="1"
         android:orientation="vertical"
-        android:foreground="?android:attr/windowContentOverlay">
-        <FrameLayout android:id="@android:id/content"
+        android:foreground="?attr/windowContentOverlay">
+        <FrameLayout android:id="@id/content"
             android:layout_width="match_parent"
             android:layout_height="match_parent" />
     </FrameLayout>
diff --git a/core/res/res/layout/notification_material_action.xml b/core/res/res/layout/notification_material_action.xml
index 8f8c4fb..da8b2e7 100644
--- a/core/res/res/layout/notification_material_action.xml
+++ b/core/res/res/layout/notification_material_action.xml
@@ -25,8 +25,9 @@
     android:gravity="start|center_vertical"
     android:drawablePadding="8dp"
     android:paddingStart="8dp"
-    android:textColor="#555555"
-    android:textSize="@dimen/notification_text_size"
+    android:textColor="@color/secondary_text_material_light"
+    android:textSize="13sp"
     android:singleLine="true"
     android:ellipsize="end"
+    android:background="@drawable/notification_material_action_background"
     />
diff --git a/core/res/res/layout/notification_material_action_list.xml b/core/res/res/layout/notification_material_action_list.xml
index ec4919b..2a36949 100644
--- a/core/res/res/layout/notification_material_action_list.xml
+++ b/core/res/res/layout/notification_material_action_list.xml
@@ -22,9 +22,6 @@
     android:orientation="horizontal"
     android:visibility="gone"
     android:layout_marginBottom="8dp"
-    android:showDividers="middle"
-    android:divider="@drawable/list_divider_holo_light"
-    android:dividerPadding="12dp"
     >
     <!-- actions will be added here -->
 </LinearLayout>
diff --git a/core/res/res/layout/notification_material_media_action.xml b/core/res/res/layout/notification_material_media_action.xml
index 331ee57..1d52e54 100644
--- a/core/res/res/layout/notification_material_media_action.xml
+++ b/core/res/res/layout/notification_material_media_action.xml
@@ -16,10 +16,13 @@
   -->
 
 <ImageButton xmlns:android="http://schemas.android.com/apk/res/android"
-    style="@android:style/Widget.Material.Light.Button.Borderless.Small"
+    style="@android:style/Widget.Material.Button.Borderless.Small"
     android:id="@+id/action0"
-    android:layout_width="60dp"
+    android:layout_width="48dp"
     android:layout_height="match_parent"
+    android:layout_marginLeft="2dp"
+    android:layout_marginRight="2dp"
     android:layout_weight="1"
     android:gravity="center"
+    android:background="@drawable/notification_material_media_action_background"
     />
diff --git a/core/res/res/layout/notification_template_icon_group.xml b/core/res/res/layout/notification_template_icon_group.xml
index 2ad6f9e..fa66163 100644
--- a/core/res/res/layout/notification_template_icon_group.xml
+++ b/core/res/res/layout/notification_template_icon_group.xml
@@ -23,20 +23,23 @@
     android:id="@+id/icon_group"
     >
     <ImageView android:id="@+id/icon"
-        android:layout_width="@dimen/notification_large_icon_width"
-        android:layout_height="@dimen/notification_large_icon_height"
-        android:padding="8dp"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:layout_marginTop="12dp"
+        android:layout_marginBottom="12dp"
+        android:layout_marginStart="12dp"
+        android:layout_marginEnd="12dp"
         android:scaleType="centerInside"
         />
     <ImageView android:id="@+id/right_icon"
-        android:layout_width="24dp"
-        android:layout_height="24dp"
-        android:padding="4dp"
+        android:layout_width="16dp"
+        android:layout_height="16dp"
+        android:padding="3dp"
         android:layout_gravity="end|bottom"
         android:scaleType="centerInside"
         android:visibility="gone"
-        android:layout_marginEnd="3dp"
-        android:layout_marginBottom="3dp"
+        android:layout_marginEnd="8dp"
+        android:layout_marginBottom="8dp"
         />
 </FrameLayout>
 
diff --git a/core/res/res/layout/notification_template_material_base.xml b/core/res/res/layout/notification_template_material_base.xml
index 5e51db9..674d7b8 100644
--- a/core/res/res/layout/notification_template_material_base.xml
+++ b/core/res/res/layout/notification_template_material_base.xml
@@ -31,25 +31,12 @@
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         android:layout_gravity="top"
-        android:layout_marginEnd="8dp"
         android:layout_marginStart="@dimen/notification_large_icon_width"
         android:minHeight="@dimen/notification_large_icon_height"
         android:orientation="vertical"
         >
-        <include layout="@layout/notification_template_part_line1"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            />
-        <include layout="@layout/notification_template_part_line2"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            />
-        <include layout="@layout/notification_template_part_line3"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            />
+        <include layout="@layout/notification_template_part_line1" />
+        <include layout="@layout/notification_template_part_line2" />
+        <include layout="@layout/notification_template_part_line3" />
     </LinearLayout>
 </FrameLayout>
diff --git a/core/res/res/layout/notification_template_material_big_base.xml b/core/res/res/layout/notification_template_material_big_base.xml
index 2243a09..ef916ed1 100644
--- a/core/res/res/layout/notification_template_material_big_base.xml
+++ b/core/res/res/layout/notification_template_material_big_base.xml
@@ -31,33 +31,52 @@
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:layout_gravity="top"
-        android:layout_marginEnd="8dp"
         android:layout_marginStart="@dimen/notification_large_icon_width"
         android:minHeight="@dimen/notification_large_icon_height"
         android:orientation="vertical"
         >
         <include layout="@layout/notification_template_part_line1" />
         <include layout="@layout/notification_template_part_line2" />
-        <TextView android:id="@+id/big_text"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+        <LinearLayout
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:minHeight="@dimen/notification_large_icon_height"
-            android:layout_weight="1"
-            android:singleLine="false"
-            android:visibility="gone"
+            android:layout_marginEnd="8dp"
+            android:orientation="horizontal"
+            android:gravity="top"
+            >
+            <TextView android:id="@+id/big_text"
+                android:textAppearance="@style/TextAppearance.Material.Notification"
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_weight="1"
+                android:singleLine="false"
+                android:visibility="gone"
+                />
+            <ImageView android:id="@+id/profile_badge_large_template"
+                android:layout_width="@dimen/notification_badge_size"
+                android:layout_height="@dimen/notification_badge_size"
+                android:layout_weight="0"
+                android:layout_marginStart="4dp"
+                android:scaleType="fitCenter"
+                android:visibility="gone"
+                />
+        </LinearLayout>
+        <include
+            layout="@layout/notification_template_part_line3"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginEnd="8dp"
             />
-        <include layout="@layout/notification_template_part_line3" />
         <ImageView
             android:layout_width="match_parent"
             android:layout_height="1dp"
+            android:layout_marginTop="10dp"
             android:id="@+id/action_divider"
             android:visibility="gone"
-            android:background="@drawable/list_divider_holo_light" />
+            android:background="@drawable/notification_template_divider" />
         <include
             layout="@layout/notification_material_action_list"
-            android:layout_marginLeft="-8dp"
-            android:layout_marginRight="-8dp"
+            android:layout_marginStart="-8dp"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             />
diff --git a/core/res/res/layout/notification_template_material_big_media.xml b/core/res/res/layout/notification_template_material_big_media.xml
index f8e1986..93acdbf 100644
--- a/core/res/res/layout/notification_template_material_big_media.xml
+++ b/core/res/res/layout/notification_template_material_big_media.xml
@@ -15,143 +15,43 @@
   ~ limitations under the License
   -->
 
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:internal="http://schemas.android.com/apk/prv/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:id="@+id/status_bar_latest_event_content"
     android:layout_width="match_parent"
-    android:layout_height="wrap_content"
-    internal:layout_minHeight="65dp"
-    internal:layout_maxHeight="unbounded"
+    android:layout_height="128dp"
+    android:background="#00000000"
     >
+    <include layout="@layout/notification_template_icon_group"
+        android:layout_width="@dimen/notification_large_icon_width"
+        android:layout_height="@dimen/notification_large_icon_height"
+        />
     <LinearLayout
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
-        android:layout_gravity="fill_vertical"
+        android:layout_marginStart="@dimen/notification_large_icon_width"
         android:minHeight="@dimen/notification_large_icon_height"
         android:orientation="vertical"
-        android:gravity="top"
         >
-        <LinearLayout
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:paddingStart="@dimen/notification_large_icon_width"
-            android:minHeight="@dimen/notification_large_icon_height"
-            android:paddingTop="2dp"
-            android:orientation="vertical"
-            >
-            <LinearLayout
-                android:id="@+id/line1"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:paddingTop="6dp"
-                android:layout_marginEnd="8dp"
-                android:layout_marginStart="8dp"
-                android:orientation="horizontal"
-                >
-                <TextView android:id="@+id/title"
-                    android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Title"
-                    android:layout_width="match_parent"
-                    android:layout_height="wrap_content"
-                    android:singleLine="true"
-                    android:ellipsize="marquee"
-                    android:fadingEdge="horizontal"
-                    android:layout_weight="1"
-                    />
-                <ViewStub android:id="@+id/time"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_weight="0"
-                    android:visibility="gone"
-                    android:layout="@layout/notification_template_part_time"
-                    />
-                <ViewStub android:id="@+id/chronometer"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_weight="0"
-                    android:visibility="gone"
-                    android:layout="@layout/notification_template_part_chronometer"
-                    />
-            </LinearLayout>
-            <TextView android:id="@+id/text2"
-                android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Line2"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginTop="-2dp"
-                android:layout_marginBottom="-2dp"
-                android:layout_marginStart="8dp"
-                android:layout_marginEnd="8dp"
-                android:singleLine="true"
-                android:fadingEdge="horizontal"
-                android:ellipsize="marquee"
-                android:visibility="gone"
-                />
-            <TextView android:id="@+id/big_text"
-                android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginStart="8dp"
-                android:layout_marginEnd="8dp"
-                android:singleLine="false"
-                android:visibility="gone"
-                />
-            <LinearLayout
-                android:id="@+id/line3"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:layout_marginStart="8dp"
-                android:layout_marginEnd="8dp"
-                android:orientation="horizontal"
-                android:gravity="center_vertical"
-                >
-                <TextView android:id="@+id/text"
-                    android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
-                    android:layout_width="0dp"
-                    android:layout_height="wrap_content"
-                    android:layout_weight="1"
-                    android:layout_gravity="center"
-                    android:singleLine="true"
-                    android:ellipsize="marquee"
-                    android:fadingEdge="horizontal"
-                    />
-                <TextView android:id="@+id/info"
-                    android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Info"
-                    android:layout_width="wrap_content"
-                    android:layout_height="wrap_content"
-                    android:layout_gravity="center"
-                    android:layout_weight="0"
-                    android:singleLine="true"
-                    android:gravity="center"
-                    android:paddingStart="8dp"
-                    />
-            </LinearLayout>
-        </LinearLayout>
-        <FrameLayout
-                android:layout_width="match_parent"
-                android:layout_height="60dp"
-                android:id="@+id/media_action_area"
-                android:background="@color/notification_media_action_bg"
-                >
-            <LinearLayout
-                android:id="@+id/actions"
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:layout_marginTop="6dp"
-                android:orientation="horizontal"
-                >
-                <!-- media buttons will be added here -->
-            </LinearLayout>
-            <ProgressBar
-                android:id="@android:id/progress"
-                android:layout_width="match_parent"
-                android:layout_height="6dp"
-                android:layout_gravity="top"
-                android:visibility="gone"
-                style="@style/Widget.StatusBar.Material.ProgressBar.Media"
-                />
-        </FrameLayout>
+        <include layout="@layout/notification_template_part_line1" />
+        <include layout="@layout/notification_template_part_line2" />
+        <include layout="@layout/notification_template_part_line3" />
     </LinearLayout>
-    <include layout="@layout/notification_template_icon_group"
-             android:layout_width="@dimen/notification_large_icon_width"
-             android:layout_height="@dimen/notification_large_icon_height"
-            />
-</FrameLayout>
+    <LinearLayout
+        android:id="@+id/media_actions"
+        android:layout_width="match_parent"
+        android:layout_height="48dp"
+        android:layout_alignParentBottom="true"
+        android:layout_marginStart="12dp"
+        android:layout_marginEnd="12dp"
+        android:orientation="horizontal"
+        android:layoutDirection="ltr"
+        >
+        <!-- media buttons will be added here -->
+    </LinearLayout>
+    <ImageView
+        android:layout_width="match_parent"
+        android:layout_height="1dp"
+        android:layout_above="@id/media_actions"
+        android:id="@+id/action_divider"
+        android:background="@drawable/notification_template_divider_media" />
+</RelativeLayout>
diff --git a/core/res/res/layout/notification_template_material_big_media_narrow.xml b/core/res/res/layout/notification_template_material_big_media_narrow.xml
new file mode 100644
index 0000000..21e5ff8
--- /dev/null
+++ b/core/res/res/layout/notification_template_material_big_media_narrow.xml
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<!-- Layout to be used with only max 3 actions. It has a much larger picture at the left side-->
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@+id/status_bar_latest_event_content"
+    android:layout_width="match_parent"
+    android:layout_height="128dp"
+    android:background="#00000000"
+    >
+    <ImageView android:id="@+id/icon"
+        android:layout_width="128dp"
+        android:layout_height="128dp"
+        android:scaleType="centerCrop"
+        />
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_marginStart="12dp"
+        android:layout_toEndOf="@id/icon"
+        android:minHeight="@dimen/notification_large_icon_height"
+        android:orientation="vertical"
+        >
+        <include layout="@layout/notification_template_part_line1" />
+        <include layout="@layout/notification_template_part_line2" />
+        <include layout="@layout/notification_template_part_line3" />
+    </LinearLayout>
+    <LinearLayout
+        android:id="@+id/media_actions"
+        android:layout_width="match_parent"
+        android:layout_height="48dp"
+        android:layout_toEndOf="@id/icon"
+        android:layout_alignParentBottom="true"
+        android:layout_marginStart="12dp"
+        android:layout_marginEnd="12dp"
+        android:orientation="horizontal"
+        android:layoutDirection="ltr"
+        >
+        <!-- media buttons will be added here -->
+    </LinearLayout>
+    <ImageView
+        android:layout_width="match_parent"
+        android:layout_height="1dp"
+        android:layout_toEndOf="@id/icon"
+        android:layout_above="@id/media_actions"
+        android:id="@+id/action_divider"
+        android:background="@drawable/notification_template_divider_media" />
+</RelativeLayout>
diff --git a/core/res/res/layout/notification_template_material_big_text.xml b/core/res/res/layout/notification_template_material_big_text.xml
new file mode 100644
index 0000000..3415814
--- /dev/null
+++ b/core/res/res/layout/notification_template_material_big_text.xml
@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:internal="http://schemas.android.com/apk/prv/res/android"
+    android:id="@+id/status_bar_latest_event_content"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    internal:layout_minHeight="65dp"
+    internal:layout_maxHeight="unbounded"
+    >
+    <include layout="@layout/notification_template_icon_group"
+        android:layout_width="@dimen/notification_large_icon_width"
+        android:layout_height="@dimen/notification_large_icon_height"
+        />
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_gravity="top"
+        android:layout_marginStart="@dimen/notification_large_icon_width"
+        android:minHeight="@dimen/notification_large_icon_height"
+        android:orientation="vertical"
+        >
+        <include layout="@layout/notification_template_part_line1" />
+        <include layout="@layout/notification_template_part_line2" />
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
+            android:layout_marginBottom="10dp"
+            android:orientation="horizontal"
+            android:gravity="top"
+            android:layout_weight="1"
+            >
+            <TextView android:id="@+id/big_text"
+                android:textAppearance="@style/TextAppearance.Material.Notification"
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:layout_weight="1"
+                android:singleLine="false"
+                android:visibility="gone"
+                />
+            <ImageView android:id="@+id/profile_badge_large_template"
+                android:layout_width="@dimen/notification_badge_size"
+                android:layout_height="@dimen/notification_badge_size"
+                android:layout_weight="0"
+                android:layout_marginStart="4dp"
+                android:scaleType="fitCenter"
+                android:visibility="gone"
+                />
+        </LinearLayout>
+        <ImageView
+            android:layout_width="match_parent"
+            android:layout_height="1dp"
+            android:id="@+id/action_divider"
+            android:visibility="gone"
+            android:background="@drawable/notification_template_divider" />
+        <include
+            layout="@layout/notification_material_action_list"
+            android:layout_marginStart="-8dp"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            />
+        <ImageView
+            android:layout_width="match_parent"
+            android:layout_height="1dip"
+            android:id="@+id/overflow_divider"
+            android:visibility="visible"
+            android:background="@drawable/notification_template_divider" />
+        <include
+            layout="@layout/notification_template_part_line3"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginEnd="8dp"
+            android:layout_marginTop="8dp"
+            android:layout_marginBottom="10dp" />
+    </LinearLayout>
+</FrameLayout>
diff --git a/core/res/res/layout/notification_template_material_inbox.xml b/core/res/res/layout/notification_template_material_inbox.xml
index 6133791..8a66c3f 100644
--- a/core/res/res/layout/notification_template_material_inbox.xml
+++ b/core/res/res/layout/notification_template_material_inbox.xml
@@ -37,73 +37,99 @@
         >
         <include layout="@layout/notification_template_part_line1" />
         <include layout="@layout/notification_template_part_line2" />
-        <TextView android:id="@+id/inbox_text0"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+
+        <!-- We can't have another vertical linear layout here with weight != 0 so this forces us to
+             put the badge on the first line. -->
+        <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="0dp"
-            android:singleLine="true"
-            android:ellipsize="end"
-            android:visibility="gone"
             android:layout_weight="1"
-            />
+            android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
+            android:orientation="horizontal"
+            >
+            <TextView android:id="@+id/inbox_text0"
+                android:textAppearance="@style/TextAppearance.Material.Notification"
+                android:layout_width="0dp"
+                android:layout_height="wrap_content"
+                android:singleLine="true"
+                android:ellipsize="end"
+                android:visibility="gone"
+                android:layout_weight="1"
+                />
+            <ImageView android:id="@+id/profile_badge_large_template"
+                android:layout_width="@dimen/notification_badge_size"
+                android:layout_height="@dimen/notification_badge_size"
+                android:layout_weight="0"
+                android:layout_marginStart="4dp"
+                android:scaleType="fitCenter"
+                android:visibility="gone"
+                />
+        </LinearLayout>
         <TextView android:id="@+id/inbox_text1"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_text2"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_text3"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_text4"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_text5"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_text6"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
             android:layout_weight="1"
             />
         <TextView android:id="@+id/inbox_more"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+            android:textAppearance="@style/TextAppearance.Material.Notification"
             android:layout_width="match_parent"
             android:layout_height="0dp"
+            android:layout_marginEnd="8dp"
             android:singleLine="true"
             android:ellipsize="end"
             android:visibility="gone"
@@ -113,7 +139,7 @@
         <FrameLayout
             android:id="@+id/inbox_end_pad"
             android:layout_width="match_parent"
-            android:layout_height="8dip"
+            android:layout_height="10dp"
             android:visibility="gone"
             android:layout_weight="0"
         />
@@ -122,7 +148,7 @@
             android:layout_height="1dip"
             android:id="@+id/action_divider"
             android:visibility="gone"
-            android:background="@drawable/list_divider_holo_light" />
+            android:background="@drawable/notification_template_divider" />
         <include
             layout="@layout/notification_material_action_list"
             android:layout_width="match_parent"
@@ -136,7 +162,13 @@
             android:layout_height="1dip"
             android:id="@+id/overflow_divider"
             android:visibility="visible"
-            android:background="@drawable/list_divider_holo_light" />
-        <include layout="@layout/notification_template_part_line3" />
+            android:background="@drawable/notification_template_divider" />
+        <include
+            layout="@layout/notification_template_part_line3"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:layout_marginEnd="8dp"
+            android:layout_marginTop="8dp"
+            android:layout_marginBottom="10dp" />
     </LinearLayout>
 </FrameLayout>
diff --git a/core/res/res/layout/notification_template_material_media.xml b/core/res/res/layout/notification_template_material_media.xml
index c2fc006..69020a4 100644
--- a/core/res/res/layout/notification_template_material_media.xml
+++ b/core/res/res/layout/notification_template_material_media.xml
@@ -21,6 +21,7 @@
     android:layout_width="match_parent"
     android:layout_height="64dp"
     android:orientation="horizontal"
+    android:background="#00000000"
     internal:layout_minHeight="64dp"
     internal:layout_maxHeight="64dp"
     >
@@ -36,99 +37,19 @@
         android:layout_gravity="fill_vertical"
         android:minHeight="@dimen/notification_large_icon_height"
         android:orientation="vertical"
-        android:paddingEnd="8dp"
-        android:paddingTop="2dp"
-        android:paddingBottom="2dp"
-        android:gravity="top"
         >
-        <LinearLayout
-            android:id="@+id/line1"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:paddingTop="6dp"
-            android:layout_marginStart="8dp"
-            android:orientation="horizontal"
-            >
-            <TextView android:id="@+id/title"
-                android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Title"
-                android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:singleLine="true"
-                android:ellipsize="marquee"
-                android:fadingEdge="horizontal"
-                android:layout_weight="1"
-                />
-            <ViewStub android:id="@+id/time"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_weight="0"
-                android:visibility="gone"
-                android:layout="@layout/notification_template_part_time"
-                />
-            <ViewStub android:id="@+id/chronometer"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_weight="0"
-                android:visibility="gone"
-                android:layout="@layout/notification_template_part_chronometer"
-                />
-        </LinearLayout>
-        <TextView android:id="@+id/text2"
-            android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Line2"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="-2dp"
-            android:layout_marginBottom="-2dp"
-            android:layout_marginStart="8dp"
-            android:singleLine="true"
-            android:fadingEdge="horizontal"
-            android:ellipsize="marquee"
-            android:visibility="gone"
-            />
-        <ProgressBar
-            android:id="@android:id/progress"
-            android:layout_width="match_parent"
-            android:layout_height="12dp"
-            android:layout_marginStart="8dp"
-            android:visibility="gone"
-            style="@style/Widget.StatusBar.Material.ProgressBar"
-            />
-        <LinearLayout
-            android:id="@+id/line3"
-            android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:orientation="horizontal"
-            android:gravity="center_vertical"
-            android:layout_marginStart="8dp"
-            >
-            <TextView android:id="@+id/text"
-                android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
-                android:layout_width="0dp"
-                android:layout_height="wrap_content"
-                android:layout_weight="1"
-                android:layout_gravity="center"
-                android:singleLine="true"
-                android:ellipsize="marquee"
-                android:fadingEdge="horizontal"
-                />
-            <TextView android:id="@+id/info"
-                android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Info"
-                android:layout_width="wrap_content"
-                android:layout_height="wrap_content"
-                android:layout_gravity="center"
-                android:layout_weight="0"
-                android:singleLine="true"
-                android:gravity="center"
-                android:paddingStart="8dp"
-                />
-        </LinearLayout>
+        <include layout="@layout/notification_template_part_line1" />
+        <include layout="@layout/notification_template_part_line2" />
+        <include layout="@layout/notification_template_part_line3" />
     </LinearLayout>
     <LinearLayout
-        android:id="@+id/actions"
+        android:id="@+id/media_actions"
         android:layout_width="wrap_content"
         android:layout_height="match_parent"
+        android:layout_marginEnd="6dp"
         android:layout_gravity="center_vertical|end"
         android:orientation="horizontal"
+        android:layoutDirection="ltr"
         >
         <!-- media buttons will be added here -->
     </LinearLayout>
diff --git a/core/res/res/layout/notification_template_part_chronometer.xml b/core/res/res/layout/notification_template_part_chronometer.xml
index 87dfe1f..1f0430e 100644
--- a/core/res/res/layout/notification_template_part_chronometer.xml
+++ b/core/res/res/layout/notification_template_part_chronometer.xml
@@ -15,7 +15,7 @@
 -->
 
 <Chronometer android:id="@+id/chronometer" xmlns:android="http://schemas.android.com/apk/res/android"
-    android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Time"
+    android:textAppearance="@style/TextAppearance.Material.Notification.Time"
     android:layout_width="wrap_content"
     android:layout_height="wrap_content"
     android:layout_gravity="center"
diff --git a/core/res/res/layout/notification_template_part_line1.xml b/core/res/res/layout/notification_template_part_line1.xml
index d652959..78bc1ed 100644
--- a/core/res/res/layout/notification_template_part_line1.xml
+++ b/core/res/res/layout/notification_template_part_line1.xml
@@ -19,13 +19,12 @@
     android:id="@+id/line1"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
+    android:layout_marginEnd="8dp"
     android:orientation="horizontal"
-    android:paddingTop="@dimen/notification_vert_pad"
-    android:layout_weight="0"
     >
     <TextView android:id="@+id/title"
-        android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Title"
-        android:layout_width="match_parent"
+        android:textAppearance="@style/TextAppearance.Material.Notification.Title"
+        android:layout_width="0dp"
         android:layout_height="wrap_content"
         android:singleLine="true"
         android:ellipsize="marquee"
diff --git a/core/res/res/layout/notification_template_part_line2.xml b/core/res/res/layout/notification_template_part_line2.xml
index 1e19df1..aeef3ab 100644
--- a/core/res/res/layout/notification_template_part_line2.xml
+++ b/core/res/res/layout/notification_template_part_line2.xml
@@ -16,25 +16,42 @@
   -->
 
 <merge xmlns:android="http://schemas.android.com/apk/res/android">
-    <TextView 
-        android:id="@+id/text2"
-        android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Line2"
+    <LinearLayout
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
-        android:layout_marginTop="-2dp"
-        android:layout_marginBottom="-2dp"
-        android:singleLine="true"
-        android:fadingEdge="horizontal"
-        android:ellipsize="marquee"
-        android:visibility="gone"
-        android:layout_weight="0"
+        android:layout_marginEnd="8dp"
+        android:orientation="horizontal"
+        android:gravity="center_vertical"
+        >
+        <TextView
+            android:id="@+id/text2"
+            android:textAppearance="@style/TextAppearance.Material.Notification.Line2"
+            android:layout_width="0dp"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="-1dp"
+            android:layout_marginBottom="-1dp"
+            android:singleLine="true"
+            android:fadingEdge="horizontal"
+            android:ellipsize="marquee"
+            android:visibility="gone"
+            android:layout_weight="1"
         />
-    <ProgressBar
+        <ImageView android:id="@+id/profile_badge_line2"
+            android:layout_width="@dimen/notification_badge_size"
+            android:layout_height="@dimen/notification_badge_size"
+            android:layout_weight="0"
+            android:layout_marginStart="4dp"
+            android:scaleType="fitCenter"
+            android:visibility="gone"
+            />
+    </LinearLayout>
+    <ViewStub
         android:id="@android:id/progress"
+        android:layout="@layout/notification_template_progressbar"
         android:layout_width="match_parent"
-        android:layout_height="8dp"
+        android:layout_height="15dp"
+        android:layout_marginEnd="8dp"
         android:visibility="gone"
         android:layout_weight="0"
-        style="@style/Widget.Material.Light.ProgressBar.Horizontal"
         />
 </merge>
diff --git a/core/res/res/layout/notification_template_part_line3.xml b/core/res/res/layout/notification_template_part_line3.xml
index 2c8c704c..6c043a0 100644
--- a/core/res/res/layout/notification_template_part_line3.xml
+++ b/core/res/res/layout/notification_template_part_line3.xml
@@ -19,13 +19,12 @@
     android:id="@+id/line3"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
+    android:layout_marginEnd="8dp"
     android:orientation="horizontal"
-    android:layout_weight="0"
     android:gravity="center_vertical"
-    android:paddingBottom="@dimen/notification_vert_pad"
     >
     <TextView android:id="@+id/text"
-        android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent"
+        android:textAppearance="@style/TextAppearance.Material.Notification"
         android:layout_width="0dp"
         android:layout_height="wrap_content"
         android:layout_weight="1"
@@ -35,7 +34,7 @@
         android:fadingEdge="horizontal"
         />
     <TextView android:id="@+id/info"
-        android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Info"
+        android:textAppearance="@style/TextAppearance.Material.Notification.Info"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
         android:layout_gravity="center"
@@ -44,13 +43,13 @@
         android:gravity="center"
         android:paddingStart="8dp"
         />
-    <ImageView android:id="@+id/profile_icon"
-        android:layout_width="24dp"
-        android:layout_height="24dp"
+    <ImageView android:id="@+id/profile_badge_line3"
+        android:layout_width="@dimen/notification_badge_size"
+        android:layout_height="@dimen/notification_badge_size"
         android:layout_gravity="center"
         android:layout_weight="0"
-        android:layout_marginStart="8dp"
-        android:scaleType="centerInside"
+        android:layout_marginStart="4dp"
+        android:scaleType="fitCenter"
         android:visibility="gone"
         />
 </LinearLayout>
diff --git a/core/res/res/layout/notification_template_part_time.xml b/core/res/res/layout/notification_template_part_time.xml
index 5982c48..37c7ebe 100644
--- a/core/res/res/layout/notification_template_part_time.xml
+++ b/core/res/res/layout/notification_template_part_time.xml
@@ -15,7 +15,7 @@
 -->
 
 <DateTimeView android:id="@+id/time" xmlns:android="http://schemas.android.com/apk/res/android"
-    android:textAppearance="@style/TextAppearance.StatusBar.Material.EventContent.Time"
+    android:textAppearance="@style/TextAppearance.Material.Notification.Time"
     android:layout_width="wrap_content"
     android:layout_height="wrap_content"
     android:layout_gravity="center"
diff --git a/core/res/res/layout/notification_template_progressbar.xml b/core/res/res/layout/notification_template_progressbar.xml
new file mode 100644
index 0000000..61480b8
--- /dev/null
+++ b/core/res/res/layout/notification_template_progressbar.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<ProgressBar xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@android:id/progress"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    style="@style/Widget.Material.Light.ProgressBar.Horizontal"
+    />
diff --git a/core/res/res/layout/preference_material.xml b/core/res/res/layout/preference_material.xml
index 3919f5f..39c979c 100644
--- a/core/res/res/layout/preference_material.xml
+++ b/core/res/res/layout/preference_material.xml
@@ -20,58 +20,64 @@
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
-    android:minHeight="?android:attr/listPreferredItemHeightSmall"
+    android:minHeight="?attr/listPreferredItemHeightSmall"
     android:gravity="center_vertical"
     android:paddingStart="?attr/listPreferredItemPaddingStart"
     android:paddingEnd="?attr/listPreferredItemPaddingEnd"
-    android:background="?android:attr/activatedBackgroundIndicator">
+    android:background="?attr/activatedBackgroundIndicator"
+    android:clipToPadding="false">
 
     <LinearLayout
-        android:id="@+android:id/icon_frame"
+        android:id="@+id/icon_frame"
         android:layout_width="wrap_content"
         android:layout_height="match_parent"
-        android:minWidth="58dip"
+        android:layout_marginStart="-4dp"
+        android:minWidth="60dp"
         android:gravity="start|center_vertical"
-        android:orientation="horizontal">
+        android:orientation="horizontal"
+        android:paddingEnd="12dp"
+        android:paddingTop="4dp"
+        android:paddingBottom="4dp">
         <ImageView
-            android:id="@+android:id/icon"
+            android:id="@+id/icon"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:scaleType="centerInside"
-            android:layout_marginEnd="8dip" />
+            android:adjustViewBounds="true"
+            android:maxWidth="48dp"
+            android:maxHeight="48dp" />
     </LinearLayout>
 
     <RelativeLayout
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
         android:layout_weight="1"
-        android:paddingTop="16dip"
-        android:paddingBottom="16dip">
+        android:paddingTop="16dp"
+        android:paddingBottom="16dp">
 
-        <TextView android:id="@+android:id/title"
+        <TextView android:id="@+id/title"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:singleLine="true"
-            android:textAppearance="?android:attr/textAppearanceListItem"
+            android:textAppearance="?attr/textAppearanceListItem"
             android:ellipsize="marquee" />
 
-        <TextView android:id="@+android:id/summary"
+        <TextView android:id="@+id/summary"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:layout_below="@android:id/title"
-            android:layout_alignStart="@android:id/title"
-            android:textAppearance="?android:attr/textAppearanceListItemSecondary"
-            android:textColor="?android:attr/textColorSecondary"
+            android:layout_below="@id/title"
+            android:layout_alignStart="@id/title"
+            android:textAppearance="?attr/textAppearanceListItemSecondary"
+            android:textColor="?attr/textColorSecondary"
             android:maxLines="10" />
 
     </RelativeLayout>
 
     <!-- Preference should place its actual preference widget here. -->
-    <LinearLayout android:id="@+android:id/widget_frame"
+    <LinearLayout android:id="@+id/widget_frame"
         android:layout_width="wrap_content"
         android:layout_height="match_parent"
-        android:minWidth="58dip"
         android:gravity="end|center_vertical"
+        android:paddingStart="16dp"
         android:orientation="vertical" />
 
 </LinearLayout>
diff --git a/core/res/res/layout/progress_dialog_material.xml b/core/res/res/layout/progress_dialog_material.xml
index 84d06b5..54af106 100644
--- a/core/res/res/layout/progress_dialog_material.xml
+++ b/core/res/res/layout/progress_dialog_material.xml
@@ -19,21 +19,27 @@
     android:layout_width="match_parent"
     android:layout_height="wrap_content">
 
-    <LinearLayout android:id="@+id/body"
+    <LinearLayout
+        android:id="@+id/body"
         android:orientation="horizontal"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         android:baselineAligned="false"
-        android:padding="16dip">
+        android:paddingStart="@dimen/alert_dialog_padding_material"
+        android:paddingTop="@dimen/alert_dialog_padding_top_material"
+        android:paddingEnd="@dimen/alert_dialog_padding_material"
+        android:paddingBottom="@dimen/alert_dialog_padding_top_material">
 
-        <ProgressBar android:id="@android:id/progress"
+        <ProgressBar
+            android:id="@id/progress"
             style="?android:attr/progressBarStyle"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:max="10000"
-            android:layout_marginEnd="16dip" />
+            android:layout_marginEnd="@dimen/alert_dialog_padding_material" />
 
-        <TextView android:id="@+id/message"
+        <TextView
+            android:id="@+id/message"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_gravity="center_vertical" />
diff --git a/core/res/res/layout/resolve_list_item.xml b/core/res/res/layout/resolve_list_item.xml
index 7aa9a72..37c4270 100644
--- a/core/res/res/layout/resolve_list_item.xml
+++ b/core/res/res/layout/resolve_list_item.xml
@@ -18,9 +18,10 @@
 */
 -->
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:orientation="vertical"
+              android:orientation="horizontal"
               android:layout_height="wrap_content"
               android:layout_width="match_parent"
+              android:minHeight="?attr/listPreferredItemHeightSmall"
               android:paddingTop="4dp"
               android:paddingBottom="4dp"
               android:background="?attr/activatedBackgroundIndicator">
@@ -28,37 +29,40 @@
     <!-- Activity icon when presenting dialog
          Size will be filled in by ResolverActivity -->
     <ImageView android:id="@+id/icon"
-               android:layout_width="0dp"
-               android:layout_height="0dp"
-               android:layout_gravity="center"
-               android:layout_margin="4dp"
+               android:layout_width="24dp"
+               android:layout_height="24dp"
+               android:layout_gravity="start|center_vertical"
+               android:layout_marginStart="16dp"
+               android:layout_marginEnd="16dp"
+               android:layout_marginTop="12dp"
+               android:layout_marginBottom="12dp"
                android:scaleType="fitCenter" />
 
     <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-              android:gravity="center"
+              android:gravity="start|center_vertical"
               android:orientation="vertical"
+              android:paddingStart="16dp"
+              android:paddingEnd="16dp"
               android:layout_height="wrap_content"
               android:layout_width="wrap_content"
-              android:layout_gravity="center">
+              android:layout_gravity="start|center_vertical">
         <!-- Activity name -->
         <TextView android:id="@android:id/text1"
-                  android:textAppearance="?android:attr/textAppearanceSmall"
-                  android:fontFamily="sans-serif-condensed"
                   android:layout_width="wrap_content"
                   android:layout_height="wrap_content"
-                  android:gravity="center"
-                  android:minLines="2"
-                  android:maxLines="2" />
+                  android:textAppearance="?attr/textAppearanceMedium"
+                  android:textColor="?attr/textColorPrimary"
+                  android:minLines="1"
+                  android:maxLines="1"
+                  android:ellipsize="marquee" />
         <!-- Extended activity info to distinguish between duplicate activity names -->
         <TextView android:id="@android:id/text2"
                   android:textAppearance="?android:attr/textAppearanceSmall"
-                  android:fontFamily="sans-serif-condensed"
                   android:layout_width="wrap_content"
                   android:layout_height="wrap_content"
-                  android:gravity="center"
-                  android:minLines="2"
-                  android:maxLines="2"
-                  android:paddingTop="4dip" />
+                  android:minLines="1"
+                  android:maxLines="1"
+                  android:ellipsize="marquee" />
     </LinearLayout>
 </LinearLayout>
 
diff --git a/core/res/res/layout/resolver_different_item_header.xml b/core/res/res/layout/resolver_different_item_header.xml
new file mode 100644
index 0000000..5889136
--- /dev/null
+++ b/core/res/res/layout/resolver_different_item_header.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+ * Copyright 2014, 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.
+ */
+-->
+<TextView
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="wrap_content"
+    android:layout_alwaysShow="true"
+    android:text="@string/use_a_different_app"
+    android:minHeight="56dp"
+    android:textAppearance="?android:attr/textAppearanceMedium"
+    android:gravity="start|center_vertical"
+    android:paddingStart="16dp"
+    android:paddingEnd="16dp"
+    android:paddingTop="8dp"
+    android:paddingBottom="8dp"
+    android:background="@color/white"
+    android:elevation="8dp"
+    />
diff --git a/core/res/res/layout/resolver_list.xml b/core/res/res/layout/resolver_list.xml
index 8e57543..727f9c6 100644
--- a/core/res/res/layout/resolver_list.xml
+++ b/core/res/res/layout/resolver_list.xml
@@ -21,38 +21,36 @@
     android:layout_width="match_parent"
     android:layout_height="match_parent"
     android:maxWidth="@dimen/resolver_max_width"
-    android:maxCollapsedHeight="260dp"
+    android:maxCollapsedHeight="192dp"
     android:maxCollapsedHeightSmall="56dp"
     android:id="@id/contentPanel"
     >
 
     <TextView android:id="@+id/title"
               android:layout_width="match_parent"
-              android:layout_height="?android:attr/listPreferredItemHeight"
+              android:layout_height="wrap_content"
               android:layout_alwaysShow="true"
+              android:minHeight="56dp"
               android:textAppearance="?android:attr/textAppearanceMedium"
               android:gravity="start|center_vertical"
-              android:paddingLeft="32dp"
-              android:paddingRight="32dp"
+              android:paddingStart="16dp"
+              android:paddingEnd="16dp"
+              android:paddingTop="8dp"
+              android:paddingBottom="8dp"
               android:background="@color/white"
               android:elevation="8dp"
               />
 
-    <GridView
+    <ListView
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:id="@+id/resolver_list"
-        android:numColumns="4"
-        android:columnWidth="128dp"
         android:clipToPadding="false"
         android:scrollbarStyle="outsideOverlay"
-        android:paddingLeft="32dp"
-        android:paddingRight="32dp"
-        android:paddingTop="16dp"
-        android:paddingBottom="16dp"
         android:background="@color/white"
         android:elevation="8dp"
         android:nestedScrollingEnabled="true"
+        android:divider="@null"
         />
 
     <TextView android:id="@+id/empty"
@@ -72,14 +70,15 @@
         android:layout_height="wrap_content"
         android:layout_ignoreOffset="true"
         android:layout_alwaysShow="true"
-        android:gravity="end"
+        android:gravity="end|center_vertical"
         android:orientation="horizontal"
         android:layoutDirection="locale"
         android:measureWithLargestChild="true"
         android:background="@color/white"
-        android:paddingBottom="16dp"
-        android:paddingStart="32dp"
-        android:paddingEnd="32dp"
+        android:paddingTop="8dp"
+        android:paddingBottom="8dp"
+        android:paddingStart="12dp"
+        android:paddingEnd="12dp"
         android:elevation="8dp">
         <Button android:id="@+id/button_once"
                 android:layout_width="wrap_content"
diff --git a/core/res/res/layout/resolver_list_with_default.xml b/core/res/res/layout/resolver_list_with_default.xml
index 0bd0e14..884f41e 100644
--- a/core/res/res/layout/resolver_list_with_default.xml
+++ b/core/res/res/layout/resolver_list_with_default.xml
@@ -21,7 +21,7 @@
     android:layout_width="match_parent"
     android:layout_height="match_parent"
     android:maxWidth="@dimen/resolver_max_width"
-    android:maxCollapsedHeight="48dp"
+    android:maxCollapsedHeight="144dp"
     android:id="@id/contentPanel"
     >
 
@@ -35,26 +35,28 @@
 
         <LinearLayout
             android:layout_width="match_parent"
-            android:layout_height="80dp"
-            android:paddingStart="32dp"
-            android:paddingEnd="32dp"
+            android:layout_height="64dp"
             android:orientation="horizontal"
             >
 
+            <ImageView android:id="@+id/icon"
+                       android:layout_width="24dp"
+                       android:layout_height="24dp"
+                       android:layout_gravity="start|top"
+                       android:layout_marginStart="16dp"
+                       android:layout_marginEnd="16dp"
+                       android:layout_marginTop="20dp"
+                       android:scaleType="fitCenter"
+                       />
             <TextView android:id="@+id/title"
                       android:layout_width="0dp"
                       android:layout_weight="1"
                       android:layout_height="?android:attr/listPreferredItemHeight"
+                      android:layout_marginStart="16dp"
                       android:textAppearance="?android:attr/textAppearanceMedium"
                       android:gravity="start|center_vertical"
                       android:paddingEnd="16dp"
                       />
-            <ImageView android:id="@+id/icon"
-                       android:layout_width="56dp"
-                       android:layout_height="56dp"
-                       android:layout_gravity="center_vertical"
-                       android:scaleType="fitCenter"
-                       />
         </LinearLayout>
 
         <LinearLayout
@@ -64,13 +66,14 @@
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
             android:layout_alwaysShow="true"
-            android:gravity="end"
+            android:gravity="end|center_vertical"
             android:orientation="horizontal"
             android:layoutDirection="locale"
             android:measureWithLargestChild="true"
-            android:paddingBottom="16dp"
-            android:paddingStart="32dp"
-            android:paddingEnd="32dp"
+            android:paddingTop="8dp"
+            android:paddingBottom="8dp"
+            android:paddingStart="12dp"
+            android:paddingEnd="12dp"
             android:background="@color/white"
             android:elevation="8dp">
             <Button android:id="@+id/button_once"
@@ -99,21 +102,16 @@
               android:background="?android:attr/dividerVertical" />
     </LinearLayout>
 
-    <GridView
+    <ListView
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:id="@+id/resolver_list"
-        android:numColumns="4"
-        android:columnWidth="128dp"
         android:clipToPadding="false"
         android:scrollbarStyle="outsideOverlay"
-        android:paddingLeft="32dp"
-        android:paddingRight="32dp"
-        android:paddingTop="16dp"
-        android:paddingBottom="16dp"
         android:background="@color/white"
         android:elevation="8dp"
         android:nestedScrollingEnabled="true"
+        android:divider="@null"
         />
 
 </com.android.internal.widget.ResolverDrawerLayout>
diff --git a/core/res/res/layout/screen_toolbar.xml b/core/res/res/layout/screen_toolbar.xml
index 039e89f..88c9cf6 100644
--- a/core/res/res/layout/screen_toolbar.xml
+++ b/core/res/res/layout/screen_toolbar.xml
@@ -41,6 +41,7 @@
             android:id="@+id/action_bar"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
+            android:navigationContentDescription="@string/action_bar_up_description"
             style="?attr/toolbarStyle" />
         <com.android.internal.widget.ActionBarContextView
             android:id="@+id/action_context_bar"
diff --git a/core/res/res/layout/simple_spinner_dropdown_item.xml b/core/res/res/layout/simple_spinner_dropdown_item.xml
index e2bd474..f276cfa 100644
--- a/core/res/res/layout/simple_spinner_dropdown_item.xml
+++ b/core/res/res/layout/simple_spinner_dropdown_item.xml
@@ -4,24 +4,23 @@
 **
 ** Copyright 2008, 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 
+** 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 
+**     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 
+** 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.
 */
 -->
-<CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android" 
+<CheckedTextView xmlns:android="http://schemas.android.com/apk/res/android"
     android:id="@android:id/text1"
     style="?android:attr/spinnerDropDownItemStyle"
     android:singleLine="true"
     android:layout_width="match_parent"
     android:layout_height="?android:attr/dropdownListPreferredItemHeight"
-    android:ellipsize="marquee"
-    android:textAlignment="inherit"/>
+    android:ellipsize="marquee"/>
diff --git a/core/res/res/layout/time_picker_holo.xml b/core/res/res/layout/time_picker_holo.xml
index 483eb6d..08d2211 100644
--- a/core/res/res/layout/time_picker_holo.xml
+++ b/core/res/res/layout/time_picker_holo.xml
@@ -18,20 +18,17 @@
 -->
 
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-          android:layout_width="wrap_content"
-          android:layout_height="match_parent"
-          android:orientation="vertical"
-          android:focusable="true" >
+    android:layout_width="wrap_content"
+    android:layout_height="match_parent"
+    android:orientation="vertical">
     <include
-            layout="@layout/time_header_label"
-            android:layout_width="match_parent"
-            android:layout_height="@dimen/timepicker_header_height"
-            android:layout_gravity="center" />
+        layout="@layout/time_header_label"
+        android:layout_width="match_parent"
+        android:layout_height="@dimen/timepicker_header_height"
+        android:layout_gravity="center" />
     <android.widget.RadialTimePickerView
-            android:id="@+id/radial_picker"
-            android:layout_width="wrap_content"
-            android:layout_height="@dimen/timepicker_radial_picker_dimen"
-            android:layout_gravity="center"
-            android:focusable="true"
-            android:focusableInTouchMode="true" />
+        android:id="@+id/radial_picker"
+        android:layout_width="wrap_content"
+        android:layout_height="@dimen/timepicker_radial_picker_dimen"
+        android:layout_gravity="center" />
 </LinearLayout>
diff --git a/core/res/res/layout/time_picker_legacy_leanback.xml b/core/res/res/layout/time_picker_legacy_leanback.xml
deleted file mode 100644
index b4e5e3e..0000000
--- a/core/res/res/layout/time_picker_legacy_leanback.xml
+++ /dev/null
@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-     Copyright (C) 2014 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.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:id="@+id/timePickerLayout"
-    android:orientation="horizontal"
-    android:layout_gravity="center_horizontal"
-    android:layout_width="wrap_content"
-    android:layout_height="wrap_content"
-    android:paddingStart="8dip"
-    android:paddingEnd="8dip">
-
-    <LinearLayout android:orientation="horizontal"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:paddingStart="8dip"
-        android:paddingEnd="8dip"
-        android:layoutDirection="ltr">
-
-        <!-- hour -->
-        <NumberPicker
-            android:id="@+id/hour"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="16dip"
-            android:layout_marginBottom="16dip"
-            android:focusable="true"
-            android:focusableInTouchMode="true"
-            />
-
-        <!-- divider -->
-        <TextView
-            android:id="@+id/divider"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginStart="6dip"
-            android:layout_marginEnd="6dip"
-            android:layout_gravity="center_vertical"
-            android:importantForAccessibility="no"
-            />
-
-        <!-- minute -->
-        <NumberPicker
-            android:id="@+id/minute"
-            android:layout_width="wrap_content"
-            android:layout_height="wrap_content"
-            android:layout_marginTop="16dip"
-            android:layout_marginBottom="16dip"
-            android:focusable="true"
-            android:focusableInTouchMode="true"
-            />
-
-    </LinearLayout>
-
-    <!-- AM / PM -->
-    <NumberPicker
-        android:id="@+id/amPm"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_marginTop="16dip"
-        android:layout_marginBottom="16dip"
-        android:layout_marginStart="8dip"
-        android:layout_marginEnd="8dip"
-        android:focusable="true"
-        android:focusableInTouchMode="true"
-        />
-
-</LinearLayout>
diff --git a/core/res/res/layout/user_switching_dialog.xml b/core/res/res/layout/user_switching_dialog.xml
new file mode 100644
index 0000000..8617e5d
--- /dev/null
+++ b/core/res/res/layout/user_switching_dialog.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+     Copyright (C) 2014 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.
+-->
+
+<TextView xmlns:android="http://schemas.android.com/apk/res/android"
+        android:id="@+id/message"
+        style="?attr/textAppearanceListItem"
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:gravity="center"
+        android:paddingStart="@dimen/alert_dialog_padding_material"
+        android:paddingEnd="@dimen/alert_dialog_padding_material"
+        android:paddingTop="24dp"
+        android:paddingBottom="24dp" />
diff --git a/core/res/res/values-af/strings.xml b/core/res/res/values-af/strings.xml
index 45a392b..ca94c3a 100644
--- a/core/res/res/values-af/strings.xml
+++ b/core/res/res/values-af/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Dit laat die houer toe om aan die top-koppelvlak van \'n afstandskerm te koppel. Behoort nooit vir gewone programme nodig te wees nie."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bind aan \'n legstukdiens"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Dit laat die houer toe om aan die topvlak-koppelvlak van \'n legstuk-diens te bind. Dit moet nooit vir normale programme nodig wees nie."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bind aan \'n roeteverskafferdiens"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Laat die houer toe om aan enige geregistreerde roeteverskaffers te bind. Behoort nooit vir normale programme nodig te wees nie."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"skakel met \'n toestel-admin"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Laat die houer toe om bedoelings na \'n toesteladministrateur te stuur. Dit moet nooit vir normale programme nodig wees nie."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bind aan \'n TV-invoer"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"Sit foon aan of af"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Laat die program toe om die tablet aan en af te skakel."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Laat die program toe om die foon aan en af te skakel."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"stel skermuitteltyd terug"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Laat die program toe om die skermuitteltyd terug te stel."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"laat loop in fabriekstoetsmodus"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Laat loop as \'n laevlak-vervaardigertoets, sodat volle toegang tot die tablethardeware verkry word. Net beskikbaar wanneer \'n tablet in vervaardigertoetsmodus loop."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Laat loop as \'n laevlak-vervaardigertoets, sodat volle toegang tot die foonhardeware verkry word. Net beskikbaar wanneer \'n foon in vervaardigertoets-modus loop."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Laat die program toe om die kaslêerstelsel te lees en skryf."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"maak en/of ontvang SIP-oproepe"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Laat die program toe om SIP-oproepe te maak en te ontvang."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"beleef interaksie met in-oproep-skerm"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Laat die program beheer wanneer en hoe die gebruiker die in-oproep-skerm sien."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"beleef interaksie met inoproep-skerm"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Laat die program beheer wanneer en hoe die gebruiker die inoproep-skerm sien."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"werk met telefoniedienste saam"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Laat die program toe om met telefoniedienste saam te werk om oproepe te maak of ontvang."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"bied \'n inoproep-gebruikerervaring"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Laat die program toe om \'n inoproep-gebruikerervaring te bied."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lees netwerkgebruik-geskiedenis"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Laat die program toe om historiese netwerkgebruik vir spesifieke netwerke en programme te lees."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"bestuur netwerkbeleid"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Laat die houer toe om aan die top-koppelvlak van \'n kennisgewingluisteraardiens te bind. Behoort nooit vir gewone programme nodig te wees nie."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"verbind met \'n toestandverskafferdiens"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Laat die houer toe om met die topvlak-koppelvlak van \'n toestandverskafferdiens te verbind. Behoort nooit vir normale programme nodig te wees nie."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bind aan \'n mediaroetediens"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Laat die houer toe om aan die topvlakkoppelvlak van \'n mediaroetediens te bind. Behoort nooit vir normale programme nodig te wees nie."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bind aan \'n droomdiens"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Laat die houer toe om aan die topvlak-koppelvlak van \'n droomdiens te bind. Behoort nooit vir normale programme nodig te wees nie."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"roep die opstellingprogram op wat deur die diensverskaffer voorsien is"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Deel met %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Kies \'n tuisprogram"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Gebruik hierdie aksie by verstek."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Gebruik \'n ander program"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Vee die verstek instelling uit in Stelselinstellings &gt; Programme &gt; Afgelaai."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Kies \'n handeling"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Kies \'n program vir die USB-toestel"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Laat toe"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Weier"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; wil \'n boodskap na &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; stuur."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Hierdie "<font fgcolor="#ffffb060">"kan heffings veroorsaak"</font>" op jou selfoonrekening."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Dit sal heffings op jou selfoonrekening veroorsaak."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Dit "<b>"kan heffings veroorsaak"</b>" op jou selfoonrekening."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Dit sal heffings op jou selfoonrekening veroorsaak."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Stuur"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Kanselleer"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Onthou my keuse"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Raak om USB-ontfouting te deaktiveer."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Verander sleutelbord"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Kies sleutelborde"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fisiese sleutelbord"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Wys invoermetode"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardeware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Kies sleutelborduitleg"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Raak om \'n sleutelborduitleg te kies."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Laat \'n program toe om met \'n vertrouensagentdiens te verbind."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Tree in wisselwerking met opdatering- en terugstellingstelsel"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Laat \'n program met die terugstellingstelsel en stelselopdaterings in wisselwerking tree."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Skep mediaprojeksiesessies"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Laat \'n program toe om mediaprojeksiesessies te skep. Hierdie sessies kan programme die vermoë gee om skerm- en oudio-inhoud vas te vang. Behoort nooit nodig te wees vir normale programme nie."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Bestuur mediaprojeksiesessies"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Laat \'n program toe om mediaprojeksiesessies te bestuur. Hierdie sessies kan programme die vermoë gee om skerm- en oudio-inhoud vas te vang. Behoort nooit vir normale programme nodig te wees nie."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Lees installasiesessies"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Laat \'n program toe om installasiesessies te lees. Dit laat dit toe om besonderhede van aktiewe pakketinstallasies te sien."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Raak twee keer vir zoembeheer"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Weier"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Toestemming versoek"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Toestemming versoek\nvir rekening <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Jy gebruik tans hierdie program in jou persoonlike spasie"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Jy gebruik hierdie program in jou werkspasie"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Jy gebruik hierdie program buite jou werkprofiel"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Jy gebruik tans hierdie program in jou werkprofiel"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Invoermetode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinkroniseer"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Toeganklikheid"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Verminder uur"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Stel NM."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Stel VM."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"nm"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"vm"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Vermeerder maand"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Verminder maand"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Vermeerder dag"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Redigeer"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Dataverbruik-waarskuwing"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Raak gebruik/instellings te sien."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G-data is af"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-data is af"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Sellulêre data is af"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-data is af"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limiet bereik"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G-datalimiet bereik"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G-datalimiet bereik"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Sellulêredata-limiet bereik"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi-datalimiet bereik"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data vir res van siklus laat wag"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G-datalimiet oorskry"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G-datalimiet oorskry"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Sellulêredata-limiet oorskry"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Aanvaar oproep?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Altyd"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Net een keer"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s steun nie werkprofiel nie."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s steun nie werkprofiel nie"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Foon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Oorfone"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Toeganklikheid geaktiveer."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Toeganklikheid gekanselleer."</string>
     <string name="user_switched" msgid="3768006783166984410">"Huidige gebruiker <xliff:g id="NAME">%1$s</xliff:g> ."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Skakel tans oor na <xliff:g id="NAME">%1$s</xliff:g> …"</string>
     <string name="owner_name" msgid="2716755460376028154">"Eienaar"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Fout"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Hierdie verandering word nie deur jou administrateur toegelaat nie"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> gekies"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> uitgevee"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Werk-<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Om hierdie skerm te ontspeld, raak en hou Terug en Onlangse programme tegelyk."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Om hierdie skerm te ontspeld, raak en hou Onlangse programme."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skerm is vasgespeld. Jou organisasie laat nie toe dat dit ontspeld word nie."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Gebruik skermvasspeld?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Skermvasspeld sluit die skerm in \'n enkele aansig vas.\n\nOm uit te gaan, raak en hou Terug en Onlangse programme tegelyk."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Skermvasspeld sluit die skerm in \'n enkele aansig vas.\n\nOm uit te gaan, raak en hou Onlangse programme."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NEE, DANKIE"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"BEGIN"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ontsluitpatroon"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"wagwoord"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skerm vasgespeld"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skerm ontspeld"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Vra PIN voordat jy ontspeld"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Vra ontsluitpatroon voordat jy ontspeld"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Vra wagwoord voordat jy ontspeld"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Om batteryleeftyd te help verbeter, verminder batterybespaarder jou toestel se werkverrigting en beperk vibrasie en die meeste agtergronddata. E-pos, boodskappe en ander programme wat op sinkronisering staatmaak, sal dalk nie opdateer nie tensy jy hulle oopmaak.\n\nBatterybespaarder skakel outomaties af wanneer jou toestel laai."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Totdat jou ontspantyd om <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> eindig"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Een minuut lank"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d minute lank"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Een uur lank"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d uur lank"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Onbepaalde tyd"</string>
 </resources>
diff --git a/core/res/res/values-am/strings.xml b/core/res/res/values-am/strings.xml
index 91f777d..05746b6 100644
--- a/core/res/res/values-am/strings.xml
+++ b/core/res/res/values-am/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ያዢው ከአንድ የርቀት ማሳያ ከፍተኛ-ደረጃ በይነገጽ ጋር እንዲጠርዝ ይፈቅድለታል። ለመደበኛ መተግበሪያዎች በጭራሽ አያስፈልግም።"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ወደ ፍርግም አገልግሎት አያይዝ"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ያዡ ግቤት ስልቱን ወደ ከፍተኛ-ደረጃ ፍርግም አገልግሎት ለመጠረዝ  ይፈቅዳሉ። ለመደበኛ ትግበራዎች በፍፁም አያስፈልግም።"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"ከመንገድ አቅራቢዎች አገልግሎት ጋር ያስተሳስሩ"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"አቃፊው ከማናቸውም የተመዘገቡ የመንገድ አቅራቢዎች ጋር እንዲተሳሰር ይፈቅድለታል። ለመደበኛ መተግበሪያዎች በጭራሽ ሊያስፈልግ አይገባም።"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ከመሣሪያ አስተዳደር ጋር ተገናኝ"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ያዡ በይነመረብን ለመሣሪያ አስተዳዳሪ ለመላክ ይፈቅዳሉ። ለመደበኛ መተግበሪያዎች በፍፁም አያስፈልግም።"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ከአንድ የቴሌቪዥን ግብዓት ጋር እሰር"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ስልክ አብራ ወይም አጥፋ"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ጡባዊ ተኮውን ለማብራት እና ለማጥፋት ለመተግበሪያው ይፈቅዳሉ።"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ስልኩን ለማብራት እና ለማጥፋት ለመተግበሪያው ይፈቅዳሉ።"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"የማሳያ እረፍት መውሰጃ ዳግም አስጀምር"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"መተግበሪያው የማሳያው እረፍት መውሰጃውን ዳግም እንዲያስጀምር ያስችለዋል።"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"የፋብሪካ ሙከራ ሁነታ አሂድ"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ለመሣሪያው ሀርድዌር ሙሉ ድረስበመፍቀድ እንደ ዝቅተኛ-ደረጃ አምራች ሙከራ አሂድ። የሚገኘው መሣሪያው በአምራች ሙከራ ሁነታ ላይ ሲአሄድ ብቻ ነው።"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ለስልኩ ሀርድዌር ሙሉመድረስበመፍቀድእንደ ዝቅተኛ-ደረጃ አምራች ሙከራ አሂድ። የሚገኘው ስልኩ በአምራች ሙከራ ሁነታ ላይ ሲአሄድ ብቻ ነው።"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"መሸጎጫ ስርዓተ ፋይል ለማንበብ እና ለመፃፍ ለመተግበሪያው ይፈቅዳሉ።"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"የSIP ጥሪዎችን ያድርጉ/ይቀበሉ"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"መተግበሪያው የSIP ጥሪዎችን እንዲያደር እና እንዲቀበል ያስችላል።"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ከጥሪ ውስጥ ማያ ገጽ ጋር ይገናኝ"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"መተግበሪያው ተጠቃሚው በጥሪ ውስጥ ያለውን ማያ ገጽ መቼ እና እንዴት ማየት እንደሚችል እንዲቆጣጠር ይፈቅድለታል።"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ከውስጠ-ጥሪ ማያ ገጽ ጋር መስተጋብር ይፈጥራል"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"መተግበሪያው ተጠቃሚው በጥሪ ውስጥ ያለውን ማያ ገጽ መቼ እና እንዴት ማየት እንደሚችል እንዲቆጣጠር ይፈቅድለታል።"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ከስልክ አገልግሎቶች ጋር መስተጋብር ይፈጥራል"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"መተግበሪያው ጥሪዎችን እንዲያደርግ/እንዲቀበል ከስልክ አገልግሎቶች ጋር መስተጋብር እንዲፈጥር ያስችለዋል።"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"የውስጠ-ጥሪ ተጠቃሚ ተሞክሮ ያቀርባል"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"መተግበሪያው የውስጠ-ጥሪ ተጠቃሚ ተሞክሮ እንዲያቀርብ ያስችለዋል።"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"የታሪካዊ አውታረመረብ አጠቃቀም አንብብ"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"የተወሰኑ የአውታረ መረቦች እና ትግበራዎችን ታሪካዊ የአውታረመረብ አጠቃቀም ለማንበብ ለመተግበሪያው ይፈቅዳሉ፡፡"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"የአውታረ መረብ መምሪያ አደራጅ"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ያዢው የማሳወቂያ አዳማጭ አገልግሎቱን ከከፍተኛ-ደረጃ በይነገጹ ጋር እንዲያስር ያስችለዋል። ለመደበኛ መተግበሪያዎች በጭራሽ አያስፈልግም።"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"ከአንድ የሁኔታ አቅራቢ አገልግሎት ጋር ይሰሩ"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"ያዢው የአንድ የሁኔታ አቅራቢ አገልግሎት የከፍተኛ ደረጃ በይነገጽ እንዲያስር ያስችለዋል። ለመደበኛ መተግበሪያዎች በጭራሽ አያስፈልግም።"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"ከአንድ ማህደረመረጃ ማዞር አገልግሎት ጋር ያስተሳስራል"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"ያዢው የአንድ ማህደረመረጃ ማዞር አገልግሎት የከፍተኛ ደረጃ በይነገጽ እንዲያስር ያስችለዋል። ለመደበኛ መተግበሪያዎች በጭራሽ አያስፈልግም።"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ከህልም አገልግሎት ጋር ጠርዝ"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ያዢው የህልም አገልግሎቱን ከከፍተኛ-ደረጃ በይነገጽ ጋር እንዲጠርዝ ይፈቅዳል። ለመደበኛ መተግበሪያዎች በጭራሽ አያስፈልግም።"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"በድምጸ-ተያያዥ ሞደም የቀረበው የውቅር መተግበሪያውን መጥራት"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"በ%1$s ያጋሩ"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"የመነሻ መተግበሪያ ይምረጡ"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ለዕርምጃ ነባሪ ተጠቀም።"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"የተለየ መተግበሪያ ይጠቀሙ"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"ነባሪ አጽዳ በስርዓት ቅንብሮች  ውስጥ  &gt; Apps &amp;gt፤ወርዷል፡፡"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ድርጊት ምረጥ"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"ለUSB መሳሪያ መተግበሪያ ምረጥ"</string>
@@ -1213,10 +1212,10 @@
     <string name="aerr_application" msgid="932628488013092776">"መጥፎ ዕድል ሆኖ፣ <xliff:g id="APPLICATION">%1$s</xliff:g> አቁሞዋል፡፡"</string>
     <string name="aerr_process" msgid="4507058997035697579">"መጥፎ ዕድል ሆኖ፣ ይሄ ሂደት <xliff:g id="PROCESS">%1$s</xliff:g> ቆሞዋል፡፡"</string>
     <string name="anr_title" msgid="4351948481459135709"></string>
-    <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g>ምላሽ እየሰጠ አይደለም።\n\nመዝጋት ትፈልጋለህ?"</string>
-    <string name="anr_activity_process" msgid="5776209883299089767">"እንቅስቃሴ <xliff:g id="ACTIVITY">%1$s</xliff:g>ምላሽ እየሰጠ አይደለም።\n\nመዝጋት ትፈልጋለህ?"</string>
-    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g>ምላሽ እየሰጠ አይደለም።መዝጋት ትፈልጋለህ?"</string>
-    <string name="anr_process" msgid="6513209874880517125">" ሂደት<xliff:g id="PROCESS">%1$s</xliff:g> ምላሽ እየሰጠ አይደለም።\n\nመዝጋት ትፈልጋለህ?"</string>
+    <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g> ምላሽ እየሰጠ አይደለም።\n\n መዝጋት ይፈልጋሉ?"</string>
+    <string name="anr_activity_process" msgid="5776209883299089767">"እንቅስቃሴ <xliff:g id="ACTIVITY">%1$s</xliff:g> ምላሽ እየሰጠ አይደለም።\n\n መዝጋት ይፈልጋሉ?"</string>
+    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g> ምላሽ እየሰጠ አይደለም። መዝጋት ይፈልጋሉ?"</string>
+    <string name="anr_process" msgid="6513209874880517125">"ሂደት <xliff:g id="PROCESS">%1$s</xliff:g> ምላሽ እየሰጠ አይደለም።\n\n መዝጋት ይፈልጋሉ?"</string>
     <string name="force_close" msgid="8346072094521265605">"ይሁን"</string>
     <string name="report" msgid="4060218260984795706">"ሪፖርት"</string>
     <string name="wait" msgid="7147118217226317732">"ቆይ"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"ፍቀድ"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ከልክል"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ለ&lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; መልዕክት ለመላክ ይፈልጋል።"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ይሄ በተንቀሳቃሽ ስልክ መለያዎ ላይ "<font fgcolor="#ffffb060">"ክፍያዎችን ሊያስከትል ይችላል"</font>"።"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"ይሄ በተንቀሳቃሽ ስልክ መለያዎ ላይ ክፍያዎችን ያስከትላል።"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"ይሄ በእርስዎ የተንቀሳቃሽ ስልክ ሒሳብ ላይ "<b>"ወጪዎችን ሊያስከትል ይችላል"</b>"።"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ይሄ በእርስዎ የተንቀሳቃሽ ስልክ ሒሳብ ላይ ወጪዎችን ያስከትላል።"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ላክ"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ይቅር"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ምርጫዬን አስታውስ"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB ማረሚያ ላለማንቃት ዳስስ።"</string>
     <string name="select_input_method" msgid="8547250819326693584">"ቁልፍ ሰሌዳ ይቀይሩ"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"ቁልፍ ሰሌዳዎችን ምረጥ"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"የሚዳሰስ የቁልፍ ሰሌዳ"</string>
+    <string name="show_ime" msgid="9157568568695230830">"የግቤት ስልት አሳይ"</string>
     <string name="hardware" msgid="7517821086888990278">"ሃርድዌር"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"የቁልፍ ሰሌዳ አቀማመጥ ምረጥ"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"የቁልፍ ሰሌዳ አቀማመጥ ለመምረጥ ንካ።"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"ለመተግበሪያን የተአማኒነት ወኪል አገልግሎትን እንዲያከብር ይፈቅዳል።"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"ከዝማኔዎች እና ከመልሶ ማግኛ ስርዓቶች ጋር ይገናኙ"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"መተግበሪያው ከመልሶ ማግኛ ስርዓት እና ከስርዓት ማዘመኛዎች ጋር እንዲገናኝ ይፈቅድለታል።"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"የማህደረ መረጃ ማሳየት ክፍለ ጊዜዎች ፍጠር"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"መተግበሪያው የማህደረ መረጃ ማሳያ ክፍለ ጊዜዎችን እንዲፈጥር ይፈቅድለታል። እነዚህ ክፍለ ጊዜዎች ለመተግበሪያዎች ማሳያንና የተሰሚ ይዘቶችን ይዘው እንዲያቆዩ ችሎታውን ይሰጧቸዋል። በመደበኛ መተግበሪያዎች መፈለግ የለበትም።"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"የማህደረመረጃ ይዘት አቅርቦት ክፍለ-ጊዜዎችን ያቀናብራል"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"አንድ መተግበሪያ የማህደረመረጃ ይዘት አቅርቦት ክፍለ-ጊዜዎችን እንዲያቀናብር ያስችለዋል። እነዚህ ክፍለ-ጊዜዎች የማሳያ እና የተሰሚ ይዘቶችን የመቅረጽ ችሎታ ለመተግበሪያዎች ሊያቀርብ ይችላሉ። በመደበኛ መተግበሪያዎች በጭራሽ ሊያስፈልጉ አይገባም።"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"የመጫን ክፍለ ጊዜዎችን አንብብ"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"መተግበሪያው የመጫን ክፍለ ጊዜዎችን እንዲያነብ ይፈቅድለታል። ይህም ስለ ገቢር የጥቅል ጭነቶች ዝርዝር መረጃን እንዲያይ ይፈቅድለታል።"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ለአጉላ መቆጣጠሪያ ሁለት ጊዜ ነካ አድርግ"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"ያስተባብሉ"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"ፈቃድ ተጠይቋል"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">\n" ለ<xliff:g id="ACCOUNT">%s</xliff:g> መለያ ፈቃድ ተጠይቋል"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"ይህንን መተግበሪያ እየተጠቀሙ ያሉት በግል ቦታዎ ውስጥ ብቻ ነው"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"ይህንን መተግበሪያ እየተጠቀሙ ያሉት በግል ቦታዎ ውስጥ ነው"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"ከስራ መገለጫዎ ውጪ ሆነው መተግበሪያ እየተጠቀሙ ነው"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"ይህን መተግበሪያ በእርስዎ የስራ መገለጫ ላይ እየተጠቀሙበት ነው"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ግቤት ስልት"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"አስምር"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ተደራሽነት"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"ሰዓት ቀንስ"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM አዘጋጅ"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM አዘጋጅ"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ከሰዓት"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ጠዋት"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"ወር ጨምር"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ወር ቀንስ"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"ቀን ጨምር"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"አርትዕ"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"የውሂብ አጠቃቀም ማስጠንቀቂየ"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ቅንብሮችን እና አጠቃቀምን ለማየት ይንኩ።"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2ጂ-3ጂ ውሂብ ጠፍቷል"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4ጂ ውሂብ ጠፍቷል"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"የተንቀሳቃሽ ስልክ ውሂብ ጠፍቷል"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi ውሂብ ጠፍቷል"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ገደብ ላይ ተደርሷል"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"የ2ጂ-3ጂ ውሂብ ገደብ ላይ ተደርሷል"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"የ4ጂ ውሂብ ገደብ ላይ ተደርሷል"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"የተንቀሳቃሽ ስልክ ውሂብ ገደብ ላይ ተደርሷል"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"የWi-Fi ውሂብ ገደብ ላይ ተደርሷል"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ለተቀረው ዑደት ውሂብ ለአፍታ ቆሟል"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G የውሂብ ወሰን አልፏል"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ውሂብ ወሰን አልፏል"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"የተንቀሳቃሽ ስልክ ውሂብ ወሰን አልፏል"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"ጥሪ ተቀበል?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ዘወትር"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"አንዴ ብቻ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s የስራ መገለጫ አይደግፍም።"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s የስራ መገለጫ አይደግፍም"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ጡባዊ ተኮ"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ስልክ"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"የጆሮ ማዳመጫዎች"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ተደራሽነት ነቅቷል።"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ተደራሽነት ተሰርዟል።"</string>
     <string name="user_switched" msgid="3768006783166984410">"የአሁኑ ተጠቃሚ <xliff:g id="NAME">%1$s</xliff:g>።"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"ወደ <xliff:g id="NAME">%1$s</xliff:g> በመቀየር ላይ…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ባለቤት"</string>
     <string name="error_message_title" msgid="4510373083082500195">"ስህተት"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ይህ ለውጥ በአስተዳዳሪዎ አይፈቀድም"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ተመርጧል"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ተሰርዟል"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"ስራ <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ይህን ማያ ገጽ ለመንቀል ለመውጣት ተመለስን እና የቅርብ ጊዜዎችን አንድ ላይ ነክተው ይያዟቸው።"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ይህን ማያ ገጽ ለመንቀል ለመውጣት የቅርብ ጊዜዎችን አንድ ላይ ነክተው ይያዙት።"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"ማያ ገጽ ተሰክቷል። መንቀል በድርጅትዎ አይፈቀድም።"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"ማያ ገጽ መሰካትን ይጠቀሙ?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"ማያ ገጽ መሰካት ማሳያውን በአንዲት ነጠላ እይታ ውስጥ ይቆልፈዋል።\n\nለመውጣት ተመለስን እና የቅርብ ጊዜዎችን አንድ ላይ ነክተው ይያዟቸው።"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"ማያ ገጽ መሰካት ማሳያውን በአንዲት ነጠላ እይታ ውስጥ ይቆልፈዋል።\n\nለመውጣት የቅርብ ጊዜዎችን አንድ ላይ ነክተው ይያዙት።"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"አይ፣ አመሰግናለሁ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ጀምር"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"ፒን"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"የማስከፈቻ ስርዓተ-ጥለት"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"የይለፍ ቃል"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"ማያ ገጽ ተሰክቷል"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"ማያ ገጽ ተነቅሏል"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ከመንቀል በፊት ፒን ጠይቅ"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ከመንቀል በፊት የማስከፈቻ ስርዓተ-ጥለት ጠይቅ"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ከመንቀል በፊት የይለፍ ቃል ጠይቅ"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"የባትሪ ህይወትን ለማሻሻል ሲባል ባትሪ ቆጣቢ የመሣሪያዎ የስራ አፈጻጸምን እና ንዝረትንና አብዛኛውን የጀርባ ውሂብ ይቀንሳል። ኢሜይል፣ መልዕክት መላላኪያ እና ሌሎች በማመሳሰል ላይ የሚወሰኑ መተግበሪያዎች እስኪከፍቷቸው ድረስ ላይዘምኑ ይችላሉ።\n\nመሣሪያዎ ባትሪ እየሞላ ሲሆን ባትሪ ቆጣቢ በራስ-ሰር ይጠፋል።"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"የጥገና ጊዜዎ <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> ላይ እስኪያበቃ ድረስ"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ለአንድ ደቂቃ"</item>
+    <item quantity="other" msgid="6924190729213550991">"ለ%d ደቂቃዎች"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ለአንድ ሰዓት"</item>
+    <item quantity="other" msgid="5408537517529822157">"ለ%d ሰዓቶች"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"ያለገደብ"</string>
 </resources>
diff --git a/core/res/res/values-ar/strings.xml b/core/res/res/values-ar/strings.xml
index e0cd94c..4467285 100644
--- a/core/res/res/values-ar/strings.xml
+++ b/core/res/res/values-ar/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"للسماح للمالك بالالتزام بواجهة المستوى العلوي للعرض عن بُعد. لن تكون هناك حاجة إليه مطلقًا مع التطبيقات العادية."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"الالتزام بخدمة أداة"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"للسماح للمالك بالالتزام بواجهة المستوى العلوي لخدمة الأداة. لن تكون هناك حاجة إليه مطلقًا مع التطبيقات العادية."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"الربط مع خدمة مزود طريق"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"للسماح لحامل البطاقة الربط مع أي مزود طريق مسجل. لا يجب استخدامه على الإطلاق مع التطبيقات العادية."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"التفاعل مع مشرف الجهاز"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"للسماح للمالك بإرسال الأهداف إلى أحد مشرفي الجهاز. لن تكون هناك حاجة إليه مطلقًا مع التطبيقات العادية."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"الالتزام بإدخال التلفزيون"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"تشغيل الهاتف أو إيقاف تشغيله"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"للسماح للتطبيق بتشغيل الجهاز اللوحي أو إيقاف تشغيله."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"للسماح للتطبيق بتشغيل الهاتف أو إيقاف تشغيله."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"إعادة تعيين مهلة العرض"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"للسماح للتطبيق بإعادة تعيين مهلة العرض."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"تشغيل في وضع اختبار المصنع"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"التشغيل كاختبار للشركة المصنعة من المستوى المنخفض، مما يسمح بإكمال الدخول إلى الجهاز اللوحي. ويتوفر فقط عندما يتم تشغيل الجهاز اللوحي في وضع اختبار المصنِّع."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"للتشغيل كاختبار مصنِّع بمستوى أدنى، مما يسمح بالدخول الكامل إلى جهاز الهاتف. لا يتوفر سوى عند تشغيل الهاتف في وضع اختبار المصنِّع."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"للسماح للتطبيق بقراءة نظام ملفات ذاكرة التخزين المؤقت والكتابة به."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"‏إجراء/تلقي مكالمات SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"‏للسماح للتطبيق بإجراء مكالمات SIP وتلقيها."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"التفاعل مع الشاشة أثناء الاتصال"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"للسماح للتطبيق بالتحكم في وقت وكيفية مشاهدة المستخدم للشاشة أثناء الاتصال."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"التفاعل مع الشاشة أثناء الاتصال"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"للسماح للتطبيق بالتحكم في وقت وكيفية مشاهدة المستخدم للشاشة أثناء الاتصال."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"التفاعل مع الخدمات الهاتفية"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"للسماح للتطبيق بالتفاعل مع الخدمات الهاتفية لإجراء/تلقي المكالمات."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"توفير تجربة للمستخدم أثناء الاتصال"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"للسماح للتطبيق بتوفير تجربة للمستخدم أثناء الاتصال."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"قراءة بيانات الاستخدام السابقة للشبكة"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"للسماح للتطبيق بقراءة معلومات سابقة عن استخدام الشبكة لشبكات وتطبيقات محددة."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"إدارة سياسة الشبكة"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"يتيح للمالك الربط بواجهة المستوى العلوي لخدمة تلقّي الإشعارات الصوتية. ولن تكون هناك حاجة إليه مطلقًا مع التطبيقات العادية."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"الربط بخدمة موفر الحالة"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"للسماح للمالك بالربط بواجهة المستوى العلوي لخدمة موفر الحالة. لن تكون هناك حاجة إلى هذا الإعداد مطلقًا مع التطبيقات العادية."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"الربط بخدمة توجيه الوسائط"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"للسماح للمالك بالربط بواجهة المستوى العلوي لخدمة توجيه الوسائط. لن تكون هناك حاجة إلى هذا الإعداد مطلقًا مع التطبيقات العادية."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"‏الالتزام بخدمة dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"‏للسماح للمالك بالالتزام بواجهة المستوى العلوي لخدمة dream. لن تكون هناك حاجة إليه مطلقًا مع التطبيقات العادية."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"استدعاء تطبيق التهيئة الذي يوفره مشغل شبكة الجوال"</string>
@@ -1073,7 +1071,7 @@
   </plurals>
   <plurals name="num_hours_ago">
     <item quantity="one" msgid="9150797944610821849">"قبل ساعة واحدة"</item>
-    <item quantity="other" msgid="2467273239587587569">"قبل <xliff:g id="COUNT">%d</xliff:g> ساعة"</item>
+    <item quantity="other" msgid="2467273239587587569">"قبل <xliff:g id="COUNT">%d</xliff:g> ساعات"</item>
   </plurals>
   <plurals name="last_num_days">
     <item quantity="other" msgid="3069992808164318268">"آخر <xliff:g id="COUNT">%d</xliff:g> من الأيام"</item>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"‏مشاركة مع %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"تحديد تطبيق الشاشة الرئيسية"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"الاستخدام بشكل افتراضي لهذا الإجراء."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"استخدام تطبيق آخر"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"‏يمكنك محو الإعدادات الافتراضية في إعدادات النظام &gt; التطبيقات &gt; ما تم تنزيله."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"اختيار إجراء"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"‏اختيار أحد التطبيقات لجهاز USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"السماح"</string>
     <string name="sms_control_no" msgid="625438561395534982">"رفض"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"‏هناك رغبة من &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; في إرسال رسالة إلى &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"هذا "<font fgcolor="#ffffb060">"قد يؤدي إلى فرض رسوم"</font>" على حسابك على الجوال."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"سيؤدي هذا إلى فرض رسوم على حسابك على الجوال."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"ربما يؤدي هذا إلى تحصيل رسوم"</b>" من حساب الجوّال."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"سيؤدي هذا إلى تحصيل رسوم من حساب الجوّال."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"إرسال"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"إلغاء"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"تذكر اختياري"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"‏المس لتعطيل تصحيح أخطاء USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"تغيير لوحة المفاتيح"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"اختيار لوحات المفاتيح"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"لوحة مفاتيح فعلية"</string>
+    <string name="show_ime" msgid="9157568568695230830">"إظهار طريقة الإدخال"</string>
     <string name="hardware" msgid="7517821086888990278">"أجهزة"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"تحديد تخطيط لوحة مفاتيح"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"المس لتحديد تخطيط لوحة مفاتيح."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"للسماح لأحد التطبيقات بالالتزام بخدمة الوكيل المعتمد."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"التفاعل مع نظام التحديث والاسترداد"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"للسماح للتطبيق بالتفاعل مع نظام الاسترداد وتحديثات النظام."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"إنشاء جلسات عرض وسائط"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"للسماح لأحد التطبيقات بإنشاء جلسات عرض وسائط. ويُمكن لهذه الجلسات تمكين التطبيقات من التقاط محتويات مصورة وأخرى صوتية. ولا حاجة إليها مع التطبيقات العادية."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"إدارة جلسات عرض الوسائط"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"للسماح لتطبيق بإدارة جلسات عرض الوسائط. ويمكن أن تزود هذه الجلسات التطبيقات بإمكانية التقاط محتويات مرئية وصوتية. ولن تحتاج التطبيقات العادية إلى هذا الإعداد مطلقًا."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"قراءة جلسات التثبيت"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"للسماح لأحد التطبيقات بقراءة جلسات التثبيت. ويسمح لك هذا بالاطلاع على تفاصيل بشأن عمليات تثبيت الحزم النشطة."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"المس مرتين للتحكم في التكبير/التصغير"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"رفض"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"الإذن مطلوب"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"الإذن مطلوب\nللحساب <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"إنك تستخدم هذا التطبيق في مساحتك الشخصية"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"إنك تستخدم هذا التطبيق في مساحة العمل"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"أنت تستخدم هذا التطبيق خارج ملفك الشخصي للعمل"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"أنت تستخدم هذا التطبيق في ملفك الشخصي للعمل"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"طريقة الإرسال"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"مزامنة"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"إمكانية الدخول"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"تقليل الساعات"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"تعيين المساء"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"تعيين الصباح"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"م"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ص"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"زيادة الشهور"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"تقليل الشهور"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"زيادة الأيام"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"تعديل"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"تحذير استخدام البيانات"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"المس لعرض الاستخدام والإعدادات."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2-3 غيغابايت من البيانات المعطلة"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4 غيغابايت من البيانات المعطلة"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"البيانات الخلوية معطلة"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"‏بيانات Wi-Fi معطلة"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"تم بلوغ الحد المعين"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"‏تم بلوغ حد بيانات اتصال 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"‏تم بلوغ حد بيانات اتصال 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"تم بلوغ حد بيانات الجوّال"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"‏تم بلوغ حد بيانات Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"توقفت البيانات مؤقتًا لاستكمال الدورة"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"‏تم تجاوز حد بيانات شبكات 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"‏تم تجاوز حد بيانات 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"تم تجاوز حد البيانات الخلوية"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"هل تريد قبول المكالمة؟"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"دومًا"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"مرة واحدة فقط"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"‏لا يدعم %1$s الملفات الشخصية للعمل."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"‏لا يدعم %1$s الملفات الشخصية للعمل"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"الجهاز اللوحي"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"الهاتف"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"سماعات رأس"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"تم تمكين إمكانية الدخول."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"تم إلغاء تسهيل الدخول."</string>
     <string name="user_switched" msgid="3768006783166984410">"المستخدم الحالي <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"جارٍ التبديل إلى <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"المالك"</string>
     <string name="error_message_title" msgid="4510373083082500195">"خطأ"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"لا يسمح المشرف بإجراء هذا التغيير"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"تم تحديد <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"تم حذف <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> المخصص للعمل"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"لإلغاء تثبيت هذه الشاشة، المس مع الاستمرار زر الرجوع وزر التطبيقات الأخيرة في الوقت نفسه."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"لإلغاء تثبيت هذه الشاشة، المس مع الاستمرار زر التطبيقات الأخيرة."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"الشاشة مثبتة. لا تسمح منظمتك بإلغاء التثبيت."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"هل تريد استخدام تثبيت الشاشة؟"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"يؤدي تثبيت الشاشة إلى تقييد شاشة العرض بمشهد واحد.\n\nلإنهاء تثبيت الشاشة، المس مع الاستمرار زر الرجوع وزر التطبيقات الأخيرة في الوقت نفسه."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"يؤدي تثبيت الشاشة إلى تقييد شاشة العرض بمشهد واحد.\n\nلإنهاء تثبيت الشاشة، المس مع الاستمرار زر \"التطبيقات الأخيرة\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"لا، شكرًا"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"بدء"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"رقم التعريف الشخصي"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"نقش إلغاء القفل"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"كلمة المرور"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"تم تثبيت الشاشة"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"تم إلغاء تثبيت الشاشة"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"المطالبة برقم التعريف الشخصي قبل إزالة التثبيت"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"المطالبة بنقش إلغاء القفل قبل إزالة التثبيت"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"المطالبة بكلمة المرور قبل إزالة التثبيت"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"للمساعدة في تحسين مدة تشغيل البطارية، يقلل وضع توفير طاقة البطارية أداء جهازك ويقلل من الاهتزاز ومعظم بيانات الخلفية. وقد لا يتم تحديث البريد الإلكتروني والمراسلة والتطبيقات الأخرى التي تعتمد على المزامنة ما لم تفتحها.\n\nيتم إيقاف وضع توفير طاقة البطارية تلقائيًا عندما يكون الجهاز قيد الشحن."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"إلى أن ينتهي وقت التوقف عن العمل في <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"لمدة دقيقة واحدة"</item>
+    <item quantity="other" msgid="6924190729213550991">"‏لمدة %d من الدقائق"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"لمدة ساعة واحدة"</item>
+    <item quantity="other" msgid="5408537517529822157">"‏لمدة %d من الساعات"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"إلى أجل غير مسمى"</string>
 </resources>
diff --git a/core/res/res/values-bg/strings.xml b/core/res/res/values-bg/strings.xml
index 51d11c6..ba776c3 100644
--- a/core/res/res/values-bg/strings.xml
+++ b/core/res/res/values-bg/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Разрешава на притежателя да се свърже с интерфейса от първо ниво на отдалечен екран. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"обвързване с услуга за приспособления"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Разрешава на притежателя да се обвърже с интерфейса от най-високото ниво на услуга за приспособления. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"свързване с услуга за предоставяне на маршрути"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Разрешава на собственика да се свързва с всички регистрирани доставчици на маршрути. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"взаимодействие с администратор на устройството"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Разрешава на притежателя да изпраща намерения до администратор на устройството. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"свързване към вход на телевизор"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"включване или изключване на телефона"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Разрешава на приложението да включва или изключва таблета."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Разрешава на приложението да включва или изключва телефона."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"нулиране на времето за изчакване на екрана"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Разрешава на приложението да нулира времето за изчакване на екрана."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"изпълнение в режим на фабричен тест"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Изпълнява се като тест на ниско ниво от производителя, което позволява пълен достъп до хардуера на таблета. Налице е само когато таблетът работи в режим на тест от производителя."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Изпълнява се като тест на ниско ниво от производителя, което позволява пълен достъп до хардуера на телефона. Налице е само когато телефонът работи в режим на тест от производителя."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Разрешава на приложението да чете и записва във файловата система на кеша."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"извършване/получаване на обаждания чрез SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Разрешава на приложението да извършва и получава обаждания чрез SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"взаимодействие с екрана за обаждане"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Разрешава на приложението да контролира кога и как потребителят вижда екрана за обаждане."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"взаимодействие с екрана за обаждане"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Разрешава на приложението да контролира кога и как потребителят вижда екрана за обаждане."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"взаимодействие с телефонни услуги"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Разрешава на приложението да взаимодейства с телефонни услуги за извършване/получаване на обаждания."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"предоставяне на опции за практическа работа по време на обаждане"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Разрешава на приложението да предоставя опции за практическа работа по време на обаждане."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"четене на употребата на мрежата до момента"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Разрешава на приложението да чете употребата на данни за конкретни мрежи и приложения до момента."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"управление на правилата на мрежата"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Разрешава на притежателя да се обвърже с интерфейса от първо ниво на услуга за слушател на известия. Нормалните приложения не би трябвало никога да се нуждаят от това."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"свързване с услуга за предоставяне на условия"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Разрешава на притежателя да се свърже с интерфейса от най-високото ниво на услуга за предоставяне на условия. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"свързване с услуга за маршрутизиране на мултимедия"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Разрешава на притежателя да се свърже с интерфейса от най-високото ниво на услуга за маршрутизиране на мултимедия. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"свързване с услуга за „мечти“"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Разрешава на притежателя да се свърже с интерфейса от най-високото ниво на услуга за „мечти“. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"извикване на предоставеното от оператора приложение за конфигуриране"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Споделяне чрез %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Избиране на приложение за начало"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Използване по подразбиране за това действие."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Използване на друго приложение"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Изчистване на стандартната настройка в „Системни настройки“ &gt; „Приложения“ &gt; „Изтеглени“."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Избиране на действие"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Избор на приложение за USB устройството"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Разрешаване"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Отказване"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; иска да изпрати съобщение до &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Това "<font fgcolor="#ffffb060">"може да доведе до таксуване"</font>" на мобилната ви сметка."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Това ще доведе до таксуване на мобилната ви сметка."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Това "<b>"може да доведе до таксуване"</b>" на мобилния ви профил."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Това ще доведе до таксуване на мобилния ви профил."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Изпращане"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Отказ"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Изборът ми да се запомни"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Докоснете, за да деактивирате отстраняването на грешки през USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Промяна на клавиатурата"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Избиране на клавиатури"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Физическа клавиатура"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Метод на въвежд.: Показв."</string>
     <string name="hardware" msgid="7517821086888990278">"Хардуер"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Избиране на клавиатурна подредба"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Докоснете, за да изберете клавиатурна подредба."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Разрешава на приложението да се обвърже с услуга за надежден агент."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Взаимодействие със системата за актуализации и възстановяване"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Разрешава на приложението да взаимодейства със системата за възстановяване и системните актуализации."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Създаване на сесии за прожектиране на мултимедия"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Разрешава на приложението да създава сесии за прожектиране на мултимедия. Те могат да предоставят на приложенията възможността да заснемат екрана и да записват аудиосъдържание. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Управление на сесии за прожектиране на мултимедия"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Разрешава на приложението да управлява сесии за прожектиране на мултимедия. Те могат да предоставят на приложенията възможността да заснемат екрана и да записват аудиосъдържание. Нормалните приложения би трябвало никога да не се нуждаят от това."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Четене на сесии за инсталиране"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Разрешава на приложението да чете сесии за инсталиране. Това му позволява да вижда подробности за активните инсталирания на пакети."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Докоснете двукратно за управление на промяната на мащаба"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Отказване"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Иска се разрешение"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Иска се разрешение\nза профила <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Използвате това приложение в личното си пространство"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Използвате това приложение в работното си пространство"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Използвате това приложение извън служебния си потребителски профил"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Използвате това приложение в служебния си потребителски профил"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Метод на въвеждане"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синхронизиране"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Достъпност"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Намаляване на часовете"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Задаване на PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Задаване на AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Увеличаване на месеците"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Намаляване на месеците"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Увеличаване на дните"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Редактиране"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Предупрежд. за ползване на данни"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Ползване и настройки: Докоснете"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Данните от 2G – 3G са изключени"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Данните от 4G са изключени"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Мобилните данни са изключени"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Данните от Wi-Fi са изключени"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Ограничението е достигнато"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Достигнат лимит за 2G/3G данните"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Достигнат лимит за 4G данните"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Достигнат лимит за мобилни данни"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Достигнат лимит за Wi-Fi данните"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Данните са на пауза за ост. от цикъла"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Превишен лимит на 2G–3G данните"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Лимит за 4G данните – превишен"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Лимитът за моб. данни е превишен"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Да се приеме ли обаждането?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Винаги"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Само веднъж"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s не поддържа служебен потребителски профил."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s не поддържа служебен потребителски профил"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Таблет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Слушалки"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Достъпността е активирана."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Функцията за достъпност е анулирана."</string>
     <string name="user_switched" msgid="3768006783166984410">"Текущ потребител <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Превключва се към <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Собственик"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Грешка"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Тази промяна не е разрешена от администратора ви"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Избрахте <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Изтрихте <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> за работа"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"За да освободите този екран, докоснете и задръжте бутона за назад и същевременно натиснете и задръжте този за скорошни приложения."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"За да освободите този екран, докоснете и задръжте бутона за скорошни приложения."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Екранът е фиксиран. Освобождаването не е разрешено от организацията ви."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Да се използва ли функцията за фиксиране на екрана?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Фиксирането на екрана заключва дисплея в един изглед.\n\nЗа изход натиснете и задръжте бутона за назад и същевременно натиснете и задръжте този за скорошни приложения."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Фиксирането на екрана заключва дисплея в един изглед.\n\nЗа изход докоснете и задръжте бутона за скорошни приложения."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"НЕ, БЛАГОДАРЯ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"СТАРТИРАНЕ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"ПИН код"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"фигура за отключване"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"парола"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Екранът е фиксиран"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Екранът е освободен"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Запитване за ПИН код преди освобождаване"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Запитване за фигура за отключване преди освобождаване"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Запитване за парола преди освобождаване"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"С цел удължаване на живота на батерията режимът за запазването й намалява ефективността на устройството ви и ограничава вибрирането и повечето данни на заден план. Имейл, Съобщения и другите приложения, които разчитат на синхронизиране, може да не се актуализират, освен ако не ги отворите.\n\nТози режим автоматично се изключва, когато устройството ви се зарежда."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"До приключване на неактивността в <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"За една минута"</item>
+    <item quantity="other" msgid="6924190729213550991">"За %d минути"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"За един час"</item>
+    <item quantity="other" msgid="5408537517529822157">"За %d часа"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"За неопределено време"</string>
 </resources>
diff --git a/core/res/res/values-bn-rBD/strings.xml b/core/res/res/values-bn-rBD/strings.xml
index c288ab1..f8b122c 100644
--- a/core/res/res/values-bn-rBD/strings.xml
+++ b/core/res/res/values-bn-rBD/strings.xml
@@ -59,12 +59,12 @@
     <string name="mismatchPin" msgid="609379054496863419">"আপনার টাইপ করা PINগুলি মিলছে না৷"</string>
     <string name="invalidPin" msgid="3850018445187475377">"একটি PIN লিখুন যাতে ৪ থেকে ৮ নম্বর রয়েছে৷"</string>
     <string name="invalidPuk" msgid="8761456210898036513">"৮ বা তার থেকে বেশি নম্বরেরে একটি PUK লিখুন৷"</string>
-    <string name="needPuk" msgid="919668385956251611">"আপনার SIM কার্ডটি PUK-কোড দিয়ে লক করা রয়েছে৷ এটিকে আনলক করতে PUK কোডটি লিখুন৷"</string>
-    <string name="needPuk2" msgid="4526033371987193070">"SIM কার্ড অবরোধ মুক্ত করতে PUK2 লিখুন৷"</string>
-    <string name="enablePin" msgid="209412020907207950">"অসফল, SIM/RUIM লক সক্ষম করুন৷"</string>
+    <string name="needPuk" msgid="919668385956251611">"আপনার সিম কার্ডটি PUK-কোড দিয়ে লক করা রয়েছে৷ এটিকে আনলক করতে PUK কোডটি লিখুন৷"</string>
+    <string name="needPuk2" msgid="4526033371987193070">"সিম কার্ড অবরোধ মুক্ত করতে PUK2 লিখুন৷"</string>
+    <string name="enablePin" msgid="209412020907207950">"অসফল, সিম/RUIM লক সক্ষম করুন৷"</string>
   <plurals name="pinpuk_attempts">
-    <item quantity="one" msgid="6596245285809790142">"আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার SIM লক হয়ে যাবে৷"</item>
-    <item quantity="other" msgid="7530597808358774740">"আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার SIM লক হয়ে যাবে৷"</item>
+    <item quantity="one" msgid="6596245285809790142">"আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার সিম লক হয়ে যাবে৷"</item>
+    <item quantity="other" msgid="7530597808358774740">"আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার সিম লক হয়ে যাবে৷"</item>
   </plurals>
     <string name="imei" msgid="2625429890869005782">"IMEI"</string>
     <string name="meid" msgid="4841221237681254195">"MEID"</string>
@@ -289,11 +289,11 @@
     <string name="permlab_sendRespondViaMessageRequest" msgid="8713889105305943200">"বার্তার মাধ্যমে উত্তর দেওয়ার ইভেন্টগুলিকে পাঠায়"</string>
     <string name="permdesc_sendRespondViaMessageRequest" msgid="7107648548468778734">"আগত কলগুলির জন্য বার্তার-মাধ্যমে-উত্তর দেওয়ার ঘটনাগুলিকে পরিচালনা করতে অ্যাপ্লিকেশানটিকে অন্যান্য বার্তাপ্রেরণ অ্যাপ্লিকেশানে অনুরোধ পাঠানোর অনুমতি দেয়৷"</string>
     <string name="permlab_readSms" msgid="8745086572213270480">"আপনার পাঠ্য বার্তা পড়ুন (SMS বা MMS)"</string>
-    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"অ্যাপ্লিকেশানটিকে আপনার ট্যাবলেটে বা আপনার SIM কার্ডে সংরক্ষিত SMS বার্তাগুলি পড়ার অনুমতি দেয়৷ এটি অ্যাপ্লিকেশানটিকে সামগ্রী বা গোপনীয়তার সমস্ত SMS বার্তা নির্বিশেষে পড়ার অনুমতি দেয়৷"</string>
-    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"অ্যাপ্লিকেশানটিকে আপনার ফোনে বা আপনার SIM কার্ডে সংরক্ষিত SMS বার্তাগুলি পড়ার অনুমতি দেয়৷ এটি অ্যাপ্লিকেশানটিকে সামগ্রী বা গোপনীয়তার সমস্ত SMS বার্তা নির্বিশেষে পড়ার অনুমতি দেয়৷"</string>
+    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"অ্যাপ্লিকেশানটিকে আপনার ট্যাবলেটে বা আপনার সিম কার্ডে সংরক্ষিত SMS বার্তাগুলি পড়ার অনুমতি দেয়৷ এটি অ্যাপ্লিকেশানটিকে সামগ্রী বা গোপনীয়তার সমস্ত SMS বার্তা নির্বিশেষে পড়ার অনুমতি দেয়৷"</string>
+    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"অ্যাপ্লিকেশানটিকে আপনার ফোনে বা আপনার সিম কার্ডে সংরক্ষিত SMS বার্তাগুলি পড়ার অনুমতি দেয়৷ এটি অ্যাপ্লিকেশানটিকে সামগ্রী বা গোপনীয়তার সমস্ত SMS বার্তা নির্বিশেষে পড়ার অনুমতি দেয়৷"</string>
     <string name="permlab_writeSms" msgid="3216950472636214774">"আপনার পাঠ্য বার্তা সম্পাদনা করুন (SMS বা MMS)"</string>
-    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"অ্যাপ্লিকেশানকে আপনার ট্যাবলেটে বা SIM কার্ডে SMS বার্তাগুলি লিখতে দেয়৷ ক্ষতিকারক অ্যাপ্লিকেশানগুলি আপনার বার্তাগুলি মুছে দিতে পারে৷"</string>
-    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"অ্যাপ্লিকেশানকে আপনার ফোন বা SIM কার্ডে SMS বার্তাগুলি লিখতে দেয়৷ ক্ষতিকারক অ্যাপ্লিকেশানগুলি আপনার বার্তাগুলি মুছে দিতে পারে৷"</string>
+    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"অ্যাপ্লিকেশানকে আপনার ট্যাবলেটে বা সিম কার্ডে SMS বার্তাগুলি লিখতে দেয়৷ ক্ষতিকারক অ্যাপ্লিকেশানগুলি আপনার বার্তাগুলি মুছে দিতে পারে৷"</string>
+    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"অ্যাপ্লিকেশানকে আপনার ফোন বা সিম কার্ডে SMS বার্তাগুলি লিখতে দেয়৷ ক্ষতিকারক অ্যাপ্লিকেশানগুলি আপনার বার্তাগুলি মুছে দিতে পারে৷"</string>
     <string name="permlab_receiveWapPush" msgid="5991398711936590410">"পাঠ্য বার্তা পান (WAP)"</string>
     <string name="permdesc_receiveWapPush" msgid="748232190220583385">"অ্যাপ্লিকেশানটিকে WAP বার্তা প্রাপ্ত করার এবং প্রক্রিয়া করার অনুমতি দেয়৷ এর মানে হল অ্যাপ্লিকেশানটি আপনার ডিভাইস থেকে পাঠানো বার্তাগুলিকে পর্যবেক্ষণ করতে পারে এবং মুছতে পারে সেগুলিকে আপনাকে না দেখিয়ে৷"</string>
     <string name="permlab_receiveBluetoothMap" msgid="7593811487142360528">"Bluetooth বার্তা (MAP) গ্রহণ করুন"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ধারককে, একটি দূরবর্তী প্রদর্শনের উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়। সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"একটি উইজেট পরিষেবাতে সংলগ্ন করে"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ধারককে, একটি উইজেট পরিষেবার উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"একটি রুট প্রদানকারীর পরিষেবা বাঁধাই করে"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ধারককে, কোনো নিবন্ধিত রুট প্রদানকারীকে বাঁধাই করার অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"একটি ডিভাইস প্রশাসকের সাথে ইন্টারঅ্যাক্ট করে"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ধারককে, একটি ডিভাইস প্রশাসকে ইন্টেন্টগুলি পাঠানোর অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"টিভি ইনপুট বাঁধাই করে"</string>
@@ -544,7 +542,7 @@
     <string name="permlab_recordAudio" msgid="3876049771427466323">"অডিও রেকর্ড করে"</string>
     <string name="permdesc_recordAudio" msgid="4906839301087980680">"অ্যাপ্লিকেশানটিকে মাইক্রোফোনের দ্বারা অডিও রেকর্ড করার অনুমতি দেয়৷ এই অনুমতিটি অ্যাপ্লিকেশানটিকে আপনার অনুমোদন ছাড়া যেকোনো সময় অডিও রেকর্ড করার অনুমতি দেয়৷"</string>
     <string name="permlab_sim_communication" msgid="1180265879464893029">"sim যোগাযোগ"</string>
-    <string name="permdesc_sim_communication" msgid="5725159654279639498">"অ্যাপ্লিকেশানটিকে SIM কার্ডে কমান্ডগুলি পাঠানোর অনুমতি দেয়৷ এটি খুবই বিপজ্জনক৷"</string>
+    <string name="permdesc_sim_communication" msgid="5725159654279639498">"অ্যাপ্লিকেশানটিকে সিম কার্ডে কমান্ডগুলি পাঠানোর অনুমতি দেয়৷ এটি খুবই বিপজ্জনক৷"</string>
     <string name="permlab_camera" msgid="3616391919559751192">"ছবি এবং ভিডিও তোলে"</string>
     <string name="permdesc_camera" msgid="8497216524735535009">"ক্যামেরার সাহায্যে ছবি তুলতে ও ভিডিও তৈরি করতে অ্যাপ্লিকেশানটিকে মঞ্জুর করে৷ এই অনুমতিটি অ্যাপ্লিকেশানটিকে আপনার নিশ্চয়তা ছাড়াই যেকোনো সময় ক্যামেরা ব্যবহার করতে মঞ্জুর করে৷"</string>
     <string name="permlab_cameraDisableTransmitLed" msgid="2651072630501126222">"যখন ক্যামেরা ব্যবহারে থাকে তখন ট্রান্সমিট সূচক LED অক্ষম করে"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ফোনের পাওয়ার চালু বা বন্ধ করে"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"অ্যাপ্লিকেশানকে ট্যাবলেটটি চালু বা বন্ধ করতে দেয়৷"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"অ্যাপ্লিকেশানকে ফোনটি চালু বা বন্ধ করতে দেয়৷"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"প্রদর্শনের সময় সমাপ্ত হওয়া পুনরায় সেট করুন"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"প্রদর্শন সময় সমাপ্ত হওয়া পুনরায় সেট করতে অ্যাপ্লিকেশানটিকে অনুমতি দেয়।"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ফ্যাক্টরী পরীক্ষা মোডে চালায়"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ট্যাবলেটের হার্ডওয়্যারে সম্পূর্ণ অ্যাক্সেসের অনুমতি দিয়ে, একটি নিম্ন স্তরের প্রস্তুতকারকের পরীক্ষা হিসাবে চালায়৷ যখন একটি ট্যাবলেট, প্রস্তুতকারকের পরীক্ষা মোডে চালানো হয় শুধুমাত্র তখনই উপলব্ধ হয়৷"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ফোনের হার্ডওয়্যারে সম্পূর্ণ অ্যাক্সেসের অনুমতি দিয়ে একটি নিম্ন-স্তরের প্রস্তুতকারকের পরীক্ষা হিসাবে চালায়৷ যখন একটি ফোন প্রস্তুতকারকের পরীক্ষা মোডে চালানো হয় শুধুমাত্র তখনই উপলব্ধ হয়৷"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ক্যাশে ফাইল সিস্টেম পড়তে ও লিখতে অ্যাপ্লিকেশানকে অনুমতি দেয়৷"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP কল করুন/গ্রহণ করুন"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"অ্যাপ্লিকেশানকে SIP কল করতে ও গ্রহণ করতে অনুমতি দেয়।"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"কলে-থাকা স্ক্রীণের সাথে ইন্টারঅ্যাক্ট করে"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"কখন এবং কীভাবে ব্যবহারকারী কলে-থাকা স্ক্রীণটিকে দেখতে পাবেন অ্যাপ্লিকেশানটিকে তা নিয়ন্ত্রণ করতে দেয়৷"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"কলে-থাকা স্ক্রীণের সাথে ইন্টারঅ্যাক্ট করে"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ব্যবহারকারী কখন এবং কীভাবে কলে-থাকা স্ক্রীণটিকে দেখতে পাবেন, অ্যাপ্লিকেশানটিকে তা নিয়ন্ত্রণ করতে দেয়৷"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"টেলিফোন পরিষেবার সাথে ইন্টারঅ্যাক্ট করুন"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"কল করা/গ্রহণ করার জন্য অ্যাপ্লিকেশানটিকে টেলিফোন পরিষেবার সাথে ইন্টারঅ্যাক্ট করার অনুমতি দেয়।"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"কলে-থাকা এক ব্যবহারকারী অভিজ্ঞতা সরবরাহ করুন"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"অ্যাপ্লিকেশানটিকে কলে-থাকা এক ব্যবহারকারী অভিজ্ঞতা সরবরাহের অনুমতি দেয়।"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"তারিখ অনুযায়ী নেটওয়ার্কের ব্যবহার পড়ে"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"অ্যাপ্লিকেশানটিকে নিদিষ্ট নেটওয়ার্ক এবং অ্যাপ্লিকেশানগুলির জন্য পূর্বের নেটওয়ার্কের ব্যবহার পড়তে দেয়৷"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"নেটওয়ার্ক নীতি পরিচালনা করে"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ধারককে, একটি বিজ্ঞপ্তি শ্রোতা পরিষেবার উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"একটি শর্ত প্রদানকারীর পরিষেবা বাঁধাই করে"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"ধারককে, একটি শর্ত প্রদানকারী পরিষেবার উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"একটি মিডিয়া রুট পরিষেবায় জুড়ুন"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"ধারককে একটি মিডিয়া রুট পরিষেবার উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়। সাধারণ অ্যাপ্লিকেশানগুলির জন্য কখনোই প্রয়োজন হয় না।"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"একটি স্বপ্নের পরিষেবার সাথে যুক্ত হন"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ধারককে, একটি স্বপ্নের পরিষেবার উচ্চ স্তরের ইন্টারফেসে জুড়তে অনুমতি দেয়৷ সধারণ অ্যাপ্লিকেশানগুলির জন্য কখনই প্রয়োজন হয় না৷"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ক্যারিয়ারের প্রদেয় কনফিগারেশন অ্যাপ্লিকেশানকে দিয়ে কাজ করায়"</string>
@@ -909,13 +907,13 @@
     <string name="lockscreen_charged" msgid="321635745684060624">"চার্জ হয়েছে"</string>
     <string name="lockscreen_battery_short" msgid="4477264849386850266">"<xliff:g id="NUMBER">%d</xliff:g><xliff:g id="PERCENT">%%</xliff:g>"</string>
     <string name="lockscreen_low_battery" msgid="1482873981919249740">"আপনার চার্জার সংযুক্ত করুন৷"</string>
-    <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"কোনো SIM কার্ড নেই"</string>
-    <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"ট্যাবলেটের মধ্যে কোনো SIM কার্ড নেই৷"</string>
-    <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"ফোনের মধ্যে কোনো SIM কার্ড নেই৷"</string>
-    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"একটি SIM কার্ড ঢোকান৷"</string>
-    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"SIM কার্ডটি অনুপস্থিত বা পাঠযোগ্য নয়৷ একটি SIM কার্ড ঢোকান৷"</string>
-    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"ব্যবহার করার অযোগ্য SIM কার্ড৷"</string>
-    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"আপনার SIM কার্ড স্থায়ীভাবে অক্ষম করা হয়েছে৷\n অন্য একটি SIM কার্ড পেতে আপনার ওয়্যারলেস পরিষেবা প্রদানকারীর সাথে যোগাযোগ করুন৷"</string>
+    <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"কোনো সিম কার্ড নেই"</string>
+    <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"ট্যাবলেটের মধ্যে কোনো সিম কার্ড নেই৷"</string>
+    <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"ফোনের মধ্যে কোনো সিম কার্ড নেই৷"</string>
+    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"একটি সিম কার্ড ঢোকান৷"</string>
+    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"সিম কার্ডটি অনুপস্থিত বা পাঠযোগ্য নয়৷ একটি সিম কার্ড ঢোকান৷"</string>
+    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"ব্যবহার করার অযোগ্য সিম কার্ড৷"</string>
+    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"আপনার সিম কার্ড স্থায়ীভাবে অক্ষম করা হয়েছে৷\n অন্য একটি সিম কার্ড পেতে আপনার ওয়্যারলেস পরিষেবা প্রদানকারীর সাথে যোগাযোগ করুন৷"</string>
     <string name="lockscreen_transport_prev_description" msgid="6300840251218161534">"পূর্ববর্তী ট্র্যাক"</string>
     <string name="lockscreen_transport_next_description" msgid="573285210424377338">"পরবর্তী ট্র্যাক"</string>
     <string name="lockscreen_transport_pause_description" msgid="3980308465056173363">"বিরাম দিন"</string>
@@ -925,10 +923,10 @@
     <string name="lockscreen_transport_ffw_description" msgid="42987149870928985">"দ্রুত সামনে এগোন"</string>
     <string name="emergency_calls_only" msgid="6733978304386365407">"শুধুমাত্র জরুরী কল"</string>
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"নেটওয়ার্ক লক হয়েছে"</string>
-    <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"SIM কার্ডটি PUK কোড দিয়ে লক করা আছে৷"</string>
+    <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"সিম কার্ডটি PUK কোড দিয়ে লক করা আছে৷"</string>
     <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"ব্যবহারকারীর নির্দেশিকা দেখুন বা গ্রাহক পরিষেবা কেন্দ্রে যোগাযোগ করুন৷"</string>
-    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"SIM কার্ড লক করা আছে৷"</string>
-    <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"SIM কার্ড আনলক করা হচ্ছে…"</string>
+    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"সিম কার্ড লক করা আছে৷"</string>
+    <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"সিম কার্ড আনলক করা হচ্ছে…"</string>
     <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"আপনি আপনার আনলকের প্যাটার্ন আঁকার ক্ষেত্রে <xliff:g id="NUMBER_0">%d</xliff:g> বার ভুল করেছেন৷ \n\n<xliff:g id="NUMBER_1">%d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
     <string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"আপনি আপনার পাসওয়ার্ড টাইপ করতে <xliff:g id="NUMBER_0">%d</xliff:g> বার ভুল করেছেন৷ \n\n<xliff:g id="NUMBER_1">%d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
     <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"আপনি আপনার PIN টাইপ করতে <xliff:g id="NUMBER_0">%d</xliff:g> বার ভুল করেছেন৷ \n\n<xliff:g id="NUMBER_1">%d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s এর সাথে ভাগ করুন"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"একটি হোম অ্যাপ্লিকেশান নির্বাচন করুন"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"এই ক্রিয়াটির জন্য এটিকে ডিফল্টরুপে ব্যবহার করুন৷"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"আলাদা কোনো অ্যাপ্লিকেশান ব্যবহার করুন"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"সিস্টেম সেটিংস &gt; অ্যাপ্স &gt; ডাউনলোড করাগুলি এ গিয়ে ডিফল্ট সরিয়ে দিন৷"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"একটি ক্রিয়া চয়ন করুন"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB ডিভাইসটির জন্য একটি অ্যাপ্লিকেশান চয়ন করুন"</string>
@@ -1296,18 +1295,18 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"অনুমতি দিন"</string>
     <string name="sms_control_no" msgid="625438561395534982">"আস্বীকার করুন"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; এ একটি বার্তা পাঠাতে চায়৷"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"এটির জন্য আপনার মোবাইল অ্যাকাউন্টে "<font fgcolor="#ffffb060">"চার্জ করা হতে পারে"</font>"৷"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"এর ফলে আপনার মোবাইল অ্যাকাউন্টের উপরে চার্জ করা হবে৷"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"এটির জন্য আপনার মোবাইল অ্যাকাউন্টে "<b>"চার্জ বহন করতে হতে পারে"</b>"।"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"এর ফলে আপনার মোবাইল অ্যাকাউন্টে চার্জ বহন করতে হতে পারে।"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"পাঠান"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"বাতিল করুন"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"আমার পছন্দ মনে রাখুন"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"আপনি সেটিংস &gt; অ্যাপ্লিকেশানে এটি পরে পরিবর্তন করতে পারেন"</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"সর্বদা অনুমতি দিন"</string>
     <string name="sms_short_code_confirm_never_allow" msgid="446992765774269673">"কখনো অনুমতি দেবেন না"</string>
-    <string name="sim_removed_title" msgid="6227712319223226185">"SIM কার্ড সরানো হয়েছে"</string>
-    <string name="sim_removed_message" msgid="5450336489923274918">"আপনি একটি বৈধ SIM ঢুকিয়ে পুনর্সূচনা না করা পর্যন্ত সেলুলার নেটওয়ার্ক অনুপলব্ধ থাকবে।"</string>
+    <string name="sim_removed_title" msgid="6227712319223226185">"সিম কার্ড সরানো হয়েছে"</string>
+    <string name="sim_removed_message" msgid="5450336489923274918">"আপনি একটি বৈধ সিম ঢুকিয়ে পুনর্সূচনা না করা পর্যন্ত সেলুলার নেটওয়ার্ক অনুপলব্ধ থাকবে।"</string>
     <string name="sim_done_button" msgid="827949989369963775">"সম্পন্ন হয়েছে"</string>
-    <string name="sim_added_title" msgid="3719670512889674693">"SIM কার্ড যোগ করা হয়েছে"</string>
+    <string name="sim_added_title" msgid="3719670512889674693">"সিম কার্ড যোগ করা হয়েছে"</string>
     <string name="sim_added_message" msgid="7797975656153714319">"সেলুলার নেটওয়ার্ক অ্যাক্সেস করতে আপনার ডিভাইস পুনর্সূচনা করুন"</string>
     <string name="sim_restart_button" msgid="4722407842815232347">"পুনর্সূচনা"</string>
     <string name="time_picker_dialog_title" msgid="8349362623068819295">"সময় সেট করুন"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB ডিবাগিং অক্ষম করতে স্পর্শ করুন৷"</string>
     <string name="select_input_method" msgid="8547250819326693584">"কীবোর্ড পরিবর্তন করুন"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"কীবোর্ড চয়ন করুন"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ফিজিক্যাল কীবোর্ড"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ইনপুট পদ্ধতি দেখান"</string>
     <string name="hardware" msgid="7517821086888990278">"হার্ডওয়্যার"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"কীবোর্ডের লেআউট নির্বাচন করুন"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"একটি কীবোর্ডের লেআউট নির্বাচন করতে স্পর্শ করুন৷"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"একটি অ্যাপ্লিকেশানকে, একটি বিশ্বস্ত এজেন্ট পরিষেবাতে বাঁধাই করার অনুমতি দেয়৷"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"আপডেট এবং পুনরুদ্ধারের ব্যবস্থার সাথে ইন্টারঅ্যাক্ট করে"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"একটি অ্যাপ্লিকেশানকে পুনরুদ্ধার সিস্টেম ও সিস্টেম আপডেটগুলির সঙ্গে ইন্টারঅ্যাক্ট করার অনুমতি দেয়৷"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"মিডিয়া অভিক্ষেপ সেশন তৈরি করুন"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"কোনো অ্যাপ্লিকেশানকে মিডিয়া অভিক্ষেপ সেশন তৈরি করার অনুমতি দেয়। এসব সেশন অ্যাপ্লিকেশানগুলিকে প্রদর্শন ও অডিও বিষয়বস্তু ক্যাপচার করার সক্ষমতা দিতে পারে। সাধারণ অ্যাপ্লিকেশানের জন্য কখনো এমন প্রয়োজন হয় না।"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"মিডিয়া অভিক্ষেপ সেশন পরিচালনা করুন"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"কোনো অ্যাপ্লিকেশানকে মিডিয়া অভিক্ষেপ সেশন পরিচালনা করার অনুমতি দেয়। এসব সেশন অ্যাপ্লিকেশানগুলিকে প্রদর্শন ও অডিও বিষয়বস্তু ক্যাপচার করার সক্ষমতা দিতে পারে। সাধারণ অ্যাপ্লিকেশানের জন্য কখনো এমন প্রয়োজন হয় না।"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ইনস্টল সেশন পড়ুন"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"কোনো অ্যাপ্লিকেশানকে সেশনগুলি পড়ার অনুমতি দেয়। এটি সক্রিয় প্যাকেজ ইনস্টলেশনের বিশদ বিবরণ দেখতে দেয়।"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"জুম নিয়ন্ত্রণের জন্য দুবার স্পর্শ করুন"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"আস্বীকার করুন"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"অনুমতির অনুরোধ করা হয়েছে"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g>অ্যাকাউন্টের জন্য\nঅনুমতির অনুরোধ করা হয়েছে৷"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"আপনি এই অ্যাপ্লিকেশানটি আপনার ব্যক্তিগত জায়গায় ব্যবহার করছেন"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"আপনি এই অ্যাপ্লিকেশানটি আপনার কাজের জায়গায় ব্যবহার করছেন"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"আপনি এই অ্যাপ্লিকেশানটি আপনার কর্মস্থলের প্রোফাইলের বাইরে ব্যবহার করছেন"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"আপনি এই অ্যাপ্লিকেশানটি আপনার কর্মস্থলের প্রোফাইলে ব্যবহার করছেন"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ইনপুট পদ্ধতি"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"সিঙ্ক"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"অ্যাক্সেসযোগ্যতা"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"ঘন্টা কমান"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM সেট করুন"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM সেট করুন"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"মাস বাড়ান"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"মাস কম করুন"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"দিন বাড়ান"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"সম্পাদনা করুন"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ডেটা ব্যবহারের সতর্কতা"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ব্যবহার এবং সেটিংস দেখতে স্পর্শ করুন৷"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G ডেটা বন্ধ"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G ডেটা বন্ধ"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"সেলুলার ডেটা বন্ধ"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi ডেটা বন্ধ"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"সীমায় পৌঁছে গেছেন"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G ডেটা সীমা ছাড়িয়েছে"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G ডেটা সীমা ছাড়িয়েছে"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"সেলুলার ডেটা সীমা ছাড়িয়েছে"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi ডেটা সীমা ছাড়িয়েছে"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"বাকি চক্রের জন্য ডেটা বিরামে গেছে"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G ডেটা সীমা ছাড়িয়ে গেছে"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ডেটা সীমা ছাড়িয়ে গেছে"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"সেলুলার ডেটা সীমা ছাড়িয়ে গেছে"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"কল গ্রহণ করবেন?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"সবসময়"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"শুধু একবার"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s কর্মস্থলের প্রোফাইল সমর্থন করে না।"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s কর্মস্থলের প্রোফাইল সমর্থন করে না।"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ট্যাবলেট"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ফোন"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"হেডফোন"</string>
@@ -1607,13 +1604,13 @@
     <string name="kg_wrong_pin" msgid="1131306510833563801">"ভুল PIN"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"আপনার প্যাটার্ন আঁকুন"</string>
-    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN লিখুন"</string>
+    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"সিম PIN লিখুন"</string>
     <string name="kg_pin_instructions" msgid="2377242233495111557">"PIN লিখুন"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"পাসওয়ার্ড লিখুন"</string>
-    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM এখন অক্ষম করা হয়েছে৷ অবিরত থাকতে PUK কোডটি লিখুন৷ বিশদ বিবরণের জন্য ক্যারিয়ারের সাথে যোগাযোগ করুন৷"</string>
+    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"সিম এখন অক্ষম করা হয়েছে৷ অবিরত থাকতে PUK কোডটি লিখুন৷ বিশদ বিবরণের জন্য ক্যারিয়ারের সাথে যোগাযোগ করুন৷"</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"কাঙ্ক্ষিত PIN কোড লিখুন"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"কাঙ্ক্ষিত PIN কোড নিশ্চিত করুন"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM কার্ড আনলক করা হচ্ছে…"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"সিম কার্ড আনলক করা হচ্ছে…"</string>
     <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"ভুল PIN কোড৷"</string>
     <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"৪ থেকে ৮টি সংখ্যার একটি PIN লিখুন৷"</string>
     <string name="kg_invalid_sim_puk_hint" msgid="6025069204539532000">"PUK কোডকে ৮ সংখ্যার হতে হবে৷"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"অ্যাক্সেসযোগ্যতা সক্ষম করা হয়েছে৷"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"অ্যাক্সেসযোগ্যতা বাতিল করা হয়েছে৷"</string>
     <string name="user_switched" msgid="3768006783166984410">"বর্তমান ব্যবহারকারী <xliff:g id="NAME">%1$s</xliff:g>৷"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> নামের ব্যবহারকারীতে যাচ্ছে…"</string>
     <string name="owner_name" msgid="2716755460376028154">"মালিক"</string>
     <string name="error_message_title" msgid="4510373083082500195">"ত্রুটি"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"এই পরিবর্তনটি আপনার প্রশাসক দ্বারা অনুমোদিত নয়"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> নির্বাচন করা হয়েছে"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> মুছে ফেলা হয়েছে"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"কর্মক্ষেত্র <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"এই স্ক্রীন পিনমুক্ত করার জন্য একই সময়ে ‘ফিরুন’ ও ‘সাম্প্রতিকগুলি’ স্পর্শ করে ধরে থাকুন।"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"এই স্ক্রীন পিনমুক্ত করার জন্য ‘সাম্প্রতিকগুলি’ স্পর্শ করে ধরে থাকুন।"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"স্ক্রীন পিন করা আছে। আপনার প্রতিষ্ঠান এটিকে পিনমুক্ত করার অনুমতি দেয়নি।"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"স্ক্রীন পিন করা ব্যবহার করবেন?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"স্ক্রীনে পিন করা হলে প্রদর্শনকে একটি দৃশ্যে লক করে দেয়।\n\nসেখান থেকে বেরিয়ে যাওয়ার জন্য, একই সময়ে ‘ফিরুন’ ও ‘সাম্প্রতিকগুলি’ স্পর্শ করে ধরে থাকুন।"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"স্ক্রীনে পিন করা হলে প্রদর্শনকে একটি দৃশ্যে লক করে দেয়।\n\nসেখান থেকে বেরিয়ে যাওয়ার জন্য, ‘সাম্প্রতিকগুলি’ স্পর্শ করে ধরে থাকুন।"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"না, থাক"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"চালু করুন"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"আনলক প্যাটার্ন"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"পাসওয়ার্ড"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"স্ক্রীন পিন করা হয়েছে"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"পিন না করা স্ক্রীন"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"আনপিন করার আগে PIN চান"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"আনপিন করার আগে আনলক প্যাটার্ন চান"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"আনপিন করার আগে পাসওয়ার্ড চান"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ব্যাটারির আয়ু বাড়াতে সহায়তার জন্য, ব্যাটারি সঞ্চয়কারী আপনার ডিভাইসের কার্য-সম্পাদনা কমিয়ে আনবে এবং কম্পন ও পশ্চাদভূমি ডেটাকে সীমিত করবে। ইমেল, বার্তাপ্রেরণ ও অন্যান্য অ্যাপ্লিকেশান, যেগুলি সিঙ্ক হওয়ার উপর নির্ভরশীল সেগুলিকে আপনি না খোলা পর্যন্ত সেগুলি আপডেট নাও হতে পারে।\n\nআপনার ডিভাইস চার্জ হওয়ার সময় ব্যাটারি সঞ্চয়কারী স্বয়ংক্রিয়ভাবে বন্ধ হয়ে যাবে।"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>টার সময়ে আপনার ডাউনটাইম শেষ হওয়া পর্যন্ত"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"এক মিনিটের জন্য"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d মিনিটের জন্য"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"এক ঘন্টার জন্য"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d ঘন্টার জন্য"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"অনির্দিষ্টভাবে"</string>
 </resources>
diff --git a/core/res/res/values-ca/strings.xml b/core/res/res/values-ca/strings.xml
index 510c772..59eef74 100644
--- a/core/res/res/values-ca/strings.xml
+++ b/core/res/res/values-ca/strings.xml
@@ -300,7 +300,7 @@
     <string name="permdesc_receiveBluetoothMap" msgid="8656755936919466345">"Permet que l\'aplicació rebi i processi missatges de Bluetooth MAP. Això vol dir que l\'aplicació pot controlar o suprimir missatges que s\'hagin enviat al teu dispositiu sense mostrar-te\'ls."</string>
     <string name="permlab_getTasks" msgid="6466095396623933906">"recupera les aplicacions en execució"</string>
     <string name="permdesc_getTasks" msgid="7454215995847658102">"Permet que l\'aplicació recuperi informació sobre les tasques que s\'executen actualment i les que s\'han executat recentment. Aquesta acció pot permetre que l\'aplicació descobreixi informació sobre les aplicacions que s\'utilitzen al dispositiu."</string>
-    <string name="permlab_startTasksFromRecents" msgid="8990073877885690623">"inicia una tasca recent"</string>
+    <string name="permlab_startTasksFromRecents" msgid="8990073877885690623">"inicia una tasca des de recents"</string>
     <string name="permdesc_startTasksFromRecents" msgid="7382133554871222235">"Permet que l\'aplicació utilitzi un objecte ActivityManager.RecentTaskInfo per iniciar una tasca obsoleta que ActivityManager.getRecentTaskList() ha retornat."</string>
     <string name="permlab_interactAcrossUsers" msgid="7114255281944211682">"interacciona entre usuaris"</string>
     <string name="permdesc_interactAcrossUsers" msgid="364670963623385786">"Permet que l\'aplicació dugui a terme accions en diferents usuaris del dispositiu. Les aplicacions malicioses poden fer servir aquest permís per infringir la protecció entre usuaris."</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permet que el titular es vinculi a la interfície de nivell superior d\'una pantalla remota. No s\'hauria de necessitar mai per a les aplicacions normals."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vincula a un servei de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permet que el titular vinculi a la interfície de nivell superior d\'un servei de widget. No s\'hauria de necessitar mai per a les aplicacions normals."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"establir vincles amb un servei d\'aprovisionament de rutes"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permet que el titular estableixi vincles amb els proveïdors de rutes registrats. No hauria de ser mai necessari per a les aplicacions normals."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interactuar amb un administrador del dispositiu"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permet que el titular enviï intents a un administrador del sistema. No s\'hauria de necessitar mai per a les aplicacions normals."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"Vinculació a una entrada de televisor"</string>
@@ -575,8 +573,8 @@
     <string name="permdesc_asec_rename" msgid="1794757588472127675">"Permet que l\'aplicació canviï el nom de l\'emmagatzematge intern."</string>
     <string name="permlab_vibrate" msgid="7696427026057705834">"controlar la vibració"</string>
     <string name="permdesc_vibrate" msgid="6284989245902300945">"Permet que l\'aplicació controli el vibrador."</string>
-    <string name="permlab_flashlight" msgid="2155920810121984215">"controlar el flaix"</string>
-    <string name="permdesc_flashlight" msgid="6522284794568368310">"Permet que l\'aplicació controli el flaix."</string>
+    <string name="permlab_flashlight" msgid="2155920810121984215">"controla la llanterna"</string>
+    <string name="permdesc_flashlight" msgid="6522284794568368310">"Permet que l\'aplicació controli la llanterna."</string>
     <string name="permlab_manageUsb" msgid="1113453430645402723">"gestiona les preferències i els permisos dels dispositius USB"</string>
     <string name="permdesc_manageUsb" msgid="7776155430218239833">"Permet que l\'aplicació gestioni les preferències i els permisos dels dispositius USB."</string>
     <string name="permlab_accessMtp" msgid="4953468676795917042">"implementa el protocol MTP"</string>
@@ -602,7 +600,7 @@
     <string name="permdesc_readPhoneState" msgid="1639212771826125528">"Permet que l\'aplicació accedeixi a les funcions de telèfon del dispositiu. Aquest permís permet que l\'aplicació determini el número de telèfon i els identificadors del dispositiu, si hi ha una trucada activa i el número remot connectat amb una trucada."</string>
     <string name="permlab_readPrecisePhoneState" msgid="5476483020282007597">"llegeix els estats exactes del telèfon"</string>
     <string name="permdesc_readPrecisePhoneState" msgid="6648009074263855418">"Permet que l\'aplicació accedeixi als estats exactes del telèfon. Amb aquest permís, l\'aplicació pot determinar l\'estat real de la trucada, si la trucada està activa o en segon pla, si s\'ha produït algun error, l\'estat exacte de la connexió de dades i els errors de la connexió de dades."</string>
-    <string name="permlab_wakeLock" product="tablet" msgid="1531731435011495015">"evita que la tauleta entri en mode d\'inactivitat"</string>
+    <string name="permlab_wakeLock" product="tablet" msgid="1531731435011495015">"evita que la tauleta entri en mode de repòs"</string>
     <string name="permlab_wakeLock" product="default" msgid="573480187941496130">"impedir que el telèfon entri en mode de repòs"</string>
     <string name="permdesc_wakeLock" product="tablet" msgid="7311319824400447868">"Permet que l\'aplicació impedeixi que la tauleta entri en repòs."</string>
     <string name="permdesc_wakeLock" product="default" msgid="8559100677372928754">"Permet que l\'aplicació impedeixi que el telèfon entri en repòs."</string>
@@ -613,10 +611,12 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"engegar o apagar el telèfon"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permet que l\'aplicació encengui i apagui la tauleta."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permet a l\'aplicació engegar o apagar el telèfon."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"Restableix el temps d\'espera de la pantalla"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permet que l\'aplicació restableixi el temps d\'espera de la pantalla."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"executar en mode de proves de fàbrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Executa com a prova de perfil baix del fabricant que permet accés complet al maquinari de la tauleta. Només està disponible quan la tauleta s\'executa en mode de prova del fabricant."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"S\'executa com a prova del fabricant de baix nivell, cosa que permet l\'accés total al maquinari del telèfon. Només està disponible quan un telèfon s\'executa en mode de proves del fabricant."</string>
-    <string name="permlab_setWallpaper" msgid="6627192333373465143">"definir fons de pantalla"</string>
+    <string name="permlab_setWallpaper" msgid="6627192333373465143">"establir fons de pantalla"</string>
     <string name="permdesc_setWallpaper" msgid="7373447920977624745">"Permet que l\'aplicació estableixi el fons de pantalla del sistema."</string>
     <string name="permlab_setWallpaperHints" msgid="3278608165977736538">"ajustament de la mida del fons de pantalla"</string>
     <string name="permdesc_setWallpaperHints" msgid="8235784384223730091">"Permet que l\'aplicació defineixi els suggeriments de mida del fons de pantalla."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permet que l\'aplicació llegeixi el sistema de fitxers de la memòria cau i que hi escrigui."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"Fer i rebre trucades de SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permet que l\'aplicació pugui fer i rebre trucades de SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interacciona amb la pantalla de la trucada"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permet que l\'aplicació controli quan i com l\'usuari veu la pantalla de la trucada."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interaccionar amb la pantalla de la trucada"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permet que l\'aplicació controli quan i com l\'usuari veu la pantalla de la trucada."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interacciona amb els serveis de telefonia"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permet que l\'aplicació interaccioni amb els serveis de telefonia per fer i rebre trucades."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"proporcionar una experiència d\'usuari durant la trucada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permet que l\'aplicació proporcioni una experiència d\'usuari durant la trucada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lectura de l\'ús històric de la xarxa"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permet que l\'aplicació llegeixi l\'ús històric de la xarxa per a xarxes i per a aplicacions específiques."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gestió de la política de xarxa"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permet que el titular vinculi la interfície de nivell superior d\'un servei oient de notificacions. No s\'hauria de necessitar mai per a les aplicacions normals."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"enllaçar amb el servei de proveïdor de condicions"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permet enllaçar amb la interfície de nivell superior d\'un servei de proveïdor de condicions. No ha de ser mai necessari per a aplicacions normals."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"vincular-se amb un servei de rutes multimèdia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permet que el titular es vinculi amb la interfície de nivell superior d\'un servei de rutes multimèdia. No ha de ser mai necessari per a aplicacions normals."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"enllaçar amb un servei en repòs"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permet enllaçar amb la interfície de nivell superior d\'un servei en repòs. No hauria de ser mai necessari per a aplicacions normals."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invoca l\'aplicació de configuració proporcionada per l\'operador"</string>
@@ -784,13 +782,13 @@
     <item msgid="8073994352956129127">"Casa"</item>
     <item msgid="7084237356602625604">"Feina"</item>
     <item msgid="1112044410659011023">"Altres"</item>
-    <item msgid="2374913952870110618">"Personalitzada"</item>
+    <item msgid="2374913952870110618">"Personalitza"</item>
   </string-array>
   <string-array name="postalAddressTypes">
     <item msgid="6880257626740047286">"Casa"</item>
     <item msgid="5629153956045109251">"Feina"</item>
     <item msgid="4966604264500343469">"Altres"</item>
-    <item msgid="4932682847595299369">"Personalitzada"</item>
+    <item msgid="4932682847595299369">"Personalitza"</item>
   </string-array>
   <string-array name="imAddressTypes">
     <item msgid="1738585194601476694">"Casa"</item>
@@ -832,18 +830,18 @@
     <string name="phoneTypeTtyTdd" msgid="8606514378585000044">"TTY TDD"</string>
     <string name="phoneTypeWorkMobile" msgid="1311426989184065709">"Mòbil de la feina"</string>
     <string name="phoneTypeWorkPager" msgid="649938731231157056">"Cercapersones de la feina"</string>
-    <string name="phoneTypeAssistant" msgid="5596772636128562884">"Auxiliar"</string>
+    <string name="phoneTypeAssistant" msgid="5596772636128562884">"Assistent"</string>
     <string name="phoneTypeMms" msgid="7254492275502768992">"MMS"</string>
-    <string name="eventTypeCustom" msgid="7837586198458073404">"Personalitzats"</string>
+    <string name="eventTypeCustom" msgid="7837586198458073404">"Personalitza"</string>
     <string name="eventTypeBirthday" msgid="2813379844211390740">"Aniversari"</string>
     <string name="eventTypeAnniversary" msgid="3876779744518284000">"Aniversari"</string>
     <string name="eventTypeOther" msgid="7388178939010143077">"Altres"</string>
-    <string name="emailTypeCustom" msgid="8525960257804213846">"Personalitzada"</string>
+    <string name="emailTypeCustom" msgid="8525960257804213846">"Personalitzat"</string>
     <string name="emailTypeHome" msgid="449227236140433919">"Casa"</string>
     <string name="emailTypeWork" msgid="3548058059601149973">"Feina"</string>
     <string name="emailTypeOther" msgid="2923008695272639549">"Altres"</string>
     <string name="emailTypeMobile" msgid="119919005321166205">"Mòbil"</string>
-    <string name="postalTypeCustom" msgid="8903206903060479902">"Personalitzada"</string>
+    <string name="postalTypeCustom" msgid="8903206903060479902">"Personalitza"</string>
     <string name="postalTypeHome" msgid="8165756977184483097">"Casa"</string>
     <string name="postalTypeWork" msgid="5268172772387694495">"Feina"</string>
     <string name="postalTypeOther" msgid="2726111966623584341">"Altres"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Comparteix amb %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Selecciona una aplicació d\'inici"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Utilitza-ho de manera predeterminada per a aquesta acció."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Fes servir una altra aplicació"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Esborra els paràmetres predeterminats a Configuració del sistema &gt; Aplicacions &gt; Baixades."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Tria una acció"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Tria una aplicació per al dispositiu USB"</string>
@@ -1259,7 +1258,7 @@
     <string name="ringtone_default" msgid="3789758980357696936">"To predeterminat"</string>
     <string name="ringtone_default_with_actual" msgid="8129563480895990372">"To predeterminat (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
     <string name="ringtone_silent" msgid="7937634392408977062">"Cap"</string>
-    <string name="ringtone_picker_title" msgid="3515143939175119094">"Sons de trucada"</string>
+    <string name="ringtone_picker_title" msgid="3515143939175119094">"Sons"</string>
     <string name="ringtone_unknown" msgid="5477919988701784788">"To desconegut"</string>
   <plurals name="wifi_available">
     <item quantity="one" msgid="6654123987418168693">"Xarxa Wi-fi disponible"</item>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permet"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Denega"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vol enviar un missatge a &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Aquesta acció "<font fgcolor="#ffffb060">"pot fer que s\'apliquin càrrecs"</font>" al compte del mòbil."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Aquesta acció farà que s\'apliquin càrrecs al compte del mòbil."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Aquesta acció "<b>"pot produir càrrecs"</b>" al teu compte per a mòbils."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Aquesta acció produirà càrrecs al teu compte per a mòbils."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Envia"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancel·la"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Recorda la meva selecció"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toca per desactivar la depuració USB"</string>
     <string name="select_input_method" msgid="8547250819326693584">"Canviar el teclat"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Tria els teclats"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclat físic"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostra mètode d\'entrada."</string>
     <string name="hardware" msgid="7517821086888990278">"Maquinari"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selecciona una disposició de teclat"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toca per seleccionar una disposició de teclat."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permet que una aplicació es vinculi amb un servei d\'agent de confiança."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interacciona amb el sistema de recuperació i amb les actualitzacions"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permet que una aplicació interaccioni amb el sistema de recuperació i amb les actualitzacions del sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Creació de sessions de projecció de fitxers multimèdia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permet que una aplicació creï sessions de projecció de fitxers multimèdia. Aquestes sessions poden permetre que les aplicacions enregistrin continguts d\'àudio i de vídeo. No ha de ser mai necessari per a aplicacions normals."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gestionar les sessions de projecció multimèdia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permet que una aplicació gestioni les sessions de projecció multimèdia. Amb aquestes sessions es pot proporcionar la possibilitat de capturar continguts d\'àudio i de display a les aplicacions. No ha de ser mai necessari per a les aplicacions normals."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Lectura de les instal·lacions de sessió"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permet que una aplicació llegeixi les sessions d\'instal·lació i això permet veure detalls sobre les instal·lacions de paquet actives."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toca dos cops per controlar el zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Denega"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permís sol·licitat"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"S\'ha sol·licitat permís\nper al compte <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Estàs utilitzant l\'aplicació a l\'espai personal."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Estàs utilitzant l\'aplicació a l\'espai de la feina."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Estàs utilitzant aquesta aplicació fora del perfil professional."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Estàs utilitzant l\'aplicació al perfil professional."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Mètode d\'introducció de text"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronització"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibilitat"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Fes disminuir l\'hora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Estableix com a p. m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Estableix com a a. m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"pm"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"am"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Fes augmentar el mes"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Fes disminuir el mes"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Fes augmentar el dia"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edita"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Advertiment d\'ús de dades"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toca per veure ús/configuració."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Ús de dades 2G-3G desactivat"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Ús de dades 4G desactivat"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Dades mòbils desactivades"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Dades de Wi-Fi desactivades"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Límit superat"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Límit de dades 2G-3G assolit"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Límit de dades 4G assolit"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Límit de dades mòbils assolit"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Límit de dades Wi-Fi assolit"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dades resta del cicle aturades"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"S\'ha superat el límit de dades 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"S\'ha superat el límit de dades 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Límit de dades mòbils superat"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vols acceptar la trucada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Només una vegada"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s no admet perfils professionals."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s no admet perfils professionals."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tauleta"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telèfon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Auriculars"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"S\'ha activat l\'accessibilitat."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibilitat cancel·lada."</string>
     <string name="user_switched" msgid="3768006783166984410">"Usuari actual: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"S\'està canviant a <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propietari"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"L\'administrador no permet aquest canvi."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> seleccionat"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> suprimit"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> de la feina"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Per desfixar aquesta pantalla, mantén premuts Enrere i Recents alhora."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Per desfixar aquesta pantalla, mantén premut Recents."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"S\'ha fixat la pantalla. La teva organització no permet anul·lar-ne la fixació."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Vols fixar aquesta pantalla?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"La fixació de pantalla bloqueja la pantalla en una visualització única.\n\nPer sortir-ne, mantén premuts els botons de tornar enrere i d\'aplicacions recents."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"La fixació de pantalla bloqueja la pantalla en una visualització única.\n\nPer sortir-ne, mantén premut el botó d\'aplicacions recents."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, GRÀCIES"</string>
-    <string name="lock_to_app_positive" msgid="7085139175671313864">"INICI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"patró de desbloqueig"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"contrasenya"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_positive" msgid="7085139175671313864">"INICIA"</string>
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Pantalla fixada"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Fixació de la pantalla anul·lada"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Demana el codi PIN abans d\'anul·lar la fixació"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Sol·licita el patró de desbloqueig per anul·lar la fixació"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Demana la contrasenya abans d\'anul·lar la fixació"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Per tal d\'augmentar la durada de la bateria, la funció d\'estalvi de bateria redueix el rendiment del dispositiu i en limita la vibració i la majoria de dades en segon pla. És possible que el correu electrònic, la missatgeria i la resta d\'aplicacions que se sincronitzen amb freqüència no s\'actualitzin llevat que les obris.\n\nL\'estalvi de bateria es desactiva automàticament mentre el dispositiu s\'està carregant."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Fins que no finalitzi la inactivitat a les <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>."</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Durant un minut"</item>
+    <item quantity="other" msgid="6924190729213550991">"Durant %d minuts"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Durant una hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Durant %d hores"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidament"</string>
 </resources>
diff --git a/core/res/res/values-cs/strings.xml b/core/res/res/values-cs/strings.xml
index 7bab386..6e795df 100644
--- a/core/res/res/values-cs/strings.xml
+++ b/core/res/res/values-cs/strings.xml
@@ -183,9 +183,9 @@
     <string name="global_action_toggle_silent_mode" msgid="8219525344246810925">"Tichý režim"</string>
     <string name="global_action_silent_mode_on_status" msgid="3289841937003758806">"Zvuk je VYPNUTÝ."</string>
     <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"Zvuk je zapnutý"</string>
-    <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"Režim V letadle"</string>
-    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"Režim V letadle je ZAPNUTÝ"</string>
-    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"Režim V letadle je VYPNUTÝ"</string>
+    <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"Režim Letadlo"</string>
+    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"Režim Letadlo je ZAPNUTÝ"</string>
+    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"Režim Letadlo je VYPNUTÝ"</string>
     <string name="global_action_settings" msgid="1756531602592545966">"Nastavení"</string>
     <string name="global_action_lockdown" msgid="8751542514724332873">"Zamknout"</string>
     <string name="status_bar_notification_info_overflow" msgid="5301981741705354993">"999+"</string>
@@ -280,10 +280,10 @@
     <string name="permdesc_receiveSms" msgid="6424387754228766939">"Umožňuje aplikaci přijmout a zpracovat zprávy SMS. Znamená to, že aplikace může sledovat zprávy odeslané do vašeho zařízení nebo je smazat, aniž by se vám zobrazily."</string>
     <string name="permlab_receiveMms" msgid="1821317344668257098">"příjem textových zpráv (MMS)"</string>
     <string name="permdesc_receiveMms" msgid="533019437263212260">"Umožňuje aplikaci přijmout a zpracovat zprávy MMS. Znamená to, že aplikace může sledovat zprávy odeslané do vašeho zařízení nebo je smazat, aniž by se vám zobrazily."</string>
-    <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"příjem nouzového vysílání"</string>
-    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"Umožňuje aplikaci přijmout a zpracovat zprávy tísňového vysílání. Toto oprávnění je dostupné pouze pro systémové aplikace."</string>
-    <string name="permlab_readCellBroadcasts" msgid="1598328843619646166">"čtení zpráv informační služby"</string>
-    <string name="permdesc_readCellBroadcasts" msgid="6361972776080458979">"Umožňuje aplikaci číst zprávy informační služby přijaté ve vašem zařízení. Upozornění informační služby jsou v některých oblastech odesílána za účelem varování před mimořádnými událostmi. Škodlivé aplikace mohou narušit výkon či provoz vašeho zařízení během přijímání zpráv informační služby."</string>
+    <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"příjem výstražných zpráv o výjimečné situaci"</string>
+    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"Umožňuje aplikaci přijmout a zpracovat výstražné zprávy o výjimečných situacích. Toto oprávnění je dostupné pouze pro systémové aplikace."</string>
+    <string name="permlab_readCellBroadcasts" msgid="1598328843619646166">"čtení zpráv informačních služeb"</string>
+    <string name="permdesc_readCellBroadcasts" msgid="6361972776080458979">"Umožňuje aplikaci číst zprávy informačních služeb přijaté ve vašem zařízení. Výstražná upozornění informačních služeb jsou v některých oblastech odesílána za účelem varování před výjimečnými událostmi. Škodlivé aplikace mohou narušit výkon či provoz vašeho zařízení během přijímání zpráv informačních služeb."</string>
     <string name="permlab_sendSms" msgid="5600830612147671529">"odesílaní zpráv SMS"</string>
     <string name="permdesc_sendSms" msgid="7094729298204937667">"Umožňuje aplikaci odesílat zprávy SMS. Může to mít za následek účtování neočekávaných poplatků. Škodlivé aplikace vás mohou připravit o peníze odesíláním zpráv bez vašeho svolení."</string>
     <string name="permlab_sendRespondViaMessageRequest" msgid="8713889105305943200">"odesílání událostí typu „odpovězte zprávou“"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Umožňuje držiteli připojit se k vysokoúrovňovému rozhraní vzdáleného displeje. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"navázat se na službu widgetu"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Umožňuje držiteli navázat se na nejvyšší úroveň služby widgetu. Běžné aplikace by toto oprávnění neměly nikdy požadovat."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"navázání na službu poskytovatele tras"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Umožňuje držiteli navázat se na libovolného poskytovatele registrovaných tras. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"komunikovat se správcem zařízení"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Umožňuje držiteli oprávnění odesílat informace správci zařízení. Běžné aplikace by toto oprávnění neměly nikdy požadovat."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"navázání na televizní vstup"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"zapnutí či vypnutí telefonu"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Umožňuje aplikaci zapnout či vypnout tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Umožňuje aplikaci zapnout či vypnout telefon."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"resetování časového limitu displeje"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Umožňuje aplikaci resetovat časový limit displeje."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"spuštění v režimu továrního testu"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Umožňuje aplikaci spuštění v režimu nízkoúrovňového testu výrobce a povolí přístup k hardwaru tabletu. K dispozici, pouze je-li tablet spuštěn v režimu testování výrobce."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Umožňuje aplikaci spuštění v režimu nízkoúrovňového testu výrobce a povolí přístup k hardwaru telefonu. K dispozici pouze, je-li telefon spuštěn v režimu testování výrobce."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Umožňuje aplikaci číst a zapisovat do souborového systému mezipaměti."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"uskutečňování/příjem volání SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Povolí aplikaci uskutečňovat a přijímat volání SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakce s obrazovkou příchozího hovoru"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Umožňuje aplikaci řídit, kdy a jak se uživateli zobrazí obrazovka příchozího hovoru."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakce s obrazovkou příchozího hovoru"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Umožňuje aplikaci řídit, kdy a jak se uživateli zobrazí obrazovka příchozího hovoru."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"komunikace s telefonními službami"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Umožňuje aplikaci komunikovat s telefonními službami a provádět/přijímat hovory."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"zobrazení uživatelského prostředí během hovoru"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Umožňuje aplikaci zobrazit uživatelské prostředí během hovoru."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"číst využití sítě v historii"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Umožňuje aplikaci číst historii využití sítě (u určitých sítí a aplikací)."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"spravovat zásady sítě"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Umožňuje držiteli navázat se na nejvyšší úroveň služby pro poslouchání oznámení. Běžné aplikace by toto oprávnění neměly nikdy požadovat."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"navázání na službu poskytovatele podmínky"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Umožňuje držiteli navázat se na nejvyšší úroveň rozhraní služby poskytovatele podmínky. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"navázání na službu směrování médií"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Umožňuje držiteli navázat se na nejvyšší úroveň rozhraní služby směrování médií. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"navázat se na službu spořiče"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Umožňuje navázání na nejvyšší úroveň služby spořiče. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"vyvolat konfigurační aplikaci poskytnutou operátorem"</string>
@@ -774,7 +772,7 @@
     <item msgid="8901098336658710359">"Domů"</item>
     <item msgid="869923650527136615">"Mobil"</item>
     <item msgid="7897544654242874543">"Práce"</item>
-    <item msgid="1103601433382158155">"Pracovní fax"</item>
+    <item msgid="1103601433382158155">"Fax práce"</item>
     <item msgid="1735177144948329370">"Fax domů"</item>
     <item msgid="603878674477207394">"Pager"</item>
     <item msgid="1650824275177931637">"Ostatní"</item>
@@ -829,7 +827,7 @@
     <string name="phoneTypeOtherFax" msgid="8587657145072446565">"Jiný fax"</string>
     <string name="phoneTypeRadio" msgid="4093738079908667513">"Radiotelefon"</string>
     <string name="phoneTypeTelex" msgid="3367879952476250512">"Telex"</string>
-    <string name="phoneTypeTtyTdd" msgid="8606514378585000044">"Telefon pro sluchově postižené (TTY/TDD)"</string>
+    <string name="phoneTypeTtyTdd" msgid="8606514378585000044">"TTY/TDD"</string>
     <string name="phoneTypeWorkMobile" msgid="1311426989184065709">"Pracovní mobil"</string>
     <string name="phoneTypeWorkPager" msgid="649938731231157056">"Pracovní pager"</string>
     <string name="phoneTypeAssistant" msgid="5596772636128562884">"Asistent"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Sdílet v aplikaci %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Vyberte domovskou aplikaci"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Použít jako výchozí nastavení pro tuto činnost."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Použít jinou aplikaci"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Výchozí nastavení vymažete v sekci Nastavení systému &gt; Aplikace &gt; Stažené."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Vyberte akci"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Vyberte aplikaci pro zařízení USB"</string>
@@ -1230,9 +1229,9 @@
     <string name="smv_application" msgid="3307209192155442829">"Aplikace <xliff:g id="APPLICATION">%1$s</xliff:g> (proces <xliff:g id="PROCESS">%2$s</xliff:g>) porušila své vlastní vynucené zásady StrictMode."</string>
     <string name="smv_process" msgid="5120397012047462446">"Proces <xliff:g id="PROCESS">%1$s</xliff:g> porušil své vlastní vynucené zásady StrictMode."</string>
     <string name="android_upgrading_title" msgid="1584192285441405746">"Android se upgraduje..."</string>
-    <string name="android_upgrading_apk" msgid="7904042682111526169">"Optimalizace aplikace <xliff:g id="NUMBER_0">%1$d</xliff:g> z <xliff:g id="NUMBER_1">%2$d</xliff:g>."</string>
+    <string name="android_upgrading_apk" msgid="7904042682111526169">"Optimalizování aplikace <xliff:g id="NUMBER_0">%1$d</xliff:g> z <xliff:g id="NUMBER_1">%2$d</xliff:g>."</string>
     <string name="android_upgrading_starting_apps" msgid="451464516346926713">"Spouštění aplikací."</string>
-    <string name="android_upgrading_complete" msgid="1405954754112999229">"Probíhá dokončování spouštění."</string>
+    <string name="android_upgrading_complete" msgid="1405954754112999229">"Dokončování inicializace."</string>
     <string name="heavy_weight_notification" msgid="9087063985776626166">"Běží aplikace <xliff:g id="APP">%1$s</xliff:g>"</string>
     <string name="heavy_weight_notification_detail" msgid="1721681741617898865">"Dotykem přepnete aplikaci"</string>
     <string name="heavy_weight_switcher_title" msgid="7153167085403298169">"Přepnout aplikace?"</string>
@@ -1257,7 +1256,7 @@
     <string name="volume_icon_description_media" msgid="4217311719665194215">"Hlasitost médií"</string>
     <string name="volume_icon_description_notification" msgid="7044986546477282274">"Hlasitost oznámení"</string>
     <string name="ringtone_default" msgid="3789758980357696936">"Výchozí vyzváněcí tón"</string>
-    <string name="ringtone_default_with_actual" msgid="8129563480895990372">"Výchozí vyzváněcí tón (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
+    <string name="ringtone_default_with_actual" msgid="8129563480895990372">"Výchozí tón (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
     <string name="ringtone_silent" msgid="7937634392408977062">"Žádné"</string>
     <string name="ringtone_picker_title" msgid="3515143939175119094">"Vyzváněcí tóny"</string>
     <string name="ringtone_unknown" msgid="5477919988701784788">"Neznámý vyzváněcí tón"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Povolit"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Odmítnout"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; chce odeslat zprávu na adresu &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Mohou být účtovány poplatky"</font>" na váš mobilní účet."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Budou účtovány poplatky na váš mobilní účet."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Tato akce "<b>"může vést k naúčtování poplatků"</b>" na váš účet u mobilního operátora."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Tato akce povede k naúčtování poplatku na váš účet u mobilního operátora."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Odeslat"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Zrušit"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Zapamatovat moji volbu"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Dotykem zakážete ladění USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Změna klávesnice"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Vyberte klávesnice"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fyzická klávesnice"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Zobrazit metodu zadávání"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Výběr rozložení klávesnice"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Dotykem vyberte rozložení klávesnice."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Umožňuje aplikaci vázat se na službu agent důvěry."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interakce se systémem aktualizací a obnovení"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Umožňuje aplikaci interakci se systémem obnovení a s aktualizacemi systému."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Vytváření relací promítání médií"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Umožňuje aplikaci vytvářet relace promítání médií. Tyto relace mohou aplikacím umožnit zaznamenávat obsah obrazu a zvuku. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Správa relací promítání médií"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Umožňuje aplikaci spravovat relace promítání médií. Tyto relace mohou aplikacím umožnit zaznamenávat obsah obrazu a zvuku. Běžné aplikace by toto oprávnění neměly nikdy potřebovat."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Čtení instalačních relací"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Povoluje aplikaci číst instalační relace. Díky tomu můžete zobrazit podrobnosti o aktivních instalacích balíčku."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Dvojitým dotykem můžete ovládat přiblížení"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Odepřít"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Požadováno oprávnění"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Požadováno oprávnění\npro účet <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Tuto aplikaci používáte ve svém soukromém prostoru."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Tuto aplikaci používáte ve svém pracovním prostoru."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Tuto aplikaci používáte mimo svůj pracovní profil."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Tuto aplikaci používáte v pracovním profilu"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Metoda zadávání dat"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchronizace"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Usnadnění"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Ubrat hodinu"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Nastavit PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Nastavit AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Přidat měsíc"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Ubrat měsíc"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Přidat den"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Upravit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Upozornění na využití dat"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Informace o využití a nastavení"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Data 2G a 3G jsou vypnuta"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Data 4G jsou vypnuta"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobilní data jsou vypnuta"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Data Wi-Fi jsou vypnuta"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Bylo dosaženo limitu"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Dosáhli jste limitu dat 2G–3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Dosáhli jste limitu dat 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Dosáhli jste limitu mobilních dat"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Dosáhli jste limitu dat Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data pro zbytek cyklu pozastavena"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Překročili jste limit dat 2G–3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Překročili jste limit dat 4G."</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Dosažen limit mobilních dat"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Přijmout hovor?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Vždy"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Pouze jednou"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s pracovní profily nepodporuje."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s pracovní profily nepodporuje."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Sluchátka"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Usnadnění přístupu je aktivováno."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Usnadnění zrušeno."</string>
     <string name="user_switched" msgid="3768006783166984410">"Aktuální uživatel je <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Přepínání na účet <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Vlastník"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Chyba"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Administrátor tuto změnu zakázal"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Vybrána položka <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Číslice <xliff:g id="KEY">%1$s</xliff:g> byla smazána"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Pracovní <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Chcete-li obrazovku uvolnit, současně stiskněte a podržte tlačítka Zpět a Poslední."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Chcete-li obrazovku uvolnit, stiskněte a podržte tlačítko Poslední."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Obrazovka je připnuta. Vaše organizace uvolnění zakázala."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Použít připnutí obrazovky?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Připnutím obrazovky uzamknete displej v jednom zobrazení.\n\nRežim ukončíte současným klepnutím na tlačítka Zpět a Poslední."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Připnutím obrazovky uzamknete displej v jednom zobrazení.\n\nRežim ukončíte stisknutím a podržením tlačítka Poslední."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NE, DĚKUJI"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"SPUSTIT"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"bezpečnostní gesto"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"heslo"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Obrazovka připnuta"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Obrazovka uvolněna"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Před uvolněním požádat o kód PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Před uvolněním požádat o bezpečnostní gesto"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Před uvolněním požádat o heslo"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Za účelem zvýšení životnosti baterie spořič baterie sníží výkon vašeho zařízení a omezí vibrace a většinu dat na pozadí. E-mail, zprávy a další aplikace, které používají synchronizaci, nemusejí být aktualizovány, dokud je nespustíte.\n\nPři nabíjení zařízení se spořič baterie automaticky vypne."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Dokud v <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> neskončí pozastavení"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Na jednu minutu"</item>
+    <item quantity="other" msgid="6924190729213550991">"Na %d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Na 1 h"</item>
+    <item quantity="other" msgid="5408537517529822157">"Na %d h"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Na dobu neurčitou"</string>
 </resources>
diff --git a/core/res/res/values-da/strings.xml b/core/res/res/values-da/strings.xml
index c0351bc..4927409 100644
--- a/core/res/res/values-da/strings.xml
+++ b/core/res/res/values-da/strings.xml
@@ -281,7 +281,7 @@
     <string name="permlab_receiveMms" msgid="1821317344668257098">"modtage tekstbeskeder (mms)"</string>
     <string name="permdesc_receiveMms" msgid="533019437263212260">"Tillader, at appen kan modtage og behandle mms-beskeder. Det betyder, at appen kan overvåge eller slette de beskeder, der sendes til din enhed, uden at vise dem til dig."</string>
     <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"modtage nødudsendelser"</string>
-    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"Tillader, at appen kan modtage og behandle nødtransmissioner. Denne tilladelse er kun tilgængelig for systemapps."</string>
+    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"Tillader, at appen kan modtage og behandle nødudsendelser. Denne tilladelse er kun tilgængelig for systemapps."</string>
     <string name="permlab_readCellBroadcasts" msgid="1598328843619646166">"læse Cell Broadcast-beskeder"</string>
     <string name="permdesc_readCellBroadcasts" msgid="6361972776080458979">"Tillader, at appen læser Cell Broadcast-beskeder, der modtages af din enhed. I nogle områder sendes der Cell Broadcast-beskeder for at advare om nødsituationer. Ondsindede apps kan forstyrre ydelsen eller driften af ​din ​enhed, når der modtages en Cell Broadcast-besked om en nødsituation."</string>
     <string name="permlab_sendSms" msgid="5600830612147671529">"sende sms-beskeder"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Tillader, at brugeren kan foretage en binding til grænsefladens øverste niveau på en ekstern skærm. Bør aldrig være nødvendigt til almindelige apps."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"forpligt til en widgettjeneste"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Tillader, at brugeren kan forpligte sig til en grænseflade for en widgettjeneste på øverste niveau. Bør aldrig være nødvendigt til almindelige apps."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"oprette tilknytning til en ruteudbydertjeneste"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Tillader, at indehaveren opretter tilknytninger til registrerede ruteudbydere. Dette bør aldrig være nødvendigt for normale apps."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"kommunikere med en enhedsadministrator"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Tillader, at brugeren kan sende hensigter til en enhedsadministrator. Dette bør aldrig være nødvendigt for almindelige apps."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"knyt til en tv-indgang"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"tænd eller sluk for telefonen"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Tillader, at appen kan slukke og tænde din tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Tillader, at appen kan slukke og tænde telefonen."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"nulstil timeout for skærmen"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Tillader, at appen kan nulstille timeout for skærmen."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"kør i fabriksindstillet testtilstand"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Kør som en producenttest på lavt niveau, der giver fuld adgang til tabletens hardware. Kun tilgængeligt når en tablet kører i producenttesttilstand."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Kør som en producenttest på lavt niveau. Giver fuld adgang til telefonens hardware. Kun tilgængeligt når en telefon kører i producenttesttilstand."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Tillader, at appen kan læse og skrive i cachefilsystemet."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"foretage/modtage SIP-opkald"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Tillader, at appen foretager og modtager SIP-opkald."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interager med skærmen for indgående opkald"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Tillader, at appen styrer, hvornår og hvordan brugeren ser skærmen for indgående opkald."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interager med skærmen under opkald"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Tillader, at appen styrer, hvornår og hvordan brugeren ser skærmen for indgående opkald."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interagere med telefonitjenester"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Tillader, at appen kan interagere med telefonitjenester for at foretage/modtage opkald."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"leverer brugeroplevelsen under opkald"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Tillader, at appen leverer brugeroplevelsen under opkald."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"læse oversigt over netværksbrug"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Tillader, at appen kan læse historisk netværksbrug for specifikke netværk og apps."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"administrer netværkspolitik"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Tillader brugeren at forpligte sig til en underretningslyttertjenestes grænseflade på øverste niveau. Bør aldrig være nødvendigt til almindelige apps."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"oprette binding til en tjeneste til formidling af betingelser"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Tillader, at brugeren opretter en binding til det øverste niveau af grænsefladen i en tjeneste til formidling af betingelser. Dette bør aldrig være nødvendigt for almindelige apps."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"opret binding til en medierutetjeneste"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Tillader, at brugeren opretter en binding til det øverste niveau af grænsefladen i en medierutetjeneste. Dette bør aldrig være nødvendigt for almindelige apps."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"fastlås til en drømmetjeneste"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Tillader, at indehaveren fastlåser det øverste niveau af brugergrænsefladen for en drømmetjeneste. Dette bør aldrig være nødvendigt for almindelige apps."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"aktivere konfigurationsappen, der leveres af mobilselskabet"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Del med %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Vælg en startapp"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Brug som standard til denne handling."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Brug en anden app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Ryd standard i Systemindstillinger &gt; Apps &gt; Downloadet."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Vælg en handling"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Vælg en app til USB-enheden"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Tillad"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Afvis"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vil sende en besked til &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Dette "<font fgcolor="#ffffb060">"kan medføre gebyrer"</font>" på din mobilkonto."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Dette vil medføre gebyrer på din mobilkonto."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Dette "<b>"kan medføre gebyrer"</b>" på din mobilkonto."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Dette vil medføre gebyrer på din mobilkonto."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Send"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Annuller"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Husk mit valg"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Tryk for at deaktivere USB-fejlretning."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Skift tastatur"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Vælg tastaturer"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fysisk tastatur"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Vis indtastningsmetode"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Vælg tastaturlayout"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Tryk for at vælge et tastaturlayout."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Tillader, at en applikation knytter sig til en trust agent-tjeneste."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interager med opdaterings- og gendannelsessystemet"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Giver en applikation tilladelse til at interagere med gendannelsessystemet og systemopdateringerne."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Opret sessioner med medieprojektion"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Tillader, at en app opretter sessioner med medieprojektion. Disse sessioner kan give applikationer mulighed for at optage billed- og lydindhold. Normale apps bør aldrig have brug for dette."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Styrer sessioner med medieprojektion"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Tillader, at en app styrer sessioner med medieprojektion. Disse sessioner kan give applikationer mulighed for at optage billed- og lydindhold. Normale apps bør aldrig have brug for dette."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Læs installationssessioner"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Tillader, at en applikation læser installationssessioner. Dermed kan applikationen se oplysninger om aktive pakkeinstallationer."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Tryk to gange for zoomstyring"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Afvis"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Der er anmodet om tilladelse"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Der er anmodet om tilladelse\nfor kontoen <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Du bruger denne app i dit personlige område"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Du bruger denne app i dit arbejdsområde"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Du bruger denne app uden for din arbejdsprofil"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Du bruger denne app i din arbejdsprofil"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Inputmetode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synkroniser"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Hjælpefunktioner"</string>
@@ -1438,9 +1437,9 @@
     <string name="vpn_title_long" msgid="6400714798049252294">"VPN aktiveres af <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="vpn_text" msgid="3011306607126450322">"Tryk for at administrere netværket."</string>
     <string name="vpn_text_long" msgid="6407351006249174473">"Forbundet til <xliff:g id="SESSION">%s</xliff:g>. Tryk for at administrere netværket."</string>
-    <string name="vpn_lockdown_connecting" msgid="6443438964440960745">"Opretter forbindelse til Always-on VPN…"</string>
+    <string name="vpn_lockdown_connecting" msgid="6443438964440960745">"Opretter forbindelse til altid aktiveret VPN…"</string>
     <string name="vpn_lockdown_connected" msgid="8202679674819213931">"Always-on VPN er forbundet"</string>
-    <string name="vpn_lockdown_error" msgid="6009249814034708175">"Fejl i Always-on VPN"</string>
+    <string name="vpn_lockdown_error" msgid="6009249814034708175">"Fejl i altid aktiveret VPN"</string>
     <string name="vpn_lockdown_config" msgid="6415899150671537970">"Tryk for at konfigurere"</string>
     <string name="upload_file" msgid="2897957172366730416">"Vælg fil"</string>
     <string name="no_file_chosen" msgid="6363648562170759465">"Ingen fil er valgt"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Sænk timetal"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Indstil PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Indstil AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Senere måned"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Tidligere måned"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Senere dag"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Rediger"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Advarsel om dataforbrug"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Tryk for at se brug og indstill."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G-data er deaktiveret"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-data er deaktiveret"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobildata er deaktiveret"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-data er deaktiveret"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Grænsen er nået"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Grænsen for 2G-3G-data er nået"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Grænsen for 4G-data er nået"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Grænsen for mobildata er nået"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Grænsen for Wi-Fi-data er nået"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data er afbrudt i resten af perioden"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G-data overskredet"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Grænsen for 4G-data er overskredet"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Grænsen for mobildata er overskredet"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vil du besvare opkaldet?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Altid"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Kun én gang"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s understøtter ikke arbejdsprofilen."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s understøtter ikke arbejdsprofil"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Hovedtelefoner"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Hjælpefunktioner er aktiveret."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Hjælpefunktioner er annulleret."</string>
     <string name="user_switched" msgid="3768006783166984410">"Nuværende bruger <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Skifter til <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Ejer"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Fejl"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Din administrator har ikke givet tilladelse til at foretage denne ændring"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> er valgt"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> er slettet"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> – arbejde"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Hvis du vil frigøre dette skærmbillede, skal du trykke på og holde Tilbage og Seneste nede på samme tid."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Hvis du vil frigøre dette skærmbillede, skal du trykke på og holde Seneste nede."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skærmen er fastgjort. Frigørelse er ikke tilladt af din organisation."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Vil du bruge Bliv i app?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Bliv i app låser skærmen i en enkelt visning.\n\nAfslut ved at trykke på Tilbage og Seneste samtidig og holde dem nede."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Bliv i app låser skærmen i en enkelt visning.\n\nHvis du vil afslutte, skal du trykke på knappen Seneste og holde den nede."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NEJ TAK"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Pinkode"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"oplåsningsmønster"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"adgangskode"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skærmen blev fastgjort"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skærmen blev frigjort"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Bed om pinkode inden frigørelse"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Bed om oplåsningsmønster ved deaktivering"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Bed om adgangskode inden frigørelse"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"For at forbedre batteriets levetid reducerer batterisparefunktionen enhedens ydeevne og begrænser vibrationer og de fleste baggrundsdata. E-mail, beskeder og andre apps, der benytter synkronisering, opdateres ikke, medmindre du åbner dem.\n\nBatterisparefunktionen deaktiveres automatisk, når enheden oplades."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Indtil din nedetid slutter kl. <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"I ét minut"</item>
+    <item quantity="other" msgid="6924190729213550991">"I %d minutter"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"I én time"</item>
+    <item quantity="other" msgid="5408537517529822157">"I %d timer"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Uendeligt"</string>
 </resources>
diff --git a/core/res/res/values-de/strings.xml b/core/res/res/values-de/strings.xml
index e45ce8a..c20b0ff 100644
--- a/core/res/res/values-de/strings.xml
+++ b/core/res/res/values-de/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Ermöglicht dem Halter, sich an die Oberfläche eines Remote-Displays auf oberster Ebene zu binden. Sollte für normale Apps nie benötigt werden."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"An einen Widget-Dienst binden"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Ermöglicht dem Halter, sich an die Oberfläche eines Widget-Dienstes auf oberster Ebene zu binden. Sollte nie für normale Apps benötigt werden."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"An Routenanbieterdienst binden"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Ermöglicht dem Inhaber die Bindung an registrierte Routenanbieter. Sollte für normale Apps nicht erforderlich sein"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"Interaktion mit einem Geräteadministrator"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Ermöglicht dem Halter, Intents an einen Geräteadministrator zu senden. Sollte nie für normale Apps benötigt werden."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"An eine TV-Eingabe binden"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"Gerät ein- oder ausschalten"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Ermöglicht der App, das Tablet ein- oder auszuschalten"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Ermöglicht der App, das Telefon ein- oder auszuschalten"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"Display-Zeitlimit zurücksetzen"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Ermöglicht der App das Zurücksetzen des Display-Zeitlimits."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"In Werkstestmodus ausführen"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Führt einen systemnahen Herstellertest durch, in dessen Rahmen auf die gesamte Tablet-Hardware zugegriffen werden kann. Nur verfügbar, wenn ein Tablet im Herstellertestmodus ausgeführt wird."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Führt einen systemnahen Herstellertest durch, in dessen Rahmen auf die gesamte Telefon-Hardware zugegriffen werden kann. Nur verfügbar, wenn ein Telefon im Herstellertestmodus ausgeführt wird."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Ermöglicht der App Lese- und Schreibzugriff auf das Cache-Dateisystem"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP-Anrufe tätigen/empfangen"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ermöglicht der App das Tätigen und Empfangen von SIP-Anrufen"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"Mit Anrufbildschirm interagieren"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Die App kann steuern, wann und wie der Nutzer den Anrufbildschirm sieht."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"Mit Anrufbildschirm interagieren"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Die App kann steuern, wann und wie der Nutzer den Anrufbildschirm sieht."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"Mit Telefondiensten interagieren"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Ermöglicht der App die Interaktion mit Telefondiensten, um Anrufe zu tätigen und zu empfangen"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"Anrufoptionen anzeigen"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Die App kann Anrufoptionen für den Nutzer bereitstellen."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"Bisherige Netzwerkauslastung lesen"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Ermöglicht der App, Daten zur bisherigen Netzwerkauslastung für bestimmte Netzwerke und Apps zu lesen"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"Netzwerkrichtlinien verwalten"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Ermöglicht dem Inhaber, sich an die Oberfläche der obersten Ebene eines Benachrichtigungs-Listener-Dienstes zu binden. Sollte nie für normale Apps benötigt werden."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"An einen Bedingungsproviderdienst binden"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Ermöglicht dem Inhaber, sich an die Oberfläche eines Bedingungsproviderdienstes auf oberster Ebene zu binden. Für normale Apps sollte dies nie erforderlich sein."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"An Mediarouting-Dienst binden"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Ermöglicht dem Inhaber die Bindung an die Oberfläche eines Mediarouting-Dienstes auf oberster Ebene. Für normale Apps sollte dies nie erforderlich sein."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"An Dream-Dienst binden"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Ermöglicht der App, sich an die Oberfläche eines Dream-Dienstes auf oberster Ebene zu binden. Für normale Apps sollte dies nie erforderlich sein."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"Vom Mobilfunkanbieter bereitgestellte Konfigurations-App aufrufen"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Für %1$s freigeben"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Start-App auswählen"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Immer für diese Aktion verwenden"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Andere App verwenden"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Das Löschen der Standardeinstellungen ist in den Systemeinstellungen unter \"Apps &gt; Heruntergeladen\" möglich."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Aktion auswählen"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"App für USB-Gerät auswählen"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Zulassen"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Nicht zulassen"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; möchte eine Nachricht an &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; senden."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Hierfür könnten Ihrem Mobilfunkkonto "<font fgcolor="#ffffb060">"Gebühren berechnet werden"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Hierfür werden Ihrem Mobilfunkkonto Gebühren berechnet."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Hierfür könnten Ihrem Mobilfunkkonto "<b>"Gebühren berechnet werden"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Hierfür werden Ihrem Mobilfunkkonto Gebühren berechnet."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Senden"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Abbrechen"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Auswahl merken"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Zum Deaktivieren von USB-Debugging berühren"</string>
     <string name="select_input_method" msgid="8547250819326693584">"Tastatur ändern"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Tastatur auswählen"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Physische Tastatur"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Eingabemethode anzeigen"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Tastaturlayout auswählen"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Zum Auswählen eines Tastaturlayouts berühren"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Ermöglicht einer App die Anbindung an einen Trust Agent-Service"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Mit Update- und Wiederherstellungssystem interagieren"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Ermöglicht einer App die Interaktion mit dem Wiederherstellungssystem und den Systemupdates"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Sitzungen zur Projektion von Medieninhalten erstellen"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Ermöglicht einer App, Sitzungen zur Projektion von Medieninhalten zu erstellen. In diesen Sitzungen können Apps Bildschirm- und Audioinhalte aufnehmen. Für normale Apps sollte dies nie erforderlich sein."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Sitzungen zur Projektion von Medieninhalten verwalten"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Ermöglicht einer App, Sitzungen zur Projektion von Medieninhalten zu verwalten. In diesen Sitzungen können Apps Bildschirm- und Audioinhalte aufnehmen. Für normale Apps sollte dies nie erforderlich sein."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Installationssitzungen lesen"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Ermöglicht der App, Installationssitzungen zu lesen. Dadurch kann sie Details aktiver Paketinstallationen abrufen."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Für Zoomeinstellung zweimal berühren"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Ablehnen"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Berechtigung angefordert"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Berechtigung angefordert\nfür Konto <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Sie verwenden diese App in Ihrem persönlichen Bereich."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Sie verwenden diese App in Ihren Arbeitsbereich."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Sie verwenden diese App außerhalb Ihres Arbeitsprofils."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Sie verwenden diese App in Ihrem Arbeitsprofil."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Eingabemethode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchronisieren"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Bedienungshilfen"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Stunden verringern"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Zeit festlegen"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Zeit festlegen"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Monat verlängern"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Monat verringern"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Tag verlängern"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Bearbeiten"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Warnung zum Datenverbrauch"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Für Verbrauch/Einstell. berühren"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G/3G-Daten deaktiviert"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-Daten deaktiviert"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobilfunkdaten deaktiviert"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"WLAN-Daten deaktiviert"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limit erreicht"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-/3G-Datenlimit erreicht"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G-Datenlimit erreicht"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobilfunkdatenlimit erreicht"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"WLAN-Datenlimit erreicht"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Daten für restl. Zeitraum deakt."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-/3G-Datenlimit überschritten"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G-Datenlimit überschritten"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobilfunkdatenlimit überschritten"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Anruf annehmen?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Immer"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Nur diesmal"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s unterstützt das Arbeitsprofil nicht."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"Das Arbeitsprofil wird von %1$s nicht unterstützt."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Kopfhörer"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Bedienungshilfen aktiviert"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Bedienungshilfen abgebrochen"</string>
     <string name="user_switched" msgid="3768006783166984410">"Aktueller Nutzer <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Wechseln zu <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Eigentümer"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Fehler"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Ihr Administrator lässt diese Änderung nicht zu."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ausgewählt"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> gelöscht"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (geschäftlich)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Berühren und halten Sie zum Beenden der Bildschirmfixierung gleichzeitig die Schaltfläche \"Zurück\" und \"Neueste\"."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Berühren und halten Sie zum Beenden der Bildschirmfixierung die Schaltfläche \"Neueste\"."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Der Bildschirm ist fixiert. Sie sind nicht berechtigt, diese Einstellung zu beenden."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Bildschirmfixierung verwenden?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Durch die Bildschirmfixierung wird das Display in einer bestimmten Ansicht gesperrt.\n\nBerühren und halten Sie zum Beenden gleichzeitig die Schaltfläche \"Zurück\" und \"Neueste\"."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Durch die Bildschirmfixierung wird das Display in einer bestimmten Ansicht gesperrt.\n\nBerühren und halten Sie zum Beenden die Schaltfläche \"Neueste\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"Nein danke"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"Starten"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"Entsperrungsmuster"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"Passwort"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Bildschirm fixiert"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Bildschirm gelöst"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Vor dem Beenden nach PIN fragen"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Vor dem Beenden nach Entsperrungsmuster fragen"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Vor dem Beenden nach Passwort fragen"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Der Energiesparmodus hilft, den Akku zu schonen, indem er die Leistung des Geräts reduziert und die Vibrationsfunktion und die meisten Hintergrunddatenaktivitäten einschränkt. E-Mail-, SMS/MMS- und andere Apps, die die Synchronisierungsfunktion benötigen, werden möglicherweise nicht aktualisiert, bis Sie sie öffnen.\n\nDer Energiesparmodus endet automatisch, wenn Ihr Gerät aufgeladen wird."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Bis zum Ende der Downtime um <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Für eine Minute"</item>
+    <item quantity="other" msgid="6924190729213550991">"Für %d Minuten"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Für eine Stunde"</item>
+    <item quantity="other" msgid="5408537517529822157">"Für %d Stunden"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Unbegrenzt"</string>
 </resources>
diff --git a/core/res/res/values-el/strings.xml b/core/res/res/values-el/strings.xml
index b3db37d..c95e84d 100644
--- a/core/res/res/values-el/strings.xml
+++ b/core/res/res/values-el/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Επιτρέπει στον κάτοχο τη δέσμευση στη διεπαφή ανωτάτου επιπέδου μιας απομακρυσμένης οθόνης. Δεν απαιτείται ποτέ για κανονικές εφαρμογές."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"δέσμευση σε υπηρεσία γραφικών στοιχείων"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Επιτρέπει στον κάτοχο τη δέσμευση στη διεπαφή ανωτάτου επιπέδου μιας υπηρεσίας γραφικών στοιχείων. Δεν απαιτείται για κανονικές εφαρμογές."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"σύνδεση σε μια υπηρεσία παρόχου δρομολογητή"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Δίνει στον κάτοχο τη δυνατότητα σύνδεσης με οποιονδήποτε εγγεγραμμένο πάροχο δρομολογητή. Δεν απαιτείται ποτέ για κανονικές εφαρμογές."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"επικοινωνία με έναν διαχειριστή συσκευής"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Επιτρέπει στον κάτοχο την αποστολή στόχων σε έναν διαχειριστή συσκευής. Δεν είναι απαραίτητο για συνήθεις εφαρμογές."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"σύνδεση σε μία είσοδο τηλεόρασης"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ενεργοποίηση και απενεργοποίηση τηλεφώνου"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Επιτρέπει στην εφαρμογή να ενεργοποιήσει ή να απενεργοποιήσει το tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Επιτρέπει στην εφαρμογή να ενεργοποιήσει ή να απενεργοποιήσει το τηλέφωνο."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"επαναφορά χρονικού ορίου λήξης οθόνης"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Επιτρέπει στην εφαρμογή να επαναφέρει το χρονικό όριο λήξης της οθόνης."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"εκτέλεση σε λειτουργία εργοστασιακής δοκιμής"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Εκτέλεση ως χαμηλού επιπέδου δοκιμή κατασκευαστή, ώστε να επιτρέπεται πλήρης πρόσβαση στο υλικό του tablet. Διαθέσιμο μόνο όταν το tablet βρίσκεται σε λειτουργία δοκιμής κατασκευαστή."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Εκτέλεση ως χαμηλού επιπέδου δοκιμή κατασκευαστή, ώστε να επιτρέπεται πλήρης πρόσβαση στο υλικό του τηλεφώνου. Διαθέσιμο μόνο όταν το τηλέφωνο βρίσκεται σε λειτουργία δοκιμής κατασκευαστή."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Επιτρέπει στην εφαρμογή την ανάγνωση και την εγγραφή του συστήματος αρχείων προσωρινής μνήμης."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"πραγματοποίηση/λήψη κλήσεων SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Επιτρέπει στην εφαρμογή να πραγματοποιεί και να λαμβάνει κλήσεις SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"αλληλεπίδραση με την οθόνη κατά τη διάρκεια κλήσης"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Επιτρέπει στην εφαρμογή να ελέγχει πότε και πώς βλέπει ο χρήστης την οθόνη κατά τη διάρκεια κλήσης."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"αλληλεπίδραση με την οθόνη κατά τη διάρκεια κλήσης"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Επιτρέπει στην εφαρμογή να ελέγχει πότε και πώς βλέπει ο χρήστης την οθόνη κατά τη διάρκεια κλήσης."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"αλληλεπίδραση με υπηρεσίες τηλεφωνίας"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Επιτρέπει στην εφαρμογή να αλληλεπιδρά με υπηρεσίες τηλεφωνίας για την πραγματοποίηση/λήψη κλήσεων."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"παροχή εμπειρίας χρήστη κατά τη διάρκεια κλήσης"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Επιτρέπει στην εφαρμογή να παρέχει μια εμπειρία στο χρήστη κατά τη διάρκεια κλήσης."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ανάγνωση ιστορικών δεδομένων χρήσης δικτύου"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Επιτρέπει στην εφαρμογή την ανάγνωση ιστορικών στοιχείων χρήσης δικτύου για συγκεκριμένα δίκτυα και εφαρμογές."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"διαχείριση πολιτικής δικτύου"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Επιτρέπει στον κάτοχο τη δέσμευση στη διεπαφή ανωτάτου επιπέδου μιας υπηρεσίας ακρόασης ειδοποιήσεων. Δεν απαιτείται σε κανονικές εφαρμογές."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"σύνδεση σε μια υπηρεσία παρόχου συνθηκών"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Επιτρέπει στον κάτοχο τη σύνδεση στη διεπαφή ανωτάτου επιπέδου ενός παρόχου συνθηκών. Δεν απαιτείται για κανονικές εφαρμογές."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"σύνδεση σε μια υπηρεσία δρομολόγησης μέσων"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Επιτρέπει στον κάτοχο τη σύνδεση στη διεπαφή ανωτάτου επιπέδου μιας υπηρεσίας δρομολόγησης μέσων. Δεν απαιτείται για κανονικές εφαρμογές."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"δέσμευση σε υπηρεσία dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Επιτρέπει στον κάτοχο τη δέσμευση στη διεπαφή ανωτάτου επιπέδου μιας υπηρεσίας dream. Δεν απαιτείται σε κανονικές εφαρμογές."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"κλήση της εφαρμογής διαμόρφωσης που παρέχεται από την εταιρεία κινητής τηλεφωνίας"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Κοινή χρήση με %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Επιλέξτε μια εφαρμογή από την αρχική οθόνη"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Χρήση από προεπιλογή για αυτήν την ενέργεια."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Χρήση άλλης εφαρμογής"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Εκκθάριση προεπιλογής στις Ρυθμίσεις συστήματος &gt; Εφαρμογές &gt; Ληφθείσες."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Επιλέξτε μια ενέργεια"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Επιλέξτε μια εφαρμογή για τη συσκευή USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Αποδοχή"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Άρνηση"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"Η εφαρμογή &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; θέλει να αποστείλει ένα μήνυμα στη διεύθυνση &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Αυτή η ρύθμιση "<font fgcolor="#ffffb060">"ενδέχεται να επιφέρει χρεώσεις"</font>" στον λογαριασμό κινητού σας."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Αυτή η ρύθμιση θα επιφέρει χρεώσεις στον λογαριασμό κινητού σας."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Αυτό "<b>"ενδέχεται να επιφέρει χρεώσεις"</b>" στο λογαριασμό του κινητού σας."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Αυτό θα επιφέρει χρεώσεις στο λογαριασμό του κινητού σας."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Αποστολή"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Ακύρωση"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Απομνημόνευση της επιλογής μου"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Αγγίξτε για απενεργοποίηση του εντοπισμού σφαλμάτων USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Αλλαγή πληκτρολογίου"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Επιλογή πληκτρολογίων"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Φυσικό πληκτρολόγιο"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Εμφάνιση μεθόδου εισαγ."</string>
     <string name="hardware" msgid="7517821086888990278">"Υλικό"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Επιλογή διάταξης πληκτρολογίου"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Αγγίξτε για να επιλέξετε διάταξη πληκτρολογίου."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Επιτρέπει σε μια εφαρμογή να συνδεθεί σε μια υπηρεσία trust agents."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Αλληλεπίδραση με το σύστημα ενημέρωσης και ανάκτησης"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Επιτρέπει σε μια εφαρμογή να αλληλεπιδρά με το σύστημα ανάκτησης και ενημερώσεων συστήματος."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Δημιουργία περιόδων σύνδεσης προβολής μέσων"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Επιτρέπει σε μια εφαρμογή τη δημιουργία περιόδων σύνδεσης προβολής μέσων. Οι περίοδοι σύνδεσης μπορούν να παρέχουν στις εφαρμογές τη δυνατότητα να καταγράφουν την οθόνη και το ηχητικό περιεχόμενο. Δεν απαιτείται από συνήθεις εφαρμογές."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Διαχείριση περιόδων σύνδεσης προβολής μέσων"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Επιτρέπει σε μια εφαρμογή να διαχειρίζεται περιόδους σύνδεσης προβολής μέσων. Αυτές οι περίοδοι σύνδεσης μπορεί να παρέχουν σε εφαρμογές τη δυνατότητα εγγραφής περιεχομένου εικόνας και ήχου. Δεν πρέπει σε καμία περίπτωση να είναι απαραίτητη από απλές εφαρμογές."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Ανάγνωση περιόδων σύνδεσης εγκατάστασης"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Επιτρέπει σε μια εφαρμογή την ανάγνωση των περιόδων σύνδεσης εγκατάστασης. Αυτό της επιτρέπει να βλέπει λεπτομέρειες σχετικά με τις εγκαταστάσεις του ενεργού πακέτου."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Αγγίξτε δύο φορές για έλεγχο εστίασης"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Άρνηση"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Απαιτείται άδεια"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Ζητήθηκε άδεια\nγια τον λογαριασμό <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Χρησιμοποιείτε αυτήν την εφαρμογή στον προσωπικό σας χώρο"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Χρησιμοποιείτε αυτήν την εφαρμογή στο χώρο εργασίας σας"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Χρησιμοποιείτε αυτήν την εφαρμογή εκτός του προφίλ εργασίας σας"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Χρησιμοποιείτε αυτήν την εφαρμογή στο προφίλ εργασίας"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Μέθοδος εισόδου"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Συγχρονισμός"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Προσβασιμότητα"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Μείωση ώρας"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Ορισμός ΜΜ"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Ορισμός ΠΜ"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ΜΜ"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ΠΜ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Αύξηση μήνα"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Μείωση μήνα"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Αύξηση ημέρας"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Επεξεργασία"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Προειδοποίηση χρήσης δεδομένων"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Αγγίξτε για προβολή χρήσης/ρυθμ."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Τα δεδομένα 2G-3G είναι ανενεργά"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Τα δεδομένα 4G είναι ανενεργά"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Ανενεργά δεδ.κινητής τηλεφωνίας"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Τα δεδομένα Wi-Fi είναι ανενεργά"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Εξαντλήθηκε το όριο"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Συμπλ. το όριο δεδομένων 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Συμπλ. το όριο δεδομένων 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Συμπλ. το όριο δεδ. κιν. τηλ."</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Συμπλ. το όριο δεδ. Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Παύση δεδ. για το υπ. του κύκλ."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Ξεπεράστηκε το όριο δεδομ. 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Ξεπεράστηκε το όριο δεδομένων 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Υπέρβαση ορίου δεδ.κιν.τηλεφ."</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Αποδοχή κλήσης;"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Πάντα"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Μόνο μία φορά"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"Το %1$s δεν υποστηρίζει προφίλ εργασίας."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"Το προφίλ εργασίας δεν υποστηρίζεται από %1$s"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Τηλέφωνο"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Ακουστικά"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Ενεργοποιήθηκε η προσβασιμότητα."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Η λειτουργία προσβασιμότητας ακυρώθηκε."</string>
     <string name="user_switched" msgid="3768006783166984410">"Τρέχων χρήστης <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Εναλλαγή σε <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Κάτοχος"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Σφάλμα"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Αυτή η αλλαγή δεν επιτρέπεται από το διαχειριστή σας"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Επιλέχτηκε το στοιχείο <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> διαγράφηκε"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Εργασία <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Για να ξεκαρφιτσώσετε αυτήν την οθόνη, αγγίξτε παρατεταμένα τα κουμπιά \"Επιστροφή\" και \"Πρόσφατα\" ταυτόχρονα."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Για να ξεκαρφιτσώσετε αυτήν την οθόνη, αγγίξτε παρατεταμένα το κουμπί \"Πρόσφατα\"."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Η οθόνη καρφιστώθηκε. Το ξεκαρφίτσωμα δεν επιτρέπεται από τον οργανισμό σας."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Χρήση καρφιτσώματος οθόνης;"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Το καρφίτσωμα της οθόνης κλειδώνει την οθόνη σε μία μόνο προβολή.\n\nΓια έξοδο, αγγίξτε παρατεταμένα τα κουμπιά \"Επιστροφή\" και \"Πρόσφατα\" ταυτόχρονα."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Το καρφίτσωμα της οθόνης κλειδώνει την οθόνη σε μία μόνο προβολή.\n\nΓια έξοδο, αγγίξτε παρατεταμένα το κουμπί \"Πρόσφατα\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ΟΧΙ, ΕΥΧΑΡΙΣΤΩ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ΕΝΑΡΞΗ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Αριθμός PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"μοτίβο ξεκλειδώματος"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"κωδικός πρόσβασης"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Η οθόνη καρφιτσώθηκε"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Η οθόνη ξεκαρφιτσώθηκε"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Να γίνεται ερώτηση για το PIN, πριν από το ξεκαρφίτσωμα"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Να γίνεται ερώτηση για το μοτίβο ξεκλειδώματος, πριν από το ξεκαρφίτσωμα"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Να γίνεται ερώτηση για τον κωδικό πρόσβασης, πριν από το ξεκαρφίτσωμα"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Για τη βελτίωση της διάρκειας ζωής της μπαταρίας, η λειτουργία εξοικονόμησης μπαταρίας μειώνει την απόδοση της συσκευής σας και περιορίζει τη δόνηση και την πλειονότητα των δεδομένων παρασκηνίου. Το ηλεκτρονικό ταχυδρομείου, η ανταλλαγή μηνυμάτων και άλλες εφαρμογές που βασίζονται στο συγχρονισμό ενδέχεται να μην ενημερώνονται, παρά μόνο εάν τις ανοίξετε.\n\nΗ λειτουργία εξοικονόμησης μπαταρίας απενεργοποιείται αυτόματα κατά τη φόρτιση της συσκευής σας."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Έως τη λήξη του νεκρού χρόνου σας στις <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Για ένα λεπτό"</item>
+    <item quantity="other" msgid="6924190729213550991">"Για %d λεπτά"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Για μία ώρα"</item>
+    <item quantity="other" msgid="5408537517529822157">"Για %d ώρες"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Επ\' αόριστον"</string>
 </resources>
diff --git a/core/res/res/values-en-rAU/strings.xml b/core/res/res/values-en-rAU/strings.xml
deleted file mode 100644
index 1cbfbba..0000000
--- a/core/res/res/values-en-rAU/strings.xml
+++ /dev/null
@@ -1,1214 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<resources xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="byteShort">"B"</string>
-    <!-- no translation found for kilobyteShort (5865542430193761682) -->
-    <skip />
-    <!-- no translation found for megabyteShort (112984851085937882) -->
-    <skip />
-    <!-- no translation found for gigabyteShort (8586075069559273847) -->
-    <skip />
-    <!-- no translation found for terabyteShort (5828502357595687794) -->
-    <skip />
-    <!-- no translation found for petabyteShort (7523248732657962413) -->
-    <skip />
-    <!-- no translation found for untitled (284687023829080340) -->
-    <skip />
-    <!-- no translation found for ellipsis (8538883953764277342) -->
-    <skip />
-    <!-- no translation found for emptyPhoneNumber (6416283285732095329) -->
-    <skip />
-    <!-- no translation found for unknownName (3974255879290140525) -->
-    <skip />
-    <!-- no translation found for defaultVoiceMailAlphaTag (6484324201071049939) -->
-    <skip />
-    <!-- no translation found for defaultMsisdnAlphaTag (4953008223227371928) -->
-    <skip />
-    <!-- no translation found for mmiError (7480678835624852655) -->
-    <skip />
-    <!-- no translation found for serviceEnabled (4042194305396115167) -->
-    <skip />
-    <!-- no translation found for serviceEnabledFor (638808419103886277) -->
-    <skip />
-    <!-- no translation found for serviceDisabled (1059935666763511541) -->
-    <skip />
-    <!-- no translation found for serviceRegistered (7639869107156932038) -->
-    <skip />
-    <!-- no translation found for serviceErased (4602215208593071820) -->
-    <skip />
-    <!-- no translation found for passwordIncorrect (5142040651297346232) -->
-    <skip />
-    <!-- no translation found for mmiComplete (3178168770150013486) -->
-    <skip />
-    <!-- no translation found for badPin (5103184589972647739) -->
-    <skip />
-    <!-- no translation found for badPuk (2200634943393540609) -->
-    <skip />
-    <!-- no translation found for mismatchPin (5055729703806180857) -->
-    <skip />
-    <!-- no translation found for invalidPin (6201854814319326475) -->
-    <skip />
-    <!-- no translation found for needPuk (4788728144863892764) -->
-    <skip />
-    <!-- no translation found for needPuk2 (7056908944942451033) -->
-    <skip />
-    <!-- no translation found for ClipMmi (5649729434121615509) -->
-    <skip />
-    <!-- no translation found for ClirMmi (5220979296096544477) -->
-    <skip />
-    <!-- no translation found for CfMmi (4998483717856803914) -->
-    <skip />
-    <!-- no translation found for CwMmi (5678103638951836350) -->
-    <skip />
-    <!-- no translation found for BaMmi (6030555200442855833) -->
-    <skip />
-    <!-- no translation found for PwdMmi (2549941247959366670) -->
-    <skip />
-    <!-- no translation found for PinMmi (2463353963837922189) -->
-    <skip />
-    <!-- no translation found for CLIRDefaultOnNextCallOn (4005921990799469144) -->
-    <skip />
-    <!-- no translation found for CLIRDefaultOnNextCallOff (1497360760012205230) -->
-    <skip />
-    <!-- no translation found for CLIRDefaultOffNextCallOn (604591440398078227) -->
-    <skip />
-    <!-- no translation found for CLIRDefaultOffNextCallOff (5114039908683246336) -->
-    <skip />
-    <!-- no translation found for serviceNotProvisioned (3754416031529306610) -->
-    <skip />
-    <!-- no translation found for CLIRPermanent (3819908477891272611) -->
-    <skip />
-    <!-- no translation found for serviceClassVoice (3059107563169935913) -->
-    <skip />
-    <!-- no translation found for serviceClassData (2669025626575716504) -->
-    <skip />
-    <!-- no translation found for serviceClassFAX (973109472405729679) -->
-    <skip />
-    <!-- no translation found for serviceClassSMS (3857383928743625711) -->
-    <skip />
-    <!-- no translation found for serviceClassDataAsync (8526461993032174729) -->
-    <skip />
-    <!-- no translation found for serviceClassDataSync (2461138395498381801) -->
-    <skip />
-    <!-- no translation found for serviceClassPacket (8119604233041078065) -->
-    <skip />
-    <!-- no translation found for serviceClassPAD (202892636830042266) -->
-    <skip />
-    <!-- no translation found for cfTemplateNotForwarded (3171755805856206604) -->
-    <skip />
-    <!-- no translation found for cfTemplateForwarded (2468661573318024785) -->
-    <skip />
-    <!-- no translation found for cfTemplateForwardedTime (5151810870794744740) -->
-    <skip />
-    <!-- no translation found for cfTemplateRegistered (5685211900474527085) -->
-    <skip />
-    <!-- no translation found for cfTemplateRegisteredTime (2978918277762252776) -->
-    <skip />
-    <!-- no translation found for httpErrorOk (984913805621139001) -->
-    <skip />
-    <!-- no translation found for httpError (9177990053748151835) -->
-    <skip />
-    <!-- no translation found for httpErrorLookup (5251341716070330936) -->
-    <skip />
-    <!-- no translation found for httpErrorUnsupportedAuthScheme (2865679883634239474) -->
-    <skip />
-    <!-- no translation found for httpErrorAuth (1637382600929594620) -->
-    <skip />
-    <!-- no translation found for httpErrorProxyAuth (5947648983995807455) -->
-    <skip />
-    <!-- no translation found for httpErrorConnect (129984292497034683) -->
-    <skip />
-    <!-- no translation found for httpErrorIO (8128922048686581131) -->
-    <skip />
-    <!-- no translation found for httpErrorTimeout (8357966263983739012) -->
-    <skip />
-    <!-- no translation found for httpErrorRedirectLoop (4122379005100433886) -->
-    <skip />
-    <!-- no translation found for httpErrorUnsupportedScheme (4072339858288462569) -->
-    <skip />
-    <!-- no translation found for httpErrorFailedSslHandshake (2316625025255452595) -->
-    <skip />
-    <!-- no translation found for httpErrorBadUrl (8885244563103716039) -->
-    <skip />
-    <!-- no translation found for httpErrorFile (1408273621719669493) -->
-    <skip />
-    <!-- no translation found for httpErrorFileNotFound (2309088465300506314) -->
-    <skip />
-    <!-- no translation found for httpErrorTooManyRequests (3764334538393544875) -->
-    <skip />
-    <!-- no translation found for contentServiceSync (4863236165350475642) -->
-    <skip />
-    <!-- no translation found for contentServiceSyncNotificationTitle (6855304679069026824) -->
-    <skip />
-    <!-- no translation found for contentServiceTooManyDeletesNotificationDesc (8477597194404210723) -->
-    <skip />
-    <!-- no translation found for low_memory (4191592786596642367) -->
-    <skip />
-    <!-- no translation found for me (4616693653158602117) -->
-    <skip />
-    <!-- no translation found for power_dialog (8210256011408959109) -->
-    <skip />
-    <!-- no translation found for silent_mode (5218239246946854300) -->
-    <skip />
-    <!-- no translation found for turn_on_radio (1901054698789840131) -->
-    <skip />
-    <!-- no translation found for turn_off_radio (2870296409392615956) -->
-    <skip />
-    <!-- no translation found for screen_lock (1560333453597081877) -->
-    <skip />
-    <!-- no translation found for power_off (2412024417733516836) -->
-    <skip />
-    <!-- no translation found for shutdown_progress (3735034517335251808) -->
-    <skip />
-    <!-- no translation found for shutdown_confirm (699224922526414097) -->
-    <skip />
-    <!-- no translation found for no_recent_tasks (1367712919998349373) -->
-    <skip />
-    <!-- no translation found for global_actions (8299888906525675157) -->
-    <skip />
-    <!-- no translation found for global_action_lock (5943677976245541105) -->
-    <skip />
-    <!-- no translation found for global_action_power_off (3143027278596694254) -->
-    <skip />
-    <!-- no translation found for global_action_toggle_silent_mode (5849335789367070450) -->
-    <skip />
-    <!-- no translation found for global_action_silent_mode_on_status (6053429980569202260) -->
-    <skip />
-    <!-- no translation found for global_action_silent_mode_off_status (1994514127029249081) -->
-    <skip />
-    <!-- no translation found for safeMode (3375134507868534320) -->
-    <skip />
-    <!-- no translation found for permgrouplab_costMoney (904087853776533085) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_costMoney (4662370555643969515) -->
-    <skip />
-    <!-- no translation found for permgrouplab_messages (2984053976424233925) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_messages (2129093134354989379) -->
-    <skip />
-    <!-- no translation found for permgrouplab_personalInfo (4548406335021507392) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_personalInfo (8499310823817958034) -->
-    <skip />
-    <!-- no translation found for permgrouplab_location (8535677827151907069) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_location (2341662219604651887) -->
-    <skip />
-    <!-- no translation found for permgrouplab_network (3597781730625751831) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_network (8332572695347918340) -->
-    <skip />
-    <!-- no translation found for permgrouplab_accounts (8631201594657951893) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_accounts (443982868906396781) -->
-    <skip />
-    <!-- no translation found for permgrouplab_hardwareControls (5074512938567152139) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_hardwareControls (8772503144945278440) -->
-    <skip />
-    <!-- no translation found for permgrouplab_phoneCalls (7096448531266882376) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_phoneCalls (6703873478653366233) -->
-    <skip />
-    <!-- no translation found for permgrouplab_systemTools (1840847965111633430) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_systemTools (2810337951496685271) -->
-    <skip />
-    <!-- no translation found for permgrouplab_developmentTools (692844635256963358) -->
-    <skip />
-    <!-- no translation found for permgroupdesc_developmentTools (5253915519857796400) -->
-    <skip />
-    <!-- no translation found for permlab_statusBar (8789506912215455922) -->
-    <skip />
-    <!-- no translation found for permdesc_statusBar (5034247171231682403) -->
-    <skip />
-    <!-- no translation found for permlab_expandStatusBar (6382500803293284173) -->
-    <skip />
-    <!-- no translation found for permdesc_expandStatusBar (90953162060681436) -->
-    <skip />
-    <!-- no translation found for permlab_processOutgoingCalls (786316295241100144) -->
-    <skip />
-    <!-- no translation found for permdesc_processOutgoingCalls (1655242138991854396) -->
-    <skip />
-    <!-- no translation found for permlab_receiveSms (5820796051959871222) -->
-    <skip />
-    <!-- no translation found for permdesc_receiveSms (2265740044646990161) -->
-    <skip />
-    <!-- no translation found for permlab_receiveMms (7983091218880782611) -->
-    <skip />
-    <!-- no translation found for permdesc_receiveMms (3641275586518289960) -->
-    <skip />
-    <!-- no translation found for permlab_sendSms (4713837923748234081) -->
-    <skip />
-    <!-- no translation found for permdesc_sendSms (7126594387176704010) -->
-    <skip />
-    <!-- no translation found for permlab_readSms (4256004535185449429) -->
-    <skip />
-    <!-- no translation found for permdesc_readSms (4586480500886941902) -->
-    <skip />
-    <!-- no translation found for permlab_writeSms (8453452414726246828) -->
-    <skip />
-    <!-- no translation found for permdesc_writeSms (1036408118901361812) -->
-    <skip />
-    <!-- no translation found for permlab_receiveWapPush (5726837205927152203) -->
-    <skip />
-    <!-- no translation found for permdesc_receiveWapPush (4779188629794134886) -->
-    <skip />
-    <!-- no translation found for permlab_getTasks (357640569227780364) -->
-    <skip />
-    <!-- no translation found for permdesc_getTasks (2916615403728003200) -->
-    <skip />
-    <!-- no translation found for permlab_reorderTasks (4758862288285224517) -->
-    <skip />
-    <!-- no translation found for permdesc_reorderTasks (7507060843941912021) -->
-    <skip />
-    <!-- no translation found for permlab_setDebugApp (2973363275929449444) -->
-    <skip />
-    <!-- no translation found for permdesc_setDebugApp (5720449860498265972) -->
-    <skip />
-    <!-- no translation found for permlab_changeConfiguration (8581093564179818627) -->
-    <skip />
-    <!-- no translation found for permdesc_changeConfiguration (4055366453803187171) -->
-    <skip />
-    <!-- no translation found for permlab_restartPackages (5836367540766044606) -->
-    <skip />
-    <!-- no translation found for permdesc_restartPackages (1764965996765573321) -->
-    <skip />
-    <!-- no translation found for permlab_setProcessForeground (4860990420780868638) -->
-    <skip />
-    <!-- no translation found for permdesc_setProcessForeground (3795477299954784360) -->
-    <skip />
-    <!-- no translation found for permlab_forceBack (4737517869935566733) -->
-    <skip />
-    <!-- no translation found for permdesc_forceBack (5579316297001154697) -->
-    <skip />
-    <!-- no translation found for permlab_dump (3177569414212943167) -->
-    <skip />
-    <!-- no translation found for permdesc_dump (1815913623373011608) -->
-    <skip />
-    <!-- no translation found for permlab_addSystemService (9166015020584794942) -->
-    <skip />
-    <!-- no translation found for permdesc_addSystemService (2310425587289835743) -->
-    <skip />
-    <!-- no translation found for permlab_runSetActivityWatcher (2615943932761994905) -->
-    <skip />
-    <!-- no translation found for permdesc_runSetActivityWatcher (2488524206195482220) -->
-    <skip />
-    <!-- no translation found for permlab_broadcastPackageRemoved (355775368495637820) -->
-    <skip />
-    <!-- no translation found for permdesc_broadcastPackageRemoved (6486181398191058385) -->
-    <skip />
-    <!-- no translation found for permlab_broadcastSmsReceived (1994692154847312518) -->
-    <skip />
-    <!-- no translation found for permdesc_broadcastSmsReceived (6072362543164841432) -->
-    <skip />
-    <!-- no translation found for permlab_broadcastWapPush (3070023012636951639) -->
-    <skip />
-    <!-- no translation found for permdesc_broadcastWapPush (726912255218924336) -->
-    <skip />
-    <!-- no translation found for permlab_setProcessLimit (5190694306017260601) -->
-    <skip />
-    <!-- no translation found for permdesc_setProcessLimit (593938303319848578) -->
-    <skip />
-    <!-- no translation found for permlab_setAlwaysFinish (8745533365504920540) -->
-    <skip />
-    <!-- no translation found for permdesc_setAlwaysFinish (2437195869854312148) -->
-    <skip />
-    <!-- no translation found for permlab_batteryStats (1598947993704535568) -->
-    <skip />
-    <!-- no translation found for permdesc_batteryStats (6247598531831307989) -->
-    <skip />
-    <!-- no translation found for permlab_internalSystemWindow (5780262737320556654) -->
-    <skip />
-    <!-- no translation found for permdesc_internalSystemWindow (6495031598062517795) -->
-    <skip />
-    <!-- no translation found for permlab_systemAlertWindow (843729657746130626) -->
-    <skip />
-    <!-- no translation found for permdesc_systemAlertWindow (2731854380682210852) -->
-    <skip />
-    <!-- no translation found for permlab_setAnimationScale (2419250686027992384) -->
-    <skip />
-    <!-- no translation found for permdesc_setAnimationScale (8518027785481727264) -->
-    <skip />
-    <!-- no translation found for permlab_manageAppTokens (1033424552444304594) -->
-    <skip />
-    <!-- no translation found for permdesc_manageAppTokens (7285840918912623550) -->
-    <skip />
-    <!-- no translation found for permlab_injectEvents (1383601196263145482) -->
-    <skip />
-    <!-- no translation found for permdesc_injectEvents (840097509341464737) -->
-    <skip />
-    <!-- no translation found for permlab_readInputState (2723668746963882102) -->
-    <skip />
-    <!-- no translation found for permdesc_readInputState (4651137638757852001) -->
-    <skip />
-    <!-- no translation found for permlab_setOrientation (1112555600323148680) -->
-    <skip />
-    <!-- no translation found for permdesc_setOrientation (1960269530378827858) -->
-    <skip />
-    <!-- no translation found for permlab_signalPersistentProcesses (8511163028160623175) -->
-    <skip />
-    <!-- no translation found for permdesc_signalPersistentProcesses (1099349638354917733) -->
-    <skip />
-    <!-- no translation found for permlab_persistentActivity (8163108526929094627) -->
-    <skip />
-    <!-- no translation found for permdesc_persistentActivity (5258975883823299624) -->
-    <skip />
-    <!-- no translation found for permlab_deletePackages (5005536434839333208) -->
-    <skip />
-    <!-- no translation found for permdesc_deletePackages (2687196995215591923) -->
-    <skip />
-    <!-- no translation found for permlab_clearAppUserData (3858185484601410171) -->
-    <skip />
-    <!-- no translation found for permdesc_clearAppUserData (7233537744753081136) -->
-    <skip />
-    <!-- no translation found for permlab_deleteCacheFiles (7362746182961997888) -->
-    <skip />
-    <!-- no translation found for permdesc_deleteCacheFiles (8293849509208181266) -->
-    <skip />
-    <!-- no translation found for permlab_getPackageSize (6743556676630447973) -->
-    <skip />
-    <!-- no translation found for permdesc_getPackageSize (2893996655828539776) -->
-    <skip />
-    <!-- no translation found for permlab_installPackages (1637554234554641998) -->
-    <skip />
-    <!-- no translation found for permdesc_installPackages (4747794850590875195) -->
-    <skip />
-    <!-- no translation found for permlab_clearAppCache (7860214328511700776) -->
-    <skip />
-    <!-- no translation found for permdesc_clearAppCache (5203820862573167878) -->
-    <skip />
-    <!-- no translation found for permlab_readLogs (6653488552442991707) -->
-    <skip />
-    <!-- no translation found for permdesc_readLogs (356352685800884319) -->
-    <skip />
-    <!-- no translation found for permlab_diagnostic (2955142476313469329) -->
-    <skip />
-    <!-- no translation found for permdesc_diagnostic (1282409892215520166) -->
-    <skip />
-    <!-- no translation found for permlab_changeComponentState (8107835954049971459) -->
-    <skip />
-    <!-- no translation found for permdesc_changeComponentState (1791096057705836844) -->
-    <skip />
-    <!-- no translation found for permlab_setPreferredApplications (4355701371185331520) -->
-    <skip />
-    <!-- no translation found for permdesc_setPreferredApplications (9029326613767614711) -->
-    <skip />
-    <!-- no translation found for permlab_writeSettings (2915467191611898256) -->
-    <skip />
-    <!-- no translation found for permdesc_writeSettings (8492982548350342641) -->
-    <skip />
-    <!-- no translation found for permlab_writeSecureSettings (4851801872124242319) -->
-    <skip />
-    <!-- no translation found for permdesc_writeSecureSettings (2080620249472761366) -->
-    <skip />
-    <!-- no translation found for permlab_writeGservices (296370685945777755) -->
-    <skip />
-    <!-- no translation found for permdesc_writeGservices (2496928471286495053) -->
-    <skip />
-    <!-- no translation found for permlab_receiveBootCompleted (5598819384278633845) -->
-    <skip />
-    <!-- no translation found for permdesc_receiveBootCompleted (3197439472472771192) -->
-    <skip />
-    <!-- no translation found for permlab_broadcastSticky (8142357333543531543) -->
-    <skip />
-    <!-- no translation found for permdesc_broadcastSticky (8488762822718743531) -->
-    <skip />
-    <!-- no translation found for permlab_readContacts (5116003370450871686) -->
-    <skip />
-    <!-- no translation found for permdesc_readContacts (3499378044902258770) -->
-    <skip />
-    <!-- no translation found for permlab_writeContacts (1555136823460617179) -->
-    <skip />
-    <!-- no translation found for permdesc_writeContacts (4787318403287293114) -->
-    <skip />
-    <!-- no translation found for permlab_writeOwnerData (8036840529708535113) -->
-    <skip />
-    <!-- no translation found for permdesc_writeOwnerData (5873447528845878348) -->
-    <skip />
-    <!-- no translation found for permlab_readOwnerData (1847040178513733757) -->
-    <skip />
-    <!-- no translation found for permdesc_readOwnerData (7563299529149214764) -->
-    <skip />
-    <!-- no translation found for permlab_readCalendar (2111238731453410895) -->
-    <skip />
-    <!-- no translation found for permdesc_readCalendar (4408253940601239114) -->
-    <skip />
-    <!-- no translation found for permlab_writeCalendar (7518052789370653396) -->
-    <skip />
-    <!-- no translation found for permdesc_writeCalendar (8057304232140147596) -->
-    <skip />
-    <!-- no translation found for permlab_accessMockLocation (321094551062270213) -->
-    <skip />
-    <!-- no translation found for permdesc_accessMockLocation (3651565866471419739) -->
-    <skip />
-    <!-- no translation found for permlab_accessLocationExtraCommands (8291822077788811687) -->
-    <skip />
-    <!-- no translation found for permdesc_accessLocationExtraCommands (5135782633548630731) -->
-    <skip />
-    <!-- no translation found for permlab_accessFineLocation (4846261651944924865) -->
-    <skip />
-    <!-- no translation found for permdesc_accessFineLocation (3572307331039348419) -->
-    <skip />
-    <!-- no translation found for permlab_accessCoarseLocation (1760779730797169189) -->
-    <skip />
-    <!-- no translation found for permdesc_accessCoarseLocation (8878785899768310712) -->
-    <skip />
-    <!-- no translation found for permlab_accessSurfaceFlinger (6405475452322847618) -->
-    <skip />
-    <!-- no translation found for permdesc_accessSurfaceFlinger (5348283543622360967) -->
-    <skip />
-    <!-- no translation found for permlab_readFrameBuffer (4655248388550039199) -->
-    <skip />
-    <!-- no translation found for permdesc_readFrameBuffer (794888199105081402) -->
-    <skip />
-    <!-- no translation found for permlab_modifyAudioSettings (1587341813207960943) -->
-    <skip />
-    <!-- no translation found for permdesc_modifyAudioSettings (1447143004892708149) -->
-    <skip />
-    <!-- no translation found for permlab_recordAudio (4447848534036991667) -->
-    <skip />
-    <!-- no translation found for permdesc_recordAudio (6936874682400894820) -->
-    <skip />
-    <!-- no translation found for permlab_camera (1944473855727060380) -->
-    <skip />
-    <!-- no translation found for permdesc_camera (5978058582323766022) -->
-    <skip />
-    <!-- no translation found for permlab_brick (4749832243303289777) -->
-    <skip />
-    <!-- no translation found for permdesc_brick (7428524578693695766) -->
-    <skip />
-    <!-- no translation found for permlab_reboot (8844650672567077423) -->
-    <skip />
-    <!-- no translation found for permdesc_reboot (4704919552870918328) -->
-    <skip />
-    <!-- no translation found for permlab_mount_unmount_filesystems (1009574821038043781) -->
-    <skip />
-    <!-- no translation found for permdesc_mount_unmount_filesystems (100792065894811109) -->
-    <skip />
-    <!-- no translation found for permlab_vibrate (61984555644467146) -->
-    <skip />
-    <!-- no translation found for permdesc_vibrate (7831723100758509238) -->
-    <skip />
-    <!-- no translation found for permlab_flashlight (9097145977808182652) -->
-    <skip />
-    <!-- no translation found for permdesc_flashlight (7851502731988978358) -->
-    <skip />
-    <!-- no translation found for permlab_hardware_test (4103324677866524254) -->
-    <skip />
-    <!-- no translation found for permdesc_hardware_test (7315242723603994769) -->
-    <skip />
-    <!-- no translation found for permlab_callPhone (168275616535116686) -->
-    <skip />
-    <!-- no translation found for permdesc_callPhone (1852033967965785973) -->
-    <skip />
-    <!-- no translation found for permlab_callPrivileged (2166923597287697159) -->
-    <skip />
-    <!-- no translation found for permdesc_callPrivileged (5109789447971735501) -->
-    <skip />
-    <!-- no translation found for permlab_locationUpdates (4216418293360456836) -->
-    <skip />
-    <!-- no translation found for permdesc_locationUpdates (7635814693478743648) -->
-    <skip />
-    <!-- no translation found for permlab_checkinProperties (2260796787386280708) -->
-    <skip />
-    <!-- no translation found for permdesc_checkinProperties (3508022022841741945) -->
-    <skip />
-    <!-- no translation found for permlab_modifyPhoneState (7791696535097912313) -->
-    <skip />
-    <!-- no translation found for permdesc_modifyPhoneState (6352405226410454770) -->
-    <skip />
-    <!-- no translation found for permlab_readPhoneState (7320082586621086653) -->
-    <skip />
-    <!-- no translation found for permdesc_readPhoneState (8004450067066407969) -->
-    <skip />
-    <!-- no translation found for permlab_wakeLock (1591164750935072136) -->
-    <skip />
-    <!-- no translation found for permdesc_wakeLock (160471538196734936) -->
-    <skip />
-    <!-- no translation found for permlab_devicePower (9214865067086065548) -->
-    <skip />
-    <!-- no translation found for permdesc_devicePower (5608364066480036402) -->
-    <skip />
-    <!-- no translation found for permlab_factoryTest (7786199300637896247) -->
-    <skip />
-    <!-- no translation found for permdesc_factoryTest (3466066005210542042) -->
-    <skip />
-    <!-- no translation found for permlab_setWallpaper (2256730637138641725) -->
-    <skip />
-    <!-- no translation found for permdesc_setWallpaper (3034653140208685093) -->
-    <skip />
-    <!-- no translation found for permlab_setWallpaperHints (4192438316932517807) -->
-    <skip />
-    <!-- no translation found for permdesc_setWallpaperHints (738757439960921674) -->
-    <skip />
-    <!-- no translation found for permlab_masterClear (6155403967270586906) -->
-    <skip />
-    <!-- no translation found for permdesc_masterClear (4213553172342689754) -->
-    <skip />
-    <!-- no translation found for permlab_setTimeZone (477196167239548690) -->
-    <skip />
-    <!-- no translation found for permdesc_setTimeZone (8564892020460841198) -->
-    <skip />
-    <!-- no translation found for permlab_getAccounts (2764070033402295170) -->
-    <skip />
-    <!-- no translation found for permdesc_getAccounts (1203491378748649898) -->
-    <skip />
-    <!-- no translation found for permlab_accessNetworkState (2032916924886010827) -->
-    <skip />
-    <!-- no translation found for permdesc_accessNetworkState (7081329402551195933) -->
-    <skip />
-    <!-- no translation found for permlab_createNetworkSockets (4706698319966917864) -->
-    <skip />
-    <!-- no translation found for permdesc_createNetworkSockets (2580337178778551792) -->
-    <skip />
-    <!-- no translation found for permlab_writeApnSettings (3190585220761979369) -->
-    <skip />
-    <!-- no translation found for permdesc_writeApnSettings (4093875220468761052) -->
-    <skip />
-    <!-- no translation found for permlab_changeNetworkState (2710779001260856872) -->
-    <skip />
-    <!-- no translation found for permdesc_changeNetworkState (8076109230787022270) -->
-    <skip />
-    <!-- no translation found for permlab_accessWifiState (3613679494230374297) -->
-    <skip />
-    <!-- no translation found for permdesc_accessWifiState (8226508433563326925) -->
-    <skip />
-    <!-- no translation found for permlab_changeWifiState (6043889338995432957) -->
-    <skip />
-    <!-- no translation found for permdesc_changeWifiState (7829372845909567994) -->
-    <skip />
-    <!-- no translation found for permlab_bluetoothAdmin (5513286736585647334) -->
-    <skip />
-    <!-- no translation found for permdesc_bluetoothAdmin (1838208497914347365) -->
-    <skip />
-    <!-- no translation found for permlab_bluetooth (6378797624765639115) -->
-    <skip />
-    <!-- no translation found for permdesc_bluetooth (8592386018922265273) -->
-    <skip />
-    <!-- no translation found for permlab_disableKeyguard (4574886811903233903) -->
-    <skip />
-    <!-- no translation found for permdesc_disableKeyguard (815972646344251271) -->
-    <skip />
-    <!-- no translation found for permlab_readSyncSettings (8818819977141505127) -->
-    <skip />
-    <!-- no translation found for permdesc_readSyncSettings (8454705401908767847) -->
-    <skip />
-    <!-- no translation found for permlab_writeSyncSettings (4514911143753152941) -->
-    <skip />
-    <!-- no translation found for permdesc_writeSyncSettings (7630627689635091836) -->
-    <skip />
-    <!-- no translation found for permlab_readSyncStats (5748337739678952863) -->
-    <skip />
-    <!-- no translation found for permdesc_readSyncStats (582551457321957183) -->
-    <skip />
-    <!-- no translation found for permlab_subscribedFeedsRead (2043206814904506589) -->
-    <skip />
-    <!-- no translation found for permdesc_subscribedFeedsRead (6977343942680042449) -->
-    <skip />
-    <!-- no translation found for permlab_subscribedFeedsWrite (2556727307229571556) -->
-    <skip />
-    <!-- no translation found for permdesc_subscribedFeedsWrite (4134783294590266220) -->
-    <skip />
-    <!-- no translation found for phoneTypes:0 (6070018634209800981) -->
-    <!-- no translation found for phoneTypes:1 (1514509689885965711) -->
-    <!-- no translation found for phoneTypes:2 (497473201754095234) -->
-    <!-- no translation found for phoneTypes:3 (5554432614281047787) -->
-    <!-- no translation found for phoneTypes:4 (2222084401110150993) -->
-    <!-- no translation found for phoneTypes:5 (2290007103906353121) -->
-    <!-- no translation found for phoneTypes:6 (6930783706213719251) -->
-    <!-- no translation found for phoneTypes:7 (1326005699931077792) -->
-    <!-- no translation found for emailAddressTypes:0 (1540640638077615417) -->
-    <!-- no translation found for emailAddressTypes:1 (4252853367575831977) -->
-    <!-- no translation found for emailAddressTypes:2 (7158046581744435718) -->
-    <!-- no translation found for emailAddressTypes:3 (3625034471181268169) -->
-    <!-- no translation found for postalAddressTypes:0 (5732960259696659380) -->
-    <!-- no translation found for postalAddressTypes:1 (7132240704786130285) -->
-    <!-- no translation found for postalAddressTypes:2 (1317604357745852817) -->
-    <!-- no translation found for postalAddressTypes:3 (1582953598462826702) -->
-    <!-- no translation found for imAddressTypes:0 (7806620012096518833) -->
-    <!-- no translation found for imAddressTypes:1 (5748846799950672787) -->
-    <!-- no translation found for imAddressTypes:2 (6196536810275073680) -->
-    <!-- no translation found for imAddressTypes:3 (8519128375350623648) -->
-    <!-- no translation found for organizationTypes:0 (1299224825223821142) -->
-    <!-- no translation found for organizationTypes:1 (2455717447227299354) -->
-    <!-- no translation found for organizationTypes:2 (7027570839313438290) -->
-    <!-- no translation found for imProtocols:0 (3318725788774688043) -->
-    <!-- no translation found for imProtocols:1 (1787713387022932886) -->
-    <!-- no translation found for imProtocols:2 (6751174158442316516) -->
-    <!-- no translation found for imProtocols:3 (1151283347465052653) -->
-    <!-- no translation found for imProtocols:4 (2157980008878817934) -->
-    <!-- no translation found for imProtocols:5 (7836237460308230767) -->
-    <!-- no translation found for imProtocols:6 (1180789904462172516) -->
-    <!-- no translation found for imProtocols:7 (21955111672779862) -->
-    <!-- no translation found for keyguard_password_enter_pin_code (6779835451906812518) -->
-    <skip />
-    <!-- no translation found for keyguard_password_wrong_pin_code (230312338493035499) -->
-    <skip />
-    <!-- no translation found for keyguard_label_text (3902954467573892533) -->
-    <skip />
-    <!-- no translation found for emergency_call_dialog_number_for_display (6256361184251050511) -->
-    <skip />
-    <!-- no translation found for lockscreen_carrier_default (5222269885486229730) -->
-    <skip />
-    <!-- no translation found for lockscreen_screen_locked (1922273663462058967) -->
-    <skip />
-    <!-- no translation found for lockscreen_instructions_when_pattern_enabled (7535864145009679967) -->
-    <skip />
-    <!-- no translation found for lockscreen_instructions_when_pattern_disabled (6526504555912746785) -->
-    <skip />
-    <!-- no translation found for lockscreen_pattern_instructions (8984964506352089877) -->
-    <skip />
-    <!-- no translation found for lockscreen_emergency_call (422835617844547383) -->
-    <skip />
-    <!-- no translation found for lockscreen_pattern_correct (7104753084746383672) -->
-    <skip />
-    <!-- no translation found for lockscreen_pattern_wrong (7517004470797680361) -->
-    <skip />
-    <!-- no translation found for lockscreen_plugged_in (8806977650003537118) -->
-    <skip />
-    <!-- no translation found for lockscreen_low_battery (9002637795199621345) -->
-    <skip />
-    <!-- no translation found for lockscreen_missing_sim_message_short (5051192587315492957) -->
-    <skip />
-    <!-- no translation found for lockscreen_missing_sim_message (8912914495901434841) -->
-    <skip />
-    <!-- no translation found for lockscreen_missing_sim_instructions (8125847194365725429) -->
-    <skip />
-    <!-- no translation found for lockscreen_network_locked_message (323609607922245071) -->
-    <skip />
-    <!-- no translation found for lockscreen_sim_puk_locked_message (1005803622871256359) -->
-    <skip />
-    <!-- no translation found for lockscreen_sim_puk_locked_instructions (5033160098036646955) -->
-    <skip />
-    <!-- no translation found for lockscreen_sim_locked_message (7398401200962556379) -->
-    <skip />
-    <!-- no translation found for lockscreen_sim_unlock_progress_dialog_message (5939537246164692076) -->
-    <skip />
-    <!-- no translation found for lockscreen_too_many_failed_attempts_dialog_message (6709066241494622136) -->
-    <skip />
-    <!-- no translation found for lockscreen_failed_attempts_almost_glogin (1569017295989454551) -->
-    <skip />
-    <!-- no translation found for lockscreen_too_many_failed_attempts_countdown (8823588000022797566) -->
-    <skip />
-    <!-- no translation found for lockscreen_forgot_pattern_button_text (4219994639843985488) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_too_many_attempts (7504679498838839295) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_instructions (6542400673357252011) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_username_hint (6378418320242015111) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_password_hint (3224230234042131153) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_submit_button (5562051040043760034) -->
-    <skip />
-    <!-- no translation found for lockscreen_glogin_invalid_input (4881057177478491580) -->
-    <skip />
-    <!-- no translation found for status_bar_time_format (2168573805413119180) -->
-    <!-- no translation found for hour_minute_ampm (1850330605794978742) -->
-    <skip />
-    <!-- no translation found for hour_minute_cap_ampm (1122840227537374196) -->
-    <skip />
-    <!-- no translation found for hour_ampm (7665432130905376251) -->
-    <skip />
-    <!-- no translation found for hour_cap_ampm (3600295014648400268) -->
-    <skip />
-    <!-- no translation found for status_bar_clear_all_button (2202004591253243750) -->
-    <skip />
-    <!-- no translation found for status_bar_no_notifications_title (5123133188102094464) -->
-    <skip />
-    <!-- no translation found for status_bar_ongoing_events_title (799961521630569167) -->
-    <skip />
-    <!-- no translation found for status_bar_latest_events_title (5414094466807164279) -->
-    <skip />
-    <!-- no translation found for battery_status_text_percent_format (7391464609447031944) -->
-    <skip />
-    <!-- no translation found for battery_status_charging (5078780715755132756) -->
-    <skip />
-    <!-- no translation found for battery_low_title (3665400828395001695) -->
-    <skip />
-    <!-- no translation found for battery_low_subtitle (7537149915372180016) -->
-    <skip />
-    <!-- no translation found for battery_low_percent_format (8635359708781261154) -->
-    <skip />
-    <!-- no translation found for factorytest_failed (5784901108608196679) -->
-    <skip />
-    <!-- no translation found for factorytest_not_system (6330339565054095688) -->
-    <skip />
-    <!-- no translation found for factorytest_no_action (1662569013408679347) -->
-    <skip />
-    <!-- no translation found for factorytest_reboot (6080912029718954885) -->
-    <skip />
-    <!-- no translation found for save_password_label (4129493019621348626) -->
-    <skip />
-    <!-- no translation found for save_password_message (7412617920202682045) -->
-    <skip />
-    <!-- no translation found for save_password_notnow (3887362423496820832) -->
-    <skip />
-    <!-- no translation found for save_password_remember (4319688896716308569) -->
-    <skip />
-    <!-- no translation found for save_password_never (1836981952883642377) -->
-    <skip />
-    <!-- no translation found for open_permission_deny (6408502671105717111) -->
-    <skip />
-    <!-- no translation found for text_copied (6106873823411904723) -->
-    <skip />
-    <!-- no translation found for more_item_label (5204075544750360778) -->
-    <skip />
-    <!-- no translation found for prepend_shortcut_label (6091430648975237047) -->
-    <skip />
-    <!-- no translation found for menu_space_shortcut_label (194586306440382711) -->
-    <skip />
-    <!-- no translation found for menu_enter_shortcut_label (7214761412193519345) -->
-    <skip />
-    <!-- no translation found for menu_delete_shortcut_label (2854936426194985313) -->
-    <skip />
-    <!-- no translation found for search_go (4823831235057123206) -->
-    <skip />
-    <!-- no translation found for today (6914914811057683636) -->
-    <skip />
-    <!-- no translation found for yesterday (5280495043584636271) -->
-    <skip />
-    <!-- no translation found for tomorrow (561215115479060939) -->
-    <skip />
-    <!-- no translation found for oneMonthDurationPast (3402179395240209557) -->
-    <skip />
-    <!-- no translation found for beforeOneMonthDurationPast (7578100953282866827) -->
-    <skip />
-    <!-- no translation found for num_seconds_ago:one (7416512229671810725) -->
-    <!-- no translation found for num_seconds_ago:other (8138756910300398447) -->
-    <!-- no translation found for num_minutes_ago:one (8620869479299420562) -->
-    <!-- no translation found for num_minutes_ago:other (5065488162050522741) -->
-    <!-- no translation found for num_hours_ago:one (853404611989669641) -->
-    <!-- no translation found for num_hours_ago:other (3558873784561756849) -->
-    <!-- no translation found for num_days_ago:one (4222479980812128212) -->
-    <!-- no translation found for num_days_ago:other (5445701370433601703) -->
-    <!-- no translation found for in_num_seconds:one (4253290037777327003) -->
-    <!-- no translation found for in_num_seconds:other (1280033870920841404) -->
-    <!-- no translation found for in_num_minutes:one (1487585791027953091) -->
-    <!-- no translation found for in_num_minutes:other (6274204576475209932) -->
-    <!-- no translation found for in_num_hours:one (6501470863235186391) -->
-    <!-- no translation found for in_num_hours:other (4415358752953289251) -->
-    <!-- no translation found for in_num_days:one (5608475533104443893) -->
-    <!-- no translation found for in_num_days:other (3827193006163842267) -->
-    <!-- no translation found for preposition_for_date (2689847983632851560) -->
-    <skip />
-    <!-- no translation found for preposition_for_time (2613388053493148013) -->
-    <skip />
-    <!-- no translation found for preposition_for_year (6968468294728152393) -->
-    <skip />
-    <!-- no translation found for day (7849249054576985912) -->
-    <skip />
-    <!-- no translation found for days (8381828105391141169) -->
-    <skip />
-    <!-- no translation found for hour (1044439788994278057) -->
-    <skip />
-    <!-- no translation found for hours (9008157371441255845) -->
-    <skip />
-    <!-- no translation found for minute (2434431396283136076) -->
-    <skip />
-    <!-- no translation found for minutes (8176836254200264856) -->
-    <skip />
-    <!-- no translation found for second (6620645953323664299) -->
-    <skip />
-    <!-- no translation found for seconds (6416703426008384360) -->
-    <skip />
-    <!-- no translation found for week (7738046527402739781) -->
-    <skip />
-    <!-- no translation found for weeks (3178327674459887377) -->
-    <skip />
-    <!-- no translation found for year (8024790425994085153) -->
-    <skip />
-    <!-- no translation found for years (8592090054773244417) -->
-    <skip />
-    <!-- no translation found for sunday (4811082193700148223) -->
-    <skip />
-    <!-- no translation found for monday (7543713499896911033) -->
-    <skip />
-    <!-- no translation found for tuesday (7962192298359117585) -->
-    <skip />
-    <!-- no translation found for wednesday (5768878309383390437) -->
-    <skip />
-    <!-- no translation found for thursday (5690060634904123607) -->
-    <skip />
-    <!-- no translation found for friday (2718325370375116889) -->
-    <skip />
-    <!-- no translation found for saturday (222899317300942333) -->
-    <skip />
-    <!-- no translation found for every_weekday (8466333034903391066) -->
-    <skip />
-    <!-- no translation found for daily (1661712840773846970) -->
-    <skip />
-    <!-- no translation found for weekly (578642117234613009) -->
-    <skip />
-    <!-- no translation found for monthly (8526124657540210537) -->
-    <skip />
-    <!-- no translation found for yearly (8083067713764127070) -->
-    <skip />
-    <!-- no translation found for VideoView_error_title (1024334251681931859) -->
-    <skip />
-    <!-- no translation found for VideoView_error_text_unknown (3398417247398476771) -->
-    <skip />
-    <!-- no translation found for VideoView_error_button (3144127115413163445) -->
-    <skip />
-    <!-- no translation found for am (5354895493921411502) -->
-    <skip />
-    <!-- no translation found for pm (7206933220587555766) -->
-    <skip />
-    <!-- from values-de/strings.xml and removal of all the german craziyness-->
-    <skip />
-    <!-- no translation found for numeric_date (5120078478872821100) -->
-    <!-- no translation found for wday1_date1_time1_wday2_date2_time2 (7066878981949584861) -->
-    <!-- no translation found for wday1_date1_wday2_date2 (8671068747172261907) -->
-    <!-- no translation found for numeric_date (5537215108967329745) -->
-    <skip />
-    <!-- no translation found for date1_time1_date2_time2 (3645498975775629615) -->
-    <!-- no translation found for date1_date2 (377057563556488062) -->
-    <!-- no translation found for time1_time2 (3173474242109288305) -->
-    <!-- no translation found for time_wday_date (8928955562064570313) -->
-    <!-- no translation found for wday_date (8794741400546136975) -->
-    <!-- no translation found for time_date (1922644512833014496) -->
-    <!-- no translation found for time_wday (1422050241301754712) -->
-    <skip />
-    <!-- no translation found for full_date_month_first (6011143962222283357) -->
-    <skip />
-    <!-- no translation found for full_date_day_first (8621594762705478189) -->
-    <!-- no translation found for medium_date_month_first (48990963718825728) -->
-    <skip />
-    <!-- no translation found for medium_date_day_first (2898992016440387123) -->
-    <!-- no translation found for twelve_hour_time_format (6015557937879492156) -->
-    <skip />
-    <!-- no translation found for twenty_four_hour_time_format (5176807998669709535) -->
-    <skip />
-    <!-- no translation found for noon (8390796001560682897) -->
-    <skip />
-    <!-- no translation found for Noon (7698941576181064429) -->
-    <skip />
-    <!-- no translation found for midnight (7773339795626486146) -->
-    <skip />
-    <!-- no translation found for Midnight (1260172107848123187) -->
-    <skip />
-    <!-- no translation found for month_day (3356633704511426364) -->
-    <!-- no translation found for month (3017405760734206414) -->
-    <skip />
-    <!-- no translation found for month_day_year (2435948225709176752) -->
-    <!-- no translation found for month_year (6228414124777343135) -->
-    <skip />
-    <!-- no translation found for time_of_day (8375993139317154157) -->
-    <!-- no translation found for date_and_time (9197690194373107109) -->
-    <skip />
-    <!-- no translation found for same_year_md1_md2 (9199324363135981317) -->
-    <!-- no translation found for same_year_wday1_md1_wday2_md2 (6006392413355305178) -->
-     <!-- no translation found for date_and_time (353898423108629694) -->
-    <!-- no translation found for same_year_mdy1_mdy2 (1576657593937827090) -->
-    <!-- no translation found for same_year_wday1_mdy1_wday2_mdy2 (9135935796468891580) -->
-    <!-- no translation found for same_year_md1_time1_md2_time2 (2172964106375558081) -->
-    <!-- no translation found for same_year_wday1_md1_time1_wday2_md2_time2 (1702879534101786310) -->
-    <!-- no translation found for same_year_mdy1_time1_mdy2_time2 (2476443311723358767) -->
-    <!-- no translation found for same_year_wday1_mdy1_time1_wday2_mdy2_time2 (1564837340334069879) -->
-    <!-- no translation found for numeric_md1_md2 (8908376522875100300) -->
-    <!-- no translation found for numeric_wday1_md1_wday2_md2 (3239690882018292077) -->
-    <!-- no translation found for numeric_mdy1_mdy2 (8883797176939233525) -->
-    <!-- no translation found for numeric_wday1_mdy1_wday2_mdy2 (4150475769255828954) -->
-    <!-- no translation found for numeric_md1_time1_md2_time2 (3624746590607741419) -->
-    <!-- no translation found for numeric_wday1_md1_time1_wday2_md2_time2 (4258040955467298134) -->
-    <!-- no translation found for numeric_mdy1_time1_mdy2_time2 (3598215409314517987) -->
-    <!-- no translation found for numeric_wday1_mdy1_time1_wday2_mdy2_time2 (264076937155877259) -->
-    <!-- no translation found for same_month_md1_md2 (2393563617438036111) -->
-    <!-- no translation found for same_month_wday1_md1_wday2_md2 (1208946773794057819) -->
-    <!-- no translation found for same_month_mdy1_mdy2 (3713236637869030492) -->
-    <!-- no translation found for same_month_wday1_mdy1_wday2_mdy2 (389638922479870472) -->
-    <!-- no translation found for same_month_md1_time1_md2_time2 (7477075526337542685) -->
-    <!-- no translation found for same_month_wday1_md1_time1_wday2_md2_time2 (3516978303779391173) -->
-    <!-- no translation found for same_month_mdy1_time1_mdy2_time2 (7320410992514057310) -->
-    <!-- no translation found for same_month_wday1_mdy1_time1_wday2_mdy2_time2 (1332950588774239228) -->
-    <!-- no translation found for abbrev_month_day_year (5767271534015320250) -->
-    <!-- no translation found for abbrev_month_year (8058929633673942490) -->
-    <skip />
-    <!-- no translation found for abbrev_month_day (458867920693482757) -->
-    <!-- no translation found for abbrev_month (1674509986330181349) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_sunday (9057662850446501884) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_monday (7358451993082888343) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_tuesday (2282901451170509613) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_wednesday (2100217950343286482) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_thursday (5475158963242863176) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_friday (4081018004819837155) -->
-    <skip />
-    <!-- no translation found for day_of_week_long_saturday (1929694088305891795) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_sunday (6462580883948669820) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_monday (6960587654241349502) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_tuesday (7004462235990108936) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_wednesday (5688564741951314696) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_thursday (1784339868453982400) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_friday (4314577583604069357) -->
-    <skip />
-    <!-- no translation found for day_of_week_medium_saturday (70321191398427845) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_sunday (7403409454572591357) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_monday (5278358100012478239) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_tuesday (5121116040712487059) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_wednesday (1601079579293330319) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_thursday (5863422096017401812) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_friday (2916686031099723960) -->
-    <skip />
-    <!-- no translation found for day_of_week_short_saturday (8521564973195542073) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_sunday (1650484495176707638) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_monday (9133193697786876074) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_tuesday (4012095408481489663) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_wednesday (6279056612496078470) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_thursday (2748599403545071011) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_friday (5037282109124849673) -->
-    <skip />
-    <!-- no translation found for day_of_week_shorter_saturday (3208167155877833783) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_sunday (4683862964821549758) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_monday (6701142261471667000) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_tuesday (9098171980161292477) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_wednesday (655049238289460956) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_thursday (7816913627500884083) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_friday (903301878650619398) -->
-    <skip />
-    <!-- no translation found for day_of_week_shortest_saturday (5359692489649817988) -->
-    <skip />
-    <!-- no translation found for month_long_january (7128497801440564337) -->
-    <skip />
-    <!-- no translation found for month_long_february (7808570514581190617) -->
-    <skip />
-    <!-- no translation found for month_long_march (2061328556983796034) -->
-    <skip />
-    <!-- no translation found for month_long_april (6575007959043269919) -->
-    <skip />
-    <!-- no translation found for month_long_may (8404051103463071121) -->
-    <skip />
-    <!-- no translation found for month_long_june (6255771619238859451) -->
-    <skip />
-    <!-- no translation found for month_long_july (4129177743136800884) -->
-    <skip />
-    <!-- no translation found for month_long_august (5494331003296804494) -->
-    <skip />
-    <!-- no translation found for month_long_september (2691137479752033087) -->
-    <skip />
-    <!-- no translation found for month_long_october (7501261567327243313) -->
-    <skip />
-    <!-- no translation found for month_long_november (8759690753068763664) -->
-    <skip />
-    <!-- no translation found for month_long_december (4505008719696569497) -->
-    <skip />
-    <!-- no translation found for month_medium_january (2315492772833932512) -->
-    <skip />
-    <!-- no translation found for month_medium_february (118412521324313430) -->
-    <skip />
-    <!-- no translation found for month_medium_march (5546835583839352358) -->
-    <skip />
-    <!-- no translation found for month_medium_april (7052559668687733702) -->
-    <skip />
-    <!-- no translation found for month_medium_may (2825303871720116018) -->
-    <skip />
-    <!-- no translation found for month_medium_june (829843667101495271) -->
-    <skip />
-    <!-- no translation found for month_medium_july (5029778226925324789) -->
-    <skip />
-    <!-- no translation found for month_medium_august (8851230594641162805) -->
-    <skip />
-    <!-- no translation found for month_medium_september (8420590486625304647) -->
-    <skip />
-    <!-- no translation found for month_medium_october (1787382806172930239) -->
-    <skip />
-    <!-- no translation found for month_medium_november (675513809622370603) -->
-    <skip />
-    <!-- no translation found for month_medium_december (2934948295928978783) -->
-    <skip />
-    <!-- no translation found for month_shortest_january (6070060405144675883) -->
-    <skip />
-    <!-- no translation found for month_shortest_february (5632605004902176653) -->
-    <skip />
-    <!-- no translation found for month_shortest_march (4304231552356086624) -->
-    <skip />
-    <!-- no translation found for month_shortest_april (1166434066469385532) -->
-    <skip />
-    <!-- no translation found for month_shortest_may (9131326028845529001) -->
-    <skip />
-    <!-- no translation found for month_shortest_june (1875723154506665289) -->
-    <skip />
-    <!-- no translation found for month_shortest_july (2003596275389810773) -->
-    <skip />
-    <!-- no translation found for month_shortest_august (9120245162625763214) -->
-    <skip />
-    <!-- no translation found for month_shortest_september (7980651111022693669) -->
-    <skip />
-    <!-- no translation found for month_shortest_october (3640405450427788312) -->
-    <skip />
-    <!-- no translation found for month_shortest_november (4002935318566146993) -->
-    <skip />
-    <!-- no translation found for month_shortest_december (6213739417171334040) -->
-    <skip />
-    <!-- no translation found for elapsed_time_short_format_mm_ss (1294409362352514646) -->
-    <string name="elapsed_time_short_format_mm_ss">"<xliff:g id="MINUTES">%1$02d</xliff:g>:<xliff:g id="SECONDS">%2$02d</xliff:g>"</string>
-    <!-- no translation found for elapsed_time_short_format_h_mm_ss (2997059666628785039) -->
-    <string name="elapsed_time_short_format_h_mm_ss">"<xliff:g id="HOURS">%1$d</xliff:g>:<xliff:g id="MINUTES">%2$02d</xliff:g>:<xliff:g id="SECONDS">%3$02d</xliff:g>"</string>
-    <!-- no translation found for selectAll (691691810023908884) -->
-    <skip />
-    <!-- no translation found for cut (5845613239192595662) -->
-    <skip />
-    <skip />
-    <!-- no translation found for copy (8603721575469529820) -->
-    <skip />
-    <skip />
-    <!-- no translation found for paste (6458036735811828538) -->
-    <skip />
-    <!-- no translation found for copyUrl (5785708478767435812) -->
-    <skip />
-    <!-- no translation found for inputMethod (7911866729148111492) -->
-    <skip />
-    <!-- no translation found for editTextMenuTitle (3984253728638788023) -->
-    <skip />
-    <!-- no translation found for low_internal_storage_view_title (5997772070488639934) -->
-    <skip />
-    <!-- no translation found for low_internal_storage_view_text (2230118755295375293) -->
-    <skip />
-    <!-- no translation found for ok (4003878536083514869) -->
-    <skip />
-    <!-- no translation found for cancel (1527674037280267012) -->
-    <skip />
-    <!-- no translation found for yes (8185296114406773873) -->
-    <skip />
-    <!-- no translation found for no (2300685350903156262) -->
-    <skip />
-    <!-- no translation found for capital_on (8418242581217554942) -->
-    <skip />
-    <!-- no translation found for capital_off (8870368560477693851) -->
-    <skip />
-    <!-- no translation found for whichApplication (2828159696176255212) -->
-    <skip />
-    <!-- no translation found for alwaysUse (6433627451071144629) -->
-    <skip />
-    <!-- no translation found for clearDefaultHintMsg (5742432113023174321) -->
-    <skip />
-    <!-- no translation found for chooseActivity (7588691622928031978) -->
-    <skip />
-    <!-- no translation found for noApplications (4068560364116066745) -->
-    <skip />
-    <!-- no translation found for aerr_title (2654390351574026098) -->
-    <skip />
-    <!-- no translation found for aerr_application (4917288809565116720) -->
-    <skip />
-    <!-- no translation found for aerr_process (1273819861108073461) -->
-    <skip />
-    <!-- no translation found for anr_title (3305935690891435915) -->
-    <skip />
-    <!-- no translation found for anr_activity_application (1653036325679156678) -->
-    <skip />
-    <!-- no translation found for anr_activity_process (2674027618362070465) -->
-    <skip />
-    <!-- no translation found for anr_application_process (2163656674970221928) -->
-    <skip />
-    <!-- no translation found for anr_process (7747550780123472160) -->
-    <skip />
-    <!-- no translation found for force_close (9020954128872810669) -->
-    <skip />
-    <!-- no translation found for wait (7973775702304037058) -->
-    <skip />
-    <!-- no translation found for debug (857932504764728770) -->
-    <skip />
-    <!-- no translation found for sendText (6158329286172492543) -->
-    <skip />
-    <!-- no translation found for volume_ringtone (4121694816346562058) -->
-    <skip />
-    <!-- no translation found for volume_music (4869950240104717493) -->
-    <skip />
-    <!-- no translation found for volume_call (5723421277753250395) -->
-    <skip />
-    <!-- no translation found for volume_alarm (2752102730973081294) -->
-    <skip />
-    <!-- no translation found for volume_unknown (6908187627672375742) -->
-    <skip />
-    <!-- no translation found for ringtone_default (2873893375149093475) -->
-    <skip />
-    <!-- no translation found for ringtone_default_with_actual (5474076151665761913) -->
-    <skip />
-    <!-- no translation found for ringtone_silent (7477159279081654685) -->
-    <skip />
-    <!-- no translation found for ringtone_picker_title (7055241890764367884) -->
-    <skip />
-    <!-- no translation found for ringtone_unknown (6888219771401173795) -->
-    <skip />
-    <!-- no translation found for wifi_available:one (8168012881468888470) -->
-    <!-- no translation found for wifi_available:other (4666122955807117718) -->
-    <!-- no translation found for wifi_available_detailed:one (5107769161192143259) -->
-    <!-- no translation found for wifi_available_detailed:other (853347657960575809) -->
-    <!-- no translation found for select_character (3735110139249491726) -->
-    <skip />
-    <!-- no translation found for sms_control_default_app_name (7522184737840550841) -->
-    <skip />
-    <!-- no translation found for sms_control_title (2742400596989418394) -->
-    <skip />
-    <!-- no translation found for sms_control_message (3447126217666595989) -->
-    <skip />
-    <!-- no translation found for sms_control_yes (8839660939359273650) -->
-    <skip />
-    <!-- no translation found for sms_control_no (909756849988183801) -->
-    <skip />
-    <!-- no translation found for date_time_set (2495199891239480952) -->
-    <skip />
-    <!-- no translation found for default_permission_group (7742780381379652409) -->
-    <skip />
-    <!-- no translation found for no_permissions (85461124044682315) -->
-    <skip />
-    <!-- no translation found for perms_hide (4145325555929151849) -->
-    <skip />
-    <!-- no translation found for perms_show_all (6040194843455403173) -->
-    <skip />
-    <!-- no translation found for googlewebcontenthelper_loading (2140804350507245589) -->
-    <skip />
-    <!-- no translation found for usb_storage_title (8699631567051394409) -->
-    <skip />
-    <!-- no translation found for usb_storage_message (5344039189213308733) -->
-    <skip />
-    <!-- no translation found for usb_storage_button_mount (6700104384375121662) -->
-    <skip />
-    <!-- no translation found for usb_storage_button_unmount (465869657252626688) -->
-    <skip />
-    <!-- no translation found for usb_storage_error_message (3192564550748426087) -->
-    <skip />
-    <!-- no translation found for usb_storage_notification_title (6237028017872246940) -->
-    <skip />
-    <!-- no translation found for usb_storage_notification_message (7371717280517625905) -->
-    <skip />
-    <!-- no translation found for select_input_method (2658280517827502015) -->
-    <skip />
-    <!-- no translation found for fast_scroll_alphabet (1017432309285755759) -->
-    <skip />
-    <!-- no translation found for fast_scroll_numeric_alphabet (3092587363718901074) -->
-    <skip />
-    <!-- no translation found for candidates_style (7738463880139922176) -->
-    <skip />
-</resources>
diff --git a/core/res/res/values-en-rGB/strings.xml b/core/res/res/values-en-rGB/strings.xml
index 3e2d93e..5a7dbcd 100644
--- a/core/res/res/values-en-rGB/strings.xml
+++ b/core/res/res/values-en-rGB/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Allows the holder to bind to the top-level interface of a remote display. Should never be needed for normal apps."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bind to a widget service"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Allows the holder to bind to the top-level interface of a widget service. Should never be needed for normal apps."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bind to a route provider service"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Allows the holder to bind to any registered route providers. Should never be needed for normal apps."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interact with device admin"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Allows the holder to send intents to a device administrator. Should never be needed for normal apps."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bind to a TV input"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"turn phone on or off"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Allows the app to turn the tablet on or off."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Allows the app to turn the phone on or off."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"reset display timeout"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Allows the app to reset the display timeout."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"run in factory test mode"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Run as a low-level manufacturer test, allowing complete access to the tablet hardware. Only available when a tablet is running in manufacturer test mode."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Run as a low-level manufacturer test, allowing complete access to the phone hardware. Only available when a phone is running in manufacturer test mode."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Allows the app to read and write the cache file system."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"make/receive SIP calls"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Allows the app to make and receive SIP calls."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interact with in-call screen"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Allows the app to control when and how the user sees the in-call screen."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interact with in-call screen"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Allows the app to control when and how the user sees the in-call screen."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interact with telephony services"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Allows the app to interact with telephony services to make/receive calls."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"provide an in-call user experience"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Allows the app to provide an in-call user experience."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"read historical network usage"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Allows the app to read historical network usage for specific networks and apps."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"manage network policy"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Allows the holder to bind to the top-level interface of a notification listener service. Should never be needed for normal apps."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bind to a condition provider service"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Allows the holder to bind to the top-level interface of a condition provider service. Should never be needed for normal apps."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bind to a media route service"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Allows the holder to bind to the top-level interface of a media route service. Should never be needed for normal apps."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bind to a dream service"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Allows the holder to bind to the top-level interface of a dream service. Should never be needed for normal apps."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invoke the carrier-provided configuration app"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Share with %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Select a home app"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Use by default for this action."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Use a different app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Clear default in System settings &gt; Apps &gt; Downloaded."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Choose an action"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Choose an app for the USB device"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Allow"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Deny"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; would like to send a message to &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"This "<font fgcolor="#ffffb060">"may cause charges"</font>" on your mobile account."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"This will cause charges on your mobile account."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"This "<b>"may cause charges"</b>" on your mobile account."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"This will cause charges on your mobile account."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Send"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancel"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Remember my choice"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Touch to disable USB debugging."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Change keyboard"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Choose keyboards"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Physical keyboard"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Show input method"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Select keyboard layout"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Touch to select a keyboard layout."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Allows an application to bind to a trust agent service."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interact with update and recovery system"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Allows an application to interact with the recovery system and system updates."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Create media projection sessions"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Allows an application to create media projection sessions. These sessions can provide applications the ability to capture display and audio contents. Should never be needed by normal apps."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Manage media projection sessions"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Allows an application to manage media projection sessions. These sessions can provide applications with the ability to capture display and audio contents. Should never be needed by normal apps."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Read install sessions"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Allows an application to read install sessions. This allows it to see details about active package installations."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Touch twice for zoom control"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Deny"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permission requested"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permission requested\nfor account <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"You\'re using this app in your personal space"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"You\'re using this app in your work space"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"You\'re using this app outside of your work profile"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"You\'re using this app in your work profile"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Input Method"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sync"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibility"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Decrease hour"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Set p.m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Set a.m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"p.m."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"a.m."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Increase month"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Decrease month"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Increase day"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Data usage warning"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Touch to view usage and settings."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G data is off"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G data is off"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobile data is off"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi data is off"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limit reached"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G data limit reached"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G data limit reached"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobile data limit reached"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi data limit reached"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data paused for rest of cycle"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G data limit exceeded"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G data limit exceeded"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobile data limit exceeded"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Accept call?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Always"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Just once"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s doesn\'t support work profile."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s doesn\'t support work profile"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Phone"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Headphones"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Accessibility enabled."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibility cancelled."</string>
     <string name="user_switched" msgid="3768006783166984410">"Current user <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Switching to <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Owner"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"This change isn\'t allowed by your administrator"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> selected"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> deleted"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Work <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"To unpin this screen, touch and hold Back and Recents at the same time."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"To unpin this screen, touch and hold Recents."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Screen is pinned. Unpinning isn\'t allowed by your organisation."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Use screen pinning?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Screen pinning locks the display in a single view.\n\nTo exit, touch and hold Back and Recents at the same time."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Screen pinning locks the display in a single view.\n\nTo exit, touch and hold Recents."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, THANKS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"unlock pattern"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"password"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Screen pinned"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Screen unpinned"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Ask for PIN before unpinning"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Ask for unlock pattern before unpinning"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Ask for password before unpinning"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"To help improve battery life, battery saver reduces your device’s performance and limits vibration and most background data. Email, messaging and other apps that rely on syncing may not update unless you open them.\n\nBattery saver turns off automatically when your device is charging."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Until your downtime ends at <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"For one minute"</item>
+    <item quantity="other" msgid="6924190729213550991">"For %d minutes"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"For one hour"</item>
+    <item quantity="other" msgid="5408537517529822157">"For %d hours"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinitely"</string>
 </resources>
diff --git a/core/res/res/values-en-rIN/strings.xml b/core/res/res/values-en-rIN/strings.xml
index 3e2d93e..5a7dbcd 100644
--- a/core/res/res/values-en-rIN/strings.xml
+++ b/core/res/res/values-en-rIN/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Allows the holder to bind to the top-level interface of a remote display. Should never be needed for normal apps."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bind to a widget service"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Allows the holder to bind to the top-level interface of a widget service. Should never be needed for normal apps."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bind to a route provider service"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Allows the holder to bind to any registered route providers. Should never be needed for normal apps."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interact with device admin"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Allows the holder to send intents to a device administrator. Should never be needed for normal apps."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bind to a TV input"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"turn phone on or off"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Allows the app to turn the tablet on or off."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Allows the app to turn the phone on or off."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"reset display timeout"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Allows the app to reset the display timeout."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"run in factory test mode"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Run as a low-level manufacturer test, allowing complete access to the tablet hardware. Only available when a tablet is running in manufacturer test mode."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Run as a low-level manufacturer test, allowing complete access to the phone hardware. Only available when a phone is running in manufacturer test mode."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Allows the app to read and write the cache file system."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"make/receive SIP calls"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Allows the app to make and receive SIP calls."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interact with in-call screen"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Allows the app to control when and how the user sees the in-call screen."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interact with in-call screen"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Allows the app to control when and how the user sees the in-call screen."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interact with telephony services"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Allows the app to interact with telephony services to make/receive calls."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"provide an in-call user experience"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Allows the app to provide an in-call user experience."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"read historical network usage"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Allows the app to read historical network usage for specific networks and apps."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"manage network policy"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Allows the holder to bind to the top-level interface of a notification listener service. Should never be needed for normal apps."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bind to a condition provider service"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Allows the holder to bind to the top-level interface of a condition provider service. Should never be needed for normal apps."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bind to a media route service"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Allows the holder to bind to the top-level interface of a media route service. Should never be needed for normal apps."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bind to a dream service"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Allows the holder to bind to the top-level interface of a dream service. Should never be needed for normal apps."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invoke the carrier-provided configuration app"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Share with %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Select a home app"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Use by default for this action."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Use a different app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Clear default in System settings &gt; Apps &gt; Downloaded."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Choose an action"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Choose an app for the USB device"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Allow"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Deny"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; would like to send a message to &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"This "<font fgcolor="#ffffb060">"may cause charges"</font>" on your mobile account."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"This will cause charges on your mobile account."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"This "<b>"may cause charges"</b>" on your mobile account."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"This will cause charges on your mobile account."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Send"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancel"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Remember my choice"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Touch to disable USB debugging."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Change keyboard"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Choose keyboards"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Physical keyboard"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Show input method"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Select keyboard layout"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Touch to select a keyboard layout."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Allows an application to bind to a trust agent service."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interact with update and recovery system"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Allows an application to interact with the recovery system and system updates."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Create media projection sessions"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Allows an application to create media projection sessions. These sessions can provide applications the ability to capture display and audio contents. Should never be needed by normal apps."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Manage media projection sessions"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Allows an application to manage media projection sessions. These sessions can provide applications with the ability to capture display and audio contents. Should never be needed by normal apps."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Read install sessions"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Allows an application to read install sessions. This allows it to see details about active package installations."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Touch twice for zoom control"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Deny"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permission requested"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permission requested\nfor account <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"You\'re using this app in your personal space"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"You\'re using this app in your work space"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"You\'re using this app outside of your work profile"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"You\'re using this app in your work profile"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Input Method"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sync"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibility"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Decrease hour"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Set p.m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Set a.m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"p.m."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"a.m."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Increase month"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Decrease month"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Increase day"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Data usage warning"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Touch to view usage and settings."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G data is off"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G data is off"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobile data is off"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi data is off"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limit reached"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G data limit reached"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G data limit reached"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobile data limit reached"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi data limit reached"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data paused for rest of cycle"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G data limit exceeded"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G data limit exceeded"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobile data limit exceeded"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Accept call?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Always"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Just once"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s doesn\'t support work profile."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s doesn\'t support work profile"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Phone"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Headphones"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Accessibility enabled."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibility cancelled."</string>
     <string name="user_switched" msgid="3768006783166984410">"Current user <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Switching to <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Owner"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"This change isn\'t allowed by your administrator"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> selected"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> deleted"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Work <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"To unpin this screen, touch and hold Back and Recents at the same time."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"To unpin this screen, touch and hold Recents."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Screen is pinned. Unpinning isn\'t allowed by your organisation."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Use screen pinning?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Screen pinning locks the display in a single view.\n\nTo exit, touch and hold Back and Recents at the same time."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Screen pinning locks the display in a single view.\n\nTo exit, touch and hold Recents."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, THANKS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"unlock pattern"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"password"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Screen pinned"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Screen unpinned"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Ask for PIN before unpinning"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Ask for unlock pattern before unpinning"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Ask for password before unpinning"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"To help improve battery life, battery saver reduces your device’s performance and limits vibration and most background data. Email, messaging and other apps that rely on syncing may not update unless you open them.\n\nBattery saver turns off automatically when your device is charging."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Until your downtime ends at <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"For one minute"</item>
+    <item quantity="other" msgid="6924190729213550991">"For %d minutes"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"For one hour"</item>
+    <item quantity="other" msgid="5408537517529822157">"For %d hours"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinitely"</string>
 </resources>
diff --git a/core/res/res/values-es-rUS/strings.xml b/core/res/res/values-es-rUS/strings.xml
index d321412..571fbfd 100644
--- a/core/res/res/values-es-rUS/strings.xml
+++ b/core/res/res/values-es-rUS/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite al propietario vincularse a la interfaz de nivel superior de una pantalla remota. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vincular a un servicio de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite al propietario vincularse a la interfaz de nivel superior del servicio de widget. Las aplicaciones normales no deberían necesitar este permiso."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"vincular con un servicio de proveedor de rutas"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite al propietario vincular con proveedores de rutas registrados. No debe ser necesario para las aplicaciones normales."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interactuar con un administrador de dispositivos"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite enviar intentos a un administrador de dispositivos. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"vincular a una entrada de TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"apagar o encender el dispositivo"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite que la aplicación encienda o apague la tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite que la aplicación encienda o apague el dispositivo."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"restablecer el tiempo de espera de la pantalla"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite que la aplicación restablezca el tiempo de espera de la pantalla."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ejecutar en el modo de prueba de fábrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Se ejecuta como una prueba de fábrica de bajo nivel que permite un acceso completo al hardware del tablet. Sólo disponible cuando el tablet se ejecuta en el modo de prueba de fábrica."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Se ejecuta como una prueba de fábrica de bajo nivel que permite un acceso completo al hardware del dispositivo. Sólo disponible cuando un dispositivo se ejecuta en el modo de prueba de fábrica."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite que la aplicación lea y escriba el sistema de archivos almacenado en caché."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"realizar/recibir llamadas SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite que la aplicación realice y reciba llamadas SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interactuar con la pantalla de llamada"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite que la aplicación controle cuándo y cómo el usuario ve la pantalla de llamada."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interactuar con la pantalla de llamada"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite que la aplicación controle cuándo y cómo el usuario ve la pantalla de llamada."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interaccionar con servicios de telefonía"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite que la aplicación interaccione con servicios de telefonía para hacer y recibir llamadas."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ofrecer una experiencia de usuario de llamada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite que la aplicación proporcione una experiencia de usuario de llamada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"leer uso histórico de la red"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite que la aplicación lea el uso histórico de la red en redes y aplicaciones específicas."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gestionar la política de la red"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite al propietario vincularse a la interfaz de nivel superior de un servicio de agente de escucha de notificaciones. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"vincular con un servicio de proveedor de condiciones"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite vincular con la interfaz de nivel superior de un servicio de proveedor de condiciones. Las aplicaciones normales no deberían necesitar este permiso."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"vincular a un servicio de enrutamiento de contenido multimedia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite vincular con la interfaz de nivel superior de un servicio de enrutamiento de contenido multimedia. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"vincularse a un servicio de protector de pantalla interactivo"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite al propietario vincularse a la interfaz de nivel superior de un servicio de protector de pantalla interactivo. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ejecutar la aplicación de configuración proporcionada por el proveedor"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Compartir con %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Seleccionar una aplicación de la pantalla principal"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Utilizar de manera predeterminada en esta acción."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utilizar una aplicación diferente"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Eliminar valores predeterminados en Configuración del sistema &gt; Aplicaciones &gt; Descargas."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Seleccionar una acción"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Selecciona una aplicación para el dispositivo USB."</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permitir"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Rechazar"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; desea enviar un mensaje a &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Esto "<font fgcolor="#ffffb060">" puede causar que se apliquen cargos "</font>" en tu cuenta móvil."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Se aplicarán cargos en tu cuenta móvil."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"Es posible que se apliquen cargos"</b>" en la cuenta del dispositivo móvil."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Se aplicarán cargos en la cuenta del dispositivo móvil."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Enviar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancelar"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Recordar mi elección"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toca para desactivar la depuración por USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Cambiar el teclado"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Seleccionar teclados"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclado físico"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostrar método de entrada"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selecciona un diseño de teclado"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toca para seleccionar un diseño de teclado."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite que una aplicación se vincule con un servicio de agente de confianza."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interaccionar con el sistema de recuperación y las actualizaciones"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite que una aplicación interaccione con el sistema de recuperación y las actualizaciones del sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Crear sesiones de proyección de contenido multimedia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite a una aplicación crear sesiones de proyección de contenido multimedia. Estas sesiones pueden proporcionar a las aplicaciones la capacidad de capturar contenidos de pantalla y audio. Las aplicaciones normales no deberían necesitar este permiso."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Administrar sesiones de proyección de contenido multimedia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite a una aplicación administrar sesiones de proyección de contenido multimedia. Estas sesiones pueden brindar a las aplicaciones la posibilidad de capturar contenidos de pantalla y audio. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Leer sesiones de instalación"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite que una aplicación lea sesiones de instalación. Esto le permite ver detalles acerca de instalaciones de paquetes activas."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toca dos veces para acceder al control de zoom."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Denegar"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permiso solicitado"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permiso solicitado\npara la cuenta <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Estás usando esta aplicación en tu espacio personal."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Estás usando esta aplicación en tu espacio de trabajo."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Estás utilizando esta aplicación fuera del perfil de trabajo."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Estás utilizando esta aplicación en tu perfil de trabajo."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Método de entrada"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronización"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accesibilidad"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Reducir hora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Establecer p.m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Establecer a.m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"p. m."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"a. m."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumentar mes"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Reducir mes"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumentar día"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editar"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Advertencia de uso de datos"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toca para ver uso y config."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Datos 2G-3G desactivados"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Datos 4G desactivados"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Datos móviles desactivados"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Datos de red Wi-Fi desactivados"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Límite alcanzado"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Límite de datos 2G-3G alcanzado"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Límite de datos 4G alcanzado"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Límite datos móviles alcanzado"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Límite de datos Wi-Fi alcanzado"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Datos pausados resto del ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Supera límite de datos de 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Límite de datos de 4G superado"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Límite de datos móviles superado"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"¿Aceptar la llamada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Siempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Solo una vez"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s no admite perfiles de trabajo."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s no admite perfiles de trabajo."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Dispositivo"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Auriculares"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Se activó la accesibilidad."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Se canceló la accesibilidad."</string>
     <string name="user_switched" msgid="3768006783166984410">"Usuario actual: <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Cambiando a <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propietario"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"El administrador no permite este cambio."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> seleccionado"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> borrado"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> de trabajo"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Para dejar de fijar esta pantalla, mantén presionados los botones para volver y de aplicaciones recientes al mismo tiempo."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Para dejar de fijar esta pantalla, mantén presionado el botón de aplicaciones recientes."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"La pantalla está fija. La organización no permite dejar de fijar la pantalla."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"¿Utilizar función para fijar la pantalla?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Si fijas la pantalla, esta se bloqueará en una vista única.\n\nPara salir, mantén presionados los botones para volver y de aplicaciones recientes al mismo tiempo."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Si fijas la pantalla, esta se bloqueará en una vista única.\n\nPara salir, mantén presionado el botón de aplicaciones recientes."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, GRACIAS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"INICIAR"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"patrón de desbloqueo"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"contraseña"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Pantalla fija"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Pantalla no fija"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Solicitar PIN para quitar fijación"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Solicitar patrón de desbloqueo para quitar fijación"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Solicitar contraseña para quitar fijación"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Para ayudar a mejorar la duración de la batería, la función de ahorro de batería reduce el rendimiento del dispositivo y limita la vibración y la mayor parte de la transmisión de datos en segundo plano. Es posible que las aplicaciones que se sincronizan, como las de correo electrónico y mensajería, no se actualicen a menos que las abras.\n\nEl ahorro de batería se desactiva automáticamente cuando el dispositivo se está cargando."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Hasta que termine el tiempo de inactividad a la(s) <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Durante una hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
 </resources>
diff --git a/core/res/res/values-es/strings.xml b/core/res/res/values-es/strings.xml
index ccbb8d3..4a139b1 100644
--- a/core/res/res/values-es/strings.xml
+++ b/core/res/res/values-es/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite enlazar con la interfaz de nivel superior de una pantalla remota. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"enlazar con un servicio de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite enlazar con la interfaz de nivel superior de un servicio de widget. Las aplicaciones normales no deberían necesitar este permiso."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"enlazar con un servicio de proveedor de rutas"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite enlazar con proveedores de rutas registrados. No debe ser necesario para las aplicaciones normales."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interactuar con el administrador de un dispositivo"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite que se envíen intentos a un administrador de dispositivos. Las aplicaciones normales nunca deberían necesitar este permiso."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"enlazar a una entrada de TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"encender o apagar el teléfono"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite que la aplicación encienda o apague el tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite que la aplicación encienda o apague el teléfono."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"restablecer tiempo de espera de la pantalla"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite que la aplicación restablezca el tiempo de espera de la pantalla."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ejecutar en modo de prueba de fábrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Permite la ejecución como prueba de fabricante de nivel inferior, lo que posibilita un acceso completo al hardware del tablet. Solo está disponible cuando un tablet se está ejecutando en modo de prueba."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Ejecutar como prueba de fabricante de nivel inferior, permitiendo un acceso íntegro al hardware del teléfono. Solo está disponible cuando un teléfono se está ejecutando en modo de prueba."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite que la aplicación lea y escriba el sistema de archivos almacenado en caché."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"hacer/recibir llamadas SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite que la aplicación haga y reciba llamadas SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interactuar con la pantalla de llamada"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite que la aplicación controle cómo y cuándo aparece la pantalla de llamada."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interactuar con la pantalla de llamada"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite que la aplicación controle cómo y cuándo aparece la pantalla de llamada."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interactuar con servicios de telefonía"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite que la aplicación interactúe con servicios de telefonía para hacer y recibir llamadas."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ofrecer una experiencia de usuario de llamada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite que la aplicación proporcione una experiencia de usuario de llamada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"leer uso de red histórico"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite que la aplicación consulte el uso de red histórico de redes y de aplicaciones específicas."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"administrar política de red"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite enlazar con la interfaz de nivel superior de un servicio de detector de notificaciones. No debe ser necesario para las aplicaciones normales."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"enlazar con un servicio de proveedor de condiciones"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite enlazar con la interfaz de nivel superior de un servicio de proveedor de condiciones. Las aplicaciones normales no deberían necesitar este permiso."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"enlazar a un servicio de rutas multimedia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite enlazar con la interfaz de nivel superior de un servicio de rutas multimedia. No debe ser necesario para las aplicaciones normales."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"enlazar con un servicio de salvapantallas"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite enlazar con la interfaz de nivel superior de un servicio de salvapantallas. Las aplicaciones normales no deberían necesitar este permiso."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ejecutar la aplicación de configuración proporcionada por el operador"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Compartir con %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Seleccionar una aplicación en la pantalla de inicio"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Usar siempre para esta acción"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Uitliza otra aplicación"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Para borrar los valores predeterminados, accede a Ajustes del sistema &gt; Aplicaciones &gt; Descargadas."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Selecciona una acción"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Seleccionar una aplicación para el dispositivo USB"</string>
@@ -1256,7 +1255,7 @@
     <string name="volume_icon_description_incall" msgid="8890073218154543397">"Volumen de llamada"</string>
     <string name="volume_icon_description_media" msgid="4217311719665194215">"Volumen multimedia"</string>
     <string name="volume_icon_description_notification" msgid="7044986546477282274">"Volumen de notificaciones"</string>
-    <string name="ringtone_default" msgid="3789758980357696936">"Tono predeterminado"</string>
+    <string name="ringtone_default" msgid="3789758980357696936">"Tono por defecto"</string>
     <string name="ringtone_default_with_actual" msgid="8129563480895990372">"Tono predeterminado (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
     <string name="ringtone_silent" msgid="7937634392408977062">"Ninguno"</string>
     <string name="ringtone_picker_title" msgid="3515143939175119094">"Tonos"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permitir"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Denegar"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; quiere enviar un mensaje a &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Es posible que se apliquen cargos"</font>" en tu cuenta móvil."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Se aplicarán cargos en tu cuenta móvil."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"Es posible que se apliquen cargos"</b>" en tu cuenta móvil."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Se aplicarán cargos en tu cuenta móvil."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Enviar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancelar"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Recordar opción seleccionada"</string>
@@ -1351,8 +1350,8 @@
     <string name="adb_active_notification_title" msgid="6729044778949189918">"Depuración USB habilitada"</string>
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toca para inhabilitar la depuración USB"</string>
     <string name="select_input_method" msgid="8547250819326693584">"Cambiar teclado"</string>
-    <string name="configure_input_methods" msgid="4769971288371946846">"Seleccionar teclados"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclado físico"</string>
+    <string name="configure_input_methods" msgid="4769971288371946846">"Elegir teclados"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostrar método de entrada"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selecciona un diseño de teclado"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toca para seleccionar un diseño de teclado."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite a una aplicación enlazar con un servicio de agente de confianza."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interactuar con el sistema de recuperación y las actualizaciones"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite que una aplicación interactúe con el sistema de recuperación y las actualizaciones del sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Crear sesiones de proyección de contenido multimedia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite que una aplicación cree sesiones de proyección de contenido multimedia. Estas sesiones pueden ofrecer a las aplicaciones la posibilidad de capturar contenido de audio e imágenes. Este permiso no debe ser necesario para aplicaciones normales."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Administrar sesiones de proyección de contenido multimedia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite que una aplicación administre sesiones de proyección de contenido multimedia. Estas sesiones pueden ofrecer a las aplicaciones la posibilidad de capturar contenido de audio e imágenes. Este permiso no debe ser necesario para aplicaciones normales."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Consultar sesiones de instalación"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite que una aplicación consulte sesiones de instalación para ver detalles sobre instalaciones de paquetes activos."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toca dos veces para acceder al control de zoom."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Denegar"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permiso solicitado"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permiso solicitado\npara la cuenta <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Estás usando esta aplicación en tu espacio personal"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Estás usando esta aplicación en tu espacio de trabajo"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Estás usando esta aplicación fuera del perfil de trabajo"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Estás usando esta aplicación en tu perfil de trabajo"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Método de introducción de texto"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronización"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accesibilidad"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Reducir horas"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Establecer p.m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Establecer a.m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"pm"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"am"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumentar mes"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Reducir mes"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumentar días"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editar"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Advertencia de uso de datos"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toca para ver el uso y ajustes."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Datos 2G-3G desactivados"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Datos 4G desactivados"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Datos móviles desactivados"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Datos Wi-Fi desactivados"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Límite alcanzado"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Límite de datos 2G-3G alcanzado"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Límite de datos 4G alcanzado"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Límite datos móviles alcanzado"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Límite de datos Wi-Fi alcanzado"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Datos pausados resto del ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Límite de datos 2G-3G superado"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Límite de datos 4G superado"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Límite de datos móviles superado"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"¿Aceptar la llamada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Siempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Solo una vez"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s no es compatible con perfiles de trabajo."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s no admite perfiles de trabajo"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Teléfono"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Auriculares"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Accesibilidad habilitada"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accesibilidad cancelada"</string>
     <string name="user_switched" msgid="3768006783166984410">"Usuario actual: <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Cambiando a <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propietario"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"El administrador no permite este cambio"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> seleccionado"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> eliminado"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> de trabajo"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Para anular la fijación de esta pantalla, mantén pulsados los botones de volver y de aplicaciones recientes a la vez."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Para anular la fijación de esta pantalla, mantén pulsado el botón de aplicaciones recientes."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Se ha activado la pantalla. Tu organización no puede desactivarla."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"¿Quieres fijar esta pantalla?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Si fijas la pantalla se bloqueará en una vista única.\n\nPara salir, mantén pulsados los botones de volver y de aplicaciones recientes a la vez."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Si fijas la pantalla, se bloqueará en una vista única.\n\nPara salir, mantén pulsado el botón de aplicaciones recientes."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, GRACIAS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"INICIAR"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"patrón de desbloqueo"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"contraseña"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Pantalla fijada"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"La pantalla ya no está fija"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Solicitar PIN para desactivar"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Solicitar patrón de desbloqueo para desactivar"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Solicitar contraseña para desactivar"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Para ayudar a mejorar la duración de la batería, la función de ahorro de energía reduce el rendimiento del dispositivo y limita la vibración y la mayor parte de la transmisión de datos en segundo plano. Es posible que las aplicaciones que se sincronizan, como las de correo y mensajes, no se actualicen a menos que las abras.\n\nLa función de ahorro de energía se desactiva automáticamente cuando el dispositivo se carga."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Hasta que el tiempo de inactividad finalice el <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Durante 1 hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
 </resources>
diff --git a/core/res/res/values-et-rEE/strings.xml b/core/res/res/values-et-rEE/strings.xml
index a3820ee..95153ad 100644
--- a/core/res/res/values-et-rEE/strings.xml
+++ b/core/res/res/values-et-rEE/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Lubab omanikul siduda rakenduse kaugekraani ülataseme liidesega. Tavarakenduste puhul ei peaks seda kunagi vaja minema."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vidinateenusega sidumine"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Lubab omanikul siduda vidina teenuse ülataseme liidesega. Tavarakenduste puhul ei peaks seda kunagi vaja minema."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"sidumine marsruudi pakkumisteenusega"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Lubab õiguste omajal luua seosed kõikide registreeritud marsruutide pakkujatega. Pole kunagi vajalik tavaliste rakenduste korral."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"seadme administraatoriga suhtlemine"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Võimaldab omanikul saata kavatsusi seadme administraatorile. Tavarakenduste puhul ei peaks seda kunagi vaja minema."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"sidumine TV-sisendiga"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"lülita telefon sisse või välja"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Võimaldab rakendusel tahvelarvutit sisse või välja lülitada."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Võimaldab rakendusel telefoni sisse või välja lülitada."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ekraanikuva ajalõpu lähtestamine"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Lubab rakendusel lähtestada ekraanikuva ajalõpu."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"käivita tehase testrežiimis"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Käitage madalatasemelise tootjatestina, mis annab täieliku juurdepääsu tahvelarvuti riistvarale. Saadaval ainult siis, kui tahvelarvuti töötab tootjatesti režiimis."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Käivitage madalatasemelise tootjatestina, mis võimaldab täielikku juurdepääsu telefoni riistvarale. Kasutatav ainult juhul, kui telefon töötab tootja testrežiimis."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Võimaldab rakendusel vahemälu failisüsteemi lugeda ja kirjutada."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP-kõnede tegemine/vastuvõtmine"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Lubab rakendusel teha ja vastu võtta SIP-kõnesid."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ekraani Kõne pooleli kasutamine"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Lubab rakendusel juhtida, millal ja kuidas kasutajale kuvatakse ekraan Kõne pooleli."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ekraani Kõne pooleli kasutamine"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Lubab rakendusel juhtida, millal ja kuidas kasutajale kuvatakse ekraan Kõne pooleli."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"telefoniteenustega suhtlemine"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Võimaldab rakendusel telefoniteenustega kõnede tegemiseks ja vastuvõtmiseks suhelda."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"funktsiooni Kõne pooleli kasutuskogemuse pakkumine"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Lubab rakendusel pakkuda kasutuskogemust funktsiooni Kõne pooleli kasutamisel."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"võrgukasutuse ajaloo lugemine"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Võimaldab rakendusel lugeda võrgukasutuse ajalugu teatud võrkude ja rakenduste puhul."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"võrgueeskirjade haldamine"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Võimaldab omanikul siduda märguannete kuulamisteenuse ülemise taseme kasutajaliidese. Seda ei tohiks tavarakenduste puhul kunagi vaja olla."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"seo tingimuse pakkuja teenusega"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Lubab omanikul siduda tingimuse pakkuja teenuse ülataseme liidesega. Pole kunagi vajalik tavaliste rakenduste puhul."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"meediumi marsruutimise teenusega sidumine"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Lubab omanikul siduda meediumi marsruutimise teenuse ülataseme liidesega. Pole kunagi vajalik tavaliste rakenduste puhul."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"sidumine uneteenusega"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Lubab omanikul siduda uneteenuse ülataseme liidesega. Tavarakenduste puhul ei peaks seda kunagi vaja minema."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"operaatoripoolse konfiguratsioonirakenduse aktiveerimine"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Jagamine rakendusega %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Avalehe rakenduse valimine"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Kasuta vaikimisi selleks toiminguks."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Teise rakenduse kasutamine"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Tühjendage vaikeandmed valikutes Süsteemiseaded &gt; Rakendused &gt; Allalaaditud."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Toimingu valimine"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB-seadme jaoks rakenduse valimine"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Luba"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Keela"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; soovib saata sõnumi aadressile &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"See "<font fgcolor="#ffffb060">"võib põhjustada kulusid"</font>" teie mobiilikontole."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"See lisab kulusid teie mobiilikontole."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Sellega võivad teie mobiilikontol "<b>"kaasneda kulud"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Sellega kaasnevad teie mobiilikontol kulud."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Saada"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Tühista"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Jäta minu valik meelde"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Puudutage USB-silumise keelamiseks."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Klaviatuuri muutmine"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Vali klaviatuurid"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Füüsiline klaviatuur"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Sisestusmeetodi kuvamine"</string>
     <string name="hardware" msgid="7517821086888990278">"Riistvara"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Klaviatuuri paigutuse valimine"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Puudutage klaviatuuri paigutuse valimiseks."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Lubab rakendusel ennast siduda usaldusväärse agendi teenusega."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Suhtlemine värskenduse ja taastesüsteemiga"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Lubab rakendusel suhelda taastesüsteemi ja süsteemivärskendustega."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Meediumi projitseerimise seansi loomine"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Lubab rakendusel luua meediumi projitsiooni seanssi. Need seansid võivad annda rakendustele võimaluse hõivata kuva- ja helisisu. Ei ole kunagi vajalik tavaliste rakenduste puhul."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Meedia projektsiooniseansi haldamine"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Lubab rakendusel hallata meedia projektsiooniseansse. Need seansid võivad anda rakendusele võimaluse hõivata ekraanikuva ja heli sisu. Pole kunagi vajalik tavalise rakenduse puhul."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Installiseansside lugemine"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Lubab rakendusel lugeda installiseansse. See võimaldab näha aktiivse paketi installimise üksikasju."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Suumi juhtimiseks puudutage kaks korda"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Keela"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Taotletud luba"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Luba on taotletud\nkontole <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Kasutate seda rakendust oma isiklikus ruumis"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Kasutate seda rakendust oma tööruumis"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Kasutate rakendust väljaspool tööprofiili"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Kasutate seda rakendust oma tööprofiilil"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Sisestusmeetod"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sünkroonimine"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Juurdepääsetavus"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Tundide vähendamine"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM-i seadmine"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM-i seadmine"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Kuu suurendamine"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Kuu vähendamine"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Päeva suurendamine"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Muuda"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Andmete kasutamise hoiatus"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Kasutuse/sätete vaat. puudutage."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G–3G andmeside on väljalülitatud"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G andmeside on väljalülitatud"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mob. andmeside väljalülitatud"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"WiFi andmeside väljalülitatud"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limiit on täis"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-, 3G-andmeside limiit on täis"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G-andmeside limiit on täis"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobiilse andmes. limiit on täis"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"WiFi-andmeside limiit on täis"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Andmed on ülej. tsükliks peatat."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G andmemahupiirang ületatud"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G andmemahupiirang ületatud"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mob. andmeside limiit ületatud"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Kas vastata kõnele?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Alati"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Ainult üks kord"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ei toeta tööprofiili."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ei toeta tööprofiili"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tahvelarvuti"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Kõrvaklapid"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Hõlbustus on lubatud."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Hõlbustus on tühistatud."</string>
     <string name="user_switched" msgid="3768006783166984410">"Praegune kasutaja <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Üleminek kasutajale <xliff:g id="NAME">%1$s</xliff:g> ..."</string>
     <string name="owner_name" msgid="2716755460376028154">"Omanik"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Viga"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Administraator ei luba sellist muudatust teha"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> on valitud"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> on kustutatud"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Töö <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Ekraani vabastamiseks puudutage ja hoidke korraga all nuppe Tagasi ning Hiljutised."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Ekraani vabastamiseks puudutage ja hoidke all nuppu Hiljutised."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekraan on kinnitatud. Teie organisatsioon ei luba vabastamist."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Kas kasutada ekraani kinnitamist?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ekraani kinnitamine lukustab kuva ühele vaatele.\n\nVäljumiseks puudutage ja hoidke korraga all nuppe Tagasi ja Hiljutised."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ekraani kinnitamine lukustab kuva ühele vaatele.\n\nVäljumiseks puudutage ja hoidke all nuppu Hiljutised."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"TÄNAN, EI"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"KÄIVITA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-koodi"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"avamismustrit"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"parooli"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekraan on kinnitatud"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekraan on vabastatud"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Enne vabastamist küsi PIN-koodi"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Enne vabastamist küsi avamismustrit"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Enne vabastamist küsi parooli"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Aku kestuse parandamiseks vähendab akusäästja teie seadme jõudlust ja piirab vibratsiooni ning suuremat osa taustaandmetest. E-posti, sõnumsidet ja muid sünkroonimisele tuginevaid rakendusi võidakse värskendada ainult siis, kui te need avate.\n\nAkusäästja lülitatakse seadme laadimise ajal automaatselt välja."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Kuni seisakuaja lõppemiseni kell <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Üheks minutiks"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d minutiks"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Üheks tunniks"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d tunniks"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Määramata ajaks"</string>
 </resources>
diff --git a/core/res/res/values-eu-rES/strings.xml b/core/res/res/values-eu-rES/strings.xml
index a82f4a3..6844784 100644
--- a/core/res/res/values-eu-rES/strings.xml
+++ b/core/res/res/values-eu-rES/strings.xml
@@ -205,7 +205,7 @@
     <string name="permgroupdesc_location" msgid="5704679763124170100">"Zure kokapen fisikoa kontrolatzea."</string>
     <string name="permgrouplab_network" msgid="5808983377727109831">"Sare bidezko komunikazioa"</string>
     <string name="permgroupdesc_network" msgid="4478299413241861987">"Sareko hainbat eginbide atzitzea."</string>
-    <string name="permgrouplab_bluetoothNetwork" msgid="1585403544162128109">"Bluetootha"</string>
+    <string name="permgrouplab_bluetoothNetwork" msgid="1585403544162128109">"Bluetooth"</string>
     <string name="permgroupdesc_bluetoothNetwork" msgid="5625288577164282391">"Bluetooth bidez gailuak eta sareak atzitzea."</string>
     <string name="permgrouplab_audioSettings" msgid="8329261670151871235">"Audio-ezarpenak"</string>
     <string name="permgroupdesc_audioSettings" msgid="2641515403347568130">"Audio-ezarpenak aldatzea."</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Urruneko pantaila baten goi-mailako interfazera lotzeko aukera ematen dio titularrari. Aplikazio normalek ez dute baimen hau behar."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"lotu widget-zerbitzu batekin"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Widget-zerbitzu baten goi-mailako interfazeari lotzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"Lotu ibilbide-hornitzaileen zerbitzuei"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Erregistratutako ibilbide-hornitzaileei lotzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"aritu elkarlanean gailu baten administratzailearekin"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Gailu-administratzaileei xedeak bidaltzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"Lotu telebista-sarrerei"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"piztu edo itzali telefonoa"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Tableta piztea eta itzaltzea baimentzen die aplikazioei."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Telefonoa piztea eta itzaltzea baimentzen die aplikazioei."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"berrezarri bistaratzeko denbora-muga"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Bistaratzeko denbora-muga berrezartzea baimentzen die aplikazioei."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"exekutatu fabrikako proba moduan"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Exekutatu fabrikatzailearen behe-mailako proba gisa, tabletaren hardwarerako sarbide osoa izateko. Tableta fabrikatzailearen proba moduan exekutatzen denean baino ez dago erabilgarri."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Exekutatu fabrikatzailearen behe-mailako proba gisa, telefonoaren hardwarerako sarbide osoa izateko. Telefonoa fabrikatzailearen proba moduan exekutatzen denean baino ez dago erabilgarri."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Cachearen fitxategi-sistema irakurtzea eta bertan idaztea baimentzen die aplikazioei."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"Egin/Jaso SIP deiak"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP deiak egitea eta jasotzea baimentzen die aplikazioei."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"Interaktuatu deiaren pantailarekin"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Erabiltzaileak deiaren pantaila noiz eta nola ikusten duen kontrolatzeko aukera ematen die aplikazioei."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"Deiak abian direnean pantaila erabiltzea"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Erabiltzaileak deiaren pantaila noiz eta nola ikusten duen kontrolatzea baimentzen die aplikazioei."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"Elkarreragin telefono-zerbitzuekin"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Deiak egiteko eta jasotzeko telefonia-zerbitzuekin elkarreragitea baimentzen die aplikazioei."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"Deiak abian direnean erabiltzeko aukera eskaintzea"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Deiak abian direnean erabiltzeko aukera eskaintzea baimentzen die aplikazioei."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"irakurri sare-erabileraren historia"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Sare eta aplikazio jakin batzuen sare-erabileraren historia irakurtzea baimentzen die aplikazioei."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"kudeatu sare-gidalerroak"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Jakinarazpenak hautemateko zerbitzu baten goi-mailako interfazera lotzeko aukera ematen dio titularrari. Aplikazio normalek ez dute baimen hau behar."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"Lotu baldintza-hornitzaileen zerbitzuei"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Baldintza-hornitzaileen zerbitzuen goi-mailako interfazeari lotzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"lotetsi multimedia-irteerako zerbitzu bati"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Multimedia-irteerako zerbitzu baten goi-mailako interfazeari lotzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"lotu dream zerbitzuei"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Dream zerbitzu baten goi-mailako interfazeari lotzea baimentzen die titularrei. Aplikazio normalek ez lukete beharko."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"Deitu operadorearen konfigurazio-aplikazioari"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Partekatu %1$s aplikazioarekin"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Hautatu hasierako pantailako aplikazio bat"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Erabili modu lehenetsian ekintza honetarako."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Erabili beste aplikazio bat"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Garbitu aplikazio lehenetsia Sistemaren ezarpenak &gt; Aplikazioak &gt; Deskargatutakoak atalean."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Aukeratu ekintza bat"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Aukeratu USB gailurako aplikazioa"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Onartu"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Eragotzi"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; aplikazioak mezu bat bidali nahi du &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; helbidera."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Gastuak sor daitezke"</font>" mugikorreko kontuan."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Mugikorreko kontuan aldaketak egingo dira."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Baliteke horrek mugikorreko kontuan "<b>"gastuak eragitea"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Mugikorreko kontuan gastuak eragingo ditu horrek."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Bidali"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Utzi"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Gogoratu aukera"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB arazketa desgaitzeko, ukitu hau."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Aldatu teklatua"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Aukeratu teklatuak"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teklatu fisikoa"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Erakutsi idazketa-metodoa"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardwarea"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Hautatu teklatuaren diseinua"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Ukitu teklatuaren diseinua hautatzeko."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Fidagarritasun-agenteen zerbitzu bati lotzea baimentzen die aplikazioei."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interaktuatu eguneratze- eta eskuratze-sistemekin"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Eskuratze-sistemarekin nahiz sistema-eguneratzeekin interaktuatzeko aukera ematen die aplikazioei."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Sortu multimedia-edukia proiektatzeko saioak"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Multimedia-elementuak proiektatzeko saioak sortzea baimentzen die aplikazioei. Saio horiekin, aplikazioek pantailan bistaratutakoa eta audioa graba ditzakete. Aplikazio normalek ez lukete behar."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Multimedia-edukia proiektatzeko saioak kudeatzea"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Multimedia-edukia proiektatzeko saioak kudeatzea baimentzen die aplikazioei. Saio horiekin, pantailan ikusten dena eta audioa graba ditzakete aplikazioek. Aplikazio normalek ez lukete behar."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Irakurri instalazio-saioak"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Instalazio-saioak irakurtzea baimentzen die aplikazioei. Horrela, pakete-instalazio aktiboei buruzko xehetasunak ikus ditzakete."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Ukitu birritan zooma kontrolatzeko"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Ukatu"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Baimena eskatu da"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Baimena eskatu da \n<xliff:g id="ACCOUNT">%s</xliff:g> konturako."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Aplikazioa eremu pertsonalean erabiltzen ari zara"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Aplikazioa lan-eremuan erabiltzen ari zara"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Laneko profiletik kanpo ari zara aplikazioa erabiltzen"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Laneko profilean ari zara aplikazioa erabiltzen"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Idazketa-metodoa"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinkronizatuta"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Erabilerraztasuna"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Atzeratu ordu bat"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Ezarri PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Ezarri AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aurreratu hilabete"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Atzeratu hilabete"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aurreratu egun bat"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editatu"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Datuen erabilerari buruzko abisua"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Ukitu erabilera eta ezarpenak ikusteko."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G datu-konexioa desaktibatuta dago"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G datu-konexioa desaktibatuta dago"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Datu mugikorrak desaktibatuta daude"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi datuak desaktibatuta daude"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Mugara iritsi zara"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2-3 GB-ko mugara iritsi zara"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4 GB-ko mugara iritsi zara"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Datuen mugara iritsi zara"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi datuen mugara iritsi zara"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Datuen erab. etenda zikloa amaitu arte"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G datu-muga gainditu da"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G datu-muga gainditu da"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Datu mugikorren muga gainditu da"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Deia onartu nahi duzu?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Beti"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Behin soilik"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s abiarazleak ez du laneko profila onartzen."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s abiarazleak ez du laneko profil hau onartzen"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tableta"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefonoa"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Aurikularrak"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Erabilerraztasuna gaitu da."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Erabilerraztasuna bertan behera utzi da."</string>
     <string name="user_switched" msgid="3768006783166984410">"Uneko erabiltzailea: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> erabiltzailera aldatzen…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Jabea"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Errorea"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Zure administratzaileak ez du aldaketa egiteko baimena eman"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> hautatu da"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ezabatu da"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Laneko <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Pantailari aingura kentzeko, eduki ukituta Atzera eta Azkenak botoiak aldi berean."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Pantailari aingura kentzeko, eduki ukituta Azkenak botoia."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Pantaila ainguratu da. Erakundeak ez du aingura kentzea onartzen."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Pantaila ainguratzeko aukera erabili nahi duzu?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Pantaila-ainguratzeak ikuspegi bakarrean blokeatzen du pantaila.\n\nIrteteko, eduki ukituta Atzera eta Azkenak botoiak aldi berean."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Pantaila ainguratzeko aukerak ikuspegi bakarrean blokeatzen du pantaila.\n\nIrteteko, eduki ukituta Azkenak botoia."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"EZ, ESKERRIK ASKO"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"HASI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN kodea"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"desblokeatzeko eredua"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"pasahitza"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Pantaila ainguratu da"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Aingura kendu zaio pantailari"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Eskatu PIN kodea aingura kendu aurretik"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Eskatu desblokeatzeko eredua aingura kendu aurretik"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Eskatu pasahitza aingura kendu aurretik"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Bateriak gehiago iraun dezan, bateria aurrezteko aukerak gailuaren errendimendua murrizten du, eta dardara eta atzeko planoko datu gehienak mugatzen ditu. Baliteke posta elektronikoa, mezuak eta sinkronizatzen diren beste aplikazio batzuk ez eguneratzea, ireki ezean.\n\nBateria aurrezteko aukera automatikoki desaktibatzen da gailua kargatzen ari denean."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g> arte iraungo du jarduerarik gabeko aldiak"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Minutu batez"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d minutuz"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Ordubetez"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d orduz"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Mugagabea"</string>
 </resources>
diff --git a/core/res/res/values-fa/strings.xml b/core/res/res/values-fa/strings.xml
index bd725ae..448e072 100644
--- a/core/res/res/values-fa/strings.xml
+++ b/core/res/res/values-fa/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"به دارنده ام‍ک‍ان می‌دهد تا به رابط سطح بالای نمایشگر راه دور وصل شود. نباید هرگز برای برنامه‌های عادی لازم باشد."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"اتصال به یک سرویس ابزارک"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"به دارنده اجازه می‌دهد که به رابط سطح بالای سرویس ابزارک متصل شود. هرگز برای برنامه‌های معمولی مورد نیاز نیست."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"اتصال به یک سرویس ارائه‌دهنده مسیر"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"به دارنده امکان می‌دهد به هر ارائه‌دهنده مسیر ثبت شده‌ای متصل شود. هرگز برای برنامه‌های عادی مورد نیاز نیست."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"تعامل با یک سرپرست دستگاه"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"‏به دارنده اجازه می‎دهد اهداف خود را به سرپرست دستگاه ارسال کند. برنامه‎های معمولی هیچگاه به این ویژگی نیازی ندارند."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"اتصال به ورودی تلویزیون"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"روشن/خاموش کردن تلفن"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"‏به برنامه اجازه می‎دهد رایانهٔ لوحی را روشن یا خاموش کند."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"‏به برنامه اجازه می‎دهد گوشی را روشن یا خاموش کند."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"بازنشانی مهلت زمانی صفحه‌نمایش"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"به برنامه امکان می‌دهد مهلت زمانی صفحه‌نمایش را بازیابی کند."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"اجرا در حالت تست کارخانه"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"اجرا به‌عنوان تست سازنده سطح پایین، امکان دسترسی کامل به سخت‌افزار رایانهٔ لوحی شما را فراهم می‌آورد. فقط زمانی که رایانهٔ لوحی در حالت تست سازنده در حال اجراست قابل دسترسی است."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"اجرا به‌عنوان تست سازنده سطح پایین، امکان دسترسی کامل به سخت‌افزار تلفن شما را فراهم می‌آورد. فقط زمانی که تلفن در حالت تست سازنده در حال اجراست قابل دسترسی است."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"‏به برنامه اجازه می‎دهد تا سیستم فایل حافظهٔ پنهان را بخواند و بنویسد."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"‏تماس گرفتن/دریافت تماس از طریق SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"‏به برنامه اجازه می‌دهد تماس‌های SIP بگیرد یا دریافت کند."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"تعامل با صفحه‌نمایش هنگام تماس"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"به برنامه امکان می‌دهد کنترل کند که کاربر چه زمانی و چگونه صفحه‌نمایش هنگام تماس را مشاهده کند."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"تعامل با صفحه‌نمایش هنگام تماس"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"به برنامه امکان می‌دهد کنترل کند که کاربر چه زمانی و چگونه صفحه‌نمایش هنگام تماس را مشاهده کند."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"تعامل با سرویس‌های تلفنی"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"به برنامه اجازه می‌دهد جهت برقراری/دریافت تماس با سرویس‌های تلفنی تعامل داشته باشد."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ارائه یک تجربه کاربری هنگام تماس"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"به برنامه امکان می‌دهد تجربه کاربر در حال تماس را ارائه دهد."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"خواندن سابقه استفاده از شبکه"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"‏به برنامه اجازه می‎دهد تا کاربرد شبکه را در طول زمان برای برنامه‎ها و شبکه‎های خاص بخواند."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"مدیریت خط مشی شبکه"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"به دارنده اجازه می‌دهد به یک رابط سطح بالای سرویس شنونده اعلان متصل شود. هرگز نباید برای برنامه‌های عادی لازم شود."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"مقید بودن به سرویس ارائه‌دهنده وضعیت"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"به دارنده امکان می‌دهد تا به واسط سطح بالای سرویس ارائه‌دهنده وضعیت مقید باشد. برای برنامه‌های عادی هرگز نباید لازم باشد."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"اتصال به یک سرویس مسیر رسانه‌ای"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"به دارنده امکان می‌دهد به واسط کاربر سطح بالای سرویس مسیر رسانه‌ای متصل شود. هرگز نباید برای برنامه‌های عادی لازم شود."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"اتصال به سرویس مورد نظر"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"به برنامه اجازه می‌دهد که به رابط سطح بالای سرویس مورد نظر متصل شود. هرگز نباید برای برنامه‌های معمولی مورد نیاز باشد."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"لغو برنامه پیکربندی ارائه شده توسط شرکت مخابراتی"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"‏اشتراک‌گذاری با %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"انتخاب یک برنامه صفحه اصلی"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"استفاده به صورت پیش‌فرض برای این عملکرد."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"استتفاده از یک برنامه دیگر"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"‏پیش‌فرض را در تنظیمات سیستم&gt; برنامه‎ها&gt; مورد دانلود شده پاک کنید."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"انتخاب عملکرد"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"‏انتخاب برنامه برای دستگاه USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"اجازه دادن"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ردکردن"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"‏&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; مایل است پیامی به &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; ارسال کند."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"این کار "<font fgcolor="#ffffb060">"می‌تواند منجر به شارژ"</font>" حساب تلفن همراه شما شود."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"این کار حساب تلفن همراه شما را شارژ خواهد کرد."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"این مورد "<b>"شاید هزینه‌ای"</b>" را به حساب دستگاه همراهتان بگذارد."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"این مورد هزینه‌ای را به حساب دستگاه همراهتان می‌گذارد."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ارسال"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"لغو"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"این انتخاب را به خاطر بسپار"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"‏برای غیرفعال کردن اشکال زدایی USB لمس کنید."</string>
     <string name="select_input_method" msgid="8547250819326693584">"تغییر صفحه‌کلید"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"انتخاب صفحه‌کلیدها"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"صفحه‌کلید فیزیکی"</string>
+    <string name="show_ime" msgid="9157568568695230830">"نمایش روش ورودی"</string>
     <string name="hardware" msgid="7517821086888990278">"سخت‌افزار"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"انتخاب طرح‌بندی صفحه‌کلید"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"برای انتخاب یک طرح‌بندی صفحه‌کلید لمس کنید…"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"به یک برنامه کاربردی برای اتصال به یک سرویس نماینده معتمد اجازه می‌دهد."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"تعامل با سیستم به‌روزرسانی و بازیابی"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"به یک برنامه کاربردی اجازه می‌دهد با سیستم بازیابی و به‌روزرسانی‌های سیستم تعامل داشته باشد."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"ایجاد جلسات فرستادن رسانه"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"به برنامه اجازه می‌دهد جلسه‌های فرستادن رسانه ایجاد کند. این جلسات می‌توانند به برنامه این توانایی را بدهند که نمایشگر و محتوای صوتی را ضبط کند. هرگز نباید برای برنامه‌های عادی مورد نیاز باشد."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"مدیریت جلسات فرستادن محتوای رسانه‌ای"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"به برنامه اجازه می‌دهد جلسه‌های فرستادن محتوای رسانه‌ای را مدیریت کند. این جلسه‌ها می‌توانند به برنامه‌ها این توانایی را بدهند که نمایشگر و محتواهای صوتی را ضبط کنند. هرگز نباید برای برنامه‌های عادی مورد نیاز باشد."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"خواندن جلسات نصب"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"به برنامه اجازه می‌دهد جلسات نصب را بخواند. این کار به برنامه اجازه می‌دهد جزئیات نصب‌های بسته فعال را ببیند."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"دوبار لمس کنید تا بزرگنمایی کنترل شود"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"رد کردن"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"مجوز درخواست شد"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"مجوز\nبرای حساب <xliff:g id="ACCOUNT">%s</xliff:g> درخواست شد."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"از این برنامه در فضای شخصی‌تان استفاده می‌کنید"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"از این برنامه در فضای کاریتان استفاده می‌کنید"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"شما از این برنامه در خارج از نمایه کاری‌تان استفاده می‌کنید"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"از این برنامه در نمایه کاری‌تان استفاده می‌کنید"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"روش ورودی"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"همگام‌سازی"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"قابلیت دسترسی"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"کاهش ساعت"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"تنظیم ب.ظ"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"تنظیم ق.ظ"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ب‌ظ"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ق‌ظ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"افزایش ماه"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"کاهش ماه"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"افزایش روز"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ویرایش"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"هشدار میزان استفاده از داده"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"برای مشاهده کاربرد و تنظیمات لمس کنید."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"‏داده 2G-3G خاموش است"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"‏داده 4G خاموش است"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"داده شبکه سلولی خاموش است"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"‏داده Wi-Fi خاموش است"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"به حد مجاز رسیده‌اید"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"‏به حد مجاز مصرف داده 2G-3G رسید"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"‏به حد مجاز مصرف داده 4G رسید"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"به حد مجاز مصرف داده همراه رسید"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"‏به حد مجاز مصرف داده Wi-Fi رسید"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"داده برای مابقی دوره متوقف شد"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"‏اطلاعات 2G-3G بیش از حد مجاز است"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"‏بیش از حد مجاز 4G است"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"از حد مجاز شبکه سلولی فراتر رفتید"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"تماس را می‌پذیرید؟"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"همیشه"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"فقط این بار"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"‏%1$s نمایه کاری را پشتیبانی نمی‌کند."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"‏%1$s از نمایه کاری پشتیبانی نمی‌کند"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"رایانهٔ لوحی"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"تلفن"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"هدفون‌ها"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"قابلیت دسترسی فعال شد."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"قابلیت دسترسی لغو شد."</string>
     <string name="user_switched" msgid="3768006783166984410">"کاربر کنونی <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"در حالت تغییر به <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"دارنده"</string>
     <string name="error_message_title" msgid="4510373083082500195">"خطا"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"این تغییر از طرف سرپرستتان مجاز دانسته نشده است"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> انتخاب شد"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> حذف شد"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> محل کار"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
-    <string name="lock_to_app_negative" msgid="2259143719362732728">"نه، سپاسگزارم"</string>
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"برای برداشتن پین این صفحه، کلید بازگشت و برنامه‌های اخیر را همزمان لمس کنید و نگه دارید."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"برای برداشتن پین این صفحه، کلید برنامه‌های اخیر را لمس کنید و نگه دارید."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"صفحه پین شده است. سازمان شما برداشتن پین را غیرمجاز کرده است."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"از پین کردن صفحه استفاده شود؟"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"پین کردن صفحه، نمایشگر را در یک نمای واحد قفل می‌کند.\n\nبرای خروج، کلیدهای بازگشت و برنامه‌های اخیر را همزمان لمس کنید و نگه دارید."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"پین کردن صفحه، نمایشگر را در یک نمای واحد قفل می‌کند.\n\nبرای خروج، کلید برنامه‌های اخیر را لمس کنید و نگه دارید."</string>
+    <string name="lock_to_app_negative" msgid="2259143719362732728">"خیر، سپاسگزارم"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"شروع"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"پین"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"الگوی بازگشایی"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"گذرواژه"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"صفحه پین شد"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"پین صفحه برداشته شد"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"درخواست کد پین قبل از برداشتن پین"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"درخواست الگوی باز کردن قفل قبل از برداشتن پین"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"درخواست گذرواژه قبل از برداشتن پین"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"برای کمک به بهبود عمر باتری، ذخیره‌کننده باتری عملکرد دستگاه‌تان را کاهش می‌دهد و اغلب اطلاعات پس‌زمینه و لرزش را محدود می‌کند. ایمیل، پیام‌رسانی و سایر برنامه‌هایی که به همگام‌سازی وابسته هستند ممکن است به‌روز نشوند مگر اینکه آنها را باز کنید.\n\nوقتی دستگاه‌تان شارژ می‌شود، ذخیره‌کننده باتری به صورت خودکار خاموش می‌شود."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"تا زمانی که زمان استراحت در <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> به پایان برسد"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"برای یک دقیقه"</item>
+    <item quantity="other" msgid="6924190729213550991">"‏برای %d دقیقه"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"برای یک ساعت"</item>
+    <item quantity="other" msgid="5408537517529822157">"‏برای %d ساعت"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"نامحدود"</string>
 </resources>
diff --git a/core/res/res/values-fi/strings.xml b/core/res/res/values-fi/strings.xml
index 71e33e9..e726d7b 100644
--- a/core/res/res/values-fi/strings.xml
+++ b/core/res/res/values-fi/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Antaa sovelluksen sitoutua etänäytön ylemmän tason käyttöliittymään. Ei tavallisten sovelluksien käyttöön."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"sitoudu widget-palveluun"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Antaa sovelluksen sitoutua widget-palvelun ylemmän tason käyttöliittymään. Ei tavallisten sovelluksien käyttöön."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"reitin tarjoajan palveluun sitominen"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Antaa sovelluksen luoda sidoksen mihin tahansa rekisteröityyn reitin tarjoajaan. Ei tavallisten sovelluksien käyttöön."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"kommunikoi laitteen järjestelmänvalvojan kanssa"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Antaa sovelluksen lähettää aikomuksia laitteen järjestelmänvalvojalle. Ei tavallisten sovellusten käyttöön."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"sido TV-tuloon"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"sammutta tai käynnistä puhelin"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Antaa sovelluksen sammuttaa tai käynnistää tablet-laitteen."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Antaa sovelluksen sammuttaa ja käynnistää puhelimen."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"nollaa näytön aikakatkaisu"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Sallii sovelluksen nollata näytön aikakatkaisu."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"toimi tehdastestaustilassa"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Suorita matalan tason valmistajan testinä, jolloin koko tabletin laitteisto on käytössä. Käytettävissä vain, kun tabletia käytetään valmistajan testitilassa."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Suorita alemman tason valmistajan testinä ja anna täydet oikeudet puhelimen laitteistolle. Käytettävissä vain, kun puhelin on valmistajan testitilassa."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Antaa sovelluksen lukea välimuistin tiedostojärjestelmää ja kirjoittaa siihen."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"soita/vastaanota SIP-puheluja"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Sallii sovelluksen soittaa ja vastaanottaa SIP-puheluja."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interaktiivinen puhelunäyttö"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Sallii sovelluksen hallita, milloin ja miten käyttäjä näkee puhelunäytön."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"Vuorovaikutteinen puhelunäyttö"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Antaa sovelluksen määrätä, milloin ja millaisena käyttäjä näkee puhelunäytön."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"Puhelinpalveluiden yhteyslupa"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Sallii sovelluksen olla yhteydessä puhelinpalveluihin soittamista / puhelujen vastaanottamista varten."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"mahdollistavat puhelukokemuksen"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Antaa sovelluksen määrätä puhelukokemuksen."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"verkonkäyttöhistorian lukeminen"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Sallii sovelluksen lukea tiettyjen verkkojen ja sovellusten verkonkäyttöhistoriaa."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"verkkokäytännön hallinnointi"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Antaa sovelluksen sitoutua ilmoituskuuntelijan ylimmän tason käyttöliittymään. Ei tavallisten sovelluksien käyttöön."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"ehtojen toimituspalveluun sitominen"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Antaa sovelluksen luoda sidoksen ehtojen toimituspalvelun ylätason rajapintaan. Ei tavallisten sovelluksien käyttöön."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"median reitityspalveluun sitoutuminen"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Antaa sovelluksen sitoutua median reitityspalvelun ylätason liittymään. Ei tavallisten sovellusten käyttöön."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"sitoudu Unelma-palveluun"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Antaa sovelluksen sitoutua Unelma-palvelun ylemmän tason käyttöliittymään. Ei tavallisten sovelluksien käyttöön."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"Palveluntarjoajan määrityssovelluksen käynnistäminen"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Jaa sovelluksessa %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Valitse aloitusruutusovellus"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Käytä oletuksena tälle toiminnolle."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Käytä toista sovellusta"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Poista oletusasetus kohdassa Järjestelmäasetukset &gt; Sovellukset &gt; Ladattu."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Valitse toiminto"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Valitse USB-laitetta käyttävä sovellus"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Salli"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Kiellä"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; haluaa lähettää viestin osoitteeseen &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Tämä "<font fgcolor="#ffffb060">"voi aiheuttaa kuluja"</font>" matkapuhelinliittymälaskuusi."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Tämä aiheuttaa kuluja matkapuhelinliittymälaskuusi."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Tämä "<b>"voi aiheuttaa kuluja"</b>" matkapuhelinliittymälaskuusi."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Tämä aiheuttaa kuluja matkapuhelinliittymälaskuusi."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Lähetä"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Peruuta"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Muista valintani"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Poista USB-vianetsintä käytöstä koskettamalla tätä."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Vaihda näppäimistö"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Valitse näppäimistöt"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fyysinen näppäimistö"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Näytä syöttötapa"</string>
     <string name="hardware" msgid="7517821086888990278">"Laitteisto"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Valitse näppäimistöasettelu"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Kosketa ja valitse näppäimistöasettelu."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Antaa sovelluksen sitoutua luotettavaan tahoon."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Vuorovaikutus päivitys- ja palautusjärjestelmän kanssa"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Sallii sovelluksen vuorovaikutuksen palautusjärjestelmän ja järjestelmäpäivitysten kanssa."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Medialähetysistuntojen luominen"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Antaa sovelluksen luoda medialähetysistuntoja. Nämä istunnot antavat sovellusten tallentaa näyttö- ja äänisisältöä. Ei tavallisten sovellusten käyttöön."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Hallitse mediaistuntoja"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Antaa sovelluksen hallita mediaistuntoja. Istunnot voivat antaa sovelluksille mahdollisuuden tallentaa näytön sisällön ja ääntä. Tavalliset sovellukset eivät ehkä koskaan tarvitse sitä."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Lue asennusistuntoja"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Sallii sovelluksen lukea asennusistuntoja. Toiminto sallii sovelluksen lukea aktiivisten asennuspakettien tietoja."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Ohjaa zoomausta napauttamalla kahdesti"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Kiellä"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Lupa pyydetty"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Pyydetään lupaa\ntilille <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Käytät sovellusta henkilökohtaisessa tilassa"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Käytät sovellusta työtilassa"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Käytät sovellusta muulla kuin työprofiililla"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Käytät sovellusta työprofiililla"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Syöttötapa"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synkronointi"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Esteettömyys"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Vähennä tuntien määrää."</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Aseta ip"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Aseta ap"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"IP"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AP"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Lisää kuukausien määrää."</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Vähennä kuukausien määrää."</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Lisää päivien määrää."</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Muokkaa"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Tiedonsiirtovaroitus"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Näytä käyttö ja aset. koskettam."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G–3G-tiedonsiirto ei käytössä"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-tiedonsiirto ei käytössä"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobiilitiedonsiirto ei käytössä"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-tiedonsiirto ei käytössä"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Raja saavutettu"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G-tietojen raja saavutettu"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G-tietojen raja saavutettu"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Matkapuhelintietojen raja saavutettu"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi-tietojen raja saavutettu"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Tiedonsiirto keskeytetty jakson loppuun asti"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G-tiedonsiirtoraja ylitetty"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G-tiedonsiirtoraja ylitetty"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobiilitiedonsiirtoraja ylitetty"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vastataanko puheluun?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Aina"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Vain kerran"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ei tue työprofiileja."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ei tue työprofiilia"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet-laite"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Puhelin"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Kuulokkeet"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Esteettömyystila käytössä."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Esteettömyystila peruutettu."</string>
     <string name="user_switched" msgid="3768006783166984410">"Nykyinen käyttäjä: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Vaihdetaan käyttäjään <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Omistaja"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Virhe"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Järjestelmänvalvoja ei salli tätä muutosta"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> on valittu"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> poistettiin"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (työ)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Irrota näyttö koskettamalla ja painamalla samanaikaisesti Takaisin ja Äskettäiset."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Irrota näyttö koskettamalla ja painamalla Äskettäiset."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Näyttö on kiinnitetty. Irrottaminen ei ole sallittu organisaatiossasi."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Käytetäänkö näytön kiinnitystä?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Näytön kiinnitys lukitsee ruudun yhteen näkymään.\n\nPoistu koskettamalla ja painamalla samalla Takaisin ja Äskettäiset."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Näytön kiinnitys lukitsee ruudun yhteen näkymään.\n\nPoistu koskettamalla ja painamalla Äskettäiset."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"EI KIITOS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ALOITA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-koodi"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"lukituksenpoistokuvio"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"salasana"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Näyttö kiinnitetty"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Näyttö irrotettu"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pyydä PIN-koodi ennen irrotusta"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pyydä lukituksenpoistokuvio ennen irrotusta"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pyydä salasana ennen irrotusta"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Akunsäästötoiminto heikentää laitteen suorituskykyä ja rajoittaa värinää ja useimpia taustatietoja akun iän pidentämiseksi. Sähköposti, viestitys ja muut synkronointia edellyttävät sovellukset eivät ehkä päivity, ellet käynnistä niitä.\n\nAkunsäästö kytkeytyy automaattisesti pois laitteen akun latauksen ajaksi."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Käyttökatkos päättyy klo <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Minuutiksi"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d minuutiksi"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Tunniksi"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d tunniksi"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Toistaiseksi"</string>
 </resources>
diff --git a/core/res/res/values-fr-rCA/strings.xml b/core/res/res/values-fr-rCA/strings.xml
index 4a63f0e..e49f7bc 100644
--- a/core/res/res/values-fr-rCA/strings.xml
+++ b/core/res/res/values-fr-rCA/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permet à l\'application autorisée de s\'associer à l\'interface de plus haut niveau d\'un écran distant. Les applications standards ne doivent jamais avoir recours à cette fonctionnalité."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"s\'associer à un service de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permet à l\'application autorisée de s\'associer à l\'interface de plus haut niveau d\'un service de widget. Les applications standards ne doivent jamais avoir recours à cette fonctionnalité."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"associer à un fournisseur d\'itinéraires enregistré"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permet à l\'application autorisée de s\'associer à des fournisseurs d\'itinéraires enregistrés. Cette fonctionnalité ne devrait pas être nécessaire pour les applications standards."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interagir avec l\'administrateur d\'un périphérique"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permet à l\'application autorisée d\'envoyer des intentions à l\'administrateur de l\'appareil. Les applications standards ne doivent jamais avoir recours à cette fonctionnalité."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"s\'associer à une entrée de téléviseur"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"éteindre ou allumer le téléphone"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permet à l\'application d\'éteindre et d\'allumer la tablette."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permet à l\'application d\'éteindre et d\'allumer le téléphone."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"réinitialiser le délai d\'affichage"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permet à l\'application de réinitialiser le délai d\'affichage."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"exécuter en mode test d\'usine"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Permet d\'exécuter une application en mode test fabricant de faible niveau, autorisant ainsi l\'accès complet à la tablette. Cette fonctionnalité est uniquement disponible lorsque la tablette est en mode test fabricant."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Permet d\'exécuter en tant que test fabricant de faible niveau en autorisant l\'accès au matériel du téléphone. Cette fonctionnalité est uniquement disponible lorsque le téléphone est en mode de test fabricant."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permet à l\'application d\'obtenir des droits en lecture et en écriture pour le système de fichiers du cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"faire et recevoir des appels SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Autorise l\'application à effectuer et à recevoir des appels SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interagir avec l\'écran d\'appel"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permet à l\'application de contrôler quand et comment l\'écran d\'appel s\'affiche."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interagir avec l\'écran d\'appel"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permet à l\'application de contrôler quand et comment l\'écran d\'appel s\'affiche."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interagir avec les services de téléphonie"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permet à l\'application d\'interagir avec les services de téléphonie afin de faire et de recevoir des appels."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"fournir une expérience utilisateur pendant l\'appel"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permet à l\'application de fournir une expérience utilisateur pendant l\'appel."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lire l\'historique d\'utilisation de réseaux"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permet à l\'application de lire l\'historique d\'utilisation de réseaux et d\'applications particuliers."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gérer les politiques du réseau"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service d\'écoute des notifications. Ne devrait jamais être nécessaire pour les applications normales."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"s\'associer à un service de fournisseur de conditions"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service de fournisseur de conditions. Ne devrait pas être nécessaire pour les applications standards."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"s\'associer à un service d\'itinéraires multimédias"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service d\'itinéraires multimédias. Ne devrait pas être nécessaire pour les applications standards."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"associer à un service de rêve"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permet à l\'application autorisée de s\'associer à l\'interface de plus haut niveau d\'un service de rêve. Les applications standard ne devraient pas avoir recours à cette fonctionnalité."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"faire appel à l\'application de configuration du fournisseur de services"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Partager avec %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Sélectionnez une application de l\'écran d\'accueil"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Utiliser cette application par défaut pour cette action"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utiliser une application différente"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Pour supprimer les valeurs par défaut, accédez à Paramètres système &gt; Applications &gt; Téléchargements."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Sélectionnez une action"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Sélectionnez une application pour le périphérique de stockage USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Autoriser"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Refuser"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; souhaite envoyer un message à &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ceci "<font fgcolor="#ffffb060">"peut entraîner des frais"</font>" sur votre compte mobile."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ceci entraînera des frais sur votre compte mobile."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ceci "<b>"peut entraîner des frais"</b>" sur votre compte."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Cela entraînera des frais sur votre compte."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Envoyer"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Annuler"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Mémoriser mon choix"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Appuyez pour désactiver le débogage USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Changer de clavier"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Choisir les claviers"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Clavier physique"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Afficher le mode d\'entrée"</string>
     <string name="hardware" msgid="7517821086888990278">"Matériel"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Sélectionnez la disposition du clavier"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Appuyez ici pour sélectionner une disposition de clavier."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permet à une application de se lier à un service d\'agent de confiance."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interagir avec le système de récupération et de mise à jour"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permet à une application d\'interagir avec le système de récupération et les mises à jour système."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Créer des sessions de projection multimédia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permet à une application de créer des sessions de projection multimédia. Ces sessions peuvent fournir aux applications la capacité d\'enregistrer et de présenter du contenu audio. Cela ne devrait jamais être nécessaire pour les applications normales."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gérer des séances de projection de contenus multimédias"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permet à une application de gérer des séances de projection de contenus multimédias. Au cours de ces séances, les applications peuvent capturer des contenus audio ou affichés à l\'écran. Ne doit jamais être utilisé par des applications standards."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Accéder aux sessions d\'installation"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permet à une application d\'accéder aux sessions d\'installation. Cela lui permet de consulter les détails relatifs à l\'installation des paquets actifs."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Appuyer deux fois pour régler le zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Refuser"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Autorisation demandée"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Autorisation demandée\npour le compte \"<xliff:g id="ACCOUNT">%s</xliff:g>\""</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Vous utilisez cette application dans votre espace personnel"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Vous utilisez cette application dans votre espace de travail"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Vous utilisez cette application en dehors de votre profil professionnel"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Vous utilisez cette application dans votre profil professionnel"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Mode de saisie"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchroniser"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibilité"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Heure précédente"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Définir la valeur PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Définir la valeur AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Mois suivant"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Mois précédent"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Jour suivant"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Modifier"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Avertissement utilisation données"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Appuyez pour conso/paramètres"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Données 2G/3G désactivées"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Données 4G désactivées"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Données cellulaire désactivées"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Données Wi-Fi désactivées"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limite atteinte"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Limite de données 2G-3G atteinte"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Limite de données 4G atteinte"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Limite donn. cellulaires atteinte"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Limite données Wi-Fi atteinte"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Données suspend. pour reste cycle"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Quota de données 2G-3G dépassé"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Quota de données 4G dépassé"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limite données cell. dépassée"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Prendre l\'appel?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Toujours"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Une seule fois"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s n\'est pas compatible avec le profil professionnel."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ne prend pas en charge le profil professionnel"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablette"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Téléphone"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Oreillettes"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"L\'accessibilité a bien été activée."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibilité annulée."</string>
     <string name="user_switched" msgid="3768006783166984410">"Utilisateur actuel : <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Changement d\'utilisateur (<xliff:g id="NAME">%1$s</xliff:g>) en cours…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propriétaire"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Erreur"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Cette modification n\'est pas autorisée par votre administrateur"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"« <xliff:g id="ITEM">%1$s</xliff:g> » a été sélectionné"</string>
     <string name="deleted_key" msgid="7659477886625566590">"« <xliff:g id="KEY">%1$s</xliff:g> » a été supprimé"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (travail)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Pour annuler l\'épinglage de cet écran, maintenez le doigt sur Retour et Récents simultanément."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Pour annuler l\'épinglage de cet écran, maintenez le doigt sur Récents."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"L\'écran est épinglé. Votre organisation n\'autorise pas l\'annulation d\'épinglage."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Utiliser l\'épinglage d\'écran?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"L\'épinglage de l\'écran permet de verrouiller l\'écran dans un affichage unique.\n\nPour quitter cet affichage, maintenez le doigt sur Retour et Récents simultanément."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Le verrouillage d\'écran verrouille l\'écran dans un mode d\'affichage unique.\n\nPour quitter ce mode, maintenez le doigt sur Récents."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NON, MERCI"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"COMMENCER"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"NIP"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"schéma de déverrouillage"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"mot de passe"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Écran épinglé"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Épinglage d\'écran annulé"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Demander le NIP avant d\'annuler l\'épinglage"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Demander le schéma de déverrouillage avant d\'annuler l\'épinglage"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Demander le mot de passe avant d\'annuler l\'épinglage"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Pour optimiser l\'autonomie de la pile, l\'économiseur d\'énergie réduit les performances de votre appareil et limite les données en arrière-plan. Vous devrez peut-être ouvrir manuellement les applications de courriel, de messagerie et les autres applications synchronisées pour les mettre à jour.\n\nL\'économiseur d\'énergie se désactive automatiquement lorsque votre appareil est en charge."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Jusqu\'à ce que le temps d\'arrêt se termine à <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Pendant une minute"</item>
+    <item quantity="other" msgid="6924190729213550991">"Pendant %d minutes"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Pendant une heure"</item>
+    <item quantity="other" msgid="5408537517529822157">"Pendant %d heures"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indéfiniment"</string>
 </resources>
diff --git a/core/res/res/values-fr/strings.xml b/core/res/res/values-fr/strings.xml
index d300946..0bf1b93 100644
--- a/core/res/res/values-fr/strings.xml
+++ b/core/res/res/values-fr/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permettre à l\'application autorisée de s\'associer à l\'interface de niveau supérieur d\'un écran à distance. Cette fonctionnalité ne devrait pas être nécessaire pour les applications standards."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"associer à un service widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permet à l\'application autorisée de s\'associer à l\'interface de plus haut niveau d\'un service widget. Les applications standards ne doivent jamais avoir recours à cette fonctionnalité."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"s\'associer à un fournisseur d\'itinéraires"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permettre à l\'application autorisée de s\'associer à n\'importe quel fournisseur d\'itinéraires. Ne devrait pas être nécessaire pour les applications standards."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interagir avec l\'administrateur du périphérique"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permet à l\'application autorisée d\'envoyer des intentions à l\'administrateur de l\'appareil. Les applications standards ne doivent jamais avoir recours à cette fonctionnalité."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"s\'associer à une entrée TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"Éteindre ou allumer le téléphone"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permet à l\'application d\'éteindre et d\'allumer la tablette."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permet à l\'application d\'éteindre et d\'allumer le téléphone."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"réinitialiser le délai d\'affichage"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permet à l\'application de réinitialiser le délai d\'affichage."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"Exécution en mode Test d\'usine"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Permet d\'exécuter une application en mode test fabricant de faible niveau, autorisant ainsi l\'accès complet à la tablette. Cette fonctionnalité est uniquement disponible lorsque la tablette est en mode test fabricant."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Permet d\'exécuter une application en mode test fabricant de faible niveau en autorisant ainsi l\'accès au téléphone. Cette fonctionnalité est uniquement disponible lorsque le téléphone est en mode test fabricant."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permet à l\'application d\'obtenir des droits en lecture/écriture concernant le système de fichiers du cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"effectuer/recevoir des appels SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Autorise l\'application à effectuer et à recevoir des appels SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"contrôler l\'écran d\'appel"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permet à l\'application de contrôler quand et comment l\'écran d\'appel s\'affiche."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"contrôler l\'écran d\'appel"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permet à l\'application de contrôler quand et comment l\'écran d\'appel s\'affiche."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interagir avec des services de téléphonie"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permet à l\'application d\'interagir avec des services de téléphonie pour effectuer et recevoir des appels."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"fournir une expérience utilisateur pendant l\'appel"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permet à l\'application de fournir une expérience utilisateur pendant l\'appel."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lire l\'historique d\'utilisation du réseau"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permet à l\'application de lire l\'historique d\'utilisation de réseaux et d\'applications spécifiques."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gérer les règles du réseau"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service d\'écoute des notifications. Ne devrait jamais être nécessaire pour les applications normales."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"s\'associer à un service de fournisseur de conditions"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service de fournisseur de conditions. Ne devrait pas être nécessaire pour les applications standards."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"s\'associer à un service d\'itinéraires médias"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permet à l\'application de s\'associer à l\'interface de niveau supérieur d\'un service d\'itinéraires médias. Ne devrait pas être nécessaire pour les applications standards."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"associer à un service d\'écran de veille interactif"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permet à l\'application autorisée de s\'associer à l\'interface de plus haut niveau d\'un service d\'écran de veille interactif. Cette autorisation ne devrait jamais être nécessaire pour les applications standards."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"faire appel à l\'application de configuration fournie par l\'opérateur"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Partager avec %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Sélectionner une application de l\'écran d\'accueil"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Utiliser cette application par défaut pour cette action"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utiliser une autre application"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Pour supprimer les valeurs par défaut, accédez à Paramètres système &gt; Applications &gt; Téléchargements."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Sélectionnez une action"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Sélectionnez une application pour le périphérique de stockage USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Autoriser"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Refuser"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; souhaite envoyer un message à &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ceci "<font fgcolor="#ffffb060">"peut entraîner des frais"</font>" sur votre compte mobile."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ceci entraînera des frais sur votre compte mobile."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ceci "<b>"peut entraîner des frais"</b>" sur votre compte de téléphonie mobile."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ceci entraînera des frais sur votre compte de téléphonie mobile."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Envoyer"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Annuler"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Mémoriser mon choix"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Appuyez pour désactiver le débogage USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Changer de clavier"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Sélectionner des claviers"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Clavier physique"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Afficher mode de saisie"</string>
     <string name="hardware" msgid="7517821086888990278">"Matériel"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Sélectionnez la disposition du clavier"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Appuyez ici pour sélectionner une disposition de clavier."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permettre à une application de s\'associer à un service d\'agent de confiance."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interagir avec le système de récupération et de mise à jour"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permet à une application d\'interagir avec le système de récupération et les mises à jour du système."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Créer des séances de projection de contenus multimédias"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permet à une application de créer des séances de projection de contenus multimédias. Au cours de ces séances, les applications peuvent capturer des contenus audio ou affichés à l\'écran. Ne doit jamais être utilisé par des applications standards."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gérer des séances de projection de contenus multimédias"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permet à une application de gérer des séances de projection de contenus multimédias. Au cours de ces séances, les applications peuvent capturer des contenus audio ou affichés à l\'écran. Ne doit jamais être utilisé par des applications standards."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Accéder aux sessions d\'installation"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permet à une application d\'accéder aux sessions d\'installation. Cela lui permet de consulter les détails relatifs à l\'installation des packages actifs."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Appuyez deux fois pour régler le zoom."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Refuser"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Autorisation demandée"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Autorisation demandée\npour le compte \"<xliff:g id="ACCOUNT">%s</xliff:g>\""</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Vous utilisez cette application dans votre espace personnel."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Vous utilisez cette application dans votre espace de travail."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Vous utilisez cette application en dehors de votre profil professionnel."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Vous utilisez cette application dans votre profil professionnel."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Mode de saisie"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchronisation"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibilité"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Heure précédente"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Définir la valeur PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Définir la valeur AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"p.m."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"a.m."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Mois suivant"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Mois précédent"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Jour suivant"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Modifier"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Avertissement utilisation données"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Appuyez pour conso/paramètres"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Données 2G-3G désactivées"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Données 4G désactivées"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Données mobiles désactivées"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Données Wi-Fi désactivées"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limite atteinte"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Limite de données 2G-3G atteinte"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Limite de données 4G atteinte"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Limite données mobiles atteinte"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Limite données Wi-Fi atteinte"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Données suspend. pour reste cycle"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Quota de données 2G-3G dépassé"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Quota de données 4G dépassé"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limite de données mobiles dépassée"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Prendre l\'appel ?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Toujours"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Une seule fois"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s n\'est pas compatible avec le profil professionnel."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s n\'est pas compatible avec le profil professionnel."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablette"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Téléphone"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Écouteurs"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"L\'accessibilité a bien été activée."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibilité annulée."</string>
     <string name="user_switched" msgid="3768006783166984410">"Utilisateur actuel : <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Passage à (<xliff:g id="NAME">%1$s</xliff:g>) en cours…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propriétaire"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Erreur"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Votre administrateur n\'autorise pas cette modification."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"\"<xliff:g id="ITEM">%1$s</xliff:g>\" sélectionné"</string>
     <string name="deleted_key" msgid="7659477886625566590">"\"<xliff:g id="KEY">%1$s</xliff:g>\" supprimé"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (travail)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Pour annuler l\'épinglage de cet écran, appuyez simultanément et de façon prolongée sur \"Retour\" et \"Écrans récents\"."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Pour annuler l\'épinglage de cet écran, appuyez de façon prolongée sur \"Écrans récents\"."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"L\'écran est épinglé. L\'annulation de l\'épinglage n\'est pas autorisée par votre organisation."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Utiliser l\'épinglage d\'écran ?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"L\'épinglage d\'écran permet de verrouiller l\'écran dans une vue unique.\n\nPour quitter cette vue, appuyez simultanément et de façon prolongée sur \"Retour\" et \"Écrans récents\"."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"L\'épinglage d\'écran permet de verrouiller l\'écran dans une vue unique.\n\nPour quitter cette vue, appuyez de façon prolongée sur \"Écrans récents\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NON, MERCI"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ACTIVER"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"code PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"schéma de déverrouillage"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"mot de passe"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Écran épinglé."</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Épinglage d\'écran annulé."</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Demander le code PIN avant d\'annuler l\'épinglage"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Demander le schéma de déverrouillage avant d\'annuler l\'épinglage"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Demander le mot de passe avant d\'annuler l\'épinglage"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Pour optimiser l\'autonomie de la batterie, l\'économiseur de batterie réduit les performances de votre appareil et limite les données en arrière-plan. Vous devrez peut-être ouvrir manuellement les applications d\'e-mail, de SMS/MMS et les autres applications synchronisées pour les mettre à jour.\n\nL\'économiseur de batterie s\'éteint automatiquement lorsque votre appareil est en charge."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Jusqu\'à ce que le temps d\'arrêt se termine à <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Pendant une minute"</item>
+    <item quantity="other" msgid="6924190729213550991">"Pendant %d minutes"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Pendant une heure"</item>
+    <item quantity="other" msgid="5408537517529822157">"Pendant %d heures"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indéfiniment"</string>
 </resources>
diff --git a/core/res/res/values-gl-rES/strings.xml b/core/res/res/values-gl-rES/strings.xml
index 622d3d0..07ddb67 100644
--- a/core/res/res/values-gl-rES/strings.xml
+++ b/core/res/res/values-gl-rES/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite ao propietario vincularse á interface de nivel superior dunha pantalla remota. Non debería ser nunca necesario para as aplicacións normais."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vincular a un servizo de widgets"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite ao propietario vincularse á interface de nivel superior dun servizo de widget. As aplicacións normais non deberían necesitar este permiso."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"vincular a un servizo de provedor de rutas"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite ao propietario vincularse a calquera provedor de ruta rexistrado. As aplicacións normais non deberían necesitar este permiso."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interactuar cun administrador de dispositivos"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite ao propietario enviar intentos a un administrador de dispositivos. As aplicacións normais non deberían necesitar este permiso."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"vincular a unha entrada de televisión"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"acender ou apagar o teléfono"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite á aplicación acender ou apagar o tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite á aplicación acender ou apagar o teléfono."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"restablecer tempo de espera da pantalla"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite que a aplicación restableza o tempo de espera da pantalla."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"executarse en modo de proba de fábrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Executar como unha proba de baixo nivel do fabricante, permitindo un acceso completo ao hardware do tablet. Só está dispoñible cando o tablet está funcionando en modo de proba do fabricante."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Executar como unha proba de baixo nivel do fabricante, o cal permite un acceso completo ao hardware do teléfono. Só está dispoñible cando o teléfono está funcionando no modo de proba do fabricante."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite á aplicación ler e escribir no sistema de ficheiros da caché."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"facer/recibir chamadas SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite que a aplicación faga e reciba chamadas SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interactuar cunha pantalla de chamada"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite á aplicación controlar cando e como ve o usuario a pantalla de chamada."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interactuar cunha pantalla de chamada"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite á aplicación controlar cando e como ve o usuario a pantalla de chamada."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interactuar cos servizos de telefonía"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite que a aplicación interactúe cos servizos de telefonía para facer ou recibir chamadas."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"proporcionar unha experiencia de usuario durante a chamada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite á aplicación proporcionar unha experiencia de usuario durante a chamada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ler o historial de uso da rede"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite á aplicación ler o uso da rede histórico de redes e aplicacións específicas."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"xestionar a política de rede"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite ao propietario vincularse á interface de nivel superior dun servizo axente de escoita de notificacións.  Non debería ser nunca necesario para as aplicacións normais."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"vincular a un servizo de provedor de condicións"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite ao propietario vincularse á interface de nivel superior dun servizo provedor de condicións. As aplicacións normais non deberían necesitar este permiso."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"vincular a un servizo de ruta de medios"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite ao propietario vincularse á interface de nivel superior dun servizo de ruta de medio. As aplicacións normais non deberían necesitar este permiso."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"vincular a un servizo de soños"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite ao propietario vincularse á interface de nivel superior dun servizo de soños. As aplicacións normais non deberían necesitar este permiso."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invocar a aplicación de configuración fornecida polo operador"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Compartir con %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Selecciona unha aplicación de inicio"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Usar de forma predeterminada para esta acción."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utilizar unha aplicación diferente"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Borra a configuración predeterminada en Configuración do sistema &gt; Aplicacións &gt; Descargadas."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Escoller unha acción"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Selecciona unha aplicación para o dispositivo USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permitir"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Rexeitar"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; quere enviar unha mensaxe a &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Esta acción "<font fgcolor="#ffffb060">"pode implicar custos"</font>" na túa conta de teléfono móbil."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Esta acción provocará a aplicación de custos na túa conta de teléfono móbil."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Esta acción "<b>"pode supoñer custos"</b>" na túa conta de teléfono móbil."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Esta acción suporá custos na túa conta de teléfono móbil."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Enviar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancelar"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Lembrar a miña opción"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toca para desactivar a depuración de erros de USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Cambiar teclado"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Seleccionar teclados"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclado físico"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostra método de entrada"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Seleccionar deseño de teclado"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toca para seleccionar un deseño de teclado."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite a unha aplicación vincularse cun servizo de axente de confianza."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interactuar co sistema de actualización e recuperación"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite a unha aplicación interactuar co sistema de recuperación e as actualizacións do sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Crear sesións de proxeccións multimedia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite que unha aplicación cree sesións de proxeccións multimedia. Estas sesións poden proporcionarlles ás aplicacións a capacidade de capturar a pantalla e contidos de audio. Nunca debería ser necesario para as aplicacións normais."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Xestionar sesións de proxeccións multimedia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite a unha aplicación xestionar sesións de proxeccións multimedia. Estas sesións poden proporcionar ás aplicacións a capacidade de capturar a pantalla e contidos de audio. Nunca debe ser necesario para as aplicacións normais."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Consultar sesións de instalación"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite que unha aplicación consulte as sesións de instalación. Desta forma, pode ver os detalles acerca das instalacións de paquetes activas."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toca dúas veces para controlar o zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Rexeitar"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permiso solicitado"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permiso solicitado\npara a conta <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Estás usando esta aplicación no teu espazo persoal"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Estás usando esta aplicación no teu espazo de traballo"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Estás usando esta aplicación fóra do teu perfil de traballo"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Estás usando esta aplicación no teu perfil de traballo"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Método de entrada"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronizar"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accesibilidade"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Reducir a hora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Establecer PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Establecer AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumentar mes"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Reducir mes"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumentar día"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editar"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Aviso de uso de datos"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toca para uso e configuración"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Datos 2G-3G desactivados"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Os datos 4G están desactivados"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Datos móbiles desactivados"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Os datos wifi están desactivados"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Límite alcanzado"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Límite de datos de 2G-3G acadado"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Límite de datos de 4G acadado"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Límite de datos móbiles acadado"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Límite de datos da wifi acadado"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Datos pausados para o ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Límite de datos 2G-3G superado"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Límite de datos 4G superado"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Límite de datos móbiles superado"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Aceptar chamada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Só unha vez"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s non é compatible co perfil de traballo."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s non admite o perfil de traballo"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Teléfono"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Auriculares"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Accesibilidade activada"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accesibilidade cancelada"</string>
     <string name="user_switched" msgid="3768006783166984410">"Usuario actual <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Cambiando a <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Propietario"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Erro"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"O administrador non admite este cambio"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> seleccionado"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> eliminado"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> do traballo"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Para desactivar esta pantalla, mantén pulsado Atrás e Recentes ao mesmo tempo."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Para desactivar esta pantalla, mantén pulsado Recentes."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"A pantalla está fixada. A túa organización non permite desactivar a pantalla."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Queres usar a fixación de pantalla?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"A fixación de pantalla bloquea a pantalla nunha vista única.\n\nPara saír, mantén pulsado Atrás e Recentes ao mesmo tempo."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"A fixación de pantalla bloquea a pantalla nunha vista única.\n\nPara saír, mantén pulsado Recentes."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NON, GRAZAS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"SI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"deseño de desbloqueo"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"contrasinal"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Pantalla fixada"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Pantalla desactivada"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Solicitar un PIN antes de soltar a pantalla"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Solicitar un padrón de desbloqueo antes de soltar a pantalla"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Solicitar un contrasinal antes de soltar a pantalla"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Para axudar a mellorar a duración da batería, o aforro de batería reduce o rendemento do dispositivo e restrinxe a vibración e a maioría dos datos en segundo plano. É posible que o correo, as mensaxes e outras aplicacións que se sincronizan con frecuencia, non se actualicen a menos que as abras.\n\nO aforro de batería desactívase automaticamente durante a carga do dispositivo."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Ata que remate o tempo de inactividade ás <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Durante unha hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
 </resources>
diff --git a/core/res/res/values-hi/strings.xml b/core/res/res/values-hi/strings.xml
index 9662dda..3faaf0c 100644
--- a/core/res/res/values-hi/strings.xml
+++ b/core/res/res/values-hi/strings.xml
@@ -147,9 +147,9 @@
     <string name="contentServiceSync" msgid="8353523060269335667">"समन्वयन"</string>
     <string name="contentServiceSyncNotificationTitle" msgid="397743349191901458">"समन्वयन"</string>
     <string name="contentServiceTooManyDeletesNotificationDesc" msgid="8100981435080696431">"बहुत से <xliff:g id="CONTENT_TYPE">%s</xliff:g> हटाए जाते हैं."</string>
-    <string name="low_memory" product="tablet" msgid="6494019234102154896">"टेबलेट संग्रहण भर गया है. स्‍थान रिक्त करने के लिए कुछ फ़ाइलें हटाएं."</string>
-    <string name="low_memory" product="watch" msgid="4415914910770005166">"घड़ी संग्रहण भर गया है. स्‍थान रिक्त करने के लिए कुछ फ़ाइलें हटाएं."</string>
-    <string name="low_memory" product="default" msgid="3475999286680000541">"फ़ोन संग्रहण भर गया है. स्‍थान रिक्त करने के लिए कुछ फ़ाइलें हटाएं."</string>
+    <string name="low_memory" product="tablet" msgid="6494019234102154896">"टेबलेट मेमोरी भर गया है. स्‍थान खाली करने के लिए कुछ फ़ाइलें हटाएं."</string>
+    <string name="low_memory" product="watch" msgid="4415914910770005166">"घड़ी मेमोरी भर गया है. स्‍थान खाली करने के लिए कुछ फ़ाइलें हटाएं."</string>
+    <string name="low_memory" product="default" msgid="3475999286680000541">"फ़ोन मेमोरी भर गया है. स्‍थान खाली करने के लिए कुछ फ़ाइलें हटाएं."</string>
     <string name="ssl_ca_cert_warning" msgid="5848402127455021714">"नेटवर्क को मॉनिटर किया जा सकता है"</string>
     <string name="ssl_ca_cert_noti_by_unknown" msgid="4475437862189850602">"किसी अज्ञात तृतीय पक्ष के द्वारा"</string>
     <string name="ssl_ca_cert_noti_managed" msgid="4030263497686867141">"<xliff:g id="MANAGING_DOMAIN">%s</xliff:g> के द्वारा"</string>
@@ -206,7 +206,7 @@
     <string name="permgrouplab_network" msgid="5808983377727109831">"नेटवर्क संचार"</string>
     <string name="permgroupdesc_network" msgid="4478299413241861987">"विभिन्‍न नेटवर्क सुविधाओं पर पहुंचें."</string>
     <string name="permgrouplab_bluetoothNetwork" msgid="1585403544162128109">"ब्लूटूथ"</string>
-    <string name="permgroupdesc_bluetoothNetwork" msgid="5625288577164282391">"ब्लूटूथ के माध्‍यम से उपकरणों और नेटवर्क पर पहुंचें."</string>
+    <string name="permgroupdesc_bluetoothNetwork" msgid="5625288577164282391">"ब्लूटूथ के माध्‍यम से डिवाइस और नेटवर्क पर पहुंचें."</string>
     <string name="permgrouplab_audioSettings" msgid="8329261670151871235">"ऑडियो सेटिंग"</string>
     <string name="permgroupdesc_audioSettings" msgid="2641515403347568130">"ऑडियो सेटिंग बदलें."</string>
     <string name="permgrouplab_affectsBattery" msgid="6209246653424798033">"बैटरी प्रभावित होती है"</string>
@@ -251,8 +251,8 @@
     <string name="permgroupdesc_developmentTools" msgid="7058828032358142018">"सुविधाएं जो केवल ऐप्स  डेवलपर के लिए आवश्यक हैं."</string>
     <string name="permgrouplab_display" msgid="4279909676036402636">"अन्‍य ऐप्स UI"</string>
     <string name="permgroupdesc_display" msgid="6051002031933013714">"अन्‍य ऐप्स के UI को प्रभावित करें."</string>
-    <string name="permgrouplab_storage" msgid="1971118770546336966">"संग्रहण"</string>
-    <string name="permgroupdesc_storage" product="nosdcard" msgid="7442318502446874999">"USB संग्रहण में पहुंचें."</string>
+    <string name="permgrouplab_storage" msgid="1971118770546336966">"मेमोरी"</string>
+    <string name="permgroupdesc_storage" product="nosdcard" msgid="7442318502446874999">"USB मेमोरी में पहुंचें."</string>
     <string name="permgroupdesc_storage" product="default" msgid="9203302214915355774">"SD कार्ड में पहुंचें."</string>
     <string name="permgrouplab_accessibilityFeatures" msgid="7919025602283593907">"आसान तरीका सुविधाएं"</string>
     <string name="permgroupdesc_accessibilityFeatures" msgid="4205196881678144335">"सहायक प्रौद्योगिकी के द्वारा अनुरोध की जा सकने वाली सुविधाएं."</string>
@@ -262,7 +262,7 @@
     <string name="capability_desc_canRequestTouchExploration" msgid="5800552516779249356">"स्पर्श किए गए आइटम ज़ोर से बोले जाएंगे और स्क्रीन को जेस्चर के उपयोग से एक्सप्लोर किया जा सकेगा."</string>
     <string name="capability_title_canRequestEnhancedWebAccessibility" msgid="1739881766522594073">"एन्हांस की गई वेब आसान तरीका चालू करें"</string>
     <string name="capability_desc_canRequestEnhancedWebAccessibility" msgid="7881063961507511765">"ऐप्स  सामग्री को अधिक पहुंच-योग्य बनाने के लिए स्क्रिप्ट इंस्टॉल किए जा सकते हैं."</string>
-    <string name="capability_title_canRequestFilterKeyEvents" msgid="2103440391902412174">"आपके द्वारा लिखे हुए पाठ को ध्यान से देखें"</string>
+    <string name="capability_title_canRequestFilterKeyEvents" msgid="2103440391902412174">"आपके द्वारा लिखे हुए लेख को ध्यान से देखें"</string>
     <string name="capability_desc_canRequestFilterKeyEvents" msgid="7463135292204152818">"क्रेडिट कार्ड नंबर और पासवर्ड जैसा व्यक्तिगत डेटा शामिल होता है."</string>
     <string name="permlab_statusBar" msgid="7417192629601890791">"स्‍थिति बार अक्षम या बदलें"</string>
     <string name="permdesc_statusBar" msgid="8434669549504290975">"ऐप्स  को स्थिति बार अक्षम करने या सिस्‍टम आइकन को जोड़ने या निकालने देता है."</string>
@@ -276,9 +276,9 @@
     <string name="permdesc_uninstall_shortcut" msgid="6745743474265057975">"एप्‍लिकेशन को उपयोगकर्ता के हस्‍तक्षेप के बिना होमस्‍क्रीन शॉर्टकट निकालने की अनुमति देता है."</string>
     <string name="permlab_processOutgoingCalls" msgid="3906007831192990946">"आउटगोइंग कॉल को कहीं और भेजें"</string>
     <string name="permdesc_processOutgoingCalls" msgid="5156385005547315876">"ऐप्स को किसी कॉल को भिन्न नंबर पर रिडायरेक्ट करने या पूरी तरह से कॉल निरस्त करने के विकल्प के साथ आउटगोइंग कॉल के दौरान डायल किए जा रहे नंबर को देखने की अनुमति देती है."</string>
-    <string name="permlab_receiveSms" msgid="8673471768947895082">"पाठ संदेश (SMS) प्राप्त करें"</string>
+    <string name="permlab_receiveSms" msgid="8673471768947895082">"लेख संदेश (SMS) प्राप्त करें"</string>
     <string name="permdesc_receiveSms" msgid="6424387754228766939">"ऐप्स  को SMS संदेशों को प्राप्‍त और संसाधित करने देता है. इसका अर्थ है कि ऐप्स  आपके उपकरण पर भेजे गए संदेशों की निगरानी आपको दिखाए बिना कर सकता है और उन्‍हें हटा सकता है."</string>
-    <string name="permlab_receiveMms" msgid="1821317344668257098">"पाठ संदेश (MMS) प्राप्त करें"</string>
+    <string name="permlab_receiveMms" msgid="1821317344668257098">"लेख संदेश (MMS) प्राप्त करें"</string>
     <string name="permdesc_receiveMms" msgid="533019437263212260">"ऐप्स  को MMS संदेशों को प्राप्‍त और संसाधित करने देता है. इसका अर्थ है कि ऐप्स  आपके उपकरण पर भेजे गए संदेशों की निगरानी आपको दिखाए बिना कर सकता है और उन्‍हें हटा सकता है."</string>
     <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"आपातकालीन प्रसारण प्राप्त करें"</string>
     <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"ऐप्स  को आपातकालीन प्रसारण संदेशों को प्राप्त करने और संसाधित करने देता है. यह अनुमति केवल सिस्टम ऐप्स  में उपलब्ध है."</string>
@@ -288,13 +288,13 @@
     <string name="permdesc_sendSms" msgid="7094729298204937667">"ऐप्स  को SMS संदेशों को भेजने देता है. इसके परिणामस्वरूप अप्रत्‍याशित शुल्‍क लागू हो सकते हैं. दुर्भावनापूर्ण ऐप्स  आपकी पुष्टि के बिना संदेश भेजकर आपका धन व्‍यय कर सकते हैं."</string>
     <string name="permlab_sendRespondViaMessageRequest" msgid="8713889105305943200">"संदेश-द्वारा-जवाब भेजें ईवेंट"</string>
     <string name="permdesc_sendRespondViaMessageRequest" msgid="7107648548468778734">"इनकमिंग कॉल के संदेश-द्वारा-जवाब देने के ईवेंट प्रबंधित करने के लिए, ऐप्स  को अन्य संदेश सेवा ऐप्स  को अनुरोध भेजने देती है."</string>
-    <string name="permlab_readSms" msgid="8745086572213270480">"अपने पाठ संदेश (SMS या MMS) पढ़ें"</string>
-    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"ऐप्स  को आपके टेबलेट या SIM कार्ड में संग्रहीत SMS संदेश पढ़ने देता है. इससे सामग्री या गोपनीयता पर ध्यान दिए बिना, ऐप्स  सभी SMS संदेश पढ़ सकता है."</string>
-    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"ऐप्स  को आपके फ़ोन या SIM कार्ड में संग्रहीत SMS संदेश पढ़ने देता है. इससे सामग्री या गोपनीयता पर ध्यान दिए बिना, ऐप्स  सभी SMS संदेश पढ़ सकता है."</string>
-    <string name="permlab_writeSms" msgid="3216950472636214774">"अपने पाठ संदेश (SMS या MMS) संपादित करें"</string>
+    <string name="permlab_readSms" msgid="8745086572213270480">"अपने लेख संदेश (SMS या MMS) पढ़ें"</string>
+    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"ऐप्स  को आपके टेबलेट या सिम कार्ड में संग्रहीत SMS संदेश पढ़ने देता है. इससे सामग्री या गोपनीयता पर ध्यान दिए बिना, ऐप्स  सभी SMS संदेश पढ़ सकता है."</string>
+    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"ऐप्स  को आपके फ़ोन या सिम कार्ड में संग्रहीत SMS संदेश पढ़ने देता है. इससे सामग्री या गोपनीयता पर ध्यान दिए बिना, ऐप्स  सभी SMS संदेश पढ़ सकता है."</string>
+    <string name="permlab_writeSms" msgid="3216950472636214774">"अपने लेख संदेश (SMS या MMS) संपादित करें"</string>
     <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"ऐप्स  को आपके टेबलेट या सिम कार्ड में संग्रहीत SMS संदेशों में लिखने देता है. दुर्भावनापूर्ण ऐप्स  आपके संदेशों को हटा सकते हैं."</string>
     <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"ऐप्स  को आपके फ़ोन या सिम कार्ड में संग्रहीत SMS संदेशों को लिखने देता है.  दुर्भावनापूर्ण ऐप्स  आपके संदेशों को हटा सकते हैं."</string>
-    <string name="permlab_receiveWapPush" msgid="5991398711936590410">"पाठ संदेश (WAP) प्राप्त करें"</string>
+    <string name="permlab_receiveWapPush" msgid="5991398711936590410">"लेख संदेश (WAP) प्राप्त करें"</string>
     <string name="permdesc_receiveWapPush" msgid="748232190220583385">"ऐप्स  को WAP संदेशों को प्राप्‍त और संसाधित करने देता है. इस अनुमति में आपको भेजे गए संदेशों की निगरानी आपको दिखाए बिना करने और हटाने की क्षमता शामिल है."</string>
     <string name="permlab_receiveBluetoothMap" msgid="7593811487142360528">"ब्लूटूथ संदेश प्राप्त करें (MAP)"</string>
     <string name="permdesc_receiveBluetoothMap" msgid="8656755936919466345">"ऐप्स को ब्लूटूथ MAP संदेशों को प्राप्त करने और भेजने देती है. इसका अर्थ है कि ऐप्स आपके उपकरण पर भेजे गए संदेशों को आपको दिखाए बिना ही मॉनीटर कर सकता है या उन्हें हटा सकता है."</string>
@@ -335,7 +335,7 @@
     <string name="permlab_dump" msgid="1681799862438954752">"सिस्‍टम की आंतरिक स्‍थिति पुनर्प्राप्त करें"</string>
     <string name="permdesc_dump" msgid="1778299088692290329">"ऐप्स को सिस्‍टम की आंतरिक स्‍थिति पुनर्प्राप्त करने देता है. दुर्भावनापूर्ण ऐप्स विभिन्‍न प्रकार की निजी और सुरक्षा जानकारी प्राप्त कर सकते हैं जिनकी उन्‍हें सामान्‍यत: आवश्‍यकता नहीं होती."</string>
     <string name="permlab_retrieve_window_content" msgid="8022588608994589938">"स्‍क्रीन सामग्री पुनर्प्राप्त करें"</string>
-    <string name="permdesc_retrieve_window_content" msgid="3193269069469700265">"ऐप्स को सक्रिय विंडो की सामग्री पुनर्प्राप्त करने देता है. दुर्भावनापूर्ण ऐप्स विंडो की संपूर्ण सामग्री प्राप्त कर सकते हैं और पासवर्ड को छोड़कर इसके सभी पाठ जांच सकते हैं."</string>
+    <string name="permdesc_retrieve_window_content" msgid="3193269069469700265">"ऐप्स को सक्रिय विंडो की सामग्री पुनर्प्राप्त करने देता है. दुर्भावनापूर्ण ऐप्स विंडो की संपूर्ण सामग्री प्राप्त कर सकते हैं और पासवर्ड को छोड़कर इसके सभी लेख जांच सकते हैं."</string>
     <string name="permlab_temporary_enable_accessibility" msgid="2312612135127310254">"आसान तरीका को अस्थायी रूप से सक्षम करें"</string>
     <string name="permdesc_temporary_enable_accessibility" msgid="8079456293182975464">"ऐप्स  को उपकरण पर आसान तरीका को अस्थायी रूप से सक्षम करने देता है. दुर्भावनापूर्ण ऐप्स  उपयोगकर्ता की सहमति के बिना आसान तरीका को सक्षम कर सकते हैं."</string>
     <string name="permlab_retrieveWindowToken" msgid="7154762602367758602">"विंडो टोकन प्राप्त करें"</string>
@@ -399,8 +399,8 @@
     <string name="permdesc_bindPrintSpoolerService" msgid="3680552285933318372">"धारक को प्रिंट स्पूलर सेवा के शीर्ष-स्‍तर इंटरफ़ेस से आबद्ध होने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_bindNfcService" msgid="2752731300419410724">"NFC सेवा से आबद्ध रहें"</string>
     <string name="permdesc_bindNfcService" msgid="6120647629174066862">"धारक को ऐसे ऐप्स  से आबद्ध रहने देता है जो NFC कार्ड का अनुकरण कर रहे हैं. सामान्य ऐप्स  के लिए कभी भी आवश्यक नहीं होना चाहिए."</string>
-    <string name="permlab_bindTextService" msgid="7358378401915287938">"किसी पाठ सेवा पर बने रहें"</string>
-    <string name="permdesc_bindTextService" msgid="8151968910973998670">"धारक को किसी पाठ सेवा (उदा. SpellCheckerService) के शीर्ष-स्‍तर इंटरफ़ेस पर आबद्ध होने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
+    <string name="permlab_bindTextService" msgid="7358378401915287938">"किसी लेख सेवा पर बने रहें"</string>
+    <string name="permdesc_bindTextService" msgid="8151968910973998670">"धारक को किसी लेख सेवा (उदा. SpellCheckerService) के शीर्ष-स्‍तर इंटरफ़ेस पर आबद्ध होने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_bindVpnService" msgid="4708596021161473255">"किसी VPN सेवा से आबद्ध करें"</string>
     <string name="permdesc_bindVpnService" msgid="2067845564581693905">"धारक को किसी Vpn सेवा के शीर्ष-स्‍तर इंटरफ़ेस से आबद्ध होने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_bindWallpaper" msgid="8716400279937856462">"वॉलपेपर से आबद्ध करें"</string>
@@ -413,10 +413,8 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"धारक को किसी रिमोट डिस्प्ले के शीर्ष-स्‍तरीय इंटरफ़ेस से आबद्ध होने देती है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"किसी विजेट सेवा से आबद्ध करें"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"धारक को किसी विजेट सेवा के शीर्ष-स्‍तर इंटरफ़ेस से आबद्ध होने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"किसी रूट प्रदाता सेवा से आबद्ध हों"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"धारक को किसी भी पंजीकृत रूट प्रदाता से आबद्ध रहने देती है. सामान्य ऐप्स के लिए कभी भी आवश्यक नहीं होना चाहिए."</string>
-    <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"किसी उपकरण व्‍यवस्‍थापक के साथ सहभागिता करें"</string>
-    <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"धारक को किसी उपकरण व्‍यवस्‍थापक को उद्देश्य भेजने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
+    <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"किसी डिवाइस नियंत्रक के साथ सहभागिता करें"</string>
+    <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"धारक को किसी डिवाइस नियंत्रक को उद्देश्य भेजने देता है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"टीवी इनपुट से आबद्ध करें"</string>
     <string name="permdesc_bindTvInput" msgid="2371008331852001924">"धारक को किसी टीवी इनपुट के शीर्ष-स्‍तर इंटरफ़ेस से आबद्ध होने देती है. सामान्‍य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_modifyParentalControls" msgid="4611318225997592242">"अभिभावकीय नियंत्रणों को बदल सकता है"</string>
@@ -432,21 +430,21 @@
     <string name="permlab_signalPersistentProcesses" msgid="4539002991947376659">"ऐप्स  को Linux सिग्नल भेजें"</string>
     <string name="permdesc_signalPersistentProcesses" msgid="4896992079182649141">"ऐप्स को यह अनुरोध करने देता है कि दिया गया सिग्नल सभी जारी प्रक्रियाओं को भेजा जाए."</string>
     <string name="permlab_persistentActivity" msgid="8841113627955563938">"ऐप्स को हमेशा चलने वाला बनाएं"</string>
-    <string name="permdesc_persistentActivity" product="tablet" msgid="8525189272329086137">"ऐप्स को स्मृति में स्‍वयं के कुछ हिस्सों को लगातार बनाने की अनुमति देता है. यह अन्‍य ऐप्स  के लिए उपलब्‍ध स्‍मृति को सीमित कर टेबलेट को धीमा कर सकता है."</string>
-    <string name="permdesc_persistentActivity" product="default" msgid="4384760047508278272">"ऐप्स को स्मृति में स्‍वयं के कुछ हिस्सों को लगातार बनाने देता है. यह अन्‍य ऐप्स  के लिए उपलब्‍ध स्‍मृति को सीमित कर फ़ोन को धीमा कर सकता है."</string>
+    <string name="permdesc_persistentActivity" product="tablet" msgid="8525189272329086137">"ऐप्स को मेमोरी में स्‍वयं के कुछ हिस्सों को लगातार बनाने की अनुमति देता है. यह अन्‍य ऐप्स  के लिए उपलब्‍ध स्‍मृति को सीमित कर टेबलेट को धीमा कर सकता है."</string>
+    <string name="permdesc_persistentActivity" product="default" msgid="4384760047508278272">"ऐप्स को मेमोरी में स्‍वयं के कुछ हिस्सों को लगातार बनाने देता है. यह अन्‍य ऐप्स  के लिए उपलब्‍ध स्‍मृति को सीमित कर फ़ोन को धीमा कर सकता है."</string>
     <string name="permlab_deletePackages" msgid="184385129537705938">"ऐप्स हटाएं"</string>
     <string name="permdesc_deletePackages" msgid="7411480275167205081">"ऐप्स  को Android पैकेज हटाने देता है. दुर्भावनापूर्ण ऐप्स  इसका उपयोग महत्वपूर्ण ऐप्स  हटाने के लिए कर सकते हैं."</string>
     <string name="permlab_clearAppUserData" msgid="274109191845842756">"अन्‍य ऐप्स का डेटा हटाएं"</string>
     <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"ऐप्स  को उपयोगकर्ता डेटा साफ़ करने देता है."</string>
     <string name="permlab_deleteCacheFiles" msgid="3128665571837408675">"अन्‍य ऐप्स के संचय हटाएं"</string>
     <string name="permdesc_deleteCacheFiles" msgid="3812998599006730196">"ऐप्स  को संचय फ़ाइलें हटाने देता है."</string>
-    <string name="permlab_getPackageSize" msgid="7472921768357981986">"ऐप्स  संग्रहण स्थान मापें"</string>
+    <string name="permlab_getPackageSize" msgid="7472921768357981986">"ऐप्स  मेमोरी स्थान मापें"</string>
     <string name="permdesc_getPackageSize" msgid="3921068154420738296">"ऐप्स  को उसका कोड, डेटा, और संचय आकारों को प्राप्त करने देता है"</string>
     <string name="permlab_installPackages" msgid="2199128482820306924">"सीधे ऐप्स इंस्‍टॉल करें"</string>
     <string name="permdesc_installPackages" msgid="5628530972548071284">"एप को नए या नई जानकारी वाले Android पैकेज इंस्टॉल करने देता है. दुर्भावनापूर्ण ऐप्स  इसका उपयोग अनियंत्रित रूप से सशक्त अनुमतियों वाले नए ऐप्स  जोड़ने में कर सकते हैं."</string>
     <string name="permlab_clearAppCache" msgid="7487279391723526815">"सभी ऐप्स  संचय डेटा हटाएं"</string>
-    <string name="permdesc_clearAppCache" product="tablet" msgid="8974640871945434565">"ऐप्स  को अन्य ऐप्स  की संचय निर्देशिकाओं में से फ़ाइलें हटाकर टेबलेट संग्रहण को खाली करने देती है. इससे अन्य ऐप्स  अधिक धीमे प्रारंभ हो सकते हैं क्योंकि उन्हें अपना डेटा पुनर्प्राप्त करने की आवश्यकता होती है."</string>
-    <string name="permdesc_clearAppCache" product="default" msgid="2459441021956436779">"ऐप्स  को अन्य ऐप्स  की संचय निर्देशिकाओं में से फ़ाइलें हटाकर फ़ोन संग्रहण को खाली करने देती है. इससे अन्य ऐप्स  अधिक धीमे प्रारंभ हो सकते हैं क्योंकि उन्हें अपना डेटा पुनर्प्राप्त करने की आवश्यकता होती है."</string>
+    <string name="permdesc_clearAppCache" product="tablet" msgid="8974640871945434565">"ऐप्स  को अन्य ऐप्स  की संचय निर्देशिकाओं में से फ़ाइलें हटाकर टेबलेट मेमोरी को खाली करने देती है. इससे अन्य ऐप्स  अधिक धीमे प्रारंभ हो सकते हैं क्योंकि उन्हें अपना डेटा पुनर्प्राप्त करने की आवश्यकता होती है."</string>
+    <string name="permdesc_clearAppCache" product="default" msgid="2459441021956436779">"ऐप्स  को अन्य ऐप्स  की संचय निर्देशिकाओं में से फ़ाइलें हटाकर फ़ोन मेमोरी को खाली करने देती है. इससे अन्य ऐप्स  अधिक धीमे प्रारंभ हो सकते हैं क्योंकि उन्हें अपना डेटा पुनर्प्राप्त करने की आवश्यकता होती है."</string>
     <string name="permlab_movePackage" msgid="3289890271645921411">"ऐप्स संसाधनों को ले जाएं"</string>
     <string name="permdesc_movePackage" msgid="319562217778244524">"ऐप्स को ऐप्स संसाधनों को आंतरिक से बाहरी मीडिया में और इसके विपरीत ले जाने देता है."</string>
     <string name="permlab_readLogs" msgid="6615778543198967614">"संवेदनशील लॉग डेटा पढ़ें"</string>
@@ -454,8 +452,8 @@
     <string name="permdesc_readLogs" product="default" msgid="2063438140241560443">"ऐप्स को सिस्‍टम की विभिन्‍न लॉग फ़ाइलें पढ़ने देता है. संभावित रूप से व्यक्तिगत या निजी जानकारी सहित, यह इसे इस बारे में सामान्य जानकारी खोजने देता है कि आप फ़ोन से क्‍या कर रहे हैं."</string>
     <string name="permlab_anyCodecForPlayback" msgid="715805555823881818">"प्लेबैक के लिए किसी भी मीडिया डीकोडर का उपयोग करें"</string>
     <string name="permdesc_anyCodecForPlayback" msgid="8283912488433189010">"ऐप्स  को प्लेबैक डीकोड करने के लिए किसी भी इंस्टॉल किए गए डीकोडर का उपयोग करने देता है."</string>
-    <string name="permlab_manageCaCertificates" msgid="1678391896786882014">"विश्वसनीय क्रेडेंशियल प्रबंधित करें"</string>
-    <string name="permdesc_manageCaCertificates" msgid="4015644047196937014">"ऐप्स  को CA प्रमाणपत्रों को विश्वसनीय क्रेडेंशियल के रूप में इंस्टॉल और अनइंस्टॉल करने दें"</string>
+    <string name="permlab_manageCaCertificates" msgid="1678391896786882014">"विश्वसनीय प्रमाणिकता प्रबंधित करें"</string>
+    <string name="permdesc_manageCaCertificates" msgid="4015644047196937014">"ऐप्स  को CA प्रमाणपत्रों को विश्वसनीय प्रमाणिकता के रूप में इंस्टॉल और अनइंस्टॉल करने दें"</string>
     <string name="permlab_bindJobService" msgid="3637568367978271086">"ऐप्लिकेशन का शेड्यूल किया गया पृष्ठभूमि कार्य चलाएं"</string>
     <string name="permdesc_bindJobService" msgid="3473288460524119838">"यह अनुमति Android सिस्टम को, अनुरोध किए जाने पर ऐप्लिकेशन को पृष्ठभूमि में चलाने देती है."</string>
     <string name="permlab_diagnostic" msgid="8076743953908000342">"निदान के स्‍वामित्‍व वाले संसाधनों को पढ़ें/लिखें"</string>
@@ -463,7 +461,7 @@
     <string name="permlab_changeComponentState" msgid="6335576775711095931">"ऐप्स घटकों को सक्षम या अक्षम करें"</string>
     <string name="permdesc_changeComponentState" product="tablet" msgid="8887435740982237294">"ऐप्स को यह बदलने देता है कि किसी अन्‍य ऐप्स का घटक सक्षम है या नहीं. दुर्भावनापूर्ण ऐप्स महत्‍वपूर्ण फ़ोन क्षमताओं को अक्षम करने में इसका उपयोग कर सकते हैं. इस अनुमति का उपयोग सावधानी के साथ करना चाहिए, क्योंकि इससे ऐप्स घटकों के अनुपयोगी, असंगत, या अस्‍थिर स्‍थिति में जाने की संभावना है."</string>
     <string name="permdesc_changeComponentState" product="default" msgid="1827232484416505615">"ऐप्स को यह बदलने देता है कि किसी अन्‍य ऐप्स का घटक सक्षम है या नहीं. दुर्भावनापूर्ण ऐप्स महत्‍वपूर्ण फ़ोन क्षमताओं को अक्षम करने में इसका उपयोग कर सकते हैं. इस अनुमति का उपयोग सावधानी के साथ करना चाहिए, क्योंकि इससे ऐप्स घटकों के अनुपयोगी, असंगत, या अस्‍थिर स्‍थिति में जाने की संभावना है."</string>
-    <string name="permlab_grantRevokePermissions" msgid="4627315351093508795">"अनुमति दें या रद्द करें"</string>
+    <string name="permlab_grantRevokePermissions" msgid="4627315351093508795">"अनुमति दें या रहने दें"</string>
     <string name="permdesc_grantRevokePermissions" msgid="4088642654085850662">"ऐप्स  को उसके या अन्य ऐप्स  के लिए विशेष अनुमतियां देने या रद्द करने देता है. दुर्भावनापूर्ण ऐप्स  इसका उपयोग उन सुविधाओं तक पहुंचने के लिए कर सकते हैं जो आपने उन्हें नहीं दी हैं."</string>
     <string name="permlab_setPreferredApplications" msgid="8463181628695396391">"पसंदीदा ऐप्स सेट करें"</string>
     <string name="permdesc_setPreferredApplications" msgid="4973986762241783712">"ऐप्स  को आपके पसंदीदा ऐप्स  को संशोधित करने देता है. दुर्भावनापूर्ण ऐप्स  आपसे निजी डेटा एकत्रित करने के लिए आपके मौजूदा ऐप्स  को स्पूफ़ करके, चलाए जाने वाले ऐप्स  को चुपचाप बदल सकते हैं."</string>
@@ -477,8 +475,8 @@
     <string name="permdesc_receiveBootCompleted" product="tablet" msgid="7390304664116880704">"ऐप्स  को सिस्टम द्वारा बूटिंग पूर्ण करते ही स्वतः आरंभ करने देता है. इससे टेबलेट को आरंभ होने में अधिक समय लग सकता है और ऐप्स  को निरंतर चलाकर संपूर्ण टेबलेट को धीमा करने देता है."</string>
     <string name="permdesc_receiveBootCompleted" product="default" msgid="513950589102617504">"ऐप्स  को सिस्टम द्वारा बूटिंग पूर्ण करते ही स्वतः प्रारंभ होने देता है. इससे फ़ोन को प्रारंभ होने में अधिक समय लग सकता है और ऐप्स  के निरंतर चलते रहने से संपूर्ण फ़ोन प्रक्रियाएं धीमी हो सकती हैं."</string>
     <string name="permlab_broadcastSticky" msgid="7919126372606881614">"स्टिकी प्रसारण भेजें"</string>
-    <string name="permdesc_broadcastSticky" product="tablet" msgid="7749760494399915651">"ऐप्स को स्‍टिकी प्रसारण भेजने देता है, जो प्रसारण समाप्त होने के बाद भी बने रहते हैं. अत्यधिक उपयोग, टेबलेट की बहुत अधिक स्मृति का उपयोग करके उसे धीमा या अस्‍थिर कर सकता है."</string>
-    <string name="permdesc_broadcastSticky" product="default" msgid="2825803764232445091">"ऐप्स को स्‍टिकी प्रसारण भेजने देता है, जो प्रसारण समाप्त होने के बाद भी बने रहते हैं. अत्यधिक उपयोग, फ़ोन की बहुत अधिक स्मृति का उपयोग करके उसे धीमा या अस्‍थिर कर सकता है."</string>
+    <string name="permdesc_broadcastSticky" product="tablet" msgid="7749760494399915651">"ऐप्स को स्‍टिकी प्रसारण भेजने देता है, जो प्रसारण समाप्त होने के बाद भी बने रहते हैं. अत्यधिक उपयोग, टेबलेट की बहुत अधिक मेमोरी का उपयोग करके उसे धीमा या अस्‍थिर कर सकता है."</string>
+    <string name="permdesc_broadcastSticky" product="default" msgid="2825803764232445091">"ऐप्स को स्‍टिकी प्रसारण भेजने देता है, जो प्रसारण समाप्त होने के बाद भी बने रहते हैं. अत्यधिक उपयोग, फ़ोन की बहुत अधिक मेमोरी का उपयोग करके उसे धीमा या अस्‍थिर कर सकता है."</string>
     <string name="permlab_readContacts" msgid="8348481131899886131">"अपने संपर्क पढ़ें"</string>
     <string name="permdesc_readContacts" product="tablet" msgid="5294866856941149639">"ऐप्स  को आपके टेबलेट में संग्रहीत संपर्कों के डेटा को, साथ ही आपके द्वारा विशिष्ट व्यक्तियों को कॉल करने, ईमेल करने, या अन्‍य तरीके से डॉयलॉग करने की आवृत्ति को पढ़ने देता है. यह अनुमति ऐप्स  को आपके संपर्क डेटा को सहेजने देती है, और दुर्भावनापूर्ण ऐप्स  आपकी जानकारी के बिना संपर्क डेटा को साझा कर सकते हैं."</string>
     <string name="permdesc_readContacts" product="default" msgid="8440654152457300662">"ऐप्स  को आपके फ़ोन में संग्रहीत संपर्कों के डेटा को, साथ ही आपके द्वारा विशिष्ट व्यक्तियों को कॉल करने, ईमेल करने, या अन्‍य तरीके से डॉयलॉग करने की आवृत्ति को पढ़ने देता है. यह अनुमति ऐप्स  को आपके संपर्क डेटा को सहेजने देती है, और दुर्भावनापूर्ण ऐप्स  आपकी जानकारी के बिना संपर्क डेटा को साझा कर सकते हैं."</string>
@@ -557,32 +555,32 @@
     <string name="permlab_reboot" product="default" msgid="2898560872462638242">"फ़ोन रीबूट के लिए बाध्‍य करें"</string>
     <string name="permdesc_reboot" product="tablet" msgid="8172056180063700741">"ऐप्स को टेबलेट रीबूट करने के लिए बाध्‍य करने देता है."</string>
     <string name="permdesc_reboot" product="default" msgid="5326008124289989969">"ऐप्स को फ़ोन बलपूर्वक रीबूट करने देता है."</string>
-    <string name="permlab_mount_unmount_filesystems" product="nosdcard" msgid="2927361537942591841">"USB संग्रहण फ़ाइल सिस्‍टम पर पहुंचें"</string>
+    <string name="permlab_mount_unmount_filesystems" product="nosdcard" msgid="2927361537942591841">"USB मेमोरी फ़ाइल सिस्‍टम पर पहुंचें"</string>
     <string name="permlab_mount_unmount_filesystems" product="default" msgid="4402305049890953810">"SD कार्ड फ़ाइल सिस्‍टम पर पहुंचें"</string>
-    <string name="permdesc_mount_unmount_filesystems" msgid="1829290701658992347">"ऐप्स को निकाले जाने योग्‍य संग्रहण के लिए फ़ाइल सिस्‍टम माउंट और अनमाउंट करने देता है."</string>
-    <string name="permlab_mount_format_filesystems" product="nosdcard" msgid="6227819582624904972">"USB संग्रहण मिटाएं"</string>
+    <string name="permdesc_mount_unmount_filesystems" msgid="1829290701658992347">"ऐप्स को निकाले जाने योग्‍य मेमोरी के लिए फ़ाइल सिस्‍टम माउंट और अनमाउंट करने देता है."</string>
+    <string name="permlab_mount_format_filesystems" product="nosdcard" msgid="6227819582624904972">"USB मेमोरी मिटाएं"</string>
     <string name="permlab_mount_format_filesystems" product="default" msgid="262582698639274056">"SD कार्ड मिटाएं"</string>
-    <string name="permdesc_mount_format_filesystems" msgid="8784268246779198627">"ऐप्स को निकालने योग्‍य संग्रहण फ़ॉर्मेट करने देता है."</string>
-    <string name="permlab_asec_access" msgid="3411338632002193846">"मोबाइल संग्रहण पर जानकारी प्राप्त करें"</string>
-    <string name="permdesc_asec_access" msgid="3094563844593878548">"ऐप्स  को मोबाइल संग्रहण की जानकारी प्राप्‍त करने देता है."</string>
-    <string name="permlab_asec_create" msgid="6414757234789336327">"मोबाइल संग्रहण बनाएं"</string>
-    <string name="permdesc_asec_create" msgid="4558869273585856876">"ऐप्स को मोबाइल संग्रहण बनाने देता है."</string>
-    <string name="permlab_asec_destroy" msgid="526928328301618022">"मोबाइल संग्रहण नष्ट करें"</string>
-    <string name="permdesc_asec_destroy" msgid="7218749286145526537">"ऐप्स को मोबाइल संग्रहण नष्ट करने देता है."</string>
-    <string name="permlab_asec_mount_unmount" msgid="8877998101944999386">"मोबाइल संग्रहण माउंट/अनमाउंट करें"</string>
-    <string name="permdesc_asec_mount_unmount" msgid="3451360114902490929">"ऐप्स को मोबाइल संग्रहण माउंट/अनमाउंट करने देता है."</string>
-    <string name="permlab_asec_rename" msgid="7496633954080472417">"मोबाइल संग्रहण का नाम बदलें"</string>
-    <string name="permdesc_asec_rename" msgid="1794757588472127675">"ऐप्स को मोबाइल संग्रहण का नाम बदलने देता है."</string>
+    <string name="permdesc_mount_format_filesystems" msgid="8784268246779198627">"ऐप्स को निकालने योग्‍य मेमोरी फ़ॉर्मेट करने देता है."</string>
+    <string name="permlab_asec_access" msgid="3411338632002193846">"मोबाइल मेमोरी पर जानकारी प्राप्त करें"</string>
+    <string name="permdesc_asec_access" msgid="3094563844593878548">"ऐप्स  को मोबाइल मेमोरी की जानकारी प्राप्‍त करने देता है."</string>
+    <string name="permlab_asec_create" msgid="6414757234789336327">"मोबाइल मेमोरी बनाएं"</string>
+    <string name="permdesc_asec_create" msgid="4558869273585856876">"ऐप्स को मोबाइल मेमोरी बनाने देता है."</string>
+    <string name="permlab_asec_destroy" msgid="526928328301618022">"मोबाइल मेमोरी नष्ट करें"</string>
+    <string name="permdesc_asec_destroy" msgid="7218749286145526537">"ऐप्स को मोबाइल मेमोरी नष्ट करने देता है."</string>
+    <string name="permlab_asec_mount_unmount" msgid="8877998101944999386">"मोबाइल मेमोरी माउंट/अनमाउंट करें"</string>
+    <string name="permdesc_asec_mount_unmount" msgid="3451360114902490929">"ऐप्स को मोबाइल मेमोरी माउंट/अनमाउंट करने देता है."</string>
+    <string name="permlab_asec_rename" msgid="7496633954080472417">"मोबाइल मेमोरी का नाम बदलें"</string>
+    <string name="permdesc_asec_rename" msgid="1794757588472127675">"ऐप्स को मोबाइल मेमोरी का नाम बदलने देता है."</string>
     <string name="permlab_vibrate" msgid="7696427026057705834">"कंपन नियंत्रित करें"</string>
     <string name="permdesc_vibrate" msgid="6284989245902300945">"ऐप्स को कंपनकर्ता नियंत्रित करने देता है."</string>
     <string name="permlab_flashlight" msgid="2155920810121984215">"फ़्लैशलाइट नियंत्रित करें"</string>
     <string name="permdesc_flashlight" msgid="6522284794568368310">"ऐप्स को फ़्लैशलाइट नियंत्रित करने देता है."</string>
-    <string name="permlab_manageUsb" msgid="1113453430645402723">"USB उपकरणों की प्राथमिकताएं और अनुमतियां प्रबंधित करें"</string>
-    <string name="permdesc_manageUsb" msgid="7776155430218239833">"ऐप्स को USB उपकरणों की प्राथमिकताओं और अनुमतियों को प्रबंधित करने देता है."</string>
+    <string name="permlab_manageUsb" msgid="1113453430645402723">"USB डिवाइस की प्राथमिकताएं और अनुमतियां प्रबंधित करें"</string>
+    <string name="permdesc_manageUsb" msgid="7776155430218239833">"ऐप्स को USB डिवाइस की प्राथमिकताओं और अनुमतियों को प्रबंधित करने देता है."</string>
     <string name="permlab_accessMtp" msgid="4953468676795917042">"MTP प्रोटोकॉल लागू करें"</string>
     <string name="permdesc_accessMtp" msgid="6532961200486791570">"MTP USB प्रोटोकॉल लागू करने के लिए कर्नेल MTP ड्राइवर में पहुंच की अनुमति देता है."</string>
     <string name="permlab_hardware_test" msgid="4148290860400659146">"परीक्षण हार्डवेयर"</string>
-    <string name="permdesc_hardware_test" msgid="6597964191208016605">"ऐप्स को हार्डवेयर परीक्षण के लिए विविध सहायक उपकरणों को नियंत्रित करने देता है."</string>
+    <string name="permdesc_hardware_test" msgid="6597964191208016605">"ऐप्स को हार्डवेयर परीक्षण के लिए विविध सहायक डिवाइस को नियंत्रित करने देता है."</string>
     <string name="permlab_callPhone" msgid="3925836347681847954">"फ़ोन नंबर पर सीधे कॉल करें"</string>
     <string name="permdesc_callPhone" msgid="3740797576113760827">"ऐप्स  को आपके हस्‍तक्षेप के बिना फ़ोन नंबर पर कॉल करने देता है. इसके परिणाम अप्रत्‍याशित शुल्‍क या कॉल हो सकते हैं. ध्यान दें कि यह ऐप्स  को आपातकालीन नंबर पर कॉल नहीं करने देता. दुर्भावनापूर्ण ऐप्स  आपकी पुष्टि के बिना कॉल करके आपका धन व्‍यय कर सकते हैं."</string>
     <string name="permlab_callPrivileged" msgid="4198349211108497879">"किसी भी फ़ोन नंबर पर सीधे कॉल करें"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"फ़ोन चालू या बंद करें"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ऐप्स को टेबलेट चालू या बंद करने देता है."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ऐप्स को फ़ोन चालू या बंद करने देता है."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"प्रदर्शन समयबाह्य रीसेट करें"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"एेप्स को प्रदर्शन समयबाह्य रीसेट करने देती है."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"फ़ैक्‍ट्री परीक्षण मोड में चलाएं"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"टेबलेट हार्डवेयर में पूर्ण पहुंच की अनुमति देते हुए निम्‍न-स्‍तर निर्माता परीक्षण के रूप में चलाएं. केवल तभी उपलब्‍ध जब कोई टेबलेट निर्माता परीक्षण मोड में चल रहा हो."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"फ़ोन हार्डवेयर में पूर्ण पहुंच की अनुमति देते हुए निम्‍न-स्‍तर निर्माता परीक्षण के रूप में चलाएं. केवल तभी उपलब्‍ध जब कोई फ़ोन निर्माता परीक्षण मोड में चल रहा हो."</string>
@@ -652,21 +652,21 @@
     <string name="permlab_changeBackgroundDataSetting" msgid="1400666012671648741">"पृष्ठभूमि डेटा उपयोग सेटिंग बदलें"</string>
     <string name="permdesc_changeBackgroundDataSetting" msgid="5347729578468744379">"ऐप्स को पृष्ठभूमि डेटा उपयोग सेटिंग बदलने देता है."</string>
     <string name="permlab_accessWifiState" msgid="5202012949247040011">"वाई-फ़ाई  कनेक्‍शन देखें"</string>
-    <string name="permdesc_accessWifiState" msgid="5002798077387803726">"ऐप्स  को वाई-फ़ाई  नेटवर्क के बारे में जानकारी, जैसे WI-Fi सक्षम है या नहीं और कनेक्‍ट किए गए वाई-फ़ाई  उपकरणों के नाम, देखने देता है."</string>
+    <string name="permdesc_accessWifiState" msgid="5002798077387803726">"ऐप्स  को वाई-फ़ाई  नेटवर्क के बारे में जानकारी, जैसे WI-Fi सक्षम है या नहीं और कनेक्‍ट किए गए वाई-फ़ाई  डिवाइस के नाम, देखने देता है."</string>
     <string name="permlab_changeWifiState" msgid="6550641188749128035">"वाई-फ़ाई  से कनेक्‍ट और डिस्‍कनेक्‍ट करें"</string>
     <string name="permdesc_changeWifiState" msgid="7137950297386127533">"ऐप्स  को वाई-फ़ाई  पहुंच बिंदुओं से कनेक्ट और डिस्कनेक्ट करने और वाई-फ़ाई  नेटवर्क के लिए उपकरण कॉन्फ़िगरेशन में परिवर्तन करने देता है."</string>
     <string name="permlab_changeWifiMulticastState" msgid="1368253871483254784">"वाई-फ़ाई  मल्‍टीकास्‍ट प्राप्ति को अनुमति दें"</string>
-    <string name="permdesc_changeWifiMulticastState" product="tablet" msgid="7969774021256336548">"ऐप्स  को वाई-फ़ाई  नेटवर्क पर मल्टीकास्ट पते के उपयोग से केवल आपके टेबलेट पर ही नहीं, बल्कि सभी उपकरणों पर भेजे गए पैकेट प्राप्‍त करने देता है. यह गैर-मल्टीकास्ट मोड से अधिक पावर का उपयोग करता है."</string>
-    <string name="permdesc_changeWifiMulticastState" product="default" msgid="6851949706025349926">"ऐप्स  को वाई-फ़ाई  नेटवर्क पर मल्टीकास्ट पते के उपयोग से केवल आपके फ़ोन पर ही नहीं, बल्कि सभी उपकरणों पर भेजे गए पैकेट प्राप्‍त करने देता है. यह गैर-मल्टीकास्ट मोड से अधिक पावर का उपयोग करता है."</string>
+    <string name="permdesc_changeWifiMulticastState" product="tablet" msgid="7969774021256336548">"ऐप्स  को वाई-फ़ाई  नेटवर्क पर मल्टीकास्ट पते के उपयोग से केवल आपके टेबलेट पर ही नहीं, बल्कि सभी डिवाइस पर भेजे गए पैकेट प्राप्‍त करने देता है. यह गैर-मल्टीकास्ट मोड से अधिक पावर का उपयोग करता है."</string>
+    <string name="permdesc_changeWifiMulticastState" product="default" msgid="6851949706025349926">"ऐप्स  को वाई-फ़ाई  नेटवर्क पर मल्टीकास्ट पते के उपयोग से केवल आपके फ़ोन पर ही नहीं, बल्कि सभी डिवाइस पर भेजे गए पैकेट प्राप्‍त करने देता है. यह गैर-मल्टीकास्ट मोड से अधिक पावर का उपयोग करता है."</string>
     <string name="permlab_bluetoothAdmin" msgid="6006967373935926659">"ब्लूटूथ सेटिंग पर पहुंचें"</string>
-    <string name="permdesc_bluetoothAdmin" product="tablet" msgid="6921177471748882137">"किसी ऐप्स को स्‍थानीय ब्लूटूथ टेबलेट कॉन्‍फ़िगर करने की और रिमोट उपकरणों के साथ खोजने और युग्‍मित करने देता है."</string>
-    <string name="permdesc_bluetoothAdmin" product="default" msgid="8931682159331542137">"ऐप्स को स्‍थानीय ब्लूटूथ फ़ोन कॉन्‍फ़िगर करने देता है, और रिमोट उपकरणों के साथ खोजने और युग्‍मित करने देता है."</string>
+    <string name="permdesc_bluetoothAdmin" product="tablet" msgid="6921177471748882137">"किसी ऐप्स को स्‍थानीय ब्लूटूथ टेबलेट कॉन्‍फ़िगर करने की और रिमोट डिवाइस के साथ खोजने और युग्‍मित करने देता है."</string>
+    <string name="permdesc_bluetoothAdmin" product="default" msgid="8931682159331542137">"ऐप्स को स्‍थानीय ब्लूटूथ फ़ोन कॉन्‍फ़िगर करने देता है, और रिमोट डिवाइस के साथ खोजने और युग्‍मित करने देता है."</string>
     <string name="permlab_bluetoothPriv" msgid="4009494246009513828">"एप्‍लिकेशन के द्वारा ब्लूटूथ युग्‍मन करने देती है"</string>
-    <string name="permdesc_bluetoothPriv" product="tablet" msgid="8045735193417468857">"एप्‍लिकेशन को उपयोगकर्ता के इंटरैक्शन के बिना दूरस्‍थ उपकरणों के साथ युग्‍मित करने देती है."</string>
-    <string name="permdesc_bluetoothPriv" product="default" msgid="8045735193417468857">"एप्‍लिकेशन को उपयोगकर्ता के इंटरैक्शन के बिना दूरस्‍थ उपकरणों के साथ युग्‍मित करने देती है."</string>
-    <string name="permlab_bluetoothMap" msgid="6372198338939197349">"Bluetooth नक्शा डेटा एक्सेस करें"</string>
-    <string name="permdesc_bluetoothMap" product="tablet" msgid="5784090105926959958">"ऐप्स को Bluetooth नक्शा डेटा एक्सेस करने दें."</string>
-    <string name="permdesc_bluetoothMap" product="default" msgid="5784090105926959958">"ऐप्स को Bluetooth नक्शा डेटा एक्सेस करने दें."</string>
+    <string name="permdesc_bluetoothPriv" product="tablet" msgid="8045735193417468857">"एप्‍लिकेशन को उपयोगकर्ता के इंटरैक्शन के बिना दूरस्‍थ डिवाइस के साथ युग्‍मित करने देती है."</string>
+    <string name="permdesc_bluetoothPriv" product="default" msgid="8045735193417468857">"एप्‍लिकेशन को उपयोगकर्ता के इंटरैक्शन के बिना दूरस्‍थ डिवाइस के साथ युग्‍मित करने देती है."</string>
+    <string name="permlab_bluetoothMap" msgid="6372198338939197349">"ब्लूटूथ नक्शा डेटा एक्सेस करें"</string>
+    <string name="permdesc_bluetoothMap" product="tablet" msgid="5784090105926959958">"ऐप्स को ब्लूटूथ नक्शा डेटा एक्सेस करने दें."</string>
+    <string name="permdesc_bluetoothMap" product="default" msgid="5784090105926959958">"ऐप्स को ब्लूटूथ नक्शा डेटा एक्सेस करने दें."</string>
     <string name="permlab_accessWimaxState" msgid="4195907010610205703">"WiMAX से कनेक्ट और डिस्कनेक्ट करें"</string>
     <string name="permdesc_accessWimaxState" msgid="6360102877261978887">"ऐप्स  को WiMAX सक्षम है या नहीं और कनेक्‍ट किए गए किसी WiMAX नेटवर्क के बारे में जानकारी निर्धारित करने देता है."</string>
     <string name="permlab_changeWimaxState" msgid="2405042267131496579">"WiMAX स्‍थिति बदलें"</string>
@@ -675,9 +675,9 @@
     <string name="permlab_scoreNetworks" msgid="6445777779383587181">"स्कोर नेटवर्क"</string>
     <string name="permdesc_scoreNetworks" product="tablet" msgid="1304304745850215556">"ऐप्स को नेटवर्क को रैंक करने देती है और इस बात पर ज़ोर देती है कि टेबलेट को किस नेटवर्क को प्राथमिकता देनी चाहिए."</string>
     <string name="permdesc_scoreNetworks" product="default" msgid="1831501848178651379">"ऐप्स को नेटवर्क को रैंक करने देती है और इस बात पर ज़ोर देती है कि फ़ोन को किस नेटवर्क को प्राथमिकता देनी चाहिए."</string>
-    <string name="permlab_bluetooth" msgid="6127769336339276828">"ब्लूटूथ उपकरणों के साथ युग्मित करें"</string>
-    <string name="permdesc_bluetooth" product="tablet" msgid="3480722181852438628">"ऐप्स को टेबलेट पर ब्लूटूथ का कॉन्‍फ़िगरेशन देखने, और युग्‍मित उपकरणों के साथ कनेक्‍शन बनाने और स्‍वीकार करने देता है."</string>
-    <string name="permdesc_bluetooth" product="default" msgid="3207106324452312739">"ऐप्स को फ़ोन पर ब्लूटूथ का कॉन्‍फ़िगरेशन देखने, और युग्‍मित उपकरणों के साथ कनेक्‍शन बनाने और स्‍वीकार करने देता है."</string>
+    <string name="permlab_bluetooth" msgid="6127769336339276828">"ब्लूटूथ डिवाइस के साथ युग्मित करें"</string>
+    <string name="permdesc_bluetooth" product="tablet" msgid="3480722181852438628">"ऐप्स को टेबलेट पर ब्लूटूथ का कॉन्‍फ़िगरेशन देखने, और युग्‍मित डिवाइस के साथ कनेक्‍शन बनाने और स्‍वीकार करने देता है."</string>
+    <string name="permdesc_bluetooth" product="default" msgid="3207106324452312739">"ऐप्स को फ़ोन पर ब्लूटूथ का कॉन्‍फ़िगरेशन देखने, और युग्‍मित डिवाइस के साथ कनेक्‍शन बनाने और स्‍वीकार करने देता है."</string>
     <string name="permlab_nfc" msgid="4423351274757876953">"नियर फ़ील्‍ड कम्‍यूनिकेशन नियंत्रित करें"</string>
     <string name="permdesc_nfc" msgid="7120611819401789907">"ऐप्स  को नियर फ़ील्ड कम्यूनिकेशन (NFC) टैग, कार्ड, और रीडर के साथ संचार करने देता है."</string>
     <string name="permlab_disableKeyguard" msgid="3598496301486439258">"अपना स्‍क्रीन लॉक अक्षम करें"</string>
@@ -696,30 +696,30 @@
     <string name="permdesc_readDictionary" msgid="659614600338904243">"ऐप्स को ऐसे सभी शब्‍दों, नामों और वाक्यांशों को पढ़ने देता है जो संभवत: उपयोगकर्ता द्वारा उपयोगकर्ता ‍शब्दकोश में संग्रहीत किए गए हों."</string>
     <string name="permlab_writeDictionary" msgid="2183110402314441106">"उपयोगकर्ता द्वारा परिभाषित शब्दकोश में शब्द जोड़ें"</string>
     <string name="permdesc_writeDictionary" msgid="8185385716255065291">"ऐप्स  को उपयोगकर्ता शब्दकोश में नए शब्द लिखने देता है."</string>
-    <string name="permlab_sdcardRead" product="nosdcard" msgid="367275095159405468">"अपने USB संग्रहण की सामग्री पढ़ें"</string>
+    <string name="permlab_sdcardRead" product="nosdcard" msgid="367275095159405468">"अपने USB मेमोरी की सामग्री पढ़ें"</string>
     <string name="permlab_sdcardRead" product="default" msgid="2188156462934977940">"अपने SD कार्ड की सामग्री पढ़ें"</string>
-    <string name="permdesc_sdcardRead" product="nosdcard" msgid="3446988712598386079">"एप्‍लिकेशन को आपके USB संग्रहण की सामग्री पढ़ने की अनुमति देता है."</string>
+    <string name="permdesc_sdcardRead" product="nosdcard" msgid="3446988712598386079">"एप्‍लिकेशन को आपके USB मेमोरी की सामग्री पढ़ने की अनुमति देता है."</string>
     <string name="permdesc_sdcardRead" product="default" msgid="2607362473654975411">"एप्‍लिकेशन को आपके SD कार्ड की सामग्री पढ़ने की अनुमति देता है."</string>
-    <string name="permlab_sdcardWrite" product="nosdcard" msgid="8485979062254666748">"अपने USB संग्रहण की सामग्री बदलें या हटाएं"</string>
+    <string name="permlab_sdcardWrite" product="nosdcard" msgid="8485979062254666748">"अपने USB मेमोरी की सामग्री बदलें या हटाएं"</string>
     <string name="permlab_sdcardWrite" product="default" msgid="8805693630050458763">"अपने SD कार्ड की सामग्री बदलें या हटाएं"</string>
-    <string name="permdesc_sdcardWrite" product="nosdcard" msgid="6175406299445710888">"ऐप्स को USB संग्रहण में लिखने देता है."</string>
+    <string name="permdesc_sdcardWrite" product="nosdcard" msgid="6175406299445710888">"ऐप्स को USB मेमोरी में लिखने देता है."</string>
     <string name="permdesc_sdcardWrite" product="default" msgid="4337417790936632090">"ऐप्स  को SD कार्ड पर लिखने देता है."</string>
-    <string name="permlab_mediaStorageWrite" product="default" msgid="6859839199706879015">"आंतरिक मीडिया संग्रहण सामग्रियों को बदलें/हटाएं"</string>
-    <string name="permdesc_mediaStorageWrite" product="default" msgid="8189160597698529185">"ऐप्स  को आंतरिक मीडिया संग्रहण की सामग्री को संशोधित करने देता है."</string>
-    <string name="permlab_manageDocs" product="default" msgid="5778318598448849829">"दस्तावेज़ संग्रहण प्रबंधित करें"</string>
-    <string name="permdesc_manageDocs" product="default" msgid="8704323176914121484">"ऐप्स  को दस्तावेज़ संग्रहण प्रबंधित करने की अनुमति दें."</string>
-    <string name="permlab_sdcardAccessAll" msgid="8150613823900460576">"सभी उपयोगकर्ताओं के बाहरी संग्रहण तक पहुंचें"</string>
-    <string name="permdesc_sdcardAccessAll" msgid="3215208357415891320">"ऐप्स  को सभी उपयोगकर्ताओं के बाहरी संग्रहण तक पहुंचने दें."</string>
+    <string name="permlab_mediaStorageWrite" product="default" msgid="6859839199706879015">"आंतरिक मीडिया मेमोरी सामग्रियों को बदलें/हटाएं"</string>
+    <string name="permdesc_mediaStorageWrite" product="default" msgid="8189160597698529185">"ऐप्स  को आंतरिक मीडिया मेमोरी की सामग्री को संशोधित करने देता है."</string>
+    <string name="permlab_manageDocs" product="default" msgid="5778318598448849829">"दस्तावेज़ मेमोरी प्रबंधित करें"</string>
+    <string name="permdesc_manageDocs" product="default" msgid="8704323176914121484">"ऐप्स  को दस्तावेज़ मेमोरी प्रबंधित करने की अनुमति दें."</string>
+    <string name="permlab_sdcardAccessAll" msgid="8150613823900460576">"सभी उपयोगकर्ताओं के बाहरी मेमोरी तक पहुंचें"</string>
+    <string name="permdesc_sdcardAccessAll" msgid="3215208357415891320">"ऐप्स  को सभी उपयोगकर्ताओं के बाहरी मेमोरी तक पहुंचने दें."</string>
     <string name="permlab_cache_filesystem" msgid="5656487264819669824">"कैश फ़ाइल सिस्‍टम में पहंचे"</string>
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ऐप्स को संचय फ़ाइल सिस्‍टम पढ़ने और लिखने देता है."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP कॉल करें/प्राप्‍त करें"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"ऐप्स को SIP कॉल करने और प्राप्‍त करने देती है."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"इन-कॉल स्क्रीन से सहभागिता करें"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ऐप्लिकेशन को यह नियंत्रित करने देती है कि उपयोगकर्ता को इन-कॉल स्क्रीन कब और कैसी दिखाई देती है."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"इन-कॉल स्क्रीन से सहभागिता करें"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ऐप्स को यह नियंत्रित करने देती है कि उपयोगकर्ता को इन-कॉल स्क्रीन कब और कैसी दिखाई देती है."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"टेलीफ़ोनी सेवाओं के साथ सहभागिता करें"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"कॉल करने/प्राप्‍त करने के लिए ऐप्स को टेलीफ़ोनी सेवा के साथ सहभागिता करने दें."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"इन कॉल उपयोगकर्ता अनुभव प्रदान करना"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ऐप्स को इन कॉल उपयोगकर्ता अनुभव लेने देती है."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ऐतिहासिक नेटवर्क उपयोग पढें"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"किसी ऐप्स  को विशिष्ट नेटवर्क और ऐप्स के लिए ऐतिहासिक नेटवर्क उपयोग को पढ़ने देता है."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"नेटवर्क नीति प्रबंधित करें"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"धारक को सूचना श्रवणकर्ता सेवा के शीर्ष स्तरीय इंटरफ़ेस से जुड़ने देती है. सामान्य ऐप्स  के लिए कभी भी आवश्यक नहीं होनी चाहिए."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"किसी स्थिति प्रदाता सेवा से आबद्ध हों"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"धारक को किसी स्थिति प्रदाता सेवा के शीर्ष-स्तर के इंटरफ़ेस से आबद्ध होने देती है. सामान्य ऐप्स के लिए कभी भी आवश्यक नहीं होना चाहिए."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"मीडिया रूट सेवा से आबद्ध हों"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"धारक को मीडिया रूट सेवा के शीर्ष-स्तर के इंटरफ़ेस से आबद्ध होने देती है. सामान्य ऐप्स के लिए कभी भी आवश्यक नहीं होना चाहिए."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"भावी सेवा से आबद्ध करें"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"धारक को किसी भावी सेवा के शीर्ष-स्तर इंटरफ़ेस से आबद्ध होने देता है. सामान्य ऐप्स के लिए कभी भी आवश्‍यक नहीं होना चाहिए."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"वाहक के द्वारा उपलब्ध कराया गया कॉन्फ़िगरेशन ऐप्स  प्रारंभ करें"</string>
@@ -761,10 +759,10 @@
     <string name="policydesc_wipeData" product="tablet" msgid="4306184096067756876">"फ़ैक्टरी डेटा रीसेट करके, बिना चेतावनी के टेबलेट का डेटा मिटाएं."</string>
     <string name="policydesc_wipeData" product="default" msgid="5096895604574188391">"फ़ैक्‍टरी डेटा रीसेट करके, बिना चेतावनी के फ़ोन का डेटा मिटाएं."</string>
     <string name="policylab_setGlobalProxy" msgid="2784828293747791446">"उपकरण वैश्विक प्रॉक्‍सी सेट करें"</string>
-    <string name="policydesc_setGlobalProxy" msgid="6387497466660154931">"नीति सक्षम होने के दौरान उपकरण वैश्विक प्रॉक्‍सी सेट करें. केवल पहला उपकरण व्‍यवस्‍थापक, प्रभावी वैश्विक प्रॉक्‍सी सेट करता है."</string>
+    <string name="policydesc_setGlobalProxy" msgid="6387497466660154931">"नीति सक्षम होने के दौरान उपकरण वैश्विक प्रॉक्‍सी सेट करें. केवल पहला डिवाइस नियंत्रक, प्रभावी वैश्विक प्रॉक्‍सी सेट करता है."</string>
     <string name="policylab_expirePassword" msgid="885279151847254056">"स्‍क्रीन लॉक करें पासवर्ड समाप्ति सेट करें"</string>
     <string name="policydesc_expirePassword" msgid="1729725226314691591">"नियंत्रित करें कि कितने समय में लॉक-स्‍क्रीन पासवर्ड बदला जाना चाहिए."</string>
-    <string name="policylab_encryptedStorage" msgid="8901326199909132915">"संग्रहण एन्‍क्रिप्‍शन सेट करें"</string>
+    <string name="policylab_encryptedStorage" msgid="8901326199909132915">"मेमोरी एन्‍क्रिप्‍शन सेट करें"</string>
     <string name="policydesc_encryptedStorage" msgid="2637732115325316992">"संग्रहीत ऐप्स डेटा को एन्क्रिप्ट किया जाना आवश्‍यक है."</string>
     <string name="policylab_disableCamera" msgid="6395301023152297826">"कैमरों को अक्षम करें"</string>
     <string name="policydesc_disableCamera" msgid="2306349042834754597">"सभी उपकरण कैमरों का उपयोग रोकें."</string>
@@ -914,8 +912,8 @@
     <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"फ़ोन में कोई सिम कार्ड नहीं है."</string>
     <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"कोई सिमकार्ड डालें."</string>
     <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"सिम कार्ड गुम है या पढ़ने योग्‍य नहीं है. कोई सिम कार्ड डालें."</string>
-    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"अनुपयोगी SIM कार्ड."</string>
-    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"आपका सिम कार्ड स्‍थायी रूप से अक्षम कर दिया गया है.\n दूसरे SIM कार्ड के लिए अपने वायरलेस सेवा प्रदाता से संपर्क करें."</string>
+    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"अनुपयोगी सिम कार्ड."</string>
+    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"आपका सिम कार्ड स्‍थायी रूप से अक्षम कर दिया गया है.\n दूसरे सिम कार्ड के लिए अपने वायरलेस सेवा प्रदाता से संपर्क करें."</string>
     <string name="lockscreen_transport_prev_description" msgid="6300840251218161534">"पिछला ट्रैक"</string>
     <string name="lockscreen_transport_next_description" msgid="573285210424377338">"अगला ट्रैक"</string>
     <string name="lockscreen_transport_pause_description" msgid="3980308465056173363">"रोकें"</string>
@@ -958,7 +956,7 @@
     <string name="lockscreen_access_pattern_detected" msgid="4988730895554057058">"आकार पूरा किया गया"</string>
     <string name="keyguard_accessibility_widget_changed" msgid="5678624624681400191">"%1$s. %3$d विजेट में से %2$d."</string>
     <string name="keyguard_accessibility_add_widget" msgid="8273277058724924654">"विजेट जोड़ें"</string>
-    <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"रिक्त"</string>
+    <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"खाली"</string>
     <string name="keyguard_accessibility_unlock_area_expanded" msgid="2278106022311170299">"अनलॉक क्षेत्र को विस्तृत कर दिया गया."</string>
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"अनलॉक क्षेत्र को संक्षिप्त कर दिया गया."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> विजेट."</string>
@@ -993,7 +991,7 @@
     <string name="js_dialog_title" msgid="1987483977834603872">"\'<xliff:g id="TITLE">%s</xliff:g>\' पर यह पृष्ठ दर्शाता है:"</string>
     <string name="js_dialog_title_default" msgid="6961903213729667573">"JavaScript"</string>
     <string name="js_dialog_before_unload_title" msgid="2619376555525116593">"मार्गदर्शक की पुष्टि करें"</string>
-    <string name="js_dialog_before_unload_positive_button" msgid="3112752010600484130">"इस पृष्ठ को छोड़ें"</string>
+    <string name="js_dialog_before_unload_positive_button" msgid="3112752010600484130">"इस पृष्ठ से आगे बढ़ें"</string>
     <string name="js_dialog_before_unload_negative_button" msgid="5614861293026099715">"इस पृष्ठ पर बने रहें"</string>
     <string name="js_dialog_before_unload" msgid="3468816357095378590">"<xliff:g id="MESSAGE">%s</xliff:g>\n\nक्या आप वाकई इस पृष्ठ से दूर नेविगेट करना चाहते हैं?"</string>
     <string name="save_password_label" msgid="6860261758665825069">"पुष्टि करें"</string>
@@ -1046,7 +1044,7 @@
     <string name="save_password_remember" msgid="6491879678996749466">"याद रखें"</string>
     <string name="save_password_never" msgid="8274330296785855105">"कभी नहीं"</string>
     <string name="open_permission_deny" msgid="7374036708316629800">"आपके पास इस पृष्ठ को खोलने की अनुमति नहीं है."</string>
-    <string name="text_copied" msgid="4985729524670131385">"पाठ की क्‍लिपबोर्ड पर प्रतिलिपि बनाई गई."</string>
+    <string name="text_copied" msgid="4985729524670131385">"लेख की क्‍लिपबोर्ड पर प्रतिलिपि बनाई गई."</string>
     <string name="more_item_label" msgid="4650918923083320495">"अधिक"</string>
     <string name="prepend_shortcut_label" msgid="2572214461676015642">"मेनू+"</string>
     <string name="menu_space_shortcut_label" msgid="2410328639272162537">"space"</string>
@@ -1177,20 +1175,20 @@
     <string name="replace" msgid="5781686059063148930">"बदलें•"</string>
     <string name="delete" msgid="6098684844021697789">"हटाएं"</string>
     <string name="copyUrl" msgid="2538211579596067402">"URL की प्रतिलिपि बनाएं"</string>
-    <string name="selectTextMode" msgid="1018691815143165326">"पाठ को चुनें"</string>
-    <string name="textSelectionCABTitle" msgid="5236850394370820357">"पाठ चयन"</string>
+    <string name="selectTextMode" msgid="1018691815143165326">"लेख को चुनें"</string>
+    <string name="textSelectionCABTitle" msgid="5236850394370820357">"लेख चयन"</string>
     <string name="addToDictionary" msgid="4352161534510057874">"शब्दकोश में जोड़ें"</string>
     <string name="deleteText" msgid="6979668428458199034">"हटाएं"</string>
     <string name="inputMethod" msgid="1653630062304567879">"इनपुट विधि"</string>
-    <string name="editTextMenuTitle" msgid="4909135564941815494">"पाठ क्रियाएं"</string>
-    <string name="low_internal_storage_view_title" msgid="5576272496365684834">"संग्रहण स्‍थान समाप्‍त हो रहा है"</string>
+    <string name="editTextMenuTitle" msgid="4909135564941815494">"लेख क्रियाएं"</string>
+    <string name="low_internal_storage_view_title" msgid="5576272496365684834">"मेमोरी स्‍थान समाप्‍त हो रहा है"</string>
     <string name="low_internal_storage_view_text" msgid="6640505817617414371">"हो सकता है कुछ सिस्टम फ़ंक्शन कार्य न करें"</string>
     <string name="app_running_notification_title" msgid="8718335121060787914">"<xliff:g id="APP_NAME">%1$s</xliff:g> चल रहा है"</string>
     <string name="app_running_notification_text" msgid="4653586947747330058">"अधिक जानकारी के लिए या ऐप्स  रोकने के लिए स्पर्श करें."</string>
     <string name="ok" msgid="5970060430562524910">"ठीक है"</string>
-    <string name="cancel" msgid="6442560571259935130">"रद्द करें"</string>
+    <string name="cancel" msgid="6442560571259935130">"रहने दें"</string>
     <string name="yes" msgid="5362982303337969312">"ठीक है"</string>
-    <string name="no" msgid="5141531044935541497">"रद्द करें"</string>
+    <string name="no" msgid="5141531044935541497">"रहने दें"</string>
     <string name="dialog_alert_title" msgid="2049658708609043103">"ध्यानाकर्षण"</string>
     <string name="loading" msgid="7933681260296021180">"लोड हो रहे हैं..."</string>
     <string name="capital_on" msgid="1544682755514494298">"चालू"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s से साझा करें"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"होम ऐप्लिकेशन चुनें"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"इस क्रिया के लिए डिफ़ॉल्‍ट रूप से उपयोग करें."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"किसी भिन्न ऐप्स का उपयोग करें"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"सिस्‍टम सेटिंग &gt; Apps &gt; डाउनलोड किए गए में डिफ़ॉल्‍ट साफ करें."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"कोई क्रिया चुनें"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB उपकरण के लिए कोई ऐप्स  चुनें"</string>
@@ -1241,7 +1240,7 @@
     <string name="old_app_description" msgid="2082094275580358049">"नया ऐप्स प्रारंभ न करें."</string>
     <string name="new_app_action" msgid="5472756926945440706">"<xliff:g id="OLD_APP">%1$s</xliff:g> प्रारंभ करें"</string>
     <string name="new_app_description" msgid="1932143598371537340">"पुराने ऐप्स को बिना सहेजे बंद करें."</string>
-    <string name="sendText" msgid="5209874571959469142">"पाठ के लिए किसी क्रिया को चुनें"</string>
+    <string name="sendText" msgid="5209874571959469142">"लेख के लिए किसी क्रिया को चुनें"</string>
     <string name="volume_ringtone" msgid="6885421406845734650">"रिंगर वॉल्‍यूम"</string>
     <string name="volume_music" msgid="5421651157138628171">"मीडिया वॉल्‍यूम"</string>
     <string name="volume_music_hint_playing_through_bluetooth" msgid="9165984379394601533">"ब्लूटूथ द्वारा चलाया जा रहा है"</string>
@@ -1275,10 +1274,10 @@
     <skip />
     <string name="wifi_watchdog_network_disabled" msgid="7904214231651546347">"वाई-फ़ाई  से कनेक्‍ट नहीं हो सका"</string>
     <string name="wifi_watchdog_network_disabled_detailed" msgid="5548780776418332675">" के पास एक कमज़ोर इंटरनेट कनेक्‍शन है."</string>
-    <string name="wifi_p2p_dialog_title" msgid="97611782659324517">"वाई-फ़ाई  प्रत्यक्ष"</string>
+    <string name="wifi_p2p_dialog_title" msgid="97611782659324517">"वाई-फ़ाई डायरेक्ट"</string>
     <string name="wifi_p2p_turnon_message" msgid="2909250942299627244">"वाई-फ़ाई  डायरेक्ट प्रारंभ करें. इससे वाई-फ़ाई  क्‍लाइंट/हॉटस्पॉट कार्यवाही बंद हो जाएगी."</string>
     <string name="wifi_p2p_failed_message" msgid="3763669677935623084">"वाई-फ़ाई  डायरेक्ट प्रारंभ नहीं किया जा सका."</string>
-    <string name="wifi_p2p_enabled_notification_title" msgid="2068321881673734886">"वाई-फ़ाई  प्रत्यक्ष चालू है"</string>
+    <string name="wifi_p2p_enabled_notification_title" msgid="2068321881673734886">"वाई-फ़ाई डायरेक्ट चालू है"</string>
     <string name="wifi_p2p_enabled_notification_message" msgid="1638949953993894335">"सेटिंग के लिए स्‍पर्श करें"</string>
     <string name="accept" msgid="1645267259272829559">"स्वीकार करें"</string>
     <string name="decline" msgid="2112225451706137894">"अस्वीकार करें"</string>
@@ -1296,16 +1295,16 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"अनुमति दें"</string>
     <string name="sms_control_no" msgid="625438561395534982">"अस्वीकार करें"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt;, &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; पर संदेश भेजना चाहता है."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"इससे आपके मोबाइल खाते पर "<font fgcolor="#ffffb060">"शुल्क लग सकते हैं"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"इससे आपके मोबाइल खाते पर शुल्क लगेंगे."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"इससे आपके मोबाइल खाते पर "<b>"शुल्क लग सकता है"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"इससे आपके मोबाइल खाते पर शुल्क लगेगा."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"भेजें"</string>
-    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"रद्द करें"</string>
+    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"रहने दें"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"मेरी पसंद को याद रखें"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"आप इसे बाद में सेटिंग &gt; ऐप्स  में बदल सकते हैं"</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"हमेशा अनुमति दें"</string>
     <string name="sms_short_code_confirm_never_allow" msgid="446992765774269673">"कभी भी अनुमति न दें"</string>
     <string name="sim_removed_title" msgid="6227712319223226185">"सिमकार्ड निकाला गया"</string>
-    <string name="sim_removed_message" msgid="5450336489923274918">"जब तक आप मान्‍य SIM कार्ड डालकर पुन: प्रारंभ नहीं करते, तब तक सेल्युलर नेटवर्क अनुपलब्‍ध रहेगा."</string>
+    <string name="sim_removed_message" msgid="5450336489923274918">"जब तक आप मान्‍य सिम कार्ड डालकर पुन: प्रारंभ नहीं करते, तब तक सेल्युलर नेटवर्क अनुपलब्‍ध रहेगा."</string>
     <string name="sim_done_button" msgid="827949989369963775">"पूर्ण"</string>
     <string name="sim_added_title" msgid="3719670512889674693">"सिम कार्ड जोड़ा गया"</string>
     <string name="sim_added_message" msgid="7797975656153714319">"सेल्युलर नेटवर्क एक्सेस करने के लिए अपना उपकरण पुन: प्रारंभ करें."</string>
@@ -1318,24 +1317,24 @@
     <string name="perms_description_app" msgid="5139836143293299417">"<xliff:g id="APP_NAME">%1$s</xliff:g> द्वारा प्रदत्त."</string>
     <string name="no_permissions" msgid="7283357728219338112">"किसी अनुमति की आवश्‍यकता नहीं है"</string>
     <string name="perm_costs_money" msgid="4902470324142151116">"इससे आपको धन देना पड़ सकता है"</string>
-    <string name="usb_storage_activity_title" msgid="4465055157209648641">"USB विशाल संग्रहण"</string>
+    <string name="usb_storage_activity_title" msgid="4465055157209648641">"USB विशाल मेमोरी"</string>
     <string name="usb_storage_title" msgid="5901459041398751495">"USB कनेक्ट किया गया"</string>
-    <string name="usb_storage_message" product="nosdcard" msgid="3308538094316477839">"आप USB द्वारा अपने कंप्‍यूटर से कनेक्‍ट हो चुके हैं. यदि आप अपने कंप्‍यूटर और Android के USB संग्रहण के बीच फ़ाइलों की प्रतिलिपि बनाना चाहते हैं तो नीचे दिया गया बटन स्‍पर्श करें."</string>
+    <string name="usb_storage_message" product="nosdcard" msgid="3308538094316477839">"आप USB द्वारा अपने कंप्‍यूटर से कनेक्‍ट हो चुके हैं. यदि आप अपने कंप्‍यूटर और Android के USB मेमोरी के बीच फ़ाइलों की प्रतिलिपि बनाना चाहते हैं तो नीचे दिया गया बटन स्‍पर्श करें."</string>
     <string name="usb_storage_message" product="default" msgid="805351000446037811">"आप USB द्वारा अपने कंप्‍यूटर से कनेक्‍ट हैं. यदि आप अपने कंप्‍यूटर और Android के SD कार्ड के बीच फ़ाइलों की प्रतिलिपि बनाना चाहते हैं तो नीचे दिए गए बटन को स्‍पर्श करें."</string>
-    <string name="usb_storage_button_mount" msgid="1052259930369508235">"USB संग्रहण चालू करें"</string>
-    <string name="usb_storage_error_message" product="nosdcard" msgid="3017045217365540658">"USB विशाल संग्रहण के लिए आपके USB संग्रहण का उपयोग करने में समस्‍या है."</string>
-    <string name="usb_storage_error_message" product="default" msgid="2876018512716970313">"USB विशाल संग्रहण के लिए आपके SD कार्ड का उपयोग करने में समस्‍या है."</string>
+    <string name="usb_storage_button_mount" msgid="1052259930369508235">"USB मेमोरी चालू करें"</string>
+    <string name="usb_storage_error_message" product="nosdcard" msgid="3017045217365540658">"USB विशाल मेमोरी के लिए आपके USB मेमोरी का उपयोग करने में समस्‍या है."</string>
+    <string name="usb_storage_error_message" product="default" msgid="2876018512716970313">"USB विशाल मेमोरी के लिए आपके SD कार्ड का उपयोग करने में समस्‍या है."</string>
     <string name="usb_storage_notification_title" msgid="8175892554757216525">"USB कनेक्ट किया गया"</string>
     <string name="usb_storage_notification_message" msgid="939822783828183763">"आपके कंप्‍यूटर में/से फ़ाइल की प्रतिलिपि बनाने के लिए चुनें."</string>
-    <string name="usb_storage_stop_notification_title" msgid="2336058396663516017">"USB संग्रहण बंद करें"</string>
-    <string name="usb_storage_stop_notification_message" msgid="1656852098555623822">"USB संग्रहण बंद करने के लिए स्‍पर्श करें."</string>
-    <string name="usb_storage_stop_title" msgid="660129851708775853">"USB संग्रहण उपयोग में है"</string>
-    <string name="usb_storage_stop_message" product="nosdcard" msgid="4264025280777219521">"USB संग्रहण बंद करने से पहले, अपने कंप्‍यूटर से अपने Android का USB संग्रहण अनमाउंट (\"इजेक्ट\") करें."</string>
-    <string name="usb_storage_stop_message" product="default" msgid="8043969782460613114">"USB संग्रहण बंद करने से पहले, अपने कंप्‍यूटर से अपने Android का SD कार्ड अनमाउंट (\"इजेक्‍ट\") करें."</string>
-    <string name="usb_storage_stop_button_mount" msgid="7060218034900696029">"USB संग्रहण बंद करें"</string>
-    <string name="usb_storage_stop_error_message" msgid="1970374898263063836">"USB संग्रहण बंद करने में कोई समस्‍या हुई थी. जांचें कि आपने USB होस्‍ट अनमाउंट किया है या नहीं, तब पुन: प्रयास करें."</string>
-    <string name="dlg_confirm_kill_storage_users_title" msgid="963039033470478697">"USB संग्रहण चालू करें"</string>
-    <string name="dlg_confirm_kill_storage_users_text" msgid="5100428757107469454">"यदि आप USB संग्रहण चालू करते हैं, तो आपके द्वारा उपयोग किए जा रहे कुछ ऐप्स रुक जाएंगे और हो सकता है कि वे तब तक अनुपलब्‍ध रहें जब तक कि आप USB संग्रहण बंद नहीं कर देते."</string>
+    <string name="usb_storage_stop_notification_title" msgid="2336058396663516017">"USB मेमोरी बंद करें"</string>
+    <string name="usb_storage_stop_notification_message" msgid="1656852098555623822">"USB मेमोरी बंद करने के लिए स्‍पर्श करें."</string>
+    <string name="usb_storage_stop_title" msgid="660129851708775853">"USB मेमोरी उपयोग में है"</string>
+    <string name="usb_storage_stop_message" product="nosdcard" msgid="4264025280777219521">"USB मेमोरी बंद करने से पहले, अपने कंप्‍यूटर से अपने Android का USB मेमोरी अनमाउंट (\"इजेक्ट\") करें."</string>
+    <string name="usb_storage_stop_message" product="default" msgid="8043969782460613114">"USB मेमोरी बंद करने से पहले, अपने कंप्‍यूटर से अपने Android का SD कार्ड अनमाउंट (\"इजेक्‍ट\") करें."</string>
+    <string name="usb_storage_stop_button_mount" msgid="7060218034900696029">"USB मेमोरी बंद करें"</string>
+    <string name="usb_storage_stop_error_message" msgid="1970374898263063836">"USB मेमोरी बंद करने में कोई समस्‍या हुई थी. जांचें कि आपने USB होस्‍ट अनमाउंट किया है या नहीं, तब पुन: प्रयास करें."</string>
+    <string name="dlg_confirm_kill_storage_users_title" msgid="963039033470478697">"USB मेमोरी चालू करें"</string>
+    <string name="dlg_confirm_kill_storage_users_text" msgid="5100428757107469454">"यदि आप USB मेमोरी चालू करते हैं, तो आपके द्वारा उपयोग किए जा रहे कुछ ऐप्स रुक जाएंगे और हो सकता है कि वे तब तक अनुपलब्‍ध रहें जब तक कि आप USB मेमोरी बंद नहीं कर देते."</string>
     <string name="dlg_error_title" msgid="7323658469626514207">"USB कार्यवाही विफल"</string>
     <string name="dlg_ok" msgid="7376953167039865701">"ठीक है"</string>
     <string name="usb_mtp_notification_title" msgid="3699913097391550394">"किसी मीडिया उपकरण के रूप में कनेक्‍ट किया गया"</string>
@@ -1343,44 +1342,44 @@
     <string name="usb_cd_installer_notification_title" msgid="6774712827892090754">"किसी इंस्‍टॉलर के रूप में कनेक्‍ट किया गया"</string>
     <string name="usb_accessory_notification_title" msgid="7848236974087653666">"USB सहायक सामग्री से कनेक्‍ट कि‍या गया"</string>
     <string name="usb_notification_message" msgid="2290859399983720271">"अन्‍य USB विकल्‍पों के लिए स्पर्श करें."</string>
-    <string name="extmedia_format_title" product="nosdcard" msgid="9020092196061007262">"USB संग्रहण फ़ॉर्मेट करें?"</string>
+    <string name="extmedia_format_title" product="nosdcard" msgid="9020092196061007262">"USB मेमोरी फ़ॉर्मेट करें?"</string>
     <string name="extmedia_format_title" product="default" msgid="3648415921526526069">"SD कार्ड प्रारूपित करें?"</string>
-    <string name="extmedia_format_message" product="nosdcard" msgid="3934016853425761078">"आपके USB संग्रहण में संग्रहीत सभी फ़ाइलें मिट जाएंगी. यह क्रिया पूर्ववत नहीं की जा सकती!"</string>
+    <string name="extmedia_format_message" product="nosdcard" msgid="3934016853425761078">"आपके USB मेमोरी में संग्रहीत सभी फ़ाइलें मिट जाएंगी. यह क्रिया पूर्ववत नहीं की जा सकती!"</string>
     <string name="extmedia_format_message" product="default" msgid="14131895027543830">"आपके कार्ड का सभी डेटा खो जाएगा."</string>
     <string name="extmedia_format_button_format" msgid="4131064560127478695">"प्रारूपित करें"</string>
     <string name="adb_active_notification_title" msgid="6729044778949189918">"USB डीबग करना कनेक्ट किया गया"</string>
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB डीबग करना अक्षम करने के लिए स्‍पर्श करें."</string>
     <string name="select_input_method" msgid="8547250819326693584">"कीबोर्ड बदल सकता है"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"कीबोर्ड चुनें"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"भौतिक कीबोर्ड"</string>
+    <string name="show_ime" msgid="9157568568695230830">"इनपुट विधि दिखाएं"</string>
     <string name="hardware" msgid="7517821086888990278">"हार्डवेयर"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"कीबोर्ड लेआउट को चुनें"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"कीबोर्ड लेआउट का चयन करने के लिए स्‍पर्श करें."</string>
     <string name="fast_scroll_alphabet" msgid="5433275485499039199">" ABCDEFGHIJKLMNOPQRSTUVWXYZ"</string>
     <string name="fast_scroll_numeric_alphabet" msgid="4030170524595123610">" 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"</string>
     <string name="candidates_style" msgid="4333913089637062257"><u>"उम्‍मीदवार"</u></string>
-    <string name="ext_media_checking_notification_title" product="nosdcard" msgid="3449816005351468560">"USB संग्रहण तैयार किया जा रहा है"</string>
+    <string name="ext_media_checking_notification_title" product="nosdcard" msgid="3449816005351468560">"USB मेमोरी तैयार किया जा रहा है"</string>
     <string name="ext_media_checking_notification_title" product="default" msgid="5457603418970994050">"SD कार्ड तैयार कर रहा है"</string>
     <string name="ext_media_checking_notification_message" msgid="8287319882926737053">"त्रुटियों की जांच कर रहा है."</string>
-    <string name="ext_media_nofs_notification_title" product="nosdcard" msgid="7788040745686229307">"रिक्त USB संग्रहण"</string>
-    <string name="ext_media_nofs_notification_title" product="default" msgid="780477838241212997">"रिक्त SD कार्ड"</string>
-    <string name="ext_media_nofs_notification_message" product="nosdcard" msgid="7840121067427269500">"USB संग्रहण रिक्त है या उसका फ़ाइल सिस्‍टम असमर्थित है."</string>
-    <string name="ext_media_nofs_notification_message" product="default" msgid="8641065641786923604">"SD कार्ड रिक्त है या इसका फ़ाइल सिस्‍टम असमर्थित है."</string>
-    <string name="ext_media_unmountable_notification_title" product="nosdcard" msgid="2090046769532713563">"क्षतिग्रस्‍त USB संग्रहण"</string>
+    <string name="ext_media_nofs_notification_title" product="nosdcard" msgid="7788040745686229307">"खाली USB मेमोरी"</string>
+    <string name="ext_media_nofs_notification_title" product="default" msgid="780477838241212997">"खाली SD कार्ड"</string>
+    <string name="ext_media_nofs_notification_message" product="nosdcard" msgid="7840121067427269500">"USB मेमोरी खाली है या उसका फ़ाइल सिस्‍टम असमर्थित है."</string>
+    <string name="ext_media_nofs_notification_message" product="default" msgid="8641065641786923604">"SD कार्ड खाली है या इसका फ़ाइल सिस्‍टम असमर्थित है."</string>
+    <string name="ext_media_unmountable_notification_title" product="nosdcard" msgid="2090046769532713563">"क्षतिग्रस्‍त USB मेमोरी"</string>
     <string name="ext_media_unmountable_notification_title" product="default" msgid="6410723906019100189">"क्षतिग्रस्‍त SD कार्ड"</string>
-    <string name="ext_media_unmountable_notification_message" product="nosdcard" msgid="1795917578395333280">"USB संग्रहण क्षतिग्रस्‍त हो गया है. उसे पुन: प्रारूपित करने का प्रयास करें."</string>
+    <string name="ext_media_unmountable_notification_message" product="nosdcard" msgid="1795917578395333280">"USB मेमोरी क्षतिग्रस्‍त हो गया है. उसे पुन: प्रारूपित करने का प्रयास करें."</string>
     <string name="ext_media_unmountable_notification_message" product="default" msgid="1753898567525568253">"SD कार्ड क्षतिग्रस्‍त हो गया है. उसे पुन: प्रारूपित करने का प्रयास करें."</string>
-    <string name="ext_media_badremoval_notification_title" product="nosdcard" msgid="1661683031330951073">"USB संग्रहण अप्रत्‍याशित रूप से निकाला गया"</string>
+    <string name="ext_media_badremoval_notification_title" product="nosdcard" msgid="1661683031330951073">"USB मेमोरी अप्रत्‍याशित रूप से निकाला गया"</string>
     <string name="ext_media_badremoval_notification_title" product="default" msgid="6872152882604407837">"SD कार्ड को अनपेक्षित रूप से निकाल दिया गया"</string>
-    <string name="ext_media_badremoval_notification_message" product="nosdcard" msgid="4329848819865594241">"डेटा हानि से बचने के लिए निकालने से पहले USB संग्रहण अनमाउंट करें."</string>
+    <string name="ext_media_badremoval_notification_message" product="nosdcard" msgid="4329848819865594241">"डेटा हानि से बचने के लिए निकालने से पहले USB मेमोरी अनमाउंट करें."</string>
     <string name="ext_media_badremoval_notification_message" product="default" msgid="7260183293747448241">"डेटा हानि से बचने के लिए निकालने से पहले SD कार्ड अनमाउंट करें."</string>
-    <string name="ext_media_safe_unmount_notification_title" product="nosdcard" msgid="3967973893270360230">"USB संग्रहण निकालने के लिए सुरक्षित है"</string>
+    <string name="ext_media_safe_unmount_notification_title" product="nosdcard" msgid="3967973893270360230">"USB मेमोरी निकालने के लिए सुरक्षित है"</string>
     <string name="ext_media_safe_unmount_notification_title" product="default" msgid="6729801130790616200">"SD कार्ड निकालने के लिए सुरक्षित है"</string>
-    <string name="ext_media_safe_unmount_notification_message" product="nosdcard" msgid="6142195361606493530">"आप USB संग्रहण को सुरक्षित रूप से निकाल सकते हैं."</string>
+    <string name="ext_media_safe_unmount_notification_message" product="nosdcard" msgid="6142195361606493530">"आप USB मेमोरी को सुरक्षित रूप से निकाल सकते हैं."</string>
     <string name="ext_media_safe_unmount_notification_message" product="default" msgid="568841278138377604">"आप SD कार्ड को सुरक्षित रूप से निकाल सकते हैं."</string>
-    <string name="ext_media_nomedia_notification_title" product="nosdcard" msgid="4486377230140227651">"USB संग्रहण निकाला गया"</string>
+    <string name="ext_media_nomedia_notification_title" product="nosdcard" msgid="4486377230140227651">"USB मेमोरी निकाला गया"</string>
     <string name="ext_media_nomedia_notification_title" product="default" msgid="8902518030404381318">"SD कार्ड निकाल दिया गया है"</string>
-    <string name="ext_media_nomedia_notification_message" product="nosdcard" msgid="6921126162580574143">"USB संग्रहण निकाला गया. नया मीडिया सम्‍मिलित करें."</string>
+    <string name="ext_media_nomedia_notification_message" product="nosdcard" msgid="6921126162580574143">"USB मेमोरी निकाला गया. नया मीडिया सम्‍मिलित करें."</string>
     <string name="ext_media_nomedia_notification_message" product="default" msgid="3870120652983659641">"SD कार्ड निकाला गया. एक नया सम्‍मिलित करें."</string>
     <string name="activity_list_empty" msgid="1675388330786841066">"कोई मिलती-जुलती गतिविधि नहीं मिली."</string>
     <string name="permlab_pkgUsageStats" msgid="8787352074326748892">"घटक उपयोग आंकड़ों की नई जानकारी पाएं"</string>
@@ -1388,9 +1387,9 @@
     <string name="permlab_copyProtectedData" msgid="4341036311211406692">"सामग्री की प्रतिलिपि बनाएं"</string>
     <string name="permdesc_copyProtectedData" msgid="4390697124288317831">"ऐप्स  को सामग्री की प्रतिलिपि बनाने के लिए डिफ़ॉल्ट कंटेनर सेवा शुरू करने देता है. सामान्‍य ऐप्स द्वारा उपयोग करने के लिए नहीं."</string>
     <string name="permlab_route_media_output" msgid="1642024455750414694">"मीडिया आउटपुट को रूट करें"</string>
-    <string name="permdesc_route_media_output" msgid="4932818749547244346">"ऐप्स  को मीडिया आउटपुट को अन्य बाहरी उपकरणों पर रूट करने देता है."</string>
-    <string name="permlab_access_keyguard_secure_storage" msgid="7565552237977815047">"कीगार्ड सुरक्षित संग्रहण एक्सेस करें"</string>
-    <string name="permdesc_access_keyguard_secure_storage" msgid="5866245484303285762">"ऐप्स  को कीगार्ड सुरक्षित संग्रहण एक्सेस करने देती है."</string>
+    <string name="permdesc_route_media_output" msgid="4932818749547244346">"ऐप्स  को मीडिया आउटपुट को अन्य बाहरी डिवाइस पर रूट करने देता है."</string>
+    <string name="permlab_access_keyguard_secure_storage" msgid="7565552237977815047">"कीगार्ड सुरक्षित मेमोरी एक्सेस करें"</string>
+    <string name="permdesc_access_keyguard_secure_storage" msgid="5866245484303285762">"ऐप्स  को कीगार्ड सुरक्षित मेमोरी एक्सेस करने देती है."</string>
     <string name="permlab_control_keyguard" msgid="172195184207828387">"कीगार्ड दिखाना और छिपाना नियंत्रित करें"</string>
     <string name="permdesc_control_keyguard" msgid="3043732290518629061">"ऐप्स  को कीगार्ड नियंत्रित करने देती है."</string>
     <string name="permlab_trust_listener" msgid="1765718054003704476">"ट्रस्ट स्थिति बदलावों को सुनें."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"किसी ऐप्लिकेशन को विश्वसनीय एजेंट सेवा से जुडॉव की अनुमति देती है."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"अपडेट और पुनर्प्राप्ति सिस्टम के साथ सहभागिता करें"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"ऐप्लिकेशन को पुनर्प्राप्ति सिस्टम और सिस्टम अपडेट के साथ सहभागिता करने देती है."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"मीडिया प्रोजेक्शन सत्र बनाएं"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"ऐप्लिकेशन को मीडिया प्रोजेक्शन सत्र बनाने देती है. ये सत्र ऐप्लिकेशन को प्रदर्शन और ऑडियो सामग्री कैप्चर करने की क्षमता प्रदान कर सकते हैं. सामान्य ऐप्लिकेशन को इसकी कभी भी आवश्यकता नहीं होगी."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"मीडिया प्रोजेक्शन सत्र प्रबंधित करना"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"ऐप्लिकेशन को मीडिया प्रोजेक्शन सत्र प्रबंधित करने देती है . ये सत्र ऐप्लिकेशन को प्रदर्शन और ऑडियो सामग्री कैप्चर करने की क्षमता देते हैं. सामान्य ऐप्स को इसकी कभी आवश्यकता नहीं होगी."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"इंस्टॉल सत्रों को पढ़ें"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ऐप्लिकेशन को इंस्टॉल सत्रों को पढ़ने देती है. इससे उसे सक्रिय पैकेज इंस्टॉलेशन के बारे में विवरण देखने की अनुमति मिल जाती है."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ज़ूम नियंत्रण के लिए दो बार स्पर्श करें"</string>
@@ -1412,7 +1411,7 @@
     <string name="ime_action_go" msgid="8320845651737369027">"जाएं"</string>
     <string name="ime_action_search" msgid="658110271822807811">"खोजें"</string>
     <string name="ime_action_send" msgid="2316166556349314424">"भेजें"</string>
-    <string name="ime_action_next" msgid="3138843904009813834">"अगला"</string>
+    <string name="ime_action_next" msgid="3138843904009813834">"आगे"</string>
     <string name="ime_action_done" msgid="8971516117910934605">"पूर्ण"</string>
     <string name="ime_action_previous" msgid="1443550039250105948">"पिछला"</string>
     <string name="ime_action_default" msgid="2840921885558045721">"निष्‍पादित करें"</string>
@@ -1425,11 +1424,11 @@
     <string name="deny" msgid="2081879885755434506">"अस्वीकारें"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"अनुमति अनुरोधित"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> खाते के लिए अनुमति\nका अनुरोध किया गया."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"आप इस ऐप्स का उपयोग अपने व्यक्तिगत स्थान में कर रहे हैं"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"आप इस ऐप्स का उपयोग अपने कार्य स्थान में कर रहे हैं"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"आप इस ऐप्स का उपयोग अपनी कार्य प्रोफ़ाइल से बाहर कर रहे हैं"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"आप इस ऐप्स का उपयोग अपनी कार्य प्रोफ़ाइल में कर रहे हैं"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"इनपुट विधि"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"समन्वयन"</string>
-    <string name="accessibility_binding_label" msgid="4148120742096474641">"आसान तरीका"</string>
+    <string name="accessibility_binding_label" msgid="4148120742096474641">"सरल उपयोग"</string>
     <string name="wallpaper_binding_label" msgid="1240087844304687662">"वॉलपेपर"</string>
     <string name="chooser_wallpaper" msgid="7873476199295190279">"वॉलपेपर बदलें"</string>
     <string name="notification_listener_binding_label" msgid="2014162835481906429">"सूचना श्रवणकर्ता"</string>
@@ -1451,8 +1450,8 @@
     <string name="tethered_notification_title" msgid="3146694234398202601">"टेदरिंग या हॉटस्‍पॉट सक्रिय"</string>
     <string name="tethered_notification_message" msgid="6857031760103062982">"सेट करने के लिए स्‍पर्श करें."</string>
     <string name="back_button_label" msgid="2300470004503343439">"वापस जाएं"</string>
-    <string name="next_button_label" msgid="1080555104677992408">"अगला"</string>
-    <string name="skip_button_label" msgid="1275362299471631819">"छोड़ें"</string>
+    <string name="next_button_label" msgid="1080555104677992408">"आगे"</string>
+    <string name="skip_button_label" msgid="1275362299471631819">"अभी नहीं"</string>
     <string name="no_matches" msgid="8129421908915840737">"कोई मिलान नहीं"</string>
     <string name="find_on_page" msgid="1946799233822820384">"पृष्ठ पर ढूंढें"</string>
   <plurals name="matches_found">
@@ -1460,23 +1459,23 @@
     <item quantity="other" msgid="4641872797067609177">"<xliff:g id="TOTAL">%d</xliff:g> में से <xliff:g id="INDEX">%d</xliff:g>"</item>
   </plurals>
     <string name="action_mode_done" msgid="7217581640461922289">"पूर्ण"</string>
-    <string name="progress_unmounting" product="nosdcard" msgid="3923810448507612746">"USB संग्रहण अनमाउंट हो रहा है…"</string>
+    <string name="progress_unmounting" product="nosdcard" msgid="3923810448507612746">"USB मेमोरी अनमाउंट हो रहा है…"</string>
     <string name="progress_unmounting" product="default" msgid="1327894998409537190">"SD कार्ड अनमाउंट किया जा रहा है…"</string>
-    <string name="progress_erasing" product="nosdcard" msgid="4521573321524340058">"USB संग्रहण मिटाया जा रहा है…"</string>
+    <string name="progress_erasing" product="nosdcard" msgid="4521573321524340058">"USB मेमोरी मिटाया जा रहा है…"</string>
     <string name="progress_erasing" product="default" msgid="6596988875507043042">"SD कार्ड मिटाया जा रहा है…"</string>
-    <string name="format_error" product="nosdcard" msgid="6299769563624776948">"USB संग्रहण नहीं मिटाया जा सका."</string>
+    <string name="format_error" product="nosdcard" msgid="6299769563624776948">"USB मेमोरी नहीं मिटाया जा सका."</string>
     <string name="format_error" product="default" msgid="7315248696644510935">"SD कार्ड नहीं मिटाया जा सका."</string>
     <string name="media_bad_removal" msgid="7960864061016603281">"SD कार्ड को अनमाउंट होने से पहले निकाल दिया गया था."</string>
-    <string name="media_checking" product="nosdcard" msgid="418188720009569693">"USB संग्रहण वर्तमान में जांचा जा रहा है."</string>
+    <string name="media_checking" product="nosdcard" msgid="418188720009569693">"USB मेमोरी वर्तमान में जांचा जा रहा है."</string>
     <string name="media_checking" product="default" msgid="7334762503904827481">"SD कार्ड वर्तमान में जांचा जा रहा है."</string>
     <string name="media_removed" msgid="7001526905057952097">"SD कार्ड निकाल दिया गया है."</string>
-    <string name="media_shared" product="nosdcard" msgid="5830814349250834225">"USB संग्रहण का उपयोग वर्तमान में एक कंप्‍यूटर द्वारा किया जा रहा है."</string>
+    <string name="media_shared" product="nosdcard" msgid="5830814349250834225">"USB मेमोरी का उपयोग वर्तमान में एक कंप्‍यूटर द्वारा किया जा रहा है."</string>
     <string name="media_shared" product="default" msgid="5706130568133540435">"SD कार्ड का उपयोग वर्तमान में एक कंप्‍यूटर द्वारा किया जा रहा है."</string>
     <string name="media_unknown_state" msgid="729192782197290385">"बाह्य मीडिया अज्ञात स्‍थिति में है."</string>
     <string name="share" msgid="1778686618230011964">"साझा करें"</string>
     <string name="find" msgid="4808270900322985960">"ढूंढें"</string>
     <string name="websearch" msgid="4337157977400211589">"वेब खोज"</string>
-    <string name="find_next" msgid="5742124618942193978">"अगला ढूंढें"</string>
+    <string name="find_next" msgid="5742124618942193978">"आगे ढूंढें"</string>
     <string name="find_previous" msgid="2196723669388360506">"पिछला ढूंढें"</string>
     <string name="gpsNotifTicker" msgid="5622683912616496172">"<xliff:g id="NAME">%s</xliff:g> की ओर से स्‍थान अनुरोध"</string>
     <string name="gpsNotifTitle" msgid="5446858717157416839">"स्‍थान अनुरोध"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"घंटे कम करें"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"सायं सेट करें"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"प्रात: सेट करें"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"अप"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"पू"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"माह बढ़ाएं"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"माह कम करें"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"दिन बढ़ाएं"</string>
@@ -1510,7 +1507,7 @@
     <string name="date_picker_increment_year_button" msgid="6318697384310808899">"वर्ष बढ़ाएं"</string>
     <string name="date_picker_decrement_year_button" msgid="4482021813491121717">"वर्ष कम करें"</string>
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Alt"</string>
-    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"रद्द करें"</string>
+    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"रहने दें"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"हटाएं"</string>
     <string name="keyboardview_keycode_done" msgid="1992571118466679775">"पूर्ण"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"Mode change"</string>
@@ -1529,17 +1526,17 @@
     <string name="action_menu_overflow_description" msgid="2295659037509008453">"अधिक विकल्प"</string>
     <string name="action_bar_home_description_format" msgid="7965984360903693903">"%1$s, %2$s"</string>
     <string name="action_bar_home_subtitle_description_format" msgid="6985546530471780727">"%1$s, %2$s, %3$s"</string>
-    <string name="storage_internal" msgid="4891916833657929263">"मोबाइल संग्रहण"</string>
+    <string name="storage_internal" msgid="4891916833657929263">"मोबाइल मेमोरी"</string>
     <string name="storage_sd_card" msgid="3282948861378286745">"SD कार्ड"</string>
-    <string name="storage_usb" msgid="3017954059538517278">"USB संग्रहण"</string>
+    <string name="storage_usb" msgid="3017954059538517278">"USB मेमोरी"</string>
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"संपादित करें"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"डेटा उपयोग की चेतावनी"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"उपयोग व सेटिंग देखने हेतु स्‍पर्श करें."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G डेटा बंद है"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G डेटा बंद है"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"सेल्युलर डेटा बंद है"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"वाई-फ़ाई  डेटा बंद है"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"सीमा पार हो गई है"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G डेटा सीमा पूर्ण हो गई"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G डेटा सीमा पूर्ण हो गई"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"सेल्युलर डेटा सीमा पूर्ण हो गई"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi डेटा की सीमा पूर्ण हो गई"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"शेष चक्र के लिए डेटा रोका गया"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G डेटा सीमा पार हो गई है"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G डेटा सीमा पार हो गई है"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"सेल्युलर डेटा की सीमा पार हो गई"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"कॉल स्वीकार करें?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"हमेशा"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"केवल एक बार"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s कार्य प्रोफ़ाइल का समर्थन नहीं करता."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s कार्य प्रोफ़ाइल का समर्थन नहीं करता"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"टेबलेट"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"फ़ोन"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"हेडफ़ोन"</string>
@@ -1613,7 +1610,7 @@
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"सिम अब अक्षम हो गई है. जारी रखने के लिए PUK कोड डालें. विवरण के लिए कैरियर से संपर्क करें."</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"इच्छित पिन कोड डालें"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"इच्छित पिन कोड की पुष्टि करें"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM कार्ड अनलॉक कर रहा है…"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"सिम कार्ड अनलॉक कर रहा है…"</string>
     <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"गलत PIN कोड."</string>
     <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"ऐसा PIN लिखें, जो 4 से 8 अंकों का हो."</string>
     <string name="kg_invalid_sim_puk_hint" msgid="6025069204539532000">"PUK कोड 8 अंकों का होना चाहिए."</string>
@@ -1638,11 +1635,12 @@
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"आपने अपने अनलॉक आकार को <xliff:g id="NUMBER_0">%d</xliff:g> बार गलत तरीके से आरेखित किया है. <xliff:g id="NUMBER_1">%d</xliff:g> और असफल प्रयासों के बाद, आपसे अपने फ़ोन को किसी ईमेल खाते का उपयोग करके अनलॉक करने के लिए कहा जाएगा.\n\n <xliff:g id="NUMBER_2">%d</xliff:g> सेकंड में पुन: प्रयास करें."</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
     <string name="kg_reordering_delete_drop_target_text" msgid="7899202978204438708">"निकालें"</string>
-    <string name="safe_media_volume_warning" product="default" msgid="2276318909314492312">"वॉल्यूम को अनुशंसित स्तर से ऊपर बढ़ाएं?\n\nअत्यधिक वॉल्यूम पर अधिक समय तक सुनने से आपकी सुनने की क्षमता को नुकसान हो सकता है."</string>
+    <string name="safe_media_volume_warning" product="default" msgid="2276318909314492312">"वॉल्यूम को सुझाए गए स्तर से ऊपर बढ़ाएं?\n\nअत्यधिक वॉल्यूम पर अधिक समय तक सुनने से आपकी सुनने की क्षमता को नुकसान हो सकता है."</string>
     <string name="continue_to_enable_accessibility" msgid="1626427372316070258">"आसान तरीका को सक्षम करने के लिए दो अंगुलियों से नीचे दबाए रखें."</string>
     <string name="accessibility_enabled" msgid="1381972048564547685">"आसान तरीका सक्षम कर दी है."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"आसान तरीका रद्द की गई."</string>
     <string name="user_switched" msgid="3768006783166984410">"वर्तमान उपयोगकर्ता <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> पर स्विच किया जा रहा है…"</string>
     <string name="owner_name" msgid="2716755460376028154">"स्वामी"</string>
     <string name="error_message_title" msgid="4510373083082500195">"त्रुटि"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"यह बदलाव आपके व्यवस्थापक द्वारा अनुमत नहीं है"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> चयनित"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> को हटा दिया गया"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"कार्यस्थल का <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"इस स्‍क्रीन को अनपिन करने के लिए, वापस और हाल ही के एक साथ दबाकर रखें."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"इस स्‍क्रीन को अनपिन करने के लिए, हाल ही के दबाकर रखें."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"स्‍क्रीन पिन की गई है. आपके संगठन के द्वारा अनपिन करने की अनुमति नहीं है."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"स्‍क्रीन पिन करने का उपयोग करें?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"स्‍क्रीन को पिन करने से प्रदर्शन एकल दृश्‍य में लॉक हो जाता है.\n\nबाहर निकलने के लिए, वापस और हाल ही के एक साथ दबाकर रखें."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"स्‍क्रीन को पिन करने से प्रदर्शन एकल दृश्‍य में लॉक हो जाता है.\n\nबाहर निकलने के लिए, हाल ही के दबाकर रखें."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"नहीं, धन्यवाद"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"प्रारंभ करें"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"पिन"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"पैटर्न अनलॉक करें"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"पासवर्ड"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"स्‍क्रीन पिन की गई"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"स्‍क्रीन अनपिन की गई"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"अनपिन करने से पहले पिन के लिए पूछें"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"अनपिन करने से पहले अनलॉक पैटर्न के लिए पूछें"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"अनपिन करने से पहले पासवर्ड के लिए पूछें"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"बैटरी के जीवन काल को बेहतर बनाने में सहायता के लिए, बैटरी सेवर आपके उपकरण के प्रदर्शन को घटा देता है तथा कंपन और अधिकांश पृष्ठभूमि डेटा को सीमित कर देता है. ईमेल, संदेश सेवा और अन्य ऐप्स जो समन्वयन पर निर्भर करते हैं वे तब तक अपडेट नहीं हो सकते जब तक कि आप उन्हें नहीं खोलते.\n\nजब आपका उपकरण चार्ज हो रहा होता है तो बैटरी सेवर अपने आप बंद हो जाता है."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"जब तक कि <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> बजे आपका डाउनटाइम समाप्‍त न हो"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"एक मिनट के लिए"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d मिनट के लिए"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"एक घंटे के लिए"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d घंटे के लिए"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्चित समय तक"</string>
 </resources>
diff --git a/core/res/res/values-hr/strings.xml b/core/res/res/values-hr/strings.xml
index 4e434f4..172587f 100644
--- a/core/res/res/values-hr/strings.xml
+++ b/core/res/res/values-hr/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Nositelju omogućuje vezanje uza sučelje najviše razine udaljenog zaslona. Ne bi smjelo biti potrebno za normalne aplikacije."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vezanje na uslugu widgeta"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Nositelju omogućuje vezanje uz sučelje najviše razine usluge widgeta. Ne bi smjelo biti potrebno za normalne aplikacije."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"povezivanje s davateljem usluge usmjeravanja poziva"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Nositelju omogućuje povezivanje s registriranim davateljem usluga usmjeravanja poziva. Nije potrebno za normalne aplikacije."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interakcija s administratorom uređaja"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Nositelju omogućuje slanje namjera administratoru uređaja. Ne bi smjelo biti potrebno za normalne aplikacije."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"povezivanje s TV ulazom"</string>
@@ -575,8 +573,8 @@
     <string name="permdesc_asec_rename" msgid="1794757588472127675">"Aplikaciji omogućuje preimenovanje interne pohrane."</string>
     <string name="permlab_vibrate" msgid="7696427026057705834">"upravljanje vibracijom"</string>
     <string name="permdesc_vibrate" msgid="6284989245902300945">"Aplikaciji omogućuje nadzor nad vibratorom."</string>
-    <string name="permlab_flashlight" msgid="2155920810121984215">"nadzor bljeskalice"</string>
-    <string name="permdesc_flashlight" msgid="6522284794568368310">"Aplikaciji omogućuje upravljanje bljeskalicom."</string>
+    <string name="permlab_flashlight" msgid="2155920810121984215">"upravljanje svjetiljkom"</string>
+    <string name="permdesc_flashlight" msgid="6522284794568368310">"Aplikaciji omogućuje upravljanje svjetiljkom."</string>
     <string name="permlab_manageUsb" msgid="1113453430645402723">"upravljanje postavkama i dozvolama za USB uređaje"</string>
     <string name="permdesc_manageUsb" msgid="7776155430218239833">"Aplikaciji omogućuje upravljanje postavkama i dozvolama za USB uređaje."</string>
     <string name="permlab_accessMtp" msgid="4953468676795917042">"Primjena MTP protokola"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"uključivanje ili isključivanje telefona"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Aplikaciji omogućuje uključivanje i isključivanje tabletnog računala."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Aplikaciji omogućuje uključivanje ili isključivanje telefona."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ponovno postavljanje vremena čekanja zaslona"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Omogućuje aplikaciji ponovno postavljanje vremena čekanja zaslona."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"pokretanje u tvorničkom testnom načinu rada"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Pokrenite kao niskorazinski proizvođački test, uz omogućavanje potpunog pristupa hardveru tabletnog uređaja. Dostupno je samo ako tabletni uređaj radi u proizvođačkom testnom načinu rada."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Pokrenite kao niskorazinski proizvođački test, uz omogućavanje potpunog pristupa telefonskom hardveru. Dostupno je samo ako telefon radi u proizvođačkom testnom načinu rada."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Aplikaciji omogućuje čitanje i pisanje u datotečnom sustavu privremene memorije."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"upućivanje/primanje SIP poziva"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Aplikacija može upućivati i primati SIP pozive."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakcija sa zaslonom tijekom poziva"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Omogućuje aplikaciji upravljanje time kada će i kako korisnik vidjeti zaslon tijekom poziva."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakcija sa zaslonom tijekom poziva"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Omogućuje aplikaciji upravljanje vremenom i načinom na koji se korisniku prikazuje zaslon tijekom poziva."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interakcija s telefonskim uslugama"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Omogućuje aplikacijama interakciju s telefonskim uslugama za uspostavljanje i primanje poziva."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"pružanje korisničkog iskustva tijekom poziva"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Omogućuje aplikaciji pružanje korisničkog iskustva tijekom poziva."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"čitanje povijesti upotrebe mreže"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Aplikaciji omogućuje čitanje povijesti upotrebe mreže za određene mreže i aplikacije."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"Upravljanje mrežnim pravilima"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Nositelju omogućuje vezanje uz sučelje najviše razine usluge slušatelja obavijesti. Ne bi smjelo biti potrebno za uobičajene aplikacije."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"povezivanje s uslugom davatelja uvjeta"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Vlasniku omogućuje povezivanje sa sučeljem najviše razine usluge davatelja uvjeta. Nije potrebno za normalne aplikacije."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"povezivanje s uslugom za usmjeravanje medija"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Korisniku omogućuje vezanje uz sučelje najviše razine usluge za usmjeravanje medija. Ne bi smjelo biti potrebno za uobičajene aplikacije."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"vezanje na Dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Vlasniku omogućuje povezivanje sa sučeljem najviše razine za Dream. Ne bi trebalo biti potrebno za normalne aplikacije."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"pozovi operaterovu aplikaciju za konfiguraciju"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Dijeljenje pomoću aplikacije %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Odaberite aplikaciju na početnom zaslonu"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Koristi se kao zadana postavka za ovu lokaciju."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Upotrijebite neku drugu aplikaciju"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Izbrisati zadano u Postavkama sustava &gt; Aplikacije &gt; Preuzimanja."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Odaberi radnju"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Odabir aplikacije za USB uređaj"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Dopusti"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Odbij"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; želi poslati poruku na &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ovo "<font fgcolor="#ffffb060">"će se možda naplaćivati"</font>" putem vašeg mobilnog računa."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ovo se naplaćuje putem vašeg mobilnog računa."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"To "<b>"će se možda naplatiti"</b>" putem vašeg mobilnog računa."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"To se naplaćuje putem vašeg mobilnog računa."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Pošalji"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Odustani"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Zapamti odabir"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Dodirnite da biste onemogućili rješavanje programske pogreške na USB-u."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Promjena tipkovnice"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Odaberi tipkovnice"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fizička tipkovnica"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Prikaz način unosa"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardver"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Odaberite izgled tipkovnice"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Dodirnite za odabir izgleda tipkovnice."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Omogućuje aplikaciji povezivanje s uslugom agenta za pouzdanost."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interakcija s ažuriranjem i sustavom za oporavak"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Omogućuje aplikaciji interakciju sa sustavom za oporavak i ažuriranjima sustava."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Stvaranje sesija za projiciranje medija"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Omogućuje aplikaciji stvaranje sesija za projiciranje medija. Te sesije mogu omogućiti aplikaciji snimanje zaslona i audiosadržaja. Ne bi trebalo biti potrebno za uobičajene aplikacije."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Upravljanje projekcijskim sesijama multimedije"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Aplikaciji omogućuje upravljanje projekcijskim sesijama multimedije. Ove sesije pružaju aplikacijama mogućnost snimanja zaslona i audiosadržaja. Uobičajene aplikacije vjerojatno neće trebati tu značajku."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Čitanje sesija instaliranja"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Omogućuje aplikaciji čitanje sesija instaliranja. Aplikacija može vidjeti pojedinosti o aktivnim instaliranjima paketa."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Dodirnite dvaput za upravljanje zumiranjem"</string>
@@ -1425,11 +1424,11 @@
     <string name="deny" msgid="2081879885755434506">"Odbij"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Zatražena je dozvola"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Zatražena je dozvola\nza račun <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Upotrebljavate tu aplikaciju u osobnom prostoru"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Upotrebljavate tu aplikaciju u radnom prostoru"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Ovu aplikaciju upotrebljavate izvan svog radnog profila"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Upotrebljavate tu aplikaciju u radnom profilu"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Način unosa"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinkronizacija"</string>
-    <string name="accessibility_binding_label" msgid="4148120742096474641">"Dostupnost"</string>
+    <string name="accessibility_binding_label" msgid="4148120742096474641">"Pristupačnost"</string>
     <string name="wallpaper_binding_label" msgid="1240087844304687662">"Pozadinska slika"</string>
     <string name="chooser_wallpaper" msgid="7873476199295190279">"Promjena pozadinske slike"</string>
     <string name="notification_listener_binding_label" msgid="2014162835481906429">"Slušatelj obavijesti"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Smanjenje sati"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Postavi PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Postavi AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Povećanje mjeseca"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Smanjenje mjeseca"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Povećanje dana"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Uredi"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Upozorenje o upotrebi podataka"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Dod. za prikaz upotrebe i post."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G podaci isključeni"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G podaci isključeni"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobilni podaci isključeni"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi podaci isključeni"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Ograničenje dosegnuto"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Dost. ogr. 2G–3G prijenosa pod."</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Dost. ogr. 4G prijenosa podataka"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Dost. ogr. mob. prijenosa podat."</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Dost. ogr. Wi-Fi prijenosa pod."</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Podaci su pauz. za ostatak cikl."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Prekoračeno ograničenje 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Prekoračeno je ograničenje 4G podataka"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limit mobilnih podataka premašen"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Prihvatiti poziv?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Uvijek"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Samo jednom"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ne podržava radni profil."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ne podržava radni profil"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tabletno računalo"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Slušalice"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Dostupnost je omogućena."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Pristupačnost otkazana."</string>
     <string name="user_switched" msgid="3768006783166984410">"Trenutačni korisnik <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Prebacivanje na korisnika <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Vlasnik"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Pogreška"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Vaš administrator ne dopušta tu promjenu"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Odabrana je stavka <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Izbrisan je broj <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> za posao"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Da biste otkvačili ovaj zaslon, istovremeno dodirnite i zadržite prste na gumbima Natrag i Nedavno."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Da biste otkvačili ovaj zaslon, dodirnite i zadržite prst na gumbu Nedavno."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Zaslon je pričvršćen. Vaša organizacija ne dopušta otkvačivanje."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Želite li upotrijebiti prikvačivanje?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Prikvačivanje zaslona zaključava zaslon u jednom prikazu. \n\n Za izlaz istovremeno dodirnite i zadržite prste na gumbima Natrag i Nedavno."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Prikvačivanje zaslona zaključava zaslon u jednom prikazu.\n\nZa izlazak dodirnite i zadržite prst na gumbu Nedavno."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NE, HVALA"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"POKRENI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"uzorak za otključavanje"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"zaporka"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Zaslon je pričvršćen"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Zaslon je otkvačen"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Traži PIN radi otkvačivanja"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Traži uzorak za otključavanje radi otkvačivanja"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Traži zaporku radi otkvačivanja"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Da bi se produljilo trajanje baterije, ušteda baterije smanjuje rad uređaja i ograničava vibraciju i većinu pozadinskih podataka. Aplikacije za e-poštu, slanje poruka i ostalo koje se oslanjaju na sinkronizaciju možda se neće ažurirati ako ih ne otvorite.\n\nUšteda baterije isključuje se automatski dok se uređaj puni."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Dok razdoblje zastoja ne završi u <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Jednu minutu"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Jedan sat"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d h"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Neodređeno"</string>
 </resources>
diff --git a/core/res/res/values-hu/strings.xml b/core/res/res/values-hu/strings.xml
index d38e841..9516966 100644
--- a/core/res/res/values-hu/strings.xml
+++ b/core/res/res/values-hu/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Lehetővé teszi a használó számára, hogy csatlakozzon egy távoli kijelző legfelső szintű kezelőfelületéhez. A normál alkalmazásoknak erre soha nincs szükségük."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"csatlakozás modulszolgáltatáshoz"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Lehetővé teszi a használó számára, hogy csatlakozzon egy modulszolgáltatás legfelső szintű kezelőfelületéhez. A normál alkalmazásoknak erre soha nincs szüksége."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"csatlakozás egy útvonal-szolgáltatóhoz"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Az eszköz kezelője csatlakozhat bármely regisztrált útvonal-szolgáltatóhoz. A normál alkalmazások esetében erre nincs szükség."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"az eszközkezelő használata"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Lehetővé teszi a tulajdonos számára, hogy célokat küldjön egy eszközkezelőnek. A normál alkalmazásoknak erre soha nincs szüksége."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"csatlakozás tévébemenethez"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"a telefon be- és kikapcsolása"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Lehetővé teszi az alkalmazás számára a táblagép be- és kikapcsolását."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Lehetővé teszi az alkalmazás számára, hogy be- vagy kikapcsolja a telefont."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"a képernyő időkorlátjának visszaállítása"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Lehetővé teszi az alkalmazás számára a képernyő időkorlátjának visszaállítását."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"futtatás gyári tesztüzemmódban"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Alacsony szintű gyári tesztként fut, lehetővé téve a táblagép összes hardverének elérését. Csak akkor érhető el, ha a táblagép gyári teszt üzemmódban fut."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Futtatás alacsony szintű gyártói tesztként, lehetővé téve a telefon hardverének teljes körű elérését. Csak akkor érhető el, ha a telefon gyártói tesztüzemmódban van."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Lehetővé teszi az alkalmazás számára a gyorsítótár-fájlrendszer olvasását és írását."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP-hívások indítása/fogadása"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP-hívások indításának és fogadásának engedélyezése az alkalmazás számára."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakció a hívás közbeni képernyővel"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Lehetővé teszi, hogy az alkalmazás felügyelje, a felhasználók mikor és hogyan láthatják a hívás közbeni képernyőt."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakció a hívás közbeni képernyővel"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Lehetővé teszi, hogy az alkalmazás felügyelje, a felhasználók mikor és hogyan láthatják a hívás közbeni képernyőt."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"együttműködés a telefonos szolgáltatásokkal"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Lehetővé teszi, hogy az alkalmazás a telefonos szolgáltatásokkal együttműködve hívásokat kezdeményezzen/fogadjon."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"hívás közbeni felhasználói élmény biztosítása"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Lehetővé teszi, hogy az alkalmazás hívás közbeni felhasználói élményt biztosítson."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"hálózathasználati előzmények beolvasása"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Lehetővé teszi az alkalmazás számára a hálózathasználati előzmények beolvasását adott hálózatok és alkalmazások esetében."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"hálózati házirend kezelése"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Lehetővé teszi a használó számára, hogy csatlakozzon egy értesítésfigyelő szolgáltatás legfelső szintű felületéhez. A normál alkalmazásoknak erre soha nincs szükségük."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"csatlakozás egy feltételbiztosító szolgáltatáshoz"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Lehetővé teszi a használó számára, hogy csatlakozzon egy feltételbiztosító szolgáltatás legfelső szintű kezelőfelületéhez. A normál alkalmazásoknak erre soha nincs szükségük."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"csatlakozás egy médiaútvonal-szolgáltatáshoz"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Lehetővé teszi a használó számára, hogy csatlakozzon egy médiaútvonal-szolgáltatás legfelső szintű kezelőfelületéhez. A normál alkalmazásoknak erre soha nincs szükségük."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"csatlakozás egy képernyővédő szolgáltatáshoz"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Lehetővé teszi a használó számára, hogy csatlakozzon egy képernyővédő szolgáltatás legfelső szintű kezelőfelületéhez. A normál alkalmazásoknak erre soha nincs szükségük."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"a szolgáltatói konfigurációs alkalmazás hívása"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Megosztás a következővel: %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"A kezdőalkalmazás kiválasztása"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Ez legyen az alapértelmezett program ehhez a művelethez."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Használjon másik alkalmazást"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Alapértelmezés törlése itt: Rendszerbeállítások &gt; Alkalmazások &gt; Letöltve."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Válasszon egy műveletet"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Válasszon egy alkalmazást az USB-eszközhöz"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Engedélyezés"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Elutasítás"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; üzenetet szeretne küldeni &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; számra."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ezzel "<font fgcolor="#ffffb060">"díjtételek keletkezhetnek"</font>" mobilszámláján."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ezzel díjtételek keletkeznek mobilszámláján."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ez "<b>"költségeket eredményezhet"</b>" mobilszámláján."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ez költségeket eredményez mobilszámláján."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Küldés"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Mégse"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"A választás mentése"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Érintse meg az USB hibakeresés kikapcsolásához."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Billentyűzet megváltoztatása"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Billentyűzetek kiválasztása"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fizikai billentyűzet"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Beviteli mód megjelenítése"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardver"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Válasszon billentyűzetkiosztást"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Érintse meg az egyik billentyűzetkiosztás kiválasztásához."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Lehetővé teszi, hogy az alkalmazás egy trust agent szolgáltatáshoz csatlakozzon."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Kapcsolatfelvétel a frissítési és helyreállítási rendszerrel"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Lehetővé teszi egy alkalmazás számára, hogy kapcsolatba lépjen a helyreállítási rendszerrel és a rendszerfrissítésekkel."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Médiakivetítési munkamenetek létrehozása"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Lehetővé teszi egy alkalmazásnak, hogy médiakivetítési munkameneteket hozzon létre. Az ilyen munkamenetek révén az alkalmazások rögzíthetik a vizuális és audiotartalmakat. A normál alkalmazásoknak erre soha nincs szükségük."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Médiakivetítési munkamenetek kezelése"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Lehetővé teszi egy alkalmazásnak, hogy médiakivetítési munkameneteket kezeljen. Az ilyen munkamenetek révén az alkalmazások rögzíthetik a vizuális és audiotartalmakat. A normál alkalmazásoknak erre soha nincs szükségük."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Telepítési munkamenetek olvasása"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Engedélyezi az alkalmazásnak a telepítési munkamenetek olvasását. Ezáltal részleteket kaphat az egyes csomagok éppen folyamatban lévő telepítéséről."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Érintse meg kétszer a nagyítás beállításához"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Elutasítás"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Az engedélykérés megtörtént"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Az engedélykérés megtörtént\na(z) <xliff:g id="ACCOUNT">%s</xliff:g> fiók számára."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Személyes területén használja az alkalmazást"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Munkaterületén használja az alkalmazást"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Ezt az alkalmazást munkaprofilján kívül használja"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Munkaprofiljában már használja az alkalmazást"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Beviteli mód"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Szinkronizálás"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Kisegítő lehetőségek"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Óra értékének csökkentése"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Állítsa du. értékre"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Állítsa de. értékre"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"DU"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"DE"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Hónap értékének növelése"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Hónap értékének csökkentése"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Dátum értékének növelése"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Szerkesztés"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Adathasználati figyelmeztetés"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Érintse meg az adatokért."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"A 2G és 3G nem használható"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"A 4G nem használható"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobiladat-kapcsolat kikapcsolva"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-adatok kikapcsolva"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Elérte a korlátot"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-/3G-adatkorlát elérve"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G-adatkorlát elérve"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobiladat-korlát elérve"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi-adatkorlát elérve"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"A ciklus végéig az adatforgalom szünetel"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Elérte a 2G/3G adatkorlátot"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Elérte a 4G adatkorlátot"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Túllépte a mobiladat-korlátozást"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Fogadja a hívást?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Mindig"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Csak egyszer"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"A(z) %1$s nem támogatja a munkahelyi profilokat."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"A(z) %1$s nem támogatja a munkaprofilokat."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Táblagép"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Fejhallgató"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Hozzáférés engedélyezve"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Hozzáférés megszakítva."</string>
     <string name="user_switched" msgid="3768006783166984410">"<xliff:g id="NAME">%1$s</xliff:g> az aktuális felhasználó."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Átváltás erre: <xliff:g id="NAME">%1$s</xliff:g>..."</string>
     <string name="owner_name" msgid="2716755460376028154">"Tulajdonos"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Hiba"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Rendszergazdája nem engedélyezi ezt a módosítást"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> kiválasztva"</string>
     <string name="deleted_key" msgid="7659477886625566590">"A(z) <xliff:g id="KEY">%1$s</xliff:g> érték törölve"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Munkahelyi <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"A képernyő rögzítésének feloldásához érintse meg és tartsa megérintve egyszerre a Vissza és a Legutóbbi feliratot."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"A képernyő rögzítésének feloldásához érintse meg és tartsa megérintve a Legutóbbi feliratot."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"A képernyő rögzítve van. Szervezete nem engedélyezi a rögzítés feloldását."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Rögzíti a képernyőt?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"A képernyő rögzítése a kijelzőt egyetlen nézetben zárolja.\n\nA kilépéshez érintse meg és tartsa megérintve egyidejűleg a Vissza és Legutóbbi feliratokat."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"A képernyő rögzítése a kijelzőt egyetlen nézetben zárolja.\n\nA kilépéshez érintse meg és tartsa megérintve a Legutóbbi feliratot."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"KÖSZÖNÖM, NEM"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"INDÍT"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN kód"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"feloldási minta"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"jelszó"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Képernyő rögzítve"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Képernyő rögzítése feloldva"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"PIN kód kérése a rögzítés feloldásához"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Feloldási minta kérése a rögzítés feloldásához"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Jelszó kérése a rögzítés feloldásához"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Az akkumulátor üzemidejének növeléséhez az akkumulátorkímélő mód csökkenti az eszköz teljesítményét, valamint korlátozza a rezgést és a legtöbb háttéradatot. Előfordulhat, hogy az e-mailek, az üzenetküldő programok és más alkalmazások, amelyek a szinkronizálás funkciót használják, nem frissülnek addig, amíg meg nem nyitja őket.\n\nAz akkumulátorkímélő mód automatikusan kikapcsol, amikor az eszköz töltődik."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Amíg az állásidő véget nem ér ekkor: <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Egy percen át"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d percen át"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Egy órán át"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d órán át"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Határozatlan ideig"</string>
 </resources>
diff --git a/core/res/res/values-hy-rAM/strings.xml b/core/res/res/values-hy-rAM/strings.xml
index 69c0c60..64d1f9e 100644
--- a/core/res/res/values-hy-rAM/strings.xml
+++ b/core/res/res/values-hy-rAM/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Թույլ է տալիս սեփականատիրոջը միանալ հեռակա էկրանի վերին մակարդակի ինտերֆեյսին: Սովորական ծրագրերի համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"միանալ վիջեթ ծառայությանը"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Թույլ է տալիս սեփականատիրոջը միանալ վիջեթ ծառայության վերին մակարդակի ինտերֆեյսին: Սովորական հավելվածների համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"կապվել երթուղու մատակարարի ծառայությանը"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Թույլ է տալիս տիրոջը կապվել երթուղու մատակարարներից ցանկացածին: Սովորական ծրագրերի համար երբեք անհրաժեշտ չէ:"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"փոխգործակցել սարքի կառավարչի հետ"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Թույլ է տալիս սեփականատիրոջը ուղարկել մտադրություններ սարքի կառավարչին: Սովորական հավելվածների համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"միանալ հեռուստացույցի մուտքին"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"հեռախոսը միացնել կամ անջատել"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Թույլ է տալիս հավելվածին միացնել կամ անջատել գրասալիկը:"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Թույլ է տալիս հավելվածին միացնել կամ անջատել հեռախոսը:"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"վերակայել էկրանի ակտիվության ժամանակը"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Թույլ է տալիս հավելվածին վերակայել էկրանի ակտիվության ժամանակը:"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"աշխատել գործարանային փորձնական ռեժիմում"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Աշխատեցնել որպես արտադրողի ցածր մակարդակի փորձարկում` թույլատրելով գրասալիկի սարքին լիարժեք մուտք: Հասանելի է միայն այն ժամանակ, երբ գրասալիկը աշխատում է արտադրողի փորձնական ռեժիմում:"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Աշխատեցնել որպես արտադրողի ցածր մակարդակի փորձարկում` թույլատրելով լիարժեք մուտք հեռախոսի սարքաշարին: Հասանելի է միայն այն ժամանակ, երբ հեռախոսն աշխատում է արտադրողի փորձնական ռեժիմում:"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Թույլ է տալիս հավելվածին գրել և կարդալ քեշ ֆայլային համակարգը:"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"կատարել կամ ստանալ SIP զանգեր"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ծրագրին թույլ է տալիս կատարել և ստանալ SIP զանգեր:"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"փոխազդել մուտքային զանգի էկրանի հետ"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Թույլ է տալիս ծրագրին վերահսկել՝ երբ և ինչպես է օգտվողը տեսնում մուտքային զանգը էկրանին:"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"փոխազդել մուտքային զանգի էկրանին"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Թույլ է տալիս ծրագրին վերահսկել՝ երբ և ինչպես է օգտվողը տեսնում մուտքային զանգը էկրանին:"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"համագործակցել հեռախոսակապի ծառայությունների հետ"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Թույլատրում է ծրագրին համագործակցել հեռախոսակապի ծառայությունների հետ՝ զանգեր կատարելու/ստանալու համար:"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"Մատակարարել ներզանգային հնարավորություն:"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Թույլ է տալիս ծրագրին մատակարարել ներզանգային հնարավորություն:"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"կարդալ պատմական ցանցի օգտագործումը"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Թույլ է տալիս հավելվածին կարդալ հատուկ ցանցերի և հավելվածների համար ցանցի օգտագործման պատմությունը:"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"կառավարել ցանցի քաղաքականությունը"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Թույլ է տալիս սեփականատիրոջը միանալ ծանուցումները ունկնդրող ծառայության վերին մակարդակի ինտերֆեյսին: Սովորական հավելվածների համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"կապվել պայմանների մատակարարի ծառայությանը"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Թույլ է տալիս սեփականատիրոջը միանալ պայմանների մատակարարների բազային միջերեսին: Սովորական ծրագրերի համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"կապվել մեդիա երթուղու ծառայությանը"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Թույլ է տալիս սեփականատիրոջը միանալ մեդիա երթուղու ծառայության բազային միջերեսին: Սովորական ծրագրերի համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"Միացում էկրանապահների ծառայությանը"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Թույլ է տալիս սեփականատիրոջը միանալ էկրանապահների ծառայության վերին մակարդակի միջերեսին: Սովորական ծրագրերի համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"գործարկել օպերատորի կողմից տրամադրված կազմաձևման ծրագիրը"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Տարածել ըստ %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Ընտրեք հիմնական հավելվածը"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Օգտագործել լռելյայն այս գործողության համար:"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Օգտագործել այլ հավելված"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Մաքրել լռելյայնը Համակարգի կարգավորումներ &gt; Ծրագրեր &gt;Ներբեռնված էջից:"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Ընտրել գործողություն"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Ընտրեք հավելված USB սարքի համար"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Թույլատրել"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Ժխտել"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>-ը&lt;/b&gt; ուզում է հաղորդագրություն ուղարկել &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>-ին&lt;/b&gt;:"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Այս "<font fgcolor="#ffffb060">"-ը կարող է գանձումներ առաջացնել"</font>" ձեր բջջային հաշվի վրա:"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Սրա հետևանքով ձեր բջջային հաշվին կներկայացվի հաշիվ:"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Սա "<b>"կարող է հանգեցնել գանձումների"</b>"՝ ձեր բջջային հաշվից:"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Սա կհանգեցնի գանձումների՝ ձեր բջջային հաշվից:"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Ուղարկել"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Չեղարկել"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Հիշել իմ ընտրությունը"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Հպեք` USB կարգաբերումը կասեցնելու համար:"</string>
     <string name="select_input_method" msgid="8547250819326693584">"Փոխել ստեղնաշարը"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Ընտրել ստեղնաշար"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Ֆիզիկական ստեղնաշար"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Ցուցադրել մուտքագրման եղանակը"</string>
     <string name="hardware" msgid="7517821086888990278">"Սարքաշար"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Ընտրեք ստեղնաշարի դիրքը"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Հպեք` ստեղնաշարի դիրքը ընտրելու համար:"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Հավելվածը կարող է կապակցվել միջանկյալ գործակալի ծառայությանը:"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Փոխազդել թարմացման և վերականգնման համակարգի հետ"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Թույլ է տալիս ծրագրին փոխազդել վերականգնման համակարգի և համակարգի թարմացումների հետ:"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Ստեղծել մեդիայի տեսարձակման աշխատաշրջաններ"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Ծրագրին թույլ է տալիս ստեղծել մեդիայի տեսարձակման աշխատաշրջաններ: Այդ աշխատաշրջանները կարող են ծրագրերին թույլ տալ հավաքագրել էկրանի և աուդիոյի բովանդակությունը: Սովորական հավելվածների համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Կառավարել մեդիայի տեսարձակման աշխատաշրջաններ"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Ծրագրին թույլ է տալիս կառավարել մեդիայի տեսարձակման աշխատաշրջաններ: Այդ աշխատաշրջանները կարող են ծրագրերին թույլ տալ հավաքագրել էկրանի և աուդիոյի բովանդակությունը: Սովորական հավելվածների համար երբևէ չպետք է անհրաժեշտ լինի:"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Կարդալ տեղադրման աշխատաշրջանները"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Ծրագրին թույլ է տալիս կարդալ տեղադրման աշխատաշրջանները: Սա թույլ է տալիս տեղեկանալ փաթեթների ակտիվ տեղադրումների մանրամասներին:"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Հպեք երկու անգամ` դիտափոխման կարգավորման համար"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Մերժել"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Թույլտվության հարցում է արված"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Թույլտվության հարցում է արված\n<xliff:g id="ACCOUNT">%s</xliff:g> հաշվի համար:"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Դուք օգտագործում եք այս ծրագիրը ձեր անձնական տարածքում"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Դուք օգտագործում եք այս ծրագիրը ձեր աշխատանքային տարածքում"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Դուք օգտագործում եք այս հավելվածը ձեր աշխատանքային պրոֆիլից դուրս"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Դուք օգտագործում եք այս հավելվածը ձեր աշխատանքային պրոֆիլում"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Ներածման եղանակը"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Համաժամել"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Մատչելիությունը"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Նվազեցնել ժամը"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Դնել PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Դնել AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ԿՀ"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ԿԱ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Աճեցնել ամիսը"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Նվազեցնել ամիսը"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Աճեցնել օրը"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Խմբագրել"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Տվյալների օգտագործման նախազգուշացում"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Հպեք` օգտագործումը և կարգավորումները տեսնելու համար:"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G տվյալների կապն անջատված է"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G տվյալների կապն անջատված է"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Բջջային տվյալներն անջատված են"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi տվյալներն անջատված են"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Սահմանաչափը սպառվեց"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G տվյալների սահմանաչափը սպառվել է"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G տվյալների սահմանաչափը սպառվել է"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Բջջային տվյալների սահմանաչափը սպառվել է"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi տվյալների սահմանը սպառվել է"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Տվյալները ընդմիվել են ցիկլի հանգստի համար"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G տվյալների սահմանը գերազանցված է"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G տվյալների սահմանը գերազանցվել է"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Բջջային տվյալների չափը սպառվեց"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Ընդունե՞լ զանգը:"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Միշտ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Միայն մեկ անգամ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s-ը չի աջակցում աշխատանքային պրոֆիլներ:"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s-ը չի աջակցում աշխատանքային պրոֆիլներ"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Գրասալիկ"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Հեռախոս"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Ականջակալներ"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Մատչելիությունը միացված է:"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Մուտքի հնարավորությունը չեղարկված է:"</string>
     <string name="user_switched" msgid="3768006783166984410">"Ներկայիս օգտվողը <xliff:g id="NAME">%1$s</xliff:g>:"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Փոխարկվում է <xliff:g id="NAME">%1$s</xliff:g>-ին..."</string>
     <string name="owner_name" msgid="2716755460376028154">"Սեփականատեր"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Սխալ"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Այս փոփոխությունը չի թույլատրվում ձեր ադմինիստրատորի կողմից:"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Ընտրված է <xliff:g id="ITEM">%1$s</xliff:g> տարրը"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> թիվը ջնջված է"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Աշխատանքային <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Այս էկրանը ապամրացնելու համար՝ հպեք և պահեք «Հետ» և «Վերջինները» կոճակները միաժամանակ:"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Այս էկրանն ապամրացնելու համար՝ հպեք և պահեք «Վերջինները» կոճակը:"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Էկրանն ամրացված է: Ապամրացումը չի թույլատրվում ձեր կազմակերպության կողմից:"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Օգտագործե՞լ էկրանի ամրացումը:"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Էկրանի ամրացումը կողպում է էկրանը մեկ պատուհանով:\n\nԴուրս գալու համար՝ հպեք և պահեք «Հետ» և «Վերջինները» կոճակները միաժամանակ:"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Էկրանի ամրացումը կողպում է էկրանը մեկ պատուհանի համար:\n\nԴուրս գալու համար՝ հպեք և պահեք «Վերջինները»:"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ՈՉ, ՇՆՈՐՀԱԿԱԼՈՒԹՅՈՒՆ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"Այո"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ապակողպող նախշ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"գաղտնաբառ"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Էկրանն ամրացված է"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Էկրանն ապամրացված է"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Ապաամրացնելուց առաջ հարցնել PIN-կոդը"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Ապաամրացնելուց առաջ հարցնել ապակողպող նախշը"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Ապաամրացնելուց առաջ հարցնել գաղտնաբառը"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Մարտկոցի աշխատաժամանակը շատացնելու համար մարտկոցի տնտեսումը կնվազեցնի ձեր սարքի կատարողականը և կսահմանափակի թրթռոցն ու ֆոնային տվյալներից շատերը: Էլփոստը, հաղորդագրությունները և այլ ծրագրերը, որոնք  օգտագործում են համաժամեցումը, կթարմանան միայն դրանք աշխատեցնելիս:\n\nՄարկտոցի տնտեսումը ավտոմատ կանջատվի, հենց սարքը միացվի լիցքավորման:"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Մինչև ձեր ժամանակն ավարտվի ժամը <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Մեկ րոպե"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d րոպե"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Մեկ ժամ"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d ժամ"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Անորոշ ժամանակով"</string>
 </resources>
diff --git a/core/res/res/values-in/strings.xml b/core/res/res/values-in/strings.xml
index 465f9d4..5529521 100644
--- a/core/res/res/values-in/strings.xml
+++ b/core/res/res/values-in/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Mengizinkan pemegang mengikat ke antarmuka tingkat atas dari layar jarak jauh. Tidak pernah diperlukan untuk aplikasi normal."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"mengikat ke layanan widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Mengizinkan pemegang mengikat antarmuka tingkat tinggi dari suatu layanan widget. Tidak pernah diperlukan oleh apl normal."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"mengikat ke layanan penyedia rute"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Memungkinkan pemegang mengikat ke penyedia rute terdaftar mana pun. Tidak pernah dibutuhkan untuk aplikasi normal."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"berinteraksi dengan admin perangkat"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Mengizinkan pemegang mengirimkan tujuan kepada administrator perangkat. Tidak pernah diperlukan oleh apl normal."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"mengikat ke masukan TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"daya ponsel hidup atau mati"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Mengizinkan apl menyalakan atau mematikan tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Mengizinkan apl mematikan atau menyalakan ponsel."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"setel ulang batas waktu tampilan"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Memungkinkan aplikasi menyetel ulang batas waktu tampilan."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"jalankan pada mode uji pabrik"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Menjalankan sebagai uji pabrikan tingkat rendah, mengizinkan akses lengkap ke perangkat keras tablet. Hanya tersedia jika tablet berjalan dalam mode uji pabrikan."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Jalankan sebagai uji pabrik tingkat rendah, yang memungkinkan akses penuh pada perangkat keras ponsel. Hanya tersedia ketika ponsel berjalan pada mode uji pabrik."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Mengizinkan apl membaca dan menulis pada sistem file cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"lakukan/terima panggilan SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Izinkan aplikasi melakukan dan menerima panggilan SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"berinteraksi dengan layar dalam panggilan"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Memungkinkan aplikasi mengontrol kapan dan bagaimana pengguna melihat layar dalam panggilan."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"berinteraksi dengan layar dalam panggilan"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Memungkinkan aplikasi mengontrol kapan dan bagaimana pengguna melihat layar dalam panggilan."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"berinteraksi dengan layanan telepon"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Memungkinkan aplikasi berinteraksi dengan layanan telepon untuk melakukan/menerima panggilan."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"memberikan pengalaman pengguna dalam panggilan"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Memungkinkan aplikasi memberikan pengalaman pengguna dalam panggilan."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"baca riwayat penggunaan jaringan"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Mengizinkan apl membaca penggunaan jaringan historis untuk apl dan jaringan tertentu."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"kelola kebijakan jaringan"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Memungkinkan pemegang mengikat antarmuka tingkat teratas dari suatu layanan pendengar pemberitahuan. Tidak pernah diperlukan oleh aplikasi normal."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"mengikat ke layanan penyedia ketentuan"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Memungkinkan pemegang mengikat antarmuka tingkat tinggi dari layanan penyedia ketentuan. Tidak pernah diperlukan oleh aplikasi normal."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"mengikat ke layanan rute media"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Memungkinkan pemegang mengikat antarmuka tingkat tinggi dari layanan rute media. Tidak pernah diperlukan oleh aplikasi normal."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"mengikat ke layanan lamunan"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Memungkinkan pemegang mengikat antarmuka tingkat tinggi dari suatu layanan lamunan. Tidak pernah diperlukan oleh aplikasi normal."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"memanggil aplikasi konfigurasi yang disediakan operator"</string>
@@ -835,7 +833,7 @@
     <string name="phoneTypeAssistant" msgid="5596772636128562884">"Asisten"</string>
     <string name="phoneTypeMms" msgid="7254492275502768992">"MMS"</string>
     <string name="eventTypeCustom" msgid="7837586198458073404">"Khusus"</string>
-    <string name="eventTypeBirthday" msgid="2813379844211390740">"Hari Ulang Tahun"</string>
+    <string name="eventTypeBirthday" msgid="2813379844211390740">"Ulang Tahun"</string>
     <string name="eventTypeAnniversary" msgid="3876779744518284000">"Hari Peringatan"</string>
     <string name="eventTypeOther" msgid="7388178939010143077">"Lainnya"</string>
     <string name="emailTypeCustom" msgid="8525960257804213846">"Khusus"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Bagikan dengan %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Pilih aplikasi beranda"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Gunakan secara default untuk tindakan ini."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Gunakan aplikasi yang berbeda"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Menghapus default di Setelan sistem &gt; Apl &gt; Terunduh."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Pilih tindakan"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Pilih apl untuk perangkat USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Izinkan"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Tolak"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ingin mengirim pesan kepada &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Hal ini "<font fgcolor="#ffffb060">"dapat menyebabkan akun ponsel Anda"</font>" mendapat tagihan."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Hal ini akan menyebabkan tagihan diberlakukan pada akun seluler Anda."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Tindakan ini "<b>"dapat menimbulkan tagihan"</b>" untuk ponsel Anda."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Tindakan ini akan menimbulkan tagihan untuk ponsel Anda."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Kirim"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Batal"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Ingat pilihan saya"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Sentuh untuk menonaktifkan debugging USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Ubah keyboard"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Pilih keyboard"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Keyboard fisik"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Tampilkan metode masukan"</string>
     <string name="hardware" msgid="7517821086888990278">"Perangkat Keras"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Pilih tata letak keyboard"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Sentuh untuk memilih tata letak keyboard."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Mengizinkan aplikasi mengikat ke layanan agen tepercaya."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Berinteraksi dengan sistem pemulihan dan pembaruan"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Mengizinkan aplikasi berinteraksi dengan sistem pemulihan dan pembaruan sistem."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Membuat sesi proyeksi media"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Memungkinkan aplikasi membuat sesi proyeksi media. Sesi ini dapat memberikan kemampuan pada aplikasi untuk menangkap konten audio dan layar. Tidak diperlukan oleh aplikasi normal."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Mengelola sesi proyeksi media"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Memungkinkan aplikasi mengelola sesi proyeksi media. Sesi ini dapat memberikan kemampuan pada aplikasi untuk menangkap konten audio dan layar. Tidak pernah diperlukan oleh aplikasi normal."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Membaca sesi pemasangan"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Memungkinkan aplikasi membaca sesi pemasangan. Tindakan ini memungkinkannya melihat detail tentang pemasangan paket aktif."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Sentuh dua kali untuk mengontrol perbesar/perkecil"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Tolak"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Izin dimintakan"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Izin dimintakan\nuntuk akun <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Anda menggunakan aplikasi ini di ruang pribadi"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Anda menggunakan aplikasi ini di ruang kerja"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Anda menggunakan aplikasi ini di luar profil kerja"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Anda menggunakan aplikasi ini di profil kerja"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Metode masukan"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinkron"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Aksesibilitas"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Kurangi jam"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Menyetel PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Setel AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Tambah bulan"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Kurangi bulan"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Tambah hari"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Peringatan penggunaan data"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Sentuh utk mlht pnggnaan &amp; stln."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Data 2G-3G nonaktif"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Data 4G nonaktif"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Data seluler nonaktif"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Data Wi-Fi nonaktif"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Batas tercapai"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Batas data 2G-3G terlampaui"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Batas data 4G terlampaui"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Batas data seluler terlampaui"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Batas data Wi-Fi terlampaui"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data dijeda untuk sisa periode"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Batas data 2G-3G terlampaui"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Batas data 4G terlampaui"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Batas data seluler terlampaui"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Terima panggilan?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Selalu"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Hanya sekali"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s tidak mendukung profil kerja."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s tidak mendukung profil kerja"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Ponsel"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Headphone"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Aksesibilitas diaktifkan."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Aksesibilitas dibatalkan."</string>
     <string name="user_switched" msgid="3768006783166984410">"Pengguna saat ini <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Beralih ke <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Pemilik"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Kesalahan"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Perubahan ini tidak diizinkan oleh administrator Anda"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> dipilih"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> dihapus"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Kantor <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Untuk melepas sematan layar ini, sentuh lama Kembali dan Terkini secara bersamaan."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Untuk melepas sematan layar ini, sentuh lama Terkini."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Layar disematkan. Pelepasan sematan tidak diizinkan oleh organisasi Anda."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Gunakan penyematan layar?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Penyematan layar mengunci layar dalam tampilan tunggal.\n\nUntuk keluar, sentuh lama Kembali dan Terkini secara bersamaan."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Penyematan layar mengunci layar dalam tampilan tunggal.\n\nUntuk keluar, sentuh lama Terkini."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"TIDAK, TERIMA KASIH"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"MULAI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"pola pembuka kunci"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"sandi"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Layar disematkan"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Layar dicopot sematannya"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Meminta PIN sebelum melepas sematan"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Meminta pola pembukaan kunci sebelum melepas sematan"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Meminta sandi sebelum melepas sematan"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Guna membantu meningkatkan masa pakai baterai, penghemat baterai mengurangi kinerja perangkat dan membatasi getaran serta sebagian besar data latar belakang. Email, perpesanan, dan aplikasi lain yang bergantung pada sinkronisasi mungkin tidak akan diperbarui kecuali Anda membukanya.\n\nPenghemat baterai dinonaktifkan secara otomatis saat perangkat diisi daya."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Hingga waktu perbaikan Anda berakhir pukul <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Selama satu menit"</item>
+    <item quantity="other" msgid="6924190729213550991">"Selama %d menit"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Selama satu jam"</item>
+    <item quantity="other" msgid="5408537517529822157">"Selama %d jam"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Tidak ditentukan"</string>
 </resources>
diff --git a/core/res/res/values-is-rIS/strings.xml b/core/res/res/values-is-rIS/strings.xml
index 716c789..eb66c60 100644
--- a/core/res/res/values-is-rIS/strings.xml
+++ b/core/res/res/values-is-rIS/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Leyfir forriti að bindast efsta viðmótslagi fjartengds skjás. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bindast græjuþjónustu"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Leyfir handhafa að bindast efsta viðmótslagi græjuþjónustu. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bindast þjónustu leiðaveitu"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Leyfir handhafa að bindast öllum veitum skráðra leiða. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"samskipti við stjórnanda tækis"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Leyfir handhafa að senda tilgang til stjórnanda tækis. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bindast sjónvarpsinntaki"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"kveikja eða slökkva á símanum"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Leyfir forriti að kveikja og slökkva á spjaldtölvunni."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Leyfir forriti að kveikja og slökkva á símanum."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"endurstilla tímamörk skjás"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Leyfir forritinu að endurstilla tímamörk skjás."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"keyra í prófunarstillingu verksmiðju"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Keyra sem lágtækniprófun framleiðanda með fullan aðgang að vélbúnaði spjaldtölvunnar. Aðeins í boði þegar spjaldtölva er keyrð í prófunarstillingu framleiðanda."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Keyra sem lágtækniprófun framleiðanda með fullan aðgang að vélbúnaði símans. Aðeins í boði þegar sími er keyrður í prófunarstillingu framleiðanda."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Leyfir forriti að lesa og skrifa í skráakerfi skyndiminnis."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"hringja/svara SIP-símtölum"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Leyfir forritinu að hringja og svara SIP-símtölum."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"eiga samskipti við símtalsskjá"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Leyfir forriti að stjórna því hvenær og hvernig notandi sér símtalsskjá."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"eiga samskipti við símtalsskjá"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Leyfir forriti að stjórna því hvenær og hvernig notandi sér símtalsskjá."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"hafa samskipti við símafyrirtæki"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Leyfir forritinu að hafa samskipti við símafyrirtæki til að hringja/taka á móti símtölum."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"bjóða upp á notendaviðmót innan símtals"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Leyfir forriti að birta notendaviðmót innan símtals."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lesa söguleg gögn um netnotkun"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Leyfir forriti að lesa söguleg gögn um netnotkun fyrir tiltekin net og forrit."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"hafa umsjón með netstefnu"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Leyfir forriti að bindast efsta viðmótslagi hlustunarþjónustu tilkynninga. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bindast þjónustu skilyrðaveitu"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Leyfir handhafa að bindast efsta viðmótslagi skilyrðaveitu. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bindast beiningarþjónustu fyrir margmiðlun"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Leyfir handhafa að bindast efsta viðmótslagi beiningarþjónustu fyrir margmiðlun. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bindast skjávaraþjónustu"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Leyfir handhafa að bindast efsta viðmótslagi skjávaraþjónustu. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ræsa grunnstillingarforrit frá símafyrirtæki"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Deila með %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Veldu heimaforrit"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Nota sjálfgefið fyrir þessa aðgerð."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Nota annað forrit"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Hreinsa sjálfgefna stillingu í Kerfisstillingar &gt; Forrit &gt; Sótt."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Veldu aðgerð"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Veldu forrit fyrir USB-tækið"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Leyfa"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Hafna"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vill senda skilaboð til &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Þetta "<font fgcolor="#ffffb060">"gæti hækkað farsímareikninginn"</font>" þinn."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Þetta mun hækka farsímareikninginn þinn."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Þetta "<b>"kann að leiða til kostnaðar"</b>" á farsímareikningnum þínum."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Þetta mun leiða til kostnaðar á farsímareikningnum þínum."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Senda"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Hætta við"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Muna valið"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Snertu til að slökkva á USB-villuleit."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Skipta um lyklaborð"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Velja lyklaborð"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Vélbúnaðarlyklaborð"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Sýna innsláttaraðferð"</string>
     <string name="hardware" msgid="7517821086888990278">"Vélbúnaður"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Veldu lyklaskipan"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Snertu til að velja lyklaskipan."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Leyfir forriti að bindast traustfulltrúaþjónustu."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Eiga samskipti við uppfærslu- og endurheimtarkerfi"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Leyfir forriti að eiga samskipti við endurheimtarkerfi og kerfisuppfærslur."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Búa til útsendingarlotur fyrir margmiðlunarefni"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Leyfir forriti að búa til útsendingarlotur fyrir margmiðlunarefni. Þessar lotur geta gert forritum kleift að fanga hljóð og mynd. Ætti aldrei að vera nauðsynlegt fyrir venjuleg forrit."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Stjórna útsendingarlotum"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Gefur forrit aðgang að stjórnun útsendingarlota. Þessar lotur geta gefið forritum leyfi til að taka mynd af skjánum og taka upp hljóðefni. Venjuleg forrit ættu aldrei að þurfa á þessu að halda."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Lesa uppsetningarlotur"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Leyfir forriti að lesa uppsetningarlotur. Þetta gerir því kleift að sjá upplýsingar um virkar pakkauppsetningar."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Ýttu tvisvar til að fá upp aðdráttarstýringar"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Hafna"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Beðið um heimild"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Beðið um heimild\nfyrir reikninginn <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Þú ert að nota þetta forrit á persónulega svæðinu þínu"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Þú ert að nota þetta forrit á vinnusvæðinu þínu"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Þú ert að nota þetta forrit utan vinnusniðsins"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Þú ert að nota þetta forrit á vinnusniðinu þínu"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Innsláttaraðferð"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Samstilling"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Aðgengi"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Niður um klukkustund"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Velja e.h."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Velja f.h."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"eh"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"fh"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Upp um mánuð"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Niður um mánuð"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Upp um dag"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Breyta"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Viðvörun vegna gagnanotkunar"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Snertu fyrir uppl. og stillingar"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Slökkt er á 2G- og 3G-gögnum"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Slökkt er á 4G-gögnum"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Slökkt er á farsímagögnum"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Slökkt er á Wi-Fi gögnum"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Hámarki náð"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Gagnahámarki 2G og 3G náð"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Gagnahámarki 4G náð"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Farsímagagnahámarki náð"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Gagnahámarki Wi-Fi náð"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Hlé gert á gagnasendingu við þessa notkun"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Gagnahámarki 2G og 3G náð"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Gagnahámarki 4G náð"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Hámarki farsímagagna náð"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Samþykkja símtal?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Alltaf"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Bara einu sinni"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s styður ekki vinnusnið."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s styður ekki vinnusnið"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Spjaldtölva"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Sími"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Heyrnartól"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Kveikt á auknu aðgengi."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Hætt við aukið aðgengi."</string>
     <string name="user_switched" msgid="3768006783166984410">"Núverandi notandi <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Skiptir yfir á <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Eigandi"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Villa"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Stjórnandinn þinn leyfir ekki þessa breytingu."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> valið"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> eytt"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> í vinnu"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Til að losa þennan skjá skaltu halda inni Til baka og Nýlegt samtímis."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Til að losa þennan skjá skaltu halda inni Nýlegt."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skjárinn er festur. Póstskipanin þín leyfir ekki að hann sé losaður."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Nota skjáfestingu?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Skjáfesting læsir skjánum á eina skjámynd.\n\nTil að hætta skaltu halda inni Til baka og Nýlegt samtímis."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Skjáfesting læsir skjánum á eina skjámynd.\n\nTil að hætta skaltu halda inni Nýlegt."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NEI, TAKK"</string>
-    <string name="lock_to_app_positive" msgid="7085139175671313864">"RÆSA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-númer"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"opnunarmynstur"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"aðgangsorð"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_positive" msgid="7085139175671313864">"BYRJA"</string>
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skjár festur"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skjár opnaður"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Biðja um PIN-númer til að losa"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Biðja um opnunarmynstur til að losa"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Biðja um aðgangsorð til að losa"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Til að auka endingu rafhlöðunnar dregur rafhlöðusparnaður úr afköstum tækisins og takmarkar titring og flest bakgrunnsgögn. Ekki er víst að tölvupóstur, skilaboð og önnur forrit sem reiða sig á samstillingu verði uppfærð fyrr en þú opnar þau.\n\nSjálfkrafa er slökkt á rafhlöðusparnaði þegar tækið er í hleðslu."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Þangað til niðritíma lýkur, <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Í eina mínútu"</item>
+    <item quantity="other" msgid="6924190729213550991">"Í %d mínútur"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Í eina klukkustund"</item>
+    <item quantity="other" msgid="5408537517529822157">"Í %d klukkustundir"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Án tímatakmarkana"</string>
 </resources>
diff --git a/core/res/res/values-it/strings.xml b/core/res/res/values-it/strings.xml
index 13374b7..93707ad 100644
--- a/core/res/res/values-it/strings.xml
+++ b/core/res/res/values-it/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Consente al titolare di collegarsi all\'interfaccia di primo livello di un display remoto. Non dovrebbe essere mai necessaria per le normali applicazioni."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"associazione a un servizio widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Consente l\'associazione all\'interfaccia principale di un servizio widget. Non dovrebbe mai essere necessario per le normali applicazioni."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"collegamento a un servizio provider di routing"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Consente al titolare di collegarsi a qualsiasi provider di routing registrato. Non dovrebbe mai essere necessario per le normali applicazioni."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interazione con un amministratore dispositivo"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Consente l\'invio di intent a un amministratore del dispositivo. L\'autorizzazione non dovrebbe mai essere necessaria per le normali applicazioni."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"collegamento a ingresso TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"accensione o spegnimento del telefono"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Consente all\'applicazione di accendere o spegnere il tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Consente all\'applicazione di accendere o spegnere il telefono."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"reimpostazione del timeout del display"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Consente all\'app di reimpostare il timeout del display."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"esecuzione in modalità test di fabbrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"In esecuzione come test del produttore di basso livello, consentendo l\'accesso completo all\'hardware del tablet. Disponibile soltanto quando il tablet è in esecuzione in modalità test del produttore."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"In esecuzione come test del produttore di basso livello, consentendo l\'accesso completo all\'hardware del telefono. Disponibile soltanto quando il telefono è in esecuzione in modalità test del produttore."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Consente all\'applicazione di leggere e scrivere il filesystem nella cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"fare/ricevere chiamate SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Consente all\'app di effettuare e ricevere chiamate SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interazione con lo schermo durante una chiamata"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Consente all\'app di stabilire quando e come l\'utente vede lo schermo durante una chiamata."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interazione con lo schermo durante una chiamata"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Consente all\'app di stabilire quando e come l\'utente vede lo schermo durante una chiamata."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interagire con i servizi di telefonia"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Consente all\'app di interagire con i servizi di telefonia per effettuare/ricevere chiamate."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"offerta di un\'esperienza utente durante le chiamate"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Consente all\'app di offrire un\'esperienza utente durante le chiamate."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lettura dati storici di utilizzo della rete"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Consente all\'applicazione di leggere dati storici di utilizzo della rete per reti e applicazioni specifiche."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gestione norme rete"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Consente al titolare di vincolarsi all\'interfaccia di primo livello di un servizio listener di notifica. Non dovrebbe mai essere necessaria per le normali applicazioni."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"collegamento a un servizio provider di condizioni"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Consente al titolare di collegarsi all\'interfaccia di primo livello di un servizio provider di condizioni. Non dovrebbe essere mai necessaria per le normali app."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"associa a servizio di routing multimediale"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Consente di eseguire l\'associazione all\'interfaccia di primo livello di un servizio di routing multimediale. Generalmente non necessario per le normali app."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"associa a servizio dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Consente all\'utente di associare l\'interfaccia di primo livello di un servizio dream. Questa impostazione non è mai necessaria per le app normali."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"richiamo dell\'app di configurazione operatore-provider"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Condividi con %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Seleziona un\'app home"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Usa come predefinita per questa azione."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utilizza un\'app diversa"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Cancella l\'applicazione predefinita in Impostazioni di sistema &gt; Applicazioni &gt; Scaricate."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Scegli un\'azione"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Scegli un\'applicazione per il dispositivo USB"</string>
@@ -1243,7 +1242,7 @@
     <string name="new_app_description" msgid="1932143598371537340">"Interrompi la vecchia applicazione senza salvare."</string>
     <string name="sendText" msgid="5209874571959469142">"Scegli un\'azione per il testo"</string>
     <string name="volume_ringtone" msgid="6885421406845734650">"Volume suoneria"</string>
-    <string name="volume_music" msgid="5421651157138628171">"Volume app. multimediali"</string>
+    <string name="volume_music" msgid="5421651157138628171">"Volume contenuti multimediali"</string>
     <string name="volume_music_hint_playing_through_bluetooth" msgid="9165984379394601533">"Riproduzione tramite Bluetooth"</string>
     <string name="volume_music_hint_silent_ringtone_selected" msgid="8310739960973156272">"Suoneria silenziosa impostata"</string>
     <string name="volume_call" msgid="3941680041282788711">"Volume chiamate"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Consenti"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Nega"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vorrebbe inviare un messaggio a &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Potrebbero essere effettuati addebiti"</font>" sul tuo account per cellulari."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Verranno effettuati addebiti sul tuo account per cellulari."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"Potrebbero essere effettuati addebiti"</b>" sull\'account del tuo gestore di telefonia mobile."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Verranno effettuati addebiti sull\'account del tuo gestore di telefonia mobile."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Invia"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Annulla"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Memorizza la mia scelta"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Tocca per disattivare il debug USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Cambia tastiera"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Scegli tastiere"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Tastiera fisica"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostra metodo immissione"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Seleziona layout tastiera"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Tocca per selezionare un layout di tastiera."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Consente a un\'applicazione di associarsi a un agente di attendibilità."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interazione con il sistema di ripristino e aggiornamento"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Consente a un\'applicazione di interagire con il sistema di ripristino e con gli aggiornamenti di sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Crea sessioni di proiezioni multimediali"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Consente a un\'applicazione di creare sessioni di proiezioni multimediali. Queste sessioni possono permettere alle applicazioni di acquisire contenuti presenti sul display e contenuti audio. Questa autorizzazione non dovrebbe mai essere necessaria per le normali app."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gestione delle sessioni di proiezione di contenuti multimediali"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Consente a un\'applicazione di gestire sessioni di proiezione di contenuti multimediali. Queste sessioni possono consentire alle applicazioni di acquisire contenuti visivi e audio. Non dovrebbe essere mai necessaria per le normali app."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Lettura di sessioni di installazione"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Consente a un\'applicazione di leggere le sessioni di installazione. L\'app può conoscere i dettagli sulle installazioni di pacchetti attive."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Tocca due volte per il comando dello zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Nega"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Autorizzazione richiesta"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Autorizzazione richiesta\nper l\'account <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Stai utilizzando l\'app nel tuo spazio personale"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Stai utilizzando l\'app nel tuo spazio di lavoro"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Stai utilizzando l\'app al di fuori del tuo profilo di lavoro"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Stai utilizzando l\'app nel tuo profilo di lavoro"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Metodo inserimento"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinc"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibilità"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Riduci ore"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Imposta PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Imposta AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumenta mese"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Riduci mese"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumenta giorno"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Modifica"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Avviso sull\'utilizzo dei dati"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Mostra utilizzo e impostazioni."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Dati 2G-3G disattivati"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Dati 4G disattivati"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Rete dati disattivata"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Dati Wi-Fi disattivati"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limite raggiunto"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Limite di dati 2G-3G raggiunto"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Limite di dati 4G raggiunto"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Limite dati cellulari raggiunto"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Limite di dati Wi-Fi raggiunto"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dati sospesi per resto del ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Limite dati 2G-3G superato"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Limite dati 4G superato"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limite rete dati superato"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Accettare la chiamata?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Solo una volta"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s non supporta il profilo di lavoro."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s non supporta il profilo di lavoro"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefono"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Cuffie audio"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Accessibilità attivata."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accessibilità annullata."</string>
     <string name="user_switched" msgid="3768006783166984410">"Utente corrente <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Passaggio a <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Proprietario"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Errore"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Questa modifica non è consentita dal tuo amministratore"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Elemento selezionato: <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> eliminato"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> lavoro"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Per sbloccare questa schermata, tocca e tieni premuto contemporaneamente Indietro e Recenti."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Per sbloccare questa schermata, tocca e tieni premuto Recenti."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"La schermata è bloccata. La tua organizzazione non ne consente lo sblocco."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Utilizzare il blocco su schermo?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Il blocco su schermo fissa la visualizzazione attuale sullo schermo.\n\nPer uscire, tocca e tieni premuto contemporaneamente Indietro e Recenti."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Il blocco su schermo fissa la visualizzazione attuale sullo schermo.\n\nPer uscire, tocca e tieni premuto Recenti."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NO, GRAZIE"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"AVVIA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"sequenza di sblocco"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"password"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Schermata bloccata"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Schermata sbloccata"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Richiedi il PIN prima di sbloccare"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Richiedi sequenza di sblocco prima di sbloccare"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Richiedi password prima di sbloccare"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Per aumentare la durata della batteria, la funzione Risparmio energetico riduce le prestazioni del dispositivo e limita vibrazione e gran parte dei dati in background. App di email, messaggi e altre app basate sulla sincronizzazione potrebbero non essere aggiornate se non le apri.\n\nIl risparmio energetico si disattiva automaticamente quando il dispositivo è in carica."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Fino al termine del periodo di inattività previsto per le <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Per un minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Per %d minuti"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Per un\'ora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Per %d ore"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Sempre"</string>
 </resources>
diff --git a/core/res/res/values-iw/strings.xml b/core/res/res/values-iw/strings.xml
index 01444be..f1691ef 100644
--- a/core/res/res/values-iw/strings.xml
+++ b/core/res/res/values-iw/strings.xml
@@ -211,7 +211,7 @@
     <string name="permgroupdesc_audioSettings" msgid="2641515403347568130">"שינוי הגדרות האודיו."</string>
     <string name="permgrouplab_affectsBattery" msgid="6209246653424798033">"השפעה על הסוללה"</string>
     <string name="permgroupdesc_affectsBattery" msgid="6441275320638916947">"שימוש בתכונות שיכולות לרוקן את הסוללה במהירות."</string>
-    <string name="permgrouplab_calendar" msgid="5863508437783683902">"לוח שנה"</string>
+    <string name="permgrouplab_calendar" msgid="5863508437783683902">"יומן"</string>
     <string name="permgroupdesc_calendar" msgid="5777534316982184416">"גישה ישירה ללוח השנה ולאירועים."</string>
     <string name="permgrouplab_dictionary" msgid="4148597128843641379">"קריאת מילון משתמש"</string>
     <string name="permgroupdesc_dictionary" msgid="7921166355964764490">"קריאת מילים במילון משתמש."</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"הרשאה זו מאפשרת למשתמש לבצע איגוד לממשק הרמה העליונה של צג רחוק. לעולם אינה אמורה להיות נחוצה לאפליקציות רגילות."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"‏הכפפה לשירות Widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"‏מאפשר למשתמש לבצע איגוד לממשק הרמה העליונה של שירות Widget. הרשאה זו לעולם אינה נחוצה לאפליקציות רגילים."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"איגוד לשירות של ספק ניתוב"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"מאפשרת לבעלים לאגד לספקי ניתוב רשומים. לעולם לא אמורה להיות נחוצה עבור אפליקציות רגילות."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"קיים אינטראקציה עם מנהל המכשיר"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"מאפשר למשתמש לשלוח כוונות למנהל התקנים. הרשאה זו לעולם אינה נחוצה לאפליקציות רגילים."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"איגוד לקלט טלוויזיה"</string>
@@ -502,11 +500,11 @@
     <string name="permlab_writeSocialStream" product="default" msgid="3504179222493235645">"כתיבה בזרם החברתי שלך"</string>
     <string name="permdesc_writeSocialStream" product="default" msgid="3086557552204114849">"מאפשר לאפליקציה להציג עדכונים חברתיים מהחברים שלך. היזהר בעת שיתוף מידע -- הדבר מאפשר לאפליקציה ליצור הודעות שעשויות להיראות כאילו שנשלחו מחבר. שים לב: ייתכן אישור זה לא נאכף בכל הרשתות החברתיות."</string>
     <string name="permlab_readCalendar" msgid="5972727560257612398">"קריאת אירועי יומן וגם מידע סודי"</string>
-    <string name="permdesc_readCalendar" product="tablet" msgid="4216462049057658723">"מאפשר לאפליקציה לקרוא את כל אירועי לוח השנה המאוחסנים בטאבלט, כולל אלה של חברים ועמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשתף או לשמור את נתוני לוח השנה שלך, ללא התחשבות בסודיות או ברגישות."</string>
-    <string name="permdesc_readCalendar" product="default" msgid="7434548682470851583">"מאפשר לאפליקציה לקרוא את כל אירועי לוח השנה המאוחסנים בטלפון, כולל אלה של חברים ועמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשתף או לשמור את נתוני לוח השנה שלך, ללא התחשבות בסודיות או ברגישות."</string>
+    <string name="permdesc_readCalendar" product="tablet" msgid="4216462049057658723">"מאפשר לאפליקציה לקרוא את כל אירועי היומן המאוחסנים בטאבלט, כולל אלה של חברים ועמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשתף או לשמור את נתוני היומן שלך, ללא התחשבות בסודיות או ברגישות."</string>
+    <string name="permdesc_readCalendar" product="default" msgid="7434548682470851583">"מאפשר לאפליקציה לקרוא את כל אירועי היומן המאוחסנים בטלפון, כולל אלה של חברים ועמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשתף או לשמור את נתוני היומן שלך, ללא התחשבות בסודיות או ברגישות."</string>
     <string name="permlab_writeCalendar" msgid="8438874755193825647">"הוספה ושינוי של אירועי יומן ושליחת דוא\"ל לאורחים ללא ידיעת הבעלים"</string>
-    <string name="permdesc_writeCalendar" product="tablet" msgid="6679035520113668528">"מאפשר לאפליקציה להוסיף, להסיר ולשנות אירועים שאתה יכול לשנות בטאבלט, כולל אלה של חברים או עמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשלוח הודעות הנראות כאילו שנשלחו מבעלי לוח שנה או לשנות אירועים ללא ידיעת הבעלים."</string>
-    <string name="permdesc_writeCalendar" product="default" msgid="2324469496327249376">"מאפשר לאפליקציה להוסיף, להסיר ולשנות אירועים שאתה יכול לשנות בטלפון, כולל אלה של חברים או עמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשלוח הודעות הנראות כאילו שנשלחו מבעלי לוח שנה או לשנות אירועים ללא ידיעת הבעלים."</string>
+    <string name="permdesc_writeCalendar" product="tablet" msgid="6679035520113668528">"מאפשר לאפליקציה להוסיף, להסיר ולשנות אירועים שאתה יכול לשנות בטאבלט, כולל אלה של חברים או עמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשלוח הודעות הנראות כאילו שנשלחו מבעלי יומן או לשנות אירועים ללא ידיעת הבעלים."</string>
+    <string name="permdesc_writeCalendar" product="default" msgid="2324469496327249376">"מאפשר לאפליקציה להוסיף, להסיר ולשנות אירועים שאתה יכול לשנות בטלפון, כולל אלה של חברים או עמיתים לעבודה. הדבר עשוי להתיר לאפליקציה לשלוח הודעות הנראות כאילו שנשלחו מבעלי יומן או לשנות אירועים ללא ידיעת הבעלים."</string>
     <string name="permlab_accessMockLocation" msgid="8688334974036823330">"צור מקורות מיקום מדומים לצורך בדיקה"</string>
     <string name="permdesc_accessMockLocation" msgid="5808711039482051824">"‏צור מקורות מיקום מדומים לבדיקה, או התקן ספק מיקום חדש. פעולה זו מאפשרת לאפליקציה לעקוף את המיקום ו/או הסטטוס המוחזרים על ידי מקורות מיקום אחרים כמו GPS או ספקי מיקום."</string>
     <string name="permlab_accessLocationExtraCommands" msgid="2836308076720553837">"גישה לפקודות ספק מיקום נוספות"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"הפעל או כבה את הטלפון"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"מאפשר לאפליקציה להפעיל או לכבות את הטאבלט."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"מאפשר לאפליקציה להפעיל או לכבות את הטלפון."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"איפוס הזמן הקצוב לתפוגת התצוגה"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"מאפשר לאפליקציה לאפס את הזמן הקצוב לתפוגת התצוגה."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"הפעל במצב בדיקת יצרן"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"הפעל כבדיקת יצרן ברמה נמוכה, המאפשרת גישה מלאה לחומרה של הטאבלט. זמין רק כאשר הטאבלט פועל במצב בדיקת יצרן."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"הפעל כבדיקת יצרן ברמה נמוכה, המאפשרת גישה מלאה לחומרת הטלפון. זמינה רק כאשר טלפון פועל במצב בדיקת יצרן."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"מאפשר לאפליקציה לקרוא ולכתוב במערכת הקבצים של הקבצים השמורים."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"‏ביצוע/קבלה של שיחות SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"‏אפשר לאפליקציה לבצע ולקבל שיחות SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"צור אינטראקציה עם מסך שיחה נכנסת"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"מאפשר לאפליקציה לקבוע מתי ואיך המשתמש יראה שיחה נכנסת על המסך."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"צור אינטראקציה עם מסך שיחה נכנסת"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"מאפשר לאפליקציה לקבוע מתי ואיך המשתמש יראה את מסך השיחה הנכנסת."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"צור אינטראקציה עם שירותי טלפוניה"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"מאפשר לאפליקציה ליצור אינטראקציה עם שירותי טלפוניה כדי לבצע/לקבל שיחות."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ספק חווית משתמש של שיחה נכנסת"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"מאפשר לאפליקציה לספק חוויית משתמש של שיחה נכנסת."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"קריאת נתוני שימוש היסטוריים ברשת"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"מאפשר לאפליקציה לקרוא נתוני שימוש היסטוריים ברשת עבור רשתות ואפליקציות ספציפיות."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"נהל מדיניות רשת"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"הרשאה זו מאפשרת למשתמש לבצע איגוד לממשק הרמה העליונה של שירות מאזין להתראות. הרשאה זו אף פעם אינה נחוצה לאפליקציות רגילים."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"איגוד לשירות ספק תנאי"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"מאפשרת לבעלים לאגד לממשק ברמה העליונה של שירות ספק תנאי. לעולם לא אמורה להיות נחוצה עבור אפליקציות רגילות."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"איגוד לשירות ניתוב מדיה"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"מאפשרת לבעלים לאגוד לממשק ברמה העליונה של שירות ניתוב מדיה. לעולם לא אמורה להיות נחוצה עבור אפליקציות רגילות."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"‏איגוד לשירות Dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"‏מאפשרת לבעלים לבצע איגוד לממשק הרמה העליונה של שירות Dream. הרשאה זו אף פעם אינה נחוצה לאפליקציות רגילות."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"הפעלה של אפליקציית תצורה שסופקה על ידי ספק"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"‏שתף באמצעות %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"בחר אפליקציה לדף הבית"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"השתמש כברירת מחדל עבור פעולה זו."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"השתמש באפליקציה אחרת"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"‏נקה את הגדרת המחדל ב\'הגדרות מערכת\' &lt;‏ Google Apps‏ &lt; \'הורדות\'."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"בחירת פעולה"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"‏בחר אפליקציה עבור התקן ה-USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"אפשר"</string>
     <string name="sms_control_no" msgid="625438561395534982">"דחה"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"‏&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; רוצה לשלוח הודעה אל &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"הפעולה "<font fgcolor="#ffffb060">"עשויה לגרום לחיובים"</font>" בחשבון המכשיר הנייד שלך."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"הפעולה תגרום לחיובים בחשבון המכשיר הנייד שלך."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"הדבר "<b>"עלול לגרום לחיובים"</b>" בחשבון המכשיר הנייד שלך."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"הדבר יגרום לחיובים בחשבון המכשיר הנייד שלך."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"שלח"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"בטל"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"זכור את הבחירה שלי"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"‏גע כדי להשבית את ניקוי הבאגים בהתקן ה-USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"שינוי מקלדת"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"בחר מקלדות"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"מקלדת פיזית"</string>
+    <string name="show_ime" msgid="9157568568695230830">"הצג שיטת קלט"</string>
     <string name="hardware" msgid="7517821086888990278">"חומרה"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"בחירת פריסת מקלדת"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"גע כדי לבחור פריסת מקלדת."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"מאפשר לאפליקציה לאגוד אל שירות סביבה אמינה."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"אינטראקציה עם מערכת שחזור ועדכונים"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"מאפשרת לאפליקציה ליצור אינטראקציה עם מערכת השחזור ועדכוני מערכת."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"יצירת פעילות של הקרנת מדיה"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"מאפשר לאפליקציה ליצור פעילות של הקרנת מדיה. ההפעלות האלה יכולות לתת לאפליקציות את האפשרות להקליט תוכן של מסך ואודיו. לעולם לא אמור להיות נחוץ עבור אפליקציות רגילות."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"נהל פעילויות באתר להקרנת מדיה"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"מאפשר לאפליקציה ליצור פעילות של הקרנת מדיה. ההפעלות האלה יכולות לתת לאפליקציות את האפשרות להקליט תוכן של מסך ואודיו. לעולם לא אמור להיות נחוץ עבור אפליקציות רגילות."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"קריאת פעילות התקנה"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"מאפשר לאפליקציה לקרוא הפעלות התקנה. הרשאה זו מאפשרת לה לראות פרטים על התקנות פעילות של חבילות."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"גע פעמיים לבקרת מרחק מתצוגה"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"דחה"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"בקשת הרשאה"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"נדרשת הרשאה\nלחשבון <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"אתה משתמש באפליקציה הזו בסביבה האישית שלך"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"אתה משתמש באפליקציה הזו בסביבת העבודה שלך"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"אתה משתמש באפליקציה זו מחוץ לפרופיל העבודה שלך"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"אתה משתמש באפליקציה זו בפרופיל העבודה שלך"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"שיטת קלט"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"סינכרון"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"נגישות"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"הפחת שעה"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"‏הגדר PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"‏הגדר AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"הוסף חודש"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"הפחת חודש"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"הוסף יום"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ערוך"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"אזהרת שימוש בנתונים"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"גע כדי להציג נתוני שימוש והגדרות."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"‏נתונים בחיבור 2G-3G כובו"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"‏נתונים בחיבור 4G כובו"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"נתונים בחיבור סלולרי כובו"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"‏נתונים בחיבור Wi-Fi כובו"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"הגעת למגבלה"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"‏הגעת למגבלת הנתונים של 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"‏הגעת למגבלת הנתונים של 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"הגעת למגבלת הנתונים הסלולריים"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"‏הגעת למגבלת נתוני Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"הנתונים הושהו למשך המחזור"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"‏אירעה חריגה ממגבלת הנתונים של 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"‏אירעה חריגה ממגבלת הנתונים של 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"חרגת ממגבלת הנתונים הסלולריים"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"האם לקבל את השיחה?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"תמיד"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"רק פעם אחת"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"‏%1$s אינו תומך בפרופיל עבודה."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"‏%1$s אינו תומך בפרופיל עבודה"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"טאבלט"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"טלפון"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"אוזניות"</string>
@@ -1592,7 +1589,7 @@
     <string name="media_route_status_in_use" msgid="4533786031090198063">"בשימוש"</string>
     <string name="display_manager_built_in_display_name" msgid="2583134294292563941">"מסך מובנה"</string>
     <string name="display_manager_hdmi_display_name" msgid="1555264559227470109">"‏מסך HDMI"</string>
-    <string name="display_manager_overlay_display_name" msgid="5142365982271620716">"שכבת על #<xliff:g id="ID">%1$d</xliff:g>"</string>
+    <string name="display_manager_overlay_display_name" msgid="5142365982271620716">"שכבת-על #<xliff:g id="ID">%1$d</xliff:g>"</string>
     <string name="display_manager_overlay_display_title" msgid="652124517672257172">"‏<xliff:g id="NAME">%1$s</xliff:g>: ‎<xliff:g id="WIDTH">%2$d</xliff:g>x<xliff:g id="HEIGHT">%3$d</xliff:g>‎, ‏<xliff:g id="DPI">%4$d</xliff:g> dpi"</string>
     <string name="display_manager_overlay_display_secure_suffix" msgid="6022119702628572080">", מאובטח"</string>
     <string name="wifi_display_notification_connecting_title" msgid="2838646471050359706">"העברת מסך מתבצעת"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"נגישות הופעלה."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"נגישות בוטלה."</string>
     <string name="user_switched" msgid="3768006783166984410">"המשתמש הנוכחי <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"עובר אל <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"בעלים"</string>
     <string name="error_message_title" msgid="4510373083082500195">"שגיאה"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"מנהל המערכת שלך אינו מתיר שינוי זה"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> נבחר"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> נמחק"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"עבודה <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"כדי לבטל הצמדה של מסך זה, גע נגיעה ארוכה בלחצנים \'הקודם\' ו\'אחרונים\' בו-זמנית."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"כדי לבטל הצמדה של מסך זה, גע נגיעה ארוכה בלחצן \'אחרונים\'."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"המסך מוצמד. הארגון אוסר לבטל את הצמדתו."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"להשתמש בהצמדת מסך?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"הצמדת מסך נועלת את התצוגה בתצוגה אחת.\n\nכדי לצאת, גע נגיעה ארוכה בלחצנים \'הקודם\' ו\'אחרונים\' בו-זמנית."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"הצמדת מסך נועלת את התצוגה בתצוגה אחת.\n\nכדי לצאת, גע נגיעה ארוכה בלחצן \'אחרונים\'."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"לא, תודה"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"הפעל"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"‏מספר PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"קו ביטול נעילה"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"סיסמה"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"המסך מוצמד"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"הצמדת המסך בוטלה"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"בקש קוד אימות לפני ביטול הצמדה"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"בקש קו ביטול נעילה לפני ביטול הצמדה"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"בקש סיסמה לפני ביטול הצמדה"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"כדי לעזור בהארכת חיי הסוללה, תכונת \'חיסכון בסוללה\' מצמצמת את פעילות המכשיר ומגבילה את השימוש ברטט וברוב נתוני הרקע. ייתכן שדוא\"ל, שליחת הודעות ואפליקציות אחרות המסתמכות על סנכרון לא יתעדכנו, אלא אם תפתח אותן.\n\nתכונת \'חיסכון בסוללה\' מופסקת אוטומטית כשהמכשיר מחובר לחשמל."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"עד לסיום ההשבתה בשעה <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"למשך דקה אחת"</item>
+    <item quantity="other" msgid="6924190729213550991">"‏למשך %d דקות"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"למשך שעה אחת"</item>
+    <item quantity="other" msgid="5408537517529822157">"‏למשך %d שעות"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"ללא הגבלה"</string>
 </resources>
diff --git a/core/res/res/values-ja/strings.xml b/core/res/res/values-ja/strings.xml
index 09d51da..ce5ebb5 100644
--- a/core/res/res/values-ja/strings.xml
+++ b/core/res/res/values-ja/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"リモートディスプレイのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ウィジェットサービスにバインド"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ウィジェットサービスのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"ルートプロバイダサービスへのバインド"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"登録済みのルートプロバイダにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"デバイス管理者との通信"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"デバイス管理者へのintentの送信を所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"テレビの入力へのバインド"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"電源のON/OFF"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"タブレットの電源のON/OFFをアプリに許可します。"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"携帯端末の電源のON/OFFをアプリに許可します。"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"表示タイムアウトのリセット"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"表示タイムアウトをリセットすることをアプリに許可します。"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"出荷時試験モードでの実行"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"タブレットハードウェアへのアクセスを完全に許可して、低レベルのメーカーテストを実行します。メーカーのテストモードでタブレットを使用する場合にのみ利用できます。"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"携帯電話のハードウェアへのアクセスを完全に許可して、低レベルのメーカーテストとして実行します。メーカーのテストモードで携帯電話を使用するときのみ利用できます。"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"キャッシュファイルシステムの読み書きをアプリに許可します。"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP通話の発着信"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP通話の発着信をアプリに許可します。"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"通話画面とのインタラクション"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"通話画面をユーザーに表示するタイミングと方法の制御をアプリに許可します。"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"通話画面とのインタラクション"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"通話画面をユーザーに表示するタイミングと方法の制御をアプリに許可します。"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"電話サービスとの通信"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"受発信のためアプリが電話サービスと通信することを許可する。"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"通話中のユーザーエクスペリエンスの提供"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"通話中のユーザーエクスペリエンスの提供をアプリに許可します。"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ネットワーク使用履歴の読み取り"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"特定のネットワークやアプリに関するネットワーク使用履歴の読み取りをアプリに許可します。"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ネットワークポリシーの管理"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"通知リスナーサービスのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"コンディションプロバイダサービスへのバインド"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"コンディションプロバイダサービスのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"メディアルートサービスへのバインド"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"メディアルートサービスのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ドリームサービスにバインド"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ドリームサービスのトップレベルインターフェースにバインドすることを所有者に許可します。通常のアプリでは不要です。"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"携帯通信会社が提供する設定アプリの呼び出し"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$sで共有"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ホームアプリを選択"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"常にこの操作で使用する"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"別のアプリの使用"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"[システム設定]&gt;[アプリ]&gt;[ダウンロード済み]でデフォルト設定をクリアします。"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"操作の選択"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USBデバイス用アプリを選択"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"許可する"</string>
     <string name="sms_control_no" msgid="625438561395534982">"許可しない"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt;が、&lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;にメッセージを送信しようとしています。"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"モバイルアカウントへの"<font fgcolor="#ffffb060">"請求が発生する可能性"</font>"があります。"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"モバイルアカウントへの請求が発生します。"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"モバイルアカウントへの"<b>"請求が発生する可能性"</b>"があります。"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"モバイルアカウントへの請求が発生します。"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"送信"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"キャンセル"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"この選択を保存"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"タップしてUSBデバッグを無効にします。"</string>
     <string name="select_input_method" msgid="8547250819326693584">"キーボードの変更"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"キーボードの選択"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"物理キーボード"</string>
+    <string name="show_ime" msgid="9157568568695230830">"入力方法を表示する"</string>
     <string name="hardware" msgid="7517821086888990278">"ハードウェア"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"キーボードレイアウトの選択"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"タップしてキーボードレイアウトを選択してください。"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"信頼できるエージェントサービスにバインドすることをアプリに許可します。"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"アップデートと回復システムへのアクセス"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"回復システムとシステムアップデートへのアクセスをアプリに許可します。"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"メディアプロジェクションセッションの作成"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"メディアプロジェクションセッションの作成をアプリに許可します。これらのセッションでは、アプリがディスプレイ/オーディオコンテンツをキャプチャできます。通常のアプリでは不要です。"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"メディアプロジェクションセッションの管理"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"メディアプロジェクションセッションの管理をアプリに許可します。これらのセッションでは、アプリがディスプレイ/オーディオのコンテンツをキャプチャできます。通常のアプリでは不要です。"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"インストールセッションの読み取り"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"インストールセッションの読み取りをアプリに許可します。これにより、アプリはアクティブパッケージのインストールに関する詳細情報を参照できるようになります。"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ダブルタップでズームコントロール"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"拒否"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"権限がリクエストされました"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"次のアカウントにアクセスする権限が\nリクエストされました: <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"個人用スペースでこのアプリを使用しています"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"ワークスペースでこのアプリを使用しています"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"ワークプロフィールの外部でこのアプリを使用しています"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"ワークプロフィールでこのアプリを使用しています"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"入力方法"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"同期"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ユーザー補助"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"1時間戻します"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"午後に設定"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"午前に設定"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"午後"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"午前"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"1か月進めます"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"1か月戻します"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"1日進めます"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"編集"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"データ使用の警告"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"タップして使用状況と設定を表示します。"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G~3Gデータが無効になりました"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4Gデータが無効になりました"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"モバイルデータが無効になりました"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fiデータが無効になりました"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"上限に達しました"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G~3Gデータの上限に達しました"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4Gデータの上限に達しました"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"モバイルデータの上限に達しました"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fiデータの上限に達しました"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"残りのサイクル中データは一時停止"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G~3Gデータの上限を超えました"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4Gデータの上限を超えました"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"モバイルデータの上限を超えました"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"通話を受けますか?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"常時"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"1回のみ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$sはワークプロフィールをサポートしていません。"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$sはワークプロフィールをサポートしていません"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"タブレット"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"携帯端末"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ヘッドホン"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ユーザー補助が有効になりました。"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ユーザー補助をキャンセルしました。"</string>
     <string name="user_switched" msgid="3768006783166984410">"現在のユーザーは<xliff:g id="NAME">%1$s</xliff:g>です。"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>に切り替えています…"</string>
     <string name="owner_name" msgid="2716755460376028154">"所有者"</string>
     <string name="error_message_title" msgid="4510373083082500195">"エラー"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"この変更は管理者によって許可されていません"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g>を選択しました"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g>を削除しました"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"仕事の<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"この画面の固定を解除するには[戻る]と[最近]を同時に押し続けます。"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"この画面の固定を解除するには[最近]を押し続けます。"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"画面が固定されています。会社/組織により解除は許可されていません。"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"画面固定を使用しますか?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"画面固定では、1つの画面が表示されたままになります。\n\n解除するには[戻る]と[最近]を同時に押し続けます。"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"画面固定では、1つの画面が表示されたままになります。\n\n解除するには[最近]を押し続けます。"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"いいえ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"開始する"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ロック解除パターン"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"パスワード"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"画面を固定しました"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"画面固定を解除しました"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"オフライン再生を解除する前にPINの入力を求める"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"オフライン再生を解除する前にロック解除パターンの入力を求める"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"オフライン再生を解除する前にパスワードの入力を求める"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"バッテリーを長持ちさせるため、バッテリーセーバーは端末のパフォーマンス、バイブレーション、ほとんどのバックグラウンドデータを制限します。同期を使用するメールやメッセージなどのアプリは起動しないと更新されない場合があります。\n\nバッテリーセーバーは、端末の充電中は自動的にOFFになります。"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>にダウンロードが終わるまで"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1分"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d分"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1時間"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d時間"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"制限なし"</string>
 </resources>
diff --git a/core/res/res/values-ka-rGE/strings.xml b/core/res/res/values-ka-rGE/strings.xml
index 9849d9b..bcf10ee 100644
--- a/core/res/res/values-ka-rGE/strings.xml
+++ b/core/res/res/values-ka-rGE/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"მფლობელს შეეძლება მიებას დისტანციურ მონიტორის ზედა დონის ინტერფეისს. ჩვეულებრივ აპს ეს წესით არასოდეს უნდა დაჭირდეს."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ვიჯეტ სერვისთან დაკავშირება"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"აპს შეეძლება ზედა დონის ინტერფეისის ვიჯეტთან დაკავშირება. არასდროს გამოიყენება ჩვეულებრივ აპებში."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"მარშრუტის სერვისის პროვაიდერთან შეკავშირება"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"საშუალებას აძლევს მფლობელს შეკავშირდეს მარშრუტების ნებისმიერ პროვაიდერთან. ჩვეულებრივ აპებს უმეტეს შემთხვევაში არ დაჭირდება."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"მოწყობილობის ადმინთან ინტერაქცია"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"აპს შეეძლება მოწყობილობის ადმინისტრატორისთვის intent ობიექტების გაგზავნა. არასდროს გამოიყენება ჩვეულებრივ აპებში."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV შეყვანასთან მიბმა"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ტელეფონის ჩართვა ან გამორთვა"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"აპს შეეძლება, ჩართოს ან გამორთოს ტაბლეტი."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"აპს შეეძლება, ჩართოს ან გამორთოს ტელეფონი."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"დისლპეის დროის ლიმიტის ხელახლა დაყენება"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"უფლებას აძლევს აპს, ხელახლა დააყენოს დისლპეის დროის ლიმიტი."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ქარხნულ სატესტო რეჟიმში გაშვება"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"მწარმოებლის დაბალი დონის ტესტის რეჟიმში გაშვება, რომლის დროსაც სრულად არის ხელმისაწვდომი ტაბლეტის აპარატული უზრუნველყოფა. ხელმისაწვდომია მხოლოდ მწარმოებლის ტესტის რეჟიმში ჩართულ ტაბლეტზე."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"მწარმოებლის დაბალი დონის ტესტის რეჟიმში გაშვება, რომლის დროსაც სრულად არის ხელმისაწვდომი ტელეფონის აპარატული უზრუნველყოფა. ხელმისაწვდომია მხოლოდ მწარმოებლის ტესტის რეჟიმში ჩართულ ტელეფონზე."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"აპებს აძლევს ქეშირებული სისტემური ფაილების წაკითხვისა და მათში ჩანაწერების გაკეთების საშუალებას."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP ზარების წამოწყება/მიღება"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"ნებას რთავს აპს განახორციელოს და მიიღოს SIP ზარები."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ზარს-შიდა ეკრანთან ინტერაქცია"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"საშუალებას აძლევს აპს აკონტროლოს, თუ როდის და როგორ იხილავს მომხმარებელი ზარს-შიდა ეკრანს."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ინტერაქცია საუბრის რეჟიმის ეკრანთან"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"აპს შეეძლება გაკონტროლება, როდის და როგორ დაინახავს მომხმარებელი საუბრის რეჟიმის ეკრანს."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ტელეფონიის სერვისებთან ინტერაქცია"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"ნებას აძლევს აპს მოახდინოს ტელეფონიის სერვისებთან ინტერაქცია, რათა განახორციელოს/მიიღოს ზარები."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"უზრუნველყოფს საუბრის რეჟიმში მომხმარებლის გამოცდილებას."</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"აპს საშუალებას აძლევს, უზრუნველყოს საუბრის რეჟიმში მომხმარებლის გამოცდილება."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ქსელის გამოყენების ისტორიის წაკითხვა"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"აპს შეეძლება კონკრეტული ქსელისა და აპების ისტორიული ქსელის გამოყენების წაკითხვას."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ქსელის დებულების მართვა"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"მფლობელს შეეძლება შეტყობინებების მსმენლის სერვისის ზედა დონის ინტერფეისთან დაკავშირება. არ უნდა მოხდეს მისი გამოყენება ჩვეუელებრივი აპებისთვის.ფ"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"მდგომარეობის პროვაიდერის სერვისებთან შეკავშირება"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"მფლობელს შეეძლება შეკავშირდეს მდგომარეობის პროვაიდერის სერვისების ზედა დონის ინტერფეისთან. ჩვეულებრივ აპს ეს წესით არასოდეს უნდა დასჭირდეს."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"მედიის მარშრუტის სერვისთან შეკავშირება"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"მფლობელს შეეძლება შეკავშირდეს მედიის მარშრუტიზაციის სერვისების ზედა დონის ინტერფეისთან. ჩვეულებრივ აპს ეს წესით არასოდეს უნდა დასჭირდეს."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"dream სერვისთან მიბმა"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"მფლობელს შეეძლება მიებას dream სერვისის ზედა დონის ინტერფეისი. ჩვეულებრივ აპს ეს წესით არასოდეს უნდა დაჭირდეს."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ოპერატორის მიერ მოწოდებული კოფიგურაციის აპის გამოხმობა"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s-თან გაზიარება"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"აირჩიეთ საშინაო აპი"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ამ ქმედებისთვის ნაგულისხმევად გამოყენება."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"სხვა აპის გამოყენება"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"ნაგულისხმევი პარამეტრების წაშლა სისტემის პარამეტრებში &gt; აპებში &gt; ჩამოტვირთულებში."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"აირჩიეთ მოქმედება"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB მოწყობილობისათვის აპის შერჩევა"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"უფლების მიცემა"</string>
     <string name="sms_control_no" msgid="625438561395534982">"უარყოფა"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; სურს შეტყობინების გაგზავნა &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;-ისთვის."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ამან "<font fgcolor="#ffffb060">"შესაძლოა გამოიწვიოს ცვლილებები"</font>" თქვენი მობილურის ანგარიშზე."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"ეს გამოიწვევს დანახარჯებს თქვენ მობილურ ანგარიშზე."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"ამით "<b>"შესაძლოა შეიცვალოს"</b>" თქვენი მობილური ანგარიში."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ამით თქვენი მობილური ანგარიში შეიცვლება."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"გაგზავნა"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"გაუქმება"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ჩემი არჩევანის დამახსოვრება"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"შეეხეთ, რათა შეწყვიტოთ USB-ის გამართვა."</string>
     <string name="select_input_method" msgid="8547250819326693584">"კლავიატურის შეცვლა"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"კლავიატურების არჩევა"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ფიზიკური კლავიატურა"</string>
+    <string name="show_ime" msgid="9157568568695230830">"შეყვანის მეთოდის ჩვენება"</string>
     <string name="hardware" msgid="7517821086888990278">"მოწყობილობა"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"შეარჩიეთ კლავიატურის განლაგება."</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"კლავიატურის განლაგების შესარჩევად შეეხეთ."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"საშუალებას აძლევს აპლიკაციას მიემაგროს ნდობის აგენტის სერვისს."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"განახლებასთან და აღდგენის სისტემასთან ინტერაქცია"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"საშუალებას აძლევს აპლიკაციას მოახდინოს აღდგენის სისტემასთან და სისტემის განახლებასთან ინტერაქცია."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"მედია პროეცირების სესიების შექმნა"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"საშუალებას აძლევს აპლიკაციას, შექმნას მედია პროეცირების სესიები. ამ სესიებმა შესაძლოა მისცეს აპლიკაციებს საშუალება, აღიბეჭდოს ეკრანისა და აუდიოს კონტენტი. ჩვეულებრივ აპს წესით ეს არასოდეს არ უნდა დასჭირდეს."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"მედია პროეცირების სესიების მართვა"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"საშუალებას აძლევს აპლიკაციას, მართოს მედია პროეცირების სესიები. ამ სესიებმა შესაძლოა აპლიკაციებს  საშუალება მისცეს, აღბეჭდოს ეკრანისა და აუდიოს ქონთენთი. ჩვეულებრივ აპს წესით ეს არასოდეს არ უნდა დაჭირდეს."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ინსტალაციის სესიების წაკითხვა"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"საშუალებას აძლევს აპლიკაციას წაიკითხოს ინსტალაციის სესიები. ამით მას საშუალება აქვს იხილოს პაკეტის აქტიური ინსტალაციები."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"მასშტაბის მართვისთვის შეეხეთ ორჯერ."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"აკრძალვა"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"მოთხოვნილია ნებართვა"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"მოთხოვნილია ნებრათვა \nანგარიშისთვის: <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"ამ აპს თქვენს პერსონალურ სივრცეში იყენებთ"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"ამ აპს თქვენს სამუშაო სივრცეში იყენებთ"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"იყენებთ ამ აპს თქვენს სამუშაო პროფილს მიღმა"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"ამ აპს თქვენს სამუშაო პროფილში იყენებთ"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"შეყვანის მეთოდი"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"სინქრონიზაცია"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"წვდომა"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"საათით უკან"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM-ის დაყენება"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM-ის დაყენება"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"თვის მომატება"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ერთი თვით უკან"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"დღის მომატება"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"რედაქტირება"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ინტერნეტის გამოყენების გაფრთხილება"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"შეეხეთ მოხმარებისა და პარამეტრების სანახავად."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G მონაც. გადაცემა გამორთულია"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G მონაც. გადაცემა გამორთულია"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"ფიჭური ინტერნეტი გამორთულია"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi მონაც. გადაცემა გამორთულია"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ლიმიტი მიღწეულია"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G მონაცემთა ლიმიტი ამოიწურა"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G მონაცემთა ლიმიტი ამოიწურა"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"ფიჭურ მონაცემთა ლიმიტი ამოიწურა"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi მონაცემთა ლიმიტი ამოიწურა"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"მონაცემები შეჩერდა ციკლისთვის"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"გადაჭარბებულია 2G-3G მონაცემების ლიმიტი"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ლიმიტი გადაჭარბებულია"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"ფიჭ. ინტერნეტის ლიმიტი მიღწეულია"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"უპასუხებთ ზარს?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ყოველთვის"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"მხოლოდ ერთხელ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s-ს სამუშაო პროფილის მხარდაჭერა არ გააჩნია."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s მხარს არ უჭერს სამუშაო პროფილს"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ტაბლეტი"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ტელეფონი"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ყურსასმენები"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"მარტივი წვდომა ჩართულია."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"მარტივი წვდომა გაუქმდა."</string>
     <string name="user_switched" msgid="3768006783166984410">"ამჟამინდელი მომხმარებელი <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>-ზე გადართვა…"</string>
     <string name="owner_name" msgid="2716755460376028154">"მფლობელი"</string>
     <string name="error_message_title" msgid="4510373083082500195">"შეცდომა"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ეს ცვლილება თქვენი დომენის ადმინისტრატორის მიერ ნებადართული არ არის."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"არჩეულია <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> წაიშალა"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"სამსახური <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ამ ეკრანის ფიქსაციის მოსახსნელად, შეეხეთ და არ დააყოვნეთ Back და Recents ერთდროულად."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ამ ეკრანის ფიქსაციის მოსახსნელად, შეეხეთ და არ დააყოვნეთ Recents-ზე."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"ეკრანი დაფიქსირებული. ფიქსაციის მოხსნა თქვენო ორგანიზაციის მიერ ნებადართული არ არის."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"გსურთ ეკრანის ფიქსაციის გამოყენება?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"ეკრანის ფიქსაციით ეკრანის ერთი ხედი დაფიქსირდება.\n\nგამოსასვლელად, შეეხეთ და დააყოვნეთ Back და Recents ერთდროულად."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"ეკრანის ფიქსაცია კეტავს ეკრანს ერთ აპზე.\n\nგასასვლელად დააჭირეთ და არ აუშვათ Recents-ს."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"არა, გმადლობთ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"დაწყება"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-კოდი"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"განბლოკვის ნიმუში"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"პაროლი"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"ეკრანი დაფიქსირდა"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"ეკრანს ფიქსაცია მოეხსნა"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ფიქსაციის მოხსნამდე PIN-ის მოთხოვნა"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ფიქსაციის მოხსნამდე განბლოკვის ნიმუშის მოთხოვნა"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ფიქსაციის მოხსნამდე პაროლის მოთხოვნა"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ბატარეის გამძლეობის გასახანგრძლივებლად, ბატარეის დამზოგი ამცირებს თქვენი მოწყობილობის წარმადობას და ზღუდავს ვიბრაციასა და უმეტეს ფონურ მონაცემს. თუ არ განაახლებთ, შეიძლება არ გაიხსნას ელფოსტა, შეტყობინებები და სხვა აპები, რომლებიც სინქრონიზაციაზეა დამოკიდებული.\n\nბატარეის დამზოგი ავტომატურად გამოირთვება, როდესაც თქვენი მოწყობილობა იტენება."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"დანამ თქვენი კავშირგარეშე დრო დასრულდებოდეს <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>-ზე"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ერთი წუთით"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d წუთით"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ერთი საათით"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d საათით"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"სამუდამოდ"</string>
 </resources>
diff --git a/core/res/res/values-kk-rKZ/strings.xml b/core/res/res/values-kk-rKZ/strings.xml
index 3c3d15b..e49970b 100644
--- a/core/res/res/values-kk-rKZ/strings.xml
+++ b/core/res/res/values-kk-rKZ/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Пайдаланушыға қашықтан басқарылатын дисплейдің жоғары деңгейлі интерфейсіне жалғану мүмкіндігін ұсынады. Қалыпты қолданбаны ешқашан қажет етпеуі тиіс."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"виджет қызметіне байланыстыру"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Пайдаланушыға виджет қызметінің жоғары деңгейлі интерфейсіне байластыруға рұқсат береді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"маршрут провайдері қызметіне байластыру"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Пайдаланушыға кез келген тіркелген маршрут провайдерлеріне байластыруға рұқсат береді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"құрал әкімшісімен қатынасу"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Иесіне ниеттерді құрылғы әкімшісіне жіберуге рұқсат береді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ТД кірісіне байластыру"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"телефонды қуат көзіне қосу немесе ажырату"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Қолданбаға планшетті қосуға немесе өшіруге рұқсат береді."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Қолданбаға телефонды қосуға немесе өшіруге рұқсат береді."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"дисплейдің күту уақытының бітуін қалпына келтіру"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Қолданбаға дисплейдің күту уақытының бітуін қалпына келтіруге рұқсат етеді."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"зауыт тесті режимінде жүргізу"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Төмен деңгейлі өндіріс тесті ретінде қосып, планшеттің қатты дискісіне кіру мүмкіндігін беру. Планшет өндіріс тесті режимінде жұмыс істегенде ғана қол жетімді."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Төмен деңгейлі өндіріс тесті ретінде қосып, телефонның қатты дискісіне кіру мүмкіндігін беру. Телефон өндіріс тесті режимінде жұмыс істегенде ғана қол жетімді."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Қолданбаға кэш файлдық жүйесін оқуға және оған жазуға рұқсат береді."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP қоңырауларын шалу/қабылдау"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Қолданбаға SIP қоңырауларын шалуға және қабылдауға рұқсат етеді."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"қоңырау кезінде экранды қолдану"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Қолданбаға пайдаланушының қоңырау кезінде экранды қашан және қалай көретінін басқару мүмкіндігін береді."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"қоңыраудағы экранмен өзара әрекеттесу"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Қолданбаға пайдаланушының қоңырау кезінде экранды қашан және қалай көретінін басқару мүмкіндігін береді."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"телефония қызметтерімен өзара әрекеттесу"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Қолданбаға қоңыраулар шалу/қабылдау үшін телефония қызметтерімен өзара әрекеттесуге рұқсат етеді."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"қоңыраудағы пайдаланушы тәжірибесін қамтамасыз ету"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Қолданбаға қоңыраудағы пайдаланушы тәжірибесін қамтамасыз етуге рұқсат етеді."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"тарихи желі қолданысын оқу"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Қолданбаға белгілі бір желілер және қолданбалар үшін журналдық желіні пайдалануды оқуға рұқсат береді."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"желі саясатын басқару"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Пайдаланушыға хабар есту қызметінің жоғары деңгейлі интерфейсіне жалғану мүмкіндігін ұсынады. Қалыпты қолданбаны ешқашан қажет етпеуі тиіс."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"шарттар провайдері қызметіне байластыру"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Пайдаланушыға шарт провайдері қызметінің жоғары деңгейлі интерфейсіне байластыруға рұқсат береді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"медианы бағыттау қызметіне байластыру"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Иесіне медиа бағыттау қызметінің жоғарғы деңгейлі интерфейсіне байластыруға рұқсат етеді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"dream қызметіне байластыру"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Иесіне dream қызметінің жоғарғы деңгейлі интерфейсіне байластыруға рұқсат береді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"жабдықтаушы ұсынатын жасақтамалық қолданбаны қосу"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s қолданбасымен бөлісу"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Негізгі қолданбаны таңдау"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Бұл әрекет үшін бастапқы параметрін қолданыңыз."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Басқа қолданбаны пайдалану"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Әдепкі параметрден «Жүйелік параметрлер» &gt; «Қолданбалар» &gt; «Жүктелгендер» тармағында құсбелгіні алу."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Әрекет таңдау"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB құрылғысы үшін қолданбаны таңдау"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Рұқсат беру"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Өшіру"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; қолданбасы &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; мекенжайына хабар жіберуді қалайды."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Бұл ұялы есептік жазбадан "<font fgcolor="#ffffb060">" төлем талап етуі"</font>" мүмкін."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ұялы есептік жазбаңыздан төлемдер талап етілуіне себеп болады."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Бұл мобильді есептік жазбаңызда "<b>"өзгерістер"</b>" тудыруы мүмкін."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Бұл мобильді есептік жазбаңызда өзгерістерді тудырады."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Жіберу"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Бас тарту"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Менің таңдауым есте сақталсын"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB күйін келтіруді өшіру үшін түртіңіз."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Пернетақтаны өзгерту"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Пернетақталарды таңдау"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Қатты пернетақта"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Енгізу әдісін көрсету"</string>
     <string name="hardware" msgid="7517821086888990278">"Компьютерлік жабдық"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Пернетақта орналасуын таңдау"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Пернетақта орналасуын таңдау үшін түртіңіз."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Қолданбаға сенімді агент қызметіне байластыруға рұқсат береді."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Жаңарту және қалпына келтіру жүйелерімен қатынасу"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Қолданбаның қалпына келтіру жүйесімен және жүйе жаңартуларымен қатынасу мүмкіндігін береді."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Тасушыны проекциялау сеанстарын жасау"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Қолданбаға тасушыны проекциялау сеанстарын жасауға рұқсат етеді. Бұл сеанстар қолданбаларға дисплей және аудио мазмұнын түсіру мүмкіндігін қамтамасыз етеді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Тасушыны проекциялау сеанстарын басқару"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Қолданбаға тасушыны проекциялау сеанстарын басқаруға рұқсат етеді. Бұл сеанстар қолданбаларға дисплей және аудио мазмұнын жазу мүмкіндігін қамтамасыз етеді. Қалыпты қолданбалар үшін ешқашан қажет болмайды."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Орнату сеанстарын оқу"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Қолданбаға орнату сеанстарын оқуға рұқсат етеді. Бұл оған белсенді бума орнатулары туралы мәліметтерді көруге рұқсат етеді."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Масштабтауды басқару үшін екі рет түртіңіз"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Бас тарту"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Рұқсат өтінілді"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Рұқсат \nесептік жазба үшін <xliff:g id="ACCOUNT">%s</xliff:g> өтінілді."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Осы қолданбаны жеке кеңістікте пайдаланып жатырсыз"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Осы қолданбаны жұмыс кеңістігінде пайдаланып жатырсыз"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Осы қолданбаны жұмыс профиліңізден тыс пайдаланып жатырсыз"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Осы қолданбаны жұмыс профиліңізде пайдаланып жатырсыз"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Енгізу әдісі"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синх"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Қол жетімділік"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Сағат арттыру"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"КЕШКІ уақытты реттеу"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"ТАҢҒЫ уақытты реттеу"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"түстен кейін"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"түске дейін"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Ай арттыру"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Ай азайту"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Күн арттыру"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Өзгерту"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Дерекқор қолдануға қатысты ескерту"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Қолданыс және параметрлерді көру үшін түртіңіз."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G деректері өшірулі"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G деректері өшірулі"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Ұялы деректер өшірулі"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi деректері өшірулі"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Шекке жеттіңіз"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G деректер шегіне жеттіңіз"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G деректер шегіне жеттіңіз"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Ұялы деректер шегіне жеттіңіз"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi деректер шегіне жеттіңіз"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Циклдің қал. бөл. үшін дер. кід."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2Г-3Г дерекқор шектеуінен асып кетті"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4Ш дерекқор шектеуінен асып кетті"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Ұялы деректер шегі асырылды"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Қоңырауды қабылдау?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Үнемі"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Бір рет қана"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s жұмыс профилін қолдамайды."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s жұмыс профилін қолдамайды"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Планшет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Құлақаспаптар"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Қол жетімділік қосылды."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Қол жетімділік өшірілді."</string>
     <string name="user_switched" msgid="3768006783166984410">"Ағымдағы пайдаланушы <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> ауысу орындалуда…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Пайдаланушы"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Қателік"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Бұл өзгертуге әкімші рұқсат етпеген"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> таңдалды"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> жойылды"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Жұмыс <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Осы экранды босату үшін бір уақытта «Артқа» және «Жақындағылар» түймелерін түртіп, ұстап тұрыңыз."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Осы экранды босату үшін «Жақындағылар» түймесін түртіп, ұстап тұрыңыз."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Экран түйрелген. Босатуға ұйымыңыз рұқсат етпейді."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Экранды түйреуді пайдалану керек пе?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Экранды түйреу дисплейді бір көріністе бекітеді.\n\nШығу үшін бір уақытта «Артқа» және «Жақындағылар» түймелерін түртіп, ұстап тұрыңыз."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Экранды түйреу дисплейді бір көріністе бекітеді.\n\nШығу үшін бір уақытта «Жақындағылар» түймесін түртіп, ұстап тұрыңыз."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ЖОҚ, РАҚМЕТ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"БАСТАУ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"бекітпесін ашу әдісі"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"құпия сөз"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Экран түйрелді"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Экран босатылды"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Босату алдында PIN кодын сұрау"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Босату алдында бекітпесін ашу өрнегін сұрау"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Босату алдында құпия сөзді сұрау"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Батареяның қызмет мерзімін жақсарту үшін батарея үнемдегіш құрылғының өнімділігін азайтады және діріл мен фондық деректердің көпшілігін шектейді. Синхрондауды қажет ететін электрондық пошта, хабар алмасу және басқа қолданбалар ашқанша жаңартылмауы мүмкін.\n\nБатарея үнемдегіш құрылғы зарядталып жатқанда автоматты түрде өшеді."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g> уақытында әрекетсіздік аяқталғанша"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Бір минут бойы"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d минут бойы"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Бір сағат бойы"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d сағат бойы"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Белгісіз уақыт бойы"</string>
 </resources>
diff --git a/core/res/res/values-km-rKH/strings.xml b/core/res/res/values-km-rKH/strings.xml
index f2eaf10..3aa35f2 100644
--- a/core/res/res/values-km-rKH/strings.xml
+++ b/core/res/res/values-km-rKH/strings.xml
@@ -68,7 +68,7 @@
   </plurals>
     <string name="imei" msgid="2625429890869005782">"IMEI"</string>
     <string name="meid" msgid="4841221237681254195">"MEID"</string>
-    <string name="ClipMmi" msgid="6952821216480289285">"លេខ​សម្គាល់​អ្នក​ហៅ​​ចូល"</string>
+    <string name="ClipMmi" msgid="6952821216480289285">"លេខ​សម្គាល់​អ្នក​ហៅ​​ចូល​"</string>
     <string name="ClirMmi" msgid="7784673673446833091">"លេខ​សម្គាល់​អ្នក​ហៅ​ចេញ"</string>
     <string name="ColpMmi" msgid="3065121483740183974">"បាន​ភ្ជាប់​លេខ​សម្គាល់​បន្ទាត់"</string>
     <string name="ColrMmi" msgid="4996540314421889589">"បាន​ភ្ជាប់​ការ​ដាក់កម្រិត​លេខ​សម្គាល់​បន្ទាត់"</string>
@@ -127,7 +127,7 @@
     <string name="cfTemplateRegisteredTime" msgid="6781621964320635172">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g> ៖ មិន​បាន​បញ្ជូន​បន្ត"</string>
     <string name="fcComplete" msgid="3118848230966886575">"កូដ​លក្ខណៈ​ពេញលេញ។"</string>
     <string name="fcError" msgid="3327560126588500777">"បញ្ហា​ការ​តភ្ជាប់​ ឬ​កូដ​លក្ខណៈ​​​មិន​ត្រឹមត្រូវ​។"</string>
-    <string name="httpErrorOk" msgid="1191919378083472204">"យល់​ព្រម"</string>
+    <string name="httpErrorOk" msgid="1191919378083472204">"យល់​ព្រម​"</string>
     <string name="httpError" msgid="7956392511146698522">"មាន​កំហុស​បណ្ដាញ។"</string>
     <string name="httpErrorLookup" msgid="4711687456111963163">"រក​មិន​ឃើញ URL ។"</string>
     <string name="httpErrorUnsupportedAuthScheme" msgid="6299980280442076799">"គ្រោងការណ៍​ផ្ទៀងផ្ទាត់​តំបន់បណ្ដាញ​មិន​ត្រូវ​បាន​គាំទ្រ។"</string>
@@ -185,7 +185,7 @@
     <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"បើក​សំឡេង"</string>
     <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"ពេល​ជិះ​យន្តហោះ"</string>
     <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"បាន​បើក​របៀប​ពេល​ជិះ​យន្ត​ហោះ"</string>
-    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"បាន​បិទ​របៀបពេលជិះ​យន្តហោះ"</string>
+    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"បាន​បិទ​របៀបពេលជិះ​យន្តហោះ​"</string>
     <string name="global_action_settings" msgid="1756531602592545966">"ការ​កំណត់"</string>
     <string name="global_action_lockdown" msgid="8751542514724332873">"ចាក់សោ​ឥឡូវនេះ"</string>
     <string name="status_bar_notification_info_overflow" msgid="5301981741705354993">"999+"</string>
@@ -198,7 +198,7 @@
     <string name="permgrouplab_messages" msgid="7521249148445456662">"សារ​របស់​អ្នក"</string>
     <string name="permgroupdesc_messages" msgid="7821999071003699236">"អាន និង​សរសេរ​សារ SMS, អ៊ីមែល និង​សារ​ផ្សេងៗ​ទៀត​របស់​អ្នក។"</string>
     <string name="permgrouplab_personalInfo" msgid="3519163141070533474">"ព័ត៌មាន​ផ្ទាល់ខ្លួន​របស់​អ្នក"</string>
-    <string name="permgroupdesc_personalInfo" msgid="8426453129788861338">"ចូល​ដំណើរការ​ព័ត៌មាន​ដោយ​ផ្ទាល់​អំពី​អ្នក​ ដែល​បា​ន​រក្សាទុក​ក្នុង​កាត​ទំនាក់ទំនង​របស់​អ្នក។"</string>
+    <string name="permgroupdesc_personalInfo" msgid="8426453129788861338">"ចូល​ដំណើរការ​ព័ត៌មាន​ដោយ​ផ្ទាល់​អំពី​អ្នក​ ដែល​បា​ន​រក្សាទុក​ក្នុង​កាត​ទំនាក់ទំនង​របស់​អ្នក។​"</string>
     <string name="permgrouplab_socialInfo" msgid="5799096623412043791">"ព័ត៌មាន​សង្គម​របស់​អ្នក"</string>
     <string name="permgroupdesc_socialInfo" msgid="7129842457611643493">"ចូល​ដំណើរការ​ព័ត៌មាន​ដោយ​ផ្ទាល់​អំពី​ទំនាក់ទំនង និង​ការ​ភ្ជាប់​សង្គម​របស់​អ្នក។"</string>
     <string name="permgrouplab_location" msgid="635149742436692049">"ទីតាំង​របស់​អ្នក"</string>
@@ -391,7 +391,7 @@
     <string name="permdesc_readInputState" msgid="8387754901688728043">"ឲ្យ​កម្មវិធី​មើល​គ្រាប់​ចុច​ដែល​អ្នក​ចុច​ពេល​មាន​អន្តរកម្ម​ជា​មួយ​កម្មវិធី​ផ្សេង (ដូចជា បញ្ចូល​ពាក្យ​សម្ងាត់)។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_bindInputMethod" msgid="3360064620230515776">"ចង​ទៅ​វិធីសាស្ត្រ​បញ្ចូល"</string>
     <string name="permdesc_bindInputMethod" msgid="3250440322807286331">"ឲ្យ​ម្ចាស់​ចង​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​វិធី​សាស្ត្រ​បញ្ចូល។ មិន​គួរ​​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
-    <string name="permlab_bindAccessibilityService" msgid="5357733942556031593">"ចង​សេវា​កម្ម​ភាព​មធ្យោបាយ​ងាយស្រួល"</string>
+    <string name="permlab_bindAccessibilityService" msgid="5357733942556031593">"ចង​សេវា​កម្ម​ភាព​មធ្យោបាយ​ងាយស្រួល​"</string>
     <string name="permdesc_bindAccessibilityService" msgid="7034615928609331368">"ឲ្យ​​ម្ចាស់​ចង​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​សេវាកម្ម​ភាព​ងាយស្រួល។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_bindPrintService" msgid="8462815179572748761">"ចង​សេវាកម្ម​​បោះពុម្ព"</string>
     <string name="permdesc_bindPrintService" msgid="7960067623209111135">"ឲ្យ​ម្ចាស់​ចង​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​សេវាកម្ម​ធាតុ​ក្រាហ្វិក។ មិន​គួរ​​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
@@ -411,17 +411,15 @@
     <string name="permdesc_manageVoiceKeyphrases" msgid="8476560722907530008">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​គ្រប់គ្រង​ឃ្លា​​សម្រាប់​​ការ​រក​ឃើញ​​​ពាក្យ​​ជា​សំឡេង។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_bindRemoteDisplay" msgid="1782923938029941960">"ភ្ជាប់​ទៅ​ការ​បង្ហាញ​ពី​ចម្ងាយ"</string>
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​ភ្ជាប់​​ទៅ​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​ការ​បង្ហាញ​ពី​ចម្ងាយ។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
-    <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ចង​សេវា​កម្ម​ធាតុ​ក្រាហ្វិក"</string>
+    <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ចង​សេវា​កម្ម​ធាតុ​ក្រាហ្វិក​"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ឲ្យ​ម្ចាស់​ចង​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​សេវាកម្ម​ធាតុ​ក្រាហ្វិក។ មិន​គួរ​​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"ភ្ជាប់​ទៅ​សេវាកម្ម​ក្រុមហ៊ុន​ផ្ដល់​ច្រក"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​ភ្ជាប់​ទៅ​ក្រុមហ៊ុន​ផ្ដល់​​ច្រក​ដែល​បាន​ចុះ​ឈ្មោះ។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ទាក់ទង​ជា​មួយ​អ្នកគ្រប់គ្រង​ឧបករណ៍"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ឲ្យ​ម្ចាស់​ផ្ញើ​គោលបំណង​​ទៅ​អ្នក​គ្រប់គ្រង​ឧបករណ៍។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ភ្ជាប់​ទៅ​ការ​បញ្ចូល​ទូរទស្សន៍"</string>
     <string name="permdesc_bindTvInput" msgid="2371008331852001924">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​ភ្ជាប់​ទៅ​ចំណុចប្រទាក់​កម្រិត​ខ្ពស់​នៃ​ការ​បញ្ចូល​ទូរទស្សន៍។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_modifyParentalControls" msgid="4611318225997592242">"កែប្រែ​ការ​ត្រួតពិនិត្យ​មាតាបិតា"</string>
     <string name="permdesc_modifyParentalControls" msgid="7438482894162282039">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​​កែប្រែ​ទិន្នន័យ​ការ​ត្រួតពិនិត្យ​មាតាបិតា​​របស់​ប្រព័ន្ធ​។ គួរ​តែ​មិន​ត្រូវការ​សម្រាប់​កម្មវិធី​ធម្មតា​។"</string>
-    <string name="permlab_manageDeviceAdmins" msgid="4248828900045808722">"បន្ថែម​ ឬ​លុប​កម្មវិធី​គ្រប់គ្រង​​​ឧបករណ៍"</string>
+    <string name="permlab_manageDeviceAdmins" msgid="4248828900045808722">"បន្ថែម​ ឬ​លុប​កម្មវិធី​គ្រប់គ្រង​​​ឧបករណ៍​​"</string>
     <string name="permdesc_manageDeviceAdmins" msgid="5025608167709942485">"អនុញ្ញាត​​​ឲ្យ​ម្ចាស់​​​បន្ថែម​ ឬ​លុប​កម្មវិធី​គ្រប់គ្រង​ឧបករណ៍​សកម្ម​ចេញ​។ មិន​គួរ​ប្រើ​សម្រាប់​កម្មវិធី​​ធម្មតា​ទេ​។"</string>
     <string name="permlab_setOrientation" msgid="3365947717163866844">"ប្ដូរ​ទិស​អេក្រង់"</string>
     <string name="permdesc_setOrientation" msgid="3046126619316671476">"ឲ្យ​កម្មវិធី​ប្ដូរ​ការ​បង្វិល​អេក្រង់​នៅ​ពេល​ណា​មួយ។ មិន​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
@@ -433,9 +431,9 @@
     <string name="permdesc_signalPersistentProcesses" msgid="4896992079182649141">"ឲ្យ​កម្មវិធី​ស្នើ​​សញ្ញា​ដែល​បាន​ផ្ដល់​ត្រូវ​ផ្ញើ​ទៅ​ដំណើរការ​ស្ថិតស្ថេរ​​ទាំង​អស់។"</string>
     <string name="permlab_persistentActivity" msgid="8841113627955563938">"ធ្វើ​ឲ្យ​កម្មវិធី​ដំណើរការ​ជា​និច្ច"</string>
     <string name="permdesc_persistentActivity" product="tablet" msgid="8525189272329086137">"ឲ្យ​កម្មវិធី​ធ្វើជា​ផ្នែក​​ស្ថិតស្ថេរ​ដោយ​ខ្លួន​ឯង​ក្នុង​អង្គ​ចងចាំ។ វា​អាច​កំណត់​អង្គ​ចងចាំ​ដែល​អាច​ប្រើ​បាន​ចំពោះ​កម្មវិធី​ផ្សេងៗ​ ដោយ​ធ្វើឲ្យ​កុំព្យូទ័រ​បន្ទះ​យឺត។"</string>
-    <string name="permdesc_persistentActivity" product="default" msgid="4384760047508278272">"ឲ្យ​កម្មវិធី ធ្វើជា​ផ្នែក​អចិន្ត្រៃយ៍​នៃ​ខ្លួន​ក្នុង​អង្គ​ចងចាំ។ វា​អាច​កម្រិត​អង្គ​ចងចាំ​អាច​ប្រើ​បាន​ ដើម្បី​ធ្វើ​ឲ្យ​កម្មវិធី​ផ្សេង​ធ្វើ​ឲ្យ​ទូរស័ព្ទ​របស់​អ្នក​យឺត។"</string>
+    <string name="permdesc_persistentActivity" product="default" msgid="4384760047508278272">"ឲ្យ​កម្មវិធី ធ្វើជា​ផ្នែក​អចិន្ត្រៃយ៍​នៃ​ខ្លួន​ក្នុង​អង្គ​ចងចាំ។ វា​អាច​កម្រិត​អង្គ​ចងចាំ​អាច​ប្រើ​បាន​ ដើម្បី​ធ្វើ​ឲ្យ​កម្មវិធី​ផ្សេង​ធ្វើ​ឲ្យ​ទូរស័ព្ទ​របស់​អ្នក​យឺត។​"</string>
     <string name="permlab_deletePackages" msgid="184385129537705938">"លុប​កម្មវិធី"</string>
-    <string name="permdesc_deletePackages" msgid="7411480275167205081">"ឲ្យ​កម្មវិធី​លុប​កញ្ចប់ Android ។ កម្មវិធី​ព្យាបាទ​អាច​ប្រើ​វា ដើម្បី​លុប​កម្មវិធី​សំខាន់​ៗ។"</string>
+    <string name="permdesc_deletePackages" msgid="7411480275167205081">"ឲ្យ​កម្មវិធី​លុប​កញ្ចប់ Android ។ កម្មវិធី​ព្យាបាទ​អាច​ប្រើ​វា ដើម្បី​លុប​កម្មវិធី​សំខាន់​ៗ។ ​"</string>
     <string name="permlab_clearAppUserData" msgid="274109191845842756">"លុប​ទិន្នន័យ​របស់​​កម្មវិធី​ផ្សេង"</string>
     <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"ឲ្យ​កម្មវិធី​សម្អាត​ទិន្នន័យ​អ្នក​ប្រើ។"</string>
     <string name="permlab_deleteCacheFiles" msgid="3128665571837408675">"លុប​ឃ្លាំង​សម្ងាត់​កម្មវិធី​ផ្សេងៗ"</string>
@@ -486,7 +484,7 @@
     <string name="permdesc_writeContacts" product="tablet" msgid="897243932521953602">"ឲ្យ​កម្មវិធី​កែ​ទិន្នន័យ​អំពី​ទំនាក់ទំនង​របស់​អ្នក​ដែល​បាន​រក្សាទុក​ក្នុង​កុំព្យូទ័រ​បន្ទះ រួមមាន​ប្រេកង់​​ដែល​អ្នក​បាន​ហៅ អ៊ីមែល ឬ​ទាក់ទង​តាម​វិធី​ផ្សេងៗ​ជា​មួយ​ទំនាក់ទំនង​ជាក់លាក់។ សិទ្ធិ​​នេះ​អនុញ្ញាត​ឲ្យ​​​កម្មវិធី​លុប​ទិន្នន័យ​ទំនាក់ទំនង​របស់​អ្នក។"</string>
     <string name="permdesc_writeContacts" product="default" msgid="589869224625163558">"ឲ្យ​កម្មវិធី​កែ​ទិន្នន័យ​អំពី​ទំនាក់ទំនង​របស់​អ្នក​ដែល​បាន​រក្សាទុក​ក្នុង​ទូរស័ព្ទ​របស់​អ្នក រួមមាន​ប្រេកង់​ដែល​អ្នក​បាន​ហៅ អ៊ីមែល ឬ​បាន​ទាក់ទង​​តាម​វិធី​ផ្សេងៗ​ជា​មួយ​ទំនាក់​ទំនាក់​ជាក់លាក់។ សិទ្ធិ​នេះ​ឲ្យ​កម្មវិធី​លុប​ទិន្នន័យ​ទំនាក់ទំនង។"</string>
     <string name="permlab_readCallLog" msgid="3478133184624102739">"អាន​​កំណត់​ហេតុ​​​ហៅ"</string>
-    <string name="permdesc_readCallLog" product="tablet" msgid="3700645184870760285">"ឲ្យ​កម្មវិធី​អាន​បញ្ជី​ហៅ​កុំព្យូទ័រ​បន្ទះ​របស់​អ្នក រួមមាន​ទិន្នន័យ​អំពី​ការ​ហៅ​ចូល និង​ចេញ។ សិទ្ធិ​នេះ​អនុញ្ញាត​ឲ្យ​កម្មវិធី​រក្សាទុក​ទិន្នន័យ​បញ្ជី​ហៅ​របស់​អ្នក ហើយ​កម្មវិធី​ព្យាបាទ​អាច​ចែករំលែក​ទិន្នន័យ​បញ្ជី​ហៅ​ដោយ​មិន​ឲ្យ​អ្នក​ដឹង។"</string>
+    <string name="permdesc_readCallLog" product="tablet" msgid="3700645184870760285">"ឲ្យ​កម្មវិធី​អាន​បញ្ជី​ហៅ​កុំព្យូទ័រ​បន្ទះ​របស់​អ្នក រួមមាន​ទិន្នន័យ​អំពី​ការ​ហៅ​ចូល និង​ចេញ។ សិទ្ធិ​នេះ​អនុញ្ញាត​ឲ្យ​កម្មវិធី​រក្សាទុក​ទិន្នន័យ​បញ្ជី​ហៅ​របស់​អ្នក ហើយ​កម្មវិធី​ព្យាបាទ​អាច​ចែករំលែក​ទិន្នន័យ​បញ្ជី​ហៅ​ដោយ​មិន​ឲ្យ​អ្នក​ដឹង។​"</string>
     <string name="permdesc_readCallLog" product="default" msgid="5777725796813217244">"ឲ្យ​កម្មវិធី​អាន​​​បញ្ជី​ហៅ​ទូរស័ព្ទ​របស់​អ្នក រួមមាន​ទិន្នន័យ​អំពី​ការ​ហៅ​ចូល និង​ចេញ។ សិទ្ធិ​នេះ​អនុញ្ញាត​ឲ្យ​កម្មវិធី​រក្សាទុក​ទិន្នន័យ​បញ្ជី​ហៅ​របស់​អ្នក ហើយ​កម្មវិធី​ព្យាបាទ​អាច​ចែករំលែក​ទិន្នន័យ​បញ្ជី​ហៅ​ដោយ​មិន​ឲ្យ​អ្នកដឹង។"</string>
     <string name="permlab_writeCallLog" msgid="8552045664743499354">"សរសេរ​បញ្ជី​ហៅ"</string>
     <string name="permdesc_writeCallLog" product="tablet" msgid="6661806062274119245">"ឲ្យ​កម្មវិធី​កែ​បញ្ជី​ហៅ​កុំព្យូទ័រ​បន្ទះ​របស់​អ្នក​រួមមាន​ទិន្នន័យ​អំពី​ការ​ហៅ​ចូល និង​ចេញ។​កម្មវិធី​ព្យាបាទ​អាច​ប្រើ​វា ដើម្បី​លុប ឬ​កែ​បញ្ជី​ហៅ​របស់​អ្នក។"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"បិទ/បើក​ទូរស័ព្ទ"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ឲ្យ​កម្មវិធី​បិទ/បើក​កុំព្យូទ័រ​បន្ទះ។"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ឲ្យ​កម្មវិធី​បិទ/បើក​ទូរស័ព្ទ។"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"កំណត់​ការ​អស់​ពេល​បង្ហាញ​ឡើងវិញ"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"ឲ្យ​កម្មវិធី​កំណត់​ការ​អស់​ពេល​បង្ហាញ​ឡើងវិញ។"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ដំណើរការ​ក្នុង​របៀប​សាកល្បង​ពី​រោងចក្រ"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ដំណើរការ​សាកល្បង​ក្រុមហ៊ុន​ផលិត​កម្រិត​ទាប ដោយ​អនុញ្ញាត​ឲ្យ​ចូល​ផ្នែក​រឹង​កុំព្យូទ័រ​បន្ទះ។ អាច​ប្រើ​​បាន​តែ​ពេល​កុំព្យូទ័រ​កំពុង​ដំណើរការ​ក្នុង​របៀប​សាកល្បង​ក្រុមហ៊ុន​ផលិត។"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ដំណើរ​ការ​ការ​សាកល្បង​ក្រុមហ៊ុន​ផលិត​កម្រិត​ទាប ដោយ​អនុញ្ញាត​ការ​ចូល​ដំណើរការ​ផ្នែក​រឹង​ទូរស័ព្ទ។ អាច​ប្រើ​បាន​តែ​នៅ​ពេល​ទូរស័ព្ទ​កំពុង​ដំណើរការ​របៀប​សាកល្បង​ក្រុមហ៊ុន​ផលិត។"</string>
@@ -622,7 +622,7 @@
     <string name="permdesc_setWallpaperHints" msgid="8235784384223730091">"ឲ្យ​កម្មវិធី​កំណត់​ជំនួយ​ទំហំ​ផ្ទាំង​រូបភាព​ប្រព័ន្ធ។"</string>
     <string name="permlab_masterClear" msgid="2315750423139697397">"កំណត់​ប្រព័ន្ធ​ទៅ​លំនាំដើម​រោងចក្រ​ឡើងវិញ"</string>
     <string name="permdesc_masterClear" msgid="3665380492633910226">"ឲ្យ​កម្មវិធី​កំណត់​ប្រព័ន្ធ​​ដូច​ការ​កំណត់​ចេញ​ពី​រោងចក្រ​ឡើងវិញ​ពេញលេញ ដោយ​លុប​ទិន្នន័យ ការ​កំណត់​រចនាសម្ព័ន្ធ និង​កម្មវិធី​បាន​ដំឡើង។"</string>
-    <string name="permlab_setTime" msgid="2021614829591775646">"កំណត់​​ម៉ោង"</string>
+    <string name="permlab_setTime" msgid="2021614829591775646">"កំណត់​​ម៉ោង​"</string>
     <string name="permdesc_setTime" product="tablet" msgid="1896341438151152881">"ឲ្យ​កម្មវិធី​ប្ដូរ​ម៉ោង​កុំព្យូទ័រ​បន្ទះ។"</string>
     <string name="permdesc_setTime" product="default" msgid="1855702730738020">"ឲ្យ​កម្មវិធី​ប្ដូរ​ម៉ោង​ទូរស័ព្ទ។"</string>
     <string name="permlab_setTimeZone" msgid="2945079801013077340">"កំណត់​តំបន់​ពេលវេលា"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ឲ្យ​កម្មវិធី​អាន និង​សរសេរ​ប្រព័ន្ធ​ឯកសារ​ឃ្លាំង​សម្ងាត់។"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"បង្កើត/ទទួល ការ​ហៅ SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"​ឲ្យ​​កម្មវិធី បង្កើត និង​ទទួល​ការ​ហៅ SIP ។"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ទាក់ទង​ជា​មួយ​អេក្រង់​ហៅ​ចូល"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ឲ្យ​កម្មវិធី​ពិនិត្យ​ពេលវេលា និង​វិធី​ដែល​អ្នកប្រើ​មើល​ឃើញ​អេក្រង់​ហៅ​ចូល។"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ទាក់ទង​ជា​មួយ​អេក្រង់​ហៅ​ចូល"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ឲ្យ​កម្មវិធី​ពិនិត្យ​ពេលវេលា និង​វិធី​ដែល​អ្នកប្រើ​មើល​ឃើញ​អេក្រង់​ហៅ​ចូល។"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ទាក់ទង​ជា​មួយ​សេវាកម្ម​ទូរស័ព្ទ"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"ឲ្យ​កម្មវិធី​ទាក់ទង​ជា​មួយ​សេវាកម្ម​ទូរស័ព្ទ ដើម្បី​ហៅ/ទទួល​ការ​ហៅ។"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ផ្ដល់​​បទពិសោធន៍​អ្នក​ប្រើ​ហៅ​ចូល"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ឲ្យ​កម្មវិធី​ផ្ដល់​បទពិសោធន៍​អ្នក​ប្រើ​ហៅ​ចូល។"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"អាន​ការ​ប្រើ​បណ្ដាញ​ពិសេស"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"ឲ្យ​កម្មវិធី​អាន​ការ​ប្រើ​បណ្ដាញ​ជា​ប្រវត្តិ​សាស្ត្រ​សម្រាប់​បណ្ដាញ និង​កម្មវិធី​ជាក់លាក់។"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"គ្រប់គ្រង​គោលនយោបាយ​បណ្ដាញ"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ឲ្យ​ម្ចាស់​ចង​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​សេវាកម្ម​កម្មវិធី​ស្ដាប់​ការ​ជូន​ដំណឹង។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​​ទេ។"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"ភ្ជាប់​ទៅ​សេវាកម្ម​ក្រុមហ៊ុន​ផ្ដល់​លក្ខខណ្ឌ"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​ភ្ជាប់​ទៅ​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​​របស់​សេវាកម្ម​ក្រុមហ៊ុន​ផ្ដល់​លក្ខខណ្ឌ។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"ភ្ជាប់​​ទៅ​សេវា​ផ្លូវ​មេឌៀ"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​​ភ្ជាប់​​ទៅ​ចំណុច​ប្រទាក់​ពេញ​និយម​នៃ​សេវាកម្ម​ផ្លូវ​មេឌៀ​។ មិន​គួរ​ចាំបាច់​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ​។"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ភ្ជាប់​ទៅ​សេវាកម្ម​ស្រមោល​ស្រមៃ"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"អនុញ្ញាត​ឲ្យ​ម្ចាស់​ភ្ជាប់​ទៅ​ចំណុច​ប្រទាក់​កម្រិត​កំពូល​នៃ​សេវាកម្ម​ស្រមើ​ស្រមៃ។ មិន​គួរ​ចាំបាច់​​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ដកហូត​កម្មវិធី​កំណត់​រចនាសម្ព័ន្ធ​ដែល​បាន​ផ្ដល់​ដោយ​ក្រុមហ៊ុន​បញ្ជូន"</string>
@@ -801,7 +799,7 @@
   <string-array name="organizationTypes">
     <item msgid="7546335612189115615">"កន្លែង​ធ្វើការ"</item>
     <item msgid="4378074129049520373">"ផ្សេងៗ"</item>
-    <item msgid="3455047468583965104">"តាម​តម្រូវ​ការ"</item>
+    <item msgid="3455047468583965104">"តាម​តម្រូវ​ការ​"</item>
   </string-array>
   <string-array name="imProtocols">
     <item msgid="8595261363518459565">"AIM"</item>
@@ -817,7 +815,7 @@
     <string name="phoneTypeHome" msgid="2570923463033985887">"ផ្ទះ"</string>
     <string name="phoneTypeMobile" msgid="6501463557754751037">"​ចល័ត"</string>
     <string name="phoneTypeWork" msgid="8863939667059911633">"កន្លែង​ធ្វើការ"</string>
-    <string name="phoneTypeFaxWork" msgid="3517792160008890912">"ទូរសារ​កន្លែង​ធ្វើការ"</string>
+    <string name="phoneTypeFaxWork" msgid="3517792160008890912">"ទូរសារ​កន្លែង​ធ្វើការ​"</string>
     <string name="phoneTypeFaxHome" msgid="2067265972322971467">"ទូរសារ​ផ្ទះ"</string>
     <string name="phoneTypePager" msgid="7582359955394921732">"ភេយ័រ"</string>
     <string name="phoneTypeOther" msgid="1544425847868765990">"ផ្សេងៗ"</string>
@@ -944,7 +942,7 @@
     <string name="lockscreen_glogin_too_many_attempts" msgid="2751368605287288808">"ព្យាយាម​លំនាំ​ច្រើន​ពេក"</string>
     <string name="lockscreen_glogin_instructions" msgid="3931816256100707784">"ដើម្បី​ដោះ​សោ ចូល​គណនី Google របស់​អ្នក។"</string>
     <string name="lockscreen_glogin_username_hint" msgid="8846881424106484447">"ឈ្មោះ​អ្នក​ប្រើ (អ៊ីមែល​)"</string>
-    <string name="lockscreen_glogin_password_hint" msgid="5958028383954738528">"ពាក្យសម្ងាត់"</string>
+    <string name="lockscreen_glogin_password_hint" msgid="5958028383954738528">"ពាក្យសម្ងាត់​"</string>
     <string name="lockscreen_glogin_submit_button" msgid="7130893694795786300">"ចូល"</string>
     <string name="lockscreen_glogin_invalid_input" msgid="1364051473347485908">"ឈ្មោះ​អ្នកប្រើ ឬ​ពាក្យ​សម្ងាត់​មិន​ត្រឹមត្រូវ។"</string>
     <string name="lockscreen_glogin_account_recovery_hint" msgid="1696924763690379073">"ភ្លេច​ឈ្មោះ​អ្នក​ប្រើ ឬ​ពាក្យ​សម្ងាត់​របស់​អ្នក?\nមើល "<b>"google.com/accounts/recovery"</b>" ។"</string>
@@ -989,7 +987,7 @@
     <string name="factorytest_failed" msgid="5410270329114212041">"បាន​បរាជ័យ​ក្នុង​ការ​សាកល្បង​រោងចក្រ"</string>
     <string name="factorytest_not_system" msgid="4435201656767276723">"សកម្មភាព FACTORY_TEST ត្រូវ​បាន​គាំទ្រ​សម្រាប់​តែ​កញ្ចប់​បាន​ដំឡើង​ក្នុង /system/app."</string>
     <string name="factorytest_no_action" msgid="872991874799998561">"រក​មិន​ឃើញ​កញ្ចប់​ដែល​ផ្ដល់​សកម្មភាព FACTORY_TEST ។"</string>
-    <string name="factorytest_reboot" msgid="6320168203050791643">"ចាប់​ផ្ដើម​ឡើង​វិញ"</string>
+    <string name="factorytest_reboot" msgid="6320168203050791643">"ចាប់​ផ្ដើម​ឡើង​វិញ​"</string>
     <string name="js_dialog_title" msgid="1987483977834603872">"ទំព័រ​មាន​ចំណងជើង \"<xliff:g id="TITLE">%s</xliff:g>\" សរសេរ៖"</string>
     <string name="js_dialog_title_default" msgid="6961903213729667573">"JavaScript"</string>
     <string name="js_dialog_before_unload_title" msgid="2619376555525116593">"បញ្ជាក់​ការ​រុករក"</string>
@@ -1051,7 +1049,7 @@
     <string name="prepend_shortcut_label" msgid="2572214461676015642">"ម៉ឺនុយ +"</string>
     <string name="menu_space_shortcut_label" msgid="2410328639272162537">"ដកឃ្លា"</string>
     <string name="menu_enter_shortcut_label" msgid="2743362785111309668">"enter"</string>
-    <string name="menu_delete_shortcut_label" msgid="3658178007202748164">"លុប"</string>
+    <string name="menu_delete_shortcut_label" msgid="3658178007202748164">"លុប​"</string>
     <string name="search_go" msgid="8298016669822141719">"ស្វែងរក"</string>
     <string name="searchview_description_search" msgid="6749826639098512120">"ស្វែងរក"</string>
     <string name="searchview_description_query" msgid="5911778593125355124">"ស្វែងរក​សំណួរ"</string>
@@ -1135,18 +1133,18 @@
     <string name="preposition_for_date" msgid="9093949757757445117">"នៅ <xliff:g id="DATE">%s</xliff:g>"</string>
     <string name="preposition_for_time" msgid="5506831244263083793">"នៅ​ម៉ោង <xliff:g id="TIME">%s</xliff:g>"</string>
     <string name="preposition_for_year" msgid="5040395640711867177">"ក្នុង​ឆ្នាំ <xliff:g id="YEAR">%s</xliff:g>"</string>
-    <string name="day" msgid="8144195776058119424">"ថ្ងៃ"</string>
+    <string name="day" msgid="8144195776058119424">"ថ្ងៃ​"</string>
     <string name="days" msgid="4774547661021344602">"​ថ្ងៃ"</string>
     <string name="hour" msgid="2126771916426189481">"ម៉ោង"</string>
     <string name="hours" msgid="894424005266852993">"ម៉ោង"</string>
-    <string name="minute" msgid="9148878657703769868">"នាទី"</string>
+    <string name="minute" msgid="9148878657703769868">"នាទី​"</string>
     <string name="minutes" msgid="5646001005827034509">"នាទី"</string>
-    <string name="second" msgid="3184235808021478">"វិនាទី"</string>
+    <string name="second" msgid="3184235808021478">"វិនាទី​"</string>
     <string name="seconds" msgid="3161515347216589235">"វិនាទី"</string>
-    <string name="week" msgid="5617961537173061583">"សប្ដាហ៍"</string>
-    <string name="weeks" msgid="6509623834583944518">"សប្ដាហ៍"</string>
-    <string name="year" msgid="4001118221013892076">"ឆ្នាំ"</string>
-    <string name="years" msgid="6881577717993213522">"ឆ្នាំ"</string>
+    <string name="week" msgid="5617961537173061583">"សប្ដាហ៍​"</string>
+    <string name="weeks" msgid="6509623834583944518">"សប្ដាហ៍​"</string>
+    <string name="year" msgid="4001118221013892076">"ឆ្នាំ​"</string>
+    <string name="years" msgid="6881577717993213522">"ឆ្នាំ​"</string>
   <plurals name="duration_seconds">
     <item quantity="one" msgid="6962015528372969481">"1 វិនាទី"</item>
     <item quantity="other" msgid="1886107766577166786">"<xliff:g id="COUNT">%d</xliff:g> វិនាទី"</item>
@@ -1162,12 +1160,12 @@
     <string name="VideoView_error_title" msgid="3534509135438353077">"បញ្ហា​វីដេអូ"</string>
     <string name="VideoView_error_text_invalid_progressive_playback" msgid="3186670335938670444">"វីដេអូ​នេះ​មិន​ត្រឹមត្រូវ​សម្រាប់​​ចរន្ត​ចូល​ឧបករណ៍​នេះ។"</string>
     <string name="VideoView_error_text_unknown" msgid="3450439155187810085">"មិន​អាច​ចាក់​វីដេអូ​នេះ។"</string>
-    <string name="VideoView_error_button" msgid="2822238215100679592">"យល់​ព្រម"</string>
+    <string name="VideoView_error_button" msgid="2822238215100679592">"យល់​ព្រម​"</string>
     <string name="relative_time" msgid="1818557177829411417">"<xliff:g id="DATE">%1$s</xliff:g>, <xliff:g id="TIME">%2$s</xliff:g>"</string>
     <string name="noon" msgid="7245353528818587908">"រសៀល"</string>
     <string name="Noon" msgid="3342127745230013127">"រសៀល"</string>
     <string name="midnight" msgid="7166259508850457595">"កណ្ដាលអធ្រាត្រ"</string>
-    <string name="Midnight" msgid="5630806906897892201">"កណ្ដាល​អធ្រាត្រ"</string>
+    <string name="Midnight" msgid="5630806906897892201">"កណ្ដាល​អធ្រាត្រ​"</string>
     <string name="elapsed_time_short_format_mm_ss" msgid="4431555943828711473">"<xliff:g id="MINUTES">%1$02d</xliff:g>:<xliff:g id="SECONDS">%2$02d</xliff:g>"</string>
     <string name="elapsed_time_short_format_h_mm_ss" msgid="1846071997616654124">"<xliff:g id="HOURS">%1$d</xliff:g>:<xliff:g id="MINUTES">%2$02d</xliff:g>:<xliff:g id="SECONDS">%3$02d</xliff:g>"</string>
     <string name="selectAll" msgid="6876518925844129331">"ជ្រើស​ទាំងអស់"</string>
@@ -1184,13 +1182,13 @@
     <string name="inputMethod" msgid="1653630062304567879">"វិធីសាស្ត្រ​បញ្ចូល"</string>
     <string name="editTextMenuTitle" msgid="4909135564941815494">"សកម្មភាព​អត្ថបទ"</string>
     <string name="low_internal_storage_view_title" msgid="5576272496365684834">"អស់​ទំហំ​ផ្ទុក"</string>
-    <string name="low_internal_storage_view_text" msgid="6640505817617414371">"មុខងារ​ប្រព័ន្ធ​មួយ​ចំនួន​អាច​មិន​ដំណើរការ"</string>
+    <string name="low_internal_storage_view_text" msgid="6640505817617414371">"មុខងារ​ប្រព័ន្ធ​មួយ​ចំនួន​អាច​មិន​ដំណើរការ​"</string>
     <string name="app_running_notification_title" msgid="8718335121060787914">"<xliff:g id="APP_NAME">%1$s</xliff:g> កំពុង​ដំណើរការ"</string>
     <string name="app_running_notification_text" msgid="4653586947747330058">"ប៉ះ​ ដើម្បី​មើល​ព័ត៌មាន​បន្ថែម ឬ​បញ្ឈប់​កម្មវិធី។"</string>
-    <string name="ok" msgid="5970060430562524910">"យល់​ព្រម"</string>
-    <string name="cancel" msgid="6442560571259935130">"បោះ​បង់"</string>
-    <string name="yes" msgid="5362982303337969312">"យល់​ព្រម"</string>
-    <string name="no" msgid="5141531044935541497">"បោះ​បង់"</string>
+    <string name="ok" msgid="5970060430562524910">"យល់​ព្រម​"</string>
+    <string name="cancel" msgid="6442560571259935130">"បោះ​បង់​"</string>
+    <string name="yes" msgid="5362982303337969312">"យល់​ព្រម​"</string>
+    <string name="no" msgid="5141531044935541497">"បោះ​បង់​"</string>
     <string name="dialog_alert_title" msgid="2049658708609043103">"ប្រយ័ត្ន"</string>
     <string name="loading" msgid="7933681260296021180">"កំពុង​ផ្ទុក..."</string>
     <string name="capital_on" msgid="1544682755514494298">"បើក"</string>
@@ -1207,8 +1205,9 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"ចែករំលែក​ជាមួយ"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ជ្រើស​កម្មវិធី​ដើម"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ប្រើ​តាម​លំនាំដើម​សម្រាប់​សកម្មភាព​នេះ។"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"ប្រើ​កម្មវិធី​ផ្សេង"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"សម្អាត​លំនាំដើម​ក្នុង​ការកំណត់​ប្រព័ន្ធ &gt; កម្មវិធី &gt; ទាញ​យក។"</string>
-    <string name="chooseActivity" msgid="7486876147751803333">"ជ្រើស​សកម្មភាព"</string>
+    <string name="chooseActivity" msgid="7486876147751803333">"ជ្រើស​សកម្មភាព​​"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"ជ្រើស​កម្មវិធី​សម្រាប់​ឧបករណ៍​យូអេសប៊ី"</string>
     <string name="noApplications" msgid="2991814273936504689">"គ្មាន​កម្មវិធី​អាច​អនុវត្ត​សកម្មភាព​នេះ។"</string>
     <string name="aerr_title" msgid="1905800560317137752"></string>
@@ -1219,7 +1218,7 @@
     <string name="anr_activity_process" msgid="5776209883299089767">"សកម្មភាព <xliff:g id="ACTIVITY">%1$s</xliff:g> មិន​ឆ្លើយតប។\n\nតើ​អ្នក​ចង់​បិទ​វា?"</string>
     <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g> មិន​ឆ្លើយតប។ តើ​អ្នក​ចង់​បិទ​វា?"</string>
     <string name="anr_process" msgid="6513209874880517125">"ដំណើរការ <xliff:g id="PROCESS">%1$s</xliff:g> មិន​ឆ្លើយតប។ \n\nតើ​អ្នក​ចង់​បិទ​វា​ឬ?"</string>
-    <string name="force_close" msgid="8346072094521265605">"យល់​ព្រម"</string>
+    <string name="force_close" msgid="8346072094521265605">"យល់​ព្រម​"</string>
     <string name="report" msgid="4060218260984795706">"រាយការណ៍"</string>
     <string name="wait" msgid="7147118217226317732">"រង់ចាំ"</string>
     <string name="webpage_unresponsive" msgid="3272758351138122503">"ទំព័រ​ក្លាយ​ជា​មិន​ឆ្លើយតប។\n\nតើ​អ្នក​​ចង់​បិទ​វា?"</string>
@@ -1298,10 +1297,10 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"អនុញ្ញាត"</string>
     <string name="sms_control_no" msgid="625438561395534982">"បដិសេធ"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ចង់​ផ្ញើ​សារ​ទៅ &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; ។"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"នេះ​អាច​កាត់​លុយ"</font>" លើ​គណនី​ចល័ត​របស់​អ្នក។"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"វា​នឹង​គិត​ថ្លៃ​សេវាកម្ម​លើ​គណនី​ចល័ត​របស់​អ្នក។"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"វា "<b>"អាច​គិត​លុយ"</b>" លើ​គណនី​ចល័ត​របស់​អ្នក។"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"វា​នឹង​គិតលុយ​គណនី​ចល័ត​របស់​អ្នក។"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ផ្ញើ"</string>
-    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"បោះ​បង់"</string>
+    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"បោះ​បង់​"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ចងចាំ​ជម្រើស​របស់​ខ្ញុំ"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"អ្នក​អាច​ប្ដូរ​វា​ពេល​ក្រោយ​ក្នុង​ការ​កំណត់ &gt; កម្មវិធី"</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"អនុញ្ញាត​ជា​និច្ច"</string>
@@ -1312,8 +1311,8 @@
     <string name="sim_added_title" msgid="3719670512889674693">"បាន​បន្ថែម​ស៊ីម​កាត"</string>
     <string name="sim_added_message" msgid="7797975656153714319">"ចាប់ផ្ដើម​ឧបករណ៍​របស់​អ្នក​ឡើងវិញ ដើម្បី​ចូល​ប្រើ​បណ្ដាញ​ចល័ត។"</string>
     <string name="sim_restart_button" msgid="4722407842815232347">"ចាប់ផ្ដើម​ឡើងវិញ"</string>
-    <string name="time_picker_dialog_title" msgid="8349362623068819295">"កំណត់​ម៉ោង"</string>
-    <string name="date_picker_dialog_title" msgid="5879450659453782278">"កំណត់​កាល​បរិច្ឆេទ"</string>
+    <string name="time_picker_dialog_title" msgid="8349362623068819295">"កំណត់​ម៉ោង​"</string>
+    <string name="date_picker_dialog_title" msgid="5879450659453782278">"កំណត់​កាល​បរិច្ឆេទ​"</string>
     <string name="date_time_set" msgid="5777075614321087758">"កំណត់"</string>
     <string name="date_time_done" msgid="2507683751759308828">"រួចរាល់"</string>
     <string name="perms_new_perm_prefix" msgid="8257740710754301407"><font size="12" fgcolor="#ff33b5e5">"ថ្មី៖ "</font></string>
@@ -1354,7 +1353,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"ប៉ះ ដើម្បី​បិទ​ការ​កែ​កំហុស​យូអេសប៊ី។"</string>
     <string name="select_input_method" msgid="8547250819326693584">"ប្ដូរ​ក្ដារចុច"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"ជ្រើស​ក្ដារចុច"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ក្ដារ​ចុច​​ពិតប្រាកដ"</string>
+    <string name="show_ime" msgid="9157568568695230830">"បង្ហាញ​វិធី​សាស្ត្រ​បញ្ចូល"</string>
     <string name="hardware" msgid="7517821086888990278">"ផ្នែក​រឹង"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"ជ្រើស​ប្លង់​ក្ដារ​ចុច"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"ប៉ះ ​ដើម្បី​ជ្រើស​ប្លង់​​ក្ដារចុច។"</string>
@@ -1391,7 +1390,7 @@
     <string name="permdesc_copyProtectedData" msgid="4390697124288317831">"ឲ្យ​កម្មវិធី​ដក​សេវាកម្ម​នៃ​កម្មវិធី​ផ្ទុក​​លំនាំដើម ដើម្បី​ចម្លង​មាតិកា។​ មិន​សម្រាប់​ប្រើ​ដោយ​កម្មវិធី​លំនាំដើម។"</string>
     <string name="permlab_route_media_output" msgid="1642024455750414694">"នាំ​ផ្លូវ​លទ្ធផល​មេឌៀ"</string>
     <string name="permdesc_route_media_output" msgid="4932818749547244346">"ឲ្យ​កម្មវិធី​នាំ​ផ្លូវ​លទ្ធផល​មេឌៀ​ទៅ​ឧបករណ៍​​ខាង​ក្រៅ​ផ្សេង។"</string>
-    <string name="permlab_access_keyguard_secure_storage" msgid="7565552237977815047">"ចូល​ដំណើរការ​ឧបករណ៍​ផ្ទុក​សុវត្ថិភាព"</string>
+    <string name="permlab_access_keyguard_secure_storage" msgid="7565552237977815047">"ចូល​ដំណើរការ​ឧបករណ៍​ផ្ទុក​សុវត្ថិភាព​"</string>
     <string name="permdesc_access_keyguard_secure_storage" msgid="5866245484303285762">"ឲ្យ​កម្មវិធី​ចូល​​ការ​ផ្ទុក​មាន​សុវត្ថិភាព keguard ។"</string>
     <string name="permlab_control_keyguard" msgid="172195184207828387">"ពិនិត្យ​ការ​បង្ហាញ និង​លាក់​ការ​ការពារ"</string>
     <string name="permdesc_control_keyguard" msgid="3043732290518629061">"ឲ្យ​កម្មវិធី​គ្រប់គ្រង keguard ។"</string>
@@ -1405,8 +1404,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"អនុញ្ញាត​ឲ្យ​កម្មវិធី​ភ្ជាប់​សេវាកម្ម​ភ្នាក់ងារ​ដែល​ទុក​ចិត្ត។"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"អន្តរកម្ម​ជា​មួយ​បច្ចុប្បន្នភាព និង​ប្រព័ន្ធ​សង្គ្រោះ"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"ឲ្យ​កម្មវិធី​មាន​អន្តរកម្ម​ជា​មួយ​ប្រព័ន្ធ​សង្គ្រោះ និង​បច្ចុប្បន្នភាព​ប្រព័ន្ធ។"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"បង្កើត​សម័យ​គម្រោង​មេឌៀ"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"ឲ្យ​កម្មវិធី​បង្កើត​សម័យ​គម្រោង​មេឌៀ។ សម័យ​ទាំងនេះ​​អាច​​ធ្វើឲ្យ​កម្មវិធី​មានលទ្ធភាព​ចាប់​យក​​មាតិកា​​នៃ​ការ​បង្ហាញ និង​សំឡេង។ មិន​គួរ​ចាំបាច់​​សម្រាប់​កម្មវិធី​ធម្មតា​ទេ។"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"គ្រប់គ្រង​សម័យ​​ការ​បង្ហាញ​​មេឌៀ"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"ឲ្យ​កម្មវិធី​គ្រប់គ្រង​សម័យ​ការ​បង្ហាញ​​មេឌៀ។ សម័យ​ទាំង​នេះ​អាច​​ឲ្យ​កម្មវិធី​ចាប់​យក​មាតិកា​​​បង្ហាញ និង​អូឌីយ៉ូ។ មិន​គួរ​ចាំបាច់​ដោយ​កម្មវិធី​ធម្មតា​ទេ។"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"អាន​សម័យ​ដំឡើង"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ឲ្យ​កម្មវិធី​អាន​សម័យ​ដំឡើង។ វា​អនុញ្ញាត​ឲ្យ​ឃើញ​ព័ត៌មាន​លម្អិត​អំពី​​ការដំឡើង​កញ្ចប់​សកម្ម។"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ប៉ះ​ពីរ​ដង ​​ដើម្បី​គ្រប់គ្រង​ការ​ពង្រីក"</string>
@@ -1414,7 +1413,7 @@
     <string name="ime_action_go" msgid="8320845651737369027">"ទៅ"</string>
     <string name="ime_action_search" msgid="658110271822807811">"ស្វែងរក"</string>
     <string name="ime_action_send" msgid="2316166556349314424">"ផ្ញើ"</string>
-    <string name="ime_action_next" msgid="3138843904009813834">"បន្ទាប់"</string>
+    <string name="ime_action_next" msgid="3138843904009813834">"បន្ទាប់​"</string>
     <string name="ime_action_done" msgid="8971516117910934605">"រួចរាល់"</string>
     <string name="ime_action_previous" msgid="1443550039250105948">"មុន"</string>
     <string name="ime_action_default" msgid="2840921885558045721">"អនុវត្ត"</string>
@@ -1423,12 +1422,12 @@
     <string name="grant_credentials_permission_message_header" msgid="2106103817937859662">"កម្មវិធី​មួយ ឬ​ច្រើន​ដូច​ខាង​ក្រោម​ស្នើ​សិទ្ធិ ដើម្បី​ចូល​គណនី​របស់​អ្នក​ឥឡូវ និង​ពេល​អនាគត។"</string>
     <string name="grant_credentials_permission_message_footer" msgid="3125211343379376561">"តើ​អ្នក​ចង់​អនុញ្ញាត​សំណើ​នេះ?"</string>
     <string name="grant_permissions_header_text" msgid="6874497408201826708">"ស្នើ​ចូល"</string>
-    <string name="allow" msgid="7225948811296386551">"អនុញ្ញាត"</string>
+    <string name="allow" msgid="7225948811296386551">"អនុញ្ញាត​"</string>
     <string name="deny" msgid="2081879885755434506">"បដិសេធ"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"បាន​ស្នើ​សិទ្ធិ"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"បាន​ស្នើ​សិទ្ធិ\nសម្រាប់​គណនី <xliff:g id="ACCOUNT">%s</xliff:g> ។"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"អ្នក​កំពុង​ប្រើ​កម្មវិធី​នេះ​ក្នុង​ទំហំ​ផ្ទាល់ខ្លួន​របស់​អ្នក"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"អ្នក​កំពុង​ប្រើ​កម្មវិធី​នេះ​ក្នុង​ទំហំ​ការងារ​របស់​អ្នក"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"អ្នក​កំពុង​ប្រើ​កម្មវិធី​នេះ​នៅ​ខាងក្រៅ​ប្រវត្តិរូប​​ការងារ​របស់​អ្នក"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"អ្នក​កំពុង​ប្រើ​កម្មវិធី​នេះ​ក្នុង​ប្រវត្តិរូប​ការងារ​របស់​អ្នក"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"វិធីសាស្ត្រ​បញ្ចូល"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ធ្វើ​សម​កាល​កម្ម"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ភាព​ងាយស្រួល"</string>
@@ -1448,12 +1447,12 @@
     <string name="no_file_chosen" msgid="6363648562170759465">"គ្មាន​ឯកសារ​បាន​ជ្រើស"</string>
     <string name="reset" msgid="2448168080964209908">"កំណត់​ឡើងវិញ"</string>
     <string name="submit" msgid="1602335572089911941">"ដាក់​ស្នើ"</string>
-    <string name="car_mode_disable_notification_title" msgid="3164768212003864316">"បាន​បើក​របៀប​រថយន្ត"</string>
+    <string name="car_mode_disable_notification_title" msgid="3164768212003864316">"បាន​បើក​របៀប​រថយន្ត​"</string>
     <string name="car_mode_disable_notification_message" msgid="8035230537563503262">"ប៉ះ​ ដើម្បី​ចេញ​ពី​របៀប​រថយន្ត​។"</string>
     <string name="tethered_notification_title" msgid="3146694234398202601">"ភ្ជាប់ ឬ​ហតស្ពត​សកម្ម"</string>
     <string name="tethered_notification_message" msgid="6857031760103062982">"ប៉ះ​ ដើម្បី​រៀបចំ។"</string>
     <string name="back_button_label" msgid="2300470004503343439">"ថយក្រោយ"</string>
-    <string name="next_button_label" msgid="1080555104677992408">"បន្ទាប់"</string>
+    <string name="next_button_label" msgid="1080555104677992408">"បន្ទាប់​"</string>
     <string name="skip_button_label" msgid="1275362299471631819">"រំលង"</string>
     <string name="no_matches" msgid="8129421908915840737">"គ្មាន​ការ​ផ្គូផ្គង"</string>
     <string name="find_on_page" msgid="1946799233822820384">"រក​ក្នុង​ទំព័រ"</string>
@@ -1475,7 +1474,7 @@
     <string name="media_shared" product="nosdcard" msgid="5830814349250834225">"ឧបករណ៍​ផ្ទុក​យូអេសប៊ី​បច្ចុប្បន្ន​កំពុង​ប្រើ​ដោយ​កុំព្យូទ័រ។"</string>
     <string name="media_shared" product="default" msgid="5706130568133540435">"បច្ចុប្បន្ន​កាត​អេសឌី​កំពុង​ប្រើ​ដោយ​កុំព្យូទ័រ"</string>
     <string name="media_unknown_state" msgid="729192782197290385">"មិន​ស្គាល់​ស្ថានភាព​មេឌៀ​ខាង​ក្រៅ។"</string>
-    <string name="share" msgid="1778686618230011964">"ចែក​រំលែក"</string>
+    <string name="share" msgid="1778686618230011964">"ចែក​រំលែក​"</string>
     <string name="find" msgid="4808270900322985960">"រក"</string>
     <string name="websearch" msgid="4337157977400211589">"ស្វែងរក​តាម​បណ្ដាញ"</string>
     <string name="find_next" msgid="5742124618942193978">"រក​បន្ទាប់"</string>
@@ -1491,7 +1490,7 @@
     <string name="sync_undo_deletes" msgid="2941317360600338602">"មិន​ធ្វើ​ការ​លុប​វិញ"</string>
     <string name="sync_do_nothing" msgid="3743764740430821845">"មិន​ធ្វើអ្វី​ទេ​ឥឡូវ"</string>
     <string name="choose_account_label" msgid="5655203089746423927">"ជ្រើស​គណនី"</string>
-    <string name="add_account_label" msgid="2935267344849993553">"បន្ថែម​គណនី​ថ្មី"</string>
+    <string name="add_account_label" msgid="2935267344849993553">"បន្ថែម​គណនី​ថ្មី​​"</string>
     <string name="add_account_button_label" msgid="3611982894853435874">"បន្ថែម​គណនី"</string>
     <string name="number_picker_increment_button" msgid="2412072272832284313">"បង្កើន"</string>
     <string name="number_picker_decrement_button" msgid="476050778386779067">"បន្ថយ"</string>
@@ -1503,8 +1502,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"បន្ថយ​ម៉ោង"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"កំណត់​ PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"កំណត់ AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ល្ងាច"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ព្រឹក"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"បង្កើន​ខែ"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"បន្ថយ​ខែ"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"បង្កើន​ថ្ងៃ"</string>
@@ -1512,15 +1509,15 @@
     <string name="date_picker_increment_year_button" msgid="6318697384310808899">"បង្កើន​​ឆ្នាំ"</string>
     <string name="date_picker_decrement_year_button" msgid="4482021813491121717">"បន្ថយ​ឆ្នាំ"</string>
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Alt"</string>
-    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"បោះ​បង់"</string>
+    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"បោះ​បង់​"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"លុប"</string>
     <string name="keyboardview_keycode_done" msgid="1992571118466679775">"រួចរាល់"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"ប្ដូរ​របៀប"</string>
     <string name="keyboardview_keycode_shift" msgid="2270748814315147690">"Shift"</string>
     <string name="keyboardview_keycode_enter" msgid="2985864015076059467">"Enter"</string>
-    <string name="activitychooserview_choose_application" msgid="2125168057199941199">"ជ្រើស​កម្មវិធី"</string>
+    <string name="activitychooserview_choose_application" msgid="2125168057199941199">"ជ្រើស​កម្មវិធី​​"</string>
     <string name="activitychooserview_choose_application_error" msgid="8624618365481126668">"មិន​អាច​ចាប់ផ្ដើម <xliff:g id="APPLICATION_NAME">%s</xliff:g>"</string>
-    <string name="shareactionprovider_share_with" msgid="806688056141131819">"ចែករំលែក​ជា​មួយ"</string>
+    <string name="shareactionprovider_share_with" msgid="806688056141131819">"ចែករំលែក​ជា​មួយ​"</string>
     <string name="shareactionprovider_share_with_application" msgid="5627411384638389738">"ចែក​រំលែក​ជា​មួយ <xliff:g id="APPLICATION_NAME">%s</xliff:g>"</string>
     <string name="content_description_sliding_handle" msgid="415975056159262248">"គ្រប់គ្រង​ការ​រុញ។ ប៉ះ &amp; សង្កត់។"</string>
     <string name="description_target_unlock_tablet" msgid="3833195335629795055">"អូស​ ដើម្បី​ដោះ​សោ។"</string>
@@ -1534,14 +1531,14 @@
     <string name="storage_internal" msgid="4891916833657929263">"ឧបករណ៍​ផ្ទុក​ខាង​ក្នុង"</string>
     <string name="storage_sd_card" msgid="3282948861378286745">"កាត​អេសឌី"</string>
     <string name="storage_usb" msgid="3017954059538517278">"ឧបករណ៍​ផ្ទុក​យូអេសប៊ី"</string>
-    <string name="extract_edit_menu_button" msgid="8940478730496610137">"កែសម្រួល"</string>
+    <string name="extract_edit_menu_button" msgid="8940478730496610137">"កែសម្រួល​"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ការព្រមាន​ប្រើ​ទិន្នន័យ"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ប៉ះ ដើម្បី​មើល​ការ​ប្រើ និង​ការ​កំណត់។"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"ទិន្នន័យ 2G-3G បាន​បិទ"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"ទិន្នន័យ 4G បាន​បិទ"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"ទិន្នន័យ​ចល័ត​បាន​បិទ"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"ទិន្នន័យ​វ៉ាយហ្វាយ​បាន​បិទ"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"បាន​ដល់​ដែន​កំណត់"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"បាន​ដល់​ដែន​កំណត់​ទិន្នន័យ 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"បាន​ដល់​ដែន​កំណត់​ទិន្នន័យ 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"បាន​ដល់​ដែន​កំណត់​ទិន្នន័យ​ចល័ត"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"បានដល់ដែន​កំណត់ទិន្នន័យវ៉ាយហ្វាយ"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ផ្អាកទិន្នន័យសម្រាប់រយៈពេលនៅសល់"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"លើស​ដែន​កំណត់​ទិន្នន័យ 2G​-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"បាន​លើស​ដែន​កំណត់​ទិន្នន័យ 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"បាន​លើស​ដែន​កំណត់​ទិន្នន័យ​ចល័ត"</string>
@@ -1572,7 +1569,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"ទទួល​ការ​ហៅ​?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ជា​និច្ច"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"តែ​ម្ដង"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s មិន​គាំទ្រ​ជីវប្រវត្តិ​ការងារ"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s មិន​គាំទ្រ​ប្រវត្តិរូប​ការងារ"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"កុំព្យូទ័រ​បន្ទះ"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ទូរស័ព្ទ"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"កាស"</string>
@@ -1583,7 +1580,7 @@
     <string name="wireless_display_route_description" msgid="9070346425023979651">"បង្ហាញ​បណ្ដាញ​ឥត​ខ្សែ"</string>
     <string name="media_route_button_content_description" msgid="591703006349356016">"បញ្ជូន"</string>
     <string name="media_route_chooser_title" msgid="1751618554539087622">"ភ្ជាប់​ឧបករណ៍"</string>
-    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"ចាត់​ថ្នាក់​អេក្រង់​ទៅ​ឧបករណ៍"</string>
+    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"ខាស​អេក្រង់​ទៅ​ឧបករណ៍"</string>
     <string name="media_route_chooser_searching" msgid="4776236202610828706">"កំពុង​ស្វែងរក​ឧបករណ៍..."</string>
     <string name="media_route_chooser_extended_settings" msgid="87015534236701604">"ការ​កំណត់"</string>
     <string name="media_route_controller_disconnect" msgid="8966120286374158649">"ផ្ដាច់"</string>
@@ -1592,7 +1589,7 @@
     <string name="media_route_status_available" msgid="6983258067194649391">"ទំនេរ"</string>
     <string name="media_route_status_not_available" msgid="6739899962681886401">"មិន​ទំនេរ"</string>
     <string name="media_route_status_in_use" msgid="4533786031090198063">"កំពុង​ប្រើ"</string>
-    <string name="display_manager_built_in_display_name" msgid="2583134294292563941">"អេក្រង់​ជាប់"</string>
+    <string name="display_manager_built_in_display_name" msgid="2583134294292563941">"អេក្រង់​ជាប់​"</string>
     <string name="display_manager_hdmi_display_name" msgid="1555264559227470109">"អេក្រង់ HDMI"</string>
     <string name="display_manager_overlay_display_name" msgid="5142365982271620716">"#<xliff:g id="ID">%1$d</xliff:g> ត្រួត​គ្នា"</string>
     <string name="display_manager_overlay_display_title" msgid="652124517672257172">"<xliff:g id="NAME">%1$s</xliff:g>: <xliff:g id="WIDTH">%2$d</xliff:g>x<xliff:g id="HEIGHT">%3$d</xliff:g>, <xliff:g id="DPI">%4$d</xliff:g> dpi"</string>
@@ -1624,7 +1621,7 @@
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"ព្យាយាម​លំនាំ​ច្រើន​ពេក"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"ដើម្បី​ដោះ​សោ ចូល​ក្នុង​គណនី Google ។"</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"ឈ្មោះ​អ្នក​ប្រើ (អ៊ី​ម៉ែ​ល​)"</string>
-    <string name="kg_login_password_hint" msgid="9057289103827298549">"ពាក្យសម្ងាត់"</string>
+    <string name="kg_login_password_hint" msgid="9057289103827298549">"ពាក្យសម្ងាត់​"</string>
     <string name="kg_login_submit_button" msgid="5355904582674054702">"ចូល"</string>
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"ឈ្មោះ​អ្នកប្រើ ឬ​ពាក្យ​សម្ងាត់​មិន​ត្រឹមត្រូវ។"</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"ភ្លេច​ឈ្មោះ​អ្នកប្រើ ឬ​ពាក្យ​សម្ងាត់​របស់​អ្នក?\nមើល "<b>"google.com/accounts/recovery"</b>" ។"</string>
@@ -1645,6 +1642,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"បាន​បើក​មធ្យោបាយ​ងាយស្រួល​។"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"បាន​បោះបង់​ភាព​ងាយស្រួល។"</string>
     <string name="user_switched" msgid="3768006783166984410">"អ្នក​ប្រើ​បច្ចុប្បន្ន <xliff:g id="NAME">%1$s</xliff:g> ។"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"កំពុង​ប្ដូរ​ទៅ <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ម្ចាស់"</string>
     <string name="error_message_title" msgid="4510373083082500195">"កំហុស"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ការ​ផ្លាស់ប្ដូរ​នេះ​មិន​ត្រូវ​បាន​អនុញ្ញាត​ដោយ​អ្នក​គ្រប់គ្រង​របស់​អ្នក​ទេ"</string>
@@ -1733,7 +1731,7 @@
     <string name="mediasize_japanese_you4" msgid="2091777168747058008">"You4"</string>
     <string name="mediasize_unknown_portrait" msgid="3088043641616409762">"​មិន​ស្គាល់​បញ្ឈរ"</string>
     <string name="mediasize_unknown_landscape" msgid="4876995327029361552">"មិន​ស្គាល់​ទេសភាព"</string>
-    <string name="write_fail_reason_cancelled" msgid="7091258378121627624">"បាន​បោះ​បង់"</string>
+    <string name="write_fail_reason_cancelled" msgid="7091258378121627624">"បាន​បោះ​បង់​"</string>
     <string name="write_fail_reason_cannot_write" msgid="8132505417935337724">"កំហុស​ក្នុង​ការ​សរសេរ​មាតិកា"</string>
     <string name="reason_unknown" msgid="6048913880184628119">"មិន​ស្គាល់"</string>
     <string name="reason_service_unavailable" msgid="7824008732243903268">"មិន​បា​ន​បើក​សេវាកម្ម​បោះពុម្ព"</string>
@@ -1766,31 +1764,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"បាន​ជ្រើស <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"បាន​លុប <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"កន្លែង​ធ្វើការ <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ដើម្បី​​ផ្ដាច់​​អេក្រង់ ប៉ះ និង​សង្កត់​ថយក្រោយ និង​​បច្ចុប្បន្ន​នៅ​ពេល​តែ​មួយ។"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ដើម្បី​ផ្ដាច់​អេក្រង់​នេះ ប៉ះ និង​សង្កត់​បច្ចុប្បន្ន។"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"អេក្រង់​ត្រូវ​បាន​ភ្ជាប់។ ការ​ផ្ដាច់​មិន​​ត្រូវ​បាន​អនុញ្ញាត​ដោយ​ស្ថាប័ន​របស់​អ្នក។"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"ប្រើ​ការ​ភ្ជាប់​អេក្រង់?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"ការ​ភ្ជាប់​អេក្រង់​ចាក់សោ​​ការ​បង្ហាញ​ក្នុង​ទិដ្ឋភាព​​តែ​មួយ។\n\nដើម្បី​ចាកចេញ ប៉ះ​ និង​សង្កត់​ថយក្រោយ និង​​​បច្ចុប្បន្ន​​​ក្នុង​ពេល​តែ​មួយ។"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"ការ​ភ្ជាប់​អេក្រង់​ចាក់សោ​​ការ​បង្ហាញ​ក្នុង​ទិដ្ឋភាព​​តែ​មួយ។\n\nដើម្បី​ចាកចេញ ប៉ះ​ និង​​​សង្កត់​បច្ចុប្បន្ន​។"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ទេ, ​​អរគុណ!"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ចាប់ផ្ដើម"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"កូដ PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"លំនាំ​ដោះ​សោ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"ពាក្យ​សម្ងាត់"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"បាន​ភ្ជាប់​អេក្រង់"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"មិន​បាន​ភ្ជាប់​អេក្រង់"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"សួរ​រក​កូដ PIN មុន​ពេល​ផ្ដាច់"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"សួរ​រក​លំនាំ​ដោះ​សោ​មុន​ពេល​ផ្ដាច់"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"សួរ​រក​ពាក្យ​សម្ងាត់​មុន​ពេល​ផ្ដាច់"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ដើម្បី​បង្កើន​អាយុ​ថ្ម កម្មវិធី​សន្សំ​ថ្ម​កាត់​បន្ថយ​ការអនុវត្ត​ឧបករណ៍​របស់​អ្នក​ ហើយ​​កម្រិត​ការ​ញ័រ និង​ទិន្នន័យ​ផ្ទៃ​ខាង​ក្រោយ។ អ៊ីមែល, ការ​ផ្ញើ​សារ និង​កម្មវិធី​ផ្សេងៗ​ទៀត​ដែល​ផ្អែក​លើ​ការ​ធ្វើ​សម​កាល​កម្ម​​​មិន​អាច​ធ្វើ​បច្ចុប្បន្នភាព​លុះ​ត្រា​តែ​អ្នក​បើក​ពួកវា។\n\nកម្មវិធី​សន្សំ​ថ្ម​បិទ​ដោយ​ស្វ័យ​ប្រវត្តិ​ពេល​ឧបករណ៍​របស់​អ្នក​កំពុង​បញ្ចូល​ថ្ម។"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"រហូត​ដល់ម៉ោង​សម្រាក ឬរវល់​របស់​អ្នក​បញ្ចប់​នៅ <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"សម្រាប់​មួយ​នាទី"</item>
+    <item quantity="other" msgid="6924190729213550991">"សម្រាប់ %d នាទី"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"សម្រាប់​មួយ​ម៉ោង"</item>
+    <item quantity="other" msgid="5408537517529822157">"សម្រាប់ %d ម៉ោង"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"គ្មាន​​កំណត់"</string>
 </resources>
diff --git a/core/res/res/values-kn-rIN/strings.xml b/core/res/res/values-kn-rIN/strings.xml
index 2e5fbee..951989d 100644
--- a/core/res/res/values-kn-rIN/strings.xml
+++ b/core/res/res/values-kn-rIN/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ರಿಮೋಟ್ ಪ್ರದರ್ಶನದ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗಾಗಿ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ವಿಜೆಟ್ ಸೇವೆಗೆ ಪ್ರತಿಬಂಧಿಸಿ"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ವಿಜೆಟ್‌‌ ಸೇವೆಯ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ನೀಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"ಮಾರ್ಗ ಪೂರೈಕೆದಾರರ ಸೇವೆಯನ್ನು ಪ್ರತಿಬಂಧಿಸು"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ಯಾವುದೇ ನೋಂದಾಯಿತ ಪೂರೈಕೆದಾರರನ್ನು ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ಸಾಧನ ನಿರ್ವಾಹಕರ ಜೊತೆಗೆ ಸಂವಹನ ನಡೆಸಿ"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ಸಾಧನ ನಿರ್ವಾಹಕರಿಗೆ ಉದ್ದೇಶಗಳನ್ನು ಕಳುಹಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗಾಗಿ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV ಇನ್‌ಪುಟ್‌‌ ಅನ್ನು ಪ್ರತಿಬಂಧಿಸು"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ಫೋನ್ ಆನ್ ಅಥವಾ ಆಫ್ ಮಾಡಿ"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ಟ್ಯಾಬ್ಲೆಟ್‌‌ ಅನ್ನು ಆನ್‌‌ ಅಥವಾ ಆಫ್‌ ಮಾಡಲು ಅಪ್ಲಿಕೇಶನ್‌ ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ಫೋನ್‌ ಅನ್ನು ಆನ್‌‌ ಅಥವಾ ಆಫ್‌ ಮಾಡಲು ಅಪ್ಲಿಕೇಶನ್‌ ಅನುಮತಿಸುತ್ತದೆ."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ಪ್ರದರ್ಶನ ಅವಧಿ ಮೀರುವಿಕೆಯನ್ನು ಮರುಹೊಂದಿಸಿ"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"ಪ್ರದರ್ಶನ ಅವಧಿ ಮೀರುವಿಕೆಯನ್ನು ಮರುಹೊಂದಿಸಲು ಅಪ್ಲಿಕೇಶನ್ ಅನ್ನು ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ಫ್ಯಾಕ್ಟರಿ ಪರೀಕ್ಷೆಯ ಮೋಡ್‌ನಲ್ಲಿ ರನ್ ಮಾಡಿ"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ಟ್ಯಾಬ್ಲೆಟ್ ಹಾರ್ಡ್‌ವೇರ್‌ಗೆ ಸಂಪೂರ್ಣ ಪ್ರವೇಶವನ್ನು ಕಲ್ಪಿಸುವ ಮೂಲಕ ಕೆಳಮಟ್ಟದ ತಯಾರಕರ ಪರೀಕ್ಷೆಯ ರೂಪದಲ್ಲಿ ರನ್ ಆಗುತ್ತದೆ. ತಯಾರಕರ ಪರೀಕ್ಷೆಯ ಮೋಡ್‌ನಲ್ಲಿ ಟ್ಯಾಬ್ಲೆಟ್ ರನ್ ಆಗುತ್ತಿರುವಾಗ ಮಾತ್ರ ಲಭ್ಯವಿರುತ್ತದೆ."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ಫೋನ್ ಹಾರ್ಡ್‌ವೇರ್‌ಗೆ ಸಂಪೂರ್ಣ ಪ್ರವೇಶವನ್ನು ಅನುಮತಿಸುವ ಮೂಲಕ, ಕೆಳಮಟ್ಟದ ತಯಾರಕರ ಪರೀಕ್ಷೆಯ ರೂಪದಲ್ಲಿ ರನ್ ಮಾಡಿ. ತಯಾರಕರ ಪರೀಕ್ಷೆಯ ಮೋಡ್‌ನಲ್ಲಿ ಫೋನ್ ರನ್ ಆಗುತ್ತಿರುವಾಗ ಮಾತ್ರ ಲಭ್ಯವಿದೆ."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ಕ್ಯಾಷ್‌ ಫೈಲ್‌ ವ್ಯವಸ್ಥೆಯನ್ನು ಓದಲು ಮತ್ತು ಬರೆಯಲು ಅಪ್ಲಿಕೇಶನ್‌‌ ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP ಕರೆಗಳನ್ನು ಮಾಡಿ/ಸ್ವೀಕರಿಸಿ"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP ಕರೆಗಳನ್ನು ಮಾಡಲು ಮತ್ತು ಸ್ವೀಕರಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌‌ಗೆ ಅನುಮತಿಸುತ್ತದೆ."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ಒಳ-ಕರೆ ಪರದೆಯ ಮೂಲಕ ಸಂವಹನ ನಡೆಸಿ"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ಬಳಕೆದಾರರು ಒಳ-ಕರೆಯ ಪರದೆಯನ್ನು ಯಾವಾಗ ಮತ್ತು ಹೇಗೆ ನೋಡುತ್ತಾರೆ ಎಂಬುದನ್ನು ನಿಯಂತ್ರಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ಒಳ-ಕರೆ ಪರದೆಯ ಮೂಲಕ ಸಂವಹನ ನಡೆಸಿ"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ಬಳಕೆದಾರರು ಒಳ-ಕರೆಯ ಪರದೆಯನ್ನು ಯಾವಾಗ ಮತ್ತು ಹೇಗೆ ನೋಡುತ್ತಾರೆ ಎಂಬುದನ್ನು ನಿಯಂತ್ರಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ಟೆಲಿಫೋನಿ ಸೇವೆಗಳೊಂದಿಗೆ ಸಂವಾದ ನಡೆಸಿ"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"ಕರೆಗಳನ್ನು ಮಾಡಲು/ಸ್ವೀಕರಿಸುವ ನಿಟ್ಟಿನಲ್ಲಿ ಲಿಫೋನಿ ಸೇವೆಗಳ ಜೊತೆ ಸಂವಾದ ನಡೆಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅವಕಾಶ ಮಾಡಕೊಡಿ."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ಒಳ ಕರೆ ಬಳಕೆದಾರರ ಅನುಭವವನ್ನು ಒದಗಿಸಿ"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ಒಳ ಕರೆಯ ಬಳಕೆದಾರರ ಅನುಭವವನ್ನು ಒದಗಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌ ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ಐತಿಹಾಸಿಕ ನೆಟ್‌ವರ್ಕ್ ಬಳಕೆಯನ್ನು ಓದಿರಿ"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"ನಿರ್ದಿಷ್ಟ ನೆಟ್‌ವರ್ಕ್‌ಗಳು ಮತ್ತು ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಐತಿಹಾಸಿಕ ನೆಟ್‌ವರ್ಕ್‌ನ ಬಳಕೆಯನ್ನು ಓದಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ನೆಟ್‌ವರ್ಕ್ ನೀತಿಯನ್ನು ನಿರ್ವಹಿಸಿ"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ಅಧಿಸೂಚನೆ ಕೇಳುಗ ಸೇವೆಯ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"ಕಂಡೀಶನ್‌‌ ಪೂರೈಕೆದಾರರ ಸೇವೆಯನ್ನು ಪ್ರತಿಬಂಧಿಸು"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"ಕಂಡೀಶನ್‌ ಪೂರೈಕೆದಾರರ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"ಮಾಧ್ಯಮ ಮಾರ್ಗ ಸೇವೆಯನ್ನು ಪ್ರತಿಬಂಧಿಸು"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"ಮಾಧ್ಯಮ ವರ್ಗ ಸೇವೆಯ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಹೊಂದಿರುವವರಿಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ಕನಸಿನ ಸೇವೆಗೆ ಪ್ರತಿಬಂಧಿಸಿ"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ಕನಸಿನ ಸೇವೆಯ ಮೇಲ್ಮಟ್ಟದ ಇಂಟರ್ಫೇಸ್‌ಗೆ ಪ್ರತಿಬಂಧಿಸಲು ಮಾಲೀಕರಿಗೆ ಅವಕಾಶ ನೀಡುತ್ತದೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ವಾಹಕ-ಒದಗಿಸಿರುವ ಕಾನ್ಫಿಗರೇಶನ್ ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ವಿನಂತಿಸಿಕೊಳ್ಳಿ"</string>
@@ -753,7 +751,7 @@
     <string name="policylab_watchLogin" msgid="914130646942199503">"ಪರದೆಯ-ಅನ್‌ಲಾಕ್ ಪ್ರಯತ್ನಗಳನ್ನು ಮಾನಿಟರ್ ಮಾಡಿ"</string>
     <string name="policydesc_watchLogin" product="tablet" msgid="3215729294215070072">"ಪರದೆಯನ್ನು ಅನ್‌ಲಾಕ್‌ ಮಾಡುವಾಗ ತಪ್ಪಾಗಿ ಟೈಪ್‌ ಮಾಡಿದ ಪಾಸ್‌ವರ್ಡ್‌ಗಳ ಸಂಖ್ಯೆಯನ್ನು ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಿ, ಮತ್ತು ಟ್ಯಾಬ್ಲೆಟ್‌ ಅನ್ನು ಲಾಕ್‌ ಮಾಡಿ ಅಥವಾ ಹಲವಾರು ತಪ್ಪಾದ ಪಾಸ್‌ವರ್ಡ್‌ಗಳನ್ನು ಟೈಪ್‌ ಮಾಡಿದ್ದರೆ ಟ್ಯಾಬ್ಲೆಟ್‌ನ ಎಲ್ಲಾ ಡೇಟಾವನ್ನು ಅಳಿಸಿಹಾಕಿ."</string>
     <string name="policydesc_watchLogin" product="default" msgid="5712323091846761073">"ಪರದೆಯನ್ನು ಅನ್‌ಲಾಕ್‌ ಮಾಡಿದಾಗ ತಪ್ಪಾಗಿ ಟೈಪ್‌ ಮಾಡಿದ ಪಾಸ್‌ವರ್ಡ್‌ಗಳ ಸಂಖ್ಯೆಯನ್ನು ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಿ, ಮತ್ತು ಫೋನ್‌‌ ಅನ್ನು ಲಾಕ್‌ ಮಾಡಿ ಅಥವಾ ಹಲವಾರು ತಪ್ಪಾದ ಪಾಸ್‌ವರ್ಡ್‌ಗಳನ್ನು ಟೈಪ್‌ ಮಾಡಿದ್ದರೆ ಫೋನ್‌‌ನ ಎಲ್ಲಾ ಡೇಟಾವನ್ನು ಅಳಿಸಿಹಾಕಿ."</string>
-    <string name="policylab_resetPassword" msgid="2620077191242688955">"ಪರದೆ-ಅನ್‌ಲಾಕ್ ಪಾಸ್‌ವರ್ಡ್ ಅನ್ನು ಬದಲಾಯಿಸಿ"</string>
+    <string name="policylab_resetPassword" msgid="2620077191242688955">"ಸ್ಕ್ರೀನ್‌-ಅನ್‌ಲಾಕ್ ಪಾಸ್‌ವರ್ಡ್ ಅನ್ನು ಬದಲಾಯಿಸಿ"</string>
     <string name="policydesc_resetPassword" msgid="605963962301904458">"ಪರದೆಯ-ಅನ್‍‍ಲಾಕ್ ಪಾಸ್‍ವರ್ಡ್ ಬದಲಾಯಿಸಿ."</string>
     <string name="policylab_forceLock" msgid="2274085384704248431">"ಪರದೆ ಲಾಕ್ ಮಾಡಿ"</string>
     <string name="policydesc_forceLock" msgid="1141797588403827138">"ಪರದೆಯು ಯಾವಾಗ ಮತ್ತು ಹೇಗೆ ಲಾಕ್ ಆಗಬೇಕೆಂಬುದನ್ನು ನಿಯಂತ್ರಿಸಿ."</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s ಜೊತೆಗೆ ಹಂಚಿಕೊಳ್ಳಿ"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ಹೋಮ್ ಅಪ್ಲಿಕೇಶನ್ ಆಯ್ಕೆಮಾಡಿ"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ಈ ಕ್ರಿಯೆಗೆ ಡೀಫಾಲ್ಟ್ ಆಗಿ ಬಳಸಿ."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"ಬೇರೆಯ ಅಪ್ಲಿಕೇಶನ್ ಬಳಸಿ"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"ಸಿಸ್ಟಂ ಸೆಟ್ಟಿಂಗ್‌ಗಳು &gt; ಅಪ್ಲಿಕೇಶನ್‌ಗಳು &gt; ಡೌನ್‌ಲೋಡ್ ಮಾಡಲಾದ ಡೀಫಾಲ್ಟ್‌‌ ಅನ್ನು ತೆರವುಗೊಳಿಸಿ."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ಕ್ರಿಯೆಯನ್ನು ಆಯ್ಕೆಮಾಡಿ"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB ಸಾಧನಕ್ಕೆ ಅಪ್ಲಿಕೇಶನ್‌‌ವೊಂದನ್ನು ಆಯ್ಕೆಮಾಡಿ"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"ಅನುಮತಿಸು"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ನಿರಾಕರಿಸು"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; ಗೆ ಸಂದೇಶವನ್ನು ಕಳುಹಿಸಲು &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ಬಯಸುತ್ತದೆ."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ಇದು ನಿಮ್ಮ ಮೊಬೈಲ್ ಖಾತೆಯಲ್ಲಿ "<font fgcolor="#ffffb060">"ಶುಲ್ಕಗಳನ್ನು ವಿಧಿಸುವುದಕ್ಕೆ ಕಾರಣವಾಗಬಹುದು"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"ಇದು ನಿಮ್ಮ ಮೊಬೈಲ್ ಖಾತೆಯಲ್ಲಿ ಶುಲ್ಕಗಳನ್ನು ವಿಧಿಸುವುದಕ್ಕೆ ಕಾರಣವಾಗುತ್ತದೆ."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"ಇದು ನಿಮ್ಮ ಮೊಬೈಲ್ ಖಾತೆಯಲ್ಲಿ "<b>"ಶುಲ್ಕಗಳನ್ನು ವಿಧಿಸುವುದಕ್ಕೆ ಕಾರಣವಾಗಬಹುದು"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ಇದು ನಿಮ್ಮ ಮೊಬೈಲ್ ಖಾತೆಯಲ್ಲಿ ಶುಲ್ಕಗಳನ್ನು ವಿಧಿಸುವುದಕ್ಕೆ ಕಾರಣವಾಗುತ್ತದೆ."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ಕಳುಹಿಸು"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ರದ್ದುಮಾಡು"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ನನ್ನ ಆಯ್ಕೆಯನ್ನು ನೆನಪಿಡು"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB ಡೀಬಗ್‌ ಮಾಡುವಿಕೆಯನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲು ಸ್ಪರ್ಶಿಸಿ."</string>
     <string name="select_input_method" msgid="8547250819326693584">"ಕೀಬೋರ್ಡ್ ಬದಲಿಸಿ"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"ಕೀಬೋರ್ಡ್‌ಗಳನ್ನು ಆಯ್ಕೆಮಾಡಿ"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ಭೌತಿಕ ಕೀಬೋರ್ಡ್"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ಇನ್‌ಪುಟ್‌ ವಿಧಾನವನ್ನು ತೋರಿಸು"</string>
     <string name="hardware" msgid="7517821086888990278">"ಹಾರ್ಡ್‌ವೇರ್"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"ಕೀಬೋರ್ಡ್ ಲೇಔಟ್ ಆಯ್ಕೆಮಾಡಿ"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"ಕೀಬೋರ್ಡ್ ಲೇಔಟ್ ಆಯ್ಕೆ ಮಾಡಲು ಸ್ಪರ್ಶಿಸಿ"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"ವಿಶ್ವಾಸಾರ್ಹ ಏಜೆಂಟ್‌ ಸೇವೆಯನ್ನು ಪ್ರತಿಬಂಧಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"ನವೀಕರಣ ಮತ್ತು ಮರುಪ್ರಾಪ್ತಿ ಸಿಸ್ಟಂ ಜೊತೆಗೆ ಸಂವಹನ ನಡೆಸಿ"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"ಮರುಪ್ರಾಪ್ತಿ ಸಿಸ್ಟಂ ಮ್ತತು ಸಿಸ್ಟಂ ನವೀಕರಣಗಳೊಂದಿಗೆ ಸಂವಹನ ನಡೆಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಅವಕಾಶ ಮಾಡಿಕೊಡುತ್ತದೆ."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"ಮೀಡಿಯಾ ಪ್ರಕ್ಷೇಪಣ ಅವಧಿಗಳನ್ನು ರಚಿಸಿ"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಮಾಧ್ಯಮ ಪ್ರಕ್ಷೇಪಣ ಅವಧಿಗಳನ್ನು ರಚಿಸಲು ಅನುಮತಿಸುತ್ತದೆ. ಈ ಅವಧಿಗಳು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಪ್ರದರ್ಶನವನ್ನು ಮತ್ತು ಆಡಿಯೊ ವಿಷಯಗಳನ್ನು ಸೆರೆಹಿಡಿಯುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಒದಗಿಸುತ್ತವೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರುವುದಿಲ್ಲ."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"ಮೀಡಿಯಾ ಪ್ರಕ್ಷೇಪಣೆ ಅವಧಿಗಳನ್ನು ನಿರ್ವಹಿಸಿ"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಮಾಧ್ಯಮ ಪ್ರಕ್ಷೇಪಣೆ ಅವಧಿಗಳನ್ನು ನಿರ್ವಹಿಸಲು ಅನುಮತಿಸುತ್ತದೆ. ಈ ಅವಧಿಗಳು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಪ್ರದರ್ಶನವನ್ನು ಮತ್ತು ಆಡಿಯೊ ವಿಷಯಗಳನ್ನು ಸೆರೆಹಿಡಿಯುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಒದಗಿಸುತ್ತವೆ. ಸಾಮಾನ್ಯ ಅಪ್ಲಿಕೇಶನ್‌ಗಳಿಗೆ ಎಂದಿಗೂ ಅಗತ್ಯವಿರಬಾರದು."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ಸ್ಥಾಪನೆ ಸೆಷನ್‌ಗಳನ್ನು ಓದಿ"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ಸ್ಥಾಪಿತ ಸೆಷನ್‌ಗಳನ್ನು ಓದಲು ಅಪ್ಲಿಕೇಶನ್‌ ಅನ್ನು ಅನುಮತಿಸುತ್ತದೆ. ಸಕ್ರಿಯ ಪ್ಯಾಕೇಜ್‌ ಸ್ಥಾಪನೆಗಳ ಕುರಿತು ವಿವರಣೆಗಳನ್ನು ವೀಕ್ಷಿಸಲು ಇದು ಅನುಮತಿಸುತ್ತದೆ."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ಜೂಮ್‌ ನಿಯಂತ್ರಿಸಲು ಎರಡು ಬಾರಿ ಸ್ಪರ್ಶಿಸಿ"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"ನಿರಾಕರಿಸು"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"ಅನುಮತಿ ವಿನಂತಿಸಲಾಗಿದೆ"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> ಖಾತೆಗಾಗಿ\n ಅನುಮತಿಯನ್ನು ವಿನಂತಿಸಲಾಗಿದೆ."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"ನೀವು ಈ ಅಪ್ಲಿಕೇಶನ್‌ ಅನ್ನು ನಿಮ್ಮ ವೈಯಕ್ತಿಕ ಸ್ಥಳದಲ್ಲಿ ಬಳಸುತ್ತಿರುವಿರಿ"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"ನಿಮ್ಮ ಕಾರ್ಯ ಸ್ಥಳದಲ್ಲಿ ನೀವು ಈ ಅಪ್ಲಿಕೇಶನ್‌ ಅನ್ನು ಬಳಸುತ್ತಿರುವಿರಿ"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"ನಿಮ್ಮ ಕೆಲಸದ ಪ್ರೊಫೈಲ್‌ನ ಹೊರಗೆ ನೀವು ಈ ಅಪ್ಲಿಕೇಶನ್‌ ಅನ್ನು ಬಳಸುತ್ತಿರುವಿರಿ"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"ನಿಮ್ಮ ಕೆಲಸದ ಪ್ರೊಫೈಲ್‌ನಲ್ಲಿ ನೀವು ಈ ಅಪ್ಲಿಕೇಶನ್‌ ಅನ್ನು ಬಳಸುತ್ತಿರುವಿರಿ"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ಇನ್‌ಪುಟ್ ವಿಧಾನ"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ಸಿಂಕ್ ಮಾಡು"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ಪ್ರವೇಶಿಸುವಿಕೆ"</string>
@@ -1452,7 +1451,7 @@
     <string name="tethered_notification_message" msgid="6857031760103062982">"ಹೊಂದಿಸಲು ಸ್ಪರ್ಶಿಸಿ."</string>
     <string name="back_button_label" msgid="2300470004503343439">"ಹಿಂದೆ"</string>
     <string name="next_button_label" msgid="1080555104677992408">"ಮುಂದಿನದು"</string>
-    <string name="skip_button_label" msgid="1275362299471631819">"ಬಿಟ್ಟುಬಿಡು"</string>
+    <string name="skip_button_label" msgid="1275362299471631819">"ಸ್ಕಿಪ್‌ ಮಾಡು"</string>
     <string name="no_matches" msgid="8129421908915840737">"ಯಾವುದೇ ಹೊಂದಿಕೆಗಳಿಲ್ಲ"</string>
     <string name="find_on_page" msgid="1946799233822820384">"ಪುಟದಲ್ಲಿ ಹುಡುಕಿ"</string>
   <plurals name="matches_found">
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"ಗಂಟೆಯನ್ನು ಕಡಿಮೆ ಮಾಡಿ"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM ಹೊಂದಿಸು"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM ಹೊಂದಿಸಿ"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"ತಿಂಗಳನ್ನು ಹೆಚ್ಚಿಸಿ"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ತಿಂಗಳು ಕಡಿಮೆಮಾಡಿ"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"ದಿನವನ್ನು ಹೆಚ್ಚಿಸಿ"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ಸಂಪಾದಿಸು"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ಡೇಟಾ ಬಳಕೆಯ ಎಚ್ಚರಿಕೆ"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ಬಳಕೆ ಮತ್ತು ಸೆಟ್ಟಿಂಗ್‍ಗಳನ್ನು ವೀಕ್ಷಿಸಲು ಸ್ಪರ್ಶಿಸಿ."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"ಸೆಲ್ಯುಲಾರ್ ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ಮಿತಿ ತಲುಪಿದೆ"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G ಡೇಟಾ ಮೀತಿಯನ್ನು ತಲುಪಿದೆ"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G ಡೇಟಾ ಮೀತಿಯನ್ನು ತಲುಪಿದೆ"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"ಸೆಲ್ಯುಲಾರ್ ಡೇಟಾ ಮಿತಿಯನ್ನು ತಲುಪಿದೆ"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi ಡೇಟಾ ಮಿತಿಯನ್ನು ತಲುಪಿದೆ"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ಉಳಿದಿರುವ ಆವರ್ತನೆಗೆ ಡೇಟಾವನ್ನು ವಿರಾಮಗೊಳಿಸಲಾಗಿದೆ"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G ಡೇಟಾ ಮಿತಿ ಮೀರಿದೆ"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ಡೇಟಾ ಮಿತಿ ಮೀರಿದೆ"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"ಸೆಲ್ಯುಲಾರ್ ಡೇಟಾ ಮಿತಿ ಮೀರಿದೆ"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"ಕರೆ ಸ್ವೀಕರಿಸುವುದೇ?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ಯಾವಾಗಲೂ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"ಒಮ್ಮೆ ಮಾತ್ರ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ಕೆಲಸದ ಪ್ರೊಫೈಲ್ ಅನ್ನು ಬೆಂಬಲಿಸುವುದಿಲ್ಲ."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ಕೆಲಸದ ಪ್ರೊಫೈಲ್ ಅನ್ನು ಬೆಂಬಲಿಸುವುದಿಲ್ಲ"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ಟ್ಯಾಬ್ಲೆಟ್‌‌"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ಫೋನ್"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ಹೆಡ್‌ಫೋನ್‌ಗಳು"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ಪ್ರವೇಶಿಸುವಿಕೆ ಸಕ್ರಿಯಗೊಳಿಸಲಾಗಿದೆ."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ಪ್ರವೇಶಿಸುವಿಕೆಯನ್ನು ರದ್ದುಮಾಡಲಾಗಿದೆ."</string>
     <string name="user_switched" msgid="3768006783166984410">"ಪ್ರಸ್ತುತ ಬಳಕೆದಾರರು <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> ಗೆ ಬದಲಾಯಿಸಲಾಗುತ್ತಿದೆ…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ಮಾಲೀಕರು"</string>
     <string name="error_message_title" msgid="4510373083082500195">"ದೋಷ"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ಈ ಬದಲಾವಣೆಯನ್ನು ನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಅನುಮತಿಸುವುದಿಲ್ಲ"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ಆಯ್ಕೆ ಮಾಡಲಾಗಿದೆ"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ಅಳಿಸಲಾಗಿದೆ"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"ಕೆಲಸ <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ಈ ಪರದೆ ಅನ್‌ಪಿನ್‌ ಮಾಡಲು, ಹಿಂದೆ ಹಾಗೂ ಇತ್ತೀಚಿನವು ಬಟನ್‌ಗಳನ್ನು ಏಕಕಾಲದಲ್ಲಿ ಸ್ಪರ್ಶಿಸಿ ಹಾಗೂ ಒತ್ತಿ ಹಿಡಿಯಿರಿ."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ಈ ಪರದೆ ಅನ್‌ಪಿನ್‌ ಮಾಡಲು, ಇತ್ತೀಚಿನವು ಬಟನ್‌ ಸ್ಪರ್ಶಿಸಿ ಹಾಗೂ ಒತ್ತಿ ಹಿಡಿಯಿರಿ."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"ಪರದೆ ಪಿನ್‌ ಮಾಡಲಾಗಿದೆ. ಅನ್‌ಪಿನ್‌ ಮಾಡಲು ನಿಮ್ಮ ಸಂಸ್ಥೆ ಅವಕಾಶ ಮಾಡಿಕೊಟ್ಟಿಲ್ಲ."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"ಸ್ಕ್ರೀನ್‌ ಪಿನ್ನಿಂಗ್‌ ಬಳಸುವುದೇ?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"ಸ್ಕ್ರೀನ್‌ ಪಿನ್ನಿಂಗ್‌ ಏಕವೀಕ್ಷಣೆಯಲ್ಲಿಯೇ ಡಿಸ್‌ಪ್ಲೇ ಅನ್ನು ಲಾಕ್‌ ಮಾಡುತ್ತದೆ.\n\n ಹೊರಹೋಗಲು, ‘ಹಿಂದೆ’ ಹಾಗೂ ‘ಇತ್ತೀಚಿನವು’ ಬಟನ್‌ಗಳನ್ನು ಏಕಕಾಲದಲ್ಲಿ ಸ್ಪರ್ಶಿಸಿ, ಒತ್ತಿ ಹಿಡಿಯಿರಿ."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"ಸ್ಕ್ರೀನ್‌‌ ಪಿನ್ನಿಂಗ್‌ ಏಕವೀಕ್ಷಣೆಯಲ್ಲಿಯೇ ಡಿಸ್‌ಪ್ಲೇ ಅನ್ನು ಲಾಕ್‌ ಮಾಡುತ್ತದೆ.\n\nಹೊರಹೋಗಲು  ‘ಇತ್ತೀಚಿನವು’ ಅನ್ನು ಸ್ಪರ್ಶಿಸಿ ಹಾಗೂ ಒತ್ತಿ ಹಿಡಿಯಿರಿ."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ಬೇಡ, ಧನ್ಯವಾದಗಳು"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ಪ್ರಾರಂಭಿಸು"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ಅನ್‌ಲಾಕ್ ನಮೂನೆ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"ಪಾಸ್‌ವರ್ಡ್"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"ಸ್ಕ್ರೀನ್‌ ಪಿನ್‌ ಮಾಡಲಾಗಿದೆ"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"ಸ್ಕ್ರೀನ್‌ ಅನ್‌ಪಿನ್‌ ಮಾಡಲಾಗಿದೆ"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ಅನ್‌ಪಿನ್ ಮಾಡುವುದಕ್ಕೂ ಮೊದಲು PIN ಕೇಳಿ"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ಅನ್‌ಪಿನ್ ಮಾಡುವುದಕ್ಕೂ ಮೊದಲು ಅನ್‌ಲಾಕ್ ನಮೂನೆಯನ್ನು ಕೇಳಿ"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ಅನ್‌ಪಿನ್ ಮಾಡುವುದಕ್ಕೂ ಮೊದಲು ಪಾಸ್‌ವರ್ಡ್ ಕೇಳಿ"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ಬ್ಯಾಟರಿ ಬಾಳಿಕೆಯನ್ನು ಹೆಚ್ಚಿಸುವ ನಿಟ್ಟಿನಲ್ಲಿ ಸಹಾಯ ಮಾಡಲು, ಬ್ಯಾಟರಿ ಉಳಿತಾಯವು ನಿಮ್ಮ ಸಾಧನದ ಕಾರ್ಯಕ್ಷಮತೆಯನ್ನು ಕುಂಠಿತಗೊಳಿಸುತ್ತದೆ ಮತ್ತು ವೈಬ್ರೇಷನ್‌‌ ಹಾಗೂ ಹೆಚ್ಚಿನ ಹಿನ್ನೆಲೆ ಡೇಟಾವನ್ನು ಸೀಮಿತಗೊಳಿಸುತ್ತದೆ. ಇಮೇಲ್, ಸಂದೇಶ ಕಳುಹಿಸುವಿಕೆ, ಮತ್ತು ಸಿಂಕ್ ಮಾಡುವುದನ್ನು ಅವಲಂಬಿಸಿರುವ ಇತರ ಅಪ್ಲಿಕೇಶನ್‌ಗಳನ್ನು ನೀವು ತೆರೆಯುವವರೆಗೆ ಅವುಗಳನ್ನು ನವೀಕರಿಸಲಾಗುವುದಿಲ್ಲ.\n\nನಿಮ್ಮ ಸಾಧನವು ಚಾರ್ಜ್ ಆಗುತ್ತಿರುವಾಗ ಬ್ಯಾಟರಿ ಉಳಿತಾಯವು ಸ್ವಯಂಚಾಲಿತವಾಗಿ ಆಫ್ ಆಗುತ್ತದೆ."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"ನಿಮ್ಮ ಅಲಭ್ಯತೆ ಕೊನೆಗೊಳ್ಳುವವರೆಗೆ <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ಒಂದು ನಿಮಿಷದವರೆಗೆ"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d ನಿಮಿಷಗಳವರೆಗೆ"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ಒಂದು ಗಂಟೆಯವರೆಗೆ"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d ಗಂಟೆಗಳವರೆಗೆ"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"ಅನಿರ್ದಿಷ್ಟವಾಗಿ"</string>
 </resources>
diff --git a/core/res/res/values-ko/strings.xml b/core/res/res/values-ko/strings.xml
index 55ae682..ee5f39d 100644
--- a/core/res/res/values-ko/strings.xml
+++ b/core/res/res/values-ko/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"권한을 가진 프로그램이 원격 디스플레이에 대한 최상위 인터페이스를 사용하도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"위젯 서비스와 연결"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"권한을 가진 프로그램이 위젯 서비스에 대한 최상위 인터페이스를 사용하도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"경로 제공업체 서비스 사용"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"권한을 가진 프로그램이 등록된 경로 제공업체를 사용하도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"기기 관리자와 상호 작용"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"권한을 가진 프로그램이 기기 관리자에게 인텐트를 보낼 수 있도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV 입력 사용"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"휴대전화 전원 켜고 끄기"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"앱이 태블릿을 켜거나 끌 수 있도록 허용합니다."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"앱이 휴대전화를 켜거나 끌 수 있도록 허용합니다."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"화면 자동 잠금 시간 재설정"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"앱에서 화면 자동 잠금 시간을 재설정하도록 허용합니다."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"출고 테스트 모드로 실행"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"태블릿 하드웨어에 대한 완전한 액세스를 허용하는 하위 수준의 제조업체 테스트로 실행됩니다. 태블릿이 제조업체 테스트 모드로 실행 중일 때만 사용할 수 있습니다."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"휴대전화 하드웨어에 대한 완전한 액세스를 허용하는 하위 수준의 제조업체 테스트로 실행됩니다. 휴대전화가 제조업체 테스트 모드로 실행 중일 때만 사용할 수 있습니다."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"앱이 캐시 파일 시스템을 읽고 쓸 수 있도록 허용합니다."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP 통화 발신/수신"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"앱에서 SIP 통화를 발신 및 수신하도록 허용"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"통화 화면과 상호 작용"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"앱에서 사용자가 통화 화면을 보는 시기와 방법을 제어하도록 허용합니다."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"통화 화면과 상호작용"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"앱에서 사용자가 통화 화면을 보는 시기와 방법을 제어하도록 허용합니다."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"전화 서비스와 상호 작용"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"앱을 전화 서비스와 상호 작용하도록 허용하여 전화를 송수신하세요."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"통화 사용자 경험 제공"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"앱에서 통화 사용자 경험을 제공하도록 허용합니다."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"이전 네트워크 사용량 읽기"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"앱이 특정 네트워크 및 앱에 대한 이전 네트워크 사용량을 읽을 수 있도록 허용합니다."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"네트워크 정책 관리"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"권한을 가진 프로그램이 알림 수신기 서비스에 대한 최상위 인터페이스를 사용하도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"조건 제공자 서비스 사용"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"권한을 가진 프로그램이 조건 제공자 서비스의 최상위 인터페이스를 사용하도록 합니다. 일반 앱에는 필요하지 않습니다."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"미디어 경로 서비스 사용"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"권한을 가진 프로그램이 미디어 경로 서비스의 최상위 인터페이스를 사용하도록 합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"드림 서비스에 연결"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"권한을 가진 프로그램이 드림 서비스에 대한 최상위 인터페이스를 사용하도록 허용합니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"이동통신사에서 제공한 구성 앱 호출"</string>
@@ -923,7 +921,7 @@
     <string name="lockscreen_transport_stop_description" msgid="5907083260651210034">"중지"</string>
     <string name="lockscreen_transport_rew_description" msgid="6944412838651990410">"되감기"</string>
     <string name="lockscreen_transport_ffw_description" msgid="42987149870928985">"빨리 감기"</string>
-    <string name="emergency_calls_only" msgid="6733978304386365407">"긴급 통화만"</string>
+    <string name="emergency_calls_only" msgid="6733978304386365407">"긴급 통화만 허용"</string>
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"네트워크 잠김"</string>
     <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"SIM 카드가 PUK 잠김 상태입니다."</string>
     <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"사용자 가이드를 참조하거나 고객지원팀에 문의하세요."</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s와(과) 공유"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"홈 앱 선택"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"이 작업에 대해 기본값으로 사용"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"다른 앱 사용"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"시스템 설정 &gt; 앱 &gt; 다운로드로 이동하여 기본 설정을 지웁니다."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"작업 선택"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB 기기에 대한 앱 선택"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"허용"</string>
     <string name="sms_control_no" msgid="625438561395534982">"거부"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;(으)로 메시지를 보내시겠습니까?"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"모바일 계정에 "<font fgcolor="#ffffb060">"요금이 부과될 수 있습니다"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"모바일 계정에 요금이 부과됩니다."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"모바일 계정에 "<b>"요금이 부과될 수 있습니다"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"모바일 계정에 요금이 부과됩니다."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"전송"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"취소"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"내 선택사항 기억"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB 디버깅을 사용하지 않으려면 터치하세요."</string>
     <string name="select_input_method" msgid="8547250819326693584">"키보드 변경"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"키보드 선택"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"물리적 키보드"</string>
+    <string name="show_ime" msgid="9157568568695230830">"입력 방법 표시"</string>
     <string name="hardware" msgid="7517821086888990278">"하드웨어"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"키보드 레이아웃 선택"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"터치하여 키보드 레이아웃을 선택합니다."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"애플리케이션이 Trust Agent 서비스에 바인딩할 수 있도록 허용합니다."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"업데이트 및 복구 시스템과 상호작용"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"애플리케이션이 복구 시스템 및 시스템 업데이트와 상호작용할 수 있도록 허용합니다."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"미디어 프로젝션 세션 만들기"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"애플리케이션이 미디어 프로젝션 세션을 만드는 것을 허용합니다. 이 세션은 애플리케이션에 디스플레이 및 오디오 콘텐츠를 캡처하는 기능을 제공할 수 있습니다. 일반 앱에는 필요하지 않습니다."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"미디어 프로젝션 세션 관리"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"애플리케이션이 미디어 프로젝션 세션을 관리하도록 허용합니다. 이 세션은 애플리케이션에 디스플레이 및 오디오 콘텐츠를 캡처하는 기능을 제공할 수 있습니다. 일반 앱에는 필요하지 않습니다."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"설치 세션 읽기"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"애플리케이션의 설치 세션 읽기를 허용하면, 활성 패키지 설치에 대한 세부 정보를 볼 수 있습니다."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"확대/축소하려면 두 번 터치하세요."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"거부"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"권한 요청됨"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> 계정에 대해\n권한 요청"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"현재 개인 공간에서 이 앱을 사용 중입니다."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"현재 작업 공간에서 이 앱을 사용 중입니다."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"직장 프로필 외부에서 이 앱을 사용 중입니다."</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"직장 프로필에서 이 앱을 사용 중입니다."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"입력 방법"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"동기화"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"접근성"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"\'시간\'을 줄입니다."</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM 설정"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM 설정"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"오후"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"오전"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"\'월\'을 늘립니다."</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"\'월\'을 줄입니다."</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"\'일\'을 늘립니다."</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"수정"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"데이터 사용 경고"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"사용량 및 설정을 보려면 터치하세요."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G 데이터 사용 중지됨"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G 데이터 사용 중지됨"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"이동통신 데이터 사용 중지됨"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi 데이터 사용 중지됨"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"한도 도달"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G 데이터 한도에 도달함"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G 데이터 한도에 도달함"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"이동통신 데이터 한도에 도달함"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi 데이터 한도에 도달함"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"나머지 주기 동안 데이터 일시중지됨"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G - 3G 데이터 제한 초과됨"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4GB의 데이터 제한 초과됨"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"이동통신 데이터 한도 초과"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"통화를 수락하시겠습니까?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"항상"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"한 번만"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s에서 직장 프로필을 지원하지 않습니다."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s에서 직장 프로필을 지원하지 않습니다."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"태블릿"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"휴대전화"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"헤드폰"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"접근성을 사용 설정했습니다."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"접근성이 취소되었습니다."</string>
     <string name="user_switched" msgid="3768006783166984410">"현재 사용자는 <xliff:g id="NAME">%1$s</xliff:g>님입니다."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>님으로 전환하는 중…"</string>
     <string name="owner_name" msgid="2716755460376028154">"소유자"</string>
     <string name="error_message_title" msgid="4510373083082500195">"오류"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"관리자가 이 변경을 허용하지 않습니다."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g>이(가) 선택됨"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> 삭제됨"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"업무용 <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"이 화면을 고정 해제하려면 뒤로, 최근 버튼을 동시에 길게 누르세요."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"이 화면을 고정 해제하려면 최근을 길게 누르세요."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"화면이 고정되었습니다. 소속된 조직에서 고정 해제를 허용하지 않습니다."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"화면을 고정하시겠습니까?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"화면 고정을 사용하면 화면을 단일 보기로 잠급니다.\n\n종료하려면 뒤로, 최근 버튼을 동시에 길게 누릅니다."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"화면 고정을 사용하면 화면을 단일 보기로 잠급니다.\n\n종료하려면 최근을 길게 누릅니다."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"아니요"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"시작"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"잠금해제 패턴"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"비밀번호"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"화면 고정됨"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"화면 고정 해제됨"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"고정 해제 이전에 PIN 요청"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"고정 해제 이전에 잠금해제 패턴 요청"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"고정 해제 이전에 비밀번호 요청"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"배터리 수명을 개선하기 위해 배터리 세이버에서는 기기의 성능을 줄이고 진동과 대부분의 백그라운드 데이터를 제한합니다. 동기화가 필요한 이메일, 메시지, 기타 앱은 열어야 업데이트됩니다.\n\n기기를 충전하는 중에는 배터리 세이버가 자동으로 사용 중지됩니다."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>에 정지가 종료될 때까지"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1분 동안"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d분 동안"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1시간 동안"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d시간 동안"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"무제한"</string>
 </resources>
diff --git a/core/res/res/values-ky-rKG/strings.xml b/core/res/res/values-ky-rKG/strings.xml
index 2b66d13..22559ba 100644
--- a/core/res/res/values-ky-rKG/strings.xml
+++ b/core/res/res/values-ky-rKG/strings.xml
@@ -564,8 +564,6 @@
     <!-- no translation found for permlab_bindRemoteViews (5697987759897367099) -->
     <skip />
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Кармоочуга виджет кызматынын жогорку деңгээлдеги интерфейсине жалгашуу мүмкүнчүлүгүн берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"багыт берүүчү кызматка жалгаштыруу"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Кармоочуга катталган багыт берүүчүлөргө жалгашуу мүмкүнчүлүгүн берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
     <!-- no translation found for permlab_bindDeviceAdmin (8704986163711455010) -->
     <skip />
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Кармоочуга түзмөк администраторуна ниетин билдирүү мүмкүнчүлүгүн берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
@@ -805,6 +803,8 @@
     <skip />
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Колдонмого планшетти күйгүзүп же өчүрүү мүмкүнчүлүгүн берет."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Колдонмого телефонду күйгүзүп же өчүрүү мүмкүнчүлүгүн берет."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"дисплейдин күтүү убакытын кайра коюу"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Колдонмонун дисплейин күтүү убакытын кайра коюу мүмкүнчүлүгүн берет."</string>
     <!-- no translation found for permlab_factoryTest (3715225492696416187) -->
     <skip />
     <!-- no translation found for permdesc_factoryTest (3952059318359653091) -->
@@ -924,12 +924,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Колдонмого кэш файл тутумун окуу жана жазуу мүмкүнчүлүгүн берет."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP чалууларын жасоо/кабыл алуу"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Колдонмонун SIP чалууларын жасап жана кабыл алуусуна жол ачат."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"чалуу экраны менен байланыштыруу"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Колдонмого чалуу экранын колдонуучу качан жана кандай көрөөрүн башкаруу мүмкүнчүлүгүн берет."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"чалуу экраны менен байланыштыруу"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Колдонмого чалуу экраны качан жана кандай көрүнө тургандыгын башкаруу мүмкүнчүлүгүн берет."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"телефония кызматтары"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Колдонмого чалууларды жасоо/кабыл алуу үчүн телефония кызматтары менен байланышууга уруксат берет."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"чалуу ичиндеги колдонуучу тажрыйбасын камсыз кылуу"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Колдонмого чалуу учурундагы колдонуучу тажрыйбасын камсыз кылуу мүмкүнчүлүгүн берет."</string>
     <!-- no translation found for permlab_readNetworkUsageHistory (7862593283611493232) -->
     <skip />
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Колдонмого белгилүү бир тармактарга жана колдонмолорго байланыштуу тармактын колдонулушу жөнүндө таржымалды окуу мүмкүнчүлүгүн берет."</string>
@@ -945,8 +945,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Ээсине эскертүү тыңшагыч кызматтын жогорку деңгээл интерфейсине туташуу мүмкүнчүлүгүн берет. Жөнөкөй колдонмолордо эч качан керектелбейт."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"шарт түзүүчү кызматына жалгаштыруу"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Кармоочуга шарт түзүүчү кызматтын жогорку деңгээлдеги интерфейсине жалгашуу мүмкүнчүлүгүн берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"медиа жол кызматына жалгаштыруу"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Кармоочуга медиа жол кызматынын жогорку деңгээл интерфейсин жалгаштырууга мүмкүндүк берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"dream кызматына жалгаштыруу"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Кармоочуга dream кызматынын жогорку деңгээлдеги интерфейсине жалгашуу мүмкүнчүлүгүн берет. Кадимки колдонмолорго эч качан талап кылынбайт."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"оператордун конфигурациялык колдонмосун чакыруу"</string>
@@ -1559,6 +1557,7 @@
     <string name="whichHomeApplication" msgid="4616420172727326782">"Үй колдонмосун тандаңыз"</string>
     <!-- no translation found for alwaysUse (4583018368000610438) -->
     <skip />
+    <string name="use_a_different_app" msgid="8134926230585710243">"Башка колдонмону пайдалануу"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Тутум жөндөөлөрүндөгү демейкини тазалоо &gt; Колдонмолор &gt; Жүктөлүп алынды."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Аракет тандаңыз"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB түзмөгү үчүн колдонмо тандаңыз"</string>
@@ -1670,8 +1669,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Ооба"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Жок"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; номуруна билдирүү жөнөткөнү жатат."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Бул мобилдик эсебиңизден "<font fgcolor="#ffffb060">"каражаттардын сарпталуусуна"</font>" алып келет."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Бул мобилдик эсебиңизден каражаттын сарпталуусуна алып келет."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Бул уюлдук эсебиңиздеги төлөмдөргө "<b>"алып келиши мүмкүн"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Бул уюлдук эсебиңиздеги төлөмдөргө алып келет."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Жөнөтүү"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Айнуу"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Менин тандоомду эстеп кал"</string>
@@ -1747,7 +1746,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB мүчүлүштүктөрдү жоюу мүмкүнчүлүгүн өчүрүү үчүн тийип коюңуз."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Баскычтопту өзгөртүү"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Баскычтопторду тандаңыз"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Аппараттык тергич"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Киргизүү ыкмасын көрсөтүү"</string>
     <string name="hardware" msgid="7517821086888990278">"Аппараттык"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Тергичтин жайгашуусун тандоо"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Тергичтин жайгашуусун тандаш үчүн басыңыз."</string>
@@ -1821,8 +1820,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Колдонмого ишенимдүү агент кызматына жалгашууга мүмкүнчүлүк берет."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Калыбына келтирүү системасы жана жаңыртуулар менен иштөө"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Колдонмого калыбына келтирүү системасы жана система жаңыртуулары менен карым-катнашуу мүмкүнчүлүгүн берет."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Медиа чагылдыруу сеанстарын түзүү"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Колдонмого медиа чагылдыруу сеанстарын түзүү мүмкүнчүлүгүн берет. Мындай сеанстардын жардамы менен, колдонмолор дисплей жана видео мазмунду сүрөткө тартып турушат. Кадимки колдонмолор үчүн талап кылынбайт."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Медиа чагылтуу сеанстарын башкаруу"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Колдонмого медиа чагылдыруу сеанстарын башкаруу мүмкүнчүлүгүн берет. Мындай сеанстардын жардамы менен, колдонмолор дисплей жана видео мазмунду сүрөткө тартып турушат. Кадимки колдонмолор үчүн талап кылынбайт."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Орнотуу сеанстарын окуу"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Колдонмого орнотуу сеанстарын окуу мүмкүнчүлүгүн берет. Ушуну менен, ал жигердүү топтом орнотууларынын чоо-жайын көрө алат."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Чен өлчөмүн көзөмөлдөө үчүн эки жолу тийип коюңуз"</string>
@@ -1855,8 +1854,8 @@
     <skip />
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Уруксат талап кылуу"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Кийинки эсепке\nуруксат талап кылынууда: <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Бул колдонмону жеке мейкиндигиңизде пайдаланып жатасыз"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Бул колдонмону жумуш мейкиндигиңизде пайдаланып жатасыз"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Бул колдонмо жумуш профилиңиздин сыртында колдонулуп жатат"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Бул колдонмону жумуш профилиңизде пайдаланып жатасыз"</string>
     <!-- no translation found for input_method_binding_label (1283557179944992649) -->
     <skip />
     <!-- no translation found for sync_binding_label (3687969138375092423) -->
@@ -1963,8 +1962,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Саатты төмөндөтүү"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"т.к. орнотуу"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"т.ч. орнотуу"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"т.к."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"т.ч."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Айды жогорулатуу"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Айды азайтуу"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Күндү жогорулатуу"</string>
@@ -2002,11 +1999,11 @@
     <!-- no translation found for data_usage_warning_title (1955638862122232342) -->
     <skip />
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Колдонууну көрүш үчүн басыңыз."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2Гб-3Гб көлмдөгү дайындр өчүрлдү."</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4Гб көлөмдөгү дайындар өчүрүлдү"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Уюктук дайындар тармагы өчүк"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi дайындар тармагы өчүк"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Белгиленген чекке жеттиңиз"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G дайындар чегине жетти"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G дайындар чегине жетти"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Уюктук дайындар чегине жетти"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi дайындар чегине жетти"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Калган мерчимде дайындар бир азга токтотулду"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G трафик чектен ашты"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G трафик чектен ашты"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Уюкт дайндр белглнгн чегнн аштңз"</string>
@@ -2051,7 +2048,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Чалуу кабыл алынсынбы?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Дайыма"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Бир жолу гана"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s жумуш профилин колдоого албайт."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s жумуш профилин колдоого албайт"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Планшет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Кулакчын"</string>
@@ -2124,6 +2121,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Жеткиликтүүлүк иштетилди."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Атайын мүмкүнчүлүктөр иштетилген жок."</string>
     <string name="user_switched" msgid="3768006783166984410">"Учурдагы колдонуучу <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> дегенге которулууда…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Ээси"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Ката"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Мындай өзгөртүүгө администраторуңуз тарабынан тыюу салынган."</string>
@@ -2245,31 +2243,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> тандалды"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> өчүрүлдү"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Жумуш <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Бул экранды бошотуу үчүн, бир эле маалда Артка жана Акыркылар баскычтарына тийип, кармап туруңуз."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Бул экранды бошотуу үчүн, Акыркылар баскычына тийип, кармап туруңуз."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Экран кадалды. Уюмуңуздун уруксатысыз бошото албайсыз."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Экран кадалсынбы?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Экран кадалганда дисплей жалгыз көрүнүштө чагылдырылат.\n\nЧыгуу үчүн, бир эле маалда Артка жана Акыркылар деген баскычтарды коё бербей басып туруңуз."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Экран кадалганда дисплей жалгыз көрүнүштө кулпулайт.\n\nЧыгуу үчүн Акыркылар көрүнүшүн коё бербей басып туруңуз."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ЖОК, РАХМАТ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"БАШТОО"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"бөгөттөн чыгаруу үлгүсү"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"сырсөз"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Экран кадалды"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Экран бошотулду"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Бошотуудан мурун PIN суралсын"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Бошотуудан мурун кулпуну ачкан үлгү суралсын"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Бошотуудан мурун сырсөз суралсын"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Батарея өмүрүн узартууга жардамдашуу үчүн, батарея үнөмдөгүч түзмөгүңүздүн өндүрүмдүүлүгүн азайтып, дирилдөөнү жана көпчүлүк фон дайындарын чектейт. Email, билдирүү жазуу жана башка шайкештирүүгө көз каранды колдонмолор, аларды ачмайыңызча жаңыртылбашы мүмкүн.\n\nТүзмөгүңүз кубатталып жатканда батарея үнөмдөгүч автоматтык түрдө өчөт."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Иштебей турган абал <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> аяктамайынча"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Бир мүнөткө"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d мүнөткө"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Бир саатка"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d саатка"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Белгисиз"</string>
 </resources>
diff --git a/core/res/res/values-land/dimens_material.xml b/core/res/res/values-land/dimens_material.xml
index c8c95d7b..77719a6 100644
--- a/core/res/res/values-land/dimens_material.xml
+++ b/core/res/res/values-land/dimens_material.xml
@@ -19,5 +19,9 @@
     <dimen name="action_bar_default_height_material">48dp</dimen>
     <!-- Default padding of an action bar. -->
     <dimen name="action_bar_default_padding_material">0dp</dimen>
+    <!-- Default text size for action bar title.-->
+    <dimen name="text_size_title_material_toolbar">14dp</dimen>
+    <!-- Default text size for action bar subtitle.-->
+    <dimen name="text_size_subtitle_material_toolbar">12dp</dimen>
 
 </resources>
diff --git a/core/res/res/values-lo-rLA/strings.xml b/core/res/res/values-lo-rLA/strings.xml
index 7372528..a40c056 100644
--- a/core/res/res/values-lo-rLA/strings.xml
+++ b/core/res/res/values-lo-rLA/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ອະນຸຍາດໃຫ້ຜູ່ຖືຜູກກັບສ່ວນຕິດຕໍ່ລະດັບສູງສຸດ ຂອງການສະແດງຜົນທາງໄກ. ບໍ່ຈຳເປັນສຳລັບແອັບຯທົ່ວໄປ."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ເຊື່ອມໂຍງໄປຫາບໍລິການວິດເຈັດ"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ອະນຸຍາດໃຫ້ຜູ່ຖືຜູກກັບອິນເຕີເຟດລະດັບສູງສຸດ ຂອງບໍລິການວິເຈັດ. ບໍ່ຈຳເປັນສຳລັບແອັບຯທົ່ວໄປ."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"ເຊື່ອມ​ໂຍງ​ກັບ​ການ​ບໍ​ລິ​ການ​ຂອງ​ຜູ່​ໃຫ້​ບໍ​ລິ​ການ​ເສັ້ນ​ທາງ"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ອະ​ນຸ​ຍາດ​ໃຫ້​ເຈົ້າ​ຂອງ​ສາ​ມາດ​ເຊື່ອມ​ໂຍງກັບ​ທຸກໆ​ຜູ່​ໃຫ້​ບໍ​ລິ​ການເສັ້ນ​ທາງ​ທີ່​ລົງ​ທະ​ບຽນ. ບໍ່​ຄວນ​ຈະ​ໄດ້​ໃຊ້​ໃນ​ແອັບຯ​ທົ່ວ​ໄປ."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ຕິດຕໍ່ກັບຜູ່ເບິ່ງແຍງອຸປະກອນ"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ອະນຸຍາດໃຫ້ເຈົ້າຂອງສົ່ງເຈດຕະນາຫາຜູ່ເບິ່ງແຍງລະບົບອຸປະກອນ. ແອັບຯທົ່ວໄປບໍ່ຄວນຈຳເປັນຕ້ອງໃຊ້."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ຜູກ​ກັບ​ການ​ປ້ອນ​ຂໍ້​ມູນ​ເຂົ້າ​ໂທ​ລະ​ທັດ"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ເປີດ ຫຼືປິດໂທລະສັບ"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ອະນຸຍາດໃຫ້ແອັບຯເປີດ ຫຼືປິດແທັບເລັດ."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ອະນຸຍາດໃຫ້ແອັບພລິເຄຊັນປິດ ຫຼືເປີດແທັບເລັດໄດ້."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ຣີ​ເຊັດ​ໄລ​​ຍະ​ເວ​ລາ​ກ່ອນ​ປິດ​ໜ້າ​ຈໍ."</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບຯ​ຣີ​ເຊັດ​ໄລ​​ຍະ​ເວ​ລາ​ກ່ອນ​ປິດ​ໜ້າ​ຈໍ."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ເຮັດວຽກໃນໂໝດການທົດສອບຂອງໂຮງງານ"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ເຮັດວຽກໃນຮູບແບບທົດສອບໃນລະດັບຕໍ່າຂອງຜູ່ຜະລິດ, ອະນຸຍາດການເຂົ້າເຖິງແບບເຕັມຮູບແບບຫາຮາດແວຂອງແທັບເລັດ. ໃຊ້ໄດ້ສະເພາະໃນເວລາທີ່ແທັບເລັດກຳລັງຢູ່ໃນໂໝດ ການທົດສອບຂອງຜູ່ຜະລິດgmqjkoaho."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ເປີດໃຊ້ໃນແບບການທົດສອບຂອງຜູ່ລະລິດໃນລະດັບຕໍ່າ, ອະນຸຍາດການເຂົ້າເຖິງຮາດແວຂອງໂທລະສັບແບບສົມບູນ. ສະເພາະເມື່ອໂທລະສັບຖືກເປີດໃຊ້ ໃນໂໝດການທົດສອບຂອງຜູ່ຜະລິດເທົ່ານັ້ນ."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ອະນຸຍາດໃຫ້ແອັບຯ ອ່ານ ແລະຂຽນ ລະບົບໄຟລ໌ແຄດ."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"ຮັບສາຍ/ໂທອອກ ຜ່ານ SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"ອະນຸຍາດ​ໃຫ້ແອັບຯ​ສາມາດ​ຮັບສາຍ ແລະໂທອອກ​ຜ່ານ SIP ໄດ້"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ໂຕ້ຕອບກັບໜ້າຈໍການໂທ"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ອະນຸຍາດໃຫ້ແອັບຯ ຄວບຄຸມເວລາ ແລະວິທີການທີ່ຜູ່ໃຊ້ເຫັນໜ້າຈໍການໂທໄດ້."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ໂຕ້​ຕອບ​ກັບ​ໜ້າ​ຈໍ​ການ​ໂທ"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ອະນຸຍາດ​ໃຫ້​ແອັບຯ​ຄວບຄຸມ​ເວລາ ແລະ​ວິທີ​ການ​ທີ່​ຜູ່ໃຊ້​ເຫັນ​ໜ້າ​ຈໍ​ການ​ໂທ​ໄດ້."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ສັ່ງ​ບໍ​ລິ​ການ​ໂທ​ລະ​ສັບ"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບຯ​ສັ່ງ​​ບໍ​ລິ​ການ​ໂທ​ລະ​ສັບ​ເພື່ອ​ໂທຫຼື​ຮັບ​ສາຍ​ໄດ້."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ສະ​ໜອງ​ປະ​ສົບ​ການ​ຜູ່​ໃຊ້​ໃນ​ການ​ໂທ​ລະ​ສັບ"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບຯ​ສະ​ໜອງ​ປະ​ສົບ​ການ​ຜູ່​ໃຊ້​ໃນ​ການ​ໂທ​ລະ​ສັບ."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ອ່ານປະຫວັດການນຳໃຊ້ເຄືອຂ່າຍ"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"ອະນຸຍາດໃຫ້ແອັບຯ ອ່ານປະຫວັດການນຳໃຊ້ເຄືອຂ່າຍຂອງແອັບຯ ແລະເຄືອຂ່າຍໃດນຶ່ງ."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ຈັດການນະໂຍບາຍເຄືອຂ່າຍ"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ອະນຸຍາດໃຫ້ເຈົ້າຂອງເຊື່ອມໂຍງສ່ວນຕິດຕໍ່ລະດັບເທິງສຸດ ຂອງຜູ່ຟັງບໍລິການການແຈ້ງເຕືອນ. ບໍ່ຈຳເປັນສຳລັບແອັບຯທົ່ວໄປ."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"ເຊື່ອມ​ໂຍງ​ກັບ​ບໍ​ລິ​ການ​ຜູ່​ສະ​ໜອງ​ເງື່ອນ​ໄຂ"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"ອະນຸຍາດ​ໃຫ້​ເຈົ້າຂອງ​ເຊື່ອມໂຍງ​ສ່ວນຕິດຕໍ່​ລະດັບ​ສູງສຸດ​ຂອງ​ບໍ​ລິ​ການ​ສະ​ໜອງ​ເງື່ອນ​ໄຂ. ບໍ່ຈຳເປັນ​ສຳລັບ​ແອັບຯທົ່ວໄປ."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"​ເຊື່ອມ​ໂຍງ​ກັບ​ບໍ​ລິ​ການ​ເສັ້ນ​ທາງ​ມີ​ເດຍ"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ຜູ່​ໃຊ້​ເຊື່ອມ​ໂຍງ​ກັບ​ສ່ວນ​ຕິດ​ຕໍ່​ຜູ່​ໃຊ້​ລະ​ດັບ​ສູງ​ສຸດ​ຂອງ​ບໍ​ລິ​ການ​ເສັ້ນ​ທາງ​ມີ​ເດຍ. ແອັບຯ​ທົ່ວ​ໄປ​ບໍ່​ຄວນ​ຕ້ອງໃຊ້."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ຜູກ​ກັບ​ບໍ​ລິ​ການ dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ອະນຸຍາດ​ໃຫ້ຜູ່ຖື​ຜູກກັບ​ສ່ວນຕິດຕໍ່​ລະດັບ​ສູງສຸດ ຂອງ​ບໍລິການ dream. ບໍ່ຈຳເປັນ​ສຳລັບ​ແອັບຯ​ທົ່ວໄປ."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"ຮ້ອງຂໍແອັບຯປັບຄ່າທີ່ສະໜອງໂດຍຜູ່ໃຫ້ບໍລິການ"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"ແບ່ງ​ປັນ​ກັບ %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ເລືອກແອັບຯ Home"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ໃຊ້ໂດຍຄ່າເລີ່ມຕົນສຳລັບການເຮັດວຽກນີ້."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"ນຳໃຊ້ແອັບຯອື່ນ"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"ລຶບລ້າງຄ່າເລີ່ມຕົ້ນ ໃນ ການຕັ້ງຄ່າລະບົບ &gt; ແອັບຯ &gt; ດາວໂຫລດແລ້ວ."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ເລືອກການເຮັດວຽກ"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"ເລືອກແອັບຯສໍາລັບອຸປະກອນ USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"ອະນຸຍາດ"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ປະຕິເສດ"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ຕ້ອງການສົ່ງຂໍ້ຄວາມຫາ &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ນີ້ "<font fgcolor="#ffffb060">"ອາດເຮັດໃຫ້ເກີດຄ່າໃຊ້ຈ່າຍ"</font>" ໃນບັນຊີມືຖືຂອງທ່ານໄດ້."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"ມັນຈະເຮັດໃຫ້ທ່ານເສຍຄ່າບໍລິການໃນບັນຊີຂອງທ່ານ."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"ນີ້ "<b>"ອາດ​ເຮັດ​ໃຫ້​ເກີດ​ມີການ​ຮຽກ​ເກັບ​ຄ່າ​ໃຊ້​ຈ່າຍ"</b>" ໃນ​ບັນ​ຊີ​ມື​ຖື​ຂອງ​ທ່ານ."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ນີ້​ອາດ​​ເຮັດ​ໃຫ້​ເກີດ​ມີ​ການ​ຮຽກ​ເກັບ​ຄ່າ​ໃຊ້​ຈ່າຍ​ໃນ​ບັນ​ຊີ​ມື​ຖື​ຂອງ​ທ່ານ."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ສົ່ງ"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ຍົກເລີກ"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ຈື່ການເລືອກຂອງຂ້ອຍ"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"ແຕະເພື່ອປິດການດີບັ໊ກຜ່ານ USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"​ປ່ຽນ​ແປ້ນ​ພິມ"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"​ເລືອກ​ແປ້ນ​ພິມ"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ແປ້ນພິມແທ້"</string>
+    <string name="show_ime" msgid="9157568568695230830">"​ສະ​ແດງ​ຮູບ​ແບບ​ການ​ປ້ອນ​ຂໍ້​ມູນ"</string>
     <string name="hardware" msgid="7517821086888990278">"ຮາດແວ"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"ເລືອກຮູບແບບແປ້ນພິມ"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"ກົດເພື່ອເລືອກຮູບແບບແປ້ນພິມ."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບ​ພ​ລິ​ເຄ​ຊັນເຊື່ອມ​ໂຍງ​ກັບ​ບໍ​ລິ​ການ​ຕົວ​ແທນ​ທີ່​ເຊື່ອ​ຖື​ໄດ້."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"ຕິດຕໍ່ກັບລະບົບອັບເດດ ແລະລະບົບກູ້ຂໍ້ມູນ."</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"ອະນຸຍາດໃຫ້ແອັບພລິເຄຊັນຕິດຕໍ່ກັບລະບົບກູ້ຂໍ້ມູນ ແລະການອັບເດດລະບົບ."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"ສ້າງ​ມີ​ເດຍ​ໂປ​ຣ​ເຈັກ​ຊັນ​ເຊດ​ຊັນ"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບ​ພ​ລິ​ເຄ​ຊັນ​ສ້າງ​​ມີ​ເດຍ​ໂປ​ຣ​ເຈັກ​ຊັນ​ເຊດ​ຊັນ. ເຊດ​ຊັນ​ເຫຼົ່າ​ນີ້​ສາ​ມາດ​ສະ​ໜອງ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຈັບ​ພາບ ແລະ​​ສຽງ​​ໄດ້. ແອັບຯ​ທົ່ວ​ໄປ​ບໍ່​ຄວນ​ໃຊ້."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"ຈັດ​ການ​ເຊດ​ຊັນ​ຂອງມີ​ເດຍ​ໂປ​ຣ​ເຈັກ​​ຊັນ"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບ​ພລິ​ເຄ​ຊັນ​ຈັດ​ການ​ເຊດ​ຊັນ​ຂອງມີ​ເດຍ​ໂປ​ຣ​ເຈັກ​​ຊັນ. ເຊດ​ຊັນ​ນີ້​ຈະ​ເຮັດ​ໃຫ້​ແອັບ​ພລິ​ເຄ​ຊັນ​​ຕ່າງໆ​ສາ​ມາດ​ບັນ​ທຶກ​ເນື້ອ​ຫາ​ພາບ​ແລະ​ສຽງ​ໄດ້. ແອັບຯ​ທົ່ວ​ໄປ​ບໍ່​ຄວນ​ຕ້ອງ​ໃຊ້."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ອ່ານ​ເຊດ​ຊັນ​ການ​ຕິດ​ຕັ້ງ"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"​ອະ​ນຸ​ຍາດ​ໃຫ້​ແອັບ​ພລິ​ເຄ​ຊັນ​ອ່ານ​ເຊດ​ຊັນ​ການ​ຕິດ​ຕັ້ງ​ໄດ້. ນີ້​ຈະ​ອະ​ນຸ​ຍາດ​ໃຫ້​ມັນ​ເບິ່ງ​ເຫັນ​ລາຍ​ລະ​ອຽດ​ກ່ຽວ​ກັບ​ການ​ຕິດ​ຕັ້ງ​ແພັກ​ເກດ​ທີ່​ເຮັດ​​ວຽກ​ຢູ່​ໄດ້."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ແຕະສອງເທື່ອສຳລັບການຄວບຄຸມການຊູມ"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"ປະ​ຕິ​ເສດ"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"ຕ້ອງການການອະນຸຍາດ"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"ຮ້ອງຂໍການກຳນົດສິດ\nສຳລັບບັນຊີ <xliff:g id="ACCOUNT">%s</xliff:g> ແລ້ວ."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"​ທ່ານ​ກຳ​ລັງ​ໃຊ້​ແອັບຯ​ນີ້​ໃນ​ພື້ນ​ທີ່​ສ່ວນ​ໂຕ​ຂອງ​ທ່ານ"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"​ທ່ານ​ກຳ​ລັງ​ໃຊ້​ແອັບຯ​ນີ້​ໃນ​ພື້ນ​ທີ່​ບ່ອນ​ເຮັດ​ວຽກ​ຂອງ​ທ່ານ"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"​ທ່ານ​ກຳ​ລັງ​ໃຊ້​ແອັບຯ​ນີ້ນອກ​ໂປຣ​ໄຟລ໌​ບ່ອນ​ເຮັດ​ວຽກ​ຂອງ​ທ່ານ"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"​ທ່ານ​ກຳ​ລັງ​ໃຊ້​ແອັບຯ​ນີ້​ໃນ​ໂປຣ​ໄຟລ໌​​ບ່ອນ​ເຮັດ​ວຽກ​ຂອງ​ທ່ານ"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ວິທີການປ້ອນຂໍ້ມູນ"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ຊິ້ງຂໍ້ມູນ"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ການຊ່ວຍເຂົ້າເຖິງ"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"ຫຼຸດຊົ່ວໂມງ"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"ຕັ້ງ PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"ຕັ້ງ AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ຫຼັງທ່ຽງ"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"​ກ່ອນ​ທ່ຽງ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"ເພີ່ມຈຳນວນເດືອນ"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ຫຼຸດເດືອນ"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"ເພີ່ມຈຳນວນມື້"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ແກ້ໄຂ"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ເຕືອນກ່ຽວກັບການນຳໃຊ້ຂໍ້ມູນ"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ແຕະເພື່ອເບິ່ງການນຳໃຊ້ ແລະການຕັ້ງຄ່າ."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"ຂໍ້​ມູນ 2G-3G ​ແມ່ນ​ປິດ"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"ຂໍ້​ມູນ 4G ແມ່ນ​ປິດ"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"​ຂໍ້​ມູນ​ມື​ຖື​ຖືກ​ປິດ​ໄວ້"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"ຂໍ້​ມູນ Wi-Fi ຖືກ​ປິດ​ໄວ້"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ຮອດຂີດຈຳກັດແລ້ວ"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"ໃຊ້​ຂໍ້​ມູນ 2G-3G ຮອດ​ຈຳ​ນວນ​ທີ່​ຈຳ​ກັດ​ແລ້ວ"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"ໃຊ້​ຂໍ້​ມູນ 4G ຮອດ​ຈຳ​ນວນ​ທີ່​ຈຳ​ກັດ​ແລ້ວ"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"ໃຊ້​ຂໍ້​ມູນ​ອິນ​ເຕີ​ເນັດ​ມື​ຖື​ຮອດ​ຈຳ​ນວນ​ທີ່​ຈຳ​ກັດ​ແລ້ວ"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"ໃຊ້​ຂໍ້​ມູນ​ອິນ​ເຕີ​ເນັດ​ Wi-Fi ​ຮອດ​ຈຳ​ນວນ​ທີ່​ຈຳ​ກັດ​ແລ້ວ"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ຂໍ້​ມູນ​ຖືກ​ຢຸດ​ຊົ່ວ​ຄາວ​ສຳ​ລັບ​ໄລ​ຍະ​ເວ​ລາ​ທີ່​ເຫຼືອ"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"ຂໍ້ມູນ 2G-3G ຮອດຂີດຈຳກັດແລ້ວ"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"ໝົດກຳນົດການນຳໃຊ້ຂໍ້ມູນ 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"​ຂໍ້​ມູນ​ມື​ຖື​ຂອງ​ຂີດ​ຈຳ​ກັດ​ທີ່​ກຳ​ນົດ​ໄວ້​ແລ້ວ"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"ຮັບການໂທບໍ່?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ທຸກຄັ້ງ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"ຄັ້ງດຽວ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ບໍ່​ຮອງ​ຮັບ​ໂປຣ​ໄຟລ໌​ບ່ອນ​ເຮັດ​ວຽກ."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ບໍ່​ຮອງ​ຮັບ​ໂປຣ​ໄຟລ໌​ບ່ອນ​ເຮັດ​ວຽກ​ຂອງ​ທ່ານ"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ແທັບເລັດ"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ໂທລະສັບ"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ຫູຟັງ"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ເປີດການຊ່ວຍເຂົ້າເຖິງແລ້ວ."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ຍົກເລີກໂຕຊ່ວຍການເຂົ້າເຖິງແລ້ວ."</string>
     <string name="user_switched" msgid="3768006783166984410">"ຜູ່ໃຊ້ປັດຈຸບັນ <xliff:g id="NAME">%1$s</xliff:g> ."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"ກຳ​ລັງ​ສະ​ລັບ​​ໄປ​ຫາ <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ເຈົ້າຂອງ"</string>
     <string name="error_message_title" msgid="4510373083082500195">"ຜິດພາດ"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານບໍ່​ອະ​ນຸ​ຍາດ​ໃຫ້​ປ່ຽນ​ແປງ​ສິ່ງ​ນີ້"</string>
@@ -1743,7 +1741,7 @@
     <string name="restr_pin_enter_old_pin" msgid="1462206225512910757">"PIN ປະ​ຈຸ​ບັນ"</string>
     <string name="restr_pin_enter_new_pin" msgid="5959606691619959184">"ລະຫັດ PIN ໃໝ່"</string>
     <string name="restr_pin_confirm_pin" msgid="8501523829633146239">"ຢືນຢັນລະຫັດ PIN ໃໝ່"</string>
-    <string name="restr_pin_create_pin" msgid="8017600000263450337">"ສ້າງ PIN ສໍາ​ລັບ​ການ​ປັບ​ປຸງ​ຂໍ້ຈໍາ​ກັດ"</string>
+    <string name="restr_pin_create_pin" msgid="8017600000263450337">"ສ້າງ PIN ສໍາ​ລັບ​ການ​ປັບ​ປຸງ​ຂໍ້ຈໍາ​ກັດ​"</string>
     <string name="restr_pin_error_doesnt_match" msgid="2224214190906994548">"PIN ບໍ່​ກົງກັນ. ລອງໃໝ່ອີກຄັ້ງ​."</string>
     <string name="restr_pin_error_too_short" msgid="8173982756265777792">"PIN ​ສັ້ນ​ເກີນ​ໄປ​. ຕ້ອງມີຢ່າງໜ້ອຍ 4 ຫຼັກ​."</string>
   <plurals name="restr_pin_countdown">
@@ -1764,30 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ຖືກເລືອກແລ້ວ"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ຖືກລຶບແລ້ວ"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"​ບ່ອນ​ເຮັດ​ວຽກ <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ເພື່ອ​ຍົກ​ເລີກ​ການ​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ນີ້, ໃຫ້​ແຕະ​ປຸ່ມ​ກັບ​ຄືນ​​ແລະ​ປຸ່ມ​ແອັບຯ​​ທີ່​ຫາ​ກໍ​ໃຊ້​ຄ້າງໄວ້​ພ້ອມ​ກັນ."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ເພື່ອ​ຍົກ​ເລີກ​ການ​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ນີ້, ໃຫ້​ແຕະ​ປຸ່ມ​ແອັບຯ​ທີ່​ຫາ​ກໍ​ໃຊ້​ຄ້າງ​ໄວ້."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"ໜ້າ​ຈໍ​ຖືກ​ປັກ​ໝຸດ​ໄວ້. ​ອົງ​ກອນ​ຂອງ​ທ່ານບໍ່​​ອະ​ນຸ​ຍາດ​ໃຫ້​ຍົກ​ເລີກ​ການ​ປັກ​ໝຸດ​ໄດ້."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"ໃຊ້​ການ​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ບໍ່?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"ການ​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ຈະ​ລັອກ​ໜ້າ​ຈໍ​ໄວ້​ທີ່​ມຸມມອງ​ໃດ​ນຶ່ງ.\n\nເພື່ອ​ອອກ, ໃຫ້​ແຕະ​ປຸ່ມ​ກັບ​ຄືນ​​ແລະ​ປຸ່ມ​ແອັບຯ​​ທີ່​ຫາ​ກໍ​ໃຊ້​ຄ້າງໄວ້​ພ້ອມ​ກັນ."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"ການ​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ຈະ​ລັອກ​ໜ້າ​ຈໍ​ໄວ້​ທີ່​ມຸມມອງ​ໃດ​ນຶ່ງ.\n\nເພື່​ອ​ອອກ, ໃຫ້​ແຕະ​ປຸ່ມ​ແອັບຯ​ທີ່​ຫາ​ກໍ​ໃຊ້​ຄ້າງ​ໄວ້."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ບໍ່, ຂອບ​ໃຈ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"​ເລີ່ມ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ຮູບແບບປົດລັອກ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"​ລະ​ຫັດ​ຜ່ານ"</string>
-    <string name="battery_saver_description" msgid="725676363406667978">"ເພື່ອ​ຊ່ວຍ​ປັບ​ປຸ​ງ​ອາ​ຍຸ​ແບັດ​ເຕີ​ຣີ, ໂຕ​ປະ​ຢັດ​ແບັດ​ເຕີ​ຣີ​ຈະຫຼຸດ​ປະ​ສິດ​ທິ​ພາບ​ຂອງ​ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ​ລົງ ແລະ​ຈຳ​ກັດ​ການ​ສັ່ນ​ເຕືອນ ຮວມ​​ທັງ​ຂໍ້​ມູນ​ພື້ນຫຼັງ​ສ່ວນ​ໃຫຍ່. ອີ​ເມວ, ການ​ສົ່ງ​ຂໍ້​ຄ​ວາມ ແລະ​ແອັບຯ​ອື່ນໆ​ທີ່​ອີງ​ອາ​ໃສ​ການ​ຊິ້ງ​ຂໍ້​ມູນ​ອາດບໍ່​ມີ​ການ​ອັບ​ເດດ​ຈົນ​ກວ່າ​ທ່ານ​ຈະ​ເປີດ​ແອັບຯ​ເຫຼົ່າ​ນັ້ນ.\n\nໂຕ​ປະ​ຢັດ​ແບັດ​ເຕີ​ຣີ​ຈະ​ປິດ​ໂຕ​ເອງ​​ອັດ​ຕະ​ໂນ​ມັດ​ໃນ​ເວ​ລາ​ທີ່​ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ​ສາກ​ໄຟ​ຢູ່"</string>
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"​ປັກ​ໝຸດ​ໜ້າ​ຈໍ​ແລ້ວ"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"ຍົກ​ເລີກ​ການ​ປັກ​ໝຸນ​​ຫນ້າ​ຈໍ​ແລ້ວ"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"​ຖາມ​ຫາ PIN ກ່ອນ​ຍົກ​ເລີກ​ການປັກ​ໝຸດ"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"​ຖາມ​ຫາ​ຮູບ​ແບບ​ປົດ​ລັອກ​ກ່ອນ​ຍົກ​ເລີກ​ການ​ປັກ​ໝຸດ"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"​ຖາມ​ຫາ​ລະ​ຫັດ​ຜ່ານ​ກ່ອນ​ຍົກ​ເລີກ​ການ​ປັກ​ໝຸດ"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ເພື່ອ​ຊ່ວຍ​ປັບ​ປຸງ​ອາ​ຍຸ​ແບັດ​ເຕ​ີ​ຣີ, ໂຕ​ປະ​ຢັດ​ແບັດ​ເຕີ​ຣີ​ຈະຫຼຸດ​ປະ​ສິດ​ທິ​ພາບ​​ຂອງ​ອຸ​ປະ​ກອນ​ທ່ານ​ລົງ ແລະ​ຈຳ​ກັດ​ການ​ສັ່ນເຕືອນ ຮວມ​ເຖິງຂໍ້​ມູນ​ພື້ນຫຼັງ​ສ່ວນ​ໃຫຍ່​ນຳ. ອີ​ເມວ, ການ​ສົ່ງ​ຂໍ້​ຄວາມ ແລະ​ແອັບຯ​ອື່ນໆ​ທີ່​ອີງ​ອາ​ໃສ​ການ​ຊິ້ງ​ຂໍ້​ມູນ​ອາດບໍ່​ມີ​ການ​ອັບ​ເດດ​ຈົນ​ກວ່າ​ທ່ານ​ຈະ​ເປີດ​ພວກ​ມັນ​ຂຶ້ນ​ມາ.\n\n​ໂຕ​ປະ​ຢັດ​ແບັດ​ເຕີ​ຣີ​ຈະ​ປິດ​ໂດຍ​ອັດ​ຕະ​ໂນ​ມັດ​ເມື່ອ​ມີ​ອຸ​ປະ​ກອນ​ຖືກ​ສາກ​ໄຟ."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"ຈົນ​ກວ່າ​ດາວ​ທາມ​ຂອງ​ທ່ານ​ຈະ​ສິ້ນ​ສຸດ​ທີ່ <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ເປັນ​ເວລາ​ນຶ່ງ​ນາ​ທີ"</item>
+    <item quantity="other" msgid="6924190729213550991">"ເປັນ​ເວລາ %d ນາ​ທີ"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ເປັນ​ເວລາ​ນຶ່ງ​ຊົ່ວ​ໂມງ"</item>
+    <item quantity="other" msgid="5408537517529822157">"ເປັນ​ເວລາ %d ຊົ່ວ​ໂມງ"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"ຢ່າງ​ບໍ່​ມີ​ກຳນົດ"</string>
 </resources>
diff --git a/core/res/res/values-lt/strings.xml b/core/res/res/values-lt/strings.xml
index 5d65ce3..fd5b024 100644
--- a/core/res/res/values-lt/strings.xml
+++ b/core/res/res/values-lt/strings.xml
@@ -177,9 +177,9 @@
     <string name="global_actions" product="default" msgid="2406416831541615258">"Telefono parinktys"</string>
     <string name="global_action_lock" msgid="2844945191792119712">"Ekrano užraktas"</string>
     <string name="global_action_power_off" msgid="4471879440839879722">"Išjungiamas maitinimas"</string>
-    <string name="global_action_bug_report" msgid="7934010578922304799">"Pranešimas apie triktį"</string>
-    <string name="bugreport_title" msgid="2667494803742548533">"Pranešti apie triktį"</string>
-    <string name="bugreport_message" msgid="398447048750350456">"Bus surinkta informacija apie dabartinę įrenginio būseną ir išsiųsta el. pašto pranešimu. Šiek tiek užtruks, kol pranešimas apie triktį bus paruoštas siųsti; būkite kantrūs."</string>
+    <string name="global_action_bug_report" msgid="7934010578922304799">"Pranešimas apie riktą"</string>
+    <string name="bugreport_title" msgid="2667494803742548533">"Pranešti apie riktą"</string>
+    <string name="bugreport_message" msgid="398447048750350456">"Bus surinkta informacija apie dabartinę įrenginio būseną ir išsiųsta el. pašto pranešimu. Šiek tiek užtruks, kol pranešimas apie riktą bus paruoštas siųsti; būkite kantrūs."</string>
     <string name="global_action_toggle_silent_mode" msgid="8219525344246810925">"Tylus režimas"</string>
     <string name="global_action_silent_mode_on_status" msgid="3289841937003758806">"Garsas IŠJUNGTAS"</string>
     <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"Garsas ĮJUNGTAS"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Leidžiama savininkui susisaistyti su aukščiausiojo lygio nuotolinio ekrano sąsaja. Įprastoms programoms to neturėtų prireikti."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"susaistyti su valdiklio paslauga"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Leidžiama savininkui susisaistyti su aukščiausio lygio valdiklio paslaugos sąsaja. Įprastoms programoms to neturėtų prireikti."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"susisaistyti su maršruto parinkimo paslauga"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Savininkui leidžiama susisaistyti su bet kokiomis registruotomis maršrutų parinkimo paslaugomis. To niekada neturėtų prireikti naudojant įprastas programas."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"sąveikauti su įrenginio administratoriumi"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Leidžiama savininkui siųsti tikslus įrenginio administratoriui. Įprastoms programoms to neturėtų prireikti."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"susisaistyti su TV įvestimi"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"telefono įjungimas ir išjungimas"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Leidžiama programai įjungti ar išjungti planšetinį kompiuterį."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Leidžiama programai įjungti ar išjungti telefoną."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"iš naujo nustatyti vaizdo skirtąjį laiką"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Leidžiama programai iš naujo nustatyti vaizdo skirtąjį laiką."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"paleisti gamyklos bandymo režime"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Paleisti kaip žemo lygio gamintojo bandymą, leidžiant užbaigti prieigą prie aparatinės planšetinio kompiuterio įrangos. Pasiekiama tik tada, kai planšetinis kompiuteris veikia gamintojo bandymo režimu."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Paleisti kaip žemo lygio gamintojo bandymą, leidžiant užbaigti prieigą prie aparatinės telefono įrangos. Galima tik kai telefonas veikia gamintojo bandymo režimu."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Leidžiama programai skaityti talpyklos failų sistemą ir į ją rašyti."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"skambinti / priimti SIP skambučius"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Leidžiama programai skambinti ir priimti SIP skambučius."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"sąveika su gaunamojo skambučio ekranu"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Programai leidžiama valdyti, kada ir kaip naudotojai matys gaunamojo skambučio ekraną."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"sąveika su gaunamojo skambučio ekranu"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Programai leidžiama valdyti, kada ir kaip naudotojai matys gaunamojo skambučio ekraną."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"sąveikauti su telefonijos paslaugomis"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Programai leidžiama sąveikauti su telefonijos paslaugomis skambučiams atlikti / gauti."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"naudotojui teikti paslaugas vykstant skambučiui"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Programai leidžiama teikti naudotojui paslaugas vykstant skambučiui."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"skaityti tinklo naudojimo istoriją"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Leidžiama programai skaityti konkrečių tinklų ir programų tinklo naudojimo istoriją."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"valdyti tinklo politiką"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Leidžiama turėtojui susisaistyti su pranešimų skaitymo priemonės paslaugos aukščiausio lygio sąsaja. Įprastoms programoms to neturėtų prireikti."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"susaistyti su sąlygos teikėjo paslauga"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Turėtojui leidžiama susaistyti programą su sąlygos teikėjo paslaugos aukščiausio lygio sąsaja. Įprastoms programoms to niekada neturėtų prireikti."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"susaistyti su medijos maršruto paslauga"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Leidžiama savininką susaistyti su aukščiausio lygio medijos maršruto paslaugos sąsaja. Niekada neturėtų būti reikalinga įprastoms programoms."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"susisaistyti su mėgstama paslauga"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Savininkui leidžiama susisaistyti su mėgstamos paslaugos aukščiausio lygio sąsaja. Įprastoms programoms to neturėtų prireikti."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"iškviesti operatoriaus pateiktą konfigūravimo programą"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Bendrinti naudojant %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Pasirinkite programą, paleidžiamą spustelėjus pagrindinio ekrano mygtuką"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Šiam veiksmui tai naudoti pagal numatytuosius nustatymus."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Naudoti kitą programą"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Numatytuosius nustatymus išvalykite nuėję į „Sistemos nustatymai“ &gt; „Programos“ &gt; „Atsisiųsta“."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Pasirinkti veiksmą"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Pasirinkite USB įrenginio programą"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Leisti"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Uždrausti"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; norėtų išsiųsti pranešimą šiuo adresu: &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Gali būti taikomi mokesčiai"</font>" paskyroje mobiliesiems."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Bus taikomi mokesčiai paskyroje mobiliesiems."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Taip "<b>"galite būti apmokestinti"</b>" mobiliojo ryšio operatoriaus."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Taip būsite apmokestinti mobiliojo ryšio operatoriaus."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Siųsti"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Atšaukti"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Atsiminti mano pasirinkimą"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Palieskite, kad neleistumėte USB derinimo."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Klaviatūros keitimas"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Pasirinkti klaviatūras"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fizinė klaviatūra"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Rodyti įvesties metodą"</string>
     <string name="hardware" msgid="7517821086888990278">"Apar. įr."</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Pasirinkite klaviatūros išdėstymą"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Palieskite, kad pasirinktumėte klaviatūros išdėstymą."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Programai leidžiama susisaistyti su patikimos priemonės paslauga."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Sąveikauti su naujiniu ir atkūrimo sistema"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Programai leidžiama sąveikauti su atkūrimo sistema ir sistemos naujiniais."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Kurti medijos projekcijų seansus"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Programai leidžiama kurti medijos projekcijų seansus. Sukūrusios šiuos seansus, programos gali fiksuoti vaizdo ir garso turinį. To niekada neturėtų prireikti naudojant įprastas programas."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Tvarkyti medijos projektų sesijas"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Programai leidžiama tvarkyti medijos projektų sesijas. Šios sesijos leidžia programoms fiksuoti vaizdo ir garso turinį. Neturėtų prireikti naudojant įprastas programas."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Skaityti diegimo seansus"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Leidžiama programai skaityti diegimo seansus. Leidžiama peržiūrėti išsamią aktyvių paketų diegimo informaciją."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Dukart palieskite, kad valdytumėte mastelio keitimą"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Atmesti"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Pateikta užklausa dėl leidimo"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Pateikta leidimo užklausa\ndėl <xliff:g id="ACCOUNT">%s</xliff:g> paskyros"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Šią programą naudojate asmeninėje vietoje"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Šią programą naudojate darbo vietoje"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Šią programą naudojate ne darbo profilyje"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Šią programą naudojate darbo profilyje"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Įvesties būdas"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinchronizuoti"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Pasiekiamumas"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Sumažinti valandų skaičių"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Nustatyti po pusiaudienio"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Nustatyti prieš pusiaudienį"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"popiet"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"priešpiet"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Padidinti mėnesių skaičių"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Sumažinti mėnesių skaičių"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Padidinti dienų skaičių"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Redaguoti"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Įspėjimas dėl duomenų naudojimo"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Palieskite ir žr. naud. ir nust."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G–3G duomenys išjungti"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G duomenys išjungti"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobil. ryšio duomenys išjungti"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"„Wi-Fi“ duomenys išjungti"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Pasiektas limitas"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Pasiektas 2G–3G duomenų apribojimas"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Pasiektas 4G duomenų apribojimas"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Pasiektas mobiliųjų duomenų apribojimas"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Pasiektas „Wi-Fi“ duomenų apribojimas"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Pristabdyti likusio ciklo duomenys"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Viršyta 2G–3G duomenų riba"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Viršyta 4G duomenų riba"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Viršytas mobil. duom. limitas"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Priimti skambutį?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Visada"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Tik kartą"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"„%1$s“ nepalaiko darbo profilio."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s nepalaiko darbo profilio"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Planšetinis kompiuteris"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefonas"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Ausinės"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Pritaikymas neįgaliesiems įgalintas."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Pritaikymo neįgaliesiems režimas atšauktas."</string>
     <string name="user_switched" msgid="3768006783166984410">"Dabartinis naudotojas: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Perjungiama į <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Savininkas"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Klaida"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Administratorius neleidžia atlikti šio pakeitimo"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Pasirinkta: <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Ištrinta: <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Darbo <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Jei norite atsegti šį ekraną, palieskite ir vienu metu laikykite palietę Atgal ir Naujausi."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Jei norite atsegti šį ekraną, palieskite ir laikykite palietę Naujausi."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekranas yra prisegtas. Jūsų organizacija neleidžia jo atsegti."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Naudoti ekrano prisegimo funkciją?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Prisegus ekraną jis bus užrakintas viename rodinyje.\n\nKad išeitumėte, palieskite ir vienu metu laikykite palietę Atgal ir Naujausi."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Prisegus ekraną jis bus užrakintas viename rodinyje.\n\nKad išeitumėte, palieskite ir laikykite palietę Naujausi."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NE, AČIŪ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ĮJUNGTI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN kodas"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"atrakinimo piešinys"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"slaptažodis"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekrano prisegtas"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekranas atsegtas"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Prašyti PIN kodo prieš atsegant"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Prašyti atrakinimo piešinio prieš atsegant"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Prašyti slaptažodžio prieš atsegant"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Siekiant pailginti akumuliatoriaus veikimo laiką, Akumuliatoriaus tausojimo priemonė sumažina įrenginio našumą ir apriboja vibravimą bei daugumą foninių duomenų. El. paštas, pranešimų siuntimas ir kitos programos, kurios veikia sinchronizavimo pagrindu, gali nebūti atnaujintos, nebent jas atidarysite.\n\nKraunant įrenginį Akumuliatoriaus tausojimo priemonė automatiškai išjungiama."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Kol jūsų prastova baigsis <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 min."</item>
+    <item quantity="other" msgid="6924190729213550991">"%d min."</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 val."</item>
+    <item quantity="other" msgid="5408537517529822157">"%d val."</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Neapibrėžta"</string>
 </resources>
diff --git a/core/res/res/values-lv/strings.xml b/core/res/res/values-lv/strings.xml
index 7c07f92..a67eeb9 100644
--- a/core/res/res/values-lv/strings.xml
+++ b/core/res/res/values-lv/strings.xml
@@ -397,8 +397,8 @@
     <string name="permdesc_bindPrintService" msgid="7960067623209111135">"Ļauj īpašniekam izveidot savienojumu ar drukāšanas pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_bindPrintSpoolerService" msgid="6807762783744125954">"izveidot savienojumu ar drukas spolētāja pakalpojumu"</string>
     <string name="permdesc_bindPrintSpoolerService" msgid="3680552285933318372">"Ļauj īpašniekam izveidot savienojumu ar drukas spolētāja pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
-    <string name="permlab_bindNfcService" msgid="2752731300419410724">"Saistīt ar TDLS pakalpojumu"</string>
-    <string name="permdesc_bindNfcService" msgid="6120647629174066862">"Ļauj īpašniekam saistīt lietojumprogrammas, kas emulē TDLS kartes. Parastajām lietotnēm šī atļauja nav nepieciešama."</string>
+    <string name="permlab_bindNfcService" msgid="2752731300419410724">"Saistīt ar NFC pakalpojumu"</string>
+    <string name="permdesc_bindNfcService" msgid="6120647629174066862">"Ļauj īpašniekam saistīt lietojumprogrammas, kas emulē NFC kartes. Parastajām lietotnēm šī atļauja nav nepieciešama."</string>
     <string name="permlab_bindTextService" msgid="7358378401915287938">"saistīt ar īsziņu pakalpojumu"</string>
     <string name="permdesc_bindTextService" msgid="8151968910973998670">"Ļauj īpašniekam veikt saistīšanu ar īsziņu pakalpojuma augstākā līmeņa saskarni (piem., SpellCheckerService). Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_bindVpnService" msgid="4708596021161473255">"saistīt ar VPN pakalpojumu"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Ļauj īpašniekam izveidot saiti ar attāla displeja augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"saistīt ar logrīka pakalpojumu"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Ļauj īpašniekam izveidot saiti ar logrīka pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"Saistīšana ar maršruta nodrošinātāja pakalpojumu"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Ļauj īpašniekam saistīt jebkādus reģistrētus maršrutēšanas nodrošinātājus. Parastām lietotnēm šī atļauja nekad nav nepieciešama."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"mijiedarboties ar ierīces administratoru"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Ļauj īpašniekam nosūtīt informāciju par nodomiem ierīces administratoram. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"Izveidot saiti ar TV ieeju"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ieslēgt vai izslēgt tālruni"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Ļauj lietotnei ieslēgt vai izslēgt planšetdatoru."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Ļauj lietotnei ieslēgt vai izslēgt tālruni."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"displeja noildzes atiestatīšana"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Ļauj lietotnei atiestatīt displeja noildzi."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"darbināt rūpnīcas pārbaudes režīmā"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Darbina kā zema līmeņa ražotāja testu, atļaujot pilnīgu piekļuvi planšetdatora aparatūrai. Pieejama tikai tad, ja planšetdators darbojas ražotāja testa režīmā."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Darbiniet kā zema līmeņa ražotāja pārbaudi, atļaujot pilnīgu piekļuvi tālruņa aparatūrai. Pieejams tikai tad, ja tālrunis darbojas ražotāja pārbaudes režīmā."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Ļauj lietotnei lasīt un rakstīt kešatmiņas failu sistēmā."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP zvanu veikšana/saņemšana"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ļauj lietotnei veikt un saņemt SIP zvanus."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"mijiedarbība ar zvana laikā rādītu ekrānu"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Ļauj lietotnei kontrolēt, kad un kā lietotājam ir redzams zvana laikā redzamais ekrāns."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"Mijiedarboties ar zvana laikā rādītu ekrānu"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Ļauj lietotnei kontrolēt, kad un kā lietotājam ir redzams zvana laikā redzamais ekrāns."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"mijiedarbība ar tālruņu komunikācijas pakalpojumiem"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Ļauj lietotnei sazināties ar tālruņu komunikācijas pakalpojumiem, lai veiktu vai saņemtu zvanus."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"Nodrošināt lietotāja pieredzi zvana laikā"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Ļauj lietotnei nodrošināt lietotāja pieredzi zvana laikā."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lasīt informāciju par iepriekšēju tīkla izmantošanu"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Ļauj lietotnei lasīt informāciju par iepriekšēju tīkla izmantošanu saistībā ar noteiktiem tīkliem un lietotnēm."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"pārvaldīt tīkla politiku"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Ļauj īpašniekam izveidot saiti ar paziņojumu uztvērēja pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"Saistīšana ar nosacījumu sniedzēja pakalpojumu"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Ļauj īpašniekam izveidot savienojumu ar drukas nosacījumu sniedzēja pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"Saistīšana ar multivides datu maršrutēšanas pakalpojumu"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Ļauj īpašniekam izveidot saiti ar multivides datu maršrutēšanas pakalpojuma augstākā līmeņa saskarni. Nekad nav nepieciešama parastām lietotnēm."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"piesaistīt ekrānsaudzētāja pakalpojumu"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Ļauj īpašniekam piesaistīt ekrānsaudzētāja pakalpojuma augšējā līmeņa saskarni. Parastajām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"Operatora nodrošinātas konfigurācijas lietotnes izsaukšana"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Kopīgot, izmantojot %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Sākuma ekrāna lietotnes atlase"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Pēc noklusējuma izmantot šai darbībai."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Izmantot citu lietotni"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Notīriet noklusējuma iestatījumus šeit: Sistēmas iestatījumi &gt; Lietotnes &gt; Lejupielādētās."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Darbības izvēle"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Lietotnes izvēlēšanās USB ierīcei"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Atļaut"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Aizliegt"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vēlas sūtīt īsziņu adresātam &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"No jūsu mobilās ierīces konta "<font fgcolor="#ffffb060">"var tikt iekasēta maksa"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"No jūsu mobilās ierīces konta tiks iekasēta maksa."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"No jūsu mobilās ierīces konta "<b>"var tikt iekasēta maksa"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"No jūsu mobilās ierīces konta tiks iekasēta maksa."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Sūtīt"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Atcelt"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Atcerēties manu izvēli"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Pieskarieties, lai atspējotu USB atkļūdošanu."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Tastatūras maiņa"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Izvēlēties tastatūru"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fiziskā tastatūra"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Rādīt ievades metodi"</string>
     <string name="hardware" msgid="7517821086888990278">"Aparatūra"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Atlasiet tastatūras izkārtojumu"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Pieskarieties, lai atlasītu tastatūras izkārtojumu."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Ļauj lietojumprogrammai izveidot savienojumu ar uzticamības pārbaudes programmu."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Mijiedarbošanās ar atjauninājumu un atkopšanas sistēmu"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Ļauj lietojumprogrammai mijiedarboties ar atkopšanas sistēmu un sistēmas atjauninājumiem."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Izveidot satura projekcijas sesijas"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Ļauj lietojumprogrammai izveidot satura projekcijas sesijas. Šīs sesijas var atļaut lietojumprogrammām uzņemt ekrāna un skaņas saturu. Parastām lietotnēm tas nekad nav nepieciešams."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Pārvaldīt satura projekcijas sesijas"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Ļauj lietojumprogrammai pārvaldīt satura projekcijas sesijas. Šīs sesijas var atļaut lietojumprogrammām uzņemt ekrāna attēlu un tvert skaņas saturu. Parastām lietotnēm tas nekad nav nepieciešams."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Instalēšanas sesiju lasīšana"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Ļauj lietojumprogrammai lasīt instalēšanas sesijas. Tādējādi lietojumprogrammai ir pieejama informācija par aktīvajām pakotņu instalācijām."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Pieskarieties divreiz, lai kontrolētu tālummaiņu."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Noraidīt"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Atļauja ir pieprasīta."</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Atļauja kontam <xliff:g id="ACCOUNT">%s</xliff:g>\nir pieprasīta."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Jūs izmantojat šo lietotni savā personiskajā vidē."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Jūs izmantojat šo lietotni savā darba vidē."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Šo lietotni izmantojat ārpus sava darba profila"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Jūs izmantojat šo lietotni no sava darba profila."</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Ievades metode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinhronizācija"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Pieejamība"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Norādīt agrāku stundu"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Iestatīt pēcpusdienas laiku"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Iestatīt priekšpusdienas laiku"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"pēcpusd."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"priekšpusd."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Norādīt vēlāku mēnesi"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Norādīt agrāku mēnesi"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Norādīt vēlāku dienu"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Rediģēt"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Datu izmantošanas brīdinājums"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Piesk., lai sk. lietoš. un iest."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G–3G dati ir atslēgti"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G dati ir atslēgti"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobilie dati ir atslēgti"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi dati ir atslēgti"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Sasniegts ierobežojums"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Sasniegts 2G-3G datu ierobež."</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Sasniegts 4G datu ierobežojums"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Sasniegts mob. datu ierobežojums"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Sasniegts Wi-Fi datu ierobež."</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Datu lietošana ciklā pārtraukta."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G datu ierobež. pārsniegts"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G datu limits pārsniegts"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Pārsniegts mob. datu ierobežojums"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vai atbildēt uz zvanu?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Vienmēr"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Tikai vienreiz"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s neatbalsta darba profilu."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"Programma %1$s neatbalsta darba profilus"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Planšetdators"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Tālrunis"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Austiņas"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Pieejamības režīms ir iespējots."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Pieejamība ir atcelta."</string>
     <string name="user_switched" msgid="3768006783166984410">"Pašreizējais lietotājs: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Notiek pāriešana uz: <xliff:g id="NAME">%1$s</xliff:g>"</string>
     <string name="owner_name" msgid="2716755460376028154">"Īpašnieks"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Kļūda"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Jūsu administrators neļauj veikt šīs izmaiņas."</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Atlasīts: <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> tika dzēsts."</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Darbā: <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Lai atspraustu šo ekrānu, vienlaikus pieskarieties pogām “Atpakaļ” un “Pēdējās” un turiet tās nospiestas."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Lai atspraustu šo ekrānu, pieskarieties pogai “Pēdējās” un turiet to nospiestu."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekrāns ir piesprausts. Jūsu organizācija nav atļāvusi atspraušanu."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Vai izmantot ekrāna piespraušanu?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ekrāna piespraušana bloķē ekrānu vienā skatā.\n\nLai izietu, vienlaikus pieskarieties pogām “Atpakaļ” un “Pēdējās” un turiet tās nospiestas."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ekrāna piespraušana bloķē ekrānu vienā skatā.\n\nLai izietu, pieskarieties un pogai “Pēdējās” un turiet to nospiestu."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NĒ, PALDIES"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"SĀKT"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN kods"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"grafiskā atslēga"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"parole"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekrāns ir piesprausts"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekrāns ir atsprausts"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pirms atspraušanas pieprasīt PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pirms atspraušanas pieprasīt grafisko atslēgu"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pirms atspraušanas pieprasīt paroli"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Lai paildzinātu akumulatora darbības laiku, akumulatora enerģijas taupīšanas režīmā tiks pazemināta ierīces veiktspēja, samazināta vibrācija un ierobežota liela daļa fona datu. E-pasta, ziņojumapmaiņas un citas lietotnes, kas regulāri tiek sinhronizētas, tiks atjauninātas tikai tad, ja tās atvērsiet.\n\nIerīces uzlādes laikā akumulatora jaudas taupīšana tiek izslēgta automātiski."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Līdz beigsies dīkstāve (<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>)"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Vienu minūti"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Vienu stundu"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d h"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Uz nenoteiktu laiku"</string>
 </resources>
diff --git a/core/res/res/values-mcc234-mnc20/config.xml b/core/res/res/values-mcc234-mnc20/config.xml
index 1ed53dc..619e517 100644
--- a/core/res/res/values-mcc234-mnc20/config.xml
+++ b/core/res/res/values-mcc234-mnc20/config.xml
@@ -21,6 +21,22 @@
      for different hardware and product builds. -->
 <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
 
+    <!-- Array of ConnectivityManager.TYPE_xxxx values allowable for tethering -->
+    <!-- Common options are [1, 4] for TYPE_WIFI and TYPE_MOBILE_DUN or
+    <!== [0,1,5,7] for TYPE_MOBILE, TYPE_WIFI, TYPE_MOBILE_HIPRI and TYPE_BLUETOOTH -->
+    <integer-array translatable="false" name="config_tether_upstream_types">
+        <item>1</item>
+        <item>4</item>
+        <item>7</item>
+        <item>9</item>
+    </integer-array>
+
+    <!-- String containing the apn value for tethering.  May be overriden by secure settings
+         TETHER_DUN_APN.  Value is a comma separated series of strings:
+         "name,apn,proxy,port,username,password,server,mmsc,mmsproxy,mmsport,mcc,mnc,auth,type"
+         note that empty fields can be ommitted: "name,apn,,,,,,,,,310,260,,DUN" -->
+    <string translatable="false" name="config_tether_apndata">3hotspot,3hotspot,,,,,,,,,234,20,0,DUN</string>
+
     <!-- Configure mobile network MTU. Carrier specific value is set here.
     -->
     <integer name="config_mobile_mtu">1440</integer>
diff --git a/core/res/res/values-mcc235-mnc94/config.xml b/core/res/res/values-mcc235-mnc94/config.xml
index d602c9f..723af3d 100644
--- a/core/res/res/values-mcc235-mnc94/config.xml
+++ b/core/res/res/values-mcc235-mnc94/config.xml
@@ -21,6 +21,22 @@
      for different hardware and product builds. -->
 <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
 
+    <!-- Array of ConnectivityManager.TYPE_xxxx values allowable for tethering -->
+    <!-- Common options are [1, 4] for TYPE_WIFI and TYPE_MOBILE_DUN or
+    <!== [0,1,5,7] for TYPE_MOBILE, TYPE_WIFI, TYPE_MOBILE_HIPRI and TYPE_BLUETOOTH -->
+    <integer-array translatable="false" name="config_tether_upstream_types">
+        <item>1</item>
+        <item>4</item>
+        <item>7</item>
+        <item>9</item>
+    </integer-array>
+
+    <!-- String containing the apn value for tethering.  May be overriden by secure settings
+         TETHER_DUN_APN.  Value is a comma separated series of strings:
+         "name,apn,proxy,port,username,password,server,mmsc,mmsproxy,mmsport,mcc,mnc,auth,type"
+         note that empty fields can be ommitted: "name,apn,,,,,,,,,310,260,,DUN" -->
+    <string translatable="false" name="config_tether_apndata">3hotspot,3hotspot,,,,,,,,,235,94,0,DUN</string>
+
     <!-- Configure mobile network MTU. Carrier specific value is set here.
     -->
     <integer name="config_mobile_mtu">1440</integer>
diff --git a/core/res/res/values-mcc302-mnc220/config.xml b/core/res/res/values-mcc302-mnc220/config.xml
index 5259152..06b6efe 100644
--- a/core/res/res/values-mcc302-mnc220/config.xml
+++ b/core/res/res/values-mcc302-mnc220/config.xml
@@ -25,4 +25,6 @@
         <item>302720</item>
         <item>302780</item>
     </string-array>
+
+    <integer name="config_mobile_mtu">1410</integer>
 </resources>
diff --git a/core/res/res/values-mcc310-mnc004/config.xml b/core/res/res/values-mcc310-mnc004/config.xml
index 4aac79d..423e250 100644
--- a/core/res/res/values-mcc310-mnc004/config.xml
+++ b/core/res/res/values-mcc310-mnc004/config.xml
@@ -33,4 +33,5 @@
         <item>83</item>
     </string-array>
 
+    <bool name="config_auto_attach_data_on_creation">false</bool>
 </resources>
diff --git a/core/res/res/values-mcc310-mnc120/config.xml b/core/res/res/values-mcc310-mnc120/config.xml
index 62001d9..24e55b1 100644
--- a/core/res/res/values-mcc310-mnc120/config.xml
+++ b/core/res/res/values-mcc310-mnc120/config.xml
@@ -25,4 +25,6 @@
     -->
     <integer name="config_mobile_mtu">1422</integer>
 
+    <!-- Sprint need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">70</integer>
 </resources>
diff --git a/core/res/res/values-mcc310-mnc260/config.xml b/core/res/res/values-mcc310-mnc260/config.xml
index d602c9f..28cd695 100644
--- a/core/res/res/values-mcc310-mnc260/config.xml
+++ b/core/res/res/values-mcc310-mnc260/config.xml
@@ -25,4 +25,8 @@
     -->
     <integer name="config_mobile_mtu">1440</integer>
 
+    <!-- Flag specifying whether VoLTE & VT should be available for carrier: independent of
+         carrier provisioning. If false: hard disabled. If true: then depends on carrier
+         provisioning, availability etc -->
+    <bool name="config_carrier_volte_vt_available">true</bool>
 </resources>
diff --git a/core/res/res/values-mcc310-mnc410/config.xml b/core/res/res/values-mcc310-mnc410/config.xml
index c7ae8c8..b863aae 100644
--- a/core/res/res/values-mcc310-mnc410/config.xml
+++ b/core/res/res/values-mcc310-mnc410/config.xml
@@ -40,4 +40,9 @@
         <item>315</item>
         <item>316</item>
     </string-array>
+    <!-- Do not translate. Defines the slots is Two Digit Number for dialing normally not USSD -->
+    <string-array name="config_twoDigitNumberPattern">
+        <item>"0"</item>
+        <item>"00"</item>
+    </string-array>
 </resources>
diff --git a/core/res/res/values-mcc311-mnc220/config.xml b/core/res/res/values-mcc311-mnc220/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc220/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc221/config.xml b/core/res/res/values-mcc311-mnc221/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc221/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc222/config.xml b/core/res/res/values-mcc311-mnc222/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc222/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc223/config.xml b/core/res/res/values-mcc311-mnc223/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc223/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc224/config.xml b/core/res/res/values-mcc311-mnc224/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc224/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc225/config.xml b/core/res/res/values-mcc311-mnc225/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc225/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc226/config.xml b/core/res/res/values-mcc311-mnc226/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc226/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc227/config.xml b/core/res/res/values-mcc311-mnc227/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc227/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc228/config.xml b/core/res/res/values-mcc311-mnc228/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc228/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc229/config.xml b/core/res/res/values-mcc311-mnc229/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc229/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc480/config.xml b/core/res/res/values-mcc311-mnc480/config.xml
index e3d8420..cf19235 100644
--- a/core/res/res/values-mcc311-mnc480/config.xml
+++ b/core/res/res/values-mcc311-mnc480/config.xml
@@ -38,4 +38,10 @@
         be disabled) but individual Features can be disabled using ImsConfig.setFeatureValue() -->
     <bool name="imsServiceAllowTurnOff">false</bool>
 
+    <!-- Flag specifying whether VoLTE & VT should be available for carrier: independent of
+         carrier provisioning. If false: hard disabled. If true: then depends on carrier
+         provisioning, availability etc -->
+    <bool name="config_carrier_volte_vt_available">false</bool>
+
+    <bool name="config_auto_attach_data_on_creation">false</bool>
 </resources>
diff --git a/core/res/res/values-mcc311-mnc490/config.xml b/core/res/res/values-mcc311-mnc490/config.xml
new file mode 100644
index 0000000..defe78d
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc490/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- Sprint need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">70</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc580/config.xml b/core/res/res/values-mcc311-mnc580/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc580/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc581/config.xml b/core/res/res/values-mcc311-mnc581/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc581/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc582/config.xml b/core/res/res/values-mcc311-mnc582/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc582/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc583/config.xml b/core/res/res/values-mcc311-mnc583/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc583/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc584/config.xml b/core/res/res/values-mcc311-mnc584/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc584/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc585/config.xml b/core/res/res/values-mcc311-mnc585/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc585/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc586/config.xml b/core/res/res/values-mcc311-mnc586/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc586/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc587/config.xml b/core/res/res/values-mcc311-mnc587/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc587/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc588/config.xml b/core/res/res/values-mcc311-mnc588/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc588/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc589/config.xml b/core/res/res/values-mcc311-mnc589/config.xml
new file mode 100644
index 0000000..811e9c7
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc589/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- USC need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">300</integer>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc870/config.xml b/core/res/res/values-mcc311-mnc870/config.xml
new file mode 100644
index 0000000..24e55b1
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc870/config.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- Configure mobile network MTU. Carrier specific value is set here.
+    -->
+    <integer name="config_mobile_mtu">1422</integer>
+
+    <!-- Sprint need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">70</integer>
+</resources>
diff --git a/core/res/res/values-mcc312-mnc530/config.xml b/core/res/res/values-mcc312-mnc530/config.xml
new file mode 100644
index 0000000..24e55b1
--- /dev/null
+++ b/core/res/res/values-mcc312-mnc530/config.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 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 my 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.
+*/
+-->
+
+<!-- These resources are around just to allow their values to be customized
+     for different hardware and product builds. -->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+
+    <!-- Configure mobile network MTU. Carrier specific value is set here.
+    -->
+    <integer name="config_mobile_mtu">1422</integer>
+
+    <!-- Sprint need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">70</integer>
+</resources>
diff --git a/core/res/res/values-mcc425-mnc01/config.xml b/core/res/res/values-mcc425-mnc01/config.xml
deleted file mode 100644
index f4854da..0000000
--- a/core/res/res/values-mcc425-mnc01/config.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-** Copyright 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 my 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.
-*/
--->
-
-<!-- These resources are around just to allow their values to be customized
-     for different hardware and product builds. -->
-<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-
-    <!-- Array of ConnectivityManager.TYPE_xxxx values allowable for tethering -->
-    <!-- Common options are [1, 4] for TYPE_WIFI and TYPE_MOBILE_DUN or
-    <!== [0,1,5,7] for TYPE_MOBILE, TYPE_WIFI, TYPE_MOBILE_HIPRI and TYPE_BLUETOOTH -->
-    <integer-array translatable="false" name="config_tether_upstream_types">
-      <item>1</item>
-      <item>4</item>
-      <item>7</item>
-      <item>9</item>
-    </integer-array>
-
-    <!-- String containing the apn value for tethering.  May be overriden by secure settings
-         TETHER_DUN_APN.  Value is a comma separated series of strings:
-         "name,apn,proxy,port,username,password,server,mmsc,mmsproxy,mmsport,mcc,mnc,auth,type"
-         note that empty fields can be ommitted: "name,apn,,,,,,,,,310,260,,DUN" -->
-    <string translatable="false" name="config_tether_apndata">DUN,modem.orange.net.il,,,,,,,,,425,01,,DUN</string>
-
-</resources>
diff --git a/core/res/res/values-mk-rMK/strings.xml b/core/res/res/values-mk-rMK/strings.xml
index c53226a..f4ecd7e 100644
--- a/core/res/res/values-mk-rMK/strings.xml
+++ b/core/res/res/values-mk-rMK/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Овозможува сопственикот да се поврзе со интерфејс од највисоко ниво на приказ од далечина. Не треба да се користи за стандардни апликации."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"врзи се со услуга за виџет"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Дозволува сопственикот да се поврзе со интерфејс од највисоко ниво на услугата за додатоци. Не треба да се користи за стандардни апликации."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"поврзување со услуга за давател на маршрута"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Дозволува сопственикот да се поврзе со сите регистрирани даватели на маршрути. Не треба да се користи за стандардни апликации."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"комуницирај со администратор на уред"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Дозволува сопственикот да испраќа намери до администратор за уреди. Не треба да се користи за стандардни апликации."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"поврзување со ТВ-влез"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"вклучи или исклучи телефон"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Дозволува апликацијата да го вклучува или исклучува таблетот."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Дозволува апликацијата да го вклучува или исклучува телефонот."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ресетирај истечено време на екран"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Овозможува апликацијата да го ресетира истеченото време на екранот."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"извршувај во режим на фабричко тестирање"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Изврши во режим на фабричко тестирање од ниско ниво; дозволи целосен пристап кон хардверот на таблетот. Достапно само кога таблетот работи во режимот на фабричко тестирање."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Изврши во режим на фабричко тестирање од ниско ниво; дозволи целосен пристап кон хардверот на телефонот. Достапно само кога телефонот работи во режимот на фабричко тестирање."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Дозволува апликацијата да чита и да пишува кеш систем на датотеки."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"остварувај/примај повици преку СИП"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Дозволува апликацијата да остварува и прима повици преку СИП."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"комуницирај со екран на дојдовен повик"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Овозможува апликацијата да контролира кога и како корисникот го гледа екранот на дојдовен повик."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"комуницирај со екран на дојдовен повик"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Овозможува апликацијата да контролира кога и како корисникот го гледа екранот на дојдовен повик."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"комуницира со телефонски услуги"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Дозволува апликацијата да комуницира со телефонски услуги за да прави/прима повици."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"обезбеди искуство за корисникот при дојдовен повик"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Овозможува апликацијата да обезбеди искуство за корисникот при дојдовен повик."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"читај употреба на мрежа во минатото"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Дозволува апликацијата да го чита историското користење на мрежата за одредени мрежи или апликации."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"управувај со политика на мрежа"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Овозможува сопственикот да се поврзе со интерфејс од највисоко ниво на услугата слушател на известувања. Не треба да се користи за стандардни апликации."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"поврзување со услуга за давател на услов"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Дозволува сопственикот да се поврзе со интерфејс од највисоко ниво на давател на услуги за услов. Не треба да се користи за стандардни апликации."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"врзува со услуга за насочување медиуми"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Овозможува носителот да се врзува со интерфејс на највисоко ниво на услуга за насочување медиуми. Не би требало да е потребно за стандардни апликации."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"поврзи се со услугата мечтаење"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Дозволува сопственикот да се поврзе со интерфејс од највисоко ниво на услугата мечтаење. Не треба да се користи за стандардни апликации."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"повикај конфигурација на апликацијата обезбедена од давателот"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Сподели со %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Избери почетна апликација"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Користи ја стандардно за ова дејство."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Користи различна апликација"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Избриши ги стандардните вредности во Системски поставки &gt; Апликации &gt; Преземено."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Избери дејство"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Изберете апликација за УСБ-уредот"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Дозволи"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Одбиј"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; би сакала да испрати порака до &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ова "<font fgcolor="#ffffb060">"може да направи трошоци"</font>" на вашата сметка за мобилен телефон."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ова ќе направи трошоци на вашата сметка за мобилен телефон."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ова "<b>"може да направи трошоци"</b>" на вашата сметка за мобилен телефон."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ова ќе направи трошоци на вашата сметка за мобилен телефон."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Испрати"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Откажи"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Запомни го мојот избор"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Допрете за да се оневозможи отстранувањето грешки преку USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Измени тастатура"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Избери тастатури"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Физичка тастатура"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Прикажи влезен метод"</string>
     <string name="hardware" msgid="7517821086888990278">"Хардвер"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Избери изглед на тастатура"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Допри за да избереш изглед на тастатура."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Дозволува апликацијата да се поврзе со услуга за агенти за доверба."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Комуницирај со системот за обновување и ажурирање"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Овозможува апликацијата да комуницира со системот за обновување и ажурирање."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Создади сесии за проектирање на медиуми"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Дозволува апликацијата да создава сесии за проектирање на медиуми. Овие сесии им обезбедуваат можност на апликациите да снимаат екранска и аудиосодржина. Не би требало да се користи кај вообичаени апликации."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Управувај со сесиите на прикажување во медиумите"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Овозможува апликацијата да управува со сесиите на прикажување во медиумите. Ваквите сесии може на апликациите да им обезбедат можност да снимаат содржини на екран и аудиосодржини. На стандардните апликации ова не им е потребно."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Читај сесии на инсталирање"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Дозволува апликација да чита сесии на инсталирање. Тоа овозможува апликацијата да гледа детали за активни инсталации на пакет."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Допрете двапати за регулирање на зумирањето"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Одбиј"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Побарана е дозвола"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Побарана е дозвола\nза сметка <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Користите апликација во личниот простор"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Користите апликација во работниот простор"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Ја користите апликацијата надвор од работниот профил"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Ја користите апликацијата во работниот профил"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Метод на внес"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синхронизирај"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Пристапност"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Намали час"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Постави попладне"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Подеси претпладне"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"попладне"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"претпладне"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Зголеми месец"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Намали месец"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Зголеми ден"</string>
@@ -1537,11 +1534,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Уреди"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Предупредување за користење податоци"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Допри за да видиш употреба и подесувања."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Податоците 2G-3G се исклучени"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Податоците 4G се исклучени"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Мобилните податоци се исклучени"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Подат. преку Wi-Fi се исклучени"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Го достигнавте лимитот"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Постигна лимит за 2G-3G податоци"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Постигнат лимит за 4G податоци"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Постигна лимит за мобилни подат."</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Постигна лимит за Wi-Fi податоци"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Паузирано до крај на циклус"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Надминат лимит од 2G-3G податоци"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Надминат лимит од 4G податоци"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Лимитот за моб. подат. е надминат"</string>
@@ -1572,9 +1569,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Прифати повик?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Секогаш"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Само еднаш"</string>
-    <!-- String.format failed for translation -->
-    <!-- no translation found for activity_resolver_work_profiles_support (5462991471861024343) -->
-    <skip />
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s не поддржува работен профил"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Таблет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Слушалки"</string>
@@ -1647,6 +1642,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Овозможена е пристапност."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Пристапноста е откажана."</string>
     <string name="user_switched" msgid="3768006783166984410">"Тековен корисник <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Се префрла на <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Сопственик"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Грешка"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Администраторот не ја дозволува промената"</string>
@@ -1768,31 +1764,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Избрано <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Избришано <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Работа <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"За да го откачите екранот, допрете и задржете Назад и Неодамнешни истовремено."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"За да го откачите екранот, допрете и задржете Неодамнешни."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Екранот е закачен. Откачување не е дозволено од вашата организација."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Да се употреби закачување на екранот?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Закачувањето на екранот го заклучува екранот во еден приказ.\n\nЗа да излезете, допрете и задржете Назад и Неодамнешни истовремено."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Закачувањето на екранот го заклучува екранот во еден приказ.\n\nЗа да излезете, допрете и задржете Неодамнешни."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"НЕ, БЛАГОДАРАМ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"СТАРТ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"ПИН"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"шема за отклучување"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"лозинка"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Екранот е закачен"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Екранот е откачен"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Прашај за ПИН пред откачување"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Прашај за шема за отклучување пред откачување"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Прашај за лозинка пред откачување"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"За да помогне во подобрување на трајноста на батеријата, штедачот на батерија го намалува учинокот на уредот и ги ограничува вибрациите и повеќето податоци во заднина. Е-поштата, испраќањето пораки и другите апликации кои се потпираат на синхронизирање може да не се ажурираат освен ако не ги отворите.\n\nШтедачот на батерија автоматски се исклучува кога уредот се полни."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Додека не заврши паузата во <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"За една минута"</item>
+    <item quantity="other" msgid="6924190729213550991">"За %d минути"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"За еден час"</item>
+    <item quantity="other" msgid="5408537517529822157">"За %d часа"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Неодредено време"</string>
 </resources>
diff --git a/core/res/res/values-ml-rIN/strings.xml b/core/res/res/values-ml-rIN/strings.xml
index 733a508..6479f0a 100644
--- a/core/res/res/values-ml-rIN/strings.xml
+++ b/core/res/res/values-ml-rIN/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ഒരു വിദൂര ഡിസ്‌പ്ലേയുടെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ഹോൾഡറിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ഒരു വിജറ്റ് സേവനവുമായി ബന്ധിപ്പിക്കുക"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"ഒരു വിജറ്റ് സേവനത്തിന്റെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ഹോൾഡറിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"റൂട്ട് പ്രൊവൈഡർ സേവനവുമായി ബന്ധിപ്പിക്കുക"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ഏതെങ്കിലും രജിസ്‌റ്റർചെയ്‌ത റൂട്ട് ദാതാക്കളുമായി ബന്ധിപ്പിക്കാൻ ഹോൾഡറിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ഒരു ഉപകരണ അഡ്‌മിനുമായി സംവദിക്കുക"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"ഒരു ഉപകരണ അഡ്മിനിസ്‌ട്രേറ്ററിലേക്ക് ഇന്റന്റുകൾ അയയ്ക്കുന്നതിന് ദാതാവിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV ഇൻപുട്ടുമായി ബന്ധിപ്പിക്കുക"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ഫോൺ ഓണാക്കുക അല്ലെങ്കിൽ ഓഫാക്കുക"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ടാബ്‌ലെറ്റ് ഓൺ ചെയ്യുന്നതിനോ ഓഫുചെയ്യുന്നതിനോ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ഫോൺ ഓൺ ചെയ്യുന്നതിനോ ഓഫുചെയ്യുന്നതിനോ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ഡിസ്പ്ലേ കാലഹരണപ്പെടൽ പുനഃസജ്ജമാക്കുക"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"ഡിസ്പ്ലേ കാലഹരണപ്പെടൽ പുനഃസജ്ജമാക്കാൻ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ഫാക്‌ടറി പരീക്ഷണ മോഡിൽ പ്രവർത്തിപ്പിക്കുക"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"കുറഞ്ഞ നിലയിലുള്ള നിർമ്മാതാവിന്റെ പരീക്ഷണമായി പ്രവർത്തിപ്പിക്കുന്നത്, ടാബ്‌ലെറ്റ് ഹാർഡ്‌വെയറിലേക്ക് പൂർണ്ണ ആക്‌സസ്സ് അനുവദിക്കുന്നു. നിർമ്മാതാവിന്റെ പരീക്ഷണ മോഡിൽ ഒരു ടാബ്‌ലെറ്റ് പ്രവർത്തിക്കുമ്പോൾ മാത്രമേ ലഭ്യമാകൂ."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"കുറഞ്ഞ നിലയിലുള്ള നിർമ്മാതാവിന്റെ പരീക്ഷണമായി പ്രവർത്തിപ്പിക്കുന്നത്, ഫോൺ ഹാർഡ്‌വെയറിലേക്ക് പൂർണ്ണ ആക്‌സസ്സ് അനുവദിക്കുന്നു. നിർമ്മാതാവിന്റെ പരീക്ഷണ മോഡിൽ ഒരു ഫോൺ പ്രവർത്തിക്കുമ്പോൾ മാത്രമേ ലഭ്യമാകൂ."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"കാഷെ ഫയൽ സിസ്‌റ്റം റീഡുചെയ്യുന്നതിനും റൈറ്റുചെയ്യുന്നതിനും അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP കോളുകൾ വിളിക്കുക/സ്വീകരിക്കുക"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP കോളുകൾ വിളിക്കാനും സ്വീകരിക്കാനും അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ഇൻ-കോൾ സ്‌ക്രീനുമായി സംവദിക്കുക"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ഉപയോക്താവ് ഇൻ-കോൾ സ്‌ക്രീൻ എപ്പോൾ, എങ്ങനെ കാണുന്നുവെന്നത് നിയന്ത്രിക്കാൻ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ഇൻ-കോൾ സ്‌ക്രീനുമായി സംവദിക്കുക"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ഉപയോക്താവ് ഇൻ-കോൾ സ്‌ക്രീൻ എപ്പോൾ, എങ്ങനെ കാണുന്നുവെന്നത് നിയന്ത്രിക്കാൻ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ടെലിഫോണി സേവനങ്ങൾ ഉപയോഗിച്ച് സംവദിക്കുക"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"കോളുകൾ ചെയ്യുന്നതിനോ/സ്വീകരിക്കുന്നതിനോ ടെലിഫോണി സേവനങ്ങൾ ഉപയോഗിച്ച് സംവദിക്കാൻ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ഇൻ‌-കോൾ ഉപയോക്തൃ അനുഭവം നൽകുക"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ഇൻ- കോൾ ഉപയോക്തൃ അനുഭവം നൽകുന്നതിന് അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ചരിത്രപരമായ നെറ്റ്‌വർക്ക് ഉപയോഗം വായിക്കുക"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"നിർദ്ദി‌ഷ്‌ട നെറ്റ്‌വർക്കുകൾക്കും അപ്ലിക്കേഷനുകൾക്കുമുള്ള ചരിത്രപരമായ നെറ്റ്‌വർക്ക് ഉപയോഗം റീഡുചെയ്യുന്നതിന് അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"നെറ്റ്‌വർക്ക് നയം നിയന്ത്രിക്കുക"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ഒരു അറിയിപ്പ് ലിസണർ സേവനത്തിന്റെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ഹോൾഡറിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"കണ്ടീഷൻ പ്രൊവൈഡർ സേവനവുമായി ബന്ധിപ്പിക്കുക"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"ഒരു കണ്ടീഷൻ പ്രൊവൈഡർ സേവനത്തിന്റെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ഹോൾഡറിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"മീഡിയ റൂട്ട് സേവനവുമായി ബന്ധിപ്പിക്കുക"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"ഒരു മീഡിയ റൂട്ട് സേവനത്തിന്റെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ദാതാവിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"സ്വപ്‌നതുല്യമായ ഒരു സേവനത്തിലേക്ക് ബന്ധിപ്പിക്കുക"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"സ്വപ്‌നതുല്യമായ ഒരു സേവനത്തിന്റെ ഉയർന്ന നിലയിലുള്ള ഇന്റർഫേസിലേക്ക് ബന്ധിപ്പിക്കാൻ ദാതാവിനെ അനുവദിക്കുന്നു. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"കാരിയർ നൽകിയ കോൺഫിഗറേഷൻ അപ്ലിക്കേഷൻ റദ്ദാക്കുക"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s എന്നതുമായി പങ്കിടുക"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ഒരു ഹോം അപ്ലിക്കേഷൻ തിരഞ്ഞെടുക്കുക"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ഈ പ്രവർത്തനത്തിന് സ്ഥിരമായി ഉപയോഗിക്കുക."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"മറ്റൊരു അപ്ലിക്കേഷൻ ഉപയോഗിക്കുക"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"സിസ്‌റ്റം ക്രമീകരണങ്ങൾ &gt; അപ്ലിക്കേഷനുകൾ &gt; ഡൗൺലോഡുചെയ്‌തവ എന്നതിലെ സ്ഥിരമായതിനെ മറയ്ക്കുക."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ഒരു പ്രവർത്തനം തിരഞ്ഞെടുക്കുക"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB ഉപകരണത്തിന് ഒരു അപ്ലിക്കേഷൻ തിരഞ്ഞെടുക്കുക"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"അനുവദിക്കുക"</string>
     <string name="sms_control_no" msgid="625438561395534982">"നിരസിക്കുക"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt;, &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; എന്നതിലേക്ക് ഒരു സന്ദേശം അയയ്‌ക്കാൻ താൽപ്പര്യപ്പെടുന്നു."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ഇത് നിങ്ങളുടെ മൊബൈൽ അക്കൗണ്ടിൽ നിന്ന് "<font fgcolor="#ffffb060">"നിരക്കീടാക്കാൻ കാരണമാകാം."</font></string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"ഇത് നിങ്ങളുടെ മൊബൈൽ അക്കൗണ്ടിൽ നിന്നും നിരക്ക് ഈടാക്കുന്നതിന് കാരണമാകും."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"ഇത് നിങ്ങളുടെ മൊബൈൽ അക്കൗണ്ടിൽ നിന്ന് "<b>"നിരക്കുകൾ ഈടാക്കാൻ കാരണമാകാം"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ഇത് നിങ്ങളുടെ മൊബൈൽ അക്കൗണ്ടിൽ നിന്ന് നിരക്കുകൾ ഈടാക്കാൻ കാരണമാകും."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"അയയ്‌ക്കുക"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"റദ്ദാക്കുക"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"എന്റെ ചോയ്‌സ് ഓർമ്മിക്കുക"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB ഡീബഗ്ഗിംഗ് പ്രവർത്തനരഹിതമാക്കാൻ സ്‌പർശിക്കുക."</string>
     <string name="select_input_method" msgid="8547250819326693584">"കീബോർട്ട് മാറ്റുക"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"കീബോർഡുകൾ തിരഞ്ഞെടുക്കുക"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ഭൗതിക കീബോർഡ്"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ടൈപ്പുചെയ്യൽ രീതി കാണിക്കുക"</string>
     <string name="hardware" msgid="7517821086888990278">"ഹാർഡ്‌വെയർ"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"കീബോർഡ് ലേഔട്ട് തിരഞ്ഞെടുക്കുക"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"ഒരു കീബോർഡ് ലേഔട്ട് തിരഞ്ഞെടുക്കാൻ സ്‌പർശിക്കുക."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"ഒരു പരിചിത ഏജന്റ് സേവനത്തിലേക്ക് ബന്ധിപ്പിക്കാൻ അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"അപ്‌ഡേറ്റ്, വീണ്ടെടുക്കൽ സിസ്റ്റവുമായി സംവദിക്കുക"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"വീണ്ടെടുക്കൽ സിസ്റ്റവുമായും സിസ്റ്റം അപ്‌ഡേറ്റുകളുമായും സംവദിക്കാൻ ഒരു അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"മീഡിയ പ്രൊജക്ഷൻ സെഷനുകൾ സൃഷ്‌ടിക്കുക"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"മീഡിയ പ്രൊജക്ഷൻ സെഷനുകൾ സൃഷ്‌ടിക്കുന്നതിന് ഒരു അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു. അപ്ലിക്കേഷനുകൾക്ക് ഡിസ്‌പ്ലേയും ഓഡിയോ ഉള്ളടക്കങ്ങളും ക്യാപ്‌ചർചെയ്യുന്നതിനുള്ള കഴിവ് നൽകാൻ ഈ സെഷനുകൾക്കാവും. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"മീഡിയ പ്രൊജക്ഷൻ സെഷനുകൾ നിയന്ത്രിക്കുക"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"മീഡിയ പ്രൊജക്ഷൻ സെഷനുകൾ നിയന്ത്രിക്കുന്നതിന് അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു. അപ്ലിക്കേഷനുകൾക്ക് ഡിസ്‌പ്ലേയും ഓഡിയോ ഉള്ളടക്കങ്ങളും ക്യാപ്‌ചർചെയ്യുന്നതിനുള്ള കഴിവ് നൽകാൻ ഈ സെഷനുകൾക്കാവും. സാധാരണ അപ്ലിക്കേഷനുകൾക്ക് ഒരിക്കലും ആവശ്യമില്ല."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ഇൻസ്‌റ്റാൾ സെഷനുകൾ റീഡുചെയ്യുക"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ഇൻസ്റ്റാൾ ചെയ്‌ത സെഷനുകൾ റീഡുചെയ്യുന്നതിന് ഒരു അപ്ലിക്കേഷനെ അനുവദിക്കുന്നു. സജീവ പാക്കേജ് ഇൻസ്റ്റാളേഷനുകളെക്കുറിച്ചുള്ള വിശദാംശങ്ങൾ കാണുന്നതിന് ഇത് അനുവദിക്കുന്നു."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"സൂം ചെയ്യൽ നിയന്ത്രണങ്ങൾക്ക് രണ്ട് തവണ സ്‌പർശിക്കുക"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"നിരസിക്കുക"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"അനുമതി ആവശ്യമാണ്"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> എന്ന അക്കൗണ്ടിനായി\nഅനുമതി അഭ്യർത്ഥിച്ചു."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"നിങ്ങളുടെ സ്വകാര്യ ഇടത്തിൽ ഈ അപ്ലിക്കേഷൻ ഉപയോഗിക്കുന്നു"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"നിങ്ങളുടെ ഔദ്യോഗികയിടത്തിൽ ഈ അപ്ലിക്കേഷൻ ഉപയോഗിക്കുന്നു"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"നിങ്ങളുടെ ഔദ്യോഗിക പ്രൊഫൈലിന് പുറത്ത് ഈ അപ്ലിക്കേഷൻ ഉപയോഗിക്കുന്നു"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"നിങ്ങളുടെ ഔദ്യോഗിക പ്രൊഫൈലിൽ ഈ അപ്ലിക്കേഷൻ ഉപയോഗിക്കുന്നു"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ടൈപ്പുചെയ്യൽ രീതി"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"സമന്വയിപ്പിക്കുക"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"പ്രവേശനക്ഷമത"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"മണിക്കൂർ കുറയ്‌ക്കുക"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM സജ്ജീകരിക്കുക"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM സജ്ജീകരിക്കുക"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"മാസം വർദ്ധിപ്പിക്കുക"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"മാസം കുറയ്‌ക്കുക"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"ദിവസം വർദ്ധിപ്പിക്കുക"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"എഡിറ്റുചെയ്യുക"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ഡാറ്റ ഉപയോഗ മുന്നറിയിപ്പ്"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ഉപയോഗവും ക്രമീകരണങ്ങളും കാണാൻ സ്‌പർശിക്കുക."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G ഡാറ്റ ഓഫാണ്"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G ഡാറ്റ ഓഫാണ്"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"സെല്ലുലാർ ഡാറ്റ ഓഫാണ്"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi ഡാറ്റ ഓഫാണ്"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"പരിധിയെത്തി"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G ഡാറ്റ പരിധിയിലെത്തി"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G ഡാറ്റ പരിധിയിലെത്തി"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"സെല്ലുലാർ ഡാറ്റ പരിധിയിലെത്തി"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi ഡാറ്റ പരിധിയിലെത്തി"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ശേഷിക്കുന്ന പ്രവർത്തനങ്ങൾക്കായി ഡാറ്റ താൽക്കാലികമായി നിർത്തി"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G ഡാറ്റ പരിധി കവിഞ്ഞു"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ഡാറ്റ പരിധി കവിഞ്ഞു"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"സെല്ലുലാർ ഡാറ്റ പരിധി കവിഞ്ഞു"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"കോൾ സ്വീകരിക്കണോ?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"എല്ലായ്പ്പോഴും"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"ഒരിക്കൽ മാത്രം"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s എന്നത് ഔദ്യോഗിക പ്രൊഫൈലിനെ പിന്തുണയ്‌ക്കുന്നില്ല."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s, ഔദ്യോഗിക പ്രൊഫൈലിനെ പിന്തുണയ്‌ക്കുന്നില്ല"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ടാബ്‌ലെറ്റ്"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ഫോണ്‍"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ഹെഡ്‌ഫോണുകൾ"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"പ്രവേശനക്ഷമത പ്രവർത്തനക്ഷമമാക്കി."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"പ്രവേശനക്ഷമത റദ്ദാക്കി."</string>
     <string name="user_switched" msgid="3768006783166984410">"നിലവിലെ ഉപയോക്താവ് <xliff:g id="NAME">%1$s</xliff:g> ആണ്."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> എന്ന ഉപയോക്താവിലേക്ക് മാറുന്നു…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ഉടമ"</string>
     <string name="error_message_title" msgid="4510373083082500195">"പിശക്"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ഈ മാറ്റം നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്റർ അനുവദിച്ചതല്ല"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> തിരഞ്ഞെടുത്തു"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ഇല്ലാതാക്കി"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"ഔദ്യോഗികം <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ഈ സ്ക്രീൻ അൺപിൻ ചെയ്യാൻ, ഒരേസമയം \'മടങ്ങുക\', \'അടുത്തിടെയുള്ളവ\' എന്നിവ സ്‌പർശിച്ച് പിടിക്കുക."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ഈ സ്ക്രീൻ അൺപിൻ ചെയ്യാൻ, \'അടുത്തിടെയുള്ളവ\' സ്‌പർശിച്ച് പിടിക്കുക."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"സ്ക്രീൻ പിൻ ചെയ്തിരിക്കുന്നു. നിങ്ങളുടെ ഓർഗനൈസേഷൻ അൺപിൻ ചെയ്യൽ അനുവദിക്കുന്നില്ല."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"സ്ക്രീൻ പിൻ ചെയ്യൽ ഉപയോഗിക്കണോ?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"സ്ക്രീൻ പിന്നുചെയ്യുന്നത്, ഒരൊറ്റ കാഴ്ചയിൽ ഡിസ്പ്ലേ ലോക്കുചെയ്യുന്നതിനിടയാക്കും.\n\nപുറത്തുകടക്കുന്നതിന്, ഒരേസമയം \'മടങ്ങുക\', \'അടുത്തിടെയുള്ളവ\' എന്നിവ സ്‌പർശിച്ച് പിടിക്കുക."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"സ്ക്രീൻ പിന്നുചെയ്യുന്നത്, ഒരൊറ്റ കാഴ്ചയിൽ ഡിസ്പ്ലേ ലോക്കുചെയ്യുന്നതിനിടയാക്കും.\n\nപുറത്തുകടക്കുന്നതിന്, \'അടുത്തിടെയുള്ളവ\' സ്‌പർശിച്ച് പിടിക്കുക."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"വേണ്ട, നന്ദി"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ആരംഭിക്കുക"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"പിൻ"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"അൺലോക്ക് പാറ്റേൺ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"പാസ്‌വേഡ്"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"സ്ക്രീൻ പിൻ ചെയ്തു"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"സ്ക്രീൻ അൺപിൻ ചെയ്തു"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"അൺപിൻ ചെയ്യുന്നതിനുമുമ്പ് PIN ആവശ്യപ്പെടുക"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"അൺപിൻ ചെയ്യുന്നതിനുമുമ്പ് അൺലോക്ക് പാറ്റേൺ ആവശ്യപ്പെടുക"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"അൺപിൻ ചെയ്യുന്നതിനുമുമ്പ് പാസ്‌വേഡ് ആവശ്യപ്പെടുക"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ബാറ്ററി ആയുസ്സ് മെച്ചപ്പെടുത്താൻ സഹായിക്കുന്നതിന്, ബാറ്ററി സേവർ നിങ്ങളുടെ ഉപകരണത്തിന്റെ പ്രകടനത്തെ കുറയ്‌ക്കുകയും വൈബ്രേഷനെയും മിക്ക പശ്ചാത്തല ഡാറ്റയെയും പരിമിതപ്പെടുത്തുകയും ചെയ്യുന്നു. ഇമെയിൽ, സന്ദേശമയയ്‌ക്കൽ, സമന്വയിപ്പിക്കലിനെ ആശ്രയിച്ചുള്ള മറ്റ് അപ്ലിക്കേഷനുകൾ എന്നിവ നിങ്ങൾ തുറക്കുന്നതുവരെ അപ്‌ഡേറ്റുചെയ്യാനിടയില്ല.\n\nനിങ്ങളുടെ ഉപകരണം ചാർജ്ജുചെയ്യുമ്പോൾ ബാറ്ററി സേവർ യാന്ത്രികമായി ഓഫാകും."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>-ന് നിങ്ങളുടെ കാലാവധി അവസാനിക്കുന്നതുവരെ"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ഒരു മിനിറ്റ് ദൈർഘ്യം"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d മിനിറ്റ് ദൈർഘ്യം"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ഒരു മണിക്കൂർ ദൈർഘ്യം"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d മണിക്കൂർ ദൈർഘ്യം"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"അവ്യക്തം"</string>
 </resources>
diff --git a/core/res/res/values-mn-rMN/strings.xml b/core/res/res/values-mn-rMN/strings.xml
index 0e90ada..eea7f9d 100644
--- a/core/res/res/values-mn-rMN/strings.xml
+++ b/core/res/res/values-mn-rMN/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Эзэмшигчид алсын дэлгэц дэх дээд давхаргын интерфэйстэй холбогдох боломж олгоно. Энгийн апп-д шаардагдахгүй."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"виджет үйлчилгээтэй холбох"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Эзэмшигч нь виджет үйлчилгээний дээд-төвшиний интерфейстэй холбох боломжтой. Энгийн апп-д шаардлагагүй."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"маршрут нийлүүлэгчийн үйлчилгээтэй холбогдох"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Эзэмшигчид бүртгэгдсэн маршрут нийлүүлэгчтэй холбогдох  боломж олгоно. Энгийн апп-уудад хэзээ ч шаардагдахгүй."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"төхөөрөмжийн админтай харилцан үйлчлэх"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Эзэмшигч нь төхөөрөмжийн админруу интент илгээх боломжтой. Энгийн апп-д шаардлагагүй."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ТВ оролт холбох"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"утсыг унтраах эсвэл асаах"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Апп нь таблетыг асаах, унтраах боломжтой."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Апп нь утсыг асаах, унтраах боломжтой."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"дэлгэцийн амрах хугацааг тохируулах"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Апп-т дэлгэцийн амрах хугацааг өөрчлөхийг зөвшөөрнө."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"үйлдвэрийн тест горимд ажиллуулах"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Доод төвшиний үйлдвэрийн тестийг ажиллуулан таблетын хардверт бүрэн хандах боломжтой. Таблет нь үйлдвэрийн тестийн горимд ажиллах үед л боломжтой."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Доод төвшиний үйлдвэрийн тестийг ажиллуулан утасны хардверт бүрэн хандах боломжтой. Утас үйлдвэрийн тестийн горимд ажиллах үед л боломжтой."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Апп нь кеш файлсистемийг унших бичих боломжтой."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP дуудлага хийх/хүлээн авах"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Апп-д SIP дуудлага хийх болон хүлээн авахыг зөвшөөрөх."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"дуудлагын дэлгэцтэй харьцах"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Апп-д дуудлагын дэлгэцийг хэрэглэгчид хэзээ хэрхэн харуулахыг удирдахыг зөвшөөрнө."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"дуудлагын дэлгэцтэй харьцах"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Апп-д дуудлагын дэлгэцийг хэрэглэгчид хэзээ хэрхэн харуулахыг удирдахыг зөвшөөрнө."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"телефоны үйлчилгээтэй харилцах"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Апп-д телефон үйлчилгээтэй харилцаж дуудлага хийх/авахыг зөвшөөрнө."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"дуудлага хийж байгаа хэрэглэгчтэй харьцах"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Апп-д дуудлага хийж байгаа хэрэглэгчтэй харьцахыг зөвшөөрнө."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"сүлжээний ашиглалтын түүхийг унших"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Апп нь тусгай сүлжээ болон апп-н сүлжээ ашиглалтын түүхийг унших боломжтой."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"сүлжээний бодлогыг удирдах"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Эзэмшигч нь мэдэгдэл сонсох үйлчилгээний дээд-төвшиний интерфейстэй холбох боломжтой. Энгийн апп-д шаардлагагүй."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"нөхцөл нийлүүлэгч үйлчилгээнд холбох"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Эзэмшигчид нөхцөл нийлүүлэгч үйлчилгээний дээд-түвшний интерфейстэй холбох боломж олгоно. Энгийн апп-уудад хэзээ ч ашиглагдахгүй."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"медиа маршрут үйлчилгээтэй холбох"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Эзэмшигчид медиа маршрут үйлчилгээний дээр түвшний интерфэйст холбогдох боломж олгоно. Энгийн апп-д шаардагдахгүй."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"дрийм үйлчилгээнд холбох"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Эзэмшигч нь дрийм үйлчилгээний дээд-төвшиний интерфейстэй холбох боломжтой. Энгийн апп-д шаардлагагүй."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"үүрэн компанийн нийлүүлсэн тохируулгын апп-г өдөөх"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s ашиглан хуваалцах"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Нүүр апп-г сонгоно уу"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Энэ ажиллагааг үндсэн болгох."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Өөр апп ашиглах"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Систем тохиргоо &gt; Апп &gt; Татаж авсан хэсгийн үндсэн утгуудыг цэвэрлэх"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Үйлдэл сонгох"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB төхөөрөмжийн апп-г сонгох"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Зөвшөөрөх"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Татгалзах"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; нь &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; уруу мессеж илгээх гэж байна."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Энэ таны мобайл акаунтад "<font fgcolor="#ffffb060">"төлбөр гаргаж"</font>" болзошгүй."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Энэ таны мобайл акаунтад төлбөр гаргах болно."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Энэ таны мобайл акаунтад "<b>"төлбөр нэмэгдүүлж магадгүй"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Энэ таны мобайл акаунтад төлбөр нэмэгдүүлж магадгүй."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Илгээх"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Цуцлах"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Миний сонголтыг санах"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB дебаг хийхийг идэвхгүй болгох бол хүрнэ үү."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Гарыг өөрчлөх"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Гар сонгох"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Бодит гар"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Оруулах аргыг харуулах"</string>
     <string name="hardware" msgid="7517821086888990278">"Хардвер"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Гарын схемийг сонгох"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Гарын схемийг сонгох бол хүрнэ үү."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Аппликешнд итгэмжлэгдсэн төлөөлөгчтэй холбогдох боломж олгоно."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Шинэчлэлт болон сэргээх системтэй харилцах"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Аппликешнд сэргээх систем болон системийн шинэчлэлтэй харилцах боломж олгоно."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Медиа проекци үүсгэх"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Аппликешнд медиа проекци үүсгэхийг зөвшөөрнө. Ингэснээр аппликешнд дэлгэц болон аудио контентыг бичих боломж олгоно. Энгийн апп-д шаардагдахгүй."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Медиа проекци удирдах"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Аппликешнд медиа проекци удирдахыг зөвшөөрнө. Ингэснээр аппликешнд дэлгэц болон аудио контентыг бичих боломж олгоно. Энгийн апп-д шаардагдахгүй."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Суулгах сешн унших"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Аппликешн-д суулгах сешн уншихыг зөвшөөрнө. Энэ нь идэвхтэй багцуудыг суулгалтын талаар дэлгэрэнгүй мэдээллийг үзэх боломж олгоно."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Өсгөх контрол дээр хоёр удаа товшино уу"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Татгалзах"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Зөвшөөрөл хүсэв"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> акаунт зөвшөөрөл \n хүссэн"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Та энэ апп-г өөрийн хувийн профайл дээр ашиглаж байна"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Та энэ апп-г өөрийн ажлын профайл дээр ашиглаж байна"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Та энэ апп-г өөрийн ажлын профайлаас гадуур ашиглаж байна"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Та энэ апп-г өөрийн ажлын профайл дотор ашиглаж байна"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Оруулах арга"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синк"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Хандалт"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Цаг бууруулах"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM тохируулах"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM тохируулах"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ҮХ"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ҮӨ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Сар өсгөх"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Сарыг бууруулах"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Өдөр өсгөх"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Засах"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Дата хэрэглээний анхааруулга"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Ашиглалт болон тохиргоог харах бол хүрнэ үү."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G дата идэвхгүй"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G дата идэвхгүй"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Үүрэн дата идэвхгүй"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi дата идэвхгүй"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Хязгаарт хүрсэн"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G дата хязгаарт хүрсэн"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G дата хязгаарт хүрсэн"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Үүрэн дата хязгаарт хүрсэн"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi дата хязгаарт хүрсэн"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Циклийн үлдсэн хугацаанд датаг түр зогсоосон"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G дата хязгаар хэтрэв"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G дата хязгаар хэтрэв"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Үүрэн дата хязгаар хэтэрсэн"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Дуудлагыг зөвшөөрөх үү?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Байнга"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Нэг удаа"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ажлын профайлыг дэмждэггүй."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ажлын профайлыг дэмждэггүй"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Таблет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Утас"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Чихэвч"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Хялбаршуулсан горим идэвхжив."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Хандалт цуцлагдсан."</string>
     <string name="user_switched" msgid="3768006783166984410">"Одоогийн хэрэглэгч <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> руу сэлгэж байна…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Эзэмшигч"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Алдаа"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Энэ өөрчлөлтийг админ зөвшөөрөөгүй байна"</string>
@@ -1764,30 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> сонгогдсон"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> устсан"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Ажлын <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Дэлгэцийг суллахын тулд Буцах болон Саяхных-г зэрэг дараад барина уу."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Дэлгэцийг суллахын тулд Саяхных-д хүрээд барина уу."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Дэлгэцийг тогтоосон. Дэлгэц суллахыг таны байгууллага зөвшөөрөөгүй."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Дэлгэц тогтоогчийг ашиглах уу?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Дэлгэц тогтоогч нь дэлгэцийг нэг янзаар түгжинэ.\n\nГарахын тулд Буцах болон Саяхных-д зэрэг хүрээд барина уу."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Дэлгэц тогтоогч нь дэлгэцийг нэг янзаар түгжинэ.\n\nГарахын тулд Буцах болон Саяхных-д зэрэг хүрээд барина уу."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ҮГҮЙ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ЭХЛҮҮЛЭХ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"тайлах хээ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"нууц үг"</string>
-    <string name="battery_saver_description" msgid="725676363406667978">"Батерейны ашиглалтыг уртасгахын тулд батерей хэмнэгч нь таны төхөөрөмжийн ажиллагааг бууруулж, чичрэлт болон далд датаны ихэнх хувийг хязгаарлана. Имэйл, зурвас гэх мэт синк хийгддэг бусад апп-ууд таныг нээхээс нааш шинэчлэгдэхгүй байж болно.\n\nТаныг төхөөрөмжөө цэнэглэх үед батерей хэмнэгч автоматаар унтарна."</string>
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Дэлгэцийг тогтоосон"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Дэлгэцийг сулласан"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Тогтоосныг суллахаас өмнө PIN асуух"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Тогтоосныг суллахаас өмнө түгжээ тайлах хээ асуух"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Тогтоосныг суллахаас өмнө нууц үг асуух"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Батерейны ашиглалтыг уртасгахын тулд батерей хэмнэгч нь таны төхөөрөмжийн ажиллагааг бууруулж, чичрэлт болон далд датаны ихэнх хувийг хязгаарлана. Имэйл, зурвас гэх мэт синк хийгддэг бусад апп-ууд таныг нээхээс нааш шинэчлэгдэхгүй байж болно.\n\nТаныг төхөөрөмжөө цэнэглэх үед батерей хэмнэгч автоматаар унтарна."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Таны уйтгартай байдал <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>-д дуусах хүртэл"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Нэг минутын турш"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d минутын турш"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Нэг цагийн турш"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d цагийн турш"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Тодорхойгүй"</string>
 </resources>
diff --git a/core/res/res/values-mr-rIN/strings.xml b/core/res/res/values-mr-rIN/strings.xml
index cde4dd1..2e4a047 100644
--- a/core/res/res/values-mr-rIN/strings.xml
+++ b/core/res/res/values-mr-rIN/strings.xml
@@ -160,7 +160,7 @@
     <string name="turn_on_radio" msgid="3912793092339962371">"वायरलेस चालू करा"</string>
     <string name="turn_off_radio" msgid="8198784949987062346">"वायरलेस बंद करा"</string>
     <string name="screen_lock" msgid="799094655496098153">"स्क्रीन लॉक"</string>
-    <string name="power_off" msgid="4266614107412865048">"बंद"</string>
+    <string name="power_off" msgid="4266614107412865048">"बंद करा"</string>
     <string name="silent_mode_silent" msgid="319298163018473078">"रिंगर बंद"</string>
     <string name="silent_mode_vibrate" msgid="7072043388581551395">"रिंगर कंपन"</string>
     <string name="silent_mode_ring" msgid="8592241816194074353">"रिंगर चालू"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"होल्‍डरला दूरस्‍थ प्रदर्शनाच्‍या उच्च-दर्जाच्या इंटरफेसशी प्रतिबद्ध करण्‍याची अनुमती देते. सामान्‍य अ‍ॅप्‍ससाठी कधीही आवश्‍यक नसावे."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"विजेट सेवेवर प्रतिबद्ध व्हा"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"विजेट सेवेचा शीर्ष-स्तर इंटरफेस प्रतिबद्ध करण्‍यासाठी होल्‍डरला अनुमती देते. सामान्‍य अ‍ॅप्‍सकरिता कधीही आवश्‍यक नसते."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"एका मार्ग प्रदाता सेवेवर प्रतिबद्ध करा"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"कोणत्याही नोंदणीकृत मार्ग प्रदात्यांना प्रतिबद्ध करण्यासाठी होल्डरला अनुमती देते. सामान्य अॅप्सकरिता कधीही आवश्यकता नसते."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"डिव्हाइस प्रशासनाशी संवाद साधा"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"डिव्हाइस प्रशासकाकडे अभिप्राय पाठविण्यासाठी होल्डरला अनुमती देते. सामान्य अॅप्सकरिता कधीही आवश्यक नसते."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"एका टीव्ही इनपुटवर प्रतिबद्ध करा"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"फोन चालू किंवा बंद करा"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"टॅब्लेट चालू किंवा बंद करण्यासाठी अॅप ला अनुमती देते."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"फोन चालू किंवा बंद करण्यासाठी अॅप ला अनुमती देते."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"प्रदर्शन कालबाह्य रीसेट करा"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"अ‍ॅपला प्रदर्शन कालबाह्य रीसेट करण्‍याची अनुमती देते."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"फॅक्टरी चाचणी मोडमध्ये चालवा"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"टॅब्लेट हार्डवेअरमध्‍ये पूर्ण प्रवेशाची अनुमती देऊन निम्‍न-दर्जा निर्माता चाचणी म्‍हणून चालवा. टॅब्लेट केवळ निर्माता चाचणी मोडमध्‍ये चालत असताना उपलब्‍ध."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"फोन हार्डवेअरमध्‍ये पूर्ण प्रवेशाची अनुमती देऊन निम्‍न-दर्जा निर्माता चाचणी म्‍हणून चालवा. फोन केवळ निर्माता चाचणी मोडमध्‍ये चालत असताना उपलब्‍ध."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"कॅशे filesystem वाचण्यासाठी आणि लिहिण्यासाठी अॅप ला अनुमती देते."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP कॉल करा/प्राप्त करा"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"अॅपला SIP कॉल करण्‍याची आणि प्राप्त करण्‍याची अनुमती देते."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"कॉल-मध्‍ये स्‍क्रीनशी परस्‍परसंवाद करा"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"कॉल-मधील स्‍क्रीन वापरकर्ता केव्‍हा आणि कशी पाहतो अ‍ॅपला ते नियंत्रित करण्‍याची अनुमती देते."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"कॉल-मधील स्‍क्रीनशी परस्‍परसंवाद करा"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"वापरकर्ता कॉल-मधील स्‍क्रीन केव्‍हा आणि कशी पाहतो ते नियंत्रित करण्‍याची अ‍ॅपला अनुमती देते."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"टेलिफोनी सेवांशी परस्परसंवाद साधा"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"कॉल करण्यासाठी/घेण्यासाठी टेलिफोनी सेवांशी परस्परसंवाद साधण्यासाठी अॅप ला अनुमती देते."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"एक कॉल-मधील वापरकर्ता अनुभव प्रदान करा"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"अ‍ॅप्सला कॉल-मधील वापरकर्ता अनुभव प्रदान करण्‍याची अनुमती देते."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ऐतिहासिक नेटवर्क वापर वाचा"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"विशिष्ट नेटवर्क आणि अ‍ॅप्सकरिता ऐतिहासिक नेटवर्क वापराचे वाचन करण्यासाठी अ‍ॅप ला अनुमती देते."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"नेटवर्क धोरण व्यवस्थापित करा"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"होल्‍डरला सूचना ऐकणार्‍या सेवेच्‍या शीर्ष-दर्जाच्या इंटरफेसशी प्रतिबद्ध करण्‍याची अनुमती देते. सामान्‍य अ‍ॅप्‍ससाठी कधीही आवश्‍यक नसावे."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"एका अट प्रदाता सेवेवर प्रतिबद्ध करा"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"स्थिती प्रदाता सेवेचा शीर्ष-स्तर इंटरफेस प्रतिबद्ध करण्यासाठी होल्डरला अनुमती देते. सामान्य अॅप्सकरिता कधीही आवश्यक नसते."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"मीडिया मार्ग सेवेशी प्रतिबद्ध व्हा"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"मीडीया मार्ग सेवेच्या शीर्ष-दर्जाच्या इंटरफेसशी प्रतिबद्ध होण्यासाठी होल्डरला अनुमती द्या. सामान्य अॅप्ससाठी कधीही आवश्यकता नसावी."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"स्‍वप्न सेवेवर प्रतिबद्ध करा"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"होल्‍डरला स्‍वप्नसेवेच्या शीर्ष-स्‍तराच्या इंटरफेसशी प्रतिबद्ध करण्‍यास अनुमती देते. सामान्‍य अ‍ॅप्‍सकरिता कधीही आवश्‍यक नसते."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"वाहकाद्वारे-प्रदान केलेल्‍या कॉन्‍फिगरेशन अ‍ॅपची विनंती करा"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s सह सामायिक करा"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"मुख्‍यपृष्‍ठ अ‍ॅप निवडा"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"या क्रियेसाठी डीफॉल्‍टनुसार वापरा."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"एक भिन्न अ‍ॅप वापरा"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"डाउनलोड केलेल्या सिस्टीम सेटिंग्ज &gt; Apps &gt; मधील डीफॉल्ट साफ करा."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"क्रिया निवडा"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB डिव्हाइससाठी अॅप निवडा"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"अनुमती द्या"</string>
     <string name="sms_control_no" msgid="625438561395534982">"नकार द्या"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; हा &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;वर एक संदेश पाठवू इच्छितो."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"यामुळे आपल्या मोबाईल खात्यावर "<font fgcolor="#ffffb060">"शुल्क लागू शकते"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"यामुळे आपल्या मोबाईल खात्यावर शुल्क लागू शकते."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"यामुळे आपल्या मोबाईल खात्यावर "<b>"शुल्क आकारले जाऊ शकते"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"यामुळे आपल्या मोबाईल खात्यावर शुल्क आकारले जाऊ शकते."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"पाठवा"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"रद्द करा"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"माझी आवड लक्षात ठेवा"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB डीबग करणे अक्षम करण्यासाठी स्पर्श करा."</string>
     <string name="select_input_method" msgid="8547250819326693584">"कीबोर्ड बदला"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"कीबोर्ड निवडा"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"वास्तविक कीबोर्ड"</string>
+    <string name="show_ime" msgid="9157568568695230830">"इनपुट पद्धत दर्शवा"</string>
     <string name="hardware" msgid="7517821086888990278">"हार्डवेअर"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"कीबोर्ड लेआउट निवडा"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"कीबोर्ड लेआउट निवडण्यासाठी स्पर्श करा."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"विश्वासू एजंट सेवा प्रतिबद्ध करण्यासाठी अनुप्रयोगास अनुमती देते."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"अद्यतन आणि पुनर्प्राप्ती सिस्‍टमसह परस्‍परसंवाद करा"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"अनुप्रयोगाला पुनर्प्राप्ती सिस्‍ट‍मसह आणि सिस्‍टम अद्यतनांसह परस्‍परसंवाद करण्‍याची अनुमती देते."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"मीडिया प्रोजेक्शन सत्र तयार करा"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"अनुप्रयोगास मीडिया प्रोजेक्‍शन सत्र तयार करण्‍याची अनुमती देते. हे सत्र अनुप्रयोगांना प्रदर्शन आणि ऑडिओ सामग्री कॅप्‍चर करण्‍याची क्षमता प्रदान करु शकतात. सामान्य अ‍ॅप्‍स द्वारे कधीही आवश्यकता नसावी."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"मीडिया प्रोजेक्‍शन सत्र व्‍यवस्‍थापित करा"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"अनुप्रयोगास मीडिया प्रोजेक्‍शन सत्र व्यवस्‍थापित करण्‍याची अनुमती देते. हे सत्र अनुप्रयोगांना प्रदर्शन आणि ऑडिओ सामग्री कॅप्‍चर करण्‍याची क्षमता प्रदान करू शकतात. सामान्य अ‍ॅप्‍स द्वारे कधीही आवश्यकता नसावी."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"स्‍थापना सत्र वाचा"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"अनुप्रयोगास स्‍थापना सत्र वाचण्‍याची अनुमती देते. हे सक्रिय पॅकेज स्‍थापनांविषयी तपशील पाहाण्‍याची यास अनुमती देते."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"झूम नियंत्रणासाठी दोनदा स्पर्श करा"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"नकार द्या"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"परवानगीची विनंती केली"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> खात्यासाठी\nपरवानगीची विनंती केली."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"आपण आपल्‍या वैयक्तिक स्‍थानामध्‍ये या अ‍ॅपचा वापर करीत आहात"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"आपण आपल्‍या कार्य स्‍थानामध्‍ये या अ‍ॅपचा वापर करीत आहात"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"आपण हा अ‍ॅप आपल्‍या कार्य प्रोफाईलच्या बाहेर वापरत आहात"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"आपण हा अ‍ॅप आपल्या कार्य प्रोफाईलमध्‍ये वापरत आहात"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"इनपुट पद्धत"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"संकालन करा"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"प्रवेशयोग्यता"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"तास कमी करा"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM सेट करा"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM सेट करा"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"महिना वाढवा"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"महिना कमी करा"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"दिवस वाढवा"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"संपादित करा"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"डेटा वापर चेतावणी"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"वापर आणि सेटिंग्ज पाहण्यासाठी स्पर्श करा."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G डेटा बंद आहे"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G डेटा बंद आहे"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"सेल्युलर डेटा बंद आहे"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi डेटा बंद आहे"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"मर्यादा गाठली"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G डेटा मर्यादा गाठली"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G डेटा मर्यादा गाठली"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"सेल्‍युलर डेटा मर्यादा गाठली"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi डेटा मर्यादा गाठली"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"उर्वरित चक्रासाठी डेटास विराम दिला"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G डेटा मर्यादा ओलांडली"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G डेटा मर्यादा ओलांडली"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"सेल्युलर डेटा मर्यादा ओलांडली"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"कॉल स्वीकारायचा?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"नेहमी"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"फक्त एकदाच"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s कार्य प्रोफाईलला समर्थन देत नाही."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s कार्य प्रोफाईलचे समर्थन करीत नाही"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"टॅब्लेट"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"फोन"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"हेडफोन"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"प्रवेशयोग्यता सक्षम."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"प्रवेशयोग्यता रद्द."</string>
     <string name="user_switched" msgid="3768006783166984410">"वर्तमान वापरकर्ता <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> वर स्विच करत आहे…"</string>
     <string name="owner_name" msgid="2716755460376028154">"मालक"</string>
     <string name="error_message_title" msgid="4510373083082500195">"त्रुटी"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"या बदलास आपल्या प्रशासकाकडून अनुमती नाही"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> निवडले"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> हटविली"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"कार्य <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ही स्क्रीन अनपिन करण्यासाठी, एकाच वेळी परत आणि अलीकडील ला स्पर्श करा आणि धरून ठेवा."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ही स्क्रीन अनपिन करण्यासाठी, अलीकडील ला स्पर्श करा आणि धरून ठेवा."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"स्क्रीन पिन केली आहे. आपल्या संस्थेद्वारे अनपिन करण्यास अनुमती नाही."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"स्क्रीन पिन करणे वापरायचे?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"स्क्रीन पिन करणे एका एकल दृश्यामध्ये प्रदर्शन लॉक करते.\n\nबाहेर पडण्यासाठी, एकाच वेळी परत आणि अलीकडील ला स्पर्श करा आणि धरून ठेवा."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"स्क्रीन पिन करणे एका एकल दृश्यामध्ये प्रदर्शन लॉक करते.\n\nबाहेर पडण्यासाठी, अलीकडील ला स्पर्श करा आणि धरून ठेवा."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"नाही, धन्यवाद"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"प्रारंभ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"अनलॉक नमुना"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"संकेतशब्द"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"स्क्रीन पिन केली"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"स्क्रीन अनपिन केली"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"अनपिन करण्‍यापूर्वी PIN साठी विचारा"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"अनपिन करण्‍यापूर्वी अनलॉक नमुन्यासाठी विचारा"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"अनपिन करण्‍यापूर्वी संकेतशब्दासाठी विचारा"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"बॅटरीचे आयुष्य सुधारण्यात मदत होण्यासाठी, बॅटरी बचतकर्ता आपल्या डिव्हाइसचे कार्यप्रदर्शन कमी करतो आणि कंपन आणि बराच पार्श्वभूमी डेटा मर्यादित करतो. संकालनावर अवलंबून असणारे ईमेल, संदेशन आणि अन्य अॅप्स आपण ते उघडल्याशिवाय अद्यतनित होऊ शकत नाहीत.\n\nआपले डिव्हाइस चार्ज होत असते तेव्हा बॅटरी बचतकर्ता स्वयंचलितपणे बंद होतो."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"आपला कार्य न करण्याचा कालावधी <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> वाजता समाप्त होईपर्यंत"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"एक मिनिटासाठी"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d मिनिटांसाठी"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"एका तासासाठी"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d तासांसाठी"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्‍चितपणे"</string>
 </resources>
diff --git a/core/res/res/values-ms-rMY/strings.xml b/core/res/res/values-ms-rMY/strings.xml
index 0bf4ca6..0d632b0 100644
--- a/core/res/res/values-ms-rMY/strings.xml
+++ b/core/res/res/values-ms-rMY/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi paparan jauh. Tidak sekali-kali diperlukan untuk apl biasa."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"terikat kepada perkhidmatan widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi perkhidmatan widget. Tidak sekali-kali diperlukan untuk apl biasa."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"terikat kepada perkhidmatan pembekal laluan"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Membenarkan pemegang untuk terikat kepada mana-mana pembekal laluan yang berdaftar. Tidak sekali-kali diperlukan untuk apl normal."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"berinteraksi dengan pentadbir peranti"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Membenarkan pemegang menghantar tujuan kepada pentadbir peranti. Tidak sekali-kali diperlukan untuk apl biasa."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"ikat kepada input TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"kuasakan telefon hidup atau mati"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Membenarkan apl menghidupkan atau mematikan tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Membenarkan apl menghidupkan atau mematikan telefon."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"tetapkan semula tamat masa paparan"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Membenarkan apl menetapkan semula tamat masa paparan."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"jalankan dalam mod ujian kilang"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Jalankan sebagai ujian pengeluar peringkat rendah, membenarkan akses penuh kepada perkakasan tablet. Hanya tersedia apabila tablet dijalankan dalam mod ujian pengeluar."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Menjalankan sebagai ujian pengilang peringkat rendah, membenarkan akses penuh kepada perkakasan telefon. Hanya tersedia apabila telefon dijalankan dalam mod ujian pengilang."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Membenarkan apl membaca dan menulis cache sistem fail."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"buat/terima panggilan SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Membenarkan apl membuat dan menerima panggilan SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"berinteraksi dengan skrin dalam panggilan"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Membenarkan apl mengawal masa dan cara pengguna melihat skrin dalam panggilan."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"berinteraksi dengan skrin dalam panggilan"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Membenarkan apl mengawal masa dan cara pengguna melihat skrin dalam panggilan."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"berinteraksi dengan perkhidmatan telefoni"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Membenarkan apl berinteraksi dengan perkhidmatan telefoni untuk membuat/menerima panggilan."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"menyediakan pengalaman pengguna dalam panggilan"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Membenarkan apl menyediakan pengalaman pengguna dalam panggilan."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"baca sejarah penggunaan rangkaian"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Membenarkan apl membaca sejarah penggunaan rangkaian untuk rangkaian dan apl khusus."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"urus dasar rangkaian"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi perkhidmatan pendengar pemberitahuan. Tidak sekali-kali diperlukan untuk apl biasa."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"terikat kepada perkhidmatan pembekal keadaan"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi perkhidmatan pembekal keadaan. Tidak sekali-kali diperlukan untuk apl biasa."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"terikat kepada perkhidmatan laluan media"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi perkhidmatan laluan media. Tidak sekali-kali diperlukan untuk apl biasa."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"terikat kepada perkhidmatan impian"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Membenarkan pemegang terikat dengan antara muka peringkat tertinggi bagi perkhidmatan impian. Tidak sekali-kali diperlukan untuk apl biasa."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"gunakan apl konfigurasi yang disediakan oleh pembawa"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Kongsi dengan %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Pilih apl laman utama"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Gunakannya secara lalai untuk tindakan ini."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Gunakan apl lain"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Padam bersih lalai dalam tetapan Sistem &gt; Apl &gt; Dimuat turun."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Pilih tindakan"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Pilih apl untuk peranti USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Benarkan"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Nafikan"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ingin menghantar mesej kepada &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ini akan menyebabkan akaun mudah alih anda "<font fgcolor="#ffffb060">"dikenakan caj"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ini akan menyebabkan akaun mudah alih anda dikenakan caj."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ini "<b>"boleh menyebabkan"</b>" akaun mudah alih anda dikenakan bayaran."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ini akan menyebabkan akaun mudah alih anda dikenakan bayaran."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Hantar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Batal"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Ingat pilihan saya"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Sentuh untuk melumpuhkan penyahpepijatan USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Tukar papan kekunci"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Pilih papan kekunci"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Papan kekunci fizikal"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Tunjukkan kaedah input"</string>
     <string name="hardware" msgid="7517821086888990278">"Perkakasan"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Pilih susun atur papan kekunci"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Sentuh untuk memilih susun atur papan kekunci."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Membenarkan aplikasi terikat kepada perkhidmatan ejen amanah."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Berinteraksi dengan kemas kini dan sistem pemulihan"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Membenarkan aplikasi berinteraksi dengan sistem pemulihan dan kemas kini sistem."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Buat sesi unjuran media"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Membenarkan aplikasi membuat sesi unjuran media. Sesi ini boleh memberikan aplikasi keupayaan untuk mengabadikan paparan dan kandungan audio. Tidak sekali-kali diperlukan oleh apl biasa."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Urus sesi unjuran media"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Membenarkan aplikasi mengurus sesi unjuran media. Sesi ini boleh memberikan aplikasi keupayaan untuk mengabadikan paparan dan kandungan audio. Tidak sekali-kali diperlukan oleh apl biasa."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Baca sesi pemasangan"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Membenarkan aplikasi membaca sesi pemasangan Ini membenarkan apl melihat butiran mengenai pemasangan pakej yang aktif."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Sentuh dua kali untuk mendapatkan kawalan zum"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Nafi"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Kebenaran diminta"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Kebenaran diminta\nuntuk akaun <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Anda sedang menggunakan apl ini dalam ruang peribadi anda"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Anda sedang menggunakan apl ini dalam ruang kerja anda"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Anda menggunakan apl ini di luar profil kerja anda"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Anda menggunakan apl ini dalam profil kerja anda"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Kaedah input"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Penyegerakan"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Kebolehaksesan"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Kurangkan jam"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Tetapkan PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Tetapkan AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PTG"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"PG"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Tingkatkan bulan"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Kurangkan bulan"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Tingkatkan hari"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Amaran penggunaan data"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Sentuh untuk melihat penggunaan dan tetapan."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Data 2G-3G dimatikan"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Data 4G dimatikan"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Data selular dimatikan"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Data Wi-Fi dimatikan"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Sudah mencapai had"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Mencapai had data 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Mencapai had data 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mencapai had data selular"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Mencapai had data Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data dijeda untuk baki kitaran"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Melebihi had data 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Melebihi had data 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Melebihi had data seluluar"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Terima panggilan?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sentiasa"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Hanya sekali"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s tidak menyokong profil kerja."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s tidak menyokong profil kerja"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Fon kepala"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Kebolehcapaian didayakan."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Kebolehcapaian dibatalkan."</string>
     <string name="user_switched" msgid="3768006783166984410">"Pengguna semasa <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Bertukar kepada <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Pemilik"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Ralat"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Perubahan ini tidak dibenarkan oleh pentadbir anda"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> dipilih"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> dipadamkan"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Kerja <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Untuk menyahsemat skrin ini, sentuh dan tahan Kembali serta Terbaru serentak."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Untuk menyahsemat skrin ini, sentuh dan tahan Terbaru."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skrin disemat. Menyahsemat tidak dibenarkan oleh organisasi anda."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Gunakan penyematan skrin?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Penyematan skrin mengunci paparan dalam paparan tunggal.\n\nUntuk keluar, sentuh dan tahan Tekan serta Terbaru serentak."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Penyematan skrin mengunci paparan dalam paparan tunggal.\n\nUntuk keluar, sentuh dan tahan Terbaru."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"TIDAK, TERIMA KASIH"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"MULA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"corak buka kunci"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"kata laluan"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skrin disemat"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skrin dinyahsemat"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Minta PIN sebelum menyahsemat"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Minta corak buka kunci sebelum menyahsemat"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Minta kata laluan sebelum menyahsemat"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Untuk membantu memperbaik hayat bateri, penjimat bateri mengurangkan prestasi peranti anda dan menghadkan getaran serta kebanyakan data latar belakang. E-mel, pemesejan dan apl lain yang bergantung pada penyegerakan mungkin tidak dikemas kini melainkan anda membuka apl tersebut.\n\nPenjimat bateri dimatikan secara automatik semasa peranti anda mengecas."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Sehingga waktu gendala anda berakhir pada <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Selama satu minit"</item>
+    <item quantity="other" msgid="6924190729213550991">"Selama %d minit"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Selama satu jam"</item>
+    <item quantity="other" msgid="5408537517529822157">"Selama %d jam"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Selama-lamanya"</string>
 </resources>
diff --git a/core/res/res/values-my-rMM/strings.xml b/core/res/res/values-my-rMM/strings.xml
index 8fdeedb..c85a6e6 100644
--- a/core/res/res/values-my-rMM/strings.xml
+++ b/core/res/res/values-my-rMM/strings.xml
@@ -34,10 +34,10 @@
     <string name="durationHourMinutes" msgid="9029176248692041549">"<xliff:g id="HOURS">%1$d</xliff:g> နာရီ <xliff:g id="MINUTES">%2$d</xliff:g> မိနစ်"</string>
     <string name="durationHourMinute" msgid="2741677355177402539">"<xliff:g id="HOURS">%1$d</xliff:g> နာရီ <xliff:g id="MINUTES">%2$d</xliff:g> မိနစ်"</string>
     <string name="durationMinutes" msgid="3134226679883579347">"<xliff:g id="MINUTES">%1$d</xliff:g> မိနစ်"</string>
-    <string name="durationMinuteSeconds" msgid="1424656185379003751">"<xliff:g id="MINUTES">%1$d</xliff:g> မိနစ် <xliff:g id="SECONDS">%2$d</xliff:g> စက္ကန့်"</string>
-    <string name="durationMinuteSecond" msgid="3989228718067466680">"<xliff:g id="MINUTES">%1$d</xliff:g> မိနစ် <xliff:g id="SECONDS">%2$d</xliff:g> စက္ကန့်"</string>
-    <string name="durationSeconds" msgid="8050088505238241405">"<xliff:g id="SECONDS">%1$d</xliff:g> စက္ကန့်"</string>
-    <string name="durationSecond" msgid="985669622276420331">"<xliff:g id="SECONDS">%1$d</xliff:g> စက္ကန့်"</string>
+    <string name="durationMinuteSeconds" msgid="1424656185379003751">"<xliff:g id="MINUTES">%1$d</xliff:g> မိနစ် <xliff:g id="SECONDS">%2$d</xliff:g> စက္ကန့်"</string>
+    <string name="durationMinuteSecond" msgid="3989228718067466680">"<xliff:g id="MINUTES">%1$d</xliff:g> မိနစ် <xliff:g id="SECONDS">%2$d</xliff:g> စက္ကန့်"</string>
+    <string name="durationSeconds" msgid="8050088505238241405">"<xliff:g id="SECONDS">%1$d</xliff:g> စက္ကန့်"</string>
+    <string name="durationSecond" msgid="985669622276420331">"<xliff:g id="SECONDS">%1$d</xliff:g> စက္ကန့်"</string>
     <string name="untitled" msgid="4638956954852782576">"&lt;ခေါင်းစဉ်မဲ့&gt;"</string>
     <string name="ellipsis" msgid="7899829516048813237">"…"</string>
     <string name="ellipsis_two_dots" msgid="1228078994866030736">"‥"</string>
@@ -46,7 +46,7 @@
     <string name="defaultVoiceMailAlphaTag" msgid="2660020990097733077">"အသံစာပို့စနစ်"</string>
     <string name="defaultMsisdnAlphaTag" msgid="2850889754919584674">"MSISDN1"</string>
     <string name="mmiError" msgid="5154499457739052907">"ဆက်သွယ်မှုဆိုင်ရာပြသနာ သို့မဟုတ် မမှန်ကန်သောMMIကုတ်"</string>
-    <string name="mmiFdnError" msgid="5224398216385316471">"သတ်မှတ်ခေါ်ဆိုနိုင်သောနံပါတ်များထံသာ ကန့်သတ်ထားသည်"</string>
+    <string name="mmiFdnError" msgid="5224398216385316471">"သတ်မှတ်ခေါ်ဆိုနိုင်သောနံပါတ်များထံသာ ကန့်သတ်ထားသည်"</string>
     <string name="serviceEnabled" msgid="8147278346414714315">"ဝန်ဆောင်မှု လုပ်ဆောင်နိုင်မည်"</string>
     <string name="serviceEnabledFor" msgid="6856228140453471041">"ဝန်ဆောင်မှု ရရှိမည်"</string>
     <string name="serviceDisabled" msgid="1937553226592516411">"ဝန်ဆောင်မှုအား ရပ်ဆိုင်းသည်"</string>
@@ -56,10 +56,10 @@
     <string name="mmiComplete" msgid="8232527495411698359">"MMI ပြီးဆုံးပါပြီ"</string>
     <string name="badPin" msgid="9015277645546710014">"သင် ရိုက်ထည့်သော PIN ဟောင်းမှာ မမှန်ပါ။"</string>
     <string name="badPuk" msgid="5487257647081132201">"သင်ရိုက် ထည့်သော PUK မှာ မမှန်ကန်ပါ။"</string>
-    <string name="mismatchPin" msgid="609379054496863419">"သင် ရိုက်ထည့်ခဲ့သည့် PIN များ မတိုက်ဆိုင်ပါ။"</string>
-    <string name="invalidPin" msgid="3850018445187475377">"နံပါတ်(၄)ခုမှ(၈)ခုအထိပါရှိသော ပင်နံပါတ်အားထည့်ပါ"</string>
-    <string name="invalidPuk" msgid="8761456210898036513">"နံပါတ်(၈)ခုသို့မဟုတ် ထိုထက်ရှည်သောသော PUKအားထည့်သွင်းပါ"</string>
-    <string name="needPuk" msgid="919668385956251611">"ဆင်းမ်ကဒ် ရဲ့ ပင်နံပါတ် ပြန်ဖွင့်သည့် ကုဒ် သော့ကျနေပါသည်။ ဖွင့်ရန် ကုဒ်အားထည့်သွင်းပါ။"</string>
+    <string name="mismatchPin" msgid="609379054496863419">"သင် ရိုက်ထည့်ခဲ့သည့် PIN များ မတိုက်ဆိုင်ပါ။"</string>
+    <string name="invalidPin" msgid="3850018445187475377">"နံပါတ်(၄)ခုမှ(၈)ခုအထိပါရှိသော ပင်နံပါတ်အားထည့်ပါ"</string>
+    <string name="invalidPuk" msgid="8761456210898036513">"နံပါတ်(၈)ခုသို့မဟုတ် ထိုထက်ရှည်သောသော PUKအားထည့်သွင်းပါ"</string>
+    <string name="needPuk" msgid="919668385956251611">"ဆင်းမ်ကဒ် ရဲ့ ပင်နံပါတ် ပြန်ဖွင့်သည့် ကုဒ် သော့ကျနေပါသည်။ ဖွင့်ရန် ကုဒ်အားထည့်သွင်းပါ။"</string>
     <string name="needPuk2" msgid="4526033371987193070">"ဆင်းမ်ကဒ်အားမပိတ်ရန် PUK2အားထည့်သွင်းပါ"</string>
     <string name="enablePin" msgid="209412020907207950">"မအောင်မြင်ပါ, SIM/RUIM သော့ကို အရင် သုံးခွင့်ပြုရန်"</string>
   <plurals name="pinpuk_attempts">
@@ -72,24 +72,24 @@
     <string name="ClirMmi" msgid="7784673673446833091">"အထွက်ခေါ်ဆိုခြင်းအိုင်ဒီ"</string>
     <string name="ColpMmi" msgid="3065121483740183974">"လိုင်း ID ချိတ်ဆက်သည်"</string>
     <string name="ColrMmi" msgid="4996540314421889589">"လိုင်း ID ချိတ်ဆက်မှု ကန့်သတ်ချက်များ"</string>
-    <string name="CfMmi" msgid="5123218989141573515">"အဝင်ခေါ်ဆိုမှုအား ထပ်ဆင့်ပို့ခြင်း"</string>
-    <string name="CwMmi" msgid="9129678056795016867">"ခေါ်ဆိုမှု စောင့်ဆိုင်းခြင်း"</string>
+    <string name="CfMmi" msgid="5123218989141573515">"အဝင်ခေါ်ဆိုမှုအား ထပ်ဆင့်ပို့ခြင်း"</string>
+    <string name="CwMmi" msgid="9129678056795016867">"ခေါ်ဆိုမှု စောင့်ဆိုင်းခြင်း"</string>
     <string name="BaMmi" msgid="455193067926770581">"အဝင်ခေါ်ဆိုမှုအားတားဆီးခြင်း"</string>
     <string name="PwdMmi" msgid="7043715687905254199">"လျှို့ဝှက်နံပါတ်/စာ ပြောင်းသည်"</string>
     <string name="PinMmi" msgid="3113117780361190304">"ပင်နံပါတ်ပြောင်းသည်"</string>
     <string name="CnipMmi" msgid="3110534680557857162">"ခေါ်ဆိုသောနံပါတ်တည်ရှိသည်"</string>
-    <string name="CnirMmi" msgid="3062102121430548731">"ခေါ်ဆိုသောနံပါတ်အားကန့်သတ်ခြင်း"</string>
+    <string name="CnirMmi" msgid="3062102121430548731">"ခေါ်ဆိုသောနံပါတ်အားကန့်သတ်ခြင်း"</string>
     <string name="ThreeWCMmi" msgid="9051047170321190368">"(၃)ယောက်ဆိုင်ပြောဆိုခြင်း"</string>
-    <string name="RuacMmi" msgid="7827887459138308886">"စိတ်အနှောက်အယှက်ဖြစ်သော မလိုလားသည့်ခေါ်ဆိုမှုများအား ငြင်းဖယ်ခြင်း"</string>
+    <string name="RuacMmi" msgid="7827887459138308886">"စိတ်အနှောက်အယှက်ဖြစ်သော မလိုလားသည့်ခေါ်ဆိုမှုများအား ငြင်းဖယ်ခြင်း"</string>
     <string name="CndMmi" msgid="3116446237081575808">"ခေါ်ဆိုသောနံပါတ် ပေးပို့မှု"</string>
-    <string name="DndMmi" msgid="1265478932418334331">"မနှောက်ယှက်ပါနှင့်"</string>
-    <string name="CLIRDefaultOnNextCallOn" msgid="429415409145781923">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်ထားသည်။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်ထားသည်။"</string>
-    <string name="CLIRDefaultOnNextCallOff" msgid="3092918006077864624">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်ထားသည်။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်မထားပါ။"</string>
-    <string name="CLIRDefaultOffNextCallOn" msgid="6179425182856418465">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်မထားပါ။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်ထားသည်။"</string>
-    <string name="CLIRDefaultOffNextCallOff" msgid="2567998633124408552">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်မထားပါ။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်မထားပါ။"</string>
-    <string name="serviceNotProvisioned" msgid="8614830180508686666">"ဝန်ဆောင်မှုအား ကန့်သတ်မထားပါ"</string>
+    <string name="DndMmi" msgid="1265478932418334331">"မနှောက်ယှက်ပါနှင့်"</string>
+    <string name="CLIRDefaultOnNextCallOn" msgid="429415409145781923">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်ထားသည်။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်ထားသည်။"</string>
+    <string name="CLIRDefaultOnNextCallOff" msgid="3092918006077864624">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်ထားသည်။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်မထားပါ။"</string>
+    <string name="CLIRDefaultOffNextCallOn" msgid="6179425182856418465">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်မထားပါ။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်ထားသည်။"</string>
+    <string name="CLIRDefaultOffNextCallOff" msgid="2567998633124408552">"ပုံသေအားဖြင့် ခေါ်ဆိုသူအိုင်ဒီ(Caller ID)အား ကန့်သတ်မထားပါ။ နောက်ထပ်အဝင်ခေါ်ဆိုမှု-ကန့်သတ်မထားပါ။"</string>
+    <string name="serviceNotProvisioned" msgid="8614830180508686666">"ဝန်ဆောင်မှုအား ကန့်သတ်မထားပါ"</string>
     <string name="CLIRPermanent" msgid="3377371145926835671">"သင်သည် ခေါ်ဆိုသူ ID ဆက်တင်ကို မပြောင်းလဲနိုင်ပါ။"</string>
-    <string name="RestrictedChangedTitle" msgid="5592189398956187498">"ဝင်ရောက်ကြည့်ရှုခြင်းကန့်သတ်ချက်အားပြောင်းထားသည်"</string>
+    <string name="RestrictedChangedTitle" msgid="5592189398956187498">"ဝင်ရောက်ကြည့်ရှုခြင်းကန့်သတ်ချက်အားပြောင်းထားသည်"</string>
     <string name="RestrictedOnData" msgid="8653794784690065540">"ဒေတာဝန်ဆောင်မှုပိတ်ထားသည်။"</string>
     <string name="RestrictedOnEmergency" msgid="6581163779072833665">"အရေးပေါ်ဝန်ဆောင်မှုပိတ်ထားသည်။"</string>
     <string name="RestrictedOnNormal" msgid="4953867011389750673">"အသံဝန်ဆောင်မှုပိတ်ထားသည်။"</string>
@@ -106,25 +106,25 @@
     <string name="serviceClassDataSync" msgid="7530000519646054776">"ထပ်တူ ကိုက်ညီခြင်း"</string>
     <string name="serviceClassPacket" msgid="6991006557993423453">"Packet"</string>
     <string name="serviceClassPAD" msgid="3235259085648271037">"PAD"</string>
-    <string name="roamingText0" msgid="7170335472198694945">"ရုန်းမင်းအချက်ပြမီး ဖွင့်ထားခြင်း"</string>
+    <string name="roamingText0" msgid="7170335472198694945">"ရုန်းမင်းအချက်ပြမီး ဖွင့်ထားခြင်း"</string>
     <string name="roamingText1" msgid="5314861519752538922">"ရုန်းမင်းအချက်ပြမီး ပိတ်ထားခြင်း"</string>
     <string name="roamingText2" msgid="8969929049081268115">"ရုန်းမင်းအချက်ပြမီး လက်နေခြင်း"</string>
     <string name="roamingText3" msgid="5148255027043943317">"ပတ်ဝန်းကျင်အနီးအနားပြင်ပ"</string>
     <string name="roamingText4" msgid="8808456682550796530">"အဆောက်အဦးပြင်ပ"</string>
-    <string name="roamingText5" msgid="7604063252850354350">"ရုန်းမင်း-ပိုမိုသင့်တော်သောစနစ်"</string>
+    <string name="roamingText5" msgid="7604063252850354350">"ရုန်းမင်း-ပိုမိုသင့်တော်သောစနစ်"</string>
     <string name="roamingText6" msgid="2059440825782871513">"ရုန်းမင်း-ရရှိနိုင်သောစနစ်"</string>
     <string name="roamingText7" msgid="7112078724097233605">"ရုန်းမင်း-ပူးပေါင်းလုပ်ဖော်ကိုင်ဖက်"</string>
     <string name="roamingText8" msgid="5989569778604089291">"ရုန်းမင်း-အထူးတန်ဖိုးထားရသောလုပ်ဖော်ကိုင်ဖက်"</string>
-    <string name="roamingText9" msgid="7969296811355152491">"ရုန်းမင်း-ဝန်ဆောင်မှုအပြည့်လုပ်ဆောင်မှု"</string>
+    <string name="roamingText9" msgid="7969296811355152491">"ရုန်းမင်း-ဝန်ဆောင်မှုအပြည့်လုပ်ဆောင်မှု"</string>
     <string name="roamingText10" msgid="3992906999815316417">"ရုန်းမင်း-ဝန်ဆောင်မှုတစိတ်တပိုင်းလုပ်ဆောင်မှု"</string>
-    <string name="roamingText11" msgid="4154476854426920970">"ရုန်းမင်းစာတမ်းဖွင့်ရန်"</string>
+    <string name="roamingText11" msgid="4154476854426920970">"ရုန်းမင်းစာတမ်းဖွင့်ရန်"</string>
     <string name="roamingText12" msgid="1189071119992726320">"ရုန်းမင်းစာတမ်းပိတ်ထားရန်"</string>
     <string name="roamingTextSearching" msgid="8360141885972279963">"ဆားဗစ်အားရှာဖွေနေသည်"</string>
-    <string name="cfTemplateNotForwarded" msgid="1683685883841272560">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
+    <string name="cfTemplateNotForwarded" msgid="1683685883841272560">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
     <string name="cfTemplateForwarded" msgid="1302922117498590521">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: <xliff:g id="DIALING_NUMBER">{1}</xliff:g>"</string>
-    <string name="cfTemplateForwardedTime" msgid="9206251736527085256">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: <xliff:g id="DIALING_NUMBER">{1}</xliff:g> နောက် <xliff:g id="TIME_DELAY">{2}</xliff:g> စက္ကန့်"</string>
-    <string name="cfTemplateRegistered" msgid="5073237827620166285">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
-    <string name="cfTemplateRegisteredTime" msgid="6781621964320635172">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
+    <string name="cfTemplateForwardedTime" msgid="9206251736527085256">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: <xliff:g id="DIALING_NUMBER">{1}</xliff:g> နောက် <xliff:g id="TIME_DELAY">{2}</xliff:g> စက္ကန့်"</string>
+    <string name="cfTemplateRegistered" msgid="5073237827620166285">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
+    <string name="cfTemplateRegisteredTime" msgid="6781621964320635172">"<xliff:g id="BEARER_SERVICE_CODE">{0}</xliff:g>: ထပ်ဆင့်မပို့နိုင်ပါ"</string>
     <string name="fcComplete" msgid="3118848230966886575">"ပုံစံကုတ်ပြီးဆုံးသည်"</string>
     <string name="fcError" msgid="3327560126588500777">"ဆက်သွယ်မှုဆိုင်ရာပြသနာ သို့မဟုတ် တရားမဝင်သောပုံစံကုတ်"</string>
     <string name="httpErrorOk" msgid="1191919378083472204">"ကောင်းပြီ"</string>
@@ -132,11 +132,11 @@
     <string name="httpErrorLookup" msgid="4711687456111963163">"URL ကို ရှာဖွေ့ မတွေ့ရှိပါ"</string>
     <string name="httpErrorUnsupportedAuthScheme" msgid="6299980280442076799">"ဆိုက် မှန်ကန်မှု စိစစ်ရေး စနစ်ကို ပံ့ပိုး မပေးပါ။"</string>
     <string name="httpErrorAuth" msgid="1435065629438044534">"စစ်ဆေးမှု မအောင်မြင်ပါ"</string>
-    <string name="httpErrorProxyAuth" msgid="1788207010559081331">"ပရိုစီဆာဗာမှတဆင့် အထောက်အထားပြခြင်းမအောင်မြင်ပါ"</string>
+    <string name="httpErrorProxyAuth" msgid="1788207010559081331">"ပရိုစီဆာဗာမှတဆင့် အထောက်အထားပြခြင်းမအောင်မြင်ပါ"</string>
     <string name="httpErrorConnect" msgid="8714273236364640549">"ဆာဗာကို ဆက်သွယ်လို့ မရပါ"</string>
     <string name="httpErrorIO" msgid="2340558197489302188">"ဆာဗာနဲ့ ဆက်သွယ်လို့ မရပါ။ နောက်မှ ပြန်လည်ကြိုးစားပါ"</string>
     <string name="httpErrorTimeout" msgid="4743403703762883954">"ဆာဗာအားဆက်သွယ်မှု အချိန်ကုန်ဆုံးသွားပါသည်"</string>
-    <string name="httpErrorRedirectLoop" msgid="8679596090392779516">"ဤစာမျက်နှာတွင် ဆာဗာအားတဆင့်လွှဲမှု များစွာပါဝင်သည်"</string>
+    <string name="httpErrorRedirectLoop" msgid="8679596090392779516">"ဤစာမျက်နှာတွင် ဆာဗာအားတဆင့်လွှဲမှု များစွာပါဝင်သည်"</string>
     <string name="httpErrorUnsupportedScheme" msgid="5015730812906192208">"ပရိုတိုကောကို ပံ့ပိုး မပေးပါ။"</string>
     <string name="httpErrorFailedSslHandshake" msgid="96549606000658641">"လုံခြုံစိတ်ချရသော ဆက်သွယ်မှု မရပါ"</string>
     <string name="httpErrorBadUrl" msgid="3636929722728881972">"URL က အမှန်အကန် မဟုတ်သောကြောင့် စာမျက်နှာကို ဖွင့် လို့ မရပါ"</string>
@@ -148,7 +148,7 @@
     <string name="contentServiceSyncNotificationTitle" msgid="397743349191901458">"ထပ်တူ ကိုက်ညီခြင်း"</string>
     <string name="contentServiceTooManyDeletesNotificationDesc" msgid="8100981435080696431">"ဖျက်ရန် <xliff:g id="CONTENT_TYPE">%s</xliff:g> များစွာရှိ"</string>
     <string name="low_memory" product="tablet" msgid="6494019234102154896">"တက်ဘလက်တွင် သိမ်းဆည်းသော နေရာ ကုန်သွားပါပြီ။ တချို့ ဖိုင်များ ဖျက်စီးခြင်းဖြင့် နေရာလွတ် ပြုလုပ်ပါ"</string>
-    <string name="low_memory" product="watch" msgid="4415914910770005166">"သိုလှောင်ခန်း နေရာ ပြည့်နေပြီ။ နေရာ လွတ်လာရန် ဖိုင် အချို့ကို ဖျက်ပါ။"</string>
+    <string name="low_memory" product="watch" msgid="4415914910770005166">"သိုလှောင်ခန်း နေရာ ပြည့်နေပြီ။ နေရာ လွတ်လာရန် ဖိုင် အချို့ကို ဖျက်ပါ။"</string>
     <string name="low_memory" product="default" msgid="3475999286680000541">"ဖုန်းတွင် သိမ်းဆည်းသော နေရာ ကုန်သွားပါပြီ။ တချို့ ဖိုင်များ ဖျက်စီးခြင်းဖြင့် နေရာလွတ် ပြုလုပ်ပါ"</string>
     <string name="ssl_ca_cert_warning" msgid="5848402127455021714">"ကွန်ရက်ကို စောင့်ကြည့်စစ်ဆေးခံရနိုင်သည်"</string>
     <string name="ssl_ca_cert_noti_by_unknown" msgid="4475437862189850602">"အမျိုးအမည်မသိ တတိယ ပါတီဖြင့်"</string>
@@ -157,17 +157,17 @@
     <string name="power_dialog" product="tablet" msgid="8545351420865202853">"Tabletဆိုင်ရာရွေးချယ်မှုများ"</string>
     <string name="power_dialog" product="default" msgid="1319919075463988638">"ဖုန်းဆိုင်ရာရွေးချယ်မှုများ"</string>
     <string name="silent_mode" msgid="7167703389802618663">"အသံတိတ်စနစ်"</string>
-    <string name="turn_on_radio" msgid="3912793092339962371">"wirelessအားဖွင့်မည်"</string>
+    <string name="turn_on_radio" msgid="3912793092339962371">"wirelessအားဖွင့်မည်"</string>
     <string name="turn_off_radio" msgid="8198784949987062346">"wirelessအားပိတ်မည်"</string>
     <string name="screen_lock" msgid="799094655496098153">"ဖုန်းမျက်နှာပြင်အား သော့ချရန်"</string>
-    <string name="power_off" msgid="4266614107412865048">"ပိတ်ရန်"</string>
+    <string name="power_off" msgid="4266614107412865048">"စက်ပိတ်ပါ"</string>
     <string name="silent_mode_silent" msgid="319298163018473078">"ဖုန်းမြည်သံပိတ်ထားသည်"</string>
     <string name="silent_mode_vibrate" msgid="7072043388581551395">"တုန်ခါခြင်း ဖုန်းမြည်သံ"</string>
     <string name="silent_mode_ring" msgid="8592241816194074353">"ဖုန်းမြည်သံဖွင့်ထားသည်"</string>
     <string name="shutdown_progress" msgid="2281079257329981203">"စက်ပိတ်ပါမည်"</string>
-    <string name="shutdown_confirm" product="tablet" msgid="3385745179555731470">"သင့်တက်ပလက်အား စက်ပိတ်ပါမည်"</string>
-    <string name="shutdown_confirm" product="watch" msgid="3490275567476369184">"သင်၏ ကြည့်ရှုမှု ပိတ်ပစ်မည်။"</string>
-    <string name="shutdown_confirm" product="default" msgid="649792175242821353">"သင့်ဖုန်းအား စက်ပိတ်ပါမည်"</string>
+    <string name="shutdown_confirm" product="tablet" msgid="3385745179555731470">"သင့်တက်ပလက်အား စက်ပိတ်ပါမည်"</string>
+    <string name="shutdown_confirm" product="watch" msgid="3490275567476369184">"သင်၏ ကြည့်ရှုမှု ပိတ်ပစ်မည်။"</string>
+    <string name="shutdown_confirm" product="default" msgid="649792175242821353">"သင့်ဖုန်းအား စက်ပိတ်ပါမည်"</string>
     <string name="shutdown_confirm_question" msgid="2906544768881136183">"သင်က ပိတ်ပစ်မှာကို လိုပါသလား?"</string>
     <string name="reboot_safemode_title" msgid="7054509914500140361">"safe mode ဖြင့် ပြန်လည် စ တင်ရန်"</string>
     <string name="reboot_safemode_confirm" msgid="55293944502784668">"safe mode ကို ပြန်လည် စတင် မလား? ဒီလို စတင်ခြင်းဟာ သင် သွင်းထားသော တတိယပါတီ အပလီကေးရှင်းများအား ရပ်ဆိုင်းထားပါမည်။ ပုံမှန်အတိုင်း ပြန်စလျှင် ထိုအရာများ ပြန်လည် ရောက်ရှိလာပါမည်။"</string>
@@ -182,9 +182,9 @@
     <string name="bugreport_message" msgid="398447048750350456">"သင့်ရဲ့ လက်ရှိ စက်အခြေအနေ အချက်အလက်များကို အီးမေးလ် အနေဖြင့် ပေးပို့ရန် စုဆောင်းပါမည်။ အမှားရှာဖွေပြင်ဆင်မှုမှတ်တမ်းမှ ပေးပို့ရန် အသင့်ဖြစ်သည်အထိ အချိန် အနည်းငယ်ကြာမြင့်မှာ ဖြစ်သဖြင့် သည်းခံပြီး စောင့်ပါရန်"</string>
     <string name="global_action_toggle_silent_mode" msgid="8219525344246810925">"အသံတိတ်စနစ်"</string>
     <string name="global_action_silent_mode_on_status" msgid="3289841937003758806">"အသံပိတ်ထားသည်"</string>
-    <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"အသံဖွင့်ထားသည်"</string>
+    <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"အသံဖွင့်ထားသည်"</string>
     <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"လေယာဥ်ပျံပေါ်အသုံးပြုသောစနစ်"</string>
-    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"လေယဥ်ပျံပေါ်၌အသုံးပြုသောစနစ်ဖွင့်ထားသည်"</string>
+    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"လေယဥ်ပျံပေါ်၌အသုံးပြုသောစနစ်ဖွင့်ထားသည်"</string>
     <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"လေယဥ်ပျံပေါ်၌အသုံးပြုသောစနစ်ပိတ်ထားသည်"</string>
     <string name="global_action_settings" msgid="1756531602592545966">"ဆက်တင်များ"</string>
     <string name="global_action_lockdown" msgid="8751542514724332873">"ယခု သော့ပိတ်ရန်"</string>
@@ -195,13 +195,13 @@
     <string name="managed_profile_label" msgid="6260850669674791528">"အလုပ်"</string>
     <string name="permgrouplab_costMoney" msgid="5429808217861460401">"သင်ငွေကုန်ကျမည်ဖြစ်သောဝန်ဆောင်မှုများ"</string>
     <string name="permgroupdesc_costMoney" msgid="3293301903409869495">"သင်ပိုက်ဆံကုန်ကျစေသော အရာများ ပြုလုပ်ခြင်း"</string>
-    <string name="permgrouplab_messages" msgid="7521249148445456662">"သင့်စာများ"</string>
-    <string name="permgroupdesc_messages" msgid="7821999071003699236">"Read and write သင်၏ စာတို၊ အီးမေးလ်၊ နှင့် အခြား စာများကို ဖတ်ခြင်း နှင့် ရေးခြင်း။"</string>
-    <string name="permgrouplab_personalInfo" msgid="3519163141070533474">"သင့်ကိုယ်ပိုင်ရေးရာအချက်အလက်များ"</string>
+    <string name="permgrouplab_messages" msgid="7521249148445456662">"သင့်စာများ"</string>
+    <string name="permgroupdesc_messages" msgid="7821999071003699236">"Read and write သင်၏ စာတို၊ အီးမေးလ်၊ နှင့် အခြား စာများကို ဖတ်ခြင်း နှင့် ရေးခြင်း။"</string>
+    <string name="permgrouplab_personalInfo" msgid="3519163141070533474">"သင့်ကိုယ်ပိုင်ရေးရာအချက်အလက်များ"</string>
     <string name="permgroupdesc_personalInfo" msgid="8426453129788861338">"အဆက်အသွယ်ကဒ်ထဲ၌ သိမ်းဆည်းထားသော သင့် သတင်းအချက်အလက်များအား တိုက်ရိုက်အသုံးပြုခွင့် ရယူရန်"</string>
     <string name="permgrouplab_socialInfo" msgid="5799096623412043791">"သင်၏ ဆိုရှယ် သတင်းအချက်အလက်"</string>
     <string name="permgroupdesc_socialInfo" msgid="7129842457611643493">"သင်၏ အဆက်အသွယ်များနှင့် ဆိုရှယ်လ် အဆက်အသွယ်များအား၏ သတင်းအချက်အလက်များအား တိုက်ရိုက်အသုံးပြုခွင့် ရယူရန်"</string>
-    <string name="permgrouplab_location" msgid="635149742436692049">"သင့်တည်နေရာ"</string>
+    <string name="permgrouplab_location" msgid="635149742436692049">"သင့်တည်နေရာ"</string>
     <string name="permgroupdesc_location" msgid="5704679763124170100">"သင် ရောက်ရှိနေသော တည်နေရာကို စောင့်ကြည့်ခြင်း"</string>
     <string name="permgrouplab_network" msgid="5808983377727109831">"ကွန်ယက်ဆက်သွယ်မှု"</string>
     <string name="permgroupdesc_network" msgid="4478299413241861987">"ကွန်ရက် စွမ်းဆောင်ချက် အမျိုးမျိုးအသုံးပြုခွင့်ပေးရန်"</string>
@@ -239,52 +239,52 @@
     <string name="permgroupdesc_statusBar" msgid="6242593432226807171">"စက်ရဲ့ အခြေအနေပြ ဘား ဆက်တင်အား ပြင်ဆင်ရန်"</string>
     <string name="permgrouplab_syncSettings" msgid="3341990986147826541">"ထပ်တူပြုဆက်တင်များ"</string>
     <string name="permgroupdesc_syncSettings" msgid="7603195265129031797">"ထပ်တူညီအောင်လုပ်ရန်ဆက်တင်အား အသုံးပြုခွင့်ပေးရန်"</string>
-    <string name="permgrouplab_accounts" msgid="3359646291125325519">"သင့်အကောင့်များ"</string>
-    <string name="permgroupdesc_accounts" msgid="4948732641827091312">"ရရိှနိုင်သောအကောင့်များကို အသုံးပြုရန်"</string>
+    <string name="permgrouplab_accounts" msgid="3359646291125325519">"သင့်အကောင့်များ"</string>
+    <string name="permgroupdesc_accounts" msgid="4948732641827091312">"ရရိှနိုင်သောအကောင့်များကို အသုံးပြုရန်"</string>
     <string name="permgrouplab_hardwareControls" msgid="7998214968791599326">"စက်ပစ္စည်းအား ထိန်းချုပ်ရန်"</string>
     <string name="permgroupdesc_hardwareControls" msgid="4357057861225462702">"ဖုန်း၏ စက်ပိုင်းဆိုင်ရာကို တိုက်ရိုက်ဝင်ရောက်ရန်"</string>
     <string name="permgrouplab_phoneCalls" msgid="9067173988325865923">"ဖုန်းခေါ်ဆိုမှုများ"</string>
-    <string name="permgroupdesc_phoneCalls" msgid="7489701620446183770">"ဖုန်းခေါ်ဆိုမှုများကို စောင့်ကြည့်စစ်ဆေးခြင်း၊ မှတ်တမ်းတင်ခြင်းနှင့် စီမံခြင်း"</string>
+    <string name="permgroupdesc_phoneCalls" msgid="7489701620446183770">"ဖုန်းခေါ်ဆိုမှုများကို စောင့်ကြည့်စစ်ဆေးခြင်း၊ မှတ်တမ်းတင်ခြင်းနှင့် စီမံခြင်း"</string>
     <string name="permgrouplab_systemTools" msgid="4652191644082714048">"စစ်စတန်ကိရိယာများ"</string>
-    <string name="permgroupdesc_systemTools" msgid="8162102602190734305">"အဆင့်နိမ့်ဝင်ရောက်ကြည့်ခြင်းနှင့် စနစ်ကိုထိန်းချုပ်ခြင်း"</string>
+    <string name="permgroupdesc_systemTools" msgid="8162102602190734305">"အဆင့်နိမ့်ဝင်ရောက်ကြည့်ခြင်းနှင့် စနစ်ကိုထိန်းချုပ်ခြင်း"</string>
     <string name="permgrouplab_developmentTools" msgid="3446164584710596513">"ဖွံ့ဖိြုးတိုးတက်မှုဆိုင်ရာ ကိရိယာများ"</string>
-    <string name="permgroupdesc_developmentTools" msgid="7058828032358142018">"appကို တိုးတက်ပြုစုကြသူတို့သာ လိုအပ်နိုင်သည့် အင်္ဂါရပ်များ ဖြစ်သည်။"</string>
+    <string name="permgroupdesc_developmentTools" msgid="7058828032358142018">"appကို တိုးတက်ပြုစုကြသူတို့သာ လိုအပ်နိုင်သည့် အင်္ဂါရပ်များ ဖြစ်သည်။"</string>
     <string name="permgrouplab_display" msgid="4279909676036402636">"တခြား အပလီကေးရှင်း အသွင်အပြင်"</string>
     <string name="permgroupdesc_display" msgid="6051002031933013714">"တခြားအပလီကေးရှင်းများရဲ့ အသွင်အပြင်ကို အကျိုးသက်ရောက်စေရန်"</string>
     <string name="permgrouplab_storage" msgid="1971118770546336966">"သိုလှောင်မှုများ"</string>
     <string name="permgroupdesc_storage" product="nosdcard" msgid="7442318502446874999">"USBအားချိတ်ဆက်ရန်"</string>
     <string name="permgroupdesc_storage" product="default" msgid="9203302214915355774">"SDကတ်အားချိတ်ဆက်ရန်"</string>
-    <string name="permgrouplab_accessibilityFeatures" msgid="7919025602283593907">"လွယ်ကူစွာ ရရှိနိုင်မှု ပေးသော စွမ်းရည်"</string>
+    <string name="permgrouplab_accessibilityFeatures" msgid="7919025602283593907">"အများသုံးစွဲနိုင်မှု စွမ်းရည်"</string>
     <string name="permgroupdesc_accessibilityFeatures" msgid="4205196881678144335">"ကူညီပေးမှု နည်းပညာများမှ တောင်းဆိုနိုင်သော ထူးခြားချက်များ"</string>
     <string name="capability_title_canRetrieveWindowContent" msgid="3901717936930170320">"ဝင်းဒိုးမှာပါရှိသည်များကို ထုတ်ယူခြင်း"</string>
     <string name="capability_desc_canRetrieveWindowContent" msgid="3772225008605310672">"သင် အပြန်အလှန်လုပ်နေသော ဝင်းဒိုးမှာပါရှိသည်များကို သေချာစွာ ကြည့်ရှုစစ်ဆေးပါ"</string>
     <string name="capability_title_canRequestTouchExploration" msgid="3108723364676667320">"ထိတို့ခြင်းဖြင့် ရှာဖွေပေးနိုင်တာကို ဖွင့်လိုက်ပါ"</string>
     <string name="capability_desc_canRequestTouchExploration" msgid="5800552516779249356">"ထိတွေ့လိုက်တဲ့ အရာများကို အသံနဲ့ ထုတ်ပြောမှာဖြစ်ပြီး ဖန်သားပြင်ပေါကနေ လက်နဲ့ ထပ်မံ ကြည့်ရှုနိုင်ပါတယ်"</string>
-    <string name="capability_title_canRequestEnhancedWebAccessibility" msgid="1739881766522594073">"ဝက်ဘ် လွယ်ကူစွာ အသုံးပြုနိုင်မှု စွမ်းရည် မြှင့်တင်ခြင်းကို ဖွင့်ရန်"</string>
+    <string name="capability_title_canRequestEnhancedWebAccessibility" msgid="1739881766522594073">"ပိုမိုကောင်းမွန်သော ဝက်ဘ်အများသုံးစွဲနိုင်မှုကို ဖွင့်ရန်"</string>
     <string name="capability_desc_canRequestEnhancedWebAccessibility" msgid="7881063961507511765">"အပလီကေးရှင်းကို ပိုမိုပြည့်စုံစေရန် စကရစ်များကို သွင်းနိုင်ပါတယ်"</string>
     <string name="capability_title_canRequestFilterKeyEvents" msgid="2103440391902412174">"ရိုက်သောစာများကို သေချာစွာ စစ်ဆေးပါ"</string>
     <string name="capability_desc_canRequestFilterKeyEvents" msgid="7463135292204152818">"အရေးကြီးသော ကိုယ်ရေးအချက်အလက်များဖြစ်တဲ့ ခရက်ဒစ်ကဒ်နံပါတ်များနှင့် စကားဝှက်များ ပါဝင်ပါတယ်."</string>
     <string name="permlab_statusBar" msgid="7417192629601890791">"အခြေအနေပြဘားအား အလုပ်မလုပ်ခိုင်းရန်သို့မဟုတ် မွမ်းမံရန်"</string>
-    <string name="permdesc_statusBar" msgid="8434669549504290975">"appအား အခြေအနေပြ ဘားကို ပိတ်ခွင့် သို့မဟတ် စနစ် အိုင်ကွန်များကို ထည့်ခြင်း ဖယ်ရှားခြင်း ပြုလုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_statusBar" msgid="8434669549504290975">"appအား အခြေအနေပြ ဘားကို ပိတ်ခွင့် သို့မဟတ် စနစ် အိုင်ကွန်များကို ထည့်ခြင်း ဖယ်ရှားခြင်း ပြုလုပ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_statusBarService" msgid="7247281911387931485">"အခြေအနေပြနေရာ"</string>
-    <string name="permdesc_statusBarService" msgid="716113660795976060">"appအား အခြေအနေပြ ဘားဖြစ်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_expandStatusBar" msgid="1148198785937489264">"အခြေအနေပြဘားအား ချဲ့/ပြန့်ခြင်း"</string>
-    <string name="permdesc_expandStatusBar" msgid="6917549437129401132">"appအား အခြေအနေပြ ဘားကို ချဲ့ခွင့် သို့မဟုတ် ခေါက်သိမ်းခွင့် ပြုသည်။"</string>
+    <string name="permdesc_statusBarService" msgid="716113660795976060">"appအား အခြေအနေပြ ဘားဖြစ်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_expandStatusBar" msgid="1148198785937489264">"အခြေအနေပြဘားအား ချဲ့/ပြန့်ခြင်း"</string>
+    <string name="permdesc_expandStatusBar" msgid="6917549437129401132">"appအား အခြေအနေပြ ဘားကို ချဲ့ခွင့် သို့မဟုတ် ခေါက်သိမ်းခွင့် ပြုသည်။"</string>
     <string name="permlab_install_shortcut" msgid="4279070216371564234">"အတိုကောက်များအား ထည့်သွင်းခြင်း"</string>
     <string name="permdesc_install_shortcut" msgid="8341295916286736996">"အပလီကေးရှင်းအား အသုံးပြုသူ လုပ်ဆောင်ခြင်း မပါပဲ ပင်မ မြင်ကွင်းအား ပြောင်းလဲခွင့် ပေးခြင်း"</string>
     <string name="permlab_uninstall_shortcut" msgid="4729634524044003699">"အတိုကောက်များ ဖယ်ထုတ်ခြင်း"</string>
     <string name="permdesc_uninstall_shortcut" msgid="6745743474265057975">"အပလီကေးရှင်းအား အသုံးပြုသူ လုပ်ဆောင်ခြင်း မပါပဲ ပင်မ မြင်ကွင်းအား ဖယ်ရှားခွင့် ပေးခြင်း"</string>
     <string name="permlab_processOutgoingCalls" msgid="3906007831192990946">"အထွက် ခေါ်ဆိုမှုများအား လမ်းလွှဲပြောင်းခြင်း"</string>
-    <string name="permdesc_processOutgoingCalls" msgid="5156385005547315876">"appအား အပြင်သို့ ဖုန်းခေါ်ဆိုမှု အတွင်းမှာ ဆက်ခဲ့သည့် နံပါတ်ကို ကြည့်နိုင်ကာ ခေါ်ဆိုမှုကို အခြား နံပါတ် တစ်ခုသို့ ပြောင်းလဲပစ်ခြင်း သို့မဟုတ် ခေါ်ဆိုမှုကို လုံးဝ ဖျက်သိမ်းခွင့် ပြုသည်။"</string>
+    <string name="permdesc_processOutgoingCalls" msgid="5156385005547315876">"appအား အပြင်သို့ ဖုန်းခေါ်ဆိုမှု အတွင်းမှာ ဆက်ခဲ့သည့် နံပါတ်ကို ကြည့်နိုင်ကာ ခေါ်ဆိုမှုကို အခြား နံပါတ် တစ်ခုသို့ ပြောင်းလဲပစ်ခြင်း သို့မဟုတ် ခေါ်ဆိုမှုကို လုံးဝ ဖျက်သိမ်းခွင့် ပြုသည်။"</string>
     <string name="permlab_receiveSms" msgid="8673471768947895082">"စာပို့ခြင်းအား လက်ခံရယူခြင်း (စာတိုစနစ်)"</string>
-    <string name="permdesc_receiveSms" msgid="6424387754228766939">"အပလီကေးရှင်းအား စာတိုများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
+    <string name="permdesc_receiveSms" msgid="6424387754228766939">"အပလီကေးရှင်းအား စာတိုများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
     <string name="permlab_receiveMms" msgid="1821317344668257098">"စာပို့ခြင်းအား လက်ခံရယူခြင်း (ရုပ်သံစာ)"</string>
-    <string name="permdesc_receiveMms" msgid="533019437263212260">"အပလီကေးရှင်းအား ရုပ်သံစာများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
-    <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"အရေးပေါ်ထုတ်လွှင့်မှုများ လက်ခံခြင်း"</string>
-    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"appအား အရေးပေါ် ထုတ်လွှင့်သည့် စာများကို လက်ခံလျက် စီမံဆောင်ရွက်ခွင့် ပြုသည်။ ယင်း ခွင့်ပြုချက်မှာ စနစ် appများ အတွက်သာ ဖြစ်သည်။"</string>
+    <string name="permdesc_receiveMms" msgid="533019437263212260">"အပလီကေးရှင်းအား ရုပ်သံစာများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
+    <string name="permlab_receiveEmergencyBroadcast" msgid="1803477660846288089">"အရေးပေါ်ထုတ်လွှင့်မှုများ လက်ခံခြင်း"</string>
+    <string name="permdesc_receiveEmergencyBroadcast" msgid="848524070262431974">"appအား အရေးပေါ် ထုတ်လွှင့်သည့် စာများကို လက်ခံလျက် စီမံဆောင်ရွက်ခွင့် ပြုသည်။ ယင်း ခွင့်ပြုချက်မှာ စနစ် appများ အတွက်သာ ဖြစ်သည်။"</string>
     <string name="permlab_readCellBroadcasts" msgid="1598328843619646166">"စာတိုများ ဖြန့်ဝေခြင်းစနစ်အား ဖတ်ခြင်း"</string>
     <string name="permdesc_readCellBroadcasts" msgid="6361972776080458979">"အပလီကေးရှင်းကို သင်၏ စက်ပစ္စည်းမှ လက်ခံရရှိသော အများလွှင့်ထုတ်ချက်များကို ဖတ်ရန် ခွင့်ပြုသည်။  အများလွှင့်ထုတ်ချက်များသည် အရေးပေါ်အခြေအနေများကို သင့်အား သတိပေးရန် အချို့ နေရာများတွင် ပို့ပေးသည်။ အရေးပေါ်သတိပေးချက် ထုတ်လွှင့်ချက်ကို လက်ခံရရှိချိန်တွင်အန္တရာယ် ဖြစ်စေနိုင်သော အပလီကေးရှင်းများသည် သင့်စက်ပစ္စည်း၏ လုပ်ငန်းလည်ပတ်မှုနှင့် စွမ်းဆောင်မှုကို ဝင်စွက်ဖက်နိုင်သည်။"</string>
-    <string name="permlab_sendSms" msgid="5600830612147671529">"စာတိုပို့စနစ်(SMS)ဖြင့် စာများ ပို့သည်"</string>
+    <string name="permlab_sendSms" msgid="5600830612147671529">"စာတိုပို့စနစ်(SMS)ဖြင့် စာများ ပို့သည်"</string>
     <string name="permdesc_sendSms" msgid="7094729298204937667">"အပလီကေးရှင်းအား စာတိုပို့ခွင့် ပြုပါ။ မမျှော်လင့်သော ကုန်ကျမှု ဖြစ်နိုင်ပါသည်။ အန္တရာယ်ရှိ အပလီကေးရှင်းများမှ သင် မသိပဲ စာပို့ခြင်းများ ပြုလုပ်ခြင်းကြောင့် ပိုက်ဆံ အပို ကုန်စေနိုင်သည်"</string>
     <string name="permlab_sendRespondViaMessageRequest" msgid="8713889105305943200">"စာပြန်မှုခြင်း အသိပေးခြင်း များ ပြုလုပ်ခြင်း"</string>
     <string name="permdesc_sendRespondViaMessageRequest" msgid="7107648548468778734">"အပလီကေးရှင်းအား တခြား စာအပြန်အလှန် ပို့ဆောင်မှု ပေးသော အပလီကေးရှင်းများဆီကို ဖုန်းခေါ်ဆိုမှု များအတွက် စာပို့ခြင်းဖြင့် ပြန်လည် ဖြေဆိုသော တောင်းဆိုမှု များ ခွင့်ပြုခြင်း"</string>
@@ -292,16 +292,16 @@
     <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"အပလီကေးရှင်းအား တက်ဘလက် သို့မဟုတ် ဆင်းမ်ကဒ်မှာ သိမ်းဆည်းထားသော စာတိုများ ဖတ်ရှုခွင့်ပြုပါ။ အပလီကေးရှင်းအနေဖြင့် အကြာင်းအရာ သို့မဟုတ် ယုံကြည်စိတ်ချရမှုကို ဂရုမပြုပဲ စာတိုအားလုံးကို ဖတ်နိုင်ပါလိမ်မည်။"</string>
     <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"အပလီကေးရှင်းအား ဖုန်း သို့မဟုတ် ဆင်းမ်ကဒ်မှာ သိမ်းဆည်းထားသော စာတိုများ ဖတ်ရှုခွင့်ပြုပါ။ အပလီကေးရှင်းအနေဖြင့် အကြာင်းအရာ သို့မဟုတ် ယုံကြည်စိတ်ချရမှုကို ဂရုမပြုပဲ စာတိုအားလုံးကို ဖတ်နိုင်ပါလိမ်မည်။"</string>
     <string name="permlab_writeSms" msgid="3216950472636214774">"သင့်ရဲ့ စာပေးပို့ခြင်းများ ပြင်ခြင်း (စာတို နှင့် ရုပ်သံစာ)"</string>
-    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"appအား သင်၏ တက်ဘလက် သို့မဟုတ် ဆင်းမ်ကဒ်ထဲမှာ သိုလှောင်ထားသည့် စာတိုများသို့ ရေးခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စာတိုမျာကို ဖျက်ပစ်နိုင်သည်။"</string>
-    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"appအား သင်၏ ဖုန်း သို့မဟုတ် ဆင်းမ်ကဒ်ထဲမှာ သိုလှောင်ထားသည့် စာတိုများသို့ ရေးခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စာတိုမျာကို ဖျက်ပစ်နိုင်သည်။"</string>
+    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"appအား သင်၏ တက်ဘလက် သို့မဟုတ် ဆင်းမ်ကဒ်ထဲမှာ သိုလှောင်ထားသည့် စာတိုများသို့ ရေးခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စာတိုမျာကို ဖျက်ပစ်နိုင်သည်။"</string>
+    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"appအား သင်၏ ဖုန်း သို့မဟုတ် ဆင်းမ်ကဒ်ထဲမှာ သိုလှောင်ထားသည့် စာတိုများသို့ ရေးခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စာတိုမျာကို ဖျက်ပစ်နိုင်သည်။"</string>
     <string name="permlab_receiveWapPush" msgid="5991398711936590410">"စာပို့ခြင်းအား လက်ခံရယူခြင်း (WAP)"</string>
-    <string name="permdesc_receiveWapPush" msgid="748232190220583385">"အပလီကေးရှင်းအား WAP စာများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
+    <string name="permdesc_receiveWapPush" msgid="748232190220583385">"အပလီကေးရှင်းအား WAP စာများ လက်ခံခြင်း၊ ဆောင်ရွက်ခြင်း ခွင့်ပြုပါ။ ဤခွင့်ပြုချက်တွင် အပလီကေးရှင်းအနေဖြင့် သင် လက်ခံရရှိသော စာများအား သင့်အား မပြပဲစောင့်ကြည့်ခွင့်နှင့် ဖျက်ပစ်ခွင့်များ ပါဝင်ပါသည်။"</string>
     <string name="permlab_receiveBluetoothMap" msgid="7593811487142360528">"Bluetooth စာများလက်ခံမည် (MAP)"</string>
     <string name="permdesc_receiveBluetoothMap" msgid="8656755936919466345">"Bluetooth MAP စာများကို app မှလက်ခံကာ အလုပ်လုပ်ရန် ခွင့်ပြင်မည်။ ဆိုလိုသည်မှာ app သည်သင့်အား မပြသဘဲ သင့်ကိရိယာသို့ပို့လိုက်သည့် စာများကို ထိန်းချုပ်နိုင် သို့မဟုတ် ဖျက်နိုင်ပါသည်။"</string>
-    <string name="permlab_getTasks" msgid="6466095396623933906">"အလုပ်လုပ်နေကြသည့် appများကို ရယူခြင်း"</string>
+    <string name="permlab_getTasks" msgid="6466095396623933906">"အလုပ်လုပ်နေကြသည့် appများကို ရယူခြင်း"</string>
     <string name="permdesc_getTasks" msgid="7454215995847658102">"အပလီကေးရှင်းအား လက်ရှိနဲ့ လတ်တလော လုပ်ဆောင်ခဲ့သော သတင်းအချက်အလက် အသေးစိတ်အား ထုတ်ယူခွင့်ပြုရန်။ အပလီကေးရှင်းမှ သင် ဘယ် အပလီကေးရှင်းများသုံးရှိကြောင့် တွေ့ရှိနိုင်ပါသည်"</string>
     <string name="permlab_startTasksFromRecents" msgid="8990073877885690623">"မကြာမီ ထဲက တာဝန် တစ်ခုကို စတင်ရန်"</string>
-    <string name="permdesc_startTasksFromRecents" msgid="7382133554871222235">"appအား တက်ကြွမန်နေဂျာ။မကြာမီတာဝန်အင်ဖို အရာကို သုံးပြီး တက်ကြွမန်နေဂျာ။မကြာမီတာဝန်စာရင်းရယူ() ထံမှ ပြန်လာခဲ့သည့် ရပ်စဲခံလိုက်ရသည့် တာဝန်ကို ဖွင့်တင်ရန် အတွက် သုံးခွင့်ပြုသည်။"</string>
+    <string name="permdesc_startTasksFromRecents" msgid="7382133554871222235">"appအား တက်ကြွမန်နေဂျာ။မကြာမီတာဝန်အင်ဖို အရာကို သုံးပြီး တက်ကြွမန်နေဂျာ။မကြာမီတာဝန်စာရင်းရယူ() ထံမှ ပြန်လာခဲ့သည့် ရပ်စဲခံလိုက်ရသည့် တာဝန်ကို ဖွင့်တင်ရန် အတွက် သုံးခွင့်ပြုသည်။"</string>
     <string name="permlab_interactAcrossUsers" msgid="7114255281944211682">"အသုံးပြုသူများအကြား ဆက်ဆံခြင်း"</string>
     <string name="permdesc_interactAcrossUsers" msgid="364670963623385786">"အပလီကေးရှင်းအား စက်ပေါ်ရှိ တစ်ယောက်ထက်ပိုသော အသုံးပြုသူများအတွက် လုပ်ဆောင်ချက်များ ပြုလုပ်ခွင့်ပေးပါ။ အန္တရာယ်ရှိသော အပလီကေးရှင်းများမှ ဒီအရာကို သုံးပြီး အသုံးပြုသူများအတွင်း ကာကွယ်မှုကို ဖောက်ဖျက်နိုင်ပါသည်"</string>
     <string name="permlab_interactAcrossUsersFull" msgid="2567734285545074105">"အသုံးပြုသူများအကြား ဆက်ဆံရန် လိုင်စင် အပြည့်"</string>
@@ -310,9 +310,9 @@
     <string name="permdesc_manageUsers" msgid="8409306667645355638">"အပလီကေးရှင်းအား အသုံးပြုသူများကို စီမံခန့်ခွဲခွင့် ပေးပါ။ ဥပမာ ကြည့်ရှုခြင်း၊ အသစ်ပြုလုပ်ခြင်း၊ ဖျက်စီးခြင်း"</string>
     <string name="permlab_getDetailedTasks" msgid="6229468674753529501">"သုံးနေသော အပလီကေးရှင်းများ၏ အချက်အလက် ရယူခြင်း"</string>
     <string name="permdesc_getDetailedTasks" msgid="153824741440717599">"အပလီကေးရှင်းအား လက်ရှိနဲ့ လတ်တလော လုပ်ဆောင်ခဲ့သော သတင်းအချက်အလက် အသေးစိတ်အား ထုတ်ယူခွင့်ပြုရန်။ အန္တရာယ်ရှိသော အပလီကေးရှင်းများမှ တခြား အပလီကေးရှင်းများရဲ့ အတွင်းကျသော သတင်းအချက်အလက်များအား တွေ့ရှိနိုင်ပါသည်။"</string>
-    <string name="permlab_reorderTasks" msgid="2018575526934422779">"အလုပ်လုပ်နေကြသည့် appများကို ပြန်လည်စီစဉ်ခြင်း"</string>
+    <string name="permlab_reorderTasks" msgid="2018575526934422779">"အလုပ်လုပ်နေကြသည့် appများကို ပြန်လည်စီစဉ်ခြင်း"</string>
     <string name="permdesc_reorderTasks" msgid="7734217754877439351">"အပလီကေးရှင်းအား နောက်ကွယ် နှင့် ရှေ့မှောက်တွင် လက်ရှိ လုပ်ဆောင်နေမှုများအား ဖယ်ခွင့် ပြုပါ။ သင့် ခွင့်ပြုချက်မပါပဲ လုပ်ဆောင်နိုင်ပါလိမ့်မည်"</string>
-    <string name="permlab_removeTasks" msgid="6821513401870377403">"အလုပ်လုပ်နေကြသည့် appများကို ရပ်ခြင်း"</string>
+    <string name="permlab_removeTasks" msgid="6821513401870377403">"အလုပ်လုပ်နေကြသည့် appများကို ရပ်ခြင်း"</string>
     <string name="permdesc_removeTasks" msgid="1394714352062635493">"အပလီကေးရှင်းအား စက်မှ လက်ရှိလုပ်ဆောင်နေမှုများအား ဖယ်ရှားခြင်းနှင့် ၎င်းတို့၏ အပလီကေးရှင်းများအား ရပ်တန့်စေရန် လုပ်ခွင့်ပြုပါ။ အန္တရာယ်ရှိ အပလီကေးရှင်းများက တခြား အပလီကေးရှင်းများ၏ အပြုအမူအား ဒုက္ခပေးနိုင်ပါသည်"</string>
     <string name="permlab_manageActivityStacks" msgid="7391191384027303065">"လုပ်ဆောင်မှု စာရင်းများအား ထိန်းသိမ်းခြင်း"</string>
     <string name="permdesc_manageActivityStacks" msgid="1615881933034084440">"အပလီကေးရှင်းအား တခြားအပလီကေးရှင်းများမှ လုပ်ဆောင်ချက်များအား ထပ်ထည့်ခွင့်၊ ဖယ်ခွင့်၊ ပြင်ဆင်ခွင့် ပေးခြင်း။ စိတ်ချရမှု မရှိသော အပလီကေးရှင်းဆိုလျှင် တခြား အပလီကေးရှင်းများရဲ့ လုပ်ငန်းဆောင်ရွက်ချက်များအား မှားယွင်းစေနိုင်ပါသည်"</string>
@@ -320,48 +320,48 @@
     <string name="permdesc_startAnyActivity" msgid="997823695343584001">"ခွင့်ပြုချက်ကာကွယ်ခြင်း၊ သို့ အပြင်သို့ ထုတ်နိုင်မှု အခြေအနေများ မည်သို့ပင်ဖြစ်စေကာမူ အပလီကေးရှင်းအား လှုပ်ရှားမှုများအား စတင်ရန် ခွင့်ပြုပါ"</string>
     <string name="permlab_setScreenCompatibility" msgid="6975387118861842061">"ဖန်သားပြင်နှင့် လိုက်ဖက်မှုကို သတ်မှတ်ရန်"</string>
     <string name="permdesc_setScreenCompatibility" msgid="692043618693917374">"အပလီကေးရှင်းအား တခြား အပလီကေးရှင်းများ ဖန်သားပြင် ပြသမှုအား ထိန်းချုပ်ခွင့်ပြုပါ။ အန္တရာယ်ရှိ အပလီကေးရှင်းများက တခြားအပလီကေးရှင်းများ ဒုက္ခပေးနိုင်ပါသည်"</string>
-    <string name="permlab_setDebugApp" msgid="3022107198686584052">"app ဒီဘာဂင် ဖွင့်ပေးခြင်း"</string>
+    <string name="permlab_setDebugApp" msgid="3022107198686584052">"app ဒီဘာဂင် ဖွင့်ပေးခြင်း"</string>
     <string name="permdesc_setDebugApp" msgid="4474512416299013256">"အပလီကေးရှင်းအား တခြား အပလီကေးရှင်းအတွက် အမှားရှာဖွေပြင်ဆင်ခြင်း ခွင့်ပြုပါ။ အန္တရာယ်ရှိ အပလီကေးရှင်း ဒီခွင့်ပြုချက်အား သုံးပြီး တခြားအပလီကေးရှင်းအား ရပ်ပစ်နိုင်ပါသည်"</string>
     <string name="permlab_changeConfiguration" msgid="4162092185124234480">"စနစ် ပြသမှုဆက်တင်များပြင်ရန်"</string>
     <string name="permdesc_changeConfiguration" msgid="4372223873154296076">"အပလီကေးရှင်းအား လက်ရှိ အပြင်အဆင် ဥပမာ ဘာသာစကား၊ စာလုံးအကြီးအသေး များ ပြင်ခွင့် ပြုရန်"</string>
     <string name="permlab_enableCarMode" msgid="5684504058192921098">"ကားမောင်းနေစဥ်စနစ်အား ရရှိစေခြင်း"</string>
-    <string name="permdesc_enableCarMode" msgid="4853187425751419467">"appအား ကား မုဒ် ဖွင့်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_enableCarMode" msgid="4853187425751419467">"appအား ကား မုဒ် ဖွင့်ခွင့် ပြုသည်။"</string>
     <string name="permlab_killBackgroundProcesses" msgid="3914026687420177202">"အခြား အပလီကေးရှင်းများအား ပိတ်ရန်"</string>
     <string name="permdesc_killBackgroundProcesses" msgid="4593353235959733119">"အပလီကေးရှင်းအား နောက်ကွယ်တွင် ဖွင့်ထားသော အခြားအပလီကေးရှင်းများရဲ့ လုပ်ဆောင်မှုများအား ရပ်ခွင့်ပေးပါ။ ဒီလိုလုပ်ခြင်းဖြင့် အခြား အပလီကေးရှင်းများ ရပ်တန့်သွားနိုင်ပါသည်"</string>
     <string name="permlab_forceStopPackages" msgid="2329627428832067700">"အခြား appများ ရပ်ပစ်ရန် အကြပ်ကိုင်ခြင်း"</string>
-    <string name="permdesc_forceStopPackages" msgid="5253157296183940812">"appအား အခြား appများ၏ အလုပ်ကို အတင်းအကြပ် ရပ်ပစ်ခွင့် ရှိသည်။"</string>
+    <string name="permdesc_forceStopPackages" msgid="5253157296183940812">"appအား အခြား appများ၏ အလုပ်ကို အတင်းအကြပ် ရပ်ပစ်ခွင့် ရှိသည်။"</string>
     <string name="permlab_forceBack" msgid="652935204072584616">"appကို ပိတ်သွားရန် အကြပ်ကိုင်ခြင်း"</string>
-    <string name="permdesc_forceBack" msgid="3892295830419513623">"appအား အရှေ့ပိုင်းမှ မည်သည့် လှုပ်ရှားမှုကို မဆို ပိတ်ခွင့် နှင့် နောက်ကို ပို့ခွင့် ရှိသည်။ သာမန် appများ ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_forceBack" msgid="3892295830419513623">"appအား အရှေ့ပိုင်းမှ မည်သည့် လှုပ်ရှားမှုကို မဆို ပိတ်ခွင့် နှင့် နောက်ကို ပို့ခွင့် ရှိသည်။ သာမန် appများ ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_dump" msgid="1681799862438954752">"စနစ်၏စက်တွင်းအခြအေနေများထံ ပြန်ထုတ်ခြင်း"</string>
-    <string name="permdesc_dump" msgid="1778299088692290329">"appအား စနစ်၏ အတွင်းပိုင်း အခြေအနေကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများသည် ၎င်းတို့ အနေနှင့် ပုံမှန် ဘယ်တော့မှ မလိုအပ်သည့် ကိုယ်ရေး နှင့် လုံခြုံမှု အချက်အလက် အမျိုးမျိုးကို ရယူနိုင်ကြသည်။"</string>
+    <string name="permdesc_dump" msgid="1778299088692290329">"appအား စနစ်၏ အတွင်းပိုင်း အခြေအနေကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများသည် ၎င်းတို့ အနေနှင့် ပုံမှန် ဘယ်တော့မှ မလိုအပ်သည့် ကိုယ်ရေး နှင့် လုံခြုံမှု အချက်အလက် အမျိုးမျိုးကို ရယူနိုင်ကြသည်။"</string>
     <string name="permlab_retrieve_window_content" msgid="8022588608994589938">"ဖန်သားပြင်အကြောင်းအရာအားပြန်လည်ရယူရန်"</string>
-    <string name="permdesc_retrieve_window_content" msgid="3193269069469700265">"appအား တက်ကြွ ဝင်ဒိုး၏ အကြောင်းအရာကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများက ဝင်ဒိုး၏ အကြောင်းအရာ တစ်ခုလုံးကို ရယူနိုင်ပြီး စကားဝှက်မှ လွဲပြီး ၎င်းထဲက စာသား တစ်ခုလုံးကို ဆန်းစစ်နိုင်သည်။"</string>
+    <string name="permdesc_retrieve_window_content" msgid="3193269069469700265">"appအား တက်ကြွ ဝင်ဒိုး၏ အကြောင်းအရာကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများက ဝင်ဒိုး၏ အကြောင်းအရာ တစ်ခုလုံးကို ရယူနိုင်ပြီး စကားဝှက်မှ လွဲပြီး ၎င်းထဲက စာသား တစ်ခုလုံးကို ဆန်းစစ်နိုင်သည်။"</string>
     <string name="permlab_temporary_enable_accessibility" msgid="2312612135127310254">"ယာယီ ရယူခွင့် ပြုရန်"</string>
     <string name="permdesc_temporary_enable_accessibility" msgid="8079456293182975464">"အပလီကေးရှင်းအား စက်အား ခဏတာ အသုံးပြုခွင့်ပေးပါ။ အန္တရာယ်ရှိ အပလီကေးရှင်းများမှ သုံးစွဲသူ မသိပဲ ရယူခြင်း လုပ်နိုင်ပါသည်"</string>
     <string name="permlab_retrieveWindowToken" msgid="7154762602367758602">"ဝင်ဒိုး တိုကင်ကို ရယူခြင်း"</string>
-    <string name="permdesc_retrieveWindowToken" msgid="668173747687795074">"အပလီကေးရှင်း တစ်ခုအား ဝင်ဒိုး တိုကင်ကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများက စနစ်လို အယောင်ဆောင်ကာ အပလီကေးရှင်း ဝင်ဒိုးနှင့် ခွင့်မပြုထားသည့် တုံ့ပြန်မှုကို ပြုလုပ်နိုင်သည်။"</string>
+    <string name="permdesc_retrieveWindowToken" msgid="668173747687795074">"အပလီကေးရှင်း တစ်ခုအား ဝင်ဒိုး တိုကင်ကို ရယူခွင့် ပြုသည်။ ကြံဖန် appများက စနစ်လို အယောင်ဆောင်ကာ အပလီကေးရှင်း ဝင်ဒိုးနှင့် ခွင့်မပြုထားသည့် တုံ့ပြန်မှုကို ပြုလုပ်နိုင်သည်။"</string>
     <string name="permlab_frameStats" msgid="7056374987314361639">"ဘောင် စာရင်းအင်းများကို ရယူခြင်း"</string>
-    <string name="permdesc_frameStats" msgid="4758001089491284919">"အပလီကေးရှင်း တစ်ခုအား မူဘောင် စာရင်းအင်းများကို စုစည်းစေနိုင်သည်။ ကြံဖန် appများက ဝင်ဒိုး၏ မူဘောင် စာရင်းအင်းများကို အခြား appများမှ စောင့်ကြည့်နိုင်သည်။"</string>
+    <string name="permdesc_frameStats" msgid="4758001089491284919">"အပလီကေးရှင်း တစ်ခုအား မူဘောင် စာရင်းအင်းများကို စုစည်းစေနိုင်သည်။ ကြံဖန် appများက ဝင်ဒိုး၏ မူဘောင် စာရင်းအင်းများကို အခြား appများမှ စောင့်ကြည့်နိုင်သည်။"</string>
     <string name="permlab_filter_events" msgid="8675535648807427389">"အဖြစ်အပျက်များအား စစ်ထုတ်ခြင်း"</string>
     <string name="permdesc_filter_events" msgid="8006236315888347680">"အပလီကေးရှင်းအား သုံးစွဲသူ လုပ်ဆောင်မှုကို မပြုလုပ်ခင် စစ်ဆေးပေးသော input filter မှတ်ပုံတင်ခွင့်ပြုရန်၊ အန္တရယယ် ရှိသော အပလီကေးရှင်းများမှ သုံးစွဲသူ မသိပဲ စနစ်ပုံရိပ်ပြမှုအား ထိန်းချုပ်နိုင်ပါသည်"</string>
     <string name="permlab_shutdown" msgid="7185747824038909016">"တစိတ်တပိုင်းအားပိတ်ချရန်"</string>
-    <string name="permdesc_shutdown" msgid="7046500838746291775">"လုပ်ဆောင်မှုမန်နေဂျာကို ပိတ်ထားသည့်အခြေအနေတွင်ထားသည်။ အပြီးပိတ်ခြင်းအား မပြုလုပ်ပါ။"</string>
+    <string name="permdesc_shutdown" msgid="7046500838746291775">"လုပ်ဆောင်မှုမန်နေဂျာကို ပိတ်ထားသည့်အခြေအနေတွင်ထားသည်။ အပြီးပိတ်ခြင်းအား မပြုလုပ်ပါ။"</string>
     <string name="permlab_stopAppSwitches" msgid="4138608610717425573">"အပ်ပလီကေးရှင်းဖလှယ်ခြင်းမှ မဖြစ်စေရန်"</string>
-    <string name="permdesc_stopAppSwitches" msgid="8262195802582255021">"အသုံးပြုသူကို အခြား appသို့ ခလုတ် ပြောင်းမရအောင် ဟန့်တားသည်။"</string>
+    <string name="permdesc_stopAppSwitches" msgid="8262195802582255021">"အသုံးပြုသူကို အခြား appသို့ ခလုတ် ပြောင်းမရအောင် ဟန့်တားသည်။"</string>
     <string name="permlab_getTopActivityInfo" msgid="2537922311411546016">"အပလီကေးရှင်း အချက်အလက်များ ယူခြင်း"</string>
     <string name="permdesc_getTopActivityInfo" msgid="2512448855496067131">"ကိုင်ဆောင်ထားသူအား လက်ရှိ အပလီကေးရှင်းမှ လျို့ဝှက် အချက်အလက်များအား ထုတ်ယူကြည့်ခွင့်ပြုခြင်း"</string>
-    <string name="permlab_runSetActivityWatcher" msgid="892239094867182656">"app အားလုံး ဖွင့်တင်မှုကို စောင့်ကြည့်ခြင်း နှင့် ထိန်းချုပ်ခြင်း"</string>
-    <string name="permdesc_runSetActivityWatcher" msgid="6003603162578577406">"appအား စနစ်မှ လှုပ်ရှားမှုများကို ဖွင့်လှစ်စတင်ပုံကို စောင့်ကြည့်လျက် ထိန်းချုပ်ခွင့် ပြုသည်။ ကြံဖန် appများက စနစ်ကို လုံးဝ ဖျက်ဆီးပစ်နိုင်ကြသည်။ ယင်း ခွင့်ပြုချက်မှာ တိုးတက်အောင် ပြုစုရာမှာသာ လိုအပ်ပြီး၊ ပုံမှန် အသုံးပြုမှု အတွက် လုံးဝ မဟုတ်ပါ။"</string>
+    <string name="permlab_runSetActivityWatcher" msgid="892239094867182656">"app အားလုံး ဖွင့်တင်မှုကို စောင့်ကြည့်ခြင်း နှင့် ထိန်းချုပ်ခြင်း"</string>
+    <string name="permdesc_runSetActivityWatcher" msgid="6003603162578577406">"appအား စနစ်မှ လှုပ်ရှားမှုများကို ဖွင့်လှစ်စတင်ပုံကို စောင့်ကြည့်လျက် ထိန်းချုပ်ခွင့် ပြုသည်။ ကြံဖန် appများက စနစ်ကို လုံးဝ ဖျက်ဆီးပစ်နိုင်ကြသည်။ ယင်း ခွင့်ပြုချက်မှာ တိုးတက်အောင် ပြုစုရာမှာသာ လိုအပ်ပြီး၊ ပုံမှန် အသုံးပြုမှု အတွက် လုံးဝ မဟုတ်ပါ။"</string>
     <string name="permlab_broadcastPackageRemoved" msgid="2576333434893532475">"package ပယ်ဖျက်မှု ထုတ်လွှင့်မှုအား ပေးပို့ပါ"</string>
-    <string name="permdesc_broadcastPackageRemoved" msgid="6621901216207931089">"appအား app အထုပ် တစ်ခုကို ဖယ်ရှားပစ်လိုက်ကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို  အသုံးပြုပြီး အလုပ်လုပ်နေသည့် မည့်သည့် appကို မဆို သတ်ပစ်နိုင်သည်။"</string>
-    <string name="permlab_broadcastSmsReceived" msgid="5689095009030336593">"SMS-အားပို့ပြီး ထုတ်လွင့်မှုအားရယူခြင်း"</string>
-    <string name="permdesc_broadcastSmsReceived" msgid="4152037720034365492">"appအား SMS ရရှိထားကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး ဝင်လာကြသည့် SMS စာများကို အတုလုပ်နိုင်သည်။"</string>
-    <string name="permlab_broadcastWapPush" msgid="3145347413028582371">"WAP-PUSH-အားပို့ပြီး ထုတ်လွင့်မှုအားရယူခြင်း"</string>
-    <string name="permdesc_broadcastWapPush" msgid="4783402525039442729">"appအား WAP PUSH စာ ရရှိထားကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး ရရှိခဲ့သည့်MMS စာများကို လုပ်ကြံနိုင်သလို၊ မည်သည့် ဝက်ဘ် စာမျက်နှာ၏ အကြောင်းအရာကို မဆို လုပ်ကြံချက်များဖြင့် တိတ်တိတ်ပုန်း အစားထိုးနိုင်သည်။"</string>
-    <string name="permlab_setProcessLimit" msgid="2451873664363662666">"အလုပ်လုပ်နေသောလုပ်ငန်းစဥ်နှုန်းအား ကန့်သတ်ခြင်း"</string>
-    <string name="permdesc_setProcessLimit" msgid="7318061314040879542">"appအား အလုပ်လုပ်ကြမည့် လုပ်ငန်းစဉ်များ၏ အများဆုံး အရေအတွက်ကို ထိန်းချုပ်ခွင့် ပြုနိုင်သည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_broadcastPackageRemoved" msgid="6621901216207931089">"appအား app အထုပ် တစ်ခုကို ဖယ်ရှားပစ်လိုက်ကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို  အသုံးပြုပြီး အလုပ်လုပ်နေသည့် မည့်သည့် appကို မဆို သတ်ပစ်နိုင်သည်။"</string>
+    <string name="permlab_broadcastSmsReceived" msgid="5689095009030336593">"SMS-အားပို့ပြီး ထုတ်လွင့်မှုအားရယူခြင်း"</string>
+    <string name="permdesc_broadcastSmsReceived" msgid="4152037720034365492">"appအား SMS ရရှိထားကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး ဝင်လာကြသည့် SMS စာများကို အတုလုပ်နိုင်သည်။"</string>
+    <string name="permlab_broadcastWapPush" msgid="3145347413028582371">"WAP-PUSH-အားပို့ပြီး ထုတ်လွင့်မှုအားရယူခြင်း"</string>
+    <string name="permdesc_broadcastWapPush" msgid="4783402525039442729">"appအား WAP PUSH စာ ရရှိထားကြောင်း အကြောင်းကြားစာကို ထုတ်လွင့်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး ရရှိခဲ့သည့်MMS စာများကို လုပ်ကြံနိုင်သလို၊ မည်သည့် ဝက်ဘ် စာမျက်နှာ၏ အကြောင်းအရာကို မဆို လုပ်ကြံချက်များဖြင့် တိတ်တိတ်ပုန်း အစားထိုးနိုင်သည်။"</string>
+    <string name="permlab_setProcessLimit" msgid="2451873664363662666">"အလုပ်လုပ်နေသောလုပ်ငန်းစဥ်နှုန်းအား ကန့်သတ်ခြင်း"</string>
+    <string name="permdesc_setProcessLimit" msgid="7318061314040879542">"appအား အလုပ်လုပ်ကြမည့် လုပ်ငန်းစဉ်များ၏ အများဆုံး အရေအတွက်ကို ထိန်းချုပ်ခွင့် ပြုနိုင်သည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_setAlwaysFinish" msgid="550958507798796965">"နောက်ခံ အပလီကေးရှင်းအား မဖြစ်မနေပိတ်ရန်"</string>
-    <string name="permdesc_setAlwaysFinish" msgid="7471310652868841499">"appအား လှုပ်ရှားမှုများ နောက်ခံသို့ သွားကြသည့်နှင့် ပြီးဆုံးခြင်း ရှိမရှိကို အမြဲတမ်း ထိန်းချုပ်ခွင့် ရှိသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်ပါ။"</string>
+    <string name="permdesc_setAlwaysFinish" msgid="7471310652868841499">"appအား လှုပ်ရှားမှုများ နောက်ခံသို့ သွားကြသည့်နှင့် ပြီးဆုံးခြင်း ရှိမရှိကို အမြဲတမ်း ထိန်းချုပ်ခွင့် ရှိသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်ပါ။"</string>
     <string name="permlab_batteryStats" msgid="2789610673514103364">"ဘတ်ထရီ အခြေအနေအား ဖတ်ရန်"</string>
     <string name="permdesc_batteryStats" msgid="5897346582882915114">"အပလီကေးရှင်းအား အနိမ့်ပိုင်း စက် အချက်အလက် ဘက်ထရီ အခြေအနေကို ကြည့်ခွင့်ပြုပါ။ အပလီကေးရှင်းမှ သင် အသုံးပြုသော အပလီကေးရှင်းများ၏ အသေးစိတ် သတင်းအချက်အလက်များကို ရှာဖွေရန် ခွင့်ပြုပါ။"</string>
     <string name="permlab_updateBatteryStats" msgid="3719689764536379557">"ဘက်ထရီ အချက်အလက်အား ပြင်ရန်"</string>
@@ -370,27 +370,27 @@
     <string name="permdesc_getAppOpsStats" msgid="6243887041577912877">"အပလီကေးရှင်းကို အပလီကေးရှင်း အသုံးပြုမှု အချက်အလက် စာရင်းများအား ယူသုံးခွင့် ပြုခြင်း။ ပုံမှန် အပလီကေးရှင်းများအတွက် မဟုတ်ပါ"</string>
     <string name="permlab_updateAppOpsStats" msgid="8829097373851521505">"အပလီကေးရှင်း အသုံးပြုမှုအား ပြင်ဆင်ခြင်း"</string>
     <string name="permdesc_updateAppOpsStats" msgid="50784596594403483">"အပလီကေးရှင်းကို အပလီကေးရှင်း အသုံးပြုမှု အချက်အလက် စာရင်းများအား ပြောင်းလဲခွင့် ပြုခြင်း။ ပုံမှန် အပလီကေးရှင်းများအတွက် မဟုတ်ပါ"</string>
-    <string name="permlab_backup" msgid="470013022865453920">"စနစ်အရန်သိမ်းဆည်းမှုနှင့် ပြန်လည်ရယူရန် ထိန်းချုပ်ခြင်း"</string>
-    <string name="permdesc_backup" msgid="6912230525140589891">"appအား စနစ်၏ ဘက်အာပ် နှင့် ပြန်လည် ဖေါ်ထုတ်ရေး ယန္တရားကို ထိန်းချုပ်ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
-    <string name="permlab_confirm_full_backup" msgid="5557071325804469102">"အပြည့်အဝအရန်သိမ်းဆည်းရန် သို့မဟုတ် ပြန်လည်ရယူခြင်းအောက်ပရေးရှင်းအား အတည်ပြုရန်"</string>
-    <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"appအား ဘက်အာပ် အတည်ပြုရေး UI အပြည့်အဝကို ဖွင့်တင်ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
-    <string name="permlab_internalSystemWindow" msgid="2148563628140193231">"ခွင့်မပြုထားသောဝင်ဒိုးမျာကို ဖော်ပြခြင်း"</string>
+    <string name="permlab_backup" msgid="470013022865453920">"စနစ်အရန်သိမ်းဆည်းမှုနှင့် ပြန်လည်ရယူရန် ထိန်းချုပ်ခြင်း"</string>
+    <string name="permdesc_backup" msgid="6912230525140589891">"appအား စနစ်၏ ဘက်အာပ် နှင့် ပြန်လည် ဖေါ်ထုတ်ရေး ယန္တရားကို ထိန်းချုပ်ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
+    <string name="permlab_confirm_full_backup" msgid="5557071325804469102">"အပြည့်အဝအရန်သိမ်းဆည်းရန် သို့မဟုတ် ပြန်လည်ရယူခြင်းအောက်ပရေးရှင်းအား အတည်ပြုရန်"</string>
+    <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"appအား ဘက်အာပ် အတည်ပြုရေး UI အပြည့်အဝကို ဖွင့်တင်ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
+    <string name="permlab_internalSystemWindow" msgid="2148563628140193231">"ခွင့်မပြုထားသောဝင်ဒိုးမျာကို ဖော်ပြခြင်း"</string>
     <string name="permdesc_internalSystemWindow" msgid="7458387759461466397">"အပလီကေးရှင်း အတွင်းပိုင်းစနစ်သာ သုံးရန်သင့်သော ဝင်းဒိုးများ တည်ဆောက်ခွင့် ပြုပါ။ ပုံမှန် အပလီကေးရှင်းများအတွက် မရည်ရွယ်ပါ"</string>
     <string name="permlab_systemAlertWindow" msgid="3543347980839518613">"တခြား အပလီကေးရှင်းပေါ်တွင် ထပ်ဆွဲရန်"</string>
     <string name="permdesc_systemAlertWindow" msgid="8584678381972820118">"အပလီကေးရှင်းအား အခြားအပလီကေးရှင်းများ သို့ တခြား အသုံးပြုသူ မြင်ရသော နေရာများပေါ်တွင် ထပ်၍ ရေးဆွဲခွင့် ပေးသည်။ ဒီခွင့်ပြုမှုဟာ သင် အပလီကေးရှင်းများနဲ့ အသုံးပြုရန် စီစဉ်ထားမှု သို့ သင် မြင်ရသောမြင်ကွင်းအား ပြောင်းလဲမှု ဖြစ်စေနိုင်သည်"</string>
     <string name="permlab_setAnimationScale" msgid="2805103241153907174">"တကမ္ဘာလုံးဆိုင်ရာ လှုပ်ရှားသက်ဝင်နှုန်းမွမ်းမံခြင်း"</string>
     <string name="permdesc_setAnimationScale" msgid="7690063428924343571">"အပလီကေးရှင်းအား စက်တစ်ခုလုံးနှင့်ဆိုင်သော သရုပ်ပြမှု အနှေး အမြန် နှုန်း အား အချိန်မရွေး ပြောင်းခွင့်ပြုပါ"</string>
     <string name="permlab_manageAppTokens" msgid="1286505717050121370">"app တိုကင်များကို စီမံကွပ်ကဲခြင်း"</string>
-    <string name="permdesc_manageAppTokens" msgid="8043431713014395671">"appအား၊ ၎င်းတို့၏ ပုံမှန် Z-အော်ဒါပေးမှုကို ကျော်လွှားပြီး၊  ၎င်းတို့၏ ကိုယ်ပိုင် တိုကင်များကို ဖန်တီးရန် နှင့် စီမံကွပ်ကဲခွင့်ကို ပြုသည်။ သာမန် appများ အတွက ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_manageAppTokens" msgid="8043431713014395671">"appအား၊ ၎င်းတို့၏ ပုံမှန် Z-အော်ဒါပေးမှုကို ကျော်လွှားပြီး၊  ၎င်းတို့၏ ကိုယ်ပိုင် တိုကင်များကို ဖန်တီးရန် နှင့် စီမံကွပ်ကဲခွင့်ကို ပြုသည်။ သာမန် appများ အတွက ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_freezeScreen" msgid="4708181184441880175">"ဖန်သားပြင်အား ရပ်တန့်စေခြင်း"</string>
     <string name="permdesc_freezeScreen" msgid="8558923789222670064">"အပလီကေးရှင်းအား ဖန်သားပြည့် ပြသမှုအတွက် ပြောင်းလဲစဉ် ဖန်သားပြင်အား ခဏရပ်ခွင့်ပြုရန်"</string>
-    <string name="permlab_injectEvents" msgid="1378746584023586600">"ခလုတ်များနှင့် ထိန်းချုပ်သည့်ခလုတ်များကို နှိပ်ခြင်း"</string>
-    <string name="permdesc_injectEvents" product="tablet" msgid="206352565599968632">"appအား ၎င်းကိုယ်နှိုက်၏ ထည့်သွင်းမှုများ (ခလုတ် နှိပ်မှုများ၊ စသဖြင့်)ကို ထည့်ပေးခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး တက်ဘလက်၏ နေရာကို ရယူနိုင်သည်။"</string>
-    <string name="permdesc_injectEvents" product="default" msgid="653128057572326253">"appအား ၎င်းကိုယ်နှိုက်၏ ထည့်သွင်းမှုများ (ခလုတ် နှိပ်မှုများ၊ စသဖြင့်)ကို ထည့်ပေးခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး ဖုန်း၏ နေရာကို ရယူနိုင်သည်။"</string>
-    <string name="permlab_readInputState" msgid="469428900041249234">"သင်မည်သည်ကိုရိုက်သွင်းသည်နှင့် လှုပ်ရှားမှုများကို မှတ်တမ်းတင်ခြင်း"</string>
-    <string name="permdesc_readInputState" msgid="8387754901688728043">"appအား သင် နှိပ်သည့် ခလုတ်များကို၊ သင်က အခြား app တစ်ခုနှင့် (စကားဝှက် ရိုက်ထည့်မှုလို) အပြန်အလှန် တုံ့ပြန်နေချိန်မှာတောင်၊ စောင့်ကြည့်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_bindInputMethod" msgid="3360064620230515776">"ထည့်သွင်းရန်နည်းလမ်းအား ဆက်ရန်"</string>
-    <string name="permdesc_bindInputMethod" msgid="3250440322807286331">"စွဲကိုင်ထားသူအား ရိုက်ထည့်ရေး နည်းလမ်း၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_injectEvents" msgid="1378746584023586600">"ခလုတ်များနှင့် ထိန်းချုပ်သည့်ခလုတ်များကို နှိပ်ခြင်း"</string>
+    <string name="permdesc_injectEvents" product="tablet" msgid="206352565599968632">"appအား ၎င်းကိုယ်နှိုက်၏ ထည့်သွင်းမှုများ (ခလုတ် နှိပ်မှုများ၊ စသဖြင့်)ကို ထည့်ပေးခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး တက်ဘလက်၏ နေရာကို ရယူနိုင်သည်။"</string>
+    <string name="permdesc_injectEvents" product="default" msgid="653128057572326253">"appအား ၎င်းကိုယ်နှိုက်၏ ထည့်သွင်းမှုများ (ခလုတ် နှိပ်မှုများ၊ စသဖြင့်)ကို ထည့်ပေးခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး ဖုန်း၏ နေရာကို ရယူနိုင်သည်။"</string>
+    <string name="permlab_readInputState" msgid="469428900041249234">"သင်မည်သည်ကိုရိုက်သွင်းသည်နှင့် လှုပ်ရှားမှုများကို မှတ်တမ်းတင်ခြင်း"</string>
+    <string name="permdesc_readInputState" msgid="8387754901688728043">"appအား သင် နှိပ်သည့် ခလုတ်များကို၊ သင်က အခြား app တစ်ခုနှင့် (စကားဝှက် ရိုက်ထည့်မှုလို) အပြန်အလှန် တုံ့ပြန်နေချိန်မှာတောင်၊ စောင့်ကြည့်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_bindInputMethod" msgid="3360064620230515776">"ထည့်သွင်းရန်နည်းလမ်းအား ဆက်ရန်"</string>
+    <string name="permdesc_bindInputMethod" msgid="3250440322807286331">"စွဲကိုင်ထားသူအား ရိုက်ထည့်ရေး နည်းလမ်း၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_bindAccessibilityService" msgid="5357733942556031593">"အသုံးပြုမှု ပေးနိုင်သော ဆားဗစ်တစ်ခုနှင့် ပူးပေါင်းမှု ပြုရန်"</string>
     <string name="permdesc_bindAccessibilityService" msgid="7034615928609331368">"ဖုန်းကိုင်ထားသူနဲ့ ရယူခွင့်ပြုသော ဆားဗစ်မှ ထိပ်ပိုင်းအင်တာဖေ့စ် ကို ပူပေါင်းခွင့်ပေးခြင်း။ ပုံမှန် အပလီကေးရှင်းများမှာ မလိုအပ်ပါ။"</string>
     <string name="permlab_bindPrintService" msgid="8462815179572748761">"စာထုတ်မှု ဆားဗစ်နှင့် ပူးပေါင်းခြင်း"</string>
@@ -400,82 +400,80 @@
     <string name="permlab_bindNfcService" msgid="2752731300419410724">"NFC ဆားဗစ်နှင့်ပူးပေါင်းခြင်း"</string>
     <string name="permdesc_bindNfcService" msgid="6120647629174066862">"ဖုန်းကိုင်ထားသူနှင့် NFC ထုတ်လွှတ်နေတဲ့ အပလီကေးရှင်း ကို ပူးပေါင်းခွင့် ပေးခြင်း၊. ပုံမှန် အပလီကေးရှင်းများမှာ မလိုအပ်ပါ"</string>
     <string name="permlab_bindTextService" msgid="7358378401915287938">"စာတိုပို့ခြင်းဆားဗစ်နှင့် ပူးပေါင်းခြင်း"</string>
-    <string name="permdesc_bindTextService" msgid="8151968910973998670">"စွဲကိုင်ထားသူအား စာသား ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_bindTextService" msgid="8151968910973998670">"စွဲကိုင်ထားသူအား စာသား ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_bindVpnService" msgid="4708596021161473255">"VPNဆားဗစ်နှင့် ပူးပေါင်းခြင်း"</string>
-    <string name="permdesc_bindVpnService" msgid="2067845564581693905">"စွဲကိုင်ထားသူအား Vpn ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
-    <string name="permlab_bindWallpaper" msgid="8716400279937856462">"နောက်ခံနှင့် ပူးပေါင်းခြင်း"</string>
-    <string name="permdesc_bindWallpaper" msgid="7108428692595491668">"စွဲကိုင်ထားသူအား နောက်ခံ ပုံ၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_bindVpnService" msgid="2067845564581693905">"စွဲကိုင်ထားသူအား Vpn ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_bindWallpaper" msgid="8716400279937856462">"နောက်ခံနှင့် ပူးပေါင်းခြင်း"</string>
+    <string name="permdesc_bindWallpaper" msgid="7108428692595491668">"စွဲကိုင်ထားသူအား နောက်ခံ ပုံ၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_bindVoiceInteraction" msgid="5334852580713715068">"အသံ တုံ့ပြန်လုပ်ပေးသူ တစ်ခုဆီသို့ ချိတ်တွဲခြင်း"</string>
-    <string name="permdesc_bindVoiceInteraction" msgid="2345721766501778101">"စွဲကိုင်ထားသူအား အသံဖြင့် တုံ့ပြန်ရေး ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_bindVoiceInteraction" msgid="2345721766501778101">"စွဲကိုင်ထားသူအား အသံဖြင့် တုံ့ပြန်ရေး ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_manageVoiceKeyphrases" msgid="1252285102392793548">"အသံ သော့ချက် စကားရပ်များကို စီမံကွပ်ကဲရန်"</string>
-    <string name="permdesc_manageVoiceKeyphrases" msgid="8476560722907530008">"စွဲကိုင်ထားသူအား စကားလုံးတို ရှာကြံရေး အတွက် သော့ချက် စကားရပ်များကို စီမံခွင့်ပြုသည်။သာမန် appများ အတွက် ဘယ်တော့မှ လိုအပ်မည် မဟုတ်။"</string>
+    <string name="permdesc_manageVoiceKeyphrases" msgid="8476560722907530008">"စွဲကိုင်ထားသူအား စကားလုံးတို ရှာကြံရေး အတွက် သော့ချက် စကားရပ်များကို စီမံခွင့်ပြုသည်။သာမန် appများ အတွက် ဘယ်တော့မှ လိုအပ်မည် မဟုတ်။"</string>
     <string name="permlab_bindRemoteDisplay" msgid="1782923938029941960">"ထိန်းချုပ်ပြသခြင်း နဲ့ ပူးပေါင်းရန်"</string>
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ဖုန်းကိုင်ထားသူနဲ့ ထိန်းချုပ်ပြသမှုမှ ထိပ်ပိုင်းအင်တာဖေ့စ် ကို ပူးပေါင်းခွင့်ပေးခြင်း။ ပုံမှန် အပလီကေးရှင်းများမှာ မလိုအပ်ပါ"</string>
-    <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ဝဒ်ဂျက်ဝန်ဆောင်မှုနှင့် ပူးပေါင်းရန်"</string>
-    <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"စွဲကိုင်ထားသူအားဝီဂျက် ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"လမ်းကြောင်း စီမံပေးရေး ဝန်ဆောင်မှု တစ်ခုဆီသို့ ချိတ်တွဲခြင်း"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"စွဲကိုင်ထားသူအား မှတ်ပုံတင်ထားသည့်  လမ်းကြောင်း စီမံပေးသူ မည်သူနှင့်မဆို ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
-    <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"စက်ပစ္စည်း ထိန်းချုပ်ခြင်းနှင့် တုံ့ပြန်မှု"</string>
-    <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"စွဲကိုင်ထားသူအား ကိရိယာ စီမံအုပ်ချုပ်သူထံသို့ ရည်ရွယ်ချက်များကို ပို့ခွင့် ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
-    <string name="permlab_bindTvInput" msgid="5601264742478168987">"တီဗီ ထည့်သွင်းမှု တစ်ခုဆီသို့ ချိတ်တွဲပေးခြင်း"</string>
-    <string name="permdesc_bindTvInput" msgid="2371008331852001924">"စွဲကိုင်ထားသူအား တီဗီ ထည့်သွင်းမှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ဝဒ်ဂျက်ဝန်ဆောင်မှုနှင့် ပူးပေါင်းရန်"</string>
+    <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"စွဲကိုင်ထားသူအားဝီဂျက် ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"စက်ပစ္စည်း ထိန်းချုပ်ခြင်းနှင့် တုံ့ပြန်မှု"</string>
+    <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"စွဲကိုင်ထားသူအား ကိရိယာ စီမံအုပ်ချုပ်သူထံသို့ ရည်ရွယ်ချက်များကို ပို့ခွင့် ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_bindTvInput" msgid="5601264742478168987">"တီဗီ ထည့်သွင်းမှု တစ်ခုဆီသို့ ချိတ်တွဲပေးခြင်း"</string>
+    <string name="permdesc_bindTvInput" msgid="2371008331852001924">"စွဲကိုင်ထားသူအား တီဗီ ထည့်သွင်းမှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_modifyParentalControls" msgid="4611318225997592242">"မိဘ ထိန်းချုပ်မှုများကို မွမ်းမံရန်"</string>
-    <string name="permdesc_modifyParentalControls" msgid="7438482894162282039">"ပိုင်ရှင်အား စနစ်၏ မိဘများ ထိန်းချုပ်ရေး ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ ပုံမှန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_modifyParentalControls" msgid="7438482894162282039">"ပိုင်ရှင်အား စနစ်၏ မိဘများ ထိန်းချုပ်ရေး ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ ပုံမှန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_manageDeviceAdmins" msgid="4248828900045808722">"စက်အက်မင်တစ်ယောက် ကို ထည့်ခြင်း သို့ ထုတ်ခြင်း"</string>
     <string name="permdesc_manageDeviceAdmins" msgid="5025608167709942485">"အသုံးပြုသူအား အက်ဒ်မင်များအား ထည့်ခြင်း ထုတ်ခြင်း ပြုလုပ်ခွင့် ပေးခြင်း။ . ပုံမှန် အပလီကေးရှင်းများမှာ မလိုအပ်ပါ"</string>
     <string name="permlab_setOrientation" msgid="3365947717163866844">"စကရင်အနေအထားအားပြောင်းခြင်း"</string>
-    <string name="permdesc_setOrientation" msgid="3046126619316671476">"appအား မျက်နှာပြင် လည်မှုကို အချိန်မရွေး ရပ်ပစ်ခွင့် ပြုသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_setOrientation" msgid="3046126619316671476">"appအား မျက်နှာပြင် လည်မှုကို အချိန်မရွေး ရပ်ပစ်ခွင့် ပြုသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_setPointerSpeed" msgid="9175371613322562934">"မြားအမြန်နှုန်းအား ပြောင်းခြင်း"</string>
-    <string name="permdesc_setPointerSpeed" msgid="6866563234274104233">"appအား မောက်စ်ကို သို့မဟုတ် ထရက်ပဲဒ် ညွှန်တံ၏ နှုန်းကို အချိန်မရွေး ပြောင်းခွင့် ရှိသည်။သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_setPointerSpeed" msgid="6866563234274104233">"appအား မောက်စ်ကို သို့မဟုတ် ထရက်ပဲဒ် ညွှန်တံ၏ နှုန်းကို အချိန်မရွေး ပြောင်းခွင့် ရှိသည်။သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_setKeyboardLayout" msgid="4778731703600909340">"လက်ကွက် အပြင်အဆင်ပြောင်းရန်"</string>
     <string name="permdesc_setKeyboardLayout" msgid="8480016771134175879">"အပလီကေးရှင်းအား လက်ကွက်အပြင်အဆင်အား ပြောင်းခွင့်ပြုပါ။ ပုံမှန် အပလီကေးရှင်းများတွင် မလိုအပ်ပါ။"</string>
     <string name="permlab_signalPersistentProcesses" msgid="4539002991947376659">"appများသို့ Linux အချက်ပြမှု ပို့ခြင်း"</string>
-    <string name="permdesc_signalPersistentProcesses" msgid="4896992079182649141">"appအား ပို့နေသော အချက်ပြမှုကို ရှိနေကြသည့် လုပ်ငန်းစဉ် အားလုံးထံသို့ ပို့ရေးကို တောင်းဆိုခွင့် ပေးသည်။"</string>
+    <string name="permdesc_signalPersistentProcesses" msgid="4896992079182649141">"appအား ပို့နေသော အချက်ပြမှုကို ရှိနေကြသည့် လုပ်ငန်းစဉ် အားလုံးထံသို့ ပို့ရေးကို တောင်းဆိုခွင့် ပေးသည်။"</string>
     <string name="permlab_persistentActivity" msgid="8841113627955563938">"appကို အမြဲတမ်း အလုပ်လုပ်စေခြင်း"</string>
     <string name="permdesc_persistentActivity" product="tablet" msgid="8525189272329086137">"အပလီကေးရှင်းအား မှတ်ဉာဏ်ထဲတွင် ရေရှည်သိမ်းဆည်ထားရန် ခွင့်ပြုပါ။ ဒီခွင့်ပြုချက်ကြောင့် တခြားအပလီကေးရှင်းအများအတွက် မှတ်ဉာဏ်ရရှိမှု နည်းသွားနိုင်ပြီး တက်ဘလက်လည်း နှေးသွားနိုင်ပါသည်။"</string>
     <string name="permdesc_persistentActivity" product="default" msgid="4384760047508278272">"အပလီကေးရှင်းအား မှတ်ဉာဏ်ထဲတွင် ရေရှည်သိမ်းဆည်ထားရန် ခွင့်ပြုပါ။ ဒီခွင့်ပြုချက်ကြောင့် တခြားအပလီကေးရှင်းအများအတွက် မှတ်ဉာဏ်ရရှိမှု နည်းသွားနိုင်ပြီး ဖုန်းလည်း နှေးသွားနိုင်ပါသည်။"</string>
     <string name="permlab_deletePackages" msgid="184385129537705938">"appများကို ဖျက်ရန်"</string>
-    <string name="permdesc_deletePackages" msgid="7411480275167205081">"appအား အန်ဒရွိုက် အထုပ်များကို ဖျက်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် appများကို ဖျက်ပစ်နိုင်သည်။"</string>
+    <string name="permdesc_deletePackages" msgid="7411480275167205081">"appအား အန်ဒရွိုက် အထုပ်များကို ဖျက်ခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် appများကို ဖျက်ပစ်နိုင်သည်။"</string>
     <string name="permlab_clearAppUserData" msgid="274109191845842756">"အခြား appများ၏ ဒေတာကို ဖျက်ရန်"</string>
-    <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"appအား အသုံးပြုသူ ဒေတာကို ရှင်းပစ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"appအား အသုံးပြုသူ ဒေတာကို ရှင်းပစ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_deleteCacheFiles" msgid="3128665571837408675">"အခြား appများ၏ ကက်ရှများကို ဖျက်ရန်"</string>
-    <string name="permdesc_deleteCacheFiles" msgid="3812998599006730196">"appအား ကက်ရှ ဖိုင်များကို ဖျက်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_deleteCacheFiles" msgid="3812998599006730196">"appအား ကက်ရှ ဖိုင်များကို ဖျက်ခွင့် ပြုသည်။"</string>
     <string name="permlab_getPackageSize" msgid="7472921768357981986">"app သိုလ​ှောင်မှု နေရာကို တိုင်းထွာခြင်း"</string>
-    <string name="permdesc_getPackageSize" msgid="3921068154420738296">"appအား ၎င်း၏ ကုဒ်၊ ဒေတာ၊ နှင့် ကက်ရှ ဆိုက်များကို ရယူခွင့် ပြုသည်။"</string>
+    <string name="permdesc_getPackageSize" msgid="3921068154420738296">"appအား ၎င်း၏ ကုဒ်၊ ဒေတာ၊ နှင့် ကက်ရှ ဆိုက်များကို ရယူခွင့် ပြုသည်။"</string>
     <string name="permlab_installPackages" msgid="2199128482820306924">"appများကို တိုက်ရိုက် တပ်ဆင်ခြင်း"</string>
-    <string name="permdesc_installPackages" msgid="5628530972548071284">"appအား အန်ဒရွိုက် အထုပ် အသစ် သို့မဟုတ် မွမ်းမံပြီးကို တပ်ဆင်ခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး ထင်ရာလုပ်နိုင်သော ကြီးမားသည့် ခွင့်ပြုချက်များ ရှိမည့် appများကို ထည့်ပေးနိုင်ကြသည်။"</string>
+    <string name="permdesc_installPackages" msgid="5628530972548071284">"appအား အန်ဒရွိုက် အထုပ် အသစ် သို့မဟုတ် မွမ်းမံပြီးကို တပ်ဆင်ခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးပြုပြီး ထင်ရာလုပ်နိုင်သော ကြီးမားသည့် ခွင့်ပြုချက်များ ရှိမည့် appများကို ထည့်ပေးနိုင်ကြသည်။"</string>
     <string name="permlab_clearAppCache" msgid="7487279391723526815">"app ကက်ရှ ဒေတာ အားလုံးကို ဖျက်ပစ်ရန်"</string>
     <string name="permdesc_clearAppCache" product="tablet" msgid="8974640871945434565">"အပလီကေးရှင်းမှာ တခြား အပလီကေးရှင်းများမှ ဒေတာများအား ယာယီ သိုလှောင်မှုနေရာမှ ဖျက်ပစ်ပြီး နေရာလွတ် လုပ်ခွင့်ပြုပါ။ ဒီလိုလုပ်ခြင်းဖြင့် တခြား အပလီကေးရှင်းများ စတင်ရာတွင် နှေးကွေးမှု ဖြစ်စေနိုင်ပါသည်။"</string>
     <string name="permdesc_clearAppCache" product="default" msgid="2459441021956436779">"အပလီကေးရှင်းမှာ တခြား အပလီကေးရှင်းများမှ ဒေတာများအား ယာယီ သိုလှောင်မှုနေရာမှ ဖျက်ပစ်ပြီး နေရာလွတ် လုပ်ခွင့်ပြုပါ။ ဒီလိုလုပ်ခြင်းဖြင့် တခြား အပလီကေးရှင်းများ စတင်ရာတွင် နှေးကွေးမှု ဖြစ်စေနိုင်ပါသည်။"</string>
     <string name="permlab_movePackage" msgid="3289890271645921411">"app အရင်းအမြစ်များကို ဖယ်ရှားခြင်း"</string>
-    <string name="permdesc_movePackage" msgid="319562217778244524">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်းကို app၏ အရင်းအမြစ်များကို အတွင်းမှ အပြင်သို့ ရွှေ့ပြောင်းခြင်း နှင့် ပြောင်းပြန်လုပ်ခြင်းကို ခွင့်ပြုသည်။"</string>
+    <string name="permdesc_movePackage" msgid="319562217778244524">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်းကို app၏ အရင်းအမြစ်များကို အတွင်းမှ အပြင်သို့ ရွှေ့ပြောင်းခြင်း နှင့် ပြောင်းပြန်လုပ်ခြင်းကို ခွင့်ပြုသည်။"</string>
     <string name="permlab_readLogs" msgid="6615778543198967614">"တုံ့ပြန်မှုလွယ်သောစာ​ရင်းဒေတာအားဖတ်ခြင်း"</string>
-    <string name="permdesc_readLogs" product="tablet" msgid="82061313293455151">"appအား စနစ်၏ လော့ဂ် ဖိုင် အမျိုးမျိုးတို့ကို ဖတ်ကြားခွင့် ပြုသည်။ သို့ဖြစ်၍ ၎င်းသည် သင်က တက်ဘလက်နှင့် ဘာတွေ လုပ်ကိုင်နေကြောင်း အထွေထွေ အချက်အလက်များကို၊ ဖြစ်နိုင်သည်မှာ ကိုယ်ရေး သို့မဟုတ် ပုဂ္ဂိုလ်ရေး အချက်အလက်များ အပါအဝင် တို့ကိုပါ၊ ရှာတွေ့သိလာနိုင်သည်။"</string>
-    <string name="permdesc_readLogs" product="default" msgid="2063438140241560443">"appအား စနစ်၏ လော့ဂ် ဖိုင် အမျိုးမျိုးတို့ကို ဖတ်ကြားခွင့် ပြုသည်။ သို့ဖြစ်၍ ၎င်းသည် သင်က ဖုန်းနှင့် ဘာတွေ လုပ်ကိုင်နေကြောင်း အထွေထွေ အချက်အလက်များကို၊ ဖြစ်နိုင်သည်မှာ ကိုယ်ရေး သို့မဟုတ် ပုဂ္ဂိုလ်ရေး အချက်အလက်များ အပါအဝင် တို့ကိုပါ၊ ရှာတွေ့သိလာနိုင်သည်။"</string>
+    <string name="permdesc_readLogs" product="tablet" msgid="82061313293455151">"appအား စနစ်၏ လော့ဂ် ဖိုင် အမျိုးမျိုးတို့ကို ဖတ်ကြားခွင့် ပြုသည်။ သို့ဖြစ်၍ ၎င်းသည် သင်က တက်ဘလက်နှင့် ဘာတွေ လုပ်ကိုင်နေကြောင်း အထွေထွေ အချက်အလက်များကို၊ ဖြစ်နိုင်သည်မှာ ကိုယ်ရေး သို့မဟုတ် ပုဂ္ဂိုလ်ရေး အချက်အလက်များ အပါအဝင် တို့ကိုပါ၊ ရှာတွေ့သိလာနိုင်သည်။"</string>
+    <string name="permdesc_readLogs" product="default" msgid="2063438140241560443">"appအား စနစ်၏ လော့ဂ် ဖိုင် အမျိုးမျိုးတို့ကို ဖတ်ကြားခွင့် ပြုသည်။ သို့ဖြစ်၍ ၎င်းသည် သင်က ဖုန်းနှင့် ဘာတွေ လုပ်ကိုင်နေကြောင်း အထွေထွေ အချက်အလက်များကို၊ ဖြစ်နိုင်သည်မှာ ကိုယ်ရေး သို့မဟုတ် ပုဂ္ဂိုလ်ရေး အချက်အလက်များ အပါအဝင် တို့ကိုပါ၊ ရှာတွေ့သိလာနိုင်သည်။"</string>
     <string name="permlab_anyCodecForPlayback" msgid="715805555823881818">"မည်သည့် မီဒီယာ ဒီကုဒ်ဒါမဆို ပြသရာတွင် သုံးရန်"</string>
     <string name="permdesc_anyCodecForPlayback" msgid="8283912488433189010">"အပလီကေးရှင်းအား သွင်းထားသည့် မီဒီယာ ဒီကုဒ်ဒါ အား သုံးပြီး ဖွင့်ရန် ဒီကုဒ် လုပ်ခွင့် ပြုပါ"</string>
     <string name="permlab_manageCaCertificates" msgid="1678391896786882014">"ယုံကြည်ရသော အကောင့်များအား ထိန်းသိမ်းခြင်း"</string>
     <string name="permdesc_manageCaCertificates" msgid="4015644047196937014">"အပလီကေးရှင်းအား CA လက်မှတ်များအား ယုံကြည်စိတ်ချရသော အရာ အဖြစ် ထည့်ခွင့် ပြန်ထုတ်ခွင့် ပေးခြင်း။"</string>
-    <string name="permlab_bindJobService" msgid="3637568367978271086">"အပလီကေးရှင်း၏ စီစဉ်ထားသည့် နောက်ခံ အလုပ်ကို လုပ်ကိုင်ရန်"</string>
+    <string name="permlab_bindJobService" msgid="3637568367978271086">"အပလီကေးရှင်း၏ စီစဉ်ထားသည့် နောက်ခံ အလုပ်ကို လုပ်ကိုင်ရန်"</string>
     <string name="permdesc_bindJobService" msgid="3473288460524119838">"ဒီခွင့်ပြုချက်က တောင်းဆိုလာလျှင် အန်ဒရွိုက် စနစ်အား အပလီကေးရှင်းကို နောက်ခံမှာ အလုပ် လုပ်ကိုင်စေပါသည်။"</string>
     <string name="permlab_diagnostic" msgid="8076743953908000342">"diagမှပိုင်ဆိုင်သော ရင်းနှီးမှုများကို ဖတ်/ရေးခြင်း"</string>
-    <string name="permdesc_diagnostic" msgid="6608295692002452283">"appအား diag အုပ်စု ပိုင်ဆိုင်သည့် မည်သည့် အရင်းအမြစ်ကို မဆို ရေးခြင်း နှင့် ဖတ်ခြင်းကို ခွင့်ပြုသည်၊ ဥပမာ၊ /dev ထဲက ဖိုင်များ။ ၎င်းက စနစ်၏ တည်ငြိမ်မှု နှင့် လုံခြုံမှုကို ထိပါးနိုင်သည့် အလားအလာ ရှိသည်။ ထုတ်လုပ်သူ သို့မဟုတ် အော်ပရေတာက ဟာ့ဒ်ဝဲ ဆိုင်ရာ ပြဿနာ ရှာဖွေ စူးစမ်းမှု အတွက်သာ ၎င်းကို အသုံးပြုရမည်။"</string>
-    <string name="permlab_changeComponentState" msgid="6335576775711095931">"app အစိတ်အပိုင်းများကို ဖွင့်ခြင်း သို့မဟုတ် ပိတ်ခြင်း"</string>
-    <string name="permdesc_changeComponentState" product="tablet" msgid="8887435740982237294">"appအား အခြား app တစ်ခု၏ အစိတ်အပိုင်း တစ်ခုမှာ ဖွင့်ထားသည် ဖြစ်စေ ဖွင့်မထားသည် ဖြစ်စေ ပြောင်းလဲခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် တက်ဘလက်၏ လုပ်နိုင်စွမ်းကို ပိတ်ပစ်နိုင်သည်။ app၏ အစိတ်အပိုင်းများကို သုံးမရအောင်၊ စနစ်မမှန်အောင် သို့မဟုတ် အခြေအနေ မတည်ငြိမ်အောင် လုပ်၍ ရနိုင်သောကြောင့် ဒီ ခွင့်ပြုချက်ကို သုံးရာတွင် သတိထားရန် လိုအပ်သည်။"</string>
-    <string name="permdesc_changeComponentState" product="default" msgid="1827232484416505615">"appအား အခြား app တစ်ခု၏ အစိတ်အပိုင်း တစ်ခုမှာ ဖွင့်ထားသည် ဖြစ်စေ ဖွင့်မထားသည် ဖြစ်စေ ပြောင်းလဲခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် ဖုန်း၏ လုပ်နိုင်စွမ်းကို ပိတ်ပစ်နိုင်သည်။ app၏ အစိတ်အပိုင်းများကို သုံးမရအောင်၊ စနစ်မမှန်အောင် သို့မဟုတ် အခြေအနေ မတည်ငြိမ်အောင် လုပ်၍ ရနိုင်သောကြောင့် ဒီ ခွင့်ပြုချက်ကို သုံးရာတွင် သတိထားရန် လိုအပ်သည်။"</string>
+    <string name="permdesc_diagnostic" msgid="6608295692002452283">"appအား diag အုပ်စု ပိုင်ဆိုင်သည့် မည်သည့် အရင်းအမြစ်ကို မဆို ရေးခြင်း နှင့် ဖတ်ခြင်းကို ခွင့်ပြုသည်၊ ဥပမာ၊ /dev ထဲက ဖိုင်များ။ ၎င်းက စနစ်၏ တည်ငြိမ်မှု နှင့် လုံခြုံမှုကို ထိပါးနိုင်သည့် အလားအလာ ရှိသည်။ ထုတ်လုပ်သူ သို့မဟုတ် အော်ပရေတာက ဟာ့ဒ်ဝဲ ဆိုင်ရာ ပြဿနာ ရှာဖွေ စူးစမ်းမှု အတွက်သာ ၎င်းကို အသုံးပြုရမည်။"</string>
+    <string name="permlab_changeComponentState" msgid="6335576775711095931">"app အစိတ်အပိုင်းများကို ဖွင့်ခြင်း သို့မဟုတ် ပိတ်ခြင်း"</string>
+    <string name="permdesc_changeComponentState" product="tablet" msgid="8887435740982237294">"appအား အခြား app တစ်ခု၏ အစိတ်အပိုင်း တစ်ခုမှာ ဖွင့်ထားသည် ဖြစ်စေ ဖွင့်မထားသည် ဖြစ်စေ ပြောင်းလဲခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် တက်ဘလက်၏ လုပ်နိုင်စွမ်းကို ပိတ်ပစ်နိုင်သည်။ app၏ အစိတ်အပိုင်းများကို သုံးမရအောင်၊ စနစ်မမှန်အောင် သို့မဟုတ် အခြေအနေ မတည်ငြိမ်အောင် လုပ်၍ ရနိုင်သောကြောင့် ဒီ ခွင့်ပြုချက်ကို သုံးရာတွင် သတိထားရန် လိုအပ်သည်။"</string>
+    <string name="permdesc_changeComponentState" product="default" msgid="1827232484416505615">"appအား အခြား app တစ်ခု၏ အစိတ်အပိုင်း တစ်ခုမှာ ဖွင့်ထားသည် ဖြစ်စေ ဖွင့်မထားသည် ဖြစ်စေ ပြောင်းလဲခွင့် ပြုသည်။ အကြံအဖန် appများက ၎င်းကို အသုံးပြုပြီး အရေးကြီးသည့် ဖုန်း၏ လုပ်နိုင်စွမ်းကို ပိတ်ပစ်နိုင်သည်။ app၏ အစိတ်အပိုင်းများကို သုံးမရအောင်၊ စနစ်မမှန်အောင် သို့မဟုတ် အခြေအနေ မတည်ငြိမ်အောင် လုပ်၍ ရနိုင်သောကြောင့် ဒီ ခွင့်ပြုချက်ကို သုံးရာတွင် သတိထားရန် လိုအပ်သည်။"</string>
     <string name="permlab_grantRevokePermissions" msgid="4627315351093508795">"ခွင့်ပြုချက် ထောက်ခံခြင်း သို့ ပယ်ဖျက်ခြင်း"</string>
     <string name="permdesc_grantRevokePermissions" msgid="4088642654085850662">"အပလီကေးရှင်းအား ကိုယ်တိုင် ဒါမှမဟုတ် တခြား အပလီကေးရှင်းအတွက် ခွင့်ပြုချက်များအား ခွင့်ပြုခြင်း၊ပယ်ဖျယ်ခြင်း လုပ်ခွင့်ပြုပါ။ အန္တရာယ်ရှိသော အပလီကေးရှင်းများမှ ဒီခွင့်ပြုချက်အားသုံးပြီး အခွင့်မရှိသော စွမ်းဆောင်ချက်များအား သုံးနိုင်ပါသည်"</string>
-    <string name="permlab_setPreferredApplications" msgid="8463181628695396391">"ပိုကြိုက်သည့် appများကို သတ်မှတ်ခြင်း"</string>
-    <string name="permdesc_setPreferredApplications" msgid="4973986762241783712">"appအား သင် နှစ်ခြုက်သည့် appများကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက ဖွင့်ထားသည့် appများကို တိတ်တဆိတ် ပြောင်းလဲပစ်ကာ၊ ရှိနေကြသည့် သင်၏ appများကို သင့်ထံမှ သင်၏ ကိုယ်ရေး ဒေတာများကို စုစည်းရန် ခိုင်းနိုင်သည်။"</string>
+    <string name="permlab_setPreferredApplications" msgid="8463181628695396391">"ပိုကြိုက်သည့် appများကို သတ်မှတ်ခြင်း"</string>
+    <string name="permdesc_setPreferredApplications" msgid="4973986762241783712">"appအား သင် နှစ်ခြုက်သည့် appများကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက ဖွင့်ထားသည့် appများကို တိတ်တဆိတ် ပြောင်းလဲပစ်ကာ၊ ရှိနေကြသည့် သင်၏ appများကို သင့်ထံမှ သင်၏ ကိုယ်ရေး ဒေတာများကို စုစည်းရန် ခိုင်းနိုင်သည်။"</string>
     <string name="permlab_writeSettings" msgid="2226195290955224730">"စနစ်အပြင်အဆင်အား မွမ်းမံခြင်း"</string>
-    <string name="permdesc_writeSettings" msgid="7775723441558907181">"appအား စနစ်၏ ဆက်တင် ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများက သင့် စနစ်၏ စီစဉ်ဖွဲ့စည်းမှုကို ဖျက်ဆီးပစ်နိုင်သည်။"</string>
+    <string name="permdesc_writeSettings" msgid="7775723441558907181">"appအား စနစ်၏ ဆက်တင် ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများက သင့် စနစ်၏ စီစဉ်ဖွဲ့စည်းမှုကို ဖျက်ဆီးပစ်နိုင်သည်။"</string>
     <string name="permlab_writeSecureSettings" msgid="204676251876718288">"စနစ်အပြင်အဆင်လုံခြုံမှုအား မွမ်းမံခြင်း"</string>
-    <string name="permdesc_writeSecureSettings" msgid="8159535613020137391">"appအား စနစ်၏ လုံခြုံစိတ်ချရသည့် ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
+    <string name="permdesc_writeSecureSettings" msgid="8159535613020137391">"appအား စနစ်၏ လုံခြုံစိတ်ချရသည့် ဒေတာကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
     <string name="permlab_writeGservices" msgid="2149426664226152185">"ဂူဂဲလ်ဝန်ဆောင်မှုမြေပုံအားမွမ်းမံခြင်း"</string>
-    <string name="permdesc_writeGservices" msgid="1287309437638380229">"appအယဒ Google ဝန်ဆောင်မှုများ မြေပုံကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
+    <string name="permdesc_writeGservices" msgid="1287309437638380229">"appအယဒ Google ဝန်ဆောင်မှုများ မြေပုံကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
     <string name="permlab_receiveBootCompleted" msgid="5312965565987800025">"အစတွင် လုပ်ဆောင်ရန်"</string>
-    <string name="permdesc_receiveBootCompleted" product="tablet" msgid="7390304664116880704">"appအား စနစ်၏ စတင်မှု ပြီးဆုံးသည့်နှင့် မိမိကိုမိမိ စတင်ခွင့် ပြုသည်။ သို့ဖြစ်၍ ဖုန်း စတင်မှုမှာ အချိန် ပိုကြာနိုင်ပြီး appက တချိန်လုံး အလုပ်လုပ်နေခြင်းကြောင့် တက်ဘလက်၏ အလုပ် တစ်ခုလုံးကို နှေးကွေးလာစေနိုင်သည်။"</string>
-    <string name="permdesc_receiveBootCompleted" product="default" msgid="513950589102617504">"appအား စနစ်၏ စတင်မှု ပြီးဆုံးသည့်နှင့် မိမိကိုမိမိ စတင်ခွင့် ပြုသည်။ သို့ဖြစ်၍ ဖုန်း စတင်မှုမှာ အချိန် ပိုကြာနိုင်ပြီး appက တချိန်လုံး အလုပ်လုပ်နေခြင်းကြောင့် ဖုန်း၏ အလုပ် တစ်ခုလုံးကို နှေးကွေးလာစေနိုင်သည်။"</string>
+    <string name="permdesc_receiveBootCompleted" product="tablet" msgid="7390304664116880704">"appအား စနစ်၏ စတင်မှု ပြီးဆုံးသည့်နှင့် မိမိကိုမိမိ စတင်ခွင့် ပြုသည်။ သို့ဖြစ်၍ ဖုန်း စတင်မှုမှာ အချိန် ပိုကြာနိုင်ပြီး appက တချိန်လုံး အလုပ်လုပ်နေခြင်းကြောင့် တက်ဘလက်၏ အလုပ် တစ်ခုလုံးကို နှေးကွေးလာစေနိုင်သည်။"</string>
+    <string name="permdesc_receiveBootCompleted" product="default" msgid="513950589102617504">"appအား စနစ်၏ စတင်မှု ပြီးဆုံးသည့်နှင့် မိမိကိုမိမိ စတင်ခွင့် ပြုသည်။ သို့ဖြစ်၍ ဖုန်း စတင်မှုမှာ အချိန် ပိုကြာနိုင်ပြီး appက တချိန်လုံး အလုပ်လုပ်နေခြင်းကြောင့် ဖုန်း၏ အလုပ် တစ်ခုလုံးကို နှေးကွေးလာစေနိုင်သည်။"</string>
     <string name="permlab_broadcastSticky" msgid="7919126372606881614">"ကြာရှည်ခံ ထုတ်လွှတ်မှု အားပေးပို့ခြင်း"</string>
     <string name="permdesc_broadcastSticky" product="tablet" msgid="7749760494399915651">"အပလီကေးရှင်းအား ကြာရှည်ခံ ထုတ်လွှင့်မှု ပြုပါ။ ဒီထုတ်လွှင့်မှုများဟာ ထုတ်လွှင့်မှု ပြီးဆုံးပြီးသွားတည့်တိုင် ကျန်နေမည် ဖြစ်ပါသည်။ အလွန်အကျွံသုံးခြင်းကြောင့် မက်မိုရီ အသုံးများပြီး တက်ဘလက်နှေးခြင်း၊ မတည်ငြိမ်ခြင်း ဖြစ်နိုင်ပါသည်"</string>
     <string name="permdesc_broadcastSticky" product="default" msgid="2825803764232445091">"အပလီကေးရှင်းအား ကြာရှည်ခံ ထုတ်လွှင့်မှု ပြုပါ။ ဒီထုတ်လွှင့်မှုများဟာ ထုတ်လွှင့်မှု ပြီးဆုံးပြီးသွားတည့်တိုင် ကျန်နေမည် ဖြစ်ပါသည်။ အလွန်အကျွံသုံးခြင်းကြောင့် မှတ်ဉာဏ်အသုံးများပြီး ဖုန်းနှေးခြင်း၊ မတည်ငြိမ်ခြင်း ဖြစ်နိုင်ပါသည်"</string>
@@ -495,32 +493,32 @@
     <string name="permdesc_readProfile" product="default" msgid="5462475151849888848">"အပလီကေးရှင်းအား စက်မှာ သိမ်းထားသော သင့်နာမည် နှင့် အဆက်အသွယ် သတင်းအချက်အလက်များကဲ့သို့သော ကိုယ်ရေးကိုယ်တာ အချက်အလက်များအား ဖတ်ခွင့် ပြုခြင်း။ အပလီကေးရှင်းမှ သင့်အား သိရှိနိုင်ပြီး သင့်ကိုယ်ရေးအချက်အလက်များအား အခြားသူများကို ပေးပို့နိုင်ပါသည်"</string>
     <string name="permlab_writeProfile" msgid="907793628777397643">"သင့်ရဲ့ အဆက်အသွယ်ကဒ် အား ပြင်ရန်"</string>
     <string name="permdesc_writeProfile" product="default" msgid="5552084294598465899">"အပလီကေးရှင်းအား စက်မှာ သိမ်းထားသော သင့်နာမည် နှင့် အဆက်အသွယ် သတင်းအချက်အလက်များကဲ့သို့သော ကိုယ်ရေးကိုယ်တာ အချက်အလက်များအား ပြင်ဆင်ခွင့် သို့ ထည့်ခွင့် ပြုခြင်း။ အပလီကေးရှင်းမှ သင့်အား သိရှိနိုင်ပြီး သင့်ကိုယ်ရေးအချက်အလက်များအား အခြားသူများကို ပေးပို့နိုင်ပါသည်"</string>
-    <string name="permlab_bodySensors" msgid="4871091374767171066">"ခန္ဓာကိုယ် အာရံခံကိရိယာများ (နှလုံးခုန်နှုန်း စောင့်ကြည့်စက် လို)"</string>
-    <string name="permdesc_bodySensors" product="default" msgid="2998865085124153531">"appအား သင့် ခန္ဓာကိုယ် အတွင်းမှာ၊ နှလုံးခုန်နှုန်းလို၊ ဘာတွေ ဖြစ်ပျက်နေကြောင်းကို တိုင်းထွာရန် အသုံးပြုသည့် အာရုံခံကိရိယာများ ထံမှ ဒေတာများကို ရယူသုံးခွင့် ပေးထားသည်။"</string>
-    <string name="permlab_readSocialStream" product="default" msgid="1268920956152419170">"သင့်လူမှုရေးရာအဖွဲ့အစည်းတွင်ရေးသားရန်"</string>
+    <string name="permlab_bodySensors" msgid="4871091374767171066">"ခန္ဓာကိုယ် အာရံခံကိရိယာများ (နှလုံးခုန်နှုန်း စောင့်ကြည့်စက် လို)"</string>
+    <string name="permdesc_bodySensors" product="default" msgid="2998865085124153531">"appအား သင့် ခန္ဓာကိုယ် အတွင်းမှာ၊ နှလုံးခုန်နှုန်းလို၊ ဘာတွေ ဖြစ်ပျက်နေကြောင်းကို တိုင်းထွာရန် အသုံးပြုသည့် အာရုံခံကိရိယာများ ထံမှ ဒေတာများကို ရယူသုံးခွင့် ပေးထားသည်။"</string>
+    <string name="permlab_readSocialStream" product="default" msgid="1268920956152419170">"သင့်လူမှုရေးရာအဖွဲ့အစည်းတွင်ရေးသားရန်"</string>
     <string name="permdesc_readSocialStream" product="default" msgid="4255706027172050872">"အပလီကေးရှင်းအား သင်နှင့် သင့်သူငယ်ချင်းတို့၏ ဆိုရှယ်နက်ဝဘ်မှ နောက်ဆုံးပေါ် အချက်အလက်များအား အသုံးပြုခွင့်နင့် ထပ်တူညီအောင် လုပ်ဆောင်ခွင့် ပြုပါ။ သတင်းအချက်အလက် မျှဝေခြင်းတွင် သတိပြုရန် -- ဤသို့ ခွင့်ပြုခြင်းဖြင့် အပလီကေးရှင်းမှ ယုံကြည်စိတ်ချရမှုကို ဂရုမပြုပဲ သင် နှင့် သူငယ်ချင်းများကြား ဆက်သွယ်မှုများအား သိရှိနိုင်ပါသည်။ မှတ်ချက်။ ဤခွင့်ပြုချက်အား ဆိုရှယ်နက်ဝဘ် အားလုံးတွင် ခွင့်ပြုခြင်း မလုပ်သင့်ပါ။"</string>
-    <string name="permlab_writeSocialStream" product="default" msgid="3504179222493235645">"သင့်လူမှုရေးရာအဖွဲ့အစည်းတွင်ရေးသားရန်"</string>
+    <string name="permlab_writeSocialStream" product="default" msgid="3504179222493235645">"သင့်လူမှုရေးရာအဖွဲ့အစည်းတွင်ရေးသားရန်"</string>
     <string name="permdesc_writeSocialStream" product="default" msgid="3086557552204114849">"အပလီကေးရှင်းအား သူငယ်ချင်းများရဲ့ ဆိုရှယ်နက်ဝဘ်မှနောက်ဆုံးပေါ် အချက်အလက်များအား ဖန်သားပြင်ပေါ်တွင် ပြခွင့်ပြုရန်။ သတင်းအချက်အလက် မျှဝေခြင်းတွင် သတိပြုရန် -- ဤသို့ ခွင့်ပြုခြင်းဖြင့် အပလီကေးရှင်းမှ  သူငယ်ချင်းများထံမှ လာသကဲ့သို့ သတင်းများ ပြုလုပ်နိုင်ပါသည်။ မှတ်ချက်၊ ဤခွင့်ပြုချက်အား ဆိုရှယ်နက်ဝဘ် အားလုံးတွင် ခွင့်ပြုခြင်း မလုပ်သင့်ပါ။"</string>
-    <string name="permlab_readCalendar" msgid="5972727560257612398">"ပြက္ခဒိန်အဖြစ်အပျက်များနှင့် လှို့ဝှက်အချက်အလက်များအား ဖတ်ခြင်း"</string>
+    <string name="permlab_readCalendar" msgid="5972727560257612398">"ပြက္ခဒိန်အဖြစ်အပျက်များနှင့် လှို့ဝှက်အချက်အလက်များအား ဖတ်ခြင်း"</string>
     <string name="permdesc_readCalendar" product="tablet" msgid="4216462049057658723">"အပလီကေးရှင်းအား တက်ဘလက်ထဲတွင် သိမ်းထားသော သူငယ်ချင်းနှင့် လုပ်ဖော်ကိုင်ဘက်များ၏ ပြက္ခဒိန် အဖြစ်အပျက်များအပါအဝင် အားလုံးကို ဖတ်ရှုခွင့်ပြုပါ။ ဒီခွင့်ပြုချက်ကြောင့် အပလီကေးရှင်းမှ ပြက္ခဒိန် အဖြစ်အပျက်များအား လျှို့ဝှက်မှု သို့ ဂရုပြုမှု ကို ထည့်သွင်းမစဉ်းစားပဲ သိမ်းဆည်းခြင်း၊ မျှဝေခြင်း ပြုလုပ်စေနိုင်ပါသည်"</string>
     <string name="permdesc_readCalendar" product="default" msgid="7434548682470851583">"အပလီကေးရှင်းအားဖုန်းထဲတွင် သိမ်းထားသော သူငယ်ချင်းနှင့် လုပ်ဖော်ကိုင်ဘက်များ၏ ပြက္ခဒိန် အဖြစ်အပျက်များအပါအဝင် အားလုံးကို ဖတ်ရှုခွင့်ပြုပါ။ ဒီခွင့်ပြုချက်ကြောင့် အပလီကေးရှင်းမှ ပြက္ခဒိန် အဖြစ်အပျက်များအား လျှို့ဝှက်မှု သို့ ဂရုပြုမှု ကို ထည့်သွင်းမစဉ်းစားပဲ သိမ်းဆည်းခြင်း၊ မျှဝေခြင်း ပြုလုပ်စေနိုင်ပါသည်"</string>
-    <string name="permlab_writeCalendar" msgid="8438874755193825647">"ပြက္ခဒိန်အဖြစ်အပျက်များကို ထပ်ထည့်ရန် သို့မဟုတ် မွမ်းမံရန်နှင့် ပိုင်ရှင်၏အသိမပေးပဲ ဧည့်သည်များထံ အီးမေးလ်ပို့ရန်"</string>
+    <string name="permlab_writeCalendar" msgid="8438874755193825647">"ပြက္ခဒိန်အဖြစ်အပျက်များကို ထပ်ထည့်ရန် သို့မဟုတ် မွမ်းမံရန်နှင့် ပိုင်ရှင်၏အသိမပေးပဲ ဧည့်သည်များထံ အီးမေးလ်ပို့ရန်"</string>
     <string name="permdesc_writeCalendar" product="tablet" msgid="6679035520113668528">"အပလီကေးရှင်းအား သင်၏ တက်ဘလက်တွင် သူငယ်ချင်း အလုပ်ဖော်များ အပါအဝင် သင်၏ ပြောင်းလဲအဖြစ်အပျက်များအား ထည့်ခြင်း၊ ထုတ်ခြင်းအား ခွင့်ပြုရန်။ ဤခွင့်ပြုချက်သည် အပလီကေးရှင်းအား သတင်းများပို့ခြင်းကို ပြက္ခဒိန်ပိုင်ရှင်ဆီမှ လာသလို အနေဖြင့် ပေးပို့ခြင်း သို့မဟုတ် အဖြစ်အပျက်များကို ပိုင်ရှင်မသိပဲ ပြင်ဆင်နိုင်ပါသည်။"</string>
     <string name="permdesc_writeCalendar" product="default" msgid="2324469496327249376">"အပလီကေးရှင်းအား သင်၏ ဖုန်းတွင် သူငယ်ချင်း အလုပ်ဖော်များ အပါအဝင် သင်၏ ပြောင်းလဲအဖြစ်အပျက်များအား ထည့်ခြင်း၊ ထုတ်ခြင်းအား ခွင့်ပြုရန်။ ဤခွင့်ပြုချက်သည် အပလီကေးရှင်းအား သတင်းများပို့ခြင်းကို ပြက္ခဒိန်ပိုင်ရှင်ဆီမှ လာသလို အနေဖြင့် ပေးပို့ခြင်း သို့မဟုတ် အဖြစ်အပျက်များကို ပိုင်ရှင်မသိပဲ ပြင်ဆင်နိုင်ပါသည်။"</string>
     <string name="permlab_accessMockLocation" msgid="8688334974036823330">"စမ်းသပ်ရန်အတွက် တည်နေရာပုံစံတုမူရင်း"</string>
     <string name="permdesc_accessMockLocation" msgid="5808711039482051824">"စမ်းသပ်ရန် သို့ နေရာပြပံ့ပို့းမှု အသစ်သွင်းရန် တည်နေရာဇစ်မြစ်အတုကို ဖန်တီးပါ။ ဤသို့လုပ်ခြင်းအားဖြင့် အပလီကေးရှင်းမှ တည်နေရာကို ကျော်ဖြတ်ပြင်ဆင်ခြင်းနှင်ူ ဂျီပီအက်စ် သို့ နေရာပြပံ့ပိုးမှုကဲ့သို့သော အခြား တည်နေရာဇစ်မြစ်များ၏ အခြေအနေကို ပြန်ပို့ပေးနိုင်မည်ဖြစ်သည်။"</string>
-    <string name="permlab_accessLocationExtraCommands" msgid="2836308076720553837">"တည်နေရာပံ့ပိုးမှုညွှန်ကြားချက်အပိုအား ဝင်ရောက်ကြည့်ခြင်း"</string>
-    <string name="permdesc_accessLocationExtraCommands" msgid="6078307221056649927">"appအား တည်နေရာ စီမံပေးရေး ညွှန်ကြားချက် အပိုများကို ရယူခွင့်ပြုသည်။ သို့ဖြစ်၍ appသည် GPS သို့မဟုတ် အခြား တည်နေရာ ရင်းမြစ်ကို သုံးကြသူတို့၏ လုပ်ငန်းများကို ဝင်စွက်ခွင့် ပြုနိုင်သည်။"</string>
-    <string name="permlab_installLocationProvider" msgid="6578101199825193873">"တည်နေရာဝန်ဆောင်မှုပေးသူအားထည့်သွင်းရန်ခွင့်ပြုခြင်း"</string>
+    <string name="permlab_accessLocationExtraCommands" msgid="2836308076720553837">"တည်နေရာပံ့ပိုးမှုညွှန်ကြားချက်အပိုအား ဝင်ရောက်ကြည့်ခြင်း"</string>
+    <string name="permdesc_accessLocationExtraCommands" msgid="6078307221056649927">"appအား တည်နေရာ စီမံပေးရေး ညွှန်ကြားချက် အပိုများကို ရယူခွင့်ပြုသည်။ သို့ဖြစ်၍ appသည် GPS သို့မဟုတ် အခြား တည်နေရာ ရင်းမြစ်ကို သုံးကြသူတို့၏ လုပ်ငန်းများကို ဝင်စွက်ခွင့် ပြုနိုင်သည်။"</string>
+    <string name="permlab_installLocationProvider" msgid="6578101199825193873">"တည်နေရာဝန်ဆောင်မှုပေးသူအားထည့်သွင်းရန်ခွင့်ပြုခြင်း"</string>
     <string name="permdesc_installLocationProvider" msgid="9066146120470591509">"စမ်းသပ်ရန် သို့ နေရာပြပံ့ပို့းမှု အသစ်သွင်းရန် တည်နေရာဇစ်မြစ်အတုကို ဖန်တီးပါ။ ဤသို့လုပ်ခြင်းအားဖြင့် အပလီကေးရှင်းမှ တည်နေရာကို ကျော်ဖြတ်ပြင်ဆင်ခြင်းနှင်ူ ဂျီပီအက်စ် သို့ နေရာပြပံ့ပိုးမှုကဲ့သို့သော အခြား တည်နေရာဇစ်မြစ်များ၏ အခြေအနေကို ပြန်ပို့ပေးနိုင်မည်ဖြစ်သည်။"</string>
     <string name="permlab_accessFineLocation" msgid="1191898061965273372">"တည်နေရာ အတိအကျ (ဂျီပီအက်စ် နှင့် ကွန်ရက်အခြေခံ)"</string>
     <string name="permdesc_accessFineLocation" msgid="5295047563564981250">"အပလီကေးရှင်းမှ သင့်ရဲ့ တိကျသောနေရာကို ဂျီပီအက်စ် သို့ ဆယ်လူလာတာဝါတိုင်၊ ဝိုင်ဖိုင် အချက်အလက်များ သုံးပြီး ရှာခြင်း ခွင့်ယူပါ။ နေရာပြ ဆားဗစ်များ စက်ပေါ်မှာ ရှိရမှာ ဖြစ်သလို ဖွင့်ထားရမှာလည်း ဖြစ်ပါသည်။ အပလီကေးရှင်းမှ ဒီဆားဗစ်များကို သုံး၍ ရှာဖွေသောကြောင့် ဘက်ထရီ ပိုကုန်နိုင်ပါသည်။"</string>
     <string name="permlab_accessCoarseLocation" msgid="4887895362354239628">"အကြမ်းဖျင်းနေရာ (ကွန်ရက်အခြေခံ)"</string>
     <string name="permdesc_accessCoarseLocation" msgid="2538200184373302295">"သင့်ရဲ့ ပျမ်းမျတည်နေရာကို အပလီကေးရှင်း အား သိခွင့် ပြုရန်။ ဒီ တည်နေရာကို တည်နေရာရှာဖွေရေး ဆားဗစ်မှ မိုဘိုင်း တာဝါတိုင်၊ ဝိုင်ဖိုင် စသည်တို့မှ တဆင့် ရယူပါသည်။  အပလီကေးရှင်း အနေဖြင့် ဒီ ဆားဗစ်များ ရှိနေရန် လိုအပ်ပါသည်။ ဒီအရာများကို အသုံးပြု၍ သင့်နေရာကို သိနိုင်ပါသည်။"</string>
     <string name="permlab_accessSurfaceFlinger" msgid="2363969641792388947">"SurfaceFlingerအား ချိတ်ဆက်ရန်"</string>
-    <string name="permdesc_accessSurfaceFlinger" msgid="1041619516733293551">"ဒီ appအား InputFlinger အဆင့်နိမ့် အင်္ဂါရပ်များကို သုံးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_accessSurfaceFlinger" msgid="1041619516733293551">"ဒီ appအား InputFlinger အဆင့်နိမ့် အင်္ဂါရပ်များကို သုံးခွင့် ပြုသည်။"</string>
     <string name="permlab_readFrameBuffer" msgid="6690504248178498136">"frame bufferအားဖတ်ခြင်း"</string>
-    <string name="permdesc_readFrameBuffer" msgid="4937405521809454680">"appအား ဘောင် စပ်ကြား နေရာ ထဲက အကြောင်းအရာကို ဖတ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_readFrameBuffer" msgid="4937405521809454680">"appအား ဘောင် စပ်ကြား နေရာ ထဲက အကြောင်းအရာကို ဖတ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_accessInputFlinger" msgid="5348635270689553857">"InputFlinger အား သုံးခွင့်"</string>
     <string name="permdesc_accessInputFlinger" msgid="2104864941201226616">"အပလီကေးရှင်းကို InputFlinger low-level features ပေးသုံးခြင်း"</string>
     <string name="permlab_configureWifiDisplay" msgid="5595661694746742168">"ဝိုင်ဖိုင်ဖြင့် ပြသမှုအား ပြင်ဆင်ရန်"</string>
@@ -529,23 +527,23 @@
     <string name="permdesc_controlWifiDisplay" msgid="4543912292681826986">"အပလီကေးရှင်းအား စက်ရဲ့ အနိမ့်ပိုင်းမှာ ရှိသော ဝိုင်ဖိုင် ပြသမှုအား ထိန်းချုပ်ခွင့်ပြုပါ"</string>
     <string name="permlab_captureAudioOutput" msgid="6857134498402346708">"အသံထွက်မှု အား ဖမ်းယူခြင်း"</string>
     <string name="permdesc_captureAudioOutput" msgid="6210597754212208853">"အပလီကေးရှင်းကို အသံဖမ်းခွင့် လမ်းကြောင်းလွှဲခွင့်များ ခွင့်ပြုခြင်း"</string>
-    <string name="permlab_captureAudioHotword" msgid="1890553935650349808">"အသံဖြင့်ညွှန်ကြားရန်အတိုကောက်များအား ဖမ်းယူ သိနိုင်မှု"</string>
-    <string name="permdesc_captureAudioHotword" msgid="9151807958153056810">"အပလီကေးရှင်းကို အသံဖြင့်ညွှန်းကြားရန်အတိုကောက်များ အတွက် အသံဖမ်းယူခွင့်ပြုခြင်း။ နောက်ကွယ်မှာ ဖြစ်နိုင်ပေမယ့် တခြားအသံဖမ်းခြင်းများ (ဥပမာ ရုပ်သံဖမ်းစက်) များကို ပိတ်ပင်မှု မဖြစ်စေပါ"</string>
+    <string name="permlab_captureAudioHotword" msgid="1890553935650349808">"အသံဖြင့်ညွှန်ကြားရန်အတိုကောက်များအား ဖမ်းယူ သိနိုင်မှု"</string>
+    <string name="permdesc_captureAudioHotword" msgid="9151807958153056810">"အပလီကေးရှင်းကို အသံဖြင့်ညွှန်းကြားရန်အတိုကောက်များ အတွက် အသံဖမ်းယူခွင့်ပြုခြင်း။ နောက်ကွယ်မှာ ဖြစ်နိုင်ပေမယ့် တခြားအသံဖမ်းခြင်းများ (ဥပမာ ရုပ်သံဖမ်းစက်) များကို ပိတ်ပင်မှု မဖြစ်စေပါ"</string>
     <string name="permlab_modifyAudioRouting" msgid="7738060354490807723">"အသံ လမ်းကြောင်း"</string>
-    <string name="permdesc_modifyAudioRouting" msgid="7205731074267199735">"အက်ပ်အား အသံ လမ်းကြောင်းကို တိုက်ရိုက် ထိန်းချုပ်ခွင့် နှင့် အသံ မူဝါဒ ဆုံးဖြတ်ချက်များကို ကျော်ပြီးလုပ်ပိုင်ခွင့် ပေးသည်။"</string>
+    <string name="permdesc_modifyAudioRouting" msgid="7205731074267199735">"အက်ပ်အား အသံ လမ်းကြောင်းကို တိုက်ရိုက် ထိန်းချုပ်ခွင့် နှင့် အသံ မူဝါဒ ဆုံးဖြတ်ချက်များကို ကျော်ပြီးလုပ်ပိုင်ခွင့် ပေးသည်။"</string>
     <string name="permlab_captureVideoOutput" msgid="2246828773589094023">"ရုပ်သံလွှင့်မှုအား ဖမ်းယူရန်"</string>
     <string name="permdesc_captureVideoOutput" msgid="359481658034149860">"အပလီကေးရှင်းကို ရုပ်သံဖမ်းခွင့် လမ်းကြောင်းလွှဲခွင့်များ ခွင့်ပြုခြင်း"</string>
     <string name="permlab_captureSecureVideoOutput" msgid="7815398969303382016">"လုံခြုံသော ရုပ်သံလွှင့်မှုအား ဖမ်းယူရန်"</string>
     <string name="permdesc_captureSecureVideoOutput" msgid="2779793064709350289">"အပလီကေးရှင်းကို လုံးခြုံစိတ်ချရသော အသံဖမ်းခြင်း လမ်းကြောင်းလွှဲခွင့်များ ခွင့်ပြုခြင်း"</string>
     <string name="permlab_mediaContentControl" msgid="8749790560720562511">"မီဒီယာ ပလေးဘက် နဲ့ မက်တာဒေတာ အသုံးပြုခွင့် အား ထိန်းချုပ်ခြင်း"</string>
     <string name="permdesc_mediaContentControl" msgid="1637478200272062">"အပလီကေးရှင်းအား ရုပ်သံ ပြန်လည်ပြသမှု နှင့် မီဒီယာ အချက်အလက် (ခေါင်းစဉ်၊ ရေးသားသူ) များကို ထိန်းချုပ်ခွင့် ပေးခြင်း"</string>
-    <string name="permlab_modifyAudioSettings" msgid="6095859937069146086">"သင့်အသံအပြင်အဆင်အားပြောင်းခြင်း"</string>
+    <string name="permlab_modifyAudioSettings" msgid="6095859937069146086">"သင့်အသံအပြင်အဆင်အားပြောင်းခြင်း"</string>
     <string name="permdesc_modifyAudioSettings" msgid="3522565366806248517">"အပလီကေးရှင်းအား အသံအတိုးအကျယ်နှင့် အထွက်ကို မည်သည့်စပီကာကို သုံးရန်စသည်ဖြင့် စက်တစ်ခုလုံးနှင့်ဆိုင်သော အသံဆိုင်ရာ ဆက်တင်များ ပြင်ဆင်ခွင့် ပြုရန်"</string>
     <string name="permlab_recordAudio" msgid="3876049771427466323">"အသံဖမ်းခြင်း"</string>
-    <string name="permdesc_recordAudio" msgid="4906839301087980680">"အပလီကေးရှင်းအား မိုက်ခရိုဖုန်းဖြင့် အသံသွင်းခွင့် ပြုပါ။ အပလီကေးရှင်းအနေဖြင့် သင့် ခွင့်ပြုချက် မပါပဲ အချိန်မရွေး အသံဖမ်းနိုင်ပါမည်"</string>
+    <string name="permdesc_recordAudio" msgid="4906839301087980680">"အပလီကေးရှင်းအား မိုက်ခရိုဖုန်းဖြင့် အသံသွင်းခွင့် ပြုပါ။ အပလီကေးရှင်းအနေဖြင့် သင့် ခွင့်ပြုချက် မပါပဲ အချိန်မရွေး အသံဖမ်းနိုင်ပါမည်"</string>
     <string name="permlab_sim_communication" msgid="1180265879464893029">"ဆင်းမ်ကဒ် ဆက်သွယ်ရေး"</string>
     <string name="permdesc_sim_communication" msgid="5725159654279639498">"အပလီကေးရှင်းအား ဆင်းမ်ကဒ်ဆီသို့ အမိန့်များ ပေးပို့ခွင့် ပြုခြင်း။ ဒီ ခွင့်ပြုမှုဟာ အန်တရယ် အလွန် ရှိပါသည်။."</string>
-    <string name="permlab_camera" msgid="3616391919559751192">"ဓါတ်ပုံနှင့်ဗွီဒီယိုရိုက်ခြင်း"</string>
+    <string name="permlab_camera" msgid="3616391919559751192">"ဓါတ်ပုံနှင့်ဗွီဒီယိုရိုက်ခြင်း"</string>
     <string name="permdesc_camera" msgid="8497216524735535009">"အပလီကေးရှင်းအား အလိုအလျောက် ဓာတ်ပုံရိုက်ခွင့်၊ ဗီဒီယို ရိုက်ကူးခွင့် ပြုပါ။ ဒီခွင့်ပြုချက်က အပလီကေးရှင်းကို အချိန်မရွေး ကင်မရာအား ခွင့်ပြုချက် မလိုအပ်ပဲ သုံးခွင့်ပြုပါသည်။"</string>
     <string name="permlab_cameraDisableTransmitLed" msgid="2651072630501126222">"ထုတ်လွှင့်မှုပြ အချက်ပေး မီးအား ကင်မရာ သုံးနေစဉ် ပိတ်ရန်"</string>
     <string name="permdesc_cameraDisableTransmitLed" msgid="4764585465480295341">"ကြိုတင်သွင်းထားသော စစ်စတန် စနစ်တစ်ခုကို ကင်မရာ သုံးနေသော မီးအား ထိန်းချုပ်ခွင့်ပေးခြင်း"</string>
@@ -555,131 +553,133 @@
     <string name="permdesc_brick" product="default" msgid="5788903297627283099">"appအား ဖုန်း တစ်ခုလုံးကို ထာဝရ ပိတ်ပစ်ခွင် ပြုသည်။ ၎င်းမှာ အထူး အန္တရာယ် ရှိနိုင်သည်။"</string>
     <string name="permlab_reboot" product="tablet" msgid="3436634972561795002">"တက်ပလက် မဖြစ်မနေပြန်လည်စတင်လုပ်ဆောင်ရန်"</string>
     <string name="permlab_reboot" product="default" msgid="2898560872462638242">"ဖုန်းကို မဖြစ်မနေပြန်လည်စတင်လုပ်ဆောင်ရန်"</string>
-    <string name="permdesc_reboot" product="tablet" msgid="8172056180063700741">"appအား တက်ဘလက်ကို ပြန်စတင်ရန် အတင်းအကြပ် ပြုလုပ်ခွင့် ပြုပါသည်။"</string>
-    <string name="permdesc_reboot" product="default" msgid="5326008124289989969">"appအား ဖုန်းကို ပြန်စတင်ရန် အတင်းအကြပ် ပြုလုပ်ခွင့် ပြုပါသည်။"</string>
+    <string name="permdesc_reboot" product="tablet" msgid="8172056180063700741">"appအား တက်ဘလက်ကို ပြန်စတင်ရန် အတင်းအကြပ် ပြုလုပ်ခွင့် ပြုပါသည်။"</string>
+    <string name="permdesc_reboot" product="default" msgid="5326008124289989969">"appအား ဖုန်းကို ပြန်စတင်ရန် အတင်းအကြပ် ပြုလုပ်ခွင့် ပြုပါသည်။"</string>
     <string name="permlab_mount_unmount_filesystems" product="nosdcard" msgid="2927361537942591841">"USBသိုလှောင်ရာဖိုင်စနစ်အား အသုံးပြုခွင့်ပေးရန်"</string>
     <string name="permlab_mount_unmount_filesystems" product="default" msgid="4402305049890953810">"SDကတ် ဖိုင် စနစ် အား အသုံးပြုခွင့်ပေးရန်"</string>
-    <string name="permdesc_mount_unmount_filesystems" msgid="1829290701658992347">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်း၏ ဖိုင် စနစ်များကို တပ်ဆင်ခြင်း နှင့် ဖြုတ်ခြင်းကို ပြုလုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_mount_unmount_filesystems" msgid="1829290701658992347">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်း၏ ဖိုင် စနစ်များကို တပ်ဆင်ခြင်း နှင့် ဖြုတ်ခြင်းကို ပြုလုပ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_mount_format_filesystems" product="nosdcard" msgid="6227819582624904972">"USBသိုလှောင်ရာအား ဖျက်ရန်"</string>
     <string name="permlab_mount_format_filesystems" product="default" msgid="262582698639274056">"SDကတ်အား ဖျက်ရန်"</string>
-    <string name="permdesc_mount_format_filesystems" msgid="8784268246779198627">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်းကို ပုံစံပြန်ချခွင့် ပြုသည်။"</string>
+    <string name="permdesc_mount_format_filesystems" msgid="8784268246779198627">"appအား ဖယ်ရှားရနိုင်သော သိုလှောင်ခန်းကို ပုံစံပြန်ချခွင့် ပြုသည်။"</string>
     <string name="permlab_asec_access" msgid="3411338632002193846">"စက်တွင်းသိုလှောင်ခြင်း၏အချက်အလက်ရယူရန်"</string>
-    <string name="permdesc_asec_access" msgid="3094563844593878548">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းထဲက အချက်အလက်များကို ရယူခွင့် ပြုသည်။"</string>
+    <string name="permdesc_asec_access" msgid="3094563844593878548">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းထဲက အချက်အလက်များကို ရယူခွင့် ပြုသည်။"</string>
     <string name="permlab_asec_create" msgid="6414757234789336327">"စက်တွင်းသိုလှောင်ခြင်း ပြုလုပ်ဖန်တီးရန်"</string>
-    <string name="permdesc_asec_create" msgid="4558869273585856876">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို ဖန်တီးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_asec_create" msgid="4558869273585856876">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို ဖန်တီးခွင့် ပြုသည်။"</string>
     <string name="permlab_asec_destroy" msgid="526928328301618022">"စက်တွင်းသိုလှောင်ခြင်းအား ဖျက်စီးရန်"</string>
-    <string name="permdesc_asec_destroy" msgid="7218749286145526537">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို ဖျက်ပစ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_asec_destroy" msgid="7218749286145526537">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို ဖျက်ပစ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_asec_mount_unmount" msgid="8877998101944999386">"အတွင်းပိုင်း သိုလ​ှောင်ခန်းကို တပ်ဆင်/ဖြုတ်ခြင်း"</string>
-    <string name="permdesc_asec_mount_unmount" msgid="3451360114902490929">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို တပ်ဆင်/ဖြုတ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_asec_mount_unmount" msgid="3451360114902490929">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို တပ်ဆင်/ဖြုတ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_asec_rename" msgid="7496633954080472417">"စက်တွင်းသိုလှောင်မှုအားအမည်ပြောင်းခြင်း"</string>
-    <string name="permdesc_asec_rename" msgid="1794757588472127675">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို အမည်ပြောင်းခွင့် ပြုသည်။"</string>
+    <string name="permdesc_asec_rename" msgid="1794757588472127675">"appအား အတွင်းပိုင်း သိုလှောင်ခန်းကို အမည်ပြောင်းခွင့် ပြုသည်။"</string>
     <string name="permlab_vibrate" msgid="7696427026057705834">"တုန်ခုန်မှုအား ထိန်းချုပ်ခြင်း"</string>
-    <string name="permdesc_vibrate" msgid="6284989245902300945">"appအား တုန်ခါစက်ကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_vibrate" msgid="6284989245902300945">"appအား တုန်ခါစက်ကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_flashlight" msgid="2155920810121984215">"ဓါတ်မီးအား ထိန်းသိမ်းရန်"</string>
-    <string name="permdesc_flashlight" msgid="6522284794568368310">"appအား ကား ဖလက်ရှမီးကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_manageUsb" msgid="1113453430645402723">"USB စက်ပစ္စည်းများအတွက် ကြိုက်နှစ်သက်ရာနှင့်ခွင့်ပြုချက်များကို စီမံရန်"</string>
-    <string name="permdesc_manageUsb" msgid="7776155430218239833">"appအား USB ကိရိယာများ၏ နှစ်ခြိုက်မှုများ နှင့် ခွင့်ပြုချက်များကို စီမံခန့်ခွဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_flashlight" msgid="6522284794568368310">"appအား ကား ဖလက်ရှမီးကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_manageUsb" msgid="1113453430645402723">"USB စက်ပစ္စည်းများအတွက် ကြိုက်နှစ်သက်ရာနှင့်ခွင့်ပြုချက်များကို စီမံရန်"</string>
+    <string name="permdesc_manageUsb" msgid="7776155430218239833">"appအား USB ကိရိယာများ၏ နှစ်ခြိုက်မှုများ နှင့် ခွင့်ပြုချက်များကို စီမံခန့်ခွဲခွင့် ပြုသည်။"</string>
     <string name="permlab_accessMtp" msgid="4953468676795917042">"MTPပရိုတိုကောအား စတင်ရန်"</string>
-    <string name="permdesc_accessMtp" msgid="6532961200486791570">"MTP USBပရိုတိုကော အကောင်အထည်ဖော်ဆောင်ရွက်ရန် kernel MTPဒရိုင်ဘာအား သုံးစွဲခွင့်ပြုမည်။"</string>
+    <string name="permdesc_accessMtp" msgid="6532961200486791570">"MTP USBပရိုတိုကော အကောင်အထည်ဖော်ဆောင်ရွက်ရန် kernel MTPဒရိုင်ဘာအား သုံးစွဲခွင့်ပြုမည်။"</string>
     <string name="permlab_hardware_test" msgid="4148290860400659146">"စက်ပစ္စည်းများကိုစမ်းသပ်ခြင်း"</string>
-    <string name="permdesc_hardware_test" msgid="6597964191208016605">"appအယဒ ဟာ့ဒ်ဝဲကို စမ်းသပ်ရန် ရည်ရွယ်ချက်ဖြင့် သာမည အစိတ်အပိုင်း အမျိုးမျိုးကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_hardware_test" msgid="6597964191208016605">"appအယဒ ဟာ့ဒ်ဝဲကို စမ်းသပ်ရန် ရည်ရွယ်ချက်ဖြင့် သာမည အစိတ်အပိုင်း အမျိုးမျိုးကို ထိန်းချုပ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_callPhone" msgid="3925836347681847954">"ဖုန်းနံပါတ်များကိုတိုက်ရိုက်ခေါ်ဆိုခြင်း"</string>
     <string name="permdesc_callPhone" msgid="3740797576113760827">"အပလီကေးရှင်းအား အလိုအလျောက် ဖုန်းခေါ်ခွင့် ပြုပါ။ မလိုအပ်သော ဖုန်းခ များ ဖြစ်ပေါ်နိုင်ပါသည်။ ဒီခွင့်ပြုခြင်းမှာ အရေးပေါ်ဖုန်းခေါ်ခြင်း မပါဝင်ပါ။ သံသယဖြစ်စရာ အပလီကေးရှင်းများက သင့်မသိပဲ ဖုန်းခေါ်ခြင်းဖြင့် ဖုန်းခ ပိုမိုကျနိုင်ပါသည်။"</string>
-    <string name="permlab_callPrivileged" msgid="4198349211108497879">"မည်သည့်ဖုန်းနံပါတ်မဆိုအားတိုက်ရိုက်ခေါ်ဆိုခြင်း"</string>
-    <string name="permdesc_callPrivileged" msgid="1689024901509996810">"appအား ဘယ် ဖုန်း နံပါတ်ကိုမဆို၊ အရေးပေါ် နံပါတ်များ အပါအဝင်ကို၊ သင်၏ စွက်ဖက်မှု မပါဘဲ၊ ခေါ်ဆိုခွင့် ပြုသည်။ အကြံအဖန် appများက အရေးပေါ် ဝန်ဆောင်မှုများ ထံသို့ မလိုလားအပ်သော သို့မဟုတ် တရားမဝင်သော ခေါ်ဆိုမှုများ ပြုလုပ်လာနိုင်ကြမည်။"</string>
+    <string name="permlab_callPrivileged" msgid="4198349211108497879">"မည်သည့်ဖုန်းနံပါတ်မဆိုအားတိုက်ရိုက်ခေါ်ဆိုခြင်း"</string>
+    <string name="permdesc_callPrivileged" msgid="1689024901509996810">"appအား ဘယ် ဖုန်း နံပါတ်ကိုမဆို၊ အရေးပေါ် နံပါတ်များ အပါအဝင်ကို၊ သင်၏ စွက်ဖက်မှု မပါဘဲ၊ ခေါ်ဆိုခွင့် ပြုသည်။ အကြံအဖန် appများက အရေးပေါ် ဝန်ဆောင်မှုများ ထံသို့ မလိုလားအပ်သော သို့မဟုတ် တရားမဝင်သော ခေါ်ဆိုမှုများ ပြုလုပ်လာနိုင်ကြမည်။"</string>
     <string name="permlab_performCdmaProvisioning" product="tablet" msgid="4842576994144604821">"CDMAတက်ပလက်အစသတ်မှတ်ခြင်းကို တိုက်ရိုက်စတင်ရန်"</string>
     <string name="permlab_performCdmaProvisioning" product="default" msgid="5604848095315421425">"CDMAဖုန်း အစသတ်မှတ်ခြင်းကို တိုက်ရိုက်စတင်ရန်"</string>
-    <string name="permdesc_performCdmaProvisioning" msgid="1994193538802314186">"appအား CDMA အတွက် စီမံလုပ်ကိုင်မှုကို စတင်ခွင့် ပြုသည်။ ကြံဖန် appများက မလိုအပ်ဘဲနှင့် CDMA အတွက် စီမံလုပ်ကိုင်မှုကို စတင်နိုင်ကြသည်။"</string>
-    <string name="permlab_locationUpdates" msgid="7785408253364335740">"တည်နေရာအဆင့်မြှင့်ခြင်းသတိပေးချက်အားထိန်းချုပ်ရန်"</string>
-    <string name="permdesc_locationUpdates" msgid="1120741557891438876">"appအား ရေဒီယိုထံမှ တည်နေရာ မွမ်းမံမှု အကြောင်းကြားစာများကို ပိတ်/ဖွင့်ခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်နိုင်ပါ။"</string>
+    <string name="permdesc_performCdmaProvisioning" msgid="1994193538802314186">"appအား CDMA အတွက် စီမံလုပ်ကိုင်မှုကို စတင်ခွင့် ပြုသည်။ ကြံဖန် appများက မလိုအပ်ဘဲနှင့် CDMA အတွက် စီမံလုပ်ကိုင်မှုကို စတင်နိုင်ကြသည်။"</string>
+    <string name="permlab_locationUpdates" msgid="7785408253364335740">"တည်နေရာအဆင့်မြှင့်ခြင်းသတိပေးချက်အားထိန်းချုပ်ရန်"</string>
+    <string name="permdesc_locationUpdates" msgid="1120741557891438876">"appအား ရေဒီယိုထံမှ တည်နေရာ မွမ်းမံမှု အကြောင်းကြားစာများကို ပိတ်/ဖွင့်ခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်နိုင်ပါ။"</string>
     <string name="permlab_checkinProperties" msgid="7855259461268734914">"ချက်ခ်အင်ဂုဏ်သတ္တိများအား ဝင်ရောက်ချိတ်ဆက်ခြင်း"</string>
-    <string name="permdesc_checkinProperties" msgid="4024526968630194128">"appအား စစ်ဆေးရေး ဝန်ဆောင်မှုက အာပ်လုဒ် လုပ်ခဲ့သည့် အရည်အချင်းများကို ရယူသုံးလျက် ရေး/ဖတ် ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
+    <string name="permdesc_checkinProperties" msgid="4024526968630194128">"appအား စစ်ဆေးရေး ဝန်ဆောင်မှုက အာပ်လုဒ် လုပ်ခဲ့သည့် အရည်အချင်းများကို ရယူသုံးလျက် ရေး/ဖတ် ခွင့် ပြုသည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
     <string name="permlab_bindGadget" msgid="776905339015863471">"ဝဒ်ဂျက်အား ရွေးရန်"</string>
-    <string name="permdesc_bindGadget" msgid="8261326938599049290">"appအား မည်သည့် ဝီဂျက်ကို မည်သည့် app သုံးနိုင်ကြောင်းကို စနစ်များ ပြောခွင့် ပေးသည်။ ယင်း ခွင့်ပြုချက်မျိုး ရှိသော appသည် အခြား appများအား ကိုယ်ရေး ဒေတာများကို ရယူသုံးခွင့် ပေးနိုင်သည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
+    <string name="permdesc_bindGadget" msgid="8261326938599049290">"appအား မည်သည့် ဝီဂျက်ကို မည်သည့် app သုံးနိုင်ကြောင်းကို စနစ်များ ပြောခွင့် ပေးသည်။ ယင်း ခွင့်ပြုချက်မျိုး ရှိသော appသည် အခြား appများအား ကိုယ်ရေး ဒေတာများကို ရယူသုံးခွင့် ပေးနိုင်သည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
     <string name="permlab_modifyPhoneState" msgid="8423923777659292228">"ဖုန်းအခြေအနေအား မွမ်းမံခြင်း"</string>
-    <string name="permdesc_modifyPhoneState" msgid="1029877529007686732">"appအား ဖုန်း၏ အင်္ဂါရပ်များကို ထိန်းချုပ်ခွင့် ပြုသည်။ ယင်း ခွင့်ပြုချက် ရှိသော appသည် ကွန်ရက်များကို ပြောင်းလဲခြင်း၊ ဖုန်း ရေဒီယိုကို ပိတ်ဖွင့်ခြင်း နှင့် အလားတူများကို သင့်ကို အကြောင်းတောင် မကြားဘဲ ပြုလုပ်နိုင်သည်။"</string>
+    <string name="permdesc_modifyPhoneState" msgid="1029877529007686732">"appအား ဖုန်း၏ အင်္ဂါရပ်များကို ထိန်းချုပ်ခွင့် ပြုသည်။ ယင်း ခွင့်ပြုချက် ရှိသော appသည် ကွန်ရက်များကို ပြောင်းလဲခြင်း၊ ဖုန်း ရေဒီယိုကို ပိတ်ဖွင့်ခြင်း နှင့် အလားတူများကို သင့်ကို အကြောင်းတောင် မကြားဘဲ ပြုလုပ်နိုင်သည်။"</string>
     <string name="permlab_readPhoneState" msgid="9178228524507610486">"ဖုန်းရဲ့ အခြေအနေ နှင့် အမှတ်သညာအား ဖတ်ခြင်း"</string>
     <string name="permdesc_readPhoneState" msgid="1639212771826125528">"အပလီကေးရှင်းအား ဖုန်းရဲ့ စွမ်းဆောင်ချက်များအား သုံးခွင့်ပြုပါ။ အပလီကေးရှင်းအနေဖြင့် ဖုန်းနံပါတ်၊ စက်နံပါတ်၊ ဖုန်းခေါ်နေမှု ရှိမရှိနှင့် တဖက်မှ ဖုန်းနံပါတ် များအား သိရှိနိုင်ပါသည်"</string>
     <string name="permlab_readPrecisePhoneState" msgid="5476483020282007597">"ဖုန်းရဲ့ တိကျသော အခြေအနေအား ဖတ်ရှုခြင်း"</string>
     <string name="permdesc_readPrecisePhoneState" msgid="6648009074263855418">"အပလီကေးရှင်းအား ဖုန်းရဲ့ အခြေအနေအတိအကျကို ယူသုံးခွင့် ပြုခြင်း။. ဒီအခွင့်အရေးက အပလီကေးရှင်း ကို ဖုန်းခေါ်ဆိုမှု အခြေအနေ၊ လက်ရှိ ဖုန်းခေါ်နေမှု ရှိမရှိ၊ ဒါမှမဟုတ် နောက်ခံမှာ ဖုန်းခေါ်နေမှု၊ ဖုန်းခေါ်ဆို​အောင်မြင်မှု၊ ဒေတာဆက်သွယ်မှု အခြေအနေ နဲ့ မအောင်မြင်မှု တွေကို သိရှိစေပါသည်။"</string>
     <string name="permlab_wakeLock" product="tablet" msgid="1531731435011495015">"တက်ပလက်အား ပိတ်ခြင်းမှ ကာကွယ်ခြင်း"</string>
     <string name="permlab_wakeLock" product="default" msgid="573480187941496130">"ဖုန်းအနားယူခြင်းမပြုလုပ်စေရန်"</string>
-    <string name="permdesc_wakeLock" product="tablet" msgid="7311319824400447868">"appအား တက်ဘလက်ကို အနားမယူနိုင်အောင် ဟန့်တားခွင့် ပြုသည်။"</string>
-    <string name="permdesc_wakeLock" product="default" msgid="8559100677372928754">"appအား ဖုန်းကို အနားမယူနိုင်အောင် ဟန့်တားခွင့် ပြုသည်။"</string>
+    <string name="permdesc_wakeLock" product="tablet" msgid="7311319824400447868">"appအား တက်ဘလက်ကို အနားမယူနိုင်အောင် ဟန့်တားခွင့် ပြုသည်။"</string>
+    <string name="permdesc_wakeLock" product="default" msgid="8559100677372928754">"appအား ဖုန်းကို အနားမယူနိုင်အောင် ဟန့်တားခွင့် ပြုသည်။"</string>
     <string name="permlab_transmitIr" msgid="7545858504238530105">"အနီအောက်ရောင်ခြည် ထုတ်လွှတ်ခြင်း"</string>
     <string name="permdesc_transmitIr" product="tablet" msgid="5358308854306529170">"အပလီကေးရှင်းအား တက်ဘလက်ရဲ့ အနီအောက်ရောင်ခြည် ထုတ်လွှတ်ခြင်းအား သုံးခွင့်ပေးခြင်း"</string>
     <string name="permdesc_transmitIr" product="default" msgid="7957763745020300725">"အပလီကေးရှင်းအား ဖုန်းရဲ့ အနီအောက်ရောင်ခြည် ထုတ်လွှတ်ခြင်းအား သုံးခွင့်ပေးခြင်း"</string>
-    <string name="permlab_devicePower" product="tablet" msgid="2787034722616350417">"တက်ပလက်ဖွင့် (သို့)ပိတ်"</string>
-    <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ဖုန်းဖွင့် (သို့)ပိတ်"</string>
-    <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"appအား တက်ဘလက်ကို ဖွင့် သို့မဟုတ် ပိတ်ခွင့် ပြုသည်။"</string>
-    <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"appအား ဖုန်းကို ဖွင့် သို့မဟုတ် ပိတ်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_factoryTest" msgid="3715225492696416187">"စက်ရုံစမ်းသပ်စနစ်ဖြင့် အလုပ်လုပ်ဆောင်စေရန်"</string>
-    <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ထုတ်လုပ်သူ၏အနိမ့်စားအဆင့်စမ်းသပ်မှုအနေဖြင့်လုပ်ဆောင်စေမည် တက်ပလက်စက်အား လုံးဝဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုမည်။ တက်ပလက်မှာ ထုတ်လုပ်သူ၏စမ်းသပ်မှုစနစ်ဖြင့် လုပ်ဆောင်နေစဥ်သာ ရရှိမည်။"</string>
-    <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ထုတ်လုပ်သူ၏အနိမ့်စားအဆင့်စမ်းသပ်မှုအနေဖြင့်လုပ်ဆောင်စေမည် ဖုန်းစက်အား လုံးဝဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုမည် ဖုန်းမှာ ထုတ်လုပ်သူ၏စမ်းသပ်မှုစနစ်ဖြင့် လုပ်ဆောင်နေစဥ်သာ ရရှိမည်"</string>
+    <string name="permlab_devicePower" product="tablet" msgid="2787034722616350417">"တက်ပလက်ဖွင့် (သို့)ပိတ်"</string>
+    <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ဖုန်းဖွင့် (သို့)ပိတ်"</string>
+    <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"appအား တက်ဘလက်ကို ဖွင့် သို့မဟုတ် ပိတ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"appအား ဖုန်းကို ဖွင့် သို့မဟုတ် ပိတ်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"မျက်နှာပြင်မှိန်ချိန် ပြန်ညှိရန်"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"မျက်နှာပြင်မှိန်ချိန် ပြန်ညှိရန် app ကိုခွင့်ပြုပါ။"</string>
+    <string name="permlab_factoryTest" msgid="3715225492696416187">"စက်ရုံစမ်းသပ်စနစ်ဖြင့် အလုပ်လုပ်ဆောင်စေရန်"</string>
+    <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ထုတ်လုပ်သူ၏အနိမ့်စားအဆင့်စမ်းသပ်မှုအနေဖြင့်လုပ်ဆောင်စေမည် တက်ပလက်စက်အား လုံးဝဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုမည်။ တက်ပလက်မှာ ထုတ်လုပ်သူ၏စမ်းသပ်မှုစနစ်ဖြင့် လုပ်ဆောင်နေစဥ်သာ ရရှိမည်။"</string>
+    <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ထုတ်လုပ်သူ၏အနိမ့်စားအဆင့်စမ်းသပ်မှုအနေဖြင့်လုပ်ဆောင်စေမည် ဖုန်းစက်အား လုံးဝဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုမည် ဖုန်းမှာ ထုတ်လုပ်သူ၏စမ်းသပ်မှုစနစ်ဖြင့် လုပ်ဆောင်နေစဥ်သာ ရရှိမည်"</string>
     <string name="permlab_setWallpaper" msgid="6627192333373465143">"နောက်ခံအား သတ်မှတ်ရန်"</string>
-    <string name="permdesc_setWallpaper" msgid="7373447920977624745">"appအား စနစ် နောက်ခံပုံကို သတ်မှတ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_setWallpaper" msgid="7373447920977624745">"appအား စနစ် နောက်ခံပုံကို သတ်မှတ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_setWallpaperHints" msgid="3278608165977736538">"နောက်ခံပုံအား အရွယ်အစားပြောင်းရန်"</string>
-    <string name="permdesc_setWallpaperHints" msgid="8235784384223730091">"appအား စနစ် နောက်ခံပုံ ဆိုက်ဆိုင်ရာ ညွှန်းချက်များကို သတ်မှတ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_setWallpaperHints" msgid="8235784384223730091">"appအား စနစ် နောက်ခံပုံ ဆိုက်ဆိုင်ရာ ညွှန်းချက်များကို သတ်မှတ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_masterClear" msgid="2315750423139697397">"စနစ်အား မူလစက်ရုံအခြအေနေထံ ပြန်လည်သတ်မှတ်ရန်"</string>
-    <string name="permdesc_masterClear" msgid="3665380492633910226">"appအား စနစ်ကို စက်ရုံအတိုင်း လုံးဝ ပြန်ညှိခြင်း၊ ဒေတာများ၊ စီစင်ဖွဲ့စည်းမှု နှင့် တပ်ဆင်ပြီး appများ အားလုံးကို ဖျက်ပစ်ခြင်း လုပ်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_masterClear" msgid="3665380492633910226">"appအား စနစ်ကို စက်ရုံအတိုင်း လုံးဝ ပြန်ညှိခြင်း၊ ဒေတာများ၊ စီစင်ဖွဲ့စည်းမှု နှင့် တပ်ဆင်ပြီး appများ အားလုံးကို ဖျက်ပစ်ခြင်း လုပ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_setTime" msgid="2021614829591775646">"အချိန်သတ်မှတ်ရန်"</string>
-    <string name="permdesc_setTime" product="tablet" msgid="1896341438151152881">"appအား တက်ဘလက်၏ နာရီ အချိန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
-    <string name="permdesc_setTime" product="default" msgid="1855702730738020">"appအား ဖုန်း၏ နာရီ အချိန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_setTime" product="tablet" msgid="1896341438151152881">"appအား တက်ဘလက်၏ နာရီ အချိန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_setTime" product="default" msgid="1855702730738020">"appအား ဖုန်း၏ နာရီ အချိန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
     <string name="permlab_setTimeZone" msgid="2945079801013077340">"အချိန်ဇုန်းအား သတ်မှတ်ခြင်း"</string>
-    <string name="permdesc_setTimeZone" product="tablet" msgid="1676983712315827645">"appအား တက်ဘလက်၏ နာရီ ဇုန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
-    <string name="permdesc_setTimeZone" product="default" msgid="4499943488436633398">"appအား ဖုန်း၏ နာရီ ဇုန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
-    <string name="permlab_accountManagerService" msgid="4829262349691386986">"AccountManagerServiceအနေဖြင့်ပြုမူရန်"</string>
+    <string name="permdesc_setTimeZone" product="tablet" msgid="1676983712315827645">"appအား တက်ဘလက်၏ နာရီ ဇုန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_setTimeZone" product="default" msgid="4499943488436633398">"appအား ဖုန်း၏ နာရီ ဇုန်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permlab_accountManagerService" msgid="4829262349691386986">"AccountManagerServiceအနေဖြင့်ပြုမူရန်"</string>
     <string name="permdesc_accountManagerService" msgid="1948455552333615954">"အပလီကေးရှင်းအား အကောင့် စစ်ဆေးသော အရာများအား ဖုန်းခေါ်ခွင့်ပြုပါ"</string>
     <string name="permlab_getAccounts" msgid="1086795467760122114">"စက်ပေါ်မှာ အကောင့်များ ရှာဖွေခြင်း"</string>
     <string name="permdesc_getAccounts" product="tablet" msgid="2741496534769660027">"အပလီကေးရှင်းအား တက်ဘလက်မှ သိရှိထားသော အကောင့်များအား ရယူခွင့်ပေးပါ။ ဒီထဲတွင် သင် ထည့်သွင်းထားသော အပလီကေးရှင်းများမှတဆင့် ပြုလုပ်ထားသော အကောင့်များပါ ပါဝင်နိုင်ပါသည်။"</string>
     <string name="permdesc_getAccounts" product="default" msgid="3448316822451807382">"အပလီကေးရှင်းအား ဖုန်းမှ သိရှိထားသော အကောင့်စာရင်းများအား ရယူခွင့်ပေးပါ။ ဒီထဲတွင် သင် ထည့်သွင်းထားသော အပလီကေးရှင်းများမှတဆင့် ပြုလုပ်ထားသော အကောင့်များပါ ပါဝင်နိုင်ပါသည်။"</string>
     <string name="permlab_authenticateAccounts" msgid="5265908481172736933">"အကောင့်များ ဖန်တီးရန်နှင့် စကားဝှက်များ ရွေးချယ်ရန်"</string>
-    <string name="permdesc_authenticateAccounts" msgid="5472124296908977260">"appအား အကောင့် မန်နေဂျာ၏ အကောင့် စိစစ်ရေး လုပ်နိုင်စွမ်းများကို၊ အကောင့်များ ဖန်တီးခြင်း နှင့် ၎င်းတို့၏ စကားဝှက်များကို ရယူခြင်း နှင့် သတ်မှတ်ခြင်း အပါအဝင်ကို၊ အသုံးချခွင့် ပြုသည်။"</string>
+    <string name="permdesc_authenticateAccounts" msgid="5472124296908977260">"appအား အကောင့် မန်နေဂျာ၏ အကောင့် စိစစ်ရေး လုပ်နိုင်စွမ်းများကို၊ အကောင့်များ ဖန်တီးခြင်း နှင့် ၎င်းတို့၏ စကားဝှက်များကို ရယူခြင်း နှင့် သတ်မှတ်ခြင်း အပါအဝင်ကို၊ အသုံးချခွင့် ပြုသည်။"</string>
     <string name="permlab_manageAccounts" msgid="4983126304757177305">"အကောင့်များအား ထည့် သို့ ထုတ်ပါ"</string>
-    <string name="permdesc_manageAccounts" msgid="8698295625488292506">"appအား အကောင့်များ ထည့်ခြင်း နှင့် ဖယ်ရှားခြင်း နှင့် ၎င်းတို့၏ စကားဝှက်များကို ဖျက်ခြင်းလို လုပ်ရပ်များကို လုပ်ကိုင်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_manageAccounts" msgid="8698295625488292506">"appအား အကောင့်များ ထည့်ခြင်း နှင့် ဖယ်ရှားခြင်း နှင့် ၎င်းတို့၏ စကားဝှက်များကို ဖျက်ခြင်းလို လုပ်ရပ်များကို လုပ်ကိုင်ခွင့် ပြုသည်။"</string>
     <string name="permlab_useCredentials" msgid="235481396163877642">"စက်ပေါ်ရှိ သုံးစွဲသူအကောင့်များ"</string>
-    <string name="permdesc_useCredentials" msgid="7984227147403346422">"appအား အထောက်အထား စိစစ်ရေး တိုကင်များကို တောင်းဆိုခွင့် ပြုသည်။"</string>
+    <string name="permdesc_useCredentials" msgid="7984227147403346422">"appအား အထောက်အထား စိစစ်ရေး တိုကင်များကို တောင်းဆိုခွင့် ပြုသည်။"</string>
     <string name="permlab_accessNetworkState" msgid="4951027964348974773">"ကွန်ရက် ချိတ်ဆက်မှုများအား ကြည့်ရန်"</string>
     <string name="permdesc_accessNetworkState" msgid="8318964424675960975">"အပလီကေးရှင်းအား မည်သည့်ကွန်ရက်နက်ဝဘ်ရှိသလဲ၊ မည်သည့်ကွန်ရက်နှင့် ချိတ်ဆက်ထားလဲ စသည်ဖြင့် ကွန်ရက်ချိတ်ဆက်မှုများ၏ သတင်းအချက်အလက်များကို ကြည့်ခွင့်ပေးရန်"</string>
     <string name="permlab_createNetworkSockets" msgid="8018758136404323658">"အပြည့်အ၀ ကွန်ရက်သုံးခွင့်ရရန်"</string>
     <string name="permdesc_createNetworkSockets" msgid="3403062187779724185">"အပလီကေးရှင်းအား ကွန်ရက်ဆော့ကတ်များ တည်ဆောက်ခွင့်၊ တသီးတသန့် ကွန်ရက် ပရိုတိုကောလ်များ သုံးခွင့် ပြုပါ။ အင်တာနက်မှ အချက်အလက်များ ပေးပို့ခြင်းကို ဘရောက်ဇာနှင့် တခြား အပလီကေးရှင်းများက လုပ်ဆောင်ပေးသောကြောင့် ဒီခွင့်ပြုချက်က အင်တာနက်မှ အချက်အလက် ပေးပို့ခြင်း မလိုအပ်ပါ"</string>
-    <string name="permlab_writeApnSettings" msgid="505660159675751896">"ကွန်ယက်အပြင်အဆင်နှင့် အသွားအလာများကို ပြောင်းလဲ/ကြားဖြတ်စေခြင်း"</string>
-    <string name="permdesc_writeApnSettings" msgid="5333798886412714193">"appအား ကွန်ရက် ဆက်တင်များကို ပြောင်းလဲလျက် ကွန်ရက် ဆက်သွယ်မှုများ အားလုံးကို ကြားဖြတ်ယူခြင်း နှင့် စုံစမ်းစစ်ဆေးခြင်း၊ ဥပမာ၊ မည်သည့် APN ၏ ပရော့က်စီ နှင့် ပို့တ်များကို ပြောင်းလဲခြင်း၊ ပြုလုပ်ခွင့် ပြုသည်။ ကြံဖန် appများက သင် မသိရဘဲနှင့် ကွန်ရက် အထုပ်များကို စောင့်ကြည့်ခြင်း၊ အခြားသို့ ညွှန်းပို့ခြင်း၊ သို့မဟုတ် မွမ်းမံခြင်းကို ပြုလုပ်နိုင်သည်။"</string>
+    <string name="permlab_writeApnSettings" msgid="505660159675751896">"ကွန်ယက်အပြင်အဆင်နှင့် အသွားအလာများကို ပြောင်းလဲ/ကြားဖြတ်စေခြင်း"</string>
+    <string name="permdesc_writeApnSettings" msgid="5333798886412714193">"appအား ကွန်ရက် ဆက်တင်များကို ပြောင်းလဲလျက် ကွန်ရက် ဆက်သွယ်မှုများ အားလုံးကို ကြားဖြတ်ယူခြင်း နှင့် စုံစမ်းစစ်ဆေးခြင်း၊ ဥပမာ၊ မည်သည့် APN ၏ ပရော့က်စီ နှင့် ပို့တ်များကို ပြောင်းလဲခြင်း၊ ပြုလုပ်ခွင့် ပြုသည်။ ကြံဖန် appများက သင် မသိရဘဲနှင့် ကွန်ရက် အထုပ်များကို စောင့်ကြည့်ခြင်း၊ အခြားသို့ ညွှန်းပို့ခြင်း၊ သို့မဟုတ် မွမ်းမံခြင်းကို ပြုလုပ်နိုင်သည်။"</string>
     <string name="permlab_changeNetworkState" msgid="958884291454327309">"ကွန်ယက်ဆက်သွယ်မှုအားပြောင်းခြင်း"</string>
-    <string name="permdesc_changeNetworkState" msgid="6789123912476416214">"appအား ကွန်ရက် ချိတ်ဆက်နိုင်စွမ်း အခြေအနေကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
-    <string name="permlab_changeTetherState" msgid="5952584964373017960">"တစ်ဆင့်ပွါးဆက်သွယ်မှုအားပြောင်းခြင်း"</string>
-    <string name="permdesc_changeTetherState" msgid="1524441344412319780">"appအား ချိတ်တွဲထားသည့် ကွန်ရက် ချိတ်ဆက်နိုင်စွမ်း အခြေအနေကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_changeNetworkState" msgid="6789123912476416214">"appအား ကွန်ရက် ချိတ်ဆက်နိုင်စွမ်း အခြေအနေကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permlab_changeTetherState" msgid="5952584964373017960">"တစ်ဆင့်ပွါးဆက်သွယ်မှုအားပြောင်းခြင်း"</string>
+    <string name="permdesc_changeTetherState" msgid="1524441344412319780">"appအား ချိတ်တွဲထားသည့် ကွန်ရက် ချိတ်ဆက်နိုင်စွမ်း အခြေအနေကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
     <string name="permlab_changeBackgroundDataSetting" msgid="1400666012671648741">"နောက်ခံဒေတာအသုံးပြုခြင်းဆက်တင်အား ပြောင်းခြင်း"</string>
-    <string name="permdesc_changeBackgroundDataSetting" msgid="5347729578468744379">"appအား နောက်ခံ ဒေတာ သုံးစွဲမှု ဆက်တင်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
+    <string name="permdesc_changeBackgroundDataSetting" msgid="5347729578468744379">"appအား နောက်ခံ ဒေတာ သုံးစွဲမှု ဆက်တင်ကို ပြောင်းလဲခွင့် ပြုသည်။"</string>
     <string name="permlab_accessWifiState" msgid="5202012949247040011">"ဝိုင်ဖိုင် ချိတ်ဆက်မှများအား ကြည့်ရန်"</string>
     <string name="permdesc_accessWifiState" msgid="5002798077387803726">"အပလီကေးရှင်းအား ဝိုင်ဖိုင် ဖွင့်ထား မထား၊ ချိတ်ဆက်ထားသော ပိုင်ဖိုင် စက်ပစ္စည်း စသဖြင့် ဝိုင်ဖိုင်နှင့် သက်ဆိုင်သော အချက်အလက် ကြည့်ခွင့်ပေးရန်"</string>
     <string name="permlab_changeWifiState" msgid="6550641188749128035">"ဝိုင်ဖိုင်အား ချိတ်ဆက်ရန် နှင့် ဆက်သွယ်မှု ဖြတ်တောက်ရန်"</string>
     <string name="permdesc_changeWifiState" msgid="7137950297386127533">"အပလီကေးရှင်းအား ဝိုင်ဖိုင်တည်နေရာများအား ဆက်သွယ်ခြင်း၊ ဆက်သွယ်မှု ရပ်ဆိုင်းခြင်း၊ ဝိုင်ဖိုင်ကွန်ရက်အတွက် စက်အပြင်အဆင်များ ပြုလုပ်ခြင်း ခွင့်ပြုပါ"</string>
-    <string name="permlab_changeWifiMulticastState" msgid="1368253871483254784">"Wi-Fi Multicastလက်ခံခြင်းကိုခွင့်ပြုရန်"</string>
+    <string name="permlab_changeWifiMulticastState" msgid="1368253871483254784">"Wi-Fi Multicastလက်ခံခြင်းကိုခွင့်ပြုရန်"</string>
     <string name="permdesc_changeWifiMulticastState" product="tablet" msgid="7969774021256336548">"အပလီကေးရှင်းအား ဝိုင်ဖိုင်ကွန်ရက်ပေါ်တွင် သင့်တက်ဘလက်တစ်ခုထဲအားမဟုတ်ပဲ multicast လိပ်စာအား သုံးပြီး လွှင့်ထုတ်သော အချက်အလက်များ လက်ခံခွင့် ပြုပါ။ ဒီလိုသုံးခြင်းမှာ  non-multicast ထက် ဘက်ထရီ ပိုကုန်ပါသည်။"</string>
     <string name="permdesc_changeWifiMulticastState" product="default" msgid="6851949706025349926">"အပလီကေးရှင်းအား ဝိုင်ဖိုင်နက်ဘ်ပေါ်တွင် သင့်ဖုန်းတစ်ခုထဲအားမဟုတ်ပဲ multicast လိပ်စာအား သုံးပြီး လွှင့်ထုတ်သော အချက်အလက်များ လက်ခံခွင့် ပြုပါ။ ဒီလိုသုံးခြင်းမှာ non-multicast ထက် ဘက်ထရီ ပိုကုန်ပါသည်။"</string>
     <string name="permlab_bluetoothAdmin" msgid="6006967373935926659">"ဘလူးတု ဆက်တင်များအား သုံးခွင့်ပေးရန်"</string>
-    <string name="permdesc_bluetoothAdmin" product="tablet" msgid="6921177471748882137">"appအား ဒေသန္တရ ဘလူးတုသ် တက်ဘလက်ကို စီစဉ်ဖွဲ့စည်းခွင့်ကို၎င်း၊ အဝေးထိန်း ကိရိယာများကို ရှာကြံလျက် ချိတ်တွဲခွင့်ကို၎င်း ပေးထားသည်။"</string>
-    <string name="permdesc_bluetoothAdmin" product="default" msgid="8931682159331542137">"appအား ဒေသန္တရ ဘလူးတုသ် ဖုန်းကို စီစဉ်ဖွဲ့စည်းခွင့်ကို၎င်း၊ အဝေးထိန်း ကိရိယာများကို ရှာကြံလျက် ချိတ်တွဲခွင့်ကို၎င်း ပေးထားသည်။"</string>
+    <string name="permdesc_bluetoothAdmin" product="tablet" msgid="6921177471748882137">"appအား ဒေသန္တရ ဘလူးတုသ် တက်ဘလက်ကို စီစဉ်ဖွဲ့စည်းခွင့်ကို၎င်း၊ အဝေးထိန်း ကိရိယာများကို ရှာကြံလျက် ချိတ်တွဲခွင့်ကို၎င်း ပေးထားသည်။"</string>
+    <string name="permdesc_bluetoothAdmin" product="default" msgid="8931682159331542137">"appအား ဒေသန္တရ ဘလူးတုသ် ဖုန်းကို စီစဉ်ဖွဲ့စည်းခွင့်ကို၎င်း၊ အဝေးထိန်း ကိရိယာများကို ရှာကြံလျက် ချိတ်တွဲခွင့်ကို၎င်း ပေးထားသည်။"</string>
     <string name="permlab_bluetoothPriv" msgid="4009494246009513828">"အပလီကေးရှင်းသုံးပြီး ဘလူးတုသ်နှင့် ပူးတွဲချိတ်ဆက်ခြင်း အား ခွင့်ပြုရန်"</string>
     <string name="permdesc_bluetoothPriv" product="tablet" msgid="8045735193417468857">"အပလီကေးရှင်းကို အဝေးက စက်များနဲ့ ကိုင်ထားသူ မလုပ်ဆောင်ပဲ ပူးတွဲခွင့်ပေးခြင်း"</string>
     <string name="permdesc_bluetoothPriv" product="default" msgid="8045735193417468857">"အပလီကေးရှင်းကို အဝေးက စက်များနဲ့ ကိုင်ထားသူ မလုပ်ဆောင်ပဲ ပူးတွဲခွင့်ပေးခြင်း"</string>
     <string name="permlab_bluetoothMap" msgid="6372198338939197349">"ဘလူးတုသ် MAP ဒေတာကို ရယူသုံးရန်"</string>
-    <string name="permdesc_bluetoothMap" product="tablet" msgid="5784090105926959958">"appအား ဘလူးတုသ် MAP ဒေတာကို ရယူသုံးခွင့် ပြုသည်။"</string>
-    <string name="permdesc_bluetoothMap" product="default" msgid="5784090105926959958">"appအား ဘလူးတုသ် MAP ဒေတာကို ရယူသုံးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_bluetoothMap" product="tablet" msgid="5784090105926959958">"appအား ဘလူးတုသ် MAP ဒေတာကို ရယူသုံးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_bluetoothMap" product="default" msgid="5784090105926959958">"appအား ဘလူးတုသ် MAP ဒေတာကို ရယူသုံးခွင့် ပြုသည်။"</string>
     <string name="permlab_accessWimaxState" msgid="4195907010610205703">"ဝိုင်မက်စ် နှင့် ချိတ်ဆက်ရန်နှင့် ဆက်သွယ်မှု ဖြတ်တောက်ရန်"</string>
     <string name="permdesc_accessWimaxState" msgid="6360102877261978887">"အပလီကေးရှင်းအား ဝိုင်မက်စ် အခြေအနေ ကြည့်ခွင့်ပေးရန် ဥပမာ ဝိုင်မက်စ် ဖွင့်ထား မထား၊ ဝိုင်မက်စ် ချိတ်ဆက်ထားသော ကွန်ရက်အခြေအနေ"</string>
     <string name="permlab_changeWimaxState" msgid="2405042267131496579">"ဝိုက်မက်စ် အခြေအနေအား ပြင်ရန်"</string>
     <string name="permdesc_changeWimaxState" product="tablet" msgid="3156456504084201805">"အပလီကေးရှင်းအား တက်ဘလက်ကို ဝိုင်မက်စ် ကွန်ရက်များနဲ့ ဆက်သွယ်ခြင်း၊ ဆက်သွယ်မှု ရပ်ဆိုင်းခြင်းများ လုပ်ခွင့်ပြုပါ"</string>
     <string name="permdesc_changeWimaxState" product="default" msgid="697025043004923798">"အပလီကေးရှင်းအား ဖုန်းကို ဝိုင်မက်စ် ကွန်ရက်များနဲ့ ဆက်သွယ်ခြင်း၊ ဆက်သွယ်မှု ရပ်ဆိုင်းခြင်းများ လုပ်ခွင့်ပြုပါ"</string>
     <string name="permlab_scoreNetworks" msgid="6445777779383587181">"ကွန်ရက်များကို အမှတ်ပေးခြင်း"</string>
-    <string name="permdesc_scoreNetworks" product="tablet" msgid="1304304745850215556">"appအား ကွန်ရက်များကို အဆင့်အတန်း သတ်မှတ်ခွင့် ပြုကာ တက်ဘလက် အနေနှင့် မည်သည့် ကွန်ရက်ကို ပိုနှစ်ခြိုက်သင့်ကြောင်းကို ဆုံးဖြတ်စေနိုင်သည်။"</string>
-    <string name="permdesc_scoreNetworks" product="default" msgid="1831501848178651379">"appအား ကွန်ရက်များကို အဆင့်အတန်း သတ်မှတ်ခွင့် ပြုကာ ဖုန်း အနေနှင့် မည်သည့် ကွန်ရက်ကို ပိုနှစ်ခြိုက်သင့်ကြောင်းကို ဆုံးဖြတ်စေနိုင်သည်။"</string>
+    <string name="permdesc_scoreNetworks" product="tablet" msgid="1304304745850215556">"appအား ကွန်ရက်များကို အဆင့်အတန်း သတ်မှတ်ခွင့် ပြုကာ တက်ဘလက် အနေနှင့် မည်သည့် ကွန်ရက်ကို ပိုနှစ်ခြိုက်သင့်ကြောင်းကို ဆုံးဖြတ်စေနိုင်သည်။"</string>
+    <string name="permdesc_scoreNetworks" product="default" msgid="1831501848178651379">"appအား ကွန်ရက်များကို အဆင့်အတန်း သတ်မှတ်ခွင့် ပြုကာ ဖုန်း အနေနှင့် မည်သည့် ကွန်ရက်ကို ပိုနှစ်ခြိုက်သင့်ကြောင်းကို ဆုံးဖြတ်စေနိုင်သည်။"</string>
     <string name="permlab_bluetooth" msgid="6127769336339276828">"ဘလူးတု စက်များနှင့် အတူတွဲချိတ်ရန်"</string>
     <string name="permdesc_bluetooth" product="tablet" msgid="3480722181852438628">"အပလီကေးရှင်းအား တက်ဘလက်ပေါ်မှ ဘလူးတုသ် အပြင်အဆင်အား ကြည့်ခွင့်၊ တခြားစက်များနဲ့ ဆက်သွယ်ခြင်း၊ ဆက်သွယ်ခြင်းကို လက်ခံခွင့်ပြုပါ။"</string>
     <string name="permdesc_bluetooth" product="default" msgid="3207106324452312739">"အပလီကေးရှင်းအား ဖုန်းမှဘလူးတု အပြင်အဆင်အား ကြည့်ခွင့်၊ တခြားစက်များနဲ့ ဆက်သွယ်ခြင်း၊ ဆက်သွယ်ခြင်းကို လက်ခံခွင့်ပြုပါ။"</string>
     <string name="permlab_nfc" msgid="4423351274757876953">"Near Field Communicationအား ထိန်းချုပ်ရန်"</string>
-    <string name="permdesc_nfc" msgid="7120611819401789907">"appအား တာတို စက်ကွင်း ဆက်သွယ်ရေး (NFC) တဲဂ်များ၊ ကဒ်များ နှင့် ဖတ်ကြသူတို့နှင့် ဆက်သွယ်ပြောဆိုခွင့် ပြုသည်။"</string>
+    <string name="permdesc_nfc" msgid="7120611819401789907">"appအား တာတို စက်ကွင်း ဆက်သွယ်ရေး (NFC) တဲဂ်များ၊ ကဒ်များ နှင့် ဖတ်ကြသူတို့နှင့် ဆက်သွယ်ပြောဆိုခွင့် ပြုသည်။"</string>
     <string name="permlab_disableKeyguard" msgid="3598496301486439258">"ဖန်သားပြင် သော့ချခြင်းအား မလုပ်နိုင်အောင် ပိတ်ရန်"</string>
     <string name="permdesc_disableKeyguard" msgid="6034203065077122992">"အပလီကေးရှင်းအား သော့ချခြင်းနှင့် သက်ဆိုင်ရာ စကားဝှက်သတ်မှတ်ခြင်းများအား မသုံးနိုင်အောင် ပိတ်ခြင်းကို ခွင့်ပြုရန်။ ဥပမာ ဖုန်းလာလျှင် သော့ပိတ်ခြင်း ပယ်ဖျက်ခြင်း၊ ဖုန်းပြောပြီးလျှင် သော့ကို အလိုအလျောက် ပြန်ပိတ်ခြင်း"</string>
     <string name="permlab_readSyncSettings" msgid="6201810008230503052">"ထပ်တူပြုအဆင်အပြင်အားဖတ်ခြင်း"</string>
@@ -688,42 +688,42 @@
     <string name="permdesc_writeSyncSettings" msgid="8956262591306369868">"အကောင့်တစ်ခုအတွက် ထပ်တူညီအောင်လုပ်သော ဆက်တင်များကို ပြင်ရန် အပလီကေးရှင်းကို ခွင့်ပြုရန်။ ဥပမာ People အပလီကေးရှင်း က အကောင့်တစ်ခုနှင့် ထပ်တူညီအောင် လုပ်ဆောင်ခြင်းအား ဖွင့်ရန် သုံးနိုင်သည်။"</string>
     <string name="permlab_readSyncStats" msgid="7396577451360202448">"ထပ်တူကူးခြင်း ကိန်းဂဏန်းအချက်အလက်များကို ဖတ်ခြင်း"</string>
     <string name="permdesc_readSyncStats" msgid="1510143761757606156">"အပလီကေးရှင်းအား အကောင့်တစ်ခု၏ ထပ်တူညီအောင် လုပ်ဆောင်မှု အခြေအနေ (ပြီးခဲ့သော အဖြစ်အပျက်၊ ဒေတာ ပမာဏ ပါဝင်မှု များအပါအဝင်)ကို ဖတ်ရှုခွင့် ပြုပါ။"</string>
-    <string name="permlab_subscribedFeedsRead" msgid="4756609637053353318">"အမည်သွင်းထားသောဖိဖ့်များကို ဖတ်ခြင်း"</string>
-    <string name="permdesc_subscribedFeedsRead" msgid="5557058907906144505">"appအား လောလောဆယ် စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများ ဆိုင်ရာ အသေးစိတ်များကို ရယူခွင့်ပြုသည်။"</string>
-    <string name="permlab_subscribedFeedsWrite" msgid="9015246325408209296">"အမည်သွင်းထားသောဖိဖ့်များကို ရေးခြင်း"</string>
-    <string name="permdesc_subscribedFeedsWrite" msgid="6928930188826089413">"appအား လောလောဆယ် စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများကို ပြောင်းပစ်နိုင်သည်။"</string>
+    <string name="permlab_subscribedFeedsRead" msgid="4756609637053353318">"အမည်သွင်းထားသောဖိဖ့်များကို ဖတ်ခြင်း"</string>
+    <string name="permdesc_subscribedFeedsRead" msgid="5557058907906144505">"appအား လောလောဆယ် စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများ ဆိုင်ရာ အသေးစိတ်များကို ရယူခွင့်ပြုသည်။"</string>
+    <string name="permlab_subscribedFeedsWrite" msgid="9015246325408209296">"အမည်သွင်းထားသောဖိဖ့်များကို ရေးခြင်း"</string>
+    <string name="permdesc_subscribedFeedsWrite" msgid="6928930188826089413">"appအား လောလောဆယ် စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက သင်၏ စင့်က် လုပ်ပြီးသား ထည့်သွင်းမှုများကို ပြောင်းပစ်နိုင်သည်။"</string>
     <string name="permlab_readDictionary" msgid="4107101525746035718">"အဘိဓာန်သို့ သင့် ထည့်ထားသည်များအား ဖတ်ခြင်း"</string>
     <string name="permdesc_readDictionary" msgid="659614600338904243">"အပလီကေးရှင်းအား အဘိဓာန်တွင် သိမ်းဆည်းထားသော စာလုံးအားလုံး၊ နာမည်များနှင့် စာစုများ ဖတ်ရှုခွင့် ပြုရန်"</string>
     <string name="permlab_writeDictionary" msgid="2183110402314441106">"သုံးစွဲသူ၏ အဘိဓာန် ထဲသို့ စာလုံးများ ထည့်ခြင်း"</string>
-    <string name="permdesc_writeDictionary" msgid="8185385716255065291">"အသုံးပြုသူ အဘိဓာန်ထဲသို့ စာလုံး အသစ်များကို ရေးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_writeDictionary" msgid="8185385716255065291">"အသုံးပြုသူ အဘိဓာန်ထဲသို့ စာလုံး အသစ်များကို ရေးခွင့် ပြုသည်။"</string>
     <string name="permlab_sdcardRead" product="nosdcard" msgid="367275095159405468">"USB သိုလှောင်မှုမှ အချက်အလက်များအား ဖတ်ခြင်း"</string>
     <string name="permlab_sdcardRead" product="default" msgid="2188156462934977940">"SD ကဒ်မှ အချက်အလက်များအား ဖတ်ခြင်း"</string>
     <string name="permdesc_sdcardRead" product="nosdcard" msgid="3446988712598386079">"အပလီကေးရှင်းအား USB သိုလှောင်မှုပေါ်မှ ဒေတာများ ဖတ်ရှုခွင့်ပြုခြင်း"</string>
     <string name="permdesc_sdcardRead" product="default" msgid="2607362473654975411">"အပလီကေးရှင်းအား အက်စ်ဒီ ကဒ်ပေါ်မှ ဒေတာများ ဖတ်ရှုခွင့်ပြုခြင်း"</string>
     <string name="permlab_sdcardWrite" product="nosdcard" msgid="8485979062254666748">"USBမှဒေတာအား ပြင် သို့ ဖျက်ရန်"</string>
     <string name="permlab_sdcardWrite" product="default" msgid="8805693630050458763">"SD ကဒ်ပေါ်မှ အချက်အလက်များအား ပြင်ဆင်ခြင်း သို့ ဖျက်ပစ်ခြင်း"</string>
-    <string name="permdesc_sdcardWrite" product="nosdcard" msgid="6175406299445710888">"appအား USB သိုလှောင်ခန်းသို့ ရေးခွင့် ပြုသည်။"</string>
-    <string name="permdesc_sdcardWrite" product="default" msgid="4337417790936632090">"appအား SD ကဒ်သို့ ရေးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_sdcardWrite" product="nosdcard" msgid="6175406299445710888">"appအား USB သိုလှောင်ခန်းသို့ ရေးခွင့် ပြုသည်။"</string>
+    <string name="permdesc_sdcardWrite" product="default" msgid="4337417790936632090">"appအား SD ကဒ်သို့ ရေးခွင့် ပြုသည်။"</string>
     <string name="permlab_mediaStorageWrite" product="default" msgid="6859839199706879015">"စက်တွင်းမီဒီယာသိမ်းဆည်းမှုအကြောင်းအရာများကို မွမ်းမံ/ပယ်ဖျက်ရန်"</string>
-    <string name="permdesc_mediaStorageWrite" product="default" msgid="8189160597698529185">"appအား အတွင်းပိုင်း မီဒီယာ သိုလှော်ခန်း အကြေင်းအရာများကို မွမ်းမံခွင့် ပြုသည်။"</string>
+    <string name="permdesc_mediaStorageWrite" product="default" msgid="8189160597698529185">"appအား အတွင်းပိုင်း မီဒီယာ သိုလှော်ခန်း အကြေင်းအရာများကို မွမ်းမံခွင့် ပြုသည်။"</string>
     <string name="permlab_manageDocs" product="default" msgid="5778318598448849829">"စာရွက်စာတန်းများ သိုလှောင်မှုကို ထိန်းသိမ်းခြင်း"</string>
     <string name="permdesc_manageDocs" product="default" msgid="8704323176914121484">"အပလီကေးရှင်းအား စာရွက်စာတမ်းများအား ထိန်းချုပ်ခွင့်ပေးခြင်း"</string>
     <string name="permlab_sdcardAccessAll" msgid="8150613823900460576">"အသုံးပြုသူ အားလုံး၏ ပြင်ပသိုလှောင်ရာအား အသုံးပြုရန်"</string>
     <string name="permdesc_sdcardAccessAll" msgid="3215208357415891320">"အပလီကေးရှင်းအား သုံးစွဲသူ အားလုံးအတွက် ပြင်ပသိမ်းဆည်မှုအား သုံးခွင့် ပြုပါ။"</string>
     <string name="permlab_cache_filesystem" msgid="5656487264819669824">"cache ဖိုင်စနစ်အား ဝင်ရောက်ချိတ်ဆက်ခြင်း"</string>
-    <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"appအား ဖိုင်စနစ်၏ကက်ရှကို ဖတ် နှင့် ရေး ခွင့်ပြုသည်။"</string>
+    <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"appအား ဖိုင်စနစ်၏ကက်ရှကို ဖတ် နှင့် ရေး ခွင့်ပြုသည်။"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP ခေါ်ဆိုမှုများ ခေါ်ရန်/လက်ခံရန်"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP ခေါ်ဆိုမှုများ ခေါ်ရန်နှင့် လက်ခံနိုင်ရန် app ကို ခွင့်ပြုပါ။"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"တခါတည်း ခေါ်ဆိုနိုင်သော ဖန်သားပြင်နဲ့ ဆက်ဆံရန်"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ဖုန်းကိုင်သူ ဘယ်အချိန် ဘယ်လိုမှာ အပလီကေးရှင်းအတွင်း ဖုန်းခေါ်မှုကို မြင်ရခြင်းအား ထိန်းချုပ်ခွင့်ပေးခြင်း"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ခေါ်ဆိုမှု-အဝင် မျက်နှာပြင်နဲ့ တုံ့ပြန်လုပ်ကိုင်ရန်"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"appအား အသုံးပြုသူက ခေါ်ဆိုမှုအဝင် မျက်နှာပြင် ဘယ်အချိန်မှာ ဘယ်လို မြင်ရမှာကို ထိန်းချုပ်ခွင့်ပေးရန်"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"တယ်လီဖုန်း ဝန်ဆောင်မှုများနှင့် အပြန်အလှန် တုံ့ပြန်မှု"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"appအား ခေါ်ဆိုမှုများ လုပ်ခြင်း/လက်ခံခြင်း ပြုလုပ်နိုင်ရန် တယ်လီဖုန်း ဝန်ဆောင်မှုများနှင့် အပြန်အလှန် တုံ့ပြန်မှုကို ခွင့်ပြုသည်။"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"အသုံးပြုသူ အတွက် ခေါ်ဆိုမှုအဝင် လုပ်ကိုင်ပုံကို စီစဉ်ပေးခြင်း"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"appအား အသုံးပြုသူ အတွက် ခေါ်ဆိုမှုအဝင် လုပ်ကိုင်ပုံကို စီစဉ်ခွင့် ပြုသည်။"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ရာဇဝင်အလိုက် ကွန်ယက်သုံစွဲမှုအား ဖတ်ခြင်း"</string>
-    <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"appအား အထူး ကွန်ရက်များ နှင့် appများ အတွက် ကွန်ရက် အသုံးပြုမှု မှတ်တမ်းကို ဖတ်ကြားခွင့် ပြုသည်။"</string>
+    <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"appအား အထူး ကွန်ရက်များ နှင့် appများ အတွက် ကွန်ရက် အသုံးပြုမှု မှတ်တမ်းကို ဖတ်ကြားခွင့် ပြုသည်။"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ကွန်ယက်မူဝါဒအား စီမံခြင်း"</string>
-    <string name="permdesc_manageNetworkPolicy" msgid="7537586771559370668">"appအား ကွန်ရက် မူဝါဒများကို စီမံခန့်ခွဲခွင့် နှင့် app-ဆိုင်ရာ စည်းကမ်းချက်များကို ပြဌာန်းခွင့် ပြုသည်။"</string>
+    <string name="permdesc_manageNetworkPolicy" msgid="7537586771559370668">"appအား ကွန်ရက် မူဝါဒများကို စီမံခန့်ခွဲခွင့် နှင့် app-ဆိုင်ရာ စည်းကမ်းချက်များကို ပြဌာန်းခွင့် ပြုသည်။"</string>
     <string name="permlab_modifyNetworkAccounting" msgid="5088217309088729650">"ကွန်ယက်အသုံးပြုမှုစာရင်းအား မွမ်းမံခြင်း"</string>
     <string name="permdesc_modifyNetworkAccounting" msgid="5443412866746198123">"အပလီကေးရှင်းအား တခြားအပလီကေးရှင်းများမှ ကွန်ရက်အသုံးပြုမှု တွက်ချက်ခြင်းအား ပြင်ဆင်ခွင့် ပြုပါ။ ပုံမှန် အပလီကေးရှင်းများအတွက် မလိုအပ်ပါ။"</string>
     <string name="permlab_accessNotifications" msgid="7673416487873432268">"သတိပေးချက်များအား အသုံးပြုခွင့်"</string>
@@ -731,37 +731,35 @@
     <string name="permlab_bindNotificationListenerService" msgid="7057764742211656654">"သတိပေးချက် နားထောင်ခြင်း ဆားဗစ် နှင့် ပူးပေါင်းခြင်း"</string>
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"ဖုန်းကိုင်ထားသူနှင့် အကြောင်းကြားချက် နားစွင့်သော ဆားဗစ်မှ ထိပ်ပိုင်းအင်တာဖေ့စ် ကို ပူးပေါင်းခွင့်ပေးခြင်း။ ပုံမှန် အပလီကေးရှင်းများမှာ မလိုအပ်ပါ"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"အခြေအနေ စီမံပေးရေး ဝန်ဆောင်မှု တစ်ခုဆီသို့ ချိတ်တွဲခြင်း"</string>
-    <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"စွဲကိုင်ထားသူအား အခြေအနေကို စီမံပေးသူ၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"မီဒီယာ လမ်းကြောင်း ဝန်ဆောင်မှုသို့ တွဲချည်ရန်"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"ကိုင်ထားသူအား မီဒီယာ လမ်းကြောင်း ဝန်ဆောင်မှု၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ တွဲချည်ခွင့် ပြုသည်။ သာမန် appများ ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"စွဲကိုင်ထားသူအား အခြေအနေကို စီမံပေးသူ၏ ထိပ်သီး အဆင့် အင်တာဖေ့စ်သို့ ချိတ်တွဲခွင့်ကို ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"အိပ်မက် ဝန်ဆောင်မှုသို့ ပေါင်းစည်းမည်"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"အိမ်မက်ဝန်ဆောင်မှု၏ ထိပ်တန်းအဆင့် မျက်နှာပြင်အား ကိုင်ဆောင်သူမှ ပေါင်းစည်းရန် ခွင့်ပြုမည်။ သာမန် အပလီကေးရှင်းများတွင် မလိုအပ်ပါ။"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"မိုဘိုင်းဆက်သွယ်ရေးဝန်ဆောင်မှုဌာန မှ ထည့်သွင်းပေးသော အခြေအနေများအား ပယ်ဖျက်ခြင်း"</string>
     <string name="permdesc_invokeCarrierSetup" msgid="4159549152529111920">"ကိုင်ဆောင်သူအားမိုဘိုင်းဆက်သွယ်ရေးဝန်ဆောင်မှုဌာနမှ ထည့်သွင်းထားတဲ့ အပြင်အဆင်အား ပယ်ဖျက်ခွင့် ပေးခြင်း။ ပုံမှန် အပလီကေးရှင်းများမှာ မလိုပါ"</string>
     <string name="permlab_accessNetworkConditions" msgid="8206077447838909516">"ကွန်ယက်အခြေအနေအား လေ့လာနေမှုအား နားထောင်ခွင့်"</string>
     <string name="permdesc_accessNetworkConditions" msgid="6899102075825272211">"အပလီကေးရှင်းကို နက်ဝေါ့ ပေါ်က အခြေအနေကို သတိထားခွင့် ပေးခြင်း၊. ပုံမှန် အပလီကေးရှင်း များတွင် မလိုအပ်ပါ"</string>
-    <string name="permlab_setInputCalibration" msgid="4902620118878467615">"change ထည့်သွင်းရေး ကိရိယာ တိုင်းထွာညှိနှိုင်းမှု ပြောင်းလဲခြင်း"</string>
-    <string name="permdesc_setInputCalibration" msgid="4527511047549456929">"appအား တို့ထိရေး မျက်နှာပြင် တိုင်းထွာစံညှိမှုကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ  ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permlab_setInputCalibration" msgid="4902620118878467615">"change ထည့်သွင်းရေး ကိရိယာ တိုင်းထွာညှိနှိုင်းမှု ပြောင်းလဲခြင်း"</string>
+    <string name="permdesc_setInputCalibration" msgid="4527511047549456929">"appအား တို့ထိရေး မျက်နှာပြင် တိုင်းထွာစံညှိမှုကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ  ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_accessDrmCertificates" msgid="7436886640723203615">"DRM လက်မှတ်များကို ရယူသုံးခြင်း"</string>
-    <string name="permdesc_accessDrmCertificates" msgid="8073288354426159089">"အပလီကေးရှင်း တစ်ခုအား စီမံလုပ်ကိုင်ခွင့် DRM လက်မှတ်များ သုံးခွင့် ပြုသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_accessDrmCertificates" msgid="8073288354426159089">"အပလီကေးရှင်း တစ်ခုအား စီမံလုပ်ကိုင်ခွင့် DRM လက်မှတ်များ သုံးခွင့် ပြုသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_handoverStatus" msgid="1159132046126626731">"အန်ဒရွိုက်၏ အလင်းတန်းထိုး လွှဲပြောင်းမှု အခြေအနေကို ရယူရန်"</string>
-    <string name="permdesc_handoverStatus" msgid="4788144087245714948">"ဒီအပလီကေးရှင်းအား အန်ဒရွိုက်၏ လက်ရှိ အလင်းတန်းထိုး လွှဲပြောင်းမှု အကြောင်း အချက်အလက်ကို ရယူခွင့် ပြုသည်"</string>
+    <string name="permdesc_handoverStatus" msgid="4788144087245714948">"ဒီအပလီကေးရှင်းအား အန်ဒရွိုက်၏ လက်ရှိ အလင်းတန်းထိုး လွှဲပြောင်းမှု အကြောင်း အချက်အလက်ကို ရယူခွင့် ပြုသည်"</string>
     <string name="permlab_removeDrmCertificates" msgid="7044888287209892751">"DRM လက်မှတ်များ ဖယ်ရှားရန်"</string>
-    <string name="permdesc_removeDrmCertificates" msgid="7272999075113400993">"အပလီကေးရှင်းအား DRM လက်မှတ်များကို ဖယ်ရှားခွင့် ပြုသည်။  သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_removeDrmCertificates" msgid="7272999075113400993">"အပလီကေးရှင်းအား DRM လက်မှတ်များကို ဖယ်ရှားခွင့် ပြုသည်။  သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="policylab_limitPassword" msgid="4497420728857585791">"စကားဝှက်စည်းမျဥ်းကိုသတ်မှတ်ရန်"</string>
     <string name="policydesc_limitPassword" msgid="3252114203919510394">"မျက်နှာပြင် သော့ဖွင့်ရန် လိုအပ်သော စကားလုံးအရေအတွက်နှင့် အမျိုးအစားအား ထိန်းချုပ်ရန်"</string>
-    <string name="policylab_watchLogin" msgid="914130646942199503">"မော်နီတာမျက်နှာပြင်ဖွင့်ရန် ကြိုးစားခွင့်များ"</string>
-    <string name="policydesc_watchLogin" product="tablet" msgid="3215729294215070072">"မျက်နှာပြင်ကို သော့ဖွင့်ရန် အတွက် စကားဝှက် မမှန်မကန် ထည့်သွင်းမှု အရေအတွက်ကို စောင့်ကြည့်လျက်၊ စကားဝှက် ရိုက်ထည့်မှု သိပ်များနေလျှင် တက်ဘလက်ကို သော့ခတ်ရန် သို့မဟုတ် တက်ဘလက် ဒေတာ အားလုံးကို ဖျက်ပစ်ရန်။"</string>
-    <string name="policydesc_watchLogin" product="default" msgid="5712323091846761073">"မျက်နှာပြင်ကို သော့ဖွင့်ရန် အတွက် စကားဝှက် မမှန်မကန် ထည့်သွင်းမှု အရေအတွက်ကို စောင့်ကြည့်လျက်၊ စကားဝှက် ရိုက်ထည့်မှု သိပ်များနေလျှင် ဖုန်းကို သော့ခတ်ရန် သို့မဟုတ် ဖုန်း ဒေတာ အားလုံးကို ဖျက်ပစ်ရန်။"</string>
-    <string name="policylab_resetPassword" msgid="2620077191242688955">"မျက်နှာပြင်ဖွင့်ရန်စကားဝှက်အား ပြောင်းခြင်း"</string>
-    <string name="policydesc_resetPassword" msgid="605963962301904458">"မျက်နှာပြင်ဖွင့်ရန်စကားဝှက်အား ပြောင်းခြင်း"</string>
+    <string name="policylab_watchLogin" msgid="914130646942199503">"မော်နီတာမျက်နှာပြင်ဖွင့်ရန် ကြိုးစားခွင့်များ"</string>
+    <string name="policydesc_watchLogin" product="tablet" msgid="3215729294215070072">"မျက်နှာပြင်ကို သော့ဖွင့်ရန် အတွက် စကားဝှက် မမှန်မကန် ထည့်သွင်းမှု အရေအတွက်ကို စောင့်ကြည့်လျက်၊ စကားဝှက် ရိုက်ထည့်မှု သိပ်များနေလျှင် တက်ဘလက်ကို သော့ခတ်ရန် သို့မဟုတ် တက်ဘလက် ဒေတာ အားလုံးကို ဖျက်ပစ်ရန်။"</string>
+    <string name="policydesc_watchLogin" product="default" msgid="5712323091846761073">"မျက်နှာပြင်ကို သော့ဖွင့်ရန် အတွက် စကားဝှက် မမှန်မကန် ထည့်သွင်းမှု အရေအတွက်ကို စောင့်ကြည့်လျက်၊ စကားဝှက် ရိုက်ထည့်မှု သိပ်များနေလျှင် ဖုန်းကို သော့ခတ်ရန် သို့မဟုတ် ဖုန်း ဒေတာ အားလုံးကို ဖျက်ပစ်ရန်။"</string>
+    <string name="policylab_resetPassword" msgid="2620077191242688955">"မျက်နှာပြင်ဖွင့်ရန်စကားဝှက်အား ပြောင်းခြင်း"</string>
+    <string name="policydesc_resetPassword" msgid="605963962301904458">"မျက်နှာပြင်ဖွင့်ရန်စကားဝှက်အား ပြောင်းခြင်း"</string>
     <string name="policylab_forceLock" msgid="2274085384704248431">"မျက်နှာပြင်အားသော့ချရန်"</string>
     <string name="policydesc_forceLock" msgid="1141797588403827138">"မည်သည့်အချိန်တွင် ဖန်သားပြင်အား မည်ကဲ့သို့နည်းဖြင် သော့ချရန် ထိန်းချုပ်ခြင်း"</string>
     <string name="policylab_wipeData" msgid="3910545446758639713">"ဒေတာအားလုံးအားဖျက်ခြင်း"</string>
     <string name="policydesc_wipeData" product="tablet" msgid="4306184096067756876">"စက်ရုံထုတ် အခြေအနေအား ပြန်ပြောင်းခြင်းဖြင့် တက်ဘလက်ရှိ အချက်အလက်များအား ကြိုတင်သတိပေးမှုမရှိပဲ ဖျက်စီးရန်"</string>
     <string name="policydesc_wipeData" product="default" msgid="5096895604574188391">"စက်ရုံထုတ် အခြေအနေအား ပြန်ပြောင်းခြင်းဖြင့် ဖုန်းရှိ အချက်အလက်များအား ကြိုတင်သတိပေးမှုမရှိပဲ ဖျက်စီးရန်"</string>
     <string name="policylab_setGlobalProxy" msgid="2784828293747791446">"တကမာ္ဘလုံးဆိုင်ရာပရော်စီကို သတ်မှတ်ခြင်း"</string>
-    <string name="policydesc_setGlobalProxy" msgid="6387497466660154931">"မူဝါဒအသုံးပြုခွင့်ရလျှင် စက်ပစ္စည်းတကမ္ဘာလုံးဆိုင်ရာပရော်စီအားသုံးရန် သတ်မှတ်ခြင်း။ ပထမဦးဆုံးသောစက်၏ထိန်းချုပ်သူသာ တကမ္ဘာလုံးဆိုင်ရာပရော်စီသာအားအကျိုးသက်ရောက်စေရန် သတ်မှတ်နိုင်သည်။"</string>
+    <string name="policydesc_setGlobalProxy" msgid="6387497466660154931">"မူဝါဒအသုံးပြုခွင့်ရလျှင် စက်ပစ္စည်းတကမ္ဘာလုံးဆိုင်ရာပရော်စီအားသုံးရန် သတ်မှတ်ခြင်း။ ပထမဦးဆုံးသောစက်၏ထိန်းချုပ်သူသာ တကမ္ဘာလုံးဆိုင်ရာပရော်စီသာအားအကျိုးသက်ရောက်စေရန် သတ်မှတ်နိုင်သည်။"</string>
     <string name="policylab_expirePassword" msgid="885279151847254056">"စကားဝှက်သက်တမ်းသတ်မှတ်ရန်"</string>
     <string name="policydesc_expirePassword" msgid="1729725226314691591">"ဖန်သားပြင်သော့ချခြင်း စကားဝှက် ပြင်ဆင်ခွင့် အကြိမ်ရေအား ထိန်းချုပ်ခြင်း"</string>
     <string name="policylab_encryptedStorage" msgid="8901326199909132915">"သိုလှောင်လျို့ဝှက်ခြင်းသတ်မှတ်"</string>
@@ -884,21 +882,21 @@
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"အလုပ်အကိုင်"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"တခြား"</string>
     <string name="quick_contacts_not_available" msgid="746098007828579688">"ဒီအဆက်အသွယ်အား ကြည့်ရှုရန်  အပလီကေးရှင်း မတွေ့ပါ"</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN ကုဒ် ရိုက်ထည့်ပါ"</string>
-    <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"PUK နှင့် PIN ကုဒ် အသစ်ကို ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN ကုဒ် ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"PUK နှင့် PIN ကုဒ် အသစ်ကို ရိုက်ထည့်ပါ"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1341112146710087048">"PUK နံပါတ်"</string>
     <string name="keyguard_password_enter_pin_prompt" msgid="8027680321614196258">"PIN ကုဒ် အသစ်"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"စကားဝှက် ရိုက်ရန် ထိပါ"</font></string>
-    <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"သော့ဖွင့်ရန် စကားဝှက်ကို ရိုက်ထည့်ပါ"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"သော့ဖွင့်ရန် PIN ကို ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"သော့ဖွင့်ရန် စကားဝှက်ကို ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"သော့ဖွင့်ရန် PIN ကို ရိုက်ထည့်ပါ"</string>
     <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"ပင်နံပါတ်မှားနေပါသည်"</string>
-    <string name="keyguard_label_text" msgid="861796461028298424">"သော့ဖွင့်ရန် Menu ထိုနောက်0ကိုနှိပ်ပါ"</string>
+    <string name="keyguard_label_text" msgid="861796461028298424">"သော့ဖွင့်ရန် Menu ထိုနောက်0ကိုနှိပ်ပါ"</string>
     <string name="emergency_call_dialog_number_for_display" msgid="696192103195090970">"အရေးပေါ်နံပါတ်"</string>
     <string name="lockscreen_carrier_default" msgid="8963839242565653192">"ဆားဗစ် မရှိပါ"</string>
     <string name="lockscreen_screen_locked" msgid="7288443074806832904">"မျက်နှာပြင်အားသော့ချထားသည်"</string>
-    <string name="lockscreen_instructions_when_pattern_enabled" msgid="46154051614126049">"ဖွင့်ရန်သို့မဟုတ်အရေးပေါ်ခေါ်ဆိုခြင်းပြုလုပ်ရန် မီနူးကိုနှိပ်ပါ"</string>
+    <string name="lockscreen_instructions_when_pattern_enabled" msgid="46154051614126049">"ဖွင့်ရန်သို့မဟုတ်အရေးပေါ်ခေါ်ဆိုခြင်းပြုလုပ်ရန် မီနူးကိုနှိပ်ပါ"</string>
     <string name="lockscreen_instructions_when_pattern_disabled" msgid="686260028797158364">"မီးနူးကို နှိပ်ခြင်းဖြင့် သော့ဖွင့်ပါ"</string>
-    <string name="lockscreen_pattern_instructions" msgid="7478703254964810302">"ဖွင့်ရန်ပုံစံဆွဲပါ"</string>
+    <string name="lockscreen_pattern_instructions" msgid="7478703254964810302">"ဖွင့်ရန်ပုံစံဆွဲပါ"</string>
     <string name="lockscreen_emergency_call" msgid="5347633784401285225">"အရေးပေါ်ခေါ်ဆိုရန်"</string>
     <string name="lockscreen_return_to_call" msgid="5244259785500040021">"ခေါ်ဆိုမှုထံပြန်သွားရန်"</string>
     <string name="lockscreen_pattern_correct" msgid="9039008650362261237">"မှန်ပါသည်"</string>
@@ -912,10 +910,10 @@
     <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"ဆင်းကဒ် မရှိပါ"</string>
     <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"တက်ပလက်ထဲတွင်း ဆင်းကဒ် မရှိပါ"</string>
     <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"ဖုန်းထဲတွင် ဆင်းကဒ် မရှိပါ"</string>
-    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"ဆင်းမ်ကဒ် ထည့်ပါ"</string>
+    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"ဆင်းမ်ကဒ် ထည့်ပါ"</string>
     <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"ဆင်းမ်ကဒ် မရှိဘူး သို့မဟုတ် ဖတ်မရပါ။ ဆင်းမ်ကဒ် တစ်ခုကို ထည့်ပါ။"</string>
     <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"သုံးစွဲ မရတော့သော ဆင်းကဒ်"</string>
-    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"သင့် ဆင်းမ်ကဒ်ကို ထာဝရ ပိတ်လိုက်ပါပြီ။\n နောက် ဆင်းမ်ကဒ် တစ်ခု အတွက် သင်၏ ကြိုးမဲ့ ဝန်ဆောင်မှု စီမံပေးသူကို ဆက်သွယ်ပါ"</string>
+    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"သင့် ဆင်းမ်ကဒ်ကို ထာဝရ ပိတ်လိုက်ပါပြီ။\n နောက် ဆင်းမ်ကဒ် တစ်ခု အတွက် သင်၏ ကြိုးမဲ့ ဝန်ဆောင်မှု စီမံပေးသူကို ဆက်သွယ်ပါ"</string>
     <string name="lockscreen_transport_prev_description" msgid="6300840251218161534">"ယခင် တစ်ပုဒ်"</string>
     <string name="lockscreen_transport_next_description" msgid="573285210424377338">"နောက် တစ်ပုဒ်"</string>
     <string name="lockscreen_transport_pause_description" msgid="3980308465056173363">"ခဏရပ်ရန်"</string>
@@ -926,21 +924,21 @@
     <string name="emergency_calls_only" msgid="6733978304386365407">"အရေးပေါ်ခေါ်ဆိုမှုသာ"</string>
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"ကွန်ယက် သော့ကျနေခြင်း"</string>
     <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"ဆင်းမ်ကဒ် ရဲ့ ပင်နံပါတ် ပြန်ဖွင့်သည့် ကုဒ် သော့ကျနေပါသည်"</string>
-    <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"သုံးစွဲသူ လမ်းညွှန်ကို ကြည့်ပါ သို့မဟုတ် ဖောက်သည်များ စောင့်ရှောက်ရေး ဌာနကို ဆက်သွယ်ပါ။"</string>
+    <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"သုံးစွဲသူ လမ်းညွှန်ကို ကြည့်ပါ သို့မဟုတ် ဖောက်သည်များ စောင့်ရှောက်ရေး ဌာနကို ဆက်သွယ်ပါ။"</string>
     <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"ဆင်းမ်ကဒ် သော့ကျနေပါသည်"</string>
     <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"ဆင်းမ်ကဒ် ကို သော့ဖွင့်နေပါသည်"</string>
-    <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"သင်သည် သော့ဖွင့် ပုံစံကို<xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ \n\nထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g>စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
-    <string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"သင်သည် စကားဝှက်ကို  <xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရိုက်ခဲ့ပြီ။ \n\n ထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g> စက္ကန့်အကြာ စမ်းကြည့်ပါ။"</string>
-    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"သင်သည် သင်၏ PIN <xliff:g id="NUMBER_0">%d</xliff:g>ကို ကြိမ် မမှန်မကန် ရိုက်ခဲ့ပြီ။ \n\n ထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g> စက္ကန့်အကြာ စမ်းကြည့်ပါ။"</string>
-    <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"သင်သည် သော့ဖွင့် ပုံစံကို<xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ နောက်ထပ် <xliff:g id="NUMBER_1">%d</xliff:g> မအောင်မြင်သည့် ကြိုးပမ်းမှု နောက်မှာ၊ သင်၏ တက်ဘလက်ကို Google လက်မှတ်ထိုး ဝင်မှုဖြင့် ဖွင့်ရန် တောင်းဆိုခံရမည်။ \n\n ထပ်ပြီး <xliff:g id="NUMBER_2">%d</xliff:g> စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
-    <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"သင်သည် သော့ဖွင့် ပုံစံကို <xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ နောက်ထပ် <xliff:g id="NUMBER_1">%d</xliff:g> မအောင်မြင်သည့် ကြိုးပမ်းမှု နောက်မှာ၊ သင်၏ ဖုန်းကို Google လက်မှတ်ထိုး ဝင်မှုဖြင့် ဖွင့်ရန် တောင်းဆိုခံရမည်။ \n\n ထပ်ပြီး <xliff:g id="NUMBER_2">%d</xliff:g> စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"သင့်Tabletအား မှားယွင်းစွာ <xliff:g id="NUMBER_0">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားနေပါသည်။ နောက်ထပ်<xliff:g id="NUMBER_1">%d</xliff:g>ကြိမ်မအောင်မြင်ပါက မူလစက်ရုံ အနေအထားသို့ပြန်လည်ရောက်ရှိကာ အသုံးပြုသူ၏ဒေတာအားလုံးဆုံးရှုံးပါမည်။"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"သင့်ဖုန်းအား မှားယွင်းစွာ <xliff:g id="NUMBER_0">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားနေပါသည်။ နောက်ထပ်<xliff:g id="NUMBER_1">%d</xliff:g>ကြိမ်မအောင်မြင်ပါက မူလစက်ရုံ အနေအထားသို့ပြန်လည်ရောက်ရှိကာ အသုံးပြုသူ၏ဒေတာအားလုံးဆုံးရှုံးပါမည်။"</string>
-    <string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"သင့်Tabletအား မှားယွင်းစွာ <xliff:g id="NUMBER">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားခဲ့ပါသည်။ယခုဖုန်းကိုမူလစက်ရုံအနေအထားသို့ပြန်လည်ရောက်ရှိပါမည်။"</string>
-    <string name="lockscreen_failed_attempts_now_wiping" product="default" msgid="3025504721764922246">"သင့်ဖုန်းအား မှားယွင်းစွာ <xliff:g id="NUMBER">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားခဲ့ပါသည်။ ယခုဖုန်းကို မူလစက်ရုံအနေအထားသို့ပြန်လည်ရောက်ရှိပါမည်။"</string>
-    <string name="lockscreen_too_many_failed_attempts_countdown" msgid="6251480343394389665">"<xliff:g id="NUMBER">%d</xliff:g> စက္ကန့်အကြာတွင် ပြန်ကြိုးစားပါ"</string>
+    <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"သင်သည် သော့ဖွင့် ပုံစံကို<xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ \n\nထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g>စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
+    <string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"သင်သည် စကားဝှက်ကို  <xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရိုက်ခဲ့ပြီ။ \n\n ထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g> စက္ကန့်အကြာ စမ်းကြည့်ပါ။"</string>
+    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"သင်သည် သင်၏ PIN <xliff:g id="NUMBER_0">%d</xliff:g>ကို ကြိမ် မမှန်မကန် ရိုက်ခဲ့ပြီ။ \n\n ထပ်ပြီးတော့ <xliff:g id="NUMBER_1">%d</xliff:g> စက္ကန့်အကြာ စမ်းကြည့်ပါ။"</string>
+    <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"သင်သည် သော့ဖွင့် ပုံစံကို<xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ နောက်ထပ် <xliff:g id="NUMBER_1">%d</xliff:g> မအောင်မြင်သည့် ကြိုးပမ်းမှု နောက်မှာ၊ သင်၏ တက်ဘလက်ကို Google လက်မှတ်ထိုး ဝင်မှုဖြင့် ဖွင့်ရန် တောင်းဆိုခံရမည်။ \n\n ထပ်ပြီး <xliff:g id="NUMBER_2">%d</xliff:g> စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
+    <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"သင်သည် သော့ဖွင့် ပုံစံကို <xliff:g id="NUMBER_0">%d</xliff:g> ကြိမ် မမှန်မကန် ရေးဆွဲခဲ့သည်။ နောက်ထပ် <xliff:g id="NUMBER_1">%d</xliff:g> မအောင်မြင်သည့် ကြိုးပမ်းမှု နောက်မှာ၊ သင်၏ ဖုန်းကို Google လက်မှတ်ထိုး ဝင်မှုဖြင့် ဖွင့်ရန် တောင်းဆိုခံရမည်။ \n\n ထပ်ပြီး <xliff:g id="NUMBER_2">%d</xliff:g> စက္ကန့် အကြာမှာ စမ်းကြည့်ပါ။"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"သင့်Tabletအား မှားယွင်းစွာ <xliff:g id="NUMBER_0">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားနေပါသည်။ နောက်ထပ်<xliff:g id="NUMBER_1">%d</xliff:g>ကြိမ်မအောင်မြင်ပါက မူလစက်ရုံ အနေအထားသို့ပြန်လည်ရောက်ရှိကာ အသုံးပြုသူ၏ဒေတာအားလုံးဆုံးရှုံးပါမည်။"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"သင့်ဖုန်းအား မှားယွင်းစွာ <xliff:g id="NUMBER_0">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားနေပါသည်။ နောက်ထပ်<xliff:g id="NUMBER_1">%d</xliff:g>ကြိမ်မအောင်မြင်ပါက မူလစက်ရုံ အနေအထားသို့ပြန်လည်ရောက်ရှိကာ အသုံးပြုသူ၏ဒေတာအားလုံးဆုံးရှုံးပါမည်။"</string>
+    <string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"သင့်Tabletအား မှားယွင်းစွာ <xliff:g id="NUMBER">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားခဲ့ပါသည်။ယခုဖုန်းကိုမူလစက်ရုံအနေအထားသို့ပြန်လည်ရောက်ရှိပါမည်။"</string>
+    <string name="lockscreen_failed_attempts_now_wiping" product="default" msgid="3025504721764922246">"သင့်ဖုန်းအား မှားယွင်းစွာ <xliff:g id="NUMBER">%d</xliff:g>ကြိမ်ဖွင့်ရန် ကြိုးစားခဲ့ပါသည်။ ယခုဖုန်းကို မူလစက်ရုံအနေအထားသို့ပြန်လည်ရောက်ရှိပါမည်။"</string>
+    <string name="lockscreen_too_many_failed_attempts_countdown" msgid="6251480343394389665">"<xliff:g id="NUMBER">%d</xliff:g> စက္ကန့်အကြာတွင် ပြန်ကြိုးစားပါ"</string>
     <string name="lockscreen_forgot_pattern_button_text" msgid="2626999449610695930">"ပုံစံအားမေ့နေပါသလား"</string>
-    <string name="lockscreen_glogin_forgot_pattern" msgid="2588521501166032747">"အကောင့်ဖွင့်ရန်"</string>
+    <string name="lockscreen_glogin_forgot_pattern" msgid="2588521501166032747">"အကောင့်ဖွင့်ရန်"</string>
     <string name="lockscreen_glogin_too_many_attempts" msgid="2751368605287288808">"အကြိမ်ရေ များစွာ ပုံဆွဲသော့ဖွင့်ရန် ကြိုးစားခြင်း"</string>
     <string name="lockscreen_glogin_instructions" msgid="3931816256100707784">"သော့ဖွင့်ရန် ဂူဂဲလ် အကောင့်ဖြင့် ဝင်ပါ"</string>
     <string name="lockscreen_glogin_username_hint" msgid="8846881424106484447">"သုံးစွဲသူ အမှတ် (အီးမေးလ်)"</string>
@@ -950,7 +948,7 @@
     <string name="lockscreen_glogin_account_recovery_hint" msgid="1696924763690379073">"သုံးစွဲသူ အမည် သို့ စကားဝှင်ကို မေ့နေပါသလား။ \n"<b>"google.com/accounts/recovery"</b>" ကို သွားရောက်ပါ။"</string>
     <string name="lockscreen_glogin_checking_password" msgid="7114627351286933867">"စစ်ဆေးနေပါသည်…"</string>
     <string name="lockscreen_unlock_label" msgid="737440483220667054">"ဆင်းမ်ကဒ် ဖွင့်ပါ"</string>
-    <string name="lockscreen_sound_on_label" msgid="9068877576513425970">"အသံဖွင့်ထားသည်"</string>
+    <string name="lockscreen_sound_on_label" msgid="9068877576513425970">"အသံဖွင့်ထားသည်"</string>
     <string name="lockscreen_sound_off_label" msgid="996822825154319026">"အသံပိတ်ထားသည်"</string>
     <string name="lockscreen_access_pattern_start" msgid="3941045502933142847">"ပုံစံစတင်ခြင်း"</string>
     <string name="lockscreen_access_pattern_cleared" msgid="5583479721001639579">"ပုံစံရှင်းလင်းခြင်း"</string>
@@ -987,9 +985,9 @@
     <string name="hour_ampm" msgid="4584338083529355982">"<xliff:g id="HOUR">%-l</xliff:g><xliff:g id="AMPM">%P</xliff:g>"</string>
     <string name="hour_cap_ampm" msgid="2083465992940444366">"<xliff:g id="HOUR">%-l</xliff:g><xliff:g id="AMPM">%p</xliff:g>"</string>
     <string name="factorytest_failed" msgid="5410270329114212041">"စက်ရုံစမ်းသပ်ခြင်းမအောင်မြင်ပါ"</string>
-    <string name="factorytest_not_system" msgid="4435201656767276723">"စက်ရုံစမ်းသပ်မှုမှာ စနစ်/အပ်ပလီကေးရှင်း ထည့်သွင်းထားသောpackageများကိုသာ ပံ့ပိုးမှုပေးသည်။."</string>
-    <string name="factorytest_no_action" msgid="872991874799998561">"စက်ရုံစမ်းသပ်မှုအားလုပ်ဆောင်ရန် မည်သည့်packageမှ မတွေ့ပါ။"</string>
-    <string name="factorytest_reboot" msgid="6320168203050791643">"လုပ်ငန်းစနစ်ထည့်သွင်းပြီး ပြန်လည်စတင်ရန်"</string>
+    <string name="factorytest_not_system" msgid="4435201656767276723">"စက်ရုံစမ်းသပ်မှုမှာ စနစ်/အပ်ပလီကေးရှင်း ထည့်သွင်းထားသောpackageများကိုသာ ပံ့ပိုးမှုပေးသည်။."</string>
+    <string name="factorytest_no_action" msgid="872991874799998561">"စက်ရုံစမ်းသပ်မှုအားလုပ်ဆောင်ရန် မည်သည့်packageမှ မတွေ့ပါ။"</string>
+    <string name="factorytest_reboot" msgid="6320168203050791643">"လုပ်ငန်းစနစ်ထည့်သွင်းပြီး ပြန်လည်စတင်ရန်"</string>
     <string name="js_dialog_title" msgid="1987483977834603872">"ဒီ \"<xliff:g id="TITLE">%s</xliff:g>\" က စာမျက်နှာက ပြောဆိုတာက:"</string>
     <string name="js_dialog_title_default" msgid="6961903213729667573">"JavaScript"</string>
     <string name="js_dialog_before_unload_title" msgid="2619376555525116593">"သေချာကြောင်း လုပ်ပါ"</string>
@@ -1022,21 +1020,21 @@
     <string name="permdesc_writeHistoryBookmarks" product="tablet" msgid="6825527469145760922">"အပလီကေးရှင်းအား ဘရောင်ဇာမှ မှတ်တမ်း သို့ မှတ်သားမှု အမှတ်များအား ပြင်ဆင်ခွင့် ပေးခြင်း။ အပလီကေးရှင်းမှ ဘရောင်ဇာ မှတ်တမ်းများကို ဖျက်ပစ်ခွင့် သို့ ပြင်ဆင်ခွင့် ရှိပါမည်။ မှတ်ချက်။ ဤခွင့်ပြုချက်ကို တတိယပါတီ ဘရောင်ဇာများ၊ တခြား အပလီကေးရှင်းများမှ သုံးမည် မဟုတ်ပါ။"</string>
     <string name="permdesc_writeHistoryBookmarks" product="default" msgid="8497389531014185509">"အပလီကေးရှင်းအား ဘရောင်ဇာမှ မှတ်တမ်း သို့ မှတ်သားမှု အမှတ်များအား ပြင်ဆင်ခွင့် ပေးခြင်း။ အပလီကေးရှင်းမှ ဘရောင်ဇာ မှတ်တမ်းများကို ဖျက်ပစ်ခွင့် သို့ ပြင်ဆင်ခွင့် ရှိပါမည်။ မှတ်ချက်။ ဒီခွင့်ပြုချက်ကို တတိယပါတီ ဘရောင်ဇာများ၊ တခြား အပလီကေးရှင်းများမှ သုံးမည် မဟုတ်ပါ။"</string>
     <string name="permlab_setAlarm" msgid="1379294556362091814">"နှိုးစက်သတ်မှတ်ရန်"</string>
-    <string name="permdesc_setAlarm" msgid="316392039157473848">"appအား တပ်ဆင်ထားသည့် နှိုးစက်နာရီ app ထဲတွင် နှိုးစက်ကို သတ်မှတ်ခွင့် ပြုသည်။ အချို့ နှိုးစက် appများက ထိုအင်္ဂါရပ်ကို ပြီးမြောက်အောင် မလုပ်နိုင်ကြပါ။"</string>
+    <string name="permdesc_setAlarm" msgid="316392039157473848">"appအား တပ်ဆင်ထားသည့် နှိုးစက်နာရီ app ထဲတွင် နှိုးစက်ကို သတ်မှတ်ခွင့် ပြုသည်။ အချို့ နှိုးစက် appများက ထိုအင်္ဂါရပ်ကို ပြီးမြောက်အောင် မလုပ်နိုင်ကြပါ။"</string>
     <string name="permlab_writeVoicemail" msgid="7309899891683938100">"အသံမေးလ်ကို ရေးရန်"</string>
-    <string name="permdesc_writeVoicemail" msgid="6592572839715924830">"appအား သင်၏ အသံမေးလ် ဝင်စာများကို မွမ်းမံခွင့် နှင့် ဖယ်ရှားခွင့် ပြုသည်။"</string>
-    <string name="permlab_addVoicemail" msgid="5525660026090959044">"အသံစာပို့စနစ်အားထည့်ရန်"</string>
-    <string name="permdesc_addVoicemail" msgid="6604508651428252437">"appအား သင့် အသံမေးလ် ဝင်စာသို့ စာများကို ထည့်ခွင့် ပြုသည်။"</string>
+    <string name="permdesc_writeVoicemail" msgid="6592572839715924830">"appအား သင်၏ အသံမေးလ် ဝင်စာများကို မွမ်းမံခွင့် နှင့် ဖယ်ရှားခွင့် ပြုသည်။"</string>
+    <string name="permlab_addVoicemail" msgid="5525660026090959044">"အသံစာပို့စနစ်အားထည့်ရန်"</string>
+    <string name="permdesc_addVoicemail" msgid="6604508651428252437">"appအား သင့် အသံမေးလ် ဝင်စာသို့ စာများကို ထည့်ခွင့် ပြုသည်။"</string>
     <string name="permlab_readVoicemail" msgid="8415201752589140137">"အသံမေးလ်ကို  ဖတ်ရန်"</string>
-    <string name="permdesc_readVoicemail" msgid="8926534735321616550">"appအား သင်၏ အသံမေးလ်များကို ဖတ်ခွင့် ပြုရန်"</string>
-    <string name="permlab_writeGeolocationPermissions" msgid="5962224158955273932">"ဘရောင်ဇာ ဘူမိဇုန်သတ်မှတ်မှု ခွင့်ပြုချက်များကို မွမ်းမံခြင်း"</string>
-    <string name="permdesc_writeGeolocationPermissions" msgid="1083743234522638747">"appအား ဘရောင်ဇာ၏ ဘူမိဇုန်သတ်မှတ်ရေး ခွင့်ပြုချက်များကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးချပြီး လိုရာ ဝက်ဘ်ဆိုက်များသို့ တည်နေရာ အချက်အလက် ပို့မှုကို လုပ်နိုင်သည်။"</string>
+    <string name="permdesc_readVoicemail" msgid="8926534735321616550">"appအား သင်၏ အသံမေးလ်များကို ဖတ်ခွင့် ပြုရန်"</string>
+    <string name="permlab_writeGeolocationPermissions" msgid="5962224158955273932">"ဘရောင်ဇာ ဘူမိဇုန်သတ်မှတ်မှု ခွင့်ပြုချက်များကို မွမ်းမံခြင်း"</string>
+    <string name="permdesc_writeGeolocationPermissions" msgid="1083743234522638747">"appအား ဘရောင်ဇာ၏ ဘူမိဇုန်သတ်မှတ်ရေး ခွင့်ပြုချက်များကို မွမ်းမံခွင့် ပြုသည်။ ကြံဖန် appများက ၎င်းကို အသုံးချပြီး လိုရာ ဝက်ဘ်ဆိုက်များသို့ တည်နေရာ အချက်အလက် ပို့မှုကို လုပ်နိုင်သည်။"</string>
     <string name="permlab_packageVerificationAgent" msgid="5568139100645829117">"packages များကိုအတည်ပြုစိစစ်ခြင်း"</string>
-    <string name="permdesc_packageVerificationAgent" msgid="8437590190990843381">"appအား အထုပ် တစ်ခု၏ မတည်ငြိမ်မှုကို စိစစ်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_bindPackageVerifier" msgid="4187786793360326654">"package အတည်ပြုခြင်းနှင့် ပူးပေါင်းရန်"</string>
-    <string name="permdesc_bindPackageVerifier" msgid="3180741773233862126">"စွဲကိုင်ထားသူအား အထုပ်များအား စိစစ်ရေး တောင်းဆိုချက်များကို ပြုလုပ်ခွင့် ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
+    <string name="permdesc_packageVerificationAgent" msgid="8437590190990843381">"appအား အထုပ် တစ်ခု၏ မတည်ငြိမ်မှုကို စိစစ်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_bindPackageVerifier" msgid="4187786793360326654">"package အတည်ပြုခြင်းနှင့် ပူးပေါင်းရန်"</string>
+    <string name="permdesc_bindPackageVerifier" msgid="3180741773233862126">"စွဲကိုင်ထားသူအား အထုပ်များအား စိစစ်ရေး တောင်းဆိုချက်များကို ပြုလုပ်ခွင့် ပေးသည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_serialPort" msgid="546083327654631076">"အစဥ်လိုက်ပို့များကို ဝင်ရောက်ချိတ်ဆက်ခြင်း"</string>
-    <string name="permdesc_serialPort" msgid="2991639985224598193">"SerialManager APIအားအသုံးပြုကာ ကိုင်ဆောင်သူကို စီရီယာပို့မျာကို ဝင်ရောက်အသုံးပြုခြင်းအား ခွင့်ပြုသည်။"</string>
+    <string name="permdesc_serialPort" msgid="2991639985224598193">"SerialManager APIအားအသုံးပြုကာ ကိုင်ဆောင်သူကို စီရီယာပို့မျာကို ဝင်ရောက်အသုံးပြုခြင်းအား ခွင့်ပြုသည်။"</string>
     <string name="permlab_accessContentProvidersExternally" msgid="5077774297943409285">"အချက်အလက်များ ပံ့ပိုသူများအား အပြင်ဖက်မှ ရယူခြင်း"</string>
     <string name="permdesc_accessContentProvidersExternally" msgid="4544346486697853685">"ကိုင်ဆောင်ထားသူကို အချက်အလက်ပံ့ပိုးမှုများကို ကွန်ဆိုးလ်မှ ရယူခွင့် ပြုပါ။ ပုံမှန်အပလီကေးရှင်းအတွက် မလိုအပ်ပါ။"</string>
     <string name="permlab_updateLock" msgid="3527558366616680889">"စက်အလိုအလျောက်အဆင်မြှင့်ခြင်း အားမပေးရန်"</string>
@@ -1044,8 +1042,8 @@
     <string name="save_password_message" msgid="767344687139195790">"ဤလျှို့ဝှက်စကားဝှက်အား ဘရောင်ဇာကိုမှတ်ခိုင်းမည်လား"</string>
     <string name="save_password_notnow" msgid="6389675316706699758">"ယခုမဟုတ်ပါ"</string>
     <string name="save_password_remember" msgid="6491879678996749466">"မှတ်ထားရန်"</string>
-    <string name="save_password_never" msgid="8274330296785855105">"မည်သည့်အခါမှ"</string>
-    <string name="open_permission_deny" msgid="7374036708316629800">"သင့်ဆီမှာ ဒီစာမျက်နှာကို ဖွင့်ရန် ခွင့်ပြုချက် မရှိပါ။"</string>
+    <string name="save_password_never" msgid="8274330296785855105">"မည်သည့်အခါမှ"</string>
+    <string name="open_permission_deny" msgid="7374036708316629800">"သင့်ဆီမှာ ဒီစာမျက်နှာကို ဖွင့်ရန် ခွင့်ပြုချက် မရှိပါ။"</string>
     <string name="text_copied" msgid="4985729524670131385">"clipboardထံ စာသားအားကူးယူမည်"</string>
     <string name="more_item_label" msgid="4650918923083320495">"နောက်ထပ်"</string>
     <string name="prepend_shortcut_label" msgid="2572214461676015642">"Menu+"</string>
@@ -1064,8 +1062,8 @@
     <string name="oneMonthDurationPast" msgid="7396384508953779925">"လွန်ခဲ့သော၁လက"</string>
     <string name="beforeOneMonthDurationPast" msgid="909134546836499826">"လွန်ခဲ့သော၁လမတိုင်မီက"</string>
   <plurals name="num_seconds_ago">
-    <item quantity="one" msgid="4869870056547896011">"လွန်ခဲ့သော ၁စက္ကန့်က"</item>
-    <item quantity="other" msgid="3903706804349556379">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်က"</item>
+    <item quantity="one" msgid="4869870056547896011">"လွန်ခဲ့သော ၁စက္ကန့်က"</item>
+    <item quantity="other" msgid="3903706804349556379">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်က"</item>
   </plurals>
   <plurals name="num_minutes_ago">
     <item quantity="one" msgid="3306787433088810191">"လွန်ခဲ့သော ၁မိနစ်က"</item>
@@ -1085,8 +1083,8 @@
     <item quantity="other" msgid="2479586466153314633">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> ရက်တွင်"</item>
   </plurals>
   <plurals name="in_num_seconds">
-    <item quantity="one" msgid="2729745560954905102">"နောက် ၁စက္ကန့်တွင်"</item>
-    <item quantity="other" msgid="1241926116443974687">"နောက် <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်တွင်"</item>
+    <item quantity="one" msgid="2729745560954905102">"နောက် ၁စက္ကန့်တွင်"</item>
+    <item quantity="other" msgid="1241926116443974687">"နောက် <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်တွင်"</item>
   </plurals>
   <plurals name="in_num_minutes">
     <item quantity="one" msgid="8793095251325200395">"နောက်၁မီနစ်တွင်"</item>
@@ -1101,8 +1099,8 @@
     <item quantity="other" msgid="5109449375100953247">"နောက် <xliff:g id="COUNT">%d</xliff:g> ရက်တွင်"</item>
   </plurals>
   <plurals name="abbrev_num_seconds_ago">
-    <item quantity="one" msgid="1849036840200069118">"လွန်ခဲ့သော ၁စက္ကန့်က"</item>
-    <item quantity="other" msgid="3699169366650930415">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်က"</item>
+    <item quantity="one" msgid="1849036840200069118">"လွန်ခဲ့သော ၁စက္ကန့်က"</item>
+    <item quantity="other" msgid="3699169366650930415">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်က"</item>
   </plurals>
   <plurals name="abbrev_num_minutes_ago">
     <item quantity="one" msgid="6361490147113871545">"လွန်ခဲ့သော ၁မိနစ်က"</item>
@@ -1117,8 +1115,8 @@
     <item quantity="other" msgid="3453342639616481191">"လွန်ခဲ့သော <xliff:g id="COUNT">%d</xliff:g> ရက်တွင်"</item>
   </plurals>
   <plurals name="abbrev_in_num_seconds">
-    <item quantity="one" msgid="5842225370795066299">"နောက် ၁စက္ကန့်တွင်"</item>
-    <item quantity="other" msgid="5495880108825805108">"နောက် <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်တွင်"</item>
+    <item quantity="one" msgid="5842225370795066299">"နောက် ၁စက္ကန့်တွင်"</item>
+    <item quantity="other" msgid="5495880108825805108">"နောက် <xliff:g id="COUNT">%d</xliff:g> စက္ကန့်တွင်"</item>
   </plurals>
   <plurals name="abbrev_in_num_minutes">
     <item quantity="one" msgid="562786149928284878">"နောက်၁မိနစ်တွင်"</item>
@@ -1141,8 +1139,8 @@
     <string name="hours" msgid="894424005266852993">"နာရီများ"</string>
     <string name="minute" msgid="9148878657703769868">"မိနစ်"</string>
     <string name="minutes" msgid="5646001005827034509">"မိနစ်"</string>
-    <string name="second" msgid="3184235808021478">"စက္ကန့်"</string>
-    <string name="seconds" msgid="3161515347216589235">"စက္ကန့်"</string>
+    <string name="second" msgid="3184235808021478">"စက္ကန့်"</string>
+    <string name="seconds" msgid="3161515347216589235">"စက္ကန့်"</string>
     <string name="week" msgid="5617961537173061583">"အပတ်"</string>
     <string name="weeks" msgid="6509623834583944518">"အပတ်"</string>
     <string name="year" msgid="4001118221013892076">"နှစ်"</string>
@@ -1160,12 +1158,12 @@
     <item quantity="other" msgid="3863962854246773930">"<xliff:g id="COUNT">%d</xliff:g> နာရီ"</item>
   </plurals>
     <string name="VideoView_error_title" msgid="3534509135438353077">"ဗီဒီယို ပြဿနာ"</string>
-    <string name="VideoView_error_text_invalid_progressive_playback" msgid="3186670335938670444">"ဒီဗိဒီယိုမှာ ဒီကိရိယာ ပေါ်မှာ ဖွင့်ကြည့်၍ မရနိုင်ပါ။"</string>
+    <string name="VideoView_error_text_invalid_progressive_playback" msgid="3186670335938670444">"ဒီဗိဒီယိုမှာ ဒီကိရိယာ ပေါ်မှာ ဖွင့်ကြည့်၍ မရနိုင်ပါ။"</string>
     <string name="VideoView_error_text_unknown" msgid="3450439155187810085">"ဒီဗီဒီယိုကို ပြသလို့ မရပါ"</string>
     <string name="VideoView_error_button" msgid="2822238215100679592">"ကောင်းပြီ"</string>
     <string name="relative_time" msgid="1818557177829411417">"<xliff:g id="DATE">%1$s</xliff:g>, <xliff:g id="TIME">%2$s</xliff:g>"</string>
-    <string name="noon" msgid="7245353528818587908">"မွန်းတည့်"</string>
-    <string name="Noon" msgid="3342127745230013127">"မွန်းတည့်"</string>
+    <string name="noon" msgid="7245353528818587908">"မွန်းတည့်"</string>
+    <string name="Noon" msgid="3342127745230013127">"မွန်းတည့်"</string>
     <string name="midnight" msgid="7166259508850457595">"ညသန်းခေါင်"</string>
     <string name="Midnight" msgid="5630806906897892201">"ညသန်းခေါင်"</string>
     <string name="elapsed_time_short_format_mm_ss" msgid="4431555943828711473">"<xliff:g id="MINUTES">%1$02d</xliff:g>:<xliff:g id="SECONDS">%2$02d</xliff:g>"</string>
@@ -1181,7 +1179,7 @@
     <string name="textSelectionCABTitle" msgid="5236850394370820357">"စာတိုရွေးချယ်မှု"</string>
     <string name="addToDictionary" msgid="4352161534510057874">"အဘိဓာန်ထဲ ထည့်ပါ"</string>
     <string name="deleteText" msgid="6979668428458199034">"ဖျက်ပစ်ရန်"</string>
-    <string name="inputMethod" msgid="1653630062304567879">"ထည့်သွင်းရန်နည်းလမ်း"</string>
+    <string name="inputMethod" msgid="1653630062304567879">"ထည့်သွင်းရန်နည်းလမ်း"</string>
     <string name="editTextMenuTitle" msgid="4909135564941815494">"စာတို လုပ်ဆောင်ချက်"</string>
     <string name="low_internal_storage_view_title" msgid="5576272496365684834">"သိမ်းဆည်သော နေရာ နည်းနေပါသည်"</string>
     <string name="low_internal_storage_view_text" msgid="6640505817617414371">"တချို့ စနစ်လုပ်ငန်းများ အလုပ် မလုပ်ခြင်း ဖြစ်နိုင်ပါသည်"</string>
@@ -1190,28 +1188,29 @@
     <string name="ok" msgid="5970060430562524910">"ကောင်းပြီ"</string>
     <string name="cancel" msgid="6442560571259935130">"ပယ်ဖျက်ရန်"</string>
     <string name="yes" msgid="5362982303337969312">"ကောင်းပြီ"</string>
-    <string name="no" msgid="5141531044935541497">"ပယ်ဖျက်သည်"</string>
+    <string name="no" msgid="5141531044935541497">"နေတော့"</string>
     <string name="dialog_alert_title" msgid="2049658708609043103">"သတိပြုရန်"</string>
     <string name="loading" msgid="7933681260296021180">"တင်နေ…"</string>
     <string name="capital_on" msgid="1544682755514494298">"ဖွင့်ရန်"</string>
-    <string name="capital_off" msgid="6815870386972805832">"ပိတ်ရန်"</string>
+    <string name="capital_off" msgid="6815870386972805832">"ပိတ်"</string>
     <string name="whichApplication" msgid="4533185947064773386">"အသုံးပြု၍ ဆောင်ရွက်မှုအားပြီးဆုံးစေခြင်း"</string>
     <string name="whichApplicationNamed" msgid="8260158865936942783">"%1$s ကို သုံးပြီး လုပ်ဆောင်ချက် ပြီးဆုံးပါစေ"</string>
     <string name="whichViewApplication" msgid="3272778576700572102">"...ဖြင့် ဖွင့်မည်"</string>
     <string name="whichViewApplicationNamed" msgid="2286418824011249620">"%1$s ဖြင့် ဖွင့်မည်"</string>
-    <string name="whichEditApplication" msgid="144727838241402655">"...နှင့် တည်းဖြတ်ရန်"</string>
-    <string name="whichEditApplicationNamed" msgid="1775815530156447790">"%1$s နှင့် တည်းဖြတ်ရန်"</string>
-    <string name="whichSendApplication" msgid="6902512414057341668">"...နှင့် မျှဝေရန်"</string>
-    <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$sနှင့် မျှဝေရန်"</string>
+    <string name="whichEditApplication" msgid="144727838241402655">"...နှင့် တည်းဖြတ်ရန်"</string>
+    <string name="whichEditApplicationNamed" msgid="1775815530156447790">"%1$s နှင့် တည်းဖြတ်ရန်"</string>
+    <string name="whichSendApplication" msgid="6902512414057341668">"...နှင့် မျှဝေရန်"</string>
+    <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$sနှင့် မျှဝေရန်"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ပင်မ အပလီကေးရှင်း ရွေးချယ်ပါ"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ဤလှုပ်ရှားမှုအတွက် မူရင်းအတိုင်း အသုံးပြုပါ။"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"အခြား appကို သုံးပါ"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"စနစ် ဆက်တင် ထဲမှာ ပုံသေကို ရှင်းလိုက်ပါ &gt; Appများ &gt; ဒေါင်းလုဒ် လုပ်ပြီး။"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"လုပ်စရာ တစ်ခု ရွေးချယ်ပါ"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB ကိရိယာ အတွက် app တစ်ခု ရွေးပါ"</string>
     <string name="noApplications" msgid="2991814273936504689">"ဘယ် appကမှ ဒီ လုပ်ဆောင်ချက်ကို မလုပ်ကိုင်နိုင်ပါ။"</string>
     <string name="aerr_title" msgid="1905800560317137752"></string>
-    <string name="aerr_application" msgid="932628488013092776">"ဝမ်းနည်းစွာဖြင့်<xliff:g id="APPLICATION">%1$s</xliff:g>မှာ ရပ်ဆိုင်းသွားသည်။"</string>
-    <string name="aerr_process" msgid="4507058997035697579">"ဝမ်းနည်းစွာဖြင့် လုပ်ဆောင်ချက်<xliff:g id="PROCESS">%1$s</xliff:g>မှာ ရပ်ဆိုင်းသွားသည်။"</string>
+    <string name="aerr_application" msgid="932628488013092776">"ဝမ်းနည်းစွာဖြင့်<xliff:g id="APPLICATION">%1$s</xliff:g>မှာ ရပ်ဆိုင်းသွားသည်။"</string>
+    <string name="aerr_process" msgid="4507058997035697579">"ဝမ်းနည်းစွာဖြင့် လုပ်ဆောင်ချက်<xliff:g id="PROCESS">%1$s</xliff:g>မှာ ရပ်ဆိုင်းသွားသည်။"</string>
     <string name="anr_title" msgid="4351948481459135709"></string>
     <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g> က မတုံ့ပြန်ပါ။ \n\n၎င်းကို သင် ပိတ်လိုပါသလား?"</string>
     <string name="anr_activity_process" msgid="5776209883299089767">"လှုပ်ရှားမှု <xliff:g id="ACTIVITY">%1$s</xliff:g>က မတုံ့ပြန်ပါ။\n\n၎င်းကို သင် ပိတ်လိုပါသလား?"</string>
@@ -1219,35 +1218,35 @@
     <string name="anr_process" msgid="6513209874880517125">"ဖြစ်စဉ်<xliff:g id="PROCESS">%1$s</xliff:g> က မတုံ့ပြန်ပါ။ \n\n၎င်းကို သင် ပိတ် ချင်သလား?"</string>
     <string name="force_close" msgid="8346072094521265605">"ကောင်းပြီ"</string>
     <string name="report" msgid="4060218260984795706">"သတင်းပို့ခြင်း"</string>
-    <string name="wait" msgid="7147118217226317732">"စောင့်ဆိုင်းရန်"</string>
+    <string name="wait" msgid="7147118217226317732">"စောင့်ဆိုင်းရန်"</string>
     <string name="webpage_unresponsive" msgid="3272758351138122503">"စာမျက်နှာမှာ ပြန်လည် တုံ့ပြန်မှု မရှိတော့ပါ။\n\nပိတ်လိုက်ချင်ပါသလား?"</string>
     <string name="launch_warning_title" msgid="1547997780506713581">"App ပြန်ညွှန်းခဲ့"</string>
     <string name="launch_warning_replace" msgid="6202498949970281412">"<xliff:g id="APP_NAME">%1$s</xliff:g> သည် ယခုအလုပ်လုပ်နေသည်"</string>
-    <string name="launch_warning_original" msgid="188102023021668683">"မူလ <xliff:g id="APP_NAME">%1$s</xliff:g> တွင် ထုတ်လွင့်သည်"</string>
+    <string name="launch_warning_original" msgid="188102023021668683">"မူလ <xliff:g id="APP_NAME">%1$s</xliff:g> တွင် ထုတ်လွင့်သည်"</string>
     <string name="screen_compat_mode_scale" msgid="3202955667675944499">"စကေး"</string>
     <string name="screen_compat_mode_show" msgid="4013878876486655892">"အမြဲပြသရန်"</string>
-    <string name="screen_compat_mode_hint" msgid="1064524084543304459">"ဒါကို စနစ် ဆက်တင်များထဲ ပြန်ဖွင့်ပေးရန် &gt; Apps &gt; ဒေါင်းလုဒ် လုပ်ပြီး။"</string>
-    <string name="smv_application" msgid="3307209192155442829">"app <xliff:g id="APPLICATION">%1$s</xliff:g> (လုပ်ငန်းစဉ် <xliff:g id="PROCESS">%2$s</xliff:g>) က ကိုယ်တိုင် ပြဌာန်းခဲ့သည့် StrictMode မူဝါဒကို ချိုးဖောက်ခဲ့သည်။"</string>
+    <string name="screen_compat_mode_hint" msgid="1064524084543304459">"ဒါကို စနစ် ဆက်တင်များထဲ ပြန်ဖွင့်ပေးရန် &gt; Apps &gt; ဒေါင်းလုဒ် လုပ်ပြီး။"</string>
+    <string name="smv_application" msgid="3307209192155442829">"app <xliff:g id="APPLICATION">%1$s</xliff:g> (လုပ်ငန်းစဉ် <xliff:g id="PROCESS">%2$s</xliff:g>) က ကိုယ်တိုင် ပြဌာန်းခဲ့သည့် StrictMode မူဝါဒကို ချိုးဖောက်ခဲ့သည်။"</string>
     <string name="smv_process" msgid="5120397012047462446">"ဤ<xliff:g id="PROCESS">%1$s</xliff:g>ဖြစ်စဥ်မှာ ကိုယ်တိုင်အကျိုးသက်ရောက်သော StrictModeမူဝါဒအား ချိုးဖောက်သည်"</string>
     <string name="android_upgrading_title" msgid="1584192285441405746">"အန်ဒရွိုက်ကို မွမ်းမံနေ…"</string>
     <string name="android_upgrading_apk" msgid="7904042682111526169">"<xliff:g id="NUMBER_0">%1$d</xliff:g> ထဲက app<xliff:g id="NUMBER_1">%2$d</xliff:g>ကို ဆီလျော်အောင် လုပ်နေ"</string>
     <string name="android_upgrading_starting_apps" msgid="451464516346926713">"appများကို စတင်နေ"</string>
-    <string name="android_upgrading_complete" msgid="1405954754112999229">"လုပ်ငန်းစနစ်ထည့်သွင်း၍ ပြန်လည်စတင်ရန် ပြီးပါပြီ"</string>
+    <string name="android_upgrading_complete" msgid="1405954754112999229">"လုပ်ငန်းစနစ်ထည့်သွင်း၍ ပြန်လည်စတင်ရန် ပြီးပါပြီ"</string>
     <string name="heavy_weight_notification" msgid="9087063985776626166">"<xliff:g id="APP">%1$s</xliff:g> က အလုပ်လုပ်နေသည်"</string>
     <string name="heavy_weight_notification_detail" msgid="1721681741617898865">"ppဆီ ပြောင်းရန် ထိပါ"</string>
     <string name="heavy_weight_switcher_title" msgid="7153167085403298169">"appများကို ပြောင်းမလား?"</string>
     <string name="heavy_weight_switcher_text" msgid="7022631924534406403">"အခြား app တစ်ခု အလုပ်လုပ်နေ၍ သင်က အသစ် တစ်ခုကို မစမီ ၎င်းကို ရပ်ပစ်ရမည်။"</string>
     <string name="old_app_action" msgid="493129172238566282">"<xliff:g id="OLD_APP">%1$s</xliff:g>သို့ပြန်သွားရန်"</string>
-    <string name="old_app_description" msgid="2082094275580358049">"pp အသစ်ကို မစတင်ပါနှင့်။"</string>
+    <string name="old_app_description" msgid="2082094275580358049">"pp အသစ်ကို မစတင်ပါနှင့်။"</string>
     <string name="new_app_action" msgid="5472756926945440706">"<xliff:g id="OLD_APP">%1$s</xliff:g>စတင်ပါ"</string>
     <string name="new_app_description" msgid="1932143598371537340">"app အဟောင်းကို မသိမ်းဆည်းဘဲ ရပ်လိုက်ပါ။"</string>
     <string name="sendText" msgid="5209874571959469142">"စာတိုအတွက် လုပ်ဆောင်ချက် ရေးပါ"</string>
     <string name="volume_ringtone" msgid="6885421406845734650">"ဖုန်းမြည်သံအတိုးအကျယ်"</string>
     <string name="volume_music" msgid="5421651157138628171">"မီဒီယာအသံအတိုးအကျယ်"</string>
-    <string name="volume_music_hint_playing_through_bluetooth" msgid="9165984379394601533">"ဘလူးတူးသ်မှတဆင့်ဖွင့်ရန်"</string>
+    <string name="volume_music_hint_playing_through_bluetooth" msgid="9165984379394601533">"ဘလူးတူးသ်မှတဆင့်ဖွင့်ရန်"</string>
     <string name="volume_music_hint_silent_ringtone_selected" msgid="8310739960973156272">"အသံတိတ် မြည်သံ သတ်မှတ်ရန်"</string>
     <string name="volume_call" msgid="3941680041282788711">"ခေါ်ဆိုနေခြင်းအသံအတိုးအကျယ်"</string>
-    <string name="volume_bluetooth_call" msgid="2002891926351151534">"ဘလူးတုသ်ဖြင့် ခေါ်ဆိုနေခြင်းအသံအတိုးအကျယ်"</string>
+    <string name="volume_bluetooth_call" msgid="2002891926351151534">"ဘလူးတုသ်ဖြင့် ခေါ်ဆိုနေခြင်းအသံအတိုးအကျယ်"</string>
     <string name="volume_alarm" msgid="1985191616042689100">"နှိုးစက်သံအတိုးအကျယ်"</string>
     <string name="volume_notification" msgid="2422265656744276715">"အကြောင်းကြားသံအတိုးအကျယ်"</string>
     <string name="volume_unknown" msgid="1400219669770445902">"အသံအတိုးအကျယ်"</string>
@@ -1266,8 +1265,8 @@
     <item quantity="other" msgid="4192424489168397386">"ဝိုင်ဖိုင်ကွန်ယက်များရှိသည်"</item>
   </plurals>
   <plurals name="wifi_available_detailed">
-    <item quantity="one" msgid="1634101450343277345">"ဖွင့်ထားသောဝိုင်ဖိုင်ကွန်ယက်ရှိသည်"</item>
-    <item quantity="other" msgid="7915895323644292768">"ဖွင့်ထားသောဝိုင်ဖိုင်ကွန်ယက်များရှိသည်"</item>
+    <item quantity="one" msgid="1634101450343277345">"ဖွင့်ထားသောဝိုင်ဖိုင်ကွန်ယက်ရှိသည်"</item>
+    <item quantity="other" msgid="7915895323644292768">"ဖွင့်ထားသောဝိုင်ဖိုင်ကွန်ယက်များရှိသည်"</item>
   </plurals>
     <string name="wifi_available_sign_in" msgid="4029489716605255386">"ဝိုင်ဖိုင်ကွန်ရက်သို့ ဝင်ပါ"</string>
     <string name="network_available_sign_in" msgid="8495155593358054676">"ကွန်ရက်သို့ ဝင်ပါ"</string>
@@ -1278,7 +1277,7 @@
     <string name="wifi_p2p_dialog_title" msgid="97611782659324517">"တိုက်ရိုက် ဝိုင်ဖိုင်"</string>
     <string name="wifi_p2p_turnon_message" msgid="2909250942299627244">"တိုက်ရိုက်ဝိုင်ဖိုင်ကို စတင်ပါ။ ၎င်းသည် ဝိုင်ဖိုင် ဟော့စပေါ့ကို ရပ်ဆိုင်းစေမှာ ဖြစ်ပါသည်။"</string>
     <string name="wifi_p2p_failed_message" msgid="3763669677935623084">"တိုက်ရိုက်ဝိုင်ဖိုင်ကို စတင်လို့ မရပါ"</string>
-    <string name="wifi_p2p_enabled_notification_title" msgid="2068321881673734886">"ဝိုင်ဖိုင် တိုက်ရိုက် ကိုဖွင့်ထားသည်"</string>
+    <string name="wifi_p2p_enabled_notification_title" msgid="2068321881673734886">"ဝိုင်ဖိုင် တိုက်ရိုက် ကိုဖွင့်ထားသည်"</string>
     <string name="wifi_p2p_enabled_notification_message" msgid="1638949953993894335">"အပြင်အဆင်များအတွက်ထိပါ"</string>
     <string name="accept" msgid="1645267259272829559">"လက်ခံရန်"</string>
     <string name="decline" msgid="2112225451706137894">"လက်မခံပါ"</string>
@@ -1290,25 +1289,25 @@
     <string name="wifi_p2p_show_pin_message" msgid="8530563323880921094">"ပင် နံပါတ်:"</string>
     <string name="wifi_p2p_frequency_conflict_message" product="tablet" msgid="8012981257742232475">"<xliff:g id="DEVICE_NAME">%1$s</xliff:g> နှင့် ဆက်သွယ်ထားစဉ် တက်ဘလက်ဟာ ဝိုင်ဖိုင် နှင့် ဆက်သွယ်မှု ရပ်ဆိုင်းထားမှာ ဖြစ်ပါတယ်"</string>
     <string name="wifi_p2p_frequency_conflict_message" product="default" msgid="7363907213787469151">"<xliff:g id="DEVICE_NAME">%1$s</xliff:g> ကို ဆက်သွယ်ထားစဉ် ဖုန်းအား ဝိုင်ဖိုင်မှ ဆက်သွယ်မှု ရပ်ဆိုင်းထားပါမည်"</string>
-    <string name="select_character" msgid="3365550120617701745">"စာရိုက်ထည့်ရန်"</string>
-    <string name="sms_control_title" msgid="7296612781128917719">"စာတိုပို့စနစ်(SMS)ဖြင့် စာများ ပို့သည်"</string>
+    <string name="select_character" msgid="3365550120617701745">"စာရိုက်ထည့်ရန်"</string>
+    <string name="sms_control_title" msgid="7296612781128917719">"စာတိုပို့စနစ်(SMS)ဖြင့် စာများ ပို့သည်"</string>
     <string name="sms_control_message" msgid="3867899169651496433">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; မှ စာ အမြောက်အများ ပို့နေပါသည်။ ဒီအပလီကေးရှင်းကို ဆက်လက်ပြီး လုပ်ဆောင်ရန် ခွင့်ပြုပါမလား"</string>
     <string name="sms_control_yes" msgid="3663725993855816807">"ခွင့်ပြုရန်"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ငြင်းပယ်ခြင်း"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; မှ &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; ကို စာတို ပို့ချင်ပါသည်"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"ဒီ "<font fgcolor="#ffffb060">"သည် သင့် မိုဘိုင်းအကောင့်တွင်"</font>" အကုန်အကျ ဖြစ်စေနိုင်ပါသည်"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"သင့်မိုဘိုင်း အကောင့်တွင် ပိုက်ဆံကုန်ကျပါမည်"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"ဒါက သင့် မိုဘိုင်း အကောင့် အတွက် "</b>" ကုန်ကျမှု ရှိလာနိုင်သည်။"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"ဒါက သင့် မိုဘိုင်း အကောင့် အတွက် ကုန်ကျမှု ရှိလာနိုင်သည်။"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ပို့ရန်"</string>
-    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ပယ်ဖျက်သည်"</string>
+    <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"နေတော့"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"ကျွန်ပ်၏ရွေးချယ်မှုကို မှတ်ထားရန်"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"နောင်တွင် ဆက်တင် &gt; အပလီကေးရှင်းများ မှပြောင်းနိုင်သည်"</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"အမြဲခွင့်ပြုရန်"</string>
     <string name="sms_short_code_confirm_never_allow" msgid="446992765774269673">"ဘယ်တော့မှခွင့်မပြုပါ"</string>
     <string name="sim_removed_title" msgid="6227712319223226185">"SIMကဒ်ဖယ်ရှားခြင်း"</string>
-    <string name="sim_removed_message" msgid="5450336489923274918">"သင်က မှန်ကန်သည့် ဆင်းမ် ကဒ် တစ်ခုနှင့် ပြန်မစမချင်း ဆယ်လူလာ ကွန်ရက်ကို ရှာတွေ့မည် မဟုတ်ပါ။"</string>
+    <string name="sim_removed_message" msgid="5450336489923274918">"သင်က မှန်ကန်သည့် ဆင်းမ် ကဒ် တစ်ခုနှင့် ပြန်မစမချင်း ဆယ်လူလာ ကွန်ရက်ကို ရှာတွေ့မည် မဟုတ်ပါ။"</string>
     <string name="sim_done_button" msgid="827949989369963775">"ပြီးပါပြီ"</string>
-    <string name="sim_added_title" msgid="3719670512889674693">"ဆင်းမ်ကဒ် ထည့်ပါသည်"</string>
-    <string name="sim_added_message" msgid="7797975656153714319">"ဆယ်လူလာ ကွန်ရက်ကို ရယူသုံးရန် သင့် ကိရိယာကို ပြန်ဖွင့်ပေးပါ။"</string>
+    <string name="sim_added_title" msgid="3719670512889674693">"ဆင်းမ်ကဒ် ထည့်ပါသည်"</string>
+    <string name="sim_added_message" msgid="7797975656153714319">"ဆယ်လူလာ ကွန်ရက်ကို ရယူသုံးရန် သင့် ကိရိယာကို ပြန်ဖွင့်ပေးပါ။"</string>
     <string name="sim_restart_button" msgid="4722407842815232347">"အစက ပြန်စရန်"</string>
     <string name="time_picker_dialog_title" msgid="8349362623068819295">"အချိန်သတ်မှတ်ရန်"</string>
     <string name="date_picker_dialog_title" msgid="5879450659453782278">"ရက်စွဲ အတည်ပြုရန်"</string>
@@ -1316,13 +1315,13 @@
     <string name="date_time_done" msgid="2507683751759308828">"ပြီးပါပြီ"</string>
     <string name="perms_new_perm_prefix" msgid="8257740710754301407"><font size="12" fgcolor="#ff33b5e5">"အသစ်: "</font></string>
     <string name="perms_description_app" msgid="5139836143293299417">"<xliff:g id="APP_NAME">%1$s</xliff:g> မှ ထောက်ပံ့သည်"</string>
-    <string name="no_permissions" msgid="7283357728219338112">"ခွင့်ပြုချက်မလိုအပ်ပါ"</string>
+    <string name="no_permissions" msgid="7283357728219338112">"ခွင့်ပြုချက်မလိုအပ်ပါ"</string>
     <string name="perm_costs_money" msgid="4902470324142151116">"သင့်အတွက် ပိုက်ဆံကုန်ကျနိုင်ပါသည်"</string>
     <string name="usb_storage_activity_title" msgid="4465055157209648641">"USB ဖြင့်အချက်အလက်မြောက်များစွာ သိမ်းဆည်းနိုင်သော နေရာ"</string>
     <string name="usb_storage_title" msgid="5901459041398751495">"USB ချိန်ဆက်ထားပြီး"</string>
     <string name="usb_storage_message" product="nosdcard" msgid="3308538094316477839">"သင့်ကွန်ပျူတာကို USB မှ တဆင့် ဆက်သွယ်ထားပါသည်။ ကွန်ပျူတာနဲ့ အန်းဒရွိုက်၏ USB သိုလှောင်မှု အကြား အချက်အလက် လွှဲပြောင်းရန် တို့ထိပါ"</string>
     <string name="usb_storage_message" product="default" msgid="805351000446037811">"သင့်ကွန်ပျူတာကို USB မှ တဆင့် ဆက်သွယ်ထားပါသည်။ ကွန်ပျူတာနဲ့ အန်းဒရွိုက်၏ SD ကဒ် အကြား အချက်အလက် လွှဲပြောင်းရန် တို့ထိပါ"</string>
-    <string name="usb_storage_button_mount" msgid="1052259930369508235">"USBသိမ်းဆည်းခြင်းကိုဖွင့်ရန်"</string>
+    <string name="usb_storage_button_mount" msgid="1052259930369508235">"USBသိမ်းဆည်းခြင်းကိုဖွင့်ရန်"</string>
     <string name="usb_storage_error_message" product="nosdcard" msgid="3017045217365540658">"USB ကို သုံးပြီး USB ဖြင့်အချက်အလက်မြောက်များစွာ သိမ်းဆည်းနိုင်သော နေရာတွင် ပြသနာ ဖြစ်နေပါသည်"</string>
     <string name="usb_storage_error_message" product="default" msgid="2876018512716970313">"SD card ကို သုံးပြီး USB ဖြင့်အချက်အလက်မြောက်များစွာ သိမ်းဆည်းနိုင်သော နေရာတွင် ပြသနာ ဖြစ်နေပါသည်"</string>
     <string name="usb_storage_notification_title" msgid="8175892554757216525">"USB ချိန်ဆက်ထားပြီး"</string>
@@ -1334,33 +1333,33 @@
     <string name="usb_storage_stop_message" product="default" msgid="8043969782460613114">"USB သိုလှောင်မှုကို မပိတ်ခင်, ကွန်ပျူတာမှ Android ၏ SD ကဒ်ကို ဖြုတ်ပါ (\"eject\")"</string>
     <string name="usb_storage_stop_button_mount" msgid="7060218034900696029">"USBသိမ်းဆည်းခြင်းကိုပိတ်ရန်"</string>
     <string name="usb_storage_stop_error_message" msgid="1970374898263063836">"USB သိုလှောင်မှု ပိတ်ရာတွင် ပြသနာရှိပါသည်။ USB လာရာအား မဆက်သွယ်ထားကြောင်း စစ်ဆေးပြီး ပြန်လည်ကြိုးစားပါ"</string>
-    <string name="dlg_confirm_kill_storage_users_title" msgid="963039033470478697">"USBသိမ်းဆည်းခြင်းကိုဖွင့်ရန်"</string>
+    <string name="dlg_confirm_kill_storage_users_title" msgid="963039033470478697">"USBသိမ်းဆည်းခြင်းကိုဖွင့်ရန်"</string>
     <string name="dlg_confirm_kill_storage_users_text" msgid="5100428757107469454">"သင် ယူအက်စ်ဘီ နဲ့ သိမ်းဆည်းမှုကို ဖွင့်လိုက်ပါက တချို့ အပလီကေးရှင်းများ က ယူအက်စ်ဘီ နဲ့ သိမ်းဆည်းမှု ပြန်ပိတ်သည်အထိ အလုပ်မလုပ် သို့ သုံးစွဲရန် ရှိနေမည် မဟုတ်ပါ"</string>
     <string name="dlg_error_title" msgid="7323658469626514207">"USBဆောင်ရွက်မှုမအောင်မြင်ပါ"</string>
     <string name="dlg_ok" msgid="7376953167039865701">"ကောင်းပြီ"</string>
-    <string name="usb_mtp_notification_title" msgid="3699913097391550394">"မီဒီယာစက်အနေဖြင့် ချိတ်ဆက်သည်"</string>
-    <string name="usb_ptp_notification_title" msgid="1960817192216064833">"ကင်မရာအနေဖြင့်ဆက်သွယ်ခြင်း"</string>
-    <string name="usb_cd_installer_notification_title" msgid="6774712827892090754">"installerအနေဖြင့် ချိတ်ဆက်သည်"</string>
+    <string name="usb_mtp_notification_title" msgid="3699913097391550394">"မီဒီယာစက်အနေဖြင့် ချိတ်ဆက်သည်"</string>
+    <string name="usb_ptp_notification_title" msgid="1960817192216064833">"ကင်မရာအနေဖြင့်ဆက်သွယ်ခြင်း"</string>
+    <string name="usb_cd_installer_notification_title" msgid="6774712827892090754">"installerအနေဖြင့် ချိတ်ဆက်သည်"</string>
     <string name="usb_accessory_notification_title" msgid="7848236974087653666">"USBတွဲဖက်ပစ္စည်းအား ချိတ်ဆက်ထားသည်"</string>
     <string name="usb_notification_message" msgid="2290859399983720271">"အခြား USB စိတ်ကြိုက်ရွေးချယ်ခွင့်များ အတွက် တို့ထိပါ။"</string>
     <string name="extmedia_format_title" product="nosdcard" msgid="9020092196061007262">"USB သိုလှောင်ခန်းကို ပုံစံပြန်ချမလား?"</string>
     <string name="extmedia_format_title" product="default" msgid="3648415921526526069">"SD ကဒ်ကို ပုံစံပြန်ချမလား?"</string>
-    <string name="extmedia_format_message" product="nosdcard" msgid="3934016853425761078">"သင်၏ USB သိုလှောင်ခန်းထဲ သိုလှောင်ထားသည့် ဖိုင်အားလုံး ဖျက်ခံရမည်။ ဒီလုပ်ရပ်ကို ပြန်ပြီး ပြောင်းလဲ မရနိုင်ပါ။"</string>
-    <string name="extmedia_format_message" product="default" msgid="14131895027543830">"သင့် ကဒ် ထဲက ဒေတာ အားလုံး ဆုံးသွားမည်။"</string>
+    <string name="extmedia_format_message" product="nosdcard" msgid="3934016853425761078">"သင်၏ USB သိုလှောင်ခန်းထဲ သိုလှောင်ထားသည့် ဖိုင်အားလုံး ဖျက်ခံရမည်။ ဒီလုပ်ရပ်ကို ပြန်ပြီး ပြောင်းလဲ မရနိုင်ပါ။"</string>
+    <string name="extmedia_format_message" product="default" msgid="14131895027543830">"သင့် ကဒ် ထဲက ဒေတာ အားလုံး ဆုံးသွားမည်။"</string>
     <string name="extmedia_format_button_format" msgid="4131064560127478695">"ပုံစံချရန်ပြင်ဆင်သည်"</string>
     <string name="adb_active_notification_title" msgid="6729044778949189918">"USB အမှားစစ်ခြင်းအား ချိတ်ဆက်ထားသည်"</string>
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB ဒီဘာဂင် ပိတ်ရန် ထိပါ။"</string>
     <string name="select_input_method" msgid="8547250819326693584">"ကီးဘုတ် ပြောင်းလဲရန်"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"ကီးဘုတ်များကို ရွေးရန်"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"ခလုတ်ပါဝင်သော ကီးဘုတ်"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ရိုက်သွင်းမှု နည်းလမ်းကို ပြရန်"</string>
     <string name="hardware" msgid="7517821086888990278">"ဟာ့ဒ်ဝဲ"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"လက်ကွက် အပြင်အဆင်ရွေးရန်"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"လက်ကွက် အပြင်အဆင်ရွေးရန် တို့ထိပါ"</string>
     <string name="fast_scroll_alphabet" msgid="5433275485499039199">" ABCDEFGHIJKLMNOPQRSTUVWXYZ"</string>
     <string name="fast_scroll_numeric_alphabet" msgid="4030170524595123610">" 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"</string>
-    <string name="candidates_style" msgid="4333913089637062257"><u>"ရွေးချယ်ခံမည့်သူ"</u></string>
-    <string name="ext_media_checking_notification_title" product="nosdcard" msgid="3449816005351468560">"USBသိမ်းဆည်းသည့်အရာအားအဆင်သင့်စေရန်ပြုလုပ်ခြင်း"</string>
-    <string name="ext_media_checking_notification_title" product="default" msgid="5457603418970994050">"SDကဒ်အအဆင်သင့်စေရန်ပြုလုပ်ခြင်း"</string>
+    <string name="candidates_style" msgid="4333913089637062257"><u>"ရွေးချယ်ခံမည့်သူ"</u></string>
+    <string name="ext_media_checking_notification_title" product="nosdcard" msgid="3449816005351468560">"USBသိမ်းဆည်းသည့်အရာအားအဆင်သင့်စေရန်ပြုလုပ်ခြင်း"</string>
+    <string name="ext_media_checking_notification_title" product="default" msgid="5457603418970994050">"SDကဒ်အအဆင်သင့်စေရန်ပြုလုပ်ခြင်း"</string>
     <string name="ext_media_checking_notification_message" msgid="8287319882926737053">"မှားယွင်းမှုရှိမရှိစစ်ခြင်း"</string>
     <string name="ext_media_nofs_notification_title" product="nosdcard" msgid="7788040745686229307">"USBသိမ်းဆည်းမှု၌ ဘာမှမရှိပါ"</string>
     <string name="ext_media_nofs_notification_title" product="default" msgid="780477838241212997">"SDကဒ်ထဲ၌ဘာမှမရှိပါ"</string>
@@ -1372,19 +1371,19 @@
     <string name="ext_media_unmountable_notification_message" product="default" msgid="1753898567525568253">"SD ကဒ် ပျက်စီးနေပါသည်။ ပြန်လည် ဖောမက် ချကြည့်ပါ"</string>
     <string name="ext_media_badremoval_notification_title" product="nosdcard" msgid="1661683031330951073">"မရည်ရွယ်ပဲ USBသိုလှောင်ကိရိယာဖယ်ရှားသည်"</string>
     <string name="ext_media_badremoval_notification_title" product="default" msgid="6872152882604407837">"မထင်မှတ်ပဲSDကဒ်ဖြုတ်သည်"</string>
-    <string name="ext_media_badremoval_notification_message" product="nosdcard" msgid="4329848819865594241">"ဒေတာမဆုံးရှုံးစေရန် မပြုတ်ခင် USB သိမ်းဆည်းခြင်းအား မဖြုတ်ပါနှင့်"</string>
+    <string name="ext_media_badremoval_notification_message" product="nosdcard" msgid="4329848819865594241">"ဒေတာမဆုံးရှုံးစေရန် မပြုတ်ခင် USB သိမ်းဆည်းခြင်းအား မဖြုတ်ပါနှင့်"</string>
     <string name="ext_media_badremoval_notification_message" product="default" msgid="7260183293747448241">"ဒေတာမဆုံးရှုံးစေရန် မပြုတ်ခင် SDကဒ်အားမတပ်ရန်"</string>
     <string name="ext_media_safe_unmount_notification_title" product="nosdcard" msgid="3967973893270360230">"USB ကိရိယာအား ဖြုတ်နိုင်သည်"</string>
     <string name="ext_media_safe_unmount_notification_title" product="default" msgid="6729801130790616200">"အန္တရာယ်ကင်းစွာSDကဒ်အား ဖယ်နိုင်ပါပြီ"</string>
-    <string name="ext_media_safe_unmount_notification_message" product="nosdcard" msgid="6142195361606493530">"USBသိမ်းဆည်းသည့်အရာအား အန္တရာယ်ကင်းစွာဖယ်နိုင်ပါပြီ"</string>
+    <string name="ext_media_safe_unmount_notification_message" product="nosdcard" msgid="6142195361606493530">"USBသိမ်းဆည်းသည့်အရာအား အန္တရာယ်ကင်းစွာဖယ်နိုင်ပါပြီ"</string>
     <string name="ext_media_safe_unmount_notification_message" product="default" msgid="568841278138377604">"SDကဒ်အား အန္တရာယ်ကင်းစွာဖယ်နိုင်ပါပြီ"</string>
     <string name="ext_media_nomedia_notification_title" product="nosdcard" msgid="4486377230140227651">"USBသိုလှောင်ကိရိယာအား ဖြုတ်သည်"</string>
     <string name="ext_media_nomedia_notification_title" product="default" msgid="8902518030404381318">"SDကဒ်ဖယ်ထားသည်"</string>
-    <string name="ext_media_nomedia_notification_message" product="nosdcard" msgid="6921126162580574143">"USBသိမ်းဆည်းသည့်အရာ ဖယ်ရှားလိုက်သည်။ နောက်မီဒီယာအသစ်တခုအားထည့်ပါ။"</string>
-    <string name="ext_media_nomedia_notification_message" product="default" msgid="3870120652983659641">"SDကဒ်အားဖယ်ရှားလိုက်သည်။ နောက်အသစ်တခုအားထည့်ပါ။"</string>
+    <string name="ext_media_nomedia_notification_message" product="nosdcard" msgid="6921126162580574143">"USBသိမ်းဆည်းသည့်အရာ ဖယ်ရှားလိုက်သည်။ နောက်မီဒီယာအသစ်တခုအားထည့်ပါ။"</string>
+    <string name="ext_media_nomedia_notification_message" product="default" msgid="3870120652983659641">"SDကဒ်အားဖယ်ရှားလိုက်သည်။ နောက်အသစ်တခုအားထည့်ပါ။"</string>
     <string name="activity_list_empty" msgid="1675388330786841066">"တိုက်ဆိုင်သော ပြုလုပ်ချက် ရှာမတွေ့ပါ"</string>
-    <string name="permlab_pkgUsageStats" msgid="8787352074326748892">"အစိတ်အပိုင်းများသုံစွဲခြင်း ကိန်းဂဏန်းအချက်အလက်များကို အဆင်မြှင့်ရန်ပြုလုပ်ခြင်း"</string>
-    <string name="permdesc_pkgUsageStats" msgid="1106612424254277630">"appအား စုစည်းထားသည့် အစိတ်အပိုင်း၏ သုံးစွဲမှု စာရင်းအင်းများကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
+    <string name="permlab_pkgUsageStats" msgid="8787352074326748892">"အစိတ်အပိုင်းများသုံစွဲခြင်း ကိန်းဂဏန်းအချက်အလက်များကို အဆင်မြှင့်ရန်ပြုလုပ်ခြင်း"</string>
+    <string name="permdesc_pkgUsageStats" msgid="1106612424254277630">"appအား စုစည်းထားသည့် အစိတ်အပိုင်း၏ သုံးစွဲမှု စာရင်းအင်းများကို မွမ်းမံခွင့် ပြုသည်။ သာမန် appများ အသုံးပြုရန် မဟုတ်ပါ။"</string>
     <string name="permlab_copyProtectedData" msgid="4341036311211406692">"အကြောင်းအရာ ကော်ပီ လုပ်ရန်"</string>
     <string name="permdesc_copyProtectedData" msgid="4390697124288317831">"appအား ပုံသေ ကွန်တင်နား  ဝန်ဆောင်မှု၏ အကြောင်းအရာကို ကူးယူရန် တောင်းခံနိုင်သည်။ သာမန် appများ သုံးရန် မဟုတ်ပါ။"</string>
     <string name="permlab_route_media_output" msgid="1642024455750414694">"မီဒီယာထွက်ပေါက်အား လမ်းလွှဲပြောင်းခြင်း"</string>
@@ -1394,40 +1393,40 @@
     <string name="permlab_control_keyguard" msgid="172195184207828387">"keyguard အား ပြသခြင်း ကွယ်ဖျောက်ခြင်းများအား ထိန်းချုပ်ခြင်း"</string>
     <string name="permdesc_control_keyguard" msgid="3043732290518629061">"အပလီကေးရှင်း ကို keguard secure storage အား ထိန်းချုပ်ခွင့်ပေးခြင်း"</string>
     <string name="permlab_trust_listener" msgid="1765718054003704476">"ယုံကြည်မှု အခြေအနေ ပြောင်းလဲမှုများကို စူးစမ်းခြင်း။"</string>
-    <string name="permdesc_trust_listener" msgid="8233895334214716864">"အပလီကေးရှင်းအား ယုံကြည်မှု အခြေအနေ ထဲက အပြောင်းအလဲများကို စူးစမ်းခွင့် ပြုသည်။"</string>
-    <string name="permlab_provide_trust_agent" msgid="5465587586091358316">"ယုံကြည်မှု အေဂျင့် စီစဉ်ပေးသည်။"</string>
-    <string name="permdesc_provide_trust_agent" msgid="3865702641053068148">"အပလီကေးရှင်းအား ယုံကြည်မှု အေဂျင့် စီစဉ်ခွင့် ပေးသည်။"</string>
-    <string name="permlab_launch_trust_agent_settings" msgid="5859430082240410200">"ယုံကြည်ရ အေဂျင့် ဆက်တင် မီနူး ဖွင့်တင်ပါ။"</string>
-    <string name="permdesc_launch_trust_agent_settings" msgid="8185142708644913381">"အပလီကေးရှင်း တစ်ခုအား ယုံကြည်ရ အေဂျင့်၏ ပြုမူပုံကို ပြောင်းလဲစေနိုင်သည့် လှုပ်ရှားမှု တစ်ခုကို ဖွင့်တင်ခွင့် ပြုသည်။"</string>
-    <string name="permlab_bind_trust_agent_service" msgid="8242093169457695334">"ယုံကြည်မှု အေဂျင့် ဝန်ဆောင်မှု တစ်ခုဆီသို့ ချိတ်တွဲခြင်း"</string>
-    <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"စွဲကိုင်ထားသူအား ယုံကြည်မှု အေဂျင့် ဝန်ဆောင်မှုသို့ ချိတ်တွဲခွင့်ကို ပေးသည်။"</string>
+    <string name="permdesc_trust_listener" msgid="8233895334214716864">"အပလီကေးရှင်းအား ယုံကြည်မှု အခြေအနေ ထဲက အပြောင်းအလဲများကို စူးစမ်းခွင့် ပြုသည်။"</string>
+    <string name="permlab_provide_trust_agent" msgid="5465587586091358316">"ယုံကြည်မှု အေဂျင့် စီစဉ်ပေးသည်။"</string>
+    <string name="permdesc_provide_trust_agent" msgid="3865702641053068148">"အပလီကေးရှင်းအား ယုံကြည်မှု အေဂျင့် စီစဉ်ခွင့် ပေးသည်။"</string>
+    <string name="permlab_launch_trust_agent_settings" msgid="5859430082240410200">"ယုံကြည်ရ အေဂျင့် ဆက်တင် မီနူး ဖွင့်တင်ပါ။"</string>
+    <string name="permdesc_launch_trust_agent_settings" msgid="8185142708644913381">"အပလီကေးရှင်း တစ်ခုအား ယုံကြည်ရ အေဂျင့်၏ ပြုမူပုံကို ပြောင်းလဲစေနိုင်သည့် လှုပ်ရှားမှု တစ်ခုကို ဖွင့်တင်ခွင့် ပြုသည်။"</string>
+    <string name="permlab_bind_trust_agent_service" msgid="8242093169457695334">"ယုံကြည်မှု အေဂျင့် ဝန်ဆောင်မှု တစ်ခုဆီသို့ ချိတ်တွဲခြင်း"</string>
+    <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"စွဲကိုင်ထားသူအား ယုံကြည်မှု အေဂျင့် ဝန်ဆောင်မှုသို့ ချိတ်တွဲခွင့်ကို ပေးသည်။"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"အဆင့်မြှင့်ခြင်းနဲ့ ပြန်လည် ထိန်းသိမ်းခြင်း များနှင့် ဆက်ဆံစေခြင်း"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"အပလီကေးရှင်းအား စစ်စတန်အား ပြန်လည် ကယ်ဆယ်မှု နဲ့ အဆင့်မြှင့်ခြင်းများအား လုပ်ဆောင်ခွင့် ပေးခြင်း"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"မီဒီယာ အနာဂတ် ချိတ်ဆက်မှုများကို ဖန်တီးရန်"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"အပလီကေးရှင်း တစ်ခုအား မီဒီယာ အနာဂတ် ချိတ်ဆက်မှုများကို ဖန်တီးခွင့် ပြုသည်။ ယင်း ချိတ်ဆက်မှုများ ထဲမှာ အပလီကေးရှင်းအား ပြသမှု နှင့် အသံ အကြောင်းအရာများကို ဖမ်းယူခွင့် ပေးနိုင်သည်။ သာမန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"မီဒီယာ ပရိုဂျက် ချိတ်ဆက်မှုများကို စီမံကွပ်ကဲခြင်း"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"အပလီကေးရှင်းအား မီဒီယာ ပရိုဂျက် ချိတ်ဆက်မှုများကို စီမံကွပ်ကဲခွင့် ပြုသည်။ ယင်း ချိတ်ဆက်မှုများ အတွင်းမှာ အပလီကေးရှင်း အတွက် ပြသမှု နှင့် အသံ အကြောင်းအရာများကို ဖမ်းယူရေး အခွင့်အလမ်းများကို စီမံပေးနိုင်သည်။ ပုံမှန် appများ အတွက် ဘယ်တော့မှ မလိုအပ်နိုင်ပါ။"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"တပ်ဆင်ရေး ချိတ်ဆက်မှုများကို ဖတ်ရန်"</string>
-    <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"အပလီကေးရှင်းအား တပ်ဆင်ရေး ချိတ်ဆက်မှုများကို ဖတ်ခွင့်ပြုသည်။ ၎င်းသည် ဖွင့်သုံးနေသည့် အထုပ်အား တပ်ဆင်မှုဆိုင်ရာ အသေးိစတ်များကို ကြည့်ရှုခွင့် ပြုသည်။"</string>
+    <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"အပလီကေးရှင်းအား တပ်ဆင်ရေး ချိတ်ဆက်မှုများကို ဖတ်ခွင့်ပြုသည်။ ၎င်းသည် ဖွင့်သုံးနေသည့် အထုပ်အား တပ်ဆင်မှုဆိုင်ရာ အသေးိစတ်များကို ကြည့်ရှုခွင့် ပြုသည်။"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"ချုံ့ချဲ့မှုကို ထိန်းချုပ်ရန် အတွက် နှစ်ကြိမ် ထိပါ"</string>
     <string name="gadget_host_error_inflating" msgid="4882004314906466162">"ဝဒ်ဂျက်ထည့်လို့ မရပါ"</string>
     <string name="ime_action_go" msgid="8320845651737369027">"သွားပါ"</string>
     <string name="ime_action_search" msgid="658110271822807811">"ရှာဖွေခြင်း"</string>
     <string name="ime_action_send" msgid="2316166556349314424">"ပို့ခြင်း"</string>
-    <string name="ime_action_next" msgid="3138843904009813834">"အရှေ့သို့"</string>
+    <string name="ime_action_next" msgid="3138843904009813834">"ရှေ့သို့"</string>
     <string name="ime_action_done" msgid="8971516117910934605">"ပြီးပါပြီ"</string>
     <string name="ime_action_previous" msgid="1443550039250105948">"အနောက်သို့"</string>
     <string name="ime_action_default" msgid="2840921885558045721">"လုပ်ဆောင်ချက်"</string>
     <string name="dial_number_using" msgid="5789176425167573586">\n"အား အသုံးပြု၍ <xliff:g id="NUMBER">%s</xliff:g>နံပါတ်ခေါ်ဆိုပါ"</string>
-    <string name="create_contact_using" msgid="4947405226788104538">\n"အား အသုံးပြု၍<xliff:g id="NUMBER">%s</xliff:g>ဆက်သွယ်မည့်သူများအား ဖန်တီးခြင်း"</string>
-    <string name="grant_credentials_permission_message_header" msgid="2106103817937859662">"အောက်ပါထဲက app တစ်ခု သို့မဟုတ် ပိုလျက် သင်၏ အကောင့်ကို၊ ယခု နှင့် အနာဂတ်မှာ ရယူအသုံးချရန် ခွင့်ပြုချက်ကို တောင်းထားသည်။"</string>
-    <string name="grant_credentials_permission_message_footer" msgid="3125211343379376561">"ဤတောင်းခံမှုအားခွင့်ပြုမည်လား"</string>
+    <string name="create_contact_using" msgid="4947405226788104538">\n"အား အသုံးပြု၍<xliff:g id="NUMBER">%s</xliff:g>ဆက်သွယ်မည့်သူများအား ဖန်တီးခြင်း"</string>
+    <string name="grant_credentials_permission_message_header" msgid="2106103817937859662">"အောက်ပါထဲက app တစ်ခု သို့မဟုတ် ပိုလျက် သင်၏ အကောင့်ကို၊ ယခု နှင့် အနာဂတ်မှာ ရယူအသုံးချရန် ခွင့်ပြုချက်ကို တောင်းထားသည်။"</string>
+    <string name="grant_credentials_permission_message_footer" msgid="3125211343379376561">"ဤတောင်းခံမှုအားခွင့်ပြုမည်လား"</string>
     <string name="grant_permissions_header_text" msgid="6874497408201826708">"သုံးစွဲခွင့် တောင်းဆိုရန်"</string>
     <string name="allow" msgid="7225948811296386551">"ခွင့်ပြုသည်"</string>
     <string name="deny" msgid="2081879885755434506">"ငြင်းပယ်သည်"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"ခွင့်ပြုချက် တောင်းခံထားခြင်း"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"အကောင့် <xliff:g id="ACCOUNT">%s</xliff:g> အတွက် \n ခွင့်ပြုချက် တောင်းခံထားပြီး"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"သင်သည် ဒီappကို သင်၏ ကိုယ်ရေး နေရာထဲမှာ သုံးနေသည်။"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"သင်သည် ဒီappကို သင်၏ အလုပ် နေရာထဲမှာ သုံးနေသည်။"</string>
-    <string name="input_method_binding_label" msgid="1283557179944992649">"ထည့်သွင်းရန်နည်းလမ်း"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"သင်သည် ဒီappကို သင့်အလုပ်ပရိုဖိုင် ပြင်ပတွင် အသုံးပြုနေ၏"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"သင်သည် ဒီappကို သင်၏ အလုပ် ပရိုဖိုင် ထဲမှာ အသုံးပြုနေသည်"</string>
+    <string name="input_method_binding_label" msgid="1283557179944992649">"ထည့်သွင်းရန်နည်းလမ်း"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ထပ်တူ ကိုက်ညီခြင်း"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"အသုံးပြုခွင့်"</string>
     <string name="wallpaper_binding_label" msgid="1240087844304687662">"နောက်ခံ"</string>
@@ -1443,12 +1442,12 @@
     <string name="vpn_lockdown_error" msgid="6009249814034708175">"အမြဲတမ်းဖွင့်ထား VPN အမှား"</string>
     <string name="vpn_lockdown_config" msgid="6415899150671537970">"ပြင်ဆင်ရန် ထိလိုက်ပါ"</string>
     <string name="upload_file" msgid="2897957172366730416">"ဖိုင်ရွေးချယ်ရန်"</string>
-    <string name="no_file_chosen" msgid="6363648562170759465">"မည်သည့်ဖိုင်ကိုမှမရွေးပါ"</string>
+    <string name="no_file_chosen" msgid="6363648562170759465">"မည်သည့်ဖိုင်ကိုမှမရွေးပါ"</string>
     <string name="reset" msgid="2448168080964209908">"ပြန်လည်စတင်စေရန်"</string>
-    <string name="submit" msgid="1602335572089911941">"တင်​ပြရန်"</string>
+    <string name="submit" msgid="1602335572089911941">"တင်​ပြရန်​"</string>
     <string name="car_mode_disable_notification_title" msgid="3164768212003864316">"ကားထဲတွင်အသုံးပြုနိုင်သောစနစ် ရရှိနိုင်သည်"</string>
     <string name="car_mode_disable_notification_message" msgid="8035230537563503262">"ကားပေါ်ရောက် အခြေအနေမှ ထွက်ရန် ထိလိုက်ပါ"</string>
-    <string name="tethered_notification_title" msgid="3146694234398202601">"တဆင့်ပြန်လည်လွှင့်ခြင်း သို့မဟုတ် ဟော့စပေါ့ ဖွင့်ထားသည်"</string>
+    <string name="tethered_notification_title" msgid="3146694234398202601">"တဆင့်ပြန်လည်လွှင့်ခြင်း သို့မဟုတ် ဟော့စပေါ့ ဖွင့်ထားသည်"</string>
     <string name="tethered_notification_message" msgid="6857031760103062982">"အပြင်အဆင်ပြုလုပ်ရန် ပိုမိုသိနားလည်စေရန် တို့ထိပါ။"</string>
     <string name="back_button_label" msgid="2300470004503343439">"နောက်သို့"</string>
     <string name="next_button_label" msgid="1080555104677992408">"နောက်"</string>
@@ -1481,16 +1480,16 @@
     <string name="gpsNotifTicker" msgid="5622683912616496172">"<xliff:g id="NAME">%s</xliff:g>မှ တည်နေရာအား တောင်းခံသည်"</string>
     <string name="gpsNotifTitle" msgid="5446858717157416839">"တည်နေရာအား တောင်းခံသည်"</string>
     <string name="gpsNotifMessage" msgid="1374718023224000702">"<xliff:g id="NAME">%1$s</xliff:g> (<xliff:g id="SERVICE">%2$s</xliff:g>)မှတောင်းခံသည်"</string>
-    <string name="gpsVerifYes" msgid="2346566072867213563">"ဟုတ်သည်"</string>
+    <string name="gpsVerifYes" msgid="2346566072867213563">"ဟုတ်ကဲ့"</string>
     <string name="gpsVerifNo" msgid="1146564937346454865">"မဟုတ်ပါ"</string>
-    <string name="sync_too_many_deletes" msgid="5296321850662746890">"ပယ်ဖျက်မည့်ကန့်သတ်နှုန်းကျော်လွန်သည်"</string>
+    <string name="sync_too_many_deletes" msgid="5296321850662746890">"ပယ်ဖျက်မည့်ကန့်သတ်နှုန်းကျော်လွန်သည်"</string>
     <string name="sync_too_many_deletes_desc" msgid="496551671008694245">"<xliff:g id="TYPE_OF_SYNC">%2$s</xliff:g>၊  account <xliff:g id="ACCOUNT_NAME">%3$s</xliff:g> အတွက် စုစုပေါင်း <xliff:g id="NUMBER_OF_DELETED_ITEMS">%1$d</xliff:g> အရာဖျက်ထားပါသည်။ သင်ဘာလုပ်ချင်ပါလဲ?"</string>
     <string name="sync_really_delete" msgid="2572600103122596243">"ဤအရာများကိုဖျက်ပါ"</string>
     <string name="sync_undo_deletes" msgid="2941317360600338602">"ဖျက်ပီးသည်များကို ပယ်ဖျက်ရန်"</string>
     <string name="sync_do_nothing" msgid="3743764740430821845">"လက်ရှိ ဘာမှမလုပ်ရန်"</string>
-    <string name="choose_account_label" msgid="5655203089746423927">"အကောင့် တစ်ခု ရွေးပါ"</string>
-    <string name="add_account_label" msgid="2935267344849993553">"အကောင့် ထပ်ဖြည့်ပါ"</string>
-    <string name="add_account_button_label" msgid="3611982894853435874">"အကောင့်ထပ်ထည့်ရန်"</string>
+    <string name="choose_account_label" msgid="5655203089746423927">"အကောင့် တစ်ခု ရွေးပါ"</string>
+    <string name="add_account_label" msgid="2935267344849993553">"အကောင့် ထပ်ဖြည့်ပါ"</string>
+    <string name="add_account_button_label" msgid="3611982894853435874">"အကောင့်ထပ်ထည့်ရန်"</string>
     <string name="number_picker_increment_button" msgid="2412072272832284313">"တိုးရန်"</string>
     <string name="number_picker_decrement_button" msgid="476050778386779067">"လျှော့ရန်"</string>
     <string name="number_picker_increment_scroll_mode" msgid="3073101067441638428">"<xliff:g id="VALUE">%s</xliff:g> ကြာကြာ ဖိ ကိုင်ထားပါ"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"နာရီလျော့ရန်"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"မွန်းလွဲပိုင်း သတ်မှတ်ရန်"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"မနက်ပိုင်းချိန် သတ်မှတ်ရန်"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ညနေပိုင်း"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ညနေပိုင်း"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"လ တိုးရန်"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"လ လျှော့ရန်"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"ရက် တိုးရန်"</string>
@@ -1512,15 +1509,15 @@
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Altခလုတ်"</string>
     <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"ပယ်ဖျက်ရန်ခလုတ်"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"ဖျက်ရန်ခလုတ်"</string>
-    <string name="keyboardview_keycode_done" msgid="1992571118466679775">"ပြီးဆုံးသည့်ခလုတ်"</string>
+    <string name="keyboardview_keycode_done" msgid="1992571118466679775">"ပြီးဆုံးသည့်ခလုတ်"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"စနစ်ပြောင်းခြင်းခလုတ်"</string>
     <string name="keyboardview_keycode_shift" msgid="2270748814315147690">"Shiftခလုတ်"</string>
     <string name="keyboardview_keycode_enter" msgid="2985864015076059467">"Enterခလုတ်"</string>
     <string name="activitychooserview_choose_application" msgid="2125168057199941199">"app တစ်ခုကို ရွေးရန်"</string>
     <string name="activitychooserview_choose_application_error" msgid="8624618365481126668">"<xliff:g id="APPLICATION_NAME">%s</xliff:g> ကို စတင်လို့ မရပါ"</string>
     <string name="shareactionprovider_share_with" msgid="806688056141131819">"မျှဝေဖို့ ရွေးပါ"</string>
-    <string name="shareactionprovider_share_with_application" msgid="5627411384638389738">"<xliff:g id="APPLICATION_NAME">%s</xliff:g>နှင့် မျှဝေပါမည်"</string>
-    <string name="content_description_sliding_handle" msgid="415975056159262248">"ဆွဲယူနိုင်သည့် လက်ကိုင်။ ထိပါ &amp; ကိုင်ထားပါ။"</string>
+    <string name="shareactionprovider_share_with_application" msgid="5627411384638389738">"<xliff:g id="APPLICATION_NAME">%s</xliff:g>နှင့် မျှဝေပါမည်"</string>
+    <string name="content_description_sliding_handle" msgid="415975056159262248">"ဆွဲယူနိုင်သည့် လက်ကိုင်။ ထိပါ &amp; ကိုင်ထားပါ။"</string>
     <string name="description_target_unlock_tablet" msgid="3833195335629795055">"သော့ဖွင့်ရန် ပွတ်ဆွဲပါ"</string>
     <string name="keyboard_headset_required_to_hear_password" msgid="7011927352267668657">"စကားဝှက်ပြောဆိုမှုကို ကြားနိုင်ရန် မိုက်ခွက်ပါနားကြပ် တပ်ပြီး နားထောင်ပါ"</string>
     <string name="keyboard_password_character_no_headset" msgid="2859873770886153678">"ဒေါ့"</string>
@@ -1529,23 +1526,23 @@
     <string name="action_menu_overflow_description" msgid="2295659037509008453">"ပိုမိုရွေးချယ်စရာများ"</string>
     <string name="action_bar_home_description_format" msgid="7965984360903693903">"%1$s ၊ %2$s"</string>
     <string name="action_bar_home_subtitle_description_format" msgid="6985546530471780727">"%1$s ၊ %2$s ၊ %3$s"</string>
-    <string name="storage_internal" msgid="4891916833657929263">"စက်အတွင်းသိမ်းဆည်းရန်နေရာ"</string>
+    <string name="storage_internal" msgid="4891916833657929263">"စက်တွင်း သိုလှောင်ထားမှု"</string>
     <string name="storage_sd_card" msgid="3282948861378286745">"SD ကဒ်"</string>
-    <string name="storage_usb" msgid="3017954059538517278">"USBဖြင့် သိမ်းဆည်း"</string>
+    <string name="storage_usb" msgid="3017954059538517278">"USBဖြင့် သိမ်းဆည်း"</string>
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ပြင်ဆင်ရန်"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ဒေတာအသုံးပြုမှုသတိပေးချက်"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"ဆက်တင်နှင့်သုံးစွဲမှုကြည့်ရန်ထိပါ"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G ဒေတာ ပိတ်ထား"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G ဒေတာ ပိတ်ထား"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"ဆယ်လူလာ ဒေတာ ပိတ်ထား"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"ကြိုးမဲ့ ဒေတာ ပိတ်ထား"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ကန့်သတ်ချက် ပြည့်မီသွားပြီ"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G ဒေတာ ကန့်သတ်ချက် ပြည့်မီသွားပြီ"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G ဒေတာ ကန့်သတ်ချက် ပြည့်မီသွားပြီ"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"ဆယ်လူလာ ဒေတာ ကန့်သတ်ချက် ပြည့်မီသွားပြီ"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"ကြိုးမဲ့ ဒေတာ ကန့်သတ်ချက် ပြည့်မီသွားပြီ"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"ကျန် စက်ဝန်း အတွက် ဒေတာကို ဆိုင်းငံ့ထား"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"သတ်မှတ်ထားသော2G-3Gဒေတာအားကျော်လွန်နေသည်"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"သတ်မှတ်ထားသော4Gဒေတာအားကျော်လွန်နေသည်"</string>
-    <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"ဆယ်လူလာ ကန့်သတ်ချက် ကျော်လွန်သွားပြီ"</string>
+    <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"ဆယ်လူလာ ကန့်သတ်ချက် ကျော်လွန်သွားပြီ"</string>
     <string name="data_usage_wifi_limit_snoozed_title" msgid="8743856006384825974">"သတ်မှတ်ဝိုင်ဖိုင်ဒေတာထက်ကျော်နေ"</string>
     <string name="data_usage_limit_snoozed_body" msgid="7035490278298441767">"သက်မှတ်နှုန်းထက် <xliff:g id="SIZE">%s</xliff:g> ကျော်နေပါသည်"</string>
-    <string name="data_usage_restricted_title" msgid="5965157361036321914">"နောက်ခံဒေတာ ကန့်သတ်ထားသည်"</string>
+    <string name="data_usage_restricted_title" msgid="5965157361036321914">"နောက်ခံဒေတာ ကန့်သတ်ထားသည်"</string>
     <string name="data_usage_restricted_body" msgid="6741521330997452990">"ကန့်သတ်ထားမှု ဖျက်ရန် ထိလိုက်ပါ"</string>
     <string name="ssl_certificate" msgid="6510040486049237639">"လုံခြံုမှုဆိုင်ရာ အသိအမှတ်ပြုလက်မှတ်"</string>
     <string name="ssl_certificate_is_valid" msgid="6825263250774569373">"ဤအသိအမှတ်ပြုလက်မှတ်မှာ တရားဝင်သည်"</string>
@@ -1563,14 +1560,14 @@
     <string name="sha1_fingerprint" msgid="7930330235269404581">"SHA-1 လက်ပွေ"</string>
     <string name="activity_chooser_view_see_all" msgid="4292569383976636200">"အားလုံးကို ကြည့်ရန်"</string>
     <string name="activity_chooser_view_dialog_title_default" msgid="4710013864974040615">"လှုပ်ရှားမှုကို ရွေးရန်"</string>
-    <string name="share_action_provider_share_with" msgid="5247684435979149216">"...နှင့် မျှဝေရန်"</string>
+    <string name="share_action_provider_share_with" msgid="5247684435979149216">"...နှင့် မျှဝေရန်"</string>
     <string name="list_delimeter" msgid="3975117572185494152">", "</string>
     <string name="sending" msgid="3245653681008218030">"ပေးပို့နေစဉ်…"</string>
     <string name="launchBrowserDefault" msgid="2057951947297614725">"ဘရောက်ဇာ ဖွင့်မည်လား။"</string>
     <string name="SetupCallDefault" msgid="5834948469253758575">"ဖုန်းခေါ်ဆိုမှုကို လက်ခံမလား?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"အမြဲတမ်း"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"တစ်ခါတည်း"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s က အလုပ် ပရိုဖိုင်ကို မပံ့ပိုးပါ။"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s က အလုပ်ပရိုဖိုင်ကို မပံ့ပိုးပါ။"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"တက်ဘလက်"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ဖုန်း"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"နားကြပ်"</string>
@@ -1638,14 +1635,15 @@
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"သင် ပုံဖော်၍သော့ဖွင့်ခြင်းကို <xliff:g id="NUMBER_0">%d</xliff:g> အကြိမ် မှန်ကန်စွာ မပြုလုပ်နိုင်ပါ။ နောက်ထပ် <xliff:g id="NUMBER_1">%d</xliff:g> အကြိမ် မမှန်ကန်ပါက သင့်ဖုန်းအား အီးမေးလ်အသုံးပြု၍ သော့ဖွင့်ရန် တောင်းဆိုပါလိမ့်မည်။ \n\n <xliff:g id="NUMBER_2">%d</xliff:g> စက္ကန့်အကြာတွင် ပြန်လည် ကြိုးစားပါ"</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
     <string name="kg_reordering_delete_drop_target_text" msgid="7899202978204438708">"ဖယ်ရှားရန်"</string>
-    <string name="safe_media_volume_warning" product="default" msgid="2276318909314492312">"အသံကို အကြံပြုထားသည့် ပမာဏထက် မြှင့်ပေးရမလား?\n\nအသံကို မြင့်သည့် အဆင့်မှာ ကြာရှည်စွာ နားထောင်ခြင်းက သင်၏ နားကို ထိခိုက်စေနိုင်သည်။"</string>
+    <string name="safe_media_volume_warning" product="default" msgid="2276318909314492312">"အသံကို အကြံပြုထားသည့် ပမာဏထက် မြှင့်ပေးရမလား?\n\nအသံကို မြင့်သည့် အဆင့်မှာ ကြာရှည်စွာ နားထောင်ခြင်းက သင်၏ နားကို ထိခိုက်စေနိုင်သည်။"</string>
     <string name="continue_to_enable_accessibility" msgid="1626427372316070258">"လက်နှစ်ချောင်းကို ထိကိုင်ထားခြင်းဖြင့် သုံးစွဲနိုင်မှုကို ခွင့်ပြုပါ"</string>
     <string name="accessibility_enabled" msgid="1381972048564547685">"သုံးစွဲခွင့် ကို ဖွင့်ထားသည်"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"အသုံးပြုခွင့် ဖျက်လိုက်သည်"</string>
     <string name="user_switched" msgid="3768006783166984410">"လက်ရှိအသုံးပြုနေသူ <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>သို့ ပြောင်းနေ…"</string>
     <string name="owner_name" msgid="2716755460376028154">"ပိုင်ရှင်"</string>
     <string name="error_message_title" msgid="4510373083082500195">"အမှား"</string>
-    <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ဒီအပြောင်းအလဲမျိုးကို သင့် စီမံအုပ်ချုပ်သူမှ ခွင့်မပြုပါ"</string>
+    <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ဒီအပြောင်းအလဲမျိုးကို သင့် စီမံအုပ်ချုပ်သူမှ ခွင့်မပြုပါ"</string>
     <string name="app_not_found" msgid="3429141853498927379">"ဤလုပ်ဆောင်ချက်ကို ပြုလုပ်ပေးမည့် အပလီကေးရှင်း မရှိပါ။"</string>
     <string name="revoke" msgid="5404479185228271586">"ပယ်ဖျက်ရန်"</string>
     <string name="mediasize_iso_a0" msgid="1994474252931294172">"အိုက်အက်စ်အို အေ ဝ"</string>
@@ -1764,31 +1762,26 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ခုရွေးချယ်ထားပြီး"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> ကို ဖျက်ပြီးပါပြီ"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"အလုပ် <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ဒီမျက်နှာပြင် ပင်ထိုးထားမှုကို ဖြုတ်ရန် နောက် နှင့် မကြာမီတုန်းက ခလုတ်များကို တစ်ချိန်တည်း ထိလျက် ကိုင်ထားပါ။"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ဒီမျက်နှာပြင် ပင်ထိုးထားမှုကို ဖြုတ်ရန် နောက် နှင့် မကြာမီတုန်းက ခလုတ်များကို ထိလျက် ကိုင်ထားပါ။."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"မျက်နှာပြင်ကို ပင်ထိုးထားသည်။ ပင်ထိုးထားမှု ဖြုတ်ခြင်းကို သင့် အဖွဲ့အစည်းက ခွင့် မပြုပါ။"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"မျက်နှာပြင် ပင်ထိုးမှုကို သုံးမလား?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"မျက်နှာပြင်ကို ပင်ထိုးလိုက်ခြင်းက ပြကွက်ကို တစ်ခုတည်းသော မြင်းကွင်းသို့ သော့ပိတ်ထားမည်။ \n\nထွက်လိုက်ရန်၊ နောက် နှင့် မကြာမီတုန်းက ခလုတ်များကို တစ်ချိန်တည်း ထိလျက် ကိုင်ထားပါ။"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"မျက်နှာပြင်ကို ပင်ထိုးလိုက်ခြင်းက ပြကွက်ကို တစ်ခုတည်းသော မြင်းကွင်းသို့ သော့ပိတ်ထားမည်။ \n\nထွက်လိုက်ရန်၊ နောက် နှင့် မကြာမီတုန်းက ခလုတ်များကို ထိလျက် ကိုင်ထားပါ။"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"မလို၊ ကျေးဇူးပါပဲ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"စတင်ရန်"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"သော့ဖွင့် ပုံစံဒီဇိုင်း"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"စကားဝှက်"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"မျက်နှာပြင်ကို ပင်ထိုးထား"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"မျက်နှာပြင် ပင်ထိုးမှု ဖြတ်လိုက်ပြီ"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ပင်မဖြုတ်မီမှာ PIN ကို မေးကြည့်ရန်"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ပင်မဖြုတ်မီမှာ သော့ဖွင့် ရေးဆွဲမှုပုံစံကို မေးကြည့်ရန်"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ပင်မဖြုတ်မီမှာ စကားဝှက်ကို မေးကြည့်ရန်"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ဘက်ထရီသက်တမ်း ကြာရှည်ခံရန်အတွက်၊ ဘက်ထရီချွေတာရေးအပိုင်းမှ သင့် စက်ပစ္စည်း၏ဆောင်ရွက်ချက်များကို လျော့ချပေးပြီး တုန်ခါမှုနှင့် နောက်ခံအချက်အလက်အများစုကို ကန့်သတ်ပေးသည်။ အီးမေး၊ စာပို့ခြင်း နှင့် တခြားapp များကို သင်ဖွင့်မထားပါက အချိန်နှင့်တပြေးညီ ညှိမပေးပါ။ \n\n စက်ပစ္စည်း အားသွင်းနေစဉ် ဘက်ထရီချွေတာရေးအပိုင်းသည် အလိုအလျောက်ပင် အလုပ်မလုပ်ပါ။"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"သင်၏ စက်ရပ်ချိန် <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> မှာ ပြီးဆုံးသည့် အထိ။"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"တစ်မိနစ် အတွင်း"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d မိနစ် အတွင်း"</item>
+  </plurals>
+    <!-- String.format failed for translation -->
+    <!-- no translation found for zen_mode_duration_hours:other (5408537517529822157) -->
+    <string name="zen_mode_forever" msgid="4316804956488785559">"အကန့်အသတ်မရှိစွာ"</string>
 </resources>
diff --git a/core/res/res/values-nb/strings.xml b/core/res/res/values-nb/strings.xml
index 0073ad1..bc1eb6e 100644
--- a/core/res/res/values-nb/strings.xml
+++ b/core/res/res/values-nb/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Lar innehaveren binde seg til det øverste grensesnittnivået for ekstern skjerm. Skal aldri være nødvendig for vanlige apper."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"binde til modultjenste"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Lar innehaveren binde seg til det øverste nivået av grensesnittet for en modultjeneste. Skal aldri være nødvendig for vanlige apper."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"binde seg til en ruteleverandørtjeneste"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Innehaveren av tillatelsen kan binde seg til ruteleverandører. Dette er ikke nødvendig for vanlige apper."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"kommunisere med enhetsadministrator"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Lar innehaveren sende hensikter til en enhetsadministrator. Skal aldri være nødvendig for normale apper."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"binde appen til en TV-inngang"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"slå telefonen av eller på"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Lar appen slå på eller av nettbrettet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Lar appen slå på eller av telefonen."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"tilbakestille tidsavbruddet for skjermen"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Tillater at appen tilbakestiller tidsavbruddet for skjermen."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"kjøre i fabrikktestmodus"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Kjør en produsenttest på lavt nivå, noe som gir fullstendig tilgang til nettbrettets maskinvare. Kun tilgjengelig når nettbrettet kjøres i produsenttestmodus."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Kjøre som en lavnivås produsenttest, med full tilgang til telefonens maskinvare. Kun tilgjengelig når telefonen kjører i produsenttestmodus."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Lar appen lese og skrive til det bufrede filsystemet."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"foreta/motta SIP-anrop"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Tillater at appen utfører og mottar SIP-anrop."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"samhandle med skjermen for innkommende anrop"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Lar appen styre når og hvordan brukeren ser skjermbildet for innkommende anrop."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"samhandle med skjermen for innkommende anrop"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Lar appen styre når og hvordan brukeren ser skjermen for innkommende anrop."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"samhandle med telefonitjenester"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Gjør at appen kan samhandle med telefonitjenester for å foreta/motta anrop."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"levere en brukeropplevelse for innkommende anrop"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Lar appen levere en brukeropplevelse for innkommende anrop."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"lese tidligere nettverksbruk"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Lar appen lese tidligere nettverksbruk for bestemte nettverk og apper."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"administrer retningslinjene for nettverk"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Lar innehaveren binde seg til det øverste grensesnittnivået for en varsellyttertjeneste. Skal aldri være nødvendig for vanlige apper."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"binde seg til en leverandørtjeneste for betingelser"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Gir innehaveren tillatelse til å binde til toppnivået av brukergrensesnittet for en leverandørtjeneste for betingelser. Dette skal ikke være nødvendig for vanlige apper."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"binde seg til en mediarutingstjeneste"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Gir innehaveren tillatelse til å binde til øverste nivå av grensesnittet for en tjeneste som bruker mediaruting. Dette skal ikke være nødvendig for vanlige apper."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"binde til en drømmetjeneste"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Tillater eieren å binde seg til det øverste nivået av grensesnittet til en drømmetjeneste. Kreves aldri for vanlige apper."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"starte konfigurasjonsappen som ble levert av operatøren"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Del med %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Velg en startside-app"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Bruk som standardvalg."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Bruk en annen app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Fjern app angitt som standard i systeminnstillingene &gt; Apper &gt; Nedlastet."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Velg en handling"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Velg en app for USB-enheten"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Tillat"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Sperr"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ønsker å sende en melding til &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Dette "<font fgcolor="#ffffb060">"kan føre til belastninger"</font>" på mobilkontoen din."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Dette kommer til å føre til belastninger på mobilkontoen din."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Dette "<b>"kan føre til kostnader"</b>" på mobilabonnementet ditt."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Dette kommer til å føre til kostnader på mobilabonnementet ditt."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Send"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Avbryt"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Husk valget mitt"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Trykk for å deaktivere USB-feilsøking."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Endre tastatur"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Velg tastatur"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fysisk tastatur"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Vis inndatametode"</string>
     <string name="hardware" msgid="7517821086888990278">"Maskinvare"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Velg tastaturoppsett"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Trykk for å velge et tastaturoppsett"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Gir appen tillatelse til å knyttes til en pålitelig agent-tjeneste."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Samhandling med oppdateringer og gjenopprettingssystem"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Tillater en app å samhandle med gjenopprettingsssystemet og systemoppdateringer."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"opprette økter for mediaprojisering"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Tillater at en app oppretter økter for mediaprojisering. Disse øktene kan la appene ta opp skjerm- og lydinnhold. Skal aldri være nødvendig for normale apper."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Behandle medieprojeksjonsøkter"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Lar appen behandle medieprojeksjonsøkter. Disse øktene kan gi apper evnen til å registrere bilde- og lydinnhold. Bør aldri være nødvendig for vanlige apper."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"lese installeringsøkter"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Tillater en app å lese installeringsøkter. Dette gjør det mulig for den å se detaljer om aktive pakkeinstallasjoner."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Trykk to ganger for zoomkontroll"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Avslå"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Tillatelse forespurt"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Tillatelse forespurt\nfor kontoen <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Du bruker denne appen i det personlige området ditt"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Du bruker denne appen i arbeidsområdet ditt"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Du bruker denne appen utenfor arbeidsprofilen"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Du bruker denne appen i jobbprofilen din"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Inndatametode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synkronisering"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Tilgjengelighet"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Reduser timer"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Angi p.m."</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Angi a.m."</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Øk måneder"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Reduser måneder"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Øk dager"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Rediger"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Advarsel for høyt dataforbruk"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Trykk for å se bruk og innst."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G- og 3G-data er slått av"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-datatrafikk er slått av"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobildatatrafikk er slått av"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-datatrafikk er slått av"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Grensen er nådd"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Datagrensen for 2G-3G er nådd"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Datagrensen for 4G er nådd"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Grensen for mobildata er nådd"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Datagrensen for Wi-Fi er nådd"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data er på pause resten av sykl."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Grense på 2G-3G data overskredet"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Grensen på 4G data er overskredet"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobildatagrensen er overskredet"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vil du besvare anropet?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Alltid"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Bare én gang"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s støtter ikke jobbprofiler."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s støtter ikke arbeidsprofiler"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Nettbrett"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Hodetelefoner"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Tilgjengelighet er aktivert."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Tilgjengelighetstjenesten ble avbrutt."</string>
     <string name="user_switched" msgid="3768006783166984410">"Gjeldende bruker: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Bytter til <xliff:g id="NAME">%1$s</xliff:g> …"</string>
     <string name="owner_name" msgid="2716755460376028154">"Eier"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Feil"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Denne endringen er ikke tillatt av administratoren"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> er valgt"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> er slettet"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Jobb-<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
-    <string name="lock_to_app_negative" msgid="2259143719362732728">"NEI, TAKK"</string>
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Hvis du vil løsne denne skjermen, trykker og holder du på Tilbake og Sist brukte samtidig."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Hvis du vil løsne denne skjermen, trykker og holder du på Sist brukte."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skjermen er festet. Løsning er ikke tillatt av organisasjonen din."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Vil du bruke skjermfesting?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Skjermfesting låser skjermen til én bestemt side.\n\nHvis du vil avslutte, trykker og holder du på Tilbake og Sist brukte samtidig."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Skjermfesting låser skjermen til én bestemt side.\n\nHvis du vil avslutte, trykker og holder du på Sist brukte."</string>
+    <string name="lock_to_app_negative" msgid="2259143719362732728">"NEI TAKK"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-kode"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"opplåsingsmønster"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"passord"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skjermen er festet"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skjermen er løsnet"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Krev PIN-kode for å løsne apper"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Krev bruk av opplåsningsmønster for å løsne apper"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Krev passord for å løsne apper"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Batterisparing reduserer enhetens ytelse og begrenser vibrering og de fleste bakgrunnsdata for å forbedre batterilevetiden. Det kan hende E-post, Meldinger og andre apper som er avhengige av synkronisering, ikke oppdateres med mindre du åpner dem.\n\nBatterisparing slås automatisk av når enheten lades."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Til hviletiden din ender kl. <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"I ett minutt"</item>
+    <item quantity="other" msgid="6924190729213550991">"I %d minutter"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"I én time"</item>
+    <item quantity="other" msgid="5408537517529822157">"I %d timer"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"På ubestemt tid"</string>
 </resources>
diff --git a/core/res/res/values-ne-rNP/strings.xml b/core/res/res/values-ne-rNP/strings.xml
index eb9c066..2dbcb08 100644
--- a/core/res/res/values-ne-rNP/strings.xml
+++ b/core/res/res/values-ne-rNP/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"ताररहित प्रदर्शनको उच्च स्तरको इन्टरफेसलाई पक्का गर्न सम्पर्क राख्ने अनुमति दिन्छ। साधारण अनुप्रयोगहरूलाई कहिल्यै आवश्यक पर्दैन।"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"एउटा विजेट सेवासँग संगठित हुनुहोस्"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"एउटा विजेट सेवाको उच्च स्तरको इन्टरफेसलाई पक्का गर्नको लागि समाती राख्नेलाई अनुमति दिन्छ। साधारण अनुप्रयोगहरूलाई कहिल्यै आवश्यक पर्ने छैन।"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"मार्ग प्रदाय सेवा बाँध्छ"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"होल्डरलाई कुनै पनि दर्ता मार्ग प्रदायहरूमा बाँध्न अनुमति दिन्छ। साधारण अनुप्रयोगहरूको लागि कहिल्यै पनि आवश्यक पर्दैन।"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"उपकरणको प्रबन्धसँग अन्तरक्रिया गर्नुहोस्"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"उपकरण प्रशासक लाई आशय पठाउन समाती राख्‍नेलाई अनुमति दिन्छ। साधारण अनुप्रयोहरूको लागि कहिल्यै पनी आवश्यक पर्दैन।"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"टिभि निवेशलाई आबद्ध"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"फोन खोल्न वा बन्द गर्न उर्जा प्रदान गर्नुहोस"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ट्याब्लेटलाई खोल्न र बन्द गर्न अनुप्रयोगलाई अनुमति दिन्छ।"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"अनुप्रयोगलाई फोन खोल्न र बन्द गर्न अनुमति दिन्छ।"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"प्रदर्शन समाप्ति पुनःसेट गर्नुहोस्"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"प्रदर्शन समाप्ति समायोजन सबै नष्ट गर्न अनुमति दिन्छ।"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"फ्याक्ट्रि परीक्षण मोडमा चालु गर्नुहोस्"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ट्याब्लेट हार्डवेयरलाई पुरा पहुँच गर्न दिँदै तल्लो स्तर उत्त्पादक परीक्षणको रूपमा चलाउनुहोस्। ट्याब्लेट उत्त्पादक परीक्षण मोडमा चलिरहेको बेला मात्र उपलब्ध हुन्छ।"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"तल्लो स्तर उत्त्पादक जस्तै चलाउनुहोस्, पुरा पहुँच दिन फोन हार्डवेयरलाई अनुमति हुन्छ। फोन उत्पादक परीक्षण मोडमा चलिरहेको बेला मात्र उपलब्ध हुन्छ।"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"केस फाइल प्रणालीलाई पढ्न र लेख्‍नको लागि अनुप्रयोगलाई अनुमति दिन्छ।"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP कलहरू प्राप्त/बनाउन"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP कलहरू बनाउन र प्राप्त गर्न अनुप्रयोगलाई अनुमति दिन्छ।"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"आगमन कल स्क्रिनसँग अन्तर्क्रिया गर्नुहोस्"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"कहिले र कसरी प्रयोगकर्ताले आगमन कल स्क्रीन हेर्न सक्दछ भनेर नियन्त्रण गर्न अनुप्रयोगलाई अनुमति दिनुहोस्।"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"आगमन कल स्क्रिन संग अन्तर्क्रिया गर्नुहोस्"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"कहिले र कसरी प्रयोगकर्ताले आगमन कल स्क्रीन हेर्न सक्दछ भनेर नियन्त्रण गर्न अनुप्रयोगलाई अनुमति दिनुहोस्।"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"टेलिफोनी सेवा अन्तरक्रिया"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"अनुप्रयोगलाई कल बनाउन/प्राप्त गर्न टेलीफोनी सेवा साथ अन्तरक्रिया गर्न अनुमति दिन्छ।"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"आउने-कल प्रयोगकर्ता अनुभव प्रदान गर्नुहोस्"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"अनुप्रयोगलाई आउने-कल प्रयोगकर्ता अनुभव प्रदान गर्न अनुमति दिन्छ।"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"नेटवर्क उपयोगको इतिहास पढ्नुहोस्"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"निश्चित नेटवर्कहरू र अनुप्रयोगहरूको लागि ऐतिहासिक नेटवर्क उपयोग पढ्नको लागि अनुप्रयोगलाई अनुमति दिन्छ।"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"नेटवर्क नीति प्रबन्ध गर्नुहोस्"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"होल्डरलाई सूचना श्रोता सेवाको शीर्ष-स्तरको इन्टरफेस बाँध्न अनुमति दिन्छ। सामान्य अनुप्रयोगहरूलाई कहिले पनि आवश्यक नपर्न सक्दछ।"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"सर्त प्रदायक सेवामा जोड्न"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"सर्त प्रदायक सेवाको माथिल्लो स्तरको इन्टरफेसमा जोड्न बाहकलाई अनुमति दिन्छ। साधारण अनुप्रयोगहरूको लागि कहिल्यै पनि आवश्यक पर्दैन।"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"मिडिया मार्ग सेवासँग बाँध्नुहोस्"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"होल्डरलाई मिडिया मार्ग सेवाको शीर्ष तह इन्टरफेस बाध्ने गर्न अनुमति दिन्छ। साधारण अनुप्रयोगहरूको लागि कहिल्यै पनि आवश्यक पर्दैन।"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"सपना सेवामा बाँध्नुहोस्"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"होल्डरलाई सपना सेवाको माथिल्लो स्तरको इन्टरफेसमा बाँध्न अनुमति दिन्छ। साधारण अनुप्रयोगहरूको लागि कहिल्यै पनि आवश्यक पर्दैन।"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"वाहक-प्रदान विन्यास अनुप्रयोग सुरु गर्नुहोस्"</string>
@@ -1213,6 +1211,7 @@
     <skip />
     <string name="whichHomeApplication" msgid="4616420172727326782">"मुख्य अनुप्रयोग चयन गर्नुहोस्"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"यस कार्यको लागि पूर्वनिर्धारितबाट प्रयोग गर्नुहोस्।"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"फरक अनुप्रयोग प्रयोग गर्नुहोस्"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"प्रणाली सेटिङहरूमा पूर्वनिर्धारितलाई हटाउनुहोस् &gt; अनुप्रयोगहरू &gt; डाउनलोड।"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"एउटा कार्यको चयन गर्नुहोस्"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB उपकरणको लागि एउटा अनुप्रयोग छान्नुहोस्"</string>
@@ -1304,8 +1303,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"अनुमति दिनुहोस्"</string>
     <string name="sms_control_no" msgid="625438561395534982">"अस्वीकार गर्नुहोस्"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; के तपाईँ सन्देश पठाउन चाहुनु हुन्छ &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"यसले "<font fgcolor="#ffffb060">" शुल्क लगाउन सक्छ"</font>" तपाईँको मोबाइल खातामा।"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"यसले तपाईंको मोबाइल खातामा चार्जहरू उत्पन्न गर्दछ।"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"यसको "<b>" कारणले तपाईँको मोबाइल खातामा शुल्क"</b>" लाग्नेछ।"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"यसको कारणले तपाईँको मोबाइल खातामा शुल्क लाग्नेछ।"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"पठाउनुहोस्"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"रद्द गर्नुहोस्"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"मेरो छनौट याद राख्नुहोस्"</string>
@@ -1360,7 +1359,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB डिबग गर्ने असक्षम पार्न छुनुहोस्।"</string>
     <string name="select_input_method" msgid="8547250819326693584">"कुञ्जीपाटी परिवर्तन गर्नुहोस्"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"कीबोर्ड छान्नुहोस्"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"भौतिक किबोर्ड"</string>
+    <string name="show_ime" msgid="9157568568695230830">"आगत विधि देखाउनुहोस्"</string>
     <string name="hardware" msgid="7517821086888990278">"हार्डवेयर"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"किबोर्ड रूपरेखा चयन गर्नुहोस्"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"किबोर्ड रूपरेखा चयन गर्न टच गर्नुहोस्।"</string>
@@ -1403,16 +1402,16 @@
     <string name="permdesc_control_keyguard" msgid="3043732290518629061">"अनुप्रयोगलाई किगार्ड नियन्त्रण गर्न अनुमति दिन्छ।"</string>
     <string name="permlab_trust_listener" msgid="1765718054003704476">"भरोसा स्थितिमा परिवर्तनको सुन्नुहोस्।"</string>
     <string name="permdesc_trust_listener" msgid="8233895334214716864">"भरोसा स्थितिमा परिवर्तनको लागि सुन्न अनुप्रयोगलाई अनुमति दिन्छ।"</string>
-    <string name="permlab_provide_trust_agent" msgid="5465587586091358316">"विश्वस्त प्रतिनिधि प्रदान गर्नुहोस्।"</string>
-    <string name="permdesc_provide_trust_agent" msgid="3865702641053068148">"अनुप्रयोगलाई विश्वस्त प्रतिनिधि प्रदान गर्न अनुमति दिन्छ।"</string>
-    <string name="permlab_launch_trust_agent_settings" msgid="5859430082240410200">"विश्वस्त प्रतिनिधि सेटिङ्हरूका मेनु सुरुवात गर्नुहोस्।"</string>
-    <string name="permdesc_launch_trust_agent_settings" msgid="8185142708644913381">"उपकरणलाई विश्वस्त प्रतिनिधिको ब्यवहार परिवर्तन गर्ने गतिविधि सुरुवात गर्न अनुमति दिन्छ।"</string>
-    <string name="permlab_bind_trust_agent_service" msgid="8242093169457695334">"विश्वस्त प्रतिनिधि सेवासँग जोडिएको"</string>
-    <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"विश्वस्त प्रतिनिधि सेवालाई बाँध्न अनुप्रयोगलाई अनुमति दिन्छ।"</string>
+    <string name="permlab_provide_trust_agent" msgid="5465587586091358316">"विश्वस्त एजेन्ट उपलब्ध गराउने।"</string>
+    <string name="permdesc_provide_trust_agent" msgid="3865702641053068148">"अनुप्रयोगलाई एक विश्वस्त एजेन्ट उपलब्ध गराउन अनुमति दिन्छ।"</string>
+    <string name="permlab_launch_trust_agent_settings" msgid="5859430082240410200">"विश्वस्त एजेन्ट सेटिङ मेनु सुरूवात गर्ने।"</string>
+    <string name="permdesc_launch_trust_agent_settings" msgid="8185142708644913381">"अनुप्रयोगलाई विश्वस्त एजेन्ट ब्यवहार परिवर्तन गर्ने गतिविधि सुरूवात गर्न अनुमति दिन्छ।"</string>
+    <string name="permlab_bind_trust_agent_service" msgid="8242093169457695334">"विश्वस्त एजेन्ट सेवासँग सम्बद्ध हुनु"</string>
+    <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"विश्वस्त एजेन्ट सेवासँग सम्बद्ध हुन एक अनुप्रयोगलाई अनुमति दिन्छ।"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"अद्यावधिक र रिकभरी प्रणालीको साथ अन्तर्क्रिया"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"अनुप्रयोगलाई रिकभरी प्रणाली र प्रणाली अद्यावधिकहरूको साथ अन्तर्क्रिया गर्न अनुमति दिन्छ।"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"मिडिया प्रक्षेपण सत्रहरू सिर्जना गर्नुहोस्"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"मिडिया प्रक्षेपण सत्र सिर्जना गर्न अनुप्रयोगलाई अनुमति दिन्छ। यी सत्रले प्रदर्शन र अडियो सामग्री खिच्ने क्षमताका अनुप्रयोगहरू प्रदान गर्न सक्छन्। सामान्य अनुप्रयोगहरूको कहिल्यै पनि आवश्यक पर्दैन।"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"मिडिया प्रक्षेपण सत्र व्यवस्थापन गर्नुहोस्"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"मिडिया प्रक्षेपण सत्र व्यवस्थापन गर्न अनुप्रयोगलाई अनुमति दिन्छ। यी सत्रहरूले प्रदर्शन र अडियो सामग्री खिच्ने क्षमताका अनुप्रयोगहरू प्रदान गर्न सक्छन्। सामान्य अनुप्रयोगहरूको कहिल्यै पनि आवश्यक पर्दैन।"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"स्थापना सत्रहरू पढ्नुहोस्"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"स्थापित सत्र पढ्न अनुप्रयोगलाई अनुमति दिनुहोस्। यसले सक्रिय प्याकेज प्रतिष्ठानहरू बारेमा विवरण हेर्ने अनुमति दिन्छ।"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"जुम नियन्त्रणको लागि दुई चोटि टच गर्नुहोस्"</string>
@@ -1433,8 +1432,8 @@
     <string name="deny" msgid="2081879885755434506">"अस्वीकार गर्नुहोस्"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"अनुरोध गरिएको अनुमति"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">\n"खाता <xliff:g id="ACCOUNT">%s</xliff:g>को लागि अनुरोध गरिएको अनुमति।"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"तपाईँ आफ्नो व्यक्तिगत ठाउँमा यो अनुप्रयोग प्रयोग गरिरहनु भएको छ"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"तपाईँ आफ्नो कार्य ठाउँमा यो अनुप्रयोग प्रयोग गरिरहनु भएको छ"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"तपाईं तपाईँको कार्य प्रोफाइल बाहिर यो अनुप्रयोग प्रयोग गरिरहनु भएको छ"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"तपाईँ आफ्नो कार्य प्रोफाइलमा यो अनुप्रयोग प्रयोग गरिरहनु भएको छ"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"इनपुट विधि"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"सिङ्क गर्नुहोस्"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"उपलब्धता"</string>
@@ -1509,8 +1508,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"घन्टा घटाउनुहोस्"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM सेट गर्नुहोस्"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM सेट गर्नुहोस्"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"अपरान्ह"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"बिहान"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"महिना बढाउनुहोस्"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"महिना घटाउनुहो्स्"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"दिन बढाउनुहोस्"</string>
@@ -1543,11 +1540,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"सम्पादन गर्नुहोस्"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"डेटा प्रयोग चेतावनी"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"उपयोग र सेटिङहरू हेर्न छुनुहोस्।"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G डेटा बन्द छ"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G डेटा बन्द छ"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"सेलुलर डेटा बन्द छ"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"वाइफाइ डेटा बन्द छ"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"सीमा पुग्यो"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G डेटा सीमा पुग्यो"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G डेटा सीमा पुग्यो"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"सेलुलर डेटा सीमा पुग्यो"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"वाइफाइ डेटा सीमा पुग्यो"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"तथ्याङ्क बाँकी चक्रको लागि रोकिएको छ"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G डेटा सीमा भन्दा पार भएको छ"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G डेटा SIMा नाघ्यो"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"सेलुलर डेटा सीमा नाघ्यो"</string>
@@ -1578,9 +1575,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"कल स्वीकार गर्नुहुन्छ?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"सधैँ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"एउटा मात्र"</string>
-    <!-- String.format failed for translation -->
-    <!-- no translation found for activity_resolver_work_profiles_support (5462991471861024343) -->
-    <skip />
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%%१$ को कार्य प्रोफाइल समर्थन गर्दैन"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ट्याब्लेट"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"फोन"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"हेडफोनहरू"</string>
@@ -1653,6 +1648,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"पहुँच सक्षम गरिएको।"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"पहुँचयोग्यता रद्द गरियो।"</string>
     <string name="user_switched" msgid="3768006783166984410">"अहिलेको प्रयोगकर्ता <xliff:g id="NAME">%1$s</xliff:g>।"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> मा स्विच गर्दै..."</string>
     <string name="owner_name" msgid="2716755460376028154">"मालिक"</string>
     <string name="error_message_title" msgid="4510373083082500195">"त्रुटि"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"यो परिवर्तन गर्न तपाईँको प्रशासक द्वारा अनुमति छैन"</string>
@@ -1774,31 +1770,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> चयन गरियो"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> हटाइयो"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"कार्य <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"स्क्रिन अनपिन गर्न, उही समयमा भर्खरहरू टच गरेर फेरि होल्ड गर्नुहोस्।"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"यो स्क्रिन अनपिन गर्न, भर्खरहरू टच गर्नुहोस् र होल्ड गर्नुहोस्।"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"स्क्रिन अनपिन हुँदैछ। अनपिन गर्ने तपाईँको संगठन द्वारा समर्थित छैन।"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"स्क्रिन पिन गर्ने प्रयोग गर्नुहुन्छ?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"स्क्रिन पिनिङले एकल दृश्यमा डिस्प्ले लक गर्छ।\n\n बाहिर निस्कन, भर्खरहरू छुनुहोस् होल्ड गर्नुहोस् उही समयमा।"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"स्क्रिन पिनिङले एकल दृश्यमा डिस्प्ले लक गर्छ।\n\n बाहिर निस्कन, भर्खरहरू छुनुहोस् होल्ड गर्नुहोस्"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"होइन, धन्यवाद"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"शैली बन्द गर्नुहोस"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"पासवर्ड"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"स्क्रिन पिन गरियो"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"स्क्रिन अनपिन गरियो"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"पिन निकाल्नुअघि PIN सोध्नुहोस्"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"पिन निकाल्नुअघि खोल्ने रूपरेखा सोध्नुहोस्"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"पिन निकाल्नुअघि पासवर्ड सोध्नुहोस्"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"ब्याट्री जीवन सुधार्न, ब्याट्री बचतले आफ्नो उपकरणको प्रदर्शन र कम्पनको सीमा र सबैभन्दा पृष्ठभूमि डेटा कम गर्छ। इमेल, सन्देश, र अन्य अनुप्रयोगहरू जसले तपाईं तिनीहरूलाई नखोले सम्म समिकरण अद्यावधिक नगर्न सक्छ भनि भर पर्छ।\n\nब्याट्री बचतले तपाईँको उपकरण चार्ज हुँदै बेला तपाईँको उपकरण स्वचालित बन्द गर्छ।"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"तपाईँको <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> डाउनटाइम समाप्त हुँदा सम्म"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"एक मिनेटको लागि"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d मिनेटको लागि"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"एक घण्टाको लागि"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d घण्टाको लागि"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्चित"</string>
 </resources>
diff --git a/core/res/res/values-nl/strings.xml b/core/res/res/values-nl/strings.xml
index 5b0c5f4..8c6171d 100644
--- a/core/res/res/values-nl/strings.xml
+++ b/core/res/res/values-nl/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Hiermee wordt de houder toegestaan verbinding te maken met de hoofdinterface van een extern display. Nooit vereist voor normale apps."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"verbinden met een widgetservice"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Hiermee wordt de houder toegestaan verbinding te maken met de hoofdinterface van een widgetservice. Nooit vereist voor normale apps."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"binden aan de service van een routeprovider"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Hiermee kan de houder binden aan geregistreerde routeproviders. Nooit gebruikt voor normale apps."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interactie met apparaatbeheer"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Hiermee kan de houder intenties verzenden naar een apparaatbeheerder. Nooit vereist voor normale apps."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"binden aan een tv-ingang"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"telefoon in- of uitschakelen"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Hiermee kan de app de tablet in- of uitschakelen."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Hiermee kan de app de telefoon in- of uitschakelen."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"time-out van het scherm opnieuw instellen"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Hiermee kan de app de time-out van het scherm opnieuw instellen."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"uitvoeren in fabriekstestmodus"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Uitvoeren als fabrikanttest op laag niveau, waardoor toegang wordt gegeven tot de hardware van de tablet. Alleen beschikbaar als een tablet zich in de fabrikanttestmodus bevindt."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Uitvoeren als fabrikanttest op laag niveau, waardoor toegang wordt gegeven tot de hardware van de telefoon. Alleen beschikbaar als een telefoon zich in de fabrikanttestmodus bevindt."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Hiermee kan de app het cachebestandssysteem lezen en schrijven."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP-oproepen plaatsen/ontvangen"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Toestaan dat de app SIP-oproepen plaatst en ontvangt."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interactie met scherm in actieve oproep"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Hiermee kan de app bepalen wanneer en hoe de gebruiker het scherm in een actieve oproep te zien krijgt."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interactie met scherm in actieve oproep"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Hiermee kan de app bepalen wanneer en hoe de gebruiker het scherm in een actieve oproep te zien krijgt."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"communicatie met telefonische diensten"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Hiermee kan de app met telefonische diensten communiceren om oproepen te plaatsen/ontvangen."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"een gebruikerservaring bieden tijdens een gesprek"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Hiermee kan de app een gebruikerservaring bieden tijdens een gesprek."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"historisch netwerkgebruik lezen"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Hiermee kan de app historisch netwerkgebruik voor specifieke netwerken en apps lezen."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"netwerkbeleid beheren"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Hiermee kan de houder koppelen aan de hoofdinterface van een listener-service voor meldingen. Nooit vereist voor normale apps."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"binden aan de service van een provider van voorwaarden"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Hiermee kan de houder binden aan de hoofdinterface van de service van een provider van voorwaarden. Nooit vereist voor normale apps."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"binden aan een service voor mediaroutering"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Hiermee kan de houder binden aan de hoofdinterface van een service voor mediaroutering. Nooit vereist voor normale apps."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"verbinding maken met een droomservice"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Hiermee wordt de houder toegestaan verbinding te maken met de hoofdinterface van een droomservice. Nooit vereist voor normale apps."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"de door de provider geleverde configuratie-app aanroepen"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Delen met %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Een startscherm-app selecteren"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Standaard gebruiken voor deze actie."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Een andere app gebruiken"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Standaardinstelling wissen via Systeeminstellingen &gt; Apps &gt; Gedownload."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Een actie selecteren"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Een app voor het USB-apparaat selecteren"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Toestaan"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Weigeren"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; wil graag een bericht verzenden naar &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Dit "<font fgcolor="#ffffb060">"kan leiden tot kosten"</font>" in uw mobiele account."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Dit leidt tot kosten in uw mobiele account."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Hiervoor "<b>"worden mogelijk kosten in rekening gebracht"</b>" op uw mobiele account."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Hiervoor worden kosten in rekening gebracht op uw mobiele account."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Verzenden"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Annuleren"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Mijn keuze onthouden"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Tik om USB-foutopsporing uit te schakelen."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Toetsenbord wijzigen"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Toetsenborden kiezen"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fysiek toetsenbord"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Invoermethode weergeven"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Toetsenbordindeling selecteren"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Tik om een ​​toetsenbordindeling te selecteren."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Toestaan dat een app wordt gebonden aan een trust agent-service."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interactie met update- en herstelsysteem"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Hiermee kan een app interactie hebben met het herstelsysteem en systeemupdates."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Mediaprojectiesessies maken"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Hiermee kan een app mediaprojectiesessies maken. Met deze sessies kunnen apps scherm- en audio-inhoud vastleggen. Nooit vereist voor normale apps."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Mediaprojectiesessies beheren"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Hiermee kan een app mediaprojectiesessies beheren. Met deze sessies kunnen apps scherm- en audio-inhoud vastleggen. Nooit vereist voor normale apps."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Installatiesessies lezen"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Hiermee wordt een app toegestaan installatiesessies te lezen. Zo kan de app informatie bekijken over actieve pakketinstallaties."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Raak twee keer aan voor zoomregeling"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Weigeren"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Toestemming gevraagd"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Toestemming gevraagd\nvoor account <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"U gebruikt deze app in uw persoonlijke ruimte"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"U gebruikt deze app in uw werkruimte"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"U gebruikt deze app buiten uw werkprofiel"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"U gebruikt deze app in uw werkprofiel"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Invoermethode"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchroniseren"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Toegankelijkheid"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Lagere waarde voor uren"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM instellen"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM instellen"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"pm"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"am"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Hogere waarde voor maand"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Lagere waarde voor maand"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Hogere waarde voor dag"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Bewerken"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Waarschuwing v. gegevensgebruik"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Aanraken: gebruik/inst. bekijken"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G/3G-data zijn uitgeschakeld"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-data zijn uitgeschakeld"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobiele data zijn uitgeschakeld"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wifi-data zijn uitgeschakeld"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limiet bereikt"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Gegevenslimiet van 2G-3G bereikt"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Gegevenslimiet van 4G bereikt"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobiele gegevenslimiet bereikt"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wifi-gegevenslimiet bereikt"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Gegev. onderbr. voor rest cyclus"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Gegevenslimiet 2G-3G overschreden"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Gegevenslimiet 4G overschreden"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobiele datalimiet overschreden"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Oproep accepteren?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Altijd"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Eén keer"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ondersteunt werkprofielen niet."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ondersteunt werkprofielen niet"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefoon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Hoofdtelefoon"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Toegankelijkheid ingeschakeld."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Toegankelijkheid geannuleerd."</string>
     <string name="user_switched" msgid="3768006783166984410">"Huidige gebruiker <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Overschakelen naar <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Eigenaar"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Fout"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Deze wijziging is niet toegestaan door uw beheerder"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> geselecteerd"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> verwijderd"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Werk <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Als u dit scherm wilt losmaken, blijft u \'Terug\' en \'Recente schermen\' tegelijkertijd aanraken."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Als u dit scherm wilt losmaken, blijft u \'Recente schermen\' aanraken."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Scherm is vastgezet. Losmaken is niet toegestaan door uw organisatie."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Scherm vastzetten?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Door het scherm vast te zetten, wordt het display vergrendeld in één weergave.\n\nAls u deze modus wilt verlaten, blijft u \'Terug\' en \'Recente schermen\' tegelijkertijd aanraken."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Door het scherm vast te zetten, wordt het display in één weergave vergrendeld.\n\nAls u deze modus wilt verlaten, bljift u \'Recente schermen\' aanraken."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NEE, BEDANKT"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"pincode"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ontgrendelingspatroon"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"wachtwoord"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Scherm vastgezet"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Scherm losgemaakt"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Vragen om pincode voordat items worden losgemaakt"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Vragen om ontgrendelingspatroon voordat items worden losgemaakt"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Vragen om wachtwoord voordat items worden losgemaakt"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Accubesparing beperkt de prestaties van uw apparaat, de trilfunctie en de meeste achtergrondgegevens om de accuduur te verlengen.\n\nAccubesparing wordt automatisch uitgeschakeld wanneer uw apparaat wordt opgeladen."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Totdat uw downtime eindigt om <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Eén minuut"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d minuten"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Eén uur"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d uur"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Voor onbepaalde tijd"</string>
 </resources>
diff --git a/core/res/res/values-pl/strings.xml b/core/res/res/values-pl/strings.xml
index 65616c2..746eb4f 100644
--- a/core/res/res/values-pl/strings.xml
+++ b/core/res/res/values-pl/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu wyświetlacza zdalnego. Nieprzeznaczone dla zwykłych aplikacji."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"powiązanie z usługą widżetów"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu usługi widżetów. Nie powinno być nigdy potrzebne w przypadku zwykłych aplikacji."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"powiązanie z usługą dostawcy tras"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Umożliwia właścicielowi powiązanie z dowolnymi zarejestrowanymi dostawcami tras. Nie powinno być nigdy potrzebne w normalnych aplikacjach."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interakcja z administratorem urządzenia"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Zezwala na wysyłanie intencji do administratora urządzenia. Nie powinno być nigdy potrzebne w przypadku zwykłych aplikacji."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"powiązanie z wejściem TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"włączanie lub wyłączanie telefonu"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Pozwala aplikacji na włączanie i wyłączanie tabletu."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Pozwala aplikacji na włączanie i wyłączanie telefonu."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"resetowanie czasu oczekiwania wyświetlacza"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Pozwala aplikacji zresetować czas oczekiwania na wygaszenie wyświetlacza."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"uruchamianie w trybie testu fabrycznego"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Możliwość uruchamiania aplikacji jako niskopoziomowego testu producenta, co zapewnia pełny dostęp do elementów sprzętowych tabletu. Dostępna tylko wówczas, gdy tablet działa w trybie testu producenta."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Uruchom jako niskopoziomowy test producenta, pozwalając na całkowity dostęp do elementów sprzętowych telefonu. Dostępne tylko jeśli telefon działa w trybie testu producenta."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Pozwala aplikacji na odczyt i zapis w systemie plików pamięci podręcznej."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"wykonywanie/odbieranie połączeń SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Pozwala aplikacji na wykonywanie i odbieranie połączeń SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakcje z ekranem połączenia"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Zezwala aplikacji na kontrolowanie, kiedy i w jaki sposób użytkownik widzi ekran połączenia."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakcje z ekranem połączenia"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Zezwala aplikacji na kontrolowanie, kiedy i w jaki sposób użytkownik widzi ekran połączenia."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"korzystanie z usług telefonii"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Pozwala aplikacji na korzystanie z usług telefonii oraz wykonywanie i odbieranie połączeń."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"udostępnianie użytkownikowi funkcji połączenia"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Zezwala aplikacji na udostępnianie użytkownikowi funkcji połączenia."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"odczyt historii wykorzystania sieci"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Pozwala aplikacji na odczyt historii wykorzystania określonych sieci przez poszczególne aplikacje."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"zarządzanie zasadami dotyczącymi sieci"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu usługi odbiornika powiadomień. Nie powinno być nigdy potrzebne dla zwykłych aplikacji."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"powiąż z usługą dostawcy warunków"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu usługi dostawcy warunków. Nieprzeznaczone dla zwykłych aplikacji."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"powiązanie z usługą kierowania multimediów"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu usługi kierowania multimediów. Nieprzeznaczone dla zwykłych aplikacji."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"powiąż z usługą wygaszacza ekranu"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Zezwala na tworzenie powiązania z interfejsem najwyższego poziomu usługi wygaszacza ekranu. Nie powinno być nigdy potrzebne dla zwykłych aplikacji."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"wywoływanie aplikacji konfiguracyjnej udostępnionej przez operatora"</string>
@@ -1069,11 +1067,11 @@
   </plurals>
   <plurals name="num_minutes_ago">
     <item quantity="one" msgid="3306787433088810191">"1 minutę temu"</item>
-    <item quantity="other" msgid="2176942008915455116">"<xliff:g id="COUNT">%d</xliff:g> min. temu"</item>
+    <item quantity="other" msgid="2176942008915455116">"<xliff:g id="COUNT">%d</xliff:g> min temu"</item>
   </plurals>
   <plurals name="num_hours_ago">
     <item quantity="one" msgid="9150797944610821849">"godzinę temu"</item>
-    <item quantity="other" msgid="2467273239587587569">"<xliff:g id="COUNT">%d</xliff:g> godzin temu"</item>
+    <item quantity="other" msgid="2467273239587587569">"<xliff:g id="COUNT">%d</xliff:g> godz. temu"</item>
   </plurals>
   <plurals name="last_num_days">
     <item quantity="other" msgid="3069992808164318268">"Ostatnie (<xliff:g id="COUNT">%d</xliff:g>) dni"</item>
@@ -1201,10 +1199,11 @@
     <string name="whichViewApplicationNamed" msgid="2286418824011249620">"Otwórz w aplikacji %1$s"</string>
     <string name="whichEditApplication" msgid="144727838241402655">"Edytuj w aplikacji"</string>
     <string name="whichEditApplicationNamed" msgid="1775815530156447790">"Edytuj w aplikacji %1$s"</string>
-    <string name="whichSendApplication" msgid="6902512414057341668">"Udostępnij w aplikacji"</string>
-    <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Udostępnij w aplikacji %1$s"</string>
+    <string name="whichSendApplication" msgid="6902512414057341668">"Udostępnij przez"</string>
+    <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Udostępnij przez %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Wybierz aplikację ekranu głównego"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Domyślne dla tej czynności"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Użyj innej aplikacji"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Wyczyść wartości domyślne w: Ustawienia systemu &gt; Aplikacje &gt; Pobrane."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Wybierz czynność"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Wybierz aplikację dla urządzenia USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Pozwól"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Odmów"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; chce wysłać wiadomość do &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"To "<font fgcolor="#ffffb060">"może spowodować obciążenie"</font>" Twojego konta komórkowego."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"To spowoduje obciążenie Twojego konta komórkowego."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"To "<b>"może spowodować naliczenie opłat"</b>" przez operatora komórkowego."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Spowoduje to naliczanie opłat przez operatora komórkowego."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Wyślij"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Anuluj"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Zapamiętaj mój wybór"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Dotknij, aby wyłączyć debugowanie USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Zmień klawiaturę"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Wybierz klawiatury"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Klawiatura fizyczna"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Pokaż metodę wprowadzania"</string>
     <string name="hardware" msgid="7517821086888990278">"Sprzęt"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Wybierz układ klawiatury"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Kliknij, by wybrać układ klawiatury."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Zezwala aplikacji na powiązanie z usługą agenta zaufania."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interakcja z systemem odzyskiwania i aktualizacjami"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Zezwala aplikacji na interakcję z systemem odzyskiwania i aktualizacjami systemu."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Twórz sesje wyświetlania multimediów"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Zezwala aplikacji na tworzenie sesji wyświetlania multimediów. Te sesje mogą umożliwić aplikacjom zapisywanie dźwięku i obrazu. Normalne aplikacje nie powinny żądać tego uprawnienia."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Zarządzanie sesjami wyświetlania multimediów"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Zezwala aplikacji na zarządzanie sesjami wyświetlania multimediów. Te sesje mogą umożliwić aplikacjom zapisywanie dźwięku i obrazu. Zwykłe aplikacje nie powinny żądać tego uprawnienia."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Odczyt sesji instalacji"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Pozwala aplikacji odczytywać sesje instalacji. Umożliwia to jej na poznanie szczegółów aktywnych instalacji pakietów."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Dotknij dwukrotnie, aby sterować powiększeniem."</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Odmów"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Prośba o pozwolenie"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Prośba o pozwolenie\ndotyczące konta <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Używasz tej aplikacji w swojej pamięci osobistej"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Używasz tej aplikacji w swojej pamięci do pracy"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Używasz tej aplikacji poza profilem do pracy"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Używasz tej aplikacji w swoim profilu do pracy"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Sposób wprowadzania tekstu"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchronizacja"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Ułatwienia dostępu"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Zmień godzinę na wcześniejszą"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Ustaw PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Ustaw AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Zmień miesiąc na późniejszy"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Zmień miesiąc na wcześniejszy"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Zmień dzień na późniejszy"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Edytuj"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Ostrzeżenie o transmisji danych"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Dotknij – użycie i ustawienia."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Połączenie danych 2G-3G wyłączone"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Połączenie danych 4G wyłączone"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Komórkowe połączenie danych wył."</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Połączenie danych Wi-Fi wyłączone"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Osiągnięto limit"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Osiągnięto limit danych 2G/3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Osiągnięto limit danych 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Osiągnięto limit danych komórkowych"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Osiągnięto limit danych Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dane wstrzymane do końca cyklu"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Przekroczono limit danych 2G/3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Przekroczono limit danych 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Przekroczono limit danych komórk."</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Odebrać połączenie?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Zawsze"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Tylko raz"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s nie obsługuje profilu do pracy"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s nie obsługuje profilu do pracy"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Słuchawki"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Włączono ułatwienia dostępu."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Ułatwienia dostępu zostały anulowane."</string>
     <string name="user_switched" msgid="3768006783166984410">"Bieżący użytkownik: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Przełączam na <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Właściciel"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Błąd"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Ta zmiana nie jest dozwolona przez administratora"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Wybrałeś <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> usunięte"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (praca)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Aby odpiąć ekran, kliknij i przytrzymaj jednocześnie Wróć i Ostatnie."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Aby odpiąć ekran, kliknij i przytrzymaj Ostatnie."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekran jest przypięty. Ustawienia organizacji nie pozwalają go odpiąć."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Przypiąć ekran?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Przypięcie ekranu blokuje na nim jeden widok.\n\nAby zakończyć ten tryb, kliknij i przytrzymaj jednocześnie Wróć i Ostatnie."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Przypięcie ekranu blokuje na nim jeden widok.\n\nAby zakończyć ten tryb, kliknij i przytrzymaj Ostatnie."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NIE, DZIĘKUJĘ"</string>
-    <string name="lock_to_app_positive" msgid="7085139175671313864">"START"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Kod PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"wzór odblokowania"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"hasło"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_positive" msgid="7085139175671313864">"TAK"</string>
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekran przypięty"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekran odpięty"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Aby odpiąć, poproś o PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Aby odpiąć, poproś o wzór odblokowania"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Aby odpiąć, poproś o hasło"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Aby wydłużyć czas pracy baterii, Oszczędzanie baterii ogranicza aktywność urządzenia, w tym wibracje i przetwarzanie większości danych w tle. Poczta, SMS i inne synchronizowane aplikacje mogą nie aktualizować swojej zawartości, dopóki ich nie otworzysz.\n\nOszczędzanie baterii wyłącza się automatycznie podczas ładowania urządzenia."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Do zakończenia przestoju o <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Przez minutę"</item>
+    <item quantity="other" msgid="6924190729213550991">"Przez %d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Przez 1 godz."</item>
+    <item quantity="other" msgid="5408537517529822157">"Przez %d godz."</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Na czas nieokreślony"</string>
 </resources>
diff --git a/core/res/res/values-pt-rPT/strings.xml b/core/res/res/values-pt-rPT/strings.xml
index b54d6c0..1b76f03 100644
--- a/core/res/res/values-pt-rPT/strings.xml
+++ b/core/res/res/values-pt-rPT/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite ao detentor associar a interface de nível superior a um ecrã remoto. Nunca deve ser necessário para aplicações normais."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vincular a um serviço de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite que o titular vincule a interface de nível superior de um serviço de widget. Nunca deverá ser necessário para aplicações normais."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"vincular a serviço de fornecedor de trajeto"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite ao titular vincular a quaisquer fornecedores de trajeto registado. Nunca deverá ser necessário para aplicações normais."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interagir com um administrador do dispositivo"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite ao titular enviar intenções para um administrador do aparelho. Nunca deverá ser necessário para aplicações normais."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"vincular a uma entrada de TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ligar ou desligar o telefone"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite que uma aplicação ligue ou desligue o tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite que a aplicação ligue ou desligue o telemóvel."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"repor tempo limite de visualização"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite que a aplicação reponha o tempo limite de visualização."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"executar em modo de teste de fábrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Executar como um teste de nível inferior do fabricante, permitindo o acesso total ao hardware do tablet. Apenas disponível quando um tablet está em execução em modo de teste do fabricante."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Executar como um teste de nível inferior do fabricante, permitindo o acesso total ao hardware do telefone. Apenas disponível quando um telefone está em execução em modo de teste do fabricante."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite à aplicação ler e escrever no sistema de ficheiros da cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"efetuar/receber chamadas SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite que a aplicação efetue e receba chamadas SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interagir com o ecrã durante uma chamada"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite que a aplicação controle quando e como o utilizador vê o ecrã durante uma chamada."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interagir com o ecrã durante uma chamada"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite que a aplicação controle quando e como o utilizador vê o ecrã durante uma chamada."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"Interagir com serviços telefónicos"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite à aplicação interagir com serviços telefónicos e fazer/receber chamadas."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"proporcionar uma experiência de utilizador em chamada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite que a aplicação proporcione uma experiência de utilizador em chamada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ler utilização histórica da rede"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite que a aplicação leia utilização histórica da rede para redes e aplicações específicas."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gerir a política de rede"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite que o titular vincule a interface de nível superior de um serviço de escuta de notificações. Nunca deverá ser necessário para aplicações normais."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"vincular a um serviço de fornecedor de condição"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite que o titular vincule a interface de nível superior de um serviço de fornecedor de condição. Nunca deverá ser necessário para aplicações normais."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"vincular a um serviço de encaminhamento multimédia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite que o titular vincule a interface de nível superior de um serviço de encaminhamento multimédia. Nunca deverá ser necessário para aplicações normais."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"vincular-se a um serviço de sonho"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite ao detentor ficar vinculado à interface de nível superior de um serviço de sonho. Nunca deverá ser necessário para aplicações normais."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invocar a aplicação de configuração fornecida pela operadora"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Partilhar com %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Selecionar uma aplicação de página inicial"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Utilizar por predefinição para esta acção."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utilizar outra aplicação"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Limpar a predefinição nas Definições do Sistema &gt; Aplicações &gt; Transferidas."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Escolha uma ação"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Escolher uma aplicação para o dispositivo USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permitir"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Recusar"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; gostaria de enviar uma mensagem para &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Isto "<font fgcolor="#ffffb060">"poderá resultar em custos"</font>" para a sua conta de telemóvel."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Isto resultará em custos para a sua conta de telemóvel."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Isto "<b>"pode resultar em custos"</b>" para a sua conta de dispositivo móvel."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Isto resultará em custos para a sua conta de dispositivo móvel."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Enviar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancelar"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Memorizar a minha escolha"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toque para desativar a depuração USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Alterar teclado"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Escolher teclados"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclado físico"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostrar método de entrada"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selecionar esquema de teclado"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toque para selecionar um esquema de teclado."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite que uma aplicação fique vinculada a um serviço de agente fidedigno."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interagir com o sistema de recuperação e de atualização"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite que uma aplicação interaja com o sistema de recuperação e as atualizações do sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Criar sessões de projeção multimédia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite que uma aplicação crie sessões de projeção multimédia. Estas sessões podem proporcionar às aplicações a capacidade de captar conteúdos visuais e de áudio. Nunca deverá ser necessário para aplicações normais."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gerir sessões de projeção de multimédia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite a uma aplicação gerir sessões de projeção de multimédia. Estas sessões podem proporcionar às aplicações a capacidade de captar conteúdos de visualização e de áudio. Não deverá ser necessário para as aplicações normais."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Ler sessões de instalação"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite que uma aplicação leia sessões de instalação. Isto permite que veja detalhes acerca de instalações de pacotes ativas."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toque duas vezes para controlar o zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Recusar"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permissão solicitada"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permissão solicitada\npara a conta <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Está a utilizar esta aplicação no seu espaço pessoal"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Está a utilizar esta aplicação no seu espaço de trabalho"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Está a utilizar esta aplicação fora do seu perfil de trabalho"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Está a utilizar esta aplicação no seu perfil de trabalho"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Método de entrada"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronização"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Acessibilidade"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Diminuir hora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Definir PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Definir AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumentar mês"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Diminuir mês"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumentar o dia"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editar"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Aviso de utilização de dados"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toque para ver a utilização e as definições."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Dados 2G-3G desligados"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Dados 4G desligados"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Dados de rede móvel desligados"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Dados Wi-Fi desligados"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limite atingido"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Limite de dados 2G/3G atingido"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Limite de dados 4G atingido"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Limite de dados móveis atingido"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Limite de dados Wi-Fi atingido"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dados parados no resto do ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Limite de dados 2G-3G excedido"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Limite de dados 4G excedido"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limite dados rede móvel excedido"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Aceitar chamada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Apenas uma vez"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s não suporta o perfil de trabalho."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s não suporta o perfil de trabalho"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telemóvel"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Auscultadores"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Acessibilidade ativada."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Acessibilidade cancelada."</string>
     <string name="user_switched" msgid="3768006783166984410">"<xliff:g id="NAME">%1$s</xliff:g> do utilizador atual."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"A mudar para <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Proprietário"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Erro"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"O administrador não permite esta alteração"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> selecionado"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> eliminado"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> de trabalho"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Para soltar este ecrã, toque sem soltar em Anterior e Recentes ao mesmo tempo."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Para soltar este ecrã, toque sem soltar em Recentes."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"O ecrã está fixo. A sua entidade não o(a) autoriza a soltá-lo."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Pretende utilizar a fixação do ecrã?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"A fixação do ecrã bloqueia o visor numa única vista.\n\nPara sair, toque sem soltar em Anterior e Recentes ao mesmo tempo."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"A fixação do ecrã bloqueia o visor numa única vista.\n\nPara sair, toque sem soltar em Recentes."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NÃO, OBRIGADO"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"INICIAR"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"sequência de desbloqueio"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"palavra-passe"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ecrã fixo"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ecrã solto"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pedir PIN antes de soltar"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pedir sequência de desbloqueio antes de soltar"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pedir palavra-passe antes de soltar"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Para ajudar a melhorar a duração da bateria, a poupança de bateria reduz o desempenho do dispositivo e limita a vibração e a maior parte dos dados de segundo plano. O email, as mensagens e outras aplicações que dependem da sincronização não podem ser atualizados, exceto se os abrir.\n\nA poupança de bateria desliga-se automaticamente quando o dispositivo estiver a carregar."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Até o período de inatividade terminar às <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Durante um minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Durante uma hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
 </resources>
diff --git a/core/res/res/values-pt/strings.xml b/core/res/res/values-pt/strings.xml
index 5c3e589..8313138 100644
--- a/core/res/res/values-pt/strings.xml
+++ b/core/res/res/values-pt/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite que o proprietário use a interface de nível superior de uma tela remota. Não deve ser necessário para aplicativos comuns."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"sujeitar-se a um serviço de widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite que o proprietário utilize a interface de nível superior de um serviço de widget. Nunca deve ser necessário para aplicativos normais."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"usar um serviço provedor de rotas"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite que o proprietário use qualquer provedor de rotas registrado. Não deve ser necessário para aplicativos comuns."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interagir com o administrador de um dispositivo"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite que o proprietário envie tentativas ao administrador de um aparelho. Nunca deve ser necessário para aplicativos normais."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"associar a uma entrada de TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"ligar ou desligar o telefone"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite que o aplicativo ative ou desative o tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite que o aplicativo ative ou desative o telefone."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"tempo limite de exibição"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite que o app redefina o tempo limite de exibição."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"executar no modo de teste de fábrica"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Executa como um teste do fabricante de nível inferior, permitindo o acesso completo ao hardware do tablet. Disponível apenas quando um tablet está em execução no modo de teste do fabricante."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Executa como um teste do fabricante de nível inferior, permitindo o acesso completo ao hardware do telefone. Disponível apenas quando um telefone está em execução no modo de teste do fabricante."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite que o aplicativo leia e grave o sistema de arquivos cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"fazer/receber chamadas SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite que o app faça e receba chamadas SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interagir com chamada na tela"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite que o aplicativo controle quando e como o usuário visualiza a chamada na tela."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interagir com chamada na tela"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite que o app controle quando e como o usuário visualiza a chamada na tela."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"interagir com os serviços de telefonia"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite ao app interagir com os serviços de telefonia para fazer/receber chamadas."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"fornecer uma experiência de usuário em chamada"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite ao app fornecer uma experiência de usuário em chamada."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ler histórico de uso da rede"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite que o aplicativo leia o histórico de uso da rede para redes e aplicativos específicos."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gerenciar a política de rede"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite que o proprietário sujeite a interface de nível superior a um serviço ouvinte de notificações. Não deve ser necessário para aplicativos comuns."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"associar a um serviço provedor de condições"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite que o proprietário use a interface de nível superior de um serviço provedor de condições. Não deve ser necessário para aplicativos comuns."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"usar serviço de roteamento de mídia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite que o proprietário use a interface de nível superior de um serviço de roteamento de mídia. Não deve ser necessário para aplicativos comuns."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"conectar-se a um serviço de sonho"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite que o sistema autorizado se conecte à interface de nível superior de um serviço de sonho. Não deve ser necessário para aplicativos comuns."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"invocar o aplicativo de configuração fornecido pela operadora"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Compartilhar com %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Selecione um aplicativo de tela inicial"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Usar como padrão para esta ação."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Usar um app diferente"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Padrão claro em Configurações do sistema &gt; Aplicativos &gt; Baixado."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Escolher uma ação"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Selecione um aplicativo para o dispositivo USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permitir"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Negar"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; deseja enviar uma mensagem para &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Isto "<font fgcolor="#ffffb060">"poderá gerar cobranças"</font>" em sua conta de celular."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Isto irá gerar cobranças em sua conta de celular."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Isso "<b>"pode resultar em cobranças"</b>" na conta de seu dispositivo móvel."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Isso resultará em cobranças na conta de seu dispositivo móvel."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Enviar"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Cancelar"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Lembrar minha escolha"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Toque para desativar a depuração do USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Alterar teclado"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Escolher teclados"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Teclado físico"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Mostrar método de entrada"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selecione o layout de teclado"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Toque para selecionar um layout de teclado."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite que o aplicativo se associe a um serviço de agente de confiança."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interagir com o sistema de atualizações e recuperação"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite que um aplicativo interaja com o sistema de recuperação e as atualizações do sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Criar sessões de projeção de mídia"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite que um aplicativo crie sessões de projeção de mídia. As sessões podem fornecer aos aplicativos a capacidade de capturar conteúdo de tela e de áudio. Isso nunca deve ser necessário em aplicativos normais."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gerenciar sessões de projeção de mídia"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite que um app gerencie sessões de projeção de mídia. As sessões podem fornecer aos apps a capacidade de capturar conteúdo de tela e de áudio. Isso nunca deve ser necessário em aplicativos normais."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Ler sessões de instalação"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite que um aplicativo leia sessões de instalação. Isso permite que ele veja detalhes sobre as instalações de pacote ativas."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Toque duas vezes para controlar o zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Negar"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permissão solicitada"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permissão solicitada\npara a conta <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Você está usando esse aplicativo em seu espaço pessoal"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Você está usando esse aplicativo em seu espaço de trabalho"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Este app está sendo usado fora de seu perfil de trabalho"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Você está usando este app em seu perfil de trabalho"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Método de entrada"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronizar"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Acessibilidade"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Diminuir hora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Configurar valor PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Configurar valor AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Aumentar mês"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Diminuir mês"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Aumentar dia"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editar"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Aviso sobre uso de dados"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Toque p/ ver uso e config."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Os dados 2G-3G foram desativados"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Os dados 4G foram desativados"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Dados da rede cel. desativados"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Os dados Wi-Fi foram desativados"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limite atingido"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Limite de dados 2G-3G atingido"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Limite de dados 4G atingido"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Limite de dados celular atingido"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Limite de dados Wi-Fi atingido"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dados pausados no resto do ciclo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Limite de dados 2G-3G excedido"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Limite de dados 4G excedido"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Lim. de dados rede cel. excedido"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Aceitar chamada?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Sempre"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Só uma vez"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s não é compatível com o perfil de trabalho."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s não aceita perfis de trabalho"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefone"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Fones de ouvido"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Acessibilidade ativada."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Acessibilidade cancelada."</string>
     <string name="user_switched" msgid="3768006783166984410">"Usuário atual <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Alternando para <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Proprietário"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Erro"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Esta alteração não é permitida pelo administrador"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> selecionado"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> excluído"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Trabalho: <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Para liberar esta tela, mantenha pressionados \"Voltar\" e \"Recentes\"."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Para liberar esta tela, mantenha pressionado \"Recentes\"."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"A tela está fixada. A liberação não é permitida por sua organização."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Usar fixação de tela?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"A fixação de tela bloqueia o visor em uma visualização única.\n\nPara sair, mantenha pressionados \"Voltar\" e \"Recentes\"."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"A fixação de tela bloqueia o visor em uma visualização única.\n\nPara sair, mantenha pressionado \"Recentes\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NÃO, OBRIGADO"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"INICIAR"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"desbloquear padrão"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"senha"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Tela fixada"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Tela liberada"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pedir PIN antes de liberar"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pedir padrão de desbloqueio antes de liberar"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pedir senha antes de liberar"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Para ajudar a melhorar a vida útil da bateria, a economia de bateria reduz o desempenho do dispositivo e restringe a vibração e a maioria dos dados em segundo plano. É possível que apps de e-mail, mensagens, entre outros que dependem de sincronização não sejam atualizados a menos que sejam abertos.\n\nA economia de bateria é desativada automaticamente quando o dispositivo estiver carregando."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Até o período de inatividade terminar às <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Por 1 minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Por %d minutos"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Por 1 hora"</item>
+    <item quantity="other" msgid="5408537517529822157">"Por %d horas"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
 </resources>
diff --git a/core/res/res/values-ro/strings.xml b/core/res/res/values-ro/strings.xml
index 325c0a9..48d4920 100644
--- a/core/res/res/values-ro/strings.xml
+++ b/core/res/res/values-ro/strings.xml
@@ -300,10 +300,8 @@
     <string name="permdesc_receiveBluetoothMap" msgid="8656755936919466345">"Permite aplicației să primească și să proceseze mesaje MAP prin Bluetooth. Aceasta înseamnă că aplicația ar putea monitoriza sau șterge mesajele trimise pe dispozitiv fără a le afișa."</string>
     <string name="permlab_getTasks" msgid="6466095396623933906">"preluare aplicaţii care rulează"</string>
     <string name="permdesc_getTasks" msgid="7454215995847658102">"Permite aplicaţiei să preia informaţiile despre activităţile care rulează în prezent şi care au rulat recent. În acest fel, aplicaţia poate descoperi informaţii despre aplicaţiile care sunt utilizate pe dispozitiv."</string>
-    <!-- no translation found for permlab_startTasksFromRecents (8990073877885690623) -->
-    <skip />
-    <!-- no translation found for permdesc_startTasksFromRecents (7382133554871222235) -->
-    <skip />
+    <string name="permlab_startTasksFromRecents" msgid="8990073877885690623">"începeți o sarcină din activități recente"</string>
+    <string name="permdesc_startTasksFromRecents" msgid="7382133554871222235">"Permite aplicației să utilizeze obiectul ActivityManager.RecentTaskInfo pentru a lansa o sarcină eșuată, readusă din ActivityManager.getRecentTaskList()."</string>
     <string name="permlab_interactAcrossUsers" msgid="7114255281944211682">"interacţiune între utilizatori"</string>
     <string name="permdesc_interactAcrossUsers" msgid="364670963623385786">"Permite aplicaţiei să efectueze acţiuni pentru diferiţi utilizatori pe dispozitiv. Aplicaţiile rău intenţionate pot utiliza această permisiune pentru a încălca protecţia între utilizatori."</string>
     <string name="permlab_interactAcrossUsersFull" msgid="2567734285545074105">"licenţă completă pentru interacţiune între utilizatori"</string>
@@ -415,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Permite proprietarului să se conecteze la interfața de nivel superior a unui ecran la distanță. Nu ar trebui să fie niciodată necesară pentru aplicațiile obișnuite."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"conectare la un serviciu widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Permite proprietarului să se conecteze la interfaţa de nivel superior a unui serviciu widget. Nu ar trebui să fie niciodată necesară pentru aplicaţiile obişnuite."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"se conectează la un serviciu de furnizare a traseelor"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Permite titularului să se conecteze la furnizorii de trasee înregistrați. Nu este necesară pentru aplicațiile obișnuite."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interacţionare cu administratorul unui dispozitiv"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Permite proprietarului să trimită intenţii către un administrator al dispozitivului. Nu ar trebui să fie niciodată necesară pentru aplicaţiile obişnuite."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"se conectează la o intrare TV"</string>
@@ -615,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"telefon pornit sau oprit"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Permite aplicaţiei să pornească sau să oprească tableta."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Permite aplicaţiei să activeze sau să dezactiveze telefonul."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"resetează timpul limită de afișare"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Permite aplicației să reseteze timpul limită de afișare."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"rulare în mod test de fabrică"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Rulează ca test de nivel redus setat de producător, permiţând accesul complet la sistemul hardware al computerului tablet PC. Permisiune disponibilă doar când acesta rulează în modul de testare setat de producător."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Rulează ca testare de nivel redus al producătorului, permiţând accesul complet la hardware-ul telefonului. Permisiune disponibilă doar când telefonul rulează în modul de testare a producător."</string>
@@ -716,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Permite aplicaţiei să scrie şi să citească sistemul de fişiere cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"efectuarea/primirea apelurilor SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Permite aplicației să efectueze și să primească apeluri SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interacțiune cu ecranul în timpul unui apel"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Permite aplicației să controleze când și cum vede utilizatorul ecranul în timpul unui apel."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interacțiune cu ecranul în timpul unui apel"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Permite aplicației să controleze când și cum vede utilizatorul ecranul în timpul unui apel."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"să interacționeze cu servicii de telefonie"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Permite aplicației să interacționeze cu servicii de telefonie pentru a da / a primi apeluri."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"oferă o experiență de utilizare în timpul unui apel"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Permite aplicației să ofere o experiență de utilizare în timpul unui apel."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"citeşte utilizarea statistică a reţelei"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Permite aplicaţiei să citească utilizarea statistică a reţelei pentru anumite reţele şi aplicaţii."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"gestionează politica de reţea"</string>
@@ -734,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Permite proprietarului să se conecteze la interfața de nivel superior a unui serviciu de citire a notificărilor. În mod normal aplicațiile nu ar trebui să aibă nevoie de această permisiune."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"conectare la un serviciu furnizor de condiții"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Permite proprietarului să se conecteze la interfața de nivel superior a unui serviciu furnizor de condiții. Nu ar trebui să fie necesară pentru aplicațiile obișnuite."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"se conectează la un serviciu de trasee multimedia"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Permite deținătorului să se conecteze la interfața de nivel superior a unui serviciu de trasee multimedia. Nu ar trebui să fie necesară pentru aplicațiile obișnuite."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"se conectează la un serviciu de vis"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Permite deținătorului să se conecteze la interfața superioară a unui serviciu de vis. Această opțiune nu ar trebui să fie necesară pentru aplicațiile obișnuite."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"apelarea aplicației de configurare furnizată de operator"</string>
@@ -1207,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Distribuiți cu %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Selectați o aplicație de pe ecranul de pornire"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Se utilizează în mod prestabilit pentru această acţiune."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Utilizați altă aplicație"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Ștergeţi setările prestabilite din Setări de sistem &gt; Aplicaţii &gt; Descărcate."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Alegeţi o acţiune"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Alegeţi o aplicaţie pentru dispozitivul USB"</string>
@@ -1298,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Permiteţi"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Refuzaţi"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; intenţionează să trimită un mesaj la &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Aceasta "<font fgcolor="#ffffb060">"poate genera costuri"</font>" în contul dvs. mobil."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Aceasta va genera costuri în contul dvs. mobil."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Acest lucru "<b>"poate genera costuri"</b>" în contul dvs. mobil."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Acest lucru va genera costuri în contul dvs. mobil."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Trimiteţi"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Anulaţi"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Doresc să se reţină opţiunea"</string>
@@ -1354,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Atingeţi pentru a dezactiva depanarea USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Schimbați tastatura"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Alegeți tastaturi"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Tastatură fizică"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Afișați metoda de introducere a textului"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Selectaţi aspectul tastaturii"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Atingeţi pentru a selecta un aspect de tastatură."</string>
@@ -1405,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Permite unei aplicații să se asocieze la un serviciu „agent de încredere”."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interacțiune cu sistemul de recuperare și de actualizare"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Permite unei aplicații să interacționeze cu sistemul de recuperare și cu actualizările de sistem."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Creați sesiuni de proiecție media"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Permite unei aplicații să creeze sesiuni de proiecție media. Aceste sesiuni pot permite aplicațiilor să captureze conținuturi vizuale și audio. Nu trebuie utilizată pentru aplicații obișnuite."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Gestionați sesiunile de proiecții media"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Permite unei aplicații să gestioneze sesiunile de proiecții media. Aceste sesiuni pot oferi aplicațiilor capacitatea de a captura conținuturile afișate și conținuturi video. Această opțiune nu ar trebui să fie necesară pentru aplicațiile normale."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Citirea sesiunilor de instalare"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Permite unei aplicații accesul la citirea sesiunilor de instalare. Aceasta poate vedea detalii despre instalările de pachete active."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Atingeţi de două ori pentru a mări/micşora"</string>
@@ -1427,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Refuzaţi"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Permisiune solicitată"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Permisiune solicitată\npentru contul <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Utilizați această aplicație în spațiul personal"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Utilizați această aplicație în spațiul de lucru"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Utilizați această aplicație în afara profilului de serviciu"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Utilizați această aplicație în profilul de serviciu"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Metodă de intrare"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sincronizare"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accesibilitate"</string>
@@ -1503,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Reduceţi valoarea pentru oră"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Setaţi valoarea PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Setaţi valoarea AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Creşteţi valoarea pentru lună"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Reduceţi valoarea pentru lună"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Creşteţi valoarea pentru zi"</string>
@@ -1537,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Editaţi"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Avertisment de utiliz. a datelor"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Atingeţi pt. a afişa utiliz./set."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Datele 2G-3G sunt dezactivate"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Datele 4G sunt dezactivate"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Datele mobile sunt dezactivate"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Datele Wi-Fi sunt dezactivate"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Limita a fost atinsă"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Ați atins limita de date 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Ați atins limita de date 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Ați atins limita de date mobile"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Ați atins limita de date Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"S-au întrerupt datele pentru restul ciclului"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"S-a depăşit limita de date 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"S-a depăşit limita de date 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Limită de date mobile depășită"</string>
@@ -1572,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Acceptaţi apelul?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Întotdeauna"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Numai o dată"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s nu acceptă profilul de serviciu."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s nu acceptă profilul de serviciu"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tabletă"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Căşti"</string>
@@ -1645,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"S-a activat accesibilitatea."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Accesibilitatea a fost anulată"</string>
     <string name="user_switched" msgid="3768006783166984410">"Utilizator curent: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Se comută la <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Proprietar"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Eroare"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Această modificare nu este permisă de administratorul dvs."</string>
@@ -1766,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> selectat"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> a fost șters"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> de serviciu"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Pentru a anula fixarea acestui ecran, atingeți și țineți apăsat pe Înapoi și Recente în același timp."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Pentru a anula fixarea acestui ecran, atingeți și țineți apăsat pe Recente."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ecranul este fixat. Anularea fixării nu este permisă de organizația dvs."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Utilizați fixarea ecranului?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Dacă fixați ecranul, rămâne o singură vizualizare.\n\nPentru a ieși, atingeți și țineți apăsat pe Înapoi și Recente în același timp."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Dacă fixați ecranul, rămâne o singură vizualizare.\n\nPentru a ieși, atingeți și țineți apăsat pe Recente."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NU, MULȚUMESC"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"PORNIȚI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"model pentru deblocare"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"parolă"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ecran fixat"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Fixarea ecranului anulată"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Solicită codul PIN înainte de a anula fixarea"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Solicită modelul pentru deblocare înainte de a anula fixarea"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Solicită parola înainte de a anula fixarea"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Pentru a ajuta la îmbunătățirea duratei bateriei, modul Economisirea bateriei reduce performanțele dispozitivului și limitează vibrațiile și majoritatea datelor de fundal. Mesajele prin e-mail și alte aplicații care se bazează pe sincronizare nu se vor actualiza dacă nu le deschideți.\n\nEconomisirea baterie se dezactivează automat când dispozitivul se încarcă."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Până când inactivitatea dvs. se încheie la <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Timp de un minut"</item>
+    <item quantity="other" msgid="6924190729213550991">"Timp de %d (de) minute"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Timp de o oră"</item>
+    <item quantity="other" msgid="5408537517529822157">"Timp de %d (de) ore"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Nedefinit"</string>
 </resources>
diff --git a/core/res/res/values-ru/strings.xml b/core/res/res/values-ru/strings.xml
index 632bdda..b072385 100644
--- a/core/res/res/values-ru/strings.xml
+++ b/core/res/res/values-ru/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Приложение сможет подключаться к базовому интерфейсу удаленного дисплея. Это разрешение обычно используется только специальными приложениями."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"Подключение к службе виджетов"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Приложение сможет подключаться к базовому интерфейсу службы виджетов. Это разрешение не используется обычными приложениями."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"Подключение к серверам поставщиков маршрутов"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Приложение сможет подключаться к серверам зарегистрированных поставщиков маршрутов. Это разрешение не используется обычными приложениями."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"Взаимодействие с администратором устройства"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Приложение сможет отправлять объекты intent администратору устройства. Это разрешение не используется обычными приложениями."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"Подключение к ТВ-входу"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"Включение/выключение телефона"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Приложение сможет включать и выключать планшетный ПК."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Приложение сможет включать и выключать телефон."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"сброс времени ожидания перед переходом в спящий режим"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Сброс времени ожидания перед переходом в спящий режим."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"Включение тестового режима"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Выполнять стандартную проверку нижнего уровня, обеспечивающую полный доступ к аппаратному обеспечению планшетного ПК. Доступно только в режиме стандартной проверки."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Выполнить стандартную проверку нижнего уровня, обеспечивающую полный доступ к аппаратному обеспечению телефона. Доступно, только в режиме стандартной проверки."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Приложение сможет выполнять чтение и запись в файловую систему кэша."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"Входящие и исходящие вызовы SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Разрешить вызовы по протоколу SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"Управление экраном во время разговора"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Приложение сможет управлять экраном во время разговора."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"Управление экраном во время разговора"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Управление экраном во время разговора."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"доступ к службам телефонии"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Доступ к службам телефонии для совершения и приема вызовов."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"Работа с приложением во время разговора"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Работа с приложением во время разговора."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"Просмотр журнала использования сети"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Приложение сможет считывать сохраненную историю использования определенных сетей и приложений."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"Управление сетевой политикой"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Приложение сможет подключаться к базовому интерфейсу службы просмотра уведомлений. Это разрешение не используется обычными приложениями."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"Подключение к серверам поставщиков условий"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Приложение сможет подключаться к базовому интерфейсу поставщиков условий. Это разрешение обычно используется только специальными приложениями."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"Привязка к средству передачи медиафайлов"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Привязка к интерфейсу верхнего уровня средства передачи медиафайлов. Не требуется для работы обычных приложений."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"Подключение к службе экранных заставок"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Подключение к базовому интерфейсу службы экранных заставок. Это разрешение не используется обычными приложениями."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"Запуск приложения настроек, предоставленного оператором"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Предоставлять доступ с помощью приложения \"%1$s\""</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Выберите приложение"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"По умолчанию для этого действия"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Другое приложение"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Удаляет настройки по умолчанию в меню \"Настройки &gt; Приложения &gt; Загруженные\"."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Выберите действие"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Выбор приложения для USB-устройства"</string>
@@ -1295,12 +1294,12 @@
     <string name="sms_control_message" msgid="3867899169651496433">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; отправляет большое количество SMS. Разрешить приложению и дальше отправлять сообщения?"</string>
     <string name="sms_control_yes" msgid="3663725993855816807">"Разрешить"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Запретить"</string>
-    <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"Приложение &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; собирается отправить сообщение на адрес &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"С вашего мобильного счета "<font fgcolor="#ffffb060">"могут быть списаны средства"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"С вашего мобильного счета будут списаны средства."</font></string>
+    <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"Из приложения &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; будет отправлено сообщение на номер &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Со счета вашего мобильного телефона "<b>"могут быть списаны средства"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Со счета вашего мобильного телефона будут списаны средства."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Отправить"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Отмена"</string>
-    <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Запомнить выбранный телефон"</string>
+    <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Запомнить выбор"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"Это можно изменить позже в разделе настроек \"Приложения\"."</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"Всегда разрешать"</string>
     <string name="sms_short_code_confirm_never_allow" msgid="446992765774269673">"Не разрешать"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Нажмите, чтобы отключить отладку по USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Выбор раскладки"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Выбрать раскладку"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Физическая клавиатура"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Показать способ ввода"</string>
     <string name="hardware" msgid="7517821086888990278">"Аппаратура"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Выберите раскладку клавиатуры"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Нажмите, чтобы выбрать раскладку клавиатуры."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Приложение может подключаться к службе промежуточного агента."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Взаимодействовать с системой восстановления и обновлениями"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Приложение сможет взаимодействовать с системой восстановления и обновлениями системы."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Создание сеансов трансляции контента"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Создание сеансов трансляции контента, во время которых приложение получит доступ к изображению на экране и аудио. Это разрешение обычно используется только специальными приложениями."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Управление сеансами трансляции контента"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Управление сеансами трансляции контента, во время которых приложение получит доступ к изображению на экране и аудио. Большинству приложений это разрешение не требуется."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Чтение данных сеансов установки"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Чтение данных текущих сеансов установки пакетов."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Нажмите дважды для изменения масштаба"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Отклонить"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Разрешение запрошено"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Требуется разрешение\nдля аккаунта <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Вы перешли в хранилище личных данных."</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Вы перешли в хранилище рабочих данных."</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Это приложение используется в личном профиле"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Вы перешли в рабочий профиль"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Способ ввода"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синхр."</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Спец. возможности"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"На час назад"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Установить время после полудня"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Установить время до полудня"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"АМ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"На месяц вперед"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"На месяц назад"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"На день вперед"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Изменить"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Осталось мало трафика"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Проверьте трафик и настройки."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Передача данных 2G/3G отключена"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Передача данных 4G отключена"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Передача мобильных данных отключена"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Передача данных Wi-Fi отключена"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Достигнут лимит"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Достигнут лимит трафика 2G/3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Достигнут лимит трафика 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Достигнут лимит мобильного трафика"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Достигнут лимит трафика Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Передача данных приостановлена"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Превышен лимита трафика 2G и 3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Превышен лимит на трафик 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Превышен лимит мобильного трафика"</string>
@@ -1570,9 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Ответить?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Всегда"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Только сейчас"</string>
-    <!-- String.format failed for translation -->
-    <!-- no translation found for activity_resolver_work_profiles_support (5462991471861024343) -->
-    <skip />
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s не поддерживает рабочие профили"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Планшетный ПК"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Наушники"</string>
@@ -1645,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Специальные возможности включены."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Специальные возможности не будут включены."</string>
     <string name="user_switched" msgid="3768006783166984410">"Выбран аккаунт пользователя <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Смена профиля на <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Владелец"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Ошибка"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Это действие запрещено администратором"</string>
@@ -1766,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Выбран элемент <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Цифра <xliff:g id="KEY">%1$s</xliff:g> удалена"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Рабочий <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Чтобы отключить блокировку, одновременно нажмите и удерживайте кнопки \"Назад\" и \"Недавние приложения\"."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Чтобы отключить блокировку, нажмите и удерживайте кнопку недавних приложений."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Блокировка включена. Ее отключение запрещено правилами организации."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Использовать блокировку в приложении?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Режим блокировки не позволяет переходить в другие приложения.\n\nДля выхода из него одновременно нажмите и удерживайте кнопки \"Назад\" и \"Недавние приложения\"."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Эта функция блокирует переход в другие приложения.\n\nЧтобы отключить блокировку, нажмите и удерживайте кнопку недавних приложений."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"НЕТ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ДА"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-код"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"графический ключ"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"пароль"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Блокировка включена"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Блокировка выключена"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Запрашивать PIN-код для отключения блокировки"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Запрашивать графический ключ для отключения блокировки"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Запрашивать пароль для отключения блокировки"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Чтобы продлить время работы устройства от батареи, в режиме энергосбережения снижается производительность, а также ограничивается использование вибросигнала и фоновой передачи данных. Данные, требующие синхронизации, могут обновляться только когда вы откроете приложение.\n\nРежим энергосбережения автоматически отключается во время зарядки устройства."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Когда период простоя завершится (в <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>)"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 мин."</item>
+    <item quantity="other" msgid="6924190729213550991">"%d мин."</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 ч."</item>
+    <item quantity="other" msgid="5408537517529822157">"%d ч."</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Бессрочно"</string>
 </resources>
diff --git a/core/res/res/values-si-rLK/strings.xml b/core/res/res/values-si-rLK/strings.xml
index 8db3349..98a4e39 100644
--- a/core/res/res/values-si-rLK/strings.xml
+++ b/core/res/res/values-si-rLK/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"දූරස්ථ දර්ශනය ඉහල මට්ටමේ අතුරු මුහුණතක් වෙත සම්බන්ධ කිරීමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම්වලට කිසි විටෙක අවශ්‍ය නොවෙයි."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"විජට සේවාවකට බඳින්න"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"විජට් සේවාව ඉහල මට්ටමේ අතුරු මුහුණතක් වෙත සම්බන්ධ කිරීමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම්වලට කිසි විටෙක අවශ්‍ය නොවෙයි."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"මාර්ග ප්‍රතිපාදකගේ සේවාව බඳින්න"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ඕනෑම ලියාපදිංචි කළ මාර්ග ප්‍රතිපාදකයන්ට බඳින්න ධාරකයාට අනුමත කරන්න. සාමාන්‍ය යෙදුම් සඳහා කිසිදා අවශ්‍ය නොවෙයි."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"උපාංග පරිපාලක සමඟ අන්තර්ක්‍රියාකාරී වීම"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"උපාංග පාලකයා වෙතට අභිප්‍රායයන් යැවීමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම්වලට කිසි විටෙක අවශ්‍ය නොවෙයි."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV ආදානයක් වෙතට බඳින්න"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"දුරකථනය බල ගැන්වීම හෝ වැසීම"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ටැබ්ලටය සක්‍රිය හෝ අක්‍රිය කිරීමට යෙදුමට අවසර දේ."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"දුරකථනය සක්‍රිය සහ අක්‍රිය කිරීමට යෙදුමට අවසර දෙන්න."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"කල් ඉකුත්වීම දර්ශනය යළි පිහිටුවන්න"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"කල් ඉකුත්වීම දර්ශනය යළි පිහිටුවන්න යෙදුමට ඉඩ දෙන්න."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"කර්මාන්තශාලා පරීක්ෂණ ආකාරය තුළ ධාවනය කරන්න"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ටැබ්ලටයේ දෘඩාංග වෙත සම්පූර්ණ පිවිසුම සඳහා අවසර දීමෙන් පහළ මට්ටමේ නිපැවුම්කරු පරීක්ෂණයක් ලෙස ධාවනය කරන්න. නිපැවුම්කරු පරීක්ෂණ ආකාරයෙන් ටැබ්ලටයේ ධාවනය වන විට පමණි."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"දුරකථනයේ දෘඩාංග වෙත සම්පූර්ණ පිවිසුම සඳහා අවසර දීමෙන් පහළ මට්ටමේ නිපැවුම්කරු පරීක්ෂණයක් ලෙස ධාවනය කරන්න. නිපැවුම්කරු පරීක්ෂණ ආකාරයෙන් දුරකථනයේ ධාවනය වන විට පමණි."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"හැඹිලි ගොනු පද්ධති කියවීමට සහ ලිවීමට යෙදුමට අවසර දෙන්න."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP ඇමතුම් සිදුකිරීමට/ලබාගැනීමට"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP ඇමතුම් සිදුකිරීමට සහ ලබාගැනීමට යෙදුමට ඉඩ දෙන්න."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ලැබෙන ඇමතුම් තිරය සමග අන්තර් ක්‍රියාකාරී වන්න"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ලැබෙන ඇමතුම් තිරය පරිශීලකයාට පෙනෙන්නේ කෙදිනද සහ කෙසේද යැයි පාලනය කිරීමට යෙදුමට අවසර දෙන්න."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ලැබෙන ඇමතුම් තිරය සමග අන්තර් ක්‍රියාකාරී වන්න"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ලැබෙන ඇමතුම් තිරය පරිශීලකයාට පෙනෙන්නේ කෙදිනද සහ කෙසේද යැයි පාලනය කිරීමට යෙදුමට අවසර දෙන්න."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"දුරකථන සේවාවන් සමඟ සම්බන්ධ වීම"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"ඇමතුම් ගැනීමට/ලැබීමට දුරකථන සේවාවන් සමඟ සම්බන්ධ වීමට යෙදුමට ඉඩ දෙන්න."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"එන-ඇමතුම් පරිශීලක අත්දැකීම සපයන්න"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"එන-ඇමතුම් පරිශීලක අත්දැකීම සැපයීමට යෙදුම් වෙත ඉඩ දෙන්න."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"ඉතිහාසගත ජාල භාවිතය කියවන්න"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"විශේෂිත ජාල සහ යෙදුම් සඳහා ඉතිහාසගත ජාල භාවිතය කියවීමට යෙදුමට අවසර දෙන්න."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ජාල ප්‍රතිපත්තිය කළමනාකරණය කිරීම"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"දැනුම්දීම් අසන්නාගේ සේවාවේ ඉහළ මට්ටමේ අතුරුමුහුණතට බැඳීමට දරන්නාට අවසර දේ. සාමාන්‍ය යෙදුම් සඳහා කිසිසේත් අවශ්‍ය නොවේ."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"තත්ත්වය සපයන්නාගේ සේවාවට බඳින්න"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"තත්ත්වය සපයන්නාගේ සේවාවට ඉහළ-මට්ටමේ අතුරු මුහුණතක් බැඳිමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම් සඳහා කවදාවත් අවශ්‍යය නොවෙයි."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"මාධ්‍ය ගමන් කරන සේවාව බඳින්න"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"මාධ්‍ය ගමන් කරන සේවාවට ඉහළ-මට්ටමේ අතුරු මුහුණතක් බැඳිමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම් සඳහා කවදාවත් අවශ්‍යය නොවෙයි."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ඩ්‍රීම් සේවාවකට බැඳීම"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"ඩ්‍රීම් සේවාව ඉහල මට්ටමේ අතුරු මුහුණතක් වෙත සම්බන්ධ කිරීමට ධාරකයාට අවසර දෙන්න. සාමාන්‍ය යෙදුම්වලට කිසි විටෙක අවශ්‍ය නොවෙයි."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"වාහකය සැපයු වින්‍යාසය යෙදුම ඉල්ලා සිටින්න"</string>
@@ -1207,6 +1205,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%s සමඟ බෙදාගන්න"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"මුල්පිටු යෙදුමක් තෝරන්න"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"මෙම ක්‍රියාව සඳහා සුපුරුද්දෙන් භාවිත කරන්න."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"වෙනත් යෙදුමක් භාවිතා කරන්න"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"පද්ධති සැකසීම් &gt; යෙදුම් &gt; බාගැනීම් තුළ ඇති සුපුරුද්ද හිස් කරන්න."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ක්‍රියාවක් තෝරන්න"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB උපාංගය සඳහා යෙදුමක් තෝරන්න"</string>
@@ -1245,7 +1244,7 @@
     <string name="new_app_description" msgid="1932143598371537340">"සුරැකීමකින් තොරව පරණ යෙදුම නවත්වන්න."</string>
     <string name="sendText" msgid="5209874571959469142">"පෙළ සඳහා ක්‍රියාව තෝරන්න"</string>
     <string name="volume_ringtone" msgid="6885421406845734650">"හඬ නඟනයේ ශබ්දය"</string>
-    <string name="volume_music" msgid="5421651157138628171">"මාධ්‍ය ශබ්දය ත්‍රීවතාවය"</string>
+    <string name="volume_music" msgid="5421651157138628171">"මාධ්‍ය ශබ්දය"</string>
     <string name="volume_music_hint_playing_through_bluetooth" msgid="9165984379394601533">"බ්ලූටූත් හරහා ධාවනය වෙයි"</string>
     <string name="volume_music_hint_silent_ringtone_selected" msgid="8310739960973156272">"නිහඬ රිගින් ටෝනයක් සකසන්න"</string>
     <string name="volume_call" msgid="3941680041282788711">"ඇමතුම-තුළ ශබ්ද ත්‍රීවතාව"</string>
@@ -1256,7 +1255,7 @@
     <string name="volume_icon_description_bluetooth" msgid="6538894177255964340">"බ්ලූටූත් ශබ්ද ත්‍රීවතාව"</string>
     <string name="volume_icon_description_ringer" msgid="3326003847006162496">"රින්ටෝනයේ ශබ්දය"</string>
     <string name="volume_icon_description_incall" msgid="8890073218154543397">"ඇමතුම් ශබ්දය ත්‍රීවතාවය"</string>
-    <string name="volume_icon_description_media" msgid="4217311719665194215">"මාධ්‍ය ශබ්දය ත්‍රීවතාවය"</string>
+    <string name="volume_icon_description_media" msgid="4217311719665194215">"මාධ්‍ය ශබ්දය"</string>
     <string name="volume_icon_description_notification" msgid="7044986546477282274">"දැනුම්දීමේ ශබ්ද ත්‍රීවතාව"</string>
     <string name="ringtone_default" msgid="3789758980357696936">"සුපුරුදු රින්ටෝනය සකසන්න"</string>
     <string name="ringtone_default_with_actual" msgid="8129563480895990372">"සුපුරුදු රින්ටෝනය (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
@@ -1298,9 +1297,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"අවසර දෙන්න"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ප්‍රතික්ෂේප කරන්න"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;b&gt; වෙත කෙටි පණිවීඩයක් යැවීමට &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;b&gt; කැමතිය."</string>
-    <!-- syntax error in translation for sms_short_code_details (3492025719868078457) org.xmlpull.v1.XmlPullParserException: expected: /string read: font (position:END_TAG </font>@1:83 in     <string name="sms_short_code_details" msgid="3492025719868078457">"මෙය "</font>"ඔබගේ ජංගම ගිණුමේ"<font fgcolor="#ffffb060">" අය වීම් වලට හේතුවක් වේ."</string>
-)  -->
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"මෙය ඔබගේ ජංගම ගිණුමෙන් අයවීමට හේතු වේ."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"මෙය "<b>"ඔබගේ ජංගම ගිණුමේ"</b>" අය වීම් වලට හේතුවක් වේ."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"මෙය ඔබගේ ජංගම ගිණුමෙන් අයවීමට හේතු වේ."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"යවන්න"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"අවලංගු කරන්න"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"මගේ තේරීම මතක තබාගන්න"</string>
@@ -1355,7 +1353,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB නිදොස්කරණය අබල කිරීමට ස්පර්ශ කරන්න."</string>
     <string name="select_input_method" msgid="8547250819326693584">"යතුරු පුවරු වෙනස් කිරීම"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"යතුරු පුවරු තෝරන්න"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"භෞතික යතුරු පුවරුව"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ආදාන ක්‍රමය පෙන්වන්න"</string>
     <string name="hardware" msgid="7517821086888990278">"දෘඨාංග"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"යතුරු පුවරුවට පිරිසැලැස්ම තෝරන්න"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"යතුරු පුවරුවට පිරිසැලැස්මක් තේරීමට ස්පර්ශ කරන්න."</string>
@@ -1406,8 +1404,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"යෙදුමකට විශ්වාසනීය ඒජන්ත සේවාවකට බැඳීමට අවසර දේ."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"ප්‍රතිසාධන පද්ධතිය සහ යාවත්කාලීන සමඟ කටයුතු කරන්න"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"යෙදුමකට ප්‍රතිසාධන පද්ධතිය සහ පද්ධති යාවත්කාලීන සමඟ කටයුතු කිරීමට ඉඩ දෙන්න."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"මාධ්‍ය ප්‍රක්ෂේපන සැසියන් සාදන්න"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"මාධ්‍ය ප්‍රක්ෂේපන සැසියන් සාදන්න යෙදුමට ඉඩ දෙන්න. ශ්‍රව්‍ය අන්තර්ගතයන් සහ දර්ශන ලබා ගැනීමට හැකියාව යෙදුම් වලට මෙම සැසියන් ලබාගත හැක. සමාන්‍ය යෙදුම් සඳහා කවදාවත් අවශ්‍ය නොවේ."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"මාධ්‍ය ප්‍රක්ෂේපන සැසියන් කළමනාකරණය කරන්න"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"මාධ්‍ය ප්‍රක්ෂේපන සැසියන් කළමනාකරණ යෙදුමට ඉඩ දෙන්න. ශ්‍රව්‍ය අන්තර්ගතයන් සහ දර්ශන ලබා ගැනීමට හැකියාව යෙදුම් වලට මෙම සැසියන් ලබාගත හැක. සමාන්‍ය යෙදුම් සඳහා කවදාවත් අවශ්‍ය නොවේ."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ස්ථාපන සැසියන් කියවන්න"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ස්ථාපන සැසිය කියවීමට යෙදුමට ඉඩ දෙන්න. සක්‍රිය පැකේජ ස්ථාපනය පිළිබඳ විස්තර බැලීමට එයට මෙයින් ඉඩ දෙයි."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"විශාලන පාලනය සඳහා දෙවරක් ස්පර්ශ කරන්න"</string>
@@ -1428,8 +1426,8 @@
     <string name="deny" msgid="2081879885755434506">"ප්‍රතික්ෂේප කරන්න"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"අවසර ඉල්ලා සිටී"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> ගිණුම සඳහා\nඅවසර ඉල්ලන ලදි."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"මෙම යෙදුම ඔබගේ පුද්ගලික කොටසේ ඔබ භාවිතා කරයි"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"මෙම යෙදුම ඔබගේ වැඩ කරන කොටසේ ඔබ භාවිතා කරයි"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"මෙම යෙදුම ඔබගේ කාර්යාල පැතිකඩින් පිට දී ඔබ භාවිතා කරයි"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"මෙම යෙදුම ඔබගේ පුද්ගලික කොටසේ ඔබ භාවිතා කරයි"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ආදාන ක්‍රමය"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"සමමුහුර්තය"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ප්‍රවේශ්‍යතාව"</string>
@@ -1504,8 +1502,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"පැය අඩුකරන්න"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"ප.ව.සකසන්න"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"පෙ.ව. සකස් කිරීම"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ප.ව."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"පෙ.ව."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"මාසය වැඩි කරන්න"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"මාසයක් අඩු කරන්න"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"දවස වැඩි කරන්න"</string>
@@ -1538,11 +1534,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"සංස්කරණය කරන්න"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"දත්ත භාවිතා අවවාදය"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"භාවිතය සහ සැකසීම් බැලීමට ස්පර්ශ කරන්න."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G දත්ත අක්‍රියයි"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G දත්ත අක්‍රියයි"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"සෙලියුලර් දත්ත අක්‍රියයි"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi දත්ත අක්‍රියයි"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"සීමාව ළඟාවී ඇත"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G දත්ත සීමාවට ළඟාවී ඇත"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G දත්ත සීමාවට ළඟාවී ඇත"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"සෙල්‍යුලර් දත්ත සීමාවට ළඟාවී ඇත"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi දත්ත සීමාවට ළඟාවී ඇත"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"විරාම චක්‍රය සඳහා දත්ත විරාමය කරන ලදි"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G දත්ත සීමාව ඉක්මවන ලදි"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G දත්ත සීමාව ඉක්මවා යන ලදි"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"සෙලියුලර් දත්ත සීමාව ඉක්මවා තිබේ"</string>
@@ -1573,7 +1569,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"ඇමතුම පිළිගන්නවාද?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"සැම විටම"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"එක් වාරයයි"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s වැඩ කරන පැතිකඩ සඳහා සහාය ලබනොදේ."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s කාර්යාල පැතිකඩ සඳහා සහාය ලබනොදේ."</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ටැබ්ලට්ය"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"දුරකථනය"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ඉස් බණු"</string>
@@ -1646,6 +1642,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ප‍්‍රවේශ්‍යතාව සබල කරන ලදි."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ප‍්‍රවේශ්‍යතාව අවලංගු කර ඇත."</string>
     <string name="user_switched" msgid="3768006783166984410">"දැනට සිටින පරිශීලකයා <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> වෙත මාරු කරමින්…"</string>
     <string name="owner_name" msgid="2716755460376028154">"හිමිකරු"</string>
     <string name="error_message_title" msgid="4510373083082500195">"දෝෂය"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ඔබගේ පරිපාලක විසින් මෙම වෙනස් කිරීමට ඉඩ නොදේ"</string>
@@ -1767,31 +1764,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> තෝරාගෙන ඇත"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> මකා දමන ලදි"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"වැඩ <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"මෙම තිරය අගුළු ඇරීමට, ආපසු සහ මෑත බොත්තම් එකම විටෙක ස්පර්ශ කර අල්ලාගෙන සිටින්න."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"මෙම තිරය අගුළු ඇරීමට, මෑත බොත්තම ස්පර්ශ කර අල්ලාගෙන සිටින්න."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"තිරය අගුළු දමා ඇත. ඔබගේ සංවිධානය විසින් අගුළු ඇරීමට ඉඩ නොදෙයි."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"තිරය අගුළු දැමීම භාවිත කරනවාද?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"තිර ඇමිණුම තනි පෙනුමක් තුළ දර්ශනයට අගුළු දමයි.\n\nඉවත් වීමට, ආපසු සහ බොත්තම් ස්පර්ශකොට අල්ලා ගෙන සිටින්න."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"තනි පෙනුමක් තුළ තිරයේ අගුළු ඇරීමට, දර්ශනයට අගුළු දමයි.\n\nඉවත් වීමට, ස්පර්ශකොට මෑත දේවල් අල්ලා ගන්න."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"නැත, ස්තූතියි"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ආරම්භය"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"අඟුළු ඇරීමේ රටාව"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"මුරපදය"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"තිරය අගුළු දමා ඇත"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"තිරයේ අගුළු ඇර ඇත"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ගැලවීමට පෙර PIN විමසන්න"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ගැලවීමට පෙර අගුළු අරින රටාව සඳහා අසන්න"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ගැලවීමට පෙර මුරපදය විමසන්න"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"බැටරියේ ජීව කාලය දියුණු කිරීමට උදව් කිරීමට, ඔබගේ උපාංගයේ ක්‍රියාකාරිත්වය සහ සීමා කළ කම්පනයන් සහ බොහොමයක් පසුබිම් දත්ත බැටරි සුරැකීමෙන් අඩු කරයි. සමමුහුර්ත කිරීම බලාපොරොත්තු වෙන ඊ-තැපෑල, පණිවිඩ යැවීම සහ වෙනත් යෙදුම් යාවත්කාලීන වන්නේ ඔබ ඒවා විවෘත කළ විට පමණි.\n\nඔබගේ උපාංගය ආරෝපණය වන විට බැටරි සුරැකීම ස්වයංක්‍රීයව අක්‍රිය වේ."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"ඔබගේ බිඳවැටුම් වේලාව <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> දී අවසන්වන තුරු"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"විනාඩි එකක් සඳහා"</item>
+    <item quantity="other" msgid="6924190729213550991">"විනාඩි %d සඳහා"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"පැයක් සඳහා"</item>
+    <item quantity="other" msgid="5408537517529822157">"පැය %d ක් සඳහා"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"අනියත ආකාරයට"</string>
 </resources>
diff --git a/core/res/res/values-sk/strings.xml b/core/res/res/values-sk/strings.xml
index e561d9b..1bfa108 100644
--- a/core/res/res/values-sk/strings.xml
+++ b/core/res/res/values-sk/strings.xml
@@ -183,9 +183,9 @@
     <string name="global_action_toggle_silent_mode" msgid="8219525344246810925">"Tichý režim"</string>
     <string name="global_action_silent_mode_on_status" msgid="3289841937003758806">"Zvuk je VYPNUTÝ."</string>
     <string name="global_action_silent_mode_off_status" msgid="1506046579177066419">"Zvuk je zapnutý"</string>
-    <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"Režim V lietadle"</string>
-    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"Režim V lietadle je ZAPNUTÝ"</string>
-    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"Režim V lietadle je VYPNUTÝ"</string>
+    <string name="global_actions_toggle_airplane_mode" msgid="5884330306926307456">"Režim v lietadle"</string>
+    <string name="global_actions_airplane_mode_on_status" msgid="2719557982608919750">"Režim v lietadle je ZAPNUTÝ"</string>
+    <string name="global_actions_airplane_mode_off_status" msgid="5075070442854490296">"Režim v lietadle je VYPNUTÝ"</string>
     <string name="global_action_settings" msgid="1756531602592545966">"Nastavenia"</string>
     <string name="global_action_lockdown" msgid="8751542514724332873">"Uzamknúť"</string>
     <string name="status_bar_notification_info_overflow" msgid="5301981741705354993">"999+"</string>
@@ -370,7 +370,7 @@
     <string name="permdesc_getAppOpsStats" msgid="6243887041577912877">"Umožňuje aplikácii získať zhromaždené štatistické údaje o fungovaní aplikácií. Bežné aplikácie toto nastavenie nepoužívajú."</string>
     <string name="permlab_updateAppOpsStats" msgid="8829097373851521505">"upraviť štatistické údaje o fungovaní aplikácií"</string>
     <string name="permdesc_updateAppOpsStats" msgid="50784596594403483">"Umožňuje aplikácii zmeniť zhromaždené štatistické údaje o fungovaní aplikácií. Bežné aplikácie toto nastavenie nepoužívajú."</string>
-    <string name="permlab_backup" msgid="470013022865453920">"Ovládať zálohovanie a obnovu systému"</string>
+    <string name="permlab_backup" msgid="470013022865453920">"ovládať zálohovanie a obnovu systému"</string>
     <string name="permdesc_backup" msgid="6912230525140589891">"Umožňuje aplikácii ovládať mechanizmus na zálohovanie a obnovu údajov systému. Bežné aplikácie toto nastavenie nepoužívajú."</string>
     <string name="permlab_confirm_full_backup" msgid="5557071325804469102">"potvrdenie operácie úplnej zálohy alebo úplného obnovenia"</string>
     <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"Umožňuje aplikácii spustiť používateľské rozhranie potvrdenia úplnej zálohy. Toto nastavenie by nemala používať žiadna aplikácia."</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Umožňuje držiteľovi viazať sa na najvyššiu úroveň rozhrania vzdialeného displeja. Bežné aplikácie by toto nastavenie nemali nikdy potrebovať."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"viazať sa k službe miniaplikácie"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Umožňuje držiteľovi viazať sa na najvyššiu úroveň rozhrania služby miniaplikácií. Bežné aplikácie by toto nastavenie nemali nikdy potrebovať."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"viazanie na službu poskytovateľa cesty"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Umožňuje držiteľovi viazať sa na akýchkoľvek registrovaných poskytovateľov cesty. Normálne aplikácie by toto povolenie nemali nikdy nepotrebovať."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"komunikovať so správcom zariadenia"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Umožňuje držiteľovi odosielať informácie správcovi zariadenia. Bežné aplikácie by toto nastavenie nemali nikdy potrebovať."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"viazanie na televízny vstup"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"zapnutie a vypnutie telefónu"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Umožňuje aplikácii zapnúť a vypnúť tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Umožňuje aplikácii zapnúť a vypnúť telefón."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"obnoviť časový limit obrazovky"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Umožňuje aplikácii obnoviť časový limit obrazovky."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"spustenie v režime továrenského testu"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Umožňuje aplikácii spustenie v režime nízkoúrovňového testu výrobcu a povolí úplný prístup k hardvéru tabletu. K dispozícii iba vtedy, keď je tablet spustený v režime testovania výrobcu."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Umožňuje aplikácii spustenie v režime nízkoúrovňového testu výrobcu a povolí úplný prístup k hardvéru telefónu. K dispozícii iba vtedy, keď je telefón spustený v režime testovania výrobcu."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Umožňuje aplikácii čítať a zapisovať do súborového systému vyrovnávacej pamäte."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"uskutočňovanie/príjem hovorov SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Umožňuje aplikácii uskutočňovať a prijímať hovory SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakcia s obrazovkou hovoru"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Umožňuje aplikácii ovládať, kedy a ako sa používateľovi zobrazí obrazovka hovoru."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakcia s obrazovkou hovoru"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Umožňuje aplikácii ovládať, kedy a ako sa používateľovi zobrazí obrazovka hovoru."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"komunikovať s telefonickými službami"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Umožňuje aplikácii komunikovať s telefonickými službami a uskutočňovať a prijímať hovory."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"zobrazenie používateľského prostredia počas hovoru"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Umožňuje aplikácii zobraziť používateľské prostredie počas hovoru."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"čítať históriu používania siete"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Umožňuje aplikácii čítať históriu používania siete pre určité siete a aplikácie."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"spravovať pravidlá siete"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Umožňuje držiteľovi naviazať sa na najvyššiu úroveň služby na počúvanie upozornení. Bežné aplikácie by toto nastavenie nemali nikdy požadovať."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"viazanie na službu poskytovateľa podmienky"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Umožňuje držiteľovi viazať sa na najvyššiu úroveň rozhrania služby poskytovateľa podmienky. Bežné aplikácie by toto povolenie nemali nikdy potrebovať."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"viazanie na službu smerovania médií"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Umožňuje držiteľovi viazať sa na najvyššiu úroveň rozhrania služby smerovania médií. Bežné aplikácie by toto povolenie nemali nikdy potrebovať."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"viazať sa so službou Dream service"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Umožňuje držiteľovi viazať sa na najvyššiu úroveň rozhrania služby Dream service. Bežné aplikácie by toto povolenie nemali nikdy potrebovať."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"vyvolanie aplikácie pre konfiguráciu poskytnutú operátorom"</string>
@@ -764,17 +762,17 @@
     <string name="policydesc_setGlobalProxy" msgid="6387497466660154931">"Vyberte globálny server proxy, ktorý sa bude používať po aktivácii pravidiel. Platný globálny server proxy nastavuje iba prvý správca zariadenia."</string>
     <string name="policylab_expirePassword" msgid="885279151847254056">"Nastaviť vypršanie hesla zámky"</string>
     <string name="policydesc_expirePassword" msgid="1729725226314691591">"Nastavte, ako často sa musí zmeniť heslo na uzamknutie obrazovky."</string>
-    <string name="policylab_encryptedStorage" msgid="8901326199909132915">"Nastaviť šifr. ukl. priestoru"</string>
+    <string name="policylab_encryptedStorage" msgid="8901326199909132915">"Nastaviť šifrovanie úložiska"</string>
     <string name="policydesc_encryptedStorage" msgid="2637732115325316992">"Vyžadovať šifrovanie uložených údajov aplikácií."</string>
     <string name="policylab_disableCamera" msgid="6395301023152297826">"Zakázať fotoaparáty"</string>
     <string name="policydesc_disableCamera" msgid="2306349042834754597">"Zakázať používanie všetkých fotoaparátov zariadenia."</string>
-    <string name="policylab_disableKeyguardFeatures" msgid="266329104542638802">"Zákaz funkcie v zámke kláves."</string>
-    <string name="policydesc_disableKeyguardFeatures" msgid="3467082272186534614">"Zabrániť používaniu niektorých funkcií v zámke klávesov."</string>
+    <string name="policylab_disableKeyguardFeatures" msgid="266329104542638802">"Zákaz funkcií pri zámke klávesov"</string>
+    <string name="policydesc_disableKeyguardFeatures" msgid="3467082272186534614">"Zabrániť používaniu niektorých funkcií pri zámke klávesov."</string>
   <string-array name="phoneTypes">
     <item msgid="8901098336658710359">"Domov"</item>
     <item msgid="869923650527136615">"Mobil"</item>
     <item msgid="7897544654242874543">"Práca"</item>
-    <item msgid="1103601433382158155">"Fax do práce"</item>
+    <item msgid="1103601433382158155">"Fax práca"</item>
     <item msgid="1735177144948329370">"Fax domov"</item>
     <item msgid="603878674477207394">"Pager"</item>
     <item msgid="1650824275177931637">"Iné"</item>
@@ -817,7 +815,7 @@
     <string name="phoneTypeHome" msgid="2570923463033985887">"Domov"</string>
     <string name="phoneTypeMobile" msgid="6501463557754751037">"Mobil"</string>
     <string name="phoneTypeWork" msgid="8863939667059911633">"Práca"</string>
-    <string name="phoneTypeFaxWork" msgid="3517792160008890912">"Fax do práce"</string>
+    <string name="phoneTypeFaxWork" msgid="3517792160008890912">"Fax práca"</string>
     <string name="phoneTypeFaxHome" msgid="2067265972322971467">"Fax domov"</string>
     <string name="phoneTypePager" msgid="7582359955394921732">"Pager"</string>
     <string name="phoneTypeOther" msgid="1544425847868765990">"Iné"</string>
@@ -874,11 +872,11 @@
     <string name="relationTypeManager" msgid="6365677861610137895">"Manažér"</string>
     <string name="relationTypeMother" msgid="4578571352962758304">"Matka"</string>
     <string name="relationTypeParent" msgid="4755635567562925226">"Rodič"</string>
-    <string name="relationTypePartner" msgid="7266490285120262781">"Partner(-ka)"</string>
+    <string name="relationTypePartner" msgid="7266490285120262781">"Partner(ka)"</string>
     <string name="relationTypeReferredBy" msgid="101573059844135524">"Referencie od"</string>
     <string name="relationTypeRelative" msgid="1799819930085610271">"Príbuzný(-á)"</string>
     <string name="relationTypeSister" msgid="1735983554479076481">"Sestra"</string>
-    <string name="relationTypeSpouse" msgid="394136939428698117">"Manžel(-ka)"</string>
+    <string name="relationTypeSpouse" msgid="394136939428698117">"Manžel(ka)"</string>
     <string name="sipAddressTypeCustom" msgid="2473580593111590945">"Vlastné"</string>
     <string name="sipAddressTypeHome" msgid="6093598181069359295">"Domov"</string>
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"Práca"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Zdieľať v aplikácii %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Vyberte domovskú aplikáciu"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Použiť ako predvolené nastavenie pre túto akciu."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Použiť inú aplikáciu"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Vymazať predvolené nastavenia v sekcii Nastavenia systému &gt; Aplikácie &gt; Stiahnuté položky."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Zvoľte akciu"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Zvoľte aplikáciu pre zariadenie USB"</string>
@@ -1257,7 +1256,7 @@
     <string name="volume_icon_description_media" msgid="4217311719665194215">"Hlasitosť médií"</string>
     <string name="volume_icon_description_notification" msgid="7044986546477282274">"Hlasitosť upozornení"</string>
     <string name="ringtone_default" msgid="3789758980357696936">"Predvolený tón zvonenia"</string>
-    <string name="ringtone_default_with_actual" msgid="8129563480895990372">"Predvolený tón zvonenia (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
+    <string name="ringtone_default_with_actual" msgid="8129563480895990372">"Predvolený tón (<xliff:g id="ACTUAL_RINGTONE">%1$s</xliff:g>)"</string>
     <string name="ringtone_silent" msgid="7937634392408977062">"Žiadny"</string>
     <string name="ringtone_picker_title" msgid="3515143939175119094">"Vyzváňacie tóny"</string>
     <string name="ringtone_unknown" msgid="5477919988701784788">"Neznámy tón zvonenia"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Povoliť"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Odmietnuť"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; chce odoslať správu na adresu &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"Môžu sa účtovať poplatky"</font>" na váš mobilný účet."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Budú sa účtovať poplatky na váš mobilný účet."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Táto akcia "<b>"môže viesť k zaúčtovaniu poplatkov"</b>" na váš účet u mobilného operátora."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Táto akcia povedie k zaúčtovaniu poplatku na váš účet u mobilného operátora."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Odoslať"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Zrušiť"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Zapamätať si voľbu"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Dotknutím zakážete ladenie USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Zmeniť klávesnicu"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Vybrať klávesnice"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fyzická klávesnica"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Zobraziť metódu vstupu"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardvér"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Zvoľte rozloženie klávesnice"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Dotykom zvoľte rozloženie klávesnice."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Umožňuje aplikácii viazať sa na službu agenta dôvery."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interakcia so systémom aktualizácií a obnovenia"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Umožňuje aplikácii interakciu so systémom obnovenia a s aktualizáciami systému."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Vytváranie relácií projekcie médií"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Umožňuje aplikácii vytvárať relácie projekcie médií. Tieto relácie môžu aplikáciám umožniť zaznamenávať obsah na obrazovke a zvukový obsah. Bežné aplikácie by toto povolenie nemali nikdy potrebovať."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Správa relácií premietania médií"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Umožňuje aplikácii spravovať relácie premietania médií. Tieto relácie môžu aplikáciám umožniť zaznamenávanie obsahu obrazu a zvuku. Bežné aplikácie by tieto povolenia nemali nikdy potrebovať."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Čítať relácie inštalácií"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Toto povolenie umožňuje aplikácii čítať relácie inštalácií a zobraziť tak podrobnosti o aktívnych inštaláciách balíkov."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Ovládacie prvky lupy zobrazíte dvojitým dotknutím"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Zamietnuť"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Vyžaduje sa povolenie"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Vyžaduje sa oprávnenie\npre účet <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Túto aplikáciu používate vo svojom osobnom priestore"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Túto aplikáciu používate vo svojom pracovnom priestore"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Túto aplikáciu používate mimo svojho pracovného profilu"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Túto aplikáciu používate vo svojom pracovnom profile"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Metóda vstupu"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synchronizovať"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Zjednodušenie"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Ubrať hodinu"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Nastaviť čas popoludní"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Nastaviť čas dopoludnia"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Pridať mesiac"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Ubrať mesiac"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Pridať deň"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Upraviť"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Upozornenie o využití dát"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Zobr. využív. dát a nastavení."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"dáta 2G–3G sú vypnuté"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"dáta 4G sú vypnuté"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobilné dáta sú vypnuté"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Dáta siete Wi-Fi sú vypnuté"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Dosiahli ste limit"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Bol dosiahnutý limit 2G–3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Bol dosiahnutý limit 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Bol dosiahnutý limit mobilných dát"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Bol dosiahnutý limit dát Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Údaje pre zbytok cyklu pozastavené"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G, 3G dátový limit prekročený"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Dátový limit 4G bol prekročený"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Presiahli ste limit mobil. dát"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Prijať hovor?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Vždy"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Len raz"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s nepodporuje pracovný profil."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"Spúšťač %1$s nepodporuje pracovné profily"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefón"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Slúchadlá"</string>
@@ -1581,7 +1578,7 @@
     <string name="wireless_display_route_description" msgid="9070346425023979651">"Bezdrôtový displej"</string>
     <string name="media_route_button_content_description" msgid="591703006349356016">"Preniesť"</string>
     <string name="media_route_chooser_title" msgid="1751618554539087622">"Pripojenie k zariadeniu"</string>
-    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"Prenos obraz. do zariad."</string>
+    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"Prenos obrazovky do zariadenia"</string>
     <string name="media_route_chooser_searching" msgid="4776236202610828706">"Prebieha vyhľadávanie zariadení…"</string>
     <string name="media_route_chooser_extended_settings" msgid="87015534236701604">"Nastavenia"</string>
     <string name="media_route_controller_disconnect" msgid="8966120286374158649">"Odpojiť"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Zjednodušenie ovládania je povolené."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Zjednodušenie ovládania bolo zrušené."</string>
     <string name="user_switched" msgid="3768006783166984410">"Aktuálny používateľ je <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Prepína sa na účet <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Vlastník"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Chyba"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Správca túto zmenu zakázal"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Bola vybratá položka <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Číslo <xliff:g id="KEY">%1$s</xliff:g> bolo odstránené"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Práca – <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Ak chcete obrazovku uvoľniť, súčasne stlačte a podržte tlačidlá Späť a Nedávne."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Ak chcete obrazovku uvoľniť, stlačte a podržte tlačidlo Nedávne."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Obrazovka je pripnutá. Uvoľnenie vaša organizácia nepovoľuje."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Použiť pripnutie k obrazovke?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Pripnutím k obrazovke uzamknete displej v jednom zobrazení.\n\nRežim ukončíte súčasným klepnutím na tlačidlá Späť a Nedávne."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Pripnutím k obrazovke uzamknete displej v jednom zobrazení.\n\nRežim ukončíte stlačením a podržaním tlačidla Nedávne."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NIE, ĎAKUJEM"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"SPUSTIŤ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Číslo PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"bezpečnostný vzor"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"heslo"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Obrazovka bola pripnutá"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Obrazovka bola uvoľnená"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pred uvoľnením požiadať o číslo PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pred uvoľnením požiadať o bezpečnostný vzor"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pred uvoľnením požiadať o heslo"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Šetrič batérie znižuje výkonnosť vášho zariadenia a obmedzuje vibrácie a prenos údajov na pozadí, aby tak predĺžil výdrž batérie. E-mail, správy a ďalšie aplikácie, ktorú používajú synchronizáciu, sa nemusia aktualizovať, dokiaľ ich neotvoríte.\n\nPri nabíjaní zariadenia sa šetrič batérie automaticky vypne."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Dokým o <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> neskončí výpadok"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Na jednu minútu"</item>
+    <item quantity="other" msgid="6924190729213550991">"Na %d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Na jednu hodinu"</item>
+    <item quantity="other" msgid="5408537517529822157">"Na %d h"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Natrvalo"</string>
 </resources>
diff --git a/core/res/res/values-sl/strings.xml b/core/res/res/values-sl/strings.xml
index 462dc19..e5daa75 100644
--- a/core/res/res/values-sl/strings.xml
+++ b/core/res/res/values-sl/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Imetniku omogoča povezovanje z vmesnikom oddaljenega prikaza najvišje ravni. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"poveži s storitvijo pripomočka"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Lastniku omogoča povezovanje z vmesnikom storitve pripomočka najvišje ravni. Tega ni treba nikoli uporabiti za navadne programe."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"Povezava s storitvijo ponudnika poti"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Omogoča imetniku, da se povezuje z registriranimi ponudniki poti. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"interakcija s skrbnikom naprave"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Omogoča lastniku, da pošlje namere skrbniku naprave. Nikoli se ne uporablja za navadne programe."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"povezava s TV-vhodom"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"vklop ali izklop telefona"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Programu omogoča vklop ali izklop tabličnega računalnika."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Programu omogoča vklop ali izklop telefona."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ponastavitev časovne omejitve za zaslon"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Aplikaciji omogoča ponastavitev časovne omejitve za zaslon."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"izvajanje v preskusnem načinu delovanja"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Izvajanje kot proizvajalčev preskus na najnižjem nivoju, kar omogoča popoln dostop do strojne opreme tabličnega računalnika. Dovoljenje je na voljo, samo če se tablični računalnik izvaja v načinu proizvajalčevega preskusa."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Se izvaja kot preskus izdelovalca nizke ravni, ki dovoljuje popoln dostop do strojne opreme telefona. Na voljo le, ko se telefon izvaja v načinu preskusa izdelovalca."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Programu omogoča branje in pisanje v datotečni sistem predpomnilnika."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"opravljanje/sprejemanje klicev SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Aplikaciji omogoča opravljanje in sprejemanje klicev SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interakcija z zaslonom pri klicu"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Aplikaciji omogoča nadzor nad tem, kdaj in kako uporabnik vidi zaslon pri klicu."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interakcija z zaslonom pri klicu"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Aplikaciji omogoča nadzor nad tem, kdaj in kako uporabnik vidi zaslon pri klicu."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"uporaba telefonskih storitev"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Aplikaciji omogoča uporabo telefonskih storitev za klicanje/sprejemanje klicev."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"zagotavljanje uporabniške izkušnje med klicem"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Aplikaciji omogoča zagotavljanje uporabniške izkušnje med klicem."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"branje prejšnje uporabe omrežja"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Programu omogoča branje pretekle uporabe omrežja za določena omrežja in programe."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"upravljanje pravilnika o omrežju"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Lastniku omogoča povezovanje z vmesnikom storitve poslušalca obvestil najvišje ravni. Tega nikoli ni treba uporabiti za navadne aplikacije."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"povezovanje s storitvijo ponudnika pogojev"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Imetniku omogoča povezovanje z vmesnikom storitve ponudnika pogojev najvišje ravni. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"povezovanje s storitvijo poti predstavnosti"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Imetniku omogoča povezovanje z vmesnikom storitve poti predstavnosti najvišje ravni. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"povezava s storitvijo sanjarjenja"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Imetniku omogoča povezovanje z vmesnikom storitve sanjarjenja najvišje ravni. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"sprožitev operaterjeve aplikacije za konfiguracijo"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Skupna raba z aplikacijo %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Izberite aplikacijo za začetno stran"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Privzeta uporaba za to dejanje."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Uporaba druge aplikacije"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Izbrišite privzeti program v sistemskih nastavitvah &gt; Programi &gt; Preneseno."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Izberite dejanje"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Izberite program za napravo USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Dovoli"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Zavrni"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; želi poslati sporočilo na &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"S tem bo "<font fgcolor="#ffffb060">"morda bremenjen"</font>" vaš račun za mobilno napravo."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"S tem bo bremenjen vaš račun za mobilno napravo."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"S tem "<b>"bo morda bremenjen račun"</b>" za vašo mobilno napravo."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"S tem bo bremenjen vaš račun za mobilno napravo."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Pošlji"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Prekliči"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Zapomni si mojo izbiro"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Dotaknite se, če želite onemogočiti iskanje in odpravljanje napak prek vrat USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Sprememba tipkovnice"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Izbira tipkovnic"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fizična tipkovnica"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Pokaži način vnosa"</string>
     <string name="hardware" msgid="7517821086888990278">"Strojna oprema"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Izberite razporeditev tipkovnice"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Dotaknite se, da izberete razporeditev tipkovnice"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Aplikaciji dovoli povezovanje s storitvijo posrednikov zaupanja."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Uporaba sistema za posodobitev in obnovitev"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Aplikaciji dovoli uporabo sistema za obnovitev in posodobitev sistema."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Ustvarjanje sej projekcije predstavnosti"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Aplikaciji omogoča ustvarjanje sej projekcije predstavnosti. Te seje lahko aplikacijam omogočijo zajem vsebin na zaslonu in zvočnih vsebin. Tega ni treba nikoli uporabiti za navadne aplikacije."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Upravljanje sej projekcije predstavnosti"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Aplikaciji omogoča upravljanje sej projekcije predstavnosti. Te seje lahko aplikacijam omogočijo zajem zaslonske in zvočne vsebine. Navadne aplikacije naj tega ne bi potrebovale."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Branje sej namestitev"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Aplikaciji omogoča branje sej namestitev. Tako lahko bere podrobnosti o aktivnih namestitvah paketov."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Dvakrat se dotaknite za nadzor povečave/pomanjšave"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Zavrni"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Zahtevano je dovoljenje"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Zahtevano je dovoljenje\nza račun <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"To aplikacijo uporabljate v osebnem prostoru"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"To aplikacijo uporabljate v delovnem prostoru"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Aplikacijo uporabljate zunaj delovnega profila"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"To aplikacijo uporabljate v delovnem profilu"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Način vnosa"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinhronizacija"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Pripomočki za osebe s posebnimi potrebami"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Zmanjšanje vrednosti za uro"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Nastavi PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Nastavi AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"p."</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"d."</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Povečanje vrednosti za mesec"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Zmanjšanje vrednosti za mesec"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Povečanje vrednosti za dan"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Uredi"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Opozorilo o uporabi podatkov"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Dotaknite se za uporabo in nast."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Podatki v omrežju 2G/3G so izkl."</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Podatki v omrežju 4G so izklop."</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Prenos mob. podatkov izklopljen"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Prenos pod. prek Wi-Fi je izkl."</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Omejitev je dosežena"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Dosežena pod. omejitev za 2G/3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Dosežena pod. omejitev za 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Dosežena mobilna pod. omejitev"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Dosežena pod. omejitev za Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Prenos pod. ust. do konca cikla"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Omejit. za podat. 2G-3G presež."</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Omejitev za podat. 4G presež."</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Omej. mobil. podatkov presežena"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Ali želite sprejeti klic?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Vedno"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Samo tokrat"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ne podpira delovnega profila."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ne podpira delovnega profila"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablični računalnik"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Slušalke"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Pripomočki za ljudi s posebnimi potrebami so omogočeni."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Omogočanje pripomočkov za ljudi s posebnimi potrebami preklicano."</string>
     <string name="user_switched" msgid="3768006783166984410">"Trenutni uporabnik <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Preklop na uporabnika <xliff:g id="NAME">%1$s</xliff:g> …"</string>
     <string name="owner_name" msgid="2716755460376028154">"Lastnik"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Napaka"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Skrbnik ne dovoli te spremembe"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Izbrano: <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Številka <xliff:g id="KEY">%1$s</xliff:g> je izbrisana"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> za delo"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Če želite odpeti ta zaslon, se hkrati dotaknite in pridržite »Nazaj« in »Nedavni«."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Če želite odpeti ta zaslon, se dotaknite in pridržite »Nedavni«."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Zaslon je pripet. Vaša organizacija ne dovoli odpenjanja."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Želite uporabljati pripenjanje zaslona?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Pripenjanje zaslona zaklene zaslon v en pogled.\n\nČe ga želite zapustiti, se hkrati dotaknite ter pridržite »Nazaj« in »Nedavni«."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Pripenjanje zaslona zaklene zaslon v en pogled.\n\nČe ga želite zapustiti, se dotaknite in pridržite »Nedavni«."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NE, HVALA"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ZAŽENI"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"vzorec za odklepanje"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"geslo"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Zaslon je pripet"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Zaslon je odpet"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Pred odpenjanjem vprašaj za PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Pred odpenjanjem vprašaj za vzorec za odklepanje"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Pred odpenjanjem vprašaj za geslo"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Varčevanje z energijo akumulatorja poveča čas delovanja akumulatorja, tako da zmanjša zmogljivost delovanja naprave in omeji vibriranje ter prenos večine podatkov v ozadju. Aplikacije za e-pošto, sporočanje in drugo, ki uporabljajo sinhroniziranje, se morda ne posodabljajo, razen če jih odprete.\n\nVarčevanje z energijo se samodejno izklopi med polnjenjem akumulatorja naprave."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Do konca prekinitve delovanja ob <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Za eno minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Za %d min"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Za eno uro"</item>
+    <item quantity="other" msgid="5408537517529822157">"Za %d h"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Za nedoločen čas"</string>
 </resources>
diff --git a/core/res/res/values-sr/strings.xml b/core/res/res/values-sr/strings.xml
index c11e1ff..f0edc61 100644
--- a/core/res/res/values-sr/strings.xml
+++ b/core/res/res/values-sr/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Дозвољава власнику да се повеже са интерфејсом удаљеног екрана највишег нивоа. Уобичајене апликације никада не би требало да је користе."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"обавезивање на услугу виџета"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Дозвољава власнику да се обавеже на интерфејс услуге виџета највишег нивоа. Уобичајене апликације никада не би требало да је користе."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"повежи са услугом добављача путања"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Дозвољава власнику да се повеже са добављачима путања. Никада не би требало да буде потребно за обичне апликације."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"интеракција са администратором уређаја"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Омогућава да власник шаље своје намере администратору уређаја. Уобичајене апликације никада не би требало да је користе."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"повезивање са ТВ улазом"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"укључивање или искључивање телефона"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Дозвољава апликацији да укључује или искључује таблет."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Дозвољава апликацији да укључује и искључује телефон."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ресетовање временског ограничења за екран"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Дозвољава апликацији да ресетује временско ограничење за екран."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"покретање у режиму фабричког тестирања"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Покреће се као тест произвођача ниског нивоа, омогућавајући комплетан приступ хардверу таблета. Доступно је само када је таблет покренут у пробном режиму произвођача."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Покретање теста ниског нивоа који спроводи произвођач, које омогућава потпуни приступ хардверу телефона. Доступно је само када телефон покренут у режиму тестирања које спроводи произвођач."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Дозвољава апликацији да чита систем датотека кеша и уписује податке у њега."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"упућивање/пријем SIP позива"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Омогућава апликацији да упућује и прима SIP позиве."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"интеракција са екраном током позива"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Дозвољава апликацији да контролише када и како се кориснику приказује екран приликом позива."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"комуницирај са екраном током позива"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Дозвољава апликацији да контролише када и како се кориснику приказује екран током позива."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"да ступа у интеракцију са телефонским услугама"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Дозвољава интеракцију апликације са телефонским услугама ради упућивања/примања позива."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"пружај кориснички доживљај током позива"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Дозвољава апликацији да пружа кориснички доживљај током позива."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"чита историју коришћења мреже"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Дозвољава апликацији да чита историју коришћења мреже за посебне мреже и апликације."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"управљање смерницама за мрежу"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Дозвољава власнику да се повеже са интерфејсом услуге монитора обавештења највишег нивоа. Уобичајене апликације никада не би требало да је користе."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"повежи са услугом добављача услова"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Дозвољава власнику да се повеже са интерфејсом највишег нивоа услуге добављача услова. Не би требало никада да буде потребно за уобичајене апликације."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"повезивање са услугом усмеравања медија"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Дозвољава власнику да се повеже са интерфејсом највишег нивоа услуге усмеравања медија. Никада не би требало да буде потребно за уобичајене апликације."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"повезивање са услугом сањарења"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Дозвољава власнику да се повеже са интерфејсом услуге сањарења највишег нивоа. Уобичајене апликације никада не би требало да је користе."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"позивање апликације са конфигурацијом коју одређује оператер"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Делите помоћу апликације %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Изаберите апликацију за почетну страницу"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Подразумевано користи за ову радњу."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Користите другу апликацију"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Обришите подразумевано подешавање у менију Подешавања система &gt; Апликације &gt; Преузето."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Изаберите радњу"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Избор апликације за USB уређај"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Дозволи"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Одбиј"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; жели да пошаље поруку на адресу &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Ово "<font fgcolor="#ffffb060">"може да изазове трошкове"</font>" на налогу за мобилни уређај."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ово ће изазвати трошкове на налогу за мобилни уређај."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ово "<b>"може да проузрокује трошкове"</b>" на рачуну за мобилни уређај."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ово ће проузроковати трошкове на рачуну за мобилни уређај."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Пошаљи"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Откажи"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Запамти мој избор"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Додирните да бисте онемогућили отклањање грешака са USB-а."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Промените тастатуру"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Изаберите тастатуре"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Физичка тастатура"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Приказивање метода уноса"</string>
     <string name="hardware" msgid="7517821086888990278">"Хардвер"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Избор распореда тастатуре"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Додирните да бисте изабрали распоред тастатуре."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Дозвољава апликацији да се веже за услугу Trust agents."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Интеракција са системом за ажурирање и опоравак"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Дозвољава апликацији да ступа у интеракцију са системом за опоравак и ажурирањима система."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Прави сесије пројекција медија"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Омогућава апликацији да прави сесије пројекција медија. Ове сесије могу да омогуће апликацијама да снимају садржај на екрану или аудио садржај. Никада не би требало да буде потребно за стандардне апликације."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Управљај сесијама пројекције медија"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Дозвољава апликацији да управља сесијама пројекције медија. Те сесије могу да пруже апликацијама могућност да снимају садржај екрана и аудио-садржај. Никада не би требало да буде потребно за обичне апликације."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Читај сесије инсталирања"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Дозвољава апликацији да чита сесије инсталирања. То јој дозвољава да види детаље о активним инсталацијама пакета."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Додирните двапут да бисте контролисали зум"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Одбиј"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Затражена је дозвола"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Затражена је дозвола\nза налог <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Користите ову апликацију у личном простору"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Користите ову апликацију у простору за рад"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Користите ову апликацију изван пословног профила"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Користите ову апликацију на пословном профилу"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Метод уноса"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синхронизација"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Приступачност"</string>
@@ -1448,7 +1447,7 @@
     <string name="submit" msgid="1602335572089911941">"Пошаљи"</string>
     <string name="car_mode_disable_notification_title" msgid="3164768212003864316">"Режим рада у аутомобилу је омогућен"</string>
     <string name="car_mode_disable_notification_message" msgid="8035230537563503262">"Додирните да бисте изашли из режима рада у аутомобилу."</string>
-    <string name="tethered_notification_title" msgid="3146694234398202601">"Активно повезивање са Интернетом преко мобилног уређаја или врућа тачка"</string>
+    <string name="tethered_notification_title" msgid="3146694234398202601">"Активно повезивање са интернетом преко мобилног уређаја или врућа тачка"</string>
     <string name="tethered_notification_message" msgid="6857031760103062982">"Додирните да бисте подесили."</string>
     <string name="back_button_label" msgid="2300470004503343439">"Назад"</string>
     <string name="next_button_label" msgid="1080555104677992408">"Next"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Смањивање сати"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Подеси по подне"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Подеси пре подне"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Повећавање месеца"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Смањивање месеца"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Повећавање дана"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Измени"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Упозорење о потрошњи података"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Додирните за преглед кор. и под."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G–3G подаци су искључени"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G подаци су искључени"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Мобилни подаци су искључени"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi подаци су искључени"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Ограничење је достигнуто"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Нема више 2G-3G података"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Нема више 4G података"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Нема више подат. за мобил. уређ."</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Нема више Wi-Fi података"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Нема података до краја циклуса"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Прекорачен пренос 2G-3G података"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Прекорачење преноса 4G података"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Ограничење мобилних података је прекорачено"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Желите ли да прихватите позив?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Увек"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Само једном"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s не подржава профил за посао."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s не подржава пословни профил"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Таблет"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Слушалице"</string>
@@ -1586,7 +1583,7 @@
     <string name="media_route_chooser_extended_settings" msgid="87015534236701604">"Подешавања"</string>
     <string name="media_route_controller_disconnect" msgid="8966120286374158649">"Прекини везу"</string>
     <string name="media_route_status_scanning" msgid="7279908761758293783">"Скенирање..."</string>
-    <string name="media_route_status_connecting" msgid="6422571716007825440">"Повезивање..."</string>
+    <string name="media_route_status_connecting" msgid="6422571716007825440">"Повезује се..."</string>
     <string name="media_route_status_available" msgid="6983258067194649391">"Доступна"</string>
     <string name="media_route_status_not_available" msgid="6739899962681886401">"Нису доступне"</string>
     <string name="media_route_status_in_use" msgid="4533786031090198063">"У употреби"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Приступачност је омогућена."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Приступачност је отказана."</string>
     <string name="user_switched" msgid="3768006783166984410">"Актуелни корисник <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Пребацивање на <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Власник"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Грешка"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Администратор није дозволио ову промену"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Изабрали сте <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Избрисали сте <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> на послу"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Да бисте откачили овај екран, истовремено додирните и задржите Назад и Недавно."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Да бисте откачили овај екран, додирните и задржите Недавно."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Екран је закачен. Ваша организација не дозвољава откачињање."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Желите ли да користите качење екрана?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Качење екрана закључава екран у једном приказу.\n\nДа бисте изашли, истовремено додирните и задржите Назад и Недавно."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Качење екрана закључава екран у једном приказу.\n\nДа бисте изашли, додирните и задржите Недавно."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"НЕ, ХВАЛА"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ПОКРЕНИ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"шаблон за откључавање"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"лозинка"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Екран је закачен"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Екран је откачен"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Тражи PIN пре откачињања"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Тражи шаблон за откључавање пре откачињања"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Тражи лозинку пре откачињања"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Да би смањила потрошњу батерије, Штедња батерије снижава перформансе уређаја, ограничава вибрацију и већину позадинских података. Имејл, размена порука и друге апликације које се ослањају на синхронизацију се можда неће ажурирати ако их не отворите.\n\nШтедња батерије се аутоматски искључује када се уређај пуни."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Док се прекид рада не заврши у <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Један минут"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d мин"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Један сат"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d с"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Бесконачно"</string>
 </resources>
diff --git a/core/res/res/values-sv/strings.xml b/core/res/res/values-sv/strings.xml
index 9115c06..ce3b5ec 100644
--- a/core/res/res/values-sv/strings.xml
+++ b/core/res/res/values-sv/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Innehavaren tillåts att binda till den översta nivåns gränssnitt för en fjärrskärm. Ska inte behövas för vanliga appar."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bind till en widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Innehavaren tillåts att binda till den översta nivåns gränssnitt för en widget. Ska inte behövas för vanliga appar."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bind till en ruttleverantörstjänst"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Tillåter att innehavaren binds till en registrerad ruttleverantör. Detta ska inte behövas för vanliga appar."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"arbeta med en enhetsadministratör"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Tillåter att innehavaren skickar avsikter till en enhetsadministratör. Vanliga appar behöver aldrig göra detta."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"binda till en tv-insignal"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"sätta på eller stänga av telefonen"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Tillåter att appen slår på eller stänger av surfplattan."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Tillåter att appen slår på eller stänger av mobilen."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"återställa tidsgräns för skärm"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Gör att appen kan återställa tidsgränsen för skärmen."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"kör i fabrikstestläge"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Köra som ett testläge för tillverkaren på låg nivå. På så sätt får du fullständig åtkomst till surfplattans maskinvara. Är endast tillgänglig när surfplattan körs i tillverkarens testläge."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Köra som ett testläge för tillverkaren på låg nivå. På så sätt får du fullständig åtkomst till telefonens maskinvara. Är endast tillgänglig när telefonen körs i tillverkarens testläge."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Tillåter att appen läser och skriver till cachefilsystemet."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"gör/ta emot SIP-anrop"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Tillåter att appen gör och tar emot SIP-anrop."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"interagera med skärmen för inkommande samtal"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Låter appen kontrollera hur och när användaren ser skärmen för inkommande samtal."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"interagera med skärmen för inkommande samtal"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Tillåter att appen kontrollerar hur och när användaren ser skärmen för inkommande samtal."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"samverka med telefonitjänster"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Tillåter appen att använda telefonitjänster för att ringa/ta emot samtal."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"förbättra användarupplevelsen för inkommande samtal."</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Tillåter att appen förbättrar användarupplevelsen för inkommande samtal."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"läsa historisk nätverksanvändning"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Tillåter att appen läser den historiska nätverksanvändningen för specifika nätverk och appar."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"hantera nätverkspolicy"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Innehavaren tillåts att binda till den översta nivåns gränssnitt för en meddelandelyssnare. Ska inte behövas för vanliga appar."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bind till en leverantörstjänst"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Innehavaren tillåts att binda till den översta nivåns gränssnitt för en leverantörstjänst. Ska inte behövas för vanliga appar."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"binda till medieruttjänst"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Tillåter att innehavaren kan binda till den översta nivåns gränssnitt för en medieruttjänst. Detta ska inte behövas för vanliga appar."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"binda till en drömtjänst"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Innehavaren tillåts att binda till den översta nivåns gränssnitt för en drömtjänst. Ska inte behövas för vanliga appar."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"anropa konfigurationsappen från operatören"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Dela med %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Välj en app på startskärmen"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Använd som standard för denna åtgärd."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Använd en annan app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Rensa standardinställningar i Systeminställningar &gt; Appar &gt; Hämtat."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Välj en åtgärd"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Välja en app för USB-enheten"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Tillåt"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Neka"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; vill skicka ett meddelande till &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Detta "<font fgcolor="#ffffb060">"kan medföra debiteringar"</font>" på ditt mobilkonto."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Ditt mobilkonto kommer att debiteras."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Detta "<b>"kan medföra debiteringar"</b>" på ditt mobilkonto."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Ditt mobilkonto kommer att debiteras."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Skickat"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Avbryt"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Kom ihåg mitt val"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Tryck om du vill inaktivera USB-felsökning."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Byt tangentbord"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Välj tangentbord"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fysiskt tangentbord"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Visa inmatningsmetod"</string>
     <string name="hardware" msgid="7517821086888990278">"Maskinvara"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Välj en tangentbordslayout"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Välj en tangentbordslayout genom att trycka."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Tillåter att en app binds vid en tjänst från en betrodd agent."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Interagera med uppdaterings- och återställningssystemet"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Tillåter att en app interagerar med systemuppdateringar och återställningssystemet."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Skapa sessioner för medieprojektioner"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Tillåter att appen skapar sessioner för mediaprojektioner. Sessionerna kan ge appar möjlighet att ta bilder av det som visas på skärmen eller spela in ljudinnehåll. Detta ska inte behövas för vanliga appar."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Hantera medieprojektionssessioner"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Tillåter att en app hanterar sessioner för medieprojektion. Dessa sessioner kan ge appar möjlighet att spela in skärm- och ljudinnehåll. Detta ska aldrig behövas för vanliga appar."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Läsa installationssessioner"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Tillåt appen att läsa installationssessioner. Det ger den tillgång till uppgifter om aktiva paketinstallationer."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Tryck två gånger för zoomkontroll"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Neka"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Begärd behörighet"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Begärd behörighet\nför kontot <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Du använder den här appen i ditt personliga utrymme"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Du använder den här appen i ditt arbetsutrymme"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Du använder den här appen i din arbetsprofil"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Du använder den här appen i din profil"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Indatametod"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Synkronisera"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Tillgänglighet"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Minska timmar"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Ange em"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Ange fm"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"em"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"fm"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Öka månader"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Minska månader"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Öka dagar"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Redigera"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Varning angående dataanvändning"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Visa användning och inställning"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-/3G-data har inaktiverats"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G-data har inaktiverats"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobildata har inaktiverats"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi-data har inaktiverats"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Gränsen har uppnåtts"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Datagränsen för 2G-3G har uppnåtts"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Datagränsen för 4G har uppnåtts"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Datagränsen för mobilen har uppnåtts"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Datagränsen för Wi-Fi har uppnåtts"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data är pausade under resten av cykeln"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Gränsen för data via 2G-3G har överskridits"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Gränsen för data via 4G har överskridits"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mobildatagränsen är överskriden"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Vill du ta emot samtal?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Alltid"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Bara en gång"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s har inte stöd för arbetsprofil."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s har inte stöd för arbetsprofil"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Surfplatta"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Mobil"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Hörlurar"</string>
@@ -1581,7 +1578,7 @@
     <string name="wireless_display_route_description" msgid="9070346425023979651">"Trådlös skärm"</string>
     <string name="media_route_button_content_description" msgid="591703006349356016">"Casta"</string>
     <string name="media_route_chooser_title" msgid="1751618554539087622">"Anslut till enhet"</string>
-    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"Överför skärmen till enheten"</string>
+    <string name="media_route_chooser_title_for_remote_display" msgid="3395541745872017583">"Casta skärmen till enheten"</string>
     <string name="media_route_chooser_searching" msgid="4776236202610828706">"Söker efter enheter ..."</string>
     <string name="media_route_chooser_extended_settings" msgid="87015534236701604">"Inställningar"</string>
     <string name="media_route_controller_disconnect" msgid="8966120286374158649">"Koppla från"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Tillgänglighetsläget har aktiverats."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Byte till tillgänglighetsläge avbrutet."</string>
     <string name="user_switched" msgid="3768006783166984410">"Nuvarande användare: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Byter till <xliff:g id="NAME">%1$s</xliff:g> …"</string>
     <string name="owner_name" msgid="2716755460376028154">"Ägare"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Fel"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Administratören tillåter inte den här ändringen"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> har markerats"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> har tagits bort"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> för arbetet"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Om du inte vill att skärmen ska vara fäst håller du ned Föregående och Senaste samtidigt."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Håll ned Senaste om du inte vill att skärmen ska vara fäst."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skärmen är fäst. Din organisation tillåter inte att du avslutar läget."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Fäst skärmen?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Om skärmen fästs låses bilden.\n\nAvsluta läget genom att hålla ned Föregående och Senaste samtidigt."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Om skärmen fästs låses bilden.\n\nAnsluta läget genom att hålla ned Senaste."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"NEJ TACK"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"STARTA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Pinkod"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"grafiskt lösenord"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"lösenord"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skärmen är fäst"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skärmen är inte längre fäst"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Be om pinkod innan skärmen slutar fästas"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Be om upplåsningsmönster innan skärmen slutar fästas"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Be om lösenord innan skärmen slutar fästas"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"I batterisparläget reduceras enhetens prestanda så att batteriet ska räcka längre, och vibration samt den mesta användningen av bakgrundsdata begränsas. Det kan hända att appar för e-post, sms och annat som kräver synkronisering inte uppdateras förrän du öppnar dem.\n\nBatterisparläget inaktiveras automatiskt när enheten laddas."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Tills avbrottstiden är slut <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"I en minut"</item>
+    <item quantity="other" msgid="6924190729213550991">"I %d minuter"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"I en timme"</item>
+    <item quantity="other" msgid="5408537517529822157">"I %d timmar"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"För alltid"</string>
 </resources>
diff --git a/core/res/res/values-sw/strings.xml b/core/res/res/values-sw/strings.xml
index 177730c..d2cee98 100644
--- a/core/res/res/values-sw/strings.xml
+++ b/core/res/res/values-sw/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Huruhusu mtumiaji kujifungia kiolesura cha kiwango cha juu cha mwonekano wa mbali. Haipaswi kuhitajika kwa programu za kawaida."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"funga kwenye huduma ya widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Inaruhusu mmiliki kushurutisha kusano ya kiwango cha juu ya huduma ya wijeti. Haipaswi kuhitajika kwa programu za kawaida."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bandika kwenye huduma ya mtoa huduma za njia"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Huruhusu mmiliki kubandika kwenye watoa huduma za njia waliosajiliwa. Haipaswi kuhitajika kwa programu za kawaida."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"jiunge na msimamizi wa kifaa"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Humruhusu mmiliki kutuma kidhibiti cha kifaa malengo. Programu za kawaida hazikihitaji."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bandika kwenye zana za data ya runinga"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"washa au zima simu"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Inaruhusu programu kuwasha au kuzima kompyuta kibao."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Inaruhusu programu kuwasha au kuzima simu."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"weka upya onyesho la muda umekwisha"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Huruhusu programu kuweka upya onyesho la muda umekwisha."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"endesha katika hali ya jaribio ya kiwanda"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Endesha kama jaribio la mtengenezaji la kiwango cha chini, kwa hivyo kuruhusu ufikiaji kamili wa maunzi ya kompyuta ndogo. Inapatikana tu wakati kompyuta ndogo inaendeshwa katika hali ya jaribio la mtengenezaji."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Endesha kama jaribio la kiwango cha chini cha mtengenezaji, kwa hivyo kuruhusu ufikiaji kamili wa maunzi ya simu. Inapatikana tu wakati simu inaendeshwa katika gumzo ya jaribio ya mtengenezaji."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Huruhusu programu kusoma na kuandika mfumo wa faili wa akiba."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"piga/pokea simu za SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ruhusu programu ipige na kupokea simu za SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"tumikisha skrini ya simu inayoendelea"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Huruhusu programu kudhibiti wakati na jinsi mtumiaji anaona skrini anapopigiwa simu."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"wezesha mwingiliano na skrini ya simu inayoingia"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Huruhusu programu kudhibiti wakati na jinsi mtumiaji anavyoona skrini ya simu inayoingia."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"shirikiana na huduma za simu"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Huruhusu programu kushirikiana na huduma za simu ili kupiga au kupokea simu."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"wasilisha hali ya skrini ya simu inayoingia"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Huruhusu programu kuwasilisha maboresho ya matumizi ya skrini ya simu inayoingia."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"soma matumizi ya historia ya mtandao"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Inaruhusu programu kusoma historia ya matumizi ya mtandao kwa mitandao maalum na programu."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"dhibiti sera ya mtandao"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Inaruhusu kishikilizi kuunganishwa kwenye kusano cha kiwango cha juu cha huduma ya kisikilizi cha arifa. Haipaswi kuhitajika tena kwa programu za kawaida."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bandika kwenye huduma ya mtoa masharti"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Humruhusu mmiliki kubandika kwenye kiolesura cha kiwango cha juu cha huduma ya mtoa masharti. Isihitajike kamwe kwa pogramu za kawaida."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bandika kwenye huduma ya njia za sauti, picha na video."</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Humruhusu mmiliki kubandika kwenye kiolesura cha ngazi ya juu cha huduma ya njia za sauti, picha na video. Haipaswi kuhitajika kwa programu za kawaida."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"shurutisha kwa huduma murua"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Huruhusu mmiliki kushurutisha kwenye kiolesura cha kiwango cha juu cha huduma murua. Haipaswi kuhitajika kwa programu za kawaida."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"omba programu ya usakinishaji inayotolewa na mtoa huduma."</string>
@@ -912,8 +910,8 @@
     <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"Hakuna SIM kadi"</string>
     <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"Hakuna SIM kadi katika kompyuta ndogo."</string>
     <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"Hakuna SIM kadi kwenye simu."</string>
-    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"Ingiza SIM kadi."</string>
-    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"SIM kadi haipatikani au haisomeki. Tafadhali ingiza SIM kadi."</string>
+    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"Weka SIM kadi."</string>
+    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"SIM kadi haipatikani au haisomeki. Tafadhali weka SIM kadi."</string>
     <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"SIM kadi isiyotumika."</string>
     <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"SIM kadi yako imelemezwa kabisa.\n Wasiliana na mtoa huduma wako wa pasi waya ili upate SIM kadi nyingine."</string>
     <string name="lockscreen_transport_prev_description" msgid="6300840251218161534">"Wimbo uliotangulia"</string>
@@ -1090,7 +1088,7 @@
   </plurals>
   <plurals name="in_num_minutes">
     <item quantity="one" msgid="8793095251325200395">"kati ya dakika  1"</item>
-    <item quantity="other" msgid="3330713936399448749">"katika dakika <xliff:g id="COUNT">%d</xliff:g>"</item>
+    <item quantity="other" msgid="3330713936399448749">"baada ya dakika <xliff:g id="COUNT">%d</xliff:g>"</item>
   </plurals>
   <plurals name="in_num_hours">
     <item quantity="one" msgid="7164353342477769999">"kati ya saa 1"</item>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Shiriki na %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Chagua programu ya nyumbani"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Tumia kama chaguo-msingi la kitendo hiki."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Tumia programu tofauti"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Futa chaguo-msingi katika mipangilio ya Mfumo &gt; Apps &gt; iliyopakuliwa."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Chagua kitendo"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Chagua programu ya kifaa cha USB"</string>
@@ -1214,9 +1213,9 @@
     <string name="aerr_process" msgid="4507058997035697579">"Kwa bahati mbaya, mchakato wa <xliff:g id="PROCESS">%1$s</xliff:g> umekoma."</string>
     <string name="anr_title" msgid="4351948481459135709"></string>
     <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g> haifanyi kazi.\n\nUnataka kuifunga?"</string>
-    <string name="anr_activity_process" msgid="5776209883299089767">"Shughuli <xliff:g id="ACTIVITY">%1$s</xliff:g> haijibu. \n\n Unataka kuifunga?"</string>
-    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g> haijibu. Unataka kufunga?"</string>
-    <string name="anr_process" msgid="6513209874880517125">"Mchakato <xliff:g id="PROCESS">%1$s</xliff:g> haijibu. \n\n Unataka kuifunga?"</string>
+    <string name="anr_activity_process" msgid="5776209883299089767">"Shughuli ya <xliff:g id="ACTIVITY">%1$s</xliff:g> haifanyi kazi.\n\nJe, ungependa kuifunga?"</string>
+    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g> haifanyi kazi. Je, ungependa kuifunga?"</string>
+    <string name="anr_process" msgid="6513209874880517125">"Mchakato wa <xliff:g id="PROCESS">%1$s</xliff:g> haufanyi kazi. \n\nJe, ungependa kuifunga?"</string>
     <string name="force_close" msgid="8346072094521265605">"Sawa"</string>
     <string name="report" msgid="4060218260984795706">"Ripoti"</string>
     <string name="wait" msgid="7147118217226317732">"Subiri"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Ruhusu"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Kataza"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ingependa kutuma ujumbe kwa &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Hii "<font fgcolor="#ffffb060">"huenda ikasababisha gharama"</font>" kwenye akaunti yako ya simu."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Hii itasababisha gharama kwenye akaunti yako ya simu."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Hii "<b>"huenda ikasababisha ulipe gharama"</b>" kwenye akaunti ya kifaa chako cha mkononi."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Hii itafanya ulipe gharama kwenye akaunti ya kifaa chako cha mkononi."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Tuma"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Ghairi"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Kumbuka chaguo yangu"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Gusa ili uzime utatuaji wa USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Badilisha kibodi"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Chagua kibodi"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Kibodi halisi"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Onyesha mbinu ya kuingiza"</string>
     <string name="hardware" msgid="7517821086888990278">"Maunzi"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Teua mpangilio wa kibodi"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Gusa ili kuchagua mpangilio wa kibodi."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Huruhusu programu kujiambatisha kwenye huduma ya kutathmini hali ya kuaminika."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Ingiliana na sasisho na mfumo wa kurejesha"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Huruhusu programu kuingiliana na mfumo wa kurejesha na sasisho la mfumo."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Unda vipindi vya kuonyesha maudhui"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Huruhusu programu kuunda vipindi vya kuonyesha maudhui. Vipindi hivi vinaweza kuipa programu uwezo wa kupiga picha maudhui ya onyesho na sauti. Haipaswi kuhitajika kamwe kwa programu za kawaida."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Simamia vipindi vya kuonyesha maudhui."</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Huruhusu programu kusimamia vipindi vya kuonyesha maudhui. Vipindi hivi vinaweza kuipa programu uwezo wa kupiga picha maudhui ya onyesho na sauti. Haipaswi kuhitajika kwa programu za kawaida."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Soma vipindi vya kusanikisha"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Huruhusu programu kusoma vipindi vya kusanikisha. Hii huiruhusu kuona maelezo kuhusu usanikishaji wa programu unaoendelea."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Gusa mara mbili kwa udhibiti cha kuza"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Kataza"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Idhini imeitishwa"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Idhini imeombwa\nya akaunti<xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Unatumia programu hii kwenye nafasi yako ya binafsi"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Unatumia programu hii kwenye nafasi yako ya kufanyia kazi"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Unatumia programu hii nje ya wasifu wako wa kazini"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Unatumia programu hii kwenye wasifu wako wa kazini"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Mbinu ya uingizaji"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sawazisha"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Ufikiaji"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Punguza saa"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Seti PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Seti AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Ongeza mwezi"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Punguza mwezi"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Ongeza siku"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Badilisha"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Onyo la matumizi ya data"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Gusa ili kuangalia matumizi na mipangilio."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Data ya 2G-3G imezimwa"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Data ya 4G imezimwa"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Data ya simu za mkononi imezimwa"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Data ya Wi-Fi imezimwa"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Kikomo kimefikiwa"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Kikomo data ya 2G-3G kimefikiwa"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Kikomo cha data ya 4G kimefikiwa"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Kikomo data ya simu kimefikiwa"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Kikomo data ya Wi-Fi kimefikiwa"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Data imesitishwa kwa mzunguko uliosalia"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Kikomo cha data ya 2G-3G kimezidishwa"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Kikomo cha data cha 4G kimezidishwa"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Umezidi kikomo cha data ya simu"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Kubali simu?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Kila mara"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Mara moja tu"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s hakiwezi kutumika na wasifu wa kazi."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s haitumii wasifu wa kazini"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Kompyuta kibao"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Simu"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Vipokeasauti"</string>
@@ -1609,7 +1606,7 @@
     <string name="kg_pattern_instructions" msgid="398978611683075868">"Chora ruwaza yako"</string>
     <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ingiza PIN ya SIM"</string>
     <string name="kg_pin_instructions" msgid="2377242233495111557">"Ingiza PIN"</string>
-    <string name="kg_password_instructions" msgid="5753646556186936819">"Ingiza Nenosiri"</string>
+    <string name="kg_password_instructions" msgid="5753646556186936819">"Weka Nenosiri"</string>
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM sasa imelemazwa. Ingiza msimbo wa PUK ili kuendelea. Wasiliana na mtoa huduma kwa maelezo."</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"Ingiza msimbo wa PIN unaopendelewa"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"Thibitisha msimbo wa PIN unaopendelewa"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Ufikivu umewezeshwa."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Ufikivu umeghairiwa."</string>
     <string name="user_switched" msgid="3768006783166984410">"Mtumiaji wa sasa <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Inabadili kwenda <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Mmiliki"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Hitilafu"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Mabadiliko haya hayaruhusiwi na msimamizi wako"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> kimechaguliwa"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> kimefutwa"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Ya kazini <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Ili ubandue skrini hii, gusa na ushikilie Nyuma na Ya hivi majuzi kwa wakati mmoja."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Ili ubandue skrini hii, gusa na ushikilie Ya hivi karibuni."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Skrini imebandikwa. Ubanduaji hauruhusiwi na shirika lako."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Ungependa kutumia ubandikaji skrini?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ubandikaji skrini hufunga skrini kwenye onyesho moja.\n\nIli uondoe, gusa na ushikilie Nyuma na Ya hivi majuzi kwa wakati mmoja."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ubandikaji skrini hufunga skrini kwenye onyesho moja.\n\nIli uondoe, gusa na ushikilie Ya hivi majuzi."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"HAPANA, ASANTE"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ANZA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"mchoro wa kufungua"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"nenosiri"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Skrini imebandikwa"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Skrini imebanduliwa"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Omba PIN kabla hujabandua"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Omba mchoro wa kufungua kabla hujabandua"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Omba nenosiri kabla hujabandua"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Ili kusaidia kuokoa muda wa matumizi wa betri, kiokoa betri hupunguza utendaji wa kifaa chako na kuzuia kutetema na data nyingi ya chinichini. Barua pepe, kutuma ujumbe na programu zingine zinazotegemea usawazishaji huenda hazitasasisha usipozifungua.\n\nKiokoa betri hujizima kiotomatiki kifaa chako kikianza kuchajiwa."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Hadi <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> wakati wa kutotenda kazi kwa kifaa chako unapoisha"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Kwa dakika moja"</item>
+    <item quantity="other" msgid="6924190729213550991">"Kwa dakika %d"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Kwa saa moja"</item>
+    <item quantity="other" msgid="5408537517529822157">"Kwa saa %d"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Bila kikomo"</string>
 </resources>
diff --git a/core/res/res/values-sw600dp/dimens.xml b/core/res/res/values-sw600dp/dimens.xml
index 3180e58..c0d9995 100644
--- a/core/res/res/values-sw600dp/dimens.xml
+++ b/core/res/res/values-sw600dp/dimens.xml
@@ -19,9 +19,9 @@
 -->
 <resources>
     <!-- The width that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_width">512dp</dimen>
+    <dimen name="thumbnail_width">360dp</dimen>
     <!-- The height that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_height">512dp</dimen>
+    <dimen name="thumbnail_height">360dp</dimen>
     <!-- The maximum number of action buttons that should be permitted within
          an action bar/action mode. This will be used to determine how many
          showAsAction="ifRoom" items can fit. "always" items can override this. -->
diff --git a/core/res/res/values-sw600dp/dimens_material.xml b/core/res/res/values-sw600dp/dimens_material.xml
new file mode 100644
index 0000000..e0aac38
--- /dev/null
+++ b/core/res/res/values-sw600dp/dimens_material.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+<resources>
+
+    <!-- Use the default title sizes on tablets. -->
+    <dimen name="text_size_title_material_toolbar">@dimen/text_size_title_material</dimen>
+    <!-- Use the default subtitle sizes on tablets. -->
+    <dimen name="text_size_subtitle_material_toolbar">@dimen/text_size_subhead_material</dimen>
+    <!-- Default height of an action bar. -->
+    <dimen name="action_bar_default_height_material">64dp</dimen>
+    <!-- Default padding of an action bar. -->
+    <dimen name="action_bar_default_padding_material">4dp</dimen>
+
+</resources>
diff --git a/core/res/res/values-sw720dp/dimens.xml b/core/res/res/values-sw720dp/dimens.xml
index 21235ec..2317d1f 100644
--- a/core/res/res/values-sw720dp/dimens.xml
+++ b/core/res/res/values-sw720dp/dimens.xml
@@ -35,9 +35,9 @@
     <item type="dimen" name="dialog_fixed_height_minor">90%</item>
 
     <!-- The width that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_width">640dp</dimen>
+    <dimen name="thumbnail_width">420dp</dimen>
     <!-- The height that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_height">640dp</dimen>
+    <dimen name="thumbnail_height">420dp</dimen>
 
     <!-- Preference activity, vertical padding for the header list -->
     <dimen name="preference_screen_header_vertical_padding">32dp</dimen>
diff --git a/core/res/res/values-sw720dp/styles.xml b/core/res/res/values-sw720dp/styles.xml
index fee1c24f..94ec0a6 100644
--- a/core/res/res/values-sw720dp/styles.xml
+++ b/core/res/res/values-sw720dp/styles.xml
@@ -16,10 +16,9 @@
 
 <resources>
     <style name="PreferencePanel">
-        <item name="android:layout_marginStart">@dimen/preference_screen_side_margin</item>
-        <item name="android:layout_marginEnd">@dimen/preference_screen_side_margin</item>
-        <item name="android:layout_marginTop">@dimen/preference_screen_top_margin</item>
-        <item name="android:layout_marginBottom">@dimen/preference_screen_bottom_margin</item>
-        <item name="android:background">?attr/detailsElementBackground</item>
+        <item name="layout_marginStart">@dimen/preference_screen_side_margin</item>
+        <item name="layout_marginEnd">@dimen/preference_screen_side_margin</item>
+        <item name="layout_marginTop">@dimen/preference_screen_top_margin</item>
+        <item name="layout_marginBottom">@dimen/preference_screen_bottom_margin</item>
     </style>
 </resources>
diff --git a/core/res/res/values-ta-rIN/strings.xml b/core/res/res/values-ta-rIN/strings.xml
index a72e813..600e173 100644
--- a/core/res/res/values-ta-rIN/strings.xml
+++ b/core/res/res/values-ta-rIN/strings.xml
@@ -54,17 +54,17 @@
     <string name="serviceErased" msgid="1288584695297200972">"அழித்தல் வெற்றியடைந்தது."</string>
     <string name="passwordIncorrect" msgid="7612208839450128715">"தவறான கடவுச்சொல்."</string>
     <string name="mmiComplete" msgid="8232527495411698359">"MMI நிறைவடைந்தது."</string>
-    <string name="badPin" msgid="9015277645546710014">"உள்ளிட்ட பழைய PIN தவறானது."</string>
+    <string name="badPin" msgid="9015277645546710014">"உள்ளிட்ட பழைய பின் தவறானது."</string>
     <string name="badPuk" msgid="5487257647081132201">"உள்ளிட்ட PUK2 தவறானது."</string>
     <string name="mismatchPin" msgid="609379054496863419">"உள்ளிட்ட PINகள் பொருந்தவில்லை."</string>
-    <string name="invalidPin" msgid="3850018445187475377">"4 இலிருந்து 8 எண்கள் வரையுள்ள PIN ஐத் தட்டச்சு செய்யவும்."</string>
+    <string name="invalidPin" msgid="3850018445187475377">"4 இலிருந்து 8 எண்கள் வரையுள்ள பின் ஐத் தட்டச்சு செய்யவும்."</string>
     <string name="invalidPuk" msgid="8761456210898036513">"8 அல்லது அதற்கு மேல் எண்கள் உள்ள PUK ஐத் தட்டச்சு செய்யவும்."</string>
-    <string name="needPuk" msgid="919668385956251611">"உங்கள் SIM கார்டு PUK பூட்டுதல் செய்யப்பட்டுள்ளது. அதைத் திறக்க PUK குறியீட்டைத் உள்ளிடவும்."</string>
-    <string name="needPuk2" msgid="4526033371987193070">"SIM கார்டைத் தடுப்பு நீக்க PUK2 ஐ உள்ளிடவும்."</string>
-    <string name="enablePin" msgid="209412020907207950">"தோல்வி, SIM/RUIM பூட்டை இயக்கவும்."</string>
+    <string name="needPuk" msgid="919668385956251611">"உங்கள் சிம் கார்டு PUK பூட்டுதல் செய்யப்பட்டுள்ளது. அதைத் திறக்க PUK குறியீட்டைத் உள்ளிடவும்."</string>
+    <string name="needPuk2" msgid="4526033371987193070">"சிம் கார்டைத் தடுப்பு நீக்க PUK2 ஐ உள்ளிடவும்."</string>
+    <string name="enablePin" msgid="209412020907207950">"தோல்வி, சிம்/RUIM பூட்டை இயக்கவும்."</string>
   <plurals name="pinpuk_attempts">
-    <item quantity="one" msgid="6596245285809790142">"SIM பூட்டப்படுவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
-    <item quantity="other" msgid="7530597808358774740">"SIM பூட்டப்படுவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
+    <item quantity="one" msgid="6596245285809790142">"சிம் பூட்டப்படுவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
+    <item quantity="other" msgid="7530597808358774740">"சிம் பூட்டப்படுவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
   </plurals>
     <string name="imei" msgid="2625429890869005782">"IMEI"</string>
     <string name="meid" msgid="4841221237681254195">"MEID"</string>
@@ -76,7 +76,7 @@
     <string name="CwMmi" msgid="9129678056795016867">"அழைப்பு காத்திருப்பு"</string>
     <string name="BaMmi" msgid="455193067926770581">"அழைப்புத் தவிர்ப்பு"</string>
     <string name="PwdMmi" msgid="7043715687905254199">"கடவுச்சொல்லை மாற்று"</string>
-    <string name="PinMmi" msgid="3113117780361190304">"PIN ஐ மாற்று"</string>
+    <string name="PinMmi" msgid="3113117780361190304">"பின்னை மாற்று"</string>
     <string name="CnipMmi" msgid="3110534680557857162">"இருக்கும் எண்ணை அழைக்கிறது"</string>
     <string name="CnirMmi" msgid="3062102121430548731">"அழைப்பு எண் வரையறுக்கப்பட்டது"</string>
     <string name="ThreeWCMmi" msgid="9051047170321190368">"மும்முனை அழைப்பு"</string>
@@ -287,13 +287,13 @@
     <string name="permlab_sendSms" msgid="5600830612147671529">"SMS குறுந்தகவல்களை அனுப்புதல்"</string>
     <string name="permdesc_sendSms" msgid="7094729298204937667">"SMS செய்திகளை அனுப்ப பயன்பாட்டை அனுமதிக்கிறது. இதற்கு எதிர்பாராத கட்டணங்கள் விதிக்கப்படலாம். தீங்கு விளைவிக்கும் பயன்பாடுகள் உங்களின் உறுதிப்படுத்தல் எதுவுமின்றி செய்திகளை அனுப்பி உங்களுக்குக் கட்டணம் விதிக்கலாம்."</string>
     <string name="permlab_sendRespondViaMessageRequest" msgid="8713889105305943200">"நிகழ்வுகளுக்குச் செய்தி வழியாகப் பதிலை அனுப்புதல்"</string>
-    <string name="permdesc_sendRespondViaMessageRequest" msgid="7107648548468778734">"உள்வரும் அழைப்புகளுக்கான நிகழ்வுகளுக்கு, செய்தி வழியாகப் பதிலளிப்பதை நிர்வகிப்பதற்கு, பிற செய்தியிடல் பயன்பாடுகளுக்குக் கோரிக்கைகளை அனுப்புவதற்குப் பயன்பாட்டை அனுமதிக்கிறது."</string>
+    <string name="permdesc_sendRespondViaMessageRequest" msgid="7107648548468778734">"உள்வரும் அழைப்புகளுக்கான நிகழ்வுகளுக்கு, செய்தி வழியாகப் பதிலளிப்பதை நிர்வகிப்பதற்கு, பிற மெசேஜ் பயன்பாடுகளுக்குக் கோரிக்கைகளை அனுப்புவதற்குப் பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_readSms" msgid="8745086572213270480">"உங்கள் உரைச் செய்திகளை (SMS அல்லது MMS) படித்தல்"</string>
-    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"உங்கள் டேப்லெட் அல்லது SIM கார்டில் சேமிக்கப்பட்ட SMS குறுஞ்செய்திகளைப் படிக்க பயன்பாட்டை அனுமதிக்கிறது. SMS குறுஞ்செய்திகளின் உள்ளடக்கம் அல்லது ரகசியத்தன்மை ஆகியவற்றைப் பொருட்படுத்தாமல் அச்செய்திகளைப் படிக்க பயன்பாட்டை இது அனுமதிக்கிறது."</string>
-    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"உங்கள் மொபைல் அல்லது SIM கார்டில் சேமிக்கப்பட்ட SMS குறுஞ்செய்திகளைப் படிக்கப் பயன்பாட்டை அனுமதிக்கிறது. SMS குறுஞ்செய்திகளின் உள்ளடக்கம் அல்லது ரகசியத்தன்மை ஆகியவற்றைப் பொருட்படுத்தாமல் அச்செய்திகளைப் படிக்க பயன்பாட்டை இது அனுமதிக்கிறது."</string>
+    <string name="permdesc_readSms" product="tablet" msgid="2467981548684735522">"உங்கள் டேப்லெட் அல்லது சிம் கார்டில் சேமிக்கப்பட்ட SMS குறுஞ்செய்திகளைப் படிக்க பயன்பாட்டை அனுமதிக்கிறது. SMS குறுஞ்செய்திகளின் உள்ளடக்கம் அல்லது ரகசியத்தன்மை ஆகியவற்றைப் பொருட்படுத்தாமல் அச்செய்திகளைப் படிக்க பயன்பாட்டை இது அனுமதிக்கிறது."</string>
+    <string name="permdesc_readSms" product="default" msgid="3695967533457240550">"உங்கள் மொபைல் அல்லது சிம் கார்டில் சேமிக்கப்பட்ட SMS குறுஞ்செய்திகளைப் படிக்கப் பயன்பாட்டை அனுமதிக்கிறது. SMS குறுஞ்செய்திகளின் உள்ளடக்கம் அல்லது ரகசியத்தன்மை ஆகியவற்றைப் பொருட்படுத்தாமல் அச்செய்திகளைப் படிக்க பயன்பாட்டை இது அனுமதிக்கிறது."</string>
     <string name="permlab_writeSms" msgid="3216950472636214774">"உங்கள் உரைச் செய்திகளைத் (SMS அல்லது MMS) திருத்துதல்"</string>
-    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"டேப்லெட் அல்லது SIM கார்டில் சேமிக்கப்பட்ட SMS செய்திகளை எழுத, பயன்பாட்டை அனுமதிக்கிறது. தீங்குவிளைவிக்கும் பயன்பாடுகள் செய்திகளை நீக்கலாம்."</string>
-    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"ஃபோன் அல்லது SIM கார்டில் சேமிக்கப்பட்ட SMS செய்திகளை எழுத, பயன்பாட்டை அனுமதிக்கிறது. தீங்குவிளைவிக்கும் பயன்பாடுகள் செய்திகளை நீக்கலாம்."</string>
+    <string name="permdesc_writeSms" product="tablet" msgid="5160413947794501538">"டேப்லெட் அல்லது சிம் கார்டில் சேமிக்கப்பட்ட SMS செய்திகளை எழுத, பயன்பாட்டை அனுமதிக்கிறது. தீங்குவிளைவிக்கும் பயன்பாடுகள் செய்திகளை நீக்கலாம்."</string>
+    <string name="permdesc_writeSms" product="default" msgid="7268668709052328567">"ஃபோன் அல்லது சிம் கார்டில் சேமிக்கப்பட்ட SMS செய்திகளை எழுத, பயன்பாட்டை அனுமதிக்கிறது. தீங்குவிளைவிக்கும் பயன்பாடுகள் செய்திகளை நீக்கலாம்."</string>
     <string name="permlab_receiveWapPush" msgid="5991398711936590410">"உரைச் செய்திகளைப் (WAP) பெறுதல்"</string>
     <string name="permdesc_receiveWapPush" msgid="748232190220583385">"WAP செய்திகளைப் பெற, செயற்படுத்தப் பயன்பாட்டை அனுமதிக்கிறது. உங்களுக்கு அனுப்பப்படும் செய்திகளை உங்களுக்குக் காட்டாமல் கண்காணிக்க அல்லது நீக்குவதற்கான திறன் இந்த அனுமதியில் உள்ளடங்கும்."</string>
     <string name="permlab_receiveBluetoothMap" msgid="7593811487142360528">"Bluetooth செய்திகளைப் (MAP) பெறுதல்"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"தொலைநிலைக் காட்சியின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. இயல்பான பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"விட்ஜெட் சேவையுடன் இணைத்தல்"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"விட்ஜெட் சேவையின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. சாதாரண பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"வழு வழங்குநர் சேவையுடன் இணைத்தல்"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"பதிவு செய்த எந்தவொரு வழி வழங்குநர்கள் சேவையின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. சாதாரண பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"சாதன நிர்வாகியுடன் ஊடாடுதல்"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"சாதன நிர்வாகிக்கு இன்டென்ட்ஸை அனுப்ப, ஹோல்டரை அனுமதிக்கிறது. சாதாரண பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"டிவி உள்ளீட்டுடன் இணைத்தல்"</string>
@@ -543,8 +541,8 @@
     <string name="permdesc_modifyAudioSettings" msgid="3522565366806248517">"ஒலியளவு மற்றும் வெளியீட்டிற்கு ஸ்பீக்கர்கள் பயன்படுத்தப்படுவது போன்ற ஒட்டுமொத்த ஆடியோ அமைப்புகளைக் கட்டுப்படுத்தப் பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_recordAudio" msgid="3876049771427466323">"ஆடியோவைப் பதிவுசெய்தல்"</string>
     <string name="permdesc_recordAudio" msgid="4906839301087980680">"மைக்ரோஃபோன் மூலம் ஆடியோவைப் பதிவுசெய்ய பயன்பாட்டை அனுமதிக்கிறது. உங்கள் உறுதிப்படுத்தல் இல்லாமல் எந்நேரத்திலும் ஆடியோவைப் பதிவுசெய்ய இந்த அனுமதி பயன்பாட்டை அனுமதிக்கிறது."</string>
-    <string name="permlab_sim_communication" msgid="1180265879464893029">"SIM தகவல்தொடர்பு"</string>
-    <string name="permdesc_sim_communication" msgid="5725159654279639498">"SIM க்குக் கட்டளைகளை அனுப்ப பயன்பாட்டை அனுமதிக்கிறது. இது மிகவும் ஆபத்தானதாகும்."</string>
+    <string name="permlab_sim_communication" msgid="1180265879464893029">"சிம் தகவல்தொடர்பு"</string>
+    <string name="permdesc_sim_communication" msgid="5725159654279639498">"சிம் க்குக் கட்டளைகளை அனுப்ப பயன்பாட்டை அனுமதிக்கிறது. இது மிகவும் ஆபத்தானதாகும்."</string>
     <string name="permlab_camera" msgid="3616391919559751192">"படங்கள் மற்றும் வீடியோக்களை எடுத்தல்"</string>
     <string name="permdesc_camera" msgid="8497216524735535009">"கேமரா மூலமாகப் படங்களையும், வீடியோக்களையும் எடுக்க பயன்பாட்டை அனுமதிக்கிறது. உங்கள் உறுதிப்படுத்தல் இன்றி கேமராவை எந்நேரத்திலும் பயன்படுத்தப் பயன்பாட்டை இது அனுமதிக்கிறது."</string>
     <string name="permlab_cameraDisableTransmitLed" msgid="2651072630501126222">"கேமரா பயன்பாட்டில் இருக்கும்போது டிரான்ஸ்மிட் இன்டிகேட்டர் LED ஐ முடக்குதல்"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"தொலைபேசியை இயக்குதல் அல்லது முடக்குதல்"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"டேப்லெட்டை இயக்க அல்லது முடக்க, பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"மொபைலை இயக்க அல்லது முடக்க, பயன்பாட்டை அனுமதிக்கிறது."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"திரை நேர முடிவை மீட்டமைத்தல்"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"திரை நேர முடிவை மீட்டமைக்கப் பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ஆரம்ப சோதனைமுறையில் இயக்குதல்"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"டேப்லெட் வன்பொருளிற்கு முழு அணுகலையும் வழங்கி, கீழ்நிலை தயாரிப்பாளர் சோதனையாக இயக்கவும். டேப்லெட்டானது தயாரிப்பாளர் சோதனை முறையில் இயங்கும்போது மட்டுமே கிடைக்கும்."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"தொலைபேசி வன்பொருளிற்கு முழு அணுகலையும் வழங்கி, கீழ்நிலை தயாரிப்பாளர் சோதனையாக இயக்கவும். தொலைபேசியானது தயாரிப்பாளர் சோதனை முறையில் இயங்கும்போது மட்டுமே கிடைக்கும்."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"தற்காலிகச் சேமிப்பு கோப்பு அமைப்பைப் படிக்க மற்றும் எழுத, பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP அழைப்புகளைச் செய்தல்/பெறுதல்"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP அழைப்புகளைச் செய்ய/பெற, பயன்பாட்டை அனுமதிக்கிறது."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"உள்வரும் அழைப்பிற்கான திரையுடன் ஊடாடுதல்"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"உள்வரும் அழைப்பிற்கான திரையைப் பயனர் எப்போது மற்றும் எப்படிக் காணவேண்டும் என்பதைக் கட்டுப்படுத்துவதற்குப் பயன்பாட்டை அனுமதிக்கிறது."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"உள்வரும் அழைப்பிற்கான திரையுடன் ஊடாடுதல்"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"உள்வரும் அழைப்பிற்கான திரையைப் பயனர் எப்போது மற்றும் எப்படிக் காணவேண்டும் என்பதைக் கட்டுப்படுத்துவதற்குப் பயன்பாட்டை அனுமதிக்கிறது."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"டெலிஃபோனி சேவைகளுடனான ஊடாடல்"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"அழைப்புகளைச் செய்ய/பெற, டெலிஃபோனி சேவைகளுடன் ஊடாட பயன்பாட்டை அனுமதிக்கிறது."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"அழைப்பின் பயனர் அனுபவத்தை வழங்குதல்"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"அழைப்பின் பயனர் அனுபவத்தை வழங்க பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"பிணைய பயன்பாட்டு வரலாற்றைப் படித்தல்"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"குறிப்பிட்ட நெட்வொர்க்குகள் மற்றும் பயன்பாடுகளுக்கான நெட்வொர்க் பயன்பாட்டின் வரலாற்றைப் படிக்க, பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"பிணைய கொள்கையை நிர்வகித்தல்"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"அறிவிப்புகளைக் கண்காணிக்கும் சேவையின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. இயல்பான பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"நிபந்தனை வழங்குநர் சேவையுடன் இணைத்தல்"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"நிபந்தனை வழங்குநர் சேவையின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. சாதாரண பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"மீடியா வழிச் சேவையுடன் இணைத்தல்"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"மீடியா வழிச் சேவையின் உயர்-அளவு இடைமுகத்துடன் இணைக்க உரிமையாளரை அனுமதிக்கிறது. சாதாரண பயன்பாடுகளுக்கு ஒருபோதும் தேவையில்லை."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"டிரீம் சேவையுடன் இணை"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"டிரீம் சேவையின் உயர் நிலை இடைமுகத்துடன் இணைப்பதற்கு ஹோல்டரை அனுமதிக்கிறது. இயல்பான பயன்பாடுகளுக்கு எப்போதுமே தேவைப்படாது."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"மொபைல் நிறுவனம் வழங்கிய உள்ளமைவு பயன்பாட்டை செயலாக்குதல்"</string>
@@ -884,14 +882,14 @@
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"அலுவலகம்"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"மற்றவை"</string>
     <string name="quick_contacts_not_available" msgid="746098007828579688">"இதைப் பார்ப்பதற்குகந்த பயன்பாடு எதுவும் நிறுவப்படவில்லை."</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN குறியீட்டை உள்ளிடவும்"</string>
-    <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"PUK மற்றும் புதிய PIN குறியீட்டை உள்ளிடவும்"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"பின் குறியீட்டை உள்ளிடவும்"</string>
+    <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"PUK மற்றும் புதிய பின் குறியீட்டை உள்ளிடவும்"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1341112146710087048">"PUK குறியீடு"</string>
-    <string name="keyguard_password_enter_pin_prompt" msgid="8027680321614196258">"புதிய PIN குறியீடு"</string>
+    <string name="keyguard_password_enter_pin_prompt" msgid="8027680321614196258">"புதிய பின் குறியீடு"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"கடவுச்சொல்லை உள்ளிட, தொடவும்"</font></string>
     <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"திறக்க, கடவுச்சொல்லை உள்ளிடவும்"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"திறக்க, PIN ஐ உள்ளிடவும்"</string>
-    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"தவறான PIN குறியீடு."</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"திறக்க, பின்னை உள்ளிடவும்"</string>
+    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"தவறான பின் குறியீடு."</string>
     <string name="keyguard_label_text" msgid="861796461028298424">"தடைநீக்க, மெனுவை அழுத்தி பின்பு 0 ஐ அழுத்தவும்."</string>
     <string name="emergency_call_dialog_number_for_display" msgid="696192103195090970">"அவசர எண்"</string>
     <string name="lockscreen_carrier_default" msgid="8963839242565653192">"சேவை இல்லை."</string>
@@ -909,13 +907,13 @@
     <string name="lockscreen_charged" msgid="321635745684060624">"சார்ஜ் செய்யப்பட்டது"</string>
     <string name="lockscreen_battery_short" msgid="4477264849386850266">"<xliff:g id="NUMBER">%d</xliff:g><xliff:g id="PERCENT">%%</xliff:g>"</string>
     <string name="lockscreen_low_battery" msgid="1482873981919249740">"உங்கள் சார்ஜரை இணைக்கவும்."</string>
-    <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"SIM கார்டு இல்லை"</string>
-    <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"டேப்லெட்டில் SIM கார்டு இல்லை."</string>
-    <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"தொலைபேசியில் SIM கார்டு இல்லை."</string>
-    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"SIM கார்டைச் செருகவும்."</string>
-    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"SIM கார்டு இல்லை அல்லது படிக்கக்கூடியதாக இல்லை. SIM கார்டைச் செருகவும்."</string>
-    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"பயன்படுத்த முடியாத SIM கார்டு."</string>
-    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"உங்கள் SIM கார்டு நிரந்தரமாக முடக்கப்பட்டது.\n மற்றொரு SIM கார்டிற்காக உங்கள் வயர்லெஸ் சேவை வழங்குநரைத் தொடர்புகொள்ளவும்."</string>
+    <string name="lockscreen_missing_sim_message_short" msgid="5099439277819215399">"சிம் கார்டு இல்லை"</string>
+    <string name="lockscreen_missing_sim_message" product="tablet" msgid="151659196095791474">"டேப்லெட்டில் சிம் கார்டு இல்லை."</string>
+    <string name="lockscreen_missing_sim_message" product="default" msgid="2186920585695169078">"தொலைபேசியில் சிம் கார்டு இல்லை."</string>
+    <string name="lockscreen_missing_sim_instructions" msgid="5372787138023272615">"சிம் கார்டைச் செருகவும்."</string>
+    <string name="lockscreen_missing_sim_instructions_long" msgid="3526573099019319472">"சிம் கார்டு இல்லை அல்லது படிக்கக்கூடியதாக இல்லை. சிம் கார்டைச் செருகவும்."</string>
+    <string name="lockscreen_permanent_disabled_sim_message_short" msgid="5096149665138916184">"பயன்படுத்த முடியாத சிம் கார்டு."</string>
+    <string name="lockscreen_permanent_disabled_sim_instructions" msgid="910904643433151371">"உங்கள் சிம் கார்டு நிரந்தரமாக முடக்கப்பட்டது.\n மற்றொரு சிம் கார்டிற்காக உங்கள் வயர்லெஸ் சேவை வழங்குநரைத் தொடர்புகொள்ளவும்."</string>
     <string name="lockscreen_transport_prev_description" msgid="6300840251218161534">"முந்தைய ட்ராக்"</string>
     <string name="lockscreen_transport_next_description" msgid="573285210424377338">"அடுத்த ட்ராக்"</string>
     <string name="lockscreen_transport_pause_description" msgid="3980308465056173363">"இடைநிறுத்து"</string>
@@ -925,13 +923,13 @@
     <string name="lockscreen_transport_ffw_description" msgid="42987149870928985">"வேகமாக முன்செல்"</string>
     <string name="emergency_calls_only" msgid="6733978304386365407">"அவசர அழைப்புகள் மட்டும்"</string>
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"நெட்வொர்க் பூட்டப்பட்டது"</string>
-    <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"SIM கார்டு PUK பூட்டுதல் செய்யப்பட்டுள்ளது."</string>
+    <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"சிம் கார்டு PUK பூட்டுதல் செய்யப்பட்டுள்ளது."</string>
     <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"பயனர் கையேட்டைப் பார்க்கவும் அல்லது வாடிக்கையாளர் சேவையைத் தொடர்புகொள்ளவும்."</string>
-    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"SIM கார்டு பூட்டப்பட்டுள்ளது."</string>
-    <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"SIM கார்டைத் திறக்கிறது..."</string>
+    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"சிம் கார்டு பூட்டப்பட்டுள்ளது."</string>
+    <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"சிம் கார்டைத் திறக்கிறது..."</string>
     <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"உங்கள் கடவுச்சொல்லை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
-    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"உங்கள் PIN ஐ <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
+    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"உங்கள் பின்னை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். இன்னும் <xliff:g id="NUMBER_1">%d</xliff:g> முறை தவறாக வரைந்தால், உங்கள் Google உள்நுழைவைப் பயன்படுத்தி டேப்லெட்டைத் திறக்குமாறு கேட்கப்படுவீர்கள். \n\n <xliff:g id="NUMBER_2">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். இன்னும் <xliff:g id="NUMBER_1">%d</xliff:g> முறை தவறாக வரைந்தால், உங்கள் Google உள்நுழைவைப் பயன்படுத்தி மொபைலைத் திறக்குமாறு கேட்கப்படுவீர்கள். \n\n <xliff:g id="NUMBER_2">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"டேப்லெட்டைத் தடைநீக்க <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக முயற்சித்துள்ளீர்கள். இன்னும் <xliff:g id="NUMBER_1">%d</xliff:g> தோல்வி முயற்சிகளுக்குப் பிறகு, டேப்லெட்டானது ஆரம்ப இயல்புநிலைக்கு மீட்டமைக்கப்பட்டு, எல்லா பயனர் தரவும் இழக்கப்படும்."</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s மூலம் பகிர்"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"முகப்பு பயன்பாட்டைத் தேர்ந்தெடுக்கவும்"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"இந்தச் செயலுக்கு இயல்பாகப் பயன்படுத்து."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"வேறு பயன்பாட்டைப் பயன்படுத்தவும்"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"முறைமை அமைப்பு &gt; பயன்பாடுகள் &gt; பதிவிறக்கியவை என்பதில் உள்ள இயல்பை அழிக்கவும்."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"செயலைத் தேர்ந்தெடுக்கவும்"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB சாதனத்திற்கான பயன்பாட்டைத் தேர்வுசெய்க"</string>
@@ -1286,8 +1285,8 @@
     <string name="wifi_p2p_invitation_to_connect_title" msgid="4958803948658533637">"இணைவதற்கான அழைப்பு"</string>
     <string name="wifi_p2p_from_message" msgid="570389174731951769">"அனுப்புநர்:"</string>
     <string name="wifi_p2p_to_message" msgid="248968974522044099">"பெறுநர்:"</string>
-    <string name="wifi_p2p_enter_pin_message" msgid="5920929550367828970">"பின்வரும் அவசியமான PIN ஐ உள்ளிடவும்:"</string>
-    <string name="wifi_p2p_show_pin_message" msgid="8530563323880921094">"PIN:"</string>
+    <string name="wifi_p2p_enter_pin_message" msgid="5920929550367828970">"பின்வரும் அவசியமான பின்னை உள்ளிடவும்:"</string>
+    <string name="wifi_p2p_show_pin_message" msgid="8530563323880921094">"பின்:"</string>
     <string name="wifi_p2p_frequency_conflict_message" product="tablet" msgid="8012981257742232475">"<xliff:g id="DEVICE_NAME">%1$s</xliff:g> உடன் டேப்லெட் இணைக்கப்படும்போது, வைஃபையிலிருந்து தற்காலிகமாகத் துண்டிக்கப்படும்."</string>
     <string name="wifi_p2p_frequency_conflict_message" product="default" msgid="7363907213787469151">"<xliff:g id="DEVICE_NAME">%1$s</xliff:g> உடன் மொபைல் இணைக்கப்படும்போது, வைஃபையிலிருந்து தற்காலிகமாகத் துண்டிக்கப்படும்."</string>
     <string name="select_character" msgid="3365550120617701745">"எழுத்துக்குறியைச் செருகு"</string>
@@ -1296,18 +1295,18 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"அனுமதி"</string>
     <string name="sms_control_no" msgid="625438561395534982">"நிராகரி"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; க்குச் செய்தியை அனுப்ப விரும்புகிறது."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"உங்கள் மொபைல் கணக்கில் இது "<font fgcolor="#ffffb060">"கட்டணம் விதிக்கலாம்"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"உங்கள் மொபைல் கணக்கில் இது கட்டணம் விதிக்கலாம்."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"உங்கள் மொபைல் கணக்கில் இது "<b>"கட்டணம் விதிக்கலாம்"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"உங்கள் மொபைல் கணக்கில் இது கட்டணம் விதிக்கலாம்."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"அனுப்பு"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ரத்துசெய்"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"எனது விருப்பத்தேர்வை நினைவில்கொள்"</string>
     <string name="sms_short_code_remember_undo_instruction" msgid="4960944133052287484">"அமைப்பு &gt; பயன்பாடுகள் என்பதில் பிறகு நீங்கள் மாற்றலாம்"</string>
     <string name="sms_short_code_confirm_always_allow" msgid="3241181154869493368">"எப்போதும் அனுமதி"</string>
     <string name="sms_short_code_confirm_never_allow" msgid="446992765774269673">"ஒருபோதும் அனுமதிக்காதே"</string>
-    <string name="sim_removed_title" msgid="6227712319223226185">"SIM கார்டு அகற்றப்பட்டது"</string>
-    <string name="sim_removed_message" msgid="5450336489923274918">"சரியான SIM கார்டைச் செருகி, மறுதொடக்கம் செய்யும் வரை செல்லுலார் நெட்வொர்க் கிடைக்காது."</string>
+    <string name="sim_removed_title" msgid="6227712319223226185">"சிம் கார்டு அகற்றப்பட்டது"</string>
+    <string name="sim_removed_message" msgid="5450336489923274918">"சரியான சிம் கார்டைச் செருகி, மறுதொடக்கம் செய்யும் வரை செல்லுலார் நெட்வொர்க் கிடைக்காது."</string>
     <string name="sim_done_button" msgid="827949989369963775">"முடிந்தது"</string>
-    <string name="sim_added_title" msgid="3719670512889674693">"SIM கார்டு சேர்க்கப்பட்டது"</string>
+    <string name="sim_added_title" msgid="3719670512889674693">"சிம் கார்டு சேர்க்கப்பட்டது"</string>
     <string name="sim_added_message" msgid="7797975656153714319">"செல்லுலார் நெட்வொர்க்கை அணுக உங்கள் சாதனத்தை மறுதொடக்கம் செய்யவும்."</string>
     <string name="sim_restart_button" msgid="4722407842815232347">"மறுதொடக்கம்"</string>
     <string name="time_picker_dialog_title" msgid="8349362623068819295">"நேரத்தை அமை"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB பிழைத்திருத்தத்தை முடக்க, தொடவும்."</string>
     <string name="select_input_method" msgid="8547250819326693584">"விசைப்பலகையை மாற்று"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"விசைப்பலகைகளைத் தேர்வுசெய்க"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"கைமுறை விசைப்பலகை"</string>
+    <string name="show_ime" msgid="9157568568695230830">"உள்ளீட்டு முறையைக் காட்டு"</string>
     <string name="hardware" msgid="7517821086888990278">"வன்பொருள்"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"விசைப்பலகைத் தளவமைப்பைத் தேர்ந்தெடுக்கவும்"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"விசைப்பலகைத் தளவமைப்பைத் தேர்ந்தெடுக்க தொடவும்."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"நம்பகமான ஏஜென்ட் சேவையுடன் இணைப்பதற்குப் பயன்பாட்டை அனுமதிக்கிறது."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"புதுப்பிப்பு மற்றும் மீட்டெடுப்பு அமைப்புடன் ஊடாடுதல்"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"மீட்டெடுப்பு அமைப்பு மற்றும் முறைமை புதுப்பிப்புகளுடன் ஊடாடப் பயன்பாட்டை அனுமதிக்கிறது."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"மீடியா வெளிப்பாடு அமர்வுகளை உருவாக்கு"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"மீடியா வெளிப்பாடு அமர்வுகளை உருவாக்கப் பயன்பாட்டை அனுமதிக்கிறது. காட்சி மற்றும் ஆடியோ உள்ளடக்கத்தைப் அறிவதற்கான திறனை இந்த அமர்வுகள் பயன்பாடுகளுக்கு வழங்குகின்றன. சாதாரண பயன்பாடுகளுக்கு ஒருபோதும் தேவையில்லை."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"மீடியா வெளிப்பாடு அமர்வுகளை நிர்வகித்தல்"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"மீடியா வெளிப்பாடு அமர்வுகளை நிர்வகிக்க பயன்பாட்டை அனுமதிக்கிறது. காட்சி மற்றும் ஆடியோ உள்ளடக்கத்தைப் படமெடுப்பதற்கான திறனை இந்த அமர்வுகள் பயன்பாடுகளுக்கு வழங்குகின்றன. சாதாரண பயன்பாடுகளுக்கு ஒருபோதும் தேவையில்லை."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"நிறுவல் அமர்வுகளைப் படிக்கலாம்"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"நிறுவல் அமர்வுகளைப் படிக்க, பயன்பாட்டை அனுமதிக்கிறது. இது செயல்படும் தொகுப்பு நிறுவல்களைப் பற்றிய விவரங்களைப் பார்க்க அனுமதிக்கிறது."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"அளவை மாற்றும் கட்டுப்பாடுகளுக்கு இருமுறை தொடவும்"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"நிராகரி"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"அனுமதிக் கோரப்பட்டது"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> கணக்கிற்கான அனுமதி\nகோரப்பட்டது."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"தனிப்பட்ட இடத்தில் பயன்பாட்டைப் பயன்படுத்துகிறீர்கள்"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"பணியிடத்தில் பயன்பாட்டைப் பயன்படுத்துகிறீர்கள்"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"இந்தப் பயன்பாட்டைப் பணி சுயவிவரத்திற்கு வெளியே பயன்படுத்துகிறீர்கள்"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"பணி சுயவிவரத்தில் பயன்பாட்டைப் பயன்படுத்துகிறீர்கள்"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"உள்ளீட்டு முறை"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ஒத்திசை"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"அணுகல்தன்மை"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"மணிநேரத்தைக் குறை"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM ஐ அமை"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM ஐ அமை"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"மாதத்தை அதிகரி"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"மாதத்தைக் குறை"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"நாளை அதிகரி"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"திருத்து"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"தரவு பயன்பாட்டு எச்சரிக்கை"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"பயன்பாட்டின் அளவு, அமைப்புகளைத் பார்க்க தொடவும்."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G தரவு முடக்கப்பட்டது"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G தரவு முடக்கப்பட்டது"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"செல்லுலார் தரவு முடக்கப்பட்டது"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"வைஃபை தரவு முடக்கப்பட்டது"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"வரம்பை அடைந்தது"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G தரவு வரம்பைக் கடந்தது"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G தரவு வரம்பைக் கடந்தது"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"செல்லுலார் தரவு வரம்பைக் கடந்தது"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"வைஃபை தரவு வரம்பைக் கடந்தது"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"மீதமுள்ள சுழற்சிக்கு தரவு இடைநிறுத்தப்பட்டது"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G தரவு வரம்பு கடந்தது"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G தரவு வரம்பு கடந்தது"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"செல்லுலார் தரவு வரம்பை மீறியது"</string>
@@ -1570,9 +1567,9 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"அழைப்பை ஏற்கவா?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"எப்போதும்"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"இப்போது மட்டும்"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s பணி சுயவிவரத்தை ஆதரிக்காது."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s பணி சுயவிவரத்தை ஆதரிக்காது"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"டேப்லெட்"</string>
-    <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"மொபைல்"</string>
+    <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ஃபோன்"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ஹெட்ஃபோன்கள்"</string>
     <string name="default_audio_route_name_dock_speakers" msgid="6240602982276591864">"மொபைல் வைக்கும் கருவியின் ஸ்பீக்கர்கள்"</string>
     <string name="default_media_route_name_hdmi" msgid="2450970399023478055">"HDMI"</string>
@@ -1604,21 +1601,21 @@
     <string name="kg_forgot_pattern_button_text" msgid="8852021467868220608">"வடிவத்தை மறந்துவிட்டீர்களா"</string>
     <string name="kg_wrong_pattern" msgid="1850806070801358830">"தவறான வடிவம்"</string>
     <string name="kg_wrong_password" msgid="2333281762128113157">"தவறான கடவுச்சொல்"</string>
-    <string name="kg_wrong_pin" msgid="1131306510833563801">"தவறான PIN"</string>
+    <string name="kg_wrong_pin" msgid="1131306510833563801">"தவறான பின்"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%1$d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"உங்கள் வடிவத்தை வரையவும்"</string>
-    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN ஐ உள்ளிடவும்"</string>
-    <string name="kg_pin_instructions" msgid="2377242233495111557">"PIN ஐ உள்ளிடுக"</string>
+    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"சிம் பின்னை உள்ளிடவும்"</string>
+    <string name="kg_pin_instructions" msgid="2377242233495111557">"பின்னை உள்ளிடுக"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"கடவுச்சொல்லை உள்ளிடவும்"</string>
-    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM தற்போது முடக்கப்பட்டுள்ளது. தொடர்வதற்கு PUK குறியீட்டை உள்ளிடவும். விவரங்களுக்கு மொபைல் நிறுவனங்களைத் தொடர்புகொள்ளவும்."</string>
-    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"விரும்பிய PIN குறியீட்டை உள்ளிடவும்"</string>
-    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"விரும்பிய PIN குறியீட்டை உறுதிப்படுத்தவும்"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM கார்டின் தடையைநீக்குகிறது..."</string>
-    <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"தவறான PIN குறியீடு."</string>
-    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"4 இலிருந்து 8 எண்கள் வரையுள்ள PIN ஐ உள்ளிடவும்."</string>
+    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"சிம் தற்போது முடக்கப்பட்டுள்ளது. தொடர்வதற்கு PUK குறியீட்டை உள்ளிடவும். விவரங்களுக்கு மொபைல் நிறுவனங்களைத் தொடர்புகொள்ளவும்."</string>
+    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"விரும்பிய பின் குறியீட்டை உள்ளிடவும்"</string>
+    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"விரும்பிய பின் குறியீட்டை உறுதிப்படுத்தவும்"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"சிம் கார்டின் தடையைநீக்குகிறது..."</string>
+    <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"தவறான பின் குறியீடு."</string>
+    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"4 இலிருந்து 8 எண்கள் வரையுள்ள பின்னை உள்ளிடவும்."</string>
     <string name="kg_invalid_sim_puk_hint" msgid="6025069204539532000">"PUK குறியீட்டில் 8 எழுத்துக்குறிகள் இருக்க வேண்டும்."</string>
-    <string name="kg_invalid_puk" msgid="3638289409676051243">"சரியான PUK குறியீட்டை மீண்டும் உள்ளிடவும். தொடர் முயற்சிகள் SIM ஐ நிரந்தரமாக முடக்கிவிடும்."</string>
-    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN குறியீடுகள் பொருந்தவில்லை"</string>
+    <string name="kg_invalid_puk" msgid="3638289409676051243">"சரியான PUK குறியீட்டை மீண்டும் உள்ளிடவும். தொடர் முயற்சிகள் சிம் ஐ நிரந்தரமாக முடக்கிவிடும்."</string>
+    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"பின் குறியீடுகள் பொருந்தவில்லை"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"அதிகமான வடிவ முயற்சிகள்"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"திறக்க, உங்கள் Google கணக்கு மூலம் உள்நுழையவும்."</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"பயனர்பெயர் (மின்னஞ்சல்)"</string>
@@ -1627,7 +1624,7 @@
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"தவறான பயனர்பெயர் அல்லது கடவுச்சொல்."</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"உங்கள் பயனர்பெயர் அல்லது கடவுச்சொல்லை மறந்துவிட்டீர்களா?\n"<b>"google.com/accounts/recovery"</b>" ஐப் பார்வையிடவும்."</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"கணக்கைச் சரிபார்க்கிறது…"</string>
-    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"உங்கள் PIN ஐ <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
+    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"உங்கள் பின்னை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"உங்கள் கடவுச்சொல்லை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகளில் மீண்டும் முயற்சிக்கவும்."</string>
     <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"டேப்லெட்டைத் திறக்க <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக முயற்சித்துள்ளீர்கள். இன்னும் <xliff:g id="NUMBER_1">%d</xliff:g> தோல்வி முயற்சிகளுக்குப் பிறகு, டேப்லெட்டானது ஆரம்பநிலைக்கு மீட்டமைக்கப்பட்டு, எல்லா பயனர் தரவையும் இழப்பீர்கள்."</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"அணுகல்தன்மை இயக்கப்பட்டது."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"அணுகல்தன்மை ரத்துசெய்யப்பட்டது."</string>
     <string name="user_switched" msgid="3768006783166984410">"நடப்பு பயனர் <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>க்கு மாறுகிறது…"</string>
     <string name="owner_name" msgid="2716755460376028154">"உரிமையாளர்"</string>
     <string name="error_message_title" msgid="4510373083082500195">"பிழை"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"உங்கள் நிர்வாகி இந்த மாற்றத்தை அனுமதிக்கவில்லை"</string>
@@ -1737,15 +1735,15 @@
     <string name="reason_service_unavailable" msgid="7824008732243903268">"பிரிண்டர் இயக்கத்தில் இல்லை"</string>
     <string name="print_service_installed_title" msgid="2246317169444081628">"<xliff:g id="NAME">%s</xliff:g> சேவை நிறுவப்பட்டது"</string>
     <string name="print_service_installed_message" msgid="5897362931070459152">"இயக்குவதற்குத் தட்டவும்"</string>
-    <string name="restr_pin_enter_admin_pin" msgid="783643731895143970">"நிர்வாகி PIN ஐ உள்ளிடவும்"</string>
-    <string name="restr_pin_enter_pin" msgid="3395953421368476103">"PIN ஐ உள்ளிடவும்"</string>
+    <string name="restr_pin_enter_admin_pin" msgid="783643731895143970">"நிர்வாகி பின்னை உள்ளிடவும்"</string>
+    <string name="restr_pin_enter_pin" msgid="3395953421368476103">"பின்னை உள்ளிடவும்"</string>
     <string name="restr_pin_incorrect" msgid="8571512003955077924">"தவறானது"</string>
-    <string name="restr_pin_enter_old_pin" msgid="1462206225512910757">"நடப்பு PIN"</string>
-    <string name="restr_pin_enter_new_pin" msgid="5959606691619959184">"புதிய PIN"</string>
-    <string name="restr_pin_confirm_pin" msgid="8501523829633146239">"புதிய PIN ஐ உறுதிப்படுத்தவும்"</string>
-    <string name="restr_pin_create_pin" msgid="8017600000263450337">"வரம்புகளைத் திருத்துவதற்கு PIN ஐ உருவாக்கவும்"</string>
+    <string name="restr_pin_enter_old_pin" msgid="1462206225512910757">"நடப்பு பின்"</string>
+    <string name="restr_pin_enter_new_pin" msgid="5959606691619959184">"புதிய பின்"</string>
+    <string name="restr_pin_confirm_pin" msgid="8501523829633146239">"புதிய பின்னை உறுதிப்படுத்தவும்"</string>
+    <string name="restr_pin_create_pin" msgid="8017600000263450337">"வரம்புகளைத் திருத்துவதற்கு பின்னை உருவாக்கவும்"</string>
     <string name="restr_pin_error_doesnt_match" msgid="2224214190906994548">"PINகள் பொருந்தவில்லை. மீண்டும் முயற்சிக்கவும்."</string>
-    <string name="restr_pin_error_too_short" msgid="8173982756265777792">"PIN மிகவும் சிறியதாக உள்ளது. குறைந்தது 4 இலக்கங்கள் இருக்க வேண்டும்."</string>
+    <string name="restr_pin_error_too_short" msgid="8173982756265777792">"பின் மிகவும் சிறியதாக உள்ளது. குறைந்தது 4 இலக்கங்கள் இருக்க வேண்டும்."</string>
   <plurals name="restr_pin_countdown">
     <item quantity="one" msgid="311050995198548675">"1 வினாடி கழித்து முயற்சிக்கவும்"</item>
     <item quantity="other" msgid="4730868920742952817">"<xliff:g id="COUNT">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்"</item>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> தேர்ந்தெடுக்கப்பட்டது"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> நீக்கப்பட்டது"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"பணியிடம் <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"இந்தத் திரையின் பின்னை அகற்ற, ஒரே நேரத்தில் முந்தைய மற்றும் சமீபத்தியவையைத் தொட்டு பிடிக்கவும்."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"திரையின் பின்னை அகற்ற, சமீபத்தியவையைத் தொட்டு பிடிக்கவும்."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"திரை பின் செய்யப்பட்டது. பின்னை அகற்ற உங்கள் நிறுவனம் ஆதரிக்கவில்லை."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"திரையை பின் செய்தலைப் பயன்படுத்தவா?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"திரையைப் பின் செய்தல், ஒரே காட்சியில் திரையைப் பூட்டுகிறது.\n\nவெளியேற, ஒரே நேரத்தில் முந்தையது மற்றும் சமீபத்தியவையை அழுத்திப் பிடிக்கவும்."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"திரையைப் பின் செய்தல், ஒரே காட்சியில் திரையைப் பூட்டுகிறது.\n\nவெளியேற, சமீபத்தியவையை அழுத்திப் பிடிக்கவும்."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"வேண்டாம், நன்றி"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"தொடங்கு"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"திறப்பதற்கான வடிவம்"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"கடவுச்சொல்"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"திரை பின் செய்யப்பட்டது"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"திரையின் பின் அகற்றப்பட்டது"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"அகற்றும் முன் PINஐக் கேள்"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"அகற்றும் முன் திறத்தல் வடிவத்தைக் கேள்"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"அகற்றும் முன் கடவுச்சொல்லைக் கேள்"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"பேட்டரியின் ஆயுட்காலத்தை அதிகரிக்க, பேட்டரி சேமிப்பான் சாதனத்தின் செயல்திறனைக் குறைத்து, அதிர்வுறுவதையும் பெரும்பாலான பின்புலத் தரவையும் வரம்பிடுகிறது. ஒத்திசைவைச் சார்ந்திருக்கும் மின்னஞ்சல், மெசேஜ், மேலும் பிற பயன்பாடுகளைத் திறக்கும் வரை, அவை புதுப்பிக்கப்படாமல் இருக்கலாம்.\n\nசாதனம் சார்ஜ் ஆகும் போது, பேட்டரி சேமிப்பான் தானாகவே முடக்கப்படும்."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>இல் செயல்படாத நேரம் முடியும் வரை"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ஒரு நிமிடம்"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d நிமிடங்கள்"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ஒரு மணி நேரம்"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d மணிநேரம்"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"வரையறையற்றது"</string>
 </resources>
diff --git a/core/res/res/values-te-rIN/strings.xml b/core/res/res/values-te-rIN/strings.xml
index e7e24f7..70b17bd 100644
--- a/core/res/res/values-te-rIN/strings.xml
+++ b/core/res/res/values-te-rIN/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"రిమోట్ డిస్‌ప్లే యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాల కోసం ఎప్పటికీ అవసరం ఉండకూడదు."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"విడ్జెట్ సేవకు అనుబంధించడం"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"విడ్జెట్ సేవ యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"మార్గ ప్రదాత సేవకు అనుబంధించడం"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"నమోదిత మార్గ ప్రదాతల్లో వేటికైనా అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"పరికర నిర్వాహికితో పరస్పర చర్య చేయడం"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"పరికర నిర్వాహకుడికి లక్ష్యాలను పంపడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"టీవీ ఇన్‌పుట్‌కి అనుబంధించడం"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"పవర్ ఫోన్‌ను ఆన్ లేదా ఆఫ్ చేయడం"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"టాబ్లెట్‌ను ఆన్ లేదా ఆఫ్ చేయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ఫోన్‌ను ఆన్ లేదా ఆఫ్ చేయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"డిస్‌ప్లే నిలుపుదల సమయాన్ని రీసెట్ చేయడం"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"డిస్‌ప్లే నిలుపుదల సమయాన్ని రీసెట్ చేయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ఫ్యాక్టరీ పరీక్ష మోడ్‌లో అమలు చేయడం"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"టాబ్లెట్ హార్డ్‌వేర్‌కు పూర్తి ప్రాప్యతను అనుమతిస్తూ, తక్కువ-స్థాయి తయారీదారు పరీక్షగా అమలు చేయండి. టాబ్లెట్ తయారీదారు పరీక్ష మోడ్‌లో అమలవుతున్నప్పుడు మాత్రమే అందుబాటులో ఉంటుంది."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"ఫోన్ హార్డ్‌వేర్‌కు పూర్తి ప్రాప్యతను అనుమతిస్తూ, తక్కువ-స్థాయి తయారీదారు పరీక్షగా అమలు చేయండి. ఫోన్ తయారీదారు పరీక్ష మోడ్‌లో అమలవుతున్నప్పుడు మాత్రమే అందుబాటులో ఉంటుంది."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"కాష్ ఫైల్‌సిస్టమ్‌ను చదవడానికి మరియు వ్రాయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP కాల్‌లను చేయడానికి/స్వీకరించడానికి"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"SIP కాల్‌లను చేయడానికి మరియు స్వీకరించడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"ఇన్-కాల్ స్క్రీన్‌తో పరస్పర చర్య చేయడం"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"వినియోగదారుకు ఇన్-కాల్ స్క్రీన్ ఎప్పుడు, ఎలా కనిపించాలనే దాన్ని నియంత్రించడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"ఇన్-కాల్ స్క్రీన్‌తో పరస్పర చర్య చేయడం"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"వినియోగదారునికి ఇన్-కాల్ స్క్రీన్ ఎప్పుడు, ఎలా కనిపించాలనే దాన్ని నియంత్రించడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"టెలిఫోన్ సేవలతో పరస్పర చర్య చేయడం"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"కాల్‌లు చేయడం/స్వీకరించడం కోసం టెలిఫోన్ సేవలతో పరస్పర చర్య చేయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ఇన్-కాల్ వినియోగదారు అనుభవాన్ని అందించడం"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ఇన్-కాల్ వినియోగదారుని అనుభవాన్ని అందించడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"చారిత్రక నెట్‌వర్క్ వినియోగాన్ని చదవడం"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"నిర్దిష్ట నెట్‌వర్క్‌లు మరియు అనువర్తనాలు కోసం చారిత్రాత్మక నెట్‌వర్క్ వినియోగాన్ని చదవడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"నెట్‌వర్క్ విధానాన్ని నిర్వహించడం"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"నోటిఫికేషన్ పరిశీలన సేవ యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాల కోసం ఎప్పటికీ అవసరం ఉండకూడదు."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"షరతు ప్రదాత సేవకు అనుబంధించడం"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"షరతు ప్రదాత సేవ యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"మీడియా మార్గ సేవకు అనుబంధించడం"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"మీడియా మార్గ సేవ యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"డ్రీమ్ సేవ‌కి అనుబంధించడం"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"డ్రీమ్ సేవ యొక్క అగ్ర-స్థాయి ఇంటర్‌ఫేస్‌కు అనుబంధించడానికి హోల్డర్‌ను అనుమతిస్తుంది. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"క్యారియర్ అందించిన కాన్ఫిగరేషన్ అనువర్తనాన్ని అభ్యర్థించడం"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$sతో భాగస్వామ్యం చేయి"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"హోమ్ అనువర్తనాన్ని ఎంచుకోండి"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ఈ చర్యకు డిఫాల్ట్‌గా ఉపయోగించండి."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"వేరొక అనువర్తనాన్ని ఉపయోగించండి"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"సిస్టమ్ సెట్టింగ్‌లు &gt; అనువర్తనాలు &gt; డౌన్‌లోడ్ చేయబడినవిలో డిఫాల్ట్‌ను క్లియర్ చేయి."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"చర్యను ఎంచుకోండి"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB పరికరం కోసం అనువర్తనాన్ని ఎంచుకోండి"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"అనుమతిస్తున్నాను"</string>
     <string name="sms_control_no" msgid="625438561395534982">"తిరస్కరిస్తున్నాను"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ఒక సందేశాన్ని &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;కి పంపాలనుకుంటోంది."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"దీని వలన మీ మొబైల్ ఖాతాకు "<font fgcolor="#ffffb060">"ఛార్జీలు పడవచ్చు"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"దీని వలన మీ మొబైల్ ఖాతాకు ఛార్జీలు పడవచ్చు."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"దీని వలన మీ మొబైల్ ఖాతాకు "<b>"ఛార్జీలు విధించబడవచ్చు"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"దీని వలన మీ మొబైల్ ఖాతాకు ఛార్జీలు విధించబడవచ్చు."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"పంపు"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"రద్దు చేయి"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"నా ఎంపికను గుర్తుంచుకో"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB డీబగ్గింగ్‌ను నిలిపివేయడానికి తాకండి."</string>
     <string name="select_input_method" msgid="8547250819326693584">"కీబోర్డ్‌ను మార్చు"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"కీబోర్డ్‌లను ఎంచుకోండి"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"భౌతిక కీబోర్డ్"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ఇన్‌పుట్ పద్ధతిని చూపు"</string>
     <string name="hardware" msgid="7517821086888990278">"హార్డ్‌వేర్"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"కీబోర్డ్ లేఅవుట్‌ను ఎంచుకోండి"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"కీబోర్డ్ లేఅవుట్‌ను ఎంచుకోవడానికి తాకండి."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"విశ్వసనీయ ఏజెంట్ సేవకు అనుబంధించడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"నవీకరణ మరియు పునరుద్ధరణ సిస్టమ్‌తో పరస్పర చర్య చేయడం"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"పునరుద్ధరణ సిస్టమ్ మరియు సిస్టమ్ నవీకరణలతో పరస్పర చర్య చేయడానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"మీడియా ప్రొజెక్షన్ సెషన్‌లను రూపొందించడం"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"మీడియా ప్రొజెక్షన్ సెషన్‌లను రూపొందించడానికి అనువర్తనాన్ని అనుమతిస్తుంది. ఈ సెషన్‌లు ప్రదర్శన మరియు ఆడియో కంటెంట్‌లను క్యాప్చర్ చేయగల సామర్థ్యాన్ని అనువర్తనాలకు అందించగలవు. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"మీడియా ప్రొజెక్షన్ సెషన్‌లను నిర్వహించడం"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"మీడియా ప్రొజెక్షన్ సెషన్‌లను నిర్వహించడానికి అనువర్తనాన్ని అనుమతిస్తుంది. ఈ సెషన్‌లు ప్రదర్శన మరియు ఆడియో కంటెంట్‌లను క్యాప్చర్ చేయగల సామర్థ్యాన్ని అనువర్తనాలకు అందించగలవు. సాధారణ అనువర్తనాలకు ఎప్పటికీ అవసరం ఉండదు."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"ఇన్‌స్టాల్ సెషన్‌లను చదవడం"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ఇన్‌స్టాల్ సెషన్‌లను చదవడానికి అనువర్తనాన్ని అనుమతిస్తుంది. ఇది సక్రియ ప్యాకేజీ ఇన్‌స్టాలేషన్‌ల గురించి వివరాలను చూడటానికి అనువర్తనాన్ని అనుమతిస్తుంది."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"జూమ్ నియంత్రణ కోసం రెండుసార్లు తాకండి"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"తిరస్కరించండి"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"అనుమతి అభ్యర్థించబడింది"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"ఖాతా <xliff:g id="ACCOUNT">%s</xliff:g> కోసం\nఅనుమతి అభ్యర్థించబడింది."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"మీరు మీ వ్యక్తిగత స్థలంలో ఈ అనువర్తనాన్ని ఉపయోగిస్తున్నారు"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"మీరు మీ కార్య స్థలంలో ఈ అనువర్తనాన్ని ఉపయోగిస్తున్నారు"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"మీరు మీ కార్యాలయ ప్రొఫైల్‌కు వెలుపల ఈ అనువర్తనాన్ని ఉపయోగిస్తున్నారు"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"మీరు మీ కార్యాలయ ప్రొఫైల్‌లో ఈ అనువర్తనాన్ని ఉపయోగిస్తున్నారు"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"ఇన్‌పుట్ పద్ధతి"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"సమకాలీకరణ"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"ప్రాప్యత"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"గంటను తగ్గించు"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PMని సెట్ చేయి"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AMను సెట్ చేయండి"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"నెలని పెంచండి"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"నెలను తగ్గించండి"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"రోజుని పెంచండి"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"సవరించు"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"డేటా వినియోగం హెచ్చరిక"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"వినియోగం మరియు సెట్టింగ్‌లను వీక్షించడానికి తాకండి."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G డేటా ఆఫ్‌లో ఉంది"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G డేటా ఆఫ్‌లో ఉంది"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"సెల్యూలార్ డేటా ఆఫ్‌లో ఉంది"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi డేటా ఆఫ్‌లో ఉంది"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"పరిమితిని చేరుకుంది"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G డేటా పరిమితిని చేరుకుంది"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G డేటా పరిమితిని చేరుకుంది"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"సెల్యులార్ డేటా పరిమి. చేరుకుంది"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi డేటా పరిమితిని చేరుకుంది"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"మిగిలిన కార్యా. డేటా పాజ్ చేయబ."</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G డేటా పరిమితి మించిపోయింది"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G డేటా పరిమితి మించిపోయింది"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"సెల్యులార్ డేటా పరిమితిని మించిపోయింది"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"కాల్‌ను ఆమోదించాలా?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ఎల్లప్పుడూ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"ఒకసారి"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s కార్యాలయ ప్రొఫైల్‌కు మద్దతు ఇవ్వదు."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s కార్యాలయ ప్రొఫైల్‌కు మద్దతు ఇవ్వదు"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"టాబ్లెట్"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"ఫోన్"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"హెడ్‌ఫోన్‌లు"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"ప్రాప్యత ప్రారంభించబడింది."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ప్రాప్యత రద్దు చేయబడింది."</string>
     <string name="user_switched" msgid="3768006783166984410">"ప్రస్తుత వినియోగదారు <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g>కి మారుస్తోంది…"</string>
     <string name="owner_name" msgid="2716755460376028154">"యజమాని"</string>
     <string name="error_message_title" msgid="4510373083082500195">"లోపం"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ఈ మార్పును మీ నిర్వాహకుడు అనుమతించలేదు"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> ఎంచుకోబడింది"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> తొలగించబడింది"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"కార్యాలయం <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"ఈ స్క్రీన్‌ను అన్‌పిన్ చేయడానికి, వెనుకకు మరియు ఇటీవలివి బటన్‌లను ఒకేసారి నొక్కి, ఉంచండి."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"ఈ స్క్రీన్‌ను అన్‌పిన్ చేయడానికి, ఇటీవలివి బటన్‌ను నొక్కి, ఉంచండి."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"స్క్రీన్ పిన్ చేయబడింది. మీ సంస్థలో అన్‌పిన్ చేయడానికి అనుమతి లేదు."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"స్క్రీన్ పిన్నింగ్‌ను ఉపయోగించాలా?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"స్క్రీన్ పిన్నింగ్ ఒక్క వీక్షణలో డిస్‌ప్లేను లాక్ చేస్తుంది.\n\nనిష్క్రమించడానికి, వెనుకకు మరియు ఇటీవలివి బటన్‌లను ఒకేసారి నొక్కి, ఉంచండి."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"స్క్రీన్ పిన్నింగ్ ఒక్క వీక్షణలో డిస్‌ప్లేను లాక్ చేస్తుంది.\n\nనిష్క్రమించడానికి, ఇటీవలివి బటన్‌ను నొక్కి, ఉంచండి."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"వద్దు, ధన్యవాదాలు"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ప్రారంభించు"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"అన్‌లాక్ నమూనా"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"పాస్‌వర్డ్"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"స్క్రీన్ పిన్ చేయబడింది"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"స్క్రీన్ అన్‌పిన్ చేయబడింది"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"అన్‌పిన్ చేయడానికి ముందు PIN కోసం అడుగు"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"అన్‌పిన్ చేయడానికి ముందు అన్‌లాక్ నమూనా కోసం అడుగు"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"అన్‌పిన్ చేయడానికి ముందు పాస్‌వర్డ్ కోసం అడుగు"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"బ్యాటరీ సామర్థ్యాన్ని మెరుగుపరచడంలో సహాయపడటానికి, బ్యాటరీ సేవర్ మీ పరికరం పనితీరుని తగ్గిస్తుంది మరియు వైబ్రేషన్‌ను మరియు అత్యధిక నేపథ్య డేటాను పరిమితపరుస్తుంది. అలాగే సమకాలీకరణపై ఆధారపడే ఇమెయిల్, సందేశ సేవ మరియు ఇతర అనువర్తనాలు మీరు వాటిని తెరిస్తే మినహా నవీకరించబడకపోవచ్చు.\n\nమీ పరికరం ఛార్జింగ్‌లో ఉన్నప్పుడు బ్యాటరీ సేవర్ స్వయంచాలకంగా ఆఫ్ చేయబడుతుంది."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"మీ వృథా సమయం <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>కి ముగిసే వరకు"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ఒక నిమిషానికి"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d నిమిషాలకి"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ఒక గంటకు"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d గంటలకు"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"నిరవధికంగా"</string>
 </resources>
diff --git a/core/res/res/values-television/dimens.xml b/core/res/res/values-television/dimens.xml
new file mode 100644
index 0000000..4c25225
--- /dev/null
+++ b/core/res/res/values-television/dimens.xml
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+<resources>
+
+     <!-- Lighting and shadow properties -->
+     <dimen name="light_y">-400dp</dimen>
+     <item type="dimen" format="float" name="ambient_shadow_alpha">0.15</item>
+     <item type="dimen" format="float" name="spot_shadow_alpha">0.3</item>
+
+</resources>
diff --git a/core/res/res/values-television/themes.xml b/core/res/res/values-television/themes.xml
index f92ff40..377982a 100644
--- a/core/res/res/values-television/themes.xml
+++ b/core/res/res/values-television/themes.xml
@@ -20,4 +20,8 @@
     <style name="Theme.Holo.Light.Dialog.Alert" parent="Theme.Leanback.Light.Dialog.Alert" />
     <style name="Theme.Material.Dialog.Alert" parent="Theme.Leanback.Dialog.Alert" />
     <style name="Theme.Material.Light.Dialog.Alert" parent="Theme.Leanback.Light.Dialog.Alert" />
+    <style name="Theme.Material.Settings.Dialog.Alert" parent="Theme.Leanback.Settings.Dialog.Alert" />
+    <style name="Theme.Material.Dialog" parent="Theme.Leanback.Dialog" />
+    <style name="Theme.Material.Light.Dialog" parent="Theme.Leanback.Light.Dialog" />
+    <style name="Theme.Material.Settings.Dialog" parent="Theme.Leanback.Settings.Dialog" />
 </resources>
diff --git a/core/res/res/values-th/strings.xml b/core/res/res/values-th/strings.xml
index b4a5fbe..60c697a 100644
--- a/core/res/res/values-th/strings.xml
+++ b/core/res/res/values-th/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"อนุญาตให้ผู้ใช้ผูกกับอินเทอร์เฟซระดับสูงสุดของจอแสดงผลระยะไกล ซึ่งแอปพลิเคชันทั่วไปไม่จำเป็นต้องใช้"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"เชื่อมโยงกับบริการวิดเจ็ต"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"อนุญาตให้ผู้ใช้เชื่อมโยงกับส่วนติดต่อผู้ใช้ระดับสูงสุดของบริการวิดเจ็ต ไม่ควรต้องใช้สำหรับแอปพลิเคชันทั่วไป"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"เชื่อมโยงกับบริการของผู้ให้บริการเส้นทาง"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"ช่วยให้เจ้าของสามารถเชื่อมโยงกับผู้ให้บริการเส้นทางที่ลงทะเบียนรายใดก็ได้ ไม่จำเป็นสำหรับแอปทั่วไป"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"ติดต่อกับผู้ดูแลอุปกรณ์"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"อนุญาตให้ผู้ใช้ส่งการติดต่อไปยังโปรแกรมควบคุมอุปกรณ์ ไม่ควรต้องใช้สำหรับแอปพลิเคชันทั่วไป"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"เชื่อมโยงกับอินพุตทีวี"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"เปิดหรือปิดโทรศัพท์"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"อนุญาตให้แอปพลิเคชันเปิดหรือปิดแท็บเล็ต"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"อนุญาตให้แอปพลิเคชันเปิดหรือปิดโทรศัพท์"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"รีเซ็ตระยะหมดเวลาแสดงผล"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"อนุญาตให้แอปนี้รีเซ็ตระยะหมดเวลาแสดงผล"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"เรียกใช้ในโหมดการทดสอบจากโรงงาน"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"เรียกใช้การทดสอบจากผู้ผลิตในระดับต่ำ โดยอนุญาตให้เข้าถึงฮาร์ดแวร์แท็บเล็ตอย่างสมบูรณ์ ใช้ได้เฉพาะช่วงที่แท็บเล็ตทำงานในโหมดการทดสอบจากผู้ผลิตเท่านั้น"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"เรียกใช้การทดสอบจากผู้ผลิตในระดับต่ำ โดยอนุญาตให้เข้าถึงฮาร์ดแวร์โทรศัพท์อย่างสมบูรณ์ ใช้ได้เฉพาะช่วงที่โทรศัพท์ทำงานในโหมดการทดสอบจากผู้ผลิตเท่านั้น"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"อนุญาตให้แอปพลิเคชันอ่านและเขียนระบบไฟล์แคช"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"โทร/รับสาย SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"อนุญาตให้แอปโทรและรับสาย SIP"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"โต้ตอบกับหน้าจอขณะกำลังใช้สาย"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"อนุญาตให้แอปควบคุมเวลาและลักษณะที่ผู้ใช้เห็นหน้าจอขณะกำลังใช้สาย"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"โต้ตอบกับหน้าจอขณะกำลังใช้สาย"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"อนุญาตให้แอปควบคุมเวลาและลักษณะที่ผู้ใช้เห็นหน้าจอขณะกำลังใช้สาย"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"โต้ตอบกับบริการโทรศัพท์"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"อนุญาตให้แอปโต้ตอบกับบริการโทรศัพท์เพื่อโทรออก/รับสาย"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"มอบประสบการณ์ของผู้ใช้ขณะกำลังใช้สาย"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"อนุญาตให้แอปมอบประสบการณ์ของผู้ใช้ขณะกำลังใช้สาย"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"อ่านประวัติการใช้เครือข่าย"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"อนุญาตให้แอปพลิเคชันอ่านประวัติการใช้เครือข่ายสำหรับเครือข่ายและแอปพลิเคชันเฉพาะ"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"จัดการนโยบายเครือข่าย"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"อนุญาตให้เจ้าของเชื่อมโยงกับอินเตอร์เฟซระดับสูงสุดของบริการตัวฟังการแจ้งเตือน ซึ่งไม่มีความจำเป็นสำหรับแอปธรรมดา"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"เชื่อมโยงกับบริการของผู้เสนอเงื่อนไข"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"อนุญาตให้ผู้ใช้อุปกรณ์เชื่อมโยงกับอินเทอร์เฟซระดับบนสุดของบริการของผู้เสนอเงื่อนไข ไม่จำเป็นสำหรับแอปทั่วไป"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"เชื่อมโยงกับบริการเส้นทางสื่อ"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"อนุญาตให้แอปพลิเคชันเชื่อมโยงกับอินเทอร์เฟซระดับบนสุดของบริการเส้นทางสื่อ ไม่จำเป็นสำหรับแอปทั่วไป"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"เชื่อมโยงกับบริการที่ต้องการ"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"อนุญาตให้แอปพลิเคชันเชื่อมโยงกับอินเทอร์เฟซระดับบนสุดของบริการที่ต้องการ ไม่จำเป็นสำหรับแอปทั่วไป"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"เรียกใช้แอปการกำหนดค่าของผู้ให้บริการ"</string>
@@ -883,7 +881,7 @@
     <string name="sipAddressTypeHome" msgid="6093598181069359295">"หน้าแรก"</string>
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"ที่ทำงาน"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"อื่นๆ"</string>
-    <string name="quick_contacts_not_available" msgid="746098007828579688">"ไม่พบแอปพลิเคชันที่ใช้ดูที่อยู่ติดต่อนี้"</string>
+    <string name="quick_contacts_not_available" msgid="746098007828579688">"ไม่พบแอปพลิเคชันที่ใช้ดูรายชื่อติดต่อนี้"</string>
     <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"พิมพ์รหัส PIN"</string>
     <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"พิมพ์ PUK และรหัส PIN ใหม่"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1341112146710087048">"รหัส PUK"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"แชร์กับ %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"เลือกแอปหน้าแรก"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"ใช้ค่าเริ่มต้นสำหรับการทำงานนี้"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"ใช้แอปอื่น"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"ล้างค่าเริ่มต้นในการตั้งค่าระบบ &gt; แอปพลิเคชัน &gt; ดาวน์โหลด"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"เลือกการทำงาน"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"เลือกแอปพลิเคชันสำหรับอุปกรณ์ USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"อนุญาต"</string>
     <string name="sms_control_no" msgid="625438561395534982">"ปฏิเสธ"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ต้องการส่งข้อความไปยัง &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"การดำเนินการนี้"<font fgcolor="#ffffb060">"อาจมีค่าใช้จ่ายเพิ่มเติม"</font>"สำหรับบัญชีมือถือของคุณ"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"การดำเนินการนี้อาจมีค่าใช้จ่ายเพิ่มเติมสำหรับบัญชีมือถือของคุณ"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"อาจมีการเรียกเก็บเงิน"</b>"จากบัญชีมือถือของคุณ"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"จะมีการเรียกเก็บเงินจากบัญชีมือถือของคุณ"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"ส่ง"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"ยกเลิก"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"จดจำตัวเลือกของฉัน"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"แตะเพื่อปิดใช้งานการแก้ไขข้อบกพร่องของ USB"</string>
     <string name="select_input_method" msgid="8547250819326693584">"เปลี่ยนแป้นพิมพ์"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"เลือกแป้นพิมพ์"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"แป้นพิมพ์บนเครื่อง"</string>
+    <string name="show_ime" msgid="9157568568695230830">"แสดงวิธีการป้อนข้อมูล"</string>
     <string name="hardware" msgid="7517821086888990278">"ฮาร์ดแวร์"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"เลือกรูปแบบแป้นพิมพ์"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"แตะเพื่อเลือกรูปแบบแป้นพิมพ์"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"อนุญาตให้แอปพลิเคชันผูกกับบริการของเอเจนต์ความน่าเชื่อถือได้"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"โต้ตอบกับการอัปเดตและระบบการกู้คืน"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"ช่วยให้แอปพลิเคชันสามารถโต้ตอบกับระบบการกู้คืนและการอัปเดตระบบ"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"สร้างเซสชันการฉายภาพสื่อ"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"อนุญาตให้แอปพลิเคชันสร้างเซสชันการฉายภาพสื่อ เซสชันดังกล่าวช่วยให้แอปพลิเคชันสามารถจับภาพหน้าจอและเนื้อหาเสียงได้ แอปทั่วไปไม่จำเป็นต้องใช้"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"จัดการเซสชันการฉายภาพสื่อ"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"อนุญาตให้แอปพลิเคชันจัดการเซสชันการฉายภาพสื่อ เซสชันดังกล่าวช่วยให้แอปพลิเคชันสามารถจับภาพหน้าจอและเนื้อหาเสียงได้ แอปพลิเคชันทั่วไปไม่จำเป็นต้องใช้"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"อ่านเซสชันการติดตั้ง"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"อนุญาตให้แอปพลิเคชันอ่านเซสชันการติดตั้ง ซึ่งจะอนุญาตให้อ่านรายละเอียดเกี่ยวกับการติดตั้งแพ็กเกจที่ใช้งาน"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"แตะสองครั้งเพื่อควบคุมการซูม"</string>
@@ -1417,7 +1416,7 @@
     <string name="ime_action_previous" msgid="1443550039250105948">"ก่อนหน้า"</string>
     <string name="ime_action_default" msgid="2840921885558045721">"ปฏิบัติ"</string>
     <string name="dial_number_using" msgid="5789176425167573586">"หมุนหมายเลข \n โดยใช้ <xliff:g id="NUMBER">%s</xliff:g>"</string>
-    <string name="create_contact_using" msgid="4947405226788104538">"สร้างที่อยู่ติดต่อ \nโดยใช้ <xliff:g id="NUMBER">%s</xliff:g>"</string>
+    <string name="create_contact_using" msgid="4947405226788104538">"สร้างรายชื่อติดต่อ \nโดยใช้ <xliff:g id="NUMBER">%s</xliff:g>"</string>
     <string name="grant_credentials_permission_message_header" msgid="2106103817937859662">"แอปพลิเคชันต่อไปนี้ขอให้มีการอนุญาตให้เข้าถึงบัญชีของคุณในขณะนี้และในอนาคต"</string>
     <string name="grant_credentials_permission_message_footer" msgid="3125211343379376561">"คุณต้องการอนุญาตหรือไม่"</string>
     <string name="grant_permissions_header_text" msgid="6874497408201826708">"คำขอเข้าถึง"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"ปฏิเสธ"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"การอนุญาตที่ขอ"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"การอนุญาตที่ขอ\nสำหรับบัญชี <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"คุณกำลังใช้แอปนี้ในพื้นที่ส่วนตัวของคุณ"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"คุณกำลังใช้แอปนี้ในพื้นที่ทำงานของคุณ"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"คุณกำลังใช้แอปนี้นอกโปรไฟล์งานของคุณ"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"คุณกำลังใช้แอปนี้ในโปรไฟล์งานของคุณ"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"วิธีป้อนข้อมูล"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"ซิงค์"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"การเข้าถึง"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"ลดชั่วโมง"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"ตั้งค่า PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"ตั้งค่า AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"เพิ่มเดือน"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ลดเดือน"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"เพิ่มวัน"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"แก้ไข"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"คำเตือนการใช้ข้อมูล"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"แตะเพื่อดูการใช้งานและการตั้งค่า"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"ข้อมูล 2G-3G ปิดอยู่"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"ข้อมูล 4G ปิดอยู่"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"ข้อมูลมือถือปิดอยู่"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"ข้อมูล Wi-Fi ปิดอยู่"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"ถึงขีดจำกัดแล้ว"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"ถึงขีดจำกัดข้อมูล 2G-3G แล้ว"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"ถึงขีดจำกัดข้อมูล 4G แล้ว"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"ถึงขีดจำกัดข้อมูลมือถือแล้ว"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"ถึงขีดจำกัดข้อมูล Wi-Fi แล้ว"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"หยุดข้อมูลที่เหลือในรอบชั่วคราว"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"เกินขีดจำกัดข้อมูล 2G - 3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"เกินขีดจำกัดของข้อมูล 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"ถึงขีดจำกัดข้อมูลมือถือแล้ว"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"รับสายหรือไม่"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ทุกครั้ง"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"เฉพาะครั้งนี้"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ไม่สนับสนุนโปรไฟล์งาน"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ไม่สนับสนุนโปรไฟล์งาน"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"แท็บเล็ต"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"โทรศัพท์"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"หูฟัง"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"เปิดใช้งานการเข้าถึงแล้ว"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"ยกเลิกการเข้าถึงแล้ว"</string>
     <string name="user_switched" msgid="3768006783166984410">"ผู้ใช้ปัจจุบัน <xliff:g id="NAME">%1$s</xliff:g>"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"กำลังเปลี่ยนเป็น <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"เจ้าของ"</string>
     <string name="error_message_title" msgid="4510373083082500195">"ข้อผิดพลาด"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"ผู้ดูแลระบบไม่อนุญาตการเปลี่ยนแปลงนี้"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"เลือก <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"ลบ <xliff:g id="KEY">%1$s</xliff:g> แล้ว"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g>ที่ทำงาน"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"หากต้องการเลิกตรึงหน้าจอ แตะ \"กลับ\" และ \"ล่าสุด\" ค้างไว้พร้อมกัน"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"หากต้องการเลิกตรึงหน้าจอ ให้แตะ \"ล่าสุด\" ค้างไว้"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"ตรึงหน้าจอแล้ว องค์กรของคุณไม่อนุญาตให้เลิกตรึง"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"ใช้การตรึงหน้าจอไหม"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"การตรึงหน้าจอจะล็อกหน้าจอให้อยู่ในมุมมองเดียว\n\nหากต้องการออก ให้แตะ \"กลับ\" และ \"ล่าสุด\" ค้างไว้พร้อมกัน"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"การตรึงหน้าจอจะล็อกหน้าจอให้อยู่ในมุมมองเดียว\n\nหากต้องการออก แตะ \"ล่าสุด\" ค้างไว้"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"ไม่เป็นไร ขอบคุณ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"เริ่มต้น"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"รูปแบบการปลดล็อก"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"รหัสผ่าน"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"ตรึงหน้าจอแล้ว"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"เลิกตรึงหน้าจอแล้ว"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"ขอ PIN ก่อนเลิกตรึง"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"ขอรูปแบบการปลดล็อกก่อนเลิกตรึง"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"ขอรหัสผ่านก่อนเลิกตรึง"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"เพื่อให้สามารถใช้แบตเตอรี่ได้ยาวนานขึ้น โหมดประหยัดแบตเตอรี่จะลดการทำงานของอุปกรณ์ และจำกัดการสั่นรวมถึงข้อมูลแบ็กกราวด์เกือบทั้งหมด อีเมล การรับส่งข้อความ และแอปอื่นๆ ที่ใช้การซิงค์อาจไม่อัปเดตจนกว่าคุณจะเปิดใช้\n\nโหมดประหยัดแบตเตอรี่จะปิดอัตโนมัติเมื่อชาร์จอุปกรณ์"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"จนกว่าจะสิ้นสุดช่วงเวลาที่เครื่องไม่ทำงานในเวลา <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 นาที"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d นาที"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 ชั่วโมง"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d ชั่วโมง"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"ไม่มีกำหนด"</string>
 </resources>
diff --git a/core/res/res/values-tl/strings.xml b/core/res/res/values-tl/strings.xml
index bdb5172..868d29d 100644
--- a/core/res/res/values-tl/strings.xml
+++ b/core/res/res/values-tl/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Binibigyang-daan ang may-hawak na masaklaw ang pinakamataas na antas ng interface ng isang remote na display. Hindi dapat kailanman kailanganin ng normal na apps."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"itali sa serbisyo ng widget"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Pinapayagan ang may-hawak na sumailalim sa nangungunang interface ng serbisyo ng widget. Hindi kailanman dapat na kailanganin para sa normal na apps."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"mag-bind sa isang serbisyo ng route provider"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Nagbibigay-daan sa may-pahintulot na mag-bind sa anumang nakarehistrong route provider. Hindi dapat kailanganin kailanman ng mga normal na app."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"makipag-ugnay sa tagapangasiwa ng device"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Pinapayagan ang mga may-ari na magpadala ng mga layunin sa administrator ng device. Hindi kailanman dapat na kailanganin para sa normal na apps."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"i-bind sa isang TV input"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"i-on o i-off ang telepono"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Pinapayagan ang app na i-on o i-off ang tablet."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Pinapayagan ang app na i-on o i-off ang telepono."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"i-reset ang pag-timeout ng display"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Pinapayagan ang app na i-reset ang pag-timeout ng display."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"tumakbo sa factory test mode"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Patakbuhin bilang isang pagsubok ng mababang antas na gumagawa, na pumapayag sa kumpletong access sa hardware ng tablet. Available lang kapag tumatakbo ang isang tablet sa mode na pagsubok ng gumagawa."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Patakbuhin bilang mababang antas na pagsubok ng gumawa, na nagpapahintulot ng kumpletong access sa hardware ng telepono. Available lang kapag tumatakbo ang telepono sa test mode ng gumawa."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Pinapayagan ang app na basahin at isulat ang cache filesystem."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"magsagawa/tumanggap ng mga tawag sa SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Pinapayagan ang app na magsagawa at makatanggap ng mga tawag sa SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"makipag-ugnayan sa in-call na screen"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Nagbibigay-daan sa app na kontrolin kung kailan at kung paano makikita ng user ang in-call na screen."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"makipag-ugnayan sa in-call na screen"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Nagbibigay-daan sa app na kontrolin kung kailan at kung paano makikita ng user ang in-call na screen."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"makipag-ugnayan sa mga serbisyo sa telephony"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Pinapayagan ang app na makipag-ugnayan sa mga serbisyo sa telephony upang tumawag/makatanggap ng mga tawag."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"magbigay ng in-call na karanasan sa user"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Nagbibigay-daan sa app na magbigay ng in-call na karanasan sa user."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"basahin ang makasaysayang paggamit ng network"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Pinapayagan ang app na basahin ang makasaysayang paggamit network para sa mga tukoy na network at apps."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"pamahalaan ang patakaran ng network"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Nagbibigay-daan sa may-ari na mapailalim sa interface sa tuktok na antas ng isang serbisyo ng notification listener. Hindi dapat kailanganin para sa karaniwang apps kahit kailan."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"i-bind sa isang serbisyo sa pagbibigay ng kundisyon"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Nagbibigay-daan sa naghahawak na i-bind ang top-level na interface ng isang serbisyo sa pagbibigay ng kundisyon. Hindi kailanman dapat kailanganin ng mga normal na app."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"mag-bind sa isang serbisyo ng media route"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Nagbibigay-daan sa may-hawak na mag-bind sa top-level na interface ng isang serbisyo ng media route. Hindi kailanman dapat kailanganin ng mga normal na app."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"sumailalim sa isang serbisyo ng dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Pinapayagan ang may-ari na sumailalim sa interface ng serbisyo ng dream na nasa nangungunang antas. Hindi kailanman dapat na kailanganin para sa mga normal na app."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"paganahin ang app ng configuration na ibinigay ng carrier"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Ibahagi gamit ang %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Pumili ng home app"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Gamitin bilang default para sa pagkilos na ito."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Gumamit ng ibang app"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"I-clear ang default sa mga setting ng System &gt; Apps &gt; Na-download."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Pumili ng pagkilos"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Pumili ng isang app para sa USB device"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Payagan"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Tanggihan"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"Gustong magpadala ng mensahe ng &lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; sa &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Magsasanhi ito "<font fgcolor="#ffffb060">"ng mga pagsingil"</font>" sa iyong mobile account."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Magsasanhi ito ng mga pagsingil sa iyong mobile account."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Ito ay "<b>"maaaring magsanhi ng mga singilin"</b>" sa iyong mobile account."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Magsasanhi ito ng mga singilin sa iyong mobile account."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Ipadala"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Kanselahin"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Tandaan ang aking pinili"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Pindutin upang huwag paganahin ang pag-debug ng USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Baguhin ang keyboard"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Piliin ang mga keyboard"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Aktwal na keyboard"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Ipakita ang pamamaraan ng pag-input"</string>
     <string name="hardware" msgid="7517821086888990278">"Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Pumili ng layout ng keyboard"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Pindutin upang pumili ng layout ng keyboard."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Pinapayagan ang isang application na sumailalim sa isang serbisyo ng trust agent."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Makipag-ugnay sa system ng pag-update at pagbawi"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Binibigyang-daan ang isang application na makipag-ugnay sa system ng pagbawi at mga pag-update ng system."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Gumawa ng mga media projection session"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Nagbibigay-daan sa isang application upang gumawa ng mga media projection session. Makakapagbigay ang mga session na ito ng kakayahan sa mga application na ma-capture ang mga nilalaman ng display at audio. Hindi kailanman dapat kailanganin ng mga normal na app."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Pamahalaan ang mga media projection session"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Nagbibigay-daan sa isang application na mapamahalaan ang mga media projection session. Makakapagbigay ang mga session na ito ng kakayahan sa mga application na kunan ang content na display at audio. Hindi kailanman dapat kailanganin ng mga normal na app."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Basahin ang mga session ng pag-install"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Pinapayagan ang isang application na magbasa ng mga session ng pag-install. Nagbibigay-daan ito upang makita ang mga detalye tungkol sa mga aktibong pag-install ng package."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Pindutin nang dalawang beses para sa pagkontrol ng zoom"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Tanggihan"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Hiniling ang pahintulot"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Hiniling ang pahintulot\npara sa account na <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Ginagamit mo ang app na ito sa iyong personal na espasyo"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Ginagamit mo ang app na ito sa iyong lugar ng trabaho"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Ginagamit mo ang app na ito sa labas ng iyong profile sa trabaho"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Ginagamit mo ang app na ito sa iyong profile sa trabaho"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Pamamaraan ng pag-input"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"I-sync"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Kakayahang Ma-access"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Bawasan ang oras"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Itakda ang PM"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Itakda ang AM"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Dagdagan ang buwan"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Bawasan ang buwan"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Dagdagan ang araw"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"I-edit"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Babala sa paggamit ng data"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Pindutin upang tingnan ang paggamit at mga setting."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Naka-off ang 2G-3G data"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Naka-off ang 4G data"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Naka-off ang cellular data"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Naka-off ang Wi-Fi data"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Naabot na ang limitasyon"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Naabot na ang limitasyon sa 2G-3G data"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Naabot na ang limitasyon sa 4G data"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Naabot na ang limitasyon sa cellular data"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Naabot na ang limitasyon sa data ng Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Naka-pause ang data para sa nalalabing bahagi ng pag-ikot"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"lumampas sa 2G-3G na limitasyon ng data"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Lumampas sa 4G na limitasyon ng data"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Lampas na sa cellular data limit"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Tanggapin ang tawag?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Palagi"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Isang beses lang"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"Hindi sinusuportahan ng %1$s ang profile sa trabaho."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"Hindi sinusuportahan ng %1$s ang profile sa trabaho"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telepono"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Mga Headphone"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Pinagana ang accessibility."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Nakansela ang pagiging naa-access."</string>
     <string name="user_switched" msgid="3768006783166984410">"Kasalukuyang user <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Lumilipat kay <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"May-ari"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Error"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Ang pagbabagong ito ay hindi pinapahintulutan ng iyong administrator"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Napili ang <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Tinanggal ang <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> sa Trabaho"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Upang i-unpin ang screen na ito, pindutin nang matagal ang Bumalik at Mga Kamakailan nang sabay-sabay."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Upang i-unpin ang screen na ito, pindutin nang matagal ang Mga Kamakailan."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Naka-pin ang screen. Hindi pinapayagan ng iyong organisasyon ang pag-a-unpin."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Gamitin ang pagpi-pin ng screen?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Nila-lock ng pagpi-pin ng screen ang display sa iisang view.\n\nUpang lumabas, pindutin nang matagal ang Bumalik at Mga Kamakailan nang sabay-sabay."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Nila-lock ng pagpi-pin ng screen ang display sa iisang view.\n\nUpang lumabas, pindutin nang matagal ang Mga Kamakailan."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"HINDI, SALAMAT NA LANG"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"SIMULAN"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"pattern sa pag-unlock"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"password"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Naka-pin ang screen"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Naka-unpin ang screen"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Humingi ng PIN bago mag-unpin"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Humingi ng pattern sa pag-unlock bago mag-unpin"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Humingi ng password bago mag-unpin"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Upang makatulong na mas mapatagal ang baterya, binabawasan ng battery saver ang pagganap ng iyong device at nililimitahan ang pag-vibrate at ang karamihan ng data ng background. Hindi maaaring ma-update ang email, pagmemensahe at iba pang mga app na umaasa sa pagsi-sync maliban kung bubuksan mo ang mga ito.\n\nAwtomatikong mao-off ang battery saver kapag nagcha-charge ang iyong device."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Hanggang sa matapos ang iyong downtime nang <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Sa loob ng isang minuto"</item>
+    <item quantity="other" msgid="6924190729213550991">"Sa loob ng %d (na) minuto"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Sa loob ng isang oras"</item>
+    <item quantity="other" msgid="5408537517529822157">"Sa loob ng %d (na) oras"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Walang tiyak na katapusan"</string>
 </resources>
diff --git a/core/res/res/values-tr/strings.xml b/core/res/res/values-tr/strings.xml
index 8f32ec5..08beb14 100644
--- a/core/res/res/values-tr/strings.xml
+++ b/core/res/res/values-tr/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"İzin sahibine, bir uzak ekranın en üst düzey arayüzüne bağlanma izni verir. Normal uygulamalarda hiçbir zaman gerek duyulmaz."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bir widget hizmetine bağla"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Cihazın sahibine bir widget hizmetinin en üst düzey arayüzüne bağlanma izni verir. Normal uygulamalarda hiçbir zaman gerek duyulmaz."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"rota sağlayıcı hizmetine bağlanma"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"İzin verilen uygulamaya tüm kayıtlı rota sağlayıcılarına bağlanma izni verir. Normal uygulamalarda hiçbir zaman gerek duyulmaz."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"bir cihaz yöneticisi ile etkileşimde bulun"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Cihazın sahibinin cihaz yöneticisine amaç göndermesine izin verir. Normal uygulamalarda hiçbir zaman gerek duyulmaz."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV girişine bağlanma"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"telefonu aç veya kapat"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Uygulamaya, tabletinizi açma veya kapatma izni verir."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Uygulamaya, telefonu açıp kapatma izni verir."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ekran zaman aşımını sıfırlama"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Uygulamanın ekran zaman aşımı süresini sıfırlamasına olanak verir."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"fabrika test modunda çalıştır"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Tabletin donanımına tam erişim veren alt düzey bir üretici testi olarak çalıştırılır. Yalnızca tablet üretici test modunda çalışırken kullanılabilir."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Telefon donanımına tam erişim veren alt düzey bir üretici testi olarak çalıştırılır. Yalnızca telefon üretici test modunda çalışırken kullanılabilir."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Uygulamaya, önbellek dosya sisteminde okuma ve yazma yapma izni verir."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP çağrıları yapma/alma"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Uygulamanın SIP çağrıları yapmasına ve almasına izin verir."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"Çağrı ekranıyla etkileşimde bulun"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Uygulamaya, kullanıcının çağrı ekranını ne zaman ve nasıl göreceğini denetleme izni verir."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"çağrı ekranıyla etkileşimde bulunma"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Uygulamaya, kullanıcının çağrı ekranını ne zaman ve nasıl göreceğini denetleme izni verir."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"telefon hizmetleriyle etkileşimde bulunma"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Uygulamanın çağrı yapmak/almak için telefon hizmetleriyle etkileşimde bulunmasına izin verir."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"çağrı içi kullanıcı deneyimi sağlama"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Uygulamaya, çağrı içi kullanım deneyimi sağlama izin verir."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"geçmiş ağ kullanımını oku"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Uygulamaya, özel ağlar ve uygulamalar için ağ kullanım geçmişini okuma izni verir."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"ağ politikasını yönet"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"İzin sahibine bir bildirim dinleyici hizmetinin en üst düzey arayüzüne bağlanma izni verir. Normal uygulamalarda hiçbir zaman gerek duyulmaz."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"bir durum sağlayıcı hizmetine bağlanma"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"İzin sahibinin, bir durum sağlayıcı hizmete ait üst düzey arayüze bağlanmasına izin verir. Normal uygulamalar için hiçbir zaman gerekli değildir."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"bir medya yönlendirme hizmetine bağlan"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"İzin sahibinin, bir medya yönlendirme hizmetine ait üst düzey arayüze bağlanmasına izin verir. Normal uygulamalar için hiçbir zaman gerekli değildir."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bir dream hizmetine bağla"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"İzin sahibine bir dream hizmetinin üst seviye arayüzüne bağlanma olanağı sunar. Normal uygulamalarda hiçbir zaman ihtiyaç duyulmamalıdır."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"operatör tarafından sağlanan yapılandırma uygulamasını çalıştır"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"%1$s ile paylaş"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Ana ekran uygulaması seçin"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Varsayılan olarak bu işlem için kullan."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Farklı bir uygulama kullan"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Sistem ayarları &gt; Uygulamalar &gt; İndirilen bölümünden varsayılanı temizleyin."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"İşlem seçin"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB cihazı için bir uygulama seçin"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"İzin ver"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Reddet"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt;, &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; adresine bir mesaj göndermek istiyor."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Bu işlem, mobil hesabınızdan "<font fgcolor="#ffffb060">"ücret alınmasına neden olabilir"</font>"."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Bu işlem, mobil hesabınızdan ücret alınmasına neden olacaktır."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Bu işlem, mobil hesabınızdan "<b>"ödeme alınmasına neden olabilir"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Bu işlem, mobil hesabınızdan ödeme alınmasına neden olacak."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Gönder"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"İptal"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Seçimimi hatırla"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB hata ayıklama özelliğini devre dışı bırakmak için dokunun."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Klavyeyi değiştirin"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Klavyeleri seç"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Fiziksel klavye"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Giriş yöntemini göster"</string>
     <string name="hardware" msgid="7517821086888990278">"Donanım"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Klavye düzeni seçin"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Bir klavye düzeni seçmek için dokunun."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Bir uygulamanın, güven aracısı hizmetine bağlanmasına izin verir."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Güncelleme ve kurtarma sistemiyle etkileşim kur"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Bir uygulamaya, kurtarma sistemi ve sistem güncellemeriyle etkileşim kurma izni verir."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Medya yansıtma oturumları oluştur"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Bir uygulamanın medya yansıtma oturumları oluşturmasına izin verir. Bu oturumlar, uygulamaların görüntü ve ses içeriklerini kaydetmesine olanak sağlar. Normal uygulamalar için hiçbir zaman gerekli olmaz."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Medya projeksiyonu oturumlarını yönetme"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Bir uygulamaya medya projeksiyon oturumlarını yönetme izni verir. Bu oturumlar, uygulamalara görüntülü ve sesli içerikleri yakalama yeteneği sağlayabilir. Normal uygulamaların hiçbir zaman buna ihtiyacı olmamalıdır."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Yükleme oturumlarını okuma"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Bir uygulamanın yükleme oturumlarını okumasına izin verir. Bu, etkin paket yüklemeleriyle ilgili ayrıntıların görülmesine olanak tanır."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Yakınlaştırma denetimi için iki kez dokunun"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Reddet"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"İzin istendi"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> hesabı için\nizin isteğinde bulunuldu."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Bu uygulamayı kişisel alanınızda kullanıyorsunuz"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Bu uygulamayı çalışma alanınızda kullanıyorsunuz"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Bu uygulamayı iş profilinizin dışında kullanıyorsunuz"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Bu uygulamayı iş profilinizde kullanıyorsunuz"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Giriş yöntemi"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Senkronizasyon"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Erişebilirlik"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Saati azalt"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"ÖS değerini ayarla"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"ÖÖ değerini ayarla"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"ÖS"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"ÖÖ"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Ayı artır"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Ayı azalt"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Günü artır"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Düzenle"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Veri kullanım uyarısı"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Kullanımı ve ayarları görmek için dokunun."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G veri kullanımı kapalı"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G veri kullanımı kapalı"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Hücresel veri kapalı"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Kablosuz veri kapalı"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Sınıra ulaşıldı"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G veri sınırına ulaşıldı"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G veri sınırına ulaşıldı"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Hücre verisi sınırına ulaşıldı"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Kablosuz veri sınırına ulaşıldı"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Kalan dönemde veri duraklatıldı"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G veri limiti aşıldı"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G veri limiti aşıldı"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Hücresel veri sınırı aşıldı"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Çağrı kabul edilsin mi?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Her zaman"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Yalnızca bir defa"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s, iş profilini desteklemiyor."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s, iş profilini desteklemiyor"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Tablet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Kulaklıklar"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Erişilebilirlik etkinleştirildi."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Erişilebilirlik iptal edildi."</string>
     <string name="user_switched" msgid="3768006783166984410">"Geçerli kullanıcı: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> adlı kullanıcıya geçiliyor…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Sahibi"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Hata"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Yöneticiniz bu değişikliğe izin vermiyor"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> seçildi"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> silindi"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> (İş)"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Bu ekranın sabitlemesini kaldırmak için Geri ve Son Kullanılanlar düğmelerine aynı anda dokunun ve basılı tutun."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Bu ekranın sabitlemesini kaldırmak için Son Kullanılanlar düğmesine dokunun ve basılı tutun."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekran sabitlendi. Kuruluşunuz sabitlemenin kaldırılmasına izin vermiyor."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Ekran sabitleme kullanılsın mı?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ekran sabitleme, ekranı tek bir görünümde kilitler.\n\nÇıkmak için Geri ve Son Kullanılanlar düğmelerine aynı anda dokunun ve basılı tutun."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ekran sabitleme, ekranı tek bir görünümde kilitler.\n\nÇıkmak için Son Kullanılanlar düğmesine dokunun ve basılı tutun."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"HAYIR, TEŞEKKÜRLER"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"BAŞLAT"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"kilit açma deseni"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"şifre"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekran sabitlendi"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekran sabitlemesi kaldırıldı"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Sabitlemeyi kaldırmadan önce PIN\'i sor"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Sabitlemeyi kaldırmadan önce kilit açma desenini sor"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Sabitlemeyi kaldırmadan önce şifre sor"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Pil tasarrufu, pilin ömrünü uzatmaya yardımcı olmak amacıyla cihazınızın performansını düşürür ve arka plan verilerini sınırlar. E-posta, mesajlaşma ve senkronizasyona dayalı diğer uygulamalar siz açmadığınız müddetçe güncellenemez. \n\nPil tasarrufu, cihaz şarj olurken otomatik olarak kapanır."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Kesinti süreniz <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> saatinde sona erene kadar"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Bir dakika süreyle"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d dakika süreyle"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Bir saat süreyle"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d saat süreyle"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Süresiz"</string>
 </resources>
diff --git a/core/res/res/values-uk/strings.xml b/core/res/res/values-uk/strings.xml
index f7583d6..b610d98 100644
--- a/core/res/res/values-uk/strings.xml
+++ b/core/res/res/values-uk/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Дозволяє власникові прив’язуватися до інтерфейсу верхнього рівня віддаленого екрана. Ніколи не застосовується для звичайних програм."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"прив\'язувати до служби віджетів"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Дозволяє власникові прив’язуватися до інтерфейсу верхнього рівня служби віджетів. Ніколи не застосовується для звичайних програм."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"підключитися до служби постачання маршрутів"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Дозволяє власникові підключатися до зареєстрованих постачальників маршрутів. Звичайні додатки ніколи не використовують цей дозвіл."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"взаємодіяти з адмін. пристрою"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Дозволяє власнику надсилати задавані функції адміністратору пристрою. Ніколи не застосовується для звичайних програм."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"підключатися до TV-входу"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"вмик. чи вимик. телефон"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Дозволяє програмі вимикати чи вимикати планшетний ПК."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Дозволяє програмі вмикати чи вимикати телефон."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"скидати час очікування дисплея"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Додаток може скидати час очікування дисплея."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"запуск у завод. реж. тест."</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Запускає тест виробника на низьк. рівні, дозволяючи повний доступ до апарат. забезп. пристр. Доступно лише коли пристр. запущ. в режимі тестув. виробником."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Запускає тест виробника на низькому рівні, дозволяючи повний доступ до апарат. забезп. тел. Доступно лише коли тел. запущено в режимі тестув. виробником."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Дозволяє програмі читати з файлової системи кеш-пам’яті та писати в неї."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"здійснювати й отримувати дзвінки через протокол SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Додаток зможе здійснювати й отримувати дзвінки через протокол SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"взаємодіяти з екраном вхідного виклику"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Дозволяє програмі контролювати, коли та як користувач бачить екран вхідного виклику."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"взаємодіяти з екраном вхідного дзвінка"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Додаток може контролювати, коли та як користувач бачить екран вхідного дзвінка."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"взаємодіяти з телефонними службами"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Дозволяє додатку взаємодіяти з телефонними службами, щоб здійснювати/приймати дзвінки."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"працювати під час розмови"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Додаток може працювати під час розмови."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"читати історію використання мережі"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Дозволяє програмі читати історію використання мережі для певних мереж і програм."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"керувати політикою мережі"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Дозволяє власнику прив’язуватися до інтерфейсу верхнього рівня служби читання сповіщень. Ніколи не застосовується для звичайних програм."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"підключитися до служби постачання умов"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Додаток зможе підключатися до інтерфейсу верхнього рівня служби постачання умов. Звичайні додатки ніколи не використовують цей дозвіл."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"підключатися до служби передавання медіафайлів"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Додаток зможе підключатися до інтерфейсу верхнього рівня служби передавання медіафайлів. Звичайні додатки ніколи не використовують цей дозвіл."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"підключення до служби заставок"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Додаток зможе підключатися до інтерфейсу верхнього рівня служби заставок. Звичайні додатки ніколи не використовують цей дозвіл."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"викликати надану оператором програму конфігурації"</string>
@@ -778,30 +776,30 @@
     <item msgid="1735177144948329370">"Дом. факс"</item>
     <item msgid="603878674477207394">"Пейджер"</item>
     <item msgid="1650824275177931637">"Інше"</item>
-    <item msgid="9192514806975898961">"Спеціал."</item>
+    <item msgid="9192514806975898961">"Указати"</item>
   </string-array>
   <string-array name="emailAddressTypes">
     <item msgid="8073994352956129127">"Дом."</item>
     <item msgid="7084237356602625604">"Роб."</item>
     <item msgid="1112044410659011023">"Інше"</item>
-    <item msgid="2374913952870110618">"Спеціал."</item>
+    <item msgid="2374913952870110618">"Указати"</item>
   </string-array>
   <string-array name="postalAddressTypes">
     <item msgid="6880257626740047286">"Дом."</item>
     <item msgid="5629153956045109251">"Роб."</item>
     <item msgid="4966604264500343469">"Інше"</item>
-    <item msgid="4932682847595299369">"Спеціал."</item>
+    <item msgid="4932682847595299369">"Указати"</item>
   </string-array>
   <string-array name="imAddressTypes">
     <item msgid="1738585194601476694">"Дом."</item>
     <item msgid="1359644565647383708">"Роб."</item>
     <item msgid="7868549401053615677">"Інше"</item>
-    <item msgid="3145118944639869809">"Спеціал."</item>
+    <item msgid="3145118944639869809">"Указати"</item>
   </string-array>
   <string-array name="organizationTypes">
     <item msgid="7546335612189115615">"Роб."</item>
     <item msgid="4378074129049520373">"Інше"</item>
-    <item msgid="3455047468583965104">"Спеціал."</item>
+    <item msgid="3455047468583965104">"Указати"</item>
   </string-array>
   <string-array name="imProtocols">
     <item msgid="8595261363518459565">"AIM"</item>
@@ -813,7 +811,7 @@
     <item msgid="2506857312718630823">"ICQ"</item>
     <item msgid="1648797903785279353">"Jabber"</item>
   </string-array>
-    <string name="phoneTypeCustom" msgid="1644738059053355820">"Спеціал."</string>
+    <string name="phoneTypeCustom" msgid="1644738059053355820">"Указати"</string>
     <string name="phoneTypeHome" msgid="2570923463033985887">"Дом."</string>
     <string name="phoneTypeMobile" msgid="6501463557754751037">"Мобільний"</string>
     <string name="phoneTypeWork" msgid="8863939667059911633">"Роб."</string>
@@ -838,20 +836,20 @@
     <string name="eventTypeBirthday" msgid="2813379844211390740">"День нар."</string>
     <string name="eventTypeAnniversary" msgid="3876779744518284000">"Річниця"</string>
     <string name="eventTypeOther" msgid="7388178939010143077">"Інші"</string>
-    <string name="emailTypeCustom" msgid="8525960257804213846">"Спеціал."</string>
+    <string name="emailTypeCustom" msgid="8525960257804213846">"Указати"</string>
     <string name="emailTypeHome" msgid="449227236140433919">"Дом."</string>
     <string name="emailTypeWork" msgid="3548058059601149973">"Роб."</string>
     <string name="emailTypeOther" msgid="2923008695272639549">"Інше"</string>
     <string name="emailTypeMobile" msgid="119919005321166205">"Мобільний"</string>
-    <string name="postalTypeCustom" msgid="8903206903060479902">"Спеціал."</string>
+    <string name="postalTypeCustom" msgid="8903206903060479902">"Указати"</string>
     <string name="postalTypeHome" msgid="8165756977184483097">"Дом."</string>
     <string name="postalTypeWork" msgid="5268172772387694495">"Роб."</string>
     <string name="postalTypeOther" msgid="2726111966623584341">"Інше"</string>
-    <string name="imTypeCustom" msgid="2074028755527826046">"Спеціал."</string>
+    <string name="imTypeCustom" msgid="2074028755527826046">"Указати"</string>
     <string name="imTypeHome" msgid="6241181032954263892">"Дом."</string>
     <string name="imTypeWork" msgid="1371489290242433090">"Роб."</string>
     <string name="imTypeOther" msgid="5377007495735915478">"Інше"</string>
-    <string name="imProtocolCustom" msgid="6919453836618749992">"Спеціал."</string>
+    <string name="imProtocolCustom" msgid="6919453836618749992">"Указати"</string>
     <string name="imProtocolAim" msgid="7050360612368383417">"AIM"</string>
     <string name="imProtocolMsn" msgid="144556545420769442">"Windows Live"</string>
     <string name="imProtocolYahoo" msgid="8271439408469021273">"Yahoo"</string>
@@ -863,7 +861,7 @@
     <string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
     <string name="orgTypeWork" msgid="29268870505363872">"Роб."</string>
     <string name="orgTypeOther" msgid="3951781131570124082">"Інше"</string>
-    <string name="orgTypeCustom" msgid="225523415372088322">"Спеціал."</string>
+    <string name="orgTypeCustom" msgid="225523415372088322">"Указати"</string>
     <string name="relationTypeCustom" msgid="3542403679827297300">"Спеціальні"</string>
     <string name="relationTypeAssistant" msgid="6274334825195379076">"Помічник"</string>
     <string name="relationTypeBrother" msgid="8757913506784067713">"Брат"</string>
@@ -879,7 +877,7 @@
     <string name="relationTypeRelative" msgid="1799819930085610271">"Родич"</string>
     <string name="relationTypeSister" msgid="1735983554479076481">"Сестра"</string>
     <string name="relationTypeSpouse" msgid="394136939428698117">"Чоловік/дружина"</string>
-    <string name="sipAddressTypeCustom" msgid="2473580593111590945">"Спеціал."</string>
+    <string name="sipAddressTypeCustom" msgid="2473580593111590945">"Указати"</string>
     <string name="sipAddressTypeHome" msgid="6093598181069359295">"Головна"</string>
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"Робоча"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"Інша"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Надіслати через %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Виберіть програму"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Використ. за умовч. для цієї дії."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Використовувати інший додаток"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Очистити налаштування за умовчанням у меню Налаштування системи &gt; Програми &gt; Завантажені."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Виберіть дію"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Вибрати програму для пристрою USB"</string>
@@ -1218,7 +1217,7 @@
     <string name="anr_application_process" msgid="8941757607340481057">"Програма <xliff:g id="APPLICATION">%1$s</xliff:g> не відповідає. Закрити її?"</string>
     <string name="anr_process" msgid="6513209874880517125">"Процес <xliff:g id="PROCESS">%1$s</xliff:g> не відповідає.\n\nЗавершити його?"</string>
     <string name="force_close" msgid="8346072094521265605">"OK"</string>
-    <string name="report" msgid="4060218260984795706">"Повідом."</string>
+    <string name="report" msgid="4060218260984795706">"Відгук"</string>
     <string name="wait" msgid="7147118217226317732">"Чекати"</string>
     <string name="webpage_unresponsive" msgid="3272758351138122503">"Сторінка не відповідає.\n\nЗакрити її?"</string>
     <string name="launch_warning_title" msgid="1547997780506713581">"Програму переадресовано"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Дозволити"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Відмовити"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; хоче надіслати повідомлення на таку адресу: &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Це "<font fgcolor="#ffffb060">"може призвести до стягнення плати"</font>" з вашого рахунку в оператора мобільного зв’язку."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Це призведе до стягнення плати з вашого рахунку в оператора мобільного зв’язку."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"Можуть стягуватися кошти"</b>" з вашого мобільного рахунку."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Буде стягнено кошти з вашого мобільного рахунку."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Надіслати"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Скасувати"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Запам’ятати мій вибір"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Торкніться, щоб вимкнути налагодження USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Змінити клавіатуру"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Вибрати клавіатури"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Фізична клавіатура"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Показати метод введення"</string>
     <string name="hardware" msgid="7517821086888990278">"Обладнання"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Виберіть розкладку клавіатури"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Торкніться, щоб вибрати розкладку клавіатури."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Дозволяє додатку прив’язуватися до служби довірчих агентів."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Взаємодіяти з оновленнями системи та системою відновлення."</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Дозволяє додатку взаємодіяти із системою відновлення й оновленнями системи."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Створювати сеанси трансляції вмісту"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Додаток може створювати сеанси трансляції вмісту. Під час цих сеансів додаток зможе отримати доступ до аудіо й зображення на екрані. Не використовується звичайними додатками."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Керувати сеансами трансляції медіа"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Додаток може керувати сеансами трансляції медіа. Під час цих сеансів додаток зможе отримати доступ до аудіо й зображення на екрані. Не використовується звичайними додатками."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Зчитувати дані сеансів встановлення"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Дозволяє додатку читати дані сеансів встановлення. Додаток може бачити деталі про активні встановлення пакетів."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Двічі торкніться, щоб керувати масштабом"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Забор."</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Потрібен дозвіл"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Запитано дозвіл\nдля облікового запису <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Ви використовуєте цей додаток в особистому профілі"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Ви використовуєте цей додаток у робочому профілі"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Ви використовуєте цей додаток за межами робочого профілю"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Ви використовуєте цей додаток у своєму робочому профілі"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Метод введення"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Синхр."</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Доступність"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"На годину назад"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Установити час \"пп\""</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Установити час \"дп\""</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"пп"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"дп"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"На місяць уперед"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"На місяць назад"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"На день уперед"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Редагувати"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Застереження про використ. даних"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Торкн.,щоб див. викор. і налашт."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Дані 2G–3G вимкнено"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Дані 4G вимкнено"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Мобільні дані вимкнено"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Дані Wi-Fi вимкнено"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Перевищено ліміт"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Досягнуто ліміту даних 2G–3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Досягнуто ліміту даних 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Досягнуто ліміту мобільних даних"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Досягнуто ліміту даних Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Передавання даних призупинено"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Перевищено ліміт даних 2G–3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Перевищено ліміт даних 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Перевищено ліміт мобільних даних"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Прийняти виклик?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Завжди"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Лише цього разу"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s не підтримує робочий профіль."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s не підтримує робочий профіль"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Планшетний ПК"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Телефон"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Навушники"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Доступність увімкнено."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Доступність скасовано."</string>
     <string name="user_switched" msgid="3768006783166984410">"Поточний користувач: <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Перехід в обліковий запис \"<xliff:g id="NAME">%1$s</xliff:g>\"…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Власник"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Помилка"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Ця дія заборонена адміністратором"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Вибрано: <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> видалено"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Робоча <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Щоб відкріпити екран, одночасно натисніть і втримуйте кнопки \"Назад\" і \"Останні додатки\"."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Щоб відкріпити екран, натисніть і втримуйте кнопку \"Останні додатки\"."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Екран закріплено. Ваша організація заборонила відкріплювати його."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Увімкнути функцію закріплення екрана?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ця функція не дозволяє переходити в інші додатки.\n\nЩоб вийти з цього режиму, одночасно натисніть і втримуйте кнопки \"Назад\" і \"Останні додатки\"."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ця функція не дозволяє переходити в інші додатки.\n\nЩоб вийти з цього режиму, натисніть і втримуйте кнопку \"Останні додатки\"."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"НІ, ДЯКУЮ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"УВІМКНУТИ"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN-код"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"ключ розблокування"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"пароль"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Екран закріплено"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Екран відкріплено"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Запитувати PIN-код перед відкріпленням"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Запитувати ключ розблокування перед відкріпленням"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Запитувати пароль перед відкріпленням"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Щоб подовжити час роботи акумулятора, функція заощадження заряду акумулятора знизить продуктивність пристрою й обмежить вібрацію та більшість фонових даних. Електронна пошта, повідомлення й інші додатки, які синхронізуються, можуть не оновлюватися, доки ви їх не відкриєте.\n\nФункція заощадження заряду акумулятора автоматично вимкнеться, коли пристрій заряджатиметься."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Термін простою закінчується о <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Протягом хвилини"</item>
+    <item quantity="other" msgid="6924190729213550991">"Протягом %d хв"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Протягом години"</item>
+    <item quantity="other" msgid="5408537517529822157">"Протягом %d год"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Без обмежень"</string>
 </resources>
diff --git a/core/res/res/values-ur-rPK/strings.xml b/core/res/res/values-ur-rPK/strings.xml
index 99534fd9..2f17e75 100644
--- a/core/res/res/values-ur-rPK/strings.xml
+++ b/core/res/res/values-ur-rPK/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"حامل کو ریموٹ ڈسپلے کے اعلی سطحی انٹرفیس کا پابند ہونے کی اجازت دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"ایک ویجیٹ سروس کے پابند بنیں"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"حامل کو ویجیٹ سروس کے اعلی سطحی انٹرفیس کا پابند ہونے کی اجازت دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"راستہ فراہم کرنے والی ایک سروس کے پابند بنیں"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"حامل کو کسی بھی رجسٹرڈ راستہ کے فراہم کنندگان کا پابند ہونے کی اجازت دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"آلہ کے ایک منتظم کے ساتھ تعامل کریں"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"حامل کو ایک آلہ کے منتظم کو ارادے بھیجنے دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"‏ایک TV ان پٹ کے پابند بنیں"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"فون کی پاور آن یا آف کریں"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"ایپ کو ٹیبلیٹ آن یا آف کرنے کی اجازت دیتا ہے۔"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"ایپ کو فون آن یا آف کرنے کی اجازت دیتا ہے۔"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ڈسپلے ٹائم آؤٹ کو دوبارہ ترتیب دیں"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"ایپ کو ڈسپلے ٹائم آؤٹ کو دوبارہ ترتیب دینے کی اجازت دیتا ہے۔"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"فیکٹری ٹیسٹ وضع میں چلائیں"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"ٹیبلیٹ ہارڈویئر تک مکمل رسائی کی اجازت دے کر، ایک کم سطح والے مینوفیکچرر ٹیسٹ کے بطور چلائیں۔ صرف اس وقت دستیاب ہوتا ہے جب ایک ٹیبلیٹ مینوفیکچرر ٹیسٹ وضع میں چل رہا ہوتا ہے۔"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"فون ہارڈویئر تک مکمل رسائی کی اجازت دے کر ایک کم سطحی مینوفیکچرر ٹیسٹ کے بطور چلائیں۔ صرف اس وقت دستیاب ہوتا ہے جب کوئی فون مینوفیکچرر ٹیسٹ وضع میں چل رہا ہوتا ہے۔"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"ایپ کو کیش فائل سسٹم پڑھنے اور لکھنے کی اجازت دیتا ہے۔"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"‏SIP کالز کریں/موصول کریں"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"‏ایپ کو SIP کالز کرنے اور موصول کرنے کی اجازت دیتا ہے۔"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"درون کال اسکرین کے ساتھ تعامل کریں"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"ایپ کو صارف کے درون کال اسکرین دیکھنے کے وقت اور طریقے کو کنٹرول کرنے کی اجازت دیتا ہے۔"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"درون کال اسکرین کے ساتھ تعامل کریں"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"ایپ کو صارف کے درون کال اسکرین دیکھنے کے وقت اور طریقے کو کنٹرول کرنے کی اجازت دیتا ہے۔"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"ٹیلیفونی سروسز کے ساتھ تعامل کریں"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"کالز کرنے/وصول کرنے کیلئے ایپ کو ٹیلیفونی سروسز کے ساتھ تعامل کرنے دیتا ہے۔"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"ایک درون کال صارف تجربہ فراہم کریں"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"ایپ کو ایک درون کال صارف تجربہ فراہم کرنے کی اجازت دیتا ہے۔"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"تاریخی نیٹ ورک کا استعمال پڑھیں"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"ایپ کو مخصوص نیٹ ورکس اور ایپس کیلئے نیٹ ورک کے استعمال کی سرگزشت پڑھنے کی اجازت دیتا ہے۔"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"نیٹ ورک کی پالیسی کا نظم کریں"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"حامل کو اطلاع سننے والی سروس کے اعلی سطحی انٹرفیس کا پابند ہونے کی اجازت دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"شرط فراہم کرنے والی ایک سروس کے پابند بنیں"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"حامل کو شرط فراہم کنندہ کی سروس کے اعلی سطحی انٹرفیس کا پابند ہونے کی اجازت دیتا ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہئے۔"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"میڈیا روٹ سروس کا پابند بنیں"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"حامل کو میڈیا روٹ سروس کے اعلی سطحی انٹرفیس کا پابند کرنے کی اجازت دیتا ہے۔ معمول کی ایپس کیلئے کبھی درکار نہیں ہونا چاہئے۔"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"ایک ڈریم سروس کا پابند بنیں"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"حامل کو ڈریم سروس کے اعلی سطحی انٹرفیس کا پابند ہونے کی اجازت دیتی ہے۔ عام ایپس کیلئے کبھی بھی اس کی ضرورت نہيں ہونی چاہیے۔"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"کیریئر کے ذریعے فراہم کردہ کنفگریشن ایپ طلب کریں"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"‏%1$s کے ساتھ اشتراک کریں"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"ایک ہوم ایپ منتخب کریں"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"اس کارروائی کیلئے بطور ڈیفالٹ استعمال کریں۔"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"ایک مختلف ایپ استعمال کریں"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"‏سسٹم ترتیبات &gt; ایپس &gt; ڈاؤن لوڈ کردہ میں ڈیفالٹ صاف کریں۔"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"ایک کارروائی منتخب کریں"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"‏USB آلہ کیلئے ایک ایپ منتخب کریں"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"اجازت دیں"</string>
     <string name="sms_control_no" msgid="625438561395534982">"رد کریں"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"‏&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; کو ایک پیغام بھیجنا چاہے گا۔"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"اس کی وجہ سے آپ کے موبائل اکاؤنٹ پر "<font fgcolor="#ffffb060">"چارجز لگ سکتے ہیں"</font>"۔"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"اس کی وجہ سے آپ کے موبائل اکاؤنٹ پر چارجز لگیں گے۔"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"اس کی وجہ سے آپ کے موبائل اکاؤنٹ پر "<b>"چارجز لگ سکتے ہیں"</b>"۔"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"اس کی وجہ سے آپ کے موبائل اکاؤنٹ پر چارجز لگیں گے۔"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"بھیجیں"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"منسوخ کریں"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"میری پسند یاد رکھیں"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"‏USB ڈیبگنگ کو غیر فعال کرنے کیلئے ٹچ کریں۔"</string>
     <string name="select_input_method" msgid="8547250819326693584">"کی بورڈ تبدیل کریں"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"کی بورڈز منتخب کریں"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"طبعی کی بورڈ"</string>
+    <string name="show_ime" msgid="9157568568695230830">"ان پٹ طریقہ دکھائیں"</string>
     <string name="hardware" msgid="7517821086888990278">"ہارڈ ویئر"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"کی بورڈ کا خاکہ منتخب کریں"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"ایک کی بورڈ کا خاکہ منتخب کرنے کیلئے چھوئیں۔"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"ایک ایپلیکیشن کو ایک ٹرسٹ ایجنٹ سروس کا پابند ہونے دیتا ہے۔"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"اپ ڈیٹ اور بازیابی سسٹم کے ساتھ تعامل کریں"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"کسی ایپ کو بازیابی سسٹم اور بازیابی اپ ڈیٹس کے ساتھ تعامل کرنے کی اجازت دیتا ہے۔"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"میڈیا پروجیکشن سیشنز بنائیں"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"ایک ایپلیکیشن کو میڈیا پروجیکشن سیشنز بنانے کی اجازت دیتی ہے۔ یہ سیشنز ایپلیکیشنز کو ڈسپلے اور آڈیو مواد کو کیپچر کرنے کی اہلیت فراہم کر سکتے ہیں۔ عام ایپس کو کبھی بھی ان کی ضرورت نہیں ہونی چاہیے۔"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"میڈیا پروجیکشن سیشنز کا نظم کریں"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"ایک ایپلیکیشن کو میڈیا پروجیکشن سیشنز کا نظم کرنے کی اجازت دیتا ہے۔ یہ سیشنز ایپلیکیشنز کو ڈسپلے اور آڈیو مواد کو کیپچر کرنے کی اہلیت فراہم کر سکتے ہیں۔ عام ایپس کو کبھی بھی ان کی ضرورت نہیں ہونی چاہیے۔"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"انسٹال سیشنز پڑھیں"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"ایک ایپلیکیشن کو انسٹال سیشنز پڑھنے کی اجازت دیتا ہے۔ یہ اسے فعال پیکیج انسٹالیشنز کے بارے میں تفصیلات دیکھنے کی اجازت دیتا ہے۔"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"زوم کے کنٹرول کیلئے دو بار ٹچ کریں"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"مسترد کریں"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"اجازت طلب کی گئی"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"اکاؤنٹ <xliff:g id="ACCOUNT">%s</xliff:g> کیلئے\nاجازت طلب کی گئی۔"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"آپ اس ایپ کو اپنی ذاتی جگہ میں استعمال کر رہے ہیں"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"آپ اس ایپ کو اپنے کام کی جگہ میں استعمال کر رہے ہیں"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"آپ اس ایپ کا استعمال اپنے دفتری پروفائل کے باہر کر رہے ہیں"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"آپ اس ایپ کو اپنے دفتری پروفائل میں استعمال کر رہے ہیں"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"اندراج کا طریقہ"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"مطابقت پذیری کریں"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Accessibility"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"گھنٹہ گھٹائیں"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"‏PM سیٹ کریں"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"قبل از دوپہر سیٹ کریں"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"ماہ بڑھائیں"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"ماہ گھٹائیں"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"دن بڑھائیں"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"ترمیم کریں"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"ڈیٹا کے استعمال کی وارننگ"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"استعمال و ترتیبات دیکھنے کیلئے ٹچ کریں۔"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"‏2G-3G ڈیٹا آف ہے"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"‏4G ڈیٹا آف ہے"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"سیلولر ڈیٹا آف ہے"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"‏Wi-Fi ڈیٹا آف ہے"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"حد تک پہنچ گیا"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"‏2G-3G ڈیٹا کی حد کو پہنچ گیا"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"‏4G ڈیٹا کی حد کو پہنچ گیا"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"سیلولر ڈیٹا کی حد کو پہنچ گیا"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"‏Wi-Fi ڈیٹا کی حد کو پہنچ گیا"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"باقی دور کیلئے ڈیٹا موقوف کر دیا"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"‏2G-3G ڈیٹا حد سے متجاوز ہو گیا"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"‏4G ڈیٹا حد سے متجاوز ہو گیا"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"سیلولر ڈیٹا کی حد سے تجاوز کرگیا"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"کال قبول کریں؟"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"ہمیشہ"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"بس ایک مرتبہ"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"‏%1$s دفتری پروفائل کا تعاون نہیں کرتا ہے۔"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"‏%1$s دفتری پروفائل کا تعاون نہیں کرتا ہے"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"ٹیبلیٹ"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"فون"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"ہیڈ فونز"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"‏Accessibility فعال۔"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"‏Accessibility منسوخ ہوگئی۔"</string>
     <string name="user_switched" msgid="3768006783166984410">"موجودہ صارف <xliff:g id="NAME">%1$s</xliff:g>۔"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"<xliff:g id="NAME">%1$s</xliff:g> پر سوئچ کیا جا رہا ہے…"</string>
     <string name="owner_name" msgid="2716755460376028154">"مالک"</string>
     <string name="error_message_title" msgid="4510373083082500195">"خرابی"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"آپ کے منتظم کے ذریعے اس تبدیلی کی اجازت نہیں ہے"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> کو منتخب کیا گیا"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> کو حذف کر دیا گیا"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"دفتر <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"اس اسکرین کا پن ہٹانے کیلئے، پیچھے اور حالیہ کو ایک ہی وقت میں ٹچ کریں اور دبائے رکھیں۔"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"اس اسکرین کا پن ہٹانے کیلئے، حالیہ کو ٹچ کریں اور دبائے رکھیں۔"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"اسکرین کو پن کر دیا گیا ہے۔ آپ کی تنظیم کی جانب سے پن ہٹانے کی اجازت نہیں ہے۔"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"اسکرین پننگ کا استعمال کریں؟"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"اسکرین پننگ ڈسپلے کو ایک واحد منظر میں مقفل کر دیتی ہے۔\n\nخارج ہونے کیلئے، پیچھے اور حالیہ کو ایک ہی وقت میں ٹچ کریں اور دبائے رکھیں۔"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"اسکرین پننگ ڈسپلے کو ایک واحد منظر میں مقفل کر دیتی ہے۔\n\nخارج ہونے کیلئے، حالیہ کو ٹچ کریں اور دبائے رکھیں۔"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"نہیں، شکریہ"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"شروع کریں"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"غیر مقفل کرنے کا پیٹرن"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"پاس ورڈ"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"اسکرین کو پن کر دیا گیا"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"اسکرین کا پن ہٹا دیا گیا"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"‏پن ہٹانے سے پہلے PIN طلب کریں"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"پن ہٹانے سے پہلے غیر مقفل کرنے کا پیٹرن طلب کریں"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"پن ہٹانے سے پہلے پاس ورڈ طلب کریں"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"بیٹری کی میعاد بہتر بنانے میں مدد کرنے کیلئے، بیٹری سیور آپ کے آلہ کی کارکردگی میں تخفیف کر دیتی ہے اور وائبریشن اور پس منظر کے زیادہ تر ڈیٹا کو محدود کر دیتی ہے۔ ای میل، پیغام رسانی اور مطابقت پذیری پر انحصار کرنے والی دیگر ایپس ممکن ہے اس وقت تک اپ ڈیٹ نہ ہوں جب تک آپ انہیں نہ کھولیں۔\n\nآپ کا آلہ چارج ہوتے وقت بیٹری سیور خود بخود آف ہو جاتی ہے۔"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"<xliff:g id="FORMATTEDTIME">%1$s</xliff:g> پر آپ کا آخری وقت ختم ہونے تک"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"ایک منٹ کیلئے"</item>
+    <item quantity="other" msgid="6924190729213550991">"‏%d منٹ کیلئے"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"ایک گھنٹے کیلئے"</item>
+    <item quantity="other" msgid="5408537517529822157">"‏%d گھنٹوں کیلئے"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"غیر متعینہ"</string>
 </resources>
diff --git a/core/res/res/values-uz-rUZ/strings.xml b/core/res/res/values-uz-rUZ/strings.xml
index 206b2fc5..a8b55d0 100644
--- a/core/res/res/values-uz-rUZ/strings.xml
+++ b/core/res/res/values-uz-rUZ/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Foydalanuvchiga masofaviy ekranning yuqori darajali interfeysini bog‘lash imkonini beradi. Oddiy dasturlar uchun hech qachon kerak bo‘lmaydi."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"vidjet xizmatiga bog‘lash"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Ilova vidjetlar xizmatining yuqori darajali interfeysiga ulanishi mumkin. Oddiy ilovalar uchun talab qilinmaydi."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"yo‘nalish taqdim etuvchilarning serveriga bog‘lanish"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Ilova ro‘yxatdan o‘tgan shartlarni taqdim etuvchilarning serveriga ulanishi mumkin. Oddiy ilovalar uchun talab qilinmaydi."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"administrator bilan kelishib harakat qilish"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Ilova qurilma administratoriga maqsadlarni yuborishi mumkin. Oddiy ilovalar uchun talab qilinmaydi."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"TV-kiritishga ulanish"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"telefonni o‘chirish/yoqish"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Ilova planshetni yoqishi yoki o‘chirishi mumkin."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Ilova telefonni yoqishi yoki o‘chirishi mumkin."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"ekranning tanaffus vaqtini o‘zgartirish"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Ilovaga ekranning tanaffus vaqtini o‘zgartirish uchun ruxsat beradi."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"ishlab chiqarish sinovi usulida ishga tushirish"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Past darajadagi ishlab chiqarish sinovi usuli ishga tushirilganda, planshetga butunlay kirish imkonini beradi. Faqatgina planshet ishlab chiqarish sinovi usulida ishga tushirilgandagina buni amalga oshirish mumkin."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Past darajadagi ishlab chiqaruvchi sinovi usulida ishga tushirish. Telefon faqatgina ishlab chiqaruvchi sinovi usulida ishga tushirilgandagina mavjud bo‘ladi."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Ilova kesh fayl tizimini o‘qishi va unga yozishi mumkin."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"SIP qo‘ng‘iroqlarini amalga oshirish/qabul qilish"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ilovaga SIP qo‘ng‘iroqlarini amalga oshirish va qabul qilish uchun ruxsat beradi."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"kiruvchi qo‘ng‘iroq ekrani bilan ishlash"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Dasturga kirish qo‘ng‘irog‘ini  foydalanuvchi qachon va qanday ko‘rishini boshqarishga ruxsat beradi."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"suhbat vaqtida ekranni boshqarish"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Ilova suhbat vaqtida ekranni boshqarishi mumkin."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"telefoniya xizmatlarini bilan aloqa qilish"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Ilovaga qo‘ng‘iroqlarni amalga oshirish/qabul qilish uchun telefoniya xizmatlari bilan aloqa qilishga ruxsat beradi."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"suhbat vaqtida foydalanuvchi bilan aloqa qilish"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Ilova suhbat vaqtida foydalanuvchi bilan aloqa qilishi mumkin."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"tarixiy tarmoq sarfi ma‘lumotlarini o‘qish"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Ilova muayyan tarmoqlardan va ilovalardan foydalanish tarixini o‘qishi mumkin."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"tarmoq siyosatini boshqarish"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Foydalanuvchiga bildirishnomani eshituvchi xizmat yuqori darajali interfeysini bog‘lash imkonini beradi. Oddiy dasturlar uchun hech qachon kerak bo‘lmaydi."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"shartlarni taqdim etuvchilarning serveriga ulanish"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Ilova shartlarni taqdim etuvchining yuqori darajali interfeysiga ulanishi mumkin. Oddiy ilovalar uchun talab qilinmaydi."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"media fayllarni uzatish vositasiga bog‘lab qo‘yish"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Media fayllarni uzatishning yuqori darajali vositasiga bog‘lab qo‘yish. Oddiy ilovalar uchun talab qilinmaydi."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"Ekran lavhalari xizmatiga ulanish"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Ekran lavhalari xizmatining yuqori darajali interfeysiga ulanish. Oddiy ilovalar tomonidan ishlatilmaydi."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"aloqa operatorining sozlash dasturini so‘rash"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"“%1$s” orqali ulashish"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Uy dasturini tanlang"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Ushbu amaldan standart sifatida foydalanish"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Boshqa ilovadan foydalanish"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Birlamchi sozlamalarni Tizim sozlamalari &gt; Ilovalar &gt; Yuklab olingan menyusidan tozalang."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Amalni tanlash"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"USB qurilma uchun ilovani tanlang"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Ruxsat berish"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Rad qilish"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;ga xabar jo‘natishni xohlaydi."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Bu telefon hisobingizda "<font fgcolor="#ffffb060">"pul yechib olinishiga"</font>" sabab bo‘lishi mumkin."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Bu telefondagi hisobingizdan pul yechib olinishiga sabab bo‘lishi mumkin."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Bunda, mobil hisobingizdan "<b>"to‘lov olinishi mumkin"</b>"."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Bunda, mobil hisobingizdan to‘lov olinishi mumkin."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Jo‘natish"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Bekor qilish"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Tanlovim eslab qolinsin"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"USB orqali sozlashni o‘chirib qo‘yish uchun bosing."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Klaviaturani o‘zgartirish"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Klaviaturani tanlash"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Tashqi tugmatag"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Kiritish usulini ko‘rish"</string>
     <string name="hardware" msgid="7517821086888990278">"Qurilma"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Tugmalar tartibini tanlash"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Tugmalar tartibini tanlash uchun bosing."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Ilova ishonchli agentlar xizmatiga ulanishi mumkin."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Tizimni yangilash va tiklashni birgalikda amalga oshirish"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Dasturga tizimni tiklash va yangilash imkoniyatlari bilan ishlash uchun ruxsat beradi."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Kontentni translatsiya qilish seanslarini yaratish"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Ilovaga kontentni translatsiya qilish seanslarini yaratish uchun ruxsat beradi. Ushbu seanslar yordamida ilovalar qurilma ekranidagi tasvirlar va audio kontentda foydalanish huquqini qo‘lga kiritadi. Oddiy ilovalar uchun talab qilinmaydi."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Media fayllarni proyektorga uzatish seanslarini boshqarish"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Ilovaga media fayllarni proyektorga uzatish seanslarini boshqarish uchun ruxsat beradi. Ushbu seanslar yordamida ilovalar ekrandagi va audio kontentlarni yozib olishi mumkin bo‘ladi. Oddiy ilovalar uchun talab qilinmaydi."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"O‘rnatilgan seanslarni o‘qish"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Ilovaga o‘rnatilgan seanslarni o‘qish uchun ruxsat beradi. Bu unga faol paket o‘rnatmalari haqidagi ma’lumotlarni ko‘rish imkonini beradi."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Masshtabni o‘zgartirish uchun ikki marta bosing"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Rad qilish"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Ruxsat so‘raldi"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> hisobi uchun\nruxsat so‘raldi"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Siz ushbu ilovadan shaxsiy hududingizda foydalanmoqdasiz"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Siz ushbu ilovadan ishchi hududingizda foydalanmoqdasiz"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Siz ushbu ilovadan ishchi profilingizdan tashqarida foydalanmoqdasiz"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Siz ushbu ilovadan ishchi profilingizda foydalanmoqdasiz"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Kiritish uslubi"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Sinx"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Qulaylik"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Soatni kamaytirish"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"PM o‘rnatish"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"AM o‘rnatish"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"TK"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"TO"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Oyni ko‘paytirish"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Oyni kamaytirish"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Kunni ko‘paytirish"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Tahrirlash"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Ma’lumotlardan foydalanish ogohlantirilishi"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Trafik sarfi va sozlamalarni ko‘rish uchun bosing."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G/3G internet o‘chirib qo‘yildi"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G internet o‘chirib qo‘yildi"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Mobil internet o‘chirib qo‘yildi"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi internet o‘chirib qo‘yildi"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Chegaraga yetib keldi"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G trafik chekloviga yetdi"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G trafik chekloviga yetdi"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Mobil internet chekloviga yetdi"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Wi-Fi internet chekloviga yetdi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Mobil internet o‘chirib qo‘yildi"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"2G-3G ma’lumot cheklovdan o‘tdi"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"4G ma’lumot cheklovdan o‘tdi"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Mob. trafik cheg-dan oshib ketdi"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Qo‘ng‘iroqni qabul qilasizmi?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Har doim"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Bir marta"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ishchi profilni qo‘llab-quvvatlamaydi."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"“%1$s” ishchi profilni qo‘llab-quvvatlamaydi"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Planshet"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Telefon"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Quloq karnaychalari"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Imkoniyatlar yoqilgan."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Qulaylik bekor qilindi."</string>
     <string name="user_switched" msgid="3768006783166984410">"Joriy foydalanuvchi <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Quyidagi foydalanuvchiga o‘tilmoqda: <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Egasi"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Xato"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Ushbu o‘zgarishni amalga oshirish uchun administrator ruxsat bermagan"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"<xliff:g id="ITEM">%1$s</xliff:g> tanlandi"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> o‘chirildi"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Ish <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Ushbu ekranni bo‘shatish uchun “Orqaga” va “Yaqinda ishlatilganlar” tugmalarini bir vaqtda bosib turing."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Ushbu ekranni bo‘shatish uchun “Yaqinda ishlatilganlar” tugmasini bosib turing."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Ekran qadab qo‘yildi. Uni bo‘shatishga tashkilotingiz ruxsat bermagan."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Ekranni qadab qo‘yish funksiyasidan foydalanilsinmi?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ekranni qadab qo‘yish funksiyasi ekranni faqat bitta narsa ko‘rinadigan bo‘lib qulflaydi.\n\nChiqish uchun “Orqaga” va “Yaqinda ishlatilganlar” tugmalarini bir vaqtda bosib turing."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ekranni qadab qo‘yish funksiyasi ekranni faqat bitta narsa ko‘rinadigan bo‘lib qulflaydi.\n\nChiqish uchun “Yaqinda ishlatilganlar” tugmasini bosib turing."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"YO‘Q, KERAK EMAS"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"ISHGA TUSHIRISH"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN kod"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"qulfdan chiqarish chizmasi"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"parol"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Ekran qadab qo‘yildi"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Ekran bo‘shatildi"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Bo‘shatishdan oldin PIN kod so‘ralsin"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Bo‘shatishdan oldin chizmali parol so‘ralsin"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Bo‘shatishdan oldin parol so‘ralsin"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Batareya quvvatini uzoqroq vaqtga yetkazish uchun quvvat tejash funksiyasi qurilmangiz unumdorligini kamaytiradi hamda uning tebranishi va orqa fonda internetdan foydalanishni cheklaydi. Sinxronlanib turishi lozim bo‘lgan e-pochta, xabar almashinuv va boshqa ilovalar esa ishga tushirilmaguncha yangilanmaydi.\n\nQurilmani quvvat oldirish uchun energiya manbayiga ulashingiz bilanoq, quvvat tejash funksiyasi avtomatik tarzda o‘chadi."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Tanaffus vaqti tugaguncha – <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 daqiqa"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d daqiqa"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 soat"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d soat"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Uzluksiz ravishda"</string>
 </resources>
diff --git a/core/res/res/values-vi/strings.xml b/core/res/res/values-vi/strings.xml
index 7428d89..5ce45d5 100644
--- a/core/res/res/values-vi/strings.xml
+++ b/core/res/res/values-vi/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của màn hình từ xa. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"liên kết với dịch vụ tiện ích con"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của dịch vụ tiện ích con. Không cần thiết cho các ứng dụng thông thường."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"liên kết với dịch vụ nhà cung cấp định tuyến"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Cho phép chủ sở hữu liên kết với bất kỳ nhà cung cấp định tuyến đã đăng ký nào. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"tương tác với quản trị viên thiết bị"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Cho phép chủ sở hữu gửi các ý định đến quản trị viên thiết bị. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"liên kết với đầu vào TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"bật hoặc tắt điện thoại"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Cho phép ứng dụng bật hoặc tắt máy tính bảng."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Cho phép ứng dụng bật hoặc tắt điện thoại."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"đặt lại thời gian chờ hiển thị"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Cho phép ứng dụng đặt lại thời gian chờ hiển thị."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"chạy ở chế độ thử nghiệm trong nhà máy"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Chạy dưới dạng thử nghiệm nhà máy cấp thấp, cho phép quyền truy cập hoàn toàn vào phần cứng máy tính bảng. Chỉ khả dụng khi máy tính bảng chạy ở chế độ thử nghiệm trong nhà máy."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Chạy dưới dạng thử nghiệm nhà máy cấp thấp, cho phép quyền truy cập hoàn toàn vào phần cứng điện thoại. Chỉ khả dụng khi điện thoại chạy ở chế độ thử nghiệm trong nhà máy."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Cho phép ứng dụng đọc và ghi hệ thống tệp bộ nhớ cache."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"thực hiện/nhận các cuộc gọi qua SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Cho phép ứng dụng thực hiện và nhận các cuộc gọi qua SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"tương tác với màn hình trong cuộc gọi"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Cho phép ứng dụng kiểm soát thời gian và cách người dùng nhìn thấy màn hình trong cuộc gọi."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"tương tác với màn hình trong cuộc gọi"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Cho phép ứng dụng kiểm soát thời gian và cách người dùng nhìn thấy màn hình trong cuộc gọi."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"tương tác với dịch vụ điện thoại"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Cho phép ứng dụng tương tác với dịch vụ điện thoại để thực hiện/nhận cuộc gọi."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"cung cấp trải nghiệm người dùng trong cuộc gọi"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Cho phép ứng dụng cung cấp trải nghiệm người dùng trong cuộc gọi."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"đọc quá trình sử dụng mạng trước đây"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Cho phép ứng dụng đọc thông tin lịch sử sử dụng mạng của các mạng và ứng dụng cụ thể."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"quản lý chính sách mạng"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của dịch vụ trình xử lý thông báo. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"liên kết với dịch vụ trình cung cấp điều kiện"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của dịch vụ trình cung cấp điều kiện. Không cần thiết cho các ứng dụng thông thường."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"liên kết với dịch vụ định tuyến phương tiện"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của dịch vụ định tuyến phương tiện. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"liên kết với dịch vụ dream"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Cho phép chủ sở hữu liên kết với giao diện cấp cao nhất của dịch vụ dream. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"gọi ra ứng dụng cấu hình do nhà cung cấp dịch vụ cung cấp"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Chia sẻ với %1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Chọn ứng dụng gia đình"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Sử dụng theo mặc định đối với tác vụ này."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Sử dụng một ứng dụng khác"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Xóa mặc định trong Cài đặt hệ thống &gt; Ứng dụng &gt; Đã tải xuống."</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Chọn một tác vụ"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Chọn ứng dụng cho thiết bị USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Cho phép"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Từ chối"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; muốn gửi thư đến &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Điều này "<font fgcolor="#ffffb060">"có thể gây ra các khoản phí"</font>" đối với tài khoản di động của bạn."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Điều này sẽ gây ra các khoản phí đối với tài khoản di động của bạn."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Điều này "<b>"có thể gây ra các khoản phí"</b>" đối với tài khoản di động của bạn."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Điều này sẽ gây ra các khoản phí đối với tài khoản di động của bạn."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Gửi"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Hủy"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Nhớ lựa chọn của tôi"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Chạm để vô hiệu hóa gỡ lỗi USB."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Thay đổi bàn phím"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Chọn bàn phím"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Bàn phím thực"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Hiển thị phương thức nhập"</string>
     <string name="hardware" msgid="7517821086888990278">"Phần cứng"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Chọn bố cục bàn phím"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Chạm để chọn bố cục bàn phím."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Cho phép ứng dụng liên kết với một dịch vụ của tác nhân đáng tin cậy."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Tương tác với hệ thống khôi phục và bản cập nhật"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Cho phép ứng dụng tương tác với hệ thống khôi phục và bản cập nhật hệ thống."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Tạo phiên chiếu phương tiện"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Cho phép ứng dụng tạo các phiên chiếu phương tiện. Các phiên này có thể cấp cho ứng dụng khả năng chụp màn hình và ghi nội dung âm thanh. Không cần thiết cho các ứng dụng thông thường."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Quản lý phiên chiếu phương tiện"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Cho phép ứng dụng quản lý các phiên chiếu phương tiện. Các phiên này có thể cấp cho ứng dụng khả năng chụp màn hình và ghi nội dung âm thanh. Không cần thiết cho các ứng dụng thông thường."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Đọc phiên cài đặt"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Cho phép ứng dụng đọc phiên cài đặt. Thao tác này sẽ cho phép ứng dụng xem chi tiết về gói cài đặt đang hoạt động."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Chạm hai lần để kiểm soát thu phóng"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Từ chối"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Đã yêu cầu quyền"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Đã yêu cầu quyền\ncho tài khoản <xliff:g id="ACCOUNT">%s</xliff:g>."</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Bạn đang sử dụng ứng dụng này trong vùng cá nhân của mình"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Bạn đang sử dụng ứng dụng này trong vùng làm việc của mình"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Bạn đang sử dụng ứng dụng này bên ngoài hồ sơ công việc của mình"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Bạn đang sử dụng ứng dụng này trong hồ sơ công việc của mình"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Phương thức nhập"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Đồng bộ hóa"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Khả năng truy cập"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Giảm giờ"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Đặt CH"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Đặt SA"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"CH"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"SA"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Tăng tháng"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Giảm tháng"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Tăng ngày"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Chỉnh sửa"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Cảnh báo sử dụng dữ liệu"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Chạm để xem sử dụng và cài đặt."</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Dữ liệu 2G-3G bị tắt"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Dữ liệu 4G bị tắt"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Dữ liệu di động bị tắt"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Dữ liệu Wi-Fi bị tắt"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Đã đạt giới hạn"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"Đã đạt tới giới hạn dữ liệu 2G-3G"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"Đã đạt tới giới hạn dữ liệu 4G"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Đã đạt tới giới hạn dữ liệu di động"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Đã đạt tới g.hạn dữ liệu Wi-Fi"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Dữ liệu bị tạm ngừng trong phần còn lại của chu kỳ"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"Đã vượt quá g.hạn dữ liệu 2G-3G"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Đã vượt quá giới hạn dữ liệu 4G"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Đã vượt quá giới hạn dữ liệu DĐ"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Chấp nhận cuộc gọi?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Luôn chọn"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Chỉ một lần"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s không hỗ trợ hồ sơ công việc."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s không hỗ trợ hồ sơ công việc"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Máy tính bảng"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Điện thoại"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Tai nghe"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Trợ năng đã được bật."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Đã hủy trợ năng."</string>
     <string name="user_switched" msgid="3768006783166984410">"Người dùng hiện tại <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Đang chuyển sang <xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Chủ sở hữu"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Lỗi"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Quản trị viên của bạn không cho phép thực hiện thay đổi này"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"Đã chọn <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"Đã xóa <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"<xliff:g id="LABEL">%1$s</xliff:g> làm việc"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Để bỏ ghim màn hình này, hãy chạm và giữ Quay lại và Gần đây đồng thời."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Để bỏ ghim màn hình này, hãy chạm và giữ Gần đây."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Màn hình đã được ghim. Tổ chức của bạn không cho phép bỏ ghim."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Sử dụng ghim màn hình?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ghim màn hình sẽ khóa màn hình ở một chế độ xem.\n\nĐể thoát, hãy chạm và giữ Quay lại và Gần đây đồng thời."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ghim màn hình sẽ khóa màn hình ở một chế độ xem.\n\nĐể thoát, hãy chạm và giữ Gần đây."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"KHÔNG, CẢM ƠN"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"BẮT ĐẦU"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"Mã PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"hình mở khóa"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"mật khẩu"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Đã ghim màn hình"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Đã bỏ ghim màn hình"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Hỏi mã PIN trước khi bỏ ghim"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Hỏi hình mở khóa trước khi bỏ ghim"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Hỏi mật khẩu trước khi bỏ ghim"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Để giúp tăng tuổi thọ pin, trình tiết kiệm pin sẽ giảm hiệu suất thiết bị của bạn và hạn chế chế rung và hầu hết dữ liệu nền. Email, nhắn tin và các ứng dụng khác dựa trên đồng bộ hóa không thể cập nhật trừ khi bạn mở chúng.\n\nTrình tiết kiệm pin tự động tắt khi thiết bị của bạn đang sạc."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Cho tới khi thời gian ngừng hoạt động của bạn kết thúc vào <xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Trong một phút"</item>
+    <item quantity="other" msgid="6924190729213550991">"Trong %d phút"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Trong một giờ"</item>
+    <item quantity="other" msgid="5408537517529822157">"Trong %d giờ"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Không giới hạn"</string>
 </resources>
diff --git a/core/res/res/values-zh-rCN/strings.xml b/core/res/res/values-zh-rCN/strings.xml
index 557f709..9549df1 100644
--- a/core/res/res/values-zh-rCN/strings.xml
+++ b/core/res/res/values-zh-rCN/strings.xml
@@ -54,14 +54,14 @@
     <string name="serviceErased" msgid="1288584695297200972">"清除成功。"</string>
     <string name="passwordIncorrect" msgid="7612208839450128715">"密码不正确。"</string>
     <string name="mmiComplete" msgid="8232527495411698359">"MMI 码已完成。"</string>
-    <string name="badPin" msgid="9015277645546710014">"您输入的旧 PIN 不正确。"</string>
+    <string name="badPin" msgid="9015277645546710014">"您输入的旧PIN码不正确。"</string>
     <string name="badPuk" msgid="5487257647081132201">"您输入的PUK码不正确。"</string>
-    <string name="mismatchPin" msgid="609379054496863419">"您输入的 PIN 码不一致。"</string>
-    <string name="invalidPin" msgid="3850018445187475377">"输入一个 4 至 8 位数的 PIN 码。"</string>
+    <string name="mismatchPin" msgid="609379054496863419">"您输入的PIN码不一致。"</string>
+    <string name="invalidPin" msgid="3850018445187475377">"输入一个4至8位数的PIN码。"</string>
     <string name="invalidPuk" msgid="8761456210898036513">"请输入至少8位数字的PUK码。"</string>
-    <string name="needPuk" msgid="919668385956251611">"已对SIM卡进行PUK码锁定。键入PUK码将其解锁。"</string>
+    <string name="needPuk" msgid="919668385956251611">"已对SIM卡进行PUK码锁定。请输入PUK码将其解锁。"</string>
     <string name="needPuk2" msgid="4526033371987193070">"输入PUK2码以解锁SIM卡。"</string>
-    <string name="enablePin" msgid="209412020907207950">"失败,请启用SIM/RUIM 卡锁定设置。"</string>
+    <string name="enablePin" msgid="209412020907207950">"失败,请开启SIM/RUIM卡锁定设置。"</string>
   <plurals name="pinpuk_attempts">
     <item quantity="one" msgid="6596245285809790142">"您还有<xliff:g id="NUMBER">%d</xliff:g>次尝试机会。如果仍然失败,SIM卡将被锁定。"</item>
     <item quantity="other" msgid="7530597808358774740">"您还有<xliff:g id="NUMBER">%d</xliff:g>次尝试机会。如果仍然失败,SIM卡将被锁定。"</item>
@@ -76,7 +76,7 @@
     <string name="CwMmi" msgid="9129678056795016867">"来电等待"</string>
     <string name="BaMmi" msgid="455193067926770581">"呼叫限制"</string>
     <string name="PwdMmi" msgid="7043715687905254199">"密码更改"</string>
-    <string name="PinMmi" msgid="3113117780361190304">"PIN 码更改"</string>
+    <string name="PinMmi" msgid="3113117780361190304">"PIN码更改"</string>
     <string name="CnipMmi" msgid="3110534680557857162">"显示号码"</string>
     <string name="CnirMmi" msgid="3062102121430548731">"来电显示受限制"</string>
     <string name="ThreeWCMmi" msgid="9051047170321190368">"三方通话"</string>
@@ -358,7 +358,7 @@
     <string name="permdesc_broadcastSmsReceived" msgid="4152037720034365492">"允许应用广播一条有关已收到短信的通知。恶意应用可能借此伪造接到的短信。"</string>
     <string name="permlab_broadcastWapPush" msgid="3145347413028582371">"发送 WAP-PUSH 收到的广播"</string>
     <string name="permdesc_broadcastWapPush" msgid="4783402525039442729">"允许应用广播一条有关已收到 WAP PUSH 短信的通知。恶意应用可能借此伪造短信接收,或在后台将任意网页的内容替换为恶意内容。"</string>
-    <string name="permlab_setProcessLimit" msgid="2451873664363662666">"限制运行的进程个数"</string>
+    <string name="permlab_setProcessLimit" msgid="2451873664363662666">"限制运行的进程数量"</string>
     <string name="permdesc_setProcessLimit" msgid="7318061314040879542">"允许应用控制将运行的进程数上限。普通应用绝不需要此权限。"</string>
     <string name="permlab_setAlwaysFinish" msgid="550958507798796965">"强制关闭后台应用"</string>
     <string name="permdesc_setAlwaysFinish" msgid="7471310652868841499">"允许应用控制活动在转入后台后是否立即结束。普通应用绝不需要此权限。"</string>
@@ -397,8 +397,8 @@
     <string name="permdesc_bindPrintService" msgid="7960067623209111135">"允许应用绑定至打印服务的顶级接口。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindPrintSpoolerService" msgid="6807762783744125954">"绑定至打印处理服务"</string>
     <string name="permdesc_bindPrintSpoolerService" msgid="3680552285933318372">"允许应用绑定至打印处理服务的顶级接口。普通应用绝不需要此权限。"</string>
-    <string name="permlab_bindNfcService" msgid="2752731300419410724">"绑定到 NFC 服务"</string>
-    <string name="permdesc_bindNfcService" msgid="6120647629174066862">"允许应用绑定到模拟 NFC 卡的应用。普通应用绝不需要此权限。"</string>
+    <string name="permlab_bindNfcService" msgid="2752731300419410724">"绑定到NFC服务"</string>
+    <string name="permdesc_bindNfcService" msgid="6120647629174066862">"允许应用绑定到模拟NFC卡的应用。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindTextService" msgid="7358378401915287938">"绑定至文字服务"</string>
     <string name="permdesc_bindTextService" msgid="8151968910973998670">"允许应用绑定至文本服务(如 SpellCheckerService)的顶级接口。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindVpnService" msgid="4708596021161473255">"绑定到VPN服务"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"允许应用绑定至远程显示屏的顶级接口。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"绑定到小部件服务"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"允许应用绑定到小部件服务的顶级接口。普通应用绝不需要此权限。"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"绑定到路由程序服务"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"允许应用绑定到任何已注册的路由程序。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"与设备管理器交互"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"允许应用向设备管理器发送Intent。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"绑定至电视输入设备"</string>
@@ -531,8 +529,8 @@
     <string name="permdesc_captureAudioOutput" msgid="6210597754212208853">"允许该应用捕获和重定向音频输出。"</string>
     <string name="permlab_captureAudioHotword" msgid="1890553935650349808">"启动指令检测"</string>
     <string name="permdesc_captureAudioHotword" msgid="9151807958153056810">"允许应用捕获音频以便检测语音启动指令。捕获操作会在后台进行,但不会妨碍其他音频捕获工具(例如摄像机)。"</string>
-    <string name="permlab_modifyAudioRouting" msgid="7738060354490807723">"音频路由"</string>
-    <string name="permdesc_modifyAudioRouting" msgid="7205731074267199735">"允许应用直接控制音频路由以及覆盖音频规范决策。"</string>
+    <string name="permlab_modifyAudioRouting" msgid="7738060354490807723">"音频转接"</string>
+    <string name="permdesc_modifyAudioRouting" msgid="7205731074267199735">"允许应用直接控制音频转接以及覆盖音频规范决策。"</string>
     <string name="permlab_captureVideoOutput" msgid="2246828773589094023">"捕获视频输出"</string>
     <string name="permdesc_captureVideoOutput" msgid="359481658034149860">"允许该应用捕获和重定向视频输出。"</string>
     <string name="permlab_captureSecureVideoOutput" msgid="7815398969303382016">"捕获安全视频输出"</string>
@@ -579,8 +577,8 @@
     <string name="permdesc_flashlight" msgid="6522284794568368310">"允许应用控制闪光灯。"</string>
     <string name="permlab_manageUsb" msgid="1113453430645402723">"管理USB设备的偏好设置和权限"</string>
     <string name="permdesc_manageUsb" msgid="7776155430218239833">"允许应用管理针对USB设备的偏好设置和权限。"</string>
-    <string name="permlab_accessMtp" msgid="4953468676795917042">"应用 MTP 协议"</string>
-    <string name="permdesc_accessMtp" msgid="6532961200486791570">"允许访问内核 MTP 驱动程序,以便应用 MTPUSB协议。"</string>
+    <string name="permlab_accessMtp" msgid="4953468676795917042">"实现MTP协议"</string>
+    <string name="permdesc_accessMtp" msgid="6532961200486791570">"允许访问内核MTP驱动程序,以便实现MTP USB协议。"</string>
     <string name="permlab_hardware_test" msgid="4148290860400659146">"测试硬件"</string>
     <string name="permdesc_hardware_test" msgid="6597964191208016605">"允许应用控制各种外围设备以进行硬件测试。"</string>
     <string name="permlab_callPhone" msgid="3925836347681847954">"直接拨打电话号码"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"开机或关机"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"允许应用打开或关闭平板电脑。"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"允许应用打开或关闭手机。"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"重置显示屏超时"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"允许该应用重置显示屏超时。"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"在出厂测试模式下运行"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"作为低级制造商测试运行,从而允许对平板电脑硬件进行完全访问。此权限仅当平板电脑在制造商测试模式下运行时才可用。"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"作为一项低级制造商测试来运行,从而允许对手机硬件进行完全访问。此权限仅当手机在制造商测试模式下运行时才可用。。"</string>
@@ -621,7 +621,7 @@
     <string name="permlab_setWallpaperHints" msgid="3278608165977736538">"调整您的壁纸大小"</string>
     <string name="permdesc_setWallpaperHints" msgid="8235784384223730091">"允许应用设置有关系统壁纸大小的提示。"</string>
     <string name="permlab_masterClear" msgid="2315750423139697397">"将系统恢复为出厂设置"</string>
-    <string name="permdesc_masterClear" msgid="3665380492633910226">"允许应用将系统完全重置为其出厂设置,这会清除所有数据、配置和已安装的应用。"</string>
+    <string name="permdesc_masterClear" msgid="3665380492633910226">"允许应用将系统完全恢复为出厂设置,这会清除所有数据、配置和已安装的应用。"</string>
     <string name="permlab_setTime" msgid="2021614829591775646">"设置时间"</string>
     <string name="permdesc_setTime" product="tablet" msgid="1896341438151152881">"允许应用更改平板电脑的时间。"</string>
     <string name="permdesc_setTime" product="default" msgid="1855702730738020">"允许应用更改手机的时间。"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"允许应用读取和写入缓存文件系统。"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"拨打/接听SIP电话"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"允许该应用拨打和接听SIP电话。"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"与通话屏幕互动"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"允许应用控制用户看到通话屏幕的时机和方式。"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"与通话屏幕互动"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"允许应用控制用户看到通话屏幕的时机和方式。"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"与电话服务交互"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"允许该应用与电话服务交互以便接打电话。"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"向用户提供通话体验"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"允许应用向用户提供通话体验。"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"读取网络使用情况历史记录"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"允许应用读取特定网络和应用的网络使用情况历史记录。"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"管理网络政策"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"允许应用绑定到通知侦听器服务的顶级接口(普通应用绝不需要此权限)。"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"绑定到条件提供程序服务"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"允许应用绑定到条件提供程序服务的顶级接口。普通应用绝不需要此权限。"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"绑定至媒体路由服务"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"允许应用绑定至媒体路由服务的顶级接口。普通应用绝不需要此权限。"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"绑定到互动屏保服务"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"允许应用绑定到互动屏保服务的顶级接口。普通应用绝不需要此权限。"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"调用运营商提供的配置应用"</string>
@@ -884,14 +882,14 @@
     <string name="sipAddressTypeWork" msgid="6920725730797099047">"单位"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"其他"</string>
     <string name="quick_contacts_not_available" msgid="746098007828579688">"找不到可用来查看此联系人的应用。"</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"输入 PIN 码"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"输入PIN码"</string>
     <string name="keyguard_password_enter_puk_code" msgid="4800725266925845333">"请输入PUK码和新的PIN码"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1341112146710087048">"PUK码"</string>
-    <string name="keyguard_password_enter_pin_prompt" msgid="8027680321614196258">"新的 PIN 码"</string>
+    <string name="keyguard_password_enter_pin_prompt" msgid="8027680321614196258">"新的PIN码"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"触摸可输入密码"</font></string>
     <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"输入密码以解锁"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"输入 PIN 进行解锁"</string>
-    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"PIN 码有误。"</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"输入PIN码进行解锁"</string>
+    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"PIN码有误。"</string>
     <string name="keyguard_label_text" msgid="861796461028298424">"要解锁,请先按 MENU 再按 0。"</string>
     <string name="emergency_call_dialog_number_for_display" msgid="696192103195090970">"急救或报警电话"</string>
     <string name="lockscreen_carrier_default" msgid="8963839242565653192">"无服务。"</string>
@@ -927,17 +925,17 @@
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"网络已锁定"</string>
     <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"SIM卡已用PUK码锁定。"</string>
     <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"请参阅《用户指南》或与客服人员联系。"</string>
-    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"SIM卡被锁定"</string>
+    <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"SIM卡已被锁定。"</string>
     <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"正在解锁SIM卡..."</string>
     <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
     <string name="lockscreen_too_many_failed_password_attempts_dialog_message" msgid="2725973286239344555">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了密码。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
-    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了 PIN。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
+    <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次输错了PIN码。\n\n请在<xliff:g id="NUMBER_1">%d</xliff:g>秒后重试。"</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地绘制了解锁图案。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,系统就会要求您使用自己的Google登录信息解锁平板电脑。\n\n请在<xliff:g id="NUMBER_2">%d</xliff:g>秒后重试。"</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地绘制了解锁图案。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,系统会要求您使用自己的Google登录信息解锁手机。\n\n请在<xliff:g id="NUMBER_2">%d</xliff:g>秒后重试。"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁平板电脑。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,平板电脑将重置为出厂默认设置,所有用户数据将会丢失。"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁手机。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,手机将重置为出厂默认设置,所有用户数据将会丢失。"</string>
-    <string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁平板电脑。平板电脑现在将重置为出厂默认设置。"</string>
-    <string name="lockscreen_failed_attempts_now_wiping" product="default" msgid="3025504721764922246">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁手机。手机现在将重置为出厂默认设置。"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁平板电脑。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,平板电脑将恢复为出厂默认设置,所有用户数据将会丢失。"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁手机。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,手机将恢复为出厂默认设置,所有用户数据将会丢失。"</string>
+    <string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁平板电脑。平板电脑现在将恢复为出厂默认设置。"</string>
+    <string name="lockscreen_failed_attempts_now_wiping" product="default" msgid="3025504721764922246">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁手机。手机现在将恢复为出厂默认设置。"</string>
     <string name="lockscreen_too_many_failed_attempts_countdown" msgid="6251480343394389665">"<xliff:g id="NUMBER">%d</xliff:g>秒后重试。"</string>
     <string name="lockscreen_forgot_pattern_button_text" msgid="2626999449610695930">"忘记了图案?"</string>
     <string name="lockscreen_glogin_forgot_pattern" msgid="2588521501166032747">"帐户解锁"</string>
@@ -973,7 +971,7 @@
     <string name="keyguard_accessibility_slide_unlock" msgid="2959928478764697254">"滑动解锁。"</string>
     <string name="keyguard_accessibility_pattern_unlock" msgid="1490840706075246612">"图案解锁。"</string>
     <string name="keyguard_accessibility_face_unlock" msgid="4817282543351718535">"人脸解锁。"</string>
-    <string name="keyguard_accessibility_pin_unlock" msgid="2469687111784035046">"PIN 解锁。"</string>
+    <string name="keyguard_accessibility_pin_unlock" msgid="2469687111784035046">"PIN码解锁。"</string>
     <string name="keyguard_accessibility_password_unlock" msgid="7675777623912155089">"密码解锁。"</string>
     <string name="keyguard_accessibility_pattern_area" msgid="7679891324509597904">"图案区域。"</string>
     <string name="keyguard_accessibility_slide_area" msgid="6736064494019979544">"滑动区域。"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"使用%1$s分享"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"选择主屏幕应用"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"设为默认选项。"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"使用其他应用"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"在“系统设置”&gt;“应用”&gt;“已下载”中清除默认设置。"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"选择操作"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"为USB设备选择一个应用"</string>
@@ -1213,14 +1212,14 @@
     <string name="aerr_application" msgid="932628488013092776">"很抱歉,“<xliff:g id="APPLICATION">%1$s</xliff:g>”已停止运行。"</string>
     <string name="aerr_process" msgid="4507058997035697579">"抱歉,进程“<xliff:g id="PROCESS">%1$s</xliff:g>”已停止运行。"</string>
     <string name="anr_title" msgid="4351948481459135709"></string>
-    <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g> 无响应。\n\n要将其关闭吗?"</string>
-    <string name="anr_activity_process" msgid="5776209883299089767">"<xliff:g id="ACTIVITY">%1$s</xliff:g> 活动无响应。\n\n要将其关闭吗?"</string>
-    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g> 无响应。要将其关闭吗?"</string>
-    <string name="anr_process" msgid="6513209874880517125">"<xliff:g id="PROCESS">%1$s</xliff:g> 进程无响应。\n\n要将其关闭吗?"</string>
+    <string name="anr_activity_application" msgid="1904477189057199066">"<xliff:g id="APPLICATION">%2$s</xliff:g>无响应。\n\n要将其关闭吗?"</string>
+    <string name="anr_activity_process" msgid="5776209883299089767">"<xliff:g id="ACTIVITY">%1$s</xliff:g>活动无响应。\n\n要将其关闭吗?"</string>
+    <string name="anr_application_process" msgid="8941757607340481057">"<xliff:g id="APPLICATION">%1$s</xliff:g>无响应。要将其关闭吗?"</string>
+    <string name="anr_process" msgid="6513209874880517125">"<xliff:g id="PROCESS">%1$s</xliff:g>进程无响应。\n\n要将其关闭吗?"</string>
     <string name="force_close" msgid="8346072094521265605">"确定"</string>
     <string name="report" msgid="4060218260984795706">"报告"</string>
     <string name="wait" msgid="7147118217226317732">"等待"</string>
-    <string name="webpage_unresponsive" msgid="3272758351138122503">"该网页已无响应。\n\n要将其关闭吗?"</string>
+    <string name="webpage_unresponsive" msgid="3272758351138122503">"该网页无响应。\n\n要将其关闭吗?"</string>
     <string name="launch_warning_title" msgid="1547997780506713581">"应用已重定向"</string>
     <string name="launch_warning_replace" msgid="6202498949970281412">"<xliff:g id="APP_NAME">%1$s</xliff:g>目前正在运行。"</string>
     <string name="launch_warning_original" msgid="188102023021668683">"<xliff:g id="APP_NAME">%1$s</xliff:g>已启动。"</string>
@@ -1230,7 +1229,7 @@
     <string name="smv_application" msgid="3307209192155442829">"“<xliff:g id="APPLICATION">%1$s</xliff:g>”应用(<xliff:g id="PROCESS">%2$s</xliff:g> 进程)违反了自我强制执行的严格模式 (StrictMode) 政策。"</string>
     <string name="smv_process" msgid="5120397012047462446">"进程 <xliff:g id="PROCESS">%1$s</xliff:g> 违反了自我强制执行的严格模式 (StrictMode) 政策。"</string>
     <string name="android_upgrading_title" msgid="1584192285441405746">"Android正在升级..."</string>
-    <string name="android_upgrading_apk" msgid="7904042682111526169">"正在优化第 <xliff:g id="NUMBER_0">%1$d</xliff:g> 个应用(共 <xliff:g id="NUMBER_1">%2$d</xliff:g> 个)。"</string>
+    <string name="android_upgrading_apk" msgid="7904042682111526169">"正在优化第<xliff:g id="NUMBER_0">%1$d</xliff:g>个应用(共<xliff:g id="NUMBER_1">%2$d</xliff:g>个)。"</string>
     <string name="android_upgrading_starting_apps" msgid="451464516346926713">"正在启动应用。"</string>
     <string name="android_upgrading_complete" msgid="1405954754112999229">"即将完成启动。"</string>
     <string name="heavy_weight_notification" msgid="9087063985776626166">"<xliff:g id="APP">%1$s</xliff:g>正在运行"</string>
@@ -1286,8 +1285,8 @@
     <string name="wifi_p2p_invitation_to_connect_title" msgid="4958803948658533637">"连接邀请"</string>
     <string name="wifi_p2p_from_message" msgid="570389174731951769">"发件人:"</string>
     <string name="wifi_p2p_to_message" msgid="248968974522044099">"收件人:"</string>
-    <string name="wifi_p2p_enter_pin_message" msgid="5920929550367828970">"键入所需的 PIN:"</string>
-    <string name="wifi_p2p_show_pin_message" msgid="8530563323880921094">"PIN:"</string>
+    <string name="wifi_p2p_enter_pin_message" msgid="5920929550367828970">"输入所需的PIN码:"</string>
+    <string name="wifi_p2p_show_pin_message" msgid="8530563323880921094">"PIN码:"</string>
     <string name="wifi_p2p_frequency_conflict_message" product="tablet" msgid="8012981257742232475">"平板电脑连接到“<xliff:g id="DEVICE_NAME">%1$s</xliff:g>”时会暂时断开与WLAN的连接"</string>
     <string name="wifi_p2p_frequency_conflict_message" product="default" msgid="7363907213787469151">"手机连接到<xliff:g id="DEVICE_NAME">%1$s</xliff:g>时会暂时断开与WLAN的连接。"</string>
     <string name="select_character" msgid="3365550120617701745">"插入字符"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"允许"</string>
     <string name="sms_control_no" msgid="625438561395534982">"拒绝"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt;想要向 &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt; 发送一条短信。"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457"><font fgcolor="#ffffb060">"这可能会导致您的手机号产生费用。"</font></string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"这会导致您的手机号产生费用。"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400"><b>"这可能会导致您的手机号产生费用。"</b></string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"这会导致您的手机号产生费用。"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"发送"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"取消"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"记住我的选择"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"触摸可停用USB调试。"</string>
     <string name="select_input_method" msgid="8547250819326693584">"更改键盘"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"选择键盘"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"物理键盘"</string>
+    <string name="show_ime" msgid="9157568568695230830">"显示输入法"</string>
     <string name="hardware" msgid="7517821086888990278">"硬件"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"选择键盘布局"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"触摸可选择键盘布局。"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"允许应用绑定至信任的代理服务。"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"与更新和恢复系统互动"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"允许应用与恢复系统和系统更新互动。"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"创建媒体投影会话"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"允许应用创建媒体投影会话。这些会话可让应用截取显示内容和音频内容。普通应用绝不需要此权限。"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"管理媒体投影会话"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"允许应用管理媒体投影会话。这些会话可让应用截取显示内容和音频内容。普通应用绝不需要此权限。"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"读取安装会话"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"允许应用读取安装会话。这样,应用将可以查看有关当前软件包安装的详情。"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"触摸两次可进行缩放控制"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"拒绝"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"权限请求"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"应用对帐户 <xliff:g id="ACCOUNT">%s</xliff:g>\n 提出权限请求。"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"您目前是在个人空间内使用此应用"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"您目前是在工作空间内使用此应用"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"您目前是在工作资料之外使用此应用"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"您目前是在工作资料内使用此应用"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"输入法"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"同步"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"辅助功能"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"减小小时值"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"设置下午时间"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"设置上午时间"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"下午"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"上午"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"增大月份值"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"减小月份值"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"增大日期值"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"修改"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"流量警告"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"触摸可查看使用情况和设置。"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G数据网络已关闭"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G数据网络已关闭"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"移动数据网络已关闭"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"WLAN数据网络已关闭"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"已达到上限"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"已达到2G-3G流量上限"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"已达到4G流量上限"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"已达到移动数据流量上限"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"已达到WLAN流量上限"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"已暂停本周期剩余时间的流量使用"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"已超出 2G-3G 数据流量限制"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"已超出 4G 数据使用上限"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"已超出移动数据流量上限"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"要接听电话吗?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"始终"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"仅此一次"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s不支持工作资料。"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s不支持工作资料"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"平板电脑"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"手机"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"耳机"</string>
@@ -1604,21 +1601,21 @@
     <string name="kg_forgot_pattern_button_text" msgid="8852021467868220608">"忘记了图案"</string>
     <string name="kg_wrong_pattern" msgid="1850806070801358830">"图案错误"</string>
     <string name="kg_wrong_password" msgid="2333281762128113157">"密码错误"</string>
-    <string name="kg_wrong_pin" msgid="1131306510833563801">"PIN 有误"</string>
+    <string name="kg_wrong_pin" msgid="1131306510833563801">"PIN码有误"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"请在 <xliff:g id="NUMBER">%1$d</xliff:g> 秒后重试。"</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"绘制您的图案"</string>
     <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"输入SIM卡PIN码"</string>
-    <string name="kg_pin_instructions" msgid="2377242233495111557">"输入 PIN"</string>
+    <string name="kg_pin_instructions" msgid="2377242233495111557">"输入PIN码"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"输入密码"</string>
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM卡已被停用,需要输入PUK码才能继续使用。有关详情,请联系您的运营商。"</string>
-    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"请输入所需 PIN 码"</string>
-    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"请确认所需 PIN 码"</string>
+    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"请输入所需的PIN码"</string>
+    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"请确认所需的PIN码"</string>
     <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"正在解锁SIM卡..."</string>
-    <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"PIN 码有误。"</string>
-    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"请输入 4 至 8 位数的 PIN。"</string>
+    <string name="kg_password_wrong_pin_code" msgid="1139324887413846912">"PIN码有误。"</string>
+    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"请输入4至8位数的PIN码。"</string>
     <string name="kg_invalid_sim_puk_hint" msgid="6025069204539532000">"PUK码应包含8位数字。"</string>
     <string name="kg_invalid_puk" msgid="3638289409676051243">"请重新输入正确的PUK码。如果尝试错误次数过多,SIM卡将永久停用。"</string>
-    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN 码不匹配"</string>
+    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN码不匹配"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"图案尝试次数过多"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"要解锁,请登录您的Google帐户。"</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"用户名(电子邮件地址)"</string>
@@ -1627,13 +1624,13 @@
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"用户名或密码无效。"</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘记了用户名或密码?\n请访问 "<b>"google.com/accounts/recovery"</b>"。"</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"正在检查帐户…"</string>
-    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了 PIN。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
+    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次输错了PIN码。\n\n请在<xliff:g id="NUMBER_1">%d</xliff:g>秒后重试。"</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了密码。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁平板电脑。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,平板电脑就会重置为出厂默认设置,而且所有用户数据都会丢失。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁手机。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,手机就会重置为出厂默认设置,而且所有用户数据都会丢失。"</string>
-    <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁平板电脑。平板电脑现在将重置为出厂默认设置。"</string>
-    <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁手机。手机现在将重置为出厂默认设置。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地尝试解锁平板电脑。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,平板电脑就会恢复为出厂默认设置,而且所有用户数据都会丢失。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地尝试解锁手机。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,手机就会恢复为出厂默认设置,而且所有用户数据都会丢失。"</string>
+    <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁平板电脑。平板电脑现在将恢复为出厂默认设置。"</string>
+    <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁手机。手机现在将恢复为出厂默认设置。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="tablet" msgid="3253575572118914370">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,系统就会要求您使用自己的电子邮件帐户解锁平板电脑。\n\n请在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,系统就会要求您使用自己的电子邮件帐户解锁手机。\n\n请在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"辅助功能已启用。"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"已取消辅助功能。"</string>
     <string name="user_switched" msgid="3768006783166984410">"当前用户是<xliff:g id="NAME">%1$s</xliff:g>。"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"正在切换为<xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"机主"</string>
     <string name="error_message_title" msgid="4510373083082500195">"错误"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"您的管理员不允许进行此更改"</string>
@@ -1737,15 +1735,15 @@
     <string name="reason_service_unavailable" msgid="7824008732243903268">"未启用打印服务"</string>
     <string name="print_service_installed_title" msgid="2246317169444081628">"已安装“<xliff:g id="NAME">%s</xliff:g>”服务"</string>
     <string name="print_service_installed_message" msgid="5897362931070459152">"点按即可启用"</string>
-    <string name="restr_pin_enter_admin_pin" msgid="783643731895143970">"输入管理员 PIN 码"</string>
-    <string name="restr_pin_enter_pin" msgid="3395953421368476103">"输入 PIN 码"</string>
+    <string name="restr_pin_enter_admin_pin" msgid="783643731895143970">"输入管理员PIN码"</string>
+    <string name="restr_pin_enter_pin" msgid="3395953421368476103">"输入PIN码"</string>
     <string name="restr_pin_incorrect" msgid="8571512003955077924">"错误"</string>
-    <string name="restr_pin_enter_old_pin" msgid="1462206225512910757">"当前 PIN 码"</string>
-    <string name="restr_pin_enter_new_pin" msgid="5959606691619959184">"新 PIN 码"</string>
-    <string name="restr_pin_confirm_pin" msgid="8501523829633146239">"确认新 PIN 码"</string>
-    <string name="restr_pin_create_pin" msgid="8017600000263450337">"创建 PIN 码,防止他人修改限制条件"</string>
-    <string name="restr_pin_error_doesnt_match" msgid="2224214190906994548">"PIN 码不符,请重试。"</string>
-    <string name="restr_pin_error_too_short" msgid="8173982756265777792">"PIN 码太短,至少应包含 4 位数字。"</string>
+    <string name="restr_pin_enter_old_pin" msgid="1462206225512910757">"当前PIN码"</string>
+    <string name="restr_pin_enter_new_pin" msgid="5959606691619959184">"新PIN码"</string>
+    <string name="restr_pin_confirm_pin" msgid="8501523829633146239">"确认新PIN码"</string>
+    <string name="restr_pin_create_pin" msgid="8017600000263450337">"设置PIN码,防止他人修改限制条件"</string>
+    <string name="restr_pin_error_doesnt_match" msgid="2224214190906994548">"PIN码不符,请重试。"</string>
+    <string name="restr_pin_error_too_short" msgid="8173982756265777792">"PIN码太短,至少应包含4位数字。"</string>
   <plurals name="restr_pin_countdown">
     <item quantity="one" msgid="311050995198548675">"1秒后重试"</item>
     <item quantity="other" msgid="4730868920742952817">"<xliff:g id="COUNT">%d</xliff:g>秒后重试"</item>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"已选择<xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"已删除<xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"工作<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"要取消固定屏幕,请同时触摸并按住“返回”和“最近”按钮。"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"要取消固定屏幕,请触摸并按住“最近”按钮。"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"屏幕处于固定状态。您所属的单位不允许取消固定。"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"要固定屏幕吗?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"固定屏幕后,设备会一直显示某个屏幕。\n\n要取消固定,请同时触摸并按住“返回”和“最近”按钮。"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"固定屏幕后,设备会一直显示某个屏幕。\n\n要取消固定,请触摸并按住“最近”按钮。"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"不用了"</string>
-    <string name="lock_to_app_positive" msgid="7085139175671313864">"启动"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN码"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"解锁图案"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"密码"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_positive" msgid="7085139175671313864">"固定"</string>
+    <string name="lock_to_app_start" msgid="6643342070839862795">"已固定屏幕"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"已取消固定屏幕"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"取消时要求输入PIN码"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"取消时要求绘制解锁图案"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"取消时要求输入密码"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"为了延长电池的续航时间,节电助手会降低设备的性能,并限制振动和大部分后台流量。对于电子邮件、聊天工具等依赖于同步功能的应用,可能要打开这类应用时才能收到新信息。\n\n节电助手会在设备充电时自动关闭。"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"直到休息时间结束(<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>)"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1分钟"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d分钟"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1小时"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d小时"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"无限期"</string>
 </resources>
diff --git a/core/res/res/values-zh-rHK/strings.xml b/core/res/res/values-zh-rHK/strings.xml
index 1dfcad3..ca0e1b9 100644
--- a/core/res/res/values-zh-rHK/strings.xml
+++ b/core/res/res/values-zh-rHK/strings.xml
@@ -213,10 +213,10 @@
     <string name="permgroupdesc_affectsBattery" msgid="6441275320638916947">"使用可能大量耗電的功能。"</string>
     <string name="permgrouplab_calendar" msgid="5863508437783683902">"日曆"</string>
     <string name="permgroupdesc_calendar" msgid="5777534316982184416">"直接存取日曆和活動。"</string>
-    <string name="permgrouplab_dictionary" msgid="4148597128843641379">"讀取用戶字典"</string>
-    <string name="permgroupdesc_dictionary" msgid="7921166355964764490">"讀取用戶字典中的字詞。"</string>
-    <string name="permgrouplab_writeDictionary" msgid="8090237702432576788">"寫入用戶字典"</string>
-    <string name="permgroupdesc_writeDictionary" msgid="2711561994497361646">"將字詞加入用戶字典。"</string>
+    <string name="permgrouplab_dictionary" msgid="4148597128843641379">"讀取使用者字典"</string>
+    <string name="permgroupdesc_dictionary" msgid="7921166355964764490">"讀取使用者字典中的字詞。"</string>
+    <string name="permgrouplab_writeDictionary" msgid="8090237702432576788">"寫入使用者字典"</string>
+    <string name="permgroupdesc_writeDictionary" msgid="2711561994497361646">"將字詞加入使用者字典。"</string>
     <string name="permgrouplab_bookmarks" msgid="1949519673103968229">"書籤和記錄"</string>
     <string name="permgroupdesc_bookmarks" msgid="4169771606257963028">"直接存取書籤和瀏覽器紀錄。"</string>
     <string name="permgrouplab_deviceAlarms" msgid="6117704629728824101">"鬧鐘"</string>
@@ -249,8 +249,8 @@
     <string name="permgroupdesc_systemTools" msgid="8162102602190734305">"系統的低階存取權和控制權。"</string>
     <string name="permgrouplab_developmentTools" msgid="3446164584710596513">"開發工具"</string>
     <string name="permgroupdesc_developmentTools" msgid="7058828032358142018">"僅限應用程式開發人員使用的功能。"</string>
-    <string name="permgrouplab_display" msgid="4279909676036402636">"其他應用程式用戶介面"</string>
-    <string name="permgroupdesc_display" msgid="6051002031933013714">"影響其他應用程式的用戶介面。"</string>
+    <string name="permgrouplab_display" msgid="4279909676036402636">"其他應用程式使用者介面"</string>
+    <string name="permgroupdesc_display" msgid="6051002031933013714">"影響其他應用程式的使用者介面。"</string>
     <string name="permgrouplab_storage" msgid="1971118770546336966">"儲存空間"</string>
     <string name="permgroupdesc_storage" product="nosdcard" msgid="7442318502446874999">"存取 USB 儲存裝置。"</string>
     <string name="permgroupdesc_storage" product="default" msgid="9203302214915355774">"存取 SD 卡。"</string>
@@ -271,9 +271,9 @@
     <string name="permlab_expandStatusBar" msgid="1148198785937489264">"展開/收合狀態列"</string>
     <string name="permdesc_expandStatusBar" msgid="6917549437129401132">"允許應用程式展開或收合狀態列。"</string>
     <string name="permlab_install_shortcut" msgid="4279070216371564234">"安裝捷徑"</string>
-    <string name="permdesc_install_shortcut" msgid="8341295916286736996">"允許應用程式繞過用戶授權直接新增主畫面捷徑。"</string>
+    <string name="permdesc_install_shortcut" msgid="8341295916286736996">"允許應用程式繞過使用者授權直接新增主畫面捷徑。"</string>
     <string name="permlab_uninstall_shortcut" msgid="4729634524044003699">"解除安裝捷徑"</string>
-    <string name="permdesc_uninstall_shortcut" msgid="6745743474265057975">"允許應用程式繞過用戶授權直接移除主畫面捷徑。"</string>
+    <string name="permdesc_uninstall_shortcut" msgid="6745743474265057975">"允許應用程式繞過使用者授權直接移除主畫面捷徑。"</string>
     <string name="permlab_processOutgoingCalls" msgid="3906007831192990946">"重新設定撥出電話的路徑"</string>
     <string name="permdesc_processOutgoingCalls" msgid="5156385005547315876">"允許應用程式在撥出電話時查看所撥打的電話號碼,並選擇將電話重新導向至另一個號碼或完全中斷通話。"</string>
     <string name="permlab_receiveSms" msgid="8673471768947895082">"接收短訊 (SMS)"</string>
@@ -302,12 +302,12 @@
     <string name="permdesc_getTasks" msgid="7454215995847658102">"允許應用程式擷取有關目前和最近執行的工作的資訊。如此一來,應用程式或可找出裝置上所使用應用程式的相關資訊。"</string>
     <string name="permlab_startTasksFromRecents" msgid="8990073877885690623">"開始最近傳回的工作"</string>
     <string name="permdesc_startTasksFromRecents" msgid="7382133554871222235">"允許應用程式使用 ActivityManager.RecentTaskInfo 啟動已停止的工作 (先前由 ActivityManager.getRecentTaskList() 傳回)。"</string>
-    <string name="permlab_interactAcrossUsers" msgid="7114255281944211682">"與其他用戶互動"</string>
-    <string name="permdesc_interactAcrossUsers" msgid="364670963623385786">"允許應用程式對裝置上的不同用戶執行各種操作。請注意,惡意應用程式可能藉此破壞各用戶之間的保護機制。"</string>
-    <string name="permlab_interactAcrossUsersFull" msgid="2567734285545074105">"全面授權與其他用戶互動"</string>
-    <string name="permdesc_interactAcrossUsersFull" msgid="376841368395502366">"允許與其他用戶進行各種可能的互動。"</string>
-    <string name="permlab_manageUsers" msgid="1676150911672282428">"管理用戶"</string>
-    <string name="permdesc_manageUsers" msgid="8409306667645355638">"允許應用程式管理裝置上的用戶,包括查詢、建立及刪除用戶。"</string>
+    <string name="permlab_interactAcrossUsers" msgid="7114255281944211682">"與其他使用者互動"</string>
+    <string name="permdesc_interactAcrossUsers" msgid="364670963623385786">"允許應用程式對裝置上的不同使用者執行各種操作。請注意,惡意應用程式可能藉此破壞各使用者之間的保護機制。"</string>
+    <string name="permlab_interactAcrossUsersFull" msgid="2567734285545074105">"全面授權與其他使用者互動"</string>
+    <string name="permdesc_interactAcrossUsersFull" msgid="376841368395502366">"允許與其他使用者進行各種可能的互動。"</string>
+    <string name="permlab_manageUsers" msgid="1676150911672282428">"管理使用者"</string>
+    <string name="permdesc_manageUsers" msgid="8409306667645355638">"允許應用程式管理裝置上的使用者,包括查詢、建立及刪除使用者。"</string>
     <string name="permlab_getDetailedTasks" msgid="6229468674753529501">"擷取運行中應用程式的詳細資料"</string>
     <string name="permdesc_getDetailedTasks" msgid="153824741440717599">"允許應用程式擷取目前及最近執行任務的詳細資訊。惡意應用程式可能會找到其他應用程式的私人資訊。"</string>
     <string name="permlab_reorderTasks" msgid="2018575526934422779">"為執行中的應用程式重新排序"</string>
@@ -337,17 +337,17 @@
     <string name="permlab_retrieve_window_content" msgid="8022588608994589938">"取得螢幕內容"</string>
     <string name="permdesc_retrieve_window_content" msgid="3193269069469700265">"允許應用程式擷取使用中的視窗內容。惡意應用程式可能會擷取整個視窗的內容,以及檢視密碼除外的所有文字。"</string>
     <string name="permlab_temporary_enable_accessibility" msgid="2312612135127310254">"暫時啟用協助工具"</string>
-    <string name="permdesc_temporary_enable_accessibility" msgid="8079456293182975464">"允許應用程式在裝置上暫時啟用協助工具。惡意應用程式可能藉此在未經用戶同意的情況下擅自啟用協助工具。"</string>
+    <string name="permdesc_temporary_enable_accessibility" msgid="8079456293182975464">"允許應用程式在裝置上暫時啟用協助工具。惡意應用程式可能藉此在未經使用者同意的情況下擅自啟用協助工具。"</string>
     <string name="permlab_retrieveWindowToken" msgid="7154762602367758602">"擷取視窗憑證"</string>
     <string name="permdesc_retrieveWindowToken" msgid="668173747687795074">"允許應用程式擷取視窗憑證。惡意應用程式可能會在未經授權的情況下,與冒充系統的應用程式視窗互動。"</string>
     <string name="permlab_frameStats" msgid="7056374987314361639">"擷取畫格統計資料"</string>
     <string name="permdesc_frameStats" msgid="4758001089491284919">"允許應用程式收集畫格統計資料。惡意應用程式可能會透過其他應用程式監察視窗畫格統計資料。"</string>
     <string name="permlab_filter_events" msgid="8675535648807427389">"篩選活動"</string>
-    <string name="permdesc_filter_events" msgid="8006236315888347680">"允許應用程式註冊輸入篩選器,在分派所有用戶活動的串流前先行篩選。惡意應用程式可能會繞過用戶操作,直接控制系統用戶介面。"</string>
+    <string name="permdesc_filter_events" msgid="8006236315888347680">"允許應用程式註冊輸入篩選器,在分派所有使用者活動的串流前先行篩選。惡意應用程式可能會繞過使用者操作,直接控制系統使用者介面。"</string>
     <string name="permlab_shutdown" msgid="7185747824038909016">"部分關機"</string>
     <string name="permdesc_shutdown" msgid="7046500838746291775">"讓活動管理員進入關機狀態,而不執行完整的關機程序。"</string>
     <string name="permlab_stopAppSwitches" msgid="4138608610717425573">"防止切換應用程式"</string>
-    <string name="permdesc_stopAppSwitches" msgid="8262195802582255021">"防止用戶切換至其他應用程式。"</string>
+    <string name="permdesc_stopAppSwitches" msgid="8262195802582255021">"防止使用者切換至其他應用程式。"</string>
     <string name="permlab_getTopActivityInfo" msgid="2537922311411546016">"取得目前的應用程式資訊"</string>
     <string name="permdesc_getTopActivityInfo" msgid="2512448855496067131">"允許應用程式從目前螢幕前景的應用程式擷取私人資訊。"</string>
     <string name="permlab_runSetActivityWatcher" msgid="892239094867182656">"監視及控制所有應用程式的啟動程序"</string>
@@ -373,11 +373,11 @@
     <string name="permlab_backup" msgid="470013022865453920">"控制系統備份和還原"</string>
     <string name="permdesc_backup" msgid="6912230525140589891">"允許應用程式控制系統備份與還原機制 (不建議一般應用程式使用)。"</string>
     <string name="permlab_confirm_full_backup" msgid="5557071325804469102">"確認完整備份或還原作業"</string>
-    <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"允許應用程式啟動完整備份確認用戶介面 (不建議任何應用程式使用)。"</string>
+    <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"允許應用程式啟動完整備份確認使用者介面 (不建議任何應用程式使用)。"</string>
     <string name="permlab_internalSystemWindow" msgid="2148563628140193231">"顯示未經授權的視窗"</string>
-    <string name="permdesc_internalSystemWindow" msgid="7458387759461466397">"允許應用程式為內部系統用戶介面建立視窗 (不建議一般應用程式使用)。"</string>
+    <string name="permdesc_internalSystemWindow" msgid="7458387759461466397">"允許應用程式為內部系統使用者介面建立視窗 (不建議一般應用程式使用)。"</string>
     <string name="permlab_systemAlertWindow" msgid="3543347980839518613">"可套用至其他應用程式"</string>
-    <string name="permdesc_systemAlertWindow" msgid="8584678381972820118">"允許應用程式在其他應用程式上面或用戶介面的特定部分繪圖。這可能會干擾您使用任何應用程式的介面,或讓您誤會您在其他應用程式上所見內容的意思。"</string>
+    <string name="permdesc_systemAlertWindow" msgid="8584678381972820118">"允許應用程式在其他應用程式上面或使用者介面的特定部分繪圖。這可能會干擾您使用任何應用程式的介面,或讓您誤會您在其他應用程式上所見內容的意思。"</string>
     <string name="permlab_setAnimationScale" msgid="2805103241153907174">"修改全域動畫速度"</string>
     <string name="permdesc_setAnimationScale" msgid="7690063428924343571">"允許應用程式隨時更改全域的動畫速度 (更快或更慢)。"</string>
     <string name="permlab_manageAppTokens" msgid="1286505717050121370">"管理應用程式憑證"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"允許應用程式繫結至遠端屏螢的頂層介面 (不建議一般應用程式使用)。"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"繫結至小工具服務"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"允許應用程式繫結至小工具服務的頂層介面 (不建議一般應用程式使用)。"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"繫結至路由供應商服務"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"允許應用程式繫結至任何已註冊的路由供應商,但一般應用程式並不需要使用。"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"與裝置管理員互動"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"允許應用程式將調用請求傳送至裝置管理員 (不建議一般應用程式使用)。"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"繫結至電視訊號輸入裝置"</string>
@@ -437,7 +435,7 @@
     <string name="permlab_deletePackages" msgid="184385129537705938">"刪除應用程式"</string>
     <string name="permdesc_deletePackages" msgid="7411480275167205081">"允許應用程式刪除 Android 套件。惡意應用程式可能會藉此刪除重要應用程式。"</string>
     <string name="permlab_clearAppUserData" msgid="274109191845842756">"刪除其他應用程式資料"</string>
-    <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"允許應用程式清除用戶資料。"</string>
+    <string name="permdesc_clearAppUserData" msgid="4625323684125459488">"允許應用程式清除使用者資料。"</string>
     <string name="permlab_deleteCacheFiles" msgid="3128665571837408675">"刪除其他應用程式的快取檔案"</string>
     <string name="permdesc_deleteCacheFiles" msgid="3812998599006730196">"允許應用程式刪除快取檔案。"</string>
     <string name="permlab_getPackageSize" msgid="7472921768357981986">"測量應用程式儲存空間"</string>
@@ -586,7 +584,7 @@
     <string name="permlab_callPhone" msgid="3925836347681847954">"直接撥打電話號碼"</string>
     <string name="permdesc_callPhone" msgid="3740797576113760827">"允許應用程式繞過您自行撥打電話號碼,但可能會產生未預期的費用或撥打未預期的電話。注意:這項權限不允許應用程式撥打緊急電話。惡意應用程式可能未經您確認擅自撥打電話,增加您的支出。"</string>
     <string name="permlab_callPrivileged" msgid="4198349211108497879">"直接撥打任何電話號碼"</string>
-    <string name="permdesc_callPrivileged" msgid="1689024901509996810">"允許應用程式繞過用戶自行撥打任何電話號碼,包括緊急電話號碼。惡意應用程式可能會濫用緊急服務,撥打不必要或違法的電話。"</string>
+    <string name="permdesc_callPrivileged" msgid="1689024901509996810">"允許應用程式繞過使用者自行撥打任何電話號碼,包括緊急電話號碼。惡意應用程式可能會濫用緊急服務,撥打不必要或違法的電話。"</string>
     <string name="permlab_performCdmaProvisioning" product="tablet" msgid="4842576994144604821">"直接啟動 CDMA 平板電腦設定程序"</string>
     <string name="permlab_performCdmaProvisioning" product="default" msgid="5604848095315421425">"直接啟動 CDMA 手機設定程序"</string>
     <string name="permdesc_performCdmaProvisioning" msgid="1994193538802314186">"允許應用程式啟動 CDMA 佈建功能。惡意應用程式可能會在非必要的情況下啟動 CDMA 佈建功能。"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"開啟或關閉手機"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"允許應用程式開啟或關閉平板電腦。"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"允許應用程式開啟或關閉手機。"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"重設顯示逾時"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"允許應用程式重設顯示逾時。"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"以原廠測試模式執行"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"允許在以低階製造商測試身分執行時,可具有平板電腦硬體的完整存取權限。只有在平板電腦以製造商測試模式執行時,才能使用此權限。"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"以低階製造商測試執行,可具有手機硬件的完整存取權限。只有在手機以製造商測試模式執行時,才能使用此權限。"</string>
@@ -693,9 +693,9 @@
     <string name="permlab_subscribedFeedsWrite" msgid="9015246325408209296">"寫入訂閱的資訊提供"</string>
     <string name="permdesc_subscribedFeedsWrite" msgid="6928930188826089413">"允許應用程式修改目前已同步的資訊提供。惡意應用程式可能會更改已同步的資訊提供。"</string>
     <string name="permlab_readDictionary" msgid="4107101525746035718">"讀取加入字典中的字詞"</string>
-    <string name="permdesc_readDictionary" msgid="659614600338904243">"允許應用程式讀取用戶儲存在用戶字典中的所有字詞、名稱和詞組。"</string>
-    <string name="permlab_writeDictionary" msgid="2183110402314441106">"將字詞加入用戶定義字典"</string>
-    <string name="permdesc_writeDictionary" msgid="8185385716255065291">"允許應用程式將新字詞寫入用戶字典。"</string>
+    <string name="permdesc_readDictionary" msgid="659614600338904243">"允許應用程式讀取使用者儲存在使用者字典中的所有字詞、名稱和詞組。"</string>
+    <string name="permlab_writeDictionary" msgid="2183110402314441106">"將字詞加入使用者定義字典"</string>
+    <string name="permdesc_writeDictionary" msgid="8185385716255065291">"允許應用程式將新字詞寫入使用者字典。"</string>
     <string name="permlab_sdcardRead" product="nosdcard" msgid="367275095159405468">"讀取您 USB 儲存裝置中的內容"</string>
     <string name="permlab_sdcardRead" product="default" msgid="2188156462934977940">"讀取您 SD 記憶卡中的內容"</string>
     <string name="permdesc_sdcardRead" product="nosdcard" msgid="3446988712598386079">"允許應用程式讀取 USB 儲存裝置的內容。"</string>
@@ -708,18 +708,18 @@
     <string name="permdesc_mediaStorageWrite" product="default" msgid="8189160597698529185">"允許應用程式修改內部媒體儲存空間的內容。"</string>
     <string name="permlab_manageDocs" product="default" msgid="5778318598448849829">"管理文件儲存"</string>
     <string name="permdesc_manageDocs" product="default" msgid="8704323176914121484">"允許應用程式管理文件儲存。"</string>
-    <string name="permlab_sdcardAccessAll" msgid="8150613823900460576">"存取外部儲存空間 (所有用戶)"</string>
-    <string name="permdesc_sdcardAccessAll" msgid="3215208357415891320">"允許應用程式存取外部儲存空間 (所有用戶)。"</string>
+    <string name="permlab_sdcardAccessAll" msgid="8150613823900460576">"存取外部儲存空間 (所有使用者)"</string>
+    <string name="permdesc_sdcardAccessAll" msgid="3215208357415891320">"允許應用程式存取外部儲存空間 (所有使用者)。"</string>
     <string name="permlab_cache_filesystem" msgid="5656487264819669824">"存取快取檔案系統"</string>
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"允許應用程式讀取及寫入快取檔案系統。"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"撥打/接聽 SIP 電話"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"允許應用程式撥打及接聽 SIP 電話。"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"與通話畫面互動"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"允許應用程式控制通話畫面的顯示時間和方式。"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"與通話畫面互動"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"允許應用程式控制通話畫面的顯示時間和方式。"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"與電話語音服務互動"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"允許應用程式與電話語音服務互動以收發電話。"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"提供通話使用者體驗"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"允許應用程式提供通話使用者體驗。"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"讀取網絡用量記錄"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"允許應用程式讀取特定網絡和應用程式的網絡使用量記錄。"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"管理網絡政策"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"允許應用程式繫結至通知接聽器服務的頂層介面 (不建議一般應用程式使用)。"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"繫結至條件供應商服務"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"允許應用程式繫結至條件供應商服務的頂層介面,但一般應用程式並不需要使用。"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"繫結至媒體轉送服務"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"允許應用程式繫結至媒體轉送服務的頂層介面,但一般應用程式並不需要使用。"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"繫結至 Dream 服務"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"允許應用程式繫結至 Dream 服務的頂層介面 (不建議一般應用程式使用)。"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"調用流動網絡供應商提供的設定應用程式"</string>
@@ -771,9 +769,9 @@
     <string name="policylab_disableKeyguardFeatures" msgid="266329104542638802">"停用鍵盤保護框上的功能"</string>
     <string name="policydesc_disableKeyguardFeatures" msgid="3467082272186534614">"禁止使用鍵盤保護框上的部分功能。"</string>
   <string-array name="phoneTypes">
-    <item msgid="8901098336658710359">"首頁"</item>
+    <item msgid="8901098336658710359">"住宅"</item>
     <item msgid="869923650527136615">"手機"</item>
-    <item msgid="7897544654242874543">"工作"</item>
+    <item msgid="7897544654242874543">"公司"</item>
     <item msgid="1103601433382158155">"公司傳真"</item>
     <item msgid="1735177144948329370">"住宅傳真"</item>
     <item msgid="603878674477207394">"傳呼機"</item>
@@ -781,25 +779,25 @@
     <item msgid="9192514806975898961">"自訂"</item>
   </string-array>
   <string-array name="emailAddressTypes">
-    <item msgid="8073994352956129127">"首頁"</item>
-    <item msgid="7084237356602625604">"工作"</item>
+    <item msgid="8073994352956129127">"住宅"</item>
+    <item msgid="7084237356602625604">"公司"</item>
     <item msgid="1112044410659011023">"其他"</item>
     <item msgid="2374913952870110618">"自訂"</item>
   </string-array>
   <string-array name="postalAddressTypes">
-    <item msgid="6880257626740047286">"首頁"</item>
-    <item msgid="5629153956045109251">"工作"</item>
+    <item msgid="6880257626740047286">"住宅"</item>
+    <item msgid="5629153956045109251">"公司"</item>
     <item msgid="4966604264500343469">"其他"</item>
     <item msgid="4932682847595299369">"自訂"</item>
   </string-array>
   <string-array name="imAddressTypes">
-    <item msgid="1738585194601476694">"首頁"</item>
-    <item msgid="1359644565647383708">"工作"</item>
+    <item msgid="1738585194601476694">"住宅"</item>
+    <item msgid="1359644565647383708">"公司"</item>
     <item msgid="7868549401053615677">"其他"</item>
     <item msgid="3145118944639869809">"自訂"</item>
   </string-array>
   <string-array name="organizationTypes">
-    <item msgid="7546335612189115615">"工作"</item>
+    <item msgid="7546335612189115615">"公司"</item>
     <item msgid="4378074129049520373">"其他"</item>
     <item msgid="3455047468583965104">"自訂"</item>
   </string-array>
@@ -814,9 +812,9 @@
     <item msgid="1648797903785279353">"Jabber"</item>
   </string-array>
     <string name="phoneTypeCustom" msgid="1644738059053355820">"自訂"</string>
-    <string name="phoneTypeHome" msgid="2570923463033985887">"首頁"</string>
+    <string name="phoneTypeHome" msgid="2570923463033985887">"住宅"</string>
     <string name="phoneTypeMobile" msgid="6501463557754751037">"手機"</string>
-    <string name="phoneTypeWork" msgid="8863939667059911633">"工作"</string>
+    <string name="phoneTypeWork" msgid="8863939667059911633">"公司"</string>
     <string name="phoneTypeFaxWork" msgid="3517792160008890912">"公司傳真"</string>
     <string name="phoneTypeFaxHome" msgid="2067265972322971467">"住宅傳真"</string>
     <string name="phoneTypePager" msgid="7582359955394921732">"傳呼機"</string>
@@ -831,7 +829,7 @@
     <string name="phoneTypeTelex" msgid="3367879952476250512">"電報"</string>
     <string name="phoneTypeTtyTdd" msgid="8606514378585000044">"TTY TDD"</string>
     <string name="phoneTypeWorkMobile" msgid="1311426989184065709">"公司手機"</string>
-    <string name="phoneTypeWorkPager" msgid="649938731231157056">"工作傳呼機"</string>
+    <string name="phoneTypeWorkPager" msgid="649938731231157056">"公司傳呼機"</string>
     <string name="phoneTypeAssistant" msgid="5596772636128562884">"助理"</string>
     <string name="phoneTypeMms" msgid="7254492275502768992">"MMS"</string>
     <string name="eventTypeCustom" msgid="7837586198458073404">"自訂"</string>
@@ -839,17 +837,17 @@
     <string name="eventTypeAnniversary" msgid="3876779744518284000">"週年紀念"</string>
     <string name="eventTypeOther" msgid="7388178939010143077">"其他"</string>
     <string name="emailTypeCustom" msgid="8525960257804213846">"自訂"</string>
-    <string name="emailTypeHome" msgid="449227236140433919">"首頁"</string>
-    <string name="emailTypeWork" msgid="3548058059601149973">"工作"</string>
+    <string name="emailTypeHome" msgid="449227236140433919">"住宅"</string>
+    <string name="emailTypeWork" msgid="3548058059601149973">"公司"</string>
     <string name="emailTypeOther" msgid="2923008695272639549">"其他"</string>
     <string name="emailTypeMobile" msgid="119919005321166205">"流動電郵"</string>
     <string name="postalTypeCustom" msgid="8903206903060479902">"自訂"</string>
-    <string name="postalTypeHome" msgid="8165756977184483097">"首頁"</string>
-    <string name="postalTypeWork" msgid="5268172772387694495">"工作"</string>
+    <string name="postalTypeHome" msgid="8165756977184483097">"住宅"</string>
+    <string name="postalTypeWork" msgid="5268172772387694495">"公司"</string>
     <string name="postalTypeOther" msgid="2726111966623584341">"其他"</string>
     <string name="imTypeCustom" msgid="2074028755527826046">"自訂"</string>
-    <string name="imTypeHome" msgid="6241181032954263892">"首頁"</string>
-    <string name="imTypeWork" msgid="1371489290242433090">"工作"</string>
+    <string name="imTypeHome" msgid="6241181032954263892">"住宅"</string>
+    <string name="imTypeWork" msgid="1371489290242433090">"公司"</string>
     <string name="imTypeOther" msgid="5377007495735915478">"其他"</string>
     <string name="imProtocolCustom" msgid="6919453836618749992">"自訂"</string>
     <string name="imProtocolAim" msgid="7050360612368383417">"AIM"</string>
@@ -861,7 +859,7 @@
     <string name="imProtocolIcq" msgid="1574870433606517315">"ICQ"</string>
     <string name="imProtocolJabber" msgid="2279917630875771722">"Jabber"</string>
     <string name="imProtocolNetMeeting" msgid="8287625655986827971">"NetMeeting"</string>
-    <string name="orgTypeWork" msgid="29268870505363872">"工作"</string>
+    <string name="orgTypeWork" msgid="29268870505363872">"公司"</string>
     <string name="orgTypeOther" msgid="3951781131570124082">"其他"</string>
     <string name="orgTypeCustom" msgid="225523415372088322">"自訂"</string>
     <string name="relationTypeCustom" msgid="3542403679827297300">"自訂"</string>
@@ -881,7 +879,7 @@
     <string name="relationTypeSpouse" msgid="394136939428698117">"配偶"</string>
     <string name="sipAddressTypeCustom" msgid="2473580593111590945">"自訂"</string>
     <string name="sipAddressTypeHome" msgid="6093598181069359295">"家用"</string>
-    <string name="sipAddressTypeWork" msgid="6920725730797099047">"工作"</string>
+    <string name="sipAddressTypeWork" msgid="6920725730797099047">"公司"</string>
     <string name="sipAddressTypeOther" msgid="4408436162950119849">"其他"</string>
     <string name="quick_contacts_not_available" msgid="746098007828579688">"找不到可以查看這位聯絡人的應用程式。"</string>
     <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"輸入 PIN 碼"</string>
@@ -926,7 +924,7 @@
     <string name="emergency_calls_only" msgid="6733978304386365407">"僅可撥打緊急電話"</string>
     <string name="lockscreen_network_locked_message" msgid="143389224986028501">"網絡已鎖定"</string>
     <string name="lockscreen_sim_puk_locked_message" msgid="7441797339976230">"SIM 卡處於 PUK 鎖定狀態。"</string>
-    <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"請參閱用戶指南或與客戶服務中心聯絡。"</string>
+    <string name="lockscreen_sim_puk_locked_instructions" msgid="8127916255245181063">"請參閱使用者指南或與客戶服務中心聯絡。"</string>
     <string name="lockscreen_sim_locked_message" msgid="8066660129206001039">"SIM 卡處於鎖定狀態。"</string>
     <string name="lockscreen_sim_unlock_progress_dialog_message" msgid="595323214052881264">"正在解除 SIM 卡鎖定..."</string>
     <string name="lockscreen_too_many_failed_attempts_dialog_message" msgid="6481623830344107222">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
@@ -934,8 +932,8 @@
     <string name="lockscreen_too_many_failed_pin_attempts_dialog_message" msgid="6216672706545696955">"您已輸入錯誤的 PIN 碼 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="tablet" msgid="9191611984625460820">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次,如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,系統會要求您使用您的 Google 登入資料解開上鎖的平板電腦。\n\n請在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒後再試一次。"</string>
     <string name="lockscreen_failed_attempts_almost_glogin" product="default" msgid="2590227559763762751">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次,如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,系統會要求您使用您的 Google 登入資料解開上鎖的手機。\n\n請在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒後再試一次。"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"您嘗試解除這部平板電腦的鎖定已失敗 <xliff:g id="NUMBER_0">%d</xliff:g> 次,剩餘 <xliff:g id="NUMBER_1">%d</xliff:g> 次嘗試機會。如果失敗次數超過嘗試次數限制,平板電腦將恢復原廠設定,所有用戶資料均會遺失。"</string>
-    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"您嘗試解除這部手機的鎖定已失敗 <xliff:g id="NUMBER_0">%d</xliff:g> 次,剩餘 <xliff:g id="NUMBER_1">%d</xliff:g> 次嘗試機會。如果失敗次數超過嘗試次數限制,手機將恢復原廠設定,所有用戶資料均會遺失。"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="tablet" msgid="6128106399745755604">"您嘗試解除這部平板電腦的鎖定已失敗 <xliff:g id="NUMBER_0">%d</xliff:g> 次,剩餘 <xliff:g id="NUMBER_1">%d</xliff:g> 次嘗試機會。如果失敗次數超過嘗試次數限制,平板電腦將恢復原廠設定,所有使用者資料均會遺失。"</string>
+    <string name="lockscreen_failed_attempts_almost_at_wipe" product="default" msgid="8603565142156826565">"您嘗試解除這部手機的鎖定已失敗 <xliff:g id="NUMBER_0">%d</xliff:g> 次,剩餘 <xliff:g id="NUMBER_1">%d</xliff:g> 次嘗試機會。如果失敗次數超過嘗試次數限制,手機將恢復原廠設定,所有使用者資料均會遺失。"</string>
     <string name="lockscreen_failed_attempts_now_wiping" product="tablet" msgid="280873516493934365">"您嘗試解除這部平板電腦的鎖定已失敗 <xliff:g id="NUMBER">%d</xliff:g> 次。平板電腦現在會重設為原廠預設值。"</string>
     <string name="lockscreen_failed_attempts_now_wiping" product="default" msgid="3025504721764922246">"您嘗試解除這部手機的鎖定已失敗 <xliff:g id="NUMBER">%d</xliff:g> 次。手機現在會重設為原廠預設值。"</string>
     <string name="lockscreen_too_many_failed_attempts_countdown" msgid="6251480343394389665">"<xliff:g id="NUMBER">%d</xliff:g> 秒後再試一次。"</string>
@@ -943,11 +941,11 @@
     <string name="lockscreen_glogin_forgot_pattern" msgid="2588521501166032747">"帳戶解鎖"</string>
     <string name="lockscreen_glogin_too_many_attempts" msgid="2751368605287288808">"圖案嘗試次數過多"</string>
     <string name="lockscreen_glogin_instructions" msgid="3931816256100707784">"如要解鎖,請以 Google 帳戶登入。"</string>
-    <string name="lockscreen_glogin_username_hint" msgid="8846881424106484447">"用戶名稱 (電子郵件)"</string>
+    <string name="lockscreen_glogin_username_hint" msgid="8846881424106484447">"使用者名稱 (電子郵件)"</string>
     <string name="lockscreen_glogin_password_hint" msgid="5958028383954738528">"密碼"</string>
     <string name="lockscreen_glogin_submit_button" msgid="7130893694795786300">"登入"</string>
-    <string name="lockscreen_glogin_invalid_input" msgid="1364051473347485908">"無效的用戶名稱或密碼。"</string>
-    <string name="lockscreen_glogin_account_recovery_hint" msgid="1696924763690379073">"忘記用戶名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
+    <string name="lockscreen_glogin_invalid_input" msgid="1364051473347485908">"無效的使用者名稱或密碼。"</string>
+    <string name="lockscreen_glogin_account_recovery_hint" msgid="1696924763690379073">"忘記使用者名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
     <string name="lockscreen_glogin_checking_password" msgid="7114627351286933867">"正在檢查..."</string>
     <string name="lockscreen_unlock_label" msgid="737440483220667054">"解除鎖定"</string>
     <string name="lockscreen_sound_on_label" msgid="9068877576513425970">"開啟音效"</string>
@@ -962,7 +960,7 @@
     <string name="keyguard_accessibility_unlock_area_expanded" msgid="2278106022311170299">"解鎖區域已展開。"</string>
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"解鎖區域已收合。"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>小工具。"</string>
-    <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"用戶選取工具"</string>
+    <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"使用者選取工具"</string>
     <string name="keyguard_accessibility_status" msgid="8008264603935930611">"狀態"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"相機"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"媒體控制"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"與 %1$s 分享"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"選取主畫面應用程式"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"設定用於執行這項操作。"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"使用不同的應用程式"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"前往 [系統設定] &gt; [應用程式] &gt; [已下載] 清除預設值。"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"選擇操作"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"選取要以 USB 裝置存取的應用程式"</string>
@@ -1276,7 +1275,7 @@
     <string name="wifi_watchdog_network_disabled" msgid="7904214231651546347">"無法連線至 Wi-Fi"</string>
     <string name="wifi_watchdog_network_disabled_detailed" msgid="5548780776418332675">" 互聯網連線欠佳。"</string>
     <string name="wifi_p2p_dialog_title" msgid="97611782659324517">"Wi-Fi Direct"</string>
-    <string name="wifi_p2p_turnon_message" msgid="2909250942299627244">"啟動 Wi-Fi Direct,這會關閉 Wi-Fi 用戶端/熱點。"</string>
+    <string name="wifi_p2p_turnon_message" msgid="2909250942299627244">"啟動 Wi-Fi Direct,這會關閉 Wi-Fi 使用者端/熱點。"</string>
     <string name="wifi_p2p_failed_message" msgid="3763669677935623084">"無法啟動 Wi-Fi Direct。"</string>
     <string name="wifi_p2p_enabled_notification_title" msgid="2068321881673734886">"Wi-Fi Direct 已開啟"</string>
     <string name="wifi_p2p_enabled_notification_message" msgid="1638949953993894335">"輕觸進行設定"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"允許"</string>
     <string name="sms_control_no" msgid="625438561395534982">"拒絕"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; 要求將訊息傳送至 &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;。"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"這"<font fgcolor="#ffffb060">"可能將收費計入"</font>"您的流動服務帳戶中。"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"這會將收費計入您的流動服務帳戶中。"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"您的流動服務帳戶"<b>"可能因此繳付費用"</b>"。"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"您的流動服務帳戶將因此繳付費用。"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"發送"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"取消"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"記住我的選擇"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"輕觸即可停用 USB 偵錯。"</string>
     <string name="select_input_method" msgid="8547250819326693584">"變更鍵盤"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"選擇鍵盤"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"實體鍵盤"</string>
+    <string name="show_ime" msgid="9157568568695230830">"顯示輸入法"</string>
     <string name="hardware" msgid="7517821086888990278">"硬件"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"選取鍵盤配置"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"輕觸即可選取鍵盤配置。"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"允許應用程式繫結至信任的代理程式。"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"與更新和復原系統互動"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"允許應用程式與復原系統和系統更新互動。"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"建立媒體投影工作階段"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"允許應用程式建立媒體投影工作階段。這類工作階段可讓應用程式擷取畫面內容和音訊內容 (一般應用程式並不需用)。"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"管理媒體投影工作階段"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"允許應用程式管理媒體投影工作階段。這類工作階段可讓應用程式擷取畫面內容和音訊內容 (一般應用程式並不需要)。"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"讀取安裝工作階段"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"允許應用程式讀取安裝工作階段。應用程式將可查看目前安裝套裝的詳細資料。"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"輕觸兩下即可控制縮放"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"拒絕"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"已要求權限"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"<xliff:g id="ACCOUNT">%s</xliff:g> 帳戶的\n權限要求。"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"您目前在個人空間使用此應用程式"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"您目前在工作空間使用此應用程式"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"您目前並未透過工作設定檔使用這個應用程式"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"您目前透過工作設定檔使用這個應用程式"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"輸入法"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"同步處理"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"協助工具"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"減少時數"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"設定 PM 值"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"設定 AM 值"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"下午"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"上午"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"增加月數"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"減少月數"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"增加日數"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"編輯"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"資料用量警告"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"輕觸即可查看使用量和設定。"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G 數據連線已關閉"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G 數據連線已關閉"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"流動數據連線已關閉"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi 數據連線已關閉"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"已達上限"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"已達到 2G-3G 數據流量上限"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"已達到 4G 數據流量上限"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"已達到流動數據流量上限"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"已達到 Wi-Fi 數據流量上限"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"已暫停使用數據連線,直到工作階段結束為止"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"已達 2G-3G 數據上限"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"已達 4G 數據上限"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"已超過流動數據流量上限"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"接聽電話嗎?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"一律採用"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"只此一次"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s 不支援工作設定檔。"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s 不支援工作設定檔"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"平板電腦"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"手機"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"耳機"</string>
@@ -1621,17 +1618,17 @@
     <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN 碼不符"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"圖案嘗試次數過多"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"如要解鎖,請以 Google 帳戶登入。"</string>
-    <string name="kg_login_username_hint" msgid="5718534272070920364">"用戶名稱 (電子郵件)"</string>
+    <string name="kg_login_username_hint" msgid="5718534272070920364">"使用者名稱 (電子郵件)"</string>
     <string name="kg_login_password_hint" msgid="9057289103827298549">"密碼"</string>
     <string name="kg_login_submit_button" msgid="5355904582674054702">"登入"</string>
-    <string name="kg_login_invalid_input" msgid="5754664119319872197">"無效的用戶名稱或密碼。"</string>
-    <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘記用戶名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
+    <string name="kg_login_invalid_input" msgid="5754664119319872197">"無效的使用者名稱或密碼。"</string>
+    <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘記使用者名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"正在檢查帳戶…"</string>
     <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已輸入錯誤的 PIN 碼 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"您已輸入錯誤的密碼 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,平板電腦將回復原廠設定,所有用戶資料均會失去。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,手機將回復原廠設定,所有用戶資料均會失去。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,平板電腦將回復原廠設定,所有使用者資料均會失去。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,手機將回復原廠設定,所有使用者資料均會失去。"</string>
     <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您嘗試了 <xliff:g id="NUMBER">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。平板電腦現在將回復原廠設定。"</string>
     <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您嘗試了 <xliff:g id="NUMBER">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。手機現在將回復原廠設定。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="tablet" msgid="3253575572118914370">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次,如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,系統會要求您透過電郵帳戶解開上鎖的平板電腦。\n\n請在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒後再試一次。"</string>
@@ -1642,7 +1639,8 @@
     <string name="continue_to_enable_accessibility" msgid="1626427372316070258">"以兩隻手指按住不放,即可啟用協助工具。"</string>
     <string name="accessibility_enabled" msgid="1381972048564547685">"協助工具已啟用。"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"協助工具已取消。"</string>
-    <string name="user_switched" msgid="3768006783166984410">"目前的用戶是<xliff:g id="NAME">%1$s</xliff:g>。"</string>
+    <string name="user_switched" msgid="3768006783166984410">"目前的使用者是<xliff:g id="NAME">%1$s</xliff:g>。"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"正在切換至<xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"擁有者"</string>
     <string name="error_message_title" msgid="4510373083082500195">"錯誤"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"您的管理員不允許這項變更"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"已選取<xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"<xliff:g id="KEY">%1$s</xliff:g> 已刪除"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"公司<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"如要取消固定這個螢幕,請同時輕觸並按住 [返回] 和 [近期]。"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"如要取消固定這個螢幕,請輕觸並按住 [近期]。"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"螢幕已固定,而您的機構不允許取消固定。"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"使用螢幕固定功能?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"螢幕固定會鎖定螢幕,只顯示單一應用程式畫面。\n\n如要退出這個模式,請同時輕觸並按住 [返回] 和 [近期]。"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"螢幕固定會鎖定螢幕,只顯示單一應用程式畫面。\n\n如要退出這個模式,請輕觸並按住 [近期]。"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"不用了,謝謝"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"啟動"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"解鎖圖案"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"密碼"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"螢幕已固定"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"已取消固定螢幕"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"取消固定時必須輸入 PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"取消固定時必須畫出解鎖圖案"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"取消固定時必須輸入密碼"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"省電模式可延長電池使用時間,但會降低裝置的效能,並限制震動和大部分背景數據傳輸。電郵、短訊及其他需要同步處理的應用程式可能只會在開啟時才會更新。\n\n裝置充電時,省電模式會自動關閉。"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"直到停機時間於 <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> 結束"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 分鐘"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d 分鐘"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 小時"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d 小時"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"無限期"</string>
 </resources>
diff --git a/core/res/res/values-zh-rTW/strings.xml b/core/res/res/values-zh-rTW/strings.xml
index ec5a424..8baa781 100644
--- a/core/res/res/values-zh-rTW/strings.xml
+++ b/core/res/res/values-zh-rTW/strings.xml
@@ -376,7 +376,7 @@
     <string name="permdesc_confirm_full_backup" msgid="1748762171637699562">"允許應用程式啟動完整備份確認使用者介面 (不建議任何應用程式使用)。"</string>
     <string name="permlab_internalSystemWindow" msgid="2148563628140193231">"顯示未授權視窗"</string>
     <string name="permdesc_internalSystemWindow" msgid="7458387759461466397">"允許應用程式為內部系統使用者介面建立視窗 (不建議一般應用程式使用)。"</string>
-    <string name="permlab_systemAlertWindow" msgid="3543347980839518613">"在其他應用程式之上顯示内容"</string>
+    <string name="permlab_systemAlertWindow" msgid="3543347980839518613">"在其他應用程式之上顯示內容"</string>
     <string name="permdesc_systemAlertWindow" msgid="8584678381972820118">"允許應用程式在其他應用程式頂層或使用者介面的特定部分繪圖。這可能會干擾您在所有應用程式中的介面使用行為,或是使您在其他應用程式中預期看到的內容發生變化。"</string>
     <string name="permlab_setAnimationScale" msgid="2805103241153907174">"編輯全域動畫速度"</string>
     <string name="permdesc_setAnimationScale" msgid="7690063428924343571">"允許應用程式隨時變更全域的動畫速度 (更快或更慢)。"</string>
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"允許應用程式繫結至遠端螢幕的頂層介面 (一般應用程式不需使用)。"</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"繫結至小工具服務"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"允許應用程式繫結至小工具服務的頂層介面 (一般應用程式不需使用)。"</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"繫結至路由供應商服務"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"允許應用程式繫結至任何已註冊的路由供應商 (一般應用程式並不需要)。"</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"與裝置管理員互動"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"允許應用程式將調用請求傳送至裝置管理員 (一般應用程式不需使用)。"</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"繫結至電視訊號輸入裝置"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"開啟或關閉電源"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"允許應用程式開啟或關閉平板電腦。"</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"允許應用程式開啟或關閉手機。"</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"重設顯示逾時"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"允許應用程式重設顯示逾時。"</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"在出廠測試模式下執行"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"允許在以低階製造商測試身分執行時,可具有平板電腦硬體的完整存取權限。只有在平板電腦以製造商測試模式執行時,才能使用此權限。"</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"執行低階製造商測試,允許完全存取手機硬體。此功能只能在手機是製造商測試模式下才可執行。"</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"允許應用程式讀取及寫入快取檔案系統。"</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"撥打/接聽 SIP 通話"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"允許應用程式撥打及接聽 SIP 通話。"</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"與來電過濾互動"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"允許應用程式控制來電過濾的顯示時機與方式。"</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"與通話螢幕互動"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"允許應用程式控制使用者看到通話螢幕的時機和方式。"</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"與電話語音服務互動"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"允許應用程式與電話語音服務互動以撥接電話。"</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"為使用者提供通話體驗"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"允許應用程式向使用者提供通話體驗。"</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"讀取網路用量紀錄"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"允許應用程式讀取特定網路和應用程式的網路使用記錄。"</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"管理網路政策"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"允許應用程式繫結至通知接聽器服務的頂層介面 (一般應用程式不需使用)。"</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"繫結至條件提供者服務"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"允許應用程式繫結至條件提供者服務的頂層介面 (一般應用程式並不需要)。"</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"繫結至媒體轉送服務"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"允許應用程式繫結至媒體轉送服務的頂層介面 (一般應用程式並不需要)。"</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"繫結至 Dream 服務"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"允許應用程式繫結至 Dream 服務的頂層介面 (一般應用程式不需使用)。"</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"叫用行動通訊業者提供的設定應用程式"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"透過 %1$s 分享"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"選取主螢幕應用程式"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"設為預設應用程式。"</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"使用其他應用程式"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"前往 [系統設定] &gt; [應用程式] &gt; [下載] 清除預設值。"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"選擇分享方式"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"選取要以 USB 裝置存取的應用程式"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"允許"</string>
     <string name="sms_control_no" msgid="625438561395534982">"拒絕"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; 要求將訊息傳送至 &lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;。"</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"這"<font fgcolor="#ffffb060">"可能會透過您的行動帳戶計費"</font>"。"</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"這會透過您的行動帳戶計費。"</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"這"<b>"可能會透過您的行動帳戶計費"</b>"。"</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"這會透過您的行動帳戶計費。"</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"傳送"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"取消"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"記住我的選擇"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"輕觸即可停用 USB 偵錯。"</string>
     <string name="select_input_method" msgid="8547250819326693584">"變更鍵盤"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"選擇鍵盤"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"實體鍵盤"</string>
+    <string name="show_ime" msgid="9157568568695230830">"顯示輸入法"</string>
     <string name="hardware" msgid="7517821086888990278">"硬體"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"選取鍵盤配置"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"輕觸即可選取鍵盤配置。"</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"允許應用程式繫結至信任的代理程式服務。"</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"與更新和還原系統互動"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"允許應用程式與還原系統及系統更新互動。"</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"建立媒體投影工作階段"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"允許應用程式建立媒體投影工作階段。這類工作階段可讓應用程式擷取畫面內容和音訊內容 (一般應用程式並不需要)。"</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"管理媒體投影工作階段"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"允許應用程式管理媒體投影工作階段。這類工作階段可讓應用程式擷取螢幕內容和音訊內容,一般應用程式並不需要此權限。"</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"讀取安裝工作階段"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"允許應用程式讀取安裝工作階段。應用程式將可查看目前的套件安裝詳細資料。"</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"輕觸兩下即可控制縮放"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"拒絕"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"已要求權限"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"帳戶 <xliff:g id="ACCOUNT">%s</xliff:g> 已提出\n權限要求。"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"您目前在個人空間使用這個應用程式"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"您目前在工作空間使用這個應用程式"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"您目前並非透過工作設定檔使用這個應用程式"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"您目前透過工作設定檔使用這個應用程式"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"輸入法"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"同步處理"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"協助工具"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"減少小時數"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"設定 PM 值"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"設定 AM 值"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"下午"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"上午"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"增加月數"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"減少月數"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"增加日數"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"編輯"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"資料用量警告"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"輕觸即可查看使用量和設定。"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"2G-3G 數據連線已關閉"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"4G 數據連線已關閉"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"行動數據連線已關閉"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Wi-Fi 數據連線已關閉"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"已達上限"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"已達到 2G-3G 數據流量上限"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"已達到 4G 數據流量上限"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"已達到行動數據流量上限"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"已達到 Wi-Fi 數據流量上限"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"已暫停使用數據連線,直到工作階段結束為止"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"已超過 2G-3G 數據上限"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"已超過 4G 數據上限"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"已超過行動數據流量上限"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"接聽電話嗎?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"一律採用"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"僅限一次"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s 不支援工作設定檔。"</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s 不支援工作設定檔"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"平板電腦"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"手機"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"耳機"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"協助工具已啟用。"</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"協助工具已取消。"</string>
     <string name="user_switched" msgid="3768006783166984410">"目前的使用者是 <xliff:g id="NAME">%1$s</xliff:g>。"</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"正在切換至<xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"擁有者"</string>
     <string name="error_message_title" msgid="4510373083082500195">"錯誤"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"您的管理員不允許這項變更"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"已選取 <xliff:g id="ITEM">%1$s</xliff:g>"</string>
     <string name="deleted_key" msgid="7659477886625566590">"已刪除 <xliff:g id="KEY">%1$s</xliff:g>"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"公司<xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"如要取消固定這個螢幕,請同時輕觸並按住 [返回] 和 [近期]。"</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"如要取消固定這個螢幕,請輕觸並按住 [近期]。"</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"螢幕已固定,且貴機構不允許取消固定。"</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"使用螢幕固定功能?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"「螢幕固定」會鎖定螢幕,只顯示單一應用程式畫面。\n\n如要退出這個模式,請同時輕觸並按住 [返回] 和 [近期]。"</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"「螢幕固定」會鎖定螢幕,只顯示單一應用程式畫面。\n\n如要退出這個模式,請輕觸並按住 [近期]。"</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"不用了,謝謝"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"啟動"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"PIN"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"解鎖圖形"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"密碼"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"已固定螢幕"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"已取消固定螢幕"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"取消固定時必須輸入 PIN"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"取消固定時必須畫出解鎖圖形"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"取消固定時必須輸入密碼"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"節約耗電量功能會降低裝置的效能,並限制震動和大多數背景資料,藉此延長電池續航力。此外,電子郵件、簡訊和其他需要使用同步功能的應用程式若未開啟,將不會自動更新。\n\n當您為裝置充電時,節約耗電量功能會自動關閉。"</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"直到 <xliff:g id="FORMATTEDTIME">%1$s</xliff:g> 停機時間結束"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"1 分鐘"</item>
+    <item quantity="other" msgid="6924190729213550991">"%d 分鐘"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"1 小時"</item>
+    <item quantity="other" msgid="5408537517529822157">"%d 小時"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"無限期"</string>
 </resources>
diff --git a/core/res/res/values-zu/strings.xml b/core/res/res/values-zu/strings.xml
index 2c461d2..0d2484f 100644
--- a/core/res/res/values-zu/strings.xml
+++ b/core/res/res/values-zu/strings.xml
@@ -413,8 +413,6 @@
     <string name="permdesc_bindRemoteDisplay" msgid="1261242718727295981">"Ivumela umbambi ukuhlanganisa isixhumi esibonakalayo esisezingeni eliphezulu sesibonisi sesilawuli kude. Akumele idingelwe izinhlelo zokusebenza ezijwayelekile."</string>
     <string name="permlab_bindRemoteViews" msgid="5697987759897367099">"bophezela kube isevisi yesinqunjana"</string>
     <string name="permdesc_bindRemoteViews" msgid="4717987810137692572">"Ivumela umbambi ukuhlanganisa uxhumano nomsebenzisi kwezinga eliphezulu lensizakalo yesinqunjwana. Akusoze kwadingeka kwezinhlelo zokusebenza ezivamile."</string>
-    <string name="permlab_bindRouteProvider" msgid="4869394607915096847">"bophezela kusevisi yomhlinzeki womzila"</string>
-    <string name="permdesc_bindRouteProvider" msgid="4703804520859960329">"Ivumela isibambi ukubophezela kunoma yimuphi umhlinzeki womzila obhalisiwe. Akufanele kudingeke izinhlelo zokusebenza ezivamile."</string>
     <string name="permlab_bindDeviceAdmin" msgid="8704986163711455010">"xhumana nomphathi wedivaysi"</string>
     <string name="permdesc_bindDeviceAdmin" msgid="569715419543907930">"Ivumela ummeli ukuthumela okuqukethwe kumphathi wedivaysi. Akusoze kwadingeka kwizinhlelo zokusebenza ezivamile."</string>
     <string name="permlab_bindTvInput" msgid="5601264742478168987">"bophezela kokokufaka kwe-TV"</string>
@@ -613,6 +611,8 @@
     <string name="permlab_devicePower" product="default" msgid="4928622470980943206">"amandla efoni avuliwe noma avaliwe"</string>
     <string name="permdesc_devicePower" product="tablet" msgid="6689862878984631831">"Ivumela uhlelo lokusebenza ukuvala noma ukuvula ithebhulethi."</string>
     <string name="permdesc_devicePower" product="default" msgid="6037057348463131032">"Ivumela uhlelo lokusebenza ukuvula noma ukuvala ifoni."</string>
+    <string name="permlab_userActivity" msgid="1677844893921729548">"setha kabusha ukuphela kwesikhathi sokubonisa"</string>
+    <string name="permdesc_userActivity" msgid="651746160252248024">"Ivumela uhlelo lokusebenza ukusetha kabusha ukuphela kwesikhathi sokubonisa."</string>
     <string name="permlab_factoryTest" msgid="3715225492696416187">"sebenzisa kwimodi yokuhlola yemboni"</string>
     <string name="permdesc_factoryTest" product="tablet" msgid="3952059318359653091">"Sebenzise njengokuhlola komkhiqizi wezinga eliphansi, uvumela ukufinyelela okugcwele ihadiwe yethebhulethi. Itholakala kuphela lapho ithebhulethi isebenza kwimodi yokuhlola yomkhiqizi."</string>
     <string name="permdesc_factoryTest" product="default" msgid="8136644990319244802">"Sebenzise njengokuhlola komkhiqizi wezinga eliphansi, uvumela ukufinyelela okugcwele ihadiwe yefoni. Itholakala kuphela lapho ifoni isebenza kwimodi yokuhlola yomkhiqizi."</string>
@@ -714,12 +714,12 @@
     <string name="permdesc_cache_filesystem" msgid="5578967642265550955">"Ivumela uhlelo lokusebenza ukuthi ifunde futhi ibhale isistimu yokufayila amafayela esikhashana."</string>
     <string name="permlab_use_sip" msgid="2052499390128979920">"yenza/thola amakholi we-SIP"</string>
     <string name="permdesc_use_sip" msgid="2297804849860225257">"Ivumela uhlelo lokusebenza ukwenza nokuthola amakholi we-SIP."</string>
-    <string name="permlab_bind_call_service" msgid="6724009726671246551">"hlanganyela neskrini esingaphakathi kwekholi"</string>
-    <string name="permdesc_bind_call_service" msgid="8732547662442572435">"Ivumela uhlelo lokusebenza ukuthi lulawule ukuthi umsebenzisi ubona kanjani isikrini esingaphakathi kwekholi."</string>
-    <!-- no translation found for permlab_bind_connection_service (3557341439297014940) -->
-    <skip />
-    <!-- no translation found for permdesc_bind_connection_service (4008754499822478114) -->
-    <skip />
+    <string name="permlab_bind_incall_service" msgid="6773648341975287125">"hlanganyela neskrini esingaphakathi kwekholi"</string>
+    <string name="permdesc_bind_incall_service" msgid="8343471381323215005">"Ivumela uhlelo lokusebenza ukuthi lulawule ukuthi umsebenzisi ubona kanjani isikrini esingaphakathi kwekholi."</string>
+    <string name="permlab_bind_connection_service" msgid="3557341439297014940">"sebenzisana namasevisi wefoni"</string>
+    <string name="permdesc_bind_connection_service" msgid="4008754499822478114">"Ivumela uhlelo lokusebenza ukusebenzisana namasevisi wefoni ukwenza/ukwamukela amakholi."</string>
+    <string name="permlab_control_incall_experience" msgid="9061024437607777619">"nikezela ngomuzwa womsebenzisi ongaphakathi kwekholi"</string>
+    <string name="permdesc_control_incall_experience" msgid="915159066039828124">"Ivumela uhlelo lokusebenza ukunikezela ngomuzwa ongaphakathi kwekholi."</string>
     <string name="permlab_readNetworkUsageHistory" msgid="7862593283611493232">"funda ukusetshenziswa komlando wohleloxhumano"</string>
     <string name="permdesc_readNetworkUsageHistory" msgid="7689060749819126472">"Ivumela uhlelo lokusebenza ukuthi ifunde umlando wokusetshenziswa kwenethiwekhi emanethiwekhini athize kanye nasezinsizeni."</string>
     <string name="permlab_manageNetworkPolicy" msgid="2562053592339859990">"phatha inqubomgomo yenethiwekhi"</string>
@@ -732,8 +732,6 @@
     <string name="permdesc_bindNotificationListenerService" msgid="985697918576902986">"Ivumela umbambi ukubophezela kwisixhumi esibonakalayo sezinga eliphezulu lesevisi yomlaleli wesaziso. Akusoze kwadingeka kwizinhlelo zokusebenza ezivamile."</string>
     <string name="permlab_bindConditionProviderService" msgid="1180107672332704641">"hlanganisa kwisevisi yomhlinzeki wesimo"</string>
     <string name="permdesc_bindConditionProviderService" msgid="1680513931165058425">"Ivumela umbambi ukuhlanganisa isixhumi esibonakalayo seleveli ephezulu sesevisi yomhlinzeki wesimo. Akufanele kudingekele izinhlelo zokusebenza ezivamile."</string>
-    <string name="permlab_bindMediaRouteService" msgid="6637740382272686835">"hlanganisela kusevisi yomzila yemidiya"</string>
-    <string name="permdesc_bindMediaRouteService" msgid="6436655024972496687">"Ivumela umbambi ukuhlanganisa kusibonisi esiphezulu sesevisi yomzila wemidiya. Akufanele kudingeke kuzinhlelo zokusebenza ezivamile."</string>
     <string name="permlab_bindDreamService" msgid="4153646965978563462">"bophezela kusevisi yephupho"</string>
     <string name="permdesc_bindDreamService" msgid="7325825272223347863">"Ivumela isiphathi ukuthi sibophezele ukusebenzisana kwezinga eliphezulu kwesevisi yephupho. Akumele kudingelwe izinhlelo zokusebenza ezijwayelekile."</string>
     <string name="permlab_invokeCarrierSetup" msgid="3699600833975117478">"buyisela uhlelo lokusebenza lokulungiselelwa okunikezwe yinkampani yenethiwekhi"</string>
@@ -1205,6 +1203,7 @@
     <string name="whichSendApplicationNamed" msgid="2799370240005424391">"Yabelana no-%1$s"</string>
     <string name="whichHomeApplication" msgid="4616420172727326782">"Khetha uhlelo lokusebenza lwasekhaya"</string>
     <string name="alwaysUse" msgid="4583018368000610438">"Sebenzisa ngokuzenzakalelayo kulesenzo."</string>
+    <string name="use_a_different_app" msgid="8134926230585710243">"Sebenzisa uhlelo lokusebenza oluhlukile"</string>
     <string name="clearDefaultHintMsg" msgid="3252584689512077257">"Susa izilungiselelo zesistimu; Izinhlelo zokusebenza &amp; Okulandiwe"</string>
     <string name="chooseActivity" msgid="7486876147751803333">"Khetha okufanele kwenziwe"</string>
     <string name="chooseUsbActivity" msgid="6894748416073583509">"Kheth uhlelo lokusebenza yedivayisi ye-USB"</string>
@@ -1296,8 +1295,8 @@
     <string name="sms_control_yes" msgid="3663725993855816807">"Vumela"</string>
     <string name="sms_control_no" msgid="625438561395534982">"Nqaba"</string>
     <string name="sms_short_code_confirm_message" msgid="1645436466285310855">"I-&lt;b&gt;<xliff:g id="APP_NAME">%1$s</xliff:g>&lt;/b&gt; ingathanda ukuthumela umlayezo ku-&lt;b&gt;<xliff:g id="DEST_ADDRESS">%2$s</xliff:g>&lt;/b&gt;."</string>
-    <string name="sms_short_code_details" msgid="3492025719868078457">"Lokhu "<font fgcolor="#ffffb060">"kungabangela amashaji"</font>" ku-akhawunti yakho yeselula."</string>
-    <string name="sms_premium_short_code_details" msgid="5523826349105123687"><font fgcolor="#ffffb060">"Lokhu kuzobangela amashaji ku-akhawunti yakho yeselula."</font></string>
+    <string name="sms_short_code_details" msgid="5873295990846059400">"Lokhu "<b>"kungabangela ukukhokhiswa"</b>" ku-akhawunti yakho yeselula."</string>
+    <string name="sms_premium_short_code_details" msgid="7869234868023975"><b>"Lokhu kuzobangela ukukhokhiswa ku-akhawunti yakho yeselula."</b></string>
     <string name="sms_short_code_confirm_allow" msgid="4458878637111023413">"Thumela"</string>
     <string name="sms_short_code_confirm_deny" msgid="2927389840209170706">"Khansela"</string>
     <string name="sms_short_code_remember_choice" msgid="5289538592272218136">"Khumbula inketho yami"</string>
@@ -1352,7 +1351,7 @@
     <string name="adb_active_notification_message" msgid="1016654627626476142">"Thinta ukwenza ukuthi ukudibhaga kwe-USB kungasebenzi."</string>
     <string name="select_input_method" msgid="8547250819326693584">"Shintsha ikhibhodi"</string>
     <string name="configure_input_methods" msgid="4769971288371946846">"Khetha amakhibhodi"</string>
-    <string name="use_physical_keyboard" msgid="6203112478095117625">"Ukwakheka kwekhibhodi"</string>
+    <string name="show_ime" msgid="9157568568695230830">"Bonisa indlela yokufaka"</string>
     <string name="hardware" msgid="7517821086888990278">"I-Hardware"</string>
     <string name="select_keyboard_layout_notification_title" msgid="1407367017263030773">"Khetha isendlalelo sekhibhodi"</string>
     <string name="select_keyboard_layout_notification_message" msgid="4465907700449257063">"Thinta ukuze ukhethe isendlalelo sekhibhodi."</string>
@@ -1403,8 +1402,8 @@
     <string name="permdesc_bind_trust_agent_service" msgid="7041930026024507515">"Ivumela uhlelo lokusebenza ukuthi libophezeleke kusevisi yomsebenzeli wokuthemba."</string>
     <string name="permlab_recovery" msgid="3157024487744125846">"Ixhumana nesibuyekezo nesistimu yokutakula"</string>
     <string name="permdesc_recovery" msgid="8511774533266359571">"Ivumela uhlelo lokusebenza ukuthi lixhumane nesistimu yokutakula nezibuyekezo zesistimu."</string>
-    <string name="permlab_createMediaProjection" msgid="4941338725487978112">"Dala isikhathi sephrojekthi semidiya"</string>
-    <string name="permdesc_createMediaProjection" msgid="1284530992706219702">"Ivumela uhlelo lokusebenza ukudala isikhathi sephrojekthi. Lezo zikhathi zinganikela izinhlelo zokusebenza amandla wokuthwebula okuqukethwe okuboniswayo nokomsindo. Akufanele kudingwe izinhlelo zokusebenza ezivamile."</string>
+    <string name="permlab_manageMediaProjection" msgid="1120495449419929218">"Phatha izikhathi zokuvikela zemidiya"</string>
+    <string name="permdesc_manageMediaProjection" msgid="8053759147529492856">"Ivumela uhlelo lokusebenza ukuphatha isikhathi sokuvikela semidiya. Lezi zikhathi zinganiekela izinhlelo zokusebenza amandla wokuthwebula isibonisi nokuqukethwe komsindo. Akufanele kudingeke ngezinhlelo zokusebenza ezivamile."</string>
     <string name="permlab_readInstallSessions" msgid="6165432407628065939">"Funda izikhathi zokufaka"</string>
     <string name="permdesc_readInstallSessions" msgid="2049771699626019849">"Ivumela uhlelo lokusebenza ukufunda izikhathi. Lokhu kuzolivumela ukubona imininingwane mayelana nokufaka kwephakethi esebenzayo."</string>
     <string name="tutorial_double_tap_to_zoom_message_short" msgid="4070433208160063538">"Thinta kabili ukulawula ukusondeza"</string>
@@ -1425,8 +1424,8 @@
     <string name="deny" msgid="2081879885755434506">"Yala"</string>
     <string name="permission_request_notification_title" msgid="6486759795926237907">"Imvume Iceliwe"</string>
     <string name="permission_request_notification_with_subtitle" msgid="8530393139639560189">"Imvume Iceliwe \n ye-akhawunti <xliff:g id="ACCOUNT">%s</xliff:g>"</string>
-    <string name="forward_intent_to_owner" msgid="570916783072215572">"Usebenzisa lolu hlelo lokusebenza esikhaleni sakho sokusebenza somuntu siqu"</string>
-    <string name="forward_intent_to_work" msgid="8624579696577525279">"Usebenzisa lolu hlelo lokusebenza esikhaleni sakho sokusebenza"</string>
+    <string name="forward_intent_to_owner" msgid="1207197447013960896">"Usebenzisa lolu hlelo lokusebenza ngaphandle kwephrofayela yakho yomsebenzi"</string>
+    <string name="forward_intent_to_work" msgid="621480743856004612">"Usebenzisa lolu hlelo lokusebenza kuphrofayela yakho yomsebenzi"</string>
     <string name="input_method_binding_label" msgid="1283557179944992649">"Indlela yokufakwayo"</string>
     <string name="sync_binding_label" msgid="3687969138375092423">"Vumelanisaa"</string>
     <string name="accessibility_binding_label" msgid="4148120742096474641">"Ukufinyeleleka"</string>
@@ -1501,8 +1500,6 @@
     <string name="time_picker_decrement_hour_button" msgid="1377479863429214792">"Yehlisa ihora"</string>
     <string name="time_picker_increment_set_pm_button" msgid="4147590696151230863">"Setha Ntambama"</string>
     <string name="time_picker_decrement_set_am_button" msgid="8302140353539486752">"Setha Ekuseni"</string>
-    <string name="time_picker_pm_label" msgid="9075415075642718536">"PM"</string>
-    <string name="time_picker_am_label" msgid="7367798547923815593">"AM"</string>
     <string name="date_picker_increment_month_button" msgid="5369998479067934110">"Khulisa inyanga"</string>
     <string name="date_picker_decrement_month_button" msgid="1832698995541726019">"Yehlisa inyanga"</string>
     <string name="date_picker_increment_day_button" msgid="7130465412308173903">"Khulisa usuku"</string>
@@ -1535,11 +1532,11 @@
     <string name="extract_edit_menu_button" msgid="8940478730496610137">"Hlela"</string>
     <string name="data_usage_warning_title" msgid="1955638862122232342">"Isexwayiso sokusetshenziswa kwedatha"</string>
     <string name="data_usage_warning_body" msgid="2814673551471969954">"Thinta ze ubone ukusebenza kanye nezisetho"</string>
-    <string name="data_usage_3g_limit_title" msgid="4462365924791862301">"Idatha ye-2G-3G ivaliwe"</string>
-    <string name="data_usage_4g_limit_title" msgid="7476424187522765328">"Idatha ye-4G ivaliwe"</string>
-    <string name="data_usage_mobile_limit_title" msgid="3393439305227911006">"Idatha yeselula ivaliwe"</string>
-    <string name="data_usage_wifi_limit_title" msgid="3461968509557554571">"Idatha ye-Wi-Fi ivaliwe"</string>
-    <string name="data_usage_limit_body" msgid="6131350187562939365">"Kufinyelelwe kumkhawulo"</string>
+    <string name="data_usage_3g_limit_title" msgid="4361523876818447683">"2G-3G umkhawulo wedatha ufinyelelwe"</string>
+    <string name="data_usage_4g_limit_title" msgid="4609566827219442376">"4G umkhawulo wedatha ufinyelelwe"</string>
+    <string name="data_usage_mobile_limit_title" msgid="557158376602636112">"Umkhawulo wedatha yeselula ufinyelelwe"</string>
+    <string name="data_usage_wifi_limit_title" msgid="5803363779034792676">"Umkhawulo wedatha ye-Wi-Fi ufinyelelwe"</string>
+    <string name="data_usage_limit_body" msgid="291731708279614081">"Idatha imiswe ngokusetha kabusha umjikelezo"</string>
     <string name="data_usage_3g_limit_snoozed_title" msgid="7026739121138005231">"umkhawulo wedatha ye-2G-3G ufinyelelwe"</string>
     <string name="data_usage_4g_limit_snoozed_title" msgid="1106562779311209039">"Umkhawulo wedatha ye-4G ufinyelelwe"</string>
     <string name="data_usage_mobile_limit_snoozed_title" msgid="4941346653729943789">"Umkhawulo wedatha yeselula udliwe"</string>
@@ -1570,7 +1567,7 @@
     <string name="SetupCallDefault" msgid="5834948469253758575">"Amukela ucingo?"</string>
     <string name="activity_resolver_use_always" msgid="8017770747801494933">"Njalo"</string>
     <string name="activity_resolver_use_once" msgid="2404644797149173758">"Kanye nje"</string>
-    <string name="activity_resolver_work_profiles_support" msgid="5462991471861024343">"%1$s ayisekeli iphrofayela yomsebenzi."</string>
+    <string name="activity_resolver_work_profiles_support" msgid="185598180676883455">"%1$s ayisekeli iphrofayela yomsebenzi"</string>
     <string name="default_audio_route_name" product="tablet" msgid="4617053898167127471">"Ithebulethi"</string>
     <string name="default_audio_route_name" product="default" msgid="4239291273420140123">"Ifoni"</string>
     <string name="default_audio_route_name_headphones" msgid="8119971843803439110">"Ama-headphone"</string>
@@ -1643,6 +1640,7 @@
     <string name="accessibility_enabled" msgid="1381972048564547685">"Ukufinyelela kunikwe amandla."</string>
     <string name="enable_accessibility_canceled" msgid="3833923257966635673">"Ukufinyelela kukhanseliwe."</string>
     <string name="user_switched" msgid="3768006783166984410">"Umsebenzisi wamanje <xliff:g id="NAME">%1$s</xliff:g>."</string>
+    <string name="user_switching_message" msgid="2871009331809089783">"Ishintshela ku-<xliff:g id="NAME">%1$s</xliff:g>…"</string>
     <string name="owner_name" msgid="2716755460376028154">"Umnikazi"</string>
     <string name="error_message_title" msgid="4510373083082500195">"Iphutha"</string>
     <string name="error_message_change_not_allowed" msgid="1347282344200417578">"Le nguquko ayivumelekile ngomqondisi wakho"</string>
@@ -1764,31 +1762,28 @@
     <string name="item_is_selected" msgid="949687401682476608">"I-<xliff:g id="ITEM">%1$s</xliff:g> ekhethiwe"</string>
     <string name="deleted_key" msgid="7659477886625566590">"I-<xliff:g id="KEY">%1$s</xliff:g> isusiwe"</string>
     <string name="managed_profile_label_badge" msgid="2355652472854327647">"Umsebenzi <xliff:g id="LABEL">%1$s</xliff:g>"</string>
-    <!-- no translation found for lock_to_app_toast (1230563865743799321) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_accessible (3340628918851844044) -->
-    <skip />
-    <!-- no translation found for lock_to_app_toast_locked (8739004135132606329) -->
-    <skip />
-    <!-- no translation found for lock_to_app_title (1682643873107812874) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description (9076084599283282800) -->
-    <skip />
-    <!-- no translation found for lock_to_app_description_accessible (2132076937479670601) -->
-    <skip />
+    <string name="lock_to_app_toast" msgid="1230563865743799321">"Ukuze ususe ukuphina lesi sikrini, thinta futhi ubambe u-Emuva no-Kwakamuva ngesikhathi esisodwa."</string>
+    <string name="lock_to_app_toast_accessible" msgid="3340628918851844044">"Ukuze ususe ukuphina lesi sikrini, thinta futhi ubambe u-Kwakamuva."</string>
+    <string name="lock_to_app_toast_locked" msgid="8739004135132606329">"Isikrini siphiniwe. Ukususa ukuphina akuvumelekile inhlangano yakho."</string>
+    <string name="lock_to_app_title" msgid="1682643873107812874">"Sebenzisa ukuphina isikrini?"</string>
+    <string name="lock_to_app_description" msgid="9076084599283282800">"Ukuphina isikrini kukhiya isibonisi ngokubuka okukodwa.\n\nUkuze ushiye, thinta futhi ubambe u-Emuva no-Kwakamuca ngesikhathi esisodwa."</string>
+    <string name="lock_to_app_description_accessible" msgid="2132076937479670601">"Ukuphina isikrini kukhiya isibonisi ngokubuka okukodwa.\n\nUkuze uphume, thinta futhi ubambe u-Kwakamuva."</string>
     <string name="lock_to_app_negative" msgid="2259143719362732728">"CHA, NGIYABONGA"</string>
     <string name="lock_to_app_positive" msgid="7085139175671313864">"QALA"</string>
-    <!-- no translation found for lock_to_app_start (6643342070839862795) -->
-    <skip />
-    <!-- no translation found for lock_to_app_exit (8598219838213787430) -->
-    <skip />
-    <!-- no translation found for lock_to_app_use_screen_lock (5732663305876339596) -->
-    <skip />
-    <string name="lock_to_app_unlock_pin" msgid="7908385370846820001">"IPHINIKHODI"</string>
-    <string name="lock_to_app_unlock_pattern" msgid="7763071104790758405">"iphethini yokuvula"</string>
-    <string name="lock_to_app_unlock_password" msgid="795224196583495868">"iphasiwedi"</string>
-    <!-- no translation found for battery_saver_description (725676363406667978) -->
-    <skip />
-    <!-- no translation found for downtime_condition_summary (8761776337475705749) -->
-    <skip />
+    <string name="lock_to_app_start" msgid="6643342070839862795">"Isikrini siphiniwe"</string>
+    <string name="lock_to_app_exit" msgid="8598219838213787430">"Isikrini sisuswe ukuphina"</string>
+    <string name="lock_to_app_unlock_pin" msgid="2552556656504331634">"Cela iphinikhodi ngaphambi kokuphina"</string>
+    <string name="lock_to_app_unlock_pattern" msgid="4182192144797225137">"Cela iphethini yokuvula ngaphambi kokususa ukuphina"</string>
+    <string name="lock_to_app_unlock_password" msgid="6380979775916974414">"Cela iphasiwedi ngaphambi kokususa ukuphina"</string>
+    <string name="battery_saver_description" msgid="2510530476513605742">"Ukuze usize ukwenza kangcono impilo yebhethri, isilondolozi sebhethri sehlisa ukusebenza kwedivayisi yakho futhi sikhawulela ukudlidliza nedatha eningi yangasemuva. I-imeyili, imilayezo, nezinye izinhlelo zokusebenza ezincike ekuvumelaniseni kungenzeka zingabuyekezi ngaphandle kokuthi uzivule.\n\nIsilondolozi sebhethri sivaleka ngokuzenzakalelayo uma idivayisi yakho ishaja."</string>
+    <string name="downtime_condition_summary" msgid="8761776337475705749">"Kuze kuphele isikhathi sakho ngo-<xliff:g id="FORMATTEDTIME">%1$s</xliff:g>"</string>
+  <plurals name="zen_mode_duration_minutes">
+    <item quantity="one" msgid="9040808414992812341">"Iminithi elilodwa"</item>
+    <item quantity="other" msgid="6924190729213550991">"Amaminithi angu-%d"</item>
+  </plurals>
+  <plurals name="zen_mode_duration_hours">
+    <item quantity="one" msgid="3480040795582254384">"Ihora elilodwa"</item>
+    <item quantity="other" msgid="5408537517529822157">"Amahora angu-%d"</item>
+  </plurals>
+    <string name="zen_mode_forever" msgid="4316804956488785559">"Unaphakade"</string>
 </resources>
diff --git a/core/res/res/values/arrays.xml b/core/res/res/values/arrays.xml
index 327782d..a8b5d6d 100644
--- a/core/res/res/values/arrays.xml
+++ b/core/res/res/values/arrays.xml
@@ -397,30 +397,30 @@
        <item>@drawable/expander_open_mtrl_alpha</item>
        <item>@drawable/fastscroll_thumb_mtrl_alpha</item>
        <item>@drawable/fastscroll_track_mtrl_alpha</item>
-       <item>@drawable/ic_ab_back_mtrl_am_alpha</item>
+       <item>@drawable/ic_ab_back_material</item>
        <item>@drawable/ic_cab_done_mtrl_alpha</item>
        <item>@drawable/ic_clear_mtrl_alpha</item>
        <item>@drawable/ic_commit_search_api_mtrl_alpha</item>
-       <item>@drawable/ic_dialog_alert_mtrl_alpha</item>
+       <item>@drawable/ic_dialog_alert_material</item>
        <item>@drawable/ic_find_next_mtrl_alpha</item>
        <item>@drawable/ic_find_previous_mtrl_alpha</item>
-       <item>@drawable/ic_go_search_api_mtrl_alpha</item>
+       <item>@drawable/ic_go_search_api_material</item>
        <item>@drawable/ic_media_route_disabled_mtrl_alpha</item>
        <item>@drawable/ic_media_route_off_mtrl_alpha</item>
        <item>@drawable/ic_media_route_on_0_mtrl_alpha</item>
        <item>@drawable/ic_media_route_on_1_mtrl_alpha</item>
        <item>@drawable/ic_media_route_on_2_mtrl_alpha</item>
        <item>@drawable/ic_media_route_on_mtrl_alpha</item>
-       <item>@drawable/ic_menu_copy_mtrl_am_alpha</item>
-       <item>@drawable/ic_menu_cut_mtrl_alpha</item>
+       <item>@drawable/ic_menu_copy_material</item>
+       <item>@drawable/ic_menu_cut_material</item>
        <item>@drawable/ic_menu_find_mtrl_alpha</item>
-       <item>@drawable/ic_menu_moreoverflow_mtrl_alpha</item>
-       <item>@drawable/ic_menu_paste_mtrl_am_alpha</item>
+       <item>@drawable/ic_menu_moreoverflow_material</item>
+       <item>@drawable/ic_menu_paste_material</item>
        <item>@drawable/ic_menu_search_mtrl_alpha</item>
-       <item>@drawable/ic_menu_selectall_mtrl_alpha</item>
-       <item>@drawable/ic_menu_share_mtrl_alpha</item>
-       <item>@drawable/ic_search_api_mtrl_alpha</item>
-       <item>@drawable/ic_voice_search_api_mtrl_alpha</item>
+       <item>@drawable/ic_menu_selectall_material</item>
+       <item>@drawable/ic_menu_share_material</item>
+       <item>@drawable/ic_search_api_material</item>
+       <item>@drawable/ic_voice_search_api_material</item>
        <item>@drawable/list_divider_mtrl_alpha</item>
        <item>@drawable/list_section_divider_mtrl_alpha</item>
        <item>@drawable/popup_background_mtrl_mult</item>
@@ -506,12 +506,24 @@
 
     <!-- Used in LocalePicker -->
     <string-array translatable="false" name="special_locale_codes">
+        <!-- http://b/17150708 - ensure that the list of languages says "Arabic"
+             rather than "Arabic (Egypt)". If you're an OEM supporting multiple
+             Arabic locales, you should remove this entry so that ar_EG is shown
+             as "Arabic (Egypt)" in Settings. -->
+        <item>ar_EG</item>
+
         <item>zh_CN</item>
         <item>zh_TW</item>
     </string-array>
 
     <!-- Used in LocalePicker -->
     <string-array translatable="false" name="special_locale_names">
+        <!-- http://b/17150708 - ensure that the list of languages says "Arabic"
+             rather than "Arabic (Egypt)". If you're an OEM supporting multiple
+             Arabic locales, you should remove this entry so that ar_EG is shown
+             as "Arabic (Egypt)" in Settings. -->
+        <item>العربية</item>
+
         <item>中文 (简体)</item>
         <item>中文 (繁體)</item>
     </string-array>
diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml
index 89bda82..85c1072 100644
--- a/core/res/res/values/attrs.xml
+++ b/core/res/res/values/attrs.xml
@@ -308,6 +308,10 @@
                   null so it will not be drawn.
              </ul> -->
         <attr name="windowBackground" format="reference" />
+        <!-- Drawable to draw selectively within the inset areas when the windowBackground
+             has been set to null. This protects against seeing visual garbage in the
+             surface when the app has not drawn any content into this area. -->
+        <attr name="windowBackgroundFallback" format="reference" />
         <!-- Drawable to use as a frame around the window. -->
         <attr name="windowFrame" format="reference" />
         <!-- Flag indicating whether there should be no title on this window. -->
@@ -458,6 +462,10 @@
              transitions between different window content. -->
         <attr name="windowContentTransitionManager" format="reference" />
 
+        <!-- Flag indicating whether this window allows Activity Transitions.
+             Corresponds to {@link android.view.Window#FEATURE_ACTIVITY_TRANSITIONS}. -->
+        <attr name="windowActivityTransitions" format="boolean" />
+
         <!-- Reference to a Transition XML resource defining the desired Transition
              used to move Views into the initial Window's content Scene. Corresponds to
              {@link android.view.Window#setEnterTransition(android.transition.Transition)}. -->
@@ -514,8 +522,12 @@
         <!-- Flag indicating whether this Window's transition should overlap with
              the exiting transition of the called Activity when the called Activity
              finishes. Corresponds to
-             {@link android.view.Window#setAllowExitTransitionOverlap(boolean)}. -->
-        <attr name="windowAllowExitTransitionOverlap" format="boolean"/>
+             {@link android.view.Window#setAllowReturnTransitionOverlap(boolean)}. -->
+        <attr name="windowAllowReturnTransitionOverlap" format="boolean"/>
+
+        <!-- Indicates whether or not shared elements should use an overlay
+             during transitions. The default value is true. -->
+        <attr name="windowSharedElementsUseOverlay" format="boolean"/>
 
         <!-- Internal layout used internally for window decor -->
         <attr name="windowActionBarFullscreenDecorLayout" format="reference" />
@@ -733,6 +745,7 @@
         <attr name="fastScrollOverlayPosition">
             <enum name="floating" value="0" />
             <enum name="atThumb" value="1" />
+            <enum name="aboveThumb" value="2" />
         </attr>
         <!-- Text color for the fast scroll index overlay. Make sure it
              plays nicely with fastScrollPreviewBackground[Left|Right]. -->
@@ -1004,13 +1017,28 @@
         <!-- The color applied to framework buttons in their normal state. -->
         <attr name="colorButtonNormal" format="color" />
 
-        <!-- ================== -->
-        <!-- Hardware rendering -->
-        <!-- ================== -->
+        <!-- The color applied to framework switch thumbs in their normal state. -->
+        <attr name="colorSwitchThumbNormal" format="color" />
+
+        <!-- =================== -->
+        <!-- Lighting properties -->
+        <!-- =================== -->
         <eat-comment />
 
-        <!-- Reference to the Lighting style. -->
-        <attr name="lightingStyle" format="reference" />
+        <!-- @hide The default Y position of the light used to project view shadows. -->
+        <attr name="lightY" format="dimension" />
+
+        <!-- @hide The default Z position of the light used to project view shadows. -->
+        <attr name="lightZ" format="dimension" />
+
+        <!-- @hide The default radius of the light used to project view shadows. -->
+        <attr name="lightRadius" format="dimension" />
+
+        <!-- Alpha value of the ambient shadow projected by elevated views, between 0 and 1. -->
+        <attr name="ambientShadowAlpha" format="float" />
+
+        <!-- Alpha value of the spot shadow projected by elevated views, between 0 and 1. -->
+        <attr name="spotShadowAlpha" format="float" />
     </declare-styleable>
 
     <!-- **************************************************************** -->
@@ -1705,6 +1733,35 @@
         <enum name="KEYCODE_12" value="228" />
         <enum name="KEYCODE_LAST_CHANNEL" value="229" />
         <enum name="KEYCODE_TV_DATA_SERVICE" value="230" />
+        <enum name="KEYCODE_VOICE_ASSIST" value="231" />
+        <enum name="KEYCODE_TV_RADIO_SERVICE" value="232" />
+        <enum name="KEYCODE_TV_TELETEXT" value="233" />
+        <enum name="KEYCODE_TV_NUMBER_ENTRY" value="234" />
+        <enum name="KEYCODE_TV_TERRESTRIAL_ANALOG" value="235" />
+        <enum name="KEYCODE_TV_TERRESTRIAL_DIGITAL" value="236" />
+        <enum name="KEYCODE_TV_SATELLITE" value="237" />
+        <enum name="KEYCODE_TV_SATELLITE_BS" value="238" />
+        <enum name="KEYCODE_TV_SATELLITE_CS" value="239" />
+        <enum name="KEYCODE_TV_SATELLITE_SERVICE" value="240" />
+        <enum name="KEYCODE_TV_NETWORK" value="241" />
+        <enum name="KEYCODE_TV_ANTENNA_CABLE" value="242" />
+        <enum name="KEYCODE_TV_INPUT_HDMI_1" value="243" />
+        <enum name="KEYCODE_TV_INPUT_HDMI_2" value="244" />
+        <enum name="KEYCODE_TV_INPUT_HDMI_3" value="245" />
+        <enum name="KEYCODE_TV_INPUT_HDMI_4" value="246" />
+        <enum name="KEYCODE_TV_INPUT_COMPOSITE_1" value="247" />
+        <enum name="KEYCODE_TV_INPUT_COMPOSITE_2" value="248" />
+        <enum name="KEYCODE_TV_INPUT_COMPONENT_1" value="249" />
+        <enum name="KEYCODE_TV_INPUT_COMPONENT_2" value="250" />
+        <enum name="KEYCODE_TV_INPUT_VGA_1" value="251" />
+        <enum name="KEYCODE_TV_AUDIO_DESCRIPTION" value="252" />
+        <enum name="KEYCODE_TV_AUDIO_DESCRIPTION_MIX_UP" value="253" />
+        <enum name="KEYCODE_TV_AUDIO_DESCRIPTION_MIX_DOWN" value="254" />
+        <enum name="KEYCODE_TV_ZOOM_MODE" value="255" />
+        <enum name="KEYCODE_TV_CONTENTS_MENU" value="256" />
+        <enum name="KEYCODE_TV_MEDIA_CONTEXT_MENU" value="257" />
+        <enum name="KEYCODE_TV_TIMER_PROGRAMMING" value="258" />
+        <enum name="KEYCODE_HELP" value="259" />
     </attr>
 
     <!-- ***************************************************************** -->
@@ -1719,6 +1776,7 @@
     <!-- The set of attributes that describe a Windows's theme. -->
     <declare-styleable name="Window">
         <attr name="windowBackground" />
+        <attr name="windowBackgroundFallback" />
         <attr name="windowContentOverlay" />
         <attr name="windowFrame" />
         <attr name="windowNoTitle" />
@@ -1743,6 +1801,7 @@
         <attr name="windowTranslucentNavigation" />
         <attr name="windowSwipeToDismiss" />
         <attr name="windowContentTransitions" />
+        <attr name="windowActivityTransitions" />
         <attr name="windowContentTransitionManager" />
         <attr name="windowActionBarFullscreenDecorLayout" />
 
@@ -1832,8 +1891,12 @@
         <!-- Flag indicating whether this Window's transition should overlap with
              the exiting transition of the called Activity when the called Activity
              finishes. Corresponds to
-             {@link android.view.Window#setAllowExitTransitionOverlap(boolean)}. -->
-        <attr name="windowAllowExitTransitionOverlap"/>
+             {@link android.view.Window#setAllowReturnTransitionOverlap(boolean)}. -->
+        <attr name="windowAllowReturnTransitionOverlap"/>
+
+        <!-- Indicates whether or not shared elements should use an overlay
+             during transitions. The default value is true. -->
+        <attr name="windowSharedElementsUseOverlay"/>
 
         <!-- Flag indicating whether this Window is responsible for drawing the background for the
              system bars. If true and the window is not floating, the system bars are drawn with a
@@ -1896,6 +1959,8 @@
         <attr name="listItemLayout" format="reference" />
         <attr name="progressLayout" format="reference" />
         <attr name="horizontalProgressLayout" format="reference" />
+        <!-- @hide Whether fullDark, etc. should use default values if null. -->
+        <attr name="needsDefaultBackgrounds" format="boolean" />
     </declare-styleable>
 
     <!-- Fragment animation class attributes. -->
@@ -1940,7 +2005,7 @@
         <!--  When opening an activity in a new task using Intent/FLAG_ACTIVITY_LAUNCH_BEHIND,
               this is the animation that is run on the activity of the new task (which is
               entering the screen and then leaving). -->
-        <attr name="launchTaskBehindBackgroundAnimation" format="reference" />
+        <attr name="launchTaskBehindTargetAnimation" format="reference" />
         <!--  When opening an activity in a new task using Intent.FLAG_ACTIVITY_LAUNCH_BEHIND,
               this is the animation that is run on the activity of the old task (which is
               already on the screen and then stays on). -->
@@ -2512,6 +2577,19 @@
                  result to valid color values. Saturate(S + D) -->
             <enum name="add" value="16" />
         </attr>
+
+        <!-- ViewOutlineProvider used to determine the View's Outline. -->
+        <attr name="outlineProvider">
+            <!-- Default, background drawable-driven outline. -->
+            <enum name="background" value="0" />
+            <!-- No outline provider. -->
+            <enum name="none" value="1" />
+            <!-- Generates an opaque outline for the bounds of the view. -->
+            <enum name="bounds" value="2" />
+            <!-- Generates an opaque outline for the padded bounds of the view. -->
+            <enum name="paddedBounds" value="3" />
+        </attr>
+
     </declare-styleable>
 
     <!-- Attributes that can be assigned to a tag for a particular View. -->
@@ -3196,6 +3274,8 @@
             <enum name="floating" value="0" />
             <!-- Pinned alongside the thumb. -->
             <enum name="atThumb" value="1" />
+            <!-- Pinned above the thumb. -->
+            <enum name="aboveThumb" value="2" />
         </attr>
         <attr name="textAppearance" />
         <attr name="textColor" />
@@ -3366,7 +3446,7 @@
         <!-- An optional argument to supply a maximum height for this view.
              See {see android.widget.ImageView#setMaxHeight} for details. -->
         <attr name="maxHeight" format="dimension" />
-        <!-- Set a tinting color for the image. -->
+        <!-- Set a tinting color for the image. By default, the tint will blend using SRC_ATOP mode. -->
         <attr name="tint" format="color" />
         <!-- If true, the image view will be baseline aligned with based on its
              bottom edge. -->
@@ -3379,8 +3459,6 @@
         <!-- @hide The alpha value (0-255) set on the ImageView's drawable. Equivalent
              to calling ImageView.setAlpha(int), not the same as View.setAlpha(float). -->
         <attr name="drawableAlpha" format="integer" />
-        <!-- Tint to apply to the image. -->
-        <attr name="tint" />
         <!-- Blending mode used to apply the image tint. -->
         <attr name="tintMode" />
     </declare-styleable>
@@ -3783,13 +3861,17 @@
         <attr name="textColorLink" />
         <!-- Present the text in ALL CAPS. This may use a small-caps form when available. -->
         <attr name="textAllCaps" format="boolean" />
-        <!-- Place a shadow of the specified color behind the text. -->
+        <!-- Place a blurred shadow of text underneath the text, drawn with the
+             specified color. The text shadow produced does not interact with
+             properties on View that are responsible for real time shadows,
+             {@link android.R.styleable#View_elevation elevation} and
+             {@link android.R.styleable#View_translationZ translationZ}. -->
         <attr name="shadowColor" format="color" />
-        <!-- Horizontal offset of the shadow. -->
+        <!-- Horizontal offset of the text shadow. -->
         <attr name="shadowDx" format="float" />
-        <!-- Vertical offset of the shadow. -->
+        <!-- Vertical offset of the text shadow. -->
         <attr name="shadowDy" format="float" />
-        <!-- Radius of the shadow. -->
+        <!-- Blur radius of the text shadow. -->
         <attr name="shadowRadius" format="float" />
         <!-- Elegant text height, especially for less compacted complex script text. -->
         <attr name="elegantTextHeight" format="boolean" />
@@ -3930,13 +4012,17 @@
         <!-- Set an input filter to constrain the text length to the
              specified number. -->
         <attr name="maxLength" format="integer" min="0" />
-        <!-- Place a shadow of the specified color behind the text. -->
+        <!-- Place a blurred shadow of text underneath the text, drawn with the
+             specified color. The text shadow produced does not interact with
+             properties on View that are responsible for real time shadows,
+             {@link android.R.styleable#View_elevation elevation} and
+             {@link android.R.styleable#View_translationZ translationZ}. -->
         <attr name="shadowColor" />
-        <!-- Horizontal offset of the shadow. -->
+        <!-- Horizontal offset of the text shadow. -->
         <attr name="shadowDx" />
-        <!-- Vertical offset of the shadow. -->
+        <!-- Vertical offset of the text shadow. -->
         <attr name="shadowDy" />
-        <!-- Radius of the shadow. -->
+        <!-- Blur radius of the text shadow. -->
         <attr name="shadowRadius" />
         <attr name="autoLink" />
         <!-- If set to false, keeps the movement method from being set
@@ -4124,10 +4210,6 @@
         <attr name="completionThreshold" format="integer" min="1" />
         <!-- Selector in a drop down list. -->
         <attr name="dropDownSelector" format="reference|color" />
-        <!-- Amount of pixels by which the drop down should be offset vertically. -->
-        <attr name="dropDownVerticalOffset" format="dimension" />
-        <!-- Amount of pixels by which the drop down should be offset horizontally. -->
-        <attr name="dropDownHorizontalOffset" format="dimension" />
         <!-- View to anchor the auto-complete dropdown to. If not specified, the text view itself
              is used. -->
         <attr name="dropDownAnchor" format="reference" />
@@ -4175,6 +4257,12 @@
         <!-- Whether the popup window should overlap its anchor view. -->
         <attr name="overlapAnchor" format="boolean" />
     </declare-styleable>
+    <declare-styleable name="ListPopupWindow">
+        <!-- Amount of pixels by which the drop down should be offset vertically. -->
+        <attr name="dropDownVerticalOffset" format="dimension" />
+        <!-- Amount of pixels by which the drop down should be offset horizontally. -->
+        <attr name="dropDownHorizontalOffset" format="dimension" />
+    </declare-styleable>
     <declare-styleable name="ViewAnimator">
         <!-- Identifier for the animation to use when a view is shown. -->
         <attr name="inAnimation" format="reference" />
@@ -4233,12 +4321,6 @@
         <attr name="popupBackground" />
         <!-- Window elevation to use for the dropdown in spinnerMode="dropdown". -->
         <attr name="popupElevation" />
-        <!-- Vertical offset from the spinner widget for positioning the dropdown in
-             spinnerMode="dropdown". -->
-        <attr name="dropDownVerticalOffset" />
-        <!-- Horizontal offset from the spinner widget for positioning the dropdown
-             in spinnerMode="dropdown". -->
-        <attr name="dropDownHorizontalOffset" />
         <!-- Width of the dropdown in spinnerMode="dropdown". -->
         <attr name="dropDownWidth" />
         <!-- Reference to a layout to use for displaying a prompt in the dropdown for
@@ -4267,12 +4349,14 @@
         <attr name="minDate" format="string" />
         <!-- The maximal date shown by this calendar view in mm/dd/yyyy format. -->
         <attr name="maxDate" format="string" />
+        <!-- The first day of week according to {@link java.util.Calendar}. -->
+        <attr name="firstDayOfWeek" />
         <!-- @hide The layout of the date picker. -->
         <attr name="internalLayout" format="reference"  />
         <!-- @hide The layout of the legacy DatePicker. -->
         <attr name="legacyLayout" />
         <!-- The background color for the date selector 's day of week. -->
-        <attr name="dayOfWeekBackgroundColor" format="color" />
+        <attr name="dayOfWeekBackground" format="color|reference" />
         <!-- The text color for the date selector's day of week. -->
         <attr name="dayOfWeekTextAppearance" format="reference" />
         <!-- The month's text appearance in the date selector. -->
@@ -4281,8 +4365,8 @@
         <attr name="headerDayOfMonthTextAppearance" format="reference" />
         <!-- The year's text appearance in the date selector. -->
         <attr name="headerYearTextAppearance" format="reference" />
-        <!-- The background color for the date selector. -->
-        <attr name="headerBackgroundColor" />
+        <!-- The background for the date selector. -->
+        <attr name="headerBackground" />
         <!-- @hide The selected text color for the date selector. Used as a
              backup if the text appearance does not explicitly have a color
              set for the selected state. -->
@@ -4407,12 +4491,12 @@
         <!-- The row boundary delimiting the top of the group of cells
         occupied by this view. -->
         <attr name="layout_row" format="integer" />
-        <!-- The row span: the difference between the bottom and top
+        <!-- The row span: the difference between the top and bottom
         boundaries delimiting the group of cells occupied by this view.
         The default is one.
         See {@link android.widget.GridLayout.Spec}. -->
         <attr name="layout_rowSpan" format="integer" min="1" />
-        <!-- The relative proportion of horizontal space that should be allocated to this view
+        <!-- The relative proportion of vertical space that should be allocated to this view
         during excess space distribution. -->
         <attr name="layout_rowWeight" format="float" />
         <!-- The column boundary delimiting the left of the group of cells
@@ -4423,7 +4507,7 @@
         The default is one.
         See {@link android.widget.GridLayout.Spec}. -->
         <attr name="layout_columnSpan" format="integer" min="1" />
-        <!-- The relative proportion of vertical space that should be allocated to this view
+        <!-- The relative proportion of horizontal space that should be allocated to this view
         during excess space distribution. -->
         <attr name="layout_columnWeight" format="float" />
         <!-- Gravity specifies how a component should be placed in its group of cells.
@@ -4579,29 +4663,29 @@
         <attr name="legacyLayout" format="reference" />
         <!-- @hide The layout of the time picker. -->
         <attr name="internalLayout" />
-        <!-- The text appearance for the AM/PM header of the TimePicker. -->
+        <!-- The text appearance for the AM/PM header. -->
         <attr name="headerAmPmTextAppearance" format="reference" />
-        <!-- The text appearance for the time header of the TimePicker. -->
+        <!-- The text appearance for the time header. -->
         <attr name="headerTimeTextAppearance" format="reference" />
         <!-- @hide The text color for selected time header of the TimePicker.
              This will override the value from the text appearance if it does
              not explicitly have a color set for the selected state. -->
         <attr name="headerSelectedTextColor" format="color" />
-        <!-- The background color for the header of the TimePicker. -->
-        <attr name="headerBackgroundColor" format="color" />
-        <!-- The color for the hours/minutes numbers of the TimePicker. -->
+        <!-- The background for the header containing the currently selected time. -->
+        <attr name="headerBackground" />
+        <!-- The color for the hours/minutes numbers. -->
         <attr name="numbersTextColor" format="color" />
-        <!-- The background color for the hours/minutes numbers of the TimePicker. -->
+        <!-- The background color for the hours/minutes numbers. -->
         <attr name="numbersBackgroundColor" format="color" />
-        <!-- The color for the AM/PM selectors of the TimePicker. -->
+        <!-- The color for the AM/PM selectors. -->
         <attr name="amPmTextColor" format="color" />
-        <!-- The background color state list for the AM/PM selectors of the TimePicker. -->
+        <!-- The background color state list for the AM/PM selectors. -->
         <attr name="amPmBackgroundColor" format="color" />
         <!-- @hide The background color for the AM/PM selectors of the
              TimePicker when selected. Used if the background color does not
              explicitly have a color set for the selected state. -->
         <attr name="amPmSelectedBackgroundColor" format="color" />
-        <!-- The color for the hours/minutes selector of the TimePicker. -->
+        <!-- The color for the hours/minutes selector. -->
         <attr name="numbersSelectorColor" format="color" />
         <!-- Defines the look of the widget. Prior to the L release, the only choice was
              spinner. As of L, with the Material theme selected, the default layout is clock,
@@ -5190,11 +5274,16 @@
         <attr name="viewportWidth" format="float"/>
         <!-- The height of the canvas the drawing is on. -->
         <attr name="viewportHeight" format="float"/>
+        <!-- The name of this vector drawable -->
+        <attr name="name" />
+        <!-- The opacity of the whole vector drawable, as a value between 0
+             (completely transparent) and 1 (completely opaque). -->
+        <attr name="alpha" />
     </declare-styleable>
 
     <!-- Defines the group used in VectorDrawables. -->
     <declare-styleable name="VectorDrawableGroup">
-        <!-- The Name of this group -->
+        <!-- The name of this group -->
         <attr name="name" />
         <!-- The amount to rotate the group -->
         <attr name="rotation" />
@@ -5210,20 +5299,24 @@
         <attr name="scaleX" />
         <!-- The amount to scale the group on X coordinate -->
         <attr name="scaleY" />
-        <!-- The alpha of the group (0 is transparent and 1 is opaque) -->
-        <attr name="alpha" />
     </declare-styleable>
 
     <!-- Defines the path used in VectorDrawables. -->
     <declare-styleable name="VectorDrawablePath">
-        <!-- The Name of this path -->
+        <!-- The name of this path -->
         <attr name="name" />
         <!-- The width a path stroke -->
         <attr name="strokeWidth" format="float" />
         <!-- The color to stroke the path if not defined implies no stroke-->
         <attr name="strokeColor" format="color" />
+        <!-- The opacity of a path stroke, as a value between 0 (completely transparent)
+             and 1 (completely opaque) -->
+        <attr name="strokeAlpha" format="float" />
         <!-- The color to fill the path if not defined implies no fill-->
         <attr name="fillColor" format="color" />
+        <!-- The alpha of the path fill, as a value between 0 (completely transparent)
+             and 1 (completely opaque)-->
+        <attr name="fillAlpha" format="float" />
         <!-- The specification of the operations that define the path  -->
         <attr name="pathData" format="string" />
         <!-- The fraction of the path to trim from the start from 0 to 1 -->
@@ -5496,7 +5589,7 @@
          resource are available in addition to the specific attributes of Fade
          described here. -->
     <declare-styleable name="Fade">
-        <!-- Equivalent to <code>visibilityMode</code>, fadingMode works only
+        <!-- Equivalent to <code>transitionVisibilityMode</code>, fadingMode works only
              with the Fade transition. -->
         <attr name="fadingMode">
             <!-- Fade will only fade appearing items in. -->
@@ -5532,7 +5625,7 @@
     <declare-styleable name="VisibilityTransition">
         <!-- Changes whether the transition supports appearing and/or disappearing Views.
              Corresponds to {@link android.transition.Visibility#setMode(int)}. -->
-        <attr name="visibilityMode">
+        <attr name="transitionVisibilityMode">
             <!-- Only appearing Views will be supported. -->
             <flag name="mode_in" value="1" />
             <!-- Only disappearing Views will be supported. -->
@@ -5573,6 +5666,19 @@
         </attr>
     </declare-styleable>
 
+    <!-- Use <code>changeTransform</code> as the root tag of the XML resource that
+         describes a {@link android.transition.ChangeTransform} transition. -->
+    <declare-styleable name="ChangeTransform">
+        <!-- A parent change should use an overlay or affect the transform of the
+             transitionining View. Default is true. Corresponds to
+             {@link android.transition.ChangeTransform#setReparentWithOverlay(boolean)}. -->
+        <attr name="reparentWithOverlay" format="boolean"/>
+
+        <!-- Tells ChangeTransform to track parent changes. Default is true. Corresponds to
+             {@link android.transition.ChangeTransform#setReparent(boolean)}. -->
+        <attr name="reparent" format="boolean"/>
+    </declare-styleable>
+
     <!-- Use <code>transitionManager</code> as the root tag of the XML resource that
          describes a {@link android.transition.TransitionManager
          TransitionManager}. -->
@@ -5599,12 +5705,12 @@
         <attr name="maximumAngle" format="float" />
     </declare-styleable>
 
-    <!-- Use <code>patternMotion</code> as the root tag of the XML resource that
-         describes a {@link android.transition.PatternMotion}. This must be used
+    <!-- Use <code>patternPathMotion</code> as the root tag of the XML resource that
+         describes a {@link android.transition.PatternPathMotion}. This must be used
          within a transition with which the PathMotion should be associated. -->
-    <declare-styleable name="PatternMotion">
-        <!-- The path string describing the pattern to use for the PathMotion. -->
-        <attr name="pathData" />
+    <declare-styleable name="PatternPathMotion">
+        <!-- The path string describing the pattern to use for the PathPathMotion. -->
+        <attr name="patternPathData" format="string" />
     </declare-styleable>
 
     <!-- ========================== -->
@@ -6513,12 +6619,12 @@
             <flag name="vertical" value="0x2" />
         </attr>
         <!-- Optional parameter which indicates where this widget can be shown,
-             ie. home screen, keyguard, recents or any combination thereof.
+             ie. home screen, keyguard, search bar or any combination thereof.
              Supports combined values using | operator. -->
         <attr name="widgetCategory" format="integer">
             <flag name="home_screen" value="0x1" />
             <flag name="keyguard" value="0x2" />
-            <flag name="recents" value="0x4" />
+            <flag name="searchbox" value="0x4" />
         </attr>
     </declare-styleable>
 
@@ -6570,6 +6676,53 @@
              IDs (through the android:id attribute) instead of tags because
              they are faster and allow for compile-time type checking. -->
         <attr name="tag" />
+
+        <!-- The Transition that will be used to move Views out of the scene when the
+             fragment is removed, hidden, or detached when not popping the back stack.
+             Corresponds to {@link android.app.Fragment#setExitTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentExitTransition" format="reference"/>
+
+        <!-- The Transition that will be used to move Views into the initial scene.
+             Corresponds to {@link android.app.Fragment#setEnterTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentEnterTransition" format="reference"/>
+
+        <!-- The Transition that will be used for shared elements transferred into the content
+             Scene.
+             Corresponds to {@link android.app.Fragment#setSharedElementEnterTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentSharedElementEnterTransition" format="reference"/>
+
+        <!-- The Transition that will be used to move Views out of the scene when the Fragment is
+             preparing to be removed, hidden, or detached because of popping the back stack.
+             Corresponds to {@link android.app.Fragment#setReturnTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentReturnTransition" format="reference"/>
+
+        <!-- The Transition that will be used for shared elements transferred back during a
+             pop of the back stack. This Transition acts in the leaving Fragment.
+             Corresponds to {@link android.app.Fragment#setSharedElementReturnTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentSharedElementReturnTransition" format="reference"/>
+
+        <!-- The Transition that will be used to move Views in to the scene when returning due
+             to popping a back stack.
+             Corresponds to {@link android.app.Fragment#setReenterTransition(
+             android.transition.Transition)} -->
+        <attr name="fragmentReenterTransition" format="reference"/>
+
+        <!-- Sets whether the enter and exit transitions should overlap when transitioning
+             forward.
+             Corresponds to {@link android.app.Fragment#setAllowEnterTransitionOverlap(
+             boolean)} -->
+        <attr name="fragmentAllowEnterTransitionOverlap" format="reference"/>
+
+        <!-- Sets whether the enter and exit transitions should overlap when transitioning
+             because of popping the back stack.
+             Corresponds to {@link android.app.Fragment#setAllowReturnTransitionOverlap(
+             boolean)} -->
+        <attr name="fragmentAllowReturnTransitionOverlap" format="reference"/>
     </declare-styleable>
 
     <!-- Use <code>device-admin</code> as the root tag of the XML resource that
@@ -6882,8 +7035,8 @@
         <attr name="searchKeyphraseId" format="integer" />
         <!-- The actual keyphrase/hint text, or empty if not keyphrase dependent. @hide @SystemApi -->
         <attr name="searchKeyphrase" format="string" />
-        <!-- A comma separated list of java locales that are supported for this keyphrase,
-             or empty if not locale dependent. @hide @SystemApi -->
+        <!-- A comma separated list of BCP-47 language tag for locales that are supported
+             for this keyphrase, or empty if not locale dependent. @hide @SystemApi -->
         <attr name="searchKeyphraseSupportedLocales" format="string" />
         <!-- Flags for supported recognition modes. @hide @SystemApi -->
         <attr name="searchKeyphraseRecognitionFlags">
@@ -6983,6 +7136,8 @@
         <attr name="backgroundSplit" />
         <!-- Specifies a fixed height for the action mode bar. -->
         <attr name="height" />
+        <!-- Specifies a layout to use for the "close" item at the starting edge. -->
+        <attr name="closeItemLayout" format="reference" />
     </declare-styleable>
 
     <declare-styleable name="SearchView">
@@ -7015,6 +7170,7 @@
         <attr name="queryBackground" format="reference" />
         <!-- Background for the section containing the action (e.g. voice search) -->
         <attr name="submitBackground" format="reference" />
+        <attr name="focusable" />
     </declare-styleable>
 
     <declare-styleable name="Switch">
@@ -7055,9 +7211,9 @@
         <!-- Drawable to use as the icon bitmap. -->
         <attr name="bitmap" format="reference" />
         <!-- X coordinate of the icon hot spot. -->
-        <attr name="hotSpotX" format="float" />
+        <attr name="hotSpotX" format="dimension" />
         <!-- Y coordinate of the icon hot spot. -->
-        <attr name="hotSpotY" format="float" />
+        <attr name="hotSpotY" format="dimension" />
     </declare-styleable>
 
     <declare-styleable name="Storage">
@@ -7261,6 +7417,12 @@
         <!-- Reference to a theme that should be used to inflate popups
              shown by widgets in the toolbar. -->
         <attr name="popupTheme" format="reference" />
+        <!-- Icon drawable to use for the navigation button located at
+             the start of the toolbar. -->
+        <attr name="navigationIcon" format="reference" />
+        <!-- Text to set as the content description for the navigation button
+             located at the start of the toolbar. -->
+        <attr name="navigationContentDescription" format="string" />
     </declare-styleable>
 
     <declare-styleable name="Toolbar_LayoutParams">
@@ -7276,7 +7438,7 @@
         <attr name="colorPrimary" />
     </declare-styleable>
 
-    <!-- Use <code>tv-input</code> as the root tag of the XML resource that describes an
+    <!-- Use <code>tv-input</code> as the root tag of the XML resource that describes a
          {@link android.media.tv.TvInputService}, which is referenced from its
          {@link android.media.tv.TvInputService#SERVICE_META_DATA} meta-data entry.
          Described here are the attributes that can be included in that tag. -->
@@ -7287,8 +7449,38 @@
         <!-- Component name of an activity that allows the user to modify
              the settings for this service. -->
         <attr name="settingsActivity" />
-        <!-- Reference to an XML document that describes TV content rating. -->
-        <attr name="tvContentRatingDescription" format="reference" />
+    </declare-styleable>
+
+    <!-- Attributes that can be used with <code>rating-system-definition</code> tags inside of the
+         XML resource that describes TV content rating of a {@link android.media.tv.TvInputService},
+         which is referenced from its
+         {@link android.media.tv.TvInputManager#META_DATA_CONTENT_RATING_SYSTEMS}. -->
+    <declare-styleable name="RatingSystemDefinition">
+        <!-- The unique name of the content rating system. -->
+        <attr name="name" />
+        <!-- The title of the content rating system which is shown to the user. -->
+        <attr name="title" />
+        <!-- The short description of the content rating system. -->
+        <attr name="description" />
+        <!-- The country code associated with the content rating system, which consists of two
+             uppercase letters that conform to the ISO 3166 standard. -->
+        <attr name="country" format="string" />
+    </declare-styleable>
+
+    <!-- Attributes that can be used with <code>rating-definition</code> tags inside of the XML
+         resource that describes TV content rating of a {@link android.media.tv.TvInputService},
+         which is referenced from its
+         {@link android.media.tv.TvInputManager#META_DATA_CONTENT_RATING_SYSTEMS}. -->
+    <declare-styleable name="RatingDefinition">
+        <!-- The unique name of the content rating. -->
+        <attr name="name" />
+        <!-- The title of the content rating which is shown to the user. -->
+        <attr name="title" />
+        <!-- The short description of the content rating. -->
+        <attr name="description" />
+        <!-- The age associated with the content rating. The content of this rating is suitable for
+             people of this age or above. -->
+        <attr name="contentAgeHint" format="integer" />
     </declare-styleable>
 
     <declare-styleable name="ResolverDrawerLayout">
@@ -7305,11 +7497,11 @@
 
     <!-- @hide -->
     <declare-styleable name="Lighting">
-        <attr name="lightY" format="dimension" />
-        <attr name="lightZ" format="dimension" />
-        <attr name="lightRadius" format="dimension" />
-        <attr name="ambientShadowAlpha" format="float" />
-        <attr name="spotShadowAlpha" format="float" />
+        <attr name="lightY" />
+        <attr name="lightZ" />
+        <attr name="lightRadius" />
+        <attr name="ambientShadowAlpha" />
+        <attr name="spotShadowAlpha" />
     </declare-styleable>
 
     <declare-styleable name="RestrictionEntry">
diff --git a/core/res/res/values/attrs_manifest.xml b/core/res/res/values/attrs_manifest.xml
index 7d4c37e..10c2518e 100644
--- a/core/res/res/values/attrs_manifest.xml
+++ b/core/res/res/values/attrs_manifest.xml
@@ -277,17 +277,6 @@
          applications can request this feature. Default value is false. -->
     <attr name="requiredForAllUsers" format="boolean" />
 
-    <!-- Flag to specifiy for which types of profile this application needs to be present.
-         Only pre-installed applications can request this feature. Default is none. -->
-    <attr name="requiredForProfile">
-        <!-- This application needs to be present for restricted profiles -->
-        <flag name="restricted" value="0x0001" />
-        <!-- This application needs to be present for managed profiles -->
-        <flag name="managed" value="0x0002" />
-        <!-- This application needs to be present for all types of profiles -->
-        <flag name="all" value="0xFFFF" />
-    </attr>
-
     <!-- Flag indicating whether the application can be debugged, even when
          running on a device that is running in user mode. -->
     <attr name="debuggable" format="boolean" />
@@ -950,7 +939,7 @@
          {@link android.content.Intent#FLAG_ACTIVITY_MULTIPLE_TASK
          Intent.FLAG_ACTIVITY_MULTIPLE_TASK}. If the value of
          documentLaunchModes is <code>never</code> then any use of
-.........{@link android.content.Intent#FLAG_ACTIVITY_NEW_DOCUMENT
+         {@link android.content.Intent#FLAG_ACTIVITY_NEW_DOCUMENT
          Intent.FLAG_ACTIVITY_NEW_DOCUMENT} to launch this activity will be ignored. -->
     <attr name="documentLaunchMode">
         <!-- The default mode, which will create a new task only when
@@ -1005,6 +994,15 @@
          TaskDescription to change labels, colors and icons in the recent task list. -->
     <attr name="relinquishTaskIdentity" format="boolean" />
 
+    <!-- Indicate that it is okay for this activity be resumed while the previous
+         activity is in the process of pausing, without waiting for the previous pause
+         to complete.  Use this with caution: your activity can not acquire any exclusive
+         resources (such as opening the camera or recording audio) when it launches, or it
+         may conflict with the previous activity and fail.
+
+         <p>The default value of this attribute is <code>false</code>. -->
+    <attr name="resumeWhilePausing" format="boolean" />
+
     <!-- The <code>manifest</code> tag is the root of an
          <code>AndroidManifest.xml</code> file,
          describing the contents of an Android package (.apk) file.  One
@@ -1073,7 +1071,6 @@
         <attr name="hasCode" format="boolean" />
         <attr name="persistent" />
         <attr name="requiredForAllUsers" />
-        <attr name="requiredForProfile" />
         <!-- Specify whether the components in this application are enabled or not (that is, can be
              instantiated by the system).
              If "false", it overrides any component specific values (a value of "true" will not
@@ -1690,6 +1687,7 @@
         <attr name="maxRecents" />
         <attr name="autoRemoveFromRecents" />
         <attr name="relinquishTaskIdentity" />
+        <attr name="resumeWhilePausing" />
     </declare-styleable>
     
     <!-- The <code>activity-alias</code> tag declares a new
diff --git a/core/res/res/values/colors.xml b/core/res/res/values/colors.xml
index dd316ed..cbaf54f 100644
--- a/core/res/res/values/colors.xml
+++ b/core/res/res/values/colors.xml
@@ -127,12 +127,14 @@
 
     <drawable name="notification_template_icon_bg">#3333B5E5</drawable>
     <drawable name="notification_template_icon_low_bg">#0cffffff</drawable>
+    <drawable name="notification_template_divider">#29000000</drawable>
+    <drawable name="notification_template_divider_media">#29ffffff</drawable>
 
-    <color name="notification_icon_bg_color">#ffa3a3a3</color>
-    <color name="notification_action_legacy_color_filter">#ff555555</color>
+    <color name="notification_icon_bg_color">#ff9e9e9e</color>
+    <color name="notification_action_color_filter">@color/secondary_text_material_light</color>
 
-    <color name="notification_media_action_bg">#00000000</color>
-    <color name="notification_media_progress">#FFFFFFFF</color>
+    <color name="notification_media_primary_color">@color/primary_text_material_dark</color>
+    <color name="notification_media_secondary_color">@color/secondary_text_material_dark</color>
 
     <!-- Keyguard colors -->
     <color name="keyguard_avatar_frame_color">#ffffffff</color>
@@ -142,5 +144,19 @@
 
     <color name="accessibility_focus_highlight">#bf39b500</color>
 
+    <color name="system_notification_accent_color">#ff607D8B</color>
+    <color name="battery_saver_mode_color">#fff4511e</color><!-- deep orange 600 -->
+
+    <!-- Default user icon colors -->
+    <color name="user_icon_1">#ff00bcd4</color><!-- teal 500 -->
+    <color name="user_icon_2">#ff3f51b5</color><!-- indigo 500 -->
+    <color name="user_icon_3">#ff4285f4</color><!-- blue 500 -->
+    <color name="user_icon_4">#ffe91e63</color><!-- pink 500 -->
+    <color name="user_icon_5">#ff0f9d58</color><!-- green 500 -->
+    <color name="user_icon_6">#ff8bc34a</color><!-- light green 500 -->
+    <color name="user_icon_7">#ffff9800</color><!-- orange 500 -->
+    <color name="user_icon_8">#ffff5722</color><!-- deep orange 500 -->
+    <color name="user_icon_default_gray">#ff9e9e9e</color><!-- gray 500 -->
+    <color name="user_icon_default_white">#ffffffff</color><!-- white -->
 </resources>
 
diff --git a/core/res/res/values/colors_material.xml b/core/res/res/values/colors_material.xml
index ccbb8bc..939cbf1 100644
--- a/core/res/res/values/colors_material.xml
+++ b/core/res/res/values/colors_material.xml
@@ -19,12 +19,17 @@
     <color name="background_material_dark">#ff212121</color>
     <color name="background_material_light">#fffafafa</color>
 
-    <color name="ripple_material_light">#20444444</color>
-    <color name="ripple_material_dark">#20ffffff</color>
+    <color name="ripple_material_light">#40000000</color>
+    <color name="ripple_material_dark">#40ffffff</color>
 
     <color name="button_material_dark">#ff5a595b</color>
     <color name="button_material_light">#ffd6d7d7</color>
 
+    <color name="switch_thumb_normal_material_dark">#ffbdbdbd</color>
+    <color name="switch_thumb_normal_material_light">#fff1f1f1</color>
+    <color name="switch_thumb_disabled_material_dark">#ff616161</color>
+    <color name="switch_thumb_disabled_material_light">#ffbdbdbd</color>
+
     <color name="bright_foreground_material_dark">@color/white</color>
     <color name="bright_foreground_material_light">@color/black</color>
     <!-- White 50% -->
@@ -41,139 +46,57 @@
 
     <color name="hint_foreground_material_dark">@color/bright_foreground_disabled_material_dark</color>
     <color name="hint_foreground_material_light">@color/bright_foreground_disabled_material_light</color>
+
     <!-- TODO: This is 40% alpha on the default accent color. -->
-    <color name="highlighted_text_material_dark">#6640c4ff</color>
+    <color name="highlighted_text_material_dark">#6680cbc4</color>
     <!-- TODO: This is 40% alpha on the default accent color. -->
-    <color name="highlighted_text_material_light">#6640c4ff</color>
+    <color name="highlighted_text_material_light">#66009688</color>
+
+    <color name="link_text_material_dark">@color/material_deep_teal_200</color>
+    <color name="link_text_material_light">@color/material_deep_teal_500</color>
 
     <!-- Text & foreground colors -->
     <eat-comment />
 
-    <!-- Black 87% -->
     <color name="primary_text_default_material_light">#de000000</color>
-    <!-- Black 54% -->
-    <color name="secondary_text_material_light">#8a000000</color>
-    <!-- Black 54% (TODO: same as secondary?) -->
-    <color name="tertiary_text_material_light">#8a000000</color>
+    <color name="secondary_text_default_material_light">#8a000000</color>
 
-    <!-- White 87% -->
-    <color name="primary_text_default_material_dark">#deffffff</color>
-    <!-- White 38% -->
-    <color name="secondary_text_material_dark">#61ffffff</color>
-    <!-- White 38% (TODO: same as secondary?) -->
-    <color name="tertiary_text_material_dark">#61ffffff</color>
+    <color name="primary_text_default_material_dark">#ffffffff</color>
+    <color name="secondary_text_default_material_dark">#b3ffffff</color>
+
+    <item name="disabled_alpha_material_light" format="float" type="dimen">0.26</item>
+    <item name="disabled_alpha_material_dark" format="float" type="dimen">0.30</item>
 
     <!-- Primary & accent colors -->
     <eat-comment />
 
-    <color name="material_red_100">#fff4c7c3</color>
-    <color name="material_red_300">#ffe67c73</color>
-    <color name="material_red_500">#ffdb4437</color>
-    <color name="material_red_700">#ffc53929</color>
-    <color name="material_red_A200">#ffff5252</color>
-    <color name="material_red_A400">#ffff1744</color>
-
-    <color name="material_blue_100">#ffc6dafc</color>
-    <color name="material_blue_300">#ff7baaf7</color>
-    <color name="material_blue_500">#ff4285f4</color>
-    <color name="material_blue_700">#ff3367d6</color>
-    <color name="material_blue_A200">#ff448aff</color>
-    <color name="material_blue_A400">#ff2979ff</color>
-
-    <color name="material_light_blue_A200">#ff40c4ff</color>
-
-    <color name="material_teal_100">#ffb2ebf2</color>
-    <color name="material_teal_300">#ff4dd0e1</color>
-    <color name="material_teal_500">#ff00bcd4</color>
-    <color name="material_teal_700">#ff0097a7</color>
-    <color name="material_teal_A200">#ff18ffff</color>
-    <color name="material_teal_A400">#ff00e5ff</color>
-
-    <color name="material_deep_teal_A200">#ff80cbc4</color>
-    <color name="material_deep_teal_A500">#ff009688</color>
-
-    <color name="material_green_100">#ffb7e1cd</color>
-    <color name="material_green_300">#ff57bb8a</color>
-    <color name="material_green_500">#ff0f9d58</color>
-    <color name="material_green_700">#ff0b8043</color>
-    <color name="material_green_A200">#ff69f0ae</color>
-    <color name="material_green_A400">#ff00e676</color>
-
-    <color name="material_lime_100">#fff0f4c3</color>
-    <color name="material_lime_300">#ffdce775</color>
-    <color name="material_lime_500">#ffcddc39</color>
-    <color name="material_lime_700">#ffafb42b</color>
-    <color name="material_lime_A200">#ffeeff41</color>
-    <color name="material_lime_A400">#ffc6ff00</color>
-
-    <color name="material_yellow_100">#fffce8b2</color>
-    <color name="material_yellow_300">#fff7cb4d</color>
-    <color name="material_yellow_500">#fff4b400</color>
-    <color name="material_yellow_700">#fff09300</color>
-    <color name="material_yellow_A200">#ffffcd40</color>
-    <color name="material_yellow_A400">#ffffbc00</color>
-
-    <color name="material_orange_100">#ffffe0b2</color>
-    <color name="material_orange_300">#ffffb74d</color>
-    <color name="material_orange_500">#ffff9800</color>
-    <color name="material_orange_700">#fff57c00</color>
-    <color name="material_orange_A200">#ffffab40</color>
-    <color name="material_orange_A400">#ffff9100</color>
-
-    <color name="material_deep_orange_100">#fff4c7c3</color>
-    <color name="material_deep_orange_300">#ffe67c73</color>
-    <color name="material_deep_orange_500">#ffff5722</color>
-    <color name="material_deep_orange_700">#ffc53929</color>
-    <color name="material_deep_orange_A200">#ffff5252</color>
-    <color name="material_deep_orange_A400">#ffff1744</color>
-
-    <!-- Neutral colors -->
-    <eat-comment />
-
-    <color name="material_grey_50">#fffafafa</color>
-    <color name="material_grey_100">#fff5f5f5</color>
-    <color name="material_grey_300">#ffeeeeee</color>
-    <color name="material_grey_500">#ffa3a3a3</color>
-    <color name="material_grey_600">#ff757575</color>
-    <color name="material_grey_700">#ff717171</color>
-    <color name="material_grey_900">#ff212121</color>
+    <color name="material_deep_teal_200">#ff80cbc4</color>
+    <color name="material_deep_teal_500">#ff009688</color>
 
     <color name="material_blue_grey_50">#ffeceff1</color>
     <color name="material_blue_grey_100">#ffcfd8dc</color>
-    <color name="material_blue_grey_300">#ff90a4ae</color>
-    <color name="material_blue_grey_400">#ff78909c</color>
-    <color name="material_blue_grey_500">#ff607d8b</color>
-    <color name="material_blue_grey_600">#ff546e7a</color>
-    <color name="material_blue_grey_700">#ff455a64</color>
     <color name="material_blue_grey_800">#ff37474f</color>
-    <!-- Primary color used by Settings -->
     <color name="material_blue_grey_900">#ff263238</color>
-    <!-- Primary dark color used by Settings -->
     <color name="material_blue_grey_950">#ff21272b</color>
 
-    <color name="material_brown_100">#ffd7ccc8</color>
-    <color name="material_brown_300">#ffa1887f</color>
-    <color name="material_brown_500">#ff795548</color>
-    <color name="material_brown_700">#ff5d4037</color>
-
     <!-- Time picker defaults when no theme is set -->
     <eat-comment />
 
     <color name="timepicker_default_background_material">@color/primary_text_default_material_light</color>
     <color name="timepicker_default_text_color_material">@color/black</color>
-    <color name="timepicker_default_ampm_selected_background_color_material">@color/material_light_blue_A200</color>
+    <color name="timepicker_default_ampm_selected_background_color_material">@color/material_deep_teal_200</color>
     <color name="timepicker_default_ampm_unselected_background_color_material">@color/transparent</color>
-    <color name="timepicker_default_selector_color_material">@color/material_light_blue_A200</color>
+    <color name="timepicker_default_selector_color_material">@color/material_deep_teal_200</color>
     <color name="timepicker_default_numbers_background_color_material">@color/transparent</color>
 
     <!-- DatePicker colors -->
     <eat-comment />
 
-    <color name="datepicker_default_header_selector_background_material_light">@android:color/white</color>
+    <color name="datepicker_default_header_selector_background_material_light">@color/white</color>
     <color name="datepicker_default_header_selector_background_material_dark">#ff303030</color>
 
     <color name="datepicker_default_header_dayofweek_background_color_material_light">#999999</color>
-    <color name="datepicker_default_header_dayofweek_background_color_material_dark">@android:color/white</color>
+    <color name="datepicker_default_header_dayofweek_background_color_material_dark">@color/white</color>
 
     <color name="datepicker_default_normal_text_color_material_light">#ff999999</color>
     <color name="datepicker_default_normal_text_color_material_dark">@android:color/white</color>
@@ -187,8 +110,8 @@
     <color name="datepicker_default_pressed_text_color_material_light">#0099cc</color>
     <color name="datepicker_default_pressed_text_color_material_dark">#0099cc</color>
 
-    <color name="datepicker_default_circle_background_color_material_light">@android:color/holo_blue_light</color>
-    <color name="datepicker_default_circle_background_color_material_dark">@android:color/holo_blue_light</color>
+    <color name="datepicker_default_circle_background_color_material_light">@color/material_deep_teal_500</color>
+    <color name="datepicker_default_circle_background_color_material_dark">@color/material_deep_teal_200</color>
 
     <color name="datepicker_default_view_animator_color_material_light">#f2f2f2</color>
     <color name="datepicker_default_view_animator_color_material_dark">#ff303030</color>
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml
index bf97ca5..ef3f47e 100644
--- a/core/res/res/values/config.xml
+++ b/core/res/res/values/config.xml
@@ -26,6 +26,7 @@
        <item><xliff:g id="id">ime</xliff:g></item>
        <item><xliff:g id="id">sync_failing</xliff:g></item>
        <item><xliff:g id="id">sync_active</xliff:g></item>
+       <item><xliff:g id="id">cast</xliff:g></item>
        <item><xliff:g id="id">location</xliff:g></item>
        <item><xliff:g id="id">bluetooth</xliff:g></item>
        <item><xliff:g id="id">nfc</xliff:g></item>
@@ -338,6 +339,42 @@
          capability can provide power savings when wifi needs to be always kept on. -->
     <bool translatable="false" name="config_wifi_background_scan_support">false</bool>
 
+    <!-- Boolean indicating we re-try re-associating once upon disconnection and RSSI is high failure  -->
+    <bool translatable="true" name="config_wifi_enable_disconnection_debounce">true</bool>
+
+    <!-- Boolean indicating autojoin will prefer 5GHz and choose 5GHz BSSIDs -->
+    <bool translatable="true" name="config_wifi_enable_5GHz_preference">true</bool>
+
+    <!-- Integer specifying the basic autojoin parameters -->
+    <integer translatable="false" name="config_wifi_framework_5GHz_preference_boost_threshold">-65</integer>
+    <integer translatable="false" name="config_wifi_framework_5GHz_preference_boost_factor">5</integer>
+    <integer translatable="false" name="config_wifi_framework_current_association_hysteresis_high">16</integer>
+    <integer translatable="false" name="config_wifi_framework_current_association_hysteresis_low">10</integer>
+    <integer translatable="false" name="config_wifi_framework_5GHz_preference_penalty_threshold">-75</integer>
+    <integer translatable="false" name="config_wifi_framework_5GHz_preference_penalty_factor">2</integer>
+
+    <!-- Integer parameters of the wifi to cellular handover feature
+         wifi should not stick to bad networks -->
+    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz">-82</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_low_rssi_threshold_5GHz">-72</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_good_rssi_threshold_5GHz">-60</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz">-87</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_low_rssi_threshold_24GHz">-77</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_good_rssi_threshold_24GHz">-65</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_link_speed_24">6</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_bad_link_speed_5">12</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_good_link_speed_24">24</integer>
+    <integer translatable="false" name="config_wifi_framework_wifi_score_good_link_speed_5">36</integer>
+    <bool translatable="false" name="config_wifi_framework_cellular_handover_enable_user_triggered_adjustment">true</bool>
+
+    <!-- Integer packet threshold used to allow scan while associated -->
+    <integer translatable="false" name="config_wifi_framework_associated_full_scan_tx_packet_threshold">5</integer>
+    <integer translatable="false" name="config_wifi_framework_associated_full_scan_rx_packet_threshold">10</integer>
+    <integer translatable="false" name="config_wifi_framework_associated_partial_scan_tx_packet_threshold">40</integer>
+    <integer translatable="false" name="config_wifi_framework_associated_partial_scan_rx_packet_threshold">80</integer>
+    <integer translatable="false" name="config_wifi_framework_network_switch_tx_packet_threshold">2</integer>
+    <integer translatable="false" name="config_wifi_framework_network_switch_rx_packet_threshold">20</integer>
+
     <!-- Integer indicating wpa_supplicant scan interval in milliseconds -->
     <integer translatable="false" name="config_wifi_supplicant_scan_interval">15000</integer>
 
@@ -350,6 +387,33 @@
          point on the move. A value of 0 means no periodic scans will be used in the framework. -->
     <integer translatable="false" name="config_wifi_framework_scan_interval">300000</integer>
 
+    <!-- Integer indicating associated partial scan interval in milliseconds -->
+    <integer translatable="false" name="config_wifi_framework_associated_scan_interval">10000</integer>
+
+    <!-- Integer indicating associated full scan backoff, representing a fraction: xx/8 -->
+    <integer translatable="false" name="config_wifi_framework_associated_full_scan_backoff">12</integer>
+
+    <!-- Integer indicating associated full scan max interval in milliseconds -->
+    <integer translatable="false" name="config_wifi_framework_associated_full_scan_max_interval">300000</integer>
+
+    <!-- Integer indicating associated full scan max total dwell time in milliseconds -->
+    <integer translatable="false" name="config_wifi_framework_associated_full_scan_max_total_dwell_time">500</integer>
+
+    <!-- Integer indicating associated full scan max num active channels -->
+    <integer translatable="false" name="config_wifi_framework_associated_partial_scan_max_num_active_channels">6</integer>
+
+    <!-- Integer indicating associated full scan max num passive channels -->
+    <integer translatable="false" name="config_wifi_framework_associated_partial_scan_max_num_passive_channels">3</integer>
+
+    <!-- Boolean indicating associated scan are allowed -->
+    <bool translatable="false" name="config_wifi_framework_enable_associated_autojoin_scan">true</bool>
+
+    <!-- Boolean indicating associated network selection is allowed -->
+    <bool translatable="false" name="config_wifi_framework_enable_associated_network_selection">true</bool>
+
+    <!-- Boolean indicating that wifi only link configuratios that have exact same credentials (i.e PSK) -->
+    <bool translatable="false" name="config_wifi_only_link_same_credential_configurations">true</bool>
+
     <!-- Wifi driver stop delay, in milliseconds.
          Default value is 2 minutes. -->
     <integer translatable="false" name="config_wifi_driver_stop_delay">120000</integer>
@@ -373,7 +437,7 @@
     <bool name="config_useAttentionLight">false</bool>
 
     <!-- If this is true, the screen will fade off. -->
-    <bool name="config_animateScreenLights">true</bool>
+    <bool name="config_animateScreenLights">false</bool>
 
     <!-- If this is true, key chords can be used to take a screenshot on the device. -->
     <bool name="config_enableScreenshotChord">true</bool>
@@ -548,13 +612,13 @@
     <!-- Vibrator pattern for feedback when selecting an hour/minute tick of a Clock -->
     <integer-array name="config_clockTickVibePattern">
         <item>125</item>
-        <item>5</item>
+        <item>30</item>
     </integer-array>
 
     <!-- Vibrator pattern for feedback when selecting a day/month/year date of a Calendar -->
     <integer-array name="config_calendarDateVibePattern">
         <item>125</item>
-        <item>5</item>
+        <item>30</item>
     </integer-array>
 
     <!-- Vibrator pattern for feedback about booting with safe mode disabled -->
@@ -627,7 +691,7 @@
     <integer name="config_notificationsBatteryLedOff">2875</integer>
 
     <!-- Number of notifications to keep in the notification service historical archive -->
-    <integer name="config_notificationServiceArchiveSize">250</integer>
+    <integer name="config_notificationServiceArchiveSize">100</integer>
 
     <!-- Allow the menu hard key to be disabled in LockScreen on some devices -->
     <bool name="config_disableMenuKeyInLockScreen">false</bool>
@@ -673,6 +737,37 @@
     -->
     <integer name="config_doubleTapOnHomeBehavior">0</integer>
 
+    <!-- Minimum screen brightness setting allowed by the power manager.
+         The user is forbidden from setting the brightness below this level. -->
+    <integer name="config_screenBrightnessSettingMinimum">10</integer>
+
+    <!-- Maximum screen brightness allowed by the power manager.
+         The user is forbidden from setting the brightness above this level. -->
+    <integer name="config_screenBrightnessSettingMaximum">255</integer>
+
+    <!-- Default screen brightness setting.
+         Must be in the range specified by minimum and maximum. -->
+    <integer name="config_screenBrightnessSettingDefault">102</integer>
+
+    <!-- Screen brightness used to dim the screen while dozing in a very low power state.
+         May be less than the minimum allowed brightness setting
+         that can be set by the user. -->
+    <integer name="config_screenBrightnessDoze">1</integer>
+
+    <!-- Screen brightness used to dim the screen when the user activity
+         timeout expires.  May be less than the minimum allowed brightness setting
+         that can be set by the user. -->
+    <integer name="config_screenBrightnessDim">10</integer>
+
+    <!-- Minimum allowable screen brightness to use in a very dark room.
+         This value sets the floor for the darkest possible auto-brightness
+         adjustment.  It is expected to be somewhat less than the first entry in
+         config_autoBrightnessLcdBacklightValues so as to allow the user to have
+         some range of adjustment to dim the screen further than usual in very
+         dark rooms. The contents of the screen must still be clearly visible
+         in darkness (although they may not be visible in a bright room). -->
+    <integer name="config_screenBrightnessDark">1</integer>
+
     <!-- Array of light sensor LUX values to define our levels for auto backlight brightness support.
          The N entries of this array define N + 1 control points as follows:
          (1-based arrays)
@@ -696,28 +791,6 @@
     <integer-array name="config_autoBrightnessLevels">
     </integer-array>
 
-    <!-- Minimum screen brightness setting allowed by the power manager.
-         The user is forbidden from setting the brightness below this level. -->
-    <integer name="config_screenBrightnessSettingMinimum">10</integer>
-
-    <!-- Maximum screen brightness allowed by the power manager.
-         The user is forbidden from setting the brightness above this level. -->
-    <integer name="config_screenBrightnessSettingMaximum">255</integer>
-
-    <!-- Default screen brightness setting.
-         Must be in the range specified by minimum and maximum. -->
-    <integer name="config_screenBrightnessSettingDefault">102</integer>
-
-    <!-- Screen brightness used to dim the screen while dozing in a very low power state.
-         May be less than the minimum allowed brightness setting
-         that can be set by the user. -->
-    <integer name="config_screenBrightnessDoze">1</integer>
-
-    <!-- Screen brightness used to dim the screen when the user activity
-         timeout expires.  May be less than the minimum allowed brightness setting
-         that can be set by the user. -->
-    <integer name="config_screenBrightnessDim">10</integer>
-
     <!-- Array of output values for LCD backlight corresponding to the LUX values
          in the config_autoBrightnessLevels array.  This array should have size one greater
          than the size of the config_autoBrightnessLevels array.
@@ -761,6 +834,9 @@
          specified -->
     <string name="default_wallpaper_component" translatable="false">@null</string>
 
+    <!-- Component name of the built in wallpaper used to display bitmap wallpapers. This must not be null. -->
+    <string name="image_wallpaper_component" translatable="false">com.android.systemui/com.android.systemui.ImageWallpaper</string>
+
     <!-- True if WallpaperService is enabled -->
     <bool name="config_enableWallpaperService">true</bool>
 
@@ -1225,6 +1301,10 @@
          Doze dreams will run whenever the power manager is in a dozing state. -->
     <string name="config_dozeComponent"></string>
 
+    <!-- If true, the doze component is not started until after the screen has been
+         turned off and the screen off animation has been performed. -->
+    <bool name="config_dozeAfterScreenOff">false</bool>
+
     <!-- Power Management: Specifies whether to decouple the auto-suspend state of the
          device from the display on/off state.
 
@@ -1371,6 +1451,21 @@
          may have a specific value set in an overlay config.xml file. -->
     <integer name="config_mobile_mtu">1500</integer>
 
+    <!-- Configure mobile tcp buffer sizes in the form:
+         rat-name:rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max
+         If no value is found for the rat-name in use, the system default will be applied.
+    -->
+    <string-array name="config_mobile_tcp_buffers">
+    </string-array>
+
+    <!-- Configure ethernet tcp buffersizes in the form:
+         rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max -->
+    <string name="config_ethernet_tcp_buffers" translatable="false">524288,1048576,3145728,524288,1048576,2097152</string>
+
+    <!-- Configure wifi tcp buffersizes in the form:
+         rmem_min,rmem_def,rmem_max,wmem_min,wmem_def,wmem_max -->
+    <string name="config_wifi_tcp_buffers" translatable="false">524288,1048576,2097152,262144,524288,1048576</string>
+
     <!-- Whether WiFi display is supported by this device.
          There are many prerequisites for this feature to work correctly.
          Here are a few of them:
@@ -1431,6 +1526,10 @@
     <!-- Set to true if after a provisioning apn the radio should be restarted -->
     <bool name="config_restartRadioAfterProvisioning">false</bool>
 
+    <!-- Boolean indicating if RADIO POWER OFF is required on receiving SIM REFRESH with RESET.
+         This will be handled by modem if it is false. -->
+    <bool name="config_requireRadioPowerOffOnSimRefreshReset">false</bool>
+
     <!-- Vibrator pattern to be used as the default for notifications
          that specify DEFAULT_VIBRATE.
      -->
@@ -1508,6 +1607,7 @@
         <item>com.android.server.notification.ValidateNotificationPeople</item>
         <item>com.android.server.notification.PackagePriorityExtractor</item>
         <item>com.android.server.notification.NotificationIntrusivenessExtractor</item>
+        <item>com.android.server.notification.PackageVisibilityExtractor</item>
     </string-array>
 
     <!-- Flag indicating that this device does not rotate and will always remain in its default
@@ -1566,6 +1666,9 @@
          2 - The device DOES NOT have a permanent menu key; ignore autodetection. -->
     <integer name="config_overrideHasPermanentMenuKey">0</integer>
 
+    <!-- Override the DPad detection behavior for configuration purposes -->
+    <bool name="config_hasPermanentDpad">false</bool>
+
     <!-- default window inset isRound property -->
     <bool name="config_windowIsRound">false</bool>
 
@@ -1578,6 +1681,10 @@
     <!-- default window ShowCircularMask property -->
     <bool name="config_windowShowCircularMask">false</bool>
 
+    <!-- default value for whether circular emulators (ro.emulator.circular)
+         should show a display overlay on the screen -->
+    <bool name="config_windowEnableCircularEmulatorDisplayOverlay">false</bool>
+
     <!-- Defines the default set of global actions. Actions may still be disabled or hidden based
          on the current state of the device.
          Each item must be one of the following strings:
@@ -1641,6 +1748,14 @@
         be disabled) but individual Features can be disabled using ImsConfig.setFeatureValue() -->
     <bool name="imsServiceAllowTurnOff">true</bool>
 
+    <!-- Flag specifying whether VoLTE & VT is availasble on device -->
+    <bool name="config_device_volte_vt_available">false</bool>
+
+    <!-- Flag specifying whether VoLTE & VT should be available for carrier: independent of
+         carrier provisioning. If false: hard disabled. If true: then depends on carrier
+         provisioning, availability etc -->
+    <bool name="config_carrier_volte_vt_available">false</bool>
+
     <bool name="config_networkSamplingWakesDevice">true</bool>
 
     <string-array translatable="false" name="config_cdma_home_system" />
@@ -1656,4 +1771,44 @@
     <!-- Package name providing WebView implementation. -->
     <string name="config_webViewPackageName" translatable="false">com.android.webview</string>
 
+    <!-- If EMS is not supported, framework breaks down EMS into single segment SMS
+         and adds page info " x/y". This config is used to set which carrier doesn't
+         support EMS and whether page info should be added at the beginning or the end.
+         We use tag 'prefix' for position beginning and 'suffix' for position end.
+         And use gid to distinguish different carriers which using same mcc and mnc.
+         Examples: <item>simOperatorNumber;position;gid(optional)</item>>
+    -->
+    <string-array translatable="false" name="no_ems_support_sim_operators">
+        <!-- VZW -->
+        <item>20404;suffix;BAE0000000000000</item>
+    </string-array>
+
+    <bool name="config_auto_attach_data_on_creation">true</bool>
+
+    <!-- Values for GPS configuration -->
+    <string-array translatable="false" name="config_gpsParameters">
+        <item>SUPL_HOST=supl.google.com</item>
+        <item>SUPL_PORT=7275</item>
+        <item>NTP_SERVER=north-america.pool.ntp.org</item>
+        <item>SUPL_VER=0x20000</item>
+        <item>SUPL_MODE=0x01</item>
+    </string-array>
+
+    <!-- If there is no preload VM number in the sim card, carriers such as
+         Verizon require to load a default vm number from the configurantion.
+         Define config_default_vm_number for this purpose. And there are two
+         optional formats for this configuration as below:
+         (1)<item>voicemail number</item>
+         (2)<item>voicemail number;gid</item>
+         The logic to pick up the correct voicemail number:
+         (1) If the config_default_vm_number array has no gid special item, the last one will be
+         picked
+         (2) If the config_default_vm_number array has gid special item and  it matches the current
+         sim's gid, it will be picked.
+         (3) If the config_default_vm_number array has gid special item but it doesn't match the
+         current sim's gid, the last one without gid will be picked -->
+    <string-array translatable="false" name="config_default_vm_number" />
+
+    <!-- Sprint need a 70 ms delay for 3way call -->
+    <integer name="config_cdma_3waycall_flash_delay">0</integer>
 </resources>
diff --git a/core/res/res/values/dimens.xml b/core/res/res/values/dimens.xml
index a29a34c..7a2bbc1 100644
--- a/core/res/res/values/dimens.xml
+++ b/core/res/res/values/dimens.xml
@@ -19,9 +19,9 @@
 -->
 <resources>
     <!-- The width that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_width">256dp</dimen>
+    <dimen name="thumbnail_width">192dp</dimen>
     <!-- The height that is used when creating thumbnails of applications. -->
-    <dimen name="thumbnail_height">256dp</dimen>
+    <dimen name="thumbnail_height">192dp</dimen>
     <!-- The standard size (both width and height) of an application icon that
          will be displayed in the app launcher and elsewhere. -->
     <dimen name="app_icon_size">48dip</dimen>
@@ -215,17 +215,29 @@
     <dimen name="action_bar_stacked_tab_max_width">180dp</dimen>
 
     <!-- Size of notification text (see TextAppearance.StatusBar.EventContent) -->
-    <dimen name="notification_text_size">13sp</dimen>
+    <dimen name="notification_text_size">14sp</dimen>
     <!-- Size of notification text titles (see TextAppearance.StatusBar.EventContent.Title) -->
     <dimen name="notification_title_text_size">16sp</dimen>
     <!-- Size of smaller notification text (see TextAppearance.StatusBar.EventContent.Line2, Info, Time) -->
     <dimen name="notification_subtext_size">12sp</dimen>
 
-    <!-- 8dp at the top/bottom of the notification view -->
-    <dimen name="notification_vert_pad">10dp</dimen>
+    <!-- Top padding for notifications in the standard layout. -->
+    <dimen name="notification_top_pad">10dp</dimen>
 
-    <!-- Replacement for @dimen/notification_vert_pad when the text is large -->
-    <dimen name="notification_large_font_vert_pad">3dp</dimen>
+    <!-- Top padding for notifications when narrow (i.e. it has 3 lines) -->
+    <dimen name="notification_top_pad_narrow">4dp</dimen>
+
+    <!-- Top padding for notification when text is large -->
+    <dimen name="notification_top_pad_large_text">5dp</dimen>
+
+    <!-- Top padding for notification when text is large and narrow (i.e. it has 3 lines -->
+    <dimen name="notification_top_pad_large_text_narrow">-4dp</dimen>
+
+    <!-- Padding for notification icon when drawn with circle around it -->
+    <dimen name="notification_large_icon_circle_padding">11dp</dimen>
+
+    <!-- Size of the profile badge for notifications -->
+    <dimen name="notification_badge_size">16dp</dimen>
 
     <!-- Keyguard dimensions -->
     <!-- TEMP -->
@@ -364,7 +376,7 @@
 
     <!-- Used by SimpleMonthView -->
     <dimen name="datepicker_day_number_size">12sp</dimen>
-    <dimen name="datepicker_month_label_size">16sp</dimen>
+    <dimen name="datepicker_month_label_size">14sp</dimen>
     <dimen name="datepicker_month_day_label_text_size">12sp</dimen>
     <dimen name="datepicker_month_list_item_header_height">48dp</dimen>
     <dimen name="datepicker_day_number_select_circle_radius">16dp</dimen>
@@ -374,10 +386,9 @@
     <dimen name="datepicker_year_label_height">64dp</dimen>
     <dimen name="datepicker_year_label_text_size">22dp</dimen>
     <dimen name="datepicker_component_width">270dp</dimen>
-    <dimen name="datepicker_selected_calendar_layout_height">155dp</dimen>
-    <dimen name="datepicker_selected_date_day_size">75dp</dimen>
-    <dimen name="datepicker_selected_date_month_size">30dp</dimen>
-    <dimen name="datepicker_selected_date_year_size">30dp</dimen>
+    <dimen name="datepicker_selected_date_day_size">88dp</dimen>
+    <dimen name="datepicker_selected_date_month_size">24dp</dimen>
+    <dimen name="datepicker_selected_date_year_size">24dp</dimen>
     <dimen name="datepicker_header_height">30dp</dimen>
     <dimen name="datepicker_header_text_size">14dp</dimen>
 
@@ -394,4 +405,14 @@
      <dimen name="lock_pattern_dot_line_width">3dp</dimen>
      <dimen name="lock_pattern_dot_size">12dp</dimen>
      <dimen name="lock_pattern_dot_size_activated">28dp</dimen>
+
+     <dimen name="text_handle_min_size">40dp</dimen>
+
+     <!-- Lighting and shadow properties -->
+     <dimen name="light_y">-200dp</dimen>
+     <dimen name="light_z">800dp</dimen>
+     <dimen name="light_radius">800dp</dimen>
+     <item type="dimen" format="float" name="ambient_shadow_alpha">0.047</item>
+     <item type="dimen" format="float" name="spot_shadow_alpha">0.098</item>
+
 </resources>
diff --git a/core/res/res/values/dimens_material.xml b/core/res/res/values/dimens_material.xml
index e5a3c17..ac5890a 100644
--- a/core/res/res/values/dimens_material.xml
+++ b/core/res/res/values/dimens_material.xml
@@ -31,9 +31,9 @@
     <!-- Bottom margin for action bar subtitles -->
     <dimen name="action_bar_subtitle_bottom_margin_material">5dp</dimen>
 
+    <dimen name="action_button_min_width_overflow_material">36dp</dimen>
     <dimen name="action_button_min_width_material">48dp</dimen>
     <dimen name="action_button_min_height_material">48dp</dimen>
-    <dimen name="action_overflow_min_width_material">36dp</dimen>
 
     <dimen name="text_size_display_4_material">112sp</dimen>
     <dimen name="text_size_display_3_material">56sp</dimen>
@@ -42,6 +42,8 @@
     <dimen name="text_size_headline_material">24sp</dimen>
     <dimen name="text_size_title_material">20sp</dimen>
     <dimen name="text_size_subhead_material">16sp</dimen>
+    <dimen name="text_size_title_material_toolbar">@dimen/text_size_title_material</dimen>
+    <dimen name="text_size_subtitle_material_toolbar">@dimen/text_size_subhead_material</dimen>
     <dimen name="text_size_menu_material">16sp</dimen>
     <dimen name="text_size_body_2_material">14sp</dimen>
     <dimen name="text_size_body_1_material">14sp</dimen>
@@ -62,6 +64,13 @@
     <dimen name="button_elevation_material">1dp</dimen>
     <!-- Z translation to apply when button is pressed -->
     <dimen name="button_pressed_z_material">2dp</dimen>
+    <!-- Default insets (outer padding) around buttons -->
+    <dimen name="button_inset_vertical_material">6dp</dimen>
+    <dimen name="button_inset_horizontal_material">@dimen/control_inset_material</dimen>
+    <!-- Default inner padding within buttons -->
+    <dimen name="button_padding_vertical_material">@dimen/control_padding_material</dimen>
+    <dimen name="button_padding_horizontal_material">8dp</dimen>
+
     <!-- Default insets (outer padding) around controls -->
     <dimen name="control_inset_material">4dp</dimen>
     <!-- Default inner padding within controls -->
@@ -69,6 +78,6 @@
     <!-- Default rounded corner for controls -->
     <dimen name="control_corner_material">2dp</dimen>
 
-    <!-- Default alpha value for disabled elements. -->
-    <item name="disabled_alpha_material" format="float" type="dimen">0.26</item>
+    <dimen name="alert_dialog_padding_material">24dp</dimen>
+    <dimen name="alert_dialog_padding_top_material">18dp</dimen>
 </resources>
diff --git a/core/res/res/values/ids.xml b/core/res/res/values/ids.xml
index c64e910..bd24f3e 100644
--- a/core/res/res/values/ids.xml
+++ b/core/res/res/values/ids.xml
@@ -85,4 +85,8 @@
   <item type="id" name="scene_layoutid_cache" />
   <item type="id" name="mask" />
   <item type="id" name="transitionPosition" />
+  <item type="id" name="transitionTransform" />
+  <item type="id" name="parentMatrix" />
+  <item type="id" name="statusBarBackground" />
+  <item type="id" name="navigationBarBackground" />
 </resources>
diff --git a/core/res/res/values/public.xml b/core/res/res/values/public.xml
index c8edad0..bbd40a1 100644
--- a/core/res/res/values/public.xml
+++ b/core/res/res/values/public.xml
@@ -2101,478 +2101,485 @@
 <!-- ===============================================================
      Resources added in version 21 of the platform
      =============================================================== -->
-  <eat-comment />
+    <eat-comment />
 
-  <public-padding type="attr" name="l_resource_pad" end="0x1010410" />
+    <public type="attr" name="fastScrollStyle" id="0x010103f7" />
+    <public type="attr" name="windowContentTransitions" id="0x010103f8" />
+    <public type="attr" name="windowContentTransitionManager" id="0x010103f9" />
+    <public type="attr" name="translationZ" id="0x010103fa" />
+    <public type="attr" name="tintMode" id="0x010103fb" />
+    <public type="attr" name="controlX1" id="0x010103fc" />
+    <public type="attr" name="controlY1" id="0x010103fd" />
+    <public type="attr" name="controlX2" id="0x010103fe" />
+    <public type="attr" name="controlY2" id="0x010103ff" />
+    <public type="attr" name="transitionName" id="0x01010400" />
+    <public type="attr" name="transitionGroup" id="0x01010401" />
+    <public type="attr" name="viewportWidth" id="0x01010402" />
+    <public type="attr" name="viewportHeight" id="0x01010403" />
+    <public type="attr" name="fillColor" id="0x01010404" />
+    <public type="attr" name="pathData" id="0x01010405" />
+    <public type="attr" name="strokeColor" id="0x01010406" />
+    <public type="attr" name="strokeWidth" id="0x01010407" />
+    <public type="attr" name="trimPathStart" id="0x01010408" />
+    <public type="attr" name="trimPathEnd" id="0x01010409" />
+    <public type="attr" name="trimPathOffset" id="0x0101040a" />
+    <public type="attr" name="strokeLineCap" id="0x0101040b" />
+    <public type="attr" name="strokeLineJoin" id="0x0101040c" />
+    <public type="attr" name="strokeMiterLimit" id="0x0101040d" />
+    <public type="attr" name="colorControlNormal" id="0x01010429" />
+    <public type="attr" name="colorControlActivated" id="0x0101042a" />
+    <public type="attr" name="colorButtonNormal" id="0x0101042b" />
+    <public type="attr" name="colorControlHighlight" id="0x0101042c" />
+    <public type="attr" name="persistableMode" id="0x0101042d" />
+    <public type="attr" name="titleTextAppearance" id="0x0101042e" />
+    <public type="attr" name="subtitleTextAppearance" id="0x0101042f" />
+    <public type="attr" name="slideEdge" id="0x01010430" />
+    <public type="attr" name="actionBarTheme" id="0x01010431" />
+    <public type="attr" name="textAppearanceListItemSecondary" id="0x01010432" />
+    <public type="attr" name="colorPrimary" id="0x01010433" />
+    <public type="attr" name="colorPrimaryDark" id="0x01010434" />
+    <public type="attr" name="colorAccent" id="0x01010435" />
+    <public type="attr" name="nestedScrollingEnabled" id="0x01010436" />
+    <public type="attr" name="windowEnterTransition" id="0x01010437" />
+    <public type="attr" name="windowExitTransition" id="0x01010438" />
+    <public type="attr" name="windowSharedElementEnterTransition" id="0x01010439" />
+    <public type="attr" name="windowSharedElementExitTransition" id="0x0101043a" />
+    <public type="attr" name="windowAllowReturnTransitionOverlap" id="0x0101043b" />
+    <public type="attr" name="windowAllowEnterTransitionOverlap" id="0x0101043c" />
+    <public type="attr" name="sessionService" id="0x0101043d" />
+    <public type="attr" name="stackViewStyle" id="0x0101043e" />
+    <public type="attr" name="switchStyle" id="0x0101043f" />
+    <public type="attr" name="elevation" id="0x01010440" />
+    <public type="attr" name="excludeId" id="0x01010441" />
+    <public type="attr" name="excludeClass" id="0x01010442" />
+    <public type="attr" name="hideOnContentScroll" id="0x01010443" />
+    <public type="attr" name="actionOverflowMenuStyle" id="0x01010444" />
+    <public type="attr" name="documentLaunchMode" id="0x01010445" />
+    <public type="attr" name="maxRecents" id="0x01010446" />
+    <public type="attr" name="autoRemoveFromRecents" id="0x01010447" />
+    <public type="attr" name="stateListAnimator" id="0x01010448" />
+    <public type="attr" name="toId" id="0x01010449" />
+    <public type="attr" name="fromId" id="0x0101044a" />
+    <public type="attr" name="reversible" id="0x0101044b" />
+    <public type="attr" name="splitTrack" id="0x0101044c" />
+    <public type="attr" name="targetName" id="0x0101044d" />
+    <public type="attr" name="excludeName" id="0x0101044e" />
+    <public type="attr" name="matchOrder" id="0x0101044f" />
+    <public type="attr" name="windowDrawsSystemBarBackgrounds" id="0x01010450" />
+    <public type="attr" name="statusBarColor" id="0x01010451" />
+    <public type="attr" name="navigationBarColor" id="0x01010452" />
+    <public type="attr" name="contentInsetStart" id="0x01010453" />
+    <public type="attr" name="contentInsetEnd" id="0x01010454" />
+    <public type="attr" name="contentInsetLeft" id="0x01010455" />
+    <public type="attr" name="contentInsetRight" id="0x01010456" />
+    <public type="attr" name="paddingMode" id="0x01010457" />
+    <public type="attr" name="layout_rowWeight" id="0x01010458" />
+    <public type="attr" name="layout_columnWeight" id="0x01010459" />
+    <public type="attr" name="translateX" id="0x0101045a" />
+    <public type="attr" name="translateY" id="0x0101045b" />
+    <public type="attr" name="selectableItemBackgroundBorderless" id="0x0101045c" />
+    <public type="attr" name="elegantTextHeight" id="0x0101045d" />
+    <public type="attr" name="searchKeyphraseId" id="0x0101045e" />
+    <public type="attr" name="searchKeyphrase" id="0x0101045f" />
+    <public type="attr" name="searchKeyphraseSupportedLocales" id="0x01010460" />
+    <public type="attr" name="windowTransitionBackgroundFadeDuration" id="0x01010461" />
+    <public type="attr" name="overlapAnchor" id="0x01010462" />
+    <public type="attr" name="progressTint" id="0x01010463" />
+    <public type="attr" name="progressTintMode" id="0x01010464" />
+    <public type="attr" name="progressBackgroundTint" id="0x01010465" />
+    <public type="attr" name="progressBackgroundTintMode" id="0x01010466" />
+    <public type="attr" name="secondaryProgressTint" id="0x01010467" />
+    <public type="attr" name="secondaryProgressTintMode" id="0x01010468" />
+    <public type="attr" name="indeterminateTint" id="0x01010469" />
+    <public type="attr" name="indeterminateTintMode" id="0x0101046a" />
+    <public type="attr" name="backgroundTint" id="0x0101046b" />
+    <public type="attr" name="backgroundTintMode" id="0x0101046c" />
+    <public type="attr" name="foregroundTint" id="0x0101046d" />
+    <public type="attr" name="foregroundTintMode" id="0x0101046e" />
+    <public type="attr" name="buttonTint" id="0x0101046f" />
+    <public type="attr" name="buttonTintMode" id="0x01010470" />
+    <public type="attr" name="thumbTint" id="0x01010471" />
+    <public type="attr" name="thumbTintMode" id="0x01010472" />
+    <public type="attr" name="fullBackupOnly" id="0x01010473" />
+    <public type="attr" name="propertyXName" id="0x01010474" />
+    <public type="attr" name="propertyYName" id="0x01010475" />
+    <public type="attr" name="relinquishTaskIdentity" id="0x01010476" />
+    <public type="attr" name="tileModeX" id="0x01010477" />
+    <public type="attr" name="tileModeY" id="0x01010478" />
+    <public type="attr" name="actionModeShareDrawable" id="0x01010479" />
+    <public type="attr" name="actionModeFindDrawable" id="0x0101047a" />
+    <public type="attr" name="actionModeWebSearchDrawable" id="0x0101047b" />
+    <public type="attr" name="transitionVisibilityMode" id="0x0101047c" />
+    <public type="attr" name="minimumHorizontalAngle" id="0x0101047d" />
+    <public type="attr" name="minimumVerticalAngle" id="0x0101047e" />
+    <public type="attr" name="maximumAngle" id="0x0101047f" />
+    <public type="attr" name="searchViewStyle" id="0x01010480" />
+    <public type="attr" name="closeIcon" id="0x01010481" />
+    <public type="attr" name="goIcon" id="0x01010482" />
+    <public type="attr" name="searchIcon" id="0x01010483" />
+    <public type="attr" name="voiceIcon" id="0x01010484" />
+    <public type="attr" name="commitIcon" id="0x01010485" />
+    <public type="attr" name="suggestionRowLayout" id="0x01010486" />
+    <public type="attr" name="queryBackground" id="0x01010487" />
+    <public type="attr" name="submitBackground" id="0x01010488" />
+    <public type="attr" name="buttonBarPositiveButtonStyle" id="0x01010489" />
+    <public type="attr" name="buttonBarNeutralButtonStyle" id="0x0101048a" />
+    <public type="attr" name="buttonBarNegativeButtonStyle" id="0x0101048b" />
+    <public type="attr" name="popupElevation" id="0x0101048c" />
+    <public type="attr" name="actionBarPopupTheme" id="0x0101048d" />
+    <public type="attr" name="multiArch" id="0x0101048e" />
+    <public type="attr" name="touchscreenBlocksFocus" id="0x0101048f" />
+    <public type="attr" name="windowElevation" id="0x01010490" />
+    <public type="attr" name="launchTaskBehindTargetAnimation" id="0x01010491" />
+    <public type="attr" name="launchTaskBehindSourceAnimation" id="0x01010492" />
+    <public type="attr" name="restrictionType" id="0x01010493" />
+    <public type="attr" name="dayOfWeekBackground" id="0x01010494" />
+    <public type="attr" name="dayOfWeekTextAppearance" id="0x01010495" />
+    <public type="attr" name="headerMonthTextAppearance" id="0x01010496" />
+    <public type="attr" name="headerDayOfMonthTextAppearance" id="0x01010497" />
+    <public type="attr" name="headerYearTextAppearance" id="0x01010498" />
+    <public type="attr" name="yearListItemTextAppearance" id="0x01010499" />
+    <public type="attr" name="yearListSelectorColor" id="0x0101049a" />
+    <public type="attr" name="calendarTextColor" id="0x0101049b" />
+    <public type="attr" name="recognitionService" id="0x0101049c" />
+    <public type="attr" name="timePickerStyle" id="0x0101049d" />
+    <public type="attr" name="timePickerDialogTheme" id="0x0101049e" />
+    <public type="attr" name="headerTimeTextAppearance" id="0x0101049f" />
+    <public type="attr" name="headerAmPmTextAppearance" id="0x010104a0" />
+    <public type="attr" name="numbersTextColor" id="0x010104a1" />
+    <public type="attr" name="numbersBackgroundColor" id="0x010104a2" />
+    <public type="attr" name="numbersSelectorColor" id="0x010104a3" />
+    <public type="attr" name="amPmTextColor" id="0x010104a4" />
+    <public type="attr" name="amPmBackgroundColor" id="0x010104a5" />
+    <public type="attr" name="searchKeyphraseRecognitionFlags" id="0x010104a6" />
+    <public type="attr" name="checkMarkTint" id="0x010104a7" />
+    <public type="attr" name="checkMarkTintMode" id="0x010104a8" />
+    <public type="attr" name="popupTheme" id="0x010104a9" />
+    <public type="attr" name="toolbarStyle" id="0x010104aa" />
+    <public type="attr" name="windowClipToOutline" id="0x010104ab" />
+    <public type="attr" name="datePickerDialogTheme" id="0x010104ac" />
+    <public type="attr" name="showText" id="0x010104ad" />
+    <public type="attr" name="windowReturnTransition" id="0x010104ae" />
+    <public type="attr" name="windowReenterTransition" id="0x010104af" />
+    <public type="attr" name="windowSharedElementReturnTransition" id="0x010104b0" />
+    <public type="attr" name="windowSharedElementReenterTransition" id="0x010104b1" />
+    <public type="attr" name="resumeWhilePausing" id="0x010104b2" />
+    <public type="attr" name="datePickerMode" id="0x010104b3" />
+    <public type="attr" name="timePickerMode" id="0x010104b4" />
+    <public type="attr" name="inset" id="0x010104b5" />
+    <public type="attr" name="letterSpacing" id="0x010104b6" />
+    <public type="attr" name="fontFeatureSettings" id="0x010104b7" />
+    <public type="attr" name="outlineProvider" id="0x010104b8" />
+    <public type="attr" name="contentAgeHint" id="0x010104b9" />
+    <public type="attr" name="country" id="0x010104ba" />
+    <public type="attr" name="windowSharedElementsUseOverlay" id="0x010104bb" />
+    <public type="attr" name="reparent" id="0x010104bc" />
+    <public type="attr" name="reparentWithOverlay" id="0x010104bd" />
+    <public type="attr" name="ambientShadowAlpha" id="0x010104be" />
+    <public type="attr" name="spotShadowAlpha" id="0x010104bf" />
+    <public type="attr" name="navigationIcon" id="0x010104c0" />
+    <public type="attr" name="navigationContentDescription" id="0x010104c1" />
+    <public type="attr" name="fragmentExitTransition" id="0x010104c2" />
+    <public type="attr" name="fragmentEnterTransition" id="0x010104c3" />
+    <public type="attr" name="fragmentSharedElementEnterTransition" id="0x010104c4" />
+    <public type="attr" name="fragmentReturnTransition" id="0x010104c5" />
+    <public type="attr" name="fragmentSharedElementReturnTransition" id="0x010104c6" />
+    <public type="attr" name="fragmentReenterTransition" id="0x010104c7" />
+    <public type="attr" name="fragmentAllowEnterTransitionOverlap" id="0x010104c8" />
+    <public type="attr" name="fragmentAllowReturnTransitionOverlap" id="0x010104c9" />
+    <public type="attr" name="patternPathData" id="0x010104ca" />
+    <public type="attr" name="strokeAlpha" id="0x010104cb" />
+    <public type="attr" name="fillAlpha" id="0x010104cc" />
+    <public type="attr" name="windowActivityTransitions" id="0x010104cd" />
 
-  <public type="attr" name="fastScrollStyle" />
-  <public type="attr" name="windowContentTransitions" />
-  <public type="attr" name="windowContentTransitionManager" />
-  <public type="attr" name="translationZ" />
-  <public type="attr" name="tintMode" />
-  <public type="attr" name="controlX1" />
-  <public type="attr" name="controlY1" />
-  <public type="attr" name="controlX2" />
-  <public type="attr" name="controlY2" />
-  <public type="attr" name="transitionName" />
-  <public type="attr" name="transitionGroup" />
-  <public type="attr" name="viewportWidth" />
-  <public type="attr" name="viewportHeight" />
-  <public type="attr" name="fillColor" />
-  <public type="attr" name="pathData" />
-  <public type="attr" name="strokeColor" />
-  <public type="attr" name="strokeWidth" />
-  <public type="attr" name="trimPathStart" />
-  <public type="attr" name="trimPathEnd" />
-  <public type="attr" name="trimPathOffset" />
-  <public type="attr" name="strokeLineCap" />
-  <public type="attr" name="strokeLineJoin" />
-  <public type="attr" name="strokeMiterLimit" />
-  <public type="attr" name="requiredForProfile"/>
-  <public type="attr" name="colorControlNormal" />
-  <public type="attr" name="colorControlActivated" />
-  <public type="attr" name="colorButtonNormal" />
-  <public type="attr" name="colorControlHighlight" />
-  <public type="attr" name="persistableMode" />
-  <public type="attr" name="titleTextAppearance" />
-  <public type="attr" name="subtitleTextAppearance" />
-  <public type="attr" name="slideEdge" />
-  <public type="attr" name="actionBarTheme" />
-  <public type="attr" name="textAppearanceListItemSecondary" />
-  <public type="attr" name="colorPrimary" />
-  <public type="attr" name="colorPrimaryDark" />
-  <public type="attr" name="colorAccent" />
-  <public type="attr" name="nestedScrollingEnabled" />
-  <public type="attr" name="windowEnterTransition" />
-  <public type="attr" name="windowExitTransition" />
-  <public type="attr" name="windowSharedElementEnterTransition" />
-  <public type="attr" name="windowSharedElementExitTransition" />
-  <public type="attr" name="windowAllowExitTransitionOverlap" />
-  <public type="attr" name="windowAllowEnterTransitionOverlap" />
-  <public type="attr" name="sessionService" />
-  <public type="attr" name="stackViewStyle" />
-  <public type="attr" name="switchStyle" />
-  <public type="attr" name="elevation" />
-  <public type="attr" name="excludeId" />
-  <public type="attr" name="excludeClass" />
-  <public type="attr" name="hideOnContentScroll" />
-  <public type="attr" name="actionOverflowMenuStyle" />
-  <public type="attr" name="documentLaunchMode" />
-  <public type="attr" name="maxRecents" />
-  <public type="attr" name="autoRemoveFromRecents" />
-  <public type="attr" name="stateListAnimator" />
-  <public type="attr" name="toId" />
-  <public type="attr" name="fromId" />
-  <public type="attr" name="reversible" />
-  <public type="attr" name="splitTrack" />
-  <public type="attr" name="targetName" />
-  <public type="attr" name="excludeName" />
-  <public type="attr" name="matchOrder" />
-  <public type="attr" name="windowDrawsSystemBarBackgrounds" />
-  <public type="attr" name="statusBarColor"/>
-  <public type="attr" name="navigationBarColor"/>
-  <public type="attr" name="contentInsetStart" />
-  <public type="attr" name="contentInsetEnd" />
-  <public type="attr" name="contentInsetLeft" />
-  <public type="attr" name="contentInsetRight" />
-  <public type="attr" name="paddingMode" />
-  <public type="attr" name="layout_rowWeight" />
-  <public type="attr" name="layout_columnWeight" />
-  <public type="attr" name="translateX" />
-  <public type="attr" name="translateY" />
-  <public type="attr" name="selectableItemBackgroundBorderless" />
-  <public type="attr" name="elegantTextHeight" />
-  <public type="attr" name="searchKeyphraseId" />
-  <public type="attr" name="searchKeyphrase" />
-  <public type="attr" name="searchKeyphraseSupportedLocales" />
-  <public type="attr" name="windowTransitionBackgroundFadeDuration" />
-  <public type="attr" name="overlapAnchor" />
-  <public type="attr" name="progressTint" />
-  <public type="attr" name="progressTintMode" />
-  <public type="attr" name="progressBackgroundTint" />
-  <public type="attr" name="progressBackgroundTintMode" />
-  <public type="attr" name="secondaryProgressTint" />
-  <public type="attr" name="secondaryProgressTintMode" />
-  <public type="attr" name="indeterminateTint" />
-  <public type="attr" name="indeterminateTintMode" />
-  <public type="attr" name="backgroundTint" />
-  <public type="attr" name="backgroundTintMode" />
-  <public type="attr" name="foregroundTint" />
-  <public type="attr" name="foregroundTintMode" />
-  <public type="attr" name="buttonTint" />
-  <public type="attr" name="buttonTintMode" />
-  <public type="attr" name="thumbTint" />
-  <public type="attr" name="thumbTintMode" />
-  <public type="attr" name="fullBackupOnly" />
-  <public type="attr" name="propertyXName" />
-  <public type="attr" name="propertyYName" />
-  <public type="attr" name="relinquishTaskIdentity" />
-  <public type="attr" name="tileModeX" />
-  <public type="attr" name="tileModeY" />
-  <public type="attr" name="actionModeShareDrawable" />
-  <public type="attr" name="actionModeFindDrawable" />
-  <public type="attr" name="actionModeWebSearchDrawable" />
-  <public type="attr" name="visibilityMode" />
-  <public type="attr" name="minimumHorizontalAngle" />
-  <public type="attr" name="minimumVerticalAngle" />
-  <public type="attr" name="maximumAngle" />
-  <public type="attr" name="searchViewStyle" />
-  <public type="attr" name="closeIcon" />
-  <public type="attr" name="goIcon" />
-  <public type="attr" name="searchIcon" />
-  <public type="attr" name="voiceIcon" />
-  <public type="attr" name="commitIcon" />
-  <public type="attr" name="suggestionRowLayout" />
-  <public type="attr" name="queryBackground" />
-  <public type="attr" name="submitBackground" />
-  <public type="attr" name="buttonBarPositiveButtonStyle" />
-  <public type="attr" name="buttonBarNeutralButtonStyle" />
-  <public type="attr" name="buttonBarNegativeButtonStyle" />
-  <public type="attr" name="popupElevation" />
-  <public type="attr" name="actionBarPopupTheme" />
-  <public type="attr" name="multiArch" />
-  <public type="attr" name="touchscreenBlocksFocus" />
-  <public type="attr" name="windowElevation" />
-  <public type="attr" name="launchTaskBehindBackgroundAnimation" />
-  <public type="attr" name="launchTaskBehindSourceAnimation" />
-  <public type="attr" name="restrictionType" />
-  <public type="attr" name="dayOfWeekBackgroundColor" />
-  <public type="attr" name="dayOfWeekTextAppearance" />
-  <public type="attr" name="headerMonthTextAppearance" />
-  <public type="attr" name="headerDayOfMonthTextAppearance" />
-  <public type="attr" name="headerYearTextAppearance" />
-  <public type="attr" name="yearListItemTextAppearance" />
-  <public type="attr" name="yearListSelectorColor" />
-  <public type="attr" name="calendarTextColor" />
-  <public type="attr" name="recognitionService" />
-  <public type="attr" name="timePickerStyle" />
-  <public type="attr" name="timePickerDialogTheme" />
-  <public type="attr" name="headerTimeTextAppearance" />
-  <public type="attr" name="headerAmPmTextAppearance" />
-  <public type="attr" name="headerBackgroundColor" />
-  <public type="attr" name="numbersTextColor" />
-  <public type="attr" name="numbersBackgroundColor" />
-  <public type="attr" name="numbersSelectorColor" />
-  <public type="attr" name="amPmTextColor" />
-  <public type="attr" name="amPmBackgroundColor" />
-  <public type="attr" name="searchKeyphraseRecognitionFlags" />
-  <public type="attr" name="checkMarkTint" />
-  <public type="attr" name="checkMarkTintMode" />
-  <public type="attr" name="popupTheme" />
-  <public type="attr" name="toolbarStyle" />
-  <public type="attr" name="windowClipToOutline" />
-  <public type="attr" name="datePickerDialogTheme" />
-  <public type="attr" name="showText" />
-  <public type="attr" name="windowReturnTransition" />
-  <public type="attr" name="windowReenterTransition" />
-  <public type="attr" name="windowSharedElementReturnTransition" />
-  <public type="attr" name="windowSharedElementReenterTransition" />
-  <public type="attr" name="tvContentRatingDescription"/>
-  <public type="attr" name="datePickerMode"/>
-  <public type="attr" name="timePickerMode"/>
-  <public type="attr" name="inset" />
-  <public type="attr" name="letterSpacing" />
-  <public type="attr" name="fontFeatureSettings" />
+    <public type="id" name="mask" id="0x0102002e" />
+    <public type="id" name="statusBarBackground" id="0x0102002f" />
+    <public type="id" name="navigationBarBackground" id="0x01020030" />
 
-  <public-padding type="dimen" name="l_resource_pad" end="0x01050010" />
+    <public type="style" name="Widget.FastScroll" id="0x010301e5" />
+    <public type="style" name="Widget.StackView" id="0x010301e6" />
+    <public type="style" name="Widget.Toolbar" id="0x010301e7" />
+    <public type="style" name="Widget.Toolbar.Button.Navigation" id="0x010301e8" />
 
-  <public-padding type="id" name="l_resource_pad" end="0x01020040" />
+    <public type="style" name="Widget.DeviceDefault.FastScroll" id="0x010301e9" />
+    <public type="style" name="Widget.DeviceDefault.StackView" id="0x010301ea" />
+    <public type="style" name="Widget.DeviceDefault.Light.FastScroll" id="0x010301eb" />
+    <public type="style" name="Widget.DeviceDefault.Light.StackView" id="0x010301ec" />
 
-  <public type="id" name="mask" />
+    <public type="style" name="TextAppearance.Material" id="0x010301ed" />
+    <public type="style" name="TextAppearance.Material.Button" id="0x010301ee" />
+    <public type="style" name="TextAppearance.Material.Body2" id="0x010301ef" />
+    <public type="style" name="TextAppearance.Material.Body1" id="0x010301f0" />
+    <public type="style" name="TextAppearance.Material.Caption" id="0x010301f1" />
+    <public type="style" name="TextAppearance.Material.DialogWindowTitle" id="0x010301f2" />
+    <public type="style" name="TextAppearance.Material.Display4" id="0x010301f3" />
+    <public type="style" name="TextAppearance.Material.Display3" id="0x010301f4" />
+    <public type="style" name="TextAppearance.Material.Display2" id="0x010301f5" />
+    <public type="style" name="TextAppearance.Material.Display1" id="0x010301f6" />
+    <public type="style" name="TextAppearance.Material.Headline" id="0x010301f7" />
+    <public type="style" name="TextAppearance.Material.Inverse" id="0x010301f8" />
+    <public type="style" name="TextAppearance.Material.Large" id="0x010301f9" />
+    <public type="style" name="TextAppearance.Material.Large.Inverse" id="0x010301fa" />
+    <public type="style" name="TextAppearance.Material.Medium" id="0x010301fb" />
+    <public type="style" name="TextAppearance.Material.Medium.Inverse" id="0x010301fc" />
+    <public type="style" name="TextAppearance.Material.Menu" id="0x010301fd" />
+    <public type="style" name="TextAppearance.Material.Notification" id="0x010301fe" />
+    <public type="style" name="TextAppearance.Material.Notification.Emphasis" id="0x010301ff" />
+    <public type="style" name="TextAppearance.Material.Notification.Info" id="0x01030200" />
+    <public type="style" name="TextAppearance.Material.Notification.Line2" id="0x01030201" />
+    <public type="style" name="TextAppearance.Material.Notification.Time" id="0x01030202" />
+    <public type="style" name="TextAppearance.Material.Notification.Title" id="0x01030203" />
+    <public type="style" name="TextAppearance.Material.SearchResult.Subtitle" id="0x01030204" />
+    <public type="style" name="TextAppearance.Material.SearchResult.Title" id="0x01030205" />
+    <public type="style" name="TextAppearance.Material.Small" id="0x01030206" />
+    <public type="style" name="TextAppearance.Material.Small.Inverse" id="0x01030207" />
+    <public type="style" name="TextAppearance.Material.Subhead" id="0x01030208" />
+    <public type="style" name="TextAppearance.Material.Title" id="0x01030209" />
+    <public type="style" name="TextAppearance.Material.WindowTitle" id="0x0103020a" />
 
-  <public-padding type="style" name="l_resource_pad" end="0x01030200" />
+    <public type="style" name="TextAppearance.Material.Widget" id="0x0103020b" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionBar.Menu" id="0x0103020c" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionBar.Subtitle" id="0x0103020d" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionBar.Subtitle.Inverse" id="0x0103020e" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionBar.Title" id="0x0103020f" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionBar.Title.Inverse" id="0x01030210" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionMode.Subtitle" id="0x01030211" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionMode.Subtitle.Inverse" id="0x01030212" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionMode.Title" id="0x01030213" />
+    <public type="style" name="TextAppearance.Material.Widget.ActionMode.Title.Inverse" id="0x01030214" />
+    <public type="style" name="TextAppearance.Material.Widget.Button" id="0x01030215" />
+    <public type="style" name="TextAppearance.Material.Widget.DropDownHint" id="0x01030216" />
+    <public type="style" name="TextAppearance.Material.Widget.DropDownItem" id="0x01030217" />
+    <public type="style" name="TextAppearance.Material.Widget.EditText" id="0x01030218" />
+    <public type="style" name="TextAppearance.Material.Widget.IconMenu.Item" id="0x01030219" />
+    <public type="style" name="TextAppearance.Material.Widget.PopupMenu" id="0x0103021a" />
+    <public type="style" name="TextAppearance.Material.Widget.PopupMenu.Large" id="0x0103021b" />
+    <public type="style" name="TextAppearance.Material.Widget.PopupMenu.Small" id="0x0103021c" />
+    <public type="style" name="TextAppearance.Material.Widget.TabWidget" id="0x0103021d" />
+    <public type="style" name="TextAppearance.Material.Widget.TextView" id="0x0103021e" />
+    <public type="style" name="TextAppearance.Material.Widget.TextView.PopupMenu" id="0x0103021f" />
+    <public type="style" name="TextAppearance.Material.Widget.TextView.SpinnerItem" id="0x01030220" />
+    <public type="style" name="TextAppearance.Material.Widget.Toolbar.Subtitle" id="0x01030221" />
+    <public type="style" name="TextAppearance.Material.Widget.Toolbar.Title" id="0x01030222" />
 
-  <public type="style" name="Widget.FastScroll" />
-  <public type="style" name="Widget.StackView" />
-  <public type="style" name="Widget.Toolbar" />
-  <public type="style" name="Widget.Toolbar.Button.Navigation" />
+    <public type="style" name="Theme.DeviceDefault.Settings" id="0x01030223" />
 
-  <public type="style" name="Widget.Holo.FastScroll" />
-  <public type="style" name="Widget.Holo.StackView" />
+    <public type="style" name="Theme.Material" id="0x01030224" />
+    <public type="style" name="Theme.Material.Dialog" id="0x01030225" />
+    <public type="style" name="Theme.Material.Dialog.Alert" id="0x01030226" />
+    <public type="style" name="Theme.Material.Dialog.MinWidth" id="0x01030227" />
+    <public type="style" name="Theme.Material.Dialog.NoActionBar" id="0x01030228" />
+    <public type="style" name="Theme.Material.Dialog.NoActionBar.MinWidth" id="0x01030229" />
+    <public type="style" name="Theme.Material.Dialog.Presentation" id="0x0103022a" />
+    <public type="style" name="Theme.Material.DialogWhenLarge" id="0x0103022b" />
+    <public type="style" name="Theme.Material.DialogWhenLarge.NoActionBar" id="0x0103022c" />
+    <public type="style" name="Theme.Material.InputMethod" id="0x0103022d" />
+    <public type="style" name="Theme.Material.NoActionBar" id="0x0103022e" />
+    <public type="style" name="Theme.Material.NoActionBar.Fullscreen" id="0x0103022f" />
+    <public type="style" name="Theme.Material.NoActionBar.Overscan" id="0x01030230" />
+    <public type="style" name="Theme.Material.NoActionBar.TranslucentDecor" id="0x01030231" />
+    <public type="style" name="Theme.Material.Panel" id="0x01030232" />
+    <public type="style" name="Theme.Material.Settings" id="0x01030233" />
+    <public type="style" name="Theme.Material.Voice" id="0x01030234" />
+    <public type="style" name="Theme.Material.Wallpaper" id="0x01030235" />
+    <public type="style" name="Theme.Material.Wallpaper.NoTitleBar" id="0x01030236" />
 
-  <public type="style" name="Widget.Holo.Light.Button.Borderless" />
-  <public type="style" name="Widget.Holo.Light.FastScroll" />
-  <public type="style" name="Widget.Holo.Light.StackView" />
+    <public type="style" name="Theme.Material.Light" id="0x01030237" />
+    <public type="style" name="Theme.Material.Light.DarkActionBar" id="0x01030238" />
+    <public type="style" name="Theme.Material.Light.Dialog" id="0x01030239" />
+    <public type="style" name="Theme.Material.Light.Dialog.Alert" id="0x0103023a" />
+    <public type="style" name="Theme.Material.Light.Dialog.MinWidth" id="0x0103023b" />
+    <public type="style" name="Theme.Material.Light.Dialog.NoActionBar" id="0x0103023c" />
+    <public type="style" name="Theme.Material.Light.Dialog.NoActionBar.MinWidth" id="0x0103023d" />
+    <public type="style" name="Theme.Material.Light.Dialog.Presentation" id="0x0103023e" />
+    <public type="style" name="Theme.Material.Light.DialogWhenLarge" id="0x0103023f" />
+    <public type="style" name="Theme.Material.Light.DialogWhenLarge.NoActionBar" id="0x01030240" />
+    <public type="style" name="Theme.Material.Light.NoActionBar" id="0x01030241" />
+    <public type="style" name="Theme.Material.Light.NoActionBar.Fullscreen" id="0x01030242" />
+    <public type="style" name="Theme.Material.Light.NoActionBar.Overscan" id="0x01030243" />
+    <public type="style" name="Theme.Material.Light.NoActionBar.TranslucentDecor" id="0x01030244" />
+    <public type="style" name="Theme.Material.Light.Panel" id="0x01030245" />
+    <public type="style" name="Theme.Material.Light.Voice" id="0x01030246" />
 
-  <public type="style" name="Widget.DeviceDefault.FastScroll" />
-  <public type="style" name="Widget.DeviceDefault.StackView" />
+    <public type="style" name="ThemeOverlay" id="0x01030247" />
+    <public type="style" name="ThemeOverlay.Material" id="0x01030248" />
+    <public type="style" name="ThemeOverlay.Material.ActionBar" id="0x01030249" />
+    <public type="style" name="ThemeOverlay.Material.Light" id="0x0103024a" />
+    <public type="style" name="ThemeOverlay.Material.Dark" id="0x0103024b" />
+    <public type="style" name="ThemeOverlay.Material.Dark.ActionBar" id="0x0103024c" />
 
-  <public type="style" name="Widget.DeviceDefault.Light.FastScroll" />
-  <public type="style" name="Widget.DeviceDefault.Light.StackView" />
+    <public type="style" name="Widget.Material" id="0x0103024d" />
+    <public type="style" name="Widget.Material.ActionBar" id="0x0103024e" />
+    <public type="style" name="Widget.Material.ActionBar.Solid" id="0x0103024f" />
+    <public type="style" name="Widget.Material.ActionBar.TabBar" id="0x01030250" />
+    <public type="style" name="Widget.Material.ActionBar.TabText" id="0x01030251" />
+    <public type="style" name="Widget.Material.ActionBar.TabView" id="0x01030252" />
+    <public type="style" name="Widget.Material.ActionButton" id="0x01030253" />
+    <public type="style" name="Widget.Material.ActionButton.CloseMode" id="0x01030254" />
+    <public type="style" name="Widget.Material.ActionButton.Overflow" id="0x01030255" />
+    <public type="style" name="Widget.Material.ActionMode" id="0x01030256" />
+    <public type="style" name="Widget.Material.AutoCompleteTextView" id="0x01030257" />
+    <public type="style" name="Widget.Material.Button" id="0x01030258" />
+    <public type="style" name="Widget.Material.Button.Borderless" id="0x01030259" />
+    <public type="style" name="Widget.Material.Button.Borderless.Colored" id="0x0103025a" />
+    <public type="style" name="Widget.Material.Button.Borderless.Small" id="0x0103025b" />
+    <public type="style" name="Widget.Material.Button.Inset" id="0x0103025c" />
+    <public type="style" name="Widget.Material.Button.Small" id="0x0103025d" />
+    <public type="style" name="Widget.Material.Button.Toggle" id="0x0103025e" />
+    <public type="style" name="Widget.Material.ButtonBar" id="0x0103025f" />
+    <public type="style" name="Widget.Material.ButtonBar.AlertDialog" id="0x01030260" />
+    <public type="style" name="Widget.Material.CalendarView" id="0x01030261" />
+    <public type="style" name="Widget.Material.CheckedTextView" id="0x01030262" />
+    <public type="style" name="Widget.Material.CompoundButton.CheckBox" id="0x01030263" />
+    <public type="style" name="Widget.Material.CompoundButton.RadioButton" id="0x01030264" />
+    <public type="style" name="Widget.Material.CompoundButton.Star" id="0x01030265" />
+    <public type="style" name="Widget.Material.DatePicker" id="0x01030266" />
+    <public type="style" name="Widget.Material.DropDownItem" id="0x01030267" />
+    <public type="style" name="Widget.Material.DropDownItem.Spinner" id="0x01030268" />
+    <public type="style" name="Widget.Material.EditText" id="0x01030269" />
+    <public type="style" name="Widget.Material.ExpandableListView" id="0x0103026a" />
+    <public type="style" name="Widget.Material.FastScroll" id="0x0103026b" />
+    <public type="style" name="Widget.Material.GridView" id="0x0103026c" />
+    <public type="style" name="Widget.Material.HorizontalScrollView" id="0x0103026d" />
+    <public type="style" name="Widget.Material.ImageButton" id="0x0103026e" />
+    <public type="style" name="Widget.Material.ListPopupWindow" id="0x0103026f" />
+    <public type="style" name="Widget.Material.ListView" id="0x01030270" />
+    <public type="style" name="Widget.Material.ListView.DropDown" id="0x01030271" />
+    <public type="style" name="Widget.Material.MediaRouteButton" id="0x01030272" />
+    <public type="style" name="Widget.Material.PopupMenu" id="0x01030273" />
+    <public type="style" name="Widget.Material.PopupMenu.Overflow" id="0x01030274" />
+    <public type="style" name="Widget.Material.PopupWindow" id="0x01030275" />
+    <public type="style" name="Widget.Material.ProgressBar" id="0x01030276" />
+    <public type="style" name="Widget.Material.ProgressBar.Horizontal" id="0x01030277" />
+    <public type="style" name="Widget.Material.ProgressBar.Large" id="0x01030278" />
+    <public type="style" name="Widget.Material.ProgressBar.Small" id="0x01030279" />
+    <public type="style" name="Widget.Material.ProgressBar.Small.Title" id="0x0103027a" />
+    <public type="style" name="Widget.Material.RatingBar" id="0x0103027b" />
+    <public type="style" name="Widget.Material.RatingBar.Indicator" id="0x0103027c" />
+    <public type="style" name="Widget.Material.RatingBar.Small" id="0x0103027d" />
+    <public type="style" name="Widget.Material.ScrollView" id="0x0103027e" />
+    <public type="style" name="Widget.Material.SearchView" id="0x0103027f" />
+    <public type="style" name="Widget.Material.SeekBar" id="0x01030280" />
+    <public type="style" name="Widget.Material.SegmentedButton" id="0x01030281" />
+    <public type="style" name="Widget.Material.StackView" id="0x01030282" />
+    <public type="style" name="Widget.Material.Spinner" id="0x01030283" />
+    <public type="style" name="Widget.Material.Spinner.Underlined" id="0x01030284" />
+    <public type="style" name="Widget.Material.Tab" id="0x01030285" />
+    <public type="style" name="Widget.Material.TabWidget" id="0x01030286" />
+    <public type="style" name="Widget.Material.TextView" id="0x01030287" />
+    <public type="style" name="Widget.Material.TextView.SpinnerItem" id="0x01030288" />
+    <public type="style" name="Widget.Material.TimePicker" id="0x01030289" />
+    <public type="style" name="Widget.Material.Toolbar" id="0x0103028a" />
+    <public type="style" name="Widget.Material.Toolbar.Button.Navigation" id="0x0103028b" />
+    <public type="style" name="Widget.Material.WebTextView" id="0x0103028c" />
+    <public type="style" name="Widget.Material.WebView" id="0x0103028d" />
 
-  <public type="style" name="TextAppearance.Material" />
-  <public type="style" name="TextAppearance.Material.DialogWindowTitle" />
-  <public type="style" name="TextAppearance.Material.Inverse" />
-  <public type="style" name="TextAppearance.Material.Large" />
-  <public type="style" name="TextAppearance.Material.Large.Inverse" />
-  <public type="style" name="TextAppearance.Material.Medium" />
-  <public type="style" name="TextAppearance.Material.Medium.Inverse" />
-  <public type="style" name="TextAppearance.Material.SearchResult.Subtitle" />
-  <public type="style" name="TextAppearance.Material.SearchResult.Title" />
-  <public type="style" name="TextAppearance.Material.Small" />
-  <public type="style" name="TextAppearance.Material.Small.Inverse" />
-  <public type="style" name="TextAppearance.Material.WindowTitle" />
+    <public type="style" name="Widget.Material.Light" id="0x0103028e" />
+    <public type="style" name="Widget.Material.Light.ActionBar" id="0x0103028f" />
+    <public type="style" name="Widget.Material.Light.ActionBar.Solid" id="0x01030290" />
+    <public type="style" name="Widget.Material.Light.ActionBar.TabBar" id="0x01030291" />
+    <public type="style" name="Widget.Material.Light.ActionBar.TabText" id="0x01030292" />
+    <public type="style" name="Widget.Material.Light.ActionBar.TabView" id="0x01030293" />
+    <public type="style" name="Widget.Material.Light.ActionButton" id="0x01030294" />
+    <public type="style" name="Widget.Material.Light.ActionButton.CloseMode" id="0x01030295" />
+    <public type="style" name="Widget.Material.Light.ActionButton.Overflow" id="0x01030296" />
+    <public type="style" name="Widget.Material.Light.ActionMode" id="0x01030297" />
+    <public type="style" name="Widget.Material.Light.AutoCompleteTextView" id="0x01030298" />
+    <public type="style" name="Widget.Material.Light.Button" id="0x01030299" />
+    <public type="style" name="Widget.Material.Light.Button.Borderless" id="0x0103029a" />
+    <public type="style" name="Widget.Material.Light.Button.Borderless.Colored" id="0x0103029b" />
+    <public type="style" name="Widget.Material.Light.Button.Borderless.Small" id="0x0103029c" />
+    <public type="style" name="Widget.Material.Light.Button.Inset" id="0x0103029d" />
+    <public type="style" name="Widget.Material.Light.Button.Small" id="0x0103029e" />
+    <public type="style" name="Widget.Material.Light.Button.Toggle" id="0x0103029f" />
+    <public type="style" name="Widget.Material.Light.ButtonBar" id="0x010302a0" />
+    <public type="style" name="Widget.Material.Light.ButtonBar.AlertDialog" id="0x010302a1" />
+    <public type="style" name="Widget.Material.Light.CalendarView" id="0x010302a2" />
+    <public type="style" name="Widget.Material.Light.CheckedTextView" id="0x010302a3" />
+    <public type="style" name="Widget.Material.Light.CompoundButton.CheckBox" id="0x010302a4" />
+    <public type="style" name="Widget.Material.Light.CompoundButton.RadioButton" id="0x010302a5" />
+    <public type="style" name="Widget.Material.Light.CompoundButton.Star" id="0x010302a6" />
+    <public type="style" name="Widget.Material.Light.DatePicker" id="0x010302a7" />
+    <public type="style" name="Widget.Material.Light.DropDownItem" id="0x010302a8" />
+    <public type="style" name="Widget.Material.Light.DropDownItem.Spinner" id="0x010302a9" />
+    <public type="style" name="Widget.Material.Light.EditText" id="0x010302aa" />
+    <public type="style" name="Widget.Material.Light.ExpandableListView" id="0x010302ab" />
+    <public type="style" name="Widget.Material.Light.FastScroll" id="0x010302ac" />
+    <public type="style" name="Widget.Material.Light.GridView" id="0x010302ad" />
+    <public type="style" name="Widget.Material.Light.HorizontalScrollView" id="0x010302ae" />
+    <public type="style" name="Widget.Material.Light.ImageButton" id="0x010302af" />
+    <public type="style" name="Widget.Material.Light.ListPopupWindow" id="0x010302b0" />
+    <public type="style" name="Widget.Material.Light.ListView" id="0x010302b1" />
+    <public type="style" name="Widget.Material.Light.ListView.DropDown" id="0x010302b2" />
+    <public type="style" name="Widget.Material.Light.MediaRouteButton" id="0x010302b3" />
+    <public type="style" name="Widget.Material.Light.PopupMenu" id="0x010302b4" />
+    <public type="style" name="Widget.Material.Light.PopupMenu.Overflow" id="0x010302b5" />
+    <public type="style" name="Widget.Material.Light.PopupWindow" id="0x010302b6" />
+    <public type="style" name="Widget.Material.Light.ProgressBar" id="0x010302b7" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Horizontal" id="0x010302b8" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Inverse" id="0x010302b9" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Large" id="0x010302ba" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Large.Inverse" id="0x010302bb" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Small" id="0x010302bc" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Small.Inverse" id="0x010302bd" />
+    <public type="style" name="Widget.Material.Light.ProgressBar.Small.Title" id="0x010302be" />
+    <public type="style" name="Widget.Material.Light.RatingBar" id="0x010302bf" />
+    <public type="style" name="Widget.Material.Light.RatingBar.Indicator" id="0x010302c0" />
+    <public type="style" name="Widget.Material.Light.RatingBar.Small" id="0x010302c1" />
+    <public type="style" name="Widget.Material.Light.ScrollView" id="0x010302c2" />
+    <public type="style" name="Widget.Material.Light.SearchView" id="0x010302c3" />
+    <public type="style" name="Widget.Material.Light.SeekBar" id="0x010302c4" />
+    <public type="style" name="Widget.Material.Light.SegmentedButton" id="0x010302c5" />
+    <public type="style" name="Widget.Material.Light.StackView" id="0x010302c6" />
+    <public type="style" name="Widget.Material.Light.Spinner" id="0x010302c7" />
+    <public type="style" name="Widget.Material.Light.Spinner.Underlined" id="0x010302c8" />
+    <public type="style" name="Widget.Material.Light.Tab" id="0x010302c9" />
+    <public type="style" name="Widget.Material.Light.TabWidget" id="0x010302ca" />
+    <public type="style" name="Widget.Material.Light.TextView" id="0x010302cb" />
+    <public type="style" name="Widget.Material.Light.TextView.SpinnerItem" id="0x010302cc" />
+    <public type="style" name="Widget.Material.Light.TimePicker" id="0x010302cd" />
+    <public type="style" name="Widget.Material.Light.WebTextView" id="0x010302ce" />
+    <public type="style" name="Widget.Material.Light.WebView" id="0x010302cf" />
 
-  <public type="style" name="TextAppearance.Material.Widget" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionBar.Menu" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionBar.Subtitle" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionBar.Subtitle.Inverse" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionBar.Title" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionBar.Title.Inverse" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionMode.Subtitle" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionMode.Subtitle.Inverse" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionMode.Title" />
-  <public type="style" name="TextAppearance.Material.Widget.ActionMode.Title.Inverse" />
-  <public type="style" name="TextAppearance.Material.Widget.Button" />
-  <public type="style" name="TextAppearance.Material.Widget.DropDownHint" />
-  <public type="style" name="TextAppearance.Material.Widget.DropDownItem" />
-  <public type="style" name="TextAppearance.Material.Widget.EditText" />
-  <public type="style" name="TextAppearance.Material.Widget.IconMenu.Item" />
-  <public type="style" name="TextAppearance.Material.Widget.PopupMenu" />
-  <public type="style" name="TextAppearance.Material.Widget.PopupMenu.Large" />
-  <public type="style" name="TextAppearance.Material.Widget.PopupMenu.Small" />
-  <public type="style" name="TextAppearance.Material.Widget.TabWidget" />
-  <public type="style" name="TextAppearance.Material.Widget.TextView" />
-  <public type="style" name="TextAppearance.Material.Widget.TextView.PopupMenu" />
-  <public type="style" name="TextAppearance.Material.Widget.TextView.SpinnerItem" />
+    <!-- @hide This really shouldn't be public; clients using it should use @* to ref it.  -->
+    <public type="style" name="Theme.Leanback.FormWizard" id="0x010302d0" />
 
-  <public type="style" name="Theme.DeviceDefault.Settings" />
+    <public type="string" name="config_webSettingsDefaultTextEncoding" id="0x01040018" />
 
-  <public type="style" name="Theme.Material" />
-  <public type="style" name="Theme.Material.Dialog" />
-  <public type="style" name="Theme.Material.Dialog.MinWidth" />
-  <public type="style" name="Theme.Material.Dialog.NoActionBar" />
-  <public type="style" name="Theme.Material.Dialog.NoActionBar.MinWidth" />
-  <public type="style" name="Theme.Material.DialogWhenLarge" />
-  <public type="style" name="Theme.Material.DialogWhenLarge.NoActionBar" />
-  <public type="style" name="Theme.Material.InputMethod" />
-  <public type="style" name="Theme.Material.NoActionBar" />
-  <public type="style" name="Theme.Material.NoActionBar.Fullscreen" />
-  <public type="style" name="Theme.Material.NoActionBar.Overscan" />
-  <public type="style" name="Theme.Material.NoActionBar.TranslucentDecor" />
-  <public type="style" name="Theme.Material.Panel" />
-  <public type="style" name="Theme.Material.Settings" />
-  <public type="style" name="Theme.Material.Voice" />
-  <public type="style" name="Theme.Material.Wallpaper" />
-  <public type="style" name="Theme.Material.Wallpaper.NoTitleBar" />
+    <public type="array" name="config_keySystemUuidMapping" id="0x01070005" />
 
-  <public type="style" name="Theme.Material.Light" />
-  <public type="style" name="Theme.Material.Light.DarkActionBar" />
-  <public type="style" name="Theme.Material.Light.Dialog" />
-  <public type="style" name="Theme.Material.Light.Dialog.MinWidth" />
-  <public type="style" name="Theme.Material.Light.Dialog.NoActionBar" />
-  <public type="style" name="Theme.Material.Light.Dialog.NoActionBar.MinWidth" />
-  <public type="style" name="Theme.Material.Light.DialogWhenLarge" />
-  <public type="style" name="Theme.Material.Light.DialogWhenLarge.NoActionBar" />
-  <public type="style" name="Theme.Material.Light.NoActionBar" />
-  <public type="style" name="Theme.Material.Light.NoActionBar.Fullscreen" />
-  <public type="style" name="Theme.Material.Light.NoActionBar.Overscan" />
-  <public type="style" name="Theme.Material.Light.NoActionBar.TranslucentDecor" />
-  <public type="style" name="Theme.Material.Light.Panel" />
-  <public type="style" name="Theme.Material.Light.Voice" />
+    <!-- An interpolator which accelerates fast but decelerates slowly. -->
+    <public type="interpolator" name="fast_out_slow_in" id="0x010c000d" />
+    <!-- An interpolator which starts with a peak non-zero velocity and decelerates slowly. -->
+    <public type="interpolator" name="linear_out_slow_in" id="0x010c000e" />
+    <!-- An interpolator which accelerates fast and keeps accelerating until the end. -->
+    <public type="interpolator" name="fast_out_linear_in" id="0x010c000f" />
 
-  <public type="style" name="ThemeOverlay" />
-  <public type="style" name="ThemeOverlay.Material" />
-  <public type="style" name="ThemeOverlay.Material.ActionBar" />
-  <public type="style" name="ThemeOverlay.Material.Light" />
-  <public type="style" name="ThemeOverlay.Material.Dark" />
-  <public type="style" name="ThemeOverlay.Material.Dark.ActionBar" />
+    <!-- Used for Activity Transitions, this transition indicates that no Transition
+         should be used. -->
+    <public type="transition" name="no_transition" id="0x010f0000" />
+    <!-- A transition that moves and resizes a view -->
+    <public type="transition" name="move" id="0x010f0001" />
+    <!-- A transition that fades views in and out. -->
+    <public type="transition" name="fade" id="0x010f0002" />
+    <!-- A transition that moves views in or out of the scene to or from the edges when
+         a view visibility changes. -->
+    <public type="transition" name="explode" id="0x010f0003" />
+    <!-- A transition that moves views in or out of the scene to or from the bottom edge when
+         a view visibility changes. -->
+    <public type="transition" name="slide_bottom" id="0x010f0004" />
+    <!-- A transition that moves views in or out of the scene to or from the top edge when
+         a view visibility changes. -->
+    <public type="transition" name="slide_top" id="0x010f0005" />
+    <!-- A transition that moves views in or out of the scene to or from the right edge when
+         a view visibility changes. -->
+    <public type="transition" name="slide_right" id="0x010f0006" />
+    <!-- A transition that moves views in or out of the scene to or from the left edge when
+         a view visibility changes. -->
+    <public type="transition" name="slide_left" id="0x010f0007" />
 
-  <public type="style" name="Widget.Material" />
-  <public type="style" name="Widget.Material.ActionBar" />
-  <public type="style" name="Widget.Material.ActionBar.Solid" />
-  <public type="style" name="Widget.Material.ActionBar.TabBar" />
-  <public type="style" name="Widget.Material.ActionBar.TabText" />
-  <public type="style" name="Widget.Material.ActionBar.TabView" />
-  <public type="style" name="Widget.Material.ActionButton" />
-  <public type="style" name="Widget.Material.ActionButton.CloseMode" />
-  <public type="style" name="Widget.Material.ActionButton.Overflow" />
-  <public type="style" name="Widget.Material.ActionMode" />
-  <public type="style" name="Widget.Material.AutoCompleteTextView" />
-  <public type="style" name="Widget.Material.Button" />
-  <public type="style" name="Widget.Material.Button.Borderless" />
-  <public type="style" name="Widget.Material.Button.Borderless.Small" />
-  <public type="style" name="Widget.Material.Button.Inset" />
-  <public type="style" name="Widget.Material.Button.Small" />
-  <public type="style" name="Widget.Material.Button.Toggle" />
-  <public type="style" name="Widget.Material.ButtonBar" />
-  <public type="style" name="Widget.Material.ButtonBar.AlertDialog" />
-  <public type="style" name="Widget.Material.CalendarView" />
-  <public type="style" name="Widget.Material.CheckedTextView" />
-  <public type="style" name="Widget.Material.CompoundButton.CheckBox" />
-  <public type="style" name="Widget.Material.CompoundButton.RadioButton" />
-  <public type="style" name="Widget.Material.CompoundButton.Star" />
-  <public type="style" name="Widget.Material.DatePicker" />
-  <public type="style" name="Widget.Material.DropDownItem" />
-  <public type="style" name="Widget.Material.DropDownItem.Spinner" />
-  <public type="style" name="Widget.Material.EditText" />
-  <public type="style" name="Widget.Material.ExpandableListView" />
-  <public type="style" name="Widget.Material.FastScroll" />
-  <public type="style" name="Widget.Material.GridView" />
-  <public type="style" name="Widget.Material.HorizontalScrollView" />
-  <public type="style" name="Widget.Material.ImageButton" />
-  <public type="style" name="Widget.Material.ListPopupWindow" />
-  <public type="style" name="Widget.Material.ListView" />
-  <public type="style" name="Widget.Material.ListView.DropDown" />
-  <public type="style" name="Widget.Material.MediaRouteButton" />
-  <public type="style" name="Widget.Material.PopupMenu" />
-  <public type="style" name="Widget.Material.PopupMenu.Overflow" />
-  <public type="style" name="Widget.Material.PopupWindow" />
-  <public type="style" name="Widget.Material.ProgressBar" />
-  <public type="style" name="Widget.Material.ProgressBar.Horizontal" />
-  <public type="style" name="Widget.Material.ProgressBar.Large" />
-  <public type="style" name="Widget.Material.ProgressBar.Small" />
-  <public type="style" name="Widget.Material.ProgressBar.Small.Title" />
-  <public type="style" name="Widget.Material.RatingBar" />
-  <public type="style" name="Widget.Material.RatingBar.Indicator" />
-  <public type="style" name="Widget.Material.RatingBar.Small" />
-  <public type="style" name="Widget.Material.ScrollView" />
-  <public type="style" name="Widget.Material.SeekBar" />
-  <public type="style" name="Widget.Material.SegmentedButton" />
-  <public type="style" name="Widget.Material.StackView" />
-  <public type="style" name="Widget.Material.Spinner" />
-  <public type="style" name="Widget.Material.Tab" />
-  <public type="style" name="Widget.Material.TabWidget" />
-  <public type="style" name="Widget.Material.TextView" />
-  <public type="style" name="Widget.Material.TextView.SpinnerItem" />
-  <public type="style" name="Widget.Material.Toolbar" />
-  <public type="style" name="Widget.Material.Toolbar.Button.Navigation" />
-  <public type="style" name="Widget.Material.WebTextView" />
-  <public type="style" name="Widget.Material.WebView" />
-
-  <public type="style" name="Widget.Material.Light" />
-  <public type="style" name="Widget.Material.Light.ActionBar" />
-  <public type="style" name="Widget.Material.Light.ActionBar.Solid" />
-  <public type="style" name="Widget.Material.Light.ActionBar.TabBar" />
-  <public type="style" name="Widget.Material.Light.ActionBar.TabText" />
-  <public type="style" name="Widget.Material.Light.ActionBar.TabView" />
-  <public type="style" name="Widget.Material.Light.ActionButton" />
-  <public type="style" name="Widget.Material.Light.ActionButton.CloseMode" />
-  <public type="style" name="Widget.Material.Light.ActionButton.Overflow" />
-  <public type="style" name="Widget.Material.Light.ActionMode" />
-  <public type="style" name="Widget.Material.Light.AutoCompleteTextView" />
-  <public type="style" name="Widget.Material.Light.Button" />
-  <public type="style" name="Widget.Material.Light.Button.Borderless" />
-  <public type="style" name="Widget.Material.Light.Button.Borderless.Small" />
-  <public type="style" name="Widget.Material.Light.Button.Inset" />
-  <public type="style" name="Widget.Material.Light.Button.Small" />
-  <public type="style" name="Widget.Material.Light.Button.Toggle" />
-  <public type="style" name="Widget.Material.Light.ButtonBar" />
-  <public type="style" name="Widget.Material.Light.ButtonBar.AlertDialog" />
-  <public type="style" name="Widget.Material.Light.CalendarView" />
-  <public type="style" name="Widget.Material.Light.CheckedTextView" />
-  <public type="style" name="Widget.Material.Light.CompoundButton.CheckBox" />
-  <public type="style" name="Widget.Material.Light.CompoundButton.RadioButton" />
-  <public type="style" name="Widget.Material.Light.CompoundButton.Star" />
-  <public type="style" name="Widget.Material.Light.DropDownItem" />
-  <public type="style" name="Widget.Material.Light.DropDownItem.Spinner" />
-  <public type="style" name="Widget.Material.Light.EditText" />
-  <public type="style" name="Widget.Material.Light.ExpandableListView" />
-  <public type="style" name="Widget.Material.Light.FastScroll" />
-  <public type="style" name="Widget.Material.Light.GridView" />
-  <public type="style" name="Widget.Material.Light.HorizontalScrollView" />
-  <public type="style" name="Widget.Material.Light.ImageButton" />
-  <public type="style" name="Widget.Material.Light.ListPopupWindow" />
-  <public type="style" name="Widget.Material.Light.ListView" />
-  <public type="style" name="Widget.Material.Light.ListView.DropDown" />
-  <public type="style" name="Widget.Material.Light.MediaRouteButton" />
-  <public type="style" name="Widget.Material.Light.PopupMenu" />
-  <public type="style" name="Widget.Material.Light.PopupMenu.Overflow" />
-  <public type="style" name="Widget.Material.Light.PopupWindow" />
-  <public type="style" name="Widget.Material.Light.ProgressBar" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Horizontal" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Inverse" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Large" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Large.Inverse" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Small" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Small.Inverse" />
-  <public type="style" name="Widget.Material.Light.ProgressBar.Small.Title" />
-  <public type="style" name="Widget.Material.Light.RatingBar" />
-  <public type="style" name="Widget.Material.Light.RatingBar.Indicator" />
-  <public type="style" name="Widget.Material.Light.RatingBar.Small" />
-  <public type="style" name="Widget.Material.Light.ScrollView" />
-  <public type="style" name="Widget.Material.Light.SeekBar" />
-  <public type="style" name="Widget.Material.Light.SegmentedButton" />
-  <public type="style" name="Widget.Material.Light.StackView" />
-  <public type="style" name="Widget.Material.Light.Spinner" />
-  <public type="style" name="Widget.Material.Light.Tab" />
-  <public type="style" name="Widget.Material.Light.TabWidget" />
-  <public type="style" name="Widget.Material.Light.TextView" />
-  <public type="style" name="Widget.Material.Light.TextView.SpinnerItem" />
-  <public type="style" name="Widget.Material.Light.WebTextView" />
-  <public type="style" name="Widget.Material.Light.WebView" />
-
-  <public type="style" name="TextAppearance.Material.Display4" />
-  <public type="style" name="TextAppearance.Material.Display3" />
-  <public type="style" name="TextAppearance.Material.Display2" />
-  <public type="style" name="TextAppearance.Material.Display1" />
-  <public type="style" name="TextAppearance.Material.Headline" />
-  <public type="style" name="TextAppearance.Material.Title" />
-  <public type="style" name="TextAppearance.Material.Subhead" />
-  <public type="style" name="TextAppearance.Material.Body2" />
-  <public type="style" name="TextAppearance.Material.Body1" />
-  <public type="style" name="TextAppearance.Material.Caption" />
-  <public type="style" name="TextAppearance.Material.Menu" />
-  <public type="style" name="TextAppearance.Material.Button" />
-
-  <public type="style" name="Widget.Material.Button.Borderless.Colored" />
-  <public type="style" name="Widget.Material.Light.Button.Borderless.Colored" />
-
-  <public type="style" name="Theme.Leanback.FormWizard"/>
-
-  <public type="style" name="TextAppearance.StatusBar.Material" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent.Title" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent.Line2" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent.Info" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent.Time" />
-  <public type="style" name="TextAppearance.StatusBar.Material.EventContent.Emphasis" />
-
-  <public type="style" name="Widget.Material.Spinner.Form" />
-  <public type="style" name="Widget.Material.Light.Spinner.Form" />
-
-  <public-padding type="string" name="l_resource_pad" end="0x01040030" />
-
-  <public type="string" name="config_webSettingsDefaultTextEncoding" />
-
-  <public-padding type="array" name="l_resource_pad" end="0x01070020" />
-
-  <public type="array" name="config_keySystemUuidMapping" />
-
-  <public-padding type="interpolator" name="l_resource_pad" end="0x010c0010" />
-
-  <!-- An interpolator which accelerates fast but decelerates slowly. -->
-  <public type="interpolator" name="fast_out_slow_in" />
-  <!-- An interpolator which starts with a peak non-zero velocity and decelerates slowly. -->
-  <public type="interpolator" name="linear_out_slow_in" />
-  <!-- An interpolator which accelerates fast and keeps accelerating until the end. -->
-  <public type="interpolator" name="fast_out_linear_in" />
-
-  <!-- Used for Activity Transitions, this transition indicates that no Transition
-       should be used. -->
-  <public type="transition" name="no_transition" id="0x010f0000"/>
-  <!-- A transition that moves and resizes a view -->
-  <public type="transition" name="move"/>
-  <!-- A transition that fades views in and out. -->
-  <public type="transition" name="fade"/>
-  <!-- A transition that moves views in or out of the scene to or from the edges when
-       a view visibility changes. -->
-  <public type="transition" name="explode"/>
-  <!-- A transition that moves views in or out of the scene to or from the bottom edge when
-       a view visibility changes. -->
-  <public type="transition" name="slide_bottom"/>
-  <!-- A transition that moves views in or out of the scene to or from the top edge when
-       a view visibility changes. -->
-  <public type="transition" name="slide_top"/>
-  <!-- A transition that moves views in or out of the scene to or from the right edge when
-       a view visibility changes. -->
-  <public type="transition" name="slide_right"/>
-  <!-- A transition that moves views in or out of the scene to or from the left edge when
-       a view visibility changes. -->
-  <public type="transition" name="slide_left"/>
-
-  <!-- WebView error page for when the load fails. @hide @SystemApi -->
-  <public type="raw" name="loaderror" id="0x01100000"/>
-  <!-- WebView error page for when domain lookup fails. @hide @SystemApi -->
-  <public type="raw" name="nodomain"/>
+    <!-- WebView error page for when the load fails. @hide @SystemApi -->
+    <public type="raw" name="loaderror" id="0x01100000" />
+    <!-- WebView error page for when domain lookup fails. @hide @SystemApi -->
+    <public type="raw" name="nodomain" id="0x01100001" />
 </resources>
diff --git a/core/res/res/values/removed.xml b/core/res/res/values/removed.xml
new file mode 100644
index 0000000..8eaca29
--- /dev/null
+++ b/core/res/res/values/removed.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<!-- Placeholder resources to be removed before release. -->
+<resources>
+    <style name="__removed1" />
+    <attr name="__removed2" />
+    <style name="__removed3" />
+    <style name="__removed4" />
+    <style name="__removed5" />
+    <style name="__removed6" />
+    <style name="__removed7" />
+</resources>
diff --git a/core/res/res/values/strings.xml b/core/res/res/values/strings.xml
index c68f355..50da1fa 100644
--- a/core/res/res/values/strings.xml
+++ b/core/res/res/values/strings.xml
@@ -1160,12 +1160,6 @@
         interface of a widget service. Should never be needed for normal apps.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permlab_bindRouteProvider">bind to a route provider service</string>
-    <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permdesc_bindRouteProvider">Allows the holder to bind to any registered
-        route providers. Should never be needed for normal apps.</string>
-
-    <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_bindDeviceAdmin">interact with a device admin</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permdesc_bindDeviceAdmin">Allows the holder to send intents to
@@ -1821,6 +1815,11 @@
     <string name="permdesc_devicePower" product="default">Allows the app to turn the phone on or off.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
+    <string name="permlab_userActivity">reset display timeout</string>
+    <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
+    <string name="permdesc_userActivity">Allows the app to reset the display timeout.</string>
+
+    <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_factoryTest">run in factory test mode</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permdesc_factoryTest" product="tablet">Run as a low-level manufacturer test,
@@ -2112,9 +2111,9 @@
     <string name="permdesc_use_sip">Allows the app to make and receive SIP calls.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permlab_bind_call_service">interact with in-call screen</string>
+    <string name="permlab_bind_incall_service">interact with in-call screen</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permdesc_bind_call_service">Allows the app to control when and how the user sees the in-call screen.</string>
+    <string name="permdesc_bind_incall_service">Allows the app to control when and how the user sees the in-call screen.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_bind_connection_service">interact with telephony services</string>
@@ -2122,6 +2121,11 @@
     <string name="permdesc_bind_connection_service">Allows the app to interact with telephony services to make/receive calls.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
+    <string name="permlab_control_incall_experience">provide an in-call user experience</string>
+    <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
+    <string name="permdesc_control_incall_experience">Allows the app to provide an in-call user experience.</string>
+
+    <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_readNetworkUsageHistory">read historical network usage</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permdesc_readNetworkUsageHistory">Allows the app to read historical network usage for specific networks and apps.</string>
@@ -2152,11 +2156,6 @@
     <string name="permdesc_bindConditionProviderService">Allows the holder to bind to the top-level interface of a condition provider service. Should never be needed for normal apps.</string>
 
     <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permlab_bindMediaRouteService">bind to a media route service</string>
-    <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
-    <string name="permdesc_bindMediaRouteService">Allows the holder to bind to the top-level interface of a media route service. Should never be needed for normal apps.</string>
-
-    <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permlab_bindDreamService">bind to a dream service</string>
     <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. -->
     <string name="permdesc_bindDreamService">Allows the holder to bind to the top-level interface of a dream service. Should never be needed for normal apps.</string>
@@ -3444,6 +3443,9 @@
     <string name="whichHomeApplication">Select a home app</string>
     <!-- Option to always use the selected application resolution in the future. See the "Complete action using" dialog title-->
     <string name="alwaysUse">Use by default for this action.</string>
+    <!-- Title of the list of alternate options to complete an action shown when the
+         last used option is being displayed separately. -->
+    <string name="use_a_different_app">Use a different app</string>
     <!-- Text displayed when the user selects the check box for setting default application.  See the "Use by default for this action" check box. -->
     <string name="clearDefaultHintMsg">Clear default in System settings &gt; Apps &gt; Downloaded.</string>
     <!-- Default title for the activity chooser, when one is not given. Android allows multiple activities to perform an action.  for example, there may be many ringtone pickers installed.  A dialog is shown to the user allowing him to pick which activity should be used.  This is the title. -->
@@ -3643,9 +3645,9 @@
     <!-- The message text for the SMS short code confirmation dialog. [CHAR LIMIT=NONE] -->
     <string name="sms_short_code_confirm_message">&lt;b><xliff:g id="app_name">%1$s</xliff:g>&lt;/b> would like to send a message to &lt;b><xliff:g id="dest_address">%2$s</xliff:g>&lt;/b>.</string>
     <!-- Message details for the SMS short code confirmation dialog (possible premium short code). [CHAR LIMIT=NONE] -->
-    <string name="sms_short_code_details">This <font fgcolor="#ffffb060">may cause charges</font> on your mobile account.</string>
+    <string name="sms_short_code_details">This <b>may cause charges</b> on your mobile account.</string>
     <!-- Message details for the SMS short code confirmation dialog (premium short code). [CHAR LIMIT=NONE] -->
-    <string name="sms_premium_short_code_details"><font fgcolor="#ffffb060">This will cause charges on your mobile account.</font></string>
+    <string name="sms_premium_short_code_details"><b>This will cause charges on your mobile account.</b></string>
     <!-- Text of the approval button for the SMS short code confirmation dialog. [CHAR LIMIT=30] -->
     <string name="sms_short_code_confirm_allow">Send</string>
     <!-- Text of the cancel button for the SMS short code confirmation dialog. [CHAR LIMIT=30] -->
@@ -3899,10 +3901,10 @@
     <!-- Description of an application permission that lets it control keyguard. -->
     <string name="permdesc_recovery">Allows an application to interact with the recovery system and system updates.</string>
 
-    <!-- Title of an application permission that lets it create media projection sessions. -->
-    <string name="permlab_createMediaProjection">Create media projection sessions</string>
-    <!-- Description of an application permission that lets it create media projection sessions. -->
-    <string name="permdesc_createMediaProjection">Allows an application to create media projection sessions. These sessions can provide applications the ability to capture display and audio contents. Should never be needed by normal apps.</string>
+    <!-- Title of an application permission that lets it manage media projection sessions. -->
+    <string name="permlab_manageMediaProjection">Manage media projection sessions</string>
+    <!-- Description of an application permission that lets it manage media projection sessions. -->
+    <string name="permdesc_manageMediaProjection">Allows an application to manage media projection sessions. These sessions can provide applications the ability to capture display and audio contents. Should never be needed by normal apps.</string>
 
     <!-- Title of an application permission that lets it read install sessions. -->
     <string name="permlab_readInstallSessions">Read install sessions</string>
@@ -3964,9 +3966,9 @@
     <string name="permission_request_notification_with_subtitle">Permission requested\nfor account <xliff:g id="account" example="foo@gmail.com">%s</xliff:g>.</string>
 
     <!-- Message to show when an intent automatically switches users into the personal profile. -->
-    <string name="forward_intent_to_owner">You\'re using this app in your personal space</string>
+    <string name="forward_intent_to_owner">You\'re using this app outside of your work profile</string>
     <!-- Message to show when an intent automatically switches users into a work profile. -->
-    <string name="forward_intent_to_work">You\'re using this app in your work space</string>
+    <string name="forward_intent_to_work">You\'re using this app in your work profile</string>
 
     <!-- Label to show for a service that is running because it is an input method. -->
     <string name="input_method_binding_label">Input method</string>
@@ -4148,10 +4150,6 @@
     <string name="time_picker_increment_set_pm_button">Set PM</string>
     <!-- Description of the button to decrease the TimePicker's set AM value. [CHAR LIMIT=NONE] -->
     <string name="time_picker_decrement_set_am_button">Set AM</string>
-    <!-- Label for the TimePicker's PM button. [CHAR LIMIT=2] -->
-    <string name="time_picker_pm_label">PM</string>
-    <!-- Label for the TimePicker's AM button. [CHAR LIMIT=2] -->
-    <string name="time_picker_am_label">AM</string>
 
     <!-- DatePicker - accessibility support -->
     <!-- Description of the button to increase the DatePicker's month value. [CHAR LIMIT=NONE] -->
@@ -4245,15 +4243,15 @@
     <string name="data_usage_warning_body">Touch to view usage and settings.</string>
 
     <!-- Notification title when 2G-3G data usage has exceeded limit threshold, and has been disabled. [CHAR LIMIT=32] -->
-    <string name="data_usage_3g_limit_title">2G-3G data is off</string>
+    <string name="data_usage_3g_limit_title">2G-3G data limit reached</string>
     <!-- Notification title when 4G data usage has exceeded limit threshold, and has been disabled. [CHAR LIMIT=32] -->
-    <string name="data_usage_4g_limit_title">4G data is off</string>
+    <string name="data_usage_4g_limit_title">4G data limit reached</string>
     <!-- Notification title when mobile data usage has exceeded limit threshold, and has been disabled. [CHAR LIMIT=32] -->
-    <string name="data_usage_mobile_limit_title">Cellular data is off</string>
+    <string name="data_usage_mobile_limit_title">Cellular data limit reached</string>
     <!-- Notification title when Wi-Fi data usage has exceeded limit threshold, and has been disabled. [CHAR LIMIT=32] -->
-    <string name="data_usage_wifi_limit_title">Wi-Fi data is off</string>
+    <string name="data_usage_wifi_limit_title">Wi-Fi data limit reached</string>
     <!-- Notification body when data usage has exceeded limit threshold, and has been disabled. [CHAR LIMIT=32] -->
-    <string name="data_usage_limit_body">Limit reached</string>
+    <string name="data_usage_limit_body">Data paused for rest of cycle</string>
 
     <!-- Notification title when 2G-3G data usage has exceeded limit threshold. [CHAR LIMIT=32] -->
     <string name="data_usage_3g_limit_snoozed_title">2G-3G data limit exceeded</string>
@@ -4331,7 +4329,7 @@
 
     <!-- Text for the toast that is shown when the user clicks on a launcher that
          doesn't support the work profile. [CHAR LIMIT=100] -->
-    <string name="activity_resolver_work_profiles_support">%1$s doesn\'t support work profile.</string>
+    <string name="activity_resolver_work_profiles_support">%1$s doesn\'t support work profile</string>
 
     <!-- Name of the default audio route for tablets when nothing
          is connected to a headphone or other wired audio output jack. [CHAR LIMIT=50] -->
@@ -4549,6 +4547,8 @@
     <string name="enable_accessibility_canceled">Accessibility canceled.</string>
     <!-- Text spoken when the current user is switched if accessibility is enabled. [CHAR LIMIT=none] -->
     <string name="user_switched">Current user <xliff:g id="name" example="Bob">%1$s</xliff:g>.</string>
+    <!-- Message shown when switching to a user [CHAR LIMIT=none] -->
+    <string name="user_switching_message">Switching to <xliff:g id="name" example="Bob">%1$s</xliff:g>\u2026</string>
     <!-- Default name of the owner user [CHAR LIMIT=20] -->
     <string name="owner_name" msgid="3879126011135546571">Owner</string>
     <!-- Error message title [CHAR LIMIT=35] -->
@@ -4827,7 +4827,7 @@
     <string name="deleted_key"><xliff:g id="key" example="4">%1$s</xliff:g> deleted</string>
 
     <!--
-        Used to wrap a label for content description for a managed profile, e.g. "Work Email" instead
+        Used to wrap a label for content description for a work profile, e.g. "Work Email" instead
         of email when there are two email apps.
         [CHAR LIMIT=20]
      -->
@@ -4865,671 +4865,31 @@
     <!-- Exting lock-to-app indication. -->
     <string name="lock_to_app_exit">Screen unpinned</string>
 
-    <!-- Lock-to-app checkbox for lock on exit -->
-    <string name="lock_to_app_use_screen_lock">Ask for %1$s before unpinning</string>
-
     <!-- Lock-to-app unlock pin string -->
-    <string name="lock_to_app_unlock_pin">PIN</string>
+    <string name="lock_to_app_unlock_pin">Ask for PIN before unpinning</string>
     <!-- Lock-to-app unlock pattern string -->
-    <string name="lock_to_app_unlock_pattern">unlock pattern</string>
+    <string name="lock_to_app_unlock_pattern">Ask for unlock pattern before unpinning</string>
     <!-- Lock-to-app unlock password string -->
-    <string name="lock_to_app_unlock_password">password</string>
-
-    <!-- Range specific TV content rating system strings for AM TV -->
-    <string name="display_name_amtvrs" translatable="false">AM-TV-RS</string>
-    <string name="description_amtvrs" translatable="false">Range specific TV content rating system strings for Armenia</string>
-    <string name="display_name_amtvrs_y" translatable="false">Y</string>
-    <string name="display_name_amtvrs_y7" translatable="false">Y7</string>
-    <string name="display_name_amtvrs_ga" translatable="false">GA</string>
-    <string name="display_name_amtvrs_tw" translatable="false">TW</string>
-    <string name="display_name_amtvrs_t" translatable="false">T</string>
-    <string name="display_name_amtvrs_a" translatable="false">A</string>
-    <string name="description_amtvrs_y" translatable="false">Suitable for ages 2-11</string>
-    <string name="description_amtvrs_y7" translatable="false">Suitable for ages 7-16</string>
-    <string name="description_amtvrs_ga" translatable="false">Suitable for general audiences</string>
-    <string name="description_amtvrs_tw" translatable="false">Suitable for teens ages 9 and up</string>
-    <string name="description_amtvrs_t" translatable="false">Suitable for teens ages 12 and up</string>
-    <string name="description_amtvrs_a" translatable="false">Suitable only for adults ages 18 and up</string>
-
-    <!-- Age specific TV content rating system strings for AM TV -->
-    <string name="display_name_amtvas" translatable="false">AM-TV-AS</string>
-    <string name="description_amtvas" translatable="false">Age specific TV content rating system strings for Armenia</string>
-    <string name="display_name_amtvas_ec" translatable="false">EC</string>
-    <string name="display_name_amtvas_e" translatable="false">E</string>
-    <string name="display_name_amtvas_e9" translatable="false">E9</string>
-    <string name="display_name_amtvas_t" translatable="false">T</string>
-    <string name="display_name_amtvas_m" translatable="false">M</string>
-    <string name="display_name_amtvas_ao" translatable="false">AO</string>
-    <string name="description_amtvas_ec" translatable="false">Suitable for ages 2 and up</string>
-    <string name="description_amtvas_e" translatable="false">Suitable for ages 5 and up</string>
-    <string name="description_amtvas_e9" translatable="false">Suitable for ages 9 and up</string>
-    <string name="description_amtvas_t" translatable="false">Suitable for ages 12 and up</string>
-    <string name="description_amtvas_m" translatable="false">Suitable for ages 16 and up</string>
-    <string name="description_amtvas_ao" translatable="false">Suitable for ages 17 and up</string>
-
-    <!-- TV content rating system strings for AR TV -->
-    <string name="display_name_artv" translatable="false">AR-TV</string>
-    <string name="display_name_artv_all" translatable="false">Apto para todo público</string>
-    <string name="display_name_artv_13" translatable="false">Apto para mayores de 13 años</string>
-    <string name="display_name_artv_16" translatable="false">Apto para mayores de 16 años</string>
-    <string name="display_name_artv_18" translatable="false">Apto para mayores de 18 años</string>
-    <string name="description_artv_all" translatable="false">Suitable for all audiences. Programs may contain mild violence, language and mature situations</string>
-    <string name="description_artv_13" translatable="false">Suitable for ages 13 and up. Programs may contain mild to moderate language and mild violence and sexual references</string>
-    <string name="description_artv_16" translatable="false">Suitable for ages 16 and up. Programs may contain more intensive violence and coarse language, partial nudity and moderate sexual references</string>
-    <string name="description_artv_18" translatable="false">Suitable for mature audiences only. Programs contain strong violence, coarse language and explicit sexual references</string>
-
-    <!-- TV content rating system strings for AU TV -->
-    <string name="display_name_autv" translatable="false">Australian TV Classification</string>
-    <string name="display_name_autv_ctc" translatable="false">CTC</string>
-    <string name="display_name_autv_g" translatable="false">G</string>
-    <string name="display_name_autv_pg" translatable="false">PG</string>
-    <string name="display_name_autv_m" translatable="false">M</string>
-    <string name="display_name_autv_ma15" translatable="false">MA 15+</string>
-    <string name="display_name_autv_r18" translatable="false">R 18+</string>
-    <string name="display_name_autv_x18" translatable="false">X 18+</string>
-    <string name="description_autv_ctc" translatable="false">This has advertising approval, but is not yet classified</string>
-    <string name="description_autv_g" translatable="false">The content is very mild in impact, and suitable for everyone</string>
-    <string name="description_autv_pg" translatable="false">The content is mild in impact, but it may contain content that children find confusing or upsetting and may require the guidance or parents and guardians</string>
-    <string name="description_autv_m" translatable="false">The content is moderate in impact, and it is recommended for teenagers aged 15 years and over</string>
-    <string name="description_autv_ma15" translatable="false">The content is strong in impact, and it is legally restricted to persons 15 years and over</string>
-    <string name="description_autv_r18" translatable="false">The content is high in impact, and it is restricted to adults</string>
-    <string name="description_autv_x18" translatable="false">The content is restricted to adults. This classification is a special and legally restricted category which contains only sexually explicit content</string>
-
-    <!-- TV content rating system strings for BG TV -->
-    <string name="display_name_bgtv" translatable="false">BG-TV</string>
-    <string name="display_name_bgtv_a" translatable="false">A</string>
-    <string name="display_name_bgtv_b" translatable="false">B</string>
-    <string name="display_name_bgtv_c" translatable="false">C</string>
-    <string name="display_name_bgtv_d" translatable="false">D</string>
-    <string name="display_name_bgtv_x" translatable="false">X</string>
-    <string name="description_bgtv_a" translatable="false">Recommended to children. When the film confirms the ideals of humanism or popularizes the national and world cultures or contributes to upbringing children</string>
-    <string name="description_bgtv_b" translatable="false">No restrictive recommendations from the Committee. When the film is in no way contrary to the universal rules of morality in this country, has no restrictive recommendations from the Committee and does not fall in rating A</string>
-    <string name="description_bgtv_c" translatable="false">No persons under the age of 12 are admitted unless accompanied by an adult. When the film contains certain erotic scenes or scenes with drinking, taking drugs or stimulants or a few scenes of violence</string>
-    <string name="description_bgtv_d" translatable="false">No persons under the age of 16 are admitted. When the film contains quite a number of erotic scenes or scenes with drinking, taking drugs or stimulants or a considerable number of scenes showing violence</string>
-    <string name="description_bgtv_x" translatable="false">No persons under the age of 18 are admitted. When the film is naturalistically erotic or shows violence in an ostentatious manner</string>
-
-    <!-- TV content rating system strings for BR TV -->
-    <string name="display_name_brtv" translatable="false">Brazil Content Rating</string>
-    <string name="display_name_brtv_l" translatable="false">Livre</string>
-    <string name="display_name_brtv_10" translatable="false">10 anos</string>
-    <string name="display_name_brtv_12" translatable="false">12 anos</string>
-    <string name="display_name_brtv_14" translatable="false">14 anos</string>
-    <string name="display_name_brtv_16" translatable="false">16 anos</string>
-    <string name="display_name_brtv_18" translatable="false">18 anos</string>
-    <string name="description_brtv_l" translatable="false">Content is suitable for all audiences</string>
-    <string name="description_brtv_10" translatable="false">Content suitable for viewers over the age of 10</string>
-    <string name="description_brtv_12" translatable="false">Content suitable for viewers over the age of 12</string>
-    <string name="description_brtv_14" translatable="false">Content suitable for viewers over the age of 14</string>
-    <string name="description_brtv_16" translatable="false">Content suitable for viewers over the age of 16</string>
-    <string name="description_brtv_18" translatable="false">Content suitable for viewers over the age of 18</string>
-
-    <!-- TV content rating system strings for CA TV -->
-    <string name="display_name_catv" translatable="false">Canadian TV Classification System</string>
-    <string name="display_name_catv_exempt" translatable="false">Exempt</string>
-    <string name="display_name_catv_c" translatable="false">C</string>
-    <string name="display_name_catv_c8" translatable="false">C8</string>
-    <string name="display_name_catv_g" translatable="false">G</string>
-    <string name="display_name_catv_pg" translatable="false">PG</string>
-    <string name="display_name_catv_14" translatable="false">14+</string>
-    <string name="display_name_catv_18" translatable="false">18+</string>
-    <string name="description_catv_exempt" translatable="false">Shows which are exempt from ratings (such as news and sports programming) will not display an on-screen rating at all</string>
-    <string name="description_catv_c" translatable="false">Programming suitable for children ages of 2-7 years. No profanity or sexual content of any level allowed. Contains little violence</string>
-    <string name="description_catv_c8" translatable="false">Suitable for children ages 8+. Low level violence and fantasy horror is allowed. No foul language is allowed, but occasional "socially offensive and discriminatory" language is allowed if in the context of the story. No sexual content of any level allowed</string>
-    <string name="description_catv_g" translatable="false">Suitable for general audiences. Programming suitable for the entire family with mild violence, and mild profanity and/or censored language</string>
-    <string name="description_catv_pg" translatable="false">Parental guidance. Moderate violence and moderate profanity is allowed, as is brief nudity and sexual references if important to the context of the story</string>
-    <string name="description_catv_14" translatable="false">Programming intended for viewers ages 14 and older. May contain strong violence and strong profanity, and depictions of sexual activity as long as they are within the context of a story</string>
-    <string name="description_catv_18" translatable="false">Programming intended for viewers ages 18 and older. May contain explicit violence and sexual activity</string>
-
-    <!-- TV content rating system strings for CH TV -->
-    <string name="display_name_chtv" translatable="false">CH-TV</string>
-    <string name="display_name_chtv_all" translatable="false">All ages</string>
-    <string name="display_name_chtv_red" translatable="false">Red rectangle</string>
-    <string name="description_chtv_all" translatable="false">This program is suitable for all ages</string>
-    <string name="description_chtv_red" translatable="false">This program contains scenes that may hurt sensitive people, therefore the red symbol will be displayed</string>
-
-    <!-- TV content rating system strings for CL TV -->
-    <string name="display_name_cltv" translatable="false">CL-TV</string>
-    <string name="display_name_cltv_i" translatable="false">I</string>
-    <string name="display_name_cltv_i7" translatable="false">I7</string>
-    <string name="display_name_cltv_i10" translatable="false">I10</string>
-    <string name="display_name_cltv_i12" translatable="false">I12</string>
-    <string name="display_name_cltv_f" translatable="false">F</string>
-    <string name="display_name_cltv_r" translatable="false">R</string>
-    <string name="display_name_cltv_a" translatable="false">A</string>
-    <string name="description_cltv_i" translatable="false">Programs suitable for all children</string>
-    <string name="description_cltv_i7" translatable="false">Programs recommended for children ages 7 or older</string>
-    <string name="description_cltv_i10" translatable="false">Programs recommended for children ages 10 or older</string>
-    <string name="description_cltv_i12" translatable="false">Programs recommended for children and teens ages 12 or older</string>
-    <string name="description_cltv_f" translatable="false">Programs suitable for a general audience, with content appropriate for all ages</string>
-    <string name="description_cltv_r" translatable="false">Programs may content not suitable for children not accompanied by an adult</string>
-    <string name="description_cltv_a" translatable="false">Programs suitable for adult audiences only (ages 18 or older), may contain coarse language, and sexual or explicit situations</string>
-
-    <!-- TV content rating system strings for DE TV -->
-    <string name="display_name_detv" translatable="false">DE-TV</string>
-    <string name="display_name_detv_all" translatable="false">ab 0 Jahren</string>
-    <string name="display_name_detv_12" translatable="false">ab 12 Jahren</string>
-    <string name="display_name_detv_16" translatable="false">ab 16 Jahren</string>
-    <string name="display_name_detv_18" translatable="false">ab 18 Jahren</string>
-    <string name="description_detv_all" translatable="false">The program is suitable for all ages</string>
-    <string name="description_detv_12" translatable="false">The program is not suitable for viewers under the age of 12</string>
-    <string name="description_detv_16" translatable="false">The program is not suitable for viewers under the age of 16</string>
-    <string name="description_detv_18" translatable="false">The program is not suitable for viewers under the age of 18</string>
-
-    <!-- TV content rating system strings for DK TV -->
-    <string name="display_name_dktv" translatable="false">DK-TV</string>
-    <string name="display_name_dktv_g" translatable="false">Green symbol</string>
-    <string name="display_name_dktv_y" translatable="false">Yellow symbol</string>
-    <string name="display_name_dktv_r" translatable="false">Red symbol</string>
-    <string name="display_name_dktv_b" translatable="false">Blue symbol</string>
-    <string name="description_dktv_g" translatable="false">programs suitable for all ages</string>
-    <string name="description_dktv_y" translatable="false">programs suitable children accompanied by an adult</string>
-    <string name="description_dktv_r" translatable="false">programs containing material with more intensive content </string>
-    <string name="description_dktv_b" translatable="false">programs containing explicit content and strictly for adults only</string>
-
-    <!-- TV content rating system strings for ES TV -->
-    <string name="display_name_estv" translatable="false">ES-TV</string>
-    <string name="display_name_estv_tp" translatable="false">TP</string>
-    <string name="display_name_estv_i" translatable="false">I</string>
-    <string name="display_name_estv_7" translatable="false">+7</string>
-    <string name="display_name_estv_7i" translatable="false">7I</string>
-    <string name="display_name_estv_12" translatable="false">12</string>
-    <string name="display_name_estv_16" translatable="false">16</string>
-    <string name="display_name_estv_18" translatable="false">18</string>
-    <string name="description_estv_tp" translatable="false">Recommended for all ages</string>
-    <string name="description_estv_i" translatable="false">Specially recommended for preschoolers and kids</string>
-    <string name="description_estv_7" translatable="false">Recommended for people older than 7 years old</string>
-    <string name="description_estv_7i" translatable="false">Recommended for kids older than 7 years old</string>
-    <string name="description_estv_12" translatable="false">Recommended for people older than 12 years old</string>
-    <string name="description_estv_16" translatable="false">Recommended for people older than 16 years old</string>
-    <string name="description_estv_18" translatable="false">Recommended for people older than 18 years old</string>
-
-    <!-- TV content rating system strings for FI TV -->
-    <string name="display_name_fitv" translatable="false">FI-TV</string>
-    <string name="display_name_fitv_s" translatable="false">S</string>
-    <string name="display_name_fitv_k7" translatable="false">K7</string>
-    <string name="display_name_fitv_k12" translatable="false">K12</string>
-    <string name="display_name_fitv_k16" translatable="false">K16</string>
-    <string name="display_name_fitv_k18" translatable="false">K18</string>
-    <string name="description_fitv_s" translatable="false">Allowed at all times</string>
-    <string name="description_fitv_k7" translatable="false">Not recommended for children under 7</string>
-    <string name="description_fitv_k12" translatable="false">Not recommended for children under 12</string>
-    <string name="description_fitv_k16" translatable="false">Not recommended for children under 16</string>
-    <string name="description_fitv_k18" translatable="false">Not recommended for children under 18</string>
-
-    <!-- TV content rating system strings for FR TV -->
-    <string name="display_name_frtv" translatable="false">FR-TV</string>
-    <string name="display_name_frtv_all" translatable="false">Les programmes tous publics</string>
-    <string name="display_name_frtv_10" translatable="false">Déconseillé aux -10 ans</string>
-    <string name="display_name_frtv_12" translatable="false">Déconseillé aux -12 ans</string>
-    <string name="display_name_frtv_16" translatable="false">Déconseillé aux -16 ans</string>
-    <string name="display_name_frtv_18" translatable="false">Déconseillé aux -18 ans</string>
-    <string name="description_frtv_all" translatable="false">Appropriate for all ages</string>
-    <string name="description_frtv_10" translatable="false">Not recommended for children under 10</string>
-    <string name="description_frtv_12" translatable="false">Not recommended for children under 12</string>
-    <string name="description_frtv_16" translatable="false">Not recommended for children under 16</string>
-    <string name="description_frtv_18" translatable="false">Not recommended for persons under 18</string>
-
-    <!-- TV content rating system strings for GR TV -->
-    <string name="display_name_grtv" translatable="false">GR-TV</string>
-    <string name="display_name_grtv_all" translatable="false">White rhombus in green background</string>
-    <string name="display_name_grtv_10" translatable="false">White circle in blue background</string>
-    <string name="display_name_grtv_12" translatable="false">White triangle in orange background</string>
-    <string name="display_name_grtv_15" translatable="false">White square in purple background</string>
-    <string name="display_name_grtv_18" translatable="false">White X in red background</string>
-    <string name="description_grtv_all" translatable="false">Suitable for all ages</string>
-    <string name="description_grtv_10" translatable="false">Parental consent suggested</string>
-    <string name="description_grtv_12" translatable="false">Required parental consent</string>
-    <string name="description_grtv_15" translatable="false">Suitable for minors over the age of 15</string>
-    <string name="description_grtv_18" translatable="false">Suitable only for adults profanity before midnight is punishable by fine, except when used in the context of the program</string>
-
-    <!-- TV content rating system strings for HK TV -->
-    <string name="display_name_hktv" translatable="false">HK-TV</string>
-    <string name="display_name_hktv_g" translatable="false">G</string>
-    <string name="display_name_hktv_pg" translatable="false">PG</string>
-    <string name="display_name_hktv_m" translatable="false">M</string>
-    <string name="description_hktv_g" translatable="false">For general audiences</string>
-    <string name="description_hktv_pg" translatable="false">Programs are unsuitable for children, parental guidance is recommended</string>
-    <string name="description_hktv_m" translatable="false">Programs are recommended only for adult viewers above the age of 18</string>
-
-    <!-- TV content rating system strings for HU TV -->
-    <string name="display_name_hutv" translatable="false">HU-TV</string>
-    <string name="display_name_hutv_u" translatable="false">Unrated</string>
-    <string name="display_name_hutv_cf" translatable="false">Children Friendly</string>
-    <string name="display_name_hutv_6" translatable="false">6</string>
-    <string name="display_name_hutv_12" translatable="false">12</string>
-    <string name="display_name_hutv_16" translatable="false">16</string>
-    <string name="display_name_hutv_18" translatable="false">18</string>
-    <string name="description_hutv_u" translatable="false">Programs can be viewed by any age</string>
-    <string name="description_hutv_cf" translatable="false">Programs recommended for children. It is an optional rating, there is no obligation for broadcasters to indicate it</string>
-    <string name="description_hutv_6" translatable="false">Programs not recommended for children below the age of 6, may not contain any violence or sexual content</string>
-    <string name="description_hutv_12" translatable="false">Programs not recommended for children below the age of 12, may contain light sexual content or explicit language</string>
-    <string name="description_hutv_16" translatable="false">Programs not recommended for teens and children below the age of 16, may contain more intensive violence and sexual content</string>
-    <string name="description_hutv_18" translatable="false">The program is recommended only for adult viewers (for ages 18 and up), may contain explicit violence and explicit sexual content</string>
-
-    <!-- TV content rating system strings for ID TV -->
-    <string name="display_name_idtv" translatable="false">ID-TV</string>
-    <string name="display_name_idtv_p" translatable="false">P</string>
-    <string name="display_name_idtv_a" translatable="false">A</string>
-    <string name="display_name_idtv_a_bo" translatable="false">A-BO</string>
-    <string name="display_name_idtv_su" translatable="false">SU</string>
-    <string name="display_name_idtv_bo" translatable="false">BO</string>
-    <string name="display_name_idtv_r" translatable="false">R</string>
-    <string name="display_name_idtv_r_bo" translatable="false">R-BO</string>
-    <string name="display_name_idtv_d" translatable="false">D</string>
-    <string name="description_idtv_p" translatable="false">Suitable for children from ages 2 through 11</string>
-    <string name="description_idtv_a" translatable="false">Suitable for teens and children from ages 7 through 16</string>
-    <string name="description_idtv_a_bo" translatable="false">Suitable for children ages 5 through 10, with parental guidance or permission</string>
-    <string name="description_idtv_su" translatable="false">Suitable for general audiences</string>
-    <string name="description_idtv_bo" translatable="false">Parental guidance suggested for ages 5 and under</string>
-    <string name="description_idtv_r" translatable="false">Suitable for teens from ages 13 through 17</string>
-    <string name="description_idtv_r_bo" translatable="false">Suitable for teens with parental guidance or permission</string>
-    <string name="description_idtv_d" translatable="false">Suitable for viewers over 18 and older only</string>
-
-    <!-- TV content rating system strings for IE TV -->
-    <string name="display_name_ietv" translatable="false">RTÉ programme classifications</string>
-    <string name="display_name_ietv_ga" translatable="false">GA</string>
-    <string name="display_name_ietv_ch" translatable="false">Ch</string>
-    <string name="display_name_ietv_ya" translatable="false">YA</string>
-    <string name="display_name_ietv_ps" translatable="false">PS</string>
-    <string name="display_name_ietv_ma" translatable="false">MA</string>
-    <string name="description_ietv_ga" translatable="false">Suitable for all ages</string>
-    <string name="description_ietv_ch" translatable="false">Suitable for children ages 5 to 10, may contain comedic violence or action fantasy violence</string>
-    <string name="description_ietv_ya" translatable="false">Suitable for adolescent audiences, may contain thematic elements that would appeal to teenagers</string>
-    <string name="description_ietv_ps" translatable="false">Suitable for more mature viewers, more mature themes may be present</string>
-    <string name="description_ietv_ma" translatable="false">Most restrictive classification, allowing for heavy subject matter and coarse language</string>
-
-    <!-- TV content rating system strings for IL TV -->
-    <string name="display_name_iltv" translatable="false">IL-TV</string>
-    <string name="display_name_iltv_g" translatable="false">G</string>
-    <string name="display_name_iltv_12" translatable="false">12+</string>
-    <string name="display_name_iltv_15" translatable="false">15+</string>
-    <string name="display_name_iltv_18" translatable="false">18+</string>
-    <string name="display_name_iltv_e" translatable="false">E</string>
-    <string name="description_iltv_g" translatable="false">General audience; anyone, regardless of age, can view the program, usually news and children\'s programming</string>
-    <string name="description_iltv_12" translatable="false">Suitable for teens and children ages 12 and over, no child under 12 are permitted to view the program</string>
-    <string name="description_iltv_15" translatable="false">Suitable for teens ages 15 and over, no child under 15 may view the programme</string>
-    <string name="description_iltv_18" translatable="false">Suitable for adults only, no minors may view the programme</string>
-    <string name="description_iltv_e" translatable="false">Exempt from classification</string>
-
-    <!-- TV content rating system strings for IN TV -->
-    <string name="display_name_intv" translatable="false">IN-TV</string>
-    <string name="display_name_intv_u" translatable="false">U</string>
-    <string name="display_name_intv_u/a" translatable="false">U/A</string>
-    <string name="display_name_intv_a" translatable="false">A</string>
-    <string name="display_name_intv_s" translatable="false">S</string>
-    <string name="description_intv_u" translatable="false">Unrestricted public exhibition</string>
-    <string name="description_intv_u/a" translatable="false">Unrestricted public exhibition, but with a caution regarding parental guidance to those under 12 years of age</string>
-    <string name="description_intv_a" translatable="false">Public exhibition restricted to adults 18 years of age and older only</string>
-    <string name="description_intv_s" translatable="false">Public exhibition restricted to members of any profession or any class of persons</string>
-
-    <!-- TV content rating system strings for IS TV -->
-    <string name="display_name_istv" translatable="false">IS-TV</string>
-    <string name="display_name_istv_l" translatable="false">L</string>
-    <string name="display_name_istv_7" translatable="false">7</string>
-    <string name="display_name_istv_10" translatable="false">10</string>
-    <string name="display_name_istv_12" translatable="false">12</string>
-    <string name="display_name_istv_14" translatable="false">14</string>
-    <string name="display_name_istv_16" translatable="false">16</string>
-    <string name="display_name_istv_18" translatable="false">18</string>
-    <string name="description_istv_l" translatable="false">Programs suitable for all ages</string>
-    <string name="description_istv_7" translatable="false">Programs suitable for ages 7 and older</string>
-    <string name="description_istv_10" translatable="false">Programs suitable for ages 10 and older</string>
-    <string name="description_istv_12" translatable="false">Programs suitable for ages 12 and older</string>
-    <string name="description_istv_14" translatable="false">Programs suitable for ages 14 and older</string>
-    <string name="description_istv_16" translatable="false">Programs suitable for ages 16 and older</string>
-    <string name="description_istv_18" translatable="false">Programs suitable for ages 18 and older</string>
-
-    <!-- TV content rating system strings for KR TV -->
-    <string name="display_name_krtv" translatable="false">KR-TV</string>
-    <string name="display_name_krtv_all" translatable="false">모든연령시청가</string>
-    <string name="display_name_krtv_7" translatable="false">7세이상시청가</string>
-    <string name="display_name_krtv_12" translatable="false">12세이상시청가</string>
-    <string name="display_name_krtv_15" translatable="false">15세이상시청가</string>
-    <string name="display_name_krtv_19" translatable="false">19세이상시청가</string>
-    <string name="description_krtv_all" translatable="false">Appropriate for all ages</string>
-    <string name="description_krtv_7" translatable="false">May contain material inappropriate for children younger than 7, and parental discretion should be used</string>
-    <string name="description_krtv_12" translatable="false">May deemed inappropriate for those younger than 12, and parental discretion should be used</string>
-    <string name="description_krtv_15" translatable="false">May be inappropriate for children under 15, and that parental discretion should be used</string>
-    <string name="description_krtv_19" translatable="false">For adults only</string>
-
-    <!-- TV content rating system strings for MV TV -->
-    <string name="display_name_mvtv" translatable="false">MV-TV</string>
-    <string name="display_name_mvtv_y" translatable="false">Y</string>
-    <string name="display_name_mvtv_g" translatable="false">G</string>
-    <string name="display_name_mvtv_pg" translatable="false">PG</string>
-    <string name="display_name_mvtv_pg-12" translatable="false">PG-12</string>
-    <string name="display_name_mvtv_12" translatable="false">12+</string>
-    <string name="display_name_mvtv_15" translatable="false">15+</string>
-    <string name="display_name_mvtv_18" translatable="false">18+</string>
-    <string name="display_name_mvtv_21" translatable="false">21+</string>
-    <string name="display_name_mvtv_x" translatable="false">X</string>
-    <string name="description_mvtv_y" translatable="false">Young children</string>
-    <string name="description_mvtv_g" translatable="false">General viewing for all ages</string>
-    <string name="description_mvtv_pg" translatable="false">Parental guidance is required unaccompanied children</string>
-    <string name="description_mvtv_pg-12" translatable="false">Parental guidance is required for children under the age of 12</string>
-    <string name="description_mvtv_12" translatable="false">Teens and children aged 12 and older may watch, otherwise restricted</string>
-    <string name="description_mvtv_15" translatable="false">Restricted to viewers aged 15 and above</string>
-    <string name="description_mvtv_18" translatable="false">Restricted to viewers aged 18 and above</string>
-    <string name="description_mvtv_21" translatable="false">Restricted to viewers aged 21 and above</string>
-    <string name="description_mvtv_x" translatable="false">Most restrictive classification, only adults ages 25 and above may view</string>
-
-    <!-- TV content rating system strings for MX TV -->
-    <string name="display_name_mxtv" translatable="false">MX-TV</string>
-    <string name="display_name_mxtv_a" translatable="false">A</string>
-    <string name="display_name_mxtv_b" translatable="false">B</string>
-    <string name="display_name_mxtv_b-15" translatable="false">B-15</string>
-    <string name="display_name_mxtv_c" translatable="false">C</string>
-    <string name="display_name_mxtv_d" translatable="false">D</string>
-    <string name="display_name_mxtv_rc" translatable="false">RC</string>
-    <string name="description_mxtv_a" translatable="false">Appropriate for all ages, parental guidance is recommended for children under 7 years</string>
-    <string name="description_mxtv_b" translatable="false">Designed for ages 12 and older, may contain some sexual situations, mild violence, and mild language</string>
-    <string name="description_mxtv_b-15" translatable="false">Designed for ages 15 and up, slightly more intensive than the \'A\' and \'B\' ratings</string>
-    <string name="description_mxtv_c" translatable="false">Designed to be viewed by adults aged 18 or older only, generally more intensive content </string>
-    <string name="description_mxtv_d" translatable="false">Designed to be viewed only by mature adults (at least 21 years of age and over), contains extreme content matter</string>
-    <string name="description_mxtv_rc" translatable="false">Banned from public television in Mexico</string>
-
-    <!-- TV content rating system strings for MY TV -->
-    <string name="display_name_mytv" translatable="false">MY-TV</string>
-    <string name="display_name_mytv_u" translatable="false">U</string>
-    <string name="display_name_mytv_p13" translatable="false">P13</string>
-    <string name="display_name_mytv_18" translatable="false">18</string>
-    <string name="description_mytv_u" translatable="false">General viewing for all ages, can be broadcast anytime</string>
-    <string name="description_mytv_p13" translatable="false">For viewers ages 13 and above, children under 13 needs parental guidance, can be broadcast anytime, but some elements may only be broadcast at night</string>
-    <string name="description_mytv_18" translatable="false">For viewers ages 18 and above only</string>
-
-    <!-- TV content rating system strings for NL TV -->
-    <string name="display_name_nltv" translatable="false">NICAM</string>
-    <string name="display_name_nltv_v" translatable="false">Geweld</string>
-    <string name="display_name_nltv_f" translatable="false">Angst</string>
-    <string name="display_name_nltv_s" translatable="false">Seks</string>
-    <string name="display_name_nltv_d" translatable="false">Discriminatie</string>
-    <string name="display_name_nltv_da" translatable="false">Drugs- en/of alcoholmisbruik</string>
-    <string name="display_name_nltv_l" translatable="false">Grof taalgebruik</string>
-    <string name="display_name_nltv_al" translatable="false">Alle leeftijden</string>
-    <string name="display_name_nltv_6" translatable="false">Let op met kinderen tot 6 jaar</string>
-    <string name="display_name_nltv_9" translatable="false">Let op met kinderen tot 9 jaar</string>
-    <string name="display_name_nltv_12" translatable="false">Let op met kinderen tot 12 jaar</string>
-    <string name="display_name_nltv_16" translatable="false">Let op met kinderen tot 16 jaar</string>
-    <string name="description_nltv_v" translatable="false">Violence\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_f" translatable="false">Scary or Disturbing ContentViolence\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_s" translatable="false">Sexual Content\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_d" translatable="false">Discrimination\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_da" translatable="false">Drug and/or Alcohol abuse\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_l" translatable="false">Bad Language\nApplicable to NL_TV_AL, NL_TV_6, NL_TV_9, NL_TV_12, NL_TV_16</string>
-    <string name="description_nltv_al" translatable="false">All Ages</string>
-    <string name="description_nltv_6" translatable="false">Parental advisory for children under 6</string>
-    <string name="description_nltv_9" translatable="false">Parental advisory for children under 9</string>
-    <string name="description_nltv_12" translatable="false">Parental advisory for children under 12</string>
-    <string name="description_nltv_16" translatable="false">Parental advisory for children under 16</string>
-
-    <!-- TV content rating system strings for NZF(Free) TV -->
-    <string name="display_name_nzftv" translatable="false">NZ-Free-TV</string>
-    <string name="description_nzftv" translatable="false">TV content rating system for free-to-air channels in New Zealand</string>
-    <string name="display_name_nzftv_g" translatable="false">G</string>
-    <string name="display_name_nzftv_pgr" translatable="false">PGR</string>
-    <string name="display_name_nzftv_ao" translatable="false">AO</string>
-    <string name="description_nzftv_g" translatable="false">These exclude material likely to harm children under 14 and can screen at any time. Programmes may not necessarily be designed for younger viewers, but must not contain material likely to cause them undue distress or discomfort</string>
-    <string name="description_nzftv_pgr" translatable="false">Programmes more suited to more mature viewers. These are not necessarily unsuitable for children, but viewer discretion is advised, and parents and guardians are encouraged to supervise younger viewers</string>
-    <string name="description_nzftv_ao" translatable="false">Contain material of an adult nature handled in such a way that it is unsuitable for children</string>
-
-    <!-- TV content rating system strings for NZP(Pay) TV -->
-    <string name="display_name_nzptv" translatable="false">NZ-Pay-TV</string>
-    <string name="description_nzptv" translatable="false">TV content rating system for Pay TV channels in New Zealand</string>
-    <string name="display_name_nzptv_c" translatable="false">C</string>
-    <string name="display_name_nzptv_v" translatable="false">V</string>
-    <string name="display_name_nzptv_l" translatable="false">L</string>
-    <string name="display_name_nzptv_s" translatable="false">S</string>
-    <string name="display_name_nzptv_g" translatable="false">G</string>
-    <string name="display_name_nzptv_pg" translatable="false">PG</string>
-    <string name="display_name_nzptv_m" translatable="false">M</string>
-    <string name="display_name_nzptv_16" translatable="false">16</string>
-    <string name="display_name_nzptv_18" translatable="false">18</string>
-    <string name="description_nzptv_c" translatable="false">Content may offend\nApplicable to NZ_PTV_PG, NZ_PTV_M, NZ_PTV_16, NZ_PTV_18</string>
-    <string name="description_nzptv_v" translatable="false">Violence\nApplicable to NZ_PTV_PG, NZ_PTV_M, NZ_PTV_16, NZ_PTV_18</string>
-    <string name="description_nzptv_l" translatable="false">Language\nApplicable to NZ_PTV_PG, NZ_PTV_M, NZ_PTV_16, NZ_PTV_18</string>
-    <string name="description_nzptv_s" translatable="false">Sexual content\nApplicable to NZ_PTV_PG, NZ_PTV_M, NZ_PTV_16, NZ_PTV_18</string>
-    <string name="description_nzptv_g" translatable="false">suitable for general audiences</string>
-    <string name="description_nzptv_pg" translatable="false">Parental guidance recommended for under 10</string>
-    <string name="description_nzptv_m" translatable="false">Suitable for mature audiences 13 and up</string>
-    <string name="description_nzptv_16" translatable="false">Suitable for viewers 16 and up</string>
-    <string name="description_nzptv_18" translatable="false">Suitable for viewers 18 and up</string>
-
-    <!-- TV content rating system strings for PE TV -->
-    <string name="display_name_petv" translatable="false">PE-TV</string>
-    <string name="description_petv" translatable="false">TV content rating system for some Peruvian channels in Peru</string>
-    <string name="display_name_petv_a" translatable="false">Apt</string>
-    <string name="display_name_petv_14" translatable="false">14</string>
-    <string name="display_name_petv_18" translatable="false">18</string>
-    <string name="description_petv_a" translatable="false">Suitable for all audiences</string>
-    <string name="description_petv_14" translatable="false">Suitable for people aged 14 and above only</string>
-    <string name="description_petv_18" translatable="false">Suitable for people aged 18 and above only</string>
-
-    <!-- TV content rating system strings for America TV in PE -->
-    <string name="display_name_peatv" translatable="false">PE-ATV</string>
-    <string name="description_peatv" translatable="false">TV content rating system for America Television in Peru that uses its own rating system</string>
-    <string name="display_name_peatv_gp" translatable="false">GP</string>
-    <string name="display_name_peatv_pg" translatable="false">PG</string>
-    <string name="display_name_peatv_14" translatable="false">TV-14</string>
-    <string name="display_name_peatv_18" translatable="false">TV-18</string>
-    <string name="description_peatv_gp" translatable="false">General audience</string>
-    <string name="description_peatv_pg" translatable="false">Parental guidance required for under 6</string>
-    <string name="description_peatv_14" translatable="false">Suitable for people aged 14 and above only</string>
-    <string name="description_peatv_18" translatable="false">Suitable for people aged 18 and above only</string>
-
-    <!-- TV content rating system strings for PH TV -->
-    <string name="display_name_phtv" translatable="false">MTRCB</string>
-    <string name="display_name_phtv_g" translatable="false">G</string>
-    <string name="display_name_phtv_pg" translatable="false">PG</string>
-    <string name="display_name_phtv_spg" translatable="false">SPG</string>
-    <string name="description_phtv_g" translatable="false">Suitable for all public viewers</string>
-    <string name="description_phtv_pg" translatable="false">Programmes rated PG may contain scenes or other content that are unsuitable for children without the guidance of a parent</string>
-    <string name="description_phtv_spg" translatable="false">Contains mature themes or moderate to intense violence, which may be deemed unfit for children to watch without strict parental supervision</string>
-
-    <!-- TV content rating system strings for PL TV -->
-    <string name="display_name_pltv" translatable="false">PL-TV</string>
-    <string name="display_name_pltv_g" translatable="false">No age limit</string>
-    <string name="display_name_pltv_7" translatable="false">7</string>
-    <string name="display_name_pltv_12" translatable="false">12</string>
-    <string name="display_name_pltv_16" translatable="false">16</string>
-    <string name="display_name_pltv_18" translatable="false">18</string>
-    <string name="description_pltv_g" translatable="false">Positive or neutral view of the world, little to no violence, non-sexual love, and no sexual content</string>
-    <string name="description_pltv_7" translatable="false">Age 7 and above. May additionally contain some mild language, bloodless violence, and a more negative view of the world</string>
-    <string name="description_pltv_12" translatable="false">Age 12 and above. May contain some foul language, some violence, and some sexual content</string>
-    <string name="description_pltv_16" translatable="false">Age 16 and above. Deviant social behaviour, world filled with violence and sexuality, simplified picture of adulthood, display of physical force, especially in controversial social context, immoral behaviour without ethic dilemma, putting the blame on the victim, excessive concentration on material possessions</string>
-    <string name="description_pltv_18" translatable="false">Age 18 and above. One-sided display of the joys of adult life without showing responsibilities, social justification of violent behaviour, excessive vulgarity, use of racial slurs and social stereotypes, explicit sexual content, praise of aggression or vulgarity</string>
-
-    <!-- TV content rating system strings for PT TV -->
-    <string name="display_name_pttv" translatable="false">PT-TV</string>
-    <string name="display_name_pttv_t" translatable="false">Todos</string>
-    <string name="display_name_pttv_10" translatable="false">10</string>
-    <string name="display_name_pttv_12" translatable="false">12</string>
-    <string name="display_name_pttv_16" translatable="false">16</string>
-    <string name="description_pttv_t" translatable="false">Suitable for all</string>
-    <string name="description_pttv_10" translatable="false">May not be suitable for children under 10, parental guidance advised</string>
-    <string name="description_pttv_12" translatable="false">May not be suitable for children under 12, parental guidance advised</string>
-    <string name="description_pttv_16" translatable="false">Not suitable for children under 16</string>
-
-    <!-- TV content rating system strings for RO TV -->
-    <string name="display_name_rotv" translatable="false">RO-TV</string>
-    <string name="display_name_rotv_y" translatable="false">Y</string>
-    <string name="display_name_rotv_g" translatable="false">G</string>
-    <string name="display_name_rotv_ap" translatable="false">AP</string>
-    <string name="display_name_rotv_12" translatable="false">12</string>
-    <string name="display_name_rotv_15" translatable="false">15</string>
-    <string name="display_name_rotv_18" translatable="false">18</string>
-    <string name="description_rotv_y" translatable="false">Young Ages</string>
-    <string name="description_rotv_g" translatable="false">General Exhibition</string>
-    <string name="description_rotv_ap" translatable="false">Parental guidance is recommended for children below the age of 12</string>
-    <string name="description_rotv_12" translatable="false">Forbidden for children under 12 years of age</string>
-    <string name="description_rotv_15" translatable="false">Forbidden for children under 15 years of age</string>
-    <string name="description_rotv_18" translatable="false">Forbidden for children under 18 years of age</string>
-
-    <!-- TV content rating system strings for RU TV -->
-    <string name="display_name_rutv" translatable="false">RU-TV</string>
-    <string name="display_name_rutv_0" translatable="false">0+</string>
-    <string name="display_name_rutv_6" translatable="false">6+</string>
-    <string name="display_name_rutv_12" translatable="false">12+</string>
-    <string name="display_name_rutv_16" translatable="false">16+</string>
-    <string name="display_name_rutv_18" translatable="false">18+</string>
-    <string name="description_rutv_0" translatable="false">Can be watched by Any Age</string>
-    <string name="description_rutv_6" translatable="false">Only kids the age of 6 or older can watch</string>
-    <string name="description_rutv_12" translatable="false">Only kids the age of 12 or older can watch</string>
-    <string name="description_rutv_16" translatable="false">Only teens the age of 16 or older can watch</string>
-    <string name="description_rutv_18" translatable="false">Restricted to children ONLY people 18 or older</string>
-
-    <!-- TV content rating system strings for RS TV -->
-    <string name="display_name_rstv" translatable="false">RS-TV</string>
-    <string name="display_name_rstv_g" translatable="false">G</string>
-    <string name="display_name_rstv_12" translatable="false">12</string>
-    <string name="display_name_rstv_14" translatable="false">14</string>
-    <string name="display_name_rstv_15" translatable="false">15</string>
-    <string name="display_name_rstv_16" translatable="false">16</string>
-    <string name="display_name_rstv_17" translatable="false">17</string>
-    <string name="display_name_rstv_18" translatable="false">18</string>
-    <string name="description_rstv_g" translatable="false">Program suitable for all ages</string>
-    <string name="description_rstv_12" translatable="false">Program not suitable for children under the age of 12 </string>
-    <string name="description_rstv_14" translatable="false">Program not suitable for children/teens under the age of 14</string>
-    <string name="description_rstv_15" translatable="false">Program not suitable for children/teens under the age of 15</string>
-    <string name="description_rstv_16" translatable="false">Program not suitable for children/teens under the age of 16</string>
-    <string name="description_rstv_17" translatable="false">Program not suitable for children/teens under the age of 17</string>
-    <string name="description_rstv_18" translatable="false">Program not suitable for minors under the age of 18</string>
-
-    <!-- TV content rating system strings for SGF(Free-to-Air) TV -->
-    <string name="display_name_sgftv" translatable="false">SG-Free-TV</string>
-    <string name="display_name_sgftv_pg" translatable="false">PG</string>
-    <string name="display_name_sgftv_pg13" translatable="false">PG13</string>
-    <string name="description_sgftv_pg" translatable="false">Suitable for most but parents should guide their young</string>
-    <string name="description_sgftv_pg13" translatable="false">Parental Guidance Strongly Cautioned - Suitable for 13 And Above</string>
-
-    <!-- TV content rating system strings for SGP(Pay TV) TV -->
-    <string name="display_name_sgptv" translatable="false">SG-Pay-TV</string>
-    <string name="display_name_sgptv_nc16" translatable="false">NC16</string>
-    <string name="display_name_sgptv_m18" translatable="false">M18</string>
-    <string name="description_sgptv_nc16" translatable="false">No Children Under 16</string>
-    <string name="description_sgptv_m18" translatable="false">Nobody under age 18 is admitted</string>
-
-    <!-- TV content rating system strings for SI TV -->
-    <string name="display_name_sitv" translatable="false">SI-TV</string>
-    <string name="display_name_sitv_vs" translatable="false">VS</string>
-    <string name="display_name_sitv_12" translatable="false">+12</string>
-    <string name="display_name_sitv_15" translatable="false">+15</string>
-    <string name="display_name_sitv_ad" translatable="false">AD</string>
-    <string name="description_sitv_vs" translatable="false">Parental guidance suggested (for children under 6)</string>
-    <string name="description_sitv_12" translatable="false">Content suitable for teens over 12 years</string>
-    <string name="description_sitv_15" translatable="false">Content suitable for teens over 15 years</string>
-    <string name="description_sitv_ad" translatable="false">Content exclusively for adults</string>
-
-    <!-- TV content rating system strings for TH TV -->
-    <string name="display_name_thtv" translatable="false">TH-TV</string>
-    <string name="display_name_thtv_primary" translatable="false">Primary</string>
-    <string name="display_name_thtv_children" translatable="false">Children</string>
-    <string name="display_name_thtv_general" translatable="false">General</string>
-    <string name="display_name_thtv_pg13" translatable="false">PG13</string>
-    <string name="display_name_thtv_pg18" translatable="false">PG18</string>
-    <string name="display_name_thtv_adults" translatable="false">Adults</string>
-    <string name="description_thtv_primary" translatable="false">Content suitable for primary school aged children</string>
-    <string name="description_thtv_children" translatable="false">Content suitable for children between 6-12 years old</string>
-    <string name="description_thtv_general" translatable="false">Content suitable for general audiences</string>
-    <string name="description_thtv_pg13" translatable="false">Content suitable for people aged 13 and above, but can be watched by those who are under the recommended age if parental guidance is provided</string>
-    <string name="description_thtv_pg18" translatable="false">Content suitable for people aged above 18 years old; those who are younger that 18 must be provided with parental guidance</string>
-    <string name="description_thtv_adults" translatable="false">Content unsuitable for children and youngsters</string>
-
-    <!-- TV content rating system strings for TR TV -->
-    <string name="display_name_trtv" translatable="false">TR-TV</string>
-    <string name="display_name_trtv_g" translatable="false">Genel İzleyici</string>
-    <string name="display_name_trtv_7" translatable="false">7+</string>
-    <string name="display_name_trtv_13" translatable="false">13+</string>
-    <string name="display_name_trtv_18" translatable="false">18+</string>
-    <string name="description_trtv_g" translatable="false">General audience. Suitable for all ages</string>
-    <string name="description_trtv_7" translatable="false">Suitable for ages 7 and over</string>
-    <string name="description_trtv_13" translatable="false">Suitable for ages 13 and over</string>
-    <string name="description_trtv_18" translatable="false">Suitable for ages 13 and over</string>
-
-    <!-- TV content rating system strings for TW TV -->
-    <string name="display_name_twtv" translatable="false">TW-TV</string>
-    <string name="display_name_twtv_g" translatable="false">General audiences category</string>
-    <string name="display_name_twtv_p" translatable="false">Protected category</string>
-    <string name="display_name_twtv_pg" translatable="false">Parental guidance category</string>
-    <string name="display_name_twtv_r" translatable="false">Restricted category</string>
-    <string name="description_twtv_g" translatable="false">For all ages</string>
-    <string name="description_twtv_p" translatable="false">Not suitable for children under 6 years old. People aged 6 but under 12 require guidance from accompanying adults to watch</string>
-    <string name="description_twtv_pg" translatable="false">Not suitable for people under 12 years of age. Parental guidance is required for people aged 12 but under 18</string>
-    <string name="description_twtv_r" translatable="false">For adults only and people under 18 years of age must not watch</string>
-
-    <!-- TV content rating system strings for UA TV -->
-    <string name="display_name_uatv" translatable="false">UA-TV</string>
-    <string name="display_name_uatv_green circle" translatable="false">Green Circle</string>
-    <string name="display_name_uatv_yellow triangle" translatable="false">Yellow Triangle</string>
-    <string name="display_name_uatv_red square" translatable="false">Red Square</string>
-    <string name="description_uatv_green circle" translatable="false">This program does not have age restrictions</string>
-    <string name="description_uatv_yellow triangle" translatable="false">Children must view this program with parents. In it program there are fragments, which unsuitable for children</string>
-    <string name="description_uatv_red square" translatable="false">This program is only for adult viewers. In it there are scenes with nudity, drug use, or violence</string>
-
-    <!-- TV content rating system strings for US TV -->
-    <string name="display_name_ustv" translatable="false">US-TV</string>
-    <string name="description_ustv" translatable="false">TV content rating system for United States</string>
-    <string name="display_name_ustv_d" translatable="false">D</string>
-    <string name="display_name_ustv_l" translatable="false">L</string>
-    <string name="display_name_ustv_s" translatable="false">S</string>
-    <string name="display_name_ustv_v" translatable="false">V</string>
-    <string name="display_name_ustv_fv" translatable="false">FV</string>
-    <string name="display_name_ustv_y" translatable="false">TV-Y</string>
-    <string name="display_name_ustv_y7" translatable="false">TV-Y7</string>
-    <string name="display_name_ustv_g" translatable="false">TV-G</string>
-    <string name="display_name_ustv_pg" translatable="false">TV-PG</string>
-    <string name="display_name_ustv_14" translatable="false">TV-14</string>
-    <string name="display_name_ustv_ma" translatable="false">TV-MA</string>
-    <string name="description_ustv_d" translatable="false">Suggestive dialogue (Usually means talks about sex)\nApplicable to US_TV_PG, US_TV_14, US_TV</string>
-    <string name="description_ustv_l" translatable="false">Coarse language\nApplicable to US_TV_PG, US_TV_14</string>
-    <string name="description_ustv_s" translatable="false">Sexual content\nApplicable to US_TV_PG, US_TV_14, US_TV_MA</string>
-    <string name="description_ustv_v" translatable="false">Violence\nApplicable to US_TV_PG, US_TV_14, US_TV_MA</string>
-    <string name="description_ustv_fv" translatable="false">Fantasy violence (Children\'s programming only)\nApplicable to US_TV_Y7</string>
-    <string name="description_ustv_y" translatable="false">This program is designed to be appropriate for all children</string>
-    <string name="description_ustv_y7" translatable="false">This program is designed for children age 7 and above</string>
-    <string name="description_ustv_g" translatable="false">Most parents would find this program suitable for all ages</string>
-    <string name="description_ustv_pg" translatable="false">This program contains material that parents may find unsuitable for younger children</string>
-    <string name="description_ustv_14" translatable="false">This program contains some material that many parents would find unsuitable for children under 14 years of age</string>
-    <string name="description_ustv_ma" translatable="false">This program is specifically designed to be viewed by adults and therefore may be unsuitable for children under 17</string>
-
-    <!-- TV content rating system strings for VE TV -->
-    <string name="display_name_vetv" translatable="false">VE-TV</string>
-    <string name="display_name_vetv_tu" translatable="false">TU</string>
-    <string name="display_name_vetv_su" translatable="false">SU</string>
-    <string name="display_name_vetv_a" translatable="false">A</string>
-    <string name="description_vetv_tu" translatable="false">For all ages</string>
-    <string name="description_vetv_su" translatable="false">Parental guidance for young viewers</string>
-    <string name="description_vetv_a" translatable="false">Mature viewers</string>
-
-    <!-- TV content rating system strings for ZA TV -->
-    <string name="display_name_zatv" translatable="false">ZA-TV</string>
-    <string name="display_name_zatv_d" translatable="false">D</string>
-    <string name="display_name_zatv_v" translatable="false">V</string>
-    <string name="display_name_zatv_n" translatable="false">N</string>
-    <string name="display_name_zatv_p" translatable="false">P</string>
-    <string name="display_name_zatv_s" translatable="false">S</string>
-    <string name="display_name_zatv_l" translatable="false">L</string>
-    <string name="display_name_zatv_f" translatable="false">Family</string>
-    <string name="display_name_zatv_pg" translatable="false">PG</string>
-    <string name="display_name_zatv_13" translatable="false">13</string>
-    <string name="display_name_zatv_16" translatable="false">16</string>
-    <string name="display_name_zatv_18" translatable="false">18</string>
-    <string name="display_name_zatv_r18" translatable="false">R18</string>
-    <string name="description_zatv_d" translatable="false">Drug\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_v" translatable="false">Violence\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_n" translatable="false">Nudity\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_p" translatable="false">Prejudice\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_s" translatable="false">Sex\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_l" translatable="false">Language\nApplicable to ZA_TV_F, ZA_TV_PG, ZA_TV_13, ZA_TV_16, ZA_TV_18, ZA_TV_R18</string>
-    <string name="description_zatv_f" translatable="false">This is a program/film that does not contain any obscenity, and is suitable for family viewing. A logo must be displayed in the corner of the screen for 30 seconds after each commercial break</string>
-    <string name="description_zatv_pg" translatable="false">Children under 6 may watch this program/film, but must be accompanied by an adult. This program contains an adult related theme, which might include very mild language, violence and sexual innuendo. A logo must be displayed in the corner of the screen for one minute after each commercial break</string>
-    <string name="description_zatv_13" translatable="false">Children under 13 are prohibited from watching this program/film. This program contains mild language, violence and sexual innuendo. A logo must be displayed in the corner of the screen for two minutes after each commercial break</string>
-    <string name="description_zatv_16" translatable="false">Children under 16 are prohibited from watching this program/film. It contains moderate violence, language, and some sexual situations. In the case of television, this program may only be broadcast after 9pm-4:30am. A logo must be displayed in the corner of the screen for five minutes after each commercial break. A full-screen warning must be issued before the start of the program. If the program is longer than an hour, a warning must be displayed every half an hour</string>
-    <string name="description_zatv_18" translatable="false">Children under 18 are prohibited from watching this program/film. It contains extreme violence, language and/or graphic sexual content. In the case of television, this program may only be broadcast from 10pm-4:30am. A logo must be displayed in the corner of the screen for the duration of the program. A full-screen warning must be issued before the start of the program and after each commercial break</string>
-    <string name="description_zatv_r18" translatable="false">This is reserved for films of an extreme sexual nature (pornography). R18 films may only be distributed in the form of video and DVD in a controlled environment (e.g. Adult Shops). No public viewing of this film may take place. R18 films may not be broadcast on television and in cinemas</string>
+    <string name="lock_to_app_unlock_password">Ask for password before unpinning</string>
 
     <!-- [CHAR_LIMIT=NONE] Battery saver: Feature description -->
-    <string name="battery_saver_description">To help improve battery life, battery saver reduces your device’s performance and limits vibration and most background data. Email, messaging, and other apps that rely on syncing may not update unless you open them.\n\nBattery saver turns off automatically when your device is charging</string>
+    <string name="battery_saver_description">To help improve battery life, battery saver reduces your device’s performance and limits vibration and most background data. Email, messaging, and other apps that rely on syncing may not update unless you open them.\n\nBattery saver turns off automatically when your device is charging.</string>
 
     <!-- [CHAR_LIMIT=NONE] Zen mode: Condition summary for built-in downtime condition, if active -->
     <string name="downtime_condition_summary">Until your downtime ends at <xliff:g id="formattedTime" example="10.00 PM">%1$s</xliff:g></string>
+
+    <!-- Zen mode condition: time duration in minutes. [CHAR LIMIT=NONE] -->
+    <plurals name="zen_mode_duration_minutes">
+        <item quantity="one">For one minute</item>
+        <item quantity="other">For %d minutes</item>
+    </plurals>
+
+    <!-- Zen mode condition: time duration in hours. [CHAR LIMIT=NONE] -->
+    <plurals name="zen_mode_duration_hours">
+        <item quantity="one">For one hour</item>
+        <item quantity="other">For %d hours</item>
+    </plurals>
+
+    <!-- Zen mode condition: no exit criteria. [CHAR LIMIT=NONE] -->
+    <string name="zen_mode_forever">Indefinitely</string>
 </resources>
diff --git a/core/res/res/values/styles.xml b/core/res/res/values/styles.xml
index 8fc9bac..c6d0b0b 100644
--- a/core/res/res/values/styles.xml
+++ b/core/res/res/values/styles.xml
@@ -62,6 +62,7 @@
         <item name="centerMedium">@drawable/popup_center_medium</item>
         <item name="progressLayout">@layout/progress_dialog</item>
         <item name="horizontalProgressLayout">@layout/alert_dialog_progress</item>
+        <item name="needsDefaultBackgrounds">false</item>
     </style>
 
     <style name="Widget.PreferenceFrameLayout">
@@ -82,7 +83,7 @@
         <item name="activityCloseExitAnimation">@anim/activity_close_exit</item>
         <item name="taskOpenEnterAnimation">@anim/task_open_enter</item>
         <item name="taskOpenExitAnimation">@anim/task_open_exit</item>
-        <item name="launchTaskBehindBackgroundAnimation">@anim/launch_task_behind_background</item>
+        <item name="launchTaskBehindTargetAnimation">@anim/launch_task_behind_target</item>
         <item name="launchTaskBehindSourceAnimation">@anim/launch_task_behind_source</item>
         <item name="taskCloseEnterAnimation">@anim/task_close_enter</item>
         <item name="taskCloseExitAnimation">@anim/task_close_exit</item>
@@ -1355,12 +1356,4 @@
         <item name="padding">16dp</item>
     </style>
 
-    <style name="Lighting">
-        <item name="lightY">-200dp</item>
-        <item name="lightZ">800dp</item>
-        <item name="lightRadius">800dp</item>
-        <item name="ambientShadowAlpha">0.06</item>
-        <item name="spotShadowAlpha">0.16</item>
-    </style>
-
 </resources>
diff --git a/core/res/res/values/styles_holo.xml b/core/res/res/values/styles_holo.xml
index 2a54ccf..c7d2db1 100644
--- a/core/res/res/values/styles_holo.xml
+++ b/core/res/res/values/styles_holo.xml
@@ -468,7 +468,7 @@
         <item name="internalLayout">@layout/time_picker_holo</item>
         <item name="headerTimeTextAppearance">@style/TextAppearance.Holo.TimePicker.TimeLabel</item>
         <item name="headerAmPmTextAppearance">@style/TextAppearance.Holo.TimePicker.AmPmLabel</item>
-        <item name="headerBackgroundColor">@color/timepicker_default_background_holo_dark</item>
+        <item name="headerBackground">@color/timepicker_default_background_holo_dark</item>
         <item name="headerSelectedTextColor">@color/holo_blue_light</item>
         <item name="numbersTextColor">@color/timepicker_default_text_color_holo_dark</item>
         <item name="numbersBackgroundColor">@color/timepicker_default_background_holo_dark</item>
@@ -484,9 +484,9 @@
         <item name="internalLayout">@layout/date_picker_holo</item>
         <item name="calendarViewShown">true</item>
         <!-- New-style date picker attributes. -->
-        <item name="dayOfWeekBackgroundColor">@color/datepicker_default_header_dayofweek_background_color_holo_dark</item>
+        <item name="dayOfWeekBackground">@color/datepicker_default_header_dayofweek_background_color_holo_dark</item>
         <item name="dayOfWeekTextAppearance">@style/TextAppearance.Holo.DatePicker.DayOfWeekLabel</item>
-        <item name="headerBackgroundColor">@color/datepicker_default_header_selector_background_holo_dark</item>
+        <item name="headerBackground">@color/datepicker_default_header_selector_background_holo_dark</item>
         <item name="headerMonthTextAppearance">@style/TextAppearance.Holo.DatePicker.Selector.MonthLabel</item>
         <item name="headerDayOfMonthTextAppearance">@style/TextAppearance.Holo.DatePicker.Selector.DayOfMonthLabel</item>
         <item name="headerYearTextAppearance">@style/TextAppearance.Holo.DatePicker.Selector.YearLabel</item>
@@ -892,7 +892,7 @@
         <item name="internalLayout">@layout/time_picker_holo</item>
         <item name="headerTimeTextAppearance">@style/TextAppearance.Holo.Light.TimePicker.TimeLabel</item>
         <item name="headerAmPmTextAppearance">@style/TextAppearance.Holo.Light.TimePicker.AmPmLabel</item>
-        <item name="headerBackgroundColor">@color/timepicker_default_background_holo_light</item>
+        <item name="headerBackground">@color/timepicker_default_background_holo_light</item>
         <item name="headerSelectedTextColor">@color/holo_blue_light</item>
         <item name="numbersTextColor">@color/timepicker_default_text_color_holo_light</item>
         <item name="numbersBackgroundColor">@color/timepicker_default_background_holo_light</item>
@@ -908,12 +908,12 @@
         <item name="internalLayout">@layout/date_picker_holo</item>
         <item name="calendarViewShown">true</item>
         <!-- New-style date picker attributes. -->
-        <item name="dayOfWeekBackgroundColor">@color/datepicker_default_header_dayofweek_background_color_holo_light</item>
+        <item name="dayOfWeekBackground">@color/datepicker_default_header_dayofweek_background_color_holo_light</item>
         <item name="dayOfWeekTextAppearance">@style/TextAppearance.Holo.Light.DatePicker.DayOfWeekLabel</item>
         <item name="headerMonthTextAppearance">@style/TextAppearance.Holo.Light.DatePicker.Selector.MonthLabel</item>
         <item name="headerDayOfMonthTextAppearance">@style/TextAppearance.Holo.Light.DatePicker.Selector.DayOfMonthLabel</item>
         <item name="headerYearTextAppearance">@style/TextAppearance.Holo.Light.DatePicker.Selector.YearLabel</item>
-        <item name="headerBackgroundColor">@color/datepicker_default_header_selector_background_holo_light</item>
+        <item name="headerBackground">@color/datepicker_default_header_selector_background_holo_light</item>
         <item name="headerSelectedTextColor">@color/holo_blue_light</item>
         <item name="yearListItemTextAppearance">@style/TextAppearance.Holo.Light.DatePicker.List.YearLabel</item>
         <item name="yearListSelectorColor">@color/datepicker_default_circle_background_color_holo_light</item>
diff --git a/core/res/res/values/styles_leanback.xml b/core/res/res/values/styles_leanback.xml
index da83c36..aaeaadd 100644
--- a/core/res/res/values/styles_leanback.xml
+++ b/core/res/res/values/styles_leanback.xml
@@ -15,8 +15,7 @@
 -->
 <resources>
     <style name="AlertDialog.Leanback" parent="AlertDialog.Material">
-        <item name="layout">@android:layout/alert_dialog_leanback</item>
-        <item name="buttonPanelSideLayout">@android:layout/alert_dialog_leanback_button_panel_right</item>
+        <item name="buttonPanelSideLayout">@android:layout/alert_dialog_leanback_button_panel_side</item>
     </style>
 
     <style name="AlertDialog.Leanback.Light">
@@ -24,7 +23,6 @@
 
     <style name="Widget.Leanback.TimePicker" parent="Widget.Material.TimePicker">
         <item name="timePickerMode">spinner</item>
-        <item name="legacyLayout">@layout/time_picker_legacy_leanback</item>
     </style>
 
     <style name="Widget.Leanback.DatePicker" parent="Widget.Material.DatePicker">
@@ -38,24 +36,28 @@
     <!-- Setup and form wizard themes -->
     <style name="TextAppearance.Leanback.FormWizard" parent="@style/TextAppearance.Material">
         <item name="textSize">18sp</item>
+        <item name="lineSpacingExtra">24sp</item>
         <item name="fontFamily">sans-serif-light</item>
         <item name="textColor">?attr/textColorPrimary</item>
     </style>
 
     <style name="TextAppearance.Leanback.FormWizard.Small" parent="@style/TextAppearance.Material.Small">
-        <item name="textSize">18sp</item>
+        <item name="textSize">14sp</item>
+        <item name="lineSpacingExtra">24sp</item>
         <item name="fontFamily">sans-serif-light</item>
         <item name="textColor">?attr/textColorPrimary</item>
     </style>
 
     <style name="TextAppearance.Leanback.FormWizard.Medium" parent="@style/TextAppearance.Material.Medium">
         <item name="textSize">36sp</item>
+        <item name="lineSpacingExtra">40sp</item>
         <item name="fontFamily">sans-serif-thin</item>
         <item name="textColor">?attr/textColorPrimary</item>
     </style>
 
     <style name="TextAppearance.Leanback.FormWizard.Large" parent="@style/TextAppearance.Material.Large">
-        <item name="textSize">56sp</item>
+        <item name="textSize">42sp</item>
+        <item name="lineSpacingExtra">48sp</item>
         <item name="fontFamily">sans-serif-thin</item>
         <item name="textColor">?attr/textColorPrimary</item>
     </style>
diff --git a/core/res/res/values/styles_material.xml b/core/res/res/values/styles_material.xml
index 0f27824..e6e5cbb 100644
--- a/core/res/res/values/styles_material.xml
+++ b/core/res/res/values/styles_material.xml
@@ -306,22 +306,45 @@
     </style>
 
     <style name="TextAppearance.Material.Widget.TextView.PopupMenu" parent="TextAppearance.Material.Menu" />
-    <style name="TextAppearance.Material.Widget.TextView.SpinnerItem" />
+    <style name="TextAppearance.Material.Widget.TextView.SpinnerItem" parent="TextAppearance.Material.Menu" />
 
-    <style name="TextAppearance.Material.Widget.DropDownItem">
+    <style name="TextAppearance.Material.Widget.DropDownItem" parent="TextAppearance.Material.Menu">
         <item name="textColor">?attr/textColorPrimaryDisableOnly</item>
     </style>
 
     <style name="TextAppearance.Material.Widget.ActionMode"/>
-    <style name="TextAppearance.Material.Widget.ActionMode.Title" parent="TextAppearance.Material.Title" />
-    <style name="TextAppearance.Material.Widget.ActionMode.Title.Inverse" parent="TextAppearance.Material.Title.Inverse" />
-    <style name="TextAppearance.Material.Widget.ActionMode.Subtitle" parent="TextAppearance.Material.Subhead" />
-    <style name="TextAppearance.Material.Widget.ActionMode.Subtitle.Inverse" parent="TextAppearance.Material.Subhead.Inverse" />
-
-    <style name="TextAppearance.Material.Widget.ActionBar.Title" parent="TextAppearance.Material.Title" />
-    <style name="TextAppearance.Material.Widget.ActionBar.Title.Inverse" parent="TextAppearance.Material.Title.Inverse" />
-    <style name="TextAppearance.Material.Widget.ActionBar.Subtitle" parent="TextAppearance.Material.Subhead" />
-    <style name="TextAppearance.Material.Widget.ActionBar.Subtitle.Inverse" parent="TextAppearance.Material.Subhead.Inverse" />
+    <style name="TextAppearance.Material.Widget.ActionMode.Title"
+           parent="TextAppearance.Material.Title">
+        <item name="textSize">@dimen/text_size_title_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionMode.Title.Inverse"
+           parent="TextAppearance.Material.Title.Inverse">
+        <item name="textSize">@dimen/text_size_title_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionMode.Subtitle"
+           parent="TextAppearance.Material.Subhead">
+        <item name="textSize">@dimen/text_size_subtitle_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionMode.Subtitle.Inverse"
+           parent="TextAppearance.Material.Subhead.Inverse">
+        <item name="textSize">@dimen/text_size_subtitle_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionBar.Title"
+           parent="TextAppearance.Material.Title">
+        <item name="textSize">@dimen/text_size_title_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionBar.Title.Inverse"
+           parent="TextAppearance.Material.Title.Inverse">
+        <item name="textSize">@dimen/text_size_title_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionBar.Subtitle"
+           parent="TextAppearance.Material.Subhead">
+        <item name="textSize">@dimen/text_size_subtitle_material_toolbar</item>
+    </style>
+    <style name="TextAppearance.Material.Widget.ActionBar.Subtitle.Inverse"
+           parent="TextAppearance.Material.Subhead.Inverse">
+        <item name="textSize">@dimen/text_size_subtitle_material_toolbar</item>
+    </style>
 
     <style name="TextAppearance.Material.Widget.ActionBar.Menu" parent="TextAppearance.Material.Menu">
         <item name="textColor">?attr/actionMenuTextColor</item>
@@ -333,6 +356,11 @@
         <item name="textAllCaps">@bool/config_actionMenuItemAllCaps</item>
     </style>
 
+    <style name="TextAppearance.Material.Widget.Toolbar.Title"
+           parent="TextAppearance.Material.Widget.ActionBar.Title" />
+    <style name="TextAppearance.Material.Widget.Toolbar.Subtitle"
+           parent="TextAppearance.Material.Widget.ActionBar.Subtitle" />
+
     <style name="TextAppearance.Material.WindowTitle" parent="TextAppearance.Material.Title" />
     <style name="TextAppearance.Material.DialogWindowTitle" parent="TextAppearance.Material.Title" />
 
@@ -382,39 +410,33 @@
         <item name="textSize">@dimen/datepicker_year_label_text_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material" />
-
-    <style name="TextAppearance.StatusBar.Material.EventContent">
-        <item name="textColor">#90000000</item>
+    <style name="TextAppearance.Material.Notification">
+        <item name="textColor">@color/secondary_text_material_light</item>
         <item name="textSize">@dimen/notification_text_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Title">
-        <item name="textColor">#DD000000</item>
+    <style name="TextAppearance.Material.Notification.Title">
+        <item name="textColor">@color/primary_text_default_material_light</item>
         <item name="textSize">@dimen/notification_title_text_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Line2">
+    <style name="TextAppearance.Material.Notification.Line2">
         <item name="textSize">@dimen/notification_subtext_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Info">
+    <style name="TextAppearance.Material.Notification.Info">
         <item name="textSize">@dimen/notification_subtext_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Time">
+    <style name="TextAppearance.Material.Notification.Time">
         <item name="textSize">@dimen/notification_subtext_size</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Emphasis">
+    <style name="TextAppearance.Material.Notification.Emphasis">
         <item name="textColor">#66000000</item>
     </style>
 
-    <style name="Widget.StatusBar.Material.ProgressBar" parent="Widget.Material.Light.ProgressBar.Horizontal" />
-
-    <style name="Widget.StatusBar.Material.ProgressBar.Media">
-        <item name="progressDrawable">@drawable/notification_material_media_progress</item>
-    </style>
+    <style name="Widget.Material.Notification.ProgressBar" parent="Widget.Material.Light.ProgressBar.Horizontal" />
 
     <!-- Widget Styles -->
 
@@ -423,12 +445,15 @@
     <style name="Widget.Material" parent="Widget" />
 
     <!-- Bordered ink button -->
-    <style name="Widget.Material.Button" parent="Widget.Button">
+    <style name="Widget.Material.Button">
         <item name="background">@drawable/btn_default_material</item>
         <item name="textAppearance">?attr/textAppearanceButton</item>
         <item name="minHeight">48dip</item>
         <item name="minWidth">88dip</item>
         <item name="stateListAnimator">@anim/button_state_list_anim_material</item>
+        <item name="focusable">true</item>
+        <item name="clickable">true</item>
+        <item name="gravity">center_vertical|center_horizontal</item>
     </style>
 
     <!-- Small bordered ink button -->
@@ -449,6 +474,13 @@
         <item name="stateListAnimator">@anim/disabled_anim_material</item>
     </style>
 
+    <!-- Alert dialog button bar button -->
+    <style name="Widget.Material.Button.ButtonBar.AlertDialog" parent="Widget.Material.Button.Borderless.Colored">
+        <item name="minWidth">64dp</item>
+        <item name="maxLines">2</item>
+        <item name="minHeight">@dimen/alert_dialog_button_bar_height</item>
+    </style>
+
     <!-- Small borderless ink button -->
     <style name="Widget.Material.Button.Borderless.Small">
         <item name="minHeight">48dip</item>
@@ -471,10 +503,6 @@
 
     <style name="Widget.Material.ButtonBar.AlertDialog">
         <item name="background">@null</item>
-        <item name="paddingStart">16dp</item>
-        <item name="paddingEnd">16dp</item>
-        <item name="paddingBottom">16dp</item>
-        <item name="minHeight">@dimen/alert_dialog_button_bar_height</item>
     </style>
 
     <style name="Widget.Material.SearchView">
@@ -597,7 +625,7 @@
         <item name="headerTimeTextAppearance">@style/TextAppearance.Material.TimePicker.TimeLabel</item>
         <item name="headerAmPmTextAppearance">@style/TextAppearance.Material.TimePicker.AmPmLabel</item>
         <item name="headerSelectedTextColor">?attr/textColorPrimaryInverse</item>
-        <item name="headerBackgroundColor">?attr/colorAccent</item>
+        <item name="headerBackground">@drawable/time_picker_header_material</item>
         <item name="numbersTextColor">?attr/textColorSecondary</item>
         <item name="numbersBackgroundColor">#10ffffff</item>
         <item name="amPmTextColor">?attr/textColorSecondary</item>
@@ -612,13 +640,13 @@
         <!-- Attributes for new-style DatePicker. -->
         <item name="internalLayout">@layout/date_picker_holo</item>
         <item name="calendarViewShown">true</item>
-        <item name="dayOfWeekBackgroundColor">#10000000</item>
+        <item name="dayOfWeekBackground">#10000000</item>
         <item name="dayOfWeekTextAppearance">@style/TextAppearance.Material.DatePicker.DayOfWeekLabel</item>
         <item name="headerMonthTextAppearance">@style/TextAppearance.Material.DatePicker.MonthLabel</item>
         <item name="headerDayOfMonthTextAppearance">@style/TextAppearance.Material.DatePicker.DayOfMonthLabel</item>
         <item name="headerYearTextAppearance">@style/TextAppearance.Material.DatePicker.YearLabel</item>
         <item name="headerSelectedTextColor">?attr/textColorPrimaryInverse</item>
-        <item name="headerBackgroundColor">?attr/colorAccent</item>
+        <item name="headerBackground">?attr/colorAccent</item>
         <item name="yearListItemTextAppearance">@style/TextAppearance.Material.DatePicker.List.YearLabel</item>
         <item name="yearListSelectorColor">?attr/colorControlActivated</item>
         <item name="calendarTextColor">?attr/textColorSecondary</item>
@@ -718,6 +746,7 @@
         <item name="popupElevation">@dimen/floating_window_z</item>
         <item name="dropDownVerticalOffset">0dip</item>
         <item name="dropDownHorizontalOffset">0dip</item>
+        <item name="overlapAnchor">true</item>
         <item name="dropDownWidth">wrap_content</item>
         <item name="popupPromptView">@layout/simple_dropdown_hint</item>
         <item name="gravity">start|center_vertical</item>
@@ -731,7 +760,7 @@
         <item name="overlapAnchor">true</item>
     </style>
 
-    <style name="Widget.Material.Spinner.Form">
+    <style name="Widget.Material.Spinner.Underlined">
         <item name="background">@drawable/spinner_textfield_background_material</item>
     </style>
 
@@ -759,6 +788,8 @@
 
     <style name="Widget.Material.Toolbar" parent="Widget.Toolbar">
         <item name="navigationButtonStyle">@style/Widget.Material.Toolbar.Button.Navigation</item>
+        <item name="titleTextAppearance">@style/TextAppearance.Material.Widget.Toolbar.Title</item>
+        <item name="subtitleTextAppearance">@style/TextAppearance.Material.Widget.Toolbar.Subtitle</item>
     </style>
 
     <style name="Widget.Material.Toolbar.Button.Navigation" parent="Widget.Toolbar.Button.Navigation">
@@ -799,6 +830,7 @@
 
     <style name="Widget.Material.PopupMenu.Overflow">
         <item name="overlapAnchor">true</item>
+        <item name="dropDownHorizontalOffset">-4dip</item>
     </style>
 
     <style name="Widget.Material.ActionButton" parent="Widget.ActionButton">
@@ -807,19 +839,22 @@
         <item name="gravity">center</item>
         <item name="scaleType">center</item>
         <item name="maxLines">2</item>
+        <item name="paddingStart">12dp</item>
+        <item name="paddingEnd">12dp</item>
     </style>
 
     <style name="Widget.Material.ActionButton.CloseMode">
-        <item name="background">@drawable/btn_cab_done_material</item>
+        <item name="background">?attr/selectableItemBackgroundBorderless</item>
     </style>
 
     <style name="Widget.Material.ActionButton.Overflow">
         <item name="src">@drawable/ic_menu_moreoverflow_material</item>
         <item name="background">?attr/actionBarItemBackground</item>
         <item name="contentDescription">@string/action_menu_overflow_description</item>
-        <item name="minWidth">@dimen/action_overflow_min_width_material</item>
+        <item name="minWidth">@dimen/action_button_min_width_overflow_material</item>
         <item name="minHeight">@dimen/action_button_min_height_material</item>
-        <item name="scaleType">center</item>
+        <item name="paddingStart">0dp</item>
+        <item name="paddingEnd">12dp</item>
     </style>
 
     <style name="Widget.Material.ActionBar.TabView" parent="Widget.ActionBar.TabView">
@@ -872,11 +907,16 @@
     <style name="Widget.Material.ActionMode" parent="Widget.ActionMode">
         <item name="titleTextStyle">@style/TextAppearance.Material.Widget.ActionMode.Title</item>
         <item name="subtitleTextStyle">@style/TextAppearance.Material.Widget.ActionMode.Subtitle</item>
+        <item name="closeItemLayout">@layout/action_mode_close_item_material</item>
     </style>
 
     <style name="Widget.Material.FastScroll" parent="Widget.FastScroll">
         <item name="thumbMinWidth">0dp</item>
         <item name="thumbMinHeight">0dp</item>
+        <item name="minWidth">88dp</item>
+        <item name="minHeight">88dp</item>
+        <item name="padding">0dp</item>
+        <item name="textSize">45sp</item>
     </style>
 
     <style name="Widget.Material.PreferenceFrameLayout">
@@ -902,6 +942,7 @@
     <style name="Widget.Material.Light.Button.Small" parent="Widget.Material.Button.Small"/>
     <style name="Widget.Material.Light.Button.Borderless" parent="Widget.Material.Button.Borderless"/>
     <style name="Widget.Material.Light.Button.Borderless.Colored" parent="Widget.Material.Button.Borderless.Colored"/>
+    <style name="Widget.Material.Light.Button.ButtonBar.AlertDialog" parent="Widget.Material.Button.ButtonBar.AlertDialog" />
     <style name="Widget.Material.Light.Button.Borderless.Small" parent="Widget.Material.Button.Borderless.Small"/>
     <style name="Widget.Material.Light.Button.Inset" parent="Widget.Material.Button.Inset"/>
     <style name="Widget.Material.Light.Button.Toggle" parent="Widget.Material.Button.Toggle" />
@@ -988,7 +1029,7 @@
     <style name="Widget.Material.Light.Spinner" parent="Widget.Material.Spinner" />
     <style name="Widget.Material.Light.Spinner.DropDown" parent="Widget.Material.Spinner.DropDown"/>
     <style name="Widget.Material.Light.Spinner.DropDown.ActionBar" parent="Widget.Material.Spinner.DropDown.ActionBar"/>
-    <style name="Widget.Material.Light.Spinner.Form" parent="Widget.Material.Spinner.Form" />
+    <style name="Widget.Material.Light.Spinner.Underlined" parent="Widget.Material.Spinner.Underlined" />
     <style name="Widget.Material.Light.TabWidget" parent="Widget.Material.TabWidget"/>
     <style name="Widget.Material.Light.WebTextView" parent="Widget.Material.WebTextView"/>
     <style name="Widget.Material.Light.WebView" parent="Widget.Material.WebView"/>
@@ -1035,16 +1076,16 @@
     <!-- Dialog styles -->
 
     <style name="AlertDialog.Material" parent="AlertDialog">
-        <item name="fullDark">@color/transparent</item>
-        <item name="topDark">@color/transparent</item>
-        <item name="centerDark">@color/transparent</item>
-        <item name="bottomDark">@color/transparent</item>
-        <item name="fullBright">@color/transparent</item>
-        <item name="topBright">@color/transparent</item>
-        <item name="centerBright">@color/transparent</item>
-        <item name="bottomBright">@color/transparent</item>
-        <item name="bottomMedium">@color/transparent</item>
-        <item name="centerMedium">@color/transparent</item>
+        <item name="fullDark">@null</item>
+        <item name="topDark">@null</item>
+        <item name="centerDark">@null</item>
+        <item name="bottomDark">@null</item>
+        <item name="fullBright">@null</item>
+        <item name="topBright">@null</item>
+        <item name="centerBright">@null</item>
+        <item name="bottomBright">@null</item>
+        <item name="bottomMedium">@null</item>
+        <item name="centerMedium">@null</item>
         <item name="layout">@layout/alert_dialog_material</item>
         <item name="listLayout">@layout/select_dialog_material</item>
         <item name="progressLayout">@layout/progress_dialog_material</item>
diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml
index 426a82d..ea7188d 100644
--- a/core/res/res/values/symbols.xml
+++ b/core/res/res/values/symbols.xml
@@ -216,7 +216,9 @@
   <java-symbol type="id" name="pin_confirm_text" />
   <java-symbol type="id" name="pin_error_message" />
   <java-symbol type="id" name="timePickerLayout" />
-  <java-symbol type="id" name="profile_icon" />
+  <java-symbol type="id" name="profile_badge_large_template" />
+  <java-symbol type="id" name="profile_badge_line2" />
+  <java-symbol type="id" name="profile_badge_line3" />
   <java-symbol type="id" name="transitionPosition" />
 
   <java-symbol type="attr" name="actionModeShareDrawable" />
@@ -281,6 +283,7 @@
   <java-symbol type="bool" name="config_camera_sound_forced" />
   <java-symbol type="bool" name="config_dontPreferApn" />
   <java-symbol type="bool" name="config_restartRadioAfterProvisioning" />
+  <java-symbol type="bool" name="config_requireRadioPowerOffOnSimRefreshReset" />
   <java-symbol type="bool" name="config_speed_up_audio_on_mt_calls" />
   <java-symbol type="bool" name="config_useFixedVolume" />
   <java-symbol type="bool" name="config_forceDefaultOrientation" />
@@ -290,7 +293,43 @@
   <java-symbol type="bool" name="config_windowIsRound" />
   <java-symbol type="bool" name="config_hasRecents" />
   <java-symbol type="bool" name="config_windowShowCircularMask" />
+  <java-symbol type="bool" name="config_windowEnableCircularEmulatorDisplayOverlay" />
+  <java-symbol type="bool" name="config_wifi_framework_enable_associated_autojoin_scan" />
+  <java-symbol type="bool" name="config_wifi_framework_enable_associated_network_selection" />
+  <java-symbol type="bool" name="config_wifi_only_link_same_credential_configurations" />
+  <java-symbol type="bool" name="config_wifi_enable_disconnection_debounce" />
+  <java-symbol type="bool" name="config_wifi_enable_5GHz_preference" />
+  <java-symbol type="integer" name="config_wifi_framework_5GHz_preference_boost_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_5GHz_preference_boost_factor" />
+  <java-symbol type="integer" name="config_wifi_framework_5GHz_preference_penalty_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_current_association_hysteresis_high" />
+  <java-symbol type="integer" name="config_wifi_framework_current_association_hysteresis_low" />
+  <java-symbol type="integer" name="config_wifi_framework_5GHz_preference_penalty_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_5GHz_preference_penalty_factor" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_scan_interval" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_full_scan_backoff" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_full_scan_max_interval" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_full_scan_max_total_dwell_time" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_partial_scan_max_num_active_channels" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_partial_scan_max_num_passive_channels" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_bad_rssi_threshold_24GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_low_rssi_threshold_24GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_good_rssi_threshold_24GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_bad_rssi_threshold_5GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_low_rssi_threshold_5GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_good_rssi_threshold_5GHz" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_bad_link_speed_24" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_bad_link_speed_5" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_good_link_speed_24" />
+  <java-symbol type="integer" name="config_wifi_framework_wifi_score_good_link_speed_5" />
 
+  <java-symbol type="bool" name="config_wifi_framework_cellular_handover_enable_user_triggered_adjustment" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_full_scan_tx_packet_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_full_scan_rx_packet_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_partial_scan_tx_packet_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_associated_partial_scan_rx_packet_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_network_switch_tx_packet_threshold" />
+  <java-symbol type="integer" name="config_wifi_framework_network_switch_tx_packet_threshold" />
   <java-symbol type="integer" name="config_bluetooth_max_advertisers" />
   <java-symbol type="integer" name="config_bluetooth_max_scan_filters" />
   <java-symbol type="integer" name="config_cursorWindowSize" />
@@ -321,9 +360,11 @@
   <java-symbol type="integer" name="config_multiuserMaximumUsers" />
   <java-symbol type="integer" name="config_safe_media_volume_index" />
   <java-symbol type="integer" name="config_mobile_mtu" />
+  <java-symbol type="array"   name="config_mobile_tcp_buffers" />
   <java-symbol type="integer" name="config_volte_replacement_rat"/>
   <java-symbol type="integer" name="config_valid_wappush_index" />
   <java-symbol type="integer" name="config_overrideHasPermanentMenuKey" />
+  <java-symbol type="bool" name="config_hasPermanentDpad" />
 
   <java-symbol type="color" name="tab_indicator_text_v4" />
 
@@ -349,7 +390,12 @@
   <java-symbol type="dimen" name="notification_text_size" />
   <java-symbol type="dimen" name="notification_title_text_size" />
   <java-symbol type="dimen" name="notification_subtext_size" />
-  <java-symbol type="dimen" name="notification_large_font_vert_pad" />
+  <java-symbol type="dimen" name="notification_top_pad" />
+  <java-symbol type="dimen" name="notification_top_pad_narrow" />
+  <java-symbol type="dimen" name="notification_top_pad_large_text" />
+  <java-symbol type="dimen" name="notification_top_pad_large_text_narrow" />
+  <java-symbol type="dimen" name="notification_large_icon_circle_padding" />
+  <java-symbol type="dimen" name="notification_badge_size" />
   <java-symbol type="dimen" name="immersive_mode_cling_width" />
   <java-symbol type="dimen" name="circular_display_mask_offset" />
 
@@ -621,7 +667,6 @@
   <java-symbol type="id" name="lock_to_app_checkbox" />
   <java-symbol type="string" name="lock_to_app_start" />
   <java-symbol type="string" name="lock_to_app_exit" />
-  <java-symbol type="string" name="lock_to_app_use_screen_lock" />
   <java-symbol type="string" name="lock_to_app_unlock_pin" />
   <java-symbol type="string" name="lock_to_app_unlock_pattern" />
   <java-symbol type="string" name="lock_to_app_unlock_password" />
@@ -830,6 +875,7 @@
   <java-symbol type="string" name="time_picker_increment_set_pm_button" />
   <java-symbol type="string" name="upload_file" />
   <java-symbol type="string" name="user_switched" />
+  <java-symbol type="string" name="user_switching_message" />
   <java-symbol type="string" name="volume_alarm" />
   <java-symbol type="string" name="volume_icon_description_bluetooth" />
   <java-symbol type="string" name="volume_icon_description_incall" />
@@ -983,6 +1029,8 @@
   <java-symbol type="string" name="ssl_ca_cert_warning" />
   <java-symbol type="string" name="lockscreen_transport_play_description" />
   <java-symbol type="string" name="lockscreen_transport_pause_description" />
+  <java-symbol type="string" name="config_ethernet_tcp_buffers" />
+  <java-symbol type="string" name="config_wifi_tcp_buffers" />
 
   <java-symbol type="plurals" name="abbrev_in_num_days" />
   <java-symbol type="plurals" name="abbrev_in_num_hours" />
@@ -1027,6 +1075,7 @@
   <java-symbol type="array" name="config_globalActionsList" />
   <java-symbol type="array" name="config_telephonyHardware" />
   <java-symbol type="array" name="config_keySystemUuidMapping" />
+  <java-symbol type="array" name="config_gpsParameters" />
 
   <java-symbol type="drawable" name="default_wallpaper" />
   <java-symbol type="drawable" name="indicator_input_error" />
@@ -1143,6 +1192,8 @@
   <java-symbol type="drawable" name="ic_corp_badge" />
   <java-symbol type="drawable" name="ic_corp_icon_badge" />
   <java-symbol type="drawable" name="ic_corp_icon" />
+  <java-symbol type="drawable" name="ic_corp_statusbar_icon" />
+  <java-symbol type="drawable" name="emulator_circular_window_overlay" />
 
   <java-symbol type="drawable" name="sim_light_blue" />
   <java-symbol type="drawable" name="sim_light_green" />
@@ -1153,6 +1204,18 @@
   <java-symbol type="drawable" name="sim_dark_orange" />
   <java-symbol type="drawable" name="sim_dark_purple" />
 
+  <java-symbol type="drawable" name="ic_account_circle" />
+  <java-symbol type="color" name="user_icon_1" />
+  <java-symbol type="color" name="user_icon_2" />
+  <java-symbol type="color" name="user_icon_3" />
+  <java-symbol type="color" name="user_icon_4" />
+  <java-symbol type="color" name="user_icon_5" />
+  <java-symbol type="color" name="user_icon_6" />
+  <java-symbol type="color" name="user_icon_7" />
+  <java-symbol type="color" name="user_icon_8" />
+  <java-symbol type="color" name="user_icon_default_gray" />
+  <java-symbol type="color" name="user_icon_default_white" />
+
   <java-symbol type="layout" name="action_bar_home" />
   <java-symbol type="layout" name="action_bar_title_item" />
   <java-symbol type="layout" name="action_menu_item_layout" />
@@ -1244,6 +1307,7 @@
   <java-symbol type="layout" name="restrictions_pin_challenge" />
   <java-symbol type="layout" name="restrictions_pin_setup" />
   <java-symbol type="layout" name="immersive_mode_cling" />
+  <java-symbol type="layout" name="user_switching_dialog" />
 
   <java-symbol type="anim" name="slide_in_child_bottom" />
   <java-symbol type="anim" name="slide_in_right" />
@@ -1265,7 +1329,6 @@
   <java-symbol type="xml" name="audio_assets" />
   <java-symbol type="xml" name="global_keys" />
   <java-symbol type="xml" name="default_zen_mode_config" />
-  <java-symbol type="xml" name="tv_content_rating_systems" />
 
   <java-symbol type="raw" name="color_fade_vert" />
   <java-symbol type="raw" name="color_fade_frag" />
@@ -1493,6 +1556,7 @@
   <java-symbol type="bool" name="config_useAttentionLight" />
   <java-symbol type="bool" name="config_animateScreenLights" />
   <java-symbol type="bool" name="config_automatic_brightness_available" />
+  <java-symbol type="bool" name="config_dozeAfterScreenOff" />
   <java-symbol type="bool" name="config_enableActivityRecognitionHardwareOverlay" />
   <java-symbol type="bool" name="config_enableFusedLocationOverlay" />
   <java-symbol type="bool" name="config_enableHardwareFlpOverlay" />
@@ -1557,6 +1621,7 @@
   <java-symbol type="integer" name="config_screenBrightnessSettingMinimum" />
   <java-symbol type="integer" name="config_screenBrightnessSettingMaximum" />
   <java-symbol type="integer" name="config_screenBrightnessSettingDefault" />
+  <java-symbol type="integer" name="config_screenBrightnessDark" />
   <java-symbol type="integer" name="config_screenBrightnessDim" />
   <java-symbol type="integer" name="config_screenBrightnessDoze" />
   <java-symbol type="integer" name="config_shutdownBatteryTemperature" />
@@ -1621,6 +1686,7 @@
   <java-symbol type="string" name="hardware" />
   <java-symbol type="string" name="heavy_weight_notification" />
   <java-symbol type="string" name="heavy_weight_notification_detail" />
+  <java-symbol type="string" name="image_wallpaper_component" />
   <java-symbol type="string" name="input_method_binding_label" />
   <java-symbol type="string" name="launch_warning_original" />
   <java-symbol type="string" name="launch_warning_replace" />
@@ -1705,16 +1771,16 @@
   <java-symbol type="layout" name="notification_template_material_inbox" />
   <java-symbol type="layout" name="notification_template_material_media" />
   <java-symbol type="layout" name="notification_template_material_big_media" />
+  <java-symbol type="layout" name="notification_template_material_big_media_narrow" />
+  <java-symbol type="layout" name="notification_template_material_big_text" />
   <java-symbol type="layout" name="notification_template_icon_group" />
   <java-symbol type="layout" name="notification_material_media_action" />
-  <java-symbol type="color" name="notification_action_legacy_color_filter" />
+  <java-symbol type="color" name="notification_action_color_filter" />
   <java-symbol type="color" name="notification_icon_bg_color" />
   <java-symbol type="drawable" name="notification_icon_legacy_bg" />
-  <java-symbol type="drawable" name="notification_icon_legacy_bg_inset" />
-  <java-symbol type="drawable" name="notification_material_media_progress" />
-  <java-symbol type="color" name="notification_media_action_bg" />
-  <java-symbol type="color" name="notification_media_progress" />
-  <java-symbol type="id" name="media_action_area" />
+  <java-symbol type="color" name="notification_media_primary_color" />
+  <java-symbol type="color" name="notification_media_secondary_color" />
+  <java-symbol type="id" name="media_actions" />
 
     <!-- From SystemUI -->
   <java-symbol type="anim" name="push_down_in" />
@@ -1901,6 +1967,9 @@
   <java-symbol type="string" name="timepicker_transition_end_radius_multiplier" />
   <java-symbol type="string" name="battery_saver_description" />
   <java-symbol type="string" name="downtime_condition_summary" />
+  <java-symbol type="string" name="zen_mode_forever" />
+  <java-symbol type="plurals" name="zen_mode_duration_minutes" />
+  <java-symbol type="plurals" name="zen_mode_duration_hours" />
 
   <java-symbol type="string" name="item_is_selected" />
   <java-symbol type="string" name="day_of_week_label_typeface" />
@@ -1956,6 +2025,8 @@
   <java-symbol type="attr" name="preferenceFragmentStyle" />
   <java-symbol type="bool" name="skipHoldBeforeMerge" />
   <java-symbol type="bool" name="imsServiceAllowTurnOff" />
+  <java-symbol type="bool" name="config_device_volte_vt_available" />
+  <java-symbol type="bool" name="config_carrier_volte_vt_available" />
   <java-symbol type="bool" name="useImsAlwaysForEmergencyCall" />
   <java-symbol type="attr" name="touchscreenBlocksFocus" />
   <java-symbol type="layout" name="resolver_list_with_default" />
@@ -1966,7 +2037,6 @@
   <java-symbol type="string" name="whichEditApplicationNamed" />
   <java-symbol type="string" name="whichSendApplication" />
   <java-symbol type="string" name="whichSendApplicationNamed" />
-  <java-symbol type="attr" name="lightingStyle" />
   <java-symbol type="attr" name="lightY" />
   <java-symbol type="attr" name="lightZ" />
   <java-symbol type="attr" name="lightRadius" />
@@ -1976,10 +2046,22 @@
   <java-symbol type="attr" name="headerSelectedTextColor" />
   <java-symbol type="attr" name="amPmSelectedBackgroundColor" />
   <java-symbol type="bool" name="config_sms_decode_gsm_8bit_data" />
-  <java-symbol type="string" name="time_picker_am_label" />
-  <java-symbol type="string" name="time_picker_pm_label" />
   <java-symbol type="dimen" name="text_size_small_material" />
   <java-symbol type="attr" name="checkMarkGravity" />
   <java-symbol type="layout" name="select_dialog_singlechoice_material" />
   <java-symbol type="layout" name="select_dialog_multichoice_material" />
+  <java-symbol type="array" name="no_ems_support_sim_operators" />
+  <java-symbol type="color" name="battery_saver_mode_color" />
+  <java-symbol type="color" name="system_notification_accent_color" />
+  <java-symbol type="dimen" name="text_handle_min_size" />
+  <java-symbol type="id" name="transitionTransform" />
+  <java-symbol type="id" name="parentMatrix" />
+  <java-symbol type="bool" name="config_auto_attach_data_on_creation" />
+  <java-symbol type="id" name="date_picker_month_day_year_layout" />
+  <java-symbol type="attr" name="closeItemLayout" />
+  <java-symbol type="layout" name="resolver_different_item_header" />
+  <java-symbol type="array" name="config_default_vm_number" />
+  <java-symbol type="integer" name="config_cdma_3waycall_flash_delay"/>
+  <java-symbol type="attr" name="windowBackgroundFallback" />
+  <java-symbol type="id" name="textSpacerNoButtons" />
 </resources>
diff --git a/core/res/res/values/themes.xml b/core/res/res/values/themes.xml
index b36cdb9..0577659 100644
--- a/core/res/res/values/themes.xml
+++ b/core/res/res/values/themes.xml
@@ -116,12 +116,12 @@
 
         <!-- Button styles -->
         <item name="buttonStyle">@style/Widget.Button</item>
-
         <item name="buttonStyleSmall">@style/Widget.Button.Small</item>
         <item name="buttonStyleInset">@style/Widget.Button.Inset</item>
-
         <item name="buttonStyleToggle">@style/Widget.Button.Toggle</item>
 
+        <item name="switchStyle">@style/Widget.CompoundButton.Switch</item>
+
         <item name="selectableItemBackground">@drawable/item_background</item>
         <item name="selectableItemBackgroundBorderless">?attr/selectableItemBackground</item>
         <item name="borderlessButtonStyle">?attr/buttonStyle</item>
@@ -169,6 +169,7 @@
 
         <!-- Window attributes -->
         <item name="windowBackground">@drawable/screen_background_selector_dark</item>
+        <item name="windowBackgroundFallback">?attr/colorBackground</item>
         <item name="windowClipToOutline">false</item>
         <item name="windowFrame">@null</item>
         <item name="windowNoTitle">false</item>
@@ -192,6 +193,7 @@
         <item name="navigationBarColor">@color/black</item>
         <item name="windowActionBarFullscreenDecorLayout">@layout/screen_action_bar</item>
         <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">false</item>
 
         <!-- Define these here; ContextThemeWrappers around themes that define them should
              always clear these values. -->
@@ -410,14 +412,19 @@
         <item name="fastScrollPreviewBackgroundLeft">@drawable/menu_submenu_background</item>
         <item name="fastScrollOverlayPosition">floating</item>
         <item name="fastScrollTextColor">@color/primary_text_dark</item>
+
         <!-- Pointer style -->
         <item name="pointerStyle">@style/Pointer</item>
 
-        <!-- Accessibility focused drawable. -->
+        <!-- Accessibility focused drawable -->
         <item name="accessibilityFocusedDrawable">@drawable/view_accessibility_focused</item>
 
-        <!-- Lighting and shadow style. -->
-        <item name="lightingStyle">@style/Lighting</item>
+        <!-- Lighting and shadow properties -->
+        <item name="lightY">@dimen/light_y</item>
+        <item name="lightZ">@dimen/light_z</item>
+        <item name="lightRadius">@dimen/light_radius</item>
+        <item name="ambientShadowAlpha">@dimen/ambient_shadow_alpha</item>
+        <item name="spotShadowAlpha">@dimen/spot_shadow_alpha</item>
     </style>
 
     <!-- Variant of {@link #Theme} with no title bar -->
@@ -811,6 +818,7 @@
     <!-- Theme for the dialog shown when an app crashes or ANRs. -->
     <style name="Theme.Dialog.AppError" parent="Theme.DeviceDefault.Light.Dialog.Alert">
         <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">false</item>
         <item name="windowCloseOnTouchOutside">false</item>
     </style>
 
@@ -822,6 +830,7 @@
         <item name="textColor">@color/secondary_text_nofocus</item>
         <item name="windowCloseOnTouchOutside">false</item>
         <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">false</item>
     </style>
 
     <!-- Theme for a window that looks like a toast. -->
@@ -831,6 +840,7 @@
         <item name="backgroundDimEnabled">false</item>
         <item name="windowCloseOnTouchOutside">false</item>
         <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">false</item>
     </style>
 
 </resources>
diff --git a/core/res/res/values/themes_leanback.xml b/core/res/res/values/themes_leanback.xml
index 0a2c0a4..82cf288 100644
--- a/core/res/res/values/themes_leanback.xml
+++ b/core/res/res/values/themes_leanback.xml
@@ -14,12 +14,43 @@
      limitations under the License.
 -->
 <resources>
+    <style name="Theme.Leanback.Dialog" parent="Theme.Material.BaseDialog">
+      <item name="colorBackground">@color/background_leanback_dark</item>
+      <item name="textColorPrimary">@color/primary_text_leanback_dark</item>
+      <item name="textColorSecondary">@color/secondary_text_leanback_dark</item>
+      <item name="alertDialogStyle">@style/AlertDialog.Leanback</item>
+      <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+      <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
+      <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
+    </style>
+
+    <style name="Theme.Leanback.Light.Dialog" parent="Theme.Material.Light.BaseDialog">
+      <item name="colorBackground">@color/background_leanback_dark</item>
+      <item name="textColorPrimary">@color/primary_text_leanback_dark</item>
+      <item name="textColorSecondary">@color/secondary_text_leanback_dark</item>
+      <item name="alertDialogStyle">@style/AlertDialog.Leanback</item>
+      <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+      <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
+      <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
+    </style>
+
+    <style name="Theme.Leanback.Settings.Dialog" parent="Theme.Material.Settings.BaseDialog">
+        <item name="colorBackground">@color/background_leanback_dark</item>
+        <item name="textColorPrimary">@color/primary_text_leanback_dark</item>
+        <item name="textColorSecondary">@color/secondary_text_leanback_dark</item>
+        <item name="alertDialogStyle">@style/AlertDialog.Leanback</item>
+        <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+        <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
+        <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
+    </style>
+
     <style name="Theme.Leanback.Dialog.Alert" parent="Theme.Material.Dialog.BaseAlert">
       <item name="colorBackground">@color/background_leanback_dark</item>
       <item name="textColorPrimary">@color/primary_text_leanback_dark</item>
       <item name="textColorSecondary">@color/secondary_text_leanback_dark</item>
       <item name="alertDialogStyle">@style/AlertDialog.Leanback</item>
       <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+      <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
       <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
     </style>
 
@@ -29,22 +60,24 @@
       <item name="textColorSecondary">@color/secondary_text_leanback_light</item>
       <item name="alertDialogStyle">@style/AlertDialog.Leanback.Light</item>
       <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+      <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
       <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
     </style>
 
-    <style name="Theme.Leanback.Light.Dialog" parent="Theme.Material.Light.Dialog">
-    </style>
-
-    <style name="Theme.Leanback.Dialog" parent="Theme.Material.Dialog">
+    <style name="Theme.Leanback.Settings.Dialog.Alert" parent="Theme.Material.Settings.Dialog.BaseAlert">
+        <item name="colorBackground">@color/background_leanback_light</item>
+        <item name="textColorPrimary">@color/primary_text_leanback_light</item>
+        <item name="textColorSecondary">@color/secondary_text_leanback_light</item>
+        <item name="alertDialogStyle">@style/AlertDialog.Leanback.Light</item>
+        <item name="timePickerStyle">@style/Widget.Leanback.TimePicker</item>
+        <item name="datePickerStyle">@style/Widget.Leanback.DatePicker</item>
+        <item name="numberPickerStyle">@style/Widget.Leanback.NumberPicker</item>
     </style>
 
     <style name="Theme.Leanback.Dialog.AppError" parent="Theme.Leanback.Dialog">
-        <item name="windowFrame">@null</item>
-        <item name="windowBackground">@color/transparent</item>
-        <item name="windowIsFloating">true</item>
-        <item name="windowContentOverlay">@null</item>
+        <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">false</item>
         <item name="windowCloseOnTouchOutside">false</item>
-        <item name="alertDialogStyle">@style/AlertDialog.Leanback</item>
     </style>
 
     <!-- Setup and form wizard themes @hide @SystemApi-->
diff --git a/core/res/res/values/themes_material.xml b/core/res/res/values/themes_material.xml
index 691ddb1..ebff965 100644
--- a/core/res/res/values/themes_material.xml
+++ b/core/res/res/values/themes_material.xml
@@ -46,7 +46,7 @@
         <item name="colorForegroundInverse">@color/bright_foreground_material_light</item>
         <item name="colorBackground">@color/background_material_dark</item>
         <item name="colorBackgroundCacheHint">@color/background_cache_hint_selector_material_dark</item>
-        <item name="disabledAlpha">@dimen/disabled_alpha_material</item>
+        <item name="disabledAlpha">@dimen/disabled_alpha_material_dark</item>
         <item name="backgroundDimAmount">0.6</item>
 
         <!-- Text styles -->
@@ -58,14 +58,14 @@
         <item name="textColorPrimaryDisableOnly">@color/primary_text_disable_only_material_dark</item>
         <item name="textColorSecondary">@color/secondary_text_material_dark</item>
         <item name="textColorSecondaryInverse">@color/secondary_text_material_light</item>
-        <item name="textColorTertiary">@color/tertiary_text_material_dark</item>
-        <item name="textColorTertiaryInverse">@color/tertiary_text_material_light</item>
+        <item name="textColorTertiary">@color/secondary_text_material_dark</item>
+        <item name="textColorTertiaryInverse">@color/secondary_text_material_light</item>
         <item name="textColorHint">@color/hint_foreground_material_dark</item>
         <item name="textColorHintInverse">@color/hint_foreground_material_light</item>
         <item name="textColorHighlight">@color/highlighted_text_material_dark</item>
         <item name="textColorHighlightInverse">@color/highlighted_text_material_light</item>
-        <item name="textColorLink">@color/material_teal_500</item>
-        <item name="textColorLinkInverse">@color/material_teal_500</item>
+        <item name="textColorLink">@color/link_text_material_dark</item>
+        <item name="textColorLinkInverse">@color/link_text_material_light</item>
         <item name="textColorSearchUrl">@color/search_url_text_material_dark</item>
         <item name="textColorAlertDialogListItem">@color/primary_text_material_dark</item>
 
@@ -129,7 +129,7 @@
         <item name="listChoiceBackgroundIndicator">?attr/selectableItemBackground</item>
         <item name="activatedBackgroundIndicator">@drawable/activated_background_material</item>
 
-        <item name="listDividerAlertDialog">@drawable/list_divider_material</item>
+        <item name="listDividerAlertDialog">@null</item>
 
         <item name="expandableListPreferredItemPaddingLeft">40dip</item>
         <item name="expandableListPreferredChildPaddingLeft">?attr/expandableListPreferredItemPaddingLeft</item>
@@ -145,7 +145,7 @@
         <item name="galleryItemBackground">@drawable/gallery_item_background</item>
 
         <!-- Window attributes -->
-        <item name="windowBackground">@color/background_material_dark</item>
+        <item name="windowBackground">?attr/colorBackground</item>
         <item name="windowClipToOutline">true</item>
         <item name="windowFrame">@null</item>
         <item name="windowNoTitle">false</item>
@@ -157,7 +157,8 @@
         <item name="windowTitleStyle">@style/WindowTitle.Material</item>
         <item name="windowTitleSize">@dimen/action_bar_default_height_material</item>
         <item name="windowTitleBackgroundStyle">@style/WindowTitleBackground.Material</item>
-        <item name="windowContentTransitions">true</item>
+        <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">true</item>
         <item name="windowAnimationStyle">@style/Animation.Material.Activity</item>
         <item name="windowSoftInputMode">stateUnspecified|adjustUnspecified</item>
         <item name="windowActionBar">true</item>
@@ -306,7 +307,7 @@
         <item name="actionOverflowMenuStyle">@style/Widget.Material.PopupMenu.Overflow</item>
         <item name="actionModeBackground">@drawable/cab_background_top_material</item>
         <item name="actionModeSplitBackground">@drawable/cab_background_bottom_material</item>
-        <item name="actionModeCloseDrawable">@drawable/ic_cab_done_material</item>
+        <item name="actionModeCloseDrawable">@drawable/ic_ab_back_material</item>
         <item name="actionBarTabStyle">@style/Widget.Material.ActionBar.TabView</item>
         <item name="actionBarTabBarStyle">@style/Widget.Material.ActionBar.TabBar</item>
         <item name="actionBarTabTextStyle">@style/Widget.Material.ActionBar.TabText</item>
@@ -315,6 +316,8 @@
         <item name="actionBarStyle">@style/Widget.Material.ActionBar.Solid</item>
         <item name="actionBarSize">@dimen/action_bar_default_height_material</item>
         <item name="actionModePopupWindowStyle">@style/Widget.Material.PopupWindow.ActionMode</item>
+        <item name="actionMenuTextAppearance">@style/TextAppearance.Material.Widget.ActionBar.Menu</item>
+        <item name="actionMenuTextColor">?attr/textColorPrimary</item>
         <item name="actionBarWidgetTheme">@null</item>
         <item name="actionBarPopupTheme">@null</item>
         <item name="actionBarTheme">@style/ThemeOverlay.Material.ActionBar</item>
@@ -333,8 +336,7 @@
         <item name="dividerVertical">?attr/listDivider</item>
         <item name="dividerHorizontal">?attr/listDivider</item>
         <item name="buttonBarStyle">@style/Widget.Material.ButtonBar</item>
-        <item name="buttonBarButtonStyle">@style/Widget.Material.Button.Borderless</item>
-        <item name="buttonBarPositiveButtonStyle">@style/Widget.Material.Button.Borderless.Colored</item>
+        <item name="buttonBarButtonStyle">@style/Widget.Material.Button.ButtonBar.AlertDialog</item>
         <item name="segmentedButtonStyle">@style/Widget.Material.SegmentedButton</item>
 
         <!-- SearchView attributes -->
@@ -357,28 +359,29 @@
         <item name="timePickerDialogTheme">?attr/dialogTheme</item>
 
         <!-- DatePicker style -->
-        <item name="datePickerStyle">?attr/dialogTheme</item>
+        <item name="datePickerStyle">@style/Widget.Material.DatePicker</item>
 
         <!-- DatePicker dialog theme -->
-        <item name="datePickerDialogTheme">@style/Theme.Material.Dialog.Alert</item>
+        <item name="datePickerDialogTheme">?attr/dialogTheme</item>
 
         <!-- TODO: This belongs in a FastScroll style -->
         <item name="fastScrollThumbDrawable">@drawable/fastscroll_thumb_material</item>
-        <item name="fastScrollPreviewBackgroundLeft">@drawable/fastscroll_label_left_holo_dark</item>
-        <item name="fastScrollPreviewBackgroundRight">@drawable/fastscroll_label_right_holo_dark</item>
+        <item name="fastScrollPreviewBackgroundLeft">@drawable/fastscroll_label_left_material</item>
+        <item name="fastScrollPreviewBackgroundRight">@drawable/fastscroll_label_right_material</item>
         <item name="fastScrollTrackDrawable">@drawable/fastscroll_track_material</item>
-        <item name="fastScrollOverlayPosition">atThumb</item>
+        <item name="fastScrollOverlayPosition">aboveThumb</item>
 
         <!-- Color palette -->
         <item name="colorPrimaryDark">@color/material_blue_grey_900</item>
         <item name="colorPrimary">@color/material_blue_grey_800</item>
-        <item name="colorAccent">@color/material_deep_teal_A200</item>
+        <item name="colorAccent">@color/material_deep_teal_200</item>
 
         <item name="colorControlNormal">?attr/textColorSecondary</item>
         <item name="colorControlActivated">?attr/colorAccent</item>
 
         <item name="colorControlHighlight">@color/ripple_material_dark</item>
         <item name="colorButtonNormal">@color/btn_default_material_dark</item>
+        <item name="colorSwitchThumbNormal">@color/switch_thumb_material_dark</item>
     </style>
 
     <!-- Material theme (light version). -->
@@ -387,7 +390,7 @@
         <item name="colorForegroundInverse">@color/bright_foreground_material_dark</item>
         <item name="colorBackground">@color/background_material_light</item>
         <item name="colorBackgroundCacheHint">@color/background_cache_hint_selector_material_light</item>
-        <item name="disabledAlpha">@dimen/disabled_alpha_material</item>
+        <item name="disabledAlpha">@dimen/disabled_alpha_material_light</item>
         <item name="backgroundDimAmount">0.6</item>
 
         <!-- Text styles -->
@@ -398,16 +401,16 @@
         <item name="textColorPrimaryInverse">@color/primary_text_material_dark</item>
         <item name="textColorSecondary">@color/secondary_text_material_light</item>
         <item name="textColorSecondaryInverse">@color/secondary_text_material_dark</item>
-        <item name="textColorTertiary">@color/tertiary_text_material_light</item>
-        <item name="textColorTertiaryInverse">@color/tertiary_text_material_dark</item>
+        <item name="textColorTertiary">@color/secondary_text_material_light</item>
+        <item name="textColorTertiaryInverse">@color/secondary_text_material_dark</item>
         <item name="textColorPrimaryDisableOnly">@color/primary_text_disable_only_material_light</item>
         <item name="textColorPrimaryInverseDisableOnly">@color/primary_text_disable_only_material_dark</item>
         <item name="textColorHint">@color/hint_foreground_material_light</item>
         <item name="textColorHintInverse">@color/hint_foreground_material_dark</item>
         <item name="textColorHighlight">@color/highlighted_text_material_light</item>
         <item name="textColorHighlightInverse">@color/highlighted_text_material_dark</item>
-        <item name="textColorLink">@color/material_teal_500</item>
-        <item name="textColorLinkInverse">@color/material_teal_500</item>
+        <item name="textColorLink">@color/link_text_material_light</item>
+        <item name="textColorLinkInverse">@color/link_text_material_dark</item>
         <item name="textColorSearchUrl">@color/search_url_text_material_light</item>
         <item name="textColorAlertDialogListItem">@color/primary_text_material_light</item>
 
@@ -480,7 +483,7 @@
         <item name="expandableListPreferredChildIndicatorLeft">?attr/expandableListPreferredItemIndicatorLeft</item>
         <item name="expandableListPreferredChildIndicatorRight">?attr/expandableListPreferredItemIndicatorRight</item>
 
-        <item name="listDividerAlertDialog">@drawable/list_divider_material</item>
+        <item name="listDividerAlertDialog">@null</item>
         <item name="findOnPageNextDrawable">@drawable/ic_find_next_material</item>
         <item name="findOnPagePreviousDrawable">@drawable/ic_find_previous_material</item>
 
@@ -488,7 +491,7 @@
         <item name="galleryItemBackground">@drawable/gallery_item_background</item>
 
         <!-- Window attributes -->
-        <item name="windowBackground">@color/background_material_light</item>
+        <item name="windowBackground">?attr/colorBackground</item>
         <item name="windowClipToOutline">true</item>
         <item name="windowFrame">@null</item>
         <item name="windowNoTitle">false</item>
@@ -511,7 +514,8 @@
         <item name="windowEnterTransition">@transition/fade</item>
         <item name="windowSharedElementEnterTransition">@transition/move</item>
         <item name="windowSharedElementExitTransition">@transition/move</item>
-        <item name="windowContentTransitions">true</item>
+        <item name="windowContentTransitions">false</item>
+        <item name="windowActivityTransitions">true</item>
 
         <!-- Dialog attributes -->
         <item name="dialogTheme">@style/Theme.Material.Light.Dialog</item>
@@ -652,7 +656,7 @@
         <item name="actionOverflowMenuStyle">@style/Widget.Material.Light.PopupMenu.Overflow</item>
         <item name="actionModeBackground">@drawable/cab_background_top_material</item>
         <item name="actionModeSplitBackground">@drawable/cab_background_bottom_material</item>
-        <item name="actionModeCloseDrawable">@drawable/ic_cab_done_material</item>
+        <item name="actionModeCloseDrawable">@drawable/ic_ab_back_material</item>
         <item name="actionBarTabStyle">@style/Widget.Material.Light.ActionBar.TabView</item>
         <item name="actionBarTabBarStyle">@style/Widget.Material.Light.ActionBar.TabBar</item>
         <item name="actionBarTabTextStyle">@style/Widget.Material.Light.ActionBar.TabText</item>
@@ -679,8 +683,7 @@
         <item name="dividerVertical">?attr/listDivider</item>
         <item name="dividerHorizontal">?attr/listDivider</item>
         <item name="buttonBarStyle">@style/Widget.Material.Light.ButtonBar</item>
-        <item name="buttonBarButtonStyle">@style/Widget.Material.Light.Button.Borderless</item>
-        <item name="buttonBarPositiveButtonStyle">@style/Widget.Material.Light.Button.Borderless.Colored</item>
+        <item name="buttonBarButtonStyle">@style/Widget.Material.Light.Button.ButtonBar.AlertDialog</item>
         <item name="segmentedButtonStyle">@style/Widget.Material.Light.SegmentedButton</item>
 
         <!-- SearchView attributes -->
@@ -706,21 +709,22 @@
         <item name="datePickerDialogTheme">?attr/dialogTheme</item>
 
         <item name="fastScrollThumbDrawable">@drawable/fastscroll_thumb_material</item>
-        <item name="fastScrollPreviewBackgroundLeft">@drawable/fastscroll_label_left_holo_light</item>
-        <item name="fastScrollPreviewBackgroundRight">@drawable/fastscroll_label_right_holo_light</item>
+        <item name="fastScrollPreviewBackgroundLeft">@drawable/fastscroll_label_left_material</item>
+        <item name="fastScrollPreviewBackgroundRight">@drawable/fastscroll_label_right_material</item>
         <item name="fastScrollTrackDrawable">@drawable/fastscroll_track_material</item>
-        <item name="fastScrollOverlayPosition">atThumb</item>
+        <item name="fastScrollOverlayPosition">aboveThumb</item>
 
         <!-- Color palette -->
         <item name="colorPrimaryDark">@color/material_blue_grey_100</item>
         <item name="colorPrimary">@color/material_blue_grey_50</item>
-        <item name="colorAccent">@color/material_deep_teal_A500</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
 
         <item name="colorControlNormal">?attr/textColorSecondary</item>
         <item name="colorControlActivated">?attr/colorAccent</item>
 
         <item name="colorControlHighlight">@color/ripple_material_light</item>
         <item name="colorButtonNormal">@color/btn_default_material_light</item>
+        <item name="colorSwitchThumbNormal">@color/switch_thumb_material_light</item>
     </style>
 
     <!-- Variant of the material (light) theme that has a solid (opaque) action bar
@@ -750,16 +754,16 @@
         <item name="textColorPrimaryInverse">@color/primary_text_material_dark</item>
         <item name="textColorSecondary">@color/secondary_text_material_light</item>
         <item name="textColorSecondaryInverse">@color/secondary_text_material_dark</item>
-        <item name="textColorTertiary">@color/tertiary_text_material_light</item>
-        <item name="textColorTertiaryInverse">@color/tertiary_text_material_dark</item>
+        <item name="textColorTertiary">@color/secondary_text_material_light</item>
+        <item name="textColorTertiaryInverse">@color/secondary_text_material_dark</item>
         <item name="textColorPrimaryDisableOnly">@color/primary_text_disable_only_material_light</item>
         <item name="textColorPrimaryInverseDisableOnly">@color/primary_text_disable_only_material_dark</item>
         <item name="textColorHint">@color/hint_foreground_material_light</item>
         <item name="textColorHintInverse">@color/hint_foreground_material_dark</item>
         <item name="textColorHighlight">@color/highlighted_text_material_light</item>
         <item name="textColorHighlightInverse">@color/highlighted_text_material_dark</item>
-        <item name="textColorLink">@color/material_teal_500</item>
-        <item name="textColorLinkInverse">@color/material_teal_500</item>
+        <item name="textColorLink">@color/link_text_material_light</item>
+        <item name="textColorLinkInverse">@color/link_text_material_dark</item>
         <item name="textColorSearchUrl">@color/search_url_text_material_light</item>
         <item name="textColorAlertDialogListItem">@color/primary_text_material_light</item>
 
@@ -774,6 +778,7 @@
         <item name="colorControlNormal">?attr/textColorSecondary</item>
         <item name="colorControlHighlight">@color/ripple_material_light</item>
         <item name="colorButtonNormal">@color/btn_default_material_light</item>
+        <item name="colorSwitchThumbNormal">@color/switch_thumb_material_light</item>
     </style>
 
     <!-- Theme overlay that replaces colors with their dark versions but preserves
@@ -789,14 +794,14 @@
         <item name="textColorPrimaryDisableOnly">@color/primary_text_disable_only_material_dark</item>
         <item name="textColorSecondary">@color/secondary_text_material_dark</item>
         <item name="textColorSecondaryInverse">@color/secondary_text_material_light</item>
-        <item name="textColorTertiary">@color/tertiary_text_material_dark</item>
-        <item name="textColorTertiaryInverse">@color/tertiary_text_material_light</item>
+        <item name="textColorTertiary">@color/secondary_text_material_dark</item>
+        <item name="textColorTertiaryInverse">@color/secondary_text_material_light</item>
         <item name="textColorHint">@color/hint_foreground_material_dark</item>
         <item name="textColorHintInverse">@color/hint_foreground_material_light</item>
         <item name="textColorHighlight">@color/highlighted_text_material_dark</item>
         <item name="textColorHighlightInverse">@color/highlighted_text_material_light</item>
-        <item name="textColorLink">@color/material_teal_500</item>
-        <item name="textColorLinkInverse">@color/material_teal_500</item>
+        <item name="textColorLink">@color/link_text_material_dark</item>
+        <item name="textColorLinkInverse">@color/link_text_material_light</item>
         <item name="textColorSearchUrl">@color/search_url_text_material_dark</item>
         <item name="textColorAlertDialogListItem">@color/primary_text_material_dark</item>
 
@@ -811,6 +816,7 @@
         <item name="colorControlNormal">?attr/textColorSecondary</item>
         <item name="colorControlHighlight">@color/ripple_material_dark</item>
         <item name="colorButtonNormal">@color/btn_default_material_dark</item>
+        <item name="colorSwitchThumbNormal">@color/switch_thumb_material_dark</item>
     </style>
 
     <!-- Theme overlay that replaces the normal control color, which by default is the same as the
@@ -985,12 +991,7 @@
     <!-- Dialog themes for Material -->
     <eat-comment />
 
-    <!-- Material theme for dialog windows and activities, which is used by the
-         {@link android.app.Dialog} class.  This changes the window to be
-         floating (not fill the entire screen), and puts a frame around its
-         contents.  You can set this theme on an activity if you would like to
-         make an activity that looks like a Dialog. -->
-    <style name="Theme.Material.Dialog">
+    <style name="Theme.Material.BaseDialog">
         <item name="windowFrame">@null</item>
         <item name="windowTitleStyle">@style/DialogWindowTitle.Material</item>
         <item name="windowBackground">@drawable/dialog_background_material</item>
@@ -1016,9 +1017,18 @@
         <item name="listPreferredItemPaddingStart">16dip</item>
         <item name="listPreferredItemPaddingEnd">16dip</item>
 
+        <item name="listDivider">@null</item>
+
         <item name="preferencePanelStyle">@style/PreferencePanel.Dialog</item>
     </style>
 
+    <!-- Material theme for dialog windows and activities, which is used by the
+         {@link android.app.Dialog} class.  This changes the window to be
+         floating (not fill the entire screen), and puts a frame around its
+         contents.  You can set this theme on an activity if you would like to
+         make an activity that looks like a Dialog. -->
+    <style name="Theme.Material.Dialog" parent="Theme.Material.BaseDialog"/>
+
     <!-- Variant of Theme.Material.Dialog that has a nice minimum width for
          a regular dialog. -->
     <style name="Theme.Material.Dialog.MinWidth">
@@ -1095,12 +1105,7 @@
 
     <!-- Light material dialog themes -->
 
-    <!-- Material light theme for dialog windows and activities, which is used by the
-         {@link android.app.Dialog} class.  This changes the window to be
-         floating (not fill the entire screen), and puts a frame around its
-         contents.  You can set this theme on an activity if you would like to
-         make an activity that looks like a Dialog. -->
-    <style name="Theme.Material.Light.Dialog">
+    <style name="Theme.Material.Light.BaseDialog">
         <item name="windowFrame">@null</item>
         <item name="windowTitleStyle">@style/DialogWindowTitle.Material.Light</item>
         <item name="windowBackground">@drawable/dialog_background_material</item>
@@ -1126,9 +1131,18 @@
         <item name="listPreferredItemPaddingStart">16dip</item>
         <item name="listPreferredItemPaddingEnd">16dip</item>
 
+        <item name="listDivider">@null</item>
+
         <item name="preferencePanelStyle">@style/PreferencePanel.Dialog</item>
     </style>
 
+    <!-- Material light theme for dialog windows and activities, which is used by the
+         {@link android.app.Dialog} class.  This changes the window to be
+         floating (not fill the entire screen), and puts a frame around its
+         contents.  You can set this theme on an activity if you would like to
+         make an activity that looks like a Dialog. -->
+    <style name="Theme.Material.Light.Dialog" parent="Theme.Material.Light.BaseDialog"/>
+
     <!-- Variant of Theme.Material.Light.Dialog that has a nice minimum width for
          a regular dialog. -->
     <style name="Theme.Material.Light.Dialog.MinWidth">
@@ -1188,7 +1202,7 @@
     <style name="Theme.Material.Light.Dialog.Alert" parent="Theme.Material.Light.Dialog.BaseAlert"/>
 
     <!-- Theme for a presentation window on a secondary display. -->
-    <style name="Theme.Material.Light.Dialog.Presentation" parent="@style/Theme.Material.Light.NoActionBar.Fullscreen" />
+    <style name="Theme.Material.Light.Dialog.Presentation" parent="Theme.Material.Light.NoActionBar.Fullscreen" />
 
     <!-- Default material (dark) for windows that want to have the user's selected
          wallpaper appear behind them.  -->
@@ -1205,10 +1219,49 @@
     </style>
 
     <!-- Default theme for Settings and activities launched from Settings. -->
-    <style name="Theme.Material.Settings" parent="@style/Theme.Material.Light.DarkActionBar">
+    <style name="Theme.Material.Settings" parent="Theme.Material.Light.DarkActionBar">
         <item name="colorPrimary">@color/material_blue_grey_900</item>
         <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
-        <item name="colorAccent">@color/material_deep_teal_A500</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+
+        <item name="dialogTheme">@style/Theme.Material.Settings.Dialog</item>
+        <item name="alertDialogTheme">@style/Theme.Material.Settings.Dialog.Alert</item>
+        <item name="presentationTheme">@style/Theme.Material.Settings.Dialog.Presentation</item>
+        <item name="searchDialogTheme">@style/Theme.Material.Settings.SearchBar</item>
+        <item name="panelMenuListTheme">@style/Theme.Material.Settings.CompactMenu</item>
     </style>
 
+    <style name="Theme.Material.Settings.BaseDialog" parent="Theme.Material.Light.BaseDialog">
+        <item name="colorPrimary">@color/material_blue_grey_900</item>
+        <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+    </style>
+
+    <style name="Theme.Material.Settings.Dialog" parent="Theme.Material.Settings.BaseDialog" />
+
+    <style name="Theme.Material.Settings.Dialog.BaseAlert" parent="Theme.Material.Light.Dialog.BaseAlert">
+        <item name="colorPrimary">@color/material_blue_grey_900</item>
+        <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+    </style>
+
+    <style name="Theme.Material.Settings.Dialog.Alert" parent="Theme.Material.Settings.Dialog.BaseAlert" />
+
+    <style name="Theme.Material.Settings.Dialog.Presentation" parent="Theme.Material.Light.Dialog.Presentation">
+        <item name="colorPrimary">@color/material_blue_grey_900</item>
+        <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+    </style>
+
+    <style name="Theme.Material.Settings.SearchBar" parent="Theme.Material.Light.SearchBar">
+        <item name="colorPrimary">@color/material_blue_grey_900</item>
+        <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+    </style>
+
+    <style name="Theme.Material.Settings.CompactMenu" parent="Theme.Material.Light.CompactMenu">
+        <item name="colorPrimary">@color/material_blue_grey_900</item>
+        <item name="colorPrimaryDark">@color/material_blue_grey_950</item>
+        <item name="colorAccent">@color/material_deep_teal_500</item>
+    </style>
 </resources>
diff --git a/core/res/res/xml/tv_content_rating_systems.xml b/core/res/res/xml/tv_content_rating_systems.xml
deleted file mode 100644
index 1318274..0000000
--- a/core/res/res/xml/tv_content_rating_systems.xml
+++ /dev/null
@@ -1,1744 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/*
-** Copyright 2014, 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.
-*/
--->
-<rating-system-definitions version="1.0">
-    <!-- Range specific TV content rating system for AM TV-->
-    <rating-system-definition id="AM_TV_RS"
-        displayName="@string/display_name_amtvrs"
-        description="@string/description_amtvrs"
-        country="AM">
-        <rating-definition id="AM_TV_RS_Y"
-            displayName="@string/display_name_amtvrs_y"
-            description="@string/description_amtvrs_y"
-            ageHint="2" />
-        <rating-definition id="AM_TV_RS_Y7"
-            displayName="@string/display_name_amtvrs_y7"
-            description="@string/description_amtvrs_y7"
-            ageHint="7" />
-        <rating-definition id="AM_TV_RS_GA"
-            displayName="@string/display_name_amtvrs_ga"
-            description="@string/description_amtvrs_ga"
-            ageHint="0" />
-        <rating-definition id="AM_TV_RS_TW"
-            displayName="@string/display_name_amtvrs_tw"
-            description="@string/description_amtvrs_tw"
-            ageHint="9" />
-        <rating-definition id="AM_TV_RS_T"
-            displayName="@string/display_name_amtvrs_t"
-            description="@string/description_amtvrs_t"
-            ageHint="12" />
-        <rating-definition id="AM_TV_RS_A"
-            displayName="@string/display_name_amtvrs_a"
-            description="@string/description_amtvrs_a"
-            ageHint="18" />
-        <order>
-             <rating id="AM_TV_RS_Y" />
-             <rating id="AM_TV_RS_Y7" />
-        </order>
-        <order>
-            <rating id="AM_TV_RS_GA" />
-            <rating id="AM_TV_RS_TW" />
-            <rating id="AM_TV_RS_T" />
-            <rating id="AM_TV_RS_A" />
-        </order>
-    </rating-system-definition>
-
-    <!-- Age specific TV content rating system for AM TV-->
-    <rating-system-definition id="AM_TV_AS"
-        displayName="@string/display_name_amtvas"
-        description="@string/description_amtvas"
-        country="AM">
-        <rating-definition id="AM_TV_AS_EC"
-            displayName="@string/display_name_amtvas_ec"
-            description="@string/description_amtvas_ec"
-            ageHint="2" />
-        <rating-definition id="AM_TV_AS_E"
-            displayName="@string/display_name_amtvas_e"
-            description="@string/description_amtvas_e"
-            ageHint="5" />
-        <rating-definition id="AM_TV_AS_E9"
-            displayName="@string/display_name_amtvas_e9"
-            description="@string/description_amtvas_e9"
-            ageHint="9" />
-        <rating-definition id="AM_TV_AS_T"
-            displayName="@string/display_name_amtvas_t"
-            description="@string/description_amtvas_t"
-            ageHint="12" />
-        <rating-definition id="AM_TV_AS_M"
-            displayName="@string/display_name_amtvas_m"
-            description="@string/description_amtvas_m"
-            ageHint="16" />
-        <rating-definition id="AM_TV_AS_AO"
-            displayName="@string/display_name_amtvas_ao"
-            description="@string/description_amtvas_ao"
-            ageHint="17" />
-        <order>
-            <rating id="AM_TV_AS_EC" />
-            <rating id="AM_TV_AS_E" />
-            <rating id="AM_TV_AS_E9" />
-            <rating id="AM_TV_AS_T" />
-            <rating id="AM_TV_AS_M" />
-            <rating id="AM_TV_AS_AO" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for AR TV -->
-    <rating-system-definition id="AR_TV"
-        displayName="@string/display_name_artv"
-        country="AR">
-        <rating-definition id="AR_TV_ALL"
-            displayName="@string/display_name_artv_all"
-            description="@string/description_artv_all"
-            ageHint="0" />
-        <rating-definition id="AR_TV_13"
-            displayName="@string/display_name_artv_13"
-            description="@string/description_artv_13"
-            ageHint="13" />
-        <rating-definition id="AR_TV_16"
-            displayName="@string/display_name_artv_16"
-            description="@string/description_artv_16"
-            ageHint="16" />
-        <rating-definition id="AR_TV_18"
-            displayName="@string/display_name_artv_18"
-            description="@string/description_artv_18"
-            ageHint="18" />
-        <order>
-            <rating id="AR_TV_ALL" />
-            <rating id="AR_TV_13" />
-            <rating id="AR_TV_16" />
-            <rating id="AR_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for AU TV -->
-    <rating-system-definition id="AU_TV"
-        displayName="@string/display_name_autv"
-        country="AU">
-        <rating-definition id="AU_TV_CTC"
-            displayName="@string/display_name_autv_ctc"
-            description="@string/description_autv_ctc"
-            ageHint="0" />
-        <rating-definition id="AU_TV_G"
-            displayName="@string/display_name_autv_g"
-            description="@string/description_autv_g"
-            ageHint="0" />
-        <rating-definition id="AU_TV_PG"
-            displayName="@string/display_name_autv_pg"
-            description="@string/description_autv_pg"
-            ageHint="15" />
-        <rating-definition id="AU_TV_M"
-            displayName="@string/display_name_autv_m"
-            description="@string/description_autv_m"
-            ageHint="15" />
-        <rating-definition id="AU_TV_MA15"
-            displayName="@string/display_name_autv_ma15"
-            description="@string/description_autv_ma15"
-            ageHint="15" />
-        <rating-definition id="AU_TV_R18"
-            displayName="@string/display_name_autv_r18"
-            description="@string/description_autv_r18"
-            ageHint="18" />
-        <rating-definition id="AU_TV_X18"
-            displayName="@string/display_name_autv_x18"
-            description="@string/description_autv_x18"
-            ageHint="18" />
-        <order>
-            <rating id="AU_TV_G" />
-            <rating id="AU_TV_PG" />
-            <rating id="AU_TV_M" />
-            <rating id="AU_TV_MA15" />
-            <rating id="AU_TV_R18" />
-            <rating id="AU_TV_X18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for BG TV -->
-    <rating-system-definition id="BG_TV"
-        displayName="@string/display_name_bgtv"
-        country="BG">
-        <rating-definition id="BG_TV_A"
-            displayName="@string/display_name_bgtv_a"
-            description="@string/description_bgtv_a"
-            ageHint="0" />
-        <rating-definition id="BG_TV_B"
-            displayName="@string/display_name_bgtv_b"
-            description="@string/description_bgtv_b"
-            ageHint="0" />
-        <rating-definition id="BG_TV_C"
-            displayName="@string/display_name_bgtv_c"
-            description="@string/description_bgtv_c"
-            ageHint="12" />
-        <rating-definition id="BG_TV_D"
-            displayName="@string/display_name_bgtv_d"
-            description="@string/description_bgtv_d"
-            ageHint="16" />
-        <rating-definition id="BG_TV_X"
-            displayName="@string/display_name_bgtv_x"
-            description="@string/description_bgtv_x"
-            ageHint="18" />
-        <order>
-            <rating id="BG_TV_A" />
-            <rating id="BG_TV_B" />
-            <rating id="BG_TV_C" />
-            <rating id="BG_TV_D" />
-            <rating id="BG_TV_X" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for BR TV -->
-    <rating-system-definition id="BR_TV"
-        displayName="@string/display_name_brtv"
-        country="BR">
-        <rating-definition id="BR_TV_L"
-            displayName="@string/display_name_brtv_l"
-            description="@string/description_brtv_l"
-            ageHint="0" />
-        <rating-definition id="BR_TV_10"
-            displayName="@string/display_name_brtv_10"
-            description="@string/description_brtv_10"
-            ageHint="10" />
-        <rating-definition id="BR_TV_12"
-            displayName="@string/display_name_brtv_12"
-            description="@string/description_brtv_12"
-            ageHint="12" />
-        <rating-definition id="BR_TV_14"
-            displayName="@string/display_name_brtv_14"
-            description="@string/description_brtv_14"
-            ageHint="14" />
-        <rating-definition id="BR_TV_16"
-            displayName="@string/display_name_brtv_16"
-            description="@string/description_brtv_16"
-            ageHint="16" />
-        <rating-definition id="BR_TV_18"
-            displayName="@string/display_name_brtv_18"
-            description="@string/description_brtv_18"
-            ageHint="18" />
-        <order>
-            <rating id="BR_TV_L" />
-            <rating id="BR_TV_10" />
-            <rating id="BR_TV_12" />
-            <rating id="BR_TV_14" />
-            <rating id="BR_TV_16" />
-            <rating id="BR_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for CA TV -->
-    <rating-system-definition id="CA_TV"
-        displayName="@string/display_name_catv"
-        country="CA">
-        <rating-definition id="CA_TV_EXEMPT"
-            displayName="@string/display_name_catv_exempt"
-            description="@string/description_catv_exempt"
-            ageHint="0" />
-        <rating-definition id="CA_TV_C"
-            displayName="@string/display_name_catv_c"
-            description="@string/description_catv_c"
-            ageHint="0" />
-        <rating-definition id="CA_TV_C8"
-            displayName="@string/display_name_catv_c8"
-            description="@string/description_catv_c8"
-            ageHint="8" />
-        <rating-definition id="CA_TV_G"
-            displayName="@string/display_name_catv_g"
-            description="@string/description_catv_g"
-            ageHint="0" />
-        <rating-definition id="CA_TV_PG"
-            displayName="@string/display_name_catv_pg"
-            description="@string/description_catv_pg"
-            ageHint="14" />
-        <rating-definition id="CA_TV_14"
-            displayName="@string/display_name_catv_14"
-            description="@string/description_catv_14"
-            ageHint="14" />
-        <rating-definition id="CA_TV_18"
-            displayName="@string/display_name_catv_18"
-            description="@string/description_catv_18"
-            ageHint="18" />
-        <order>
-            <rating id="CA_TV_C" />
-            <rating id="CA_TV_C8" />
-        </order>
-        <order>
-            <rating id="CA_TV_G" />
-            <rating id="CA_TV_PG" />
-            <rating id="CA_TV_14" />
-            <rating id="CA_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for CH TV -->
-    <rating-system-definition id="CH_TV"
-        displayName="@string/display_name_chtv"
-        country="CH">
-        <rating-definition id="CH_TV_ALL"
-            displayName="@string/display_name_chtv_all"
-            description="@string/description_chtv_all"
-            ageHint="0" />
-        <rating-definition id="CH_TV_RED"
-            displayName="@string/display_name_chtv_red"
-            description="@string/description_chtv_red"
-            ageHint="18" />
-        <order>
-            <rating id="CH_TV_ALL" />
-            <rating id="CH_TV_RED" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for CL TV -->
-    <rating-system-definition id="CL_TV"
-        displayName="@string/display_name_cltv"
-        country="CL">
-        <rating-definition id="CL_TV_I"
-            displayName="@string/display_name_cltv_i"
-            description="@string/description_cltv_i"
-            ageHint="0" />
-        <rating-definition id="CL_TV_I7"
-            displayName="@string/display_name_cltv_i7"
-            description="@string/description_cltv_i7"
-            ageHint="7" />
-        <rating-definition id="CL_TV_I10"
-            displayName="@string/display_name_cltv_i10"
-            description="@string/description_cltv_i10"
-            ageHint="10" />
-        <rating-definition id="CL_TV_I12"
-            displayName="@string/display_name_cltv_i12"
-            description="@string/description_cltv_i12"
-            ageHint="12" />
-        <rating-definition id="CL_TV_F"
-            displayName="@string/display_name_cltv_f"
-            description="@string/description_cltv_f"
-            ageHint="0" />
-        <rating-definition id="CL_TV_R"
-            displayName="@string/display_name_cltv_r"
-            description="@string/description_cltv_r"
-            ageHint="12" />
-        <rating-definition id="CL_TV_A"
-            displayName="@string/display_name_cltv_a"
-            description="@string/description_cltv_a"
-            ageHint="18" />
-        <order>
-            <rating id="CL_TV_I" />
-            <rating id="CL_TV_I7" />
-            <rating id="CL_TV_I10" />
-            <rating id="CL_TV_I12" />
-        </order>
-        <order>
-            <rating id="CL_TV_F" />
-            <rating id="CL_TV_R" />
-            <rating id="CL_TV_A" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for DE TV -->
-    <rating-system-definition id="DE_TV"
-        displayName="@string/display_name_detv"
-        country="DE">
-        <rating-definition id="DE_TV_ALL"
-            displayName="@string/display_name_detv_all"
-            description="@string/description_detv_all"
-            ageHint="0" />
-        <rating-definition id="DE_TV_12"
-            displayName="@string/display_name_detv_12"
-            description="@string/description_detv_12"
-            ageHint="12" />
-        <rating-definition id="DE_TV_16"
-            displayName="@string/display_name_detv_16"
-            description="@string/description_detv_16"
-            ageHint="16" />
-        <rating-definition id="DE_TV_18"
-            displayName="@string/display_name_detv_18"
-            description="@string/description_detv_18"
-            ageHint="18" />
-        <order>
-            <rating id="DE_TV_ALL" />
-            <rating id="DE_TV_12" />
-            <rating id="DE_TV_16" />
-            <rating id="DE_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for DK TV -->
-    <rating-system-definition id="DK_TV"
-        displayName="@string/display_name_dktv"
-        country="DK">
-        <rating-definition id="DK_TV_G"
-            displayName="@string/display_name_dktv_g"
-            description="@string/description_dktv_g"
-            ageHint="0" />
-        <rating-definition id="DK_TV_Y"
-            displayName="@string/display_name_dktv_y"
-            description="@string/description_dktv_y"
-            ageHint="13" />
-        <rating-definition id="DK_TV_R"
-            displayName="@string/display_name_dktv_r"
-            description="@string/description_dktv_r"
-            ageHint="18" />
-        <rating-definition id="DK_TV_B"
-            displayName="@string/display_name_dktv_b"
-            description="@string/description_dktv_b"
-            ageHint="18" />
-        <order>
-            <rating id="DK_TV_G" />
-            <rating id="DK_TV_Y" />
-            <rating id="DK_TV_R" />
-            <rating id="DK_TV_B" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for ES TV -->
-    <rating-system-definition id="ES_TV"
-        displayName="@string/display_name_estv"
-        country="ES">
-        <rating-definition id="ES_TV_TP"
-            displayName="@string/display_name_estv_tp"
-            description="@string/description_estv_tp"
-            ageHint="0" />
-        <rating-definition id="ES_TV_I"
-            displayName="@string/display_name_estv_i"
-            description="@string/description_estv_i"
-            ageHint="0" />
-        <rating-definition id="ES_TV_7"
-            displayName="@string/display_name_estv_7"
-            description="@string/description_estv_7"
-            ageHint="7" />
-        <rating-definition id="ES_TV_7I"
-            displayName="@string/display_name_estv_7i"
-            description="@string/description_estv_7i"
-            ageHint="7" />
-        <rating-definition id="ES_TV_12"
-            displayName="@string/display_name_estv_12"
-            description="@string/description_estv_12"
-            ageHint="12" />
-        <rating-definition id="ES_TV_16"
-            displayName="@string/display_name_estv_16"
-            description="@string/description_estv_16"
-            ageHint="16" />
-        <rating-definition id="ES_TV_18"
-            displayName="@string/display_name_estv_18"
-            description="@string/description_estv_18"
-            ageHint="18" />
-        <order>
-            <rating id="ES_TV_TP" />
-            <rating id="ES_TV_I" />
-            <rating id="ES_TV_7" />
-            <rating id="ES_TV_7I" />
-            <rating id="ES_TV_12" />
-            <rating id="ES_TV_16" />
-            <rating id="ES_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for FI TV -->
-    <rating-system-definition id="FI_TV"
-        displayName="@string/display_name_fitv"
-        country="FI">
-        <rating-definition id="FI_TV_S"
-            displayName="@string/display_name_fitv_s"
-            description="@string/description_fitv_s"
-            ageHint="0" />
-        <rating-definition id="FI_TV_K7"
-            displayName="@string/display_name_fitv_k7"
-            description="@string/description_fitv_k7"
-            ageHint="7" />
-        <rating-definition id="FI_TV_K12"
-            displayName="@string/display_name_fitv_k12"
-            description="@string/description_fitv_k12"
-            ageHint="12" />
-        <rating-definition id="FI_TV_K16"
-            displayName="@string/display_name_fitv_k16"
-            description="@string/description_fitv_k16"
-            ageHint="16" />
-        <rating-definition id="FI_TV_K18"
-            displayName="@string/display_name_fitv_k18"
-            description="@string/description_fitv_k18"
-            ageHint="18" />
-        <order>
-            <rating id="FI_TV_S" />
-            <rating id="FI_TV_K7" />
-            <rating id="FI_TV_K12" />
-            <rating id="FI_TV_K16" />
-            <rating id="FI_TV_K18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for FR TV -->
-    <rating-system-definition id="FR_TV"
-        displayName="@string/display_name_frtv"
-        country="FR">
-        <rating-definition id="FR_TV_ALL"
-            displayName="@string/display_name_frtv_all"
-            description="@string/description_frtv_all"
-            ageHint="0" />
-        <rating-definition id="FR_TV_10"
-            displayName="@string/display_name_frtv_10"
-            description="@string/description_frtv_10"
-            ageHint="10" />
-        <rating-definition id="FR_TV_12"
-            displayName="@string/display_name_frtv_12"
-            description="@string/description_frtv_12"
-            ageHint="12" />
-        <rating-definition id="FR_TV_16"
-            displayName="@string/display_name_frtv_16"
-            description="@string/description_frtv_16"
-            ageHint="16" />
-        <rating-definition id="FR_TV_18"
-            displayName="@string/display_name_frtv_18"
-            description="@string/description_frtv_18"
-            ageHint="18" />
-        <order>
-            <rating id="FR_TV_ALL" />
-            <rating id="FR_TV_10" />
-            <rating id="FR_TV_12" />
-            <rating id="FR_TV_16" />
-            <rating id="FR_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for GR TV -->
-    <rating-system-definition id="GR_TV"
-        displayName="@string/display_name_grtv"
-        country="GR">
-        <rating-definition id="GR_TV_all"
-            displayName="@string/display_name_grtv_all"
-            description="@string/description_grtv_all"
-            ageHint="0" />
-        <rating-definition id="GR_TV_10"
-            displayName="@string/display_name_grtv_10"
-            description="@string/description_grtv_10"
-            ageHint="10" />
-        <rating-definition id="GR_TV_12"
-            displayName="@string/display_name_grtv_12"
-            description="@string/description_grtv_12"
-            ageHint="12" />
-        <rating-definition id="GR_TV_15"
-            displayName="@string/display_name_grtv_15"
-            description="@string/description_grtv_15"
-            ageHint="15" />
-        <rating-definition id="GR_TV_18"
-            displayName="@string/display_name_grtv_18"
-            description="@string/description_grtv_18"
-            ageHint="18" />
-        <order>
-            <rating id="GR_TV_all" />
-            <rating id="GR_TV_10" />
-            <rating id="GR_TV_12" />
-            <rating id="GR_TV_15" />
-            <rating id="GR_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for HK TV -->
-    <rating-system-definition id="HK_TV"
-        displayName="@string/display_name_hktv"
-        country="HK">
-        <rating-definition id="HK_TV_G"
-            displayName="@string/display_name_hktv_g"
-            description="@string/description_hktv_g"
-            ageHint="0" />
-        <rating-definition id="HK_TV_PG"
-            displayName="@string/display_name_hktv_pg"
-            description="@string/description_hktv_pg"
-            ageHint="14" />
-        <rating-definition id="HK_TV_M"
-            displayName="@string/display_name_hktv_m"
-            description="@string/description_hktv_m"
-            ageHint="18" />
-        <order>
-            <rating id="HK_TV_G" />
-            <rating id="HK_TV_PG" />
-            <rating id="HK_TV_M" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for HU TV -->
-    <rating-system-definition id="HU_TV"
-        displayName="@string/display_name_hutv"
-        country="HU">
-        <rating-definition id="HU_TV_U"
-            displayName="@string/display_name_hutv_u"
-            description="@string/description_hutv_u"
-            ageHint="0" />
-        <rating-definition id="HU_TV_CF"
-            displayName="@string/display_name_hutv_cf"
-            description="@string/description_hutv_cf"
-            ageHint="0" />
-        <rating-definition id="HU_TV_6"
-            displayName="@string/display_name_hutv_6"
-            description="@string/description_hutv_6"
-            ageHint="6" />
-        <rating-definition id="HU_TV_12"
-            displayName="@string/display_name_hutv_12"
-            description="@string/description_hutv_12"
-            ageHint="12" />
-        <rating-definition id="HU_TV_16"
-            displayName="@string/display_name_hutv_16"
-            description="@string/description_hutv_16"
-            ageHint="16" />
-        <rating-definition id="HU_TV_18"
-            displayName="@string/display_name_hutv_18"
-            description="@string/description_hutv_18"
-            ageHint="18" />
-        <order>
-            <rating id="HU_TV_U" />
-            <rating id="HU_TV_CF" />
-            <rating id="HU_TV_6" />
-            <rating id="HU_TV_12" />
-            <rating id="HU_TV_16" />
-            <rating id="HU_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for ID TV -->
-    <rating-system-definition id="ID_TV"
-        displayName="@string/display_name_idtv"
-        country="ID">
-        <rating-definition id="ID_TV_P"
-            displayName="@string/display_name_idtv_p"
-            description="@string/description_idtv_p"
-            ageHint="2" />
-        <rating-definition id="ID_TV_A"
-            displayName="@string/display_name_idtv_a"
-            description="@string/description_idtv_a"
-            ageHint="7" />
-        <rating-definition id="ID_TV_A_BO"
-            displayName="@string/display_name_idtv_a_bo"
-            description="@string/description_idtv_a_bo"
-            ageHint="10" />
-        <rating-definition id="ID_TV_SU"
-            displayName="@string/display_name_idtv_su"
-            description="@string/description_idtv_su"
-            ageHint="0" />
-        <rating-definition id="ID_TV_BO"
-            displayName="@string/display_name_idtv_bo"
-            description="@string/description_idtv_bo"
-            ageHint="5" />
-        <rating-definition id="ID_TV_R"
-            displayName="@string/display_name_idtv_r"
-            description="@string/description_idtv_r"
-            ageHint="13" />
-        <rating-definition id="ID_TV_R_BO"
-            displayName="@string/display_name_idtv_r_bo"
-            description="@string/description_idtv_r_bo"
-            ageHint="18" />
-        <rating-definition id="ID_TV_D"
-            displayName="@string/display_name_idtv_d"
-            description="@string/description_idtv_d"
-            ageHint="18" />
-        <order>
-            <rating id="ID_TV_P" />
-            <rating id="ID_TV_A" />
-            <rating id="ID_TV_A_BO" />
-        </order>
-        <order>
-            <rating id="ID_TV_SU" />
-            <rating id="ID_TV_BO" />
-            <rating id="ID_TV_R" />
-            <rating id="ID_TV_R_BO" />
-            <rating id="ID_TV_D" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for IE TV -->
-    <rating-system-definition id="IE_TV"
-        displayName="@string/display_name_ietv"
-        country="IE">
-        <rating-definition id="IE_TV_GA"
-            displayName="@string/display_name_ietv_ga"
-            description="@string/description_ietv_ga"
-            ageHint="0" />
-        <rating-definition id="IE_TV_Ch"
-            displayName="@string/display_name_ietv_ch"
-            description="@string/description_ietv_ch"
-            ageHint="10" />
-        <rating-definition id="IE_TV_YA"
-            displayName="@string/display_name_ietv_ya"
-            description="@string/description_ietv_ya"
-            ageHint="13" />
-        <rating-definition id="IE_TV_PS"
-            displayName="@string/display_name_ietv_ps"
-            description="@string/description_ietv_ps"
-            ageHint="18" />
-        <rating-definition id="IE_TV_MA"
-            displayName="@string/display_name_ietv_ma"
-            description="@string/description_ietv_ma"
-            ageHint="21" />
-        <order>
-            <rating id="IE_TV_GA" />
-            <rating id="IE_TV_Ch" />
-            <rating id="IE_TV_YA" />
-            <rating id="IE_TV_PS" />
-            <rating id="IE_TV_MA" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for IL TV -->
-    <rating-system-definition id="IL_TV"
-        displayName="@string/display_name_iltv"
-        country="IL">
-        <rating-definition id="IL_TV_G"
-            displayName="@string/display_name_iltv_g"
-            description="@string/description_iltv_g"
-            ageHint="0" />
-        <rating-definition id="IL_TV_12"
-            displayName="@string/display_name_iltv_12"
-            description="@string/description_iltv_12"
-            ageHint="12" />
-        <rating-definition id="IL_TV_15"
-            displayName="@string/display_name_iltv_15"
-            description="@string/description_iltv_15"
-            ageHint="15" />
-        <rating-definition id="IL_TV_18"
-            displayName="@string/display_name_iltv_18"
-            description="@string/description_iltv_18"
-            ageHint="18" />
-        <rating-definition id="IL_TV_E"
-            displayName="@string/display_name_iltv_e"
-            description="@string/description_iltv_e"
-            ageHint="0" />
-        <order>
-            <rating id="IL_TV_G" />
-            <rating id="IL_TV_12" />
-            <rating id="IL_TV_15" />
-            <rating id="IL_TV_18" />
-            <rating id="IL_TV_E" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for IN TV -->
-    <rating-system-definition id="IN_TV"
-        displayName="@string/display_name_intv"
-        country="IN">
-        <rating-definition id="IN_TV_U"
-            displayName="@string/display_name_intv_u"
-            description="@string/description_intv_u"
-            ageHint="0" />
-        <rating-definition id="IN_TV_U/A"
-            displayName="@string/display_name_intv_u/a"
-            description="@string/description_intv_u/a"
-            ageHint="12" />
-        <rating-definition id="IN_TV_A"
-            displayName="@string/display_name_intv_a"
-            description="@string/description_intv_a"
-            ageHint="18" />
-        <rating-definition id="IN_TV_S"
-            displayName="@string/display_name_intv_s"
-            description="@string/description_intv_s"
-            ageHint="0" />
-        <order>
-            <rating id="IN_TV_U" />
-            <rating id="IN_TV_U/A" />
-            <rating id="IN_TV_A" />
-            <rating id="IN_TV_S" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for IS TV -->
-    <rating-system-definition id="IS_TV"
-        displayName="@string/display_name_istv"
-        country="IS">
-        <rating-definition id="IS_TV_L"
-            displayName="@string/display_name_istv_l"
-            description="@string/description_istv_l"
-            ageHint="0" />
-        <rating-definition id="IS_TV_7"
-            displayName="@string/display_name_istv_7"
-            description="@string/description_istv_7"
-            ageHint="7" />
-        <rating-definition id="IS_TV_10"
-            displayName="@string/display_name_istv_10"
-            description="@string/description_istv_10"
-            ageHint="10" />
-        <rating-definition id="IS_TV_12"
-            displayName="@string/display_name_istv_12"
-            description="@string/description_istv_12"
-            ageHint="12" />
-        <rating-definition id="IS_TV_14"
-            displayName="@string/display_name_istv_14"
-            description="@string/description_istv_14"
-            ageHint="14" />
-        <rating-definition id="IS_TV_16"
-            displayName="@string/display_name_istv_16"
-            description="@string/description_istv_16"
-            ageHint="16" />
-        <rating-definition id="IS_TV_18"
-            displayName="@string/display_name_istv_18"
-            description="@string/description_istv_18"
-            ageHint="18" />
-        <order>
-            <rating id="IS_TV_L" />
-            <rating id="IS_TV_7" />
-            <rating id="IS_TV_10" />
-            <rating id="IS_TV_12" />
-            <rating id="IS_TV_14" />
-            <rating id="IS_TV_16" />
-            <rating id="IS_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for KR TV -->
-    <rating-system-definition id="KR_TV"
-        displayName="@string/display_name_krtv"
-        country="KR">
-        <rating-definition id="KR_TV_All"
-            displayName="@string/display_name_krtv_all"
-            description="@string/description_krtv_all"
-            ageHint="0" />
-        <rating-definition id="KR_TV_7"
-            displayName="@string/display_name_krtv_7"
-            description="@string/description_krtv_7"
-            ageHint="7" />
-        <rating-definition id="KR_TV_12"
-            displayName="@string/display_name_krtv_12"
-            description="@string/description_krtv_12"
-            ageHint="12" />
-        <rating-definition id="KR_TV_15"
-            displayName="@string/display_name_krtv_15"
-            description="@string/description_krtv_15"
-            ageHint="15" />
-        <rating-definition id="KR_TV_19"
-            displayName="@string/display_name_krtv_19"
-            description="@string/description_krtv_19"
-            ageHint="19" />
-        <order>
-            <rating id="KR_TV_All" />
-            <rating id="KR_TV_7" />
-            <rating id="KR_TV_12" />
-            <rating id="KR_TV_15" />
-            <rating id="KR_TV_19" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for MV TV -->
-    <rating-system-definition id="MV_TV"
-        displayName="@string/display_name_mvtv"
-        country="MV">
-        <rating-definition id="MV_TV_Y"
-            displayName="@string/display_name_mvtv_y"
-            description="@string/description_mvtv_y"
-            ageHint="0" />
-        <rating-definition id="MV_TV_G"
-            displayName="@string/display_name_mvtv_g"
-            description="@string/description_mvtv_g"
-            ageHint="0" />
-        <rating-definition id="MV_TV_PG"
-            displayName="@string/display_name_mvtv_pg"
-            description="@string/description_mvtv_pg"
-            ageHint="0" />
-        <rating-definition id="MV_TV_PG-12"
-            displayName="@string/display_name_mvtv_pg-12"
-            description="@string/description_mvtv_pg-12"
-            ageHint="12" />
-        <rating-definition id="MV_TV_12"
-            displayName="@string/display_name_mvtv_12"
-            description="@string/description_mvtv_12"
-            ageHint="12" />
-        <rating-definition id="MV_TV_15"
-            displayName="@string/display_name_mvtv_15"
-            description="@string/description_mvtv_15"
-            ageHint="15" />
-        <rating-definition id="MV_TV_18"
-            displayName="@string/display_name_mvtv_18"
-            description="@string/description_mvtv_18"
-            ageHint="18" />
-        <rating-definition id="MV_TV_21"
-            displayName="@string/display_name_mvtv_21"
-            description="@string/description_mvtv_21"
-            ageHint="21" />
-        <rating-definition id="MV_TV_X"
-            displayName="@string/display_name_mvtv_x"
-            description="@string/description_mvtv_x"
-            ageHint="25" />
-        <order>
-            <rating id="MV_TV_Y" />
-            <rating id="MV_TV_G" />
-            <rating id="MV_TV_PG" />
-            <rating id="MV_TV_PG-12" />
-            <rating id="MV_TV_12" />
-            <rating id="MV_TV_15" />
-            <rating id="MV_TV_18" />
-            <rating id="MV_TV_21" />
-            <rating id="MV_TV_X" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for MX TV -->
-    <rating-system-definition id="MX_TV"
-        displayName="@string/display_name_mxtv"
-        country="MX">
-        <rating-definition id="MX_TV_A"
-            displayName="@string/display_name_mxtv_a"
-            description="@string/description_mxtv_a"
-            ageHint="7" />
-        <rating-definition id="MX_TV_B"
-            displayName="@string/display_name_mxtv_b"
-            description="@string/description_mxtv_b"
-            ageHint="12" />
-        <rating-definition id="MX_TV_B-15"
-            displayName="@string/display_name_mxtv_b-15"
-            description="@string/description_mxtv_b-15"
-            ageHint="15" />
-        <rating-definition id="MX_TV_C"
-            displayName="@string/display_name_mxtv_c"
-            description="@string/description_mxtv_c"
-            ageHint="18" />
-        <rating-definition id="MX_TV_D"
-            displayName="@string/display_name_mxtv_d"
-            description="@string/description_mxtv_d"
-            ageHint="21" />
-        <rating-definition id="MX_TV_RC"
-            displayName="@string/display_name_mxtv_rc"
-            description="@string/description_mxtv_rc"
-            ageHint="0" />
-        <order>
-            <rating id="MX_TV_A" />
-            <rating id="MX_TV_B" />
-            <rating id="MX_TV_B-15" />
-            <rating id="MX_TV_C" />
-            <rating id="MX_TV_D" />
-            <rating id="MX_TV_RC" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for MY TV -->
-    <rating-system-definition id="MY_TV"
-        displayName="@string/display_name_mytv"
-        country="MY">
-        <rating-definition id="MY_TV_U"
-            displayName="@string/display_name_mytv_u"
-            description="@string/description_mytv_u"
-            ageHint="0" />
-        <rating-definition id="MY_TV_P13"
-            displayName="@string/display_name_mytv_p13"
-            description="@string/description_mytv_p13"
-            ageHint="13" />
-        <rating-definition id="MY_TV_18"
-            displayName="@string/display_name_mytv_18"
-            description="@string/description_mytv_18"
-            ageHint="18" />
-        <order>
-            <rating id="MY_TV_U" />
-            <rating id="MY_TV_P13" />
-            <rating id="MY_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for NL TV -->
-    <rating-system-definition id="NL_TV"
-        displayName="@string/display_name_nltv"
-        country="NL">
-        <sub-rating-definition id="NL_TV_V"
-            displayName="@string/display_name_nltv_v"
-            description="@string/description_nltv_v" />
-        <sub-rating-definition id="NL_TV_F"
-            displayName="@string/display_name_nltv_f"
-            description="@string/description_nltv_f" />
-        <sub-rating-definition id="NL_TV_S"
-            displayName="@string/display_name_nltv_s"
-            description="@string/description_nltv_s" />
-        <sub-rating-definition id="NL_TV_D"
-            displayName="@string/display_name_nltv_d"
-            description="@string/description_nltv_d" />
-        <sub-rating-definition id="NL_TV_DA"
-            displayName="@string/display_name_nltv_da"
-            description="@string/description_nltv_da" />
-        <sub-rating-definition id="NL_TV_L"
-            displayName="@string/display_name_nltv_l"
-            description="@string/description_nltv_l" />
-
-        <rating-definition id="NL_TV_AL"
-            displayName="@string/display_name_nltv_al"
-            description="@string/description_nltv_al"
-            ageHint="0">
-            <sub-rating id="NL_TV_V" />
-            <sub-rating id="NL_TV_F" />
-            <sub-rating id="NL_TV_S" />
-            <sub-rating id="NL_TV_D" />
-            <sub-rating id="NL_TV_DA" />
-            <sub-rating id="NL_TV_L" />
-        </rating-definition>
-        <rating-definition id="NL_TV_6"
-            displayName="@string/display_name_nltv_6"
-            description="@string/description_nltv_6"
-            ageHint="6">
-            <sub-rating id="NL_TV_V" />
-            <sub-rating id="NL_TV_F" />
-            <sub-rating id="NL_TV_S" />
-            <sub-rating id="NL_TV_D" />
-            <sub-rating id="NL_TV_DA" />
-            <sub-rating id="NL_TV_L" />
-        </rating-definition>
-        <rating-definition id="NL_TV_9"
-            displayName="@string/display_name_nltv_9"
-            description="@string/description_nltv_9"
-            ageHint="9">
-            <sub-rating id="NL_TV_V" />
-            <sub-rating id="NL_TV_F" />
-            <sub-rating id="NL_TV_S" />
-            <sub-rating id="NL_TV_D" />
-            <sub-rating id="NL_TV_DA" />
-            <sub-rating id="NL_TV_L" />
-        </rating-definition>
-        <rating-definition id="NL_TV_12"
-            displayName="@string/display_name_nltv_12"
-            description="@string/description_nltv_12"
-            ageHint="12">
-            <sub-rating id="NL_TV_V" />
-            <sub-rating id="NL_TV_F" />
-            <sub-rating id="NL_TV_S" />
-            <sub-rating id="NL_TV_D" />
-            <sub-rating id="NL_TV_DA" />
-            <sub-rating id="NL_TV_L" />
-        </rating-definition>
-        <rating-definition id="NL_TV_16"
-            displayName="@string/display_name_nltv_16"
-            description="@string/description_nltv_16"
-            ageHint="16">
-            <sub-rating id="NL_TV_V" />
-            <sub-rating id="NL_TV_F" />
-            <sub-rating id="NL_TV_S" />
-            <sub-rating id="NL_TV_D" />
-            <sub-rating id="NL_TV_DA" />
-            <sub-rating id="NL_TV_L" />
-        </rating-definition>
-        <order>
-            <rating id="NL_TV_AL" />
-            <rating id="NL_TV_6" />
-            <rating id="NL_TV_9" />
-            <rating id="NL_TV_12" />
-            <rating id="NL_TV_16" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for NZ Free-to-Air TV -->
-    <rating-system-definition id="NZ_FTV"
-        displayName="@string/display_name_nzftv"
-        description="@string/description_nzftv"
-        country="NZ">
-        <rating-definition id="NZ_FTV_G"
-            displayName="@string/display_name_nzftv_g"
-            description="@string/description_nzftv_g"
-            ageHint="0" />
-        <rating-definition id="NZ_FTV_PGR"
-            displayName="@string/display_name_nzftv_pgr"
-            description="@string/description_nzftv_pgr"
-            ageHint="14" />
-        <rating-definition id="NZ_FTV_AO"
-            displayName="@string/display_name_nzftv_ao"
-            description="@string/description_nzftv_ao"
-            ageHint="18" />
-        <order>
-            <rating id="NZ_FTV_G" />
-            <rating id="NZ_FTV_PGR" />
-            <rating id="NZ_FTV_AO" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for NZ Pay Television -->
-    <rating-system-definition id="NZ_PTV"
-        displayName="@string/display_name_nzptv"
-        description="@string/description_nzptv"
-        country="NZ">
-        <sub-rating-definition id="NZ_PTV_C"
-            displayName="@string/display_name_nzptv_c"
-            description="@string/description_nzptv_c" />
-        <sub-rating-definition id="NZ_PTV_V"
-            displayName="@string/display_name_nzptv_v"
-            description="@string/description_nzptv_v" />
-        <sub-rating-definition id="NZ_PTV_L"
-            displayName="@string/display_name_nzptv_l"
-            description="@string/description_nzptv_l" />
-        <sub-rating-definition id="NZ_PTV_S"
-            displayName="@string/display_name_nzptv_s"
-            description="@string/description_nzptv_s" />
-        <rating-definition id="NZ_PTV_G"
-            displayName="@string/display_name_nzptv_g"
-            description="@string/description_nzptv_g"
-            ageHint="0" />
-        <rating-definition id="NZ_PTV_PG"
-            displayName="@string/display_name_nzptv_pg"
-            description="@string/description_nzptv_pg"
-            ageHint="10">
-            <sub-rating id="NZ_PTV_C" />
-            <sub-rating id="NZ_PTV_V" />
-            <sub-rating id="NZ_PTV_L" />
-            <sub-rating id="NZ_PTV_S" />
-        </rating-definition>
-        <rating-definition id="NZ_PTV_M"
-            displayName="@string/display_name_nzptv_m"
-            description="@string/description_nzptv_m"
-            ageHint="13">
-            <sub-rating id="NZ_PTV_C" />
-            <sub-rating id="NZ_PTV_V" />
-            <sub-rating id="NZ_PTV_L" />
-            <sub-rating id="NZ_PTV_S" />
-        </rating-definition>
-        <rating-definition id="NZ_PTV_16"
-            displayName="@string/display_name_nzptv_16"
-            description="@string/description_nzptv_16"
-            ageHint="16">
-            <sub-rating id="NZ_PTV_C" />
-            <sub-rating id="NZ_PTV_V" />
-            <sub-rating id="NZ_PTV_L" />
-            <sub-rating id="NZ_PTV_S" />
-        </rating-definition>
-        <rating-definition id="NZ_PTV_18"
-            displayName="@string/display_name_nzptv_18"
-            description="@string/description_nzptv_18"
-            ageHint="18">
-            <sub-rating id="NZ_PTV_C" />
-            <sub-rating id="NZ_PTV_V" />
-            <sub-rating id="NZ_PTV_L" />
-            <sub-rating id="NZ_PTV_S" />
-        </rating-definition>
-        <order>
-            <rating id="NZ_PTV_G" />
-            <rating id="NZ_PTV_PG" />
-            <rating id="NZ_PTV_M" />
-            <rating id="NZ_PTV_16" />
-            <rating id="NZ_PTV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for PE TV -->
-    <rating-system-definition id="PE_TV"
-        displayName="@string/display_name_petv"
-        description="@string/description_petv"
-        country="PE">
-        <rating-definition id="PE_TV_A"
-            displayName="@string/display_name_petv_a"
-            description="@string/description_petv_a"
-            ageHint="0" />
-        <rating-definition id="PE_TV_14"
-            displayName="@string/display_name_petv_14"
-            description="@string/description_petv_14"
-            ageHint="14" />
-        <rating-definition id="PE_TV_18"
-            displayName="@string/display_name_petv_18"
-            description="@string/description_petv_18"
-            ageHint="18" />
-        <order>
-            <rating id="PE_TV_A" />
-            <rating id="PE_TV_14" />
-            <rating id="PE_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <rating-system-definition id="PE_ATV"
-        displayName="@string/display_name_peatv"
-        description="@string/description_peatv"
-        country="PE">
-        <rating-definition id="PE_ATV_GP"
-            displayName="@string/display_name_peatv_gp"
-            description="@string/description_peatv_gp"
-            ageHint="0" />
-        <rating-definition id="PE_ATV_PG"
-            displayName="@string/display_name_peatv_pg"
-            description="@string/description_peatv_pg"
-            ageHint="6" />
-        <rating-definition id="PE_ATV_14"
-            displayName="@string/display_name_peatv_14"
-            description="@string/description_peatv_14"
-            ageHint="14" />
-        <rating-definition id="PE_ATV_18"
-            displayName="@string/display_name_peatv_18"
-            description="@string/description_peatv_18"
-            ageHint="18" />
-        <order>
-            <rating id="PE_ATV_GP" />
-            <rating id="PE_ATV_PG" />
-            <rating id="PE_ATV_14" />
-            <rating id="PE_ATV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for PH TV -->
-    <rating-system-definition id="PH_TV"
-        displayName="@string/display_name_phtv"
-        country="PH">
-        <rating-definition id="PH_TV_G"
-            displayName="@string/display_name_phtv_g"
-            description="@string/description_phtv_g"
-            ageHint="0" />
-        <rating-definition id="PH_TV_PG"
-            displayName="@string/display_name_phtv_pg"
-            description="@string/description_phtv_pg"
-            ageHint="14" />
-        <rating-definition id="PH_TV_SPG"
-            displayName="@string/display_name_phtv_spg"
-            description="@string/description_phtv_spg"
-            ageHint="18" />
-        <order>
-            <rating id="PH_TV_G" />
-            <rating id="PH_TV_PG" />
-            <rating id="PH_TV_SPG" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for PL TV -->
-    <rating-system-definition id="PL_TV"
-        displayName="@string/display_name_pltv"
-        country="PL">
-        <rating-definition id="PL_TV_G"
-            displayName="@string/display_name_pltv_g"
-            description="@string/description_pltv_g"
-            ageHint="0" />
-        <rating-definition id="PL_TV_7"
-            displayName="@string/display_name_pltv_7"
-            description="@string/description_pltv_7"
-            ageHint="7" />
-        <rating-definition id="PL_TV_12"
-            displayName="@string/display_name_pltv_12"
-            description="@string/description_pltv_12"
-            ageHint="12" />
-        <rating-definition id="PL_TV_16"
-            displayName="@string/display_name_pltv_16"
-            description="@string/description_pltv_16"
-            ageHint="16" />
-        <rating-definition id="PL_TV_18"
-            displayName="@string/display_name_pltv_18"
-            description="@string/description_pltv_18"
-            ageHint="18" />
-        <order>
-            <rating id="PL_TV_G" />
-            <rating id="PL_TV_7" />
-            <rating id="PL_TV_12" />
-            <rating id="PL_TV_16" />
-            <rating id="PL_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for PT TV -->
-    <rating-system-definition id="PT_TV"
-        displayName="@string/display_name_pttv"
-        country="PT">
-        <rating-definition id="PT_TV_T"
-            displayName="@string/display_name_pttv_t"
-            description="@string/description_pttv_t"
-            ageHint="0" />
-        <rating-definition id="PT_TV_10"
-            displayName="@string/display_name_pttv_10"
-            description="@string/description_pttv_10"
-            ageHint="10" />
-        <rating-definition id="PT_TV_12"
-            displayName="@string/display_name_pttv_12"
-            description="@string/description_pttv_12"
-            ageHint="12" />
-        <rating-definition id="PT_TV_16"
-            displayName="@string/display_name_pttv_16"
-            description="@string/description_pttv_16"
-            ageHint="16" />
-        <order>
-            <rating id="PT_TV_T" />
-            <rating id="PT_TV_10" />
-            <rating id="PT_TV_12" />
-            <rating id="PT_TV_16" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for RO TV -->
-    <rating-system-definition id="RO_TV"
-        displayName="@string/display_name_rotv"
-        country="RO">
-        <rating-definition id="RO_TV_Y"
-            displayName="@string/display_name_rotv_y"
-            description="@string/description_rotv_y"
-            ageHint="0" />
-        <rating-definition id="RO_TV_G"
-            displayName="@string/display_name_rotv_g"
-            description="@string/description_rotv_g"
-            ageHint="0" />
-        <rating-definition id="RO_TV_AP"
-            displayName="@string/display_name_rotv_ap"
-            description="@string/description_rotv_ap"
-            ageHint="12" />
-        <rating-definition id="RO_TV_12"
-            displayName="@string/display_name_rotv_12"
-            description="@string/description_rotv_12"
-            ageHint="12" />
-        <rating-definition id="RO_TV_15"
-            displayName="@string/display_name_rotv_15"
-            description="@string/description_rotv_15"
-            ageHint="15" />
-        <rating-definition id="RO_TV_18"
-            displayName="@string/display_name_rotv_18"
-            description="@string/description_rotv_18"
-            ageHint="18" />
-        <order>
-            <rating id="RO_TV_Y" />
-            <rating id="RO_TV_G" />
-            <rating id="RO_TV_AP" />
-            <rating id="RO_TV_12" />
-            <rating id="RO_TV_15" />
-            <rating id="RO_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for RU TV -->
-    <rating-system-definition id="RU_TV"
-        displayName="@string/display_name_rutv"
-        country="RU">
-        <rating-definition id="RU_TV_0"
-            displayName="@string/display_name_rutv_0"
-            description="@string/description_rutv_0"
-            ageHint="0" />
-        <rating-definition id="RU_TV_6"
-            displayName="@string/display_name_rutv_6"
-            description="@string/description_rutv_6"
-            ageHint="6" />
-        <rating-definition id="RU_TV_12"
-            displayName="@string/display_name_rutv_12"
-            description="@string/description_rutv_12"
-            ageHint="12" />
-        <rating-definition id="RU_TV_16"
-            displayName="@string/display_name_rutv_16"
-            description="@string/description_rutv_16"
-            ageHint="16" />
-        <rating-definition id="RU_TV_18"
-            displayName="@string/display_name_rutv_18"
-            description="@string/description_rutv_18"
-            ageHint="18" />
-        <order>
-            <rating id="RU_TV_0" />
-            <rating id="RU_TV_6" />
-            <rating id="RU_TV_12" />
-            <rating id="RU_TV_16" />
-            <rating id="RU_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for RS TV -->
-    <rating-system-definition id="RS_TV"
-        displayName="@string/display_name_rstv"
-        country="RS">
-        <rating-definition id="RS_TV_G"
-            displayName="@string/display_name_rstv_g"
-            description="@string/description_rstv_g"
-            ageHint="0" />
-        <rating-definition id="RS_TV_12"
-            displayName="@string/display_name_rstv_12"
-            description="@string/description_rstv_12"
-            ageHint="12" />
-        <rating-definition id="RS_TV_14"
-            displayName="@string/display_name_rstv_14"
-            description="@string/description_rstv_14"
-            ageHint="14" />
-        <rating-definition id="RS_TV_15"
-            displayName="@string/display_name_rstv_15"
-            description="@string/description_rstv_15"
-            ageHint="15" />
-        <rating-definition id="RS_TV_16"
-            displayName="@string/display_name_rstv_16"
-            description="@string/description_rstv_16"
-            ageHint="16" />
-        <rating-definition id="RS_TV_17"
-            displayName="@string/display_name_rstv_17"
-            description="@string/description_rstv_17"
-            ageHint="17" />
-        <rating-definition id="RS_TV_18"
-            displayName="@string/display_name_rstv_18"
-            description="@string/description_rstv_18"
-            ageHint="18" />
-        <order>
-            <rating id="RS_TV_G" />
-            <rating id="RS_TV_12" />
-            <rating id="RS_TV_14" />
-            <rating id="RS_TV_15" />
-            <rating id="RS_TV_16" />
-            <rating id="RS_TV_17" />
-            <rating id="RS_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for SG Free-to-Air TV -->
-    <rating-system-definition id="SG_FTV"
-        displayName="@string/display_name_sgftv"
-        country="SG">
-        <rating-definition id="SG_FTV_PG"
-            displayName="@string/display_name_sgftv_pg"
-            description="@string/description_sgftv_pg"
-            ageHint="0" />
-        <rating-definition id="SG_FTV_PG13"
-            displayName="@string/display_name_sgftv_pg13"
-            description="@string/description_sgftv_pg13"
-            ageHint="13" />
-       <order>
-            <rating id="SG_FTV_PG" />
-            <rating id="SG_FTV_PG13" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for SG Pay TV -->
-    <rating-system-definition id="SG_PTV"
-        displayName="@string/display_name_sgptv"
-        country="SG">
-        <rating-definition id="SG_PTV_NC16"
-            displayName="@string/display_name_sgptv_nc16"
-            description="@string/description_sgptv_nc16"
-            ageHint="16" />
-        <rating-definition id="SG_PTV_M18"
-            displayName="@string/display_name_sgptv_m18"
-            description="@string/description_sgptv_m18"
-            ageHint="18" />
-       <order>
-            <rating id="SG_PTV_NC16" />
-            <rating id="SG_PTV_M18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for SI TV -->
-    <rating-system-definition id="SI_TV"
-        displayName="@string/display_name_sitv"
-        country="SI">
-        <rating-definition id="SI_TV_VS"
-            displayName="@string/display_name_sitv_vs"
-            description="@string/description_sitv_vs"
-            ageHint="6" />
-        <rating-definition id="SI_TV_12"
-            displayName="@string/display_name_sitv_12"
-            description="@string/description_sitv_12"
-            ageHint="12" />
-        <rating-definition id="SI_TV_15"
-            displayName="@string/display_name_sitv_15"
-            description="@string/description_sitv_15"
-            ageHint="15" />
-        <rating-definition id="SI_TV_AD"
-            displayName="@string/display_name_sitv_ad"
-            description="@string/description_sitv_ad"
-            ageHint="0" />
-        <order>
-            <rating id="SI_TV_VS" />
-            <rating id="SI_TV_12" />
-            <rating id="SI_TV_15" />
-            <rating id="SI_TV_AD" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for TH TV -->
-    <rating-system-definition id="TH_TV"
-        displayName="@string/display_name_thtv"
-        country="TH">
-        <rating-definition id="TH_TV_P"
-            displayName="@string/display_name_thtv_primary"
-            description="@string/description_thtv_primary"
-            ageHint="0" />
-        <rating-definition id="TH_TV_C"
-            displayName="@string/display_name_thtv_children"
-            description="@string/description_thtv_children"
-            ageHint="6" />
-        <rating-definition id="TH_TV_G"
-            displayName="@string/display_name_thtv_general"
-            description="@string/description_thtv_general"
-            ageHint="0" />
-        <rating-definition id="TH_TV_PG13"
-            displayName="@string/display_name_thtv_pg13"
-            description="@string/description_thtv_pg13"
-            ageHint="13" />
-        <rating-definition id="TH_TV_PG18"
-            displayName="@string/display_name_thtv_pg18"
-            description="@string/description_thtv_pg18"
-            ageHint="18" />
-        <rating-definition id="TH_TV_A"
-            displayName="@string/display_name_thtv_adults"
-            description="@string/description_thtv_adults"
-            ageHint="18" />
-        <order>
-            <rating id="TH_TV_P" />
-            <rating id="TH_TV_C" />
-        </order>
-        <order>
-            <rating id="TH_TV_G" />
-            <rating id="TH_TV_PG13" />
-            <rating id="TH_TV_PG18" />
-            <rating id="TH_TV_A" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for TR TV -->
-    <rating-system-definition id="TR_TV"
-        displayName="@string/display_name_trtv"
-        country="TR">
-        <rating-definition id="TR_TV_G"
-            displayName="@string/display_name_trtv_g"
-            description="@string/description_trtv_g"
-            ageHint="0" />
-        <rating-definition id="TR_TV_7"
-            displayName="@string/display_name_trtv_7"
-            description="@string/description_trtv_7"
-            ageHint="7" />
-        <rating-definition id="TR_TV_13"
-            displayName="@string/display_name_trtv_13"
-            description="@string/description_trtv_13"
-            ageHint="13" />
-        <rating-definition id="TR_TV_18"
-            displayName="@string/display_name_trtv_18"
-            description="@string/description_trtv_18"
-            ageHint="18" />
-        <order>
-            <rating id="TR_TV_G" />
-            <rating id="TR_TV_7" />
-            <rating id="TR_TV_13" />
-            <rating id="TR_TV_18" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for TW TV -->
-    <rating-system-definition id="TW_TV"
-        displayName="@string/display_name_twtv"
-        country="TW">
-        <rating-definition id="TW_TV_G"
-            displayName="@string/display_name_twtv_g"
-            description="@string/description_twtv_g"
-            ageHint="0" />
-        <rating-definition id="TW_TV_P"
-            displayName="@string/display_name_twtv_p"
-            description="@string/description_twtv_p"
-            ageHint="6" />
-        <rating-definition id="TW_TV_PG"
-            displayName="@string/display_name_twtv_pg"
-            description="@string/description_twtv_pg"
-            ageHint="12" />
-        <rating-definition id="TW_TV_R"
-            displayName="@string/display_name_twtv_r"
-            description="@string/description_twtv_r"
-            ageHint="18" />
-        <order>
-            <rating id="TW_TV_G" />
-            <rating id="TW_TV_P" />
-            <rating id="TW_TV_PG" />
-            <rating id="TW_TV_R" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for UA TV -->
-    <rating-system-definition id="UA_TV"
-        displayName="@string/display_name_uatv"
-        country="UA">
-        <rating-definition id="UA_TV_G"
-            displayName="@string/display_name_uatv_green circle"
-            description="@string/description_uatv_green circle"
-            ageHint="0" />
-        <rating-definition id="UA_TV_Y"
-            displayName="@string/display_name_uatv_yellow triangle"
-            description="@string/description_uatv_yellow triangle"
-            ageHint="12" />
-        <rating-definition id="UA_TV_R"
-            displayName="@string/display_name_uatv_red square"
-            description="@string/description_uatv_red square"
-            ageHint="18" />
-        <order>
-            <rating id="UA_TV_G" />
-            <rating id="UA_TV_Y" />
-            <rating id="UA_TV_R" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for US TV -->
-    <rating-system-definition id="US_TV"
-        displayName="@string/display_name_ustv"
-        description="@string/description_ustv"
-        country="US">
-        <sub-rating-definition id="US_TV_D"
-            displayName="@string/display_name_ustv_d"
-            description="@string/description_ustv_d" />
-        <sub-rating-definition id="US_TV_L"
-            displayName="@string/display_name_ustv_l"
-            description="@string/description_ustv_l" />
-        <sub-rating-definition id="US_TV_S"
-            displayName="@string/display_name_ustv_s"
-            description="@string/description_ustv_s" />
-        <sub-rating-definition id="US_TV_V"
-            displayName="@string/display_name_ustv_v"
-            description="@string/description_ustv_v" />
-        <sub-rating-definition id="US_TV_FV"
-            displayName="@string/display_name_ustv_fv"
-            description="@string/description_ustv_fv" />
-
-        <rating-definition id="US_TV_Y"
-            displayName="@string/display_name_ustv_y"
-            description="@string/description_ustv_y"
-            ageHint="0" />
-        <rating-definition id="US_TV_Y7"
-            displayName="@string/display_name_ustv_y7"
-            description="@string/description_ustv_y7"
-            ageHint="7">
-            <sub-rating id="US_TV_FV" />
-        </rating-definition>
-        <rating-definition id="US_TV_G"
-            displayName="@string/display_name_ustv_g"
-            description="@string/description_ustv_g"
-            ageHint="0" />
-        <rating-definition id="US_TV_PG"
-            displayName="@string/display_name_ustv_pg"
-            description="@string/description_ustv_pg"
-            ageHint="14">
-            <sub-rating id="US_TV_D" />
-            <sub-rating id="US_TV_L" />
-            <sub-rating id="US_TV_S" />
-            <sub-rating id="US_TV_V" />
-        </rating-definition>
-        <rating-definition id="US_TV_14"
-            displayName="@string/display_name_ustv_14"
-            description="@string/description_ustv_14"
-            ageHint="14">
-            <sub-rating id="US_TV_D" />
-            <sub-rating id="US_TV_L" />
-            <sub-rating id="US_TV_S" />
-            <sub-rating id="US_TV_V" />
-        </rating-definition>
-        <rating-definition id="US_TV_MA"
-            displayName="@string/display_name_ustv_ma"
-            description="@string/description_ustv_ma"
-            ageHint="17">
-            <sub-rating id="US_TV_L" />
-            <sub-rating id="US_TV_S" />
-            <sub-rating id="US_TV_V" />
-        </rating-definition>
-        <order>
-            <rating id="US_TV_Y" />
-            <rating id="US_TV_Y7" />
-        </order>
-        <order>
-            <rating id="US_TV_G" />
-            <rating id="US_TV_PG" />
-            <rating id="US_TV_14" />
-            <rating id="US_TV_MA" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for VE TV -->
-    <rating-system-definition id="VE_TV"
-        displayName="@string/display_name_vetv"
-        country="VE">
-        <rating-definition id="VE_TV_TU"
-            displayName="@string/display_name_vetv_tu"
-            description="@string/description_vetv_tu"
-            ageHint="0" />
-        <rating-definition id="VE_TV_SU"
-            displayName="@string/display_name_vetv_su"
-            description="@string/description_vetv_su"
-            ageHint="15" />
-        <rating-definition id="VE_TV_A"
-            displayName="@string/display_name_vetv_a"
-            description="@string/description_vetv_a"
-            ageHint="18" />
-        <order>
-            <rating id="VE_TV_TU" />
-            <rating id="VE_TV_SU" />
-            <rating id="VE_TV_A" />
-        </order>
-    </rating-system-definition>
-
-    <!-- TV content rating system for ZA TV -->
-    <rating-system-definition id="ZA_TV"
-        displayName="@string/display_name_zatv"
-        country="ZA">
-        <sub-rating-definition id="ZA_TV_D"
-            displayName="@string/display_name_zatv_d"
-            description="@string/description_zatv_d" />
-        <sub-rating-definition id="ZA_TV_V"
-            displayName="@string/display_name_zatv_v"
-            description="@string/description_zatv_v" />
-        <sub-rating-definition id="ZA_TV_N"
-            displayName="@string/display_name_zatv_n"
-            description="@string/description_zatv_n" />
-        <sub-rating-definition id="ZA_TV_P"
-            displayName="@string/display_name_zatv_p"
-            description="@string/description_zatv_p" />
-        <sub-rating-definition id="ZA_TV_S"
-            displayName="@string/display_name_zatv_s"
-            description="@string/description_zatv_s" />
-        <sub-rating-definition id="ZA_TV_L"
-            displayName="@string/display_name_zatv_l"
-            description="@string/description_zatv_l" />
-        <rating-definition id="ZA_TV_F"
-            displayName="@string/display_name_zatv_f"
-            description="@string/description_zatv_f"
-            ageHint="0">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <rating-definition id="ZA_TV_PG"
-            displayName="@string/display_name_zatv_pg"
-            description="@string/description_zatv_pg"
-            ageHint="0">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <rating-definition id="ZA_TV_13"
-            displayName="@string/display_name_zatv_13"
-            description="@string/description_zatv_13"
-            ageHint="13">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <rating-definition id="ZA_TV_16"
-            displayName="@string/display_name_zatv_16"
-            description="@string/description_zatv_16"
-            ageHint="16">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <rating-definition id="ZA_TV_18"
-            displayName="@string/display_name_zatv_18"
-            description="@string/description_zatv_18"
-            ageHint="18">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <rating-definition id="ZA_TV_R18"
-            displayName="@string/display_name_zatv_r18"
-            description="@string/description_zatv_r18"
-            ageHint="18">
-            <sub-rating id="ZA_TV_D" />
-            <sub-rating id="ZA_TV_V" />
-            <sub-rating id="ZA_TV_N" />
-            <sub-rating id="ZA_TV_P" />
-            <sub-rating id="ZA_TV_S" />
-            <sub-rating id="ZA_TV_L" />
-        </rating-definition>
-        <order>
-            <rating id="ZA_TV_F" />
-            <rating id="ZA_TV_PG" />
-            <rating id="ZA_TV_13" />
-            <rating id="ZA_TV_16" />
-            <rating id="ZA_TV_18" />
-            <rating id="ZA_TV_R18" />
-        </order>
-    </rating-system-definition>
-</rating-system-definitions>
diff --git a/core/tests/ConnectivityManagerTest/assets/accesspoints.xml b/core/tests/ConnectivityManagerTest/assets/accesspoints.xml
deleted file mode 100644
index ce6eebc..0000000
--- a/core/tests/ConnectivityManagerTest/assets/accesspoints.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<resources>
-  <accesspoint>
-    <ssid>opennet</ssid>
-    <security>NONE</security>
-  </accesspoint>
-  <accesspoint>
-    <ssid>GoogleGuest</ssid>
-    <security>NONE</security>
-  </accesspoint>
-  <accesspoint>
-    <ssid>securenetdhcp</ssid>
-    <security>PSK</security>
-    <password>androidwifi</password>
-  </accesspoint>
-  <accesspoint>
-    <ssid>securenetstatic</ssid>
-    <security>PSK</security>
-    <password>androidwifi</password>
-    <ip>192.168.14.2</ip>
-    <gateway>192.168.14.1</gateway>
-    <networkprefixlength>24</networkprefixlength>
-    <dns1>192.168.14.1</dns1>
-    <dns2>192.168.1.9</dns2>
-  </accesspoint>
-<!-- TODO: This AP is outdated and only supports 2.4GHz.
-           Need to switch to a new dual-band AP.
-           Enable this test case again once the configuration is completed.
-     bug#: 9470594
-  <accesspoint>
-    <ssid>botnet</ssid>
-    <security>EAP</security>
-    <eap>PEAP</eap>
-    <phase2>MSCHAPV2</phase2>
-    <identity>donut</identity>
-    <password>android</password>
-  </accesspoint>
--->
-</resources>
-
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/AccessPointParserHelper.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/AccessPointParserHelper.java
deleted file mode 100644
index 116a31e..0000000
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/AccessPointParserHelper.java
+++ /dev/null
@@ -1,374 +0,0 @@
-/*
- * Copyright (C) 2010, 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.connectivitymanagertest;
-
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.SAXException;
-import org.xml.sax.helpers.DefaultHandler;
-
-import android.net.IpConfiguration.IpAssignment;
-import android.net.IpConfiguration.ProxySettings;
-import android.net.LinkAddress;
-import android.net.LinkProperties;
-import android.net.RouteInfo;
-import android.net.wifi.WifiConfiguration;
-import android.net.wifi.WifiConfiguration.AuthAlgorithm;
-import android.net.wifi.WifiConfiguration.KeyMgmt;
-import android.net.wifi.WifiEnterpriseConfig;
-
-import java.io.InputStream;
-import java.net.InetAddress;
-import java.net.UnknownHostException;
-import java.util.ArrayList;
-import java.util.List;
-
-
-/**
- * Help class to process configurations of access points saved in an XML file.
- * The configurations of an access point is included in tag
- * <accesspoint></accesspoint>. The supported configuration includes: ssid,
- * security, eap, phase2, identity, password, anonymousidentity, cacert, usercert,
- * in which each is included in the corresponding tags. Static IP setting is also supported.
- * Tags that can be used include: ip, gateway, networkprefixlength, dns1, dns2. All access points
- * have to be enclosed in tags of <resources></resources>.
- *
- * The following is a sample configuration file for an access point using EAP-PEAP with MSCHAP2.
- * <resources>
- *   <accesspoint>
- *   <ssid>testnet</ssid>
- *   <security>EAP</security>
- *   <eap>PEAP</eap>
- *   <phase2>MSCHAP2</phase2>
- *   <identity>donut</identity</identity>
- *   <password>abcdefgh</password>
- *   </accesspoint>
- * </resources>
- *
- * Note:ssid and security have to be the first two tags
- *      for static ip setting, tag "ip" should be listed before other fields: dns, gateway,
- *      networkprefixlength.
- */
-public class AccessPointParserHelper {
-    private static final String TAG = "AccessPointParserHelper";
-    static final int NONE = 0;
-    static final int WEP = 1;
-    static final int PSK = 2;
-    static final int EAP = 3;
-
-    List<WifiConfiguration> networks = new ArrayList<WifiConfiguration>();
-
-    private int getSecurityType (String security) {
-        if (security.equalsIgnoreCase("NONE")) {
-            return NONE;
-        } else if (security.equalsIgnoreCase("WEP")) {
-            return WEP;
-        } else if (security.equalsIgnoreCase("PSK")) {
-            return PSK;
-        } else if (security.equalsIgnoreCase("EAP")) {
-            return EAP;
-        } else {
-            return -1;
-        }
-    }
-
-    private boolean validateEapValue(String value) {
-        if (value.equalsIgnoreCase("PEAP") ||
-                value.equalsIgnoreCase("TLS") ||
-                value.equalsIgnoreCase("TTLS")) {
-            return true;
-        } else {
-            return false;
-        }
-    }
-
-    DefaultHandler mHandler = new DefaultHandler() {
-
-        boolean ssid = false;
-        boolean security = false;
-        boolean password = false;
-        boolean ip = false;
-        boolean gateway = false;
-        boolean networkprefix = false;
-        boolean dns1 = false;
-        boolean dns2 = false;
-        boolean eap = false;
-        boolean phase2 = false;
-        boolean identity = false;
-        boolean anonymousidentity = false;
-        boolean cacert = false;
-        boolean usercert = false;
-        WifiConfiguration config = null;
-        int securityType = NONE;
-        LinkProperties mLinkProperties = null;
-        InetAddress mInetAddr = null;
-
-        @Override
-        public void startElement(String uri, String localName, String tagName,
-                Attributes attributes) throws SAXException {
-            if (tagName.equalsIgnoreCase("accesspoint")) {
-                config = new WifiConfiguration();
-            }
-            if (tagName.equalsIgnoreCase("ssid")) {
-                ssid = true;
-            }
-            if (tagName.equalsIgnoreCase("security")) {
-                security = true;
-            }
-            if (tagName.equalsIgnoreCase("password")) {
-                password = true;
-            }
-            if (tagName.equalsIgnoreCase("eap")) {
-                eap = true;
-            }
-            if (tagName.equalsIgnoreCase("phase2")) {
-                phase2 = true;
-            }
-            if (tagName.equalsIgnoreCase("identity")) {
-                identity = true;
-            }
-            if (tagName.equalsIgnoreCase("anonymousidentity")) {
-                anonymousidentity = true;
-            }
-            if (tagName.equalsIgnoreCase("cacert")) {
-                cacert = true;
-            }
-            if (tagName.equalsIgnoreCase("usercert")) {
-                usercert = true;
-            }
-            if (tagName.equalsIgnoreCase("ip")) {
-                mLinkProperties = new LinkProperties();
-                ip = true;
-            }
-            if (tagName.equalsIgnoreCase("gateway")) {
-                gateway = true;
-            }
-            if (tagName.equalsIgnoreCase("networkprefixlength")) {
-                networkprefix = true;
-            }
-            if (tagName.equalsIgnoreCase("dns1")) {
-                dns1 = true;
-            }
-            if (tagName.equalsIgnoreCase("dns2")) {
-                dns2 = true;
-            }
-        }
-
-        @Override
-        public void endElement(String uri, String localName, String tagName) throws SAXException {
-            if (tagName.equalsIgnoreCase("accesspoint")) {
-                if (mLinkProperties != null) {
-                    config.setIpAssignment(IpAssignment.STATIC);
-                    config.setLinkProperties(mLinkProperties);
-                } else {
-                    config.setIpAssignment(IpAssignment.DHCP);
-                }
-                config.setProxySettings(ProxySettings.NONE);
-                networks.add(config);
-                mLinkProperties = null;
-            }
-        }
-
-        @Override
-        public void characters(char ch[], int start, int length) throws SAXException {
-            if (ssid) {
-                config.SSID = new String(ch, start, length);
-                ssid = false;
-            }
-            if (security) {
-                String securityStr = (new String(ch, start, length)).toUpperCase();
-                securityType = getSecurityType(securityStr);
-                switch (securityType) {
-                    case NONE:
-                        config.allowedKeyManagement.set(KeyMgmt.NONE);
-                        break;
-                    case WEP:
-                        config.allowedKeyManagement.set(KeyMgmt.NONE);
-                        config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
-                        config.allowedAuthAlgorithms.set(AuthAlgorithm.SHARED);
-                        break;
-                    case PSK:
-                        config.allowedKeyManagement.set(KeyMgmt.WPA_PSK);
-                        break;
-                    case EAP:
-                        config.allowedKeyManagement.set(KeyMgmt.WPA_EAP);
-                        config.allowedKeyManagement.set(KeyMgmt.IEEE8021X);
-                        // Initialize other fields.
-                        config.enterpriseConfig.setPhase2Method(WifiEnterpriseConfig.Phase2.NONE);
-                        config.enterpriseConfig.setCaCertificateAlias("");
-                        config.enterpriseConfig.setClientCertificateAlias("");
-                        config.enterpriseConfig.setIdentity("");
-                        config.enterpriseConfig.setAnonymousIdentity("");
-                        break;
-                    default:
-                        throw new SAXException();
-                }
-                security = false;
-            }
-            if (password) {
-                String passwordStr = new String(ch, start, length);
-                int len = passwordStr.length();
-                if (len == 0) {
-                    throw new SAXException();
-                }
-                if (securityType == WEP) {
-                    if ((len == 10 || len == 26 || len == 58) &&
-                            passwordStr.matches("[0-9A-Fa-f]*")) {
-                        config.wepKeys[0] = passwordStr;
-                    } else {
-                        config.wepKeys[0] = '"' + passwordStr + '"';
-                    }
-                } else if (securityType == PSK) {
-                    if (passwordStr.matches("[0-9A-Fa-f]{64}")) {
-                        config.preSharedKey = passwordStr;
-                    } else {
-                        config.preSharedKey = '"' + passwordStr + '"';
-                    }
-                } else if (securityType == EAP) {
-                    config.enterpriseConfig.setPassword(passwordStr);
-                } else {
-                    throw new SAXException();
-                }
-                password = false;
-            }
-            if (eap) {
-                String eapValue = new String(ch, start, length);
-                if (!validateEapValue(eapValue)) {
-                    throw new SAXException();
-                }
-                if (eapValue.equals("TLS")) {
-                    config.enterpriseConfig.setEapMethod(WifiEnterpriseConfig.Eap.TLS);
-                } else if (eapValue.equals("TTLS")) {
-                    config.enterpriseConfig.setEapMethod(WifiEnterpriseConfig.Eap.TTLS);
-                } else if (eapValue.equals("PEAP")) {
-                    config.enterpriseConfig.setEapMethod(WifiEnterpriseConfig.Eap.PEAP);
-                }
-                eap = false;
-            }
-            if (phase2) {
-                String phase2Value = new String(ch, start, length);
-                if (phase2Value.equals("PAP")) {
-                    config.enterpriseConfig.setPhase2Method(WifiEnterpriseConfig.Phase2.PAP);
-                } else if (phase2Value.equals("MSCHAP")) {
-                    config.enterpriseConfig.setPhase2Method(WifiEnterpriseConfig.Phase2.MSCHAP);
-                } else if (phase2Value.equals("MSCHAPV2")) {
-                    config.enterpriseConfig.setPhase2Method(WifiEnterpriseConfig.Phase2.MSCHAPV2);
-                } else if (phase2Value.equals("GTC")) {
-                    config.enterpriseConfig.setPhase2Method(WifiEnterpriseConfig.Phase2.GTC);
-                }
-                phase2 = false;
-            }
-            if (identity) {
-                String identityValue = new String(ch, start, length);
-                config.enterpriseConfig.setIdentity(identityValue);
-                identity = false;
-            }
-            if (anonymousidentity) {
-                String anonyId = new String(ch, start, length);
-                config.enterpriseConfig.setAnonymousIdentity(anonyId);
-                anonymousidentity = false;
-            }
-            if (cacert) {
-                String cacertValue = new String(ch, start, length);
-                config.enterpriseConfig.setCaCertificateAlias(cacertValue);
-                cacert = false;
-            }
-            if (usercert) {
-                String usercertValue = new String(ch, start, length);
-                config.enterpriseConfig.setClientCertificateAlias(usercertValue);
-                usercert = false;
-            }
-            if (ip) {
-                try {
-                    String ipAddr = new String(ch, start, length);
-                    if (!InetAddress.isNumeric(ipAddr)) {
-                        throw new SAXException();
-                    }
-                    mInetAddr = InetAddress.getByName(ipAddr);
-                } catch (UnknownHostException e) {
-                    throw new SAXException();
-                }
-                ip = false;
-            }
-            if (gateway) {
-                try {
-                    String gwAddr = new String(ch, start, length);
-                    if (!InetAddress.isNumeric(gwAddr)) {
-                        throw new SAXException();
-                    }
-                    mLinkProperties.addRoute(new RouteInfo(InetAddress.getByName(gwAddr)));
-                } catch (UnknownHostException e) {
-                    throw new SAXException();
-                }
-                gateway = false;
-            }
-            if (networkprefix) {
-                try {
-                    int nwPrefixLength = Integer.parseInt(new String(ch, start, length));
-                    if ((nwPrefixLength < 0) || (nwPrefixLength > 32)) {
-                        throw new SAXException();
-                    }
-                    mLinkProperties.addLinkAddress(new LinkAddress(mInetAddr, nwPrefixLength));
-                } catch (NumberFormatException e) {
-                    throw new SAXException();
-                }
-                networkprefix = false;
-            }
-            if (dns1) {
-                try {
-                    String dnsAddr = new String(ch, start, length);
-                    if (!InetAddress.isNumeric(dnsAddr)) {
-                        throw new SAXException();
-                    }
-                    mLinkProperties.addDnsServer(InetAddress.getByName(dnsAddr));
-                } catch (UnknownHostException e) {
-                    throw new SAXException();
-                }
-                dns1 = false;
-            }
-            if (dns2) {
-                try {
-                    String dnsAddr = new String(ch, start, length);
-                    if (!InetAddress.isNumeric(dnsAddr)) {
-                        throw new SAXException();
-                    }
-                    mLinkProperties.addDnsServer(InetAddress.getByName(dnsAddr));
-                } catch (UnknownHostException e) {
-                    throw new SAXException();
-                }
-                dns2 = false;
-            }
-        }
-    };
-
-    /**
-     * Process the InputStream in
-     * @param in is the InputStream that can be used for XML parsing
-     * @throws Exception
-     */
-    public AccessPointParserHelper(InputStream in) throws Exception {
-        SAXParserFactory factory = SAXParserFactory.newInstance();
-        SAXParser saxParser = factory.newSAXParser();
-        saxParser.parse(in, mHandler);
-    }
-
-    public List<WifiConfiguration> getNetworkConfigurations() throws Exception {
-        return networks;
-    }
-}
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerStressTestRunner.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerStressTestRunner.java
index 3ec9031..fbaf0f3 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerStressTestRunner.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerStressTestRunner.java
@@ -35,14 +35,14 @@
  */
 
 public class ConnectivityManagerStressTestRunner extends InstrumentationTestRunner {
-    public int mSoftapIterations = 100;
-    public int mScanIterations = 100;
-    public int mReconnectIterations = 100;
+    private int mSoftApIterations = 100;
+    private int mScanIterations = 100;
+    private int mReconnectIterations = 100;
     // sleep time before restart wifi, default is set to 2 minutes
-    public int mSleepTime = 2 * 60 * 1000;
-    public String mReconnectSsid = "securenetdhcp";
-    public String mReconnectPassword = "androidwifi";
-    public boolean mWifiOnlyFlag = false;
+    private long mSleepTime = 2 * 60 * 1000;
+    private String mReconnectSsid = null;
+    private String mReconnectPassword = null;
+    private boolean mWifiOnlyFlag = false;
 
     @Override
     public TestSuite getAllTests() {
@@ -60,15 +60,15 @@
     @Override
     public void onCreate(Bundle icicle) {
         super.onCreate(icicle);
-        String valueStr = (String) icicle.get("softap_iterations");
+        String valueStr = icicle.getString("softap_iterations");
         if (valueStr != null) {
             int iteration = Integer.parseInt(valueStr);
             if (iteration > 0) {
-                mSoftapIterations = iteration;
+                mSoftApIterations = iteration;
             }
         }
 
-        String scanIterationStr = (String) icicle.get("scan_iterations");
+        String scanIterationStr = icicle.getString("scan_iterations");
         if (scanIterationStr != null) {
             int scanIteration = Integer.parseInt(scanIterationStr);
             if (scanIteration > 0) {
@@ -76,17 +76,17 @@
             }
         }
 
-        String ssidStr= (String) icicle.get("reconnect_ssid");
+        String ssidStr= icicle.getString("reconnect_ssid");
         if (ssidStr != null) {
             mReconnectSsid = ssidStr;
         }
 
-        String passwordStr = (String) icicle.get("reconnect_password");
+        String passwordStr = icicle.getString("reconnect_password");
         if (passwordStr != null) {
             mReconnectPassword = passwordStr;
         }
 
-        String reconnectStr = (String) icicle.get("reconnect_iterations");
+        String reconnectStr = icicle.getString("reconnect_iterations");
         if (reconnectStr != null) {
             int iteration = Integer.parseInt(reconnectStr);
             if (iteration > 0) {
@@ -94,7 +94,7 @@
             }
         }
 
-        String sleepTimeStr = (String) icicle.get("sleep_time");
+        String sleepTimeStr = icicle.getString("sleep_time");
         if (sleepTimeStr != null) {
             int sleepTime = Integer.parseInt(sleepTimeStr);
             if (sleepTime > 0) {
@@ -102,9 +102,37 @@
             }
         }
 
-        String wifiOnlyFlag = (String) icicle.get("wifi-only");
+        String wifiOnlyFlag = icicle.getString("wifi-only");
         if (wifiOnlyFlag != null) {
             mWifiOnlyFlag = true;
         }
     }
+
+    public int getSoftApInterations() {
+        return mSoftApIterations;
+    }
+
+    public int getScanIterations() {
+        return mScanIterations;
+    }
+
+    public int getReconnectIterations() {
+        return mReconnectIterations;
+    }
+
+    public boolean isWifiOnly() {
+        return mWifiOnlyFlag;
+    }
+
+    public long getSleepTime() {
+        return mSleepTime;
+    }
+
+    public String getReconnectSsid() {
+        return mReconnectSsid;
+    }
+
+    public String getReconnectPassword() {
+        return mReconnectPassword;
+    }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestBase.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestBase.java
index 30eda75..80d5668 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestBase.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestBase.java
@@ -17,30 +17,24 @@
 package com.android.connectivitymanagertest;
 
 import android.app.KeyguardManager;
-import android.content.Context;
 import android.content.BroadcastReceiver;
+import android.content.Context;
 import android.content.Intent;
 import android.content.IntentFilter;
 import android.net.ConnectivityManager;
 import android.net.NetworkInfo;
 import android.net.NetworkInfo.State;
+import android.net.wifi.ScanResult;
 import android.net.wifi.WifiConfiguration;
 import android.net.wifi.WifiManager;
-import android.net.wifi.WifiConfiguration.KeyMgmt;
-import android.os.Handler;
-import android.os.Message;
 import android.os.PowerManager;
 import android.os.SystemClock;
 import android.test.InstrumentationTestCase;
 import android.util.Log;
 import android.view.KeyEvent;
 
-import com.android.internal.util.AsyncChannel;
-
 import java.io.IOException;
-import java.io.InputStream;
 import java.net.UnknownHostException;
-import java.util.ArrayList;
 import java.util.List;
 
 
@@ -55,51 +49,43 @@
  */
 public class ConnectivityManagerTestBase extends InstrumentationTestCase {
 
-    public static final String LOG_TAG = "ConnectivityManagerTestBase";
-    public static final int WAIT_FOR_SCAN_RESULT = 10 * 1000; //10 seconds
-    public static final int WIFI_SCAN_TIMEOUT = 50 * 1000; // 50 seconds
-    public static final int SHORT_TIMEOUT = 5 * 1000; // 5 seconds
-    public static final long LONG_TIMEOUT = 50 * 1000;  // 50 seconds
-    public static final long WIFI_CONNECTION_TIMEOUT = 5 * 60 * 1000; // 5 minutes
+    private static final String PING_IP_ADDR = "8.8.8.8";
+
+    protected static final int WAIT_FOR_SCAN_RESULT = 10 * 1000; //10 seconds
+    protected static final int WIFI_SCAN_TIMEOUT = 50 * 1000; // 50 seconds
+    protected static final int SHORT_TIMEOUT = 5 * 1000; // 5 seconds
+    protected static final long LONG_TIMEOUT = 2 * 60 * 1000;  // 2 minutes
+    protected static final long WIFI_CONNECTION_TIMEOUT = 5 * 60 * 1000; // 5 minutes
     // 2 minutes timer between wifi stop and start
-    public static final long  WIFI_STOP_START_INTERVAL = 2 * 60 * 1000; // 2 minutes
+    protected static final long  WIFI_STOP_START_INTERVAL = 2 * 60 * 1000; // 2 minutes
     // Set ping test timer to be 3 minutes
-    public static final long PING_TIMER = 3 * 60 *1000; // 3 minutes
-    public static final int SUCCESS = 0;  // for Wifi tethering state change
-    public static final int FAILURE = 1;
-    public static final int INIT = -1;
-    private static final String ACCESS_POINT_FILE = "accesspoints.xml";
-    public ConnectivityReceiver mConnectivityReceiver = null;
-    public WifiReceiver mWifiReceiver = null;
-    private AccessPointParserHelper mParseHelper = null;
-    /*
-     * Track network connectivity information
-     */
-    public State mState;
-    public NetworkInfo mNetworkInfo;
-    public NetworkInfo mOtherNetworkInfo;
-    public boolean mIsFailOver;
-    public String mReason;
-    public boolean mScanResultIsAvailable = false;
-    public ConnectivityManager mCM;
-    public Object wifiObject = new Object();
-    public Object connectivityObject = new Object();
-    public int mWifiState;
-    public NetworkInfo mWifiNetworkInfo;
-    public String mBssid;
-    public String mPowerSsid = "opennet"; //Default power SSID
+    protected static final long PING_TIMER = 3 * 60 *1000; // 3 minutes
+    protected static final int SUCCESS = 0;  // for Wifi tethering state change
+    protected static final int FAILURE = 1;
+    protected static final int INIT = -1;
+
+    protected final String mLogTag;
+
+    private ConnectivityReceiver mConnectivityReceiver = null;
+    private WifiReceiver mWifiReceiver = null;
+
+    private long mLastConnectivityChangeTime = -1;
+    protected ConnectivityManager mCm;
     private Context mContext;
-    public boolean scanResultAvailable = false;
+    protected List<ScanResult> mLastScanResult;
+    protected Object mWifiScanResultLock = new Object();
 
     /* Control Wifi States */
     public WifiManager mWifiManager;
-    /* Verify connectivity state */
-    public static final int NUM_NETWORK_TYPES = ConnectivityManager.MAX_NETWORK_TYPE + 1;
-    NetworkState[] connectivityState = new NetworkState[NUM_NETWORK_TYPES];
 
-    // For wifi tethering tests
-    private String[] mWifiRegexs;
-    public int mWifiTetherResult = INIT;    // -1 is initialization state
+    public ConnectivityManagerTestBase(String logTag) {
+        super();
+        mLogTag = logTag;
+    }
+
+    protected long getLastConnectivityChangeTime() {
+        return mLastConnectivityChangeTime;
+    }
 
     /**
      * A wrapper of a broadcast receiver which provides network connectivity information
@@ -108,40 +94,12 @@
     private class ConnectivityReceiver extends BroadcastReceiver {
         @Override
         public void onReceive(Context context, Intent intent) {
-            log("ConnectivityReceiver: onReceive() is called with " + intent);
+            mLastConnectivityChangeTime = SystemClock.uptimeMillis();
+            logv("ConnectivityReceiver: " + intent);
             String action = intent.getAction();
             if (!action.equals(ConnectivityManager.CONNECTIVITY_ACTION)) {
                 Log.v("ConnectivityReceiver", "onReceive() called with " + intent);
-                return;
             }
-
-            boolean noConnectivity =
-                intent.getBooleanExtra(ConnectivityManager.EXTRA_NO_CONNECTIVITY, false);
-
-            if (noConnectivity) {
-                mState = State.DISCONNECTED;
-            } else {
-                mState = State.CONNECTED;
-            }
-
-            mNetworkInfo = (NetworkInfo)
-                intent.getParcelableExtra(ConnectivityManager.EXTRA_NETWORK_INFO);
-
-            mOtherNetworkInfo = (NetworkInfo)
-                intent.getParcelableExtra(ConnectivityManager.EXTRA_OTHER_NETWORK_INFO);
-
-            mReason = intent.getStringExtra(ConnectivityManager.EXTRA_REASON);
-            mIsFailOver = intent.getBooleanExtra(ConnectivityManager.EXTRA_IS_FAILOVER, false);
-
-            log("mNetworkInfo: " + mNetworkInfo.toString());
-            if (mOtherNetworkInfo != null) {
-                log("mOtherNetworkInfo: " + mOtherNetworkInfo.toString());
-            }
-            recordNetworkState(mNetworkInfo.getType(), mNetworkInfo.getState());
-            if (mOtherNetworkInfo != null) {
-                recordNetworkState(mOtherNetworkInfo.getType(), mOtherNetworkInfo.getState());
-            }
-            notifyNetworkConnectivityChange();
         }
     }
 
@@ -151,74 +109,31 @@
             String action = intent.getAction();
             Log.v("WifiReceiver", "onReceive() is calleld with " + intent);
             if (action.equals(WifiManager.SCAN_RESULTS_AVAILABLE_ACTION)) {
-                log("scan results are available");
-                notifyScanResult();
-            } else if (action.equals(WifiManager.NETWORK_STATE_CHANGED_ACTION)) {
-                mWifiNetworkInfo =
-                    (NetworkInfo) intent.getParcelableExtra(WifiManager.EXTRA_NETWORK_INFO);
-                log("mWifiNetworkInfo: " + mWifiNetworkInfo.toString());
-                if (mWifiNetworkInfo.getState() == State.CONNECTED) {
-                    mBssid = intent.getStringExtra(WifiManager.EXTRA_BSSID);
+                logv("scan results are available");
+                synchronized (mWifiScanResultLock) {
+                    mLastScanResult = mWifiManager.getScanResults();
+                    mWifiScanResultLock.notifyAll();
                 }
-                notifyWifiState();
-            } else if (action.equals(WifiManager.WIFI_STATE_CHANGED_ACTION)) {
-                mWifiState = intent.getIntExtra(WifiManager.EXTRA_WIFI_STATE,
-                                                WifiManager.WIFI_STATE_UNKNOWN);
-                notifyWifiState();
-            } else if (action.equals(WifiManager.WIFI_AP_STATE_CHANGED_ACTION)) {
-                notifyWifiAPState();
-            } else if (action.equals(ConnectivityManager.ACTION_TETHER_STATE_CHANGED)) {
-                ArrayList<String> available = intent.getStringArrayListExtra(
-                        ConnectivityManager.EXTRA_AVAILABLE_TETHER);
-                ArrayList<String> active = intent.getStringArrayListExtra(
-                        ConnectivityManager.EXTRA_ACTIVE_TETHER);
-                ArrayList<String> errored = intent.getStringArrayListExtra(
-                        ConnectivityManager.EXTRA_ERRORED_TETHER);
-                updateTetherState(available.toArray(), active.toArray(), errored.toArray());
-            }
-            else {
-                return;
-            }
-        }
-    }
-
-    private class WifiServiceHandler extends Handler {
-        @Override
-        public void handleMessage(Message msg) {
-            switch (msg.what) {
-                case AsyncChannel.CMD_CHANNEL_HALF_CONNECTED:
-                    if (msg.arg1 == AsyncChannel.STATUS_SUCCESSFUL) {
-                        //AsyncChannel in msg.obj
-                    } else {
-                        log("Failed to establish AsyncChannel connection");
-                    }
-                    break;
-                default:
-                    //Ignore
-                    break;
             }
         }
     }
 
     @Override
-    public void setUp() throws Exception {
-        mState = State.UNKNOWN;
-        scanResultAvailable = false;
+    protected void setUp() throws Exception {
+        mLastScanResult = null;
         mContext = getInstrumentation().getContext();
 
         // Get an instance of ConnectivityManager
-        mCM = (ConnectivityManager)mContext.getSystemService(Context.CONNECTIVITY_SERVICE);
+        mCm = (ConnectivityManager)mContext.getSystemService(Context.CONNECTIVITY_SERVICE);
         // Get an instance of WifiManager
         mWifiManager =(WifiManager)mContext.getSystemService(Context.WIFI_SERVICE);
 
         if (mWifiManager.isWifiApEnabled()) {
             // if soft AP is enabled, disable it
             mWifiManager.setWifiApEnabled(null, false);
-            log("Disable soft ap");
+            logv("Disable soft ap");
         }
 
-        initializeNetworkStates();
-
         // register a connectivity receiver for CONNECTIVITY_ACTION;
         mConnectivityReceiver = new ConnectivityReceiver();
         mContext.registerReceiver(mConnectivityReceiver,
@@ -234,213 +149,66 @@
         mIntentFilter.addAction(ConnectivityManager.ACTION_TETHER_STATE_CHANGED);
         mContext.registerReceiver(mWifiReceiver, mIntentFilter);
 
-        log("Clear Wifi before we start the test.");
+        logv("Clear Wifi before we start the test.");
         removeConfiguredNetworksAndDisableWifi();
-        mWifiRegexs = mCM.getTetherableWifiRegexs();
      }
 
-    public List<WifiConfiguration> loadNetworkConfigurations() throws Exception {
-        InputStream in = mContext.getAssets().open(ACCESS_POINT_FILE);
-        mParseHelper = new AccessPointParserHelper(in);
-        return mParseHelper.getNetworkConfigurations();
-    }
-
-    // for each network type, initialize network states to UNKNOWN, and no verification flag is set
-    public void initializeNetworkStates() {
-        for (int networkType = NUM_NETWORK_TYPES - 1; networkType >=0; networkType--) {
-            connectivityState[networkType] =  new NetworkState();
-            log("Initialize network state for " + networkType + ": " +
-                    connectivityState[networkType].toString());
-        }
-    }
-
-    // deposit a network state
-    public void recordNetworkState(int networkType, State networkState) {
-        log("record network state for network " +  networkType +
-                ", state is " + networkState);
-        if (connectivityState == null) {
-             log("ConnectivityState is null");
-        }
-        if (connectivityState[networkType] == null) {
-             log("connectivityState[networkType] is null");
-        }
-        connectivityState[networkType].recordState(networkState);
-    }
-
-    // set the state transition criteria
-    public void setStateTransitionCriteria(int networkType, State initState,
-            int transitionDir, State targetState) {
-        connectivityState[networkType].setStateTransitionCriteria(
-                initState, transitionDir, targetState);
-    }
-
-    // Validate the states recorded
-    public boolean validateNetworkStates(int networkType) {
-        log("validate network state for " + networkType + ": ");
-        return connectivityState[networkType].validateStateTransition();
-    }
-
-    // return result from network state validation
-    public String getTransitionFailureReason(int networkType) {
-        log("get network state transition failure reason for " + networkType + ": " +
-                connectivityState[networkType].toString());
-        return connectivityState[networkType].getReason();
-    }
-
-    private void notifyNetworkConnectivityChange() {
-        synchronized(connectivityObject) {
-            log("notify network connectivity changed");
-            connectivityObject.notifyAll();
-        }
-    }
-    private void notifyScanResult() {
-        synchronized (this) {
-            log("notify that scan results are available");
-            scanResultAvailable = true;
-            this.notify();
-        }
-    }
-
-    private void notifyWifiState() {
-        synchronized (wifiObject) {
-            log("notify wifi state changed");
-            wifiObject.notify();
-        }
-    }
-
-    private void notifyWifiAPState() {
-        synchronized (this) {
-            log("notify wifi AP state changed");
-            this.notify();
-        }
-    }
-
-    // Update wifi tethering state
-    private void updateTetherState(Object[] available, Object[] tethered, Object[] errored) {
-        boolean wifiTethered = false;
-        boolean wifiErrored = false;
-
-        synchronized (this) {
-            for (Object obj: tethered) {
-                String str = (String)obj;
-                for (String tethRex: mWifiRegexs) {
-                    log("str: " + str +"tethRex: " + tethRex);
-                    if (str.matches(tethRex)) {
-                        wifiTethered = true;
-                    }
-                }
-            }
-
-            for (Object obj: errored) {
-                String str = (String)obj;
-                for (String tethRex: mWifiRegexs) {
-                    log("error: str: " + str +"tethRex: " + tethRex);
-                    if (str.matches(tethRex)) {
-                        wifiErrored = true;
-                    }
-                }
-            }
-
-            if (wifiTethered) {
-                mWifiTetherResult = SUCCESS;   // wifi tethering is successful
-            } else if (wifiErrored) {
-                mWifiTetherResult = FAILURE;   // wifi tethering failed
-            }
-            log("mWifiTetherResult: " + mWifiTetherResult);
-            this.notify();
-        }
-    }
-
-
-    // Wait for network connectivity state: CONNECTING, CONNECTED, SUSPENDED,
-    //                                      DISCONNECTING, DISCONNECTED, UNKNOWN
-    public boolean waitForNetworkState(int networkType, State expectedState, long timeout) {
-        long startTime = System.currentTimeMillis();
+    // wait for network connectivity state: CONNECTING, CONNECTED, SUSPENDED, DISCONNECTING,
+    //                                      DISCONNECTED, UNKNOWN
+    protected boolean waitForNetworkState(int networkType, State expectedState, long timeout) {
+        long startTime = SystemClock.uptimeMillis();
         while (true) {
-            if ((System.currentTimeMillis() - startTime) > timeout) {
-                log("waitForNetworkState time out, the state of network type " + networkType +
-                        " is: " + mCM.getNetworkInfo(networkType).getState());
-                if (mCM.getNetworkInfo(networkType).getState() != expectedState) {
-                    return false;
-                } else {
-                    // the broadcast has been sent out. the state has been changed.
-                    log("networktype: " + networkType + " state: " +
-                            mCM.getNetworkInfo(networkType));
-                    return true;
-                }
-            }
-            log("Wait for the connectivity state for network: " + networkType +
-                    " to be " + expectedState.toString());
-            synchronized (connectivityObject) {
-                try {
-                    connectivityObject.wait(SHORT_TIMEOUT);
-                } catch (InterruptedException e) {
-                    e.printStackTrace();
-                }
-                if ((mNetworkInfo.getType() != networkType) ||
-                    (mNetworkInfo.getState() != expectedState)) {
-                    log("network state for " + mNetworkInfo.getType() +
-                            "is: " + mNetworkInfo.getState());
-                    continue;
-                }
+            NetworkInfo ni = mCm.getNetworkInfo(networkType);
+            if (ni != null && expectedState.equals(ni.getState())) {
+                logv("waitForNetworkState success: %s", ni);
                 return true;
             }
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                logv("waitForNetworkState timeout: %s", ni);
+                return false;
+            }
+            logv("waitForNetworkState interim: %s", ni);
+            SystemClock.sleep(SHORT_TIMEOUT);
         }
     }
 
-    // Wait for Wifi state: WIFI_STATE_DISABLED, WIFI_STATE_DISABLING, WIFI_STATE_ENABLED,
+    // wait for Wifi state: WIFI_STATE_DISABLED, WIFI_STATE_DISABLING, WIFI_STATE_ENABLED,
     //                      WIFI_STATE_ENALBING, WIFI_STATE_UNKNOWN
-    public boolean waitForWifiState(int expectedState, long timeout) {
-        long startTime = System.currentTimeMillis();
+    protected boolean waitForWifiState(int expectedState, long timeout) {
+        long startTime = SystemClock.uptimeMillis();
         while (true) {
-            if ((System.currentTimeMillis() - startTime) > timeout) {
-                if (mWifiState != expectedState) {
-                    return false;
-                } else {
-                    return true;
-                }
-            }
-            log("Wait for wifi state to be: " + expectedState);
-            synchronized (wifiObject) {
-                try {
-                    wifiObject.wait(SHORT_TIMEOUT);
-                } catch (InterruptedException e) {
-                    e.printStackTrace();
-                }
-                if (mWifiState != expectedState) {
-                    log("Wifi state is: " + mWifiState);
-                    continue;
-                }
+            int state = mWifiManager.getWifiState();
+            if (state == expectedState) {
+                logv("waitForWifiState success: state=" + state);
                 return true;
             }
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                logv("waitForWifiState timeout: expected=%d, actual=%d", expectedState, state);
+                return false;
+            }
+            logv("waitForWifiState interim: expected=%d, actual=%d", expectedState, state);
+            SystemClock.sleep(SHORT_TIMEOUT);
         }
     }
 
     // Wait for Wifi AP state: WIFI_AP_STATE_DISABLED, WIFI_AP_STATE_DISABLING,
     //                         WIFI_AP_STATE_ENABLED, WIFI_STATE_ENALBING, WIFI_STATE_UNKNOWN
-    public boolean waitForWifiAPState(int expectedState, long timeout) {
-        long startTime = System.currentTimeMillis();
+    protected boolean waitForWifiApState(int expectedState, long timeout) {
+        long startTime = SystemClock.uptimeMillis();
         while (true) {
-            if ((System.currentTimeMillis() - startTime) > timeout) {
-                if (mWifiManager.getWifiApState() != expectedState) {
-                    return false;
-                } else {
-                    return true;
-                }
-            }
-            log("Wait for wifi AP state to be: " + expectedState);
-            synchronized (wifiObject) {
-                try {
-                    wifiObject.wait(SHORT_TIMEOUT);
-                } catch (InterruptedException e) {
-                    e.printStackTrace();
-                }
-                if (mWifiManager.getWifiApState() != expectedState) {
-                    log("Wifi state is: " + mWifiManager.getWifiApState());
-                    continue;
-                }
+            int state = mWifiManager.getWifiApState();
+            if (state == expectedState) {
+                logv("waitForWifiAPState success: state=" + state);
                 return true;
             }
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                logv(String.format("waitForWifiAPState timeout: expected=%d, actual=%d",
+                        expectedState, state));
+                return false;
+            }
+            logv(String.format("waitForWifiAPState interim: expected=%d, actual=%d",
+                    expectedState, state));
+            SystemClock.sleep(SHORT_TIMEOUT);
         }
     }
 
@@ -450,53 +218,58 @@
      * @return SUCCESS if tethering result is successful
      *         FAILURE if tethering result returns error.
      */
-    public int waitForTetherStateChange(long timeout) {
-        long startTime = System.currentTimeMillis();
+    protected boolean waitForTetherStateChange(long timeout) {
+        long startTime = SystemClock.uptimeMillis();
+        String[] wifiRegexes = mCm.getTetherableWifiRegexs();
         while (true) {
-            if ((System.currentTimeMillis() - startTime) > timeout) {
-                return mWifiTetherResult;
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                return false;
             }
-            log("Wait for wifi tethering result.");
-            synchronized (this) {
-                try {
-                    this.wait(SHORT_TIMEOUT);
-                } catch (InterruptedException e) {
-                    e.printStackTrace();
-                }
-                if (mWifiTetherResult == INIT ) {
-                    continue;
-                } else {
-                    return mWifiTetherResult;
+            String[] active = mCm.getTetheredIfaces();
+            String[] error = mCm.getTetheringErroredIfaces();
+            for (String iface: active) {
+                for (String regex: wifiRegexes) {
+                    if (iface.matches(regex)) {
+                        return true;
+                    }
                 }
             }
+            for (String iface: error) {
+                for (String regex: wifiRegexes) {
+                    if (iface.matches(regex)) {
+                        return false;
+                    }
+                }
+            }
+            SystemClock.sleep(SHORT_TIMEOUT);
         }
     }
 
     // Return true if device is currently connected to mobile network
-    public boolean isConnectedToMobile() {
-        return (mNetworkInfo.getType() == ConnectivityManager.TYPE_MOBILE);
+    protected boolean isConnectedToMobile() {
+        return (mCm.getActiveNetworkInfo().getType() == ConnectivityManager.TYPE_MOBILE);
     }
 
     // Return true if device is currently connected to Wifi
-    public boolean isConnectedToWifi() {
-        return (mNetworkInfo.getType() == ConnectivityManager.TYPE_WIFI);
+    protected boolean isConnectedToWifi() {
+        return (mCm.getActiveNetworkInfo().getType() == ConnectivityManager.TYPE_WIFI);
     }
 
-    public boolean enableWifi() {
+    protected boolean enableWifi() {
         return mWifiManager.setWifiEnabled(true);
     }
 
     // Turn screen off
-    public void turnScreenOff() {
-        log("Turn screen off");
+    protected void turnScreenOff() {
+        logv("Turn screen off");
         PowerManager pm =
             (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
         pm.goToSleep(SystemClock.uptimeMillis());
     }
 
     // Turn screen on
-    public void turnScreenOn() {
-        log("Turn screen on");
+    protected void turnScreenOn() {
+        logv("Turn screen on");
         PowerManager pm =
                 (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
         pm.wakeUp(SystemClock.uptimeMillis());
@@ -511,7 +284,7 @@
      * @param pingServerList a list of servers that can be used for ping test, can be null
      * @return true if the ping test is successful, false otherwise.
      */
-    public boolean pingTest(String[] pingServerList) {
+    protected boolean pingTest(String[] pingServerList) {
         String[] hostList = {"www.google.com", "www.yahoo.com",
                 "www.bing.com", "www.facebook.com", "www.ask.com"};
         if (pingServerList != null) {
@@ -524,7 +297,7 @@
                 // assume the chance that all servers are down is very small
                 for (int i = 0; i < hostList.length; i++ ) {
                     String host = hostList[i];
-                    log("Start ping test, ping " + host);
+                    logv("Start ping test, ping " + host);
                     Process p = Runtime.getRuntime().exec("ping -c 10 -w 100 " + host);
                     int status = p.waitFor();
                     if (status == 0) {
@@ -533,11 +306,11 @@
                     }
                 }
             } catch (UnknownHostException e) {
-                log("Ping test Fail: Unknown Host");
+                logv("Ping test Fail: Unknown Host");
             } catch (IOException e) {
-                log("Ping test Fail:  IOException");
+                logv("Ping test Fail:  IOException");
             } catch (InterruptedException e) {
-                log("Ping test Fail: InterruptedException");
+                logv("Ping test Fail: InterruptedException");
             }
         }
         // ping test timeout
@@ -549,30 +322,28 @@
      * If the device is already associated with a WiFi, disconnect and forget it,
      * We don't verify whether the connection is successful or not, leave this to the test
      */
-    public boolean connectToWifi(String knownSSID) {
-        WifiConfiguration config = new WifiConfiguration();
-        config.SSID = knownSSID;
-        config.allowedKeyManagement.set(KeyMgmt.NONE);
+    protected boolean connectToWifi(String ssid, String password) {
+        WifiConfiguration config;
+        if (password == null) {
+            config = WifiConfigurationHelper.createOpenConfig(ssid);
+        } else {
+            config = WifiConfigurationHelper.createPskConfig(ssid, password);
+        }
         return connectToWifiWithConfiguration(config);
     }
 
     /**
      * Connect to Wi-Fi with the given configuration. Note the SSID in the configuration
      * is pure string, we need to convert it to quoted string.
-     * @param config
-     * @return
      */
-    public boolean connectToWifiWithConfiguration(WifiConfiguration config) {
-        String ssid = config.SSID;
-        config.SSID = convertToQuotedString(ssid);
-
+    protected boolean connectToWifiWithConfiguration(WifiConfiguration config) {
         // If Wifi is not enabled, enable it
         if (!mWifiManager.isWifiEnabled()) {
-            log("Wifi is not enabled, enable it");
+            logv("Wifi is not enabled, enable it");
             mWifiManager.setWifiEnabled(true);
             // wait for the wifi state change before start scanning.
-            if (!waitForWifiState(WifiManager.WIFI_STATE_ENABLED, 2*SHORT_TIMEOUT)) {
-                log("wait for WIFI_STATE_ENABLED failed");
+            if (!waitForWifiState(WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT)) {
+                logv("wait for WIFI_STATE_ENABLED failed");
                 return false;
             }
         }
@@ -580,10 +351,13 @@
         // Save network configuration and connect to network without scanning
         mWifiManager.connect(config,
             new WifiManager.ActionListener() {
+                @Override
                 public void onSuccess() {
                 }
+
+                @Override
                 public void onFailure(int reason) {
-                    log("connect failure " + reason);
+                    logv("connect failure " + reason);
                 }
             });
         return true;
@@ -592,28 +366,31 @@
     /*
      * Disconnect from the current AP and remove configured networks.
      */
-    public boolean disconnectAP() {
+    protected boolean disconnectAP() {
         // remove saved networks
         if (!mWifiManager.isWifiEnabled()) {
-            log("Enabled wifi before remove configured networks");
+            logv("Enabled wifi before remove configured networks");
             mWifiManager.setWifiEnabled(true);
-            sleep(SHORT_TIMEOUT);
+            SystemClock.sleep(SHORT_TIMEOUT);
         }
 
         List<WifiConfiguration> wifiConfigList = mWifiManager.getConfiguredNetworks();
         if (wifiConfigList == null) {
-            log("no configuration list is null");
+            logv("no configuration list is null");
             return true;
         }
-        log("size of wifiConfigList: " + wifiConfigList.size());
+        logv("size of wifiConfigList: " + wifiConfigList.size());
         for (WifiConfiguration wifiConfig: wifiConfigList) {
-            log("remove wifi configuration: " + wifiConfig.networkId);
+            logv("remove wifi configuration: " + wifiConfig.networkId);
             int netId = wifiConfig.networkId;
             mWifiManager.forget(netId, new WifiManager.ActionListener() {
+                    @Override
                     public void onSuccess() {
                     }
+
+                    @Override
                     public void onFailure(int reason) {
-                        log("Failed to forget " + reason);
+                        logv("Failed to forget " + reason);
                     }
                 });
         }
@@ -623,37 +400,76 @@
      * Disable Wifi
      * @return true if Wifi is disabled successfully
      */
-    public boolean disableWifi() {
+    protected boolean disableWifi() {
         return mWifiManager.setWifiEnabled(false);
     }
 
     /**
      * Remove configured networks and disable wifi
      */
-    public boolean removeConfiguredNetworksAndDisableWifi() {
+    protected boolean removeConfiguredNetworksAndDisableWifi() {
         if (!disconnectAP()) {
            return false;
         }
-        sleep(SHORT_TIMEOUT);
+        SystemClock.sleep(SHORT_TIMEOUT);
         if (!mWifiManager.setWifiEnabled(false)) {
             return false;
         }
-        sleep(SHORT_TIMEOUT);
+        SystemClock.sleep(SHORT_TIMEOUT);
         return true;
     }
 
-    private void sleep(long sleeptime) {
-        try {
-            Thread.sleep(sleeptime);
-        } catch (InterruptedException e) {}
-    }
-
     protected static String convertToQuotedString(String string) {
         return "\"" + string + "\"";
     }
 
+    protected boolean waitForActiveNetworkConnection(long timeout) {
+        long startTime = SystemClock.uptimeMillis();
+        while (true) {
+            NetworkInfo ni = mCm.getActiveNetworkInfo();
+            if (ni != null && ni.isConnected()) {
+                return true;
+            }
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                logv("waitForActiveNetworkConnection timeout: %s", ni);
+                return false;
+            }
+            logv("waitForActiveNetworkConnection interim: %s", ni);
+            SystemClock.sleep(SHORT_TIMEOUT);
+        }
+    }
+
+    protected boolean waitUntilNoActiveNetworkConnection(long timeout) {
+        long startTime = SystemClock.uptimeMillis();
+        while (true) {
+            NetworkInfo ni = mCm.getActiveNetworkInfo();
+            if (ni == null) {
+                return true;
+            }
+            if ((SystemClock.uptimeMillis() - startTime) > timeout) {
+                logv("waitForActiveNetworkConnection timeout: %s", ni);
+                return false;
+            }
+            logv("waitForActiveNetworkConnection interim: %s", ni);
+            SystemClock.sleep(SHORT_TIMEOUT);
+        }
+    }
+
+    // use ping request against Google public DNS to verify connectivity
+    protected boolean checkNetworkConnectivity() {
+        assertTrue("no active network connection", waitForActiveNetworkConnection(LONG_TIMEOUT));
+        try {
+            Process proc = Runtime.getRuntime().exec(new String[]{
+                    "/system/bin/ping", "-W", "30", "-c", "1", PING_IP_ADDR});
+            return proc.waitFor() == 0;
+        } catch (InterruptedException | IOException e) {
+            Log.e(mLogTag, "Ping failed", e);
+        }
+        return false;
+    }
+
     @Override
-    public void tearDown() throws Exception{
+    protected void tearDown() throws Exception{
         //Unregister receiver
         if (mConnectivityReceiver != null) {
           mContext.unregisterReceiver(mConnectivityReceiver);
@@ -664,7 +480,27 @@
         super.tearDown();
     }
 
-    private void log(String message) {
-        Log.v(LOG_TAG, message);
+    protected void logv(String format, Object... args) {
+        Log.v(mLogTag, String.format(format, args));
+    }
+
+    /**
+     * Connect to the provided Wi-Fi network
+     * @param config is the network configuration
+     * @throws AssertionError if fails to associate and connect to wifi ap
+     */
+    protected void connectToWifi(WifiConfiguration config) {
+        // step 1: connect to the test access point
+        assertTrue("failed to associate with " + config.SSID,
+                connectToWifiWithConfiguration(config));
+
+        // step 2: verify Wifi state and network state;
+        assertTrue("wifi state not connected with " + config.SSID,
+                waitForNetworkState(ConnectivityManager.TYPE_WIFI,
+                State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+
+        // step 3: verify the current connected network is the given SSID
+        assertNotNull("no active wifi info", mWifiManager.getConnectionInfo());
+        assertEquals("SSID mismatch", config.SSID, mWifiManager.getConnectionInfo().getSSID());
     }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestRunner.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestRunner.java
index b94306a..b6eb674 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestRunner.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/ConnectivityManagerTestRunner.java
@@ -35,8 +35,9 @@
  */
 
 public class ConnectivityManagerTestRunner extends InstrumentationTestRunner {
-    public boolean mWifiOnlyFlag = false;
-    public String mTestSsid = null;
+    public boolean mWifiOnly = false;
+    public String mSsid = null;
+    public String mPassword = null;
 
     @Override
     public TestSuite getAllTests() {
@@ -54,13 +55,29 @@
     @Override
     public void onCreate(Bundle icicle) {
         super.onCreate(icicle);
-        String testSSID = (String) icicle.get("ssid");
-        if (testSSID != null) {
-            mTestSsid = testSSID;
+        String ssid = icicle.getString("ssid");
+        if (ssid != null) {
+            mSsid = ssid;
+        }
+        String password = (String) icicle.get("password");
+        if (password != null) {
+            mPassword = password;
         }
         String wifiOnlyFlag = (String) icicle.get("wifi-only");
         if (wifiOnlyFlag != null) {
-            mWifiOnlyFlag = true;
+            mWifiOnly = true;
         }
     }
+
+    public String getWifiSsid() {
+        return mSsid;
+    }
+
+    public String getWifiPassword() {
+        return mPassword;
+    }
+
+    public boolean isWifiOnly() {
+        return mWifiOnly;
+    }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/NetworkState.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/NetworkState.java
deleted file mode 100644
index 9d97ac5..0000000
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/NetworkState.java
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Copyright (C) 2010 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.connectivitymanagertest;
-
-import android.net.NetworkInfo.State;
-import android.util.Log;
-
-import java.util.List;
-import java.util.ArrayList;
-
-public class NetworkState {
-    public static final int TO_DISCONNECTION = 0; // transition to disconnection
-    public static final int TO_CONNECTION = 1; // transition to connection
-    public static final int DO_NOTHING = -1;   // no state change
-    private final String LOG_TAG = "NetworkState";
-    private List<State> mStateDepository;
-    private State mTransitionTarget;
-    private int mTransitionDirection;
-    private String mReason = null;         // record mReason of state transition failure
-
-    public NetworkState() {
-        mStateDepository = new ArrayList<State>();
-        mTransitionDirection = DO_NOTHING;
-        mTransitionTarget = State.UNKNOWN;
-    }
-
-    public NetworkState(State currentState) {
-        mStateDepository = new ArrayList<State>();
-        mStateDepository.add(currentState);
-        mTransitionDirection = DO_NOTHING;
-        mTransitionTarget = State.UNKNOWN;
-    }
-
-    // Reinitialize the network state
-    public void resetNetworkState() {
-        mStateDepository.clear();
-        mTransitionDirection = DO_NOTHING;
-        mTransitionTarget = State.UNKNOWN;
-    }
-
-    // set the transition criteria, transitionDir could be:
-    // DO_NOTHING, TO_CONNECTION, TO_DISCONNECTION
-    public void setStateTransitionCriteria(State initState, int transitionDir, State targetState) {
-        if (!mStateDepository.isEmpty()) {
-            mStateDepository.clear();
-        }
-        mStateDepository.add(initState);
-        mTransitionDirection = transitionDir;
-        mTransitionTarget = targetState;
-        Log.v(LOG_TAG, "setStateTransitionCriteria: " + printStates());
-    }
-
-    public void recordState(State currentState) {
-        mStateDepository.add(currentState);
-    }
-
-    // Verify state transition
-    public boolean validateStateTransition() {
-        Log.v(LOG_TAG, "print state depository: " + printStates());
-        if (mTransitionDirection == DO_NOTHING) {
-            if (mStateDepository.isEmpty()) {
-                Log.v(LOG_TAG, "no state is recorded");
-                mReason = "no state is recorded.";
-                return false;
-            } else if (mStateDepository.size() > 1) {
-                for (int i = 0; i < mStateDepository.size(); i++) {
-                    if (mStateDepository.get(i) != mTransitionTarget) {
-                        Log.v(LOG_TAG, "state changed.");
-                        mReason = "Unexpected state change";
-                        return false;
-                    }
-                }
-            } else if (mStateDepository.get(0) != mTransitionTarget) {
-                Log.v(LOG_TAG, mTransitionTarget + " is expected, but it is " +
-                        mStateDepository.get(0));
-                mReason = mTransitionTarget + " is expected, but it is " + mStateDepository.get(0);
-                return false;
-            }
-            return true;
-        } else if (mTransitionDirection == TO_CONNECTION) {
-            Log.v(LOG_TAG, "transition to CONNECTED");
-            return transitToConnection();
-        } else {
-            Log.v(LOG_TAG, "transition to DISCONNECTED");
-            return transitToDisconnection();
-        }
-    }
-
-    /*
-     * Verifies state transition from CONNECTED->...-> DISCONNECTED.
-     *
-     * returns false if initial state or target state is not correct, or if there is
-     * any transition from DISCONNECTING/DISCONNECTED -> CONNECTED.
-     */
-    public boolean transitToDisconnection () {
-        mReason = "states: " + printStates();
-        if (mStateDepository.get(0) != State.CONNECTED) {
-            mReason += " initial state should be CONNECTED, but it is " +
-                    mStateDepository.get(0) + ".";
-            return false;
-        }
-        State lastState = mStateDepository.get(mStateDepository.size() - 1);
-        if ( lastState != mTransitionTarget) {
-            mReason += " the last state should be DISCONNECTED, but it is " + lastState;
-            return false;
-        }
-        for (int i = 1; i < mStateDepository.size() - 1; i++) {
-            State preState = mStateDepository.get(i-1);
-            State curState = mStateDepository.get(i);
-            if (preState == curState) {
-                continue;
-            } else if ((preState == State.CONNECTED) && ((curState == State.DISCONNECTING) ||
-                    (curState == State.DISCONNECTED))) {
-                continue;
-            } else if ((preState == State.DISCONNECTING) && (curState == State.DISCONNECTED)) {
-                continue;
-            } else {
-                mReason += " Transition state from " + preState.toString() + " to " +
-                        curState.toString() + " is not valid.";
-                return false;
-            }
-        }
-        return true;
-    }
-
-    /*
-     * Verifies state transition from DISCONNECTED->...-> CONNECTED.
-     *
-     * returns false if initial state or target state is not correct, or if there is
-     * any transition from CONNECED -> DISCONNECTED.
-     */
-    public boolean transitToConnection() {
-        mReason = "states: " + printStates();
-        if (mStateDepository.get(0) != State.DISCONNECTED) {
-            mReason += " initial state should be DISCONNECTED, but it is " +
-                    mStateDepository.get(0) + ".";
-            return false;
-        }
-        State lastState = mStateDepository.get(mStateDepository.size() - 1);
-        if ( lastState != mTransitionTarget) {
-            mReason += "The last state should be " + mTransitionTarget + ", but it is " + lastState;
-            return false;
-        }
-        for (int i = 1; i < mStateDepository.size(); i++) {
-            State preState = mStateDepository.get(i-1);
-            State curState = mStateDepository.get(i);
-            if (preState == curState) {
-                continue;
-            }
-            if ((preState == State.DISCONNECTED) && ((curState == State.CONNECTING) ||
-                    (curState == State.CONNECTED))) {
-                continue;
-             } else if ((preState == State.CONNECTING) && (curState == State.CONNECTED)) {
-                 continue;
-             } else {
-                mReason += " Transition state from " + preState.toString() + " to " +
-                        curState.toString() + " is not valid.";
-                return false;
-            }
-        }
-        return true;
-    }
-
-    public List<State> getTransitionStates() {
-        return mStateDepository;
-    }
-
-    // return state failure mReason
-    public String getReason() {
-        return mReason;
-    }
-
-    public String printStates() {
-        StringBuilder stateBuilder = new StringBuilder("");
-        for (int i = 0; i < mStateDepository.size(); i++) {
-            stateBuilder.append(" ").append(mStateDepository.get(i).toString()).append("->");
-        }
-        return stateBuilder.toString();
-    }
-
-    @Override
-    public String toString() {
-        StringBuilder builder = new StringBuilder(" ");
-        builder.append("mTransitionDirection: ").append(Integer.toString(mTransitionDirection)).
-                append("; ").append("states:").
-                append(printStates()).append("; ");
-        return builder.toString();
-    }
-}
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiAssociationTestRunner.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiAssociationTestRunner.java
index 722df2e..f4ea6f2 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiAssociationTestRunner.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiAssociationTestRunner.java
@@ -16,17 +16,12 @@
 
 package com.android.connectivitymanagertest;
 
-import android.content.Context;
-import android.net.wifi.WifiManager;
-import android.os.Bundle;
 import android.test.InstrumentationTestRunner;
 import android.test.InstrumentationTestSuite;
-import android.util.Log;
 
 import com.android.connectivitymanagertest.functional.WifiAssociationTest;
 
 import junit.framework.TestSuite;
-import junit.framework.Assert;
 
 /**
  * Instrumentation Test Runner for wifi association test.
@@ -39,8 +34,6 @@
  * -w com.android.connectivitymanagertest/.WifiAssociationTestRunner"
  */
 public class WifiAssociationTestRunner extends InstrumentationTestRunner {
-    private static final String TAG = "WifiAssociationTestRunner";
-    public int mBand;
 
     @Override
     public TestSuite getAllTests() {
@@ -53,36 +46,4 @@
     public ClassLoader getLoader() {
         return WifiAssociationTestRunner.class.getClassLoader();
     }
-
-    @Override
-    public void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        Bundle arguments = icicle;
-        String mFrequencyBand = arguments.getString("frequency-band");
-        if (mFrequencyBand != null) {
-            setFrequencyBand(mFrequencyBand);
-        }
-    }
-
-    private void setFrequencyBand(String band) {
-        WifiManager mWifiManager = (WifiManager)getContext().getSystemService(Context.WIFI_SERVICE);
-        if (band.equals("2.4")) {
-            Log.v(TAG, "set frequency band to 2.4");
-            mBand = WifiManager.WIFI_FREQUENCY_BAND_2GHZ;
-        } else if (band.equals("5.0")) {
-            Log.v(TAG, "set frequency band to 5.0");
-            mBand = WifiManager.WIFI_FREQUENCY_BAND_5GHZ;
-        } else if (band.equals("auto")) {
-            Log.v(TAG, "set frequency band to auto");
-            mBand = WifiManager.WIFI_FREQUENCY_BAND_AUTO;
-        } else {
-            Assert.fail("invalid frequency band");
-        }
-        int currentFreq = mWifiManager.getFrequencyBand();
-        if (mBand == currentFreq) {
-            Log.v(TAG, "frequency band has been set");
-            return;
-        }
-        mWifiManager.setFrequencyBand(mBand, true);
-    }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiConfigurationHelper.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiConfigurationHelper.java
new file mode 100644
index 0000000..f0a8367
--- /dev/null
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/WifiConfigurationHelper.java
@@ -0,0 +1,364 @@
+/*
+ * Copyright (C) 2010, 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.connectivitymanagertest;
+
+import android.net.IpConfiguration.IpAssignment;
+import android.net.IpConfiguration.ProxySettings;
+import android.net.LinkAddress;
+import android.net.StaticIpConfiguration;
+import android.net.wifi.WifiConfiguration;
+import android.net.wifi.WifiConfiguration.AuthAlgorithm;
+import android.net.wifi.WifiConfiguration.KeyMgmt;
+import android.net.wifi.WifiEnterpriseConfig;
+
+import org.json.JSONArray;
+import org.json.JSONException;
+import org.json.JSONObject;
+
+import java.net.InetAddress;
+import java.net.UnknownHostException;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Helper for dealing with creating {@link WifiConfiguration} objects.
+ */
+public class WifiConfigurationHelper {
+    private static final int NONE = 0;
+    private static final int WEP = 1;
+    private static final int PSK = 2;
+    private static final int EAP = 3;
+
+    /**
+     * Private constructor since this a static class.
+     */
+    private WifiConfigurationHelper() {}
+
+    /**
+     * Create a {@link WifiConfiguration} for an open network
+     *
+     * @param ssid The SSID of the wifi network
+     * @return The {@link WifiConfiguration}
+     */
+    public static WifiConfiguration createOpenConfig(String ssid) {
+        WifiConfiguration config = createGenericConfig(ssid);
+
+        config.allowedKeyManagement.set(KeyMgmt.NONE);
+        return config;
+    }
+
+    /**
+     * Create a {@link WifiConfiguration} for a WEP secured network
+     *
+     * @param ssid The SSID of the wifi network
+     * @param password Either a 10, 26, or 58 character hex string or the plain text password
+     * @return The {@link WifiConfiguration}
+     */
+    public static WifiConfiguration createWepConfig(String ssid, String password) {
+        WifiConfiguration config = createGenericConfig(ssid);
+
+        if (isHex(password, 10) || isHex(password, 26) || isHex(password, 58)) {
+            config.wepKeys[0] = password;
+        } else {
+            config.wepKeys[0] = quotedString(password);
+        }
+
+        config.allowedKeyManagement.set(KeyMgmt.NONE);
+        config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
+        config.allowedAuthAlgorithms.set(AuthAlgorithm.SHARED);
+        return config;
+    }
+
+    /**
+     * Create a {@link WifiConfiguration} for a PSK secured network
+     *
+     * @param ssid The SSID of the wifi network
+     * @param password Either a 64 character hex string or the plain text password
+     * @return The {@link WifiConfiguration}
+     */
+    public static WifiConfiguration createPskConfig(String ssid, String password) {
+        WifiConfiguration config = createGenericConfig(ssid);
+
+        if (isHex(password, 64)) {
+            config.preSharedKey = password;
+        } else {
+            config.preSharedKey = quotedString(password);
+        }
+        config.allowedKeyManagement.set(KeyMgmt.WPA_PSK);
+        return config;
+    }
+
+    /**
+     * Create a {@link WifiConfiguration} for an EAP secured network
+     *
+     * @param ssid The SSID of the wifi network
+     * @param password The password
+     * @param eapMethod The EAP method
+     * @param phase2 The phase 2 method or null
+     * @param identity The identity or null
+     * @param anonymousIdentity The anonymous identity or null
+     * @param caCert The CA certificate or null
+     * @param clientCert The client certificate or null
+     * @return The {@link WifiConfiguration}
+     */
+    public static WifiConfiguration createEapConfig(String ssid, String password, int eapMethod,
+            Integer phase2, String identity, String anonymousIdentity, String caCert,
+            String clientCert) {
+        WifiConfiguration config = new WifiConfiguration();
+        config.SSID = quotedString(ssid);
+
+        config.allowedKeyManagement.set(KeyMgmt.WPA_EAP);
+        config.allowedKeyManagement.set(KeyMgmt.IEEE8021X);
+
+        // Set defaults
+        if (phase2 == null) phase2 = WifiEnterpriseConfig.Phase2.NONE;
+        if (identity == null) identity = "";
+        if (anonymousIdentity == null) anonymousIdentity = "";
+        if (caCert == null) caCert = "";
+        if (clientCert == null) clientCert = "";
+
+        config.enterpriseConfig.setPassword(password);
+        config.enterpriseConfig.setEapMethod(eapMethod);
+        config.enterpriseConfig.setPhase2Method(phase2);
+        config.enterpriseConfig.setIdentity(identity);
+        config.enterpriseConfig.setAnonymousIdentity(anonymousIdentity);
+        config.enterpriseConfig.setCaCertificateAlias(caCert);
+        config.enterpriseConfig.setClientCertificateAlias(clientCert);
+        return config;
+    }
+
+    /**
+     * Create a generic {@link WifiConfiguration} used by the other create methods.
+     */
+    private static WifiConfiguration createGenericConfig(String ssid) {
+        WifiConfiguration config = new WifiConfiguration();
+        config.SSID = quotedString(ssid);
+        config.setIpAssignment(IpAssignment.DHCP);
+        config.setProxySettings(ProxySettings.NONE);
+        return config;
+    }
+
+    /**
+     * Parse a JSON string for WiFi configurations stored as a JSON string.
+     * <p>
+     * This json string should be a list of dictionaries, with each dictionary containing a single
+     * wifi configuration. The wifi configuration requires the fields "ssid" and "security" with
+     * security being one of NONE, WEP, PSK, or EAP. If WEP, PSK, or EAP are selected, the field
+     * "password" must also be provided.  If EAP is selected, then the fiels "eap", "phase2",
+     * "identity", "ananymous_identity", "ca_cert", and "client_cert" are also required. Lastly,
+     * static IP settings are also supported.  If the field "ip" is set, then the fields "gateway",
+     * "prefix_length", "dns1", and "dns2" are required.
+     * </p>
+     * @throws IllegalArgumentException if the input string was not valid JSON or if any mandatory
+     * fields are missing.
+     */
+    public static List<WifiConfiguration> parseJson(String in) {
+        try {
+            JSONArray jsonConfigs = new JSONArray(in);
+            List<WifiConfiguration> wifiConfigs = new ArrayList<>(jsonConfigs.length());
+
+            for (int i = 0; i < jsonConfigs.length(); i++) {
+                JSONObject jsonConfig = jsonConfigs.getJSONObject(i);
+
+                wifiConfigs.add(getWifiConfiguration(jsonConfig));
+            }
+            return wifiConfigs;
+        } catch (JSONException e) {
+            throw new IllegalArgumentException(e);
+        }
+    }
+
+    /**
+     * Parse a {@link JSONObject} and return the wifi configuration.
+     *
+     * @throws IllegalArgumentException if any mandatory fields are missing.
+     */
+    private static WifiConfiguration getWifiConfiguration(JSONObject jsonConfig)
+            throws JSONException {
+        String ssid = jsonConfig.getString("ssid");
+        String password = null;
+        WifiConfiguration config;
+
+        int securityType = getSecurityType(jsonConfig.getString("security"));
+        switch (securityType) {
+            case NONE:
+                config = createOpenConfig(ssid);
+                break;
+            case WEP:
+                password = jsonConfig.getString("password");
+                config = createWepConfig(ssid, password);
+                break;
+            case PSK:
+                password = jsonConfig.getString("password");
+                config = createPskConfig(ssid, password);
+                break;
+            case EAP:
+                password = jsonConfig.getString("password");
+                int eapMethod = getEapMethod(jsonConfig.getString("eap"));
+                Integer phase2 = null;
+                if (jsonConfig.has("phase2")) {
+                    phase2 = getPhase2(jsonConfig.getString("phase2"));
+                }
+                String identity = null;
+                if (jsonConfig.has("identity")) {
+                    identity = jsonConfig.getString("identity");
+                }
+                String anonymousIdentity = null;
+                if (jsonConfig.has("anonymous_identity")) {
+                    anonymousIdentity = jsonConfig.getString("anonymous_identity");
+                }
+                String caCert = null;
+                if (jsonConfig.has("ca_cert")) {
+                    caCert = (jsonConfig.getString("ca_cert"));
+                }
+                String clientCert = null;
+                if (jsonConfig.has("client_cert")) {
+                    clientCert = jsonConfig.getString("client_cert");
+                }
+                config = createEapConfig(ssid, password, eapMethod, phase2, identity,
+                        anonymousIdentity, caCert, clientCert);
+                break;
+            default:
+                // Should never reach here as getSecurityType will already throw an exception
+                throw new IllegalArgumentException();
+        }
+
+        if (jsonConfig.has("ip")) {
+            StaticIpConfiguration staticIpConfig = new StaticIpConfiguration();
+
+            InetAddress ipAddress = getInetAddress(jsonConfig.getString("ip"));
+            int prefixLength = getPrefixLength(jsonConfig.getInt("prefix_length"));
+            staticIpConfig.ipAddress = new LinkAddress(ipAddress, prefixLength);
+            staticIpConfig.gateway = getInetAddress(jsonConfig.getString("gateway"));
+            staticIpConfig.dnsServers.add(getInetAddress(jsonConfig.getString("dns1")));
+            staticIpConfig.dnsServers.add(getInetAddress(jsonConfig.getString("dns2")));
+
+            config.setIpAssignment(IpAssignment.STATIC);
+            config.setStaticIpConfiguration(staticIpConfig);
+        } else {
+            config.setIpAssignment(IpAssignment.DHCP);
+        }
+
+        config.setProxySettings(ProxySettings.NONE);
+        return config;
+    }
+
+    private static String quotedString(String s) {
+        return String.format("\"%s\"", s);
+    }
+
+    /**
+     * Get the security type from a string.
+     *
+     * @throws IllegalArgumentException if the string is not a supported security type.
+     */
+    private static int getSecurityType(String security) {
+        if ("NONE".equalsIgnoreCase(security)) {
+            return NONE;
+        }
+        if ("WEP".equalsIgnoreCase(security)) {
+            return WEP;
+        }
+        if ("PSK".equalsIgnoreCase(security)) {
+            return PSK;
+        }
+        if ("EAP".equalsIgnoreCase(security)) {
+            return EAP;
+        }
+        throw new IllegalArgumentException("Security type must be one of NONE, WEP, PSK, or EAP");
+    }
+
+    /**
+     * Get the EAP method from a string.
+     *
+     * @throws IllegalArgumentException if the string is not a supported EAP method.
+     */
+    private static int getEapMethod(String eapMethod) {
+        if ("TLS".equalsIgnoreCase(eapMethod)) {
+            return WifiEnterpriseConfig.Eap.TLS;
+        }
+        if ("TTLS".equalsIgnoreCase(eapMethod)) {
+            return WifiEnterpriseConfig.Eap.TTLS;
+        }
+        if ("PEAP".equalsIgnoreCase(eapMethod)) {
+            return WifiEnterpriseConfig.Eap.PEAP;
+        }
+        throw new IllegalArgumentException("EAP method must be one of TLS, TTLS, or PEAP");
+    }
+
+    /**
+     * Get the phase 2 method from a string.
+     *
+     * @throws IllegalArgumentException if the string is not a supported phase 2 method.
+     */
+    private static int getPhase2(String phase2) {
+        if ("PAP".equalsIgnoreCase(phase2)) {
+            return WifiEnterpriseConfig.Phase2.PAP;
+        }
+        if ("MSCHAP".equalsIgnoreCase(phase2)) {
+            return WifiEnterpriseConfig.Phase2.MSCHAP;
+        }
+        if ("MSCHAPV2".equalsIgnoreCase(phase2)) {
+            return WifiEnterpriseConfig.Phase2.MSCHAPV2;
+        }
+        if ("GTC".equalsIgnoreCase(phase2)) {
+            return WifiEnterpriseConfig.Phase2.GTC;
+        }
+        throw new IllegalArgumentException("Phase2 must be one of PAP, MSCHAP, MSCHAPV2, or GTC");
+    }
+
+    /**
+     * Get an {@link InetAddress} from a string
+     *
+     * @throws IllegalArgumentException if the string is not a valid IP address.
+     */
+    private static InetAddress getInetAddress(String ipAddress) {
+        if (!InetAddress.isNumeric(ipAddress)) {
+            throw new IllegalArgumentException(
+                    String.format("IP address %s is not numeric", ipAddress));
+        }
+
+        try {
+            return InetAddress.getByName(ipAddress);
+        } catch (UnknownHostException e) {
+            throw new IllegalArgumentException(
+                    String.format("IP address %s could not be resolved", ipAddress));
+        }
+    }
+
+    /**
+     * Get the prefix length from an int.
+     *
+     * @throws IllegalArgumentException if the prefix length is less than 0 or greater than 32.
+     */
+    private static int getPrefixLength(int prefixLength) {
+        if (prefixLength < 0 || prefixLength > 32) {
+            throw new IllegalArgumentException("Prefix length cannot be less than 0 or more than 32");
+        }
+        return prefixLength;
+    }
+
+    /**
+     * Utility method to check if a given string is a hexadecimal string of given length
+     */
+    public static boolean isHex(String input, int length) {
+        if (input == null || length < 0) {
+            return false;
+        }
+        return input.matches(String.format("[0-9A-Fa-f]{%d}", length));
+    }
+}
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/ConnectivityManagerMobileTest.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/ConnectivityManagerMobileTest.java
index 05462b4..d5051df 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/ConnectivityManagerMobileTest.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/ConnectivityManagerMobileTest.java
@@ -16,27 +16,25 @@
 
 package com.android.connectivitymanagertest.functional;
 
-import android.content.Context;
 import android.net.ConnectivityManager;
 import android.net.NetworkInfo;
 import android.net.NetworkInfo.State;
 import android.net.wifi.WifiManager;
-import android.os.PowerManager;
-import android.os.PowerManager.WakeLock;
+import android.os.SystemClock;
 import android.provider.Settings;
 import android.test.suitebuilder.annotation.LargeTest;
-import android.util.Log;
 
 import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
 import com.android.connectivitymanagertest.ConnectivityManagerTestRunner;
-import com.android.connectivitymanagertest.NetworkState;
 
-public class ConnectivityManagerMobileTest extends
-        ConnectivityManagerTestBase {
-    private static final String TAG = "ConnectivityManagerMobileTest";
+public class ConnectivityManagerMobileTest extends  ConnectivityManagerTestBase {
 
-    private String mTestAccessPoint;
-    private WakeLock wl;
+    public ConnectivityManagerMobileTest() {
+        super(ConnectivityManagerMobileTest.class.getSimpleName());
+    }
+
+    private String mSsid;
+    private String mPassword;
     private boolean mWifiOnlyFlag;
 
     @Override
@@ -44,18 +42,15 @@
         super.setUp();
         ConnectivityManagerTestRunner mRunner =
                 (ConnectivityManagerTestRunner)getInstrumentation();
-        mTestAccessPoint = mRunner.mTestSsid;
-        mWifiOnlyFlag = mRunner.mWifiOnlyFlag;
+        mSsid = mRunner.getWifiSsid();
+        mPassword = mRunner.getWifiPassword();
+        mWifiOnlyFlag = mRunner.isWifiOnly();
 
-        PowerManager pm = (PowerManager)getInstrumentation().
-                getContext().getSystemService(Context.POWER_SERVICE);
-        wl = pm.newWakeLock(PowerManager.SCREEN_BRIGHT_WAKE_LOCK, "CMWakeLock");
-        wl.acquire();
         // Each test case will start with cellular connection
         if (Settings.Global.getInt(getInstrumentation().getContext().getContentResolver(),
                 Settings.Global.AIRPLANE_MODE_ON) == 1) {
-            log("airplane is not disabled, disable it.");
-            mCM.setAirplaneMode(false);
+            logv("airplane is not disabled, disable it.");
+            mCm.setAirplaneMode(false);
         }
 
         if (!mWifiOnlyFlag) {
@@ -72,449 +67,273 @@
 
     @Override
     public void tearDown() throws Exception {
-        wl.release();
         removeConfiguredNetworksAndDisableWifi();
-        mCM.setAirplaneMode(false);
+        mCm.setAirplaneMode(false);
         super.tearDown();
     }
 
     // help function to verify 3G connection
     public void verifyCellularConnection() {
-        NetworkInfo extraNetInfo = mCM.getActiveNetworkInfo();
+        NetworkInfo extraNetInfo = mCm.getActiveNetworkInfo();
         assertEquals("network type is not MOBILE", ConnectivityManager.TYPE_MOBILE,
                 extraNetInfo.getType());
         assertTrue("not connected to cellular network", extraNetInfo.isConnected());
     }
 
-    private void log(String message) {
-        Log.v(TAG, message);
-    }
 
-    private void sleep(long sleeptime) {
-        try {
-            Thread.sleep(sleeptime);
-        } catch (InterruptedException e) {}
-    }
 
     // Test case 1: Test enabling Wifi without associating with any AP, no broadcast on network
     //              event should be expected.
     @LargeTest
     public void test3GToWifiNotification() {
         if (mWifiOnlyFlag) {
-            Log.v(TAG, this.getName() + " is excluded for wifi-only test");
+            logv(getName() + " is excluded for wifi-only test");
             return;
         }
-        // Enable Wi-Fi to avoid initial UNKNOWN state
-        enableWifi();
-        sleep(2 * SHORT_TIMEOUT);
 
-        // Wi-Fi is disabled
-        disableWifi();
+        // disable WiFi
+        assertTrue("failed to disable WiFi", disableWifi());
 
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.DISCONNECTED, LONG_TIMEOUT));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                State.CONNECTED, LONG_TIMEOUT));
-        // Wait for 10 seconds for broadcasts to be sent out
-        sleep(10 * 1000);
+        // wait for mobile
+        assertTrue("failed to wait for mobile connection", waitForNetworkState(
+                ConnectivityManager.TYPE_MOBILE, State.CONNECTED, LONG_TIMEOUT));
 
-        // As Wifi stays in DISCONNETED, Mobile statys in CONNECTED,
-        // the connectivity manager will not broadcast any network connectivity event for Wifi
-        NetworkInfo networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                networkInfo.getState(), NetworkState.DO_NOTHING, State.CONNECTED);
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                NetworkState.DO_NOTHING, State.DISCONNECTED);
-        // Eanble Wifi without associating with any AP
-        enableWifi();
-        sleep(2 * SHORT_TIMEOUT);
+        // assert that we are indeed using mobile
+        NetworkInfo ni = mCm.getActiveNetworkInfo();
+        assertEquals("active network is not mobile", ConnectivityManager.TYPE_MOBILE, ni.getType());
 
-        // validate state and broadcast
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("the state for WIFI is changed");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue("state validation fail", false);
-        }
-        if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-            log("the state for MOBILE is changed");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-            assertTrue("state validation fail", false);
-        }
-        // Verify that the device is still connected to MOBILE
+        long timestamp = SystemClock.uptimeMillis();
+        // now enable WiFi
+        assertTrue("failed to enable WiFi", enableWifi());
+        // assert that WiFi state settles at disconnected since no AP should be configured
+        assertTrue("WiFi state is not DISCONNECTED after enabling", waitForWifiState(
+                WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
+
+        // assert that no connectivity change broadcast was sent since we enable wifi
+        assertTrue("connectivity has changed since wifi enable",
+                timestamp > getLastConnectivityChangeTime());
+
+        // verify that the device is still connected to MOBILE
         verifyCellularConnection();
+        // verify that connection actually works
+        assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
     }
 
     // Test case 2: test connection to a given AP
     @LargeTest
     public void testConnectToWifi() {
-        assertNotNull("SSID is null", mTestAccessPoint);
-        NetworkInfo networkInfo;
-        if (!mWifiOnlyFlag) {
-            //Prepare for connectivity verification
-            networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-            setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                    networkInfo.getState(), NetworkState.TO_DISCONNECTION, State.DISCONNECTED);
-        }
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                NetworkState.TO_CONNECTION, State.CONNECTED);
+        assertNotNull("SSID is null", mSsid);
 
-        // Enable Wifi and connect to a test access point
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
-
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
-        log("wifi state is enabled");
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-        if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                    State.DISCONNECTED, LONG_TIMEOUT));
-        }
-
-        // validate states
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("Wifi state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue(false);
-        }
-        if (!mWifiOnlyFlag) {
-            if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-                log("Mobile state transition validation failed.");
-                log("reason: " +
-                        getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-                assertTrue(false);
-            }
-        }
+        // assert that we are able to connect to the ap
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
+        // assert that WifiManager reports correct state
+        assertTrue("wifi not enabled", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
+        // assert that ConnectivityManager reports correct state for Wifi
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+        // below check disbabled since we have bug in what ConnectivityManager returns
+//        if (!mWifiOnlyFlag) {
+//            // assert that ConnectivityManager reports correct state for mobile
+//            assertTrue("mobile not disconnected", waitForNetworkState(
+//                    ConnectivityManager.TYPE_MOBILE, State.DISCONNECTED, LONG_TIMEOUT));
+//        }
+        // verify that connection actually works
+        assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
     }
 
-    // Test case 3: connect to Wifi with known AP
+    // Test case 3: connect & reconnect to Wifi with known AP
     @LargeTest
     public void testConnectToWifWithKnownAP() {
-        assertNotNull("SSID is null", mTestAccessPoint);
-        // Connect to mTestAccessPoint
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
+        assertNotNull("SSID is null", mSsid);
+        // enable WiFi
+        assertTrue("failed to enable wifi", enableWifi());
+        // wait for wifi enable
+        assertTrue("wifi not enabled", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
+        // Connect to AP
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
+        // verify wifi connected as reported by ConnectivityManager
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
 
-        sleep(SHORT_TIMEOUT);
-        // Disable Wifi
-        log("Disable Wifi");
-        if (!disableWifi()) {
-            log("disable Wifi failed");
-            return;
-        }
+        assertTrue("failed to disable wifi", disableWifi());
 
         // Wait for the Wifi state to be DISABLED
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.DISCONNECTED, LONG_TIMEOUT));
+        assertTrue("wifi state not disabled", waitForWifiState(
+                WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
+        // below check disbabled since we have bug in what ConnectivityManager returns
+//        assertTrue("wifi not disconnected", waitForNetworkState(ConnectivityManager.TYPE_WIFI,
+//                State.DISCONNECTED, LONG_TIMEOUT));
         if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                    State.CONNECTED, LONG_TIMEOUT));
+            assertTrue("mobile not connected after wifi disable", waitForNetworkState(
+                    ConnectivityManager.TYPE_MOBILE, State.CONNECTED, LONG_TIMEOUT));
         }
 
-        NetworkInfo networkInfo;
-        if (!mWifiOnlyFlag) {
-            //Prepare for connectivity state verification
-            networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-            setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                                                  networkInfo.getState(), NetworkState.DO_NOTHING,
-                                                  State.DISCONNECTED);
-        }
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                NetworkState.TO_CONNECTION, State.CONNECTED);
+        // wait for 30s before restart wifi
+        SystemClock.sleep(LONG_TIMEOUT);
+        assertTrue("failed to enable wifi after disable", enableWifi());
 
-        // wait for 2 minutes before restart wifi
-        sleep(WIFI_STOP_START_INTERVAL);
-        // Enable Wifi again
-        log("Enable Wifi again");
-        enableWifi();
-
+        // wait for wifi enable
+        assertTrue("wifi not enabled after toggle", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
         // Wait for Wifi to be connected and mobile to be disconnected
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-        if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                    State.DISCONNECTED, LONG_TIMEOUT));
-        }
-
-        // validate wifi states
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("Wifi state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue(false);
-        }
+        assertTrue("wifi not connected after toggle", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+        // below check disbabled since we have bug in what ConnectivityManager returns
+//        if (!mWifiOnlyFlag) {
+//            assertTrue("mobile not disconnected after wifi toggle", waitForNetworkState(
+//                    ConnectivityManager.TYPE_MOBILE, State.DISCONNECTED, LONG_TIMEOUT));
+//        }
+        // verify that connection actually works
+        assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
     }
 
-    // Test case 4:  test disconnect Wifi
+    // Test case 4:  test disconnect and clear wifi settings
     @LargeTest
     public void testDisconnectWifi() {
-        assertNotNull("SSID is null", mTestAccessPoint);
+        assertNotNull("SSID is null", mSsid);
 
+        // enable WiFi
+        assertTrue("failed to enable wifi", enableWifi());
+        // wait for wifi enable
+        assertTrue("wifi not enabled", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
         // connect to Wifi
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
 
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-
-        // Wait for a few seconds to avoid the state that both Mobile and Wifi is connected
-        sleep(SHORT_TIMEOUT);
-
-        NetworkInfo networkInfo;
-        if (!mWifiOnlyFlag) {
-            networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-            setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                                                  networkInfo.getState(),
-                                                  NetworkState.TO_CONNECTION,
-                                                  State.CONNECTED);
-        }
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                NetworkState.TO_DISCONNECTION, State.DISCONNECTED);
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
 
         // clear Wifi
         removeConfiguredNetworksAndDisableWifi();
 
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.DISCONNECTED, LONG_TIMEOUT));
+        // assert that wifi has been disabled
+        assertTrue("wifi state not disabled", waitForWifiState(
+                WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
         if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
+            // assert that mobile is now connected
+            assertTrue("mobile not enabled", waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
                     State.CONNECTED, LONG_TIMEOUT));
-        }
-
-        // validate states
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("Wifi state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue(false);
-        }
-        if (!mWifiOnlyFlag) {
-            if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-                log("Mobile state transition validation failed.");
-                log("reason: " +
-                        getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-                assertTrue(false);
-            }
+            // verify that connection actually works
+            assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
         }
     }
 
-    // Test case 5: test connectivity from 3G to airplane mode, then to 3G again
+    // Test case 5: test connectivity with mobile->airplane mode->mobile
     @LargeTest
     public void testDataConnectionWith3GToAmTo3G() {
         if (mWifiOnlyFlag) {
-            Log.v(TAG, this.getName() + " is excluded for wifi-only test");
+            logv(getName() + " is excluded for wifi-only test");
             return;
         }
-        //Prepare for state verification
-        NetworkInfo networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                                              networkInfo.getState(),
-                                              NetworkState.TO_DISCONNECTION,
-                                              State.DISCONNECTED);
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        assertEquals(State.DISCONNECTED, networkInfo.getState());
+        // disable wifi
+        assertTrue("failed to disable wifi", disableWifi());
+        assertTrue("wifi state not disabled", waitForWifiState(
+                WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
+        // assert that we have mobile connection
+        assertTrue("no mobile connection", waitForNetworkState(
+                ConnectivityManager.TYPE_MOBILE, State.CONNECTED, LONG_TIMEOUT));
 
-        // Enable airplane mode
-        log("Enable airplane mode");
-        mCM.setAirplaneMode(true);
-        sleep(SHORT_TIMEOUT);
-
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        assertEquals(State.DISCONNECTED, networkInfo.getState());
-        // wait until mobile is turn off
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                State.DISCONNECTED, LONG_TIMEOUT));
-        if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-            log("Mobile state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-            assertTrue(false);
-        }
-
-        // reset state recorder
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                                              networkInfo.getState(),
-                                              NetworkState.TO_CONNECTION,
-                                              State.CONNECTED);
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                NetworkState.DO_NOTHING, State.DISCONNECTED);
+        // enable airplane mode
+        mCm.setAirplaneMode(true);
+        // assert no active network connection after airplane mode enabled
+        assertTrue("still has active network connection",
+                waitUntilNoActiveNetworkConnection(LONG_TIMEOUT));
 
         // disable airplane mode
-        mCM.setAirplaneMode(false);
+        mCm.setAirplaneMode(false);
+        // assert there is active network connection after airplane mode disabled
+        assertTrue("no active network connection after airplane mode disable",
+                waitForActiveNetworkConnection(LONG_TIMEOUT));
 
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                State.CONNECTED, LONG_TIMEOUT));
-
-        // Validate the state transition
-        if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-            log("Mobile state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-            assertTrue(false);
-        }
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-          log("Wifi state transition validation failed.");
-          log("reason: " +
-                  getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-          assertTrue(false);
-        }
+        // assert that we have mobile connection
+        assertTrue("no mobile connection", waitForNetworkState(
+                ConnectivityManager.TYPE_MOBILE, State.CONNECTED, LONG_TIMEOUT));
+        // verify that connection actually works
+        assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
     }
 
-    // Test case 6: test connectivity with airplane mode Wifi connected
+    // Test case 6: test connectivity with airplane mode on but wifi enabled
     @LargeTest
     public void testDataConnectionOverAMWithWifi() {
-        if (mWifiOnlyFlag) {
-            Log.v(TAG, this.getName() + " is excluded for wifi-only test");
-            return;
-        }
-        assertNotNull("SSID is null", mTestAccessPoint);
-        // Eanble airplane mode
-        log("Enable airplane mode");
-        mCM.setAirplaneMode(true);
+        assertNotNull("SSID is null", mSsid);
+        // enable airplane mode
+        mCm.setAirplaneMode(true);
+        // assert there is active network connection after airplane mode disabled
+        assertTrue("still has active network connection",
+                waitUntilNoActiveNetworkConnection(LONG_TIMEOUT));
 
-        NetworkInfo networkInfo;
-        if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                    State.DISCONNECTED, LONG_TIMEOUT));
-            networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE);
-            setStateTransitionCriteria(ConnectivityManager.TYPE_MOBILE,
-                                                  networkInfo.getState(),
-                                                  NetworkState.DO_NOTHING,
-                                                  State.DISCONNECTED);
-        }
-        networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI, networkInfo.getState(),
-                                              NetworkState.TO_CONNECTION, State.CONNECTED);
+        // connect to Wifi
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+        // verify that connection actually works
+        assertTrue("no network connectivity after wifi enable", checkNetworkConnectivity());
 
-        // Connect to Wifi
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-
-        // validate state and broadcast
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("state validate for Wifi failed");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue("State validation failed", false);
-        }
-        if (!mWifiOnlyFlag) {
-            if (!validateNetworkStates(ConnectivityManager.TYPE_MOBILE)) {
-                log("state validation for Mobile failed");
-                log("reason: " +
-                        getTransitionFailureReason(ConnectivityManager.TYPE_MOBILE));
-                assertTrue("state validation failed", false);
-            }
-        }
-        mCM.setAirplaneMode(false);
+        // disable airplane mode
+        mCm.setAirplaneMode(false);
     }
 
     // Test case 7: test connectivity while transit from Wifi->AM->Wifi
     @LargeTest
     public void testDataConnectionWithWifiToAMToWifi () {
-        if (mWifiOnlyFlag) {
-            Log.v(TAG, this.getName() + " is excluded for wifi-only test");
-            return;
-        }
-        // Connect to mTestAccessPoint
-        assertNotNull("SSID is null", mTestAccessPoint);
-        // Connect to Wifi
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
+        // connect to mTestAccessPoint
+        assertNotNull("SSID is null", mSsid);
+        // enable WiFi
+        assertTrue("failed to enable wifi", enableWifi());
+        // wait for wifi enable
+        assertTrue("wifi not enabled", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
+        // connect to Wifi
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
 
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
+        // enable airplane mode without clearing Wifi
+        mCm.setAirplaneMode(true);
+        // assert there is active network connection after airplane mode disabled
+        assertTrue("still has active network connection",
+                waitUntilNoActiveNetworkConnection(LONG_TIMEOUT));
 
-        try {
-            Thread.sleep(SHORT_TIMEOUT);
-        } catch (Exception e) {
-            log("exception: " + e.toString());
-        }
-
-        // Enable airplane mode without clearing Wifi
-        mCM.setAirplaneMode(true);
-
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.DISCONNECTED, LONG_TIMEOUT));
-
-        try {
-            Thread.sleep(SHORT_TIMEOUT);
-        } catch (Exception e) {
-            log("exception: " + e.toString());
-        }
-
-        // Prepare for state validation
-        NetworkInfo networkInfo = mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI);
-        assertEquals(State.DISCONNECTED, networkInfo.getState());
-        setStateTransitionCriteria(ConnectivityManager.TYPE_WIFI,
-                networkInfo.getState(), NetworkState.TO_CONNECTION, State.CONNECTED);
-
-        // Disable airplane mode
-        mCM.setAirplaneMode(false);
-
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-        if (!mWifiOnlyFlag) {
-            assertTrue(waitForNetworkState(ConnectivityManager.TYPE_MOBILE,
-                    State.DISCONNECTED, LONG_TIMEOUT));
-        }
-
-        // validate the state transition
-        if (!validateNetworkStates(ConnectivityManager.TYPE_WIFI)) {
-            log("Wifi state transition validation failed.");
-            log("reason: " +
-                    getTransitionFailureReason(ConnectivityManager.TYPE_WIFI));
-            assertTrue(false);
-        }
+        // disable airplane mode
+        mCm.setAirplaneMode(false);
+        // assert there is active network connection after airplane mode disabled
+        assertTrue("no active network connection after airplane mode disable",
+                waitForActiveNetworkConnection(LONG_TIMEOUT));
+        // assert that we have a Wifi connection
+        assertTrue("wifi not connected after airplane mode disable", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+        // verify that connection actually works
+        assertTrue("no network connectivity at end of test", checkNetworkConnectivity());
     }
 
     // Test case 8: test wifi state change while connecting/disconnecting to/from an AP
     @LargeTest
     public void testWifiStateChange () {
-        assertNotNull("SSID is null", mTestAccessPoint);
-        //Connect to mTestAccessPoint
-        assertTrue("failed to connect to " + mTestAccessPoint,
-                connectToWifi(mTestAccessPoint));
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
-        assertNotNull("Not associated with any AP",
-                      mWifiManager.getConnectionInfo().getBSSID());
+        assertNotNull("SSID is null", mSsid);
+        // enable WiFi
+        assertTrue("failed to enable wifi", enableWifi());
+        // wait for wifi enable
+        assertTrue("wifi not enabled", waitForWifiState(
+                WifiManager.WIFI_STATE_ENABLED, LONG_TIMEOUT));
+        // connect to Wifi
+        assertTrue("failed to connect to " + mSsid, connectToWifi(mSsid, mPassword));
+        assertTrue("wifi not connected", waitForNetworkState(
+                ConnectivityManager.TYPE_WIFI, State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
+        assertNotNull("not associated with any AP", mWifiManager.getConnectionInfo().getBSSID());
 
-        try {
-            Thread.sleep(SHORT_TIMEOUT);
-        } catch (Exception e) {
-            log("exception: " + e.toString());
-        }
+        // disconnect from the current AP
+        assertTrue("failed to disconnect from AP", disconnectAP());
 
-        // Disconnect from the current AP
-        log("disconnect from the AP");
-        if (!disconnectAP()) {
-            log("failed to disconnect from " + mTestAccessPoint);
-        }
-
+        // below check disbabled since we have bug in what ConnectivityManager returns
         // Verify the connectivity state for Wifi is DISCONNECTED
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.DISCONNECTED, LONG_TIMEOUT));
+//        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
+//                State.DISCONNECTED, LONG_TIMEOUT));
 
-        if (!disableWifi()) {
-            log("disable Wifi failed");
-            return;
-        }
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
+        // disable WiFi
+        assertTrue("failed to disable wifi", disableWifi());
+        assertTrue("wifi state not disabled", waitForWifiState(
+                WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
     }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiAssociationTest.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiAssociationTest.java
index 183f2a9..68f3179 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiAssociationTest.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiAssociationTest.java
@@ -16,23 +16,19 @@
 
 package com.android.connectivitymanagertest.functional;
 
-import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
-import com.android.connectivitymanagertest.WifiAssociationTestRunner;
-
-import android.content.Context;
-import android.os.Bundle;
-import android.net.wifi.WifiInfo;
 import android.net.wifi.WifiConfiguration;
-import android.net.wifi.WifiConfiguration.KeyMgmt;
 import android.net.wifi.WifiConfiguration.AuthAlgorithm;
 import android.net.wifi.WifiConfiguration.GroupCipher;
 import android.net.wifi.WifiConfiguration.PairwiseCipher;
 import android.net.wifi.WifiConfiguration.Protocol;
+import android.net.wifi.WifiInfo;
 import android.net.wifi.WifiManager;
-import android.net.ConnectivityManager;
-import android.net.NetworkInfo.State;
+import android.os.Bundle;
 import android.test.suitebuilder.annotation.LargeTest;
-import android.util.Log;
+
+import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
+import com.android.connectivitymanagertest.WifiAssociationTestRunner;
+import com.android.connectivitymanagertest.WifiConfigurationHelper;
 
 /**
  * Test Wi-Fi connection with different configuration
@@ -41,164 +37,115 @@
  * -e security-type [OPEN|WEP64|WEP128|WPA_TKIP|WPA2_AES] -e frequency-band [2.4|5.0|auto]
  * -w com.android.connectivitymanagertest/.WifiAssociationTestRunner"
  */
-public class WifiAssociationTest
-        extends ConnectivityManagerTestBase {
-    private static final String TAG = "WifiAssociationTest";
-    private String mSsid = null;
-    private String mPassword = null;
-    private String mSecurityType = null;
-    private String mFrequencyBand = null;
-    private int mBand;
-
-    enum SECURITY_TYPE {
+public class WifiAssociationTest extends ConnectivityManagerTestBase {
+    private enum SecurityType {
         OPEN, WEP64, WEP128, WPA_TKIP, WPA2_AES
     }
 
-    @Override
-    public void setUp() throws Exception {
-        super.setUp();
-        WifiAssociationTestRunner mRunner = (WifiAssociationTestRunner)getInstrumentation();
-        Bundle arguments = mRunner.getArguments();
-        mSecurityType = arguments.getString("security-type");
-        mSsid = arguments.getString("ssid");
-        mPassword = arguments.getString("password");
-        mFrequencyBand = arguments.getString("frequency-band");
-        mBand = mRunner.mBand;
-        assertNotNull("Security type is empty", mSecurityType);
-        assertNotNull("Ssid is empty", mSsid);
-        validateFrequencyBand();
-        // enable Wifi and verify wpa_supplicant is started
-        assertTrue("enable Wifi failed", enableWifi());
-        sleep(2 * SHORT_TIMEOUT, "interrupted while waiting for WPA_SUPPLICANT to start");
-        WifiInfo mConnection = mWifiManager.getConnectionInfo();
-        assertNotNull(mConnection);
-        assertTrue("wpa_supplicant is not started ", mWifiManager.pingSupplicant());
-    }
-
-    @Override
-    public void tearDown() throws Exception {
-        super.tearDown();
-    }
-
-    private void validateFrequencyBand() {
-        if (mFrequencyBand != null) {
-            int currentFreq = mWifiManager.getFrequencyBand();
-            Log.v(TAG, "read frequency band: " + currentFreq);
-            assertTrue("device frequency band is not set successfully", (mBand == currentFreq));
-         }
+    public WifiAssociationTest() {
+        super(WifiAssociationTest.class.getSimpleName());
     }
 
     /**
-     * Connect to the provided Wi-Fi network
-     * @param config is the network configuration
-     * @return true if the connection is successful.
+     * Test that the wifi can associate with a given access point.
      */
-    private void connectToWifi(WifiConfiguration config) {
-        // step 1: connect to the test access point
-        assertTrue("failed to associate with " + config.SSID,
-                connectToWifiWithConfiguration(config));
-
-        // step 2: verify Wifi state and network state;
-        assertTrue("failed to connect with " + config.SSID,
-                waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
-
-        // step 3: verify the current connected network is the given SSID
-        assertNotNull("Wifi connection returns null", mWifiManager.getConnectionInfo());
-        assertTrue(config.SSID.contains(mWifiManager.getConnectionInfo().getSSID()));
-    }
-
-    private void sleep(long sometime, String errorMsg) {
-        try {
-            Thread.sleep(sometime);
-        } catch (InterruptedException e) {
-            fail(errorMsg);
-        }
-    }
-
-    private void log(String message) {
-        Log.v(TAG, message);
-    }
-
     @LargeTest
     public void testWifiAssociation() {
-        assertNotNull("no test ssid", mSsid);
-        WifiConfiguration config = new WifiConfiguration();
-        config.SSID = mSsid;
-        SECURITY_TYPE security = SECURITY_TYPE.valueOf(mSecurityType);
-        log("Security type is " + security.toString());
-        switch (security) {
-            // set network configurations
+        WifiAssociationTestRunner runner = (WifiAssociationTestRunner) getInstrumentation();
+        Bundle arguments = runner.getArguments();
+
+        String ssid = arguments.getString("ssid");
+        assertNotNull("ssid is empty", ssid);
+
+        String securityTypeStr = arguments.getString("security-type");
+        assertNotNull("security-type is empty", securityTypeStr);
+        SecurityType securityType = SecurityType.valueOf(securityTypeStr);
+
+        String password = arguments.getString("password");
+
+        String freqStr = arguments.getString("frequency-band");
+        if (freqStr != null) {
+            setFrequencyBand(freqStr);
+        }
+
+        assertTrue("enable Wifi failed", enableWifi());
+        WifiInfo wi = mWifiManager.getConnectionInfo();
+        logv("%s", wi);
+        assertNotNull("no active wifi info", wi);
+
+        WifiConfiguration config = getConfig(ssid, securityType, password);
+
+        logv("Network config: %s", config.toString());
+        connectToWifi(config);
+    }
+
+    /**
+     * Set the frequency band and verify that it has been set.
+     */
+    private void setFrequencyBand(String frequencyBandStr) {
+        int frequencyBand = -1;
+        if ("2.4".equals(frequencyBandStr)) {
+            frequencyBand = WifiManager.WIFI_FREQUENCY_BAND_2GHZ;
+        } else if ("5.0".equals(frequencyBandStr)) {
+            frequencyBand = WifiManager.WIFI_FREQUENCY_BAND_5GHZ;
+        } else if ("auto".equals(frequencyBandStr)) {
+            frequencyBand = WifiManager.WIFI_FREQUENCY_BAND_AUTO;
+        } else {
+            fail("Invalid frequency-band");
+        }
+        if (mWifiManager.getFrequencyBand() != frequencyBand) {
+            logv("Set frequency band to %s", frequencyBandStr);
+            mWifiManager.setFrequencyBand(frequencyBand, true);
+        }
+        assertEquals("Specified frequency band does not match operational band",
+                frequencyBand, mWifiManager.getFrequencyBand());
+    }
+
+    /**
+     * Get the {@link WifiConfiguration} based on ssid, security, and password.
+     */
+    private WifiConfiguration getConfig(String ssid, SecurityType securityType, String password) {
+        logv("Security type is %s", securityType.toString());
+
+        WifiConfiguration config = null;
+        switch (securityType) {
             case OPEN:
-                config.allowedKeyManagement.set(KeyMgmt.NONE);
+                config = WifiConfigurationHelper.createOpenConfig(ssid);
                 break;
             case WEP64:
+                assertNotNull("password is empty", password);
                 // always use hex pair for WEP-40
-                assertTrue("not a WEP64 security type?", mPassword.length() == 10);
-                config.allowedKeyManagement.set(KeyMgmt.NONE);
-                config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
-                config.allowedAuthAlgorithms.set(AuthAlgorithm.SHARED);
+                assertTrue(WifiConfigurationHelper.isHex(password, 10));
+                config = WifiConfigurationHelper.createWepConfig(ssid, password);
                 config.allowedGroupCiphers.set(GroupCipher.WEP40);
-                if (mPassword != null) {
-                    int length = mPassword.length();
-                    // WEP-40
-                    if (mPassword.matches("[0-9A-Fa-f]*")) {
-                        config.wepKeys[0] = mPassword;
-                    } else {
-                        fail("Please type hex pair for the password");
-                    }
-                }
                 break;
             case WEP128:
-                assertNotNull("password is empty", mPassword);
+                assertNotNull("password is empty", password);
                 // always use hex pair for WEP-104
-                assertTrue("not a WEP128 security type?", mPassword.length() == 26);
-                config.allowedKeyManagement.set(KeyMgmt.NONE);
-                config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
-                config.allowedAuthAlgorithms.set(AuthAlgorithm.SHARED);
+                assertTrue(WifiConfigurationHelper.isHex(password, 26));
+                config = WifiConfigurationHelper.createWepConfig(ssid, password);
                 config.allowedGroupCiphers.set(GroupCipher.WEP104);
-                if (mPassword != null) {
-                    int length = mPassword.length();
-                    // WEP-40
-                    if (mPassword.matches("[0-9A-Fa-f]*")) {
-                        config.wepKeys[0] = mPassword;
-                    } else {
-                        fail("Please type hex pair for the password");
-                    }
-                }
                 break;
             case WPA_TKIP:
-                assertNotNull("missing password", mPassword);
-                config.allowedKeyManagement.set(KeyMgmt.WPA_PSK);
+                assertNotNull("password is empty", password);
+                config = WifiConfigurationHelper.createPskConfig(ssid, password);
                 config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
                 config.allowedProtocols.set(Protocol.WPA);
                 config.allowedPairwiseCiphers.set(PairwiseCipher.TKIP);
                 config.allowedGroupCiphers.set(GroupCipher.TKIP);
-                if (mPassword.matches("[0-9A-Fa-f]{64}")) {
-                    config.preSharedKey = mPassword;
-                } else {
-                    config.preSharedKey = '"' + mPassword + '"';
-                }
                 break;
             case WPA2_AES:
-                assertNotNull("missing password", mPassword);
-                config.allowedKeyManagement.set(KeyMgmt.WPA_PSK);
+                assertNotNull("password is empty", password);
+                config = WifiConfigurationHelper.createPskConfig(ssid, password);
                 config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
                 config.allowedProtocols.set(Protocol.RSN);
                 config.allowedPairwiseCiphers.set(PairwiseCipher.CCMP);
                 config.allowedGroupCiphers.set(GroupCipher.CCMP);
-                config.allowedProtocols.set(Protocol.RSN);
-                if (mPassword.matches("[0-9A-Fa-f]{64}")) {
-                    config.preSharedKey = mPassword;
-                } else {
-                    config.preSharedKey = '"' + mPassword + '"';
-                }
                 break;
             default:
-                fail("Not a valid security type: " + mSecurityType);
+                fail("Not a valid security type: " + securityType);
                 break;
         }
-        Log.v(TAG, "network config: " + config.toString());
-        connectToWifi(config);
+        return config;
     }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiConnectionTest.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiConnectionTest.java
index ad73ee1..b37daa3 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiConnectionTest.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/functional/WifiConnectionTest.java
@@ -16,57 +16,38 @@
 
 package com.android.connectivitymanagertest.functional;
 
-import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
-import com.android.connectivitymanagertest.ConnectivityManagerTestRunner;
-
-import android.content.Context;
 import android.net.wifi.WifiConfiguration;
-import android.net.wifi.WifiInfo;
-import android.net.wifi.WifiManager;
-import android.net.ConnectivityManager;
-import android.net.NetworkInfo.State;
+import android.os.SystemClock;
 import android.test.suitebuilder.annotation.LargeTest;
-import android.util.Log;
 
-import java.util.ArrayList;
+import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
+import com.android.connectivitymanagertest.WifiConfigurationHelper;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileReader;
+import java.io.IOException;
 import java.util.List;
-import java.util.Set;
 
 /**
  * Test Wi-Fi connection with different configuration
  * To run this tests:
- *     adb shell am instrument -e class
- *          com.android.connectivitymanagertest.functional.WifiConnectionTest
- *          -w com.android.connectivitymanagertest/.ConnectivityManagerTestRunner
+ *     adb shell am instrument \
+ *         -e class com.android.connectivitymanagertest.functional.WifiConnectionTest \
+ *         -w com.android.connectivitymanagertest/.ConnectivityManagerTestRunner
  */
-public class WifiConnectionTest
-    extends ConnectivityManagerTestBase {
-    private static final String TAG = "WifiConnectionTest";
-    private static final boolean DEBUG = false;
-    private List<WifiConfiguration> networks = new ArrayList<WifiConfiguration>();
+public class WifiConnectionTest extends ConnectivityManagerTestBase {
+    private static final String WIFI_CONFIG_FILE = "/data/wifi_configs.json";
+    private static final long PAUSE_DURATION_MS = 60 * 1000;
+
+    public WifiConnectionTest() {
+        super(WifiConnectionTest.class.getSimpleName());
+    }
 
     @Override
     public void setUp() throws Exception {
         super.setUp();
-        networks = loadNetworkConfigurations();
-        if (DEBUG) {
-            printNetworkConfigurations();
-        }
-
-        // enable Wifi and verify wpa_supplicant is started
-        assertTrue("enable Wifi failed", enableWifi());
-        sleep(2 * SHORT_TIMEOUT, "interrupted while waiting for WPA_SUPPLICANT to start");
-        WifiInfo mConnection = mWifiManager.getConnectionInfo();
-        assertNotNull(mConnection);
-        assertTrue("wpa_supplicant is not started ", mWifiManager.pingSupplicant());
-    }
-
-    private void printNetworkConfigurations() {
-        log("==== print network configurations parsed from XML file ====");
-        log("number of access points: " + networks.size());
-        for (WifiConfiguration config : networks) {
-            log(config.toString());
-        }
+        assertTrue("Failed to enable wifi", enableWifi());
     }
 
     @Override
@@ -75,51 +56,67 @@
         super.tearDown();
     }
 
-    /**
-     * Connect to the provided Wi-Fi network
-     * @param config is the network configuration
-     * @return true if the connection is successful.
-     */
-    private void connectToWifi(WifiConfiguration config) {
-        // step 1: connect to the test access point
-        assertTrue("failed to connect to " + config.SSID,
-                connectToWifiWithConfiguration(config));
-
-        // step 2: verify Wifi state and network state;
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI,
-                State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
-
-        // step 3: verify the current connected network is the given SSID
-        assertNotNull("Wifi connection returns null", mWifiManager.getConnectionInfo());
-        if (DEBUG) {
-            log("config.SSID = " + config.SSID);
-            log("mWifiManager.getConnectionInfo.getSSID()" +
-                    mWifiManager.getConnectionInfo().getSSID());
-        }
-        assertTrue(config.SSID.contains(mWifiManager.getConnectionInfo().getSSID()));
-    }
-
-    private void sleep(long sometime, String errorMsg) {
-        try {
-            Thread.sleep(sometime);
-        } catch (InterruptedException e) {
-            fail(errorMsg);
-        }
-    }
-
-    private void log(String message) {
-        Log.v(TAG, message);
-    }
-
     @LargeTest
     public void testWifiConnections() {
-        for (int i = 0; i < networks.size(); i++) {
-            String ssid = networks.get(i).SSID;
-            log("-- START Wi-Fi connection test to : " + ssid + " --");
-            connectToWifi(networks.get(i));
-            // wait for 2 minutes between wifi stop and start
-            sleep(WIFI_STOP_START_INTERVAL, "interruped while connected to wifi");
-            log("-- END Wi-Fi connection test to " + ssid + " -- ");
+        List<WifiConfiguration> wifiConfigs = loadConfigurations();
+
+        printWifiConfigurations(wifiConfigs);
+
+        assertFalse("No configurations to test against", wifiConfigs.isEmpty());
+
+        boolean shouldPause = false;
+        for (WifiConfiguration config : wifiConfigs) {
+            if (shouldPause) {
+                logv("Pausing for %d seconds", PAUSE_DURATION_MS / 1000);
+                SystemClock.sleep(PAUSE_DURATION_MS);
+            }
+            logv("Start wifi connection test to: %s", config.SSID);
+            connectToWifi(config);
+
+            // verify that connection actually works
+            assertTrue("No connectivity at end of test", checkNetworkConnectivity());
+
+            // Disconnect and remove the network
+            assertTrue("Unable to remove network", disconnectAP());
+            logv("End wifi connection test to: %s", config.SSID);
+
+            shouldPause = true;
+        }
+    }
+
+    /**
+     * Load the configuration file from the root of the data partition
+     */
+    private List<WifiConfiguration> loadConfigurations() {
+        BufferedReader reader = null;
+        try {
+            reader = new BufferedReader(new FileReader(new File(WIFI_CONFIG_FILE)));
+            StringBuffer jsonBuffer = new StringBuffer();
+            String line;
+            while ((line = reader.readLine()) != null) {
+                jsonBuffer.append(line);
+            }
+            return WifiConfigurationHelper.parseJson(jsonBuffer.toString());
+        } catch (IllegalArgumentException | IOException e) {
+            throw new AssertionError("Error parsing file", e);
+        } finally {
+            if (reader != null) {
+                try {
+                    reader.close();
+                } catch (IOException e) {
+                    // Ignore
+                }
+            }
+        }
+    }
+
+    /**
+     * Print the wifi configurations to test against.
+     */
+    private void printWifiConfigurations(List<WifiConfiguration> wifiConfigs) {
+        logv("Wifi configurations to be tested");
+        for (WifiConfiguration config : wifiConfigs) {
+            logv(config.toString());
         }
     }
 }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiApStress.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiApStress.java
index 790ca38..41f01e6 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiApStress.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiApStress.java
@@ -17,51 +17,53 @@
 package com.android.connectivitymanagertest.stress;
 
 
-import com.android.connectivitymanagertest.ConnectivityManagerStressTestRunner;
-import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
-
 import android.net.wifi.WifiConfiguration;
-import android.net.wifi.WifiConfiguration.KeyMgmt;
 import android.net.wifi.WifiConfiguration.AuthAlgorithm;
+import android.net.wifi.WifiConfiguration.KeyMgmt;
 import android.net.wifi.WifiManager;
 import android.os.Environment;
 import android.test.suitebuilder.annotation.LargeTest;
-import android.util.Log;
+
+import com.android.connectivitymanagertest.ConnectivityManagerStressTestRunner;
+import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
 
 import java.io.BufferedWriter;
 import java.io.File;
 import java.io.FileWriter;
 
 /**
- * Stress the wifi driver as access point.
+ * Stress test setting up device as wifi hotspot
  */
-public class WifiApStress
-    extends ConnectivityManagerTestBase {
-    private final static String TAG = "WifiApStress";
+public class WifiApStress extends ConnectivityManagerTestBase {
     private static String NETWORK_ID = "AndroidAPTest";
     private static String PASSWD = "androidwifi";
     private final static String OUTPUT_FILE = "WifiStressTestOutput.txt";
-    private int iterations;
+    private int mTotalIterations;
     private BufferedWriter mOutputWriter = null;
     private int mLastIteration = 0;
     private boolean mWifiOnlyFlag;
 
+    public WifiApStress() {
+        super(WifiApStress.class.getSimpleName());
+    }
+
     @Override
-    public void setUp() throws Exception {
+    protected void setUp() throws Exception {
         super.setUp();
         ConnectivityManagerStressTestRunner mRunner =
             (ConnectivityManagerStressTestRunner)getInstrumentation();
-        iterations = mRunner.mSoftapIterations;
-        mWifiOnlyFlag = mRunner.mWifiOnlyFlag;
+        mTotalIterations = mRunner.getSoftApInterations();
+        mWifiOnlyFlag = mRunner.isWifiOnly();
         turnScreenOn();
     }
 
     @Override
-    public void tearDown() throws Exception {
+    protected void tearDown() throws Exception {
         // write the total number of iterations into output file
         mOutputWriter = new BufferedWriter(new FileWriter(new File(
                 Environment.getExternalStorageDirectory(), OUTPUT_FILE)));
-        mOutputWriter.write(String.format("iteration %d out of %d\n", mLastIteration, iterations));
+        mOutputWriter.write(String.format("iteration %d out of %d\n",
+                mLastIteration + 1, mTotalIterations));
         mOutputWriter.flush();
         mOutputWriter.close();
         super.tearDown();
@@ -70,7 +72,7 @@
     @LargeTest
     public void testWifiHotSpot() {
         if (mWifiOnlyFlag) {
-            Log.v(TAG, this.getName() + " is excluded for wi-fi only test");
+            logv(getName() + " is excluded for wi-fi only test");
             return;
         }
         WifiConfiguration config = new WifiConfiguration();
@@ -79,40 +81,44 @@
         config.allowedAuthAlgorithms.set(AuthAlgorithm.OPEN);
         config.preSharedKey = PASSWD;
 
-        // If Wifi is enabled, disable it
+        // if wifiap enabled, disable it
+        assertTrue("failed to disable wifi hotspot",
+                mWifiManager.setWifiApEnabled(config, false));
+        assertTrue("wifi hotspot not enabled", waitForWifiApState(
+                WifiManager.WIFI_AP_STATE_DISABLED, 2 * LONG_TIMEOUT));
+
+        // if Wifi is enabled, disable it
         if (mWifiManager.isWifiEnabled()) {
-            disableWifi();
+            assertTrue("failed to disable wifi", disableWifi());
+            // wait for the wifi state to be DISABLED
+            assertTrue("wifi state not disabled", waitForWifiState(
+                    WifiManager.WIFI_STATE_DISABLED, LONG_TIMEOUT));
         }
         int i;
-        for (i = 0; i < iterations; i++) {
-            Log.v(TAG, "iteration: " + i);
+        for (i = 0; i < mTotalIterations; i++) {
+            logv("iteration: " + i);
             mLastIteration = i;
             // enable Wifi tethering
-            assertTrue(mWifiManager.setWifiApEnabled(config, true));
-            // Wait for wifi ap state to be ENABLED
-            assertTrue(waitForWifiAPState(WifiManager.WIFI_AP_STATE_ENABLED, 2 * LONG_TIMEOUT));
-            // Wait for wifi tethering result
-            assertEquals(SUCCESS, waitForTetherStateChange(2 * SHORT_TIMEOUT));
-            // Allow the wifi tethering to be enabled for 10 seconds
+            assertTrue("failed to enable wifi hotspot",
+                    mWifiManager.setWifiApEnabled(config, true));
+            // wait for wifi ap state to be ENABLED
+            assertTrue("wifi hotspot not enabled", waitForWifiApState(
+                    WifiManager.WIFI_AP_STATE_ENABLED, 2 * LONG_TIMEOUT));
+            // wait for wifi tethering result
+            assertTrue("tether state not changed", waitForTetherStateChange(LONG_TIMEOUT));
+            // allow the wifi tethering to be enabled for 10 seconds
             try {
                 Thread.sleep(2 * SHORT_TIMEOUT);
             } catch (Exception e) {
-                fail("thread in sleep is interrupted");
+                // ignore
             }
             assertTrue("no uplink data connection after Wi-Fi tethering", pingTest(null));
-            // Disable soft AP
-            assertTrue(mWifiManager.setWifiApEnabled(config, false));
-            // Wait for 30 seconds until Wi-Fi tethering is stopped
-            try {
-                Thread.sleep(30 * 1000);
-                Log.v(TAG, "wait for Wi-Fi tethering to be disabled.");
-            } catch (Exception e) {
-                fail("thread in sleep is interrupted");
-            }
-            assertFalse("Wi-Fi AP disable failed", mWifiManager.isWifiApEnabled());
-        }
-        if (i == iterations) {
-            mLastIteration = iterations;
+            // disable wifi hotspot
+            assertTrue("failed to disable wifi hotspot",
+                    mWifiManager.setWifiApEnabled(config, false));
+            assertTrue("wifi hotspot not enabled", waitForWifiApState(
+                    WifiManager.WIFI_AP_STATE_DISABLED, 2 * LONG_TIMEOUT));
+            assertFalse("wifi hotspot still enabled", mWifiManager.isWifiApEnabled());
         }
     }
 
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiStressTest.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiStressTest.java
index 08618d6..fbd4669 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiStressTest.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/stress/WifiStressTest.java
@@ -16,25 +16,25 @@
 
 package com.android.connectivitymanagertest.stress;
 
+import android.app.Activity;
 import android.content.Context;
 import android.net.ConnectivityManager;
-import android.net.IpConfiguration.IpAssignment;
-import android.net.IpConfiguration.ProxySettings;
+import android.net.NetworkInfo;
 import android.net.NetworkInfo.State;
 import android.net.wifi.ScanResult;
-import android.net.wifi.WifiConfiguration.KeyMgmt;
 import android.net.wifi.WifiConfiguration;
 import android.net.wifi.WifiManager;
+import android.os.Bundle;
 import android.os.Environment;
 import android.os.PowerManager;
 import android.os.SystemClock;
 import android.provider.Settings;
-import android.view.KeyEvent;
 import android.test.suitebuilder.annotation.LargeTest;
 import android.util.Log;
 
 import com.android.connectivitymanagertest.ConnectivityManagerStressTestRunner;
 import com.android.connectivitymanagertest.ConnectivityManagerTestBase;
+import com.android.connectivitymanagertest.WifiConfigurationHelper;
 
 import java.io.BufferedWriter;
 import java.io.File;
@@ -49,15 +49,12 @@
  * adb shell am instrument -e class com.android.connectivitymanagertest.stress.WifiStressTest
  *                  -w com.android.connectivitymanagertest/.ConnectivityManagerStressTestRunner
  */
-public class WifiStressTest
-        extends ConnectivityManagerTestBase {
-    private final static String TAG = "WifiStressTest";
-
+public class WifiStressTest extends ConnectivityManagerTestBase {
     private final static long SCREEN_OFF_TIMER = 500; //500ms
     /**
      * Wi-Fi idle time for default sleep policy
      */
-    private final static long WIFI_IDLE_MS = 60 * 1000;
+    private final static long WIFI_IDLE_MS = 15 * 1000;
 
     /**
      * Delay after issuing wifi shutdown.
@@ -69,7 +66,7 @@
 
     private final static String OUTPUT_FILE = "WifiStressTestOutput.txt";
     private int mReconnectIterations;
-    private int mWifiSleepTime;
+    private long mWifiSleepTime;
     private int mScanIterations;
     private String mSsid;
     private String mPassword;
@@ -77,25 +74,29 @@
     private BufferedWriter mOutputWriter = null;
     private boolean mWifiOnlyFlag;
 
+    public WifiStressTest() {
+        super(WifiStressTest.class.getSimpleName());
+    }
+
     @Override
-    public void setUp() throws Exception {
+    protected void setUp() throws Exception {
         super.setUp();
 
         mRunner = (ConnectivityManagerStressTestRunner) getInstrumentation();
-        mReconnectIterations = mRunner.mReconnectIterations;
-        mSsid = mRunner.mReconnectSsid;
-        mPassword = mRunner.mReconnectPassword;
-        mScanIterations = mRunner.mScanIterations;
-        mWifiSleepTime = mRunner.mSleepTime;
-        mWifiOnlyFlag = mRunner.mWifiOnlyFlag;
-        log(String.format("mReconnectIterations(%d), mSsid(%s), mPassword(%s),"
+        mReconnectIterations = mRunner.getReconnectIterations();
+        mSsid = mRunner.getReconnectSsid();
+        mPassword = mRunner.getReconnectPassword();
+        mScanIterations = mRunner.getScanIterations();
+        mWifiSleepTime = mRunner.getSleepTime();
+        mWifiOnlyFlag = mRunner.isWifiOnly();
+        logv(String.format("mReconnectIterations(%d), mSsid(%s), mPassword(%s),"
             + "mScanIterations(%d), mWifiSleepTime(%d)", mReconnectIterations, mSsid,
             mPassword, mScanIterations, mWifiSleepTime));
         mOutputWriter = new BufferedWriter(new FileWriter(new File(
                 Environment.getExternalStorageDirectory(), OUTPUT_FILE), true));
         turnScreenOn();
         if (!mWifiManager.isWifiEnabled()) {
-            log("Enable wi-fi before stress tests.");
+            logv("Enable wi-fi before stress tests.");
             if (!enableWifi()) {
                 tearDown();
                 fail("enable wifi failed.");
@@ -105,8 +106,8 @@
     }
 
     @Override
-    public void tearDown() throws Exception {
-        log("tearDown()");
+    protected void tearDown() throws Exception {
+        logv("tearDown()");
         if (mOutputWriter != null) {
             mOutputWriter.close();
         }
@@ -114,23 +115,19 @@
     }
 
     private void writeOutput(String s) {
-        log("write message: " + s);
+        logv("write message: " + s);
         if (mOutputWriter == null) {
-            log("no writer attached to file " + OUTPUT_FILE);
+            logv("no writer attached to file " + OUTPUT_FILE);
             return;
         }
         try {
             mOutputWriter.write(s + "\n");
             mOutputWriter.flush();
         } catch (IOException e) {
-            log("failed to write output.");
+            logv("failed to write output.");
         }
     }
 
-    public void log(String message) {
-        Log.v(TAG, message);
-    }
-
     private void sleep(long sometime, String errorMsg) {
         try {
             Thread.sleep(sometime);
@@ -145,109 +142,84 @@
      */
     @LargeTest
     public void testWifiScanning() {
-        int scanTimeSum = 0;
-        int i;
+        long scanTimeSum = 0, i, averageScanTime = -1;
         int ssidAppearInScanResultsCount = 0; // count times of given ssid appear in scan results.
-        for (i = 0; i < mScanIterations; i++) {
-            log("testWifiScanning: iteration: " + i);
-            int averageScanTime = 0;
-            if (i > 0) {
-                averageScanTime = scanTimeSum/i;
-            }
-            writeOutput(String.format("iteration %d out of %d",
-                    i, mScanIterations));
+        for (i = 1; i <= mScanIterations; i++) {
+            logv("testWifiScanning: iteration: " + i);
+            averageScanTime = scanTimeSum / i;
+            writeOutput(String.format("iteration %d out of %d", i, mScanIterations));
             writeOutput(String.format("average scanning time is %d", averageScanTime));
             writeOutput(String.format("ssid appear %d out of %d scan iterations",
                     ssidAppearInScanResultsCount, i));
-            long startTime = SystemClock.uptimeMillis();
-            scanResultAvailable = false;
-            assertTrue("start scan failed", mWifiManager.startScan());
-            while (true) {
-                if ((SystemClock.uptimeMillis() - startTime) >
-                WIFI_SCAN_TIMEOUT) {
-                    fail("Wifi scanning takes more than " + WIFI_SCAN_TIMEOUT + " ms");
+            List<ScanResult> scanResultLocal = null;
+            // wait for a scan result
+            long start = 0;
+            synchronized (mWifiScanResultLock) {
+                start = SystemClock.uptimeMillis();
+                assertTrue("start scan failed", mWifiManager.startScan());
+                try {
+                    mWifiScanResultLock.wait(WAIT_FOR_SCAN_RESULT);
+                } catch (InterruptedException e) {
+                    // ignore
                 }
-                synchronized(this) {
-                    try {
-                        wait(WAIT_FOR_SCAN_RESULT);
-                    } catch (InterruptedException e) {
-                        e.printStackTrace();
-                    }
-                    if (scanResultAvailable) {
-                        long scanTime = (SystemClock.uptimeMillis() - startTime);
-                        scanTimeSum += scanTime;
-                        break;
-                    }
-                }
+                scanTimeSum += SystemClock.uptimeMillis() - start;
+                // save the scan result while in lock
+                scanResultLocal = mLastScanResult;
             }
-            if ((mWifiManager.getScanResults() == null) ||
-                    (mWifiManager.getScanResults().size() <= 0)) {
+            if (scanResultLocal == null || scanResultLocal.isEmpty()) {
                 fail("Scan results are empty ");
             }
-
-            List<ScanResult> netList = mWifiManager.getScanResults();
-            if (netList != null) {
-                log("size of scan result list: " + netList.size());
-                for (int s = 0; s < netList.size(); s++) {
-                    ScanResult sr= netList.get(s);
-                    log(String.format("scan result for %s is: %s", sr.SSID, sr.toString()));
-                    log(String.format("signal level for %s is %d ", sr.SSID, sr.level));
-                    if (sr.SSID.equals(mSsid)) {
-                        ssidAppearInScanResultsCount += 1;
-                        log("Number of times " + mSsid + " appear in the scan list: " +
-                                ssidAppearInScanResultsCount);
-                        break;
-                    }
+            logv("size of scan result list: " + scanResultLocal.size());
+            for (ScanResult sr : scanResultLocal) {
+                logv(String.format("scan result: " + sr.toString()));
+                if (mSsid.equals(sr.SSID)) {
+                    ssidAppearInScanResultsCount += 1;
+                    break;
                 }
             }
         }
-        if (i == mScanIterations) {
-            writeOutput(String.format("iteration %d out of %d",
-                    i, mScanIterations));
-            writeOutput(String.format("average scanning time is %d", scanTimeSum/mScanIterations));
+        Bundle result = new Bundle();
+        result.putLong("actual-iterations", i - 1);
+        result.putLong("avg-scan-time", averageScanTime);
+        result.putInt("ap-discovered", ssidAppearInScanResultsCount);
+        getInstrumentation().sendStatus(Activity.RESULT_FIRST_USER, result);
+        if (i == mScanIterations + 1) {
+            writeOutput(String.format("iteration %d out of %d", i, mScanIterations));
+            writeOutput(String.format("average scanning time is %d", scanTimeSum / (i - 1)));
             writeOutput(String.format("ssid appear %d out of %d scan iterations",
-                    ssidAppearInScanResultsCount, mScanIterations));
+                    ssidAppearInScanResultsCount, i));
         }
     }
 
     // Stress Wifi reconnection to secure net after sleep
     @LargeTest
     public void testWifiReconnectionAfterSleep() {
-        int value = Settings.Global.getInt(mRunner.getContext().getContentResolver(),
-                Settings.Global.WIFI_SLEEP_POLICY, -1);
-        log("wifi sleep policy is: " + value);
-        if (value != Settings.Global.WIFI_SLEEP_POLICY_DEFAULT) {
-            Settings.Global.putInt(mRunner.getContext().getContentResolver(),
-                    Settings.Global.WIFI_SLEEP_POLICY, Settings.Global.WIFI_SLEEP_POLICY_DEFAULT);
-            log("set wifi sleep policy to default value");
-        }
+        // set always scan to false
+        Settings.Global.putInt(mRunner.getContext().getContentResolver(),
+                Settings.Global.WIFI_SCAN_ALWAYS_AVAILABLE, 0);
+        // set wifi sleep policy to never on while in sleep
+        Settings.Global.putInt(mRunner.getContext().getContentResolver(),
+                Settings.Global.WIFI_SLEEP_POLICY, Settings.Global.WIFI_SLEEP_POLICY_NEVER);
+        // set idle timeout for wifi to 15s
         Settings.Global.putLong(mRunner.getContext().getContentResolver(),
                 Settings.Global.WIFI_IDLE_MS, WIFI_IDLE_MS);
 
-        // Connect to a Wi-Fi network
-        WifiConfiguration config = new WifiConfiguration();
-        config.SSID = mSsid;
-        config.allowedKeyManagement.set(KeyMgmt.WPA_PSK);
-        if (mPassword.matches("[0-9A-Fa-f]{64}")) {
-            config.preSharedKey = mPassword;
+        WifiConfiguration config;
+        if (mPassword == null) {
+            config = WifiConfigurationHelper.createOpenConfig(mSsid);
         } else {
-            config.preSharedKey = '"' + mPassword + '"';
+            config = WifiConfigurationHelper.createPskConfig(mSsid, mPassword);
         }
-        config.setIpAssignment(IpAssignment.DHCP);
-        config.setProxySettings(ProxySettings.NONE);
 
         assertTrue("Failed to connect to Wi-Fi network: " + mSsid,
                 connectToWifiWithConfiguration(config));
-        assertTrue(waitForWifiState(WifiManager.WIFI_STATE_ENABLED,
-                SHORT_TIMEOUT));
-        assertTrue(waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                WIFI_CONNECTION_TIMEOUT));
+        assertTrue("wifi not connected", waitForNetworkState(ConnectivityManager.TYPE_WIFI,
+                State.CONNECTED, WIFI_CONNECTION_TIMEOUT));
         // Run ping test to verify the data connection
         assertTrue("Wi-Fi is connected, but no data connection.", pingTest(null));
 
-        int i;
-        long sum = 0;
-        for (i = 0; i < mReconnectIterations; i++) {
+        long i, sum = 0, avgReconnectTime = 0;
+        for (i = 1; i <= mReconnectIterations; i++) {
             // 1. Put device into sleep mode
             // 2. Wait for the device to sleep for sometime, verify wi-fi is off and mobile is on.
             // 3. Maintain the sleep mode for some time,
@@ -255,59 +227,67 @@
             // 5. Wake up the device, verify Wi-Fi is enabled and connected.
             writeOutput(String.format("iteration %d out of %d",
                     i, mReconnectIterations));
-            log("iteration: " + i);
+            logv("iteration: " + i);
             turnScreenOff();
             // Use clock time since boot for intervals.
             long start = SystemClock.uptimeMillis();
             PowerManager pm =
                 (PowerManager)mRunner.getContext().getSystemService(Context.POWER_SERVICE);
-            while (pm.isScreenOn() && ((SystemClock.uptimeMillis() - start) < SCREEN_OFF_TIMER)) {
-                sleep(100, "wait for screen off");
+            while (pm.isInteractive() &&
+                    ((SystemClock.uptimeMillis() - start) < SCREEN_OFF_TIMER)) {
+                SystemClock.sleep(100);
             }
-            assertFalse(pm.isScreenOn());
-            sleep(WIFI_IDLE_MS + WIFI_SHUTDOWN_DELAY, "Interruped while wait for wifi to be idle");
-            assertTrue("Wait for Wi-Fi to idle timeout",
-                    waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.DISCONNECTED,
-                    6 * SHORT_TIMEOUT));
-            if (!mWifiOnlyFlag) {
+            assertFalse("screen still on", pm.isInteractive());
+            // wait for WiFi timeout
+            SystemClock.sleep(WIFI_IDLE_MS + WIFI_SHUTDOWN_DELAY);
+            // below check temporarily disabled due to bug in ConnectivityManager return
+//            assertTrue("Wait for Wi-Fi to idle timeout",
+//                    waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.DISCONNECTED,
+//                    6 * SHORT_TIMEOUT));
+            if (mWifiOnlyFlag) {
+                assertTrue("expected wifi disconnect, still has active connection",
+                        waitUntilNoActiveNetworkConnection(2 * LONG_TIMEOUT));
+            } else {
                 // use long timeout as the pppd startup may take several retries.
-                assertTrue("Wait for cellular connection timeout",
+                assertTrue("no fallback on mobile or wifi didn't disconnect",
                         waitForNetworkState(ConnectivityManager.TYPE_MOBILE, State.CONNECTED,
                         2 * LONG_TIMEOUT));
             }
-            sleep(mWifiSleepTime, "Interrupted while device is in sleep mode");
-            // Verify the wi-fi is still off and data connection is on
-            assertEquals("Wi-Fi is reconnected", State.DISCONNECTED,
-                    mCM.getNetworkInfo(ConnectivityManager.TYPE_WIFI).getState());
-
-            if (!mWifiOnlyFlag) {
-                assertEquals("Cellular connection is down", State.CONNECTED,
-                             mCM.getNetworkInfo(ConnectivityManager.TYPE_MOBILE).getState());
-                assertTrue("Mobile is connected, but no data connection.", pingTest(null));
+            SystemClock.sleep(mWifiSleepTime);
+            // verify the wi-fi is still off and either we have no connectivity or fallback on mobile
+            if (mWifiOnlyFlag) {
+                NetworkInfo ni = mCm.getActiveNetworkInfo();
+                if (ni != null) {
+                    Log.e(mLogTag, "has active network while in wifi sleep: " + ni.toString());
+                    fail("active network detected");
+                }
+            } else {
+                assertEquals("mobile not connected", State.CONNECTED,
+                        mCm.getNetworkInfo(ConnectivityManager.TYPE_MOBILE).getState());
+                assertTrue("no connectivity over mobile", pingTest(null));
             }
 
             // Turn screen on again
             turnScreenOn();
-            // Wait for 2 seconds for the lock screen
-            sleep(2 * 1000, "wait 2 seconds for lock screen");
-            // Disable lock screen by inject menu key event
-            mRunner.sendKeyDownUpSync(KeyEvent.KEYCODE_MENU);
-
             // Measure the time for Wi-Fi to get connected
             long startTime = SystemClock.uptimeMillis();
-            assertTrue("Wait for Wi-Fi enable timeout after wake up",
-                    waitForWifiState(WifiManager.WIFI_STATE_ENABLED,
-                    SHORT_TIMEOUT));
-            assertTrue("Wait for Wi-Fi connection timeout after wake up",
+            assertTrue("screen on: wifi not enabled before timeout",
+                    waitForWifiState(WifiManager.WIFI_STATE_ENABLED, SHORT_TIMEOUT));
+            assertTrue("screen on: wifi not connected before timeout",
                     waitForNetworkState(ConnectivityManager.TYPE_WIFI, State.CONNECTED,
-                    WIFI_CONNECTION_TIMEOUT));
+                    LONG_TIMEOUT));
             long connectionTime = SystemClock.uptimeMillis() - startTime;
             sum += connectionTime;
-            log("average reconnection time is: " + sum/(i+1));
+            avgReconnectTime = sum / i;
+            logv("average reconnection time is: " + avgReconnectTime);
 
             assertTrue("Reconnect to Wi-Fi network, but no data connection.", pingTest(null));
         }
-        if (i == mReconnectIterations) {
+        Bundle result = new Bundle();
+        result.putLong("actual-iterations", i - 1);
+        result.putLong("avg-reconnect-time", avgReconnectTime);
+        getInstrumentation().sendStatus(Activity.RESULT_FIRST_USER, result);
+        if (i == mReconnectIterations + 1) {
             writeOutput(String.format("iteration %d out of %d",
                     i, mReconnectIterations));
         }
diff --git a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/unit/WifiClientTest.java b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/unit/WifiClientTest.java
index 7a9bc78..5c2f388 100644
--- a/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/unit/WifiClientTest.java
+++ b/core/tests/ConnectivityManagerTest/src/com/android/connectivitymanagertest/unit/WifiClientTest.java
@@ -38,7 +38,6 @@
 public class WifiClientTest extends AndroidTestCase {
 
     private WifiManager mWifiManager;
-    private final String TAG = "WifiClientTest";
 
     //10s delay for turning on wifi
     private static final int DELAY = 10000;
diff --git a/core/tests/coretests/src/android/content/pm/PackageHelperTests.java b/core/tests/coretests/src/android/content/pm/PackageHelperTests.java
index 7ad35d0..06c495e 100644
--- a/core/tests/coretests/src/android/content/pm/PackageHelperTests.java
+++ b/core/tests/coretests/src/android/content/pm/PackageHelperTests.java
@@ -16,7 +16,7 @@
 
 package android.content.pm;
 
-import com.android.internal.content.PackageHelper;
+import static android.net.TrafficStats.MB_IN_BYTES;
 
 import android.os.IBinder;
 import android.os.RemoteException;
@@ -25,6 +25,8 @@
 import android.test.AndroidTestCase;
 import android.util.Log;
 
+import com.android.internal.content.PackageHelper;
+
 public class PackageHelperTests extends AndroidTestCase {
     private static final boolean localLOGV = true;
     public static final String TAG = "PackageHelperTests";
@@ -81,8 +83,8 @@
     public void testMountAndPullSdCard() {
         try {
             fullId = PREFIX;
-            fullId2 = PackageHelper.createSdDir(1024, fullId, "none", android.os.Process.myUid(),
-                    true);
+            fullId2 = PackageHelper.createSdDir(1024 * MB_IN_BYTES, fullId, "none",
+                    android.os.Process.myUid(), true);
 
             Log.d(TAG,PackageHelper.getSdDir(fullId));
             PackageHelper.unMountSdDir(fullId);
diff --git a/core/tests/coretests/src/android/net/NetworkStatsTest.java b/core/tests/coretests/src/android/net/NetworkStatsTest.java
index 6331964..9ee4e20 100644
--- a/core/tests/coretests/src/android/net/NetworkStatsTest.java
+++ b/core/tests/coretests/src/android/net/NetworkStatsTest.java
@@ -310,6 +310,16 @@
         assertEquals(128L + 512L, clone.getTotalBytes());
     }
 
+    public void testAddWhenEmpty() throws Exception {
+        final NetworkStats red = new NetworkStats(TEST_START, -1);
+        final NetworkStats blue = new NetworkStats(TEST_START, 5)
+                .addValues(TEST_IFACE, 100, SET_DEFAULT, TAG_NONE, 128L, 8L, 0L, 2L, 20L)
+                .addValues(TEST_IFACE2, 100, SET_DEFAULT, TAG_NONE, 512L, 32L, 0L, 0L, 0L);
+
+        // We're mostly checking that we don't crash
+        red.combineAllValues(blue);
+    }
+
     private static void assertValues(NetworkStats stats, int index, String iface, int uid, int set,
             int tag, long rxBytes, long rxPackets, long txBytes, long txPackets, long operations) {
         final NetworkStats.Entry entry = stats.getValues(index, null);
diff --git a/core/tests/coretests/src/android/os/storage/AsecTests.java b/core/tests/coretests/src/android/os/storage/AsecTests.java
index abb8eae..4f724fe 100644
--- a/core/tests/coretests/src/android/os/storage/AsecTests.java
+++ b/core/tests/coretests/src/android/os/storage/AsecTests.java
@@ -90,7 +90,7 @@
         String fullId = SECURE_CONTAINER_PREFIX + localId;
 
         IMountService ms = getMs();
-        return ms.mountSecureContainer(fullId, key, android.os.Process.myUid());
+        return ms.mountSecureContainer(fullId, key, android.os.Process.myUid(), true);
     }
 
     private int renameContainer(String localId1, String localId2) throws Exception {
diff --git a/core/tests/hosttests/test-apps/DownloadManagerTestApp/Android.mk b/core/tests/hosttests/test-apps/DownloadManagerTestApp/Android.mk
index a288058..97e8b1f 100644
--- a/core/tests/hosttests/test-apps/DownloadManagerTestApp/Android.mk
+++ b/core/tests/hosttests/test-apps/DownloadManagerTestApp/Android.mk
@@ -21,7 +21,7 @@
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
 
 LOCAL_STATIC_JAVA_LIBRARIES := android-common mockwebserver
-LOCAL_SDK_VERSION := current
+LOCAL_JAVA_LIBRARIES := android.test.runner
 
 LOCAL_PACKAGE_NAME := DownloadManagerTestApp
 
diff --git a/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestApp.java b/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestApp.java
index bcf2e45..db547e2 100644
--- a/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestApp.java
+++ b/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestApp.java
@@ -60,10 +60,10 @@
         super.setUp();
         DownloadManagerTestRunner mRunner = (DownloadManagerTestRunner)getInstrumentation();
         externalDownloadUriValue = normalizeUri(mRunner.externalDownloadUriValue);
-        assertNotNull(externalDownloadUriValue);
+        assertNotNull("download url is null", externalDownloadUriValue);
 
         externalLargeDownloadUriValue = normalizeUri(mRunner.externalDownloadUriValue);
-        assertNotNull(externalLargeDownloadUriValue);
+        assertNotNull("large download url is null", externalLargeDownloadUriValue);
     }
 
     /**
@@ -140,7 +140,7 @@
 
             dlRequest = mDownloadManager.enqueue(request);
             waitForDownloadToStart(dlRequest);
-            assertTrue(dlRequest != -1);
+            assertTrue("request id is -1 from download manager", dlRequest != -1);
 
             // Store ID of download for later retrieval
             outputFile = new DataOutputStream(fileOutput);
@@ -183,7 +183,7 @@
             mContext.deleteFile(DOWNLOAD_STARTED_FLAG);
         }
 
-        assertTrue(dlRequest != -1);
+        assertTrue("request id is -1 from download manager", dlRequest != -1);
         Cursor cursor = getCursor(dlRequest);
         ParcelFileDescriptor pfd = null;
         try {
@@ -193,7 +193,7 @@
             int status = cursor.getInt(columnIndex);
             int currentWaitTime = 0;
 
-            assertTrue(waitForDownload(dlRequest, 15 * 60 * 1000));
+            assertTrue("download not finished", waitForDownload(dlRequest, 15 * 60 * 1000));
 
             Log.i(LOG_TAG, "Verifying download information...");
             // Verify specific info about the file (size, name, etc)...
@@ -233,7 +233,7 @@
         dlRequest = mDownloadManager.enqueue(request);
 
         // Rather large file, so wait up to 15 mins...
-        assertTrue(waitForDownload(dlRequest, 15 * 60 * 1000));
+        assertTrue("download not finished", waitForDownload(dlRequest, 15 * 60 * 1000));
 
         Cursor cursor = getCursor(dlRequest);
         ParcelFileDescriptor pfd = null;
@@ -317,7 +317,7 @@
             Log.i(LOG_TAG, "Turning on WiFi...");
             setWiFiStateOn(true);
             Log.i(LOG_TAG, "Waiting up to 10 minutes for download to complete...");
-            assertTrue(waitForDownload(dlRequest, 10 * 60 * 1000));
+            assertTrue("download not finished", waitForDownload(dlRequest, 10 * 60 * 1000));
             ParcelFileDescriptor pfd = mDownloadManager.openDownloadedFile(dlRequest);
             verifyFileSize(pfd, filesize);
         } finally {
@@ -385,7 +385,7 @@
             setWiFiStateOn(true);
 
             Log.i(LOG_TAG, "Waiting up to 10 minutes for download to complete...");
-            assertTrue(waitForDownload(dlRequest, 10 * 60 * 1000));
+            assertTrue("download not finished", waitForDownload(dlRequest, 10 * 60 * 1000));
             ParcelFileDescriptor pfd = mDownloadManager.openDownloadedFile(dlRequest);
             verifyFileSize(pfd, filesize);
         } finally {
@@ -456,7 +456,7 @@
             setAirplaneModeOn(false);
 
             Log.i(LOG_TAG, "Waiting up to 10 minutes for donwload to complete...");
-            assertTrue(waitForDownload(dlRequest, 10 * 60 * 1000)); // wait up to 10 mins
+            assertTrue("download not finished", waitForDownload(dlRequest, 10 * 60 * 1000)); // wait up to 10 mins
             ParcelFileDescriptor pfd = mDownloadManager.openDownloadedFile(dlRequest);
             verifyFileSize(pfd, filesize);
         } finally {
@@ -489,11 +489,11 @@
                 Request request = new Request(remoteUri);
                 request.setTitle(filename);
                 dlRequest = mDownloadManager.enqueue(request);
-                assertTrue(dlRequest != -1);
+                assertTrue("request id is -1 from download manager", dlRequest != -1);
                 downloadIds.add(dlRequest);
             }
 
-            assertTrue(waitForMultipleDownloads(downloadIds, 15 * 60 * 2000));  // wait 15 mins max
+            assertTrue("download not finished", waitForMultipleDownloads(downloadIds, 15 * 60 * 2000));  // wait 15 mins max
         } finally {
             removeAllCurrentDownloads();
         }
diff --git a/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestRunner.java b/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestRunner.java
index 27bf7e1..70c266a 100644
--- a/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestRunner.java
+++ b/core/tests/hosttests/test-apps/DownloadManagerTestApp/src/com/android/frameworks/downloadmanagertests/DownloadManagerTestRunner.java
@@ -16,12 +16,11 @@
 
 package com.android.frameworks.downloadmanagertests;
 
+import android.content.Context;
+import android.net.wifi.WifiManager;
 import android.os.Bundle;
 import android.test.InstrumentationTestRunner;
 import android.test.InstrumentationTestSuite;
-import android.util.Log;
-
-import com.android.frameworks.downloadmanagertests.DownloadManagerTestApp;
 
 import junit.framework.TestSuite;
 
@@ -57,6 +56,9 @@
         if (externalDownloadUri != null) {
             externalDownloadUriValue = externalDownloadUri;
         }
+        // enable verbose wifi logging
+        ((WifiManager)getContext().getSystemService(Context.WIFI_SERVICE))
+            .enableVerboseLogging(1);
         super.onCreate(icicle);
     }
 
diff --git a/core/tests/inputmethodtests/run_core_inputmethod_test.sh b/core/tests/inputmethodtests/run_core_inputmethod_test.sh
index ed8b7f7..a11e49b 100755
--- a/core/tests/inputmethodtests/run_core_inputmethod_test.sh
+++ b/core/tests/inputmethodtests/run_core_inputmethod_test.sh
@@ -15,7 +15,7 @@
 
 if [[ $rebuild == true ]]; then
   make -j4 FrameworksCoreInputMethodTests
-  TESTAPP=${ANDROID_PRODUCT_OUT}/data/app/FrameworksCoreInputMethodTests.apk
+  TESTAPP=${ANDROID_PRODUCT_OUT}/data/app/FrameworksCoreInputMethodTests/FrameworksCoreInputMethodTests.apk
   COMMAND="adb install -r $TESTAPP"
   echo $COMMAND
   $COMMAND
diff --git a/core/tests/inputmethodtests/src/android/os/CursorAnchorInfoTest.java b/core/tests/inputmethodtests/src/android/os/CursorAnchorInfoTest.java
index cc4a7c4..d4244ba 100644
--- a/core/tests/inputmethodtests/src/android/os/CursorAnchorInfoTest.java
+++ b/core/tests/inputmethodtests/src/android/os/CursorAnchorInfoTest.java
@@ -26,14 +26,12 @@
 
 import java.util.Objects;
 
-import static android.view.inputmethod.CursorAnchorInfo.CHARACTER_RECT_TYPE_FULLY_VISIBLE;
-import static android.view.inputmethod.CursorAnchorInfo.CHARACTER_RECT_TYPE_INVISIBLE;
-import static android.view.inputmethod.CursorAnchorInfo.CHARACTER_RECT_TYPE_NOT_FEASIBLE;
-import static android.view.inputmethod.CursorAnchorInfo.CHARACTER_RECT_TYPE_PARTIALLY_VISIBLE;
-import static android.view.inputmethod.CursorAnchorInfo.CHARACTER_RECT_TYPE_UNSPECIFIED;
+import static android.view.inputmethod.CursorAnchorInfo.FLAG_HAS_INVISIBLE_REGION;
+import static android.view.inputmethod.CursorAnchorInfo.FLAG_HAS_VISIBLE_REGION;
+import static android.view.inputmethod.CursorAnchorInfo.FLAG_IS_RTL;
 
 public class CursorAnchorInfoTest extends InstrumentationTestCase {
-    private static final RectF[] MANY_RECTS = new RectF[] {
+    private static final RectF[] MANY_BOUNDS = new RectF[] {
             new RectF(101.0f, 201.0f, 301.0f, 401.0f),
             new RectF(102.0f, 202.0f, 302.0f, 402.0f),
             new RectF(103.0f, 203.0f, 303.0f, 403.0f),
@@ -55,25 +53,25 @@
             new RectF(119.0f, 219.0f, 319.0f, 419.0f),
     };
     private static final int[] MANY_FLAGS_ARRAY = new int[] {
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_INVISIBLE,
-        CHARACTER_RECT_TYPE_PARTIALLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_NOT_FEASIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_FULLY_VISIBLE,
-        CHARACTER_RECT_TYPE_NOT_FEASIBLE,
-        CHARACTER_RECT_TYPE_NOT_FEASIBLE,
+        FLAG_HAS_INVISIBLE_REGION,
+        FLAG_HAS_INVISIBLE_REGION | FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_INVISIBLE_REGION | FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_INVISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_VISIBLE_REGION | FLAG_IS_RTL,
+        FLAG_HAS_VISIBLE_REGION,
+        FLAG_HAS_INVISIBLE_REGION,
+        FLAG_HAS_INVISIBLE_REGION | FLAG_IS_RTL,
     };
 
     @SmallTest
@@ -82,11 +80,13 @@
         final int SELECTION_END = 40;
         final int COMPOSING_TEXT_START = 32;
         final String COMPOSING_TEXT = "test";
-        final boolean INSERTION_MARKER_CLIPPED = true;
+        final int INSERTION_MARKER_FLAGS =
+                FLAG_HAS_VISIBLE_REGION | FLAG_HAS_INVISIBLE_REGION | FLAG_IS_RTL;
         final float INSERTION_MARKER_HORIZONTAL = 10.5f;
         final float INSERTION_MARKER_TOP = 100.1f;
         final float INSERTION_MARKER_BASELINE = 110.4f;
         final float INSERTION_MARKER_BOTOM = 111.0f;
+
         Matrix TRANSFORM_MATRIX = new Matrix(Matrix.IDENTITY_MATRIX);
         TRANSFORM_MATRIX.setScale(10.0f, 20.0f);
 
@@ -94,13 +94,13 @@
         builder.setSelectionRange(SELECTION_START, SELECTION_END)
                 .setComposingText(COMPOSING_TEXT_START, COMPOSING_TEXT)
                 .setInsertionMarkerLocation(INSERTION_MARKER_HORIZONTAL, INSERTION_MARKER_TOP,
-                        INSERTION_MARKER_BASELINE, INSERTION_MARKER_BOTOM,
-                        INSERTION_MARKER_CLIPPED)
+                        INSERTION_MARKER_BASELINE, INSERTION_MARKER_BOTOM, INSERTION_MARKER_FLAGS)
                 .setMatrix(TRANSFORM_MATRIX);
-        for (int i = 0; i < MANY_RECTS.length; i++) {
-            final RectF rect = MANY_RECTS[i];
+        for (int i = 0; i < MANY_BOUNDS.length; i++) {
+            final RectF bounds = MANY_BOUNDS[i];
             final int flags = MANY_FLAGS_ARRAY[i];
-            builder.addCharacterRect(i, rect.left, rect.top, rect.right, rect.bottom, flags);
+            builder.addCharacterBounds(i, bounds.left, bounds.top, bounds.right, bounds.bottom,
+                    flags);
         }
 
         final CursorAnchorInfo info = builder.build();
@@ -108,26 +108,24 @@
         assertEquals(SELECTION_END, info.getSelectionEnd());
         assertEquals(COMPOSING_TEXT_START, info.getComposingTextStart());
         assertTrue(TextUtils.equals(COMPOSING_TEXT, info.getComposingText()));
-        assertTrue(info.isInsertionMarkerClipped());
+        assertEquals(INSERTION_MARKER_FLAGS, info.getInsertionMarkerFlags());
         assertEquals(INSERTION_MARKER_HORIZONTAL, info.getInsertionMarkerHorizontal());
         assertEquals(INSERTION_MARKER_TOP, info.getInsertionMarkerTop());
         assertEquals(INSERTION_MARKER_BASELINE, info.getInsertionMarkerBaseline());
         assertEquals(INSERTION_MARKER_BOTOM, info.getInsertionMarkerBottom());
         assertEquals(TRANSFORM_MATRIX, info.getMatrix());
-        for (int i = 0; i < MANY_RECTS.length; i++) {
-            final RectF expectedRect = MANY_RECTS[i];
-            assertEquals(expectedRect, info.getCharacterRect(i));
+        for (int i = 0; i < MANY_BOUNDS.length; i++) {
+            final RectF expectedBounds = MANY_BOUNDS[i];
+            assertEquals(expectedBounds, info.getCharacterBounds(i));
         }
-        assertNull(info.getCharacterRect(-1));
-        assertNull(info.getCharacterRect(MANY_RECTS.length + 1));
+        assertNull(info.getCharacterBounds(-1));
+        assertNull(info.getCharacterBounds(MANY_BOUNDS.length + 1));
         for (int i = 0; i < MANY_FLAGS_ARRAY.length; i++) {
             final int expectedFlags = MANY_FLAGS_ARRAY[i];
-            assertEquals(expectedFlags, info.getCharacterRectFlags(i));
+            assertEquals(expectedFlags, info.getCharacterBoundsFlags(i));
         }
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED,
-                info.getCharacterRectFlags(-1));
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED,
-                info.getCharacterRectFlags(MANY_RECTS.length + 1));
+        assertEquals(0, info.getCharacterBoundsFlags(-1));
+        assertEquals(0, info.getCharacterBoundsFlags(MANY_BOUNDS.length + 1));
 
         // Make sure that the builder can reproduce the same object.
         final CursorAnchorInfo info2 = builder.build();
@@ -135,25 +133,24 @@
         assertEquals(SELECTION_END, info2.getSelectionEnd());
         assertEquals(COMPOSING_TEXT_START, info2.getComposingTextStart());
         assertTrue(TextUtils.equals(COMPOSING_TEXT, info2.getComposingText()));
-        assertTrue(info2.isInsertionMarkerClipped());
+        assertEquals(INSERTION_MARKER_FLAGS, info2.getInsertionMarkerFlags());
         assertEquals(INSERTION_MARKER_HORIZONTAL, info2.getInsertionMarkerHorizontal());
         assertEquals(INSERTION_MARKER_TOP, info2.getInsertionMarkerTop());
         assertEquals(INSERTION_MARKER_BASELINE, info2.getInsertionMarkerBaseline());
         assertEquals(INSERTION_MARKER_BOTOM, info2.getInsertionMarkerBottom());
         assertEquals(TRANSFORM_MATRIX, info2.getMatrix());
-        for (int i = 0; i < MANY_RECTS.length; i++) {
-            final RectF expectedRect = MANY_RECTS[i];
-            assertEquals(expectedRect, info2.getCharacterRect(i));
+        for (int i = 0; i < MANY_BOUNDS.length; i++) {
+            final RectF expectedBounds = MANY_BOUNDS[i];
+            assertEquals(expectedBounds, info2.getCharacterBounds(i));
         }
-        assertNull(info2.getCharacterRect(-1));
-        assertNull(info2.getCharacterRect(MANY_RECTS.length + 1));
+        assertNull(info2.getCharacterBounds(-1));
+        assertNull(info2.getCharacterBounds(MANY_BOUNDS.length + 1));
         for (int i = 0; i < MANY_FLAGS_ARRAY.length; i++) {
             final int expectedFlags = MANY_FLAGS_ARRAY[i];
-            assertEquals(expectedFlags, info2.getCharacterRectFlags(i));
+            assertEquals(expectedFlags, info2.getCharacterBoundsFlags(i));
         }
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED, info2.getCharacterRectFlags(-1));
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED,
-                info2.getCharacterRectFlags(MANY_RECTS.length + 1));
+        assertEquals(0, info2.getCharacterBoundsFlags(-1));
+        assertEquals(0, info2.getCharacterBoundsFlags(MANY_BOUNDS.length + 1));
         assertEquals(info, info2);
         assertEquals(info.hashCode(), info2.hashCode());
 
@@ -163,25 +160,24 @@
         assertEquals(SELECTION_END, info3.getSelectionEnd());
         assertEquals(COMPOSING_TEXT_START, info3.getComposingTextStart());
         assertTrue(TextUtils.equals(COMPOSING_TEXT, info3.getComposingText()));
-        assertTrue(info3.isInsertionMarkerClipped());
+        assertEquals(INSERTION_MARKER_FLAGS, info3.getInsertionMarkerFlags());
         assertEquals(INSERTION_MARKER_HORIZONTAL, info3.getInsertionMarkerHorizontal());
         assertEquals(INSERTION_MARKER_TOP, info3.getInsertionMarkerTop());
         assertEquals(INSERTION_MARKER_BASELINE, info3.getInsertionMarkerBaseline());
         assertEquals(INSERTION_MARKER_BOTOM, info3.getInsertionMarkerBottom());
         assertEquals(TRANSFORM_MATRIX, info3.getMatrix());
-        for (int i = 0; i < MANY_RECTS.length; i++) {
-            final RectF expectedRect = MANY_RECTS[i];
-            assertEquals(expectedRect, info3.getCharacterRect(i));
+        for (int i = 0; i < MANY_BOUNDS.length; i++) {
+            final RectF expectedBounds = MANY_BOUNDS[i];
+            assertEquals(expectedBounds, info3.getCharacterBounds(i));
         }
-        assertNull(info3.getCharacterRect(-1));
-        assertNull(info3.getCharacterRect(MANY_RECTS.length + 1));
+        assertNull(info3.getCharacterBounds(-1));
+        assertNull(info3.getCharacterBounds(MANY_BOUNDS.length + 1));
         for (int i = 0; i < MANY_FLAGS_ARRAY.length; i++) {
             final int expectedFlags = MANY_FLAGS_ARRAY[i];
-            assertEquals(expectedFlags, info3.getCharacterRectFlags(i));
+            assertEquals(expectedFlags, info3.getCharacterBoundsFlags(i));
         }
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED, info3.getCharacterRectFlags(-1));
-        assertEquals(CHARACTER_RECT_TYPE_UNSPECIFIED,
-                info3.getCharacterRectFlags(MANY_RECTS.length + 1));
+        assertEquals(0, info3.getCharacterBoundsFlags(-1));
+        assertEquals(0, info3.getCharacterBoundsFlags(MANY_BOUNDS.length + 1));
         assertEquals(info.hashCode(), info3.hashCode());
 
         builder.reset();
@@ -190,7 +186,7 @@
         assertEquals(-1, uninitializedInfo.getSelectionEnd());
         assertEquals(-1, uninitializedInfo.getComposingTextStart());
         assertNull(uninitializedInfo.getComposingText());
-        assertFalse(uninitializedInfo.isInsertionMarkerClipped());
+        assertEquals(0, uninitializedInfo.getInsertionMarkerFlags());
         assertEquals(Float.NaN, uninitializedInfo.getInsertionMarkerHorizontal());
         assertEquals(Float.NaN, uninitializedInfo.getInsertionMarkerTop());
         assertEquals(Float.NaN, uninitializedInfo.getInsertionMarkerBaseline());
@@ -218,7 +214,7 @@
         final int SELECTION_END1 = 7;
         final String COMPOSING_TEXT1 = "0123456789";
         final int COMPOSING_TEXT_START1 = 0;
-        final boolean INSERTION_MARKER_CLIPPED1 = true;
+        final int INSERTION_MARKER_FLAGS1 = FLAG_HAS_VISIBLE_REGION;
         final float INSERTION_MARKER_HORIZONTAL1 = 10.5f;
         final float INSERTION_MARKER_TOP1 = 100.1f;
         final float INSERTION_MARKER_BASELINE1 = 110.4f;
@@ -227,7 +223,8 @@
         final int SELECTION_END2 = 8;
         final String COMPOSING_TEXT2 = "9876543210";
         final int COMPOSING_TEXT_START2 = 3;
-        final boolean INSERTION_MARKER_CLIPPED2 = false;
+        final int INSERTION_MARKER_FLAGS2 =
+                FLAG_HAS_VISIBLE_REGION | FLAG_HAS_INVISIBLE_REGION | FLAG_IS_RTL;
         final float INSERTION_MARKER_HORIZONTAL2 = 14.5f;
         final float INSERTION_MARKER_TOP2 = 200.1f;
         final float INSERTION_MARKER_BASELINE2 = 210.4f;
@@ -265,10 +262,10 @@
         assertEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         Float.NaN, Float.NaN, Float.NaN, Float.NaN,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         Float.NaN, Float.NaN, Float.NaN, Float.NaN,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
 
         // Check Matrix.
         assertEquals(
@@ -290,74 +287,74 @@
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         Float.NaN, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL2, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP2,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE2, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL2, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM2,
-                        INSERTION_MARKER_CLIPPED1).build());
+                        INSERTION_MARKER_FLAGS1).build());
         assertNotEquals(
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED1).build(),
+                        INSERTION_MARKER_FLAGS1).build(),
                 new Builder().setMatrix(MATRIX1).setInsertionMarkerLocation(
                         INSERTION_MARKER_HORIZONTAL1, INSERTION_MARKER_TOP1,
                         INSERTION_MARKER_BASELINE1, INSERTION_MARKER_BOTOM1,
-                        INSERTION_MARKER_CLIPPED2).build());
+                        INSERTION_MARKER_FLAGS2).build());
     }
 
     @SmallTest
@@ -394,7 +391,7 @@
         final int SELECTION_END = 40;
         final int COMPOSING_TEXT_START = 32;
         final String COMPOSING_TEXT = "test";
-        final boolean INSERTION_MARKER_CLIPPED = true;
+        final int INSERTION_MARKER_FLAGS = FLAG_HAS_VISIBLE_REGION;
         final float INSERTION_MARKER_HORIZONTAL = 10.5f;
         final float INSERTION_MARKER_TOP = 100.1f;
         final float INSERTION_MARKER_BASELINE = 110.4f;
@@ -416,7 +413,7 @@
             }
 
             builder.setInsertionMarkerLocation(INSERTION_MARKER_HORIZONTAL, INSERTION_MARKER_TOP,
-                    INSERTION_MARKER_BASELINE, INSERTION_MARKER_BOTOM, INSERTION_MARKER_CLIPPED);
+                    INSERTION_MARKER_BASELINE, INSERTION_MARKER_BOTOM, INSERTION_MARKER_FLAGS);
             try {
                 // Coordinate transformation matrix is required if no positional information is
                 // specified.
@@ -438,19 +435,10 @@
     }
 
     @SmallTest
-    public void testBuilderAddCharacterRect() throws Exception {
+    public void testBuilderAddCharacterBounds() throws Exception {
         // A negative index should be rejected.
         try {
-            new Builder().addCharacterRect(-1, 0.0f, 0.0f, 0.0f, 0.0f,
-                    CHARACTER_RECT_TYPE_FULLY_VISIBLE);
-            assertTrue(false);
-        } catch (IllegalArgumentException ex) {
-        }
-
-        // CHARACTER_RECT_TYPE_UNSPECIFIED is not allowed.
-        try {
-            new Builder().addCharacterRect(0, 0.0f, 0.0f, 0.0f, 0.0f,
-                    CHARACTER_RECT_TYPE_UNSPECIFIED);
+            new Builder().addCharacterBounds(-1, 0.0f, 0.0f, 0.0f, 0.0f, FLAG_HAS_VISIBLE_REGION);
             assertTrue(false);
         } catch (IllegalArgumentException ex) {
         }
diff --git a/core/tests/inputmethodtests/src/android/os/InputMethodTest.java b/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
index fa1bd8f..577dd64 100644
--- a/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
+++ b/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
@@ -16,8 +16,6 @@
 
 package android.os;
 
-import com.android.internal.inputmethod.InputMethodUtils;
-
 import android.content.Context;
 import android.content.pm.ApplicationInfo;
 import android.content.pm.ResolveInfo;
@@ -26,79 +24,106 @@
 import android.test.suitebuilder.annotation.SmallTest;
 import android.view.inputmethod.InputMethodInfo;
 import android.view.inputmethod.InputMethodSubtype;
+import android.view.inputmethod.InputMethodSubtype.InputMethodSubtypeBuilder;
+
+import com.android.internal.inputmethod.InputMethodUtils;
 
 import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashSet;
 import java.util.List;
+import java.util.Locale;
 
 public class InputMethodTest extends InstrumentationTestCase {
     private static final boolean IS_AUX = true;
     private static final boolean IS_DEFAULT = true;
     private static final boolean IS_AUTO = true;
+    private static final boolean IS_ASCII_CAPABLE = true;
+    private static final boolean IS_SYSTEM_READY = true;
     private static final ArrayList<InputMethodSubtype> NO_SUBTYPE = null;
+    private static final Locale LOCALE_EN_US = new Locale("en", "US");
+    private static final Locale LOCALE_EN_GB = new Locale("en", "GB");
+    private static final Locale LOCALE_EN_IN = new Locale("en", "IN");
+    private static final Locale LOCALE_HI = new Locale("hi");
+    private static final Locale LOCALE_JA_JP = new Locale("ja", "JP");
+    private static final String SUBTYPE_MODE_KEYBOARD = "keyboard";
+    private static final String SUBTYPE_MODE_VOICE = "voice";
 
     @SmallTest
-    public void testDefaultEnabledImesWithDefaultVoiceIme() throws Exception {
-        final Context context = getInstrumentation().getTargetContext();
-        final ArrayList<InputMethodInfo> imis = new ArrayList<InputMethodInfo>();
-        imis.add(createDefaultAutoDummyVoiceIme());
-        imis.add(createNonDefaultAutoDummyVoiceIme0());
-        imis.add(createNonDefaultAutoDummyVoiceIme1());
-        imis.add(createNonDefaultDummyVoiceIme2());
-        imis.add(createDefaultDummyEnUSKeyboardIme());
-        imis.add(createNonDefaultDummyJaJPKeyboardIme());
-        imis.add(createNonDefaultDummyJaJPKeyboardImeWithoutSubtypes());
-        final ArrayList<InputMethodInfo> enabledImis = InputMethodUtils.getDefaultEnabledImes(
-                context, true, imis);
-        assertEquals(2, enabledImis.size());
-        for (int i = 0; i < enabledImis.size(); ++i) {
-            final InputMethodInfo imi = enabledImis.get(0);
-            // "DummyDefaultAutoVoiceIme" and "DummyDefaultEnKeyboardIme"
-            if (imi.getPackageName().equals("DummyDefaultAutoVoiceIme")
-                    || imi.getPackageName().equals("DummyDefaultEnKeyboardIme")) {
-                continue;
-            } else {
-                fail("Invalid enabled subtype.");
-            }
-        }
+    public void testVoiceImes() throws Exception {
+        // locale: en_US
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_US, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_US, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_US, IS_SYSTEM_READY,
+                "DummyDefaultAutoVoiceIme", "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_US, IS_SYSTEM_READY,
+                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
+                "DummyDefaultEnKeyboardIme");
+
+        // locale: en_GB
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_GB, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_GB, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_GB, IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_GB, IS_SYSTEM_READY,
+                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
+                "DummyDefaultEnKeyboardIme");
+
+        // locale: ja_JP
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_JA_JP, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_JA_JP, !IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme");
+        assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_JA_JP, IS_SYSTEM_READY,
+                "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
+        assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_JA_JP, IS_SYSTEM_READY,
+                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
+                "DummyDefaultEnKeyboardIme");
     }
 
     @SmallTest
-    public void testDefaultEnabledImesWithOutDefaultVoiceIme() throws Exception {
-        final Context context = getInstrumentation().getTargetContext();
-        final ArrayList<InputMethodInfo> imis = new ArrayList<InputMethodInfo>();
-        imis.add(createNonDefaultAutoDummyVoiceIme0());
-        imis.add(createNonDefaultAutoDummyVoiceIme1());
-        imis.add(createNonDefaultDummyVoiceIme2());
-        imis.add(createDefaultDummyEnUSKeyboardIme());
-        imis.add(createNonDefaultDummyJaJPKeyboardIme());
-        imis.add(createNonDefaultDummyJaJPKeyboardImeWithoutSubtypes());
-        final ArrayList<InputMethodInfo> enabledImis = InputMethodUtils.getDefaultEnabledImes(
-                context, true, imis);
-        assertEquals(3, enabledImis.size());
-        for (int i = 0; i < enabledImis.size(); ++i) {
-            final InputMethodInfo imi = enabledImis.get(0);
-            // "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1" and
-            // "DummyDefaultEnKeyboardIme"
-            if (imi.getPackageName().equals("DummyNonDefaultAutoVoiceIme0")
-                    || imi.getPackageName().equals("DummyNonDefaultAutoVoiceIme1")
-                    || imi.getPackageName().equals("DummyDefaultEnKeyboardIme")) {
-                continue;
-            } else {
-                fail("Invalid enabled subtype.");
-            }
-        }
+    public void testKeyboardImes() throws Exception {
+        // locale: en_US
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_US, !IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.latin");
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_US, IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin");
+
+        // locale: en_GB
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_GB, !IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.latin");
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_GB, IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin");
+
+        // locale: en_IN
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_IN, !IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.latin");
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_IN, IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
+                "com.android.apps.inputmethod.hindi");
+
+        // locale: hi
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_HI, !IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.latin");
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_HI, IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
+                "com.android.apps.inputmethod.hindi");
+
+        // locale: ja_JP
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_JA_JP, !IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.latin");
+        assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_JA_JP, IS_SYSTEM_READY,
+                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
+                "com.android.apps.inputmethod.japanese");
     }
 
     @SmallTest
     public void testParcelable() throws Exception {
-        final ArrayList<InputMethodInfo> originalList = new ArrayList<InputMethodInfo>();
-        originalList.add(createNonDefaultAutoDummyVoiceIme0());
-        originalList.add(createNonDefaultAutoDummyVoiceIme1());
-        originalList.add(createNonDefaultDummyVoiceIme2());
-        originalList.add(createDefaultDummyEnUSKeyboardIme());
-        originalList.add(createNonDefaultDummyJaJPKeyboardIme());
-        originalList.add(createNonDefaultDummyJaJPKeyboardImeWithoutSubtypes());
-
+        final ArrayList<InputMethodInfo> originalList = getSamplePreinstalledImes();
         final List<InputMethodInfo> clonedList = cloneViaParcel(originalList);
         assertNotNull(clonedList);
         final List<InputMethodInfo> clonedClonedList = cloneViaParcel(clonedList);
@@ -113,6 +138,14 @@
         }
     }
 
+    private void assertDefaultEnabledImes(final ArrayList<InputMethodInfo> preinstalledImes,
+            final Locale systemLocale, final boolean isSystemReady, String... imeNames) {
+        final Context context = getInstrumentation().getTargetContext();
+        assertEquals(new HashSet<String>(Arrays.asList(imeNames)),
+                getPackageNames(callGetDefaultEnabledImesUnderWithLocale(context,
+                        isSystemReady, preinstalledImes, systemLocale)));
+    }
+
     private static List<InputMethodInfo> cloneViaParcel(final List<InputMethodInfo> list) {
         Parcel p = null;
         try {
@@ -127,6 +160,27 @@
         }
     }
 
+    private static ArrayList<InputMethodInfo> callGetDefaultEnabledImesUnderWithLocale(
+            final Context context, final boolean isSystemReady,
+            final ArrayList<InputMethodInfo> imis, final Locale locale) {
+        final Locale initialLocale = context.getResources().getConfiguration().locale;
+        try {
+            context.getResources().getConfiguration().setLocale(locale);
+            return InputMethodUtils.getDefaultEnabledImes(context, isSystemReady, imis);
+        } finally {
+            context.getResources().getConfiguration().setLocale(initialLocale);
+        }
+    }
+
+    private HashSet<String> getPackageNames(final ArrayList<InputMethodInfo> imis) {
+        final HashSet<String> packageNames = new HashSet<>();
+        for (final InputMethodInfo imi : imis) {
+            final String actualPackageName = imi.getPackageName();
+            packageNames.add(actualPackageName);
+        }
+        return packageNames;
+    }
+
     private static void verifyEquality(InputMethodInfo expected, InputMethodInfo actual) {
         assertEquals(expected, actual);
         assertEquals(expected.getSubtypeCount(), actual.getSubtypeCount());
@@ -158,61 +212,146 @@
     }
 
     private static InputMethodSubtype createDummyInputMethodSubtype(String locale, String mode,
-            boolean isAuxiliary, boolean overridesImplicitlyEnabledSubtype) {
-        return new InputMethodSubtype(0, 0, locale, mode, "", isAuxiliary,
-                overridesImplicitlyEnabledSubtype);
+            boolean isAuxiliary, boolean overridesImplicitlyEnabledSubtype,
+            boolean isAsciiCapable) {
+        return new InputMethodSubtypeBuilder()
+                .setSubtypeNameResId(0)
+                .setSubtypeIconResId(0)
+                .setSubtypeLocale(locale)
+                .setSubtypeMode(mode)
+                .setSubtypeExtraValue("")
+                .setIsAuxiliary(isAuxiliary)
+                .setOverridesImplicitlyEnabledSubtype(overridesImplicitlyEnabledSubtype)
+                .setIsAsciiCapable(isAsciiCapable)
+                .build();
     }
 
-    private static InputMethodInfo createDefaultAutoDummyVoiceIme() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("auto", "voice", IS_AUX, IS_AUTO));
-        subtypes.add(createDummyInputMethodSubtype("en_US", "voice", IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyDefaultAutoVoiceIme", "dummy.voice0",
-                "DummyVoice0", IS_AUX, IS_DEFAULT, subtypes);
+    private static ArrayList<InputMethodInfo> getImesWithDefaultVoiceIme() {
+        ArrayList<InputMethodInfo> preinstalledImes = new ArrayList<>();
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("auto", SUBTYPE_MODE_VOICE, IS_AUX, IS_AUTO,
+                    !IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_VOICE, IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("DummyDefaultAutoVoiceIme",
+                    "dummy.voice0", "DummyVoice0", IS_AUX, IS_DEFAULT, subtypes));
+        }
+        preinstalledImes.addAll(getImesWithoutDefaultVoiceIme());
+        return preinstalledImes;
     }
 
-    private static InputMethodInfo createNonDefaultAutoDummyVoiceIme0() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("auto", "voice", IS_AUX, IS_AUTO));
-        subtypes.add(createDummyInputMethodSubtype("en_US", "voice", IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyNonDefaultAutoVoiceIme0", "dummy.voice1",
-                "DummyVoice1", IS_AUX, !IS_DEFAULT, subtypes);
+    private static ArrayList<InputMethodInfo> getImesWithoutDefaultVoiceIme() {
+        ArrayList<InputMethodInfo> preinstalledImes = new ArrayList<>();
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("auto", SUBTYPE_MODE_VOICE, IS_AUX, IS_AUTO,
+                    !IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_VOICE, IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("DummyNonDefaultAutoVoiceIme0",
+                    "dummy.voice1", "DummyVoice1", IS_AUX, !IS_DEFAULT, subtypes));
+        }
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("auto", SUBTYPE_MODE_VOICE, IS_AUX, IS_AUTO,
+                    !IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_VOICE, IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("DummyNonDefaultAutoVoiceIme1",
+                    "dummy.voice2", "DummyVoice2", IS_AUX, !IS_DEFAULT, subtypes));
+        }
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_VOICE, IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("DummyNonDefaultVoiceIme2",
+                    "dummy.voice3", "DummyVoice3", IS_AUX, !IS_DEFAULT, subtypes));
+        }
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("DummyDefaultEnKeyboardIme",
+                    "dummy.keyboard0", "DummyKeyboard0", !IS_AUX, IS_DEFAULT, subtypes));
+        }
+        return preinstalledImes;
     }
 
-    private static InputMethodInfo createNonDefaultAutoDummyVoiceIme1() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("auto", "voice", IS_AUX, IS_AUTO));
-        subtypes.add(createDummyInputMethodSubtype("en_US", "voice", IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyNonDefaultAutoVoiceIme1", "dummy.voice2",
-                "DummyVoice2", IS_AUX, !IS_DEFAULT, subtypes);
-    }
+    private static ArrayList<InputMethodInfo> getSamplePreinstalledImes() {
+        ArrayList<InputMethodInfo> preinstalledImes = new ArrayList<>();
 
-    private static InputMethodInfo createNonDefaultDummyVoiceIme2() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("en_US", "voice", IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyNonDefaultVoiceIme2", "dummy.voice3",
-                "DummyVoice3", IS_AUX, !IS_DEFAULT, subtypes);
-    }
+        // a dummy Voice IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("", SUBTYPE_MODE_VOICE, IS_AUX,
+                    IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("com.android.apps.inputmethod.voice",
+                    "com.android.inputmethod.voice", "DummyVoiceIme", IS_AUX, IS_DEFAULT,
+                    subtypes));
+        }
 
-    private static InputMethodInfo createDefaultDummyEnUSKeyboardIme() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("en_US", "keyboard", !IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyDefaultEnKeyboardIme", "dummy.keyboard0",
-                "DummyKeyboard0", !IS_AUX, IS_DEFAULT, subtypes);
-    }
+        // a dummy Hindi IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            // TODO: This subtype should be marked as IS_ASCII_CAPABLE
+            subtypes.add(createDummyInputMethodSubtype("en_IN", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("hi", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("com.android.apps.inputmethod.hindi",
+                    "com.android.inputmethod.hindi", "DummyHindiIme", !IS_AUX, IS_DEFAULT,
+                    subtypes));
+        }
 
-    private static InputMethodInfo createNonDefaultDummyJaJPKeyboardIme() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        subtypes.add(createDummyInputMethodSubtype("ja_JP", "keyboard", !IS_AUX, !IS_AUTO));
-        return createDummyInputMethodInfo("DummyNonDefaultJaJPKeyboardIme", "dummy.keyboard1",
-                "DummyKeyboard1", !IS_AUX, !IS_DEFAULT, subtypes);
-    }
+        // a dummy Pinyin IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("zh_CN", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("ccom.android.apps.inputmethod.pinyin",
+                    "com.android.apps.inputmethod.pinyin", "DummyPinyinIme", !IS_AUX, IS_DEFAULT,
+                    subtypes));
+        }
 
-    // Although IMEs that have no subtype are considered to be deprecated, the Android framework
-    // must still be able to handle such IMEs as well as IMEs that have at least one subtype.
-    private static InputMethodInfo createNonDefaultDummyJaJPKeyboardImeWithoutSubtypes() {
-        final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
-        return createDummyInputMethodInfo("DummyNonDefaultJaJPKeyboardImeWithoutSubtypes",
-                "dummy.keyboard2", "DummyKeyboard2", !IS_AUX, !IS_DEFAULT, NO_SUBTYPE);
+        // a dummy Korian IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("ko", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("com.android.apps.inputmethod.korean",
+                    "com.android.apps.inputmethod.korean", "DummyKorianIme", !IS_AUX, IS_DEFAULT,
+                    subtypes));
+        }
+
+        // a dummy Latin IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("en_US", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("en_GB", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("en_IN", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("hi", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("com.android.apps.inputmethod.latin",
+                    "com.android.apps.inputmethod.latin", "DummyLatinIme", !IS_AUX, IS_DEFAULT,
+                    subtypes));
+        }
+
+        // a dummy Japanese IME
+        {
+            final ArrayList<InputMethodSubtype> subtypes = new ArrayList<InputMethodSubtype>();
+            subtypes.add(createDummyInputMethodSubtype("ja", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            subtypes.add(createDummyInputMethodSubtype("emoji", SUBTYPE_MODE_KEYBOARD, !IS_AUX,
+                    !IS_AUTO, !IS_ASCII_CAPABLE));
+            preinstalledImes.add(createDummyInputMethodInfo("com.android.apps.inputmethod.japanese",
+                    "com.android.apps.inputmethod.japanese", "DummyJapaneseIme", !IS_AUX,
+                    IS_DEFAULT, subtypes));
+        }
+
+        return preinstalledImes;
     }
 }
diff --git a/data/fonts/AndroidClock.ttf b/data/fonts/AndroidClock.ttf
index 4781ccd..a955442 100644
--- a/data/fonts/AndroidClock.ttf
+++ b/data/fonts/AndroidClock.ttf
Binary files differ
diff --git a/data/fonts/AndroidClock_Highlight.ttf b/data/fonts/AndroidClock_Highlight.ttf
index 3fa6d88..923bb30 100644
--- a/data/fonts/AndroidClock_Highlight.ttf
+++ b/data/fonts/AndroidClock_Highlight.ttf
Binary files differ
diff --git a/data/fonts/AndroidClock_Solid.ttf b/data/fonts/AndroidClock_Solid.ttf
index 3fa6d88..923bb30 100644
--- a/data/fonts/AndroidClock_Solid.ttf
+++ b/data/fonts/AndroidClock_Solid.ttf
Binary files differ
diff --git a/data/fonts/Clockopia.ttf b/data/fonts/Clockopia.ttf
index 123ea4f..3f7b6aa 100644
--- a/data/fonts/Clockopia.ttf
+++ b/data/fonts/Clockopia.ttf
Binary files differ
diff --git a/data/fonts/DroidSansFallback.ttf b/data/fonts/DroidSansFallback.ttf
index 03f49a8..96b16bb 100644
--- a/data/fonts/DroidSansFallback.ttf
+++ b/data/fonts/DroidSansFallback.ttf
Binary files differ
diff --git a/data/fonts/DroidSansFallbackFull.ttf b/data/fonts/DroidSansFallbackFull.ttf
index 1dfcc33..89959f5 100644
--- a/data/fonts/DroidSansFallbackFull.ttf
+++ b/data/fonts/DroidSansFallbackFull.ttf
Binary files differ
diff --git a/data/fonts/DroidSansMono.ttf b/data/fonts/DroidSansMono.ttf
index a007071..4085cee 100644
--- a/data/fonts/DroidSansMono.ttf
+++ b/data/fonts/DroidSansMono.ttf
Binary files differ
diff --git a/data/fonts/MTLc3m.ttf b/data/fonts/MTLc3m.ttf
index 86bdcc7..e9018f6 100644
--- a/data/fonts/MTLc3m.ttf
+++ b/data/fonts/MTLc3m.ttf
Binary files differ
diff --git a/data/fonts/MTLmr3m.ttf b/data/fonts/MTLmr3m.ttf
index 91dd47f..14f27d4 100644
--- a/data/fonts/MTLmr3m.ttf
+++ b/data/fonts/MTLmr3m.ttf
Binary files differ
diff --git a/data/fonts/fallback_fonts.xml b/data/fonts/fallback_fonts.xml
index 0f0281b..c4a949f 100644
--- a/data/fonts/fallback_fonts.xml
+++ b/data/fonts/fallback_fonts.xml
@@ -1,5 +1,9 @@
 <?xml version="1.0" encoding="utf-8"?>
 <!--
+    NOTE: this file is the legacy format, for compatibility with apps. The new,
+    more flexible format is fonts.xml. Please keep the two in sync until the legacy
+    format can be fully removed.
+
     Fallback Fonts
 
     This file specifies the fonts, and the priority order, that will be searched for any
diff --git a/data/fonts/fonts.xml b/data/fonts/fonts.xml
index a4d4906..04bc67a 100644
--- a/data/fonts/fonts.xml
+++ b/data/fonts/fonts.xml
@@ -1,4 +1,20 @@
 <?xml version="1.0" encoding="utf-8"?>
+<!--
+    NOTE: this is the newer (L) version of the system font configuration,
+    supporting richer weight selection. Some apps will expect the older
+    version, so please keep system_fonts.xml and fallback_fonts.xml in sync
+    with any changes, even though framework will only read this file.
+
+    All fonts withohut names are added to the default list. Fonts are chosen
+    based on a match: full BCP-47 language tag including script, then just
+    language, and finally order (the first font containing the glyph).
+
+    Order of appearance is also the tiebreaker for weight matching. This is
+    the reason why the 900 weights of Roboto precede the 700 weights - we
+    prefer the former when an 800 weight is requested. Since bold spans
+    effectively add 300 to the weight, this ensures that 900 is the bold
+    paired with the 500 weight, ensuring adequate contrast.
+-->
 <familyset version="22">
     <!-- first font is default -->
     <family name="sans-serif">
@@ -10,15 +26,16 @@
         <font weight="400" style="italic">Roboto-Italic.ttf</font>
         <font weight="500" style="normal">Roboto-Medium.ttf</font>
         <font weight="500" style="italic">Roboto-MediumItalic.ttf</font>
-        <font weight="700" style="normal">Roboto-Bold.ttf</font>
-        <font weight="700" style="italic">Roboto-BoldItalic.ttf</font>
         <font weight="900" style="normal">Roboto-Black.ttf</font>
         <font weight="900" style="italic">Roboto-BlackItalic.ttf</font>
+        <font weight="700" style="normal">Roboto-Bold.ttf</font>
+        <font weight="700" style="italic">Roboto-BoldItalic.ttf</font>
     </family>
 
     <!-- Note that aliases must come after the fonts they reference. -->
     <alias name="sans-serif-thin" to="sans-serif" weight="100" />
     <alias name="sans-serif-light" to="sans-serif" weight="300" />
+    <alias name="sans-serif-medium" to="sans-serif" weight="500" />
     <alias name="sans-serif-black" to="sans-serif" weight="900" />
     <alias name="arial" to="sans-serif" />
     <alias name="helvetica" to="sans-serif" />
@@ -227,6 +244,9 @@
     <family>
         <font weight="400" style="normal">NotoColorEmoji.ttf</font>
     </family>
+    <family>
+        <font weight="400" style="normal">DroidSansFallback.ttf</font>
+    </family>
     <family lang="ja">
         <font weight="400" style="normal">MTLmr3m.ttf</font>
     </family>
diff --git a/data/keyboards/Generic.kl b/data/keyboards/Generic.kl
index cfc1484..f10ba96 100644
--- a/data/keyboards/Generic.kl
+++ b/data/keyboards/Generic.kl
@@ -405,6 +405,7 @@
 # key 504 KEY_BRL_DOT8
 
 key 580   APP_SWITCH
+key 582   VOICE_ASSIST
 
 # Keys defined by HID usages
 key usage 0x0c006F BRIGHTNESS_UP
diff --git a/data/keyboards/Vendor_0a5c_Product_8502.kl b/data/keyboards/Vendor_0a5c_Product_8502.kl
deleted file mode 100644
index 2f07328..0000000
--- a/data/keyboards/Vendor_0a5c_Product_8502.kl
+++ /dev/null
@@ -1,42 +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.
-
-# Rhodi
-
-key 304 BUTTON_A
-key 305 BUTTON_B
-key 307 BUTTON_X
-key 308 BUTTON_Y
-key 310 BUTTON_L1
-key 311 BUTTON_R1
-key 316 BUTTON_MODE
-key 317 BUTTON_THUMBL
-key 318 BUTTON_THUMBR
-
-key 158 BACK
-key 172 HOME
-
-axis 0x00 X
-axis 0x01 Y
-axis 0x02 Z
-axis 0x05 RZ
-axis 0x09 RTRIGGER
-axis 0x0a LTRIGGER
-axis 0x10 HAT_X
-axis 0x11 HAT_Y
-
-led 0x00 CONTROLLER_1
-led 0x01 CONTROLLER_2
-led 0x02 CONTROLLER_3
-led 0x03 CONTROLLER_4
diff --git a/data/sounds/AudioPackage10.mk b/data/sounds/AudioPackage10.mk
index 879e57a..5a5eea6 100644
--- a/data/sounds/AudioPackage10.mk
+++ b/data/sounds/AudioPackage10.mk
@@ -22,16 +22,16 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete_48k.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid_48k.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn_48k.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord_48k.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click_48k.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord_48k.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click_48k.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery_48k.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock_48k.ogg:system/media/audio/ui/Lock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Unlock_48k.ogg:system/media/audio/ui/Unlock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Trusted_48k.ogg:system/media/audio/ui/Trusted.ogg \
-	$(LOCAL_PATH)/effects/ogg/WirelessChargingStarted.ogg:system/media/audio/ui/WirelessChargingStarted.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/WirelessChargingStarted_48k.ogg:system/media/audio/ui/WirelessChargingStarted.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Adara.ogg:system/media/audio/notifications/Adara.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Alya.ogg:system/media/audio/notifications/Alya.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Arcturus.ogg:system/media/audio/notifications/Arcturus.ogg \
diff --git a/data/sounds/AudioPackage11.mk b/data/sounds/AudioPackage11.mk
index 03e205b..0f85b33 100644
--- a/data/sounds/AudioPackage11.mk
+++ b/data/sounds/AudioPackage11.mk
@@ -22,16 +22,16 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete_48k.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid_48k.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn_48k.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord_48k.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click_48k.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord_48k.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click_48k.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery_48k.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock_48k.ogg:system/media/audio/ui/Lock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Unlock_48k.ogg:system/media/audio/ui/Unlock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Trusted_48k.ogg:system/media/audio/ui/Trusted.ogg \
-	$(LOCAL_PATH)/effects/ogg/WirelessChargingStarted.ogg:system/media/audio/ui/WirelessChargingStarted.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/WirelessChargingStarted_48k.ogg:system/media/audio/ui/WirelessChargingStarted.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Adara.ogg:system/media/audio/notifications/Adara.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Alya.ogg:system/media/audio/notifications/Alya.ogg \
 	$(LOCAL_PATH)/notifications/ogg/Arcturus.ogg:system/media/audio/notifications/Arcturus.ogg \
diff --git a/data/sounds/AudioPackage12.mk b/data/sounds/AudioPackage12.mk
index c37c392..4251332 100644
--- a/data/sounds/AudioPackage12.mk
+++ b/data/sounds/AudioPackage12.mk
@@ -12,8 +12,8 @@
 NOTIFICATION_FILES := Ariel Ceres Carme Elara Europa Iapetus Io Rhea Salacia Titan Tethys
 RINGTONE_FILES := Callisto Dione Ganymede Luna Oberon Phobos Sedna Titania Triton Umbriel
 EFFECT_FILES := Effect_Tick KeypressReturn KeypressInvalid KeypressDelete KeypressSpacebar KeypressStandard \
-	VideoRecord camera_click camera_focus LowBattery Dock Undock Lock Unlock WirelessChargingStarted \
-	Trusted
+	camera_focus Dock Undock Lock Unlock Trusted
+MATERIAL_EFFECT_FILES := camera_click VideoRecord LowBattery WirelessChargingStarted
 
 PRODUCT_COPY_FILES += $(foreach fn,$(ALARM_FILES),\
 	$(LOCAL_PATH)/alarms/ogg/$(fn).ogg:system/media/audio/alarms/$(fn).ogg)
@@ -26,3 +26,5 @@
 
 PRODUCT_COPY_FILES += $(foreach fn,$(EFFECT_FILES),\
 	$(LOCAL_PATH)/effects/ogg/$(fn).ogg:system/media/audio/ui/$(fn).ogg)
+PRODUCT_COPY_FILES += $(foreach fn,$(MATERIAL_EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/material/ogg/$(fn).ogg:system/media/audio/ui/$(fn).ogg)
diff --git a/data/sounds/AudioPackage12_48.mk b/data/sounds/AudioPackage12_48.mk
index 2a5efb0..70e68d3 100644
--- a/data/sounds/AudioPackage12_48.mk
+++ b/data/sounds/AudioPackage12_48.mk
@@ -12,7 +12,8 @@
 NOTIFICATION_FILES := Ariel Ceres Carme Elara Europa Iapetus Io Rhea Salacia Titan Tethys
 RINGTONE_FILES := Callisto Dione Ganymede Luna Oberon Phobos Sedna Titania Triton Umbriel
 EFFECT_FILES := Effect_Tick KeypressReturn KeypressInvalid KeypressDelete KeypressSpacebar KeypressStandard \
-	VideoRecord camera_click Lock Unlock Trusted
+	Lock Unlock Trusted
+MATERIAL_EFFECT_FILES := camera_click VideoRecord LowBattery WirelessChargingStarted
 
 # Alarms not yet available in 48 kHz
 PRODUCT_COPY_FILES += $(foreach fn,$(ALARM_FILES),\
@@ -26,11 +27,11 @@
 
 PRODUCT_COPY_FILES += $(foreach fn,$(EFFECT_FILES),\
 	$(LOCAL_PATH)/effects/ogg/$(fn)_48k.ogg:system/media/audio/ui/$(fn).ogg)
+PRODUCT_COPY_FILES += $(foreach fn,$(MATERIAL_EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/material/ogg/$(fn)_48k.ogg:system/media/audio/ui/$(fn).ogg)
 
 # no gold-plated version yet
 PRODUCT_COPY_FILES += \
     $(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-    $(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
-    $(LOCAL_PATH)/effects/ogg/WirelessChargingStarted.ogg:system/media/audio/ui/WirelessChargingStarted.ogg \
     $(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
-    $(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg
\ No newline at end of file
+    $(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg
diff --git a/data/sounds/AudioPackage13.mk b/data/sounds/AudioPackage13.mk
new file mode 100644
index 0000000..cec7280
--- /dev/null
+++ b/data/sounds/AudioPackage13.mk
@@ -0,0 +1,31 @@
+#
+# Audio Package 13 - L
+#
+# Include this file in a product makefile to include these audio files
+#
+#
+
+LOCAL_PATH := frameworks/base/data/sounds
+
+# Simple files that do not require renaming
+ALARM_FILES := Argon Carbon Helium Krypton Neon Oxygen Osmium Platinum Timer
+NOTIFICATION_FILES := Ariel Ceres Carme Elara Europa Iapetus Io Rhea Salacia Titan Tethys
+RINGTONE_FILES := Atria Callisto Dione Ganymede Luna Oberon Phobos Pyxis Sedna Titania Triton \
+	Umbriel
+EFFECT_FILES := Effect_Tick KeypressReturn KeypressInvalid KeypressDelete KeypressSpacebar KeypressStandard \
+	camera_focus Dock Undock Lock Unlock Trusted
+MATERIAL_EFFECT_FILES := camera_click VideoRecord WirelessChargingStarted LowBattery
+
+PRODUCT_COPY_FILES += $(foreach fn,$(ALARM_FILES),\
+	$(LOCAL_PATH)/alarms/material/ogg/$(fn).ogg:system/media/audio/alarms/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(NOTIFICATION_FILES),\
+	$(LOCAL_PATH)/notifications/material/ogg/$(fn).ogg:system/media/audio/notifications/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(RINGTONE_FILES),\
+	$(LOCAL_PATH)/ringtones/material/ogg/$(fn).ogg:system/media/audio/ringtones/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/ogg/$(fn).ogg:system/media/audio/ui/$(fn).ogg)
+PRODUCT_COPY_FILES += $(foreach fn,$(MATERIAL_EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/material/ogg/$(fn).ogg:system/media/audio/ui/$(fn).ogg)
diff --git a/data/sounds/AudioPackage13_48.mk b/data/sounds/AudioPackage13_48.mk
new file mode 100644
index 0000000..d1b17c8
--- /dev/null
+++ b/data/sounds/AudioPackage13_48.mk
@@ -0,0 +1,37 @@
+#
+# Audio Package 13 - L (48kHz)
+#
+# Include this file in a product makefile to include these audio files
+#
+#
+
+LOCAL_PATH := frameworks/base/data/sounds
+
+# Simple files that do not require renaming
+ALARM_FILES := Argon Carbon Helium Krypton Neon Oxygen Osmium Platinum Timer
+NOTIFICATION_FILES := Ariel Ceres Carme Elara Europa Iapetus Io Rhea Salacia Titan Tethys
+RINGTONE_FILES := Atria Callisto Dione Ganymede Luna Oberon Phobos Pyxis Sedna Titania Triton \
+	Umbriel
+EFFECT_FILES := Effect_Tick KeypressReturn KeypressInvalid KeypressDelete KeypressSpacebar KeypressStandard \
+	Lock Unlock Trusted
+MATERIAL_EFFECT_FILES := camera_click VideoRecord WirelessChargingStarted LowBattery
+
+PRODUCT_COPY_FILES += $(foreach fn,$(ALARM_FILES),\
+	$(LOCAL_PATH)/alarms/material/ogg/$(fn)_48k.ogg:system/media/audio/alarms/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(NOTIFICATION_FILES),\
+	$(LOCAL_PATH)/notifications/material/ogg/$(fn)_48k.ogg:system/media/audio/notifications/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(RINGTONE_FILES),\
+	$(LOCAL_PATH)/ringtones/material/ogg/$(fn)_48k.ogg:system/media/audio/ringtones/$(fn).ogg)
+
+PRODUCT_COPY_FILES += $(foreach fn,$(EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/ogg/$(fn)_48k.ogg:system/media/audio/ui/$(fn).ogg)
+PRODUCT_COPY_FILES += $(foreach fn,$(MATERIAL_EFFECT_FILES),\
+	$(LOCAL_PATH)/effects/material/ogg/$(fn)_48k.ogg:system/media/audio/ui/$(fn).ogg)
+
+# no gold-plated version yet
+PRODUCT_COPY_FILES += \
+    $(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
+    $(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
+    $(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg
diff --git a/data/sounds/AudioPackage6.mk b/data/sounds/AudioPackage6.mk
index 3205c0e..c843fdc 100644
--- a/data/sounds/AudioPackage6.mk
+++ b/data/sounds/AudioPackage6.mk
@@ -18,10 +18,10 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock.ogg:system/media/audio/ui/Lock.ogg \
diff --git a/data/sounds/AudioPackage7.mk b/data/sounds/AudioPackage7.mk
index c92c1d0..ce82651 100644
--- a/data/sounds/AudioPackage7.mk
+++ b/data/sounds/AudioPackage7.mk
@@ -20,10 +20,10 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete_120.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid_120.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn_120.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock.ogg:system/media/audio/ui/Lock.ogg \
diff --git a/data/sounds/AudioPackage7alt.mk b/data/sounds/AudioPackage7alt.mk
index 9c35a2e..db468f3 100644
--- a/data/sounds/AudioPackage7alt.mk
+++ b/data/sounds/AudioPackage7alt.mk
@@ -21,7 +21,7 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid_120.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn_120.ogg:system/media/audio/ui/KeypressReturn.ogg \
 	$(LOCAL_PATH)/effects/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
diff --git a/data/sounds/AudioPackage8.mk b/data/sounds/AudioPackage8.mk
index b8be4e3e..4112c18 100644
--- a/data/sounds/AudioPackage8.mk
+++ b/data/sounds/AudioPackage8.mk
@@ -22,10 +22,10 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock.ogg:system/media/audio/ui/Lock.ogg \
diff --git a/data/sounds/AudioPackage9.mk b/data/sounds/AudioPackage9.mk
index 9b761bc..1b430c0 100644
--- a/data/sounds/AudioPackage9.mk
+++ b/data/sounds/AudioPackage9.mk
@@ -22,10 +22,10 @@
 	$(LOCAL_PATH)/effects/ogg/KeypressDelete.ogg:system/media/audio/ui/KeypressDelete.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressInvalid.ogg:system/media/audio/ui/KeypressInvalid.ogg \
 	$(LOCAL_PATH)/effects/ogg/KeypressReturn.ogg:system/media/audio/ui/KeypressReturn.ogg \
-	$(LOCAL_PATH)/effects/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
-	$(LOCAL_PATH)/effects/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/VideoRecord.ogg:system/media/audio/ui/VideoRecord.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/camera_click.ogg:system/media/audio/ui/camera_click.ogg \
 	$(LOCAL_PATH)/effects/ogg/camera_focus.ogg:system/media/audio/ui/camera_focus.ogg \
-	$(LOCAL_PATH)/effects/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
+	$(LOCAL_PATH)/effects/material/ogg/LowBattery.ogg:system/media/audio/ui/LowBattery.ogg \
 	$(LOCAL_PATH)/effects/ogg/Dock.ogg:system/media/audio/ui/Dock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Undock.ogg:system/media/audio/ui/Undock.ogg \
 	$(LOCAL_PATH)/effects/ogg/Lock.ogg:system/media/audio/ui/Lock.ogg \
diff --git a/data/sounds/alarms/material/ogg/Argon.ogg b/data/sounds/alarms/material/ogg/Argon.ogg
new file mode 100644
index 0000000..87ecfeb
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Argon.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Argon_48k.ogg b/data/sounds/alarms/material/ogg/Argon_48k.ogg
new file mode 100644
index 0000000..7ca6faa
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Argon_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Carbon.ogg b/data/sounds/alarms/material/ogg/Carbon.ogg
new file mode 100644
index 0000000..0d96853f
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Carbon.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Carbon_48k.ogg b/data/sounds/alarms/material/ogg/Carbon_48k.ogg
new file mode 100644
index 0000000..133fcb5
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Carbon_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Helium.ogg b/data/sounds/alarms/material/ogg/Helium.ogg
new file mode 100644
index 0000000..d381448
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Helium.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Helium_48k.ogg b/data/sounds/alarms/material/ogg/Helium_48k.ogg
new file mode 100644
index 0000000..a53fbb8
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Helium_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Krypton.ogg b/data/sounds/alarms/material/ogg/Krypton.ogg
new file mode 100644
index 0000000..4529aa8
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Krypton.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Krypton_48k.ogg b/data/sounds/alarms/material/ogg/Krypton_48k.ogg
new file mode 100644
index 0000000..ac8781d
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Krypton_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Neon.ogg b/data/sounds/alarms/material/ogg/Neon.ogg
new file mode 100644
index 0000000..61582d5
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Neon.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Neon_48k.ogg b/data/sounds/alarms/material/ogg/Neon_48k.ogg
new file mode 100644
index 0000000..0f0ff03
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Neon_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Osmium.ogg b/data/sounds/alarms/material/ogg/Osmium.ogg
new file mode 100644
index 0000000..245c4ce
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Osmium.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Osmium_48k.ogg b/data/sounds/alarms/material/ogg/Osmium_48k.ogg
new file mode 100644
index 0000000..b8abc3a
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Osmium_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Oxygen.ogg b/data/sounds/alarms/material/ogg/Oxygen.ogg
new file mode 100644
index 0000000..0b489bd
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Oxygen.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Oxygen_48k.ogg b/data/sounds/alarms/material/ogg/Oxygen_48k.ogg
new file mode 100644
index 0000000..0fdeab6
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Oxygen_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Platinum.ogg b/data/sounds/alarms/material/ogg/Platinum.ogg
new file mode 100644
index 0000000..053b008
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Platinum.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Platinum_48k.ogg b/data/sounds/alarms/material/ogg/Platinum_48k.ogg
new file mode 100644
index 0000000..2107172
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Platinum_48k.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Timer.ogg b/data/sounds/alarms/material/ogg/Timer.ogg
new file mode 100644
index 0000000..97519aa
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Timer.ogg
Binary files differ
diff --git a/data/sounds/alarms/material/ogg/Timer_48k.ogg b/data/sounds/alarms/material/ogg/Timer_48k.ogg
new file mode 100644
index 0000000..bd30280
--- /dev/null
+++ b/data/sounds/alarms/material/ogg/Timer_48k.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/LowBattery.ogg b/data/sounds/effects/material/ogg/LowBattery.ogg
new file mode 100644
index 0000000..9dbce2b
--- /dev/null
+++ b/data/sounds/effects/material/ogg/LowBattery.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/LowBattery_48k.ogg b/data/sounds/effects/material/ogg/LowBattery_48k.ogg
new file mode 100644
index 0000000..f60f2b1
--- /dev/null
+++ b/data/sounds/effects/material/ogg/LowBattery_48k.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/VideoRecord.ogg b/data/sounds/effects/material/ogg/VideoRecord.ogg
new file mode 100644
index 0000000..e98fabc
--- /dev/null
+++ b/data/sounds/effects/material/ogg/VideoRecord.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/VideoRecord_48k.ogg b/data/sounds/effects/material/ogg/VideoRecord_48k.ogg
new file mode 100644
index 0000000..b1eb780
--- /dev/null
+++ b/data/sounds/effects/material/ogg/VideoRecord_48k.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/WirelessChargingStarted.ogg b/data/sounds/effects/material/ogg/WirelessChargingStarted.ogg
new file mode 100644
index 0000000..db5d2cb
--- /dev/null
+++ b/data/sounds/effects/material/ogg/WirelessChargingStarted.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/WirelessChargingStarted_48k.ogg b/data/sounds/effects/material/ogg/WirelessChargingStarted_48k.ogg
new file mode 100644
index 0000000..adacd47
--- /dev/null
+++ b/data/sounds/effects/material/ogg/WirelessChargingStarted_48k.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/camera_click.ogg b/data/sounds/effects/material/ogg/camera_click.ogg
new file mode 100644
index 0000000..2528ef6
--- /dev/null
+++ b/data/sounds/effects/material/ogg/camera_click.ogg
Binary files differ
diff --git a/data/sounds/effects/material/ogg/camera_click_48k.ogg b/data/sounds/effects/material/ogg/camera_click_48k.ogg
new file mode 100644
index 0000000..01f3a05
--- /dev/null
+++ b/data/sounds/effects/material/ogg/camera_click_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Ariel.ogg b/data/sounds/notifications/material/ogg/Ariel.ogg
new file mode 100644
index 0000000..ff17500
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Ariel.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Ariel_48k.ogg b/data/sounds/notifications/material/ogg/Ariel_48k.ogg
new file mode 100644
index 0000000..b138284
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Ariel_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Carme.ogg b/data/sounds/notifications/material/ogg/Carme.ogg
new file mode 100644
index 0000000..ec6e7cb
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Carme.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Carme_48k.ogg b/data/sounds/notifications/material/ogg/Carme_48k.ogg
new file mode 100644
index 0000000..2be9332
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Carme_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Ceres.ogg b/data/sounds/notifications/material/ogg/Ceres.ogg
new file mode 100644
index 0000000..f7386a7
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Ceres.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Ceres_48k.ogg b/data/sounds/notifications/material/ogg/Ceres_48k.ogg
new file mode 100644
index 0000000..0ffba07
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Ceres_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Elara.ogg b/data/sounds/notifications/material/ogg/Elara.ogg
new file mode 100644
index 0000000..e4dcf28
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Elara.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Elara_48k.ogg b/data/sounds/notifications/material/ogg/Elara_48k.ogg
new file mode 100644
index 0000000..2891de6
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Elara_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Europa.ogg b/data/sounds/notifications/material/ogg/Europa.ogg
new file mode 100644
index 0000000..ce94e21
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Europa.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Europa_48k.ogg b/data/sounds/notifications/material/ogg/Europa_48k.ogg
new file mode 100644
index 0000000..45c5f0a
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Europa_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Iapetus.ogg b/data/sounds/notifications/material/ogg/Iapetus.ogg
new file mode 100644
index 0000000..d7c810d
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Iapetus.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Iapetus_48k.ogg b/data/sounds/notifications/material/ogg/Iapetus_48k.ogg
new file mode 100644
index 0000000..8b9703e
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Iapetus_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Io.ogg b/data/sounds/notifications/material/ogg/Io.ogg
new file mode 100644
index 0000000..e05a529
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Io.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Io_48k.ogg b/data/sounds/notifications/material/ogg/Io_48k.ogg
new file mode 100644
index 0000000..599b3fc
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Io_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Rhea.ogg b/data/sounds/notifications/material/ogg/Rhea.ogg
new file mode 100644
index 0000000..347c38d
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Rhea.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Rhea_48k.ogg b/data/sounds/notifications/material/ogg/Rhea_48k.ogg
new file mode 100644
index 0000000..1de91de
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Rhea_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Salacia.ogg b/data/sounds/notifications/material/ogg/Salacia.ogg
new file mode 100644
index 0000000..ea83b5b
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Salacia.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Salacia_48k.ogg b/data/sounds/notifications/material/ogg/Salacia_48k.ogg
new file mode 100644
index 0000000..dba0416
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Salacia_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Tethys.ogg b/data/sounds/notifications/material/ogg/Tethys.ogg
new file mode 100644
index 0000000..fc61f70
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Tethys.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Tethys_48k.ogg b/data/sounds/notifications/material/ogg/Tethys_48k.ogg
new file mode 100644
index 0000000..b2ab648
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Tethys_48k.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Titan.ogg b/data/sounds/notifications/material/ogg/Titan.ogg
new file mode 100644
index 0000000..0e54844
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Titan.ogg
Binary files differ
diff --git a/data/sounds/notifications/material/ogg/Titan_48k.ogg b/data/sounds/notifications/material/ogg/Titan_48k.ogg
new file mode 100644
index 0000000..4c4af31
--- /dev/null
+++ b/data/sounds/notifications/material/ogg/Titan_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Atria.ogg b/data/sounds/ringtones/material/ogg/Atria.ogg
new file mode 100644
index 0000000..173f73d
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Atria.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Atria_48k.ogg b/data/sounds/ringtones/material/ogg/Atria_48k.ogg
new file mode 100644
index 0000000..c98a437
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Atria_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Callisto.ogg b/data/sounds/ringtones/material/ogg/Callisto.ogg
new file mode 100644
index 0000000..dd9bc5b
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Callisto.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Callisto_48k.ogg b/data/sounds/ringtones/material/ogg/Callisto_48k.ogg
new file mode 100644
index 0000000..44855dc
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Callisto_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Dione.ogg b/data/sounds/ringtones/material/ogg/Dione.ogg
new file mode 100644
index 0000000..cf7d1cb
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Dione.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Dione_48k.ogg b/data/sounds/ringtones/material/ogg/Dione_48k.ogg
new file mode 100644
index 0000000..8abbf98
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Dione_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Ganymede.ogg b/data/sounds/ringtones/material/ogg/Ganymede.ogg
new file mode 100644
index 0000000..e7ff9f4
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Ganymede.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Ganymede_48k.ogg b/data/sounds/ringtones/material/ogg/Ganymede_48k.ogg
new file mode 100644
index 0000000..1ce7d33
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Ganymede_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Luna.ogg b/data/sounds/ringtones/material/ogg/Luna.ogg
new file mode 100644
index 0000000..8aeb3a0
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Luna.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Luna_48k.ogg b/data/sounds/ringtones/material/ogg/Luna_48k.ogg
new file mode 100644
index 0000000..a2f7f49
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Luna_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Oberon.ogg b/data/sounds/ringtones/material/ogg/Oberon.ogg
new file mode 100644
index 0000000..145f474
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Oberon.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Oberon_48k.ogg b/data/sounds/ringtones/material/ogg/Oberon_48k.ogg
new file mode 100644
index 0000000..7f2e274
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Oberon_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Phobos.ogg b/data/sounds/ringtones/material/ogg/Phobos.ogg
new file mode 100644
index 0000000..5e312d2
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Phobos.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Phobos_48k.ogg b/data/sounds/ringtones/material/ogg/Phobos_48k.ogg
new file mode 100644
index 0000000..cd02cbc
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Phobos_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Pyxis.ogg b/data/sounds/ringtones/material/ogg/Pyxis.ogg
new file mode 100644
index 0000000..4786b18
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Pyxis.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Pyxis_48k.ogg b/data/sounds/ringtones/material/ogg/Pyxis_48k.ogg
new file mode 100644
index 0000000..6b39351
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Pyxis_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Sedna.ogg b/data/sounds/ringtones/material/ogg/Sedna.ogg
new file mode 100644
index 0000000..ff889e6
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Sedna.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Sedna_48k.ogg b/data/sounds/ringtones/material/ogg/Sedna_48k.ogg
new file mode 100644
index 0000000..68bc35e
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Sedna_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Titania.ogg b/data/sounds/ringtones/material/ogg/Titania.ogg
new file mode 100644
index 0000000..87a05ee
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Titania.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Titania_48k.ogg b/data/sounds/ringtones/material/ogg/Titania_48k.ogg
new file mode 100644
index 0000000..ebf8f32
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Titania_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Triton.ogg b/data/sounds/ringtones/material/ogg/Triton.ogg
new file mode 100644
index 0000000..b5893bd
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Triton.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Triton_48k.ogg b/data/sounds/ringtones/material/ogg/Triton_48k.ogg
new file mode 100644
index 0000000..e44d01e
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Triton_48k.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Umbriel.ogg b/data/sounds/ringtones/material/ogg/Umbriel.ogg
new file mode 100644
index 0000000..193e566
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Umbriel.ogg
Binary files differ
diff --git a/data/sounds/ringtones/material/ogg/Umbriel_48k.ogg b/data/sounds/ringtones/material/ogg/Umbriel_48k.ogg
new file mode 100644
index 0000000..583a1d7
--- /dev/null
+++ b/data/sounds/ringtones/material/ogg/Umbriel_48k.ogg
Binary files differ
diff --git a/docs/html/_redirects.yaml b/docs/html/_redirects.yaml
index c5b6c24..1e32d43 100644
--- a/docs/html/_redirects.yaml
+++ b/docs/html/_redirects.yaml
@@ -1,3 +1,10 @@
+# WARNING: THIS FILE IS NOT USED IN PRODUCTION
+# CHANGES MADE HERE **DO NOT EFFECT** developer.android.com
+
+# Instead, update the following file in the current docs release branch:
+# <docs-release-branch>/vendor/google/docs/app-engine-server/v3/redirects.yaml
+
+#=============================================================================
 # Redirects file.
 # This file contains the list of rewrite rules that are applied when serving
 # pages. Add "pattern: True" to use python regex in to or from.
@@ -59,6 +66,9 @@
 - from: /guide/google/gcm/server-javadoc/...
   to: /reference/com/google/android/gcm/server/package-summary.html
 
+- from: /google/play-services/auth.html
+  to: /google/auth/http-auth.html
+
 - from: /guide/google/play/services.html
   to: /google/play-services/index.html
 
diff --git a/docs/html/about/dashboards/index.jd b/docs/html/about/dashboards/index.jd
index 1e5fc4d..808f04a 100644
--- a/docs/html/about/dashboards/index.jd
+++ b/docs/html/about/dashboards/index.jd
@@ -64,7 +64,7 @@
 </div>
 
 
-<p style="clear:both"><em>Data collected during a 7-day period ending on August 12, 2014.
+<p style="clear:both"><em>Data collected during a 7-day period ending on September 9, 2014.
 <br/>Any versions with less than 0.1% distribution are not shown.</em>
 </p>
 
@@ -95,7 +95,8 @@
 </div>
 
 
-<p style="clear:both"><em>Data collected during a 7-day period ending on August 12, 2014.
+<p style="clear:both"><em>Data collected during a 7-day period ending on September 9, 2014.
+
 <br/>Any screen configurations with less than 0.1% distribution are not shown.</em></p>
 
 
@@ -114,7 +115,7 @@
 
 
 <img alt="" style="float:right"
-src="//chart.googleapis.com/chart?chs=400x250&cht=p&chd=t%3A0.1%2C80.2%2C19.7&chf=bg%2Cs%2C00000000&chl=GL%201.1%20only%7CGL%202.0%7CGL%203.0&chco=c4df9b%2C6fad0c" />
+src="//chart.googleapis.com/chart?chs=400x250&cht=p&chd=t%3A77.5%2C22.5&chf=bg%2Cs%2C00000000&chl=GL%202.0%7CGL%203.0&chco=c4df9b%2C6fad0c" />
 
 <p>To declare which version of OpenGL ES your application requires, you should use the {@code
 android:glEsVersion} attribute of the <a
@@ -131,22 +132,18 @@
 <th scope="col">Distribution</th>
 </tr>
 <tr>
-<td>1.1 only</th>
-<td>0.1%</td>
+<td>2.0</td>
+<td>77.5%</td>
 </tr>
 <tr>
-<td>2.0</th>
-<td>80.2%</td>
-</tr>
-<tr>
-<td>3.0</th>
-<td>19.7%</td>
+<td>3.0</td>
+<td>22.5%</td>
 </tr>
 </table>
 
 
 
-<p style="clear:both"><em>Data collected during a 7-day period ending on August 12, 2014</em></p>
+<p style="clear:both"><em>Data collected during a 7-day period ending on September 9, 2014</em></p>
 
 
 
@@ -164,7 +161,7 @@
 var VERSION_DATA =
 [
   {
-    "chart": "//chart.googleapis.com/chart?cht=p&chs=500x250&chl=Froyo%7CGingerbread%7CIce%20Cream%20Sandwich%7CJelly%20Bean%7CKitKat&chd=t%3A0.7%2C13.6%2C10.6%2C54.2%2C20.9&chf=bg%2Cs%2C00000000&chco=c4df9b%2C6fad0c",
+    "chart": "//chart.googleapis.com/chart?chco=c4df9b%2C6fad0c&cht=p&chs=500x250&chl=Froyo%7CGingerbread%7CIce%20Cream%20Sandwich%7CJelly%20Bean%7CKitKat&chd=t%3A0.7%2C11.4%2C9.6%2C53.8%2C24.5&chf=bg%2Cs%2C00000000",
     "data": [
       {
         "api": 8,
@@ -174,41 +171,38 @@
       {
         "api": 10,
         "name": "Gingerbread",
-        "perc": "13.6"
+        "perc": "11.4"
       },
       {
         "api": 15,
         "name": "Ice Cream Sandwich",
-        "perc": "10.6"
+        "perc": "9.6"
       },
       {
         "api": 16,
         "name": "Jelly Bean",
-        "perc": "26.5"
+        "perc": "25.1"
       },
       {
         "api": 17,
         "name": "Jelly Bean",
-        "perc": "19.8"
+        "perc": "20.7"
       },
       {
         "api": 18,
         "name": "Jelly Bean",
-        "perc": "7.9"
+        "perc": "8.0"
       },
       {
         "api": 19,
         "name": "KitKat",
-        "perc": "20.9"
+        "perc": "24.5"
       }
     ]
   }
 ];
 
 
-
-
-
 var SCREEN_DATA =
 [
   {
@@ -216,27 +210,27 @@
       "Large": {
         "hdpi": "0.6",
         "ldpi": "0.5",
-        "mdpi": "4.2",
-        "tvdpi": "1.6",
-        "xhdpi": "0.5"
+        "mdpi": "4.3",
+        "tvdpi": "1.7",
+        "xhdpi": "0.6"
       },
       "Normal": {
-        "hdpi": "35.5",
-        "mdpi": "11.8",
-        "xhdpi": "18.4",
-        "xxhdpi": "15.2"
+        "hdpi": "35.7",
+        "mdpi": "10.6",
+        "xhdpi": "19.2",
+        "xxhdpi": "16.2"
       },
       "Small": {
-        "ldpi": "7.4"
+        "ldpi": "6.2"
       },
       "Xlarge": {
         "hdpi": "0.3",
-        "mdpi": "3.6",
+        "mdpi": "3.7",
         "xhdpi": "0.4"
       }
     },
-    "densitychart": "//chart.googleapis.com/chart?cht=p&chs=400x250&chl=ldpi%7Cmdpi%7Ctvdpi%7Chdpi%7Cxhdpi%7Cxxhdpi&chd=t%3A7.9%2C19.6%2C1.6%2C36.4%2C19.3%2C15.2&chf=bg%2Cs%2C00000000&chco=c4df9b%2C6fad0c",
-    "layoutchart": "//chart.googleapis.com/chart?cht=p&chs=400x250&chl=Xlarge%7CLarge%7CNormal%7CSmall&chd=t%3A4.3%2C7.4%2C80.9%2C7.4&chf=bg%2Cs%2C00000000&chco=c4df9b%2C6fad0c"
+    "densitychart": "//chart.googleapis.com/chart?chco=c4df9b%2C6fad0c&cht=p&chs=400x250&chl=ldpi%7Cmdpi%7Ctvdpi%7Chdpi%7Cxhdpi%7Cxxhdpi&chd=t%3A6.7%2C18.6%2C1.7%2C36.6%2C20.2%2C16.2&chf=bg%2Cs%2C00000000",
+    "layoutchart": "//chart.googleapis.com/chart?chco=c4df9b%2C6fad0c&cht=p&chs=400x250&chl=Xlarge%7CLarge%7CNormal%7CSmall&chd=t%3A4.4%2C7.7%2C81.7%2C6.2&chf=bg%2Cs%2C00000000"
   }
 ];
 
diff --git a/docs/html/design/style/iconography.jd b/docs/html/design/style/iconography.jd
index d8d8c76..e5161f4 100644
--- a/docs/html/design/style/iconography.jd
+++ b/docs/html/design/style/iconography.jd
@@ -29,7 +29,7 @@
 scaling ratio</strong> between the five primary densities (medium, high, x-high, xx-high, and
 xxx-high respectively). For example, consider that the size for a launcher icon is specified to be
 48x48 dp. This means the baseline (MDPI) asset is 48x48 px, and the
-high density (HDPI) asset should be 1.5x the baseline at 72x72 px, and the x-high
+high-density(HDPI) asset should be 1.5x the baseline at 72x72 px, and the x-high
 density (XHDPI) asset should be 2x the baseline at 96x96 px, and so on.</p>
 
 <p class="note"><strong>Note:</strong> Android also supports low-density (LDPI) screens,
@@ -489,11 +489,12 @@
     xhdpi/...
         _pre_production/...
             <em>working_file</em>.psd
-        <em>finished_asset</em>.png</pre>
+        <em>finished_asset</em>.png
     xxhdpi/...
         _pre_production/...
             <em>working_file</em>.psd
-        <em>finished_asset</em>.png</pre>
+        <em>finished_asset</em>.png
+</pre>
 
 <p>Because the structure in your working space is similar to that of the application, you
 can quickly determine which assets should be copied to each
@@ -513,6 +514,8 @@
         <em>finished_asset</em>.png
     drawable-xhdpi/...
         <em>finished_asset</em>.png
+    drawable-xxhdpi/...
+        <em>finished_asset</em>.png
 </pre>
 
 <p>For more information about how to save resources in the application project,
@@ -520,6 +523,21 @@
 </p>
 
 
+<h3 id="xxxhdpi-launcher">Provide an xxx-high-density launcher icon</h3>
+
+<p>Some devices scale-up the launcher icon by as much as 25%. For example, if your highest density 
+launcher icon image is already extra-extra-high density, the scaling process will make it appear
+less crisp. So you should provide a higher density launcher icon in the <code>drawable-xxxhdpi
+</code> directory, which the system uses instead of scaling up a smaller version of the icon.</p>
+
+<p class="note"><strong>Note:</strong> the <code>drawable-xxxhdpi</code> qualifier is necessary only
+to provide a launcher icon that can appear larger than usual on an xxhdpi device. You do not need to
+provide xxxhdpi assets for all your app's images.</p>
+
+<p>See <a href="{@docRoot}guide/practices/screens_support.html">Supporting Multiple Screens</a> for
+more information.</p>
+
+
 <h3>Remove unnecessary metadata from final assets</h3>
 
 <p>Although the Android SDK tools will automatically compress PNGs when packaging
diff --git a/docs/html/distribute/googleplay/edu/start.jd b/docs/html/distribute/googleplay/edu/start.jd
index 067a15f..3c3a175 100644
--- a/docs/html/distribute/googleplay/edu/start.jd
+++ b/docs/html/distribute/googleplay/edu/start.jd
@@ -9,27 +9,23 @@
 <div id="qv-wrapper"><div id="qv">
 <h2>Steps to Join</h2>
 <ol>
-<li><a href="#register">Register for a Publisher Account</li>
+<li><a href="#register">Register for a Publisher Account</a></li>
 <li><a href="#prepare">Prepare Your Apps</a></li>
 <li><a href="#publish">Publish Your Apps</a></li>
 <li><a href="#related-resources">Related Resources</a></li>
 </ol>
 </div></div>
 <p>
-  If you've got great Android apps for education and want to reach even more teachers
+  If you've got great Android and Chrome apps for education and want to reach even more teachers
   and students, you can join the <strong>Google Play for Education</strong>
   program in a few simple steps. You do everything using the familiar tools and
-  processes in Google Play.
+  processes you currently use to manage your Android or Chrome apps.
 </p>
 
 <p>
 Note that Google Play for Education is currently available to <strong>K-12 schools in the United
 States</strong> only.</p>
 
-<p>If you have an educational Chrome app instead of an Android app, you can learn more about
-Chrome Apps in Google Play for Education at <a href=
-"https://developers.google.com/edu">developers.google.com/edu</a>.
-</p>
 
 <img src="{@docRoot}images/gpfe-start-0.jpg" style=
   "border:1px solid #ddd;padding:0px" width="760" height="403">
@@ -43,23 +39,20 @@
 </div>
 
 <p>
-  If you’re new to Google Play, review the information on <a href=
+  To publish an Android app in Google Play for Education, review the information on <a href=
   "{@docRoot}distribute/googleplay/start.html">getting started</a> with
   publishing on Google Play. You’ll gain access to the <a href=
   "{@docRoot}distribute/googleplay/developer-console.html">Developer
   Console</a>, where you’ll manage your details, apps, and payments.
 </p>
 
+<p>To publish a Chrome app in Google Play for Education, you'll need a
+<a href="https://developer.chrome.com/webstore/publish">Chrome Web Store account</a>.</p>
+
 <div class="headerLine">
   <h2 id="prepare">
     Prepare Your Apps
   </h2>
-
-
-</div>
-
-<div class="figure-right">
-  <img src="{@docRoot}images/gp-edu-process.png">
 </div>
 
 <p>
@@ -77,13 +70,13 @@
   To prepare for a launch on Google Play for Education, start by reviewing the
   guidelines for educational apps in Google Play and the policies that apply to
   your apps. See the <a href=
-  "{@docRoot}distribute/essentials/gpfe-guidelines.html">Education
+  "https://developers.google.com/edu/guidelines">Education
   Guidelines</a> for details.
 </p>
 
 <p>
   Also, make sure that you're familiar with the policies that your app must
-  comply with, including <a href=
+  comply with. For Android, they include <a href=
   "http://play.google.com/about/developer-content-policy.html">content
   policies</a>, the <a href=
   "http://play.google.com/about/developer-distribution-agreement.html">Developer
@@ -91,6 +84,14 @@
   "https://play.google.com/about/developer-distribution-agreement-addendum.html">
   Google Play for Education Addendum</a>.
 </p>
+<p>For Chrome, they include <a href=
+  "https://developer.chrome.com/webstore/program_policies">content
+  policies</a>, the <a href=
+  "https://developer.chrome.com/webstore/terms">Developer
+  Distribution Agreement</a>, and <a href=
+  "https://developers.google.com/edu/chrome-d-d-a-addendum">
+  Google Play for Education Addendum</a>.
+</p>
 
 <h3>
   Design and develop a great app for education
@@ -105,7 +106,7 @@
 
 <p>
   Assess your app against the criteria listed in the <a href=
-  "{@docRoot}distribute/essentials/gpfe-guidelines.html">Education
+  "https://developers.google.com/edu/guidelines">Education
   Guidelines</a> and plan on supporting them to the greatest extent possible.
   In some cases you might need to modify the app’s features or UI to support
   classroom requirements. It's a good idea to identify any changes early in
@@ -113,7 +114,7 @@
 </p>
 
 <p>
-  With Google Play for Education, optimizing your apps for tablets is crucial.
+  With Google Play for Education, optimizing your Android apps for tablets is crucial.
   A variety of resources are available to help you understand what you need to
   do — a good starting point is the <a href=
   "{@docRoot}distribute/essentials/quality/tablets.html">Tablet App Quality</a>
@@ -132,6 +133,11 @@
 </p>
 
 <p>
+For Chrome apps, optimizing your apps for mouse, keyboard, and touch is just as important.
+Some students will use touch as their primary input method, and some will have Chromebooks
+without touch. Make sure your app works for all students.
+</p>
+<p>
   Comprehensive testing and quality assurance are key aspects of delivering
   great apps for teachers and students. Make sure you set up a <a href=
   "{@docRoot}distribute/essentials/gpfe-guidelines.html#test-environment">proper
@@ -160,15 +166,13 @@
     apps.
   </li>
 
-  <li>Publish your apps in the Developer Console as normal, but opt-in to
+  <li>Publish your apps in the Developer Console (for Android apps) or the Chrome Web Store
+  (for Chrome apps) as normal, but opt-in to
   Google Play for Education.
   </li>
 </ul>
 
-<h3 id="opt-in">
-  Opt-in to Google Play for Education and publish
-</h3>
-
+<h3>Opt-in to Google Play for Education and publish Android apps</h3>
 <p>
   Once you've built your release-ready APK upload it to the Developer Console,
   create your store listing, and set distribution options. If you aren't
@@ -231,7 +235,7 @@
   will be shown to educators when they are browsing your app.
   </li>
 
-  <li>Click <strong>Save</strong>f to save your Pricing and Distribution
+  <li>Click <strong>Save</strong> to save your Pricing and Distribution
   changes.
   </li>
 </ol>
@@ -247,58 +251,55 @@
 </div>
 
 <p>
-  Once you save changes and publish your app, the app will be submitted to our
-  third-party educator network for review and approval. If the app is already
-  published, it will be submitted for review as soon as you opt-in and save
-  your changes.
+  Once you save changes and publish your app, the app will be available on Google Play for
+  Education. We may submit your app to our
+  third-party educator network for additional review and to be featured and badged as
+  Educator-approved.
 </p>
 
 <p class="note">
   <strong>Note</strong>: Google Play for Education is part of Google Play. When
-  you publish an app that's opted-in to Google Play for Education, the app
-  becomes available to users in Google Play right away. After the app is
-  <a href="{@docRoot}distribute/essentials/gpfe-guidelines.html#e-value">review
-  and approval</a>, it then becomes available to educators in Google Play for
-  Education.
+  you publish an Android app that's opted-in to Google Play for Education, the app
+  becomes available to users in Google Play.
 </p>
 
-<h3>
-  Track your review and approval
-</h3>
-
+<h3>Opt-in to Google Play for Education and publish Chrome apps</h3>
 <p>
-  As soon as you opt-in to Google Play for Education and publish, your apps are
-  queued for review by our third-party educator network. The review and
-  approval process can take four weeks or more. You'll receive notification by
-  email (to your developer account address) when the review is complete, with a
-  summary of the review results.
+Once you've uploaded your app or extension to the Developer Dashboard, create your store listing
+and set distribution options.
 </p>
-
 <p>
-  At any time, you can check the review and approval status of your app in the
-  Developer Console, under "Google Play for Education" in the app's Pricing and
-  Distribution page. There are three approval states:
+When your apps are ready to publish, you opt-in to Google Play for Education directly from the
+<a href="https://chrome.google.com/webstore/developer/dashboard">Developer Dashboard</a>.
+Opt-in means that you want your apps to be made available to educators
+through Google Play for Education, including review, classification, and approval by our
+third-party educator network.
+</p>
+<p>
+Opt-in also confirms that your app complies with
+<a href="https://developer.chrome.com/webstore/program_policies">Chrome Web Store Program Policies</a>
+and the <a href="https://developer.chrome.com/webstore/terms">Terms of Service</a>, including a
+<a href="https://developers.google.com/edu/chrome-d-d-a-addendum">Google Play for Education Addendum</a>.
+If you are not familiar with these
+policy documents or the Addendum, make sure to read them before opting-in.
 </p>
 
-<ul>
-  <li>
-    <em>Pending</em> &mdash; Your app was sent for review and the review isn't
-    yet complete.
-  </li>
+<p>Here's how to opt-in to Google Play for Education for a specific app or extension:</p>
+<ol>
+<li>In the Developer Dashboard, click <b>Edit</b> on the app you want to opt-in.</li>
+<li>Scroll down to <b>Google Play for Education</b> and review the additional
+Developer Terms and Conditions.</li>
+<li>Select the checkbox to opt-in to include this item in Google Play for Education.</li>
+<li>Click <b>Publish Changes</b> to save your changes and submit your application.
+Once you save changes and publish your app, the app will be available on Google Play for Education.
+We may submit your app to our third-party educator network for additional review, and to be
+featured and badged as Educator-approved.</li>
+<p class="note"><b>Note:</b>
+When you publish an app that's opted-in to Google Play for Education,
+the app becomes available to users in the Chrome Web Store.
+</p>
+</ol>
 
-  <li>
-    <em>Approved</em> &mdash; Your app was reviewed and approved. The app will
-    be made available directly to educators through Google Play for Education.
-    Once your app is approved, you can update it at your convenience without
-    needing another full review.
-  </li>
-
-  <li>
-    <em>Not approved</em> &mdash; Your app was reviewed and not approved. Check
-    the notification email send for information about why the app wasn’t
-    approved. You can address any issues and opt-in again for another review.
-  </li>
-</ul>
 <div class="headerLine">
 <h2 id="related-resources">Related Resources</h2>
 </div>
diff --git a/docs/html/google/auth/http-auth.jd b/docs/html/google/auth/http-auth.jd
index 3b2a83f..804ba12 100644
--- a/docs/html/google/auth/http-auth.jd
+++ b/docs/html/google/auth/http-auth.jd
@@ -342,9 +342,9 @@
 "{@docRoot}reference/com/google/android/gms/auth/GoogleAuthUtil.html#getToken(android.content.Context,%20java.lang.String,%20java.lang.String)">
 {@code GoogleAuthUtil.getToken()}</a>, you must provide the app {@link android.content.Context},
 the account name retrieved from the account picker, and the scope for your auth
-token request. The above sample code (and the attached sample) defines these arguments with
-class members that the host activity passes to
-the {@link android.os.AsyncTask} class constructor.</p>
+token request. The above sample code (and the attached sample) defines these
+arguments with class members that the host activity passes to the {@link android.os.AsyncTask} class constructor. For more information about setting the scope, see
+the <a href="#SpecifyingScopes">Specifying Scopes</a> section below. </p>
 
 <p class="note"><strong>Note:</strong>
 As shown by the {@code fetchToken()} method above, you must handle
@@ -397,8 +397,32 @@
 "{@docRoot}reference/com/google/android/gms/auth/GoogleAuthUtil.html#getToken(android.content.Context,%20java.lang.String,%20java.lang.String)">
 {@code GoogleAuthUtil.getToken()}</a>.</p>
 
-
-
+<h3 id="SpecifyingScopes">Specifying scopes</h3>
+<p>The scope string is used to specify which Google services can be accessed by
+  an app using the requested auth token. An auth token can be associated with
+  multiple scopes.</p>
+<p>When specifying the scopes in your auth token request, prefix the
+  scope string with {@code "oauth2:"} followed by a list of one or more OAuth scope
+  values. Use a space to separate each scope value in the list. To see a list of
+  valid OAuth scope values for Google services, browse
+  the <a href="https://developers.google.com/oauthplayground/"
+  class="external-link">OAuth 2.0 Playground</a>.</p>
+<p class="note"><strong>Tip:</strong> Specify {@code "oauth2:&lt;scope&gt;"}
+  for a single scope. Specify
+  {@code "oauth2:&lt;scope1&gt; &lt;scope2&gt; &lt;scopeN&gt;"} for multiple
+  scopes (using a space to separate each scope).</p>
+<p>For example, to access the Google Books API, the scope is
+  {@code "oauth2:https://www.googleapis.com/auth/books"}. To add an additional
+  scope, say for Google+ login, your code might look like this:</p>
+<pre>
+private final static String BOOKS_API_SCOPE
+        = "https://www.googleapis.com/auth/books";
+private fina; static String GPLUS_SCOPE
+        = "https://www.googleapis.com/auth/plus.login";
+private final static String mScopes
+        = "oauth2:" + BOOKS_API_SCOPE + " " + GPLUS_SCOPE;
+String token = GoogleAuthUtil.getToken(mActivity, mEmail, mScopes);
+</pre>
 
 <h2 id="HandleExceptions">Handle Exceptions</h2>
 
diff --git a/docs/html/google/play-services/setup.jd b/docs/html/google/play-services/setup.jd
index ebd3694..d7e449b 100644
--- a/docs/html/google/play-services/setup.jd
+++ b/docs/html/google/play-services/setup.jd
@@ -66,8 +66,8 @@
 ...
 
 dependencies {
-    compile 'com.android.support:appcompat-v7:+'
-    <strong>compile 'com.google.android.gms:play-services:5.0.77'</strong>
+    compile 'com.android.support:appcompat-v7:20.+'
+    <strong>compile 'com.google.android.gms:play-services:5.+'</strong>
 }
 </pre>
 <p>Be sure you update this version number each time Google Play services is updated.</p>
diff --git a/docs/html/google/play/billing/api.jd b/docs/html/google/play/billing/api.jd
index 3d46715..bc710f9 100644
--- a/docs/html/google/play/billing/api.jd
+++ b/docs/html/google/play/billing/api.jd
@@ -1,6 +1,7 @@
-page.title=In-app Billing Version 3
+page.title=In-app Billing API
 parent.title=In-app Billing
 parent.link=index.html
+page.tags="billing, inapp, iap"
 @jd:body
 
 <div id="qv-wrapper">
diff --git a/docs/html/google/play/billing/billing_integrate.jd b/docs/html/google/play/billing/billing_integrate.jd
index dba43cd..052cf75 100644
--- a/docs/html/google/play/billing/billing_integrate.jd
+++ b/docs/html/google/play/billing/billing_integrate.jd
@@ -1,6 +1,7 @@
-page.title=Implementing In-app Billing <span style="font-size:16px;">(IAB Version 3)</span>
+page.title=Implementing In-app Billing
 parent.title=In-app Billing
 parent.link=index.html
+page.tags="inapp, billing, iap"
 @jd:body
 
 <div id="qv-wrapper">
@@ -141,15 +142,17 @@
 };
 </pre>
 
-<p>In your activity’s {@link android.app.Activity#onCreate onCreate} method, perform the binding by calling the {@link android.content.Context#bindService bindService} method. Pass the method an {@link android.content.Intent} that references the In-app Billing service and an instance of the {@link android.content.ServiceConnection} that you created.</p>
-<pre>
-&#64;Override
-public void onCreate(Bundle savedInstanceState) {    
-    super.onCreate(savedInstanceState);
-    setContentView(R.layout.activity_main);        
-    bindService(new 
-        Intent("com.android.vending.billing.InAppBillingService.BIND"),
-                mServiceConn, Context.BIND_AUTO_CREATE);
+<p>In your activity’s {@link android.app.Activity#onCreate onCreate} method, perform the binding by calling the {@link android.content.Context#bindService bindService} method. Pass the method an {@link android.content.Intent} that references the In-app Billing service and an instance of the {@link android.content.ServiceConnection} that you created, and explicitly set the Intent's target package name to <code>com.android.vending</code> &mdash; the package name of Google Play app.</p>
+
+<p class="caution"><strong>Caution:</strong> To protect the security of billing transactions, always make sure to explicitly set the intent's target package name to <code>com.android.vending</code>, using {@link android.content.Intent#setPackage(java.lang.String) setPackage()} as shown in the example below. Setting the package name explicitly ensures that <em>only</em> the Google Play app can handle billing requests from your app, preventing other apps from intercepting those requests.</p>
+
+<pre>&#64;Override
+public void onCreate(Bundle savedInstanceState) {
+  super.onCreate(savedInstanceState);
+  setContentView(R.layout.activity_main);
+  Intent serviceIntent = new Intent("com.android.vending.billing.InAppBillingService.BIND");
+  serviceIntent.setPackage("com.android.vending");
+  bindService(serviceIntent, mServiceConn, Context.BIND_AUTO_CREATE);
 </pre>
 <p>You can now use the mService reference to communicate with the Google Play service.</p>
 <p class="note"><strong>Important:</strong> Remember to unbind from the In-app Billing service when you are done with your {@link android.app.Activity}. If you don’t unbind, the open service connection could cause your device’s performance to degrade. This example shows how to perform the unbind operation on a service connection to In-app Billing called {@code mServiceConn} by overriding the activity’s {@link android.app.Activity#onDestroy onDestroy} method.</p>
@@ -269,7 +272,7 @@
    }
 }
 </pre>
-<p class="note"><strong>Security Recommendation:</strong> When you send a purchase request, create a String token that uniquely identifies this purchase request and include this token in the {@code developerPayload}.You can use a randomly generated string as the token. When you receive the purchase response from Google Play, make sure to check the returned data signature, the {@code orderId}, and the {@code developerPayload} String. For added security, you should perform the checking on your own secure server. Make sure to verify that the {@code orderId} is a unique value that you have not previously processed, and the {@code developerPayload} String matches the token that you sent previously with the purchase request.</p>
+<p class="note"><strong>Security Recommendation:</strong>  When you send a purchase request, create a String token that uniquely identifies this purchase request and include this token in the {@code developerPayload}.You can use a randomly generated string as the token. When you receive the purchase response from Google Play, make sure to check the returned data signature, the {@code orderId}, and the {@code developerPayload} String. For added security, you should perform the checking on your own secure server. Make sure to verify that the {@code orderId} is a unique value that you have not previously processed, and the {@code developerPayload} String matches the token that you sent previously with the purchase request.</p>
 
 <h3 id="QueryPurchases">Querying for Purchased Items</h3>
 <p>To retrieve information about purchases made by a user from your app, call the {@code getPurchases} method on the In-app Billing Version 3 service. Pass in to the method the In-app Billing API version (“3”), the package name of your calling app, and the purchase type (“inapp” or "subs").</p>
diff --git a/docs/html/google/play/billing/billing_reference.jd b/docs/html/google/play/billing/billing_reference.jd
index e168d70..4d80964 100644
--- a/docs/html/google/play/billing/billing_reference.jd
+++ b/docs/html/google/play/billing/billing_reference.jd
@@ -1,4 +1,4 @@
-page.title=In-app Billing Reference <span style="font-size:16px;">(IAB Version 3)</span>
+page.title=In-app Billing Reference
 parent.title=In-app Billing
 parent.link=index.html
 @jd:body
@@ -102,15 +102,28 @@
   </tr>
   <tr>
     <td>{@code type}</td>
-    <td>Value must be “inapp” for an in-app product or "subs" for 
+    <td>Value must be “inapp” for an in-app product or "subs" for
 subscriptions.</td>
   </tr>
   <tr>
     <td>{@code price}</td>
-    <td>Formatted price of the item, including its currency sign. The price 
+    <td>Formatted price of the item, including its currency sign. The price
 does not include tax.</td>
   </tr>
   <tr>
+    <td>{@code price_amount_micros}</td>
+    <td>Price in micro-units, where 1,000,000 micro-units equal one unit of the
+    currency. For example, if {@code price} is {@code "€7.99"}, {@code
+    price_amount_micros} is {@code "7990000"}.</td>
+  </tr>
+  <tr>
+    <td>{@code price_currency_code}</td>
+    <td><a href="http://en.wikipedia.org/wiki/ISO_4217#Active_codes">ISO 4217
+    currency code</a> for {@code price}. For example, if {@code price} is
+    specified in British pounds sterling, {@code price_currency_code} is {@code
+    "GBP"}.</td>
+  </tr>
+  <tr>
     <td>{@code title}</td>
     <td>Title of the product.</td>
   </tr>
diff --git a/docs/html/google/play/billing/billing_subscriptions.jd b/docs/html/google/play/billing/billing_subscriptions.jd
index 3c72da1..b9b77df 100644
--- a/docs/html/google/play/billing/billing_subscriptions.jd
+++ b/docs/html/google/play/billing/billing_subscriptions.jd
@@ -1,9 +1,9 @@
-page.title=Google Play In-App Subscriptions
+page.title=In-App Subscriptions
 parent.title=In-app Billing
 parent.link=index.html
 page.metaDescription=Subscriptions let you sell content or features in your app with automated, recurring billing.
 page.image=/images/play_dev.jpg
-page.tags="inapp, iap, billing"
+page.tags="subscriptions, billing, inapp, iap"
 meta.tags="monetization, inappbilling, subscriptions"
 @jd:body
 
@@ -11,25 +11,32 @@
 <div id="qv">
   <h2>Quickview</h2>
   <ul>
-     <li>Users purchase your subscriptions from inside your apps, rather than 
-directly from Google Play.</li>
-     <li>Subscriptions let you sell products with automated, recurring billing
-(monthly or annual).</li>
-     <li>You can offer a configurable trial period for any subscription.</li>
-
+    <li>Subscriptions let you sell products with automated, recurring billing
+        at a variety of intervals.</li>
+    <li>You can offer a configurable trial period for monthly and
+        annual subscriptions.</li>
+    <li>You can manage subscriptions through the Developer Console, or by using
+        the
+        <a href="https://developers.google.com/android-publisher/">Google Play
+        Developer API</a>.</li>
+    <li>Users purchase your subscriptions from inside your apps, rather than
+        directly from Google Play.</li>
+    <li>You can defer billing for a particular user's subscription, to manage
+        accounts or offer rewards.</li>
   </ul>
   <h2>In this document</h2>
   <ol>
-    <li><a href="#overview">Overview</a></li>
+    <li><a href="#overview">Overview of Subscriptions</a></li>
     <li><a href="#administering">Configuring Subscriptions Items</a></li>
-    <li><a href="#cancellation">Cancellation</a></li>
-    <li><a href="#payment">Payment Processing</a></li>
+    <li><a href="#cancellation">Subscription Cancellation</a></li>
+    <li><a href="#payment">Payment Processing and Policies</a></li>
     <li><a href="#strategies">Purchase Verification Strategies</a></li>
+    <li><a href="#play-dev-api">Google Play Developer API</a></li>
   </ol>
   <h2>See also</h2>
   <ol>
     <li><a href="{@docRoot}google/play/billing/billing_integrate.html#Subs">Implementing Subscriptions (V3)</a></li>
-    <li><a href="https://developers.google.com/android-publisher/v1_1/">Google Play Android Developer API</a></li>
+    <li><a href="https://developers.google.com/android-publisher/">Google Play Developer API</a></li>
   </ol>
 </div>
 </div>
@@ -44,14 +51,15 @@
 <h2 id="overview">Overview of Subscriptions</h2>
 <p>A <em>subscription</em> is a product type offered in In-app Billing that 
 lets you sell content, services, or features to users from inside your app with 
-recurring monthly or annual billing. You can sell subscriptions to almost any 
+recurring, automated billing at the interval you specify. You can sell subscriptions to almost
+any
 type of digital content, from any type of app or game.</p>
 
 <p>As with other in-app products, you configure and publish subscriptions using
 the Developer Console and then sell them from inside apps installed on 
 Android devices. In the Developer console, you create subscription
 products and add them to a product list, then set a price and optional trial
-period for each, choose a billing interval (monthly or annual), and then 
+period for each, choose a billing interval, and then
 publish. For more information about using the Developer Console, see 
 <a href="#administering">Configuring Subscription Items</a>.</p>
 
@@ -63,17 +71,17 @@
 
 <img src="{@docRoot}images/in-app-billing/v3/billing_subscription_v3.png" style="float:right; border:4px solid ddd;">
 
-<p>After users have purchase subscriptions, they can view the subscriptions and 
+<p>After users have purchased subscriptions, they can view the subscriptions and 
 cancel them from the <strong>My Apps</strong> screen in the Play Store app or 
 from the app's product details page in the Play Store app. For more information 
 about handling user cancellations, see <a href="#cancellation">Subscription Cancellation</a>.</p>
 
-<p>In adddition to client-side API calls, you can use the server-side API for 
+<p>In addition to client-side API calls, you can use the server-side API for 
 In-app Billing to provide subscription purchasers with extended access to 
 content (for example, from your web site or another service).
 The server-side API lets you validate the status of a subscription when users
 sign into your other services. For more information about the API, see <a
-href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Purchase Status API</a>. </p>
+href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google Play Developer API</a>. </p>
 
 <p>You can also build on your existing external subscriber base from inside your
 Android apps.</p>
@@ -102,8 +110,10 @@
 subscriptions, see the <a href="{@docRoot}google/play/billing/versions.html#Subs">Version Notes</a>.</p>
 
 <h2 id="administering">Configuring Subscription Items</h2>
-<p>To create and manage subscriptions, use the Developer Console to set up a 
-product list for the app then configure these attributes for each subscription 
+
+<p>To create and manage subscriptions, you can use the Developer Console to set
+up a
+product list for the app, then configure these attributes for each subscription 
 product:</p>
 
 <ul>
@@ -113,8 +123,8 @@
 <li>Language: The default language for displaying the subscription</li>
 <li>Title: The title of the subscription product</li>
 <li>Description: Details that tell the user about the subscription</li>
-<li>Price: USD price of subscription per recurrence</li>
-<li>Recurrence: monthly or yearly</li>
+<li>Price: Default price of subscription per recurrence</li>
+<li>Recurrence: Interval of billing recurrence</li>
 <li>Additional currency pricing (can be auto-filled)</li>
 </ul>
 
@@ -122,6 +132,10 @@
 see <a href="{@docRoot}google/play/billing/billing_admin.html">Administering
 In-app Billing</a>.</p>
 
+<p>You can also create and manage subscriptions using the
+<a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">
+Google Play Developer API</a>.</p>
+
 <h3 id="pricing">Subscription pricing</h3>
 
 <p>When you create a subscription in the Developer Console, you can set a price
@@ -139,20 +153,30 @@
 <h3 id="user-billing">User billing</h3>
 
 <p>In the Developer Console, you can configure subscription products with 
-automated recurring billing at either of two intervals:</p>
+automated recurring billing at your choice of intervals:</p>
 
 <ul>
   <li>Monthly &mdash; Google Play bills the customer’s Google Wallet account at
   the time of purchase and monthly subsequent to the purchase date (exact billing
-  intervals can vary slightly over time)</li>
+  intervals can vary slightly over time).</li>
   <li>Annually &mdash; Google Play bills the customer's Google Wallet account at
   the time of purchase and again on the same date in subsequent years.</li>
+
+  <li>Seasonal &mdash; Google Play bills the customer's Google Wallet account at
+  the beginning of each "season" (you specify the season beginning and end
+  dates). This
+  is intended for annual purchases of seasonal content (such as sports-related
+  content). The subscription runs through the end of the season, and restarts
+  the next year at the start of the season.</li>
+
 </ul>
 
 <p>Billing continues indefinitely at the interval and price specified for the
 subscription. At each subscription renewal, Google Play charges the user account
-automatically, then notifies the user of the charges afterward by email. Billing
-cycles will always match subscription cycles, based on the purchase date.</p>
+automatically, then notifies the user of the charges afterward by email. For
+monthly and annual subscriptions, billing cycles will always match subscription
+cycles, based on the purchase date. (Seasonal subscriptions are charged
+annually, on the first day of the season.)</p>
 
 <p>Over the life of a subscription, the form of payment billed remains the same
 &mdash; Google Play always bills the same form of payment (such as credit card
@@ -164,7 +188,7 @@
 API. Your apps can store the token locally or pass it to your backend servers, 
 which can then use it to validate or cancel the subscription remotely using the
 <a
-href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Purchase Status API</a>.</p>
+href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google Play Developer API</a>.</p>
 
 <p>If a recurring payment fails (for example, because the customer’s credit
 card has become invalid), the subscription does not renew. How your app is 
@@ -182,18 +206,57 @@
 billing errors that may occur. Your backend servers can use the server-side API 
 to query and update your records and follow up with customers directly, if needed.</p>
 
+<h3 id="deferred-billing">Deferred Billing</h3>
+
+<p>Using the
+<a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google
+Play Developer API</a>, you can defer the next billing date for a
+subscriber. The user continues to be subscribed to the content, and has full
+access to it, but is not charged during the deferral period. This allows you
+to do things like:</p>
+
+<ul>
+  <li>Give users free access as part of a bundle or a special offer (for
+    example, giving free access to web content to users who subscribe to a
+    print magazine)</li>
+  <li>Give free access to customers as a goodwill gesture</li>
+</ul>
+
+<p>The longest you can defer billing is for one year per call. Of course, you
+can call the API again before the year is up to defer billing further.</p>
+
+<p>For example, Darcy has a monthly subscription to online content for the
+<em>Fishing Gentleman</em> app. He is normally
+billed £1.25 on the first of each month.
+On March 10, he participates in an online survey for the app publisher. The
+publisher rewards him by deferring his next payment until June 1. Darcy is not
+charged on April 1 or May 1, but still has access to the content as normal. On
+June 1, he is charged his normal £1.25 subscription fee.</p>
+
+<p class="note"><strong>Note:</strong> The API always defers the billing date
+by a whole number of days. If you request a deferral period that includes a
+fractional number of days, the API rounds the period up to the next full day.
+For example, if a user's subscription is set to renew on 15 June 2015 at
+14:00:00 UTC, and you use the API to defer the renewal date to 15 August 2015 at
+02:00:00 UTC, the API will round up to the next full day and set the renewal
+date to 15 August 2015 14:00:00 UTC.</p>
+
+<p>You can also offer free trials to new subscribers, as described in
+<a href="#trials">Free trials</a>.</p>
+
 <h3 id="trials">Free trials</h3>
 
 <p>In the Developer Console, you can set up a free trial period that lets users
 try your subscription content before buying it. The trial period runs for the 
 period of time that you set and then automatically converts to a full 
 subscription managed according to the subscription's billing interval and 
-price.</p>
+price. Free trials are supported for monthly and annual subscriptions only, and are not supported for seasonal subscriptions.</p>
 
 <p>To take advantage of a free trial, a user must "purchase" the full
 subscription through the standard In-app Billing flow, providing a valid form of
 payment to use for billing and completing the normal purchase transaction.
-However, the user is not charged any money, since the initial period corresponds
+However, the user is not charged any money, because the initial period
+corresponds
 to the free trial. Instead, Google Play records a transaction of $0.00 and the
 subscription is marked as purchased for the duration of the trial period or
 until cancellation. When the transaction is complete, Google Play notifies users
@@ -220,8 +283,10 @@
 period per subscription product.</p>
 
 <h3 id="publishing">Subscription publishing</h3>
+
 <p>When you have finished configuring your subscription product details in the
-Developer Console, you can publish the subscription in the app product list.</p>
+Developer Console or via the API,
+you can publish the subscription in the app product list.</p>
 
 <p>In the product list, you can add subscriptions, in-app products, or both. You
 can add multiple subscriptions that give access to different content or
@@ -263,10 +328,13 @@
 
 <p class="caution"><strong>Important:</strong> In all cases, you must continue
 to offer the content that your subscribers have purchased through their
-subscriptions, for as long any users are able to access it. That is, you must
-not remove any subscriber’s content while any user still has an active
+subscriptions, as long any user is able to access it. That is, you must
+not remove any content while any user still has an active
 subscription to it, even if that subscription will terminate at the end of the
-current billing cycle. Removing content that a subscriber is entitled to access
+current billing cycle. Alternatively, you can use the <a href="#refunds">refund
+and revoke</a> API to revoke each subscriber's subscription (one by one) and
+refund their subscription payments.
+Removing content that any subscriber is entitled to access
 will result in penalties. Please see the <a
 href="http://support.google.com/googleplay/android-developer/bin/answer.py?hl=en&answer=140504">policies document</a> for more information. </p>
 
@@ -280,19 +348,26 @@
 screen of the Play Store app. If the user chooses to cancel the uninstallation, 
 the app and subscriptions remain as they were.</p>
 
-<h3 id="refunds">Refunds</h3>
+<h3 id="refunds">Refunding and revoking subscriptions</h3>
 
-<p>With subscriptions, Google Play does not provide a refund window, so users 
-will need to contact you directly to request a refund.
+<p>With subscriptions, Google Play does not provide a refund window, so users
+will need to request a refund. They can request a refund from the <strong>My
+Orders</strong> page in the Play Store, or by contacting you directly.</p>
 
-<p>If you receive requests for refunds, you can use the server-side API to
-cancel the subscription or verify that it is already cancelled. However, keep in
-mind that Google Play considers cancelled subscriptions valid until the end of
-their current billing cycles, so even if you grant a refund and cancel the
-subscription, the user will still have access to the content.
+<p>If you receive requests for refunds, you can use the
+<a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google Play
+Developer API</a> or the Merchant Center to cancel the subscription, verify that it
+is already cancelled, or refund the user's payment without cancelling it. You
+can also use the
+<a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google
+Play Developer API</a> to <em>refund and revoke</em> a
+user's subscription. If you refund and revoke a subscription, the user's
+subscription is immediately cancelled, and the user's most recent subscription
+payment is refunded. (If you want to refund more than the most recent payment,
+you can process additional refunds through the Merchant Center.)</p>
 
-<p class="caution"><strong>Important:</strong> Partial refunds for canceled
-subscriptions are not available at this time.</p>
+<p class="caution"><strong>Important:</strong> Partial refunds are not available
+at this time.</p>
 
 <h2 id="payment">Payment Processing and Policies</h2>
 
@@ -317,9 +392,9 @@
 each recurring transaction by appending an integer as follows: </p>
 
 <p><span style="color:#777"><code style="color:#777">12999556515565155651.5565135565155651</code> (base order number)</span><br />
-<code>12999556515565155651.5565135565155651..0</code> (initial purchase orderID)<br />
-<code>12999556515565155651.5565135565155651..1</code> (first recurrence orderID)<br />
-<code>12999556515565155651.5565135565155651..2</code> (second recurrence orderID)<br />
+<code>12999556515565155651.5565135565155651..0</code> (first recurrence orderID)<br />
+<code>12999556515565155651.5565135565155651..1</code> (second recurrence orderID)<br />
+<code>12999556515565155651.5565135565155651..2</code> (third recurrence orderID)<br />
 ...<br /></p>
 
 <p>Google Play provides the order number as the value of the 
@@ -334,19 +409,28 @@
 
 <p>To verify a purchase, the app passes the purchase token and other details up
 to your backend servers, which verifies them directly with Google Play using the
-Purchase Status API.  If the backend server determines that the purchase is
+Google Play Developer API.  If the backend server determines that the purchase is
 valid, it notifies the app and grants access to the content.</p>
 
 <p>Keep in mind that users will want the ability to use your app at any time,
 including when there may be no network connection available. Make sure that your
 approach to purchase verification accounts for the offline use-case.</p>
 
-<h2 id="play-dev-api">Google Play Android Developer API</h2>
+<h2 id="play-dev-api">Google Play Developer API</h2>
 
-<p>Google Play offers an HTTP-based API that lets you remotely query the
-validity of a specific subscription at any time or cancel a subscription. The
-API is designed to be used from your backend servers as a way of securely
+<p>Google Play offers an HTTP-based API that lets you perform such tasks as:</p>
+  <ul>
+    <li>Remotely query the validity of a specific subscription at any time</li>
+    <li>Cancel a subscription</li>
+    <li>Defer a subscription's next billing date</li>
+    <li>Refund a subscription payment without cancelling the subscription</li>
+    <li>Refund and revoke a subscription</li>
+  </ul>
+
+<p>The API is designed to be used from your backend servers as a way of securely
 managing subscriptions, as well as extending and integrating subscriptions with
 other services.</p>
 
-<p>For complete information, see <a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Purchase Status API</a>.</p>
+<p>For complete information, see
+<a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google Play
+Developer API</a>.</p>
diff --git a/docs/html/google/play/billing/billing_testing.jd b/docs/html/google/play/billing/billing_testing.jd
index 8a49433..10f5326 100644
--- a/docs/html/google/play/billing/billing_testing.jd
+++ b/docs/html/google/play/billing/billing_testing.jd
@@ -1,6 +1,7 @@
 page.title=Testing In-app Billing
 parent.title=In-app Billing
 parent.link=index.html
+page.tags="inapp, billing, iap"
 @jd:body
 
 <div id="qv-wrapper">
diff --git a/docs/html/google/play/billing/index.jd b/docs/html/google/play/billing/index.jd
index 18b1523..bdbf5c7 100644
--- a/docs/html/google/play/billing/index.jd
+++ b/docs/html/google/play/billing/index.jd
@@ -2,7 +2,7 @@
 page.metaDescription=In-app Billing lets you sell digital content as one-time purchases or subscriptions.
 page.image=/images/play_dev.jpg
 meta.tags="monetizing, inappbilling, subscriptions"
-page.tags="inapp, iap, subscriptions"
+page.tags="billing, inapp, iap"
 @jd:body
 
 <p>In-app Billing is a Google Play service that lets you sell digital content from inside
@@ -14,21 +14,35 @@
 <div class="sidebox">
   <h2><strong>New in In-App Billing</strong></h2>
   <ul>
+  <li><strong>IAB v2 shutdown</strong>&mdash;In-app Billing v2 API is deprecated and will be shut down in January 2015. If your app is still using In-app Billing v2, please migrate to the v3 API as soon as possible.</li>
+  <li><strong>Seasonal subscriptions</strong>&mdash;You can now set up a
+    recurring <a href="billing_subscriptions.html#user-billing">seasonal
+    subscription</a> that starts and ends on the same date each year (for
+    example, a sports subscription that starts every September 1 and ends every
+    April 10).</li>
+  <li><strong>Deferred subscription billing</strong>&mdash;You can
+    <a href="billing_subscriptions.html#deferred-billing">defer</a> a
+    subscriber's next billing date until the date you choose. The user still has
+    access to the content but is not charged during the deferral period.</li>
   <li><strong>Google Play Developer API</strong>&mdash;The
     <a href="{@docRoot}google/play/billing/gp-purchase-status-api.html">Google
     Play Developer API</a> allows you to perform a number of publishing and
     app-management tasks. It includes the functionality previously known as the
     <em>Purchase Status API.</em> </li>
+  <li><strong>Refund/Revoke subscription</strong>&mdash;You can use the
+    Google Play Developer API to <a href="billing_subscriptions.html#refunds">refund
+    and revoke</a> a user's subscription. If you do this, the user's
+    subscription ends
+    immediately, and his or her most recent subscription payment is
+    refunded.</li>
   <li><strong>In-app Billing Version 3</strong>&mdash;The <a href="{@docRoot}google/play/billing/api.html">latest version</a> of In-app Billing features a synchronous API that is easier to implement and lets you manage in-app products and subscriptions more effectively.</li>
-  <li><strong>Subscriptions now supported in Version 3</strong>&mdash;You can query and launch purchase flows for subscription items using the V3 API.</li>
-  <li><strong>Free trials</strong>&mdash;You can now offer users a configurable <a href="/google/play/billing/v2/billing_subscriptions.html#trials">free trial period</a> for your in-app subscriptions. You can set up trials with a simple change in the Developer Console&mdash;no change to your app code is needed.</li>
  </ul>
 </div>
 </div>
 
 <ul>
 <li>Standard in-app products (one-time billing), or</li>
-<li>Subscriptions, (recurring, automated billing)</li>
+<li>Subscriptions (recurring, automated billing)</li>
 </ul>
 
 <p>When you use the in-app billing service to sell an item,
diff --git a/docs/html/google/play/billing/v2/api.jd b/docs/html/google/play/billing/v2/api.jd
index 9501555..36a9017 100644
--- a/docs/html/google/play/billing/v2/api.jd
+++ b/docs/html/google/play/billing/v2/api.jd
@@ -2,7 +2,28 @@
 excludeFromSuggestions=true
 @jd:body
 
-<div style="background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">In-app Billing Version 2 is superseded. Please <a href="{@docRoot}google/play/billing/billing_overview.html#migration">migrate to Version 3</a> at your earliest convenience.</div>
+<p class="caution" style=
+"background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">
+  The <strong>In-app Billing Version 2 API</strong> has been deprecated in
+  favor of the Version 3 API. If your app is using In-app Billing, please
+  <strong>make sure that it is using the Version 3 API</strong>. If your app is
+  still using the Version 2 API, you must <strong>migrate to the Version 3 API
+  as soon as possible</strong>.<br>
+  <br>
+  We plan to turn off the In-app Billing Version 2 service on <strong>January
+  27, 2015</strong>, after which time users will <strong>no longer be able to
+  purchase in-app items and subscriptions through the Version 2 API</strong>.
+  We strongly encourage and recommend you migrate your apps to use Version 3
+  API by November 2014, to provide ample time for users to update their apps to
+  the new version.<br>
+  <br>
+  For more information, please see the <a href=
+  "http://support.google.com/googleplay/android-developer/answer/6090268">Help Center
+  article</a>. For common questions about transitioning your implementation to
+  In-app Billing Version 3, please see <a href=
+  "{@docRoot}google/play/billing/billing_overview.html#migration">Migration
+  Considerations</a>.
+</p>
     <div id="qv-wrapper" style="margin-top:0;">
 <div id="qv">
 
diff --git a/docs/html/google/play/billing/v2/billing_integrate.jd b/docs/html/google/play/billing/v2/billing_integrate.jd
index 5eb17d5..c264271 100644
--- a/docs/html/google/play/billing/v2/billing_integrate.jd
+++ b/docs/html/google/play/billing/v2/billing_integrate.jd
@@ -2,7 +2,28 @@
 excludeFromSuggestions=true
 @jd:body
 
-<div style="background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">In-app Billing Version 2 is superseded. Please <a href="{@docRoot}google/play/billing/billing_overview.html#migration">migrate to Version 3</a> at your earliest convenience.</div>
+<p class="caution" style=
+"background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">
+  The <strong>In-app Billing Version 2 API</strong> has been deprecated in
+  favor of the Version 3 API. If your app is using In-app Billing, please
+  <strong>make sure that it is using the Version 3 API</strong>. If your app is
+  still using the Version 2 API, you must <strong>migrate to the Version 3 API
+  as soon as possible</strong>.<br>
+  <br>
+  We plan to turn off the In-app Billing Version 2 service on <strong>January
+  27, 2015</strong>, after which time users will <strong>no longer be able to
+  purchase in-app items and subscriptions through the Version 2 API</strong>.
+  We strongly encourage and recommend you migrate your apps to use Version 3
+  API by November 2014, to provide ample time for users to update their apps to
+  the new version.<br>
+  <br>
+  For more information, please see the <a href=
+  "http://support.google.com/googleplay/android-developer/answer/6090268">Help Center
+  article</a>. For common questions about transitioning your implementation to
+  In-app Billing Version 3, please see <a href=
+  "{@docRoot}google/play/billing/billing_overview.html#migration">Migration
+  Considerations</a>.
+</p>
     <div id="qv-wrapper" style="margin-top:0;">
 <div id="qv">
   <h2>In this document</h2>
diff --git a/docs/html/google/play/billing/v2/billing_reference.jd b/docs/html/google/play/billing/v2/billing_reference.jd
index 4587dee..32e00cf 100644
--- a/docs/html/google/play/billing/v2/billing_reference.jd
+++ b/docs/html/google/play/billing/v2/billing_reference.jd
@@ -2,7 +2,28 @@
 excludeFromSuggestions=true
 @jd:body
 
-<div style="background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">In-app Billing Version 2 is superseded. Please <a href="{@docRoot}google/play/billing/billing_overview.html#migration">migrate to Version 3</a> at your earliest convenience.</div>
+<p class="caution" style=
+"background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">
+  The <strong>In-app Billing Version 2 API</strong> has been deprecated in
+  favor of the Version 3 API. If your app is using In-app Billing, please
+  <strong>make sure that it is using the Version 3 API</strong>. If your app is
+  still using the Version 2 API, you must <strong>migrate to the Version 3 API
+  as soon as possible</strong>.<br>
+  <br>
+  We plan to turn off the In-app Billing Version 2 service on <strong>January
+  27, 2015</strong>, after which time users will <strong>no longer be able to
+  purchase in-app items and subscriptions through the Version 2 API</strong>.
+  We strongly encourage and recommend you migrate your apps to use Version 3
+  API by November 2014, to provide ample time for users to update their apps to
+  the new version.<br>
+  <br>
+  For more information, please see the <a href=
+  "http://support.google.com/googleplay/android-developer/answer/6090268">Help Center
+  article</a>. For common questions about transitioning your implementation to
+  In-app Billing Version 3, please see <a href=
+  "{@docRoot}google/play/billing/billing_overview.html#migration">Migration
+  Considerations</a>.
+</p>
     <div id="qv-wrapper" style="margin-top:0;">
 <div id="qv">
 <h2>In this document</h2>
diff --git a/docs/html/google/play/billing/v2/billing_subscriptions.jd b/docs/html/google/play/billing/v2/billing_subscriptions.jd
index f8051a9..01e39ac 100644
--- a/docs/html/google/play/billing/v2/billing_subscriptions.jd
+++ b/docs/html/google/play/billing/v2/billing_subscriptions.jd
@@ -2,7 +2,28 @@
 excludeFromSuggestions=true
 @jd:body
 
-<div style="background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">In-app Billing Version 2 is superseded. Please <a href="{@docRoot}google/play/billing/billing_overview.html#migration">migrate to Version 3</a> at your earliest convenience.</div>
+<p class="caution" style=
+"background-color:#fffdeb;width:100%;margin-bottom:1em;padding:.5em;">
+  The <strong>In-app Billing Version 2 API</strong> has been deprecated in
+  favor of the Version 3 API. If your app is using In-app Billing, please
+  <strong>make sure that it is using the Version 3 API</strong>. If your app is
+  still using the Version 2 API, you must <strong>migrate to the Version 3 API
+  as soon as possible</strong>.<br>
+  <br>
+  We plan to turn off the In-app Billing Version 2 service on <strong>January
+  27, 2015</strong>, after which time users will <strong>no longer be able to
+  purchase in-app items and subscriptions through the Version 2 API</strong>.
+  We strongly encourage and recommend you migrate your apps to use Version 3
+  API by November 2014, to provide ample time for users to update their apps to
+  the new version.<br>
+  <br>
+  For more information, please see the <a href=
+  "http://support.google.com/googleplay/android-developer/answer/6090268">Help Center
+  article</a>. For common questions about transitioning your implementation to
+  In-app Billing Version 3, please see <a href=
+  "{@docRoot}google/play/billing/billing_overview.html#migration">Migration
+  Considerations</a>.
+</p>
     <div id="qv-wrapper" style="margin-top:0;">
 <div id="qv">
   <h2>In this document</h2>
diff --git a/docs/html/google/play/billing/versions.jd b/docs/html/google/play/billing/versions.jd
index 1271a15..dbe3ea3 100644
--- a/docs/html/google/play/billing/versions.jd
+++ b/docs/html/google/play/billing/versions.jd
@@ -1,3 +1,4 @@
+excludeFromSuggestions=true
 page.title=In-app Billing Version Notes
 @jd:body
 
diff --git a/docs/html/guide/components/intents-common.jd b/docs/html/guide/components/intents-common.jd
index b4813a5..af9456d 100644
--- a/docs/html/guide/components/intents-common.jd
+++ b/docs/html/guide/components/intents-common.jd
@@ -1316,7 +1316,7 @@
 <dt>{@link android.provider.MediaStore#EXTRA_MEDIA_FOCUS MediaStore.EXTRA_MEDIA_FOCUS} (required)</dt>
 <dd>
 <p>Indicates the search mode (whether the user is looking for a particular artist, album, song,
-playlist, or radio channel). Most search modes take additional extras. For example, if the user
+or playlist). Most search modes take additional extras. For example, if the user
 is interested in listening to a particular song, the intent might have three additional extras:
 the song title, the artist, and the album. This intent supports the following search modes for
 each value of {@link android.provider.MediaStore#EXTRA_MEDIA_FOCUS}:</p>
@@ -1399,24 +1399,6 @@
       intent as an unstructured search.</li>
 </ul>
 </dd>
-<dt><p><em>Radio channel</em> - <code>"vnd.android.cursor.item/radio"</code></p></dt>
-<dd>
-<p>Play a particular radio channel or a radio channel that matches some criteria specified
-by additional extras.</p>
-<p>Additional extras:</p>
-<ul>
-  <li>{@link android.provider.MediaStore#EXTRA_MEDIA_ALBUM} - The album.</li>
-  <li>{@link android.provider.MediaStore#EXTRA_MEDIA_ARTIST} - The artist.</li>
-  <li><code>"android.intent.extra.genre"</code> - The genre.</li>
-  <li><code>"android.intent.extra.radio_channel"</code> - The radio channel.</li>
-  <li>{@link android.provider.MediaStore#EXTRA_MEDIA_TITLE} - The song name that the radio
-      channel is based on.</li>
-  <li>{@link android.app.SearchManager#QUERY} (required) - A string that contains any combination
-      of: the album, the artist, the genre, the radio channel, or the title. This extra is
-      always provided for backward compatibility: existing apps that do not know about search
-      modes can process this intent as an unstructured search.</li>
-</ul>
-</dd>
 <dt><p><em>Playlist</em> - {@link android.provider.MediaStore.Audio.Playlists#ENTRY_CONTENT_TYPE Audio.Playlists.ENTRY_CONTENT_TYPE}</p></dt>
 <dd>
 <p>Play a particular playlist or a playlist that matches some criteria specified
@@ -1444,13 +1426,13 @@
 
 
 <p><b>Example intent:</b></p>
-<p>If the user wants to listen to a radio station that plays songs from a particular artist,
-a search app may generate the following intent:</p>
+<p>If the user wants to listen to music from a particular artist, a search app may generate the
+following intent:</p>
 <pre>
-public void playSearchRadioByArtist(String artist) {
+public void playSearchArtist(String artist) {
     Intent intent = new Intent(MediaStore.INTENT_ACTION_MEDIA_PLAY_FROM_SEARCH);
     intent.putExtra(MediaStore.EXTRA_MEDIA_FOCUS,
-                    "vnd.android.cursor.item/radio");
+                    MediaStore.Audio.Artists.ENTRY_CONTENT_TYPE);
     intent.putExtra(MediaStore.EXTRA_MEDIA_ARTIST, artist);
     intent.putExtra(SearchManager.QUERY, artist);
     if (intent.resolveActivity(getPackageManager()) != null) {
@@ -1488,7 +1470,6 @@
         String artist = intent.getStringExtra(MediaStore.EXTRA_MEDIA_ARTIST);
         String genre = intent.getStringExtra("android.intent.extra.genre");
         String playlist = intent.getStringExtra("android.intent.extra.playlist");
-        String rchannel = intent.getStringExtra("android.intent.extra.radio_channel");
         String title = intent.getStringExtra(MediaStore.EXTRA_MEDIA_TITLE);
 
         // Determine the search mode and use the corresponding extras
@@ -1521,10 +1502,6 @@
             // 'Song' search mode
             playSong(album, artist, genre, title);
 
-        } else if (mediaFocus.compareTo("vnd.android.cursor.item/radio") == 0) {
-            // 'Radio channel' search mode
-            playRadioChannel(album, artist, genre, rchannel, title);
-
         } else if (mediaFocus.compareTo(MediaStore.Audio.Playlists.ENTRY_CONTENT_TYPE) == 0) {
             // 'Playlist' search mode
             playPlaylist(album, artist, genre, playlist, title);
@@ -1701,7 +1678,7 @@
 <p><b>Example intent:</b></p>
 <pre>
 public void composeMmsMessage(String message, Uri attachment) {
-    Intent intent = new Intent(Intent.ACTION_SEND);
+    Intent intent = new Intent(Intent.ACTION_SENDTO);
     intent.setType(HTTP.PLAIN_TEXT_TYPE);
     intent.putExtra("sms_body", message);
     intent.putExtra(Intent.EXTRA_STREAM, attachment);
diff --git a/docs/html/guide/practices/screens_support.jd b/docs/html/guide/practices/screens_support.jd
index dbe6c1a..7ebda53 100644
--- a/docs/html/guide/practices/screens_support.jd
+++ b/docs/html/guide/practices/screens_support.jd
@@ -111,15 +111,15 @@
   <dd>Actual physical size, measured as the screen's diagonal.
 
   <p>For simplicity, Android groups all actual screen sizes into four generalized sizes: small,
-normal, large, and extra large.</p></dd>
+normal, large, and extra-large.</p></dd>
 
 <dt><em>Screen density</em></dt>
   <dd>The quantity of pixels within a physical area of the screen; usually referred to as dpi (dots
 per inch). For example, a "low" density screen has fewer pixels within a given physical area,
 compared to a "normal" or "high" density screen.</p>
 
-  <p>For simplicity, Android groups all actual screen densities into four generalized densities:
-low, medium, high, and extra high.</p></dd>
+  <p>For simplicity, Android groups all actual screen densities into six generalized densities:
+low, medium, high, extra-high, extra-extra-high, and extra-extra-extra-high.</p></dd>
 
 <dt><em>Orientation</em></dt>
   <dd>The orientation of the screen from the user's point of view. This is either landscape or
@@ -168,9 +168,15 @@
 href="#DeclaringTabletLayouts">Declaring Tablet Layouts for Android 3.2</a> for more
 information.</p>
 </li>
-<li>A set of four generalized <strong>densities</strong>: <em>ldpi</em> (low), <em>mdpi</em>
-(medium),
-<em>hdpi</em> (high), and <em>xhdpi</em> (extra high)
+<li>A set of six generalized <strong>densities</strong>:
+  <ul>
+    <li><em>ldpi</em> (low) ~120dpi</li>
+    <li><em>mdpi</em> (medium) ~160dpi</li>
+    <li><em>hdpi</em> (high) ~240dpi</li>
+    <li><em>xhdpi</em> (extra-high) ~320dpi</li>
+    <li><em>xxhdpi</em> (extra-extra-high) ~480dpi</li>
+    <li><em>xxxhdpi</em> (extra-extra-extra-high) ~640dpi</li>
+  </ul>
 </li>
 </ul>
 
@@ -243,14 +249,14 @@
 densities.</p>
 
 <p>Maintaining density independence is important because, without it, a UI element (such as a
-button) appears physically larger on a low density screen and smaller on a high density screen. Such
+button) appears physically larger on a low-density screen and smaller on a high-density screen. Such
 density-related size changes can cause problems in your application layout and usability. Figures 2
 and 3 show the difference between an application when it does not provide density independence and
 when it does, respectively.</p>
 
 <img src="{@docRoot}images/screens_support/density-test-bad.png" alt=""  />
 <p class="img-caption"><strong>Figure 2.</strong> Example application without support for
-different densities, as shown on low, medium, and high density screens.</p>
+different densities, as shown on low, medium, and high-density screens.</p>
 
 <img src="{@docRoot}images/screens_support/density-test-good.png" alt="" />
 <p class="img-caption"><strong>Figure 3.</strong> Example application with good support for
@@ -266,8 +272,8 @@
 </ul>
 
 <p>In figure 2, the text view and bitmap drawable have dimensions specified in pixels ({@code px}
-units), so the views are physically larger on a low density screen and smaller on a high density
-screen. This is because although the actual screen sizes may be the same, the high density screen
+units), so the views are physically larger on a low-density screen and smaller on a high-density
+screen. This is because although the actual screen sizes may be the same, the high-density screen
 has more pixels per inch (the same amount of pixels fit in a smaller area). In figure 3, the layout
 dimensions are specified in density-independent pixels ({@code dp} units). Because the baseline for
 density-independent pixels is a medium-density screen, the device with a medium-density screen looks
@@ -311,7 +317,7 @@
 <a href="{@docRoot}guide/topics/manifest/supports-screens-element.html">{@code
 &lt;supports-screens&gt;}</a> element in your manifest file.</p>
   </li>
-  
+
   <li><strong>Provide different layouts for different screen sizes</strong>
     <p>By default, Android resizes your application layout to fit the current device screen. In most
 cases, this works fine. In other cases, your UI might not look as good and might need adjustments
@@ -320,7 +326,7 @@
 you might need to adjust sizes so that everything can fit on the screen.</p>
     <p>The configuration qualifiers you can use to provide size-specific resources are
 <code>small</code>, <code>normal</code>, <code>large</code>, and <code>xlarge</code>. For
-example, layouts for an extra large screen should go in {@code layout-xlarge/}.</p>
+example, layouts for an extra-large screen should go in {@code layout-xlarge/}.</p>
     <p>Beginning with Android 3.2 (API level 13), the above size groups are deprecated and you
 should instead use the {@code sw&lt;N&gt;dp} configuration qualifier to define the smallest
 available width required by your layout resources. For example, if your multi-pane tablet layout
@@ -328,7 +334,7 @@
 new techniques for declaring layout resources is discussed further in the section about <a
 href="#DeclaringTabletLayouts">Declaring Tablet Layouts for Android 3.2</a>.</p>
   </li>
-  
+
   <li><strong>Provide different bitmap drawables for different screen densities</strong>
     <p>By default, Android scales your bitmap drawables ({@code .png}, {@code .jpg}, and {@code
 .gif} files) and Nine-Patch drawables ({@code .9.png} files) so that they render at the appropriate
@@ -337,10 +343,22 @@
 screen, and scales them down when on a low-density screen. This scaling can cause artifacts in the
 bitmaps. To ensure your bitmaps look their best, you should include alternative versions at
 different resolutions for different screen densities.</p>
-    <p>The configuration qualifiers you can use for density-specific resources are
-<code>ldpi</code> (low), <code>mdpi</code> (medium), <code>hdpi</code> (high), and
-<code>xhdpi</code> (extra high). For example, bitmaps for high-density screens should go in
-{@code drawable-hdpi/}.</p>
+    <p>The <a href="#qualifiers">configuration qualifiers</a> (described in detail below) that you
+can use for density-specific resources are <code>ldpi</code> (low), <code>mdpi</code> (medium),
+<code>hdpi</code> (high), <code>xhdpi</code> extra-high), <code>xxhdpi</code>
+(extra-extra-high), and <code>xxxhdpi</code> (extra-extra-extra-high). For example, bitmaps
+for high-density screens should go in {@code drawable-hdpi/}.</p>
+    <p class="note" id="xxxhdpi-note"><strong>Note:</strong>  the <code>drawable-xxxhdpi</code>
+qualifier is necessary only to provide a launcher icon that can appear larger than usual on an
+xxhdpi device. You do not need to provide xxxhdpi assets for all your app's images.</p>
+    <p>Some devices scale-up the launcher icon by as much as 25%. For example, if your highest
+density launcher icon image is already extra-extra-high-density, the scaling process will make it
+appear less crisp. So you should provide a higher density launcher icon in the
+<code>drawable-xxxhdpi</code> directory, which the system uses instead of scaling up a smaller
+version of the icon.</p>
+    <p>See <a href="{@docRoot}design/style/iconography.html#xxxhdpi-launcher">Provide an
+xxx-high-density launcher icon</a> for more information. You should not use the
+<code>xxxhdpi</code> qualifier for UI elements other than the launcher icon.</p>
   </li>
 </ul>
 
@@ -371,14 +389,14 @@
   <p>The "default" resources are those that are not tagged with a configuration qualifier. For
 example, the resources in {@code drawable/} are the default drawable resources. The system
 assumes that default resources are designed for the baseline screen size and density, which is a
-normal screen size and a medium density. As such, the system scales default density
+normal screen size and a medium-density. As such, the system scales default density
 resources up for high-density screens and down for low-density screens, as appropriate.</p>
   <p>However, when the system is looking for a density-specific resource and does not find it in
 the density-specific directory, it won't always use the default resources. The system may
 instead use one of the other density-specific resources in order to provide better results
 when scaling. For example, when looking for a low-density resource and it is not available, the
 system prefers to scale-down the high-density version of the resource, because the
-system can easily scale a high-density resource down to low-density by a factor of 0.5, with 
+system can easily scale a high-density resource down to low-density by a factor of 0.5, with
 fewer artifacts, compared to scaling a medium-density resource by a factor of 0.75.</p>
 </li>
 </ol>
@@ -416,9 +434,9 @@
 files must be named exactly the same as the default resource files.</li>
 </ol>
 
-<p>For example, {@code xlarge} is a configuration qualifier for extra large screens. When you append
+<p>For example, {@code xlarge} is a configuration qualifier for extra-large screens. When you append
 this string to a resource directory name (such as {@code layout-xlarge}), it indicates to the
-system that these resources are to be used on devices that have an extra large screen.</p>
+system that these resources are to be used on devices that have an extra-large screen.</p>
 
 <p class="table-caption"><strong>Table 1.</strong> Configuration qualifiers that allow you to
 provide special resources for different screen configurations.</p>
@@ -445,11 +463,11 @@
 </tr>
 <tr>
 <td><code>xlarge</code></td>
-<td>Resources for <em>extra large</em> size screens.</td>
+<td>Resources for <em>extra-large</em> size screens.</td>
 </tr>
 
 <tr>
-<td rowspan="6">Density</td>
+<td rowspan="8">Density</td>
 <td><code>ldpi</code></td>
 <td>Resources for low-density (<em>ldpi</em>) screens (~120dpi).</td>
 </tr>
@@ -464,7 +482,14 @@
 </tr>
 <tr>
 <td><code>xhdpi</code></td>
-<td>Resources for extra high-density (<em>xhdpi</em>) screens (~320dpi).</td>
+<td>Resources for extra-high-density (<em>xhdpi</em>) screens (~320dpi).</td>
+</tr>
+<td><code>xxhdpi</code></td>
+<td>Resources for extra-extra-high-density (<em>xxhdpi</em>) screens (~480dpi).</td>
+</tr>
+<td><code>xxxhdpi</code></td>
+<td>Resources for extra-extra-extra-high-density (<em>xxxhdpi</em>) uses (~640dpi). Use this for the
+  launcher icon only, see <a href="#xxxhdpi-note">note</a> above.</td>
 </tr>
 <tr>
 <td><code>nodpi</code></td>
@@ -515,18 +540,18 @@
 
 <p>For example, the following is a list of resource directories in an application that
 provides different layout designs for different screen sizes and different bitmap drawables
-for medium, high, and extra high density screens.</p>
+for medium, high, and extra-high-density screens.</p>
 
 <pre class="classic">
-res/layout/my_layout.xml             // layout for normal screen size ("default")
-res/layout-small/my_layout.xml       // layout for small screen size
-res/layout-large/my_layout.xml       // layout for large screen size
-res/layout-xlarge/my_layout.xml      // layout for extra large screen size
-res/layout-xlarge-land/my_layout.xml // layout for extra large in landscape orientation
+res/layout/my_layout.xml              // layout for normal screen size ("default")
+res/layout-large/my_layout.xml        // layout for large screen size
+res/layout-xlarge/my_layout.xml       // layout for extra-large screen size
+res/layout-xlarge-land/my_layout.xml  // layout for extra-large in landscape orientation
 
-res/drawable-mdpi/my_icon.png        // bitmap for medium density
-res/drawable-hdpi/my_icon.png        // bitmap for high density
-res/drawable-xhdpi/my_icon.png       // bitmap for extra high density
+res/drawable-mdpi/my_icon.png         // bitmap for medium-density
+res/drawable-hdpi/my_icon.png         // bitmap for high-density
+res/drawable-xhdpi/my_icon.png        // bitmap for extra-high-density
+res/drawable-xxhdpi/my_icon.png       // bitmap for extra-extra-high-density
 </pre>
 
 <p>For more information about how to use alternative resources and a complete list of
@@ -575,10 +600,10 @@
 screen. For example, a row of buttons might not fit within the width of the screen on a small screen
 device. In this case you should provide an alternative layout for small screens that adjusts the
 size or position of the buttons.</li>
-  <li>When testing on an extra large screen, you might realize that your layout doesn't make
+  <li>When testing on an extra-large screen, you might realize that your layout doesn't make
 efficient use of the big screen and is obviously stretched to fill it.
-In this case, you should provide an alternative layout for extra large screens that provides a
-redesigned UI that is optimized for bigger screens such as tablets. 
+In this case, you should provide an alternative layout for extra-large screens that provides a
+redesigned UI that is optimized for bigger screens such as tablets.
     <p>Although your application should work fine without an alternative layout on big screens, it's
 quite important to users that your application looks as though it's designed specifically for their
 devices. If the UI is obviously stretched, users are more likely to be unsatisfied with the
@@ -598,7 +623,7 @@
 <p>If your UI uses bitmaps that need to fit the size of a view even after the system scales
 the layout (such as the background image for a button), you should use <a
 href="{@docRoot}guide/topics/graphics/2d-graphics.html#nine-patch">Nine-Patch</a> bitmap files. A
-Nine-Patch file is basically a PNG file in which you specific two-dimensional regions that are
+Nine-Patch file is basically a PNG file in which you specify two-dimensional regions that are
 stretchable. When the system needs to scale the view in which the bitmap is used, the system
 stretches the Nine-Patch bitmap, but stretches only the specified regions. As such, you don't
 need to provide different drawables for different screen sizes, because the Nine-Patch bitmap can
@@ -621,21 +646,24 @@
 each one, for different densities.</p>
 
 <p class="note"><strong>Note:</strong> You only need to provide density-specific drawables for
-bitmap files ({@code .png}, {@code .jpg}, or {@code .gif}) and Nine-Path files ({@code
+bitmap files ({@code .png}, {@code .jpg}, or {@code .gif}) and Nine-Patch files ({@code
 .9.png}). If you use XML files to define shapes, colors, or other <a
 href="{@docRoot}guide/topics/resources/drawable-resource.html">drawable resources</a>, you should
 put one copy in the default drawable directory ({@code drawable/}).</p>
 
 <p>To create alternative bitmap drawables for different densities, you should follow the
-<b>3:4:6:8 scaling ratio</b> between the four generalized densities. For example, if you have
-a bitmap drawable that's 48x48 pixels for medium-density screen (the size for a launcher icon),
-all the different sizes should be:</p>
+<b>3:4:6:8:12:16 scaling ratio</b> between the six generalized densities. For example, if you have
+a bitmap drawable that's 48x48 pixels for medium-density screens, all the different sizes should be:
+</p>
 
 <ul>
-  <li>36x36 for low-density</li>
-  <li>48x48 for medium-density</li>
-  <li>72x72 for high-density</li>
-  <li>96x96 for extra high-density</li>
+  <li>36x36 (0.75x) for low-density</li>
+  <li>48x48 (1.0x baseline) for medium-density</li>
+  <li>72x72 (1.5x) for high-density</li>
+  <li>96x96 (2.0x) for extra-high-density</li>
+  <li>180x180 (3.0x) for extra-extra-high-density</li>
+  <li>192x192 (4.0x) for extra-extra-extra-high-density (launcher icon only; see
+    <a href="#xxxhdpi-note">note</a> above)</li>
 </ul>
 
 <p>For more information about designing icons, see the <a
@@ -715,7 +743,7 @@
 screen area. Specifically, the device's smallestWidth is the shortest of the screen's available
 height and width (you may also think of it as the "smallest possible width" for the screen). You can
 use this qualifier to ensure that, regardless of the screen's current orientation, your
-application's has at least {@code &lt;N&gt;} dps of width available for it UI.</p>
+application's has at least {@code &lt;N&gt;} dps of width available for its UI.</p>
         <p>For example, if your layout requires that its smallest dimension of screen area be at
 least 600 dp at all times, then you can use this qualifer to create the layout resources, {@code
 res/layout-sw600dp/}. The system will use these resources only when the smallest dimension of
@@ -1011,8 +1039,8 @@
 <p>If you need to control exactly how your application will look on various
 screen configurations, adjust your layouts and bitmap drawables in configuration-specific
 resource directories. For example, consider an icon that you want to display on
-medium and high density screens. Simply create your icon at two different sizes
-(for instance 100x100 for medium density and 150x150 for high density) and put
+medium and high-density screens. Simply create your icon at two different sizes
+(for instance 100x100 for medium-density and 150x150 for high-density) and put
 the two variations in the appropriate directories, using the proper
 qualifiers:</p>
 
@@ -1115,9 +1143,7 @@
 <div class="figure" style="width:300px">
 <img src="{@docRoot}images/screens_support/scale-test.png" alt="" />
 <p class="img-caption"><strong>Figure 5.</strong> Comparison of pre-scaled and auto-scaled
-bitmaps, from <a
-href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/graphics/DensityActivity.html">
-ApiDemos</a>.
+bitmaps.
 </p>
 </div>
 
@@ -1153,10 +1179,7 @@
 (120), medium (160) and high (240) density bitmaps on a high-density screen. The differences are
 subtle, because all of the bitmaps are being scaled to match the current screen density, however the
 scaled bitmaps have slightly different appearances depending on whether they are pre-scaled or
-auto-scaled at draw time. You can find the source code for this sample application, which
-demonstrates using pre-scaled and auto-scaled bitmaps, in <a
-href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/graphics/DensityActivity.html">
-ApiDemos</a>.</p>
+auto-scaled at draw time.</p>
 
 <p class="note"><strong>Note:</strong> In Android 3.0 and above, there should be no perceivable
 difference between pre-scaled and auto-scaled bitmaps, due to improvements in the graphics
@@ -1172,9 +1195,9 @@
 pixels. Imagine an application in which a scroll or fling gesture is recognized after the user's
 finger has moved by at least 16 pixels. On a baseline screen, a user's must move by {@code 16 pixels
 / 160 dpi}, which equals 1/10th of an inch (or 2.5 mm) before the gesture is recognized. On a device
-with a high density display (240dpi), the user's must move by {@code 16 pixels / 240 dpi}, which
+with a high-density display (240dpi), the user's must move by {@code 16 pixels / 240 dpi}, which
 equals 1/15th of an inch (or 1.7 mm). The distance is much shorter and the application thus appears
-more sensitive to the user.</p> 
+more sensitive to the user.</p>
 
 <p>To fix this issue, the gesture threshold must be expressed in code in <code>dp</code> and then
 converted to actual pixels. For example:</p>
@@ -1194,7 +1217,7 @@
 <p>The {@link android.util.DisplayMetrics#density DisplayMetrics.density} field specifies the scale
 factor you must use to convert {@code dp} units to pixels, according to the current screen density.
 On a medium-density screen, {@link android.util.DisplayMetrics#density DisplayMetrics.density}
-equals 1.0; on a high-density screen it equals 1.5; on an extra high-density screen, it equals 2.0;
+equals 1.0; on a high-density screen it equals 1.5; on an extra-high-density screen, it equals 2.0;
 and on a low-density screen, it equals 0.75. This figure is the factor by which you should multiply
 the {@code dp} units on order to get the actual pixel count for the current screen. (Then add {@code
 0.5f} to round the figure up to the nearest whole number, when converting to an integer.) For more
@@ -1277,7 +1300,7 @@
         <nobr>High density (240), <em>hdpi</em><nobr>
       </th>
       <th>
-        <nobr>Extra high density (320), <em>xhdpi</em><nobr>
+        <nobr>Extra-high-density (320), <em>xhdpi</em><nobr>
       </th>
     </tr>
     <tr>
@@ -1315,7 +1338,7 @@
     </tr>
     <tr>
       <th>
-        <em>Extra Large</em> screen
+        <em>Extra-Large</em> screen
       </th>
       <td>1024x600</td>
       <td><strong>WXGA (1280x800)</strong><sup>&dagger;</sup><br>
@@ -1369,4 +1392,4 @@
 
 <p>For more information about creating AVDs from the command line, see <a
 href="{@docRoot}tools/devices/managing-avds-cmdline.html">Managing AVDs from the
-Command Line</a></p>
+Command Line</a>.</p>
\ No newline at end of file
diff --git a/docs/html/guide/topics/admin/device-admin.jd b/docs/html/guide/topics/admin/device-admin.jd
index ee6b814..bed4b4d 100644
--- a/docs/html/guide/topics/admin/device-admin.jd
+++ b/docs/html/guide/topics/admin/device-admin.jd
@@ -28,12 +28,6 @@
       <li>{@link android.app.admin.DevicePolicyManager}</li>
       <li>{@link android.app.admin.DeviceAdminInfo}</li>
     </ol>
-    <h2>Related samples</h2>
-    <ol>
-      <li><a
-href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html">
-DeviceAdminSample</a></li>
-</ol>
 </div>
 </div>
 
@@ -232,18 +226,12 @@
 
 <h2 id="sample">Sample Application</h2>
 
-<p>The examples used in this document are based on the <a
-href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html">
-Device Administration API
-sample</a>, which is included in the SDK samples. For information on downloading and
-installing the SDK samples, see <a
-href="{@docRoot}resources/samples/get.html">
-Getting the Samples</a>. Here is the  <a
-href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html">
-complete code</a> for
-the sample. </p>
-<p>The
-sample application offers a demo of device admin features. It presents users
+<p>The examples used in this document are based on the Device Administration API
+sample, which is included in the SDK samples (available through the
+Android SDK Manager) and located on your system as 
+<code>&lt;sdk_root&gt;/ApiDemos/app/src/main/java/com/example/android/apis/app/DeviceAdminSample.java</code>.</p>
+
+<p>The sample application offers a demo of device admin features. It presents users
 with a user interface that lets them enable the device admin application. Once
 they've enabled the application, they can use the buttons in the user interface
 to do the following:</p>
@@ -676,7 +664,8 @@
 <p>You can also programmatically tell the device to lock immediately:</p>
 <pre>
 DevicePolicyManager mDPM;
-mDPM.lockNow();</pre>
+mDPM.lockNow();
+</pre>
 
 
 
@@ -692,12 +681,12 @@
 <pre>
 DevicePolicyManager mDPM;
 mDPM.wipeData(0);</pre>
-<p>The {@link android.app.admin.DevicePolicyManager#wipeData wipeData()} method takes as its parameter a bit mask of
-additional options. Currently the value must be 0. </p>
+<p>The {@link android.app.admin.DevicePolicyManager#wipeData wipeData()} method takes as its
+  parameter a bit mask of additional options. Currently the value must be 0. </p>
 
 <h4>Disable camera</h4>
 <p>Beginning with Android 4.0, you can disable the camera. Note that this doesn't have to be a permanent disabling. The camera can be enabled/disabled dynamically based on context, time, and so on. </p>
-<p>You control whether the camera is disabled by using the 
+<p>You control whether the camera is disabled by using the
 {@link android.app.admin.DevicePolicyManager#setCameraDisabled(android.content.ComponentName, boolean) setCameraDisabled()} method. For example, this snippet sets the camera to be enabled or disabled based on a checkbox setting:</p>
 
 <pre>private CheckBoxPreference mDisableCameraCheckbox;
@@ -708,8 +697,8 @@
 </pre>
 
 
-<h4 id=storage">Storage encryption</h4>
-<p>Beginning with Android 3.0, you can use the 
+<h4 id="storage">Storage encryption</h4>
+<p>Beginning with Android 3.0, you can use the
 {@link android.app.admin.DevicePolicyManager#setStorageEncryption(android.content.ComponentName,boolean) setStorageEncryption()} 
 method to set a policy requiring encryption of the storage area, where supported.</p>
 
@@ -722,5 +711,5 @@
 mDPM.setStorageEncryption(mDeviceAdminSample, true);
 </pre>
 <p>
-See the <a href="{@docRoot}resources/samples/ApiDemos/src/com/example/android/apis/app/DeviceAdminSample.html"> Device Administration API sample</a> for a complete
-example of how to enable storage encryption.</p>
+See the Device Administration API sample for a complete example of how to enable storage encryption.
+</p>
\ No newline at end of file
diff --git a/docs/html/guide/topics/renderscript/compute.jd b/docs/html/guide/topics/renderscript/compute.jd
index 297a2dc..2e7ce56 100644
--- a/docs/html/guide/topics/renderscript/compute.jd
+++ b/docs/html/guide/topics/renderscript/compute.jd
@@ -159,8 +159,7 @@
 
 <ul>
   <li><strong>{@link android.renderscript}</strong> - The APIs in this class package are
-    available on devices running Android 3.0 (API level 11) and higher. These are the original APIs
-    for RenderScript and are not currently being updated.</li>
+    available on devices running Android 3.0 (API level 11) and higher. </li>
   <li><strong>{@link android.support.v8.renderscript}</strong> - The APIs in this package are
     available through a <a href="{@docRoot}tools/support-library/features.html#v8">Support
     Library</a>, which allows you to use them on devices running Android 2.2 (API level 8) and
@@ -168,8 +167,8 @@
 </ul>
 
 <p>We strongly recommend using the Support Library APIs for accessing RenderScript because they
-  include the latest improvements to the RenderScript compute framework and provide a wider range
-  of device compatibility.</p>
+  provide a wider range of device compatibility. Developers targeting specific versions of 
+  Android can use {@link android.renderscript} if necessary.</p>
 
 
 <h3 id="ide-setup">Using the RenderScript Support Library APIs</h3>
diff --git a/docs/html/guide/topics/resources/providing-resources.jd b/docs/html/guide/topics/resources/providing-resources.jd
index bf16630..6d9527f 100644
--- a/docs/html/guide/topics/resources/providing-resources.jd
+++ b/docs/html/guide/topics/resources/providing-resources.jd
@@ -389,7 +389,7 @@
             <ul>
               <li>240x320 ldpi (QVGA handset)</li>
               <li>320x480 mdpi (handset)</li>
-              <li>480x800 hdpi (high density handset)</li>
+              <li>480x800 hdpi (high-density handset)</li>
             </ul>
           </li>
           <li>480, for screens such as 480x800 mdpi (tablet/handset).</li>
@@ -483,20 +483,20 @@
         <ul class="nolist">
         <li>{@code small}: Screens that are of similar size to a
         low-density QVGA screen. The minimum layout size for a small screen
-        is approximately 320x426 dp units.  Examples are QVGA low density and VGA high
+        is approximately 320x426 dp units.  Examples are QVGA low-density and VGA high
         density.</li>
         <li>{@code normal}: Screens that are of similar size to a
         medium-density HVGA screen. The minimum
         layout size for a normal screen is approximately 320x470 dp units.  Examples
-        of such screens a WQVGA low density, HVGA medium density, WVGA
-        high density.</li>
+        of such screens a WQVGA low-density, HVGA medium-density, WVGA
+        high-density.</li>
         <li>{@code large}: Screens that are of similar size to a
         medium-density VGA screen.
         The minimum layout size for a large screen is approximately 480x640 dp units.
-        Examples are VGA and WVGA medium density screens.</li>
+        Examples are VGA and WVGA medium-density screens.</li>
         <li>{@code xlarge}: Screens that are considerably larger than the traditional
         medium-density HVGA screen. The minimum layout size for an xlarge screen
-        is approximately 720x960 dp units.  In most cases, devices with extra large
+        is approximately 720x960 dp units.  In most cases, devices with extra-large
         screens would be too large to carry in a pocket and would most likely
         be tablet-style devices. <em>Added in API level 9.</em></li>
         </ul>
@@ -613,6 +613,8 @@
         <code>mdpi</code><br/>
         <code>hdpi</code><br/>
         <code>xhdpi</code><br/>
+        <code>xxhdpi</code><br/>
+        <code>xxxhdpi</code><br/>
         <code>nodpi</code><br/>
         <code>tvdpi</code>
       </td>
@@ -622,8 +624,14 @@
           <li>{@code mdpi}: Medium-density (on traditional HVGA) screens; approximately
 160dpi.</li>
           <li>{@code hdpi}: High-density screens; approximately 240dpi.</li>
-          <li>{@code xhdpi}: Extra high-density screens; approximately 320dpi. <em>Added in API
+          <li>{@code xhdpi}: Extra-high-density screens; approximately 320dpi. <em>Added in API
 Level 8</em></li>
+          <li>{@code xxhdpi}: Extra-extra-high-density screens; approximately 480dpi. <em>Added in API
+Level 16</em></li>
+          <li>{@code xxxhdpi}: Extra-extra-extra-high-density uses (launcher icon only, see the 
+            <a href="{@docRoot}guide/practices/screens_support.html#xxxhdpi-note">note</a> 
+            in <em>Supporting Multiple Screens</em>); approximately 640dpi. <em>Added in API
+Level 18</em></li>
           <li>{@code nodpi}: This can be used for bitmap resources that you do not want to be scaled
 to match the device density.</li>
           <li>{@code tvdpi}: Screens somewhere between mdpi and hdpi; approximately 213dpi. This is
@@ -631,8 +639,9 @@
 apps shouldn't need it&mdash;providing mdpi and hdpi resources is sufficient for most apps and
 the system will scale them as appropriate. This qualifier was introduced with API level 13.</li>
         </ul>
-        <p>There is a 3:4:6:8 scaling ratio between the four primary densities (ignoring the
-tvdpi density). So, a 9x9 bitmap in ldpi is 12x12 in mdpi, 18x18 in hdpi and 24x24 in xhdpi.</p>
+        <p>There is a 3:4:6:8:12:16 scaling ratio between the six primary densities (ignoring the
+tvdpi density). So, a 9x9 bitmap in ldpi is 12x12 in mdpi, 18x18 in hdpi, 24x24 in xhdpi and so on.
+</p>
         <p>If you decide that your image resources don't look good enough on a television or
 other certain devices and want to try tvdpi resources, the scaling factor is 1.33*mdpi. For
 example, a 100px x 100px image for mdpi screens should be 133px x 133px for tvdpi.</p>
diff --git a/docs/html/guide/topics/ui/accessibility/services.jd b/docs/html/guide/topics/ui/accessibility/services.jd
index c868080..d69af9f 100644
--- a/docs/html/guide/topics/ui/accessibility/services.jd
+++ b/docs/html/guide/topics/ui/accessibility/services.jd
@@ -71,24 +71,30 @@
 
 <h3 id="service-declaration">Accessibility service declaration</h3>
 
-<p>In order to be treated as an accessibility service, your application must include the
+<p>In order to be treated as an accessibility service, you must include a
 {@code service} element (rather than the {@code activity} element) within the {@code application}
-element in its manifest. In addition, within the {@code service} element, you must also include an
+element in your manifest. In addition, within the {@code service} element, you must also include an
 accessibility service intent filter. For compatiblity with Android 4.1 and higher, the manifest
 must also request the {@link android.Manifest.permission#BIND_ACCESSIBILITY_SERVICE} permission
 as shown in the following sample:</p>
 
 <pre>
-&lt;application&gt;
-  &lt;service android:name=&quot;.MyAccessibilityService&quot;
-      android:label=&quot;@string/accessibility_service_label&quot;
-      android:permission=&quot;android.permission.BIND_ACCESSIBILITY_SERVICE&quot&gt;
-    &lt;intent-filter&gt;
-      &lt;action android:name=&quot;android.accessibilityservice.AccessibilityService&quot; /&gt;
-    &lt;/intent-filter&gt;
-  &lt;/service&gt;
-  &lt;uses-permission android:name="android.permission.BIND_ACCESSIBILITY_SERVICE" /&gt;
-&lt;/application&gt;
+&lt;manifest&gt;
+  ...
+  &lt;uses-permission ... /&gt;
+  ...
+  &lt;application&gt;
+    ...
+    &lt;service android:name=&quot;.MyAccessibilityService&quot;
+        android:label=&quot;@string/accessibility_service_label&quot;
+        android:permission=&quot;android.permission.BIND_ACCESSIBILITY_SERVICE&quot&gt;
+      &lt;intent-filter&gt;
+        &lt;action android:name=&quot;android.accessibilityservice.AccessibilityService&quot; /&gt;
+      &lt;/intent-filter&gt;
+    &lt;/service&gt;
+    &lt;uses-permission android:name="android.permission.BIND_ACCESSIBILITY_SERVICE" /&gt;
+  &lt;/application&gt;
+&lt;/manifest&gt;
 </pre>
 
 <p>These declarations are required for all accessibility services deployed on Android 1.6 (API Level
diff --git a/docs/html/guide/topics/ui/declaring-layout.jd b/docs/html/guide/topics/ui/declaring-layout.jd
index cb952a4..ab105fd 100644
--- a/docs/html/guide/topics/ui/declaring-layout.jd
+++ b/docs/html/guide/topics/ui/declaring-layout.jd
@@ -31,7 +31,7 @@
     <li>{@link android.view.ViewGroup}</li>
     <li>{@link android.view.ViewGroup.LayoutParams}</li>
   </ol>
-  
+
   <h2>See also</h2>
   <ol>
     <li><a href="{@docRoot}training/basics/firstapp/building-ui.html">Building a Simple User
@@ -43,9 +43,9 @@
 href="{@docRoot}guide/topics/appwidgets/index.html">app widget</a>.
 You can declare a layout in two ways:</p>
 <ul>
-<li><strong>Declare UI elements in XML</strong>. Android provides a straightforward XML 
+<li><strong>Declare UI elements in XML</strong>. Android provides a straightforward XML
 vocabulary that corresponds to the View classes and subclasses, such as those for widgets and layouts.</li>
-<li><strong>Instantiate layout elements at runtime</strong>. Your 
+<li><strong>Instantiate layout elements at runtime</strong>. Your
 application can create View and ViewGroup objects (and manipulate their properties) programmatically. </li>
 </ul>
 
@@ -55,12 +55,12 @@
 <div class="sidebox">
   <ul>
   <li>The <a href="{@docRoot}tools/sdk/eclipse-adt.html">ADT
-  Plugin for Eclipse</a> offers a layout preview of your XML &mdash; 
+  Plugin for Eclipse</a> offers a layout preview of your XML &mdash;
   with the XML file opened, select the <strong>Layout</strong> tab.</li>
-  <li>You should also try the 
-  <a href="{@docRoot}tools/debugging/debugging-ui.html#hierarchyViewer">Hierarchy Viewer</a> tool, 
-  for debugging layouts &mdash; it reveals layout property values, 
-  draws wireframes with padding/margin indicators, and full rendered views while 
+  <li>You should also try the
+  <a href="{@docRoot}tools/debugging/debugging-ui.html#hierarchyViewer">Hierarchy Viewer</a> tool,
+  for debugging layouts &mdash; it reveals layout property values,
+  draws wireframes with padding/margin indicators, and full rendered views while
   you debug on the emulator or device.</li>
   <li>The <a href="{@docRoot}tools/debugging/debugging-ui.html#layoutopt">layoutopt</a> tool lets
   you quickly analyze your layouts and hierarchies for inefficiencies or other problems.</li>
@@ -68,7 +68,7 @@
 </div>
 
 <p>The advantage to declaring your UI in XML is that it enables you to better separate the presentation of your application from the code that controls its behavior. Your UI descriptions are external to your application code, which means that you can modify or adapt it without having to modify your source code and recompile. For example, you can create XML layouts for different screen orientations, different device screen sizes, and different languages. Additionally, declaring the layout in XML makes it easier to visualize the structure of your UI, so it's easier to debug problems. As such, this document focuses on teaching you how to declare your layout in XML. If you're
-interested in instantiating View objects at runtime, refer to the {@link android.view.ViewGroup} and 
+interested in instantiating View objects at runtime, refer to the {@link android.view.ViewGroup} and
 {@link android.view.View} class references.</p>
 
 <p>In general, the XML vocabulary for declaring UI elements closely follows the structure and naming of the classes and methods, where element names correspond to class names and attribute names correspond to methods. In fact, the correspondence is often so direct that you can guess what XML attribute corresponds to a class method, or guess what class corresponds to a given XML element. However, note that not all vocabulary is identical. In some cases, there are slight naming differences. For
@@ -102,7 +102,7 @@
 &lt;/LinearLayout>
 </pre>
 
-<p>After you've declared your layout in XML, save the file with the <code>.xml</code> extension, 
+<p>After you've declared your layout in XML, save the file with the <code>.xml</code> extension,
 in your Android project's <code>res/layout/</code> directory, so it will properly compile. </p>
 
 <p>More information about the syntax for a layout XML file is available in the <a
@@ -111,11 +111,11 @@
 <h2 id="load">Load the XML Resource</h2>
 
 <p>When you compile your application, each XML layout file is compiled into a
-{@link android.view.View} resource. You should load the layout resource from your application code, in your 
+{@link android.view.View} resource. You should load the layout resource from your application code, in your
 {@link android.app.Activity#onCreate(android.os.Bundle) Activity.onCreate()} callback implementation.
-Do so by calling <code>{@link android.app.Activity#setContentView(int) setContentView()}</code>, 
-passing it the reference to your layout resource in the form of: 
-<code>R.layout.<em>layout_file_name</em></code>. 
+Do so by calling <code>{@link android.app.Activity#setContentView(int) setContentView()}</code>,
+passing it the reference to your layout resource in the form of:
+<code>R.layout.<em>layout_file_name</em></code>.
 For example, if your XML layout is saved as <code>main_layout.xml</code>, you would load it
 for your Activity like so:</p>
 <pre>
@@ -126,7 +126,7 @@
 </pre>
 
 <p>The <code>onCreate()</code> callback method in your Activity is called by the Android framework when
-your Activity is launched (see the discussion about lifecycles, in the 
+your Activity is launched (see the discussion about lifecycles, in the
 <a href="{@docRoot}guide/components/activities.html#Lifecycle">Activities</a>
 document).</p>
 
@@ -136,18 +136,18 @@
 <p>Every View and ViewGroup object supports their own variety of XML attributes.
 Some attributes are specific to a View object (for example, TextView supports the <code>textSize</code>
 attribute), but these attributes are also inherited by any View objects that may extend this class.
-Some are common to all View objects, because they are inherited from the root View class (like 
-the <code>id</code> attribute). And, other attributes are considered "layout parameters," which are 
+Some are common to all View objects, because they are inherited from the root View class (like
+the <code>id</code> attribute). And, other attributes are considered "layout parameters," which are
 attributes that describe certain layout orientations of the View object, as defined by that object's
 parent ViewGroup object.</p>
 
 <h3 id="id">ID</h3>
 
 <p>Any View object may have an integer ID associated with it, to uniquely identify the View within the tree.
-When the application is compiled, this ID is referenced as an integer, but the ID is typically 
+When the application is compiled, this ID is referenced as an integer, but the ID is typically
 assigned in the layout XML file as a string, in the <code>id</code> attribute.
 This is an XML attribute common to all View objects
-(defined by the {@link android.view.View} class) and you will use it very often. 
+(defined by the {@link android.view.View} class) and you will use it very often.
 The syntax for an ID, inside an XML tag is:</p>
 <pre>android:id="&#64;+id/my_button"</pre>
 
@@ -170,7 +170,7 @@
         android:text="&#64;string/my_button_text"/>
 </pre>
   </li>
-  <li>Then create an instance of the view object and capture it from the layout 
+  <li>Then create an instance of the view object and capture it from the layout
 (typically in the <code>{@link android.app.Activity#onCreate(Bundle) onCreate()}</code> method):
 <pre>
 Button myButton = (Button) findViewById(R.id.my_button);
@@ -178,16 +178,16 @@
   </li>
 </ol>
 <p>Defining IDs for view objects is important when creating a {@link android.widget.RelativeLayout}.
-In a relative layout, sibling views can define their layout relative to another sibling view, 
+In a relative layout, sibling views can define their layout relative to another sibling view,
 which is referenced by the unique ID.</p>
 <p>An ID need not be unique throughout the entire tree, but it should be
-unique within the part of the tree you are searching (which may often be the entire tree, so it's best 
+unique within the part of the tree you are searching (which may often be the entire tree, so it's best
 to be completely unique when possible).</p>
 
 
 <h3 id="layout-params">Layout Parameters</h3>
 
-<p>XML layout attributes named <code>layout_<em>something</em></code> define 
+<p>XML layout attributes named <code>layout_<em>something</em></code> define
 layout parameters for the View that are appropriate for the ViewGroup in which it resides.</p>
 
 <p>Every ViewGroup class implements a nested class that extends {@link
@@ -201,7 +201,7 @@
 parameters associated with each view.</p>
 
 <p>Note that every LayoutParams subclass has its own syntax for setting
-values. Each child element must define LayoutParams that are appropriate for its parent, 
+values. Each child element must define LayoutParams that are appropriate for its parent,
 though it may also define different LayoutParams for its own children. </p>
 
 <p>All view groups include a width and height (<code>layout_width</code> and
@@ -236,7 +236,7 @@
    two dimensions, expressed as a width and a height. The unit for location
    and dimensions is the pixel.
    </p>
-  
+
    <p>
    It is possible to retrieve the location of a view by invoking the methods
    {@link android.view.View#getLeft()} and {@link android.view.View#getTop()}. The former returns the left, or X,
@@ -246,7 +246,7 @@
    when <code>getLeft()</code> returns 20, that means the view is located 20 pixels to the
    right of the left edge of its direct parent.
    </p>
-  
+
    <p>
    In addition, several convenience methods are offered to avoid unnecessary
    computations, namely {@link android.view.View#getRight()} and {@link android.view.View#getBottom()}.
@@ -254,14 +254,14 @@
    rectangle representing the view. For instance, calling {@link android.view.View#getRight()}
    is similar to the following computation: <code>getLeft() + getWidth()</code>.
    </p>
-   
+
 
 <h2 id="SizePaddingMargins">Size, Padding and Margins</h2>
    <p>
    The size of a view is expressed with a width and a height. A view actually
    possess two pairs of width and height values.
    </p>
-  
+
    <p>
    The first pair is known as <em>measured width</em> and
    <em>measured height</em>. These dimensions define how big a view wants to be
@@ -269,16 +269,16 @@
    measured dimensions can be obtained by calling {@link android.view.View#getMeasuredWidth()}
    and {@link android.view.View#getMeasuredHeight()}.
    </p>
-  
+
    <p>
    The second pair is simply known as <em>width</em> and <em>height</em>, or
    sometimes <em>drawing width</em> and <em>drawing height</em>. These
    dimensions define the actual size of the view on screen, at drawing time and
    after layout. These values may, but do not have to, be different from the
    measured width and height. The width and height can be obtained by calling
-   {@link android.view.View#getWidth()} and {@link android.view.View#getHeight()}. 
+   {@link android.view.View#getWidth()} and {@link android.view.View#getHeight()}.
    </p>
-  
+
    <p>
    To measure its dimensions, a view takes into account its padding. The padding
    is expressed in pixels for the left, top, right and bottom parts of the view.
@@ -287,9 +287,9 @@
    2 pixels to the right of the left edge. Padding can be set using the
    {@link android.view.View#setPadding(int, int, int, int)} method and queried by calling
    {@link android.view.View#getPaddingLeft()}, {@link android.view.View#getPaddingTop()},
-   {@link android.view.View#getPaddingRight()} and {@link android.view.View#getPaddingBottom()}.  
+   {@link android.view.View#getPaddingRight()} and {@link android.view.View#getPaddingBottom()}.
    </p>
-  
+
    <p>
    Even though a view can define a padding, it does not provide any support for
    margins. However, view groups provide such a support. Refer to
@@ -297,13 +297,13 @@
    {@link android.view.ViewGroup.MarginLayoutParams} for further information.
    </p>
 
-   <p>For more information about dimensions, see 
+   <p>For more information about dimensions, see
    <a href="{@docRoot}guide/topics/resources/more-resources.html#Dimension">Dimension Values</a>.
    </p>
-   
 
-   
-   
+
+
+
 
 
 <style type="text/css">
@@ -332,7 +332,7 @@
 possible. Your layout draws faster if it has fewer nested layouts (a wide view hierarchy is
 better than a deep view hierarchy).</p>
 
-<!-- 
+<!--
 <h2 id="framelayout">FrameLayout</h2>
 <p>{@link android.widget.FrameLayout FrameLayout} is the simplest type of layout
 object. It's basically a blank space on your screen that you can
@@ -417,7 +417,7 @@
 android.widget.ListView}, initialize a new {@link android.widget.ArrayAdapter} using a
 constructor to specify the layout for each string and the string array:</p>
 <pre>
-ArrayAdapter adapter = new ArrayAdapter&lt;String>(this, 
+ArrayAdapter&lt;String> adapter = new ArrayAdapter&lt;String>(this,
         android.R.layout.simple_list_item_1, myStringArray);
 </pre>
 <p>The arguments for this constructor are:</p>
@@ -453,14 +453,14 @@
 android.database.Cursor} you want in the layout for each result and an integer array specifying the
 corresponding views that each column should be placed:</p>
 <pre>
-String[] fromColumns = {ContactsContract.Data.DISPLAY_NAME, 
+String[] fromColumns = {ContactsContract.Data.DISPLAY_NAME,
                         ContactsContract.CommonDataKinds.Phone.NUMBER};
 int[] toViews = {R.id.display_name, R.id.phone_number};
 </pre>
 <p>When you instantiate the {@link android.widget.SimpleCursorAdapter}, pass the layout to use for
 each result, the {@link android.database.Cursor} containing the results, and these two arrays:</p>
 <pre>
-SimpleCursorAdapter adapter = new SimpleCursorAdapter(this, 
+SimpleCursorAdapter adapter = new SimpleCursorAdapter(this,
         R.layout.person_name_and_number, cursor, fromColumns, toViews, 0);
 ListView listView = getListView();
 listView.setAdapter(adapter);
@@ -490,7 +490,7 @@
     }
 };
 
-listView.setOnItemClickListener(mMessageClickedHandler); 
+listView.setOnItemClickListener(mMessageClickedHandler);
 </pre>
 
 
diff --git a/docs/html/images/tools/projectview01.png b/docs/html/images/tools/projectview01.png
new file mode 100644
index 0000000..90589fb
--- /dev/null
+++ b/docs/html/images/tools/projectview01.png
Binary files differ
diff --git a/docs/html/images/tools/projectview03.png b/docs/html/images/tools/projectview03.png
new file mode 100644
index 0000000..f527ff1
--- /dev/null
+++ b/docs/html/images/tools/projectview03.png
Binary files differ
diff --git a/docs/html/preview/tv/ui/recommendations.jd b/docs/html/preview/tv/ui/recommendations.jd
index 2c78064..a2ff55c 100644
--- a/docs/html/preview/tv/ui/recommendations.jd
+++ b/docs/html/preview/tv/ui/recommendations.jd
@@ -9,7 +9,6 @@
     <li><a href="#service">Create a Recommendations Service</a></li>
     <li><a href="#build">Build Recommendations</a></li>
     <li><a href="#run-service">Run Recommendations Service</a></li>
-    <li><a href="#DesignLandscapeLayouts">Design Landscape Layouts</a></li>
   </ol>
 
 </div>
diff --git a/docs/html/reference/renderscript/rs__matrix_8rsh.html b/docs/html/reference/renderscript/rs__matrix_8rsh.html
index 69cc373..3b8e047 100644
--- a/docs/html/reference/renderscript/rs__matrix_8rsh.html
+++ b/docs/html/reference/renderscript/rs__matrix_8rsh.html
@@ -3,7 +3,7 @@
 <head>
 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
 
-<title>/usr/local/google/home/srhines/android_trees/jb-mr2-dev/frameworks/rs/scriptc/rs_matrix.rsh File Reference</title>
+<title>frameworks/rs/scriptc/rs_matrix.rsh File Reference</title>
 <link href="tabs.css" rel="stylesheet" type="text/css"/>
 <link href="doxygen.css" rel="stylesheet" type="text/css" />
 
@@ -27,18 +27,18 @@
   <div class="summary">
 <a href="#func-members">Functions</a>  </div>
   <div class="headertitle">
-<div class="title">/usr/local/google/home/srhines/android_trees/jb-mr2-dev/frameworks/rs/scriptc/rs_matrix.rsh File Reference</div>  </div>
+<div class="title">frameworks/rs/scriptc/rs_matrix.rsh File Reference</div>  </div>
 </div>
 <div class="contents">
 <table class="memberdecls">
 <tr><td colspan="2"><h2><a name="func-members"></a>
 Functions</h2></td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad6ea242218e0f1a031f754df0317e6e7">rsMatrixSet</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ab69543f85a673f23fbb5f893e5824395">rsMatrixSet</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a0a85c8d3607f1b75019f6991c5b19fca">rsMatrixSet</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, float v)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a22e983b67d3089c5cb97032e249ca335">rsMatrixGet</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad485084684991796cffdd8a008557569">rsMatrixGet</a> (const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aaa86b029d5c5c15fead5338bba02e4c3">rsMatrixGet</a> (const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aca88832ed720e301780152c60884393e">rsMatrixSet</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a08a247cdf2e70e78310bf04f9ecd5144">rsMatrixSet</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#af9707d7be5945bf55ed53683624176ff">rsMatrixSet</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, float v)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#af26fdbf8b8f0ed5d1b53f62b2aef5110">rsMatrixGet</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#acfebfc7b97e7282b78cd9c65b791932a">rsMatrixGet</a> (const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a683b4537b98103c50cc66780dfe8cd69">rsMatrixGet</a> (const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a5b31e83553efa947db2198674d5db043">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad2954a5ac11d2370227296be89e92471">rsMatrixLoadIdentity</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr>
@@ -65,9 +65,9 @@
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float left, float right, float bottom, float top, float near, float far)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, float fovy, float aspect, float near, float far)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a2f11c3d7cc34ddce90ba785b93af8da2">rsMatrixMultiply</a> (const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a88ae2ed203769cb4a7917f84f6c1a2e2">rsMatrixMultiply</a> (const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in)</td></tr>
-<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a8d81a7143d5d45f60f7e91f955579bab">rsMatrixMultiply</a> (const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a47b6abbf32ffaf77bb13d96c3f05779f">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m, <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a716bc2d29b80eb25388aba3ba8845aef">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *m, <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in)</td></tr>
+<tr><td class="memItemLeft" align="right" valign="top">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m, <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *m)</td></tr>
@@ -75,16 +75,30 @@
 <tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="rs__matrix_8rsh.html#a49164dd4d4e85b212196028b1fd89dc1">rsMatrixTranspose</a> (<a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *m)</td></tr>
 </table>
 <hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
-<div class="textblock"><p>Matrix routines. </p>
+<div class="textblock"><p>Matrix functions. </p>
+<p>These functions let you manipulate square matrices of rank 2x2, 3x3, and 4x4. They are particularly useful for graphical transformations and are compatible with OpenGL.</p>
+<p>A few general notes:</p>
+<ul>
+<li>We use a zero-based index for rows and columns. E.g. the last element of a <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> is found at (3, 3).</li>
+</ul>
+<ul>
+<li>RenderScript uses column-based vectors. Transforming a vector is done by postmultiplying the vector, e.g. <em>(matrix * vector)</em>, as provided by <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</li>
+</ul>
+<ul>
+<li>To create a transformation matrix that performs two transformations at once, multiply the two source matrices, with the first transformation as the right argument. E.g. to create a transformation matrix that applies the transformation <em>s1</em> followed by <em>s2</em>, call rsMatrixLoadMultiply(&amp;combined, &amp;s2, &amp;s1). This derives from <em>s2 * (s1 * v)</em>, which is <em>(s2 * s1) * v</em>.</li>
+</ul>
+<ul>
+<li>We have two style of functions to create transformation matrices: rsMatrixLoad<em>Transformation</em> and rsMatrix<em>Transformation</em>. The former style simply stores the transformation matrix in the first argument. The latter modifies a pre-existing transformation matrix so that the new transformation happens first. E.g. if you call <a class="el" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a> on a matrix that already does a scaling, the resulting matrix when applied to a vector will first do the translation then the scaling. </li>
+</ul>
 
 <p>Definition in file <a class="el" href="rs__matrix_8rsh_source.html">rs_matrix.rsh</a>.</p>
 </div><hr/><h2>Function Documentation</h2>
-<a class="anchor" id="a22e983b67d3089c5cb97032e249ca335"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="a22e983b67d3089c5cb97032e249ca335" args="(const rs_matrix4x4 *m, uint32_t row, uint32_t col)" -->
+<a class="anchor" id="af26fdbf8b8f0ed5d1b53f62b2aef5110"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="af26fdbf8b8f0ed5d1b53f62b2aef5110" args="(const rs_matrix4x4 *m, uint32_t col, uint32_t row)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">float rsMatrixGet </td>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
           <td>(</td>
           <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -93,13 +107,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>&#160;</td>
+          <td class="paramname"><em>row</em>&#160;</td>
         </tr>
         <tr>
           <td></td>
@@ -109,25 +123,26 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Get one element of a matrix.</p>
+<p>Returns one element of a matrix.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td>The matrix to read from </td></tr>
-    <tr><td class="paramname">row</td><td></td></tr>
-    <tr><td class="paramname">col</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to extract the element from. </td></tr>
+    <tr><td class="paramname">col</td><td>The zero-based column of the element to be extracted. </td></tr>
+    <tr><td class="paramname">row</td><td>The zero-based row of the element to extracted.</td></tr>
   </table>
   </dd>
 </dl>
+<dl class="warning"><dt><b>Warning:</b></dt><dd>The order of the column and row parameters may be unexpected.</dd></dl>
 <dl class="return"><dt><b>Returns:</b></dt><dd>float </dd></dl>
 
 </div>
 </div>
-<a class="anchor" id="ad485084684991796cffdd8a008557569"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="ad485084684991796cffdd8a008557569" args="(const rs_matrix3x3 *m, uint32_t row, uint32_t col)" -->
+<a class="anchor" id="acfebfc7b97e7282b78cd9c65b791932a"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="acfebfc7b97e7282b78cd9c65b791932a" args="(const rs_matrix3x3 *m, uint32_t col, uint32_t row)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">float rsMatrixGet </td>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
           <td>(</td>
           <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -136,13 +151,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>&#160;</td>
+          <td class="paramname"><em>row</em>&#160;</td>
         </tr>
         <tr>
           <td></td>
@@ -156,12 +171,12 @@
 
 </div>
 </div>
-<a class="anchor" id="aaa86b029d5c5c15fead5338bba02e4c3"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="aaa86b029d5c5c15fead5338bba02e4c3" args="(const rs_matrix2x2 *m, uint32_t row, uint32_t col)" -->
+<a class="anchor" id="a683b4537b98103c50cc66780dfe8cd69"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixGet" ref="a683b4537b98103c50cc66780dfe8cd69" args="(const rs_matrix2x2 *m, uint32_t col, uint32_t row)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">float rsMatrixGet </td>
+          <td class="memname">_RS_RUNTIME float rsMatrixGet </td>
           <td>(</td>
           <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -170,13 +185,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>&#160;</td>
+          <td class="paramname"><em>row</em>&#160;</td>
         </tr>
         <tr>
           <td></td>
@@ -204,10 +219,11 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Returns true if the matrix was successfully inversed</p>
+<p>Inverts a matrix in place.</p>
+<p>Returns true if the matrix was successfully inversed.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to invert. </td></tr>
   </table>
   </dd>
 </dl>
@@ -228,10 +244,11 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Returns true if the matrix was successfully inversed and transposed.</p>
+<p>Inverts and transpose a matrix in place.</p>
+<p>The matrix is first inverted then transposed. Returns true if the matrix was successfully inverted.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr>
   </table>
   </dd>
 </dl>
@@ -263,9 +280,11 @@
 </div>
 <div class="memdoc">
 <p>Set the elements of a matrix from an array of floats.</p>
+<p>The array of floats should be in row-major order, i.e. the element a <em>row 0, column 0</em> should be first, followed by the element at <em>row 0, column 1</em>, etc.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">v</td><td>The array of values to set the matrix to. These arrays should be 4, 9, or 16 floats long, depending on the matrix size. </td></tr>
   </table>
   </dd>
 </dl>
@@ -352,7 +371,20 @@
       </table>
 </div>
 <div class="memdoc">
-<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
+<p>Set the elements of a matrix from another matrix.</p>
+<p>If the source matrix is smaller than the destination, the rest of the destination is filled with elements of the identity matrix. E.g. loading a <a class="el" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> into a <a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> will give:</p>
+ <table>
+ <tr><td>m00</td><td>m01</td><td>0.0</td><td>0.0</td></tr>
+ <tr><td>m10</td><td>m11</td><td>0.0</td><td>0.0</td></tr>
+ <tr><td>0.0</td><td>0.0</td><td>1.0</td><td>0.0</td></tr>
+ <tr><td>0.0</td><td>0.0</td><td>0.0</td><td>1.0</td></tr>
+ </table><dl><dt><b>Parameters:</b></dt><dd>
+  <table class="params">
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">v</td><td>The source matrix. </td></tr>
+  </table>
+  </dd>
+</dl>
 
 </div>
 </div>
@@ -408,13 +440,7 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Set the elements of a matrix from another matrix.</p>
-<dl><dt><b>Parameters:</b></dt><dd>
-  <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-  </table>
-  </dd>
-</dl>
+<p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
 
 </div>
 </div>
@@ -528,10 +554,13 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Load an Frustum projection matrix constructed from the 6 planes</p>
+<p>Load a frustum projection matrix.</p>
+<p>Constructs a frustum projection matrix, transforming the box identified by the six clipping planes <em>left, right, bottom, top, near, far</em>.</p>
+<p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
+<p>See <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
     <tr><td class="paramname">left</td><td></td></tr>
     <tr><td class="paramname">right</td><td></td></tr>
     <tr><td class="paramname">bottom</td><td></td></tr>
@@ -561,7 +590,7 @@
 <p>Set the elements of a matrix to the identity matrix.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
   </table>
   </dd>
 </dl>
@@ -634,12 +663,15 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiply two matrix (lhs, rhs) and place the result in m.</p>
+<p>Multiply two matrices.</p>
+<p>Sets <em>m</em> to the matrix product of <em>lhs * rhs</em>.</p>
+<p>To combine two 4x4 transformaton matrices, multiply the second transformation matrix by the first transformation matrix. E.g. to create a transformation matrix that applies the transformation <em>s1</em> followed by <em>s2</em>, call rsMatrixLoadMultiply(&amp;combined, &amp;s2, &amp;s1).</p>
+<dl class="warning"><dt><b>Warning:</b></dt><dd>As of version 21, storing the result back into right matrix is not supported and will result in undefined behavior. Use rsMatrixMulitply instead. E.g. instead of doing rsMatrixLoadMultiply (&amp;m2r, &amp;m2r, &amp;m2l), use rsMatrixMultiply (&amp;m2r, &amp;m2l). rsMatrixLoadMultiply (&amp;m2l, &amp;m2r, &amp;m2l) works as expected.</dd></dl>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">lhs</td><td></td></tr>
-    <tr><td class="paramname">rhs</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">lhs</td><td>The left matrix of the product. </td></tr>
+    <tr><td class="paramname">rhs</td><td>The right matrix of the product. </td></tr>
   </table>
   </dd>
 </dl>
@@ -768,10 +800,13 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Load an Ortho projection matrix constructed from the 6 planes</p>
+<p>Load an orthographic projection matrix.</p>
+<p>Constructs an orthographic projection matrix, transforming the box identified by the six clipping planes <em>left, right, bottom, top, near, far</em> into a unit cube with a corner at <em>(-1, -1, -1)</em> and the opposite at <em>(1, 1, 1)</em>.</p>
+<p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
+<p>See <a href="https://en.wikipedia.org/wiki/Orthographic_projection">https://en.wikipedia.org/wiki/Orthographic_projection</a> and <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
     <tr><td class="paramname">left</td><td></td></tr>
     <tr><td class="paramname">right</td><td></td></tr>
     <tr><td class="paramname">bottom</td><td></td></tr>
@@ -826,14 +861,17 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Load an perspective projection matrix constructed from the 6 planes</p>
+<p>Load a perspective projection matrix.</p>
+<p>Constructs a perspective projection matrix, assuming a symmetrical field of view.</p>
+<p>To apply this projection to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
+<p>See <a href="https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf">https://www.opengl.org/documentation/specs/version2.0/glspec20.pdf</a></p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
     <tr><td class="paramname">fovy</td><td>Field of view, in degrees along the Y axis. </td></tr>
     <tr><td class="paramname">aspect</td><td>Ratio of x / y. </td></tr>
-    <tr><td class="paramname">near</td><td></td></tr>
-    <tr><td class="paramname">far</td><td></td></tr>
+    <tr><td class="paramname">near</td><td>The near clipping plane. </td></tr>
+    <tr><td class="paramname">far</td><td>The far clipping plane. </td></tr>
   </table>
   </dd>
 </dl>
@@ -883,13 +921,16 @@
 </div>
 <div class="memdoc">
 <p>Load a rotation matrix.</p>
+<p>This function creates a rotation matrix. The axis of rotation is the <em>(x, y, z)</em> vector.</p>
+<p>To rotate a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
+<p>See <a href="http://en.wikipedia.org/wiki/Rotation_matrix">http://en.wikipedia.org/wiki/Rotation_matrix</a> .</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">rot</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">rot</td><td>How much rotation to do, in degrees. </td></tr>
+    <tr><td class="paramname">x</td><td>The x component of the vector that is the axis of rotation. </td></tr>
+    <tr><td class="paramname">y</td><td>The y component of the vector that is the axis of rotation. </td></tr>
+    <tr><td class="paramname">z</td><td>The z component of the vector that is the axis of rotation. </td></tr>
   </table>
   </dd>
 </dl>
@@ -933,12 +974,14 @@
 </div>
 <div class="memdoc">
 <p>Load a scale matrix.</p>
+<p>This function creates a scaling matrix, where each component of a vector is multiplied by a number. This number can be negative.</p>
+<p>To scale a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">x</td><td>The multiple to scale the x components by. </td></tr>
+    <tr><td class="paramname">y</td><td>The multiple to scale the y components by. </td></tr>
+    <tr><td class="paramname">z</td><td>The multiple to scale the z components by. </td></tr>
   </table>
   </dd>
 </dl>
@@ -982,12 +1025,14 @@
 </div>
 <div class="memdoc">
 <p>Load a translation matrix.</p>
+<p>This function creates a translation matrix, where a number is added to each element of a vector.</p>
+<p>To translate a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to set. </td></tr>
+    <tr><td class="paramname">x</td><td>The number to add to each x component. </td></tr>
+    <tr><td class="paramname">y</td><td>The number to add to each y component. </td></tr>
+    <tr><td class="paramname">z</td><td>The number to add to each z component. </td></tr>
   </table>
   </dd>
 </dl>
@@ -1018,11 +1063,13 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiply the matrix m by rhs and place the result back into m.</p>
+<p>Multiply a matrix into another one.</p>
+<p>Sets <em>m</em> to the matrix product <em>m * rhs</em>.</p>
+<p>When combining two 4x4 transformation matrices using this function, the resulting matrix will correspond to performing the <em>rhs</em> transformation first followed by the original <em>m</em> transformation.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td>(lhs) </td></tr>
-    <tr><td class="paramname">rhs</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The left matrix of the product and the matrix to be set. </td></tr>
+    <tr><td class="paramname">rhs</td><td>The right matrix of the product. </td></tr>
   </table>
   </dd>
 </dl>
@@ -1085,14 +1132,14 @@
 
 </div>
 </div>
-<a class="anchor" id="a2f11c3d7cc34ddce90ba785b93af8da2"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a2f11c3d7cc34ddce90ba785b93af8da2" args="(const rs_matrix4x4 *m, float4 in)" -->
+<a class="anchor" id="a47b6abbf32ffaf77bb13d96c3f05779f"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a47b6abbf32ffaf77bb13d96c3f05779f" args="(rs_matrix4x4 *m, float4 in)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname"><a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> rsMatrixMultiply </td>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> rsMatrixMultiply </td>
           <td>(</td>
-          <td class="paramtype">const <a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
         </tr>
         <tr>
@@ -1109,19 +1156,24 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiply a vector by a matrix and return the result vector. API version 14+</p>
+<p>Multiply a vector by a matrix.</p>
+<p>Returns the post-multiplication of the vector by the matrix, ie. <em>m * in</em>.</p>
+<p>When multiplying a <em>float3</em> to a <em><a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a></em>, the vector is expanded with (1).</p>
+<p>When multiplying a <em>float2</em> to a <em><a class="el" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a></em>, the vector is expanded with (0, 1).</p>
+<p>When multiplying a <em>float2</em> to a <em><a class="el" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a></em>, the vector is expanded with (0).</p>
+<p>This function is available in API version 10-13. Starting with API 14, the function takes a const matrix as the first argument.</p>
 <p>This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. </p>
 
 </div>
 </div>
-<a class="anchor" id="a88ae2ed203769cb4a7917f84f6c1a2e2"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a88ae2ed203769cb4a7917f84f6c1a2e2" args="(const rs_matrix3x3 *m, float3 in)" -->
+<a class="anchor" id="a716bc2d29b80eb25388aba3ba8845aef"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a716bc2d29b80eb25388aba3ba8845aef" args="(rs_matrix3x3 *m, float3 in)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname"><a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> rsMatrixMultiply </td>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> rsMatrixMultiply </td>
           <td>(</td>
-          <td class="paramtype">const <a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
         </tr>
         <tr>
@@ -1142,14 +1194,14 @@
 
 </div>
 </div>
-<a class="anchor" id="a8d81a7143d5d45f60f7e91f955579bab"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a8d81a7143d5d45f60f7e91f955579bab" args="(const rs_matrix2x2 *m, float2 in)" -->
+<a class="anchor" id="a4d9a8bb7c3f5d67b14fa349bdd531d13"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixMultiply" ref="a4d9a8bb7c3f5d67b14fa349bdd531d13" args="(rs_matrix2x2 *m, float2 in)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname"><a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> rsMatrixMultiply </td>
+          <td class="memname">_RS_RUNTIME <a class="el" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> rsMatrixMultiply </td>
           <td>(</td>
-          <td class="paramtype">const <a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
+          <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
         </tr>
         <tr>
@@ -1212,14 +1264,16 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiple matrix m with a rotation matrix</p>
+<p>Multiply the matrix <em>m</em> with a rotation matrix.</p>
+<p>This function modifies a transformation matrix to first do a rotation. The axis of rotation is the <em>(x, y, z)</em> vector.</p>
+<p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">rot</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr>
+    <tr><td class="paramname">rot</td><td>How much rotation to do, in degrees. </td></tr>
+    <tr><td class="paramname">x</td><td>The x component of the vector that is the axis of rotation. </td></tr>
+    <tr><td class="paramname">y</td><td>The y component of the vector that is the axis of rotation. </td></tr>
+    <tr><td class="paramname">z</td><td>The z component of the vector that is the axis of rotation. </td></tr>
   </table>
   </dd>
 </dl>
@@ -1262,25 +1316,27 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiple matrix m with a scale matrix</p>
+<p>Multiply the matrix <em>m</em> with a scaling matrix.</p>
+<p>This function modifies a transformation matrix to first do a scaling. When scaling, each component of a vector is multiplied by a number. This number can be negative.</p>
+<p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr>
+    <tr><td class="paramname">x</td><td>The multiple to scale the x components by. </td></tr>
+    <tr><td class="paramname">y</td><td>The multiple to scale the y components by. </td></tr>
+    <tr><td class="paramname">z</td><td>The multiple to scale the z components by. </td></tr>
   </table>
   </dd>
 </dl>
 
 </div>
 </div>
-<a class="anchor" id="ad6ea242218e0f1a031f754df0317e6e7"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="ad6ea242218e0f1a031f754df0317e6e7" args="(rs_matrix4x4 *m, uint32_t row, uint32_t col, float v)" -->
+<a class="anchor" id="aca88832ed720e301780152c60884393e"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="aca88832ed720e301780152c60884393e" args="(rs_matrix4x4 *m, uint32_t col, uint32_t row, float v)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">void rsMatrixSet </td>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
           <td>(</td>
           <td class="paramtype"><a class="el" href="structrs__matrix4x4.html">rs_matrix4x4</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -1289,13 +1345,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>, </td>
+          <td class="paramname"><em>row</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
@@ -1311,26 +1367,27 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Set one element of a matrix.</p>
+<p>Set an element of a matrix.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td>The matrix to be set </td></tr>
-    <tr><td class="paramname">row</td><td></td></tr>
-    <tr><td class="paramname">col</td><td></td></tr>
-    <tr><td class="paramname">v</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix that will be modified. </td></tr>
+    <tr><td class="paramname">col</td><td>The zero-based column of the element to be set. </td></tr>
+    <tr><td class="paramname">row</td><td>The zero-based row of the element to be set. </td></tr>
+    <tr><td class="paramname">v</td><td>The value to set.</td></tr>
   </table>
   </dd>
 </dl>
+<dl class="warning"><dt><b>Warning:</b></dt><dd>The order of the column and row parameters may be unexpected.</dd></dl>
 <dl class="return"><dt><b>Returns:</b></dt><dd>void </dd></dl>
 
 </div>
 </div>
-<a class="anchor" id="ab69543f85a673f23fbb5f893e5824395"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="ab69543f85a673f23fbb5f893e5824395" args="(rs_matrix3x3 *m, uint32_t row, uint32_t col, float v)" -->
+<a class="anchor" id="a08a247cdf2e70e78310bf04f9ecd5144"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="a08a247cdf2e70e78310bf04f9ecd5144" args="(rs_matrix3x3 *m, uint32_t col, uint32_t row, float v)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">void rsMatrixSet </td>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
           <td>(</td>
           <td class="paramtype"><a class="el" href="structrs__matrix3x3.html">rs_matrix3x3</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -1339,13 +1396,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>, </td>
+          <td class="paramname"><em>row</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
@@ -1365,12 +1422,12 @@
 
 </div>
 </div>
-<a class="anchor" id="a0a85c8d3607f1b75019f6991c5b19fca"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="a0a85c8d3607f1b75019f6991c5b19fca" args="(rs_matrix2x2 *m, uint32_t row, uint32_t col, float v)" -->
+<a class="anchor" id="af9707d7be5945bf55ed53683624176ff"></a><!-- doxytag: member="rs_matrix.rsh::rsMatrixSet" ref="af9707d7be5945bf55ed53683624176ff" args="(rs_matrix2x2 *m, uint32_t col, uint32_t row, float v)" -->
 <div class="memitem">
 <div class="memproto">
       <table class="memname">
         <tr>
-          <td class="memname">void rsMatrixSet </td>
+          <td class="memname">_RS_RUNTIME void rsMatrixSet </td>
           <td>(</td>
           <td class="paramtype"><a class="el" href="structrs__matrix2x2.html">rs_matrix2x2</a> *&#160;</td>
           <td class="paramname"><em>m</em>, </td>
@@ -1379,13 +1436,13 @@
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>row</em>, </td>
+          <td class="paramname"><em>col</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
           <td></td>
           <td class="paramtype"><a class="el" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a>&#160;</td>
-          <td class="paramname"><em>col</em>, </td>
+          <td class="paramname"><em>row</em>, </td>
         </tr>
         <tr>
           <td class="paramkey"></td>
@@ -1441,13 +1498,15 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Multiple matrix m with a translation matrix</p>
+<p>Multiply the matrix <em>m</em> with a translation matrix.</p>
+<p>This function modifies a transformation matrix to first do a translation. When translating, a number is added to each component of a vector.</p>
+<p>To apply this combined transformation to a vector, multiply the vector by the created matrix using <a class="el" href="rs__matrix_8rsh.html#a4d9a8bb7c3f5d67b14fa349bdd531d13">rsMatrixMultiply</a>.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
-    <tr><td class="paramname">x</td><td></td></tr>
-    <tr><td class="paramname">y</td><td></td></tr>
-    <tr><td class="paramname">z</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to modify. </td></tr>
+    <tr><td class="paramname">x</td><td>The number to add to each x component. </td></tr>
+    <tr><td class="paramname">y</td><td>The number to add to each y component. </td></tr>
+    <tr><td class="paramname">z</td><td>The number to add to each z component. </td></tr>
   </table>
   </dd>
 </dl>
@@ -1468,10 +1527,10 @@
       </table>
 </div>
 <div class="memdoc">
-<p>Transpose the matrix m.</p>
+<p>Transpose the matrix m in place.</p>
 <dl><dt><b>Parameters:</b></dt><dd>
   <table class="params">
-    <tr><td class="paramname">m</td><td></td></tr>
+    <tr><td class="paramname">m</td><td>The matrix to transpose. </td></tr>
   </table>
   </dd>
 </dl>
diff --git a/docs/html/reference/renderscript/rs__matrix_8rsh_source.html b/docs/html/reference/renderscript/rs__matrix_8rsh_source.html
index c1aaeb2..77144bd 100644
--- a/docs/html/reference/renderscript/rs__matrix_8rsh_source.html
+++ b/docs/html/reference/renderscript/rs__matrix_8rsh_source.html
@@ -3,7 +3,7 @@
 <head>
 <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
 
-<title>/usr/local/google/home/srhines/android_trees/jb-mr2-dev/frameworks/rs/scriptc/rs_matrix.rsh Source File</title>
+<title>frameworks/rs/scriptc/rs_matrix.rsh Source File</title>
 <link href="tabs.css" rel="stylesheet" type="text/css"/>
 <link href="doxygen.css" rel="stylesheet" type="text/css" />
 
@@ -24,7 +24,7 @@
   </div>
 <div class="header">
   <div class="headertitle">
-<div class="title">/usr/local/google/home/srhines/android_trees/jb-mr2-dev/frameworks/rs/scriptc/rs_matrix.rsh</div>  </div>
+<div class="title">frameworks/rs/scriptc/rs_matrix.rsh</div>  </div>
 </div>
 <div class="contents">
 <a href="rs__matrix_8rsh.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
@@ -43,129 +43,128 @@
 <a name="l00014"></a>00014 <span class="comment"> * limitations under the License.</span>
 <a name="l00015"></a>00015 <span class="comment"> */</span>
 <a name="l00016"></a>00016 
-<a name="l00023"></a>00023 <span class="preprocessor">#ifndef __RS_MATRIX_RSH__</span>
-<a name="l00024"></a>00024 <span class="preprocessor"></span><span class="preprocessor">#define __RS_MATRIX_RSH__</span>
-<a name="l00025"></a>00025 <span class="preprocessor"></span>
-<a name="l00036"></a>00036 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00037"></a>00037 <a class="code" href="rs__matrix_8rsh.html#ad6ea242218e0f1a031f754df0317e6e7">rsMatrixSet</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
-<a name="l00041"></a>00041 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00042"></a>00042 <a class="code" href="rs__matrix_8rsh.html#ad6ea242218e0f1a031f754df0317e6e7">rsMatrixSet</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
-<a name="l00046"></a>00046 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00047"></a>00047 <a class="code" href="rs__matrix_8rsh.html#ad6ea242218e0f1a031f754df0317e6e7">rsMatrixSet</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <span class="keywordtype">float</span> v);
-<a name="l00048"></a>00048 
-<a name="l00058"></a>00058 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
-<a name="l00059"></a>00059 <a class="code" href="rs__matrix_8rsh.html#a22e983b67d3089c5cb97032e249ca335">rsMatrixGet</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
-<a name="l00063"></a>00063 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
-<a name="l00064"></a>00064 <a class="code" href="rs__matrix_8rsh.html#a22e983b67d3089c5cb97032e249ca335">rsMatrixGet</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
-<a name="l00068"></a>00068 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
-<a name="l00069"></a>00069 <a class="code" href="rs__matrix_8rsh.html#a22e983b67d3089c5cb97032e249ca335">rsMatrixGet</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col);
-<a name="l00070"></a>00070 
-<a name="l00076"></a>00076 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
-<a name="l00080"></a>00080 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
-<a name="l00084"></a>00084 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
-<a name="l00085"></a>00085 
-<a name="l00091"></a>00091 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <span class="keywordtype">float</span> *v);
-<a name="l00095"></a>00095 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <span class="keywordtype">float</span> *v);
-<a name="l00099"></a>00099 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <span class="keywordtype">float</span> *v);
-<a name="l00103"></a>00103 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *v);
-<a name="l00107"></a>00107 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
-<a name="l00108"></a>00108 
-<a name="l00114"></a>00114 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
-<a name="l00118"></a>00118 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
-<a name="l00122"></a>00122 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
-<a name="l00123"></a>00123 
-<a name="l00133"></a>00133 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00134"></a>00134 <a class="code" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rsMatrixLoadRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00135"></a>00135 
-<a name="l00144"></a>00144 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00145"></a>00145 <a class="code" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rsMatrixLoadScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00146"></a>00146 
-<a name="l00155"></a>00155 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00156"></a>00156 <a class="code" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rsMatrixLoadTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00157"></a>00157 
-<a name="l00165"></a>00165 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00166"></a>00166 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *lhs, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
-<a name="l00170"></a>00170 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00171"></a>00171 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *lhs, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
-<a name="l00175"></a>00175 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00176"></a>00176 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *lhs, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
-<a name="l00177"></a>00177 
-<a name="l00184"></a>00184 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00185"></a>00185 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
-<a name="l00189"></a>00189 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00190"></a>00190 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
-<a name="l00194"></a>00194 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00195"></a>00195 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
-<a name="l00196"></a>00196 
-<a name="l00206"></a>00206 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00207"></a>00207 <a class="code" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rsMatrixRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00208"></a>00208 
-<a name="l00217"></a>00217 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00218"></a>00218 <a class="code" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rsMatrixScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00219"></a>00219 
-<a name="l00228"></a>00228 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00229"></a>00229 <a class="code" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
-<a name="l00230"></a>00230 
-<a name="l00242"></a>00242 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00243"></a>00243 <a class="code" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
-<a name="l00244"></a>00244 
-<a name="l00256"></a>00256 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00257"></a>00257 <a class="code" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
-<a name="l00258"></a>00258 
-<a name="l00268"></a>00268 extern <span class="keywordtype">void</span> __attribute__((overloadable))
-<a name="l00269"></a>00269 <a class="code" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a>* m, <span class="keywordtype">float</span> fovy, <span class="keywordtype">float</span> aspect, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
-<a name="l00270"></a>00270 
-<a name="l00271"></a>00271 <span class="preprocessor">#if !defined(RS_VERSION) || (RS_VERSION &lt; 14)</span>
-<a name="l00272"></a>00272 <span class="preprocessor"></span>
-<a name="l00276"></a>00276 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00277"></a>00277 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
-<a name="l00278"></a>00278 
-<a name="l00282"></a>00282 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00283"></a>00283 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00050"></a>00050 <span class="preprocessor">#ifndef __RS_MATRIX_RSH__</span>
+<a name="l00051"></a>00051 <span class="preprocessor"></span><span class="preprocessor">#define __RS_MATRIX_RSH__</span>
+<a name="l00052"></a>00052 <span class="preprocessor"></span>
+<a name="l00066"></a>00066 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00067"></a>00067 <a class="code" href="rs__matrix_8rsh.html#aca88832ed720e301780152c60884393e">rsMatrixSet</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <span class="keywordtype">float</span> v);
+<a name="l00071"></a>00071 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00072"></a>00072 <a class="code" href="rs__matrix_8rsh.html#aca88832ed720e301780152c60884393e">rsMatrixSet</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <span class="keywordtype">float</span> v);
+<a name="l00076"></a>00076 _RS_RUNTIME <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00077"></a>00077 <a class="code" href="rs__matrix_8rsh.html#aca88832ed720e301780152c60884393e">rsMatrixSet</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row, <span class="keywordtype">float</span> v);
+<a name="l00078"></a>00078 
+<a name="l00091"></a>00091 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00092"></a>00092 <a class="code" href="rs__matrix_8rsh.html#af26fdbf8b8f0ed5d1b53f62b2aef5110">rsMatrixGet</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row);
+<a name="l00096"></a>00096 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00097"></a>00097 <a class="code" href="rs__matrix_8rsh.html#af26fdbf8b8f0ed5d1b53f62b2aef5110">rsMatrixGet</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row);
+<a name="l00101"></a>00101 _RS_RUNTIME <span class="keywordtype">float</span> __attribute__((overloadable))
+<a name="l00102"></a>00102 <a class="code" href="rs__matrix_8rsh.html#af26fdbf8b8f0ed5d1b53f62b2aef5110">rsMatrixGet</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> col, <a class="code" href="rs__types_8rsh.html#a435d1572bf3f880d55459d9805097f62">uint32_t</a> row);
+<a name="l00103"></a>00103 
+<a name="l00109"></a>00109 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00113"></a>00113 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
+<a name="l00117"></a>00117 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a0ffd9de971cf10d0a663ff565be8d3cc">rsMatrixLoadIdentity</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
+<a name="l00118"></a>00118 
+<a name="l00130"></a>00130 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00134"></a>00134 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00138"></a>00138 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <span class="keywordtype">float</span> *v);
+<a name="l00156"></a>00156 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *v);
+<a name="l00160"></a>00160 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
+<a name="l00164"></a>00164 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
+<a name="l00168"></a>00168 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *v);
+<a name="l00172"></a>00172 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac380c4117e047da494a74f0dad20fab3">rsMatrixLoad</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *v);
+<a name="l00173"></a>00173 
+<a name="l00191"></a>00191 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00192"></a>00192 <a class="code" href="rs__matrix_8rsh.html#a268032f3ac6d766b1d7fe72a6cb50464">rsMatrixLoadRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00193"></a>00193 
+<a name="l00208"></a>00208 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00209"></a>00209 <a class="code" href="rs__matrix_8rsh.html#acaf51d1f9ad5041ce01fbf8b7c5923fd">rsMatrixLoadScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00210"></a>00210 
+<a name="l00225"></a>00225 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00226"></a>00226 <a class="code" href="rs__matrix_8rsh.html#a1b521c8a3d1260fa732cbf0a71af0e74">rsMatrixLoadTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00227"></a>00227 
+<a name="l00247"></a>00247 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00248"></a>00248 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *lhs, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
+<a name="l00252"></a>00252 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00253"></a>00253 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *lhs, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
+<a name="l00257"></a>00257 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00258"></a>00258 <a class="code" href="rs__matrix_8rsh.html#a79f14c4c0f5ecc1bbd0bf54da8b653ef">rsMatrixLoadMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *lhs, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
+<a name="l00259"></a>00259 
+<a name="l00272"></a>00272 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00273"></a>00273 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *rhs);
+<a name="l00277"></a>00277 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00278"></a>00278 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *rhs);
+<a name="l00282"></a>00282 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00283"></a>00283 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *rhs);
 <a name="l00284"></a>00284 
-<a name="l00288"></a>00288 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00289"></a>00289 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
-<a name="l00290"></a>00290 
-<a name="l00294"></a>00294 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
-<a name="l00295"></a>00295 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
-<a name="l00296"></a>00296 
-<a name="l00300"></a>00300 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
-<a name="l00301"></a>00301 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00300"></a>00300 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00301"></a>00301 <a class="code" href="rs__matrix_8rsh.html#ad5ed05ca4880397fb29615e3c6798de1">rsMatrixRotate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> rot, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
 <a name="l00302"></a>00302 
-<a name="l00306"></a>00306 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
-<a name="l00307"></a>00307 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
-<a name="l00308"></a>00308 <span class="preprocessor">#else</span>
-<a name="l00309"></a>00309 <span class="preprocessor"></span>
-<a name="l00313"></a>00313 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00314"></a>00314 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
-<a name="l00315"></a>00315 
-<a name="l00319"></a>00319 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00320"></a>00320 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
-<a name="l00321"></a>00321 
-<a name="l00325"></a>00325 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
-<a name="l00326"></a>00326 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
-<a name="l00327"></a>00327 
-<a name="l00331"></a>00331 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
-<a name="l00332"></a>00332 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
-<a name="l00333"></a>00333 
-<a name="l00337"></a>00337 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
-<a name="l00338"></a>00338 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
-<a name="l00339"></a>00339 
-<a name="l00343"></a>00343 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
-<a name="l00344"></a>00344 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
-<a name="l00345"></a>00345 <span class="preprocessor">#endif</span>
-<a name="l00346"></a>00346 <span class="preprocessor"></span>
-<a name="l00347"></a>00347 
-<a name="l00353"></a>00353 <span class="keyword">extern</span> <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
-<a name="l00354"></a>00354 
-<a name="l00360"></a>00360 extern <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
-<a name="l00361"></a>00361 
-<a name="l00367"></a>00367 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
-<a name="l00371"></a>00371 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
-<a name="l00375"></a>00375 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
-<a name="l00376"></a>00376 
-<a name="l00377"></a>00377 
-<a name="l00378"></a>00378 <span class="preprocessor">#endif</span>
+<a name="l00318"></a>00318 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00319"></a>00319 <a class="code" href="rs__matrix_8rsh.html#a94cc6b22bd1a6c07a9a1c1d21afb392c">rsMatrixScale</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00320"></a>00320 
+<a name="l00336"></a>00336 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00337"></a>00337 <a class="code" href="rs__matrix_8rsh.html#a4df5f9b5bb6044f3c3426f2f58b94405">rsMatrixTranslate</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> x, <span class="keywordtype">float</span> y, <span class="keywordtype">float</span> z);
+<a name="l00338"></a>00338 
+<a name="l00361"></a>00361 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00362"></a>00362 <a class="code" href="rs__matrix_8rsh.html#a4c59884a0e534dbbcdc5655842732d43">rsMatrixLoadOrtho</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00363"></a>00363 
+<a name="l00384"></a>00384 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00385"></a>00385 <a class="code" href="rs__matrix_8rsh.html#ad25760aaf01e95d0055237afab41bbb3">rsMatrixLoadFrustum</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> top, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00386"></a>00386 
+<a name="l00403"></a>00403 extern <span class="keywordtype">void</span> __attribute__((overloadable))
+<a name="l00404"></a>00404 <a class="code" href="rs__matrix_8rsh.html#aa404c34d7478f2921f7415d2da95d02b">rsMatrixLoadPerspective</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a>* m, <span class="keywordtype">float</span> fovy, <span class="keywordtype">float</span> aspect, <span class="keywordtype">float</span> near, <span class="keywordtype">float</span> far);
+<a name="l00405"></a>00405 
+<a name="l00406"></a>00406 <span class="preprocessor">#if !defined(RS_VERSION) || (RS_VERSION &lt; 14)</span>
+<a name="l00407"></a>00407 <span class="preprocessor"></span>
+<a name="l00421"></a>00421 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00422"></a>00422 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
+<a name="l00423"></a>00423 
+<a name="l00427"></a>00427 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00428"></a>00428 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00429"></a>00429 
+<a name="l00433"></a>00433 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00434"></a>00434 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00435"></a>00435 
+<a name="l00439"></a>00439 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00440"></a>00440 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00441"></a>00441 
+<a name="l00445"></a>00445 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00446"></a>00446 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00447"></a>00447 
+<a name="l00451"></a>00451 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
+<a name="l00452"></a>00452 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00453"></a>00453 <span class="preprocessor">#else</span>
+<a name="l00454"></a>00454 <span class="preprocessor"></span>
+<a name="l00467"></a>00467 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00468"></a>00468 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> in);
+<a name="l00469"></a>00469 
+<a name="l00473"></a>00473 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00474"></a>00474 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00475"></a>00475 
+<a name="l00479"></a>00479 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#adb5162dc168ddd471d948faa60b37c5e">float4</a> __attribute__((overloadable))
+<a name="l00480"></a>00480 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00481"></a>00481 
+<a name="l00485"></a>00485 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00486"></a>00486 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> in);
+<a name="l00487"></a>00487 
+<a name="l00491"></a>00491 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a0046fa0f208d0899adbcf1f8b5aafadd">float3</a> __attribute__((overloadable))
+<a name="l00492"></a>00492 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00493"></a>00493 
+<a name="l00497"></a>00497 _RS_RUNTIME <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> __attribute__((overloadable))
+<a name="l00498"></a>00498 <a class="code" href="rs__matrix_8rsh.html#a97953ab2606900a839e5816c619abe66">rsMatrixMultiply</a>(const <a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m, <a class="code" href="rs__types_8rsh.html#a5086d0fcb71f916c936af486ccf0dd41">float2</a> in);
+<a name="l00499"></a>00499 <span class="preprocessor">#endif</span>
+<a name="l00500"></a>00500 <span class="preprocessor"></span>
+<a name="l00501"></a>00501 
+<a name="l00509"></a>00509 <span class="keyword">extern</span> <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a00b6a334ba5ac94d84850f22ec9f4de5">rsMatrixInverse</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00510"></a>00510 
+<a name="l00519"></a>00519 extern <span class="keywordtype">bool</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#ac05080d52da2d99a759ef34fa0655e82">rsMatrixInverseTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00520"></a>00520 
+<a name="l00526"></a>00526 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix4x4.html" title="4x4 float matrix">rs_matrix4x4</a> *m);
+<a name="l00530"></a>00530 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix3x3.html" title="3x3 float matrix">rs_matrix3x3</a> *m);
+<a name="l00534"></a>00534 extern <span class="keywordtype">void</span> __attribute__((overloadable)) <a class="code" href="rs__matrix_8rsh.html#a88095c70f1550c760844b3e32e41a31a">rsMatrixTranspose</a>(<a class="code" href="structrs__matrix2x2.html" title="2x2 float matrix">rs_matrix2x2</a> *m);
+<a name="l00535"></a>00535 
+<a name="l00536"></a>00536 
+<a name="l00537"></a>00537 <span class="preprocessor">#endif</span>
 </pre></div></div>
 </div>
 
diff --git a/docs/html/sdk/installing/create-project.jd b/docs/html/sdk/installing/create-project.jd
index c0d523a..a7c12d4 100644
--- a/docs/html/sdk/installing/create-project.jd
+++ b/docs/html/sdk/installing/create-project.jd
@@ -76,7 +76,7 @@
 <img src="{@docRoot}images/tools/wizard7.png" alt="" width="750" height="509">
 <p class="img-caption"><strong>Figure 7.</strong> The default project structure for a mobile app.</p>
 
-<p>Now you are ready to develop your app. Fore more information, see the following links:</p>
+<p>Now you are ready to develop your app. For more information, see the following links:</p>
 
 <ul>
 <li><a href="{@docRoot}training/">Training Lessons</a></li>
diff --git a/docs/html/sdk/installing/installing-adt.jd b/docs/html/sdk/installing/installing-adt.jd
index 851827c..5a433d4 100644
--- a/docs/html/sdk/installing/installing-adt.jd
+++ b/docs/html/sdk/installing/installing-adt.jd
@@ -104,7 +104,7 @@
   </tr>
   <tr>
     <td>
-      <a href="http://dl.google.com/android/{@adtZipDownload}">{@adtZipDownload}</a>
+      <a href="https://dl.google.com/android/{@adtZipDownload}">{@adtZipDownload}</a>
     </td>
     <td>{@adtZipBytes} bytes</td>
     <td>{@adtZipChecksum}</td>
diff --git a/docs/html/sdk/installing/studio-androidview.jd b/docs/html/sdk/installing/studio-androidview.jd
new file mode 100644
index 0000000..09aeaba
--- /dev/null
+++ b/docs/html/sdk/installing/studio-androidview.jd
@@ -0,0 +1,55 @@
+page.title=Using the Android Project View
+
+@jd:body
+
+
+<p>The Android project view in Android Studio shows a flattened version of your project's structure
+that provides quick access to the key source files of Android projects and helps you work with
+the new <a href="{@docRoot}sdk/installing/studio-build.html">Gradle-based build system</a>. The
+Android project view:</p>
+
+<ul>
+<li>Groups the build files for all modules at the top level of the project hierarchy.</li>
+<li>Shows the most important source directories at the top level of the module hierarchy.</li>
+<li>Groups all the manifest files for each module.</li>
+<li>Shows resource files from all Gradle source sets.</li>
+<li>Groups resource files for different locales, orientations, and screen types in a single group
+per resource type.</li>
+</ul>
+
+<div style="float:right;margin-left:30px;width:240px">
+<img src="{@docRoot}images/tools/projectview01.png" alt="" width="220" height="264"/>
+<p class="img-caption"><strong>Figure 1:</strong> Show the Android project view.</p>
+</div>
+
+
+<h2 id="enable-view">Enable the Android Project View</h2>
+
+<p>The Android project view is not yet enabled by default. To show the Android project view,
+click <strong>Project</strong> and select <strong>Android</strong>, as shown in Figure 1.</p>
+
+
+<h2 id="project-view">Use the Android Project View</h2>
+
+<p>The Android project view shows all the build files at the top level of the project hierarchy
+under <strong>Gradle Scripts</strong>. Each project module appears as a folder at the top
+level of the project hierarchy and contains these three elements at the top level:</p>
+
+<ul>
+<li><code>java/</code> - Source files for the module.</li>
+<li><code>manifests/</code> - Manifest files for the module.</li>
+<li><code>res/</code> - Resource files for the module.</li>
+</ul>
+
+<p>Figure 2 shows how the Android project view groups all the instances of the
+<code>ic_launcher.png</code> resource for different screen densities under the same element.</p>
+
+<p class="note"><strong>Note:</strong> The Android project view shows a hierarchy that helps you
+work with Android projects by providing a flattened structure that highlights the most commonly
+used files while developing Android applications. However, the project structure on disk differs
+from this representation.</p>
+
+<img src="{@docRoot}images/tools/projectview03.png" alt=""
+     style="margin-top:10px" width="650" height="508"/>
+<p class="img-caption"><strong>Figure 2:</strong> The traditional project view (left) and the
+Android project view (right).</p>
\ No newline at end of file
diff --git a/docs/html/sdk/installing/studio.jd b/docs/html/sdk/installing/studio.jd
index e7f93bc..776e312 100644
--- a/docs/html/sdk/installing/studio.jd
+++ b/docs/html/sdk/installing/studio.jd
@@ -220,7 +220,7 @@
   <li>Lint tools to catch performance, usability, version compatibility, and other problems.</li>
   <li>ProGuard and app-signing capabilities.</li>
   <li>Built-in support for <a
-  href="https://developers.google.com/cloud/devtools/android_studio_templates/"
+  href="https://developers.google.com/cloud/mobile"
   class="external-link">Google Cloud Platform</a>, making it easy to integrate Google Cloud
   Messaging and App Engine.
 </ul>
@@ -251,36 +251,36 @@
     <td>Windows</td>
     <td>
   <a onclick="return onDownload(this)" id="win-studio"
-      href="http://dl.google.com/android/studio/install/0.8.0/android-studio-bundle-135.1245622-windows.exe">
-      android-studio-bundle-135.1245622-windows.exe
+      href="https://dl.google.com/android/studio/install/0.8.6/android-studio-bundle-135.1339820-windows.exe">
+      android-studio-bundle-135.1339820-windows.exe
       </a>
     </td>
-    <td>380000036 bytes</td>
-    <td>5720baef7d492f2df7398a38dae2fa92</td>
+    <td>379497130 bytes</td>
+    <td>024e002b8c8fa7dcd2ff69fd69e06e56</td>
   </tr>
 
   <tr>
     <td><nobr>Mac OS X</nobr></td>
     <td>
   <a onclick="return onDownload(this)" id="mac-studio"
-    href="http://dl.google.com/android/studio/install/0.8.0/android-studio-bundle-135.1245622-mac.dmg">
-    android-studio-bundle-135.1245622-mac.dmg
+    href="https://dl.google.com/android/studio/install/0.8.6/android-studio-bundle-135.1339820-mac.dmg">
+    android-studio-bundle-135.1339820-mac.dmg
     </a>
     </td>
-    <td>368451923 bytes</td>
-    <td>fa9da3625db44687576c5c4e8f96280e</td>
+    <td>368507143 bytes</td>
+    <td>4143f2aa556634eae91701965d88899b</td>
   </tr>
 
   <tr>
     <td>Linux</td>
     <td>
   <a onclick="return onDownload(this)" id="linux-studio"
-    href="http://dl.google.com/android/studio/install/0.8.0/android-studio-bundle-135.1245622-linux.tgz">
-    android-studio-bundle-135.1245622-linux.tgz
+    href="https://dl.google.com/android/studio/install/0.8.6/android-studio-bundle-135.1339820-linux.tgz">
+    android-studio-bundle-135.1339820-linux.tgz
     </a>
     </td>
-    <td>417756987 bytes</td>
-    <td>c70dd2e4035484b84f0ad0046a34f136</td>
+    <td>417631443 bytes</td>
+    <td>fa403762ecd0a5da87acbeff485f81cc</td>
   </tr>
   </table>
 
@@ -450,6 +450,17 @@
 <div class="toggle-content opened">
   <p><a href="#" onclick="return toggleContent(this)">
     <img src="{@docRoot}assets/images/triangle-opened.png" class="toggle-content-img"
+      alt=""/>Android Studio v0.8.6</a> <em>(August 2014)</em>
+  </p>
+
+  <div class="toggle-content-toggleme">
+    <p>See <a href="http://tools.android.com/recent">tools.android.com</a> for a full list of changes.</p>
+  </div>
+</div>
+
+<div class="toggle-content closed">
+  <p><a href="#" onclick="return toggleContent(this)">
+    <img src="{@docRoot}assets/images/triangle-closed.png" class="toggle-content-img"
       alt=""/>Android Studio v0.8.0</a> <em>(June 2014)</em>
   </p>
 
@@ -636,7 +647,7 @@
   if (os) {
     /* set up primary ACE download button */
     $('#download-ide-button').show();
-    $('#download-ide-button').append("Download Android Studio Beta <span class='small'>v0.8.0</span>"
+    $('#download-ide-button').append("Download Android Studio Beta <span class='small'>v0.8.6</span>"
         + "<br/> <span class='small'>with the Android SDK for " + os + "</span>");
     $('#download-ide-button').click(function() {return onDownload(this,true);}).attr('href', bundlename);
 
diff --git a/docs/html/tools/building/index.jd b/docs/html/tools/building/index.jd
index c64942f..c1f3019 100644
--- a/docs/html/tools/building/index.jd
+++ b/docs/html/tools/building/index.jd
@@ -79,3 +79,14 @@
     running on a device.</li>
   </ul>
 
+<p class="note"><b>Note:</b> Apps are limited to a 64K method reference limit. If your app reaches
+this limit, the build process outputs the following error message:
+
+<pre>Unable to execute dex: method ID not in [0, 0xffff]: 65536.</pre>
+
+To avoid this, you can
+<a href="http://android-developers.blogspot.com.es/2011/07/custom-class-loading-in-dalvik.html">load
+secondary dex files at runtime</a> and use
+<a href="http://developer.android.com/tools/help/proguard.html">ProGuard</a> to strip out unnecessary
+class references (Proguard only works when building in release mode).
+</p>
\ No newline at end of file
diff --git a/docs/html/tools/sdk/ndk/index.jd b/docs/html/tools/sdk/ndk/index.jd
index 71b15d5..e75f451 100644
--- a/docs/html/tools/sdk/ndk/index.jd
+++ b/docs/html/tools/sdk/ndk/index.jd
@@ -2,59 +2,59 @@
 page.template=sdk
 
 
-ndk.mac64_download=android-ndk32-r10-darwin-x86_64.tar.bz2
-ndk.mac64_bytes=411610468
-ndk.mac64_checksum=3ce1fa3dbe7a188f5d2640fd2f7ca944
+ndk.mac64_download=android-ndk32-r10b-darwin-x86_64.tar.bz2
+ndk.mac64_bytes=413652124
+ndk.mac64_checksum=7ca4a84e9c56c38acdafb007e7cd33c5
 
-ndk.mac32_download=android-ndk32-r10-darwin-x86.tar.bz2
-ndk.mac32_bytes=404768263
-ndk.mac32_checksum=1824eec1f6749b6cb7bb306a3b924c33
+ndk.mac32_download=android-ndk32-r10b-darwin-x86.tar.bz2
+ndk.mac32_bytes=406998070
+ndk.mac32_checksum=db3626b2c5f3245d90e2724f7bcf4c3e
 
-ndk.linux64_download=android-ndk32-r10-linux-x86_64.tar.bz2
-ndk.linux64_bytes=420671390
-ndk.linux64_checksum=e3ff629d212a8106a43415862fa39baf
+ndk.linux64_download=android-ndk32-r10b-linux-x86_64.tar.bz2
+ndk.linux64_bytes=422237011
+ndk.linux64_checksum=5c0f301aa789a1a747d5d2aeb8c69ef3
 
-ndk.linux32_download=android-ndk32-r10-linux-x86.tar.bz2
-ndk.linux32_bytes=420078216
-ndk.linux32_checksum=8d9a5faa6e77b43bfae0f169079b21c4
+ndk.linux32_download=android-ndk32-r10b-linux-x86.tar.bz2
+ndk.linux32_bytes=421052081
+ndk.linux32_checksum=e8f55daa5c9de7ab79aaaf5d7d751b69
 
-ndk.win64_download=android-ndk32-r10-windows-x86_64.zip
-ndk.win64_bytes=529850429
-ndk.win64_checksum=b11f9239344f7c377ed5b627f0fb236e
+ndk.win64_download=android-ndk32-r10b-windows-x86_64.zip
+ndk.win64_bytes=531912027
+ndk.win64_checksum=e4dd2e0c6f38e3ad936c366bdf6b1d4e
 
-ndk.win32_download=android-ndk32-r10-windows-x86.zip
-ndk.win32_bytes=500135685
-ndk.win32_checksum=0a3c01147abba945cc4ef5837519ec97
+ndk.win32_download=android-ndk32-r10b-windows-x86.zip
+ndk.win32_bytes=502720425
+ndk.win32_checksum=9fa4f19bca7edd6eefa63fe788737987
 
 
 
-ndk.mac64_64_download=android-ndk64-r10-darwin-x86_64.tar.bz2
-ndk.mac64_64_bytes=327740247
-ndk.mac64_64_checksum=72561b27acc6192a2e81b345ea128a20
+ndk.mac64_64_download=android-ndk64-r10b-darwin-x86_64.tar.bz2
+ndk.mac64_64_bytes=346423776
+ndk.mac64_64_checksum=5bae7feed20ebf0762c0baefe6b84b6d
 
-ndk.mac32_64_download=android-ndk64-r10-darwin-x86.tar.bz2
-ndk.mac32_64_bytes=323736411
-ndk.mac32_64_checksum=5bbaf9d8051ba5d2c0fff74cfd87c374
+ndk.mac32_64_download=android-ndk64-r10b-darwin-x86.tar.bz2
+ndk.mac32_64_bytes=344052876
+ndk.mac32_64_checksum=4447049ac2b5877176b9b6b1cf3bcdb2
 
-ndk.linux64_64_download=android-ndk64-r10-linux-x86_64.tar.bz2
-ndk.linux64_64_bytes=339708042
-ndk.linux64_64_checksum=737290195583268b7fbff4aa56465ab6
+ndk.linux64_64_download=android-ndk64-r10b-linux-x86_64.tar.bz2
+ndk.linux64_64_bytes=358835298
+ndk.linux64_64_checksum=2aa12a0d9a70bcab83e42d010a685136
 
-ndk.linux32_64_download=android-ndk64-r10-linux-x86.tar.bz2
-ndk.linux32_64_bytes=338544906
-ndk.linux32_64_checksum=bea5d027baeb948cbff6af840d26b80d
+ndk.linux32_64_download=android-ndk64-r10b-linux-x86.tar.bz2
+ndk.linux32_64_bytes=358060577
+ndk.linux32_64_checksum=b77eb583626d8c7f5c11e49181fd5eac
 
-ndk.win64_64_download=android-ndk64-r10-windows-x86_64.zip
-ndk.win64_64_bytes=417411195
-ndk.win64_64_checksum=91879ec85539b45313a21b9526b911a8
+ndk.win64_64_download=android-ndk64-r10b-windows-x86_64.zip
+ndk.win64_64_bytes=437152652
+ndk.win64_64_checksum=df39185e6c5a4d72eb9fca3f9aaabc46
 
-ndk.win32_64_download=android-ndk64-r10-windows-x86.zip
-ndk.win32_64_bytes=396751892
-ndk.win32_64_checksum=f79070ace2cde9ebf6a2e2be4a61ac7a
+ndk.win32_64_download=android-ndk64-r10b-windows-x86.zip
+ndk.win32_64_bytes=417290468
+ndk.win32_64_checksum=0f0324cb11f04e8b2641e5422ee39c81
 
-ndk.debug_info_download=android-ndk-r10-cxx-stl-libs-with-debug-info.zip
-ndk.debug_info_bytes=253198908
-ndk.debug_info_checksum=c2a90c43d17dbb5f0609cc8237491788
+ndk.debug_info_download=android-ndk-r10b-cxx-stl-libs-with-debug-info.zip
+ndk.debug_info_bytes=227302317
+ndk.debug_info_checksum=bed1bb855a41bdb572a804dbf6d45aa6
 
 
 page.title=Android NDK
@@ -357,15 +357,6 @@
 </div>
 </div>
 
-
-
-
-
-
-
-
-
-
  <div id="qv-wrapper">
     <div id="qv">
       <h2>In this document</h2>
@@ -418,7 +409,7 @@
 
 
 <p>With NDK revision 9 and higher, the release packages have been split to reduce download size.
-  The first download for each platform contains the default NDK toolchain. The second download
+  The first download for each platform contains the default NDK toolchain. The additional download
   contains legacy NDK toolchains for that platform, which is only required if you are not using
   the current, recommended toolchain for your NDK builds.</p>
 
@@ -426,10 +417,91 @@
 
 <p>The following sections provide information about releases of the NDK.</p>
 
+
 <div class="toggle-content opened">
  <p>
    <a href="#" onclick="return toggleContent(this)"> <img
      src="/assets/images/triangle-opened.png" class="toggle-content-img" alt=""
+   >Android NDK, Revision 10b</a> <em>(September 2014)</em>
+ </p>
+ <div class="toggle-content-toggleme">
+   <dl>
+
+        <dt>Important notes:</dt>
+     <dd>
+     <ul>
+      <li>Because of the 512MB size restriction on downloadable packages, the following 32-bit items are not in the 32-bit NDK download packages. Instead, they reside in the 64-bit ones:</li>
+      <ul>
+      <li>Android-L headers</li>
+      <li>GCC 4.9</li>
+      </ul>
+     <li>Currently, the only Renderscript support provided by the NDK is for 32-bit Renderscript with Android 4.4 (API level 19). You cannot build HelloComputeNDK (the only Renderscript sample) with any other combination of Renderscript (32- or 64-bit) and Android version.</li>
+     <li>To compile native-codec, you must use a 64-bit NDK package, which is where all the Android-L headers are located. </li>
+     </ul>
+     </dd>
+
+
+     <dt>Important bug fixes:</dt>
+     <dd>
+     <ul>
+     <li>Fixed gdb 7.6 in GCC 4.8/4.9. (Issues <a href="http://b.android.com/74112">74112</a> and <a href="http://b.android.com/74371">74371</a>.)</li>
+     <li>Fixed GCC 4.8/4.9 for x86, so that they no longer enable <code>-msse4.2</code> and <code>-mpopcnt</code> by default. (Issue <a href="http://b.android.com/73843">73843</a>.)</li>
+     </ul>
+     </dd>
+
+     <dt>Other bug fixes:</dt>
+     <dd>
+     <ul>
+     <li>Removed <code>stdio.h</code> from the <code>include-fixed/</code> directories of all versions of GCC. (Issue <a href="http://b.android.com/73728">73728</a>.)</li>
+     <li>Removed duplicate header files from the Windows packages in the <code>platforms/android-L/arch-*/usr/include/linux/netfilter*/</code> directories. (Issue <a href="https://code.google.com/p/android/issues/detail?id=73704">73704</a>.)</li>
+     <li>Fixed a problem that prevented Clang from building HelloComputeNDK.</li>
+     <li>Fixed atexit. (Issue <a href="http://b.android.com/66595">66595</a>.)</li>
+     <li>Made various fixes to the docs in <code>docs/</code> and <code>sources/third_party/googletest/README.NDK</code>. (Issue <a href="http://b.android.com/74069">74069</a>.)</li>
+     <li>Made the following fixes to the Android-L headers:</li>
+     <ol>
+     <li>Added the following functions to <code>ctype.h</code> and <code>wchar.h</code>: <code>dn_expand()</code>, <code>grantpt()</code>, <code> inet_nsap_addr()</code>, <code>inet_nsap_ntoa()</code>, <code>insque()</code>, <code>nsdispatch()</code>, <code>posix_openpt()</code>, <code>__pthread_cleanup_pop()</code>, <code>__pthread_cleanup_push()</code>, <code>remque()</code>, <code>setfsgid()</code>, <code>setfsuid()</code>, <code>splice()</code>, <code>tee()</code>, <code>twalk()</code> (Issue <a href = "http://b.android.com/73719">73719</a>), and 42 <code>*_l()</code> functions.</li>
+
+    <li>Renamed <code>cmsg_nxthdr</code> to <code>__cmsg_nxthdr</code>.</li>
+
+    <li>Removed <code>__libc_malloc_dispatch</code>.</li>
+
+    <li>Changed the <code>ptrace()</code> prototype to <code>long ptrace(int, ...);</code>.</li>
+
+    <li>Removed <code>sha1.h</code>.</li>
+
+    <li>Extended <code>android_dlextinfo</code> in <code>android/dlext.h</code>.</li>
+
+    <li>Annotated <code>__NDK_FPABI__</code> for functions receiving or returning float- or double-type values in <code>stdlib.h</code>, <code>time.h</code>, <code>wchar.h</code>, and <code>complex.h</code>.</li>
+    </ol>
+     </ul>
+     </dd>
+
+     <dt>Other changes:</dt>
+     <dd>
+     <ul>
+        <li>Updated <code>mipsel-linux-android-4.9</code> and <code>mips64el-linux-android-4.9</code>, implementing a new multilib directory layout, and providing support for gdb-7.7</li>
+        <li>Enhanced <code>cpu-features</code> to detect more arm64 features.  (Change list <a href="https://android-review.googlesource.com/#/c/100339">100339</a>.)</li>
+     </dd>
+     </ul>
+
+
+
+   </dl>
+ </div>
+</div>
+
+
+
+
+
+
+
+
+
+<div class="toggle-content closed">
+ <p>
+   <a href="#" onclick="return toggleContent(this)"> <img
+     src="/assets/images/triangle-closed.png" class="toggle-content-img" alt=""
    >Android NDK, Revision 10</a> <em>(July 2014)</em>
  </p>
  <div class="toggle-content-toggleme">
@@ -442,7 +514,7 @@
            <li>GCC 4.9 is the default compiler for 64-bit ABIs. Clang is currently version 3.4.
 <code>NDK_TOOLCHAIN_VERSION=clang</code>
       may not work for arm64-v8a and mips64.</li>
-           <li>Android API level L is the first level with 64-bit support.  Note that this API
+           <li>Android-L is the first level with 64-bit support.  Note that this API
 level is a temporary one, and only for L-preview. An actual API level number will replace it at
 L-release.</li>
            <li>This release includes now includes <code>all32</code> and <code>all64</code>
@@ -479,7 +551,7 @@
            <li>For ndk-build, enable 32-bit, GCC 4.9 building either by adding
 <code>NDK_TOOLCHAIN_VERSION=4.9</code> to <code>Application.mk</code>, or exporting it as an
 environment variable from the command line.</li>
-           <li>For a standalone toolchain, use the <code> --toolchain=</code> option in the
+           <li>For a standalone toolchain, use the <code>--toolchain=</code> option in the
 <code>make-standalone-toolchain.sh</code> script. For example: <code>--toolchain=arm-linux-androideabi-4.9.</code></li>
         </ul>
         <li>Upgraded GDB to version 7.6 in GCC 4.8/4.9 and x86*. Since GDB is still at version GDB-7.3.x in
diff --git a/docs/html/tools/testing/testing_accessibility.jd b/docs/html/tools/testing/testing_accessibility.jd
index daf9b36..20948fa 100644
--- a/docs/html/tools/testing/testing_accessibility.jd
+++ b/docs/html/tools/testing/testing_accessibility.jd
@@ -179,7 +179,7 @@
 </p>
 
 <p>For more information about using TalkBack, see
-<a href="http://support.google.com/nexus/bin/answer.py?hl=en&answer=2700928">Use TalkBack</a>.</p>
+<a href="https://support.google.com/accessibility/android/topic/3529932">TalkBack</a>.</p>
 
 <h4 id="testing-ebt">Testing with Explore by Touch</h4>
 
@@ -207,8 +207,7 @@
 </ol>
 
 <p>For more information about using the Explore by Touch features, see
-<a href="http://support.google.com/nexus/bin/answer.py?hl=en&answer=2700722">Use Explore by
-Touch</a>.</p>
+<a href="https://support.google.com/accessibility/android/answer/6006598">Touch Exploration</a>.</p>
 
 <h3 id="test-navigation">Testing focus navigation</h3>
 
@@ -231,7 +230,7 @@
 
 <p>Gesture navigation is an accessibility navigation mode that allows users to navigate Android
   devices and applications using specific
-  <a href="http://support.google.com/nexus/bin/answer.py?hl=en&answer=2700718">gestures</a>. This
+  <a href="https://support.google.com/accessibility/android/answer/6006598">gestures</a>. This
   navigation mode is available on Android 4.1 (API Level 16) and higher.</p>
 
 <p class="note"><strong>Note:</strong> Accessibility gestures provide a different navigation path
@@ -248,8 +247,7 @@
 </ul>
 
 <p>For more information about using Explore by Touch accessibility gestures, see
-<a href="http://support.google.com/android/bin/topic.py?hl=en&topic=2492346">Accessibility
-gestures</a>.</p>
+<a href="https://support.google.com/accessibility/android/answer/6006598">Touch Exploration</a>.</p>
 
 <p class="note">
   <strong>Note:</strong> Accessibility services other than TalkBack may map accessibility gestures
diff --git a/docs/html/tools/tools_toc.cs b/docs/html/tools/tools_toc.cs
index 93e5976..8eb9cbf 100644
--- a/docs/html/tools/tools_toc.cs
+++ b/docs/html/tools/tools_toc.cs
@@ -24,6 +24,8 @@
           Creating a Project</a></li>
       <li><a href="<?cs var:toroot ?>sdk/installing/studio-tips.html">
           Tips and Tricks</a></li>
+      <li><a href="<?cs var:toroot ?>sdk/installing/studio-androidview.html">
+          Using the Android Project View</a></li>
       <li><a href="<?cs var:toroot ?>sdk/installing/studio-layout.html">
           Using the Layout Editor</a></li>
       <li><a href="<?cs var:toroot ?>sdk/installing/studio-build.html">
diff --git a/docs/html/training/efficient-downloads/redundant_redundant.jd b/docs/html/training/efficient-downloads/redundant_redundant.jd
index 4bf9af9..674298a 100644
--- a/docs/html/training/efficient-downloads/redundant_redundant.jd
+++ b/docs/html/training/efficient-downloads/redundant_redundant.jd
@@ -30,8 +30,8 @@
 <p>The most fundamental way to reduce your downloads is to download only what you need. In terms of data, that means implementing REST APIs that allow you to specify query criteria that limit the returned data by using parameters such as the time of your last update.</p>
 
 <p>Similarly, when downloading images, it's good practice to reduce the size of the images server-side, rather than downloading full-sized images that are reduced on the client.</p>
- 
-<h2 id="LocalCache">Cache Files Locally</h2> 
+
+<h2 id="LocalCache">Cache Files Locally</h2>
 
 <p>Another important technique is to avoid downloading duplicate data. You can do this by aggressive caching. Always cache static resources, including on-demand downloads such as full size images, for as long as reasonably possible. On-demand resources should be stored separately to enable you to regularly flush your on-demand cache to manage its size.</p>
 
@@ -60,11 +60,11 @@
 
 <p>Alternatively, you can use the managed / secure application cache. Note that this internal cache may be flushed when the system is running low on available storage.</p>
 
-<pre>Context.getCache();</pre>
+<pre>Context.getCacheDir();</pre>
 
 <p>Files stored in either cache location will be erased when the application is uninstalled.</p>
 
-<h2 id="ResponseCache">Use the HttpURLConnection Response Cache</h2> 
+<h2 id="ResponseCache">Use the HttpURLConnection Response Cache</h2>
 
 <p>Android 4.0 added a response cache to {@code HttpURLConnection}. You can enable HTTP response caching on supported devices using reflection as follows:</p>
 
diff --git a/docs/html/training/location/retrieve-current.jd b/docs/html/training/location/retrieve-current.jd
index 99e475f..f079040 100644
--- a/docs/html/training/location/retrieve-current.jd
+++ b/docs/html/training/location/retrieve-current.jd
@@ -167,13 +167,12 @@
                     "Google Play services is available.");
             // Continue
             return true;
-        // Google Play services was not available for some reason
+        // Google Play services was not available for some reason.
+        // resultCode holds the error code.
         } else {
-            // Get the error code
-            int errorCode = connectionResult.getErrorCode();
             // Get the error dialog from Google Play services
             Dialog errorDialog = GooglePlayServicesUtil.getErrorDialog(
-                    errorCode,
+                    resultCode,
                     this,
                     CONNECTION_FAILURE_RESOLUTION_REQUEST);
 
diff --git a/docs/html/training/wearables/data-layer/assets.jd b/docs/html/training/wearables/data-layer/assets.jd
index 52ccbb0..5dc11cb 100644
--- a/docs/html/training/wearables/data-layer/assets.jd
+++ b/docs/html/training/wearables/data-layer/assets.jd
@@ -91,7 +91,7 @@
   for (DataEvent event : dataEvents) {
     if (event.getType() == DataEvent.TYPE_CHANGED &&
         event.getDataItem().getUri().getPath().equals("/image")) {
-      DataMapItem dataMapItem = DataMapItem.fromDataItem(dataItem); 
+      DataMapItem dataMapItem = DataMapItem.fromDataItem(event.getDataItem());
       Asset profileAsset = dataMapItem.getDataMap().getAsset("profileImage");
       Bitmap bitmap = loadBitmapFromAsset(profileAsset);
       // Do something with the bitmap
diff --git a/docs/html/training/wearables/data-layer/index.jd b/docs/html/training/wearables/data-layer/index.jd
index bac7d3e..39d6561 100644
--- a/docs/html/training/wearables/data-layer/index.jd
+++ b/docs/html/training/wearables/data-layer/index.jd
@@ -28,7 +28,7 @@
 
   <dt><b>Messages</b></dt>
   <dd>The <a href="{@docRoot}reference/com/google/android/gms/wearable/MessageApi.html"><code>MessageApi</code></a> class
-  can send messages designed for "fire-and-forget" commands, such as controlling a handheld's
+  can send messages and is good for remote procedure calls (RPC), such as controlling a handheld's
   media player from the wearable or starting an intent on the wearable from the handheld.
   The system always delivers the message when the handheld and wearable are connected and delivers
   an error when the devices are disconnected. Messages are great for one-way requests or for a
diff --git a/docs/html/training/wearables/data-layer/messages.jd b/docs/html/training/wearables/data-layer/messages.jd
index 15e552d..71f1bb1 100644
--- a/docs/html/training/wearables/data-layer/messages.jd
+++ b/docs/html/training/wearables/data-layer/messages.jd
@@ -23,8 +23,8 @@
 </ul>
 <p>
 Unlike data items, there is no syncing between the handheld and wearable apps.
-Messages are a one-way communication mechanism that's meant for
-"fire-and-forget" tasks, such as sending a message to the wearable
+Messages are a one-way communication mechanism that's good for remote procedure calls (RPC),
+such as sending a message to the wearable
 to start an activity. You can also use messages in request/response model
 where one side of the connection sends a message, does some work,
 sends back a response message.</p>
diff --git a/docs/html/training/wearables/notifications/creating.jd b/docs/html/training/wearables/notifications/creating.jd
index d6ad34a..9398f96 100644
--- a/docs/html/training/wearables/notifications/creating.jd
+++ b/docs/html/training/wearables/notifications/creating.jd
@@ -208,9 +208,12 @@
         <b>.setStyle(bigStyle);</b>
 </pre>
 
-<p>Notice that you can add a large background image to any notification using the
+<p>Notice that you can add a large icon image to any notification using the
 {@link android.support.v4.app.NotificationCompat.Builder#setLargeIcon setLargeIcon()}
-method. For more information about designing notifications with large images, see the
+method. However, these icons appear as large background images on a wearable and do not look
+good as they are scaled up to fit the wearable screen. To add a wearable-specific background image
+to a notification, see <a href="#AddWearableFeatures">Add Wearable Features For a Notification</a>.
+For more information about designing notifications with large images, see the
 <a href="{@docRoot}design/wear/index.html">Design Principles of Android
 Wear</a>.</p>
 
@@ -244,7 +247,8 @@
 // Create a WearableExtender to add functionality for wearables
 NotificationCompat.WearableExtender wearableExtender =
         new NotificationCompat.WearableExtender()
-        .setHintHideIcon(true);
+        .setHintHideIcon(true)
+        .setBackground(mBitmap);
 
 // Create a NotificationCompat.Builder to build a standard notification
 // then extend it with the WearableExtender
@@ -257,12 +261,21 @@
 </pre>
 
 <p>The
-  {@link android.support.v4.app.NotificationCompat.WearableExtender#setHintHideIcon setHintHideIcon()}
-  method is just one example of new notification features available with
-  {@link android.support.v4.app.NotificationCompat.WearableExtender}.
-</p>
+{@link android.support.v4.app.NotificationCompat.WearableExtender#setHintHideIcon setHintHideIcon()}
+and {@link android.support.v4.app.NotificationCompat.WearableExtender#setBackground setBackground()}
+methods are just two examples of new notification features available with
+{@link android.support.v4.app.NotificationCompat.WearableExtender}.</p>
 
-<p>If you ever need to read wearable-specifc options at a later time, use the corresponding get
+<p class="note"><strong>Note:</strong> The bitmap that you use with
+{@link android.support.v4.app.NotificationCompat.WearableExtender#setBackground setBackground()}
+should have a resolution of 400x400 for non-scrolling backgrounds and 640x400 for backgrounds
+that support parallax scrolling. Place these bitmap images in the <code>res/drawable-nodpi</code>
+directory of your handheld app. Place other non-bitmap resources for wearable notifications, such
+as those used with the
+{@link android.support.v4.app.NotificationCompat.WearableExtender#setContentIcon setContentIcon()}
+method, in the <code>res/drawable-hdpi</code> directory of your handheld app.</p>
+
+<p>If you ever need to read wearable-specific options at a later time, use the corresponding get
 method for the option. This example calls the
 {@link android.support.v4.app.NotificationCompat.WearableExtender#getHintHideIcon()} method to
 get whether or not this notification hides the icon:
@@ -272,6 +285,7 @@
 boolean hintHideIcon = wearableExtender.getHintHideIcon();
 </pre>
 
+
 <h2 id="Deliver">Deliver the Notification</h2>
 <p>When you want to deliver your notifications, always use the
   {@link android.support.v4.app.NotificationManagerCompat} API instead of
diff --git a/docs/html/wear/images/partners/sony.png b/docs/html/wear/images/partners/sony.png
new file mode 100644
index 0000000..e097fbb
--- /dev/null
+++ b/docs/html/wear/images/partners/sony.png
Binary files differ
diff --git a/docs/html/wear/index.jd b/docs/html/wear/index.jd
index 5dd7690..c372395 100644
--- a/docs/html/wear/index.jd
+++ b/docs/html/wear/index.jd
@@ -228,6 +228,9 @@
             <div class="col-4">
               <img src="/wear/images/partners/samsung.png" alt="Samsung">
             </div>
+            <div class="col-4">
+              <img src="/wear/images/partners/sony.png" alt="Sony">
+            </div>
           </div>
         </div> <!-- end .wrap -->
       </div>
diff --git a/graphics/java/android/graphics/Bitmap.java b/graphics/java/android/graphics/Bitmap.java
index 4d0bb75..3090ffd 100644
--- a/graphics/java/android/graphics/Bitmap.java
+++ b/graphics/java/android/graphics/Bitmap.java
@@ -21,6 +21,7 @@
 import android.os.Parcelable;
 import android.os.Trace;
 import android.util.DisplayMetrics;
+import dalvik.system.VMRuntime;
 
 import java.io.OutputStream;
 import java.nio.Buffer;
@@ -122,15 +123,18 @@
         mIsMutable = isMutable;
         mRequestPremultiplied = requestPremultiplied;
         mBuffer = buffer;
+
         // we delete this in our finalizer
         mNativeBitmap = nativeBitmap;
-        mFinalizer = new BitmapFinalizer(nativeBitmap);
 
         mNinePatchChunk = ninePatchChunk;
         mNinePatchInsets = ninePatchInsets;
         if (density >= 0) {
             mDensity = density;
         }
+
+        int nativeAllocationByteCount = buffer == null ? getByteCount() : 0;
+        mFinalizer = new BitmapFinalizer(nativeBitmap, nativeAllocationByteCount);
     }
 
     /**
@@ -1574,8 +1578,17 @@
     private static class BitmapFinalizer {
         private final long mNativeBitmap;
 
-        BitmapFinalizer(long nativeBitmap) {
+        // Native memory allocated for the duration of the Bitmap,
+        // if pixel data allocated into native memory, instead of java byte[]
+        private final int mNativeAllocationByteCount;
+
+        BitmapFinalizer(long nativeBitmap, int nativeAllocationByteCount) {
             mNativeBitmap = nativeBitmap;
+            mNativeAllocationByteCount = nativeAllocationByteCount;
+
+            if (mNativeAllocationByteCount != 0) {
+                VMRuntime.getRuntime().registerNativeAllocation(mNativeAllocationByteCount);
+            }
         }
 
         @Override
@@ -1585,6 +1598,9 @@
             } catch (Throwable t) {
                 // Ignore
             } finally {
+                if (mNativeAllocationByteCount != 0) {
+                    VMRuntime.getRuntime().registerNativeFree(mNativeAllocationByteCount);
+                }
                 nativeDestructor(mNativeBitmap);
             }
         }
diff --git a/graphics/java/android/graphics/Canvas.java b/graphics/java/android/graphics/Canvas.java
index f3af8f6..f45c0cb 100644
--- a/graphics/java/android/graphics/Canvas.java
+++ b/graphics/java/android/graphics/Canvas.java
@@ -203,7 +203,7 @@
      */
     public void setBitmap(@Nullable Bitmap bitmap) {
         if (isHardwareAccelerated()) {
-            throw new RuntimeException("Can't set a bitmap device on a GL canvas");
+            throw new RuntimeException("Can't set a bitmap device on a HW accelerated canvas");
         }
 
         if (bitmap == null) {
@@ -243,10 +243,11 @@
     /** @hide */
     public void setHighContrastText(boolean highContrastText) {}
 
-    /**
-     * @hide
-     */
-    public void initializeLight(float lightX, float lightY, float lightZ, float lightRadius) {}
+    /** @hide */
+    public void insertReorderBarrier() {}
+
+    /** @hide */
+    public void insertInorderBarrier() {}
 
     /**
      * Return true if the device that the current layer draws into is opaque
@@ -410,10 +411,10 @@
      * @return       value to pass to restoreToCount() to balance this save()
      */
     public int saveLayer(@Nullable RectF bounds, @Nullable Paint paint, @Saveflags int saveFlags) {
-        return native_saveLayer(mNativeCanvasWrapper,
-                bounds.left, bounds.top, bounds.right, bounds.bottom,
-                paint != null ? paint.mNativePaint : 0,
-                saveFlags);
+        if (bounds == null) {
+            bounds = new RectF(getClipBounds());
+        }
+        return saveLayer(bounds.left, bounds.top, bounds.right, bounds.bottom, paint, saveFlags);
     }
 
     /**
@@ -456,17 +457,17 @@
      * @param saveFlags see _SAVE_FLAG constants
      * @return          value to pass to restoreToCount() to balance this call
      */
-    public int saveLayerAlpha(@NonNull RectF bounds, int alpha, @Saveflags int saveFlags) {
-        alpha = Math.min(255, Math.max(0, alpha));
-        return native_saveLayerAlpha(mNativeCanvasWrapper,
-                bounds.left, bounds.top, bounds.right, bounds.bottom,
-                alpha, saveFlags);
+    public int saveLayerAlpha(@Nullable RectF bounds, int alpha, @Saveflags int saveFlags) {
+        if (bounds == null) {
+            bounds = new RectF(getClipBounds());
+        }
+        return saveLayerAlpha(bounds.left, bounds.top, bounds.right, bounds.bottom, alpha, saveFlags);
     }
 
     /**
      * Convenience for saveLayerAlpha(bounds, alpha, {@link #ALL_SAVE_FLAG})
      */
-    public int saveLayerAlpha(@NonNull RectF bounds, int alpha) {
+    public int saveLayerAlpha(@Nullable RectF bounds, int alpha) {
         return saveLayerAlpha(bounds, alpha, ALL_SAVE_FLAG);
     }
 
@@ -475,6 +476,7 @@
      */
     public int saveLayerAlpha(float left, float top, float right, float bottom, int alpha,
             @Saveflags int saveFlags) {
+        alpha = Math.min(255, Math.max(0, alpha));
         return native_saveLayerAlpha(mNativeCanvasWrapper, left, top, right, bottom,
                                      alpha, saveFlags);
     }
diff --git a/graphics/java/android/graphics/FontFamily.java b/graphics/java/android/graphics/FontFamily.java
index 11d3165..b8b7e76 100644
--- a/graphics/java/android/graphics/FontFamily.java
+++ b/graphics/java/android/graphics/FontFamily.java
@@ -18,8 +18,6 @@
 
 import android.content.res.AssetManager;
 
-import java.io.File;
-
 /**
  * A family of typefaces with different styles.
  *
@@ -64,6 +62,10 @@
         return nAddFont(mNativePtr, path);
     }
 
+    public boolean addFontWeightStyle(String path, int weight, boolean style) {
+        return nAddFontWeightStyle(mNativePtr, path, weight, style);
+    }
+
     public boolean addFontFromAsset(AssetManager mgr, String path) {
         return nAddFontFromAsset(mNativePtr, mgr, path);
     }
@@ -71,6 +73,8 @@
     private static native long nCreateFamily(String lang, int variant);
     private static native void nUnrefFamily(long nativePtr);
     private static native boolean nAddFont(long nativeFamily, String path);
+    private static native boolean nAddFontWeightStyle(long nativeFamily, String path,
+            int weight, boolean isItalic);
     private static native boolean nAddFontFromAsset(long nativeFamily, AssetManager mgr,
             String path);
 }
diff --git a/graphics/java/android/graphics/FontListParser.java b/graphics/java/android/graphics/FontListParser.java
index a863a06..97081f9 100644
--- a/graphics/java/android/graphics/FontListParser.java
+++ b/graphics/java/android/graphics/FontListParser.java
@@ -33,23 +33,48 @@
  */
 public class FontListParser {
 
+    public static class Config {
+        Config() {
+            families = new ArrayList<Family>();
+            aliases = new ArrayList<Alias>();
+        }
+        public List<Family> families;
+        public List<Alias> aliases;
+    }
+
+    public static class Font {
+        Font(String fontName, int weight, boolean isItalic) {
+            this.fontName = fontName;
+            this.weight = weight;
+            this.isItalic = isItalic;
+        }
+        public String fontName;
+        public int weight;
+        public boolean isItalic;
+    }
+
+    public static class Alias {
+        public String name;
+        public String toName;
+        public int weight;
+    }
+
     public static class Family {
-        public Family(List<String> names, List<String> fontFiles, String lang, String variant) {
-            this.names = names;
-            this.fontFiles = fontFiles;
+        public Family(String name, List<Font> fonts, String lang, String variant) {
+            this.name = name;
+            this.fonts = fonts;
             this.lang = lang;
             this.variant = variant;
         }
 
-        public List<String> names;
-        // todo: need attributes for font files
-        public List<String> fontFiles;
+        public String name;
+        public List<Font> fonts;
         public String lang;
         public String variant;
     }
 
     /* Parse fallback list (no names) */
-    public static List<Family> parse(InputStream in) throws XmlPullParserException, IOException {
+    public static Config parse(InputStream in) throws XmlPullParserException, IOException {
         try {
             XmlPullParser parser = Xml.newPullParser();
             parser.setInput(in, null);
@@ -60,57 +85,59 @@
         }
     }
 
-    private static List<Family> readFamilies(XmlPullParser parser)
+    private static Config readFamilies(XmlPullParser parser)
             throws XmlPullParserException, IOException {
-        List<Family> families = new ArrayList<Family>();
+        Config config = new Config();
         parser.require(XmlPullParser.START_TAG, null, "familyset");
         while (parser.next() != XmlPullParser.END_TAG) {
             if (parser.getEventType() != XmlPullParser.START_TAG) continue;
             if (parser.getName().equals("family")) {
-                families.add(readFamily(parser));
+                config.families.add(readFamily(parser));
+            } else if (parser.getName().equals("alias")) {
+                config.aliases.add(readAlias(parser));
             } else {
                 skip(parser);
             }
         }
-        return families;
+        return config;
     }
 
     private static Family readFamily(XmlPullParser parser)
             throws XmlPullParserException, IOException {
-        List<String> names = null;
-        List<String> fontFiles = new ArrayList<String>();
-        String lang = null;
-        String variant = null;
+        String name = parser.getAttributeValue(null, "name");
+        String lang = parser.getAttributeValue(null, "lang");
+        String variant = parser.getAttributeValue(null, "variant");
+        List<Font> fonts = new ArrayList<Font>();
         while (parser.next() != XmlPullParser.END_TAG) {
             if (parser.getEventType() != XmlPullParser.START_TAG) continue;
             String tag = parser.getName();
-            if (tag.equals("fileset")) {
-                while (parser.next() != XmlPullParser.END_TAG) {
-                    if (parser.getEventType() != XmlPullParser.START_TAG) continue;
-                    if (parser.getName().equals("file")) {
-                        if (lang == null) {
-                            lang = parser.getAttributeValue(null, "lang");
-                        }
-                        if (variant == null) {
-                            variant = parser.getAttributeValue(null, "variant");
-                        }
-                        String filename = parser.nextText();
-                        String fullFilename = "/system/fonts/" + filename;
-                        fontFiles.add(fullFilename);
-                    }
-                }
-            } else if (tag.equals("nameset")) {
-                names = new ArrayList<String>();
-                while (parser.next() != XmlPullParser.END_TAG) {
-                    if (parser.getEventType() != XmlPullParser.START_TAG) continue;
-                    if (parser.getName().equals("name")) {
-                        String name = parser.nextText();
-                        names.add(name);
-                    }
-                }
+            if (tag.equals("font")) {
+                String weightStr = parser.getAttributeValue(null, "weight");
+                int weight = weightStr == null ? 400 : Integer.parseInt(weightStr);
+                boolean isItalic = "italic".equals(parser.getAttributeValue(null, "style"));
+                String filename = parser.nextText();
+                String fullFilename = "/system/fonts/" + filename;
+                fonts.add(new Font(fullFilename, weight, isItalic));
+            } else {
+                skip(parser);
             }
         }
-        return new Family(names, fontFiles, lang, variant);
+        return new Family(name, fonts, lang, variant);
+    }
+
+    private static Alias readAlias(XmlPullParser parser)
+            throws XmlPullParserException, IOException {
+        Alias alias = new Alias();
+        alias.name = parser.getAttributeValue(null, "name");
+        alias.toName = parser.getAttributeValue(null, "to");
+        String weightStr = parser.getAttributeValue(null, "weight");
+        if (weightStr == null) {
+            alias.weight = 400;
+        } else {
+            alias.weight = Integer.parseInt(weightStr);
+        }
+        skip(parser);  // alias tag is empty, ignore any contents and consume end tag
+        return alias;
     }
 
     private static void skip(XmlPullParser parser) throws XmlPullParserException, IOException {
diff --git a/graphics/java/android/graphics/Outline.java b/graphics/java/android/graphics/Outline.java
index 3177023..4bf0b71 100644
--- a/graphics/java/android/graphics/Outline.java
+++ b/graphics/java/android/graphics/Outline.java
@@ -18,15 +18,15 @@
 
 import android.annotation.NonNull;
 import android.graphics.drawable.Drawable;
-import android.view.View;
 
 /**
  * Defines a simple shape, used for bounding graphical regions.
  * <p>
- * Can be used with a View, or computed by a Drawable, to drive the shape of shadows cast by a
- * View, or to clip the contents of the View.
+ * Can be computed for a View, or computed by a Drawable, to drive the shape of
+ * shadows cast by a View, or to clip the contents of the View.
  *
- * @see View#setOutline(Outline)
+ * @see android.view.ViewOutlineProvider
+ * @see android.view.View#setOutlineProvider(android.view.ViewOutlineProvider)
  * @see Drawable#getOutline(Outline)
  */
 public final class Outline {
@@ -79,21 +79,27 @@
 
     /**
      * Returns whether the outline can be used to clip a View.
+     * <p>
+     * Currently, only Outlines that can be represented as a rectangle, circle,
+     * or round rect support clipping.
      *
-     * Currently, only outlines that can be represented as a rectangle, circle, or round rect
-     * support clipping.
-     *
-     * @see {@link View#setClipToOutline(boolean)}
+     * @see {@link android.view.View#setClipToOutline(boolean)}
      */
     public boolean canClip() {
         return !isEmpty() && mRect != null;
     }
 
     /**
-     * Sets the alpha represented by the Outline.
-     *
-     * Content producing a fully opaque (alpha = 1.0f) outline is assumed by the drawing system
-     * to fully cover content beneath it, meaning content beneath may be optimized away.
+     * Sets the alpha represented by the Outline - the degree to which the
+     * producer is guaranteed to be opaque over the Outline's shape.
+     * <p>
+     * An alpha value of <code>0.0f</code> either represents completely
+     * transparent content, or content that isn't guaranteed to fill the shape
+     * it publishes.
+     * <p>
+     * Content producing a fully opaque (alpha = <code>1.0f</code>) outline is
+     * assumed by the drawing system to fully cover content beneath it,
+     * meaning content beneath may be optimized away.
      */
     public void setAlpha(float alpha) {
         mAlpha = alpha;
@@ -130,7 +136,8 @@
     }
 
     /**
-     * Sets the Outline to the rounded rect defined by the input rect, and corner radius.
+     * Sets the Outline to the rounded rect defined by the input rect, and
+     * corner radius.
      */
     public void setRect(int left, int top, int right, int bottom) {
         setRoundRect(left, top, right, bottom, 0.0f);
@@ -145,7 +152,7 @@
 
     /**
      * Sets the Outline to the rounded rect defined by the input rect, and corner radius.
-     *
+     * <p>
      * Passing a zero radius is equivalent to calling {@link #setRect(int, int, int, int)}
      */
     public void setRoundRect(int left, int top, int right, int bottom, float radius) {
@@ -196,7 +203,8 @@
     }
 
     /**
-     * Sets the Constructs an Outline from a {@link android.graphics.Path#isConvex() convex path}.
+     * Sets the Constructs an Outline from a
+     * {@link android.graphics.Path#isConvex() convex path}.
      */
     public void setConvexPath(@NonNull Path convexPath) {
         if (convexPath.isEmpty()) {
diff --git a/graphics/java/android/graphics/Paint.java b/graphics/java/android/graphics/Paint.java
index 1c76d9c..652fe64 100644
--- a/graphics/java/android/graphics/Paint.java
+++ b/graphics/java/android/graphics/Paint.java
@@ -1109,9 +1109,16 @@
      * This draws a shadow layer below the main layer, with the specified
      * offset and color, and blur radius. If radius is 0, then the shadow
      * layer is removed.
+     * <p>
+     * Can be used to create a blurred shadow underneath text. Support for use
+     * with other drawing operations is constrained to the software rendering
+     * pipeline.
+     * <p>
+     * The alpha of the shadow will be the paint's alpha if the shadow color is
+     * opaque, or the alpha from the shadow color if not.
      */
-    public void setShadowLayer(float radius, float dx, float dy, int color) {
-      native_setShadowLayer(mNativePaint, radius, dx, dy, color);
+    public void setShadowLayer(float radius, float dx, float dy, int shadowColor) {
+      native_setShadowLayer(mNativePaint, radius, dx, dy, shadowColor);
     }
 
     /**
diff --git a/graphics/java/android/graphics/Picture.java b/graphics/java/android/graphics/Picture.java
index 5aa7c6a..d28c3d5 100644
--- a/graphics/java/android/graphics/Picture.java
+++ b/graphics/java/android/graphics/Picture.java
@@ -122,6 +122,11 @@
      * @param canvas  The picture is drawn to this canvas
      */
     public void draw(Canvas canvas) {
+        if (canvas.isHardwareAccelerated()) {
+            throw new IllegalArgumentException(
+                    "Picture playback is only supported on software canvas.");
+        }
+
         if (mRecordingCanvas != null) {
             endRecording();
         }
diff --git a/graphics/java/android/graphics/PorterDuffColorFilter.java b/graphics/java/android/graphics/PorterDuffColorFilter.java
index c078c1c..ff768b7 100644
--- a/graphics/java/android/graphics/PorterDuffColorFilter.java
+++ b/graphics/java/android/graphics/PorterDuffColorFilter.java
@@ -60,6 +60,8 @@
      * @see Color
      * @see #getColor()
      * @see #getMode()
+     *
+     * @hide
      */
     public void setColor(int color) {
         mColor = color;
@@ -84,6 +86,8 @@
      * @see PorterDuff
      * @see #getMode()
      * @see #getColor()
+     *
+     * @hide
      */
     public void setMode(PorterDuff.Mode mode) {
         mMode = mode;
@@ -95,5 +99,25 @@
         native_instance = native_CreatePorterDuffFilter(mColor, mMode.nativeInt);
     }
 
+    @Override
+    public boolean equals(Object object) {
+        if (this == object) {
+            return true;
+        }
+        if (object == null || getClass() != object.getClass()) {
+            return false;
+        }
+        final PorterDuffColorFilter other = (PorterDuffColorFilter) object;
+        if (mColor != other.mColor || mMode != other.mMode) {
+            return false;
+        }
+        return true;
+    }
+
+    @Override
+    public int hashCode() {
+        return 31 *  mMode.hashCode() + mColor;
+    }
+
     private static native long native_CreatePorterDuffFilter(int srcColor, int porterDuffMode);
 }
diff --git a/graphics/java/android/graphics/Shader.java b/graphics/java/android/graphics/Shader.java
index 265a564..6934955 100644
--- a/graphics/java/android/graphics/Shader.java
+++ b/graphics/java/android/graphics/Shader.java
@@ -28,8 +28,6 @@
      */
     private long native_instance;
 
-    private long native_with_local_matrix;
-
     /**
      * Initialization step that should be called by subclasses in their
      * constructors. Calling again may result in memory leaks.
@@ -80,24 +78,18 @@
      * Set the shader's local matrix. Passing null will reset the shader's
      * matrix to identity.
      *
-     * Starting with {@link android.os.Build.VERSION_CODES#L}, this does not
-     * modify any Paints which use this Shader. In order to modify the Paint,
-     * you need to call {@link Paint#setShader} again. Further, any {@link ComposeShader}s
-     * created with this Shader will be unaffected.
-     *
      * @param localM The shader's new local matrix, or null to specify identity
      */
     public void setLocalMatrix(Matrix localM) {
         mLocalMatrix = localM;
-        native_with_local_matrix = nativeSetLocalMatrix(native_instance,
-                native_with_local_matrix, localM == null ? 0 : localM.native_instance);
+        nativeSetLocalMatrix(native_instance, localM == null ? 0 : localM.native_instance);
     }
 
     protected void finalize() throws Throwable {
         try {
             super.finalize();
         } finally {
-            nativeDestructor(native_instance, native_with_local_matrix);
+            nativeDestructor(native_instance);
         }
     }
 
@@ -124,13 +116,9 @@
     }
 
     /* package */ long getNativeInstance() {
-        if (native_with_local_matrix != 0) {
-            return native_with_local_matrix;
-        }
         return native_instance;
     }
 
-    private static native void nativeDestructor(long native_shader, long native_with_local_matrix);
-    private static native long nativeSetLocalMatrix(long native_shader,
-            long native_with_local_matrix, long matrix_instance);
+    private static native void nativeDestructor(long native_shader);
+    private static native void nativeSetLocalMatrix(long native_shader, long matrix_instance);
 }
diff --git a/graphics/java/android/graphics/Typeface.java b/graphics/java/android/graphics/Typeface.java
index 06586ca..db42314 100644
--- a/graphics/java/android/graphics/Typeface.java
+++ b/graphics/java/android/graphics/Typeface.java
@@ -66,8 +66,7 @@
     static Map<String, Typeface> sSystemFontMap;
     static FontFamily[] sFallbackFonts;
 
-    static final String SYSTEM_FONTS_CONFIG = "system_fonts.xml";
-    static final String FALLBACK_FONTS_CONFIG = "fallback_fonts.xml";
+    static final String FONTS_CONFIG = "fonts.xml";
 
     /**
      * @hide
@@ -188,7 +187,7 @@
                 return createFromFamiliesWithDefault(families);
             }
         }
-        return null;
+        throw new RuntimeException("Font asset not found " + path);
     }
 
     /**
@@ -215,7 +214,7 @@
                 return createFromFamiliesWithDefault(families);
             }
         }
-        return null;
+        throw new RuntimeException("Font not found " + path);
     }
 
     /**
@@ -261,10 +260,9 @@
     }
 
     private static FontFamily makeFamilyFromParsed(FontListParser.Family family) {
-        // TODO: expand to handle attributes like lang and variant
         FontFamily fontFamily = new FontFamily(family.lang, family.variant);
-        for (String fontFile : family.fontFiles) {
-            fontFamily.addFont(fontFile);
+        for (FontListParser.Font font : family.fonts) {
+            fontFamily.addFontWeightStyle(font.fontName, font.weight, font.isItalic);
         }
         return fontFamily;
     }
@@ -277,48 +275,53 @@
     private static void init() {
         // Load font config and initialize Minikin state
         File systemFontConfigLocation = getSystemFontConfigLocation();
-        File systemConfigFilename = new File(systemFontConfigLocation, SYSTEM_FONTS_CONFIG);
-        File configFilename = new File(systemFontConfigLocation, FALLBACK_FONTS_CONFIG);
+        File configFilename = new File(systemFontConfigLocation, FONTS_CONFIG);
         try {
-            // TODO: throws an exception non-Minikin builds, to fail early;
-            // remove when Minikin-only
-            new FontFamily();
+            FileInputStream fontsIn = new FileInputStream(configFilename);
+            FontListParser.Config fontConfig = FontListParser.parse(fontsIn);
 
-            FileInputStream systemIn = new FileInputStream(systemConfigFilename);
-            List<FontListParser.Family> systemFontConfig = FontListParser.parse(systemIn);
-
-            FileInputStream fallbackIn = new FileInputStream(configFilename);
             List<FontFamily> familyList = new ArrayList<FontFamily>();
             // Note that the default typeface is always present in the fallback list;
             // this is an enhancement from pre-Minikin behavior.
-            familyList.add(makeFamilyFromParsed(systemFontConfig.get(0)));
-            for (Family f : FontListParser.parse(fallbackIn)) {
-                familyList.add(makeFamilyFromParsed(f));
+            for (int i = 0; i < fontConfig.families.size(); i++) {
+                Family f = fontConfig.families.get(i);
+                if (i == 0 || f.name == null) {
+                    familyList.add(makeFamilyFromParsed(f));
+                }
             }
             sFallbackFonts = familyList.toArray(new FontFamily[familyList.size()]);
             setDefault(Typeface.createFromFamilies(sFallbackFonts));
 
             Map<String, Typeface> systemFonts = new HashMap<String, Typeface>();
-            for (int i = 0; i < systemFontConfig.size(); i++) {
+            for (int i = 0; i < fontConfig.families.size(); i++) {
                 Typeface typeface;
-                Family f = systemFontConfig.get(i);
-                if (i == 0) {
-                    // The first entry is the default typeface; no sense in duplicating
-                    // the corresponding FontFamily.
-                    typeface = sDefaultTypeface;
-                } else {
-                    FontFamily fontFamily = makeFamilyFromParsed(f);
-                    FontFamily[] families = { fontFamily };
-                    typeface = Typeface.createFromFamiliesWithDefault(families);
+                Family f = fontConfig.families.get(i);
+                if (f.name != null) {
+                    if (i == 0) {
+                        // The first entry is the default typeface; no sense in
+                        // duplicating the corresponding FontFamily.
+                        typeface = sDefaultTypeface;
+                    } else {
+                        FontFamily fontFamily = makeFamilyFromParsed(f);
+                        FontFamily[] families = { fontFamily };
+                        typeface = Typeface.createFromFamiliesWithDefault(families);
+                    }
+                    systemFonts.put(f.name, typeface);
                 }
-                for (String name : f.names) {
-                    systemFonts.put(name, typeface);
+            }
+            for (FontListParser.Alias alias : fontConfig.aliases) {
+                Typeface base = systemFonts.get(alias.toName);
+                Typeface newFace = base;
+                int weight = alias.weight;
+                if (weight != 400) {
+                    newFace = new Typeface(nativeCreateWeightAlias(base.native_instance, weight));
                 }
+                systemFonts.put(alias.name, newFace);
             }
             sSystemFontMap = systemFonts;
 
         } catch (RuntimeException e) {
-            Log.w(TAG, "Didn't create default family (most likely, non-Minikin build)");
+            Log.w(TAG, "Didn't create default family (most likely, non-Minikin build)", e);
             // TODO: normal in non-Minikin case, remove or make error when Minikin-only
         } catch (FileNotFoundException e) {
             Log.e(TAG, "Error opening " + configFilename);
@@ -383,6 +386,7 @@
     }
 
     private static native long nativeCreateFromTypeface(long native_instance, int style);
+    private static native long nativeCreateWeightAlias(long native_instance, int weight);
     private static native void nativeUnref(long native_instance);
     private static native int  nativeGetStyle(long native_instance);
     private static native long nativeCreateFromArray(long[] familyArray);
diff --git a/graphics/java/android/graphics/drawable/AnimatedRotateDrawable.java b/graphics/java/android/graphics/drawable/AnimatedRotateDrawable.java
index 0bc4fdf..4c8b4f1 100644
--- a/graphics/java/android/graphics/drawable/AnimatedRotateDrawable.java
+++ b/graphics/java/android/graphics/drawable/AnimatedRotateDrawable.java
@@ -346,22 +346,24 @@
         private boolean mCanConstantState;
         private boolean mCheckedConstantState;
 
-        public AnimatedRotateState(AnimatedRotateState source, AnimatedRotateDrawable owner,
+        public AnimatedRotateState(AnimatedRotateState orig, AnimatedRotateDrawable owner,
                 Resources res) {
-            if (source != null) {
+            if (orig != null) {
                 if (res != null) {
-                    mDrawable = source.mDrawable.getConstantState().newDrawable(res);
+                    mDrawable = orig.mDrawable.getConstantState().newDrawable(res);
                 } else {
-                    mDrawable = source.mDrawable.getConstantState().newDrawable();
+                    mDrawable = orig.mDrawable.getConstantState().newDrawable();
                 }
                 mDrawable.setCallback(owner);
-                mDrawable.setLayoutDirection(source.mDrawable.getLayoutDirection());
-                mPivotXRel = source.mPivotXRel;
-                mPivotX = source.mPivotX;
-                mPivotYRel = source.mPivotYRel;
-                mPivotY = source.mPivotY;
-                mFramesCount = source.mFramesCount;
-                mFrameDuration = source.mFrameDuration;
+                mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+                mDrawable.setBounds(orig.mDrawable.getBounds());
+                mDrawable.setLevel(orig.mDrawable.getLevel());
+                mPivotXRel = orig.mPivotXRel;
+                mPivotX = orig.mPivotX;
+                mPivotYRel = orig.mPivotYRel;
+                mPivotY = orig.mPivotY;
+                mFramesCount = orig.mFramesCount;
+                mFrameDuration = orig.mFrameDuration;
                 mCanConstantState = mCheckedConstantState = true;
             }
         }
diff --git a/graphics/java/android/graphics/drawable/AnimatedVectorDrawable.java b/graphics/java/android/graphics/drawable/AnimatedVectorDrawable.java
index 00c92fa..49e8b9d 100644
--- a/graphics/java/android/graphics/drawable/AnimatedVectorDrawable.java
+++ b/graphics/java/android/graphics/drawable/AnimatedVectorDrawable.java
@@ -17,12 +17,17 @@
 import android.animation.Animator;
 import android.animation.AnimatorInflater;
 import android.animation.ValueAnimator;
+import android.annotation.NonNull;
+import android.content.res.ColorStateList;
 import android.content.res.Resources;
 import android.content.res.Resources.Theme;
 import android.content.res.TypedArray;
 import android.graphics.Canvas;
 import android.graphics.ColorFilter;
+import android.graphics.Outline;
+import android.graphics.PorterDuff;
 import android.graphics.Rect;
+import android.util.ArrayMap;
 import android.util.AttributeSet;
 import android.util.Log;
 
@@ -127,8 +132,9 @@
 
     private static final boolean DBG_ANIMATION_VECTOR_DRAWABLE = false;
 
-    private final AnimatedVectorDrawableState mAnimatedVectorState;
+    private AnimatedVectorDrawableState mAnimatedVectorState;
 
+    private boolean mMutated;
 
     public AnimatedVectorDrawable() {
         mAnimatedVectorState = new AnimatedVectorDrawableState(
@@ -137,7 +143,6 @@
 
     private AnimatedVectorDrawable(AnimatedVectorDrawableState state, Resources res,
             Theme theme) {
-        // TODO: Correctly handle the constant state for AVD.
         mAnimatedVectorState = new AnimatedVectorDrawableState(state);
         if (theme != null && canApplyTheme()) {
             applyTheme(theme);
@@ -145,14 +150,23 @@
     }
 
     @Override
+    public Drawable mutate() {
+        if (!mMutated && super.mutate() == this) {
+            mAnimatedVectorState = new AnimatedVectorDrawableState(mAnimatedVectorState);
+            mMutated = true;
+        }
+        return this;
+    }
+
+    @Override
     public ConstantState getConstantState() {
-        return null;
+        return mAnimatedVectorState;
     }
 
     @Override
     public void draw(Canvas canvas) {
         mAnimatedVectorState.mVectorDrawable.draw(canvas);
-        if (isRunning()) {
+        if (isStarted()) {
             invalidateSelf();
         }
     }
@@ -163,6 +177,16 @@
     }
 
     @Override
+    protected boolean onStateChange(int[] state) {
+        return mAnimatedVectorState.mVectorDrawable.setState(state);
+    }
+
+    @Override
+    protected boolean onLevelChange(int level) {
+        return mAnimatedVectorState.mVectorDrawable.setLevel(level);
+    }
+
+    @Override
     public int getAlpha() {
         return mAnimatedVectorState.mVectorDrawable.getAlpha();
     }
@@ -178,6 +202,43 @@
     }
 
     @Override
+    public void setTintList(ColorStateList tint) {
+        mAnimatedVectorState.mVectorDrawable.setTintList(tint);
+    }
+
+    @Override
+    public void setHotspot(float x, float y) {
+        mAnimatedVectorState.mVectorDrawable.setHotspot(x, y);
+    }
+
+    @Override
+    public void setHotspotBounds(int left, int top, int right, int bottom) {
+        mAnimatedVectorState.mVectorDrawable.setHotspotBounds(left, top, right, bottom);
+    }
+
+    @Override
+    public void setTintMode(PorterDuff.Mode tintMode) {
+        mAnimatedVectorState.mVectorDrawable.setTintMode(tintMode);
+    }
+
+    @Override
+    public boolean setVisible(boolean visible, boolean restart) {
+        mAnimatedVectorState.mVectorDrawable.setVisible(visible, restart);
+        return super.setVisible(visible, restart);
+    }
+
+    /** {@hide} */
+    @Override
+    public void setLayoutDirection(int layoutDirection) {
+        mAnimatedVectorState.mVectorDrawable.setLayoutDirection(layoutDirection);
+    }
+
+    @Override
+    public boolean isStateful() {
+        return mAnimatedVectorState.mVectorDrawable.isStateful();
+    }
+
+    @Override
     public int getOpacity() {
         return mAnimatedVectorState.mVectorDrawable.getOpacity();
     }
@@ -193,10 +254,16 @@
     }
 
     @Override
+    public void getOutline(@NonNull Outline outline) {
+        mAnimatedVectorState.mVectorDrawable.getOutline(outline);
+    }
+
+    @Override
     public void inflate(Resources res, XmlPullParser parser, AttributeSet attrs, Theme theme)
             throws XmlPullParserException, IOException {
 
         int eventType = parser.getEventType();
+        float pathErrorScale = 1;
         while (eventType != XmlPullParser.END_DOCUMENT) {
             if (eventType == XmlPullParser.START_TAG) {
                 final String tagName = parser.getName();
@@ -206,9 +273,11 @@
                     int drawableRes = a.getResourceId(
                             R.styleable.AnimatedVectorDrawable_drawable, 0);
                     if (drawableRes != 0) {
-                        mAnimatedVectorState.mVectorDrawable = (VectorDrawable) res.getDrawable(
+                        VectorDrawable vectorDrawable = (VectorDrawable) res.getDrawable(
                                 drawableRes, theme).mutate();
-                        mAnimatedVectorState.mVectorDrawable.setAllowCaching(false);
+                        vectorDrawable.setAllowCaching(false);
+                        pathErrorScale = vectorDrawable.getPixelSize();
+                        mAnimatedVectorState.mVectorDrawable = vectorDrawable;
                     }
                     a.recycle();
                 } else if (TARGET.equals(tagName)) {
@@ -220,7 +289,8 @@
                     int id = a.getResourceId(
                             R.styleable.AnimatedVectorDrawableTarget_animation, 0);
                     if (id != 0) {
-                        Animator objectAnimator = AnimatorInflater.loadAnimator(res, theme, id);
+                        Animator objectAnimator = AnimatorInflater.loadAnimator(res, theme, id,
+                                pathErrorScale);
                         setupAnimatorsForTarget(target, objectAnimator);
                     }
                     a.recycle();
@@ -252,14 +322,31 @@
         int mChangingConfigurations;
         VectorDrawable mVectorDrawable;
         ArrayList<Animator> mAnimators;
+        ArrayMap<Animator, String> mTargetNameMap;
 
         public AnimatedVectorDrawableState(AnimatedVectorDrawableState copy) {
             if (copy != null) {
                 mChangingConfigurations = copy.mChangingConfigurations;
-                // TODO: Make sure the constant state are handled correctly.
-                mVectorDrawable = new VectorDrawable();
-                mVectorDrawable.setAllowCaching(false);
-                mAnimators = new ArrayList<Animator>();
+                if (copy.mVectorDrawable != null) {
+                    mVectorDrawable = (VectorDrawable) copy.mVectorDrawable.getConstantState().newDrawable();
+                    mVectorDrawable.mutate();
+                    mVectorDrawable.setAllowCaching(false);
+                    mVectorDrawable.setBounds(copy.mVectorDrawable.getBounds());
+                }
+                if (copy.mAnimators != null) {
+                    final int numAnimators = copy.mAnimators.size();
+                    mAnimators = new ArrayList<Animator>(numAnimators);
+                    mTargetNameMap = new ArrayMap<Animator, String>(numAnimators);
+                    for (int i = 0; i < numAnimators; ++i) {
+                        Animator anim = copy.mAnimators.get(i);
+                        Animator animClone = anim.clone();
+                        String targetName = copy.mTargetNameMap.get(anim);
+                        Object targetObject = mVectorDrawable.getTargetByName(targetName);
+                        animClone.setTarget(targetObject);
+                        mAnimators.add(animClone);
+                        mTargetNameMap.put(animClone, targetName);
+                    }
+                }
             }
         }
 
@@ -287,7 +374,12 @@
     private void setupAnimatorsForTarget(String name, Animator animator) {
         Object target = mAnimatedVectorState.mVectorDrawable.getTargetByName(name);
         animator.setTarget(target);
+        if (mAnimatedVectorState.mAnimators == null) {
+            mAnimatedVectorState.mAnimators = new ArrayList<Animator>();
+            mAnimatedVectorState.mTargetNameMap = new ArrayMap<Animator, String>();
+        }
         mAnimatedVectorState.mAnimators.add(animator);
+        mAnimatedVectorState.mTargetNameMap.put(animator, name);
         if (DBG_ANIMATION_VECTOR_DRAWABLE) {
             Log.v(LOGTAG, "add animator  for target " + name + " " + animator);
         }
@@ -306,13 +398,25 @@
         return false;
     }
 
+    private boolean isStarted() {
+        final ArrayList<Animator> animators = mAnimatedVectorState.mAnimators;
+        final int size = animators.size();
+        for (int i = 0; i < size; i++) {
+            final Animator animator = animators.get(i);
+            if (animator.isStarted()) {
+                return true;
+            }
+        }
+        return false;
+    }
+
     @Override
     public void start() {
         final ArrayList<Animator> animators = mAnimatedVectorState.mAnimators;
         final int size = animators.size();
         for (int i = 0; i < size; i++) {
             final Animator animator = animators.get(i);
-            if (!animator.isRunning()) {
+            if (!animator.isStarted()) {
                 animator.start();
             }
         }
diff --git a/graphics/java/android/graphics/drawable/AnimationDrawable.java b/graphics/java/android/graphics/drawable/AnimationDrawable.java
index 5318fa7..d87e8e4 100644
--- a/graphics/java/android/graphics/drawable/AnimationDrawable.java
+++ b/graphics/java/android/graphics/drawable/AnimationDrawable.java
@@ -114,7 +114,9 @@
         final boolean changed = super.setVisible(visible, restart);
         if (visible) {
             if (restart || changed) {
-                setFrame(restart ? 0 : mCurFrame, true, mAnimating);
+                boolean startFromZero = restart || mCurFrame < 0 ||
+                        mCurFrame >= mAnimationState.getChildCount();
+                setFrame(startFromZero ? 0 : mCurFrame, true, mAnimating);
             }
         } else {
             unscheduleSelf(this);
diff --git a/graphics/java/android/graphics/drawable/BitmapDrawable.java b/graphics/java/android/graphics/drawable/BitmapDrawable.java
index 40adf94..cf6be48 100644
--- a/graphics/java/android/graphics/drawable/BitmapDrawable.java
+++ b/graphics/java/android/graphics/drawable/BitmapDrawable.java
@@ -81,14 +81,14 @@
     private static final int TILE_MODE_REPEAT = 1;
     private static final int TILE_MODE_MIRROR = 2;
 
-    private final Rect mDstRect = new Rect();   // Gravity.apply() sets this
+    private final Rect mDstRect = new Rect();   // #updateDstRectAndInsetsIfDirty() sets this
 
     private BitmapState mBitmapState;
     private PorterDuffColorFilter mTintFilter;
 
     private int mTargetDensity = DisplayMetrics.DENSITY_DEFAULT;
 
-    private boolean mApplyGravity;
+    private boolean mDstRectAndInsetsDirty = true;
     private boolean mMutated;
 
      // These are scaled to match the target density.
@@ -96,7 +96,7 @@
     private int mBitmapHeight;
 
     /** Optical insets due to gravity. */
-    private Insets mOpticalInsets = null;
+    private Insets mOpticalInsets = Insets.NONE;
 
     // Mirroring matrix for using with Shaders
     private Matrix mMirrorMatrix;
@@ -285,7 +285,7 @@
     public void setGravity(int gravity) {
         if (mBitmapState.mGravity != gravity) {
             mBitmapState.mGravity = gravity;
-            mApplyGravity = true;
+            mDstRectAndInsetsDirty = true;
             invalidateSelf();
         }
     }
@@ -428,6 +428,7 @@
             state.mTileModeX = xmode;
             state.mTileModeY = ymode;
             state.mRebuildShader = true;
+            mDstRectAndInsetsDirty = true;
             invalidateSelf();
         }
     }
@@ -464,7 +465,7 @@
 
     @Override
     protected void onBoundsChange(Rect bounds) {
-        mApplyGravity = true;
+        mDstRectAndInsetsDirty = true;
 
         final Shader shader = mBitmapState.mPaint.getShader();
         if (shader != null) {
@@ -503,7 +504,6 @@
             }
 
             state.mRebuildShader = false;
-            copyBounds(mDstRect);
         }
 
         final int restoreAlpha;
@@ -523,14 +523,10 @@
             clearColorFilter = false;
         }
 
+        updateDstRectAndInsetsIfDirty();
         final Shader shader = paint.getShader();
         final boolean needMirroring = needMirroring();
         if (shader == null) {
-            if (mApplyGravity) {
-                applyGravity();
-                mApplyGravity = false;
-            }
-
             if (needMirroring) {
                 canvas.save();
                 // Mirror the bitmap
@@ -544,11 +540,6 @@
                 canvas.restore();
             }
         } else {
-            if (mApplyGravity) {
-                copyBounds(mDstRect);
-                mApplyGravity = false;
-            }
-
             if (needMirroring) {
                 // Mirror the bitmap
                 updateMirrorMatrix(mDstRect.right - mDstRect.left);
@@ -574,39 +565,46 @@
         }
     }
 
+    private void updateDstRectAndInsetsIfDirty() {
+        if (mDstRectAndInsetsDirty) {
+            if (mBitmapState.mTileModeX == null && mBitmapState.mTileModeY == null) {
+                final Rect bounds = getBounds();
+                final int layoutDirection = getLayoutDirection();
+                Gravity.apply(mBitmapState.mGravity, mBitmapWidth, mBitmapHeight,
+                        bounds, mDstRect, layoutDirection);
+
+                final int left = mDstRect.left - bounds.left;
+                final int top = mDstRect.top - bounds.top;
+                final int right = bounds.right - mDstRect.right;
+                final int bottom = bounds.bottom - mDstRect.bottom;
+                mOpticalInsets = Insets.of(left, top, right, bottom);
+            } else {
+                copyBounds(mDstRect);
+                mOpticalInsets = Insets.NONE;
+            }
+        }
+        mDstRectAndInsetsDirty = false;
+    }
+
     /**
      * @hide
      */
     @Override
     public Insets getOpticalInsets() {
-        if (mApplyGravity && mBitmapState.mPaint.getShader() == null) {
-            applyGravity();
-            mApplyGravity = false;
-        }
-        return mOpticalInsets == null ? Insets.NONE : mOpticalInsets;
-    }
-
-    private void applyGravity() {
-        final Rect bounds = getBounds();
-        final int layoutDirection = getLayoutDirection();
-        Gravity.apply(mBitmapState.mGravity, mBitmapWidth, mBitmapHeight,
-                bounds, mDstRect, layoutDirection);
-
-        final int left = mDstRect.left - bounds.left;
-        final int top = mDstRect.top - bounds.top;
-        final int right = bounds.right - mDstRect.right;
-        final int bottom = bounds.bottom - mDstRect.bottom;
-        mOpticalInsets = Insets.of(left, top, right, bottom);
+        updateDstRectAndInsetsIfDirty();
+        return mOpticalInsets;
     }
 
     @Override
     public void getOutline(@NonNull Outline outline) {
-        super.getOutline(outline);
-        if (mBitmapState.mBitmap.hasAlpha()) {
-            // Bitmaps with alpha can't report a non-0 alpha,
-            // since they may not fill their rectangular bounds
-            outline.setAlpha(0.0f);
-        }
+        updateDstRectAndInsetsIfDirty();
+        outline.setRect(mDstRect);
+
+        // Only opaque Bitmaps can report a non-0 alpha,
+        // since only they are guaranteed to fill their bounds
+        boolean opaqueOverShape = mBitmapState.mBitmap != null
+                && !mBitmapState.mBitmap.hasAlpha();
+        outline.setAlpha(opaqueOverShape ? getAlpha() / 255.0f : 0.0f);
     }
 
     @Override
@@ -869,7 +867,7 @@
         int[] mThemeAttrs = null;
         Bitmap mBitmap = null;
         ColorStateList mTint = null;
-        Mode mTintMode = Mode.SRC_IN;
+        Mode mTintMode = DEFAULT_TINT_MODE;
         int mGravity = Gravity.FILL;
         float mBaseAlpha = 1.0f;
         Shader.TileMode mTileModeX = null;
diff --git a/graphics/java/android/graphics/drawable/ClipDrawable.java b/graphics/java/android/graphics/drawable/ClipDrawable.java
index f116376..61ef81b 100644
--- a/graphics/java/android/graphics/drawable/ClipDrawable.java
+++ b/graphics/java/android/graphics/drawable/ClipDrawable.java
@@ -285,6 +285,8 @@
                 }
                 mDrawable.setCallback(owner);
                 mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+                mDrawable.setBounds(orig.mDrawable.getBounds());
+                mDrawable.setLevel(orig.mDrawable.getLevel());
                 mOrientation = orig.mOrientation;
                 mGravity = orig.mGravity;
                 mCheckedConstantState = mCanConstantState = true;
diff --git a/graphics/java/android/graphics/drawable/ColorDrawable.java b/graphics/java/android/graphics/drawable/ColorDrawable.java
index 9e42a89..33225ce 100644
--- a/graphics/java/android/graphics/drawable/ColorDrawable.java
+++ b/graphics/java/android/graphics/drawable/ColorDrawable.java
@@ -261,8 +261,8 @@
         @ViewDebug.ExportedProperty
         int mUseColor;  // basecolor modulated by setAlpha()
         int mChangingConfigurations;
-        ColorStateList mTint;
-        Mode mTintMode;
+        ColorStateList mTint = null;
+        Mode mTintMode = DEFAULT_TINT_MODE;
 
         ColorState() {
             // Empty constructor.
diff --git a/graphics/java/android/graphics/drawable/Drawable.java b/graphics/java/android/graphics/drawable/Drawable.java
index 5a3e3a3..43a9eaa 100644
--- a/graphics/java/android/graphics/drawable/Drawable.java
+++ b/graphics/java/android/graphics/drawable/Drawable.java
@@ -125,6 +125,8 @@
 public abstract class Drawable {
     private static final Rect ZERO_BOUNDS_RECT = new Rect();
 
+    static final PorterDuff.Mode DEFAULT_TINT_MODE = PorterDuff.Mode.SRC_IN;
+
     private int[] mStateSet = StateSet.WILD_CARD;
     private int mLevel = 0;
     private int mChangingConfigurations = 0;
@@ -470,19 +472,6 @@
     }
 
     /**
-     * Specifies a tint and blending mode for this drawable.
-     * <p>
-     * Setting a color filter via {@link #setColorFilter(ColorFilter)} overrides
-     * tint.
-     *
-     * @param tint Color state list to use for tinting this drawable, or null to
-     *            clear the tint
-     * @param tintMode A Porter-Duff blending mode
-     * @hide TODO: Was in L-preview, remove this API for release
-     */
-    public void setTint(ColorStateList tint, PorterDuff.Mode tintMode) {}
-
-    /**
      * Specifies a tint for this drawable.
      * <p>
      * Setting a color filter via {@link #setColorFilter(ColorFilter)} overrides
diff --git a/graphics/java/android/graphics/drawable/GradientDrawable.java b/graphics/java/android/graphics/drawable/GradientDrawable.java
index a383aab..cd6297b 100644
--- a/graphics/java/android/graphics/drawable/GradientDrawable.java
+++ b/graphics/java/android/graphics/drawable/GradientDrawable.java
@@ -811,6 +811,11 @@
     }
 
     @Override
+    public ColorFilter getColorFilter() {
+        return mColorFilter;
+    }
+
+    @Override
     public void setColorFilter(ColorFilter cf) {
         if (cf != mColorFilter) {
             mColorFilter = cf;
@@ -820,7 +825,7 @@
 
     @Override
     public int getOpacity() {
-        return (mAlpha == 255 && mGradientState.mOpaque) ?
+        return (mAlpha == 255 && mGradientState.mOpaqueOverBounds && isOpaqueForState()) ?
                 PixelFormat.OPAQUE : PixelFormat.TRANSLUCENT;
     }
 
@@ -1409,11 +1414,25 @@
         return mGradientState;
     }
 
+    private boolean isOpaqueForState() {
+        if (mGradientState.mStrokeWidth >= 0 && mStrokePaint != null
+                && !isOpaque(mStrokePaint.getColor())) {
+            return false;
+        }
+
+        if (!isOpaque(mFillPaint.getColor())) {
+            return false;
+        }
+
+        return true;
+    }
+
     @Override
     public void getOutline(Outline outline) {
         final GradientState st = mGradientState;
         final Rect bounds = getBounds();
-        outline.setAlpha(mAlpha / 255.0f);
+        // only report non-zero alpha if shape being drawn is opaque
+        outline.setAlpha(st.mOpaqueOverShape && isOpaqueForState() ? (mAlpha / 255.0f) : 0.0f);
 
         switch (st.mShape) {
             case RECTANGLE:
@@ -1492,7 +1511,8 @@
         private int mGradientRadiusType = RADIUS_TYPE_PIXELS;
         private boolean mUseLevel;
         private boolean mUseLevelForShape;
-        private boolean mOpaque;
+        private boolean mOpaqueOverBounds;
+        private boolean mOpaqueOverShape;
 
         int[] mThemeAttrs;
         int[] mAttrSize;
@@ -1544,7 +1564,8 @@
             mGradientRadiusType = state.mGradientRadiusType;
             mUseLevel = state.mUseLevel;
             mUseLevelForShape = state.mUseLevelForShape;
-            mOpaque = state.mOpaque;
+            mOpaqueOverBounds = state.mOpaqueOverBounds;
+            mOpaqueOverShape = state.mOpaqueOverShape;
             mThemeAttrs = state.mThemeAttrs;
             mAttrSize = state.mAttrSize;
             mAttrGradient = state.mAttrGradient;
@@ -1606,44 +1627,28 @@
         }
 
         private void computeOpacity() {
-            if (mShape != RECTANGLE) {
-                mOpaque = false;
-                return;
-            }
-
-            if (mRadius > 0 || mRadiusArray != null) {
-                mOpaque = false;
-                return;
-            }
-
-            if (mStrokeWidth > 0) {
-                if (mStrokeColorStateList != null) {
-                    if (!mStrokeColorStateList.isOpaque()) {
-                        mOpaque = false;
-                        return;
-                    }
-                }
-            }
-
-            if (mColorStateList != null && !mColorStateList.isOpaque()) {
-                mOpaque = false;
-                return;
-            }
+            mOpaqueOverBounds = false;
+            mOpaqueOverShape = false;
 
             if (mColors != null) {
                 for (int i = 0; i < mColors.length; i++) {
                     if (!isOpaque(mColors[i])) {
-                        mOpaque = false;
                         return;
                     }
                 }
             }
 
-            mOpaque = true;
-        }
+            // An unfilled shape is not opaque over bounds or shape
+            if (mColors == null && mColorStateList == null) {
+                return;
+            }
 
-        private static boolean isOpaque(int color) {
-            return ((color >> 24) & 0xff) == 0xff;
+            // Colors are opaque, so opaqueOverShape=true,
+            mOpaqueOverShape = true;
+            // and opaqueOverBounds=true if shape fills bounds
+            mOpaqueOverBounds = mShape == RECTANGLE
+                    && mRadius <= 0
+                    && mRadiusArray == null;
         }
 
         public void setStroke(
@@ -1681,6 +1686,10 @@
         }
     }
 
+    static boolean isOpaque(int color) {
+        return ((color >> 24) & 0xff) == 0xff;
+    }
+
     /**
      * Creates a new themed GradientDrawable based on the specified constant state.
      * <p>
diff --git a/graphics/java/android/graphics/drawable/InsetDrawable.java b/graphics/java/android/graphics/drawable/InsetDrawable.java
index 588e776..384226f 100644
--- a/graphics/java/android/graphics/drawable/InsetDrawable.java
+++ b/graphics/java/android/graphics/drawable/InsetDrawable.java
@@ -26,10 +26,13 @@
 import android.content.res.Resources;
 import android.content.res.TypedArray;
 import android.content.res.Resources.Theme;
-import android.graphics.*;
+import android.graphics.Canvas;
+import android.graphics.ColorFilter;
+import android.graphics.Insets;
+import android.graphics.Outline;
 import android.graphics.PorterDuff.Mode;
+import android.graphics.Rect;
 import android.util.AttributeSet;
-import android.util.Log;
 
 import java.io.IOException;
 
@@ -50,8 +53,6 @@
  * @attr ref android.R.styleable#InsetDrawable_insetBottom
  */
 public class InsetDrawable extends Drawable implements Drawable.Callback {
-    private static final String LOG_TAG = "InsetDrawable";
-
     private final Rect mTmpRect = new Rect();
 
     private InsetState mInsetState;
@@ -85,8 +86,9 @@
             throws XmlPullParserException, IOException {
         final TypedArray a = r.obtainAttributes(attrs, R.styleable.InsetDrawable);
         super.inflateWithAttributes(r, parser, a, R.styleable.InsetDrawable_visible);
+
+        mInsetState.mDrawable = null;
         updateStateFromTypedArray(a);
-        a.recycle();
 
         // Load inner XML elements.
         if (mInsetState.mDrawable == null) {
@@ -104,9 +106,17 @@
             dr.setCallback(this);
         }
 
-        // Verify state.
-        if (mInsetState.mDrawable == null) {
-            Log.w(LOG_TAG, "No drawable specified for <inset>");
+        verifyRequiredAttributes(a);
+        a.recycle();
+    }
+
+    private void verifyRequiredAttributes(TypedArray a) throws XmlPullParserException {
+        // If we're not waiting on a theme, verify required attributes.
+        if (mInsetState.mDrawable == null && (mInsetState.mThemeAttrs == null
+                || mInsetState.mThemeAttrs[R.styleable.InsetDrawable_drawable] == 0)) {
+            throw new XmlPullParserException(a.getPositionDescription() +
+                    ": <inset> tag requires a 'drawable' attribute or "
+                    + "child tag defining a drawable");
         }
     }
 
@@ -167,6 +177,7 @@
         final TypedArray a = t.resolveAttributes(state.mThemeAttrs, R.styleable.InsetDrawable);
         try {
             updateStateFromTypedArray(a);
+            verifyRequiredAttributes(a);
         } catch (XmlPullParserException e) {
             throw new RuntimeException(e);
         } finally {
@@ -224,12 +235,8 @@
         padding.top += mInsetState.mInsetTop;
         padding.bottom += mInsetState.mInsetBottom;
 
-        if (pad || (mInsetState.mInsetLeft | mInsetState.mInsetRight |
-                    mInsetState.mInsetTop | mInsetState.mInsetBottom) != 0) {
-            return true;
-        } else {
-            return false;
-        }
+        return pad || (mInsetState.mInsetLeft | mInsetState.mInsetRight |
+                mInsetState.mInsetTop | mInsetState.mInsetBottom) != 0;
     }
 
     /** @hide */
@@ -395,6 +402,8 @@
                 }
                 mDrawable.setCallback(owner);
                 mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+                mDrawable.setBounds(orig.mDrawable.getBounds());
+                mDrawable.setLevel(orig.mDrawable.getLevel());
                 mInsetLeft = orig.mInsetLeft;
                 mInsetTop = orig.mInsetTop;
                 mInsetRight = orig.mInsetRight;
diff --git a/graphics/java/android/graphics/drawable/LayerDrawable.java b/graphics/java/android/graphics/drawable/LayerDrawable.java
index 43bc89a..001ed88 100644
--- a/graphics/java/android/graphics/drawable/LayerDrawable.java
+++ b/graphics/java/android/graphics/drawable/LayerDrawable.java
@@ -961,20 +961,22 @@
             // Default empty constructor.
         }
 
-        ChildDrawable(ChildDrawable or, LayerDrawable owner, Resources res) {
+        ChildDrawable(ChildDrawable orig, LayerDrawable owner, Resources res) {
             if (res != null) {
-                mDrawable = or.mDrawable.getConstantState().newDrawable(res);
+                mDrawable = orig.mDrawable.getConstantState().newDrawable(res);
             } else {
-                mDrawable = or.mDrawable.getConstantState().newDrawable();
+                mDrawable = orig.mDrawable.getConstantState().newDrawable();
             }
             mDrawable.setCallback(owner);
-            mDrawable.setLayoutDirection(or.mDrawable.getLayoutDirection());
-            mThemeAttrs = or.mThemeAttrs;
-            mInsetL = or.mInsetL;
-            mInsetT = or.mInsetT;
-            mInsetR = or.mInsetR;
-            mInsetB = or.mInsetB;
-            mId = or.mId;
+            mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+            mDrawable.setBounds(orig.mDrawable.getBounds());
+            mDrawable.setLevel(orig.mDrawable.getLevel());
+            mThemeAttrs = orig.mThemeAttrs;
+            mInsetL = orig.mInsetL;
+            mInsetT = orig.mInsetT;
+            mInsetR = orig.mInsetR;
+            mInsetB = orig.mInsetB;
+            mId = orig.mId;
         }
     }
 
diff --git a/graphics/java/android/graphics/drawable/NinePatchDrawable.java b/graphics/java/android/graphics/drawable/NinePatchDrawable.java
index 0aa1b0d..6c62ccf 100644
--- a/graphics/java/android/graphics/drawable/NinePatchDrawable.java
+++ b/graphics/java/android/graphics/drawable/NinePatchDrawable.java
@@ -446,19 +446,8 @@
                         ": <nine-patch> requires a valid 9-patch source image");
             }
 
-            // Hey, now might be a good time to actually load optical bounds!
             bitmap.getOpticalInsets(opticalInsets);
 
-            // Sanity check for valid padding when we have optical insets.
-            if (padding.left < opticalInsets.left) {
-                padding.left = opticalInsets.left;
-                padding.right = opticalInsets.right;
-            }
-            if (padding.top < opticalInsets.top) {
-                padding.top = opticalInsets.top;
-                padding.bottom = opticalInsets.bottom;
-            }
-
             state.mNinePatch = new NinePatch(bitmap, bitmap.getNinePatchChunk());
             state.mPadding = padding;
             state.mOpticalInsets = Insets.of(opticalInsets);
@@ -596,7 +585,7 @@
         int[] mThemeAttrs = null;
         NinePatch mNinePatch = null;
         ColorStateList mTint = null;
-        Mode mTintMode = Mode.SRC_IN;
+        Mode mTintMode = DEFAULT_TINT_MODE;
         Rect mPadding = null;
         Insets mOpticalInsets = Insets.NONE;
         float mBaseAlpha = 1.0f;
@@ -626,21 +615,6 @@
             mOpticalInsets = Insets.of(opticalInsets);
             mDither = dither;
             mAutoMirrored = autoMirror;
-
-            // Sanity check for valid padding when we have optical insets.
-            if (opticalInsets != null && !opticalInsets.isEmpty()) {
-                if (mPadding == null) {
-                    mPadding = new Rect();
-                }
-                if (mPadding.left < opticalInsets.left) {
-                    mPadding.left = opticalInsets.left;
-                    mPadding.right = opticalInsets.right;
-                }
-                if (mPadding.top < opticalInsets.top) {
-                    mPadding.top = opticalInsets.top;
-                    mPadding.bottom = opticalInsets.bottom;
-                }
-            }
         }
 
         // Copy constructor
diff --git a/graphics/java/android/graphics/drawable/Ripple.java b/graphics/java/android/graphics/drawable/Ripple.java
index be2241b..864e119 100644
--- a/graphics/java/android/graphics/drawable/Ripple.java
+++ b/graphics/java/android/graphics/drawable/Ripple.java
@@ -22,6 +22,7 @@
 import android.animation.TimeInterpolator;
 import android.graphics.Canvas;
 import android.graphics.CanvasProperty;
+import android.graphics.Color;
 import android.graphics.Paint;
 import android.graphics.Paint.Style;
 import android.graphics.Rect;
@@ -58,7 +59,7 @@
     private final Rect mBounds;
 
     /** Full-opacity color for drawing this ripple. */
-    private int mColor;
+    private int mColorOpaque;
 
     /** Maximum ripple radius. */
     private float mOuterRadius;
@@ -105,6 +106,9 @@
     /** Whether we have an explicit maximum radius. */
     private boolean mHasMaxRadius;
 
+    /** Whether we were canceled externally and should avoid self-removal. */
+    private boolean mCanceled;
+
     /**
      * Creates a new ripple.
      */
@@ -117,7 +121,7 @@
     }
 
     public void setup(int maxRadius, int color, float density) {
-        mColor = color | 0xFF000000;
+        mColorOpaque = color | 0xFF000000;
 
         if (maxRadius != RippleDrawable.RADIUS_AUTO) {
             mHasMaxRadius = true;
@@ -135,6 +139,10 @@
         clampStartingPosition();
     }
 
+    public boolean isHardwareAnimating() {
+        return mHardwareAnimating;
+    }
+
     private void clampStartingPosition() {
         final float cX = mBounds.exactCenterX();
         final float cY = mBounds.exactCenterY();
@@ -211,7 +219,7 @@
         final boolean canUseHardware = c.isHardwareAccelerated();
         if (mCanUseHardware != canUseHardware && mCanUseHardware) {
             // We've switched from hardware to non-hardware mode. Panic.
-            cancelHardwareAnimations();
+            cancelHardwareAnimations(true);
         }
         mCanUseHardware = canUseHardware;
 
@@ -231,7 +239,10 @@
         final ArrayList<RenderNodeAnimator> pendingAnimations = mPendingAnimations;
         final int N = pendingAnimations.size();
         if (N > 0) {
-            cancelHardwareAnimations();
+            cancelHardwareAnimations(false);
+
+            // We canceled old animations, but we're about to run new ones.
+            mHardwareAnimating = true;
 
             for (int i = 0; i < N; i++) {
                 pendingAnimations.get(i).setTarget(c);
@@ -250,9 +261,8 @@
     private boolean drawSoftware(Canvas c, Paint p) {
         boolean hasContent = false;
 
-        // Cache the paint alpha so we can restore it later.
-        final int paintAlpha = p.getAlpha();
-        final int alpha = (int) (paintAlpha * mOpacity + 0.5f);
+        p.setColor(mColorOpaque);
+        final int alpha = (int) (255 * mOpacity + 0.5f);
         final float radius = MathUtils.lerp(0, mOuterRadius, mTweenRadius);
         if (alpha > 0 && radius > 0) {
             final float x = MathUtils.lerp(
@@ -265,8 +275,6 @@
             hasContent = true;
         }
 
-        p.setAlpha(paintAlpha);
-
         return hasContent;
     }
 
@@ -295,6 +303,8 @@
      * Starts the enter animation.
      */
     public void enter() {
+        cancel();
+
         final int radiusDuration = (int)
                 (1000 * Math.sqrt(mOuterRadius / WAVE_TOUCH_DOWN_ACCELERATION * mDensity) + 0.5);
 
@@ -332,7 +342,8 @@
      * Starts the exit animation.
      */
     public void exit() {
-        cancelSoftwareAnimations();
+        cancel();
+
         final float radius = MathUtils.lerp(0, mOuterRadius, mTweenRadius);
         final float remaining;
         if (mAnimRadius != null && mAnimRadius.isRunning()) {
@@ -363,7 +374,7 @@
         final float startRadius = MathUtils.lerp(0, mOuterRadius, mTweenRadius);
         final Paint paint = getTempPaint();
         paint.setAntiAlias(true);
-        paint.setColor(mColor);
+        paint.setColor(mColorOpaque);
         paint.setAlpha((int) (255 * mOpacity + 0.5f));
         paint.setStyle(Style.FILL);
         mPropPaint = CanvasProperty.createPaint(paint);
@@ -396,9 +407,48 @@
 
         mHardwareAnimating = true;
 
+        // Set up the software values to match the hardware end values.
+        mOpacity = 0;
+        mTweenX = 1;
+        mTweenY = 1;
+        mTweenRadius = 1;
+
         invalidateSelf();
     }
 
+    /**
+     * Jump all animations to their end state. The caller is responsible for
+     * removing the ripple from the list of animating ripples.
+     */
+    public void jump() {
+        mCanceled = true;
+        endSoftwareAnimations();
+        cancelHardwareAnimations(true);
+        mCanceled = false;
+    }
+
+    private void endSoftwareAnimations() {
+        if (mAnimRadius != null) {
+            mAnimRadius.end();
+            mAnimRadius = null;
+        }
+
+        if (mAnimOpacity != null) {
+            mAnimOpacity.end();
+            mAnimOpacity = null;
+        }
+
+        if (mAnimX != null) {
+            mAnimX.end();
+            mAnimX = null;
+        }
+
+        if (mAnimY != null) {
+            mAnimY.end();
+            mAnimY = null;
+        }
+    }
+
     private Paint getTempPaint() {
         if (mTempPaint == null) {
             mTempPaint = new Paint();
@@ -440,47 +490,61 @@
     }
 
     /**
-     * Cancel all animations.
+     * Cancels all animations. The caller is responsible for removing
+     * the ripple from the list of animating ripples.
      */
     public void cancel() {
+        mCanceled = true;
         cancelSoftwareAnimations();
-        cancelHardwareAnimations();
+        cancelHardwareAnimations(true);
+        mCanceled = false;
     }
 
     private void cancelSoftwareAnimations() {
         if (mAnimRadius != null) {
             mAnimRadius.cancel();
+            mAnimRadius = null;
         }
 
         if (mAnimOpacity != null) {
             mAnimOpacity.cancel();
+            mAnimOpacity = null;
         }
 
         if (mAnimX != null) {
             mAnimX.cancel();
+            mAnimX = null;
         }
 
         if (mAnimY != null) {
             mAnimY.cancel();
+            mAnimY = null;
         }
     }
 
     /**
      * Cancels any running hardware animations.
      */
-    private void cancelHardwareAnimations() {
+    private void cancelHardwareAnimations(boolean cancelPending) {
         final ArrayList<RenderNodeAnimator> runningAnimations = mRunningAnimations;
         final int N = runningAnimations.size();
         for (int i = 0; i < N; i++) {
             runningAnimations.get(i).cancel();
         }
-
         runningAnimations.clear();
+
+        if (cancelPending && !mPendingAnimations.isEmpty()) {
+            mPendingAnimations.clear();
+        }
+
+        mHardwareAnimating = false;
     }
 
     private void removeSelf() {
         // The owner will invalidate itself.
-        mOwner.removeRipple(this);
+        if (!mCanceled) {
+            mOwner.removeRipple(this);
+        }
     }
 
     private void invalidateSelf() {
diff --git a/graphics/java/android/graphics/drawable/RippleBackground.java b/graphics/java/android/graphics/drawable/RippleBackground.java
index 93df648..4e709b5 100644
--- a/graphics/java/android/graphics/drawable/RippleBackground.java
+++ b/graphics/java/android/graphics/drawable/RippleBackground.java
@@ -22,6 +22,7 @@
 import android.animation.TimeInterpolator;
 import android.graphics.Canvas;
 import android.graphics.CanvasProperty;
+import android.graphics.Color;
 import android.graphics.Paint;
 import android.graphics.Paint.Style;
 import android.graphics.Rect;
@@ -37,18 +38,15 @@
  */
 class RippleBackground {
     private static final TimeInterpolator LINEAR_INTERPOLATOR = new LinearInterpolator();
-    private static final TimeInterpolator DECEL_INTERPOLATOR = new LogInterpolator();
 
     private static final float GLOBAL_SPEED = 1.0f;
-    private static final float WAVE_TOUCH_DOWN_ACCELERATION = 1024.0f * GLOBAL_SPEED;
     private static final float WAVE_OPACITY_DECAY_VELOCITY = 3.0f / GLOBAL_SPEED;
-    private static final float WAVE_OUTER_OPACITY_VELOCITY_MAX = 4.5f * GLOBAL_SPEED;
-    private static final float WAVE_OUTER_OPACITY_VELOCITY_MIN = 1.5f * GLOBAL_SPEED;
+    private static final float WAVE_OUTER_OPACITY_EXIT_VELOCITY_MAX = 4.5f * GLOBAL_SPEED;
+    private static final float WAVE_OUTER_OPACITY_EXIT_VELOCITY_MIN = 1.5f * GLOBAL_SPEED;
+    private static final float WAVE_OUTER_OPACITY_ENTER_VELOCITY = 10.0f * GLOBAL_SPEED;
     private static final float WAVE_OUTER_SIZE_INFLUENCE_MAX = 200f;
     private static final float WAVE_OUTER_SIZE_INFLUENCE_MIN = 40f;
 
-    private static final long RIPPLE_ENTER_DELAY = 80;
-
     // Hardware animators.
     private final ArrayList<RenderNodeAnimator> mRunningAnimations =
             new ArrayList<RenderNodeAnimator>();
@@ -61,7 +59,10 @@
     private final Rect mBounds;
 
     /** Full-opacity color for drawing this ripple. */
-    private int mColor;
+    private int mColorOpaque;
+
+    /** Maximum alpha value for drawing this ripple. */
+    private int mColorAlpha;
 
     /** Maximum ripple radius. */
     private float mOuterRadius;
@@ -69,11 +70,6 @@
     /** Screen density used to adjust pixel-based velocities. */
     private float mDensity;
 
-    private float mStartingX;
-    private float mStartingY;
-    private float mClampedStartingX;
-    private float mClampedStartingY;
-
     // Hardware rendering properties.
     private CanvasProperty<Paint> mPropOuterPaint;
     private CanvasProperty<Float> mPropOuterRadius;
@@ -82,8 +78,6 @@
 
     // Software animators.
     private ObjectAnimator mAnimOuterOpacity;
-    private ObjectAnimator mAnimX;
-    private ObjectAnimator mAnimY;
 
     // Temporary paint used for creating canvas properties.
     private Paint mTempPaint;
@@ -93,10 +87,6 @@
     private float mOuterX;
     private float mOuterY;
 
-    // Values used to tween between the start and end positions.
-    private float mTweenX = 0;
-    private float mTweenY = 0;
-
     /** Whether we should be drawing hardware animations. */
     private boolean mHardwareAnimating;
 
@@ -109,16 +99,14 @@
     /**
      * Creates a new ripple.
      */
-    public RippleBackground(RippleDrawable owner, Rect bounds, float startingX, float startingY) {
+    public RippleBackground(RippleDrawable owner, Rect bounds) {
         mOwner = owner;
         mBounds = bounds;
-
-        mStartingX = startingX;
-        mStartingY = startingY;
     }
 
     public void setup(int maxRadius, int color, float density) {
-        mColor = color | 0xFF000000;
+        mColorOpaque = color | 0xFF000000;
+        mColorAlpha = Color.alpha(color);
 
         if (maxRadius != RippleDrawable.RADIUS_AUTO) {
             mHasMaxRadius = true;
@@ -132,25 +120,10 @@
         mOuterX = 0;
         mOuterY = 0;
         mDensity = density;
-
-        clampStartingPosition();
     }
 
-    private void clampStartingPosition() {
-        final float cX = mBounds.exactCenterX();
-        final float cY = mBounds.exactCenterY();
-        final float dX = mStartingX - cX;
-        final float dY = mStartingY - cY;
-        final float r = mOuterRadius;
-        if (dX * dX + dY * dY > r * r) {
-            // Point is outside the circle, clamp to the circumference.
-            final double angle = Math.atan2(dY, dX);
-            mClampedStartingX = cX + (float) (Math.cos(angle) * r);
-            mClampedStartingY = cY + (float) (Math.sin(angle) * r);
-        } else {
-            mClampedStartingX = mStartingX;
-            mClampedStartingY = mStartingY;
-        }
+    public boolean isHardwareAnimating() {
+        return mHardwareAnimating;
     }
 
     public void onHotspotBoundsChanged() {
@@ -158,8 +131,6 @@
             final float halfWidth = mBounds.width() / 2.0f;
             final float halfHeight = mBounds.height() / 2.0f;
             mOuterRadius = (float) Math.sqrt(halfWidth * halfWidth + halfHeight * halfHeight);
-
-            clampStartingPosition();
         }
     }
 
@@ -174,28 +145,6 @@
         return mOuterOpacity;
     }
 
-    @SuppressWarnings("unused")
-    public void setXGravity(float x) {
-        mTweenX = x;
-        invalidateSelf();
-    }
-
-    @SuppressWarnings("unused")
-    public float getXGravity() {
-        return mTweenX;
-    }
-
-    @SuppressWarnings("unused")
-    public void setYGravity(float y) {
-        mTweenY = y;
-        invalidateSelf();
-    }
-
-    @SuppressWarnings("unused")
-    public float getYGravity() {
-        return mTweenY;
-    }
-
     /**
      * Draws the ripple centered at (0,0) using the specified paint.
      */
@@ -203,7 +152,7 @@
         final boolean canUseHardware = c.isHardwareAccelerated();
         if (mCanUseHardware != canUseHardware && mCanUseHardware) {
             // We've switched from hardware to non-hardware mode. Panic.
-            cancelHardwareAnimations();
+            cancelHardwareAnimations(true);
         }
         mCanUseHardware = canUseHardware;
 
@@ -217,13 +166,21 @@
         return hasContent;
     }
 
+    public boolean shouldDraw() {
+        final int outerAlpha = (int) (mColorAlpha * mOuterOpacity + 0.5f);
+        return mCanUseHardware && mHardwareAnimating || outerAlpha > 0 && mOuterRadius > 0;
+    }
+
     private boolean drawHardware(HardwareCanvas c) {
         // If we have any pending hardware animations, cancel any running
         // animations and start those now.
         final ArrayList<RenderNodeAnimator> pendingAnimations = mPendingAnimations;
         final int N = pendingAnimations.size();
         if (N > 0) {
-            cancelHardwareAnimations();
+            cancelHardwareAnimations(false);
+
+            // We canceled old animations, but we're about to run new ones.
+            mHardwareAnimating = true;
 
             for (int i = 0; i < N; i++) {
                 pendingAnimations.get(i).setTarget(c);
@@ -242,10 +199,8 @@
     private boolean drawSoftware(Canvas c, Paint p) {
         boolean hasContent = false;
 
-        // Cache the paint alpha so we can restore it later.
-        final int paintAlpha = p.getAlpha();
-
-        final int outerAlpha = (int) (paintAlpha * mOuterOpacity + 0.5f);
+        p.setColor(mColorOpaque);
+        final int outerAlpha = (int) (mColorAlpha * mOuterOpacity + 0.5f);
         if (outerAlpha > 0 && mOuterRadius > 0) {
             p.setAlpha(outerAlpha);
             p.setStyle(Style.FILL);
@@ -253,8 +208,6 @@
             hasContent = true;
         }
 
-        p.setAlpha(paintAlpha);
-
         return hasContent;
     }
 
@@ -269,58 +222,30 @@
     }
 
     /**
-     * Specifies the starting position relative to the drawable bounds. No-op if
-     * the ripple has already entered.
-     */
-    public void move(float x, float y) {
-        mStartingX = x;
-        mStartingY = y;
-
-        clampStartingPosition();
-    }
-
-    /**
      * Starts the enter animation.
      */
     public void enter() {
-        final int radiusDuration = (int)
-                (1000 * Math.sqrt(mOuterRadius / WAVE_TOUCH_DOWN_ACCELERATION * mDensity) + 0.5);
-        final int outerDuration = (int) (1000 * 1.0f / WAVE_OUTER_OPACITY_VELOCITY_MIN);
+        cancel();
 
-        final ObjectAnimator cX = ObjectAnimator.ofFloat(this, "xGravity", 1);
-        cX.setAutoCancel(true);
-        cX.setDuration(radiusDuration);
-        cX.setInterpolator(LINEAR_INTERPOLATOR);
-        cX.setStartDelay(RIPPLE_ENTER_DELAY);
-
-        final ObjectAnimator cY = ObjectAnimator.ofFloat(this, "yGravity", 1);
-        cY.setAutoCancel(true);
-        cY.setDuration(radiusDuration);
-        cY.setInterpolator(LINEAR_INTERPOLATOR);
-        cY.setStartDelay(RIPPLE_ENTER_DELAY);
-
+        final int outerDuration = (int) (1000 * 1.0f / WAVE_OUTER_OPACITY_ENTER_VELOCITY);
         final ObjectAnimator outer = ObjectAnimator.ofFloat(this, "outerOpacity", 0, 1);
         outer.setAutoCancel(true);
         outer.setDuration(outerDuration);
         outer.setInterpolator(LINEAR_INTERPOLATOR);
 
         mAnimOuterOpacity = outer;
-        mAnimX = cX;
-        mAnimY = cY;
 
         // Enter animations always run on the UI thread, since it's unlikely
         // that anything interesting is happening until the user lifts their
         // finger.
         outer.start();
-        cX.start();
-        cY.start();
     }
 
     /**
      * Starts the exit animation.
      */
     public void exit() {
-        cancelSoftwareAnimations();
+        cancel();
 
         // Scale the outer max opacity and opacity velocity based
         // on the size of the outer radius.
@@ -328,37 +253,31 @@
         final float outerSizeInfluence = MathUtils.constrain(
                 (mOuterRadius - WAVE_OUTER_SIZE_INFLUENCE_MIN * mDensity)
                 / (WAVE_OUTER_SIZE_INFLUENCE_MAX * mDensity), 0, 1);
-        final float outerOpacityVelocity = MathUtils.lerp(WAVE_OUTER_OPACITY_VELOCITY_MIN,
-                WAVE_OUTER_OPACITY_VELOCITY_MAX, outerSizeInfluence);
+        final float outerOpacityVelocity = MathUtils.lerp(WAVE_OUTER_OPACITY_EXIT_VELOCITY_MIN,
+                WAVE_OUTER_OPACITY_EXIT_VELOCITY_MAX, outerSizeInfluence);
 
         // Determine at what time the inner and outer opacity intersect.
         // inner(t) = mOpacity - t * WAVE_OPACITY_DECAY_VELOCITY / 1000
         // outer(t) = mOuterOpacity + t * WAVE_OUTER_OPACITY_VELOCITY / 1000
-        final int outerInflection = Math.max(0, (int) (1000 * (1 - mOuterOpacity)
+        final int inflectionDuration = Math.max(0, (int) (1000 * (1 - mOuterOpacity)
                 / (WAVE_OPACITY_DECAY_VELOCITY + outerOpacityVelocity) + 0.5f));
-        final int inflectionOpacity = (int) (255 * (mOuterOpacity + outerInflection
-                * outerOpacityVelocity * outerSizeInfluence / 1000) + 0.5f);
+        final int inflectionOpacity = (int) (mColorAlpha * (mOuterOpacity
+                + inflectionDuration * outerOpacityVelocity * outerSizeInfluence / 1000) + 0.5f);
 
         if (mCanUseHardware) {
-            exitHardware(opacityDuration, outerInflection, inflectionOpacity);
+            exitHardware(opacityDuration, inflectionDuration, inflectionOpacity);
         } else {
-            exitSoftware(opacityDuration, outerInflection, inflectionOpacity);
+            exitSoftware(opacityDuration, inflectionDuration, inflectionOpacity);
         }
     }
 
-    private void exitHardware(int opacityDuration, int outerInflection, int inflectionOpacity) {
+    private void exitHardware(int opacityDuration, int inflectionDuration, int inflectionOpacity) {
         mPendingAnimations.clear();
 
-        // TODO: Adjust background by starting position.
-        final float startX = MathUtils.lerp(
-                mClampedStartingX - mBounds.exactCenterX(), mOuterX, mTweenX);
-        final float startY = MathUtils.lerp(
-                mClampedStartingY - mBounds.exactCenterY(), mOuterY, mTweenY);
-
         final Paint outerPaint = getTempPaint();
         outerPaint.setAntiAlias(true);
-        outerPaint.setColor(mColor);
-        outerPaint.setAlpha((int) (255 * mOuterOpacity + 0.5f));
+        outerPaint.setColor(mColorOpaque);
+        outerPaint.setAlpha((int) (mColorAlpha * mOuterOpacity + 0.5f));
         outerPaint.setStyle(Style.FILL);
         mPropOuterPaint = CanvasProperty.createPaint(outerPaint);
         mPropOuterRadius = CanvasProperty.createFloat(mOuterRadius);
@@ -366,21 +285,21 @@
         mPropOuterY = CanvasProperty.createFloat(mOuterY);
 
         final RenderNodeAnimator outerOpacityAnim;
-        if (outerInflection > 0) {
+        if (inflectionDuration > 0) {
             // Outer opacity continues to increase for a bit.
-            outerOpacityAnim = new RenderNodeAnimator(
-                    mPropOuterPaint, RenderNodeAnimator.PAINT_ALPHA, inflectionOpacity);
-            outerOpacityAnim.setDuration(outerInflection);
+            outerOpacityAnim = new RenderNodeAnimator(mPropOuterPaint,
+                    RenderNodeAnimator.PAINT_ALPHA, inflectionOpacity);
+            outerOpacityAnim.setDuration(inflectionDuration);
             outerOpacityAnim.setInterpolator(LINEAR_INTERPOLATOR);
 
             // Chain the outer opacity exit animation.
-            final int outerDuration = opacityDuration - outerInflection;
+            final int outerDuration = opacityDuration - inflectionDuration;
             if (outerDuration > 0) {
                 final RenderNodeAnimator outerFadeOutAnim = new RenderNodeAnimator(
                         mPropOuterPaint, RenderNodeAnimator.PAINT_ALPHA, 0);
                 outerFadeOutAnim.setDuration(outerDuration);
                 outerFadeOutAnim.setInterpolator(LINEAR_INTERPOLATOR);
-                outerFadeOutAnim.setStartDelay(outerInflection);
+                outerFadeOutAnim.setStartDelay(inflectionDuration);
                 outerFadeOutAnim.setStartValue(inflectionOpacity);
                 outerFadeOutAnim.addListener(mAnimationListener);
 
@@ -400,9 +319,28 @@
 
         mHardwareAnimating = true;
 
+        // Set up the software values to match the hardware end values.
+        mOuterOpacity = 0;
+
         invalidateSelf();
     }
 
+    /**
+     * Jump all animations to their end state. The caller is responsible for
+     * removing the ripple from the list of animating ripples.
+     */
+    public void jump() {
+        endSoftwareAnimations();
+        cancelHardwareAnimations(true);
+    }
+
+    private void endSoftwareAnimations() {
+        if (mAnimOuterOpacity != null) {
+            mAnimOuterOpacity.end();
+            mAnimOuterOpacity = null;
+        }
+    }
+
     private Paint getTempPaint() {
         if (mTempPaint == null) {
             mTempPaint = new Paint();
@@ -410,28 +348,18 @@
         return mTempPaint;
     }
 
-    private void exitSoftware(int opacityDuration, int outerInflection, int inflectionOpacity) {
-        final ObjectAnimator xAnim = ObjectAnimator.ofFloat(this, "xGravity", 1);
-        xAnim.setAutoCancel(true);
-        xAnim.setDuration(opacityDuration);
-        xAnim.setInterpolator(DECEL_INTERPOLATOR);
-
-        final ObjectAnimator yAnim = ObjectAnimator.ofFloat(this, "yGravity", 1);
-        yAnim.setAutoCancel(true);
-        yAnim.setDuration(opacityDuration);
-        yAnim.setInterpolator(DECEL_INTERPOLATOR);
-
+    private void exitSoftware(int opacityDuration, int inflectionDuration, int inflectionOpacity) {
         final ObjectAnimator outerOpacityAnim;
-        if (outerInflection > 0) {
+        if (inflectionDuration > 0) {
             // Outer opacity continues to increase for a bit.
             outerOpacityAnim = ObjectAnimator.ofFloat(this,
                     "outerOpacity", inflectionOpacity / 255.0f);
             outerOpacityAnim.setAutoCancel(true);
-            outerOpacityAnim.setDuration(outerInflection);
+            outerOpacityAnim.setDuration(inflectionDuration);
             outerOpacityAnim.setInterpolator(LINEAR_INTERPOLATOR);
 
             // Chain the outer opacity exit animation.
-            final int outerDuration = opacityDuration - outerInflection;
+            final int outerDuration = opacityDuration - inflectionDuration;
             if (outerDuration > 0) {
                 outerOpacityAnim.addListener(new AnimatorListenerAdapter() {
                     @Override
@@ -464,52 +392,42 @@
         }
 
         mAnimOuterOpacity = outerOpacityAnim;
-        mAnimX = xAnim;
-        mAnimY = yAnim;
 
         outerOpacityAnim.start();
-        xAnim.start();
-        yAnim.start();
     }
 
     /**
-     * Cancel all animations.
+     * Cancel all animations. The caller is responsible for removing
+     * the ripple from the list of animating ripples.
      */
     public void cancel() {
         cancelSoftwareAnimations();
-        cancelHardwareAnimations();
+        cancelHardwareAnimations(true);
     }
 
     private void cancelSoftwareAnimations() {
         if (mAnimOuterOpacity != null) {
             mAnimOuterOpacity.cancel();
-        }
-
-        if (mAnimX != null) {
-            mAnimX.cancel();
-        }
-
-        if (mAnimY != null) {
-            mAnimY.cancel();
+            mAnimOuterOpacity = null;
         }
     }
 
     /**
      * Cancels any running hardware animations.
      */
-    private void cancelHardwareAnimations() {
+    private void cancelHardwareAnimations(boolean cancelPending) {
         final ArrayList<RenderNodeAnimator> runningAnimations = mRunningAnimations;
         final int N = runningAnimations.size();
         for (int i = 0; i < N; i++) {
             runningAnimations.get(i).cancel();
         }
-
         runningAnimations.clear();
-    }
 
-    private void removeSelf() {
-        // The owner will invalidate itself.
-        mOwner.removeBackground(this);
+        if (cancelPending && !mPendingAnimations.isEmpty()) {
+            mPendingAnimations.clear();
+        }
+
+        mHardwareAnimating = false;
     }
 
     private void invalidateSelf() {
@@ -519,17 +437,7 @@
     private final AnimatorListenerAdapter mAnimationListener = new AnimatorListenerAdapter() {
         @Override
         public void onAnimationEnd(Animator animation) {
-            removeSelf();
+            mHardwareAnimating = false;
         }
     };
-
-    /**
-    * Interpolator with a smooth log deceleration
-    */
-    private static final class LogInterpolator implements TimeInterpolator {
-        @Override
-        public float getInterpolation(float input) {
-            return 1 - (float) Math.pow(400, -input * 1.4);
-        }
-    }
 }
diff --git a/graphics/java/android/graphics/drawable/RippleDrawable.java b/graphics/java/android/graphics/drawable/RippleDrawable.java
index 0447e17..4fd98b7 100644
--- a/graphics/java/android/graphics/drawable/RippleDrawable.java
+++ b/graphics/java/android/graphics/drawable/RippleDrawable.java
@@ -33,7 +33,6 @@
 import android.graphics.Rect;
 import android.util.AttributeSet;
 import android.util.DisplayMetrics;
-import android.util.Log;
 
 import com.android.internal.R;
 
@@ -41,6 +40,7 @@
 import org.xmlpull.v1.XmlPullParserException;
 
 import java.io.IOException;
+import java.util.Arrays;
 
 /**
  * Drawable that shows a ripple effect in response to state changes. The
@@ -88,7 +88,6 @@
  * @attr ref android.R.styleable#RippleDrawable_color
  */
 public class RippleDrawable extends LayerDrawable {
-    private static final String LOG_TAG = RippleDrawable.class.getSimpleName();
     private static final PorterDuffXfermode DST_IN = new PorterDuffXfermode(Mode.DST_IN);
     private static final PorterDuffXfermode SRC_ATOP = new PorterDuffXfermode(Mode.SRC_ATOP);
     private static final PorterDuffXfermode SRC_OVER = new PorterDuffXfermode(Mode.SRC_OVER);
@@ -141,8 +140,8 @@
      * Lazily-created array of actively animating ripples. Inactive ripples are
      * pruned during draw(). The locations of these will not change.
      */
-    private Ripple[] mAnimatingRipples;
-    private int mAnimatingRipplesCount = 0;
+    private Ripple[] mExitingRipples;
+    private int mExitingRipplesCount = 0;
 
     /** Paint used to control appearance of ripples. */
     private Paint mRipplePaint;
@@ -157,10 +156,11 @@
     private boolean mOverrideBounds;
 
     /**
-     * Whether hotspots are being cleared. Used to prevent re-entry by
-     * animation finish listeners.
+     * Whether the next draw MUST draw something to canvas. Used to work around
+     * a bug in hardware invalidation following a render thread-accelerated
+     * animation.
      */
-    private boolean mClearingHotspots;
+    private boolean mNeedsDraw;
 
     /**
      * Constructor used for drawable inflation.
@@ -199,6 +199,46 @@
     }
 
     @Override
+    public void jumpToCurrentState() {
+        super.jumpToCurrentState();
+
+        boolean needsDraw = false;
+
+        if (mRipple != null) {
+            needsDraw |= mRipple.isHardwareAnimating();
+            mRipple.jump();
+        }
+
+        if (mBackground != null) {
+            needsDraw |= mBackground.isHardwareAnimating();
+            mBackground.jump();
+        }
+
+        needsDraw |= cancelExitingRipples();
+
+        mNeedsDraw = needsDraw;
+        invalidateSelf();
+    }
+
+    private boolean cancelExitingRipples() {
+        boolean needsDraw = false;
+
+        final int count = mExitingRipplesCount;
+        final Ripple[] ripples = mExitingRipples;
+        for (int i = 0; i < count; i++) {
+            needsDraw |= ripples[i].isHardwareAnimating();
+            ripples[i].cancel();
+        }
+
+        if (ripples != null) {
+            Arrays.fill(ripples, 0, count, null);
+        }
+        mExitingRipplesCount = 0;
+
+        return needsDraw;
+    }
+
+    @Override
     public void setAlpha(int alpha) {
         super.setAlpha(alpha);
 
@@ -220,21 +260,20 @@
 
     @Override
     protected boolean onStateChange(int[] stateSet) {
-        super.onStateChange(stateSet);
+        final boolean changed = super.onStateChange(stateSet);
 
         boolean enabled = false;
         boolean pressed = false;
         boolean focused = false;
 
-        final int N = stateSet.length;
-        for (int i = 0; i < N; i++) {
-            if (stateSet[i] == R.attr.state_enabled) {
+        for (int state : stateSet) {
+            if (state == R.attr.state_enabled) {
                 enabled = true;
             }
-            if (stateSet[i] == R.attr.state_focused) {
+            if (state == R.attr.state_focused) {
                 focused = true;
             }
-            if (stateSet[i] == R.attr.state_pressed) {
+            if (state == R.attr.state_pressed) {
                 pressed = true;
             }
         }
@@ -242,28 +281,16 @@
         setRippleActive(enabled && pressed);
         setBackgroundActive(focused || (enabled && pressed));
 
-        // Update the paint color. Only applicable when animated in software.
-        if (mRipplePaint != null && mState.mColor != null) {
-            final ColorStateList stateList = mState.mColor;
-            final int newColor = stateList.getColorForState(stateSet, 0);
-            final int oldColor = mRipplePaint.getColor();
-            if (oldColor != newColor) {
-                mRipplePaint.setColor(newColor);
-                invalidateSelf();
-                return true;
-            }
-        }
-
-        return false;
+        return changed;
     }
 
     private void setRippleActive(boolean active) {
         if (mRippleActive != active) {
             mRippleActive = active;
             if (active) {
-                activateRipple();
+                tryRippleEnter();
             } else {
-                removeRipple();
+                tryRippleExit();
             }
         }
     }
@@ -272,9 +299,9 @@
         if (mBackgroundActive != active) {
             mBackgroundActive = active;
             if (active) {
-                activateBackground();
+                tryBackgroundEnter();
             } else {
-                removeBackground();
+                tryBackgroundExit();
             }
         }
     }
@@ -301,11 +328,11 @@
             // If we just became visible, ensure the background and ripple
             // visibilities are consistent with their internal states.
             if (mRippleActive) {
-                activateRipple();
+                tryRippleEnter();
             }
 
             if (mBackgroundActive) {
-                activateBackground();
+                tryBackgroundEnter();
             }
         }
 
@@ -456,28 +483,14 @@
         if (mRipple != null) {
             mRipple.move(x, y);
         }
-
-        if (mBackground != null) {
-            mBackground.move(x, y);
-        }
     }
 
     /**
      * Creates an active hotspot at the specified location.
      */
-    private void activateBackground() {
+    private void tryBackgroundEnter() {
         if (mBackground == null) {
-            final float x;
-            final float y;
-            if (mHasPending) {
-                mHasPending = false;
-                x = mPendingX;
-                y = mPendingY;
-            } else {
-                x = mHotspotBounds.exactCenterX();
-                y = mHotspotBounds.exactCenterY();
-            }
-            mBackground = new RippleBackground(this, mHotspotBounds, x, y);
+            mBackground = new RippleBackground(this, mHotspotBounds);
         }
 
         final int color = mState.mColor.getColorForState(getState(), Color.TRANSPARENT);
@@ -485,7 +498,7 @@
         mBackground.enter();
     }
 
-    private void removeBackground() {
+    private void tryBackgroundExit() {
         if (mBackground != null) {
             // Don't null out the background, we need it to draw!
             mBackground.exit();
@@ -493,10 +506,11 @@
     }
 
     /**
-     * Creates an active hotspot at the specified location.
+     * Attempts to start an enter animation for the active hotspot. Fails if
+     * there are too many animating ripples.
      */
-    private void activateRipple() {
-        if (mAnimatingRipplesCount >= MAX_RIPPLES) {
+    private void tryRippleEnter() {
+        if (mExitingRipplesCount >= MAX_RIPPLES) {
             // This should never happen unless the user is tapping like a maniac
             // or there is a bug that's preventing ripples from being removed.
             return;
@@ -519,45 +533,45 @@
         final int color = mState.mColor.getColorForState(getState(), Color.TRANSPARENT);
         mRipple.setup(mState.mMaxRadius, color, mDensity);
         mRipple.enter();
-
-        if (mAnimatingRipples == null) {
-            mAnimatingRipples = new Ripple[MAX_RIPPLES];
-        }
-        mAnimatingRipples[mAnimatingRipplesCount++] = mRipple;
     }
 
-    private void removeRipple() {
+    /**
+     * Attempts to start an exit animation for the active hotspot. Fails if
+     * there is no active hotspot.
+     */
+    private void tryRippleExit() {
         if (mRipple != null) {
+            if (mExitingRipples == null) {
+                mExitingRipples = new Ripple[MAX_RIPPLES];
+            }
+            mExitingRipples[mExitingRipplesCount++] = mRipple;
             mRipple.exit();
             mRipple = null;
         }
     }
 
+    /**
+     * Cancels and removes the active ripple, all exiting ripples, and the
+     * background. Nothing will be drawn after this method is called.
+     */
     private void clearHotspots() {
-        mClearingHotspots = true;
-
-        final int count = mAnimatingRipplesCount;
-        final Ripple[] ripples = mAnimatingRipples;
-        for (int i = 0; i < count; i++) {
-            // Calling cancel may remove the ripple from the animating ripple
-            // array, so cache the reference before nulling it out.
-            final Ripple ripple = ripples[i];
-            ripples[i] = null;
-            ripple.cancel();
-        }
+        boolean needsDraw = false;
 
         if (mRipple != null) {
+            needsDraw |= mRipple.isHardwareAnimating();
             mRipple.cancel();
             mRipple = null;
         }
 
         if (mBackground != null) {
+            needsDraw |= mBackground.isHardwareAnimating();
             mBackground.cancel();
             mBackground = null;
         }
 
-        mClearingHotspots = false;
-        mAnimatingRipplesCount = 0;
+        needsDraw |= cancelExitingRipples();
+
+        mNeedsDraw = needsDraw;
         invalidateSelf();
     }
 
@@ -579,12 +593,16 @@
      * Notifies all the animating ripples that the hotspot bounds have changed.
      */
     private void onHotspotBoundsChanged() {
-        final int count = mAnimatingRipplesCount;
-        final Ripple[] ripples = mAnimatingRipples;
+        final int count = mExitingRipplesCount;
+        final Ripple[] ripples = mExitingRipples;
         for (int i = 0; i < count; i++) {
             ripples[i].onHotspotBoundsChanged();
         }
 
+        if (mRipple != null) {
+            mRipple.onHotspotBoundsChanged();
+        }
+
         if (mBackground != null) {
             mBackground.onHotspotBoundsChanged();
         }
@@ -611,22 +629,27 @@
 
     @Override
     public void draw(@NonNull Canvas canvas) {
-        final boolean isProjected = isProjected();
         final boolean hasMask = mMask != null;
         final boolean drawNonMaskContent = mLayerState.mNum > (hasMask ? 1 : 0);
         final boolean drawMask = hasMask && mMask.getOpacity() != PixelFormat.OPAQUE;
-        final Rect bounds = isProjected ? getDirtyBounds() : getBounds();
+        final Rect bounds = getDirtyBounds();
+        final int saveCount = canvas.save(Canvas.CLIP_SAVE_FLAG);
+        canvas.clipRect(bounds);
 
         // If we have content, draw it into a layer first.
-        final int contentLayer = drawNonMaskContent ?
-                drawContentLayer(canvas, bounds, SRC_OVER) : -1;
+        final int contentLayer;
+        if (drawNonMaskContent) {
+            contentLayer = drawContentLayer(canvas, bounds, SRC_OVER);
+        } else {
+            contentLayer = -1;
+        }
 
         // Next, try to draw the ripples (into a layer if necessary). If we need
         // to mask against the underlying content, set the xfermode to SRC_ATOP.
         final PorterDuffXfermode xfermode = (hasMask || !drawNonMaskContent) ? SRC_OVER : SRC_ATOP;
 
         // If we have a background and a non-opaque mask, draw the masking layer.
-        final int backgroundLayer = drawBackgroundLayer(canvas, bounds, xfermode);
+        final int backgroundLayer = drawBackgroundLayer(canvas, bounds, xfermode, drawMask);
         if (backgroundLayer >= 0) {
             if (drawMask) {
                 drawMaskingLayer(canvas, bounds, DST_IN);
@@ -643,42 +666,42 @@
             canvas.restoreToCount(rippleLayer);
         }
 
-        // Composite the layers if needed.
-        if (contentLayer >= 0) {
-            canvas.restoreToCount(contentLayer);
+        // If we failed to draw anything and we just canceled animations, at
+        // least draw a color so that hardware invalidation works correctly.
+        if (contentLayer < 0 && backgroundLayer < 0 && rippleLayer < 0 && mNeedsDraw) {
+            canvas.drawColor(Color.TRANSPARENT);
+
+            // Request another draw so we can avoid adding a transparent layer
+            // during the next display list refresh.
+            invalidateSelf();
         }
+        mNeedsDraw = false;
+
+        canvas.restoreToCount(saveCount);
     }
 
     /**
-     * Removes a ripple from the animating ripple list.
+     * Removes a ripple from the exiting ripple list.
      *
      * @param ripple the ripple to remove
      */
     void removeRipple(Ripple ripple) {
-        if (!mClearingHotspots) {
-            // Ripple ripple ripple ripple. Ripple ripple.
-            final Ripple[] ripples = mAnimatingRipples;
-            final int count = mAnimatingRipplesCount;
-            final int index = getRippleIndex(ripple);
-            if (index >= 0) {
-                System.arraycopy(ripples, index + 1, ripples, index + 1 - 1, count - (index + 1));
-                ripples[count - 1] = null;
-                mAnimatingRipplesCount--;
-                invalidateSelf();
-            }
-        }
-    }
+        // Ripple ripple ripple ripple. Ripple ripple.
+        final Ripple[] ripples = mExitingRipples;
+        final int count = mExitingRipplesCount;
+        final int index = getRippleIndex(ripple);
+        if (index >= 0) {
+            System.arraycopy(ripples, index + 1, ripples, index, count - (index + 1));
+            ripples[count - 1] = null;
+            mExitingRipplesCount--;
 
-    void removeBackground(RippleBackground background) {
-        if (mBackground == background) {
-            mBackground = null;
             invalidateSelf();
         }
     }
 
     private int getRippleIndex(Ripple ripple) {
-        final Ripple[] ripples = mAnimatingRipples;
-        final int count = mAnimatingRipplesCount;
+        final Ripple[] ripples = mExitingRipples;
+        final int count = mExitingRipplesCount;
         for (int i = 0; i < count; i++) {
             if (ripples[i] == ripple) {
                 return i;
@@ -694,7 +717,7 @@
         // We don't need a layer if we don't expect to draw any ripples, we have
         // an explicit mask, or if the non-mask content is all opaque.
         boolean needsLayer = false;
-        if ((mAnimatingRipplesCount > 0 || mBackground != null) && mMask == null) {
+        if ((mExitingRipplesCount > 0 || mBackground != null) && mMask == null) {
             for (int i = 0; i < count; i++) {
                 if (array[i].mId != R.id.mask
                         && array[i].mDrawable.getOpacity() != PixelFormat.OPAQUE) {
@@ -718,105 +741,65 @@
         return restoreToCount;
     }
 
-    private int drawBackgroundLayer(Canvas canvas, Rect bounds, PorterDuffXfermode mode) {
-        // Separate the ripple color and alpha channel. The alpha will be
-        // applied when we merge the ripples down to the canvas.
-        final int rippleARGB;
-        if (mState.mColor != null) {
-            rippleARGB = mState.mColor.getColorForState(getState(), Color.TRANSPARENT);
-        } else {
-            rippleARGB = Color.TRANSPARENT;
+    private int drawBackgroundLayer(
+            Canvas canvas, Rect bounds, PorterDuffXfermode mode, boolean drawMask) {
+        int saveCount = -1;
+
+        if (mBackground != null && mBackground.shouldDraw()) {
+            // TODO: We can avoid saveLayer here if we push the xfermode into
+            // the background's render thread animator at exit() time.
+            if (drawMask || mode != SRC_OVER) {
+                saveCount = canvas.saveLayer(bounds.left, bounds.top, bounds.right,
+                        bounds.bottom, getMaskingPaint(mode));
+            }
+
+            final float x = mHotspotBounds.exactCenterX();
+            final float y = mHotspotBounds.exactCenterY();
+            canvas.translate(x, y);
+            mBackground.draw(canvas, getRipplePaint());
+            canvas.translate(-x, -y);
         }
 
-        if (mRipplePaint == null) {
-            mRipplePaint = new Paint();
-            mRipplePaint.setAntiAlias(true);
-        }
-
-        final int rippleAlpha = Color.alpha(rippleARGB);
-        final Paint ripplePaint = mRipplePaint;
-        ripplePaint.setColor(rippleARGB);
-        ripplePaint.setAlpha(0xFF);
-
-        boolean drewRipples = false;
-        int restoreToCount = -1;
-        int restoreTranslate = -1;
-
-        // Draw background.
-        final RippleBackground background = mBackground;
-        if (background != null) {
-            // If we're masking the ripple layer, make sure we have a layer
-            // first. This will merge SRC_OVER (directly) onto the canvas.
-            final Paint maskingPaint = getMaskingPaint(mode);
-            maskingPaint.setAlpha(rippleAlpha);
-            restoreToCount = canvas.saveLayer(bounds.left, bounds.top,
-                    bounds.right, bounds.bottom, maskingPaint);
-
-            restoreTranslate = canvas.save();
-            // Translate the canvas to the current hotspot bounds.
-            canvas.translate(mHotspotBounds.exactCenterX(), mHotspotBounds.exactCenterY());
-
-            drewRipples = background.draw(canvas, ripplePaint);
-        }
-
-        // Always restore the translation.
-        if (restoreTranslate >= 0) {
-            canvas.restoreToCount(restoreTranslate);
-        }
-
-        // If we created a layer with no content, merge it immediately.
-        if (restoreToCount >= 0 && !drewRipples) {
-            canvas.restoreToCount(restoreToCount);
-            restoreToCount = -1;
-        }
-
-        return restoreToCount;
+        return saveCount;
     }
 
     private int drawRippleLayer(Canvas canvas, Rect bounds, PorterDuffXfermode mode) {
-        // Separate the ripple color and alpha channel. The alpha will be
-        // applied when we merge the ripples down to the canvas.
-        final int rippleARGB;
-        if (mState.mColor != null) {
-            rippleARGB = mState.mColor.getColorForState(getState(), Color.TRANSPARENT);
-        } else {
-            rippleARGB = Color.TRANSPARENT;
-        }
-
-        if (mRipplePaint == null) {
-            mRipplePaint = new Paint();
-            mRipplePaint.setAntiAlias(true);
-        }
-
-        final int rippleAlpha = Color.alpha(rippleARGB);
-        final Paint ripplePaint = mRipplePaint;
-        ripplePaint.setColor(rippleARGB);
-        ripplePaint.setAlpha(0xFF);
-
         boolean drewRipples = false;
         int restoreToCount = -1;
         int restoreTranslate = -1;
 
         // Draw ripples and update the animating ripples array.
-        final int count = mAnimatingRipplesCount;
-        final Ripple[] ripples = mAnimatingRipples;
-        for (int i = 0; i < count; i++) {
-            final Ripple ripple = ripples[i];
+        final int count = mExitingRipplesCount;
+        final Ripple[] ripples = mExitingRipples;
+        for (int i = 0; i <= count; i++) {
+            final Ripple ripple;
+            if (i < count) {
+                ripple = ripples[i];
+            } else if (mRipple != null) {
+                ripple = mRipple;
+            } else {
+                continue;
+            }
 
             // If we're masking the ripple layer, make sure we have a layer
             // first. This will merge SRC_OVER (directly) onto the canvas.
             if (restoreToCount < 0) {
                 final Paint maskingPaint = getMaskingPaint(mode);
-                maskingPaint.setAlpha(rippleAlpha);
+                final int color = mState.mColor.getColorForState(getState(), Color.TRANSPARENT);
+                final int alpha = Color.alpha(color);
+                maskingPaint.setAlpha(alpha / 2);
+
+                // TODO: We can avoid saveLayer here if we're only drawing one
+                // ripple and we don't have content or a translucent mask.
                 restoreToCount = canvas.saveLayer(bounds.left, bounds.top,
                         bounds.right, bounds.bottom, maskingPaint);
 
-                restoreTranslate = canvas.save();
                 // Translate the canvas to the current hotspot bounds.
+                restoreTranslate = canvas.save();
                 canvas.translate(mHotspotBounds.exactCenterX(), mHotspotBounds.exactCenterY());
             }
 
-            drewRipples |= ripple.draw(canvas, ripplePaint);
+            drewRipples |= ripple.draw(canvas, getRipplePaint());
         }
 
         // Always restore the translation.
@@ -845,6 +828,14 @@
         return restoreToCount;
     }
 
+    private Paint getRipplePaint() {
+        if (mRipplePaint == null) {
+            mRipplePaint = new Paint();
+            mRipplePaint.setAntiAlias(true);
+        }
+        return mRipplePaint;
+    }
+
     private Paint getMaskingPaint(PorterDuffXfermode xfermode) {
         if (mMaskingPaint == null) {
             mMaskingPaint = new Paint();
@@ -865,8 +856,9 @@
             final int cX = (int) mHotspotBounds.exactCenterX();
             final int cY = (int) mHotspotBounds.exactCenterY();
             final Rect rippleBounds = mTempRect;
-            final Ripple[] activeRipples = mAnimatingRipples;
-            final int N = mAnimatingRipplesCount;
+
+            final Ripple[] activeRipples = mExitingRipples;
+            final int N = mExitingRipplesCount;
             for (int i = 0; i < N; i++) {
                 activeRipples[i].getBounds(rippleBounds);
                 rippleBounds.offset(cX, cY);
diff --git a/graphics/java/android/graphics/drawable/RotateDrawable.java b/graphics/java/android/graphics/drawable/RotateDrawable.java
index 63b9e02..70482a6 100644
--- a/graphics/java/android/graphics/drawable/RotateDrawable.java
+++ b/graphics/java/android/graphics/drawable/RotateDrawable.java
@@ -507,21 +507,23 @@
         private boolean mCanConstantState;
         private boolean mCheckedConstantState;
 
-        public RotateState(RotateState source, RotateDrawable owner, Resources res) {
-            if (source != null) {
+        public RotateState(RotateState orig, RotateDrawable owner, Resources res) {
+            if (orig != null) {
                 if (res != null) {
-                    mDrawable = source.mDrawable.getConstantState().newDrawable(res);
+                    mDrawable = orig.mDrawable.getConstantState().newDrawable(res);
                 } else {
-                    mDrawable = source.mDrawable.getConstantState().newDrawable();
+                    mDrawable = orig.mDrawable.getConstantState().newDrawable();
                 }
                 mDrawable.setCallback(owner);
-                mDrawable.setLayoutDirection(source.mDrawable.getLayoutDirection());
-                mPivotXRel = source.mPivotXRel;
-                mPivotX = source.mPivotX;
-                mPivotYRel = source.mPivotYRel;
-                mPivotY = source.mPivotY;
-                mFromDegrees = mCurrentDegrees = source.mFromDegrees;
-                mToDegrees = source.mToDegrees;
+                mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+                mDrawable.setBounds(orig.mDrawable.getBounds());
+                mDrawable.setLevel(orig.mDrawable.getLevel());
+                mPivotXRel = orig.mPivotXRel;
+                mPivotX = orig.mPivotX;
+                mPivotYRel = orig.mPivotYRel;
+                mPivotY = orig.mPivotY;
+                mFromDegrees = mCurrentDegrees = orig.mFromDegrees;
+                mToDegrees = orig.mToDegrees;
                 mCanConstantState = mCheckedConstantState = true;
             }
         }
diff --git a/graphics/java/android/graphics/drawable/ScaleDrawable.java b/graphics/java/android/graphics/drawable/ScaleDrawable.java
index a954474..b40038a 100644
--- a/graphics/java/android/graphics/drawable/ScaleDrawable.java
+++ b/graphics/java/android/graphics/drawable/ScaleDrawable.java
@@ -295,6 +295,8 @@
                 }
                 mDrawable.setCallback(owner);
                 mDrawable.setLayoutDirection(orig.mDrawable.getLayoutDirection());
+                mDrawable.setBounds(orig.mDrawable.getBounds());
+                mDrawable.setLevel(orig.mDrawable.getLevel());
                 mScaleWidth = orig.mScaleWidth;
                 mScaleHeight = orig.mScaleHeight;
                 mGravity = orig.mGravity;
diff --git a/graphics/java/android/graphics/drawable/ShapeDrawable.java b/graphics/java/android/graphics/drawable/ShapeDrawable.java
index 6f18635..bd69d76 100644
--- a/graphics/java/android/graphics/drawable/ShapeDrawable.java
+++ b/graphics/java/android/graphics/drawable/ShapeDrawable.java
@@ -515,8 +515,8 @@
         int mChangingConfigurations;
         Paint mPaint;
         Shape mShape;
-        ColorStateList mTint;
-        Mode mTintMode = Mode.SRC_IN;
+        ColorStateList mTint = null;
+        Mode mTintMode = DEFAULT_TINT_MODE;
         Rect mPadding;
         int mIntrinsicWidth;
         int mIntrinsicHeight;
diff --git a/graphics/java/android/graphics/drawable/VectorDrawable.java b/graphics/java/android/graphics/drawable/VectorDrawable.java
index 9ac6927..ace5eab 100644
--- a/graphics/java/android/graphics/drawable/VectorDrawable.java
+++ b/graphics/java/android/graphics/drawable/VectorDrawable.java
@@ -42,7 +42,6 @@
 
 import org.xmlpull.v1.XmlPullParser;
 import org.xmlpull.v1.XmlPullParserException;
-import org.xmlpull.v1.XmlPullParserFactory;
 
 import java.io.IOException;
 import java.util.ArrayList;
@@ -104,8 +103,6 @@
  * <dt><code>android:translateY</code></dt>
  * <dd>The amount of translation on the Y coordinate.
  * This is defined in the viewport space.</dd>
- * <dt><code>android:alpha</code></dt>
- * <dd>The amount of transparency.</dd>
  * </dl></dd>
  * </dl>
  *
@@ -119,11 +116,15 @@
  * <dd>Defines path string. This is using exactly same format as "d" attribute
  * in the SVG's path data. This is defined in the viewport space.</dd>
  * <dt><code>android:fillColor</code></dt>
- * <dd>Defines the color to fill the path (black if not present).</dd>
+ * <dd>Defines the color to fill the path (none if not present).</dd>
  * <dt><code>android:strokeColor</code></dt>
  * <dd>Defines the color to draw the path outline (none if not present).</dd>
  * <dt><code>android:strokeWidth</code></dt>
  * <dd>The width a path stroke.</dd>
+ * <dt><code>android:strokeAlpha</code></dt>
+ * <dd>The opacity of a path stroke.</dd>
+ * <dt><code>android:fillAlpha</code></dt>
+ * <dd>The opacity to fill the path with.</dd>
  * <dt><code>android:trimPathStart</code></dt>
  * <dd>The fraction of the path to trim from the start, in the range from 0 to 1.</dd>
  * <dt><code>android:trimPathEnd</code></dt>
@@ -193,6 +194,7 @@
     private VectorDrawableState mVectorState;
 
     private PorterDuffColorFilter mTintFilter;
+    private ColorFilter mColorFilter;
 
     private boolean mMutated;
 
@@ -214,7 +216,6 @@
         }
 
         mTintFilter = updateTintFilter(mTintFilter, state.mTint, state.mTintMode);
-        mVectorState.mVPathRenderer.setColorFilter(mTintFilter);
     }
 
     @Override
@@ -253,22 +254,27 @@
             canvas.scale(-1.0f, 1.0f);
         }
 
-        if (!mAllowCaching) {
-            mVectorState.mVPathRenderer.draw(canvas, bounds.width(), bounds.height());
-        } else {
-            Bitmap bitmap = mVectorState.mCachedBitmap;
-            if (bitmap == null || !mVectorState.canReuseCache(bounds.width(),
-                    bounds.height())) {
-                bitmap = Bitmap.createBitmap(bounds.width(), bounds.height(),
-                        Bitmap.Config.ARGB_8888);
-                Canvas tmpCanvas = new Canvas(bitmap);
-                mVectorState.mVPathRenderer.draw(tmpCanvas, bounds.width(), bounds.height());
-                mVectorState.mCachedBitmap = bitmap;
+        // Color filters always override tint filters.
+        final ColorFilter colorFilter = mColorFilter == null ? mTintFilter : mColorFilter;
 
+        if (!mAllowCaching) {
+            // AnimatedVectorDrawable
+            if (!mVectorState.hasTranslucentRoot()) {
+                mVectorState.mVPathRenderer.draw(
+                        canvas, bounds.width(), bounds.height(), colorFilter);
+            } else {
+                mVectorState.createCachedBitmapIfNeeded(bounds);
+                mVectorState.updateCachedBitmap(bounds);
+                mVectorState.drawCachedBitmapWithRootAlpha(canvas, colorFilter);
+            }
+        } else {
+            // Static Vector Drawable case.
+            mVectorState.createCachedBitmapIfNeeded(bounds);
+            if (!mVectorState.canReuseCache()) {
+                mVectorState.updateCachedBitmap(bounds);
                 mVectorState.updateCacheStates();
             }
-            // The bitmap's size is the same as the bounds.
-            canvas.drawBitmap(bitmap, 0, 0, null);
+            mVectorState.drawCachedBitmapWithRootAlpha(canvas, colorFilter);
         }
 
         canvas.restoreToCount(saveCount);
@@ -289,18 +295,7 @@
 
     @Override
     public void setColorFilter(ColorFilter colorFilter) {
-        final VectorDrawableState state = mVectorState;
-        if (colorFilter != null) {
-            // Color filter overrides tint.
-            mTintFilter = null;
-        } else if (state.mTint != null && state.mTintMode != null) {
-            // Restore the tint filter, if we need one.
-            final int color = state.mTint.getColorForState(getState(), Color.TRANSPARENT);
-            mTintFilter = new PorterDuffColorFilter(color, state.mTintMode);
-            colorFilter = mTintFilter;
-        }
-
-        state.mVPathRenderer.setColorFilter(colorFilter);
+        mColorFilter = colorFilter;
         invalidateSelf();
     }
 
@@ -310,7 +305,6 @@
         if (state.mTint != tint) {
             state.mTint = tint;
             mTintFilter = updateTintFilter(mTintFilter, tint, state.mTintMode);
-            state.mVPathRenderer.setColorFilter(mTintFilter);
             invalidateSelf();
         }
     }
@@ -321,17 +315,22 @@
         if (state.mTintMode != tintMode) {
             state.mTintMode = tintMode;
             mTintFilter = updateTintFilter(mTintFilter, state.mTint, tintMode);
-            state.mVPathRenderer.setColorFilter(mTintFilter);
             invalidateSelf();
         }
     }
 
     @Override
+    public boolean isStateful() {
+        return super.isStateful() || (mVectorState != null && mVectorState.mTint != null
+                && mVectorState.mTint.isStateful());
+    }
+
+    @Override
     protected boolean onStateChange(int[] stateSet) {
         final VectorDrawableState state = mVectorState;
         if (state.mTint != null && state.mTintMode != null) {
             mTintFilter = updateTintFilter(mTintFilter, state.mTint, state.mTintMode);
-            mVectorState.mVPathRenderer.setColorFilter(mTintFilter);
+            invalidateSelf();
             return true;
         }
         return false;
@@ -362,12 +361,49 @@
         super.applyTheme(t);
 
         final VectorDrawableState state = mVectorState;
+        if (state != null && state.mThemeAttrs != null) {
+            final TypedArray a = t.resolveAttributes(state.mThemeAttrs, R.styleable.VectorDrawable);
+            try {
+                state.mCacheDirty = true;
+                updateStateFromTypedArray(a);
+            } catch (XmlPullParserException e) {
+                throw new RuntimeException(e);
+            } finally {
+                a.recycle();
+            }
+
+            mTintFilter = updateTintFilter(mTintFilter, state.mTint, state.mTintMode);
+        }
+
         final VPathRenderer path = state.mVPathRenderer;
         if (path != null && path.canApplyTheme()) {
             path.applyTheme(t);
         }
     }
 
+    /**
+     * The size of a pixel when scaled from the intrinsic dimension to the viewport dimension.
+     * This is used to calculate the path animation accuracy.
+     *
+     * @hide
+     */
+    public float getPixelSize() {
+        if (mVectorState == null && mVectorState.mVPathRenderer == null ||
+                mVectorState.mVPathRenderer.mBaseWidth == 0 ||
+                mVectorState.mVPathRenderer.mBaseHeight == 0 ||
+                mVectorState.mVPathRenderer.mViewportHeight == 0 ||
+                mVectorState.mVPathRenderer.mViewportWidth == 0) {
+            return 1; // fall back to 1:1 pixel mapping.
+        }
+        float intrinsicWidth = mVectorState.mVPathRenderer.mBaseWidth;
+        float intrinsicHeight = mVectorState.mVPathRenderer.mBaseHeight;
+        float viewportWidth = mVectorState.mVPathRenderer.mViewportWidth;
+        float viewportHeight = mVectorState.mVPathRenderer.mViewportHeight;
+        float scaleX = viewportWidth / intrinsicWidth;
+        float scaleY = viewportHeight / intrinsicHeight;
+        return Math.min(scaleX, scaleY);
+    }
+
     /** @hide */
     public static VectorDrawable create(Resources resources, int rid) {
         try {
@@ -408,7 +444,7 @@
         final VPathRenderer pathRenderer = new VPathRenderer();
         state.mVPathRenderer = pathRenderer;
 
-        TypedArray a = obtainAttributes(res, theme, attrs, R.styleable.VectorDrawable);
+        final TypedArray a = obtainAttributes(res, theme, attrs, R.styleable.VectorDrawable);
         updateStateFromTypedArray(a);
         a.recycle();
 
@@ -416,7 +452,6 @@
         inflateInternal(res, parser, attrs, theme);
 
         mTintFilter = updateTintFilter(mTintFilter, state.mTint, state.mTintMode);
-        state.mVPathRenderer.setColorFilter(mTintFilter);
     }
 
     private void updateStateFromTypedArray(TypedArray a) throws XmlPullParserException {
@@ -467,6 +502,15 @@
             throw new XmlPullParserException(a.getPositionDescription() +
                     "<vector> tag requires height > 0");
         }
+
+        final float alphaInFloat = a.getFloat(R.styleable.VectorDrawable_alpha,
+                pathRenderer.getAlpha());
+        pathRenderer.setAlpha(alphaInFloat);
+
+        pathRenderer.mRootName = a.getString(R.styleable.VectorDrawable_name);
+        if (pathRenderer.mRootName != null) {
+            pathRenderer.mVGTargetsMap.put(pathRenderer.mRootName, pathRenderer);
+        }
     }
 
     private void inflateInternal(Resources res, XmlPullParser parser, AttributeSet attrs,
@@ -588,8 +632,8 @@
         int[] mThemeAttrs;
         int mChangingConfigurations;
         VPathRenderer mVPathRenderer;
-        ColorStateList mTint;
-        Mode mTintMode;
+        ColorStateList mTint = null;
+        Mode mTintMode = DEFAULT_TINT_MODE;
         boolean mAutoMirrored;
 
         Bitmap mCachedBitmap;
@@ -600,27 +644,84 @@
         boolean mCachedAutoMirrored;
         boolean mCacheDirty;
 
+        /** Temporary paint object used to draw cached bitmaps. */
+        Paint mTempPaint;
+
         // Deep copy for mutate() or implicitly mutate.
         public VectorDrawableState(VectorDrawableState copy) {
             if (copy != null) {
                 mThemeAttrs = copy.mThemeAttrs;
                 mChangingConfigurations = copy.mChangingConfigurations;
                 mVPathRenderer = new VPathRenderer(copy.mVPathRenderer);
+                if (copy.mVPathRenderer.mFillPaint != null) {
+                    mVPathRenderer.mFillPaint = new Paint(copy.mVPathRenderer.mFillPaint);
+                }
+                if (copy.mVPathRenderer.mStrokePaint != null) {
+                    mVPathRenderer.mStrokePaint = new Paint(copy.mVPathRenderer.mStrokePaint);
+                }
                 mTint = copy.mTint;
                 mTintMode = copy.mTintMode;
                 mAutoMirrored = copy.mAutoMirrored;
             }
         }
 
-        public boolean canReuseCache(int width, int height) {
+        public void drawCachedBitmapWithRootAlpha(Canvas canvas, ColorFilter filter) {
+            // The bitmap's size is the same as the bounds.
+            final Paint p = getPaint(filter);
+            canvas.drawBitmap(mCachedBitmap, 0, 0, p);
+        }
+
+        public boolean hasTranslucentRoot() {
+            return mVPathRenderer.getRootAlpha() < 255;
+        }
+
+        /**
+         * @return null when there is no need for alpha paint.
+         */
+        public Paint getPaint(ColorFilter filter) {
+            if (!hasTranslucentRoot() && filter == null) {
+                return null;
+            }
+
+            if (mTempPaint == null) {
+                mTempPaint = new Paint();
+            }
+            mTempPaint.setAlpha(mVPathRenderer.getRootAlpha());
+            mTempPaint.setColorFilter(filter);
+            return mTempPaint;
+        }
+
+        public void updateCachedBitmap(Rect bounds) {
+            mCachedBitmap.eraseColor(Color.TRANSPARENT);
+            Canvas tmpCanvas = new Canvas(mCachedBitmap);
+            mVPathRenderer.draw(tmpCanvas, bounds.width(), bounds.height(), null);
+        }
+
+        public void createCachedBitmapIfNeeded(Rect bounds) {
+            if (mCachedBitmap == null || !canReuseBitmap(bounds.width(),
+                    bounds.height())) {
+                mCachedBitmap = Bitmap.createBitmap(bounds.width(), bounds.height(),
+                        Bitmap.Config.ARGB_8888);
+                mCacheDirty = true;
+            }
+
+        }
+
+        public boolean canReuseBitmap(int width, int height) {
+            if (width == mCachedBitmap.getWidth()
+                    && height == mCachedBitmap.getHeight()) {
+                return true;
+            }
+            return false;
+        }
+
+        public boolean canReuseCache() {
             if (!mCacheDirty
                     && mCachedThemeAttrs == mThemeAttrs
                     && mCachedTint == mTint
                     && mCachedTintMode == mTintMode
                     && mCachedAutoMirrored == mAutoMirrored
-                    && width == mCachedBitmap.getWidth()
-                    && height == mCachedBitmap.getHeight()
-                    && mCachedRootAlpha == mVPathRenderer.getRootAlpha())  {
+                    && mCachedRootAlpha == mVPathRenderer.getRootAlpha()) {
                 return true;
             }
             return false;
@@ -637,6 +738,12 @@
             mCacheDirty = false;
         }
 
+        @Override
+        public boolean canApplyTheme() {
+            return super.canApplyTheme() || mThemeAttrs != null
+                    || (mVPathRenderer != null && mVPathRenderer.canApplyTheme());
+        }
+
         public VectorDrawableState() {
             mVPathRenderer = new VPathRenderer();
         }
@@ -677,14 +784,13 @@
          */
         // Variables that only used temporarily inside the draw() call, so there
         // is no need for deep copying.
-        private final Path mPath = new Path();
-        private final Path mRenderPath = new Path();
+        private final Path mPath;
+        private final Path mRenderPath;
         private static final Matrix IDENTITY_MATRIX = new Matrix();
         private final Matrix mFinalPathMatrix = new Matrix();
 
         private Paint mStrokePaint;
         private Paint mFillPaint;
-        private ColorFilter mColorFilter;
         private PathMeasure mPathMeasure;
 
         /////////////////////////////////////////////////////
@@ -695,12 +801,15 @@
         float mBaseHeight = 0;
         float mViewportWidth = 0;
         float mViewportHeight = 0;
-        private int mRootAlpha = 0xFF;
+        int mRootAlpha = 0xFF;
+        String mRootName = null;
 
         final ArrayMap<String, Object> mVGTargetsMap = new ArrayMap<String, Object>();
 
         public VPathRenderer() {
             mRootGroup = new VGroup();
+            mPath = new Path();
+            mRenderPath = new Path();
         }
 
         public void setRootAlpha(int alpha) {
@@ -711,14 +820,31 @@
             return mRootAlpha;
         }
 
+        // setAlpha() and getAlpha() are used mostly for animation purpose, since
+        // Animator like to use alpha from 0 to 1.
+        public void setAlpha(float alpha) {
+            setRootAlpha((int) (alpha * 255));
+        }
+
+        @SuppressWarnings("unused")
+        public float getAlpha() {
+            return getRootAlpha() / 255.0f;
+        }
+
         public VPathRenderer(VPathRenderer copy) {
             mRootGroup = new VGroup(copy.mRootGroup, mVGTargetsMap);
+            mPath = new Path(copy.mPath);
+            mRenderPath = new Path(copy.mRenderPath);
             mBaseWidth = copy.mBaseWidth;
             mBaseHeight = copy.mBaseHeight;
             mViewportWidth = copy.mViewportWidth;
             mViewportHeight = copy.mViewportHeight;
             mChangingConfigurations = copy.mChangingConfigurations;
             mRootAlpha = copy.mRootAlpha;
+            mRootName = copy.mRootName;
+            if (copy.mRootName != null) {
+                mVGTargetsMap.put(copy.mRootName, this);
+            }
         }
 
         public boolean canApplyTheme() {
@@ -775,21 +901,8 @@
             }
         }
 
-        public void setColorFilter(ColorFilter colorFilter) {
-            mColorFilter = colorFilter;
-
-            if (mFillPaint != null) {
-                mFillPaint.setColorFilter(colorFilter);
-            }
-
-            if (mStrokePaint != null) {
-                mStrokePaint.setColorFilter(colorFilter);
-            }
-
-        }
-
         private void drawGroupTree(VGroup currentGroup, Matrix currentMatrix,
-                float currentAlpha, Canvas canvas, int w, int h) {
+                Canvas canvas, int w, int h, ColorFilter filter) {
             // Calculate current group's matrix by preConcat the parent's and
             // and the current one on the top of the stack.
             // Basically the Mfinal = Mviewport * M0 * M1 * M2;
@@ -798,31 +911,28 @@
 
             currentGroup.mStackedMatrix.preConcat(currentGroup.mLocalMatrix);
 
-            float stackedAlpha = currentAlpha * currentGroup.mGroupAlpha;
-
             // Draw the group tree in the same order as the XML file.
             for (int i = 0; i < currentGroup.mChildren.size(); i++) {
                 Object child = currentGroup.mChildren.get(i);
                 if (child instanceof VGroup) {
                     VGroup childGroup = (VGroup) child;
                     drawGroupTree(childGroup, currentGroup.mStackedMatrix,
-                            stackedAlpha, canvas, w, h);
+                            canvas, w, h, filter);
                 } else if (child instanceof VPath) {
                     VPath childPath = (VPath) child;
-                    drawPath(currentGroup, childPath, stackedAlpha, canvas, w, h);
+                    drawPath(currentGroup, childPath, canvas, w, h, filter);
                 }
             }
         }
 
-        public void draw(Canvas canvas, int w, int h) {
+        public void draw(Canvas canvas, int w, int h, ColorFilter filter) {
             // Travese the tree in pre-order to draw.
-            drawGroupTree(mRootGroup, IDENTITY_MATRIX, ((float) mRootAlpha) / 0xFF,
-                    canvas, w, h);
+            drawGroupTree(mRootGroup, IDENTITY_MATRIX, canvas, w, h, filter);
         }
 
-        private void drawPath(VGroup vGroup, VPath vPath, float stackedAlpha,
-                Canvas canvas, int w, int h) {
-            final float scaleX =  w / mViewportWidth;
+        private void drawPath(VGroup vGroup, VPath vPath, Canvas canvas, int w, int h,
+                ColorFilter filter) {
+            final float scaleX = w / mViewportWidth;
             final float scaleY = h / mViewportHeight;
             final float minScale = Math.min(scaleX, scaleY);
 
@@ -862,21 +972,22 @@
                 }
                 mRenderPath.addPath(path, mFinalPathMatrix);
 
-                if (fullPath.mFillColor != 0) {
+                if (fullPath.mFillColor != Color.TRANSPARENT) {
                     if (mFillPaint == null) {
                         mFillPaint = new Paint();
-                        mFillPaint.setColorFilter(mColorFilter);
                         mFillPaint.setStyle(Paint.Style.FILL);
                         mFillPaint.setAntiAlias(true);
                     }
-                    mFillPaint.setColor(applyAlpha(fullPath.mFillColor, stackedAlpha));
-                    canvas.drawPath(mRenderPath, mFillPaint);
+
+                    final Paint fillPaint = mFillPaint;
+                    fillPaint.setColor(applyAlpha(fullPath.mFillColor, fullPath.mFillAlpha));
+                    fillPaint.setColorFilter(filter);
+                    canvas.drawPath(mRenderPath, fillPaint);
                 }
 
-                if (fullPath.mStrokeColor != 0) {
+                if (fullPath.mStrokeColor != Color.TRANSPARENT) {
                     if (mStrokePaint == null) {
                         mStrokePaint = new Paint();
-                        mStrokePaint.setColorFilter(mColorFilter);
                         mStrokePaint.setStyle(Paint.Style.STROKE);
                         mStrokePaint.setAntiAlias(true);
                     }
@@ -891,8 +1002,8 @@
                     }
 
                     strokePaint.setStrokeMiter(fullPath.mStrokeMiterlimit);
-
-                    strokePaint.setColor(applyAlpha(fullPath.mStrokeColor, stackedAlpha));
+                    strokePaint.setColor(applyAlpha(fullPath.mStrokeColor, fullPath.mStrokeAlpha));
+                    strokePaint.setColorFilter(filter);
                     strokePaint.setStrokeWidth(fullPath.mStrokeWidth * minScale);
                     canvas.drawPath(mRenderPath, strokePaint);
                 }
@@ -916,7 +1027,6 @@
         private float mScaleY = 1;
         private float mTranslateX = 0;
         private float mTranslateY = 0;
-        private float mGroupAlpha = 1;
 
         // mLocalMatrix is updated based on the update of transformation information,
         // either parsed from the XML or by animation.
@@ -933,7 +1043,6 @@
             mScaleY = copy.mScaleY;
             mTranslateX = copy.mTranslateX;
             mTranslateY = copy.mTranslateY;
-            mGroupAlpha = copy.mGroupAlpha;
             mThemeAttrs = copy.mThemeAttrs;
             mGroupName = copy.mGroupName;
             mChangingConfigurations = copy.mChangingConfigurations;
@@ -977,10 +1086,6 @@
             return mLocalMatrix;
         }
 
-        public boolean canApplyTheme() {
-            return mThemeAttrs != null;
-        }
-
         public void inflate(Resources res, AttributeSet attrs, Theme theme) {
             final TypedArray a = obtainAttributes(res, theme, attrs,
                     R.styleable.VectorDrawableGroup);
@@ -1002,7 +1107,6 @@
             mScaleY = a.getFloat(R.styleable.VectorDrawableGroup_scaleY, mScaleY);
             mTranslateX = a.getFloat(R.styleable.VectorDrawableGroup_translateX, mTranslateX);
             mTranslateY = a.getFloat(R.styleable.VectorDrawableGroup_translateY, mTranslateY);
-            mGroupAlpha = a.getFloat(R.styleable.VectorDrawableGroup_alpha, mGroupAlpha);
 
             final String groupName = a.getString(R.styleable.VectorDrawableGroup_name);
             if (groupName != null) {
@@ -1012,13 +1116,16 @@
             updateLocalMatrix();
         }
 
+        public boolean canApplyTheme() {
+            return mThemeAttrs != null;
+        }
+
         public void applyTheme(Theme t) {
             if (mThemeAttrs == null) {
                 return;
             }
 
-            final TypedArray a = t.resolveAttributes(mThemeAttrs,
-                    R.styleable.VectorDrawableGroup);
+            final TypedArray a = t.resolveAttributes(mThemeAttrs, R.styleable.VectorDrawableGroup);
             updateStateFromTypedArray(a);
             a.recycle();
         }
@@ -1124,18 +1231,6 @@
                 updateLocalMatrix();
             }
         }
-
-        @SuppressWarnings("unused")
-        public float getAlpha() {
-            return mGroupAlpha;
-        }
-
-        @SuppressWarnings("unused")
-        public void setAlpha(float groupAlpha) {
-            if (groupAlpha != mGroupAlpha) {
-                mGroupAlpha = groupAlpha;
-            }
-        }
     }
 
     /**
@@ -1198,7 +1293,7 @@
     /**
      * Clip path, which only has name and pathData.
      */
-    private static class VClipPath extends VPath{
+    private static class VClipPath extends VPath {
         public VClipPath() {
             // Empty constructor.
         }
@@ -1237,10 +1332,13 @@
         // Variables below need to be copied (deep copy if applicable) for mutation.
         private int[] mThemeAttrs;
 
-        int mStrokeColor = 0;
+        int mStrokeColor = Color.TRANSPARENT;
         float mStrokeWidth = 0;
-        int mFillColor = Color.BLACK;
+
+        int mFillColor = Color.TRANSPARENT;
+        float mStrokeAlpha = 1.0f;
         int mFillRule;
+        float mFillAlpha = 1.0f;
         float mTrimPathStart = 0;
         float mTrimPathEnd = 1;
         float mTrimPathOffset = 0;
@@ -1259,8 +1357,10 @@
 
             mStrokeColor = copy.mStrokeColor;
             mStrokeWidth = copy.mStrokeWidth;
+            mStrokeAlpha = copy.mStrokeAlpha;
             mFillColor = copy.mFillColor;
             mFillRule = copy.mFillRule;
+            mFillAlpha = copy.mFillAlpha;
             mTrimPathStart = copy.mTrimPathStart;
             mTrimPathEnd = copy.mTrimPathEnd;
             mTrimPathOffset = copy.mTrimPathOffset;
@@ -1321,6 +1421,8 @@
 
             mFillColor = a.getColor(R.styleable.VectorDrawablePath_fillColor,
                     mFillColor);
+            mFillAlpha = a.getFloat(R.styleable.VectorDrawablePath_fillAlpha,
+                    mFillAlpha);
             mStrokeLineCap = getStrokeLineCap(a.getInt(
                     R.styleable.VectorDrawablePath_strokeLineCap, -1), mStrokeLineCap);
             mStrokeLineJoin = getStrokeLineJoin(a.getInt(
@@ -1329,6 +1431,8 @@
                     R.styleable.VectorDrawablePath_strokeMiterLimit, mStrokeMiterlimit);
             mStrokeColor = a.getColor(R.styleable.VectorDrawablePath_strokeColor,
                     mStrokeColor);
+            mStrokeAlpha = a.getFloat(R.styleable.VectorDrawablePath_strokeAlpha,
+                    mStrokeAlpha);
             mStrokeWidth = a.getFloat(R.styleable.VectorDrawablePath_strokeWidth,
                     mStrokeWidth);
             mTrimPathEnd = a.getFloat(R.styleable.VectorDrawablePath_trimPathEnd,
@@ -1345,8 +1449,7 @@
                 return;
             }
 
-            final TypedArray a = t.resolveAttributes(mThemeAttrs,
-                    R.styleable.VectorDrawablePath);
+            final TypedArray a = t.resolveAttributes(mThemeAttrs, R.styleable.VectorDrawablePath);
             updateStateFromTypedArray(a);
             a.recycle();
         }
@@ -1373,6 +1476,16 @@
         }
 
         @SuppressWarnings("unused")
+        float getstrokeAlpha() {
+            return mStrokeAlpha;
+        }
+
+        @SuppressWarnings("unused")
+        void setstrokeAlpha(float strokeAlpha) {
+            mStrokeAlpha = strokeAlpha;
+        }
+
+        @SuppressWarnings("unused")
         int getFill() {
             return mFillColor;
         }
@@ -1383,6 +1496,16 @@
         }
 
         @SuppressWarnings("unused")
+        float getfillAlpha() {
+            return mFillAlpha;
+        }
+
+        @SuppressWarnings("unused")
+        void setfillAlpha(float fillAlpha) {
+            mFillAlpha = fillAlpha;
+        }
+
+        @SuppressWarnings("unused")
         float getTrimPathStart() {
             return mTrimPathStart;
         }
diff --git a/graphics/java/android/graphics/pdf/PdfEditor.java b/graphics/java/android/graphics/pdf/PdfEditor.java
new file mode 100644
index 0000000..9837139
--- /dev/null
+++ b/graphics/java/android/graphics/pdf/PdfEditor.java
@@ -0,0 +1,162 @@
+/*
+ * Copyright (C) 2014 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 android.graphics.pdf;
+
+import android.annotation.NonNull;
+import android.os.ParcelFileDescriptor;
+import android.system.ErrnoException;
+import android.system.OsConstants;
+import dalvik.system.CloseGuard;
+import libcore.io.IoUtils;
+import libcore.io.Libcore;
+
+import java.io.IOException;
+
+/**
+ * Class for editing PDF files.
+ *
+ * @hide
+ */
+public final class PdfEditor {
+
+    private final CloseGuard mCloseGuard = CloseGuard.get();
+
+    private final long mNativeDocument;
+
+    private int mPageCount;
+
+    private ParcelFileDescriptor mInput;
+
+    /**
+     * Creates a new instance.
+     * <p>
+     * <strong>Note:</strong> The provided file descriptor must be <strong>seekable</strong>,
+     * i.e. its data being randomly accessed, e.g. pointing to a file. After finishing
+     * with this class you must call {@link #close()}.
+     * </p>
+     * <p>
+     * <strong>Note:</strong> This class takes ownership of the passed in file descriptor
+     * and is responsible for closing it when the editor is closed.
+     * </p>
+     *
+     * @param input Seekable file descriptor to read from.
+     *
+     * @see #close()
+     */
+    public PdfEditor(@NonNull ParcelFileDescriptor input) throws IOException {
+        if (input == null) {
+            throw new NullPointerException("input cannot be null");
+        }
+
+        final long size;
+        try {
+            Libcore.os.lseek(input.getFileDescriptor(), 0, OsConstants.SEEK_SET);
+            size = Libcore.os.fstat(input.getFileDescriptor()).st_size;
+        } catch (ErrnoException ee) {
+            throw new IllegalArgumentException("file descriptor not seekable");
+        }
+
+        mInput = input;
+        mNativeDocument = nativeOpen(mInput.getFd(), size);
+        mPageCount = nativeGetPageCount(mNativeDocument);
+        mCloseGuard.open("close");
+    }
+
+    /**
+     * Gets the number of pages in the document.
+     *
+     * @return The page count.
+     */
+    public int getPageCount() {
+        throwIfClosed();
+        return mPageCount;
+    }
+
+    /**
+     * Removes the page with a given index.
+     *
+     * @param pageIndex The page to remove.
+     */
+    public void removePage(int pageIndex) {
+        throwIfClosed();
+        throwIfPageNotInDocument(pageIndex);
+        mPageCount = nativeRemovePage(mNativeDocument, pageIndex);
+    }
+
+    /**
+     * Writes the PDF file to the provided destination.
+     * <p>
+     * <strong>Note:</strong> This method takes ownership of the passed in file
+     * descriptor and is responsible for closing it when writing completes.
+     * </p>
+     * @param output The destination.
+     */
+    public void write(ParcelFileDescriptor output) throws IOException {
+        try {
+            throwIfClosed();
+            nativeWrite(mNativeDocument, output.getFd());
+        } finally {
+            IoUtils.closeQuietly(output);
+        }
+    }
+
+    /**
+     * Closes this editor. You should not use this instance
+     * after this method is called.
+     */
+    public void close() {
+        throwIfClosed();
+        doClose();
+    }
+
+    @Override
+    protected void finalize() throws Throwable {
+        try {
+            mCloseGuard.warnIfOpen();
+            if (mInput != null) {
+                doClose();
+            }
+        } finally {
+            super.finalize();
+        }
+    }
+
+    private void doClose() {
+        nativeClose(mNativeDocument);
+        IoUtils.closeQuietly(mInput);
+        mInput = null;
+        mCloseGuard.close();
+    }
+
+    private void throwIfClosed() {
+        if (mInput == null) {
+            throw new IllegalStateException("Already closed");
+        }
+    }
+
+    private void throwIfPageNotInDocument(int pageIndex) {
+        if (pageIndex < 0 || pageIndex >= mPageCount) {
+            throw new IllegalArgumentException("Invalid page index");
+        }
+    }
+
+    private static native long nativeOpen(int fd, long size);
+    private static native void nativeClose(long documentPtr);
+    private static native int nativeGetPageCount(long documentPtr);
+    private static native int nativeRemovePage(long documentPtr, int pageIndex);
+    private static native void nativeWrite(long documentPtr, int fd);
+}
diff --git a/graphics/java/android/graphics/pdf/PdfRenderer.java b/graphics/java/android/graphics/pdf/PdfRenderer.java
index b5d9729..359c294 100644
--- a/graphics/java/android/graphics/pdf/PdfRenderer.java
+++ b/graphics/java/android/graphics/pdf/PdfRenderer.java
@@ -195,6 +195,7 @@
     public Page openPage(int index) {
         throwIfClosed();
         throwIfPageOpened();
+        throwIfPageNotInDocument(index);
         mCurrentPage = new Page(index);
         return mCurrentPage;
     }
@@ -237,6 +238,12 @@
         }
     }
 
+    private void throwIfPageNotInDocument(int pageIndex) {
+        if (pageIndex < 0 || pageIndex >= mPageCount) {
+            throw new IllegalArgumentException("Invalid page index");
+        }
+    }
+
     /**
      * This class represents a PDF document page for rendering.
      */
diff --git a/include/android_runtime/AndroidRuntime.h b/include/android_runtime/AndroidRuntime.h
index 51e47e6..f3cfd97 100644
--- a/include/android_runtime/AndroidRuntime.h
+++ b/include/android_runtime/AndroidRuntime.h
@@ -45,6 +45,7 @@
     };
 
     void setArgv0(const char* argv0);
+    void addOption(const char* optionString, void* extra_info = NULL);
 
     /**
      * Register a set of methods in the specified class.
@@ -63,8 +64,6 @@
      */
     static jclass findClass(JNIEnv* env, const char* className);
 
-    int addVmArguments(int argc, const char* const argv[]);
-
     void start(const char *classname, const Vector<String8>& options);
 
     void exit(int code);
@@ -116,7 +115,6 @@
 
 private:
     static int startReg(JNIEnv* env);
-    void addOption(const char* optionString, void* extra_info = NULL);
     bool parseRuntimeOption(const char* property,
                             char* buffer,
                             const char* runtimeArg,
diff --git a/include/androidfw/ResourceTypes.h b/include/androidfw/ResourceTypes.h
index b56829d..c65efe4 100644
--- a/include/androidfw/ResourceTypes.h
+++ b/include/androidfw/ResourceTypes.h
@@ -954,6 +954,7 @@
         DENSITY_XHIGH = ACONFIGURATION_DENSITY_XHIGH,
         DENSITY_XXHIGH = ACONFIGURATION_DENSITY_XXHIGH,
         DENSITY_XXXHIGH = ACONFIGURATION_DENSITY_XXXHIGH,
+        DENSITY_ANY = ACONFIGURATION_DENSITY_ANY,
         DENSITY_NONE = ACONFIGURATION_DENSITY_NONE
     };
     
@@ -1459,6 +1460,9 @@
     // Loads an unmapped reference table from the package.
     status_t load(const ResTable_lib_header* const header);
 
+    // Adds mappings from the other DynamicRefTable
+    status_t addMappings(const DynamicRefTable& other);
+
     // Creates a mapping from build-time package ID to run-time package ID for
     // the given package.
     status_t addMapping(const String16& packageName, uint8_t packageId);
@@ -1553,7 +1557,7 @@
     };
     const char16_t* valueToString(const Res_value* value, size_t stringBlock,
                                   char16_t tmpBuffer[TMP_BUFFER_SIZE],
-                                  size_t* outLen);
+                                  size_t* outLen) const;
 
     struct bag_entry {
         ssize_t stringBlock;
diff --git a/keystore/java/android/security/IKeyChainService.aidl b/keystore/java/android/security/IKeyChainService.aidl
index 60fd7f7..20c94c5 100644
--- a/keystore/java/android/security/IKeyChainService.aidl
+++ b/keystore/java/android/security/IKeyChainService.aidl
@@ -15,6 +15,8 @@
  */
 package android.security;
 
+import android.content.pm.ParceledListSlice;
+
 /**
  * Caller is required to ensure that {@link KeyStore#unlock
  * KeyStore.unlock} was successful.
@@ -29,9 +31,17 @@
     // APIs used by CertInstaller
     void installCaCertificate(in byte[] caCertificate);
 
+    // APIs used by DevicePolicyManager
+    boolean installKeyPair(in byte[] privateKey, in byte[] userCert, String alias);
+
     // APIs used by Settings
     boolean deleteCaCertificate(String alias);
     boolean reset();
+    ParceledListSlice getUserCaAliases();
+    ParceledListSlice getSystemCaAliases();
+    boolean containsCaAlias(String alias);
+    byte[] getEncodedCaCertificate(String alias, boolean includeDeletedSystem);
+    List<String> getCaCertificateChainAliases(String rootAlias, boolean includeDeletedSystem);
 
     // APIs used by KeyChainActivity
     void setGrant(int uid, String alias, boolean value);
diff --git a/keystore/java/android/security/KeyChain.java b/keystore/java/android/security/KeyChain.java
index 0da2b99..131e689 100644
--- a/keystore/java/android/security/KeyChain.java
+++ b/keystore/java/android/security/KeyChain.java
@@ -397,7 +397,8 @@
         return KeyStore.getInstance().isHardwareBacked(algorithm);
     }
 
-    private static X509Certificate toCertificate(byte[] bytes) {
+    /** @hide */
+    public static X509Certificate toCertificate(byte[] bytes) {
         if (bytes == null) {
             throw new IllegalArgumentException("bytes == null");
         }
diff --git a/keystore/java/android/security/KeyStore.java b/keystore/java/android/security/KeyStore.java
index 6ac49ee..0db8c77 100644
--- a/keystore/java/android/security/KeyStore.java
+++ b/keystore/java/android/security/KeyStore.java
@@ -331,6 +331,36 @@
         }
     }
 
+    public boolean resetUid(int uid) {
+        try {
+            mError = mBinder.reset_uid(uid);
+            return mError == NO_ERROR;
+        } catch (RemoteException e) {
+            Log.w(TAG, "Cannot connect to keystore", e);
+            return false;
+        }
+    }
+
+    public boolean syncUid(int sourceUid, int targetUid) {
+        try {
+            mError = mBinder.sync_uid(sourceUid, targetUid);
+            return mError == NO_ERROR;
+        } catch (RemoteException e) {
+            Log.w(TAG, "Cannot connect to keystore", e);
+            return false;
+        }
+    }
+
+    public boolean passwordUid(String password, int uid) {
+        try {
+            mError = mBinder.password_uid(password, uid);
+            return mError == NO_ERROR;
+        } catch (RemoteException e) {
+            Log.w(TAG, "Cannot connect to keystore", e);
+            return false;
+        }
+    }
+
     public int getLastError() {
         return mError;
     }
diff --git a/keystore/tests/src/android/security/KeyStoreTest.java b/keystore/tests/src/android/security/KeyStoreTest.java
index 7a142cc..c3cba2b 100644
--- a/keystore/tests/src/android/security/KeyStoreTest.java
+++ b/keystore/tests/src/android/security/KeyStoreTest.java
@@ -53,7 +53,8 @@
     private static final byte[] TEST_I18N_VALUE = TEST_I18N_KEY.getBytes(StandardCharsets.UTF_8);
 
     // Test vector data for signatures
-    private static final byte[] TEST_DATA =  new byte[256];
+    private static final int RSA_KEY_SIZE = 1024;
+    private static final byte[] TEST_DATA =  new byte[RSA_KEY_SIZE / 8];
     static {
         for (int i = 0; i < TEST_DATA.length; i++) {
             TEST_DATA[i] = (byte) i;
@@ -349,7 +350,7 @@
     public void testGenerate_NotInitialized_Fail() throws Exception {
         assertFalse("Should fail when keystore is not initialized",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
     }
 
     public void testGenerate_Locked_Fail() throws Exception {
@@ -357,7 +358,7 @@
         mKeyStore.lock();
         assertFalse("Should fail when keystore is locked",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
     }
 
     public void testGenerate_Success() throws Exception {
@@ -365,7 +366,7 @@
 
         assertTrue("Should be able to generate key when unlocked",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
         assertTrue(mKeyStore.contains(TEST_KEYNAME));
         assertFalse(mKeyStore.contains(TEST_KEYNAME, Process.WIFI_UID));
     }
@@ -375,7 +376,7 @@
 
         assertTrue("Should be able to generate key when unlocked",
                 mKeyStore.generate(TEST_KEYNAME, Process.WIFI_UID, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
         assertTrue(mKeyStore.contains(TEST_KEYNAME, Process.WIFI_UID));
         assertFalse(mKeyStore.contains(TEST_KEYNAME));
     }
@@ -384,7 +385,7 @@
         assertTrue(mKeyStore.password(TEST_PASSWD));
 
         assertFalse(mKeyStore.generate(TEST_KEYNAME, Process.BLUETOOTH_UID,
-                    NativeCrypto.EVP_PKEY_RSA, 1024, KeyStore.FLAG_ENCRYPTED, null));
+                    NativeCrypto.EVP_PKEY_RSA, RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
         assertFalse(mKeyStore.contains(TEST_KEYNAME, Process.BLUETOOTH_UID));
         assertFalse(mKeyStore.contains(TEST_KEYNAME, Process.WIFI_UID));
         assertFalse(mKeyStore.contains(TEST_KEYNAME));
@@ -431,7 +432,7 @@
         mKeyStore.password(TEST_PASSWD);
 
         assertTrue(mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                    1024, KeyStore.FLAG_ENCRYPTED, null));
+                    RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
         assertTrue(mKeyStore.contains(TEST_KEYNAME));
         final byte[] signature = mKeyStore.sign(TEST_KEYNAME, TEST_DATA);
 
@@ -442,7 +443,7 @@
         mKeyStore.password(TEST_PASSWD);
 
         assertTrue(mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                    1024, KeyStore.FLAG_ENCRYPTED, null));
+                    RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
         assertTrue(mKeyStore.contains(TEST_KEYNAME));
         final byte[] signature = mKeyStore.sign(TEST_KEYNAME, TEST_DATA);
 
@@ -470,7 +471,7 @@
 
         assertTrue("Should be able to generate key for testcase",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue("Should be able to grant key to other user",
                 mKeyStore.grant(TEST_KEYNAME, 0));
@@ -504,7 +505,7 @@
 
         assertTrue("Should be able to generate key for testcase",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue("Should be able to grant key to other user",
                 mKeyStore.grant(TEST_KEYNAME, 0));
@@ -538,7 +539,7 @@
 
         assertTrue("Should be able to generate key for testcase",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertFalse("Should not be able to revoke not existent grant",
                 mKeyStore.ungrant(TEST_KEYNAME, 0));
@@ -550,7 +551,7 @@
 
         assertTrue("Should be able to generate key for testcase",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue("Should be able to grant key to other user",
                 mKeyStore.grant(TEST_KEYNAME, 0));
@@ -568,7 +569,7 @@
 
         assertTrue("Should be able to generate key for testcase",
                 mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                        1024, KeyStore.FLAG_ENCRYPTED, null));
+                        RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue("Should be able to grant key to other user",
                 mKeyStore.grant(TEST_KEYNAME, 0));
@@ -589,7 +590,7 @@
         assertFalse(mKeyStore.contains(TEST_KEYNAME));
 
         assertTrue(mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                    1024, KeyStore.FLAG_ENCRYPTED, null));
+                    RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue(mKeyStore.contains(TEST_KEYNAME));
         assertFalse(mKeyStore.contains(TEST_KEYNAME, Process.WIFI_UID));
@@ -628,7 +629,7 @@
         assertFalse(mKeyStore.contains(TEST_KEYNAME));
 
         assertTrue(mKeyStore.generate(TEST_KEYNAME, KeyStore.UID_SELF, NativeCrypto.EVP_PKEY_RSA,
-                    1024, KeyStore.FLAG_ENCRYPTED, null));
+                    RSA_KEY_SIZE, KeyStore.FLAG_ENCRYPTED, null));
 
         assertTrue(mKeyStore.contains(TEST_KEYNAME));
         assertFalse(mKeyStore.contains(TEST_KEYNAME, Process.BLUETOOTH_UID));
diff --git a/libs/androidfw/ResourceTypes.cpp b/libs/androidfw/ResourceTypes.cpp
index 2a4dec0..690b1d6 100644
--- a/libs/androidfw/ResourceTypes.cpp
+++ b/libs/androidfw/ResourceTypes.cpp
@@ -2206,13 +2206,30 @@
 
         if (screenType || o.screenType) {
             if (density != o.density) {
-                // density is tough.  Any density is potentially useful
+                // Use the system default density (DENSITY_MEDIUM, 160dpi) if none specified.
+                const int thisDensity = density ? density : int(ResTable_config::DENSITY_MEDIUM);
+                const int otherDensity = o.density ? o.density : int(ResTable_config::DENSITY_MEDIUM);
+
+                // We always prefer DENSITY_ANY over scaling a density bucket.
+                if (thisDensity == ResTable_config::DENSITY_ANY) {
+                    return true;
+                } else if (otherDensity == ResTable_config::DENSITY_ANY) {
+                    return false;
+                }
+
+                int requestedDensity = requested->density;
+                if (requested->density == 0 ||
+                        requested->density == ResTable_config::DENSITY_ANY) {
+                    requestedDensity = ResTable_config::DENSITY_MEDIUM;
+                }
+
+                // DENSITY_ANY is now dealt with. We should look to
+                // pick a density bucket and potentially scale it.
+                // Any density is potentially useful
                 // because the system will scale it.  Scaling down
                 // is generally better than scaling up.
-                // Default density counts as 160dpi (the system default)
-                // TODO - remove 160 constants
-                int h = (density?density:160);
-                int l = (o.density?o.density:160);
+                int h = thisDensity;
+                int l = otherDensity;
                 bool bImBigger = true;
                 if (l > h) {
                     int t = h;
@@ -2221,17 +2238,16 @@
                     bImBigger = false;
                 }
 
-                int reqValue = (requested->density?requested->density:160);
-                if (reqValue >= h) {
+                if (requestedDensity >= h) {
                     // requested value higher than both l and h, give h
                     return bImBigger;
                 }
-                if (l >= reqValue) {
+                if (l >= requestedDensity) {
                     // requested value lower than both l and h, give l
                     return !bImBigger;
                 }
                 // saying that scaling down is 2x better than up
-                if (((2 * l) - reqValue) * h > reqValue * reqValue) {
+                if (((2 * l) - requestedDensity) * h > requestedDensity * requestedDensity) {
                     return !bImBigger;
                 } else {
                     return bImBigger;
@@ -2702,6 +2718,9 @@
             case ResTable_config::DENSITY_NONE:
                 res.append("nodpi");
                 break;
+            case ResTable_config::DENSITY_ANY:
+                res.append("anydpi");
+                break;
             default:
                 res.appendFormat("%ddpi", dtohs(density));
                 break;
@@ -2920,7 +2939,7 @@
             for (size_t i = 0; i < bags->size(); i++) {
                 TABLE_NOISY(printf("type=%d\n", i));
                 const TypeList& typeList = types[i];
-                if (typeList.isEmpty()) {
+                if (!typeList.isEmpty()) {
                     bag_set** typeBags = bags->get(i);
                     TABLE_NOISY(printf("typeBags=%p\n", typeBags));
                     if (typeBags) {
@@ -3346,6 +3365,7 @@
             TypeList& typeList = pg->types.editItemAt(j);
             typeList.appendVector(srcPg->types[j]);
         }
+        pg->dynamicRefTable.addMappings(srcPg->dynamicRefTable);
         pg->largestTypeId = max(pg->largestTypeId, srcPg->largestTypeId);
         mPackageGroups.add(pg);
     }
@@ -3708,7 +3728,7 @@
 
 const char16_t* ResTable::valueToString(
     const Res_value* value, size_t stringBlock,
-    char16_t /*tmpBuffer*/ [TMP_BUFFER_SIZE], size_t* outLen)
+    char16_t /*tmpBuffer*/ [TMP_BUFFER_SIZE], size_t* outLen) const
 {
     if (!value) {
         return NULL;
@@ -5604,7 +5624,6 @@
             return (mError=NO_MEMORY);
         }
 
-        //printf("Adding new package id %d at index %d\n", id, idx);
         err = mPackageGroups.add(group);
         if (err < NO_ERROR) {
             return (mError=err);
@@ -5844,6 +5863,37 @@
     return NO_ERROR;
 }
 
+status_t DynamicRefTable::addMappings(const DynamicRefTable& other) {
+    if (mAssignedPackageId != other.mAssignedPackageId) {
+        return UNKNOWN_ERROR;
+    }
+
+    const size_t entryCount = other.mEntries.size();
+    for (size_t i = 0; i < entryCount; i++) {
+        ssize_t index = mEntries.indexOfKey(other.mEntries.keyAt(i));
+        if (index < 0) {
+            mEntries.add(other.mEntries.keyAt(i), other.mEntries[i]);
+        } else {
+            if (other.mEntries[i] != mEntries[index]) {
+                return UNKNOWN_ERROR;
+            }
+        }
+    }
+
+    // Merge the lookup table. No entry can conflict
+    // (value of 0 means not set).
+    for (size_t i = 0; i < 256; i++) {
+        if (mLookupTable[i] != other.mLookupTable[i]) {
+            if (mLookupTable[i] == 0) {
+                mLookupTable[i] = other.mLookupTable[i];
+            } else if (other.mLookupTable[i] != 0) {
+                return UNKNOWN_ERROR;
+            }
+        }
+    }
+    return NO_ERROR;
+}
+
 status_t DynamicRefTable::addMapping(const String16& packageName, uint8_t packageId)
 {
     ssize_t index = mEntries.indexOfKey(packageName);
@@ -6216,21 +6266,36 @@
     printf("Package Groups (%d)\n", (int)pgCount);
     for (size_t pgIndex=0; pgIndex<pgCount; pgIndex++) {
         const PackageGroup* pg = mPackageGroups[pgIndex];
-        printf("Package Group %d id=%d packageCount=%d name=%s\n",
+        printf("Package Group %d id=0x%02x packageCount=%d name=%s\n",
                 (int)pgIndex, pg->id, (int)pg->packages.size(),
                 String8(pg->name).string());
 
+        const KeyedVector<String16, uint8_t>& refEntries = pg->dynamicRefTable.entries();
+        const size_t refEntryCount = refEntries.size();
+        if (refEntryCount > 0) {
+            printf("  DynamicRefTable entryCount=%d:\n", (int) refEntryCount);
+            for (size_t refIndex = 0; refIndex < refEntryCount; refIndex++) {
+                printf("    0x%02x -> %s\n",
+                        refEntries.valueAt(refIndex),
+                        String8(refEntries.keyAt(refIndex)).string());
+            }
+            printf("\n");
+        }
+
+        int packageId = pg->id;
         size_t pkgCount = pg->packages.size();
         for (size_t pkgIndex=0; pkgIndex<pkgCount; pkgIndex++) {
             const Package* pkg = pg->packages[pkgIndex];
-            printf("  Package %d id=%d name=%s\n", (int)pkgIndex,
+            // Use a package's real ID, since the ID may have been assigned
+            // if this package is a shared library.
+            packageId = pkg->package->id;
+            printf("  Package %d id=0x%02x name=%s\n", (int)pkgIndex,
                     pkg->package->id, String8(String16(pkg->package->name)).string());
         }
 
         for (size_t typeIndex=0; typeIndex < pg->types.size(); typeIndex++) {
             const TypeList& typeList = pg->types[typeIndex];
             if (typeList.isEmpty()) {
-                //printf("    type %d NULL\n", (int)typeIndex);
                 continue;
             }
             const Type* typeConfigs = typeList[0];
@@ -6239,13 +6304,15 @@
                    (int)typeIndex, (int)NTC, (int)typeConfigs->entryCount);
             if (typeConfigs->typeSpecFlags != NULL) {
                 for (size_t entryIndex=0; entryIndex<typeConfigs->entryCount; entryIndex++) {
-                    uint32_t resID = (0xff000000 & ((pg->id)<<24))
+                    uint32_t resID = (0xff000000 & ((packageId)<<24))
                                 | (0x00ff0000 & ((typeIndex+1)<<16))
                                 | (0x0000ffff & (entryIndex));
                     // Since we are creating resID without actually
                     // iterating over them, we have no idea which is a
                     // dynamic reference. We must check.
-                    pg->dynamicRefTable.lookupResourceId(&resID);
+                    if (packageId == 0) {
+                        pg->dynamicRefTable.lookupResourceId(&resID);
+                    }
 
                     resource_name resName;
                     if (this->getResourceName(resID, true, &resName)) {
@@ -6303,10 +6370,12 @@
                         continue;
                     }
 
-                    uint32_t resID = (0xff000000 & ((pg->id)<<24))
+                    uint32_t resID = (0xff000000 & ((packageId)<<24))
                                 | (0x00ff0000 & ((typeIndex+1)<<16))
                                 | (0x0000ffff & (entryIndex));
-                    pg->dynamicRefTable.lookupResourceId(&resID);
+                    if (packageId == 0) {
+                        pg->dynamicRefTable.lookupResourceId(&resID);
+                    }
                     resource_name resName;
                     if (this->getResourceName(resID, true, &resName)) {
                         String8 type8;
@@ -6387,9 +6456,11 @@
                             const ResTable_map* mapPtr = (ResTable_map*)(baseMapPtr+mapOffset);
                             const uint32_t parent = dtohl(bagPtr->parent.ident);
                             uint32_t resolvedParent = parent;
-                            status_t err = pg->dynamicRefTable.lookupResourceId(&resolvedParent);
-                            if (err != NO_ERROR) {
-                                resolvedParent = 0;
+                            if (Res_GETPACKAGE(resolvedParent) + 1 == 0) {
+                                status_t err = pg->dynamicRefTable.lookupResourceId(&resolvedParent);
+                                if (err != NO_ERROR) {
+                                    resolvedParent = 0;
+                                }
                             }
                             printf("          Parent=0x%08x(Resolved=0x%08x), Count=%d\n",
                                     parent, resolvedParent, N);
diff --git a/libs/androidfw/tests/Android.mk b/libs/androidfw/tests/Android.mk
index 4ff6eec..5808d20 100644
--- a/libs/androidfw/tests/Android.mk
+++ b/libs/androidfw/tests/Android.mk
@@ -21,10 +21,12 @@
 LOCAL_PATH:= $(call my-dir)
 testFiles := \
     ByteBucketArray_test.cpp \
+    Config_test.cpp \
+    ConfigLocale_test.cpp \
     Idmap_test.cpp \
-    ResourceTypes_test.cpp \
     ResTable_test.cpp \
     Split_test.cpp \
+    Theme_test.cpp \
     TypeWrappers_test.cpp \
     ZipUtils_test.cpp
 
diff --git a/libs/androidfw/tests/BackupData_test.cpp b/libs/androidfw/tests/BackupData_test.cpp
index 17f91ca..92af7fe 100644
--- a/libs/androidfw/tests/BackupData_test.cpp
+++ b/libs/androidfw/tests/BackupData_test.cpp
@@ -45,7 +45,7 @@
 class BackupDataTest : public testing::Test {
 protected:
     char* m_external_storage;
-    char* m_filename;
+    String8 mFilename;
     String8 mKey1;
     String8 mKey2;
     String8 mKey3;
@@ -53,15 +53,13 @@
 
     virtual void SetUp() {
         m_external_storage = getenv("EXTERNAL_STORAGE");
+        mFilename.append(m_external_storage);
+        mFilename.append(TEST_FILENAME);
 
-        const int totalLen = strlen(m_external_storage) + strlen(TEST_FILENAME) + 1;
-        m_filename = new char[totalLen];
-        snprintf(m_filename, totalLen, "%s%s", m_external_storage, TEST_FILENAME);
-
-        ::unlink(m_filename);
-        int fd = ::open(m_filename, O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR);
+        ::unlink(mFilename.string());
+        int fd = ::open(mFilename.string(), O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR);
         if (fd < 0) {
-            FAIL() << "Couldn't create " << m_filename << " for writing";
+            FAIL() << "Couldn't create " << mFilename.string() << " for writing";
         }
         mKey1 = String8(KEY1);
         mKey2 = String8(KEY2);
@@ -74,7 +72,7 @@
 };
 
 TEST_F(BackupDataTest, WriteAndReadSingle) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
 
   EXPECT_EQ(NO_ERROR, writer->WriteEntityHeader(mKey1, sizeof(DATA1)))
@@ -83,7 +81,7 @@
           << "WriteEntityData returned an error";
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
   EXPECT_EQ(NO_ERROR, reader->Status())
           << "Reader ctor failed";
@@ -116,7 +114,7 @@
 }
 
 TEST_F(BackupDataTest, WriteAndReadMultiple) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, sizeof(DATA1));
   writer->WriteEntityData(DATA1, sizeof(DATA1));
@@ -124,7 +122,7 @@
   writer->WriteEntityData(DATA2, sizeof(DATA2));
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -164,7 +162,7 @@
 }
 
 TEST_F(BackupDataTest, SkipEntity) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, sizeof(DATA1));
   writer->WriteEntityData(DATA1, sizeof(DATA1));
@@ -174,7 +172,7 @@
   writer->WriteEntityData(DATA3, sizeof(DATA3));
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -219,14 +217,14 @@
 }
 
 TEST_F(BackupDataTest, DeleteEntity) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, sizeof(DATA1));
   writer->WriteEntityData(DATA1, sizeof(DATA1));
   writer->WriteEntityHeader(mKey2, -1);
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -258,7 +256,7 @@
 }
 
 TEST_F(BackupDataTest, EneityAfterDelete) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, sizeof(DATA1));
   writer->WriteEntityData(DATA1, sizeof(DATA1));
@@ -267,7 +265,7 @@
   writer->WriteEntityData(DATA3, sizeof(DATA3));
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -319,7 +317,7 @@
 }
 
 TEST_F(BackupDataTest, OnlyDeleteEntities) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, -1);
   writer->WriteEntityHeader(mKey2, -1);
@@ -327,7 +325,7 @@
   writer->WriteEntityHeader(mKey4, -1);
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -387,13 +385,13 @@
 }
 
 TEST_F(BackupDataTest, ReadDeletedEntityData) {
-  int fd = ::open(m_filename, O_WRONLY);
+  int fd = ::open(mFilename.string(), O_WRONLY);
   BackupDataWriter* writer = new BackupDataWriter(fd);
   writer->WriteEntityHeader(mKey1, -1);
   writer->WriteEntityHeader(mKey2, -1);
 
   ::close(fd);
-  fd = ::open(m_filename, O_RDONLY);
+  fd = ::open(mFilename.string(), O_RDONLY);
   BackupDataReader* reader = new BackupDataReader(fd);
 
   bool done;
@@ -431,6 +429,7 @@
   EXPECT_EQ(-1, (int) dataSize)
           << "not recognizing deletion on second entity";
 
+  delete[] dataBytes;
   delete writer;
   delete reader;
 }
diff --git a/libs/androidfw/tests/ConfigLocale_test.cpp b/libs/androidfw/tests/ConfigLocale_test.cpp
new file mode 100644
index 0000000..4999594
--- /dev/null
+++ b/libs/androidfw/tests/ConfigLocale_test.cpp
@@ -0,0 +1,209 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#include <androidfw/ResourceTypes.h>
+#include <utils/Log.h>
+#include <utils/String8.h>
+
+#include <gtest/gtest.h>
+namespace android {
+
+TEST(ConfigLocaleTest, packAndUnpack2LetterLanguage) {
+     ResTable_config config;
+     config.packLanguage("en");
+
+     EXPECT_EQ('e', config.language[0]);
+     EXPECT_EQ('n', config.language[1]);
+
+     char out[4] = { 1, 1, 1, 1};
+     config.unpackLanguage(out);
+     EXPECT_EQ('e', out[0]);
+     EXPECT_EQ('n', out[1]);
+     EXPECT_EQ(0, out[2]);
+     EXPECT_EQ(0, out[3]);
+
+     memset(out, 1, sizeof(out));
+     config.locale = 0;
+     config.unpackLanguage(out);
+     EXPECT_EQ(0, out[0]);
+     EXPECT_EQ(0, out[1]);
+     EXPECT_EQ(0, out[2]);
+     EXPECT_EQ(0, out[3]);
+}
+
+TEST(ConfigLocaleTest, packAndUnpack2LetterRegion) {
+     ResTable_config config;
+     config.packRegion("US");
+
+     EXPECT_EQ('U', config.country[0]);
+     EXPECT_EQ('S', config.country[1]);
+
+     char out[4] = { 1, 1, 1, 1};
+     config.unpackRegion(out);
+     EXPECT_EQ('U', out[0]);
+     EXPECT_EQ('S', out[1]);
+     EXPECT_EQ(0, out[2]);
+     EXPECT_EQ(0, out[3]);
+}
+
+TEST(ConfigLocaleTest, packAndUnpack3LetterLanguage) {
+     ResTable_config config;
+     config.packLanguage("eng");
+
+     // 1-00110-01 101-00100
+     EXPECT_EQ('\x99', config.language[0]);
+     EXPECT_EQ('\xA4', config.language[1]);
+
+     char out[4] = { 1, 1, 1, 1};
+     config.unpackLanguage(out);
+     EXPECT_EQ('e', out[0]);
+     EXPECT_EQ('n', out[1]);
+     EXPECT_EQ('g', out[2]);
+     EXPECT_EQ(0, out[3]);
+}
+
+TEST(ConfigLocaleTest, packAndUnpack3LetterLanguageAtOffset16) {
+     ResTable_config config;
+     config.packLanguage("tgp");
+
+     // We had a bug where we would accidentally mask
+     // the 5th bit of both bytes
+     //
+     // packed[0] = 1011 1100
+     // packed[1] = 1101 0011
+     //
+     // which is equivalent to:
+     // 1  [0]   [1]   [2]
+     // 1-01111-00110-10011
+     EXPECT_EQ(char(0xbc), config.language[0]);
+     EXPECT_EQ(char(0xd3), config.language[1]);
+
+     char out[4] = { 1, 1, 1, 1};
+     config.unpackLanguage(out);
+     EXPECT_EQ('t', out[0]);
+     EXPECT_EQ('g', out[1]);
+     EXPECT_EQ('p', out[2]);
+     EXPECT_EQ(0, out[3]);
+}
+
+TEST(ConfigLocaleTest, packAndUnpack3LetterRegion) {
+     ResTable_config config;
+     config.packRegion("419");
+
+     char out[4] = { 1, 1, 1, 1};
+     config.unpackRegion(out);
+
+     EXPECT_EQ('4', out[0]);
+     EXPECT_EQ('1', out[1]);
+     EXPECT_EQ('9', out[2]);
+}
+
+/* static */ void fillIn(const char* lang, const char* country,
+        const char* script, const char* variant, ResTable_config* out) {
+     memset(out, 0, sizeof(ResTable_config));
+     if (lang != NULL) {
+         out->packLanguage(lang);
+     }
+
+     if (country != NULL) {
+         out->packRegion(country);
+     }
+
+     if (script != NULL) {
+         memcpy(out->localeScript, script, 4);
+     }
+
+     if (variant != NULL) {
+         memcpy(out->localeVariant, variant, strlen(variant));
+     }
+}
+
+TEST(ConfigLocaleTest, IsMoreSpecificThan) {
+    ResTable_config l;
+    ResTable_config r;
+
+    fillIn("en", NULL, NULL, NULL, &l);
+    fillIn(NULL, NULL, NULL, NULL, &r);
+
+    EXPECT_TRUE(l.isMoreSpecificThan(r));
+    EXPECT_FALSE(r.isMoreSpecificThan(l));
+
+    fillIn("eng", NULL, NULL, NULL, &l);
+    EXPECT_TRUE(l.isMoreSpecificThan(r));
+    EXPECT_FALSE(r.isMoreSpecificThan(l));
+
+    fillIn("eng", "419", NULL, NULL, &r);
+    EXPECT_FALSE(l.isMoreSpecificThan(r));
+    EXPECT_TRUE(r.isMoreSpecificThan(l));
+
+    fillIn("en", NULL, NULL, NULL, &l);
+    fillIn("en", "US", NULL, NULL, &r);
+    EXPECT_FALSE(l.isMoreSpecificThan(r));
+    EXPECT_TRUE(r.isMoreSpecificThan(l));
+
+    fillIn("en", "US", NULL, NULL, &l);
+    fillIn("en", "US", "Latn", NULL, &r);
+    EXPECT_FALSE(l.isMoreSpecificThan(r));
+    EXPECT_TRUE(r.isMoreSpecificThan(l));
+
+    fillIn("en", "US", NULL, NULL, &l);
+    fillIn("en", "US", NULL, "POSIX", &r);
+    EXPECT_FALSE(l.isMoreSpecificThan(r));
+    EXPECT_TRUE(r.isMoreSpecificThan(l));
+
+    fillIn("en", "US", "Latn", NULL, &l);
+    fillIn("en", "US", NULL, "POSIX", &r);
+    EXPECT_FALSE(l.isMoreSpecificThan(r));
+    EXPECT_TRUE(r.isMoreSpecificThan(l));
+}
+
+TEST(ConfigLocaleTest, setLocale) {
+    ResTable_config test;
+    test.setBcp47Locale("en-US");
+    EXPECT_EQ('e', test.language[0]);
+    EXPECT_EQ('n', test.language[1]);
+    EXPECT_EQ('U', test.country[0]);
+    EXPECT_EQ('S', test.country[1]);
+    EXPECT_EQ(0, test.localeScript[0]);
+    EXPECT_EQ(0, test.localeVariant[0]);
+
+    test.setBcp47Locale("eng-419");
+    char out[4] = { 1, 1, 1, 1};
+    test.unpackLanguage(out);
+    EXPECT_EQ('e', out[0]);
+    EXPECT_EQ('n', out[1]);
+    EXPECT_EQ('g', out[2]);
+    EXPECT_EQ(0, out[3]);
+    memset(out, 1, 4);
+    test.unpackRegion(out);
+    EXPECT_EQ('4', out[0]);
+    EXPECT_EQ('1', out[1]);
+    EXPECT_EQ('9', out[2]);
+
+
+    test.setBcp47Locale("en-Latn-419");
+    memset(out, 1, 4);
+    EXPECT_EQ('e', test.language[0]);
+    EXPECT_EQ('n', test.language[1]);
+
+    EXPECT_EQ(0, memcmp("Latn", test.localeScript, 4));
+    test.unpackRegion(out);
+    EXPECT_EQ('4', out[0]);
+    EXPECT_EQ('1', out[1]);
+    EXPECT_EQ('9', out[2]);
+}
+
+}  // namespace android.
diff --git a/libs/androidfw/tests/Config_test.cpp b/libs/androidfw/tests/Config_test.cpp
new file mode 100644
index 0000000..ef30df4
--- /dev/null
+++ b/libs/androidfw/tests/Config_test.cpp
@@ -0,0 +1,103 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#include <androidfw/ResourceTypes.h>
+#include <utils/Log.h>
+#include <utils/String8.h>
+#include <utils/Vector.h>
+
+#include "TestHelpers.h"
+#include <gtest/gtest.h>
+
+namespace android {
+
+static ResTable_config selectBest(const ResTable_config& target,
+        const Vector<ResTable_config>& configs) {
+    ResTable_config bestConfig;
+    memset(&bestConfig, 0, sizeof(bestConfig));
+    const size_t configCount = configs.size();
+    for (size_t i = 0; i < configCount; i++) {
+        const ResTable_config& thisConfig = configs[i];
+        if (!thisConfig.match(target)) {
+            continue;
+        }
+
+        if (thisConfig.isBetterThan(bestConfig, &target)) {
+            bestConfig = thisConfig;
+        }
+    }
+    return bestConfig;
+}
+
+static ResTable_config buildDensityConfig(int density) {
+    ResTable_config config;
+    memset(&config, 0, sizeof(config));
+    config.density = uint16_t(density);
+    config.sdkVersion = 4;
+    return config;
+}
+
+TEST(ConfigTest, shouldSelectBestDensity) {
+    ResTable_config deviceConfig;
+    memset(&deviceConfig, 0, sizeof(deviceConfig));
+    deviceConfig.density = ResTable_config::DENSITY_XHIGH;
+    deviceConfig.sdkVersion = 21;
+
+    Vector<ResTable_config> configs;
+
+    ResTable_config expectedBest = buildDensityConfig(ResTable_config::DENSITY_HIGH);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    expectedBest = buildDensityConfig(ResTable_config::DENSITY_XXHIGH);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    expectedBest = buildDensityConfig(int(ResTable_config::DENSITY_XXHIGH) - 20);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    configs.add(buildDensityConfig(int(ResTable_config::DENSITY_HIGH) + 20));
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    expectedBest = buildDensityConfig(ResTable_config::DENSITY_XHIGH);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    expectedBest = buildDensityConfig(ResTable_config::DENSITY_ANY);
+    expectedBest.sdkVersion = 21;
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+}
+
+TEST(ConfigTest, shouldSelectBestDensityWhenNoneSpecified) {
+    ResTable_config deviceConfig;
+    memset(&deviceConfig, 0, sizeof(deviceConfig));
+    deviceConfig.sdkVersion = 21;
+
+    Vector<ResTable_config> configs;
+    configs.add(buildDensityConfig(ResTable_config::DENSITY_HIGH));
+
+    ResTable_config expectedBest = buildDensityConfig(ResTable_config::DENSITY_MEDIUM);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+
+    expectedBest = buildDensityConfig(ResTable_config::DENSITY_ANY);
+    configs.add(expectedBest);
+    ASSERT_EQ(expectedBest, selectBest(deviceConfig, configs));
+}
+
+}  // namespace android.
diff --git a/libs/androidfw/tests/ObbFile_test.cpp b/libs/androidfw/tests/ObbFile_test.cpp
index 7a4dd13..1151121 100644
--- a/libs/androidfw/tests/ObbFile_test.cpp
+++ b/libs/androidfw/tests/ObbFile_test.cpp
@@ -34,20 +34,18 @@
 class ObbFileTest : public testing::Test {
 protected:
     sp<ObbFile> mObbFile;
-    char* mExternalStorage;
-    char* mFileName;
+    String8 mFileName;
 
     virtual void SetUp() {
         mObbFile = new ObbFile();
-        mExternalStorage = getenv("EXTERNAL_STORAGE");
+        char* externalStorage = getenv("EXTERNAL_STORAGE");
 
-        const int totalLen = strlen(mExternalStorage) + strlen(TEST_FILENAME) + 1;
-        mFileName = new char[totalLen];
-        snprintf(mFileName, totalLen, "%s%s", mExternalStorage, TEST_FILENAME);
+        mFileName.append(externalStorage);
+        mFileName.append(TEST_FILENAME);
 
-        int fd = ::open(mFileName, O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR);
+        int fd = ::open(mFileName.string(), O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR);
         if (fd < 0) {
-            FAIL() << "Couldn't create " << mFileName << " for tests";
+            FAIL() << "Couldn't create " << mFileName.string() << " for tests";
         }
     }
 
@@ -71,12 +69,12 @@
     EXPECT_TRUE(mObbFile->setSalt(salt, SALT_SIZE))
             << "Salt should be successfully set";
 
-    EXPECT_TRUE(mObbFile->writeTo(mFileName))
+    EXPECT_TRUE(mObbFile->writeTo(mFileName.string()))
             << "couldn't write to fake .obb file";
 
     mObbFile = new ObbFile();
 
-    EXPECT_TRUE(mObbFile->readFrom(mFileName))
+    EXPECT_TRUE(mObbFile->readFrom(mFileName.string()))
             << "couldn't read from fake .obb file";
 
     EXPECT_EQ(versionNum, mObbFile->getVersion())
diff --git a/libs/androidfw/tests/ResourceTypes_test.cpp b/libs/androidfw/tests/ResourceTypes_test.cpp
deleted file mode 100644
index f00a2d9..0000000
--- a/libs/androidfw/tests/ResourceTypes_test.cpp
+++ /dev/null
@@ -1,209 +0,0 @@
-/*
- * Copyright (C) 2014 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.
- */
-
-#include <androidfw/ResourceTypes.h>
-#include <utils/Log.h>
-#include <utils/String8.h>
-
-#include <gtest/gtest.h>
-namespace android {
-
-TEST(ResourceTypesTest, ResourceConfig_packAndUnpack2LetterLanguage) {
-     ResTable_config config;
-     config.packLanguage("en");
-
-     EXPECT_EQ('e', config.language[0]);
-     EXPECT_EQ('n', config.language[1]);
-
-     char out[4] = { 1, 1, 1, 1};
-     config.unpackLanguage(out);
-     EXPECT_EQ('e', out[0]);
-     EXPECT_EQ('n', out[1]);
-     EXPECT_EQ(0, out[2]);
-     EXPECT_EQ(0, out[3]);
-
-     memset(out, 1, sizeof(out));
-     config.locale = 0;
-     config.unpackLanguage(out);
-     EXPECT_EQ(0, out[0]);
-     EXPECT_EQ(0, out[1]);
-     EXPECT_EQ(0, out[2]);
-     EXPECT_EQ(0, out[3]);
-}
-
-TEST(ResourceTypesTest, ResourceConfig_packAndUnpack2LetterRegion) {
-     ResTable_config config;
-     config.packRegion("US");
-
-     EXPECT_EQ('U', config.country[0]);
-     EXPECT_EQ('S', config.country[1]);
-
-     char out[4] = { 1, 1, 1, 1};
-     config.unpackRegion(out);
-     EXPECT_EQ('U', out[0]);
-     EXPECT_EQ('S', out[1]);
-     EXPECT_EQ(0, out[2]);
-     EXPECT_EQ(0, out[3]);
-}
-
-TEST(ResourceTypesTest, ResourceConfig_packAndUnpack3LetterLanguage) {
-     ResTable_config config;
-     config.packLanguage("eng");
-
-     // 1-00110-01 101-00100
-     EXPECT_EQ('\x99', config.language[0]);
-     EXPECT_EQ('\xA4', config.language[1]);
-
-     char out[4] = { 1, 1, 1, 1};
-     config.unpackLanguage(out);
-     EXPECT_EQ('e', out[0]);
-     EXPECT_EQ('n', out[1]);
-     EXPECT_EQ('g', out[2]);
-     EXPECT_EQ(0, out[3]);
-}
-
-TEST(ResourceTypesTest, ResourceConfig_packAndUnpack3LetterLanguageAtOffset16) {
-     ResTable_config config;
-     config.packLanguage("tgp");
-
-     // We had a bug where we would accidentally mask
-     // the 5th bit of both bytes
-     //
-     // packed[0] = 1011 1100
-     // packed[1] = 1101 0011
-     //
-     // which is equivalent to:
-     // 1  [0]   [1]   [2]
-     // 1-01111-00110-10011
-     EXPECT_EQ(0xbc, config.language[0]);
-     EXPECT_EQ(0xd3, config.language[1]);
-
-     char out[4] = { 1, 1, 1, 1};
-     config.unpackLanguage(out);
-     EXPECT_EQ('t', out[0]);
-     EXPECT_EQ('g', out[1]);
-     EXPECT_EQ('p', out[2]);
-     EXPECT_EQ(0, out[3]);
-}
-
-TEST(ResourceTypesTest, ResourceConfig_packAndUnpack3LetterRegion) {
-     ResTable_config config;
-     config.packRegion("419");
-
-     char out[4] = { 1, 1, 1, 1};
-     config.unpackRegion(out);
-
-     EXPECT_EQ('4', out[0]);
-     EXPECT_EQ('1', out[1]);
-     EXPECT_EQ('9', out[2]);
-}
-
-/* static */ void fillIn(const char* lang, const char* country,
-        const char* script, const char* variant, ResTable_config* out) {
-     memset(out, 0, sizeof(ResTable_config));
-     if (lang != NULL) {
-         out->packLanguage(lang);
-     }
-
-     if (country != NULL) {
-         out->packRegion(country);
-     }
-
-     if (script != NULL) {
-         memcpy(out->localeScript, script, 4);
-     }
-
-     if (variant != NULL) {
-         memcpy(out->localeVariant, variant, strlen(variant));
-     }
-}
-
-TEST(ResourceTypesTest, IsMoreSpecificThan) {
-    ResTable_config l;
-    ResTable_config r;
-
-    fillIn("en", NULL, NULL, NULL, &l);
-    fillIn(NULL, NULL, NULL, NULL, &r);
-
-    EXPECT_TRUE(l.isMoreSpecificThan(r));
-    EXPECT_FALSE(r.isMoreSpecificThan(l));
-
-    fillIn("eng", NULL, NULL, NULL, &l);
-    EXPECT_TRUE(l.isMoreSpecificThan(r));
-    EXPECT_FALSE(r.isMoreSpecificThan(l));
-
-    fillIn("eng", "419", NULL, NULL, &r);
-    EXPECT_FALSE(l.isMoreSpecificThan(r));
-    EXPECT_TRUE(r.isMoreSpecificThan(l));
-
-    fillIn("en", NULL, NULL, NULL, &l);
-    fillIn("en", "US", NULL, NULL, &r);
-    EXPECT_FALSE(l.isMoreSpecificThan(r));
-    EXPECT_TRUE(r.isMoreSpecificThan(l));
-
-    fillIn("en", "US", NULL, NULL, &l);
-    fillIn("en", "US", "Latn", NULL, &r);
-    EXPECT_FALSE(l.isMoreSpecificThan(r));
-    EXPECT_TRUE(r.isMoreSpecificThan(l));
-
-    fillIn("en", "US", NULL, NULL, &l);
-    fillIn("en", "US", NULL, "POSIX", &r);
-    EXPECT_FALSE(l.isMoreSpecificThan(r));
-    EXPECT_TRUE(r.isMoreSpecificThan(l));
-
-    fillIn("en", "US", "Latn", NULL, &l);
-    fillIn("en", "US", NULL, "POSIX", &r);
-    EXPECT_FALSE(l.isMoreSpecificThan(r));
-    EXPECT_TRUE(r.isMoreSpecificThan(l));
-}
-
-TEST(ResourceTypesTest, setLocale) {
-    ResTable_config test;
-    test.setBcp47Locale("en-US");
-    EXPECT_EQ('e', test.language[0]);
-    EXPECT_EQ('n', test.language[1]);
-    EXPECT_EQ('U', test.country[0]);
-    EXPECT_EQ('S', test.country[1]);
-    EXPECT_EQ(0, test.localeScript[0]);
-    EXPECT_EQ(0, test.localeVariant[0]);
-
-    test.setBcp47Locale("eng-419");
-    char out[4] = { 1, 1, 1, 1};
-    test.unpackLanguage(out);
-    EXPECT_EQ('e', out[0]);
-    EXPECT_EQ('n', out[1]);
-    EXPECT_EQ('g', out[2]);
-    EXPECT_EQ(0, out[3]);
-    memset(out, 1, 4);
-    test.unpackRegion(out);
-    EXPECT_EQ('4', out[0]);
-    EXPECT_EQ('1', out[1]);
-    EXPECT_EQ('9', out[2]);
-
-
-    test.setBcp47Locale("en-Latn-419");
-    memset(out, 1, 4);
-    EXPECT_EQ('e', test.language[0]);
-    EXPECT_EQ('n', test.language[1]);
-
-    EXPECT_EQ(0, memcmp("Latn", test.localeScript, 4));
-    test.unpackRegion(out);
-    EXPECT_EQ('4', out[0]);
-    EXPECT_EQ('1', out[1]);
-    EXPECT_EQ('9', out[2]);
-}
-
-}  // namespace android.
diff --git a/libs/androidfw/tests/TestHelpers.h b/libs/androidfw/tests/TestHelpers.h
index 75a233a..fe2e5ce 100644
--- a/libs/androidfw/tests/TestHelpers.h
+++ b/libs/androidfw/tests/TestHelpers.h
@@ -3,6 +3,7 @@
 
 #include <ostream>
 
+#include <androidfw/ResourceTypes.h>
 #include <utils/String8.h>
 #include <utils/String16.h>
 
@@ -14,4 +15,16 @@
     return out << android::String8(str).string();
 }
 
+namespace android {
+
+static inline bool operator==(const android::ResTable_config& a, const android::ResTable_config& b) {
+    return memcmp(&a, &b, sizeof(a)) == 0;
+}
+
+static inline ::std::ostream& operator<<(::std::ostream& out, const android::ResTable_config& c) {
+    return out << c.toString().string();
+}
+
+} // namespace android
+
 #endif // __TEST_HELPERS_H
diff --git a/libs/androidfw/tests/Theme_test.cpp b/libs/androidfw/tests/Theme_test.cpp
new file mode 100644
index 0000000..4d07130
--- /dev/null
+++ b/libs/androidfw/tests/Theme_test.cpp
@@ -0,0 +1,68 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#include <androidfw/ResourceTypes.h>
+
+#include <utils/String8.h>
+#include <utils/String16.h>
+#include "TestHelpers.h"
+#include "data/system/R.h"
+#include "data/app/R.h"
+
+#include <gtest/gtest.h>
+
+using namespace android;
+
+namespace {
+
+#include "data/system/system_arsc.h"
+#include "data/app/app_arsc.h"
+
+enum { MAY_NOT_BE_BAG = false };
+
+/**
+ * TODO(adamlesinski): Enable when fixed.
+ */
+TEST(ThemeTest, DISABLED_shouldCopyThemeFromDifferentResTable) {
+    ResTable table;
+    ASSERT_EQ(NO_ERROR, table.add(system_arsc, system_arsc_len));
+    ASSERT_EQ(NO_ERROR, table.add(app_arsc, app_arsc_len));
+
+    ResTable::Theme theme1(table);
+    ASSERT_EQ(NO_ERROR, theme1.applyStyle(app::R::style::Theme_One));
+    Res_value val;
+    ASSERT_GE(theme1.getAttribute(android::R::attr::background, &val), 0);
+    ASSERT_EQ(Res_value::TYPE_INT_COLOR_RGB8, val.dataType);
+    ASSERT_EQ(uint32_t(0xffff0000), val.data);
+    ASSERT_GE(theme1.getAttribute(app::R::attr::number, &val), 0);
+    ASSERT_EQ(Res_value::TYPE_INT_DEC, val.dataType);
+    ASSERT_EQ(uint32_t(1), val.data);
+
+    ResTable table2;
+    ASSERT_EQ(NO_ERROR, table2.add(system_arsc, system_arsc_len));
+    ASSERT_EQ(NO_ERROR, table2.add(app_arsc, app_arsc_len));
+
+    ResTable::Theme theme2(table2);
+    ASSERT_EQ(NO_ERROR, theme2.setTo(theme1));
+    ASSERT_GE(theme2.getAttribute(android::R::attr::background, &val), 0);
+    ASSERT_EQ(Res_value::TYPE_INT_COLOR_RGB8, val.dataType);
+    ASSERT_EQ(uint32_t(0xffff0000), val.data);
+    ASSERT_GE(theme2.getAttribute(app::R::attr::number, &val), 0);
+    ASSERT_EQ(Res_value::TYPE_INT_DEC, val.dataType);
+    ASSERT_EQ(uint32_t(1), val.data);
+}
+
+}
diff --git a/libs/androidfw/tests/data/app/AndroidManifest.xml b/libs/androidfw/tests/data/app/AndroidManifest.xml
new file mode 100644
index 0000000..bfa3a39
--- /dev/null
+++ b/libs/androidfw/tests/data/app/AndroidManifest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.android.app">
+</manifest>
diff --git a/libs/androidfw/tests/data/app/R.h b/libs/androidfw/tests/data/app/R.h
new file mode 100644
index 0000000..780a116
--- /dev/null
+++ b/libs/androidfw/tests/data/app/R.h
@@ -0,0 +1,22 @@
+#ifndef __APP_R_H
+#define __APP_R_H
+
+namespace app {
+namespace R {
+
+namespace attr {
+    enum {
+        number         = 0x7f010000,   // default
+    };
+}
+
+namespace style {
+    enum {
+        Theme_One      = 0x7f020000,   // default
+    };
+}
+
+} // namespace R
+} // namespace app
+
+#endif // __APP_R_H
diff --git a/libs/androidfw/tests/data/app/app_arsc.h b/libs/androidfw/tests/data/app/app_arsc.h
new file mode 100644
index 0000000..d5d9a3b
--- /dev/null
+++ b/libs/androidfw/tests/data/app/app_arsc.h
@@ -0,0 +1,62 @@
+unsigned char app_arsc[] = {
+  0x02, 0x00, 0x0c, 0x00, 0xc4, 0x02, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x01, 0x00, 0x1c, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x20, 0x01, 0x9c, 0x02, 0x00, 0x00,
+  0x7f, 0x00, 0x00, 0x00, 0x63, 0x00, 0x6f, 0x00, 0x6d, 0x00, 0x2e, 0x00,
+  0x61, 0x00, 0x6e, 0x00, 0x64, 0x00, 0x72, 0x00, 0x6f, 0x00, 0x69, 0x00,
+  0x64, 0x00, 0x2e, 0x00, 0x61, 0x00, 0x70, 0x00, 0x70, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x01, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x60, 0x01, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x1c, 0x00, 0x40, 0x00, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x0c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x61, 0x00, 0x74, 0x00, 0x74, 0x00,
+  0x72, 0x00, 0x00, 0x00, 0x05, 0x00, 0x73, 0x00, 0x74, 0x00, 0x79, 0x00,
+  0x6c, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x1c, 0x00,
+  0x4c, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x06, 0x00, 0x6e, 0x00,
+  0x75, 0x00, 0x6d, 0x00, 0x62, 0x00, 0x65, 0x00, 0x72, 0x00, 0x00, 0x00,
+  0x09, 0x00, 0x54, 0x00, 0x68, 0x00, 0x65, 0x00, 0x6d, 0x00, 0x65, 0x00,
+  0x2e, 0x00, 0x4f, 0x00, 0x6e, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x02, 0x02, 0x10, 0x00, 0x14, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x44, 0x00,
+  0x64, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x48, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x01, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00,
+  0x02, 0x02, 0x10, 0x00, 0x14, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x02, 0x44, 0x00,
+  0x64, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x48, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x01, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x01, 0x01, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x01, 0x7f, 0x08, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00
+};
+unsigned int app_arsc_len = 708;
diff --git a/libs/androidfw/tests/data/app/build b/libs/androidfw/tests/data/app/build
new file mode 100755
index 0000000..89c4641
--- /dev/null
+++ b/libs/androidfw/tests/data/app/build
@@ -0,0 +1,6 @@
+#!/bin/bash
+
+aapt package -v -I ../system/bundle.apk -M AndroidManifest.xml -S res -F bundle.apk -f && \
+unzip bundle.apk resources.arsc && \
+mv resources.arsc app.arsc && \
+xxd -i app.arsc > app_arsc.h
diff --git a/libs/androidfw/tests/data/app/res/values/values.xml b/libs/androidfw/tests/data/app/res/values/values.xml
new file mode 100644
index 0000000..b0ead38
--- /dev/null
+++ b/libs/androidfw/tests/data/app/res/values/values.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <attr name="number" format="integer"/>
+    <style name="Theme.One" parent="@android:style/Theme.One">
+        <item name="number">1</item>
+    </style>
+</resources>
diff --git a/libs/androidfw/tests/data/system/AndroidManifest.xml b/libs/androidfw/tests/data/system/AndroidManifest.xml
new file mode 100644
index 0000000..af105ee
--- /dev/null
+++ b/libs/androidfw/tests/data/system/AndroidManifest.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="android">
+</manifest>
diff --git a/libs/androidfw/tests/data/system/R.h b/libs/androidfw/tests/data/system/R.h
new file mode 100644
index 0000000..7a9d3db
--- /dev/null
+++ b/libs/androidfw/tests/data/system/R.h
@@ -0,0 +1,23 @@
+#ifndef __ANDROID_R_H
+#define __ANDROID_R_H
+
+namespace android {
+namespace R {
+
+namespace attr {
+    enum {
+        background  = 0x01010000, // default
+        foreground  = 0x01010001, // default
+    };
+}
+
+namespace style {
+    enum {
+        Theme_One      = 0x01020000,   // default
+    };
+}
+
+} // namespace R
+} // namespace android
+
+#endif // __ANDROID_R_H
diff --git a/libs/androidfw/tests/data/system/build b/libs/androidfw/tests/data/system/build
new file mode 100755
index 0000000..2a3ac0b
--- /dev/null
+++ b/libs/androidfw/tests/data/system/build
@@ -0,0 +1,6 @@
+#!/bin/bash
+
+aapt package -x -M AndroidManifest.xml -S res -F bundle.apk -f && \
+unzip bundle.apk resources.arsc && \
+mv resources.arsc system.arsc && \
+xxd -i system.arsc > system_arsc.h
diff --git a/libs/androidfw/tests/data/system/res/values/themes.xml b/libs/androidfw/tests/data/system/res/values/themes.xml
new file mode 100644
index 0000000..b29848e
--- /dev/null
+++ b/libs/androidfw/tests/data/system/res/values/themes.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <public name="background" type="attr" id="0x01010000"/>
+    <public name="foreground" type="attr" id="0x01010001"/>
+    <public name="Theme.One" type="style" id="0x01020000"/>
+
+    <attr name="background" format="color|reference"/>
+    <attr name="foreground" format="color|reference"/>
+    <style name="Theme.One" parent="">
+        <item name="android:background">#ff0000</item>
+        <item name="android:foreground">#000000</item>
+    </style>
+</resources>
diff --git a/libs/androidfw/tests/data/system/system_arsc.h b/libs/androidfw/tests/data/system/system_arsc.h
new file mode 100644
index 0000000..215ecae
--- /dev/null
+++ b/libs/androidfw/tests/data/system/system_arsc.h
@@ -0,0 +1,69 @@
+unsigned char system_arsc[] = {
+  0x02, 0x00, 0x0c, 0x00, 0x18, 0x03, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x01, 0x00, 0x1c, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x20, 0x01, 0xf0, 0x02, 0x00, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x61, 0x00, 0x6e, 0x00, 0x64, 0x00, 0x72, 0x00,
+  0x6f, 0x00, 0x69, 0x00, 0x64, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x01, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x60, 0x01, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x1c, 0x00, 0x40, 0x00, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x0c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x61, 0x00, 0x74, 0x00, 0x74, 0x00,
+  0x72, 0x00, 0x00, 0x00, 0x05, 0x00, 0x73, 0x00, 0x74, 0x00, 0x79, 0x00,
+  0x6c, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x1c, 0x00,
+  0x70, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00,
+  0x0a, 0x00, 0x62, 0x00, 0x61, 0x00, 0x63, 0x00, 0x6b, 0x00, 0x67, 0x00,
+  0x72, 0x00, 0x6f, 0x00, 0x75, 0x00, 0x6e, 0x00, 0x64, 0x00, 0x00, 0x00,
+  0x0a, 0x00, 0x66, 0x00, 0x6f, 0x00, 0x72, 0x00, 0x65, 0x00, 0x67, 0x00,
+  0x72, 0x00, 0x6f, 0x00, 0x75, 0x00, 0x6e, 0x00, 0x64, 0x00, 0x00, 0x00,
+  0x09, 0x00, 0x54, 0x00, 0x68, 0x00, 0x65, 0x00, 0x6d, 0x00, 0x65, 0x00,
+  0x2e, 0x00, 0x4f, 0x00, 0x6e, 0x00, 0x65, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x02, 0x02, 0x10, 0x00, 0x18, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x40,
+  0x01, 0x02, 0x44, 0x00, 0x84, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x1c, 0x00, 0x00, 0x00, 0x10, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01,
+  0x08, 0x00, 0x00, 0x10, 0x11, 0x00, 0x00, 0x00, 0x10, 0x00, 0x03, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0x10, 0x11, 0x00, 0x00, 0x00,
+  0x02, 0x02, 0x10, 0x00, 0x14, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
+  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x01, 0x02, 0x44, 0x00,
+  0x70, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+  0x48, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x03, 0x00,
+  0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x01, 0x01, 0x08, 0x00, 0x00, 0x1d, 0x00, 0x00, 0xff, 0xff,
+  0x01, 0x00, 0x01, 0x01, 0x08, 0x00, 0x00, 0x1d, 0x00, 0x00, 0x00, 0xff
+};
+unsigned int system_arsc_len = 792;
diff --git a/libs/hwui/AmbientShadow.cpp b/libs/hwui/AmbientShadow.cpp
index 9cc83ed..cb3a002 100644
--- a/libs/hwui/AmbientShadow.cpp
+++ b/libs/hwui/AmbientShadow.cpp
@@ -16,6 +16,43 @@
 
 #define LOG_TAG "OpenGLRenderer"
 
+/**
+ * Extra vertices for the corner for smoother corner.
+ * Only for outer vertices.
+ * Note that we use such extra memory to avoid an extra loop.
+ */
+// For half circle, we could add EXTRA_VERTEX_PER_PI vertices.
+// Set to 1 if we don't want to have any.
+#define EXTRA_CORNER_VERTEX_PER_PI 12
+
+// For the whole polygon, the sum of all the deltas b/t normals is 2 * M_PI,
+// therefore, the maximum number of extra vertices will be twice bigger.
+#define MAX_EXTRA_CORNER_VERTEX_NUMBER  (2 * EXTRA_CORNER_VERTEX_PER_PI)
+
+// For each RADIANS_DIVISOR, we would allocate one more vertex b/t the normals.
+#define CORNER_RADIANS_DIVISOR (M_PI / EXTRA_CORNER_VERTEX_PER_PI)
+
+/**
+ * Extra vertices for the Edge for interpolation artifacts.
+ * Same value for both inner and outer vertices.
+ */
+#define EXTRA_EDGE_VERTEX_PER_PI 50
+
+#define MAX_EXTRA_EDGE_VERTEX_NUMBER  (2 * EXTRA_EDGE_VERTEX_PER_PI)
+
+#define EDGE_RADIANS_DIVISOR  (M_PI / EXTRA_EDGE_VERTEX_PER_PI)
+
+/**
+ * Other constants:
+ */
+// For the edge of the penumbra, the opacity is 0.
+#define OUTER_OPACITY (0.0f)
+
+// Once the alpha difference is greater than this threshold, we will allocate extra
+// edge vertices.
+// If this is set to negative value, then all the edge will be tessellated.
+#define ALPHA_THRESHOLD (0.1f / 255.0f)
+
 #include <math.h>
 #include <utils/Log.h>
 #include <utils/Vector.h>
@@ -23,11 +60,78 @@
 #include "AmbientShadow.h"
 #include "ShadowTessellator.h"
 #include "Vertex.h"
+#include "utils/MathUtils.h"
 
 namespace android {
 namespace uirenderer {
 
 /**
+ *  Local utility functions.
+ */
+inline Vector2 getNormalFromVertices(const Vector3* vertices, int current, int next) {
+    // Convert from Vector3 to Vector2 first.
+    Vector2 currentVertex = { vertices[current].x, vertices[current].y };
+    Vector2 nextVertex = { vertices[next].x, vertices[next].y };
+
+    return ShadowTessellator::calculateNormal(currentVertex, nextVertex);
+}
+
+// The input z value will be converted to be non-negative inside.
+// The output must be ranged from 0 to 1.
+inline float getAlphaFromFactoredZ(float factoredZ) {
+    return 1.0 / (1 + MathUtils::max(factoredZ, 0.0f));
+}
+
+inline float getTransformedAlphaFromAlpha(float alpha) {
+    return acosf(1.0f - 2.0f * alpha);
+}
+
+// The output is ranged from 0 to M_PI.
+inline float getTransformedAlphaFromFactoredZ(float factoredZ) {
+    return getTransformedAlphaFromAlpha(getAlphaFromFactoredZ(factoredZ));
+}
+
+inline int getEdgeExtraAndUpdateSpike(Vector2* currentSpike,
+        const Vector3& secondVertex, const Vector3& centroid) {
+    Vector2 secondSpike  = {secondVertex.x - centroid.x, secondVertex.y - centroid.y};
+    secondSpike.normalize();
+
+    int result = ShadowTessellator::getExtraVertexNumber(secondSpike, *currentSpike,
+            EDGE_RADIANS_DIVISOR);
+    *currentSpike = secondSpike;
+    return result;
+}
+
+// Given the caster's vertex count, compute all the buffers size depending on
+// whether or not the caster is opaque.
+inline void computeBufferSize(int* totalVertexCount, int* totalIndexCount,
+        int* totalUmbraCount, int casterVertexCount, bool isCasterOpaque) {
+    // Compute the size of the vertex buffer.
+    int outerVertexCount = casterVertexCount * 2 + MAX_EXTRA_CORNER_VERTEX_NUMBER +
+        MAX_EXTRA_EDGE_VERTEX_NUMBER;
+    int innerVertexCount = casterVertexCount + MAX_EXTRA_EDGE_VERTEX_NUMBER;
+    *totalVertexCount = outerVertexCount + innerVertexCount;
+
+    // Compute the size of the index buffer.
+    *totalIndexCount = 2 * outerVertexCount + 2;
+
+    // Compute the size of the umber buffer.
+    // For translucent object, keep track of the umbra(inner) vertex in order to draw
+    // inside. We only need to store the index information.
+    *totalUmbraCount = 0;
+    if (!isCasterOpaque) {
+        // Add the centroid if occluder is translucent.
+        *totalVertexCount++;
+        *totalIndexCount += 2 * innerVertexCount + 1;
+        *totalUmbraCount = innerVertexCount;
+    }
+}
+
+inline bool needsExtraForEdge(float firstAlpha, float secondAlpha) {
+    return abs(firstAlpha - secondAlpha) > ALPHA_THRESHOLD;
+}
+
+/**
  * Calculate the shadows as a triangle strips while alpha value as the
  * shadow values.
  *
@@ -43,290 +147,198 @@
  *
  * @param shadowVertexBuffer Return an floating point array of (x, y, a)
  *               triangle strips mode.
+ *
+ * An simple illustration:
+ * For now let's mark the outer vertex as Pi, the inner as Vi, the centroid as C.
+ *
+ * First project the occluder to the Z=0 surface.
+ * Then we got all the inner vertices. And we compute the normal for each edge.
+ * According to the normal, we generate outer vertices. E.g: We generate P1 / P4
+ * as extra corner vertices to make the corner looks round and smoother.
+ *
+ * Due to the fact that the alpha is not linear interpolated along the inner
+ * edge, when the alpha is different, we may add extra vertices such as P2.1, P2.2,
+ * V0.1, V0.2 to avoid the visual artifacts.
+ *
+ *                                            (P3)
+ *          (P2)     (P2.1)     (P2.2)         |     ' (P4)
+ *   (P1)'   |        |           |            |   '
+ *         ' |        |           |            | '
+ * (P0)  ------------------------------------------------(P5)
+ *           | (V0)   (V0.1)    (V0.2)         |(V1)
+ *           |                                 |
+ *           |                                 |
+ *           |               (C)               |
+ *           |                                 |
+ *           |                                 |
+ *           |                                 |
+ *           |                                 |
+ *        (V3)-----------------------------------(V2)
  */
 void AmbientShadow::createAmbientShadow(bool isCasterOpaque,
-        const Vector3* vertices, int vertexCount, const Vector3& centroid3d,
+        const Vector3* casterVertices, int casterVertexCount, const Vector3& centroid3d,
         float heightFactor, float geomFactor, VertexBuffer& shadowVertexBuffer) {
-    const int rays = SHADOW_RAY_COUNT;
-    // Validate the inputs.
-    if (vertexCount < 3 || heightFactor <= 0 || rays <= 0
-        || geomFactor <= 0) {
-#if DEBUG_SHADOW
-        ALOGW("Invalid input for createAmbientShadow(), early return!");
-#endif
-        return;
-    }
+    shadowVertexBuffer.setMode(VertexBuffer::kIndices);
 
-    Vector<Vector2> dir; // TODO: use C++11 unique_ptr
-    dir.setCapacity(rays);
-    float rayDist[rays];
-    float rayHeight[rays];
-    calculateRayDirections(rays, vertices, vertexCount, centroid3d, dir.editArray());
+    // In order to computer the outer vertices in one loop, we need pre-compute
+    // the normal by the vertex (n - 1) to vertex 0, and the spike and alpha value
+    // for vertex 0.
+    Vector2 previousNormal = getNormalFromVertices(casterVertices,
+            casterVertexCount - 1 , 0);
+    Vector2 currentSpike = {casterVertices[0].x - centroid3d.x,
+        casterVertices[0].y - centroid3d.y};
+    currentSpike.normalize();
+    float currentAlpha = getAlphaFromFactoredZ(casterVertices[0].z * heightFactor);
 
-    // Calculate the length and height of the points along the edge.
-    //
-    // The math here is:
-    // Intersect each ray (starting from the centroid) with the polygon.
-    for (int i = 0; i < rays; i++) {
-        int edgeIndex;
-        float edgeFraction;
-        float rayDistance;
-        calculateIntersection(vertices, vertexCount, centroid3d, dir[i], edgeIndex,
-                edgeFraction, rayDistance);
-        rayDist[i] = rayDistance;
-        if (edgeIndex < 0 || edgeIndex >= vertexCount) {
-#if DEBUG_SHADOW
-            ALOGW("Invalid edgeIndex!");
-#endif
-            edgeIndex = 0;
-        }
-        float h1 = vertices[edgeIndex].z;
-        float h2 = vertices[((edgeIndex + 1) % vertexCount)].z;
-        rayHeight[i] = h1 + edgeFraction * (h2 - h1);
-    }
-
-    // The output buffer length basically is roughly rays * layers, but since we
-    // need triangle strips, so we need to duplicate vertices to accomplish that.
+    // Preparing all the output data.
+    int totalVertexCount, totalIndexCount, totalUmbraCount;
+    computeBufferSize(&totalVertexCount, &totalIndexCount, &totalUmbraCount,
+            casterVertexCount, isCasterOpaque);
     AlphaVertex* shadowVertices =
-            shadowVertexBuffer.alloc<AlphaVertex>(SHADOW_VERTEX_COUNT);
+            shadowVertexBuffer.alloc<AlphaVertex>(totalVertexCount);
+    int vertexBufferIndex = 0;
+    uint16_t* indexBuffer = shadowVertexBuffer.allocIndices<uint16_t>(totalIndexCount);
+    int indexBufferIndex = 0;
+    uint16_t umbraVertices[totalUmbraCount];
+    int umbraIndex = 0;
 
-    // Calculate the vertex of the shadows.
-    //
-    // The math here is:
-    // Along the edges of the polygon, for each intersection point P (generated above),
-    // calculate the normal N, which should be perpendicular to the edge of the
-    // polygon (represented by the neighbor intersection points) .
-    // Shadow's vertices will be generated as : P + N * scale.
-    const Vector2 centroid2d = {centroid3d.x, centroid3d.y};
-    for (int rayIndex = 0; rayIndex < rays; rayIndex++) {
-        Vector2 normal = {1.0f, 0.0f};
-        calculateNormal(rays, rayIndex, dir.array(), rayDist, normal);
+    for (int i = 0; i < casterVertexCount; i++)  {
+        // Corner: first figure out the extra vertices we need for the corner.
+        const Vector3& innerVertex = casterVertices[i];
+        Vector2 currentNormal = getNormalFromVertices(casterVertices, i,
+                (i + 1) % casterVertexCount);
 
-        // The vertex should be start from rayDist[i] then scale the
-        // normalizeNormal!
-        Vector2 intersection = dir[rayIndex] * rayDist[rayIndex] +
-                centroid2d;
+        int extraVerticesNumber = ShadowTessellator::getExtraVertexNumber(currentNormal,
+                previousNormal, CORNER_RADIANS_DIVISOR);
 
-        // outer ring of points, expanded based upon height of each ray intersection
-        float expansionDist = rayHeight[rayIndex] * heightFactor *
-                geomFactor;
-        AlphaVertex::set(&shadowVertices[rayIndex],
-                intersection.x + normal.x * expansionDist,
-                intersection.y + normal.y * expansionDist,
-                0.0f);
-
-        // inner ring of points
-        float opacity = 1.0 / (1 + rayHeight[rayIndex] * heightFactor);
-        // NOTE: Shadow alpha values are transformed when stored in alphavertices,
-        // so that they can be consumed directly by gFS_Main_ApplyVertexAlphaShadowInterp
-        float transformedOpacity = acos(1.0f - 2.0f * opacity);
-        AlphaVertex::set(&shadowVertices[rays + rayIndex],
-                intersection.x,
-                intersection.y,
-                transformedOpacity);
-    }
-
-    if (isCasterOpaque) {
-        // skip inner ring, calc bounds over filled portion of buffer
-        shadowVertexBuffer.computeBounds<AlphaVertex>(2 * rays);
-        shadowVertexBuffer.setMode(VertexBuffer::kOnePolyRingShadow);
-    } else {
-        // If caster isn't opaque, we need to to fill the umbra by storing the umbra's
-        // centroid in the innermost ring of vertices.
-        float centroidAlpha = 1.0 / (1 + centroid3d.z * heightFactor);
-        AlphaVertex centroidXYA;
-        AlphaVertex::set(&centroidXYA, centroid2d.x, centroid2d.y, centroidAlpha);
-        for (int rayIndex = 0; rayIndex < rays; rayIndex++) {
-            shadowVertices[2 * rays + rayIndex] = centroidXYA;
-        }
-        // calc bounds over entire buffer
-        shadowVertexBuffer.computeBounds<AlphaVertex>();
-        shadowVertexBuffer.setMode(VertexBuffer::kTwoPolyRingShadow);
-    }
-
+        float expansionDist = innerVertex.z * heightFactor * geomFactor;
+        const int cornerSlicesNumber = extraVerticesNumber + 1; // Minimal as 1.
 #if DEBUG_SHADOW
-    for (int i = 0; i < SHADOW_VERTEX_COUNT; i++) {
-        ALOGD("ambient shadow value: i %d, (x:%f, y:%f, a:%f)", i, shadowVertices[i].x,
-                shadowVertices[i].y, shadowVertices[i].alpha);
-    }
+        ALOGD("cornerSlicesNumber is %d", cornerSlicesNumber);
 #endif
-}
 
-/**
- * Generate an array of rays' direction vectors.
- * To make sure the vertices generated are clockwise, the directions are from PI
- * to -PI.
- *
- * @param rays The number of rays shooting out from the centroid.
- * @param vertices Vertices of the polygon.
- * @param vertexCount The number of vertices.
- * @param centroid3d The centroid of the polygon.
- * @param dir Return the array of ray vectors.
- */
-void AmbientShadow::calculateRayDirections(const int rays, const Vector3* vertices,
-        const int vertexCount, const Vector3& centroid3d, Vector2* dir) {
-    // If we don't have enough rays, then fall back to the uniform distribution.
-    if (vertexCount * 2 > rays) {
-        float deltaAngle = 2 * M_PI / rays;
-        for (int i = 0; i < rays; i++) {
-            dir[i].x = cosf(M_PI - deltaAngle * i);
-            dir[i].y = sinf(M_PI - deltaAngle * i);
+        // Corner: fill the corner Vertex Buffer(VB) and Index Buffer(IB).
+        // We fill the inner vertex first, such that we can fill the index buffer
+        // inside the loop.
+        int currentInnerVertexIndex = vertexBufferIndex;
+        if (!isCasterOpaque) {
+            umbraVertices[umbraIndex++] = vertexBufferIndex;
         }
-        return;
-    }
+        AlphaVertex::set(&shadowVertices[vertexBufferIndex++], casterVertices[i].x,
+                casterVertices[i].y,
+                getTransformedAlphaFromAlpha(currentAlpha));
 
-    // If we have enough rays, then we assign each vertices a ray, and distribute
-    // the rest uniformly.
-    float rayThetas[rays];
+        const Vector3& innerStart = casterVertices[i];
 
-    const int uniformRayCount = rays - vertexCount;
-    const float deltaAngle = 2 * M_PI / uniformRayCount;
+        // outerStart is the first outer vertex for this inner vertex.
+        // outerLast is the last outer vertex for this inner vertex.
+        Vector2 outerStart = {0, 0};
+        Vector2 outerLast = {0, 0};
+        // This will create vertices from [0, cornerSlicesNumber] inclusively,
+        // which means minimally 2 vertices even without the extra ones.
+        for (int j = 0; j <= cornerSlicesNumber; j++) {
+            Vector2 averageNormal =
+                previousNormal * (cornerSlicesNumber - j) + currentNormal * j;
+            averageNormal /= cornerSlicesNumber;
+            averageNormal.normalize();
+            Vector2 outerVertex;
+            outerVertex.x = innerVertex.x + averageNormal.x * expansionDist;
+            outerVertex.y = innerVertex.y + averageNormal.y * expansionDist;
 
-    // We have to generate all the vertices' theta anyway and we also need to
-    // find the minimal, so let's precompute it first.
-    // Since the incoming polygon is clockwise, we can find the dip to identify
-    // the minimal theta.
-    float polyThetas[vertexCount];
-    int maxPolyThetaIndex = 0;
-    for (int i = 0; i < vertexCount; i++) {
-        polyThetas[i] = atan2(vertices[i].y - centroid3d.y,
-                vertices[i].x - centroid3d.x);
-        if (i > 0 && polyThetas[i] > polyThetas[i - 1]) {
-            maxPolyThetaIndex = i;
-        }
-    }
+            indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+            indexBuffer[indexBufferIndex++] = currentInnerVertexIndex;
+            AlphaVertex::set(&shadowVertices[vertexBufferIndex++], outerVertex.x,
+                    outerVertex.y, OUTER_OPACITY);
 
-    // Both poly's thetas and uniform thetas are in decrease order(clockwise)
-    // from PI to -PI.
-    int polyThetaIndex = maxPolyThetaIndex;
-    float polyTheta = polyThetas[maxPolyThetaIndex];
-    int uniformThetaIndex = 0;
-    float uniformTheta = M_PI;
-    for (int i = 0; i < rays; i++) {
-        // Compare both thetas and pick the smaller one and move on.
-        bool hasThetaCollision = abs(polyTheta - uniformTheta) < MINIMAL_DELTA_THETA;
-        if (polyTheta > uniformTheta || hasThetaCollision) {
-            if (hasThetaCollision) {
-                // Shift the uniformTheta to middle way between current polyTheta
-                // and next uniform theta. The next uniform theta can wrap around
-                // to exactly PI safely here.
-                // Note that neither polyTheta nor uniformTheta can be FLT_MAX
-                // due to the hasThetaCollision is true.
-                uniformTheta = (polyTheta +  M_PI - deltaAngle * (uniformThetaIndex + 1)) / 2;
-#if DEBUG_SHADOW
-                ALOGD("Shifted uniformTheta to %f", uniformTheta);
-#endif
-            }
-            rayThetas[i] = polyTheta;
-            polyThetaIndex = (polyThetaIndex + 1) % vertexCount;
-            if (polyThetaIndex != maxPolyThetaIndex) {
-                polyTheta = polyThetas[polyThetaIndex];
-            } else {
-                // out of poly points.
-                polyTheta = - FLT_MAX;
-            }
-        } else {
-            rayThetas[i] = uniformTheta;
-            uniformThetaIndex++;
-            if (uniformThetaIndex < uniformRayCount) {
-                uniformTheta = M_PI - deltaAngle * uniformThetaIndex;
-            } else {
-                // out of uniform points.
-                uniformTheta = - FLT_MAX;
+            if (j == 0) {
+                outerStart = outerVertex;
+            } else if (j == cornerSlicesNumber) {
+                outerLast = outerVertex;
             }
         }
-    }
+        previousNormal = currentNormal;
 
-    for (int i = 0; i < rays; i++) {
+        // Edge: first figure out the extra vertices needed for the edge.
+        const Vector3& innerNext = casterVertices[(i + 1) % casterVertexCount];
+        float nextAlpha = getAlphaFromFactoredZ(innerNext.z * heightFactor);
+        if (needsExtraForEdge(currentAlpha, nextAlpha)) {
+            // TODO: See if we can / should cache this outer vertex across the loop.
+            Vector2 outerNext;
+            float expansionDist = innerNext.z * heightFactor * geomFactor;
+            outerNext.x = innerNext.x + currentNormal.x * expansionDist;
+            outerNext.y = innerNext.y + currentNormal.y * expansionDist;
+
+            // Compute the angle and see how many extra points we need.
+            int extraVerticesNumber = getEdgeExtraAndUpdateSpike(&currentSpike,
+                    innerNext, centroid3d);
 #if DEBUG_SHADOW
-        ALOGD("No. %d : %f", i, rayThetas[i] * 180 / M_PI);
+            ALOGD("extraVerticesNumber %d for edge %d", extraVerticesNumber, i);
 #endif
-        // TODO: Fix the intersection precision problem and remvoe the delta added
-        // here.
-        dir[i].x = cosf(rayThetas[i] + MINIMAL_DELTA_THETA);
-        dir[i].y = sinf(rayThetas[i] + MINIMAL_DELTA_THETA);
-    }
-}
+            // Edge: fill the edge's VB and IB.
+            // This will create vertices pair from [1, extraVerticesNumber - 1].
+            // If there is no extra vertices created here, the edge will be drawn
+            // as just 2 triangles.
+            for (int k = 1; k < extraVerticesNumber; k++) {
+                int startWeight = extraVerticesNumber - k;
+                Vector2 currentOuter =
+                    (outerLast * startWeight + outerNext * k) / extraVerticesNumber;
+                indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+                AlphaVertex::set(&shadowVertices[vertexBufferIndex++], currentOuter.x,
+                        currentOuter.y, OUTER_OPACITY);
 
-/**
- * Calculate the intersection of a ray hitting the polygon.
- *
- * @param vertices The shadow caster's polygon, which is represented in a
- *                 Vector3 array.
- * @param vertexCount The length of caster's polygon in terms of number of vertices.
- * @param start The starting point of the ray.
- * @param dir The direction vector of the ray.
- *
- * @param outEdgeIndex Return the index of the segment (or index of the starting
- *                     vertex) that ray intersect with.
- * @param outEdgeFraction Return the fraction offset from the segment starting
- *                        index.
- * @param outRayDist Return the ray distance from centroid to the intersection.
- */
-void AmbientShadow::calculateIntersection(const Vector3* vertices, int vertexCount,
-        const Vector3& start, const Vector2& dir, int& outEdgeIndex,
-        float& outEdgeFraction, float& outRayDist) {
-    float startX = start.x;
-    float startY = start.y;
-    float dirX = dir.x;
-    float dirY = dir.y;
-    // Start the search from the last edge from poly[len-1] to poly[0].
-    int p1 = vertexCount - 1;
-
-    for (int p2 = 0; p2 < vertexCount; p2++) {
-        float p1x = vertices[p1].x;
-        float p1y = vertices[p1].y;
-        float p2x = vertices[p2].x;
-        float p2y = vertices[p2].y;
-
-        // The math here is derived from:
-        // f(t, v) = p1x * (1 - t) + p2x * t - (startX + dirX * v) = 0;
-        // g(t, v) = p1y * (1 - t) + p2y * t - (startY + dirY * v) = 0;
-        float div = (dirX * (p1y - p2y) + dirY * p2x - dirY * p1x);
-        if (div != 0) {
-            float t = (dirX * (p1y - startY) + dirY * startX - dirY * p1x) / (div);
-            if (t > 0 && t <= 1) {
-                float t2 = (p1x * (startY - p2y)
-                            + p2x * (p1y - startY)
-                            + startX * (p2y - p1y)) / div;
-                if (t2 > 0) {
-                    outEdgeIndex = p1;
-                    outRayDist = t2;
-                    outEdgeFraction = t;
-                    return;
+                if (!isCasterOpaque) {
+                    umbraVertices[umbraIndex++] = vertexBufferIndex;
                 }
+                Vector3 currentInner =
+                    (innerStart * startWeight + innerNext * k) / extraVerticesNumber;
+                indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+                AlphaVertex::set(&shadowVertices[vertexBufferIndex++], currentInner.x,
+                        currentInner.y,
+                        getTransformedAlphaFromFactoredZ(currentInner.z * heightFactor));
             }
         }
-        p1 = p2;
+        currentAlpha = nextAlpha;
     }
-    return;
-};
 
-/**
- * Calculate the normal at the intersection point between a ray and the polygon.
- *
- * @param rays The total number of rays.
- * @param currentRayIndex The index of the ray which the normal is based on.
- * @param dir The array of the all the rays directions.
- * @param rayDist The pre-computed ray distances array.
- *
- * @param normal Return the normal.
- */
-void AmbientShadow::calculateNormal(int rays, int currentRayIndex,
-        const Vector2* dir, const float* rayDist, Vector2& normal) {
-    int preIndex = (currentRayIndex - 1 + rays) % rays;
-    int postIndex = (currentRayIndex + 1) % rays;
-    Vector2 p1 = dir[preIndex] * rayDist[preIndex];
-    Vector2 p2 = dir[postIndex] * rayDist[postIndex];
+    indexBuffer[indexBufferIndex++] = 1;
+    indexBuffer[indexBufferIndex++] = 0;
 
-    // Now the rays are going CW around the poly.
-    Vector2 delta = p2 - p1;
-    if (delta.length() != 0) {
-        delta.normalize();
-        // Calculate the normal , which is CCW 90 rotate to the delta.
-        normal.x = - delta.y;
-        normal.y = delta.x;
+    if (!isCasterOpaque) {
+        // Add the centroid as the last one in the vertex buffer.
+        float centroidOpacity =
+            getTransformedAlphaFromFactoredZ(centroid3d.z * heightFactor);
+        int centroidIndex = vertexBufferIndex;
+        AlphaVertex::set(&shadowVertices[vertexBufferIndex++], centroid3d.x,
+                centroid3d.y, centroidOpacity);
+
+        for (int i = 0; i < umbraIndex; i++) {
+            // Note that umbraVertices[0] is always 0.
+            // So the start and the end of the umbra are using the "0".
+            // And penumbra ended with 0, so a degenerated triangle is formed b/t
+            // the umbra and penumbra.
+            indexBuffer[indexBufferIndex++] = umbraVertices[i];
+            indexBuffer[indexBufferIndex++] = centroidIndex;
+        }
+        indexBuffer[indexBufferIndex++] = 0;
     }
+
+    // At the end, update the real index and vertex buffer size.
+    shadowVertexBuffer.updateVertexCount(vertexBufferIndex);
+    shadowVertexBuffer.updateIndexCount(indexBufferIndex);
+
+    ShadowTessellator::checkOverflow(vertexBufferIndex, totalVertexCount, "Vertex Buffer");
+    ShadowTessellator::checkOverflow(indexBufferIndex, totalIndexCount, "Index Buffer");
+    ShadowTessellator::checkOverflow(umbraIndex, totalUmbraCount, "Umbra Buffer");
+
+#if DEBUG_SHADOW
+    for (int i = 0; i < vertexBufferIndex; i++) {
+        ALOGD("vertexBuffer i %d, (%f, %f %f)", i, shadowVertices[i].x, shadowVertices[i].y,
+                shadowVertices[i].alpha);
+    }
+    for (int i = 0; i < indexBufferIndex; i++) {
+        ALOGD("indexBuffer i %d, indexBuffer[i] %d", i, indexBuffer[i]);
+    }
+#endif
 }
 
 }; // namespace uirenderer
diff --git a/libs/hwui/AmbientShadow.h b/libs/hwui/AmbientShadow.h
index 68df246..9660dc0 100644
--- a/libs/hwui/AmbientShadow.h
+++ b/libs/hwui/AmbientShadow.h
@@ -28,27 +28,12 @@
 
 /**
  * AmbientShadow is used to calculate the ambient shadow value around a polygon.
- *
- * TODO: calculateIntersection() now is O(N*M), where N is the number of
- * polygon's vertics and M is the number of rays. In fact, by staring tracing
- * the vertex from the previous intersection, the algorithm can be O(N + M);
  */
 class AmbientShadow {
 public:
     static void createAmbientShadow(bool isCasterOpaque, const Vector3* poly,
             int polyLength, const Vector3& centroid3d, float heightFactor,
             float geomFactor, VertexBuffer& shadowVertexBuffer);
-
-private:
-    static void calculateRayDirections(const int rays, const Vector3* vertices,
-            const int vertexCount, const Vector3& centroid3d, Vector2* dir);
-
-    static void calculateIntersection(const Vector3* poly, int nbVertices,
-            const Vector3& start, const Vector2& dir, int& outEdgeIndex,
-            float& outEdgeFraction, float& outRayDist);
-
-    static void calculateNormal(int rays, int currentRayIndex, const Vector2* dir,
-            const float* rayDist, Vector2& normal);
 }; // AmbientShadow
 
 }; // namespace uirenderer
diff --git a/libs/hwui/Android.mk b/libs/hwui/Android.mk
index d9f7941..49560ff 100644
--- a/libs/hwui/Android.mk
+++ b/libs/hwui/Android.mk
@@ -12,6 +12,7 @@
 		font/CacheTexture.cpp \
 		font/Font.cpp \
 		AmbientShadow.cpp \
+		AnimationContext.cpp \
 		Animator.cpp \
 		AnimatorManager.cpp \
 		AssetAtlas.cpp \
diff --git a/libs/hwui/AnimationContext.cpp b/libs/hwui/AnimationContext.cpp
new file mode 100644
index 0000000..a20bdae
--- /dev/null
+++ b/libs/hwui/AnimationContext.cpp
@@ -0,0 +1,143 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+#include "AnimationContext.h"
+
+#include "Animator.h"
+#include "RenderNode.h"
+#include "renderthread/TimeLord.h"
+
+namespace android {
+namespace uirenderer {
+
+AnimationContext::AnimationContext(renderthread::TimeLord& clock)
+        : mClock(clock)
+        , mCurrentFrameAnimations(*this)
+        , mNextFrameAnimations(*this)
+        , mFrameTimeMs(0) {
+}
+
+AnimationContext::~AnimationContext() {
+}
+
+void AnimationContext::destroy() {
+    startFrame(TreeInfo::MODE_RT_ONLY);
+    while (mCurrentFrameAnimations.mNextHandle) {
+        AnimationHandle* current = mCurrentFrameAnimations.mNextHandle;
+        AnimatorManager& animators = current->mRenderNode->animators();
+        animators.endAllActiveAnimators();
+        LOG_ALWAYS_FATAL_IF(mCurrentFrameAnimations.mNextHandle == current,
+                "endAllAnimators failed to remove from current frame list!");
+    }
+}
+
+void AnimationContext::addAnimatingRenderNode(RenderNode& node) {
+    if (!node.animators().hasAnimationHandle()) {
+        AnimationHandle* handle = new AnimationHandle(node, *this);
+        addAnimationHandle(handle);
+    }
+}
+
+void AnimationContext::addAnimationHandle(AnimationHandle* handle) {
+    handle->insertAfter(&mNextFrameAnimations);
+}
+
+void AnimationContext::startFrame(TreeInfo::TraversalMode mode) {
+    LOG_ALWAYS_FATAL_IF(mCurrentFrameAnimations.mNextHandle,
+            "Missed running animations last frame!");
+    AnimationHandle* head = mNextFrameAnimations.mNextHandle;
+    if (head) {
+        mNextFrameAnimations.mNextHandle = NULL;
+        mCurrentFrameAnimations.mNextHandle = head;
+        head->mPreviousHandle = &mCurrentFrameAnimations;
+    }
+    mFrameTimeMs = mClock.computeFrameTimeMs();
+}
+
+void AnimationContext::runRemainingAnimations(TreeInfo& info) {
+    while (mCurrentFrameAnimations.mNextHandle) {
+        AnimationHandle* current = mCurrentFrameAnimations.mNextHandle;
+        AnimatorManager& animators = current->mRenderNode->animators();
+        animators.pushStaging();
+        animators.animateNoDamage(info);
+        LOG_ALWAYS_FATAL_IF(mCurrentFrameAnimations.mNextHandle == current,
+                "Animate failed to remove from current frame list!");
+    }
+}
+
+void AnimationContext::callOnFinished(BaseRenderNodeAnimator* animator,
+        AnimationListener* listener) {
+    listener->onAnimationFinished(animator);
+}
+
+AnimationHandle::AnimationHandle(AnimationContext& context)
+        : mContext(context)
+        , mPreviousHandle(NULL)
+        , mNextHandle(NULL) {
+}
+
+AnimationHandle::AnimationHandle(RenderNode& animatingNode, AnimationContext& context)
+        : mRenderNode(&animatingNode)
+        , mContext(context)
+        , mPreviousHandle(NULL)
+        , mNextHandle(NULL) {
+    mRenderNode->animators().setAnimationHandle(this);
+}
+
+AnimationHandle::~AnimationHandle() {
+    LOG_ALWAYS_FATAL_IF(mPreviousHandle || mNextHandle,
+            "AnimationHandle destroyed while still animating!");
+}
+
+void AnimationHandle::notifyAnimationsRan() {
+    removeFromList();
+    if (mRenderNode->animators().hasAnimators()) {
+        mContext.addAnimationHandle(this);
+    } else {
+        release();
+    }
+}
+
+void AnimationHandle::release() {
+    LOG_ALWAYS_FATAL_IF(mRenderNode->animators().hasAnimators(),
+            "Releasing the handle for an RenderNode with outstanding animators!");
+    removeFromList();
+    mRenderNode->animators().setAnimationHandle(NULL);
+    delete this;
+}
+
+void AnimationHandle::insertAfter(AnimationHandle* prev) {
+    removeFromList();
+    mNextHandle = prev->mNextHandle;
+    if (mNextHandle) {
+        mNextHandle->mPreviousHandle = this;
+    }
+    prev->mNextHandle = this;
+    mPreviousHandle = prev;
+}
+
+void AnimationHandle::removeFromList() {
+    if (mPreviousHandle) {
+        mPreviousHandle->mNextHandle = mNextHandle;
+    }
+    if (mNextHandle) {
+        mNextHandle->mPreviousHandle = mPreviousHandle;
+    }
+    mPreviousHandle = NULL;
+    mNextHandle = NULL;
+}
+
+} /* namespace uirenderer */
+} /* namespace android */
diff --git a/libs/hwui/AnimationContext.h b/libs/hwui/AnimationContext.h
new file mode 100644
index 0000000..909ed36
--- /dev/null
+++ b/libs/hwui/AnimationContext.h
@@ -0,0 +1,121 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+#ifndef TREEANIMATIONTRACKER_H_
+#define TREEANIMATIONTRACKER_H_
+
+#include <cutils/compiler.h>
+#include <utils/RefBase.h>
+#include <utils/StrongPointer.h>
+
+#include "TreeInfo.h"
+#include "renderthread/TimeLord.h"
+#include "utils/Macros.h"
+
+namespace android {
+namespace uirenderer {
+
+class AnimationContext;
+class AnimationListener;
+class BaseRenderNodeAnimator;
+class RenderNode;
+
+/*
+ * AnimationHandle is several classes merged into one.
+ * 1: It maintains the reference to the AnimationContext required to run animators.
+ * 2: It keeps a strong reference to RenderNodes with animators so that
+ *    we don't lose them if they are no longer in the display tree. This is
+ *    required so that we can keep animating them, and properly notify listeners
+ *    of onAnimationFinished.
+ * 3: It forms a doubly linked list so that we can cheaply move between states.
+ */
+class AnimationHandle {
+    PREVENT_COPY_AND_ASSIGN(AnimationHandle);
+public:
+    AnimationContext& context() { return mContext; }
+
+    // Called by the RenderNode when it has internally pulsed its own animations
+    // this frame and does not need to be run again this frame.
+    void notifyAnimationsRan();
+
+    // Stops tracking the RenderNode and destroys the handle. The node must be
+    // re-attached to the AnimationContext to receive managed animation
+    // pulses.
+    void release();
+
+private:
+    friend class AnimationContext;
+    AnimationHandle(AnimationContext& context);
+    AnimationHandle(RenderNode& animatingNode, AnimationContext& context);
+    ~AnimationHandle();
+
+    void insertAfter(AnimationHandle* prev);
+    void removeFromList();
+
+    sp<RenderNode> mRenderNode;
+
+    AnimationContext& mContext;
+
+    AnimationHandle* mPreviousHandle;
+    AnimationHandle* mNextHandle;
+};
+
+class AnimationContext {
+    PREVENT_COPY_AND_ASSIGN(AnimationContext);
+public:
+    ANDROID_API AnimationContext(renderthread::TimeLord& clock);
+    ANDROID_API virtual ~AnimationContext();
+
+    nsecs_t frameTimeMs() { return mFrameTimeMs; }
+    bool hasAnimations() {
+        return mCurrentFrameAnimations.mNextHandle
+                || mNextFrameAnimations.mNextHandle;
+    }
+
+    // Will always add to the next frame list, which is swapped when
+    // startFrame() is called
+    ANDROID_API void addAnimatingRenderNode(RenderNode& node);
+
+    // Marks the start of a frame, which will update the frame time and move all
+    // next frame animations into the current frame
+    ANDROID_API virtual void startFrame(TreeInfo::TraversalMode mode);
+
+    // Runs any animations still left in mCurrentFrameAnimations that were not run
+    // as part of the standard RenderNode:prepareTree pass.
+    ANDROID_API virtual void runRemainingAnimations(TreeInfo& info);
+
+    ANDROID_API virtual void callOnFinished(BaseRenderNodeAnimator* animator, AnimationListener* listener);
+
+    ANDROID_API virtual void destroy();
+
+private:
+    friend class AnimationHandle;
+    void addAnimationHandle(AnimationHandle* handle);
+
+    renderthread::TimeLord& mClock;
+
+    // Animations left to run this frame, at the end of the frame this should
+    // be null
+    AnimationHandle mCurrentFrameAnimations;
+    // Animations queued for next frame
+    AnimationHandle mNextFrameAnimations;
+
+    nsecs_t mFrameTimeMs;
+};
+
+} /* namespace uirenderer */
+} /* namespace android */
+
+#endif /* TREEANIMATIONTRACKER_H_ */
diff --git a/libs/hwui/Animator.cpp b/libs/hwui/Animator.cpp
index 78d569d..8bf2107 100644
--- a/libs/hwui/Animator.cpp
+++ b/libs/hwui/Animator.cpp
@@ -19,6 +19,7 @@
 #include <inttypes.h>
 #include <set>
 
+#include "AnimationContext.h"
 #include "RenderNode.h"
 #include "RenderProperties.h"
 
@@ -40,7 +41,8 @@
         , mHasStartValue(false)
         , mStartTime(0)
         , mDuration(300)
-        , mStartDelay(0) {
+        , mStartDelay(0)
+        , mMayRunAsync(true) {
 }
 
 BaseRenderNodeAnimator::~BaseRenderNodeAnimator() {
@@ -85,7 +87,7 @@
     onAttached();
 }
 
-void BaseRenderNodeAnimator::pushStaging(TreeInfo& info) {
+void BaseRenderNodeAnimator::pushStaging(AnimationContext& context) {
     if (!mHasStartValue) {
         doSetStartValue(getValue(mTarget));
     }
@@ -93,21 +95,24 @@
         mPlayState = mStagingPlayState;
         // Oh boy, we're starting! Man the battle stations!
         if (mPlayState == RUNNING) {
-            transitionToRunning(info);
+            transitionToRunning(context);
+        } else if (mPlayState == FINISHED) {
+            callOnFinishedListener(context);
         }
     }
 }
 
-void BaseRenderNodeAnimator::transitionToRunning(TreeInfo& info) {
-    LOG_ALWAYS_FATAL_IF(info.frameTimeMs <= 0, "%" PRId64 " isn't a real frame time!", info.frameTimeMs);
+void BaseRenderNodeAnimator::transitionToRunning(AnimationContext& context) {
+    nsecs_t frameTimeMs = context.frameTimeMs();
+    LOG_ALWAYS_FATAL_IF(frameTimeMs <= 0, "%" PRId64 " isn't a real frame time!", frameTimeMs);
     if (mStartDelay < 0 || mStartDelay > 50000) {
         ALOGW("Your start delay is strange and confusing: %" PRId64, mStartDelay);
     }
-    mStartTime = info.frameTimeMs + mStartDelay;
+    mStartTime = frameTimeMs + mStartDelay;
     if (mStartTime < 0) {
         ALOGW("Ended up with a really weird start time of %" PRId64
                 " with frame time %" PRId64 " and start delay %" PRId64,
-                mStartTime, info.frameTimeMs, mStartDelay);
+                mStartTime, frameTimeMs, mStartDelay);
         // Set to 0 so that the animate() basically instantly finishes
         mStartTime = 0;
     }
@@ -120,7 +125,7 @@
     }
 }
 
-bool BaseRenderNodeAnimator::animate(TreeInfo& info) {
+bool BaseRenderNodeAnimator::animate(AnimationContext& context) {
     if (mPlayState < RUNNING) {
         return false;
     }
@@ -132,15 +137,14 @@
     // because the staging properties reflect the final value, we always need
     // to call setValue even if the animation isn't yet running or is still
     // being delayed as we need to override the staging value
-    if (mStartTime > info.frameTimeMs) {
-        info.out.hasAnimations |= true;
+    if (mStartTime > context.frameTimeMs()) {
         setValue(mTarget, mFromValue);
         return false;
     }
 
     float fraction = 1.0f;
     if (mPlayState == RUNNING && mDuration > 0) {
-        fraction = (float)(info.frameTimeMs - mStartTime) / mDuration;
+        fraction = (float)(context.frameTimeMs() - mStartTime) / mDuration;
     }
     if (fraction >= 1.0f) {
         fraction = 1.0f;
@@ -151,21 +155,23 @@
     setValue(mTarget, mFromValue + (mDeltaValue * fraction));
 
     if (mPlayState == FINISHED) {
-        callOnFinishedListener(info);
+        callOnFinishedListener(context);
         return true;
     }
 
-    info.out.hasAnimations |= true;
     return false;
 }
 
-void BaseRenderNodeAnimator::callOnFinishedListener(TreeInfo& info) {
+void BaseRenderNodeAnimator::forceEndNow(AnimationContext& context) {
+    if (mPlayState < FINISHED) {
+        mPlayState = FINISHED;
+        callOnFinishedListener(context);
+    }
+}
+
+void BaseRenderNodeAnimator::callOnFinishedListener(AnimationContext& context) {
     if (mListener.get()) {
-        if (!info.animationHook) {
-            mListener->onAnimationFinished(this);
-        } else {
-            info.animationHook->callOnFinished(this, mListener.get());
-        }
+        context.callOnFinished(this, mListener.get());
     }
 }
 
diff --git a/libs/hwui/Animator.h b/libs/hwui/Animator.h
index 6dfe7b4..35a4a09 100644
--- a/libs/hwui/Animator.h
+++ b/libs/hwui/Animator.h
@@ -28,6 +28,8 @@
 namespace android {
 namespace uirenderer {
 
+class AnimationContext;
+class BaseRenderNodeAnimator;
 class RenderNode;
 class RenderProperties;
 
@@ -50,20 +52,28 @@
     ANDROID_API void setListener(AnimationListener* listener) {
         mListener = listener;
     }
+    AnimationListener* listener() { return mListener.get(); }
+    ANDROID_API void setAllowRunningAsync(bool mayRunAsync) {
+        mMayRunAsync = mayRunAsync;
+    }
+    bool mayRunAsync() { return mMayRunAsync; }
     ANDROID_API void start() { mStagingPlayState = RUNNING; onStagingPlayStateChanged(); }
     ANDROID_API void end() { mStagingPlayState = FINISHED; onStagingPlayStateChanged(); }
 
     void attach(RenderNode* target);
     virtual void onAttached() {}
     void detach() { mTarget = 0; }
-    void pushStaging(TreeInfo& info);
-    bool animate(TreeInfo& info);
+    void pushStaging(AnimationContext& context);
+    bool animate(AnimationContext& context);
 
+    bool isRunning() { return mPlayState == RUNNING; }
     bool isFinished() { return mPlayState == FINISHED; }
     float finalValue() { return mFinalValue; }
 
     ANDROID_API virtual uint32_t dirtyMask() = 0;
 
+    void forceEndNow(AnimationContext& context);
+
 protected:
     BaseRenderNodeAnimator(float finalValue);
     virtual ~BaseRenderNodeAnimator();
@@ -72,7 +82,7 @@
     virtual void setValue(RenderNode* target, float value) = 0;
     RenderNode* target() { return mTarget; }
 
-    void callOnFinishedListener(TreeInfo& info);
+    void callOnFinishedListener(AnimationContext& context);
 
     virtual void onStagingPlayStateChanged() {}
 
@@ -95,12 +105,13 @@
     nsecs_t mStartTime;
     nsecs_t mDuration;
     nsecs_t mStartDelay;
+    bool mMayRunAsync;
 
     sp<AnimationListener> mListener;
 
 private:
     inline void checkMutable();
-    virtual void transitionToRunning(TreeInfo& info);
+    virtual void transitionToRunning(AnimationContext& context);
     void doSetStartValue(float value);
 };
 
diff --git a/libs/hwui/AnimatorManager.cpp b/libs/hwui/AnimatorManager.cpp
index 7221295a4..c28fb88 100644
--- a/libs/hwui/AnimatorManager.cpp
+++ b/libs/hwui/AnimatorManager.cpp
@@ -17,6 +17,7 @@
 
 #include <algorithm>
 
+#include "AnimationContext.h"
 #include "RenderNode.h"
 
 namespace android {
@@ -30,7 +31,8 @@
 }
 
 AnimatorManager::AnimatorManager(RenderNode& parent)
-        : mParent(parent) {
+        : mParent(parent)
+        , mAnimationHandle(NULL) {
 }
 
 AnimatorManager::~AnimatorManager() {
@@ -44,6 +46,14 @@
     mNewAnimators.push_back(animator.get());
 }
 
+void AnimatorManager::setAnimationHandle(AnimationHandle* handle) {
+    LOG_ALWAYS_FATAL_IF(mAnimationHandle && handle, "Already have an AnimationHandle!");
+    mAnimationHandle = handle;
+    LOG_ALWAYS_FATAL_IF(!mAnimationHandle && mAnimators.size(),
+            "Lost animation handle on %p (%s) with outstanding animators!",
+            &mParent, mParent.getName());
+}
+
 template<typename T>
 static void move_all(T& source, T& dest) {
     dest.reserve(source.size() + dest.size());
@@ -53,26 +63,36 @@
     source.clear();
 }
 
-void AnimatorManager::pushStaging(TreeInfo& info) {
+void AnimatorManager::pushStaging() {
     if (mNewAnimators.size()) {
+        LOG_ALWAYS_FATAL_IF(!mAnimationHandle,
+                "Trying to start new animators on %p (%s) without an animation handle!",
+                &mParent, mParent.getName());
         // Since this is a straight move, we don't need to inc/dec the ref count
         move_all(mNewAnimators, mAnimators);
     }
     for (vector<BaseRenderNodeAnimator*>::iterator it = mAnimators.begin(); it != mAnimators.end(); it++) {
-        (*it)->pushStaging(info);
+        (*it)->pushStaging(mAnimationHandle->context());
     }
 }
 
 class AnimateFunctor {
 public:
-    AnimateFunctor(RenderNode& target, TreeInfo& info)
-            : dirtyMask(0), mTarget(target), mInfo(info) {}
+    AnimateFunctor(TreeInfo& info, AnimationContext& context)
+            : dirtyMask(0), mInfo(info), mContext(context) {}
 
     bool operator() (BaseRenderNodeAnimator* animator) {
         dirtyMask |= animator->dirtyMask();
-        bool remove = animator->animate(mInfo);
+        bool remove = animator->animate(mContext);
         if (remove) {
             animator->decStrong(0);
+        } else {
+            if (animator->isRunning()) {
+                mInfo.out.hasAnimations = true;
+            }
+            if (CC_UNLIKELY(!animator->mayRunAsync())) {
+                mInfo.out.requiresUiRedraw = true;
+            }
         }
         return remove;
     }
@@ -80,8 +100,8 @@
     uint32_t dirtyMask;
 
 private:
-    RenderNode& mTarget;
     TreeInfo& mInfo;
+    AnimationContext& mContext;
 };
 
 uint32_t AnimatorManager::animate(TreeInfo& info) {
@@ -93,17 +113,67 @@
     mParent.damageSelf(info);
     info.damageAccumulator->popTransform();
 
-    AnimateFunctor functor(mParent, info);
-    std::vector< BaseRenderNodeAnimator* >::iterator newEnd;
-    newEnd = std::remove_if(mAnimators.begin(), mAnimators.end(), functor);
-    mAnimators.erase(newEnd, mAnimators.end());
+    uint32_t dirty = animateCommon(info);
 
     mParent.mProperties.updateMatrix();
     info.damageAccumulator->pushTransform(&mParent);
     mParent.damageSelf(info);
 
+    return dirty;
+}
+
+void AnimatorManager::animateNoDamage(TreeInfo& info) {
+    if (!mAnimators.size()) return;
+
+    animateCommon(info);
+}
+
+uint32_t AnimatorManager::animateCommon(TreeInfo& info) {
+    AnimateFunctor functor(info, mAnimationHandle->context());
+    std::vector< BaseRenderNodeAnimator* >::iterator newEnd;
+    newEnd = std::remove_if(mAnimators.begin(), mAnimators.end(), functor);
+    mAnimators.erase(newEnd, mAnimators.end());
+    mAnimationHandle->notifyAnimationsRan();
     return functor.dirtyMask;
 }
 
+static void endStagingAnimator(BaseRenderNodeAnimator* animator) {
+    animator->end();
+    if (animator->listener()) {
+        animator->listener()->onAnimationFinished(animator);
+    }
+    animator->decStrong(0);
+}
+
+void AnimatorManager::endAllStagingAnimators() {
+    ALOGD("endAllStagingAnimators on %p (%s)", &mParent, mParent.getName());
+    // This works because this state can only happen on the UI thread,
+    // which means we're already on the right thread to invoke listeners
+    for_each(mNewAnimators.begin(), mNewAnimators.end(), endStagingAnimator);
+    mNewAnimators.clear();
+}
+
+class EndActiveAnimatorsFunctor {
+public:
+    EndActiveAnimatorsFunctor(AnimationContext& context) : mContext(context) {}
+
+    void operator() (BaseRenderNodeAnimator* animator) {
+        animator->forceEndNow(mContext);
+        animator->decStrong(0);
+    }
+
+private:
+    AnimationContext& mContext;
+};
+
+void AnimatorManager::endAllActiveAnimators() {
+    ALOGD("endAllStagingAnimators on %p (%s) with handle %p",
+            &mParent, mParent.getName(), mAnimationHandle);
+    EndActiveAnimatorsFunctor functor(mAnimationHandle->context());
+    for_each(mAnimators.begin(), mAnimators.end(), functor);
+    mAnimators.clear();
+    mAnimationHandle->release();
+}
+
 } /* namespace uirenderer */
 } /* namespace android */
diff --git a/libs/hwui/AnimatorManager.h b/libs/hwui/AnimatorManager.h
index 0d177c5..d03d427 100644
--- a/libs/hwui/AnimatorManager.h
+++ b/libs/hwui/AnimatorManager.h
@@ -27,6 +27,7 @@
 namespace android {
 namespace uirenderer {
 
+class AnimationHandle;
 class BaseRenderNodeAnimator;
 class RenderNode;
 
@@ -39,12 +40,30 @@
 
     void addAnimator(const sp<BaseRenderNodeAnimator>& animator);
 
-    void pushStaging(TreeInfo& info);
+    void setAnimationHandle(AnimationHandle* handle);
+    bool hasAnimationHandle() { return mAnimationHandle; }
+
+    void pushStaging();
+
     // Returns the combined dirty mask of all animators run
     uint32_t animate(TreeInfo& info);
 
+    void animateNoDamage(TreeInfo& info);
+
+    // Hard-ends all animators. May only be called on the UI thread.
+    ANDROID_API void endAllStagingAnimators();
+
+    // Hard-ends all animators that have been pushed. Used for cleanup if
+    // the ActivityContext is being destroyed
+    void endAllActiveAnimators();
+
+    bool hasAnimators() { return mAnimators.size(); }
+
 private:
+    uint32_t animateCommon(TreeInfo& info);
+
     RenderNode& mParent;
+    AnimationHandle* mAnimationHandle;
 
     // To improve the efficiency of resizing & removing from the vector
     // use manual ref counting instead of sp<>.
diff --git a/libs/hwui/Caches.cpp b/libs/hwui/Caches.cpp
index 5689e17..9b0025f 100644
--- a/libs/hwui/Caches.cpp
+++ b/libs/hwui/Caches.cpp
@@ -24,6 +24,7 @@
 #include "Properties.h"
 #include "LayerRenderer.h"
 #include "ShadowTessellator.h"
+#include "RenderState.h"
 
 namespace android {
 
@@ -49,7 +50,7 @@
 ///////////////////////////////////////////////////////////////////////////////
 
 Caches::Caches(): Singleton<Caches>(),
-        mExtensions(Extensions::getInstance()), mInitialized(false) {
+        mExtensions(Extensions::getInstance()), mInitialized(false), mRenderState(NULL) {
     init();
     initFont();
     initConstraints();
@@ -267,8 +268,11 @@
     log.appendFormat("Current memory usage / total memory usage (bytes):\n");
     log.appendFormat("  TextureCache         %8d / %8d\n",
             textureCache.getSize(), textureCache.getMaxSize());
-    log.appendFormat("  LayerCache           %8d / %8d\n",
-            layerCache.getSize(), layerCache.getMaxSize());
+    log.appendFormat("  LayerCache           %8d / %8d (numLayers = %zu)\n",
+            layerCache.getSize(), layerCache.getMaxSize(), layerCache.getCount());
+    log.appendFormat("  Garbage layers       %8zu\n", mLayerGarbage.size());
+    log.appendFormat("  Active layers        %8zu\n",
+            mRenderState ? mRenderState->mActiveLayers.size() : 0);
     log.appendFormat("  RenderBufferCache    %8d / %8d\n",
             renderBufferCache.getSize(), renderBufferCache.getMaxSize());
     log.appendFormat("  GradientCache        %8d / %8d\n",
@@ -338,6 +342,7 @@
 
 void Caches::deleteLayerDeferred(Layer* layer) {
     Mutex::Autolock _l(mGarbageLock);
+    layer->state = Layer::kState_InGarbageList;
     mLayerGarbage.push(layer);
 }
 
@@ -547,9 +552,13 @@
 }
 
 void Caches::bindTexture(GLenum target, GLuint texture) {
-    if (mBoundTextures[mTextureUnit] != texture) {
+    if (target == GL_TEXTURE_2D) {
+        bindTexture(texture);
+    } else {
+        // GLConsumer directly calls glBindTexture() with
+        // target=GL_TEXTURE_EXTERNAL_OES, don't cache this target
+        // since the cached state could be stale
         glBindTexture(target, texture);
-        mBoundTextures[mTextureUnit] = texture;
     }
 }
 
diff --git a/libs/hwui/Caches.h b/libs/hwui/Caches.h
index 0482430..7aa628c 100644
--- a/libs/hwui/Caches.h
+++ b/libs/hwui/Caches.h
@@ -107,6 +107,7 @@
 ///////////////////////////////////////////////////////////////////////////////
 
 class RenderNode;
+class RenderState;
 
 class ANDROID_API Caches: public Singleton<Caches> {
     Caches();
@@ -132,6 +133,8 @@
      */
     bool initProperties();
 
+    void setRenderState(RenderState* renderState) { mRenderState = renderState; }
+
     /**
      * Flush the cache.
      *
@@ -428,9 +431,12 @@
 
     uint32_t mFunctorsCount;
 
+    // Caches texture bindings for the GL_TEXTURE_2D target
     GLuint mBoundTextures[REQUIRED_TEXTURE_UNITS_COUNT];
 
     OverdrawColorSet mOverdrawDebugColorSet;
+
+    RenderState* mRenderState;
 }; // class Caches
 
 }; // namespace uirenderer
diff --git a/libs/hwui/DamageAccumulator.cpp b/libs/hwui/DamageAccumulator.cpp
index 054a164..420e331 100644
--- a/libs/hwui/DamageAccumulator.cpp
+++ b/libs/hwui/DamageAccumulator.cpp
@@ -214,7 +214,7 @@
     mHead->pendingDirty.join(left, top, right, bottom);
 }
 
-void DamageAccumulator::peekAtDirty(SkRect* dest) {
+void DamageAccumulator::peekAtDirty(SkRect* dest) const {
     *dest = mHead->pendingDirty;
 }
 
diff --git a/libs/hwui/DamageAccumulator.h b/libs/hwui/DamageAccumulator.h
index 6f0bd8c..dd3365a 100644
--- a/libs/hwui/DamageAccumulator.h
+++ b/libs/hwui/DamageAccumulator.h
@@ -50,7 +50,7 @@
     void dirty(float left, float top, float right, float bottom);
 
     // Returns the current dirty area, *NOT* transformed by pushed transforms
-    void peekAtDirty(SkRect* dest);
+    void peekAtDirty(SkRect* dest) const;
 
     void computeCurrentTransform(Matrix4* outMatrix) const;
 
diff --git a/libs/hwui/DisplayList.cpp b/libs/hwui/DisplayList.cpp
index 6461ee7..d8932ce 100644
--- a/libs/hwui/DisplayList.cpp
+++ b/libs/hwui/DisplayList.cpp
@@ -89,11 +89,9 @@
     layers.clear();
 }
 
-void DisplayListData::addChild(DrawRenderNodeOp* op) {
-    LOG_ALWAYS_FATAL_IF(!op->renderNode(), "DrawRenderNodeOp with no render node!");
-
-    mChildren.push(op);
+size_t DisplayListData::addChild(DrawRenderNodeOp* op) {
     mReferenceHolders.push(op->renderNode());
+    return mChildren.add(op);
 }
 
 }; // namespace uirenderer
diff --git a/libs/hwui/DisplayList.h b/libs/hwui/DisplayList.h
index acfa98e..dea109c 100644
--- a/libs/hwui/DisplayList.h
+++ b/libs/hwui/DisplayList.h
@@ -115,13 +115,24 @@
  * Data structure that holds the list of commands used in display list stream
  */
 class DisplayListData {
+    friend class DisplayListRenderer;
 public:
+    struct Chunk {
+        // range of included ops in DLD::displayListOps
+        size_t beginOpIndex;
+        size_t endOpIndex;
+
+        // range of included children in DLD::mChildren
+        size_t beginChildIndex;
+        size_t endChildIndex;
+
+        // whether children with non-zero Z in the chunk should be reordered
+        bool reorderChildren;
+    };
+
     DisplayListData();
     ~DisplayListData();
 
-    // allocator into which all ops were allocated
-    LinearAllocator allocator;
-
     // pointers to all ops within display list, pointing into allocator data
     Vector<DisplayListOp*> displayListOps;
 
@@ -138,13 +149,12 @@
     Vector<const SkRegion*> regions;
     Vector<Layer*> layers;
     Vector<Functor*> functors;
-    bool hasDrawOps;
 
-    bool isEmpty() {
-        return !displayListOps.size();
+    const Vector<Chunk>& getChunks() const {
+        return chunks;
     }
 
-    void addChild(DrawRenderNodeOp* childOp);
+    size_t addChild(DrawRenderNodeOp* childOp);
     const Vector<DrawRenderNodeOp*>& children() { return mChildren; }
 
     void refProperty(CanvasPropertyPrimitive* prop) {
@@ -155,12 +165,25 @@
         mReferenceHolders.push(prop);
     }
 
+    size_t getUsedSize() {
+        return allocator.usedSize();
+    }
+    bool isEmpty() {
+        return !hasDrawOps;
+    }
+
 private:
     Vector< sp<VirtualLightRefBase> > mReferenceHolders;
 
     // list of children display lists for quick, non-drawing traversal
     Vector<DrawRenderNodeOp*> mChildren;
 
+    Vector<Chunk> chunks;
+
+    // allocator into which all ops were allocated
+    LinearAllocator allocator;
+    bool hasDrawOps;
+
     void cleanupResources();
 };
 
diff --git a/libs/hwui/DisplayListOp.h b/libs/hwui/DisplayListOp.h
index c6d3db7..cb3ef9b 100644
--- a/libs/hwui/DisplayListOp.h
+++ b/libs/hwui/DisplayListOp.h
@@ -208,6 +208,8 @@
         // ensure that local bounds cover mapped bounds
         if (!state.mMatrix.isSimple()) return false;
 
+        if (state.mRoundRectClipState) return false;
+
         // check state/paint for transparency
         if (mPaint) {
             if (mPaint->getShader() && !mPaint->getShader()->isOpaque()) {
@@ -999,6 +1001,8 @@
 public:
     DrawStrokableOp(float left, float top, float right, float bottom, const SkPaint* paint)
             : DrawBoundedOp(left, top, right, bottom, paint) {};
+    DrawStrokableOp(const Rect& localBounds, const SkPaint* paint)
+            : DrawBoundedOp(localBounds, paint) {};
 
     virtual bool getLocalBounds(Rect& localBounds) {
         localBounds.set(mLocalBounds);
@@ -1101,6 +1105,34 @@
     float mRy;
 };
 
+class DrawRoundRectPropsOp : public DrawOp {
+public:
+    DrawRoundRectPropsOp(float* left, float* top, float* right, float* bottom,
+            float *rx, float *ry, const SkPaint* paint)
+            : DrawOp(paint), mLeft(left), mTop(top), mRight(right), mBottom(bottom),
+            mRx(rx), mRy(ry) {}
+
+    virtual status_t applyDraw(OpenGLRenderer& renderer, Rect& dirty) {
+        return renderer.drawRoundRect(*mLeft, *mTop, *mRight, *mBottom,
+                *mRx, *mRy, getPaint(renderer));
+    }
+
+    virtual void output(int level, uint32_t logFlags) const {
+        OP_LOG("Draw RoundRect Props " RECT_STRING ", rx %f, ry %f",
+                *mLeft, *mTop, *mRight, *mBottom, *mRx, *mRy);
+    }
+
+    virtual const char* name() { return "DrawRoundRectProps"; }
+
+private:
+    float* mLeft;
+    float* mTop;
+    float* mRight;
+    float* mBottom;
+    float* mRx;
+    float* mRy;
+};
+
 class DrawCircleOp : public DrawStrokableOp {
 public:
     DrawCircleOp(float x, float y, float radius, const SkPaint* paint)
@@ -1337,11 +1369,11 @@
     const float* mPositions;
 };
 
-class DrawTextOp : public DrawBoundedOp {
+class DrawTextOp : public DrawStrokableOp {
 public:
     DrawTextOp(const char* text, int bytesCount, int count, float x, float y,
             const float* positions, const SkPaint* paint, float totalAdvance, const Rect& bounds)
-            : DrawBoundedOp(bounds, paint), mText(text), mBytesCount(bytesCount), mCount(count),
+            : DrawStrokableOp(bounds, paint), mText(text), mBytesCount(bytesCount), mCount(count),
             mX(x), mY(y), mPositions(positions), mTotalAdvance(totalAdvance) {
         mPrecacheTransform = SkMatrix::InvalidMatrix();
     }
@@ -1441,6 +1473,7 @@
 
 class DrawRenderNodeOp : public DrawBoundedOp {
     friend class RenderNode; // grant RenderNode access to info of child
+    friend class DisplayListData; // grant DisplayListData access to info of child
 public:
     DrawRenderNodeOp(RenderNode* renderNode, int flags, const mat4& transformFromParent)
             : DrawBoundedOp(0, 0, renderNode->getWidth(), renderNode->getHeight(), 0),
@@ -1448,13 +1481,14 @@
 
     virtual void defer(DeferStateStruct& deferStruct, int saveCount, int level,
             bool useQuickReject) {
-        if (mRenderNode && mRenderNode->isRenderable() && !mSkipInOrderDraw) {
+        if (mRenderNode->isRenderable() && !mSkipInOrderDraw) {
             mRenderNode->defer(deferStruct, level + 1);
         }
     }
+
     virtual void replay(ReplayStateStruct& replayStruct, int saveCount, int level,
             bool useQuickReject) {
-        if (mRenderNode && mRenderNode->isRenderable() && !mSkipInOrderDraw) {
+        if (mRenderNode->isRenderable() && !mSkipInOrderDraw) {
             mRenderNode->replay(replayStruct, level + 1);
         }
     }
@@ -1465,7 +1499,7 @@
     }
 
     virtual void output(int level, uint32_t logFlags) const {
-        OP_LOG("Draw Display List %p, flags %#x", mRenderNode, mFlags);
+        OP_LOG("Draw RenderNode %p %s, flags %#x", mRenderNode, mRenderNode->getName(), mFlags);
         if (mRenderNode && (logFlags & kOpLogFlag_Recurse)) {
             mRenderNode->output(level + 1);
         }
@@ -1522,8 +1556,7 @@
 
     virtual status_t applyDraw(OpenGLRenderer& renderer, Rect& dirty) {
         TessellationCache::vertexBuffer_pair_t buffers;
-        Matrix4 drawTransform;
-        renderer.getMatrix(&drawTransform);
+        Matrix4 drawTransform(*(renderer.currentTransform()));
         renderer.getCaches().tessellationCache.getShadowBuffers(&drawTransform,
                 renderer.getLocalClipBounds(), isCasterOpaque(), mCasterOutline,
                 &mTransformXY, &mTransformZ, renderer.getLightCenter(), renderer.getLightRadius(),
diff --git a/libs/hwui/DisplayListRenderer.cpp b/libs/hwui/DisplayListRenderer.cpp
index 94162fc..1f70921 100644
--- a/libs/hwui/DisplayListRenderer.cpp
+++ b/libs/hwui/DisplayListRenderer.cpp
@@ -33,10 +33,10 @@
 
 DisplayListRenderer::DisplayListRenderer()
     : mCaches(Caches::getInstance())
-    , mDisplayListData(0)
+    , mDisplayListData(NULL)
     , mTranslateX(0.0f)
     , mTranslateY(0.0f)
-    , mHasTranslate(false)
+    , mDeferredBarrierType(kBarrier_None)
     , mHighContrastText(false)
     , mRestoreSaveCount(-1) {
 }
@@ -68,6 +68,7 @@
 
     initializeSaveStack(0, 0, getWidth(), getHeight(), Vector3());
 
+    mDeferredBarrierType = kBarrier_InOrder;
     mDirtyClip = opaque;
     mRestoreSaveCount = -1;
 
@@ -75,8 +76,8 @@
 }
 
 void DisplayListRenderer::finish() {
-    insertRestoreToCount();
-    insertTranslate();
+    flushRestoreToCount();
+    flushTranslate();
 }
 
 void DisplayListRenderer::interrupt() {
@@ -104,18 +105,21 @@
     }
 
     mRestoreSaveCount--;
-    insertTranslate();
+    flushTranslate();
     StatefulBaseRenderer::restore();
 }
 
 void DisplayListRenderer::restoreToCount(int saveCount) {
     mRestoreSaveCount = saveCount;
-    insertTranslate();
+    flushTranslate();
     StatefulBaseRenderer::restoreToCount(saveCount);
 }
 
 int DisplayListRenderer::saveLayer(float left, float top, float right, float bottom,
         const SkPaint* paint, int flags) {
+    // force matrix/clip isolation for layer
+    flags |= SkCanvas::kClip_SaveFlag | SkCanvas::kMatrix_SaveFlag;
+
     paint = refPaint(paint);
     addStateOp(new (alloc()) SaveLayerOp(left, top, right, bottom, paint, flags));
     return StatefulBaseRenderer::save(flags);
@@ -123,10 +127,10 @@
 
 void DisplayListRenderer::translate(float dx, float dy, float dz) {
     // ignore dz, not used at defer time
-    mHasTranslate = true;
+    mHasDeferredTranslate = true;
     mTranslateX += dx;
     mTranslateY += dy;
-    insertRestoreToCount();
+    flushRestoreToCount();
     StatefulBaseRenderer::translate(dx, dy, dz);
 }
 
@@ -174,16 +178,12 @@
 }
 
 status_t DisplayListRenderer::drawRenderNode(RenderNode* renderNode, Rect& dirty, int32_t flags) {
+    LOG_ALWAYS_FATAL_IF(!renderNode, "missing rendernode");
+
     // dirty is an out parameter and should not be recorded,
     // it matters only when replaying the display list
     DrawRenderNodeOp* op = new (alloc()) DrawRenderNodeOp(renderNode, flags, *currentTransform());
-    int opIndex = addDrawOp(op);
-    mDisplayListData->addChild(op);
-
-    if (renderNode->stagingProperties().isProjectionReceiver()) {
-        // use staging property, since recording on UI thread
-        mDisplayListData->projectionReceiveIndex = opIndex;
-    }
+    addRenderNodeOp(op);
 
     return DrawGlInfo::kStatusDone;
 }
@@ -275,6 +275,23 @@
     return DrawGlInfo::kStatusDone;
 }
 
+status_t DisplayListRenderer::drawRoundRect(
+        CanvasPropertyPrimitive* left, CanvasPropertyPrimitive* top,
+        CanvasPropertyPrimitive* right, CanvasPropertyPrimitive* bottom,
+        CanvasPropertyPrimitive* rx, CanvasPropertyPrimitive* ry,
+        CanvasPropertyPaint* paint) {
+    mDisplayListData->refProperty(left);
+    mDisplayListData->refProperty(top);
+    mDisplayListData->refProperty(right);
+    mDisplayListData->refProperty(bottom);
+    mDisplayListData->refProperty(rx);
+    mDisplayListData->refProperty(ry);
+    mDisplayListData->refProperty(paint);
+    addDrawOp(new (alloc()) DrawRoundRectPropsOp(&left->value, &top->value,
+            &right->value, &bottom->value, &rx->value, &ry->value, &paint->value));
+    return DrawGlInfo::kStatusDone;
+}
+
 status_t DisplayListRenderer::drawCircle(float x, float y, float radius, const SkPaint* paint) {
     paint = refPaint(paint);
     addDrawOp(new (alloc()) DrawCircleOp(x, y, radius, paint));
@@ -376,7 +393,7 @@
         float x, float y, const float* positions, const SkPaint* paint,
         float totalAdvance, const Rect& bounds, DrawOpMode drawOpMode) {
 
-    if (!text || count <= 0) return DrawGlInfo::kStatusDone;
+    if (!text || count <= 0 || paintWillNotDrawText(*paint)) return DrawGlInfo::kStatusDone;
 
     text = refText(text, bytesCount);
     positions = refBuffer<float>(positions, count * 2);
@@ -428,30 +445,60 @@
     addStateOp(new (alloc()) SetupPaintFilterOp(clearBits, setBits));
 }
 
-void DisplayListRenderer::insertRestoreToCount() {
+void DisplayListRenderer::insertReorderBarrier(bool enableReorder) {
+    flushRestoreToCount();
+    flushTranslate();
+    mDeferredBarrierType = enableReorder ? kBarrier_OutOfOrder : kBarrier_InOrder;
+}
+
+void DisplayListRenderer::flushRestoreToCount() {
     if (mRestoreSaveCount >= 0) {
-        DisplayListOp* op = new (alloc()) RestoreToCountOp(mRestoreSaveCount);
-        mDisplayListData->displayListOps.add(op);
+        addOpAndUpdateChunk(new (alloc()) RestoreToCountOp(mRestoreSaveCount));
         mRestoreSaveCount = -1;
     }
 }
 
-void DisplayListRenderer::insertTranslate() {
-    if (mHasTranslate) {
+void DisplayListRenderer::flushTranslate() {
+    if (mHasDeferredTranslate) {
         if (mTranslateX != 0.0f || mTranslateY != 0.0f) {
-            DisplayListOp* op = new (alloc()) TranslateOp(mTranslateX, mTranslateY);
-            mDisplayListData->displayListOps.add(op);
+            addOpAndUpdateChunk(new (alloc()) TranslateOp(mTranslateX, mTranslateY));
             mTranslateX = mTranslateY = 0.0f;
         }
-        mHasTranslate = false;
+        mHasDeferredTranslate = false;
     }
 }
 
-int DisplayListRenderer::addStateOp(StateOp* op) {
-    return addOpInternal(op);
+size_t DisplayListRenderer::addOpAndUpdateChunk(DisplayListOp* op) {
+    int insertIndex = mDisplayListData->displayListOps.add(op);
+    if (mDeferredBarrierType != kBarrier_None) {
+        // op is first in new chunk
+        mDisplayListData->chunks.push();
+        DisplayListData::Chunk& newChunk = mDisplayListData->chunks.editTop();
+        newChunk.beginOpIndex = insertIndex;
+        newChunk.endOpIndex = insertIndex + 1;
+        newChunk.reorderChildren = (mDeferredBarrierType == kBarrier_OutOfOrder);
+
+        int nextChildIndex = mDisplayListData->children().size();
+        newChunk.beginChildIndex = newChunk.endChildIndex = nextChildIndex;
+        mDeferredBarrierType = kBarrier_None;
+    } else {
+        // standard case - append to existing chunk
+        mDisplayListData->chunks.editTop().endOpIndex = insertIndex + 1;
+    }
+    return insertIndex;
 }
 
-int DisplayListRenderer::addDrawOp(DrawOp* op) {
+size_t DisplayListRenderer::flushAndAddOp(DisplayListOp* op) {
+    flushRestoreToCount();
+    flushTranslate();
+    return addOpAndUpdateChunk(op);
+}
+
+size_t DisplayListRenderer::addStateOp(StateOp* op) {
+    return flushAndAddOp(op);
+}
+
+size_t DisplayListRenderer::addDrawOp(DrawOp* op) {
     Rect localBounds;
     if (op->getLocalBounds(localBounds)) {
         bool rejected = quickRejectConservative(localBounds.left, localBounds.top,
@@ -460,7 +507,22 @@
     }
 
     mDisplayListData->hasDrawOps = true;
-    return addOpInternal(op);
+    return flushAndAddOp(op);
+}
+
+size_t DisplayListRenderer::addRenderNodeOp(DrawRenderNodeOp* op) {
+    int opIndex = addDrawOp(op);
+    int childIndex = mDisplayListData->addChild(op);
+
+    // update the chunk's child indices
+    DisplayListData::Chunk& chunk = mDisplayListData->chunks.editTop();
+    chunk.endChildIndex = childIndex + 1;
+
+    if (op->renderNode()->stagingProperties().isProjectionReceiver()) {
+        // use staging property, since recording on UI thread
+        mDisplayListData->projectionReceiveIndex = opIndex;
+    }
+    return opIndex;
 }
 
 }; // namespace uirenderer
diff --git a/libs/hwui/DisplayListRenderer.h b/libs/hwui/DisplayListRenderer.h
index b5c0159..3a3fc3a 100644
--- a/libs/hwui/DisplayListRenderer.h
+++ b/libs/hwui/DisplayListRenderer.h
@@ -57,6 +57,8 @@
     DisplayListRenderer();
     virtual ~DisplayListRenderer();
 
+    void insertReorderBarrier(bool enableReorder);
+
     DisplayListData* finishRecording();
 
 // ----------------------------------------------------------------------------
@@ -121,6 +123,10 @@
     virtual status_t drawRects(const float* rects, int count, const SkPaint* paint);
     virtual status_t drawRoundRect(float left, float top, float right, float bottom,
             float rx, float ry, const SkPaint* paint);
+    virtual status_t drawRoundRect(CanvasPropertyPrimitive* left, CanvasPropertyPrimitive* top,
+                CanvasPropertyPrimitive* right, CanvasPropertyPrimitive* bottom,
+                CanvasPropertyPrimitive* rx, CanvasPropertyPrimitive* ry,
+                CanvasPropertyPaint* paint);
     virtual status_t drawCircle(float x, float y, float radius, const SkPaint* paint);
     virtual status_t drawCircle(CanvasPropertyPrimitive* x, CanvasPropertyPrimitive* y,
                 CanvasPropertyPrimitive* radius, CanvasPropertyPaint* paint);
@@ -154,19 +160,27 @@
         mHighContrastText = highContrastText;
     }
 private:
-    void insertRestoreToCount();
-    void insertTranslate();
+    enum DeferredBarrierType {
+        kBarrier_None,
+        kBarrier_InOrder,
+        kBarrier_OutOfOrder,
+    };
+
+    void flushRestoreToCount();
+    void flushTranslate();
+    void flushReorderBarrier();
 
     LinearAllocator& alloc() { return mDisplayListData->allocator; }
 
     // Each method returns final index of op
-    int addStateOp(StateOp* op);
-    int addDrawOp(DrawOp* op);
-    int addOpInternal(DisplayListOp* op) {
-        insertRestoreToCount();
-        insertTranslate();
-        return mDisplayListData->displayListOps.add(op);
-    }
+    size_t addOpAndUpdateChunk(DisplayListOp* op);
+    // flushes any deferred operations, and appends the op
+    size_t flushAndAddOp(DisplayListOp* op);
+
+    size_t addStateOp(StateOp* op);
+    size_t addDrawOp(DrawOp* op);
+    size_t addRenderNodeOp(DrawRenderNodeOp* op);
+
 
     template<class T>
     inline const T* refBuffer(const T* srcBuffer, int32_t count) {
@@ -205,11 +219,17 @@
         if (!paint) return NULL;
 
         const SkPaint* paintCopy = mPaintMap.valueFor(paint);
-        if (paintCopy == NULL || paintCopy->getGenerationID() != paint->getGenerationID()) {
-            paintCopy = new SkPaint(*paint);
+        if (paintCopy == NULL
+                || paintCopy->getGenerationID() != paint->getGenerationID()
+                // We can't compare shader pointers because that will always
+                // change as we do partial copying via wrapping. However, if the
+                // shader changes the paint generationID will have changed and
+                // so we don't hit this comparison anyway
+                || !(paint->getShader() && paintCopy->getShader()
+                        && paint->getShader()->getGenerationID() == paintCopy->getShader()->getGenerationID())) {
+            paintCopy = copyPaint(paint);
             // replaceValueFor() performs an add if the entry doesn't exist
             mPaintMap.replaceValueFor(paint, paintCopy);
-            mDisplayListData->paints.add(paintCopy);
         }
 
         return paintCopy;
@@ -218,8 +238,15 @@
     inline SkPaint* copyPaint(const SkPaint* paint) {
         if (!paint) return NULL;
         SkPaint* paintCopy = new SkPaint(*paint);
+        if (paint->getShader()) {
+            SkShader* shaderCopy = SkShader::CreateLocalMatrixShader(
+                    paint->getShader(), paint->getShader()->getLocalMatrix());
+            paintCopy->setShader(shaderCopy);
+            paintCopy->setGenerationID(paint->getGenerationID());
+            shaderCopy->setGenerationID(paint->getShader()->getGenerationID());
+            shaderCopy->unref();
+        }
         mDisplayListData->paints.add(paintCopy);
-
         return paintCopy;
     }
 
@@ -277,7 +304,8 @@
 
     float mTranslateX;
     float mTranslateY;
-    bool mHasTranslate;
+    bool mHasDeferredTranslate;
+    DeferredBarrierType mDeferredBarrierType;
     bool mHighContrastText;
 
     int mRestoreSaveCount;
diff --git a/libs/hwui/IContextFactory.h b/libs/hwui/IContextFactory.h
new file mode 100644
index 0000000..463b55e
--- /dev/null
+++ b/libs/hwui/IContextFactory.h
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+#ifndef CONTEXTFACTORY_H_
+#define CONTEXTFACTORY_H_
+
+namespace android {
+namespace uirenderer {
+
+namespace renderthread {
+class TimeLord;
+}
+
+class AnimationContext;
+
+class IContextFactory {
+public:
+    virtual AnimationContext* createAnimationContext(renderthread::TimeLord& clock) = 0;
+
+protected:
+    virtual ~IContextFactory() {}
+};
+
+} /* namespace uirenderer */
+} /* namespace android */
+
+#endif /* CONTEXTFACTORY_H_ */
diff --git a/libs/hwui/Interpolator.cpp b/libs/hwui/Interpolator.cpp
index fc0e8a0..ff8ff73 100644
--- a/libs/hwui/Interpolator.cpp
+++ b/libs/hwui/Interpolator.cpp
@@ -110,7 +110,7 @@
     weight = modff(lutpos, &ipart);
 
     int i1 = (int) ipart;
-    int i2 = MathUtils::min(i1 + 1, mSize - 1);
+    int i2 = MathUtils::min(i1 + 1, (int) mSize - 1);
 
     LOG_ALWAYS_FATAL_IF(i1 < 0 || i2 < 0, "negatives in interpolation!"
             " i1=%d, i2=%d, input=%f, lutpos=%f, size=%zu, values=%p, ipart=%f, weight=%f",
diff --git a/libs/hwui/Layer.cpp b/libs/hwui/Layer.cpp
index 8639ae1..b5089aa 100644
--- a/libs/hwui/Layer.cpp
+++ b/libs/hwui/Layer.cpp
@@ -29,15 +29,16 @@
 namespace android {
 namespace uirenderer {
 
-Layer::Layer(RenderState& renderState, const uint32_t layerWidth, const uint32_t layerHeight)
-        : caches(Caches::getInstance())
+Layer::Layer(Type layerType, RenderState& renderState, const uint32_t layerWidth, const uint32_t layerHeight)
+        : state(kState_Uncached)
+        , caches(Caches::getInstance())
         , renderState(renderState)
-        , texture(caches) {
+        , texture(caches)
+        , type(layerType) {
     mesh = NULL;
     meshElementCount = 0;
     cacheable = true;
     dirty = false;
-    textureLayer = false;
     renderTarget = GL_TEXTURE_2D;
     texture.width = layerWidth;
     texture.height = layerHeight;
@@ -54,9 +55,18 @@
     convexMask = NULL;
     caches.resourceCache.incrementRefcount(this);
     rendererLightPosDirty = true;
+    wasBuildLayered = false;
+    if (!isTextureLayer()) {
+        // track only non-texture layer lifecycles in renderstate,
+        // because texture layers are destroyed via finalizer
+        renderState.registerLayer(this);
+    }
 }
 
 Layer::~Layer() {
+    if (!isTextureLayer()) {
+        renderState.unregisterLayer(this);
+    }
     SkSafeUnref(colorFilter);
     removeFbo();
     deleteTexture();
diff --git a/libs/hwui/Layer.h b/libs/hwui/Layer.h
index 38c29c7..a8e1c26 100644
--- a/libs/hwui/Layer.h
+++ b/libs/hwui/Layer.h
@@ -54,7 +54,23 @@
  */
 class Layer {
 public:
-    Layer(RenderState& renderState, const uint32_t layerWidth, const uint32_t layerHeight);
+    enum Type {
+        kType_Texture,
+        kType_DisplayList,
+    };
+
+    // layer lifecycle, controlled from outside
+    enum State {
+        kState_Uncached = 0,
+        kState_InCache = 1,
+        kState_FailedToCache = 2,
+        kState_RemovedFromCache = 3,
+        kState_DeletedFromCache = 4,
+        kState_InGarbageList = 5,
+    };
+    State state; // public for logging/debugging purposes
+
+    Layer(Type type, RenderState& renderState, const uint32_t layerWidth, const uint32_t layerHeight);
     ~Layer();
 
     static uint32_t computeIdealWidth(uint32_t layerWidth);
@@ -219,11 +235,7 @@
     }
 
     inline bool isTextureLayer() const {
-        return textureLayer;
-    }
-
-    inline void setTextureLayer(bool textureLayer) {
-        this->textureLayer = textureLayer;
+        return type == kType_Texture;
     }
 
     inline SkColorFilter* getColorFilter() const {
@@ -306,6 +318,7 @@
     Rect dirtyRect;
     bool debugDrawUpdate;
     bool hasDrawnSinceUpdate;
+    bool wasBuildLayered;
 
 private:
     void requireRenderer();
@@ -342,10 +355,9 @@
     bool cacheable;
 
     /**
-     * When set to true, this layer must be treated as a texture
-     * layer.
+     * Denotes whether the layer is a DisplayList, or Texture layer.
      */
-    bool textureLayer;
+    const Type type;
 
     /**
      * When set to true, this layer is dirty and should be cleared
diff --git a/libs/hwui/LayerCache.cpp b/libs/hwui/LayerCache.cpp
index 13869aa..833f64b 100644
--- a/libs/hwui/LayerCache.cpp
+++ b/libs/hwui/LayerCache.cpp
@@ -49,6 +49,10 @@
 // Size management
 ///////////////////////////////////////////////////////////////////////////////
 
+size_t LayerCache::getCount() {
+    return mCache.size();
+}
+
 uint32_t LayerCache::getSize() {
     return mSize;
 }
@@ -79,6 +83,7 @@
         LAYER_LOGD("Destroying layer %dx%d, fbo %d", layer->getWidth(), layer->getHeight(),
                 layer->getFbo());
         mSize -= layer->getWidth() * layer->getHeight() * 4;
+        layer->state = Layer::kState_DeletedFromCache;
         Caches::getInstance().resourceCache.decrementRefcount(layer);
     }
 }
@@ -102,13 +107,14 @@
         mCache.removeAt(index);
 
         layer = entry.mLayer;
+        layer->state = Layer::kState_RemovedFromCache;
         mSize -= layer->getWidth() * layer->getHeight() * 4;
 
         LAYER_LOGD("Reusing layer %dx%d", layer->getWidth(), layer->getHeight());
     } else {
         LAYER_LOGD("Creating new layer %dx%d", entry.mWidth, entry.mHeight);
 
-        layer = new Layer(renderState, entry.mWidth, entry.mHeight);
+        layer = new Layer(Layer::kType_DisplayList, renderState, entry.mWidth, entry.mHeight);
         layer->setBlend(true);
         layer->setEmpty(true);
         layer->setFbo(0);
@@ -162,8 +168,11 @@
         mCache.add(entry);
         mSize += size;
 
+        layer->state = Layer::kState_InCache;
         return true;
     }
+
+    layer->state = Layer::kState_FailedToCache;
     return false;
 }
 
diff --git a/libs/hwui/LayerCache.h b/libs/hwui/LayerCache.h
index 1b0fc2c..6b93e8f 100644
--- a/libs/hwui/LayerCache.h
+++ b/libs/hwui/LayerCache.h
@@ -87,6 +87,8 @@
      */
     uint32_t getSize();
 
+    size_t getCount();
+
     /**
      * Prints out the content of the cache.
      */
diff --git a/libs/hwui/LayerRenderer.cpp b/libs/hwui/LayerRenderer.cpp
index e3b0daf..103c843 100644
--- a/libs/hwui/LayerRenderer.cpp
+++ b/libs/hwui/LayerRenderer.cpp
@@ -272,9 +272,8 @@
 Layer* LayerRenderer::createTextureLayer(RenderState& renderState) {
     LAYER_RENDERER_LOGD("Creating new texture layer");
 
-    Layer* layer = new Layer(renderState, 0, 0);
+    Layer* layer = new Layer(Layer::kType_Texture, renderState, 0, 0);
     layer->setCacheable(false);
-    layer->setTextureLayer(true);
     layer->setEmpty(true);
     layer->setFbo(0);
     layer->setAlpha(255, SkXfermode::kSrcOver_Mode);
diff --git a/libs/hwui/OpenGLRenderer.cpp b/libs/hwui/OpenGLRenderer.cpp
index 721ab3d..25ea729 100755
--- a/libs/hwui/OpenGLRenderer.cpp
+++ b/libs/hwui/OpenGLRenderer.cpp
@@ -54,10 +54,6 @@
 namespace android {
 namespace uirenderer {
 
-///////////////////////////////////////////////////////////////////////////////
-// Defines
-///////////////////////////////////////////////////////////////////////////////
-
 static GLenum getFilter(const SkPaint* paint) {
     if (!paint || paint->getFilterLevel() != SkPaint::kNone_FilterLevel) {
         return GL_LINEAR;
@@ -605,6 +601,12 @@
     AutoFence fence;
 }
 
+void OpenGLRenderer::markLayersAsBuildLayers() {
+    for (size_t i = 0; i < mLayerUpdates.size(); i++) {
+        mLayerUpdates[i]->wasBuildLayered = true;
+    }
+}
+
 ///////////////////////////////////////////////////////////////////////////////
 // State management
 ///////////////////////////////////////////////////////////////////////////////
@@ -636,6 +638,9 @@
 
 int OpenGLRenderer::saveLayer(float left, float top, float right, float bottom,
         const SkPaint* paint, int flags, const SkPath* convexMask) {
+    // force matrix/clip isolation for layer
+    flags |= SkCanvas::kClip_SaveFlag | SkCanvas::kMatrix_SaveFlag;
+
     const int count = saveSnapshot(flags);
 
     if (!currentSnapshot()->isIgnored()) {
@@ -1742,10 +1747,13 @@
         glUniform4f(mCaches.currentProgram->getUniform("roundRectInnerRectLTRB"),
                 innerRect.left, innerRect.top,
                 innerRect.right, innerRect.bottom);
-        glUniform1f(mCaches.currentProgram->getUniform("roundRectRadius"),
-                state->radius);
         glUniformMatrix4fv(mCaches.currentProgram->getUniform("roundRectInvTransform"),
                 1, GL_FALSE, &state->matrix.data[0]);
+
+        // add half pixel to round out integer rect space to cover pixel centers
+        float roundedOutRadius = state->radius + 0.5f;
+        glUniform1f(mCaches.currentProgram->getUniform("roundRectRadius"),
+                roundedOutRadius);
     }
 }
 
@@ -2417,6 +2425,10 @@
     } else if (mode == VertexBuffer::kTwoPolyRingShadow) {
         mCaches.bindShadowIndicesBuffer();
         glDrawElements(GL_TRIANGLE_STRIP, TWO_POLY_RING_SHADOW_INDEX_COUNT, GL_UNSIGNED_SHORT, 0);
+    } else if (mode == VertexBuffer::kIndices) {
+        mCaches.unbindIndicesBuffer();
+        glDrawElements(GL_TRIANGLE_STRIP, vertexBuffer.getIndexCount(), GL_UNSIGNED_SHORT,
+                vertexBuffer.getIndices());
     }
 
     if (isAA) {
@@ -2518,8 +2530,9 @@
 
 status_t OpenGLRenderer::drawRoundRect(float left, float top, float right, float bottom,
         float rx, float ry, const SkPaint* p) {
-    if (currentSnapshot()->isIgnored() || quickRejectSetupScissor(left, top, right, bottom, p) ||
-            (p->getAlpha() == 0 && getXfermode(p->getXfermode()) != SkXfermode::kClear_Mode)) {
+    if (currentSnapshot()->isIgnored()
+            || quickRejectSetupScissor(left, top, right, bottom, p)
+            || paintWillNotDraw(*p)) {
         return DrawGlInfo::kStatusDone;
     }
 
@@ -2536,9 +2549,9 @@
 }
 
 status_t OpenGLRenderer::drawCircle(float x, float y, float radius, const SkPaint* p) {
-    if (currentSnapshot()->isIgnored() || quickRejectSetupScissor(x - radius, y - radius,
-            x + radius, y + radius, p) ||
-            (p->getAlpha() == 0 && getXfermode(p->getXfermode()) != SkXfermode::kClear_Mode)) {
+    if (currentSnapshot()->isIgnored()
+            || quickRejectSetupScissor(x - radius, y - radius, x + radius, y + radius, p)
+            || paintWillNotDraw(*p)) {
         return DrawGlInfo::kStatusDone;
     }
     if (p->getPathEffect() != 0) {
@@ -2558,8 +2571,9 @@
 
 status_t OpenGLRenderer::drawOval(float left, float top, float right, float bottom,
         const SkPaint* p) {
-    if (currentSnapshot()->isIgnored() || quickRejectSetupScissor(left, top, right, bottom, p) ||
-            (p->getAlpha() == 0 && getXfermode(p->getXfermode()) != SkXfermode::kClear_Mode)) {
+    if (currentSnapshot()->isIgnored()
+            || quickRejectSetupScissor(left, top, right, bottom, p)
+            || paintWillNotDraw(*p)) {
         return DrawGlInfo::kStatusDone;
     }
 
@@ -2580,8 +2594,9 @@
 
 status_t OpenGLRenderer::drawArc(float left, float top, float right, float bottom,
         float startAngle, float sweepAngle, bool useCenter, const SkPaint* p) {
-    if (currentSnapshot()->isIgnored() || quickRejectSetupScissor(left, top, right, bottom, p) ||
-            (p->getAlpha() == 0 && getXfermode(p->getXfermode()) != SkXfermode::kClear_Mode)) {
+    if (currentSnapshot()->isIgnored()
+            || quickRejectSetupScissor(left, top, right, bottom, p)
+            || paintWillNotDraw(*p)) {
         return DrawGlInfo::kStatusDone;
     }
 
@@ -2614,8 +2629,9 @@
 
 status_t OpenGLRenderer::drawRect(float left, float top, float right, float bottom,
         const SkPaint* p) {
-    if (currentSnapshot()->isIgnored() || quickRejectSetupScissor(left, top, right, bottom, p) ||
-            (p->getAlpha() == 0 && getXfermode(p->getXfermode()) != SkXfermode::kClear_Mode)) {
+    if (currentSnapshot()->isIgnored()
+            || quickRejectSetupScissor(left, top, right, bottom, p)
+            || paintWillNotDraw(*p)) {
         return DrawGlInfo::kStatusDone;
     }
 
@@ -3030,21 +3046,35 @@
 }
 
 void OpenGLRenderer::setupPaintFilter(int clearBits, int setBits) {
+    // TODO: don't bother with boolean, it's redundant with clear/set bits
     mDrawModifiers.mHasDrawFilter = true;
     mDrawModifiers.mPaintFilterClearBits = clearBits & SkPaint::kAllFlags;
     mDrawModifiers.mPaintFilterSetBits = setBits & SkPaint::kAllFlags;
 }
 
 const SkPaint* OpenGLRenderer::filterPaint(const SkPaint* paint) {
+    // TODO: use CompatFlagsDrawFilter here, and combine logic with android/graphics/DrawFilter.cpp
+    // to avoid clobbering 0x02 paint flag
+
+    // Equivalent to the Java Paint's FILTER_BITMAP_FLAG.
+    static const uint32_t sFilterBitmapFlag = 0x02;
+
     if (CC_LIKELY(!mDrawModifiers.mHasDrawFilter || !paint)) {
         return paint;
     }
 
-    uint32_t flags = paint->getFlags();
+    const uint32_t clearBits = mDrawModifiers.mPaintFilterClearBits;
+    const uint32_t setBits = mDrawModifiers.mPaintFilterSetBits;
 
+    const uint32_t flags = (paint->getFlags() & ~clearBits) | setBits;
     mFilteredPaint = *paint;
-    mFilteredPaint.setFlags((flags & ~mDrawModifiers.mPaintFilterClearBits) |
-            mDrawModifiers.mPaintFilterSetBits);
+    mFilteredPaint.setFlags(flags);
+
+    // check if paint filter trying to override bitmap filter
+    if ((clearBits | setBits) & sFilterBitmapFlag) {
+        mFilteredPaint.setFilterLevel(flags & sFilterBitmapFlag
+                ? SkPaint::kLow_FilterLevel : SkPaint::kNone_FilterLevel);
+    }
 
     return &mFilteredPaint;
 }
diff --git a/libs/hwui/OpenGLRenderer.h b/libs/hwui/OpenGLRenderer.h
index e9ca5d9..e295b1a 100755
--- a/libs/hwui/OpenGLRenderer.h
+++ b/libs/hwui/OpenGLRenderer.h
@@ -150,6 +150,7 @@
     void cancelLayerUpdate(Layer* layer);
     void clearLayerUpdates();
     void flushLayerUpdates();
+    void markLayersAsBuildLayers();
 
     virtual int saveLayer(float left, float top, float right, float bottom,
             const SkPaint* paint, int flags) {
diff --git a/libs/hwui/PathTessellator.cpp b/libs/hwui/PathTessellator.cpp
index e30ac19..281ca02 100644
--- a/libs/hwui/PathTessellator.cpp
+++ b/libs/hwui/PathTessellator.cpp
@@ -162,14 +162,21 @@
     }
 
     /**
-     * Outset the bounds of point data (for line endpoints or points) to account for AA stroke
+     * Outset the bounds of point data (for line endpoints or points) to account for stroke
      * geometry.
+     *
+     * bounds are in pre-scaled space.
      */
     void expandBoundsForStroke(Rect* bounds) const {
-        float outset = halfStrokeWidth;
-        if (outset == 0) outset = 0.5f;
-        bounds->outset(outset * inverseScaleX + Vertex::GeometryFudgeFactor(),
-                outset * inverseScaleY + Vertex::GeometryFudgeFactor());
+        if (halfStrokeWidth == 0) {
+            // hairline, outset by (0.5f + fudge factor) in post-scaling space
+            bounds->outset(fabs(inverseScaleX) * (0.5f + Vertex::GeometryFudgeFactor()),
+                    fabs(inverseScaleY) * (0.5f + Vertex::GeometryFudgeFactor()));
+        } else {
+            // non hairline, outset by half stroke width pre-scaled, and fudge factor post scaled
+            bounds->outset(halfStrokeWidth + fabs(inverseScaleX) * Vertex::GeometryFudgeFactor(),
+                    halfStrokeWidth + fabs(inverseScaleY) * Vertex::GeometryFudgeFactor());
+        }
     }
 };
 
diff --git a/libs/hwui/ProgramCache.cpp b/libs/hwui/ProgramCache.cpp
index c802b18..06353c0 100644
--- a/libs/hwui/ProgramCache.cpp
+++ b/libs/hwui/ProgramCache.cpp
@@ -88,7 +88,7 @@
         "varying vec2 ditherTexCoords;\n",
 };
 const char* gVS_Header_Varyings_HasRoundRectClip =
-        "varying vec2 roundRectPos;\n";
+        "varying highp vec2 roundRectPos;\n";
 const char* gVS_Main =
         "\nvoid main(void) {\n";
 const char* gVS_Main_OutTexCoords =
@@ -327,9 +327,10 @@
         // None
         "",
         // Matrix
+        "    fragColor.rgb /= (fragColor.a + 0.0019);\n" // un-premultiply
         "    fragColor *= colorMatrix;\n"
         "    fragColor += colorMatrixVector;\n"
-        "    fragColor.rgb *= fragColor.a;\n",
+        "    fragColor.rgb *= (fragColor.a + 0.0019);\n", // re-premultiply
         // PorterDuff
         "    fragColor = blendColors(colorBlend, fragColor);\n"
 };
diff --git a/libs/hwui/Properties.h b/libs/hwui/Properties.h
index feaee8e..7eb9a32 100644
--- a/libs/hwui/Properties.h
+++ b/libs/hwui/Properties.h
@@ -227,7 +227,7 @@
 #define DEFAULT_PATCH_CACHE_SIZE 128 // in kB
 #define DEFAULT_GRADIENT_CACHE_SIZE 0.5f
 #define DEFAULT_DROP_SHADOW_CACHE_SIZE 2.0f
-#define DEFAULT_FBO_CACHE_SIZE 16
+#define DEFAULT_FBO_CACHE_SIZE 0
 
 #define DEFAULT_TEXTURE_CACHE_FLUSH_RATE 0.6f
 
diff --git a/libs/hwui/RenderNode.cpp b/libs/hwui/RenderNode.cpp
index 0db6198..254492f 100644
--- a/libs/hwui/RenderNode.cpp
+++ b/libs/hwui/RenderNode.cpp
@@ -34,6 +34,7 @@
 #include "LayerRenderer.h"
 #include "OpenGLRenderer.h"
 #include "utils/MathUtils.h"
+#include "renderthread/CanvasContext.h"
 
 namespace android {
 namespace uirenderer {
@@ -57,6 +58,19 @@
     fflush(file);
 }
 
+void RenderNode::debugDumpLayers(const char* prefix) {
+    if (mLayer) {
+        ALOGD("%sNode %p (%s) has layer %p (fbo = %u, wasBuildLayered = %s)",
+                prefix, this, getName(), mLayer, mLayer->getFbo(),
+                mLayer->wasBuildLayered ? "true" : "false");
+    }
+    if (mDisplayListData) {
+        for (size_t i = 0; i < mDisplayListData->children().size(); i++) {
+            mDisplayListData->children()[i]->mRenderNode->debugDumpLayers(prefix);
+        }
+    }
+}
+
 RenderNode::RenderNode()
         : mDirtyPropertyFields(0)
         , mNeedsDisplayListDataSync(false)
@@ -95,6 +109,7 @@
     properties().debugOutputProperties(level);
     int flags = DisplayListOp::kOpLogFlag_Recurse;
     if (mDisplayListData) {
+        // TODO: consider printing the chunk boundaries here
         for (unsigned int i = 0; i < mDisplayListData->displayListOps.size(); i++) {
             mDisplayListData->displayListOps[i]->output(level, flags);
         }
@@ -106,10 +121,10 @@
 int RenderNode::getDebugSize() {
     int size = sizeof(RenderNode);
     if (mStagingDisplayListData) {
-        size += mStagingDisplayListData->allocator.usedSize();
+        size += mStagingDisplayListData->getUsedSize();
     }
     if (mDisplayListData && mDisplayListData != mStagingDisplayListData) {
-        size += mDisplayListData->allocator.usedSize();
+        size += mDisplayListData->getUsedSize();
     }
     return size;
 }
@@ -179,13 +194,6 @@
         transformUpdateNeeded = true;
     }
 
-    if (transformUpdateNeeded) {
-        // update the transform in window of the layer to reset its origin wrt light source position
-        Matrix4 windowTransform;
-        info.damageAccumulator->computeCurrentTransform(&windowTransform);
-        mLayer->setWindowTransform(windowTransform);
-    }
-
     SkRect dirty;
     info.damageAccumulator->peekAtDirty(&dirty);
 
@@ -198,6 +206,12 @@
         return;
     }
 
+    if (transformUpdateNeeded) {
+        // update the transform in window of the layer to reset its origin wrt light source position
+        Matrix4 windowTransform;
+        info.damageAccumulator->computeCurrentTransform(&windowTransform);
+        mLayer->setWindowTransform(windowTransform);
+    }
 
     if (dirty.intersect(0, 0, getWidth(), getHeight())) {
         dirty.roundOut();
@@ -208,6 +222,13 @@
     if (info.renderer && mLayer->deferredUpdateScheduled) {
         info.renderer->pushLayerUpdate(mLayer);
     }
+
+    if (CC_UNLIKELY(info.canvasContext)) {
+        // If canvasContext is not null that means there are prefetched layers
+        // that need to be accounted for. That might be us, so tell CanvasContext
+        // that this layer is in the tree and should not be destroyed.
+        info.canvasContext->markLayerInUse(this);
+    }
 }
 
 void RenderNode::prepareTreeImpl(TreeInfo& info) {
@@ -216,7 +237,10 @@
     if (info.mode == TreeInfo::MODE_FULL) {
         pushStagingPropertiesChanges(info);
     }
-    uint32_t animatorDirtyMask = mAnimatorManager.animate(info);
+    uint32_t animatorDirtyMask = 0;
+    if (CC_LIKELY(info.runAnimations)) {
+        animatorDirtyMask = mAnimatorManager.animate(info);
+    }
     prepareLayer(info, animatorDirtyMask);
     if (info.mode == TreeInfo::MODE_FULL) {
         pushStagingDisplayListChanges(info);
@@ -231,7 +255,9 @@
     // Push the animators first so that setupStartValueIfNecessary() is called
     // before properties() is trampled by stagingProperties(), as they are
     // required by some animators.
-    mAnimatorManager.pushStaging(info);
+    if (CC_LIKELY(info.runAnimations)) {
+        mAnimatorManager.pushStaging();
+    }
     if (mDirtyPropertyFields) {
         mDirtyPropertyFields = 0;
         damageSelf(info);
@@ -400,7 +426,7 @@
         handler(op, PROPERTY_SAVECOUNT, properties().getClipToBounds());
     }
 
-    // TODO: support both reveal clip and outline clip simultaneously
+    // TODO: support nesting round rect clips
     if (mProperties.getRevealClip().willClip()) {
         Rect bounds;
         mProperties.getRevealClip().getBounds(&bounds);
@@ -408,7 +434,6 @@
     } else if (mProperties.getOutline().willClip()) {
         renderer.setClippingOutline(handler.allocator(), &(mProperties.getOutline()));
     }
-
 }
 
 /**
@@ -589,15 +614,16 @@
     issueOperations<ReplayOperationHandler>(replayStruct.mRenderer, handler);
 }
 
-void RenderNode::buildZSortedChildList(Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes) {
-    if (mDisplayListData == NULL || mDisplayListData->children().size() == 0) return;
+void RenderNode::buildZSortedChildList(const DisplayListData::Chunk& chunk,
+        Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes) {
+    if (chunk.beginChildIndex == chunk.endChildIndex) return;
 
-    for (unsigned int i = 0; i < mDisplayListData->children().size(); i++) {
+    for (unsigned int i = chunk.beginChildIndex; i < chunk.endChildIndex; i++) {
         DrawRenderNodeOp* childOp = mDisplayListData->children()[i];
         RenderNode* child = childOp->mRenderNode;
         float childZ = child->properties().getZ();
 
-        if (!MathUtils::isZero(childZ)) {
+        if (!MathUtils::isZero(childZ) && chunk.reorderChildren) {
             zTranslatedNodes.add(ZDrawRenderNodeOpPair(childZ, childOp));
             childOp->mSkipInOrderDraw = true;
         } else if (!child->properties().getProjectBackwards()) {
@@ -606,7 +632,7 @@
         }
     }
 
-    // Z sort 3d children (stable-ness makes z compare fall back to standard drawing order)
+    // Z sort any 3d children (stable-ness makes z compare fall back to standard drawing order)
     std::stable_sort(zTranslatedNodes.begin(), zTranslatedNodes.end());
 }
 
@@ -647,41 +673,12 @@
     handler(shadowOp, PROPERTY_SAVECOUNT, properties().getClipToBounds());
 }
 
-template <class T>
-int RenderNode::issueOperationsOfNegZChildren(
-        const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
-        OpenGLRenderer& renderer, T& handler) {
-    if (zTranslatedNodes.isEmpty()) return -1;
-
-    // create a save around the body of the ViewGroup's draw method, so that
-    // matrix/clip methods don't affect composited children
-    int shadowSaveCount = renderer.getSaveCount();
-    handler(new (handler.allocator()) SaveOp(SkCanvas::kMatrix_SaveFlag | SkCanvas::kClip_SaveFlag),
-            PROPERTY_SAVECOUNT, properties().getClipToBounds());
-
-    issueOperationsOf3dChildren(zTranslatedNodes, kNegativeZChildren, renderer, handler);
-    return shadowSaveCount;
-}
-
-template <class T>
-void RenderNode::issueOperationsOfPosZChildren(int shadowRestoreTo,
-        const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
-        OpenGLRenderer& renderer, T& handler) {
-    if (zTranslatedNodes.isEmpty()) return;
-
-    LOG_ALWAYS_FATAL_IF(shadowRestoreTo < 0, "invalid save to restore to");
-    handler(new (handler.allocator()) RestoreToCountOp(shadowRestoreTo),
-            PROPERTY_SAVECOUNT, properties().getClipToBounds());
-    renderer.setOverrideLayerAlpha(1.0f);
-
-    issueOperationsOf3dChildren(zTranslatedNodes, kPositiveZChildren, renderer, handler);
-}
-
 #define SHADOW_DELTA 0.1f
 
 template <class T>
-void RenderNode::issueOperationsOf3dChildren(const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
-        ChildrenSelectMode mode, OpenGLRenderer& renderer, T& handler) {
+void RenderNode::issueOperationsOf3dChildren(ChildrenSelectMode mode,
+        const Matrix4& initialTransform, const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
+        OpenGLRenderer& renderer, T& handler) {
     const int size = zTranslatedNodes.size();
     if (size == 0
             || (mode == kNegativeZChildren && zTranslatedNodes[0].key > 0.0f)
@@ -690,6 +687,11 @@
         return;
     }
 
+    // Apply the base transform of the parent of the 3d children. This isolates
+    // 3d children of the current chunk from transformations made in previous chunks.
+    int rootRestoreTo = renderer.save(SkCanvas::kMatrix_SaveFlag);
+    renderer.setMatrix(initialTransform);
+
     /**
      * Draw shadows and (potential) casters mostly in order, but allow the shadows of casters
      * with very similar Z heights to draw together.
@@ -744,6 +746,7 @@
         renderer.restoreToCount(restoreTo);
         drawIndex++;
     }
+    renderer.restoreToCount(rootRestoreTo);
 }
 
 template <class T>
@@ -863,36 +866,41 @@
     bool quickRejected = properties().getClipToBounds()
             && renderer.quickRejectConservative(0, 0, properties().getWidth(), properties().getHeight());
     if (!quickRejected) {
+        Matrix4 initialTransform(*(renderer.currentTransform()));
+
         if (drawLayer) {
             handler(new (alloc) DrawLayerOp(mLayer, 0, 0),
                     renderer.getSaveCount() - 1, properties().getClipToBounds());
         } else {
-            Vector<ZDrawRenderNodeOpPair> zTranslatedNodes;
-            buildZSortedChildList(zTranslatedNodes);
-
-            // for 3d root, draw children with negative z values
-            int shadowRestoreTo = issueOperationsOfNegZChildren(zTranslatedNodes, renderer, handler);
-
-            DisplayListLogBuffer& logBuffer = DisplayListLogBuffer::getInstance();
             const int saveCountOffset = renderer.getSaveCount() - 1;
             const int projectionReceiveIndex = mDisplayListData->projectionReceiveIndex;
-            const int size = static_cast<int>(mDisplayListData->displayListOps.size());
-            for (int i = 0; i < size; i++) {
-                DisplayListOp *op = mDisplayListData->displayListOps[i];
+            DisplayListLogBuffer& logBuffer = DisplayListLogBuffer::getInstance();
+            for (size_t chunkIndex = 0; chunkIndex < mDisplayListData->getChunks().size(); chunkIndex++) {
+                const DisplayListData::Chunk& chunk = mDisplayListData->getChunks()[chunkIndex];
 
+                Vector<ZDrawRenderNodeOpPair> zTranslatedNodes;
+                buildZSortedChildList(chunk, zTranslatedNodes);
+
+                issueOperationsOf3dChildren(kNegativeZChildren,
+                        initialTransform, zTranslatedNodes, renderer, handler);
+
+
+                for (int opIndex = chunk.beginOpIndex; opIndex < chunk.endOpIndex; opIndex++) {
+                    DisplayListOp *op = mDisplayListData->displayListOps[opIndex];
 #if DEBUG_DISPLAY_LIST
-                op->output(level + 1);
+                    op->output(level + 1);
 #endif
-                logBuffer.writeCommand(level, op->name());
-                handler(op, saveCountOffset, properties().getClipToBounds());
+                    logBuffer.writeCommand(level, op->name());
+                    handler(op, saveCountOffset, properties().getClipToBounds());
 
-                if (CC_UNLIKELY(i == projectionReceiveIndex && mProjectedNodes.size() > 0)) {
-                    issueOperationsOfProjectedChildren(renderer, handler);
+                    if (CC_UNLIKELY(!mProjectedNodes.isEmpty() && opIndex == projectionReceiveIndex)) {
+                        issueOperationsOfProjectedChildren(renderer, handler);
+                    }
                 }
-            }
 
-            // for 3d root, draw children with positive z values
-            issueOperationsOfPosZChildren(shadowRestoreTo, zTranslatedNodes, renderer, handler);
+                issueOperationsOf3dChildren(kPositiveZChildren,
+                        initialTransform, zTranslatedNodes, renderer, handler);
+            }
         }
     }
 
diff --git a/libs/hwui/RenderNode.h b/libs/hwui/RenderNode.h
index afa17d5..f329283 100644
--- a/libs/hwui/RenderNode.h
+++ b/libs/hwui/RenderNode.h
@@ -102,6 +102,7 @@
     };
 
     ANDROID_API static void outputLogBuffer(int fd);
+    void debugDumpLayers(const char* prefix);
 
     ANDROID_API void setStagingDisplayList(DisplayListData* newData);
 
@@ -114,7 +115,7 @@
     ANDROID_API int getDebugSize();
 
     bool isRenderable() const {
-        return mDisplayListData && mDisplayListData->hasDrawOps;
+        return mDisplayListData && !mDisplayListData->isEmpty();
     }
 
     bool hasProjectionReceiver() const {
@@ -174,6 +175,8 @@
     // UI thread only!
     ANDROID_API void addAnimator(const sp<BaseRenderNodeAnimator>& animator);
 
+    AnimatorManager& animators() { return mAnimatorManager; }
+
     void applyViewPropertyTransforms(mat4& matrix, bool true3dTransform = false) const;
 
 private:
@@ -199,22 +202,16 @@
     template <class T>
     inline void setViewProperties(OpenGLRenderer& renderer, T& handler);
 
-    void buildZSortedChildList(Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes);
+    void buildZSortedChildList(const DisplayListData::Chunk& chunk,
+            Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes);
 
     template<class T>
     inline void issueDrawShadowOperation(const Matrix4& transformFromParent, T& handler);
 
     template <class T>
-    inline int issueOperationsOfNegZChildren(
-            const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
+    inline void issueOperationsOf3dChildren(ChildrenSelectMode mode,
+            const Matrix4& initialTransform, const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
             OpenGLRenderer& renderer, T& handler);
-    template <class T>
-    inline void issueOperationsOfPosZChildren(int shadowRestoreTo,
-            const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
-            OpenGLRenderer& renderer, T& handler);
-    template <class T>
-    inline void issueOperationsOf3dChildren(const Vector<ZDrawRenderNodeOpPair>& zTranslatedNodes,
-            ChildrenSelectMode mode, OpenGLRenderer& renderer, T& handler);
 
     template <class T>
     inline void issueOperationsOfProjectedChildren(OpenGLRenderer& renderer, T& handler);
diff --git a/libs/hwui/RenderProperties.h b/libs/hwui/RenderProperties.h
index 0c8d07f..46eeb6a 100644
--- a/libs/hwui/RenderProperties.h
+++ b/libs/hwui/RenderProperties.h
@@ -569,6 +569,10 @@
         return getClipToBounds() && (getZ() <= 0 || getOutline().isEmpty());
     }
 
+    bool hasShadow() const {
+        return getZ() >= 0.0f && getOutline().getPath() != NULL;
+    }
+
 private:
     // Rendering properties
     struct PrimitiveFields {
diff --git a/libs/hwui/RenderState.cpp b/libs/hwui/RenderState.cpp
index 97f379d..86bd7dd 100644
--- a/libs/hwui/RenderState.cpp
+++ b/libs/hwui/RenderState.cpp
@@ -15,6 +15,8 @@
  */
 #include "RenderState.h"
 
+#include "renderthread/CanvasContext.h"
+
 namespace android {
 namespace uirenderer {
 
@@ -32,6 +34,42 @@
     // This is delayed because the first access of Caches makes GL calls
     mCaches = &Caches::getInstance();
     mCaches->init();
+    mCaches->setRenderState(this);
+}
+
+void RenderState::onGLContextDestroyed() {
+/*
+    AutoMutex _lock(mLayerLock);
+    size_t size = mActiveLayers.size();
+    if (CC_UNLIKELY(size != 0)) {
+        ALOGE("Crashing, have %d contexts and %d layers at context destruction. isempty %d",
+                mRegisteredContexts.size(), size, mActiveLayers.empty());
+        mCaches->dumpMemoryUsage();
+        for (std::set<renderthread::CanvasContext*>::iterator cit = mRegisteredContexts.begin();
+                cit != mRegisteredContexts.end(); cit++) {
+            renderthread::CanvasContext* context = *cit;
+            ALOGE("Context: %p (root = %p)", context, context->mRootRenderNode.get());
+            ALOGE("  Prefeteched layers: %zu", context->mPrefetechedLayers.size());
+            for (std::set<RenderNode*>::iterator pit = context->mPrefetechedLayers.begin();
+                    pit != context->mPrefetechedLayers.end(); pit++) {
+                (*pit)->debugDumpLayers("    ");
+            }
+            context->mRootRenderNode->debugDumpLayers("  ");
+        }
+
+
+        if (mActiveLayers.begin() == mActiveLayers.end()) {
+            ALOGE("set has become empty. wat.");
+        }
+        for (std::set<const Layer*>::iterator lit = mActiveLayers.begin();
+             lit != mActiveLayers.end(); lit++) {
+            const Layer* layer = *(lit);
+            ALOGE("Layer %p, state %d, texlayer %d, fbo %d, buildlayered %d",
+                    layer, layer->state, layer->isTextureLayer(), layer->getFbo(), layer->wasBuildLayered);
+        }
+        LOG_ALWAYS_FATAL("%d layers have survived gl context destruction", size);
+    }
+*/
 }
 
 void RenderState::setViewport(GLsizei width, GLsizei height) {
diff --git a/libs/hwui/RenderState.h b/libs/hwui/RenderState.h
index f7116e2..cbe7cfc 100644
--- a/libs/hwui/RenderState.h
+++ b/libs/hwui/RenderState.h
@@ -16,8 +16,10 @@
 #ifndef RENDERSTATE_H
 #define RENDERSTATE_H
 
+#include <set>
 #include <GLES2/gl2.h>
 #include <GLES2/gl2ext.h>
+#include <utils/Mutex.h>
 
 #include <private/hwui/DrawGlInfo.h>
 
@@ -28,6 +30,7 @@
 namespace uirenderer {
 
 namespace renderthread {
+class CanvasContext;
 class RenderThread;
 }
 
@@ -37,6 +40,7 @@
     PREVENT_COPY_AND_ASSIGN(RenderState);
 public:
     void onGLContextCreated();
+    void onGLContextDestroyed();
 
     void setViewport(GLsizei width, GLsizei height);
     void getViewport(GLsizei* outWidth, GLsizei* outHeight);
@@ -48,8 +52,30 @@
 
     void debugOverdraw(bool enable, bool clear);
 
+    void registerLayer(const Layer* layer) {
+        /*
+        AutoMutex _lock(mLayerLock);
+        mActiveLayers.insert(layer);
+        */
+    }
+    void unregisterLayer(const Layer* layer) {
+        /*
+        AutoMutex _lock(mLayerLock);
+        mActiveLayers.erase(layer);
+        */
+    }
+
+    void registerCanvasContext(renderthread::CanvasContext* context) {
+        mRegisteredContexts.insert(context);
+    }
+
+    void unregisterCanvasContext(renderthread::CanvasContext* context) {
+        mRegisteredContexts.erase(context);
+    }
+
 private:
     friend class renderthread::RenderThread;
+    friend class Caches;
 
     void interruptForFunctorInvoke();
     void resumeFromFunctorInvoke();
@@ -58,10 +84,13 @@
     ~RenderState();
 
     Caches* mCaches;
+    std::set<const Layer*> mActiveLayers;
+    std::set<renderthread::CanvasContext*> mRegisteredContexts;
 
     GLsizei mViewportWidth;
     GLsizei mViewportHeight;
     GLuint mFramebuffer;
+    Mutex mLayerLock;
 };
 
 } /* namespace uirenderer */
diff --git a/libs/hwui/Renderer.h b/libs/hwui/Renderer.h
index f5cd266..3681637 100644
--- a/libs/hwui/Renderer.h
+++ b/libs/hwui/Renderer.h
@@ -67,6 +67,20 @@
         return resultMode;
     }
 
+    // TODO: move to a method on android:Paint
+    static inline bool paintWillNotDraw(const SkPaint& paint) {
+        return paint.getAlpha() == 0
+                && !paint.getColorFilter()
+                && getXfermode(paint.getXfermode()) != SkXfermode::kClear_Mode;
+    }
+
+    // TODO: move to a method on android:Paint
+    static inline bool paintWillNotDrawText(const SkPaint& paint) {
+        return paint.getAlpha() == 0
+                && paint.getLooper() == NULL
+                && !paint.getColorFilter()
+                && getXfermode(paint.getXfermode()) == SkXfermode::kSrcOver_Mode;
+    }
 // ----------------------------------------------------------------------------
 // Frame state operations
 // ----------------------------------------------------------------------------
diff --git a/libs/hwui/ShadowTessellator.cpp b/libs/hwui/ShadowTessellator.cpp
index e71439d..35cc7a4 100644
--- a/libs/hwui/ShadowTessellator.cpp
+++ b/libs/hwui/ShadowTessellator.cpp
@@ -29,11 +29,6 @@
 namespace android {
 namespace uirenderer {
 
-template<typename T>
-static inline T max(T a, T b) {
-    return a > b ? a : b;
-}
-
 void ShadowTessellator::tessellateAmbientShadow(bool isCasterOpaque,
         const Vector3* casterPolygon, int casterVertexCount,
         const Vector3& centroid3d, const Rect& casterBounds,
@@ -42,7 +37,7 @@
 
     // A bunch of parameters to tweak the shadow.
     // TODO: Allow some of these changable by debug settings or APIs.
-    float heightFactor = 1.0f / 128;
+    float heightFactor = 1.0f / 86;
     const float geomFactor = 64;
 
     Caches& caches = Caches::getInstance();
@@ -66,7 +61,7 @@
 }
 
 void ShadowTessellator::tessellateSpotShadow(bool isCasterOpaque,
-        const Vector3* casterPolygon, int casterVertexCount,
+        const Vector3* casterPolygon, int casterVertexCount, const Vector3& casterCentroid,
         const mat4& receiverTransform, const Vector3& lightCenter, int lightRadius,
         const Rect& casterBounds, const Rect& localClip, VertexBuffer& shadowVertexBuffer) {
     ATRACE_CALL();
@@ -109,9 +104,9 @@
         return;
     }
 
-    SpotShadow::createSpotShadow(isCasterOpaque,
-            casterPolygon, casterVertexCount, adjustedLightCenter, lightRadius,
-            lightVertexCount, shadowVertexBuffer);
+    SpotShadow::createSpotShadow(isCasterOpaque, adjustedLightCenter, lightRadius,
+            casterPolygon, casterVertexCount, casterCentroid, shadowVertexBuffer);
+
 #if DEBUG_SHADOW
      if(shadowVertexBuffer.getVertexCount() <= 0) {
         ALOGD("Spot shadow generation failed %d", shadowVertexBuffer.getVertexCount());
@@ -180,6 +175,18 @@
     return centroid;
 }
 
+// Make sure p1 -> p2 is going CW around the poly.
+Vector2 ShadowTessellator::calculateNormal(const Vector2& p1, const Vector2& p2) {
+    Vector2 result = p2 - p1;
+    if (result.x != 0 || result.y != 0) {
+        result.normalize();
+        // Calculate the normal , which is CCW 90 rotate to the delta.
+        float tempy = result.y;
+        result.y = result.x;
+        result.x = -tempy;
+    }
+    return result;
+}
 /**
  * Test whether the polygon is order in clockwise.
  *
@@ -245,5 +252,29 @@
     }
 }
 
+int ShadowTessellator::getExtraVertexNumber(const Vector2& vector1,
+        const Vector2& vector2, float divisor) {
+    // When there is no distance difference, there is no need for extra vertices.
+    if (vector1.lengthSquared() == 0 || vector2.lengthSquared() == 0) {
+        return 0;
+    }
+    // The formula is :
+    // extraNumber = floor(acos(dot(n1, n2)) / (M_PI / EXTRA_VERTEX_PER_PI))
+    // The value ranges for each step are:
+    // dot( ) --- [-1, 1]
+    // acos( )     --- [0, M_PI]
+    // floor(...)  --- [0, EXTRA_VERTEX_PER_PI]
+    float dotProduct = vector1.dot(vector2);
+    // TODO: Use look up table for the dotProduct to extraVerticesNumber
+    // computation, if needed.
+    float angle = acosf(dotProduct);
+    return (int) floor(angle / divisor);
+}
+
+void ShadowTessellator::checkOverflow(int used, int total, const char* bufferName) {
+    LOG_ALWAYS_FATAL_IF(used > total, "Error: %s overflow!!! used %d, total %d",
+            bufferName, used, total);
+}
+
 }; // namespace uirenderer
 }; // namespace android
diff --git a/libs/hwui/ShadowTessellator.h b/libs/hwui/ShadowTessellator.h
index cb65df5..8f19b5c 100644
--- a/libs/hwui/ShadowTessellator.h
+++ b/libs/hwui/ShadowTessellator.h
@@ -72,7 +72,7 @@
             const Rect& localClip, float maxZ, VertexBuffer& shadowVertexBuffer);
 
     static void tessellateSpotShadow(bool isCasterOpaque,
-            const Vector3* casterPolygon, int casterVertexCount,
+            const Vector3* casterPolygon, int casterVertexCount, const Vector3& casterCentroid,
             const mat4& receiverTransform, const Vector3& lightCenter, int lightRadius,
             const Rect& casterBounds, const Rect& localClip, VertexBuffer& shadowVertexBuffer);
 
@@ -82,6 +82,7 @@
 
     static bool isClockwise(const Vector2* polygon, int len);
 
+    static Vector2 calculateNormal(const Vector2& p1, const Vector2& p2);
     /**
      * Determine whether the path is clockwise, using the control points.
      *
@@ -100,6 +101,10 @@
      */
     static void reverseVertexArray(Vertex* polygon, int len);
 
+    static int getExtraVertexNumber(const Vector2& vector1, const Vector2& vector2,
+            float divisor);
+
+    static void checkOverflow(int used, int total, const char* bufferName);
 }; // ShadowTessellator
 
 }; // namespace uirenderer
diff --git a/libs/hwui/Snapshot.cpp b/libs/hwui/Snapshot.cpp
index ecc47d2..cf8229fd 100644
--- a/libs/hwui/Snapshot.cpp
+++ b/libs/hwui/Snapshot.cpp
@@ -216,14 +216,22 @@
 // Clipping round rect
 ///////////////////////////////////////////////////////////////////////////////
 
-void Snapshot::setClippingRoundRect(LinearAllocator& allocator, const Rect& bounds, float radius) {
+void Snapshot::setClippingRoundRect(LinearAllocator& allocator, const Rect& bounds,
+        float radius, bool highPriority) {
     if (bounds.isEmpty()) {
         clipRect->setEmpty();
         return;
     }
 
+    if (roundRectClipState && roundRectClipState->highPriority) {
+        // ignore, don't replace, already have a high priority clip
+        return;
+    }
+
     RoundRectClipState* state = new (allocator) RoundRectClipState;
 
+    state->highPriority = highPriority;
+
     // store the inverse drawing matrix
     Matrix4 roundRectDrawingMatrix;
     roundRectDrawingMatrix.load(getOrthoMatrix());
diff --git a/libs/hwui/Snapshot.h b/libs/hwui/Snapshot.h
index ad4ee9d..549de9b 100644
--- a/libs/hwui/Snapshot.h
+++ b/libs/hwui/Snapshot.h
@@ -55,6 +55,7 @@
                 || rect.intersects(dangerRects[3]);
     }
 
+    bool highPriority;
     Matrix4 matrix;
     Rect dangerRects[4];
     Rect innerRect;
@@ -166,8 +167,11 @@
 
     /**
      * Sets (and replaces) the current clipping outline
+     *
+     * If the current round rect clip is high priority, the incoming clip is ignored.
      */
-    void setClippingRoundRect(LinearAllocator& allocator, const Rect& bounds, float radius);
+    void setClippingRoundRect(LinearAllocator& allocator, const Rect& bounds,
+            float radius, bool highPriority);
 
     /**
      * Indicates whether this snapshot should be ignored. A snapshot
diff --git a/libs/hwui/SpotShadow.cpp b/libs/hwui/SpotShadow.cpp
index d726538..dbedf94 100644
--- a/libs/hwui/SpotShadow.cpp
+++ b/libs/hwui/SpotShadow.cpp
@@ -16,7 +16,34 @@
 
 #define LOG_TAG "OpenGLRenderer"
 
-#define SHADOW_SHRINK_SCALE 0.1f
+// The highest z value can't be higher than (CASTER_Z_CAP_RATIO * light.z)
+#define CASTER_Z_CAP_RATIO 0.95f
+
+// When there is no umbra, then just fake the umbra using
+// centroid * (1 - FAKE_UMBRA_SIZE_RATIO) + outline * FAKE_UMBRA_SIZE_RATIO
+#define FAKE_UMBRA_SIZE_RATIO 0.05f
+
+// When the polygon is about 90 vertices, the penumbra + umbra can reach 270 rays.
+// That is consider pretty fine tessllated polygon so far.
+// This is just to prevent using too much some memory when edge slicing is not
+// needed any more.
+#define FINE_TESSELLATED_POLYGON_RAY_NUMBER 270
+/**
+ * Extra vertices for the corner for smoother corner.
+ * Only for outer loop.
+ * Note that we use such extra memory to avoid an extra loop.
+ */
+// For half circle, we could add EXTRA_VERTEX_PER_PI vertices.
+// Set to 1 if we don't want to have any.
+#define SPOT_EXTRA_CORNER_VERTEX_PER_PI 18
+
+// For the whole polygon, the sum of all the deltas b/t normals is 2 * M_PI,
+// therefore, the maximum number of extra vertices will be twice bigger.
+#define SPOT_MAX_EXTRA_CORNER_VERTEX_NUMBER  (2 * SPOT_EXTRA_CORNER_VERTEX_PER_PI)
+
+// For each RADIANS_DIVISOR, we would allocate one more vertex b/t the normals.
+#define SPOT_CORNER_RADIANS_DIVISOR (M_PI / SPOT_EXTRA_CORNER_VERTEX_PER_PI)
+
 
 #include <math.h>
 #include <stdlib.h>
@@ -25,13 +52,47 @@
 #include "ShadowTessellator.h"
 #include "SpotShadow.h"
 #include "Vertex.h"
+#include "utils/MathUtils.h"
 
+// TODO: After we settle down the new algorithm, we can remove the old one and
+// its utility functions.
+// Right now, we still need to keep it for comparison purpose and future expansion.
 namespace android {
 namespace uirenderer {
 
 static const double EPSILON = 1e-7;
 
 /**
+ * For each polygon's vertex, the light center will project it to the receiver
+ * as one of the outline vertex.
+ * For each outline vertex, we need to store the position and normal.
+ * Normal here is defined against the edge by the current vertex and the next vertex.
+ */
+struct OutlineData {
+    Vector2 position;
+    Vector2 normal;
+    float radius;
+};
+
+/**
+ * For each vertex, we need to keep track of its angle, whether it is penumbra or
+ * umbra, and its corresponding vertex index.
+ */
+struct SpotShadow::VertexAngleData {
+    // The angle to the vertex from the centroid.
+    float mAngle;
+    // True is the vertex comes from penumbra, otherwise it comes from umbra.
+    bool mIsPenumbra;
+    // The index of the vertex described by this data.
+    int mVertexIndex;
+    void set(float angle, bool isPenumbra, int index) {
+        mAngle = angle;
+        mIsPenumbra = isPenumbra;
+        mVertexIndex = index;
+    }
+};
+
+/**
  * Calculate the angle between and x and a y coordinate.
  * The atan2 range from -PI to PI.
  */
@@ -388,8 +449,8 @@
         double endX = poly[i].x;
         double endY = poly[i].y;
 
-        if (((endY > testy) != (startY > testy)) &&
-            (testx < (startX - endX) * (testy - endY)
+        if (((endY > testy) != (startY > testy))
+            && (testx < (startX - endX) * (testy - endY)
              / (startY - endY) + endX)) {
             c = !c;
         }
@@ -489,135 +550,245 @@
 }
 
 /**
-* Generate the shadow from a spot light.
-*
-* @param poly x,y,z vertexes of a convex polygon that occludes the light source
-* @param polyLength number of vertexes of the occluding polygon
-* @param lightCenter the center of the light
-* @param lightSize the radius of the light source
-* @param lightVertexCount the vertex counter for the light polygon
-* @param shadowTriangleStrip return an (x,y,alpha) triangle strip representing the shadow. Return
-*                            empty strip if error.
-*
-*/
-void SpotShadow::createSpotShadow(bool isCasterOpaque, const Vector3* poly,
-        int polyLength, const Vector3& lightCenter, float lightSize,
-        int lightVertexCount, VertexBuffer& retStrips) {
-    Vector3 light[lightVertexCount * 3];
-    computeLightPolygon(lightVertexCount, lightCenter, lightSize, light);
-    computeSpotShadow(isCasterOpaque, light, lightVertexCount, lightCenter, poly,
-            polyLength, retStrips);
+ * From light center, project one vertex to the z=0 surface and get the outline.
+ *
+ * @param outline The result which is the outline position.
+ * @param lightCenter The center of light.
+ * @param polyVertex The input polygon's vertex.
+ *
+ * @return float The ratio of (polygon.z / light.z - polygon.z)
+ */
+float SpotShadow::projectCasterToOutline(Vector2& outline,
+        const Vector3& lightCenter, const Vector3& polyVertex) {
+    float lightToPolyZ = lightCenter.z - polyVertex.z;
+    float ratioZ = CASTER_Z_CAP_RATIO;
+    if (lightToPolyZ != 0) {
+        // If any caster's vertex is almost above the light, we just keep it as 95%
+        // of the height of the light.
+        ratioZ = MathUtils::clamp(polyVertex.z / lightToPolyZ, 0.0f, CASTER_Z_CAP_RATIO);
+    }
+
+    outline.x = polyVertex.x - ratioZ * (lightCenter.x - polyVertex.x);
+    outline.y = polyVertex.y - ratioZ * (lightCenter.y - polyVertex.y);
+    return ratioZ;
 }
 
 /**
  * Generate the shadow spot light of shape lightPoly and a object poly
  *
- * @param lightPoly x,y,z vertex of a convex polygon that is the light source
- * @param lightPolyLength number of vertexes of the light source polygon
+ * @param isCasterOpaque whether the caster is opaque
+ * @param lightCenter the center of the light
+ * @param lightSize the radius of the light
  * @param poly x,y,z vertexes of a convex polygon that occludes the light source
  * @param polyLength number of vertexes of the occluding polygon
  * @param shadowTriangleStrip return an (x,y,alpha) triangle strip representing the shadow. Return
  *                            empty strip if error.
  */
-void SpotShadow::computeSpotShadow(bool isCasterOpaque, const Vector3* lightPoly,
-        int lightPolyLength, const Vector3& lightCenter, const Vector3* poly,
-        int polyLength, VertexBuffer& shadowTriangleStrip) {
-    // Point clouds for all the shadowed vertices
-    Vector2 shadowRegion[lightPolyLength * polyLength];
-    // Shadow polygon from one point light.
-    Vector2 outline[polyLength];
-    Vector2 umbraMem[polyLength * lightPolyLength];
-    Vector2* umbra = umbraMem;
-
-    int umbraLength = 0;
-
-    // Validate input, receiver is always at z = 0 plane.
-    bool inputPolyPositionValid = true;
-    for (int i = 0; i < polyLength; i++) {
-        if (poly[i].z >= lightPoly[0].z) {
-            inputPolyPositionValid = false;
-            ALOGW("polygon above the light");
-            break;
-        }
-    }
-
-    // If the caster's position is invalid, don't draw anything.
-    if (!inputPolyPositionValid) {
+void SpotShadow::createSpotShadow(bool isCasterOpaque, const Vector3& lightCenter,
+        float lightSize, const Vector3* poly, int polyLength, const Vector3& polyCentroid,
+        VertexBuffer& shadowTriangleStrip) {
+    if (CC_UNLIKELY(lightCenter.z <= 0)) {
+        ALOGW("Relative Light Z is not positive. No spot shadow!");
         return;
     }
-
-    // Calculate the umbra polygon based on intersections of all outlines
-    int k = 0;
-    for (int j = 0; j < lightPolyLength; j++) {
-        int m = 0;
-        for (int i = 0; i < polyLength; i++) {
-            // After validating the input, deltaZ is guaranteed to be positive.
-            float deltaZ = lightPoly[j].z - poly[i].z;
-            float ratioZ = lightPoly[j].z / deltaZ;
-            float x = lightPoly[j].x - ratioZ * (lightPoly[j].x - poly[i].x);
-            float y = lightPoly[j].y - ratioZ * (lightPoly[j].y - poly[i].y);
-
-            Vector2 newPoint = {x, y};
-            shadowRegion[k] = newPoint;
-            outline[m] = newPoint;
-
-            k++;
-            m++;
-        }
-
-        // For the first light polygon's vertex, use the outline as the umbra.
-        // Later on, use the intersection of the outline and existing umbra.
-        if (umbraLength == 0) {
-            for (int i = 0; i < polyLength; i++) {
-                umbra[i] = outline[i];
-            }
-            umbraLength = polyLength;
-        } else {
-            int col = ((j * 255) / lightPolyLength);
-            umbraLength = intersection(outline, polyLength, umbra, umbraLength);
-            if (umbraLength == 0) {
-                break;
-            }
-        }
-    }
-
-    // Generate the penumbra area using the hull of all shadow regions.
-    int shadowRegionLength = k;
-    Vector2 penumbra[k];
-    int penumbraLength = hull(shadowRegion, shadowRegionLength, penumbra);
-
-    Vector2 fakeUmbra[polyLength];
-    if (umbraLength < 3) {
-        // If there is no real umbra, make a fake one.
-        for (int i = 0; i < polyLength; i++) {
-            float deltaZ = lightCenter.z - poly[i].z;
-            float ratioZ = lightCenter.z / deltaZ;
-            float x = lightCenter.x - ratioZ * (lightCenter.x - poly[i].x);
-            float y = lightCenter.y - ratioZ * (lightCenter.y - poly[i].y);
-
-            fakeUmbra[i].x = x;
-            fakeUmbra[i].y = y;
-        }
-
-        // Shrink the centroid's shadow by 10%.
-        // TODO: Study the magic number of 10%.
-        Vector2 shadowCentroid =
-                ShadowTessellator::centroid2d(fakeUmbra, polyLength);
-        for (int i = 0; i < polyLength; i++) {
-            fakeUmbra[i] = shadowCentroid * (1.0f - SHADOW_SHRINK_SCALE) +
-                    fakeUmbra[i] * SHADOW_SHRINK_SCALE;
-        }
+    if (CC_UNLIKELY(polyLength < 3)) {
 #if DEBUG_SHADOW
-        ALOGD("No real umbra make a fake one, centroid2d =  %f , %f",
-                shadowCentroid.x, shadowCentroid.y);
+        ALOGW("Invalid polygon length. No spot shadow!");
 #endif
-        // Set the fake umbra, whose size is the same as the original polygon.
-        umbra = fakeUmbra;
-        umbraLength = polyLength;
+        return;
+    }
+    OutlineData outlineData[polyLength];
+    Vector2 outlineCentroid;
+    // Calculate the projected outline for each polygon's vertices from the light center.
+    //
+    //                       O     Light
+    //                      /
+    //                    /
+    //                   .     Polygon vertex
+    //                 /
+    //               /
+    //              O     Outline vertices
+    //
+    // Ratio = (Poly - Outline) / (Light - Poly)
+    // Outline.x = Poly.x - Ratio * (Light.x - Poly.x)
+    // Outline's radius / Light's radius = Ratio
+
+    // Compute the last outline vertex to make sure we can get the normal and outline
+    // in one single loop.
+    projectCasterToOutline(outlineData[polyLength - 1].position, lightCenter,
+            poly[polyLength - 1]);
+
+    // Take the outline's polygon, calculate the normal for each outline edge.
+    int currentNormalIndex = polyLength - 1;
+    int nextNormalIndex = 0;
+
+    for (int i = 0; i < polyLength; i++) {
+        float ratioZ = projectCasterToOutline(outlineData[i].position,
+                lightCenter, poly[i]);
+        outlineData[i].radius = ratioZ * lightSize;
+
+        outlineData[currentNormalIndex].normal = ShadowTessellator::calculateNormal(
+                outlineData[currentNormalIndex].position,
+                outlineData[nextNormalIndex].position);
+        currentNormalIndex = (currentNormalIndex + 1) % polyLength;
+        nextNormalIndex++;
     }
 
-    generateTriangleStrip(isCasterOpaque, penumbra, penumbraLength, umbra,
-            umbraLength, poly, polyLength, shadowTriangleStrip);
+    projectCasterToOutline(outlineCentroid, lightCenter, polyCentroid);
+
+    int penumbraIndex = 0;
+    // Then each polygon's vertex produce at minmal 2 penumbra vertices.
+    // Since the size can be dynamic here, we keep track of the size and update
+    // the real size at the end.
+    int allocatedPenumbraLength = 2 * polyLength + SPOT_MAX_EXTRA_CORNER_VERTEX_NUMBER;
+    Vector2 penumbra[allocatedPenumbraLength];
+    int totalExtraCornerSliceNumber = 0;
+
+    Vector2 umbra[polyLength];
+
+    // When centroid is covered by all circles from outline, then we consider
+    // the umbra is invalid, and we will tune down the shadow strength.
+    bool hasValidUmbra = true;
+    // We need the minimal of RaitoVI to decrease the spot shadow strength accordingly.
+    float minRaitoVI = FLT_MAX;
+
+    for (int i = 0; i < polyLength; i++) {
+        // Generate all the penumbra's vertices only using the (outline vertex + normal * radius)
+        // There is no guarantee that the penumbra is still convex, but for
+        // each outline vertex, it will connect to all its corresponding penumbra vertices as
+        // triangle fans. And for neighber penumbra vertex, it will be a trapezoid.
+        //
+        // Penumbra Vertices marked as Pi
+        // Outline Vertices marked as Vi
+        //                                            (P3)
+        //          (P2)                               |     ' (P4)
+        //   (P1)'   |                                 |   '
+        //         ' |                                 | '
+        // (P0)  ------------------------------------------------(P5)
+        //           | (V0)                            |(V1)
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //           |                                 |
+        //       (V3)-----------------------------------(V2)
+        int preNormalIndex = (i + polyLength - 1) % polyLength;
+
+        const Vector2& previousNormal = outlineData[preNormalIndex].normal;
+        const Vector2& currentNormal = outlineData[i].normal;
+
+        // Depending on how roundness we want for each corner, we can subdivide
+        // further here and/or introduce some heuristic to decide how much the
+        // subdivision should be.
+        int currentExtraSliceNumber = ShadowTessellator::getExtraVertexNumber(
+                previousNormal, currentNormal, SPOT_CORNER_RADIANS_DIVISOR);
+
+        int currentCornerSliceNumber = 1 + currentExtraSliceNumber;
+        totalExtraCornerSliceNumber += currentExtraSliceNumber;
+#if DEBUG_SHADOW
+        ALOGD("currentExtraSliceNumber should be %d", currentExtraSliceNumber);
+        ALOGD("currentCornerSliceNumber should be %d", currentCornerSliceNumber);
+        ALOGD("totalCornerSliceNumber is %d", totalExtraCornerSliceNumber);
+#endif
+        if (CC_UNLIKELY(totalExtraCornerSliceNumber > SPOT_MAX_EXTRA_CORNER_VERTEX_NUMBER)) {
+            currentCornerSliceNumber = 1;
+        }
+        for (int k = 0; k <= currentCornerSliceNumber; k++) {
+            Vector2 avgNormal =
+                    (previousNormal * (currentCornerSliceNumber - k) + currentNormal * k) /
+                    currentCornerSliceNumber;
+            avgNormal.normalize();
+            penumbra[penumbraIndex++] = outlineData[i].position +
+                    avgNormal * outlineData[i].radius;
+        }
+
+
+        // Compute the umbra by the intersection from the outline's centroid!
+        //
+        //       (V) ------------------------------------
+        //           |          '                       |
+        //           |         '                        |
+        //           |       ' (I)                      |
+        //           |    '                             |
+        //           | '             (C)                |
+        //           |                                  |
+        //           |                                  |
+        //           |                                  |
+        //           |                                  |
+        //           ------------------------------------
+        //
+        // Connect a line b/t the outline vertex (V) and the centroid (C), it will
+        // intersect with the outline vertex's circle at point (I).
+        // Now, ratioVI = VI / VC, ratioIC = IC / VC
+        // Then the intersetion point can be computed as Ixy = Vxy * ratioIC + Cxy * ratioVI;
+        //
+        // When all of the outline circles cover the the outline centroid, (like I is
+        // on the other side of C), there is no real umbra any more, so we just fake
+        // a small area around the centroid as the umbra, and tune down the spot
+        // shadow's umbra strength to simulate the effect the whole shadow will
+        // become lighter in this case.
+        // The ratio can be simulated by using the inverse of maximum of ratioVI for
+        // all (V).
+        float distOutline = (outlineData[i].position - outlineCentroid).length();
+        if (CC_UNLIKELY(distOutline == 0)) {
+            // If the outline has 0 area, then there is no spot shadow anyway.
+            ALOGW("Outline has 0 area, no spot shadow!");
+            return;
+        }
+
+        float ratioVI = outlineData[i].radius / distOutline;
+        minRaitoVI = MathUtils::min(minRaitoVI, ratioVI);
+        if (ratioVI >= (1 - FAKE_UMBRA_SIZE_RATIO)) {
+            ratioVI = (1 - FAKE_UMBRA_SIZE_RATIO);
+        }
+        // When we know we don't have valid umbra, don't bother to compute the
+        // values below. But we can't skip the loop yet since we want to know the
+        // maximum ratio.
+        float ratioIC = 1 - ratioVI;
+        umbra[i] = outlineData[i].position * ratioIC + outlineCentroid * ratioVI;
+    }
+
+    hasValidUmbra = (minRaitoVI <= 1.0);
+    float shadowStrengthScale = 1.0;
+    if (!hasValidUmbra) {
+#if DEBUG_SHADOW
+        ALOGW("The object is too close to the light or too small, no real umbra!");
+#endif
+        for (int i = 0; i < polyLength; i++) {
+            umbra[i] = outlineData[i].position * FAKE_UMBRA_SIZE_RATIO +
+                    outlineCentroid * (1 - FAKE_UMBRA_SIZE_RATIO);
+        }
+        shadowStrengthScale = 1.0 / minRaitoVI;
+    }
+
+    int penumbraLength = penumbraIndex;
+    int umbraLength = polyLength;
+
+#if DEBUG_SHADOW
+    ALOGD("penumbraLength is %d , allocatedPenumbraLength %d", penumbraLength, allocatedPenumbraLength);
+    dumpPolygon(poly, polyLength, "input poly");
+    dumpPolygon(penumbra, penumbraLength, "penumbra");
+    dumpPolygon(umbra, umbraLength, "umbra");
+    ALOGD("hasValidUmbra is %d and shadowStrengthScale is %f", hasValidUmbra, shadowStrengthScale);
+#endif
+
+    // The penumbra and umbra needs to be in convex shape to keep consistency
+    // and quality.
+    // Since we are still shooting rays to penumbra, it needs to be convex.
+    // Umbra can be represented as a fan from the centroid, but visually umbra
+    // looks nicer when it is convex.
+    Vector2 finalUmbra[umbraLength];
+    Vector2 finalPenumbra[penumbraLength];
+    int finalUmbraLength = hull(umbra, umbraLength, finalUmbra);
+    int finalPenumbraLength = hull(penumbra, penumbraLength, finalPenumbra);
+
+    generateTriangleStrip(isCasterOpaque, shadowStrengthScale, finalPenumbra,
+            finalPenumbraLength, finalUmbra, finalUmbraLength, poly, polyLength,
+            shadowTriangleStrip, outlineCentroid);
+
 }
 
 /**
@@ -679,7 +850,7 @@
         lastVertex = &poly[polyIndex];
     }
 
-   return true;
+    return true;
 }
 
 int SpotShadow::calculateOccludedUmbra(const Vector2* umbra, int umbraLength,
@@ -697,103 +868,6 @@
             occludedUmbra, polyLength);
 }
 
-#define OCLLUDED_UMBRA_SHRINK_FACTOR 0.95f
-/**
- * Generate a triangle strip given two convex polygons
- *
- * @param penumbra The outer polygon x,y vertexes
- * @param penumbraLength The number of vertexes in the outer polygon
- * @param umbra The inner outer polygon x,y vertexes
- * @param umbraLength The number of vertexes in the inner polygon
- * @param shadowTriangleStrip return an (x,y,alpha) triangle strip representing the shadow. Return
- *                            empty strip if error.
-**/
-void SpotShadow::generateTriangleStrip(bool isCasterOpaque, const Vector2* penumbra,
-        int penumbraLength, const Vector2* umbra, int umbraLength,
-        const Vector3* poly, int polyLength, VertexBuffer& shadowTriangleStrip) {
-    const int rays = SHADOW_RAY_COUNT;
-    const int size = 2 * rays;
-    const float step = M_PI * 2 / rays;
-    // Centroid of the umbra.
-    Vector2 centroid = ShadowTessellator::centroid2d(umbra, umbraLength);
-#if DEBUG_SHADOW
-    ALOGD("centroid2d =  %f , %f", centroid.x, centroid.y);
-#endif
-    // Intersection to the penumbra.
-    float penumbraDistPerRay[rays];
-    // Intersection to the umbra.
-    float umbraDistPerRay[rays];
-    // Intersection to the occluded umbra area.
-    float occludedUmbraDistPerRay[rays];
-
-    // convert CW polygons to ray distance encoding, aborting on conversion failure
-    if (!convertPolyToRayDist(umbra, umbraLength, centroid, umbraDistPerRay)) return;
-    if (!convertPolyToRayDist(penumbra, penumbraLength, centroid, penumbraDistPerRay)) return;
-
-    bool hasOccludedUmbraArea = false;
-    if (isCasterOpaque) {
-        Vector2 occludedUmbra[polyLength + umbraLength];
-        int occludedUmbraLength = calculateOccludedUmbra(umbra, umbraLength, poly, polyLength,
-                occludedUmbra);
-        // Make sure the centroid is inside the umbra, otherwise, fall back to the
-        // approach as if there is no occluded umbra area.
-        if (testPointInsidePolygon(centroid, occludedUmbra, occludedUmbraLength)) {
-            hasOccludedUmbraArea = true;
-            // Shrink the occluded umbra area to avoid pixel level artifacts.
-            for (int i = 0; i < occludedUmbraLength; i ++) {
-                occludedUmbra[i] = centroid + (occludedUmbra[i] - centroid) *
-                        OCLLUDED_UMBRA_SHRINK_FACTOR;
-            }
-            if (!convertPolyToRayDist(occludedUmbra, occludedUmbraLength, centroid,
-                    occludedUmbraDistPerRay)) {
-                return;
-            }
-        }
-    }
-
-    AlphaVertex* shadowVertices =
-            shadowTriangleStrip.alloc<AlphaVertex>(SHADOW_VERTEX_COUNT);
-
-    // NOTE: Shadow alpha values are transformed when stored in alphavertices,
-    // so that they can be consumed directly by gFS_Main_ApplyVertexAlphaShadowInterp
-    float transformedMaxAlpha = M_PI;
-
-    // Calculate the vertices (x, y, alpha) in the shadow area.
-    AlphaVertex centroidXYA;
-    AlphaVertex::set(&centroidXYA, centroid.x, centroid.y, transformedMaxAlpha);
-    for (int rayIndex = 0; rayIndex < rays; rayIndex++) {
-        float dx = cosf(step * rayIndex);
-        float dy = sinf(step * rayIndex);
-
-        // penumbra ring
-        float penumbraDistance = penumbraDistPerRay[rayIndex];
-        AlphaVertex::set(&shadowVertices[rayIndex],
-                dx * penumbraDistance + centroid.x,
-                dy * penumbraDistance + centroid.y, 0.0f);
-
-        // umbra ring
-        float umbraDistance = umbraDistPerRay[rayIndex];
-        AlphaVertex::set(&shadowVertices[rays + rayIndex],
-                dx * umbraDistance + centroid.x,
-                dy * umbraDistance + centroid.y,
-                transformedMaxAlpha);
-
-        // occluded umbra ring
-        if (hasOccludedUmbraArea) {
-            float occludedUmbraDistance = occludedUmbraDistPerRay[rayIndex];
-            AlphaVertex::set(&shadowVertices[2 * rays + rayIndex],
-                    dx * occludedUmbraDistance + centroid.x,
-                    dy * occludedUmbraDistance + centroid.y, transformedMaxAlpha);
-        } else {
-            // Put all vertices of the occluded umbra ring at the centroid.
-            shadowVertices[2 * rays + rayIndex] = centroidXYA;
-        }
-    }
-
-    shadowTriangleStrip.setMode(VertexBuffer::kTwoPolyRingShadow);
-    shadowTriangleStrip.computeBounds<AlphaVertex>();
-}
-
 /**
  * This is only for experimental purpose.
  * After intersections are calculated, we could smooth the polygon if needed.
@@ -815,15 +889,656 @@
     }
 }
 
+/**
+ * Generate a array of the angleData for either umbra or penumbra vertices.
+ *
+ * This array will be merged and used to guide where to shoot the rays, in clockwise order.
+ *
+ * @param angleDataList The result array of angle data.
+ *
+ * @return int The maximum angle's index in the array.
+ */
+int SpotShadow::setupAngleList(VertexAngleData* angleDataList,
+        int polyLength, const Vector2* polygon, const Vector2& centroid,
+        bool isPenumbra, const char* name) {
+    float maxAngle = FLT_MIN;
+    int maxAngleIndex = 0;
+    for (int i = 0; i < polyLength; i++) {
+        float currentAngle = angle(polygon[i], centroid);
+        if (currentAngle > maxAngle) {
+            maxAngle = currentAngle;
+            maxAngleIndex = i;
+        }
+        angleDataList[i].set(currentAngle, isPenumbra, i);
+#if DEBUG_SHADOW
+        ALOGD("%s AngleList i %d %f", name, i, currentAngle);
+#endif
+    }
+    return maxAngleIndex;
+}
+
+/**
+ * Make sure the polygons are indeed in clockwise order.
+ *
+ * Possible reasons to return false: 1. The input polygon is not setup properly. 2. The hull
+ * algorithm is not able to generate it properly.
+ *
+ * Anyway, since the algorithm depends on the clockwise, when these kind of unexpected error
+ * situation is found, we need to detect it and early return without corrupting the memory.
+ *
+ * @return bool True if the angle list is actually from big to small.
+ */
+bool SpotShadow::checkClockwise(int indexOfMaxAngle, int listLength, VertexAngleData* angleList,
+        const char* name) {
+    int currentIndex = indexOfMaxAngle;
+#if DEBUG_SHADOW
+    ALOGD("max index %d", currentIndex);
+#endif
+    for (int i = 0; i < listLength - 1; i++) {
+        // TODO: Cache the last angle.
+        float currentAngle = angleList[currentIndex].mAngle;
+        float nextAngle = angleList[(currentIndex + 1) % listLength].mAngle;
+        if (currentAngle < nextAngle) {
+#if DEBUG_SHADOW
+            ALOGE("%s, is not CW, at index %d", name, currentIndex);
+#endif
+            return false;
+        }
+        currentIndex = (currentIndex + 1) % listLength;
+    }
+    return true;
+}
+
+/**
+ * Check the polygon is clockwise.
+ *
+ * @return bool True is the polygon is clockwise.
+ */
+bool SpotShadow::checkPolyClockwise(int polyAngleLength, int maxPolyAngleIndex,
+        const float* polyAngleList) {
+    bool isPolyCW = true;
+    // Starting from maxPolyAngleIndex , check around to make sure angle decrease.
+    for (int i = 0; i < polyAngleLength - 1; i++) {
+        float currentAngle = polyAngleList[(i + maxPolyAngleIndex) % polyAngleLength];
+        float nextAngle = polyAngleList[(i + maxPolyAngleIndex + 1) % polyAngleLength];
+        if (currentAngle < nextAngle) {
+            isPolyCW = false;
+        }
+    }
+    return isPolyCW;
+}
+
+/**
+ * Given the sorted array of all the vertices angle data, calculate for each
+ * vertices, the offset value to array element which represent the start edge
+ * of the polygon we need to shoot the ray at.
+ *
+ * TODO: Calculate this for umbra and penumbra in one loop using one single array.
+ *
+ * @param distances The result of the array distance counter.
+ */
+void SpotShadow::calculateDistanceCounter(bool needsOffsetToUmbra, int angleLength,
+        const VertexAngleData* allVerticesAngleData, int* distances) {
+
+    bool firstVertexIsPenumbra = allVerticesAngleData[0].mIsPenumbra;
+    // If we want distance to inner, then we just set to 0 when we see inner.
+    bool needsSearch = needsOffsetToUmbra ? firstVertexIsPenumbra : !firstVertexIsPenumbra;
+    int distanceCounter = 0;
+    if (needsSearch) {
+        int foundIndex = -1;
+        for (int i = (angleLength - 1); i >= 0; i--) {
+            bool currentIsOuter = allVerticesAngleData[i].mIsPenumbra;
+            // If we need distance to inner, then we need to find a inner vertex.
+            if (currentIsOuter != firstVertexIsPenumbra) {
+                foundIndex = i;
+                break;
+            }
+        }
+        LOG_ALWAYS_FATAL_IF(foundIndex == -1, "Wrong index found, means either"
+                " umbra or penumbra's length is 0");
+        distanceCounter = angleLength - foundIndex;
+    }
+#if DEBUG_SHADOW
+    ALOGD("distances[0] is %d", distanceCounter);
+#endif
+
+    distances[0] = distanceCounter; // means never see a target poly
+
+    for (int i = 1; i < angleLength; i++) {
+        bool firstVertexIsPenumbra = allVerticesAngleData[i].mIsPenumbra;
+        // When we needs for distance for each outer vertex to inner, then we
+        // increase the distance when seeing outer vertices. Otherwise, we clear
+        // to 0.
+        bool needsIncrement = needsOffsetToUmbra ? firstVertexIsPenumbra : !firstVertexIsPenumbra;
+        // If counter is not -1, that means we have seen an other polygon's vertex.
+        if (needsIncrement && distanceCounter != -1) {
+            distanceCounter++;
+        } else {
+            distanceCounter = 0;
+        }
+        distances[i] = distanceCounter;
+    }
+}
+
+/**
+ * Given umbra and penumbra angle data list, merge them by sorting the angle
+ * from the biggest to smallest.
+ *
+ * @param allVerticesAngleData The result array of merged angle data.
+ */
+void SpotShadow::mergeAngleList(int maxUmbraAngleIndex, int maxPenumbraAngleIndex,
+        const VertexAngleData* umbraAngleList, int umbraLength,
+        const VertexAngleData* penumbraAngleList, int penumbraLength,
+        VertexAngleData* allVerticesAngleData) {
+
+    int totalRayNumber = umbraLength + penumbraLength;
+    int umbraIndex = maxUmbraAngleIndex;
+    int penumbraIndex = maxPenumbraAngleIndex;
+
+    float currentUmbraAngle = umbraAngleList[umbraIndex].mAngle;
+    float currentPenumbraAngle = penumbraAngleList[penumbraIndex].mAngle;
+
+    // TODO: Clean this up using a while loop with 2 iterators.
+    for (int i = 0; i < totalRayNumber; i++) {
+        if (currentUmbraAngle > currentPenumbraAngle) {
+            allVerticesAngleData[i] = umbraAngleList[umbraIndex];
+            umbraIndex = (umbraIndex + 1) % umbraLength;
+
+            // If umbraIndex round back, that means we are running out of
+            // umbra vertices to merge, so just copy all the penumbra leftover.
+            // Otherwise, we update the currentUmbraAngle.
+            if (umbraIndex != maxUmbraAngleIndex) {
+                currentUmbraAngle = umbraAngleList[umbraIndex].mAngle;
+            } else {
+                for (int j = i + 1; j < totalRayNumber; j++) {
+                    allVerticesAngleData[j] = penumbraAngleList[penumbraIndex];
+                    penumbraIndex = (penumbraIndex + 1) % penumbraLength;
+                }
+                break;
+            }
+        } else {
+            allVerticesAngleData[i] = penumbraAngleList[penumbraIndex];
+            penumbraIndex = (penumbraIndex + 1) % penumbraLength;
+            // If penumbraIndex round back, that means we are running out of
+            // penumbra vertices to merge, so just copy all the umbra leftover.
+            // Otherwise, we update the currentPenumbraAngle.
+            if (penumbraIndex != maxPenumbraAngleIndex) {
+                currentPenumbraAngle = penumbraAngleList[penumbraIndex].mAngle;
+            } else {
+                for (int j = i + 1; j < totalRayNumber; j++) {
+                    allVerticesAngleData[j] = umbraAngleList[umbraIndex];
+                    umbraIndex = (umbraIndex + 1) % umbraLength;
+                }
+                break;
+            }
+        }
+    }
+}
+
+#if DEBUG_SHADOW
+/**
+ * DEBUG ONLY: Verify all the offset compuation is correctly done by examining
+ * each vertex and its neighbor.
+ */
+static void verifyDistanceCounter(const VertexAngleData* allVerticesAngleData,
+        const int* distances, int angleLength, const char* name) {
+    int currentDistance = distances[0];
+    for (int i = 1; i < angleLength; i++) {
+        if (distances[i] != INT_MIN) {
+            if (!((currentDistance + 1) == distances[i]
+                || distances[i] == 0)) {
+                ALOGE("Wrong distance found at i %d name %s", i, name);
+            }
+            currentDistance = distances[i];
+            if (currentDistance != 0) {
+                bool currentOuter = allVerticesAngleData[i].mIsPenumbra;
+                for (int j = 1; j <= (currentDistance - 1); j++) {
+                    bool neigborOuter =
+                            allVerticesAngleData[(i + angleLength - j) % angleLength].mIsPenumbra;
+                    if (neigborOuter != currentOuter) {
+                        ALOGE("Wrong distance found at i %d name %s", i, name);
+                    }
+                }
+                bool oppositeOuter =
+                    allVerticesAngleData[(i + angleLength - currentDistance) % angleLength].mIsPenumbra;
+                if (oppositeOuter == currentOuter) {
+                    ALOGE("Wrong distance found at i %d name %s", i, name);
+                }
+            }
+        }
+    }
+}
+
+/**
+ * DEBUG ONLY: Verify all the angle data compuated are  is correctly done
+ */
+static void verifyAngleData(int totalRayNumber, const VertexAngleData* allVerticesAngleData,
+        const int* distancesToInner, const int* distancesToOuter,
+        const VertexAngleData* umbraAngleList, int maxUmbraAngleIndex, int umbraLength,
+        const VertexAngleData* penumbraAngleList, int maxPenumbraAngleIndex,
+        int penumbraLength) {
+    for (int i = 0; i < totalRayNumber; i++) {
+        ALOGD("currentAngleList i %d, angle %f, isInner %d, index %d distancesToInner"
+              " %d distancesToOuter %d", i, allVerticesAngleData[i].mAngle,
+                !allVerticesAngleData[i].mIsPenumbra,
+                allVerticesAngleData[i].mVertexIndex, distancesToInner[i], distancesToOuter[i]);
+    }
+
+    verifyDistanceCounter(allVerticesAngleData, distancesToInner, totalRayNumber, "distancesToInner");
+    verifyDistanceCounter(allVerticesAngleData, distancesToOuter, totalRayNumber, "distancesToOuter");
+
+    for (int i = 0; i < totalRayNumber; i++) {
+        if ((distancesToInner[i] * distancesToOuter[i]) != 0) {
+            ALOGE("distancesToInner wrong at index %d distancesToInner[i] %d,"
+                    " distancesToOuter[i] %d", i, distancesToInner[i], distancesToOuter[i]);
+        }
+    }
+    int currentUmbraVertexIndex =
+            umbraAngleList[maxUmbraAngleIndex].mVertexIndex;
+    int currentPenumbraVertexIndex =
+            penumbraAngleList[maxPenumbraAngleIndex].mVertexIndex;
+    for (int i = 0; i < totalRayNumber; i++) {
+        if (allVerticesAngleData[i].mIsPenumbra == true) {
+            if (allVerticesAngleData[i].mVertexIndex != currentPenumbraVertexIndex) {
+                ALOGW("wrong penumbra indexing i %d allVerticesAngleData[i].mVertexIndex %d "
+                        "currentpenumbraVertexIndex %d", i,
+                        allVerticesAngleData[i].mVertexIndex, currentPenumbraVertexIndex);
+            }
+            currentPenumbraVertexIndex = (currentPenumbraVertexIndex + 1) % penumbraLength;
+        } else {
+            if (allVerticesAngleData[i].mVertexIndex != currentUmbraVertexIndex) {
+                ALOGW("wrong umbra indexing i %d allVerticesAngleData[i].mVertexIndex %d "
+                        "currentUmbraVertexIndex %d", i,
+                        allVerticesAngleData[i].mVertexIndex, currentUmbraVertexIndex);
+            }
+            currentUmbraVertexIndex = (currentUmbraVertexIndex + 1) % umbraLength;
+        }
+    }
+    for (int i = 0; i < totalRayNumber - 1; i++) {
+        float currentAngle = allVerticesAngleData[i].mAngle;
+        float nextAngle = allVerticesAngleData[(i + 1) % totalRayNumber].mAngle;
+        if (currentAngle < nextAngle) {
+            ALOGE("Unexpected angle values!, currentAngle nextAngle %f %f", currentAngle, nextAngle);
+        }
+    }
+}
+#endif
+
+/**
+ * In order to compute the occluded umbra, we need to setup the angle data list
+ * for the polygon data. Since we only store one poly vertex per polygon vertex,
+ * this array only needs to be a float array which are the angles for each vertex.
+ *
+ * @param polyAngleList The result list
+ *
+ * @return int The index for the maximum angle in this array.
+ */
+int SpotShadow::setupPolyAngleList(float* polyAngleList, int polyAngleLength,
+        const Vector2* poly2d, const Vector2& centroid) {
+    int maxPolyAngleIndex = -1;
+    float maxPolyAngle = -FLT_MAX;
+    for (int i = 0; i < polyAngleLength; i++) {
+        polyAngleList[i] = angle(poly2d[i], centroid);
+        if (polyAngleList[i] > maxPolyAngle) {
+            maxPolyAngle = polyAngleList[i];
+            maxPolyAngleIndex = i;
+        }
+    }
+    return maxPolyAngleIndex;
+}
+
+/**
+ * For umbra and penumbra, given the offset info and the current ray number,
+ * find the right edge index (the (starting vertex) for the ray to shoot at.
+ *
+ * @return int The index of the starting vertex of the edge.
+ */
+inline int SpotShadow::getEdgeStartIndex(const int* offsets, int rayIndex, int totalRayNumber,
+        const VertexAngleData* allVerticesAngleData) {
+    int tempOffset = offsets[rayIndex];
+    int targetRayIndex = (rayIndex - tempOffset + totalRayNumber) % totalRayNumber;
+    return allVerticesAngleData[targetRayIndex].mVertexIndex;
+}
+
+/**
+ * For the occluded umbra, given the array of angles, find the index of the
+ * starting vertex of the edge, for the ray to shoo at.
+ *
+ * TODO: Save the last result to shorten the search distance.
+ *
+ * @return int The index of the starting vertex of the edge.
+ */
+inline int SpotShadow::getPolyEdgeStartIndex(int maxPolyAngleIndex, int polyLength,
+        const float* polyAngleList, float rayAngle) {
+    int minPolyAngleIndex  = (maxPolyAngleIndex + polyLength - 1) % polyLength;
+    int resultIndex = -1;
+    if (rayAngle > polyAngleList[maxPolyAngleIndex]
+        || rayAngle <= polyAngleList[minPolyAngleIndex]) {
+        resultIndex = minPolyAngleIndex;
+    } else {
+        for (int i = 0; i < polyLength - 1; i++) {
+            int currentIndex = (maxPolyAngleIndex + i) % polyLength;
+            int nextIndex = (maxPolyAngleIndex + i + 1) % polyLength;
+            if (rayAngle <= polyAngleList[currentIndex]
+                && rayAngle > polyAngleList[nextIndex]) {
+                resultIndex = currentIndex;
+            }
+        }
+    }
+    if (CC_UNLIKELY(resultIndex == -1)) {
+        // TODO: Add more error handling here.
+        ALOGE("Wrong index found, means no edge can't be found for rayAngle %f", rayAngle);
+    }
+    return resultIndex;
+}
+
+/**
+ * Convert the incoming polygons into arrays of vertices, for each ray.
+ * Ray only shoots when there is one vertex either on penumbra on umbra.
+ *
+ * Finally, it will generate vertices per ray for umbra, penumbra and optionally
+ * occludedUmbra.
+ *
+ * Return true (success) when all vertices are generated
+ */
+int SpotShadow::convertPolysToVerticesPerRay(
+        bool hasOccludedUmbraArea, const Vector2* poly2d, int polyLength,
+        const Vector2* umbra, int umbraLength, const Vector2* penumbra,
+        int penumbraLength, const Vector2& centroid,
+        Vector2* umbraVerticesPerRay, Vector2* penumbraVerticesPerRay,
+        Vector2* occludedUmbraVerticesPerRay) {
+    int totalRayNumber = umbraLength + penumbraLength;
+
+    // For incoming umbra / penumbra polygons, we will build an intermediate data
+    // structure to help us sort all the vertices according to the vertices.
+    // Using this data structure, we can tell where (the angle) to shoot the ray,
+    // whether we shoot at penumbra edge or umbra edge, and which edge to shoot at.
+    //
+    // We first parse each vertices and generate a table of VertexAngleData.
+    // Based on that, we create 2 arrays telling us which edge to shoot at.
+    VertexAngleData allVerticesAngleData[totalRayNumber];
+    VertexAngleData umbraAngleList[umbraLength];
+    VertexAngleData penumbraAngleList[penumbraLength];
+
+    int polyAngleLength = hasOccludedUmbraArea ? polyLength : 0;
+    float polyAngleList[polyAngleLength];
+
+    const int maxUmbraAngleIndex =
+            setupAngleList(umbraAngleList, umbraLength, umbra, centroid, false, "umbra");
+    const int maxPenumbraAngleIndex =
+            setupAngleList(penumbraAngleList, penumbraLength, penumbra, centroid, true, "penumbra");
+    const int maxPolyAngleIndex = setupPolyAngleList(polyAngleList, polyAngleLength, poly2d, centroid);
+
+    // Check all the polygons here are CW.
+    bool isPolyCW = checkPolyClockwise(polyAngleLength, maxPolyAngleIndex, polyAngleList);
+    bool isUmbraCW = checkClockwise(maxUmbraAngleIndex, umbraLength,
+            umbraAngleList, "umbra");
+    bool isPenumbraCW = checkClockwise(maxPenumbraAngleIndex, penumbraLength,
+            penumbraAngleList, "penumbra");
+
+    if (!isUmbraCW || !isPenumbraCW || !isPolyCW) {
+#if DEBUG_SHADOW
+        ALOGE("One polygon is not CW isUmbraCW %d isPenumbraCW %d isPolyCW %d",
+                isUmbraCW, isPenumbraCW, isPolyCW);
+#endif
+        return false;
+    }
+
+    mergeAngleList(maxUmbraAngleIndex, maxPenumbraAngleIndex,
+            umbraAngleList, umbraLength, penumbraAngleList, penumbraLength,
+            allVerticesAngleData);
+
+    // Calculate the offset to the left most Inner vertex for each outerVertex.
+    // Then the offset to the left most Outer vertex for each innerVertex.
+    int offsetToInner[totalRayNumber];
+    int offsetToOuter[totalRayNumber];
+    calculateDistanceCounter(true, totalRayNumber, allVerticesAngleData, offsetToInner);
+    calculateDistanceCounter(false, totalRayNumber, allVerticesAngleData, offsetToOuter);
+
+    // Generate both umbraVerticesPerRay and penumbraVerticesPerRay
+    for (int i = 0; i < totalRayNumber; i++) {
+        float rayAngle = allVerticesAngleData[i].mAngle;
+        bool isUmbraVertex = !allVerticesAngleData[i].mIsPenumbra;
+
+        float dx = cosf(rayAngle);
+        float dy = sinf(rayAngle);
+        float distanceToIntersectUmbra = -1;
+
+        if (isUmbraVertex) {
+            // We can just copy umbra easily, and calculate the distance for the
+            // occluded umbra computation.
+            int startUmbraIndex = allVerticesAngleData[i].mVertexIndex;
+            umbraVerticesPerRay[i] = umbra[startUmbraIndex];
+            if (hasOccludedUmbraArea) {
+                distanceToIntersectUmbra = (umbraVerticesPerRay[i] - centroid).length();
+            }
+
+            //shoot ray to penumbra only
+            int startPenumbraIndex = getEdgeStartIndex(offsetToOuter, i, totalRayNumber,
+                    allVerticesAngleData);
+            float distanceToIntersectPenumbra = rayIntersectPoints(centroid, dx, dy,
+                    penumbra[startPenumbraIndex],
+                    penumbra[(startPenumbraIndex + 1) % penumbraLength]);
+            if (distanceToIntersectPenumbra < 0) {
+#if DEBUG_SHADOW
+                ALOGW("convertPolyToRayDist for penumbra failed rayAngle %f dx %f dy %f",
+                        rayAngle, dx, dy);
+#endif
+                distanceToIntersectPenumbra = 0;
+            }
+            penumbraVerticesPerRay[i].x = centroid.x + dx * distanceToIntersectPenumbra;
+            penumbraVerticesPerRay[i].y = centroid.y + dy * distanceToIntersectPenumbra;
+        } else {
+            // We can just copy the penumbra
+            int startPenumbraIndex = allVerticesAngleData[i].mVertexIndex;
+            penumbraVerticesPerRay[i] = penumbra[startPenumbraIndex];
+
+            // And shoot ray to umbra only
+            int startUmbraIndex = getEdgeStartIndex(offsetToInner, i, totalRayNumber,
+                    allVerticesAngleData);
+
+            distanceToIntersectUmbra = rayIntersectPoints(centroid, dx, dy,
+                    umbra[startUmbraIndex], umbra[(startUmbraIndex + 1) % umbraLength]);
+            if (distanceToIntersectUmbra < 0) {
+#if DEBUG_SHADOW
+                ALOGW("convertPolyToRayDist for umbra failed rayAngle %f dx %f dy %f",
+                        rayAngle, dx, dy);
+#endif
+                distanceToIntersectUmbra = 0;
+            }
+            umbraVerticesPerRay[i].x = centroid.x + dx * distanceToIntersectUmbra;
+            umbraVerticesPerRay[i].y = centroid.y + dy * distanceToIntersectUmbra;
+        }
+
+        if (hasOccludedUmbraArea) {
+            // Shoot the same ray to the poly2d, and get the distance.
+            int startPolyIndex = getPolyEdgeStartIndex(maxPolyAngleIndex, polyLength,
+                    polyAngleList, rayAngle);
+
+            float distanceToIntersectPoly = rayIntersectPoints(centroid, dx, dy,
+                    poly2d[startPolyIndex], poly2d[(startPolyIndex + 1) % polyLength]);
+            if (distanceToIntersectPoly < 0) {
+                distanceToIntersectPoly = 0;
+            }
+            distanceToIntersectPoly = MathUtils::min(distanceToIntersectUmbra, distanceToIntersectPoly);
+            occludedUmbraVerticesPerRay[i].x = centroid.x + dx * distanceToIntersectPoly;
+            occludedUmbraVerticesPerRay[i].y = centroid.y + dy * distanceToIntersectPoly;
+        }
+    }
+
+#if DEBUG_SHADOW
+    verifyAngleData(totalRayNumber, allVerticesAngleData, offsetToInner,
+            offsetToOuter,  umbraAngleList, maxUmbraAngleIndex,  umbraLength,
+            penumbraAngleList,  maxPenumbraAngleIndex, penumbraLength);
+#endif
+    return true; // success
+
+}
+
+/**
+ * Generate a triangle strip given two convex polygon
+**/
+void SpotShadow::generateTriangleStrip(bool isCasterOpaque, float shadowStrengthScale,
+        Vector2* penumbra, int penumbraLength, Vector2* umbra, int umbraLength,
+        const Vector3* poly, int polyLength, VertexBuffer& shadowTriangleStrip,
+        const Vector2& centroid) {
+
+    bool hasOccludedUmbraArea = false;
+    Vector2 poly2d[polyLength];
+
+    if (isCasterOpaque) {
+        for (int i = 0; i < polyLength; i++) {
+            poly2d[i].x = poly[i].x;
+            poly2d[i].y = poly[i].y;
+        }
+        // Make sure the centroid is inside the umbra, otherwise, fall back to the
+        // approach as if there is no occluded umbra area.
+        if (testPointInsidePolygon(centroid, poly2d, polyLength)) {
+            hasOccludedUmbraArea = true;
+        }
+    }
+
+    int totalRayNum = umbraLength + penumbraLength;
+    Vector2 umbraVertices[totalRayNum];
+    Vector2 penumbraVertices[totalRayNum];
+    Vector2 occludedUmbraVertices[totalRayNum];
+    bool convertSuccess = convertPolysToVerticesPerRay(hasOccludedUmbraArea, poly2d,
+            polyLength, umbra, umbraLength, penumbra, penumbraLength,
+            centroid, umbraVertices, penumbraVertices, occludedUmbraVertices);
+    if (!convertSuccess) {
+        return;
+    }
+
+    // Minimal value is 1, for each vertex show up once.
+    // The bigger this value is , the smoother the look is, but more memory
+    // is consumed.
+    // When the ray number is high, that means the polygon has been fine
+    // tessellated, we don't need this extra slice, just keep it as 1.
+    int sliceNumberPerEdge = (totalRayNum > FINE_TESSELLATED_POLYGON_RAY_NUMBER) ? 1 : 2;
+
+    // For each polygon, we at most add (totalRayNum * sliceNumberPerEdge) vertices.
+    int slicedVertexCountPerPolygon = totalRayNum * sliceNumberPerEdge;
+    int totalVertexCount = slicedVertexCountPerPolygon * 2 + totalRayNum;
+    int totalIndexCount = 2 * (slicedVertexCountPerPolygon * 2 + 2);
+    AlphaVertex* shadowVertices =
+            shadowTriangleStrip.alloc<AlphaVertex>(totalVertexCount);
+    uint16_t* indexBuffer =
+            shadowTriangleStrip.allocIndices<uint16_t>(totalIndexCount);
+
+    int indexBufferIndex = 0;
+    int vertexBufferIndex = 0;
+
+    uint16_t slicedUmbraVertexIndex[totalRayNum * sliceNumberPerEdge];
+    // Should be something like 0 0 0  1 1 1 2 3 3 3...
+    int rayNumberPerSlicedUmbra[totalRayNum * sliceNumberPerEdge];
+    int realUmbraVertexCount = 0;
+    for (int i = 0; i < totalRayNum; i++) {
+        Vector2 currentPenumbra = penumbraVertices[i];
+        Vector2 currentUmbra = umbraVertices[i];
+
+        Vector2 nextPenumbra = penumbraVertices[(i + 1) % totalRayNum];
+        Vector2 nextUmbra = umbraVertices[(i + 1) % totalRayNum];
+        // NextUmbra/Penumbra will be done in the next loop!!
+        for (int weight = 0; weight < sliceNumberPerEdge; weight++) {
+            const Vector2& slicedPenumbra = (currentPenumbra * (sliceNumberPerEdge - weight)
+                + nextPenumbra * weight) / sliceNumberPerEdge;
+
+            const Vector2& slicedUmbra = (currentUmbra * (sliceNumberPerEdge - weight)
+                + nextUmbra * weight) / sliceNumberPerEdge;
+
+            // In the vertex buffer, we fill the Penumbra first, then umbra.
+            indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+            AlphaVertex::set(&shadowVertices[vertexBufferIndex++], slicedPenumbra.x,
+                    slicedPenumbra.y, 0.0f);
+
+            // When we add umbra vertex, we need to remember its current ray number.
+            // And its own vertexBufferIndex. This is for occluded umbra usage.
+            indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+            rayNumberPerSlicedUmbra[realUmbraVertexCount] = i;
+            slicedUmbraVertexIndex[realUmbraVertexCount] = vertexBufferIndex;
+            realUmbraVertexCount++;
+            AlphaVertex::set(&shadowVertices[vertexBufferIndex++], slicedUmbra.x,
+                    slicedUmbra.y, M_PI);
+        }
+    }
+
+    indexBuffer[indexBufferIndex++] = 0;
+    //RealUmbraVertexIndex[0] must be 1, so we connect back well at the
+    //beginning of occluded area.
+    indexBuffer[indexBufferIndex++] = 1;
+
+    float occludedUmbraAlpha = M_PI;
+    if (hasOccludedUmbraArea) {
+        // Now the occludedUmbra area;
+        int currentRayNumber = -1;
+        int firstOccludedUmbraIndex = -1;
+        for (int i = 0; i < realUmbraVertexCount; i++) {
+            indexBuffer[indexBufferIndex++] = slicedUmbraVertexIndex[i];
+
+            // If the occludedUmbra vertex has not been added yet, then add it.
+            // Otherwise, just use the previously added occludedUmbra vertices.
+            if (rayNumberPerSlicedUmbra[i] != currentRayNumber) {
+                currentRayNumber++;
+                indexBuffer[indexBufferIndex++] = vertexBufferIndex;
+                // We need to remember the begining of the occludedUmbra vertices
+                // to close this loop.
+                if (currentRayNumber == 0) {
+                    firstOccludedUmbraIndex = vertexBufferIndex;
+                }
+                AlphaVertex::set(&shadowVertices[vertexBufferIndex++],
+                        occludedUmbraVertices[currentRayNumber].x,
+                        occludedUmbraVertices[currentRayNumber].y,
+                        occludedUmbraAlpha);
+            } else {
+                indexBuffer[indexBufferIndex++] = (vertexBufferIndex - 1);
+            }
+        }
+        // Close the loop here!
+        indexBuffer[indexBufferIndex++] = slicedUmbraVertexIndex[0];
+        indexBuffer[indexBufferIndex++] = firstOccludedUmbraIndex;
+    } else {
+        int lastCentroidIndex = vertexBufferIndex;
+        AlphaVertex::set(&shadowVertices[vertexBufferIndex++], centroid.x,
+                centroid.y, occludedUmbraAlpha);
+        for (int i = 0; i < realUmbraVertexCount; i++) {
+            indexBuffer[indexBufferIndex++] = slicedUmbraVertexIndex[i];
+            indexBuffer[indexBufferIndex++] = lastCentroidIndex;
+        }
+        // Close the loop here!
+        indexBuffer[indexBufferIndex++] = slicedUmbraVertexIndex[0];
+        indexBuffer[indexBufferIndex++] = lastCentroidIndex;
+    }
+
+#if DEBUG_SHADOW
+    ALOGD("allocated IB %d allocated VB is %d", totalIndexCount, totalVertexCount);
+    ALOGD("IB index %d VB index is %d", indexBufferIndex, vertexBufferIndex);
+    for (int i = 0; i < vertexBufferIndex; i++) {
+        ALOGD("vertexBuffer i %d, (%f, %f %f)", i, shadowVertices[i].x, shadowVertices[i].y,
+                shadowVertices[i].alpha);
+    }
+    for (int i = 0; i < indexBufferIndex; i++) {
+        ALOGD("indexBuffer i %d, indexBuffer[i] %d", i, indexBuffer[i]);
+    }
+#endif
+
+    // At the end, update the real index and vertex buffer size.
+    shadowTriangleStrip.updateVertexCount(vertexBufferIndex);
+    shadowTriangleStrip.updateIndexCount(indexBufferIndex);
+    ShadowTessellator::checkOverflow(vertexBufferIndex, totalVertexCount, "Spot Vertex Buffer");
+    ShadowTessellator::checkOverflow(indexBufferIndex, totalIndexCount, "Spot Index Buffer");
+
+    shadowTriangleStrip.setMode(VertexBuffer::kIndices);
+    shadowTriangleStrip.computeBounds<AlphaVertex>();
+}
+
 #if DEBUG_SHADOW
 
 #define TEST_POINT_NUMBER 128
-
 /**
  * Calculate the bounds for generating random test points.
  */
 void SpotShadow::updateBound(const Vector2 inVector, Vector2& lowerBound,
-        Vector2& upperBound ) {
+        Vector2& upperBound) {
     if (inVector.x < lowerBound.x) {
         lowerBound.x = inVector.x;
     }
@@ -844,7 +1559,16 @@
 /**
  * For debug purpose, when things go wrong, dump the whole polygon data.
  */
-static void dumpPolygon(const Vector2* poly, int polyLength, const char* polyName) {
+void SpotShadow::dumpPolygon(const Vector2* poly, int polyLength, const char* polyName) {
+    for (int i = 0; i < polyLength; i++) {
+        ALOGD("polygon %s i %d x %f y %f", polyName, i, poly[i].x, poly[i].y);
+    }
+}
+
+/**
+ * For debug purpose, when things go wrong, dump the whole polygon data.
+ */
+void SpotShadow::dumpPolygon(const Vector3* poly, int polyLength, const char* polyName) {
     for (int i = 0; i < polyLength; i++) {
         ALOGD("polygon %s i %d x %f y %f", polyName, i, poly[i].x, poly[i].y);
     }
@@ -885,8 +1609,8 @@
         const Vector2* poly2, int poly2Length,
         const Vector2* intersection, int intersectionLength) {
     // Find the min and max of x and y.
-    Vector2 lowerBound(FLT_MAX, FLT_MAX);
-    Vector2 upperBound(-FLT_MAX, -FLT_MAX);
+    Vector2 lowerBound = {FLT_MAX, FLT_MAX};
+    Vector2 upperBound = {-FLT_MAX, -FLT_MAX};
     for (int i = 0; i < poly1Length; i++) {
         updateBound(poly1[i], lowerBound, upperBound);
     }
@@ -909,14 +1633,14 @@
             if (!testPointInsidePolygon(testPoint, poly1, poly1Length)) {
                 dumpPoly = true;
                 ALOGW("(Error Type 1): one point (%f, %f) in the intersection is"
-                      " not in the poly1",
+                        " not in the poly1",
                         testPoint.x, testPoint.y);
             }
 
             if (!testPointInsidePolygon(testPoint, poly2, poly2Length)) {
                 dumpPoly = true;
                 ALOGW("(Error Type 1): one point (%f, %f) in the intersection is"
-                      " not in the poly2",
+                        " not in the poly2",
                         testPoint.x, testPoint.y);
             }
         }
diff --git a/libs/hwui/SpotShadow.h b/libs/hwui/SpotShadow.h
index d65ea89..23fdca9 100644
--- a/libs/hwui/SpotShadow.h
+++ b/libs/hwui/SpotShadow.h
@@ -26,16 +26,51 @@
 
 class SpotShadow {
 public:
-    static void createSpotShadow(bool isCasterOpaque, const Vector3* poly,
-            int polyLength, const Vector3& lightCenter, float lightSize,
-            int lightVertexCount, VertexBuffer& retStrips);
+    static void createSpotShadow(bool isCasterOpaque, const Vector3& lightCenter,
+            float lightSize, const Vector3* poly, int polyLength,
+            const Vector3& polyCentroid, VertexBuffer& retstrips);
 
 private:
+    struct VertexAngleData;
+
+    static float projectCasterToOutline(Vector2& outline,
+            const Vector3& lightCenter, const Vector3& polyVertex);
     static int calculateOccludedUmbra(const Vector2* umbra, int umbraLength,
             const Vector3* poly, int polyLength, Vector2* occludedUmbra);
-    static void computeSpotShadow(bool isCasterOpaque, const Vector3* lightPoly,
-            int lightPolyLength, const Vector3& lightCenter, const Vector3* poly,
-            int polyLength, VertexBuffer& retstrips);
+
+    static int setupAngleList(VertexAngleData* angleDataList,
+            int polyLength, const Vector2* polygon, const Vector2& centroid,
+            bool isPenumbra, const char* name);
+
+    static int convertPolysToVerticesPerRay(
+            bool hasOccludedUmbraArea, const Vector2* poly2d, int polyLength,
+            const Vector2* umbra, int umbraLength, const Vector2* penumbra,
+            int penumbraLength, const Vector2& centroid,
+            Vector2* umbraVerticesPerRay, Vector2* penumbraVerticesPerRay,
+            Vector2* occludedUmbraVerticesPerRay);
+
+    static bool checkClockwise(int maxIndex, int listLength,
+            VertexAngleData* angleList, const char* name);
+
+    static void calculateDistanceCounter(bool needsOffsetToUmbra, int angleLength,
+            const VertexAngleData* allVerticesAngleData, int* distances);
+
+    static void mergeAngleList(int maxUmbraAngleIndex, int maxPenumbraAngleIndex,
+            const VertexAngleData* umbraAngleList, int umbraLength,
+            const VertexAngleData* penumbraAngleList, int penumbraLength,
+            VertexAngleData* allVerticesAngleData);
+
+    static int setupPolyAngleList(float* polyAngleList, int polyAngleLength,
+        const Vector2* poly2d, const Vector2& centroid);
+
+    static bool checkPolyClockwise(int polyAngleLength, int maxPolyAngleIndex,
+        const float* polyAngleList);
+
+    static int getEdgeStartIndex(const int* offsets, int rayIndex, int totalRayNumber,
+        const VertexAngleData* allVerticesAngleData);
+
+    static int getPolyEdgeStartIndex(int maxPolyAngleIndex, int polyLength,
+        const float* polyAngleList, float rayAngle);
 
     static void computeLightPolygon(int points, const Vector3& lightCenter,
             float size, Vector3* ret);
@@ -60,18 +95,19 @@
     static inline bool lineIntersection(double x1, double y1, double x2, double y2,
             double x3, double y3, double x4, double y4, Vector2& ret);
 
-    static void generateTriangleStrip(bool isCasterOpaque, const Vector2* penumbra,
-            int penumbraLength, const Vector2* umbra, int umbraLength,
-            const Vector3* poly, int polyLength, VertexBuffer& retstrips);
+    static void generateTriangleStrip(bool isCasterOpaque, float shadowStrengthScale,
+            Vector2* penumbra, int penumbraLength, Vector2* umbra, int umbraLength,
+            const Vector3* poly, int polyLength, VertexBuffer& retstrips, const Vector2& centroid);
 
 #if DEBUG_SHADOW
-    // Verification utility function.
     static bool testConvex(const Vector2* polygon, int polygonLength,
             const char* name);
     static void testIntersection(const Vector2* poly1, int poly1Length,
         const Vector2* poly2, int poly2Length,
         const Vector2* intersection, int intersectionLength);
     static void updateBound(const Vector2 inVector, Vector2& lowerBound, Vector2& upperBound );
+    static void dumpPolygon(const Vector2* poly, int polyLength, const char* polyName);
+    static void dumpPolygon(const Vector3* poly, int polyLength, const char* polyName);
 #endif
 
 }; // SpotShadow
diff --git a/libs/hwui/StatefulBaseRenderer.cpp b/libs/hwui/StatefulBaseRenderer.cpp
index 06c5ab4..12b8c8d 100644
--- a/libs/hwui/StatefulBaseRenderer.cpp
+++ b/libs/hwui/StatefulBaseRenderer.cpp
@@ -102,10 +102,6 @@
 // Matrix
 ///////////////////////////////////////////////////////////////////////////////
 
-void StatefulBaseRenderer::getMatrix(Matrix4* matrix) const {
-    matrix->load(*(mSnapshot->transform));
-}
-
 void StatefulBaseRenderer::getMatrix(SkMatrix* matrix) const {
     mSnapshot->transform->copyTo(*matrix);
 }
@@ -196,17 +192,19 @@
     float radius;
     if (!outline->getAsRoundRect(&bounds, &radius)) return; // only RR supported
 
-    if (!MathUtils::isPositive(radius)) {
+    bool outlineIsRounded = MathUtils::isPositive(radius);
+    if (!outlineIsRounded || currentTransform()->isSimple()) {
         // TODO: consider storing this rect separately, so that this can't be replaced with clip ops
         clipRect(bounds.left, bounds.top, bounds.right, bounds.bottom, SkRegion::kIntersect_Op);
-        return;
     }
-    setClippingRoundRect(allocator, bounds, radius);
+    if (outlineIsRounded) {
+        setClippingRoundRect(allocator, bounds, radius, false);
+    }
 }
 
 void StatefulBaseRenderer::setClippingRoundRect(LinearAllocator& allocator,
-        const Rect& rect, float radius) {
-    mSnapshot->setClippingRoundRect(allocator, rect, radius);
+        const Rect& rect, float radius, bool highPriority) {
+    mSnapshot->setClippingRoundRect(allocator, rect, radius, highPriority);
 }
 
 
diff --git a/libs/hwui/StatefulBaseRenderer.h b/libs/hwui/StatefulBaseRenderer.h
index 3957d36..745e48a 100644
--- a/libs/hwui/StatefulBaseRenderer.h
+++ b/libs/hwui/StatefulBaseRenderer.h
@@ -69,7 +69,6 @@
     //        int alpha, SkXfermode::Mode mode, int flags);
 
     // Matrix
-    void getMatrix(Matrix4* outMatrix) const;
     virtual void getMatrix(SkMatrix* outMatrix) const;
     virtual void translate(float dx, float dy, float dz = 0.0f);
     virtual void rotate(float degrees);
@@ -98,7 +97,11 @@
      */
     void setClippingOutline(LinearAllocator& allocator, const Outline* outline);
     void setClippingRoundRect(LinearAllocator& allocator,
-            const Rect& rect, float radius);
+            const Rect& rect, float radius, bool highPriority = true);
+
+    inline const mat4* currentTransform() const {
+        return mSnapshot->transform;
+    }
 
 protected:
     const Rect& getRenderTargetClipBounds() const { return mSnapshot->getRenderTargetClip(); }
@@ -134,10 +137,6 @@
         return mSnapshot->clipRect;
     }
 
-    inline const mat4* currentTransform() const {
-        return mSnapshot->transform;
-    }
-
     inline const Snapshot* currentSnapshot() const {
         return mSnapshot != NULL ? mSnapshot.get() : mFirstSnapshot.get();
     }
diff --git a/libs/hwui/TessellationCache.cpp b/libs/hwui/TessellationCache.cpp
index 0a9aeb8..1e38f9e 100644
--- a/libs/hwui/TessellationCache.cpp
+++ b/libs/hwui/TessellationCache.cpp
@@ -216,7 +216,7 @@
 
     // tessellate caster outline into a 2d polygon
     Vector<Vertex> casterVertices2d;
-    const float casterRefinementThresholdSquared = 20.0f; // TODO: experiment with this value
+    const float casterRefinementThresholdSquared = 4.0f;
     PathTessellator::approximatePathOutlineVertices(*casterPerimeter,
             casterRefinementThresholdSquared, casterVertices2d);
     if (!ShadowTessellator::isClockwisePath(*casterPerimeter)) {
@@ -267,7 +267,7 @@
             casterBounds, *localClip, maxZ, ambientBuffer);
 
     ShadowTessellator::tessellateSpotShadow(
-            isCasterOpaque, casterPolygon, casterVertexCount,
+            isCasterOpaque, casterPolygon, casterVertexCount, centroid3d,
             *drawTransform, lightCenter, lightRadius, casterBounds, *localClip,
             spotBuffer);
 }
diff --git a/libs/hwui/TreeInfo.h b/libs/hwui/TreeInfo.h
index 331f157..ae6ea94 100644
--- a/libs/hwui/TreeInfo.h
+++ b/libs/hwui/TreeInfo.h
@@ -26,18 +26,13 @@
 namespace android {
 namespace uirenderer {
 
-class BaseRenderNodeAnimator;
-class AnimationListener;
+namespace renderthread {
+class CanvasContext;
+}
+
 class OpenGLRenderer;
 class RenderState;
 
-class AnimationHook {
-public:
-    virtual void callOnFinished(BaseRenderNodeAnimator* animator, AnimationListener* listener) = 0;
-protected:
-    ~AnimationHook() {}
-};
-
 class ErrorHandler {
 public:
     virtual void onError(const std::string& message) = 0;
@@ -62,32 +57,36 @@
 
     explicit TreeInfo(TraversalMode mode, RenderState& renderState)
         : mode(mode)
-        , frameTimeMs(0)
-        , animationHook(NULL)
         , prepareTextures(mode == MODE_FULL)
+        , runAnimations(true)
         , damageAccumulator(NULL)
         , renderState(renderState)
         , renderer(NULL)
         , errorHandler(NULL)
+        , canvasContext(NULL)
     {}
 
     explicit TreeInfo(TraversalMode mode, const TreeInfo& clone)
         : mode(mode)
-        , frameTimeMs(clone.frameTimeMs)
-        , animationHook(clone.animationHook)
         , prepareTextures(mode == MODE_FULL)
+        , runAnimations(clone.runAnimations)
         , damageAccumulator(clone.damageAccumulator)
         , renderState(clone.renderState)
         , renderer(clone.renderer)
         , errorHandler(clone.errorHandler)
+        , canvasContext(clone.canvasContext)
     {}
 
     const TraversalMode mode;
-    nsecs_t frameTimeMs;
-    AnimationHook* animationHook;
     // TODO: Remove this? Currently this is used to signal to stop preparing
     // textures if we run out of cache space.
     bool prepareTextures;
+    // TODO: buildLayer uses this to suppress running any animations, but this
+    // should probably be refactored somehow. The reason this is done is
+    // because buildLayer is not setup for injecting the animationHook, as well
+    // as this being otherwise wasted work as all the animators will be
+    // re-evaluated when the frame is actually drawn
+    bool runAnimations;
 
     // Must not be null during actual usage
     DamageAccumulator* damageAccumulator;
@@ -96,6 +95,8 @@
     // layer updates or similar. May be NULL.
     OpenGLRenderer* renderer;
     ErrorHandler* errorHandler;
+    // TODO: Remove this? May be NULL
+    renderthread::CanvasContext* canvasContext;
 
     struct Out {
         Out()
diff --git a/libs/hwui/Vector.h b/libs/hwui/Vector.h
index 2a9f01c..d033ed9 100644
--- a/libs/hwui/Vector.h
+++ b/libs/hwui/Vector.h
@@ -111,6 +111,23 @@
     float y;
     float z;
 
+    Vector3 operator+(const Vector3& v) const {
+        return (Vector3){x + v.x, y + v.y, z + v.z};
+    }
+
+    Vector3 operator-(const Vector3& v) const {
+        return (Vector3){x - v.x, y - v.y, z - v.z};
+    }
+
+    Vector3 operator/(float s) const {
+        return (Vector3){x / s, y / s, z / s};
+    }
+
+    Vector3 operator*(float s) const {
+        return (Vector3){x * s, y * s, z * s};
+    }
+
+
     void dump() {
         ALOGD("Vector3[%.2f, %.2f, %.2f]", x, y, z);
     }
diff --git a/libs/hwui/VertexBuffer.h b/libs/hwui/VertexBuffer.h
index 3837f88..8c3a272 100644
--- a/libs/hwui/VertexBuffer.h
+++ b/libs/hwui/VertexBuffer.h
@@ -17,6 +17,7 @@
 #ifndef ANDROID_HWUI_VERTEX_BUFFER_H
 #define ANDROID_HWUI_VERTEX_BUFFER_H
 
+#include "utils/MathUtils.h"
 
 namespace android {
 namespace uirenderer {
@@ -26,19 +27,27 @@
     enum Mode {
         kStandard = 0,
         kOnePolyRingShadow = 1,
-        kTwoPolyRingShadow = 2
+        kTwoPolyRingShadow = 2,
+        kIndices = 3
     };
 
     VertexBuffer()
             : mBuffer(0)
+            , mIndices(0)
             , mVertexCount(0)
+            , mIndexCount(0)
+            , mAllocatedVertexCount(0)
+            , mAllocatedIndexCount(0)
             , mByteCount(0)
             , mMode(kStandard)
+            , mReallocBuffer(0)
             , mCleanupMethod(NULL)
+            , mCleanupIndexMethod(NULL)
     {}
 
     ~VertexBuffer() {
         if (mCleanupMethod) mCleanupMethod(mBuffer);
+        if (mCleanupIndexMethod) mCleanupIndexMethod(mIndices);
     }
 
     /**
@@ -59,6 +68,7 @@
             mReallocBuffer = reallocBuffer + vertexCount;
             return reallocBuffer;
         }
+        mAllocatedVertexCount = vertexCount;
         mVertexCount = vertexCount;
         mByteCount = mVertexCount * sizeof(TYPE);
         mReallocBuffer = mBuffer = (void*)new TYPE[vertexCount];
@@ -69,6 +79,17 @@
     }
 
     template <class TYPE>
+    TYPE* allocIndices(int indexCount) {
+        mAllocatedIndexCount = indexCount;
+        mIndexCount = indexCount;
+        mIndices = (void*)new TYPE[indexCount];
+
+        mCleanupIndexMethod = &(cleanup<TYPE>);
+
+        return (TYPE*)mIndices;
+    }
+
+    template <class TYPE>
     void copyInto(const VertexBuffer& srcBuffer, float xOffset, float yOffset) {
         int verticesToCopy = srcBuffer.getVertexCount();
 
@@ -103,9 +124,17 @@
     }
 
     const void* getBuffer() const { return mBuffer; }
+    const void* getIndices() const { return mIndices; }
     const Rect& getBounds() const { return mBounds; }
     unsigned int getVertexCount() const { return mVertexCount; }
     unsigned int getSize() const { return mByteCount; }
+    unsigned int getIndexCount() const { return mIndexCount; }
+    void updateIndexCount(unsigned int newCount)  {
+        mIndexCount = MathUtils::min(newCount, mAllocatedIndexCount);
+    }
+    void updateVertexCount(unsigned int newCount)  {
+        mVertexCount = MathUtils::min(newCount, mAllocatedVertexCount);
+    }
     Mode getMode() const { return mMode; }
 
     void setBounds(Rect bounds) { mBounds = bounds; }
@@ -127,14 +156,22 @@
     }
 
     Rect mBounds;
+
     void* mBuffer;
+    void* mIndices;
+
     unsigned int mVertexCount;
+    unsigned int mIndexCount;
+    unsigned int mAllocatedVertexCount;
+    unsigned int mAllocatedIndexCount;
     unsigned int mByteCount;
+
     Mode mMode;
 
     void* mReallocBuffer; // used for multi-allocation
 
     void (*mCleanupMethod)(void*);
+    void (*mCleanupIndexMethod)(void*);
 };
 
 }; // namespace uirenderer
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index e673b0d..832d170 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -16,11 +16,13 @@
 
 #include "CanvasContext.h"
 
+#include <algorithm>
 #include <private/hwui/DrawGlInfo.h>
 #include <strings.h>
 
 #include "EglManager.h"
 #include "RenderThread.h"
+#include "../AnimationContext.h"
 #include "../Caches.h"
 #include "../DeferredLayerUpdater.h"
 #include "../RenderState.h"
@@ -35,7 +37,8 @@
 namespace uirenderer {
 namespace renderthread {
 
-CanvasContext::CanvasContext(RenderThread& thread, bool translucent, RenderNode* rootRenderNode)
+CanvasContext::CanvasContext(RenderThread& thread, bool translucent,
+        RenderNode* rootRenderNode, IContextFactory* contextFactory)
         : mRenderThread(thread)
         , mEglManager(thread.eglManager())
         , mEglSurface(EGL_NO_SURFACE)
@@ -44,14 +47,21 @@
         , mCanvas(NULL)
         , mHaveNewSurface(false)
         , mRootRenderNode(rootRenderNode) {
+    mAnimationContext = contextFactory->createAnimationContext(mRenderThread.timeLord());
+    mRenderThread.renderState().registerCanvasContext(this);
 }
 
 CanvasContext::~CanvasContext() {
-    destroyCanvasAndSurface();
-    mRenderThread.removeFrameCallback(this);
+    destroy();
+    delete mAnimationContext;
+    mRenderThread.renderState().unregisterCanvasContext(this);
 }
 
-void CanvasContext::destroyCanvasAndSurface() {
+void CanvasContext::destroy() {
+    stopDrawing();
+    freePrefetechedLayers();
+    destroyHardwareResources();
+    mAnimationContext->destroy();
     if (mCanvas) {
         delete mCanvas;
         mCanvas = 0;
@@ -81,7 +91,9 @@
 }
 
 void CanvasContext::swapBuffers() {
-    mEglManager.swapBuffers(mEglSurface);
+    if (CC_UNLIKELY(!mEglManager.swapBuffers(mEglSurface))) {
+        setSurface(NULL);
+    }
     mHaveNewSurface = false;
 }
 
@@ -92,8 +104,8 @@
 }
 
 bool CanvasContext::initialize(ANativeWindow* window) {
-    if (mCanvas) return false;
     setSurface(window);
+    if (mCanvas) return false;
     mCanvas = new OpenGLRenderer(mRenderThread.renderState());
     mCanvas->initProperties();
     return true;
@@ -104,8 +116,7 @@
 }
 
 void CanvasContext::pauseSurface(ANativeWindow* window) {
-    // TODO: For now we just need a fence, in the future suspend any animations
-    // and such to prevent from trying to render into this surface
+    stopDrawing();
 }
 
 void CanvasContext::setup(int width, int height, const Vector3& lightCenter, float lightRadius,
@@ -136,10 +147,18 @@
 void CanvasContext::prepareTree(TreeInfo& info) {
     mRenderThread.removeFrameCallback(this);
 
-    info.frameTimeMs = mRenderThread.timeLord().frameTimeMs();
     info.damageAccumulator = &mDamageAccumulator;
     info.renderer = mCanvas;
+    if (mPrefetechedLayers.size() && info.mode == TreeInfo::MODE_FULL) {
+        info.canvasContext = this;
+    }
+    mAnimationContext->startFrame(info.mode);
     mRootRenderNode->prepareTree(info);
+    mAnimationContext->runRemainingAnimations(info);
+
+    if (info.canvasContext) {
+        freePrefetechedLayers();
+    }
 
     int runningBehind = 0;
     // TODO: This query is moderately expensive, investigate adding some sort
@@ -244,6 +263,53 @@
     thread.renderState().invokeFunctor(functor, mode, NULL);
 }
 
+void CanvasContext::markLayerInUse(RenderNode* node) {
+    if (mPrefetechedLayers.erase(node)) {
+        node->decStrong(0);
+    }
+}
+
+static void destroyPrefetechedNode(RenderNode* node) {
+    ALOGW("Incorrectly called buildLayer on View: %s, destroying layer...", node->getName());
+    node->destroyHardwareResources();
+    node->decStrong(0);
+}
+
+void CanvasContext::freePrefetechedLayers() {
+    if (mPrefetechedLayers.size()) {
+        requireGlContext();
+        std::for_each(mPrefetechedLayers.begin(), mPrefetechedLayers.end(), destroyPrefetechedNode);
+        mPrefetechedLayers.clear();
+    }
+}
+
+void CanvasContext::buildLayer(RenderNode* node) {
+    ATRACE_CALL();
+    if (!mEglManager.hasEglContext() || !mCanvas) {
+        return;
+    }
+    requireGlContext();
+    // buildLayer() will leave the tree in an unknown state, so we must stop drawing
+    stopDrawing();
+
+    TreeInfo info(TreeInfo::MODE_FULL, mRenderThread.renderState());
+    info.damageAccumulator = &mDamageAccumulator;
+    info.renderer = mCanvas;
+    info.runAnimations = false;
+    node->prepareTree(info);
+    SkRect ignore;
+    mDamageAccumulator.finish(&ignore);
+    // Tickle the GENERIC property on node to mark it as dirty for damaging
+    // purposes when the frame is actually drawn
+    node->setPropertyFieldsDirty(RenderNode::GENERIC);
+
+    mCanvas->markLayersAsBuildLayers();
+    mCanvas->flushLayerUpdates();
+
+    node->incStrong(0);
+    mPrefetechedLayers.insert(node);
+}
+
 bool CanvasContext::copyLayerInto(DeferredLayerUpdater* layer, SkBitmap* bitmap) {
     requireGlContext();
     layer->apply();
@@ -254,6 +320,7 @@
     stopDrawing();
     if (mEglManager.hasEglContext()) {
         requireGlContext();
+        freePrefetechedLayers();
         mRootRenderNode->destroyHardwareResources();
         Caches::getInstance().flush(Caches::kFlushMode_Layers);
     }
diff --git a/libs/hwui/renderthread/CanvasContext.h b/libs/hwui/renderthread/CanvasContext.h
index 2a01027..2460f6b8 100644
--- a/libs/hwui/renderthread/CanvasContext.h
+++ b/libs/hwui/renderthread/CanvasContext.h
@@ -17,6 +17,8 @@
 #ifndef CANVASCONTEXT_H_
 #define CANVASCONTEXT_H_
 
+#include <set>
+
 #include <cutils/compiler.h>
 #include <EGL/egl.h>
 #include <SkBitmap.h>
@@ -25,6 +27,7 @@
 
 #include "../DamageAccumulator.h"
 #include "../DrawProfiler.h"
+#include "../IContextFactory.h"
 #include "../RenderNode.h"
 #include "RenderTask.h"
 #include "RenderThread.h"
@@ -34,10 +37,12 @@
 namespace android {
 namespace uirenderer {
 
+class AnimationContext;
 class DeferredLayerUpdater;
 class OpenGLRenderer;
 class Rect;
 class Layer;
+class RenderState;
 
 namespace renderthread {
 
@@ -45,9 +50,11 @@
 
 // This per-renderer class manages the bridge between the global EGL context
 // and the render surface.
+// TODO: Rename to Renderer or some other per-window, top-level manager
 class CanvasContext : public IFrameCallback {
 public:
-    CanvasContext(RenderThread& thread, bool translucent, RenderNode* rootRenderNode);
+    CanvasContext(RenderThread& thread, bool translucent, RenderNode* rootRenderNode,
+            IContextFactory* contextFactory);
     virtual ~CanvasContext();
 
     bool initialize(ANativeWindow* window);
@@ -60,12 +67,14 @@
     void processLayerUpdate(DeferredLayerUpdater* layerUpdater);
     void prepareTree(TreeInfo& info);
     void draw();
-    void destroyCanvasAndSurface();
+    void destroy();
 
     // IFrameCallback, Chroreographer-driven frame callback entry point
     virtual void doFrame();
 
+    void buildLayer(RenderNode* node);
     bool copyLayerInto(DeferredLayerUpdater* layer, SkBitmap* bitmap);
+    void markLayerInUse(RenderNode* node);
 
     void destroyHardwareResources();
     static void trimMemory(RenderThread& thread, int level);
@@ -87,6 +96,9 @@
 
 private:
     friend class RegisterFrameCallbackTask;
+    // TODO: Replace with something better for layer & other GL object
+    // lifecycle tracking
+    friend class android::uirenderer::RenderState;
 
     void setSurface(ANativeWindow* window);
     void swapBuffers();
@@ -94,6 +106,8 @@
 
     void requireGlContext();
 
+    void freePrefetechedLayers();
+
     RenderThread& mRenderThread;
     EglManager& mEglManager;
     sp<ANativeWindow> mNativeWindow;
@@ -104,10 +118,13 @@
     OpenGLRenderer* mCanvas;
     bool mHaveNewSurface;
     DamageAccumulator mDamageAccumulator;
+    AnimationContext* mAnimationContext;
 
     const sp<RenderNode> mRootRenderNode;
 
     DrawProfiler mProfiler;
+
+    std::set<RenderNode*> mPrefetechedLayers;
 };
 
 } /* namespace renderthread */
diff --git a/libs/hwui/renderthread/EglManager.cpp b/libs/hwui/renderthread/EglManager.cpp
index 05ca34d..a87834e 100644
--- a/libs/hwui/renderthread/EglManager.cpp
+++ b/libs/hwui/renderthread/EglManager.cpp
@@ -14,8 +14,6 @@
  * limitations under the License.
  */
 
-#define LOG_TAG "EglContext"
-
 #include "EglManager.h"
 
 #include <cutils/log.h>
@@ -214,6 +212,7 @@
         Caches::getInstance().terminate();
     }
 
+    mRenderThread.renderState().onGLContextDestroyed();
     eglDestroyContext(mEglDisplay, mEglContext);
     eglDestroySurface(mEglDisplay, mPBufferSurface);
     eglMakeCurrent(mEglDisplay, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
@@ -255,11 +254,23 @@
     eglBeginFrame(mEglDisplay, surface);
 }
 
-void EglManager::swapBuffers(EGLSurface surface) {
+bool EglManager::swapBuffers(EGLSurface surface) {
     eglSwapBuffers(mEglDisplay, surface);
     EGLint err = eglGetError();
-    LOG_ALWAYS_FATAL_IF(err != EGL_SUCCESS,
-            "Encountered EGL error %d %s during rendering", err, egl_error_str(err));
+    if (CC_LIKELY(err == EGL_SUCCESS)) {
+        return true;
+    }
+    if (err == EGL_BAD_SURFACE) {
+        // For some reason our surface was destroyed out from under us
+        // This really shouldn't happen, but if it does we can recover easily
+        // by just not trying to use the surface anymore
+        ALOGW("swapBuffers encountered EGL_BAD_SURFACE on %p, halting rendering...", surface);
+        return false;
+    }
+    LOG_ALWAYS_FATAL("Encountered EGL error %d %s during rendering",
+            err, egl_error_str(err));
+    // Impossible to hit this, but the compiler doesn't know that
+    return false;
 }
 
 bool EglManager::enableDirtyRegions(EGLSurface surface) {
diff --git a/libs/hwui/renderthread/EglManager.h b/libs/hwui/renderthread/EglManager.h
index a844cfc..71213fb 100644
--- a/libs/hwui/renderthread/EglManager.h
+++ b/libs/hwui/renderthread/EglManager.h
@@ -47,7 +47,7 @@
     // Returns true if the current surface changed, false if it was already current
     bool makeCurrent(EGLSurface surface);
     void beginFrame(EGLSurface surface, EGLint* width, EGLint* height);
-    void swapBuffers(EGLSurface surface);
+    bool swapBuffers(EGLSurface surface);
 
     bool enableDirtyRegions(EGLSurface surface);
 
diff --git a/libs/hwui/renderthread/RenderProxy.cpp b/libs/hwui/renderthread/RenderProxy.cpp
index d9b96f6c..9528874 100644
--- a/libs/hwui/renderthread/RenderProxy.cpp
+++ b/libs/hwui/renderthread/RenderProxy.cpp
@@ -52,17 +52,20 @@
     MethodInvokeRenderTask* task = new MethodInvokeRenderTask((RunnableMethod) Bridge_ ## method); \
     ARGS(method) *args = (ARGS(method) *) task->payload()
 
-CREATE_BRIDGE3(createContext, RenderThread* thread, bool translucent, RenderNode* rootRenderNode) {
-    return new CanvasContext(*args->thread, args->translucent, args->rootRenderNode);
+CREATE_BRIDGE4(createContext, RenderThread* thread, bool translucent,
+        RenderNode* rootRenderNode, IContextFactory* contextFactory) {
+    return new CanvasContext(*args->thread, args->translucent,
+            args->rootRenderNode, args->contextFactory);
 }
 
-RenderProxy::RenderProxy(bool translucent, RenderNode* rootRenderNode)
+RenderProxy::RenderProxy(bool translucent, RenderNode* rootRenderNode, IContextFactory* contextFactory)
         : mRenderThread(RenderThread::getInstance())
         , mContext(0) {
     SETUP_TASK(createContext);
     args->translucent = translucent;
     args->rootRenderNode = rootRenderNode;
     args->thread = &mRenderThread;
+    args->contextFactory = contextFactory;
     mContext = (CanvasContext*) postAndWait(task);
     mDrawFrameTask.setContext(&mRenderThread, mContext);
 }
@@ -191,13 +194,13 @@
     return mDrawFrameTask.drawFrame(frameTimeNanos, recordDurationNanos);
 }
 
-CREATE_BRIDGE1(destroyCanvasAndSurface, CanvasContext* context) {
-    args->context->destroyCanvasAndSurface();
+CREATE_BRIDGE1(destroy, CanvasContext* context) {
+    args->context->destroy();
     return NULL;
 }
 
-void RenderProxy::destroyCanvasAndSurface() {
-    SETUP_TASK(destroyCanvasAndSurface);
+void RenderProxy::destroy() {
+    SETUP_TASK(destroy);
     args->context = mContext;
     // destroyCanvasAndSurface() needs a fence as when it returns the
     // underlying BufferQueue is going to be released from under
@@ -284,6 +287,18 @@
     return layer;
 }
 
+CREATE_BRIDGE2(buildLayer, CanvasContext* context, RenderNode* node) {
+    args->context->buildLayer(args->node);
+    return NULL;
+}
+
+void RenderProxy::buildLayer(RenderNode* node) {
+    SETUP_TASK(buildLayer);
+    args->context = mContext;
+    args->node = node;
+    postAndWait(task);
+}
+
 CREATE_BRIDGE3(copyLayerInto, CanvasContext* context, DeferredLayerUpdater* layer,
         SkBitmap* bitmap) {
     bool success = args->context->copyLayerInto(args->layer, args->bitmap);
diff --git a/libs/hwui/renderthread/RenderProxy.h b/libs/hwui/renderthread/RenderProxy.h
index 28d0173..8b8d99c 100644
--- a/libs/hwui/renderthread/RenderProxy.h
+++ b/libs/hwui/renderthread/RenderProxy.h
@@ -30,6 +30,7 @@
 #include <utils/Vector.h>
 
 #include "../Caches.h"
+#include "../IContextFactory.h"
 #include "DrawFrameTask.h"
 
 namespace android {
@@ -58,7 +59,7 @@
  */
 class ANDROID_API RenderProxy {
 public:
-    ANDROID_API RenderProxy(bool translucent, RenderNode* rootNode);
+    ANDROID_API RenderProxy(bool translucent, RenderNode* rootNode, IContextFactory* contextFactory);
     ANDROID_API virtual ~RenderProxy();
 
     ANDROID_API void setFrameInterval(nsecs_t frameIntervalNanos);
@@ -72,7 +73,7 @@
     ANDROID_API void setOpaque(bool opaque);
     ANDROID_API int syncAndDrawFrame(nsecs_t frameTimeNanos, nsecs_t recordDurationNanos,
             float density);
-    ANDROID_API void destroyCanvasAndSurface();
+    ANDROID_API void destroy();
 
     ANDROID_API static void invokeFunctor(Functor* functor, bool waitForCompletion);
 
@@ -81,6 +82,7 @@
     static void enqueueDestroyLayer(Layer* layer);
     ANDROID_API DeferredLayerUpdater* createDisplayListLayer(int width, int height);
     ANDROID_API DeferredLayerUpdater* createTextureLayer();
+    ANDROID_API void buildLayer(RenderNode* node);
     ANDROID_API bool copyLayerInto(DeferredLayerUpdater* layer, SkBitmap* bitmap);
     ANDROID_API void pushLayerUpdate(DeferredLayerUpdater* layer);
     ANDROID_API void cancelLayerUpdate(DeferredLayerUpdater* layer);
diff --git a/libs/hwui/renderthread/RenderThread.h b/libs/hwui/renderthread/RenderThread.h
index 0b91e9d..c461f3a 100644
--- a/libs/hwui/renderthread/RenderThread.h
+++ b/libs/hwui/renderthread/RenderThread.h
@@ -40,6 +40,7 @@
 
 namespace renderthread {
 
+class CanvasContext;
 class DispatchFrameCallbacks;
 class EglManager;
 class RenderProxy;
diff --git a/libs/hwui/renderthread/TimeLord.cpp b/libs/hwui/renderthread/TimeLord.cpp
index 758d96e..cf3d039 100644
--- a/libs/hwui/renderthread/TimeLord.cpp
+++ b/libs/hwui/renderthread/TimeLord.cpp
@@ -30,7 +30,7 @@
     }
 }
 
-nsecs_t TimeLord::frameTimeMs() {
+nsecs_t TimeLord::computeFrameTimeMs() {
     // Logic copied from Choreographer.java
     nsecs_t now = systemTime(CLOCK_MONOTONIC);
     nsecs_t jitterNanos = now - mFrameTimeNanos;
diff --git a/libs/hwui/renderthread/TimeLord.h b/libs/hwui/renderthread/TimeLord.h
index 52c6d9e..8b0372c 100644
--- a/libs/hwui/renderthread/TimeLord.h
+++ b/libs/hwui/renderthread/TimeLord.h
@@ -30,7 +30,7 @@
 public:
     void setFrameInterval(nsecs_t intervalNanos) { mFrameIntervalNanos = intervalNanos; }
     void vsyncReceived(nsecs_t vsync);
-    nsecs_t frameTimeMs();
+    nsecs_t computeFrameTimeMs();
 
 private:
     friend class RenderThread;
diff --git a/libs/hwui/utils/MathUtils.h b/libs/hwui/utils/MathUtils.h
index 6fb0411..d89859b 100644
--- a/libs/hwui/utils/MathUtils.h
+++ b/libs/hwui/utils/MathUtils.h
@@ -66,14 +66,21 @@
         return isZero(valueA - valueB);
     }
 
-    inline static int max(int a, int b) {
+    template<typename T>
+    static inline T max(T a, T b) {
         return a > b ? a : b;
     }
 
-    inline static int min(int a, int b) {
+    template<typename T>
+    static inline T min(T a, T b) {
         return a < b ? a : b;
     }
 
+    template<typename T>
+    static inline T clamp(T a, T minValue, T maxValue) {
+        return min(max(a, minValue), maxValue);
+    }
+
     inline static float lerp(float v1, float v2, float t) {
         return v1 + ((v2 - v1) * t);
     }
diff --git a/libs/storage/IMountService.cpp b/libs/storage/IMountService.cpp
index 5701678..621de18 100644
--- a/libs/storage/IMountService.cpp
+++ b/libs/storage/IMountService.cpp
@@ -295,6 +295,8 @@
         data.writeString16(id);
         data.writeString16(key);
         data.writeInt32(ownerUid);
+        // Assume read-only
+        data.writeInt32(1);
         if (remote()->transact(TRANSACTION_mountSecureContainer, data, &reply) != NO_ERROR) {
             ALOGD("mountSecureContainer couldn't call remote");
             return -1;
diff --git a/location/java/android/location/GpsMeasurement.java b/location/java/android/location/GpsMeasurement.java
index 591a6ca..1550dc2 100644
--- a/location/java/android/location/GpsMeasurement.java
+++ b/location/java/android/location/GpsMeasurement.java
@@ -49,7 +49,7 @@
     private double mCarrierPhase;
     private double mCarrierPhaseUncertainty;
     private byte mLossOfLock;
-    private short mBitNumber;
+    private int mBitNumber;
     private short mTimeFromLastBitInMs;
     private double mDopplerShiftInHz;
     private double mDopplerShiftUncertaintyInHz;
@@ -784,14 +784,14 @@
      *
      * The value is only available if {@link #hasBitNumber()} is true.
      */
-    public short getBitNumber() {
+    public int getBitNumber() {
         return mBitNumber;
     }
 
     /**
      * Sets the bit number within the broadcast frame.
      */
-    public void setBitNumber(short bitNumber) {
+    public void setBitNumber(int bitNumber) {
         setFlag(HAS_BIT_NUMBER);
         mBitNumber = bitNumber;
     }
@@ -801,7 +801,7 @@
      */
     public void resetBitNumber() {
         resetFlag(HAS_BIT_NUMBER);
-        mBitNumber = Short.MIN_VALUE;
+        mBitNumber = Integer.MIN_VALUE;
     }
 
     /**
@@ -1161,7 +1161,7 @@
             gpsMeasurement.mCarrierPhase = parcel.readDouble();
             gpsMeasurement.mCarrierPhaseUncertainty = parcel.readDouble();
             gpsMeasurement.mLossOfLock = parcel.readByte();
-            gpsMeasurement.mBitNumber = (short) parcel.readInt();
+            gpsMeasurement.mBitNumber = parcel.readInt();
             gpsMeasurement.mTimeFromLastBitInMs = (short) parcel.readInt();
             gpsMeasurement.mDopplerShiftInHz = parcel.readDouble();
             gpsMeasurement.mDopplerShiftUncertaintyInHz = parcel.readDouble();
diff --git a/location/java/android/location/Location.java b/location/java/android/location/Location.java
index bdd1195..fcf222b 100644
--- a/location/java/android/location/Location.java
+++ b/location/java/android/location/Location.java
@@ -16,6 +16,7 @@
 
 package android.location;
 
+import android.annotation.SystemApi;
 import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
@@ -771,6 +772,7 @@
      * @see #makeComplete
      * @hide
      */
+    @SystemApi
     public boolean isComplete() {
         if (mProvider == null) return false;
         if (!mHasAccuracy) return false;
@@ -788,6 +790,7 @@
      * @see #isComplete
      * @hide
      */
+    @SystemApi
     public void makeComplete() {
         if (mProvider == null) mProvider = "?";
         if (!mHasAccuracy) {
@@ -957,6 +960,7 @@
      * @param isFromMockProvider true if this Location came from a mock provider, false otherwise
      * @hide
      */
+    @SystemApi
     public void setIsFromMockProvider(boolean isFromMockProvider) {
         mIsFromMockProvider = isFromMockProvider;
     }
diff --git a/location/java/android/location/LocationManager.java b/location/java/android/location/LocationManager.java
index 082a158..0445869 100644
--- a/location/java/android/location/LocationManager.java
+++ b/location/java/android/location/LocationManager.java
@@ -18,6 +18,7 @@
 
 import com.android.internal.location.ProviderProperties;
 
+import android.annotation.SystemApi;
 import android.app.PendingIntent;
 import android.content.Context;
 import android.content.Intent;
@@ -808,6 +809,7 @@
      *
      * @hide
      */
+    @SystemApi
     public void requestLocationUpdates(LocationRequest request, LocationListener listener,
             Looper looper) {
         checkListener(listener);
@@ -835,6 +837,7 @@
      *
      * @hide
      */
+    @SystemApi
     public void requestLocationUpdates(LocationRequest request, PendingIntent intent) {
         checkPendingIntent(intent);
         requestLocationUpdates(request, null, null, intent);
@@ -1109,9 +1112,9 @@
      * {@link #requestLocationUpdates(String, long, float, LocationListener)}.
      *
      * <p>
-     * Before API version 20, this method would throw {@link SecurityException}
-     * if the location permissions were not sufficient to use the specified
-     * provider.
+     * Before API version {@link android.os.Build.VERSION_CODES#L}, this
+     * method would throw {@link SecurityException} if the location permissions
+     * were not sufficient to use the specified provider.
      *
      * @param provider the name of the provider
      * @return true if the provider exists and is enabled
@@ -1119,7 +1122,6 @@
      * @throws IllegalArgumentException if provider is null
      */
     public boolean isProviderEnabled(String provider) {
-        // STOPSHIP: finalize API version number in javadoc
         checkProvider(provider);
 
         try {
diff --git a/location/java/android/location/LocationRequest.java b/location/java/android/location/LocationRequest.java
index c9162fe..271f2bb 100644
--- a/location/java/android/location/LocationRequest.java
+++ b/location/java/android/location/LocationRequest.java
@@ -16,6 +16,7 @@
 
 package android.location;
 
+import android.annotation.SystemApi;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.os.SystemClock;
@@ -84,6 +85,7 @@
  *
  * @hide
  */
+@SystemApi
 public final class LocationRequest implements Parcelable {
     /**
      * Used with {@link #setQuality} to request the most accurate locations available.
@@ -166,6 +168,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public static LocationRequest createFromDeprecatedProvider(String provider, long minTime,
             float minDistance, boolean singleShot) {
         if (minTime < 0) minTime = 0;
@@ -191,6 +194,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public static LocationRequest createFromDeprecatedCriteria(Criteria criteria, long minTime,
             float minDistance, boolean singleShot) {
         if (minTime < 0) minTime = 0;
@@ -475,6 +479,7 @@
 
 
     /** @hide */
+    @SystemApi
     public LocationRequest setProvider(String provider) {
         checkProvider(provider);
         mProvider = provider;
@@ -482,11 +487,13 @@
     }
 
     /** @hide */
+    @SystemApi
     public String getProvider() {
         return mProvider;
     }
 
     /** @hide */
+    @SystemApi
     public LocationRequest setSmallestDisplacement(float meters) {
         checkDisplacement(meters);
         mSmallestDisplacement = meters;
@@ -494,6 +501,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public float getSmallestDisplacement() {
         return mSmallestDisplacement;
     }
@@ -508,11 +516,13 @@
      * @param workSource WorkSource defining power blame for this location request.
      * @hide
      */
+    @SystemApi
     public void setWorkSource(WorkSource workSource) {
         mWorkSource = workSource;
     }
 
     /** @hide */
+    @SystemApi
     public WorkSource getWorkSource() {
         return mWorkSource;
     }
@@ -531,11 +541,13 @@
      * @see android.app.AppOpsManager
      * @hide
      */
+    @SystemApi
     public void setHideFromAppOps(boolean hideFromAppOps) {
         mHideFromAppOps = hideFromAppOps;
     }
 
     /** @hide */
+    @SystemApi
     public boolean getHideFromAppOps() {
         return mHideFromAppOps;
     }
diff --git a/location/java/android/location/SettingInjectorService.java b/location/java/android/location/SettingInjectorService.java
index 98c7864..fcd2cde 100644
--- a/location/java/android/location/SettingInjectorService.java
+++ b/location/java/android/location/SettingInjectorService.java
@@ -196,10 +196,7 @@
      * @deprecated not called any more
      */
     @Deprecated
-    protected String onGetSummary() {
-        // Do not delete until no callers have @Override annotations for this method
-        return null;
-    }
+    protected abstract String onGetSummary();
 
     /**
      * Returns the {@link android.preference.Preference#isEnabled()} value. Should not perform
diff --git a/location/java/com/android/internal/location/GpsNetInitiatedHandler.java b/location/java/com/android/internal/location/GpsNetInitiatedHandler.java
index b33ba00..f0a2072 100644
--- a/location/java/com/android/internal/location/GpsNetInitiatedHandler.java
+++ b/location/java/com/android/internal/location/GpsNetInitiatedHandler.java
@@ -21,15 +21,25 @@
 import android.app.Notification;
 import android.app.NotificationManager;
 import android.app.PendingIntent;
+import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
+import android.content.IntentFilter;
 import android.location.LocationManager;
+import android.location.INetInitiatedListener;
+import android.telephony.TelephonyManager;
+import android.telephony.PhoneNumberUtils;
+import android.telephony.PhoneStateListener;
 import android.os.Bundle;
+import android.os.RemoteException;
 import android.os.UserHandle;
+import android.os.SystemProperties;
+import android.provider.Settings;
 import android.util.Log;
 
 import com.android.internal.R;
 import com.android.internal.telephony.GsmAlphabet;
+import com.android.internal.telephony.TelephonyProperties;
 
 /**
  * A GPS Network-initiated Handler class used by LocationManager.
@@ -45,55 +55,70 @@
 
     // NI verify activity for bringing up UI (not used yet)
     public static final String ACTION_NI_VERIFY = "android.intent.action.NETWORK_INITIATED_VERIFY";
-    
+
     // string constants for defining data fields in NI Intent
     public static final String NI_INTENT_KEY_NOTIF_ID = "notif_id";
     public static final String NI_INTENT_KEY_TITLE = "title";
     public static final String NI_INTENT_KEY_MESSAGE = "message";
     public static final String NI_INTENT_KEY_TIMEOUT = "timeout";
     public static final String NI_INTENT_KEY_DEFAULT_RESPONSE = "default_resp";
-    
+
     // the extra command to send NI response to GpsLocationProvider
     public static final String NI_RESPONSE_EXTRA_CMD = "send_ni_response";
-    
+
     // the extra command parameter names in the Bundle
     public static final String NI_EXTRA_CMD_NOTIF_ID = "notif_id";
     public static final String NI_EXTRA_CMD_RESPONSE = "response";
-    
+
     // these need to match GpsNiType constants in gps_ni.h
     public static final int GPS_NI_TYPE_VOICE = 1;
     public static final int GPS_NI_TYPE_UMTS_SUPL = 2;
     public static final int GPS_NI_TYPE_UMTS_CTRL_PLANE = 3;
-    
-    // these need to match GpsUserResponseType constants in gps_ni.h    
+    public static final int GPS_NI_TYPE_EMERGENCY_SUPL = 4;
+
+    // these need to match GpsUserResponseType constants in gps_ni.h
     public static final int GPS_NI_RESPONSE_ACCEPT = 1;
     public static final int GPS_NI_RESPONSE_DENY = 2;
-    public static final int GPS_NI_RESPONSE_NORESP = 3;    
-    
+    public static final int GPS_NI_RESPONSE_NORESP = 3;
+    public static final int GPS_NI_RESPONSE_IGNORE = 4;
+
     // these need to match GpsNiNotifyFlags constants in gps_ni.h
     public static final int GPS_NI_NEED_NOTIFY = 0x0001;
     public static final int GPS_NI_NEED_VERIFY = 0x0002;
     public static final int GPS_NI_PRIVACY_OVERRIDE = 0x0004;
-    
+
     // these need to match GpsNiEncodingType in gps_ni.h
     public static final int GPS_ENC_NONE = 0;
     public static final int GPS_ENC_SUPL_GSM_DEFAULT = 1;
     public static final int GPS_ENC_SUPL_UTF8 = 2;
     public static final int GPS_ENC_SUPL_UCS2 = 3;
     public static final int GPS_ENC_UNKNOWN = -1;
-    
+
     private final Context mContext;
-    
+    private final TelephonyManager mTelephonyManager;
+    private final PhoneStateListener mPhoneStateListener;
+
     // parent gps location provider
     private final LocationManager mLocationManager;
-    
+
     // configuration of notificaiton behavior
     private boolean mPlaySounds = false;
     private boolean mPopupImmediately = true;
-    
-    // Set to true if string from HAL is encoded as Hex, e.g., "3F0039"    
+
+    // read the SUPL_ES form gps.conf
+    private volatile boolean mIsSuplEsEnabled;
+
+    // Set to true if the phone is having emergency call.
+    private volatile boolean mIsInEmergency;
+
+    // If Location function is enabled.
+    private volatile boolean mIsLocationEnabled = false;
+
+    private final INetInitiatedListener mNetInitiatedListener;
+
+    // Set to true if string from HAL is encoded as Hex, e.g., "3F0039"
     static private boolean mIsHexInput = true;
-        
+
     public static class GpsNiNotification
     {
         public int notificationId;
@@ -109,58 +134,137 @@
         public int textEncoding;
         public Bundle extras;
     };
-    
+
     public static class GpsNiResponse {
-        /* User reponse, one of the values in GpsUserResponseType */
+        /* User response, one of the values in GpsUserResponseType */
         int userResponse;
         /* Optional extra data to pass with the user response */
         Bundle extras;
     };
-    
+
+    private final BroadcastReceiver mBroadcastReciever = new BroadcastReceiver() {
+
+        @Override public void onReceive(Context context, Intent intent) {
+            String action = intent.getAction();
+            if (action.equals(Intent.ACTION_NEW_OUTGOING_CALL)) {
+                String phoneNumber = intent.getStringExtra(Intent.EXTRA_PHONE_NUMBER);
+                /*
+                   Emergency Mode is when during emergency call or in emergency call back mode.
+                   For checking if it is during emergency call:
+                       mIsInEmergency records if the phone is in emergency call or not. It will
+                       be set to true when the phone is having emergency call, and then will
+                       be set to false by mPhoneStateListener when the emergency call ends.
+                   For checking if it is in emergency call back mode:
+                       Emergency call back mode will be checked by reading system properties
+                       when necessary: SystemProperties.get(TelephonyProperties.PROPERTY_INECM_MODE)
+                */
+                setInEmergency(PhoneNumberUtils.isEmergencyNumber(phoneNumber));
+                if (DEBUG) Log.v(TAG, "ACTION_NEW_OUTGOING_CALL - " + getInEmergency());
+            } else if (action.equals(LocationManager.MODE_CHANGED_ACTION)) {
+                updateLocationMode();
+                if (DEBUG) Log.d(TAG, "location enabled :" + getLocationEnabled());
+            }
+        }
+    };
+
     /**
      * The notification that is shown when a network-initiated notification
-     * (and verification) event is received. 
+     * (and verification) event is received.
      * <p>
      * This is lazily created, so use {@link #setNINotification()}.
      */
     private Notification mNiNotification;
-    
-    public GpsNetInitiatedHandler(Context context) {
+
+    public GpsNetInitiatedHandler(Context context,
+                                  INetInitiatedListener netInitiatedListener,
+                                  boolean isSuplEsEnabled) {
         mContext = context;
+
+        if (netInitiatedListener == null) {
+            throw new IllegalArgumentException("netInitiatedListener is null");
+        } else {
+            mNetInitiatedListener = netInitiatedListener;
+        }
+
+        setSuplEsEnabled(isSuplEsEnabled);
         mLocationManager = (LocationManager)context.getSystemService(Context.LOCATION_SERVICE);
+        updateLocationMode();
+        mTelephonyManager =
+            (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE);
+
+        mPhoneStateListener = new PhoneStateListener() {
+            @Override
+            public void onCallStateChanged(int state, String incomingNumber) {
+                if (DEBUG) Log.d(TAG, "onCallStateChanged(): state is "+ state);
+                // listening for emergency call ends
+                if (state == TelephonyManager.CALL_STATE_IDLE) {
+                    setInEmergency(false);
+                }
+            }
+        };
+        mTelephonyManager.listen(mPhoneStateListener, PhoneStateListener.LISTEN_CALL_STATE);
+
+        IntentFilter intentFilter = new IntentFilter();
+        intentFilter.addAction(Intent.ACTION_NEW_OUTGOING_CALL);
+        intentFilter.addAction(LocationManager.MODE_CHANGED_ACTION);
+        mContext.registerReceiver(mBroadcastReciever, intentFilter);
     }
-    
+
+    public void setSuplEsEnabled(boolean isEnabled) {
+        mIsSuplEsEnabled = isEnabled;
+    }
+
+    public boolean getSuplEsEnabled() {
+        return mIsSuplEsEnabled;
+    }
+
+    /**
+     * Updates Location enabler based on location setting.
+     */
+    public void updateLocationMode() {
+        mIsLocationEnabled = mLocationManager.isProviderEnabled(LocationManager.GPS_PROVIDER);
+    }
+
+    /**
+     * Checks if user agreed to use location.
+     */
+    public boolean getLocationEnabled() {
+        return mIsLocationEnabled;
+    }
+
+    // Note: Currently, there are two mechanisms involved to determine if a
+    // phone is in emergency mode:
+    // 1. If the user is making an emergency call, this is provided by activly
+    //    monitoring the outgoing phone number;
+    // 2. If the device is in a emergency callback state, this is provided by
+    //    system properties.
+    // If either one of above exists, the phone is considered in an emergency
+    // mode. Because of this complexity, we need to be careful about how to set
+    // and clear the emergency state.
+    public void setInEmergency(boolean isInEmergency) {
+        mIsInEmergency = isInEmergency;
+    }
+
+    public boolean getInEmergency() {
+        boolean isInEmergencyCallback = Boolean.parseBoolean(
+                SystemProperties.get(TelephonyProperties.PROPERTY_INECM_MODE));
+        return mIsInEmergency || isInEmergencyCallback;
+    }
+
+
     // Handles NI events from HAL
-    public void handleNiNotification(GpsNiNotification notif)
-    {
-        if (DEBUG) Log.d(TAG, "handleNiNotification" + " notificationId: " + notif.notificationId
-                + " requestorId: " + notif.requestorId + " text: " + notif.text);
+    public void handleNiNotification(GpsNiNotification notif) {
+        if (DEBUG) Log.d(TAG, "in handleNiNotification () :"
+                        + " notificationId: " + notif.notificationId
+                        + " requestorId: " + notif.requestorId
+                        + " text: " + notif.text
+                        + " mIsSuplEsEnabled" + getSuplEsEnabled()
+                        + " mIsLocationEnabled" + getLocationEnabled());
 
-        // Notify and verify with immediate pop-up
-        if (notif.needNotify && notif.needVerify && mPopupImmediately)
-        {
-            // Popup the dialog box now
-            openNiDialog(notif);
-        }
-
-        // Notify only, or delayed pop-up (change mPopupImmediately to FALSE)
-        if (notif.needNotify && !notif.needVerify ||
-            notif.needNotify && notif.needVerify && !mPopupImmediately)
-        {
-            // Show the notification
-
-            // if mPopupImmediately == FALSE and needVerify == TRUE, a dialog will be opened
-            // when the user opens the notification message
-
-            setNiNotification(notif);
-        }
-
-        // ACCEPT cases: 1. Notify, no verify; 2. no notify, no verify; 3. privacy override.
-        if ( notif.needNotify && !notif.needVerify ||
-            !notif.needNotify && !notif.needVerify ||
-             notif.privacyOverride)
-        {
-            mLocationManager.sendNiResponse(notif.notificationId, GPS_NI_RESPONSE_ACCEPT);
+        if (getSuplEsEnabled()) {
+            handleNiInEs(notif);
+        } else {
+            handleNi(notif);
         }
 
         //////////////////////////////////////////////////////////////////////////
@@ -176,6 +280,78 @@
         //
     }
 
+    // handle NI form HAL when SUPL_ES is disabled.
+    private void handleNi(GpsNiNotification notif) {
+        if (DEBUG) Log.d(TAG, "in handleNi () :"
+                        + " needNotify: " + notif.needNotify
+                        + " needVerify: " + notif.needVerify
+                        + " privacyOverride: " + notif.privacyOverride
+                        + " mPopupImmediately: " + mPopupImmediately
+                        + " mInEmergency: " + getInEmergency());
+
+        if (getLocationEnabled() && !getInEmergency()) {
+            // Location is currently disabled, ignore all NI requests.
+            try {
+                mNetInitiatedListener.sendNiResponse(notif.notificationId,
+                                                     GPS_NI_RESPONSE_IGNORE);
+            } catch (RemoteException e) {
+                Log.e(TAG, "RemoteException in sendNiResponse");
+            }
+        }
+        if (notif.needNotify) {
+        // If NI does not need verify or the dialog is not requested
+        // to pop up immediately, the dialog box will not pop up.
+            if (notif.needVerify && mPopupImmediately) {
+                // Popup the dialog box now
+                openNiDialog(notif);
+            } else {
+                // Show the notification
+                setNiNotification(notif);
+            }
+        }
+        // ACCEPT cases: 1. Notify, no verify; 2. no notify, no verify;
+        // 3. privacy override.
+        if (!notif.needVerify || notif.privacyOverride) {
+            try {
+                mNetInitiatedListener.sendNiResponse(notif.notificationId,
+                                                     GPS_NI_RESPONSE_ACCEPT);
+            } catch (RemoteException e) {
+                Log.e(TAG, "RemoteException in sendNiResponse");
+            }
+        }
+    }
+
+    // handle NI from HAL when the SUPL_ES is enabled
+    private void handleNiInEs(GpsNiNotification notif) {
+
+        if (DEBUG) Log.d(TAG, "in handleNiInEs () :"
+                    + " niType: " + notif.niType
+                    + " notificationId: " + notif.notificationId);
+
+        // UE is in emergency mode when in emergency call mode or in emergency call back mode
+        /*
+           1. When SUPL ES bit is off and UE is not in emergency mode:
+                  Call handleNi() to do legacy behaviour.
+           2. When SUPL ES bit is on and UE is in emergency mode:
+                  Call handleNi() to do acceptance behaviour.
+           3. When SUPL ES bit is off but UE is in emergency mode:
+                  Ignore the emergency SUPL INIT.
+           4. When SUPL ES bit is on but UE is not in emergency mode:
+                  Ignore the emergency SUPL INIT.
+        */
+        boolean isNiTypeES = (notif.niType == GPS_NI_TYPE_EMERGENCY_SUPL);
+        if (isNiTypeES != getInEmergency()) {
+            try {
+                mNetInitiatedListener.sendNiResponse(notif.notificationId,
+                                                     GPS_NI_RESPONSE_IGNORE);
+            } catch (RemoteException e) {
+                Log.e(TAG, "RemoteException in sendNiResponse");
+            }
+        } else {
+            handleNi(notif);
+        }
+    }
+
     // Sets the NI notification.
     private synchronized void setNiNotification(GpsNiNotification notif) {
         NotificationManager notificationManager = (NotificationManager) mContext
@@ -202,14 +378,16 @@
             mNiNotification.defaults |= Notification.DEFAULT_SOUND;
         } else {
             mNiNotification.defaults &= ~Notification.DEFAULT_SOUND;
-        }        
+        }
 
         mNiNotification.flags = Notification.FLAG_ONGOING_EVENT | Notification.FLAG_AUTO_CANCEL;
         mNiNotification.tickerText = getNotifTicker(notif, mContext);
 
         // if not to popup dialog immediately, pending intent will open the dialog
         Intent intent = !mPopupImmediately ? getDlgIntent(notif) : new Intent();
-        PendingIntent pi = PendingIntent.getBroadcast(mContext, 0, intent, 0);                
+        PendingIntent pi = PendingIntent.getBroadcast(mContext, 0, intent, 0);
+        mNiNotification.color = mContext.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color);
         mNiNotification.setLatestEventInfo(mContext, title, message, pi);
 
         notificationManager.notifyAsUser(null, notif.notificationId, mNiNotification,
@@ -228,7 +406,7 @@
         mContext.startActivity(intent);
     }
 
-    // Construct the intent for bringing up the dialog activity, which shows the 
+    // Construct the intent for bringing up the dialog activity, which shows the
     // notification and takes user input
     private Intent getDlgIntent(GpsNiNotification notif)
     {
@@ -237,7 +415,7 @@
         String message = getDialogMessage(notif, mContext);
 
         // directly bring up the NI activity
-        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
+        intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);
         intent.setClass(mContext, com.android.internal.app.NetInitiatedActivity.class);
 
         // put data in the intent
@@ -407,7 +585,7 @@
                 decodeString(notif.requestorId, mIsHexInput, notif.requestorIdEncoding),
                 decodeString(notif.text, mIsHexInput, notif.textEncoding));
         return message;
-    }       
+    }
 
     // change this to configure dialog display (for verification)
     static public String getDialogTitle(GpsNiNotification notif, Context context)
diff --git a/media/java/android/media/AudioAttributes.java b/media/java/android/media/AudioAttributes.java
index 308f783..56fa546 100644
--- a/media/java/android/media/AudioAttributes.java
+++ b/media/java/android/media/AudioAttributes.java
@@ -33,7 +33,35 @@
 
 /**
  * A class to encapsulate a collection of attributes describing information about an audio
- * player or recorder.
+ * stream.
+ * <p><code>AudioAttributes</code> supersede the notion of stream types (see for instance
+ * {@link AudioManager#STREAM_MUSIC} or {@link AudioManager#STREAM_ALARM}) for defining the
+ * behavior of audio playback. Attributes allow an application to specify more information than is
+ * conveyed in a stream type by allowing the application to define:
+ * <ul>
+ * <li>usage: "why" you are playing a sound, what is this sound used for. This is achieved with
+ *     the "usage" information. Examples of usage are {@link #USAGE_MEDIA} and {@link #USAGE_ALARM}.
+ *     These two examples are the closest to stream types, but more detailed use cases are
+ *     available. Usage information is more expressive than a stream type, and allows certain
+ *     platforms or routing policies to use this information for more refined volume or routing
+ *     decisions. Usage is the most important information to supply in <code>AudioAttributes</code>
+ *     and it is recommended to build any instance with this information supplied, see
+ *     {@link AudioAttributes.Builder} for exceptions.</li>
+ * <li>content type: "what" you are playing. The content type expresses the general category of
+ *     the content. This information is optional. But in case it is known (for instance
+ *     {@link #CONTENT_TYPE_MOVIE} for a movie streaming service or {@link #CONTENT_TYPE_MUSIC} for
+ *     a music playback application) this information might be used by the audio framework to
+ *     selectively configure some audio post-processing blocks.</li>
+ * <li>flags: "how" is playback to be affected, see the flag definitions for the specific playback
+ *     behaviors they control. </li>
+ * </ul>
+ * <p><code>AudioAttributes</code> are used for example in one of the {@link AudioTrack}
+ * constructors (see {@link AudioTrack#AudioTrack(AudioAttributes, AudioFormat, int, int, int)}),
+ * to configure a {@link MediaPlayer}
+ * (see {@link MediaPlayer#setAudioAttributes(AudioAttributes)} or a
+ * {@link android.app.Notification} (see {@link android.app.Notification#audioAttributes}). An
+ * <code>AudioAttributes</code> instance is built through its builder,
+ * {@link AudioAttributes.Builder}.
  */
 public final class AudioAttributes implements Parcelable {
     private final static String TAG = "AudioAttributes";
@@ -162,16 +190,13 @@
     public final static int FLAG_BEACON = 0x1 << 3;
 
     /**
-     * @hide
-     * CANDIDATE FOR PUBLIC API
      * Flag requesting the use of an output stream supporting hardware A/V synchronization.
      */
-    // TODO  add in FLAG_ALL_PUBLIC when in public API
     public final static int FLAG_HW_AV_SYNC = 0x1 << 4;
 
     private final static int FLAG_ALL = FLAG_AUDIBILITY_ENFORCED | FLAG_SECURE | FLAG_SCO |
             FLAG_BEACON | FLAG_HW_AV_SYNC;
-    private final static int FLAG_ALL_PUBLIC = FLAG_AUDIBILITY_ENFORCED;
+    private final static int FLAG_ALL_PUBLIC = FLAG_AUDIBILITY_ENFORCED | FLAG_HW_AV_SYNC;
 
     private int mUsage = USAGE_UNKNOWN;
     private int mContentType = CONTENT_TYPE_UNKNOWN;
@@ -240,6 +265,22 @@
 
     /**
      * Builder class for {@link AudioAttributes} objects.
+     * <p> Here is an example where <code>Builder</code> is used to define the
+     * {@link AudioAttributes} to be used by a new <code>AudioTrack</code> instance:
+     *
+     * <pre class="prettyprint">
+     * AudioTrack myTrack = new AudioTrack(
+     *         new AudioAttributes.Builder()
+     *             .setUsage(AudioAttributes.USAGE_MEDIA)
+     *             .setContentType(AudioAttributes.CONTENT_TYPE_MUSIC)
+     *             .build(),
+     *         myFormat, myBuffSize, AudioTrack.MODE_STREAM, mySession);
+     * </pre>
+     *
+     * <p>By default all types of information (usage, content type, flags) conveyed by an
+     * <code>AudioAttributes</code> instance are set to "unknown". Unknown information will be
+     * interpreted as a default value that is dependent on the context of use, for instance a
+     * {@link MediaPlayer} will use a default usage of {@link AudioAttributes#USAGE_MEDIA}.
      */
     public static class Builder {
         private int mUsage = USAGE_UNKNOWN;
@@ -250,6 +291,11 @@
 
         /**
          * Constructs a new Builder with the defaults.
+         * By default, usage and content type are respectively {@link AudioAttributes#USAGE_UNKNOWN}
+         * and {@link AudioAttributes#CONTENT_TYPE_UNKNOWN}, and flags are 0. It is recommended to
+         * configure the usage (with {@link #setUsage(int)}) or deriving attributes from a legacy
+         * stream type (with {@link #setLegacyStreamType(int)}) before calling {@link #build()}
+         * to override any default playback behavior in terms of routing and volume management.
          */
         public Builder() {
         }
@@ -376,7 +422,9 @@
         }
 
         /**
-         * Adds attributes inferred from the legacy stream types.
+         * Sets attributes as inferred from the legacy stream types.
+         * Use this method when building an {@link AudioAttributes} instance to initialize some of
+         * the attributes by information derived from a legacy stream type.
          * @param streamType one of {@link AudioManager#STREAM_VOICE_CALL},
          *   {@link AudioManager#STREAM_SYSTEM}, {@link AudioManager#STREAM_RING},
          *   {@link AudioManager#STREAM_MUSIC}, {@link AudioManager#STREAM_ALARM},
@@ -435,7 +483,6 @@
 
         /**
          * @hide
-         * CANDIDATE FOR PUBLIC API
          * Sets the capture preset.
          * Use this audio attributes configuration method when building an {@link AudioRecord}
          * instance with {@link AudioRecord#AudioRecord(AudioAttributes, AudioFormat, int)}.
@@ -530,7 +577,6 @@
         }
     }
 
-    /** @hide */
     public static final Parcelable.Creator<AudioAttributes> CREATOR
             = new Parcelable.Creator<AudioAttributes>() {
         /**
diff --git a/media/java/android/media/AudioDevice.java b/media/java/android/media/AudioDevice.java
index e078354..df4d60d 100644
--- a/media/java/android/media/AudioDevice.java
+++ b/media/java/android/media/AudioDevice.java
@@ -20,90 +20,91 @@
 
 /**
  * Class to provide information about the audio devices.
+ * @hide
  */
 public class AudioDevice {
 
     /**
      * A device type associated with an unknown or uninitialized device.
      */
-    public static final int DEVICE_TYPE_UNKNOWN          = 0;
+    public static final int TYPE_UNKNOWN          = 0;
     /**
      * A device type describing the attached earphone speaker.
      */
-    public static final int DEVICE_TYPE_BUILTIN_EARPIECE = 1;
+    public static final int TYPE_BUILTIN_EARPIECE = 1;
     /**
      * A device type describing the speaker system (i.e. a mono speaker or stereo speakers) built
      * in a device.
      */
-    public static final int DEVICE_TYPE_BUILTIN_SPEAKER  = 2;
+    public static final int TYPE_BUILTIN_SPEAKER  = 2;
     /**
      * A device type describing a headset, which is the combination of a headphones and microphone.
      */
-    public static final int DEVICE_TYPE_WIRED_HEADSET    = 3;
+    public static final int TYPE_WIRED_HEADSET    = 3;
     /**
      * A device type describing a pair of wired headphones .
      */
-    public static final int DEVICE_TYPE_WIRED_HEADPHONES = 4;
+    public static final int TYPE_WIRED_HEADPHONES = 4;
     /**
      * A device type describing an analog line-level connection.
      */
-    public static final int DEVICE_TYPE_LINE_ANALOG      = 5;
+    public static final int TYPE_LINE_ANALOG      = 5;
     /**
      * A device type describing a digital line connection (e.g. SPDIF).
      */
-    public static final int DEVICE_TYPE_LINE_DIGITAL     = 6;
+    public static final int TYPE_LINE_DIGITAL     = 6;
     /**
      * A device type describing a Bluetooth device typically used for telephony .
      */
-    public static final int DEVICE_TYPE_BLUETOOTH_SCO    = 7;
+    public static final int TYPE_BLUETOOTH_SCO    = 7;
     /**
      * A device type describing a Bluetooth device supporting the A2DP profile.
      */
-    public static final int DEVICE_TYPE_BLUETOOTH_A2DP   = 8;
+    public static final int TYPE_BLUETOOTH_A2DP   = 8;
     /**
      * A device type describing an HDMI connection .
      */
-    public static final int DEVICE_TYPE_HDMI             = 9;
+    public static final int TYPE_HDMI             = 9;
     /**
      * A device type describing the Audio Return Channel of an HDMI connection.
      */
-    public static final int DEVICE_TYPE_HDMI_ARC         = 10;
+    public static final int TYPE_HDMI_ARC         = 10;
     /**
      * A device type describing a USB audio device.
      */
-    public static final int DEVICE_TYPE_USB_DEVICE       = 11;
+    public static final int TYPE_USB_DEVICE       = 11;
     /**
      * A device type describing a USB audio device in accessory mode.
      */
-    public static final int DEVICE_TYPE_USB_ACCESSORY    = 12;
+    public static final int TYPE_USB_ACCESSORY    = 12;
     /**
      * A device type describing the audio device associated with a dock.
      */
-    public static final int DEVICE_TYPE_DOCK             = 13;
+    public static final int TYPE_DOCK             = 13;
     /**
      * A device type associated with the transmission of audio signals over FM.
      */
-    public static final int DEVICE_TYPE_FM               = 14;
+    public static final int TYPE_FM               = 14;
     /**
      * A device type describing the microphone(s) built in a device.
      */
-    public static final int DEVICE_TYPE_BUILTIN_MIC      = 15;
+    public static final int TYPE_BUILTIN_MIC      = 15;
     /**
      * A device type for accessing the audio content transmitted over FM.
      */
-    public static final int DEVICE_TYPE_FM_TUNER         = 16;
+    public static final int TYPE_FM_TUNER         = 16;
     /**
      * A device type for accessing the audio content transmitted over the TV tuner system.
      */
-    public static final int DEVICE_TYPE_TV_TUNER         = 17;
+    public static final int TYPE_TV_TUNER         = 17;
     /**
      * A device type describing the transmission of audio signals over the telephony network.
      */
-    public static final int DEVICE_TYPE_TELEPHONY        = 18;
+    public static final int TYPE_TELEPHONY        = 18;
     /**
      * A device type describing the auxiliary line-level connectors.
      */
-    public static final int DEVICE_TYPE_AUX_LINE         = 19;
+    public static final int TYPE_AUX_LINE         = 19;
 
     AudioDevicePortConfig mConfig;
 
@@ -135,7 +136,7 @@
      * @return
      */
     public int getDeviceType() {
-        return INT_TO_EXT_DEVICE_MAPPING.get(mConfig.port().type(), DEVICE_TYPE_UNKNOWN);
+        return INT_TO_EXT_DEVICE_MAPPING.get(mConfig.port().type(), TYPE_UNKNOWN);
     }
 
     /**
@@ -154,7 +155,7 @@
 
     /** @hide */
     public static int convertInternalDeviceToDeviceType(int intDevice) {
-        return INT_TO_EXT_DEVICE_MAPPING.get(intDevice, DEVICE_TYPE_UNKNOWN);
+        return INT_TO_EXT_DEVICE_MAPPING.get(intDevice, TYPE_UNKNOWN);
     }
 
     private static final SparseIntArray INT_TO_EXT_DEVICE_MAPPING;
@@ -163,43 +164,43 @@
 
     static {
         INT_TO_EXT_DEVICE_MAPPING = new SparseIntArray();
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_EARPIECE, DEVICE_TYPE_BUILTIN_EARPIECE);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_SPEAKER, DEVICE_TYPE_BUILTIN_SPEAKER);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_WIRED_HEADSET, DEVICE_TYPE_WIRED_HEADSET);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_WIRED_HEADPHONE, DEVICE_TYPE_WIRED_HEADPHONES);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO, DEVICE_TYPE_BLUETOOTH_SCO);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO_HEADSET, DEVICE_TYPE_BLUETOOTH_SCO);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO_CARKIT, DEVICE_TYPE_BLUETOOTH_SCO);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP, DEVICE_TYPE_BLUETOOTH_A2DP);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES, DEVICE_TYPE_BLUETOOTH_A2DP);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER, DEVICE_TYPE_BLUETOOTH_A2DP);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_HDMI, DEVICE_TYPE_HDMI);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_ANLG_DOCK_HEADSET, DEVICE_TYPE_DOCK);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_DGTL_DOCK_HEADSET, DEVICE_TYPE_DOCK);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_USB_ACCESSORY, DEVICE_TYPE_USB_ACCESSORY);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_USB_DEVICE, DEVICE_TYPE_USB_DEVICE);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_TELEPHONY_TX, DEVICE_TYPE_TELEPHONY);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_LINE, DEVICE_TYPE_LINE_ANALOG);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_HDMI_ARC, DEVICE_TYPE_HDMI_ARC);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_SPDIF, DEVICE_TYPE_LINE_DIGITAL);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_FM, DEVICE_TYPE_FM);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_AUX_LINE, DEVICE_TYPE_AUX_LINE);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_EARPIECE, TYPE_BUILTIN_EARPIECE);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_SPEAKER, TYPE_BUILTIN_SPEAKER);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_WIRED_HEADSET, TYPE_WIRED_HEADSET);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_WIRED_HEADPHONE, TYPE_WIRED_HEADPHONES);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO, TYPE_BLUETOOTH_SCO);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO_HEADSET, TYPE_BLUETOOTH_SCO);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_SCO_CARKIT, TYPE_BLUETOOTH_SCO);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP, TYPE_BLUETOOTH_A2DP);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP_HEADPHONES, TYPE_BLUETOOTH_A2DP);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP_SPEAKER, TYPE_BLUETOOTH_A2DP);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_HDMI, TYPE_HDMI);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_ANLG_DOCK_HEADSET, TYPE_DOCK);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_DGTL_DOCK_HEADSET, TYPE_DOCK);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_USB_ACCESSORY, TYPE_USB_ACCESSORY);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_USB_DEVICE, TYPE_USB_DEVICE);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_TELEPHONY_TX, TYPE_TELEPHONY);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_LINE, TYPE_LINE_ANALOG);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_HDMI_ARC, TYPE_HDMI_ARC);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_SPDIF, TYPE_LINE_DIGITAL);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_FM, TYPE_FM);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_OUT_AUX_LINE, TYPE_AUX_LINE);
 
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BUILTIN_MIC, DEVICE_TYPE_BUILTIN_MIC);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BLUETOOTH_SCO_HEADSET, DEVICE_TYPE_BLUETOOTH_SCO);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_WIRED_HEADSET, DEVICE_TYPE_WIRED_HEADSET);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_HDMI, DEVICE_TYPE_HDMI);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_TELEPHONY_RX, DEVICE_TYPE_TELEPHONY);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BACK_MIC, DEVICE_TYPE_BUILTIN_MIC);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_ANLG_DOCK_HEADSET, DEVICE_TYPE_DOCK);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_DGTL_DOCK_HEADSET, DEVICE_TYPE_DOCK);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_USB_ACCESSORY, DEVICE_TYPE_USB_ACCESSORY);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_USB_DEVICE, DEVICE_TYPE_USB_DEVICE);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_FM_TUNER, DEVICE_TYPE_FM_TUNER);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_TV_TUNER, DEVICE_TYPE_TV_TUNER);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_LINE, DEVICE_TYPE_LINE_ANALOG);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_SPDIF, DEVICE_TYPE_LINE_DIGITAL);
-        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BLUETOOTH_A2DP, DEVICE_TYPE_BLUETOOTH_A2DP);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BUILTIN_MIC, TYPE_BUILTIN_MIC);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BLUETOOTH_SCO_HEADSET, TYPE_BLUETOOTH_SCO);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_WIRED_HEADSET, TYPE_WIRED_HEADSET);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_HDMI, TYPE_HDMI);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_TELEPHONY_RX, TYPE_TELEPHONY);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BACK_MIC, TYPE_BUILTIN_MIC);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_ANLG_DOCK_HEADSET, TYPE_DOCK);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_DGTL_DOCK_HEADSET, TYPE_DOCK);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_USB_ACCESSORY, TYPE_USB_ACCESSORY);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_USB_DEVICE, TYPE_USB_DEVICE);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_FM_TUNER, TYPE_FM_TUNER);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_TV_TUNER, TYPE_TV_TUNER);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_LINE, TYPE_LINE_ANALOG);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_SPDIF, TYPE_LINE_DIGITAL);
+        INT_TO_EXT_DEVICE_MAPPING.put(AudioSystem.DEVICE_IN_BLUETOOTH_A2DP, TYPE_BLUETOOTH_A2DP);
 
         // not covered here, legacy
         //AudioSystem.DEVICE_OUT_REMOTE_SUBMIX
@@ -207,25 +208,25 @@
 
         // privileges mapping to output device
         EXT_TO_INT_DEVICE_MAPPING = new SparseIntArray();
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_BUILTIN_EARPIECE, AudioSystem.DEVICE_OUT_EARPIECE);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_BUILTIN_SPEAKER, AudioSystem.DEVICE_OUT_SPEAKER);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_WIRED_HEADSET, AudioSystem.DEVICE_OUT_WIRED_HEADSET);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_WIRED_HEADPHONES, AudioSystem.DEVICE_OUT_WIRED_HEADPHONE);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_LINE_ANALOG, AudioSystem.DEVICE_OUT_LINE);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_LINE_DIGITAL, AudioSystem.DEVICE_OUT_SPDIF);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_BLUETOOTH_SCO, AudioSystem.DEVICE_OUT_BLUETOOTH_SCO);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_BLUETOOTH_A2DP, AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_HDMI, AudioSystem.DEVICE_OUT_HDMI);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_HDMI_ARC, AudioSystem.DEVICE_OUT_HDMI_ARC);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_USB_DEVICE, AudioSystem.DEVICE_OUT_USB_DEVICE);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_USB_ACCESSORY, AudioSystem.DEVICE_OUT_USB_ACCESSORY);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_DOCK, AudioSystem.DEVICE_OUT_ANLG_DOCK_HEADSET);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_FM, AudioSystem.DEVICE_OUT_FM);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_BUILTIN_MIC, AudioSystem.DEVICE_IN_BUILTIN_MIC);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_FM_TUNER, AudioSystem.DEVICE_IN_FM_TUNER);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_TV_TUNER, AudioSystem.DEVICE_IN_TV_TUNER);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_TELEPHONY, AudioSystem.DEVICE_OUT_TELEPHONY_TX);
-        EXT_TO_INT_DEVICE_MAPPING.put(DEVICE_TYPE_AUX_LINE, AudioSystem.DEVICE_OUT_AUX_LINE);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_BUILTIN_EARPIECE, AudioSystem.DEVICE_OUT_EARPIECE);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_BUILTIN_SPEAKER, AudioSystem.DEVICE_OUT_SPEAKER);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_WIRED_HEADSET, AudioSystem.DEVICE_OUT_WIRED_HEADSET);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_WIRED_HEADPHONES, AudioSystem.DEVICE_OUT_WIRED_HEADPHONE);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_LINE_ANALOG, AudioSystem.DEVICE_OUT_LINE);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_LINE_DIGITAL, AudioSystem.DEVICE_OUT_SPDIF);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_BLUETOOTH_SCO, AudioSystem.DEVICE_OUT_BLUETOOTH_SCO);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_BLUETOOTH_A2DP, AudioSystem.DEVICE_OUT_BLUETOOTH_A2DP);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_HDMI, AudioSystem.DEVICE_OUT_HDMI);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_HDMI_ARC, AudioSystem.DEVICE_OUT_HDMI_ARC);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_USB_DEVICE, AudioSystem.DEVICE_OUT_USB_DEVICE);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_USB_ACCESSORY, AudioSystem.DEVICE_OUT_USB_ACCESSORY);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_DOCK, AudioSystem.DEVICE_OUT_ANLG_DOCK_HEADSET);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_FM, AudioSystem.DEVICE_OUT_FM);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_BUILTIN_MIC, AudioSystem.DEVICE_IN_BUILTIN_MIC);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_FM_TUNER, AudioSystem.DEVICE_IN_FM_TUNER);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_TV_TUNER, AudioSystem.DEVICE_IN_TV_TUNER);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_TELEPHONY, AudioSystem.DEVICE_OUT_TELEPHONY_TX);
+        EXT_TO_INT_DEVICE_MAPPING.put(TYPE_AUX_LINE, AudioSystem.DEVICE_OUT_AUX_LINE);
     }
 }
 
diff --git a/media/java/android/media/AudioFormat.java b/media/java/android/media/AudioFormat.java
index d93d81b..58ed4f8 100644
--- a/media/java/android/media/AudioFormat.java
+++ b/media/java/android/media/AudioFormat.java
@@ -320,15 +320,26 @@
 
     /**
      * Builder class for {@link AudioFormat} objects.
+     * Use this class to configure and create an AudioFormat instance. By setting format
+     * characteristics such as audio encoding, channel mask or sample rate, you indicate which
+     * of those are to vary from the default behavior on this device wherever this audio format
+     * is used.
+     * <p>{@link AudioFormat} is for instance used in
+     * {@link AudioTrack#AudioTrack(AudioAttributes, AudioFormat, int, int, int)}. In this
+     * constructor, every format characteristic set on the <code>Builder</code> (e.g. with
+     * {@link #setSampleRate(int)}) will alter the default values used by an
+     * <code>AudioTrack</code>. In this case for audio playback with <code>AudioTrack</code>, the
+     * sample rate set in the <code>Builder</code> would override the platform output sample rate
+     * which would otherwise be selected by default.
      */
     public static class Builder {
-        private int mEncoding = ENCODING_PCM_16BIT;
+        private int mEncoding = ENCODING_INVALID;
         private int mSampleRate = 0;
         private int mChannelMask = CHANNEL_INVALID;
         private int mPropertySetMask = AUDIO_FORMAT_HAS_PROPERTY_NONE;
 
         /**
-         * Constructs a new Builder with the defaults format values.
+         * Constructs a new Builder with none of the format characteristics set.
          */
         public Builder() {
         }
diff --git a/media/java/android/media/AudioManager.java b/media/java/android/media/AudioManager.java
index 6a76a71..559c247 100644
--- a/media/java/android/media/AudioManager.java
+++ b/media/java/android/media/AudioManager.java
@@ -19,6 +19,7 @@
 import android.Manifest;
 import android.annotation.SdkConstant;
 import android.annotation.SdkConstant.SdkConstantType;
+import android.annotation.SystemApi;
 import android.app.PendingIntent;
 import android.bluetooth.BluetoothDevice;
 import android.content.ComponentName;
@@ -36,6 +37,7 @@
 import android.os.IBinder;
 import android.os.Looper;
 import android.os.Message;
+import android.os.Process;
 import android.os.RemoteException;
 import android.os.SystemClock;
 import android.os.ServiceManager;
@@ -206,6 +208,125 @@
     public static final String EXTRA_MASTER_VOLUME_MUTED =
         "android.media.EXTRA_MASTER_VOLUME_MUTED";
 
+    /**
+     * Broadcast Action: Wired Headset plugged in or unplugged.
+     *
+     * You <em>cannot</em> receive this through components declared
+     * in manifests, only by explicitly registering for it with
+     * {@link Context#registerReceiver(BroadcastReceiver, IntentFilter)
+     * Context.registerReceiver()}.
+     *
+     * <p>The intent will have the following extra values:
+     * <ul>
+     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
+     *   <li><em>name</em> - Headset type, human readable string </li>
+     *   <li><em>microphone</em> - 1 if headset has a microphone, 0 otherwise </li>
+     * </ul>
+     * </ul>
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_HEADSET_PLUG =
+            "android.intent.action.HEADSET_PLUG";
+
+    /**
+     * Broadcast Action: A sticky broadcast indicating an HMDI cable was plugged or unplugged
+     *
+     * The intent will have the following extra values: {@link #EXTRA_AUDIO_PLUG_STATE},
+     * {@link #EXTRA_MAX_CHANNEL_COUNT}, {@link #EXTRA_ENCODINGS}.
+     * <p>It can only be received by explicitly registering for it with
+     * {@link Context#registerReceiver(BroadcastReceiver, IntentFilter)}.
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_HDMI_AUDIO_PLUG =
+            "android.media.action.HDMI_AUDIO_PLUG";
+
+    /**
+     * Extra used in {@link #ACTION_HDMI_AUDIO_PLUG} to communicate whether HDMI is plugged in
+     * or unplugged.
+     * An integer value of 1 indicates a plugged-in state, 0 is unplugged.
+     */
+    public static final String EXTRA_AUDIO_PLUG_STATE = "android.media.extra.AUDIO_PLUG_STATE";
+
+    /**
+     * Extra used in {@link #ACTION_HDMI_AUDIO_PLUG} to define the maximum number of channels
+     * supported by the HDMI device.
+     * The corresponding integer value is only available when the device is plugged in (as expressed
+     * by {@link #EXTRA_AUDIO_PLUG_STATE}).
+     */
+    public static final String EXTRA_MAX_CHANNEL_COUNT = "android.media.extra.MAX_CHANNEL_COUNT";
+
+    /**
+     * Extra used in {@link #ACTION_HDMI_AUDIO_PLUG} to define the audio encodings supported by
+     * the connected HDMI device.
+     * The corresponding array of encoding values is only available when the device is plugged in
+     * (as expressed by {@link #EXTRA_AUDIO_PLUG_STATE}). Encoding values are defined in
+     * {@link AudioFormat} (for instance see {@link AudioFormat#ENCODING_PCM_16BIT}). Use
+     * {@link android.content.Intent#getIntArrayExtra(String)} to retrieve the encoding values.
+     */
+    public static final String EXTRA_ENCODINGS = "android.media.extra.ENCODINGS";
+
+    /**
+     * Broadcast Action: An analog audio speaker/headset plugged in or unplugged.
+     *
+     * <p>The intent will have the following extra values:
+     * <ul>
+     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
+     *   <li><em>name</em> - Headset type, human readable string </li>
+     * </ul>
+     * </ul>
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_ANALOG_AUDIO_DOCK_PLUG =
+            "android.media.action.ANALOG_AUDIO_DOCK_PLUG";
+
+    /**
+     * Broadcast Action: A digital audio speaker/headset plugged in or unplugged.
+     *
+     * <p>The intent will have the following extra values:
+     * <ul>
+     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
+     *   <li><em>name</em> - Headset type, human readable string </li>
+     * </ul>
+     * </ul>
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_DIGITAL_AUDIO_DOCK_PLUG =
+            "android.media.action.DIGITAL_AUDIO_DOCK_PLUG";
+
+    /**
+     * Broadcast Action: A USB audio accessory was plugged in or unplugged.
+     *
+     * <p>The intent will have the following extra values:
+     * <ul>
+     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
+     *   <li><em>card</em> - ALSA card number (integer) </li>
+     *   <li><em>device</em> - ALSA device number (integer) </li>
+     * </ul>
+     * </ul>
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_USB_AUDIO_ACCESSORY_PLUG =
+            "android.media.action.USB_AUDIO_ACCESSORY_PLUG";
+
+    /**
+     * Broadcast Action: A USB audio device was plugged in or unplugged.
+     *
+     * <p>The intent will have the following extra values:
+     * <ul>
+     *   <li><em>state</em> - 0 for unplugged, 1 for plugged. </li>
+     *   <li><em>card</em> - ALSA card number (integer) </li>
+     *   <li><em>device</em> - ALSA device number (integer) </li>
+     * </ul>
+     * </ul>
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String ACTION_USB_AUDIO_DEVICE_PLUG =
+            "android.media.action.USB_AUDIO_DEVICE_PLUG";
+
     /** The audio stream for phone calls */
     public static final int STREAM_VOICE_CALL = AudioSystem.STREAM_VOICE_CALL;
     /** The audio stream for system sounds */
@@ -1688,11 +1809,19 @@
 
     /**
      * Return a new audio session identifier not associated with any player or effect.
-     * It can for instance be used to create one of the {@link android.media.audiofx.AudioEffect}
-     * objects or specify a session for speech synthesis in
-     * {@link android.speech.tts.TextToSpeech.Engine}.
+     * An audio session identifier is a system wide unique identifier for a set of audio streams
+     * (one or more mixed together).
+     * <p>The primary use of the audio session ID is to associate audio effects to audio players,
+     * such as {@link MediaPlayer} or {@link AudioTrack}: all audio effects sharing the same audio
+     * session ID will be applied to the mixed audio content of the players that share the same
+     * audio session.
+     * <p>This method can for instance be used when creating one of the
+     * {@link android.media.audiofx.AudioEffect} objects to define the audio session of the effect,
+     * or to specify a session for a speech synthesis utterance
+     * in {@link android.speech.tts.TextToSpeech.Engine}.
      * @return a new unclaimed and unused audio session identifier, or {@link #ERROR} when the
-     *   system failed to generate a new session.
+     *   system failed to generate a new session, a condition in which audio playback or recording
+     *   will subsequently fail as well.
      */
     public int generateAudioSessionId() {
         int session = AudioSystem.newAudioSessionId();
@@ -1832,7 +1961,42 @@
             return;
         }
 
-        if (!querySoundEffectsEnabled()) {
+        if (!querySoundEffectsEnabled(Process.myUserHandle().getIdentifier())) {
+            return;
+        }
+
+        IAudioService service = getService();
+        try {
+            service.playSoundEffect(effectType);
+        } catch (RemoteException e) {
+            Log.e(TAG, "Dead object in playSoundEffect"+e);
+        }
+    }
+
+    /**
+     * Plays a sound effect (Key clicks, lid open/close...)
+     * @param effectType The type of sound effect. One of
+     *            {@link #FX_KEY_CLICK},
+     *            {@link #FX_FOCUS_NAVIGATION_UP},
+     *            {@link #FX_FOCUS_NAVIGATION_DOWN},
+     *            {@link #FX_FOCUS_NAVIGATION_LEFT},
+     *            {@link #FX_FOCUS_NAVIGATION_RIGHT},
+     *            {@link #FX_KEYPRESS_STANDARD},
+     *            {@link #FX_KEYPRESS_SPACEBAR},
+     *            {@link #FX_KEYPRESS_DELETE},
+     *            {@link #FX_KEYPRESS_RETURN},
+     *            {@link #FX_KEYPRESS_INVALID},
+     * @param userId The current user to pull sound settings from
+     * NOTE: This version uses the UI settings to determine
+     * whether sounds are heard or not.
+     * @hide
+     */
+    public void  playSoundEffect(int effectType, int userId) {
+        if (effectType < 0 || effectType >= NUM_SOUND_EFFECTS) {
+            return;
+        }
+
+        if (!querySoundEffectsEnabled(userId)) {
             return;
         }
 
@@ -1879,8 +2043,9 @@
     /**
      * Settings has an in memory cache, so this is fast.
      */
-    private boolean querySoundEffectsEnabled() {
-        return Settings.System.getInt(mContext.getContentResolver(), Settings.System.SOUND_EFFECTS_ENABLED, 0) != 0;
+    private boolean querySoundEffectsEnabled(int user) {
+        return Settings.System.getIntForUser(mContext.getContentResolver(),
+                Settings.System.SOUND_EFFECTS_ENABLED, 0, user) != 0;
     }
 
 
@@ -2332,18 +2497,21 @@
     }
 
     /**
-     * Registers a {@link RemoteController} instance for it to receive media metadata updates
-     * and playback state information from applications using {@link RemoteControlClient}, and
-     * control their playback.
-     * <p>Registration requires the {@link OnClientUpdateListener} listener to be one of the
-     * enabled notification listeners (see
+     * Registers a {@link RemoteController} instance for it to receive media
+     * metadata updates and playback state information from applications using
+     * {@link RemoteControlClient}, and control their playback.
+     * <p>
+     * Registration requires the {@link OnClientUpdateListener} listener to be
+     * one of the enabled notification listeners (see
      * {@link android.service.notification.NotificationListenerService}).
+     *
      * @param rctlr the object to register.
-     * @return true if the {@link RemoteController} was successfully registered, false if an
-     *     error occurred, due to an internal system error, or insufficient permissions.
+     * @return true if the {@link RemoteController} was successfully registered,
+     *         false if an error occurred, due to an internal system error, or
+     *         insufficient permissions.
      * @deprecated Use
-     * {@link MediaSessionManager#addActiveSessionsListener(android.media.session.MediaSessionManager.SessionListener, ComponentName)}
-     * and {@link MediaController} instead.
+     *             {@link MediaSessionManager#addOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener, ComponentName)}
+     *             and {@link MediaController} instead.
      */
     @Deprecated
     public boolean registerRemoteController(RemoteController rctlr) {
@@ -2355,12 +2523,14 @@
     }
 
     /**
-     * Unregisters a {@link RemoteController}, causing it to no longer receive media metadata and
-     * playback state information, and no longer be capable of controlling playback.
+     * Unregisters a {@link RemoteController}, causing it to no longer receive
+     * media metadata and playback state information, and no longer be capable
+     * of controlling playback.
+     *
      * @param rctlr the object to unregister.
      * @deprecated Use
-     * {@link MediaSessionManager#removeActiveSessionsListener(android.media.session.MediaSessionManager.SessionListener)}
-     * instead.
+     *             {@link MediaSessionManager#removeOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener)}
+     *             instead.
      */
     @Deprecated
     public void unregisterRemoteController(RemoteController rctlr) {
@@ -2989,6 +3159,21 @@
     }
 
     /**
+     * Returns true if Hdmi Cec system audio mode is supported.
+     *
+     * @hide
+     */
+    @SystemApi
+    public boolean isHdmiSystemAudioSupported() {
+        try {
+            return getService().isHdmiSystemAudioSupported();
+        } catch (RemoteException e) {
+            Log.w(TAG, "Error querying system audio mode", e);
+            return false;
+        }
+    }
+
+    /**
      * Return codes for listAudioPorts(), createAudioPatch() ...
      */
 
diff --git a/media/java/android/media/AudioManagerInternal.java b/media/java/android/media/AudioManagerInternal.java
index 6f1bdef..7c0d758 100644
--- a/media/java/android/media/AudioManagerInternal.java
+++ b/media/java/android/media/AudioManagerInternal.java
@@ -26,6 +26,10 @@
  */
 public abstract class AudioManagerInternal {
 
+    public abstract void adjustSuggestedStreamVolumeForUid(int streamType, int direction,
+            int flags,
+            String callingPackage, int uid);
+
     public abstract void adjustStreamVolumeForUid(int streamType, int direction, int flags,
             String callingPackage, int uid);
 
diff --git a/media/java/android/media/AudioPortEventHandler.java b/media/java/android/media/AudioPortEventHandler.java
index 8d2c172..9db4994 100644
--- a/media/java/android/media/AudioPortEventHandler.java
+++ b/media/java/android/media/AudioPortEventHandler.java
@@ -47,10 +47,7 @@
         mListeners = new ArrayList<AudioManager.OnAudioPortUpdateListener>();
 
         // find the looper for our new event handler
-        Looper looper = Looper.myLooper();
-        if (looper == null) {
-            looper = Looper.getMainLooper();
-        }
+        Looper looper = Looper.getMainLooper();
 
         if (looper != null) {
             mHandler = new Handler(looper) {
diff --git a/media/java/android/media/AudioService.java b/media/java/android/media/AudioService.java
index 0af2457..71a05ab 100644
--- a/media/java/android/media/AudioService.java
+++ b/media/java/android/media/AudioService.java
@@ -25,7 +25,6 @@
 import android.app.ActivityManagerNative;
 import android.app.AppOpsManager;
 import android.app.KeyguardManager;
-import android.app.PendingIntent;
 import android.bluetooth.BluetoothA2dp;
 import android.bluetooth.BluetoothAdapter;
 import android.bluetooth.BluetoothClass;
@@ -68,7 +67,7 @@
 import android.os.Vibrator;
 import android.provider.Settings;
 import android.provider.Settings.System;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.text.TextUtils;
 import android.util.Log;
 import android.util.MathUtils;
@@ -76,6 +75,7 @@
 import android.view.KeyEvent;
 import android.view.Surface;
 import android.view.WindowManager;
+import android.view.accessibility.AccessibilityManager;
 
 import com.android.internal.telephony.ITelephony;
 import com.android.internal.util.XmlUtils;
@@ -200,6 +200,7 @@
     private static final int MSG_UNLOAD_SOUND_EFFECTS = 20;
     private static final int MSG_SYSTEM_READY = 21;
     private static final int MSG_PERSIST_MUSIC_ACTIVE_MS = 22;
+    private static final int MSG_PERSIST_MICROPHONE_MUTE = 23;
     // start of messages handled under wakelock
     //   these messages can only be queued, i.e. sent with queueMsgUnderWakeLock(),
     //   and not with sendMsg(..., ..., SENDMSG_QUEUE, ...)
@@ -450,11 +451,6 @@
     private Looper mSoundPoolLooper = null;
     // volume applied to sound played with playSoundEffect()
     private static int sSoundEffectVolumeDb;
-    // getActiveStreamType() will return:
-    // - STREAM_NOTIFICATION on tablets during this period after a notification stopped
-    // - STREAM_MUSIC on phones during this period after music or talkback/voice search prompt
-    // stopped
-    private static final int DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS = 5000;
     // previous volume adjustment direction received by checkForRingerModeChange()
     private int mPrevVolDirection = AudioManager.ADJUST_SAME;
     // Keyguard manager proxy
@@ -543,6 +539,9 @@
         MAX_STREAM_VOLUME[AudioSystem.STREAM_VOICE_CALL] = SystemProperties.getInt(
             "ro.config.vc_call_vol_steps",
            MAX_STREAM_VOLUME[AudioSystem.STREAM_VOICE_CALL]);
+        MAX_STREAM_VOLUME[AudioSystem.STREAM_MUSIC] = SystemProperties.getInt(
+            "ro.config.media_vol_steps",
+           MAX_STREAM_VOLUME[AudioSystem.STREAM_MUSIC]);
 
         sSoundEffectVolumeDb = context.getResources().getInteger(
                 com.android.internal.R.integer.config_soundEffectVolumeDb);
@@ -598,8 +597,8 @@
                 new IntentFilter(BluetoothHeadset.ACTION_AUDIO_STATE_CHANGED);
         intentFilter.addAction(BluetoothHeadset.ACTION_CONNECTION_STATE_CHANGED);
         intentFilter.addAction(Intent.ACTION_DOCK_EVENT);
-        intentFilter.addAction(Intent.ACTION_USB_AUDIO_ACCESSORY_PLUG);
-        intentFilter.addAction(Intent.ACTION_USB_AUDIO_DEVICE_PLUG);
+        intentFilter.addAction(AudioManager.ACTION_USB_AUDIO_ACCESSORY_PLUG);
+        intentFilter.addAction(AudioManager.ACTION_USB_AUDIO_DEVICE_PLUG);
         intentFilter.addAction(Intent.ACTION_SCREEN_ON);
         intentFilter.addAction(Intent.ACTION_SCREEN_OFF);
         intentFilter.addAction(Intent.ACTION_USER_SWITCHED);
@@ -667,6 +666,9 @@
         if (mHdmiManager != null) {
             synchronized (mHdmiManager) {
                 mHdmiTvClient = mHdmiManager.getTvClient();
+                if (mHdmiTvClient != null) {
+                    mFixedVolumeDevices &= ~AudioSystem.DEVICE_ALL_HDMI_SYSTEM_AUDIO_AND_SPEAKER;
+                }
                 mHdmiPlaybackClient = mHdmiManager.getPlaybackClient();
                 mHdmiCecSink = false;
             }
@@ -679,6 +681,8 @@
                 0,
                 null,
                 SAFE_VOLUME_CONFIGURE_TIMEOUT_MS);
+
+        StreamOverride.init(mContext);
     }
 
     private void createAudioSystemThread() {
@@ -873,6 +877,10 @@
         AudioSystem.setMasterMute(masterMute);
         broadcastMasterMuteStatus(masterMute);
 
+        boolean microphoneMute =
+                System.getIntForUser(cr, System.MICROPHONE_MUTE, 0, UserHandle.USER_CURRENT) == 1;
+        AudioSystem.muteMicrophone(microphoneMute);
+
         // Each stream will read its own persisted settings
 
         // Broadcast the sticky intent
@@ -896,6 +904,12 @@
     /** @see AudioManager#adjustVolume(int, int) */
     public void adjustSuggestedStreamVolume(int direction, int suggestedStreamType, int flags,
             String callingPackage) {
+        adjustSuggestedStreamVolume(direction, suggestedStreamType, flags, callingPackage,
+                Binder.getCallingUid());
+    }
+
+    private void adjustSuggestedStreamVolume(int direction, int suggestedStreamType, int flags,
+            String callingPackage, int uid) {
         if (DEBUG_VOL) Log.d(TAG, "adjustSuggestedStreamVolume() stream="+suggestedStreamType
                 + ", flags=" + flags);
         int streamType;
@@ -920,7 +934,7 @@
             if (DEBUG_VOL) Log.d(TAG, "Volume controller suppressed adjustment");
         }
 
-        adjustStreamVolume(streamType, direction, flags, callingPackage);
+        adjustStreamVolume(streamType, direction, flags, callingPackage, uid);
     }
 
     /** @see AudioManager#adjustStreamVolume(int, int, int) */
@@ -1337,6 +1351,16 @@
             streamType = AudioSystem.STREAM_NOTIFICATION;
         }
 
+        // If Hdmi-CEC system audio mode is on, show volume bar
+        // only when TV receives volume notification from Audio Receiver.
+        if (mHdmiTvClient != null && streamType == AudioSystem.STREAM_MUSIC) {
+            synchronized (mHdmiTvClient) {
+                if (mHdmiSystemAudioSupported &&
+                        ((flags & AudioManager.FLAG_HDMI_SYSTEM_AUDIO_VOLUME) == 0)) {
+                    flags &= ~AudioManager.FLAG_SHOW_UI;
+                }
+            }
+        }
         mVolumeController.postVolumeChanged(streamType, flags);
 
         if ((flags & AudioManager.FLAG_FIXED_VOLUME) == 0) {
@@ -1447,17 +1471,15 @@
         if (mUseFixedVolume) {
             return;
         }
-
         if (mAppOps.noteOp(AppOpsManager.OP_AUDIO_MASTER_VOLUME, Binder.getCallingUid(),
                 callingPackage) != AppOpsManager.MODE_ALLOWED) {
             return;
         }
-
         if (state != AudioSystem.getMasterMute()) {
             AudioSystem.setMasterMute(state);
             // Post a persist master volume msg
             sendMsg(mAudioHandler, MSG_PERSIST_MASTER_VOLUME_MUTE, SENDMSG_REPLACE, state ? 1
-                    : 0, 0, null, PERSIST_DELAY);
+                    : 0, UserHandle.getCallingUserId(), null, PERSIST_DELAY);
             sendMasterMuteUpdate(state, flags);
         }
     }
@@ -1561,8 +1583,14 @@
                 callingPackage) != AppOpsManager.MODE_ALLOWED) {
             return;
         }
+        if (!checkAudioSettingsPermission("setMicrophoneMute()")) {
+            return;
+        }
 
         AudioSystem.muteMicrophone(on);
+        // Post a persist microphone msg.
+        sendMsg(mAudioHandler, MSG_PERSIST_MICROPHONE_MUTE, SENDMSG_REPLACE, on ? 1
+                : 0, UserHandle.getCallingUserId(), null, PERSIST_DELAY);
     }
 
     /** @see AudioManager#getRingerMode() */
@@ -1765,6 +1793,15 @@
             return;
         }
 
+        if ( (mode == AudioSystem.MODE_IN_CALL) &&
+                (mContext.checkCallingOrSelfPermission(
+                        android.Manifest.permission.MODIFY_PHONE_STATE)
+                            != PackageManager.PERMISSION_GRANTED)) {
+            Log.w(TAG, "MODIFY_PHONE_STATE Permission Denial: setMode(MODE_IN_CALL) from pid="
+                    + Binder.getCallingPid() + ", uid=" + Binder.getCallingUid());
+            return;
+        }
+
         if (mode < AudioSystem.MODE_CURRENT || mode >= AudioSystem.NUM_MODES) {
             return;
         }
@@ -1786,7 +1823,7 @@
     // must be called synchronized on mSetModeDeathHandlers
     // setModeInt() returns a valid PID if the audio mode was successfully set to
     // any mode other than NORMAL.
-    int setModeInt(int mode, IBinder cb, int pid) {
+    private int setModeInt(int mode, IBinder cb, int pid) {
         if (DEBUG_MODE) { Log.v(TAG, "setModeInt(mode=" + mode + ", pid=" + pid + ")"); }
         int newModeOwnerPid = 0;
         if (cb == null) {
@@ -2912,13 +2949,13 @@
     }
 
     private boolean isInCommunication() {
-        boolean isInAPhoneCall = false;
+        boolean IsInCall = false;
 
-        TelecommManager telecommManager =
-                (TelecommManager) mContext.getSystemService(Context.TELECOMM_SERVICE);
-        isInAPhoneCall = telecommManager.isInAPhoneCall();
+        TelecomManager telecomManager =
+                (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
+        IsInCall = telecomManager.isInCall();
 
-        return (isInAPhoneCall || getMode() == AudioManager.MODE_IN_COMMUNICATION);
+        return (IsInCall || getMode() == AudioManager.MODE_IN_COMMUNICATION);
     }
 
     /**
@@ -2945,7 +2982,7 @@
                     return AudioSystem.STREAM_VOICE_CALL;
                 }
             } else if (suggestedStreamType == AudioManager.USE_DEFAULT_STREAM_TYPE) {
-                if (isAfMusicActiveRecently(DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS)) {
+                if (isAfMusicActiveRecently(StreamOverride.sDelayMs)) {
                     if (DEBUG_VOL)
                         Log.v(TAG, "getActiveStreamType: Forcing STREAM_MUSIC stream active");
                     return AudioSystem.STREAM_MUSIC;
@@ -2977,13 +3014,13 @@
                     return AudioSystem.STREAM_VOICE_CALL;
                 }
             } else if (AudioSystem.isStreamActive(AudioSystem.STREAM_NOTIFICATION,
-                    DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS) ||
+                    StreamOverride.sDelayMs) ||
                     AudioSystem.isStreamActive(AudioSystem.STREAM_RING,
-                            DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS)) {
+                            StreamOverride.sDelayMs)) {
                 if (DEBUG_VOL) Log.v(TAG, "getActiveStreamType: Forcing STREAM_NOTIFICATION");
                 return AudioSystem.STREAM_NOTIFICATION;
             } else if (suggestedStreamType == AudioManager.USE_DEFAULT_STREAM_TYPE) {
-                if (isAfMusicActiveRecently(DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS)) {
+                if (isAfMusicActiveRecently(StreamOverride.sDelayMs)) {
                     if (DEBUG_VOL) Log.v(TAG, "getActiveStreamType: forcing STREAM_MUSIC");
                     return AudioSystem.STREAM_MUSIC;
                 } else {
@@ -3046,7 +3083,7 @@
     }
 
     boolean checkAudioSettingsPermission(String method) {
-        if (mContext.checkCallingOrSelfPermission("android.permission.MODIFY_AUDIO_SETTINGS")
+        if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.MODIFY_AUDIO_SETTINGS)
                 == PackageManager.PERMISSION_GRANTED) {
             return true;
         }
@@ -3065,8 +3102,15 @@
             //  - one A2DP device + another device: happens with duplicated output. In this case
             // retain the device on the A2DP output as the other must not correspond to an active
             // selection if not the speaker.
+            //  - HDMI-CEC system audio mode only output: give priority to available item in order.
             if ((device & AudioSystem.DEVICE_OUT_SPEAKER) != 0) {
                 device = AudioSystem.DEVICE_OUT_SPEAKER;
+            } else if ((device & AudioSystem.DEVICE_OUT_HDMI_ARC) != 0) {
+                device = AudioSystem.DEVICE_OUT_HDMI_ARC;
+            } else if ((device & AudioSystem.DEVICE_OUT_SPDIF) != 0) {
+                device = AudioSystem.DEVICE_OUT_SPDIF;
+            } else if ((device & AudioSystem.DEVICE_OUT_AUX_LINE) != 0) {
+                device = AudioSystem.DEVICE_OUT_AUX_LINE;
             } else {
                 device &= AudioSystem.DEVICE_OUT_ALL_A2DP;
             }
@@ -3486,13 +3530,28 @@
         private void dump(PrintWriter pw) {
             pw.print("   Mute count: ");
             pw.println(muteCount());
+            pw.print("   Max: ");
+            pw.println((mIndexMax + 5) / 10);
             pw.print("   Current: ");
             Set set = mIndex.entrySet();
             Iterator i = set.iterator();
             while (i.hasNext()) {
                 Map.Entry entry = (Map.Entry)i.next();
-                pw.print(Integer.toHexString(((Integer)entry.getKey()).intValue())
-                             + ": " + ((((Integer)entry.getValue()).intValue() + 5) / 10)+", ");
+                final int device = (Integer) entry.getKey();
+                pw.print(Integer.toHexString(device));
+                final String deviceName = device == AudioSystem.DEVICE_OUT_DEFAULT ? "default"
+                        : AudioSystem.getOutputDeviceName(device);
+                if (!deviceName.isEmpty()) {
+                    pw.print(" (");
+                    pw.print(deviceName);
+                    pw.print(")");
+                }
+                pw.print(": ");
+                final int index = (((Integer) entry.getValue()) + 5) / 10;
+                pw.print(index);
+                if (i.hasNext()) {
+                    pw.print(", ");
+                }
             }
         }
     }
@@ -3819,7 +3878,6 @@
 
         @Override
         public void handleMessage(Message msg) {
-
             switch (msg.what) {
 
                 case MSG_SET_DEVICE_VOLUME:
@@ -3851,7 +3909,7 @@
                     Settings.System.putIntForUser(mContentResolver,
                                                  Settings.System.VOLUME_MASTER_MUTE,
                                                  msg.arg1,
-                                                 UserHandle.USER_CURRENT);
+                                                 msg.arg2);
                     break;
 
                 case MSG_PERSIST_RINGER_MODE:
@@ -4046,6 +4104,12 @@
                             Settings.Secure.UNSAFE_VOLUME_MUSIC_ACTIVE_MS, musicActiveMs,
                             UserHandle.USER_CURRENT);
                     break;
+                case MSG_PERSIST_MICROPHONE_MUTE:
+                    Settings.System.putIntForUser(mContentResolver,
+                                                 Settings.System.MICROPHONE_MUTE,
+                                                 msg.arg1,
+                                                 msg.arg2);
+                    break;
             }
         }
     }
@@ -4290,7 +4354,8 @@
         if ((state == 0) && ((device & mBecomingNoisyIntentDevices) != 0)) {
             int devices = 0;
             for (int dev : mConnectedDevices.keySet()) {
-                if ((dev & mBecomingNoisyIntentDevices) != 0) {
+                if (((dev & AudioSystem.DEVICE_BIT_IN) == 0) &&
+                        ((dev & mBecomingNoisyIntentDevices) != 0)) {
                    devices |= dev;
                 }
             }
@@ -4336,10 +4401,10 @@
             intent.putExtra("microphone", 0);
         } else if (device == AudioSystem.DEVICE_OUT_ANLG_DOCK_HEADSET) {
             connType = AudioRoutesInfo.MAIN_DOCK_SPEAKERS;
-            intent.setAction(Intent.ACTION_ANALOG_AUDIO_DOCK_PLUG);
+            intent.setAction(AudioManager.ACTION_ANALOG_AUDIO_DOCK_PLUG);
         } else if (device == AudioSystem.DEVICE_OUT_DGTL_DOCK_HEADSET) {
             connType = AudioRoutesInfo.MAIN_DOCK_SPEAKERS;
-            intent.setAction(Intent.ACTION_DIGITAL_AUDIO_DOCK_PLUG);
+            intent.setAction(AudioManager.ACTION_DIGITAL_AUDIO_DOCK_PLUG);
         } else if (device == AudioSystem.DEVICE_OUT_HDMI) {
             connType = AudioRoutesInfo.MAIN_HDMI;
             configureHdmiPlugIntent(intent, state);
@@ -4425,7 +4490,8 @@
     }
 
     private void configureHdmiPlugIntent(Intent intent, int state) {
-        intent.setAction(Intent.ACTION_HDMI_AUDIO_PLUG);
+        intent.setAction(AudioManager.ACTION_HDMI_AUDIO_PLUG);
+        intent.putExtra(AudioManager.EXTRA_AUDIO_PLUG_STATE, state);
         if (state == 1) {
             ArrayList<AudioPort> ports = new ArrayList<AudioPort>();
             int[] portGeneration = new int[1];
@@ -4449,7 +4515,7 @@
                                 for (int i = 0 ; i < encodingArray.length ; i++) {
                                     encodingArray[i] = encodingList.get(i);
                                 }
-                                intent.putExtra("encodings", encodingArray);
+                                intent.putExtra(AudioManager.EXTRA_ENCODINGS, encodingArray);
                             }
                             // find the maximum supported number of channels
                             int maxChannels = 0;
@@ -4459,7 +4525,7 @@
                                     maxChannels = channelCount;
                                 }
                             }
-                            intent.putExtra("maxChannelCount", maxChannels);
+                            intent.putExtra(AudioManager.EXTRA_MAX_CHANNEL_COUNT, maxChannels);
                         }
                     }
                 }
@@ -4553,7 +4619,7 @@
                         }
                     }
                 }
-            } else if (action.equals(Intent.ACTION_USB_AUDIO_ACCESSORY_PLUG)) {
+            } else if (action.equals(AudioManager.ACTION_USB_AUDIO_ACCESSORY_PLUG)) {
                 state = intent.getIntExtra("state", 0);
 
                 int alsaCard = intent.getIntExtra("card", -1);
@@ -4565,7 +4631,7 @@
                 // Playback Device
                 outDevice = AudioSystem.DEVICE_OUT_USB_ACCESSORY;
                 setWiredDeviceConnectionState(outDevice, state, params);
-            } else if (action.equals(Intent.ACTION_USB_AUDIO_DEVICE_PLUG)) {
+            } else if (action.equals(AudioManager.ACTION_USB_AUDIO_DEVICE_PLUG)) {
                 // FIXME Does not yet handle the case where the setting is changed
                 // after device connection.  Ideally we should handle the settings change
                 // in SettingsObserver. Here we should log that a USB device is connected
@@ -5056,6 +5122,52 @@
         return device;
     }
 
+    @Override
+    public boolean isHdmiSystemAudioSupported() {
+        return mHdmiSystemAudioSupported;
+    }
+
+    //==========================================================================================
+    // Accessibility: taking touch exploration into account for selecting the default
+    //   stream override timeout when adjusting volume
+    //==========================================================================================
+    private static class StreamOverride
+            implements AccessibilityManager.TouchExplorationStateChangeListener {
+
+        // AudioService.getActiveStreamType() will return:
+        // - STREAM_NOTIFICATION on tablets during this period after a notification stopped
+        // - STREAM_MUSIC on phones during this period after music or talkback/voice search prompt
+        // stopped
+        private static final int DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS = 5000;
+        private static final int TOUCH_EXPLORE_STREAM_TYPE_OVERRIDE_DELAY_MS = 1000;
+
+        static int sDelayMs;
+
+        static void init(Context ctxt) {
+            AccessibilityManager accessibilityManager =
+                    (AccessibilityManager) ctxt.getSystemService(Context.ACCESSIBILITY_SERVICE);
+            updateDefaultStreamOverrideDelay(
+                    accessibilityManager.isTouchExplorationEnabled());
+            accessibilityManager.addTouchExplorationStateChangeListener(
+                    new StreamOverride());
+        }
+
+        @Override
+        public void onTouchExplorationStateChanged(boolean enabled) {
+            updateDefaultStreamOverrideDelay(enabled);
+        }
+
+        private static void updateDefaultStreamOverrideDelay(boolean touchExploreEnabled) {
+            if (touchExploreEnabled) {
+                sDelayMs = TOUCH_EXPLORE_STREAM_TYPE_OVERRIDE_DELAY_MS;
+            } else {
+                sDelayMs = DEFAULT_STREAM_TYPE_OVERRIDE_DELAY_MS;
+            }
+            if (DEBUG_VOL) Log.d(TAG, "Touch exploration enabled=" + touchExploreEnabled
+                    + " stream override delay is now " + sDelayMs + " ms");
+        }
+    }
+
     //==========================================================================================
     // Camera shutter sound policy.
     // config_camera_sound_forced configuration option in config.xml defines if the camera shutter
@@ -5305,6 +5417,15 @@
      * LocalServices.
      */
     final class AudioServiceInternal extends AudioManagerInternal {
+
+        @Override
+        public void adjustSuggestedStreamVolumeForUid(int streamType, int direction, int flags,
+                String callingPackage, int uid) {
+            // direction and stream type swap here because the public
+            // adjustSuggested has a different order than the other methods.
+            adjustSuggestedStreamVolume(direction, streamType, flags, callingPackage, uid);
+        }
+
         @Override
         public void adjustStreamVolumeForUid(int streamType, int direction, int flags,
                 String callingPackage, int uid) {
diff --git a/media/java/android/media/AudioSystem.java b/media/java/android/media/AudioSystem.java
index e11aab1..9a76f94 100644
--- a/media/java/android/media/AudioSystem.java
+++ b/media/java/android/media/AudioSystem.java
@@ -371,6 +371,7 @@
     public static final String DEVICE_OUT_HDMI_ARC_NAME = "hmdi_arc";
     public static final String DEVICE_OUT_SPDIF_NAME = "spdif";
     public static final String DEVICE_OUT_FM_NAME = "fm_transmitter";
+    public static final String DEVICE_OUT_AUX_LINE_NAME = "aux_line";
 
     public static String getOutputDeviceName(int device)
     {
@@ -417,6 +418,8 @@
             return DEVICE_OUT_SPDIF_NAME;
         case DEVICE_OUT_FM:
             return DEVICE_OUT_FM_NAME;
+        case DEVICE_OUT_AUX_LINE:
+            return DEVICE_OUT_AUX_LINE_NAME;
         case DEVICE_OUT_DEFAULT:
         default:
             return "";
diff --git a/media/java/android/media/AudioTrack.java b/media/java/android/media/AudioTrack.java
index 52bcbbb..f37cbe5 100644
--- a/media/java/android/media/AudioTrack.java
+++ b/media/java/android/media/AudioTrack.java
@@ -92,7 +92,7 @@
     /** Minimum value for sample rate */
     private static final int SAMPLE_RATE_HZ_MIN = 4000;
     /** Maximum value for sample rate */
-    private static final int SAMPLE_RATE_HZ_MAX = 48000;
+    private static final int SAMPLE_RATE_HZ_MAX = 96000;
 
     /** Maximum value for AudioTrack channel count */
     private static final int CHANNEL_COUNT_MAX = 8;
@@ -1286,7 +1286,7 @@
 
     public int write(short[] audioData, int offsetInShorts, int sizeInShorts) {
 
-        if (mState == STATE_UNINITIALIZED || mAudioFormat != AudioFormat.ENCODING_PCM_16BIT) {
+        if (mState == STATE_UNINITIALIZED || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT) {
             return ERROR_INVALID_OPERATION;
         }
 
diff --git a/media/java/android/media/CamcorderProfile.java b/media/java/android/media/CamcorderProfile.java
index 8883d28..5651fc9 100644
--- a/media/java/android/media/CamcorderProfile.java
+++ b/media/java/android/media/CamcorderProfile.java
@@ -177,9 +177,15 @@
      */
     public static final int QUALITY_HIGH_SPEED_1080P = 2004;
 
+    /**
+     * High speed ( >= 100fps) quality level corresponding to the 2160p (3840 x 2160)
+     * resolution.
+     */
+    public static final int QUALITY_HIGH_SPEED_2160P = 2005;
+
     // Start and end of high speed quality list
     private static final int QUALITY_HIGH_SPEED_LIST_START = QUALITY_HIGH_SPEED_LOW;
-    private static final int QUALITY_HIGH_SPEED_LIST_END = QUALITY_HIGH_SPEED_1080P;
+    private static final int QUALITY_HIGH_SPEED_LIST_END = QUALITY_HIGH_SPEED_2160P;
 
     /**
      * Default recording duration in seconds before the session is terminated.
@@ -313,6 +319,7 @@
      * @see #QUALITY_HIGH_SPEED_480P
      * @see #QUALITY_HIGH_SPEED_720P
      * @see #QUALITY_HIGH_SPEED_1080P
+     * @see #QUALITY_HIGH_SPEED_2160P
     */
     public static CamcorderProfile get(int cameraId, int quality) {
         if (!((quality >= QUALITY_LIST_START &&
diff --git a/media/java/android/media/IAudioService.aidl b/media/java/android/media/IAudioService.aidl
index 6477055..75fc03c 100644
--- a/media/java/android/media/IAudioService.aidl
+++ b/media/java/android/media/IAudioService.aidl
@@ -201,6 +201,8 @@
 
     int setHdmiSystemAudioSupported(boolean on);
 
-           boolean registerAudioPolicy(in AudioPolicyConfig policyConfig, IBinder cb);
+    boolean isHdmiSystemAudioSupported();
+
+    boolean registerAudioPolicy(in AudioPolicyConfig policyConfig, IBinder cb);
     oneway void unregisterAudioPolicyAsync(in IBinder cb);
 }
diff --git a/media/java/android/media/Image.java b/media/java/android/media/Image.java
index 2856edb..522e45d 100644
--- a/media/java/android/media/Image.java
+++ b/media/java/android/media/Image.java
@@ -123,7 +123,7 @@
      */
     public abstract long getTimestamp();
 
-    protected Rect mCropRect;
+    private Rect mCropRect;
 
     /**
      * Get the crop rectangle associated with this frame.
diff --git a/media/java/android/media/MediaCodec.java b/media/java/android/media/MediaCodec.java
index 7bf9e98..2ef9289 100644
--- a/media/java/android/media/MediaCodec.java
+++ b/media/java/android/media/MediaCodec.java
@@ -94,9 +94,17 @@
  * and {@link #dequeueOutputBuffer} then transfer ownership from the codec
  * to the client.<p>
  * The client is not required to resubmit/release buffers immediately
- * to the codec, the sample code above simply does this for simplicity's sake.<p>
+ * to the codec, the sample code above simply does this for simplicity's sake.
+ * Nonetheless, it is possible that a codec may hold off on generating
+ * output buffers until all outstanding buffers have been
+ * released/resubmitted.
+ * <p>
  * Once the client has an input buffer available it can fill it with data
- * and submit it it to the codec via a call to {@link #queueInputBuffer}.<p>
+ * and submit it it to the codec via a call to {@link #queueInputBuffer}.
+ * Do not submit multiple input buffers with the same timestamp (unless
+ * it is codec-specific data marked as such using the flag
+ * {@link #BUFFER_FLAG_CODEC_CONFIG}).
+ * <p>
  * The codec in turn will return an output buffer to the client in response
  * to {@link #dequeueOutputBuffer}. After the output buffer has been processed
  * a call to {@link #releaseOutputBuffer} will return it to the codec.
@@ -128,18 +136,64 @@
  * {@link #queueInputBuffer}. The codec will continue to return output buffers
  * until it eventually signals the end of the output stream by specifying
  * the same flag ({@link #BUFFER_FLAG_END_OF_STREAM}) on the BufferInfo returned in
- * {@link #dequeueOutputBuffer}.
+ * {@link #dequeueOutputBuffer}.  Do not submit additional input buffers after
+ * signaling the end of the input stream, unless the codec has been flushed,
+ * or stopped and restarted.
  * <p>
+ * <h3>Seeking &amp; Adaptive Playback Support</h3>
+ *
+ * You can check if a decoder supports adaptive playback via {@link
+ * MediaCodecInfo.CodecCapabilities#isFeatureSupported}.  Adaptive playback
+ * is only supported if you configure the codec to decode onto a {@link
+ * android.view.Surface}.
+ *
+ * <h4>For decoders that do not support adaptive playback (including
+ * when not decoding onto a Surface)</h4>
+ *
  * In order to start decoding data that's not adjacent to previously submitted
- * data (i.e. after a seek) it is necessary to {@link #flush} the decoder.
+ * data (i.e. after a seek) <em>one must</em> {@link #flush} the decoder.
  * Any input or output buffers the client may own at the point of the flush are
  * immediately revoked, i.e. after a call to {@link #flush} the client does not
  * own any buffers anymore.
+ * <p>
+ * It is important that the input data after a flush starts at a suitable
+ * stream boundary.  The first frame must be able to be decoded completely on
+ * its own (for most codecs this means an I-frame), and that no frames should
+ * refer to frames before that first new frame.
  * Note that the format of the data submitted after a flush must not change,
  * flush does not support format discontinuities,
- * for this a full {@link #stop}, {@link #configure}, {@link #start}
+ * for this a full {@link #stop}, {@link #configure configure()}, {@link #start}
  * cycle is necessary.
  *
+ * <h4>For decoders that support adaptive playback</h4>
+ *
+ * In order to start decoding data that's not adjacent to previously submitted
+ * data (i.e. after a seek) it is <em>not necessary</em> to {@link #flush} the
+ * decoder.
+ * <p>
+ * It is still important that the input data after the discontinuity starts
+ * at a suitable stream boundary (e.g. I-frame), and that no new frames refer
+ * to frames before the first frame of the new input data segment.
+ * <p>
+ * For some video formats it is also possible to change the picture size
+ * mid-stream.  To do this for H.264, the new Sequence Parameter Set (SPS) and
+ * Picture Parameter Set (PPS) values must be packaged together with an
+ * Instantaneous Decoder Refresh (IDR) frame in a single buffer, which then
+ * can be enqueued as a regular input buffer.
+ * The client will receive an {@link #INFO_OUTPUT_FORMAT_CHANGED} return
+ * value from {@link #dequeueOutputBuffer dequeueOutputBuffer()} or
+ * {@link Callback#onOutputBufferAvailable onOutputBufferAvailable()}
+ * just after the picture-size change takes place and before any
+ * frames with the new size have been returned.
+ * <p>
+ * Be careful when calling {@link #flush} shortly after you have changed
+ * the picture size.  If you have not received confirmation of the picture
+ * size change, you will need to repeat the request for the new picture size.
+ * E.g. for H.264 you will need to prepend the PPS/SPS to the new IDR
+ * frame to ensure that the codec receives the picture size change request.
+ *
+ * <h3>States and error handling</h3>
+ *
  * <p> During its life, a codec conceptually exists in one of the following states:
  * Initialized, Configured, Executing, Error, Uninitialized, (omitting transitory states
  * between them). When created by one of the factory methods,
@@ -503,12 +557,15 @@
             int i = 0;
             for (Map.Entry<String, Object> entry: formatMap.entrySet()) {
                 if (entry.getKey().equals(MediaFormat.KEY_AUDIO_SESSION_ID)) {
-                    // TODO: Wire up as soon as AudioService is ready. Check entry.getValue() for
-                    // non-integral type.
-                    // long audioHwSync = audioService.getAudioHwSyncForSession(entry.getValue());
-                    long audioHwSync = 0;
+                    int sessionId = 0;
+                    try {
+                        sessionId = (Integer)entry.getValue();
+                    }
+                    catch (Exception e) {
+                        throw new IllegalArgumentException("Wrong Session ID Parameter!");
+                    }
                     keys[i] = "audio-hw-sync";
-                    values[i] = audioHwSync;
+                    values[i] = AudioSystem.getAudioHwSyncForSession(sessionId);
                 } else {
                     keys[i] = entry.getKey();
                     values[i] = entry.getValue();
@@ -611,10 +668,15 @@
      * Thrown when an internal codec error occurs.
      */
     public final static class CodecException extends IllegalStateException {
-        public CodecException(int errorCode, int actionCode, String detailMessage) {
+        CodecException(int errorCode, int actionCode, String detailMessage) {
             super(detailMessage);
             mErrorCode = errorCode;
             mActionCode = actionCode;
+
+            // TODO get this from codec
+            final String sign = errorCode < 0 ? "neg_" : "";
+            mDiagnosticInfo =
+                "android.media.MediaCodec.error_" + sign + Math.abs(errorCode);
         }
 
         /**
@@ -639,15 +701,28 @@
          * Retrieve the error code associated with a CodecException.
          * This is opaque diagnostic information and may depend on
          * hardware or API level.
+         *
+         * @hide
          */
         public int getErrorCode() {
             return mErrorCode;
         }
 
+        /**
+         * Retrieve a human readable diagnostic information string
+         * associated with the exception. DO NOT SHOW THIS TO END-USERS!
+         * This string will not be localized or generally comprehensible
+         * to end-users.
+         */
+        public String getDiagnosticInfo() {
+            return mDiagnosticInfo;
+        }
+
         /* Must be in sync with android_media_MediaCodec.cpp */
         private final static int ACTION_TRANSIENT = 1;
         private final static int ACTION_RECOVERABLE = 2;
 
+        private final String mDiagnosticInfo;
         private final int mErrorCode;
         private final int mActionCode;
     }
@@ -663,23 +738,33 @@
 
         /**
          * This indicates that no key has been set to perform the requested
-         * decrypt operation.
+         * decrypt operation.  The operation can be retried after adding
+         * a decryption key.
          */
         public static final int ERROR_NO_KEY = 1;
 
         /**
          * This indicates that the key used for decryption is no longer
-         * valid due to license term expiration.
+         * valid due to license term expiration.  The operation can be retried
+         * after updating the expired keys.
          */
         public static final int ERROR_KEY_EXPIRED = 2;
 
         /**
          * This indicates that a required crypto resource was not able to be
-         * allocated while attempting the requested operation.
+         * allocated while attempting the requested operation.  The operation
+         * can be retried if the app is able to release resources.
          */
         public static final int ERROR_RESOURCE_BUSY = 3;
 
         /**
+         * This indicates that the output protection levels supported by the
+         * device are not sufficient to meet the requirements set by the
+         * content owner in the license policy.
+         */
+        public static final int ERROR_INSUFFICIENT_OUTPUT_PROTECTION = 4;
+
+        /**
          * Retrieve the error code associated with a CryptoException
          */
         public int getErrorCode() {
@@ -1565,8 +1650,7 @@
      * @throws IllegalStateException if in the Uninitialized state.
      */
     public MediaCodecInfo getCodecInfo() {
-        return MediaCodecList.getCodecInfoAt(
-                   MediaCodecList.findCodecByName(getName()));
+        return MediaCodecList.getInfoFor(getName());
     }
 
     private native final ByteBuffer[] getBuffers(boolean input);
@@ -1675,7 +1759,7 @@
             if (cropRect != null) {
                 cropRect.offset(-xOffset, -yOffset);
             }
-            mCropRect = cropRect;
+            super.setCropRect(cropRect);
 
             // save offsets and info
             mXOffset = xOffset;
diff --git a/media/java/android/media/MediaCodecInfo.java b/media/java/android/media/MediaCodecInfo.java
index ae2d024..01f8193 100644
--- a/media/java/android/media/MediaCodecInfo.java
+++ b/media/java/android/media/MediaCodecInfo.java
@@ -70,7 +70,7 @@
         mIsEncoder = isEncoder;
         mCaps = new HashMap<String, CodecCapabilities>();
         for (CodecCapabilities c: caps) {
-            mCaps.put(c.getMime(), c);
+            mCaps.put(c.getMimeType(), c);
         }
     }
 
@@ -98,6 +98,43 @@
         return types;
     }
 
+    private static int checkPowerOfTwo(int value, String message) {
+        if ((value & (value - 1)) != 0) {
+            throw new IllegalArgumentException(message);
+        }
+        return value;
+    }
+
+    private static class Feature {
+        public String mName;
+        public int mValue;
+        public boolean mDefault;
+        public Feature(String name, int value, boolean def) {
+            mName = name;
+            mValue = value;
+            mDefault = def;
+        }
+    }
+
+    // COMMON CONSTANTS
+    private static final Range<Integer> POSITIVE_INTEGERS =
+        Range.create(1, Integer.MAX_VALUE);
+    private static final Range<Long> POSITIVE_LONGS =
+        Range.create(1l, Long.MAX_VALUE);
+    private static final Range<Rational> POSITIVE_RATIONALS =
+        Range.create(new Rational(1, Integer.MAX_VALUE),
+                     new Rational(Integer.MAX_VALUE, 1));
+    private static final Range<Integer> SIZE_RANGE = Range.create(1, 32768);
+    private static final Range<Integer> FRAME_RATE_RANGE = Range.create(0, 960);
+
+    // found stuff that is not supported by framework (=> this should not happen)
+    private static final int ERROR_UNRECOGNIZED   = (1 << 0);
+    // found profile/level for which we don't have capability estimates
+    private static final int ERROR_UNSUPPORTED    = (1 << 1);
+    // have not found any profile/level for which we don't have capability estimate
+    private static final int ERROR_NONE_SUPPORTED = (1 << 2);
+
+
     /**
      * Encapsulates the capabilities of a given codec component.
      * For example, what profile/level combinations it supports and what colorspaces
@@ -222,17 +259,6 @@
             return checkFeature(name, mFlagsRequired);
         }
 
-        private static class Feature {
-            public String mName;
-            public int mValue;
-            public boolean mDefault;
-            public Feature(String name, int value, boolean def) {
-                mName = name;
-                mValue = value;
-                mDefault = def;
-            }
-        }
-
         private static final Feature[] decoderFeatures = {
             new Feature(FEATURE_AdaptivePlayback, (1 << 0), true),
             new Feature(FEATURE_SecurePlayback,   (1 << 1), false),
@@ -295,6 +321,9 @@
             // check feature support
             for (Feature feat: getValidFeatures()) {
                 Integer yesNo = (Integer)map.get(MediaFormat.KEY_FEATURE_ + feat.mName);
+                if (yesNo == null) {
+                    continue;
+                }
                 if ((yesNo == 1 && !isFeatureSupported(feat.mName)) ||
                         (yesNo == 0 && isFeatureRequired(feat.mName))) {
                     return false;
@@ -312,1286 +341,54 @@
             return true;
         }
 
-        // errors while reading profile levels
-        private int mError;
-        // found stuff that is not supported by framework (=> this should not happen)
-        private static final int ERROR_UNRECOGNIZED   = (1 << 0);
-        // found profile/level for which we don't have capability estimates
-        private static final int ERROR_UNSUPPORTED    = (1 << 1);
-        // have not found any profile/level for which we don't have capability estimate
-        private static final int ERROR_NONE_SUPPORTED = (1 << 2);
-
-
-        // UTILITY METHODS
-        private static final Range<Integer> POSITIVE_INTEGERS =
-            Range.create(1, Integer.MAX_VALUE);
-        private static final Range<Long> POSITIVE_LONGS =
-            Range.create(1l, Long.MAX_VALUE);
-        private static final Range<Rational> POSITIVE_RATIONALS =
-            Range.create(new Rational(1, Integer.MAX_VALUE),
-                         new Rational(Integer.MAX_VALUE, 1));
-        private static final Range<Integer> SIZE_RANGE = Range.create(1, 32768);
-        private static final Range<Integer> FRAME_RATE_RANGE = Range.create(0, 960);
+        // errors while reading profile levels - accessed from sister capabilities
+        int mError;
 
         private static final String TAG = "CodecCapabilities";
 
         // NEW-STYLE CAPABILITIES
+        private AudioCapabilities mAudioCaps;
+        private VideoCapabilities mVideoCaps;
+        private EncoderCapabilities mEncoderCaps;
+        private MediaFormat mDefaultFormat;
 
         /**
          * Returns a MediaFormat object with default values for configurations that have
          * defaults.
          */
-        public final MediaFormat getDefaultFormat() {
+        public MediaFormat getDefaultFormat() {
             return mDefaultFormat;
         }
-        private MediaFormat mDefaultFormat;
 
         /**
          * Returns the mime type for which this codec-capability object was created.
          */
-        public final String getMime() {
+        public String getMimeType() {
             return mMime;
         }
 
-        /**
-         * Returns the encoding capabilities or {@code null} if this is not an encoder.
-         */
-        public final EncoderCapabilities getEncoderCapabilities() {
-            return mEncoderCaps;
+        private boolean isAudio() {
+            return mAudioCaps != null;
         }
-        private EncoderCapabilities mEncoderCaps;
+
+        /**
+         * Returns the audio capabilities or {@code null} if this is not an audio codec.
+         */
+        public AudioCapabilities getAudioCapabilities() {
+            return mAudioCaps;
+        }
 
         private boolean isEncoder() {
             return mEncoderCaps != null;
         }
 
         /**
-         * A class that supports querying the encoding capabilities of a codec.
+         * Returns the encoding capabilities or {@code null} if this is not an encoder.
          */
-        public static final class EncoderCapabilities {
-            /**
-             * Returns the supported range of quality values.
-             */
-            public final Range<Integer> getQualityRange() {
-                return mQualityRange;
-            }
-
-            /**
-             * Returns the supported range of encoder complexity values.
-             * <p>
-             * Some codecs may support multiple complexity levels, where higher
-             * complexity values use more encoder tools (e.g. perform more
-             * intensive calculations) to improve the quality or the compression
-             * ratio.  Use a lower value to save power and/or time.
-             */
-            public final Range<Integer> getComplexityRange() {
-                return mComplexityRange;
-            }
-
-            /** Constant quality mode */
-            public static final int BITRATE_MODE_CQ = 0;
-            /** Variable bitrate mode */
-            public static final int BITRATE_MODE_VBR = 1;
-            /** Constant bitrate mode */
-            public static final int BITRATE_MODE_CBR = 2;
-
-            private static final Feature[] bitrates = new Feature[] {
-                new Feature("VBR", BITRATE_MODE_VBR, true),
-                new Feature("CBR", BITRATE_MODE_CBR, false),
-                new Feature("CQ",  BITRATE_MODE_CQ,  false)
-            };
-
-            private static int parseBitrateMode(String mode) {
-                for (Feature feat: bitrates) {
-                    if (feat.mName.equalsIgnoreCase(mode)) {
-                        return feat.mValue;
-                    }
-                }
-                return 0;
-            }
-
-            /**
-             * Query whether a bitrate mode is supported.
-             */
-            public final boolean isBitrateModeSupported(int mode) {
-                for (Feature feat: bitrates) {
-                    if (mode == feat.mValue) {
-                        return (mBitControl & (1 << mode)) != 0;
-                    }
-                }
-                return false;
-            }
-
-            private Range<Integer> mQualityRange;
-            private Range<Integer> mComplexityRange;
-            private CodecCapabilities mParent;
-
-            /* no public constructor */
-            private EncoderCapabilities() { }
-
-            /** @hide */
-            public static EncoderCapabilities create(
-                    MediaFormat info, CodecCapabilities parent) {
-                EncoderCapabilities caps = new EncoderCapabilities();
-                caps.init(info, parent);
-                return caps;
-            }
-
-            /** @hide */
-            public void init(MediaFormat info, CodecCapabilities parent) {
-                // no support for complexity or quality yet
-                mParent = parent;
-                mComplexityRange = Range.create(0, 0);
-                mQualityRange = Range.create(0, 0);
-                mBitControl = (1 << BITRATE_MODE_VBR);
-
-                applyLevelLimits();
-                parseFromInfo(info);
-            }
-
-            private void applyLevelLimits() {
-                String mime = mParent.getMime();
-                if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_FLAC)) {
-                    mComplexityRange = Range.create(0, 8);
-                    mBitControl = (1 << BITRATE_MODE_CQ);
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_NB)
-                        || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_WB)
-                        || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_ALAW)
-                        || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_MLAW)
-                        || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MSGSM)) {
-                    mBitControl = (1 << BITRATE_MODE_CBR);
-                }
-            }
-
-            private int mBitControl;
-            private Integer mDefaultComplexity;
-            private Integer mDefaultQuality;
-            private String mQualityScale;
-
-            private void parseFromInfo(MediaFormat info) {
-                Map<String, Object> map = info.getMap();
-
-                if (info.containsKey("complexity-range")) {
-                    mComplexityRange = Utils
-                            .parseIntRange(info.getString("complexity-range"), mComplexityRange);
-                    // TODO should we limit this to level limits?
-                }
-                if (info.containsKey("quality-range")) {
-                    mQualityRange = Utils
-                            .parseIntRange(info.getString("quality-range"), mQualityRange);
-                }
-                if (info.containsKey("feature-bitrate-control")) {
-                    for (String mode: info.getString("feature-bitrate-control").split(",")) {
-                        mBitControl |= parseBitrateMode(mode);
-                    }
-                }
-
-                try {
-                    mDefaultComplexity = Integer.parseInt((String)map.get("complexity-default"));
-                } catch (NumberFormatException e) { }
-
-                try {
-                    mDefaultQuality = Integer.parseInt((String)map.get("quality-default"));
-                } catch (NumberFormatException e) { }
-
-                mQualityScale = (String)map.get("quality-scale");
-            }
-
-            private boolean supports(
-                    Integer complexity, Integer quality, Integer profile) {
-                boolean ok = true;
-                if (ok && complexity != null) {
-                    ok = mComplexityRange.contains(complexity);
-                }
-                if (ok && quality != null) {
-                    ok = mQualityRange.contains(quality);
-                }
-                if (ok && profile != null) {
-                    for (CodecProfileLevel pl: mParent.profileLevels) {
-                        if (pl.profile == profile) {
-                            profile = null;
-                            break;
-                        }
-                    }
-                    ok = profile == null;
-                }
-                return ok;
-            }
-
-            /** @hide */
-            public void setDefaultFormat(MediaFormat format) {
-                // don't list trivial quality/complexity as default for now
-                if (!mQualityRange.getUpper().equals(mQualityRange.getLower())
-                        && mDefaultQuality != null) {
-                    format.setInteger(MediaFormat.KEY_QUALITY, mDefaultQuality);
-                }
-                if (!mComplexityRange.getUpper().equals(mComplexityRange.getLower())
-                        && mDefaultComplexity != null) {
-                    format.setInteger(MediaFormat.KEY_COMPLEXITY, mDefaultComplexity);
-                }
-                // bitrates are listed in order of preference
-                for (Feature feat: bitrates) {
-                    if ((mBitControl & (1 << feat.mValue)) != 0) {
-                        format.setInteger(MediaFormat.KEY_BITRATE_MODE, feat.mValue);
-                        break;
-                    }
-                }
-            }
-
-            /** @hide */
-            public boolean supportsFormat(MediaFormat format) {
-                final Map<String, Object> map = format.getMap();
-                final String mime = mParent.getMime();
-
-                Integer mode = (Integer)map.get(MediaFormat.KEY_BITRATE_MODE);
-                if (mode != null && !isBitrateModeSupported(mode)) {
-                    return false;
-                }
-
-                Integer complexity = (Integer)map.get(MediaFormat.KEY_COMPLEXITY);
-                if (MediaFormat.MIMETYPE_AUDIO_FLAC.equalsIgnoreCase(mime)) {
-                    Integer flacComplexity =
-                        (Integer)map.get(MediaFormat.KEY_FLAC_COMPRESSION_LEVEL);
-                    if (complexity == null) {
-                        complexity = flacComplexity;
-                    } else if (flacComplexity != null && complexity != flacComplexity) {
-                        throw new IllegalArgumentException(
-                                "conflicting values for complexity and " +
-                                "flac-compression-level");
-                    }
-                }
-
-                // other audio parameters
-                Integer profile = (Integer)map.get(MediaFormat.KEY_PROFILE);
-                if (MediaFormat.MIMETYPE_AUDIO_AAC.equalsIgnoreCase(mime)) {
-                    Integer aacProfile = (Integer)map.get(MediaFormat.KEY_AAC_PROFILE);
-                    if (profile == null) {
-                        profile = aacProfile;
-                    } else if (aacProfile != null && aacProfile != profile) {
-                        throw new IllegalArgumentException(
-                                "conflicting values for profile and aac-profile");
-                    }
-                }
-
-                Integer quality = (Integer)map.get(MediaFormat.KEY_QUALITY);
-
-                return supports(complexity, quality, profile);
-            }
-        };
-
-        /**
-         * A class that supports querying basic capabilities of a codec.
-         */
-        public static class BaseCapabilities {
-            /**
-             * Returns the range of supported bitrates in bits/second.
-             */
-            public final Range<Integer> getBitrateRange() {
-                return mBitrateRange;
-            }
-
-            /** @hide */
-            protected Range<Integer> mBitrateRange;
-
-            /** @hide */
-            protected CodecCapabilities mParent;
-
-            /** @hide */
-            protected BaseCapabilities() {
-            }
-
-            /** @hide */
-            protected void init(MediaFormat info, CodecCapabilities parent) {
-                mParent = parent;
-                mBitrateRange = Range.create(0, Integer.MAX_VALUE);
-            }
+        public EncoderCapabilities getEncoderCapabilities() {
+            return mEncoderCaps;
         }
 
-        /**
-         * A class that supports querying the video capabilities of a codec.
-         */
-        public static final class VideoCapabilities extends BaseCapabilities {
-            private static final String TAG = "VideoCapabilities";
-            private Range<Integer> mHeightRange;
-            private Range<Integer> mWidthRange;
-            private Range<Integer> mBlockCountRange;
-            private Range<Integer> mHorizontalBlockRange;
-            private Range<Integer> mVerticalBlockRange;
-            private Range<Rational> mAspectRatioRange;
-            private Range<Rational> mBlockAspectRatioRange;
-            private Range<Long> mBlocksPerSecondRange;
-            private Range<Integer> mFrameRateRange;
-
-            private int mBlockWidth;
-            private int mBlockHeight;
-            private int mWidthAlignment;
-            private int mHeightAlignment;
-            private int mSmallerDimensionUpperLimit;
-
-            /**
-             * Returns the range of supported video widths.
-             */
-            public final Range<Integer> getSupportedWidths() {
-                return mWidthRange;
-            }
-
-            /**
-             * Returns the range of supported video heights.
-             */
-            public final Range<Integer> getSupportedHeights() {
-                return mHeightRange;
-            }
-
-            /**
-             * Returns the alignment requirement for video width.
-             */
-            public final int getWidthAlignment() {
-                return mWidthAlignment;
-            }
-
-            /**
-             * Returns the alignment requirement for video height.
-             */
-            public final int getHeightAlignment() {
-                return mHeightAlignment;
-            }
-
-            /**
-             * Return the upper limit on the smaller dimension of width or height.
-             * <p></p>
-             * Some codecs have a limit on the smaller dimension, whether it be
-             * the width or the height.  E.g. a codec may only be able to handle
-             * up to 1920x1080 both in landscape and portrait mode (1080x1920).
-             * In this case the maximum width and height are both 1920, but the
-             * smaller dimension limit will be 1080. For other codecs, this is
-             * {@code Math.min(getSupportedWidths().getUpper(),
-             * getSupportedHeights().getUpper())}.
-             *
-             * @hide
-             */
-            public int getSmallerDimensionUpperLimit() {
-                return mSmallerDimensionUpperLimit;
-            }
-
-            /**
-             * Returns the range of supported frame rates.
-             * <p>
-             * This is not a performance indicator.  Rather, it expresses the
-             * limits specified in the coding standard, based on the complexities
-             * of encoding material for later playback at a certain frame rate,
-             * or the decoding of such material in non-realtime.
-             */
-            public final Range<Integer> getSupportedFrameRates() {
-                return mFrameRateRange;
-            }
-
-            /**
-             * Returns the range of supported video widths for a video height.
-             * @param height the height of the video
-             */
-            public final Range<Integer> getSupportedWidthsFor(int height) {
-                try {
-                    Range<Integer> range = mWidthRange;
-                    if (!mHeightRange.contains(height)
-                            || (height % mHeightAlignment) != 0) {
-                        throw new IllegalArgumentException("unsupported height");
-                    }
-                    final int heightInBlocks = Utils.divUp(height, mBlockHeight);
-
-                    // constrain by block count and by block aspect ratio
-                    final int minWidthInBlocks = Math.max(
-                            Utils.divUp(mBlockCountRange.getLower(), heightInBlocks),
-                            (int)Math.ceil(mBlockAspectRatioRange.getLower().doubleValue()
-                                    * heightInBlocks));
-                    final int maxWidthInBlocks = Math.min(
-                            mBlockCountRange.getUpper() / heightInBlocks,
-                            (int)(mBlockAspectRatioRange.getUpper().doubleValue()
-                                    * heightInBlocks));
-                    range = range.intersect(
-                            (minWidthInBlocks - 1) * mBlockWidth + mWidthAlignment,
-                            maxWidthInBlocks * mBlockWidth);
-
-                    // constrain by smaller dimension limit
-                    if (height > mSmallerDimensionUpperLimit) {
-                        range = range.intersect(1, mSmallerDimensionUpperLimit);
-                    }
-
-                    // constrain by aspect ratio
-                    range = range.intersect(
-                            (int)Math.ceil(mAspectRatioRange.getLower().doubleValue()
-                                    * height),
-                            (int)(mAspectRatioRange.getUpper().doubleValue() * height));
-                    return range;
-                } catch (IllegalArgumentException e) {
-                    // should not be here
-                    Log.w(TAG, "could not get supported widths for " + height , e);
-                    throw new IllegalArgumentException("unsupported height");
-                }
-            }
-
-            /**
-             * Returns the range of supported video heights for a video width
-             * @param width the width of the video
-             */
-            public final Range<Integer> getSupportedHeightsFor(int width) {
-                try {
-                    Range<Integer> range = mHeightRange;
-                    if (!mWidthRange.contains(width)
-                            || (width % mWidthAlignment) != 0) {
-                        throw new IllegalArgumentException("unsupported width");
-                    }
-                    final int widthInBlocks = Utils.divUp(width, mBlockWidth);
-
-                    // constrain by block count and by block aspect ratio
-                    final int minHeightInBlocks = Math.max(
-                            Utils.divUp(mBlockCountRange.getLower(), widthInBlocks),
-                            (int)Math.ceil(widthInBlocks /
-                                    mBlockAspectRatioRange.getUpper().doubleValue()));
-                    final int maxHeightInBlocks = Math.min(
-                            mBlockCountRange.getUpper() / widthInBlocks,
-                            (int)(widthInBlocks /
-                                    mBlockAspectRatioRange.getLower().doubleValue()));
-                    range = range.intersect(
-                            (minHeightInBlocks - 1) * mBlockHeight + mHeightAlignment,
-                            maxHeightInBlocks * mBlockHeight);
-
-                    // constrain by smaller dimension limit
-                    if (width > mSmallerDimensionUpperLimit) {
-                        range = range.intersect(1, mSmallerDimensionUpperLimit);
-                    }
-
-                    // constrain by aspect ratio
-                    range = range.intersect(
-                            (int)Math.ceil(width /
-                                    mAspectRatioRange.getUpper().doubleValue()),
-                            (int)(width / mAspectRatioRange.getLower().doubleValue()));
-                    return range;
-                } catch (IllegalArgumentException e) {
-                    // should not be here
-                    Log.w(TAG, "could not get supported heights for " + width , e);
-                    throw new IllegalArgumentException("unsupported width");
-                }
-            }
-
-            /**
-             * Returns the range of supported video frame rates for a video size.
-             * <p>
-             * This is not a performance indicator.  Rather, it expresses the limits specified in
-             * the coding standard, based on the complexities of encoding material of a given
-             * size for later playback at a certain frame rate, or the decoding of such material
-             * in non-realtime.
-
-             * @param width the width of the video
-             * @param height the height of the video
-             */
-            public final Range<Double> getSupportedFrameRatesFor(int width, int height) {
-                Range<Integer> range = mHeightRange;
-                if (!supports(width, height, null)) {
-                    throw new IllegalArgumentException("unsupported size");
-                }
-                final int blockCount =
-                    Utils.divUp(width, mBlockWidth) * Utils.divUp(height, mBlockHeight);
-
-                return Range.create(
-                        Math.max(mBlocksPerSecondRange.getLower() / (double) blockCount,
-                                (double) mFrameRateRange.getLower()),
-                        Math.min(mBlocksPerSecondRange.getUpper() / (double) blockCount,
-                                (double) mFrameRateRange.getUpper()));
-            }
-
-            /**
-             * Returns whether a given video size ({@code width} and
-             * {@code height}) and {@code frameRate} combination is supported.
-             */
-            public final boolean areSizeAndRateSupported(
-                    int width, int height, double frameRate) {
-                return supports(width, height, frameRate);
-            }
-
-            /**
-             * Returns whether a given video size ({@code width} and
-             * {@code height}) is supported.
-             */
-            public final boolean isSizeSupported(int width, int height) {
-                return supports(width, height, null);
-            }
-
-            private final boolean supports(
-                    Integer width, Integer height, Double rate) {
-                boolean ok = true;
-
-                if (ok && width != null) {
-                    ok = mWidthRange.contains(width)
-                            && (width % mWidthAlignment == 0);
-                }
-                if (ok && height != null) {
-                    ok = mHeightRange.contains(height)
-                            && (height % mHeightAlignment == 0);
-                }
-                if (ok && rate != null) {
-                    ok = mFrameRateRange.contains(Utils.intRangeFor(rate));
-                }
-                if (ok && height != null && width != null) {
-                    ok = Math.min(height, width) <= mSmallerDimensionUpperLimit;
-
-                    final int widthInBlocks = Utils.divUp(width, mBlockWidth);
-                    final int heightInBlocks = Utils.divUp(height, mBlockHeight);
-                    final int blockCount = widthInBlocks * heightInBlocks;
-                    ok = ok && mBlockCountRange.contains(blockCount)
-                            && mBlockAspectRatioRange.contains(
-                                    new Rational(widthInBlocks, heightInBlocks))
-                            && mAspectRatioRange.contains(new Rational(width, height));
-                    if (ok && rate != null) {
-                        double blocksPerSec = blockCount * rate;
-                        ok = mBlocksPerSecondRange.contains(
-                                Utils.longRangeFor(blocksPerSec));
-                    }
-                }
-                return ok;
-            }
-
-            /**
-             * @hide
-             * @throws java.lang.ClassCastException */
-            public boolean supportsFormat(MediaFormat format) {
-                final Map<String, Object> map = format.getMap();
-                Integer width = (Integer)map.get(MediaFormat.KEY_WIDTH);
-                Integer height = (Integer)map.get(MediaFormat.KEY_HEIGHT);
-                Double rate = (Double)map.get(MediaFormat.KEY_FRAME_RATE);
-
-                // we ignore color-format for now as it is not reliably reported by codec
-
-                return supports(width, height, rate);
-            }
-
-            /* no public constructor */
-            private VideoCapabilities() { }
-
-            /** @hide */
-            public static VideoCapabilities create(
-                    MediaFormat info, CodecCapabilities parent) {
-                VideoCapabilities caps = new VideoCapabilities();
-                caps.init(info, parent);
-                return caps;
-            }
-
-            /** @hide */
-            public void init(MediaFormat info, CodecCapabilities parent) {
-                super.init(info, parent);
-                initWithPlatformLimits();
-                applyLevelLimits();
-                parseFromInfo(info);
-                updateLimits();
-            }
-
-            /** @hide */
-            public Size getBlockSize() {
-                return new Size(mBlockWidth, mBlockHeight);
-            }
-
-            /** @hide */
-            public Range<Integer> getBlockCountRange() {
-                return mBlockCountRange;
-            }
-
-            /** @hide */
-            public Range<Long> getBlocksPerSecondRange() {
-                return mBlocksPerSecondRange;
-            }
-
-            /** @hide */
-            public Range<Rational> getAspectRatioRange(boolean blocks) {
-                return blocks ? mBlockAspectRatioRange : mAspectRatioRange;
-            }
-
-            private void initWithPlatformLimits() {
-                mWidthRange  = SIZE_RANGE;
-                mHeightRange = SIZE_RANGE;
-                mFrameRateRange = FRAME_RATE_RANGE;
-
-                mHorizontalBlockRange = SIZE_RANGE;
-                mVerticalBlockRange   = SIZE_RANGE;
-
-                // full positive ranges are supported as these get calculated
-                mBlockCountRange      = POSITIVE_INTEGERS;
-                mBlocksPerSecondRange = POSITIVE_LONGS;
-
-                mBlockAspectRatioRange = POSITIVE_RATIONALS;
-                mAspectRatioRange      = POSITIVE_RATIONALS;
-
-                // YUV 4:2:0 requires 2:2 alignment
-                mWidthAlignment = 2;
-                mHeightAlignment = 2;
-                mBlockWidth = 2;
-                mBlockHeight = 2;
-                mSmallerDimensionUpperLimit = SIZE_RANGE.getUpper();
-            }
-
-            private void parseFromInfo(MediaFormat info) {
-                final Map<String, Object> map = info.getMap();
-                Size blockSize = new Size(mBlockWidth, mBlockHeight);
-                Size alignment = new Size(mWidthAlignment, mHeightAlignment);
-                Range<Integer> counts = null, widths = null, heights = null;
-                Range<Integer> frameRates = null;
-                Range<Long> blockRates = null;
-                Range<Rational> ratios = null, blockRatios = null;
-
-                blockSize = Utils.parseSize(map.get("block-size"), blockSize);
-                alignment = Utils.parseSize(map.get("alignment"), alignment);
-                counts = Utils.parseIntRange(map.get("block-count-range"), null);
-                blockRates =
-                    Utils.parseLongRange(map.get("blocks-per-second-range"), null);
-                {
-                    Object o = map.get("size-range");
-                    Pair<Size, Size> sizeRange = Utils.parseSizeRange(o);
-                    if (sizeRange != null) {
-                        try {
-                            widths = Range.create(
-                                    sizeRange.first.getWidth(),
-                                    sizeRange.second.getWidth());
-                            heights = Range.create(
-                                    sizeRange.first.getHeight(),
-                                    sizeRange.second.getHeight());
-                        } catch (IllegalArgumentException e) {
-                            Log.w(TAG, "could not parse size range '" + o + "'");
-                            widths = null;
-                            heights = null;
-                        }
-                    }
-                }
-                ratios = Utils.parseRationalRange(
-                        map.get("block-aspect-ratio-range"), null);
-                blockRatios = Utils.parseRationalRange(
-                        map.get("pixel-aspect-ratio-range"), null);
-                frameRates = Utils.parseIntRange(map.get("frame-rate-range"), null);
-                if (frameRates != null) {
-                    try {
-                        frameRates = frameRates.intersect(FRAME_RATE_RANGE);
-                    } catch (IllegalArgumentException e) {
-                        Log.w(TAG, "frame rate range (" + frameRates
-                                + ") is out of limits: " + FRAME_RATE_RANGE);
-                        frameRates = null;
-                    }
-                }
-
-                checkPowerOfTwo(
-                        blockSize.getWidth(), "block-size width must be power of two");
-                checkPowerOfTwo(
-                        blockSize.getHeight(), "block-size height must be power of two");
-
-                checkPowerOfTwo(
-                        alignment.getWidth(), "alignment width must be power of two");
-                checkPowerOfTwo(
-                        alignment.getHeight(), "alignment height must be power of two");
-
-                // update block-size and alignment
-                applyMacroBlockLimits(
-                        Integer.MAX_VALUE, Integer.MAX_VALUE, Integer.MAX_VALUE,
-                        Long.MAX_VALUE, blockSize.getWidth(), blockSize.getHeight(),
-                        alignment.getWidth(), alignment.getHeight());
-
-                if ((mParent.mError & ERROR_UNSUPPORTED) != 0) {
-                    // codec supports profiles that we don't know.
-                    // Use supplied values clipped to platform limits
-                    if (widths != null) {
-                        mWidthRange = SIZE_RANGE.intersect(widths);
-                    }
-                    if (heights != null) {
-                        mHeightRange = SIZE_RANGE.intersect(heights);
-                    }
-                    if (counts != null) {
-                        mBlockCountRange = POSITIVE_INTEGERS.intersect(
-                                Utils.factorRange(counts, mBlockWidth * mBlockHeight
-                                        / blockSize.getWidth() / blockSize.getHeight()));
-                    }
-                    if (blockRates != null) {
-                        mBlocksPerSecondRange = POSITIVE_LONGS.intersect(
-                                Utils.factorRange(blockRates, mBlockWidth * mBlockHeight
-                                        / blockSize.getWidth() / blockSize.getHeight()));
-                    }
-                    if (blockRatios != null) {
-                        mBlockAspectRatioRange = POSITIVE_RATIONALS.intersect(
-                                Utils.scaleRange(blockRatios,
-                                        mBlockHeight / blockSize.getHeight(),
-                                        mBlockWidth / blockSize.getWidth()));
-                    }
-                    if (ratios != null) {
-                        mAspectRatioRange = POSITIVE_RATIONALS.intersect(ratios);
-                    }
-                    if (frameRates != null) {
-                        mFrameRateRange = FRAME_RATE_RANGE.intersect(frameRates);
-                    }
-                } else {
-                    // no unsupported profile/levels, so restrict values to known limits
-                    if (widths != null) {
-                        mWidthRange = mWidthRange.intersect(widths);
-                    }
-                    if (heights != null) {
-                        mHeightRange = mHeightRange.intersect(heights);
-                    }
-                    if (counts != null) {
-                        mBlockCountRange = mBlockCountRange.intersect(
-                                Utils.factorRange(counts, mBlockWidth * mBlockHeight
-                                        / blockSize.getWidth() / blockSize.getHeight()));
-                    }
-                    if (blockRates != null) {
-                        mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(
-                                Utils.factorRange(blockRates, mBlockWidth * mBlockHeight
-                                        / blockSize.getWidth() / blockSize.getHeight()));
-                    }
-                    if (blockRatios != null) {
-                        mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(
-                                Utils.scaleRange(blockRatios,
-                                        mBlockHeight / blockSize.getHeight(),
-                                        mBlockWidth / blockSize.getWidth()));
-                    }
-                    if (ratios != null) {
-                        mAspectRatioRange = mAspectRatioRange.intersect(ratios);
-                    }
-                    if (frameRates != null) {
-                        mFrameRateRange = mFrameRateRange.intersect(frameRates);
-                    }
-                }
-                updateLimits();
-            }
-
-            private int checkPowerOfTwo(int value, String message) {
-                if ((value & (value - 1)) != 0) {
-                    throw new IllegalArgumentException(message);
-                }
-                return value;
-            }
-
-            private void applyBlockLimits(
-                    int blockWidth, int blockHeight,
-                    Range<Integer> counts, Range<Long> rates, Range<Rational> ratios) {
-                checkPowerOfTwo(blockWidth, "blockWidth must be a power of two");
-                checkPowerOfTwo(blockHeight, "blockHeight must be a power of two");
-
-                final int newBlockWidth = Math.max(blockWidth, mBlockWidth);
-                final int newBlockHeight = Math.max(blockHeight, mBlockHeight);
-
-                // factor will always be a power-of-2
-                int factor =
-                    newBlockWidth * newBlockHeight / mBlockWidth / mBlockHeight;
-                if (factor != 1) {
-                    mBlockCountRange = Utils.factorRange(mBlockCountRange, factor);
-                    mBlocksPerSecondRange = Utils.factorRange(
-                            mBlocksPerSecondRange, factor);
-                    mBlockAspectRatioRange = Utils.scaleRange(
-                            mBlockAspectRatioRange,
-                            newBlockHeight / mBlockHeight,
-                            newBlockWidth / mBlockWidth);
-                    mHorizontalBlockRange = Utils.factorRange(
-                            mHorizontalBlockRange, newBlockWidth / mBlockWidth);
-                    mVerticalBlockRange = Utils.factorRange(
-                            mVerticalBlockRange, newBlockHeight / mBlockHeight);
-                }
-                factor = newBlockWidth * newBlockHeight / blockWidth / blockHeight;
-                if (factor != 1) {
-                    counts = Utils.factorRange(counts, factor);
-                    rates = Utils.factorRange(rates, factor);
-                    ratios = Utils.scaleRange(
-                            ratios, newBlockHeight / blockHeight,
-                            newBlockWidth / blockWidth);
-                }
-                mBlockCountRange = mBlockCountRange.intersect(counts);
-                mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(rates);
-                mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(ratios);
-                mBlockWidth = newBlockWidth;
-                mBlockHeight = newBlockHeight;
-            }
-
-            private void applyAlignment(int widthAlignment, int heightAlignment) {
-                checkPowerOfTwo(widthAlignment, "widthAlignment must be a power of two");
-                checkPowerOfTwo(heightAlignment, "heightAlignment must be a power of two");
-
-                if (widthAlignment > mBlockWidth || heightAlignment > mBlockHeight) {
-                    // maintain assumption that 0 < alignment <= block-size
-                    applyBlockLimits(
-                            Math.max(widthAlignment, mBlockWidth),
-                            Math.max(heightAlignment, mBlockHeight),
-                            POSITIVE_INTEGERS, POSITIVE_LONGS, POSITIVE_RATIONALS);
-                }
-
-                mWidthAlignment = Math.max(widthAlignment, mWidthAlignment);
-                mHeightAlignment = Math.max(heightAlignment, mHeightAlignment);
-
-                mWidthRange = Utils.alignRange(mWidthRange, mWidthAlignment);
-                mHeightRange = Utils.alignRange(mHeightRange, mHeightAlignment);
-            }
-
-            private void updateLimits() {
-                // pixels -> blocks <- counts
-                mHorizontalBlockRange = mHorizontalBlockRange.intersect(
-                        Utils.factorRange(mWidthRange, mBlockWidth)).intersect(mBlockCountRange);
-                mVerticalBlockRange = mVerticalBlockRange.intersect(
-                        Utils.factorRange(mHeightRange, mBlockHeight)).intersect(mBlockCountRange);
-                mBlockCountRange = mBlockCountRange.intersect(
-                        Range.create(
-                                mHorizontalBlockRange.getLower()
-                                        * mVerticalBlockRange.getLower(),
-                                mHorizontalBlockRange.getUpper()
-                                        * mVerticalBlockRange.getUpper()));
-                mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(
-                        new Rational(
-                                mHorizontalBlockRange.getLower(), mVerticalBlockRange.getUpper()),
-                        new Rational(
-                                mHorizontalBlockRange.getUpper(), mVerticalBlockRange.getLower()));
-
-                // blocks -> pixels
-                mWidthRange = mWidthRange.intersect(
-                        (mHorizontalBlockRange.getLower() - 1) * mBlockWidth + mWidthAlignment,
-                        mHorizontalBlockRange.getUpper() * mBlockWidth);
-                mHeightRange = mHeightRange.intersect(
-                        (mVerticalBlockRange.getLower() - 1) * mBlockHeight + mHeightAlignment,
-                        mVerticalBlockRange.getUpper() * mBlockHeight);
-                mAspectRatioRange = mAspectRatioRange.intersect(
-                        new Rational(mWidthRange.getLower(), mHeightRange.getUpper()),
-                        new Rational(mWidthRange.getUpper(), mHeightRange.getLower()));
-
-                mSmallerDimensionUpperLimit = Math.min(
-                        mSmallerDimensionUpperLimit,
-                        Math.min(mWidthRange.getUpper(), mHeightRange.getUpper()));
-
-                // blocks -> rate
-                mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(
-                        mBlockCountRange.getLower() * (long)mFrameRateRange.getLower(),
-                        mBlockCountRange.getUpper() * (long)mFrameRateRange.getUpper());
-                mFrameRateRange = mFrameRateRange.intersect(
-                        (int)(mBlocksPerSecondRange.getLower()
-                                / mBlockCountRange.getUpper()),
-                        (int)(mBlocksPerSecondRange.getUpper()
-                                / (double)mBlockCountRange.getLower()));
-            }
-
-            private void applyMacroBlockLimits(
-                    int maxHorizontalBlocks, int maxVerticalBlocks,
-                    int maxBlocks, long maxBlocksPerSecond,
-                    int blockWidth, int blockHeight,
-                    int widthAlignment, int heightAlignment) {
-                applyAlignment(widthAlignment, heightAlignment);
-                applyBlockLimits(
-                        blockWidth, blockHeight, Range.create(1, maxBlocks),
-                        Range.create(1L, maxBlocksPerSecond),
-                        Range.create(
-                                new Rational(1, maxVerticalBlocks),
-                                new Rational(maxHorizontalBlocks, 1)));
-                mHorizontalBlockRange =
-                        mHorizontalBlockRange.intersect(
-                                1, maxHorizontalBlocks / (mBlockWidth / blockWidth));
-                mVerticalBlockRange =
-                        mVerticalBlockRange.intersect(
-                                1, maxVerticalBlocks / (mBlockHeight / blockHeight));
-            }
-
-            private void applyLevelLimits() {
-                int maxBlocksPerSecond = 0;
-                int maxBlocks = 0;
-                int maxBps = 0;
-                int maxDPBBlocks = 0;
-
-                int errors = ERROR_NONE_SUPPORTED;
-                CodecProfileLevel[] profileLevels = mParent.profileLevels;
-                String mime = mParent.getMime();
-
-                if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_AVC)) {
-                    maxBlocks = 99;
-                    maxBlocksPerSecond = 1485;
-                    maxBps = 64000;
-                    maxDPBBlocks = 396;
-                    for (CodecProfileLevel profileLevel: profileLevels) {
-                        int MBPS = 0, FS = 0, BR = 0, DPB = 0;
-                        boolean supported = true;
-                        switch (profileLevel.level) {
-                            case CodecProfileLevel.AVCLevel1:
-                                MBPS =    1485; FS =    99; BR =     64; DPB =    396; break;
-                            case CodecProfileLevel.AVCLevel1b:
-                                MBPS =    1485; FS =    99; BR =    128; DPB =    396; break;
-                            case CodecProfileLevel.AVCLevel11:
-                                MBPS =    3000; FS =   396; BR =    192; DPB =    900; break;
-                            case CodecProfileLevel.AVCLevel12:
-                                MBPS =    6000; FS =   396; BR =    384; DPB =   2376; break;
-                            case CodecProfileLevel.AVCLevel13:
-                                MBPS =   11880; FS =   396; BR =    768; DPB =   2376; break;
-                            case CodecProfileLevel.AVCLevel2:
-                                MBPS =   11880; FS =   396; BR =   2000; DPB =   2376; break;
-                            case CodecProfileLevel.AVCLevel21:
-                                MBPS =   19800; FS =   792; BR =   4000; DPB =   4752; break;
-                            case CodecProfileLevel.AVCLevel22:
-                                MBPS =   20250; FS =  1620; BR =   4000; DPB =   8100; break;
-                            case CodecProfileLevel.AVCLevel3:
-                                MBPS =   40500; FS =  1620; BR =  10000; DPB =   8100; break;
-                            case CodecProfileLevel.AVCLevel31:
-                                MBPS =  108000; FS =  3600; BR =  14000; DPB =  18000; break;
-                            case CodecProfileLevel.AVCLevel32:
-                                MBPS =  216000; FS =  5120; BR =  20000; DPB =  20480; break;
-                            case CodecProfileLevel.AVCLevel4:
-                                MBPS =  245760; FS =  8192; BR =  20000; DPB =  32768; break;
-                            case CodecProfileLevel.AVCLevel41:
-                                MBPS =  245760; FS =  8192; BR =  50000; DPB =  32768; break;
-                            case CodecProfileLevel.AVCLevel42:
-                                MBPS =  522240; FS =  8704; BR =  50000; DPB =  34816; break;
-                            case CodecProfileLevel.AVCLevel5:
-                                MBPS =  589824; FS = 22080; BR = 135000; DPB = 110400; break;
-                            case CodecProfileLevel.AVCLevel51:
-                                MBPS =  983040; FS = 36864; BR = 240000; DPB = 184320; break;
-                            case CodecProfileLevel.AVCLevel52:
-                                MBPS = 2073600; FS = 36864; BR = 240000; DPB = 184320; break;
-                            default:
-                                Log.w(TAG, "Unrecognized level "
-                                        + profileLevel.level + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        switch (profileLevel.profile) {
-                            case CodecProfileLevel.AVCProfileHigh:
-                                BR *= 1250; break;
-                            case CodecProfileLevel.AVCProfileHigh10:
-                                BR *= 3000; break;
-                            case CodecProfileLevel.AVCProfileExtended:
-                            case CodecProfileLevel.AVCProfileHigh422:
-                            case CodecProfileLevel.AVCProfileHigh444:
-                                Log.w(TAG, "Unsupported profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNSUPPORTED;
-                                supported = false;
-                                // fall through - treat as base profile
-                            case CodecProfileLevel.AVCProfileBaseline:
-                            case CodecProfileLevel.AVCProfileMain:
-                                BR *= 1000; break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                                BR *= 1000;
-                        }
-                        if (supported) {
-                            errors &= ~ERROR_NONE_SUPPORTED;
-                        }
-                        maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
-                        maxBlocks = Math.max(FS, maxBlocks);
-                        maxBps = Math.max(BR, maxBps);
-                        maxDPBBlocks = Math.max(maxDPBBlocks, DPB);
-                    }
-
-                    int maxLengthInBlocks = (int)(Math.sqrt(maxBlocks * 8));
-                    applyMacroBlockLimits(
-                            maxLengthInBlocks, maxLengthInBlocks,
-                            maxBlocks, maxBlocksPerSecond,
-                            16 /* blockWidth */, 16 /* blockHeight */,
-                            1 /* widthAlignment */, 1 /* heightAlignment */);
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_MPEG4)) {
-                    int maxWidth = 11, maxHeight = 9, maxRate = 15;
-                    maxBlocks = 99;
-                    maxBlocksPerSecond = 1485;
-                    maxBps = 64000;
-                    for (CodecProfileLevel profileLevel: profileLevels) {
-                        int MBPS = 0, FS = 0, BR = 0, FR = 0, W = 0, H = 0;
-                        boolean supported = true;
-                        switch (profileLevel.profile) {
-                            case CodecProfileLevel.MPEG4ProfileSimple:
-                                switch (profileLevel.level) {
-                                    case CodecProfileLevel.MPEG4Level0:
-                                        FR = 15; W = 11; H =  9; MBPS =  1485; FS =  99; BR =  64; break;
-                                    case CodecProfileLevel.MPEG4Level1:
-                                        FR = 30; W = 11; H =  9; MBPS =  1485; FS =  99; BR =  64; break;
-                                    case CodecProfileLevel.MPEG4Level0b:
-                                        FR = 30; W = 11; H =  9; MBPS =  1485; FS =  99; BR = 128; break;
-                                    case CodecProfileLevel.MPEG4Level2:
-                                        FR = 30; W = 22; H = 18; MBPS =  5940; FS = 396; BR = 128; break;
-                                    case CodecProfileLevel.MPEG4Level3:
-                                        FR = 30; W = 22; H = 18; MBPS = 11880; FS = 396; BR = 384; break;
-                                    case CodecProfileLevel.MPEG4Level4:
-                                    case CodecProfileLevel.MPEG4Level4a:
-                                    case CodecProfileLevel.MPEG4Level5:
-                                        // While MPEG4 SP does not have level 4 or 5, some vendors
-                                        // report it. Use the same limits as level 3, but mark as
-                                        // unsupported.
-                                        FR = 30; W = 22; H = 18; MBPS = 11880; FS = 396; BR = 384;
-                                        supported = false;
-                                        break;
-                                    default:
-                                        Log.w(TAG, "Unrecognized profile/level "
-                                                + profileLevel.profile + "/"
-                                                + profileLevel.level + " for " + mime);
-                                        errors |= ERROR_UNRECOGNIZED;
-                                }
-                                break;
-                            case CodecProfileLevel.MPEG4ProfileAdvancedSimple:
-                                switch (profileLevel.level) {
-                                    case CodecProfileLevel.MPEG4Level0:
-                                    case CodecProfileLevel.MPEG4Level1:
-                                        FR = 30; W = 11; H =  9; MBPS =  2970; FS =   99; BR =  128; break;
-                                    case CodecProfileLevel.MPEG4Level2:
-                                        FR = 30; W = 22; H = 18; MBPS =  5940; FS =  396; BR =  384; break;
-                                    case CodecProfileLevel.MPEG4Level3:
-                                        FR = 30; W = 22; H = 18; MBPS = 11880; FS =  396; BR =  768; break;
-                                    // case CodecProfileLevel.MPEG4Level3b:
-                                    // TODO: MPEG4 level 3b is not defined in OMX
-                                    //  MBPS = 11880; FS =  396; BR = 1500; break;
-                                    case CodecProfileLevel.MPEG4Level4:
-                                    case CodecProfileLevel.MPEG4Level4a:
-                                        // TODO: MPEG4 level 4a is not defined in spec
-                                        FR = 30; W = 44; H = 36; MBPS = 23760; FS =  792; BR = 3000; break;
-                                    case CodecProfileLevel.MPEG4Level5:
-                                        FR = 30; W = 45; H = 36; MBPS = 48600; FS = 1620; BR = 8000; break;
-                                    default:
-                                        Log.w(TAG, "Unrecognized profile/level "
-                                                + profileLevel.profile + "/"
-                                                + profileLevel.level + " for " + mime);
-                                        errors |= ERROR_UNRECOGNIZED;
-                                }
-                                break;
-                            case CodecProfileLevel.MPEG4ProfileMain:             // 2-4
-                            case CodecProfileLevel.MPEG4ProfileNbit:             // 2
-                            case CodecProfileLevel.MPEG4ProfileAdvancedRealTime: // 1-4
-                            case CodecProfileLevel.MPEG4ProfileCoreScalable:     // 1-3
-                            case CodecProfileLevel.MPEG4ProfileAdvancedCoding:   // 1-4
-                            case CodecProfileLevel.MPEG4ProfileCore:             // 1-2
-                            case CodecProfileLevel.MPEG4ProfileAdvancedCore:     // 1-4
-                            case CodecProfileLevel.MPEG4ProfileSimpleScalable:   // 0-2
-                            case CodecProfileLevel.MPEG4ProfileAdvancedScalable: // 1-3
-                            case CodecProfileLevel.MPEG4ProfileHybrid:           // 1-2
-                            case CodecProfileLevel.MPEG4ProfileBasicAnimated:    // 1-2
-                            case CodecProfileLevel.MPEG4ProfileScalableTexture:  // 1
-                            case CodecProfileLevel.MPEG4ProfileSimpleFace:       // 1-2
-                            case CodecProfileLevel.MPEG4ProfileSimpleFBA:        // 1-2
-                                Log.i(TAG, "Unsupported profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNSUPPORTED;
-                                supported = false;
-                                break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        if (supported) {
-                            errors &= ~ERROR_NONE_SUPPORTED;
-                        }
-                        maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
-                        maxBlocks = Math.max(FS, maxBlocks);
-                        maxBps = Math.max(BR * 1000, maxBps);
-                        maxWidth = Math.max(W, maxWidth);
-                        maxHeight = Math.max(H, maxHeight);
-                        maxRate = Math.max(FR, maxRate);
-                    }
-                    applyMacroBlockLimits(maxWidth, maxHeight,
-                            maxBlocks, maxBlocksPerSecond,
-                            16 /* blockWidth */, 16 /* blockHeight */,
-                            1 /* widthAlignment */, 1 /* heightAlignment */);
-                    mFrameRateRange = mFrameRateRange.intersect(12, maxRate);
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_H263)) {
-                    int maxWidth = 11, maxHeight = 9, maxRate = 15;
-                    maxBlocks = 99;
-                    maxBlocksPerSecond = 1485;
-                    maxBps = 64000;
-                    for (CodecProfileLevel profileLevel: profileLevels) {
-                        int MBPS = 0, BR = 0, FR = 0, W = 0, H = 0;
-                        switch (profileLevel.level) {
-                            case CodecProfileLevel.H263Level10:
-                                FR = 15; W = 11; H =  9; BR =   1; MBPS =  W * H * FR; break;
-                            case CodecProfileLevel.H263Level20:
-                                // only supports CIF, 0..QCIF
-                                FR = 30; W = 22; H = 18; BR =   2; MBPS =  W * H * FR; break;
-                            case CodecProfileLevel.H263Level30:
-                                // only supports CIF, 0..QCIF
-                                FR = 30; W = 22; H = 18; BR =   6; MBPS =  W * H * FR; break;
-                            case CodecProfileLevel.H263Level40:
-                                // only supports CIF, 0..QCIF
-                                FR = 30; W = 22; H = 18; BR =  32; MBPS =  W * H * FR; break;
-                            case CodecProfileLevel.H263Level45:
-                                // only implies level 10 support
-                                FR = 30; W = 11; H =  9; BR =   2; MBPS =  W * H * FR; break;
-                            case CodecProfileLevel.H263Level50:
-                                // only supports 50fps for H > 15
-                                FR = 60; W = 22; H = 18; BR =  64; MBPS =  W * H * 50; break;
-                            case CodecProfileLevel.H263Level60:
-                                // only supports 50fps for H > 15
-                                FR = 60; W = 45; H = 18; BR = 128; MBPS =  W * H * 50; break;
-                            case CodecProfileLevel.H263Level70:
-                                // only supports 50fps for H > 30
-                                FR = 60; W = 45; H = 36; BR = 256; MBPS =  W * H * 50; break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile/level " + profileLevel.profile
-                                        + "/" + profileLevel.level + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        switch (profileLevel.profile) {
-                            case CodecProfileLevel.H263ProfileBackwardCompatible:
-                            case CodecProfileLevel.H263ProfileBaseline:
-                            case CodecProfileLevel.H263ProfileH320Coding:
-                            case CodecProfileLevel.H263ProfileHighCompression:
-                            case CodecProfileLevel.H263ProfileHighLatency:
-                            case CodecProfileLevel.H263ProfileInterlace:
-                            case CodecProfileLevel.H263ProfileInternet:
-                            case CodecProfileLevel.H263ProfileISWV2:
-                            case CodecProfileLevel.H263ProfileISWV3:
-                                break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        errors &= ~ERROR_NONE_SUPPORTED;
-                        maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
-                        maxBlocks = Math.max(W * H, maxBlocks);
-                        maxBps = Math.max(BR * 64000, maxBps);
-                        maxWidth = Math.max(W, maxWidth);
-                        maxHeight = Math.max(H, maxHeight);
-                        maxRate = Math.max(FR, maxRate);
-                    }
-                    applyMacroBlockLimits(maxWidth, maxHeight,
-                            maxBlocks, maxBlocksPerSecond,
-                            16 /* blockWidth */, 16 /* blockHeight */,
-                            1 /* widthAlignment */, 1 /* heightAlignment */);
-                    mFrameRateRange = Range.create(1, maxRate);
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP8) ||
-                        mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP9)) {
-                    maxBlocks = maxBlocksPerSecond = Integer.MAX_VALUE;
-
-                    // TODO: set to 100Mbps for now, need a number for VPX
-                    maxBps = 100000000;
-
-                    // profile levels are not indicative for VPx, but verify
-                    // them nonetheless
-                    for (CodecProfileLevel profileLevel: profileLevels) {
-                        switch (profileLevel.level) {
-                            case CodecProfileLevel.VP8Level_Version0:
-                            case CodecProfileLevel.VP8Level_Version1:
-                            case CodecProfileLevel.VP8Level_Version2:
-                            case CodecProfileLevel.VP8Level_Version3:
-                                break;
-                            default:
-                                Log.w(TAG, "Unrecognized level "
-                                        + profileLevel.level + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        switch (profileLevel.profile) {
-                            case CodecProfileLevel.VP8ProfileMain:
-                                break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        errors &= ~ERROR_NONE_SUPPORTED;
-                    }
-
-                    final int blockSize =
-                        mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP8) ? 16 : 8;
-                    applyMacroBlockLimits(Short.MAX_VALUE, Short.MAX_VALUE,
-                            maxBlocks, maxBlocksPerSecond, blockSize, blockSize,
-                            1 /* widthAlignment */, 1 /* heightAlignment */);
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_HEVC)) {
-                    maxBlocks = 36864;
-                    maxBlocksPerSecond = maxBlocks * 15;
-                    maxBps = 128000;
-                    for (CodecProfileLevel profileLevel: profileLevels) {
-                        double FR = 0;
-                        int FS = 0;
-                        int BR = 0;
-                        switch (profileLevel.level) {
-                            case CodecProfileLevel.HEVCMainTierLevel1:
-                            case CodecProfileLevel.HEVCHighTierLevel1:
-                                FR =    15; FS =    36864; BR =    128; break;
-                            case CodecProfileLevel.HEVCMainTierLevel2:
-                            case CodecProfileLevel.HEVCHighTierLevel2:
-                                FR =    30; FS =   122880; BR =   1500; break;
-                            case CodecProfileLevel.HEVCMainTierLevel21:
-                            case CodecProfileLevel.HEVCHighTierLevel21:
-                                FR =    30; FS =   245760; BR =   3000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel3:
-                            case CodecProfileLevel.HEVCHighTierLevel3:
-                                FR =    30; FS =   552960; BR =   6000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel31:
-                            case CodecProfileLevel.HEVCHighTierLevel31:
-                                FR = 33.75; FS =   983040; BR =  10000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel4:
-                                FR =    30; FS =  2228224; BR =  12000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel4:
-                                FR =    30; FS =  2228224; BR =  30000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel41:
-                                FR =    60; FS =  2228224; BR =  20000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel41:
-                                FR =    60; FS =  2228224; BR =  50000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel5:
-                                FR =    30; FS =  8912896; BR =  25000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel5:
-                                FR =    30; FS =  8912896; BR = 100000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel51:
-                                FR =    60; FS =  8912896; BR =  40000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel51:
-                                FR =    60; FS =  8912896; BR = 160000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel52:
-                                FR =   120; FS =  8912896; BR =  60000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel52:
-                                FR =   120; FS =  8912896; BR = 240000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel6:
-                                FR =    30; FS = 35651584; BR =  60000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel6:
-                                FR =    30; FS = 35651584; BR = 240000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel61:
-                                FR =    60; FS = 35651584; BR = 120000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel61:
-                                FR =    60; FS = 35651584; BR = 480000; break;
-                            case CodecProfileLevel.HEVCMainTierLevel62:
-                                FR =   120; FS = 35651584; BR = 240000; break;
-                            case CodecProfileLevel.HEVCHighTierLevel62:
-                                FR =   120; FS = 35651584; BR = 800000; break;
-                            default:
-                                Log.w(TAG, "Unrecognized level "
-                                        + profileLevel.level + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-                        switch (profileLevel.profile) {
-                            case CodecProfileLevel.HEVCProfileMain:
-                            case CodecProfileLevel.HEVCProfileMain10:
-                                break;
-                            default:
-                                Log.w(TAG, "Unrecognized profile "
-                                        + profileLevel.profile + " for " + mime);
-                                errors |= ERROR_UNRECOGNIZED;
-                        }
-
-                        /* DPB logic:
-                        if      (width * height <= FS / 4)    DPB = 16;
-                        else if (width * height <= FS / 2)    DPB = 12;
-                        else if (width * height <= FS * 0.75) DPB = 8;
-                        else                                  DPB = 6;
-                        */
-
-                        errors &= ~ERROR_NONE_SUPPORTED;
-                        maxBlocksPerSecond = Math.max((int)(FR * FS), maxBlocksPerSecond);
-                        maxBlocks = Math.max(FS, maxBlocks);
-                        maxBps = Math.max(BR * 1000, maxBps);
-                    }
-
-                    int maxLengthInBlocks = (int)(Math.sqrt(maxBlocks * 8));
-                    // CTBs are at least 8x8
-                    maxBlocks = Utils.divUp(maxBlocks, 8 * 8);
-                    maxBlocksPerSecond = Utils.divUp(maxBlocksPerSecond, 8 * 8);
-                    maxLengthInBlocks = Utils.divUp(maxLengthInBlocks, 8);
-
-                    applyMacroBlockLimits(
-                            maxLengthInBlocks, maxLengthInBlocks,
-                            maxBlocks, maxBlocksPerSecond,
-                            8 /* blockWidth */, 8 /* blockHeight */,
-                            1 /* widthAlignment */, 1 /* heightAlignment */);
-                } else {
-                    Log.w(TAG, "Unsupported mime " + mime);
-                    // using minimal bitrate here.  should be overriden by
-                    // info from media_codecs.xml
-                    maxBps = 64000;
-                    errors |= ERROR_UNSUPPORTED;
-                }
-                mBitrateRange = Range.create(1, maxBps);
-                mParent.mError |= errors;
-            }
-        };
-
-        VideoCapabilities mVideoCaps;
-
         private boolean isVideo() {
             return mVideoCaps != null;
         }
@@ -1599,16 +396,28 @@
         /**
          * Returns the video capabilities or {@code null} if this is not a video codec.
          */
-        public final VideoCapabilities getVideoCapabilities() {
+        public VideoCapabilities getVideoCapabilities() {
             return mVideoCaps;
         }
 
+        /** @hide */
+        public CodecCapabilities dup() {
+            return new CodecCapabilities(
+                // clone writable arrays
+                Arrays.copyOf(profileLevels, profileLevels.length),
+                Arrays.copyOf(colorFormats, colorFormats.length),
+                isEncoder(),
+                mFlagsVerified,
+                mDefaultFormat,
+                mCapabilitiesInfo);
+        }
+
         /**
          * Retrieve the codec capabilities for a certain {@code mime type}, {@code
          * profile} and {@code level}.  If the type, or profile-level combination
          * is not understood by the framework, it returns null.
          */
-        public static final CodecCapabilities CreateFromProfileLevel(
+        public static CodecCapabilities createFromProfileLevel(
                 String mime, int profile, int level) {
             CodecProfileLevel pl = new CodecProfileLevel();
             pl.profile = profile;
@@ -1664,292 +473,1512 @@
                 Integer yesNo = (Integer)map.get(key);
                 if (yesNo == null) {
                     continue;
-                } else if (yesNo > 0) {
-                    mFlagsRequired |= feat.mValue;
-                    mDefaultFormat.setInteger(key, 1);
-                } else {
-                    mFlagsSupported |= feat.mValue;
-                    mDefaultFormat.setInteger(key, 1);
                 }
+                if (yesNo > 0) {
+                    mFlagsRequired |= feat.mValue;
+                }
+                mFlagsSupported |= feat.mValue;
+                mDefaultFormat.setInteger(key, 1);
                 // TODO restrict features by mFlagsVerified once all codecs reliably verify them
             }
         }
+    }
+
+    /**
+     * A class that supports querying the audio capabilities of a codec.
+     */
+    public static final class AudioCapabilities {
+        private static final String TAG = "AudioCapabilities";
+        private CodecCapabilities mParent;
+        private Range<Integer> mBitrateRange;
+
+        private int[] mSampleRates;
+        private Range<Integer>[] mSampleRateRanges;
+        private int mMaxInputChannelCount;
+
+        private static final int MAX_INPUT_CHANNEL_COUNT = 30;
 
         /**
-         * A class that supports querying the audio capabilities of a codec.
+         * Returns the range of supported bitrates in bits/second.
          */
-        public static final class AudioCapabilities extends BaseCapabilities {
-            private static final String TAG = "AudioCapabilities";
-
-            private int[] mSampleRates;
-            private Range<Integer>[] mSampleRateRanges;
-            private int mMaxInputChannelCount;
-
-            private static final int MAX_INPUT_CHANNEL_COUNT = 30;
-
-            /**
-             * Returns the array of supported sample rates if the codec
-             * supports only discrete values.  Otherwise, it returns
-             * {@code null}.  The array is sorted in ascending order.
-             */
-            public final int[] getSupportedSampleRates() {
-                return Arrays.copyOf(mSampleRates, mSampleRates.length);
-            }
-
-            /**
-             * Returns the array of supported sample rate ranges.  The
-             * array is sorted in ascending order, and the ranges are
-             * distinct.
-             */
-            public final Range<Integer>[] getSupportedSampleRateRanges() {
-                return Arrays.copyOf(mSampleRateRanges, mSampleRateRanges.length);
-            }
-
-            /**
-             * Returns the maximum number of input channels supported.  The codec
-             * supports any number of channels between 1 and this maximum value.
-             */
-            public final int getMaxInputChannelCount() {
-                return mMaxInputChannelCount;
-            }
-
-            /* no public constructor */
-            private AudioCapabilities() { }
-
-            /** @hide */
-            public static AudioCapabilities create(
-                    MediaFormat info, CodecCapabilities parent) {
-                AudioCapabilities caps = new AudioCapabilities();
-                caps.init(info, parent);
-                return caps;
-            }
-
-            /** @hide */
-            public void init(MediaFormat info, CodecCapabilities parent) {
-                super.init(info, parent);
-                initWithPlatformLimits();
-                applyLevelLimits();
-                parseFromInfo(info);
-            }
-
-            private void initWithPlatformLimits() {
-                mMaxInputChannelCount = MAX_INPUT_CHANNEL_COUNT;
-                // mBitrateRange = Range.create(1, 320000);
-                mSampleRateRanges = new Range[] { Range.create(8000, 96000) };
-                mSampleRates = null;
-            }
-
-            private boolean supports(Integer sampleRate, Integer inputChannels) {
-                // channels and sample rates are checked orthogonally
-                if (inputChannels != null &&
-                        (inputChannels < 1 || inputChannels > mMaxInputChannelCount)) {
-                    return false;
-                }
-                if (sampleRate != null) {
-                    int ix = Utils.binarySearchDistinctRanges(
-                            mSampleRateRanges, sampleRate);
-                    if (ix < 0) {
-                        return false;
-                    }
-                }
-                return true;
-            }
-
-            /**
-             * Query whether the sample rate is supported by the codec.
-             */
-            public final boolean isSampleRateSupported(int sampleRate) {
-                return supports(sampleRate, null);
-            }
-
-            /** modifies rates */
-            private void limitSampleRates(int[] rates) {
-                Arrays.sort(rates);
-                ArrayList<Range<Integer>> ranges = new ArrayList<Range<Integer>>();
-                for (int rate: rates) {
-                    if (supports(rate, null /* channels */)) {
-                        ranges.add(Range.create(rate, rate));
-                    }
-                }
-                mSampleRateRanges = ranges.toArray(new Range[ranges.size()]);
-                createDiscreteSampleRates();
-            }
-
-            private void createDiscreteSampleRates() {
-                mSampleRates = new int[mSampleRateRanges.length];
-                for (int i = 0; i < mSampleRateRanges.length; i++) {
-                    mSampleRates[i] = mSampleRateRanges[i].getLower();
-                }
-            }
-
-            /** modifies rateRanges */
-            private void limitSampleRates(Range<Integer>[] rateRanges) {
-                sortDistinctRanges(rateRanges);
-                mSampleRateRanges = intersectSortedDistinctRanges(mSampleRateRanges, rateRanges);
-
-                // check if all values are discrete
-                for (Range<Integer> range: mSampleRateRanges) {
-                    if (!range.getLower().equals(range.getUpper())) {
-                        mSampleRates = null;
-                        return;
-                    }
-                }
-                createDiscreteSampleRates();
-            }
-
-            private void applyLevelLimits() {
-                int[] sampleRates = null;
-                Range<Integer> sampleRateRange = null, bitRates = null;
-                int maxChannels = 0;
-                String mime = mParent.getMime();
-
-                if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MPEG)) {
-                    sampleRates = new int[] {
-                            8000, 11025, 12000,
-                            16000, 22050, 24000,
-                            32000, 44100, 48000 };
-                    bitRates = Range.create(8000, 320000);
-                    maxChannels = 2;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_NB)) {
-                    sampleRates = new int[] { 8000 };
-                    bitRates = Range.create(4750, 12200);
-                    maxChannels = 1;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_WB)) {
-                    sampleRates = new int[] { 16000 };
-                    bitRates = Range.create(6600, 23850);
-                    maxChannels = 1;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AAC)) {
-                    sampleRates = new int[] {
-                            7350, 8000,
-                            11025, 12000, 16000,
-                            22050, 24000, 32000,
-                            44100, 48000, 64000,
-                            88200, 96000 };
-                    bitRates = Range.create(8000, 510000);
-                    maxChannels = 48;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_VORBIS)) {
-                    bitRates = Range.create(32000, 500000);
-                    sampleRates = new int[] { 8000, 12000, 16000, 24000, 48000, 192000 };
-                    maxChannels = 255;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_OPUS)) {
-                    bitRates = Range.create(6000, 510000);
-                    sampleRates = new int[] { 8000, 12000, 16000, 24000, 48000 };
-                    maxChannels = 255;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_RAW)) {
-                    sampleRateRange = Range.create(1, 96000);
-                    bitRates = Range.create(1, 10000000);
-                    maxChannels = 8;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_FLAC)) {
-                    sampleRateRange = Range.create(1, 655350);
-                    // lossless codec, so bitrate is ignored
-                    maxChannels = 255;
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_ALAW)
-                        || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_MLAW)) {
-                    sampleRates = new int[] { 8000 };
-                    bitRates = Range.create(64000, 64000);
-                    // platform allows multiple channels for this format
-                } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MSGSM)) {
-                    sampleRates = new int[] { 8000 };
-                    bitRates = Range.create(13000, 13000);
-                    maxChannels = 1;
-                } else {
-                    Log.w(TAG, "Unsupported mime " + mime);
-                    mParent.mError |= ERROR_UNSUPPORTED;
-                }
-
-                // restrict ranges
-                if (sampleRates != null) {
-                    limitSampleRates(sampleRates);
-                } else if (sampleRateRange != null) {
-                    limitSampleRates(new Range[] { sampleRateRange });
-                }
-                applyLimits(maxChannels, bitRates);
-            }
-
-            private void applyLimits(int maxInputChannels, Range<Integer> bitRates) {
-                mMaxInputChannelCount = Range.create(1, mMaxInputChannelCount)
-                        .clamp(maxInputChannels);
-                if (bitRates != null) {
-                    mBitrateRange = mBitrateRange.intersect(bitRates);
-                }
-            }
-
-            private void parseFromInfo(MediaFormat info) {
-                int maxInputChannels = MAX_INPUT_CHANNEL_COUNT;
-                Range<Integer> bitRates = POSITIVE_INTEGERS;
-
-                if (info.containsKey("sample-rate-ranges")) {
-                    String[] rateStrings = info.getString("sample-rate-ranges").split(",");
-                    Range<Integer>[] rateRanges = new Range[rateStrings.length];
-                    for (int i = 0; i < rateStrings.length; i++) {
-                        rateRanges[i] = Utils.parseIntRange(rateStrings[i], null);
-                    }
-                    limitSampleRates(rateRanges);
-                }
-                if (info.containsKey("max-channel-count")) {
-                    maxInputChannels = Utils.parseIntSafely(
-                            info.getString("max-channel-count"), maxInputChannels);
-                }
-                if (info.containsKey("bitrate-range")) {
-                    bitRates = bitRates.intersect(
-                            Utils.parseIntRange(info.getString("bitrate"), bitRates));
-                }
-                applyLimits(maxInputChannels, bitRates);
-            }
-
-            /** @hide */
-            public void setDefaultFormat(MediaFormat format) {
-                // report settings that have only a single choice
-                if (mBitrateRange.getLower().equals(mBitrateRange.getUpper())) {
-                    format.setInteger(MediaFormat.KEY_BIT_RATE, mBitrateRange.getLower());
-                }
-                if (mMaxInputChannelCount == 1) {
-                    // mono-only format
-                    format.setInteger(MediaFormat.KEY_CHANNEL_COUNT, 1);
-                }
-                if (mSampleRates != null && mSampleRates.length == 1) {
-                    format.setInteger(MediaFormat.KEY_SAMPLE_RATE, mSampleRates[0]);
-                }
-            }
-
-            /** @hide */
-            public boolean supportsFormat(MediaFormat format) {
-                Map<String, Object> map = format.getMap();
-                Integer sampleRate = (Integer)map.get(MediaFormat.KEY_SAMPLE_RATE);
-                Integer channels = (Integer)map.get(MediaFormat.KEY_CHANNEL_COUNT);
-                if (!supports(sampleRate, channels)) {
-                    return false;
-                }
-
-                // nothing to do for:
-                // KEY_CHANNEL_MASK: codecs don't get this
-                // KEY_IS_ADTS:      required feature for all AAC decoders
-                return true;
-            }
-        };
-
-        AudioCapabilities mAudioCaps;
-        private boolean isAudio() {
-            return mAudioCaps != null;
+        public Range<Integer> getBitrateRange() {
+            return mBitrateRange;
         }
 
         /**
-         * Returns the audio capabilities or {@code null} if this is not an audio codec.
+         * Returns the array of supported sample rates if the codec
+         * supports only discrete values.  Otherwise, it returns
+         * {@code null}.  The array is sorted in ascending order.
          */
-        public final AudioCapabilities getAudioCapabilities() {
-            return mAudioCaps;
+        public int[] getSupportedSampleRates() {
+            return Arrays.copyOf(mSampleRates, mSampleRates.length);
+        }
+
+        /**
+         * Returns the array of supported sample rate ranges.  The
+         * array is sorted in ascending order, and the ranges are
+         * distinct.
+         */
+        public Range<Integer>[] getSupportedSampleRateRanges() {
+            return Arrays.copyOf(mSampleRateRanges, mSampleRateRanges.length);
+        }
+
+        /**
+         * Returns the maximum number of input channels supported.  The codec
+         * supports any number of channels between 1 and this maximum value.
+         */
+        public int getMaxInputChannelCount() {
+            return mMaxInputChannelCount;
+        }
+
+        /* no public constructor */
+        private AudioCapabilities() { }
+
+        /** @hide */
+        public static AudioCapabilities create(
+                MediaFormat info, CodecCapabilities parent) {
+            AudioCapabilities caps = new AudioCapabilities();
+            caps.init(info, parent);
+            return caps;
         }
 
         /** @hide */
-        public CodecCapabilities dup() {
-            return new CodecCapabilities(
-                // clone writable arrays
-                Arrays.copyOf(profileLevels, profileLevels.length),
-                Arrays.copyOf(colorFormats, colorFormats.length),
-                isEncoder(),
-                mFlagsVerified,
-                mDefaultFormat,
-                mCapabilitiesInfo);
+        public void init(MediaFormat info, CodecCapabilities parent) {
+            mParent = parent;
+            initWithPlatformLimits();
+            applyLevelLimits();
+            parseFromInfo(info);
+        }
+
+        private void initWithPlatformLimits() {
+            mBitrateRange = Range.create(0, Integer.MAX_VALUE);
+            mMaxInputChannelCount = MAX_INPUT_CHANNEL_COUNT;
+            // mBitrateRange = Range.create(1, 320000);
+            mSampleRateRanges = new Range[] { Range.create(8000, 96000) };
+            mSampleRates = null;
+        }
+
+        private boolean supports(Integer sampleRate, Integer inputChannels) {
+            // channels and sample rates are checked orthogonally
+            if (inputChannels != null &&
+                    (inputChannels < 1 || inputChannels > mMaxInputChannelCount)) {
+                return false;
+            }
+            if (sampleRate != null) {
+                int ix = Utils.binarySearchDistinctRanges(
+                        mSampleRateRanges, sampleRate);
+                if (ix < 0) {
+                    return false;
+                }
+            }
+            return true;
+        }
+
+        /**
+         * Query whether the sample rate is supported by the codec.
+         */
+        public boolean isSampleRateSupported(int sampleRate) {
+            return supports(sampleRate, null);
+        }
+
+        /** modifies rates */
+        private void limitSampleRates(int[] rates) {
+            Arrays.sort(rates);
+            ArrayList<Range<Integer>> ranges = new ArrayList<Range<Integer>>();
+            for (int rate: rates) {
+                if (supports(rate, null /* channels */)) {
+                    ranges.add(Range.create(rate, rate));
+                }
+            }
+            mSampleRateRanges = ranges.toArray(new Range[ranges.size()]);
+            createDiscreteSampleRates();
+        }
+
+        private void createDiscreteSampleRates() {
+            mSampleRates = new int[mSampleRateRanges.length];
+            for (int i = 0; i < mSampleRateRanges.length; i++) {
+                mSampleRates[i] = mSampleRateRanges[i].getLower();
+            }
+        }
+
+        /** modifies rateRanges */
+        private void limitSampleRates(Range<Integer>[] rateRanges) {
+            sortDistinctRanges(rateRanges);
+            mSampleRateRanges = intersectSortedDistinctRanges(mSampleRateRanges, rateRanges);
+
+            // check if all values are discrete
+            for (Range<Integer> range: mSampleRateRanges) {
+                if (!range.getLower().equals(range.getUpper())) {
+                    mSampleRates = null;
+                    return;
+                }
+            }
+            createDiscreteSampleRates();
+        }
+
+        private void applyLevelLimits() {
+            int[] sampleRates = null;
+            Range<Integer> sampleRateRange = null, bitRates = null;
+            int maxChannels = 0;
+            String mime = mParent.getMimeType();
+
+            if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MPEG)) {
+                sampleRates = new int[] {
+                        8000, 11025, 12000,
+                        16000, 22050, 24000,
+                        32000, 44100, 48000 };
+                bitRates = Range.create(8000, 320000);
+                maxChannels = 2;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_NB)) {
+                sampleRates = new int[] { 8000 };
+                bitRates = Range.create(4750, 12200);
+                maxChannels = 1;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_WB)) {
+                sampleRates = new int[] { 16000 };
+                bitRates = Range.create(6600, 23850);
+                maxChannels = 1;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AAC)) {
+                sampleRates = new int[] {
+                        7350, 8000,
+                        11025, 12000, 16000,
+                        22050, 24000, 32000,
+                        44100, 48000, 64000,
+                        88200, 96000 };
+                bitRates = Range.create(8000, 510000);
+                maxChannels = 48;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_VORBIS)) {
+                bitRates = Range.create(32000, 500000);
+                sampleRates = new int[] { 8000, 12000, 16000, 24000, 48000, 192000 };
+                maxChannels = 255;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_OPUS)) {
+                bitRates = Range.create(6000, 510000);
+                sampleRates = new int[] { 8000, 12000, 16000, 24000, 48000 };
+                maxChannels = 255;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_RAW)) {
+                sampleRateRange = Range.create(1, 96000);
+                bitRates = Range.create(1, 10000000);
+                maxChannels = 8;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_FLAC)) {
+                sampleRateRange = Range.create(1, 655350);
+                // lossless codec, so bitrate is ignored
+                maxChannels = 255;
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_ALAW)
+                    || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_MLAW)) {
+                sampleRates = new int[] { 8000 };
+                bitRates = Range.create(64000, 64000);
+                // platform allows multiple channels for this format
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MSGSM)) {
+                sampleRates = new int[] { 8000 };
+                bitRates = Range.create(13000, 13000);
+                maxChannels = 1;
+            } else {
+                Log.w(TAG, "Unsupported mime " + mime);
+                mParent.mError |= ERROR_UNSUPPORTED;
+            }
+
+            // restrict ranges
+            if (sampleRates != null) {
+                limitSampleRates(sampleRates);
+            } else if (sampleRateRange != null) {
+                limitSampleRates(new Range[] { sampleRateRange });
+            }
+            applyLimits(maxChannels, bitRates);
+        }
+
+        private void applyLimits(int maxInputChannels, Range<Integer> bitRates) {
+            mMaxInputChannelCount = Range.create(1, mMaxInputChannelCount)
+                    .clamp(maxInputChannels);
+            if (bitRates != null) {
+                mBitrateRange = mBitrateRange.intersect(bitRates);
+            }
+        }
+
+        private void parseFromInfo(MediaFormat info) {
+            int maxInputChannels = MAX_INPUT_CHANNEL_COUNT;
+            Range<Integer> bitRates = POSITIVE_INTEGERS;
+
+            if (info.containsKey("sample-rate-ranges")) {
+                String[] rateStrings = info.getString("sample-rate-ranges").split(",");
+                Range<Integer>[] rateRanges = new Range[rateStrings.length];
+                for (int i = 0; i < rateStrings.length; i++) {
+                    rateRanges[i] = Utils.parseIntRange(rateStrings[i], null);
+                }
+                limitSampleRates(rateRanges);
+            }
+            if (info.containsKey("max-channel-count")) {
+                maxInputChannels = Utils.parseIntSafely(
+                        info.getString("max-channel-count"), maxInputChannels);
+            }
+            if (info.containsKey("bitrate-range")) {
+                bitRates = bitRates.intersect(
+                        Utils.parseIntRange(info.getString("bitrate"), bitRates));
+            }
+            applyLimits(maxInputChannels, bitRates);
+        }
+
+        /** @hide */
+        public void setDefaultFormat(MediaFormat format) {
+            // report settings that have only a single choice
+            if (mBitrateRange.getLower().equals(mBitrateRange.getUpper())) {
+                format.setInteger(MediaFormat.KEY_BIT_RATE, mBitrateRange.getLower());
+            }
+            if (mMaxInputChannelCount == 1) {
+                // mono-only format
+                format.setInteger(MediaFormat.KEY_CHANNEL_COUNT, 1);
+            }
+            if (mSampleRates != null && mSampleRates.length == 1) {
+                format.setInteger(MediaFormat.KEY_SAMPLE_RATE, mSampleRates[0]);
+            }
+        }
+
+        /** @hide */
+        public boolean supportsFormat(MediaFormat format) {
+            Map<String, Object> map = format.getMap();
+            Integer sampleRate = (Integer)map.get(MediaFormat.KEY_SAMPLE_RATE);
+            Integer channels = (Integer)map.get(MediaFormat.KEY_CHANNEL_COUNT);
+            if (!supports(sampleRate, channels)) {
+                return false;
+            }
+
+            // nothing to do for:
+            // KEY_CHANNEL_MASK: codecs don't get this
+            // KEY_IS_ADTS:      required feature for all AAC decoders
+            return true;
+        }
+    }
+
+    /**
+     * A class that supports querying the video capabilities of a codec.
+     */
+    public static final class VideoCapabilities {
+        private static final String TAG = "VideoCapabilities";
+        private CodecCapabilities mParent;
+        private Range<Integer> mBitrateRange;
+
+        private Range<Integer> mHeightRange;
+        private Range<Integer> mWidthRange;
+        private Range<Integer> mBlockCountRange;
+        private Range<Integer> mHorizontalBlockRange;
+        private Range<Integer> mVerticalBlockRange;
+        private Range<Rational> mAspectRatioRange;
+        private Range<Rational> mBlockAspectRatioRange;
+        private Range<Long> mBlocksPerSecondRange;
+        private Range<Integer> mFrameRateRange;
+
+        private int mBlockWidth;
+        private int mBlockHeight;
+        private int mWidthAlignment;
+        private int mHeightAlignment;
+        private int mSmallerDimensionUpperLimit;
+
+        /**
+         * Returns the range of supported bitrates in bits/second.
+         */
+        public Range<Integer> getBitrateRange() {
+            return mBitrateRange;
+        }
+
+        /**
+         * Returns the range of supported video widths.
+         */
+        public Range<Integer> getSupportedWidths() {
+            return mWidthRange;
+        }
+
+        /**
+         * Returns the range of supported video heights.
+         */
+        public Range<Integer> getSupportedHeights() {
+            return mHeightRange;
+        }
+
+        /**
+         * Returns the alignment requirement for video width (in pixels).
+         *
+         * This is a power-of-2 value that video width must be a
+         * multiple of.
+         */
+        public int getWidthAlignment() {
+            return mWidthAlignment;
+        }
+
+        /**
+         * Returns the alignment requirement for video height (in pixels).
+         *
+         * This is a power-of-2 value that video height must be a
+         * multiple of.
+         */
+        public int getHeightAlignment() {
+            return mHeightAlignment;
+        }
+
+        /**
+         * Return the upper limit on the smaller dimension of width or height.
+         * <p></p>
+         * Some codecs have a limit on the smaller dimension, whether it be
+         * the width or the height.  E.g. a codec may only be able to handle
+         * up to 1920x1080 both in landscape and portrait mode (1080x1920).
+         * In this case the maximum width and height are both 1920, but the
+         * smaller dimension limit will be 1080. For other codecs, this is
+         * {@code Math.min(getSupportedWidths().getUpper(),
+         * getSupportedHeights().getUpper())}.
+         *
+         * @hide
+         */
+        public int getSmallerDimensionUpperLimit() {
+            return mSmallerDimensionUpperLimit;
+        }
+
+        /**
+         * Returns the range of supported frame rates.
+         * <p>
+         * This is not a performance indicator.  Rather, it expresses the
+         * limits specified in the coding standard, based on the complexities
+         * of encoding material for later playback at a certain frame rate,
+         * or the decoding of such material in non-realtime.
+         */
+        public Range<Integer> getSupportedFrameRates() {
+            return mFrameRateRange;
+        }
+
+        /**
+         * Returns the range of supported video widths for a video height.
+         * @param height the height of the video
+         */
+        public Range<Integer> getSupportedWidthsFor(int height) {
+            try {
+                Range<Integer> range = mWidthRange;
+                if (!mHeightRange.contains(height)
+                        || (height % mHeightAlignment) != 0) {
+                    throw new IllegalArgumentException("unsupported height");
+                }
+                final int heightInBlocks = Utils.divUp(height, mBlockHeight);
+
+                // constrain by block count and by block aspect ratio
+                final int minWidthInBlocks = Math.max(
+                        Utils.divUp(mBlockCountRange.getLower(), heightInBlocks),
+                        (int)Math.ceil(mBlockAspectRatioRange.getLower().doubleValue()
+                                * heightInBlocks));
+                final int maxWidthInBlocks = Math.min(
+                        mBlockCountRange.getUpper() / heightInBlocks,
+                        (int)(mBlockAspectRatioRange.getUpper().doubleValue()
+                                * heightInBlocks));
+                range = range.intersect(
+                        (minWidthInBlocks - 1) * mBlockWidth + mWidthAlignment,
+                        maxWidthInBlocks * mBlockWidth);
+
+                // constrain by smaller dimension limit
+                if (height > mSmallerDimensionUpperLimit) {
+                    range = range.intersect(1, mSmallerDimensionUpperLimit);
+                }
+
+                // constrain by aspect ratio
+                range = range.intersect(
+                        (int)Math.ceil(mAspectRatioRange.getLower().doubleValue()
+                                * height),
+                        (int)(mAspectRatioRange.getUpper().doubleValue() * height));
+                return range;
+            } catch (IllegalArgumentException e) {
+                // should not be here
+                Log.w(TAG, "could not get supported widths for " + height , e);
+                throw new IllegalArgumentException("unsupported height");
+            }
+        }
+
+        /**
+         * Returns the range of supported video heights for a video width
+         * @param width the width of the video
+         */
+        public Range<Integer> getSupportedHeightsFor(int width) {
+            try {
+                Range<Integer> range = mHeightRange;
+                if (!mWidthRange.contains(width)
+                        || (width % mWidthAlignment) != 0) {
+                    throw new IllegalArgumentException("unsupported width");
+                }
+                final int widthInBlocks = Utils.divUp(width, mBlockWidth);
+
+                // constrain by block count and by block aspect ratio
+                final int minHeightInBlocks = Math.max(
+                        Utils.divUp(mBlockCountRange.getLower(), widthInBlocks),
+                        (int)Math.ceil(widthInBlocks /
+                                mBlockAspectRatioRange.getUpper().doubleValue()));
+                final int maxHeightInBlocks = Math.min(
+                        mBlockCountRange.getUpper() / widthInBlocks,
+                        (int)(widthInBlocks /
+                                mBlockAspectRatioRange.getLower().doubleValue()));
+                range = range.intersect(
+                        (minHeightInBlocks - 1) * mBlockHeight + mHeightAlignment,
+                        maxHeightInBlocks * mBlockHeight);
+
+                // constrain by smaller dimension limit
+                if (width > mSmallerDimensionUpperLimit) {
+                    range = range.intersect(1, mSmallerDimensionUpperLimit);
+                }
+
+                // constrain by aspect ratio
+                range = range.intersect(
+                        (int)Math.ceil(width /
+                                mAspectRatioRange.getUpper().doubleValue()),
+                        (int)(width / mAspectRatioRange.getLower().doubleValue()));
+                return range;
+            } catch (IllegalArgumentException e) {
+                // should not be here
+                Log.w(TAG, "could not get supported heights for " + width , e);
+                throw new IllegalArgumentException("unsupported width");
+            }
+        }
+
+        /**
+         * Returns the range of supported video frame rates for a video size.
+         * <p>
+         * This is not a performance indicator.  Rather, it expresses the limits specified in
+         * the coding standard, based on the complexities of encoding material of a given
+         * size for later playback at a certain frame rate, or the decoding of such material
+         * in non-realtime.
+
+         * @param width the width of the video
+         * @param height the height of the video
+         */
+        public Range<Double> getSupportedFrameRatesFor(int width, int height) {
+            Range<Integer> range = mHeightRange;
+            if (!supports(width, height, null)) {
+                throw new IllegalArgumentException("unsupported size");
+            }
+            final int blockCount =
+                Utils.divUp(width, mBlockWidth) * Utils.divUp(height, mBlockHeight);
+
+            return Range.create(
+                    Math.max(mBlocksPerSecondRange.getLower() / (double) blockCount,
+                            (double) mFrameRateRange.getLower()),
+                    Math.min(mBlocksPerSecondRange.getUpper() / (double) blockCount,
+                            (double) mFrameRateRange.getUpper()));
+        }
+
+        /**
+         * Returns whether a given video size ({@code width} and
+         * {@code height}) and {@code frameRate} combination is supported.
+         */
+        public boolean areSizeAndRateSupported(
+                int width, int height, double frameRate) {
+            return supports(width, height, frameRate);
+        }
+
+        /**
+         * Returns whether a given video size ({@code width} and
+         * {@code height}) is supported.
+         */
+        public boolean isSizeSupported(int width, int height) {
+            return supports(width, height, null);
+        }
+
+        private boolean supports(
+                Integer width, Integer height, Double rate) {
+            boolean ok = true;
+
+            if (ok && width != null) {
+                ok = mWidthRange.contains(width)
+                        && (width % mWidthAlignment == 0);
+            }
+            if (ok && height != null) {
+                ok = mHeightRange.contains(height)
+                        && (height % mHeightAlignment == 0);
+            }
+            if (ok && rate != null) {
+                ok = mFrameRateRange.contains(Utils.intRangeFor(rate));
+            }
+            if (ok && height != null && width != null) {
+                ok = Math.min(height, width) <= mSmallerDimensionUpperLimit;
+
+                final int widthInBlocks = Utils.divUp(width, mBlockWidth);
+                final int heightInBlocks = Utils.divUp(height, mBlockHeight);
+                final int blockCount = widthInBlocks * heightInBlocks;
+                ok = ok && mBlockCountRange.contains(blockCount)
+                        && mBlockAspectRatioRange.contains(
+                                new Rational(widthInBlocks, heightInBlocks))
+                        && mAspectRatioRange.contains(new Rational(width, height));
+                if (ok && rate != null) {
+                    double blocksPerSec = blockCount * rate;
+                    ok = mBlocksPerSecondRange.contains(
+                            Utils.longRangeFor(blocksPerSec));
+                }
+            }
+            return ok;
+        }
+
+        /**
+         * @hide
+         * @throws java.lang.ClassCastException */
+        public boolean supportsFormat(MediaFormat format) {
+            final Map<String, Object> map = format.getMap();
+            Integer width = (Integer)map.get(MediaFormat.KEY_WIDTH);
+            Integer height = (Integer)map.get(MediaFormat.KEY_HEIGHT);
+            Double rate = (Double)map.get(MediaFormat.KEY_FRAME_RATE);
+
+            // we ignore color-format for now as it is not reliably reported by codec
+
+            return supports(width, height, rate);
+        }
+
+        /* no public constructor */
+        private VideoCapabilities() { }
+
+        /** @hide */
+        public static VideoCapabilities create(
+                MediaFormat info, CodecCapabilities parent) {
+            VideoCapabilities caps = new VideoCapabilities();
+            caps.init(info, parent);
+            return caps;
+        }
+
+        /** @hide */
+        public void init(MediaFormat info, CodecCapabilities parent) {
+            mParent = parent;
+            initWithPlatformLimits();
+            applyLevelLimits();
+            parseFromInfo(info);
+            updateLimits();
+        }
+
+        /** @hide */
+        public Size getBlockSize() {
+            return new Size(mBlockWidth, mBlockHeight);
+        }
+
+        /** @hide */
+        public Range<Integer> getBlockCountRange() {
+            return mBlockCountRange;
+        }
+
+        /** @hide */
+        public Range<Long> getBlocksPerSecondRange() {
+            return mBlocksPerSecondRange;
+        }
+
+        /** @hide */
+        public Range<Rational> getAspectRatioRange(boolean blocks) {
+            return blocks ? mBlockAspectRatioRange : mAspectRatioRange;
+        }
+
+        private void initWithPlatformLimits() {
+            mBitrateRange = Range.create(0, Integer.MAX_VALUE);
+
+            mWidthRange  = SIZE_RANGE;
+            mHeightRange = SIZE_RANGE;
+            mFrameRateRange = FRAME_RATE_RANGE;
+
+            mHorizontalBlockRange = SIZE_RANGE;
+            mVerticalBlockRange   = SIZE_RANGE;
+
+            // full positive ranges are supported as these get calculated
+            mBlockCountRange      = POSITIVE_INTEGERS;
+            mBlocksPerSecondRange = POSITIVE_LONGS;
+
+            mBlockAspectRatioRange = POSITIVE_RATIONALS;
+            mAspectRatioRange      = POSITIVE_RATIONALS;
+
+            // YUV 4:2:0 requires 2:2 alignment
+            mWidthAlignment = 2;
+            mHeightAlignment = 2;
+            mBlockWidth = 2;
+            mBlockHeight = 2;
+            mSmallerDimensionUpperLimit = SIZE_RANGE.getUpper();
+        }
+
+        private void parseFromInfo(MediaFormat info) {
+            final Map<String, Object> map = info.getMap();
+            Size blockSize = new Size(mBlockWidth, mBlockHeight);
+            Size alignment = new Size(mWidthAlignment, mHeightAlignment);
+            Range<Integer> counts = null, widths = null, heights = null;
+            Range<Integer> frameRates = null;
+            Range<Long> blockRates = null;
+            Range<Rational> ratios = null, blockRatios = null;
+
+            blockSize = Utils.parseSize(map.get("block-size"), blockSize);
+            alignment = Utils.parseSize(map.get("alignment"), alignment);
+            counts = Utils.parseIntRange(map.get("block-count-range"), null);
+            blockRates =
+                Utils.parseLongRange(map.get("blocks-per-second-range"), null);
+            {
+                Object o = map.get("size-range");
+                Pair<Size, Size> sizeRange = Utils.parseSizeRange(o);
+                if (sizeRange != null) {
+                    try {
+                        widths = Range.create(
+                                sizeRange.first.getWidth(),
+                                sizeRange.second.getWidth());
+                        heights = Range.create(
+                                sizeRange.first.getHeight(),
+                                sizeRange.second.getHeight());
+                    } catch (IllegalArgumentException e) {
+                        Log.w(TAG, "could not parse size range '" + o + "'");
+                        widths = null;
+                        heights = null;
+                    }
+                }
+            }
+            // for now this just means using the smaller max size as 2nd
+            // upper limit.
+            // for now we are keeping the profile specific "width/height
+            // in macroblocks" limits.
+            if (Integer.valueOf(1).equals(map.get("feature-can-swap-width-height"))) {
+                if (widths != null) {
+                    mSmallerDimensionUpperLimit =
+                        Math.min(widths.getUpper(), heights.getUpper());
+                    widths = heights = widths.extend(heights);
+                } else {
+                    Log.w(TAG, "feature can-swap-width-height is best used with size-range");
+                    mSmallerDimensionUpperLimit =
+                        Math.min(mWidthRange.getUpper(), mHeightRange.getUpper());
+                    mWidthRange = mHeightRange = mWidthRange.extend(mHeightRange);
+                }
+            }
+
+            ratios = Utils.parseRationalRange(
+                    map.get("block-aspect-ratio-range"), null);
+            blockRatios = Utils.parseRationalRange(
+                    map.get("pixel-aspect-ratio-range"), null);
+            frameRates = Utils.parseIntRange(map.get("frame-rate-range"), null);
+            if (frameRates != null) {
+                try {
+                    frameRates = frameRates.intersect(FRAME_RATE_RANGE);
+                } catch (IllegalArgumentException e) {
+                    Log.w(TAG, "frame rate range (" + frameRates
+                            + ") is out of limits: " + FRAME_RATE_RANGE);
+                    frameRates = null;
+                }
+            }
+
+            checkPowerOfTwo(
+                    blockSize.getWidth(), "block-size width must be power of two");
+            checkPowerOfTwo(
+                    blockSize.getHeight(), "block-size height must be power of two");
+
+            checkPowerOfTwo(
+                    alignment.getWidth(), "alignment width must be power of two");
+            checkPowerOfTwo(
+                    alignment.getHeight(), "alignment height must be power of two");
+
+            // update block-size and alignment
+            applyMacroBlockLimits(
+                    Integer.MAX_VALUE, Integer.MAX_VALUE, Integer.MAX_VALUE,
+                    Long.MAX_VALUE, blockSize.getWidth(), blockSize.getHeight(),
+                    alignment.getWidth(), alignment.getHeight());
+
+            if ((mParent.mError & ERROR_UNSUPPORTED) != 0) {
+                // codec supports profiles that we don't know.
+                // Use supplied values clipped to platform limits
+                if (widths != null) {
+                    mWidthRange = SIZE_RANGE.intersect(widths);
+                }
+                if (heights != null) {
+                    mHeightRange = SIZE_RANGE.intersect(heights);
+                }
+                if (counts != null) {
+                    mBlockCountRange = POSITIVE_INTEGERS.intersect(
+                            Utils.factorRange(counts, mBlockWidth * mBlockHeight
+                                    / blockSize.getWidth() / blockSize.getHeight()));
+                }
+                if (blockRates != null) {
+                    mBlocksPerSecondRange = POSITIVE_LONGS.intersect(
+                            Utils.factorRange(blockRates, mBlockWidth * mBlockHeight
+                                    / blockSize.getWidth() / blockSize.getHeight()));
+                }
+                if (blockRatios != null) {
+                    mBlockAspectRatioRange = POSITIVE_RATIONALS.intersect(
+                            Utils.scaleRange(blockRatios,
+                                    mBlockHeight / blockSize.getHeight(),
+                                    mBlockWidth / blockSize.getWidth()));
+                }
+                if (ratios != null) {
+                    mAspectRatioRange = POSITIVE_RATIONALS.intersect(ratios);
+                }
+                if (frameRates != null) {
+                    mFrameRateRange = FRAME_RATE_RANGE.intersect(frameRates);
+                }
+            } else {
+                // no unsupported profile/levels, so restrict values to known limits
+                if (widths != null) {
+                    mWidthRange = mWidthRange.intersect(widths);
+                }
+                if (heights != null) {
+                    mHeightRange = mHeightRange.intersect(heights);
+                }
+                if (counts != null) {
+                    mBlockCountRange = mBlockCountRange.intersect(
+                            Utils.factorRange(counts, mBlockWidth * mBlockHeight
+                                    / blockSize.getWidth() / blockSize.getHeight()));
+                }
+                if (blockRates != null) {
+                    mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(
+                            Utils.factorRange(blockRates, mBlockWidth * mBlockHeight
+                                    / blockSize.getWidth() / blockSize.getHeight()));
+                }
+                if (blockRatios != null) {
+                    mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(
+                            Utils.scaleRange(blockRatios,
+                                    mBlockHeight / blockSize.getHeight(),
+                                    mBlockWidth / blockSize.getWidth()));
+                }
+                if (ratios != null) {
+                    mAspectRatioRange = mAspectRatioRange.intersect(ratios);
+                }
+                if (frameRates != null) {
+                    mFrameRateRange = mFrameRateRange.intersect(frameRates);
+                }
+            }
+            updateLimits();
+        }
+
+        private void applyBlockLimits(
+                int blockWidth, int blockHeight,
+                Range<Integer> counts, Range<Long> rates, Range<Rational> ratios) {
+            checkPowerOfTwo(blockWidth, "blockWidth must be a power of two");
+            checkPowerOfTwo(blockHeight, "blockHeight must be a power of two");
+
+            final int newBlockWidth = Math.max(blockWidth, mBlockWidth);
+            final int newBlockHeight = Math.max(blockHeight, mBlockHeight);
+
+            // factor will always be a power-of-2
+            int factor =
+                newBlockWidth * newBlockHeight / mBlockWidth / mBlockHeight;
+            if (factor != 1) {
+                mBlockCountRange = Utils.factorRange(mBlockCountRange, factor);
+                mBlocksPerSecondRange = Utils.factorRange(
+                        mBlocksPerSecondRange, factor);
+                mBlockAspectRatioRange = Utils.scaleRange(
+                        mBlockAspectRatioRange,
+                        newBlockHeight / mBlockHeight,
+                        newBlockWidth / mBlockWidth);
+                mHorizontalBlockRange = Utils.factorRange(
+                        mHorizontalBlockRange, newBlockWidth / mBlockWidth);
+                mVerticalBlockRange = Utils.factorRange(
+                        mVerticalBlockRange, newBlockHeight / mBlockHeight);
+            }
+            factor = newBlockWidth * newBlockHeight / blockWidth / blockHeight;
+            if (factor != 1) {
+                counts = Utils.factorRange(counts, factor);
+                rates = Utils.factorRange(rates, factor);
+                ratios = Utils.scaleRange(
+                        ratios, newBlockHeight / blockHeight,
+                        newBlockWidth / blockWidth);
+            }
+            mBlockCountRange = mBlockCountRange.intersect(counts);
+            mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(rates);
+            mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(ratios);
+            mBlockWidth = newBlockWidth;
+            mBlockHeight = newBlockHeight;
+        }
+
+        private void applyAlignment(int widthAlignment, int heightAlignment) {
+            checkPowerOfTwo(widthAlignment, "widthAlignment must be a power of two");
+            checkPowerOfTwo(heightAlignment, "heightAlignment must be a power of two");
+
+            if (widthAlignment > mBlockWidth || heightAlignment > mBlockHeight) {
+                // maintain assumption that 0 < alignment <= block-size
+                applyBlockLimits(
+                        Math.max(widthAlignment, mBlockWidth),
+                        Math.max(heightAlignment, mBlockHeight),
+                        POSITIVE_INTEGERS, POSITIVE_LONGS, POSITIVE_RATIONALS);
+            }
+
+            mWidthAlignment = Math.max(widthAlignment, mWidthAlignment);
+            mHeightAlignment = Math.max(heightAlignment, mHeightAlignment);
+
+            mWidthRange = Utils.alignRange(mWidthRange, mWidthAlignment);
+            mHeightRange = Utils.alignRange(mHeightRange, mHeightAlignment);
+        }
+
+        private void updateLimits() {
+            // pixels -> blocks <- counts
+            mHorizontalBlockRange = mHorizontalBlockRange.intersect(
+                    Utils.factorRange(mWidthRange, mBlockWidth));
+            mHorizontalBlockRange = mHorizontalBlockRange.intersect(
+                    Range.create(
+                            mBlockCountRange.getLower() / mVerticalBlockRange.getUpper(),
+                            mBlockCountRange.getUpper() / mVerticalBlockRange.getLower()));
+            mVerticalBlockRange = mVerticalBlockRange.intersect(
+                    Utils.factorRange(mHeightRange, mBlockHeight));
+            mVerticalBlockRange = mVerticalBlockRange.intersect(
+                    Range.create(
+                            mBlockCountRange.getLower() / mHorizontalBlockRange.getUpper(),
+                            mBlockCountRange.getUpper() / mHorizontalBlockRange.getLower()));
+            mBlockCountRange = mBlockCountRange.intersect(
+                    Range.create(
+                            mHorizontalBlockRange.getLower()
+                                    * mVerticalBlockRange.getLower(),
+                            mHorizontalBlockRange.getUpper()
+                                    * mVerticalBlockRange.getUpper()));
+            mBlockAspectRatioRange = mBlockAspectRatioRange.intersect(
+                    new Rational(
+                            mHorizontalBlockRange.getLower(), mVerticalBlockRange.getUpper()),
+                    new Rational(
+                            mHorizontalBlockRange.getUpper(), mVerticalBlockRange.getLower()));
+
+            // blocks -> pixels
+            mWidthRange = mWidthRange.intersect(
+                    (mHorizontalBlockRange.getLower() - 1) * mBlockWidth + mWidthAlignment,
+                    mHorizontalBlockRange.getUpper() * mBlockWidth);
+            mHeightRange = mHeightRange.intersect(
+                    (mVerticalBlockRange.getLower() - 1) * mBlockHeight + mHeightAlignment,
+                    mVerticalBlockRange.getUpper() * mBlockHeight);
+            mAspectRatioRange = mAspectRatioRange.intersect(
+                    new Rational(mWidthRange.getLower(), mHeightRange.getUpper()),
+                    new Rational(mWidthRange.getUpper(), mHeightRange.getLower()));
+
+            mSmallerDimensionUpperLimit = Math.min(
+                    mSmallerDimensionUpperLimit,
+                    Math.min(mWidthRange.getUpper(), mHeightRange.getUpper()));
+
+            // blocks -> rate
+            mBlocksPerSecondRange = mBlocksPerSecondRange.intersect(
+                    mBlockCountRange.getLower() * (long)mFrameRateRange.getLower(),
+                    mBlockCountRange.getUpper() * (long)mFrameRateRange.getUpper());
+            mFrameRateRange = mFrameRateRange.intersect(
+                    (int)(mBlocksPerSecondRange.getLower()
+                            / mBlockCountRange.getUpper()),
+                    (int)(mBlocksPerSecondRange.getUpper()
+                            / (double)mBlockCountRange.getLower()));
+        }
+
+        private void applyMacroBlockLimits(
+                int maxHorizontalBlocks, int maxVerticalBlocks,
+                int maxBlocks, long maxBlocksPerSecond,
+                int blockWidth, int blockHeight,
+                int widthAlignment, int heightAlignment) {
+            applyAlignment(widthAlignment, heightAlignment);
+            applyBlockLimits(
+                    blockWidth, blockHeight, Range.create(1, maxBlocks),
+                    Range.create(1L, maxBlocksPerSecond),
+                    Range.create(
+                            new Rational(1, maxVerticalBlocks),
+                            new Rational(maxHorizontalBlocks, 1)));
+            mHorizontalBlockRange =
+                    mHorizontalBlockRange.intersect(
+                            1, maxHorizontalBlocks / (mBlockWidth / blockWidth));
+            mVerticalBlockRange =
+                    mVerticalBlockRange.intersect(
+                            1, maxVerticalBlocks / (mBlockHeight / blockHeight));
+        }
+
+        private void applyLevelLimits() {
+            int maxBlocksPerSecond = 0;
+            int maxBlocks = 0;
+            int maxBps = 0;
+            int maxDPBBlocks = 0;
+
+            int errors = ERROR_NONE_SUPPORTED;
+            CodecProfileLevel[] profileLevels = mParent.profileLevels;
+            String mime = mParent.getMimeType();
+
+            if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_AVC)) {
+                maxBlocks = 99;
+                maxBlocksPerSecond = 1485;
+                maxBps = 64000;
+                maxDPBBlocks = 396;
+                for (CodecProfileLevel profileLevel: profileLevels) {
+                    int MBPS = 0, FS = 0, BR = 0, DPB = 0;
+                    boolean supported = true;
+                    switch (profileLevel.level) {
+                        case CodecProfileLevel.AVCLevel1:
+                            MBPS =    1485; FS =    99; BR =     64; DPB =    396; break;
+                        case CodecProfileLevel.AVCLevel1b:
+                            MBPS =    1485; FS =    99; BR =    128; DPB =    396; break;
+                        case CodecProfileLevel.AVCLevel11:
+                            MBPS =    3000; FS =   396; BR =    192; DPB =    900; break;
+                        case CodecProfileLevel.AVCLevel12:
+                            MBPS =    6000; FS =   396; BR =    384; DPB =   2376; break;
+                        case CodecProfileLevel.AVCLevel13:
+                            MBPS =   11880; FS =   396; BR =    768; DPB =   2376; break;
+                        case CodecProfileLevel.AVCLevel2:
+                            MBPS =   11880; FS =   396; BR =   2000; DPB =   2376; break;
+                        case CodecProfileLevel.AVCLevel21:
+                            MBPS =   19800; FS =   792; BR =   4000; DPB =   4752; break;
+                        case CodecProfileLevel.AVCLevel22:
+                            MBPS =   20250; FS =  1620; BR =   4000; DPB =   8100; break;
+                        case CodecProfileLevel.AVCLevel3:
+                            MBPS =   40500; FS =  1620; BR =  10000; DPB =   8100; break;
+                        case CodecProfileLevel.AVCLevel31:
+                            MBPS =  108000; FS =  3600; BR =  14000; DPB =  18000; break;
+                        case CodecProfileLevel.AVCLevel32:
+                            MBPS =  216000; FS =  5120; BR =  20000; DPB =  20480; break;
+                        case CodecProfileLevel.AVCLevel4:
+                            MBPS =  245760; FS =  8192; BR =  20000; DPB =  32768; break;
+                        case CodecProfileLevel.AVCLevel41:
+                            MBPS =  245760; FS =  8192; BR =  50000; DPB =  32768; break;
+                        case CodecProfileLevel.AVCLevel42:
+                            MBPS =  522240; FS =  8704; BR =  50000; DPB =  34816; break;
+                        case CodecProfileLevel.AVCLevel5:
+                            MBPS =  589824; FS = 22080; BR = 135000; DPB = 110400; break;
+                        case CodecProfileLevel.AVCLevel51:
+                            MBPS =  983040; FS = 36864; BR = 240000; DPB = 184320; break;
+                        case CodecProfileLevel.AVCLevel52:
+                            MBPS = 2073600; FS = 36864; BR = 240000; DPB = 184320; break;
+                        default:
+                            Log.w(TAG, "Unrecognized level "
+                                    + profileLevel.level + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    switch (profileLevel.profile) {
+                        case CodecProfileLevel.AVCProfileHigh:
+                            BR *= 1250; break;
+                        case CodecProfileLevel.AVCProfileHigh10:
+                            BR *= 3000; break;
+                        case CodecProfileLevel.AVCProfileExtended:
+                        case CodecProfileLevel.AVCProfileHigh422:
+                        case CodecProfileLevel.AVCProfileHigh444:
+                            Log.w(TAG, "Unsupported profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNSUPPORTED;
+                            supported = false;
+                            // fall through - treat as base profile
+                        case CodecProfileLevel.AVCProfileBaseline:
+                        case CodecProfileLevel.AVCProfileMain:
+                            BR *= 1000; break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                            BR *= 1000;
+                    }
+                    if (supported) {
+                        errors &= ~ERROR_NONE_SUPPORTED;
+                    }
+                    maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
+                    maxBlocks = Math.max(FS, maxBlocks);
+                    maxBps = Math.max(BR, maxBps);
+                    maxDPBBlocks = Math.max(maxDPBBlocks, DPB);
+                }
+
+                int maxLengthInBlocks = (int)(Math.sqrt(maxBlocks * 8));
+                applyMacroBlockLimits(
+                        maxLengthInBlocks, maxLengthInBlocks,
+                        maxBlocks, maxBlocksPerSecond,
+                        16 /* blockWidth */, 16 /* blockHeight */,
+                        1 /* widthAlignment */, 1 /* heightAlignment */);
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_MPEG4)) {
+                int maxWidth = 11, maxHeight = 9, maxRate = 15;
+                maxBlocks = 99;
+                maxBlocksPerSecond = 1485;
+                maxBps = 64000;
+                for (CodecProfileLevel profileLevel: profileLevels) {
+                    int MBPS = 0, FS = 0, BR = 0, FR = 0, W = 0, H = 0;
+                    boolean supported = true;
+                    switch (profileLevel.profile) {
+                        case CodecProfileLevel.MPEG4ProfileSimple:
+                            switch (profileLevel.level) {
+                                case CodecProfileLevel.MPEG4Level0:
+                                    FR = 15; W = 11; H =  9; MBPS =  1485; FS =  99; BR =  64; break;
+                                case CodecProfileLevel.MPEG4Level1:
+                                    FR = 30; W = 11; H =  9; MBPS =  1485; FS =  99; BR =  64; break;
+                                case CodecProfileLevel.MPEG4Level0b:
+                                    FR = 30; W = 11; H =  9; MBPS =  1485; FS =  99; BR = 128; break;
+                                case CodecProfileLevel.MPEG4Level2:
+                                    FR = 30; W = 22; H = 18; MBPS =  5940; FS = 396; BR = 128; break;
+                                case CodecProfileLevel.MPEG4Level3:
+                                    FR = 30; W = 22; H = 18; MBPS = 11880; FS = 396; BR = 384; break;
+                                case CodecProfileLevel.MPEG4Level4:
+                                case CodecProfileLevel.MPEG4Level4a:
+                                case CodecProfileLevel.MPEG4Level5:
+                                    // While MPEG4 SP does not have level 4 or 5, some vendors
+                                    // report it. Use the same limits as level 3, but mark as
+                                    // unsupported.
+                                    FR = 30; W = 22; H = 18; MBPS = 11880; FS = 396; BR = 384;
+                                    supported = false;
+                                    break;
+                                default:
+                                    Log.w(TAG, "Unrecognized profile/level "
+                                            + profileLevel.profile + "/"
+                                            + profileLevel.level + " for " + mime);
+                                    errors |= ERROR_UNRECOGNIZED;
+                            }
+                            break;
+                        case CodecProfileLevel.MPEG4ProfileAdvancedSimple:
+                            switch (profileLevel.level) {
+                                case CodecProfileLevel.MPEG4Level0:
+                                case CodecProfileLevel.MPEG4Level1:
+                                    FR = 30; W = 11; H =  9; MBPS =  2970; FS =   99; BR =  128; break;
+                                case CodecProfileLevel.MPEG4Level2:
+                                    FR = 30; W = 22; H = 18; MBPS =  5940; FS =  396; BR =  384; break;
+                                case CodecProfileLevel.MPEG4Level3:
+                                    FR = 30; W = 22; H = 18; MBPS = 11880; FS =  396; BR =  768; break;
+                                // case CodecProfileLevel.MPEG4Level3b:
+                                // TODO: MPEG4 level 3b is not defined in OMX
+                                //  MBPS = 11880; FS =  396; BR = 1500; break;
+                                case CodecProfileLevel.MPEG4Level4:
+                                case CodecProfileLevel.MPEG4Level4a:
+                                    // TODO: MPEG4 level 4a is not defined in spec
+                                    FR = 30; W = 44; H = 36; MBPS = 23760; FS =  792; BR = 3000; break;
+                                case CodecProfileLevel.MPEG4Level5:
+                                    FR = 30; W = 45; H = 36; MBPS = 48600; FS = 1620; BR = 8000; break;
+                                default:
+                                    Log.w(TAG, "Unrecognized profile/level "
+                                            + profileLevel.profile + "/"
+                                            + profileLevel.level + " for " + mime);
+                                    errors |= ERROR_UNRECOGNIZED;
+                            }
+                            break;
+                        case CodecProfileLevel.MPEG4ProfileMain:             // 2-4
+                        case CodecProfileLevel.MPEG4ProfileNbit:             // 2
+                        case CodecProfileLevel.MPEG4ProfileAdvancedRealTime: // 1-4
+                        case CodecProfileLevel.MPEG4ProfileCoreScalable:     // 1-3
+                        case CodecProfileLevel.MPEG4ProfileAdvancedCoding:   // 1-4
+                        case CodecProfileLevel.MPEG4ProfileCore:             // 1-2
+                        case CodecProfileLevel.MPEG4ProfileAdvancedCore:     // 1-4
+                        case CodecProfileLevel.MPEG4ProfileSimpleScalable:   // 0-2
+                        case CodecProfileLevel.MPEG4ProfileAdvancedScalable: // 1-3
+                        case CodecProfileLevel.MPEG4ProfileHybrid:           // 1-2
+                        case CodecProfileLevel.MPEG4ProfileBasicAnimated:    // 1-2
+                        case CodecProfileLevel.MPEG4ProfileScalableTexture:  // 1
+                        case CodecProfileLevel.MPEG4ProfileSimpleFace:       // 1-2
+                        case CodecProfileLevel.MPEG4ProfileSimpleFBA:        // 1-2
+                            Log.i(TAG, "Unsupported profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNSUPPORTED;
+                            supported = false;
+                            break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    if (supported) {
+                        errors &= ~ERROR_NONE_SUPPORTED;
+                    }
+                    maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
+                    maxBlocks = Math.max(FS, maxBlocks);
+                    maxBps = Math.max(BR * 1000, maxBps);
+                    maxWidth = Math.max(W, maxWidth);
+                    maxHeight = Math.max(H, maxHeight);
+                    maxRate = Math.max(FR, maxRate);
+                }
+                applyMacroBlockLimits(maxWidth, maxHeight,
+                        maxBlocks, maxBlocksPerSecond,
+                        16 /* blockWidth */, 16 /* blockHeight */,
+                        1 /* widthAlignment */, 1 /* heightAlignment */);
+                mFrameRateRange = mFrameRateRange.intersect(12, maxRate);
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_H263)) {
+                int maxWidth = 11, maxHeight = 9, maxRate = 15;
+                maxBlocks = 99;
+                maxBlocksPerSecond = 1485;
+                maxBps = 64000;
+                for (CodecProfileLevel profileLevel: profileLevels) {
+                    int MBPS = 0, BR = 0, FR = 0, W = 0, H = 0;
+                    switch (profileLevel.level) {
+                        case CodecProfileLevel.H263Level10:
+                            FR = 15; W = 11; H =  9; BR =   1; MBPS =  W * H * FR; break;
+                        case CodecProfileLevel.H263Level20:
+                            // only supports CIF, 0..QCIF
+                            FR = 30; W = 22; H = 18; BR =   2; MBPS =  W * H * FR; break;
+                        case CodecProfileLevel.H263Level30:
+                            // only supports CIF, 0..QCIF
+                            FR = 30; W = 22; H = 18; BR =   6; MBPS =  W * H * FR; break;
+                        case CodecProfileLevel.H263Level40:
+                            // only supports CIF, 0..QCIF
+                            FR = 30; W = 22; H = 18; BR =  32; MBPS =  W * H * FR; break;
+                        case CodecProfileLevel.H263Level45:
+                            // only implies level 10 support
+                            FR = 30; W = 11; H =  9; BR =   2; MBPS =  W * H * FR; break;
+                        case CodecProfileLevel.H263Level50:
+                            // only supports 50fps for H > 15
+                            FR = 60; W = 22; H = 18; BR =  64; MBPS =  W * H * 50; break;
+                        case CodecProfileLevel.H263Level60:
+                            // only supports 50fps for H > 15
+                            FR = 60; W = 45; H = 18; BR = 128; MBPS =  W * H * 50; break;
+                        case CodecProfileLevel.H263Level70:
+                            // only supports 50fps for H > 30
+                            FR = 60; W = 45; H = 36; BR = 256; MBPS =  W * H * 50; break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile/level " + profileLevel.profile
+                                    + "/" + profileLevel.level + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    switch (profileLevel.profile) {
+                        case CodecProfileLevel.H263ProfileBackwardCompatible:
+                        case CodecProfileLevel.H263ProfileBaseline:
+                        case CodecProfileLevel.H263ProfileH320Coding:
+                        case CodecProfileLevel.H263ProfileHighCompression:
+                        case CodecProfileLevel.H263ProfileHighLatency:
+                        case CodecProfileLevel.H263ProfileInterlace:
+                        case CodecProfileLevel.H263ProfileInternet:
+                        case CodecProfileLevel.H263ProfileISWV2:
+                        case CodecProfileLevel.H263ProfileISWV3:
+                            break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    errors &= ~ERROR_NONE_SUPPORTED;
+                    maxBlocksPerSecond = Math.max(MBPS, maxBlocksPerSecond);
+                    maxBlocks = Math.max(W * H, maxBlocks);
+                    maxBps = Math.max(BR * 64000, maxBps);
+                    maxWidth = Math.max(W, maxWidth);
+                    maxHeight = Math.max(H, maxHeight);
+                    maxRate = Math.max(FR, maxRate);
+                }
+                applyMacroBlockLimits(maxWidth, maxHeight,
+                        maxBlocks, maxBlocksPerSecond,
+                        16 /* blockWidth */, 16 /* blockHeight */,
+                        1 /* widthAlignment */, 1 /* heightAlignment */);
+                mFrameRateRange = Range.create(1, maxRate);
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP8) ||
+                    mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP9)) {
+                maxBlocks = maxBlocksPerSecond = Integer.MAX_VALUE;
+
+                // TODO: set to 100Mbps for now, need a number for VPX
+                maxBps = 100000000;
+
+                // profile levels are not indicative for VPx, but verify
+                // them nonetheless
+                for (CodecProfileLevel profileLevel: profileLevels) {
+                    switch (profileLevel.level) {
+                        case CodecProfileLevel.VP8Level_Version0:
+                        case CodecProfileLevel.VP8Level_Version1:
+                        case CodecProfileLevel.VP8Level_Version2:
+                        case CodecProfileLevel.VP8Level_Version3:
+                            break;
+                        default:
+                            Log.w(TAG, "Unrecognized level "
+                                    + profileLevel.level + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    switch (profileLevel.profile) {
+                        case CodecProfileLevel.VP8ProfileMain:
+                            break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    errors &= ~ERROR_NONE_SUPPORTED;
+                }
+
+                final int blockSize =
+                    mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_VP8) ? 16 : 8;
+                applyMacroBlockLimits(Short.MAX_VALUE, Short.MAX_VALUE,
+                        maxBlocks, maxBlocksPerSecond, blockSize, blockSize,
+                        1 /* widthAlignment */, 1 /* heightAlignment */);
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_VIDEO_HEVC)) {
+                maxBlocks = 36864;
+                maxBlocksPerSecond = maxBlocks * 15;
+                maxBps = 128000;
+                for (CodecProfileLevel profileLevel: profileLevels) {
+                    double FR = 0;
+                    int FS = 0;
+                    int BR = 0;
+                    switch (profileLevel.level) {
+                        case CodecProfileLevel.HEVCMainTierLevel1:
+                        case CodecProfileLevel.HEVCHighTierLevel1:
+                            FR =    15; FS =    36864; BR =    128; break;
+                        case CodecProfileLevel.HEVCMainTierLevel2:
+                        case CodecProfileLevel.HEVCHighTierLevel2:
+                            FR =    30; FS =   122880; BR =   1500; break;
+                        case CodecProfileLevel.HEVCMainTierLevel21:
+                        case CodecProfileLevel.HEVCHighTierLevel21:
+                            FR =    30; FS =   245760; BR =   3000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel3:
+                        case CodecProfileLevel.HEVCHighTierLevel3:
+                            FR =    30; FS =   552960; BR =   6000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel31:
+                        case CodecProfileLevel.HEVCHighTierLevel31:
+                            FR = 33.75; FS =   983040; BR =  10000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel4:
+                            FR =    30; FS =  2228224; BR =  12000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel4:
+                            FR =    30; FS =  2228224; BR =  30000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel41:
+                            FR =    60; FS =  2228224; BR =  20000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel41:
+                            FR =    60; FS =  2228224; BR =  50000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel5:
+                            FR =    30; FS =  8912896; BR =  25000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel5:
+                            FR =    30; FS =  8912896; BR = 100000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel51:
+                            FR =    60; FS =  8912896; BR =  40000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel51:
+                            FR =    60; FS =  8912896; BR = 160000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel52:
+                            FR =   120; FS =  8912896; BR =  60000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel52:
+                            FR =   120; FS =  8912896; BR = 240000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel6:
+                            FR =    30; FS = 35651584; BR =  60000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel6:
+                            FR =    30; FS = 35651584; BR = 240000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel61:
+                            FR =    60; FS = 35651584; BR = 120000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel61:
+                            FR =    60; FS = 35651584; BR = 480000; break;
+                        case CodecProfileLevel.HEVCMainTierLevel62:
+                            FR =   120; FS = 35651584; BR = 240000; break;
+                        case CodecProfileLevel.HEVCHighTierLevel62:
+                            FR =   120; FS = 35651584; BR = 800000; break;
+                        default:
+                            Log.w(TAG, "Unrecognized level "
+                                    + profileLevel.level + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+                    switch (profileLevel.profile) {
+                        case CodecProfileLevel.HEVCProfileMain:
+                        case CodecProfileLevel.HEVCProfileMain10:
+                            break;
+                        default:
+                            Log.w(TAG, "Unrecognized profile "
+                                    + profileLevel.profile + " for " + mime);
+                            errors |= ERROR_UNRECOGNIZED;
+                    }
+
+                    /* DPB logic:
+                    if      (width * height <= FS / 4)    DPB = 16;
+                    else if (width * height <= FS / 2)    DPB = 12;
+                    else if (width * height <= FS * 0.75) DPB = 8;
+                    else                                  DPB = 6;
+                    */
+
+                    errors &= ~ERROR_NONE_SUPPORTED;
+                    maxBlocksPerSecond = Math.max((int)(FR * FS), maxBlocksPerSecond);
+                    maxBlocks = Math.max(FS, maxBlocks);
+                    maxBps = Math.max(BR * 1000, maxBps);
+                }
+
+                int maxLengthInBlocks = (int)(Math.sqrt(maxBlocks * 8));
+                // CTBs are at least 8x8
+                maxBlocks = Utils.divUp(maxBlocks, 8 * 8);
+                maxBlocksPerSecond = Utils.divUp(maxBlocksPerSecond, 8 * 8);
+                maxLengthInBlocks = Utils.divUp(maxLengthInBlocks, 8);
+
+                applyMacroBlockLimits(
+                        maxLengthInBlocks, maxLengthInBlocks,
+                        maxBlocks, maxBlocksPerSecond,
+                        8 /* blockWidth */, 8 /* blockHeight */,
+                        1 /* widthAlignment */, 1 /* heightAlignment */);
+            } else {
+                Log.w(TAG, "Unsupported mime " + mime);
+                // using minimal bitrate here.  should be overriden by
+                // info from media_codecs.xml
+                maxBps = 64000;
+                errors |= ERROR_UNSUPPORTED;
+            }
+            mBitrateRange = Range.create(1, maxBps);
+            mParent.mError |= errors;
+        }
+    }
+
+    /**
+     * A class that supports querying the encoding capabilities of a codec.
+     */
+    public static final class EncoderCapabilities {
+        /**
+         * Returns the supported range of quality values.
+         *
+         * @hide
+         */
+        public Range<Integer> getQualityRange() {
+            return mQualityRange;
+        }
+
+        /**
+         * Returns the supported range of encoder complexity values.
+         * <p>
+         * Some codecs may support multiple complexity levels, where higher
+         * complexity values use more encoder tools (e.g. perform more
+         * intensive calculations) to improve the quality or the compression
+         * ratio.  Use a lower value to save power and/or time.
+         */
+        public Range<Integer> getComplexityRange() {
+            return mComplexityRange;
+        }
+
+        /** Constant quality mode */
+        public static final int BITRATE_MODE_CQ = 0;
+        /** Variable bitrate mode */
+        public static final int BITRATE_MODE_VBR = 1;
+        /** Constant bitrate mode */
+        public static final int BITRATE_MODE_CBR = 2;
+
+        private static final Feature[] bitrates = new Feature[] {
+            new Feature("VBR", BITRATE_MODE_VBR, true),
+            new Feature("CBR", BITRATE_MODE_CBR, false),
+            new Feature("CQ",  BITRATE_MODE_CQ,  false)
+        };
+
+        private static int parseBitrateMode(String mode) {
+            for (Feature feat: bitrates) {
+                if (feat.mName.equalsIgnoreCase(mode)) {
+                    return feat.mValue;
+                }
+            }
+            return 0;
+        }
+
+        /**
+         * Query whether a bitrate mode is supported.
+         */
+        public boolean isBitrateModeSupported(int mode) {
+            for (Feature feat: bitrates) {
+                if (mode == feat.mValue) {
+                    return (mBitControl & (1 << mode)) != 0;
+                }
+            }
+            return false;
+        }
+
+        private Range<Integer> mQualityRange;
+        private Range<Integer> mComplexityRange;
+        private CodecCapabilities mParent;
+
+        /* no public constructor */
+        private EncoderCapabilities() { }
+
+        /** @hide */
+        public static EncoderCapabilities create(
+                MediaFormat info, CodecCapabilities parent) {
+            EncoderCapabilities caps = new EncoderCapabilities();
+            caps.init(info, parent);
+            return caps;
+        }
+
+        /** @hide */
+        public void init(MediaFormat info, CodecCapabilities parent) {
+            // no support for complexity or quality yet
+            mParent = parent;
+            mComplexityRange = Range.create(0, 0);
+            mQualityRange = Range.create(0, 0);
+            mBitControl = (1 << BITRATE_MODE_VBR);
+
+            applyLevelLimits();
+            parseFromInfo(info);
+        }
+
+        private void applyLevelLimits() {
+            String mime = mParent.getMimeType();
+            if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_FLAC)) {
+                mComplexityRange = Range.create(0, 8);
+                mBitControl = (1 << BITRATE_MODE_CQ);
+            } else if (mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_NB)
+                    || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_AMR_WB)
+                    || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_ALAW)
+                    || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_G711_MLAW)
+                    || mime.equalsIgnoreCase(MediaFormat.MIMETYPE_AUDIO_MSGSM)) {
+                mBitControl = (1 << BITRATE_MODE_CBR);
+            }
+        }
+
+        private int mBitControl;
+        private Integer mDefaultComplexity;
+        private Integer mDefaultQuality;
+        private String mQualityScale;
+
+        private void parseFromInfo(MediaFormat info) {
+            Map<String, Object> map = info.getMap();
+
+            if (info.containsKey("complexity-range")) {
+                mComplexityRange = Utils
+                        .parseIntRange(info.getString("complexity-range"), mComplexityRange);
+                // TODO should we limit this to level limits?
+            }
+            if (info.containsKey("quality-range")) {
+                mQualityRange = Utils
+                        .parseIntRange(info.getString("quality-range"), mQualityRange);
+            }
+            if (info.containsKey("feature-bitrate-control")) {
+                for (String mode: info.getString("feature-bitrate-control").split(",")) {
+                    mBitControl |= parseBitrateMode(mode);
+                }
+            }
+
+            try {
+                mDefaultComplexity = Integer.parseInt((String)map.get("complexity-default"));
+            } catch (NumberFormatException e) { }
+
+            try {
+                mDefaultQuality = Integer.parseInt((String)map.get("quality-default"));
+            } catch (NumberFormatException e) { }
+
+            mQualityScale = (String)map.get("quality-scale");
+        }
+
+        private boolean supports(
+                Integer complexity, Integer quality, Integer profile) {
+            boolean ok = true;
+            if (ok && complexity != null) {
+                ok = mComplexityRange.contains(complexity);
+            }
+            if (ok && quality != null) {
+                ok = mQualityRange.contains(quality);
+            }
+            if (ok && profile != null) {
+                for (CodecProfileLevel pl: mParent.profileLevels) {
+                    if (pl.profile == profile) {
+                        profile = null;
+                        break;
+                    }
+                }
+                ok = profile == null;
+            }
+            return ok;
+        }
+
+        /** @hide */
+        public void setDefaultFormat(MediaFormat format) {
+            // don't list trivial quality/complexity as default for now
+            if (!mQualityRange.getUpper().equals(mQualityRange.getLower())
+                    && mDefaultQuality != null) {
+                format.setInteger(MediaFormat.KEY_QUALITY, mDefaultQuality);
+            }
+            if (!mComplexityRange.getUpper().equals(mComplexityRange.getLower())
+                    && mDefaultComplexity != null) {
+                format.setInteger(MediaFormat.KEY_COMPLEXITY, mDefaultComplexity);
+            }
+            // bitrates are listed in order of preference
+            for (Feature feat: bitrates) {
+                if ((mBitControl & (1 << feat.mValue)) != 0) {
+                    format.setInteger(MediaFormat.KEY_BITRATE_MODE, feat.mValue);
+                    break;
+                }
+            }
+        }
+
+        /** @hide */
+        public boolean supportsFormat(MediaFormat format) {
+            final Map<String, Object> map = format.getMap();
+            final String mime = mParent.getMimeType();
+
+            Integer mode = (Integer)map.get(MediaFormat.KEY_BITRATE_MODE);
+            if (mode != null && !isBitrateModeSupported(mode)) {
+                return false;
+            }
+
+            Integer complexity = (Integer)map.get(MediaFormat.KEY_COMPLEXITY);
+            if (MediaFormat.MIMETYPE_AUDIO_FLAC.equalsIgnoreCase(mime)) {
+                Integer flacComplexity =
+                    (Integer)map.get(MediaFormat.KEY_FLAC_COMPRESSION_LEVEL);
+                if (complexity == null) {
+                    complexity = flacComplexity;
+                } else if (flacComplexity != null && complexity != flacComplexity) {
+                    throw new IllegalArgumentException(
+                            "conflicting values for complexity and " +
+                            "flac-compression-level");
+                }
+            }
+
+            // other audio parameters
+            Integer profile = (Integer)map.get(MediaFormat.KEY_PROFILE);
+            if (MediaFormat.MIMETYPE_AUDIO_AAC.equalsIgnoreCase(mime)) {
+                Integer aacProfile = (Integer)map.get(MediaFormat.KEY_AAC_PROFILE);
+                if (profile == null) {
+                    profile = aacProfile;
+                } else if (aacProfile != null && aacProfile != profile) {
+                    throw new IllegalArgumentException(
+                            "conflicting values for profile and aac-profile");
+                }
+            }
+
+            Integer quality = (Integer)map.get(MediaFormat.KEY_QUALITY);
+
+            return supports(complexity, quality, profile);
         }
     };
 
diff --git a/media/java/android/media/MediaCodecList.java b/media/java/android/media/MediaCodecList.java
index d74f22d..0dcbd65 100644
--- a/media/java/android/media/MediaCodecList.java
+++ b/media/java/android/media/MediaCodecList.java
@@ -36,6 +36,8 @@
     /**
      * Count the number of available (regular) codecs.
      *
+     * @deprecated Use {@link #getCodecInfos} instead.
+     *
      * @see #REGULAR_CODECS
      */
     public static final int getCodecCount() {
@@ -49,6 +51,8 @@
      * Return the {@link MediaCodecInfo} object for the codec at
      * the given {@code index} in the regular list.
      *
+     * @deprecated Use {@link #getCodecInfos} instead.
+     *
      * @see #REGULAR_CODECS
      */
     public static final MediaCodecInfo getCodecInfoAt(int index) {
@@ -112,17 +116,32 @@
 
     /* package private */ static native final int findCodecByName(String codec);
 
+    /** @hide */
+    public static MediaCodecInfo getInfoFor(String codec) {
+        initCodecList();
+        return sAllCodecInfos[findCodecByName(codec)];
+    }
+
     private static native final void native_init();
 
     /**
      * Use in {@link #MediaCodecList} to enumerate only codecs that are suitable
-     * for normal playback and recording.
+     * for regular (buffer-to-buffer) decoding or encoding.
+     *
+     * <em>NOTE:</em> These are the codecs that are returned prior to API 21,
+     * using the now deprecated static methods.
      */
     public static final int REGULAR_CODECS = 0;
 
     /**
      * Use in {@link #MediaCodecList} to enumerate all codecs, even ones that are
-     * not suitable for normal playback or recording.
+     * not suitable for regular (buffer-to-buffer) decoding or encoding.  These
+     * include codecs, for example, that only work with special input or output
+     * surfaces, such as secure-only or tunneled-only codecs.
+     *
+     * @see MediaCodecInfo.CodecCapabilities#isFormatSupported
+     * @see MediaCodecInfo.CodecCapabilities#FEATURE_SecurePlayback
+     * @see MediaCodecInfo.CodecCapabilities#FEATURE_TunneledPlayback
      */
     public static final int ALL_CODECS = 1;
 
diff --git a/media/java/android/media/MediaDescription.aidl b/media/java/android/media/MediaDescription.aidl
new file mode 100644
index 0000000..6f934f7
--- /dev/null
+++ b/media/java/android/media/MediaDescription.aidl
@@ -0,0 +1,18 @@
+/* Copyright 2014, 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 android.media;
+
+parcelable MediaDescription;
diff --git a/media/java/android/media/MediaDescription.java b/media/java/android/media/MediaDescription.java
new file mode 100644
index 0000000..4399c0d
--- /dev/null
+++ b/media/java/android/media/MediaDescription.java
@@ -0,0 +1,276 @@
+package android.media;
+
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.content.ContentResolver;
+import android.content.res.Resources;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.Paint;
+import android.graphics.Point;
+import android.graphics.RectF;
+import android.graphics.drawable.BitmapDrawable;
+import android.graphics.drawable.Drawable;
+import android.net.Uri;
+import android.os.Bundle;
+import android.os.CancellationSignal;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.util.Size;
+
+/**
+ * A simple set of metadata for a media item suitable for display. This can be
+ * created using the Builder or retrieved from existing metadata using
+ * {@link MediaMetadata#getDescription()}.
+ */
+public class MediaDescription implements Parcelable {
+    /**
+     * A unique persistent id for the content or null.
+     */
+    private final String mMediaId;
+    /**
+     * A primary title suitable for display or null.
+     */
+    private final CharSequence mTitle;
+    /**
+     * A subtitle suitable for display or null.
+     */
+    private final CharSequence mSubtitle;
+    /**
+     * A description suitable for display or null.
+     */
+    private final CharSequence mDescription;
+    /**
+     * A bitmap icon suitable for display or null.
+     */
+    private final Bitmap mIcon;
+    /**
+     * A Uri for an icon suitable for display or null.
+     */
+    private final Uri mIconUri;
+    /**
+     * Extras for opaque use by apps/system.
+     */
+    private final Bundle mExtras;
+
+    private MediaDescription(String mediaId, CharSequence title, CharSequence subtitle,
+            CharSequence description, Bitmap icon, Uri iconUri, Bundle extras) {
+        mMediaId = mediaId;
+        mTitle = title;
+        mSubtitle = subtitle;
+        mDescription = description;
+        mIcon = icon;
+        mIconUri = iconUri;
+        mExtras = extras;
+    }
+
+    private MediaDescription(Parcel in) {
+        mMediaId = in.readString();
+        mTitle = in.readCharSequence();
+        mSubtitle = in.readCharSequence();
+        mDescription = in.readCharSequence();
+        mIcon = in.readParcelable(null);
+        mIconUri = in.readParcelable(null);
+        mExtras = in.readBundle();
+    }
+
+    /**
+     * Returns the media id or null. See
+     * {@link MediaMetadata#METADATA_KEY_MEDIA_ID}.
+     */
+    public @Nullable String getMediaId() {
+        return mMediaId;
+    }
+
+    /**
+     * Returns a title suitable for display or null.
+     *
+     * @return A title or null.
+     */
+    public @Nullable CharSequence getTitle() {
+        return mTitle;
+    }
+
+    /**
+     * Returns a subtitle suitable for display or null.
+     *
+     * @return A subtitle or null.
+     */
+    public @Nullable CharSequence getSubtitle() {
+        return mSubtitle;
+    }
+
+    /**
+     * Returns a description suitable for display or null.
+     *
+     * @return A description or null.
+     */
+    public @Nullable CharSequence getDescription() {
+        return mDescription;
+    }
+
+    /**
+     * Returns a bitmap icon suitable for display or null.
+     *
+     * @return An icon or null.
+     */
+    public @Nullable Bitmap getIconBitmap() {
+        return mIcon;
+    }
+
+    /**
+     * Returns a Uri for an icon suitable for display or null.
+     *
+     * @return An icon uri or null.
+     */
+    public @Nullable Uri getIconUri() {
+        return mIconUri;
+    }
+
+    /**
+     * Returns any extras that were added to the description.
+     *
+     * @return A bundle of extras or null.
+     */
+    public @Nullable Bundle getExtras() {
+        return mExtras;
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel dest, int flags) {
+        dest.writeString(mMediaId);
+        dest.writeCharSequence(mTitle);
+        dest.writeCharSequence(mSubtitle);
+        dest.writeCharSequence(mDescription);
+        dest.writeParcelable(mIcon, flags);
+        dest.writeParcelable(mIconUri, flags);
+        dest.writeBundle(mExtras);
+    }
+
+    @Override
+    public String toString() {
+        return mTitle + ", " + mSubtitle + ", " + mDescription;
+    }
+
+    public static final Parcelable.Creator<MediaDescription> CREATOR =
+            new Parcelable.Creator<MediaDescription>() {
+                @Override
+                public MediaDescription createFromParcel(Parcel in) {
+                    return new MediaDescription(in);
+                }
+
+                @Override
+                public MediaDescription[] newArray(int size) {
+                    return new MediaDescription[size];
+                }
+            };
+
+    /**
+     * Builder for {@link MediaDescription} objects.
+     */
+    public static class Builder {
+        private String mMediaId;
+        private CharSequence mTitle;
+        private CharSequence mSubtitle;
+        private CharSequence mDescription;
+        private Bitmap mIcon;
+        private Uri mIconUri;
+        private Bundle mExtras;
+
+        /**
+         * Creates an initially empty builder.
+         */
+        public Builder() {
+        }
+
+        /**
+         * Sets the media id.
+         *
+         * @param mediaId The unique id for the item or null.
+         * @return this
+         */
+        public Builder setMediaId(@Nullable String mediaId) {
+            mMediaId = mediaId;
+            return this;
+        }
+
+        /**
+         * Sets the title.
+         *
+         * @param title A title suitable for display to the user or null.
+         * @return this
+         */
+        public Builder setTitle(@Nullable CharSequence title) {
+            mTitle = title;
+            return this;
+        }
+
+        /**
+         * Sets the subtitle.
+         *
+         * @param subtitle A subtitle suitable for display to the user or null.
+         * @return this
+         */
+        public Builder setSubtitle(@Nullable CharSequence subtitle) {
+            mSubtitle = subtitle;
+            return this;
+        }
+
+        /**
+         * Sets the description.
+         *
+         * @param description A description suitable for display to the user or
+         *            null.
+         * @return this
+         */
+        public Builder setDescription(@Nullable CharSequence description) {
+            mDescription = description;
+            return this;
+        }
+
+        /**
+         * Sets the icon.
+         *
+         * @param icon A {@link Bitmap} icon suitable for display to the user or
+         *            null.
+         * @return this
+         */
+        public Builder setIconBitmap(@Nullable Bitmap icon) {
+            mIcon = icon;
+            return this;
+        }
+
+        /**
+         * Sets the icon uri.
+         *
+         * @param iconUri A {@link Uri} for an icon suitable for display to the
+         *            user or null.
+         * @return this
+         */
+        public Builder setIconUri(@Nullable Uri iconUri) {
+            mIconUri = iconUri;
+            return this;
+        }
+
+        /**
+         * Sets a bundle of extras.
+         *
+         * @param extras The extras to include with this description or null.
+         * @return this
+         */
+        public Builder setExtras(@Nullable Bundle extras) {
+            mExtras = extras;
+            return this;
+        }
+
+        public MediaDescription build() {
+            return new MediaDescription(mMediaId, mTitle, mSubtitle, mDescription, mIcon, mIconUri,
+                    mExtras);
+        }
+    }
+}
diff --git a/media/java/android/media/MediaDrm.java b/media/java/android/media/MediaDrm.java
index ca707d8..1490732 100644
--- a/media/java/android/media/MediaDrm.java
+++ b/media/java/android/media/MediaDrm.java
@@ -188,18 +188,37 @@
      */
     public static final class MediaDrmStateException extends java.lang.IllegalStateException {
         private final int mErrorCode;
+        private final String mDiagnosticInfo;
 
         public MediaDrmStateException(int errorCode, String detailMessage) {
             super(detailMessage);
             mErrorCode = errorCode;
+
+            // TODO get this from DRM session
+            final String sign = errorCode < 0 ? "neg_" : "";
+            mDiagnosticInfo =
+                "android.media.MediaDrm.error_" + sign + Math.abs(errorCode);
+
         }
 
         /**
          * Retrieve the associated error code
+         *
+         * @hide
          */
         public int getErrorCode() {
             return mErrorCode;
         }
+
+        /**
+         * Retrieve a human readable diagnostic information string
+         * associated with the exception. DO NOT SHOW THIS TO END-USERS!
+         * This string will not be localized or generally comprehensible
+         * to end-users.
+         */
+        public String getDiagnosticInfo() {
+            return mDiagnosticInfo;
+        }
     }
 
     /**
diff --git a/media/java/android/media/MediaFormat.java b/media/java/android/media/MediaFormat.java
index fd79495..2036533 100644
--- a/media/java/android/media/MediaFormat.java
+++ b/media/java/android/media/MediaFormat.java
@@ -120,19 +120,6 @@
     private Map<String, Object> mMap;
 
     /**
-     * A key prefix used together with a {@link MediaCodecInfo.CodecCapabilities}
-     * feature name describing a required or optional feature for a codec capabilities
-     * query.
-     * The associated value is an integer, where non-0 value means the feature is
-     * requested to be present, while 0 value means the feature is requested to be not
-     * present.
-     * @see MediaCodecList#findDecoderForFormat
-     * @see MediaCodecList#findEncoderForFormat
-     * @see MediaCodecInfo.CodecCapabilities#isFormatSupported
-     */
-    public static final String KEY_FEATURE_ = "feature-";
-
-    /**
      * A key describing the mime type of the MediaFormat.
      * The associated value is a string.
      */
@@ -422,6 +409,8 @@
      * codec specific, but lower values generally result in more efficient
      * (smaller-sized) encoding.
      *
+     * @hide
+     *
      * @see MediaCodecInfo.CodecCapabilities.EncoderCapabilities#getQualityRange
      */
     public static final String KEY_QUALITY = "quality";
@@ -510,6 +499,21 @@
     }
 
     /**
+     * A key prefix used together with a {@link MediaCodecInfo.CodecCapabilities}
+     * feature name describing a required or optional feature for a codec capabilities
+     * query.
+     * The associated value is an integer, where non-0 value means the feature is
+     * requested to be present, while 0 value means the feature is requested to be not
+     * present.
+     * @see MediaCodecList#findDecoderForFormat
+     * @see MediaCodecList#findEncoderForFormat
+     * @see MediaCodecInfo.CodecCapabilities#isFormatSupported
+     *
+     * @hide
+     */
+    public static final String KEY_FEATURE_ = "feature-";
+
+    /**
      * Returns the value of an integer key.
      */
     public final int getInteger(String name) {
@@ -559,6 +563,23 @@
     }
 
     /**
+     * Returns whether a feature is to be enabled ({@code true}) or disabled
+     * ({@code false}).
+     *
+     * @param feature the name of a {@link MediaCodecInfo.CodecCapabilities} feature.
+     *
+     * @throws IllegalArgumentException if the feature was neither set to be enabled
+     *        nor to be disabled.
+     */
+    public boolean getFeatureEnabled(String feature) {
+        Integer enabled = (Integer)mMap.get(KEY_FEATURE_ + feature);
+        if (enabled == null) {
+            throw new IllegalArgumentException("feature is not specified");
+        }
+        return enabled != 0;
+    }
+
+    /**
      * Sets the value of an integer key.
      */
     public final void setInteger(String name, int value) {
@@ -594,6 +615,23 @@
     }
 
     /**
+     * Sets whether a feature is to be enabled ({@code true}) or disabled
+     * ({@code false}).
+     *
+     * If {@code enabled} is {@code true}, the feature is requested to be present.
+     * Otherwise, the feature is requested to be not present.
+     *
+     * @param feature the name of a {@link MediaCodecInfo.CodecCapabilities} feature.
+     *
+     * @see MediaCodecList#findDecoderForFormat
+     * @see MediaCodecList#findEncoderForFormat
+     * @see MediaCodecInfo.CodecCapabilities#isFormatSupported
+     */
+    public void setFeatureEnabled(String feature, boolean enabled) {
+        setInteger(KEY_FEATURE_ + feature, enabled ? 1 : 0);
+    }
+
+    /**
      * Creates a minimal audio format.
      * @param mime The mime type of the content.
      * @param sampleRate The sampling rate of the content.
diff --git a/media/java/android/media/MediaHTTPConnection.java b/media/java/android/media/MediaHTTPConnection.java
index d3b1520..05acf90 100644
--- a/media/java/android/media/MediaHTTPConnection.java
+++ b/media/java/android/media/MediaHTTPConnection.java
@@ -47,6 +47,7 @@
     private InputStream mInputStream = null;
 
     private boolean mAllowCrossDomainRedirect = true;
+    private boolean mAllowCrossProtocolRedirect = true;
 
     // from com.squareup.okhttp.internal.http
     private final static int HTTP_TEMP_REDIRECT = 307;
@@ -91,6 +92,8 @@
     private boolean filterOutInternalHeaders(String key, String val) {
         if ("android-allow-cross-domain-redirect".equalsIgnoreCase(key)) {
             mAllowCrossDomainRedirect = parseBoolean(val);
+            // cross-protocol redirects are also controlled by this flag
+            mAllowCrossProtocolRedirect = mAllowCrossDomainRedirect;
         } else {
             return false;
         }
@@ -190,8 +193,12 @@
                         !url.getProtocol().equals("http")) {
                     throw new NoRouteToHostException("Unsupported protocol redirect");
                 }
+                boolean sameProtocol = mURL.getProtocol().equals(url.getProtocol());
+                if (!mAllowCrossProtocolRedirect && !sameProtocol) {
+                    throw new NoRouteToHostException("Cross-protocol redirects are disallowed");
+                }
                 boolean sameHost = mURL.getHost().equals(url.getHost());
-                if (!sameHost) {
+                if (!mAllowCrossDomainRedirect && !sameHost) {
                     throw new NoRouteToHostException("Cross-domain redirects are disallowed");
                 }
 
diff --git a/media/java/android/media/MediaMetadata.java b/media/java/android/media/MediaMetadata.java
index 74f7a96..b4e6033 100644
--- a/media/java/android/media/MediaMetadata.java
+++ b/media/java/android/media/MediaMetadata.java
@@ -17,15 +17,22 @@
 
 import android.annotation.NonNull;
 import android.annotation.Nullable;
+import android.content.ContentProviderClient;
+import android.content.ContentResolver;
 import android.graphics.Bitmap;
+import android.graphics.BitmapFactory;
+import android.media.browse.MediaBrowser;
+import android.media.session.MediaController;
 import android.net.Uri;
 import android.os.Bundle;
+import android.os.CancellationSignal;
+import android.os.OperationCanceledException;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.text.TextUtils;
-import android.text.format.Time;
 import android.util.ArrayMap;
 import android.util.Log;
+import android.util.Size;
 import android.util.SparseArray;
 
 import java.util.Set;
@@ -119,7 +126,9 @@
     public static final String METADATA_KEY_ART = "android.media.metadata.ART";
 
     /**
-     * The artwork for the media as a Uri.
+     * The artwork for the media as a Uri formatted String. The artwork can be
+     * loaded using a combination of {@link ContentResolver#openInputStream} and
+     * {@link BitmapFactory#decodeStream}.
      */
     public static final String METADATA_KEY_ART_URI = "android.media.metadata.ART_URI";
 
@@ -130,7 +139,10 @@
     public static final String METADATA_KEY_ALBUM_ART = "android.media.metadata.ALBUM_ART";
 
     /**
-     * The artwork for the album of the media's original source as a Uri.
+     * The artwork for the album of the media's original source as a Uri
+     * formatted String. The artwork can be loaded using a combination of
+     * {@link ContentResolver#openInputStream} and
+     * {@link BitmapFactory#decodeStream}.
      */
     public static final String METADATA_KEY_ALBUM_ART_URI = "android.media.metadata.ALBUM_ART_URI";
 
@@ -181,13 +193,26 @@
             = "android.media.metadata.DISPLAY_ICON";
 
     /**
-     * An icon or thumbnail that is suitable for display to the user. When
-     * displaying more information for media described by this metadata the
-     * display description should be preferred to other fields when present.
+     * A Uri formatted String for an icon or thumbnail that is suitable for
+     * display to the user. When displaying more information for media described
+     * by this metadata the display description should be preferred to other
+     * fields when present. The icon can be loaded using a combination of
+     * {@link ContentResolver#openInputStream} and
+     * {@link BitmapFactory#decodeStream}.
      */
     public static final String METADATA_KEY_DISPLAY_ICON_URI
             = "android.media.metadata.DISPLAY_ICON_URI";
 
+    /**
+     * A String key for identifying the content. This value is specific to the
+     * service providing the content. If used, this should be a persistent
+     * unique key for the underlying content. It may be used with
+     * {@link MediaController.TransportControls#playFromMediaId(String, Bundle)}
+     * to initiate playback when provided by a {@link MediaBrowser} connected to
+     * the same app.
+     */
+    public static final String METADATA_KEY_MEDIA_ID = "android.media.metadata.MEDIA_ID";
+
     private static final String[] PREFERRED_DESCRIPTION_ORDER = {
             METADATA_KEY_TITLE,
             METADATA_KEY_ARTIST,
@@ -277,7 +302,7 @@
     }
 
     private final Bundle mBundle;
-    private Description mDescription;
+    private MediaDescription mDescription;
 
     private MediaMetadata(Bundle bundle) {
         mBundle = new Bundle(bundle);
@@ -406,11 +431,13 @@
      *
      * @return A simple description of this metadata.
      */
-    public @NonNull Description getDescription() {
+    public @NonNull MediaDescription getDescription() {
         if (mDescription != null) {
             return mDescription;
         }
 
+        String mediaId = getString(METADATA_KEY_MEDIA_ID);
+
         CharSequence[] text = new CharSequence[3];
         Bitmap icon = null;
         Uri iconUri = null;
@@ -454,7 +481,15 @@
             }
         }
 
-        mDescription = new Description(text[0], text[1], text[2], icon, iconUri);
+        MediaDescription.Builder bob = new MediaDescription.Builder();
+        bob.setMediaId(mediaId);
+        bob.setTitle(text[0]);
+        bob.setSubtitle(text[1]);
+        bob.setDescription(text[2]);
+        bob.setIconBitmap(icon);
+        bob.setIconUri(iconUri);
+        mDescription = bob.build();
+
         return mDescription;
     }
 
@@ -668,90 +703,4 @@
             return new MediaMetadata(mBundle);
         }
     }
-
-    /**
-     * A simple form of the metadata that can be used for display.
-     */
-    public final class Description {
-        /**
-         * A primary title suitable for display or null.
-         */
-        private final CharSequence mTitle;
-        /**
-         * A subtitle suitable for display or null.
-         */
-        private final CharSequence mSubtitle;
-        /**
-         * A description suitable for display or null.
-         */
-        private final CharSequence mDescription;
-        /**
-         * A bitmap icon suitable for display or null.
-         */
-        private final Bitmap mIcon;
-        /**
-         * A Uri for an icon suitable for display or null.
-         */
-        private final Uri mIconUri;
-
-        /**
-         * Returns the best available title or null.
-         *
-         * @return A title or null.
-         */
-        public @Nullable CharSequence getTitle() {
-            return mTitle;
-        }
-
-        /**
-         * Returns the best available subtitle or null.
-         *
-         * @return A subtitle or null.
-         */
-        public @Nullable CharSequence getSubtitle() {
-            return mSubtitle;
-        }
-
-        /**
-         * Returns the best available description or null.
-         *
-         * @return A description or null.
-         */
-        public @Nullable CharSequence getDescription() {
-            return mDescription;
-        }
-
-        /**
-         * Returns the best available icon or null.
-         *
-         * @return An icon or null.
-         */
-        public @Nullable Bitmap getIcon() {
-            return mIcon;
-        }
-
-        /**
-         * Returns the best available icon Uri or null.
-         *
-         * @return An icon uri or null.
-         */
-        public @Nullable Uri getIconUri() {
-            return mIconUri;
-        }
-
-        private Description(CharSequence title, CharSequence subtitle, CharSequence description,
-                Bitmap icon, Uri iconUri) {
-            mTitle = title;
-            mSubtitle = subtitle;
-            mDescription = description;
-            mIcon = icon;
-            mIconUri = iconUri;
-        }
-
-        @Override
-        public String toString() {
-            return mTitle + ", " + mSubtitle + ", " + mDescription;
-        }
-    }
-
 }
diff --git a/media/java/android/media/MediaPlayer.java b/media/java/android/media/MediaPlayer.java
index 2fa0c93..afa0b6e 100644
--- a/media/java/android/media/MediaPlayer.java
+++ b/media/java/android/media/MediaPlayer.java
@@ -961,6 +961,10 @@
      * @param context the Context to use when resolving the Uri
      * @param uri the Content URI of the data you want to play
      * @param headers the headers to be sent together with the request for the data
+     *                Note that the cross domain redirection is allowed by default, but that can be
+     *                changed with key/value pairs through the headers parameter with
+     *                "android-allow-cross-domain-redirect" as the key and "0" or "1" as the value
+     *                to disallow or allow cross domain redirection.
      * @throws IllegalStateException if it is called in an invalid state
      */
     public void setDataSource(Context context, Uri uri, Map<String, String> headers)
@@ -1049,8 +1053,17 @@
     private void setDataSource(String path, String[] keys, String[] values)
             throws IOException, IllegalArgumentException, SecurityException, IllegalStateException {
         final Uri uri = Uri.parse(path);
-        if ("file".equals(uri.getScheme())) {
+        final String scheme = uri.getScheme();
+        if ("file".equals(scheme)) {
             path = uri.getPath();
+        } else if (scheme != null) {
+            // handle non-file sources
+            nativeSetDataSource(
+                MediaHTTPService.createHttpServiceBinderIfNecessary(path),
+                path,
+                keys,
+                values);
+            return;
         }
 
         final File file = new File(path);
@@ -1060,20 +1073,10 @@
             setDataSource(fd);
             is.close();
         } else {
-            _setDataSource(path, keys, values);
+            throw new IOException("setDataSource failed.");
         }
     }
 
-    private void _setDataSource(
-        String path, String[] keys, String[] values)
-        throws IOException, IllegalArgumentException, SecurityException, IllegalStateException {
-        nativeSetDataSource(
-                MediaHTTPService.createHttpServiceBinderIfNecessary(path),
-                path,
-                keys,
-                values);
-    }
-
     private native void nativeSetDataSource(
         IBinder httpServiceBinder, String path, String[] keys, String[] values)
         throws IOException, IllegalArgumentException, SecurityException, IllegalStateException;
@@ -1926,6 +1929,7 @@
         mSubtitleController.setAnchor(anchor);
     }
 
+    private final Object mInbandSubtitleLock = new Object();
     private SubtitleTrack[] mInbandSubtitleTracks;
     private int mSelectedSubtitleTrackIndex = -1;
     private Vector<SubtitleTrack> mOutOfBandSubtitleTracks;
@@ -2033,19 +2037,21 @@
         }
 
         TrackInfo[] tracks = getInbandTrackInfo();
-        SubtitleTrack[] inbandTracks = new SubtitleTrack[tracks.length];
-        for (int i=0; i < tracks.length; i++) {
-            if (tracks[i].getTrackType() == TrackInfo.MEDIA_TRACK_TYPE_SUBTITLE) {
-                if (i < mInbandSubtitleTracks.length) {
-                    inbandTracks[i] = mInbandSubtitleTracks[i];
-                } else {
-                    SubtitleTrack track = mSubtitleController.addTrack(
-                            tracks[i].getFormat());
-                    inbandTracks[i] = track;
+        synchronized (mInbandSubtitleLock) {
+            SubtitleTrack[] inbandTracks = new SubtitleTrack[tracks.length];
+            for (int i=0; i < tracks.length; i++) {
+                if (tracks[i].getTrackType() == TrackInfo.MEDIA_TRACK_TYPE_SUBTITLE) {
+                    if (i < mInbandSubtitleTracks.length) {
+                        inbandTracks[i] = mInbandSubtitleTracks[i];
+                    } else {
+                        SubtitleTrack track = mSubtitleController.addTrack(
+                                tracks[i].getFormat());
+                        inbandTracks[i] = track;
+                    }
                 }
             }
+            mInbandSubtitleTracks = inbandTracks;
         }
-        mInbandSubtitleTracks = inbandTracks;
         mSubtitleController.selectDefaultTrack();
     }
 
@@ -2221,9 +2227,9 @@
                 try {
                     Libcore.os.lseek(fd3, offset2, OsConstants.SEEK_SET);
                     byte[] buffer = new byte[4096];
-                    for (int total = 0; total < length2;) {
-                        int remain = (int)length2 - total;
-                        int bytes = IoBridge.read(fd3, buffer, 0, Math.min(buffer.length, remain));
+                    for (long total = 0; total < length2;) {
+                        int bytesToRead = (int) Math.min(buffer.length, length2 - total);
+                        int bytes = IoBridge.read(fd3, buffer, 0, bytesToRead);
                         if (bytes < 0) {
                             break;
                         } else {
@@ -2355,6 +2361,18 @@
             throws IllegalStateException {
         // handle subtitle track through subtitle controller
         SubtitleTrack track = null;
+        synchronized (mInbandSubtitleLock) {
+            if (mInbandSubtitleTracks.length == 0) {
+                TrackInfo[] tracks = getInbandTrackInfo();
+                mInbandSubtitleTracks = new SubtitleTrack[tracks.length];
+                for (int i=0; i < tracks.length; i++) {
+                    if (tracks[i].getTrackType() == TrackInfo.MEDIA_TRACK_TYPE_SUBTITLE) {
+                        mInbandSubtitleTracks[i] = mSubtitleController.addTrack(tracks[i].getFormat());
+                    }
+                }
+            }
+        }
+
         if (index < mInbandSubtitleTracks.length) {
             track = mInbandSubtitleTracks[index];
         } else if (index < mInbandSubtitleTracks.length + mOutOfBandSubtitleTracks.size()) {
@@ -3253,9 +3271,7 @@
                 if (DEBUG) Log.d(TAG, "scheduleUpdate");
                 int i = registerListener(listener);
 
-                if (mStopped) {
-                    scheduleNotification(NOTIFY_STOP, 0 /* delay */);
-                } else {
+                if (!mStopped) {
                     mTimes[i] = 0;
                     scheduleNotification(NOTIFY_TIME, 0 /* delay */);
                 }
diff --git a/media/java/android/media/MediaRouter.java b/media/java/android/media/MediaRouter.java
index 7cda961..958ffab 100644
--- a/media/java/android/media/MediaRouter.java
+++ b/media/java/android/media/MediaRouter.java
@@ -190,14 +190,6 @@
 
             final int mainType = mCurAudioRoutesInfo.mMainType;
 
-            boolean a2dpEnabled;
-            try {
-                a2dpEnabled = mAudioService.isBluetoothA2dpOn();
-            } catch (RemoteException e) {
-                Log.e(TAG, "Error querying Bluetooth A2DP state", e);
-                a2dpEnabled = false;
-            }
-
             if (!TextUtils.equals(newRoutes.mBluetoothName, mCurAudioRoutesInfo.mBluetoothName)) {
                 mCurAudioRoutesInfo.mBluetoothName = newRoutes.mBluetoothName;
                 if (mCurAudioRoutesInfo.mBluetoothName != null) {
@@ -220,6 +212,7 @@
             }
 
             if (mBluetoothA2dpRoute != null) {
+                final boolean a2dpEnabled = isBluetoothA2dpOn();
                 if (mainType != AudioRoutesInfo.MAIN_SPEAKER &&
                         mSelectedRoute == mBluetoothA2dpRoute && !a2dpEnabled) {
                     selectRouteStatic(ROUTE_TYPE_LIVE_AUDIO, mDefaultAudioVideo, false);
@@ -230,6 +223,15 @@
             }
         }
 
+        boolean isBluetoothA2dpOn() {
+            try {
+                return mAudioService.isBluetoothA2dpOn();
+            } catch (RemoteException e) {
+                Log.e(TAG, "Error querying Bluetooth A2DP state", e);
+                return false;
+            }
+        }
+
         void updateDiscoveryRequest() {
             // What are we looking for today?
             int routeTypes = 0;
@@ -950,7 +952,7 @@
     static void selectDefaultRouteStatic() {
         // TODO: Be smarter about the route types here; this selects for all valid.
         if (sStatic.mSelectedRoute != sStatic.mBluetoothA2dpRoute
-                && sStatic.mBluetoothA2dpRoute != null) {
+                && sStatic.mBluetoothA2dpRoute != null && sStatic.isBluetoothA2dpOn()) {
             selectRouteStatic(ROUTE_TYPE_ANY, sStatic.mBluetoothA2dpRoute, false);
         } else {
             selectRouteStatic(ROUTE_TYPE_ANY, sStatic.mDefaultAudioVideo, false);
@@ -2129,7 +2131,7 @@
             if (mVolume != volume) {
                 mVolume = volume;
                 if (mSvp != null) {
-                    mSvp.notifyVolumeChanged();
+                    mSvp.setCurrentVolume(mVolume);
                 }
                 dispatchRouteVolumeChanged(this);
                 if (mGroup != null) {
@@ -2215,7 +2217,7 @@
                 // Only register a new listener if necessary
                 if (mSvp == null || mSvp.getVolumeControl() != volumeControl
                         || mSvp.getMaxVolume() != mVolumeMax) {
-                    mSvp = new SessionVolumeProvider(volumeControl, mVolumeMax);
+                    mSvp = new SessionVolumeProvider(volumeControl, mVolumeMax, mVolume);
                     session.setPlaybackToRemote(mSvp);
                 }
             } else {
@@ -2229,13 +2231,8 @@
 
         class SessionVolumeProvider extends VolumeProvider {
 
-            public SessionVolumeProvider(int volumeControl, int maxVolume) {
-                super(volumeControl, maxVolume);
-            }
-
-            @Override
-            public int onGetCurrentVolume() {
-                return mVcb == null ? 0 : mVcb.route.mVolume;
+            public SessionVolumeProvider(int volumeControl, int maxVolume, int currentVolume) {
+                super(volumeControl, maxVolume, currentVolume);
             }
 
             @Override
diff --git a/media/java/android/media/RemoteControlClient.java b/media/java/android/media/RemoteControlClient.java
index 2a0fd83..3c2ad0e 100644
--- a/media/java/android/media/RemoteControlClient.java
+++ b/media/java/android/media/RemoteControlClient.java
@@ -389,6 +389,7 @@
     public void registerWithSession(MediaSessionLegacyHelper helper) {
         helper.addRccListener(mRcMediaIntent, mTransportListener);
         mSession = helper.getSession(mRcMediaIntent);
+        setTransportControlFlags(mTransportControlFlags);
     }
 
     /**
diff --git a/media/java/android/media/RemoteController.java b/media/java/android/media/RemoteController.java
index adc8391..d84cf30 100644
--- a/media/java/android/media/RemoteController.java
+++ b/media/java/android/media/RemoteController.java
@@ -74,7 +74,7 @@
     private MetadataEditor mMetadataEditor;
 
     private MediaSessionManager mSessionManager;
-    private MediaSessionManager.SessionListener mSessionListener;
+    private MediaSessionManager.OnActiveSessionsChangedListener mSessionListener;
     private MediaController.Callback mSessionCb = new MediaControllerCallback();
 
     /**
@@ -140,7 +140,7 @@
         mAudioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
         mSessionManager = (MediaSessionManager) context
                 .getSystemService(Context.MEDIA_SESSION_SERVICE);
-        mSessionListener = new TopTransportSessionListener(context);
+        mSessionListener = new TopTransportSessionListener();
 
         if (ActivityManager.isLowRamDeviceStatic()) {
             mMaxBitmapDimension = MAX_BITMAP_DIMENSION;
@@ -710,11 +710,8 @@
      * Listens for changes to the active session stack and replaces the
      * currently tracked session if it has changed.
      */
-    private class TopTransportSessionListener extends MediaSessionManager.SessionListener {
-
-        public TopTransportSessionListener(Context context) {
-            super(context);
-        }
+    private class TopTransportSessionListener implements
+            MediaSessionManager.OnActiveSessionsChangedListener {
 
         @Override
         public void onActiveSessionsChanged(List<MediaController> controllers) {
@@ -792,8 +789,12 @@
     void startListeningToSessions() {
         final ComponentName listenerComponent = new ComponentName(mContext,
                 mOnClientUpdateListener.getClass());
-        mSessionManager.addActiveSessionsListener(mSessionListener, listenerComponent,
-                UserHandle.myUserId(), null);
+        Handler handler = null;
+        if (Looper.myLooper() == null) {
+            handler = new Handler(Looper.getMainLooper());
+        }
+        mSessionManager.addOnActiveSessionsChangedListener(mSessionListener, listenerComponent,
+                UserHandle.myUserId(), handler);
         mSessionListener.onActiveSessionsChanged(mSessionManager
                 .getActiveSessions(listenerComponent));
         if (DEBUG) {
@@ -806,7 +807,7 @@
      * @hide
      */
     void stopListeningToSessions() {
-        mSessionManager.removeActiveSessionsListener(mSessionListener);
+        mSessionManager.removeOnActiveSessionsChangedListener(mSessionListener);
         if (DEBUG) {
             Log.d(TAG, "Unregistered session listener for user "
                     + UserHandle.myUserId());
@@ -979,7 +980,7 @@
         synchronized (mInfoLock) {
             if (controller == null) {
                 if (mCurrentSession != null) {
-                    mCurrentSession.removeCallback(mSessionCb);
+                    mCurrentSession.unregisterCallback(mSessionCb);
                     mCurrentSession = null;
                     sendMsg(mEventHandler, MSG_CLIENT_CHANGE, SENDMSG_REPLACE,
                             0 /* genId */, 1 /* clearing */, null /* obj */, 0 /* delay */);
@@ -988,12 +989,12 @@
                     || !controller.getSessionToken()
                             .equals(mCurrentSession.getSessionToken())) {
                 if (mCurrentSession != null) {
-                    mCurrentSession.removeCallback(mSessionCb);
+                    mCurrentSession.unregisterCallback(mSessionCb);
                 }
                 sendMsg(mEventHandler, MSG_CLIENT_CHANGE, SENDMSG_REPLACE,
                         0 /* genId */, 0 /* clearing */, null /* obj */, 0 /* delay */);
                 mCurrentSession = controller;
-                mCurrentSession.addCallback(mSessionCb, mEventHandler);
+                mCurrentSession.registerCallback(mSessionCb, mEventHandler);
 
                 PlaybackState state = controller.getPlaybackState();
                 sendMsg(mEventHandler, MSG_NEW_PLAYBACK_STATE, SENDMSG_REPLACE,
diff --git a/media/java/android/media/Ringtone.java b/media/java/android/media/Ringtone.java
index a221104..7d075ba 100644
--- a/media/java/android/media/Ringtone.java
+++ b/media/java/android/media/Ringtone.java
@@ -115,6 +115,15 @@
     }
 
     /**
+     * Returns the {@link AudioAttributes} used by this object.
+     * @return the {@link AudioAttributes} that were set with
+     *     {@link #setAudioAttributes(AudioAttributes)} or the default attributes if none were set.
+     */
+    public AudioAttributes getAudioAttributes() {
+        return mAudioAttributes;
+    }
+
+    /**
      * Returns a human-presentable title for ringtone. Looks in media
      * content provider. If not in either, uses the filename
      * 
diff --git a/media/java/android/media/SoundPool.java b/media/java/android/media/SoundPool.java
index 9b9c767..4f74bdd 100644
--- a/media/java/android/media/SoundPool.java
+++ b/media/java/android/media/SoundPool.java
@@ -151,6 +151,10 @@
 
         /**
          * Constructs a new Builder with the defaults format values.
+         * If not provided, the maximum number of streams is 1 (see {@link #setMaxStreams(int)} to
+         * change it), and the audio attributes have a usage value of
+         * {@link AudioAttributes#USAGE_MEDIA} (see {@link #setAudioAttributes(AudioAttributes)} to
+         * change them).
          */
         public Builder() {
         }
diff --git a/media/java/android/media/SubtitleController.java b/media/java/android/media/SubtitleController.java
index 37adb8c..f82dbe0 100644
--- a/media/java/android/media/SubtitleController.java
+++ b/media/java/android/media/SubtitleController.java
@@ -275,7 +275,7 @@
                      mSelectedTrack.getFormat().getInteger(
                             MediaFormat.KEY_IS_FORCED_SUBTITLE, 0) != 0)) {
                     show();
-                } else {
+                } else if (mSelectedTrack != null && !mSelectedTrack.isTimedText()) {
                     hide();
                 }
                 mVisibilityIsExplicit = false;
diff --git a/media/java/android/media/ToneGenerator.java b/media/java/android/media/ToneGenerator.java
index 713f147..4661226 100644
--- a/media/java/android/media/ToneGenerator.java
+++ b/media/java/android/media/ToneGenerator.java
@@ -34,6 +34,12 @@
      * the enum in ToneGenerator C++ class.     */
 
     /**
+     * Default value for an unknown or unspecified tone.
+     * @hide
+     */
+    public static final int TONE_UNKNOWN = -1;
+
+    /**
      * DTMF tone for key 0: 1336Hz, 941Hz, continuous</p>
      *
      * @see #ToneGenerator(int, int)
diff --git a/media/java/android/media/VolumeProvider.java b/media/java/android/media/VolumeProvider.java
index 9bda1d4..5d1e004 100644
--- a/media/java/android/media/VolumeProvider.java
+++ b/media/java/android/media/VolumeProvider.java
@@ -19,7 +19,9 @@
 
 /**
  * Handles requests to adjust or set the volume on a session. This is also used
- * to push volume updates back to the session after a request has been handled.
+ * to push volume updates back to the session. The provider must call
+ * {@link #setCurrentVolume(int)} each time the volume being provided changes.
+ * <p>
  * You can set a volume provider on a session by calling
  * {@link MediaSession#setPlaybackToRemote}.
  */
@@ -46,29 +48,26 @@
 
     private final int mControlType;
     private final int mMaxVolume;
+    private int mCurrentVolume;
     private Callback mCallback;
 
     /**
      * Create a new volume provider for handling volume events. You must specify
-     * the type of volume control and the maximum volume that can be used.
+     * the type of volume control, the maximum volume that can be used, and the
+     * current volume on the output.
      *
      * @param volumeControl The method for controlling volume that is used by
      *            this provider.
      * @param maxVolume The maximum allowed volume.
+     * @param currentVolume The current volume on the output.
      */
-    public VolumeProvider(int volumeControl, int maxVolume) {
+    public VolumeProvider(int volumeControl, int maxVolume, int currentVolume) {
         mControlType = volumeControl;
         mMaxVolume = maxVolume;
+        mCurrentVolume = currentVolume;
     }
 
     /**
-     * Get the current volume of the remote playback.
-     *
-     * @return The current volume.
-     */
-    public abstract int onGetCurrentVolume();
-
-    /**
      * Get the volume control type that this volume provider uses.
      *
      * @return The volume control type for this volume provider
@@ -87,9 +86,23 @@
     }
 
     /**
-     * Notify the system that the volume has been changed.
+     * Gets the current volume. This will be the last value set by
+     * {@link #setCurrentVolume(int)}.
+     *
+     * @return The current volume.
      */
-    public final void notifyVolumeChanged() {
+    public final int getCurrentVolume() {
+        return mCurrentVolume;
+    }
+
+    /**
+     * Notify the system that the current volume has been changed. This must be
+     * called every time the volume changes to ensure it is displayed properly.
+     *
+     * @param currentVolume The current volume on the output.
+     */
+    public final void setCurrentVolume(int currentVolume) {
+        mCurrentVolume = currentVolume;
         if (mCallback != null) {
             mCallback.onVolumeChanged(this);
         }
@@ -97,6 +110,8 @@
 
     /**
      * Override to handle requests to set the volume of the current output.
+     * After the volume has been modified {@link #setCurrentVolume} must be
+     * called to notify the system.
      *
      * @param volume The volume to set the output to.
      */
@@ -107,7 +122,9 @@
      * Override to handle requests to adjust the volume of the current output.
      * Direction will be one of {@link AudioManager#ADJUST_LOWER},
      * {@link AudioManager#ADJUST_RAISE}, {@link AudioManager#ADJUST_SAME}.
-     * 
+     * After the volume has been modified {@link #setCurrentVolume} must be
+     * called to notify the system.
+     *
      * @param direction The direction to change the volume in.
      */
     public void onAdjustVolume(int direction) {
diff --git a/media/java/android/media/audiofx/Virtualizer.java b/media/java/android/media/audiofx/Virtualizer.java
index b314c02..be5adc8 100644
--- a/media/java/android/media/audiofx/Virtualizer.java
+++ b/media/java/android/media/audiofx/Virtualizer.java
@@ -16,11 +16,14 @@
 
 package android.media.audiofx;
 
+import android.annotation.IntDef;
 import android.media.AudioDevice;
 import android.media.AudioFormat;
 import android.media.audiofx.AudioEffect;
 import android.util.Log;
 
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
 import java.nio.ByteBuffer;
 import java.nio.ByteOrder;
 import java.util.StringTokenizer;
@@ -248,14 +251,114 @@
     }
 
     /**
-     * Checks if the combination of a channel mask and device type is supported by this virtualizer.
+     * A virtualization mode indicating virtualization processing is not active.
+     * See {@link #getVirtualizationMode()} as one of the possible return value.
+     */
+    public static final int VIRTUALIZATION_MODE_OFF = 0;
+
+    /**
+     * A virtualization mode used to indicate the virtualizer effect must stop forcing the
+     * processing to a particular mode in {@link #forceVirtualizationMode(int)}.
+     */
+    public static final int VIRTUALIZATION_MODE_AUTO = 1;
+    /**
+     * A virtualization mode typically used over headphones.
+     * Binaural virtualization describes an audio processing configuration for virtualization
+     * where the left and right channels are respectively reaching the left and right ear of the
+     * user, without also feeding the opposite ear (as is the case when listening over speakers).
+     * <p>Such a mode is therefore meant to be used when audio is playing over stereo wired
+     * headphones or headsets, but also stereo headphones through a wireless A2DP Bluetooth link.
+     * <p>See {@link #canVirtualize(int, int)} to verify this mode is supported by this Virtualizer.
+     */
+    public final static int VIRTUALIZATION_MODE_BINAURAL = 2;
+
+    /**
+     * A virtualization mode typically used over speakers.
+     * Transaural virtualization describes an audio processing configuration that differs from
+     * binaural (as described in {@link #VIRTUALIZATION_MODE_BINAURAL} in that cross-talk is
+     * present, i.e. audio played from the left channel also reaches the right ear of the user,
+     * and vice-versa.
+     * <p>When supported, such a mode is therefore meant to be used when audio is playing over the
+     * built-in stereo speakers of a device, if they are featured.
+     * <p>See {@link #canVirtualize(int, int)} to verify this mode is supported by this Virtualizer.
+     */
+    public final static int VIRTUALIZATION_MODE_TRANSAURAL = 3;
+
+    /** @hide */
+    @IntDef( {
+        VIRTUALIZATION_MODE_BINAURAL,
+        VIRTUALIZATION_MODE_TRANSAURAL
+    })
+    @Retention(RetentionPolicy.SOURCE)
+    public @interface VirtualizationMode {}
+
+    /** @hide */
+    @IntDef( {
+        VIRTUALIZATION_MODE_AUTO,
+        VIRTUALIZATION_MODE_BINAURAL,
+        VIRTUALIZATION_MODE_TRANSAURAL
+    })
+    @Retention(RetentionPolicy.SOURCE)
+    public @interface ForceVirtualizationMode {}
+
+    private static int getDeviceForModeQuery(@VirtualizationMode int virtualizationMode)
+            throws IllegalArgumentException {
+        switch (virtualizationMode) {
+            case VIRTUALIZATION_MODE_BINAURAL:
+                return AudioDevice.TYPE_WIRED_HEADPHONES;
+            case VIRTUALIZATION_MODE_TRANSAURAL:
+                return AudioDevice.TYPE_BUILTIN_SPEAKER;
+            default:
+                throw (new IllegalArgumentException(
+                        "Virtualizer: illegal virtualization mode " + virtualizationMode));
+        }
+    }
+
+    private static int getDeviceForModeForce(@ForceVirtualizationMode int virtualizationMode)
+            throws IllegalArgumentException {
+        if (virtualizationMode == VIRTUALIZATION_MODE_AUTO) {
+            return AudioDevice.TYPE_UNKNOWN;
+        } else {
+            return getDeviceForModeQuery(virtualizationMode);
+        }
+    }
+
+    private static int deviceToMode(int deviceType) {
+        switch (deviceType) {
+            case AudioDevice.TYPE_WIRED_HEADSET:
+            case AudioDevice.TYPE_WIRED_HEADPHONES:
+            case AudioDevice.TYPE_BLUETOOTH_SCO:
+            case AudioDevice.TYPE_BUILTIN_EARPIECE:
+                return VIRTUALIZATION_MODE_BINAURAL;
+            case AudioDevice.TYPE_BUILTIN_SPEAKER:
+            case AudioDevice.TYPE_LINE_ANALOG:
+            case AudioDevice.TYPE_LINE_DIGITAL:
+            case AudioDevice.TYPE_BLUETOOTH_A2DP:
+            case AudioDevice.TYPE_HDMI:
+            case AudioDevice.TYPE_HDMI_ARC:
+            case AudioDevice.TYPE_USB_DEVICE:
+            case AudioDevice.TYPE_USB_ACCESSORY:
+            case AudioDevice.TYPE_DOCK:
+            case AudioDevice.TYPE_FM:
+            case AudioDevice.TYPE_AUX_LINE:
+                return VIRTUALIZATION_MODE_TRANSAURAL;
+            case AudioDevice.TYPE_UNKNOWN:
+            default:
+                return VIRTUALIZATION_MODE_OFF;
+        }
+    }
+
+    /**
+     * Checks if the combination of a channel mask and virtualization mode is supported by this
+     * virtualizer.
      * Some virtualizer implementations may only support binaural processing (i.e. only support
-     * headphone output), some may support transaural processing (i.e. for speaker output) for the
+     * headphone output, see {@link #VIRTUALIZATION_MODE_BINAURAL}), some may support transaural
+     * processing (i.e. for speaker output, see {@link #VIRTUALIZATION_MODE_TRANSAURAL}) for the
      * built-in speakers. Use this method to query the virtualizer implementation capabilities.
      * @param inputChannelMask the channel mask of the content to virtualize.
-     * @param deviceType the device type for which virtualization processing is to be performed.
-     *    Valid values are the device types defined in {@link AudioDevice}.
-     * @return true if the combination of channel mask and output device type is supported, false
+     * @param virtualizationMode the mode for which virtualization processing is to be performed,
+     *    one of {@link #VIRTUALIZATION_MODE_BINAURAL}, {@link #VIRTUALIZATION_MODE_TRANSAURAL}.
+     * @return true if the combination of channel mask and virtualization mode is supported, false
      *    otherwise.
      *    <br>An indication that a certain channel mask is not supported doesn't necessarily mean
      *    you cannot play content with that channel mask, it more likely implies the content will
@@ -268,22 +371,22 @@
      * @throws IllegalArgumentException
      * @throws UnsupportedOperationException
      */
-    public boolean canVirtualize(int inputChannelMask, int deviceType)
+    public boolean canVirtualize(int inputChannelMask, @VirtualizationMode int virtualizationMode)
             throws IllegalStateException, IllegalArgumentException, UnsupportedOperationException {
-        return getAnglesInt(inputChannelMask, deviceType, null);
+        return getAnglesInt(inputChannelMask, getDeviceForModeQuery(virtualizationMode), null);
     }
 
     /**
      * Queries the virtual speaker angles (azimuth and elevation) for a combination of a channel
-     * mask and device type.
-     * If the virtualization configuration (mask and device) is supported (see
+     * mask and virtualization mode.
+     * If the virtualization configuration (mask and mode) is supported (see
      * {@link #canVirtualize(int, int)}, the array angles will contain upon return the
      * definition of each virtual speaker and its azimuth and elevation angles relative to the
      * listener.
      * <br>Note that in some virtualizer implementations, the angles may be strength-dependent.
      * @param inputChannelMask the channel mask of the content to virtualize.
-     * @param deviceType the device type for which virtualization processing is to be performed.
-     *    Valid values are the device types defined in {@link AudioDevice}.
+     * @param virtualizationMode the mode for which virtualization processing is to be performed,
+     *    one of {@link #VIRTUALIZATION_MODE_BINAURAL}, {@link #VIRTUALIZATION_MODE_TRANSAURAL}.
      * @param angles a non-null array whose length is 3 times the number of channels in the channel
      *    mask.
      *    If the method indicates the configuration is supported, the array will contain upon return
@@ -297,37 +400,39 @@
      *      <li>the element at index <code>3*i+2</code> contains its corresponding elevation angle
      *          where +90 is directly above the listener, 0 is the horizontal plane, and -90 is
      *          directly below the listener.</li>
-     * @return true if the combination of channel mask and output device type is supported, false
+     * @return true if the combination of channel mask and virtualization mode is supported, false
      *    otherwise.
      * @throws IllegalStateException
      * @throws IllegalArgumentException
      * @throws UnsupportedOperationException
      */
-    public boolean getSpeakerAngles(int inputChannelMask, int deviceType, int[] angles)
+    public boolean getSpeakerAngles(int inputChannelMask,
+            @VirtualizationMode int virtualizationMode, int[] angles)
             throws IllegalStateException, IllegalArgumentException, UnsupportedOperationException {
         if (angles == null) {
             throw (new IllegalArgumentException(
                     "Virtualizer: illegal null channel / angle array"));
         }
 
-        return getAnglesInt(inputChannelMask, deviceType, angles);
+        return getAnglesInt(inputChannelMask, getDeviceForModeQuery(virtualizationMode), angles);
     }
 
     /**
-     * Forces the virtualizer effect to use the processing mode used for the given device type.
+     * Forces the virtualizer effect to use the given processing mode.
      * The effect must be enabled for the forced mode to be applied.
-     * @param deviceType one of the device types defined in {@link AudioDevice}.
-     *     Use {@link AudioDevice#DEVICE_TYPE_UNKNOWN} to return to the non-forced mode.
-     * @return true if the processing mode for the device type is supported, and it is successfully
-     *     set, or forcing was successfully disabled with {@link AudioDevice#DEVICE_TYPE_UNKNOWN},
-     *     false otherwise.
+     * @param virtualizationMode one of {@link #VIRTUALIZATION_MODE_BINAURAL},
+     *     {@link #VIRTUALIZATION_MODE_TRANSAURAL} to force a particular processing mode, or
+     *     {@value #VIRTUALIZATION_MODE_AUTO} to stop forcing a mode.
+     * @return true if the processing mode is supported, and it is successfully set, or
+     *     forcing was successfully disabled, false otherwise.
      * @throws IllegalStateException
      * @throws IllegalArgumentException
      * @throws UnsupportedOperationException
      */
-    public boolean forceVirtualizationMode(int deviceType)
+    public boolean forceVirtualizationMode(@ForceVirtualizationMode int virtualizationMode)
             throws IllegalStateException, IllegalArgumentException, UnsupportedOperationException {
         // convert Java device type to internal representation
+        int deviceType = getDeviceForModeForce(virtualizationMode);
         int internalDevice = AudioDevice.convertDeviceTypeToInternalDevice(deviceType);
 
         int status = setParameter(PARAM_FORCE_VIRTUALIZATION_MODE, internalDevice);
@@ -335,8 +440,8 @@
         if (status >= 0) {
             return true;
         } else if (status == AudioEffect.ERROR_BAD_VALUE) {
-            // a BAD_VALUE return from setParameter indicates the mode can't be forced to that
-            // of this device, don't throw an exception, just return false
+            // a BAD_VALUE return from setParameter indicates the mode can't be forced
+            // don't throw an exception, just return false
             return false;
         } else {
             // something wrong may have happened
@@ -349,31 +454,25 @@
     }
 
     /**
-     * Return the device type which reflects the virtualization mode being used, if any.
-     * @return a device type (as defined in {@link AudioDevice}) which reflects the virtualization
-     *     mode being used.
-     *     If virtualization is not active, the device type will be
-     *     {@link AudioDevice#DEVICE_TYPE_UNKNOWN}. Virtualization may not be active either because
-     *     the effect is not enabled or because the current output device is not compatible with
-     *     this virtualization implementation.
-     *     <p>Note that the return value may differ from a device type successfully set with
-     *     {@link #forceVirtualizationMode(int)} as the implementation
-     *     may use a single mode for multiple devices. An example of this is with
-     *     {@link AudioDevice#DEVICE_TYPE_WIRED_HEADSET} that would typically be handled
-     *     like {@link AudioDevice#DEVICE_TYPE_WIRED_HEADPHONES} from a virtualization
-     *     standpoint.
+     * Return the virtualization mode being used, if any.
+     * @return the virtualization mode being used.
+     *     If virtualization is not active, the virtualization mode will be
+     *     {@link #VIRTUALIZATION_MODE_OFF}. Otherwise the value will be
+     *     {@link #VIRTUALIZATION_MODE_BINAURAL} or {@link #VIRTUALIZATION_MODE_TRANSAURAL}.
+     *     Virtualization may not be active either because the effect is not enabled or
+     *     because the current output device is not compatible with this virtualization
+     *     implementation.
      * @throws IllegalStateException
-     * @throws IllegalArgumentException
      * @throws UnsupportedOperationException
      */
     public int getVirtualizationMode()
-            throws IllegalStateException, IllegalArgumentException, UnsupportedOperationException {
+            throws IllegalStateException, UnsupportedOperationException {
         int[] value = new int[1];
         int status = getParameter(PARAM_VIRTUALIZATION_MODE, value);
         if (status >= 0) {
-            return AudioDevice.convertInternalDeviceToDeviceType(value[0]);
+            return deviceToMode(AudioDevice.convertInternalDeviceToDeviceType(value[0]));
         } else if (status == AudioEffect.ERROR_BAD_VALUE) {
-            return AudioDevice.DEVICE_TYPE_UNKNOWN;
+            return VIRTUALIZATION_MODE_OFF;
         } else {
             // something wrong may have happened
             checkStatus(status);
@@ -381,7 +480,7 @@
         // unexpected virtualizer behavior
         Log.e(TAG, "unexpected status code " + status
                 + " after getParameter(PARAM_VIRTUALIZATION_MODE)");
-        return AudioDevice.DEVICE_TYPE_UNKNOWN;
+        return VIRTUALIZATION_MODE_OFF;
     }
 
     /**
diff --git a/media/java/android/media/browse/IMediaBrowserService.aidl b/media/java/android/media/browse/IMediaBrowserService.aidl
deleted file mode 100644
index 8acd724..0000000
--- a/media/java/android/media/browse/IMediaBrowserService.aidl
+++ /dev/null
@@ -1,23 +0,0 @@
-// Copyright 2014 Google Inc. All Rights Reserved.
-
-package android.media.browse;
-
-import android.content.res.Configuration;
-import android.media.browse.IMediaBrowserServiceCallbacks;
-import android.net.Uri;
-import android.os.Bundle;
-
-/**
- * Media API allows clients to browse through hierarchy of a user’s media collection,
- * playback a specific media entry and interact with the now playing queue.
- * @hide
- */
-oneway interface IMediaBrowserService {
-    void connect(String pkg, in Bundle rootHints, IMediaBrowserServiceCallbacks callbacks);
-    void disconnect(IMediaBrowserServiceCallbacks callbacks);
-
-    void addSubscription(in Uri uri, IMediaBrowserServiceCallbacks callbacks);
-    void removeSubscription(in Uri uri, IMediaBrowserServiceCallbacks callbacks);
-    void loadIcon(in int seqNum, in Uri uri, int width, int height,
-            IMediaBrowserServiceCallbacks callbacks);
-}
\ No newline at end of file
diff --git a/media/java/android/media/browse/IMediaBrowserServiceCallbacks.aidl b/media/java/android/media/browse/IMediaBrowserServiceCallbacks.aidl
deleted file mode 100644
index 06fabcc..0000000
--- a/media/java/android/media/browse/IMediaBrowserServiceCallbacks.aidl
+++ /dev/null
@@ -1,28 +0,0 @@
-// Copyright 2014 Google Inc. All Rights Reserved.
-
-package android.media.browse;
-
-import android.content.pm.ParceledListSlice;
-import android.graphics.Bitmap;
-import android.media.session.MediaSession;
-import android.net.Uri;
-import android.os.Bundle;
-
-/**
- * Media API allows clients to browse through hierarchy of a user’s media collection,
- * playback a specific media entry and interact with the now playing queue.
- * @hide
- */
-oneway interface IMediaBrowserServiceCallbacks {
-    /**
-     * Invoked when the connected has been established.
-     * @param root The root Uri for browsing.
-     * @param session The {@link MediaSession.Token media session token} that can be used to control
-     *         the playback of the media app.
-     * @param extra Extras returned by the media service.
-     */
-    void onConnect(in Uri root, in MediaSession.Token session, in Bundle extras);
-    void onConnectFailed();
-    void onLoadChildren(in Uri uri, in ParceledListSlice list);
-    void onLoadIcon(int seqNum, in Bitmap bitmap);
-}
diff --git a/media/java/android/media/browse/MediaBrowser.aidl b/media/java/android/media/browse/MediaBrowser.aidl
new file mode 100644
index 0000000..782e094
--- /dev/null
+++ b/media/java/android/media/browse/MediaBrowser.aidl
@@ -0,0 +1,18 @@
+/* Copyright 2014, 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 android.media.browse;
+
+parcelable MediaBrowser.MediaItem;
\ No newline at end of file
diff --git a/media/java/android/media/browse/MediaBrowser.java b/media/java/android/media/browse/MediaBrowser.java
index 1c6d81f..34713e7 100644
--- a/media/java/android/media/browse/MediaBrowser.java
+++ b/media/java/android/media/browse/MediaBrowser.java
@@ -16,6 +16,7 @@
 
 package android.media.browse;
 
+import android.annotation.IntDef;
 import android.annotation.NonNull;
 import android.annotation.Nullable;
 import android.content.ComponentName;
@@ -23,26 +24,27 @@
 import android.content.Intent;
 import android.content.ServiceConnection;
 import android.content.pm.ParceledListSlice;
-import android.content.res.Configuration;
-import android.graphics.Bitmap;
+import android.media.MediaDescription;
+import android.media.session.MediaController;
 import android.media.session.MediaSession;
-import android.net.Uri;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
+import android.os.Parcel;
+import android.os.Parcelable;
 import android.os.RemoteException;
+import android.service.media.MediaBrowserService;
+import android.service.media.IMediaBrowserService;
+import android.service.media.IMediaBrowserServiceCallbacks;
+import android.text.TextUtils;
 import android.util.ArrayMap;
 import android.util.Log;
-import android.util.SparseArray;
 
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
 import java.lang.ref.WeakReference;
-import java.util.ArrayList;
 import java.util.Collections;
-import java.util.HashMap;
-import java.util.HashSet;
 import java.util.List;
-import java.util.Objects;
-import java.util.Set;
 
 /**
  * Browses media content offered by a link MediaBrowserService.
@@ -65,19 +67,16 @@
     private final ConnectionCallback mCallback;
     private final Bundle mRootHints;
     private final Handler mHandler = new Handler();
-    private final ArrayMap<Uri,Subscription> mSubscriptions =
-            new ArrayMap<Uri, MediaBrowser.Subscription>();
-    private final SparseArray<IconRequest> mIconRequests =
-            new SparseArray<IconRequest>();
+    private final ArrayMap<String,Subscription> mSubscriptions =
+            new ArrayMap<String, MediaBrowser.Subscription>();
 
     private int mState = CONNECT_STATE_DISCONNECTED;
     private MediaServiceConnection mServiceConnection;
     private IMediaBrowserService mServiceBinder;
     private IMediaBrowserServiceCallbacks mServiceCallbacks;
-    private Uri mRootUri;
+    private String mRootId;
     private MediaSession.Token mMediaSessionToken;
     private Bundle mExtras;
-    private int mNextSeq;
 
     /**
      * Creates a media browser for the specified media browse service.
@@ -86,7 +85,7 @@
      * @param serviceComponent The component name of the media browse service.
      * @param callback The connection callback.
      * @param rootHints An optional bundle of service-specific arguments to send
-     * to the media browse service when connecting and retrieving the root uri
+     * to the media browse service when connecting and retrieving the root id
      * for browsing, or null if none.  The contents of this bundle may affect
      * the information returned when browsing.
      */
@@ -137,7 +136,7 @@
 
         mState = CONNECT_STATE_CONNECTING;
 
-        final Intent intent = new Intent(MediaBrowserService.SERVICE_ACTION);
+        final Intent intent = new Intent(MediaBrowserService.SERVICE_INTERFACE);
         intent.setComponent(mServiceComponent);
 
         final ServiceConnection thisConnection = mServiceConnection = new MediaServiceConnection();
@@ -213,7 +212,7 @@
         mServiceConnection = null;
         mServiceBinder = null;
         mServiceCallbacks = null;
-        mRootUri = null;
+        mRootId = null;
         mMediaSessionToken = null;
     }
 
@@ -236,20 +235,20 @@
     }
 
     /**
-     * Gets the root Uri.
+     * Gets the root id.
      * <p>
-     * Note that the root uri may become invalid or change when when the
+     * Note that the root id may become invalid or change when when the
      * browser is disconnected.
      * </p>
      *
      * @throws IllegalStateException if not connected.
      */
-    public @NonNull Uri getRoot() {
+    public @NonNull String getRoot() {
         if (!isConnected()) {
             throw new IllegalStateException("getSessionToken() called while not connected (state="
                     + getStateLabel(mState) + ")");
         }
-        return mRootUri;
+        return mRootId;
     }
 
     /**
@@ -286,35 +285,35 @@
 
     /**
      * Queries for information about the media items that are contained within
-     * the specified Uri and subscribes to receive updates when they change.
+     * the specified id and subscribes to receive updates when they change.
      * <p>
      * The list of subscriptions is maintained even when not connected and is
      * restored after reconnection.  It is ok to subscribe while not connected
      * but the results will not be returned until the connection completes.
      * </p><p>
-     * If the uri is already subscribed with a different callback then the new
+     * If the id is already subscribed with a different callback then the new
      * callback will replace the previous one.
      * </p>
      *
-     * @param parentUri The uri of the parent media item whose list of children
+     * @param parentId The id of the parent media item whose list of children
      * will be subscribed.
      * @param callback The callback to receive the list of children.
      */
-    public void subscribe(@NonNull Uri parentUri, @NonNull SubscriptionCallback callback) {
+    public void subscribe(@NonNull String parentId, @NonNull SubscriptionCallback callback) {
         // Check arguments.
-        if (parentUri == null) {
-            throw new IllegalArgumentException("parentUri is null");
+        if (parentId == null) {
+            throw new IllegalArgumentException("parentId is null");
         }
         if (callback == null) {
             throw new IllegalArgumentException("callback is null");
         }
 
         // Update or create the subscription.
-        Subscription sub = mSubscriptions.get(parentUri);
+        Subscription sub = mSubscriptions.get(parentId);
         boolean newSubscription = sub == null;
         if (newSubscription) {
-            sub = new Subscription(parentUri);
-            mSubscriptions.put(parentUri, sub);
+            sub = new Subscription(parentId);
+            mSubscriptions.put(parentId, sub);
         }
         sub.callback = callback;
 
@@ -322,90 +321,47 @@
         // connected, the service will be told when we connect.
         if (mState == CONNECT_STATE_CONNECTED && newSubscription) {
             try {
-                mServiceBinder.addSubscription(parentUri, mServiceCallbacks);
+                mServiceBinder.addSubscription(parentId, mServiceCallbacks);
             } catch (RemoteException ex) {
                 // Process is crashing.  We will disconnect, and upon reconnect we will
                 // automatically reregister. So nothing to do here.
-                Log.d(TAG, "addSubscription failed with RemoteException parentUri=" + parentUri);
+                Log.d(TAG, "addSubscription failed with RemoteException parentId=" + parentId);
             }
         }
     }
 
     /**
-     * Unsubscribes for changes to the children of the specified Uri.
+     * Unsubscribes for changes to the children of the specified media id.
      * <p>
      * The query callback will no longer be invoked for results associated with
-     * this Uri once this method returns.
+     * this id once this method returns.
      * </p>
      *
-     * @param parentUri The uri of the parent media item whose list of children
+     * @param parentId The id of the parent media item whose list of children
      * will be unsubscribed.
      */
-    public void unsubscribe(@NonNull Uri parentUri) {
+    public void unsubscribe(@NonNull String parentId) {
         // Check arguments.
-        if (parentUri == null) {
-            throw new IllegalArgumentException("parentUri is null");
+        if (parentId == null) {
+            throw new IllegalArgumentException("parentId is null");
         }
 
         // Remove from our list.
-        final Subscription sub = mSubscriptions.remove(parentUri);
+        final Subscription sub = mSubscriptions.remove(parentId);
 
         // Tell the service if necessary.
         if (mState == CONNECT_STATE_CONNECTED && sub != null) {
             try {
-                mServiceBinder.removeSubscription(parentUri, mServiceCallbacks);
+                mServiceBinder.removeSubscription(parentId, mServiceCallbacks);
             } catch (RemoteException ex) {
                 // Process is crashing.  We will disconnect, and upon reconnect we will
                 // automatically reregister. So nothing to do here.
-                Log.d(TAG, "removeSubscription failed with RemoteException parentUri=" + parentUri);
+                Log.d(TAG, "removeSubscription failed with RemoteException parentId=" + parentId);
             }
         }
     }
 
     /**
-     * Loads the icon of a media item.
-     *
-     * @param uri The uri of the Icon.
-     * @param width The preferred width of the icon in dp.
-     * @param height The preferred width of the icon in dp.
-     * @param callback The callback to receive the icon.
-     */
-    public void loadIcon(final @NonNull Uri uri, final int width, final int height,
-            final @NonNull IconCallback callback) {
-        if (uri == null) {
-            throw new IllegalArgumentException("Icon uri cannot be null");
-        }
-        if (callback == null) {
-            throw new IllegalArgumentException("Icon callback cannot be null");
-        }
-        mHandler.post(new Runnable() {
-            @Override
-            public void run() {
-                for (int i = 0; i < mIconRequests.size(); i++) {
-                    IconRequest existingRequest = mIconRequests.valueAt(i);
-                    if (existingRequest.isSameRequest(uri, width, height)) {
-                        existingRequest.addCallback(callback);
-                        return;
-                    }
-                }
-                final int seq = mNextSeq++;
-                IconRequest request = new IconRequest(seq, uri, width, height);
-                request.addCallback(callback);
-                mIconRequests.put(seq, request);
-                if (mState == CONNECT_STATE_CONNECTED) {
-                    try {
-                        mServiceBinder.loadIcon(seq, uri, width, height, mServiceCallbacks);
-                    } catch (RemoteException e) {
-                        // Process is crashing.  We will disconnect, and upon reconnect we will
-                        // automatically reload the icons. So nothing to do here.
-                        Log.d(TAG, "loadIcon failed with RemoteException uri=" + uri);
-                    }
-                }
-            }
-        });
-    }
-
-    /**
      * For debugging.
      */
     private static String getStateLabel(int state) {
@@ -424,7 +380,7 @@
     }
 
     private final void onServiceConnected(final IMediaBrowserServiceCallbacks callback,
-            final Uri root, final MediaSession.Token session, final Bundle extra) {
+            final String root, final MediaSession.Token session, final Bundle extra) {
         mHandler.post(new Runnable() {
             @Override
             public void run() {
@@ -439,7 +395,7 @@
                             + getStateLabel(mState) + "... ignoring");
                     return;
                 }
-                mRootUri = root;
+                mRootId = root;
                 mMediaSessionToken = session;
                 mExtras = extra;
                 mState = CONNECT_STATE_CONNECTED;
@@ -452,25 +408,13 @@
 
                 // we may receive some subscriptions before we are connected, so re-subscribe
                 // everything now
-                for (Uri uri : mSubscriptions.keySet()) {
+                for (String id : mSubscriptions.keySet()) {
                     try {
-                        mServiceBinder.addSubscription(uri, mServiceCallbacks);
+                        mServiceBinder.addSubscription(id, mServiceCallbacks);
                     } catch (RemoteException ex) {
                         // Process is crashing.  We will disconnect, and upon reconnect we will
                         // automatically reregister. So nothing to do here.
-                        Log.d(TAG, "addSubscription failed with RemoteException parentUri=" + uri);
-                    }
-                }
-
-                for (int i = 0; i < mIconRequests.size(); i++) {
-                    IconRequest request = mIconRequests.valueAt(i);
-                    try {
-                        mServiceBinder.loadIcon(request.mSeq, request.mUri,
-                                request.mWidth, request.mHeight, mServiceCallbacks);
-                    } catch (RemoteException e) {
-                        // Process is crashing.  We will disconnect, and upon reconnect we will
-                        // automatically reload. So nothing to do here.
-                        Log.d(TAG, "loadIcon failed with RemoteException request=" + request);
+                        Log.d(TAG, "addSubscription failed with RemoteException parentId=" + id);
                     }
                 }
             }
@@ -504,8 +448,8 @@
         });
     }
 
-    private final void onLoadChildren(final IMediaBrowserServiceCallbacks callback, final Uri uri,
-            final ParceledListSlice list) {
+    private final void onLoadChildren(final IMediaBrowserServiceCallbacks callback,
+            final String parentId, final ParceledListSlice list) {
         mHandler.post(new Runnable() {
             @Override
             public void run() {
@@ -515,56 +459,30 @@
                     return;
                 }
 
-                List<MediaBrowserItem> data = list.getList();
+                List<MediaItem> data = list.getList();
                 if (DBG) {
-                    Log.d(TAG, "onLoadChildren for " + mServiceComponent + " uri=" + uri);
+                    Log.d(TAG, "onLoadChildren for " + mServiceComponent + " id=" + parentId);
                 }
                 if (data == null) {
                     data = Collections.emptyList();
                 }
 
                 // Check that the subscription is still subscribed.
-                final Subscription subscription = mSubscriptions.get(uri);
+                final Subscription subscription = mSubscriptions.get(parentId);
                 if (subscription == null) {
                     if (DBG) {
-                        Log.d(TAG, "onLoadChildren for uri that isn't subscribed uri="
-                                + uri);
+                        Log.d(TAG, "onLoadChildren for id that isn't subscribed id="
+                                + parentId);
                     }
                     return;
                 }
 
                 // Tell the app.
-                subscription.callback.onChildrenLoaded(uri, data);
+                subscription.callback.onChildrenLoaded(parentId, data);
             }
         });
     }
 
-    private final void onLoadIcon(final IMediaBrowserServiceCallbacks callback,
-            final int seqNum, final Bitmap bitmap) {
-        mHandler.post(new Runnable() {
-            @Override
-            public void run() {
-                // Check that there hasn't been a disconnect or a different
-                // ServiceConnection.
-                if (!isCurrent(callback, "onLoadIcon")) {
-                    return;
-                }
-
-                IconRequest request = mIconRequests.get(seqNum);
-                if (request == null) {
-                    Log.d(TAG, "onLoadIcon called for seqNum=" + seqNum + " request="
-                            + request + " but the request is not registered");
-                    return;
-                }
-                mIconRequests.delete(seqNum);
-                for (IconCallback IconCallback : request.getCallbacks()) {
-                    IconCallback.onIconLoaded(request.mUri, bitmap);
-                }
-            }
-        });
-    }
-
-
     /**
      * Return true if {@code callback} is the current ServiceCallbacks.  Also logs if it's not.
      */
@@ -596,10 +514,130 @@
         Log.d(TAG, "  mServiceConnection=" + mServiceConnection);
         Log.d(TAG, "  mServiceBinder=" + mServiceBinder);
         Log.d(TAG, "  mServiceCallbacks=" + mServiceCallbacks);
-        Log.d(TAG, "  mRootUri=" + mRootUri);
+        Log.d(TAG, "  mRootId=" + mRootId);
         Log.d(TAG, "  mMediaSessionToken=" + mMediaSessionToken);
     }
 
+    public static class MediaItem implements Parcelable {
+        private final int mFlags;
+        private final MediaDescription mDescription;
+
+        /** @hide */
+        @Retention(RetentionPolicy.SOURCE)
+        @IntDef(flag=true, value = { FLAG_BROWSABLE, FLAG_PLAYABLE })
+        public @interface Flags { }
+
+        /**
+         * Flag: Indicates that the item has children of its own.
+         */
+        public static final int FLAG_BROWSABLE = 1 << 0;
+
+        /**
+         * Flag: Indicates that the item is playable.
+         * <p>
+         * The id of this item may be passed to
+         * {@link MediaController.TransportControls#playFromMediaId(String, Bundle)}
+         * to start playing it.
+         * </p>
+         */
+        public static final int FLAG_PLAYABLE = 1 << 1;
+
+        /**
+         * Create a new MediaItem for use in browsing media.
+         * @param description The description of the media, which must include a
+         *            media id.
+         * @param flags The flags for this item.
+         */
+        public MediaItem(@NonNull MediaDescription description, @Flags int flags) {
+            if (description == null) {
+                throw new IllegalArgumentException("description cannot be null");
+            }
+            if (TextUtils.isEmpty(description.getMediaId())) {
+                throw new IllegalArgumentException("description must have a non-empty media id");
+            }
+            mFlags = flags;
+            mDescription = description;
+        }
+
+        /**
+         * Private constructor.
+         */
+        private MediaItem(Parcel in) {
+            mFlags = in.readInt();
+            mDescription = MediaDescription.CREATOR.createFromParcel(in);
+        }
+
+        @Override
+        public int describeContents() {
+            return 0;
+        }
+
+        @Override
+        public void writeToParcel(Parcel out, int flags) {
+            out.writeInt(mFlags);
+            mDescription.writeToParcel(out, flags);
+        }
+
+        @Override
+        public String toString() {
+            final StringBuilder sb = new StringBuilder("MediaItem{");
+            sb.append("mFlags=").append(mFlags);
+            sb.append(", mDescription=").append(mDescription);
+            sb.append('}');
+            return sb.toString();
+        }
+
+        public static final Parcelable.Creator<MediaItem> CREATOR =
+                new Parcelable.Creator<MediaItem>() {
+                    @Override
+                    public MediaItem createFromParcel(Parcel in) {
+                        return new MediaItem(in);
+                    }
+
+                    @Override
+                    public MediaItem[] newArray(int size) {
+                        return new MediaItem[size];
+                    }
+                };
+
+        /**
+         * Gets the flags of the item.
+         */
+        public @Flags int getFlags() {
+            return mFlags;
+        }
+
+        /**
+         * Returns whether this item is browsable.
+         * @see #FLAG_BROWSABLE
+         */
+        public boolean isBrowsable() {
+            return (mFlags & FLAG_BROWSABLE) != 0;
+        }
+
+        /**
+         * Returns whether this item is playable.
+         * @see #FLAG_PLAYABLE
+         */
+        public boolean isPlayable() {
+            return (mFlags & FLAG_PLAYABLE) != 0;
+        }
+
+        /**
+         * Returns the description of the media.
+         */
+        public @NonNull MediaDescription getDescription() {
+            return mDescription;
+        }
+
+        /**
+         * Returns the media id for this item.
+         */
+        public @NonNull String getMediaId() {
+            return mDescription.getMediaId();
+        }
+    }
+
 
     /**
      * Callbacks for connection related events.
@@ -631,99 +669,18 @@
         /**
          * Called when the list of children is loaded or updated.
          */
-        public void onChildrenLoaded(@NonNull Uri parentUri,
-                                     @NonNull List<MediaBrowserItem> children) {
+        public void onChildrenLoaded(@NonNull String parentId,
+                                     @NonNull List<MediaItem> children) {
         }
 
         /**
-         * Called when the Uri doesn't exist or other errors in subscribing.
+         * Called when the id doesn't exist or other errors in subscribing.
          * <p>
          * If this is called, the subscription remains until {@link MediaBrowser#unsubscribe}
          * called, because some errors may heal themselves.
          * </p>
          */
-        public void onError(@NonNull Uri uri) {
-        }
-    }
-
-    /**
-     * Callbacks for icon loading.
-     */
-    public static abstract class IconCallback {
-        /**
-         * Called when the icon is loaded.
-         */
-        public void onIconLoaded(@NonNull Uri uri, @NonNull Bitmap bitmap) {
-        }
-
-        /**
-         * Called when the Uri doesn’t exist or the bitmap cannot be loaded.
-         */
-        public void onError(@NonNull Uri uri) {
-        }
-    }
-
-    private static class IconRequest {
-        final int mSeq;
-        final Uri mUri;
-        final int mWidth;
-        final int mHeight;
-        final List<IconCallback> mCallbacks;
-
-        /**
-         * Constructs an icon request.
-         * @param seq The unique sequence number assigned to the request by the media browser.
-         * @param uri The Uri for the icon.
-         * @param width The width for the icon.
-         * @param height The height for the icon.
-         */
-        IconRequest(int seq, @NonNull Uri uri, int width, int height) {
-            if (uri == null) {
-                throw new IllegalArgumentException("Icon uri cannot be null");
-            }
-            this.mSeq = seq;
-            this.mUri = uri;
-            this.mWidth = width;
-            this.mHeight = height;
-            mCallbacks = new ArrayList<IconCallback>();
-        }
-
-        /**
-         * Adds a callback to the icon request.
-         * If the callback already exists, it will not be added again.
-         */
-        public void addCallback(@NonNull IconCallback callback) {
-            if (callback == null) {
-                throw new IllegalArgumentException("callback cannot be null in IconRequest");
-            }
-            if (!mCallbacks.contains(callback)) {
-                mCallbacks.add(callback);
-            }
-        }
-
-        /**
-         * Checks if the icon request has the same uri, width, and height as the given values.
-         */
-        public boolean isSameRequest(@Nullable Uri uri, int width, int height) {
-            return Objects.equals(mUri, uri) && mWidth == width && mHeight == height;
-        }
-
-        @Override
-        public String toString() {
-            final StringBuilder sb = new StringBuilder("IconRequest{");
-            sb.append("uri=").append(mUri);
-            sb.append(", width=").append(mWidth);
-            sb.append(", height=").append(mHeight);
-            sb.append(", seq=").append(mSeq);
-            sb.append('}');
-            return sb.toString();
-        }
-
-        /**
-         * Gets an unmodifiable view of the list of callbacks associated with the request.
-         */
-        public List<IconCallback> getCallbacks() {
-            return Collections.unmodifiableList(mCallbacks);
+        public void onError(@NonNull String id) {
         }
     }
 
@@ -809,7 +766,7 @@
             }
             return true;
         }
-    };
+    }
 
     /**
      * Callbacks from the service.
@@ -826,7 +783,7 @@
          * are the initial data as requested.
          */
         @Override
-        public void onConnect(final Uri root, final MediaSession.Token session,
+        public void onConnect(final String root, final MediaSession.Token session,
                 final Bundle extras) {
             MediaBrowser mediaBrowser = mMediaBrowser.get();
             if (mediaBrowser != null) {
@@ -846,28 +803,20 @@
         }
 
         @Override
-        public void onLoadChildren(final Uri uri, final ParceledListSlice list) {
+        public void onLoadChildren(final String parentId, final ParceledListSlice list) {
             MediaBrowser mediaBrowser = mMediaBrowser.get();
             if (mediaBrowser != null) {
-                mediaBrowser.onLoadChildren(this, uri, list);
-            }
-        }
-
-        @Override
-        public void onLoadIcon(final int seqNum, final Bitmap bitmap) {
-            MediaBrowser mediaBrowser = mMediaBrowser.get();
-            if (mediaBrowser != null) {
-                mediaBrowser.onLoadIcon(this, seqNum, bitmap);
+                mediaBrowser.onLoadChildren(this, parentId, list);
             }
         }
     }
 
     private static class Subscription {
-        final Uri uri;
+        final String id;
         SubscriptionCallback callback;
 
-        Subscription(Uri u) {
-            this.uri = u;
+        Subscription(String id) {
+            this.id = id;
         }
     }
 }
diff --git a/media/java/android/media/browse/MediaBrowserItem.java b/media/java/android/media/browse/MediaBrowserItem.java
deleted file mode 100644
index 47ec46b..0000000
--- a/media/java/android/media/browse/MediaBrowserItem.java
+++ /dev/null
@@ -1,313 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.browse;
-
-import android.annotation.DrawableRes;
-import android.annotation.IntDef;
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.net.Uri;
-
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-
-/**
- * Describes a media item in the list of items offered by a {@link MediaBrowserService}.
- */
-public final class MediaBrowserItem implements Parcelable {
-    private final Uri mUri;
-    private final int mFlags;
-    private final CharSequence mTitle;
-    private final CharSequence mSummary;
-    private final Uri mIconUri;
-    private final int mIconResourceId;
-    private final Bundle mExtras;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(flag=true, value = { FLAG_BROWSABLE, FLAG_PLAYABLE })
-    public @interface Flags { }
-
-    /**
-     * Flag: Indicates that the item has children of its own.
-     */
-    public static final int FLAG_BROWSABLE = 1 << 0;
-
-    /**
-     * Flag: Indicates that the item is playable.
-     * <p>
-     * The Uri of this item may be passed to link android.media.session.MediaController#play(Uri)
-     * to start playing it.
-     * </p>
-     */
-    public static final int FLAG_PLAYABLE = 1 << 1;
-
-    /**
-     * Initialize a MediaBrowserItem object.
-     */
-    private MediaBrowserItem(@NonNull Uri uri, int flags, @NonNull CharSequence title,
-            CharSequence summary, @Nullable Uri iconUri, int iconResourceId, Bundle extras) {
-        if (uri == null) {
-            throw new IllegalArgumentException("uri can not be null");
-        }
-        if (title == null) {
-            throw new IllegalArgumentException("title can not be null");
-        }
-        mUri = uri;
-        mFlags = flags;
-        mTitle = title;
-        mSummary = summary;
-        mIconUri = iconUri;
-        mIconResourceId = iconResourceId;
-        mExtras = extras;
-    }
-
-    /**
-     * Private constructor.
-     */
-    private MediaBrowserItem(Parcel in) {
-        mUri = Uri.CREATOR.createFromParcel(in);
-        mFlags = in.readInt();
-        mTitle = in.readCharSequence();
-        if (in.readInt() != 0) {
-            mSummary = in.readCharSequence();
-        } else {
-            mSummary = null;
-        }
-        if (in.readInt() != 0) {
-            mIconUri = Uri.CREATOR.createFromParcel(in);
-        } else {
-            mIconUri = null;
-        }
-        mIconResourceId = in.readInt();
-        if (in.readInt() != 0) {
-            mExtras = Bundle.CREATOR.createFromParcel(in);
-        } else {
-            mExtras = null;
-        }
-    }
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        mUri.writeToParcel(out, flags);
-        out.writeInt(mFlags);
-        out.writeCharSequence(mTitle);
-        if (mSummary != null) {
-            out.writeInt(1);
-            out.writeCharSequence(mSummary);
-        } else {
-            out.writeInt(0);
-        }
-        if (mIconUri != null) {
-            out.writeInt(1);
-            mIconUri.writeToParcel(out, flags);
-        } else {
-            out.writeInt(0);
-        }
-        out.writeInt(mIconResourceId);
-        if (mExtras != null) {
-            out.writeInt(1);
-            mExtras.writeToParcel(out, flags);
-        } else {
-            out.writeInt(0);
-        }
-    }
-
-    @Override
-    public String toString() {
-        final StringBuilder sb = new StringBuilder("MediaBrowserItem{");
-        sb.append("mUri=").append(mUri);
-        sb.append(", mFlags=").append(mFlags);
-        sb.append(", mTitle=").append(mTitle);
-        sb.append(", mSummary=").append(mSummary);
-        sb.append(", mIconUri=").append(mIconUri);
-        sb.append(", mIconResourceId=").append(mIconResourceId);
-        sb.append('}');
-        return sb.toString();
-    }
-
-    public static final Parcelable.Creator<MediaBrowserItem> CREATOR =
-            new Parcelable.Creator<MediaBrowserItem>() {
-                @Override
-                public MediaBrowserItem createFromParcel(Parcel in) {
-                    return new MediaBrowserItem(in);
-                }
-
-                @Override
-                public MediaBrowserItem[] newArray(int size) {
-                    return new MediaBrowserItem[size];
-                }
-            };
-
-    /**
-     * Gets the Uri of the item.
-     */
-    public @NonNull Uri getUri() {
-        return mUri;
-    }
-
-    /**
-     * Gets the flags of the item.
-     */
-    public @Flags int getFlags() {
-        return mFlags;
-    }
-
-    /**
-     * Returns whether this item is browsable.
-     * @see #FLAG_BROWSABLE
-     */
-    public boolean isBrowsable() {
-        return (mFlags & FLAG_BROWSABLE) != 0;
-    }
-
-    /**
-     * Returns whether this item is playable.
-     * @see #FLAG_PLAYABLE
-     */
-    public boolean isPlayable() {
-        return (mFlags & FLAG_PLAYABLE) != 0;
-    }
-
-    /**
-     * Gets the title of the item.
-     * @more
-     * The title will be shown as the first line of text when
-     * describing each item to the user.
-     */
-    public @NonNull CharSequence getTitle() {
-        return mTitle;
-    }
-
-    /**
-     * Gets summary of the item, or null if none.
-     * @more
-     * The summary will be shown as the second line of text when
-     * describing each item to the user.
-     */
-    public @Nullable CharSequence getSummary() {
-        return mSummary;
-    }
-
-    /**
-     * Gets the Uri of the icon.
-     */
-    public @Nullable Uri getIconUri() {
-        return mIconUri;
-    }
-
-    /**
-     * Gets the resource id of the icon.
-     */
-    public @DrawableRes int getIconResourceId() {
-        return mIconResourceId;
-    }
-
-    /**
-     * Gets additional service-specified extras about the
-     * item or its content, or null if none.
-     */
-    public @Nullable Bundle getExtras() {
-        return mExtras;
-    }
-
-    /**
-     * Builder for {@link MediaBrowserItem} objects.
-     */
-    public static final class Builder {
-        private final Uri mUri;
-        private final int mFlags;
-        private final CharSequence mTitle;
-        private CharSequence mSummary;
-        private Uri mIconUri;
-        private int mIconResourceId;
-        private Bundle mExtras;
-
-        /**
-         * Creates an item builder.
-         */
-        public Builder(@NonNull Uri uri, @Flags int flags, @NonNull CharSequence title) {
-            if (uri == null) {
-                throw new IllegalArgumentException("uri can not be null");
-            }
-            if (title == null) {
-                throw new IllegalArgumentException("title can not be null");
-            }
-            mUri = uri;
-            mFlags = flags;
-            mTitle = title;
-        }
-
-        /**
-         * Sets summary of the item, or null if none.
-         */
-        public @NonNull Builder setSummary(@Nullable CharSequence summary) {
-            mSummary = summary;
-            return this;
-        }
-
-        /**
-         * Sets the uri of the icon.
-         * <p>
-         * Either {@link #setIconUri(Uri)} or {@link #setIconResourceId(int)} should be called.
-         * If both are specified, the resource id will be used to load the icon.
-         * </p>
-         */
-        public @NonNull Builder setIconUri(@Nullable Uri iconUri) {
-            mIconUri = iconUri;
-            return this;
-        }
-
-        /**
-         * Sets the resource id of the icon.
-         * <p>
-         * Either {@link #setIconUri(Uri)} or {@link #setIconResourceId(int)} should be specified.
-         * If both are specified, the resource id will be used to load the icon.
-         * </p>
-         */
-        public @NonNull Builder setIconResourceId(@DrawableRes int ResourceId) {
-            mIconResourceId = ResourceId;
-            return this;
-        }
-
-        /**
-         * Sets additional service-specified extras about the
-         * item or its content.
-         */
-        public @NonNull Builder setExtras(@Nullable Bundle extras) {
-            mExtras = extras;
-            return this;
-        }
-
-        /**
-         * Builds the item.
-         */
-        public @NonNull MediaBrowserItem build() {
-            return new MediaBrowserItem(mUri, mFlags, mTitle, mSummary, mIconUri,
-                    mIconResourceId, mExtras);
-        }
-    }
-}
-
diff --git a/media/java/android/media/browse/MediaBrowserService.java b/media/java/android/media/browse/MediaBrowserService.java
deleted file mode 100644
index 99126c9..0000000
--- a/media/java/android/media/browse/MediaBrowserService.java
+++ /dev/null
@@ -1,550 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.browse;
-
-import android.annotation.IntDef;
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.annotation.SdkConstant;
-import android.annotation.SdkConstant.SdkConstantType;
-import android.app.Service;
-import android.content.Intent;
-import android.content.pm.PackageManager;
-import android.content.pm.ParceledListSlice;
-import android.content.res.Configuration;
-import android.graphics.Bitmap;
-import android.media.session.MediaSession;
-import android.net.Uri;
-import android.os.Binder;
-import android.os.Bundle;
-import android.os.IBinder;
-import android.os.Handler;
-import android.os.RemoteException;
-import android.util.ArrayMap;
-import android.util.Log;
-
-import java.io.FileDescriptor;
-import java.io.PrintWriter;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-
-/**
- * Base class for media browse services.
- * <p>
- * Media browse services enable applications to browse media content provided by an application
- * and ask the application to start playing it.  They may also be used to control content that
- * is already playing by way of a {@link MediaSession}.
- * </p>
- *
- * To extend this class, you must declare the service in your manifest file with
- * an intent filter with the {@link #SERVICE_ACTION} action.
- *
- * For example:
- * </p><pre>
- * &lt;service android:name=".MyMediaBrowserService"
- *          android:label="&#64;string/service_name" >
- *     &lt;intent-filter>
- *         &lt;action android:name="android.media.browse.MediaBrowserService" />
- *     &lt;/intent-filter>
- * &lt;/service>
- * </pre>
- *
- */
-public abstract class MediaBrowserService extends Service {
-    private static final String TAG = "MediaBrowserService";
-    private static final boolean DBG = false;
-
-    /**
-     * The {@link Intent} that must be declared as handled by the service.
-     */
-    @SdkConstant(SdkConstantType.SERVICE_ACTION)
-    public static final String SERVICE_ACTION = "android.media.browse.MediaBrowserService";
-
-    private final ArrayMap<IBinder, ConnectionRecord> mConnections = new ArrayMap();
-    private final Handler mHandler = new Handler();
-    private ServiceBinder mBinder;
-    MediaSession.Token mSession;
-
-    /**
-     * All the info about a connection.
-     */
-    private class ConnectionRecord {
-        String pkg;
-        Bundle rootHints;
-        IMediaBrowserServiceCallbacks callbacks;
-        BrowserRoot root;
-        HashSet<Uri> subscriptions = new HashSet();
-    }
-
-    /**
-     * Completion handler for asynchronous callback methods in {@link MediaBrowserService}.
-     * <p>
-     * Each of the methods that takes one of these to send the result must call
-     * {@link #sendResult} to respond to the caller with the given results.  If those
-     * functions return without calling {@link #sendResult}, they must instead call
-     * {@link #detach} before returning, and then may call {@link #sendResult} when
-     * they are done.  If more than one of those methods is called, an exception will
-     * be thrown.
-     *
-     * @see MediaBrowserService#onLoadChildren
-     * @see MediaBrowserService#onLoadIcon
-     */
-    public class Result<T> {
-        private Object mDebug;
-        private boolean mDetachCalled;
-        private boolean mSendResultCalled;
-
-        Result(Object debug) {
-            mDebug = debug;
-        }
-
-        /**
-         * Send the result back to the caller.
-         */
-        public void sendResult(T result) {
-            if (mSendResultCalled) {
-                throw new IllegalStateException("sendResult() called twice for: " + mDebug);
-            }
-            mSendResultCalled = true;
-            onResultSent(result);
-        }
-
-        /**
-         * Detach this message from the current thread and allow the {@link #sendResult}
-         * call to happen later.
-         */
-        public void detach() {
-            if (mDetachCalled) {
-                throw new IllegalStateException("detach() called when detach() had already"
-                        + " been called for: " + mDebug);
-            }
-            if (mSendResultCalled) {
-                throw new IllegalStateException("detach() called when sendResult() had already"
-                        + " been called for: " + mDebug);
-            }
-            mDetachCalled = true;
-        }
-
-        boolean isDone() {
-            return mDetachCalled || mSendResultCalled;
-        }
-
-        /**
-         * Called when the result is sent, after assertions about not being called twice
-         * have happened.
-         */
-        void onResultSent(T result) {
-        }
-    }
-
-    private class ServiceBinder extends IMediaBrowserService.Stub {
-        @Override
-        public void connect(final String pkg, final Bundle rootHints,
-                final IMediaBrowserServiceCallbacks callbacks) {
-
-            final int uid = Binder.getCallingUid();
-            if (!isValidPackage(pkg, uid)) {
-                throw new IllegalArgumentException("Package/uid mismatch: uid=" + uid
-                        + " package=" + pkg);
-            }
-
-            mHandler.post(new Runnable() {
-                    @Override
-                    public void run() {
-                        final IBinder b = callbacks.asBinder();
-
-                        // Clear out the old subscriptions.  We are getting new ones.
-                        mConnections.remove(b);
-
-                        final ConnectionRecord connection = new ConnectionRecord();
-                        connection.pkg = pkg;
-                        connection.rootHints = rootHints;
-                        connection.callbacks = callbacks;
-
-                        connection.root = MediaBrowserService.this.onGetRoot(pkg, uid, rootHints);
-
-                        // If they didn't return something, don't allow this client.
-                        if (connection.root == null) {
-                            Log.i(TAG, "No root for client " + pkg + " from service "
-                                    + getClass().getName());
-                            try {
-                                callbacks.onConnectFailed();
-                            } catch (RemoteException ex) {
-                                Log.w(TAG, "Calling onConnectFailed() failed. Ignoring. "
-                                        + "pkg=" + pkg);
-                            }
-                        } else {
-                            try {
-                                mConnections.put(b, connection);
-                                callbacks.onConnect(connection.root.getRootUri(),
-                                        mSession, connection.root.getExtras());
-                            } catch (RemoteException ex) {
-                                Log.w(TAG, "Calling onConnect() failed. Dropping client. "
-                                        + "pkg=" + pkg);
-                                mConnections.remove(b);
-                            }
-                        }
-                    }
-                });
-        }
-
-        @Override
-        public void disconnect(final IMediaBrowserServiceCallbacks callbacks) {
-            mHandler.post(new Runnable() {
-                    @Override
-                    public void run() {
-                        final IBinder b = callbacks.asBinder();
-
-                        // Clear out the old subscriptions.  We are getting new ones.
-                        final ConnectionRecord old = mConnections.remove(b);
-                        if (old != null) {
-                            // TODO
-                        }
-                    }
-                });
-        }
-
-
-        @Override
-        public void addSubscription(final Uri uri, final IMediaBrowserServiceCallbacks callbacks) {
-            mHandler.post(new Runnable() {
-                    @Override
-                    public void run() {
-                        final IBinder b = callbacks.asBinder();
-
-                        // Get the record for the connection
-                        final ConnectionRecord connection = mConnections.get(b);
-                        if (connection == null) {
-                            Log.w(TAG, "addSubscription for callback that isn't registered uri="
-                                + uri);
-                            return;
-                        }
-
-                        MediaBrowserService.this.addSubscription(uri, connection);
-                    }
-                });
-        }
-
-        @Override
-        public void removeSubscription(final Uri uri,
-                final IMediaBrowserServiceCallbacks callbacks) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    final IBinder b = callbacks.asBinder();
-
-                    ConnectionRecord connection = mConnections.get(b);
-                    if (connection == null) {
-                        Log.w(TAG, "removeSubscription for callback that isn't registered uri="
-                                + uri);
-                        return;
-                    }
-                    if (!connection.subscriptions.remove(uri)) {
-                        Log.w(TAG, "removeSubscription called for " + uri
-                                + " which is not subscribed");
-                    }
-                }
-            });
-        }
-
-        @Override
-        public void loadIcon(final int seq, final Uri uri, final int width, final int height,
-                final IMediaBrowserServiceCallbacks callbacks) {
-            if (uri == null) {
-                throw new IllegalStateException("loadIcon sent null list for uri " + uri);
-            }
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    // In theory we could return a result to a new connection, but in practice
-                    // the other side in MediaBrowser uses a new IMediaBrowserServiceCallbacks
-                    // object every time it calls connect(), so as long as it does that we won't
-                    // see results sent for the wrong connection.
-                    final ConnectionRecord connection = mConnections.get(callbacks.asBinder());
-                    if (connection == null) {
-                        if (DBG) {
-                            Log.d(TAG, "Not loading bitmap for invalid connection. uri=" + uri);
-                        }
-                        return;
-                    }
-
-                    final Result<Bitmap> result = new Result<Bitmap>(uri) {
-                        @Override
-                        void onResultSent(Bitmap bitmap) {
-                            if (mConnections.get(connection.callbacks.asBinder()) != connection) {
-                                if (DBG) {
-                                    Log.d(TAG, "Not sending onLoadIcon result for connection"
-                                            + " that has been disconnected. pkg=" + connection.pkg
-                                            + " uri=" + uri);
-                                }
-                                return;
-                            }
-
-                            try {
-                                callbacks.onLoadIcon(seq, bitmap);
-                            } catch (RemoteException e) {
-                                // The other side is in the process of crashing.
-                                Log.w(TAG, "RemoteException in calling onLoadIcon", e);
-                            }
-                        }
-                    };
-
-                    onLoadIcon(uri, width, height, result);
-
-                    if (!result.isDone()) {
-                        throw new IllegalStateException("onLoadIcon must call detach() or"
-                                + " sendResult() before returning for package=" + connection.pkg
-                                + " uri=" + uri);
-                    }
-                }
-            });
-        }
-    }
-
-    @Override
-    public void onCreate() {
-        super.onCreate();
-        mBinder = new ServiceBinder();
-    }
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        if (SERVICE_ACTION.equals(intent.getAction())) {
-            return mBinder;
-        }
-        return null;
-    }
-
-    @Override
-    public void dump(FileDescriptor fd, PrintWriter writer, String[] args) {
-    }
-
-    /**
-     * Called to get the root information for browsing by a particular client.
-     * <p>
-     * The implementation should verify that the client package has
-     * permission to access browse media information before returning
-     * the root uri; it should return null if the client is not
-     * allowed to access this information.
-     * </p>
-     *
-     * @param clientPackageName The package name of the application
-     * which is requesting access to browse media.
-     * @param clientUid The uid of the application which is requesting
-     * access to browse media.
-     * @param rootHints An optional bundle of service-specific arguments to send
-     * to the media browse service when connecting and retrieving the root uri
-     * for browsing, or null if none.  The contents of this bundle may affect
-     * the information returned when browsing.
-     */
-    public abstract @Nullable BrowserRoot onGetRoot(@NonNull String clientPackageName,
-            int clientUid, @Nullable Bundle rootHints);
-
-    /**
-     * Called to get information about the children of a media item.
-     * <p>
-     * Implementations must call result.{@link Result#sendResult result.sendResult} with the list
-     * of children. If loading the children will be an expensive operation that should be performed
-     * on another thread, result.{@link Result#detach result.detach} may be called before returning
-     * from this function, and then {@link Result#sendResult result.sendResult} called when
-     * the loading is complete.
-     *
-     * @param parentUri The uri of the parent media item whose
-     * children are to be queried.
-     * @return The list of children, or null if the uri is invalid.
-     */
-    public abstract void onLoadChildren(@NonNull Uri parentUri,
-            @NonNull Result<List<MediaBrowserItem>> result);
-
-    /**
-     * Called to get the icon of a particular media item.
-     * <p>
-     * Implementations must call result.{@link Result#sendResult result.sendResult} with the bitmap.
-     * If loading the bitmap will be an expensive operation that should be performed
-     * on another thread, result.{@link Result#detach result.detach} may be called before returning
-     * from this function, and then {@link Result#sendResult result.sendResult} called when
-     * the loading is complete.
-     *
-     * @param uri The uri of the media item.
-     * @param width The requested width of the icon in dp.
-     * @param height The requested height of the icon in dp.
-     *
-     * @return The file descriptor of the icon, which may then be loaded
-     *          using a bitmap factory, or null if the item does not have an icon.
-     */
-    public abstract void onLoadIcon(@NonNull Uri uri, int width, int height,
-            @NonNull Result<Bitmap> result);
-
-    /**
-     * Call to set the media session.
-     * <p>
-     * This must be called before onCreate returns.
-     *
-     * @return The media session token, must not be null.
-     */
-    public void setSessionToken(MediaSession.Token token) {
-        if (token == null) {
-            throw new IllegalStateException(this.getClass().getName()
-                    + ".onCreateSession() set invalid MediaSession.Token");
-        }
-        mSession = token;
-    }
-
-    /**
-     * Gets the session token, or null if it has not yet been created
-     * or if it has been destroyed.
-     */
-    public @Nullable MediaSession.Token getSessionToken() {
-        return mSession;
-    }
-
-    /**
-     * Notifies all connected media browsers that the children of
-     * the specified Uri have changed in some way.
-     * This will cause browsers to fetch subscribed content again.
-     *
-     * @param parentUri The uri of the parent media item whose
-     * children changed.
-     */
-    public void notifyChildrenChanged(@NonNull final Uri parentUri) {
-        if (parentUri == null) {
-            throw new IllegalArgumentException("parentUri cannot be null in notifyChildrenChanged");
-        }
-        mHandler.post(new Runnable() {
-            @Override
-            public void run() {
-                for (IBinder binder : mConnections.keySet()) {
-                    ConnectionRecord connection = mConnections.get(binder);
-                    if (connection.subscriptions.contains(parentUri)) {
-                        performLoadChildren(parentUri, connection);
-                    }
-                }
-            }
-        });
-    }
-
-    /**
-     * Return whether the given package is one of the ones that is owned by the uid.
-     */
-    private boolean isValidPackage(String pkg, int uid) {
-        if (pkg == null) {
-            return false;
-        }
-        final PackageManager pm = getPackageManager();
-        final String[] packages = pm.getPackagesForUid(uid);
-        final int N = packages.length;
-        for (int i=0; i<N; i++) {
-            if (packages[i].equals(pkg)) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Save the subscription and if it is a new subscription send the results.
-     */
-    private void addSubscription(Uri uri, ConnectionRecord connection) {
-        // Save the subscription
-        final boolean added = connection.subscriptions.add(uri);
-
-        // If this is a new subscription, send the results
-        if (added) {
-            performLoadChildren(uri, connection);
-        }
-    }
-
-    /**
-     * Call onLoadChildren and then send the results back to the connection.
-     * <p>
-     * Callers must make sure that this connection is still connected.
-     */
-    private void performLoadChildren(final Uri uri, final ConnectionRecord connection) {
-        final Result<List<MediaBrowserItem>> result = new Result<List<MediaBrowserItem>>(uri) {
-            @Override
-            void onResultSent(List<MediaBrowserItem> list) {
-                if (list == null) {
-                    throw new IllegalStateException("onLoadChildren sent null list for uri " + uri);
-                }
-                if (mConnections.get(connection.callbacks.asBinder()) != connection) {
-                    if (DBG) {
-                        Log.d(TAG, "Not sending onLoadChildren result for connection that has"
-                                + " been disconnected. pkg=" + connection.pkg + " uri=" + uri);
-                    }
-                    return;
-                }
-
-                final ParceledListSlice<MediaBrowserItem> pls = new ParceledListSlice(list);
-                try {
-                    connection.callbacks.onLoadChildren(uri, pls);
-                } catch (RemoteException ex) {
-                    // The other side is in the process of crashing.
-                    Log.w(TAG, "Calling onLoadChildren() failed for uri=" + uri
-                            + " package=" + connection.pkg);
-                }
-            }
-        };
-
-        onLoadChildren(uri, result);
-
-        if (!result.isDone()) {
-            throw new IllegalStateException("onLoadChildren must call detach() or sendResult()"
-                    + " before returning for package=" + connection.pkg + " uri=" + uri);
-        }
-    }
-
-    /**
-     * Contains information that the browser service needs to send to the client
-     * when first connected.
-     */
-    public static final class BrowserRoot {
-        final private Uri mUri;
-        final private Bundle mExtras;
-
-        /**
-         * Constructs a browser root.
-         * @param uri The root Uri for browsing.
-         * @param extras Any extras about the browser service.
-         */
-        public BrowserRoot(@NonNull Uri uri, @Nullable Bundle extras) {
-            if (uri == null) {
-                throw new IllegalArgumentException("The root uri in BrowserRoot cannot be null. " +
-                        "Use null for BrowserRoot instead.");
-            }
-            mUri = uri;
-            mExtras = extras;
-        }
-
-        /**
-         * Gets the root uri for browsing.
-         */
-        public Uri getRootUri() {
-            return mUri;
-        }
-
-        /**
-         * Gets any extras about the brwoser service.
-         */
-        public Bundle getExtras() {
-            return mExtras;
-        }
-    }
-}
diff --git a/media/java/android/media/projection/IMediaProjection.aidl b/media/java/android/media/projection/IMediaProjection.aidl
index 3d25aa6..19fc052 100644
--- a/media/java/android/media/projection/IMediaProjection.aidl
+++ b/media/java/android/media/projection/IMediaProjection.aidl
@@ -26,6 +26,6 @@
     boolean canProjectVideo();
     boolean canProjectSecureVideo();
     int applyVirtualDisplayFlags(int flags);
-    void addCallback(IMediaProjectionCallback callback);
-    void removeCallback(IMediaProjectionCallback callback);
+    void registerCallback(IMediaProjectionCallback callback);
+    void unregisterCallback(IMediaProjectionCallback callback);
 }
diff --git a/media/java/android/media/projection/IMediaProjectionManager.aidl b/media/java/android/media/projection/IMediaProjectionManager.aidl
index 6ed803a..7e10c51 100644
--- a/media/java/android/media/projection/IMediaProjectionManager.aidl
+++ b/media/java/android/media/projection/IMediaProjectionManager.aidl
@@ -17,6 +17,9 @@
 package android.media.projection;
 
 import android.media.projection.IMediaProjection;
+import android.media.projection.IMediaProjectionCallback;
+import android.media.projection.IMediaProjectionWatcherCallback;
+import android.media.projection.MediaProjectionInfo;
 import android.os.IBinder;
 
 /** {@hide} */
@@ -25,4 +28,8 @@
     IMediaProjection createProjection(int uid, String packageName, int type,
             boolean permanentGrant);
     boolean isValidMediaProjection(IMediaProjection projection);
+    MediaProjectionInfo getActiveProjectionInfo();
+    void stopActiveProjection();
+    void addCallback(IMediaProjectionWatcherCallback callback);
+    void removeCallback(IMediaProjectionWatcherCallback callback);
 }
diff --git a/media/java/android/media/projection/IMediaProjectionWatcherCallback.aidl b/media/java/android/media/projection/IMediaProjectionWatcherCallback.aidl
new file mode 100644
index 0000000..2231ce1
--- /dev/null
+++ b/media/java/android/media/projection/IMediaProjectionWatcherCallback.aidl
@@ -0,0 +1,25 @@
+/*
+ * Copyright (C) 2014 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 android.media.projection;
+
+import android.media.projection.MediaProjectionInfo;
+
+/** {@hide} */
+oneway interface IMediaProjectionWatcherCallback {
+    void onStart(in MediaProjectionInfo info);
+    void onStop(in MediaProjectionInfo info);
+}
diff --git a/media/java/android/media/projection/MediaProjection.java b/media/java/android/media/projection/MediaProjection.java
index 99d3ceb..e6dadf9 100644
--- a/media/java/android/media/projection/MediaProjection.java
+++ b/media/java/android/media/projection/MediaProjection.java
@@ -40,7 +40,7 @@
  *
  * <p>
  * A screen capture session can be started through {@link
- * MediaProjectionManager#getScreenCaptureIntent}. This grants the ability to
+ * MediaProjectionManager#createScreenCaptureIntent}. This grants the ability to
  * capture screen contents, but not system audio.
  * </p>
  */
@@ -70,9 +70,9 @@
      * @param handler The handler on which the callback should be invoked, or
      * null if the callback should be invoked on the calling thread's looper.
      *
-     * @see #removeCallback
+     * @see #unregisterCallback
      */
-    public void addCallback(Callback callback, Handler handler) {
+    public void registerCallback(Callback callback, Handler handler) {
         if (callback == null) {
             throw new IllegalArgumentException("callback should not be null");
         }
@@ -83,9 +83,9 @@
      *
      * @param callback The callback to unregister.
      *
-     * @see #addCallback
+     * @see #registerCallback
      */
-    public void removeCallback(Callback callback) {
+    public void unregisterCallback(Callback callback) {
         if (callback == null) {
             throw new IllegalArgumentException("callback should not be null");
         }
@@ -97,12 +97,12 @@
      */
     public VirtualDisplay createVirtualDisplay(@NonNull String name,
             int width, int height, int dpi, boolean isSecure, @Nullable Surface surface,
-            @Nullable VirtualDisplay.Callbacks callbacks, @Nullable Handler handler) {
+            @Nullable VirtualDisplay.Callback callback, @Nullable Handler handler) {
         DisplayManager dm = (DisplayManager) mContext.getSystemService(Context.DISPLAY_SERVICE);
         int flags = isSecure ? DisplayManager.VIRTUAL_DISPLAY_FLAG_SECURE : 0;
         return dm.createVirtualDisplay(this, name, width, height, dpi, surface,
                     flags | DisplayManager.VIRTUAL_DISPLAY_FLAG_AUTO_MIRROR |
-                    DisplayManager.VIRTUAL_DISPLAY_FLAG_PRESENTATION, callbacks, handler);
+                    DisplayManager.VIRTUAL_DISPLAY_FLAG_PRESENTATION, callback, handler);
     }
 
     /**
@@ -120,21 +120,21 @@
      * should be rendered, or null if there is none initially.
      * @param flags A combination of virtual display flags. See {@link DisplayManager} for the full
      * list of flags.
-     * @param callbacks Callbacks to call when the virtual display's state
+     * @param callback Callback to call when the virtual display's state
      * changes, or null if none.
      * @param handler The {@link android.os.Handler} on which the callback should be
      * invoked, or null if the callback should be invoked on the calling
      * thread's main {@link android.os.Looper}.
      *
      * @see android.hardware.display.DisplayManager#createVirtualDisplay(
-     * String, int, int, int, int, Surface, VirtualDisplay.Callbacks, Handler)
+     * String, int, int, int, int, Surface, VirtualDisplay.Callback, Handler)
      */
     public VirtualDisplay createVirtualDisplay(@NonNull String name,
             int width, int height, int dpi, int flags, @Nullable Surface surface,
-            @Nullable VirtualDisplay.Callbacks callbacks, @Nullable Handler handler) {
+            @Nullable VirtualDisplay.Callback callback, @Nullable Handler handler) {
         DisplayManager dm = (DisplayManager) mContext.getSystemService(Context.DISPLAY_SERVICE);
         return dm.createVirtualDisplay(
-                    this, name, width, height, dpi, surface, flags, callbacks, handler);
+                    this, name, width, height, dpi, surface, flags, callback, handler);
     }
 
     /**
diff --git a/media/java/android/media/projection/MediaProjectionInfo.aidl b/media/java/android/media/projection/MediaProjectionInfo.aidl
new file mode 100644
index 0000000..3c8f9b6
--- /dev/null
+++ b/media/java/android/media/projection/MediaProjectionInfo.aidl
@@ -0,0 +1,19 @@
+/**
+ * Copyright (c) 2014, 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 android.media.projection;
+
+parcelable MediaProjectionInfo;
diff --git a/media/java/android/media/projection/MediaProjectionInfo.java b/media/java/android/media/projection/MediaProjectionInfo.java
new file mode 100644
index 0000000..5a65e65
--- /dev/null
+++ b/media/java/android/media/projection/MediaProjectionInfo.java
@@ -0,0 +1,93 @@
+/*
+ * Copyright (C) 2014 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 android.media.projection;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.os.UserHandle;
+
+import java.util.Objects;
+
+/** @hide */
+public final class MediaProjectionInfo implements Parcelable {
+    private final String mPackageName;
+    private final UserHandle mUserHandle;
+
+    public MediaProjectionInfo(String packageName, UserHandle handle) {
+        mPackageName = packageName;
+        mUserHandle = handle;
+    }
+
+    public MediaProjectionInfo(Parcel in) {
+        mPackageName = in.readString();
+        mUserHandle = UserHandle.readFromParcel(in);
+    }
+
+    public String getPackageName() {
+        return mPackageName;
+    }
+
+    public UserHandle getUserHandle() {
+        return mUserHandle;
+    }
+
+    @Override
+    public boolean equals(Object o) {
+        if (o instanceof MediaProjectionInfo) {
+            final MediaProjectionInfo other = (MediaProjectionInfo) o;
+            return Objects.equals(other.mPackageName, mPackageName)
+                    && Objects.equals(other.mUserHandle, mUserHandle);
+        }
+        return false;
+    }
+
+    @Override
+    public int hashCode() {
+        return Objects.hash(mPackageName, mUserHandle);
+    }
+
+    @Override
+    public String toString() {
+        return "MediaProjectionInfo{mPackageName="
+            + mPackageName + ", mUserHandle="
+            + mUserHandle + "}";
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeString(mPackageName);
+        UserHandle.writeToParcel(mUserHandle, out);
+    }
+
+    public static final Parcelable.Creator<MediaProjectionInfo> CREATOR =
+            new Parcelable.Creator<MediaProjectionInfo>() {
+        @Override
+        public MediaProjectionInfo createFromParcel(Parcel in) {
+            return new MediaProjectionInfo (in);
+        }
+
+        @Override
+        public MediaProjectionInfo[] newArray(int size) {
+            return new MediaProjectionInfo[size];
+        }
+    };
+}
diff --git a/media/java/android/media/projection/MediaProjectionManager.java b/media/java/android/media/projection/MediaProjectionManager.java
index aac8cf9..a1cfc35 100644
--- a/media/java/android/media/projection/MediaProjectionManager.java
+++ b/media/java/android/media/projection/MediaProjectionManager.java
@@ -17,12 +17,20 @@
 package android.media.projection;
 
 import android.annotation.NonNull;
+import android.annotation.Nullable;
 import android.app.Activity;
 import android.content.Context;
 import android.content.Intent;
 import android.media.projection.IMediaProjection;
 import android.os.Binder;
+import android.os.Handler;
 import android.os.IBinder;
+import android.os.RemoteException;
+import android.os.ServiceManager;
+import android.util.ArrayMap;
+import android.util.Log;
+
+import java.util.Map;
 
 /**
  * Manages the retrieval of certain types of {@link MediaProjection} tokens.
@@ -35,6 +43,7 @@
  * </p>
  */
 public final class MediaProjectionManager {
+    private static final String TAG = "MediaProjectionManager";
     /** @hide */
     public static final String EXTRA_APP_TOKEN = "android.media.projection.extra.EXTRA_APP_TOKEN";
     /** @hide */
@@ -49,10 +58,15 @@
     public static final int TYPE_PRESENTATION = 2;
 
     private Context mContext;
+    private Map<Callback, CallbackDelegate> mCallbacks;
+    private IMediaProjectionManager mService;
 
     /** @hide */
     public MediaProjectionManager(Context context) {
         mContext = context;
+        IBinder b = ServiceManager.getService(Context.MEDIA_PROJECTION_SERVICE);
+        mService = IMediaProjectionManager.Stub.asInterface(b);
+        mCallbacks = new ArrayMap<>();
     }
 
     /**
@@ -61,7 +75,7 @@
      * the user whether to allow screen capture.  The result of this
      * activity should be passed to getMediaProjection.
      */
-    public Intent getScreenCaptureIntent() {
+    public Intent createScreenCaptureIntent() {
         Intent i = new Intent();
         i.setClassName("com.android.systemui",
                 "com.android.systemui.media.MediaProjectionPermissionActivity");
@@ -88,4 +102,105 @@
         }
         return new MediaProjection(mContext, IMediaProjection.Stub.asInterface(projection));
     }
+
+    /**
+     * Get the {@link MediaProjectionInfo} for the active {@link MediaProjection}.
+     * @hide
+     */
+    public MediaProjectionInfo getActiveProjectionInfo() {
+        try {
+            return mService.getActiveProjectionInfo();
+        } catch (RemoteException e) {
+            Log.e(TAG, "Unable to get the active projection info", e);
+        }
+        return null;
+    }
+
+    /**
+     * Stop the current projection if there is one.
+     * @hide
+     */
+    public void stopActiveProjection() {
+        try {
+            mService.stopActiveProjection();
+        } catch (RemoteException e) {
+            Log.e(TAG, "Unable to stop the currently active media projection", e);
+        }
+    }
+
+    /**
+     * Add a callback to monitor all of the {@link MediaProjection}s activity.
+     * Not for use by regular applications, must have the MANAGE_MEDIA_PROJECTION permission.
+     * @hide
+     */
+    public void addCallback(@NonNull Callback callback, @Nullable Handler handler) {
+        if (callback == null) {
+            throw new IllegalArgumentException("callback must not be null");
+        }
+        CallbackDelegate delegate = new CallbackDelegate(callback, handler);
+        mCallbacks.put(callback, delegate);
+        try {
+            mService.addCallback(delegate);
+        } catch (RemoteException e) {
+            Log.e(TAG, "Unable to add callbacks to MediaProjection service", e);
+        }
+    }
+
+    /**
+     * Remove a MediaProjection monitoring callback.
+     * @hide
+     */
+    public void removeCallback(@NonNull Callback callback) {
+        if (callback == null) {
+            throw new IllegalArgumentException("callback must not be null");
+        }
+        CallbackDelegate delegate = mCallbacks.remove(callback);
+        try {
+            if (delegate != null) {
+                mService.removeCallback(delegate);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Unable to add callbacks to MediaProjection service", e);
+        }
+    }
+
+    /** @hide */
+    public static abstract class Callback {
+        public abstract void onStart(MediaProjectionInfo info);
+        public abstract void onStop(MediaProjectionInfo info);
+    }
+
+    /** @hide */
+    private final static class CallbackDelegate extends IMediaProjectionWatcherCallback.Stub {
+        private Callback mCallback;
+        private Handler mHandler;
+
+        public CallbackDelegate(Callback callback, Handler handler) {
+            mCallback = callback;
+            if (handler == null) {
+                handler = new Handler();
+            }
+            mHandler = handler;
+        }
+
+        @Override
+        public void onStart(final MediaProjectionInfo info) {
+            mHandler.post(new Runnable() {
+                @Override
+                public void run() {
+                    mCallback.onStart(info);
+                }
+            });
+        }
+
+        @Override
+        public void onStop(final MediaProjectionInfo info) {
+            mHandler.post(new Runnable() {
+                @Override
+                public void run() {
+                    mCallback.onStop(info);
+                }
+            });
+        }
+    }
 }
diff --git a/media/java/android/media/routing/IMediaRouteClientCallback.aidl b/media/java/android/media/routing/IMediaRouteClientCallback.aidl
deleted file mode 100644
index d90ea3b..0000000
--- a/media/java/android/media/routing/IMediaRouteClientCallback.aidl
+++ /dev/null
@@ -1,41 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-import android.media.routing.MediaRouteSelector;
-import android.media.routing.ParcelableConnectionInfo;
-import android.media.routing.ParcelableDestinationInfo;
-import android.media.routing.ParcelableRouteInfo;
-import android.os.IBinder;
-import android.os.Bundle;
-
-/**
- * @hide
- */
-oneway interface IMediaRouteClientCallback {
-    void onDestinationFound(int seq, in ParcelableDestinationInfo destination,
-            in ParcelableRouteInfo[] routes);
-
-    void onDestinationLost(int seq, String id);
-
-    void onDiscoveryFailed(int seq, int error, in CharSequence message, in Bundle extras);
-
-    void onConnected(int seq, in ParcelableConnectionInfo connection);
-
-    void onDisconnected(int seq);
-
-    void onConnectionFailed(int seq, int error, in CharSequence message, in Bundle extras);
-}
diff --git a/media/java/android/media/routing/IMediaRouteService.aidl b/media/java/android/media/routing/IMediaRouteService.aidl
deleted file mode 100644
index 493ab6d..0000000
--- a/media/java/android/media/routing/IMediaRouteService.aidl
+++ /dev/null
@@ -1,46 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-import android.media.routing.IMediaRouteClientCallback;
-import android.media.routing.MediaRouteSelector;
-import android.os.Bundle;
-
-/**
- * Interface to an app's MediaRouteService.
- * @hide
- */
-oneway interface IMediaRouteService {
-    void registerClient(int clientUid, String clientPackageName,
-            in IMediaRouteClientCallback callback);
-
-    void unregisterClient(in IMediaRouteClientCallback callback);
-
-    void startDiscovery(in IMediaRouteClientCallback callback, int seq,
-            in List<MediaRouteSelector> selectors, int flags);
-
-    void stopDiscovery(in IMediaRouteClientCallback callback);
-
-    void connect(in IMediaRouteClientCallback callback, int seq,
-            String destinationId, String routeId, int flags, in Bundle extras);
-
-    void disconnect(in IMediaRouteClientCallback callback);
-
-    void pauseStream(in IMediaRouteClientCallback callback);
-
-    void resumeStream(in IMediaRouteClientCallback callback);
-}
-
diff --git a/media/java/android/media/routing/IMediaRouter.aidl b/media/java/android/media/routing/IMediaRouter.aidl
deleted file mode 100644
index 0abb258..0000000
--- a/media/java/android/media/routing/IMediaRouter.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-/** @hide */
-interface IMediaRouter {
-
-}
-
diff --git a/media/java/android/media/routing/IMediaRouterDelegate.aidl b/media/java/android/media/routing/IMediaRouterDelegate.aidl
deleted file mode 100644
index 35f84c8..0000000
--- a/media/java/android/media/routing/IMediaRouterDelegate.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-/** @hide */
-interface IMediaRouterDelegate {
-
-}
-
diff --git a/media/java/android/media/routing/IMediaRouterRoutingCallback.aidl b/media/java/android/media/routing/IMediaRouterRoutingCallback.aidl
deleted file mode 100644
index 173ae55..0000000
--- a/media/java/android/media/routing/IMediaRouterRoutingCallback.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-/** @hide */
-interface IMediaRouterRoutingCallback {
-
-}
-
diff --git a/media/java/android/media/routing/IMediaRouterStateCallback.aidl b/media/java/android/media/routing/IMediaRouterStateCallback.aidl
deleted file mode 100644
index 0299904..0000000
--- a/media/java/android/media/routing/IMediaRouterStateCallback.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/* Copyright (C) 2014 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 android.media.routing;
-
-/** @hide */
-interface IMediaRouterStateCallback {
-
-}
-
diff --git a/media/java/android/media/routing/MediaRouteSelector.aidl b/media/java/android/media/routing/MediaRouteSelector.aidl
deleted file mode 100644
index 37bfa4a..0000000
--- a/media/java/android/media/routing/MediaRouteSelector.aidl
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Copyright 2014, 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 android.media.routing;
-
-parcelable MediaRouteSelector;
diff --git a/media/java/android/media/routing/MediaRouteSelector.java b/media/java/android/media/routing/MediaRouteSelector.java
deleted file mode 100644
index 26a9b1c..0000000
--- a/media/java/android/media/routing/MediaRouteSelector.java
+++ /dev/null
@@ -1,357 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.media.routing.MediaRouter.RouteFeatures;
-import android.os.Bundle;
-import android.os.IInterface;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.text.TextUtils;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * A media route selector consists of a set of constraints that are used to select
- * the routes to which an application would like to connect.  The constraints consist
- * of a set of required or optional features and protocols.  The constraints may also
- * require the use of a specific media route service package or additional characteristics
- * that are described by a bundle of extra parameters.
- * <p>
- * The application will typically create several different selectors that express
- * various combinations of characteristics that it would like to use together when
- * it connects to a destination media device.  For each destination that is discovered,
- * media route services will publish some number of routes and include information
- * about which selector each route matches.  The application will then choose among
- * these routes to determine which best satisfies its desired purpose and connect to it.
- * </p>
- */
-public final class MediaRouteSelector implements Parcelable {
-    private final int mRequiredFeatures;
-    private final int mOptionalFeatures;
-    private final List<String> mRequiredProtocols;
-    private final List<String> mOptionalProtocols;
-    private final String mServicePackageName;
-    private final Bundle mExtras;
-
-    MediaRouteSelector(int requiredFeatures, int optionalFeatures,
-            List<String> requiredProtocols, List<String> optionalProtocols,
-            String servicePackageName, Bundle extras) {
-        mRequiredFeatures = requiredFeatures;
-        mOptionalFeatures = optionalFeatures;
-        mRequiredProtocols = requiredProtocols;
-        mOptionalProtocols = optionalProtocols;
-        mServicePackageName = servicePackageName;
-        mExtras = extras;
-    }
-
-    /**
-     * Gets the set of required route features.
-     *
-     * @return A set of required route feature flags.
-     */
-    public @RouteFeatures int getRequiredFeatures() {
-        return mRequiredFeatures;
-    }
-
-    /**
-     * Gets the set of optional route features.
-     *
-     * @return A set of optional route feature flags.
-     */
-    public @RouteFeatures int getOptionalFeatures() {
-        return mOptionalFeatures;
-    }
-
-    /**
-     * Gets the list of route protocols that a route must support in order to be selected.
-     * <p>
-     * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-     * for more information.
-     * </p>
-     *
-     * @return The list of fully qualified route protocol names.
-     */
-    public @NonNull List<String> getRequiredProtocols() {
-        return mRequiredProtocols;
-    }
-
-    /**
-     * Gets the list of optional route protocols that a client may use if they are available.
-     * <p>
-     * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-     * for more information.
-     * </p>
-     *
-     * @return The list of optional fully qualified route protocol names.
-     */
-    public @NonNull List<String> getOptionalProtocols() {
-        return mOptionalProtocols;
-    }
-
-    /**
-     * Returns true if the selector includes a required or optional request for
-     * the specified protocol using its fully qualified class name.
-     * <p>
-     * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-     * for more information.
-     * </p>
-     *
-     * @param clazz The protocol class.
-     * @return True if the protocol was requested.
-     */
-    public boolean containsProtocol(@NonNull Class<?> clazz) {
-        return containsProtocol(clazz.getName());
-    }
-
-    /**
-     * Returns true if the selector includes a required or optional request for
-     * the specified protocol.
-     * <p>
-     * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-     * for more information.
-     * </p>
-     *
-     * @param name The name of the protocol.
-     * @return True if the protocol was requested.
-     */
-    public boolean containsProtocol(@NonNull String name) {
-        return mRequiredProtocols.contains(name)
-                || mOptionalProtocols.contains(name);
-    }
-
-    /**
-     * Gets the package name of a specific media route service that this route selector
-     * requires.
-     *
-     * @return The required media route service package name, or null if none.
-     */
-    public @Nullable String getServicePackageName() {
-        return mServicePackageName;
-    }
-
-    /**
-     * Gets optional extras that may be used to select or configure routes for a
-     * particular purpose.  Some extras may be used by media route services to apply
-     * additional constraints or parameters for the routes to be discovered.
-     *
-     * @return The optional extras, or null if none.
-     */
-    public @Nullable Bundle getExtras() {
-        return mExtras;
-    }
-
-    @Override
-    public String toString() {
-        return "MediaRouteSelector{ "
-                + ", requiredFeatures=0x" + Integer.toHexString(mRequiredFeatures)
-                + ", optionalFeatures=0x" + Integer.toHexString(mOptionalFeatures)
-                + ", requiredProtocols=" + mRequiredProtocols
-                + ", optionalProtocols=" + mOptionalProtocols
-                + ", servicePackageName=" + mServicePackageName
-                + ", extras=" + mExtras + " }";
-    }
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeInt(mRequiredFeatures);
-        dest.writeInt(mOptionalFeatures);
-        dest.writeStringList(mRequiredProtocols);
-        dest.writeStringList(mOptionalProtocols);
-        dest.writeString(mServicePackageName);
-        dest.writeBundle(mExtras);
-    }
-
-    public static final Parcelable.Creator<MediaRouteSelector> CREATOR =
-            new Parcelable.Creator<MediaRouteSelector>() {
-        @Override
-        public MediaRouteSelector createFromParcel(Parcel source) {
-            int requiredFeatures = source.readInt();
-            int optionalFeatures = source.readInt();
-            ArrayList<String> requiredProtocols = new ArrayList<String>();
-            ArrayList<String> optionalProtocols = new ArrayList<String>();
-            source.readStringList(requiredProtocols);
-            source.readStringList(optionalProtocols);
-            return new MediaRouteSelector(requiredFeatures, optionalFeatures,
-                    requiredProtocols, optionalProtocols,
-                    source.readString(), source.readBundle());
-        }
-
-        @Override
-        public MediaRouteSelector[] newArray(int size) {
-            return new MediaRouteSelector[size];
-        }
-    };
-
-    /**
-     * Builder for {@link MediaRouteSelector} objects.
-     */
-    public static final class Builder {
-        private int mRequiredFeatures;
-        private int mOptionalFeatures;
-        private final ArrayList<String> mRequiredProtocols = new ArrayList<String>();
-        private final ArrayList<String> mOptionalProtocols = new ArrayList<String>();
-        private String mServicePackageName;
-        private Bundle mExtras;
-
-        /**
-         * Creates an initially empty selector builder.
-         */
-        public Builder() {
-        }
-
-        /**
-         * Sets the set of required route features.
-         *
-         * @param features A set of required route feature flags.
-         */
-        public @NonNull Builder setRequiredFeatures(@RouteFeatures int features) {
-            mRequiredFeatures = features;
-            return this;
-        }
-
-        /**
-         * Sets the set of optional route features.
-         *
-         * @param features A set of optional route feature flags.
-         */
-        public @NonNull Builder setOptionalFeatures(@RouteFeatures int features) {
-            mOptionalFeatures = features;
-            return this;
-        }
-
-        /**
-         * Adds a route protocol that a route must support in order to be selected
-         * using its fully qualified class name.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         *
-         * @param clazz The protocol class.
-         * @return this
-         */
-        public @NonNull Builder addRequiredProtocol(@NonNull Class<?> clazz) {
-            if (clazz == null) {
-                throw new IllegalArgumentException("clazz must not be null");
-            }
-            return addRequiredProtocol(clazz.getName());
-        }
-
-        /**
-         * Adds a route protocol that a route must support in order to be selected.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         *
-         * @param name The fully qualified name of the required protocol.
-         * @return this
-         */
-        public @NonNull Builder addRequiredProtocol(@NonNull String name) {
-            if (TextUtils.isEmpty(name)) {
-                throw new IllegalArgumentException("name must not be null or empty");
-            }
-            mRequiredProtocols.add(name);
-            return this;
-        }
-
-        /**
-         * Adds an optional route protocol that a client may use if available
-         * using its fully qualified class name.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         *
-         * @param clazz The protocol class.
-         * @return this
-         */
-        public @NonNull Builder addOptionalProtocol(@NonNull Class<?> clazz) {
-            if (clazz == null) {
-                throw new IllegalArgumentException("clazz must not be null");
-            }
-            return addOptionalProtocol(clazz.getName());
-        }
-
-        /**
-         * Adds an optional route protocol that a client may use if available.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         *
-         * @param name The fully qualified name of the optional protocol.
-         * @return this
-         */
-        public @NonNull Builder addOptionalProtocol(@NonNull String name) {
-            if (TextUtils.isEmpty(name)) {
-                throw new IllegalArgumentException("name must not be null or empty");
-            }
-            mOptionalProtocols.add(name);
-            return this;
-        }
-
-        /**
-         * Sets the package name of the media route service to which this selector
-         * appertains.
-         * <p>
-         * If a package name is specified here then this selector will only be
-         * passed to media route services from that package.  This has the effect
-         * of restricting the set of matching routes to just those that are offered
-         * by that package.
-         * </p>
-         *
-         * @param packageName The required service package name, or null if none.
-         * @return this
-         */
-        public @NonNull Builder setServicePackageName(@Nullable String packageName) {
-            mServicePackageName = packageName;
-            return this;
-        }
-
-        /**
-         * Sets optional extras that may be used to select or configure routes for a
-         * particular purpose.  Some extras may be used by route services to specify
-         * additional constraints or parameters for the routes to be discovered.
-         *
-         * @param extras The optional extras, or null if none.
-         * @return this
-         */
-        public @NonNull Builder setExtras(@Nullable Bundle extras) {
-            mExtras = extras;
-            return this;
-        }
-
-        /**
-         * Builds the {@link MediaRouteSelector} object.
-         *
-         * @return The new media route selector instance.
-         */
-        public @NonNull MediaRouteSelector build() {
-            return new MediaRouteSelector(mRequiredFeatures, mOptionalFeatures,
-                    mRequiredProtocols, mOptionalProtocols, mServicePackageName, mExtras);
-        }
-    }
-}
diff --git a/media/java/android/media/routing/MediaRouteService.java b/media/java/android/media/routing/MediaRouteService.java
deleted file mode 100644
index 4d5a8a9..0000000
--- a/media/java/android/media/routing/MediaRouteService.java
+++ /dev/null
@@ -1,1023 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.annotation.SdkConstant;
-import android.app.Service;
-import android.content.Intent;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.media.routing.MediaRouter.ConnectionError;
-import android.media.routing.MediaRouter.ConnectionInfo;
-import android.media.routing.MediaRouter.ConnectionRequest;
-import android.media.routing.MediaRouter.DestinationInfo;
-import android.media.routing.MediaRouter.DiscoveryError;
-import android.media.routing.MediaRouter.DiscoveryRequest;
-import android.media.routing.MediaRouter.RouteInfo;
-import android.media.routing.MediaRouter.ServiceMetadata;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.RemoteException;
-import android.util.ArrayMap;
-import android.util.Log;
-
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Media route services implement strategies for discovering
- * and establishing connections to media devices and their routes.  These services
- * are also known as media route providers.
- * <p>
- * Each media route service subclass is responsible for enabling applications
- * and the system to interact with media devices of some kind.
- * For example, one particular media route service implementation might
- * offer support for discovering nearby wireless display devices and streaming
- * video contents to them; another media route service implementation might
- * offer support for discovering nearby speakers and streaming media appliances
- * and sending commands to play content on request.
- * </p><p>
- * Subclasses must override the {@link #onCreateClientSession} method to return
- * a {@link ClientSession} object that implements the {@link ClientSession#onStartDiscovery},
- * {@link ClientSession#onStopDiscovery}, and {@link ClientSession#onConnect} methods
- * to allow clients to discover and connect to media devices.
- * </p><p>
- * This object is not thread-safe.  All callbacks are invoked on the main looper.
- * </p>
- *
- * <h3>Clients</h3>
- * <p>
- * The clients of this API are media applications that would like to discover
- * and connect to media devices.  The client may also be the system, such as
- * when the user initiates display mirroring via the Cast Screen function.
- * </p><p>
- * There may be multiple client sessions active at the same time.  Each client
- * session can request discovery and connect to routes independently of any
- * other client.  It is the responsibility of the media route service to maintain
- * separate state for each client session and to ensure that clients cannot interfere
- * with one another in harmful ways.
- * </p><p>
- * Notwithstanding the requirement to support any number of concurrent client
- * sessions, the media route service may impose constraints on how many clients
- * can connect to the same media device in a particular mode at the same time.
- * In some cases, media devices may support connections from an arbitrary number
- * of clients simultaneously but often it may be necessary to ensure that only
- * one client is in control.  When this happens, the media route service should
- * report a connection error unless the connection request specifies that the
- * client should take control of the media device (and forcibly disconnect other
- * clients that may be using it).
- * </p>
- *
- * <h3>Destinations</h3>
- * <p>
- * The media devices to which an application may send media content are referred
- * to in the API as destinations.  Each destination therefore represents a single
- * independent device such as a speaker or TV set.  Destinations are given meaningful
- * names and descriptions to help the user associate them with devices in their
- * environment.
- * </p><p>
- * Destinations may be local or remote and may be accessed through various means,
- * often wirelessly.  The user may install media route services to enable
- * media applications to connect to a variety of destinations with different
- * capabilities.
- * </p>
- *
- * <h3>Routes</h3>
- * <p>
- * Routes represent possible usages or means of reaching and interacting with
- * a destination.  Since destinations may support many different features, they may
- * each offer multiple routes for applications to choose from based on their needs.
- * For example, one route might express the ability to stream locally rendered audio
- * and video to the device; another route might express the ability to send a URL for
- * the destination to download from the network and play all by itself.
- * </p><p>
- * Routes are discovered according to the set of capabilities that
- * an application or the system is seeking to use at a particular time.  For example,
- * if an application wants to stream music to a destination then it will ask the
- * {@link MediaRouter} to find routes to destinations can stream music and ignore
- * all other destinations that cannot.
- * </p><p>
- * In general, the application will inspect the set of routes that have been
- * offered then connect to the most appropriate route for its desired purpose.
- * </p>
- *
- * <h3>Discovery</h3>
- * <p>
- * Discovery is the process of finding destinations based on a description of the
- * kinds of routes that an application or the system would like to use.
- * </p><p>
- * Discovery begins when {@link ClientSession#onStartDiscovery} is called and ends when
- * {@link ClientSession#onStopDiscovery} is called.  There may be multiple simultaneous
- * discovery requests in progress at the same time from different clients.  It is up to
- * the media route service to perform these requests in parallel or multiplex them
- * as required.
- * </p><p>
- * Media route services are <em>strongly encouraged</em> to use the information
- * in the discovery request to optimize discovery and avoid redundant work.
- * In the case where no media device supported by the media route service
- * could possibly offer the requested capabilities, the
- * {@link ClientSession#onStartDiscovery} method should return <code>false</code> to
- * let the system know that it can unbind from the media route service and
- * release its resources.
- * </p>
- *
- * <h3>Settings</h3>
- * <p>
- * Many kinds of devices can be discovered on demand simply by scanning the local network
- * or using wireless protocols such as Bluetooth to find them.  However, in some cases
- * it may be necessary for the user to manually configure destinations before they
- * can be used (or to adjust settings later).  Actual user configuration of destinations
- * is beyond the scope of this API but media route services may specify an activity
- * in their manifest that the user can launch to perform these tasks.
- * </p><p>
- * Note that media route services that are installed from the store must be enabled
- * by the user before they become available for applications to use.
- * The {@link android.provider.Settings#ACTION_CAST_SETTINGS Settings.ACTION_CAST_SETTINGS}
- * settings activity provides the ability for the user to configure media route services.
- * </p>
- *
- * <h3>Manifest Declaration</h3>
- * <p>
- * Media route services must be declared in the manifest along with meta-data
- * about the kinds of routes that they are capable of discovering.  The system
- * uses this information to optimize the set of services to which it binds in
- * order to satisfy a particular discovery request.
- * </p><p>
- * To extend this class, you must declare the service in your manifest file with
- * the {@link android.Manifest.permission#BIND_MEDIA_ROUTE_SERVICE} permission
- * and include an intent filter with the {@link #SERVICE_INTERFACE} action.  You must
- * also add meta-data to describe the kinds of routes that your service is capable
- * of discovering.
- * </p><p>
- * For example:
- * </p><pre>
- * &lt;service android:name=".MediaRouteProvider"
- *          android:label="&#64;string/service_name"
- *          android:permission="android.permission.BIND_MEDIA_ROUTE_SERVICE">
- *     &lt;intent-filter>
- *         &lt;action android:name="android.media.routing.MediaRouteService" />
- *     &lt;/intent-filter>
- *
- *     TODO: INSERT METADATA DECLARATIONS HERE
- *
- * &lt;/service>
- * </pre>
- */
-public abstract class MediaRouteService extends Service {
-    private static final String TAG = "MediaRouteService";
-
-    private static final boolean DEBUG = true;
-
-    private final Handler mHandler;
-    private final BinderService mService;
-    private final ArrayMap<IBinder, ClientRecord> mClientRecords =
-            new ArrayMap<IBinder, ClientRecord>();
-
-    private ServiceMetadata mMetadata;
-
-    /**
-     * The {@link Intent} that must be declared as handled by the service.
-     */
-    @SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
-    public static final String SERVICE_INTERFACE =
-            "android.media.routing.MediaRouteService";
-
-    /**
-     * Creates a media route service.
-     */
-    public MediaRouteService() {
-        mHandler = new Handler(true);
-        mService = new BinderService();
-    }
-
-    @Override
-    public @Nullable IBinder onBind(Intent intent) {
-        if (SERVICE_INTERFACE.equals(intent.getAction())) {
-            return mService;
-        }
-        return null;
-    }
-
-    /**
-     * Creates a new client session on behalf of a client.
-     * <p>
-     * The implementation should return a {@link ClientSession} for the client
-     * to use.  The media route service must take care to manage the state of
-     * each client session independently from any others that might also be
-     * in use at the same time.
-     * </p>
-     *
-     * @param client Information about the client.
-     * @return The client session object, or null if the client is not allowed
-     * to interact with this media route service.
-     */
-    public abstract @Nullable ClientSession onCreateClientSession(@NonNull ClientInfo client);
-
-    /**
-     * Gets metadata about this service.
-     * <p>
-     * Use this method to obtain a {@link ServiceMetadata} object to provide when creating
-     * a {@link android.media.routing.MediaRouter.DestinationInfo.Builder}.
-     * </p>
-     *
-     * @return Metadata about this service.
-     */
-    public @NonNull ServiceMetadata getServiceMetadata() {
-        if (mMetadata == null) {
-            try {
-                mMetadata = new ServiceMetadata(this);
-            } catch (NameNotFoundException ex) {
-                Log.wtf(TAG, "Could not retrieve own service metadata!");
-            }
-        }
-        return mMetadata;
-    }
-
-    /**
-     * Enables a single client to access the functionality of the media route service.
-     */
-    public static abstract class ClientSession {
-        /**
-         * Starts discovery.
-         * <p>
-         * If the media route service is capable of discovering routes that satisfy
-         * the request then this method should start discovery and return true.
-         * Otherwise, this method should return false.  If false is returned,
-         * then the framework will not call {@link #onStopDiscovery} since discovery
-         * was never actually started.
-         * </p><p>
-         * There may already be other discovery requests in progress at the same time
-         * for other clients; the media route service must keep track of them all.
-         * </p>
-         *
-         * @param req The discovery request to start.
-         * @param callback A callback to receive discovery events related to this
-         * particular request.  The events that the service sends to this callback
-         * will be sent to the client that initiated the discovery request.
-         * @return True if discovery has started.  False if the media route service
-         * is unable to discover routes that satisfy the request.
-         */
-        public abstract boolean onStartDiscovery(@NonNull DiscoveryRequest req,
-                @NonNull DiscoveryCallback callback);
-
-        /**
-         * Stops discovery.
-         * <p>
-         * If {@link #onStartDiscovery} returned true, then this method will eventually
-         * be called when the framework no longer requires this discovery request
-         * to be performed.
-         * </p><p>
-         * There may still be other discovery requests in progress for other clients;
-         * they must keep working until they have each been stopped by their client.
-         * </p>
-         */
-        public abstract void onStopDiscovery();
-
-        /**
-         * Starts connecting to a route.
-         *
-         * @param req The connection request.
-         * @param callback A callback to receive events connection events related
-         * to this particular request.  The events that the service sends to this callback
-         * will be sent to the client that initiated the discovery request.
-         * @return True if the connection is in progress, or false if the client
-         * unable to connect to the requested route.
-         */
-        public abstract boolean onConnect(@NonNull ConnectionRequest req,
-                @NonNull ConnectionCallback callback);
-
-        /**
-         * Called when the client requests to disconnect from the route
-         * or abort a connection attempt in progress.
-         */
-        public abstract void onDisconnect();
-
-        /**
-         * Called when the client requests to pause streaming of content to
-         * live audio/video routes such as when it goes into the background.
-         * <p>
-         * The default implementation does nothing.
-         * </p>
-         */
-        public void onPauseStream() { }
-
-        /**
-         * Called when the application requests to resume streaming of content to
-         * live audio/video routes such as when it returns to the foreground.
-         * <p>
-         * The default implementation does nothing.
-         * </p>
-         */
-        public void onResumeStream() { }
-
-        /**
-         * Called when the client is releasing the session.
-         * <p>
-         * The framework automatically takes care of stopping discovery and
-         * terminating the connection politely before calling this method to release
-         * the session.
-         * </p><p>
-         * The default implementation does nothing.
-         * </p>
-         */
-        public void onRelease() { }
-    }
-
-    /**
-     * Provides events in response to a discovery request.
-     */
-    public final class DiscoveryCallback {
-        private final ClientRecord mRecord;
-
-        DiscoveryCallback(ClientRecord record) {
-            mRecord = record;
-        }
-
-        /**
-         * Called by the service when a destination is found that
-         * offers one or more routes that satisfy the discovery request.
-         * <p>
-         * This method should be called whenever the list of available routes
-         * at a destination changes or whenever the properties of the destination
-         * itself change.
-         * </p>
-         *
-         * @param destination The destination that was found.
-         * @param routes The list of that destination's routes that satisfy the
-         * discovery request.
-         */
-        public void onDestinationFound(final @NonNull DestinationInfo destination,
-                final @NonNull List<RouteInfo> routes) {
-            if (destination == null) {
-                throw new IllegalArgumentException("destination must not be null");
-            }
-            if (routes == null) {
-                throw new IllegalArgumentException("routes must not be null");
-            }
-            for (int i = 0; i < routes.size(); i++) {
-                if (routes.get(i).getDestination() != destination) {
-                    throw new IllegalArgumentException("routes must refer to the "
-                            + "destination");
-                }
-            }
-
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchDestinationFound(DiscoveryCallback.this,
-                            destination, routes);
-                }
-            });
-        }
-
-        /**
-         * Called by the service when a destination is no longer
-         * reachable or is no longer offering any routes that satisfy
-         * the discovery request.
-         *
-         * @param destination The destination that went away.
-         */
-        public void onDestinationLost(final @NonNull DestinationInfo destination) {
-            if (destination == null) {
-                throw new IllegalArgumentException("destination must not be null");
-            }
-
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchDestinationLost(DiscoveryCallback.this, destination);
-                }
-            });
-        }
-
-        /**
-         * Called by the service when a discovery has failed in a non-recoverable manner.
-         *
-         * @param error The error code: one of
-         * {@link MediaRouter#DISCOVERY_ERROR_UNKNOWN},
-         * {@link MediaRouter#DISCOVERY_ERROR_ABORTED},
-         * or {@link MediaRouter#DISCOVERY_ERROR_NO_CONNECTIVITY}.
-         * @param message The localized error message, or null if none.  This message
-         * may be shown to the user.
-         * @param extras Additional information about the error which a client
-         * may use, or null if none.
-         */
-        public void onDiscoveryFailed(final @DiscoveryError int error,
-                final @Nullable CharSequence message, final @Nullable Bundle extras) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchDiscoveryFailed(DiscoveryCallback.this,
-                            error, message, extras);
-                }
-            });
-        }
-    }
-
-    /**
-     * Provides events in response to a connection request.
-     */
-    public final class ConnectionCallback {
-        private final ClientRecord mRecord;
-
-        ConnectionCallback(ClientRecord record) {
-            mRecord = record;
-        }
-
-        /**
-         * Called by the service when the connection succeeds.
-         *
-         * @param connection Immutable information about the connection.
-         */
-        public void onConnected(final @NonNull ConnectionInfo connection) {
-            if (connection == null) {
-                throw new IllegalArgumentException("connection must not be null");
-            }
-
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchConnected(ConnectionCallback.this, connection);
-                }
-            });
-        }
-
-        /**
-         * Called by the service when the connection is terminated normally.
-         * <p>
-         * Abnormal termination is reported via {@link #onConnectionFailed}.
-         * </p>
-         */
-        public void onDisconnected() {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchDisconnected(ConnectionCallback.this);
-                }
-            });
-        }
-
-        /**
-         * Called by the service when a connection attempt or connection in
-         * progress has failed in a non-recoverable manner.
-         *
-         * @param error The error code: one of
-         * {@link MediaRouter#CONNECTION_ERROR_ABORTED},
-         * {@link MediaRouter#CONNECTION_ERROR_UNAUTHORIZED},
-         * {@link MediaRouter#CONNECTION_ERROR_UNREACHABLE},
-         * {@link MediaRouter#CONNECTION_ERROR_BUSY},
-         * {@link MediaRouter#CONNECTION_ERROR_TIMEOUT},
-         * {@link MediaRouter#CONNECTION_ERROR_BROKEN},
-         * or {@link MediaRouter#CONNECTION_ERROR_BARGED}.
-         * @param message The localized error message, or null if none.  This message
-         * may be shown to the user.
-         * @param extras Additional information about the error which a client
-         * may use, or null if none.
-         */
-        public void onConnectionFailed(final @ConnectionError int error,
-                final @Nullable CharSequence message, final @Nullable Bundle extras) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    mRecord.dispatchConnectionFailed(ConnectionCallback.this,
-                            error, message, extras);
-                }
-            });
-        }
-    }
-
-    /**
-     * Identifies a client of the media route service.
-     */
-    public static final class ClientInfo {
-        private final int mUid;
-        private final String mPackageName;
-
-        ClientInfo(int uid, String packageName) {
-            mUid = uid;
-            mPackageName = packageName;
-        }
-
-        /**
-         * Gets the UID of the client application.
-         */
-        public int getUid() {
-            return mUid;
-        }
-
-        /**
-         * Gets the package name of the client application.
-         */
-        public @NonNull String getPackageName() {
-            return mPackageName;
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "ClientInfo{ uid=" + mUid + ", package=" + mPackageName + " }";
-        }
-    }
-
-    private final class BinderService extends IMediaRouteService.Stub {
-        @Override
-        public void registerClient(final int clientUid, final String clientPackageName,
-                final IMediaRouteClientCallback callback) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientInfo client = new ClientInfo(clientUid, clientPackageName);
-                    if (DEBUG) {
-                        Log.d(TAG, "registerClient: client=" + client);
-                    }
-
-                    ClientSession session = onCreateClientSession(client);
-                    if (session == null) {
-                        // request refused by service
-                        Log.w(TAG, "Media route service refused to create session for client: "
-                                + "client=" + client);
-                        return;
-                    }
-
-                    ClientRecord record = new ClientRecord(callback, client, session);
-                    try {
-                        callback.asBinder().linkToDeath(record, 0);
-                    } catch (RemoteException ex) {
-                        // client died prematurely
-                        Log.w(TAG, "Client died prematurely while creating session: "
-                                + "client=" + client);
-                        record.release();
-                        return;
-                    }
-
-                    mClientRecords.put(callback.asBinder(), record);
-                }
-            });
-        }
-
-        @Override
-        public void unregisterClient(IMediaRouteClientCallback callback) {
-            unregisterClient(callback, false);
-        }
-
-        void unregisterClient(final IMediaRouteClientCallback callback,
-                final boolean died) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.remove(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "unregisterClient: client=" + record.getClientInfo()
-                                + ", died=" + died);
-                    }
-
-                    record.release();
-                    callback.asBinder().unlinkToDeath(record, 0);
-                }
-            });
-        }
-
-        @Override
-        public void startDiscovery(final IMediaRouteClientCallback callback,
-                final int seq, final List<MediaRouteSelector> selectors,
-                final int flags) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "startDiscovery: client=" + record.getClientInfo()
-                                + ", seq=" + seq + ", selectors=" + selectors
-                                + ", flags=0x" + Integer.toHexString(flags));
-                    }
-                    record.startDiscovery(seq, selectors, flags);
-                }
-            });
-        }
-
-        @Override
-        public void stopDiscovery(final IMediaRouteClientCallback callback) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "stopDiscovery: client=" + record.getClientInfo());
-                    }
-                    record.stopDiscovery();
-                }
-            });
-        }
-
-        @Override
-        public void connect(final IMediaRouteClientCallback callback,
-                final int seq, final String destinationId, final String routeId,
-                final int flags, final Bundle extras) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "connect: client=" + record.getClientInfo()
-                                + ", seq=" + seq + ", destinationId=" + destinationId
-                                + ", routeId=" + routeId
-                                + ", flags=0x" + Integer.toHexString(flags)
-                                + ", extras=" + extras);
-                    }
-                    record.connect(seq, destinationId, routeId, flags, extras);
-                }
-            });
-        }
-
-        @Override
-        public void disconnect(final IMediaRouteClientCallback callback) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "disconnect: client=" + record.getClientInfo());
-                    }
-                    record.disconnect();
-                }
-            });
-        }
-
-        @Override
-        public void pauseStream(final IMediaRouteClientCallback callback) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "pauseStream: client=" + record.getClientInfo());
-                    }
-                    record.pauseStream();
-                }
-            });
-        }
-
-        @Override
-        public void resumeStream(final IMediaRouteClientCallback callback) {
-            mHandler.post(new Runnable() {
-                @Override
-                public void run() {
-                    ClientRecord record = mClientRecords.get(callback.asBinder());
-                    if (record == null) {
-                        return; // spurious
-                    }
-
-                    if (DEBUG) {
-                        Log.d(TAG, "resumeStream: client=" + record.getClientInfo());
-                    }
-                    record.resumeStream();
-                }
-            });
-        }
-    }
-
-    // Must be accessed on handler
-    private final class ClientRecord implements IBinder.DeathRecipient {
-        private final IMediaRouteClientCallback mClientCallback;
-        private final ClientInfo mClient;
-        private final ClientSession mSession;
-
-        private int mDiscoverySeq;
-        private DiscoveryRequest mDiscoveryRequest;
-        private DiscoveryCallback mDiscoveryCallback;
-        private final ArrayMap<String, DestinationRecord> mDestinations =
-                new ArrayMap<String, DestinationRecord>();
-
-        private int mConnectionSeq;
-        private ConnectionRequest mConnectionRequest;
-        private ConnectionCallback mConnectionCallback;
-        private ConnectionInfo mConnection;
-        private boolean mConnectionPaused;
-
-        public ClientRecord(IMediaRouteClientCallback callback,
-                ClientInfo client, ClientSession session) {
-            mClientCallback = callback;
-            mClient = client;
-            mSession = session;
-        }
-
-        // Invoked on binder thread unlike all other methods in this class.
-        @Override
-        public void binderDied() {
-            mService.unregisterClient(mClientCallback, true);
-        }
-
-        public ClientInfo getClientInfo() {
-            return mClient;
-        }
-
-        public void release() {
-            stopDiscovery();
-            disconnect();
-        }
-
-        public void startDiscovery(int seq, List<MediaRouteSelector> selectors,
-                int flags) {
-            stopDiscovery();
-
-            mDiscoverySeq = seq;
-            mDiscoveryRequest = new DiscoveryRequest(selectors);
-            mDiscoveryRequest.setFlags(flags);
-            mDiscoveryCallback = new DiscoveryCallback(this);
-            boolean started = mSession.onStartDiscovery(mDiscoveryRequest, mDiscoveryCallback);
-            if (!started) {
-                dispatchDiscoveryFailed(mDiscoveryCallback,
-                        MediaRouter.DISCOVERY_ERROR_ABORTED, null, null);
-                clearDiscovery();
-            }
-        }
-
-        public void stopDiscovery() {
-            if (mDiscoveryRequest != null) {
-                mSession.onStopDiscovery();
-                clearDiscovery();
-            }
-        }
-
-        private void clearDiscovery() {
-            mDestinations.clear();
-            mDiscoveryRequest = null;
-            mDiscoveryCallback = null;
-        }
-
-        public void connect(int seq, String destinationId, String routeId,
-                int flags, Bundle extras) {
-            disconnect();
-
-            mConnectionSeq = seq;
-            mConnectionCallback = new ConnectionCallback(this);
-
-            DestinationRecord destinationRecord = mDestinations.get(destinationId);
-            if (destinationRecord == null) {
-                Log.w(TAG, "Aborting connection to route since no matching destination "
-                        + "was found in the list of known destinations: "
-                        + "destinationId=" + destinationId);
-                dispatchConnectionFailed(mConnectionCallback,
-                        MediaRouter.CONNECTION_ERROR_ABORTED, null, null);
-                clearConnection();
-                return;
-            }
-
-            RouteInfo route = destinationRecord.getRoute(routeId);
-            if (route == null) {
-                Log.w(TAG, "Aborting connection to route since no matching route "
-                        + "was found in the list of known routes: "
-                        + "destination=" + destinationRecord.destination
-                        + ", routeId=" + routeId);
-                dispatchConnectionFailed(mConnectionCallback,
-                        MediaRouter.CONNECTION_ERROR_ABORTED, null, null);
-                clearConnection();
-                return;
-            }
-
-            mConnectionRequest = new ConnectionRequest(route);
-            mConnectionRequest.setFlags(flags);
-            mConnectionRequest.setExtras(extras);
-            boolean started = mSession.onConnect(mConnectionRequest, mConnectionCallback);
-            if (!started) {
-                dispatchConnectionFailed(mConnectionCallback,
-                        MediaRouter.CONNECTION_ERROR_ABORTED, null, null);
-                clearConnection();
-            }
-        }
-
-        public void disconnect() {
-            if (mConnectionRequest != null) {
-                mSession.onDisconnect();
-                clearConnection();
-            }
-        }
-
-        private void clearConnection() {
-            mConnectionRequest = null;
-            mConnectionCallback = null;
-            if (mConnection != null) {
-                mConnection.close();
-                mConnection = null;
-            }
-            mConnectionPaused = false;
-        }
-
-        public void pauseStream() {
-            if (mConnectionRequest != null && !mConnectionPaused) {
-                mConnectionPaused = true;
-                mSession.onPauseStream();
-            }
-        }
-
-        public void resumeStream() {
-            if (mConnectionRequest != null && mConnectionPaused) {
-                mConnectionPaused = false;
-                mSession.onResumeStream();
-            }
-        }
-
-        public void dispatchDestinationFound(DiscoveryCallback callback,
-                DestinationInfo destination, List<RouteInfo> routes) {
-            if (callback == mDiscoveryCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "destinationFound: destination=" + destination
-                            + ", routes=" + routes);
-                }
-                mDestinations.put(destination.getId(),
-                        new DestinationRecord(destination, routes));
-
-                ParcelableDestinationInfo pdi = new ParcelableDestinationInfo();
-                pdi.id = destination.getId();
-                pdi.name = destination.getName();
-                pdi.description = destination.getDescription();
-                pdi.iconResourceId = destination.getIconResourceId();
-                pdi.extras = destination.getExtras();
-                ArrayList<ParcelableRouteInfo> pris = new ArrayList<ParcelableRouteInfo>();
-                for (RouteInfo route : routes) {
-                    int selectorIndex = mDiscoveryRequest.getSelectors().indexOf(
-                            route.getSelector());
-                    if (selectorIndex < 0) {
-                        Log.w(TAG, "Ignoring route because the selector does not match "
-                                + "any of those that were originally supplied by the "
-                                + "client's discovery request: destination=" + destination
-                                + ", route=" + route);
-                        continue;
-                    }
-
-                    ParcelableRouteInfo pri = new ParcelableRouteInfo();
-                    pri.id = route.getId();
-                    pri.selectorIndex = selectorIndex;
-                    pri.features = route.getFeatures();
-                    pri.protocols = route.getProtocols().toArray(
-                            new String[route.getProtocols().size()]);
-                    pri.extras = route.getExtras();
-                    pris.add(pri);
-                }
-                try {
-                    mClientCallback.onDestinationFound(mDiscoverySeq, pdi,
-                            pris.toArray(new ParcelableRouteInfo[pris.size()]));
-                } catch (RemoteException ex) {
-                    // binder death handled elsewhere
-                }
-            }
-        }
-
-        public void dispatchDestinationLost(DiscoveryCallback callback,
-                DestinationInfo destination) {
-            if (callback == mDiscoveryCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "destinationLost: destination=" + destination);
-                }
-
-                if (mDestinations.get(destination.getId()).destination == destination) {
-                    mDestinations.remove(destination.getId());
-                    try {
-                        mClientCallback.onDestinationLost(mDiscoverySeq, destination.getId());
-                    } catch (RemoteException ex) {
-                        // binder death handled elsewhere
-                    }
-                }
-            }
-        }
-
-        public void dispatchDiscoveryFailed(DiscoveryCallback callback,
-                int error, CharSequence message, Bundle extras) {
-            if (callback == mDiscoveryCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "discoveryFailed: error=" + error + ", message=" + message
-                            + ", extras=" + extras);
-                }
-
-                try {
-                    mClientCallback.onDiscoveryFailed(mDiscoverySeq, error, message, extras);
-                } catch (RemoteException ex) {
-                    // binder death handled elsewhere
-                }
-            }
-        }
-
-        public void dispatchConnected(ConnectionCallback callback, ConnectionInfo connection) {
-            if (callback == mConnectionCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "connected: connection=" + connection);
-                }
-                if (mConnection == null) {
-                    mConnection = connection;
-
-                    ParcelableConnectionInfo pci = new ParcelableConnectionInfo();
-                    pci.audioAttributes = connection.getAudioAttributes();
-                    pci.presentationDisplayId = connection.getPresentationDisplay() != null ?
-                            connection.getPresentationDisplay().getDisplayId() : -1;
-                    pci.protocolBinders = new IBinder[connection.getProtocols().size()];
-                    for (int i = 0; i < pci.protocolBinders.length; i++) {
-                        pci.protocolBinders[i] = connection.getProtocolBinder(i);
-                    }
-                    pci.extras = connection.getExtras();
-                    try {
-                        mClientCallback.onConnected(mConnectionSeq, pci);
-                    } catch (RemoteException ex) {
-                        // binder death handled elsewhere
-                    }
-                } else {
-                    Log.w(TAG, "Media route service called onConnected() while already "
-                            + "connected.");
-                }
-            }
-        }
-
-        public void dispatchDisconnected(ConnectionCallback callback) {
-            if (callback == mConnectionCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "disconnected");
-                }
-
-                if (mConnection != null) {
-                    mConnection.close();
-                    mConnection = null;
-
-                    try {
-                        mClientCallback.onDisconnected(mConnectionSeq);
-                    } catch (RemoteException ex) {
-                        // binder death handled elsewhere
-                    }
-                }
-            }
-        }
-
-        public void dispatchConnectionFailed(ConnectionCallback callback,
-                int error, CharSequence message, Bundle extras) {
-            if (callback == mConnectionCallback) {
-                if (DEBUG) {
-                    Log.d(TAG, "connectionFailed: error=" + error + ", message=" + message
-                            + ", extras=" + extras);
-                }
-
-                try {
-                    mClientCallback.onConnectionFailed(mConnectionSeq, error, message, extras);
-                } catch (RemoteException ex) {
-                    // binder death handled elsewhere
-                }
-            }
-        }
-    }
-
-    private static final class DestinationRecord {
-        public final DestinationInfo destination;
-        public final List<RouteInfo> routes;
-
-        public DestinationRecord(DestinationInfo destination, List<RouteInfo> routes) {
-            this.destination = destination;
-            this.routes = routes;
-        }
-
-        public RouteInfo getRoute(String routeId) {
-            final int count = routes.size();
-            for (int i = 0; i < count; i++) {
-                RouteInfo route = routes.get(i);
-                if (route.getId().equals(routeId)) {
-                    return route;
-                }
-            }
-            return null;
-        }
-    }
-}
diff --git a/media/java/android/media/routing/MediaRouter.java b/media/java/android/media/routing/MediaRouter.java
deleted file mode 100644
index 4f6d324..0000000
--- a/media/java/android/media/routing/MediaRouter.java
+++ /dev/null
@@ -1,1886 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.annotation.DrawableRes;
-import android.annotation.IntDef;
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.app.Presentation;
-import android.app.Service;
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.pm.PackageManager;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.content.pm.ServiceInfo;
-import android.graphics.drawable.Drawable;
-import android.hardware.display.DisplayManager;
-import android.media.AudioAttributes;
-import android.media.AudioManager;
-import android.media.AudioTrack;
-import android.media.VolumeProvider;
-import android.media.session.MediaController;
-import android.media.session.MediaSession;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.IInterface;
-import android.text.TextUtils;
-import android.util.ArrayMap;
-import android.view.Display;
-
-import java.io.Closeable;
-import java.io.IOException;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.List;
-
-/**
- * Media router allows applications to discover, connect to, control,
- * and send content to nearby media devices known as destinations.
- * <p>
- * There are generally two participants involved in media routing: an
- * application that wants to send media content to a destination and a
- * {@link MediaRouteService media route service} that provides the
- * service of transporting that content where it needs to go on behalf of the
- * application.
- * </p><p>
- * To send media content to a destination, the application must ask the system
- * to discover available routes to destinations that provide certain capabilities,
- * establish a connection to a route, then send messages through the connection to
- * control the routing of audio and video streams, launch remote applications,
- * and invoke other functions of the destination.
- * </p><p>
- * Media router objects are thread-safe.
- * </p>
- *
- * <h3>Destinations</h3>
- * <p>
- * The media devices to which an application may send media content are referred
- * to in the API as destinations.  Each destination therefore represents a single
- * independent device such as a speaker or TV set.  Destinations are given meaningful
- * names and descriptions to help the user associate them with devices in their
- * environment.
- * </p><p>
- * Destinations may be local or remote and may be accessed through various means,
- * often wirelessly.  The user may install media route services to enable
- * media applications to connect to a variety of destinations with different
- * capabilities.
- * </p>
- *
- * <h3>Routes</h3>
- * <p>
- * Routes represent possible usages or means of reaching and interacting with
- * a destination.  Since destinations may support many different features, they may
- * each offer multiple routes for applications to choose from based on their needs.
- * For example, one route might express the ability to stream locally rendered audio
- * and video to the device; another route might express the ability to send a URL for
- * the destination to download from the network and play all by itself.
- * </p><p>
- * Routes are discovered according to the set of capabilities that
- * an application or the system is seeking to use at a particular time.  For example,
- * if an application wants to stream music to a destination then it will ask the
- * {@link MediaRouter} to find routes to destinations can stream music and ignore
- * all other destinations that cannot.
- * </p><p>
- * In general, the application will inspect the set of routes that have been
- * offered then connect to the most appropriate route for its desired purpose.
- * </p>
- *
- * <h3>Route Selection</h3>
- * <p>
- * When the user open the media route chooser activity, the system will display
- * a list of nearby media destinations which have been discovered.  After the
- * choice is made the application may connect to one of the routes offered by
- * this destination and begin communicating with the destination.
- * </p><p>
- * Destinations are located through a process called discovery.  During discovery,
- * the system will start installed {@link MediaRouteService media route services}
- * to scan the network for nearby devices that offer the kinds of capabilities that the
- * application is seeking to use.  The application specifies the capabilities it requires by
- * adding {@link MediaRouteSelector media route selectors} to the media router
- * using the {@link #addSelector} method.  Only destinations that provide routes
- * which satisfy at least one of these media route selectors will be discovered.
- * </p><p>
- * Once the user has selected a destination, the application will be given a chance
- * to choose one of the routes to which it would like to connect.  The application
- * may switch to a different route from the same destination at a later time but
- * in order to connect to a new destination, the application must once again launch
- * the media route chooser activity to ask the user to choose a destination.
- * </p>
- *
- * <h3>Route Protocols</h3>
- * <p>
- * Route protocols express capabilities offered by routes.  Each media route selector
- * must specify at least one required protocol by which the routes will be selected.
- * </p><p>
- * The framework provides several predefined <code>MediaRouteProtocols</code> which are
- * defined in the <code>android-support-media-protocols.jar</code> support library.
- * Applications must statically link this library to make use of these protocols.
- * </p><p>
- * The static library approach is used to enable ongoing extension and refinement
- * of protocols in the SDK and interoperability with the media router implementation
- * for older platform versions which is offered by the framework support library.
- * </p><p>
- * Media route services may also define custom media route protocols of their own
- * to enable applications to access specialized capabilities of certain destinations
- * assuming they have linked in the required protocol code.
- * </p><p>
- * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code> for more information.
- * </p>
- *
- * <h3>Connections</h3>
- * <p>
- * After connecting to a media route, the application can send commands to
- * the route using any of the protocols that it requested.  If the route supports live
- * audio or video streaming then the application can create an {@link AudioTrack} or
- * {@link Presentation} to route locally generated content to the destination.
- * </p>
- *
- * <h3>Delegation</h3>
- * <p>
- * The creator of the media router is responsible for establishing the policy for
- * discovering and connecting to destinations.  UI components may observe the state
- * of the media router by {@link #createDelegate creating} a {@link Delegate}.
- * </p><p>
- * The media router should also be attached to the {@link MediaSession media session}
- * that is handling media playback lifecycle.  This will allow
- * authorized {@link MediaController media controllers}, possibly running in other
- * processes, to provide UI to examine and change the media destination by
- * {@link MediaController#createMediaRouterDelegate creating} a {@link Delegate}
- * for the media router associated with the session.
- * </p>
- */
-public final class MediaRouter {
-    private final DisplayManager mDisplayManager;
-
-    private final Object mLock = new Object();
-
-    private RoutingCallback mRoutingCallback;
-    private Handler mRoutingCallbackHandler;
-
-    private boolean mReleased;
-    private int mDiscoveryState;
-    private int mConnectionState;
-    private final ArrayList<MediaRouteSelector> mSelectors =
-            new ArrayList<MediaRouteSelector>();
-    private final ArrayMap<DestinationInfo, List<RouteInfo>> mDiscoveredDestinations =
-            new ArrayMap<DestinationInfo, List<RouteInfo>>();
-    private RouteInfo mSelectedRoute;
-    private ConnectionInfo mConnection;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(value = { DISCOVERY_STATE_STOPPED, DISCOVERY_STATE_STARTED })
-    public @interface DiscoveryState { }
-
-    /**
-     * Discovery state: Discovery is not currently in progress.
-     */
-    public static final int DISCOVERY_STATE_STOPPED = 0;
-
-    /**
-     * Discovery state: Discovery is being performed.
-     */
-    public static final int DISCOVERY_STATE_STARTED = 1;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(flag = true, value = { DISCOVERY_FLAG_BACKGROUND })
-    public @interface DiscoveryFlags { }
-
-    /**
-     * Discovery flag: Indicates that the client has requested passive discovery in
-     * the background.  The media route service should try to use less power and rely
-     * more on its internal caches to minimize its impact.
-     */
-    public static final int DISCOVERY_FLAG_BACKGROUND = 1 << 0;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(value = { DISCOVERY_ERROR_UNKNOWN, DISCOVERY_ERROR_ABORTED,
-            DISCOVERY_ERROR_NO_CONNECTIVITY })
-    public @interface DiscoveryError { }
-
-    /**
-     * Discovery error: Unknown error; refer to the error message for details.
-     */
-    public static final int DISCOVERY_ERROR_UNKNOWN = 0;
-
-    /**
-     * Discovery error: The media router or media route service has decided not to
-     * handle the discovery request for some reason.
-     */
-    public static final int DISCOVERY_ERROR_ABORTED = 1;
-
-    /**
-     * Discovery error: The media route service is unable to perform discovery
-     * due to a lack of connectivity such as because the radio is disabled.
-     */
-    public static final int DISCOVERY_ERROR_NO_CONNECTIVITY = 2;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(value = { CONNECTION_STATE_DISCONNECTED, CONNECTION_STATE_CONNECTING,
-            CONNECTION_STATE_CONNECTED })
-    public @interface ConnectionState { }
-
-    /**
-     * Connection state: No destination has been selected.  Media content should
-     * be sent to the default output.
-     */
-    public static final int CONNECTION_STATE_DISCONNECTED = 0;
-
-    /**
-     * Connection state: The application is in the process of connecting to
-     * a route offered by the selected destination.
-     */
-    public static final int CONNECTION_STATE_CONNECTING = 1;
-
-    /**
-     * Connection state: The application has connected to a route offered by
-     * the selected destination.
-     */
-    public static final int CONNECTION_STATE_CONNECTED = 2;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(flag = true, value = { CONNECTION_FLAG_BARGE })
-    public @interface ConnectionFlags { }
-
-    /**
-     * Connection flag: Indicates that the client has requested to barge in and evict
-     * other clients that might have already connected to the destination and that
-     * would otherwise prevent this client from connecting.  When this flag is not
-     * set, the media route service should be polite and report
-     * {@link MediaRouter#CONNECTION_ERROR_BUSY} in case the destination is
-     * already occupied and cannot accept additional connections.
-     */
-    public static final int CONNECTION_FLAG_BARGE = 1 << 0;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(value = { CONNECTION_ERROR_UNKNOWN, CONNECTION_ERROR_ABORTED,
-            CONNECTION_ERROR_UNAUTHORIZED, CONNECTION_ERROR_UNAUTHORIZED,
-            CONNECTION_ERROR_BUSY, CONNECTION_ERROR_TIMEOUT, CONNECTION_ERROR_BROKEN })
-    public @interface ConnectionError { }
-
-    /**
-     * Connection error: Unknown error; refer to the error message for details.
-     */
-    public static final int CONNECTION_ERROR_UNKNOWN = 0;
-
-    /**
-     * Connection error: The media router or media route service has decided not to
-     * handle the connection request for some reason.
-     */
-    public static final int CONNECTION_ERROR_ABORTED = 1;
-
-    /**
-     * Connection error: The device has refused the connection from this client.
-     * This error should be avoided because the media route service should attempt
-     * to filter out devices that the client cannot access as it performs discovery
-     * on behalf of that client.
-     */
-    public static final int CONNECTION_ERROR_UNAUTHORIZED = 2;
-
-    /**
-     * Connection error: The device is unreachable over the network.
-     */
-    public static final int CONNECTION_ERROR_UNREACHABLE = 3;
-
-    /**
-     * Connection error: The device is already busy serving another client and
-     * the connection request did not ask to barge in.
-     */
-    public static final int CONNECTION_ERROR_BUSY = 4;
-
-    /**
-     * Connection error: A timeout occurred during connection.
-     */
-    public static final int CONNECTION_ERROR_TIMEOUT = 5;
-
-    /**
-     * Connection error: The connection to the device was severed unexpectedly.
-     */
-    public static final int CONNECTION_ERROR_BROKEN = 6;
-
-    /**
-     * Connection error: The connection was terminated because a different client barged
-     * in and took control of the destination.
-     */
-    public static final int CONNECTION_ERROR_BARGED = 7;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(value = { DISCONNECTION_REASON_APPLICATION_REQUEST,
-            DISCONNECTION_REASON_USER_REQUEST, DISCONNECTION_REASON_ERROR })
-    public @interface DisconnectionReason { }
-
-    /**
-     * Disconnection reason: The application requested disconnection itself.
-     */
-    public static final int DISCONNECTION_REASON_APPLICATION_REQUEST = 0;
-
-    /**
-     * Disconnection reason: The user requested disconnection.
-     */
-    public static final int DISCONNECTION_REASON_USER_REQUEST = 1;
-
-    /**
-     * Disconnection reason: An error occurred.
-     */
-    public static final int DISCONNECTION_REASON_ERROR = 2;
-
-    /** @hide */
-    @Retention(RetentionPolicy.SOURCE)
-    @IntDef(flag = true, value = { ROUTE_FEATURE_LIVE_AUDIO, ROUTE_FEATURE_LIVE_VIDEO })
-    public @interface RouteFeatures { }
-
-    /**
-     * Route feature: Live audio.
-     * <p>
-     * A route that supports live audio streams audio rendered by the application
-     * to the destination.
-     * </p><p>
-     * To take advantage of live audio routing, the application must render its
-     * media using the audio attributes specified by {@link #getPreferredAudioAttributes}.
-     * </p>
-     *
-     * @see #getPreferredAudioAttributes
-     * @see android.media.AudioAttributes
-     */
-    public static final int ROUTE_FEATURE_LIVE_AUDIO = 1 << 0;
-
-    /**
-     * Route feature: Live video.
-     * <p>
-     * A route that supports live video streams video rendered by the application
-     * to the destination.
-     * </p><p>
-     * To take advantage of live video routing, the application must render its
-     * media to a {@link android.app.Presentation presentation window} on the
-     * display specified by {@link #getPreferredPresentationDisplay}.
-     * </p>
-     *
-     * @see #getPreferredPresentationDisplay
-     * @see android.app.Presentation
-     */
-    public static final int ROUTE_FEATURE_LIVE_VIDEO = 1 << 1;
-
-    /**
-     * Creates a media router.
-     *
-     * @param context The context with which the router is associated.
-     */
-    public MediaRouter(@NonNull Context context) {
-        if (context == null) {
-            throw new IllegalArgumentException("context must not be null");
-        }
-
-        mDisplayManager = (DisplayManager)context.getSystemService(Context.DISPLAY_SERVICE);
-    }
-
-    /** @hide */
-    public IMediaRouter getBinder() {
-        // todo
-        return null;
-    }
-
-    /**
-     * Disconnects from the selected destination and releases the media router.
-     * <p>
-     * This method should be called by the application when it no longer requires
-     * the media router to ensure that all bound resources may be cleaned up.
-     * </p>
-     */
-    public void release() {
-        synchronized (mLock) {
-            mReleased = true;
-            // todo
-        }
-    }
-
-    /**
-     * Returns true if the media router has been released.
-     */
-    public boolean isReleased() {
-        synchronized (mLock) {
-            return mReleased;
-        }
-    }
-
-    /**
-     * Gets the current route discovery state.
-     *
-     * @return The current discovery state: one of {@link #DISCOVERY_STATE_STOPPED},
-     * {@link #DISCOVERY_STATE_STARTED}.
-     */
-    public @DiscoveryState int getDiscoveryState() {
-        synchronized (mLock) {
-            return mDiscoveryState;
-        }
-    }
-
-    /**
-     * Gets the current route connection state.
-     *
-     * @return The current state: one of {@link #CONNECTION_STATE_DISCONNECTED},
-     * {@link #CONNECTION_STATE_CONNECTING} or {@link #CONNECTION_STATE_CONNECTED}.
-     */
-    public @ConnectionState int getConnectionState() {
-        synchronized (mLock) {
-            return mConnectionState;
-        }
-    }
-
-    /**
-     * Creates a media router delegate through which the destination of the media
-     * router may be controlled.
-     * <p>
-     * This is the point of entry for UI code that initiates discovery and
-     * connection to routes.
-     * </p>
-     */
-    public @NonNull Delegate createDelegate() {
-        return null; // todo
-    }
-
-    /**
-     * Sets a callback to participate in route discovery, filtering, and connection
-     * establishment.
-     *
-     * @param callback The callback to set, or null if none.
-     * @param handler The handler to receive callbacks, or null to use the current thread.
-     */
-    public void setRoutingCallback(@Nullable RoutingCallback callback,
-            @Nullable Handler handler) {
-        synchronized (mLock) {
-            if (callback == null) {
-                mRoutingCallback = null;
-                mRoutingCallbackHandler = null;
-            } else {
-                mRoutingCallback = callback;
-                mRoutingCallbackHandler = handler != null ? handler : new Handler();
-            }
-        }
-    }
-
-    /**
-     * Adds a media route selector to use to find destinations that have
-     * routes with the specified capabilities during route discovery.
-     */
-    public void addSelector(@NonNull MediaRouteSelector selector) {
-        if (selector == null) {
-            throw new IllegalArgumentException("selector must not be null");
-        }
-
-        synchronized (mLock) {
-            if (!mSelectors.contains(selector)) {
-                mSelectors.add(selector);
-                // todo
-            }
-        }
-    }
-
-    /**
-     * Removes a media route selector.
-     */
-    public void removeSelector(@NonNull MediaRouteSelector selector) {
-        if (selector == null) {
-            throw new IllegalArgumentException("selector must not be null");
-        }
-
-        synchronized (mLock) {
-            if (mSelectors.remove(selector)) {
-                // todo
-            }
-        }
-    }
-
-    /**
-     * Removes all media route selectors.
-     * <p>
-     * Note that at least one selector must be added in order to perform discovery.
-     * </p>
-     */
-    public void clearSelectors() {
-        synchronized (mLock) {
-            if (!mSelectors.isEmpty()) {
-                mSelectors.clear();
-                // todo
-            }
-        }
-    }
-
-    /**
-     * Gets a list of all media route selectors to consider during discovery.
-     */
-    public @NonNull List<MediaRouteSelector> getSelectors() {
-        synchronized (mLock) {
-            return new ArrayList<MediaRouteSelector>(mSelectors);
-        }
-    }
-
-    /**
-     * Gets the connection to the currently selected route.
-     *
-     * @return The connection to the currently selected route, or null if not connected.
-     */
-    public @NonNull ConnectionInfo getConnection() {
-        synchronized (mLock) {
-            return mConnection;
-        }
-    }
-
-    /**
-     * Gets the list of discovered destinations.
-     * <p>
-     * This list is only valid while discovery is running and is null otherwise.
-     * </p>
-     *
-     * @return The list of discovered destinations, or null if discovery is not running.
-     */
-    public @NonNull List<DestinationInfo> getDiscoveredDestinations() {
-        synchronized (mLock) {
-            if (mDiscoveryState == DISCOVERY_STATE_STARTED) {
-                return new ArrayList<DestinationInfo>(mDiscoveredDestinations.keySet());
-            }
-            return null;
-        }
-    }
-
-    /**
-     * Gets the list of discovered routes for a particular destination.
-     * <p>
-     * This list is only valid while discovery is running and is null otherwise.
-     * </p>
-     *
-     * @param destination The destination for which to get the list of discovered routes.
-     * @return The list of discovered routes for the destination, or null if discovery
-     * is not running.
-     */
-    public @NonNull List<RouteInfo> getDiscoveredRoutes(@NonNull DestinationInfo destination) {
-        if (destination == null) {
-            throw new IllegalArgumentException("destination must not be null");
-        }
-        synchronized (mLock) {
-            if (mDiscoveryState == DISCOVERY_STATE_STARTED) {
-                List<RouteInfo> routes = mDiscoveredDestinations.get(destination);
-                if (routes != null) {
-                    return new ArrayList<RouteInfo>(routes);
-                }
-            }
-            return null;
-        }
-    }
-
-    /**
-     * Gets the destination that has been selected.
-     *
-     * @return The selected destination, or null if disconnected.
-     */
-    public @Nullable DestinationInfo getSelectedDestination() {
-        synchronized (mLock) {
-            return mSelectedRoute != null ? mSelectedRoute.getDestination() : null;
-        }
-    }
-
-    /**
-     * Gets the route that has been selected.
-     *
-     * @return The selected destination, or null if disconnected.
-     */
-    public @Nullable RouteInfo getSelectedRoute() {
-        synchronized (mLock) {
-            return mSelectedRoute;
-        }
-    }
-
-    /**
-     * Gets the preferred audio attributes that should be used to stream live audio content
-     * based on the connected route.
-     * <p>
-     * Use an {@link AudioTrack} to send audio content to the destination with these
-     * audio attributes.
-     * </p><p>
-     * The preferred audio attributes may change when a connection is established but it
-     * will remain constant until disconnected.
-     * </p>
-     *
-     * @return The preferred audio attributes to use.  When connected, returns the
-     * route's audio attributes or null if it does not support live audio streaming.
-     * Otherwise returns audio attributes associated with {@link AudioAttributes#USAGE_MEDIA}.
-     */
-    public @Nullable AudioAttributes getPreferredAudioAttributes() {
-        synchronized (mLock) {
-            if (mConnection != null) {
-                return mConnection.getAudioAttributes();
-            }
-            return new AudioAttributes.Builder()
-                    .setLegacyStreamType(AudioManager.STREAM_MUSIC)
-                    .build();
-        }
-    }
-
-    /**
-     * Gets the preferred presentation display that should be used to stream live video content
-     * based on the connected route.
-     * <p>
-     * Use a {@link Presentation} to send video content to the destination with this display.
-     * </p><p>
-     * The preferred presentation display may change when a connection is established but it
-     * will remain constant until disconnected.
-     * </p>
-     *
-     * @return The preferred presentation display to use.  When connected, returns
-     * the route's presentation display or null if it does not support live video
-     * streaming.  Otherwise returns the first available
-     * {@link DisplayManager#DISPLAY_CATEGORY_PRESENTATION presentation display},
-     * such as a mirrored wireless or HDMI display or null if none.
-     */
-    public @Nullable Display getPreferredPresentationDisplay() {
-        synchronized (mLock) {
-            if (mConnection != null) {
-                return mConnection.getPresentationDisplay();
-            }
-            Display[] displays = mDisplayManager.getDisplays(
-                    DisplayManager.DISPLAY_CATEGORY_PRESENTATION);
-            return displays.length != 0 ? displays[0] : null;
-        }
-    }
-
-    /**
-     * Gets the preferred volume provider that should be used to control the volume
-     * of content rendered on the currently selected route.
-     * <p>
-     * The preferred volume provider may change when a connection is established but it
-     * will remain the same until disconnected.
-     * </p>
-     *
-     * @return The preferred volume provider to use, or null if the currently
-     * selected route does not support remote volume adjustment or if the connection
-     * is not yet established.  If no route is selected, returns null to indicate
-     * that system volume control should be used.
-     */
-    public @Nullable VolumeProvider getPreferredVolumeProvider() {
-        synchronized (mLock) {
-            if (mConnection != null) {
-                return mConnection.getVolumeProvider();
-            }
-            return null;
-        }
-    }
-
-    /**
-     * Requests to pause streaming of live audio or video routes.
-     * Should be called when the application is going into the background and is
-     * no longer rendering content locally.
-     * <p>
-     * This method does nothing unless a connection has been established.
-     * </p>
-     */
-    public void pauseStream() {
-        // todo
-    }
-
-    /**
-     * Requests to resume streaming of live audio or video routes.
-     * May be called when the application is returning to the foreground and is
-     * about to resume rendering content locally.
-     * <p>
-     * This method does nothing unless a connection has been established.
-     * </p>
-     */
-    public void resumeStream() {
-        // todo
-    }
-
-    /**
-     * This class is used by UI components to let the user discover and
-     * select a destination to which the media router should connect.
-     * <p>
-     * This API has somewhat more limited functionality than the {@link MediaRouter}
-     * itself because it is designed to allow applications to control
-     * the destination of media router instances that belong to other processes.
-     * </p><p>
-     * To control the destination of your own media router, call
-     * {@link #createDelegate} to obtain a local delegate object.
-     * </p><p>
-     * To control the destination of a media router that belongs to another process,
-     * first obtain a {@link MediaController} that is associated with the media playback
-     * that is occurring in that process, then call
-     * {@link MediaController#createMediaRouterDelegate} to obtain an instance of
-     * its destination controls.  Note that special permissions may be required to
-     * obtain the {@link MediaController} instance in the first place.
-     * </p>
-     */
-    public static final class Delegate {
-        /**
-         * Returns true if the media router has been released.
-         */
-        public boolean isReleased() {
-            // todo
-            return false;
-        }
-
-        /**
-         * Gets the current route discovery state.
-         *
-         * @return The current discovery state: one of {@link #DISCOVERY_STATE_STOPPED},
-         * {@link #DISCOVERY_STATE_STARTED}.
-         */
-        public @DiscoveryState int getDiscoveryState() {
-            // todo
-            return -1;
-        }
-
-        /**
-         * Gets the current route connection state.
-         *
-         * @return The current state: one of {@link #CONNECTION_STATE_DISCONNECTED},
-         * {@link #CONNECTION_STATE_CONNECTING} or {@link #CONNECTION_STATE_CONNECTED}.
-         */
-        public @ConnectionState int getConnectionState() {
-            // todo
-            return -1;
-        }
-
-        /**
-         * Gets the currently selected destination.
-         *
-         * @return The destination information, or null if none.
-         */
-        public @Nullable DestinationInfo getSelectedDestination() {
-            return null;
-        }
-
-        /**
-         * Gets the list of discovered destinations.
-         * <p>
-         * This list is only valid while discovery is running and is null otherwise.
-         * </p>
-         *
-         * @return The list of discovered destinations, or null if discovery is not running.
-         */
-        public @NonNull List<DestinationInfo> getDiscoveredDestinations() {
-            return null;
-        }
-
-        /**
-         * Adds a callback to receive state changes.
-         *
-         * @param callback The callback to set, or null if none.
-         * @param handler The handler to receive callbacks, or null to use the current thread.
-         */
-        public void addStateCallback(@Nullable StateCallback callback,
-                @Nullable Handler handler) {
-            if (callback == null) {
-                throw new IllegalArgumentException("callback must not be null");
-            }
-            if (handler == null) {
-                handler = new Handler();
-            }
-            // todo
-        }
-
-        /**
-         * Removes a callback for state changes.
-         *
-         * @param callback The callback to set, or null if none.
-         */
-        public void removeStateCallback(@Nullable StateCallback callback) {
-            // todo
-        }
-
-        /**
-         * Starts performing discovery.
-         * <p>
-         * Performing discovery is expensive.  Make sure to call {@link #stopDiscovery}
-         * as soon as possible once a new destination has been selected to allow the system
-         * to stop services associated with discovery.
-         * </p>
-         *
-         * @param flags The discovery flags, such as {@link MediaRouter#DISCOVERY_FLAG_BACKGROUND}.
-         */
-        public void startDiscovery(@DiscoveryFlags int flags) {
-            // todo
-        }
-
-        /**
-         * Stops performing discovery.
-         */
-        public void stopDiscovery() {
-            // todo
-        }
-
-        /**
-         * Connects to a destination during route discovery.
-         * <p>
-         * This method may only be called while route discovery is active and the
-         * destination appears in the
-         * {@link #getDiscoveredDestinations list of discovered destinations}.
-         * If the media router is already connected to a route then it will first disconnect
-         * from the current route then connect to the new route.
-         * </p>
-         *
-         * @param destination The destination to which the media router should connect.
-         * @param flags The connection flags, such as {@link MediaRouter#CONNECTION_FLAG_BARGE}.
-         */
-        public void connect(@NonNull DestinationInfo destination, @DiscoveryFlags int flags) {
-            // todo
-        }
-
-        /**
-         * Disconnects from the currently selected destination.
-         * <p>
-         * Does nothing if not currently connected.
-         * </p>
-         *
-         * @param reason The reason for the disconnection: one of
-         * {@link #DISCONNECTION_REASON_APPLICATION_REQUEST},
-         * {@link #DISCONNECTION_REASON_USER_REQUEST}, or {@link #DISCONNECTION_REASON_ERROR}.
-         */
-        public void disconnect(@DisconnectionReason int reason) {
-            // todo
-        }
-    }
-
-    /**
-     * Describes immutable properties of a connection to a route.
-     */
-    public static final class ConnectionInfo {
-        private final RouteInfo mRoute;
-        private final AudioAttributes mAudioAttributes;
-        private final Display mPresentationDisplay;
-        private final VolumeProvider mVolumeProvider;
-        private final IBinder[] mProtocolBinders;
-        private final Object[] mProtocolInstances;
-        private final Bundle mExtras;
-        private final ArrayList<Closeable> mCloseables;
-
-        private static final Class<?>[] MEDIA_ROUTE_PROTOCOL_CTOR_PARAMETERS =
-                new Class<?>[] { IBinder.class };
-
-        ConnectionInfo(RouteInfo route,
-                AudioAttributes audioAttributes, Display display,
-                VolumeProvider volumeProvider, IBinder[] protocolBinders,
-                Bundle extras, ArrayList<Closeable> closeables) {
-            mRoute = route;
-            mAudioAttributes = audioAttributes;
-            mPresentationDisplay = display;
-            mVolumeProvider = volumeProvider;
-            mProtocolBinders = protocolBinders;
-            mProtocolInstances = new Object[mProtocolBinders.length];
-            mExtras = extras;
-            mCloseables = closeables;
-        }
-
-        /**
-         * Gets the route that is connected.
-         */
-        public @NonNull RouteInfo getRoute() {
-            return mRoute;
-        }
-
-        /**
-         * Gets the audio attributes which the client should use to stream audio
-         * to the destination, or null if the route does not support live audio streaming.
-         */
-        public @Nullable AudioAttributes getAudioAttributes() {
-            return mAudioAttributes;
-        }
-
-        /**
-         * Gets the display which the client should use to stream video to the
-         * destination using a {@link Presentation}, or null if the route does not
-         * support live video streaming.
-         */
-        public @Nullable Display getPresentationDisplay() {
-            return mPresentationDisplay;
-        }
-
-        /**
-         * Gets the route's volume provider, or null if none.
-         */
-        public @Nullable VolumeProvider getVolumeProvider() {
-            return mVolumeProvider;
-        }
-
-        /**
-         * Gets the set of supported route features.
-         */
-        public @RouteFeatures int getFeatures() {
-            return mRoute.getFeatures();
-        }
-
-        /**
-         * Gets the list of supported route protocols.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         */
-        public @NonNull List<String> getProtocols() {
-            return mRoute.getProtocols();
-        }
-
-        /**
-         * Gets an instance of a route protocol object that wraps the protocol binder
-         * and provides easy access to the protocol's functionality.
-         * <p>
-         * This is a convenience method which invokes {@link #getProtocolBinder(String)}
-         * using the name of the provided class then passes the resulting {@link IBinder}
-         * to a single-argument constructor of that class.
-         * </p><p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         */
-        @SuppressWarnings("unchecked")
-        public @Nullable <T> T getProtocolObject(Class<T> clazz) {
-            int index = getProtocols().indexOf(clazz.getName());
-            if (index < 0) {
-                return null;
-            }
-            if (mProtocolInstances[index] == null && mProtocolBinders[index] != null) {
-                final Constructor<T> ctor;
-                try {
-                    ctor = clazz.getConstructor(MEDIA_ROUTE_PROTOCOL_CTOR_PARAMETERS);
-                } catch (NoSuchMethodException ex) {
-                    throw new RuntimeException("Could not find public constructor "
-                            + "with IBinder argument in protocol class: " + clazz.getName(), ex);
-                }
-                try {
-                    mProtocolInstances[index] = ctor.newInstance(mProtocolBinders[index]);
-                } catch (InstantiationException | IllegalAccessException
-                        | InvocationTargetException ex) {
-                    throw new RuntimeException("Could create instance of protocol class: "
-                            + clazz.getName(), ex);
-                }
-            }
-            return (T)mProtocolInstances[index];
-        }
-
-        /**
-         * Gets the {@link IBinder} that provides access to the specified route protocol
-         * or null if the protocol is not supported.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         */
-        public @Nullable IBinder getProtocolBinder(@NonNull String name) {
-            int index = getProtocols().indexOf(name);
-            return index >= 0 ? mProtocolBinders[index] : null;
-        }
-
-        /**
-         * Gets the {@link IBinder} that provides access to the specified route protocol
-         * at the given index in the protocol list or null if the protocol is not supported.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         */
-        public @Nullable IBinder getProtocolBinder(int index) {
-            return mProtocolBinders[index];
-        }
-
-        /**
-         * Gets optional extra media route service or protocol specific information about
-         * the connection.  Use the service or protocol name as the prefix for
-         * any extras to avoid namespace collisions.
-         */
-        public @Nullable Bundle getExtras() {
-            return mExtras;
-        }
-
-        /**
-         * Closes all closeables associated with the connection when the connection
-         * is being torn down.
-         */
-        void close() {
-            final int count = mCloseables.size();
-            for (int i = 0; i < count; i++) {
-                try {
-                    mCloseables.get(i).close();
-                } catch (IOException ex) {
-                }
-            }
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "ConnectionInfo{ route=" + mRoute
-                    + ", audioAttributes=" + mAudioAttributes
-                    + ", presentationDisplay=" + mPresentationDisplay
-                    + ", volumeProvider=" + mVolumeProvider
-                    + ", protocolBinders=" + mProtocolBinders + " }";
-        }
-
-        /**
-         * Builds {@link ConnectionInfo} objects.
-         */
-        public static final class Builder {
-            private final RouteInfo mRoute;
-            private AudioAttributes mAudioAttributes;
-            private Display mPresentationDisplay;
-            private VolumeProvider mVolumeProvider;
-            private final IBinder[] mProtocols;
-            private Bundle mExtras;
-            private final ArrayList<Closeable> mCloseables = new ArrayList<Closeable>();
-
-            /**
-             * Creates a builder for connection information.
-             *
-             * @param route The route that is connected.
-             */
-            public Builder(@NonNull RouteInfo route) {
-                if (route == null) {
-                    throw new IllegalArgumentException("route");
-                }
-                mRoute = route;
-                mProtocols = new IBinder[route.getProtocols().size()];
-            }
-
-            /**
-             * Sets the audio attributes which the client should use to stream audio
-             * to the destination, or null if the route does not support live audio streaming.
-             */
-            public @NonNull Builder setAudioAttributes(
-                    @Nullable AudioAttributes audioAttributes) {
-                mAudioAttributes = audioAttributes;
-                return this;
-            }
-
-            /**
-             * Sets the display which the client should use to stream video to the
-             * destination using a {@link Presentation}, or null if the route does not
-             * support live video streaming.
-             */
-            public @NonNull Builder setPresentationDisplay(@Nullable Display display) {
-                mPresentationDisplay = display;
-                return this;
-            }
-
-            /**
-             * Sets the route's volume provider, or null if none.
-             */
-            public @NonNull Builder setVolumeProvider(@Nullable VolumeProvider provider) {
-                mVolumeProvider = provider;
-                return this;
-            }
-
-            /**
-             * Sets the binder stub of a supported route protocol using
-             * the protocol's fully qualified class name.  The protocol must be one
-             * of those that was indicated as being supported by the route.
-             * <p>
-             * If the stub implements {@link Closeable} then it will automatically
-             * be closed when the client disconnects from the route.
-             * </p><p>
-             * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-             * for more information.
-             * </p>
-             */
-            public @NonNull Builder setProtocolStub(@NonNull Class<?> clazz,
-                    @NonNull IInterface stub) {
-                if (clazz == null) {
-                    throw new IllegalArgumentException("clazz must not be null");
-                }
-                if (stub == null) {
-                    throw new IllegalArgumentException("stub must not be null");
-                }
-                if (stub instanceof Closeable) {
-                    mCloseables.add((Closeable)stub);
-                }
-                return setProtocolBinder(clazz.getName(), stub.asBinder());
-            }
-
-            /**
-             * Sets the binder interface of a supported route protocol by name.
-             * The protocol must be one of those that was indicated as being supported
-             * by the route.
-             * <p>
-             * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-             * for more information.
-             * </p>
-             */
-            public @NonNull Builder setProtocolBinder(@NonNull String name,
-                    @NonNull IBinder binder) {
-                if (TextUtils.isEmpty(name)) {
-                    throw new IllegalArgumentException("name must not be null or empty");
-                }
-                if (binder == null) {
-                    throw new IllegalArgumentException("binder must not be null");
-                }
-                int index = mRoute.getProtocols().indexOf(name);
-                if (index < 0) {
-                    throw new IllegalArgumentException("name must specify a protocol that "
-                            + "the route actually declared that it supports: "
-                            + "name=" + name + ", protocols=" + mRoute.getProtocols());
-                }
-                mProtocols[index] = binder;
-                return this;
-            }
-
-            /**
-             * Sets optional extra media route service or protocol specific information about
-             * the connection.  Use the service or protocol name as the prefix for
-             * any extras to avoid namespace collisions.
-             */
-            public @NonNull Builder setExtras(@Nullable Bundle extras) {
-                mExtras = extras;
-                return this;
-            }
-
-            /**
-             * Builds the {@link ConnectionInfo} object.
-             */
-            public @NonNull ConnectionInfo build() {
-                return new ConnectionInfo(mRoute,
-                        mAudioAttributes, mPresentationDisplay,
-                        mVolumeProvider, mProtocols, mExtras, mCloseables);
-            }
-        }
-    }
-
-    /**
-     * Describes one particular way of routing media content to a destination
-     * according to the capabilities specified by a media route selector on behalf
-     * of an application.
-     */
-    public static final class RouteInfo {
-        private final String mId;
-        private final DestinationInfo mDestination;
-        private final MediaRouteSelector mSelector;
-        private final int mFeatures;
-        private final ArrayList<String> mProtocols;
-        private final Bundle mExtras;
-
-        RouteInfo(String id, DestinationInfo destination, MediaRouteSelector selector,
-                int features, ArrayList<String> protocols, Bundle extras) {
-            mId = id;
-            mDestination = destination;
-            mSelector = selector;
-            mFeatures = features;
-            mProtocols = protocols;
-            mExtras = extras;
-        }
-
-        /**
-         * Gets the route's stable identifier.
-         * <p>
-         * The id is intended to uniquely identify the route among all routes that
-         * are offered by a particular destination in such a way that the client can
-         * refer to it at a later time.
-         * </p>
-         */
-        public @NonNull String getId() {
-            return mId;
-        }
-
-        /**
-         * Gets the destination that is offering this route.
-         */
-        public @NonNull DestinationInfo getDestination() {
-            return mDestination;
-        }
-
-        /**
-         * Gets the media route selector provided by the client for which this
-         * route was created.
-         * <p>
-         * It is implied that this route supports all of the required capabilities
-         * that were expressed in the selector.
-         * </p>
-         */
-        public @NonNull MediaRouteSelector getSelector() {
-            return mSelector;
-        }
-
-        /**
-         * Gets the set of supported route features.
-         */
-        public @RouteFeatures int getFeatures() {
-            return mFeatures;
-        }
-
-        /**
-         * Gets the list of supported route protocols.
-         * <p>
-         * Refer to <code>android.support.media.protocols.MediaRouteProtocol</code>
-         * for more information.
-         * </p>
-         */
-        public @NonNull List<String> getProtocols() {
-            return mProtocols;
-        }
-
-        /**
-         * Gets optional extra information about the route, or null if none.
-         */
-        public @Nullable Bundle getExtras() {
-            return mExtras;
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "RouteInfo{ id=" + mId + ", destination=" + mDestination
-                    + ", features=0x" + Integer.toHexString(mFeatures)
-                    + ", selector=" + mSelector + ", protocols=" + mProtocols
-                    + ", extras=" + mExtras + " }";
-        }
-
-        /**
-         * Builds {@link RouteInfo} objects.
-         */
-        public static final class Builder {
-            private final DestinationInfo mDestination;
-            private final String mId;
-            private final MediaRouteSelector mSelector;
-            private int mFeatures;
-            private final ArrayList<String> mProtocols = new ArrayList<String>();
-            private Bundle mExtras;
-
-            /**
-             * Creates a builder for route information.
-             *
-             * @param id The route's stable identifier.
-             * @param destination The destination of this route.
-             * @param selector The media route selector provided by the client for which
-             * this route was created.  This must be one of the selectors that was
-             * included in the discovery request.
-             */
-            public Builder(@NonNull String id, @NonNull DestinationInfo destination,
-                    @NonNull MediaRouteSelector selector) {
-                if (TextUtils.isEmpty(id)) {
-                    throw new IllegalArgumentException("id must not be null or empty");
-                }
-                if (destination == null) {
-                    throw new IllegalArgumentException("destination must not be null");
-                }
-                if (selector == null) {
-                    throw new IllegalArgumentException("selector must not be null");
-                }
-                mDestination = destination;
-                mId = id;
-                mSelector = selector;
-            }
-
-            /**
-             * Sets the set of supported route features.
-             */
-            public @NonNull Builder setFeatures(@RouteFeatures int features) {
-                mFeatures = features;
-                return this;
-            }
-
-            /**
-             * Adds a supported route protocol using its fully qualified class name.
-             * <p>
-             * If the protocol was not requested by the client in its selector
-             * then it will be silently discarded.
-             * </p>
-             */
-            public @NonNull <T extends IInterface> Builder addProtocol(@NonNull Class<T> clazz) {
-                if (clazz == null) {
-                    throw new IllegalArgumentException("clazz must not be null");
-                }
-                return addProtocol(clazz.getName());
-            }
-
-            /**
-             * Adds a supported route protocol by name.
-             * <p>
-             * If the protocol was not requested by the client in its selector
-             * then it will be silently discarded.
-             * </p>
-             */
-            public @NonNull Builder addProtocol(@NonNull String name) {
-                if (TextUtils.isEmpty(name)) {
-                    throw new IllegalArgumentException("name must not be null");
-                }
-                if (mSelector.containsProtocol(name)) {
-                    mProtocols.add(name);
-                }
-                return this;
-            }
-
-            /**
-             * Sets optional extra information about the route, or null if none.
-             */
-            public @NonNull Builder setExtras(@Nullable Bundle extras) {
-                mExtras = extras;
-                return this;
-            }
-
-            /**
-             * Builds the {@link RouteInfo} object.
-             * <p>
-             * Ensures that all required protocols have been supplied.
-             * </p>
-             */
-            public @NonNull RouteInfo build() {
-                int missingFeatures = mSelector.getRequiredFeatures() & ~mFeatures;
-                if (missingFeatures != 0) {
-                    throw new IllegalStateException("The media route selector "
-                            + "specified required features which this route does "
-                            + "not appear to support so it should not have been published: "
-                            + "missing 0x" + Integer.toHexString(missingFeatures));
-                }
-                for (String protocol : mSelector.getRequiredProtocols()) {
-                    if (!mProtocols.contains(protocol)) {
-                        throw new IllegalStateException("The media route selector "
-                                + "specified required protocols which this route "
-                                + "does not appear to support so it should not have "
-                                + "been published: missing " + protocol);
-                    }
-                }
-                return new RouteInfo(mId, mDestination, mSelector,
-                        mFeatures, mProtocols, mExtras);
-            }
-        }
-    }
-
-    /**
-     * Describes a destination for media content such as a device,
-     * an individual port on a device, or a group of devices.
-     */
-    public static final class DestinationInfo {
-        private final String mId;
-        private final ServiceMetadata mService;
-        private final CharSequence mName;
-        private final CharSequence mDescription;
-        private final int mIconResourceId;
-        private final Bundle mExtras;
-
-        DestinationInfo(String id, ServiceMetadata service,
-                CharSequence name, CharSequence description,
-                int iconResourceId, Bundle extras) {
-            mId = id;
-            mService = service;
-            mName = name;
-            mDescription = description;
-            mIconResourceId = iconResourceId;
-            mExtras = extras;
-        }
-
-        /**
-         * Gets the destination's stable identifier.
-         * <p>
-         * The id is intended to uniquely identify the destination among all destinations
-         * provided by the media route service in such a way that the client can
-         * refer to it at a later time.  Ideally, the id should be resilient to
-         * user-initiated actions such as changes to the name or description
-         * of the destination.
-         * </p>
-         */
-        public @NonNull String getId() {
-            return mId;
-        }
-
-        /**
-         * Gets metadata about the service that is providing access to this destination.
-         */
-        public @NonNull ServiceMetadata getServiceMetadata() {
-            return mService;
-        }
-
-        /**
-         * Gets the destination's name for display to the user.
-         */
-        public @NonNull CharSequence getName() {
-            return mName;
-        }
-
-        /**
-         * Gets the destination's description for display to the user, or null if none.
-         */
-        public @Nullable CharSequence getDescription() {
-            return mDescription;
-        }
-
-        /**
-         * Gets an icon resource from the service's package which is used
-         * to identify the destination, or -1 if none.
-         */
-        public @DrawableRes int getIconResourceId() {
-            return mIconResourceId;
-        }
-
-        /**
-         * Loads the icon drawable, or null if none.
-         */
-        public @Nullable Drawable loadIcon(@NonNull PackageManager pm) {
-            return mIconResourceId >= 0 ? mService.getDrawable(pm, mIconResourceId) : null;
-        }
-
-        /**
-         * Gets optional extra information about the destination, or null if none.
-         */
-        public @Nullable Bundle getExtras() {
-            return mExtras;
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "DestinationInfo{ id=" + mId + ", service=" + mService + ", name=" + mName
-                    + ", description=" + mDescription + ", iconResourceId=" + mIconResourceId
-                    + ", extras=" + mExtras + " }";
-        }
-
-        /**
-         * Builds {@link DestinationInfo} objects.
-         */
-        public static final class Builder {
-            private final String mId;
-            private final ServiceMetadata mService;
-            private final CharSequence mName;
-            private CharSequence mDescription;
-            private int mIconResourceId = -1;
-            private Bundle mExtras;
-
-            /**
-             * Creates a builder for destination information.
-             *
-             * @param id The destination's stable identifier.
-             * @param service Metatada about the service that is providing access to
-             * this destination.
-             * @param name The destination's name for display to the user.
-             */
-            public Builder(@NonNull String id, @NonNull ServiceMetadata service,
-                    @NonNull CharSequence name) {
-                if (TextUtils.isEmpty(id)) {
-                    throw new IllegalArgumentException("id must not be null or empty");
-                }
-                if (service == null) {
-                    throw new IllegalArgumentException("service must not be null");
-                }
-                if (TextUtils.isEmpty(name)) {
-                    throw new IllegalArgumentException("name must not be null or empty");
-                }
-                mId = id;
-                mService = service;
-                mName = name;
-            }
-
-            /**
-             * Sets the destination's description for display to the user, or null if none.
-             */
-            public @NonNull Builder setDescription(@Nullable CharSequence description) {
-                mDescription = description;
-                return this;
-            }
-
-            /**
-             * Sets an icon resource from this package used to identify the destination,
-             * or -1 if none.
-             */
-            public @NonNull Builder setIconResourceId(@DrawableRes int resid) {
-                mIconResourceId = resid;
-                return this;
-            }
-
-            /**
-             * Gets optional extra information about the destination, or null if none.
-             */
-            public @NonNull Builder setExtras(@Nullable Bundle extras) {
-                mExtras = extras;
-                return this;
-            }
-
-            /**
-             * Builds the {@link DestinationInfo} object.
-             */
-            public @NonNull DestinationInfo build() {
-                return new DestinationInfo(mId, mService, mName, mDescription,
-                        mIconResourceId, mExtras);
-            }
-        }
-    }
-
-    /**
-     * Describes metadata about a {@link MediaRouteService} which is providing
-     * access to certain kinds of destinations.
-     */
-    public static final class ServiceMetadata {
-        private final ServiceInfo mService;
-        private CharSequence mLabel;
-        private Drawable mIcon;
-
-        ServiceMetadata(Service service) throws NameNotFoundException {
-            mService = service.getPackageManager().getServiceInfo(
-                    new ComponentName(service, service.getClass()),
-                    PackageManager.GET_META_DATA);
-        }
-
-        ServiceMetadata(ServiceInfo service) {
-            mService = service;
-        }
-
-        /**
-         * Gets the service's component information including it name, label and icon.
-         */
-        public @NonNull ServiceInfo getService() {
-            return mService;
-        }
-
-        /**
-         * Gets the service's component name.
-         */
-        public @NonNull ComponentName getComponentName() {
-            return new ComponentName(mService.packageName, mService.name);
-        }
-
-        /**
-         * Gets the service's package name.
-         */
-        public @NonNull String getPackageName() {
-            return mService.packageName;
-        }
-
-        /**
-         * Gets the service's name for display to the user, or null if none.
-         */
-        public @NonNull CharSequence getLabel(@NonNull PackageManager pm) {
-            if (mLabel == null) {
-                mLabel = mService.loadLabel(pm);
-            }
-            return mLabel;
-        }
-
-        /**
-         * Gets the icon drawable, or null if none.
-         */
-        public @Nullable Drawable getIcon(@NonNull PackageManager pm) {
-            if (mIcon == null) {
-                mIcon = mService.loadIcon(pm);
-            }
-            return mIcon;
-        }
-
-        // TODO: add service metadata
-
-        Drawable getDrawable(PackageManager pm, int resid) {
-            return pm.getDrawable(getPackageName(), resid, mService.applicationInfo);
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "ServiceInfo{ service=" + getComponentName().toShortString() + " }";
-        }
-    }
-
-    /**
-     * Describes a request to discover routes on behalf of an application.
-     */
-    public static final class DiscoveryRequest {
-        private final ArrayList<MediaRouteSelector> mSelectors =
-                new ArrayList<MediaRouteSelector>();
-        private int mFlags;
-
-        DiscoveryRequest(@NonNull List<MediaRouteSelector> selectors) {
-            setSelectors(selectors);
-        }
-
-        /**
-         * Sets the list of media route selectors to consider during discovery.
-         */
-        public void setSelectors(@NonNull List<MediaRouteSelector> selectors) {
-            if (selectors == null) {
-                throw new IllegalArgumentException("selectors");
-            }
-            mSelectors.clear();
-            mSelectors.addAll(selectors);
-        }
-
-        /**
-         * Gets the list of media route selectors to consider during discovery.
-         */
-        public @NonNull List<MediaRouteSelector> getSelectors() {
-            return mSelectors;
-        }
-
-        /**
-         * Gets discovery flags, such as {@link MediaRouter#DISCOVERY_FLAG_BACKGROUND}.
-         */
-        public @DiscoveryFlags int getFlags() {
-            return mFlags;
-        }
-
-        /**
-         * Sets discovery flags, such as {@link MediaRouter#DISCOVERY_FLAG_BACKGROUND}.
-         */
-        public void setFlags(@DiscoveryFlags int flags) {
-            mFlags = flags;
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "DiscoveryRequest{ selectors=" + mSelectors
-                    + ", flags=0x" + Integer.toHexString(mFlags)
-                    + " }";
-        }
-    }
-
-    /**
-     * Describes a request to connect to a previously discovered route on
-     * behalf of an application.
-     */
-    public static final class ConnectionRequest {
-        private RouteInfo mRoute;
-        private int mFlags;
-        private Bundle mExtras;
-
-        ConnectionRequest(@NonNull RouteInfo route) {
-            setRoute(route);
-        }
-
-        /**
-         * Gets the route to which to connect.
-         */
-        public @NonNull RouteInfo getRoute() {
-            return mRoute;
-        }
-
-        /**
-         * Sets the route to which to connect.
-         */
-        public void setRoute(@NonNull RouteInfo route) {
-            if (route == null) {
-                throw new IllegalArgumentException("route must not be null");
-            }
-            mRoute = route;
-        }
-
-        /**
-         * Gets connection flags, such as {@link MediaRouter#CONNECTION_FLAG_BARGE}.
-         */
-        public @ConnectionFlags int getFlags() {
-            return mFlags;
-        }
-
-        /**
-         * Sets connection flags, such as {@link MediaRouter#CONNECTION_FLAG_BARGE}.
-         */
-        public void setFlags(@ConnectionFlags int flags) {
-            mFlags = flags;
-        }
-
-        /**
-         * Gets optional extras supplied by the application as part of the call to
-         * connect, or null if none.  The media route service may use this
-         * information to configure the route during connection.
-         */
-        public @Nullable Bundle getExtras() {
-            return mExtras;
-        }
-
-        /**
-         * Sets optional extras supplied by the application as part of the call to
-         * connect, or null if none.  The media route service may use this
-         * information to configure the route during connection.
-         */
-        public void setExtras(@Nullable Bundle extras) {
-            mExtras = extras;
-        }
-
-        @Override
-        public @NonNull String toString() {
-            return "ConnectionRequest{ route=" + mRoute
-                    + ", flags=0x" + Integer.toHexString(mFlags)
-                    + ", extras=" + mExtras + " }";
-        }
-    }
-
-    /**
-     * Callback interface to specify policy for route discovery, filtering,
-     * and connection establishment as well as observe media router state changes.
-     */
-    public static abstract class RoutingCallback extends StateCallback {
-        /**
-         * Called to prepare a discovery request object to specify the desired
-         * media route selectors when the media router has been asked to start discovery.
-         * <p>
-         * By default, the discovery request contains all of the selectors which
-         * have been added to the media router.  Subclasses may override the list of
-         * selectors by modifying the discovery request object before returning.
-         * </p>
-         *
-         * @param request The discovery request object which may be modified by
-         * this method to alter how discovery will be performed.
-         * @param selectors The immutable list of media route selectors which were
-         * added to the media router.
-         * @return True to allow discovery to proceed or false to abort it.
-         * By default, this methods returns true.
-         */
-        public boolean onPrepareDiscoveryRequest(@NonNull DiscoveryRequest request,
-                @NonNull List<MediaRouteSelector> selectors) {
-            return true;
-        }
-
-        /**
-         * Called to prepare a connection request object to specify the desired
-         * route and connection parameters when the media router has been asked to
-         * connect to a particular destination.
-         * <p>
-         * By default, the connection request specifies the first available route
-         * to the destination.  Subclasses may override the route and destination
-         * or set additional connection parameters by modifying the connection request
-         * object before returning.
-         * </p>
-         *
-         * @param request The connection request object which may be modified by
-         * this method to alter how the connection will be established.
-         * @param destination The destination to which the media router was asked
-         * to connect.
-         * @param routes The list of routes that belong to that destination sorted
-         * in the same order as their matching media route selectors which were
-         * used during discovery.
-         * @return True to allow the connection to proceed or false to abort it.
-         * By default, this methods returns true.
-         */
-        public boolean onPrepareConnectionRequest(
-                @NonNull ConnectionRequest request,
-                @NonNull DestinationInfo destination, @NonNull List<RouteInfo> routes) {
-            return true;
-        }
-    }
-
-    /**
-     * Callback class to receive events from a {@link MediaRouter.Delegate}.
-     */
-    public static abstract class StateCallback {
-        /**
-         * Called when the media router has been released.
-         */
-        public void onReleased() { }
-
-        /**
-         * Called when the discovery state has changed.
-         *
-         * @param state The new discovery state: one of
-         * {@link #DISCOVERY_STATE_STOPPED} or {@link #DISCOVERY_STATE_STARTED}.
-         */
-        public void onDiscoveryStateChanged(@DiscoveryState int state) { }
-
-        /**
-         * Called when the connection state has changed.
-         *
-         * @param state The new connection state: one of
-         * {@link #CONNECTION_STATE_DISCONNECTED}, {@link #CONNECTION_STATE_CONNECTING}
-         * or {@link #CONNECTION_STATE_CONNECTED}.
-         */
-        public void onConnectionStateChanged(@ConnectionState int state) { }
-
-        /**
-         * Called when the selected destination has changed.
-         *
-         * @param destination The new selected destination, or null if none.
-         */
-        public void onSelectedDestinationChanged(@Nullable DestinationInfo destination) { }
-
-        /**
-         * Called when route discovery has started.
-         */
-        public void onDiscoveryStarted() { }
-
-        /**
-         * Called when route discovery has stopped normally.
-         * <p>
-         * Abnormal termination is reported via {@link #onDiscoveryFailed}.
-         * </p>
-         */
-        public void onDiscoveryStopped() { }
-
-        /**
-         * Called when discovery has failed in a non-recoverable manner.
-         *
-         * @param error The error code: one of
-         * {@link MediaRouter#DISCOVERY_ERROR_UNKNOWN},
-         * {@link MediaRouter#DISCOVERY_ERROR_ABORTED},
-         * or {@link MediaRouter#DISCOVERY_ERROR_NO_CONNECTIVITY}.
-         * @param message The localized error message, or null if none.  This message
-         * may be shown to the user.
-         * @param extras Additional information about the error which a client
-         * may use, or null if none.
-         */
-        public void onDiscoveryFailed(@DiscoveryError int error, @Nullable CharSequence message,
-                @Nullable Bundle extras) { }
-
-        /**
-         * Called when a new destination is found or has changed during discovery.
-         * <p>
-         * Certain destinations may be omitted because they have been filtered
-         * out by the media router's routing callback.
-         * </p>
-         *
-         * @param destination The destination that was found.
-         */
-        public void onDestinationFound(@NonNull DestinationInfo destination) { }
-
-        /**
-         * Called when a destination is no longer reachable or is no longer
-         * offering any routes that satisfy the discovery request.
-         *
-         * @param destination The destination that went away.
-         */
-        public void onDestinationLost(@NonNull DestinationInfo destination) { }
-
-        /**
-         * Called when a connection attempt begins.
-         */
-        public void onConnecting() { }
-
-        /**
-         * Called when the connection succeeds.
-         */
-        public void onConnected() { }
-
-        /**
-         * Called when the connection is terminated normally.
-         * <p>
-         * Abnormal termination is reported via {@link #onConnectionFailed}.
-         * </p>
-         */
-        public void onDisconnected() { }
-
-        /**
-         * Called when a connection attempt or connection in
-         * progress has failed in a non-recoverable manner.
-         *
-         * @param error The error code: one of
-         * {@link MediaRouter#CONNECTION_ERROR_ABORTED},
-         * {@link MediaRouter#CONNECTION_ERROR_UNAUTHORIZED},
-         * {@link MediaRouter#CONNECTION_ERROR_UNREACHABLE},
-         * {@link MediaRouter#CONNECTION_ERROR_BUSY},
-         * {@link MediaRouter#CONNECTION_ERROR_TIMEOUT},
-         * {@link MediaRouter#CONNECTION_ERROR_BROKEN},
-         * or {@link MediaRouter#CONNECTION_ERROR_BARGED}.
-         * @param message The localized error message, or null if none.  This message
-         * may be shown to the user.
-         * @param extras Additional information about the error which a client
-         * may use, or null if none.
-         */
-        public void onConnectionFailed(@ConnectionError int error,
-                @Nullable CharSequence message, @Nullable Bundle extras) { }
-    }
-}
diff --git a/media/java/android/media/routing/ParcelableConnectionInfo.aidl b/media/java/android/media/routing/ParcelableConnectionInfo.aidl
deleted file mode 100644
index 4a9ec94..0000000
--- a/media/java/android/media/routing/ParcelableConnectionInfo.aidl
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Copyright 2014, 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 android.media.routing;
-
-parcelable ParcelableConnectionInfo;
diff --git a/media/java/android/media/routing/ParcelableConnectionInfo.java b/media/java/android/media/routing/ParcelableConnectionInfo.java
deleted file mode 100644
index 45cfe9f..0000000
--- a/media/java/android/media/routing/ParcelableConnectionInfo.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.media.AudioAttributes;
-import android.os.Bundle;
-import android.os.IBinder;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Internal parcelable representation of a media route connection.
- */
-class ParcelableConnectionInfo implements Parcelable {
-    public AudioAttributes audioAttributes;
-    public int presentationDisplayId = -1;
-    // todo: volume
-    public IBinder[] protocolBinders;
-    public Bundle extras;
-
-    public static final Parcelable.Creator<ParcelableConnectionInfo> CREATOR =
-            new Parcelable.Creator<ParcelableConnectionInfo>() {
-        @Override
-        public ParcelableConnectionInfo createFromParcel(Parcel source) {
-            ParcelableConnectionInfo info = new ParcelableConnectionInfo();
-            if (source.readInt() != 0) {
-                info.audioAttributes = AudioAttributes.CREATOR.createFromParcel(source);
-            }
-            info.presentationDisplayId = source.readInt();
-            info.protocolBinders = source.createBinderArray();
-            info.extras = source.readBundle();
-            return info;
-        }
-
-        @Override
-        public ParcelableConnectionInfo[] newArray(int size) {
-            return new ParcelableConnectionInfo[size];
-        }
-    };
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        if (audioAttributes != null) {
-            dest.writeInt(1);
-            audioAttributes.writeToParcel(dest, flags);
-        } else {
-            dest.writeInt(0);
-        }
-        dest.writeInt(presentationDisplayId);
-        dest.writeBinderArray(protocolBinders);
-        dest.writeBundle(extras);
-    }
-}
diff --git a/media/java/android/media/routing/ParcelableDestinationInfo.aidl b/media/java/android/media/routing/ParcelableDestinationInfo.aidl
deleted file mode 100644
index bf1c198..0000000
--- a/media/java/android/media/routing/ParcelableDestinationInfo.aidl
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Copyright 2014, 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 android.media.routing;
-
-parcelable ParcelableDestinationInfo;
diff --git a/media/java/android/media/routing/ParcelableDestinationInfo.java b/media/java/android/media/routing/ParcelableDestinationInfo.java
deleted file mode 100644
index eca5eec..0000000
--- a/media/java/android/media/routing/ParcelableDestinationInfo.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.text.TextUtils;
-
-/**
- * Internal parcelable representation of a media destination.
- */
-class ParcelableDestinationInfo implements Parcelable {
-    public String id;
-    public CharSequence name;
-    public CharSequence description;
-    public int iconResourceId;
-    public Bundle extras;
-
-    public static final Parcelable.Creator<ParcelableDestinationInfo> CREATOR =
-            new Parcelable.Creator<ParcelableDestinationInfo>() {
-        @Override
-        public ParcelableDestinationInfo createFromParcel(Parcel source) {
-            ParcelableDestinationInfo info = new ParcelableDestinationInfo();
-            info.id = source.readString();
-            info.name = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(source);
-            info.description = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(source);
-            info.iconResourceId = source.readInt();
-            info.extras = source.readBundle();
-            return info;
-        }
-
-        @Override
-        public ParcelableDestinationInfo[] newArray(int size) {
-            return new ParcelableDestinationInfo[size];
-        }
-    };
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeString(id);
-        TextUtils.writeToParcel(name, dest, flags);
-        TextUtils.writeToParcel(description, dest, flags);
-        dest.writeInt(iconResourceId);
-        dest.writeBundle(extras);
-    }
-}
diff --git a/media/java/android/media/routing/ParcelableRouteInfo.aidl b/media/java/android/media/routing/ParcelableRouteInfo.aidl
deleted file mode 100644
index 126afaa..0000000
--- a/media/java/android/media/routing/ParcelableRouteInfo.aidl
+++ /dev/null
@@ -1,18 +0,0 @@
-/* Copyright 2014, 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 android.media.routing;
-
-parcelable ParcelableRouteInfo;
diff --git a/media/java/android/media/routing/ParcelableRouteInfo.java b/media/java/android/media/routing/ParcelableRouteInfo.java
deleted file mode 100644
index fb1a547..0000000
--- a/media/java/android/media/routing/ParcelableRouteInfo.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.media.routing;
-
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Internal parcelable representation of a media route.
- */
-class ParcelableRouteInfo implements Parcelable {
-    public String id;
-    public int selectorIndex; // index of selector within list used for discovery
-    public int features;
-    public String[] protocols;
-    public Bundle extras;
-
-    public static final Parcelable.Creator<ParcelableRouteInfo> CREATOR =
-            new Parcelable.Creator<ParcelableRouteInfo>() {
-        @Override
-        public ParcelableRouteInfo createFromParcel(Parcel source) {
-            ParcelableRouteInfo info = new ParcelableRouteInfo();
-            info.id = source.readString();
-            info.selectorIndex = source.readInt();
-            info.features = source.readInt();
-            info.protocols = source.createStringArray();
-            info.extras = source.readBundle();
-            return info;
-        }
-
-        @Override
-        public ParcelableRouteInfo[] newArray(int size) {
-            return new ParcelableRouteInfo[size];
-        }
-    };
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeString(id);
-        dest.writeInt(selectorIndex);
-        dest.writeInt(features);
-        dest.writeStringArray(protocols);
-        dest.writeBundle(extras);
-    }
-}
diff --git a/media/java/android/media/session/ISession.aidl b/media/java/android/media/session/ISession.aidl
index af3b72e..bd0019f 100644
--- a/media/java/android/media/session/ISession.aidl
+++ b/media/java/android/media/session/ISession.aidl
@@ -19,7 +19,6 @@
 import android.content.pm.ParceledListSlice;
 import android.media.AudioAttributes;
 import android.media.MediaMetadata;
-import android.media.routing.IMediaRouter;
 import android.media.session.ISessionController;
 import android.media.session.PlaybackState;
 import android.media.session.MediaSession;
@@ -35,7 +34,6 @@
     ISessionController getController();
     void setFlags(int flags);
     void setActive(boolean active);
-    void setMediaRouter(in IMediaRouter router);
     void setMediaButtonReceiver(in PendingIntent mbr);
     void setLaunchPendingIntent(in PendingIntent pi);
     void destroy();
diff --git a/media/java/android/media/session/ISessionCallback.aidl b/media/java/android/media/session/ISessionCallback.aidl
index 9911129..49087b0 100644
--- a/media/java/android/media/session/ISessionCallback.aidl
+++ b/media/java/android/media/session/ISessionCallback.aidl
@@ -30,7 +30,7 @@
 
     // These callbacks are for the TransportPerformer
     void onPlay();
-    void onPlayUri(in Uri uri, in Bundle extras);
+    void onPlayFromMediaId(String uri, in Bundle extras);
     void onPlayFromSearch(String query, in Bundle extras);
     void onSkipToTrack(long id);
     void onPause();
diff --git a/media/java/android/media/session/ISessionController.aidl b/media/java/android/media/session/ISessionController.aidl
index 5764bd1..d684688 100644
--- a/media/java/android/media/session/ISessionController.aidl
+++ b/media/java/android/media/session/ISessionController.aidl
@@ -20,8 +20,6 @@
 import android.content.pm.ParceledListSlice;
 import android.media.MediaMetadata;
 import android.media.Rating;
-import android.media.routing.IMediaRouterDelegate;
-import android.media.routing.IMediaRouterStateCallback;
 import android.media.session.ISessionControllerCallback;
 import android.media.session.ParcelableVolumeInfo;
 import android.media.session.PlaybackState;
@@ -51,13 +49,11 @@
     void adjustVolume(int direction, int flags, String packageName);
     void setVolumeTo(int value, int flags, String packageName);
 
-    IMediaRouterDelegate createMediaRouterDelegate(IMediaRouterStateCallback callback);
-
     // These commands are for the TransportControls
     void play();
-    void playUri(in Uri uri, in Bundle extras);
+    void playFromMediaId(String uri, in Bundle extras);
     void playFromSearch(String string, in Bundle extras);
-    void skipToTrack(long id);
+    void skipToQueueItem(long id);
     void pause();
     void stop();
     void next();
diff --git a/media/java/android/media/session/MediaController.java b/media/java/android/media/session/MediaController.java
index 63c85f8..be86741 100644
--- a/media/java/android/media/session/MediaController.java
+++ b/media/java/android/media/session/MediaController.java
@@ -26,7 +26,6 @@
 import android.media.MediaMetadata;
 import android.media.Rating;
 import android.media.VolumeProvider;
-import android.media.routing.MediaRouter;
 import android.net.Uri;
 import android.os.Bundle;
 import android.os.Handler;
@@ -48,8 +47,9 @@
  * receive updates from the session, such as metadata and play state changes.
  * <p>
  * A MediaController can be created through {@link MediaSessionManager} if you
- * hold the "android.permission.MEDIA_CONTENT_CONTROL" permission or directly if
- * you have a {@link MediaSession.Token} from the session owner.
+ * hold the "android.permission.MEDIA_CONTENT_CONTROL" permission or are an
+ * enabled notification listener or by getting a {@link MediaSession.Token}
+ * directly from the session owner.
  * <p>
  * MediaController objects are thread-safe.
  */
@@ -119,17 +119,6 @@
     }
 
     /**
-     * Creates a media router delegate through which the destination of the media
-     * router may be observed and controlled.
-     *
-     * @return The media router delegate, or null if the media session does
-     * not support media routing.
-     */
-    public @Nullable MediaRouter.Delegate createMediaRouterDelegate() {
-        return new MediaRouter.Delegate();
-    }
-
-    /**
      * Send the specified media button event to the session. Only media keys can
      * be sent by this method, other keys will be ignored.
      *
@@ -185,7 +174,7 @@
      *
      * @return The current play queue or null.
      */
-    public @Nullable List<MediaSession.Track> getQueue() {
+    public @Nullable List<MediaSession.QueueItem> getQueue() {
         try {
             ParceledListSlice queue = mSessionBinder.getQueue();
             if (queue != null) {
@@ -259,18 +248,18 @@
     }
 
     /**
-     * Get the current volume info for this session.
+     * Get the current playback info for this session.
      *
-     * @return The current volume info or null.
+     * @return The current playback info or null.
      */
-    public @Nullable VolumeInfo getVolumeInfo() {
+    public @Nullable PlaybackInfo getPlaybackInfo() {
         try {
             ParcelableVolumeInfo result = mSessionBinder.getVolumeAttributes();
-            return new VolumeInfo(result.volumeType, result.audioAttrs, result.controlType,
+            return new PlaybackInfo(result.volumeType, result.audioAttrs, result.controlType,
                     result.maxVolume, result.currentVolume);
 
         } catch (RemoteException e) {
-            Log.wtf(TAG, "Error calling getVolumeInfo.", e);
+            Log.wtf(TAG, "Error calling getAudioInfo.", e);
         }
         return null;
     }
@@ -281,7 +270,7 @@
      *
      * @return A {@link PendingIntent} to launch UI or null.
      */
-    public @Nullable PendingIntent getLaunchActivity() {
+    public @Nullable PendingIntent getSessionActivity() {
         try {
             return mSessionBinder.getLaunchPendingIntent();
         } catch (RemoteException e) {
@@ -305,9 +294,10 @@
      * {@link VolumeProvider#VOLUME_CONTROL_ABSOLUTE}. The flags in
      * {@link AudioManager} may be used to affect the handling.
      *
-     * @see #getVolumeInfo()
+     * @see #getPlaybackInfo()
      * @param value The value to set it to, between 0 and the reported max.
-     * @param flags Any flags to pass with the command.
+     * @param flags Flags from {@link AudioManager} to include with the volume
+     *            request.
      */
     public void setVolumeTo(int value, int flags) {
         try {
@@ -326,7 +316,7 @@
      * {@link VolumeProvider#VOLUME_CONTROL_ABSOLUTE}. The flags in
      * {@link AudioManager} may be used to affect the handling.
      *
-     * @see #getVolumeInfo()
+     * @see #getPlaybackInfo()
      * @param direction The direction to adjust the volume in.
      * @param flags Any flags to pass with the command.
      */
@@ -339,24 +329,24 @@
     }
 
     /**
-     * Adds a callback to receive updates from the Session. Updates will be
+     * Registers a callback to receive updates from the Session. Updates will be
      * posted on the caller's thread.
      *
      * @param callback The callback object, must not be null.
      */
-    public void addCallback(@NonNull Callback callback) {
-        addCallback(callback, null);
+    public void registerCallback(@NonNull Callback callback) {
+        registerCallback(callback, null);
     }
 
     /**
-     * Adds a callback to receive updates from the session. Updates will be
+     * Registers a callback to receive updates from the session. Updates will be
      * posted on the specified handler's thread.
      *
      * @param callback The callback object, must not be null.
      * @param handler The handler to post updates on. If null the callers thread
      *            will be used.
      */
-    public void addCallback(@NonNull Callback callback, @Nullable Handler handler) {
+    public void registerCallback(@NonNull Callback callback, @Nullable Handler handler) {
         if (callback == null) {
             throw new IllegalArgumentException("callback must not be null");
         }
@@ -369,12 +359,12 @@
     }
 
     /**
-     * Stop receiving updates on the specified callback. If an update has
-     * already been posted you may still receive it after calling this method.
+     * Unregisters the specified callback. If an update has already been posted
+     * you may still receive it after calling this method.
      *
      * @param callback The callback to remove.
      */
-    public void removeCallback(@NonNull Callback callback) {
+    public void unregisterCallback(@NonNull Callback callback) {
         if (callback == null) {
             throw new IllegalArgumentException("callback must not be null");
         }
@@ -505,7 +495,7 @@
 
     /**
      * Callback for receiving updates on from the session. A Callback can be
-     * registered using {@link #addCallback}
+     * registered using {@link #registerCallback}
      */
     public static abstract class Callback {
         /**
@@ -544,13 +534,14 @@
         }
 
         /**
-         * Override to handle changes to tracks in the queue.
+         * Override to handle changes to items in the queue.
          *
-         * @param queue A list of tracks in the current play queue. It should include the currently
-         *              playing track as well as previous and upcoming tracks if applicable.
-         * @see MediaSession.Track
+         * @param queue A list of items in the current play queue. It should
+         *            include the currently playing item as well as previous and
+         *            upcoming items if applicable.
+         * @see MediaSession.QueueItem
          */
-        public void onQueueChanged(@Nullable List<MediaSession.Track> queue) {
+        public void onQueueChanged(@Nullable List<MediaSession.QueueItem> queue) {
         }
 
         /**
@@ -572,11 +563,11 @@
         }
 
         /**
-         * Override to handle changes to the volume info.
+         * Override to handle changes to the audio info.
          *
-         * @param info The current volume info for this session.
+         * @param info The current audio info for this session.
          */
-        public void onVolumeInfoChanged(VolumeInfo info) {
+        public void onAudioInfoChanged(PlaybackInfo info) {
         }
     }
 
@@ -604,31 +595,36 @@
         /**
          * Request that the player start playback for a specific {@link Uri}.
          *
-         * @param uri The uri of the requested media.
+         * @param mediaId The uri of the requested media.
          * @param extras Optional extras that can include extra information about the media item
          *               to be played.
          */
-        public void playUri(Uri uri, Bundle extras) {
-            if (uri == null) {
-                throw new IllegalArgumentException("You must specify a non-null Uri for playUri.");
+        public void playFromMediaId(String mediaId, Bundle extras) {
+            if (TextUtils.isEmpty(mediaId)) {
+                throw new IllegalArgumentException(
+                        "You must specify a non-empty String for playFromMediaId.");
             }
             try {
-                mSessionBinder.playUri(uri, extras);
+                mSessionBinder.playFromMediaId(mediaId, extras);
             } catch (RemoteException e) {
-                Log.wtf(TAG, "Error calling play(" + uri + ").", e);
+                Log.wtf(TAG, "Error calling play(" + mediaId + ").", e);
             }
         }
 
         /**
          * Request that the player start playback for a specific search query.
+         * An empty or null query should be treated as a request to play any
+         * music.
          *
          * @param query The search query.
-         * @param extras Optional extras that can include extra information about the query.
+         * @param extras Optional extras that can include extra information
+         *            about the query.
          */
         public void playFromSearch(String query, Bundle extras) {
-            if (TextUtils.isEmpty(query)) {
-                throw new IllegalArgumentException(
-                        "You must specify a non-empty search query for playFromSearch.");
+            if (query == null) {
+                // This is to remain compatible with
+                // INTENT_ACTION_MEDIA_PLAY_FROM_SEARCH
+                query = "";
             }
             try {
                 mSessionBinder.playFromSearch(query, extras);
@@ -638,14 +634,14 @@
         }
 
         /**
-         * Play a track with a specific id in the play queue.
-         * If you specify an id that is not in the play queue, the behavior is undefined.
+         * Play an item with a specific id in the play queue. If you specify an
+         * id that is not in the play queue, the behavior is undefined.
          */
-        public void skipToTrack(long id) {
+        public void skipToQueueItem(long id) {
             try {
-                mSessionBinder.skipToTrack(id);
+                mSessionBinder.skipToQueueItem(id);
             } catch (RemoteException e) {
-                Log.wtf(TAG, "Error calling skipToTrack(" + id + ").", e);
+                Log.wtf(TAG, "Error calling skipToItem(" + id + ").", e);
             }
         }
 
@@ -784,9 +780,19 @@
     }
 
     /**
-     * Holds information about the way volume is handled for this session.
+     * Holds information about the current playback and how audio is handled for
+     * this session.
      */
-    public static final class VolumeInfo {
+    public static final class PlaybackInfo {
+        /**
+         * The session uses remote playback.
+         */
+        public static final int PLAYBACK_TYPE_REMOTE = 2;
+        /**
+         * The session uses local playback.
+         */
+        public static final int PLAYBACK_TYPE_LOCAL = 1;
+
         private final int mVolumeType;
         private final int mVolumeControl;
         private final int mMaxVolume;
@@ -796,7 +802,7 @@
         /**
          * @hide
          */
-        public VolumeInfo(int type, AudioAttributes attrs, int control, int max, int current) {
+        public PlaybackInfo(int type, AudioAttributes attrs, int control, int max, int current) {
             mVolumeType = type;
             mAudioAttrs = attrs;
             mVolumeControl = control;
@@ -805,22 +811,22 @@
         }
 
         /**
-         * Get the type of volume handling, either local or remote. One of:
+         * Get the type of playback which affects volume handling. One of:
          * <ul>
-         * <li>{@link MediaSession#PLAYBACK_TYPE_LOCAL}</li>
-         * <li>{@link MediaSession#PLAYBACK_TYPE_REMOTE}</li>
+         * <li>{@link #PLAYBACK_TYPE_LOCAL}</li>
+         * <li>{@link #PLAYBACK_TYPE_REMOTE}</li>
          * </ul>
          *
-         * @return The type of volume handling this session is using.
+         * @return The type of playback this session is using.
          */
-        public int getVolumeType() {
+        public int getPlaybackType() {
             return mVolumeType;
         }
 
         /**
          * Get the audio attributes for this session. The attributes will affect
          * volume handling for the session. When the volume type is
-         * {@link MediaSession#PLAYBACK_TYPE_REMOTE} these may be ignored by the
+         * {@link PlaybackInfo#PLAYBACK_TYPE_REMOTE} these may be ignored by the
          * remote volume handler.
          *
          * @return The attributes for this session.
@@ -904,7 +910,7 @@
 
         @Override
         public void onQueueChanged(ParceledListSlice parceledQueue) {
-            List<MediaSession.Track> queue = parceledQueue.getList();
+            List<MediaSession.QueueItem> queue = parceledQueue.getList();
             MediaController controller = mController.get();
             if (controller != null) {
                 controller.postMessage(MSG_UPDATE_QUEUE, queue, null);
@@ -931,7 +937,7 @@
         public void onVolumeInfoChanged(ParcelableVolumeInfo pvi) {
             MediaController controller = mController.get();
             if (controller != null) {
-                VolumeInfo info = new VolumeInfo(pvi.volumeType, pvi.audioAttrs, pvi.controlType,
+                PlaybackInfo info = new PlaybackInfo(pvi.volumeType, pvi.audioAttrs, pvi.controlType,
                         pvi.maxVolume, pvi.currentVolume);
                 controller.postMessage(MSG_UPDATE_VOLUME, info, null);
             }
@@ -960,7 +966,7 @@
                     mCallback.onMetadataChanged((MediaMetadata) msg.obj);
                     break;
                 case MSG_UPDATE_QUEUE:
-                    mCallback.onQueueChanged((List<MediaSession.Track>) msg.obj);
+                    mCallback.onQueueChanged((List<MediaSession.QueueItem>) msg.obj);
                     break;
                 case MSG_UPDATE_QUEUE_TITLE:
                     mCallback.onQueueTitleChanged((CharSequence) msg.obj);
@@ -969,7 +975,7 @@
                     mCallback.onExtrasChanged((Bundle) msg.obj);
                     break;
                 case MSG_UPDATE_VOLUME:
-                    mCallback.onVolumeInfoChanged((VolumeInfo) msg.obj);
+                    mCallback.onAudioInfoChanged((PlaybackInfo) msg.obj);
                     break;
                 case MSG_DESTROYED:
                     mCallback.onSessionDestroyed();
diff --git a/media/java/android/media/session/MediaSession.aidl b/media/java/android/media/session/MediaSession.aidl
index 0ad58c4..f657cef 100644
--- a/media/java/android/media/session/MediaSession.aidl
+++ b/media/java/android/media/session/MediaSession.aidl
@@ -16,4 +16,4 @@
 package android.media.session;
 
 parcelable MediaSession.Token;
-parcelable MediaSession.Track;
\ No newline at end of file
+parcelable MediaSession.QueueItem;
\ No newline at end of file
diff --git a/media/java/android/media/session/MediaSession.java b/media/java/android/media/session/MediaSession.java
index cf73c2a..2c38697 100644
--- a/media/java/android/media/session/MediaSession.java
+++ b/media/java/android/media/session/MediaSession.java
@@ -25,10 +25,10 @@
 import android.content.Intent;
 import android.content.pm.ParceledListSlice;
 import android.media.AudioAttributes;
+import android.media.MediaDescription;
 import android.media.MediaMetadata;
 import android.media.Rating;
 import android.media.VolumeProvider;
-import android.media.routing.MediaRouter;
 import android.net.Uri;
 import android.os.Bundle;
 import android.os.Handler;
@@ -39,6 +39,7 @@
 import android.os.RemoteException;
 import android.os.ResultReceiver;
 import android.os.UserHandle;
+import android.service.media.MediaBrowserService;
 import android.text.TextUtils;
 import android.util.Log;
 import android.view.KeyEvent;
@@ -102,16 +103,6 @@
             FLAG_EXCLUSIVE_GLOBAL_PRIORITY })
     public @interface SessionFlags { }
 
-    /**
-     * The session uses local playback.
-     */
-    public static final int PLAYBACK_TYPE_LOCAL = 1;
-
-    /**
-     * The session uses remote playback.
-     */
-    public static final int PLAYBACK_TYPE_REMOTE = 2;
-
     private final Object mLock = new Object();
 
     private final MediaSession.Token mSessionToken;
@@ -191,18 +182,23 @@
      * @param handler The handler that events should be posted on.
      */
     public void setCallback(@Nullable Callback callback, @Nullable Handler handler) {
-        if (callback == null) {
-            mCallback = null;
-            return;
-        }
         synchronized (mLock) {
-            if (mCallback != null && mCallback.mCallback == callback) {
-                Log.w(TAG, "Tried to set same callback, ignoring");
+            if (callback == null) {
+                if (mCallback != null) {
+                    mCallback.mCallback.mSession = null;
+                }
+                mCallback = null;
                 return;
             }
+            if (mCallback != null) {
+                // We're updating the callback, clear the session from the old
+                // one.
+                mCallback.mCallback.mSession = null;
+            }
             if (handler == null) {
                 handler = new Handler();
             }
+            callback.mSession = this;
             CallbackMessageHandler msgHandler = new CallbackMessageHandler(handler.getLooper(),
                     callback);
             mCallback = msgHandler;
@@ -216,7 +212,7 @@
      *
      * @param pi The intent to launch to show UI for this Session.
      */
-    public void setLaunchActivity(@Nullable PendingIntent pi) {
+    public void setSessionActivity(@Nullable PendingIntent pi) {
         try {
             mBinder.setLaunchPendingIntent(pi);
         } catch (RemoteException e) {
@@ -225,23 +221,6 @@
     }
 
     /**
-     * Associates a {@link MediaRouter} with this session to control the destination
-     * of media content.
-     * <p>
-     * A media router may only be associated with at most one session at a time.
-     * </p>
-     *
-     * @param router The media router, or null to remove the current association.
-     */
-    public void setMediaRouter(@Nullable MediaRouter router) {
-        try {
-            mBinder.setMediaRouter(router != null ? router.getBinder() : null);
-        } catch (RemoteException e) {
-            Log.wtf(TAG, "Failure in setMediaButtonReceiver.", e);
-        }
-    }
-
-    /**
      * Set a pending intent for your media button receiver to allow restarting
      * playback after the session has been stopped. If your app is started in
      * this way an {@link Intent#ACTION_MEDIA_BUTTON} intent will be sent via
@@ -318,6 +297,7 @@
         try {
             mBinder.setPlaybackToRemote(volumeProvider.getVolumeControl(),
                     volumeProvider.getMaxVolume());
+            mBinder.setCurrentVolume(volumeProvider.getCurrentVolume());
         } catch (RemoteException e) {
             Log.wtf(TAG, "Failure in setPlaybackToRemote.", e);
         }
@@ -435,18 +415,19 @@
     }
 
     /**
-     * Update the list of tracks in the play queue. It is an ordered list and should contain the
-     * current track, and previous or upcoming tracks if they exist.
-     * Specify null if there is no current play queue.
+     * Update the list of items in the play queue. It is an ordered list and
+     * should contain the current item, and previous or upcoming items if they
+     * exist. Specify null if there is no current play queue.
      * <p>
-     * The queue should be of reasonable size. If the play queue is unbounded within your
-     * app, it is better to send a reasonable amount in a sliding window instead.
+     * The queue should be of reasonable size. If the play queue is unbounded
+     * within your app, it is better to send a reasonable amount in a sliding
+     * window instead.
      *
-     * @param queue A list of tracks in the play queue.
+     * @param queue A list of items in the play queue.
      */
-    public void setQueue(@Nullable List<Track> queue) {
+    public void setQueue(@Nullable List<QueueItem> queue) {
         try {
-            mBinder.setQueue(new ParceledListSlice<Track>(queue));
+            mBinder.setQueue(new ParceledListSlice<QueueItem>(queue));
         } catch (RemoteException e) {
             Log.wtf("Dead object in setQueue.", e);
         }
@@ -494,7 +475,7 @@
             return;
         }
         try {
-            mBinder.setCurrentVolume(provider.onGetCurrentVolume());
+            mBinder.setCurrentVolume(provider.getCurrentVolume());
         } catch (RemoteException e) {
             Log.e(TAG, "Error in notifyVolumeChanged", e);
         }
@@ -504,16 +485,16 @@
         postToCallback(CallbackMessageHandler.MSG_PLAY);
     }
 
-    private void dispatchPlayUri(Uri uri, Bundle extras) {
-        postToCallback(CallbackMessageHandler.MSG_PLAY_URI, uri, extras);
+    private void dispatchPlayFromMediaId(String mediaId, Bundle extras) {
+        postToCallback(CallbackMessageHandler.MSG_PLAY_MEDIA_ID, mediaId, extras);
     }
 
     private void dispatchPlayFromSearch(String query, Bundle extras) {
         postToCallback(CallbackMessageHandler.MSG_PLAY_SEARCH, query, extras);
     }
 
-    private void dispatchSkipToTrack(long id) {
-        postToCallback(CallbackMessageHandler.MSG_SKIP_TO_TRACK, id);
+    private void dispatchSkipToItem(long id) {
+        postToCallback(CallbackMessageHandler.MSG_SKIP_TO_ITEM, id);
     }
 
     private void dispatchPause() {
@@ -699,6 +680,7 @@
          *
          * @param mediaButtonIntent an intent containing the KeyEvent as an
          *            extra
+         * @return True if the event was handled, false otherwise.
          */
         public boolean onMediaButtonEvent(@NonNull Intent mediaButtonIntent) {
             if (mSession != null
@@ -711,36 +693,43 @@
                         case KeyEvent.KEYCODE_MEDIA_PLAY:
                             if ((validActions & PlaybackState.ACTION_PLAY) != 0) {
                                 onPlay();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_PAUSE:
                             if ((validActions & PlaybackState.ACTION_PAUSE) != 0) {
                                 onPause();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_NEXT:
                             if ((validActions & PlaybackState.ACTION_SKIP_TO_NEXT) != 0) {
                                 onSkipToNext();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_PREVIOUS:
                             if ((validActions & PlaybackState.ACTION_SKIP_TO_PREVIOUS) != 0) {
                                 onSkipToPrevious();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_STOP:
                             if ((validActions & PlaybackState.ACTION_STOP) != 0) {
                                 onStop();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_FAST_FORWARD:
                             if ((validActions & PlaybackState.ACTION_FAST_FORWARD) != 0) {
                                 onFastForward();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_REWIND:
                             if ((validActions & PlaybackState.ACTION_REWIND) != 0) {
                                 onRewind();
+                                return true;
                             }
                             break;
                         case KeyEvent.KEYCODE_MEDIA_PLAY_PAUSE:
@@ -753,8 +742,10 @@
                                     | PlaybackState.ACTION_PAUSE)) != 0;
                             if (isPlaying && canPause) {
                                 onPause();
+                                return true;
                             } else if (!isPlaying && canPlay) {
                                 onPlay();
+                                return true;
                             }
                             break;
                     }
@@ -770,21 +761,26 @@
         }
 
         /**
-         * Override to handle requests to play a specific {@link Uri}.
+         * Override to handle requests to play a specific mediaId that was
+         * provided by your app's {@link MediaBrowserService}.
          */
-        public void onPlayUri(Uri uri, Bundle extras) {
+        public void onPlayFromMediaId(String mediaId, Bundle extras) {
         }
 
         /**
-         * Override to handle requests to begin playback from a search query.
+         * Override to handle requests to begin playback from a search query. An
+         * empty query indicates that the app may play any music. The
+         * implementation should attempt to make a smart choice about what to
+         * play.
          */
         public void onPlayFromSearch(String query, Bundle extras) {
         }
 
         /**
-         * Override to handle requests to play a track with a given id from the play queue.
+         * Override to handle requests to play an item with a given id from the
+         * play queue.
          */
-        public void onSkipToTrack(long id) {
+        public void onSkipToQueueItem(long id) {
         }
 
         /**
@@ -849,10 +845,6 @@
          */
         public void onCustomAction(@NonNull String action, @Nullable Bundle extras) {
         }
-
-        private void setSession(MediaSession session) {
-            mSession = session;
-        }
     }
 
     /**
@@ -897,10 +889,10 @@
         }
 
         @Override
-        public void onPlayUri(Uri uri, Bundle extras) {
+        public void onPlayFromMediaId(String mediaId, Bundle extras) {
             MediaSession session = mMediaSession.get();
             if (session != null) {
-                session.dispatchPlayUri(uri, extras);
+                session.dispatchPlayFromMediaId(mediaId, extras);
             }
         }
 
@@ -916,7 +908,7 @@
         public void onSkipToTrack(long id) {
             MediaSession session = mMediaSession.get();
             if (session != null) {
-                session.dispatchSkipToTrack(id);
+                session.dispatchSkipToItem(id);
             }
         }
 
@@ -1015,124 +1007,59 @@
     }
 
     /**
-     * A single track that is part of the play queue. It contains information necessary to display
-     * a single track in the queue.
+     * A single item that is part of the play queue. It contains a description
+     * of the item and its id in the queue.
      */
-    public static final class Track implements Parcelable {
+    public static final class QueueItem implements Parcelable {
         /**
-         * This id is reserved. No tracks can be explicitly asigned this id.
+         * This id is reserved. No items can be explicitly asigned this id.
          */
         public static final int UNKNOWN_ID = -1;
 
-        private final MediaMetadata mMetadata;
+        private final MediaDescription mDescription;
         private final long mId;
-        private final Uri mUri;
-        private final Bundle mExtras;
 
         /**
-         * Create a new {@link MediaSession.Track}.
+         * Create a new {@link MediaSession.QueueItem}.
          *
-         * @param metadata The metadata for this track.
-         * @param id An identifier for this track. It must be unique within the play queue.
-         * @param uri The uri for this track.
-         * @param extras A bundle of extras that can be used to add extra information about the
-         *               track.
+         * @param description The {@link MediaDescription} for this item.
+         * @param id An identifier for this item. It must be unique within the
+         *            play queue and cannot be {@link #UNKNOWN_ID}.
          */
-        private Track(MediaMetadata metadata, long id, Uri uri, Bundle extras) {
-            mMetadata = metadata;
+        public QueueItem(MediaDescription description, long id) {
+            if (description == null) {
+                throw new IllegalArgumentException("Description cannot be null.");
+            }
+            if (id == UNKNOWN_ID) {
+                throw new IllegalArgumentException("Id cannot be QueueItem.UNKNOWN_ID");
+            }
+            mDescription = description;
             mId = id;
-            mUri = uri;
-            mExtras = extras;
         }
 
-        private Track(Parcel in) {
-            mMetadata = MediaMetadata.CREATOR.createFromParcel(in);
+        private QueueItem(Parcel in) {
+            mDescription = MediaDescription.CREATOR.createFromParcel(in);
             mId = in.readLong();
-            mUri = Uri.CREATOR.createFromParcel(in);
-            mExtras = in.readBundle();
         }
 
         /**
-         * Get the metadata for this track.
+         * Get the description for this item.
          */
-        public MediaMetadata getMetadata() {
-            return mMetadata;
+        public MediaDescription getDescription() {
+            return mDescription;
         }
 
         /**
-         * Get the id for this track.
+         * Get the queue id for this item.
          */
-        public long getId() {
+        public long getQueueId() {
             return mId;
         }
 
-        /**
-         * Get the Uri for this track.
-         */
-        public Uri getUri() {
-            return mUri;
-        }
-
-        /**
-         * Get the extras for this track.
-         */
-        public Bundle getExtras() {
-            return mExtras;
-        }
-
-        /**
-         * Builder for {@link MediaSession.Track} objects.
-         */
-        public static final class Builder {
-            private final MediaMetadata mMetadata;
-            private final long mId;
-            private final Uri mUri;
-
-            private Bundle mExtras;
-
-            /**
-             * Create a builder with the metadata, id, and uri already set.
-             */
-            public Builder(MediaMetadata metadata, long id, Uri uri) {
-                if (metadata == null) {
-                    throw new IllegalArgumentException(
-                            "You must specify a non-null MediaMetadata to build a Track.");
-                }
-                if (uri == null) {
-                    throw new IllegalArgumentException(
-                            "You must specify a non-null Uri to build a Track.");
-                }
-                if (id == UNKNOWN_ID) {
-                    throw new IllegalArgumentException(
-                            "You must specify an id other than UNKNOWN_ID to build a Track.");
-                }
-                mMetadata = metadata;
-                mId = id;
-                mUri = uri;
-            }
-
-            /**
-             * Set optional extras for the track.
-             */
-            public MediaSession.Track.Builder setExtras(Bundle extras) {
-                mExtras = extras;
-                return this;
-            }
-
-            /**
-             * Create the {@link Track}.
-             */
-            public MediaSession.Track build() {
-                return new MediaSession.Track(mMetadata, mId, mUri, mExtras);
-            }
-        }
-
         @Override
         public void writeToParcel(Parcel dest, int flags) {
-            mMetadata.writeToParcel(dest, flags);
+            mDescription.writeToParcel(dest, flags);
             dest.writeLong(mId);
-            mUri.writeToParcel(dest, flags);
-            dest.writeBundle(mExtras);
         }
 
         @Override
@@ -1140,28 +1067,24 @@
             return 0;
         }
 
-        public static final Creator<MediaSession.Track> CREATOR
-                = new Creator<MediaSession.Track>() {
+        public static final Creator<MediaSession.QueueItem> CREATOR = new Creator<MediaSession.QueueItem>() {
 
             @Override
-            public MediaSession.Track createFromParcel(Parcel p) {
-                return new MediaSession.Track(p);
+            public MediaSession.QueueItem createFromParcel(Parcel p) {
+                return new MediaSession.QueueItem(p);
             }
 
             @Override
-            public MediaSession.Track[] newArray(int size) {
-                return new MediaSession.Track[size];
+            public MediaSession.QueueItem[] newArray(int size) {
+                return new MediaSession.QueueItem[size];
             }
         };
 
         @Override
         public String toString() {
-            return "MediaSession.Track {" +
-                    "Metadata=" + mMetadata +
-                    ", Id=" + mId +
-                    ", Uri=" + mUri +
-                    ", Extras=" + mExtras +
-                    " }";
+            return "MediaSession.QueueItem {" +
+                    "Description=" + mDescription +
+                    ", Id=" + mId + " }";
         }
     }
 
@@ -1180,9 +1103,9 @@
     private class CallbackMessageHandler extends Handler {
 
         private static final int MSG_PLAY = 1;
-        private static final int MSG_PLAY_URI = 2;
+        private static final int MSG_PLAY_MEDIA_ID = 2;
         private static final int MSG_PLAY_SEARCH = 3;
-        private static final int MSG_SKIP_TO_TRACK = 4;
+        private static final int MSG_SKIP_TO_ITEM = 4;
         private static final int MSG_PAUSE = 5;
         private static final int MSG_STOP = 6;
         private static final int MSG_NEXT = 7;
@@ -1226,14 +1149,14 @@
                 case MSG_PLAY:
                     mCallback.onPlay();
                     break;
-                case MSG_PLAY_URI:
-                    mCallback.onPlayUri((Uri) msg.obj, msg.getData());
+                case MSG_PLAY_MEDIA_ID:
+                    mCallback.onPlayFromMediaId((String) msg.obj, msg.getData());
                     break;
                 case MSG_PLAY_SEARCH:
                     mCallback.onPlayFromSearch((String) msg.obj, msg.getData());
                     break;
-                case MSG_SKIP_TO_TRACK:
-                    mCallback.onSkipToTrack((Long) msg.obj);
+                case MSG_SKIP_TO_ITEM:
+                    mCallback.onSkipToQueueItem((Long) msg.obj);
                 case MSG_PAUSE:
                     mCallback.onPause();
                     break;
diff --git a/media/java/android/media/session/MediaSessionLegacyHelper.java b/media/java/android/media/session/MediaSessionLegacyHelper.java
index aa196a9..06e40c5 100644
--- a/media/java/android/media/session/MediaSessionLegacyHelper.java
+++ b/media/java/android/media/session/MediaSessionLegacyHelper.java
@@ -467,10 +467,7 @@
                 mSessions.remove(mPi);
             } else if (mCb == null) {
                 mCb = new SessionCallback();
-                Handler handler = null;
-                if (Looper.myLooper() == null) {
-                    handler = new Handler(Looper.getMainLooper());
-                }
+                Handler handler = new Handler(Looper.getMainLooper());
                 mSession.setCallback(mCb, handler);
             }
         }
diff --git a/media/java/android/media/session/MediaSessionManager.java b/media/java/android/media/session/MediaSessionManager.java
index c2fb5a3..185c6d8 100644
--- a/media/java/android/media/session/MediaSessionManager.java
+++ b/media/java/android/media/session/MediaSessionManager.java
@@ -30,6 +30,7 @@
 import android.os.UserHandle;
 import android.service.notification.NotificationListenerService;
 import android.text.TextUtils;
+import android.util.ArrayMap;
 import android.util.Log;
 import android.view.KeyEvent;
 
@@ -50,6 +51,9 @@
 public final class MediaSessionManager {
     private static final String TAG = "SessionManager";
 
+    private final ArrayMap<OnActiveSessionsChangedListener, SessionsChangedWrapper> mListeners
+            = new ArrayMap<OnActiveSessionsChangedListener, SessionsChangedWrapper>();
+    private final Object mLock = new Object();
     private final ISessionManager mService;
 
     private Context mContext;
@@ -141,10 +145,32 @@
      * @param notificationListener The enabled notification listener component.
      *            May be null.
      */
-    public void addActiveSessionsListener(@NonNull SessionListener sessionListener,
+    public void addOnActiveSessionsChangedListener(
+            @NonNull OnActiveSessionsChangedListener sessionListener,
             @Nullable ComponentName notificationListener) {
-        addActiveSessionsListener(sessionListener, notificationListener, UserHandle.myUserId(),
-                null);
+        addOnActiveSessionsChangedListener(sessionListener, notificationListener, null);
+    }
+
+    /**
+     * Add a listener to be notified when the list of active sessions
+     * changes.This requires the
+     * android.Manifest.permission.MEDIA_CONTENT_CONTROL permission be held by
+     * the calling app. You may also retrieve this list if your app is an
+     * enabled notification listener using the
+     * {@link NotificationListenerService} APIs, in which case you must pass the
+     * {@link ComponentName} of your enabled listener. Updates will be posted to
+     * the handler specified or to the caller's thread if the handler is null.
+     *
+     * @param sessionListener The listener to add.
+     * @param notificationListener The enabled notification listener component.
+     *            May be null.
+     * @param handler The handler to post events to.
+     */
+    public void addOnActiveSessionsChangedListener(
+            @NonNull OnActiveSessionsChangedListener sessionListener,
+            @Nullable ComponentName notificationListener, @Nullable Handler handler) {
+        addOnActiveSessionsChangedListener(sessionListener, notificationListener,
+                UserHandle.myUserId(), handler);
     }
 
     /**
@@ -163,7 +189,8 @@
      * @param handler The handler to post updates on.
      * @hide
      */
-    public void addActiveSessionsListener(@NonNull SessionListener sessionListener,
+    public void addOnActiveSessionsChangedListener(
+            @NonNull OnActiveSessionsChangedListener sessionListener,
             @Nullable ComponentName notificationListener, int userId, @Nullable Handler handler) {
         if (sessionListener == null) {
             throw new IllegalArgumentException("listener may not be null");
@@ -171,11 +198,18 @@
         if (handler == null) {
             handler = new Handler();
         }
-        sessionListener.setHandler(handler);
-        try {
-            mService.addSessionsListener(sessionListener.mStub, notificationListener, userId);
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error in addActiveSessionsListener.", e);
+        synchronized (mLock) {
+            if (mListeners.get(sessionListener) != null) {
+                Log.w(TAG, "Attempted to add session listener twice, ignoring.");
+                return;
+            }
+            SessionsChangedWrapper wrapper = new SessionsChangedWrapper(sessionListener, handler);
+            try {
+                mService.addSessionsListener(wrapper.mStub, notificationListener, userId);
+                mListeners.put(sessionListener, wrapper);
+            } catch (RemoteException e) {
+                Log.e(TAG, "Error in addOnActiveSessionsChangedListener.", e);
+            }
         }
     }
 
@@ -184,14 +218,20 @@
      *
      * @param listener The listener to remove.
      */
-    public void removeActiveSessionsListener(@NonNull SessionListener listener) {
+    public void removeOnActiveSessionsChangedListener(
+            @NonNull OnActiveSessionsChangedListener listener) {
         if (listener == null) {
             throw new IllegalArgumentException("listener may not be null");
         }
-        try {
-            mService.removeSessionsListener(listener.mStub);
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error in removeActiveSessionsListener.", e);
+        synchronized (mLock) {
+            SessionsChangedWrapper wrapper = mListeners.remove(listener);
+            if (wrapper != null) {
+                try {
+                    mService.removeSessionsListener(wrapper.mStub);
+                } catch (RemoteException e) {
+                    Log.e(TAG, "Error in removeOnActiveSessionsChangedListener.", e);
+                }
+            }
         }
     }
 
@@ -257,28 +297,18 @@
 
     /**
      * Listens for changes to the list of active sessions. This can be added
-     * using {@link #addActiveSessionsListener}.
+     * using {@link #addOnActiveSessionsChangedListener}.
      */
-    public static abstract class SessionListener {
-        private final Context mContext;
-        private Handler mHandler;
+    public interface OnActiveSessionsChangedListener {
+        public void onActiveSessionsChanged(@Nullable List<MediaController> controllers);
+    }
 
-        public SessionListener(Context context) {
-            mContext = context;
-        }
-        /**
-         * Called when the list of active sessions has changed. This can be due
-         * to a session being added or removed or the order of sessions
-         * changing. The controllers will be provided in priority order with the
-         * most important controller at index 0.
-         *
-         * @param controllers The updated list of controllers for the user that
-         *            changed.
-         */
-        public abstract void onActiveSessionsChanged(
-                @Nullable List<MediaController> controllers);
+    private final class SessionsChangedWrapper {
+        private final OnActiveSessionsChangedListener mListener;
+        private final Handler mHandler;
 
-        private final void setHandler(Handler handler) {
+        public SessionsChangedWrapper(OnActiveSessionsChangedListener listener, Handler handler) {
+            mListener = listener;
             mHandler = handler;
         }
 
@@ -295,7 +325,7 @@
                             for (int i = 0; i < size; i++) {
                                 controllers.add(new MediaController(mContext, tokens.get(i)));
                             }
-                            SessionListener.this.onActiveSessionsChanged(controllers);
+                            mListener.onActiveSessionsChanged(controllers);
                         }
                     });
                 }
diff --git a/media/java/android/media/session/ParcelableVolumeInfo.java b/media/java/android/media/session/ParcelableVolumeInfo.java
index e71b539..f59c975 100644
--- a/media/java/android/media/session/ParcelableVolumeInfo.java
+++ b/media/java/android/media/session/ParcelableVolumeInfo.java
@@ -21,7 +21,7 @@
 
 /**
  * Convenience class for passing information about the audio configuration of a
- * session. The public implementation is {@link MediaController.VolumeInfo}.
+ * session. The public implementation is {@link MediaController.PlaybackInfo}.
  *
  * @hide
  */
diff --git a/media/java/android/media/session/PlaybackState.java b/media/java/android/media/session/PlaybackState.java
index 2ad8eae..267d1ff 100644
--- a/media/java/android/media/session/PlaybackState.java
+++ b/media/java/android/media/session/PlaybackState.java
@@ -36,95 +36,95 @@
     private static final String TAG = "PlaybackState";
 
     /**
-     * Indicates this performer supports the stop command.
+     * Indicates this session supports the stop command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_STOP = 1 << 0;
 
     /**
-     * Indicates this performer supports the pause command.
+     * Indicates this session supports the pause command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_PAUSE = 1 << 1;
 
     /**
-     * Indicates this performer supports the play command.
+     * Indicates this session supports the play command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_PLAY = 1 << 2;
 
     /**
-     * Indicates this performer supports the rewind command.
+     * Indicates this session supports the rewind command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_REWIND = 1 << 3;
 
     /**
-     * Indicates this performer supports the previous command.
+     * Indicates this session supports the previous command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_SKIP_TO_PREVIOUS = 1 << 4;
 
     /**
-     * Indicates this performer supports the next command.
+     * Indicates this session supports the next command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_SKIP_TO_NEXT = 1 << 5;
 
     /**
-     * Indicates this performer supports the fast forward command.
+     * Indicates this session supports the fast forward command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_FAST_FORWARD = 1 << 6;
 
     /**
-     * Indicates this performer supports the set rating command.
+     * Indicates this session supports the set rating command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_SET_RATING = 1 << 7;
 
     /**
-     * Indicates this performer supports the seek to command.
+     * Indicates this session supports the seek to command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_SEEK_TO = 1 << 8;
 
     /**
-     * Indicates this performer supports the play/pause toggle command.
+     * Indicates this session supports the play/pause toggle command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_PLAY_PAUSE = 1 << 9;
 
     /**
-     * Indicates this performer supports the play from uri command.
+     * Indicates this session supports the play from media id command.
      *
      * @see Builder#setActions(long)
      */
-    public static final long ACTION_PLAY_URI = 1 << 10;
+    public static final long ACTION_PLAY_FROM_MEDIA_ID = 1 << 10;
 
     /**
-     * Indicates this performer supports the play from search command.
+     * Indicates this session supports the play from search command.
      *
      * @see Builder#setActions(long)
      */
     public static final long ACTION_PLAY_FROM_SEARCH = 1 << 11;
 
     /**
-     * Indicates this performer supports the skip to track command.
+     * Indicates this session supports the skip to queue item command.
      *
      * @see Builder#setActions(long)
      */
-    public static final long ACTION_SKIP_TO_TRACK = 1 << 12;
+    public static final long ACTION_SKIP_TO_QUEUE_ITEM = 1 << 12;
 
     /**
      * This is the default playback state and indicates that no media has been
@@ -211,32 +211,40 @@
     public final static int STATE_SKIPPING_TO_NEXT = 10;
 
     /**
+     * State indicating the player is currently skipping to a specific item in
+     * the queue.
+     *
+     * @see Builder#setState
+     */
+    public final static int STATE_SKIPPING_TO_QUEUE_ITEM = 11;
+
+    /**
      * Use this value for the position to indicate the position is not known.
      */
     public final static long PLAYBACK_POSITION_UNKNOWN = -1;
 
     private final int mState;
     private final long mPosition;
-    private final long mBufferPosition;
+    private final long mBufferedPosition;
     private final float mSpeed;
     private final long mActions;
     private List<PlaybackState.CustomAction> mCustomActions;
     private final CharSequence mErrorMessage;
     private final long mUpdateTime;
-    private final long mActiveTrackId;
+    private final long mActiveItemId;
 
     private PlaybackState(int state, long position, long updateTime, float speed,
-            long bufferPosition, long transportControls,
-            List<PlaybackState.CustomAction> customActions, long activeTrackId,
+            long bufferedPosition, long transportControls,
+            List<PlaybackState.CustomAction> customActions, long activeItemId,
             CharSequence error) {
         mState = state;
         mPosition = position;
         mSpeed = speed;
         mUpdateTime = updateTime;
-        mBufferPosition = bufferPosition;
+        mBufferedPosition = bufferedPosition;
         mActions = transportControls;
         mCustomActions = new ArrayList<>(customActions);
-        mActiveTrackId = activeTrackId;
+        mActiveItemId = activeItemId;
         mErrorMessage = error;
     }
 
@@ -245,10 +253,10 @@
         mPosition = in.readLong();
         mSpeed = in.readFloat();
         mUpdateTime = in.readLong();
-        mBufferPosition = in.readLong();
+        mBufferedPosition = in.readLong();
         mActions = in.readLong();
         mCustomActions = in.createTypedArrayList(CustomAction.CREATOR);
-        mActiveTrackId = in.readLong();
+        mActiveItemId = in.readLong();
         mErrorMessage = in.readCharSequence();
 
     }
@@ -258,12 +266,12 @@
         StringBuilder bob = new StringBuilder("PlaybackState {");
         bob.append("state=").append(mState);
         bob.append(", position=").append(mPosition);
-        bob.append(", buffered position=").append(mBufferPosition);
+        bob.append(", buffered position=").append(mBufferedPosition);
         bob.append(", speed=").append(mSpeed);
         bob.append(", updated=").append(mUpdateTime);
         bob.append(", actions=").append(mActions);
         bob.append(", custom actions=").append(mCustomActions);
-        bob.append(", active track id=").append(mActiveTrackId);
+        bob.append(", active item id=").append(mActiveItemId);
         bob.append(", error=").append(mErrorMessage);
         bob.append("}");
         return bob.toString();
@@ -280,10 +288,10 @@
         dest.writeLong(mPosition);
         dest.writeFloat(mSpeed);
         dest.writeLong(mUpdateTime);
-        dest.writeLong(mBufferPosition);
+        dest.writeLong(mBufferedPosition);
         dest.writeLong(mActions);
         dest.writeTypedList(mCustomActions);
-        dest.writeLong(mActiveTrackId);
+        dest.writeLong(mActiveItemId);
         dest.writeCharSequence(mErrorMessage);
     }
 
@@ -310,12 +318,12 @@
     }
 
     /**
-     * Get the current buffer position in ms. This is the farthest playback
+     * Get the current buffered position in ms. This is the farthest playback
      * point that can be reached from the current position using only buffered
      * content.
      */
-    public long getBufferPosition() {
-        return mBufferPosition;
+    public long getBufferedPosition() {
+        return mBufferedPosition;
     }
 
     /**
@@ -374,6 +382,18 @@
     }
 
     /**
+     * Get the id of the currently active item in the queue. If there is no
+     * queue or a queue is not supported by the session this will be
+     * {@link MediaSession.QueueItem#UNKNOWN_ID}.
+     *
+     * @return The id of the currently active item in the queue or
+     *         {@link MediaSession.QueueItem#UNKNOWN_ID}.
+     */
+    public long getActiveQueueItemId() {
+        return mActiveItemId;
+    }
+
+    /**
      * Get the {@link PlaybackState} state for the given
      * {@link RemoteControlClient} state.
      *
@@ -711,12 +731,12 @@
 
         private int mState;
         private long mPosition;
-        private long mBufferPosition;
+        private long mBufferedPosition;
         private float mSpeed;
         private long mActions;
         private CharSequence mErrorMessage;
         private long mUpdateTime;
-        private long mActiveTrackId = MediaSession.Track.UNKNOWN_ID;
+        private long mActiveItemId = MediaSession.QueueItem.UNKNOWN_ID;
 
         /**
          * Creates an initially empty state builder.
@@ -736,7 +756,7 @@
             }
             mState = from.mState;
             mPosition = from.mPosition;
-            mBufferPosition = from.mBufferPosition;
+            mBufferedPosition = from.mBufferedPosition;
             mSpeed = from.mSpeed;
             mActions = from.mActions;
             if (from.mCustomActions != null) {
@@ -744,14 +764,14 @@
             }
             mErrorMessage = from.mErrorMessage;
             mUpdateTime = from.mUpdateTime;
-            mActiveTrackId = from.mActiveTrackId;
+            mActiveItemId = from.mActiveItemId;
         }
 
         /**
          * Set the current state of playback.
          * <p>
          * The position must be in ms and indicates the current playback
-         * position within the track. If the position is unknown use
+         * position within the item. If the position is unknown use
          * {@link #PLAYBACK_POSITION_UNKNOWN}. When not using an unknown
          * position the time at which the position was updated must be provided.
          * It is okay to use {@link SystemClock#elapsedRealtime()} if the
@@ -773,7 +793,7 @@
          * </ul>
          *
          * @param state The current state of playback.
-         * @param position The position in the current track in ms.
+         * @param position The position in the current item in ms.
          * @param playbackSpeed The current speed of playback as a multiple of
          *            normal playback.
          * @param updateTime The time in the {@link SystemClock#elapsedRealtime}
@@ -792,7 +812,7 @@
          * Set the current state of playback.
          * <p>
          * The position must be in ms and indicates the current playback
-         * position within the track. If the position is unknown use
+         * position within the item. If the position is unknown use
          * {@link #PLAYBACK_POSITION_UNKNOWN}. The update time will be set to
          * the current {@link SystemClock#elapsedRealtime()}.
          * <p>
@@ -812,7 +832,7 @@
          * </ul>
          *
          * @param state The current state of playback.
-         * @param position The position in the current track in ms.
+         * @param position The position in the current item in ms.
          * @param playbackSpeed The current speed of playback as a multiple of
          *            normal playback.
          * @return this
@@ -889,27 +909,28 @@
         }
 
         /**
-         * Set the current buffer position in ms. This is the farthest playback
-         * point that can be reached from the current position using only
-         * buffered content.
+         * Set the current buffered position in ms. This is the farthest
+         * playback point that can be reached from the current position using
+         * only buffered content.
          *
-         * @param bufferPosition The position in ms that playback is buffered to.
+         * @param bufferedPosition The position in ms that playback is buffered
+         *            to.
          * @return this
          */
-        public Builder setBufferPosition(long bufferPosition) {
-            mBufferPosition = bufferPosition;
+        public Builder setBufferedPosition(long bufferedPosition) {
+            mBufferedPosition = bufferedPosition;
             return this;
         }
 
         /**
-         * Set the active track in the play queue by specifying its id.
-         * The default value is {@link MediaSession.Track#UNKNOWN_ID}
+         * Set the active item in the play queue by specifying its id. The
+         * default value is {@link MediaSession.QueueItem#UNKNOWN_ID}
          *
-         * @param id The id of the active track.
+         * @param id The id of the active item.
          * @return this
          */
-        public Builder setActiveTrack(long id) {
-            mActiveTrackId = id;
+        public Builder setActiveQueueItemId(long id) {
+            mActiveItemId = id;
             return this;
         }
 
@@ -931,8 +952,8 @@
          * @return A new state instance.
          */
         public PlaybackState build() {
-            return new PlaybackState(mState, mPosition, mUpdateTime, mSpeed, mBufferPosition,
-                    mActions, mCustomActions, mActiveTrackId, mErrorMessage);
+            return new PlaybackState(mState, mPosition, mUpdateTime, mSpeed, mBufferedPosition,
+                    mActions, mCustomActions, mActiveItemId, mErrorMessage);
         }
     }
 }
diff --git a/media/java/android/media/tv/ITvInputManager.aidl b/media/java/android/media/tv/ITvInputManager.aidl
index 20b8e7c..6ca794e 100644
--- a/media/java/android/media/tv/ITvInputManager.aidl
+++ b/media/java/android/media/tv/ITvInputManager.aidl
@@ -22,6 +22,7 @@
 import android.media.tv.ITvInputHardware;
 import android.media.tv.ITvInputHardwareCallback;
 import android.media.tv.ITvInputManagerCallback;
+import android.media.tv.TvContentRatingSystemInfo;
 import android.media.tv.TvInputHardwareInfo;
 import android.media.tv.TvInputInfo;
 import android.media.tv.TvStreamConfig;
@@ -38,7 +39,7 @@
     List<TvInputInfo> getTvInputList(int userId);
     TvInputInfo getTvInputInfo(in String inputId, int userId);
 
-    List<Uri> getTvContentRatingSystemXmls(int userId);
+    List<TvContentRatingSystemInfo> getTvContentRatingSystemList(int userId);
 
     void registerCallback(in ITvInputManagerCallback callback, int userId);
     void unregisterCallback(in ITvInputManagerCallback callback, int userId);
diff --git a/media/java/android/media/tv/ITvInputManagerCallback.aidl b/media/java/android/media/tv/ITvInputManagerCallback.aidl
index 50a7636..6792680 100644
--- a/media/java/android/media/tv/ITvInputManagerCallback.aidl
+++ b/media/java/android/media/tv/ITvInputManagerCallback.aidl
@@ -24,4 +24,5 @@
     void onInputStateChanged(in String inputId, int state);
     void onInputAdded(in String inputId);
     void onInputRemoved(in String inputId);
+    void onInputUpdated(in String inputId);
 }
diff --git a/media/java/android/media/tv/ITvInputSession.aidl b/media/java/android/media/tv/ITvInputSession.aidl
index 99fb911..1aad2fa 100644
--- a/media/java/android/media/tv/ITvInputSession.aidl
+++ b/media/java/android/media/tv/ITvInputSession.aidl
@@ -29,7 +29,7 @@
 oneway interface ITvInputSession {
     void release();
 
-    void setMainSession(boolean isMainSession);
+    void setMain(boolean isMain);
     void setSurface(in Surface surface);
     void dispatchSurfaceChanged(int format, int width, int height);
     // TODO: Remove this once it becomes irrelevant for applications to handle audio focus. The plan
diff --git a/media/java/android/media/tv/ITvInputSessionWrapper.java b/media/java/android/media/tv/ITvInputSessionWrapper.java
index 5022cc1..b8cdc4b 100644
--- a/media/java/android/media/tv/ITvInputSessionWrapper.java
+++ b/media/java/android/media/tv/ITvInputSessionWrapper.java
@@ -41,8 +41,10 @@
 public class ITvInputSessionWrapper extends ITvInputSession.Stub implements HandlerCaller.Callback {
     private static final String TAG = "TvInputSessionWrapper";
 
+    private static final int MESSAGE_HANDLING_DURATION_THRESHOLD_MILLIS = 50;
+
     private static final int DO_RELEASE = 1;
-    private static final int DO_SET_MAIN_SESSION = 2;
+    private static final int DO_SET_MAIN = 2;
     private static final int DO_SET_SURFACE = 3;
     private static final int DO_DISPATCH_SURFACE_CHANGED = 4;
     private static final int DO_SET_STREAM_VOLUME = 5;
@@ -77,6 +79,7 @@
             return;
         }
 
+        long startTime = System.currentTimeMillis();
         switch (msg.what) {
             case DO_RELEASE: {
                 mTvInputSessionImpl.release();
@@ -89,71 +92,76 @@
                     mChannel.dispose();
                     mChannel = null;
                 }
-                return;
+                break;
             }
-            case DO_SET_MAIN_SESSION: {
-                mTvInputSessionImpl.setMainSession((Boolean) msg.obj);
-                return;
+            case DO_SET_MAIN: {
+                mTvInputSessionImpl.setMain((Boolean) msg.obj);
+                break;
             }
             case DO_SET_SURFACE: {
                 mTvInputSessionImpl.setSurface((Surface) msg.obj);
-                return;
+                break;
             }
             case DO_DISPATCH_SURFACE_CHANGED: {
                 SomeArgs args = (SomeArgs) msg.obj;
                 mTvInputSessionImpl.dispatchSurfaceChanged(args.argi1, args.argi2, args.argi3);
                 args.recycle();
-                return;
+                break;
             }
             case DO_SET_STREAM_VOLUME: {
                 mTvInputSessionImpl.setStreamVolume((Float) msg.obj);
-                return;
+                break;
             }
             case DO_TUNE: {
                 SomeArgs args = (SomeArgs) msg.obj;
                 mTvInputSessionImpl.tune((Uri) args.arg1, (Bundle) args.arg2);
                 args.recycle();
-                return;
+                break;
             }
             case DO_SET_CAPTION_ENABLED: {
                 mTvInputSessionImpl.setCaptionEnabled((Boolean) msg.obj);
-                return;
+                break;
             }
             case DO_SELECT_TRACK: {
                 SomeArgs args = (SomeArgs) msg.obj;
                 mTvInputSessionImpl.selectTrack((Integer) args.arg1, (String) args.arg2);
                 args.recycle();
-                return;
+                break;
             }
             case DO_APP_PRIVATE_COMMAND: {
                 SomeArgs args = (SomeArgs) msg.obj;
                 mTvInputSessionImpl.appPrivateCommand((String) args.arg1, (Bundle) args.arg2);
                 args.recycle();
-                return;
+                break;
             }
             case DO_CREATE_OVERLAY_VIEW: {
                 SomeArgs args = (SomeArgs) msg.obj;
                 mTvInputSessionImpl.createOverlayView((IBinder) args.arg1, (Rect) args.arg2);
                 args.recycle();
-                return;
+                break;
             }
             case DO_RELAYOUT_OVERLAY_VIEW: {
                 mTvInputSessionImpl.relayoutOverlayView((Rect) msg.obj);
-                return;
+                break;
             }
             case DO_REMOVE_OVERLAY_VIEW: {
                 mTvInputSessionImpl.removeOverlayView(true);
-                return;
+                break;
             }
             case DO_REQUEST_UNBLOCK_CONTENT: {
                 mTvInputSessionImpl.unblockContent((String) msg.obj);
-                return;
+                break;
             }
             default: {
                 Log.w(TAG, "Unhandled message code: " + msg.what);
-                return;
+                break;
             }
         }
+        long duration = System.currentTimeMillis() - startTime;
+        if (duration > MESSAGE_HANDLING_DURATION_THRESHOLD_MILLIS) {
+            Log.w(TAG, "Handling message (" + msg.what + ") took too long time (duration="
+                    + duration + "ms)");
+        }
     }
 
     @Override
@@ -162,8 +170,8 @@
     }
 
     @Override
-    public void setMainSession(boolean isMain) {
-        mCaller.executeOrSendMessage(mCaller.obtainMessageO(DO_SET_MAIN_SESSION, isMain));
+    public void setMain(boolean isMain) {
+        mCaller.executeOrSendMessage(mCaller.obtainMessageO(DO_SET_MAIN, isMain));
     }
 
     @Override
diff --git a/media/java/android/media/tv/TvContentRating.java b/media/java/android/media/tv/TvContentRating.java
index 405ef22..b4ec2b3 100644
--- a/media/java/android/media/tv/TvContentRating.java
+++ b/media/java/android/media/tv/TvContentRating.java
@@ -17,7 +17,6 @@
 package android.media.tv;
 
 import android.annotation.SystemApi;
-import android.net.Uri;
 import android.text.TextUtils;
 
 import java.util.Arrays;
@@ -26,115 +25,134 @@
 import java.util.Objects;
 
 /**
- * A class representing a TV content rating.
- * When a TV input service provides the content rating information of a program into TV provider,
- * TvContentRating class will be used for generating the value of {@link
- * TvContract.Programs#COLUMN_CONTENT_RATING}. To create an object of {@link TvContentRating}, use
- * the {@link #createRating} method with valid arguments. The arguments could be a system defined
- * strings, or a TV input service defined strings.
- * TV input service defined strings are in an xml file defined in <code>&lt;{@link
- * android.R.styleable#TvInputService tv-input}&gt;</code> with the {@link
- * android.R.attr#tvContentRatingDescription tvContentRatingDescription} attribute by the TV input
- * service.
- *
+ * A class representing a TV content rating. When a TV input service inserts the content rating
+ * information on a program into the database, this class can be used to generate the formatted
+ * string for
+ * {@link TvContract.Programs#COLUMN_CONTENT_RATING TvContract.Programs.COLUMN_CONTENT_RATING}.
+ * To create a {@code TvContentRating} object, use the
+ * {@link #createRating TvContentRating.createRating} method with valid rating system string
+ * constants.
+ * <p>
+ * It is possible for an application to define its own content rating system by supplying a content
+ * rating system definition XML resource (see example below) and declaring a broadcast receiver that
+ * filters {@link TvInputManager#ACTION_QUERY_CONTENT_RATING_SYSTEMS} in its manifest.
+ * </p>
  * <h3> Example: Rating system definition for the TV Parental Guidelines</h3>
- * The following XML example shows how the TV Parental Guidelines in United States can be defined:
+ * The following XML example shows how the TV Parental Guidelines in the United States can be
+ * defined:
  * <p><pre class="prettyprint">
  * {@literal
- * <?xml version="1.0" encoding="UTF-8"?>
- * <rating-system-definitions version="1.0">
- *     <rating-system-definition id="US_TV"
- *         displayName="US-TV"
- *         description="The TV Parental Guidelines"
- *         country="US">
- *         <sub-rating-definition id="US_TV_D"
- *             displayName="D"
- *             description="Suggestive dialogue (Usually means talks about sex)" />
- *         <sub-rating-definition id="US_TV_L"
- *             displayName="L"
- *             description="Coarse language" />
- *         <sub-rating-definition id="US_TV_S"
- *             displayName="S"
- *             description="Sexual content" />
- *         <sub-rating-definition id="US_TV_V"
- *             displayName="V"
- *             description="Violence" />
- *         <sub-rating-definition id="US_TV_FV"
- *             displayName="FV"
- *             description="Fantasy violence (Children\'s programming only)" />
+ * <rating-system-definitions xmlns:android="http://schemas.android.com/apk/res/android"
+ *     android:versionCode="1">
+ *     <rating-system-definition android:name="US_TV"
+ *         android:country="US"
+ *         android:description="@string/description_us_tv">
+ *         <sub-rating-definition android:name="US_TV_D"
+ *             android:title="D"
+ *             android:description="@string/description_us_tv_d" />
+ *         <sub-rating-definition android:name="US_TV_L"
+ *             android:title="L"
+ *             android:description="@string/description_us_tv_l" />
+ *         <sub-rating-definition android:name="US_TV_S"
+ *             android:title="S"
+ *             android:description="@string/description_us_tv_s" />
+ *         <sub-rating-definition android:name="US_TV_V"
+ *             android:title="V"
+ *             android:description="@string/description_us_tv_v" />
+ *         <sub-rating-definition android:name="US_TV_FV"
+ *             android:title="FV"
+ *             android:description="@string/description_us_tv_fv" />
  *
- *         <rating-definition id="US_TV_Y"
- *             displayName="TV-Y"
- *             description="This program is designed to be appropriate for all children"
- *             ageHint="0" />
- *         <rating-definition id="US_TV_Y7"
- *             displayName="TV-Y7"
- *             description="This program is designed for children age 7 and above"
- *             ageHint="7">
- *             <sub-rating id="US_TV_FV" />
+ *         <rating-definition android:name="US_TV_Y"
+ *             android:title="TV-Y"
+ *             android:description="@string/description_us_tv_y"
+ *             android:icon="@drawable/icon_us_tv_y"
+ *             android:contentAgeHint="0" />
+ *         <rating-definition android:name="US_TV_Y7"
+ *             android:title="TV-Y7"
+ *             android:description="@string/description_us_tv_y7"
+ *             android:icon="@drawable/icon_us_tv_y7"
+ *             android:contentAgeHint="7">
+ *             <sub-rating android:name="US_TV_FV" />
  *         </rating-definition>
- *         <rating-definition id="US_TV_G"
- *             displayName="TV-G"
- *             description="Most parents would find this program suitable for all ages"
- *             ageHint="0" />
- *         <rating-definition id="US_TV_PG"
- *             displayName="TV-PG"
- *             description="This program contains material that parents may find unsuitable for younger children"
- *             ageHint="14">
- *             <sub-rating id="US_TV_D" />
- *             <sub-rating id="US_TV_L" />
- *             <sub-rating id="US_TV_S" />
- *             <sub-rating id="US_TV_V" />
+ *         <rating-definition android:name="US_TV_G"
+ *             android:title="TV-G"
+ *             android:description="@string/description_us_tv_g"
+ *             android:icon="@drawable/icon_us_tv_g"
+ *             android:contentAgeHint="0" />
+ *         <rating-definition android:name="US_TV_PG"
+ *             android:title="TV-PG"
+ *             android:description="@string/description_us_tv_pg"
+ *             android:icon="@drawable/icon_us_tv_pg"
+ *             android:contentAgeHint="14">
+ *             <sub-rating android:name="US_TV_D" />
+ *             <sub-rating android:name="US_TV_L" />
+ *             <sub-rating android:name="US_TV_S" />
+ *             <sub-rating android:name="US_TV_V" />
  *         </rating-definition>
- *         <rating-definition id="US_TV_14"
- *             displayName="TV-14"
- *             description="This program contains some material that many parents would find unsuitable for children under 14 years of age"
- *             ageHint="14">
- *             <sub-rating id="US_TV_D" />
- *             <sub-rating id="US_TV_L" />
- *             <sub-rating id="US_TV_S" />
- *             <sub-rating id="US_TV_V" />
+ *         <rating-definition android:name="US_TV_14"
+ *             android:title="TV-14"
+ *             android:description="@string/description_us_tv_14"
+ *             android:icon="@drawable/icon_us_tv_14"
+ *             android:contentAgeHint="14">
+ *             <sub-rating android:name="US_TV_D" />
+ *             <sub-rating android:name="US_TV_L" />
+ *             <sub-rating android:name="US_TV_S" />
+ *             <sub-rating android:name="US_TV_V" />
  *         </rating-definition>
- *         <rating-definition id="US_TV_MA"
- *             displayName="TV-MA"
- *             description="This program is specifically designed to be viewed by adults and therefore may be unsuitable for children under 17"
- *             ageHint="17">
- *             <sub-rating id="US_TV_L" />
- *             <sub-rating id="US_TV_S" />
- *             <sub-rating id="US_TV_V" />
+ *         <rating-definition android:name="US_TV_MA"
+ *             android:title="TV-MA"
+ *             android:description="@string/description_us_tv_ma"
+ *             android:icon="@drawable/icon_us_tv_ma"
+ *             android:contentAgeHint="17">
+ *             <sub-rating android:name="US_TV_L" />
+ *             <sub-rating android:name="US_TV_S" />
+ *             <sub-rating android:name="US_TV_V" />
  *         </rating-definition>
- *         <order>
- *             <rating id="US_TV_Y" />
- *             <rating id="US_TV_Y7" />
- *         </order>
- *         <order>
- *             <rating id="US_TV_G" />
- *             <rating id="US_TV_PG" />
- *             <rating id="US_TV_14" />
- *             <rating id="US_TV_MA" />
- *         </order>
+ *         <rating-order>
+ *             <rating android:name="US_TV_Y" />
+ *             <rating android:name="US_TV_Y7" />
+ *         </rating-order>
+ *         <rating-order>
+ *             <rating android:name="US_TV_G" />
+ *             <rating android:name="US_TV_PG" />
+ *             <rating android:name="US_TV_14" />
+ *             <rating android:name="US_TV_MA" />
+ *         </rating-order>
  *     </rating-system-definition>
  * </rating-system-definitions>}</pre></p>
  *
  * <h3>System defined rating strings</h3>
- *
- * <u>System defined string for {@code domain}</u>
- * <table border="0" cellspacing="0" cellpadding="0">
+ * The following strings are defined by the system to provide a standard way to create
+ * {@code TvContentRating} objects.
+ * <p>For example, to create an object that represents TV-PG rating with suggestive dialogue and
+ * coarse language from the TV Parental Guidelines in the United States, one can use the following
+ * code snippet:
+ * </p>
+ * <pre>
+ * TvContentRating rating = TvContentRating.createRating(
+ *         "com.android.tv",
+ *         "US_TV",
+ *         "US_TV_PG",
+ *         "US_TV_D", "US_TV_L");
+ * </pre>
+ * <h4>System defined string for domains</h4>
+ * <table>
  *     <tr>
- *         <td width=10%>String value</td>
- *         <td>Comments</td>
+ *         <th>Constant Value</th>
+ *         <th>Description</th>
  *     </tr>
  *     <tr>
- *         <td>android.media.tv</td>
+ *         <td>com.android.tv</td>
  *         <td>Used for creating system defined content ratings</td>
  *     </tr>
  * </table>
  *
- * <u>System defined string for {@code ratingSystem}</u>
- * <table border="1" cellspacing="0" cellpadding="0">
+ * <h4>System defined strings for rating systems</h4>
+ * <table>
  *     <tr>
- *         <td width="10%">String value</td>
- *         <td>Comments</td>
+ *         <th>Constant Value</th>
+ *         <th>Description</th>
  *     </tr>
  *     <tr>
  *         <td>AM_TV_RS</td>
@@ -161,8 +179,12 @@
  *         <td>TV content rating system for Brazil</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV</td>
- *         <td>TV content rating system for Canada</td>
+ *         <td>CA_TV_CA</td>
+ *         <td>TV content rating system for Canada (Canadian)</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC</td>
+ *         <td>TV content rating system for Canada (Quebec)</td>
  *     </tr>
  *     <tr>
  *         <td>CH_TV</td>
@@ -225,6 +247,10 @@
  *         <td>TV content rating system for Iceland</td>
  *     </tr>
  *     <tr>
+ *         <td>JP_TV</td>
+ *         <td>TV content rating system for Japan</td>
+ *     </tr>
+ *     <tr>
  *         <td>KR_TV</td>
  *         <td>TV content rating system for South Korea</td>
  *     </tr>
@@ -286,11 +312,7 @@
  *         <td>TV content rating system for Serbia</td>
  *     </tr>
  *     <tr>
- *         <td>SG_FTV</td>
- *         <td>TV content rating system for Singapore</td>
- *     </tr>
- *     <tr>
- *         <td>SG_PTV</td>
+ *         <td>SG_TV</td>
  *         <td>TV content rating system for Singapore</td>
  *     </tr>
  *     <tr>
@@ -315,7 +337,7 @@
  *     </tr>
  *     <tr>
  *         <td>US_TV</td>
- *         <td>TV content rating system for United States</td>
+ *         <td>TV content rating system for the United States</td>
  *     </tr>
  *     <tr>
  *         <td>VE_TV</td>
@@ -327,12 +349,12 @@
  *     </tr>
  * </table>
  *
- * <u>System defined string for {@code rating}</u>
- * <table border="1" cellspacing="0" cellpadding="0">
+ * <h4>System defined strings for ratings</h4>
+ * <table>
  *     <tr>
- *         <td width="10%">RatingSystem code</td>
- *         <td width="10%">Rating string value</td>
- *         <td>Comments</td>
+ *         <th>Rating System</th>
+ *         <th>Constant Value</th>
+ *         <th>Description</th>
  *     </tr>
  *     <tr>
  *         <td valign="top" rowspan="6">AM_TV_RS</td>
@@ -493,42 +515,67 @@
  *         <td>Content suitable for viewers over the age of 18</td>
  *     </tr>
  *     <tr>
- *         <td valign="top" rowspan="7">CA_TV</td>
- *         <td>CA_TV_EXEMPT</td>
- *         <td>Shows which are exempt from ratings (such as news and sports programming) will not
- *         display an on-screen rating at all</td>
+ *         <td valign="top" rowspan="7">CA_TV_CA</td>
+ *         <td>CA_TV_CA_EXEMPT</td>
+ *         <td>Exempt from ratings and won't display an on-screen rating</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_C</td>
- *         <td>Programming suitable for children ages of 2-7 years. No profanity or sexual content
- *         of any level allowed. Contains little violence</td>
+ *         <td>CA_TV_CA_C</td>
+ *         <td>Suitable for children ages 2-7. May contain mild violence</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_C8</td>
- *         <td>Suitable for children ages 8+. Low level violence and fantasy horror is allowed. No
- *         foul language is allowed, but occasional "socially offensive and discriminatory" language
- *         is allowed if in the context of the story. No sexual content of any level allowed</td>
+ *         <td>CA_TV_CA_C8</td>
+ *         <td>Suitable for children ages 8 and older. May contain mild violence, fantasy horror,
+ *         and socially offensive language</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_G</td>
- *         <td>Suitable for general audiences. Programming suitable for the entire family with mild
- *         violence, and mild profanity and/or censored language</td>
+ *         <td>CA_TV_CA_G</td>
+ *         <td>Suitable for the entire family and may contain mild violence, profanity, and censored
+ *         language</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_PG</td>
- *         <td>Parental guidance. Moderate violence and moderate profanity is allowed, as is brief
- *         nudity and sexual references if important to the context of the story</td>
+ *         <td>CA_TV_CA_PG</td>
+ *         <td>May contain moderate violence, profanity, nudity, and sexual references</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_14</td>
- *         <td>Programming intended for viewers ages 14 and older. May contain strong violence and
- *         strong profanity, and depictions of sexual activity as long as they are within the
- *         context of a story</td>
+ *         <td>CA_TV_CA_14</td>
+ *         <td>Intended for viewers ages 14 and older. May contain strong violence and profanity,
+ *         and depictions of sexual activity</td>
  *     </tr>
  *     <tr>
- *         <td>CA_TV_18</td>
- *         <td>Programming intended for viewers ages 18 and older. May contain explicit violence and
- *         sexual activity</td>
+ *         <td>CA_TV_CA_18</td>
+ *         <td>Intended for viewers ages 18 and older. May contain explicit violence and sexual
+ *         activity</td>
+ *     </tr>
+ *     <tr>
+ *         <td valign="top" rowspan="6">CA_TV_QC</td>
+ *         <td>CA_TV_QC_E</td>
+ *         <td>Exempt from ratings and won't display an on-screen rating</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC_G</td>
+ *         <td>Appropriate for all ages and must contain little or no violence and little to no
+ *         sexual content</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC_8</td>
+ *         <td>Appropriate for children 8 and may contain with little violence, language, and little
+ *         to no sexual situations</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC_13</td>
+ *         <td>Suitable for children 13 and may contain with moderate violence, language, and some
+ *         sexual situations</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC_16</td>
+ *         <td>Recommended for children over the age of 16 and may contain with strong violence,
+ *         strong language, and strong sexual content</td>
+ *     </tr>
+ *     <tr>
+ *         <td>CA_TV_QC_18</td>
+ *         <td>Only to be viewed by adults and may contain extreme violence and graphic sexual
+ *         content. It is mostly used for 18+ movies and pornography</td>
  *     </tr>
  *     <tr>
  *         <td valign="top" rowspan="2">CH_TV</td>
@@ -677,7 +724,7 @@
  *     </tr>
  *     <tr>
  *         <td valign="top" rowspan="5">GR_TV</td>
- *         <td>GR_TV_all</td>
+ *         <td>GR_TV_ALL</td>
  *         <td>Suitable for all ages</td>
  *     </tr>
  *     <tr>
@@ -779,7 +826,7 @@
  *         <td>Suitable for all ages</td>
  *     </tr>
  *     <tr>
- *         <td>IE_TV_Ch</td>
+ *         <td>IE_TV_CH</td>
  *         <td>Suitable for children ages 5 to 10, may contain comedic violence or action fantasy
  *         violence</td>
  *     </tr>
@@ -826,7 +873,7 @@
  *         <td>Unrestricted public exhibition</td>
  *     </tr>
  *     <tr>
- *         <td>IN_TV_U/A</td>
+ *         <td>IN_TV_U_A</td>
  *         <td>Unrestricted public exhibition, but with a caution regarding parental guidance to
  *         those under 12 years of age</td>
  *     </tr>
@@ -869,8 +916,25 @@
  *         <td>Programs suitable for ages 18 and older</td>
  *     </tr>
  *     <tr>
+ *         <td valign="top" rowspan="4">JP_TV</td>
+ *         <td>JP_TV_G</td>
+ *         <td>General, suitable for all ages</td>
+ *     </tr>
+ *     <tr>
+ *         <td>JP_TV_PG12</td>
+ *         <td>Parental guidance requested for young people under 12 years</td>
+ *     </tr>
+ *     <tr>
+ *         <td>JP_TV_R15</td>
+ *         <td>For persons aged 15 and above only</td>
+ *     </tr>
+ *     <tr>
+ *         <td>JP_TV_R18</td>
+ *         <td>For persons aged 18 and above only</td>
+ *     </tr>
+ *     <tr>
  *         <td valign="top" rowspan="5">KR_TV</td>
- *         <td>KR_TV_All</td>
+ *         <td>KR_TV_ALL</td>
  *         <td>Appropriate for all ages</td>
  *     </tr>
  *     <tr>
@@ -906,7 +970,7 @@
  *         <td>Parental guidance is required unaccompanied children</td>
  *     </tr>
  *     <tr>
- *         <td>MV_TV_PG-12</td>
+ *         <td>MV_TV_PG_12</td>
  *         <td>Parental guidance is required for children under the age of 12</td>
  *     </tr>
  *     <tr>
@@ -941,7 +1005,7 @@
  *         and mild language</td>
  *     </tr>
  *     <tr>
- *         <td>MX_TV_B-15</td>
+ *         <td>MX_TV_B_15</td>
  *         <td>Designed for ages 15 and up, slightly more intensive than the 'A' and 'B' ratings
  *         </td>
  *     </tr>
@@ -1201,22 +1265,30 @@
  *         <td>Program not suitable for minors under the age of 18</td>
  *     </tr>
  *     <tr>
- *         <td valign="top" rowspan="2">SG_FTV</td>
- *         <td>SG_FTV_PG</td>
- *         <td>Suitable for most but parents should guide their young</td>
+ *         <td valign="top" rowspan="6">SG_TV</td>
+ *         <td>SG_TV_G</td>
+ *         <td>Suitable for all ages</td>
  *     </tr>
  *     <tr>
- *         <td>SG_FTV_PG13</td>
- *         <td>Parental Guidance Strongly Cautioned - Suitable for 13 And Above</td>
+ *         <td>SG_TV_PG</td>
+ *         <td>Suitable for all but parents should guide their young</td>
  *     </tr>
  *     <tr>
- *         <td valign="top" rowspan="2">SG_PTV</td>
- *         <td>SG_PTV_NC16</td>
- *         <td>No Children Under 16</td>
+ *         <td>SG_TV_PG13</td>
+ *         <td>Suitable for persons aged 13 and above but parental guidance is advised for children
+ *         below 13</td>
  *     </tr>
  *     <tr>
- *         <td>SG_PTV_M18</td>
- *         <td>Nobody under age 18 is admitted</td>
+ *         <td>SG_TV_NC16</td>
+ *         <td>Suitable for persons aged 16 and above</td>
+ *     </tr>
+ *     <tr>
+ *         <td>SG_TV_M18</td>
+ *         <td>Suitable for persons aged 18 and above</td>
+ *     </tr>
+ *     <tr>
+ *         <td>SG_TV_R21</td>
+ *         <td>Suitable for adults aged 21 and above</td>
  *     </tr>
  *     <tr>
  *         <td valign="top" rowspan="4">SI_TV</td>
@@ -1400,12 +1472,12 @@
  *     </tr>
  * </table>
  *
- * <u>System defined string for {@code subRating}</u>
- * <table border="1" cellspacing="0" cellpadding="0">
+ * <h4>System defined strings for sub-ratings</h4>
+ * <table>
  *     <tr>
- *         <td width="10%">RatingSystem code</td>
- *         <td width="10%">Rating string value</td>
- *         <td>Comments</td>
+ *         <th>Rating System</th>
+ *         <th>Constant Value</th>
+ *         <th>Description</th>
  *     </tr>
  *     <tr>
  *         <td valign="top" rowspan="6">NL_TV</td>
@@ -1506,10 +1578,6 @@
  * </table>
  */
 public final class TvContentRating {
-    /** @hide */
-    public static final Uri SYSTEM_CONTENT_RATING_SYSTEM_XML = Uri.parse(
-            "android.resource://system/" + com.android.internal.R.xml.tv_content_rating_systems);
-
     // TODO: Consider to use other DELIMITER. In some countries such as India may use this delimiter
     // in the main ratings.
     private static final String DELIMITER = "/";
@@ -1521,13 +1589,15 @@
     private final int mHashCode;
 
     /**
-     * Creates a TvContentRating object.
+     * Creates a {@code TvContentRating} object with predefined content rating strings.
      *
-     * @param domain The domain name.
-     * @param ratingSystem The rating system id.
-     * @param rating The content rating string.
-     * @param subRatings The string array of sub-ratings.
-     * @return A TvContentRating object, or null if creation failed.
+     * @param domain The domain string. For example, "com.android.tv".
+     * @param ratingSystem The rating system string. For example, "US_TV".
+     * @param rating The content rating string. For example, "US_TV_PG".
+     * @param subRatings The sub-rating strings. For example, "US_TV_D" and "US_TV_L".
+     * @return A {@code TvContentRating} object.
+     * @throws IllegalArgumentException If {@code domain}, {@code ratingSystem} or {@code rating} is
+     *             {@code null}.
      */
     public static TvContentRating createRating(String domain, String ratingSystem,
             String rating, String... subRatings) {
@@ -1544,12 +1614,12 @@
     }
 
     /**
-     * Recovers a TvContentRating from a String that was previously created with
+     * Recovers a {@code TvContentRating} object from the string that was previously created from
      * {@link #flattenToString}.
      *
-     * @param ratingString The String that was returned by flattenToString().
-     * @return a new TvContentRating containing the domain, rating system, rating and
-     *         sub-ratings information was encoded in {@code ratingString}.
+     * @param ratingString The string returned by {@link #flattenToString}.
+     * @return the {@code TvContentRating} object containing the domain, rating system, rating and
+     *         sub-ratings information encoded in {@code ratingString}.
      * @see #flattenToString
      */
     public static TvContentRating unflattenFromString(String ratingString) {
@@ -1571,10 +1641,10 @@
     /**
      * Constructs a TvContentRating object from a given rating and sub-rating constants.
      *
-     * @param domain The domain name.
-     * @param ratingSystem The rating system id.
-     * @param rating The content rating string.
-     * @param subRatings The String array of sub-rating constants defined in this class.
+     * @param domain The string for domain of the content rating system such as "com.android.tv".
+     * @param ratingSystem The rating system string such as "US_TV".
+     * @param rating The content rating string such as "US_TV_PG".
+     * @param subRatings The sub-rating strings such as "US_TV_D" and "US_TV_L".
      */
     private TvContentRating(
             String domain, String ratingSystem, String rating, String[] subRatings) {
@@ -1591,28 +1661,29 @@
     }
 
     /**
-     * Returns the domain.
+     * Returns the domain of this {@code TvContentRating} object.
      */
     public String getDomain() {
         return mDomain;
     }
 
     /**
-     * Returns the rating system id.
+     * Returns the rating system of this {@code TvContentRating} object.
      */
     public String getRatingSystem() {
         return mRatingSystem;
     }
 
     /**
-     * Returns the main rating.
+     * Returns the main rating of this {@code TvContentRating} object.
      */
     public String getMainRating() {
         return mRating;
     }
 
     /**
-     * Returns the unmodifiable {@code List} of sub-rating strings.
+     * Returns the unmodifiable sub-rating string {@link List} of this {@code TvContentRating}
+     * object.
      */
     public List<String> getSubRatings() {
         if (mSubRatings == null) {
@@ -1622,12 +1693,12 @@
     }
 
     /**
-     * Returns a String that unambiguously describes both the rating and sub-rating information
-     * contained in the TvContentRating. You can later recover the TvContentRating from this string
-     * through {@link #unflattenFromString}.
+     * Returns a string that unambiguously describes the rating information contained in a
+     * {@code TvContentRating} object. One can later recover the object from this string through
+     * {@link #unflattenFromString}.
      *
-     * @return a new String holding rating/sub-rating information, which can later be stored in the
-     *         database and settings.
+     * @return a string containing the rating information, which can later be stored in the
+     *         database.
      * @see #unflattenFromString
      */
     public String flattenToString() {
@@ -1647,11 +1718,11 @@
     }
 
     /**
-     * Returns true if this rating has the same main rating as the specified rating and when this
-     * rating's sub-ratings contain the other's.
+     * Returns {@code true} if this rating has the same main rating as the specified rating and when
+     * this rating's sub-ratings contain the other's.
      * <p>
-     * For example, a TvContentRating object that represents TV-PG with S(Sexual content) and
-     * V(Violence) contains TV-PG, TV-PG/S, TV-PG/V and itself.
+     * For example, a {@code TvContentRating} object that represents TV-PG with S(Sexual content)
+     * and V(Violence) contains TV-PG, TV-PG/S, TV-PG/V and itself.
      * </p>
      *
      * @param rating The {@link TvContentRating} to check.
diff --git a/media/java/android/media/tv/TvContentRatingSystemInfo.aidl b/media/java/android/media/tv/TvContentRatingSystemInfo.aidl
new file mode 100644
index 0000000..957be62
--- /dev/null
+++ b/media/java/android/media/tv/TvContentRatingSystemInfo.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (C) 2014 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 android.media.tv;
+
+parcelable TvContentRatingSystemInfo;
\ No newline at end of file
diff --git a/media/java/android/media/tv/TvContentRatingSystemInfo.java b/media/java/android/media/tv/TvContentRatingSystemInfo.java
new file mode 100644
index 0000000..f2e5b08
--- /dev/null
+++ b/media/java/android/media/tv/TvContentRatingSystemInfo.java
@@ -0,0 +1,111 @@
+/*
+ * Copyright (C) 2014 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 android.media.tv;
+
+import android.annotation.SystemApi;
+import android.content.ContentResolver;
+import android.content.pm.ApplicationInfo;
+import android.net.Uri;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * TvContentRatingSystemInfo class provides information about a specific TV content rating system
+ * defined either by a system app or by a third-party app.
+ *
+ * @hide
+ */
+@SystemApi
+public final class TvContentRatingSystemInfo implements Parcelable {
+    private final Uri mXmlUri;
+
+    private final ApplicationInfo mApplicationInfo;
+
+    /**
+     * Creates a TvContentRatingSystemInfo object with given resource ID and receiver info.
+     *
+     * @param xmlResourceId The ID of an XML resource whose root element is
+     *            <code> &lt;rating-system-definitions&gt;</code>
+     * @param applicationInfo Information about the application that provides the TV content rating
+     *            system definition.
+     */
+    public static final TvContentRatingSystemInfo createTvContentRatingSystemInfo(int xmlResourceId,
+            ApplicationInfo applicationInfo) {
+        Uri uri = new Uri.Builder()
+                .scheme(ContentResolver.SCHEME_ANDROID_RESOURCE)
+                .authority(applicationInfo.packageName)
+                .appendPath(String.valueOf(xmlResourceId))
+                .build();
+        return new TvContentRatingSystemInfo(uri, applicationInfo);
+    }
+
+    private TvContentRatingSystemInfo(Uri xmlUri, ApplicationInfo applicationInfo) {
+        mXmlUri = xmlUri;
+        mApplicationInfo = applicationInfo;
+    }
+
+    /**
+     * Returns {@code true} if the TV content rating system is defined by a system app,
+     * {@code false} otherwise.
+     */
+    public final boolean isSystemDefined() {
+        return (mApplicationInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0;
+    }
+
+    /**
+     * Returns the URI to the XML resource that defines the TV content rating system.
+     *
+     * TODO: Remove. Instead, parse the XML resource and provide an interface to directly access
+     * parsed information.
+     */
+    public final Uri getXmlUri() {
+        return mXmlUri;
+    }
+
+    /**
+     * Used to make this class parcelable.
+     * @hide
+     */
+    public static final Parcelable.Creator<TvContentRatingSystemInfo> CREATOR =
+            new Parcelable.Creator<TvContentRatingSystemInfo>() {
+        @Override
+        public TvContentRatingSystemInfo createFromParcel(Parcel in) {
+            return new TvContentRatingSystemInfo(in);
+        }
+
+        @Override
+        public TvContentRatingSystemInfo[] newArray(int size) {
+            return new TvContentRatingSystemInfo[size];
+        }
+    };
+
+    private TvContentRatingSystemInfo(Parcel in) {
+        mXmlUri = in.readParcelable(null);
+        mApplicationInfo = in.readParcelable(null);
+    }
+
+    @Override
+    public void writeToParcel(Parcel dest, int flags) {
+        dest.writeParcelable(mXmlUri, flags);
+        dest.writeParcelable(mApplicationInfo, flags);
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+}
diff --git a/media/java/android/media/tv/TvContract.java b/media/java/android/media/tv/TvContract.java
index bdceb24..b3890d4 100644
--- a/media/java/android/media/tv/TvContract.java
+++ b/media/java/android/media/tv/TvContract.java
@@ -680,12 +680,13 @@
          * <p>
          * A value of 1 indicates the channel is included in the channel list that applications use
          * to browse channels, a value of 0 indicates the channel is not included in the list. If
-         * not specified, this value is set to 1 (browsable) by default.
+         * not specified, this value is set to 0 (not browsable) by default.
          * </p><p>
          * Type: INTEGER (boolean)
          * </p>
          * @hide
          */
+        @SystemApi
         public static final String COLUMN_BROWSABLE = "browsable";
 
         /**
@@ -717,6 +718,7 @@
          * </p>
          * @hide
          */
+        @SystemApi
         public static final String COLUMN_LOCKED = "locked";
 
         /**
@@ -943,8 +945,8 @@
         /**
          * The comma-separated audio languages of this TV program.
          * <p>
-         * This is used to describe available audio languages included in the program. Use
-         * 3-character language code as specified by ISO 639-2.
+         * This is used to describe available audio languages included in the program. Use either
+         * ISO 639-1 or 639-2/T codes.
          * </p><p>
          * Type: TEXT
          * </p>
diff --git a/media/java/android/media/tv/TvInputInfo.java b/media/java/android/media/tv/TvInputInfo.java
index 6a7433d..54ebc6a 100644
--- a/media/java/android/media/tv/TvInputInfo.java
+++ b/media/java/android/media/tv/TvInputInfo.java
@@ -18,7 +18,6 @@
 
 import android.annotation.SystemApi;
 import android.content.ComponentName;
-import android.content.ContentResolver;
 import android.content.Context;
 import android.content.Intent;
 import android.content.pm.PackageManager;
@@ -46,7 +45,6 @@
 
 import java.io.IOException;
 import java.io.InputStream;
-import java.util.Arrays;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Map;
@@ -104,7 +102,7 @@
     /**
      * The ID of the TV input to provide to the setup activity and settings activity.
      */
-    public static final String EXTRA_INPUT_ID = "inputId";
+    public static final String EXTRA_INPUT_ID = "android.media.tv.extra.INPUT_ID";
 
     private static SparseIntArray sHardwareTypeToTvInputType = new SparseIntArray();
 
@@ -122,11 +120,12 @@
     // Attributes from XML meta data.
     private String mSetupActivity;
     private String mSettingsActivity;
+
     private int mType = TYPE_TUNER;
+    private HdmiDeviceInfo mHdmiDeviceInfo;
     private String mLabel;
     private Uri mIconUri;
     private boolean mIsConnectedToHdmiSwitch;
-    private Uri mRatingSystemXmlUri;
 
     static {
         sHardwareTypeToTvInputType.put(TvInputHardwareInfo.TV_INPUT_TYPE_OTHER_HARDWARE,
@@ -158,40 +157,42 @@
     }
 
     /**
-     * Create a new instance of the TvInputInfo class,
-     * instantiating it from the given Context, ResolveInfo, and HdmiDeviceInfo.
+     * Create a new instance of the TvInputInfo class, instantiating it from the given Context,
+     * ResolveInfo, and HdmiDeviceInfo.
      *
      * @param service The ResolveInfo returned from the package manager about this TV input service.
-     * @param deviceInfo The HdmiDeviceInfo for a HDMI CEC logical device.
+     * @param hdmiDeviceInfo The HdmiDeviceInfo for a HDMI CEC logical device.
      * @param parentId The ID of this TV input's parent input. {@code null} if none exists.
-     * @param iconUri The {@link android.net.Uri} to load the icon image.
-     *        {@see android.content.ContentResolver#openInputStream}. If it is null, the application
-     *        icon of {@code service} will be loaded.
-     * @param label The label of this TvInputInfo. If it is null or empty, {@code service} label
-     *        will be loaded.
+     * @param iconUri The {@link android.net.Uri} to load the icon image. See
+     *            {@link android.content.ContentResolver#openInputStream}. If it is {@code null},
+     *            the application icon of {@code service} will be loaded.
+     * @param label The label of this TvInputInfo. If it is {@code null} or empty, {@code service}
+     *            label will be loaded.
      * @hide
      */
     @SystemApi
     public static TvInputInfo createTvInputInfo(Context context, ResolveInfo service,
-            HdmiDeviceInfo deviceInfo, String parentId, String label, Uri iconUri)
+            HdmiDeviceInfo hdmiDeviceInfo, String parentId, String label, Uri iconUri)
                     throws XmlPullParserException, IOException {
-        boolean isConnectedToHdmiSwitch = (deviceInfo.getPhysicalAddress() & 0x0FFF) != 0;
-        return createTvInputInfo(context, service, generateInputIdForHdmiDevice(
+        boolean isConnectedToHdmiSwitch = (hdmiDeviceInfo.getPhysicalAddress() & 0x0FFF) != 0;
+        TvInputInfo input = createTvInputInfo(context, service, generateInputIdForHdmiDevice(
                 new ComponentName(service.serviceInfo.packageName, service.serviceInfo.name),
-                deviceInfo), parentId, TYPE_HDMI, label, iconUri, isConnectedToHdmiSwitch);
+                hdmiDeviceInfo), parentId, TYPE_HDMI, label, iconUri, isConnectedToHdmiSwitch);
+        input.mHdmiDeviceInfo = hdmiDeviceInfo;
+        return input;
     }
 
     /**
-     * Create a new instance of the TvInputInfo class,
-     * instantiating it from the given Context, ResolveInfo, and TvInputHardwareInfo.
+     * Create a new instance of the TvInputInfo class, instantiating it from the given Context,
+     * ResolveInfo, and TvInputHardwareInfo.
      *
      * @param service The ResolveInfo returned from the package manager about this TV input service.
      * @param hardwareInfo The TvInputHardwareInfo for a TV input hardware device.
-     * @param iconUri The {@link android.net.Uri} to load the icon image.
-     *        {@see android.content.ContentResolver#openInputStream}. If it is null, the application
-     *        icon of {@code service} will be loaded.
-     * @param label The label of this TvInputInfo. If it is null or empty, {@code service} label
-     *        will be loaded.
+     * @param iconUri The {@link android.net.Uri} to load the icon image. See
+     *            {@link android.content.ContentResolver#openInputStream}. If it is {@code null},
+     *            the application icon of {@code service} will be loaded.
+     * @param label The label of this TvInputInfo. If it is {@code null} or empty, {@code service}
+     *            label will be loaded.
      * @hide
      */
     @SystemApi
@@ -246,19 +247,6 @@
                 Log.d(TAG, "Settings activity loaded. [" + input.mSettingsActivity + "] for "
                         + si.name);
             }
-            int tvContentRatingDescription = sa.getResourceId(
-                    com.android.internal.R.styleable.TvInputService_tvContentRatingDescription, -1);
-            if (tvContentRatingDescription != -1) {
-                input.mRatingSystemXmlUri = new Uri.Builder()
-                        .scheme(ContentResolver.SCHEME_ANDROID_RESOURCE)
-                        .authority(si.packageName)
-                        .appendPath(Integer.toString(tvContentRatingDescription))
-                        .build();
-                if (DEBUG) {
-                    Log.d(TAG, "Content rating xml loaded. [" + tvContentRatingDescription
-                            + "] for " + si.name);
-                }
-            }
             sa.recycle();
 
             input.mLabel = label;
@@ -335,9 +323,9 @@
     }
 
     /**
-     * Returns an intent to start the setup activity for this TV input service.
+     * Returns an intent to start the setup activity for this TV input.
      */
-    public Intent getIntentForSetupActivity() {
+    public Intent createSetupIntent() {
         if (!TextUtils.isEmpty(mSetupActivity)) {
             Intent intent = new Intent(Intent.ACTION_MAIN);
             intent.setClassName(mService.serviceInfo.packageName, mSetupActivity);
@@ -348,9 +336,9 @@
     }
 
     /**
-     * Returns an intent to start the settings activity for this TV input service.
+     * Returns an intent to start the settings activity for this TV input.
      */
-    public Intent getIntentForSettingsActivity() {
+    public Intent createSettingsIntent() {
         if (!TextUtils.isEmpty(mSettingsActivity)) {
             Intent intent = new Intent(Intent.ACTION_MAIN);
             intent.setClassName(mService.serviceInfo.packageName, mSettingsActivity);
@@ -361,24 +349,27 @@
     }
 
     /**
-     * Returns the type of this TV input service.
+     * Returns the type of this TV input.
      */
     public int getType() {
         return mType;
     }
 
     /**
-     * Returns the resource uri for the rating system xml of this TV input service.
+     * Returns the HDMI device information of this TV input.
      * @hide
      */
     @SystemApi
-    public Uri getRatingSystemXmlUri() {
-        return mRatingSystemXmlUri;
+    public HdmiDeviceInfo getHdmiDeviceInfo() {
+        if (mType == TYPE_HDMI) {
+            return mHdmiDeviceInfo;
+        }
+        return null;
     }
 
     /**
-     * Returns {@code true} if this TV input is pass-though which does not have any real channels
-     * in TvProvider. {@code false} otherwise.
+     * Returns {@code true} if this TV input is pass-though which does not have any real channels in
+     * TvProvider. {@code false} otherwise.
      *
      * @see TvContract#buildChannelUriForPassthroughInput(String)
      */
@@ -441,23 +432,22 @@
      * Loads the user-displayed icon for this TV input.
      *
      * @param context Supplies a {@link Context} used to load the icon.
-     * @return a Drawable containing the TV input's icon. If the TV input does not have
-     *         an icon, application icon is returned. If it's unavailable too, system default is
-     *         returned.
+     * @return a Drawable containing the TV input's icon. If the TV input does not have an icon,
+     *         application's icon is returned. If it's unavailable too, {@code null} is returned.
      */
     public Drawable loadIcon(Context context) {
         if (mIconUri == null) {
-            return loadDefaultIcon(context);
+            return loadServiceIcon(context);
         }
         try (InputStream is = context.getContentResolver().openInputStream(mIconUri)) {
             Drawable drawable = Drawable.createFromStream(is, null);
             if (drawable == null) {
-                return loadDefaultIcon(context);
+                return loadServiceIcon(context);
             }
             return drawable;
         } catch (IOException e) {
             Log.w(TAG, "Loading the default icon due to a failure on loading " + mIconUri, e);
-            return loadDefaultIcon(context);
+            return loadServiceIcon(context);
         }
     }
 
@@ -506,13 +496,17 @@
         dest.writeString(mSetupActivity);
         dest.writeString(mSettingsActivity);
         dest.writeInt(mType);
+        dest.writeParcelable(mHdmiDeviceInfo, flags);
         dest.writeParcelable(mIconUri, flags);
         dest.writeString(mLabel);
         dest.writeByte(mIsConnectedToHdmiSwitch ? (byte) 1 : 0);
-        dest.writeParcelable(mRatingSystemXmlUri, flags);
     }
 
-    private Drawable loadDefaultIcon(Context context) {
+    private Drawable loadServiceIcon(Context context) {
+        if (mService.serviceInfo.icon == 0
+                && mService.serviceInfo.applicationInfo.icon == 0) {
+            return null;
+        }
         return mService.serviceInfo.loadIcon(context.getPackageManager());
     }
 
@@ -555,10 +549,6 @@
                 DELIMITER_INFO_IN_ID, PREFIX_HARDWARE_DEVICE, hardwareInfo.getDeviceId());
     }
 
-    /**
-     * Used to make this class parcelable.
-     * @hide
-     */
     public static final Parcelable.Creator<TvInputInfo> CREATOR =
             new Parcelable.Creator<TvInputInfo>() {
         @Override
@@ -579,10 +569,10 @@
         mSetupActivity = in.readString();
         mSettingsActivity = in.readString();
         mType = in.readInt();
+        mHdmiDeviceInfo = in.readParcelable(null);
         mIconUri = in.readParcelable(null);
         mLabel = in.readString();
         mIsConnectedToHdmiSwitch = in.readByte() == 1 ? true : false;
-        mRatingSystemXmlUri = in.readParcelable(null);
     }
 
     /**
@@ -616,11 +606,15 @@
         public static Set<String> getHiddenTvInputIds(Context context, int userId) {
             String hiddenIdsString = Settings.Secure.getStringForUser(
                     context.getContentResolver(), Settings.Secure.TV_INPUT_HIDDEN_INPUTS, userId);
+            Set<String> set = new HashSet<String>();
             if (TextUtils.isEmpty(hiddenIdsString)) {
-                return new HashSet<String>();
+                return set;
             }
             String[] ids = hiddenIdsString.split(TV_INPUT_SEPARATOR);
-            return new HashSet(Arrays.asList(ids));
+            for (String id : ids) {
+                set.add(Uri.decode(id));
+            }
+            return set;
         }
 
         /**
@@ -641,7 +635,7 @@
             String[] pairs = labelsString.split(TV_INPUT_SEPARATOR);
             for (String pairString : pairs) {
                 String[] pair = pairString.split(CUSTOM_NAME_SEPARATOR);
-                map.put(pair[0], pair[1]);
+                map.put(Uri.decode(pair[0]), Uri.decode(pair[1]));
             }
             return map;
         }
@@ -667,7 +661,7 @@
                 } else {
                     builder.append(TV_INPUT_SEPARATOR);
                 }
-                builder.append(inputId);
+                builder.append(Uri.encode(inputId));
             }
             Settings.Secure.putStringForUser(context.getContentResolver(),
                     Settings.Secure.TV_INPUT_HIDDEN_INPUTS, builder.toString(), userId);
@@ -695,9 +689,9 @@
                 } else {
                     builder.append(TV_INPUT_SEPARATOR);
                 }
-                builder.append(entry.getKey());
+                builder.append(Uri.encode(entry.getKey()));
                 builder.append(CUSTOM_NAME_SEPARATOR);
-                builder.append(entry.getValue());
+                builder.append(Uri.encode(entry.getValue()));
             }
             Settings.Secure.putStringForUser(context.getContentResolver(),
                     Settings.Secure.TV_INPUT_CUSTOM_LABELS, builder.toString(), userId);
@@ -707,14 +701,6 @@
             if (TextUtils.isEmpty(value)) {
                 throw new IllegalArgumentException(value + " should not empty ");
             }
-            if (value.contains(TV_INPUT_SEPARATOR)) {
-                throw new IllegalArgumentException(value + " should not include "
-                        + TV_INPUT_SEPARATOR);
-            }
-            if (value.contains(CUSTOM_NAME_SEPARATOR)) {
-                throw new IllegalArgumentException(value + " should not include "
-                        + CUSTOM_NAME_SEPARATOR);
-            }
         }
     }
 }
diff --git a/media/java/android/media/tv/TvInputManager.java b/media/java/android/media/tv/TvInputManager.java
index 6e075b2..78714d2 100644
--- a/media/java/android/media/tv/TvInputManager.java
+++ b/media/java/android/media/tv/TvInputManager.java
@@ -33,6 +33,7 @@
 import android.view.InputChannel;
 import android.view.InputEvent;
 import android.view.InputEventSender;
+import android.view.KeyEvent;
 import android.view.Surface;
 import android.view.View;
 
@@ -74,7 +75,7 @@
      * The TV input is connected.
      * <p>
      * State for {@link #getInputState} and {@link
-     * TvInputManager.TvInputListener#onInputStateChanged}.
+     * TvInputManager.TvInputCallback#onInputStateChanged}.
      * </p>
      */
     public static final int INPUT_STATE_CONNECTED = 0;
@@ -83,7 +84,7 @@
      * fully ready.
      * <p>
      * State for {@link #getInputState} and {@link
-     * TvInputManager.TvInputListener#onInputStateChanged}.
+     * TvInputManager.TvInputCallback#onInputStateChanged}.
      * </p>
      */
     public static final int INPUT_STATE_CONNECTED_STANDBY = 1;
@@ -91,7 +92,7 @@
      * The TV input is disconnected.
      * <p>
      * State for {@link #getInputState} and {@link
-     * TvInputManager.TvInputListener#onInputStateChanged}.
+     * TvInputManager.TvInputCallback#onInputStateChanged}.
      * </p>
      */
     public static final int INPUT_STATE_DISCONNECTED = 2;
@@ -110,13 +111,57 @@
     public static final String ACTION_PARENTAL_CONTROLS_ENABLED_CHANGED =
             "android.media.tv.action.PARENTAL_CONTROLS_ENABLED_CHANGED";
 
+    /**
+     * Broadcast intent action used to query available content rating systems.
+     * <p>
+     * The TV input manager service locates available content rating systems by querying broadcast
+     * receivers that are registered for this action. An application can offer additional content
+     * rating systems to the user by declaring a suitable broadcast receiver in its manifest.
+     * </p><p>
+     * Here is an example broadcast receiver declaration that an application might include in its
+     * AndroidManifest.xml to advertise custom content rating systems. The meta-data specifies a
+     * resource that contains a description of each content rating system that is provided by the
+     * application.
+     * <p><pre class="prettyprint">
+     * {@literal
+     * <receiver android:name=".TvInputReceiver">
+     *     <intent-filter>
+     *         <action android:name=
+     *                 "android.media.tv.TvInputManager.ACTION_QUERY_CONTENT_RATING_SYSTEMS" />
+     *     </intent-filter>
+     *     <meta-data
+     *             android:name="android.media.tv.TvInputManager.META_DATA_CONTENT_RATING_SYSTEMS"
+     *             android:resource="@xml/tv_content_rating_systems" />
+     * </receiver>}</pre></p>
+     * In the above example, the <code>@xml/tv_content_rating_systems</code> resource refers to an
+     * XML resource whose root element is <code>&lt;rating-system-definitions&gt;</code> that
+     * contains zero or more <code>&lt;rating-system-definition&gt;</code> elements. Each <code>
+     * &lt;rating-system-definition&gt;</code> element specifies the ratings, sub-ratings and rating
+     * orders of a particular content rating system.
+     * </p>
+     *
+     * @see TvContentRating
+     */
+    public static final String ACTION_QUERY_CONTENT_RATING_SYSTEMS =
+            "android.media.tv.action.QUERY_CONTENT_RATING_SYSTEMS";
+
+    /**
+     * Content rating systems metadata associated with {@link #ACTION_QUERY_CONTENT_RATING_SYSTEMS}.
+     * <p>
+     * Specifies the resource ID of an XML resource that describes the content rating systems that
+     * are provided by the application.
+     * </p>
+     */
+    public static final String META_DATA_CONTENT_RATING_SYSTEMS =
+            "android.media.tv.metadata.CONTENT_RATING_SYSTEMS";
+
     private final ITvInputManager mService;
 
     private final Object mLock = new Object();
 
     // @GuardedBy(mLock)
-    private final List<TvInputListenerRecord> mTvInputListenerRecordsList =
-            new LinkedList<TvInputListenerRecord>();
+    private final List<TvInputCallbackRecord> mCallbackRecords =
+            new LinkedList<TvInputCallbackRecord>();
 
     // A mapping from TV input ID to the state of corresponding input.
     // @GuardedBy(mLock)
@@ -132,7 +177,7 @@
 
     private final ITvInputClient mClient;
 
-    private final ITvInputManagerCallback mCallback;
+    private final ITvInputManagerCallback mManagerCallback;
 
     private final int mUserId;
 
@@ -235,14 +280,14 @@
         }
 
         /**
-         * This is called when {@link TvInputService.Session#layoutSurface} is called to
-         * change the layout of surface.
+         * This is called when {@link TvInputService.Session#layoutSurface} is called to change the
+         * layout of surface.
          *
          * @param session A {@link TvInputManager.Session} associated with this callback
-         * @param l Left position.
-         * @param t Top position.
-         * @param r Right position.
-         * @param b Bottom position.
+         * @param left Left position.
+         * @param top Top position.
+         * @param right Right position.
+         * @param bottom Bottom position.
          * @hide
          */
         @SystemApi
@@ -400,9 +445,9 @@
     }
 
     /**
-     * Interface used to monitor status of the TV input.
+     * Callback used to monitor status of the TV input.
      */
-    public abstract static class TvInputListener {
+    public abstract static class TvInputCallback {
         /**
          * This is called when the state of a given TV input is changed.
          *
@@ -432,26 +477,38 @@
          */
         public void onInputRemoved(String inputId) {
         }
+
+        /**
+         * This is called when a TV input is updated. The update of TV input happens when it is
+         * reinstalled or the media on which the newer version of TV input exists is
+         * available/unavailable.
+         *
+         * @param inputId The id of the TV input.
+         * @hide
+         */
+        @SystemApi
+        public void onInputUpdated(String inputId) {
+        }
     }
 
-    private static final class TvInputListenerRecord {
-        private final TvInputListener mListener;
+    private static final class TvInputCallbackRecord {
+        private final TvInputCallback mCallback;
         private final Handler mHandler;
 
-        public TvInputListenerRecord(TvInputListener listener, Handler handler) {
-            mListener = listener;
+        public TvInputCallbackRecord(TvInputCallback callback, Handler handler) {
+            mCallback = callback;
             mHandler = handler;
         }
 
-        public TvInputListener getListener() {
-            return mListener;
+        public TvInputCallback getCallback() {
+            return mCallback;
         }
 
         public void postInputStateChanged(final String inputId, final int state) {
             mHandler.post(new Runnable() {
                 @Override
                 public void run() {
-                    mListener.onInputStateChanged(inputId, state);
+                    mCallback.onInputStateChanged(inputId, state);
                 }
             });
         }
@@ -460,7 +517,7 @@
             mHandler.post(new Runnable() {
                 @Override
                 public void run() {
-                    mListener.onInputAdded(inputId);
+                    mCallback.onInputAdded(inputId);
                 }
             });
         }
@@ -469,10 +526,29 @@
             mHandler.post(new Runnable() {
                 @Override
                 public void run() {
-                    mListener.onInputRemoved(inputId);
+                    mCallback.onInputRemoved(inputId);
                 }
             });
         }
+
+        public void postInputUpdated(final String inputId) {
+            mHandler.post(new Runnable() {
+                @Override
+                public void run() {
+                    mCallback.onInputUpdated(inputId);
+                }
+            });
+        }
+    }
+
+    /**
+     * Interface used to receive events from Hardware objects.
+     * @hide
+     */
+    @SystemApi
+    public abstract static class HardwareCallback {
+        public abstract void onReleased();
+        public abstract void onStreamConfigChanged(TvStreamConfig[] configs);
     }
 
     /**
@@ -622,12 +698,12 @@
                 }
             }
         };
-        mCallback = new ITvInputManagerCallback.Stub() {
+        mManagerCallback = new ITvInputManagerCallback.Stub() {
             @Override
             public void onInputStateChanged(String inputId, int state) {
                 synchronized (mLock) {
                     mStateMap.put(inputId, state);
-                    for (TvInputListenerRecord record : mTvInputListenerRecordsList) {
+                    for (TvInputCallbackRecord record : mCallbackRecords) {
                         record.postInputStateChanged(inputId, state);
                     }
                 }
@@ -637,7 +713,7 @@
             public void onInputAdded(String inputId) {
                 synchronized (mLock) {
                     mStateMap.put(inputId, INPUT_STATE_CONNECTED);
-                    for (TvInputListenerRecord record : mTvInputListenerRecordsList) {
+                    for (TvInputCallbackRecord record : mCallbackRecords) {
                         record.postInputAdded(inputId);
                     }
                 }
@@ -647,14 +723,25 @@
             public void onInputRemoved(String inputId) {
                 synchronized (mLock) {
                     mStateMap.remove(inputId);
-                    for (TvInputListenerRecord record : mTvInputListenerRecordsList) {
+                    for (TvInputCallbackRecord record : mCallbackRecords) {
                         record.postInputRemoved(inputId);
                     }
                 }
             }
+
+            @Override
+            public void onInputUpdated(String inputId) {
+                synchronized (mLock) {
+                    for (TvInputCallbackRecord record : mCallbackRecords) {
+                        record.postInputUpdated(inputId);
+                    }
+                }
+            }
         };
         try {
-            mService.registerCallback(mCallback, mUserId);
+            if (mService != null) {
+                mService.registerCallback(mManagerCallback, mUserId);
+            }
         } catch (RemoteException e) {
             Log.e(TAG, "mService.registerCallback failed: " + e);
         }
@@ -716,39 +803,39 @@
     }
 
     /**
-     * Registers a {@link TvInputListener}.
+     * Registers a {@link TvInputCallback}.
      *
-     * @param listener A listener used to monitor status of the TV inputs.
+     * @param callback A callback used to monitor status of the TV inputs.
      * @param handler A {@link Handler} that the status change will be delivered to.
      * @throws IllegalArgumentException if any of the arguments is {@code null}.
      */
-    public void registerListener(TvInputListener listener, Handler handler) {
-        if (listener == null) {
+    public void registerCallback(TvInputCallback callback, Handler handler) {
+        if (callback == null) {
             throw new IllegalArgumentException("callback cannot be null");
         }
         if (handler == null) {
             throw new IllegalArgumentException("handler cannot be null");
         }
         synchronized (mLock) {
-            mTvInputListenerRecordsList.add(new TvInputListenerRecord(listener, handler));
+            mCallbackRecords.add(new TvInputCallbackRecord(callback, handler));
         }
     }
 
     /**
-     * Unregisters the existing {@link TvInputListener}.
+     * Unregisters the existing {@link TvInputCallback}.
      *
-     * @param listener The existing listener to remove.
+     * @param callback The existing callback to remove.
      * @throws IllegalArgumentException if any of the arguments is {@code null}.
      */
-    public void unregisterListener(final TvInputListener listener) {
-        if (listener == null) {
+    public void unregisterCallback(final TvInputCallback callback) {
+        if (callback == null) {
             throw new IllegalArgumentException("callback cannot be null");
         }
         synchronized (mLock) {
-            for (Iterator<TvInputListenerRecord> it = mTvInputListenerRecordsList.iterator();
+            for (Iterator<TvInputCallbackRecord> it = mCallbackRecords.iterator();
                     it.hasNext(); ) {
-                TvInputListenerRecord record = it.next();
-                if (record.getListener() == listener) {
+                TvInputCallbackRecord record = it.next();
+                if (record.getCallback() == callback) {
                     it.remove();
                     break;
                 }
@@ -863,13 +950,13 @@
     }
 
     /**
-     * Returns the list of xml resource uris for TV content rating systems.
+     * Returns the list of all TV content rating systems defined.
      * @hide
      */
     @SystemApi
-    public List<Uri> getTvContentRatingSystemXmls() {
+    public List<TvContentRatingSystemInfo> getTvContentRatingSystemList() {
         try {
-            return mService.getTvContentRatingSystemXmls(mUserId);
+            return mService.getTvContentRatingSystemList(mUserId);
         } catch (RemoteException e) {
             throw new RuntimeException(e);
         }
@@ -962,6 +1049,64 @@
     }
 
     /**
+     * Returns a list of TvInputHardwareInfo objects representing available hardware.
+     *
+     * @hide
+     */
+    @SystemApi
+    public List<TvInputHardwareInfo> getHardwareList() {
+        try {
+            return mService.getHardwareList();
+        } catch (RemoteException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    /**
+     * Returns acquired TvInputManager.Hardware object for given deviceId.
+     *
+     * If there are other Hardware object acquired for the same deviceId, calling this method will
+     * preempt the previously acquired object and report {@link HardwareCallback#onReleased} to the
+     * old object.
+     *
+     * @hide
+     */
+    @SystemApi
+    public Hardware acquireTvInputHardware(int deviceId, final HardwareCallback callback,
+            TvInputInfo info) {
+        try {
+            return new Hardware(
+                    mService.acquireTvInputHardware(deviceId, new ITvInputHardwareCallback.Stub() {
+                @Override
+                public void onReleased() {
+                    callback.onReleased();
+                }
+
+                @Override
+                public void onStreamConfigChanged(TvStreamConfig[] configs) {
+                    callback.onStreamConfigChanged(configs);
+                }
+            }, info, mUserId));
+        } catch (RemoteException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    /**
+     * Releases previously acquired hardware object.
+     *
+     * @hide
+     */
+    @SystemApi
+    public void releaseTvInputHardware(int deviceId, Hardware hardware) {
+        try {
+            mService.releaseTvInputHardware(deviceId, hardware.getInterface(), mUserId);
+        } catch (RemoteException e) {
+            throw new RuntimeException(e);
+        }
+    }
+
+    /**
      * The Session provides the per-session functionality of TV inputs.
      * @hide
      */
@@ -1023,10 +1168,12 @@
         }
 
         /**
-         * Sets this as main session. See {@link TvView#setMainTvView} for about meaning of "main".
-         * @hide
+         * Sets this as the main session. The main session is a session whose corresponding TV
+         * input determines the HDMI-CEC active source device.
+         *
+         * @see TvView#setMain
          */
-        public void setMainSession() {
+        void setMain() {
             if (mToken == null) {
                 Log.w(TAG, "The session has been already released");
                 return;
@@ -1164,20 +1311,23 @@
          *            {@link TvTrackInfo#TYPE_SUBTITLE}.
          * @param trackId The ID of the track to select. When {@code null}, the currently selected
          *            track of the given type will be unselected.
-         * @see #getTracks()
+         * @see #getTracks
          */
         public void selectTrack(int type, String trackId) {
             if (type == TvTrackInfo.TYPE_AUDIO) {
-                if (trackId != null && !mAudioTracks.contains(trackId)) {
+                if (trackId != null && !containsTrack(mAudioTracks, trackId)) {
                     Log.w(TAG, "Invalid audio trackId: " + trackId);
+                    return;
                 }
             } else if (type == TvTrackInfo.TYPE_VIDEO) {
-                if (trackId != null && !mVideoTracks.contains(trackId)) {
+                if (trackId != null && !containsTrack(mVideoTracks, trackId)) {
                     Log.w(TAG, "Invalid video trackId: " + trackId);
+                    return;
                 }
             } else if (type == TvTrackInfo.TYPE_SUBTITLE) {
-                if (trackId != null && !mSubtitleTracks.contains(trackId)) {
+                if (trackId != null && !containsTrack(mSubtitleTracks, trackId)) {
                     Log.w(TAG, "Invalid subtitle trackId: " + trackId);
+                    return;
                 }
             } else {
                 throw new IllegalArgumentException("invalid type: " + type);
@@ -1193,6 +1343,15 @@
             }
         }
 
+        private boolean containsTrack(List<TvTrackInfo> tracks, String trackId) {
+            for (TvTrackInfo track : tracks) {
+                if (track.getId().equals(trackId)) {
+                    return true;
+                }
+            }
+            return false;
+        }
+
         /**
          * Returns the list of tracks for a given type. Returns {@code null} if the information is
          * not available.
@@ -1339,6 +1498,9 @@
                 Log.w(TAG, "The session has been already released");
                 return;
             }
+            if (unblockedRating == null) {
+                throw new IllegalArgumentException("unblockedRating cannot be null");
+            }
             try {
                 mService.requestUnblockContent(mToken, unblockedRating.flattenToString(), mUserId);
             } catch (RemoteException e) {
@@ -1462,14 +1624,14 @@
         // Assumes the event has already been removed from the queue.
         void invokeFinishedInputEventCallback(PendingEvent p, boolean handled) {
             p.mHandled = handled;
-            if (p.mHandler.getLooper().isCurrentThread()) {
+            if (p.mEventHandler.getLooper().isCurrentThread()) {
                 // Already running on the callback handler thread so we can send the callback
                 // immediately.
                 p.run();
             } else {
                 // Post the event to the callback handler thread.
                 // In this case, the callback will be responsible for recycling the event.
-                Message msg = Message.obtain(p.mHandler, p);
+                Message msg = Message.obtain(p.mEventHandler, p);
                 msg.setAsynchronous(true);
                 msg.sendToTarget();
             }
@@ -1494,9 +1656,9 @@
                 p = new PendingEvent();
             }
             p.mEvent = event;
-            p.mToken = token;
+            p.mEventToken = token;
             p.mCallback = callback;
-            p.mHandler = handler;
+            p.mEventHandler = handler;
             return p;
         }
 
@@ -1568,27 +1730,83 @@
 
         private final class PendingEvent implements Runnable {
             public InputEvent mEvent;
-            public Object mToken;
+            public Object mEventToken;
             public FinishedInputEventCallback mCallback;
-            public Handler mHandler;
+            public Handler mEventHandler;
             public boolean mHandled;
 
             public void recycle() {
                 mEvent = null;
-                mToken = null;
+                mEventToken = null;
                 mCallback = null;
-                mHandler = null;
+                mEventHandler = null;
                 mHandled = false;
             }
 
             @Override
             public void run() {
-                mCallback.onFinishedInputEvent(mToken, mHandled);
+                mCallback.onFinishedInputEvent(mEventToken, mHandled);
 
-                synchronized (mHandler) {
+                synchronized (mEventHandler) {
                     recyclePendingEventLocked(this);
                 }
             }
         }
     }
+
+    /**
+     * The Hardware provides the per-hardware functionality of TV hardware.
+     *
+     * TV hardware is physical hardware attached to the Android device; for example, HDMI ports,
+     * Component/Composite ports, etc. Specifically, logical devices such as HDMI CEC logical
+     * devices don't fall into this category.
+     *
+     * @hide
+     */
+    @SystemApi
+    public final static class Hardware {
+        private final ITvInputHardware mInterface;
+
+        private Hardware(ITvInputHardware hardwareInterface) {
+            mInterface = hardwareInterface;
+        }
+
+        private ITvInputHardware getInterface() {
+            return mInterface;
+        }
+
+        public boolean setSurface(Surface surface, TvStreamConfig config) {
+            try {
+                return mInterface.setSurface(surface, config);
+            } catch (RemoteException e) {
+                throw new RuntimeException(e);
+            }
+        }
+
+        public void setStreamVolume(float volume) {
+            try {
+                mInterface.setStreamVolume(volume);
+            } catch (RemoteException e) {
+                throw new RuntimeException(e);
+            }
+        }
+
+        public boolean dispatchKeyEventToHdmi(KeyEvent event) {
+            try {
+                return mInterface.dispatchKeyEventToHdmi(event);
+            } catch (RemoteException e) {
+                throw new RuntimeException(e);
+            }
+        }
+
+        public void overrideAudioSink(int audioType, String audioAddress, int samplingRate,
+                int channelMask, int format) {
+            try {
+                mInterface.overrideAudioSink(audioType, audioAddress, samplingRate, channelMask,
+                        format);
+            } catch (RemoteException e) {
+                throw new RuntimeException(e);
+            }
+        }
+    }
 }
diff --git a/media/java/android/media/tv/TvInputService.java b/media/java/android/media/tv/TvInputService.java
index 8ffe6cc..4f8facb 100644
--- a/media/java/android/media/tv/TvInputService.java
+++ b/media/java/android/media/tv/TvInputService.java
@@ -66,8 +66,7 @@
  * </p>
  */
 public abstract class TvInputService extends Service {
-    // STOPSHIP: Turn debugging off.
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
     private static final String TAG = "TvInputService";
 
     /**
@@ -94,6 +93,8 @@
     private final RemoteCallbackList<ITvInputServiceCallback> mCallbacks =
             new RemoteCallbackList<ITvInputServiceCallback>();
 
+    private TvInputManager mTvInputManager;
+
     @Override
     public final IBinder onBind(Intent intent) {
         return new ITvInputService.Stub() {
@@ -225,6 +226,17 @@
         return null;
     }
 
+    private boolean isPassthroughInput(String inputId) {
+        if (mTvInputManager == null) {
+            mTvInputManager = (TvInputManager) getSystemService(Context.TV_INPUT_SERVICE);
+        }
+        TvInputInfo info = mTvInputManager.getTvInputInfo(inputId);
+        if (info != null && info.isPassthroughInput()) {
+            return true;
+        }
+        return false;
+    }
+
     /**
      * Base class for derived classes to implement to provide a TV input session.
      */
@@ -287,7 +299,7 @@
             if (eventType == null) {
                 throw new IllegalArgumentException("eventType should not be null.");
             }
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -306,7 +318,7 @@
          * @param channelUri The URI of a channel.
          */
         public void notifyChannelRetuned(final Uri channelUri) {
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -338,7 +350,7 @@
             trackIdSet.clear();
 
             // TODO: Validate the track list.
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -362,7 +374,7 @@
          * @see #onSelectTrack
          */
         public void notifyTrackSelected(final int type, final String trackId) {
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -376,11 +388,14 @@
         }
 
         /**
-         * Informs the application that video is available and the playback of the TV stream has
-         * been started.
+         * Informs the application that the video is now available for watching. This is primarily
+         * used to signal the application to unblock the screen. The TV input service must call this
+         * method as soon as the content rendered onto its surface gets ready for viewing.
+         *
+         * @see #notifyVideoUnavailable
          */
         public void notifyVideoAvailable() {
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -394,23 +409,25 @@
         }
 
         /**
-         * Informs the application that video is not available, so the TV input cannot continue
-         * playing the TV stream.
+         * Informs the application that the video became unavailable for some reason. This is
+         * primarily used to signal the application to block the screen not to show any intermittent
+         * video artifacts.
          *
-         * @param reason The reason that the TV input stopped the playback:
-         * <ul>
-         * <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_UNKNOWN}
-         * <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_TUNING}
-         * <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_WEAK_SIGNAL}
-         * <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_BUFFERING}
-         * </ul>
+         * @param reason The reason why the video became unavailable:
+         *            <ul>
+         *            <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_UNKNOWN}
+         *            <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_TUNING}
+         *            <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_WEAK_SIGNAL}
+         *            <li>{@link TvInputManager#VIDEO_UNAVAILABLE_REASON_BUFFERING}
+         *            </ul>
+         * @see #notifyVideoAvailable
          */
         public void notifyVideoUnavailable(final int reason) {
             if (reason < TvInputManager.VIDEO_UNAVAILABLE_REASON_START
                     || reason > TvInputManager.VIDEO_UNAVAILABLE_REASON_END) {
                 throw new IllegalArgumentException("Unknown reason: " + reason);
             }
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -449,7 +466,7 @@
          * @see TvInputManager
          */
         public void notifyContentAllowed() {
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -489,7 +506,7 @@
          * @see TvInputManager
          */
         public void notifyContentBlocked(final TvContentRating rating) {
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -504,12 +521,13 @@
 
         /**
          * Assigns a position of the {@link Surface} passed by {@link #onSetSurface}. The position
-         * is relative to an overlay view. {@see #onOverlayViewSizeChanged}.
+         * is relative to an overlay view.
          *
          * @param left Left position in pixels, relative to the overlay view.
          * @param top Top position in pixels, relative to the overlay view.
          * @param right Right position in pixels, relative to the overlay view.
          * @param bottm Bottom position in pixels, relative to the overlay view.
+         * @see #onOverlayViewSizeChanged
          * @hide
          */
         @SystemApi
@@ -517,7 +535,7 @@
             if (left > right || top > bottm) {
                 throw new IllegalArgumentException("Invalid parameter");
             }
-            mHandler.post(new Runnable() {
+            runOnMainThread(new Runnable() {
                 @Override
                 public void run() {
                     try {
@@ -537,29 +555,30 @@
         public abstract void onRelease();
 
         /**
-         * Set the current session as the "main" session. See {@link TvView#setMainTvView} for the
-         * meaning of "main".
+         * Sets the current session as the main session. The main session is a session whose
+         * corresponding TV input determines the HDMI-CEC active source device.
          * <p>
-         * This is primarily for HDMI-CEC active source management. TV input service that manages
-         * HDMI-CEC logical device should make sure not only to select the corresponding HDMI
-         * logical device as source device on {@code onSetMainSession(true)}, but also to select
-         * internal device on {@code onSetMainSession(false)}. Also, if surface is set to non-main
-         * session, it needs to select internal device after temporarily selecting corresponding
-         * HDMI logical device for set up.
+         * TV input service that manages HDMI-CEC logical device should implement {@link
+         * #onSetMain} to (1) select the corresponding HDMI logical device as the source device
+         * when {@code isMain} is {@code true}, and to (2) select the internal device (= TV itself)
+         * as the source device when {@code isMain} is {@code false} and the session is still main.
+         * Also, if a surface is passed to a non-main session and active source is changed to
+         * initiate the surface, the active source should be returned to the main session.
          * </p><p>
-         * It is guaranteed that {@code onSetMainSession(true)} for new session is called first,
-         * and {@code onSetMainSession(false)} for old session is called afterwards. This allows
-         * {@code onSetMainSession(false)} to be no-op when TV input service knows that the next
-         * main session corresponds to another HDMI logical device. Practically, this implies that
-         * one TV input service should handle all HDMI port and HDMI-CEC logical devices for smooth
-         * active source transition.
+         * {@link TvView} guarantees that, when tuning involves a session transition, {@code
+         * onSetMain(true)} for new session is called first, {@code onSetMain(false)} for old
+         * session is called afterwards. This allows {@code onSetMain(false)} to be no-op when TV
+         * input service knows that the next main session corresponds to another HDMI logical
+         * device. Practically, this implies that one TV input service should handle all HDMI port
+         * and HDMI-CEC logical devices for smooth active source transition.
          * </p>
          *
-         * @param isMainSession If true, session is main.
+         * @param isMain If true, session should become main.
+         * @see TvView#setMain
          * @hide
          */
         @SystemApi
-        public void onSetMainSession(boolean isMainSession) {
+        public void onSetMain(boolean isMain) {
         }
 
         /**
@@ -827,10 +846,10 @@
         }
 
         /**
-         * Calls {@link #onSetMainSession}.
+         * Calls {@link #onSetMain}.
          */
-        void setMainSession(boolean isMainSession) {
-            onSetMainSession(isMainSession);
+        void setMain(boolean isMain) {
+            onSetMain(isMain);
         }
 
         /**
@@ -1034,6 +1053,16 @@
         private void setSessionCallback(ITvInputSessionCallback callback) {
             mSessionCallback = callback;
         }
+
+        private final void runOnMainThread(Runnable action) {
+            if (mHandler.getLooper().isCurrentThread() && mSessionCallback != null) {
+                action.run();
+            } else {
+                // Posts the runnable if this is not called from the main thread or the session
+                // is not initialized yet.
+                mHandler.post(action);
+            }
+        }
     }
 
     /**
@@ -1228,9 +1257,14 @@
                         HardwareSession proxySession =
                                 ((HardwareSession) sessionImpl);
                         String harewareInputId = proxySession.getHardwareInputId();
-                        if (TextUtils.isEmpty(harewareInputId)) {
+                        if (TextUtils.isEmpty(harewareInputId) ||
+                                !isPassthroughInput(harewareInputId)) {
+                            if (TextUtils.isEmpty(harewareInputId)) {
+                                Log.w(TAG, "Hardware input id is not setup yet.");
+                            } else {
+                                Log.w(TAG, "Invalid hardware input id : " + harewareInputId);
+                            }
                             sessionImpl.onRelease();
-                            Log.w(TAG, "Hardware input id is not setup yet.");
                             try {
                                 cb.onSessionCreated(null, null);
                             } catch (RemoteException e) {
@@ -1238,7 +1272,6 @@
                             }
                             return;
                         }
-                        // TODO: check if the given ID is really hardware TV input.
                         proxySession.mProxySession = stub;
                         proxySession.mProxySessionCallback = cb;
                         proxySession.mServiceHandler = mServiceHandler;
diff --git a/media/java/android/media/tv/TvTrackInfo.java b/media/java/android/media/tv/TvTrackInfo.java
index 6ddb2a2..e0aacd6 100644
--- a/media/java/android/media/tv/TvTrackInfo.java
+++ b/media/java/android/media/tv/TvTrackInfo.java
@@ -46,10 +46,12 @@
     private final int mAudioSampleRate;
     private final int mVideoWidth;
     private final int mVideoHeight;
+    private final float mVideoFrameRate;
     private final Bundle mExtra;
 
     private TvTrackInfo(int type, String id, String language, int audioChannelCount,
-            int audioSampleRate, int videoWidth, int videoHeight, Bundle extra) {
+            int audioSampleRate, int videoWidth, int videoHeight, float videoFrameRate,
+            Bundle extra) {
         mType = type;
         mId = id;
         mLanguage = language;
@@ -57,6 +59,7 @@
         mAudioSampleRate = audioSampleRate;
         mVideoWidth = videoWidth;
         mVideoHeight = videoHeight;
+        mVideoFrameRate = videoFrameRate;
         mExtra = extra;
     }
 
@@ -68,6 +71,7 @@
         mAudioSampleRate = in.readInt();
         mVideoWidth = in.readInt();
         mVideoHeight = in.readInt();
+        mVideoFrameRate = in.readFloat();
         mExtra = in.readBundle();
     }
 
@@ -137,6 +141,17 @@
     }
 
     /**
+     * Returns the frame rate of the video, in the unit of fps (frames per second). Valid only for
+     * {@link #TYPE_VIDEO} tracks.
+     */
+    public final float getVideoFrameRate() {
+        if (mType != TYPE_VIDEO) {
+            throw new IllegalStateException("Not a video track");
+        }
+        return mVideoFrameRate;
+    }
+
+    /**
      * Returns the extra information about the current track.
      */
     public final Bundle getExtra() {
@@ -163,6 +178,7 @@
         dest.writeInt(mAudioSampleRate);
         dest.writeInt(mVideoWidth);
         dest.writeInt(mVideoHeight);
+        dest.writeFloat(mVideoFrameRate);
         dest.writeBundle(mExtra);
     }
 
@@ -190,6 +206,7 @@
         private int mAudioSampleRate;
         private int mVideoWidth;
         private int mVideoHeight;
+        private float mVideoFrameRate;
         private Bundle mExtra;
 
         /**
@@ -279,6 +296,20 @@
         }
 
         /**
+         * Sets the frame rate of the video, in the unit fps (frames per rate). Valid only for
+         * {@link #TYPE_VIDEO} tracks.
+         *
+         * @param videoFrameRate The frame rate of the video.
+         */
+        public final Builder setVideoFrameRate(float videoFrameRate) {
+            if (mType != TYPE_VIDEO) {
+                throw new IllegalStateException("Not a video track");
+            }
+            mVideoFrameRate = videoFrameRate;
+            return this;
+        }
+
+        /**
          * Sets the extra information about the current track.
          *
          * @param extra The extra information.
@@ -295,7 +326,7 @@
          */
         public TvTrackInfo build() {
             return new TvTrackInfo(mType, mId, mLanguage, mAudioChannelCount, mAudioSampleRate,
-                    mVideoWidth, mVideoHeight, mExtra);
+                    mVideoWidth, mVideoHeight, mVideoFrameRate, mExtra);
         }
     }
 }
\ No newline at end of file
diff --git a/media/java/android/media/tv/TvView.java b/media/java/android/media/tv/TvView.java
index 591f543..0949b1a 100644
--- a/media/java/android/media/tv/TvView.java
+++ b/media/java/android/media/tv/TvView.java
@@ -38,6 +38,7 @@
 import android.view.ViewGroup;
 import android.view.ViewRootImpl;
 
+import java.lang.ref.WeakReference;
 import java.util.List;
 
 /**
@@ -56,21 +57,7 @@
  */
 public class TvView extends ViewGroup {
     private static final String TAG = "TvView";
-    // STOPSHIP: Turn debugging off.
-    private static final boolean DEBUG = true;
-
-    /**
-     * Passed with {@link TvInputListener#onError(String, int)}. Indicates that the connection to
-     * the requested TV input was not established thus the view is unable to handle the further
-     * operations.
-     */
-    public static final int ERROR_INPUT_NOT_CONNECTED = 0;
-
-    /**
-     * Passed with {@link TvInputListener#onError(String, int)}. Indicates that the underlying TV
-     * input has been disconnected.
-     */
-    public static final int ERROR_INPUT_DISCONNECTED = 1;
+    private static final boolean DEBUG = false;
 
     private static final int VIDEO_SIZE_VALUE_UNKNOWN = 0;
 
@@ -82,8 +69,10 @@
     private static final int CAPTION_ENABLED = 1;
     private static final int CAPTION_DISABLED = 2;
 
+    private static final WeakReference<TvView> NULL_TV_VIEW = new WeakReference(null);
+
     private static final Object sMainTvViewLock = new Object();
-    private static TvView sMainTvView;
+    private static WeakReference<TvView> sMainTvView = NULL_TV_VIEW;
 
     private final Handler mHandler = new Handler();
     private Session mSession;
@@ -93,7 +82,7 @@
     private Rect mOverlayViewFrame;
     private final TvInputManager mTvInputManager;
     private MySessionCallback mSessionCallback;
-    private TvInputListener mListener;
+    private TvInputCallback mCallback;
     private OnUnhandledInputEventListener mOnUnhandledInputEventListener;
     private boolean mHasStreamVolume;
     private float mStreamVolume;
@@ -116,8 +105,10 @@
     private final SurfaceHolder.Callback mSurfaceHolderCallback = new SurfaceHolder.Callback() {
         @Override
         public void surfaceChanged(SurfaceHolder holder, int format, int width, int height) {
-            Log.d(TAG, "surfaceChanged(holder=" + holder + ", format=" + format + ", width=" + width
-                    + ", height=" + height + ")");
+            if (DEBUG) {
+                Log.d(TAG, "surfaceChanged(holder=" + holder + ", format=" + format + ", width="
+                    + width + ", height=" + height + ")");
+            }
             mSurfaceFormat = format;
             mSurfaceWidth = width;
             mSurfaceHeight = height;
@@ -178,34 +169,37 @@
     }
 
     /**
-     * Sets a listener for events in this TvView.
+     * Sets the callback to be invoked when an event is dispatched to this TvView.
      *
-     * @param listener The listener to be called with events. A value of {@code null} removes any
-     *         existing listener.
+     * @param callback The callback to receive events. A value of {@code null} removes any existing
+     *            callbacks.
      */
-    public void setTvInputListener(TvInputListener listener) {
-        mListener = listener;
+    public void setCallback(TvInputCallback callback) {
+        mCallback = callback;
     }
 
     /**
-     * Sets this as main TvView.
+     * Sets this as the main {@link TvView}.
      * <p>
-     * Main TvView is the TvView which user is watching and interacting mainly.  It is used for
-     * determining internal behavior of hardware TV input devices. For example, this influences
-     * how HDMI-CEC active source will be managed.
+     * The main {@link TvView} is a {@link TvView} whose corresponding TV input determines the
+     * HDMI-CEC active source device. For an HDMI port input, one of source devices that is
+     * connected to that HDMI port becomes the active source. For an HDMI-CEC logical device input,
+     * the corresponding HDMI-CEC logical device becomes the active source. For any non-HDMI input
+     * (including the tuner, composite, S-Video, etc.), the internal device (= TV itself) becomes
+     * the active source.
      * </p><p>
-     * First tuned TvView becomes main automatically, and keeps to be main until setMainTvView() is
-     * called for other TvView. Note that main TvView won't be reset even when current main TvView
-     * is removed from view hierarchy.
+     * First tuned {@link TvView} becomes main automatically, and keeps to be main until either
+     * {@link #reset} is called for the main {@link TvView} or {@link #setMain} is called for other
+     * {@link TvView}.
      * </p>
      * @hide
      */
     @SystemApi
-    public void setMainTvView() {
+    public void setMain() {
         synchronized (sMainTvViewLock) {
-            sMainTvView = this;
+            sMainTvView = new WeakReference(this);
             if (hasWindowFocus() && mSession != null) {
-                mSession.setMainSession();
+                mSession.setMain();
             }
         }
     }
@@ -296,8 +290,8 @@
             throw new IllegalArgumentException("inputId cannot be null or an empty string");
         }
         synchronized (sMainTvViewLock) {
-            if (sMainTvView == null) {
-                sMainTvView = this;
+            if (sMainTvView.get() == null) {
+                sMainTvView = new WeakReference(this);
             }
         }
         if (mSessionCallback != null && mSessionCallback.mInputId.equals(inputId)) {
@@ -310,14 +304,16 @@
                 mSessionCallback.mTuneParams = params;
             }
         } else {
-            reset();
+            resetInternal();
             // When createSession() is called multiple times before the callback is called,
             // only the callback of the last createSession() call will be actually called back.
             // The previous callbacks will be ignored. For the logic, mSessionCallback
             // is newly assigned for every createSession request and compared with
             // MySessionCreateCallback.this.
             mSessionCallback = new MySessionCallback(inputId, channelUri, params);
-            mTvInputManager.createSession(inputId, mSessionCallback, mHandler);
+            if (mTvInputManager != null) {
+                mTvInputManager.createSession(inputId, mSessionCallback, mHandler);
+            }
         }
     }
 
@@ -327,6 +323,16 @@
      * This method is primarily used to un-tune the current TvView.
      */
     public void reset() {
+        if (DEBUG) Log.d(TAG, "reset()");
+        synchronized (sMainTvViewLock) {
+            if (this == sMainTvView.get()) {
+                sMainTvView = NULL_TV_VIEW;
+            }
+        }
+        resetInternal();
+    }
+
+    private void resetInternal() {
         if (mSession != null) {
             release();
             resetSurfaceView();
@@ -537,8 +543,8 @@
         // Other app may have shown its own main TvView.
         // Set main again to regain main session.
         synchronized (sMainTvViewLock) {
-            if (hasFocus && this == sMainTvView && mSession != null) {
-                mSession.setMainSession();
+            if (hasFocus && this == sMainTvView.get() && mSession != null) {
+                mSession.setMain();
             }
         }
     }
@@ -596,6 +602,7 @@
             mSurfaceView.getHolder().removeCallback(mSurfaceHolderCallback);
             removeView(mSurfaceView);
         }
+        mSurface = null;
         mSurfaceView = new SurfaceView(getContext(), mAttrs, mDefStyleAttr) {
             @Override
             protected void updateWindow(boolean force, boolean redrawNeeded) {
@@ -674,18 +681,25 @@
     }
 
     /**
-     * Interface used to receive various status updates on the {@link TvView}.
+     * Callback used to receive various status updates on the {@link TvView}.
      */
-    public abstract static class TvInputListener {
+    public abstract static class TvInputCallback {
 
         /**
-         * This is invoked when an error occurred while handling requested operation.
+         * This is invoked when an error occurred while establishing a connection to the underlying
+         * TV input.
          *
          * @param inputId The ID of the TV input bound to this view.
-         * @param errorCode The error code. For the details of error code, please see
-         *         {@link TvView}.
          */
-        public void onError(String inputId, int errorCode) {
+        public void onConnectionFailed(String inputId) {
+        }
+
+        /**
+         * This is invoked when the existing connection to the underlying TV input is lost.
+         *
+         * @param inputId The ID of the TV input bound to this view.
+         */
+        public void onDisconnected(String inputId) {
         }
 
         /**
@@ -821,11 +835,14 @@
                 }
                 return;
             }
+            if (DEBUG) {
+                Log.d(TAG, "onSessionCreated()");
+            }
             mSession = session;
             if (session != null) {
                 synchronized (sMainTvViewLock) {
-                    if (hasWindowFocus() && TvView.this == sMainTvView) {
-                        mSession.setMainSession();
+                    if (hasWindowFocus() && TvView.this == sMainTvView.get()) {
+                        mSession.setMain();
                     }
                 }
                 // mSurface may not be ready yet as soon as starting an application.
@@ -846,8 +863,9 @@
                     mSession.setStreamVolume(mStreamVolume);
                 }
             } else {
-                if (mListener != null) {
-                    mListener.onError(mInputId, ERROR_INPUT_NOT_CONNECTED);
+                mSessionCallback = null;
+                if (mCallback != null) {
+                    mCallback.onConnectionFailed(mInputId);
                 }
             }
         }
@@ -857,10 +875,12 @@
             if (this != mSessionCallback) {
                 return;
             }
+            mOverlayViewCreated = false;
+            mOverlayViewFrame = null;
             mSessionCallback = null;
             mSession = null;
-            if (mListener != null) {
-                mListener.onError(mInputId, ERROR_INPUT_DISCONNECTED);
+            if (mCallback != null) {
+                mCallback.onDisconnected(mInputId);
             }
         }
 
@@ -872,8 +892,8 @@
             if (DEBUG) {
                 Log.d(TAG, "onChannelChangedByTvInput(" + channelUri + ")");
             }
-            if (mListener != null) {
-                mListener.onChannelRetuned(mInputId, channelUri);
+            if (mCallback != null) {
+                mCallback.onChannelRetuned(mInputId, channelUri);
             }
         }
 
@@ -885,8 +905,8 @@
             if (DEBUG) {
                 Log.d(TAG, "onTracksChanged()");
             }
-            if (mListener != null) {
-                mListener.onTracksChanged(mInputId, tracks);
+            if (mCallback != null) {
+                mCallback.onTracksChanged(mInputId, tracks);
             }
         }
 
@@ -899,8 +919,8 @@
                 Log.d(TAG, "onTrackSelected()");
             }
             // TODO: Update the video size when the type is TYPE_VIDEO.
-            if (mListener != null) {
-                mListener.onTrackSelected(mInputId, type, trackId);
+            if (mCallback != null) {
+                mCallback.onTrackSelected(mInputId, type, trackId);
             }
         }
 
@@ -912,8 +932,8 @@
             if (DEBUG) {
                 Log.d(TAG, "onVideoAvailable()");
             }
-            if (mListener != null) {
-                mListener.onVideoAvailable(mInputId);
+            if (mCallback != null) {
+                mCallback.onVideoAvailable(mInputId);
             }
         }
 
@@ -925,8 +945,8 @@
             if (DEBUG) {
                 Log.d(TAG, "onVideoUnavailable(" + reason + ")");
             }
-            if (mListener != null) {
-                mListener.onVideoUnavailable(mInputId, reason);
+            if (mCallback != null) {
+                mCallback.onVideoUnavailable(mInputId, reason);
             }
         }
 
@@ -938,23 +958,29 @@
             if (DEBUG) {
                 Log.d(TAG, "onContentAllowed()");
             }
-            if (mListener != null) {
-                mListener.onContentAllowed(mInputId);
+            if (mCallback != null) {
+                mCallback.onContentAllowed(mInputId);
             }
         }
 
         @Override
         public void onContentBlocked(Session session, TvContentRating rating) {
+            if (this != mSessionCallback) {
+                return;
+            }
             if (DEBUG) {
                 Log.d(TAG, "onContentBlocked()");
             }
-            if (mListener != null) {
-                mListener.onContentBlocked(mInputId, rating);
+            if (mCallback != null) {
+                mCallback.onContentBlocked(mInputId, rating);
             }
         }
 
         @Override
         public void onLayoutSurface(Session session, int left, int top, int right, int bottom) {
+            if (this != mSessionCallback) {
+                return;
+            }
             if (DEBUG) {
                 Log.d(TAG, "onLayoutSurface (left=" + left + ", top=" + top + ", right="
                         + right + ", bottom=" + bottom + ",)");
@@ -975,8 +1001,8 @@
             if (DEBUG) {
                 Log.d(TAG, "onSessionEvent(" + eventType + ")");
             }
-            if (mListener != null) {
-                mListener.onEvent(mInputId, eventType, eventArgs);
+            if (mCallback != null) {
+                mCallback.onEvent(mInputId, eventType, eventArgs);
             }
         }
     }
diff --git a/media/java/android/service/media/IMediaBrowserService.aidl b/media/java/android/service/media/IMediaBrowserService.aidl
new file mode 100644
index 0000000..01285ee
--- /dev/null
+++ b/media/java/android/service/media/IMediaBrowserService.aidl
@@ -0,0 +1,21 @@
+// Copyright 2014 Google Inc. All Rights Reserved.
+
+package android.service.media;
+
+import android.content.res.Configuration;
+import android.service.media.IMediaBrowserServiceCallbacks;
+import android.net.Uri;
+import android.os.Bundle;
+
+/**
+ * Media API allows clients to browse through hierarchy of a user’s media collection,
+ * playback a specific media entry and interact with the now playing queue.
+ * @hide
+ */
+oneway interface IMediaBrowserService {
+    void connect(String pkg, in Bundle rootHints, IMediaBrowserServiceCallbacks callbacks);
+    void disconnect(IMediaBrowserServiceCallbacks callbacks);
+
+    void addSubscription(String uri, IMediaBrowserServiceCallbacks callbacks);
+    void removeSubscription(String uri, IMediaBrowserServiceCallbacks callbacks);
+}
\ No newline at end of file
diff --git a/media/java/android/service/media/IMediaBrowserServiceCallbacks.aidl b/media/java/android/service/media/IMediaBrowserServiceCallbacks.aidl
new file mode 100644
index 0000000..2a37ada
--- /dev/null
+++ b/media/java/android/service/media/IMediaBrowserServiceCallbacks.aidl
@@ -0,0 +1,26 @@
+// Copyright 2014 Google Inc. All Rights Reserved.
+
+package android.service.media;
+
+import android.content.pm.ParceledListSlice;
+import android.graphics.Bitmap;
+import android.media.session.MediaSession;
+import android.os.Bundle;
+
+/**
+ * Media API allows clients to browse through hierarchy of a user’s media collection,
+ * playback a specific media entry and interact with the now playing queue.
+ * @hide
+ */
+oneway interface IMediaBrowserServiceCallbacks {
+    /**
+     * Invoked when the connected has been established.
+     * @param root The root media id for browsing.
+     * @param session The {@link MediaSession.Token media session token} that can be used to control
+     *         the playback of the media app.
+     * @param extra Extras returned by the media service.
+     */
+    void onConnect(String root, in MediaSession.Token session, in Bundle extras);
+    void onConnectFailed();
+    void onLoadChildren(String mediaId, in ParceledListSlice list);
+}
diff --git a/media/java/android/service/media/MediaBrowserService.java b/media/java/android/service/media/MediaBrowserService.java
new file mode 100644
index 0000000..d50be42
--- /dev/null
+++ b/media/java/android/service/media/MediaBrowserService.java
@@ -0,0 +1,476 @@
+/*
+ * Copyright (C) 2014 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 android.service.media;
+
+import android.annotation.IntDef;
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.annotation.SdkConstant;
+import android.annotation.SdkConstant.SdkConstantType;
+import android.app.Service;
+import android.content.Intent;
+import android.content.pm.PackageManager;
+import android.content.pm.ParceledListSlice;
+import android.media.browse.MediaBrowser;
+import android.media.session.MediaSession;
+import android.os.Binder;
+import android.os.Bundle;
+import android.os.IBinder;
+import android.os.Handler;
+import android.os.RemoteException;
+import android.service.media.IMediaBrowserService;
+import android.service.media.IMediaBrowserServiceCallbacks;
+import android.util.ArrayMap;
+import android.util.Log;
+
+import java.io.FileDescriptor;
+import java.io.PrintWriter;
+import java.util.HashSet;
+import java.util.List;
+
+/**
+ * Base class for media browse services.
+ * <p>
+ * Media browse services enable applications to browse media content provided by an application
+ * and ask the application to start playing it.  They may also be used to control content that
+ * is already playing by way of a {@link MediaSession}.
+ * </p>
+ *
+ * To extend this class, you must declare the service in your manifest file with
+ * an intent filter with the {@link #SERVICE_INTERFACE} action.
+ *
+ * For example:
+ * </p><pre>
+ * &lt;service android:name=".MyMediaBrowserService"
+ *          android:label="&#64;string/service_name" >
+ *     &lt;intent-filter>
+ *         &lt;action android:name="android.media.browse.MediaBrowserService" />
+ *     &lt;/intent-filter>
+ * &lt;/service>
+ * </pre>
+ *
+ */
+public abstract class MediaBrowserService extends Service {
+    private static final String TAG = "MediaBrowserService";
+    private static final boolean DBG = false;
+
+    /**
+     * The {@link Intent} that must be declared as handled by the service.
+     */
+    @SdkConstant(SdkConstantType.SERVICE_ACTION)
+    public static final String SERVICE_INTERFACE = "android.media.browse.MediaBrowserService";
+
+    private final ArrayMap<IBinder, ConnectionRecord> mConnections = new ArrayMap();
+    private final Handler mHandler = new Handler();
+    private ServiceBinder mBinder;
+    MediaSession.Token mSession;
+
+    /**
+     * All the info about a connection.
+     */
+    private class ConnectionRecord {
+        String pkg;
+        Bundle rootHints;
+        IMediaBrowserServiceCallbacks callbacks;
+        BrowserRoot root;
+        HashSet<String> subscriptions = new HashSet();
+    }
+
+    /**
+     * Completion handler for asynchronous callback methods in {@link MediaBrowserService}.
+     * <p>
+     * Each of the methods that takes one of these to send the result must call
+     * {@link #sendResult} to respond to the caller with the given results.  If those
+     * functions return without calling {@link #sendResult}, they must instead call
+     * {@link #detach} before returning, and then may call {@link #sendResult} when
+     * they are done.  If more than one of those methods is called, an exception will
+     * be thrown.
+     *
+     * @see MediaBrowserService#onLoadChildren
+     * @see MediaBrowserService#onLoadIcon
+     */
+    public class Result<T> {
+        private Object mDebug;
+        private boolean mDetachCalled;
+        private boolean mSendResultCalled;
+
+        Result(Object debug) {
+            mDebug = debug;
+        }
+
+        /**
+         * Send the result back to the caller.
+         */
+        public void sendResult(T result) {
+            if (mSendResultCalled) {
+                throw new IllegalStateException("sendResult() called twice for: " + mDebug);
+            }
+            mSendResultCalled = true;
+            onResultSent(result);
+        }
+
+        /**
+         * Detach this message from the current thread and allow the {@link #sendResult}
+         * call to happen later.
+         */
+        public void detach() {
+            if (mDetachCalled) {
+                throw new IllegalStateException("detach() called when detach() had already"
+                        + " been called for: " + mDebug);
+            }
+            if (mSendResultCalled) {
+                throw new IllegalStateException("detach() called when sendResult() had already"
+                        + " been called for: " + mDebug);
+            }
+            mDetachCalled = true;
+        }
+
+        boolean isDone() {
+            return mDetachCalled || mSendResultCalled;
+        }
+
+        /**
+         * Called when the result is sent, after assertions about not being called twice
+         * have happened.
+         */
+        void onResultSent(T result) {
+        }
+    }
+
+    private class ServiceBinder extends IMediaBrowserService.Stub {
+        @Override
+        public void connect(final String pkg, final Bundle rootHints,
+                final IMediaBrowserServiceCallbacks callbacks) {
+
+            final int uid = Binder.getCallingUid();
+            if (!isValidPackage(pkg, uid)) {
+                throw new IllegalArgumentException("Package/uid mismatch: uid=" + uid
+                        + " package=" + pkg);
+            }
+
+            mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        final IBinder b = callbacks.asBinder();
+
+                        // Clear out the old subscriptions.  We are getting new ones.
+                        mConnections.remove(b);
+
+                        final ConnectionRecord connection = new ConnectionRecord();
+                        connection.pkg = pkg;
+                        connection.rootHints = rootHints;
+                        connection.callbacks = callbacks;
+
+                        connection.root = MediaBrowserService.this.onGetRoot(pkg, uid, rootHints);
+
+                        // If they didn't return something, don't allow this client.
+                        if (connection.root == null) {
+                            Log.i(TAG, "No root for client " + pkg + " from service "
+                                    + getClass().getName());
+                            try {
+                                callbacks.onConnectFailed();
+                            } catch (RemoteException ex) {
+                                Log.w(TAG, "Calling onConnectFailed() failed. Ignoring. "
+                                        + "pkg=" + pkg);
+                            }
+                        } else {
+                            try {
+                                mConnections.put(b, connection);
+                                callbacks.onConnect(connection.root.getRootId(),
+                                        mSession, connection.root.getExtras());
+                            } catch (RemoteException ex) {
+                                Log.w(TAG, "Calling onConnect() failed. Dropping client. "
+                                        + "pkg=" + pkg);
+                                mConnections.remove(b);
+                            }
+                        }
+                    }
+                });
+        }
+
+        @Override
+        public void disconnect(final IMediaBrowserServiceCallbacks callbacks) {
+            mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        final IBinder b = callbacks.asBinder();
+
+                        // Clear out the old subscriptions.  We are getting new ones.
+                        final ConnectionRecord old = mConnections.remove(b);
+                        if (old != null) {
+                            // TODO
+                        }
+                    }
+                });
+        }
+
+
+        @Override
+        public void addSubscription(final String id, final IMediaBrowserServiceCallbacks callbacks) {
+            mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        final IBinder b = callbacks.asBinder();
+
+                        // Get the record for the connection
+                        final ConnectionRecord connection = mConnections.get(b);
+                        if (connection == null) {
+                            Log.w(TAG, "addSubscription for callback that isn't registered id="
+                                + id);
+                            return;
+                        }
+
+                        MediaBrowserService.this.addSubscription(id, connection);
+                    }
+                });
+        }
+
+        @Override
+        public void removeSubscription(final String id,
+                final IMediaBrowserServiceCallbacks callbacks) {
+            mHandler.post(new Runnable() {
+                @Override
+                public void run() {
+                    final IBinder b = callbacks.asBinder();
+
+                    ConnectionRecord connection = mConnections.get(b);
+                    if (connection == null) {
+                        Log.w(TAG, "removeSubscription for callback that isn't registered id="
+                                + id);
+                        return;
+                    }
+                    if (!connection.subscriptions.remove(id)) {
+                        Log.w(TAG, "removeSubscription called for " + id
+                                + " which is not subscribed");
+                    }
+                }
+            });
+        }
+    }
+
+    @Override
+    public void onCreate() {
+        super.onCreate();
+        mBinder = new ServiceBinder();
+    }
+
+    @Override
+    public IBinder onBind(Intent intent) {
+        if (SERVICE_INTERFACE.equals(intent.getAction())) {
+            return mBinder;
+        }
+        return null;
+    }
+
+    @Override
+    public void dump(FileDescriptor fd, PrintWriter writer, String[] args) {
+    }
+
+    /**
+     * Called to get the root information for browsing by a particular client.
+     * <p>
+     * The implementation should verify that the client package has
+     * permission to access browse media information before returning
+     * the root id; it should return null if the client is not
+     * allowed to access this information.
+     * </p>
+     *
+     * @param clientPackageName The package name of the application
+     * which is requesting access to browse media.
+     * @param clientUid The uid of the application which is requesting
+     * access to browse media.
+     * @param rootHints An optional bundle of service-specific arguments to send
+     * to the media browse service when connecting and retrieving the root id
+     * for browsing, or null if none.  The contents of this bundle may affect
+     * the information returned when browsing.
+     */
+    public abstract @Nullable BrowserRoot onGetRoot(@NonNull String clientPackageName,
+            int clientUid, @Nullable Bundle rootHints);
+
+    /**
+     * Called to get information about the children of a media item.
+     * <p>
+     * Implementations must call result.{@link Result#sendResult result.sendResult} with the list
+     * of children. If loading the children will be an expensive operation that should be performed
+     * on another thread, result.{@link Result#detach result.detach} may be called before returning
+     * from this function, and then {@link Result#sendResult result.sendResult} called when
+     * the loading is complete.
+     *
+     * @param parentId The id of the parent media item whose
+     * children are to be queried.
+     * @return The list of children, or null if the id is invalid.
+     */
+    public abstract void onLoadChildren(@NonNull String parentId,
+            @NonNull Result<List<MediaBrowser.MediaItem>> result);
+
+    /**
+     * Call to set the media session.
+     * <p>
+     * This must be called before onCreate returns.
+     *
+     * @return The media session token, must not be null.
+     */
+    public void setSessionToken(MediaSession.Token token) {
+        if (token == null) {
+            throw new IllegalStateException(this.getClass().getName()
+                    + ".onCreateSession() set invalid MediaSession.Token");
+        }
+        mSession = token;
+    }
+
+    /**
+     * Gets the session token, or null if it has not yet been created
+     * or if it has been destroyed.
+     */
+    public @Nullable MediaSession.Token getSessionToken() {
+        return mSession;
+    }
+
+    /**
+     * Notifies all connected media browsers that the children of
+     * the specified parent id have changed in some way.
+     * This will cause browsers to fetch subscribed content again.
+     *
+     * @param parentId The id of the parent media item whose
+     * children changed.
+     */
+    public void notifyChildrenChanged(@NonNull final String parentId) {
+        if (parentId == null) {
+            throw new IllegalArgumentException("parentId cannot be null in notifyChildrenChanged");
+        }
+        mHandler.post(new Runnable() {
+            @Override
+            public void run() {
+                for (IBinder binder : mConnections.keySet()) {
+                    ConnectionRecord connection = mConnections.get(binder);
+                    if (connection.subscriptions.contains(parentId)) {
+                        performLoadChildren(parentId, connection);
+                    }
+                }
+            }
+        });
+    }
+
+    /**
+     * Return whether the given package is one of the ones that is owned by the uid.
+     */
+    private boolean isValidPackage(String pkg, int uid) {
+        if (pkg == null) {
+            return false;
+        }
+        final PackageManager pm = getPackageManager();
+        final String[] packages = pm.getPackagesForUid(uid);
+        final int N = packages.length;
+        for (int i=0; i<N; i++) {
+            if (packages[i].equals(pkg)) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Save the subscription and if it is a new subscription send the results.
+     */
+    private void addSubscription(String id, ConnectionRecord connection) {
+        // Save the subscription
+        final boolean added = connection.subscriptions.add(id);
+
+        // If this is a new subscription, send the results
+        if (added) {
+            performLoadChildren(id, connection);
+        }
+    }
+
+    /**
+     * Call onLoadChildren and then send the results back to the connection.
+     * <p>
+     * Callers must make sure that this connection is still connected.
+     */
+    private void performLoadChildren(final String parentId, final ConnectionRecord connection) {
+        final Result<List<MediaBrowser.MediaItem>> result
+                = new Result<List<MediaBrowser.MediaItem>>(parentId) {
+            @Override
+            void onResultSent(List<MediaBrowser.MediaItem> list) {
+                if (list == null) {
+                    throw new IllegalStateException("onLoadChildren sent null list for id "
+                            + parentId);
+                }
+                if (mConnections.get(connection.callbacks.asBinder()) != connection) {
+                    if (DBG) {
+                        Log.d(TAG, "Not sending onLoadChildren result for connection that has"
+                                + " been disconnected. pkg=" + connection.pkg + " id=" + parentId);
+                    }
+                    return;
+                }
+
+                final ParceledListSlice<MediaBrowser.MediaItem> pls = new ParceledListSlice(list);
+                try {
+                    connection.callbacks.onLoadChildren(parentId, pls);
+                } catch (RemoteException ex) {
+                    // The other side is in the process of crashing.
+                    Log.w(TAG, "Calling onLoadChildren() failed for id=" + parentId
+                            + " package=" + connection.pkg);
+                }
+            }
+        };
+
+        onLoadChildren(parentId, result);
+
+        if (!result.isDone()) {
+            throw new IllegalStateException("onLoadChildren must call detach() or sendResult()"
+                    + " before returning for package=" + connection.pkg + " id=" + parentId);
+        }
+    }
+
+    /**
+     * Contains information that the browser service needs to send to the client
+     * when first connected.
+     */
+    public static final class BrowserRoot {
+        final private String mRootId;
+        final private Bundle mExtras;
+
+        /**
+         * Constructs a browser root.
+         * @param rootId The root id for browsing.
+         * @param extras Any extras about the browser service.
+         */
+        public BrowserRoot(@NonNull String rootId, @Nullable Bundle extras) {
+            if (rootId == null) {
+                throw new IllegalArgumentException("The root id in BrowserRoot cannot be null. " +
+                        "Use null for BrowserRoot instead.");
+            }
+            mRootId = rootId;
+            mExtras = extras;
+        }
+
+        /**
+         * Gets the root id for browsing.
+         */
+        public String getRootId() {
+            return mRootId;
+        }
+
+        /**
+         * Gets any extras about the brwoser service.
+         */
+        public Bundle getExtras() {
+            return mExtras;
+        }
+    }
+}
diff --git a/media/jni/android_media_MediaCodec.cpp b/media/jni/android_media_MediaCodec.cpp
index f1e1099..1cf589d 100644
--- a/media/jni/android_media_MediaCodec.cpp
+++ b/media/jni/android_media_MediaCodec.cpp
@@ -62,6 +62,7 @@
     jint cryptoErrorNoKey;
     jint cryptoErrorKeyExpired;
     jint cryptoErrorResourceBusy;
+    jint cryptoErrorInsufficientOutputProtection;
 } gCryptoErrorCodes;
 
 static struct CodecActionCodes {
@@ -756,6 +757,9 @@
         case ERROR_DRM_RESOURCE_BUSY:
             err = gCryptoErrorCodes.cryptoErrorResourceBusy;
             break;
+        case ERROR_DRM_INSUFFICIENT_OUTPUT_PROTECTION:
+            err = gCryptoErrorCodes.cryptoErrorInsufficientOutputProtection;
+            break;
         default:  /* Other negative DRM error codes go out as is. */
             break;
     }
@@ -1434,6 +1438,11 @@
     gCryptoErrorCodes.cryptoErrorResourceBusy =
         env->GetStaticIntField(clazz.get(), field);
 
+    field = env->GetStaticFieldID(clazz.get(), "ERROR_INSUFFICIENT_OUTPUT_PROTECTION", "I");
+    CHECK(field != NULL);
+    gCryptoErrorCodes.cryptoErrorInsufficientOutputProtection =
+        env->GetStaticIntField(clazz.get(), field);
+
     clazz.reset(env->FindClass("android/media/MediaCodec$CodecException"));
     CHECK(clazz.get() != NULL);
     field = env->GetStaticFieldID(clazz.get(), "ACTION_TRANSIENT", "I");
diff --git a/media/jni/android_media_MediaDrm.cpp b/media/jni/android_media_MediaDrm.cpp
index c678ac7..0fed27e 100644
--- a/media/jni/android_media_MediaDrm.cpp
+++ b/media/jni/android_media_MediaDrm.cpp
@@ -263,7 +263,7 @@
 
     String8 vendorMessage;
     if (err >= ERROR_DRM_VENDOR_MIN && err <= ERROR_DRM_VENDOR_MAX) {
-        vendorMessage.format("DRM vendor-defined error: %d", err);
+        vendorMessage = String8::format("DRM vendor-defined error: %d", err);
         drmMessage = vendorMessage.string();
     }
 
@@ -285,7 +285,7 @@
             if (msg == NULL) {
                 msg = drmMessage;
             } else {
-                errbuf.format("%s: %s", msg, drmMessage);
+                errbuf = String8::format("%s: %s", msg, drmMessage);
                 msg = errbuf.string();
             }
         }
diff --git a/media/jni/audioeffect/android_media_AudioEffect.cpp b/media/jni/audioeffect/android_media_AudioEffect.cpp
index be37aa8..c9cefbd 100644
--- a/media/jni/audioeffect/android_media_AudioEffect.cpp
+++ b/media/jni/audioeffect/android_media_AudioEffect.cpp
@@ -705,11 +705,12 @@
 }
 
 static jobjectArray
-android_media_AudioEffect_native_queryEffects(JNIEnv *env, jclass clazz)
+android_media_AudioEffect_native_queryEffects(JNIEnv *env, jclass clazz __unused)
 {
     effect_descriptor_t desc;
     char str[EFFECT_STRING_LEN_MAX];
-    uint32_t numEffects = 0;
+    uint32_t totalEffectsCount = 0;
+    uint32_t returnedEffectsCount = 0;
     uint32_t i = 0;
     jstring jdescType;
     jstring jdescUuid;
@@ -717,19 +718,20 @@
     jstring jdescName;
     jstring jdescImplementor;
     jobject jdesc;
+    jobjectArray ret;
 
-    if (AudioEffect::queryNumberEffects(&numEffects) != NO_ERROR) {
+    if (AudioEffect::queryNumberEffects(&totalEffectsCount) != NO_ERROR) {
         return NULL;
     }
 
-    jobjectArray ret = env->NewObjectArray(numEffects, fields.clazzDesc, NULL);
-    if (ret == NULL) {
-        return ret;
+    jobjectArray temp = env->NewObjectArray(totalEffectsCount, fields.clazzDesc, NULL);
+    if (temp == NULL) {
+        return temp;
     }
 
-    ALOGV("queryEffects() numEffects: %d", numEffects);
+    ALOGV("queryEffects() totalEffectsCount: %d", totalEffectsCount);
 
-    for (i = 0; i < numEffects; i++) {
+    for (i = 0; i < totalEffectsCount; i++) {
         if (AudioEffect::queryEffect(i, &desc) != NO_ERROR) {
             goto queryEffects_failure;
         }
@@ -770,15 +772,26 @@
             goto queryEffects_failure;
         }
 
-        env->SetObjectArrayElement(ret, i, jdesc);
+        env->SetObjectArrayElement(temp, returnedEffectsCount++, jdesc);
    }
 
+    if (returnedEffectsCount == 0) {
+        goto queryEffects_failure;
+    }
+    ret = env->NewObjectArray(returnedEffectsCount, fields.clazzDesc, NULL);
+    if (ret == NULL) {
+        goto queryEffects_failure;
+    }
+    for (i = 0; i < returnedEffectsCount; i++) {
+        env->SetObjectArrayElement(ret, i, env->GetObjectArrayElement(temp, i));
+    }
+    env->DeleteLocalRef(temp);
     return ret;
 
 queryEffects_failure:
 
-    if (ret != NULL) {
-        env->DeleteLocalRef(ret);
+    if (temp != NULL) {
+        env->DeleteLocalRef(temp);
     }
     return NULL;
 
@@ -787,7 +800,8 @@
 
 
 static jobjectArray
-android_media_AudioEffect_native_queryPreProcessings(JNIEnv *env, jclass clazz, jint audioSession)
+android_media_AudioEffect_native_queryPreProcessings(JNIEnv *env, jclass clazz __unused,
+                                                     jint audioSession)
 {
     // kDefaultNumEffects is a "reasonable" value ensuring that only one query will be enough on
     // most devices to get all active audio pre processing on a given session.
@@ -895,7 +909,7 @@
     return AndroidRuntime::registerNativeMethods(env, kClassPathName, gMethods, NELEM(gMethods));
 }
 
-jint JNI_OnLoad(JavaVM* vm, void* reserved)
+jint JNI_OnLoad(JavaVM* vm, void* reserved __unused)
 {
 
     JNIEnv* env = NULL;
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/MediaNames.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/MediaNames.java
index 38d7e3e..86c23c7 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/MediaNames.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/MediaNames.java
@@ -25,6 +25,9 @@
 public class MediaNames {
     // A directory to hold all kinds of media files
     public static final String MEDIA_SAMPLE_POOL = "/sdcard/media_api/samples/";
+    // A file to hold all streaming URLs
+    public static final String MEDIA_STREAMING_SRC = "/sdcard/media_api/streaming.txt";
+
     // Audio files
     public static final String MP3CBR = "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_CBR.mp3";
     public static final String MP3VBR = "/sdcard/media_api/music/MP3_48KHz_128kbps_s_1_17_VBR.mp3";
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/functional/CodecTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/functional/CodecTest.java
index e84f762..66ed933 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/functional/CodecTest.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/functional/CodecTest.java
@@ -42,13 +42,13 @@
 import java.util.Random;
 /**
  * Junit / Instrumentation test case for the media player api
- 
- */  
-public class CodecTest {    
+
+ */
+public class CodecTest {
     private static String TAG = "CodecTest";
     private static MediaPlayer mMediaPlayer;
     private MediaPlayer.OnPreparedListener mOnPreparedListener;
-    
+
     private static int WAIT_FOR_COMMAND_TO_COMPLETE = 60000;  //1 min max.
     private static boolean mInitialized = false;
     private static boolean mPrepareReset = false;
@@ -66,18 +66,18 @@
     public static int mMediaInfoNotSeekableCount = 0;
     public static int mMediaInfoMetdataUpdateCount = 0;
 
-    public static String printCpuInfo(){      
+    public static String printCpuInfo(){
         String cm = "dumpsys cpuinfo";
         String cpuinfo =null;
         int ch;
         try{
             Process  p = Runtime.getRuntime().exec(cm);
-            InputStream in = p.getInputStream();        
+            InputStream in = p.getInputStream();
             StringBuffer sb = new StringBuffer(512);
-            while ( ( ch = in.read() ) != -1 ){  
-                sb.append((char) ch); 
+            while ( ( ch = in.read() ) != -1 ){
+                sb.append((char) ch);
             }
-            cpuinfo = sb.toString();      
+            cpuinfo = sb.toString();
         }catch (IOException e){
             Log.v(TAG, e.toString());
         }
@@ -90,14 +90,14 @@
         MediaPlayer mp = new MediaPlayer();
         try{
             mp.setDataSource(filePath);
-            mp.prepare(); 
+            mp.prepare();
         }catch (Exception e){
             Log.v(TAG, e.toString());
         }
         int duration = mp.getDuration();
         Log.v(TAG, "Duration " + duration);
         mp.release();
-        Log.v(TAG, "release");      
+        Log.v(TAG, "release");
         return duration;
     }
 
@@ -122,7 +122,7 @@
         }
         currentPosition = mp.getCurrentPosition();
         mp.stop();
-        mp.release();   
+        mp.release();
         Log.v(TAG, "mp currentPositon = " + currentPosition + " play duration = " + (t2-t1));
         //The currentposition should be within 10% of the sleep time
         //For the very short mp3, it should return the length instead of 10 seconds
@@ -130,11 +130,11 @@
             if (currentPosition < 1000 )
                 return true;
         }
-        if ((currentPosition < ((t2-t1) *1.2)) && (currentPosition > 0)) 
+        if ((currentPosition < ((t2-t1) *1.2)) && (currentPosition > 0))
             return true;
         else
             return false;
-    }  
+    }
 
     public static boolean seekTo(String filePath){
         Log.v(TAG, "seekTo " + filePath);
@@ -149,12 +149,12 @@
             currentPosition = mp.getCurrentPosition();
         }catch (Exception e){
             Log.v(TAG, e.getMessage());
-        }      
+        }
         mp.stop();
         mp.release();
         Log.v(TAG, "CurrentPosition = " + currentPosition);
         //The currentposition should be at least greater than the 80% of seek time
-        if ((currentPosition > MediaNames.SEEK_TIME *0.8)) 
+        if ((currentPosition > MediaNames.SEEK_TIME *0.8))
             return true;
         else
             return false;
@@ -170,7 +170,7 @@
         try{
             mp.setDataSource(filePath);
             mp.prepare();
-            duration = mp.getDuration(); 
+            duration = mp.getDuration();
             Log.v(TAG, "setLooping duration " + duration);
             mp.setLooping(true);
             mp.start();
@@ -180,14 +180,14 @@
             Thread.sleep(20000);
             t2=SystemClock.uptimeMillis();
             Log.v(TAG, "pause");
-            //Bug# 1106852 - IllegalStateException will be thrown if pause is called 
+            //Bug# 1106852 - IllegalStateException will be thrown if pause is called
             //in here
             //mp.pause();
             currentPosition = mp.getCurrentPosition();
             Log.v(TAG, "looping position " + currentPosition + "duration = " + (t2-t1));
         }catch (Exception e){
             Log.v(TAG, "Exception : " + e.toString());
-        }      
+        }
         mp.stop();
         mp.release();
         //The current position should be within 20% of the sleep time
@@ -196,7 +196,7 @@
             return true;
         else
             return false;
-    }  
+    }
 
     public static boolean pause(String filePath) throws Exception {
         Log.v(TAG, "pause - " + filePath);
@@ -206,7 +206,7 @@
         long t2=0;
         MediaPlayer mp = new MediaPlayer();
         mp.setDataSource(filePath);
-        mp.prepare();    
+        mp.prepare();
         int duration = mp.getDuration();
         mp.start();
         t1=SystemClock.uptimeMillis();
@@ -244,7 +244,7 @@
         mp.pause();
         mp.release();
     }
-    
+
     static MediaPlayer.OnVideoSizeChangedListener mOnVideoSizeChangedListener =
         new MediaPlayer.OnVideoSizeChangedListener() {
             public void onVideoSizeChanged(MediaPlayer mp, int width, int height) {
@@ -258,7 +258,7 @@
     //Register the videoSizeChanged listener
     public static int videoHeight(String filePath) throws Exception {
         Log.v(TAG, "videoHeight - " + filePath);
-        int videoHeight = 0;    
+        int videoHeight = 0;
         synchronized (lock) {
             initializeMessageLooper();
             try {
@@ -286,7 +286,7 @@
         } catch (Exception e) {
             Log.e(TAG, e.getMessage());
         }
-        
+
         return videoHeight;
     }
 
@@ -321,12 +321,12 @@
             terminateMessageLooper();
         } catch (Exception e) {
             Log.e(TAG, e.getMessage());
-        }        
+        }
         return videoWidth;
     }
 
     //This also test the streaming video which may take a long
-    //time to start the playback. 
+    //time to start the playback.
     public static boolean videoSeekTo(String filePath) throws Exception {
         Log.v(TAG, "videoSeekTo - " + filePath);
         int currentPosition = 0;
@@ -392,12 +392,12 @@
         currentPosition = mp.getCurrentPosition();
         Log.v(TAG, "seekToEnd currentPosition= " + currentPosition + " isPlaying = " + isPlaying);
         mp.stop();
-        mp.release();   
+        mp.release();
         Log.v(TAG, "duration = " + duration);
         if (currentPosition < 0.9 * duration || isPlaying)
             return false;
         else
-            return true;        
+            return true;
     }
 
     public static boolean shortMediaStop(String filePath){
@@ -419,12 +419,12 @@
         currentPosition = mp.getCurrentPosition();
         Log.v(TAG, "seekToEnd currentPosition= " + currentPosition + " isPlaying = " + isPlaying);
         mp.stop();
-        mp.release();   
+        mp.release();
         Log.v(TAG, "duration = " + duration);
         if (currentPosition > duration || isPlaying)
             return false;
         else
-            return true;        
+            return true;
     }
 
     public static boolean playToEnd(String filePath){
@@ -449,13 +449,13 @@
         //updateDuration = mp.getDuration();
         Log.v(TAG, "seekToEnd currentPosition= " + currentPosition + " isPlaying = " + isPlaying);
         mp.stop();
-        mp.release();   
+        mp.release();
         //Log.v(TAG, "duration = " + duration);
         //Log.v(TAG, "Update duration = " + updateDuration);
         if (currentPosition > duration || isPlaying)
             return false;
         else
-            return true;        
+            return true;
     }
 
     public static boolean seektoBeforeStart(String filePath){
@@ -478,7 +478,7 @@
         if (currentPosition < duration/2)
             return false;
         else
-            return true;        
+            return true;
     }
 
     public static boolean mediaRecorderRecord(String filePath){
@@ -499,7 +499,7 @@
             mRecorder.release();
         }catch (Exception e){
             Log.v(TAG, e.toString());
-        }  
+        }
 
         //Verify the recorded file
         MediaPlayer mp = new MediaPlayer();
@@ -540,7 +540,7 @@
             }
             Bitmap outThumbnail = mMediaMetadataRetriever.getFrameAtTime(-1);
 
-            //Verify the thumbnail 
+            //Verify the thumbnail
             Bitmap goldenBitmap = mBitmapFactory.decodeFile(goldenPath);
             outputWidth = outThumbnail.getWidth();
             outputHeight = outThumbnail.getHeight();
@@ -586,8 +586,8 @@
             return false;
     }
 
-    public static boolean prepareAsyncReset(String filePath){    
-        //preparesAsync 
+    public static boolean prepareAsyncReset(String filePath){
+        //preparesAsync
         try{
             MediaPlayer mp = new MediaPlayer();
             mp.setDataSource(filePath);
@@ -602,9 +602,9 @@
     }
 
 
-    public static boolean isLooping(String filePath) {        
+    public static boolean isLooping(String filePath) {
         MediaPlayer mp = null;
-        
+
         try {
             mp = new MediaPlayer();
             if (mp.isLooping()) {
@@ -619,7 +619,7 @@
                 Log.v(TAG, "MediaPlayer.isLooping() returned false after setLooping(true)");
                 return false;
             }
-            
+
             mp.setLooping(false);
             if (mp.isLooping()) {
                 Log.v(TAG, "MediaPlayer.isLooping() returned true after setLooping(false)");
@@ -659,9 +659,9 @@
 
         return true;
     }
-    
+
     /*
-     * Initializes the message looper so that the mediaPlayer object can 
+     * Initializes the message looper so that the mediaPlayer object can
      * receive the callback messages.
      */
     private static void initializeMessageLooper() {
@@ -672,10 +672,10 @@
                 // Set up a looper to be used by camera.
                 Looper.prepare();
                 Log.v(TAG, "start loopRun");
-                // Save the looper so that we can terminate this thread 
+                // Save the looper so that we can terminate this thread
                 // after we are done with it.
-                mLooper = Looper.myLooper();                
-                mMediaPlayer = new MediaPlayer();                                
+                mLooper = Looper.myLooper();
+                mMediaPlayer = new MediaPlayer();
                 synchronized (lock) {
                     mInitialized = true;
                     lock.notify();
@@ -685,7 +685,7 @@
             }
         }.start();
     }
-    
+
     /*
      * Terminates the message looper thread.
      */
@@ -693,7 +693,7 @@
         mLooper.quit();
         mMediaPlayer.release();
     }
-    
+
     static MediaPlayer.OnPreparedListener mPreparedListener = new MediaPlayer.OnPreparedListener() {
         public void onPrepared(MediaPlayer mp) {
             synchronized (prepareDone) {
@@ -707,14 +707,14 @@
             }
         }
     };
-   
+
     public static boolean prepareAsyncCallback(String filePath, boolean reset) throws Exception {
         //Added the PrepareReset flag which allow us to switch to different
         //test case.
         if (reset){
             mPrepareReset = true;
         }
-        
+
         synchronized (lock) {
             initializeMessageLooper();
             try {
@@ -728,18 +728,18 @@
             mMediaPlayer.setOnPreparedListener(mPreparedListener);
             mMediaPlayer.setDataSource(filePath);
             mMediaPlayer.setDisplay(MediaFrameworkTest.mSurfaceView.getHolder());
-            mMediaPlayer.prepareAsync(); 
+            mMediaPlayer.prepareAsync();
             synchronized (prepareDone) {
                 try {
                     prepareDone.wait(WAIT_FOR_COMMAND_TO_COMPLETE);
                 } catch (Exception e) {
                     Log.v(TAG, "wait was interrupted.");
                 }
-            }         
+            }
             terminateMessageLooper();
         }catch (Exception e){
             Log.v(TAG,e.getMessage());
-        }      
+        }
        return onPrepareSuccess;
     }
 
@@ -784,8 +784,12 @@
         }
     };
 
-    // For each media file, forward twice and backward once, then play to the end
     public static boolean playMediaSamples(String filePath) throws Exception {
+        return playMediaSamples(filePath, 2000);
+    }
+
+    // For each media file, forward twice and backward once, then play to the end
+    public static boolean playMediaSamples(String filePath, int buffertime) throws Exception {
         int duration = 0;
         int curPosition = 0;
         int nextPosition = 0;
@@ -822,14 +826,14 @@
             waittime = duration - mMediaPlayer.getCurrentPosition();
             synchronized(onCompletion){
                 try {
-                    onCompletion.wait(waittime + 2000);
+                    onCompletion.wait(waittime + buffertime);
                 }catch (Exception e) {
                     Log.v(TAG, "playMediaSamples are interrupted");
                     return false;
                 }
             }
             terminateMessageLooper();
-        }catch (Exception e) {
+        } catch (Exception e) {
             Log.v(TAG, "playMediaSamples:" + e.getMessage());
         }
         return onCompleteSuccess;
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraBinderTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraBinderTest.java
index b6bb578..cc50c43 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraBinderTest.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraBinderTest.java
@@ -245,7 +245,7 @@
          * android.hardware.camera2.CaptureResultExtras)
          */
         @Override
-        public void onCameraError(int errorCode, CaptureResultExtras resultExtras)
+        public void onDeviceError(int errorCode, CaptureResultExtras resultExtras)
                 throws RemoteException {
             // TODO Auto-generated method stub
 
@@ -283,7 +283,7 @@
          * @see android.hardware.camera2.ICameraDeviceCallbacks#onCameraIdle()
          */
         @Override
-        public void onCameraIdle() throws RemoteException {
+        public void onDeviceIdle() throws RemoteException {
             // TODO Auto-generated method stub
 
         }
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
index 7b2e7dd..3cae19d 100644
--- a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/integration/CameraDeviceBinderTest.java
@@ -88,10 +88,10 @@
         /*
          * (non-Javadoc)
          * @see
-         * android.hardware.camera2.ICameraDeviceCallbacks#onCameraError(int,
+         * android.hardware.camera2.ICameraDeviceCallbacks#onDeviceError(int,
          * android.hardware.camera2.CaptureResultExtras)
          */
-        public void onCameraError(int errorCode, CaptureResultExtras resultExtras)
+        public void onDeviceError(int errorCode, CaptureResultExtras resultExtras)
                 throws RemoteException {
             // TODO Auto-generated method stub
 
@@ -99,9 +99,9 @@
 
         /*
          * (non-Javadoc)
-         * @see android.hardware.camera2.ICameraDeviceCallbacks#onCameraIdle()
+         * @see android.hardware.camera2.ICameraDeviceCallbacks#onDeviceIdle()
          */
-        public void onCameraIdle() throws RemoteException {
+        public void onDeviceIdle() throws RemoteException {
             // TODO Auto-generated method stub
 
         }
@@ -432,7 +432,7 @@
         // Cancel and make sure we eventually quiesce
         status = mCameraUser.cancelRequest(streamingId, null);
 
-        verify(mMockCb, timeout(WAIT_FOR_IDLE_TIMEOUT_MS).times(1)).onCameraIdle();
+        verify(mMockCb, timeout(WAIT_FOR_IDLE_TIMEOUT_MS).times(1)).onDeviceIdle();
 
         // Submit a few capture requests
         int requestId1 = submitCameraRequest(request, /* streaming */false);
@@ -442,7 +442,7 @@
         int requestId5 = submitCameraRequest(request, /* streaming */false);
 
         // And wait for more idle
-        verify(mMockCb, timeout(WAIT_FOR_IDLE_TIMEOUT_MS).times(2)).onCameraIdle();
+        verify(mMockCb, timeout(WAIT_FOR_IDLE_TIMEOUT_MS).times(2)).onDeviceIdle();
 
     }
 
@@ -472,7 +472,7 @@
         status = mCameraUser.flush(null);
         assertEquals(CameraBinderTestUtils.NO_ERROR, status);
 
-        verify(mMockCb, timeout(WAIT_FOR_FLUSH_TIMEOUT_MS).times(1)).onCameraIdle();
+        verify(mMockCb, timeout(WAIT_FOR_FLUSH_TIMEOUT_MS).times(1)).onDeviceIdle();
 
         // Now a streaming request
         int streamingId = submitCameraRequest(request, /* streaming */true);
@@ -484,7 +484,7 @@
         status = mCameraUser.flush(null);
         assertEquals(CameraBinderTestUtils.NO_ERROR, status);
 
-        verify(mMockCb, timeout(WAIT_FOR_FLUSH_TIMEOUT_MS).times(2)).onCameraIdle();
+        verify(mMockCb, timeout(WAIT_FOR_FLUSH_TIMEOUT_MS).times(2)).onDeviceIdle();
 
         // TODO: When errors are hooked up, count that errors + successful
         // requests equal to 5.
diff --git a/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/stress/MediaPlayerStreamingStressTest.java b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/stress/MediaPlayerStreamingStressTest.java
new file mode 100644
index 0000000..d92c857
--- /dev/null
+++ b/media/tests/MediaFrameworkTest/src/com/android/mediaframeworktest/stress/MediaPlayerStreamingStressTest.java
@@ -0,0 +1,165 @@
+/*
+ * Copyright (C) 2014 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.mediaframeworktest.stress;
+
+import com.android.mediaframeworktest.MediaFrameworkTest;
+import com.android.mediaframeworktest.MediaPlayerStressTestRunner;
+
+import android.os.Bundle;
+import android.os.Environment;
+import android.test.ActivityInstrumentationTestCase2;
+import android.test.suitebuilder.annotation.LargeTest;
+import android.util.Log;
+
+import com.android.mediaframeworktest.MediaNames;
+import com.android.mediaframeworktest.functional.CodecTest;
+
+import java.io.BufferedReader;
+import java.io.BufferedWriter;
+import java.io.File;
+import java.io.FileReader;
+import java.io.FileWriter;
+import java.io.Writer;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Junit / Instrumentation test case for the media player
+ */
+public class MediaPlayerStreamingStressTest extends ActivityInstrumentationTestCase2<MediaFrameworkTest> {
+    private String TAG = "MediaPlayerStreamingStressTest";
+    private String mStreamingSrc;
+
+    public MediaPlayerStreamingStressTest() {
+        super("com.android.mediaframeworktest", MediaFrameworkTest.class);
+    }
+
+    protected void setUp() throws Exception {
+        //Insert a 2 second before launching the test activity. This is
+        //the workaround for the race condition of requesting the updated surface.
+        Thread.sleep(2000);
+        getActivity();
+        MediaPlayerStressTestRunner mRunner = (MediaPlayerStressTestRunner)getInstrumentation();
+        Bundle arguments = mRunner.getArguments();
+        mStreamingSrc = arguments.getString("streaming-source");
+        if (mStreamingSrc == null) {
+            mStreamingSrc = MediaNames.MEDIA_STREAMING_SRC;
+        }
+        super.setUp();
+    }
+
+    private int mTotalPlaybackError = 0;
+    private int mTotalComplete = 0;
+    private int mTotalInfoUnknown = 0;
+    private int mTotalVideoTrackLagging = 0;
+    private int mTotalBadInterleaving = 0;
+    private int mTotalNotSeekable = 0;
+    private int mTotalMetaDataUpdate = 0;
+
+    //Test result output file
+    private static final String PLAYBACK_RESULT = "StreamingTestResult.txt";
+
+    private void writeTestOutput(String filename, Writer output) throws Exception{
+        output.write("URL: " + filename);
+        output.write(" Complete: " + CodecTest.onCompleteSuccess);
+        output.write(" Error: " + CodecTest.mPlaybackError);
+        output.write(" Unknown Info: " + CodecTest.mMediaInfoUnknownCount);
+        output.write(" Track Lagging: " +  CodecTest.mMediaInfoVideoTrackLaggingCount);
+        output.write(" Bad Interleaving: " + CodecTest.mMediaInfoBadInterleavingCount);
+        output.write(" Not Seekable: " + CodecTest.mMediaInfoNotSeekableCount);
+        output.write(" Info Meta data update: " + CodecTest.mMediaInfoMetdataUpdateCount);
+        output.write("\n");
+    }
+
+    private void writeTestSummary(Writer output) throws Exception{
+        output.write("Total Result:\n");
+        output.write("Total Complete: " + mTotalComplete + "\n");
+        output.write("Total Error: " + mTotalPlaybackError + "\n");
+        output.write("Total Unknown Info: " + mTotalInfoUnknown + "\n");
+        output.write("Total Track Lagging: " + mTotalVideoTrackLagging + "\n" );
+        output.write("Total Bad Interleaving: " + mTotalBadInterleaving + "\n");
+        output.write("Total Not Seekable: " + mTotalNotSeekable + "\n");
+        output.write("Total Info Meta data update: " + mTotalMetaDataUpdate + "\n");
+        output.write("\n");
+    }
+
+    private void updateTestResult(){
+        if (CodecTest.onCompleteSuccess){
+            mTotalComplete++;
+        }
+        else if (CodecTest.mPlaybackError){
+            mTotalPlaybackError++;
+        }
+        mTotalInfoUnknown += CodecTest.mMediaInfoUnknownCount;
+        mTotalVideoTrackLagging += CodecTest.mMediaInfoVideoTrackLaggingCount;
+        mTotalBadInterleaving += CodecTest.mMediaInfoBadInterleavingCount;
+        mTotalNotSeekable += CodecTest.mMediaInfoNotSeekableCount;
+        mTotalMetaDataUpdate += CodecTest.mMediaInfoMetdataUpdateCount;
+    }
+
+    //Test that will start the playback for all the videos
+    //under the samples folder
+    @LargeTest
+    public void testVideoPlayback() throws Exception {
+        String fileWithError = "Filename:\n";
+        File playbackOutput = new File(Environment.getExternalStorageDirectory(), PLAYBACK_RESULT);
+        Writer output = new BufferedWriter(new FileWriter(playbackOutput, true));
+
+        boolean testResult = true;
+        // load directory files
+        boolean onCompleteSuccess = false;
+
+
+        Log.i(TAG, "Streaming src file: " + mStreamingSrc);
+        //TODO: add try catch
+
+        File f = new File(mStreamingSrc);
+        BufferedReader br = new BufferedReader(new FileReader(f));
+        List<String> urls = new ArrayList<String>();
+        String line;
+        while ((line = br.readLine()) != null) {
+           urls.add(line.trim());
+        }
+        br.close();
+        if (urls == null) {
+            Log.v("MediaPlayerStreamingTest:testVideoPlayback", "no url found");
+            return;
+        } else {
+            for (int i = 0; i < urls.size(); i++) {
+                //Get url
+                String filename = urls.get(i);
+                onCompleteSuccess =
+                    CodecTest.playMediaSamples(filename, 60000);
+                if (!onCompleteSuccess){
+                    //Don't fail the test right away, print out the failure file.
+                    fileWithError += filename + '\n';
+                    Log.v(TAG, "Failure File : " + fileWithError);
+                    testResult = false;
+                }
+                Thread.sleep(3000);
+                //Write test result to an output file
+                writeTestOutput(filename,output);
+                //Get the summary
+                updateTestResult();
+            }
+            writeTestSummary(output);
+            output.close();
+            assertTrue("testMediaSamples", testResult);
+       }
+    }
+}
diff --git a/packages/BackupRestoreConfirmation/res/values-af/strings.xml b/packages/BackupRestoreConfirmation/res/values-af/strings.xml
index 0bf54cf..06a1af8 100644
--- a/packages/BackupRestoreConfirmation/res/values-af/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-af/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Voer jou toestelenkripsie-wagwoord hier onder in. Dit sal ook gebruik word om die rugsteunargief te enkripteer."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Voer asb. \'n wagwoord in om te gebruik vir enkripsie van die volle rugsteundata. As dit leeg gelaat word, sal jou huidige rugsteunwagwoord gebruik word:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"As jy die volle rugsteundata wil enkripteer, voer \'n wagwoord hieronder in:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Omdat jou toestel geënkripteer is, word daar van jou vereis om jou rugsteun te enkripteer. Voer \'n wagwoord hieronder in:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"As die hersteldata geïnkripteer  word, voer asb. die wagwoord hieronder in:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Rugsteun begin tans..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Rugsteun klaar"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-am/strings.xml b/packages/BackupRestoreConfirmation/res/values-am/strings.xml
index ec5b9631..7077b39 100644
--- a/packages/BackupRestoreConfirmation/res/values-am/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-am/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"እባክህ የመሳሪያህ ምስጠራ የይለፍ ቃል ከታች አስገባ፡፡ይሄ ለምትኬ መዝገብ ለመመስጠርም ይጠቅማል፡፡"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"እባክዎ የሙሉ ውሂብ መጠበቂያ ማመስጠር ለመጠቅም የይለፍ ቃል ያስገቡ። ይህም ባዶ ከሆነ፣ የእርስዎ የአሁኑ የመጠበቂያ ይለፍ ቃል ይወሰዳል፡"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"ሙሉ የውሂብ መጠበቂያ ለማመስጠር ከፈለጉ ከታች የይለፍ ቃል ያስገቡ፡"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"መሣሪያዎ የተመሰጠረ እንደመሆኑ መጠን ምትኬዎን ማመስጠር አለብዎት። እባክዎ የይለፍ ቃል ከታች ያስገቡ፦"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"ውሂብ እነበረበት መልስ የተመሳጠረ ከሆነ፣ እባክዎ ከታች የይለፍ ቃል ያስገቡ"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"መጠባበቂያ በመጀመር ላይ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"መጠባበቂያ ጨርሷል"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ar/strings.xml b/packages/BackupRestoreConfirmation/res/values-ar/strings.xml
index 6a6edd9..b7a56d1 100644
--- a/packages/BackupRestoreConfirmation/res/values-ar/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ar/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"الرجاء إدخال كلمة مرور تشفير الجهاز. سيتم استخدام ذلك أيضًا لتشفير أرشيف النسخ الاحتياطي."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"الرجاء إدخال كلمة المرور للاستخدام لتشفير بيانات النسخة الاحتياطية بالكامل. إذا تم ترك هذا فارغًا، فسيتم استخدام كلمة مرور النسخ الاحتياطي الحالية:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"إذا كنت ترغب في تشفير بيانات النسخة الاحتياطية بالكامل، فأدخل كلمة المرور أدناه:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"نظرًا لكون جهازك مشفرًا، أنت مطالب بتشفير النسخة الاحتياطية. يُرجى إدخال كلمة المرور أدناه:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"إذا كانت بيانات الاسترداد مشفرة، فالرجاء إدخال كلمة المرور أدناه:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"جارٍ بدء النسخ الاحتياطي..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"انتهت عملية النسخ الاحتياطي"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-bg/strings.xml b/packages/BackupRestoreConfirmation/res/values-bg/strings.xml
index c332774..f1b01e5 100644
--- a/packages/BackupRestoreConfirmation/res/values-bg/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-bg/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Моля, въведете паролата си за шифроване на устройството по-долу. Тя ще се използва и за шифроване на резервното копие на архива."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Моля, въведете парола, която да използвате за шифроване на пълното резервно копие на данните. Ако не е попълнена, ще бъде използвана текущата ви парола за резервно копие:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ако искате да шифровате пълното резервно копие на данните, въведете парола по-долу:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Тъй като устройството ви е шифровано, трябва да направите това и за резервното си копие. Моля, по-долу въведете парола:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ако възстановените данни са шифровани, моля, въведете паролата по-долу:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Създаването на резервно копие се стартира..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Създаването на резервно копие завърши"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-bn-rBD/strings.xml b/packages/BackupRestoreConfirmation/res/values-bn-rBD/strings.xml
index 3df7c4d..440cb64 100644
--- a/packages/BackupRestoreConfirmation/res/values-bn-rBD/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-bn-rBD/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"দয়া করে নীচে আপানার ডিভাইসের এনক্রিপশান পাসওয়ার্ড লিখুন৷ এছাড়াও ব্যাকআপ সংরক্ষণাগার এনক্রিপ্ট করতে এটি ব্যবহার করা হবে৷"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"সম্পূর্ণ ব্যাকআপ ডেটা এনক্রিপ্ট করতে দয়া করে একটি পাসওয়ার্ড লিখুন৷ যদি এটি খালি রেখে দেওয়া হয় তবে আপনার বর্তমান ব্যাকআপ পাসওয়ার্ডটি ব্যবহার করা হবে:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"আপনি যদি সম্পূর্ণ ব্যাকআপ ডেটা এনক্রিপ্ট করতে চান তাহলে নীচে একটি পাসওয়ার্ড লিখুন:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"আপনার ডিভাইস এনক্রিপ্ট হয়ে থাকার কারণে আপনার ব্যাকআপকে এনক্রিপ্ট করতে হবে। দয়া করে নীচে একটি পাসওয়ার্ড দিন:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"যদি পুনরুদ্ধার করা ডেটা এনক্রিপ্ট করা থাকে, তবে দয়া করে নীচে পাসওয়ার্ডটি লিখুন:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"ব্যাকআপ নেওয়া শুরু হয়েছে..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ব্যাকআপ নেওয়া সম্পূর্ণ হয়েছে"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ca/strings.xml b/packages/BackupRestoreConfirmation/res/values-ca/strings.xml
index 359df47..3326ccb 100644
--- a/packages/BackupRestoreConfirmation/res/values-ca/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ca/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Introdueix la contrasenya d\'encriptació del dispositiu a continuació. També es farà servir per encriptar l\'arxiu de seguretat."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Introdueix una contrasenya que utilitzaràs per a l\'encriptació de les dades de còpia de la seguretat completa. Si es deixa en blanc, s\'utilitzarà la teva contrasenya de còpia de seguretat actual:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Si vols xifrar les dades de la còpia de seguretat completa, introdueix una contrasenya a continuació:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Com que el teu dispositiu està encriptat, has d\'encriptar el dispositiu secundari. Escriu una contrasenya a continuació:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Si la recuperació de dades està xifrada, introdueix la contrasenya a continuació:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"S\'està iniciant la còpia de seguretat..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Ha finalitzat la còpia de seguretat"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-cs/strings.xml b/packages/BackupRestoreConfirmation/res/values-cs/strings.xml
index c46916b..697de32 100644
--- a/packages/BackupRestoreConfirmation/res/values-cs/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-cs/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Sem prosím zadejte bezpečnostní gesto. Toto gesto se použije také při šifrování záložního archivu."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Zadejte prosím heslo pro šifrování dat úplné zálohy. Pokud pole ponecháte prázdné, použije se aktuální heslo pro zálohy:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Chcete-li data úplné zálohy zašifrovat, zadejte heslo:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Protože je zařízení šifrováno, je třeba zálohu zašifrovat. Níže prosím zadejte heslo:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Pokud jsou obnovená data šifrována, zadejte prosím heslo níže:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Spouští se zálohování..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Zálohování bylo dokončeno"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-da/strings.xml b/packages/BackupRestoreConfirmation/res/values-da/strings.xml
index 0a84c30..28aea33 100644
--- a/packages/BackupRestoreConfirmation/res/values-da/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-da/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Indtast adgangskoden til kryptering for din enhed nedenfor. Denne bliver også brugt til at kryptere sikkerhedskopien af arkivet."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Angiv en adgangskode, som skal bruges til kryptering af alle dine sikkerhedsdata. Hvis dette felt er tomt, bruges din aktuelle adgangskode til sikkerhedskopiering:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Hvis du ønsker at kryptere sikkerhedsdataene, skal du indtaste en adgangskode nedenfor:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Eftersom din enhed er krypteret, skal du kryptere din backup. Indtast en adgangskode nedenfor:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Hvis gendannelsesdataene er krypteret, skal du angive adgangskoden nedenfor:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Sikkerhedskopiering begynder..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sikkerhedskopiering er færdig"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-de/strings.xml b/packages/BackupRestoreConfirmation/res/values-de/strings.xml
index 91a1dff..a2e24e7 100644
--- a/packages/BackupRestoreConfirmation/res/values-de/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-de/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Geben Sie Ihr Passwort zur Geräteverschlüsselung unten ein. Damit wird auch das Sicherungsarchiv verschlüsselt."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Geben Sie ein Passwort für die Verschlüsselung der vollständigen Sicherungsdaten ein. Wenn Sie dieses Feld leer lassen, wird Ihr aktuelles Sicherungspasswort verwendet:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Wenn Sie die gesamten Sicherungsdaten verschlüsseln möchten, geben Sie unten ein Passwort ein:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Da Ihr Gerät verschlüsselt ist, muss auch die Sicherung verschlüsselt werden. Geben Sie unten ein Passwort ein:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Geben Sie das Passwort unten ein, wenn die Daten für die Wiederherstellung verschlüsselt sind:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Sicherung wird gestartet..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sicherung abgeschlossen"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-el/strings.xml b/packages/BackupRestoreConfirmation/res/values-el/strings.xml
index cd325ef..481ad3e 100644
--- a/packages/BackupRestoreConfirmation/res/values-el/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-el/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Εισαγάγετε τον κωδικό πρόσβασης για την κρυπτογράφηση συσκευής παρακάτω. Ο κωδικός αυτός θα χρησιμοποιηθεί και για την κρυπτογράφηση του αρχείου αντιγράφων ασφαλείας."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Εισαγάγετε έναν κωδικό πρόσβασης για χρήση για την κωδικοποίηση του πλήρους αντιγράφου ασφαλείας δεδομένων. Αν μείνει κενό, θα χρησιμοποιηθεί ο τρέχων κωδικός σας πρόσβασης:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Αν θέλετε να κρυπτογραφήσετε τα πλήρη δεδομένα αντιγράφων ασφαλείας, πληκτρολογήστε έναν κωδικό πρόσβασης παρακάτω:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Δεδομένου ότι η συσκευή σας είναι κρυπτογραφημένη, θα πρέπει να κρυπτογραφήσετε τα αντίγραφα ασφαλείας σας. Εισαγάγετε τον κωδικό παρακάτω:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Εάν η επαναφορά των δεδομένων είναι κρυπτογραφημένη, εισάγετε τον κωδικό πρόσβασης παρακάτω:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Έναρξη διαδικασίας δημιουργίας αντιγράφου ασφαλείας..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Ολοκληρώθηκε η διαδικασία δημιουργίας αντιγράφου ασφαλείας"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-en-rGB/strings.xml b/packages/BackupRestoreConfirmation/res/values-en-rGB/strings.xml
index d096d98..badad60 100644
--- a/packages/BackupRestoreConfirmation/res/values-en-rGB/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-en-rGB/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Please enter your device encryption password below. This will also be used to encrypt the backup archive."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Please enter a password to use for encrypting the full backup data. If this is left blank, your current backup password will be used:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"If you wish to encrypt the full backup data, enter a password below:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Since your device is encrypted, you are required to encrypt your backup. Please enter a password below:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"If the restore data is encrypted, please enter the password below:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Backup starting..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Backup finished"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-en-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-en-rIN/strings.xml
index d096d98..badad60 100644
--- a/packages/BackupRestoreConfirmation/res/values-en-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-en-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Please enter your device encryption password below. This will also be used to encrypt the backup archive."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Please enter a password to use for encrypting the full backup data. If this is left blank, your current backup password will be used:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"If you wish to encrypt the full backup data, enter a password below:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Since your device is encrypted, you are required to encrypt your backup. Please enter a password below:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"If the restore data is encrypted, please enter the password below:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Backup starting..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Backup finished"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-es-rUS/strings.xml b/packages/BackupRestoreConfirmation/res/values-es-rUS/strings.xml
index 13ce1da..2d76a1e 100644
--- a/packages/BackupRestoreConfirmation/res/values-es-rUS/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-es-rUS/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Introduce tu contraseña de encriptación del dispositivo a continuación. Esta contraseña también se utilizará para encriptar la copia de seguridad."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Introduce una contraseña para encriptar los datos de la copia de seguridad completa. Si dejas este campo en blanco, se utilizará tu contraseña actual de copia de seguridad:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Si deseas encriptar los datos de la copia de seguridad completa, introduce una contraseña a continuación:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Dado que el dispositivo está encriptado, es necesario que encriptes la copia de seguridad. Ingresa una contraseña a continuación:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Si los datos de recuperación están encriptados, vuelve a introducir la contraseña a continuación:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Iniciando copia de seguridad..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"La realización de la copia de seguridad finalizó."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-es/strings.xml b/packages/BackupRestoreConfirmation/res/values-es/strings.xml
index 7ce3990..01f7cf7 100644
--- a/packages/BackupRestoreConfirmation/res/values-es/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-es/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Introduce a continuación la contraseña de encriptación del dispositivo. Esta contraseña se usará también para encriptar el archivo de copia de seguridad."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Introduce la contraseña que quieras usar para cifrar los datos de la copia de seguridad completa. Si dejas este campo en blanco, se usará tu contraseña de copia de seguridad actual:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Si quieres cifrar los datos de la copia de seguridad completa, introduce la contraseña a continuación:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Tu dispositivo está encriptado, por lo que debes encriptar tu copia de seguridad. Introduce una contraseña a continuación:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Si los datos de restauración están cifrados, introduce la contraseña a continuación:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Iniciando copia de seguridad..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Copia de seguridad finalizada"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-et-rEE/strings.xml b/packages/BackupRestoreConfirmation/res/values-et-rEE/strings.xml
index 0f5fde2..4399068 100644
--- a/packages/BackupRestoreConfirmation/res/values-et-rEE/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-et-rEE/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Sisestage allpool oma seadme krüpteerimise parool. Seda kasutatakse ka varukoopiate arhiivi krüpteerimiseks."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Sisestage parool kõikide varundatud andmete krüpteerimise jaoks. Kui jätate selle tühjaks, siis kasutatakse teie praegust varunduse parooli:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Kui soovite kõik varundusandmed krüpteerida, siis sisestage allpool parool:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Kuna seade on krüpteeritud, siis peate krüpteerima ka varukoopia. Sisestage all parool:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Kui taasteandmed on krüpteeritud, siis sisestage allpool parool."</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Algab varundamine ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Varundamine jõudis lõpule"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-eu-rES/strings.xml b/packages/BackupRestoreConfirmation/res/values-eu-rES/strings.xml
index a563524..ca89aa6 100644
--- a/packages/BackupRestoreConfirmation/res/values-eu-rES/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-eu-rES/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Idatzi gailua enkriptatzeko pasahitza behean. Babeskopiaren artxiboa enkriptatzeko ere erabiliko da."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Idatzi babeskopia osoaren datuak enkriptatzeko erabili nahi duzun pasahitza. Eremua hutsik uzten baduzu, babeskopien uneko pasahitza erabiliko da:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Babeskopia osoko datuak enkriptatu nahi badituzu, idatzi pasahitza behean:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Gailua enkriptatuta daukazunez, babeskopiak ere enkriptatu egin behar dituzu. Idatzi pasahitza hemen:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Leheneratze-datuak enkriptatuta badaude, idatzi pasahitza behean:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Babeskopia egiten hasten…"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Babeskopia egin da"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-fa/strings.xml b/packages/BackupRestoreConfirmation/res/values-fa/strings.xml
index 8b20954..4c16374 100644
--- a/packages/BackupRestoreConfirmation/res/values-fa/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-fa/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"لطفاً گذرواژه رمزگذاری دستگاه خود را در زیر وارد کنید. این برای رمزگذاری بایگانی پشتیبان نیز مورد استفاده قرار می‌گیرد."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"لطفاً یک گذرواژه برای رمزگذاری داده‌های کامل نسخهٔ پشتیبانی وارد کنید. اگر این خالی بماند، گذرواژه فعلی نسخهٔ پشتیبان مورد استفاده قرار خواهد گرفت:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"اگر می‌خواهید تمام نسخه پشتیبانی داده را رمزدار کنید، یک گذرواژه در زیر وارد کنید:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"چون دستگاه‌تان رمز‌گذاری شده است، باید نسخه پشتیبان خودتان را رمزگذاری کنید. لطفاً گذرواژه‌ای را در زیر وارد کنید:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"اگر داده بازیابی شده رمزگذاری شده است، لطفاً گذرواژه را در زیر وارد کنید:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"شروع پشتیبان‌گیری..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"پشتیبان‌گیری پایان یافت"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-fi/strings.xml b/packages/BackupRestoreConfirmation/res/values-fi/strings.xml
index 88aaaa5..4517410 100644
--- a/packages/BackupRestoreConfirmation/res/values-fi/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-fi/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Kirjoita laitteen salauksen salasana alle. Salasanaa käytetään myös varmuuskopioarkiston salaamiseen."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Anna salasana kaikkien varmuuskopiotietojen salaamiseksi. Jos tämä jätetään tyhjäksi, nykyistä varmuuskopioinnin salasanaa käytetään:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Jos haluat salata kaikki varmuuskopiotiedot, kirjoita salasana alle:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Koska laite on salattu, myös varmuuskopiointi on salattava. Kirjoita salasana alle:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Jos palautustiedot on salattu, anna salasana alla:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Varmuuskopiointi alkaa..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Varmuuskopiointi valmis"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-fr-rCA/strings.xml b/packages/BackupRestoreConfirmation/res/values-fr-rCA/strings.xml
index 8a70fb5..769b721 100644
--- a/packages/BackupRestoreConfirmation/res/values-fr-rCA/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-fr-rCA/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Veuillez saisir le mot de passe de chiffrement de l\'appareil ci-dessous. Il permettra également de chiffrer les archives de sauvegarde."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Veuillez saisir un mot de passe à utiliser pour chiffrer les données de sauvegarde complète. Si ce champ n\'est pas renseigné, votre mot de passe de sauvegarde actuel sera utilisé :"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Si vous souhaitez chiffrer l\'ensemble des données de sauvegarde, veuillez saisir un mot de passe ci-dessous :"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Votre appareil est chiffré. Vous devez donc chiffrer votre sauvegarde. Veuillez entrer un mot de passe ci-dessous :"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Si les données de restauration sont chiffrées, veuillez saisir le mot de passe ci-dessous :"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Démarrage de la sauvegarde…"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sauvegarde terminée."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-fr/strings.xml b/packages/BackupRestoreConfirmation/res/values-fr/strings.xml
index 897d8d1..b8d6b56 100644
--- a/packages/BackupRestoreConfirmation/res/values-fr/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-fr/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Veuillez saisir le mot de passe de chiffrement de l\'appareil ci-dessous. Il permettra également de chiffrer les archives de sauvegarde."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Veuillez saisir un mot de passe à utiliser pour chiffrer les données de sauvegarde complète. Si ce champ n\'est pas renseigné, votre mot de passe de sauvegarde actuel sera utilisé :"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Si vous souhaitez chiffrer l\'ensemble des données de sauvegarde, veuillez saisir un mot de passe ci-dessous :"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Votre appareil est chiffré. Vous devez donc chiffrer votre sauvegarde. Veuillez saisir un mot de passe ci-dessous :"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Si les données de restauration sont chiffrées, veuillez saisir le mot de passe ci-dessous :"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Démarrage de la sauvegarde…"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sauvegarde terminée."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-gl-rES/strings.xml b/packages/BackupRestoreConfirmation/res/values-gl-rES/strings.xml
index 18beb0f..c973a31 100644
--- a/packages/BackupRestoreConfirmation/res/values-gl-rES/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-gl-rES/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Insire o contrasinal de encriptación do dispositivo a continuación. Tamén se usará para encriptar o arquivo de copia de seguranza."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Insire un contrasinal para encriptar os datos da copia de seguranza completa. Se queda en branco este campo, usarase o contrasinal de copia de seguranza actual."</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Se queres encriptar os datos da copia de seguranza completa, insire un contrasinal a continuación:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Como o teu dispositivo está cifrado, debes cifrar a túa copia de seguranza. Introduce un contrasinal a continuación:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Se os datos de restauración están encriptados, insire o contrasinal a continuación:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Iniciando copia de seguranza..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"A copia de seguranza rematou"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-hi/strings.xml b/packages/BackupRestoreConfirmation/res/values-hi/strings.xml
index 0b29804..3621ebf 100644
--- a/packages/BackupRestoreConfirmation/res/values-hi/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-hi/strings.xml
@@ -26,9 +26,10 @@
     <string name="deny_restore_button_label" msgid="1724367334453104378">"पुनर्स्‍थापित न करें"</string>
     <string name="current_password_text" msgid="8268189555578298067">"कृपया नीचे अपना वर्तमान सुरक्षित करने का पासवर्ड डालें:"</string>
     <string name="device_encryption_restore_text" msgid="1570864916855208992">"कृपया नीचे अपना उपकरण एन्‍क्रिप्शन पासवर्ड डालें."</string>
-    <string name="device_encryption_backup_text" msgid="5866590762672844664">"कृपया अपना उपकरण सुरक्षित तरीका पासवर्ड नीचे दर्ज करें. बैकअप संग्रहण को एन्‍क्रिप्‍ट करने के लिए भी इसका उपयोग किया जाएगा."</string>
+    <string name="device_encryption_backup_text" msgid="5866590762672844664">"कृपया अपना उपकरण सुरक्षित तरीका पासवर्ड नीचे दर्ज करें. बैकअप मेमोरी को एन्‍क्रिप्‍ट करने के लिए भी इसका उपयोग किया जाएगा."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"कृपया संपूर्ण सुरक्षित डेटा को एन्‍क्रि‍प्‍ट करने में उपयोग के लि‍ए पासवर्ड डालें. यदि‍ यह खाली छोड़ दि‍या जाता है, तो आपके वर्तमान बैकअप पासवर्ड का उपयोग कि‍या जाएगा:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"यदि‍ आप संपूर्ण सुरक्षित डेटा को एन्‍क्रि‍प्‍ट करना चाहते हैं, तो नीचे पासवर्ड डालें:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"चूंकि आपका उपकरण एन्क्रिप्ट किया हुआ है, इसलिए आपको अपने बैकअप को एन्क्रिप्ट करना आवश्यक है. कृपया नीचे पासवर्ड डालें:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"यदि‍ पुनर्स्थापित डेटा को एन्‍क्रि‍प्‍ट कि‍या गया है, तो कृपया नीचे पासवर्ड डालें:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"सुरक्षित करना शुरु हो रहा है..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"सुरक्षित करना पूर्ण"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-hr/strings.xml b/packages/BackupRestoreConfirmation/res/values-hr/strings.xml
index 3451103..66037f3 100644
--- a/packages/BackupRestoreConfirmation/res/values-hr/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-hr/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"U nastavku unesite svoju zaporku enkripcije za uređaj. Ona će se upotrijebiti i za enkripciju te za arhivu sigurnosnih kopija."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Unesite zaporku koju ćete upotrebljavati za kriptiranje podataka potpune sigurnosne kopije. Ako je ostavite praznom, bit će upotrijebljena vaša trenutačna zaporka za sigurnosno kopiranje:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ako želite kriptirati podatke potpune sigurnosne kopije, u nastavku unesite zaporku:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Budući da vam je uređaj kriptiran, morate kriptirati sigurnosne kopije. Unesite zaporku u nastavku:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ako su podaci za vraćanje kriptirani, unesite zaporku u nastavku:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Započinje stvaranje sigurnosne kopije..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sigurnosna kopija dovršena"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-hu/strings.xml b/packages/BackupRestoreConfirmation/res/values-hu/strings.xml
index 73d9a63..a402c56 100644
--- a/packages/BackupRestoreConfirmation/res/values-hu/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-hu/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Kérjük, adja meg az eszköz titkosítási jelszavát. Ezt használjuk a biztonsági mentések archívumának titkosításához is."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Kérjük, írjon be egy jelszót a teljes biztonsági mentés adatainak titkosításához. Ha üresen hagyja, jelenlegi biztonsági jelszavát fogjuk használni:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ha minden mentett adatot szeretne titkosítani, adjon meg egy jelszót alább:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Mivel az eszköz titkosítva van, a biztonsági mentést is titkosítani kell. Kérjük, alább adjon meg egy jelszót:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ha a visszaállítási adatok titkosítva vannak, kérjük, adja meg a jelszót alább:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Biztonsági mentés indítása..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"A biztonsági mentés befejeződött"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-hy-rAM/strings.xml b/packages/BackupRestoreConfirmation/res/values-hy-rAM/strings.xml
index 4db9080..a054068 100644
--- a/packages/BackupRestoreConfirmation/res/values-hy-rAM/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-hy-rAM/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Խնդրում ենք մուտքագրել ձեր սարքի կոդավորված գաղտնաբառը ներքևում: Այն նաև կօգտագործվի պահուստային արխիվի կոդավորման համար:"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Խնդրում ենք մուտքագրել գաղտնաբառը` ամբողջական պահուստավորվող տվյալները կոդավորելու համար: Եթե ​​այն դատարկ թողնեք, ապա կօգտագործվի ձեր առկա պահուստավորման գաղտնաբառը`"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Եթե ​​ցանկանում եք կոդավորել ամբողջական պահուստավորված տվյալները, մուտքագրեք գաղտնաբառ ստորև`"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Քանի որ ձեր սարքը կոդավորված է, դուք պետք է կոդավորեք նաև ձեր պահուստը: Խնդրում ենք ստորև սահմանել գաղտնաբառը՝"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Եթե ​​վերականգնվող տվյալները կոդավորված են, խնդրում ենք մուտքագրել գաղտնաբառը ստորև`"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Պահուստավորումը սկսվում է..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Պահուստավորումն ավարտվեց"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-in/strings.xml b/packages/BackupRestoreConfirmation/res/values-in/strings.xml
index f2d6ad5..f8d8d0a 100644
--- a/packages/BackupRestoreConfirmation/res/values-in/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-in/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Masukkan sandi enkripsi perangkat Anda di bawah. Sandi ini juga akan digunakan untuk mengenkripsi arsip cadangan."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Masukkan sandi yang digunakan untuk mengenkripsi data cadangan lengkap. Jika bidang ini dikosongkan, sandi cadangan Anda saat ini akan digunakan:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Jika Anda ingin mengenkripsi data cadangan lengkap, masukkan sandi di bawah:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Karena perangkat Anda dienkripsi, Anda perlu mengenkripsi cadangan. Masukkan sandi di bawah:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Jika data pemulihan dienkripsi, masukkan sandi di bawah:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Pencadangan dimulai..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Pencadangan selesai"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-is-rIS/strings.xml b/packages/BackupRestoreConfirmation/res/values-is-rIS/strings.xml
index c6ec0e3..13e5e52 100644
--- a/packages/BackupRestoreConfirmation/res/values-is-rIS/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-is-rIS/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Sláðu inn aðgangsorð fyrir dulkóðun tækis hér fyrir neðan. Það verður einnig notað til að dulkóða afritasafnið."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Sláðu inn aðgangsorð til að dulkóða gögn fullrar afritunar. Ef þetta er skilið eftir autt verður núverandi aðgangsorð fyrir afritun notað:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ef þú vilt dulkóða gögn fullrar afritunar skaltu slá inn aðgangsorð hér að neðan:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Þar sem tækið er dulkóðað þarftu að dulkóða öryggisafritið. Veldu aðgangsorð hér fyrir neðan:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ef endurheimt gögn eru dulkóðuð skaltu slá inn aðgangsorðið hér að neðan:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Afritun er að hefjast..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Afritun lokið"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-it/strings.xml b/packages/BackupRestoreConfirmation/res/values-it/strings.xml
index a9e8ae4..2325d40 100644
--- a/packages/BackupRestoreConfirmation/res/values-it/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-it/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Inserisci la tua password di crittografia dispositivo di seguito. Verrà utilizzata anche per crittografare l\'archivio di backup."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Inserisci una password da utilizzare per la crittografia dei dati di backup completi. Se non ne inserisci una, verrà utilizzata la tua password di backup corrente:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Se desideri crittografare tutti i dati di backup, inserisci una password qui di seguito:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Il dispositivo è crittografato, pertanto devi crittografare il backup. Inserisci una password di seguito:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Se i dati di ripristino sono crittografati, inserisci la password qui di seguito:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Avvio del backup..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Backup terminato"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-iw/strings.xml b/packages/BackupRestoreConfirmation/res/values-iw/strings.xml
index 395c39e..8c2ffaf 100644
--- a/packages/BackupRestoreConfirmation/res/values-iw/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-iw/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"הזן את סיסמת ההצפנה של המכשיר שלך בהמשך. הסיסמה תשמש גם להצפנת ארכיון הגיבוי."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"הזן סיסמה שתשמש להצפנה של נתוני הגיבוי המלא. אם תשאיר שדה זה ריק, ייעשה שימוש בסיסמת הגיבוי הנוכחית שלך:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"אם אתה רוצה להצפין את נתוני הגיבוי המלא, הזן סיסמה בהמשך:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"מכיוון שהמכשיר מוצפן, אתה נדרש להצפין את הגיבוי. הזן סיסמה בהמשך:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"אם נתוני השחזור מוצפנים, הזן את הסיסמה למטה:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"מתחיל בגיבוי..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"הגיבוי הסתיים"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ja/strings.xml b/packages/BackupRestoreConfirmation/res/values-ja/strings.xml
index 6859b35..177ef5b 100644
--- a/packages/BackupRestoreConfirmation/res/values-ja/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ja/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"以下に端末暗号化用のパスワードを入力してください。このパスワードはバックアップアーカイブの暗号化にも使用します。"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"フルバックアップデータの暗号化に使用するパスワードを入力してください。空白のままにした場合、現在のバックアップ用のパスワードが使用されます:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"フルバックアップのデータを暗号化する場合は、以下にパスワードを入力してください:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"端末は暗号化されているため、バックアップを暗号化する必要があります。下にパスワードを入力してください。"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"復元するデータが暗号化されている場合、以下にパスワードを入力してください:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"バックアップを開始しています..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"バックアップが終了しました"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ka-rGE/strings.xml b/packages/BackupRestoreConfirmation/res/values-ka-rGE/strings.xml
index 9c6f67e..0c4b7c2 100644
--- a/packages/BackupRestoreConfirmation/res/values-ka-rGE/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ka-rGE/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"გთხოვთ, ქვემოთ მიუთითოთ თქვენი მოწყობილობის დაშიფვრის პაროლი. ეს ასევე გამოყენებული იქნება სათადარიგო არქივის დაშიფრვისათვის."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"გთხოვთ შეიყვანოთ ყველა სამარქაფო ასლის დაშიფრვის პაროლი. თუ ამ ველს ცარიელს დატოვებთ, გამოყენებული იქნება მიმდინარე პაროლი:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"თუ გსურთ სრული ლოკალური სარეზერვო კოპიის დაშიფრვა, შეიყვანეთ პაროლი ქვემოთ:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"ვინაიდან თქვენი მოწყობილობა დაშიფრულია, მოგიწევთ დაშიფროთ თქვენი მარქაფი. გთხოვთ, შეიყვანოთ ქვევით პაროლი:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"თუ აღსადგენი მონაცემები დაშიფრულია, გთხოვთ, შეიყვანოთ პაროლი ქვემოთ:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"ასლების მომზადება იწყება..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"სარეზერვო კოპირება დასრულებულია"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-kk-rKZ/strings.xml b/packages/BackupRestoreConfirmation/res/values-kk-rKZ/strings.xml
index 76ce884..38d7172 100644
--- a/packages/BackupRestoreConfirmation/res/values-kk-rKZ/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-kk-rKZ/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Құрылғыңыздың кодтық кілтсөзін енгізіңіз. Ол сақтық көшірме мұрағатын кодтау үшін де қолданылады."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Деректердің сақтық көшірмесін толығымен шифрлау үшін кілтсөзді енгізіңіз. Егер бұл бос қалдырылса, сіздің қазіргі сақтық көшірме кілтсөзіңіз қолданылады:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Деректердің сақтық көшірмесін толығымен шифрлауды қаласаңыз, кілтсөзді енгізіңіз:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Құрылғыңыз шифрланғандықтан, сақтық көшірмені шифрлау қажет. Төменде құпия сөзді енгізіңіз:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Қалпына келтіру деректері кодталса, кілтсөзді енгізіңіз:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Сақтық көшірме басталуда..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Қалпына келтіру аяқталды"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-km-rKH/strings.xml b/packages/BackupRestoreConfirmation/res/values-km-rKH/strings.xml
index 956fdd7..cc46d9e 100644
--- a/packages/BackupRestoreConfirmation/res/values-km-rKH/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-km-rKH/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"សូម​បញ្ចូល​ពាក្យ​សម្ងាត់​ដាក់​លេខ​កូដ​ឧបករណ៍​របស់​អ្នក​ខាង​ក្រោម។ វា​នឹង​ត្រូវ​បាន​ប្រើ ដើម្បី​ដាក់​លេខ​កូដ​ប័ណ្ណសារ​បម្រុងទុក​ផង​ដែរ។"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"សូម​បញ្ចូល​ពាក្យ​សម្ងាត់​ដើម្បី​ប្រើ​សម្រាប់​ដាក់លេខ​កូដ​ទិន្នន័យ​បម្រុងទុក​ពេញលេញ។ បើ​ទុក​វា​ទទេ ពាក្យ​សម្ងាត់​បម្រុងទុក​បច្ចុប្បន្ន​របស់​អ្នក​នឹង​ត្រូវ​បាន​ប្រើ៖"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"បើ​អ្នក​ចង់​ដាក់​លេខ​កូដ​ទិន្នន័យ​បម្រុងទុក​ពេញលេញ បញ្ចូល​ពាក្យ​សម្ងាត់​ខាង​ក្រោម៖"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"ព្រោះ​ថា​ឧបករណ៍​របស់​អ្នក​ត្រូវ​បាន​ដាក់​លេខ​កូដ អ្នក​ត្រូវ​បាន​ទាមទារ​ឲ្យ​ដាក់លេខ​កូដ​ការ​បម្រុង​ទុក​របស់​អ្នក។ សូម​បញ្ចូល​ពាក្យសម្ងាត់​ខាងក្រោម៖"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"បើ​​ទិន្នន័យ​ស្ដារ​ត្រូវ​បាន​ដាក់​លេខ​កូដ សូម​បញ្ចូល​ពាក្យ​សម្ងាត់​ខាង​ក្រោម៖"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"កំពុង​ចាប់ផ្ដើម​បម្រុងទុក..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ការ​​បម្រុង​ទុក​បាន​បញ្ចប់"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-kn-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-kn-rIN/strings.xml
index 71c60f7..77ff317 100644
--- a/packages/BackupRestoreConfirmation/res/values-kn-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-kn-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"ದಯವಿಟ್ಟು ಕೆಳಗೆ ನಿಮ್ಮ ಸಾಧನದ ಎನ್‌ಕ್ರಿಪ್ಶನ್ ಪಾಸ್‌ವರ್ಡ್ ನಮೂದಿಸಿ. ಇದನ್ನು ಬ್ಯಾಕಪ್ ಆರ್ಕೈವ್ ಅನ್ನು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡಲು ಸಹ ಬಳಸಲಾಗುತ್ತದೆ."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"ಸಂಪೂರ್ಣ ಬ್ಯಾಕಪ್ ಡೇಟಾವನ್ನು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡಲು ಪಾಸ್‌ವರ್ಡ್ ನಮೂದಿಸಿ. ಇದನ್ನು ಖಾಲಿಯಾಗಿಯೇ ಬಿಟ್ಟರೆ, ನಿಮ್ಮ ಪ್ರಸ್ತುತ ಬ್ಯಾಕಪ್ ಪಾಸ್‌ವರ್ಡ್ ಅನ್ನು ಬಳಸಲಾಗುತ್ತದೆ:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"ನೀವು ಸಂಪೂರ್ಣ ಬ್ಯಾಕಪ್ ಡೇಟಾವನ್ನು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡಲು ಬಯಸಿದರೆ, ಕಳಗೆ ಪಾಸ್‌ವರ್ಡ್ ನಮೂದಿಸಿ:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"ನಿಮ್ಮ ಸಾಧನವನ್ನು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡಿರುವ ಕಾರಣ, ನಿಮ್ಮ ಬ್ಯಾಕಪ್ ಅನ್ನು ನಿವು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡುವ ಅಗತ್ಯವಿದೆ. ದಯವಿಟ್ಟು ಕೆಳಗೆ ಪಾಸ್‌ವರ್ಡ್ ನಮೂದಿಸಿ:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"ಮರುಸ್ಥಾಪಿಸಲಾದ ಡೇಟಾವನ್ನು ಎನ್‌ಕ್ರಿಪ್ಟ್ ಮಾಡಲಾಗಿದ್ದರೆ, ದಯವಿಟ್ಟು ಪಾಸ್‌ವರ್ಡ್ ಕೆಳಗೆ ನಮೂದಿಸಿ:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"ಬ್ಯಾಕಪ್ ಪ್ರಾರಂಭವಾಗುತ್ತಿದೆ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ಬ್ಯಾಕಪ್ ಪೂರ್ಣಗೊಂಡಿದೆ"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ko/strings.xml b/packages/BackupRestoreConfirmation/res/values-ko/strings.xml
index 23c8662..600ae62 100644
--- a/packages/BackupRestoreConfirmation/res/values-ko/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ko/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"아래에 기기 암호화 비밀번호를 입력하세요. 백업 자료실을 암호화할 때에도 사용됩니다."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"전체 백업 데이터를 암호화하려면 사용할 비밀번호를 입력하세요. 공백으로 남겨 두면 현재 백업 비밀번호가 사용됩니다."</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"전체 백업 데이터를 암호화하려면 아래에 비밀번호를 입력하세요."</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"기기가 암호화되었으므로 백업을 암호화해야 합니다. 아래에 비밀번호를 입력하세요."</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"복원 데이터가 암호화되어 있는 경우, 아래에 비밀번호를 입력하세요."</string>
     <string name="toast_backup_started" msgid="550354281452756121">"백업 시작 중..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"백업을 완료했습니다."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ky-rKG/strings.xml b/packages/BackupRestoreConfirmation/res/values-ky-rKG/strings.xml
index 1901cf1..6333b18 100644
--- a/packages/BackupRestoreConfirmation/res/values-ky-rKG/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ky-rKG/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Түзмөгүңүздүн шифрлөө сырсөзүн төмөндө киргизиңиз. Ал бэкап архивин шифрлегенге дагы колдонулат."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Эгер сиз толук бэкапты шифрлегиңиз келсе, төмөндө сырсөз киргизиңиз. Эгер ал бош калтырылса, анда учурдагы сырсөз колдонулат:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Эгер сиз толук бэкапты шифрлегиңиз келсе, төмөндө сырсөз киргизиңиз:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Түзмөгүңүз шифрленген болгондуктан, камдооңузду шифрлешиңиз керек. Төмөнгө сырсөз киргизиңиз:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Эгер калыбына келтирүү берилиштери шифрленген болсо, төмөндө сырсөздү киргизиңиз:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Бэкап башталды..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Бэкап аяктады"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-lo-rLA/strings.xml b/packages/BackupRestoreConfirmation/res/values-lo-rLA/strings.xml
index fb28502..ccac8ed 100644
--- a/packages/BackupRestoreConfirmation/res/values-lo-rLA/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-lo-rLA/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"ກະລຸນາປ້ອນລະຫັດຜ່ານການເຂົ້າລະຫັດອຸປະກອນຂອງທ່ານໃສ່ດ້ານລຸ່ມ. ລະຫັດນີ້ຍັງຈະໃຊ້ເພື່ອເຂົ້າລະຫັດຂໍ້ມູນທີ່ສຳຮອງໄວ້."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"ກະລຸນາປ້ອນລະຫັດຜ່ານ ເພື່ອໃຊ້ໃນການເຂົ້າລະຫັດການສຳຮອງຂໍ້ມູນເຕັມຮູບແບບ. ຖ້າປ່ອຍໃຫ້ເປົ່າຫວ່າງໄວ້, ລະຫັດຜ່ານສຳຮອງຂໍ້ມູນທີ່ທ່ານໃຊ້ຢູ່ຈະຖືກນຳໃຊ້ແທນ:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"ຫາກທ່ານຕ້ອງການທີ່ຈະເຂົ້າລະຫັດໃຫ້ກັບການສຳຮອງຂໍ້ມູນທັງໝົດ, ກະລຸນາໃສ່ລະຫັດທາງລຸ່ມນີ້:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"ເນື່ອງ​ຈາກ​ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ​ຖືກ​ເຂົ້າ​ລະ​ຫັດ​ໄວ້, ທ່ານ​ຈຶ່ງ​ຕ້ອງ​ເຂົ້າ​ລະ​ຫັດ​ການ​ສຳ​ຮອງ​ຂໍ້​ມູນ​ຂອງ​ທ່ານ. ກະ​ລຸ​ນາ​ລະ​ບຸ​ລະ​ຫັດ​ຜ່ານ​ດ້ານ​ລຸ່ມ:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"ຫາກຂໍ້ມູນສຳຮອງຖືກເຂົ້າລະຫັດໄວ້, ກະລຸນາໃສ່ລະຫັດຜ່ານທາງດ້ານລຸ່ມນີ້:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"ກຳລັງເລີ່ມການສຳຮອງຂໍ້ມູນ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ສຳຮອງຂໍ້ມູນສຳເລັດແລ້ວ"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-lt/strings.xml b/packages/BackupRestoreConfirmation/res/values-lt/strings.xml
index 44e67de..093ff9d 100644
--- a/packages/BackupRestoreConfirmation/res/values-lt/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-lt/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Toliau įveskite įrenginio šifruotės slaptažodį. Jis bus naudojamas ir atsarginės kopijos archyvui šifruoti."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Įveskite slaptažodį, kuris bus naudojamas visai atsarginei duomenų kopijai šifruoti. Jei reikšmės neįvesite, bus naudojamas dabartinis atsarginės kopijos slaptažodis:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Jei norite užšifruoti visą atsarginę duomenų kopiją, įveskite slaptažodį:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Kadangi jūsų įrenginys užšifruotas, turite užšifruoti atsarginę kopiją. Toliau įveskite slaptažodį:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Jei atkūrimo duomenys užšifruoti, įveskite toliau nurodytą slaptažodį:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Pradedama kurti atsarginę kopiją..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Atsarginė kopija sukurta"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-lv/strings.xml b/packages/BackupRestoreConfirmation/res/values-lv/strings.xml
index c58d6fd..c969726 100644
--- a/packages/BackupRestoreConfirmation/res/values-lv/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-lv/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Lūdzu, ievadiet ierīces šifrēšanas paroli. Tā tiks arī izmantota, lai šifrētu dublējuma arhīvu."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Lūdzu, ievadiet paroli, kas tiks izmantota dublējuma datu pilnīgai šifrēšanai. Ja paroles lauciņu atstāsiet tukšu, tiks izmantota jūsu pašreizējā dublējuma parole:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ja vēlaties pilnībā šifrēt dublējuma datus, tālāk ievadiet paroli:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Tā kā ierīce ir šifrēta, jums ir jāšifrē dublējums. Lūdzu, tālāk ievadiet paroli."</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ja atjaunošanas dati ir šifrēti, lūdzu, ievadiet tālāk paroli:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Tiek sākta dublēšana..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Dublēšana ir pabeigta."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-mk-rMK/strings.xml b/packages/BackupRestoreConfirmation/res/values-mk-rMK/strings.xml
index 7efbe31..3e295c1 100644
--- a/packages/BackupRestoreConfirmation/res/values-mk-rMK/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-mk-rMK/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Внесете ја лозинката за шифрирање на вашиот уред подолу. Таа ќе се користи и за шифрирање на резервната копија на архивата."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Внесете лозинка што ќе се користи за шифрирање на целосната резервна копија на податоците. Ако ова поле остане празно, ќе се користи вашата тековна лозинка за резервна копија:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ако сакате да ја шифрирате целосната резервна копија на податоци, внесете лозинка подолу:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Бидејќи уредот е шифриран, треба да ја шифрирате и резервната копија. Внесете лозинка подолу:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ако податоците што се враќаат се шифрирани, внесете ја лозинката подолу:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Започнува правење резервна копија..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Правењето резервна копија заврши"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ml-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-ml-rIN/strings.xml
index be4335b..b2b4bcb 100644
--- a/packages/BackupRestoreConfirmation/res/values-ml-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ml-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"നിങ്ങളുടെ ഉപകരണ എൻക്രിപ്‌ഷൻ പാസ്‌വേഡ് ചുവടെ നൽകുക. ബാക്കപ്പ് ആർക്കൈവ് എൻക്രിപ്റ്റുചെയ്യാനും ഇത് ഉപയോഗിക്കുന്നു."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"പൂർണ്ണ ബാക്കപ്പ് ഡാറ്റ എൻക്രിപ്‌റ്റ് ചെയ്യുന്നതിനായി ഉപയോഗിക്കാൻ ഒരു പാസ്‌വേഡ് നൽകുക. ഇത് ശൂന്യമായി വിടുകയാണെങ്കിൽ, നിങ്ങളുടെ നിലവിലെ ബാക്കപ്പ് പാസ്‌വേഡ് ഉപയോഗിക്കും:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"പൂർണ്ണ ബാക്കപ്പ് ഡാറ്റ എൻക്രിപ്‌റ്റ് ചെയ്യണമെങ്കിൽ, ചുവടെ ഒരു പാസ്‌വേഡ് നൽകുക:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"നിങ്ങളുടെ ഉപകരണം എൻക്രിപ്റ്റുചെയ്‌തതിനാൽ, ബാക്കപ്പ് എൻക്രിപ്റ്റുചെയ്യേണ്ടതുണ്ട്. ചുവടെ പാസ്‌വേഡ് നൽകുക:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"പുനഃസ്ഥാപിച്ച ഡാറ്റ എൻക്രിപ്‌റ്റ് ചെയ്‌തിട്ടുണ്ടെങ്കിൽ, പാസ്‌വേഡ് ചുവടെ നൽകുക:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"ബാക്കപ്പ് ആരംഭിക്കുന്നു..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ബാക്കപ്പ് പൂർത്തിയായി"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-mn-rMN/strings.xml b/packages/BackupRestoreConfirmation/res/values-mn-rMN/strings.xml
index b2738c0..dc8aa17 100644
--- a/packages/BackupRestoreConfirmation/res/values-mn-rMN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-mn-rMN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Төхөөрөмж шифрлэх нууц үгийг доор оруулна уу. Энэ нууц үгийг нөөшлөх архивийг шифрлэхэд бас ашиглана."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Бүрэн дата нөөшлөлтийг шифрлэхэд ашиглах нууц үгийг оруулна уу. Хэрэв та хоосон үлдээвэл таны одоогийн нөөшлөлтийн нууц үг ашиглагдах болно:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Хэрэв та бүрэн нөөшлөх датаг шифрлэх бол доор нууц үгийг оруулна уу:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Таны төхөөрөмж шифрлэгдсэн тул та нөөшлөлтийг мөн шифрлэх шаардлагатай. Нууц үгийг доор оруулна уу:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Хэрэв сэргээх дата шифрлэгдсэн бол доор нууц үгийг оруулна уу:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Нөөшлөж эхлэх..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Нөөшлөлт дуусав"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-mr-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-mr-rIN/strings.xml
index 8b49007..121ad00 100644
--- a/packages/BackupRestoreConfirmation/res/values-mr-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-mr-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"कृपया आपला डिव्‍हाइस कूटबद्धीकरण संकेतशब्‍द खाली प्रविष्‍‍ट करा. हा बॅकअप संग्रह कूटबद्ध करण्‍यासाठी देखील वापरला जाईल."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"कृपया पूर्ण बॅकअप डेटा कूटबद्ध करण्‍यासाठी वापरण्याकरिता संकेतशब्‍द प्रविष्‍ट करा. हे रिक्त सोडल्‍यास, आपला वर्तमान बॅकअप संकेतशब्‍द वापरला जाईल:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"आपण पूर्ण बॅकअप डेटा कूटबद्ध करू इच्‍छित असल्‍यास, खालील संकेतशब्‍द प्रविष्‍ट करा:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"आपले डिव्हाइस कूटबद्ध केले असल्यामुळे, आपल्याला आपला बॅक अप कूटबद्ध करणे आवश्यक आहे. कृपया खाली एक संकेतशब्द प्रविष्ट करा:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"पुनर्संचयित डेटा कूटबद्ध केला असल्‍यास, कृपया संकेतशब्‍द खाली प्रविष्‍ट करा:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"बॅकअप सुरू होत आहे..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"बॅकअप समाप्त झाले"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ms-rMY/strings.xml b/packages/BackupRestoreConfirmation/res/values-ms-rMY/strings.xml
index 65a9ede..78ddd1c 100644
--- a/packages/BackupRestoreConfirmation/res/values-ms-rMY/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ms-rMY/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Sila masukkan kata laluan penyulitan peranti anda di bawah. Ini juga akan digunakan untuk menyulitkan arkib sandaran."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Sila masukkan kata laluan yang hendak digunakan untuk menyulitkan data sandaran lengkap. Jika dibiarkan kosong, kata laluan sandaran semasa anda akan digunakan:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Jika anda ingin menyulitkan data sandaran lengkap, masukkan kata laluan di bawah:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Memandangkan peranti anda disulitkan, anda perlu menyulitkan sandaran anda. Sila masukkan kata laluan di bawah:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Jika pemulihan data disulitkan, sila masukkan kata laluan di bawah:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Sandaran bermula..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sandaran selesai"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-my-rMM/strings.xml b/packages/BackupRestoreConfirmation/res/values-my-rMM/strings.xml
index 06a135c..d499771 100644
--- a/packages/BackupRestoreConfirmation/res/values-my-rMM/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-my-rMM/strings.xml
@@ -16,20 +16,21 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="backup_confirm_title" msgid="827563724209303345">"အရံ သိမ်းဆည်းမှု အပြည့်လုပ်ရန်"</string>
+    <string name="backup_confirm_title" msgid="827563724209303345">"အရံ သိမ်းဆည်းမှု အပြည့်လုပ်ရန်"</string>
     <string name="restore_confirm_title" msgid="5469365809567486602">"အားလုံးပြန်လည်ရယူရန်"</string>
-    <string name="backup_confirm_text" msgid="1878021282758896593">"ချိတ်ဆက်ထားသောကွန်ပြုတာသို့ ဒေတာအားလုံးအား အရန်သိမ်းဆည်းရန် တောင်းခံပါသည်။ သင်ခွင့်ပြုမည်လား။ \n\nအကယ်၍ သင်သည်အရန်သိမ်းဆည်းရန် မတောင်းခံခဲ့ပါက ဤဆောင်ရွက်ချက်အား ရှေ့ဆက်ရန်ခွင့်မပြုပါနှင့်။"</string>
+    <string name="backup_confirm_text" msgid="1878021282758896593">"ချိတ်ဆက်ထားသောကွန်ပြုတာသို့ ဒေတာအားလုံးအား အရန်သိမ်းဆည်းရန် တောင်းခံပါသည်။ သင်ခွင့်ပြုမည်လား။ \n\nအကယ်၍ သင်သည်အရန်သိမ်းဆည်းရန် မတောင်းခံခဲ့ပါက ဤဆောင်ရွက်ချက်အား ရှေ့ဆက်ရန်ခွင့်မပြုပါနှင့်။"</string>
     <string name="allow_backup_button_label" msgid="4217228747769644068">"ကျွန်ုပ်၏ဒေတာများကို အရန်ထားခြင်း"</string>
-    <string name="deny_backup_button_label" msgid="6009119115581097708">"အရံသိမ်းဆည်းမှု မလုပ်ပါနှင့်"</string>
-    <string name="restore_confirm_text" msgid="7499866728030461776">"ချိတ်ဆက်ထားသောကွန်ပြုတာသို့ ဒေတာအားလုံးအား ပြန်လည်ရယူရန် တောင်းခံပါသည်။ သင်ခွင့်ပြုမည်လား။ \n\nအကယ်၍ သင်သည် ပြန်လည်ရယူရန် ဤဆောင်ရွက်ချက်အား ရှေ့ဆက်ရန်ခွင့်မပြုပါနှင့်။ လက်ရှိစက်ထဲ၌ရှိသောဒေတာအား အစားထိုးမည်ဖြစ်သည်။"</string>
+    <string name="deny_backup_button_label" msgid="6009119115581097708">"အရံသိမ်းဆည်းမှု မလုပ်ပါနှင့်"</string>
+    <string name="restore_confirm_text" msgid="7499866728030461776">"ချိတ်ဆက်ထားသောကွန်ပြုတာသို့ ဒေတာအားလုံးအား ပြန်လည်ရယူရန် တောင်းခံပါသည်။ သင်ခွင့်ပြုမည်လား။ \n\nအကယ်၍ သင်သည် ပြန်လည်ရယူရန် ဤဆောင်ရွက်ချက်အား ရှေ့ဆက်ရန်ခွင့်မပြုပါနှင့်။ လက်ရှိစက်ထဲ၌ရှိသောဒေတာအား အစားထိုးမည်ဖြစ်သည်။"</string>
     <string name="allow_restore_button_label" msgid="3081286752277127827">"ကျွန်ုပ်၏ဒေတာများကို ပြန်လည်ရယူရန်"</string>
-    <string name="deny_restore_button_label" msgid="1724367334453104378">"ပြန်လည်ရယူခြင်းအား မပြုလုပ်ပါနှင့်"</string>
-    <string name="current_password_text" msgid="8268189555578298067">"သင့်လက်ရှိ အရံသိမ်းဆည်းမှု လျှို့ဝှက်စကားဝှက်အား ထည့်သွင်းပါ။"</string>
-    <string name="device_encryption_restore_text" msgid="1570864916855208992">"သင့်စက်၏ လျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက်စကားဝှက်ကို ထည့်သွင်းပါ။"</string>
-    <string name="device_encryption_backup_text" msgid="5866590762672844664">"သင့်စက်၏လျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက် လျှို့ဝှက်စကားဝှက်အားထည့်ပါ။ အရံသိမ်းဆည်းမှု သိမ်းဆည်းနေရာတွင်လည်း အသုံးပြုမည်ဖြစ်သည်။"</string>
-    <string name="backup_enc_password_text" msgid="4981585714795233099">"ဒေတာအားလုံးအားအရန်သိမ်းဆည်းခြင်းပြီးလျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက် လျှို့ဝှက်နံပါတ်/စာကိုထည့်ပါ။ အကယ်၍ ကွက်လပ်ထားပါက ယခုသင့်လက်ရှိလျှို့ဝှက်စကားဝှက်အား အသုံးပြုပါမည်။"</string>
-    <string name="backup_enc_password_optional" msgid="1350137345907579306">"အကယ်၍ ဒေတာအားလုံးအားအရန်သိမ်းဆည်းခြင်းကို ဝှက်လိုပါက အောက်တွင်လျှို့ဝှက်နံပါတ်/စာကိုထည့်ပါ။"</string>
-    <string name="restore_enc_password_text" msgid="6140898525580710823">"အကယ်၍ ပြန်လည်ရယူမည့်ဒေတာမှာလျှို့ဝှက်အသွင်ပြောင်းထားပါက အောက်တွင်စကားဝှက်ကိုထည့်ပါ-"</string>
+    <string name="deny_restore_button_label" msgid="1724367334453104378">"ပြန်လည်ရယူခြင်းအား မပြုလုပ်ပါနှင့်"</string>
+    <string name="current_password_text" msgid="8268189555578298067">"သင့်လက်ရှိ အရံသိမ်းဆည်းမှု လျှို့ဝှက်စကားဝှက်အား ထည့်သွင်းပါ။"</string>
+    <string name="device_encryption_restore_text" msgid="1570864916855208992">"သင့်စက်၏ လျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက်စကားဝှက်ကို ထည့်သွင်းပါ။"</string>
+    <string name="device_encryption_backup_text" msgid="5866590762672844664">"သင့်စက်၏လျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက် လျှို့ဝှက်စကားဝှက်အားထည့်ပါ။ အရံသိမ်းဆည်းမှု သိမ်းဆည်းနေရာတွင်လည်း အသုံးပြုမည်ဖြစ်သည်။"</string>
+    <string name="backup_enc_password_text" msgid="4981585714795233099">"ဒေတာအားလုံးအားအရန်သိမ်းဆည်းခြင်းပြီးလျှို့ဝှက်အသွင်ပြောင်းခြင်းအတွက် လျှို့ဝှက်နံပါတ်/စာကိုထည့်ပါ။ အကယ်၍ ကွက်လပ်ထားပါက ယခုသင့်လက်ရှိလျှို့ဝှက်စကားဝှက်အား အသုံးပြုပါမည်။"</string>
+    <string name="backup_enc_password_optional" msgid="1350137345907579306">"အကယ်၍ ဒေတာအားလုံးအားအရန်သိမ်းဆည်းခြင်းကို ဝှက်လိုပါက အောက်တွင်လျှို့ဝှက်နံပါတ်/စာကိုထည့်ပါ။"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"သင်၏ ကိရိယာကို လျှို့ဝျက်ကုဒ် သွင်းထားရာ၊ သင်သည် သင်၏ ဘက်အာပ်ကိုပါ  လျှို့ဝျက်ကုဒ် သွင်းရန် လိုအပ်သည်။ ကျေးဇူးပြုပြီး အောက်မှာ စကားဝှက်ကို ထည့်သွင်းပါ:"</string>
+    <string name="restore_enc_password_text" msgid="6140898525580710823">"အကယ်၍ ပြန်လည်ရယူမည့်ဒေတာမှာလျှို့ဝှက်အသွင်ပြောင်းထားပါက အောက်တွင်စကားဝှက်ကိုထည့်ပါ-"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Backupစတင်ပြုလုပ်နေသည်"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Backupလုပ်ခြင်းပြီးဆုံးပါပြီ"</string>
     <string name="toast_restore_started" msgid="7881679218971277385">"ပြန်လည်ရယူခြင်း စတင်ပြုလုပ်နေသည်"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-nb/strings.xml b/packages/BackupRestoreConfirmation/res/values-nb/strings.xml
index d43ec2f..8d5bc19 100644
--- a/packages/BackupRestoreConfirmation/res/values-nb/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-nb/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Skriv inn krypteringspassordet for enheten din nedenfor. Dette brukes også til å kryptere arkivet for sikkerhetskopier."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Skriv inn et passord for kryptering av full sikkerhetskopi. Hvis feltet er tomt, brukes det gjeldende passordet ditt for sikkerhetskopiering:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Hvis du vil kryptere alle de sikkerhetskopierte dataene, skriver du inn et passord nedenfor:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Siden enheten din er kryptert, er du nødt til å kryptere sikkerhetskopien din. Angi et passord nedenfor:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Hvis de gjenopprettede dataene er krypterte, må du skrive inn passordet nedenfor:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Sikkerhetskopiering er i gang …"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Sikkerhetskopieringen er fullført"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ne-rNP/strings.xml b/packages/BackupRestoreConfirmation/res/values-ne-rNP/strings.xml
index c56332f..473802e 100644
--- a/packages/BackupRestoreConfirmation/res/values-ne-rNP/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ne-rNP/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"कृपया तल तपाईंको उपकरण एन्क्रिप्सन पासवर्ड प्रविष्टि गर्नुहोस्: यो ब्याकप सँग्रह एन्क्रिप्ट गर्न पनि प्रयोग हुने छ।"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"ब्याकप डेटालाई encrypt गर्न पासवर्ड प्रविष्टि गर्नुहोस्, यदि यो खालि छोडिएको खण्डमा तपाईको पुरानै पासवर्ड प्रयोग हुने छ।"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"यदि तपाईं पूर्ण ब्याकअप डेटा इन्क्रिप्ट गर्न चाहनु हुन्छ भने तल पासवर्ड प्रविष्टि गर्नुहोस्।"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"तपाईँको उपकरण गुप्तिकरण गरिए देखि, तपाईंले आफ्नो जगेडा गुप्तिकरण गर्न आवश्यक छ। कृपया तल पासवर्ड प्रविष्ट गर्नुहोस्:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"यदि पुनःबहाली डेटा इन्क्रिप्ट छ भने कृपया तल पासवर्ड प्रविष्टि गर्नुहोस्:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"जगेडा राख्न सुरु हुँदै..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"ब्याकअप सकियो"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-nl/strings.xml b/packages/BackupRestoreConfirmation/res/values-nl/strings.xml
index 1bf73e9..f483b14 100644
--- a/packages/BackupRestoreConfirmation/res/values-nl/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-nl/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Geef hieronder uw wachtwoord voor apparaatversleuteling op. Dit wordt ook gebruikt om het back-uparchief te versleutelen."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Geef een wachtwoord op dat u wilt gebruiken voor het coderen van de gegevens van de volledige back-up. Als u dit leeg laat, wordt uw huidige back-upwachtwoord gebruikt:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Als u de gegevens van de volledige back-up wilt versleutelen, geeft u daarvoor hieronder een wachtwoord op:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Aangezien uw apparaat is gecodeerd, moet u uw back-up coderen. Geef hieronder een wachtwoord op:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Als deze herstelgegevens zijn gecodeerd, geeft u hieronder het wachtwoord op:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Back-up starten..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Back-up voltooid"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-pl/strings.xml b/packages/BackupRestoreConfirmation/res/values-pl/strings.xml
index 122b5df..81908b3 100644
--- a/packages/BackupRestoreConfirmation/res/values-pl/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-pl/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Wpisz poniżej hasło szyfrowania urządzenia. Służy ono również do szyfrowania archiwum kopii zapasowych."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Wpisz hasło do zaszyfrowania pełnej kopii zapasowej. Jeśli pozostawisz puste pole, zostanie użyte aktualne hasło kopii zapasowej:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Jeśli chcesz zaszyfrować pełną kopię zapasową, wprowadź poniżej hasło:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Ponieważ Twoje urządzenie jest szyfrowane, musisz też zaszyfrować jego kopię zapasową. Wpisz hasło poniżej:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Jeśli przywracane dane są zaszyfrowane, wpisz poniżej hasło:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Tworzenie kopii zapasowej..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Utworzono kopię zapasową"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-pt-rPT/strings.xml b/packages/BackupRestoreConfirmation/res/values-pt-rPT/strings.xml
index 477d423..ecaa069 100644
--- a/packages/BackupRestoreConfirmation/res/values-pt-rPT/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-pt-rPT/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Introduza a palavra-passe de encriptação do dispositivo abaixo. Esta também será utilizada para encriptar o arquivo da cópia de segurança."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Introduza uma palavra-passe a utilizar para encriptar os dados da cópia de segurança completa. Se deixar o campo em branco, será utilizada a palavra-passe de cópia de segurança atual."</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Se pretender encriptar os dados da cópia de segurança completa, introduza uma palavra-passe abaixo:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Uma vez que o seu dispositivo está encriptado, tem de encriptar a sua cópia de segurança. Introduza uma palavra-passe abaixo:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Se os dados a restaurar estiverem encriptados, introduza a palavra-passe abaixo:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"A iniciar cópia de segurança..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Cópia de segurança concluída"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-pt/strings.xml b/packages/BackupRestoreConfirmation/res/values-pt/strings.xml
index a56b31ca..cbc579e 100644
--- a/packages/BackupRestoreConfirmation/res/values-pt/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-pt/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Insira sua senha de criptografia do dispositivo abaixo. Ela também será usada para criptografar o arquivo de backup."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Digite uma senha para usar para criptografar os dados de backup por completo. Se isso for deixado em branco, sua senha atual de backup será usada:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Se você deseja criptografar os dados de backup por completo, digite uma senha abaixo:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Como seu dispositivo está criptografado, é necessário criptografar seu backup. Insira uma senha abaixo:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Se os dados restaurados forem criptografada, digite a senha abaixo:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Iniciando backup..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"O backup foi concluído"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ro/strings.xml b/packages/BackupRestoreConfirmation/res/values-ro/strings.xml
index 839edbb..1cf438b 100644
--- a/packages/BackupRestoreConfirmation/res/values-ro/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ro/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Introduceţi mai jos parola de criptare a dispozitivului. Aceasta va fi utilizată, de asemenea, pentru a cripta arhiva copiei de rezervă."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Introduceţi o parolă pentru a o utiliza la criptarea datelor copiei de rezervă complete. Dacă acest câmp rămâne necompletat, pentru copierea de rezervă se va utiliza parola dvs. actuală."</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Dacă doriţi să criptaţi datele copiei de rezervă complete, introduceţi o parolă mai jos:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Întrucât dispozitivul este criptat, trebuie să criptați backupurile. Introduceți o parolă mai jos:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Dacă datele pentru restabilire sunt criptate, introduceţi parola mai jos:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Se începe copierea de rezervă..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Copierea de rezervă a fost finalizată"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ru/strings.xml b/packages/BackupRestoreConfirmation/res/values-ru/strings.xml
index f516493..43fcf3b 100644
--- a/packages/BackupRestoreConfirmation/res/values-ru/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ru/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Введите пароль для шифрования устройства и архива резервных копий."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Введите пароль для шифрования всех резервных данных. Если поле останется пустым, будет использован текущий пароль:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Чтобы зашифровать все резервные данные, введите пароль:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"На устройстве включено шифрование. Оно будет применено и к резервной копии данных. Введите пароль."</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Если восстановленные данные зашифрованы, введите пароль:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Резервное копирование..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Резервное копирование завершено"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-si-rLK/strings.xml b/packages/BackupRestoreConfirmation/res/values-si-rLK/strings.xml
index ed32e73..aaeaf04 100644
--- a/packages/BackupRestoreConfirmation/res/values-si-rLK/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-si-rLK/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"කරුණාකර ඔබගේ උපාංගයේ සංකේතන මුරපදය පහත ඇතුලත් කරන්න. සංරක්ෂිත උපස්ථ සංකේතනය කිරීමට මෙය භාවිත කළ හැක."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"කරුණාකර සියලු උපස්ථ දත්ත සංකේතනය කිරීම සඳහා භාවිතයට මුරපදයක් ඇතුළත් කරන්න. මෙය හිස්ව තැබුවොත්, ඔබගේ වර්තමාන උපස්ථ මුරපදය භාවිත වෙයි:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"සියලු උපස්ථ දත්ත සංකේතනය කිරීමට ඔබ අදහස් කරන්නේ නම්, මුරපදය පහලින් ඇතුලත් කරන්න:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"ඔබගේ උපාංගය සංකේතනය කර තිබෙන නිසා, ඔබගේ උපස්ථය සංකේතනය ඔබට අවශ්‍ය වී තිබේ. කරුණාකර මුරපදය පහළින් එකතු කරන්න:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"යළි පිහිටුවන දත්ත සංකේතනය කරන ලද ඒවානම්, කරුණාකර මුරපදය පහලින් ඇතුල් කරන්න:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"උපස්ථ කිරීම ආරම්භ කරමින්..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"උපස්ථය අවසන්"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-sk/strings.xml b/packages/BackupRestoreConfirmation/res/values-sk/strings.xml
index 12f562b..a231d23 100644
--- a/packages/BackupRestoreConfirmation/res/values-sk/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-sk/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Zadajte svoje heslo na šifrovanie zariadenia nižšie. Bude tiež použité na šifrovanie archívu zálohy."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Zadajte heslo, ktoré sa použije pri šifrovaní údajov úplnej zálohy. Ak pole ponecháte prázdne, použije sa vaše aktuálne heslo zálohy:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ak chcete šifrovať údaje úplnej zálohy, zadajte heslo nižšie:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Pretože je vaše zariadenie šifrované, musíte zašifrovať aj svoju zálohu. Zadajte heslo nižšie:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ak sú údaje obnovenia šifrované, zadajte heslo nižšie:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Vytváranie zálohy..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Zálohovanie bolo dokončené"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-sl/strings.xml b/packages/BackupRestoreConfirmation/res/values-sl/strings.xml
index 17d4d80..80551d6 100644
--- a/packages/BackupRestoreConfirmation/res/values-sl/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-sl/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Vnesite geslo za šifriranje naprave spodaj. Uporabljeno bo tudi za šifriranje arhiva varnostnih kopij."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Vnesite geslo za šifriranje podatkov popolnega varnostnega kopiranja. Če to pustite prazno, bo uporabljeno trenutno geslo za varnostno kopiranje:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Če želite šifrirati vse varnostno kopirane podatke, spodaj vnesite geslo:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Vaša naprava je šifrirana, zato morate šifrirati varnostno kopirane podatke. Spodaj vnesite geslo:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Če so podatki za obnovitev šifrirani, spodaj vnesite geslo:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Varnostno kopiranje se začenja ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Varnostno kopiranje končano"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-sr/strings.xml b/packages/BackupRestoreConfirmation/res/values-sr/strings.xml
index 9af91f6..7f48e48 100644
--- a/packages/BackupRestoreConfirmation/res/values-sr/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-sr/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Унесите лозинку уређаја за шифровање. Ово ће се користити и за шифровање резервне архиве."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Унесите лозинку коју ћете користити за шифровање података потпуне резервне копије. Ако то поље оставите празно, користиће се тренутна лозинка резервне копије:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ако желите да шифрујете податке потпуне резервне копије, унесите лозинку у наставку."</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Пошто вам је уређај шифрован, морате да шифрујете резервну копију. Унесите лозинку у наставку:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Ако су подаци за враћање шифровани, унесите лозинку у наставку:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Покретање прављења резервне копије..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Резервна копија је направљена"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-sv/strings.xml b/packages/BackupRestoreConfirmation/res/values-sv/strings.xml
index a2ef430..3ae37cf 100644
--- a/packages/BackupRestoreConfirmation/res/values-sv/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-sv/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Ange lösenordet för enhetskryptering nedan. Lösenordet kommer även att användas för att kryptera säkerhetskopian."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Ange ett lösenord för kryptering av alla säkerhetskopierade data. Om det här lämnas tomt kommer ditt nuvarande lösenord för säkerhetskopior att användas:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Om du vill kryptera alla säkerhetskopierade data anger du ett lösenord nedan:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Eftersom enheten är krypterad måste du kryptera säkerhetskopierade data. Ange lösenordet nedan:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Om återställda data är krypterade anger du lösenordet nedan:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Säkerhetskopieringen har startat ..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Säkerhetskopieringen har slutförts"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-sw/strings.xml b/packages/BackupRestoreConfirmation/res/values-sw/strings.xml
index 4e35b91..530efc0 100644
--- a/packages/BackupRestoreConfirmation/res/values-sw/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-sw/strings.xml
@@ -24,12 +24,13 @@
     <string name="restore_confirm_text" msgid="7499866728030461776">"Kurejesha kamili kwa data nzima kutoka kwa eneo kazi la kompyuta lililounganishwa limeombwa. Unataka kuruhusu hii kutendeka?\n\n Ikiwa hukuweza kurejesha upya mwenyewe, usiruhusu uendeshaji huu kuendelea. Hii itaweka upya data yoyote iliyo kwenye kifaa hiki sasa!"</string>
     <string name="allow_restore_button_label" msgid="3081286752277127827">"Rejesha upya data yangu"</string>
     <string name="deny_restore_button_label" msgid="1724367334453104378">"Usirejeshe upya"</string>
-    <string name="current_password_text" msgid="8268189555578298067">"Tafadhali ingiza nenosiri unalotumia kuhifadhi nakala rudufu hapo chini:"</string>
-    <string name="device_encryption_restore_text" msgid="1570864916855208992">"Tafadhali ingiza nenosiri la usimbaji fiche wa kifaa chako hapo chini."</string>
-    <string name="device_encryption_backup_text" msgid="5866590762672844664">"Tafadhali ingiza nenosiri lako la msimbo fiche hapo chini. Pia litatumika kusimba fiche jalidi ya hifadhi."</string>
-    <string name="backup_enc_password_text" msgid="4981585714795233099">"Tafadhali ingiza nenosiri la kutumia katika kusimba nakala rudufu kamili za data kwa njia fiche. Ikiwa hii itawachwa wazi, nenosiri lako la sasa litatumika:"</string>
-    <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ikiwa unataka kusimba kwa njia fiche nakala rudufu za data, ingiza nenosiri lililo hapo chini:"</string>
-    <string name="restore_enc_password_text" msgid="6140898525580710823">"Ikiwa data iliyorejeshwa upya, tafadhali ingiza nenosiri lililo hapo chini:"</string>
+    <string name="current_password_text" msgid="8268189555578298067">"Tafadhali weka nenosiri unalotumia kuhifadhi nakala hapo chini:"</string>
+    <string name="device_encryption_restore_text" msgid="1570864916855208992">"Tafadhali weka nenosiri la kifaa chako la kusimba kwa njia fiche hapo chini."</string>
+    <string name="device_encryption_backup_text" msgid="5866590762672844664">"Tafadhali weka nenosiri lako la kusimba kifaa kwa njia fiche hapo chini. Pia litatumika kusimba kumbukumbu za nakala kwa njia fiche."</string>
+    <string name="backup_enc_password_text" msgid="4981585714795233099">"Tafadhali weka nenosiri la kutumia katika kusimba nakala kamili za data kwa njia fiche. Ikiwa sehemu hii itawachwa wazi, nenosiri lako la sasa litatumika:"</string>
+    <string name="backup_enc_password_optional" msgid="1350137345907579306">"Ikiwa unataka kusimba nakala za data kwa njia fiche, weka nenosiri hapo chini:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Kwa kuwa kifaa chako kimesimbwa kwa njia fiche, unatakiwa usimbe hifadhi rudufu yako kwa njia fiche. Tafadhali weka nenosiri hapo chini:"</string>
+    <string name="restore_enc_password_text" msgid="6140898525580710823">"Ikiwa data imesimbwa kwa njia fiche, tafadhali weka nenosiri lake hapo chini:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Inaanza kuhifadhi..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Imemaliza kuhifadhi"</string>
     <string name="toast_restore_started" msgid="7881679218971277385">"Inaanza kurejesha..."</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ta-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-ta-rIN/strings.xml
index c5dde9a..0a7ffae 100644
--- a/packages/BackupRestoreConfirmation/res/values-ta-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ta-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"உங்கள் சாதன முறைமையாக்கல் கடவுச்சொல்லைக் கீழே உள்ளிடவும். இது காப்புப் பிரதி இயக்ககத்தை முறைமையாக்கவும் பயன்படுத்தப்படும்."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"காப்புப் பிரதி எடுக்கப்பட்ட முழு தரவையும் முறைமையாக்க கடவுச்சொல்லை உள்ளிடவும். இதைக் காலியாக விட்டால், உங்கள் தற்போதைய காப்புப் பிரதி கடவுச்சொல் பயன்படுத்தப்படும்:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"காப்புப் பிரதி எடுக்கப்பட்ட முழு தரவையும் முறைமையாக்க விரும்பினால், கடவுச்சொல்லை உள்ளிடவும்:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"சாதனம் மறையாக்கப்பட்டுள்ளதால், காப்புப்பிரதியையும் மறையாக்க வேண்டும். கீழே கடவுச்சொல்லை உள்ளிடவும்:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"மீட்டமைக்கப்பட்ட தரவு முறைமையாக்கப்பட்டிருந்தால், கீழே கடவுச்சொல்லை உள்ளிடவும்:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"காப்புப் பிரதி எடுக்க தொடங்குகிறது..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"காப்புப் பிரதி எடுப்பது முடிந்தது"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-te-rIN/strings.xml b/packages/BackupRestoreConfirmation/res/values-te-rIN/strings.xml
index 781c3ae..52916d8 100644
--- a/packages/BackupRestoreConfirmation/res/values-te-rIN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-te-rIN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"దయచేసి దిగువ మీ పరికర గుప్తీకరణ పాస్‌వర్డ్‌ను నమోదు చేయండి. ఇది బ్యాకప్ ఆర్కైవ్‌ను గుప్తీకరించడానికి కూడా ఉపయోగించబడుతుంది."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"దయచేసి పూర్తి బ్యాకప్ డేటాను గుప్తీకరించడం కోసం ఉపయోగించడానికి పాస్‌వర్డ్‌ను నమోదు చేయండి. దీన్ని ఖాళీగా వదిలిపెడితే, మీ ప్రస్తుత బ్యాకప్ పాస్‌వర్డ్ ఉపయోగించబడుతుంది:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"మీరు పూర్తి బ్యాకప్ డేటాను గుప్తీకరించాలని కోరుకుంటున్నట్లయితే, దిగువ పాస్‌వర్డ్‌ను నమోదు చేయండి:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"మీ పరికరం గుప్తీకరించబడినందున, మీరు మీ బ్యాకప్‌ని గుప్తీకరించాల్సి ఉంటుంది. దయచేసి దిగువ పాస్‌వర్డ్‌ని నమోదు చేయండి:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"పునరుద్ధరణ డేటా గుప్తీకరించబడుంటే, దయచేసి దిగువ పాస్‌వర్డ్‌ను నమోదు చేయండి:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"బ్యాకప్ ప్రారంభమవుతోంది..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"బ్యాకప్ పూర్తయింది"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-th/strings.xml b/packages/BackupRestoreConfirmation/res/values-th/strings.xml
index c0543a0..a79cc6f 100644
--- a/packages/BackupRestoreConfirmation/res/values-th/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-th/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"โปรดป้อนรหัสผ่านการเข้ารหัสอุปกรณ์ของคุณด้านล่างนี้ ซึ่งจะใช้ในการเข้ารหัสที่เก็บข้อมูลสำรองด้วย"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"โปรดป้อนรหัสผ่านเพื่อใช้สำหรับเข้ารหัสข้อมูลที่สำรองแบบเต็มรูปแบบ หากเว้นว่างไว้ รหัสผ่านการสำรองข้อมูลปัจจุบันของคุณจะถูกใช้:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"หากคุณต้องการเข้ารหัสข้อมูลที่สำรองเต็มรูปแบบ โปรดป้อนรหัสผ่านด้านล่างนี้:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"เนื่องจากอุปกรณ์ของคุณมีการเข้ารหัสไว้ คุณจึงต้องเข้ารหัสการสำรองข้อมูล โปรดป้อนรหัสผ่านด้านล่าง:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"หากมีการเข้ารหัสข้อมูลที่คืนค่า โปรดป้อนรหัสผ่านด้านล่างนี้:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"กำลังเริ่มการสำรองข้อมูล..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"สำรองข้อมูลเสร็จแล้ว"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-tl/strings.xml b/packages/BackupRestoreConfirmation/res/values-tl/strings.xml
index 5c564ba..dac816b 100644
--- a/packages/BackupRestoreConfirmation/res/values-tl/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-tl/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Mangyaring ilagay ang password ng pag-encrypt ng iyong device sa ibaba. Gagamitin rin ito upang i-encrypt ang backup na archive."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Mangyaring maglagay ng password na gamitin sa pag-e-encrypt ng buong data sa pag-backup. Kung iiwanan itong blangko, gagamitin ang iyong kasalukuyang backup na password:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Kung nais mong i-encrypt ang buong data ng backup, maglagay ng password sa ibaba:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Dahil naka-encrypt ang iyong device, hinihiling sa iyo na i-encrypt ang iyong backup. Pakilagay ang password sa ibaba:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Kung naka-encrypt ang data sa pagpapanumbalik, pakilagay ang password sa ibaba:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Sinisimulan ang pag-backup..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Tapos na ang pag-backup"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-tr/strings.xml b/packages/BackupRestoreConfirmation/res/values-tr/strings.xml
index 591be7c..ee0c483 100644
--- a/packages/BackupRestoreConfirmation/res/values-tr/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-tr/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Lütfen cihazınızı şifrelemek için kullandığınız şifreyi aşağıya girin. Bu şifre aynı zamanda yedekleme arşivini şifrelemek için de kullanılacaktır."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Tam yedekleme verilerini şifrelemek için lütfen bir şifre girin. Boş bırakılırsa, mevcut yedekleme şifreniz kullanılır:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Yedeklenen tüm verileri şifrelemek isterseniz, aşağıya bir şifre girin:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Cihazınız şifrelenmiş olduğundan yedeklemenizi şifrelemeniz gerekmektedir. Lütfen şifreyi aşağıya girin:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Geri yükleme verileri şifreliyse, lütfen şifreyi aşağıya girin:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Yedekleme başlıyor..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Yedekleme işlemi sona erdi"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-uk/strings.xml b/packages/BackupRestoreConfirmation/res/values-uk/strings.xml
index b4ddef1..f3d529e 100644
--- a/packages/BackupRestoreConfirmation/res/values-uk/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-uk/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Нижче введіть свій пароль шифрування пристрою. Він також використовуватиметься для шифрування архіву резервної копії."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Введіть пароль, який використовується для шифрування повного резервного копіювання даних. Якщо залишити це поле порожнім, буде використано поточний пароль резервного копіювання."</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Якщо ви хочете зашифрувати повне резервне копіювання даних, введіть пароль нижче:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Оскільки ваш пристрій зашифровано, потрібно також зашифрувати резервну копію даних. Введіть пароль нижче."</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Якщо дані для відновлення зашифровано, введіть пароль нижче:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Початок резервного копіювання..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Резервне копіювання закінчено"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-ur-rPK/strings.xml b/packages/BackupRestoreConfirmation/res/values-ur-rPK/strings.xml
index 8c6cc48..6f1c9b5 100644
--- a/packages/BackupRestoreConfirmation/res/values-ur-rPK/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-ur-rPK/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"براہ کرم ذیل میں اپنے آلہ کی مرموز کاری کا پاس ورڈ درج کریں۔ یہ بیک اپ آرکائیو کی مرموز کاری کرنے کیلئے بھی استعمال کیا جائے گا۔"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"مکمل بیک اپ ڈیٹا کی مرموز کاری کرنے کیلئے استعمال کیلئے براہ کرم ایک پاس ورڈ درج کریں۔ اگر یہ خالی رہتا ہے تو آپ کا موجودہ بیک اپ پاس ورڈ استعمال کیا جائے گا:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"اگر آپ مکمل بیک اپ ڈیٹا کی مرموز کاری کرنا چاہتے ہیں تو ذیل میں ایک پاس ورڈ درج کریں:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"چونکہ آپ کا آلہ مرموز کردہ ہے، آپ کو اپنے بیک اپ کی مرموز کاری کرنے کی ضرورت ہے۔ براہ کرم ذیل میں ایک پاس ورڈ درج کریں:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"اگر بحال ہونے والا ڈیٹا مرموز کردہ ہے تو براہ کرم ذیل میں پاس ورڈ درج کریں:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"بیک اپ شروع ہو رہا ہے…"</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"بیک اپ مکمل ہو گیا"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-uz-rUZ/strings.xml b/packages/BackupRestoreConfirmation/res/values-uz-rUZ/strings.xml
index 5821dee..1b5741f 100644
--- a/packages/BackupRestoreConfirmation/res/values-uz-rUZ/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-uz-rUZ/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Qurilmangizning shifr parolini kiriting. U zahira arxivni shifrlash uchun ham ishlatiladi."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"To‘liq zahira fayllarini shifrlash uchun parol kiriting. Agar bo‘sh qoldirsangiz, joriy zahiralash parolingizdan foydalaniladi:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"To‘liq zahira ma’lumotlarini shifrlashni xohlasangiz, quyidagi parolni kiriting:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Qurilmangiz shifrlangani bois ma’lumotlaringizning zaxira nusxasini ham shifrlash zarur. Shifrlash uchun parolni kiriting:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Agar tiklash ma’lumoti shifrlangan bo‘lsa, pastga parolni kiriting:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Zahiralash jarayoni boshlandi..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Zahiralash jarayoni bajarildi"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-vi/strings.xml b/packages/BackupRestoreConfirmation/res/values-vi/strings.xml
index 69e8f9c..264164f 100644
--- a/packages/BackupRestoreConfirmation/res/values-vi/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-vi/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Vui lòng nhập mật khẩu mã hóa thiết bị của bạn bên dưới. Mật khẩu này cũng được sử dụng để mã hóa kho lưu trữ sao lưu."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Vui lòng nhập mật khẩu dùng để mã hóa toàn bộ dữ liệu sao lưu. Nếu trường này bị bỏ trống, mật khẩu sao lưu hiện tại của bạn sẽ được sử dụng:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Nếu bạn muốn mã hóa toàn bộ dữ liệu sao lưu, hãy nhập mật khẩu bên dưới:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Vì thiết bị của bạn được mã hóa nên bạn phải mã hóa bản sao lưu của mình. Vui lòng nhập mật khẩu bên dưới:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Nếu dữ liệu khôi phục được mã hóa, vui lòng nhập mật khẩu bên dưới:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Đang bắt đầu sao lưu..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Đã hoàn thành sao lưu"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-zh-rCN/strings.xml b/packages/BackupRestoreConfirmation/res/values-zh-rCN/strings.xml
index b2764fb..ac20aed 100644
--- a/packages/BackupRestoreConfirmation/res/values-zh-rCN/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-zh-rCN/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"请在下方输入您的设备加密密码。此密码还会用于加密备份存档。"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"请输入用于加密完整备份数据的密码。如果留空,系统将会使用您当前的备份密码:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"如果您想为整个备份数据加密,请在下方输入密码:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"由于您的设备进行了加密,因此您需要加密备份。请在下方输入密码:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"如果恢复数据已加密,请在下方输入密码:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"开始备份..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"备份已完成"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-zh-rHK/strings.xml b/packages/BackupRestoreConfirmation/res/values-zh-rHK/strings.xml
index d3bcd6e..c6180d2 100644
--- a/packages/BackupRestoreConfirmation/res/values-zh-rHK/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-zh-rHK/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"請在下面輸入您的裝置加密密碼,這也會用來將封存備份加密。"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"請輸入為完整備份資料加密的專用密碼。如果留空,系統將使用您目前的備份密碼:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"如果您想將完整的備份資料加密,請在下面輸入一組密碼:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"您的裝置已加密,因此您必須將您的備份加密。請在下方輸入密碼:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"如果還原的資料經過加密處理,請在下面輸入密碼:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"正在開始備份..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"備份完畢"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-zh-rTW/strings.xml b/packages/BackupRestoreConfirmation/res/values-zh-rTW/strings.xml
index 4da6114..3a753a0 100644
--- a/packages/BackupRestoreConfirmation/res/values-zh-rTW/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-zh-rTW/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"請在下方輸入您的裝置加密密碼,這也會用來加密備份封存檔。"</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"請輸入完整備份資料加密專用的密碼。如果您沒有輸入密碼,系統會使用您目前的備用密碼:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"如果您想要將完整備份資料進行加密,請在下面輸入一組密碼:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"由於您的裝置已加密,因此您必須為您的備份加密。請在下方輸入密碼:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"如果還原的資料經過加密處理,請在下面輸入密碼:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"正在開始備份..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"備份完畢"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values-zu/strings.xml b/packages/BackupRestoreConfirmation/res/values-zu/strings.xml
index 955b26f..90259e1 100644
--- a/packages/BackupRestoreConfirmation/res/values-zu/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values-zu/strings.xml
@@ -29,6 +29,7 @@
     <string name="device_encryption_backup_text" msgid="5866590762672844664">"Uyacelwa ukuba ufake iphasiwedi efakwe kudivayisi yakho ngezansi. lokhu kuzosetshenziswa ukufaka kusilondoloza sokusiza lapho kudingeka."</string>
     <string name="backup_enc_password_text" msgid="4981585714795233099">"Sicela ufake iphasiwedi ezosetshenziselwa ukubhala ngokufihlekileyo imininingo eyesekwe ngokulondoloza. Uma lokhu kushiywe kungabhalwe lutho, kuzosetshenziswa iphasiwedi yokweseka ngokulondoloza yamanje:"</string>
     <string name="backup_enc_password_optional" msgid="1350137345907579306">"Uma ufuna ukufaka ikhowudi kwimininingo yonke eyesekelwe ngokulondoloza faka i-passowrd engezansi:"</string>
+    <string name="backup_enc_password_required" msgid="7889652203371654149">"Njengoba idivayisi yakho ibethelwe, kudingeka ukuthi ubethele isipele sakho. Sicela ufake iphasiwedi ngezansi:"</string>
     <string name="restore_enc_password_text" msgid="6140898525580710823">"Uma uhlelo lokusebenza yokubuyiselwa esimweni kwmininingo ibhalwe ngokufihlekileyo, sicela ufake iphasiwedi engezansi:"</string>
     <string name="toast_backup_started" msgid="550354281452756121">"Ukulondoloza kuyaqala..."</string>
     <string name="toast_backup_ended" msgid="3818080769548726424">"Ukulondoloza kuphelile"</string>
diff --git a/packages/BackupRestoreConfirmation/res/values/strings.xml b/packages/BackupRestoreConfirmation/res/values/strings.xml
index 5c90fd0..3fb3fd4 100644
--- a/packages/BackupRestoreConfirmation/res/values/strings.xml
+++ b/packages/BackupRestoreConfirmation/res/values/strings.xml
@@ -44,6 +44,8 @@
     <string name="backup_enc_password_text">Please enter a password to use for encrypting the full backup data. If this is left blank, your current backup password will be used:</string>
     <!-- Text for message to user that they may optionally supply an encryption password to use for a full backup operation. -->
     <string name="backup_enc_password_optional">If you wish to encrypt the full backup data, enter a password below:</string>
+    <!-- Text for message to user that they must supply an encryption password to use for a full backup operation because their phone is locked. -->
+    <string name="backup_enc_password_required">Since your device is encrypted, you are required to encrypt your backup. Please enter a password below:</string>
 
     <!-- Text for message to user when performing a full restore operation, explaining that they must enter the password originally used to encrypt the full backup data. -->
     <string name="restore_enc_password_text">If the restore data is encrypted, please enter the password below:</string>
diff --git a/packages/BackupRestoreConfirmation/src/com/android/backupconfirm/BackupRestoreConfirmation.java b/packages/BackupRestoreConfirmation/src/com/android/backupconfirm/BackupRestoreConfirmation.java
index 82ac8cb..c2bb90c 100644
--- a/packages/BackupRestoreConfirmation/src/com/android/backupconfirm/BackupRestoreConfirmation.java
+++ b/packages/BackupRestoreConfirmation/src/com/android/backupconfirm/BackupRestoreConfirmation.java
@@ -28,6 +28,7 @@
 import android.os.RemoteException;
 import android.os.ServiceManager;
 import android.os.storage.IMountService;
+import android.os.storage.StorageManager;
 import android.util.Log;
 import android.util.Slog;
 import android.view.View;
@@ -182,25 +183,14 @@
         // We vary the password prompt depending on whether one is predefined, and whether
         // the device is encrypted.
         mIsEncrypted = deviceIsEncrypted();
-        if (mIsEncrypted) {
-            Log.d(TAG, "Device is encrypted: requiring encryption pw");
-            TextView pwPrompt = (TextView) findViewById(R.id.password_desc);
-            // this password is mandatory; we hide the other options during backup
-            if (layoutId == R.layout.confirm_backup) {
-                pwPrompt.setText(R.string.device_encryption_backup_text);
-                TextView tv = (TextView) findViewById(R.id.enc_password);
-                tv.setVisibility(View.GONE);
-                tv = (TextView) findViewById(R.id.enc_password_desc);
-                tv.setVisibility(View.GONE);
-            } else {
-                pwPrompt.setText(R.string.device_encryption_restore_text);
-            }
-        } else if (!haveBackupPassword()) {
+        if (!haveBackupPassword()) {
             curPwDesc.setVisibility(View.GONE);
             mCurPassword.setVisibility(View.GONE);
             if (layoutId == R.layout.confirm_backup) {
                 TextView encPwDesc = (TextView) findViewById(R.id.enc_password_desc);
-                encPwDesc.setText(R.string.backup_enc_password_optional);
+                encPwDesc.setText(mIsEncrypted
+                                  ? R.string.backup_enc_password_required
+                                  : R.string.backup_enc_password_optional);
             }
         }
 
@@ -246,8 +236,7 @@
             mDidAcknowledge = true;
 
             try {
-                CharSequence encPassword = (mIsEncrypted)
-                        ? mCurPassword.getText() : mEncPassword.getText();
+                CharSequence encPassword = mEncPassword.getText();
                 mBackupManager.acknowledgeFullBackupOrRestore(mToken,
                         allow,
                         String.valueOf(mCurPassword.getText()),
@@ -261,7 +250,10 @@
 
     boolean deviceIsEncrypted() {
         try {
-            return (mMountService.getEncryptionState() != IMountService.ENCRYPTION_STATE_NONE);
+            return mMountService.getEncryptionState()
+                     != IMountService.ENCRYPTION_STATE_NONE
+                && mMountService.getPasswordType()
+                     != StorageManager.CRYPT_TYPE_DEFAULT;
         } catch (Exception e) {
             // If we can't talk to the mount service we have a serious problem; fail
             // "secure" i.e. assuming that the device is encrypted.
diff --git a/packages/CaptivePortalLogin/res/values-my-rMM/strings.xml b/packages/CaptivePortalLogin/res/values-my-rMM/strings.xml
index 603a804..cd90b38 100644
--- a/packages/CaptivePortalLogin/res/values-my-rMM/strings.xml
+++ b/packages/CaptivePortalLogin/res/values-my-rMM/strings.xml
@@ -3,6 +3,6 @@
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_name" msgid="5934709770924185752">"CaptivePortalLogin"</string>
     <string name="action_use_network" msgid="6076184727448466030">"ဒီကွန်ရက်ကို လက်ရှိအတိုင်း သုံးရန်"</string>
-    <string name="action_do_not_use_network" msgid="4577366536956516683">"ဒီကွန်ရက်ကို မသုံးပါနှင့်"</string>
+    <string name="action_do_not_use_network" msgid="4577366536956516683">"ဒီကွန်ရက်ကို မသုံးပါနှင့်"</string>
     <string name="action_bar_label" msgid="2573986763322074279">"ကွန်ရက်သို့ လက်မှတ်ထိုး ဝင်ရန်"</string>
 </resources>
diff --git a/packages/CaptivePortalLogin/res/values-ru/strings.xml b/packages/CaptivePortalLogin/res/values-ru/strings.xml
index 6e7a85f..50e392c 100644
--- a/packages/CaptivePortalLogin/res/values-ru/strings.xml
+++ b/packages/CaptivePortalLogin/res/values-ru/strings.xml
@@ -4,5 +4,5 @@
     <string name="app_name" msgid="5934709770924185752">"CaptivePortalLogin"</string>
     <string name="action_use_network" msgid="6076184727448466030">"Использовать эту сеть"</string>
     <string name="action_do_not_use_network" msgid="4577366536956516683">"Не использовать эту сеть"</string>
-    <string name="action_bar_label" msgid="2573986763322074279">"Подключиться к сети"</string>
+    <string name="action_bar_label" msgid="2573986763322074279">"Регистрация в сети"</string>
 </resources>
diff --git a/packages/CaptivePortalLogin/res/values/styles.xml b/packages/CaptivePortalLogin/res/values/styles.xml
index 7ccd3d3..4a99638 100644
--- a/packages/CaptivePortalLogin/res/values/styles.xml
+++ b/packages/CaptivePortalLogin/res/values/styles.xml
@@ -16,7 +16,7 @@
     <style name="AppTheme" parent="AppBaseTheme">
         <!-- All customizations that are NOT specific to a particular API-level can go here. -->
         <!-- Setting's theme's accent color makes ProgressBar useless, reset back. -->
-        <item name="android:colorAccent">@*android:color/material_light_blue_A200</item>
+        <item name="android:colorAccent">@*android:color/material_deep_teal_500</item>
     </style>
 
 </resources>
diff --git a/packages/DefaultContainerService/src/com/android/defcontainer/DefaultContainerService.java b/packages/DefaultContainerService/src/com/android/defcontainer/DefaultContainerService.java
index 20a621b..1f28324 100644
--- a/packages/DefaultContainerService/src/com/android/defcontainer/DefaultContainerService.java
+++ b/packages/DefaultContainerService/src/com/android/defcontainer/DefaultContainerService.java
@@ -16,11 +16,13 @@
 
 package com.android.defcontainer;
 
+import static com.android.internal.content.NativeLibraryHelper.LIB_DIR_NAME;
+
 import android.app.IntentService;
+import android.content.Context;
 import android.content.Intent;
 import android.content.pm.IPackageManager;
 import android.content.pm.PackageCleanItem;
-import android.content.pm.PackageInfo;
 import android.content.pm.PackageInfoLite;
 import android.content.pm.PackageManager;
 import android.content.pm.PackageParser;
@@ -28,7 +30,6 @@
 import android.content.pm.PackageParser.PackageParserException;
 import android.content.res.ObbInfo;
 import android.content.res.ObbScanner;
-import android.os.Build;
 import android.os.Environment;
 import android.os.Environment.UserEnvironment;
 import android.os.FileUtils;
@@ -37,8 +38,6 @@
 import android.os.Process;
 import android.os.RemoteException;
 import android.os.ServiceManager;
-import android.os.StatFs;
-import android.provider.Settings;
 import android.system.ErrnoException;
 import android.system.Os;
 import android.system.StructStatVfs;
@@ -50,13 +49,11 @@
 import com.android.internal.os.IParcelFileDescriptorFactory;
 import com.android.internal.util.ArrayUtils;
 
-import dalvik.system.VMRuntime;
 import libcore.io.IoUtils;
 import libcore.io.Streams;
 
 import java.io.File;
 import java.io.FileInputStream;
-import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
@@ -69,9 +66,6 @@
  */
 public class DefaultContainerService extends IntentService {
     private static final String TAG = "DefContainer";
-    private static final boolean localLOGV = false;
-
-    private static final String LIB_DIR_NAME = "lib";
 
     // TODO: migrate native code unpacking to always be a derivative work
 
@@ -114,7 +108,7 @@
                 return copyPackageToContainerInner(pkg, handle, containerId, key, isExternal,
                         isForwardLocked, abiOverride);
             } catch (PackageParserException | IOException e) {
-                Slog.w(TAG, "Failed to parse package at " + packagePath);
+                Slog.w(TAG, "Failed to copy package at " + packagePath, e);
                 return null;
             } finally {
                 IoUtils.closeQuietly(handle);
@@ -155,10 +149,12 @@
          *            containing one or more APKs.
          */
         @Override
-        public PackageInfoLite getMinimalPackageInfo(final String packagePath, int flags,
-                long threshold, String abiOverride) {
-            PackageInfoLite ret = new PackageInfoLite();
+        public PackageInfoLite getMinimalPackageInfo(String packagePath, int flags,
+                String abiOverride) {
+            final Context context = DefaultContainerService.this;
+            final boolean isForwardLocked = (flags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
 
+            PackageInfoLite ret = new PackageInfoLite();
             if (packagePath == null) {
                 Slog.i(TAG, "Invalid package file " + packagePath);
                 ret.recommendedInstallLocation = PackageHelper.RECOMMEND_FAILED_INVALID_APK;
@@ -167,10 +163,12 @@
 
             final File packageFile = new File(packagePath);
             final PackageParser.PackageLite pkg;
+            final long sizeBytes;
             try {
                 pkg = PackageParser.parsePackageLite(packageFile, 0);
-            } catch (PackageParserException e) {
-                Slog.w(TAG, "Failed to parse package at " + packagePath);
+                sizeBytes = PackageHelper.calculateInstalledSize(pkg, isForwardLocked, abiOverride);
+            } catch (PackageParserException | IOException e) {
+                Slog.w(TAG, "Failed to parse package at " + packagePath + ": " + e);
 
                 if (!packageFile.exists()) {
                     ret.recommendedInstallLocation = PackageHelper.RECOMMEND_FAILED_INVALID_URI;
@@ -185,55 +183,13 @@
             ret.versionCode = pkg.versionCode;
             ret.installLocation = pkg.installLocation;
             ret.verifiers = pkg.verifiers;
-            ret.recommendedInstallLocation = recommendAppInstallLocation(pkg, flags, threshold,
-                    abiOverride);
+            ret.recommendedInstallLocation = PackageHelper.resolveInstallLocation(context,
+                    pkg.packageName, pkg.installLocation, sizeBytes, flags);
             ret.multiArch = pkg.multiArch;
 
             return ret;
         }
 
-        /**
-         * Determine if package will fit on internal storage.
-         *
-         * @param packagePath absolute path to the package to be copied. Can be
-         *            a single monolithic APK file or a cluster directory
-         *            containing one or more APKs.
-         */
-        @Override
-        public boolean checkInternalFreeStorage(String packagePath, boolean isForwardLocked,
-                long threshold) throws RemoteException {
-            final File packageFile = new File(packagePath);
-            final PackageParser.PackageLite pkg;
-            try {
-                pkg = PackageParser.parsePackageLite(packageFile, 0);
-                return isUnderInternalThreshold(pkg, isForwardLocked, threshold);
-            } catch (PackageParserException | IOException e) {
-                Slog.w(TAG, "Failed to parse package at " + packagePath);
-                return false;
-            }
-        }
-
-        /**
-         * Determine if package will fit on external storage.
-         *
-         * @param packagePath absolute path to the package to be copied. Can be
-         *            a single monolithic APK file or a cluster directory
-         *            containing one or more APKs.
-         */
-        @Override
-        public boolean checkExternalFreeStorage(String packagePath, boolean isForwardLocked,
-                String abiOverride) throws RemoteException {
-            final File packageFile = new File(packagePath);
-            final PackageParser.PackageLite pkg;
-            try {
-                pkg = PackageParser.parsePackageLite(packageFile, 0);
-                return isUnderExternalThreshold(pkg, isForwardLocked, abiOverride);
-            } catch (PackageParserException | IOException e) {
-                Slog.w(TAG, "Failed to parse package at " + packagePath);
-                return false;
-            }
-        }
-
         @Override
         public ObbInfo getObbInfo(String filename) {
             try {
@@ -295,13 +251,10 @@
             final PackageParser.PackageLite pkg;
             try {
                 pkg = PackageParser.parsePackageLite(packageFile, 0);
-                return calculateContainerSize(pkg, isForwardLocked, abiOverride) * 1024 * 1024;
+                return PackageHelper.calculateInstalledSize(pkg, isForwardLocked, abiOverride);
             } catch (PackageParserException | IOException e) {
-                /*
-                 * Okay, something failed, so let's just estimate it to be 2x
-                 * the file size. Note this will be 0 if the file doesn't exist.
-                 */
-                return packageFile.length() * 2;
+                Slog.w(TAG, "Failed to calculate installed size: " + e);
+                return Long.MAX_VALUE;
             }
         }
     };
@@ -356,159 +309,72 @@
 
     private String copyPackageToContainerInner(PackageLite pkg, NativeLibraryHelper.Handle handle,
             String newCid, String key, boolean isExternal, boolean isForwardLocked,
-            String abiOverride) {
-        // TODO: extend to support copying all split APKs
-        if (!ArrayUtils.isEmpty(pkg.splitNames)) {
-            throw new UnsupportedOperationException("Copying split APKs not yet supported");
-        }
+            String abiOverride) throws IOException {
 
-        final String resFileName = "pkg.apk";
-        final String publicResFileName = "res.zip";
-
-        if (pkg.multiArch) {
-            // TODO: Support multiArch installs on ASEC.
-            throw new IllegalArgumentException("multiArch not supported on ASEC installs.");
-        }
-
-        // The .apk file
-        final String codePath = pkg.baseCodePath;
-        final File codeFile = new File(codePath);
-        final String[] abis;
-        try {
-            abis = calculateAbiList(handle, abiOverride, pkg.multiArch);
-        } catch (IOException ioe) {
-            Slog.w(TAG, "Problem determining app ABIS: " + ioe);
-            return null;
-        }
-
-        // Calculate size of container needed to hold base APK.
-        final int sizeMb;
-        try {
-            sizeMb = calculateContainerSize(pkg, handle, isForwardLocked, abis);
-        } catch (IOException e) {
-            Slog.w(TAG, "Problem when trying to copy " + codeFile.getPath());
-            return null;
-        }
+        // Calculate container size, rounding up to nearest MB and adding an
+        // extra MB for filesystem overhead
+        final long sizeBytes = PackageHelper.calculateInstalledSize(pkg, handle,
+                isForwardLocked, abiOverride);
 
         // Create new container
-        final String newCachePath = PackageHelper.createSdDir(sizeMb, newCid, key, Process.myUid(),
-                isExternal);
-        if (newCachePath == null) {
-            Slog.e(TAG, "Failed to create container " + newCid);
-            return null;
+        final String newMountPath = PackageHelper.createSdDir(sizeBytes, newCid, key,
+                Process.myUid(), isExternal);
+        if (newMountPath == null) {
+            throw new IOException("Failed to create container " + newCid);
         }
-
-        if (localLOGV) {
-            Slog.i(TAG, "Created container for " + newCid + " at path : " + newCachePath);
-        }
-
-        final File resFile = new File(newCachePath, resFileName);
-        if (FileUtils.copyFile(new File(codePath), resFile)) {
-            if (localLOGV) {
-                Slog.i(TAG, "Copied " + codePath + " to " + resFile);
-            }
-        } else {
-            Slog.e(TAG, "Failed to copy " + codePath + " to " + resFile);
-            // Clean up container
-            PackageHelper.destroySdDir(newCid);
-            return null;
-        }
+        final File targetDir = new File(newMountPath);
 
         try {
-            Os.chmod(resFile.getAbsolutePath(), 0640);
+            // Copy all APKs
+            copyFile(pkg.baseCodePath, targetDir, "base.apk", isForwardLocked);
+            if (!ArrayUtils.isEmpty(pkg.splitNames)) {
+                for (int i = 0; i < pkg.splitNames.length; i++) {
+                    copyFile(pkg.splitCodePaths[i], targetDir,
+                            "split_" + pkg.splitNames[i] + ".apk", isForwardLocked);
+                }
+            }
+
+            // Extract native code
+            final File libraryRoot = new File(targetDir, LIB_DIR_NAME);
+            final int res = NativeLibraryHelper.copyNativeBinariesWithOverride(handle, libraryRoot,
+                    abiOverride);
+            if (res != PackageManager.INSTALL_SUCCEEDED) {
+                throw new IOException("Failed to extract native code, res=" + res);
+            }
+
+            if (!PackageHelper.finalizeSdDir(newCid)) {
+                throw new IOException("Failed to finalize " + newCid);
+            }
+
+            if (PackageHelper.isContainerMounted(newCid)) {
+                PackageHelper.unMountSdDir(newCid);
+            }
+
         } catch (ErrnoException e) {
-            Slog.e(TAG, "Could not chown APK: " + e.getMessage());
             PackageHelper.destroySdDir(newCid);
-            return null;
-        }
-
-        if (isForwardLocked) {
-            File publicZipFile = new File(newCachePath, publicResFileName);
-            try {
-                PackageHelper.extractPublicFiles(resFile.getAbsolutePath(), publicZipFile);
-                if (localLOGV) {
-                    Slog.i(TAG, "Copied resources to " + publicZipFile);
-                }
-            } catch (IOException e) {
-                Slog.e(TAG, "Could not chown public APK " + publicZipFile.getAbsolutePath() + ": "
-                        + e.getMessage());
-                PackageHelper.destroySdDir(newCid);
-                return null;
-            }
-
-            try {
-                Os.chmod(publicZipFile.getAbsolutePath(), 0644);
-            } catch (ErrnoException e) {
-                Slog.e(TAG, "Could not chown public resource file: " + e.getMessage());
-                PackageHelper.destroySdDir(newCid);
-                return null;
-            }
-        }
-
-        final File sharedLibraryDir = new File(newCachePath, LIB_DIR_NAME);
-        if (sharedLibraryDir.mkdir()) {
-            int ret = PackageManager.INSTALL_SUCCEEDED;
-            if (abis != null) {
-                // TODO(multiArch): Support multi-arch installs on asecs. Note that we are NOT
-                // using an ISA specific subdir here for now.
-                final String abi = abis[0];
-                ret = NativeLibraryHelper.copyNativeBinariesIfNeededLI(handle,
-                        sharedLibraryDir, abi);
-
-                if (ret != PackageManager.INSTALL_SUCCEEDED) {
-                    Slog.e(TAG, "Could not copy native libraries to " + sharedLibraryDir.getPath());
-                    PackageHelper.destroySdDir(newCid);
-                    return null;
-                }
-            }
-        } else {
-            Slog.e(TAG, "Could not create native lib directory: " + sharedLibraryDir.getPath());
+            throw e.rethrowAsIOException();
+        } catch (IOException e) {
             PackageHelper.destroySdDir(newCid);
-            return null;
+            throw e;
         }
 
-        if (!PackageHelper.finalizeSdDir(newCid)) {
-            Slog.e(TAG, "Failed to finalize " + newCid + " at path " + newCachePath);
-            // Clean up container
-            PackageHelper.destroySdDir(newCid);
-            return null;
-        }
-
-        if (localLOGV) {
-            Slog.i(TAG, "Finalized container " + newCid);
-        }
-
-        if (PackageHelper.isContainerMounted(newCid)) {
-            if (localLOGV) {
-                Slog.i(TAG, "Unmounting " + newCid + " at path " + newCachePath);
-            }
-
-            // Force a gc to avoid being killed.
-            Runtime.getRuntime().gc();
-            PackageHelper.unMountSdDir(newCid);
-        } else {
-            if (localLOGV) {
-                Slog.i(TAG, "Container " + newCid + " not mounted");
-            }
-        }
-
-        return newCachePath;
+        return newMountPath;
     }
 
     private int copyPackageInner(PackageLite pkg, IParcelFileDescriptorFactory target)
             throws IOException, RemoteException {
-        copyFile(pkg.baseCodePath, "base.apk", target);
+        copyFile(pkg.baseCodePath, target, "base.apk");
         if (!ArrayUtils.isEmpty(pkg.splitNames)) {
             for (int i = 0; i < pkg.splitNames.length; i++) {
-                copyFile(pkg.splitCodePaths[i], "split_" + pkg.splitNames[i] + ".apk", target);
+                copyFile(pkg.splitCodePaths[i], target, "split_" + pkg.splitNames[i] + ".apk");
             }
         }
 
         return PackageManager.INSTALL_SUCCEEDED;
     }
 
-    private void copyFile(String sourcePath, String targetName,
-            IParcelFileDescriptorFactory target) throws IOException, RemoteException {
+    private void copyFile(String sourcePath, IParcelFileDescriptorFactory target, String targetName)
+            throws IOException, RemoteException {
         Slog.d(TAG, "Copying " + sourcePath + " to " + targetName);
         InputStream in = null;
         OutputStream out = null;
@@ -523,251 +389,27 @@
         }
     }
 
-    private static final int PREFER_INTERNAL = 1;
-    private static final int PREFER_EXTERNAL = 2;
+    private void copyFile(String sourcePath, File targetDir, String targetName,
+            boolean isForwardLocked) throws IOException, ErrnoException {
+        final File sourceFile = new File(sourcePath);
+        final File targetFile = new File(targetDir, targetName);
 
-    private int recommendAppInstallLocation(PackageLite pkg, int flags, long threshold,
-            String abiOverride) {
-        int prefer;
-        boolean checkBoth = false;
-
-        final boolean isForwardLocked = (flags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
-
-        check_inner : {
-            /*
-             * Explicit install flags should override the manifest settings.
-             */
-            if ((flags & PackageManager.INSTALL_INTERNAL) != 0) {
-                prefer = PREFER_INTERNAL;
-                break check_inner;
-            } else if ((flags & PackageManager.INSTALL_EXTERNAL) != 0) {
-                prefer = PREFER_EXTERNAL;
-                break check_inner;
-            }
-
-            /* No install flags. Check for manifest option. */
-            if (pkg.installLocation == PackageInfo.INSTALL_LOCATION_INTERNAL_ONLY) {
-                prefer = PREFER_INTERNAL;
-                break check_inner;
-            } else if (pkg.installLocation == PackageInfo.INSTALL_LOCATION_PREFER_EXTERNAL) {
-                prefer = PREFER_EXTERNAL;
-                checkBoth = true;
-                break check_inner;
-            } else if (pkg.installLocation == PackageInfo.INSTALL_LOCATION_AUTO) {
-                // We default to preferring internal storage.
-                prefer = PREFER_INTERNAL;
-                checkBoth = true;
-                break check_inner;
-            }
-
-            // Pick user preference
-            int installPreference = Settings.Global.getInt(getApplicationContext()
-                    .getContentResolver(),
-                    Settings.Global.DEFAULT_INSTALL_LOCATION,
-                    PackageHelper.APP_INSTALL_AUTO);
-            if (installPreference == PackageHelper.APP_INSTALL_INTERNAL) {
-                prefer = PREFER_INTERNAL;
-                break check_inner;
-            } else if (installPreference == PackageHelper.APP_INSTALL_EXTERNAL) {
-                prefer = PREFER_EXTERNAL;
-                break check_inner;
-            }
-
-            /*
-             * Fall back to default policy of internal-only if nothing else is
-             * specified.
-             */
-            prefer = PREFER_INTERNAL;
+        Slog.d(TAG, "Copying " + sourceFile + " to " + targetFile);
+        if (!FileUtils.copyFile(sourceFile, targetFile)) {
+            throw new IOException("Failed to copy " + sourceFile + " to " + targetFile);
         }
 
-        final boolean emulated = Environment.isExternalStorageEmulated();
+        if (isForwardLocked) {
+            final String publicTargetName = PackageHelper.replaceEnd(targetName,
+                    ".apk", ".zip");
+            final File publicTargetFile = new File(targetDir, publicTargetName);
 
-        boolean fitsOnInternal = false;
-        if (checkBoth || prefer == PREFER_INTERNAL) {
-            try {
-                fitsOnInternal = isUnderInternalThreshold(pkg, isForwardLocked, threshold);
-            } catch (IOException e) {
-                return PackageHelper.RECOMMEND_FAILED_INVALID_URI;
-            }
-        }
+            PackageHelper.extractPublicFiles(sourceFile, publicTargetFile);
 
-        boolean fitsOnSd = false;
-        if (!emulated && (checkBoth || prefer == PREFER_EXTERNAL)) {
-            try {
-                fitsOnSd = isUnderExternalThreshold(pkg, isForwardLocked, abiOverride);
-            } catch (IOException e) {
-                return PackageHelper.RECOMMEND_FAILED_INVALID_URI;
-            }
-        }
-
-        if (prefer == PREFER_INTERNAL) {
-            if (fitsOnInternal) {
-                return PackageHelper.RECOMMEND_INSTALL_INTERNAL;
-            }
-        } else if (!emulated && prefer == PREFER_EXTERNAL) {
-            if (fitsOnSd) {
-                return PackageHelper.RECOMMEND_INSTALL_EXTERNAL;
-            }
-        }
-
-        if (checkBoth) {
-            if (fitsOnInternal) {
-                return PackageHelper.RECOMMEND_INSTALL_INTERNAL;
-            } else if (!emulated && fitsOnSd) {
-                return PackageHelper.RECOMMEND_INSTALL_EXTERNAL;
-            }
-        }
-
-        /*
-         * If they requested to be on the external media by default, return that
-         * the media was unavailable. Otherwise, indicate there was insufficient
-         * storage space available.
-         */
-        if (!emulated && (checkBoth || prefer == PREFER_EXTERNAL)
-                && !Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState())) {
-            return PackageHelper.RECOMMEND_MEDIA_UNAVAILABLE;
+            Os.chmod(targetFile.getAbsolutePath(), 0640);
+            Os.chmod(publicTargetFile.getAbsolutePath(), 0644);
         } else {
-            return PackageHelper.RECOMMEND_FAILED_INSUFFICIENT_STORAGE;
+            Os.chmod(targetFile.getAbsolutePath(), 0644);
         }
     }
-
-    /**
-     * Measure a file to see if it fits within the free space threshold.
-     *
-     * @param threshold byte threshold to compare against
-     * @return true if file fits under threshold
-     * @throws FileNotFoundException when APK does not exist
-     */
-    private boolean isUnderInternalThreshold(PackageLite pkg, boolean isForwardLocked,
-            long threshold) throws IOException {
-        long sizeBytes = 0;
-        for (String codePath : pkg.getAllCodePaths()) {
-            sizeBytes += new File(codePath).length();
-
-            if (isForwardLocked) {
-                sizeBytes += PackageHelper.extractPublicFiles(codePath, null);
-            }
-        }
-
-        final StatFs stat = new StatFs(Environment.getDataDirectory().getPath());
-        final long availBytes = stat.getAvailableBytes();
-        return (availBytes - sizeBytes) > threshold;
-    }
-
-    /**
-     * Measure a file to see if it fits in the external free space.
-     *
-     * @return true if file fits
-     * @throws IOException when file does not exist
-     */
-    private boolean isUnderExternalThreshold(PackageLite pkg, boolean isForwardLocked,
-            String abiOverride) throws IOException {
-        if (Environment.isExternalStorageEmulated()) {
-            return false;
-        }
-
-        final int sizeMb = calculateContainerSize(pkg, isForwardLocked, abiOverride);
-
-        final int availSdMb;
-        if (Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState())) {
-            final StatFs sdStats = new StatFs(Environment.getExternalStorageDirectory().getPath());
-            final int blocksToMb = (1 << 20) / sdStats.getBlockSize();
-            availSdMb = sdStats.getAvailableBlocks() * blocksToMb;
-        } else {
-            availSdMb = -1;
-        }
-
-        return availSdMb > sizeMb;
-    }
-
-    private int calculateContainerSize(PackageLite pkg, boolean isForwardLocked, String abiOverride)
-            throws IOException {
-        NativeLibraryHelper.Handle handle = null;
-        try {
-            handle = NativeLibraryHelper.Handle.create(pkg);
-            return calculateContainerSize(pkg, handle, isForwardLocked,
-                    calculateAbiList(handle, abiOverride, pkg.multiArch));
-        } finally {
-            IoUtils.closeQuietly(handle);
-        }
-    }
-
-    private String[] calculateAbiList(NativeLibraryHelper.Handle handle, String abiOverride,
-                                      boolean isMultiArch) throws IOException {
-        if (isMultiArch) {
-            final int abi32 = NativeLibraryHelper.findSupportedAbi(handle, Build.SUPPORTED_32_BIT_ABIS);
-            final int abi64 = NativeLibraryHelper.findSupportedAbi(handle, Build.SUPPORTED_64_BIT_ABIS);
-
-            if (abi32 >= 0 && abi64 >= 0) {
-                return new String[] { Build.SUPPORTED_64_BIT_ABIS[abi64], Build.SUPPORTED_32_BIT_ABIS[abi32] };
-            } else if (abi64 >= 0) {
-                return new String[] { Build.SUPPORTED_64_BIT_ABIS[abi64] };
-            } else if (abi32 >= 0) {
-                return new String[] { Build.SUPPORTED_32_BIT_ABIS[abi32] };
-            }
-
-            if (abi64 != PackageManager.NO_NATIVE_LIBRARIES || abi32 != PackageManager.NO_NATIVE_LIBRARIES) {
-                throw new IOException("Error determining ABI list: errorCode=[" + abi32 + "," + abi64 + "]");
-            }
-
-        } else {
-            String[] abiList = Build.SUPPORTED_ABIS;
-            if (abiOverride != null) {
-                abiList = new String[] { abiOverride };
-            } else if (Build.SUPPORTED_64_BIT_ABIS.length > 0 &&
-                    NativeLibraryHelper.hasRenderscriptBitcode(handle)) {
-                abiList = Build.SUPPORTED_32_BIT_ABIS;
-            }
-
-            final int abi = NativeLibraryHelper.findSupportedAbi(handle,abiList);
-            if (abi >= 0) {
-               return new String[]{Build.SUPPORTED_ABIS[abi]};
-            }
-
-            if (abi != PackageManager.NO_NATIVE_LIBRARIES) {
-                throw new IOException("Error determining ABI list: errorCode=" + abi);
-            }
-        }
-
-        return null;
-    }
-
-    /**
-     * Calculate the container size for a package.
-     * 
-     * @return size in megabytes (2^20 bytes)
-     * @throws IOException when there is a problem reading the file
-     */
-    private int calculateContainerSize(PackageLite pkg, NativeLibraryHelper.Handle handle,
-            boolean isForwardLocked, String[] abis) throws IOException {
-        // Calculate size of container needed to hold APKs.
-        long sizeBytes = 0;
-        for (String codePath : pkg.getAllCodePaths()) {
-            sizeBytes += new File(codePath).length();
-
-            if (isForwardLocked) {
-                sizeBytes += PackageHelper.extractPublicFiles(codePath, null);
-            }
-        }
-
-        // Check all the native files that need to be copied and add that to the
-        // container size.
-        if (abis != null) {
-            sizeBytes += NativeLibraryHelper.sumNativeBinariesLI(handle, abis);
-        }
-
-        int sizeMb = (int) (sizeBytes >> 20);
-        if ((sizeBytes - (sizeMb * 1024 * 1024)) > 0) {
-            sizeMb++;
-        }
-
-        /*
-         * Add buffer size because we don't have a good way to determine the
-         * real FAT size. Your FAT size varies with how many directory entries
-         * you need, how big the whole filesystem is, and other such headaches.
-         */
-        sizeMb++;
-
-        return sizeMb;
-    }
 }
diff --git a/packages/DocumentsUI/res/color/item_root_icon.xml b/packages/DocumentsUI/res/color/item_root_icon.xml
new file mode 100644
index 0000000..1374e61
--- /dev/null
+++ b/packages/DocumentsUI/res/color/item_root_icon.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_focused="true" android:state_activated="true" android:color="@*android:color/primary_text_default_material_dark" />
+    <item android:state_focused="false" android:state_activated="true" android:color="@*android:color/primary_text_default_material_dark" />
+    <item android:color="@*android:color/secondary_text_material_light" />
+</selector>
diff --git a/packages/DocumentsUI/res/color/item_root_primary_text.xml b/packages/DocumentsUI/res/color/item_root_primary_text.xml
new file mode 100644
index 0000000..7e703fa
--- /dev/null
+++ b/packages/DocumentsUI/res/color/item_root_primary_text.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_focused="true" android:state_activated="true" android:color="@*android:color/primary_text_default_material_dark" />
+    <item android:state_focused="false" android:state_activated="true" android:color="@*android:color/primary_text_default_material_dark" />
+    <item android:state_enabled="false" android:alpha="@*android:dimen/disabled_alpha_material_light" android:color="@*android:color/primary_text_default_material_light" />
+    <item android:color="@*android:color/primary_text_default_material_light" />
+</selector>
diff --git a/packages/DocumentsUI/res/drawable-hdpi/ic_grid_selection_check.png b/packages/DocumentsUI/res/drawable-hdpi/ic_grid_selection_check.png
new file mode 100644
index 0000000..f3007c2
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-hdpi/ic_grid_selection_check.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-mdpi/ic_grid_selection_check.png b/packages/DocumentsUI/res/drawable-mdpi/ic_grid_selection_check.png
new file mode 100644
index 0000000..16f2ab9
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-mdpi/ic_grid_selection_check.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xhdpi/ic_grid_selection_check.png b/packages/DocumentsUI/res/drawable-xhdpi/ic_grid_selection_check.png
new file mode 100644
index 0000000..0885320
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xhdpi/ic_grid_selection_check.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxhdpi/ic_grid_selection_check.png b/packages/DocumentsUI/res/drawable-xxhdpi/ic_grid_selection_check.png
new file mode 100644
index 0000000..083bbcc
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxhdpi/ic_grid_selection_check.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_breadcrumb_arrow_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_breadcrumb_arrow_am_alpha.png
new file mode 100644
index 0000000..84573f6
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_breadcrumb_arrow_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_accept_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_accept_alpha.png
new file mode 100644
index 0000000..986d3fb
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_accept_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_cancel_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_cancel_alpha.png
new file mode 100644
index 0000000..ce443f9
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_cancel_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_select_item_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_select_item_alpha.png
new file mode 100644
index 0000000..a54e0ea
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_cab_select_item_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_alert_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_alert_alpha.png
new file mode 100644
index 0000000..6e65716
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_alert_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_info_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_info_alpha.png
new file mode 100644
index 0000000..35bd56e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_dialog_info_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_album_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_album_alpha.png
new file mode 100644
index 0000000..64aa50b
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_album_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_apk_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_apk_alpha.png
new file mode 100644
index 0000000..7cbcb8b
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_apk_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_audio_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_audio_alpha.png
new file mode 100644
index 0000000..d6d79ec
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_audio_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_certificate_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_certificate_alpha.png
new file mode 100644
index 0000000..ca12928
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_certificate_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_codes_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_codes_alpha.png
new file mode 100644
index 0000000..c4afa37
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_codes_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_compressed_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_compressed_alpha.png
new file mode 100644
index 0000000..0b0aa04
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_compressed_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_contact_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_contact_am_alpha.png
new file mode 100644
index 0000000..ebd0535
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_contact_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_event_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_event_am_alpha.png
new file mode 100644
index 0000000..29cdbb7
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_event_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_excel_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_excel_alpha.png
new file mode 100644
index 0000000..ca349b6
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_excel_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_folder_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_folder_alpha.png
new file mode 100644
index 0000000..02249d2
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_folder_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_font_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_font_alpha.png
new file mode 100644
index 0000000..469b911
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_font_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_generic_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_generic_am_alpha.png
new file mode 100644
index 0000000..ef479c3
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_generic_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_image_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_image_alpha.png
new file mode 100644
index 0000000..3168d6f
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_image_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_pdf_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_pdf_alpha.png
new file mode 100644
index 0000000..9bb4d66
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_pdf_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_powerpoint_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_powerpoint_alpha.png
new file mode 100644
index 0000000..88ba9ad
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_powerpoint_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_presentation_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_presentation_alpha.png
new file mode 100644
index 0000000..5fe18da
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_presentation_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_spreadsheet_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_spreadsheet_am_alpha.png
new file mode 100644
index 0000000..1d05f6f
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_spreadsheet_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_text_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_text_am_alpha.png
new file mode 100644
index 0000000..c2308fe
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_text_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_video_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_video_am_alpha.png
new file mode 100644
index 0000000..9a173be
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_video_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_word_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_word_alpha.png
new file mode 100644
index 0000000..a564f5a
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_doc_word_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_folder_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_folder_alpha.png
new file mode 100644
index 0000000..c0c27a2
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_folder_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_folder_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_folder_alpha.png
new file mode 100644
index 0000000..ca6be0e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_folder_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_selection_check.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_selection_check.png
new file mode 100644
index 0000000..74b1ca5
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_grid_selection_check.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_hamburger_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_hamburger_alpha.png
new file mode 100644
index 0000000..13b20c6
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_hamburger_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_copy_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_copy_alpha.png
new file mode 100644
index 0000000..2dcf03e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_copy_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_delete_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_delete_alpha.png
new file mode 100644
index 0000000..07a78ed
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_delete_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_disconnect_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_disconnect_am_alpha.png
new file mode 100644
index 0000000..d7eb04f
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_disconnect_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_new_folder_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_new_folder_am_alpha.png
new file mode 100644
index 0000000..879bf45
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_new_folder_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_overflow_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_overflow_alpha.png
new file mode 100644
index 0000000..2cd4137
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_overflow_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_rename_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_rename_am_alpha.png
new file mode 100644
index 0000000..268049e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_rename_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_search_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_search_alpha.png
new file mode 100644
index 0000000..78fc61d
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_search_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_settings_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_settings_alpha.png
new file mode 100644
index 0000000..36e8e68
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_settings_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_share_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_share_alpha.png
new file mode 100644
index 0000000..68831f3
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_share_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_sortby_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_sortby_am_alpha.png
new file mode 100644
index 0000000..827a92c
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_sortby_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_undo_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_undo_am_alpha.png
new file mode 100644
index 0000000..0f12b7d
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_undo_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_grid_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_grid_alpha.png
new file mode 100644
index 0000000..df1bac1
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_grid_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_list_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_list_alpha.png
new file mode 100644
index 0000000..9420374
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_menu_view_list_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_open_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_open_am_alpha.png
new file mode 100644
index 0000000..0394c5c
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_open_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_popout_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_popout_am_alpha.png
new file mode 100644
index 0000000..325d374
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_popout_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_download_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_download_alpha.png
new file mode 100644
index 0000000..87a5210
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_download_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_folder_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_folder_am_alpha.png
new file mode 100644
index 0000000..bb41a91
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_folder_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_recent_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_recent_alpha.png
new file mode 100644
index 0000000..baa723d
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_recent_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_sdcard_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_sdcard_alpha.png
new file mode 100644
index 0000000..39c737f
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_sdcard_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_usb_light_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_usb_light_alpha.png
new file mode 100644
index 0000000..88973e0
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_root_usb_light_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable-xxxhdpi/ic_subdirectory_arrow_am_alpha.png b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_subdirectory_arrow_am_alpha.png
new file mode 100644
index 0000000..8fddb85
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable-xxxhdpi/ic_subdirectory_arrow_am_alpha.png
Binary files differ
diff --git a/packages/DocumentsUI/res/drawable/grid_protect_background.xml b/packages/DocumentsUI/res/drawable/grid_protect_background.xml
deleted file mode 100644
index 2e7aadd..0000000
--- a/packages/DocumentsUI/res/drawable/grid_protect_background.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 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.
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_enabled="false">
-        <color android:color="#88000000" />
-    </item>
-    <item>
-        <color android:color="#88252525" />
-    </item>
-</selector>
diff --git a/packages/DocumentsUI/res/drawable/item_activated_overlay.xml b/packages/DocumentsUI/res/drawable/item_activated_overlay.xml
deleted file mode 100644
index 83e4d7e..0000000
--- a/packages/DocumentsUI/res/drawable/item_activated_overlay.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 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.
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
-    <item android:state_focused="true" android:state_activated="true">
-        <color android:color="@color/accent_color_overlay" />
-    </item>
-    <item android:state_focused="false" android:state_activated="true">
-        <color android:color="@color/accent_color_overlay" />
-    </item>
-    <item android:drawable="@android:color/transparent" />
-</selector>
diff --git a/packages/DocumentsUI/res/drawable/item_doc_grid_overlay.xml b/packages/DocumentsUI/res/drawable/item_doc_grid_overlay.xml
new file mode 100644
index 0000000..3fbd25e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable/item_doc_grid_overlay.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_focused="true" android:state_activated="true" android:drawable="@color/item_doc_grid_overlay_activated" />
+    <item android:state_focused="false" android:state_activated="true" android:drawable="@color/item_doc_grid_overlay_activated" />
+    <item android:state_enabled="false" android:drawable="@color/item_doc_grid_overlay_disabled" />
+    <item android:drawable="@android:color/transparent" />
+</selector>
diff --git a/packages/DocumentsUI/res/drawable/item_doc_grid_overlay_icon.xml b/packages/DocumentsUI/res/drawable/item_doc_grid_overlay_icon.xml
new file mode 100644
index 0000000..d40de1e
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable/item_doc_grid_overlay_icon.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android" android:constantSize="true">
+    <item android:state_focused="true" android:state_activated="true" android:drawable="@drawable/ic_grid_selection_check" />
+    <item android:state_focused="false" android:state_activated="true" android:drawable="@drawable/ic_grid_selection_check" />
+    <item android:drawable="@android:color/transparent" />
+</selector>
diff --git a/packages/DocumentsUI/res/drawable/item_doc_list_background.xml b/packages/DocumentsUI/res/drawable/item_doc_list_background.xml
new file mode 100644
index 0000000..b879542
--- /dev/null
+++ b/packages/DocumentsUI/res/drawable/item_doc_list_background.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- 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.
+-->
+
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
+    <item android:state_focused="true" android:state_activated="true" android:drawable="@color/item_doc_list_background_activated" />
+    <item android:state_focused="false" android:state_activated="true" android:drawable="@color/item_doc_list_background_activated" />
+    <item android:drawable="@android:color/transparent" />
+</selector>
diff --git a/packages/DocumentsUI/res/drawable/item_activated.xml b/packages/DocumentsUI/res/drawable/item_root_background.xml
similarity index 100%
rename from packages/DocumentsUI/res/drawable/item_activated.xml
rename to packages/DocumentsUI/res/drawable/item_root_background.xml
diff --git a/packages/DocumentsUI/res/layout-sw720dp-land/item_doc_list.xml b/packages/DocumentsUI/res/layout-sw720dp-land/item_doc_list.xml
index 95af7e9..d124320 100644
--- a/packages/DocumentsUI/res/layout-sw720dp-land/item_doc_list.xml
+++ b/packages/DocumentsUI/res/layout-sw720dp-land/item_doc_list.xml
@@ -17,7 +17,7 @@
 <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
-    android:background="@drawable/item_activated">
+    android:background="@drawable/item_doc_list_background">
 
     <LinearLayout
         android:layout_width="match_parent"
diff --git a/packages/DocumentsUI/res/layout-sw720dp/activity.xml b/packages/DocumentsUI/res/layout-sw720dp/activity.xml
index c33932d..1cffd17 100644
--- a/packages/DocumentsUI/res/layout-sw720dp/activity.xml
+++ b/packages/DocumentsUI/res/layout-sw720dp/activity.xml
@@ -54,7 +54,7 @@
             android:layout_weight="1"
             android:orientation="vertical"
             android:elevation="8dp"
-            android:background="@*android:color/material_grey_50">
+            android:background="@color/material_grey_50">
 
             <com.android.documentsui.DirectoryContainerView
                 android:id="@+id/container_directory"
@@ -66,7 +66,7 @@
                 android:id="@+id/container_save"
                 android:layout_width="match_parent"
                 android:layout_height="wrap_content"
-                android:background="@*android:color/material_grey_50"
+                android:background="@color/material_grey_50"
                 android:elevation="8dp" />
 
         </LinearLayout>
diff --git a/packages/DocumentsUI/res/layout/activity.xml b/packages/DocumentsUI/res/layout/activity.xml
index d580821..120168e 100644
--- a/packages/DocumentsUI/res/layout/activity.xml
+++ b/packages/DocumentsUI/res/layout/activity.xml
@@ -51,7 +51,7 @@
             android:id="@+id/container_save"
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:background="@*android:color/material_grey_50"
+            android:background="@color/material_grey_50"
             android:elevation="8dp" />
 
     </LinearLayout>
diff --git a/packages/DocumentsUI/res/layout/fragment_directory.xml b/packages/DocumentsUI/res/layout/fragment_directory.xml
index c8c707e..4717839 100644
--- a/packages/DocumentsUI/res/layout/fragment_directory.xml
+++ b/packages/DocumentsUI/res/layout/fragment_directory.xml
@@ -17,7 +17,7 @@
 <com.android.documentsui.DirectoryView xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
-    android:background="@*android:color/material_grey_50">
+    android:background="@color/material_grey_50">
 
     <TextView
         android:id="@android:id/empty"
diff --git a/packages/DocumentsUI/res/layout/item_doc_grid.xml b/packages/DocumentsUI/res/layout/item_doc_grid.xml
index bdb3184..d62d050 100644
--- a/packages/DocumentsUI/res/layout/item_doc_grid.xml
+++ b/packages/DocumentsUI/res/layout/item_doc_grid.xml
@@ -17,9 +17,7 @@
 <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="@dimen/grid_item_height"
-    android:orientation="vertical"
-    android:background="@color/grid_item_background"
-    android:foreground="@drawable/item_activated_overlay">
+    android:background="@color/item_doc_grid_background">
 
     <ImageView
         android:id="@+id/icon_thumb"
@@ -44,7 +42,7 @@
         <LinearLayout
             android:layout_width="match_parent"
             android:layout_height="wrap_content"
-            android:background="@drawable/grid_protect_background"
+            android:background="@color/item_doc_grid_protect_background"
             android:orientation="vertical"
             android:paddingStart="16dp"
             android:paddingEnd="12dp"
@@ -68,7 +66,7 @@
                     android:ellipsize="middle"
                     android:textAlignment="viewStart"
                     android:textAppearance="@android:style/TextAppearance.Material.Subhead"
-                    android:textColor="?android:attr/textColorPrimaryInverse" />
+                    android:textColor="@*android:color/primary_text_default_material_dark" />
 
                 <ImageView
                     android:id="@android:id/icon1"
@@ -97,7 +95,7 @@
                     android:ellipsize="end"
                     android:textAlignment="viewStart"
                     android:textAppearance="@android:style/TextAppearance.Material.Caption"
-                    android:textColor="?android:attr/textColorPrimaryInverse" />
+                    android:textColor="@*android:color/primary_text_default_material_dark" />
 
                 <TextView
                     android:id="@+id/size"
@@ -109,7 +107,7 @@
                     android:ellipsize="end"
                     android:textAlignment="viewStart"
                     android:textAppearance="@android:style/TextAppearance.Material.Caption"
-                    android:textColor="?android:attr/textColorPrimaryInverse" />
+                    android:textColor="@*android:color/primary_text_default_material_dark" />
 
                 <ImageView
                     android:id="@android:id/icon2"
@@ -126,4 +124,19 @@
 
     </LinearLayout>
 
+    <ImageView
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:src="@drawable/item_doc_grid_overlay"
+        android:contentDescription="@null"
+        android:duplicateParentState="true" />
+
+    <ImageView
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:src="@drawable/item_doc_grid_overlay_icon"
+        android:scaleType="center"
+        android:contentDescription="@null"
+        android:duplicateParentState="true" />
+
 </FrameLayout>
diff --git a/packages/DocumentsUI/res/layout/item_doc_list.xml b/packages/DocumentsUI/res/layout/item_doc_list.xml
index c5f1842..c576669 100644
--- a/packages/DocumentsUI/res/layout/item_doc_list.xml
+++ b/packages/DocumentsUI/res/layout/item_doc_list.xml
@@ -17,7 +17,7 @@
 <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
-    android:background="@drawable/item_activated">
+    android:background="@drawable/item_doc_list_background">
 
     <LinearLayout
         android:layout_width="match_parent"
diff --git a/packages/DocumentsUI/res/layout/item_root.xml b/packages/DocumentsUI/res/layout/item_root.xml
index 266b9b0..bd83923 100644
--- a/packages/DocumentsUI/res/layout/item_root.xml
+++ b/packages/DocumentsUI/res/layout/item_root.xml
@@ -23,19 +23,21 @@
     android:gravity="center_vertical"
     android:orientation="horizontal"
     android:baselineAligned="false"
-    android:background="@drawable/item_activated">
+    android:background="@drawable/item_root_background">
 
     <FrameLayout
         android:layout_width="@dimen/icon_size"
         android:layout_height="@dimen/icon_size"
-        android:layout_marginEnd="16dp">
+        android:layout_marginEnd="16dp"
+        android:duplicateParentState="true">
 
         <ImageView
             android:id="@android:id/icon"
             android:layout_width="@dimen/root_icon_size"
             android:layout_height="match_parent"
             android:scaleType="centerInside"
-            android:contentDescription="@null" />
+            android:contentDescription="@null"
+            android:duplicateParentState="true" />
 
     </FrameLayout>
 
@@ -54,7 +56,7 @@
             android:ellipsize="end"
             android:textAlignment="viewStart"
             android:textAppearance="@android:style/TextAppearance.Material.Body1"
-            android:textColor="?android:attr/textColorPrimary" />
+            android:textColor="@color/item_root_primary_text" />
 
         <TextView
             android:id="@android:id/summary"
@@ -64,7 +66,7 @@
             android:ellipsize="end"
             android:textAlignment="viewStart"
             android:textAppearance="@android:style/TextAppearance.Material.Body1"
-            android:textColor="?android:attr/textColorSecondary" />
+            android:textColor="@color/item_root_primary_text" />
 
     </LinearLayout>
 
diff --git a/packages/DocumentsUI/res/values-cs/strings.xml b/packages/DocumentsUI/res/values-cs/strings.xml
index b08fdab..36bb72f 100644
--- a/packages/DocumentsUI/res/values-cs/strings.xml
+++ b/packages/DocumentsUI/res/values-cs/strings.xml
@@ -17,10 +17,10 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2783841764617238354">"Dokumenty"</string>
-    <string name="title_open" msgid="4353228937663917801">"Otevřít z"</string>
+    <string name="title_open" msgid="4353228937663917801">"Otevřít"</string>
     <string name="title_save" msgid="2433679664882857999">"Uložit do"</string>
     <string name="menu_create_dir" msgid="5947289605844398389">"Vytvořit složku"</string>
-    <string name="menu_grid" msgid="6878021334497835259">"Mřížka"</string>
+    <string name="menu_grid" msgid="6878021334497835259">"Mřížkové zobrazení"</string>
     <string name="menu_list" msgid="7279285939892417279">"Seznam"</string>
     <string name="menu_sort" msgid="7677740407158414452">"Řadit podle"</string>
     <string name="menu_search" msgid="3816712084502856974">"Hledat"</string>
@@ -34,7 +34,7 @@
     <string name="menu_advanced_show" product="default" msgid="5792182900084144261">"Zobrazit SD kartu"</string>
     <string name="menu_advanced_hide" product="nosdcard" msgid="4218809952721972589">"Skrýt interní úložiště"</string>
     <string name="menu_advanced_hide" product="default" msgid="4845869969015718848">"Skrýt SD kartu"</string>
-    <string name="menu_file_size_show" msgid="3240323619260823076">"Zobr. velikost souboru"</string>
+    <string name="menu_file_size_show" msgid="3240323619260823076">"Zobrazit velikost souboru"</string>
     <string name="menu_file_size_hide" msgid="8881975928502581042">"Skrýt velikost souboru"</string>
     <string name="mode_selected_count" msgid="459111894725594625">"Vybráno: <xliff:g id="COUNT">%1$d</xliff:g>"</string>
     <string name="sort_name" msgid="9183560467917256779">"Podle názvu"</string>
diff --git a/packages/DocumentsUI/res/values-hi/strings.xml b/packages/DocumentsUI/res/values-hi/strings.xml
index c4dc652..e4967e1 100644
--- a/packages/DocumentsUI/res/values-hi/strings.xml
+++ b/packages/DocumentsUI/res/values-hi/strings.xml
@@ -30,9 +30,9 @@
     <string name="menu_share" msgid="3075149983979628146">"साझा करें"</string>
     <string name="menu_delete" msgid="8138799623850614177">"हटाएं"</string>
     <string name="menu_select" msgid="8711270657353563424">"\"<xliff:g id="DIRECTORY">^1</xliff:g>\" चुनें"</string>
-    <string name="menu_advanced_show" product="nosdcard" msgid="4693652895715631401">"आंतरिक संग्रहण दिखाएं"</string>
+    <string name="menu_advanced_show" product="nosdcard" msgid="4693652895715631401">"आंतरिक मेमोरी दिखाएं"</string>
     <string name="menu_advanced_show" product="default" msgid="5792182900084144261">"SD कार्ड दिखाएं"</string>
-    <string name="menu_advanced_hide" product="nosdcard" msgid="4218809952721972589">"आंतरिक संग्रहण छिपाएं"</string>
+    <string name="menu_advanced_hide" product="nosdcard" msgid="4218809952721972589">"आंतरिक मेमोरी छिपाएं"</string>
     <string name="menu_advanced_hide" product="default" msgid="4845869969015718848">"SD कार्ड छिपाएं"</string>
     <string name="menu_file_size_show" msgid="3240323619260823076">"फ़ाइल आकार दिखाएं"</string>
     <string name="menu_file_size_hide" msgid="8881975928502581042">"फ़ाइल आकार छिपाएं"</string>
@@ -46,8 +46,8 @@
     <string name="create_error" msgid="3735649141335444215">"फ़ोल्डर बनाने में विफल"</string>
     <string name="query_error" msgid="1222448261663503501">"दस्तावेजों के लिए क्वेरी करने में विफल रहा"</string>
     <string name="root_recent" msgid="4470053704320518133">"हाल ही के"</string>
-    <string name="root_available_bytes" msgid="8568452858617033281">"<xliff:g id="SIZE">%1$s</xliff:g> रिक्त"</string>
-    <string name="root_type_service" msgid="2178854894416775409">"संग्रहण सेवाएं"</string>
+    <string name="root_available_bytes" msgid="8568452858617033281">"<xliff:g id="SIZE">%1$s</xliff:g> खाली"</string>
+    <string name="root_type_service" msgid="2178854894416775409">"मेमोरी सेवाएं"</string>
     <string name="root_type_shortcut" msgid="3318760609471618093">"शॉर्टकट"</string>
     <string name="root_type_device" msgid="7121342474653483538">"उपकरण"</string>
     <string name="root_type_apps" msgid="8838065367985945189">"अधिक ऐप्स"</string>
diff --git a/packages/DocumentsUI/res/values-km-rKH/strings.xml b/packages/DocumentsUI/res/values-km-rKH/strings.xml
index bc03c87..3055001 100644
--- a/packages/DocumentsUI/res/values-km-rKH/strings.xml
+++ b/packages/DocumentsUI/res/values-km-rKH/strings.xml
@@ -20,14 +20,14 @@
     <string name="title_open" msgid="4353228937663917801">"បើក​ពី"</string>
     <string name="title_save" msgid="2433679664882857999">"រក្សា​ទុក​ទៅ"</string>
     <string name="menu_create_dir" msgid="5947289605844398389">"បង្កើត​ថត"</string>
-    <string name="menu_grid" msgid="6878021334497835259">"ទិដ្ឋភាព​ក្រឡា"</string>
+    <string name="menu_grid" msgid="6878021334497835259">"ទិដ្ឋភាព​ក្រឡា​"</string>
     <string name="menu_list" msgid="7279285939892417279">"ទិដ្ឋភាព​បញ្ជី"</string>
     <string name="menu_sort" msgid="7677740407158414452">"តម្រៀប​តាម"</string>
     <string name="menu_search" msgid="3816712084502856974">"ស្វែងរក"</string>
     <string name="menu_settings" msgid="6008033148948428823">"ការ​កំណត់"</string>
     <string name="menu_open" msgid="432922957274920903">"បើក"</string>
     <string name="menu_save" msgid="2394743337684426338">"រក្សាទុក"</string>
-    <string name="menu_share" msgid="3075149983979628146">"ចែករំលែក"</string>
+    <string name="menu_share" msgid="3075149983979628146">"ចែករំលែក​"</string>
     <string name="menu_delete" msgid="8138799623850614177">"លុប"</string>
     <string name="menu_select" msgid="8711270657353563424">"ជ្រើស \"<xliff:g id="DIRECTORY">^1</xliff:g>\""</string>
     <string name="menu_advanced_show" product="nosdcard" msgid="4693652895715631401">"បង្ហាញឧបករណ៍ផ្ទុកខាងក្នុង"</string>
@@ -51,7 +51,7 @@
     <string name="root_type_shortcut" msgid="3318760609471618093">"ផ្លូវកាត់"</string>
     <string name="root_type_device" msgid="7121342474653483538">"ឧបករណ៍"</string>
     <string name="root_type_apps" msgid="8838065367985945189">"កម្ម​វិធី​​ច្រើន​ទៀត"</string>
-    <string name="empty" msgid="7858882803708117596">"គ្មានធាតុ"</string>
+    <string name="empty" msgid="7858882803708117596">"គ្មានធាតុ​"</string>
     <string name="toast_no_application" msgid="1339885974067891667">"មិន​អាច​បើក​ឯកសារ"</string>
     <string name="toast_failed_delete" msgid="2180678019407244069">"មិន​អាច​លុប​ឯកសារ​មួយ​ចំនួន"</string>
     <string name="share_via" msgid="8966594246261344259">"ចែករំលែក​តាម"</string>
diff --git a/packages/DocumentsUI/res/values-my-rMM/strings.xml b/packages/DocumentsUI/res/values-my-rMM/strings.xml
index 98b3a90..50f8363 100644
--- a/packages/DocumentsUI/res/values-my-rMM/strings.xml
+++ b/packages/DocumentsUI/res/values-my-rMM/strings.xml
@@ -26,7 +26,7 @@
     <string name="menu_search" msgid="3816712084502856974">"ရှာဖွေရန်"</string>
     <string name="menu_settings" msgid="6008033148948428823">"ဆက်တင်များ"</string>
     <string name="menu_open" msgid="432922957274920903">"ဖွင့်ရန်"</string>
-    <string name="menu_save" msgid="2394743337684426338">"သိမ်းဆည်းရန်"</string>
+    <string name="menu_save" msgid="2394743337684426338">"သိမ်းပါ"</string>
     <string name="menu_share" msgid="3075149983979628146">"မျှဝေခြင်း"</string>
     <string name="menu_delete" msgid="8138799623850614177">"ဖျက်ပစ်ရန်"</string>
     <string name="menu_select" msgid="8711270657353563424">"ရွေးရန်\"<xliff:g id="DIRECTORY">^1</xliff:g>\""</string>
diff --git a/packages/DocumentsUI/res/values-zh-rTW/strings.xml b/packages/DocumentsUI/res/values-zh-rTW/strings.xml
index a37dbe8..464a13e 100644
--- a/packages/DocumentsUI/res/values-zh-rTW/strings.xml
+++ b/packages/DocumentsUI/res/values-zh-rTW/strings.xml
@@ -45,7 +45,7 @@
     <string name="save_error" msgid="6167009778003223664">"無法儲存文件"</string>
     <string name="create_error" msgid="3735649141335444215">"無法建立資料夾"</string>
     <string name="query_error" msgid="1222448261663503501">"無法查詢文件"</string>
-    <string name="root_recent" msgid="4470053704320518133">"最近存取過"</string>
+    <string name="root_recent" msgid="4470053704320518133">"最近"</string>
     <string name="root_available_bytes" msgid="8568452858617033281">"可用空間:<xliff:g id="SIZE">%1$s</xliff:g>"</string>
     <string name="root_type_service" msgid="2178854894416775409">"儲存空間服務"</string>
     <string name="root_type_shortcut" msgid="3318760609471618093">"捷徑"</string>
diff --git a/packages/DocumentsUI/res/values/colors.xml b/packages/DocumentsUI/res/values/colors.xml
index 08159c4..2ceb968 100644
--- a/packages/DocumentsUI/res/values/colors.xml
+++ b/packages/DocumentsUI/res/values/colors.xml
@@ -15,10 +15,19 @@
 -->
 
 <resources>
+    <color name="material_grey_50">#fffafafa</color>
+    <color name="material_grey_300">#ffeeeeee</color>
 
-    <!-- Half-alpha of material_teal_500 -->
-    <color name="accent_color_overlay">#8800bcd4</color>
+    <color name="item_doc_grid_background">@color/material_grey_300</color>
 
-    <color name="grid_item_background">@*android:color/material_grey_300</color>
+    <color name="item_doc_grid_protect_background">#88000000</color>
+
+    <color name="item_doc_grid_overlay_activated">#88000000</color>
+    <color name="item_doc_grid_overlay_disabled">#88ffffff</color>
+
+    <color name="item_doc_list_overlay_disabled">#88ffffff</color>
+
+    <!-- 10% alpha of material_deep_teal_500 -->
+    <color name="item_doc_list_background_activated">#1a009688</color>
 
 </resources>
diff --git a/packages/DocumentsUI/res/values/styles.xml b/packages/DocumentsUI/res/values/styles.xml
index 573081c..04692f6 100644
--- a/packages/DocumentsUI/res/values/styles.xml
+++ b/packages/DocumentsUI/res/values/styles.xml
@@ -25,9 +25,12 @@
 
         <item name="android:colorPrimaryDark">@*android:color/material_blue_grey_900</item>
         <item name="android:colorPrimary">@*android:color/material_blue_grey_800</item>
-        <item name="android:colorAccent">@*android:color/material_teal_500</item>
+        <item name="android:colorAccent">@*android:color/material_deep_teal_500</item>
+
+        <item name="android:listDivider">@*android:drawable/list_divider_material</item>
 
         <item name="android:windowActionBar">false</item>
+        <item name="android:windowActionModeOverlay">true</item>
         <item name="android:windowNoTitle">true</item>
 
         <item name="*android:windowFixedWidthMajor">@null</item>
diff --git a/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java b/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
index caa07ab..39c2252 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/DirectoryFragment.java
@@ -807,6 +807,9 @@
                     || MimePredicate.mimeMatches(MimePredicate.VISUAL_MIMES, docMimeType);
             final boolean showThumbnail = supportsThumbnail && allowThumbnail && !mSvelteRecents;
 
+            final boolean enabled = isDocumentEnabled(docMimeType, docFlags);
+            final float iconAlpha = (state.derivedMode == MODE_LIST && !enabled) ? 0.5f : 1f;
+
             boolean cacheHit = false;
             if (showThumbnail) {
                 final Uri uri = DocumentsContract.buildDocumentUri(docAuthority, docId);
@@ -817,7 +820,7 @@
                 } else {
                     iconThumb.setImageDrawable(null);
                     final ThumbnailAsyncTask task = new ThumbnailAsyncTask(
-                            uri, iconMime, iconThumb, mThumbSize);
+                            uri, iconMime, iconThumb, mThumbSize, iconAlpha);
                     iconThumb.setTag(task);
                     ProviderExecutor.forAuthority(docAuthority).execute(task);
                 }
@@ -886,7 +889,7 @@
                 // hint to remind user they're a directory.
                 if (Document.MIME_TYPE_DIR.equals(docMimeType) && state.derivedMode == MODE_GRID
                         && showThumbnail) {
-                    iconDrawable = IconUtils.applyTint(context, R.drawable.ic_doc_folder,
+                    iconDrawable = IconUtils.applyTintAttr(context, R.drawable.ic_doc_folder,
                             android.R.attr.textColorPrimaryInverse);
                 }
 
@@ -940,20 +943,12 @@
                 line2.setVisibility(hasLine2 ? View.VISIBLE : View.GONE);
             }
 
-            final boolean enabled = isDocumentEnabled(docMimeType, docFlags);
-            if (enabled) {
-                setEnabledRecursive(convertView, true);
-                iconMime.setAlpha(1f);
-                iconThumb.setAlpha(1f);
-                if (icon1 != null) icon1.setAlpha(1f);
-                if (icon2 != null) icon2.setAlpha(1f);
-            } else {
-                setEnabledRecursive(convertView, false);
-                iconMime.setAlpha(0.5f);
-                iconThumb.setAlpha(0.5f);
-                if (icon1 != null) icon1.setAlpha(0.5f);
-                if (icon2 != null) icon2.setAlpha(0.5f);
-            }
+            setEnabledRecursive(convertView, enabled);
+
+            iconMime.setAlpha(iconAlpha);
+            iconThumb.setAlpha(iconAlpha);
+            if (icon1 != null) icon1.setAlpha(iconAlpha);
+            if (icon2 != null) icon2.setAlpha(iconAlpha);
 
             return convertView;
         }
@@ -1000,14 +995,16 @@
         private final ImageView mIconMime;
         private final ImageView mIconThumb;
         private final Point mThumbSize;
+        private final float mTargetAlpha;
         private final CancellationSignal mSignal;
 
-        public ThumbnailAsyncTask(
-                Uri uri, ImageView iconMime, ImageView iconThumb, Point thumbSize) {
+        public ThumbnailAsyncTask(Uri uri, ImageView iconMime, ImageView iconThumb, Point thumbSize,
+                float targetAlpha) {
             mUri = uri;
             mIconMime = iconMime;
             mIconThumb = iconThumb;
             mThumbSize = thumbSize;
+            mTargetAlpha = targetAlpha;
             mSignal = new CancellationSignal();
         }
 
@@ -1051,11 +1048,10 @@
                 mIconThumb.setTag(null);
                 mIconThumb.setImageBitmap(result);
 
-                final float targetAlpha = mIconMime.isEnabled() ? 1f : 0.5f;
-                mIconMime.setAlpha(targetAlpha);
+                mIconMime.setAlpha(mTargetAlpha);
                 mIconMime.animate().alpha(0f).start();
                 mIconThumb.setAlpha(0f);
-                mIconThumb.animate().alpha(targetAlpha).start();
+                mIconThumb.animate().alpha(mTargetAlpha).start();
             }
         }
     }
diff --git a/packages/DocumentsUI/src/com/android/documentsui/IconUtils.java b/packages/DocumentsUI/src/com/android/documentsui/IconUtils.java
index b2e38fc..416aeb0 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/IconUtils.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/IconUtils.java
@@ -266,15 +266,16 @@
         }
     }
 
-    public static Drawable applyTint(Context context, int drawableId, int tintAttrId) {
-        final Resources res = context.getResources();
-
-        final TypedValue outValue = new TypedValue();
-        context.getTheme().resolveAttribute(tintAttrId, outValue, true);
-
+    public static Drawable applyTintColor(Context context, int drawableId, int tintColorId) {
         final Drawable icon = context.getDrawable(drawableId);
         icon.mutate();
-        icon.setTintList(res.getColorStateList(outValue.resourceId));
+        icon.setTintList(context.getResources().getColorStateList(tintColorId));
         return icon;
     }
+
+    public static Drawable applyTintAttr(Context context, int drawableId, int tintAttrId) {
+        final TypedValue outValue = new TypedValue();
+        context.getTheme().resolveAttribute(tintAttrId, outValue, true);
+        return applyTintColor(context, drawableId, outValue.resourceId);
+    }
 }
diff --git a/packages/DocumentsUI/src/com/android/documentsui/RootsCache.java b/packages/DocumentsUI/src/com/android/documentsui/RootsCache.java
index a465ecd..d72db1d 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/RootsCache.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/RootsCache.java
@@ -58,7 +58,7 @@
  * Cache of known storage backends and their roots.
  */
 public class RootsCache {
-    private static final boolean LOGD = true;
+    private static final boolean LOGD = false;
 
     public static final Uri sNotificationUri = Uri.parse(
             "content://com.android.documentsui.roots/");
@@ -116,9 +116,6 @@
      * Gather roots from storage providers belonging to given package name.
      */
     public void updatePackageAsync(String packageName) {
-        // Need at least first load, since we're going to be using previously
-        // cached values for non-matching packages.
-        waitForFirstLoad();
         new UpdateTask(packageName).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR);
     }
 
@@ -183,6 +180,12 @@
         protected Void doInBackground(Void... params) {
             final long start = SystemClock.elapsedRealtime();
 
+            if (mFilterPackage != null) {
+                // Need at least first load, since we're going to be using
+                // previously cached values for non-matching packages.
+                waitForFirstLoad();
+            }
+
             mTaskRoots.put(mRecentsRoot.authority, mRecentsRoot);
 
             final ContentResolver resolver = mContext.getContentResolver();
diff --git a/packages/DocumentsUI/src/com/android/documentsui/RootsFragment.java b/packages/DocumentsUI/src/com/android/documentsui/RootsFragment.java
index b19e028..884cf31 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/RootsFragment.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/RootsFragment.java
@@ -235,7 +235,7 @@
             final TextView summary = (TextView) convertView.findViewById(android.R.id.summary);
 
             final Context context = convertView.getContext();
-            icon.setImageDrawable(root.loadIcon(context));
+            icon.setImageDrawable(root.loadDrawerIcon(context));
             title.setText(root.title);
 
             // Show available space if no summary
diff --git a/packages/DocumentsUI/src/com/android/documentsui/model/RootInfo.java b/packages/DocumentsUI/src/com/android/documentsui/model/RootInfo.java
index fcfe518..97d8ed0 100644
--- a/packages/DocumentsUI/src/com/android/documentsui/model/RootInfo.java
+++ b/packages/DocumentsUI/src/com/android/documentsui/model/RootInfo.java
@@ -211,9 +211,17 @@
         }
     }
 
+    public Drawable loadDrawerIcon(Context context) {
+        if (derivedIcon != 0) {
+            return IconUtils.applyTintColor(context, derivedIcon, R.color.item_root_icon);
+        } else {
+            return IconUtils.loadPackageIcon(context, authority, icon);
+        }
+    }
+
     public Drawable loadGridIcon(Context context) {
         if (derivedIcon != 0) {
-            return IconUtils.applyTint(context, derivedIcon,
+            return IconUtils.applyTintAttr(context, derivedIcon,
                     android.R.attr.textColorPrimaryInverse);
         } else {
             return IconUtils.loadPackageIcon(context, authority, icon);
@@ -222,7 +230,7 @@
 
     public Drawable loadToolbarIcon(Context context) {
         if (derivedIcon != 0) {
-            return IconUtils.applyTint(context, derivedIcon,
+            return IconUtils.applyTintAttr(context, derivedIcon,
                     android.R.attr.colorControlNormal);
         } else {
             return IconUtils.loadPackageIcon(context, authority, icon);
diff --git a/packages/ExternalStorageProvider/res/values-hi/strings.xml b/packages/ExternalStorageProvider/res/values-hi/strings.xml
index 1227bd4..8538081 100644
--- a/packages/ExternalStorageProvider/res/values-hi/strings.xml
+++ b/packages/ExternalStorageProvider/res/values-hi/strings.xml
@@ -16,7 +16,7 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="7123375275748530234">"बाहरी संग्रहण"</string>
-    <string name="root_internal_storage" msgid="827844243068584127">"मोबाइल संग्रहण"</string>
+    <string name="app_label" msgid="7123375275748530234">"बाहरी मेमोरी"</string>
+    <string name="root_internal_storage" msgid="827844243068584127">"मोबाइल मेमोरी"</string>
     <string name="root_documents" msgid="4051252304075469250">"दस्तावेज़"</string>
 </resources>
diff --git a/packages/ExternalStorageProvider/res/values-my-rMM/strings.xml b/packages/ExternalStorageProvider/res/values-my-rMM/strings.xml
index 643fb92..dc9d684 100644
--- a/packages/ExternalStorageProvider/res/values-my-rMM/strings.xml
+++ b/packages/ExternalStorageProvider/res/values-my-rMM/strings.xml
@@ -17,6 +17,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="7123375275748530234">"ပြင်ပသိုလှောင်ရာပစ္စည်း"</string>
-    <string name="root_internal_storage" msgid="827844243068584127">"စက်အတွင်းသိမ်းဆည်းရန်နေရာ"</string>
+    <string name="root_internal_storage" msgid="827844243068584127">"စက်တွင်း သိုလှောင်ထားမှု"</string>
     <string name="root_documents" msgid="4051252304075469250">"စာရွက်စာတန်းများ"</string>
 </resources>
diff --git a/packages/Keyguard/res/drawable-hdpi/ic_lockscreen_ime.png b/packages/Keyguard/res/drawable-hdpi/ic_lockscreen_ime.png
deleted file mode 100644
index 29a7989..0000000
--- a/packages/Keyguard/res/drawable-hdpi/ic_lockscreen_ime.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable-hdpi/kg_bouncer_bg_white.9.png b/packages/Keyguard/res/drawable-hdpi/kg_bouncer_bg_white.9.png
deleted file mode 100644
index cfd5db3..0000000
--- a/packages/Keyguard/res/drawable-hdpi/kg_bouncer_bg_white.9.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable-mdpi/ic_lockscreen_ime.png b/packages/Keyguard/res/drawable-mdpi/ic_lockscreen_ime.png
deleted file mode 100644
index b27e059..0000000
--- a/packages/Keyguard/res/drawable-mdpi/ic_lockscreen_ime.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable-mdpi/kg_bouncer_bg_white.9.png b/packages/Keyguard/res/drawable-mdpi/kg_bouncer_bg_white.9.png
deleted file mode 100644
index e3cb6db..0000000
--- a/packages/Keyguard/res/drawable-mdpi/kg_bouncer_bg_white.9.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable-xhdpi/ic_lockscreen_ime.png b/packages/Keyguard/res/drawable-xhdpi/ic_lockscreen_ime.png
deleted file mode 100644
index a40ddeb..0000000
--- a/packages/Keyguard/res/drawable-xhdpi/ic_lockscreen_ime.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable-xhdpi/kg_bouncer_bg_white.9.png b/packages/Keyguard/res/drawable-xhdpi/kg_bouncer_bg_white.9.png
deleted file mode 100644
index b9e30e2..0000000
--- a/packages/Keyguard/res/drawable-xhdpi/kg_bouncer_bg_white.9.png
+++ /dev/null
Binary files differ
diff --git a/packages/Keyguard/res/drawable/ic_lockscreen_ime.xml b/packages/Keyguard/res/drawable/ic_lockscreen_ime.xml
new file mode 100644
index 0000000..49be7dc
--- /dev/null
+++ b/packages/Keyguard/res/drawable/ic_lockscreen_ime.xml
@@ -0,0 +1,24 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M20.000000,5.000000L4.000000,5.000000C2.900000,5.000000 2.000000,5.900000 2.000000,7.000000l0.000000,10.000000c0.000000,1.100000 0.900000,2.000000 2.000000,2.000000l16.000000,0.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L22.000000,7.000000C22.000000,5.900000 21.100000,5.000000 20.000000,5.000000zM11.000000,8.000000l2.000000,0.000000l0.000000,2.000000l-2.000000,0.000000L11.000000,8.000000zM11.000000,11.000000l2.000000,0.000000l0.000000,2.000000l-2.000000,0.000000L11.000000,11.000000zM8.000000,8.000000l2.000000,0.000000l0.000000,2.000000L8.000000,10.000000L8.000000,8.000000zM8.000000,11.000000l2.000000,0.000000l0.000000,2.000000L8.000000,13.000000L8.000000,11.000000zM7.000000,13.000000L5.000000,13.000000l0.000000,-2.000000l2.000000,0.000000L7.000000,13.000000zM7.000000,10.000000L5.000000,10.000000L5.000000,8.000000l2.000000,0.000000L7.000000,10.000000zM16.000000,17.000000L8.000000,17.000000l0.000000,-2.000000l8.000000,0.000000L16.000000,17.000000zM16.000000,13.000000l-2.000000,0.000000l0.000000,-2.000000l2.000000,0.000000L16.000000,13.000000zM16.000000,10.000000l-2.000000,0.000000L14.000000,8.000000l2.000000,0.000000L16.000000,10.000000zM19.000000,13.000000l-2.000000,0.000000l0.000000,-2.000000l2.000000,0.000000L19.000000,13.000000zM19.000000,10.000000l-2.000000,0.000000L17.000000,8.000000l2.000000,0.000000L19.000000,10.000000z"
+        android:fillColor="#FFFFFFFF"/>
+</vector>
diff --git a/packages/Keyguard/res/layout/keyguard_bouncer.xml b/packages/Keyguard/res/layout/keyguard_bouncer.xml
index c85f04c..3c1f65e 100644
--- a/packages/Keyguard/res/layout/keyguard_bouncer.xml
+++ b/packages/Keyguard/res/layout/keyguard_bouncer.xml
@@ -17,7 +17,8 @@
 <FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
-    android:background="@android:color/transparent" >
+    android:background="@android:color/transparent"
+    android:fitsSystemWindows="true">
 
     <include
         style="@style/BouncerSecurityContainer"
diff --git a/packages/Keyguard/res/layout/keyguard_emergency_carrier_area.xml b/packages/Keyguard/res/layout/keyguard_emergency_carrier_area.xml
index 78b5746..a083f89 100644
--- a/packages/Keyguard/res/layout/keyguard_emergency_carrier_area.xml
+++ b/packages/Keyguard/res/layout/keyguard_emergency_carrier_area.xml
@@ -40,39 +40,19 @@
         android:visibility="gone"
         androidprv:allCaps="@bool/kg_use_all_caps" />
 
-    <LinearLayout
-        android:layout_width="match_parent"
+    <com.android.keyguard.EmergencyButton
+        android:id="@+id/emergency_call_button"
+        android:layout_width="wrap_content"
         android:layout_height="wrap_content"
+        android:layout_weight="1"
         android:layout_marginTop="@dimen/eca_overlap"
-        style="?android:attr/buttonBarStyle"
-        android:orientation="horizontal"
-        android:gravity="center"
-        android:weightSum="2">
-
-        <com.android.keyguard.EmergencyButton
-            android:id="@+id/emergency_call_button"
-            android:layout_width="0dip"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            android:drawableLeft="@drawable/lockscreen_emergency_button"
-            android:text="@string/kg_emergency_call_label"
-            style="?android:attr/buttonBarButtonStyle"
-            android:textAppearance="?android:attr/textAppearanceMedium"
-            android:textSize="@dimen/kg_status_line_font_size"
-            android:textColor="?android:attr/textColorSecondary"
-            android:drawablePadding="8dip" 
-            android:textAllCaps="@bool/kg_use_all_caps" />
-
-        <Button android:id="@+id/forgot_password_button"
-            android:layout_width="0dip"
-            android:layout_height="wrap_content"
-            android:layout_weight="1"
-            style="?android:attr/buttonBarButtonStyle"
-            android:textSize="@dimen/kg_status_line_font_size"
-            android:textColor="?android:attr/textColorSecondary"
-            android:textAppearance="?android:attr/textAppearanceMedium"
-            android:visibility="gone"
-            android:textAllCaps="@bool/kg_use_all_caps" />
-    </LinearLayout>
+        android:drawableLeft="@drawable/lockscreen_emergency_button"
+        android:text="@string/kg_emergency_call_label"
+        style="?android:attr/buttonBarButtonStyle"
+        android:textAppearance="?android:attr/textAppearanceMedium"
+        android:textSize="@dimen/kg_status_line_font_size"
+        android:textColor="?android:attr/textColorSecondary"
+        android:drawablePadding="8dip"
+        android:textAllCaps="@bool/kg_use_all_caps" />
 
 </com.android.keyguard.EmergencyCarrierArea>
diff --git a/packages/Keyguard/res/layout/keyguard_emergency_carrier_area_empty.xml b/packages/Keyguard/res/layout/keyguard_emergency_carrier_area_empty.xml
deleted file mode 100644
index 2f4adae..0000000
--- a/packages/Keyguard/res/layout/keyguard_emergency_carrier_area_empty.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-**
-** Copyright 2012, 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.
-*/
--->
-
-<!-- This is a blank layout to simplify implementation on landscape on phones
-     it is referenced indirectly by keyguard_eca -->
-<LinearLayout
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="0dip"
-    android:layout_height="0dip"
-    android:orientation="vertical"
-    android:gravity="center"
-    android:layout_gravity="center_horizontal"
-    android:layout_alignParentBottom="true">
-
-</LinearLayout>
diff --git a/packages/Keyguard/res/layout/keyguard_face_unlock_view.xml b/packages/Keyguard/res/layout/keyguard_face_unlock_view.xml
index 8c8ec7a..0c85dab 100644
--- a/packages/Keyguard/res/layout/keyguard_face_unlock_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_face_unlock_view.xml
@@ -36,7 +36,6 @@
 
     <FrameLayout
        android:id="@+id/keyguard_bouncer_frame"
-       android:background="@drawable/kg_bouncer_bg_white"
        android:layout_width="match_parent"
        android:layout_height="0dp"
        android:layout_weight="1"
diff --git a/packages/Keyguard/res/layout/keyguard_password_view.xml b/packages/Keyguard/res/layout/keyguard_password_view.xml
index ed3f0e0..b7d5d30 100644
--- a/packages/Keyguard/res/layout/keyguard_password_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_password_view.xml
@@ -32,7 +32,7 @@
     <Space
         android:layout_width="match_parent"
         android:layout_height="0dp"
-        android:layout_weight="1"
+        android:layout_weight="7"
         />
 
     <include layout="@layout/keyguard_message_area"
@@ -40,64 +40,50 @@
         android:layout_height="wrap_content" />
 
     <!-- Password entry field -->
-    <!-- Note: the entire container is styled to look like the edit field,
-         since the backspace/IME switcher looks better inside -->
       <FrameLayout
          android:id="@+id/keyguard_bouncer_frame"
-         android:background="@drawable/kg_bouncer_bg_white"
          android:layout_height="wrap_content"
-         android:layout_width="match_parent"
+         android:layout_width="280dp"
+         android:layout_gravity="center_horizontal"
+         android:theme="@style/PasswordTheme"
          >
-         <LinearLayout
-             android:layout_height="wrap_content"
+
+         <EditText android:id="@+id/passwordEntry"
              android:layout_width="match_parent"
-             android:orientation="horizontal"
-             android:background="#70000000"
-             android:layout_marginTop="8dp"
-             android:layout_marginBottom="8dp"
-             >
+             android:layout_height="wrap_content"
+             android:gravity="center_horizontal"
+             android:singleLine="true"
+             android:textStyle="normal"
+             android:inputType="textPassword"
+             android:textSize="16sp"
+             android:textAppearance="?android:attr/textAppearanceMedium"
+             android:imeOptions="flagForceAscii|actionDone"
+             />
 
-             <EditText android:id="@+id/passwordEntry"
-                 android:layout_width="0dip"
-                 android:layout_height="wrap_content"
-                 android:layout_weight="1"
-                 android:gravity="center_horizontal"
-                 android:layout_gravity="center_vertical"
-                 android:layout_marginStart="@dimen/keyguard_lockscreen_pin_margin_left"
-                 android:singleLine="true"
-                 android:textStyle="normal"
-                 android:inputType="textPassword"
-                 android:textSize="36sp"
-                 android:background="@null"
-                 android:textAppearance="?android:attr/textAppearanceMedium"
-                 android:textColor="#ffffffff"
-                 android:imeOptions="flagForceAscii|actionDone"
-                 />
-
-             <ImageView android:id="@+id/switch_ime_button"
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:src="@drawable/ic_lockscreen_ime"
-                 android:clickable="true"
-                 android:padding="8dip"
-                 android:layout_gravity="center"
-                 android:background="?android:attr/selectableItemBackground"
-                 android:visibility="gone"
-                 />
-
-            </LinearLayout>
+         <ImageView android:id="@+id/switch_ime_button"
+             android:layout_width="wrap_content"
+             android:layout_height="wrap_content"
+             android:layout_marginBottom="12dp"
+             android:src="@drawable/ic_lockscreen_ime"
+             android:clickable="true"
+             android:padding="8dip"
+             android:layout_gravity="end|center_vertical"
+             android:background="?android:attr/selectableItemBackground"
+             android:visibility="gone"
+             />
        </FrameLayout>
 
     <Space
         android:layout_width="match_parent"
         android:layout_height="0dp"
-        android:layout_weight="1"
+        android:layout_weight="2"
         />
 
     <include layout="@layout/keyguard_eca"
              android:id="@+id/keyguard_selector_fade_container"
              android:layout_width="match_parent"
              android:layout_height="wrap_content"
+             android:layout_marginBottom="12dp"
              android:orientation="vertical"
              android:layout_gravity="bottom|center_horizontal"
              android:gravity="center_horizontal" />
diff --git a/packages/Keyguard/res/layout/keyguard_pattern_view.xml b/packages/Keyguard/res/layout/keyguard_pattern_view.xml
index 3d7820f..bd585b5 100644
--- a/packages/Keyguard/res/layout/keyguard_pattern_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_pattern_view.xml
@@ -40,7 +40,7 @@
             android:layout_height="wrap_content"
             android:layout_width="wrap_content"
             android:orientation="vertical"
-            android:layout_gravity="center">
+            android:layout_gravity="center_horizontal|bottom">
 
             <include layout="@layout/keyguard_message_area"
                 android:layout_width="match_parent"
@@ -49,7 +49,6 @@
 
           <FrameLayout
              android:id="@+id/keyguard_bouncer_frame"
-             android:background="@drawable/kg_bouncer_bg_white"
              android:layout_width="match_parent"
              android:layout_height="0dp"
              android:layout_weight="1"
diff --git a/packages/Keyguard/res/layout/keyguard_pin_view.xml b/packages/Keyguard/res/layout/keyguard_pin_view.xml
index a33f95b..4cbddde 100644
--- a/packages/Keyguard/res/layout/keyguard_pin_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_pin_view.xml
@@ -40,7 +40,7 @@
             android:layout_weight="1"
             android:layoutDirection="ltr"
             >
-        <RelativeLayout
+        <com.android.keyguard.AlphaOptimizedRelativeLayout
                 android:id="@+id/row0"
                 android:layout_width="match_parent"
                 android:layout_height="0dp"
@@ -79,7 +79,7 @@
                     android:layout_alignParentBottom="true"
                     android:background="#28FFFFFF"
                     />
-        </RelativeLayout>
+        </com.android.keyguard.AlphaOptimizedRelativeLayout>
         <LinearLayout
                 android:id="@+id/row1"
                 android:layout_width="match_parent"
@@ -196,7 +196,7 @@
                     androidprv:textView="@+id/pinEntry"
                     androidprv:digit="0"
                     />
-            <ImageButton
+            <com.android.keyguard.AlphaOptimizedImageButton
                     android:id="@+id/key_enter"
                     android:layout_width="0px"
                     android:layout_height="match_parent"
diff --git a/packages/Keyguard/res/layout/keyguard_selector_view.xml b/packages/Keyguard/res/layout/keyguard_selector_view.xml
index d3064ed..5330363 100644
--- a/packages/Keyguard/res/layout/keyguard_selector_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_selector_view.xml
@@ -48,8 +48,7 @@
             android:layout_width="match_parent"
             android:layout_height="match_parent"
             android:layout_marginLeft="16dp"
-            android:layout_marginRight="16dp"
-            android:background="@drawable/kg_bouncer_bg_white"/>
+            android:layout_marginRight="16dp"/>
 
         <include layout="@layout/keyguard_glow_pad_container" />
 
diff --git a/packages/Keyguard/res/layout/keyguard_status_view.xml b/packages/Keyguard/res/layout/keyguard_status_view.xml
index 006b1ee..1858261 100644
--- a/packages/Keyguard/res/layout/keyguard_status_view.xml
+++ b/packages/Keyguard/res/layout/keyguard_status_view.xml
@@ -27,14 +27,13 @@
     android:layout_height="wrap_content"
     androidprv:layout_maxWidth="@dimen/keyguard_security_width"
     androidprv:layout_maxHeight="@dimen/keyguard_security_height"
-    android:gravity="center_horizontal|top"
-    android:contentDescription="@string/keyguard_accessibility_status">
+    android:gravity="center_horizontal|top">
     <LinearLayout
+        android:id="@+id/keyguard_clock_container"
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:layout_gravity="center_horizontal|top"
-        android:orientation="vertical"
-        android:focusable="true">
+        android:orientation="vertical" >
         <TextClock
             android:id="@+id/clock_view"
             android:layout_width="wrap_content"
diff --git a/packages/Keyguard/res/values-af/strings.xml b/packages/Keyguard/res/values-af/strings.xml
index 5811d14..74f9d1e 100644
--- a/packages/Keyguard/res/values-af/strings.xml
+++ b/packages/Keyguard/res/values-af/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Ontsluitruimte ingevou."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>-legstuk."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Gebruikerkieser"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Media-kontroles"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Herordening van legstuk begin."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Begin gekanselleer"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Laat los <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> om uit te vee."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> sal nie uitgevee word nie."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Volgende wekker gestel vir <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-am/strings.xml b/packages/Keyguard/res/values-am/strings.xml
index a630dee..fb94e94 100644
--- a/packages/Keyguard/res/values-am/strings.xml
+++ b/packages/Keyguard/res/values-am/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"የመክፈቻ አካባቢ ተሰብስቧል።"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"የ<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ንዑስ ፕሮግራም።"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ተጠቃሚ መራጭ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"ሁኔታ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ካሜራ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"የሚዲያ መቆጣጠሪያዎች"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"የንዑስ ፕሮግራም ዳግም መደርደር ተጀምሯል።"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ማስጀመር ተሰርዟል"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ለመሰረዝ <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>ን ጣል ያድርጉ።"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> አይሰርዝም።"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"ቀጣዩ ማንቂያ ለ<xliff:g id="ALARM">%1$s</xliff:g> ተዘጋጅቷል"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ar/strings.xml b/packages/Keyguard/res/values-ar/strings.xml
index 48a5fca..f04cb2f 100644
--- a/packages/Keyguard/res/values-ar/strings.xml
+++ b/packages/Keyguard/res/values-ar/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"تم تصغير منطقة إلغاء القفل."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"أداة <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"محدد المستخدم"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"الحالة"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"الكاميرا"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"أدوات التحكم في الوسائط"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"بدأت إعادة ترتيب الأدوات."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"تم إلغاء التشغيل"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"أسقط <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> للحذف."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"لن يتم حذف <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"تم ضبط التنبيه التالي على <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ب ت ث"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-bg/strings.xml b/packages/Keyguard/res/values-bg/strings.xml
index e8d5533..6b21310 100644
--- a/packages/Keyguard/res/values-bg/strings.xml
+++ b/packages/Keyguard/res/values-bg/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Областта за отключване е свита."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Приспособление за <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Инструмент за избор на потребители"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Състояние"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Контроли за мултимедията"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Пренареждането на приспособленията започна."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Стартирането е анулирано"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Пуснете <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>, за да изтриете."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> няма да се изтрие."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Следващият будилник е зададен за <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"АБВ"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-bn-rBD/strings.xml b/packages/Keyguard/res/values-bn-rBD/strings.xml
index a0e3c41..e315f7a 100644
--- a/packages/Keyguard/res/values-bn-rBD/strings.xml
+++ b/packages/Keyguard/res/values-bn-rBD/strings.xml
@@ -22,9 +22,9 @@
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_name" msgid="719438068451601849">"কীগার্ড"</string>
     <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN কোড লিখুন"</string>
-    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"SIM PUK এবং নতুন PIN কোড লিখুন"</string>
-    <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"SIM PUK কোড"</string>
-    <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"নতুন SIM PIN কোড"</string>
+    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"সিম PUK এবং নতুন PIN কোড লিখুন"</string>
+    <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"সিম PUK কোড"</string>
+    <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"নতুন সিম PIN কোড"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"পাসওয়ার্ড লিখতে স্পর্শ করুন"</font></string>
     <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"আনলক করতে পাসওয়ার্ড লিখুন"</string>
     <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"আনলক করতে PIN লিখুন"</string>
@@ -36,16 +36,16 @@
     <string name="keyguard_low_battery" msgid="8143808018719173859">"আপনার চার্জার সংযুক্ত করুন৷"</string>
     <string name="keyguard_instructions_when_pattern_disabled" msgid="1332288268600329841">"আনলক করতে মেনু টিপুন৷"</string>
     <string name="keyguard_network_locked_message" msgid="9169717779058037168">"নেটওয়ার্ক লক হয়েছে"</string>
-    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"কোনো SIM কার্ড নেই"</string>
-    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"ট্যাবলেটের মধ্যে কোনো SIM কার্ড নেই৷"</string>
-    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"ফোনের মধ্যে কোনো SIM কার্ড নেই৷"</string>
-    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"একটি SIM কার্ড ঢোকান৷"</string>
-    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"SIM কার্ডটি অনুপস্থিত বা পাঠযোগ্য নয়৷ একটি SIM কার্ড ঢোকান৷"</string>
-    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"অব্যবহারযোগ্য SIM কার্ড৷"</string>
-    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"আপনার SIM কার্ড স্থায়ীভাবে অক্ষম করা হয়েছে৷\n অন্য একটি SIM কার্ড পেতে আপনার ওয়্যারলেস পরিষেবা প্রদানকারীর সাথে যোগাযোগ করুন৷"</string>
-    <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"SIM কার্ড লক করা আছে৷"</string>
-    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"SIM কার্ডটি PUK কোড দিয়ে লক করা আছে৷"</string>
-    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"SIM কার্ড আনলক করা হচ্ছে…"</string>
+    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"কোনো সিম কার্ড নেই"</string>
+    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"ট্যাবলেটের মধ্যে কোনো সিম কার্ড নেই৷"</string>
+    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"ফোনের মধ্যে কোনো সিম কার্ড নেই৷"</string>
+    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"একটি সিম কার্ড ঢোকান৷"</string>
+    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"সিম কার্ডটি অনুপস্থিত বা পাঠযোগ্য নয়৷ একটি সিম কার্ড ঢোকান৷"</string>
+    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"অব্যবহারযোগ্য সিম কার্ড৷"</string>
+    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"আপনার সিম কার্ড স্থায়ীভাবে অক্ষম করা হয়েছে৷\n অন্য একটি সিম কার্ড পেতে আপনার ওয়্যারলেস পরিষেবা প্রদানকারীর সাথে যোগাযোগ করুন৷"</string>
+    <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"সিম কার্ড লক করা আছে৷"</string>
+    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"সিম কার্ডটি PUK কোড দিয়ে লক করা আছে৷"</string>
+    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"সিম কার্ড আনলক করা হচ্ছে…"</string>
     <string name="keyguard_accessibility_widget_changed" msgid="5678624624681400191">"%1$s৷ %3$d এর %2$d উইজেট৷"</string>
     <string name="keyguard_accessibility_add_widget" msgid="8273277058724924654">"উইজেট যোগ করুন"</string>
     <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"খালি"</string>
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"আনলক করার এলাকা সঙ্কুচিত হয়েছে৷"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> উইজেট৷"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ব্যবহারকারী নির্বাচক"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"স্থিতি"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ক্যামেরা"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"মিডিয়া নিয়ন্ত্রণগুলি"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"উইজেট রেকর্ড করা শুরু হয়েছে৷"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"লঞ্চ করা বাতিল করা হয়েছে"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"মুছে ফেলতে <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ছাড়ুন৷"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> মুছে ফেলা যাবে না৷"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g> এ পরবর্তী অ্যালার্ম সেট করা হয়েছে"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?১২৩"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
@@ -106,13 +106,13 @@
     <string name="kg_wrong_pin" msgid="1131306510833563801">"ভুল PIN"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"আপনার প্যাটার্ন আঁকুন"</string>
-    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN লিখুন"</string>
+    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"সিম PIN লিখুন"</string>
     <string name="kg_pin_instructions" msgid="2377242233495111557">"PIN লিখুন"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"পাসওয়ার্ড লিখুন"</string>
-    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM এখন অক্ষম করা হয়েছে৷ অবিরত থাকতে PUK কোডটি লিখুন৷ বিশদ বিবরণের জন্য ক্যারিয়ারের সাথে যোগাযোগ করুন৷"</string>
+    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"সিম এখন অক্ষম করা হয়েছে৷ অবিরত থাকতে PUK কোডটি লিখুন৷ বিশদ বিবরণের জন্য ক্যারিয়ারের সাথে যোগাযোগ করুন৷"</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"কাঙ্ক্ষিত PIN কোড লিখুন"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"কাঙ্ক্ষিত PIN কোড নিশ্চিত করুন"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM কার্ড আনলক করা হচ্ছে…"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"সিম কার্ড আনলক করা হচ্ছে…"</string>
     <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"৪ থেকে ৮টি সংখ্যার একটি PIN লিখুন৷"</string>
     <string name="kg_invalid_sim_puk_hint" msgid="7553388325654369575">"PUK কোডটিকে ৮টি বা তার বেশি সংখ্য বিশিষ্ট হতে হবে৷"</string>
     <string name="kg_invalid_puk" msgid="3638289409676051243">"সঠিক PUK কোড পুনরায় লিখুন৷ বার বার প্রচেষ্টা করা হলে তা স্থায়ীভাবে সিমটিকে অক্ষম করে দেবে৷"</string>
@@ -136,18 +136,18 @@
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"আপনি আপনার আনলকের প্যাটার্ন আঁকার ক্ষেত্রে <xliff:g id="NUMBER_0">%d</xliff:g> বার ভুল করেছেন৷ আর <xliff:g id="NUMBER_1">%d</xliff:g> বার অসফল প্রচেষ্টা করা হলে আপনাকে একটি ইমেল অ্যাকাউন্ট মারফত আপনার ফোন আনলক করতে বলা হবে৷\n\n <xliff:g id="NUMBER_2">%d</xliff:g> সেকেন্ডের মধ্যে আবার চেষ্টা করুন৷"</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
     <string name="kg_reordering_delete_drop_target_text" msgid="7899202978204438708">"সরান"</string>
-    <string name="kg_password_wrong_pin_code_pukked" msgid="30531039455764924">"ভুল SIM PIN কোড, আপনার ডিভাইসটি আনলক করতে এখন আপনাকে অবশ্যই আপনার ক্যারিয়ারের সাথে যোগাযোগ করতে হবে৷"</string>
+    <string name="kg_password_wrong_pin_code_pukked" msgid="30531039455764924">"ভুল সিম PIN কোড, আপনার ডিভাইসটি আনলক করতে এখন আপনাকে অবশ্যই আপনার ক্যারিয়ারের সাথে যোগাযোগ করতে হবে৷"</string>
   <plurals name="kg_password_wrong_pin_code">
-    <item quantity="one" msgid="8134313997799638254">"ভুল SIM PIN কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে, তার পরে আপনার ডিভাইসটি আনলক করতে আপনাকে অবশ্যই আপনার ক্যারিয়ারের সাথে যোগাযোগ করতে হবে৷"</item>
-    <item quantity="other" msgid="2215723361575359486">"ভুল SIM PIN কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে৷"</item>
+    <item quantity="one" msgid="8134313997799638254">"ভুল সিম PIN কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে, তার পরে আপনার ডিভাইসটি আনলক করতে আপনাকে অবশ্যই আপনার ক্যারিয়ারের সাথে যোগাযোগ করতে হবে৷"</item>
+    <item quantity="other" msgid="2215723361575359486">"ভুল সিম PIN কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে৷"</item>
   </plurals>
     <string name="kg_password_wrong_puk_code_dead" msgid="7077536808291316208">"SIMটি ব্যবহারের অযোগ্য৷ আপনার ক্যারিয়ারের সাথে যোগাযোগ করুন৷"</string>
   <plurals name="kg_password_wrong_puk_code">
-    <item quantity="one" msgid="3256893607561060649">"ভুল SIM PUK কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার SIM স্থায়ীভাবে অব্যবহারযোগ্য হবে৷"</item>
-    <item quantity="other" msgid="5477305226026342036">"ভুল SIM PUK কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার SIM স্থায়ীভাবে অব্যবহারযোগ্য হবে৷"</item>
+    <item quantity="one" msgid="3256893607561060649">"ভুল সিম PUK কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার সিম স্থায়ীভাবে অব্যবহারযোগ্য হবে৷"</item>
+    <item quantity="other" msgid="5477305226026342036">"ভুল সিম PUK কোড, আপনার কাছে আর <xliff:g id="NUMBER">%d</xliff:g>টি প্রচেষ্টা বাকি রয়েছে এটির পরেই আপনার সিম স্থায়ীভাবে অব্যবহারযোগ্য হবে৷"</item>
   </plurals>
-    <string name="kg_password_pin_failed" msgid="6268288093558031564">"SIM PIN ক্রিয়াকলাপটি ব্যর্থ হয়েছে!"</string>
-    <string name="kg_password_puk_failed" msgid="2838824369502455984">"SIM PUK ক্রিয়াকলাপটি ব্যর্থ হয়েছে!"</string>
+    <string name="kg_password_pin_failed" msgid="6268288093558031564">"সিম PIN ক্রিয়াকলাপটি ব্যর্থ হয়েছে!"</string>
+    <string name="kg_password_puk_failed" msgid="2838824369502455984">"সিম PUK ক্রিয়াকলাপটি ব্যর্থ হয়েছে!"</string>
     <string name="kg_pin_accepted" msgid="1448241673570020097">"কোড স্বীকৃত হয়েছে!"</string>
     <string name="keyguard_transport_prev_description" msgid="8229108430245669854">"পূর্ববর্তী ট্র্যাকে যাওয়ার বোতাম"</string>
     <string name="keyguard_transport_next_description" msgid="4299258300283778305">"পরবর্তী ট্র্যাকে যাওয়ার বোতাম"</string>
diff --git a/packages/Keyguard/res/values-ca/strings.xml b/packages/Keyguard/res/values-ca/strings.xml
index f258224..02fa9c3 100644
--- a/packages/Keyguard/res/values-ca/strings.xml
+++ b/packages/Keyguard/res/values-ca/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"L\'àrea de desbloqueig està replegada."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget de <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selector d\'usuaris"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Estat"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Càmera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controls multimèdia"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"S\'ha iniciat la reorganització del widget."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"S\'ha cancel·lat l\'inici"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Deixa anar <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> per suprimir-lo."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"No se suprimirà <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"S\'ha definit la pròxima alarma per a les: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-cs/strings.xml b/packages/Keyguard/res/values-cs/strings.xml
index 5df0508..870bf23 100644
--- a/packages/Keyguard/res/values-cs/strings.xml
+++ b/packages/Keyguard/res/values-cs/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Oblast odemknutí byla sbalena."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Výběr uživatele"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stav"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotoaparát"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Ovládání médií"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Přeuspořádání widgetů bylo zahájeno."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Spuštění zrušeno"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Uvolněním dotyku widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> vymažete."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> nebude vymazán."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Další budík je nastaven na <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"Alt"</string>
diff --git a/packages/Keyguard/res/values-da/strings.xml b/packages/Keyguard/res/values-da/strings.xml
index 1acfa6b..d473b96 100644
--- a/packages/Keyguard/res/values-da/strings.xml
+++ b/packages/Keyguard/res/values-da/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Oplåsningsområdet er skjult."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget til <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Brugervælger"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediekontrolelementer"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Omrokering af widgets er påbegyndt."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Starten blev annulleret"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Slip <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> for at slette."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> slettes ikke."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Næste alarm er indstillet til <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-de/strings.xml b/packages/Keyguard/res/values-de/strings.xml
index bf88124..6c399ee 100644
--- a/packages/Keyguard/res/values-de/strings.xml
+++ b/packages/Keyguard/res/values-de/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Entsperr-Bereich mminimiert"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Nutzerauswahl"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediensteuerelemente"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Neuordnung der Widgets gestartet"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Start abgebrochen"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Legen Sie <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> zum Löschen ab."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> wird nicht gelöscht."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Nächster Wecker gestellt für <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-el/strings.xml b/packages/Keyguard/res/values-el/strings.xml
index e928662..9f459be 100644
--- a/packages/Keyguard/res/values-el/strings.xml
+++ b/packages/Keyguard/res/values-el/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Σύμπτυξη της περιοχής ξεκλειδώματος."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Γραφικό στοιχείο <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Επιλογέας χρήστη"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Κατάσταση"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Φωτογραφική μηχανή"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Στοιχεία ελέγχου μέσων"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Έχει ξεκινήσει η αναδιάταξη των γραφικών στοιχείων."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Η εκκίνηση ακυρώθηκε"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Αποθέστε <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> για διαγραφή."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> δεν θα διαγραφεί."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Το επόμενο ξυπνητήρι ορίστηκε στις <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ΑΒΓ"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-en-rGB/strings.xml b/packages/Keyguard/res/values-en-rGB/strings.xml
index 962c80d..15b00db 100644
--- a/packages/Keyguard/res/values-en-rGB/strings.xml
+++ b/packages/Keyguard/res/values-en-rGB/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Unlock area collapsed."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"User selector"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Camera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Media controls"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Widget reordering started."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Launch cancelled"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Drop <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> to delete."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> will not be deleted."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Next alarm set for <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-en-rIN/strings.xml b/packages/Keyguard/res/values-en-rIN/strings.xml
index 962c80d..15b00db 100644
--- a/packages/Keyguard/res/values-en-rIN/strings.xml
+++ b/packages/Keyguard/res/values-en-rIN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Unlock area collapsed."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"User selector"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Camera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Media controls"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Widget reordering started."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Launch cancelled"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Drop <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> to delete."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> will not be deleted."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Next alarm set for <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-es-rUS/strings.xml b/packages/Keyguard/res/values-es-rUS/strings.xml
index 47288a1..2b7d33c 100644
--- a/packages/Keyguard/res/values-es-rUS/strings.xml
+++ b/packages/Keyguard/res/values-es-rUS/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"El área desbloqueada se contrajo."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selector de usuarios"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Estado"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Cámara"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controles de medios"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Se comenzaron a reordenar los widgets."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Se canceló el inicio."</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Suelta <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> para eliminarlo."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"No se eliminará <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Próxima alarma establecida: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-es/strings.xml b/packages/Keyguard/res/values-es/strings.xml
index 1bf3b0c..4a80c99 100644
--- a/packages/Keyguard/res/values-es/strings.xml
+++ b/packages/Keyguard/res/values-es/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Área de desbloqueo contraída"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget de <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selector de usuarios"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Estado"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Cámara"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controles multimedia"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Se ha empezado a cambiar el orden de los widgets."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Inicio cancelado"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Suelta <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> para eliminarlo."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> no se eliminará."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Próxima alarma: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-et-rEE/strings.xml b/packages/Keyguard/res/values-et-rEE/strings.xml
index ad43c08..ce20dad 100644
--- a/packages/Keyguard/res/values-et-rEE/strings.xml
+++ b/packages/Keyguard/res/values-et-rEE/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Avamisala on ahendatud."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Vidin <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Kasutaja valija"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Olek"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kaamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Meedia juhtnupud"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Vidina ümberkorraldamine algas."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Käivitamine on tühistatud"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Kustutamiseks laske vidin <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> lahti."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Vidinat <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ei kustutata."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Järgmine alarm on määratud ajaks <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-eu-rES/strings.xml b/packages/Keyguard/res/values-eu-rES/strings.xml
index fb8cff2..f888e56 100644
--- a/packages/Keyguard/res/values-eu-rES/strings.xml
+++ b/packages/Keyguard/res/values-eu-rES/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Desblokeatzeko eremua tolestu da."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widgeta."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Erabiltzaile-hautatzailea"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Egoera"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Multimedia-kontrolak"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Widgetak berrantolatzen hasi da."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Abiaraztea bertan behera utzi da"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Ezabatzeko, jaregin <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Ez da <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ezabatuko."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Hurrengo alarmak ordu honetan joko du: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-fa/strings.xml b/packages/Keyguard/res/values-fa/strings.xml
index fe9652c..097ff5c 100644
--- a/packages/Keyguard/res/values-fa/strings.xml
+++ b/packages/Keyguard/res/values-fa/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"منطقه بازگشایی کوچک شد."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"ابزارک <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"انتخابگر کاربر"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"وضعیت"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"دوربین"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"کنترل‌های رسانه"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"مرتب سازی مجدد ابزارک آغاز شد."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"راه‌اندازی لغو شد"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"جهت حذف، <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> را بکشید."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> پاک نخواهد شد."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"زنگ هشدار بعدی برای <xliff:g id="ALARM">%1$s</xliff:g> تنظیم شد"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-fi/strings.xml b/packages/Keyguard/res/values-fi/strings.xml
index 4a18898..c72239a 100644
--- a/packages/Keyguard/res/values-fi/strings.xml
+++ b/packages/Keyguard/res/values-fi/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Lukituksen poiston alue tiivistetty."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>-widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Käyttäjävalitsin"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Tila"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediaohjaimet"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Widgetien järjestely aloitettu."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Käynnistys peruutettu"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Poista <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> pudottamalla."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Kohdetta <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ei poisteta."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Seuraava hälytys asetettu: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-fr-rCA/strings.xml b/packages/Keyguard/res/values-fr-rCA/strings.xml
index a3960bf..fad493f 100644
--- a/packages/Keyguard/res/values-fr-rCA/strings.xml
+++ b/packages/Keyguard/res/values-fr-rCA/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Réduction de la zone de déverrouillage"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Sélecteur d\'utilisateur"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"État"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Caméra"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Commandes multimédias"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Début de la réorganisation des widgets"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Lancement annulé"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Déposez <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> pour supprimer."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ne sera pas supprimé."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Heure de la prochaine alarme : <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-fr/strings.xml b/packages/Keyguard/res/values-fr/strings.xml
index 6416e53..bd750b6 100644
--- a/packages/Keyguard/res/values-fr/strings.xml
+++ b/packages/Keyguard/res/values-fr/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Zone de déverrouillage réduite."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Sélecteur d\'utilisateur"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"État"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Caméra"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Commandes multimédias"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Début de la réorganisation des widgets"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Lancement annulé."</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Relâchez le widget \"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>\" pour le supprimer."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Le widget \"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>\" ne va pas être supprimé."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Prochaine alarme définie à <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-gl-rES/strings.xml b/packages/Keyguard/res/values-gl-rES/strings.xml
index 6aece27..1219fcb 100644
--- a/packages/Keyguard/res/values-gl-rES/strings.xml
+++ b/packages/Keyguard/res/values-gl-rES/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Área de desbloqueo contraída"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selector de usuarios"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Estado"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Cámara"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controis multimedia"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Reordenación de widget iniciada"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Inicio cancelado"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Solta <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> para eliminalo."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Non se eliminará <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Próxima alarma definida para <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-h650dp/dimens.xml b/packages/Keyguard/res/values-h650dp/dimens.xml
new file mode 100644
index 0000000..4864326
--- /dev/null
+++ b/packages/Keyguard/res/values-h650dp/dimens.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<resources>
+    <dimen name="widget_big_font_size">112dp</dimen>
+</resources>
\ No newline at end of file
diff --git a/packages/Keyguard/res/values-hi/strings.xml b/packages/Keyguard/res/values-hi/strings.xml
index f197138..b8c3358 100644
--- a/packages/Keyguard/res/values-hi/strings.xml
+++ b/packages/Keyguard/res/values-hi/strings.xml
@@ -36,24 +36,23 @@
     <string name="keyguard_low_battery" msgid="8143808018719173859">"अपना चार्जर कनेक्‍ट करें."</string>
     <string name="keyguard_instructions_when_pattern_disabled" msgid="1332288268600329841">"अनलॉक करने के लिए मेनू दबाएं."</string>
     <string name="keyguard_network_locked_message" msgid="9169717779058037168">"नेटवर्क लॉक किया गया"</string>
-    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"कोई SIM कार्ड नहीं है"</string>
-    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"टेबलेट में कोई SIM कार्ड नहीं है."</string>
-    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"फ़ोन में कोई SIM कार्ड नहीं है."</string>
-    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"SIM कार्ड डालें."</string>
-    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"SIM कार्ड गुम है या पढ़ने योग्‍य नहीं है. SIM कार्ड डालें."</string>
-    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"अनुपयोगी SIM कार्ड."</string>
-    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"आपका SIM कार्ड स्‍थायी रूप से अक्षम कर दिया गया है.\n दूसरे SIM कार्ड के लिए अपने वायरलेस सेवा प्रदाता से संपर्क करें."</string>
+    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"कोई सिम कार्ड नहीं है"</string>
+    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"टेबलेट में कोई सिम कार्ड नहीं है."</string>
+    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"फ़ोन में कोई सिम कार्ड नहीं है."</string>
+    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"सिम कार्ड डालें."</string>
+    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"सिम कार्ड गुम है या पढ़ने योग्‍य नहीं है. सिम कार्ड डालें."</string>
+    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"अनुपयोगी सिम कार्ड."</string>
+    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"आपका सिम कार्ड स्‍थायी रूप से अक्षम कर दिया गया है.\n दूसरे सिम कार्ड के लिए अपने वायरलेस सेवा प्रदाता से संपर्क करें."</string>
     <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"सिम कार्ड लॉक है."</string>
-    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"SIM कार्ड PUK द्वारा लॉक किया हुआ है."</string>
-    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"SIM कार्ड अनलॉक हो रहा है…"</string>
+    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"सिम कार्ड PUK द्वारा लॉक किया हुआ है."</string>
+    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"सिम कार्ड अनलॉक हो रहा है…"</string>
     <string name="keyguard_accessibility_widget_changed" msgid="5678624624681400191">"%1$s. %3$d विजेट में से %2$d."</string>
     <string name="keyguard_accessibility_add_widget" msgid="8273277058724924654">"विजेट जोड़ें"</string>
-    <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"रिक्त"</string>
+    <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"खाली"</string>
     <string name="keyguard_accessibility_unlock_area_expanded" msgid="2278106022311170299">"अनलॉक क्षेत्र को विस्तृत कर दिया गया."</string>
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"अनलॉक क्षेत्र को संक्षिप्त कर दिया गया."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> विजेट."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"उपयोगकर्ता चयनकर्ता"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"स्थिति"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"कैमरा"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"मीडिया नियंत्रण"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"विजेट पुनः क्रमित करना प्रारंभ."</string>
@@ -79,11 +78,12 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"लॉन्‍च रद्द कर दिया गया"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"हटाने के लिए <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> खींचें."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> को नहीं हटाया जाएगा."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"अगला अलार्म <xliff:g id="ALARM">%1$s</xliff:g> के लिए सेट किया गया"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Alt"</string>
-    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"रद्द करें"</string>
+    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"रहने दें"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"हटाएं"</string>
     <string name="keyboardview_keycode_done" msgid="1992571118466679775">"पूर्ण"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"Mode change"</string>
@@ -112,7 +112,7 @@
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"सिम अब अक्षम हो गई है. जारी रखने के लिए PUK कोड डालें. विवरण के लिए कैरियर से संपर्क करें."</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"इच्छित पिन कोड डालें"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"इच्छित पिन कोड की पुष्टि करें"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM कार्ड अनलॉक कर रहा है…"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"सिम कार्ड अनलॉक कर रहा है…"</string>
     <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"ऐसा PIN लिखें, जो 4 से 8 अंकों का हो."</string>
     <string name="kg_invalid_sim_puk_hint" msgid="7553388325654369575">"PUK कोड 8 या अधिक संख्या वाला होना चाहिए."</string>
     <string name="kg_invalid_puk" msgid="3638289409676051243">"सही PUK कोड पुन: डालें. बार-बार प्रयास करने से सिम स्थायी रूप से अक्षम हो जाएगी."</string>
diff --git a/packages/Keyguard/res/values-hr/strings.xml b/packages/Keyguard/res/values-hr/strings.xml
index 5c6a467..c44d106 100644
--- a/packages/Keyguard/res/values-hr/strings.xml
+++ b/packages/Keyguard/res/values-hr/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Područje za otključavanje sažeto je."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Birač korisnika"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotoaparat"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Nadzor medija"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Pokrenuta je promjena redoslijeda widgeta."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Pokretanje je otkazano"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Ispustite widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> da biste ga izbrisali."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> neće se izbrisati."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Sljedeći alarm postavljen za <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-hu/strings.xml b/packages/Keyguard/res/values-hu/strings.xml
index 93b9948..6b04caa 100644
--- a/packages/Keyguard/res/values-hu/strings.xml
+++ b/packages/Keyguard/res/values-hu/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Feloldási terület összecsukva."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> modul."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Felhasználóválasztó"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Állapot"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Médiaelemek vezérlője"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"A modulátrendezés elkezdődött."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Indítás törölve"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Engedje el a(z) <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> törléséhez."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"A(z) <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> nem lesz törölve."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"A következő riasztás beállított ideje: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-hy-rAM/strings.xml b/packages/Keyguard/res/values-hy-rAM/strings.xml
index c512fa9..7db59f0 100644
--- a/packages/Keyguard/res/values-hy-rAM/strings.xml
+++ b/packages/Keyguard/res/values-hy-rAM/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Ապակողպման տարածքը ետ է ծալված:"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> վիջեթ:"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Օգտվողի ընտրիչ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Կարգավիճակ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Ֆոտոխցիկ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Մեդիա կարգավորումներ"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Վիջեթների վերադասավորումը մեկնարկել է:"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Գործարկումը չեղարկվեց"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> վիջեթը ջնջելու համար բաց թողեք այն այստեղ:"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> վիջեթը չի ջնջվի:"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Հաջորդ զարթուցիչը դրված է <xliff:g id="ALARM">%1$s</xliff:g>-ի վրա"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-in/strings.xml b/packages/Keyguard/res/values-in/strings.xml
index 343c320..ba2be57 100644
--- a/packages/Keyguard/res/values-in/strings.xml
+++ b/packages/Keyguard/res/values-in/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Area buka kunci diciutkan."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Pemilih pengguna"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Kontrol media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Pengurutan ulang widget dimulai."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Peluncuran dibatalkan"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Jatuhkan <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> untuk menghapus."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> tidak akan dihapus."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Alarm berikutnya disetel untuk <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-is-rIS/strings.xml b/packages/Keyguard/res/values-is-rIS/strings.xml
index 77e4541..7f67202 100644
--- a/packages/Keyguard/res/values-is-rIS/strings.xml
+++ b/packages/Keyguard/res/values-is-rIS/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Opnunarsvæði fellt saman."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Græjan <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Notandaval"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Staða"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Myndavél"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Margmiðlunarstýringar"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Endurröðun græja hafin."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Hætt við ræsingu"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Slepptu <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> til að eyða."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> verður ekki eytt."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Næsti vekjari stilltur á <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-it/strings.xml b/packages/Keyguard/res/values-it/strings.xml
index 6c7cbfe..958e63d 100644
--- a/packages/Keyguard/res/values-it/strings.xml
+++ b/packages/Keyguard/res/values-it/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Area di sblocco compressa."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selettore utente"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stato"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotocamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controlli media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Riordino dei widget iniziato."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Avvio annullato"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Rilascia <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> per eliminarlo."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> non sarà eliminato."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Prossima sveglia impostata a: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-iw/strings.xml b/packages/Keyguard/res/values-iw/strings.xml
index 7f73b5a..52747cb 100644
--- a/packages/Keyguard/res/values-iw/strings.xml
+++ b/packages/Keyguard/res/values-iw/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"אזור ביטול הנעילה כווץ."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"‏Widget ‏<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"בוחר משתמשים"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"סטטוס"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"מצלמה"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"פקדי מדיה"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"‏סידור מחדש של Widgets התחיל."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ההפעלה בוטלה"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"שחרר את <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> למחיקה."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> לא יימחק."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"ההתראה הבאה נקבעה לשעה <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"אבג"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ja/strings.xml b/packages/Keyguard/res/values-ja/strings.xml
index 3b7ea6a..2b9bda90 100644
--- a/packages/Keyguard/res/values-ja/strings.xml
+++ b/packages/Keyguard/res/values-ja/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"ロック解除エリアを縮小しました。"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>ウィジェットです。"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ユーザー切り替え"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"ステータス"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"カメラ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"メディアコントロール"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"ウィジェットの並べ替えを開始しました。"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"起動をキャンセルしました"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"削除するには<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>をドロップしてください。"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>は削除されません。"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"次のアラームは<xliff:g id="ALARM">%1$s</xliff:g>に設定されました"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ka-rGE/strings.xml b/packages/Keyguard/res/values-ka-rGE/strings.xml
index 36a2d79..dbf4939 100644
--- a/packages/Keyguard/res/values-ka-rGE/strings.xml
+++ b/packages/Keyguard/res/values-ka-rGE/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"განბლოკვის სივრცე ჩაკეცილია."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ვიჯეტი."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"მომხმარებლის ამომრჩეველი"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"სტატუსი"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"კამერა"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"მედიის მართვის ელემენტები"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"დაიწყო ვიჯეტის ხელახლა განლაგება."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"გამოძახება გაუქმდა"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ჩააგდეთ <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> წასაშლელად."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> არ წაიშლება."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"შემდეგი მაღვიძარა დაყენებულია <xliff:g id="ALARM">%1$s</xliff:g>-ზე"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-kk-rKZ/strings.xml b/packages/Keyguard/res/values-kk-rKZ/strings.xml
index 196c4a2..2d4c737 100644
--- a/packages/Keyguard/res/values-kk-rKZ/strings.xml
+++ b/packages/Keyguard/res/values-kk-rKZ/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Ашу аймағы қирады."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> виджеті."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Пайдаланушы таңдаушы"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Күйі"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Meдиа басқарулары"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Виджетті қайта реттеу басталды."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Қосу тоқтатылды"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> жою үшін тастаңыз"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> жойылмайды."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Келесі дабыл <xliff:g id="ALARM">%1$s</xliff:g> уақытына орнатылған"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-km-rKH/strings.xml b/packages/Keyguard/res/values-km-rKH/strings.xml
index ecdad8c..b21d713 100644
--- a/packages/Keyguard/res/values-km-rKH/strings.xml
+++ b/packages/Keyguard/res/values-km-rKH/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"បាន​បង្រួម​ផ្ទៃ​ដោះ​សោ។"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ធាតុ​ក្រាហ្វិក។"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ឧបករណ៍​ជ្រើស​អ្នក​ប្រើ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"ស្ថានភាព"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ម៉ាស៊ីន​ថត"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"ពិនិត្យ​មេឌៀ"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"បាន​ចាប់ផ្ដើម​តម្រៀប​ធាតុ​ក្រាហ្វិក​ឡើងវិញ។"</string>
@@ -79,11 +78,12 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"បាន​បោះបង់​ការ​ចាប់ផ្ដើម"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ទម្លាក់ <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ដើម្បី​លុប។"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> នឹង​មិន​ត្រូវ​បាន​លុប​។"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"ការ​ជូន​ដំណឹង​បន្ទាប់​កំណត់​សម្រាប់ <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Alt"</string>
-    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"បោះ​បង់"</string>
+    <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"បោះ​បង់​"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"លុប"</string>
     <string name="keyboardview_keycode_done" msgid="1992571118466679775">"រួចរាល់"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"ប្ដូរ​របៀប"</string>
@@ -120,7 +120,7 @@
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"ព្យាយាម​លំនាំ​ច្រើន​ពេក"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"ដើម្បី​ដោះ​សោ ចូល​ក្នុង​គណនី Google ។"</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"ឈ្មោះ​អ្នក​ប្រើ (អ៊ី​ម៉ែ​ល​)"</string>
-    <string name="kg_login_password_hint" msgid="9057289103827298549">"ពាក្យសម្ងាត់"</string>
+    <string name="kg_login_password_hint" msgid="9057289103827298549">"ពាក្យសម្ងាត់​"</string>
     <string name="kg_login_submit_button" msgid="5355904582674054702">"ចូល"</string>
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"ឈ្មោះ​អ្នកប្រើ ឬ​ពាក្យ​សម្ងាត់​មិន​ត្រឹមត្រូវ។"</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"ភ្លេច​ឈ្មោះ​អ្នកប្រើ ឬ​ពាក្យ​សម្ងាត់​របស់​អ្នក?\nមើល "<b>"google.com/accounts/recovery"</b>" ។"</string>
diff --git a/packages/Keyguard/res/values-kn-rIN/strings.xml b/packages/Keyguard/res/values-kn-rIN/strings.xml
index f085915..2f69388 100644
--- a/packages/Keyguard/res/values-kn-rIN/strings.xml
+++ b/packages/Keyguard/res/values-kn-rIN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"ಅನ್‌ಲಾಕ್ ಪ್ರದೇಶವನ್ನು ಸಂಕುಚಿಸಲಾಗಿದೆ."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ವಿಜೆಟ್."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ಬಳಕೆದಾರ ಆಯ್ಕೆಗಾರ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"ಸ್ಥಿತಿ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ಕ್ಯಾಮರಾ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"ಮೀಡಿಯಾ ನಿಯಂತ್ರಣಗಳು"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"ವಿಜೆಟ್ ಮರುಕ್ರಮ ಪ್ರಾರಂಭಗೊಂಡಿದೆ."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ಪ್ರಾರಂಭವನ್ನು ರದ್ದುಗೊಳಿಸಲಾಗಿದೆ"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ಅಳಿಸಲು <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ಡ್ರಾಪ್ ಮಾಡಿ."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ಅನ್ನು ಅಳಿಸಲಾಗುವುದಿಲ್ಲ."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g> ಗೆ ಮುಂದಿನ ಅಲಾರಾಂ ಹೊಂದಿಸಲಾಗಿದೆ"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ko/strings.xml b/packages/Keyguard/res/values-ko/strings.xml
index 994c532..d7434a1 100644
--- a/packages/Keyguard/res/values-ko/strings.xml
+++ b/packages/Keyguard/res/values-ko/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"잠금 해제 영역 축소됨"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> 위젯"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"사용자 선택기"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"상태"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"카메라"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"미디어 조정"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"위젯 재정렬 시작됨"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"실행 취소됨"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"삭제하려면 <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>을(를) 드롭합니다."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>은(는) 삭제되지 않습니다."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"다음 알람이 <xliff:g id="ALARM">%1$s</xliff:g>(으)로 설정되었습니다."</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ky-rKG/strings.xml b/packages/Keyguard/res/values-ky-rKG/strings.xml
index 3f91f11..391d08a 100644
--- a/packages/Keyguard/res/values-ky-rKG/strings.xml
+++ b/packages/Keyguard/res/values-ky-rKG/strings.xml
@@ -54,7 +54,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Бөгөттөн чыгаруу аймагы жыйрылды."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> виджети."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Колдонуучуну тандагыч"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Абал"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Медиа башкаруу"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Виджет иреттөө башталды."</string>
@@ -80,6 +79,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Жүргүзүү токтотулду"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> жок кылыш үчүн, түшүрүңүз."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> жок кылынбайт."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Кийинки ойготкуч саат <xliff:g id="ALARM">%1$s</xliff:g> коюлган"</string>
     <!-- no translation found for password_keyboard_label_symbol_key (992280756256536042) -->
     <skip />
     <!-- no translation found for password_keyboard_label_alpha_key (8001096175167485649) -->
diff --git a/packages/Keyguard/res/values-land/alias.xml b/packages/Keyguard/res/values-land/alias.xml
deleted file mode 100644
index 7aac5b4..0000000
--- a/packages/Keyguard/res/values-land/alias.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/assets/res/any/colors.xml
-**
-** Copyright 2012, 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.
-*/
--->
-<resources>
-    <!-- Alias used to reference one of two possible layouts in keyguard.  -->
-    <item type="layout" name="keyguard_eca">@layout/keyguard_emergency_carrier_area_empty</item>
-</resources>
diff --git a/packages/Keyguard/res/values-lo-rLA/strings.xml b/packages/Keyguard/res/values-lo-rLA/strings.xml
index cff4cd5..ecad431 100644
--- a/packages/Keyguard/res/values-lo-rLA/strings.xml
+++ b/packages/Keyguard/res/values-lo-rLA/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"ຫຍໍ້ພື້ນທີ່ປົດລັອກແລ້ວ."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ວິດເຈັດ."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ໂຕເລືອກຂອງຜູ່ໃຊ້"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"ສະຖານະ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ກ້ອງ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"ການຄວບຄຸມສື່"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"ການຈັດຮຽງວິເຈັດໃໝ່ເລີ່ມຕົ້ນແລ້ວ."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ການເປີດໃຊ້ຖືກຍົກເລີກ"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ວາງ <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ເພື່ອລຶບ."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ຈະບໍ່ຖືກລຶບອອກ"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"​ໂມງ​ປຸກ​ຕໍ່​ໄປ​ຖືກ​ຕັ້ງ​ໄວ້​ເວ​ລາ <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-lt/strings.xml b/packages/Keyguard/res/values-lt/strings.xml
index e965076..8f56619 100644
--- a/packages/Keyguard/res/values-lt/strings.xml
+++ b/packages/Keyguard/res/values-lt/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Atrakinimo sritis sutraukta."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Valdiklis <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Naudotojo pasirinkimo valdiklis"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Būsena"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotoaparatas"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Medijos valdikliai"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Valdiklių pertvarkymas pradėtas."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Paleidimas atšauktas"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Paleiskite „<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>“, kad jį ištrintumėte."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"„<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>“ nebus ištrintas."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Kitas nustatytas signalas: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-lv/strings.xml b/packages/Keyguard/res/values-lv/strings.xml
index 144fe88..1596a7a 100644
--- a/packages/Keyguard/res/values-lv/strings.xml
+++ b/packages/Keyguard/res/values-lv/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Atbloķēšanas apgabals ir sakļauts."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Logrīks <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Lietotāju atlasītājs"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Statuss"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Multivides vadīklas"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Logrīku pārkārtošana ir sākta."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Palaišana atcelta"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Velciet logrīku <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>, lai to izdzēstu."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Logrīks <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> netiks izdzēsts."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Signāls iestatīts uz: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-mk-rMK/strings.xml b/packages/Keyguard/res/values-mk-rMK/strings.xml
index 676a164..688e97b 100644
--- a/packages/Keyguard/res/values-mk-rMK/strings.xml
+++ b/packages/Keyguard/res/values-mk-rMK/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Областа за отклучување е собрана."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Виџет <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Избирач на корисник"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Статус"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Фотоапарат"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Контроли на медиуми"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Прередувањето виџети започна."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Стартувањето е откажано"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Пушти го <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> да се избрише."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> нема да се избрише."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Следниот аларм е поставен за <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"АБВ"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ml-rIN/strings.xml b/packages/Keyguard/res/values-ml-rIN/strings.xml
index 6db8525..8de171c 100644
--- a/packages/Keyguard/res/values-ml-rIN/strings.xml
+++ b/packages/Keyguard/res/values-ml-rIN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"അൺലോക്ക് ഏരിയ ചുരുക്കി."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> വിജറ്റ്."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ഉപയോക്തൃ സെലക്‌ടർ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"നില"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ക്യാമറ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"മീഡിയ നിയന്ത്രണങ്ങൾ"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"വിജറ്റ് പുനഃക്രമീകരണം ആരംഭിച്ചു."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"സമാരംഭിക്കൽ റദ്ദാക്കി."</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ഇല്ലാതാക്കാൻ ഡ്രോപ്പുചെയ്യുക."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ഇല്ലാതാക്കില്ല."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g>-ന് അടുത്ത അലാറം സജ്ജീകരിച്ചു"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-mn-rMN/strings.xml b/packages/Keyguard/res/values-mn-rMN/strings.xml
index 200e104..708e3e3 100644
--- a/packages/Keyguard/res/values-mn-rMN/strings.xml
+++ b/packages/Keyguard/res/values-mn-rMN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Тайлах хэсэг хаагдсан."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> виджет."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Хэрэглэгч сонгоч"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Статус"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камер"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Медиа контрол"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Виджет дахин эрэмбэлж эхлэв."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Эхлүүлэхийг цуцалсан"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Устгахын тулд <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>-г тавина уу."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> устахгүй."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Дараагийн сэрүүлгийг <xliff:g id="ALARM">%1$s</xliff:g>-д тохируулсан"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"АБВ"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-mr-rIN/strings.xml b/packages/Keyguard/res/values-mr-rIN/strings.xml
index 3bb0333..4265305 100644
--- a/packages/Keyguard/res/values-mr-rIN/strings.xml
+++ b/packages/Keyguard/res/values-mr-rIN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"अनलॉक क्षेत्र संकुचित केले."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> विजेट."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"वापरकर्ता निवडकर्ता"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"स्थिती"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"कॅमेरा"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"मीडिया नियंत्रणे"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"विजेट पुनर्क्रमित करणे प्रारंभ झाले."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"लाँच रद्द केले"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"हटविण्‍यासाठी <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ड्रॉप करा."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> हटविली जाणार नाही."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"पुढील अलार्म <xliff:g id="ALARM">%1$s</xliff:g> साठी सेट केला"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ms-rMY/strings.xml b/packages/Keyguard/res/values-ms-rMY/strings.xml
index 0592b34..705e2e1 100644
--- a/packages/Keyguard/res/values-ms-rMY/strings.xml
+++ b/packages/Keyguard/res/values-ms-rMY/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Bahagian buka kunci diruntuhkan."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Pemilih pengguna"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Kawalan media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Penyusunan semula widget dimulakan."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Pelancaran dibatalkan"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Jatuhkan <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> untuk memadam."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> tidak akan dipadamkan."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Penggera seterusnya ditetapkan pada <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-my-rMM/strings.xml b/packages/Keyguard/res/values-my-rMM/strings.xml
index 03bd133..b3ebaad 100644
--- a/packages/Keyguard/res/values-my-rMM/strings.xml
+++ b/packages/Keyguard/res/values-my-rMM/strings.xml
@@ -20,16 +20,16 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_name" msgid="719438068451601849">"သော့ချက် စောင့်ပေးသူ"</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN ကုဒ် ရိုက်ထည့်ပါ"</string>
+    <string name="app_name" msgid="719438068451601849">"သော့ချက် စောင့်ပေးသူ"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN ကုဒ် ရိုက်ထည့်ပါ"</string>
     <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"ဆင်းမ်ကဒ် ပင်နံပါတ် ပြန်ဖွင့်သည့် ကုဒ် နှင့် လျို့ဝှက်နံပါတ်သစ် ရိုက်ထည့်ပါ"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"ဆင်းမ်ကဒ် ပင်နံပါတ် ပြန်ဖွင့်သည့် ကုဒ် နံပါတ်"</string>
     <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"ဆင်းမ်ကဒ် လျို့ဝှက်ပင်နံပါတ် အသစ်သွင်းရန်"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"စကားဝှက် ရိုက်ရန် ထိပါ"</font></string>
-    <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"သော့ဖွင့်ရန် စကားဝှက်ကို ရိုက်ထည့်ပါ"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"သော့ဖွင့်ရန် PIN ကို ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"သော့ဖွင့်ရန် စကားဝှက်ကို ရိုက်ထည့်ပါ"</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"သော့ဖွင့်ရန် PIN ကို ရိုက်ထည့်ပါ"</string>
     <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"ပင်နံပါတ်မှားနေပါသည်"</string>
-    <string name="keyguard_label_text" msgid="861796461028298424">"သော့ဖွင့်ရန် Menu ထိုနောက်0ကိုနှိပ်ပါ"</string>
+    <string name="keyguard_label_text" msgid="861796461028298424">"သော့ဖွင့်ရန် Menu ထိုနောက်0ကိုနှိပ်ပါ"</string>
     <string name="faceunlock_multiple_failures" msgid="754137583022792429">"မျက်မှာမှတ် သော့ဖွင့်ခြင်း ခွင့်ပြုသော အကြိမ်ရေထက် ကျော်လွန်သွားပါပြီ"</string>
     <string name="keyguard_charged" msgid="3272223906073492454">"အားသွင်းနေပါသည်"</string>
     <string name="keyguard_plugged_in" msgid="9087497435553252863">"အားသွင်းနေ"</string>
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"သောဖွင့်ထားသော နေရာကို ချုံ့လိုက်ခြင်း"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ဝဒ်ဂျက်"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"အသုံးပြုသူ ရွေးချယ်ရာ"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"အခြေအနေ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"ကင်မရာ"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"မီဒီယာ ထိန်းချုပ်မှုများ"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"ဝဒ်ဂျက်များ နေရာစီခြင်း စတင်ပါပြီ"</string>
@@ -79,20 +78,21 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ဖွင့်တာကို ပယ်ဖျက်ပါ"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ကို ဖျက်ပစ်ရန် ချ လိုက်ပါ"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ကို ဖျက်ပစ်မည် မဟုတ်ပါ"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g> အတွက် နောက် သတိပေးရန် သတ်မှတ်ချက်"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
     <string name="keyboardview_keycode_alt" msgid="4856868820040051939">"Altခလုတ်"</string>
     <string name="keyboardview_keycode_cancel" msgid="1203984017245783244">"ပယ်ဖျက်ရန်ခလုတ်"</string>
     <string name="keyboardview_keycode_delete" msgid="3337914833206635744">"ဖျက်ရန်ခလုတ်"</string>
-    <string name="keyboardview_keycode_done" msgid="1992571118466679775">"ပြီးဆုံးသည့်ခလုတ်"</string>
+    <string name="keyboardview_keycode_done" msgid="1992571118466679775">"ပြီးဆုံးသည့်ခလုတ်"</string>
     <string name="keyboardview_keycode_mode_change" msgid="4547387741906537519">"စနစ်ပြောင်းခြင်းခလုတ်"</string>
     <string name="keyboardview_keycode_shift" msgid="2270748814315147690">"Shiftခလုတ်"</string>
     <string name="keyboardview_keycode_enter" msgid="2985864015076059467">"Enterခလုတ်"</string>
-    <string name="description_target_unlock" msgid="2228524900439801453">"ဖွင့်ရန်"</string>
+    <string name="description_target_unlock" msgid="2228524900439801453">"ဖွင့်ရန်"</string>
     <string name="description_target_camera" msgid="969071997552486814">"ကင်မရာ"</string>
     <string name="description_target_silent" msgid="893551287746522182">"အသံတိတ်ရန်"</string>
-    <string name="description_target_soundon" msgid="30052466675500172">"အသံဖွင့်သည်"</string>
+    <string name="description_target_soundon" msgid="30052466675500172">"အသံဖွင့်သည်"</string>
     <string name="description_target_search" msgid="3091587249776033139">"ရှာဖွေရန်"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> အတွက် အပေါ်ကို ပွတ်ဆွဲပါ"</string>
     <string name="description_direction_down" msgid="5087739728639014595">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> အတွက် အောက်ကို ပွတ်ဆွဲပါ"</string>
diff --git a/packages/Keyguard/res/values-nb/strings.xml b/packages/Keyguard/res/values-nb/strings.xml
index 44b9641..8c6681d 100644
--- a/packages/Keyguard/res/values-nb/strings.xml
+++ b/packages/Keyguard/res/values-nb/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Opplåsingsfeltet skjules."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>-modul."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Brukervelgeren"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediekontroll"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Endring av modulplasseringen har startet."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Starten ble kansellert"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Slipp <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> for å slette den."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> blir ikke slettet."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Neste alarm er innstilt for <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ne-rNP/strings.xml b/packages/Keyguard/res/values-ne-rNP/strings.xml
index 14cdbfd..0906ff4 100644
--- a/packages/Keyguard/res/values-ne-rNP/strings.xml
+++ b/packages/Keyguard/res/values-ne-rNP/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"अनलक क्षेत्र भत्कियो।"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> विजेट।"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"प्रयोगकर्ता छनौटकर्ता"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"स्थिति"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"क्यामेरा"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"मिडिया नियन्त्रणहरू"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"विजेट पुनःक्रम गर्ने सुरु भयो।"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"सुरुवात रद्द गरियो"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"मेट्नको लागि <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ड्रप गर्नुहोस्"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> मेटिने छैन।"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g> को लागि अर्को चेतावनी सेट"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?१२३"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-nl/strings.xml b/packages/Keyguard/res/values-nl/strings.xml
index 5006f49..e3538a1 100644
--- a/packages/Keyguard/res/values-nl/strings.xml
+++ b/packages/Keyguard/res/values-nl/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Ontgrendelingsgebied samengevouwen."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Gebruikersselectie"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Camera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediabediening"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Opnieuw indelen van widget gestart."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Start geannuleerd"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Zet <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> neer om te verwijderen."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> wordt niet verwijderd."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Volgende alarm ingesteld voor <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"Alt"</string>
diff --git a/packages/Keyguard/res/values-pl/strings.xml b/packages/Keyguard/res/values-pl/strings.xml
index 8e22a5a..f879573 100644
--- a/packages/Keyguard/res/values-pl/strings.xml
+++ b/packages/Keyguard/res/values-pl/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Zwinięto obszar odblokowania."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widżet <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Wybór użytkownika"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stan"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Aparat"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Elementy sterujące multimediów"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Rozpoczęto zmienianie kolejności widżetów."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Uruchomienie anulowane"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Upuść <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>, by usunąć."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> nie zostanie usunięty."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Następny alarm ustawiono na <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-port/alias.xml b/packages/Keyguard/res/values-port/alias.xml
deleted file mode 100644
index c3ecbb9..0000000
--- a/packages/Keyguard/res/values-port/alias.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* //device/apps/common/assets/res/any/colors.xml
-**
-** Copyright 2012, 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.
-*/
--->
-<resources>
-    <!-- Alias used to reference one of two possible layouts in keyguard.  -->
-    <item type="layout" name="keyguard_eca">@layout/keyguard_emergency_carrier_area</item>
-</resources>
diff --git a/packages/Keyguard/res/values-pt-rPT/strings.xml b/packages/Keyguard/res/values-pt-rPT/strings.xml
index 443f4c2..4212c85 100644
--- a/packages/Keyguard/res/values-pt-rPT/strings.xml
+++ b/packages/Keyguard/res/values-pt-rPT/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Área de desbloqueio minimizada."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Seletor de utilizadores"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Estado"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Câmara"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controlos de multimédia"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Reordenação de widgets iniciada."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Lançamento cancelado"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Largue <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> para eliminar."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> não será eliminado."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Próximo alarme definido para as <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-pt/strings.xml b/packages/Keyguard/res/values-pt/strings.xml
index f7d6c1b..3d30218 100644
--- a/packages/Keyguard/res/values-pt/strings.xml
+++ b/packages/Keyguard/res/values-pt/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Área de desbloqueio recolhida."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget de <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Seletor de usuários"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Câmera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Controles de mídia"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Reordenação de widgets iniciada."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Inicialização cancelada"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Solte <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> para excluir."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> não será excluído."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Próximo alarme definido para <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ro/strings.xml b/packages/Keyguard/res/values-ro/strings.xml
index 2ab07b4..f33bc62 100644
--- a/packages/Keyguard/res/values-ro/strings.xml
+++ b/packages/Keyguard/res/values-ro/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Zona de deblocare a fost restrânsă."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Selector utilizator"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stare"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Cameră foto"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Comenzi media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"A început reordonarea widgeturilor."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Lansare anulată"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Eliberați <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> pentru a șterge."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Widgetul <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> nu va fi șters."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Următoarea alarmă este setată la <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ru/strings.xml b/packages/Keyguard/res/values-ru/strings.xml
index 56e9e54..7f31008 100644
--- a/packages/Keyguard/res/values-ru/strings.xml
+++ b/packages/Keyguard/res/values-ru/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Область разблокировки свернута"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Виджет \"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>\""</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Выбор аккаунта"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Статус"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Управление блокировкой"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Начато переопределение порядка виджетов"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Запуск отменен."</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Отпустите виджет \"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>\", чтобы удалить его."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Виджет \"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>\" не будет удален."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Будильник сработает в <xliff:g id="ALARM">%1$s</xliff:g>."</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"АБВ"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-si-rLK/strings.xml b/packages/Keyguard/res/values-si-rLK/strings.xml
index 183de7a..e99c488 100644
--- a/packages/Keyguard/res/values-si-rLK/strings.xml
+++ b/packages/Keyguard/res/values-si-rLK/strings.xml
@@ -55,7 +55,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"අගුළු අරින ප්‍රදේශය හැකිලී ඇත."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> විජට්."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"පරිශීලක තෝරන්නා"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"තත්වය"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"කැමරාව"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"මාධ්‍ය පාලක"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"විජටය නැවත අනුපිළිවෙළට සැකසිම ඇරඹුණි."</string>
@@ -81,6 +80,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"දියත් කිරීම අවලංගු කර ඇත"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"මැකීමට <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> හෙලන්න."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> මකා දමා නැත."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"<xliff:g id="ALARM">%1$s</xliff:g> ට ඊළඟ සීනුව සකස් කර ඇත"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-sk/strings.xml b/packages/Keyguard/res/values-sk/strings.xml
index de18f14..f4c802f 100644
--- a/packages/Keyguard/res/values-sk/strings.xml
+++ b/packages/Keyguard/res/values-sk/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Oblasť na odomknutie bola zúžená."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Miniaplikácia <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Výber používateľa"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stav"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotoaparát"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Ovládacie prvky médií"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Zmena usporiadania miniaplikácií sa začala."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Spustenie bolo zrušené"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Uvoľnením dotyku miniaplikáciu <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> odstránite."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Miniaplikácia <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> nebude odstránená."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Nasledujúci budík je nastavený na <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-sl/strings.xml b/packages/Keyguard/res/values-sl/strings.xml
index 981fb44..7d14282 100644
--- a/packages/Keyguard/res/values-sl/strings.xml
+++ b/packages/Keyguard/res/values-sl/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Območje odklepanja strnjeno."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Pripomoček <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Izbirnik uporabnika"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Stanje"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Fotoaparat"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Kontrolniki predstavnosti"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Prerazporejanje pripomočkov začeto."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Zagon je preklican"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Izpustite pripomoček <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>, da ga izbrišete."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Pripomoček <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ne bo izbrisan."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Naslednji alarm je nastavljen za <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-sr/strings.xml b/packages/Keyguard/res/values-sr/strings.xml
index b944237..8d84cb5 100644
--- a/packages/Keyguard/res/values-sr/strings.xml
+++ b/packages/Keyguard/res/values-sr/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Област откључавања је скупљена."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Виџет <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Избор корисника"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Статус"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Контроле за медије"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Започела је промена редоследа виџета."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Покретање је отказано"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Отпустите виџет <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> да бисте га избрисали."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Виџет <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> неће бити избрисан."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Следећи аларм је подешен за <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-sv/strings.xml b/packages/Keyguard/res/values-sv/strings.xml
index c7ba630..b860077 100644
--- a/packages/Keyguard/res/values-sv/strings.xml
+++ b/packages/Keyguard/res/values-sv/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Komprimerad upplåsningsyta."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Widget för <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Användarväljare"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Status"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mediereglage"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Ändring av widgetarnas ordning har påbörjats."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Lanseringen har avbrutits"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Ta bort genom att släppa <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> här."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> kommer inte att tas bort."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Nästa alarm är inställt på <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-sw/strings.xml b/packages/Keyguard/res/values-sw/strings.xml
index ca2ce47..7b4f46b 100644
--- a/packages/Keyguard/res/values-sw/strings.xml
+++ b/packages/Keyguard/res/values-sw/strings.xml
@@ -39,8 +39,8 @@
     <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"Hakuna SIM kadi"</string>
     <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"Hakuna SIM kadi katika kompyuta ndogo."</string>
     <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"Hakuna SIM kadi kwenye simu."</string>
-    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"Ingiza SIM kadi."</string>
-    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"SIM kadi haiko au haisomeki. Ingiza SIM kadi."</string>
+    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"Weka SIM kadi."</string>
+    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"SIM kadi haiko au haisomeki. Weka SIM kadi."</string>
     <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"SIM kadi isiyotumika."</string>
     <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"SIM kadi yako imefungwa kabisa.\n Wasiliana na mtoa huduma wako wa pasi waya ili upate SIM kadi nyingine."</string>
     <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"SIM kadi imefungwa."</string>
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Eneo la kufungua limekunjwa."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ya wiji."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Kiteuzi cha mtumiaji"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Hali"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Vidhibiti vya media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Upangaji upya wa wijeti umeanza."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Uzinduzi umeghairiwa"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Dondosha <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ili ufute."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> haitafutwa."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Kengele inayofuata imewekwa ilie saa <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
@@ -108,7 +108,7 @@
     <string name="kg_pattern_instructions" msgid="398978611683075868">"Chora ruwaza yako"</string>
     <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"Ingiza PIN ya SIM"</string>
     <string name="kg_pin_instructions" msgid="2377242233495111557">"Ingiza PIN"</string>
-    <string name="kg_password_instructions" msgid="5753646556186936819">"Ingiza Nenosiri"</string>
+    <string name="kg_password_instructions" msgid="5753646556186936819">"Weka Nenosiri"</string>
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM sasa imelemazwa. Ingiza msimbo wa PUK ili kuendelea. Wasiliana na mtoa huduma kwa maelezo."</string>
     <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"Ingiza msimbo wa PIN unaopendelewa"</string>
     <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"Thibitisha msimbo wa PIN unaopendelewa"</string>
diff --git a/packages/Keyguard/res/values-sw720dp/dimens.xml b/packages/Keyguard/res/values-sw720dp/dimens.xml
index 3e89a84..86d155e 100644
--- a/packages/Keyguard/res/values-sw720dp/dimens.xml
+++ b/packages/Keyguard/res/values-sw720dp/dimens.xml
@@ -21,9 +21,6 @@
     <!-- Size of the clock font in keyguard's status view -->
     <dimen name="kg_status_clock_font_size">140dp</dimen>
 
-    <!-- Size of the generic status lines keyguard's status view  -->
-    <dimen name="kg_status_line_font_size">19sp</dimen>
-
     <!-- Top margin for the clock view --> 
     <dimen name="kg_clock_top_margin">0dp</dimen>
 
diff --git a/packages/Keyguard/res/values-ta-rIN/strings.xml b/packages/Keyguard/res/values-ta-rIN/strings.xml
index 5b6a490..b763457 100644
--- a/packages/Keyguard/res/values-ta-rIN/strings.xml
+++ b/packages/Keyguard/res/values-ta-rIN/strings.xml
@@ -21,14 +21,14 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_name" msgid="719438068451601849">"விசைப்பாதுகாப்பு"</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"PIN குறியீட்டை உள்ளிடவும்"</string>
-    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"SIM PUK மற்றும் புதிய PIN குறியீட்டைத் தட்டச்சு செய்யவும்"</string>
-    <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"SIM PUK குறியீடு"</string>
-    <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"புதிய SIM PIN குறியீடு"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"பின் குறியீட்டை உள்ளிடவும்"</string>
+    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"சிம் PUK மற்றும் புதிய பின் குறியீட்டைத் தட்டச்சு செய்யவும்"</string>
+    <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"சிம் PUK குறியீடு"</string>
+    <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"புதிய சிம் பின் குறியீடு"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"கடவுச்சொல்லை உள்ளிட, தொடவும்"</font></string>
     <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"திறக்க, கடவுச்சொல்லை உள்ளிடவும்"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"திறக்க, PIN ஐ உள்ளிடவும்"</string>
-    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"தவறான PIN குறியீடு."</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"திறக்க, பின்னை உள்ளிடவும்"</string>
+    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"தவறான பின் குறியீடு."</string>
     <string name="keyguard_label_text" msgid="861796461028298424">"தடைநீக்க, மெனுவை அழுத்தி பின்பு 0 ஐ அழுத்தவும்."</string>
     <string name="faceunlock_multiple_failures" msgid="754137583022792429">"முகம் திறப்பதற்கான அதிகபட்ச முயற்சிகள் கடந்தன"</string>
     <string name="keyguard_charged" msgid="3272223906073492454">"சார்ஜ் செய்யப்பட்டது"</string>
@@ -36,16 +36,16 @@
     <string name="keyguard_low_battery" msgid="8143808018719173859">"உங்கள் சார்ஜரை இணைக்கவும்."</string>
     <string name="keyguard_instructions_when_pattern_disabled" msgid="1332288268600329841">"திறக்க, மெனுவை அழுத்தவும்."</string>
     <string name="keyguard_network_locked_message" msgid="9169717779058037168">"பிணையம் பூட்டப்பட்டது"</string>
-    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"SIM கார்டு இல்லை"</string>
-    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"டேப்லெட்டில் SIM கார்டு இல்லை."</string>
-    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"தொலைபேசியில் SIM கார்டு இல்லை."</string>
-    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"SIM கார்டைச் செருகவும்."</string>
-    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"SIM கார்டு இல்லை அல்லது படிக்கக்கூடியதாக இல்லை. SIM கார்டைச் செருகவும்."</string>
-    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"SIM கார்டைப் பயன்படுத்த முடியாது."</string>
-    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"உங்கள் SIM கார்டு நிரந்தரமாக முடக்கப்பட்டது.\n மற்றொரு SIM கார்டிற்காக உங்கள் வயர்லெஸ் சேவை வழங்குநரைத் தொடர்புகொள்ளவும்."</string>
-    <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"SIM கார்டு பூட்டப்பட்டுள்ளது."</string>
-    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"SIM கார்டு PUK ஆல் பூட்டப்பட்டது."</string>
-    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"SIM கார்டின் தடையைநீக்குகிறது..."</string>
+    <string name="keyguard_missing_sim_message_short" msgid="494980561304211931">"சிம் கார்டு இல்லை"</string>
+    <string name="keyguard_missing_sim_message" product="tablet" msgid="1445849005909260039">"டேப்லெட்டில் சிம் கார்டு இல்லை."</string>
+    <string name="keyguard_missing_sim_message" product="default" msgid="3481110395508637643">"தொலைபேசியில் சிம் கார்டு இல்லை."</string>
+    <string name="keyguard_missing_sim_instructions" msgid="5210891509995942250">"சிம் கார்டைச் செருகவும்."</string>
+    <string name="keyguard_missing_sim_instructions_long" msgid="5968985489463870358">"சிம் கார்டு இல்லை அல்லது படிக்கக்கூடியதாக இல்லை. சிம் கார்டைச் செருகவும்."</string>
+    <string name="keyguard_permanent_disabled_sim_message_short" msgid="8340813989586622356">"சிம் கார்டைப் பயன்படுத்த முடியாது."</string>
+    <string name="keyguard_permanent_disabled_sim_instructions" msgid="5892940909699723544">"உங்கள் சிம் கார்டு நிரந்தரமாக முடக்கப்பட்டது.\n மற்றொரு சிம் கார்டிற்காக உங்கள் வயர்லெஸ் சேவை வழங்குநரைத் தொடர்புகொள்ளவும்."</string>
+    <string name="keyguard_sim_locked_message" msgid="6875773413306380902">"சிம் கார்டு பூட்டப்பட்டுள்ளது."</string>
+    <string name="keyguard_sim_puk_locked_message" msgid="3747232467471801633">"சிம் கார்டு PUK ஆல் பூட்டப்பட்டது."</string>
+    <string name="keyguard_sim_unlock_progress_dialog_message" msgid="7975221805033614426">"சிம் கார்டின் தடையைநீக்குகிறது..."</string>
     <string name="keyguard_accessibility_widget_changed" msgid="5678624624681400191">"%1$s. விட்ஜெட் %2$d / %3$d."</string>
     <string name="keyguard_accessibility_add_widget" msgid="8273277058724924654">"விட்ஜெட்டைச் சேர்க்கவும்."</string>
     <string name="keyguard_accessibility_widget_empty_slot" msgid="1281505703307930757">"காலியானது"</string>
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"திறக்கும் பகுதி சுருக்கப்பட்டது."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> விட்ஜெட்."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"பயனர் தேர்வி"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"நிலை"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"கேமரா"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"மீடியா கட்டுப்பாடுகள்"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"விட்ஜெட்டை மீண்டும் வரிசைப்படுத்துவது தொடங்கியது."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"துவக்குவது ரத்துசெய்யப்பட்டது"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"நீக்குவதற்கு <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ஐ இழுக்கவும்."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> நீக்கப்படாது."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"அடுத்த அலாரம் <xliff:g id="ALARM">%1$s</xliff:g>க்கு அமைக்கப்பட்டது"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
@@ -103,20 +103,20 @@
     <string name="kg_forgot_pattern_button_text" msgid="8852021467868220608">"வடிவத்தை மறந்துவிட்டீர்களா"</string>
     <string name="kg_wrong_pattern" msgid="1850806070801358830">"தவறான வடிவம்"</string>
     <string name="kg_wrong_password" msgid="2333281762128113157">"தவறான கடவுச்சொல்"</string>
-    <string name="kg_wrong_pin" msgid="1131306510833563801">"தவறான PIN"</string>
+    <string name="kg_wrong_pin" msgid="1131306510833563801">"தவறான பின்"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"<xliff:g id="NUMBER">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"உங்கள் வடிவத்தை வரையவும்"</string>
-    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"SIM PIN ஐ உள்ளிடவும்"</string>
-    <string name="kg_pin_instructions" msgid="2377242233495111557">"PIN ஐ உள்ளிடுக"</string>
+    <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"சிம் பின்னை உள்ளிடவும்"</string>
+    <string name="kg_pin_instructions" msgid="2377242233495111557">"பின்னை உள்ளிடுக"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"கடவுச்சொல்லை உள்ளிடவும்"</string>
-    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM தற்போது முடக்கப்பட்டுள்ளது. தொடர்வதற்கு PUK குறியீட்டை உள்ளிடவும். விவரங்களுக்கு மொபைல் நிறுவனங்களைத் தொடர்புகொள்ளவும்."</string>
-    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"விரும்பிய PIN குறியீட்டை உள்ளிடவும்"</string>
-    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"விரும்பிய PIN குறியீட்டை உறுதிப்படுத்தவும்"</string>
-    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"SIM கார்டின் தடையைநீக்குகிறது..."</string>
-    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"4 இலிருந்து 8 எண்கள் வரையுள்ள PIN ஐ உள்ளிடவும்."</string>
+    <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"சிம் தற்போது முடக்கப்பட்டுள்ளது. தொடர்வதற்கு PUK குறியீட்டை உள்ளிடவும். விவரங்களுக்கு மொபைல் நிறுவனங்களைத் தொடர்புகொள்ளவும்."</string>
+    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"விரும்பிய பின் குறியீட்டை உள்ளிடவும்"</string>
+    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"விரும்பிய பின் குறியீட்டை உறுதிப்படுத்தவும்"</string>
+    <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"சிம் கார்டின் தடையைநீக்குகிறது..."</string>
+    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"4 இலிருந்து 8 எண்கள் வரையுள்ள பின்னை உள்ளிடவும்."</string>
     <string name="kg_invalid_sim_puk_hint" msgid="7553388325654369575">"PUK குறியீட்டில் 8 எண்கள் அல்லது அதற்கு மேல் இருக்க வேண்டும்."</string>
-    <string name="kg_invalid_puk" msgid="3638289409676051243">"சரியான PUK குறியீட்டை மீண்டும் உள்ளிடவும். தொடர் முயற்சிகள் SIM ஐ நிரந்தரமாக முடக்கிவிடும்."</string>
-    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN குறியீடுகள் பொருந்தவில்லை"</string>
+    <string name="kg_invalid_puk" msgid="3638289409676051243">"சரியான PUK குறியீட்டை மீண்டும் உள்ளிடவும். தொடர் முயற்சிகள் சிம் ஐ நிரந்தரமாக முடக்கிவிடும்."</string>
+    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"பின் குறியீடுகள் பொருந்தவில்லை"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"அதிகமான வடிவ முயற்சிகள்"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"திறக்க, உங்கள் Google கணக்கு மூலம் உள்நுழையவும்."</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"பயனர்பெயர் (மின்னஞ்சல்)"</string>
@@ -125,7 +125,7 @@
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"தவறான பயனர்பெயர் அல்லது கடவுச்சொல்."</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"உங்கள் பயனர்பெயர் அல்லது கடவுச்சொல்லை மறந்துவிட்டீர்களா?\n"<b>"google.com/accounts/recovery"</b>" ஐப் பார்வையிடவும்."</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"கணக்கைச் சரிபார்க்கிறது…"</string>
-    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"உங்கள் PIN ஐ <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
+    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"உங்கள் பின்னை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"உங்கள் கடவுச்சொல்லை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக உள்ளிட்டீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். \n\n<xliff:g id="NUMBER_1">%d</xliff:g> வினாடிகளில் மீண்டும் முயற்சிக்கவும்."</string>
     <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"டேப்லெட்டைத் திறக்க <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக முயற்சித்துள்ளீர்கள். இன்னும் <xliff:g id="NUMBER_1">%d</xliff:g> தோல்வி முயற்சிகளுக்குப் பிறகு, டேப்லெட்டானது ஆரம்பநிலைக்கு மீட்டமைக்கப்பட்டு, எல்லா பயனர் தரவையும் இழப்பீர்கள்."</string>
@@ -136,18 +136,18 @@
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"திறப்பதற்கான வடிவத்தை <xliff:g id="NUMBER_0">%d</xliff:g> முறை தவறாக வரைந்துள்ளீர்கள். மேலும் <xliff:g id="NUMBER_1">%d</xliff:g> தோல்வி முயற்சிகளுக்குப் பிறகு, மின்னஞ்சல் கணக்கைப் பயன்படுத்தி உங்கள் மொபைலைத் திறக்கக் கேட்கப்படுவீர்கள்.\n\n <xliff:g id="NUMBER_2">%d</xliff:g> வினாடிகள் கழித்து முயற்சிக்கவும்."</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
     <string name="kg_reordering_delete_drop_target_text" msgid="7899202978204438708">"அகற்று"</string>
-    <string name="kg_password_wrong_pin_code_pukked" msgid="30531039455764924">"SIM PIN குறியீடு தவறானது, உங்கள் சாதனத்தின் தடையை நீக்க, உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ள வேண்டும்."</string>
+    <string name="kg_password_wrong_pin_code_pukked" msgid="30531039455764924">"சிம் பின் குறியீடு தவறானது, உங்கள் சாதனத்தின் தடையை நீக்க, உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ள வேண்டும்."</string>
   <plurals name="kg_password_wrong_pin_code">
-    <item quantity="one" msgid="8134313997799638254">"SIM PIN குறியீடு தவறானது, உங்கள் சாதனத்தைத் திறக்க, உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ளும் முன், மேலும் <xliff:g id="NUMBER">%d</xliff:g> முறை முயர்ச்சிக்கலாம்."</item>
-    <item quantity="other" msgid="2215723361575359486">"SIM PIN குறியீடு தவறானது, மேலும் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
+    <item quantity="one" msgid="8134313997799638254">"சிம் பின் குறியீடு தவறானது, உங்கள் சாதனத்தைத் திறக்க, உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ளும் முன், மேலும் <xliff:g id="NUMBER">%d</xliff:g> முறை முயர்ச்சிக்கலாம்."</item>
+    <item quantity="other" msgid="2215723361575359486">"சிம் பின் குறியீடு தவறானது, மேலும் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
   </plurals>
-    <string name="kg_password_wrong_puk_code_dead" msgid="7077536808291316208">"SIM பயன்பாட்டிற்கு உகந்தது அல்ல. உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ளவும்."</string>
+    <string name="kg_password_wrong_puk_code_dead" msgid="7077536808291316208">"சிம் பயன்பாட்டிற்கு உகந்தது அல்ல. உங்கள் மொபைல் நிறுவனத்தைத் தொடர்புகொள்ளவும்."</string>
   <plurals name="kg_password_wrong_puk_code">
-    <item quantity="one" msgid="3256893607561060649">"SIM PUK குறியீடு தவறானது, சிம் நிரந்தரமாகப் பயன்படுத்த முடியாமல் போவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயர்ச்சிக்கலாம்."</item>
-    <item quantity="other" msgid="5477305226026342036">"SIM PUK குறியீடு தவறானது, SIM நிரந்தரமாகப் பயன்படுத்த முடியாமல் போவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
+    <item quantity="one" msgid="3256893607561060649">"சிம் PUK குறியீடு தவறானது, சிம் நிரந்தரமாகப் பயன்படுத்த முடியாமல் போவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயர்ச்சிக்கலாம்."</item>
+    <item quantity="other" msgid="5477305226026342036">"சிம் PUK குறியீடு தவறானது, சிம் நிரந்தரமாகப் பயன்படுத்த முடியாமல் போவதற்கு முன், நீங்கள் <xliff:g id="NUMBER">%d</xliff:g> முறை முயற்சிக்கலாம்."</item>
   </plurals>
-    <string name="kg_password_pin_failed" msgid="6268288093558031564">"SIM PIN செயல்பாடு தோல்வி!"</string>
-    <string name="kg_password_puk_failed" msgid="2838824369502455984">"SIM PUK செயல்பாடு தோல்வி!"</string>
+    <string name="kg_password_pin_failed" msgid="6268288093558031564">"சிம் பின் செயல்பாடு தோல்வி!"</string>
+    <string name="kg_password_puk_failed" msgid="2838824369502455984">"சிம் PUK செயல்பாடு தோல்வி!"</string>
     <string name="kg_pin_accepted" msgid="1448241673570020097">"குறியீடு ஏற்கப்பட்டது!"</string>
     <string name="keyguard_transport_prev_description" msgid="8229108430245669854">"முந்தைய டிராக்கிற்கான பொத்தான்"</string>
     <string name="keyguard_transport_next_description" msgid="4299258300283778305">"அடுத்த டிராக்கிற்கான பொத்தான்"</string>
diff --git a/packages/Keyguard/res/values-te-rIN/strings.xml b/packages/Keyguard/res/values-te-rIN/strings.xml
index 6c71c05..635301e 100644
--- a/packages/Keyguard/res/values-te-rIN/strings.xml
+++ b/packages/Keyguard/res/values-te-rIN/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"అన్‌లాక్ ప్రాంతం కుదించబడింది."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> విడ్జెట్."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"వినియోగదారు ఎంపికకర్త"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"స్థితి"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"కెమెరా"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"మీడియా నియంత్రణలు"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"విడ్జెట్ పునఃక్రమం ప్రారంభించబడింది."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ప్రారంభం రద్దయింది"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"తొలగించడానికి <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>ను వదలండి."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> తొలగించబడదు."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"తదుపరి అలారం <xliff:g id="ALARM">%1$s</xliff:g>కి సెట్ చేయబడింది"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-th/strings.xml b/packages/Keyguard/res/values-th/strings.xml
index c724d85..eb1f7c3 100644
--- a/packages/Keyguard/res/values-th/strings.xml
+++ b/packages/Keyguard/res/values-th/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"ยุบพื้นที่ปลดล็อกแล้ว"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"วิดเจ็ต <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"ตัวเลือกผู้ใช้"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"สถานะ"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"กล้องถ่ายรูป"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"การควบคุมสื่อ"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"เริ่มเรียงลำดับวิดเจ็ตใหม่"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"ยกเลิกการเปิดใช้งานแล้ว"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"ลาก <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> เพื่อลบ"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> จะไม่ถูกลบ"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"ตั้งเวลาปลุกครั้งถัดไปไว้ที่ <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-tl/strings.xml b/packages/Keyguard/res/values-tl/strings.xml
index 5a1090a..96a140b 100644
--- a/packages/Keyguard/res/values-tl/strings.xml
+++ b/packages/Keyguard/res/values-tl/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Pinaliit ang bahagi ng pag-unlock."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Tagapili ng user"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Katayuan"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Camera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Mga kontrol ng media"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Nagsimula na ang pagbabago ng ayos ng widget."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Nakansela ang paglunsad"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"I-drop ang <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> upang tanggalin."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"Hindi tatanggalin ang <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Nakatakda ang susunod na alarm para sa <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-tr/strings.xml b/packages/Keyguard/res/values-tr/strings.xml
index e2c1892..b38789d 100644
--- a/packages/Keyguard/res/values-tr/strings.xml
+++ b/packages/Keyguard/res/values-tr/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Kilit açma alanı daraltıldı."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget\'ı."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Kullanıcı seçici"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Durum"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Medya denetimleri"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Widget\'ları yeniden sıralama işlemi başladı."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Başlatma iptal edildi"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Silmek için <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> widget\'ını bırakın."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> silinmeyecek."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Sonraki alarm <xliff:g id="ALARM">%1$s</xliff:g> için ayarlandı"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-uk/strings.xml b/packages/Keyguard/res/values-uk/strings.xml
index 519aa4d..dc48ace 100644
--- a/packages/Keyguard/res/values-uk/strings.xml
+++ b/packages/Keyguard/res/values-uk/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Область розблокування згорнуто."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"Віджет <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Вибір користувача"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Статус"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Камера"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Елементи керування носієм"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Змінення порядку віджетів розпочато."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Запуск скасовано"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Відпустіть <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>, щоб видалити."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> не буде видалено."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Наступний сигнал: <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-ur-rPK/strings.xml b/packages/Keyguard/res/values-ur-rPK/strings.xml
index b7772e5..4921c28 100644
--- a/packages/Keyguard/res/values-ur-rPK/strings.xml
+++ b/packages/Keyguard/res/values-ur-rPK/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"غیر مقفل کرنے کا علاقہ سکیڑ دیا گیا۔"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ویجیٹ۔"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"صارف کا انتخاب کار"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"اسٹیٹس"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"کیمرا"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"میڈیا کنٹرولز"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"ویجیٹ دوبارہ ترتیب دینا شروع ہو گیا۔"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"شروعات کو منسوخ کر دیا گیا"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"حذف کرنے کیلئے <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> کو ڈراپ کریں۔"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> کو حذف نہیں کیا جائے گا۔"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"اگلا الارم <xliff:g id="ALARM">%1$s</xliff:g> کیلئے سیٹ ہے"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"‎?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-uz-rUZ/strings.xml b/packages/Keyguard/res/values-uz-rUZ/strings.xml
index 649eb90..ba09118 100644
--- a/packages/Keyguard/res/values-uz-rUZ/strings.xml
+++ b/packages/Keyguard/res/values-uz-rUZ/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Qulfni ochish maydoni yig‘ildi."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> vidjeti."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Foydalanuvchi tanlagichi"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Holati"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Kamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Media boshqaruvlari"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Vidjetlarni saralashni boshlandi."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Ishga tushirish bekor qilindi"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"O‘chirish uchun <xliff:g id="WIDGET_INDEX">%1$s</xliff:g>ni pastga tashlang."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> o‘chirilmaydi."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Keyingi uyg‘otkich <xliff:g id="ALARM">%1$s</xliff:g> uchun o‘rnatildi"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-vi/strings.xml b/packages/Keyguard/res/values-vi/strings.xml
index e1f0bd8..c640c04 100644
--- a/packages/Keyguard/res/values-vi/strings.xml
+++ b/packages/Keyguard/res/values-vi/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Đã thu gọn vùng khóa."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> tiện ích."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Bộ chọn người dùng"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Trạng thái"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Máy ảnh"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Điều khiển phương tiện"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Đã bắt đầu xắp xếp lại tiện ích."</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Quá trình chạy bị hủy"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Thả <xliff:g id="WIDGET_INDEX">%1$s</xliff:g> để xóa."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> sẽ không bị xóa."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"Báo thức tiếp theo được đặt cho <xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-zh-rCN/strings.xml b/packages/Keyguard/res/values-zh-rCN/strings.xml
index 8ea80bb..295df9c 100644
--- a/packages/Keyguard/res/values-zh-rCN/strings.xml
+++ b/packages/Keyguard/res/values-zh-rCN/strings.xml
@@ -21,14 +21,14 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_name" msgid="719438068451601849">"Keyguard"</string>
-    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"输入 PIN 码"</string>
-    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"请输入SIM卡PUK码和新的 PIN 码"</string>
+    <string name="keyguard_password_enter_pin_code" msgid="3037685796058495017">"输入PIN码"</string>
+    <string name="keyguard_password_enter_puk_code" msgid="3035856550289724338">"请输入SIM卡PUK码和新的PIN码"</string>
     <string name="keyguard_password_enter_puk_prompt" msgid="1801941051094974609">"SIM卡PUK码"</string>
     <string name="keyguard_password_enter_pin_prompt" msgid="3201151840570492538">"新SIM卡PIN码"</string>
     <string name="keyguard_password_entry_touch_hint" msgid="7858547464982981384"><font size="17">"触摸可输入密码"</font></string>
     <string name="keyguard_password_enter_password_code" msgid="1054721668279049780">"输入密码以解锁"</string>
-    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"输入 PIN 进行解锁"</string>
-    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"PIN 码有误。"</string>
+    <string name="keyguard_password_enter_pin_password_code" msgid="6391755146112503443">"输入PIN码进行解锁"</string>
+    <string name="keyguard_password_wrong_pin_code" msgid="2422225591006134936">"PIN码有误。"</string>
     <string name="keyguard_label_text" msgid="861796461028298424">"要解锁,请先按 MENU 再按 0。"</string>
     <string name="faceunlock_multiple_failures" msgid="754137583022792429">"已超过“人脸解锁”尝试次数上限"</string>
     <string name="keyguard_charged" msgid="3272223906073492454">"充电完成"</string>
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"已折叠解锁区域。"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>小部件。"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"用户选择器"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"状态"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"相机"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"媒体控制"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"已开始将小部件重新排序。"</string>
@@ -63,7 +62,7 @@
     <string name="keyguard_accessibility_slide_unlock" msgid="2959928478764697254">"滑动解锁。"</string>
     <string name="keyguard_accessibility_pattern_unlock" msgid="1490840706075246612">"图案解锁。"</string>
     <string name="keyguard_accessibility_face_unlock" msgid="4817282543351718535">"人脸解锁。"</string>
-    <string name="keyguard_accessibility_pin_unlock" msgid="2469687111784035046">"PIN 解锁。"</string>
+    <string name="keyguard_accessibility_pin_unlock" msgid="2469687111784035046">"PIN码解锁。"</string>
     <string name="keyguard_accessibility_password_unlock" msgid="7675777623912155089">"密码解锁。"</string>
     <string name="keyguard_accessibility_pattern_area" msgid="7679891324509597904">"图案区域。"</string>
     <string name="keyguard_accessibility_slide_area" msgid="6736064494019979544">"滑动区域。"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"启动已取消"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"放下<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>即可将其删除。"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>将不会被删除。"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"下次闹钟时间已设置为<xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
@@ -103,20 +103,20 @@
     <string name="kg_forgot_pattern_button_text" msgid="8852021467868220608">"忘记了图案"</string>
     <string name="kg_wrong_pattern" msgid="1850806070801358830">"图案错误"</string>
     <string name="kg_wrong_password" msgid="2333281762128113157">"密码错误"</string>
-    <string name="kg_wrong_pin" msgid="1131306510833563801">"PIN 有误"</string>
+    <string name="kg_wrong_pin" msgid="1131306510833563801">"PIN码有误"</string>
     <string name="kg_too_many_failed_attempts_countdown" msgid="6358110221603297548">"请在 <xliff:g id="NUMBER">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_pattern_instructions" msgid="398978611683075868">"绘制您的图案"</string>
     <string name="kg_sim_pin_instructions" msgid="2319508550934557331">"输入SIM卡PIN码"</string>
-    <string name="kg_pin_instructions" msgid="2377242233495111557">"输入 PIN"</string>
+    <string name="kg_pin_instructions" msgid="2377242233495111557">"输入PIN码"</string>
     <string name="kg_password_instructions" msgid="5753646556186936819">"输入密码"</string>
     <string name="kg_puk_enter_puk_hint" msgid="453227143861735537">"SIM卡已被停用,需要输入PUK码才能继续使用。有关详情,请联系您的运营商。"</string>
-    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"请输入所需 PIN 码"</string>
-    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"请确认所需 PIN 码"</string>
+    <string name="kg_puk_enter_pin_hint" msgid="7871604527429602024">"请输入所需的PIN码"</string>
+    <string name="kg_enter_confirm_pin_hint" msgid="325676184762529976">"请确认所需的PIN码"</string>
     <string name="kg_sim_unlock_progress_dialog_message" msgid="8950398016976865762">"正在解锁SIM卡..."</string>
-    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"请输入 4 至 8 位数的 PIN。"</string>
+    <string name="kg_invalid_sim_pin_hint" msgid="8795159358110620001">"请输入4至8位数的PIN码。"</string>
     <string name="kg_invalid_sim_puk_hint" msgid="7553388325654369575">"PUK码应至少包含8位数字。"</string>
     <string name="kg_invalid_puk" msgid="3638289409676051243">"请重新输入正确的PUK码。如果尝试错误次数过多,SIM卡将永久停用。"</string>
-    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN 码不匹配"</string>
+    <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN码不匹配"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"图案尝试次数过多"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"要解锁,请登录您的Google帐户。"</string>
     <string name="kg_login_username_hint" msgid="5718534272070920364">"用户名(电子邮件地址)"</string>
@@ -125,13 +125,13 @@
     <string name="kg_login_invalid_input" msgid="5754664119319872197">"用户名或密码无效。"</string>
     <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘记了用户名或密码?\n请访问 "<b>"google.com/accounts/recovery"</b>"。"</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"正在检查帐户…"</string>
-    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了 PIN。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
+    <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次输错了PIN码。\n\n请在<xliff:g id="NUMBER_1">%d</xliff:g>秒后重试。"</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地输入了密码。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。\n\n请在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒后重试。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁平板电脑。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,平板电脑就会重置为出厂默认设置,而且所有用户数据都会丢失。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地尝试解锁手机。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,手机就会重置为出厂默认设置,而且所有用户数据都会丢失。"</string>
-    <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁平板电脑。平板电脑现在将重置为出厂默认设置。"</string>
-    <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您已经 <xliff:g id="NUMBER">%d</xliff:g> 次错误地尝试解锁手机。手机现在将重置为出厂默认设置。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地尝试解锁平板电脑。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,平板电脑就会恢复为出厂默认设置,而且所有用户数据都会丢失。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您已经<xliff:g id="NUMBER_0">%d</xliff:g>次错误地尝试解锁手机。如果再尝试<xliff:g id="NUMBER_1">%d</xliff:g>次后仍不成功,手机就会恢复为出厂默认设置,而且所有用户数据都会丢失。"</string>
+    <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁平板电脑。平板电脑现在将恢复为出厂默认设置。"</string>
+    <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您已经<xliff:g id="NUMBER">%d</xliff:g>次错误地尝试解锁手机。手机现在将恢复为出厂默认设置。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="tablet" msgid="3253575572118914370">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,系统就会要求您使用自己的电子邮件帐户解锁平板电脑。\n\n请在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="default" msgid="1437638152015574839">"您已经 <xliff:g id="NUMBER_0">%d</xliff:g> 次错误地绘制了解锁图案。如果再尝试 <xliff:g id="NUMBER_1">%d</xliff:g> 次后仍不成功,系统就会要求您使用自己的电子邮件帐户解锁手机。\n\n请在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒后重试。"</string>
     <string name="kg_text_message_separator" product="default" msgid="4160700433287233771">" — "</string>
diff --git a/packages/Keyguard/res/values-zh-rHK/strings.xml b/packages/Keyguard/res/values-zh-rHK/strings.xml
index 280dea3..f196ffd 100644
--- a/packages/Keyguard/res/values-zh-rHK/strings.xml
+++ b/packages/Keyguard/res/values-zh-rHK/strings.xml
@@ -52,8 +52,7 @@
     <string name="keyguard_accessibility_unlock_area_expanded" msgid="2278106022311170299">"解鎖區域已展開。"</string>
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"解鎖區域已收合。"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>小工具。"</string>
-    <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"用戶選取工具"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"狀態"</string>
+    <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"使用者選取工具"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"相機"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"媒體控制"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"已開始為小工具重新排列次序。"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"已取消啟動"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"拖放「<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>」即可刪除。"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"「<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>」將不會被刪除。"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"已設定下一個鬧鐘時間:<xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
@@ -98,7 +98,7 @@
     <string name="description_direction_down" msgid="5087739728639014595">"向下滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"向左滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
     <string name="description_direction_right" msgid="8034433242579600980">"向右滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
-    <string name="user_switched" msgid="3768006783166984410">"目前的用戶是<xliff:g id="NAME">%1$s</xliff:g>。"</string>
+    <string name="user_switched" msgid="3768006783166984410">"目前的使用者是<xliff:g id="NAME">%1$s</xliff:g>。"</string>
     <string name="kg_emergency_call_label" msgid="684946192523830531">"緊急電話"</string>
     <string name="kg_forgot_pattern_button_text" msgid="8852021467868220608">"忘記圖案"</string>
     <string name="kg_wrong_pattern" msgid="1850806070801358830">"圖案錯誤"</string>
@@ -119,17 +119,17 @@
     <string name="kg_invalid_confirm_pin_hint" product="default" msgid="7003469261464593516">"PIN 碼不符"</string>
     <string name="kg_login_too_many_attempts" msgid="6486842094005698475">"圖案嘗試次數過多"</string>
     <string name="kg_login_instructions" msgid="1100551261265506448">"如要解鎖,請以 Google 帳戶登入。"</string>
-    <string name="kg_login_username_hint" msgid="5718534272070920364">"用戶名稱 (電子郵件)"</string>
+    <string name="kg_login_username_hint" msgid="5718534272070920364">"使用者名稱 (電子郵件)"</string>
     <string name="kg_login_password_hint" msgid="9057289103827298549">"密碼"</string>
     <string name="kg_login_submit_button" msgid="5355904582674054702">"登入"</string>
-    <string name="kg_login_invalid_input" msgid="5754664119319872197">"無效的用戶名稱或密碼。"</string>
-    <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘記用戶名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
+    <string name="kg_login_invalid_input" msgid="5754664119319872197">"無效的使用者名稱或密碼。"</string>
+    <string name="kg_login_account_recovery_hint" msgid="5690709132841752974">"忘記使用者名稱或密碼?\n請瀏覽 "<b>"google.com/accounts/recovery"</b>"。"</string>
     <string name="kg_login_checking_password" msgid="1052685197710252395">"正在檢查帳戶…"</string>
     <string name="kg_too_many_failed_pin_attempts_dialog_message" msgid="8276745642049502550">"您已輸入錯誤的 PIN 碼 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
     <string name="kg_too_many_failed_password_attempts_dialog_message" msgid="7813713389422226531">"您已輸入錯誤的密碼 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
     <string name="kg_too_many_failed_pattern_attempts_dialog_message" msgid="74089475965050805">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次。\n\n請在 <xliff:g id="NUMBER_1">%d</xliff:g> 秒後再試一次。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,平板電腦將回復原廠設定,所有用戶資料均會失去。"</string>
-    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,手機將回復原廠設定,所有用戶資料均會失去。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="tablet" msgid="1575557200627128949">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,平板電腦將回復原廠設定,所有使用者資料均會失去。"</string>
+    <string name="kg_failed_attempts_almost_at_wipe" product="default" msgid="4051015943038199910">"您嘗試了 <xliff:g id="NUMBER_0">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,手機將回復原廠設定,所有使用者資料均會失去。"</string>
     <string name="kg_failed_attempts_now_wiping" product="tablet" msgid="2072996269148483637">"您嘗試了 <xliff:g id="NUMBER">%d</xliff:g> 次仍未能成功解開這部上鎖的平板電腦。平板電腦現在將回復原廠設定。"</string>
     <string name="kg_failed_attempts_now_wiping" product="default" msgid="4817627474419471518">"您嘗試了 <xliff:g id="NUMBER">%d</xliff:g> 次仍未能成功解開這部上鎖的手機。手機現在將回復原廠設定。"</string>
     <string name="kg_failed_attempts_almost_at_login" product="tablet" msgid="3253575572118914370">"您已畫錯解鎖圖案 <xliff:g id="NUMBER_0">%d</xliff:g> 次,如果再嘗試 <xliff:g id="NUMBER_1">%d</xliff:g> 次仍未成功,系統會要求您透過電郵帳戶解開上鎖的平板電腦。\n\n請在 <xliff:g id="NUMBER_2">%d</xliff:g> 秒後再試一次。"</string>
diff --git a/packages/Keyguard/res/values-zh-rTW/strings.xml b/packages/Keyguard/res/values-zh-rTW/strings.xml
index 349282c..498d8a6 100644
--- a/packages/Keyguard/res/values-zh-rTW/strings.xml
+++ b/packages/Keyguard/res/values-zh-rTW/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"解鎖區域已收合。"</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>小工具。"</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"使用者選取工具"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"狀態"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"相機"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"媒體控制項"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"已開始將小工具重新排序。"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"已取消啟動"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"拖放「<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>」即可將其刪除。"</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"「<xliff:g id="WIDGET_INDEX">%1$s</xliff:g>」將不會遭到刪除。"</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"已設定下一個鬧鐘時間:<xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values-zu/strings.xml b/packages/Keyguard/res/values-zu/strings.xml
index c69bc18..95bbdb6 100644
--- a/packages/Keyguard/res/values-zu/strings.xml
+++ b/packages/Keyguard/res/values-zu/strings.xml
@@ -53,7 +53,6 @@
     <string name="keyguard_accessibility_unlock_area_collapsed" msgid="6366992066936076396">"Indawo yokuvula inciphisiwe."</string>
     <string name="keyguard_accessibility_widget" msgid="6527131039741808240">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> iwijethi."</string>
     <string name="keyguard_accessibility_user_selector" msgid="1226798370913698896">"Isikhethi somsebenzisi"</string>
-    <string name="keyguard_accessibility_status" msgid="8008264603935930611">"Isimo"</string>
     <string name="keyguard_accessibility_camera" msgid="8904231194181114603">"Ikhamera"</string>
     <string name="keygaurd_accessibility_media_controls" msgid="262209654292161806">"Izilawuli zemidiya"</string>
     <string name="keyguard_accessibility_widget_reorder_start" msgid="8736853615588828197">"Ukuhlelwa kabusha kwewijethi kuqalile"</string>
@@ -79,6 +78,7 @@
     <string name="keyguard_accessibility_hide_bouncer" msgid="7896992171878309358">"Ukuqalisa kukhanseliwe"</string>
     <string name="keyguard_accessibility_delete_widget_start" msgid="4096550552634391451">"Lahla i-<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ukuze uyisuse."</string>
     <string name="keyguard_accessibility_delete_widget_end" msgid="508833506780909393">"<xliff:g id="WIDGET_INDEX">%1$s</xliff:g> ngeke isuswe."</string>
+    <string name="keyguard_accessibility_next_alarm" msgid="7269583073750518672">"I-alamu elandelayo esethelwe i-<xliff:g id="ALARM">%1$s</xliff:g>"</string>
     <string name="password_keyboard_label_symbol_key" msgid="992280756256536042">"?123"</string>
     <string name="password_keyboard_label_alpha_key" msgid="8001096175167485649">"ABC"</string>
     <string name="password_keyboard_label_alt_key" msgid="1284820942620288678">"ALT"</string>
diff --git a/packages/Keyguard/res/values/alias.xml b/packages/Keyguard/res/values/alias.xml
index e6657a1..09e9591 100644
--- a/packages/Keyguard/res/values/alias.xml
+++ b/packages/Keyguard/res/values/alias.xml
@@ -49,4 +49,6 @@
     <!-- Alias used to reference framework activity duration.  -->
     <item type="integer" name="config_activityDefaultDur">@*android:integer/config_activityDefaultDur</item>
 
+    <!-- Alias used to reference one of two possible layouts in keyguard.  -->
+    <item type="layout" name="keyguard_eca">@layout/keyguard_emergency_carrier_area</item>
 </resources>
diff --git a/packages/Keyguard/res/values/dimens.xml b/packages/Keyguard/res/values/dimens.xml
index bfc0531..fb7480c 100644
--- a/packages/Keyguard/res/values/dimens.xml
+++ b/packages/Keyguard/res/values/dimens.xml
@@ -71,7 +71,7 @@
     <dimen name="kg_status_clock_font_size">75dp</dimen>
 
     <!-- Size of the generic status lines keyguard's status view  -->
-    <dimen name="kg_status_line_font_size">12dp</dimen>
+    <dimen name="kg_status_line_font_size">14sp</dimen>
 
     <!-- Size of margin on the right of keyguard's status view -->
     <dimen name="kg_status_line_font_right_margin">16dp</dimen>
@@ -120,7 +120,7 @@
     <dimen name="keyguard_security_height">400dp</dimen>
 
     <!-- Max Height of the sliding KeyguardSecurityContainer (includes 2x keyguard_security_view_margin) -->
-    <dimen name="keyguard_security_max_height">460dp</dimen>
+    <dimen name="keyguard_security_max_height">450dp</dimen>
 
     <!-- Margin around the various security views -->
     <dimen name="keyguard_security_view_margin">8dp</dimen>
diff --git a/packages/Keyguard/res/values/donottranslate.xml b/packages/Keyguard/res/values/donottranslate.xml
index 2f54406..a4d0ff7 100644
--- a/packages/Keyguard/res/values/donottranslate.xml
+++ b/packages/Keyguard/res/values/donottranslate.xml
@@ -19,7 +19,7 @@
     <string name="abbrev_wday_month_day_no_year">EEEEMMMMd</string>
 
     <!-- Skeleton string format for displaying the date when an alarm is set. -->
-    <string name="abbrev_wday_month_day_no_year_alarm">EEEMMMMd</string>
+    <string name="abbrev_wday_month_day_no_year_alarm">EEEMMMd</string>
 
     <!-- Skeleton string format for displaying the time in 12-hour format. -->
     <string name="clock_12hr_format">hm</string>
diff --git a/packages/Keyguard/res/values/strings.xml b/packages/Keyguard/res/values/strings.xml
index 55d8d81..a136acf 100644
--- a/packages/Keyguard/res/values/strings.xml
+++ b/packages/Keyguard/res/values/strings.xml
@@ -115,8 +115,6 @@
     <string name="keyguard_accessibility_widget"><xliff:g id="widget_index">%1$s</xliff:g> widget.</string>
     <!-- Accessibility description of the lock screen user selector widget. [CHAR_LIMIT=none] -->
     <string name="keyguard_accessibility_user_selector">User selector</string>
-    <!-- Accessibility description of the lock screen status widget. [CHAR_LIMIT=none] -->
-    <string name="keyguard_accessibility_status">Status</string>
     <!-- Accessibility description of the camera widget. [CHAR_LIMIT=none] -->
     <string name="keyguard_accessibility_camera">Camera</string>
     <!-- Accessibility description of the lock media control widget. [CHAR_LIMIT=none] -->
@@ -176,6 +174,9 @@
     <!-- Accessibility description announced when user drags widget away from delete drop target [CHAR LIMIT=NONE] -->
     <string name="keyguard_accessibility_delete_widget_end"><xliff:g id="widget_index">%1$s</xliff:g> will not be deleted.</string>
 
+    <!-- Accessibility description for the text view that indicates when the next alarm is set (not shown on screen). [CHAR_LIMIT=none] -->
+    <string name="keyguard_accessibility_next_alarm">Next alarm set for <xliff:g id="alarm" example="Fri 8:30 AM">%1$s</xliff:g></string>
+
     <!-- Password keyboard strings. Used by LockScreen and Settings --><skip />
     <!-- Label for "switch to symbols" key.  Must be short to fit on key! -->
     <string name="password_keyboard_label_symbol_key">\?123</string>
diff --git a/packages/Keyguard/res/values/styles.xml b/packages/Keyguard/res/values/styles.xml
index cdd6489..7d161af 100644
--- a/packages/Keyguard/res/values/styles.xml
+++ b/packages/Keyguard/res/values/styles.xml
@@ -68,8 +68,11 @@
     </style>
 
     <style name="BouncerSecurityContainer">
-        <item name="android:layout_marginBottom">32dp</item>
         <item name="android:layout_gravity">center_horizontal|bottom</item>
     </style>
 
+    <style name="PasswordTheme" parent="@android:style/Theme.DeviceDefault">
+        <item name="android:colorControlNormal">#80ffffff</item>
+        <item name="android:colorControlActivated">#80ffffff</item>
+    </style>
 </resources>
diff --git a/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedImageButton.java b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedImageButton.java
new file mode 100644
index 0000000..eda790f
--- /dev/null
+++ b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedImageButton.java
@@ -0,0 +1,38 @@
+/*
+ * Copyright (C) 2014 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.keyguard;
+
+import android.content.Context;
+import android.util.AttributeSet;
+import android.widget.ImageButton;
+import android.widget.RelativeLayout;
+
+/**
+ * A frame layout which does not have overlapping renderings commands and therefore does not need a
+ * layer when alpha is changed.
+ */
+public class AlphaOptimizedImageButton extends ImageButton {
+
+    public AlphaOptimizedImageButton(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+        return false;
+    }
+}
diff --git a/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedLinearLayout.java b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedLinearLayout.java
new file mode 100644
index 0000000..36da6f1
--- /dev/null
+++ b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedLinearLayout.java
@@ -0,0 +1,51 @@
+/*
+ * Copyright (C) 2014 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.keyguard;
+
+import android.content.Context;
+import android.util.AttributeSet;
+import android.view.View;
+import android.widget.LinearLayout;
+
+/**
+ * A linear layout which does not have overlapping renderings commands and therefore does not need a
+ * layer when alpha is changed.
+ */
+public class AlphaOptimizedLinearLayout extends LinearLayout
+{
+    public AlphaOptimizedLinearLayout(Context context) {
+        super(context);
+    }
+
+    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs, int defStyleAttr) {
+        super(context, attrs, defStyleAttr);
+    }
+
+    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs, int defStyleAttr,
+            int defStyleRes) {
+        super(context, attrs, defStyleAttr, defStyleRes);
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+        return false;
+    }
+}
diff --git a/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedRelativeLayout.java b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedRelativeLayout.java
new file mode 100644
index 0000000..200b116
--- /dev/null
+++ b/packages/Keyguard/src/com/android/keyguard/AlphaOptimizedRelativeLayout.java
@@ -0,0 +1,37 @@
+/*
+ * Copyright (C) 2014 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.keyguard;
+
+import android.content.Context;
+import android.util.AttributeSet;
+import android.widget.RelativeLayout;
+
+/**
+ * A frame layout which does not have overlapping renderings commands and therefore does not need a
+ * layer when alpha is changed.
+ */
+public class AlphaOptimizedRelativeLayout extends RelativeLayout {
+
+    public AlphaOptimizedRelativeLayout(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+        return false;
+    }
+}
diff --git a/packages/Keyguard/src/com/android/keyguard/EmergencyButton.java b/packages/Keyguard/src/com/android/keyguard/EmergencyButton.java
index 73b11f3..e0507a8 100644
--- a/packages/Keyguard/src/com/android/keyguard/EmergencyButton.java
+++ b/packages/Keyguard/src/com/android/keyguard/EmergencyButton.java
@@ -99,8 +99,7 @@
         // TODO: implement a shorter timeout once new PowerManager API is ready.
         // should be the equivalent to the old userActivity(EMERGENCY_CALL_TIMEOUT)
         mPowerManager.userActivity(SystemClock.uptimeMillis(), true);
-        if (TelephonyManager.getDefault().getCallState()
-                == TelephonyManager.CALL_STATE_OFFHOOK) {
+        if (mLockPatternUtils.isInCall()) {
             mLockPatternUtils.resumeCall();
         } else {
             final boolean bypassHandler = true;
@@ -115,7 +114,7 @@
 
     private void updateEmergencyCallButton(State simState, int phoneState) {
         boolean enabled = false;
-        if (phoneState == TelephonyManager.CALL_STATE_OFFHOOK) {
+        if (mLockPatternUtils.isInCall()) {
             enabled = true; // always show "return to call" if phone is off-hook
         } else if (mLockPatternUtils.isEmergencyCallCapable()) {
             boolean simLocked = KeyguardUpdateMonitor.getInstance(mContext).isSimLocked();
diff --git a/packages/Keyguard/src/com/android/keyguard/EmergencyCarrierArea.java b/packages/Keyguard/src/com/android/keyguard/EmergencyCarrierArea.java
index a592db9..0a89d9b 100644
--- a/packages/Keyguard/src/com/android/keyguard/EmergencyCarrierArea.java
+++ b/packages/Keyguard/src/com/android/keyguard/EmergencyCarrierArea.java
@@ -17,13 +17,11 @@
 package com.android.keyguard;
 
 import android.content.Context;
-import android.content.res.TypedArray;
 import android.util.AttributeSet;
 import android.view.MotionEvent;
 import android.view.View;
-import android.widget.LinearLayout;
 
-public class EmergencyCarrierArea extends LinearLayout {
+public class EmergencyCarrierArea extends AlphaOptimizedLinearLayout {
 
     private CarrierText mCarrierText;
     private EmergencyButton mEmergencyButton;
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardActivityLauncher.java b/packages/Keyguard/src/com/android/keyguard/KeyguardActivityLauncher.java
index 32f7a1e..1978ded 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardActivityLauncher.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardActivityLauncher.java
@@ -242,8 +242,7 @@
                             null /*resultWho*/,
                             0 /*requestCode*/,
                             Intent.FLAG_ACTIVITY_NEW_TASK,
-                            null /*profileFile*/,
-                            null /*profileFd*/,
+                            null /*profilerInfo*/,
                             options,
                             user.getIdentifier());
                     if (DEBUG) Log.d(TAG, String.format("waitResult[%s,%s,%s,%s] at %s",
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardPINView.java b/packages/Keyguard/src/com/android/keyguard/KeyguardPINView.java
index 66c30c7..55538a7 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardPINView.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardPINView.java
@@ -85,6 +85,7 @@
     @Override
     public void startAppearAnimation() {
         enableClipping(false);
+        setAlpha(1f);
         setTranslationY(mAppearAnimationUtils.getStartTranslation());
         animate()
                 .setDuration(500)
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardPasswordView.java b/packages/Keyguard/src/com/android/keyguard/KeyguardPasswordView.java
index 5f5d25c..e6c9e6c 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardPasswordView.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardPasswordView.java
@@ -25,6 +25,8 @@
 import android.util.AttributeSet;
 import android.view.KeyEvent;
 import android.view.View;
+import android.view.animation.AnimationUtils;
+import android.view.animation.Interpolator;
 import android.view.inputmethod.EditorInfo;
 import android.view.inputmethod.InputMethodInfo;
 import android.view.inputmethod.InputMethodManager;
@@ -42,9 +44,12 @@
         implements KeyguardSecurityView, OnEditorActionListener, TextWatcher {
 
     private final boolean mShowImeAtScreenOn;
+    private final int mDisappearYTranslation;
 
     InputMethodManager mImm;
     private TextView mPasswordEntry;
+    private Interpolator mLinearOutSlowInInterpolator;
+    private Interpolator mFastOutLinearInInterpolator;
 
     public KeyguardPasswordView(Context context) {
         this(context, null);
@@ -54,6 +59,12 @@
         super(context, attrs);
         mShowImeAtScreenOn = context.getResources().
                 getBoolean(R.bool.kg_show_ime_at_screen_on);
+        mDisappearYTranslation = getResources().getDimensionPixelSize(
+                R.dimen.disappear_y_translation);
+        mLinearOutSlowInInterpolator = AnimationUtils.loadInterpolator(
+                context, android.R.interpolator.linear_out_slow_in);
+        mFastOutLinearInInterpolator = AnimationUtils.loadInterpolator(
+                context, android.R.interpolator.fast_out_linear_in);
     }
 
     protected void resetState() {
@@ -72,12 +83,19 @@
     }
 
     @Override
-    public void onResume(int reason) {
+    public void onResume(final int reason) {
         super.onResume(reason);
-        mPasswordEntry.requestFocus();
-        if (reason != KeyguardSecurityView.SCREEN_ON || mShowImeAtScreenOn) {
-            mImm.showSoftInput(mPasswordEntry, InputMethodManager.SHOW_IMPLICIT);
-        }
+
+        // Wait a bit to focus the field so the focusable flag on the window is already set then.
+        post(new Runnable() {
+            @Override
+            public void run() {
+                mPasswordEntry.requestFocus();
+                if (reason != KeyguardSecurityView.SCREEN_ON || mShowImeAtScreenOn) {
+                    mImm.showSoftInput(mPasswordEntry, InputMethodManager.SHOW_IMPLICIT);
+                }
+            }
+        });
     }
 
     @Override
@@ -239,14 +257,24 @@
 
     @Override
     public void startAppearAnimation() {
-        // TODO: Fancy animation.
-        setAlpha(0);
-        animate().alpha(1).withLayer().setDuration(200);
+        setAlpha(0f);
+        setTranslationY(0f);
+        animate()
+                .alpha(1)
+                .withLayer()
+                .setDuration(300)
+                .setInterpolator(mLinearOutSlowInInterpolator);
     }
 
     @Override
     public boolean startDisappearAnimation(Runnable finishRunnable) {
-        return false;
+        animate()
+                .alpha(0f)
+                .translationY(mDisappearYTranslation)
+                .setInterpolator(mFastOutLinearInInterpolator)
+                .setDuration(100)
+                .withEndAction(finishRunnable);
+        return true;
     }
 
     @Override
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardPatternView.java b/packages/Keyguard/src/com/android/keyguard/KeyguardPatternView.java
index 3b05d11..0e01a27 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardPatternView.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardPatternView.java
@@ -15,38 +15,27 @@
  */
 package com.android.keyguard;
 
-import android.accounts.Account;
-import android.accounts.AccountManager;
-import android.accounts.AccountManagerCallback;
-import android.accounts.AccountManagerFuture;
-import android.accounts.AuthenticatorException;
-import android.accounts.OperationCanceledException;
 import android.animation.Animator;
 import android.animation.AnimatorListenerAdapter;
 import android.animation.ValueAnimator;
 import android.content.Context;
 import android.graphics.Rect;
 import android.graphics.drawable.Drawable;
-import android.os.Bundle;
 import android.os.CountDownTimer;
 import android.os.SystemClock;
-import android.os.UserHandle;
 import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.util.Log;
 import android.view.MotionEvent;
 import android.view.View;
 import android.view.ViewGroup;
-import android.view.animation.AccelerateInterpolator;
 import android.view.animation.AnimationUtils;
 import android.view.animation.Interpolator;
-import android.widget.Button;
 import android.widget.LinearLayout;
 
 import com.android.internal.widget.LockPatternUtils;
 import com.android.internal.widget.LockPatternView;
 
-import java.io.IOException;
 import java.util.List;
 
 public class KeyguardPatternView extends LinearLayout implements KeyguardSecurityView,
@@ -70,9 +59,7 @@
     private CountDownTimer mCountdownTimer = null;
     private LockPatternUtils mLockPatternUtils;
     private LockPatternView mLockPatternView;
-    private Button mForgotPatternButton;
     private KeyguardSecurityCallback mCallback;
-    private boolean mEnableFallback;
 
     /**
      * Keeps track of the last time we poked the wake lock during dispatching of the touch event.
@@ -144,20 +131,8 @@
         // vibrate mode will be the same for the life of this screen
         mLockPatternView.setTactileFeedbackEnabled(mLockPatternUtils.isTactileFeedbackEnabled());
 
-        mForgotPatternButton = (Button) findViewById(R.id.forgot_password_button);
-        // note: some configurations don't have an emergency call area
-        if (mForgotPatternButton != null) {
-            mForgotPatternButton.setText(R.string.kg_forgot_pattern_button_text);
-            mForgotPatternButton.setOnClickListener(new OnClickListener() {
-                public void onClick(View v) {
-                    mCallback.showBackupSecurity();
-                }
-            });
-        }
-
         setFocusableInTouchMode(true);
 
-        maybeEnableFallback(mContext);
         mSecurityMessageDisplay = new KeyguardMessageArea.Helper(this);
         mEcaView = findViewById(R.id.keyguard_selector_fade_container);
         View bouncerFrameView = findViewById(R.id.keyguard_bouncer_frame);
@@ -169,24 +144,6 @@
         mHelpMessage = (KeyguardMessageArea) findViewById(R.id.keyguard_message_area);
     }
 
-    private void updateFooter(FooterMode mode) {
-        if (mForgotPatternButton == null) return; // no ECA? no footer
-
-        switch (mode) {
-            case Normal:
-                if (DEBUG) Log.d(TAG, "mode normal");
-                mForgotPatternButton.setVisibility(View.GONE);
-                break;
-            case ForgotLockPattern:
-                if (DEBUG) Log.d(TAG, "mode ForgotLockPattern");
-                mForgotPatternButton.setVisibility(View.VISIBLE);
-                break;
-            case VerifyUnlocked:
-                if (DEBUG) Log.d(TAG, "mode VerifyUnlocked");
-                mForgotPatternButton.setVisibility(View.GONE);
-        }
-    }
-
     @Override
     public boolean onTouchEvent(MotionEvent ev) {
         boolean result = super.onTouchEvent(ev);
@@ -217,18 +174,6 @@
         } else {
             displayDefaultSecurityMessage();
         }
-
-        // the footer depends on how many total attempts the user has failed
-        if (mCallback.isVerifyUnlockOnly()) {
-            updateFooter(FooterMode.VerifyUnlocked);
-        } else if (mEnableFallback &&
-                (mKeyguardUpdateMonitor.getFailedUnlockAttempts()
-                        >= LockPatternUtils.FAILED_ATTEMPTS_BEFORE_TIMEOUT)) {
-            updateFooter(FooterMode.ForgotLockPattern);
-        } else {
-            updateFooter(FooterMode.Normal);
-        }
-
     }
 
     private void displayDefaultSecurityMessage() {
@@ -291,68 +236,10 @@
         }
     }
 
-    private void maybeEnableFallback(Context context) {
-        // Ask the account manager if we have an account that can be used as a
-        // fallback in case the user forgets his pattern.
-        AccountAnalyzer accountAnalyzer = new AccountAnalyzer(AccountManager.get(context));
-        accountAnalyzer.start();
-    }
-
-    private class AccountAnalyzer implements AccountManagerCallback<Bundle> {
-        private final AccountManager mAccountManager;
-        private final Account[] mAccounts;
-        private int mAccountIndex;
-
-        private AccountAnalyzer(AccountManager accountManager) {
-            mAccountManager = accountManager;
-            mAccounts = accountManager.getAccountsByTypeAsUser("com.google",
-                    new UserHandle(mLockPatternUtils.getCurrentUser()));
-        }
-
-        private void next() {
-            // if we are ready to enable the fallback or if we depleted the list of accounts
-            // then finish and get out
-            if (mEnableFallback || mAccountIndex >= mAccounts.length) {
-                return;
-            }
-
-            // lookup the confirmCredentials intent for the current account
-            mAccountManager.confirmCredentialsAsUser(mAccounts[mAccountIndex], null, null, this,
-                    null, new UserHandle(mLockPatternUtils.getCurrentUser()));
-        }
-
-        public void start() {
-            mEnableFallback = false;
-            mAccountIndex = 0;
-            next();
-        }
-
-        public void run(AccountManagerFuture<Bundle> future) {
-            try {
-                Bundle result = future.getResult();
-                if (result.getParcelable(AccountManager.KEY_INTENT) != null) {
-                    mEnableFallback = true;
-                }
-            } catch (OperationCanceledException e) {
-                // just skip the account if we are unable to query it
-            } catch (IOException e) {
-                // just skip the account if we are unable to query it
-            } catch (AuthenticatorException e) {
-                // just skip the account if we are unable to query it
-            } finally {
-                mAccountIndex++;
-                next();
-            }
-        }
-    }
-
     private void handleAttemptLockout(long elapsedRealtimeDeadline) {
         mLockPatternView.clearPattern();
         mLockPatternView.setEnabled(false);
         final long elapsedRealtime = SystemClock.elapsedRealtime();
-        if (mEnableFallback) {
-            updateFooter(FooterMode.ForgotLockPattern);
-        }
 
         mCountdownTimer = new CountDownTimer(elapsedRealtimeDeadline - elapsedRealtime, 1000) {
 
@@ -367,12 +254,6 @@
             public void onFinish() {
                 mLockPatternView.setEnabled(true);
                 displayDefaultSecurityMessage();
-                // TODO mUnlockIcon.setVisibility(View.VISIBLE);
-                if (mEnableFallback) {
-                    updateFooter(FooterMode.ForgotLockPattern);
-                } else {
-                    updateFooter(FooterMode.Normal);
-                }
             }
 
         }.start();
@@ -416,6 +297,7 @@
     @Override
     public void startAppearAnimation() {
         enableClipping(false);
+        setAlpha(1f);
         setTranslationY(mAppearAnimationUtils.getStartTranslation());
         animate()
                 .setDuration(500)
@@ -444,7 +326,7 @@
         mLockPatternView.clearPattern();
         animate()
                 .alpha(0f)
-                .translationY(-100)
+                .translationY(mDisappearYTranslation)
                 .setInterpolator(AnimationUtils.loadInterpolator(
                         mContext, android.R.interpolator.fast_out_linear_in))
                 .setDuration(100)
@@ -488,13 +370,6 @@
             // Also animate the Emergency call
             mAppearAnimationUtils.createAnimation(mEcaView, delay, duration, startTranslationY,
             interpolator, null);
-
-            // And the forgot pattern button
-            if (mForgotPatternButton != null
-                    && mForgotPatternButton.getVisibility() == View.VISIBLE) {
-                mAppearAnimationUtils.createAnimation(mForgotPatternButton, delay, duration,
-                        startTranslationY, interpolator, null);
-            }
         }
         animator.start();
         mLockPatternView.invalidate();
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardStatusView.java b/packages/Keyguard/src/com/android/keyguard/KeyguardStatusView.java
index 51a276e..8898f9e 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardStatusView.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardStatusView.java
@@ -128,22 +128,28 @@
                 getResources().getDimensionPixelSize(R.dimen.widget_label_font_size));
     }
 
-    protected void refresh() {
-        AlarmManager.AlarmClockInfo nextAlarm = mLockPatternUtils.getNextAlarm();
-        Patterns.update(mContext, nextAlarm != null);
-
+    public void refreshTime() {
         mDateView.setFormat24Hour(Patterns.dateView);
         mDateView.setFormat12Hour(Patterns.dateView);
 
         mClockView.setFormat12Hour(Patterns.clockView12);
         mClockView.setFormat24Hour(Patterns.clockView24);
+    }
 
+    private void refresh() {
+        AlarmManager.AlarmClockInfo nextAlarm = mLockPatternUtils.getNextAlarm();
+        Patterns.update(mContext, nextAlarm != null);
+
+        refreshTime();
         refreshAlarmStatus(nextAlarm);
     }
 
     void refreshAlarmStatus(AlarmManager.AlarmClockInfo nextAlarm) {
         if (nextAlarm != null) {
-            mAlarmStatusView.setText(formatNextAlarm(mContext, nextAlarm));
+            String alarm = formatNextAlarm(mContext, nextAlarm);
+            mAlarmStatusView.setText(alarm);
+            mAlarmStatusView.setContentDescription(
+                    getResources().getString(R.string.keyguard_accessibility_next_alarm, alarm));
             mAlarmStatusView.setVisibility(View.VISIBLE);
         } else {
             mAlarmStatusView.setVisibility(View.GONE);
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
index 0d79ee2..1c6dc2c 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitor.java
@@ -218,7 +218,7 @@
                     handleFingerprintProcessed(msg.arg1);
                     break;
                 case MSG_FACE_UNLOCK_STATE_CHANGED:
-                    handleFaceUnlockStateChanged(msg.arg1 != 0);
+                    handleFaceUnlockStateChanged(msg.arg1 != 0, msg.arg2);
                     break;
             }
         }
@@ -227,6 +227,7 @@
     private SparseBooleanArray mUserHasTrust = new SparseBooleanArray();
     private SparseBooleanArray mUserTrustIsManaged = new SparseBooleanArray();
     private SparseBooleanArray mUserFingerprintRecognized = new SparseBooleanArray();
+    private SparseBooleanArray mUserFaceUnlockRunning = new SparseBooleanArray();
 
     @Override
     public void onTrustChanged(boolean enabled, int userId, boolean initiatedByUser) {
@@ -297,15 +298,20 @@
         }
     }
 
-    private void handleFaceUnlockStateChanged(boolean running) {
+    private void handleFaceUnlockStateChanged(boolean running, int userId) {
+        mUserFaceUnlockRunning.put(userId, running);
         for (int i = 0; i < mCallbacks.size(); i++) {
             KeyguardUpdateMonitorCallback cb = mCallbacks.get(i).get();
             if (cb != null) {
-                cb.onFaceUnlockStateChanged(running);
+                cb.onFaceUnlockStateChanged(running, userId);
             }
         }
     }
 
+    public boolean isFaceUnlockRunning(int userId) {
+        return mUserFaceUnlockRunning.get(userId);
+    }
+
     private boolean isTrustDisabled(int userId) {
         final DevicePolicyManager dpm =
                 (DevicePolicyManager) mContext.getSystemService(Context.DEVICE_POLICY_SERVICE);
@@ -361,8 +367,7 @@
 
             if (Intent.ACTION_TIME_TICK.equals(action)
                     || Intent.ACTION_TIME_CHANGED.equals(action)
-                    || Intent.ACTION_TIMEZONE_CHANGED.equals(action)
-                    || AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED.equals(action)) {
+                    || Intent.ACTION_TIMEZONE_CHANGED.equals(action)) {
                 mHandler.sendEmptyMessage(MSG_TIME_UPDATE);
             } else if (TelephonyIntents.SPN_STRINGS_UPDATED_ACTION.equals(action)) {
                 mTelephonyPlmn = getTelephonyPlmnFrom(intent);
@@ -389,18 +394,11 @@
             } else if (TelephonyManager.ACTION_PHONE_STATE_CHANGED.equals(action)) {
                 String state = intent.getStringExtra(TelephonyManager.EXTRA_STATE);
                 mHandler.sendMessage(mHandler.obtainMessage(MSG_PHONE_STATE_CHANGED, state));
-            } else if (DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED
-                    .equals(action)) {
-                mHandler.sendEmptyMessage(MSG_DPM_STATE_CHANGED);
             } else if (Intent.ACTION_USER_REMOVED.equals(action)) {
                 mHandler.sendMessage(mHandler.obtainMessage(MSG_USER_REMOVED,
                        intent.getIntExtra(Intent.EXTRA_USER_HANDLE, 0), 0));
             } else if (Intent.ACTION_BOOT_COMPLETED.equals(action)) {
                 dispatchBootCompleted();
-            } else if (ACTION_FACE_UNLOCK_STARTED.equals(action)) {
-                mHandler.sendMessage(mHandler.obtainMessage(MSG_FACE_UNLOCK_STATE_CHANGED, 1, 0));
-            } else if (ACTION_FACE_UNLOCK_STOPPED.equals(action)) {
-                mHandler.sendMessage(mHandler.obtainMessage(MSG_FACE_UNLOCK_STATE_CHANGED, 0, 0));
             }
         }
     };
@@ -409,9 +407,20 @@
 
         public void onReceive(Context context, Intent intent) {
             final String action = intent.getAction();
-            if (Intent.ACTION_USER_INFO_CHANGED.equals(action)) {
+            if (AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED.equals(action)) {
+                mHandler.sendEmptyMessage(MSG_TIME_UPDATE);
+            } else if (Intent.ACTION_USER_INFO_CHANGED.equals(action)) {
                 mHandler.sendMessage(mHandler.obtainMessage(MSG_USER_INFO_CHANGED,
                         intent.getIntExtra(Intent.EXTRA_USER_HANDLE, getSendingUserId()), 0));
+            } else if (ACTION_FACE_UNLOCK_STARTED.equals(action)) {
+                mHandler.sendMessage(mHandler.obtainMessage(MSG_FACE_UNLOCK_STATE_CHANGED, 1,
+                        getSendingUserId()));
+            } else if (ACTION_FACE_UNLOCK_STOPPED.equals(action)) {
+                mHandler.sendMessage(mHandler.obtainMessage(MSG_FACE_UNLOCK_STATE_CHANGED, 0,
+                        getSendingUserId()));
+            } else if (DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED
+                    .equals(action)) {
+                mHandler.sendEmptyMessage(MSG_DPM_STATE_CHANGED);
             }
         }
     };
@@ -610,11 +619,7 @@
         filter.addAction(TelephonyManager.ACTION_PHONE_STATE_CHANGED);
         filter.addAction(TelephonyIntents.SPN_STRINGS_UPDATED_ACTION);
         filter.addAction(AudioManager.RINGER_MODE_CHANGED_ACTION);
-        filter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED);
         filter.addAction(Intent.ACTION_USER_REMOVED);
-        filter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED);
-        filter.addAction(ACTION_FACE_UNLOCK_STARTED);
-        filter.addAction(ACTION_FACE_UNLOCK_STOPPED);
         context.registerReceiver(mBroadcastReceiver, filter);
 
         final IntentFilter bootCompleteFilter = new IntentFilter();
@@ -622,8 +627,13 @@
         bootCompleteFilter.addAction(Intent.ACTION_BOOT_COMPLETED);
         context.registerReceiver(mBroadcastReceiver, bootCompleteFilter);
 
-        final IntentFilter userInfoFilter = new IntentFilter(Intent.ACTION_USER_INFO_CHANGED);
-        context.registerReceiverAsUser(mBroadcastAllReceiver, UserHandle.ALL, userInfoFilter,
+        final IntentFilter allUserFilter = new IntentFilter();
+        allUserFilter.addAction(Intent.ACTION_USER_INFO_CHANGED);
+        allUserFilter.addAction(AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED);
+        allUserFilter.addAction(ACTION_FACE_UNLOCK_STARTED);
+        allUserFilter.addAction(ACTION_FACE_UNLOCK_STOPPED);
+        allUserFilter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED);
+        context.registerReceiverAsUser(mBroadcastAllReceiver, UserHandle.ALL, allUserFilter,
                 null, null);
 
         try {
@@ -638,7 +648,7 @@
                         @Override
                         public void onUserSwitchComplete(int newUserId) throws RemoteException {
                             mHandler.sendMessage(mHandler.obtainMessage(MSG_USER_SWITCH_COMPLETE,
-                                    newUserId));
+                                    newUserId, 0));
                             mSwitchingUser = false;
                         }
                     });
diff --git a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
index 0acb9d0..33cab8f 100644
--- a/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
+++ b/packages/Keyguard/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
@@ -197,5 +197,5 @@
     /**
      * Called when the state of face unlock changed.
      */
-    public void onFaceUnlockStateChanged(boolean running) { }
+    public void onFaceUnlockStateChanged(boolean running, int userId) { }
 }
diff --git a/packages/Keyguard/src/com/android/keyguard/NumPadKey.java b/packages/Keyguard/src/com/android/keyguard/NumPadKey.java
index 2d20b02..d539856 100644
--- a/packages/Keyguard/src/com/android/keyguard/NumPadKey.java
+++ b/packages/Keyguard/src/com/android/keyguard/NumPadKey.java
@@ -152,6 +152,11 @@
         mKlondikeText.layout(left, top, left + mKlondikeText.getMeasuredWidth(), bottom);
     }
 
+    @Override
+    public boolean hasOverlappingRendering() {
+        return false;
+    }
+
     // Cause a VIRTUAL_KEY vibration
     public void doHapticKeyClick() {
         if (mEnableHaptics) {
diff --git a/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java b/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
index f3ba3a7..6497f46 100644
--- a/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
+++ b/packages/Keyguard/src/com/android/keyguard/PasswordTextView.java
@@ -145,6 +145,11 @@
         }
     }
 
+    @Override
+    public boolean hasOverlappingRendering() {
+        return false;
+    }
+
     private Rect getCharBounds() {
         float textHeight = mTextHeightRaw * getResources().getDisplayMetrics().scaledDensity;
         mDrawPaint.setTextSize(textHeight);
diff --git a/packages/Keyguard/test/SampleTrustAgent/src/com/android/trustagent/test/SampleTrustAgent.java b/packages/Keyguard/test/SampleTrustAgent/src/com/android/trustagent/test/SampleTrustAgent.java
index 4ea1c77..c650a0f 100644
--- a/packages/Keyguard/test/SampleTrustAgent/src/com/android/trustagent/test/SampleTrustAgent.java
+++ b/packages/Keyguard/test/SampleTrustAgent/src/com/android/trustagent/test/SampleTrustAgent.java
@@ -76,6 +76,12 @@
     }
 
     @Override
+    public void onTrustTimeout() {
+        super.onTrustTimeout();
+        Toast.makeText(this, "onTrustTimeout(): timeout expired", Toast.LENGTH_SHORT).show();
+    }
+
+    @Override
     public void onUnlockAttempt(boolean successful) {
         if (getReportUnlockAttempts(this)) {
             Toast.makeText(this, "onUnlockAttempt(successful=" + successful + ")",
diff --git a/packages/PrintSpooler/Android.mk b/packages/PrintSpooler/Android.mk
index 3fbd4d8..27d1b23 100644
--- a/packages/PrintSpooler/Android.mk
+++ b/packages/PrintSpooler/Android.mk
@@ -19,9 +19,15 @@
 LOCAL_MODULE_TAGS := optional
 
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
+LOCAL_SRC_FILES += \
+        src/com/android/printspooler/renderer/IPdfRenderer.aidl \
+        src/com/android/printspooler/renderer/IPdfEditor.aidl
 
 LOCAL_PACKAGE_NAME := PrintSpooler
 
+LOCAL_JNI_SHARED_LIBRARIES := libprintspooler_jni
 LOCAL_STATIC_JAVA_LIBRARIES := android-support-v4 android-support-v7-recyclerview
 
 include $(BUILD_PACKAGE)
+
+include $(call all-makefiles-under, $(LOCAL_PATH))
\ No newline at end of file
diff --git a/packages/PrintSpooler/AndroidManifest.xml b/packages/PrintSpooler/AndroidManifest.xml
index 9a62864..c7cf61a 100644
--- a/packages/PrintSpooler/AndroidManifest.xml
+++ b/packages/PrintSpooler/AndroidManifest.xml
@@ -45,8 +45,7 @@
         android:allowClearUserData="true"
         android:label="@string/app_label"
         android:allowBackup= "false"
-        android:supportsRtl="true"
-        android:icon="@*android:drawable/ic_print">
+        android:supportsRtl="true">
 
         <service
             android:name=".model.PrintSpoolerService"
@@ -54,6 +53,12 @@
             android:permission="android.permission.BIND_PRINT_SPOOLER_SERVICE">
         </service>
 
+        <service
+            android:name=".renderer.PdfManipulationService"
+            android:isolatedProcess="true"
+            android:process=":renderer">
+        </service>
+
         <activity
             android:name=".ui.PrintActivity"
             android:configChanges="orientation|screenSize"
diff --git a/packages/PrintSpooler/jni/Android.mk b/packages/PrintSpooler/jni/Android.mk
new file mode 100644
index 0000000..fe7d06b
--- /dev/null
+++ b/packages/PrintSpooler/jni/Android.mk
@@ -0,0 +1,19 @@
+LOCAL_PATH := $(call my-dir)
+
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES:= \
+    com_android_printspooler_util_BitmapSerializeUtils.cpp \
+
+LOCAL_C_INCLUDES += \
+    $(JNI_H_INCLUDE)
+
+LOCAL_SHARED_LIBRARIES := \
+    libnativehelper \
+    libjnigraphics \
+    liblog
+
+LOCAL_MODULE := libprintspooler_jni
+LOCAL_MODULE_TAGS := optional
+
+include $(BUILD_SHARED_LIBRARY)
diff --git a/packages/PrintSpooler/jni/com_android_printspooler_util_BitmapSerializeUtils.cpp b/packages/PrintSpooler/jni/com_android_printspooler_util_BitmapSerializeUtils.cpp
new file mode 100644
index 0000000..57281c8
--- /dev/null
+++ b/packages/PrintSpooler/jni/com_android_printspooler_util_BitmapSerializeUtils.cpp
@@ -0,0 +1,192 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#define LOG_TAG "BitmapSerializeUtils"
+
+#include <jni.h>
+#include <JNIHelp.h>
+
+#include <android/bitmap.h>
+#include <android/log.h>
+
+namespace android {
+
+#define RGBA_8888_COLOR_DEPTH 4
+
+static bool writeAllBytes(const int fd, void* buffer, const size_t byteCount) {
+    char* writeBuffer = static_cast<char*>(buffer);
+    size_t remainingBytes = byteCount;
+    while (remainingBytes > 0) {
+        ssize_t writtenByteCount = write(fd, writeBuffer, remainingBytes);
+        if (writtenByteCount == -1) {
+            if (errno == EINTR) {
+                continue;
+            }
+            __android_log_print(ANDROID_LOG_ERROR, LOG_TAG,
+                    "Error writing to buffer: %d", errno);
+            return false;
+        }
+        remainingBytes -= writtenByteCount;
+        writeBuffer += writtenByteCount;
+    }
+    return true;
+}
+
+static bool readAllBytes(const int fd, void* buffer, const size_t byteCount) {
+    char* readBuffer = static_cast<char*>(buffer);
+    size_t remainingBytes = byteCount;
+    while (remainingBytes > 0) {
+        ssize_t readByteCount = read(fd, readBuffer, remainingBytes);
+        if (readByteCount == -1) {
+            if (errno == EINTR) {
+                continue;
+            }
+            __android_log_print(ANDROID_LOG_ERROR, LOG_TAG,
+                    "Error reading from buffer: %d", errno);
+            return false;
+        }
+        remainingBytes -= readByteCount;
+        readBuffer += readByteCount;
+    }
+    return true;
+}
+
+static void throwException(JNIEnv* env, const char* className, const char* message) {
+    jclass exceptionClass = env->FindClass(className);
+    env->ThrowNew(exceptionClass, message);
+}
+
+static void throwIllegalStateException(JNIEnv* env, char *message) {
+    const char* className = "java/lang/IllegalStateException";
+    throwException(env, className, message);
+}
+
+static void throwIllegalArgumentException(JNIEnv* env, char* message) {
+    const char* className = "java/lang/IllegalArgumentException";
+    throwException(env, className, message);
+}
+
+static void readBitmapPixels(JNIEnv* env, jclass clazz, jobject jbitmap, jint fd) {
+    // Read the info.
+    AndroidBitmapInfo readInfo;
+    bool read = readAllBytes(fd, (void*) &readInfo, sizeof(AndroidBitmapInfo));
+    if (!read) {
+        throwIllegalStateException(env, (char*) "Cannot read bitmap info");
+        return;
+    }
+
+    // Get the info of the target bitmap.
+    AndroidBitmapInfo targetInfo;
+    int result = AndroidBitmap_getInfo(env, jbitmap, &targetInfo);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot get bitmap info");
+        return;
+    }
+
+    // Enforce we can reuse the bitmap.
+    if (readInfo.width != targetInfo.width || readInfo.height != targetInfo.height
+            || readInfo.stride != targetInfo.stride || readInfo.format != targetInfo.format
+            || readInfo.flags != targetInfo.flags) {
+        throwIllegalArgumentException(env, (char*) "Cannot reuse bitmap");
+        return;
+    }
+
+    // Lock the pixels.
+    void* pixels;
+    result = AndroidBitmap_lockPixels(env, jbitmap, &pixels);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot lock bitmap pixels");
+        return;
+    }
+
+    // Read the pixels.
+    size_t byteCount = readInfo.stride * readInfo.height;
+    read = readAllBytes(fd, (void*) pixels, byteCount);
+    if (!read) {
+        throwIllegalStateException(env, (char*) "Cannot read bitmap pixels");
+        return;
+    }
+
+    // Unlock the pixels.
+    result = AndroidBitmap_unlockPixels(env, jbitmap);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot unlock bitmap pixels");
+    }
+}
+
+static void writeBitmapPixels(JNIEnv* env, jclass clazz, jobject jbitmap, jint fd) {
+    // Get the info.
+    AndroidBitmapInfo info;
+    int result = AndroidBitmap_getInfo(env, jbitmap, &info);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot get bitmap info");
+        return;
+    }
+
+    // Write the info.
+    bool written = writeAllBytes(fd, (void*) &info, sizeof(AndroidBitmapInfo));
+    if (!written) {
+        throwIllegalStateException(env, (char*) "Cannot write bitmap info");
+        return;
+    }
+
+    // Lock the pixels.
+    void* pixels;
+    result = AndroidBitmap_lockPixels(env, jbitmap, &pixels);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot lock bitmap pixels");
+        return;
+    }
+
+    // Write the pixels.
+    size_t byteCount = info.stride * info.height;
+    written = writeAllBytes(fd, (void*) pixels, byteCount);
+    if (!written) {
+        throwIllegalStateException(env, (char*) "Cannot write bitmap pixels");
+        return;
+    }
+
+    // Unlock the pixels.
+    result = AndroidBitmap_unlockPixels(env, jbitmap);
+    if (result < 0) {
+        throwIllegalStateException(env, (char*) "Cannot unlock bitmap pixels");
+    }
+}
+
+static JNINativeMethod sMethods[] = {
+    {"nativeReadBitmapPixels", "(Landroid/graphics/Bitmap;I)V", (void *) readBitmapPixels},
+    {"nativeWriteBitmapPixels", "(Landroid/graphics/Bitmap;I)V", (void *) writeBitmapPixels},
+};
+
+int register_com_android_printspooler_util_BitmapSerializeUtils(JNIEnv* env) {
+    return jniRegisterNativeMethods(env, "com/android/printspooler/util/BitmapSerializeUtils",
+        sMethods, NELEM(sMethods));
+}
+
+}
+
+jint JNI_OnLoad(JavaVM* jvm, void*) {
+    JNIEnv *env = NULL;
+    if (jvm->GetEnv((void**) &env, JNI_VERSION_1_6)) {
+        return JNI_ERR;
+    }
+
+    if (android::register_com_android_printspooler_util_BitmapSerializeUtils(env) == -1) {
+        return JNI_ERR;
+    }
+
+    return JNI_VERSION_1_6;
+}
diff --git a/packages/PrintSpooler/res/drawable-hdpi/ic_menu_print.png b/packages/PrintSpooler/res/drawable-hdpi/ic_menu_print.png
deleted file mode 100644
index 09ab1a2..0000000
--- a/packages/PrintSpooler/res/drawable-hdpi/ic_menu_print.png
+++ /dev/null
Binary files differ
diff --git a/packages/PrintSpooler/res/drawable-mdpi/ic_menu_print.png b/packages/PrintSpooler/res/drawable-mdpi/ic_menu_print.png
deleted file mode 100644
index 637d94e..0000000
--- a/packages/PrintSpooler/res/drawable-mdpi/ic_menu_print.png
+++ /dev/null
Binary files differ
diff --git a/packages/PrintSpooler/res/drawable-xhdpi/ic_menu_print.png b/packages/PrintSpooler/res/drawable-xhdpi/ic_menu_print.png
deleted file mode 100644
index 4d4b3cc..0000000
--- a/packages/PrintSpooler/res/drawable-xhdpi/ic_menu_print.png
+++ /dev/null
Binary files differ
diff --git a/packages/PrintSpooler/res/drawable/ic_print.xml b/packages/PrintSpooler/res/drawable/ic_print.xml
new file mode 100644
index 0000000..dc6e0fb
--- /dev/null
+++ b/packages/PrintSpooler/res/drawable/ic_print.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
+    android:src="@*android:drawable/ic_print"
+    android:tint="@color/promoted_action_background_color" />
diff --git a/packages/PrintSpooler/res/drawable/ic_savetopdf.xml b/packages/PrintSpooler/res/drawable/ic_savetopdf.xml
deleted file mode 100644
index 60ed33a..0000000
--- a/packages/PrintSpooler/res/drawable/ic_savetopdf.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2014 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.
--->
-
-<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
-    android:src="@drawable/ic_menu_savetopdf"
-    android:tint="@color/promoted_action_background_color" />
diff --git a/packages/PrintSpooler/res/layout/preview_page.xml b/packages/PrintSpooler/res/layout/preview_page.xml
index 76dd76b..edce289 100644
--- a/packages/PrintSpooler/res/layout/preview_page.xml
+++ b/packages/PrintSpooler/res/layout/preview_page.xml
@@ -14,7 +14,7 @@
      limitations under the License.
 -->
 
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<com.android.printspooler.widget.PreviewPageFrame xmlns:android="http://schemas.android.com/apk/res/android"
     android:id="@+id/preview_page"
     android:layout_width="wrap_content"
     android:layout_height="wrap_content"
@@ -32,8 +32,9 @@
         android:id="@+id/page_footer"
         android:layout_width="fill_parent"
         android:layout_height="@dimen/preview_page_footer_height"
-        android:background="@*android:color/material_grey_500"
-        android:orientation="horizontal">
+        android:background="@color/material_grey_500"
+        android:orientation="horizontal"
+        android:duplicateParentState="true">
 
         <TextView
             android:id="@+id/page_number"
@@ -51,9 +52,10 @@
             android:layout_marginRight="8dip"
             android:layout_alignParentEnd="true"
             android:layout_centerVertical="true"
-            android:background="@drawable/page_selector_background">
+            android:background="@drawable/page_selector_background"
+            android:duplicateParentState="true">
         </ImageView>
 
     </RelativeLayout>
 
-</LinearLayout>
+</com.android.printspooler.widget.PreviewPageFrame>
diff --git a/packages/PrintSpooler/res/layout/preview_page_loading.xml b/packages/PrintSpooler/res/layout/preview_page_loading.xml
new file mode 100644
index 0000000..1af3a17
--- /dev/null
+++ b/packages/PrintSpooler/res/layout/preview_page_loading.xml
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="fill_parent"
+    android:layout_height="fill_parent">
+
+    <ImageView
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_margin="36dip"
+        android:layout_gravity="center"
+        android:src="@drawable/ic_grayedout_printer"
+        android:contentDescription="@null"
+        android:scaleType="centerInside"
+        android:adjustViewBounds="true">
+    </ImageView>
+
+</FrameLayout>
diff --git a/packages/PrintSpooler/res/layout/print_activity.xml b/packages/PrintSpooler/res/layout/print_activity.xml
index ee5d42a..6b8aa47 100644
--- a/packages/PrintSpooler/res/layout/print_activity.xml
+++ b/packages/PrintSpooler/res/layout/print_activity.xml
@@ -27,12 +27,13 @@
         android:id="@+id/static_content"
         android:layout_width="fill_parent"
         android:layout_height="wrap_content"
+        android:paddingStart="8dip"
         android:elevation="@dimen/preview_controls_elevation"
         android:background="?android:attr/colorPrimary">
 
         <Spinner
             android:id="@+id/destination_spinner"
-            android:layout_width="wrap_content"
+            android:layout_width="@dimen/preview_destination_spinner_width"
             android:layout_height="wrap_content"
             android:layout_marginTop="4dip"
             android:dropDownWidth="wrap_content"
@@ -97,7 +98,7 @@
         android:id="@+id/print_button"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:layout_marginEnd="16dip"
+        android:layout_marginStart="16dip"
         android:elevation="@dimen/preview_controls_elevation"
         android:background="@drawable/print_button">
     </ImageButton>
diff --git a/packages/PrintSpooler/res/layout/print_activity_controls.xml b/packages/PrintSpooler/res/layout/print_activity_controls.xml
index 31bda7e..0bf64aa 100644
--- a/packages/PrintSpooler/res/layout/print_activity_controls.xml
+++ b/packages/PrintSpooler/res/layout/print_activity_controls.xml
@@ -24,241 +24,219 @@
     android:elevation="@dimen/preview_controls_elevation"
     android:background="?android:attr/colorPrimary">
 
-        <LinearLayout
-         android:id="@+id/draggable_content"
-         android:layout_width="fill_parent"
-         android:layout_height="wrap_content"
-         android:orientation="vertical">
+    <LinearLayout
+        android:id="@+id/draggable_content"
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content"
+        android:orientation="vertical">
 
-         <com.android.printspooler.widget.PrintOptionsLayout
-             android:id="@+id/options_container"
-             android:layout_width="fill_parent"
-             android:layout_height="wrap_content"
-             printspooler:columnCount="@integer/print_option_column_count">
+        <com.android.printspooler.widget.PrintOptionsLayout
+            android:id="@+id/options_container"
+            android:layout_width="fill_parent"
+            android:layout_height="wrap_content"
+            printspooler:columnCount="@integer/print_option_column_count">
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Copies -->
+                <!-- Copies -->
 
-                 <TextView
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:labelFor="@+id/copies_edittext"
-                     android:text="@string/label_copies">
-                 </TextView>
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:labelFor="@+id/copies_edittext"
+                    android:text="@string/label_copies">
+                </TextView>
 
-                 <view
-                     class="com.android.printspooler.widget.FirstFocusableEditText"
-                     android:id="@+id/copies_edittext"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content"
-                     style="?android:attr/editTextStyle"
-                     android:singleLine="true"
-                     android:ellipsize="end"
-                     android:inputType="numberDecimal">
-                 </view>
+                <com.android.printspooler.widget.CustomErrorEditText
+                    android:id="@+id/copies_edittext"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="8dip"
+                    style="?android:attr/editTextStyle"
+                    android:singleLine="true"
+                    android:ellipsize="end"
+                    android:inputType="numberDecimal">
+                </com.android.printspooler.widget.CustomErrorEditText>
 
-             </LinearLayout>
+            </LinearLayout>
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Paper size -->
+                <!-- Paper size -->
 
-                 <TextView
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:labelFor="@+id/paper_size_spinner"
-                     android:text="@string/label_paper_size">
-                 </TextView>
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:labelFor="@+id/paper_size_spinner"
+                    android:text="@string/label_paper_size">
+                </TextView>
 
-                 <Spinner
-                     android:id="@+id/paper_size_spinner"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content">
-                 </Spinner>
+                <Spinner
+                    android:id="@+id/paper_size_spinner"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
+                </Spinner>
 
-             </LinearLayout>
+            </LinearLayout>
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Color -->
+                <!-- Color -->
 
-                 <TextView
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:labelFor="@+id/color_spinner"
-                     android:text="@string/label_color">
-                 </TextView>
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:labelFor="@+id/color_spinner"
+                    android:text="@string/label_color">
+                </TextView>
 
-                 <Spinner
-                     android:id="@+id/color_spinner"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content">
-                 </Spinner>
+                <Spinner
+                    android:id="@+id/color_spinner"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
+                </Spinner>
 
-             </LinearLayout>
+            </LinearLayout>
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Orientation -->
+                <!-- Orientation -->
 
-                 <TextView
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:labelFor="@+id/orientation_spinner"
-                     android:text="@string/label_orientation">
-                 </TextView>
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:labelFor="@+id/orientation_spinner"
+                    android:text="@string/label_orientation">
+                </TextView>
 
-                 <Spinner
-                     android:id="@+id/orientation_spinner"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content">
-                 </Spinner>
+                <Spinner
+                    android:id="@+id/orientation_spinner"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
+                </Spinner>
 
-             </LinearLayout>
+            </LinearLayout>
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Range options -->
+                <!-- Range options -->
 
-                 <TextView
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:labelFor="@+id/range_options_spinner"
-                     android:text="@string/label_pages">
-                 </TextView>
+                <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:labelFor="@+id/range_options_spinner"
+                    android:text="@string/label_pages">
+                </TextView>
 
-                 <Spinner
-                     android:id="@+id/range_options_spinner"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content">
-                 </Spinner>
+                <Spinner
+                    android:id="@+id/range_options_spinner"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
+                </Spinner>
 
-             </LinearLayout>
+            </LinearLayout>
 
-             <LinearLayout
-                 android:layout_width="wrap_content"
-                 android:layout_height="wrap_content"
-                 android:layout_marginStart="16dip"
-                 android:layout_marginEnd="16dip"
-                 android:orientation="vertical">
+            <LinearLayout
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginStart="16dip"
+                android:layout_marginEnd="16dip"
+                android:orientation="vertical">
 
-                 <!-- Pages -->
+                <!-- Pages -->
 
-                 <TextView
-                     android:id="@+id/page_range_title"
-                     android:layout_width="wrap_content"
-                     android:layout_height="wrap_content"
-                     android:layout_marginTop="8dip"
-                     android:layout_marginStart="12dip"
-                     android:textAppearance="?android:attr/textAppearanceSmall"
-                     android:text="@string/pages_range_example"
-                     android:labelFor="@+id/page_range_edittext"
-                     android:textAllCaps="false"
-                     android:visibility="visible">
-                 </TextView>
+                <TextView
+                    android:id="@+id/page_range_title"
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:layout_marginTop="8dip"
+                    android:layout_marginStart="12dip"
+                    android:textAppearance="?android:attr/textAppearanceSmall"
+                    android:text="@string/pages_range_example"
+                    android:labelFor="@+id/page_range_edittext"
+                    android:textAllCaps="false"
+                    android:visibility="visible">
+                </TextView>
 
-                 <view
-                     class="com.android.printspooler.widget.FirstFocusableEditText"
-                     android:id="@+id/page_range_edittext"
-                     android:layout_width="fill_parent"
-                     android:layout_height="wrap_content"
-                     android:layout_gravity="bottom|fill_horizontal"
-                     android:singleLine="true"
-                     android:ellipsize="end"
-                     android:visibility="visible"
-                     android:inputType="textNoSuggestions">
-                 </view>
+                <com.android.printspooler.widget.CustomErrorEditText
+                    android:id="@+id/page_range_edittext"
+                    android:layout_width="fill_parent"
+                    android:layout_height="wrap_content"
+                    android:layout_gravity="bottom|fill_horizontal"
+                    android:layout_marginStart="8dip"
+                    android:singleLine="true"
+                    android:ellipsize="end"
+                    android:visibility="visible"
+                    android:inputType="textNoSuggestions">
+                </com.android.printspooler.widget.CustomErrorEditText>
 
-             </LinearLayout>
+            </LinearLayout>
 
-         </com.android.printspooler.widget.PrintOptionsLayout>
+        </com.android.printspooler.widget.PrintOptionsLayout>
 
-         <!-- More options -->
+        <!-- More options -->
 
-         <LinearLayout
-             android:id="@+id/more_options_container"
-             android:layout_width="fill_parent"
-             android:layout_height="wrap_content"
-             android:paddingStart="28dip"
-             android:paddingEnd="28dip"
-             android:orientation="vertical"
-             android:visibility="visible">
+        <Button
+            android:id="@+id/more_options_button"
+            style="?android:attr/borderlessButtonStyle"
+            android:textColor="?android:attr/textColorPrimary"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_marginStart="16dip"
+            android:layout_marginEnd="16dip"
+            android:text="@string/more_options_button"
+            android:gravity="start|center_vertical">
+        </Button>
 
-             <ImageView
-                 android:layout_width="fill_parent"
-                 android:layout_height="1dip"
-                 android:layout_gravity="fill_horizontal"
-                 android:background="?android:attr/colorControlNormal"
-                 android:contentDescription="@null">
-             </ImageView>
+    </LinearLayout>
 
-             <Button
-                 android:id="@+id/more_options_button"
-                 style="?android:attr/borderlessButtonStyle"
-                 android:layout_width="fill_parent"
-                 android:layout_height="wrap_content"
-                 android:layout_gravity="fill_horizontal"
-                 android:text="@string/more_options_button"
-                 android:gravity="start|center_vertical"
-                 android:textAllCaps="false">
-             </Button>
+    <!-- Expand/collapse handle -->
 
-             <ImageView
-                 android:layout_width="fill_parent"
-                 android:layout_height="1dip"
-                 android:layout_gravity="fill_horizontal"
-                 android:background="?android:attr/colorControlNormal"
-                 android:contentDescription="@null">
-             </ImageView>
-
-         </LinearLayout>
-
-        </LinearLayout>
-
-        <!-- Expand/collapse handle -->
-
-        <FrameLayout
+    <FrameLayout
          android:id="@+id/expand_collapse_handle"
          android:layout_width="fill_parent"
          android:layout_height="wrap_content">
@@ -267,7 +245,7 @@
              android:id="@+id/expand_collapse_icon"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
-             android:layout_marginTop="4dip"
+             android:layout_marginTop="0dip"
              android:layout_marginBottom="4dip"
              android:layout_gravity="center"
              android:background="@drawable/ic_expand_more">
diff --git a/packages/PrintSpooler/res/layout/print_error_fragment.xml b/packages/PrintSpooler/res/layout/print_error_fragment.xml
index dc44339..3ea2abd 100644
--- a/packages/PrintSpooler/res/layout/print_error_fragment.xml
+++ b/packages/PrintSpooler/res/layout/print_error_fragment.xml
@@ -33,6 +33,9 @@
         android:id="@+id/message"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
+        android:layout_marginStart="16dip"
+        android:layout_marginEnd="16dip"
+        android:gravity="center_horizontal"
         android:text="@string/print_error_default_message"
         android:textAppearance="?android:attr/textAppearanceLargeInverse">
     </TextView>
diff --git a/packages/PrintSpooler/res/layout/printer_dropdown_item.xml b/packages/PrintSpooler/res/layout/printer_dropdown_item.xml
index 43d8aaf..4381a7a 100644
--- a/packages/PrintSpooler/res/layout/printer_dropdown_item.xml
+++ b/packages/PrintSpooler/res/layout/printer_dropdown_item.xml
@@ -17,8 +17,8 @@
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
       android:layout_width="fill_parent"
       android:layout_height="wrap_content"
-      android:paddingStart="16dip"
-      android:paddingEnd="16dip"
+      android:paddingStart="8dip"
+      android:paddingEnd="8dip"
       android:minHeight="56dip"
       android:orientation="horizontal"
       android:gravity="start|center_vertical">
diff --git a/packages/PrintSpooler/res/layout/select_printer_activity.xml b/packages/PrintSpooler/res/layout/select_printer_activity.xml
index 173057b..77c500a 100644
--- a/packages/PrintSpooler/res/layout/select_printer_activity.xml
+++ b/packages/PrintSpooler/res/layout/select_printer_activity.xml
@@ -23,8 +23,6 @@
         android:id="@android:id/list"
         android:layout_width="fill_parent"
         android:layout_height="fill_parent"
-        android:paddingStart="@dimen/printer_list_view_padding_start"
-        android:paddingEnd="@dimen/printer_list_view_padding_end"
         android:scrollbarStyle="outsideOverlay"
         android:cacheColorHint="@android:color/transparent"
         android:scrollbarAlwaysDrawVerticalTrack="true" >
diff --git a/packages/PrintSpooler/res/layout/spinner_dropdown_item.xml b/packages/PrintSpooler/res/layout/spinner_dropdown_item.xml
deleted file mode 100644
index 14403a1..0000000
--- a/packages/PrintSpooler/res/layout/spinner_dropdown_item.xml
+++ /dev/null
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- 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.
--->
-
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:minHeight="?android:attr/listPreferredItemHeightSmall"
-    android:orientation="vertical"
-    android:gravity="start|center_vertical">
-
-    <TextView
-        android:id="@+id/title"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        style="?android:attr/spinnerDropDownItemStyle"
-        android:textAppearance="?android:attr/textAppearanceMedium"
-        android:textColor="?android:attr/textColorPrimary"
-        android:singleLine="true"
-        android:ellipsize="end"
-        android:textIsSelectable="false"
-        android:gravity="top|left"
-        android:duplicateParentState="true">
-    </TextView>
-
-    <TextView
-        android:id="@+id/subtitle"
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        style="?android:attr/spinnerDropDownItemStyle"
-        android:textAppearance="?android:attr/textAppearanceSmall"
-        android:textColor="?android:attr/textColorPrimary"
-        android:singleLine="true"
-        android:ellipsize="end"
-        android:textIsSelectable="false"
-        android:visibility="gone"
-        android:duplicateParentState="true">
-    </TextView>
-
-</LinearLayout>
diff --git a/packages/PrintSpooler/res/values-af/strings.xml b/packages/PrintSpooler/res/values-af/strings.xml
index 2e2b425..1a840e3 100644
--- a/packages/PrintSpooler/res/values-af/strings.xml
+++ b/packages/PrintSpooler/res/values-af/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alle drukkers…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Drukdialoog"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Bladsy <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> van <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Opsomming, kopieë <xliff:g id="COPIES">%1$s</xliff:g>, papiergrootte <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Vou handvatsel uit"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Vou handvatsel in"</string>
+    <string name="print_button" msgid="645164566271246268">"Druk"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Stoor na PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Drukopsies uitgevou"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Drukopsies ingevou"</string>
     <string name="search" msgid="5421724265322228497">"Deursoek"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alle drukkers"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Voeg diens by"</string>
diff --git a/packages/PrintSpooler/res/values-am/strings.xml b/packages/PrintSpooler/res/values-am/strings.xml
index 986d2ac..683d585 100644
--- a/packages/PrintSpooler/res/values-am/strings.xml
+++ b/packages/PrintSpooler/res/values-am/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"ሁሉም አታሚዎች…"</string>
     <string name="print_dialog" msgid="32628687461331979">"የህትመት መገናኛ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"ገጽ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> ከ<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"ማጠቃለያ፣ ቅጂዎች <xliff:g id="COPIES">%1$s</xliff:g>፣ የወረቀት መጠን <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"እጀታን ወደ ውጪ ላክ"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"እጀታን ሰብስብ"</string>
+    <string name="print_button" msgid="645164566271246268">"አትም"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"ወደ ፔዲኤፍ አስቀምጥ"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"የህትመት አማራጮች ተዘርግተዋል"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"የህትመት አማራጮች ተሰብስበዋል"</string>
     <string name="search" msgid="5421724265322228497">"ፍለጋ"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"ሁሉም አታሚዎች"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"አገልግሎት አክል"</string>
diff --git a/packages/PrintSpooler/res/values-ar/strings.xml b/packages/PrintSpooler/res/values-ar/strings.xml
index 82b5e03..0a7d301 100644
--- a/packages/PrintSpooler/res/values-ar/strings.xml
+++ b/packages/PrintSpooler/res/values-ar/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"جميع الطابعات…"</string>
     <string name="print_dialog" msgid="32628687461331979">"مربع حوار الطباعة"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"الصفحة <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> من <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"الملخص، النسخ <xliff:g id="COPIES">%1$s</xliff:g>، حجم الورق <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"مقبض التوسيع"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"مقبض التصغير"</string>
+    <string name="print_button" msgid="645164566271246268">"طباعة"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"‏حفظ بتنسيق PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"تم توسيع خيارات الطباعة"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"تم تصغير خيارات الطباعة"</string>
     <string name="search" msgid="5421724265322228497">"بحث"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"جميع الطابعات"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"إضافة خدمة"</string>
diff --git a/packages/PrintSpooler/res/values-bg/strings.xml b/packages/PrintSpooler/res/values-bg/strings.xml
index c5f82fd..8792349 100644
--- a/packages/PrintSpooler/res/values-bg/strings.xml
+++ b/packages/PrintSpooler/res/values-bg/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Всички принтери…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Диалогов прозорец за отпечатване"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Страница <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> от <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Обобщена информация: копия – <xliff:g id="COPIES">%1$s</xliff:g>, размер на хартията – <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Манипулатор за разгъване"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Манипулатор за свиване"</string>
+    <string name="print_button" msgid="645164566271246268">"Печат"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Запазване като PDF файл"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Опциите за отпечатване са разгънати"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Опциите за отпечатване са свити"</string>
     <string name="search" msgid="5421724265322228497">"Търсене"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Всички принтери"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Добавяне на услуга"</string>
diff --git a/packages/PrintSpooler/res/values-bn-rBD/strings.xml b/packages/PrintSpooler/res/values-bn-rBD/strings.xml
index 35a7285..5c5fabf 100644
--- a/packages/PrintSpooler/res/values-bn-rBD/strings.xml
+++ b/packages/PrintSpooler/res/values-bn-rBD/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"সমস্ত মুদ্রক…"</string>
     <string name="print_dialog" msgid="32628687461331979">"মুদ্রণ ডায়লগ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g>টির মধ্যে <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> নম্বর পৃষ্ঠা"</string>
+    <string name="summary_template" msgid="8899734908625669193">"সারাংশ, <xliff:g id="COPIES">%1$s</xliff:g>টি অনুলিপি, কাগজের আকার <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"প্রসারিত করার হ্যান্ডেল"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"সঙ্কুচিত করার হ্যান্ডেল"</string>
+    <string name="print_button" msgid="645164566271246268">"মুদ্রণ করুন"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF হিসাবে সংরক্ষণ করুন"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"মুদ্রণ বিকল্প প্রসারিত হয়েছে"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"মুদ্রণ বিকল্প সংকুচিত হয়েছে"</string>
     <string name="search" msgid="5421724265322228497">"অনুসন্ধান করুন"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"সমস্ত মুদ্রক"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"পরিষেবা যোগ করুন"</string>
diff --git a/packages/PrintSpooler/res/values-ca/strings.xml b/packages/PrintSpooler/res/values-ca/strings.xml
index a650d7e..6d66b86 100644
--- a/packages/PrintSpooler/res/values-ca/strings.xml
+++ b/packages/PrintSpooler/res/values-ca/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Totes les impressores…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Diàleg d\'impressió"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Pàgina <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de: <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resum; còpies: <xliff:g id="COPIES">%1$s</xliff:g>; mida del paper: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Desplega l\'ansa"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Replega l\'ansa"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimeix"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Desa en PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"S\'han desplegat les opcions d\'impressió."</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"S\'han replegat les opcions d\'impressió."</string>
     <string name="search" msgid="5421724265322228497">"Cerca"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Totes les impressores"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Afegeix un servei"</string>
@@ -44,7 +52,7 @@
     <string name="print_search_box_hidden_utterance" msgid="5727755169343113351">"S\'ha amagat el quadre de cerca"</string>
     <string name="print_add_printer" msgid="1088656468360653455">"Afegeix una impressora"</string>
     <string name="print_select_printer" msgid="7388760939873368698">"Selecciona una impressora"</string>
-    <string name="print_forget_printer" msgid="5035287497291910766">"Oblida la impressora"</string>
+    <string name="print_forget_printer" msgid="5035287497291910766">"Esborra la impressora"</string>
   <plurals name="print_search_result_count_utterance">
     <item quantity="one" msgid="4484953260685964252">"S\'ha trobat <xliff:g id="COUNT">%1$s</xliff:g> impressora"</item>
     <item quantity="other" msgid="6533817036607128241">"S\'han trobat <xliff:g id="COUNT">%1$s</xliff:g> impressores"</item>
diff --git a/packages/PrintSpooler/res/values-cs/strings.xml b/packages/PrintSpooler/res/values-cs/strings.xml
index 1b84568..791e485 100644
--- a/packages/PrintSpooler/res/values-cs/strings.xml
+++ b/packages/PrintSpooler/res/values-cs/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Všechny tiskárny…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Dialog tisku"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Stránka <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> z <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Souhrn, počet kopií: <xliff:g id="COPIES">%1$s</xliff:g>, velikost papíru: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Úchyt k rozbalení"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Úchyt ke sbalení"</string>
+    <string name="print_button" msgid="645164566271246268">"Tisk"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Uložit do souboru PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Možnosti tisku jsou rozbaleny"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Možnosti tisku jsou sbaleny"</string>
     <string name="search" msgid="5421724265322228497">"Hledat"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Všechny tiskárny"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Přidat službu"</string>
diff --git a/packages/PrintSpooler/res/values-da/strings.xml b/packages/PrintSpooler/res/values-da/strings.xml
index 0e6fef6..c4a383e 100644
--- a/packages/PrintSpooler/res/values-da/strings.xml
+++ b/packages/PrintSpooler/res/values-da/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alle printere..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Udskriftsdialog"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> af <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Side <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> ud af <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Opsummering, kopier <xliff:g id="COPIES">%1$s</xliff:g>, papirstørrelse <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Håndtag til visning"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Håndtag til skjuling"</string>
+    <string name="print_button" msgid="645164566271246268">"Udskriv"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Gem som PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Valgmuligheder for udskrift vises"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Valgmulgheder for udskrift er skjult"</string>
     <string name="search" msgid="5421724265322228497">"Søg"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alle printere"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Tilføj tjeneste"</string>
diff --git a/packages/PrintSpooler/res/values-de/strings.xml b/packages/PrintSpooler/res/values-de/strings.xml
index cd17d0d..43be3dc 100644
--- a/packages/PrintSpooler/res/values-de/strings.xml
+++ b/packages/PrintSpooler/res/values-de/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alle Drucker…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Druckdialogfeld"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Seite <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> von <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Zusammenfassung: Kopien: <xliff:g id="COPIES">%1$s</xliff:g>, Papierformat <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Steuerelement zum Einblenden"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Steuerelement zum Ausblenden"</string>
+    <string name="print_button" msgid="645164566271246268">"Drucken"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Als PDF speichern"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Druckoptionen eingeblendet"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Druckoptionen ausgeblendet"</string>
     <string name="search" msgid="5421724265322228497">"Suchen"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alle Drucker"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Dienst hinzufügen"</string>
diff --git a/packages/PrintSpooler/res/values-el/strings.xml b/packages/PrintSpooler/res/values-el/strings.xml
index 2ea3cb8..25f609b 100644
--- a/packages/PrintSpooler/res/values-el/strings.xml
+++ b/packages/PrintSpooler/res/values-el/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Όλοι οι εκτυπωτές…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Πλαίσιο διαλόγου εκτύπωσης"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Σελίδα <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> από <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Σύνοψη, αντίγραφα <xliff:g id="COPIES">%1$s</xliff:g>, μέγεθος χαρτιού <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Επέκταση λαβής"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Σύμπτυξη λαβής"</string>
+    <string name="print_button" msgid="645164566271246268">"Εκτύπωση"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Αποθήκευση σε PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Έγινε επέκταση των επιλογών εκτύπωσης"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Έγινε σύμπτυξη των επιλογών εκτύπωσης"</string>
     <string name="search" msgid="5421724265322228497">"Αναζήτηση"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Όλοι οι εκτυπωτές"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Προσθήκη υπηρεσίας"</string>
diff --git a/packages/PrintSpooler/res/values-en-rGB/strings.xml b/packages/PrintSpooler/res/values-en-rGB/strings.xml
index df8cca2..2198c7a 100644
--- a/packages/PrintSpooler/res/values-en-rGB/strings.xml
+++ b/packages/PrintSpooler/res/values-en-rGB/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"All printers…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Print dialogue"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Page <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> of <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Summary, copies <xliff:g id="COPIES">%1$s</xliff:g>, paper size <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Expand handle"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Collapse handle"</string>
+    <string name="print_button" msgid="645164566271246268">"Print"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Save to PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Print options expanded"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Print options collapsed"</string>
     <string name="search" msgid="5421724265322228497">"Search"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"All printers"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Add service"</string>
diff --git a/packages/PrintSpooler/res/values-en-rIN/strings.xml b/packages/PrintSpooler/res/values-en-rIN/strings.xml
index df8cca2..2198c7a 100644
--- a/packages/PrintSpooler/res/values-en-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-en-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"All printers…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Print dialogue"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Page <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> of <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Summary, copies <xliff:g id="COPIES">%1$s</xliff:g>, paper size <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Expand handle"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Collapse handle"</string>
+    <string name="print_button" msgid="645164566271246268">"Print"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Save to PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Print options expanded"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Print options collapsed"</string>
     <string name="search" msgid="5421724265322228497">"Search"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"All printers"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Add service"</string>
diff --git a/packages/PrintSpooler/res/values-es-rUS/strings.xml b/packages/PrintSpooler/res/values-es-rUS/strings.xml
index 9825fe3..e194f55 100644
--- a/packages/PrintSpooler/res/values-es-rUS/strings.xml
+++ b/packages/PrintSpooler/res/values-es-rUS/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Todas las impresoras…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Cuadro de diálogo de impresión"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Página <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resumen, copias <xliff:g id="COPIES">%1$s</xliff:g>, tamaño de papel <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Controlador para expandir"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Controlador para contraer"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimir"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Guardar como PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opciones de impresión expandidas"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opciones de impresión contraídas"</string>
     <string name="search" msgid="5421724265322228497">"Buscar"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Todas las impresoras"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Agregar servicio"</string>
diff --git a/packages/PrintSpooler/res/values-es/strings.xml b/packages/PrintSpooler/res/values-es/strings.xml
index 5c49ef0d..b0ab529 100644
--- a/packages/PrintSpooler/res/values-es/strings.xml
+++ b/packages/PrintSpooler/res/values-es/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Todas las impresoras…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Cuadro de diálogo de impresión"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Página <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resumen, copias (<xliff:g id="COPIES">%1$s</xliff:g>), tamaño del papel (<xliff:g id="PAPER_SIZE">%2$s</xliff:g>)"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Controlador para ampliar"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Controlador para contraer"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimir"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Guardar en PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opciones de impresión ampliadas"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opciones de impresión contraídas"</string>
     <string name="search" msgid="5421724265322228497">"Buscar"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Todas las impresoras"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Añadir servicio"</string>
diff --git a/packages/PrintSpooler/res/values-et-rEE/strings.xml b/packages/PrintSpooler/res/values-et-rEE/strings.xml
index efb03dd..6e75bbb 100644
--- a/packages/PrintSpooler/res/values-et-rEE/strings.xml
+++ b/packages/PrintSpooler/res/values-et-rEE/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Kõik printerid …"</string>
     <string name="print_dialog" msgid="32628687461331979">"Printimisdialoog"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>-st"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g> lehest"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Kokkuvõte, koopiad <xliff:g id="COPIES">%1$s</xliff:g>, paberi suurus <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Laiendamispide"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Ahendamispide"</string>
+    <string name="print_button" msgid="645164566271246268">"Prindi"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF-i salvestamine"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Prindivalikud on laiendatud"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Prindivalikud on ahendatud"</string>
     <string name="search" msgid="5421724265322228497">"Otsing"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Kõik printerid"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Lisa teenus"</string>
diff --git a/packages/PrintSpooler/res/values-eu-rES/strings.xml b/packages/PrintSpooler/res/values-eu-rES/strings.xml
index 69a04ad..4f0f8fc 100644
--- a/packages/PrintSpooler/res/values-eu-rES/strings.xml
+++ b/packages/PrintSpooler/res/values-eu-rES/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Inprimagailu guztiak…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Inprimatzeko elkarrizketa-koadroa"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g> orria"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Laburpena, <xliff:g id="COPIES">%1$s</xliff:g> kopia, <xliff:g id="PAPER_SIZE">%2$s</xliff:g> paper-tamaina"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Zabaldu heldulekua"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Tolestu heldulekua"</string>
+    <string name="print_button" msgid="645164566271246268">"Inprimatu"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Gorde PDF gisa"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Inprimatzeko aukerak zabalduta daude"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Inprimatzeko aukerak tolestuta daude"</string>
     <string name="search" msgid="5421724265322228497">"Bilatu"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Inprimagailu guztiak"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Gehitu zerbitzua"</string>
diff --git a/packages/PrintSpooler/res/values-fa/strings.xml b/packages/PrintSpooler/res/values-fa/strings.xml
index e178cba..d35a063 100644
--- a/packages/PrintSpooler/res/values-fa/strings.xml
+++ b/packages/PrintSpooler/res/values-fa/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"همه چاپگرها..."</string>
     <string name="print_dialog" msgid="32628687461331979">"چاپ گفتگو"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"صفحه <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> از <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"خلاصه، تعداد نسخه <xliff:g id="COPIES">%1$s</xliff:g>، اندازه کاغذ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"بزرگ کردن لیست گزینه‌ها"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"کوچک کردن لیست گزینه‌ها"</string>
+    <string name="print_button" msgid="645164566271246268">"چاپ"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"‏ذخیره در PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"گزینه‌های چاپ بزرگ شد"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"گزینه‌های چاپ کوچک شد"</string>
     <string name="search" msgid="5421724265322228497">"جستجو"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"همه چاپگرها"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"افزودن سرویس"</string>
diff --git a/packages/PrintSpooler/res/values-fi/strings.xml b/packages/PrintSpooler/res/values-fi/strings.xml
index dcda41f..8e540f9 100644
--- a/packages/PrintSpooler/res/values-fi/strings.xml
+++ b/packages/PrintSpooler/res/values-fi/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Kaikki tulostimet…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Tulostusikkuna"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Sivu <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Yhteenveto, kopioita <xliff:g id="COPIES">%1$s</xliff:g>, paperikoko <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Laajennuskahva"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Tiivistyskahva"</string>
+    <string name="print_button" msgid="645164566271246268">"Tulosta"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Tallenna PDF-muodossa"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Tulostusasetukset on laajennettu"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Tulostusasetukset on tiivistetty"</string>
     <string name="search" msgid="5421724265322228497">"Haku"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Kaikki tulostimet"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Lisää palvelu"</string>
diff --git a/packages/PrintSpooler/res/values-fr-rCA/strings.xml b/packages/PrintSpooler/res/values-fr-rCA/strings.xml
index 9b72da1..279a467 100644
--- a/packages/PrintSpooler/res/values-fr-rCA/strings.xml
+++ b/packages/PrintSpooler/res/values-fr-rCA/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Toutes les imprimantes…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Boîte de dialogue d\'impression"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> sur <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Page <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Résumé, copies (<xliff:g id="COPIES">%1$s</xliff:g>), taille du papier (<xliff:g id="PAPER_SIZE">%2$s</xliff:g>)"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Poignée de développement"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Poignée de réduction"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimer"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Enregistrer au format PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Options d\'impression développées"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Options d\'impression réduites"</string>
     <string name="search" msgid="5421724265322228497">"Rechercher"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Toutes les imprimantes"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Ajouter le service"</string>
diff --git a/packages/PrintSpooler/res/values-fr/strings.xml b/packages/PrintSpooler/res/values-fr/strings.xml
index 601ea51..ebfd5de 100644
--- a/packages/PrintSpooler/res/values-fr/strings.xml
+++ b/packages/PrintSpooler/res/values-fr/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Toutes les imprim."</string>
     <string name="print_dialog" msgid="32628687461331979">"Boîte de dialogue d\'impression"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Page <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> sur <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Résumé, copies (<xliff:g id="COPIES">%1$s</xliff:g>), taille du papier (<xliff:g id="PAPER_SIZE">%2$s</xliff:g>)"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Poignée de développement"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Poignée de réduction"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimer"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Enregistrer au format PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Les options d\'impression ont été développées."</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Les options d\'impression ont été réduites."</string>
     <string name="search" msgid="5421724265322228497">"Rechercher"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Toutes les imprimantes"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Ajouter un service"</string>
diff --git a/packages/PrintSpooler/res/values-gl-rES/strings.xml b/packages/PrintSpooler/res/values-gl-rES/strings.xml
index 9b180cc..6e542ea 100644
--- a/packages/PrintSpooler/res/values-gl-rES/strings.xml
+++ b/packages/PrintSpooler/res/values-gl-rES/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Todas as impresoras..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Diálogo de impresión"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Páxina <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resumo, copias <xliff:g id="COPIES">%1$s</xliff:g>, tamaño do papel <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Amplía a agarradoira"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Contrae a agarradoira"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimir"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Gardar en PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opcións de impresión ampliadas"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opcións de impresión contraídas"</string>
     <string name="search" msgid="5421724265322228497">"Buscar"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Todas as impresoras"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Engadir servizo"</string>
diff --git a/packages/PrintSpooler/res/values-hi/strings.xml b/packages/PrintSpooler/res/values-hi/strings.xml
index 581995a..9186f64 100644
--- a/packages/PrintSpooler/res/values-hi/strings.xml
+++ b/packages/PrintSpooler/res/values-hi/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"सभी प्रिंटर..."</string>
     <string name="print_dialog" msgid="32628687461331979">"प्रिंट डॉयलॉग"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g> में से पृष्ठ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"सारांश, प्रतियां <xliff:g id="COPIES">%1$s</xliff:g>, काग़ज़ का आकार <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"हैंडल विस्तृत करें"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"हैंडल संक्षिप्त करें"</string>
+    <string name="print_button" msgid="645164566271246268">"प्रिंट करें"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF में सहेजें"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"प्रिंट विकल्पों को विस्तृत किया गया"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"प्रिंट विकल्पों को संक्षिप्त किया गया"</string>
     <string name="search" msgid="5421724265322228497">"खोजें"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"सभी प्रिंटर"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"सेवा जोड़ें"</string>
@@ -60,7 +68,7 @@
     <item quantity="one" msgid="5866624638054847057">"<xliff:g id="PRINT_JOB_NAME">%1$d</xliff:g> प्रिंट कार्य"</item>
     <item quantity="other" msgid="8746611264734222865">"<xliff:g id="PRINT_JOB_NAME">%1$d</xliff:g> प्रिंट कार्य"</item>
   </plurals>
-    <string name="cancel" msgid="4373674107267141885">"रद्द करें"</string>
+    <string name="cancel" msgid="4373674107267141885">"रहने दें"</string>
     <string name="restart" msgid="2472034227037808749">"पुन: आरंभ करें"</string>
     <string name="no_connection_to_printer" msgid="2159246915977282728">"प्रिंटर के लिए कोई कनेक्शन नहीं"</string>
     <string name="reason_unknown" msgid="5507940196503246139">"अज्ञात"</string>
diff --git a/packages/PrintSpooler/res/values-hr/strings.xml b/packages/PrintSpooler/res/values-hr/strings.xml
index 3b82f85..8132d21 100644
--- a/packages/PrintSpooler/res/values-hr/strings.xml
+++ b/packages/PrintSpooler/res/values-hr/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Svi pisači…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Dijaloški okvir za ispis"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Stranica <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> od <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Sažetak, kopije <xliff:g id="COPIES">%1$s</xliff:g>, veličina papira <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Ručica za proširenje"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Ručica za sažimanje"</string>
+    <string name="print_button" msgid="645164566271246268">"Ispis"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Spremanje u PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opcije ispisa proširene"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opcije ispisa sažete"</string>
     <string name="search" msgid="5421724265322228497">"Pretraživanje"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Svi pisači"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Dodaj uslugu"</string>
diff --git a/packages/PrintSpooler/res/values-hu/strings.xml b/packages/PrintSpooler/res/values-hu/strings.xml
index 63f7169..3ebc450 100644
--- a/packages/PrintSpooler/res/values-hu/strings.xml
+++ b/packages/PrintSpooler/res/values-hu/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Az összes nyomtató…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Nyomtatási párbeszédablak"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>./<xliff:g id="PAGE_COUNT">%2$d</xliff:g> oldal"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Összegzés, <xliff:g id="COPIES">%1$s</xliff:g> példány, papírméret: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"„Kibontás” fogantyú"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"„Összecsukás” fogantyú"</string>
+    <string name="print_button" msgid="645164566271246268">"Nyomtatás"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Mentés PDF-be"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Nyomtatási lehetőségek kibontva"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Nyomtatási lehetőségek összecsukva"</string>
     <string name="search" msgid="5421724265322228497">"Keresés"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Az összes nyomtató"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Szolgáltatás hozzáadása"</string>
diff --git a/packages/PrintSpooler/res/values-hy-rAM/strings.xml b/packages/PrintSpooler/res/values-hy-rAM/strings.xml
index f77a7e8..5ef15a5c 100644
--- a/packages/PrintSpooler/res/values-hy-rAM/strings.xml
+++ b/packages/PrintSpooler/res/values-hy-rAM/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Բոլոր տպիչները..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Տպելու երկխոսության պատուհան"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Էջ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>՝ <xliff:g id="PAGE_COUNT">%2$d</xliff:g>-ից"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Ամփոփում, պատճենները՝ <xliff:g id="COPIES">%1$s</xliff:g> , թղթի չափը՝ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Ընդարձակման կարգավորում"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Կոծկման կարգավորում"</string>
+    <string name="print_button" msgid="645164566271246268">"Տպել"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Պահել որպես PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Տպելու կարգավորումները կոծկված են"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Տպելու կարգավորումներն ընդարձակված են"</string>
     <string name="search" msgid="5421724265322228497">"Որոնել"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Բոլոր տպիչները"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Ավելացնել ծառայություն"</string>
diff --git a/packages/PrintSpooler/res/values-in/strings.xml b/packages/PrintSpooler/res/values-in/strings.xml
index fa47da3..9714b0f 100644
--- a/packages/PrintSpooler/res/values-in/strings.xml
+++ b/packages/PrintSpooler/res/values-in/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Semua printer…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Cetak dialog"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Halaman <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> dari <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Ringkasan, salinan <xliff:g id="COPIES">%1$s</xliff:g>, ukuran kertas <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Luaskan gagang"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Ciutkan gagang"</string>
+    <string name="print_button" msgid="645164566271246268">"Cetak"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Simpan ke PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opsi cetak diluaskan"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opsi cetak diciutkan"</string>
     <string name="search" msgid="5421724265322228497">"Cari"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Semua printer"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Tambahkan layanan"</string>
diff --git a/packages/PrintSpooler/res/values-is-rIS/strings.xml b/packages/PrintSpooler/res/values-is-rIS/strings.xml
index d18b8b5..41a047d 100644
--- a/packages/PrintSpooler/res/values-is-rIS/strings.xml
+++ b/packages/PrintSpooler/res/values-is-rIS/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Allir prentarar…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Prentgluggi"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Síða <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> af <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Yfirlit, <xliff:g id="COPIES">%1$s</xliff:g> eintök, pappírsstærð <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Stækkunarhandfang"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Minnkunarhandfang"</string>
+    <string name="print_button" msgid="645164566271246268">"Prenta"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Vista sem PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Prentvalkostir stækkaðir"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Prentvalkostir minnkaðir"</string>
     <string name="search" msgid="5421724265322228497">"Leita"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Allir prentarar"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Bæta við þjónustu"</string>
diff --git a/packages/PrintSpooler/res/values-it/strings.xml b/packages/PrintSpooler/res/values-it/strings.xml
index 28f51ac..3653c56 100644
--- a/packages/PrintSpooler/res/values-it/strings.xml
+++ b/packages/PrintSpooler/res/values-it/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Tutte le stampanti…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Finestra di dialogo Stampa"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Pagina <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> di <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Riepilogo, copie <xliff:g id="COPIES">%1$s</xliff:g>,  <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Punto di controllo per l\'espansione"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Punto di controllo per la compressione"</string>
+    <string name="print_button" msgid="645164566271246268">"Stampa"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Salva come PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opzioni di stampa espanse"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opzioni di stampa compresse"</string>
     <string name="search" msgid="5421724265322228497">"Cerca"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Tutte le stampanti"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Aggiungi servizio"</string>
diff --git a/packages/PrintSpooler/res/values-iw/strings.xml b/packages/PrintSpooler/res/values-iw/strings.xml
index 5bc339c..ba293a0 100644
--- a/packages/PrintSpooler/res/values-iw/strings.xml
+++ b/packages/PrintSpooler/res/values-iw/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"כל המדפסות…"</string>
     <string name="print_dialog" msgid="32628687461331979">"תיבת דו שיח של מדפסת"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"עמוד <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> מתוך <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"סיכום, עותקים <xliff:g id="COPIES">%1$s</xliff:g>, גודל נייר <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ידית הרחבה"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ידית כיווץ"</string>
+    <string name="print_button" msgid="645164566271246268">"הדפס"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"‏שמור כ-PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"אפשרויות ההדפסה הורחבו"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"אפשרויות ההדפסה כווצו"</string>
     <string name="search" msgid="5421724265322228497">"חפש"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"כל המדפסות"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"הוסף שירות"</string>
diff --git a/packages/PrintSpooler/res/values-ja/strings.xml b/packages/PrintSpooler/res/values-ja/strings.xml
index 828c255..f3fed3b 100644
--- a/packages/PrintSpooler/res/values-ja/strings.xml
+++ b/packages/PrintSpooler/res/values-ja/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"すべてのプリンタ…"</string>
     <string name="print_dialog" msgid="32628687461331979">"印刷ダイアログ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>ページ"</string>
+    <string name="summary_template" msgid="8899734908625669193">"概要、部数<xliff:g id="COPIES">%1$s</xliff:g>、用紙サイズ<xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"展開ハンドル"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"折りたたみハンドル"</string>
+    <string name="print_button" msgid="645164566271246268">"印刷"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDFに保存"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"印刷オプションを展開しました"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"印刷オプションを折りたたみました"</string>
     <string name="search" msgid="5421724265322228497">"検索"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"すべてのプリンタ"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"サービスを追加"</string>
diff --git a/packages/PrintSpooler/res/values-ka-rGE/strings.xml b/packages/PrintSpooler/res/values-ka-rGE/strings.xml
index d885765..061e9fb 100644
--- a/packages/PrintSpooler/res/values-ka-rGE/strings.xml
+++ b/packages/PrintSpooler/res/values-ka-rGE/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"ყველა პრინტერი…"</string>
     <string name="print_dialog" msgid="32628687461331979">"ბეჭდვის სარკმელი"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"გვერდი <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>-დან"</string>
+    <string name="summary_template" msgid="8899734908625669193">"შეჯამება, ასლები <xliff:g id="COPIES">%1$s</xliff:g>, გვერდის ზომა <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"გაშლის სახელური"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ჩაკეცვის სახელური"</string>
+    <string name="print_button" msgid="645164566271246268">"ბეჭდვა"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF-ში შენახვა"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ბეჭდვის პარამეტრები გაშლილია"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ბეჭდვის პარამეტრები ჩაკეცილია"</string>
     <string name="search" msgid="5421724265322228497">"ძიება"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"ყველა პრინტერი"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"სერვისის დამატება"</string>
diff --git a/packages/PrintSpooler/res/values-kk-rKZ/strings.xml b/packages/PrintSpooler/res/values-kk-rKZ/strings.xml
index 8c6a34fd..b02714b 100644
--- a/packages/PrintSpooler/res/values-kk-rKZ/strings.xml
+++ b/packages/PrintSpooler/res/values-kk-rKZ/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Барлық принтерлер…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Басу терезесі"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g> ішінен <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> бет"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Жиынтық мәліметтер, көшірмелер <xliff:g id="COPIES">%1$s</xliff:g>, қағаз өлшемі <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Кеңейту таңбалауышы"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Тасалау таңбалауышы"</string>
+    <string name="print_button" msgid="645164566271246268">"Басып шығару"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF пішімінде сақтау"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Басып шығару опциялары кеңейтілді"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Басып шығару опциялары тасаланды"</string>
     <string name="search" msgid="5421724265322228497">"Іздеу"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Барлық принтерлер"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Қызмет қосу"</string>
diff --git a/packages/PrintSpooler/res/values-km-rKH/strings.xml b/packages/PrintSpooler/res/values-km-rKH/strings.xml
index edda7e9..63d710a 100644
--- a/packages/PrintSpooler/res/values-km-rKH/strings.xml
+++ b/packages/PrintSpooler/res/values-km-rKH/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"ម៉ាស៊ីន​បោះពុម្ព​ទាំងអស់ ..."</string>
     <string name="print_dialog" msgid="32628687461331979">"ប្រអប់​បោះពុម្ព"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"ទំព័រ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> នៃ <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"សង្ខេប, ច្បាប់​ចម្លង <xliff:g id="COPIES">%1$s</xliff:g>, ទំហំ​ក្រដាស <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ពង្រីក​​ចំណុច​ទាញ"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"បង្រួម​ចំណុច​ទាញ"</string>
+    <string name="print_button" msgid="645164566271246268">"បោះពុម្ព"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"រក្សាទុក​ជា PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"បាន​ពង្រីក​ជម្រើស​បោះពុម្ព"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"បាន​បង្រួម​ជម្រើស​បោះពុម្ព"</string>
     <string name="search" msgid="5421724265322228497">"ស្វែងរក"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"ម៉ាស៊ីន​បោះពុម្ព​ទាំងអស់"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"បន្ថែម​សេវាកម្ម"</string>
@@ -62,7 +70,7 @@
   </plurals>
     <string name="cancel" msgid="4373674107267141885">"បោះបង់"</string>
     <string name="restart" msgid="2472034227037808749">"ចាប់ផ្ដើម​ឡើងវិញ"</string>
-    <string name="no_connection_to_printer" msgid="2159246915977282728">"គ្មាន​​​ការ​ភ្ជាប់​ទៅ​ម៉ាស៊ីន​បោះពុម្ព"</string>
+    <string name="no_connection_to_printer" msgid="2159246915977282728">"គ្មាន​​​ការ​ភ្ជាប់​ទៅ​ម៉ាស៊ីន​បោះពុម្ព​"</string>
     <string name="reason_unknown" msgid="5507940196503246139">"មិន​ស្គាល់"</string>
     <string name="printer_unavailable" msgid="2434170617003315690">"<xliff:g id="PRINT_JOB_NAME">%1$s</xliff:g> – មិន​អាច​ប្រើ​បាន"</string>
   <string-array name="color_mode_labels">
diff --git a/packages/PrintSpooler/res/values-kn-rIN/strings.xml b/packages/PrintSpooler/res/values-kn-rIN/strings.xml
index 7f848e4..3950866 100644
--- a/packages/PrintSpooler/res/values-kn-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-kn-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"ಎಲ್ಲಾ ಮುದ್ರಕಗಳು…"</string>
     <string name="print_dialog" msgid="32628687461331979">"ಮುದ್ರಣ ಸಂವಾದ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"ಪುಟ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"ಸಾರಾಂಶ, ನಕಲುಗಳು <xliff:g id="COPIES">%1$s</xliff:g>, ಪೇಪರ್ ಗಾತ್ರ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ಹ್ಯಾಂಡಲ್ ವಿಸ್ತರಿಸಿ"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ಹ್ಯಾಂಡಲ್ ಮುಚ್ಚಿರಿ"</string>
+    <string name="print_button" msgid="645164566271246268">"ಮುದ್ರಿಸು"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF ಗೆ ಉಳಿಸು"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ಪ್ರಿಂಟ್ ಆಯ್ಕೆಗಳನ್ನು ವಿಸ್ತರಿಸಲಾಗಿದೆ"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ಪ್ರಿಂಟ್ ಆಯ್ಕೆಗಳನ್ನು ಮುಚ್ಚಲಾಗಿದೆ"</string>
     <string name="search" msgid="5421724265322228497">"ಹುಡುಕು"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"ಎಲ್ಲಾ ಮುದ್ರಕಗಳು"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"ಸೇವೆಯನ್ನು ಸೇರಿಸು"</string>
diff --git a/packages/PrintSpooler/res/values-ko/strings.xml b/packages/PrintSpooler/res/values-ko/strings.xml
index 1ccd25a..f1a4869 100644
--- a/packages/PrintSpooler/res/values-ko/strings.xml
+++ b/packages/PrintSpooler/res/values-ko/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"모든 프린터…"</string>
     <string name="print_dialog" msgid="32628687461331979">"인쇄 대화상자"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"전체 <xliff:g id="PAGE_COUNT">%2$d</xliff:g>페이지 중 현재 <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>페이지"</string>
+    <string name="summary_template" msgid="8899734908625669193">"요약, 매수 <xliff:g id="COPIES">%1$s</xliff:g>, 용지 크기 <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"펼치기 핸들"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"접기 핸들"</string>
+    <string name="print_button" msgid="645164566271246268">"인쇄"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF에 저장"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"인쇄 옵션 펼침"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"인쇄 옵션 접힘"</string>
     <string name="search" msgid="5421724265322228497">"검색"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"모든 프린터"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"서비스 추가"</string>
diff --git a/packages/PrintSpooler/res/values-ky-rKG/strings.xml b/packages/PrintSpooler/res/values-ky-rKG/strings.xml
index f60f994..602f6605 100644
--- a/packages/PrintSpooler/res/values-ky-rKG/strings.xml
+++ b/packages/PrintSpooler/res/values-ky-rKG/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Бардык принтерлер…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Басуу баарлашуусу"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g> ичинен <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>-бет"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Корутунду, <xliff:g id="COPIES">%1$s</xliff:g> көчүрмө, барак өлчөмү <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Тутканы жаюу"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Тутканы жыйноо"</string>
+    <string name="print_button" msgid="645164566271246268">"Басуу"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF\'ке сактоо"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Басып чыгаруу параметрлери жайылды"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Басып чыгаруу параметрлери жыйналды"</string>
     <string name="search" msgid="5421724265322228497">"Издөө"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Бардык принтерлер"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Кызматты кошуу"</string>
diff --git a/packages/PrintSpooler/res/values-land/constants.xml b/packages/PrintSpooler/res/values-land/constants.xml
index a4666a5..84fc050 100644
--- a/packages/PrintSpooler/res/values-land/constants.xml
+++ b/packages/PrintSpooler/res/values-land/constants.xml
@@ -16,11 +16,7 @@
 
 <resources>
 
-    <dimen name="printer_list_view_padding_start">48dip</dimen>
-
-    <dimen name="printer_list_view_padding_end">48dip</dimen>
-
-    <integer name="preview_page_per_row_count">2</integer>
+    <integer name="preview_page_per_row_count">4</integer>
 
     <integer name="print_option_column_count">3</integer>
 
diff --git a/packages/PrintSpooler/res/values-lo-rLA/strings.xml b/packages/PrintSpooler/res/values-lo-rLA/strings.xml
index 555f92f..3a3f6bb 100644
--- a/packages/PrintSpooler/res/values-lo-rLA/strings.xml
+++ b/packages/PrintSpooler/res/values-lo-rLA/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"ທຸກເຄື່ອງພິມ..."</string>
     <string name="print_dialog" msgid="32628687461331979">"ໜ້າຕ່າງການພິມ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"ໜ້າທີ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> ​ຈາກ​ທັງ​ໝົດ <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"ສະ​ຫຼຸບ​, ສໍາ​ເນົາ <xliff:g id="COPIES">%1$s</xliff:g>, ຂະ​ຫນາດ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"​ຂະ​ຫຍາຍ​ໂຕ​ຈັດ​ການ"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ປິດ​ໂຕ​ຈັດ​ການ"</string>
+    <string name="print_button" msgid="645164566271246268">"ພິມ"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"ບັນທຶກເປັນ PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ຕົວ​ເລືອກ​ການ​ພິມຖືກ​ເປີດແລ້ວ"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ຕົວ​ເລືອກ​ການ​ພິມຖືກ​ປິດແລ້ວ"</string>
     <string name="search" msgid="5421724265322228497">"ຊອກຫາ"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"ທຸກເຄື່ອງພິມ"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"ເພີ່ມບໍລິການ"</string>
diff --git a/packages/PrintSpooler/res/values-lt/strings.xml b/packages/PrintSpooler/res/values-lt/strings.xml
index 51bcde3..6262a15 100644
--- a/packages/PrintSpooler/res/values-lt/strings.xml
+++ b/packages/PrintSpooler/res/values-lt/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Visi spausdintuvai…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Spausdinimo dialogo langas"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> psl. iš <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Suvestinė, kopijų: <xliff:g id="COPIES">%1$s</xliff:g>, popieriaus dydis: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Išskleidimo rankenėlė"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Sutraukimo rankenėlė"</string>
+    <string name="print_button" msgid="645164566271246268">"Spausdinti"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Išsaugoti kaip PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Spausdinimo parinktys išskleistos"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Spausdinimo parinktys sutrauktos"</string>
     <string name="search" msgid="5421724265322228497">"Ieškoti"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Visi spausdintuvai"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Pridėti paslaugą"</string>
diff --git a/packages/PrintSpooler/res/values-lv/strings.xml b/packages/PrintSpooler/res/values-lv/strings.xml
index 9cddeab..3a60ee5 100644
--- a/packages/PrintSpooler/res/values-lv/strings.xml
+++ b/packages/PrintSpooler/res/values-lv/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Visi printeri…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Drukāšanas dialoglodziņš"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>. no <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>. lapa no <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Kopsavilkums, kopiju skaits: <xliff:g id="COPIES">%1$s</xliff:g>, papīra izmērs: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Izvēršanas turis"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Sakļaušanas turis"</string>
+    <string name="print_button" msgid="645164566271246268">"Drukāt"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Saglabāt kā PDF failu"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Drukāšanas opcijas ir izvērstas."</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Drukāšanas opcijas ir sakļautas."</string>
     <string name="search" msgid="5421724265322228497">"Meklēt"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Visi printeri"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Pievienot pakalpojumu"</string>
diff --git a/packages/PrintSpooler/res/values-mk-rMK/strings.xml b/packages/PrintSpooler/res/values-mk-rMK/strings.xml
index eee7c6b..91b5763 100644
--- a/packages/PrintSpooler/res/values-mk-rMK/strings.xml
+++ b/packages/PrintSpooler/res/values-mk-rMK/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Сите печатачи..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Дијалог рамка Печати"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Страница <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> од <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Краток преглед, копии <xliff:g id="COPIES">%1$s</xliff:g>, големина на хартија <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Рачка за прикажување"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Рачка за сокривање"</string>
+    <string name="print_button" msgid="645164566271246268">"Печати"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Зачувај во PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Опциите на печатачот се прикажани"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Опциите на печатачот се сокриени"</string>
     <string name="search" msgid="5421724265322228497">"Пребарај"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Сите печатачи"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Додај услуга"</string>
diff --git a/packages/PrintSpooler/res/values-ml-rIN/strings.xml b/packages/PrintSpooler/res/values-ml-rIN/strings.xml
index 9093af1..a06ca7d 100644
--- a/packages/PrintSpooler/res/values-ml-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-ml-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"എല്ലാ പ്രിന്ററുകളും..."</string>
     <string name="print_dialog" msgid="32628687461331979">"പ്രിന്റ് സംഭാഷണം"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g> പേജ്"</string>
+    <string name="summary_template" msgid="8899734908625669193">"സംഗ്രഹം, പകർപ്പുകൾ <xliff:g id="COPIES">%1$s</xliff:g>, പേപ്പർ വലുപ്പം <xliff:g id="PAPER_SIZE">%2$s</xliff:g> എന്നിവ"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"വിപുലീകരണം കൈകാര്യം ചെയ്യുക"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ചുരുക്കുന്നത് കൈകാര്യം ചെയ്യുക"</string>
+    <string name="print_button" msgid="645164566271246268">"പ്രിന്റുചെയ്യുക"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF-ൽ സംരക്ഷിക്കുക"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"പ്രിന്റ് ചെയ്യാനുള്ള ഓപ്‌ഷനുകൾ വിപുലീകരിച്ചു"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"പ്രിന്റ് ചെയ്യാനുള്ള ഓപ്‌ഷനുകൾ ചുരുക്കി"</string>
     <string name="search" msgid="5421724265322228497">"തിരയൽ"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"എല്ലാ പ്രിന്ററുകളും"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"സേവനം ചേർക്കുക"</string>
diff --git a/packages/PrintSpooler/res/values-mn-rMN/strings.xml b/packages/PrintSpooler/res/values-mn-rMN/strings.xml
index 5239ff5..022adda 100644
--- a/packages/PrintSpooler/res/values-mn-rMN/strings.xml
+++ b/packages/PrintSpooler/res/values-mn-rMN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Бүх принтерүүд…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Хэвлэх диалоги"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g>-с <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> хуудас"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Дүгнэлт, <xliff:g id="COPIES">%1$s</xliff:g> хувь, цаасны хэмжээ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Бариулыг дэлгэх"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Бариулыг хумих"</string>
+    <string name="print_button" msgid="645164566271246268">"Хэвлэх"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF-т хадгалах"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Хэвлэх тохируулгыг дэлгэсэн"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Хэвлэх тохируулгыг хумисан"</string>
     <string name="search" msgid="5421724265322228497">"Хайх"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Бүх принтерүүд"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Үйлчилгээ нэмэх"</string>
diff --git a/packages/PrintSpooler/res/values-mr-rIN/strings.xml b/packages/PrintSpooler/res/values-mr-rIN/strings.xml
index 6afe957..1fade66 100644
--- a/packages/PrintSpooler/res/values-mr-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-mr-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"सर्व प्रिंटर..."</string>
     <string name="print_dialog" msgid="32628687461331979">"मुद्रण संवाद"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g> पैकी <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> पृष्‍ठ"</string>
+    <string name="summary_template" msgid="8899734908625669193">"सारांश, प्रती <xliff:g id="COPIES">%1$s</xliff:g>, कागद आकार <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"विस्तृत करण्याचे हँडल"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"संक्षिप्त करण्याचे हँडल"</string>
+    <string name="print_button" msgid="645164566271246268">"मुद्रण करा"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF वर जतन करा"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"मुद्रण पर्याय विस्तृत झाले"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"मुद्रण पर्याय संक्षिप्त झाले"</string>
     <string name="search" msgid="5421724265322228497">"शोध"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"सर्व प्रिंटर"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"सेवा जोडा"</string>
diff --git a/packages/PrintSpooler/res/values-ms-rMY/strings.xml b/packages/PrintSpooler/res/values-ms-rMY/strings.xml
index f327334..a392b76 100644
--- a/packages/PrintSpooler/res/values-ms-rMY/strings.xml
+++ b/packages/PrintSpooler/res/values-ms-rMY/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Semua pencetak..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Dialog cetakan"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Halaman <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> daripada <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Ringkasan, salinan <xliff:g id="COPIES">%1$s</xliff:g>, saiz kertas <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Pemegang untuk mengembangkan"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Pemegang untuk meruntuhkan"</string>
+    <string name="print_button" msgid="645164566271246268">"Cetak"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Simpan ke PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Pilihan cetakan dikembangkan"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Pilihan cetakan diruntuhkan"</string>
     <string name="search" msgid="5421724265322228497">"Cari"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Semua pencetak"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Tambahkan perkhidmatan"</string>
diff --git a/packages/PrintSpooler/res/values-my-rMM/strings.xml b/packages/PrintSpooler/res/values-my-rMM/strings.xml
index 8d0320e..d6eb380 100644
--- a/packages/PrintSpooler/res/values-my-rMM/strings.xml
+++ b/packages/PrintSpooler/res/values-my-rMM/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"စာထုတ်စက် အားလုံး"</string>
     <string name="print_dialog" msgid="32628687461331979">"စာထုတ်ရန် အချက်ပြခြင်း"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g>ထဲက စာမျက်နှာ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"အကျဉ်းချုပ်၊ ကော်ပီများ<xliff:g id="COPIES">%1$s</xliff:g>၊ စက္ကူ ဆိုက် <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ချဲ့ရန် လက်"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ခေါက်ရန် လက်"</string>
+    <string name="print_button" msgid="645164566271246268">"စာထုတ်ရန်"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF သို့ သိမ်းဆည်းခဲ့"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ပရင့်ထုတ် ရွေးစရာများကို ချဲ့ထား"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ပရင့်ထုတ် ရွေးစရာများကို ခေါက်ထား"</string>
     <string name="search" msgid="5421724265322228497">"ရှာဖွေခြင်း"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"စာထုတ်စက် အားလုံး"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"ဆားဗစ် အသစ်ထည့်ရန်"</string>
@@ -77,5 +85,5 @@
     <string name="print_error_default_message" msgid="8602678405502922346">"ဆော်ရီး၊ အဲဒါ အလုပ်မဖြစ်ခဲ့ပါ။ ထပ် စမ်းပါ။"</string>
     <string name="print_error_retry" msgid="1426421728784259538">"ထပ်စမ်း"</string>
     <string name="print_error_printer_unavailable" msgid="8985614415253203381">"ဒီပရင်တာမှာ ယခုအချိန်မှာ မရနိုင်ပါ။"</string>
-    <string name="print_preparing_preview" msgid="3939930735671364712">"အစမ်းကြည့်ရန် ပြင်ဆင်နေ…"</string>
+    <string name="print_preparing_preview" msgid="3939930735671364712">"အစမ်းကြည့်ရန် ပြင်ဆင်နေ…"</string>
 </resources>
diff --git a/packages/PrintSpooler/res/values-nb/strings.xml b/packages/PrintSpooler/res/values-nb/strings.xml
index 2380a2c..bf11068 100644
--- a/packages/PrintSpooler/res/values-nb/strings.xml
+++ b/packages/PrintSpooler/res/values-nb/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alle skrivere"</string>
     <string name="print_dialog" msgid="32628687461331979">"Skriv ut dialog"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Side <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> av <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Oppsummering, <xliff:g id="COPIES">%1$s</xliff:g> kopier, papirstørrelse <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Håndtaket for å utvide"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Håndtaket for å skjule"</string>
+    <string name="print_button" msgid="645164566271246268">"Skriv ut"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Lagre som PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Skriveralternativene er utvidet"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Skriveralternativene er skjult"</string>
     <string name="search" msgid="5421724265322228497">"Søk"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alle skrivere"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Legg til tjeneste"</string>
diff --git a/packages/PrintSpooler/res/values-ne-rNP/strings.xml b/packages/PrintSpooler/res/values-ne-rNP/strings.xml
index 110f698..eb97530 100644
--- a/packages/PrintSpooler/res/values-ne-rNP/strings.xml
+++ b/packages/PrintSpooler/res/values-ne-rNP/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"सबै प्रिन्टरहरू..."</string>
     <string name="print_dialog" msgid="32628687461331979">"सम्वाद छाप्नुहोस्"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g> को <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> पृष्ठ"</string>
+    <string name="summary_template" msgid="8899734908625669193">"सारांश, प्रतिहरू <xliff:g id="COPIES">%1$s</xliff:g> , कागज आकार <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ह्यान्डल विस्तार गर्नुहोस्"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ह्यान्डल कोल्याप्स गर्नुहोस्"</string>
+    <string name="print_button" msgid="645164566271246268">"प्रिन्ट गर्नुहोस्"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF सुरक्षित गर्नुहोस्"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"विस्तार गरेका विकल्पहरू प्रिन्ट गर्नुहोस्"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"कोल्याप्स गरेका विकल्पहरू प्रिन्ट गर्नुहोस्"</string>
     <string name="search" msgid="5421724265322228497">"खोज्नुहोस्"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"सबै प्रिन्टरहरू"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"सेवा थप्नुहोस्"</string>
diff --git a/packages/PrintSpooler/res/values-nl/strings.xml b/packages/PrintSpooler/res/values-nl/strings.xml
index ca3654f..5ea52a0 100644
--- a/packages/PrintSpooler/res/values-nl/strings.xml
+++ b/packages/PrintSpooler/res/values-nl/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alle printers…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Afdrukdialoogvenster"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Pagina <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> van <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Overzicht, <xliff:g id="COPIES">%1$s</xliff:g> exemplaren, papierformaat <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Handgreep voor uitvouwen"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Handgreep voor samenvouwen"</string>
+    <string name="print_button" msgid="645164566271246268">"Afdrukken"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Opslaan naar pdf"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Afdrukopties uitgevouwen"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Afdrukopties samengevouwen"</string>
     <string name="search" msgid="5421724265322228497">"Zoeken"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alle printers"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Service toevoegen"</string>
diff --git a/packages/PrintSpooler/res/values-pl/strings.xml b/packages/PrintSpooler/res/values-pl/strings.xml
index 6835428..609e6e9 100644
--- a/packages/PrintSpooler/res/values-pl/strings.xml
+++ b/packages/PrintSpooler/res/values-pl/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Wszystkie drukarki…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Okno drukowania"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Strona <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> z <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Posumowanie, liczba kopii <xliff:g id="COPIES">%1$s</xliff:g>, rozmiar papieru <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Uchwyt rozwijający"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Uchwyt zwijający"</string>
+    <string name="print_button" msgid="645164566271246268">"Drukuj"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Zapisz jako PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opcje wydruku są rozwinięte"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opcje wydruku są zwinięte"</string>
     <string name="search" msgid="5421724265322228497">"Szukaj"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Wszystkie drukarki"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Dodaj usługę"</string>
diff --git a/packages/PrintSpooler/res/values-pt-rPT/strings.xml b/packages/PrintSpooler/res/values-pt-rPT/strings.xml
index ec6d162..7b47f4c 100644
--- a/packages/PrintSpooler/res/values-pt-rPT/strings.xml
+++ b/packages/PrintSpooler/res/values-pt-rPT/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Todas as impressoras..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Caixa de diálogo de impressão"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Página <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resumo, <xliff:g id="COPIES">%1$s</xliff:g> cópias, tamanho do papel <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Expandir alça"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Fechar alça"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimir"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Guardar como PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opções de impressão expandidas"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opções de impressão fechadas"</string>
     <string name="search" msgid="5421724265322228497">"Pesquisar"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Todas as impressoras"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Adicionar serviço"</string>
diff --git a/packages/PrintSpooler/res/values-pt/strings.xml b/packages/PrintSpooler/res/values-pt/strings.xml
index 8ef07a8..b2541df 100644
--- a/packages/PrintSpooler/res/values-pt/strings.xml
+++ b/packages/PrintSpooler/res/values-pt/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Todas as impressoras…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Diálogo de impressão"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Página <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> de <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Resumo, cópias <xliff:g id="COPIES">%1$s</xliff:g>, tamanho do papel <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Expandir alça"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Recolher alça"</string>
+    <string name="print_button" msgid="645164566271246268">"Imprimir"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Salvar como PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opções de impressão expandidas"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opções de impressão recolhidas"</string>
     <string name="search" msgid="5421724265322228497">"Pesquisar"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Todas as impressoras"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Adicionar serviço"</string>
diff --git a/packages/PrintSpooler/res/values-ro/strings.xml b/packages/PrintSpooler/res/values-ro/strings.xml
index 64e1dc9..1446a53 100644
--- a/packages/PrintSpooler/res/values-ro/strings.xml
+++ b/packages/PrintSpooler/res/values-ro/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Toate imprimantele..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Caseta de dialog de printare"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Pagina <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> din <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Rezumat, copii <xliff:g id="COPIES">%1$s</xliff:g>, dimensiunea paginii <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Ghidaj de extindere"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Ghidaj de restrângere"</string>
+    <string name="print_button" msgid="645164566271246268">"Printați"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Salvați în format PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Opțiuni de printare extinse"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Opțiuni de printare restrânse"</string>
     <string name="search" msgid="5421724265322228497">"Căutați"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Toate imprimantele"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Adăugați un serviciu"</string>
diff --git a/packages/PrintSpooler/res/values-ru/strings.xml b/packages/PrintSpooler/res/values-ru/strings.xml
index 6abc571..c2a19bb 100644
--- a/packages/PrintSpooler/res/values-ru/strings.xml
+++ b/packages/PrintSpooler/res/values-ru/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Все принтеры"</string>
     <string name="print_dialog" msgid="32628687461331979">"Диалоговое окно печати"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Страница <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>. Всего: <xliff:g id="PAGE_COUNT">%2$d</xliff:g>."</string>
+    <string name="summary_template" msgid="8899734908625669193">"Общие сведения. Количество копий: <xliff:g id="COPIES">%1$s</xliff:g>. Размер бумаги: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>."</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Развернуть."</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Свернуть."</string>
+    <string name="print_button" msgid="645164566271246268">"Печать"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Сохранить в формате PDF."</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Параметры печати показаны."</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Параметры печати скрыты."</string>
     <string name="search" msgid="5421724265322228497">"Поиск"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Все принтеры"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Добавить службу печати"</string>
diff --git a/packages/PrintSpooler/res/values-si-rLK/strings.xml b/packages/PrintSpooler/res/values-si-rLK/strings.xml
index f6cc5e2..386ce8d 100644
--- a/packages/PrintSpooler/res/values-si-rLK/strings.xml
+++ b/packages/PrintSpooler/res/values-si-rLK/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"සියලු මුද්‍රණ යන්ත්‍ර…"</string>
     <string name="print_dialog" msgid="32628687461331979">"මුද්‍රණ සංවාද කොටුව"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"පිටු <xliff:g id="PAGE_COUNT">%2$d</xliff:g> න් <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"සාරාංශය, පිටපත් <xliff:g id="COPIES">%1$s</xliff:g>, පිටුවේ ප්‍රමණය <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"විහිදන මිට"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"හකුළන මිට"</string>
+    <string name="print_button" msgid="645164566271246268">"මුද්‍රණය කරන්න"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF වෙත සුරකින්න"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"විහිදන ලද විකල්ප මුද්‍රණය කරන්න"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"හකුළන ලද විකල්ප මුද්‍රණය කරන්න"</string>
     <string name="search" msgid="5421724265322228497">"සෙවීම"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"සියලු මුද්‍රණ යන්ත්‍ර"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"සේවාව එක් කිරීම"</string>
diff --git a/packages/PrintSpooler/res/values-sk/strings.xml b/packages/PrintSpooler/res/values-sk/strings.xml
index 439aae4..5be2034 100644
--- a/packages/PrintSpooler/res/values-sk/strings.xml
+++ b/packages/PrintSpooler/res/values-sk/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Všetky tlačiarne..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Dialógové okno tlače"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Stránka <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> z <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Súhrn, počet kópií: <xliff:g id="COPIES">%1$s</xliff:g>, veľkosť papiera: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Obslužný nástroj na rozbalenie"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Obslužný nástroj na zbalenie"</string>
+    <string name="print_button" msgid="645164566271246268">"Tlačiť"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Uložiť do súboru PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Možnosti tlače sú rozbalené"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Možnosti tlače sú zbalené"</string>
     <string name="search" msgid="5421724265322228497">"VYHĽADÁVANIE"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Všetky tlačiarne"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Pridať službu"</string>
diff --git a/packages/PrintSpooler/res/values-sl/strings.xml b/packages/PrintSpooler/res/values-sl/strings.xml
index c991444..ee15103 100644
--- a/packages/PrintSpooler/res/values-sl/strings.xml
+++ b/packages/PrintSpooler/res/values-sl/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Vsi tiskalniki …"</string>
     <string name="print_dialog" msgid="32628687461331979">"Pogovorno okno za tiskanje"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Stran <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> od <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Povzetek, št. kopij <xliff:g id="COPIES">%1$s</xliff:g>, velikost papirja <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Ročica za razširitev"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Ročica za strnitev"</string>
+    <string name="print_button" msgid="645164566271246268">"Natisni"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Shrani v PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Možnosti tiskanja razširjene"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Možnosti tiskanja strnjene"</string>
     <string name="search" msgid="5421724265322228497">"Iskanje"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Vsi tiskalniki"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Dodaj storitev"</string>
diff --git a/packages/PrintSpooler/res/values-sr/strings.xml b/packages/PrintSpooler/res/values-sr/strings.xml
index de0dfac..6ca94aa 100644
--- a/packages/PrintSpooler/res/values-sr/strings.xml
+++ b/packages/PrintSpooler/res/values-sr/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Сви штампачи…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Дијалог за штампање"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>. страница од <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Резиме, копије (<xliff:g id="COPIES">%1$s</xliff:g>), величина папира <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Регулатор за ширење"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Регулатор за скупљање"</string>
+    <string name="print_button" msgid="645164566271246268">"Штампај"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Сачувај у PDF-у"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Опције штампања су проширене"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Опције штампања су скупљене"</string>
     <string name="search" msgid="5421724265322228497">"Претражи"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Сви штампачи"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Додај услугу"</string>
diff --git a/packages/PrintSpooler/res/values-sv/strings.xml b/packages/PrintSpooler/res/values-sv/strings.xml
index 8a0ef60..4c439be 100644
--- a/packages/PrintSpooler/res/values-sv/strings.xml
+++ b/packages/PrintSpooler/res/values-sv/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Alla skrivare ..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Dialogrutan Skriv ut"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Sidan <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> av <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Sammanfattning, antal kopior <xliff:g id="COPIES">%1$s</xliff:g>, pappersformat <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Handtag som expanderar utskriftsalternativen"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Handtag som komprimerar utskriftsalternativen"</string>
+    <string name="print_button" msgid="645164566271246268">"Skriv ut"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Spara som PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Utskriftsalternativen har expanderats"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Utskriftsalternativen har komprimerats"</string>
     <string name="search" msgid="5421724265322228497">"Sök"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Alla skrivare"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Lägg till tjänst"</string>
diff --git a/packages/PrintSpooler/res/values-sw/strings.xml b/packages/PrintSpooler/res/values-sw/strings.xml
index 0116b67..e454704 100644
--- a/packages/PrintSpooler/res/values-sw/strings.xml
+++ b/packages/PrintSpooler/res/values-sw/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Printa zote..."</string>
     <string name="print_dialog" msgid="32628687461331979">"Chapisha mazungumzo"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Ukurasa wa <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> kati ya <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Muhtasari, nakala <xliff:g id="COPIES">%1$s</xliff:g>, ukubwa wa karatasi <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Panua kishikio"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Kunja kishikio"</string>
+    <string name="print_button" msgid="645164566271246268">"Chapisha"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Hifadhi kwenye PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Chaguo za kuchapisha zimepanuliwa"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Chaguo za kuchapisha zimekunjwa"</string>
     <string name="search" msgid="5421724265322228497">"Tafuta"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Printa zote"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Ongeza huduma"</string>
diff --git a/packages/PrintSpooler/res/values-sw600dp-land/constants.xml b/packages/PrintSpooler/res/values-sw600dp-land/constants.xml
index f60d8e4..f7f8a18 100644
--- a/packages/PrintSpooler/res/values-sw600dp-land/constants.xml
+++ b/packages/PrintSpooler/res/values-sw600dp-land/constants.xml
@@ -17,6 +17,9 @@
 <resources>
 
     <integer name="print_option_column_count">6</integer>
+
     <integer name="preview_page_per_row_count">4</integer>
 
+    <dimen name="preview_destination_spinner_width">256dip</dimen>
+
 </resources>
diff --git a/packages/PrintSpooler/res/values-ta-rIN/strings.xml b/packages/PrintSpooler/res/values-ta-rIN/strings.xml
index 39eead8..0421bd6 100644
--- a/packages/PrintSpooler/res/values-ta-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-ta-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"எல்லா அச்சுப்பொறிகளும்…"</string>
     <string name="print_dialog" msgid="32628687461331979">"அச்சிடல் செய்தி"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"பக்கம்: <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"சுருக்கம், நகல்கள் <xliff:g id="COPIES">%1$s</xliff:g>, தாள் அளவு <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ஹேண்டிலை விரிவாக்கு"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ஹேண்டிலைச் சுருக்கு"</string>
+    <string name="print_button" msgid="645164566271246268">"அச்சிடு"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF ஆகச் சேமி"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"அச்சு விருப்பங்கள் விரிவாக்கப்பட்டன"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"அச்சு விருப்பங்கள் சுருக்கப்பட்டன"</string>
     <string name="search" msgid="5421724265322228497">"தேடு"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"எல்லா அச்சுப்பொறிகளும்"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"சேவையைச் சேர்"</string>
diff --git a/packages/PrintSpooler/res/values-te-rIN/strings.xml b/packages/PrintSpooler/res/values-te-rIN/strings.xml
index 3ad4d1d..edb6e60 100644
--- a/packages/PrintSpooler/res/values-te-rIN/strings.xml
+++ b/packages/PrintSpooler/res/values-te-rIN/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"అన్ని ప్రింటర్‌లు…"</string>
     <string name="print_dialog" msgid="32628687461331979">"ముద్రణ డైలాగ్"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"<xliff:g id="PAGE_COUNT">%2$d</xliff:g>లో <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>వ పేజీ"</string>
+    <string name="summary_template" msgid="8899734908625669193">"సారాంశం, కాపీలు <xliff:g id="COPIES">%1$s</xliff:g>, కాగితం పరిమాణం <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"విస్తరణ హ్యాండిల్"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"కుదింపు హ్యాండిల్"</string>
+    <string name="print_button" msgid="645164566271246268">"ముద్రించు"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF వలె సేవ్ చేయి"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ముద్రణ ఎంపికలు విస్తరించబడ్డాయి"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ముద్రణ ఎంపికలు కుదించబడ్డాయి"</string>
     <string name="search" msgid="5421724265322228497">"శోధించు"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"అన్ని ప్రింటర్‌లు"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"సేవను జోడించు"</string>
diff --git a/packages/PrintSpooler/res/values-th/strings.xml b/packages/PrintSpooler/res/values-th/strings.xml
index d1d45fe..cfffa0b 100644
--- a/packages/PrintSpooler/res/values-th/strings.xml
+++ b/packages/PrintSpooler/res/values-th/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"เครื่องพิมพ์ทั้งหมด…"</string>
     <string name="print_dialog" msgid="32628687461331979">"ช่องโต้ตอบการพิมพ์"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"หน้า <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> จาก <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"สรุป สำเนา <xliff:g id="COPIES">%1$s</xliff:g>, ขนาดกระดาษ <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"ปุ่มขยาย"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"ปุ่มยุบ"</string>
+    <string name="print_button" msgid="645164566271246268">"พิมพ์"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"บันทึกไปยัง PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"ขยายตัวเลือกการพิมพ์แล้ว"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"ยุบตัวเลือกการพิมพ์แล้ว"</string>
     <string name="search" msgid="5421724265322228497">"ค้นหา"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"เครื่องพิมพ์ทั้งหมด"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"เพิ่มบริการ"</string>
diff --git a/packages/PrintSpooler/res/values-tl/strings.xml b/packages/PrintSpooler/res/values-tl/strings.xml
index 70365e7..dfb0450 100644
--- a/packages/PrintSpooler/res/values-tl/strings.xml
+++ b/packages/PrintSpooler/res/values-tl/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Lahat ng printer…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Dialog ng pag-print"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Page <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> ng <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Buod, mga kopya <xliff:g id="COPIES">%1$s</xliff:g>, laki ng papel <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Palakihin ang handle"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Paliitin ang handle"</string>
+    <string name="print_button" msgid="645164566271246268">"I-print"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"I-save sa PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Pinalaki ang mga opsyon sa pag-print"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Pinaliit ang mga opsyon sa pag-print"</string>
     <string name="search" msgid="5421724265322228497">"Hanapin"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Lahat ng printer"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Magdagdag ng serbisyo"</string>
diff --git a/packages/PrintSpooler/res/values-tr/strings.xml b/packages/PrintSpooler/res/values-tr/strings.xml
index ea803f65..50befba 100644
--- a/packages/PrintSpooler/res/values-tr/strings.xml
+++ b/packages/PrintSpooler/res/values-tr/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Tüm yazıcılar…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Yazdırma iletişim kutusu"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Sayfa <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Özet. Kopya sayısı: <xliff:g id="COPIES">%1$s</xliff:g>, kağıt boyutu: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Genişletme tutacağı"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Daraltma tutacağı"</string>
+    <string name="print_button" msgid="645164566271246268">"Yazdır"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF\'ye kaydet"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Yazdırma seçenekleri genişletildi"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Yazdırma seçenekleri daraltıldı"</string>
     <string name="search" msgid="5421724265322228497">"Ara"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Tüm yazıcılar"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Hizmet ekle"</string>
diff --git a/packages/PrintSpooler/res/values-uk/strings.xml b/packages/PrintSpooler/res/values-uk/strings.xml
index 09af096..8a924e6 100644
--- a/packages/PrintSpooler/res/values-uk/strings.xml
+++ b/packages/PrintSpooler/res/values-uk/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Усі принтери…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Діалогове вікно друку"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> з <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Сторінка <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> з <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Підсумок – копій: <xliff:g id="COPIES">%1$s</xliff:g>, розмір паперу: <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Кнопка розгортання"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Кнопка згортання"</string>
+    <string name="print_button" msgid="645164566271246268">"Друк"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Зберегти у форматі PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Параметри друку розгорнуто"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Параметри друку згорнуто"</string>
     <string name="search" msgid="5421724265322228497">"Пошук"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Усі принтери"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Додати службу"</string>
diff --git a/packages/PrintSpooler/res/values-ur-rPK/strings.xml b/packages/PrintSpooler/res/values-ur-rPK/strings.xml
index 1ff57a7..722d027 100644
--- a/packages/PrintSpooler/res/values-ur-rPK/strings.xml
+++ b/packages/PrintSpooler/res/values-ur-rPK/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"سبھی پرنٹرز…"</string>
     <string name="print_dialog" msgid="32628687461331979">"پرنٹ ڈائلاگ"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"صفحہ <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> از <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"خلاصہ، کاپیاں <xliff:g id="COPIES">%1$s</xliff:g>، کاغذ کا سائز <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"پھیلانے والا ہینڈل"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"سکیڑنے والا ہینڈل"</string>
+    <string name="print_button" msgid="645164566271246268">"پرنٹ کریں"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"‏PDF میں محفوظ کریں"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"پرنٹ کے اختیارات پھیلا دیے گئے"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"پرنٹ کے اختیارات سکیڑ دیے گئے"</string>
     <string name="search" msgid="5421724265322228497">"تلاش کریں"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"سبھی پرنٹرز"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"سروس شامل کریں"</string>
diff --git a/packages/PrintSpooler/res/values-uz-rUZ/strings.xml b/packages/PrintSpooler/res/values-uz-rUZ/strings.xml
index 8ab3410..f62728f 100644
--- a/packages/PrintSpooler/res/values-uz-rUZ/strings.xml
+++ b/packages/PrintSpooler/res/values-uz-rUZ/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Barcha printerlar…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Chop etish oynasi"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Sahifa: <xliff:g id="CURRENT_PAGE">%1$d</xliff:g>/<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Xulosa: nusxalar soni – <xliff:g id="COPIES">%1$s</xliff:g>, qog‘oz o‘lchami – <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Dastakni yoyish"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Dastakni yig‘ish"</string>
+    <string name="print_button" msgid="645164566271246268">"Chop etish"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"PDF sifatida saqlash"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Chop qilish tanlamalari yoyildi"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Chop qilish tanlamalari yig‘ildi"</string>
     <string name="search" msgid="5421724265322228497">"Izlash"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Barcha printerlar"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Xizmat qo‘shish"</string>
diff --git a/packages/PrintSpooler/res/values-vi/strings.xml b/packages/PrintSpooler/res/values-vi/strings.xml
index 4c0e6c9..fa0d26e 100644
--- a/packages/PrintSpooler/res/values-vi/strings.xml
+++ b/packages/PrintSpooler/res/values-vi/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Tất cả máy in…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Hộp thoại in"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Trang <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Tóm tắt, số bản sao <xliff:g id="COPIES">%1$s</xliff:g>, khổ giấy <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Mở rộng điều khiển"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Thu gọn điều khiển"</string>
+    <string name="print_button" msgid="645164566271246268">"In"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Lưu ở dạng PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Đã mở rộng các tùy chọn in"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Đã thu gọn các tùy chọn in"</string>
     <string name="search" msgid="5421724265322228497">"Tìm kiếm"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Tất cả máy in"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Thêm dịch vụ"</string>
diff --git a/packages/PrintSpooler/res/values-zh-rCN/strings.xml b/packages/PrintSpooler/res/values-zh-rCN/strings.xml
index 4718dc1..77ecb21 100644
--- a/packages/PrintSpooler/res/values-zh-rCN/strings.xml
+++ b/packages/PrintSpooler/res/values-zh-rCN/strings.xml
@@ -25,12 +25,9 @@
     <string name="label_paper_size_summary" msgid="5668204981332138168">"纸张尺寸:"</string>
     <string name="label_color" msgid="1108690305218188969">"颜色"</string>
     <string name="label_orientation" msgid="2853142581990496477">"方向"</string>
-    <!-- no translation found for label_pages (7768589729282182230) -->
-    <skip />
-    <!-- no translation found for template_all_pages (3322235982020148762) -->
-    <skip />
-    <!-- no translation found for template_page_range (428638530038286328) -->
-    <skip />
+    <string name="label_pages" msgid="7768589729282182230">"页数"</string>
+    <string name="template_all_pages" msgid="3322235982020148762">"全部<xliff:g id="PAGE_COUNT">%1$s</xliff:g>页"</string>
+    <string name="template_page_range" msgid="428638530038286328">"<xliff:g id="PAGE_COUNT">%1$s</xliff:g>页"</string>
     <string name="pages_range_example" msgid="8558694453556945172">"例如:1-5、8、11-13"</string>
     <string name="print_preview" msgid="8010217796057763343">"打印预览"</string>
     <string name="install_for_print_preview" msgid="6366303997385509332">"安装 PDF 查看器以便预览"</string>
@@ -40,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"所有打印机…"</string>
     <string name="print_dialog" msgid="32628687461331979">"打印对话框"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> / <xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"第<xliff:g id="CURRENT_PAGE">%1$d</xliff:g>页,共<xliff:g id="PAGE_COUNT">%2$d</xliff:g>页"</string>
+    <string name="summary_template" msgid="8899734908625669193">"摘要,<xliff:g id="COPIES">%1$s</xliff:g>份,纸张尺寸为<xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"展开手柄"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"收起手柄"</string>
+    <string name="print_button" msgid="645164566271246268">"打印"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"保存为PDF格式"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"已展开打印选项"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"已收起打印选项"</string>
     <string name="search" msgid="5421724265322228497">"搜索"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"所有打印机"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"添加服务"</string>
diff --git a/packages/PrintSpooler/res/values-zh-rHK/strings.xml b/packages/PrintSpooler/res/values-zh-rHK/strings.xml
index 9450d05..d2fa629 100644
--- a/packages/PrintSpooler/res/values-zh-rHK/strings.xml
+++ b/packages/PrintSpooler/res/values-zh-rHK/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"所有打印機…"</string>
     <string name="print_dialog" msgid="32628687461331979">"列印對話方塊"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"第 <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> 頁,共 <xliff:g id="PAGE_COUNT">%2$d</xliff:g> 頁"</string>
+    <string name="summary_template" msgid="8899734908625669193">"摘要,<xliff:g id="COPIES">%1$s</xliff:g> 份,<xliff:g id="PAPER_SIZE">%2$s</xliff:g> 紙張大小"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"展開控點"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"收合控點"</string>
+    <string name="print_button" msgid="645164566271246268">"列印"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"儲存為 PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"列印選項已展開"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"列印選項已收合"</string>
     <string name="search" msgid="5421724265322228497">"搜尋"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"所有打印機"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"新增服務"</string>
diff --git a/packages/PrintSpooler/res/values-zh-rTW/strings.xml b/packages/PrintSpooler/res/values-zh-rTW/strings.xml
index cf452c9..3e26a5e 100644
--- a/packages/PrintSpooler/res/values-zh-rTW/strings.xml
+++ b/packages/PrintSpooler/res/values-zh-rTW/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"所有印表機…"</string>
     <string name="print_dialog" msgid="32628687461331979">"印表機對話方塊"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"第 <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> 頁,共 <xliff:g id="PAGE_COUNT">%2$d</xliff:g> 頁"</string>
+    <string name="summary_template" msgid="8899734908625669193">"摘要,<xliff:g id="COPIES">%1$s</xliff:g> 份,紙張為 <xliff:g id="PAPER_SIZE">%2$s</xliff:g> 大小"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"展開控點"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"收合控點"</string>
+    <string name="print_button" msgid="645164566271246268">"列印"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"儲存為 PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"列印選項已展開"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"列印選項已收合"</string>
     <string name="search" msgid="5421724265322228497">"搜尋"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"所有印表機"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"新增服務"</string>
diff --git a/packages/PrintSpooler/res/values-zu/strings.xml b/packages/PrintSpooler/res/values-zu/strings.xml
index 1e08d8c..f8a27bc 100644
--- a/packages/PrintSpooler/res/values-zu/strings.xml
+++ b/packages/PrintSpooler/res/values-zu/strings.xml
@@ -37,6 +37,14 @@
     <string name="all_printers" msgid="5018829726861876202">"Wonke amaphrinta…"</string>
     <string name="print_dialog" msgid="32628687461331979">"Ingxoxo yokuphrinta"</string>
     <string name="current_page_template" msgid="1386638343571771292">"<xliff:g id="CURRENT_PAGE">%1$d</xliff:g> /<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="page_description_template" msgid="6831239682256197161">"Ikhasi <xliff:g id="CURRENT_PAGE">%1$d</xliff:g> kwangu-<xliff:g id="PAGE_COUNT">%2$d</xliff:g>"</string>
+    <string name="summary_template" msgid="8899734908625669193">"Isifinyezo, amakholi <xliff:g id="COPIES">%1$s</xliff:g>, usayisi wekhasi <xliff:g id="PAPER_SIZE">%2$s</xliff:g>"</string>
+    <string name="expand_handle" msgid="7282974448109280522">"Nwebisa isibambi"</string>
+    <string name="collapse_handle" msgid="6886637989442507451">"Yephula isibambi"</string>
+    <string name="print_button" msgid="645164566271246268">"Phrinta"</string>
+    <string name="savetopdf_button" msgid="2976186791686924743">"Londoloza ku-PDF"</string>
+    <string name="print_options_expanded" msgid="6944679157471691859">"Izinketho zokuphrinta zinwetshiwe"</string>
+    <string name="print_options_collapsed" msgid="7455930445670414332">"Izinketho zokuphrinta zephuliwe"</string>
     <string name="search" msgid="5421724265322228497">"Sesha"</string>
     <string name="all_printers_label" msgid="3178848870161526399">"Wonke amaphrinta"</string>
     <string name="add_print_service_label" msgid="5356702546188981940">"Engeza isevisi"</string>
diff --git a/packages/PrintSpooler/res/values/colors.xml b/packages/PrintSpooler/res/values/colors.xml
index de74a41..d1bec32 100644
--- a/packages/PrintSpooler/res/values/colors.xml
+++ b/packages/PrintSpooler/res/values/colors.xml
@@ -24,4 +24,6 @@
 
     <color name="promoted_action_background_color">#FF80CBC4</color>
 
+    <color name="material_grey_500">#ffa3a3a3</color>
+
 </resources>
diff --git a/packages/PrintSpooler/res/values/constants.xml b/packages/PrintSpooler/res/values/constants.xml
index b95703b..357d3e1 100644
--- a/packages/PrintSpooler/res/values/constants.xml
+++ b/packages/PrintSpooler/res/values/constants.xml
@@ -28,9 +28,6 @@
 
     <dimen name="print_dialog_frame_max_width_dip">400dip</dimen>
 
-    <dimen name="printer_list_view_padding_start">16dip</dimen>
-    <dimen name="printer_list_view_padding_end">16dip</dimen>
-
     <dimen name="selected_page_elevation">6dip</dimen>
     <dimen name="unselected_page_elevation">2dip</dimen>
 
@@ -46,6 +43,8 @@
     <fraction name="page_unselected_alpha">50%</fraction>
 
     <dimen name="preview_page_footer_height">32dip</dimen>
-    <dimen name="preview_page_min_width">130dip</dimen>
+    <dimen name="preview_page_min_width">128dip</dimen>
+
+    <dimen name="preview_destination_spinner_width">192dip</dimen>
 
 </resources>
diff --git a/packages/PrintSpooler/res/values/strings.xml b/packages/PrintSpooler/res/values/strings.xml
index 5b7fda3..ab633ea 100644
--- a/packages/PrintSpooler/res/values/strings.xml
+++ b/packages/PrintSpooler/res/values/strings.xml
@@ -76,11 +76,36 @@
     <!-- Title for the print dialog announced to the user for accessibility. Not shown in the UI. [CHAR LIMIT=none] -->
     <string name="print_dialog">Print dialog</string>
 
-
-    <!-- Template for the message that shows the current page out of the total number of pages -->
+    <!-- Template for the message that shows the current page out of the total number of pages [CHAR LIMIT=none] -->
     <string name="current_page_template"><xliff:g id="current_page">%1$d</xliff:g>
         /<xliff:g id="page_count">%2$d</xliff:g></string>
 
+    <!-- Description of the current page - spoken to the user [CHAR LIMIT=none] -->
+    <string name="page_description_template">Page <xliff:g id="current_page" example="1">%1$d</xliff:g>
+        of <xliff:g id="page_count" example="100">%2$d</xliff:g></string>
+
+    <!-- Template for the message to announce the print options summary - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="summary_template">Summary, copies <xliff:g id="copies" example="1">%1$s</xliff:g>,
+        paper size <xliff:g id="paper_size" example="A4">%2$s</xliff:g></string>
+
+    <!-- Description for the handle to expand all print options - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="expand_handle">Expand handle</string>
+
+    <!-- Description for the handle to collapse all print options - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="collapse_handle">Collapse handle</string>
+
+    <!-- Description for the print button - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="print_button">Print</string>
+
+    <!-- Description for the save to PDF button - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="savetopdf_button">Save to PDF</string>
+
+    <!-- Message to announce print options are expanded - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="print_options_expanded">Print options expanded</string>
+
+    <!-- Message to announce print options are collapsed - spoken to the user. [CHAR LIMIT=none] -->
+    <string name="print_options_collapsed">Print options collapsed</string>
+
     <!-- Select printer activity -->
 
     <!-- Title for the share action bar menu item. [CHAR LIMIT=20] -->
diff --git a/packages/PrintSpooler/res/values/themes.xml b/packages/PrintSpooler/res/values/themes.xml
index db319e9..532b01f 100644
--- a/packages/PrintSpooler/res/values/themes.xml
+++ b/packages/PrintSpooler/res/values/themes.xml
@@ -16,7 +16,10 @@
 
 <resources>
 
-    <style name="PrintActivity" parent="@android:style/Theme.Material.Settings">
+    <style name="PrintActivity" parent="@android:style/Theme.Material">
+        <item name="android:colorPrimary">@*android:color/material_blue_grey_900</item>
+        <item name="android:colorPrimaryDark">@*android:color/material_blue_grey_950</item>
+        <item name="android:colorAccent">@*android:color/material_deep_teal_500</item>
         <item name="android:windowIsTranslucent">true</item>
         <item name="android:windowBackground">@android:color/transparent</item>
         <item name="android:windowContentOverlay">@null</item>
diff --git a/packages/PrintSpooler/src/com/android/printspooler/model/NotificationController.java b/packages/PrintSpooler/src/com/android/printspooler/model/NotificationController.java
index 3134e93..5233c79 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/NotificationController.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/NotificationController.java
@@ -124,7 +124,9 @@
                 .setContentText(printJob.getPrinterName())
                 .setWhen(System.currentTimeMillis())
                 .setOngoing(true)
-                .setShowWhen(true);
+                .setShowWhen(true)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
         mNotificationManager.notify(0, builder.build());
     }
 
@@ -140,7 +142,9 @@
                 .setContentText(printJob.getPrinterName())
                 .setWhen(System.currentTimeMillis())
                 .setOngoing(true)
-                .setShowWhen(true);
+                .setShowWhen(true)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
         mNotificationManager.notify(0, builder.build());
     }
 
@@ -154,7 +158,9 @@
                 .setContentText(printJob.getPrinterName())
                 .setWhen(System.currentTimeMillis())
                 .setOngoing(true)
-                .setShowWhen(true);
+                .setShowWhen(true)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
            mNotificationManager.notify(0, builder.build());
     }
 
@@ -166,7 +172,9 @@
                 .setContentText(printJob.getPrinterName())
                 .setWhen(System.currentTimeMillis())
                 .setOngoing(true)
-                .setShowWhen(true);
+                .setShowWhen(true)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
         mNotificationManager.notify(0, builder.build());
     }
 
@@ -198,6 +206,8 @@
 
         builder.setNumber(printJobCount);
         builder.setStyle(inboxStyle);
+        builder.setColor(mContext.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color));
 
         mNotificationManager.notify(0, builder.build());
     }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java b/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
index c3ddad9..a4555f1 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
@@ -17,23 +17,30 @@
 package com.android.printspooler.model;
 
 import android.app.ActivityManager;
+import android.content.ComponentName;
 import android.content.Context;
-import android.content.res.Configuration;
+import android.content.Intent;
+import android.content.ServiceConnection;
 import android.graphics.Bitmap;
 import android.graphics.Color;
-import android.graphics.Matrix;
-import android.graphics.Rect;
 import android.graphics.drawable.BitmapDrawable;
-import android.graphics.pdf.PdfRenderer;
 import android.os.AsyncTask;
+import android.os.IBinder;
 import android.os.ParcelFileDescriptor;
+import android.os.RemoteException;
+import android.print.PrintAttributes;
 import android.print.PrintAttributes.MediaSize;
 import android.print.PrintAttributes.Margins;
 import android.print.PrintDocumentInfo;
 import android.util.ArrayMap;
 import android.util.Log;
 import android.view.View;
+import com.android.internal.annotations.GuardedBy;
+import com.android.printspooler.renderer.IPdfRenderer;
+import com.android.printspooler.renderer.PdfManipulationService;
+import com.android.printspooler.util.BitmapSerializeUtils;
 import dalvik.system.CloseGuard;
+import libcore.io.IoUtils;
 
 import java.io.IOException;
 import java.util.Iterator;
@@ -55,14 +62,8 @@
 
     private static final int BYTES_PER_MEGABYTE = 1048576;
 
-    private static final int MILS_PER_INCH = 1000;
-    private static final int POINTS_IN_INCH = 72;
-
     private final CloseGuard mCloseGuard = CloseGuard.get();
 
-    private final ArrayMap<Integer, PageContentProvider> mPageContentProviders =
-            new ArrayMap<>();
-
     private final AsyncRenderer mRenderer;
 
     private RenderSpec mLastRenderSpec;
@@ -115,7 +116,6 @@
         if (DEBUG) {
             Log.i(LOG_TAG, "STATE_DESTROYED");
         }
-        throwIfNotClosed();
         doDestroy();
     }
 
@@ -138,10 +138,6 @@
         return mRenderer.getPageCount();
     }
 
-    public PageContentProvider peekPageContentProvider(int pageIndex) {
-        return mPageContentProviders.get(pageIndex);
-    }
-
     public PageContentProvider acquirePageContentProvider(int pageIndex, View owner) {
         throwIfDestroyed();
 
@@ -149,15 +145,7 @@
             Log.i(LOG_TAG, "Acquiring provider for page: " + pageIndex);
         }
 
-        if (mPageContentProviders.get(pageIndex)!= null) {
-            throw new IllegalStateException("Already acquired for page: " + pageIndex);
-        }
-
-        PageContentProvider provider = new PageContentProvider(pageIndex, owner);
-
-        mPageContentProviders.put(pageIndex, provider);
-
-        return provider;
+        return new PageContentProvider(pageIndex, owner);
     }
 
     public void releasePageContentProvider(PageContentProvider provider) {
@@ -167,10 +155,6 @@
             Log.i(LOG_TAG, "Releasing provider for page: " + provider.mPageIndex);
         }
 
-        if (mPageContentProviders.remove(provider.mPageIndex) == null) {
-            throw new IllegalStateException("Not acquired");
-        }
-
         provider.cancelLoad();
     }
 
@@ -342,7 +326,7 @@
             Iterator<Map.Entry<Integer, RenderedPage>> iterator =
                     mRenderedPages.entrySet().iterator();
             while (iterator.hasNext()) {
-                iterator.next().getValue().recycle();
+                iterator.next();
                 iterator.remove();
             }
         }
@@ -351,15 +335,14 @@
     public static final class RenderSpec {
         final int bitmapWidth;
         final int bitmapHeight;
-        final MediaSize mediaSize;
-        final Margins minMargins;
+        final PrintAttributes printAttributes = new PrintAttributes.Builder().build();
 
         public RenderSpec(int bitmapWidth, int bitmapHeight,
                 MediaSize mediaSize, Margins minMargins) {
             this.bitmapWidth = bitmapWidth;
             this.bitmapHeight = bitmapHeight;
-            this.mediaSize = mediaSize;
-            this.minMargins = minMargins;
+            printAttributes.setMediaSize(mediaSize);
+            printAttributes.setMinMargins(minMargins);
         }
 
         @Override
@@ -380,18 +363,11 @@
             if (bitmapWidth != other.bitmapWidth) {
                 return false;
             }
-            if (mediaSize != null) {
-                if (!mediaSize.equals(other.mediaSize)) {
+            if (printAttributes != null) {
+                if (!printAttributes.equals(other.printAttributes)) {
                     return false;
                 }
-            } else if (other.mediaSize != null) {
-                return false;
-            }
-            if (minMargins != null) {
-                if (!minMargins.equals(other.minMargins)) {
-                    return false;
-                }
-            } else if (other.minMargins != null) {
+            } else if (other.printAttributes != null) {
                 return false;
             }
             return true;
@@ -407,8 +383,7 @@
         public int hashCode() {
             int result = bitmapWidth;
             result = 31 * result + bitmapHeight;
-            result = 31 * result + (mediaSize != null ? mediaSize.hashCode() : 0);
-            result = 31 * result + (minMargins != null ? minMargins.hashCode() : 0);
+            result = 31 * result + (printAttributes != null ? printAttributes.hashCode() : 0);
             return result;
         }
     }
@@ -431,22 +406,16 @@
             return content.getBitmap().getByteCount();
         }
 
-        public void recycle() {
-            content.getBitmap().recycle();
-        }
-
         public void erase() {
             content.getBitmap().eraseColor(Color.WHITE);
         }
     }
 
-    private static int pointsFromMils(int mils) {
-        return (int) (((float) mils / MILS_PER_INCH) * POINTS_IN_INCH);
-    }
-
-    private static class AsyncRenderer {
+    private static final class AsyncRenderer implements ServiceConnection {
         private static final int MALFORMED_PDF_FILE_ERROR = -2;
 
+        private final Object mLock = new Object();
+
         private final Context mContext;
 
         private final PageContentLruCache mPageContentCache;
@@ -457,8 +426,10 @@
 
         private int mPageCount = PrintDocumentInfo.PAGE_COUNT_UNKNOWN;
 
-        // Accessed only by the executor thread.
-        private PdfRenderer mRenderer;
+        @GuardedBy("mLock")
+        private IPdfRenderer mRenderer;
+
+        private boolean mBoundToService;
 
         public AsyncRenderer(Context context, OnMalformedPdfFileListener malformedPdfFileListener) {
             mContext = context;
@@ -470,6 +441,22 @@
             mPageContentCache = new PageContentLruCache(cacheSizeInBytes);
         }
 
+        @Override
+        public void onServiceConnected(ComponentName name, IBinder service) {
+            mBoundToService = true;
+            synchronized (mLock) {
+                mRenderer = IPdfRenderer.Stub.asInterface(service);
+                mLock.notifyAll();
+            }
+        }
+
+        @Override
+        public void onServiceDisconnected(ComponentName name) {
+            synchronized (mLock) {
+                mRenderer = null;
+            }
+        }
+
         public void open(final ParcelFileDescriptor source, final Runnable callback) {
             // Opening a new document invalidates the cache as it has pages
             // from the last document. We keep the cache even when the document
@@ -479,13 +466,32 @@
 
             new AsyncTask<Void, Void, Integer>() {
                 @Override
+                protected void onPreExecute() {
+                    Intent intent = new Intent(PdfManipulationService.ACTION_GET_RENDERER);
+                    intent.setClass(mContext, PdfManipulationService.class);
+                    mContext.bindService(intent, AsyncRenderer.this, Context.BIND_AUTO_CREATE);
+                }
+
+                @Override
                 protected Integer doInBackground(Void... params) {
-                    try {
-                        mRenderer = new PdfRenderer(source);
-                        return mRenderer.getPageCount();
-                    } catch (IOException ioe) {
-                        Log.e(LOG_TAG, "Cannot open PDF document");
-                        return MALFORMED_PDF_FILE_ERROR;
+                    synchronized (mLock) {
+                        while (mRenderer == null) {
+                            try {
+                                mLock.wait();
+                            } catch (InterruptedException ie) {
+                                /* ignore */
+                            }
+                        }
+                        try {
+                            return mRenderer.openDocument(source);
+                        } catch (RemoteException re) {
+                            Log.e(LOG_TAG, "Cannot open PDF document");
+                            return MALFORMED_PDF_FILE_ERROR;
+                        } finally {
+                            // Close the fd as we passed it to another process
+                            // which took ownership.
+                            IoUtils.closeQuietly(source);
+                        }
                     }
                 }
 
@@ -501,7 +507,7 @@
                         callback.run();
                     }
                 }
-            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR, (Void[]) null);
+            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
         }
 
         public void close(final Runnable callback) {
@@ -510,7 +516,13 @@
             new AsyncTask<Void, Void, Void>() {
                 @Override
                 protected Void doInBackground(Void... params) {
-                    mRenderer.close();
+                    synchronized (mLock) {
+                        try {
+                            mRenderer.closeDocument();
+                        } catch (RemoteException re) {
+                            /* ignore */
+                        }
+                    }
                     return null;
                 }
 
@@ -521,12 +533,26 @@
                         callback.run();
                     }
                 }
-            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR, (Void[]) null);
+            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
         }
 
         public void destroy() {
-            mPageContentCache.invalidate();
-            mPageContentCache.clear();
+            new AsyncTask<Void, Void, Void>() {
+                @Override
+                protected Void doInBackground(Void... params) {
+                    return null;
+                }
+
+                @Override
+                public void onPostExecute(Void result) {
+                    if (mBoundToService) {
+                        mBoundToService = false;
+                        mContext.unbindService(AsyncRenderer.this);
+                    }
+                    mPageContentCache.invalidate();
+                    mPageContentCache.clear();
+                }
+            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
         }
 
         public void startPreload(int firstShownPage, int lastShownPage, RenderSpec renderSpec) {
@@ -642,7 +668,7 @@
             // Oh well, we will have work to do...
             renderTask = new RenderPageTask(pageIndex, renderSpec, callback);
             mPageToRenderTaskMap.put(pageIndex, renderTask);
-            renderTask.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR, (Void[]) null);
+            renderTask.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
         }
 
         public void cancelRendering(int pageIndex) {
@@ -689,7 +715,6 @@
                                 + " with different size.");
                     }
                     mPageContentCache.removeRenderedPage(mPageIndex);
-                    mRenderedPage.recycle();
                     mRenderedPage = null;
                 }
 
@@ -713,7 +738,6 @@
                             Log.i(LOG_TAG, "Recycling bitmap for page: " + mPageIndex
                                    + " with different size.");
                         }
-                        renderedPage.recycle();
                         continue;
                     }
 
@@ -752,62 +776,28 @@
                     return mRenderedPage;
                 }
 
-                PdfRenderer.Page page = mRenderer.openPage(mPageIndex);
-
-                if (isCancelled()) {
-                    page.close();
-                    return mRenderedPage;
-                }
-
                 Bitmap bitmap = mRenderedPage.content.getBitmap();
 
-                final int srcWidthPts = page.getWidth();
-                final int srcHeightPts = page.getHeight();
+                ParcelFileDescriptor[] pipe = null;
+                try {
+                    pipe = ParcelFileDescriptor.createPipe();
+                    ParcelFileDescriptor source = pipe[0];
+                    ParcelFileDescriptor destination = pipe[1];
 
-                final int dstWidthPts = pointsFromMils(mRenderSpec.mediaSize.getWidthMils());
-                final int dstHeightPts = pointsFromMils(mRenderSpec.mediaSize.getHeightMils());
+                    mRenderer.renderPage(mPageIndex, bitmap.getWidth(), bitmap.getHeight(),
+                            mRenderSpec.printAttributes, destination);
 
-                final boolean scaleContent = mRenderer.shouldScaleForPrinting();
-                final boolean contentLandscape = !mRenderSpec.mediaSize.isPortrait();
+                    // We passed the file descriptor to the other side which took
+                    // ownership, so close our copy for the write to complete.
+                    destination.close();
 
-                final float displayScale;
-                Matrix matrix = new Matrix();
-
-                if (scaleContent) {
-                    displayScale = Math.min((float) bitmap.getWidth() / srcWidthPts,
-                            (float) bitmap.getHeight() / srcHeightPts);
-                } else {
-                    if (contentLandscape) {
-                        displayScale = (float) bitmap.getHeight() / dstHeightPts;
-                    } else {
-                        displayScale = (float) bitmap.getWidth() / dstWidthPts;
-                    }
+                    BitmapSerializeUtils.readBitmapPixels(bitmap, source);
+                } catch (IOException|RemoteException e) {
+                    Log.e(LOG_TAG, "Error rendering page:" + mPageIndex, e);
+                } finally {
+                    IoUtils.closeQuietly(pipe[0]);
+                    IoUtils.closeQuietly(pipe[1]);
                 }
-                matrix.postScale(displayScale, displayScale);
-
-                Configuration configuration = mContext.getResources().getConfiguration();
-                if (configuration.getLayoutDirection() == View.LAYOUT_DIRECTION_RTL) {
-                    matrix.postTranslate(bitmap.getWidth() - srcWidthPts * displayScale, 0);
-                }
-
-                final int paddingLeftPts = pointsFromMils(mRenderSpec.minMargins.getLeftMils());
-                final int paddingTopPts = pointsFromMils(mRenderSpec.minMargins.getTopMils());
-                final int paddingRightPts = pointsFromMils(mRenderSpec.minMargins.getRightMils());
-                final int paddingBottomPts = pointsFromMils(mRenderSpec.minMargins.getBottomMils());
-
-                Rect clip = new Rect();
-                clip.left = (int) (paddingLeftPts * displayScale);
-                clip.top = (int) (paddingTopPts * displayScale);
-                clip.right = (int) (bitmap.getWidth() - paddingRightPts * displayScale);
-                clip.bottom = (int) (bitmap.getHeight() - paddingBottomPts * displayScale);
-
-                if (DEBUG) {
-                    Log.i(LOG_TAG, "Rendering page:" + mPageIndex + " of " + mPageCount);
-                }
-
-                page.render(bitmap, clip, matrix, PdfRenderer.Page.RENDER_MODE_FOR_DISPLAY);
-
-                page.close();
 
                 return mRenderedPage;
             }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/model/PrintSpoolerProvider.java b/packages/PrintSpooler/src/com/android/printspooler/model/PrintSpoolerProvider.java
index 06723c3..8537d6c 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/PrintSpoolerProvider.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/PrintSpoolerProvider.java
@@ -20,7 +20,9 @@
 import android.content.Context;
 import android.content.Intent;
 import android.content.ServiceConnection;
+import android.os.Debug;
 import android.os.IBinder;
+import android.util.Log;
 
 public class PrintSpoolerProvider implements ServiceConnection {
     private final Context mContext;
diff --git a/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java b/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
index 9351078..c53fcad 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
@@ -55,7 +55,7 @@
 public final class RemotePrintDocument {
     private static final String LOG_TAG = "RemotePrintDocument";
 
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
 
     private static final int STATE_INITIAL = 0;
     private static final int STATE_STARTED = 1;
@@ -74,7 +74,7 @@
 
     private final Looper mLooper;
     private final IPrintDocumentAdapter mPrintDocumentAdapter;
-    private final DocumentObserver mDocumentObserver;
+    private final RemoteAdapterDeathObserver mAdapterDeathObserver;
 
     private final UpdateResultCallbacks mUpdateCallbacks;
 
@@ -107,11 +107,13 @@
                                         mDocumentInfo.info.getPageCount());
                             }
                             // Notify we are done.
+                            mState = STATE_UPDATED;
                             notifyUpdateCompleted();
                         }
                     }
                 } else {
                     // We always notify after a write.
+                    mState = STATE_UPDATED;
                     notifyUpdateCompleted();
                 }
                 runPendingCommand();
@@ -135,7 +137,7 @@
     private final DeathRecipient mDeathRecipient = new DeathRecipient() {
         @Override
         public void binderDied() {
-            finish();
+            notifyPrintingAppDied();
         }
     };
 
@@ -144,8 +146,8 @@
     private AsyncCommand mCurrentCommand;
     private AsyncCommand mNextCommand;
 
-    public interface DocumentObserver {
-        public void onDestroy();
+    public interface RemoteAdapterDeathObserver {
+        public void onDied();
     }
 
     public interface UpdateResultCallbacks {
@@ -155,12 +157,12 @@
     }
 
     public RemotePrintDocument(Context context, IPrintDocumentAdapter adapter,
-            MutexFileProvider fileProvider, DocumentObserver destroyListener,
+            MutexFileProvider fileProvider, RemoteAdapterDeathObserver deathObserver,
             UpdateResultCallbacks callbacks) {
         mPrintDocumentAdapter = adapter;
         mLooper = context.getMainLooper();
         mContext = context;
-        mDocumentObserver = destroyListener;
+        mAdapterDeathObserver = deathObserver;
         mDocumentInfo = new RemotePrintDocumentInfo();
         mDocumentInfo.fileProvider = fileProvider;
         mUpdateCallbacks = callbacks;
@@ -180,7 +182,6 @@
         } catch (RemoteException re) {
             Log.e(LOG_TAG, "Error calling start()", re);
             mState = STATE_FAILED;
-            mDocumentObserver.onDestroy();
         }
     }
 
@@ -258,7 +259,8 @@
             Log.i(LOG_TAG, "[CALLED] finish()");
         }
         if (mState != STATE_STARTED && mState != STATE_UPDATED
-                && mState != STATE_FAILED && mState != STATE_CANCELING) {
+                && mState != STATE_FAILED && mState != STATE_CANCELING
+                && mState != STATE_CANCELED) {
             throw new IllegalStateException("Cannot finish in state:"
                     + stateToString(mState));
         }
@@ -268,7 +270,6 @@
         } catch (RemoteException re) {
             Log.e(LOG_TAG, "Error calling finish()", re);
             mState = STATE_FAILED;
-            mDocumentObserver.onDestroy();
         }
     }
 
@@ -301,7 +302,6 @@
         mState = STATE_DESTROYED;
 
         disconnectFromRemoteDocument();
-        mDocumentObserver.onDestroy();
     }
 
     public boolean isUpdating() {
@@ -316,6 +316,11 @@
         return mState == STATE_FAILED;
     }
 
+    public boolean hasLaidOutPages() {
+        return mDocumentInfo.info != null
+                && mDocumentInfo.info.getPageCount() > 0;
+    }
+
     public void clearUpdateError() {
         if (!hasUpdateError()) {
             throw new IllegalStateException("No update error to clear");
@@ -1103,6 +1108,15 @@
         }
     }
 
+    private void notifyPrintingAppDied() {
+        new Handler(mLooper).post(new Runnable() {
+            @Override
+            public void run() {
+                mAdapterDeathObserver.onDied();
+            }
+        });
+    }
+
     private static final class PrintDocumentAdapterObserver
             extends IPrintDocumentAdapterObserver.Stub {
         private final WeakReference<RemotePrintDocument> mWeakDocument;
@@ -1115,12 +1129,7 @@
         public void onDestroy() {
             final RemotePrintDocument document = mWeakDocument.get();
             if (document != null) {
-                new Handler(document.mLooper).post(new Runnable() {
-                    @Override
-                    public void run() {
-                        document.mDocumentObserver.onDestroy();
-                    }
-                });
+                document.notifyPrintingAppDied();
             }
         }
     }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfEditor.aidl b/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfEditor.aidl
new file mode 100644
index 0000000..b450ccb
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfEditor.aidl
@@ -0,0 +1,30 @@
+/*
+ * Copyright (C) 2014 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.printspooler.renderer;
+
+import android.os.ParcelFileDescriptor;
+import android.print.PageRange;
+
+/**
+ * Interface for communication with a remote pdf editor.
+ */
+interface IPdfEditor {
+    int openDocument(in ParcelFileDescriptor source);
+    void removePages(in PageRange[] pages);
+    void write(in ParcelFileDescriptor destination);
+    void closeDocument();
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfRenderer.aidl b/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfRenderer.aidl
new file mode 100644
index 0000000..8e595d7
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/renderer/IPdfRenderer.aidl
@@ -0,0 +1,32 @@
+/*
+ * Copyright (C) 2014 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.printspooler.renderer;
+
+import android.graphics.Rect;
+import android.os.ParcelFileDescriptor;
+import android.print.PageRange;
+import android.print.PrintAttributes;
+
+/**
+ * Interface for communication with a remote pdf renderer.
+ */
+interface IPdfRenderer {
+    int openDocument(in ParcelFileDescriptor source);
+    oneway void renderPage(int pageIndex, int bitmapWidth, int bitmapHeight,
+        in PrintAttributes attributes, in ParcelFileDescriptor destination);
+    oneway void closeDocument();
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/renderer/PdfManipulationService.java b/packages/PrintSpooler/src/com/android/printspooler/renderer/PdfManipulationService.java
new file mode 100644
index 0000000..62716b2
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/renderer/PdfManipulationService.java
@@ -0,0 +1,291 @@
+/*
+ * Copyright (C) 2014 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.printspooler.renderer;
+
+import android.app.Service;
+import android.content.Intent;
+import android.content.res.Configuration;
+import android.graphics.Bitmap;
+import android.graphics.Color;
+import android.graphics.Matrix;
+import android.graphics.Rect;
+import android.graphics.pdf.PdfEditor;
+import android.graphics.pdf.PdfRenderer;
+import android.os.IBinder;
+import android.os.ParcelFileDescriptor;
+import android.os.RemoteException;
+import android.print.PageRange;
+import android.print.PrintAttributes;
+import android.print.PrintAttributes.Margins;
+import android.util.Log;
+import android.view.View;
+import com.android.printspooler.util.PageRangeUtils;
+import libcore.io.IoUtils;
+import com.android.printspooler.util.BitmapSerializeUtils;
+import java.io.IOException;
+
+/**
+ * Service for manipulation of PDF documents in an isolated process.
+ */
+public final class PdfManipulationService extends Service {
+    public static final String ACTION_GET_RENDERER =
+            "com.android.printspooler.renderer.ACTION_GET_RENDERER";
+    public static final String ACTION_GET_EDITOR =
+            "com.android.printspooler.renderer.ACTION_GET_EDITOR";
+
+    private static final String LOG_TAG = "PdfManipulationService";
+    private static final boolean DEBUG = false;
+
+    private static final int MILS_PER_INCH = 1000;
+    private static final int POINTS_IN_INCH = 72;
+
+    @Override
+    public IBinder onBind(Intent intent) {
+        String action = intent.getAction();
+        switch (action) {
+            case ACTION_GET_RENDERER: {
+                return new PdfRendererImpl();
+            }
+            case ACTION_GET_EDITOR: {
+                return new PdfEditorImpl();
+            }
+            default: {
+                throw new IllegalArgumentException("Invalid intent action:" + action);
+            }
+        }
+    }
+
+    private final class PdfRendererImpl extends IPdfRenderer.Stub {
+        private final Object mLock = new Object();
+
+        private Bitmap mBitmap;
+        private PdfRenderer mRenderer;
+
+        @Override
+        public int openDocument(ParcelFileDescriptor source) throws RemoteException {
+            synchronized (mLock) {
+                try {
+                    throwIfOpened();
+                    if (DEBUG) {
+                        Log.i(LOG_TAG, "openDocument()");
+                    }
+                    mRenderer = new PdfRenderer(source);
+                    return mRenderer.getPageCount();
+                } catch (IOException|IllegalStateException e) {
+                    IoUtils.closeQuietly(source);
+                    Log.e(LOG_TAG, "Cannot open file", e);
+                    throw new RemoteException(e.toString());
+                }
+            }
+        }
+
+        @Override
+        public void renderPage(int pageIndex, int bitmapWidth, int bitmapHeight,
+                PrintAttributes attributes, ParcelFileDescriptor destination) {
+            synchronized (mLock) {
+                try {
+                    throwIfNotOpened();
+
+                    PdfRenderer.Page page = mRenderer.openPage(pageIndex);
+
+                    final int srcWidthPts = page.getWidth();
+                    final int srcHeightPts = page.getHeight();
+
+                    final int dstWidthPts = pointsFromMils(
+                            attributes.getMediaSize().getWidthMils());
+                    final int dstHeightPts = pointsFromMils(
+                            attributes.getMediaSize().getHeightMils());
+
+                    final boolean scaleContent = mRenderer.shouldScaleForPrinting();
+                    final boolean contentLandscape = !attributes.getMediaSize().isPortrait();
+
+                    final float displayScale;
+                    Matrix matrix = new Matrix();
+
+                    if (scaleContent) {
+                        displayScale = Math.min((float) bitmapWidth / srcWidthPts,
+                                (float) bitmapHeight / srcHeightPts);
+                    } else {
+                        if (contentLandscape) {
+                            displayScale = (float) bitmapHeight / dstHeightPts;
+                        } else {
+                            displayScale = (float) bitmapWidth / dstWidthPts;
+                        }
+                    }
+                    matrix.postScale(displayScale, displayScale);
+
+                    Configuration configuration = PdfManipulationService.this.getResources()
+                            .getConfiguration();
+                    if (configuration.getLayoutDirection() == View.LAYOUT_DIRECTION_RTL) {
+                        matrix.postTranslate(bitmapWidth - srcWidthPts * displayScale, 0);
+                    }
+
+                    Margins minMargins = attributes.getMinMargins();
+                    final int paddingLeftPts = pointsFromMils(minMargins.getLeftMils());
+                    final int paddingTopPts = pointsFromMils(minMargins.getTopMils());
+                    final int paddingRightPts = pointsFromMils(minMargins.getRightMils());
+                    final int paddingBottomPts = pointsFromMils(minMargins.getBottomMils());
+
+                    Rect clip = new Rect();
+                    clip.left = (int) (paddingLeftPts * displayScale);
+                    clip.top = (int) (paddingTopPts * displayScale);
+                    clip.right = (int) (bitmapWidth - paddingRightPts * displayScale);
+                    clip.bottom = (int) (bitmapHeight - paddingBottomPts * displayScale);
+
+                    if (DEBUG) {
+                        Log.i(LOG_TAG, "Rendering page:" + pageIndex);
+                    }
+
+                    Bitmap bitmap = getBitmapForSize(bitmapWidth, bitmapHeight);
+                    page.render(bitmap, clip, matrix, PdfRenderer.Page.RENDER_MODE_FOR_DISPLAY);
+
+                    page.close();
+
+                    BitmapSerializeUtils.writeBitmapPixels(bitmap, destination);
+                } finally {
+                    IoUtils.closeQuietly(destination);
+                }
+            }
+        }
+
+        @Override
+        public void closeDocument() {
+            synchronized (mLock) {
+                throwIfNotOpened();
+                if (DEBUG) {
+                    Log.i(LOG_TAG, "closeDocument()");
+                }
+                mRenderer.close();
+                mRenderer = null;
+            }
+        }
+
+        private Bitmap getBitmapForSize(int width, int height) {
+            if (mBitmap != null) {
+                if (mBitmap.getWidth() == width && mBitmap.getHeight() == height) {
+                    mBitmap.eraseColor(Color.WHITE);
+                    return mBitmap;
+                }
+                mBitmap.recycle();
+            }
+            mBitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
+            mBitmap.eraseColor(Color.WHITE);
+            return mBitmap;
+        }
+
+        private void throwIfOpened() {
+            if (mRenderer != null) {
+                throw new IllegalStateException("Already opened");
+            }
+        }
+
+        private void throwIfNotOpened() {
+            if (mRenderer == null) {
+                throw new IllegalStateException("Not opened");
+            }
+        }
+    }
+
+    private final class PdfEditorImpl extends IPdfEditor.Stub {
+        private final Object mLock = new Object();
+
+        private PdfEditor mEditor;
+
+        @Override
+        public int openDocument(ParcelFileDescriptor source) throws RemoteException {
+            synchronized (mLock) {
+                try {
+                    throwIfOpened();
+                    if (DEBUG) {
+                        Log.i(LOG_TAG, "openDocument()");
+                    }
+                    mEditor = new PdfEditor(source);
+                    return mEditor.getPageCount();
+                } catch (IOException|IllegalStateException e) {
+                    IoUtils.closeQuietly(source);
+                    Log.e(LOG_TAG, "Cannot open file", e);
+                    throw new RemoteException(e.toString());
+                }
+            }
+        }
+
+        @Override
+        public void removePages(PageRange[] ranges) {
+            synchronized (mLock) {
+                throwIfNotOpened();
+                if (DEBUG) {
+                    Log.i(LOG_TAG, "removePages()");
+                }
+
+                ranges = PageRangeUtils.normalize(ranges);
+
+                final int rangeCount = ranges.length;
+                for (int i = rangeCount - 1; i >= 0; i--) {
+                    PageRange range = ranges[i];
+                    for (int j = range.getEnd(); j >= range.getStart(); j--) {
+                        mEditor.removePage(j);
+                    }
+                }
+            }
+        }
+
+        @Override
+        public void write(ParcelFileDescriptor destination) throws RemoteException {
+            synchronized (mLock) {
+                try {
+                    throwIfNotOpened();
+                    if (DEBUG) {
+                        Log.i(LOG_TAG, "write()");
+                    }
+                    mEditor.write(destination);
+                } catch (IOException | IllegalStateException e) {
+                    IoUtils.closeQuietly(destination);
+                    Log.e(LOG_TAG, "Error writing PDF to file.", e);
+                    throw new RemoteException(e.toString());
+                }
+            }
+        }
+
+        @Override
+        public void closeDocument() {
+            synchronized (mLock) {
+                throwIfNotOpened();
+                if (DEBUG) {
+                    Log.i(LOG_TAG, "closeDocument()");
+                }
+                mEditor.close();
+                mEditor = null;
+            }
+        }
+
+        private void throwIfOpened() {
+            if (mEditor != null) {
+                throw new IllegalStateException("Already opened");
+            }
+        }
+
+        private void throwIfNotOpened() {
+            if (mEditor == null) {
+                throw new IllegalStateException("Not opened");
+            }
+        }
+    }
+
+    private static int pointsFromMils(int mils) {
+        return (int) (((float) mils / MILS_PER_INCH) * POINTS_IN_INCH);
+    }
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/PageAdapter.java b/packages/PrintSpooler/src/com/android/printspooler/ui/PageAdapter.java
index 5bcdb9f..da8160a 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/ui/PageAdapter.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/ui/PageAdapter.java
@@ -17,6 +17,9 @@
 package com.android.printspooler.ui;
 
 import android.content.Context;
+import android.graphics.Bitmap;
+import android.graphics.Canvas;
+import android.graphics.drawable.BitmapDrawable;
 import android.os.ParcelFileDescriptor;
 import android.print.PageRange;
 import android.print.PrintAttributes.MediaSize;
@@ -26,18 +29,19 @@
 import android.support.v7.widget.RecyclerView.ViewHolder;
 import android.util.Log;
 import android.util.SparseArray;
-import android.util.TypedValue;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.View.OnClickListener;
 import android.view.ViewGroup;
 import android.view.ViewGroup.LayoutParams;
+import android.view.View.MeasureSpec;
 import android.widget.TextView;
 import com.android.printspooler.R;
 import com.android.printspooler.model.PageContentRepository;
 import com.android.printspooler.model.PageContentRepository.PageContentProvider;
 import com.android.printspooler.util.PageRangeUtils;
 import com.android.printspooler.widget.PageContentView;
+import com.android.printspooler.widget.PreviewPageFrame;
 import dalvik.system.CloseGuard;
 
 import java.util.ArrayList;
@@ -48,12 +52,12 @@
  * This class represents the adapter for the pages in the print preview list.
  */
 public final class PageAdapter extends Adapter implements
-        PageContentRepository.OnMalformedPdfFileListener{
+        PageContentRepository.OnMalformedPdfFileListener {
     private static final String LOG_TAG = "PageAdapter";
 
     private static final int MAX_PREVIEW_PAGES_BATCH = 50;
 
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
 
     private static final PageRange[] ALL_PAGES_ARRAY = new PageRange[] {
             PageRange.ALL_PAGES
@@ -86,15 +90,11 @@
     // Pages the user selected in the UI.
     private PageRange[] mSelectedPages;
 
+    private BitmapDrawable mEmptyState;
+
     private int mDocumentPageCount = PrintDocumentInfo.PAGE_COUNT_UNKNOWN;
     private int mSelectedPageCount;
 
-    private float mSelectedPageElevation;
-    private float mSelectedPageAlpha;
-
-    private float mUnselectedPageElevation;
-    private float mUnselectedPageAlpha;
-
     private int mPreviewPageMargin;
     private int mPreviewPageMinWidth;
     private int mPreviewListPadding;
@@ -129,16 +129,6 @@
                 Context.LAYOUT_INFLATER_SERVICE);
         mPageContentRepository = new PageContentRepository(context, this);
 
-        mSelectedPageElevation = mContext.getResources().getDimension(
-                R.dimen.selected_page_elevation);
-        mSelectedPageAlpha = mContext.getResources().getFraction(
-                R.fraction.page_selected_alpha, 1, 1);
-
-        mUnselectedPageElevation = mContext.getResources().getDimension(
-                R.dimen.unselected_page_elevation);
-        mUnselectedPageAlpha = mContext.getResources().getFraction(
-                R.fraction.page_unselected_alpha, 1, 1);
-
         mPreviewPageMargin = mContext.getResources().getDimensionPixelSize(
                 R.dimen.preview_page_margin);
 
@@ -174,6 +164,7 @@
     public void onOrientationChanged() {
         mColumnCount = mContext.getResources().getInteger(
                 R.integer.preview_page_per_row_count);
+        notifyDataSetChanged();
     }
 
     public boolean isOpened() {
@@ -184,13 +175,19 @@
         return mPageContentRepository.getFilePageCount();
     }
 
-    public void open(ParcelFileDescriptor source, Runnable callback) {
+    public void open(ParcelFileDescriptor source, final Runnable callback) {
         throwIfNotClosed();
         mState = STATE_OPENED;
         if (DEBUG) {
             Log.i(LOG_TAG, "STATE_OPENED");
         }
-        mPageContentRepository.open(source, callback);
+        mPageContentRepository.open(source, new Runnable() {
+            @Override
+            public void run() {
+                notifyDataSetChanged();
+                callback.run();
+            }
+        });
     }
 
     public void update(PageRange[] writtenPages, PageRange[] selectedPages,
@@ -257,7 +254,7 @@
         }
 
         if (updatePreviewAreaAndPageSize) {
-            updatePreviewAreaAndPageSize();
+            updatePreviewAreaPageSizeAndEmptyState();
         }
 
         if (documentChanged) {
@@ -277,9 +274,7 @@
     @Override
     public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
         View page = mLayoutInflater.inflate(R.layout.preview_page, parent, false);
-        ViewHolder holder = new MyViewHolder(page);
-        holder.setIsRecyclable(true);
-        return holder;
+        return new MyViewHolder(page);
     }
 
     @Override
@@ -289,15 +284,11 @@
                     + " for position: " + position);
         }
 
-        final int pageCount = getItemCount();
         MyViewHolder myHolder = (MyViewHolder) holder;
 
-        View page = holder.itemView;
-        if (pageCount > 1) {
-            page.setOnClickListener(mPageClickListener);
-        } else {
-            page.setOnClickListener(null);
-        }
+        PreviewPageFrame page = (PreviewPageFrame) holder.itemView;
+        page.setOnClickListener(mPageClickListener);
+
         page.setTag(holder);
 
         myHolder.mPageInAdapter = position;
@@ -321,14 +312,8 @@
                         + ", pageIndexInFile: " + pageIndexInFile);
             }
 
-            // OK, there are bugs in recycler view which tries to bind views
-            // without recycling them which would give us a chane to clean up.
-            PageContentProvider boundProvider = mPageContentRepository
-                   .peekPageContentProvider(pageIndexInFile);
-            if (boundProvider != null) {
-                PageContentView owner = (PageContentView) boundProvider.getOwner();
-                owner.init(null, mMediaSize, mMinMargins);
-                mPageContentRepository.releasePageContentProvider(boundProvider);
+            if (provider != null && provider.getPageIndex() != pageIndexInFile) {
+                mPageContentRepository.releasePageContentProvider(provider);
             }
 
             provider = mPageContentRepository.acquirePageContentProvider(
@@ -337,29 +322,17 @@
         } else {
             onSelectedPageNotInFile(pageInDocument);
         }
-        content.init(provider, mMediaSize, mMinMargins);
-
-
-        View pageSelector = page.findViewById(R.id.page_selector);
-        pageSelector.setTag(myHolder);
-        if (pageCount > 1) {
-            pageSelector.setOnClickListener(mPageClickListener);
-            pageSelector.setVisibility(View.VISIBLE);
-        } else {
-            pageSelector.setOnClickListener(null);
-            pageSelector.setVisibility(View.GONE);
-        }
+        content.init(provider, mEmptyState, mMediaSize, mMinMargins);
 
         if (mConfirmedPagesInDocument.indexOfKey(pageInDocument) >= 0) {
-            pageSelector.setSelected(true);
-            page.setTranslationZ(mSelectedPageElevation);
-            page.setAlpha(mSelectedPageAlpha);
+            page.setSelected(true, false);
         } else {
-            pageSelector.setSelected(false);
-            page.setTranslationZ(mUnselectedPageElevation);
-            page.setAlpha(mUnselectedPageAlpha);
+            page.setSelected(false, false);
         }
 
+        page.setContentDescription(mContext.getString(R.string.page_description_template,
+                pageInDocument + 1, mDocumentPageCount));
+
         TextView pageNumberView = (TextView) page.findViewById(R.id.page_number);
         String text = mContext.getString(R.string.current_page_template,
                 pageInDocument + 1, mDocumentPageCount);
@@ -395,7 +368,7 @@
             mSelectedPages = selectedPages;
             mSelectedPageCount = PageRangeUtils.getNormalizedPageCount(
                     mSelectedPages, mDocumentPageCount);
-            updatePreviewAreaAndPageSize();
+            updatePreviewAreaPageSizeAndEmptyState();
             notifyDataSetChanged();
         }
         return mSelectedPages;
@@ -403,12 +376,16 @@
 
     public void onPreviewAreaSizeChanged() {
         if (mMediaSize != null) {
-            updatePreviewAreaAndPageSize();
+            updatePreviewAreaPageSizeAndEmptyState();
             notifyDataSetChanged();
         }
     }
 
-    private void updatePreviewAreaAndPageSize() {
+    private void updatePreviewAreaPageSizeAndEmptyState() {
+        if (mMediaSize == null) {
+            return;
+        }
+
         final int availableWidth = mPreviewArea.getWidth();
         final int availableHeight = mPreviewArea.getHeight();
 
@@ -430,7 +407,7 @@
         final int pageContentDesiredHeight = (int) (((float) pageContentDesiredWidth
                 / pageAspectRatio) + 0.5f);
 
-        // If the page does not fit entirely in a vertial direction,
+        // If the page does not fit entirely in a vertical direction,
         // we shirk it but not less than the minimal page width.
         final int pageContentMinHeight = (int) (mPreviewPageMinWidth / pageAspectRatio + 0.5f);
         final int pageContentMaxHeight = Math.max(pageContentMinHeight,
@@ -448,9 +425,11 @@
                 * mPreviewPageMargin);
 
         final int verticalPadding;
-        if (mPageContentHeight + mFooterHeight + mPreviewListPadding > availableHeight) {
-            verticalPadding = Math.max(mPreviewPageMargin,
-                    (availableHeight - totalContentHeight) / 2);
+        if (mPageContentHeight + mFooterHeight + mPreviewListPadding
+                + 2 * mPreviewPageMargin > availableHeight) {
+            verticalPadding = Math.max(0,
+                    (availableHeight - mPageContentHeight - mFooterHeight) / 2
+                            - mPreviewPageMargin);
         } else {
             verticalPadding = Math.max(mPreviewListPadding,
                     (availableHeight - totalContentHeight) / 2);
@@ -458,6 +437,23 @@
 
         mPreviewArea.setPadding(horizontalPadding, verticalPadding,
                 horizontalPadding, verticalPadding);
+
+        // Now update the empty state drawable, as it depends on the page
+        // size and is reused for all views for better performance.
+        LayoutInflater inflater = LayoutInflater.from(mContext);
+        View content = inflater.inflate(R.layout.preview_page_loading, null, false);
+        content.measure(MeasureSpec.makeMeasureSpec(mPageContentWidth, MeasureSpec.EXACTLY),
+                MeasureSpec.makeMeasureSpec(mPageContentHeight, MeasureSpec.EXACTLY));
+        content.layout(0, 0, content.getMeasuredWidth(), content.getMeasuredHeight());
+
+        Bitmap bitmap = Bitmap.createBitmap(mPageContentWidth, mPageContentHeight,
+                Bitmap.Config.ARGB_8888);
+        Canvas canvas = new Canvas(bitmap);
+        content.draw(canvas);
+
+        // Do not recycle the old bitmap if such as it may be set as an empty
+        // state to any of the page views. Just let the GC take care of it.
+        mEmptyState = new BitmapDrawable(mContext.getResources(), bitmap);
     }
 
     private PageRange[] computeSelectedPages() {
@@ -728,10 +724,10 @@
     private void recyclePageView(PageContentView page, int pageIndexInAdapter) {
         PageContentProvider provider = page.getPageContentProvider();
         if (provider != null) {
-            page.init(null, null, null);
+            page.init(null, mEmptyState, mMediaSize, mMinMargins);
             mPageContentRepository.releasePageContentProvider(provider);
-            mBoundPagesInAdapter.remove(pageIndexInAdapter);
         }
+        mBoundPagesInAdapter.remove(pageIndexInAdapter);
         page.setTag(null);
     }
 
@@ -780,21 +776,20 @@
 
     private final class PageClickListener implements OnClickListener {
         @Override
-        public void onClick(View page) {
+        public void onClick(View view) {
+            PreviewPageFrame page = (PreviewPageFrame) view;
             MyViewHolder holder = (MyViewHolder) page.getTag();
             final int pageInAdapter = holder.mPageInAdapter;
             final int pageInDocument = computePageIndexInDocument(pageInAdapter);
-            View pageSelector = page.findViewById(R.id.page_selector);
             if (mConfirmedPagesInDocument.indexOfKey(pageInDocument) < 0) {
                 mConfirmedPagesInDocument.put(pageInDocument, null);
-                pageSelector.setSelected(true);
-                page.animate().translationZ(mSelectedPageElevation)
-                        .alpha(mSelectedPageAlpha);
+                page.setSelected(true, true);
             } else {
+                if (mConfirmedPagesInDocument.size() <= 1) {
+                    return;
+                }
                 mConfirmedPagesInDocument.remove(pageInDocument);
-                pageSelector.setSelected(false);
-                page.animate().translationZ(mUnselectedPageElevation)
-                        .alpha(mUnselectedPageAlpha);
+                page.setSelected(false, true);
             }
         }
     }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java
index 6b29e5f..d169319 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintActivity.java
@@ -23,6 +23,7 @@
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
+import android.content.ServiceConnection;
 import android.content.pm.PackageInfo;
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.pm.ResolveInfo;
@@ -30,9 +31,12 @@
 import android.database.DataSetObserver;
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
+import android.os.AsyncTask;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
+import android.os.ParcelFileDescriptor;
+import android.os.RemoteException;
 import android.print.IPrintDocumentAdapter;
 import android.print.PageRange;
 import android.print.PrintAttributes;
@@ -74,6 +78,8 @@
 import com.android.printspooler.model.PrintSpoolerService;
 import com.android.printspooler.model.RemotePrintDocument;
 import com.android.printspooler.model.RemotePrintDocument.RemotePrintDocumentInfo;
+import com.android.printspooler.renderer.IPdfEditor;
+import com.android.printspooler.renderer.PdfManipulationService;
 import com.android.printspooler.util.MediaSizeUtils;
 import com.android.printspooler.util.MediaSizeUtils.MediaSizeComparator;
 import com.android.printspooler.util.PageRangeUtils;
@@ -81,8 +87,15 @@
 import com.android.printspooler.widget.PrintContentView;
 import com.android.printspooler.widget.PrintContentView.OptionsStateChangeListener;
 import com.android.printspooler.widget.PrintContentView.OptionsStateController;
+import libcore.io.IoUtils;
+import libcore.io.Streams;
 
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
 import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
@@ -114,14 +127,15 @@
     private static final int DEST_ADAPTER_ITEM_ID_SAVE_AS_PDF = Integer.MAX_VALUE;
     private static final int DEST_ADAPTER_ITEM_ID_ALL_PRINTERS = Integer.MAX_VALUE - 1;
 
-    private static final int STATE_CONFIGURING = 0;
-    private static final int STATE_PRINT_CONFIRMED = 1;
-    private static final int STATE_PRINT_CANCELED = 2;
-    private static final int STATE_UPDATE_FAILED = 3;
-    private static final int STATE_CREATE_FILE_FAILED = 4;
-    private static final int STATE_PRINTER_UNAVAILABLE = 5;
-    private static final int STATE_UPDATE_SLOW = 6;
-    private static final int STATE_PRINT_COMPLETED = 7;
+    private static final int STATE_INITIALIZING = 0;
+    private static final int STATE_CONFIGURING = 1;
+    private static final int STATE_PRINT_CONFIRMED = 2;
+    private static final int STATE_PRINT_CANCELED = 3;
+    private static final int STATE_UPDATE_FAILED = 4;
+    private static final int STATE_CREATE_FILE_FAILED = 5;
+    private static final int STATE_PRINTER_UNAVAILABLE = 6;
+    private static final int STATE_UPDATE_SLOW = 7;
+    private static final int STATE_PRINT_COMPLETED = 8;
 
     private static final int UI_STATE_PREVIEW = 0;
     private static final int UI_STATE_ERROR = 1;
@@ -177,16 +191,16 @@
 
     private PrintContentView mOptionsContent;
 
+    private View mSummaryContainer;
     private TextView mSummaryCopies;
     private TextView mSummaryPaperSize;
 
-    private View mAdvancedPrintOptionsContainer;
-
     private Button mMoreOptionsButton;
 
     private ImageView mPrintButton;
 
     private ProgressMessageController mProgressMessageController;
+    private MutexFileProvider mFileProvider;
 
     private MediaSizeComparator mMediaSizeComparator;
 
@@ -198,7 +212,7 @@
 
     private int mCurrentPageCount;
 
-    private int mState;
+    private int mState = STATE_INITIALIZING;
 
     private int mUiState = UI_STATE_PREVIEW;
 
@@ -206,8 +220,6 @@
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
 
-        setState(STATE_CONFIGURING);
-
         Bundle extras = getIntent().getExtras();
 
         mPrintJob = extras.getParcelable(PrintManager.EXTRA_PRINT_JOB);
@@ -258,9 +270,8 @@
         setTitle(R.string.print_dialog);
         setContentView(R.layout.print_activity);
 
-        final MutexFileProvider fileProvider;
         try {
-            fileProvider = new MutexFileProvider(
+            mFileProvider = new MutexFileProvider(
                     PrintSpoolerService.generateFileForPrintJob(
                             PrintActivity.this, mPrintJob.getId()));
         } catch (IOException ioe) {
@@ -269,13 +280,17 @@
         }
 
         mPrintPreviewController = new PrintPreviewController(PrintActivity.this,
-                fileProvider);
+                mFileProvider);
         mPrintedDocument = new RemotePrintDocument(PrintActivity.this,
                 IPrintDocumentAdapter.Stub.asInterface(documentAdapter),
-                fileProvider, new RemotePrintDocument.DocumentObserver() {
+                mFileProvider, new RemotePrintDocument.RemoteAdapterDeathObserver() {
             @Override
-            public void onDestroy() {
-                finish();
+            public void onDied() {
+                if (isFinishing()) {
+                    return;
+                }
+                setState(STATE_PRINT_CANCELED);
+                doFinish();
             }
         }, PrintActivity.this);
         mProgressMessageController = new ProgressMessageController(
@@ -292,12 +307,31 @@
         mPrintedDocument.start();
 
         ensurePreviewUiShown();
+
+        setState(STATE_CONFIGURING);
+    }
+
+    @Override
+    public void onResume() {
+        super.onResume();
+        if (mState != STATE_INITIALIZING && mCurrentPrinter != null) {
+            mPrinterRegistry.setTrackedPrinter(mCurrentPrinter.getId());
+        }
     }
 
     @Override
     public void onPause() {
+        PrintSpoolerService spooler = mSpoolerProvider.getSpooler();
+
+        if (mState == STATE_INITIALIZING) {
+            if (isFinishing()) {
+                spooler.setPrintJobState(mPrintJob.getId(), PrintJobInfo.STATE_CANCELED, null);
+            }
+            super.onPause();
+            return;
+        }
+
         if (isFinishing()) {
-            PrintSpoolerService spooler = mSpoolerProvider.getSpooler();
             spooler.updatePrintJobUserConfigurableOptionsNoPersistence(mPrintJob);
 
             switch (mState) {
@@ -318,15 +352,10 @@
                     spooler.setPrintJobState(mPrintJob.getId(), PrintJobInfo.STATE_CANCELED, null);
                 } break;
             }
-
-            mProgressMessageController.cancel();
-            mPrinterRegistry.setTrackedPrinter(null);
-            mSpoolerProvider.destroy();
-            mPrintedDocument.finish();
-            mPrintedDocument.destroy();
         }
 
         mPrinterAvailabilityDetector.cancel();
+        mPrinterRegistry.setTrackedPrinter(null);
 
         super.onPause();
     }
@@ -342,9 +371,19 @@
 
     @Override
     public boolean onKeyUp(int keyCode, KeyEvent event) {
+        if (mState == STATE_INITIALIZING) {
+            doFinish();
+            return true;
+        }
+
+        if (mState == STATE_PRINT_CANCELED ||mState == STATE_PRINT_CONFIRMED
+                || mState == STATE_PRINT_COMPLETED) {
+            return true;
+        }
+
         if (keyCode == KeyEvent.KEYCODE_BACK
                 && event.isTracking() && !event.isCanceled()) {
-            if (mPrintPreviewController != null&&mPrintPreviewController.isOptionsOpened()
+            if (mPrintPreviewController != null && mPrintPreviewController.isOptionsOpened()
                     && !hasErrors()) {
                 mPrintPreviewController.closeOptions();
             } else {
@@ -358,7 +397,7 @@
     @Override
     public void onRequestContentUpdate() {
         if (canUpdateDocument()) {
-            updateDocument(true, false);
+            updateDocument(false);
         }
     }
 
@@ -375,7 +414,7 @@
     @Override
     public void onActionPerformed() {
         if (mState == STATE_UPDATE_FAILED
-                && canUpdateDocument() && updateDocument(true, true)) {
+                && canUpdateDocument() && updateDocument(true)) {
             ensurePreviewUiShown();
             setState(STATE_CONFIGURING);
             updateOptionsUi();
@@ -396,7 +435,7 @@
             } break;
 
             case STATE_PRINT_CANCELED: {
-                finish();
+                doFinish();
             } break;
         }
     }
@@ -433,7 +472,7 @@
             } break;
 
             case STATE_PRINT_CANCELED: {
-                finish();
+                doFinish();
             } break;
 
             default: {
@@ -546,14 +585,13 @@
         if (resultCode == RESULT_OK && data != null) {
             setState(STATE_PRINT_COMPLETED);
             updateOptionsUi();
-            Uri uri = data.getData();
-            mPrintedDocument.writeContent(getContentResolver(), uri);
+            final Uri uri = data.getData();
             // Calling finish here does not invoke lifecycle callbacks but we
             // update the print job in onPause if finishing, hence post a message.
             mDestinationSpinner.post(new Runnable() {
                 @Override
                 public void run() {
-                    finish();
+                    shredPagesAndFinish(uri);
                 }
             });
         } else if (resultCode == RESULT_CANCELED) {
@@ -567,7 +605,7 @@
             mDestinationSpinner.post(new Runnable() {
                 @Override
                 public void run() {
-                    finish();
+                    doFinish();
                 }
             });
         }
@@ -697,7 +735,7 @@
 
         // Update the content if needed.
         if (canUpdateDocument()) {
-            updateDocument(true, false);
+            updateDocument(false);
         }
     }
 
@@ -787,6 +825,9 @@
     }
 
     private void ensureProgressUiShown() {
+        if (isFinishing()) {
+            return;
+        }
         if (mUiState != UI_STATE_PROGRESS) {
             mUiState = UI_STATE_PROGRESS;
             mPrintPreviewController.setUiShown(false);
@@ -796,6 +837,9 @@
     }
 
     private void ensurePreviewUiShown() {
+        if (isFinishing()) {
+            return;
+        }
         if (mUiState != UI_STATE_PREVIEW) {
             mUiState = UI_STATE_PREVIEW;
             mPrintPreviewController.setUiShown(true);
@@ -804,6 +848,9 @@
     }
 
     private void ensureErrorUiShown(CharSequence message, int action) {
+        if (isFinishing()) {
+            return;
+        }
         if (mUiState != UI_STATE_ERROR) {
             mUiState = UI_STATE_ERROR;
             mPrintPreviewController.setUiShown(false);
@@ -829,7 +876,7 @@
         if (mCurrentPrinter == mDestinationSpinnerAdapter.getPdfPrinter()) {
             startCreateDocumentActivity();
         } else {
-            finish();
+            shredPagesAndFinish(null);
         }
     }
 
@@ -882,7 +929,7 @@
         attributes.setMinMargins(defaults.getMinMargins());
     }
 
-    private boolean updateDocument(boolean preview, boolean clearLastError) {
+    private boolean updateDocument(boolean clearLastError) {
         if (!clearLastError && mPrintedDocument.hasUpdateError()) {
             return false;
         }
@@ -891,6 +938,7 @@
             mPrintedDocument.clearUpdateError();
         }
 
+        final boolean preview = mState != STATE_PRINT_CONFIRMED;
         final PageRange[] pages;
         if (preview) {
             pages = mPrintPreviewController.getRequestedPages();
@@ -901,11 +949,11 @@
         final boolean willUpdate = mPrintedDocument.update(mPrintJob.getAttributes(),
                 pages, preview);
 
-        if (willUpdate) {
+        if (willUpdate && !mPrintedDocument.hasLaidOutPages()) {
             // When the update is done we update the print preview.
             mProgressMessageController.post();
             return true;
-        } else  {
+        } else if (!willUpdate) {
             // Update preview.
             updatePrintPreviewController(false);
         }
@@ -928,7 +976,7 @@
         if (mPrintedDocument.isUpdating()) {
             mPrintedDocument.cancel();
         }
-        finish();
+        doFinish();
     }
 
     private void confirmPrint() {
@@ -948,7 +996,7 @@
         mPrintPreviewController.closeOptions();
 
         if (canUpdateDocument()) {
-            updateDocument(false, false);
+            updateDocument(false);
         }
 
         if (!mPrintedDocument.isUpdating()) {
@@ -958,6 +1006,7 @@
 
     private void bindUi() {
         // Summary
+        mSummaryContainer = findViewById(R.id.summary_content);
         mSummaryCopies = (TextView) findViewById(R.id.copies_count_summary);
         mSummaryPaperSize = (TextView) findViewById(R.id.paper_size_summary);
 
@@ -984,21 +1033,21 @@
 
         // Media size.
         mMediaSizeSpinnerAdapter = new ArrayAdapter<>(
-                this, R.layout.spinner_dropdown_item, R.id.title);
+                this, android.R.layout.simple_spinner_dropdown_item, android.R.id.text1);
         mMediaSizeSpinner = (Spinner) findViewById(R.id.paper_size_spinner);
         mMediaSizeSpinner.setAdapter(mMediaSizeSpinnerAdapter);
         mMediaSizeSpinner.setOnItemSelectedListener(itemSelectedListener);
 
         // Color mode.
         mColorModeSpinnerAdapter = new ArrayAdapter<>(
-                this, R.layout.spinner_dropdown_item, R.id.title);
+                this, android.R.layout.simple_spinner_dropdown_item, android.R.id.text1);
         mColorModeSpinner = (Spinner) findViewById(R.id.color_spinner);
         mColorModeSpinner.setAdapter(mColorModeSpinnerAdapter);
         mColorModeSpinner.setOnItemSelectedListener(itemSelectedListener);
 
         // Orientation
         mOrientationSpinnerAdapter = new ArrayAdapter<>(
-                this, R.layout.spinner_dropdown_item, R.id.title);
+                this, android.R.layout.simple_spinner_dropdown_item, android.R.id.text1);
         String[] orientationLabels = getResources().getStringArray(
                 R.array.orientation_labels);
         mOrientationSpinnerAdapter.add(new SpinnerItem<>(
@@ -1010,8 +1059,8 @@
         mOrientationSpinner.setOnItemSelectedListener(itemSelectedListener);
 
         // Range options
-        ArrayAdapter<SpinnerItem<Integer>> rangeOptionsSpinnerAdapter =
-                new ArrayAdapter<>(this, R.layout.spinner_dropdown_item, R.id.title);
+        ArrayAdapter<SpinnerItem<Integer>> rangeOptionsSpinnerAdapter = new ArrayAdapter<>(
+                this, android.R.layout.simple_spinner_dropdown_item, android.R.id.text1);
         mRangeOptionsSpinner = (Spinner) findViewById(R.id.range_options_spinner);
         mRangeOptionsSpinner.setAdapter(rangeOptionsSpinnerAdapter);
         mRangeOptionsSpinner.setOnItemSelectedListener(itemSelectedListener);
@@ -1024,7 +1073,6 @@
         mPageRangeEditText.addTextChangedListener(new RangeTextWatcher());
 
         // Advanced options button.
-        mAdvancedPrintOptionsContainer = findViewById(R.id.more_options_container);
         mMoreOptionsButton = (Button) findViewById(R.id.more_options_button);
         mMoreOptionsButton.setOnClickListener(clickListener);
 
@@ -1057,15 +1105,7 @@
 
     void updateOptionsUi() {
         // Always update the summary.
-        if (!TextUtils.isEmpty(mCopiesEditText.getText())) {
-            mSummaryCopies.setText(mCopiesEditText.getText());
-        }
-
-        final int selectedMediaIndex = mMediaSizeSpinner.getSelectedItemPosition();
-        if (selectedMediaIndex >= 0) {
-            SpinnerItem<MediaSize> mediaItem = mMediaSizeSpinnerAdapter.getItem(selectedMediaIndex);
-            mSummaryPaperSize.setText(mediaItem.label);
-        }
+        updateSummary();
 
         if (mState == STATE_PRINT_CONFIRMED
                 || mState == STATE_PRINT_COMPLETED
@@ -1078,6 +1118,7 @@
                 mDestinationSpinner.setEnabled(false);
             }
             mCopiesEditText.setEnabled(false);
+            mCopiesEditText.setFocusable(false);
             mMediaSizeSpinner.setEnabled(false);
             mColorModeSpinner.setEnabled(false);
             mOrientationSpinner.setEnabled(false);
@@ -1092,6 +1133,7 @@
         // available, we disable all print options except the destination.
         if (mCurrentPrinter == null || !canPrint(mCurrentPrinter)) {
             mCopiesEditText.setEnabled(false);
+            mCopiesEditText.setFocusable(false);
             mMediaSizeSpinner.setEnabled(false);
             mColorModeSpinner.setEnabled(false);
             mOrientationSpinner.setEnabled(false);
@@ -1294,18 +1336,20 @@
         ComponentName serviceName = mCurrentPrinter.getId().getServiceName();
         if (!TextUtils.isEmpty(PrintOptionUtils.getAdvancedOptionsActivityName(
                 this, serviceName))) {
-            mAdvancedPrintOptionsContainer.setVisibility(View.VISIBLE);
+            mMoreOptionsButton.setVisibility(View.VISIBLE);
             mMoreOptionsButton.setEnabled(true);
         } else {
-            mAdvancedPrintOptionsContainer.setVisibility(View.GONE);
+            mMoreOptionsButton.setVisibility(View.GONE);
             mMoreOptionsButton.setEnabled(false);
         }
 
         // Print
         if (mDestinationSpinnerAdapter.getPdfPrinter() != mCurrentPrinter) {
             mPrintButton.setImageResource(com.android.internal.R.drawable.ic_print);
+            mPrintButton.setContentDescription(getString(R.string.print_button));
         } else {
             mPrintButton.setImageResource(R.drawable.ic_menu_savetopdf);
+            mPrintButton.setContentDescription(getString(R.string.savetopdf_button));
         }
         if ((mRangeOptionsSpinner.getSelectedItemPosition() == 1
                 && (TextUtils.isEmpty(mPageRangeEditText.getText()) || hasErrors()))
@@ -1319,8 +1363,10 @@
         // Copies
         if (mDestinationSpinnerAdapter.getPdfPrinter() != mCurrentPrinter) {
             mCopiesEditText.setEnabled(true);
+            mCopiesEditText.setFocusableInTouchMode(true);
         } else {
             mCopiesEditText.setEnabled(false);
+            mCopiesEditText.setFocusable(false);
         }
         if (mCopiesEditText.getError() == null
                 && TextUtils.isEmpty(mCopiesEditText.getText())) {
@@ -1329,6 +1375,28 @@
         }
     }
 
+    private void updateSummary() {
+        CharSequence copiesText = null;
+        CharSequence mediaSizeText = null;
+
+        if (!TextUtils.isEmpty(mCopiesEditText.getText())) {
+            copiesText = mCopiesEditText.getText();
+            mSummaryCopies.setText(copiesText);
+        }
+
+        final int selectedMediaIndex = mMediaSizeSpinner.getSelectedItemPosition();
+        if (selectedMediaIndex >= 0) {
+            SpinnerItem<MediaSize> mediaItem = mMediaSizeSpinnerAdapter.getItem(selectedMediaIndex);
+            mediaSizeText = mediaItem.label;
+            mSummaryPaperSize.setText(mediaSizeText);
+        }
+
+        if (!TextUtils.isEmpty(copiesText) && !TextUtils.isEmpty(mediaSizeText)) {
+            String summaryText = getString(R.string.summary_template, copiesText, mediaSizeText);
+            mSummaryContainer.setContentDescription(summaryText);
+        }
+    }
+
     private void updatePageRangeOptions(int pageCount) {
         ArrayAdapter<SpinnerItem<Integer>> rangeOptionsSpinnerAdapter =
                 (ArrayAdapter) mRangeOptionsSpinner.getAdapter();
@@ -1419,7 +1487,7 @@
         if (mCurrentPrinter.equals(printer)) {
             setState(STATE_CONFIGURING);
             if (canUpdateDocument()) {
-                updateDocument(true, false);
+                updateDocument(false);
             }
             ensurePreviewUiShown();
             updateOptionsUi();
@@ -1478,6 +1546,30 @@
         return true;
     }
 
+    private void shredPagesAndFinish(final Uri writeToUri) {
+        new PageShredder(this, mPrintJob, mFileProvider, new Runnable() {
+            @Override
+            public void run() {
+                if (writeToUri != null) {
+                    mPrintedDocument.writeContent(getContentResolver(), writeToUri);
+                }
+                doFinish();
+            }
+        }).shred();
+    }
+
+    private void doFinish() {
+        if (mState != STATE_INITIALIZING) {
+            mProgressMessageController.cancel();
+            mPrinterRegistry.setTrackedPrinter(null);
+            mPrintPreviewController.destroy();
+            mSpoolerProvider.destroy();
+            mPrintedDocument.finish();
+            mPrintedDocument.destroy();
+        }
+        finish();
+    }
+
     private final class SpinnerItem<T> {
         final T value;
         final CharSequence label;
@@ -1704,7 +1796,7 @@
                 if (position == 0 && getPdfPrinter() != null) {
                     PrinterHolder printerHolder = (PrinterHolder) getItem(position);
                     title = printerHolder.printer.getName();
-                    icon = getResources().getDrawable(R.drawable.ic_savetopdf);
+                    icon = getResources().getDrawable(R.drawable.ic_menu_savetopdf);
                 } else if (position == 1) {
                     title = getString(R.string.all_printers);
                 }
@@ -1712,7 +1804,7 @@
                 if (position == 1 && getPdfPrinter() != null) {
                     PrinterHolder printerHolder = (PrinterHolder) getItem(position);
                     title = printerHolder.printer.getName();
-                    icon = getResources().getDrawable(R.drawable.ic_savetopdf);
+                    icon = getResources().getDrawable(R.drawable.ic_menu_savetopdf);
                 } else if (position == getCount() - 1) {
                     title = getString(R.string.all_printers);
                 } else {
@@ -1918,6 +2010,7 @@
             if ((isActive && gotCapab) || (becameActive && hasCapab)) {
                 if (hasCapab && capabChanged) {
                     updatePrintAttributesFromCapabilities(newCapab);
+                    updatePrintPreviewController(false);
                 }
                 onPrinterAvailable(newPrinterState);
             } else if ((becameInactive && hasCapab) || (isActive && lostCapab)) {
@@ -1928,7 +2021,7 @@
                     || (becameActive && hasCapab) || (isActive && gotCapab));
 
             if (updateNeeded && canUpdateDocument()) {
-                updateDocument(true, false);
+                updateDocument(false);
             }
 
             updateOptionsUi();
@@ -2019,7 +2112,7 @@
             }
 
             if (canUpdateDocument()) {
-                updateDocument(true, false);
+                updateDocument(false);
             }
 
             updateOptionsUi();
@@ -2144,7 +2237,7 @@
             updateOptionsUi();
 
             if (hadErrors && canUpdateDocument()) {
-                updateDocument(true, false);
+                updateDocument(false);
             }
         }
     }
@@ -2184,4 +2277,177 @@
             updateOptionsUi();
         }
     }
-}
\ No newline at end of file
+
+    private static final class PageShredder implements ServiceConnection {
+        private static final String TEMP_FILE_PREFIX = "print_job";
+        private static final String TEMP_FILE_EXTENSION = ".pdf";
+
+        private final Context mContext;
+
+        private final MutexFileProvider mFileProvider;
+
+        private final PrintJobInfo mPrintJob;
+
+        private final PageRange[] mPagesToShred;
+
+        private final Runnable mCallback;
+
+        public PageShredder(Context context, PrintJobInfo printJob,
+                MutexFileProvider fileProvider, Runnable callback) {
+            mContext = context;
+            mPrintJob = printJob;
+            mFileProvider = fileProvider;
+            mCallback = callback;
+            mPagesToShred = computePagesToShred(mPrintJob);
+        }
+
+        public void shred() {
+            // If we have only the pages we want, done.
+            if (mPagesToShred.length <= 0) {
+                mCallback.run();
+                return;
+            }
+
+            // Bind to the manipulation service and the work
+            // will be performed upon connection to the service.
+            Intent intent = new Intent(PdfManipulationService.ACTION_GET_EDITOR);
+            intent.setClass(mContext, PdfManipulationService.class);
+            mContext.bindService(intent, this, Context.BIND_AUTO_CREATE);
+        }
+
+        @Override
+        public void onServiceConnected(ComponentName name, IBinder service) {
+            final IPdfEditor editor = IPdfEditor.Stub.asInterface(service);
+            new AsyncTask<Void, Void, Void>() {
+                @Override
+                protected Void doInBackground(Void... params) {
+                    // It's OK to access the data members as they are
+                    // final and this code is the last one to touch
+                    // them as shredding is the very last step, so the
+                    // UI is not interactive at this point.
+                    shredPages(editor);
+                    updatePrintJob();
+                    return null;
+                }
+
+                @Override
+                protected void onPostExecute(Void aVoid) {
+                    mContext.unbindService(PageShredder.this);
+                    mCallback.run();
+                }
+            }.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
+        }
+
+        @Override
+        public void onServiceDisconnected(ComponentName name) {
+            /* do nothing */
+        }
+
+        private void shredPages(IPdfEditor editor) {
+            File tempFile = null;
+            ParcelFileDescriptor src = null;
+            ParcelFileDescriptor dst = null;
+            InputStream in = null;
+            OutputStream out = null;
+            try {
+                File jobFile = mFileProvider.acquireFile(null);
+                src = ParcelFileDescriptor.open(jobFile, ParcelFileDescriptor.MODE_READ_WRITE);
+
+                // Open the document.
+                editor.openDocument(src);
+
+                // We passed the fd over IPC, close this one.
+                src.close();
+
+                // Drop the pages.
+                editor.removePages(mPagesToShred);
+
+                // Write the modified PDF to a temp file.
+                tempFile = File.createTempFile(TEMP_FILE_PREFIX, TEMP_FILE_EXTENSION,
+                        mContext.getCacheDir());
+                dst = ParcelFileDescriptor.open(tempFile, ParcelFileDescriptor.MODE_READ_WRITE);
+                editor.write(dst);
+                dst.close();
+
+                // Close the document.
+                editor.closeDocument();
+
+                // Copy the temp file over the print job file.
+                jobFile.delete();
+                in = new FileInputStream(tempFile);
+                out = new FileOutputStream(jobFile);
+                Streams.copy(in, out);
+            } catch (IOException|RemoteException e) {
+                Log.e(LOG_TAG, "Error dropping pages", e);
+            } finally {
+                IoUtils.closeQuietly(src);
+                IoUtils.closeQuietly(dst);
+                IoUtils.closeQuietly(in);
+                IoUtils.closeQuietly(out);
+                if (tempFile != null) {
+                    tempFile.delete();
+                }
+            }
+        }
+
+        private void updatePrintJob() {
+            // Update the print job pages.
+            final int newPageCount = PageRangeUtils.getNormalizedPageCount(
+                    mPrintJob.getPages(), 0);
+            mPrintJob.setPages(new PageRange[]{PageRange.ALL_PAGES});
+
+            // Update the print job document info.
+            PrintDocumentInfo oldDocInfo = mPrintJob.getDocumentInfo();
+            PrintDocumentInfo newDocInfo = new PrintDocumentInfo
+                    .Builder(oldDocInfo.getName())
+                    .setContentType(oldDocInfo.getContentType())
+                    .setPageCount(newPageCount)
+                    .build();
+            mPrintJob.setDocumentInfo(newDocInfo);
+        }
+
+        private static PageRange[] computePagesToShred(PrintJobInfo printJob) {
+            List<PageRange> rangesToShred = new ArrayList<>();
+            PageRange previousRange = null;
+
+            final int pageCount = printJob.getDocumentInfo().getPageCount();
+
+            PageRange[] printedPages = printJob.getPages();
+            final int rangeCount = printedPages.length;
+            for (int i = 0; i < rangeCount; i++) {
+                PageRange range = PageRangeUtils.asAbsoluteRange(printedPages[i], pageCount);
+
+                if (previousRange == null) {
+                    final int startPageIdx = 0;
+                    final int endPageIdx = range.getStart() - 1;
+                    if (startPageIdx <= endPageIdx) {
+                        PageRange removedRange = new PageRange(startPageIdx, endPageIdx);
+                        rangesToShred.add(removedRange);
+                    }
+                } else {
+                    final int startPageIdx = previousRange.getEnd() + 1;
+                    final int endPageIdx = range.getStart() - 1;
+                    if (startPageIdx <= endPageIdx) {
+                        PageRange removedRange = new PageRange(startPageIdx, endPageIdx);
+                        rangesToShred.add(removedRange);
+                    }
+                }
+
+                if (i == rangeCount - 1) {
+                    final int startPageIdx = range.getEnd() + 1;
+                    final int endPageIdx = printJob.getDocumentInfo().getPageCount() - 1;
+                    if (startPageIdx <= endPageIdx) {
+                        PageRange removedRange = new PageRange(startPageIdx, endPageIdx);
+                        rangesToShred.add(removedRange);
+                    }
+                }
+
+                previousRange = range;
+            }
+
+            PageRange[] result = new PageRange[rangesToShred.size()];
+            rangesToShred.toArray(result);
+            return result;
+        }
+    }
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintPreviewController.java b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintPreviewController.java
index 4a23ec4..0d45352 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/ui/PrintPreviewController.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/ui/PrintPreviewController.java
@@ -24,11 +24,10 @@
 import android.print.PrintAttributes.MediaSize;
 import android.print.PrintAttributes.Margins;
 import android.print.PrintDocumentInfo;
-import android.support.v7.widget.OrientationHelper;
+import android.support.v7.widget.GridLayoutManager;
 import android.support.v7.widget.RecyclerView;
 import android.support.v7.widget.RecyclerView.ViewHolder;
 import android.support.v7.widget.RecyclerView.LayoutManager;
-import android.support.v7.widget.StaggeredGridLayoutManager;
 import android.view.View;
 import com.android.internal.os.SomeArgs;
 import com.android.printspooler.R;
@@ -51,7 +50,7 @@
     private final MyHandler mHandler;
 
     private final PageAdapter mPageAdapter;
-    private final StaggeredGridLayoutManager mLayoutManger;
+    private final GridLayoutManager mLayoutManger;
 
     private final PrintOptionsLayout mPrintOptionsLayout;
     private final RecyclerView mRecyclerView;
@@ -73,11 +72,12 @@
         final int columnCount = mActivity.getResources().getInteger(
                 R.integer.preview_page_per_row_count);
 
-        mLayoutManger = new StaggeredGridLayoutManager(columnCount, OrientationHelper.VERTICAL);
+        mLayoutManger = new GridLayoutManager(mActivity, columnCount);
 
         mRecyclerView = (RecyclerView) activity.findViewById(R.id.preview_content);
         mRecyclerView.setLayoutManager(mLayoutManger);
         mRecyclerView.setAdapter(mPageAdapter);
+        mRecyclerView.setItemViewCacheSize(0);
         mPreloadController = new PreloadController(mRecyclerView);
         mRecyclerView.setOnScrollListener(mPreloadController);
 
@@ -131,7 +131,7 @@
     public void onContentUpdated(boolean documentChanged, int documentPageCount,
             PageRange[] writtenPages, PageRange[] selectedPages, MediaSize mediaSize,
             Margins minMargins) {
-                boolean contentChanged = false;
+        boolean contentChanged = false;
 
         if (documentChanged) {
             contentChanged = true;
@@ -152,7 +152,7 @@
 
         // The content changed. In this case we have to invalidate
         // all rendered pages and reopen the file...
-        if (contentChanged && writtenPages != null) {
+        if ((contentChanged || !mPageAdapter.isOpened()) && writtenPages != null) {
             Message operation = mHandler.obtainMessage(MyHandler.MSG_OPEN);
             mHandler.enqueueOperation(operation);
         }
@@ -184,13 +184,19 @@
             public void run() {
                 // At this point the other end will write to the file, hence
                 // we have to close it and reopen after the write completes.
-                Message operation = mHandler.obtainMessage(MyHandler.MSG_CLOSE);
-                mHandler.enqueueOperation(operation);
+                if (mPageAdapter.isOpened()) {
+                    Message operation = mHandler.obtainMessage(MyHandler.MSG_CLOSE);
+                    mHandler.enqueueOperation(operation);
+                }
             }
         });
     }
 
     public void destroy() {
+        if (mPageAdapter.isOpened()) {
+            mPageAdapter.close(null);
+        }
+        mRecyclerView.setAdapter(null);
         mPageAdapter.destroy();
     }
 
@@ -343,8 +349,7 @@
 
         public void startPreloadContent() {
             PageAdapter pageAdapter = (PageAdapter) mRecyclerView.getAdapter();
-
-            if (pageAdapter.isOpened()) {
+            if (pageAdapter != null && pageAdapter.isOpened()) {
                 PageRange shownPages = computeShownPages();
                 if (shownPages != null) {
                     pageAdapter.startPreloadContent(shownPages);
@@ -354,8 +359,7 @@
 
         public void stopPreloadContent() {
             PageAdapter pageAdapter = (PageAdapter) mRecyclerView.getAdapter();
-
-            if (pageAdapter.isOpened()) {
+            if (pageAdapter != null && pageAdapter.isOpened()) {
                 pageAdapter.stopPreloadContent();
             }
         }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/PrinterRegistry.java b/packages/PrintSpooler/src/com/android/printspooler/ui/PrinterRegistry.java
index a3d7f01..cbc568a 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/ui/PrinterRegistry.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/ui/PrinterRegistry.java
@@ -68,23 +68,40 @@
     }
 
     public void addHistoricalPrinter(PrinterInfo printer) {
-        getPrinterProvider().addHistoricalPrinter(printer);
+        FusedPrintersProvider provider = getPrinterProvider();
+        if (provider != null) {
+            getPrinterProvider().addHistoricalPrinter(printer);
+        }
     }
 
     public void forgetFavoritePrinter(PrinterId printerId) {
-        getPrinterProvider().forgetFavoritePrinter(printerId);
+        FusedPrintersProvider provider = getPrinterProvider();
+        if (provider != null) {
+            provider.forgetFavoritePrinter(printerId);
+        }
     }
 
     public boolean isFavoritePrinter(PrinterId printerId) {
-        return getPrinterProvider().isFavoritePrinter(printerId);
+        FusedPrintersProvider provider = getPrinterProvider();
+        if (provider != null) {
+            return provider.isFavoritePrinter(printerId);
+        }
+        return false;
     }
 
     public void setTrackedPrinter(PrinterId printerId) {
-        getPrinterProvider().setTrackedPrinter(printerId);
+        FusedPrintersProvider provider = getPrinterProvider();
+        if (provider != null) {
+            provider.setTrackedPrinter(printerId);
+        }
     }
 
     public boolean areHistoricalPrintersLoaded() {
-        return getPrinterProvider().areHistoricalPrintersLoaded();
+        FusedPrintersProvider provider = getPrinterProvider();
+        if (provider != null) {
+            return getPrinterProvider().areHistoricalPrintersLoaded();
+        }
+        return false;
     }
 
     private FusedPrintersProvider getPrinterProvider() {
diff --git a/packages/PrintSpooler/src/com/android/printspooler/ui/SelectPrinterActivity.java b/packages/PrintSpooler/src/com/android/printspooler/ui/SelectPrinterActivity.java
index 7715579..3905bada 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/ui/SelectPrinterActivity.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/ui/SelectPrinterActivity.java
@@ -96,7 +96,7 @@
     @Override
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
-        getActionBar().setIcon(R.drawable.ic_menu_print);
+        getActionBar().setIcon(R.drawable.ic_print);
 
         setContentView(R.layout.select_printer_activity);
 
diff --git a/packages/PrintSpooler/src/com/android/printspooler/util/BitmapSerializeUtils.java b/packages/PrintSpooler/src/com/android/printspooler/util/BitmapSerializeUtils.java
new file mode 100644
index 0000000..a1845f6
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/util/BitmapSerializeUtils.java
@@ -0,0 +1,60 @@
+/*
+ * Copyright (C) 2014 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.printspooler.util;
+
+import android.graphics.Bitmap;
+import android.os.ParcelFileDescriptor;
+
+/**
+ * Helper for serialization of bitmaps in the very specific
+ * use case of having the same bitmap on both ends and just
+ * marshaling the pixels from one side to the other.
+ */
+public final class BitmapSerializeUtils {
+
+    static {
+        System.loadLibrary("printspooler_jni");
+    }
+
+    private BitmapSerializeUtils() {
+        /* do nothing */
+    }
+
+    /**
+     * Reads a bitmap pixels from a file descriptor.
+     *
+     * @param bitmap A bitmap whose pixels to populate.
+     * @param source The source file descriptor.
+     */
+    public static void readBitmapPixels(Bitmap bitmap, ParcelFileDescriptor source) {
+        nativeReadBitmapPixels(bitmap, source.getFd());
+    }
+
+    /**
+     * Writes a bitmap pixels to a file descriptor.
+     *
+     * @param bitmap The bitmap.
+     * @param destination The destination file descriptor.
+     */
+    public static void writeBitmapPixels(Bitmap bitmap, ParcelFileDescriptor destination) {
+        nativeWriteBitmapPixels(bitmap, destination.getFd());
+    }
+
+    private static native void nativeReadBitmapPixels(Bitmap bitmap, int fd);
+
+    private static native void nativeWriteBitmapPixels(Bitmap bitmap, int fd);
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/CustomErrorEditText.java b/packages/PrintSpooler/src/com/android/printspooler/widget/CustomErrorEditText.java
new file mode 100644
index 0000000..b2aa008
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/CustomErrorEditText.java
@@ -0,0 +1,44 @@
+/*
+ * Copyright (C) 2014 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.printspooler.widget;
+
+import android.content.Context;
+import android.graphics.drawable.Drawable;
+import android.util.AttributeSet;
+import android.widget.EditText;
+
+/**
+ * EditText that shows an error without a popup.
+ */
+public final class CustomErrorEditText extends EditText {
+    private CharSequence mError;
+
+    public CustomErrorEditText(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    @Override
+    public CharSequence getError() {
+        return mError;
+    }
+
+    @Override
+    public void setError(CharSequence error, Drawable icon) {
+        setCompoundDrawables(null, null, icon, null);
+        mError = error;
+    }
+}
\ No newline at end of file
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/FirstFocusableEditText.java b/packages/PrintSpooler/src/com/android/printspooler/widget/FirstFocusableEditText.java
deleted file mode 100644
index d6bb7c8..0000000
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/FirstFocusableEditText.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2014 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.printspooler.widget;
-
-import android.content.Context;
-import android.graphics.Rect;
-import android.graphics.drawable.Drawable;
-import android.util.AttributeSet;
-import android.widget.EditText;
-
-/**
- * An instance of this class class is intended to be the first focusable
- * in a layout to which the system automatically gives focus. It performs
- * some voodoo to avoid the first tap on it to start an edit mode, rather
- * to bring up the IME, i.e. to get the behavior as if the view was not
- * focused.
- */
-public final class FirstFocusableEditText extends EditText {
-    private boolean mClickedBeforeFocus;
-    private CharSequence mError;
-
-    public FirstFocusableEditText(Context context, AttributeSet attrs) {
-        super(context, attrs);
-    }
-
-    @Override
-    public boolean performClick() {
-        super.performClick();
-        if (isFocused() && !mClickedBeforeFocus) {
-            clearFocus();
-            requestFocus();
-        }
-        mClickedBeforeFocus = true;
-        return true;
-    }
-
-    @Override
-    public CharSequence getError() {
-        return mError;
-    }
-
-    @Override
-    public void setError(CharSequence error, Drawable icon) {
-        setCompoundDrawables(null, null, icon, null);
-        mError = error;
-    }
-
-    protected void onFocusChanged(boolean gainFocus, int direction,
-            Rect previouslyFocusedRect) {
-        if (!gainFocus) {
-            mClickedBeforeFocus = false;
-        }
-        super.onFocusChanged(gainFocus, direction, previouslyFocusedRect);
-    }
-}
\ No newline at end of file
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
index 8365373..b792789 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
@@ -17,17 +17,15 @@
 package com.android.printspooler.widget;
 
 import android.content.Context;
-import android.graphics.Canvas;
 import android.graphics.drawable.BitmapDrawable;
-import android.graphics.drawable.ColorDrawable;
+import android.graphics.drawable.Drawable;
 import android.print.PrintAttributes.MediaSize;
 import android.print.PrintAttributes.Margins;
 import android.util.AttributeSet;
-import android.util.TypedValue;
 import android.view.View;
 import com.android.printspooler.model.PageContentRepository;
-import com.android.printspooler.model.PageContentRepository.PageContentProvider;
 import com.android.printspooler.model.PageContentRepository.RenderSpec;
+import com.android.printspooler.model.PageContentRepository.PageContentProvider;
 
 /**
  * This class represents a page in the print preview list. The width of the page
@@ -38,60 +36,56 @@
 public class PageContentView extends View
         implements PageContentRepository.OnPageContentAvailableCallback {
 
-    private final ColorDrawable mEmptyState;
-
     private PageContentProvider mProvider;
 
     private MediaSize mMediaSize;
+
     private Margins mMinMargins;
 
+    private Drawable mEmptyState;
+
     private boolean mContentRequested;
 
     public PageContentView(Context context, AttributeSet attrs) {
         super(context, attrs);
-
-        TypedValue typedValue = new TypedValue();
-        context.getTheme().resolveAttribute(com.android.internal.R.attr.textColorPrimary,
-                typedValue, true);
-
-        mEmptyState = new ColorDrawable(typedValue.data);
-
-        setBackground(mEmptyState);
     }
 
     @Override
-    protected void onDraw(Canvas canvas) {
-        super.onDraw(canvas);
-        requestPageContentIfNeeded();
-    }
-
-    @Override
-    protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
-        super.onLayout(changed, left, top, right, bottom);
+    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
+        mContentRequested = false;
         requestPageContentIfNeeded();
     }
 
     @Override
     public void onPageContentAvailable(BitmapDrawable content) {
-        if (getBackground() != content) {
-            setBackground(content);
-        }
+        setBackground(content);
     }
 
     public PageContentProvider getPageContentProvider() {
         return mProvider;
     }
 
-    public void init(PageContentProvider provider, MediaSize mediaSize, Margins minMargins) {
-        if (mProvider == provider
-                && ((mMediaSize == null) ? mediaSize == null : mMediaSize.equals(mediaSize))
-                && ((mMinMargins == null) ? minMargins == null : mMinMargins.equals(minMargins))) {
+    public void init(PageContentProvider provider, Drawable emptyState,
+            MediaSize mediaSize, Margins minMargins) {
+        final boolean providerChanged = (mProvider == null)
+                ? provider != null : !mProvider.equals(provider);
+        final boolean loadingDrawableChanged = (mEmptyState == null)
+                ? emptyState != null : !mEmptyState.equals(emptyState);
+        final boolean mediaSizeChanged = (mMediaSize == null)
+                ? mediaSize != null : !mMediaSize.equals(mediaSize);
+        final boolean marginsChanged = (mMinMargins == null)
+                ? minMargins != null : !mMinMargins.equals(minMargins);
+
+        if (!providerChanged && !mediaSizeChanged
+                && !marginsChanged && !loadingDrawableChanged) {
             return;
         }
 
         mProvider = provider;
         mMediaSize = mediaSize;
         mMinMargins = minMargins;
+
+        mEmptyState = emptyState;
         mContentRequested = false;
 
         // If there is no provider we want immediately to switch to
@@ -104,10 +98,11 @@
     }
 
     private void requestPageContentIfNeeded() {
-        if (getWidth() > 0 && getHeight() > 0 && !mContentRequested && mProvider != null) {
+        if (getWidth() > 0 && getHeight() > 0 && !mContentRequested
+                && mProvider != null) {
             mContentRequested = true;
-            mProvider.getPageContent(new RenderSpec(getWidth(), getHeight(), mMediaSize,
-                    mMinMargins), this);
+            mProvider.getPageContent(new RenderSpec(getWidth(), getHeight(),
+                    mMediaSize, mMinMargins), this);
         }
     }
 }
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java
new file mode 100644
index 0000000..feb0316
--- /dev/null
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PreviewPageFrame.java
@@ -0,0 +1,89 @@
+/*
+ * Copyright (C) 2014 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.printspooler.widget;
+
+import android.content.Context;
+import android.util.AttributeSet;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
+import android.widget.CompoundButton;
+import android.widget.LinearLayout;
+import com.android.printspooler.R;
+
+/**
+ * This class represents the frame of page in the print preview list
+ * that contains the page and a footer.
+ */
+public final class PreviewPageFrame extends LinearLayout {
+    private final float mSelectedElevation;
+    private final float mNotSelectedElevation;
+
+    private final float mSelectedPageAlpha;
+    private final float mNotSelectedAlpha;
+
+    public PreviewPageFrame(Context context, AttributeSet attrs) {
+        super(context, attrs);
+        mSelectedElevation = mContext.getResources().getDimension(
+                R.dimen.selected_page_elevation);
+        mNotSelectedElevation = mContext.getResources().getDimension(
+                R.dimen.unselected_page_elevation);
+        mSelectedPageAlpha = mContext.getResources().getFraction(
+                R.fraction.page_selected_alpha, 1, 1);
+        mNotSelectedAlpha = mContext.getResources().getFraction(
+                R.fraction.page_unselected_alpha, 1, 1);
+    }
+
+    @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        event.setClassName(CompoundButton.class.getName());
+        event.setChecked(isSelected());
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        info.setClassName(CompoundButton.class.getName());
+        info.setSelected(false);
+        info.setCheckable(true);
+        info.setChecked(isSelected());
+    }
+
+    public void setSelected(boolean selected, boolean animate) {
+        if (isSelected() == selected) {
+            return;
+        }
+        setSelected(selected);
+        if (selected) {
+            if (animate) {
+                animate().translationZ(mSelectedElevation)
+                        .alpha(mSelectedPageAlpha);
+            } else {
+                setTranslationZ(mSelectedElevation);
+                setAlpha(mSelectedPageAlpha);
+            }
+        } else {
+            if (animate) {
+                animate().translationZ(mNotSelectedElevation)
+                        .alpha(mNotSelectedAlpha);
+            } else {
+                setTranslationZ(mNotSelectedElevation);
+                setAlpha(mNotSelectedAlpha);
+            }
+        }
+    }
+}
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PrintContentView.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PrintContentView.java
index efb030e..bfcd334 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/PrintContentView.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PrintContentView.java
@@ -53,7 +53,7 @@
 
     private View mDraggableContent;
     private View mPrintButton;
-    private ViewGroup mMoreOptionsContainer;
+    private View mMoreOptionsButton;
     private ViewGroup mOptionsContainer;
 
     private View mEmbeddedContentContainer;
@@ -140,7 +140,7 @@
         mDynamicContent = findViewById(R.id.dynamic_content);
         mDraggableContent = findViewById(R.id.draggable_content);
         mPrintButton = findViewById(R.id.print_button);
-        mMoreOptionsContainer = (ViewGroup) findViewById(R.id.more_options_container);
+        mMoreOptionsButton = findViewById(R.id.more_options_button);
         mOptionsContainer = (ViewGroup) findViewById(R.id.options_container);
         mEmbeddedContentContainer = findViewById(R.id.embedded_content_container);
         mEmbeddedContentScrim = findViewById(R.id.embedded_content_scrim);
@@ -152,6 +152,17 @@
 
         // Make sure we start in a closed options state.
         onDragProgress(1.0f);
+
+        // The framework gives focus to the frist focusable and we
+        // do not want that, hence we will take focus instead.
+        setFocusableInTouchMode(true);
+    }
+
+    @Override
+    public void focusableViewAvailable(View v) {
+        // The framework gives focus to the frist focusable and we
+        // do not want that, hence do not announce new focusables.
+        return;
     }
 
     @Override
@@ -272,8 +283,13 @@
         mDynamicContent.layout(left, dynContentTop, right, dynContentBottom);
 
         MarginLayoutParams params = (MarginLayoutParams) mPrintButton.getLayoutParams();
-        final int rightMargin = params.rightMargin;
-        final int printButtonLeft = right - mPrintButton.getMeasuredWidth() - rightMargin;
+
+        final int printButtonLeft;
+        if (getLayoutDirection() == View.LAYOUT_DIRECTION_LTR) {
+            printButtonLeft = right - mPrintButton.getMeasuredWidth() - params.getMarginStart();
+        } else {
+            printButtonLeft = left + params.getMarginStart();
+        }
         final int printButtonTop = dynContentBottom - mPrintButton.getMeasuredHeight() / 2;
         final int printButtonRight = printButtonLeft + mPrintButton.getMeasuredWidth();
         final int printButtonBottom = printButtonTop + mPrintButton.getMeasuredHeight();
@@ -301,14 +317,15 @@
                 || (mDragProgress == 1.0f && progress < 1.0f)) {
             mSummaryContent.setLayerType(View.LAYER_TYPE_HARDWARE, null);
             mDraggableContent.setLayerType(View.LAYER_TYPE_HARDWARE, null);
-            mMoreOptionsContainer.setLayerType(View.LAYER_TYPE_HARDWARE, null);
+            mMoreOptionsButton.setLayerType(View.LAYER_TYPE_HARDWARE, null);
             ensureImeClosedAndInputFocusCleared();
         }
         if ((mDragProgress > 0 && progress == 0)
                 || (mDragProgress < 1.0f && progress == 1.0f)) {
             mSummaryContent.setLayerType(View.LAYER_TYPE_NONE, null);
             mDraggableContent.setLayerType(View.LAYER_TYPE_NONE, null);
-            mMoreOptionsContainer.setLayerType(View.LAYER_TYPE_NONE, null);
+            mMoreOptionsButton.setLayerType(View.LAYER_TYPE_NONE, null);
+            mMoreOptionsButton.setLayerType(View.LAYER_TYPE_NONE, null);
         }
 
         mDragProgress = progress;
@@ -317,14 +334,16 @@
 
         final float inverseAlpha = 1.0f - progress;
         mOptionsContainer.setAlpha(inverseAlpha);
-        mMoreOptionsContainer.setAlpha(inverseAlpha);
+        mMoreOptionsButton.setAlpha(inverseAlpha);
 
         mEmbeddedContentScrim.setBackgroundColor(computeScrimColor());
-
         if (progress == 0) {
             if (mOptionsStateChangeListener != null) {
                 mOptionsStateChangeListener.onOptionsOpened();
             }
+            mExpandCollapseHandle.setContentDescription(
+                    mContext.getString(R.string.collapse_handle));
+            announceForAccessibility(mContext.getString(R.string.print_options_expanded));
             mSummaryContent.setVisibility(View.GONE);
             mEmbeddedContentScrim.setOnClickListener(this);
             mExpandCollapseIcon.setBackgroundResource(R.drawable.ic_expand_less);
@@ -336,8 +355,11 @@
             if (mOptionsStateChangeListener != null) {
                 mOptionsStateChangeListener.onOptionsClosed();
             }
-            if (mMoreOptionsContainer.getVisibility() != View.GONE) {
-                mMoreOptionsContainer.setVisibility(View.INVISIBLE);
+            mExpandCollapseHandle.setContentDescription(
+                    mContext.getString(R.string.expand_handle));
+            announceForAccessibility(mContext.getString(R.string.print_options_collapsed));
+            if (mMoreOptionsButton.getVisibility() != View.GONE) {
+                mMoreOptionsButton.setVisibility(View.INVISIBLE);
             }
             mDraggableContent.setVisibility(View.INVISIBLE);
             // If we change the scrim visibility the dimming is lagging
@@ -346,22 +368,23 @@
             mEmbeddedContentScrim.setClickable(false);
             mExpandCollapseIcon.setBackgroundResource(R.drawable.ic_expand_more);
         } else {
-            if (mMoreOptionsContainer.getVisibility() != View.GONE) {
-                mMoreOptionsContainer.setVisibility(View.VISIBLE);
+            if (mMoreOptionsButton.getVisibility() != View.GONE) {
+                mMoreOptionsButton.setVisibility(View.VISIBLE);
             }
             mDraggableContent.setVisibility(View.VISIBLE);
         }
     }
 
     private void ensureImeClosedAndInputFocusCleared() {
-        View focus = findFocus();
-        if (focus != null) {
+        View focused = findFocus();
+
+        if (focused != null && focused.isFocused()) {
             InputMethodManager imm = (InputMethodManager) mContext.getSystemService(
                     Context.INPUT_METHOD_SERVICE);
-            if (imm.isActive(focus)) {
+            if (imm.isActive(focused)) {
                 imm.hideSoftInputFromWindow(getWindowToken(), 0);
             }
-            focus.clearFocus();
+            focused.clearFocus();
         }
     }
 
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PrintOptionsLayout.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PrintOptionsLayout.java
index 71f4aa7..7a80a8b 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/PrintOptionsLayout.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PrintOptionsLayout.java
@@ -89,7 +89,7 @@
                             columnWidth - childParams.getMarginStart() - childParams.getMarginEnd(),
                             MeasureSpec.EXACTLY);
                 } else {
-                    childWidthMeasureSpec = getChildMeasureSpec(heightMeasureSpec,
+                    childWidthMeasureSpec = getChildMeasureSpec(widthMeasureSpec,
                             getPaddingStart() + getPaddingEnd() + width, childParams.width);
                 }
 
diff --git a/packages/SettingsProvider/AndroidManifest.xml b/packages/SettingsProvider/AndroidManifest.xml
index 783aa03..469b776 100644
--- a/packages/SettingsProvider/AndroidManifest.xml
+++ b/packages/SettingsProvider/AndroidManifest.xml
@@ -16,6 +16,7 @@
                   android:multiprocess="false"
                   android:exported="true"
                   android:writePermission="android.permission.WRITE_SETTINGS"
+                  android:singleUser="true"
                   android:initOrder="100" />
     </application>
 </manifest>
diff --git a/packages/SettingsProvider/res/values-af/defaults.xml b/packages/SettingsProvider/res/values-af/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-af/defaults.xml
+++ b/packages/SettingsProvider/res/values-af/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-am/defaults.xml b/packages/SettingsProvider/res/values-am/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-am/defaults.xml
+++ b/packages/SettingsProvider/res/values-am/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ar/defaults.xml b/packages/SettingsProvider/res/values-ar/defaults.xml
index 295b4f5..22443a5 100644
--- a/packages/SettingsProvider/res/values-ar/defaults.xml
+++ b/packages/SettingsProvider/res/values-ar/defaults.xml
@@ -20,4 +20,5 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <string name="def_device_name_simple" msgid="9037785625140748221">"%1$s"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values-bg/defaults.xml b/packages/SettingsProvider/res/values-bg/defaults.xml
index 1d546ff..5e46120 100644
--- a/packages/SettingsProvider/res/values-bg/defaults.xml
+++ b/packages/SettingsProvider/res/values-bg/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s от %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-bn-rBD/defaults.xml b/packages/SettingsProvider/res/values-bn-rBD/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-bn-rBD/defaults.xml
+++ b/packages/SettingsProvider/res/values-bn-rBD/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ca/defaults.xml b/packages/SettingsProvider/res/values-ca/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ca/defaults.xml
+++ b/packages/SettingsProvider/res/values-ca/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-cs/defaults.xml b/packages/SettingsProvider/res/values-cs/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-cs/defaults.xml
+++ b/packages/SettingsProvider/res/values-cs/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-da/defaults.xml b/packages/SettingsProvider/res/values-da/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-da/defaults.xml
+++ b/packages/SettingsProvider/res/values-da/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-de/defaults.xml b/packages/SettingsProvider/res/values-de/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-de/defaults.xml
+++ b/packages/SettingsProvider/res/values-de/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-el/defaults.xml b/packages/SettingsProvider/res/values-el/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-el/defaults.xml
+++ b/packages/SettingsProvider/res/values-el/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-en-rGB/defaults.xml b/packages/SettingsProvider/res/values-en-rGB/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-en-rGB/defaults.xml
+++ b/packages/SettingsProvider/res/values-en-rGB/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-en-rIN/defaults.xml b/packages/SettingsProvider/res/values-en-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-en-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-en-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-es-rUS/defaults.xml b/packages/SettingsProvider/res/values-es-rUS/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-es-rUS/defaults.xml
+++ b/packages/SettingsProvider/res/values-es-rUS/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-es/defaults.xml b/packages/SettingsProvider/res/values-es/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-es/defaults.xml
+++ b/packages/SettingsProvider/res/values-es/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-et-rEE/defaults.xml b/packages/SettingsProvider/res/values-et-rEE/defaults.xml
index 5f99ed9..790297a 100644
--- a/packages/SettingsProvider/res/values-et-rEE/defaults.xml
+++ b/packages/SettingsProvider/res/values-et-rEE/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s, %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-eu-rES/defaults.xml b/packages/SettingsProvider/res/values-eu-rES/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-eu-rES/defaults.xml
+++ b/packages/SettingsProvider/res/values-eu-rES/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-fa/defaults.xml b/packages/SettingsProvider/res/values-fa/defaults.xml
index 295b4f5..22443a5 100644
--- a/packages/SettingsProvider/res/values-fa/defaults.xml
+++ b/packages/SettingsProvider/res/values-fa/defaults.xml
@@ -20,4 +20,5 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <string name="def_device_name_simple" msgid="9037785625140748221">"%1$s"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values-fi/defaults.xml b/packages/SettingsProvider/res/values-fi/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-fi/defaults.xml
+++ b/packages/SettingsProvider/res/values-fi/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-fr-rCA/defaults.xml b/packages/SettingsProvider/res/values-fr-rCA/defaults.xml
index 1a04b0f..15da9d2 100644
--- a/packages/SettingsProvider/res/values-fr-rCA/defaults.xml
+++ b/packages/SettingsProvider/res/values-fr-rCA/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s de %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-fr/defaults.xml b/packages/SettingsProvider/res/values-fr/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-fr/defaults.xml
+++ b/packages/SettingsProvider/res/values-fr/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-gl-rES/defaults.xml b/packages/SettingsProvider/res/values-gl-rES/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-gl-rES/defaults.xml
+++ b/packages/SettingsProvider/res/values-gl-rES/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-hi/defaults.xml b/packages/SettingsProvider/res/values-hi/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-hi/defaults.xml
+++ b/packages/SettingsProvider/res/values-hi/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-hi/strings.xml b/packages/SettingsProvider/res/values-hi/strings.xml
index 0b0bd8a..da8193f 100644
--- a/packages/SettingsProvider/res/values-hi/strings.xml
+++ b/packages/SettingsProvider/res/values-hi/strings.xml
@@ -19,5 +19,5 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="4567566098528588863">"सेटिंग संग्रहण"</string>
+    <string name="app_label" msgid="4567566098528588863">"सेटिंग मेमोरी"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values-hr/defaults.xml b/packages/SettingsProvider/res/values-hr/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-hr/defaults.xml
+++ b/packages/SettingsProvider/res/values-hr/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-hu/defaults.xml b/packages/SettingsProvider/res/values-hu/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-hu/defaults.xml
+++ b/packages/SettingsProvider/res/values-hu/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-hy-rAM/defaults.xml b/packages/SettingsProvider/res/values-hy-rAM/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-hy-rAM/defaults.xml
+++ b/packages/SettingsProvider/res/values-hy-rAM/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-in/defaults.xml b/packages/SettingsProvider/res/values-in/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-in/defaults.xml
+++ b/packages/SettingsProvider/res/values-in/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-is-rIS/defaults.xml b/packages/SettingsProvider/res/values-is-rIS/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-is-rIS/defaults.xml
+++ b/packages/SettingsProvider/res/values-is-rIS/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-it/defaults.xml b/packages/SettingsProvider/res/values-it/defaults.xml
index bc995b0..18d0b93 100644
--- a/packages/SettingsProvider/res/values-it/defaults.xml
+++ b/packages/SettingsProvider/res/values-it/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-iw/defaults.xml b/packages/SettingsProvider/res/values-iw/defaults.xml
index 295b4f5..22443a5 100644
--- a/packages/SettingsProvider/res/values-iw/defaults.xml
+++ b/packages/SettingsProvider/res/values-iw/defaults.xml
@@ -20,4 +20,5 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <string name="def_device_name_simple" msgid="9037785625140748221">"%1$s"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values-ja/defaults.xml b/packages/SettingsProvider/res/values-ja/defaults.xml
index bc995b0..18d0b93 100644
--- a/packages/SettingsProvider/res/values-ja/defaults.xml
+++ b/packages/SettingsProvider/res/values-ja/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ka-rGE/defaults.xml b/packages/SettingsProvider/res/values-ka-rGE/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ka-rGE/defaults.xml
+++ b/packages/SettingsProvider/res/values-ka-rGE/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-kk-rKZ/defaults.xml b/packages/SettingsProvider/res/values-kk-rKZ/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-kk-rKZ/defaults.xml
+++ b/packages/SettingsProvider/res/values-kk-rKZ/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-km-rKH/defaults.xml b/packages/SettingsProvider/res/values-km-rKH/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-km-rKH/defaults.xml
+++ b/packages/SettingsProvider/res/values-km-rKH/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-kn-rIN/defaults.xml b/packages/SettingsProvider/res/values-kn-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-kn-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-kn-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ko/defaults.xml b/packages/SettingsProvider/res/values-ko/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ko/defaults.xml
+++ b/packages/SettingsProvider/res/values-ko/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ky-rKG/defaults.xml b/packages/SettingsProvider/res/values-ky-rKG/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ky-rKG/defaults.xml
+++ b/packages/SettingsProvider/res/values-ky-rKG/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-lo-rLA/defaults.xml b/packages/SettingsProvider/res/values-lo-rLA/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-lo-rLA/defaults.xml
+++ b/packages/SettingsProvider/res/values-lo-rLA/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-lt/defaults.xml b/packages/SettingsProvider/res/values-lt/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-lt/defaults.xml
+++ b/packages/SettingsProvider/res/values-lt/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-lv/defaults.xml b/packages/SettingsProvider/res/values-lv/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-lv/defaults.xml
+++ b/packages/SettingsProvider/res/values-lv/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-mk-rMK/defaults.xml b/packages/SettingsProvider/res/values-mk-rMK/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-mk-rMK/defaults.xml
+++ b/packages/SettingsProvider/res/values-mk-rMK/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ml-rIN/defaults.xml b/packages/SettingsProvider/res/values-ml-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ml-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-ml-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-mn-rMN/defaults.xml b/packages/SettingsProvider/res/values-mn-rMN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-mn-rMN/defaults.xml
+++ b/packages/SettingsProvider/res/values-mn-rMN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-mr-rIN/defaults.xml b/packages/SettingsProvider/res/values-mr-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-mr-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-mr-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ms-rMY/defaults.xml b/packages/SettingsProvider/res/values-ms-rMY/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ms-rMY/defaults.xml
+++ b/packages/SettingsProvider/res/values-ms-rMY/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-my-rMM/defaults.xml b/packages/SettingsProvider/res/values-my-rMM/defaults.xml
index 295b4f5..22443a5 100644
--- a/packages/SettingsProvider/res/values-my-rMM/defaults.xml
+++ b/packages/SettingsProvider/res/values-my-rMM/defaults.xml
@@ -20,4 +20,5 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <string name="def_device_name_simple" msgid="9037785625140748221">"%1$s"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values-nb/defaults.xml b/packages/SettingsProvider/res/values-nb/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-nb/defaults.xml
+++ b/packages/SettingsProvider/res/values-nb/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ne-rNP/defaults.xml b/packages/SettingsProvider/res/values-ne-rNP/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ne-rNP/defaults.xml
+++ b/packages/SettingsProvider/res/values-ne-rNP/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-nl/defaults.xml b/packages/SettingsProvider/res/values-nl/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-nl/defaults.xml
+++ b/packages/SettingsProvider/res/values-nl/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-pl/defaults.xml b/packages/SettingsProvider/res/values-pl/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-pl/defaults.xml
+++ b/packages/SettingsProvider/res/values-pl/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-pt-rPT/defaults.xml b/packages/SettingsProvider/res/values-pt-rPT/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-pt-rPT/defaults.xml
+++ b/packages/SettingsProvider/res/values-pt-rPT/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-pt/defaults.xml b/packages/SettingsProvider/res/values-pt/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-pt/defaults.xml
+++ b/packages/SettingsProvider/res/values-pt/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ro/defaults.xml b/packages/SettingsProvider/res/values-ro/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ro/defaults.xml
+++ b/packages/SettingsProvider/res/values-ro/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ru/defaults.xml b/packages/SettingsProvider/res/values-ru/defaults.xml
index bc995b0..18d0b93 100644
--- a/packages/SettingsProvider/res/values-ru/defaults.xml
+++ b/packages/SettingsProvider/res/values-ru/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-si-rLK/defaults.xml b/packages/SettingsProvider/res/values-si-rLK/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-si-rLK/defaults.xml
+++ b/packages/SettingsProvider/res/values-si-rLK/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-sk/defaults.xml b/packages/SettingsProvider/res/values-sk/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-sk/defaults.xml
+++ b/packages/SettingsProvider/res/values-sk/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-sl/defaults.xml b/packages/SettingsProvider/res/values-sl/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-sl/defaults.xml
+++ b/packages/SettingsProvider/res/values-sl/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-sr/defaults.xml b/packages/SettingsProvider/res/values-sr/defaults.xml
index bc995b0..18d0b93 100644
--- a/packages/SettingsProvider/res/values-sr/defaults.xml
+++ b/packages/SettingsProvider/res/values-sr/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-sv/defaults.xml b/packages/SettingsProvider/res/values-sv/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-sv/defaults.xml
+++ b/packages/SettingsProvider/res/values-sv/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-sw/defaults.xml b/packages/SettingsProvider/res/values-sw/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-sw/defaults.xml
+++ b/packages/SettingsProvider/res/values-sw/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ta-rIN/defaults.xml b/packages/SettingsProvider/res/values-ta-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ta-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-ta-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-te-rIN/defaults.xml b/packages/SettingsProvider/res/values-te-rIN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-te-rIN/defaults.xml
+++ b/packages/SettingsProvider/res/values-te-rIN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-th/defaults.xml b/packages/SettingsProvider/res/values-th/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-th/defaults.xml
+++ b/packages/SettingsProvider/res/values-th/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-tl/defaults.xml b/packages/SettingsProvider/res/values-tl/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-tl/defaults.xml
+++ b/packages/SettingsProvider/res/values-tl/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-tr/defaults.xml b/packages/SettingsProvider/res/values-tr/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-tr/defaults.xml
+++ b/packages/SettingsProvider/res/values-tr/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-uk/defaults.xml b/packages/SettingsProvider/res/values-uk/defaults.xml
index 8ca4583..7da1c93 100644
--- a/packages/SettingsProvider/res/values-uk/defaults.xml
+++ b/packages/SettingsProvider/res/values-uk/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%2$s о %1$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-ur-rPK/defaults.xml b/packages/SettingsProvider/res/values-ur-rPK/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-ur-rPK/defaults.xml
+++ b/packages/SettingsProvider/res/values-ur-rPK/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-uz-rUZ/defaults.xml b/packages/SettingsProvider/res/values-uz-rUZ/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-uz-rUZ/defaults.xml
+++ b/packages/SettingsProvider/res/values-uz-rUZ/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-vi/defaults.xml b/packages/SettingsProvider/res/values-vi/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-vi/defaults.xml
+++ b/packages/SettingsProvider/res/values-vi/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-zh-rCN/defaults.xml b/packages/SettingsProvider/res/values-zh-rCN/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-zh-rCN/defaults.xml
+++ b/packages/SettingsProvider/res/values-zh-rCN/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-zh-rHK/defaults.xml b/packages/SettingsProvider/res/values-zh-rHK/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-zh-rHK/defaults.xml
+++ b/packages/SettingsProvider/res/values-zh-rHK/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-zh-rTW/defaults.xml b/packages/SettingsProvider/res/values-zh-rTW/defaults.xml
index 295b4f5..3627c9b 100644
--- a/packages/SettingsProvider/res/values-zh-rTW/defaults.xml
+++ b/packages/SettingsProvider/res/values-zh-rTW/defaults.xml
@@ -20,4 +20,6 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <!-- no translation found for def_device_name_simple (9037785625140748221) -->
+    <skip />
 </resources>
diff --git a/packages/SettingsProvider/res/values-zu/defaults.xml b/packages/SettingsProvider/res/values-zu/defaults.xml
index 295b4f5..22443a5 100644
--- a/packages/SettingsProvider/res/values-zu/defaults.xml
+++ b/packages/SettingsProvider/res/values-zu/defaults.xml
@@ -20,4 +20,5 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="def_device_name" msgid="6309317409634339402">"%1$s %2$s"</string>
+    <string name="def_device_name_simple" msgid="9037785625140748221">"%1$s"</string>
 </resources>
diff --git a/packages/SettingsProvider/res/values/defaults.xml b/packages/SettingsProvider/res/values/defaults.xml
index 299e50c..934ed38 100644
--- a/packages/SettingsProvider/res/values/defaults.xml
+++ b/packages/SettingsProvider/res/values/defaults.xml
@@ -187,12 +187,18 @@
     <!-- Default for Settings.Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS, 1==on -->
     <integer name="def_lock_screen_show_notifications">1</integer>
 
+    <!-- Default for Settings.Secure.LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS -->
+    <bool name="def_lock_screen_allow_private_notifications">true</bool>
+
     <!-- Default for Settings.Global.HEADS_UP_NOTIFICATIONS_ENABLED, 1==on -->
     <integer name="def_heads_up_enabled">1</integer>
 
-    <!-- Default for Settings.Global.DEVICE_NAME $1=BRAND $2=MODEL-->
+    <!-- Default for Settings.Global.DEVICE_NAME $1=MANUFACTURER $2=MODEL-->
     <string name="def_device_name">%1$s %2$s</string>
 
+    <!-- Default for Settings.Global.DEVICE_NAME $1=MODEL-->
+    <string name="def_device_name_simple">%1$s</string>
+
     <!-- Default for Settings.Secure.WAKE_GESTURE_ENABLED -->
     <bool name="def_wake_gesture_enabled">true</bool>
 
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
index 13301fb..873257c 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/DatabaseHelper.java
@@ -70,7 +70,7 @@
     // database gets upgraded properly. At a minimum, please confirm that 'upgradeVersion'
     // is properly propagated through your change.  Not doing so will result in a loss of user
     // settings.
-    private static final int DATABASE_VERSION = 107;
+    private static final int DATABASE_VERSION = 112;
 
     private Context mContext;
     private int mUserHandle;
@@ -1673,8 +1673,8 @@
             try {
                 stmt = db.compileStatement("INSERT OR IGNORE INTO secure(name,value)"
                         + " VALUES(?,?);");
-                loadBooleanSetting(stmt, Settings.Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS,
-                        R.bool.def_guest_user_enabled);
+                loadIntegerSetting(stmt, Settings.Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS,
+                        R.integer.def_lock_screen_show_notifications);
                 if (mUserHandle == UserHandle.USER_OWNER) {
                     final int oldShow = getIntValueFromTable(db,
                             TABLE_GLOBAL, Settings.Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS, -1);
@@ -1714,6 +1714,103 @@
             upgradeVersion = 107;
         }
 
+        if (upgradeVersion < 108) {
+            // Reset the auto-brightness setting to default since the behavior
+            // of the feature is now quite different and is being presented to
+            // the user in a new way as "adaptive brightness".
+            db.beginTransaction();
+            SQLiteStatement stmt = null;
+            try {
+                stmt = db.compileStatement("INSERT OR REPLACE INTO system(name,value)"
+                        + " VALUES(?,?);");
+                loadBooleanSetting(stmt, Settings.System.SCREEN_BRIGHTNESS_MODE,
+                        R.bool.def_screen_brightness_automatic_mode);
+                db.setTransactionSuccessful();
+            } finally {
+                db.endTransaction();
+                if (stmt != null) stmt.close();
+            }
+            upgradeVersion = 108;
+        }
+
+        if (upgradeVersion < 109) {
+            db.beginTransaction();
+            SQLiteStatement stmt = null;
+            try {
+                stmt = db.compileStatement("INSERT OR IGNORE INTO secure(name,value)"
+                        + " VALUES(?,?);");
+                loadBooleanSetting(stmt, Secure.LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS,
+                        R.bool.def_lock_screen_allow_private_notifications);
+                db.setTransactionSuccessful();
+            } finally {
+                db.endTransaction();
+                if (stmt != null) stmt.close();
+            }
+            upgradeVersion = 109;
+        }
+
+        if (upgradeVersion < 110) {
+            // The SIP_CALL_OPTIONS value SIP_ASK_EACH_TIME is being deprecated.
+            // If the SIP_CALL_OPTIONS setting is set to SIP_ASK_EACH_TIME, default to
+            // SIP_ADDRESS_ONLY.
+            db.beginTransaction();
+            SQLiteStatement stmt = null;
+            try {
+                stmt = db.compileStatement("UPDATE system SET value = ? " +
+                        "WHERE name = ? AND value = ?;");
+                stmt.bindString(1, Settings.System.SIP_ADDRESS_ONLY);
+                stmt.bindString(2, Settings.System.SIP_CALL_OPTIONS);
+                stmt.bindString(3, Settings.System.SIP_ASK_ME_EACH_TIME);
+                stmt.execute();
+                db.setTransactionSuccessful();
+            } finally {
+                db.endTransaction();
+                if (stmt != null) stmt.close();
+            }
+            upgradeVersion = 110;
+        }
+
+        if (upgradeVersion < 111) {
+            // reset ringer mode, so it doesn't force zen mode to follow
+            if (mUserHandle == UserHandle.USER_OWNER) {
+                db.beginTransaction();
+                SQLiteStatement stmt = null;
+                try {
+                    stmt = db.compileStatement("INSERT OR REPLACE INTO global(name,value)"
+                            + " VALUES(?,?);");
+                    loadSetting(stmt, Settings.Global.MODE_RINGER, AudioManager.RINGER_MODE_NORMAL);
+                    db.setTransactionSuccessful();
+                } finally {
+                    db.endTransaction();
+                    if (stmt != null) stmt.close();
+                }
+            }
+            upgradeVersion = 111;
+        }
+
+        if (upgradeVersion < 112) {
+            if (mUserHandle == UserHandle.USER_OWNER) {
+                // When device name was added, we went with Manufacturer + Model, device name should
+                // actually be Model only.
+                // Update device name to Model if it wasn't modified by user.
+                db.beginTransaction();
+                SQLiteStatement stmt = null;
+                try {
+                    stmt = db.compileStatement("UPDATE global SET value = ? "
+                        + " WHERE name = ? AND value = ?");
+                    stmt.bindString(1, getDefaultDeviceName()); // new default device name
+                    stmt.bindString(2, Settings.Global.DEVICE_NAME);
+                    stmt.bindString(3, getOldDefaultDeviceName()); // old default device name
+                    stmt.execute();
+                    db.setTransactionSuccessful();
+                } finally {
+                    db.endTransaction();
+                    if (stmt != null) stmt.close();
+                }
+            }
+            upgradeVersion = 112;
+        }
+
         // *** Remember to update DATABASE_VERSION above!
 
         if (upgradeVersion != currentVersion) {
@@ -2282,6 +2379,9 @@
             loadIntegerSetting(stmt, Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS,
                     R.integer.def_lock_screen_show_notifications);
 
+            loadBooleanSetting(stmt, Secure.LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS,
+                    R.bool.def_lock_screen_allow_private_notifications);
+
         } finally {
             if (stmt != null) stmt.close();
         }
@@ -2508,8 +2608,12 @@
         return defaultValue;
     }
 
+    private String getOldDefaultDeviceName() {
+        return mContext.getResources().getString(R.string.def_device_name,
+                Build.MANUFACTURER, Build.MODEL);
+    }
+
     private String getDefaultDeviceName() {
-        return mContext.getResources().getString(R.string.def_device_name, Build.MANUFACTURER,
-                Build.MODEL);
+        return mContext.getResources().getString(R.string.def_device_name_simple, Build.MODEL);
     }
 }
diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
index 87c015c..30ccd2c 100644
--- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
+++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java
@@ -318,10 +318,10 @@
         }
     }
 
-    private void checkUserRestrictions(String setting) {
+    private void checkUserRestrictions(String setting, int userId) {
         String userRestriction = sRestrictedKeys.get(setting);
         if (!TextUtils.isEmpty(userRestriction)
-            && mUserManager.hasUserRestriction(userRestriction)) {
+            && mUserManager.hasUserRestriction(userRestriction, new UserHandle(userId))) {
             throw new SecurityException(
                     "Permission denial: user is restricted from changing this setting.");
         }
@@ -789,8 +789,15 @@
                             Slog.v(TAG, "putting to additional user "
                                     + mManagedProfiles.get(i).id);
                         }
-                        insertForUser(Settings.Secure.CONTENT_URI, values,
-                                mManagedProfiles.get(i).id);
+                        try {
+                            insertForUser(Settings.Secure.CONTENT_URI, values,
+                                    mManagedProfiles.get(i).id);
+                        } catch (SecurityException e) {
+                            // Temporary fix, see b/17450158
+                            Slog.w(TAG, "Cannot clone request '" + request + "' with value '"
+                                    + newValue + "' to managed profile (id "
+                                    + mManagedProfiles.get(i).id + ")", e);
+                        }
                     }
                 } finally {
                     Binder.restoreCallingIdentity(token);
@@ -936,7 +943,7 @@
         try {
             int numValues = values.length;
             for (int i = 0; i < numValues; i++) {
-                checkUserRestrictions(values[i].getAsString(Settings.Secure.NAME));
+                checkUserRestrictions(values[i].getAsString(Settings.Secure.NAME), callingUser);
                 if (db.insert(args.table, null, values[i]) < 0) return 0;
                 SettingsCache.populate(cache, values[i]);
                 if (LOCAL_LOGV) Log.v(TAG, args.table + " <- " + values[i]);
@@ -1067,7 +1074,7 @@
         // Check write permissions only after determining which table the insert will touch
         checkWritePermissions(args);
 
-        checkUserRestrictions(name);
+        checkUserRestrictions(name, desiredUserHandle);
 
         // The global table is stored under the owner, always
         if (TABLE_GLOBAL.equals(args.table)) {
@@ -1143,7 +1150,7 @@
             callingUser = UserHandle.USER_OWNER;
         }
         checkWritePermissions(args);
-        checkUserRestrictions(initialValues.getAsString(Settings.Secure.NAME));
+        checkUserRestrictions(initialValues.getAsString(Settings.Secure.NAME), callingUser);
 
         final AtomicInteger mutationCount = sKnownMutationsInFlight.get(callingUser);
         mutationCount.incrementAndGet();
diff --git a/packages/Shell/AndroidManifest.xml b/packages/Shell/AndroidManifest.xml
index 6f41565..9f9dc23 100644
--- a/packages/Shell/AndroidManifest.xml
+++ b/packages/Shell/AndroidManifest.xml
@@ -85,11 +85,13 @@
     <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS" />
     <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS_FULL" />
     <uses-permission android:name="android.permission.MANAGE_USERS" />
+    <uses-permission android:name="android.permission.MANAGE_DEVICE_ADMINS" />
     <uses-permission android:name="android.permission.BLUETOOTH_STACK" />
     <uses-permission android:name="android.permission.GET_ACCOUNTS" />
     <uses-permission android:name="android.permission.RETRIEVE_WINDOW_TOKEN" />
     <uses-permission android:name="android.permission.FRAME_STATS" />
     <uses-permission android:name="android.permission.BIND_APPWIDGET" />
+    <uses-permission android:name="android.permission.UPDATE_APP_OPS_STATS" />
 
     <application android:label="@string/app_label">
         <provider
diff --git a/packages/Shell/res/values-cs/strings.xml b/packages/Shell/res/values-cs/strings.xml
index 10ef1a6c..d321159 100644
--- a/packages/Shell/res/values-cs/strings.xml
+++ b/packages/Shell/res/values-cs/strings.xml
@@ -16,7 +16,7 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="3701846017049540910">"Prostředí"</string>
+    <string name="app_label" msgid="3701846017049540910">"Shell"</string>
     <string name="bugreport_finished_title" msgid="2293711546892863898">"Bylo vytvořeno chybové hlášení"</string>
     <string name="bugreport_finished_text" product="watch" msgid="8389172248433597683">"Chcete-li hlášení chyby sdílet, přejeďte doleva."</string>
     <string name="bugreport_finished_text" product="default" msgid="3559904746859400732">"Chybové hlášení můžete sdílet klepnutím."</string>
diff --git a/packages/Shell/res/values-eu-rES/strings.xml b/packages/Shell/res/values-eu-rES/strings.xml
index 2bf91ad..2904cbb 100644
--- a/packages/Shell/res/values-eu-rES/strings.xml
+++ b/packages/Shell/res/values-eu-rES/strings.xml
@@ -20,6 +20,6 @@
     <string name="bugreport_finished_title" msgid="2293711546892863898">"Programa-akatsen txostena jaso da"</string>
     <string name="bugreport_finished_text" product="watch" msgid="8389172248433597683">"Programa-akatsen txostena partekatzeko, pasatu hatza ezkerrera"</string>
     <string name="bugreport_finished_text" product="default" msgid="3559904746859400732">"Programa-akatsen txostena partekatzeko, ukitu"</string>
-    <string name="bugreport_confirm" msgid="5130698467795669780">"Errore-txostenek sistemaren erregistro-fitxategietako datuak dauzkate, informazio pertsonala eta pribatua barne. Errore-txostenak partekatzen badituzu, partekatu soilik aplikazio eta pertsona fidagarriekin."</string>
+    <string name="bugreport_confirm" msgid="5130698467795669780">"Programa-akatsen txostenek sistemaren erregistro-fitxategietako datuak dauzkate, informazio pertsonala eta pribatua barne. Programa-akatsen txostenak partekatzen badituzu, partekatu soilik aplikazio eta pertsona fidagarriekin."</string>
     <string name="bugreport_confirm_repeat" msgid="4926842460688645058">"Erakutsi mezu hau hurrengoan"</string>
 </resources>
diff --git a/packages/Shell/res/values-lt/strings.xml b/packages/Shell/res/values-lt/strings.xml
index 914ef46..a78b1db 100644
--- a/packages/Shell/res/values-lt/strings.xml
+++ b/packages/Shell/res/values-lt/strings.xml
@@ -17,9 +17,9 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="3701846017049540910">"Apvalkalas"</string>
-    <string name="bugreport_finished_title" msgid="2293711546892863898">"Trikčių ataskaita užfiksuota"</string>
-    <string name="bugreport_finished_text" product="watch" msgid="8389172248433597683">"Perbraukite kairėn, kad bendrintumėte trikties ataskaitą"</string>
-    <string name="bugreport_finished_text" product="default" msgid="3559904746859400732">"Palieskite, kad bendrintumėte trikčių ataskaitą"</string>
-    <string name="bugreport_confirm" msgid="5130698467795669780">"Trikčių ataskaitose pateikiami duomenys iš įvairių sistemos žurnalo failų, įskaitant asmeninę ir privačią informaciją. Trikčių ataskaitas bendrinkite tik su patikimomis programomis ir žmonėmis."</string>
+    <string name="bugreport_finished_title" msgid="2293711546892863898">"Riktų ataskaita užfiksuota"</string>
+    <string name="bugreport_finished_text" product="watch" msgid="8389172248433597683">"Perbraukite kairėn, kad bendrintumėte rikto ataskaitą"</string>
+    <string name="bugreport_finished_text" product="default" msgid="3559904746859400732">"Palieskite, kad bendrintumėte riktų ataskaitą"</string>
+    <string name="bugreport_confirm" msgid="5130698467795669780">"Riktų ataskaitose pateikiami duomenys iš įvairių sistemos žurnalo failų, įskaitant asmeninę ir privačią informaciją. Riktų ataskaitas bendrinkite tik su patikimomis programomis ir žmonėmis."</string>
     <string name="bugreport_confirm_repeat" msgid="4926842460688645058">"Rodyti šį pranešimą kitą kartą"</string>
 </resources>
diff --git a/packages/Shell/res/values-zh-rHK/strings.xml b/packages/Shell/res/values-zh-rHK/strings.xml
index 0d56d76..f2e034b 100644
--- a/packages/Shell/res/values-zh-rHK/strings.xml
+++ b/packages/Shell/res/values-zh-rHK/strings.xml
@@ -20,6 +20,6 @@
     <string name="bugreport_finished_title" msgid="2293711546892863898">"已擷取錯誤報告"</string>
     <string name="bugreport_finished_text" product="watch" msgid="8389172248433597683">"向左滑動即可分享錯誤報告"</string>
     <string name="bugreport_finished_text" product="default" msgid="3559904746859400732">"輕觸即可分享您的錯誤報告"</string>
-    <string name="bugreport_confirm" msgid="5130698467795669780">"錯誤報告中有來自系統各個記錄檔案的資料,包括個人和私人資料。請只與您信任的應用程式和用戶分享錯誤報告。"</string>
+    <string name="bugreport_confirm" msgid="5130698467795669780">"錯誤報告中有來自系統各個記錄檔案的資料,包括個人和私人資料。請只與您信任的應用程式和使用者分享錯誤報告。"</string>
     <string name="bugreport_confirm_repeat" msgid="4926842460688645058">"下次再顯示這則訊息"</string>
 </resources>
diff --git a/packages/Shell/src/com/android/shell/BugreportReceiver.java b/packages/Shell/src/com/android/shell/BugreportReceiver.java
index 7a659ee..02a3aeb 100644
--- a/packages/Shell/src/com/android/shell/BugreportReceiver.java
+++ b/packages/Shell/src/com/android/shell/BugreportReceiver.java
@@ -84,14 +84,17 @@
         }
         notifIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
 
-        final Notification.Builder builder = new Notification.Builder(context);
-        builder.setSmallIcon(com.android.internal.R.drawable.stat_sys_adb);
-        builder.setContentTitle(context.getString(R.string.bugreport_finished_title));
-        builder.setTicker(context.getString(R.string.bugreport_finished_title));
-        builder.setContentText(context.getString(R.string.bugreport_finished_text));
-        builder.setContentIntent(PendingIntent.getActivity(
-                context, 0, notifIntent, PendingIntent.FLAG_CANCEL_CURRENT));
-        builder.setAutoCancel(true);
+        final Notification.Builder builder = new Notification.Builder(context)
+                .setSmallIcon(com.android.internal.R.drawable.stat_sys_adb)
+                .setContentTitle(context.getString(R.string.bugreport_finished_title))
+                .setTicker(context.getString(R.string.bugreport_finished_title))
+                .setContentText(context.getString(R.string.bugreport_finished_text))
+                .setContentIntent(PendingIntent.getActivity(
+                        context, 0, notifIntent, PendingIntent.FLAG_CANCEL_CURRENT))
+                .setAutoCancel(true)
+                .setColor(context.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
+
         NotificationManager.from(context).notify(TAG, 0, builder.build());
 
         // Clean up older bugreports in background
diff --git a/packages/SystemUI/AndroidManifest.xml b/packages/SystemUI/AndroidManifest.xml
index b8836a0..bddd691 100644
--- a/packages/SystemUI/AndroidManifest.xml
+++ b/packages/SystemUI/AndroidManifest.xml
@@ -111,7 +111,7 @@
     <uses-permission android:name="android.permission.CAMERA" />
 
     <!-- Screen Capturing -->
-    <uses-permission android:name="android.permission.CREATE_MEDIA_PROJECTION" />
+    <uses-permission android:name="android.permission.MANAGE_MEDIA_PROJECTION" />
 
     <application
         android:name=".SystemUIApplication"
@@ -176,6 +176,7 @@
                 android:theme="@style/RecentsStyle"
                 android:excludeFromRecents="true"
                 android:launchMode="singleInstance"
+                android:resumeWhilePausing="true"
                 android:exported="true">
           <intent-filter>
             <action android:name="com.android.systemui.TOGGLE_RECENTS" />
@@ -196,7 +197,9 @@
                   android:label="@string/accessibility_desc_recent_apps"
                   android:launchMode="singleInstance"
                   android:excludeFromRecents="true"
-                  android:theme="@style/RecentsTheme">
+                  android:stateNotNeeded="true"
+                  android:resumeWhilePausing="true"
+                  android:theme="@style/config_recents_activity_theme">
             <intent-filter>
                 <action android:name="com.android.systemui.recents.TOGGLE_RECENTS" />
             </intent-filter>
@@ -280,6 +283,21 @@
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
                 <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+
+        <activity android:name=".egg.LLandActivity"
+                  android:theme="@android:style/Theme.Material.Light.NoActionBar.TranslucentDecor"
+                  android:exported="true"
+                  android:label="@string/lland"
+                  android:hardwareAccelerated="true"
+                  android:launchMode="singleInstance"
+                  android:screenOrientation="locked"
+                  android:process=":sweetsweetdesserts"
+                  android:excludeFromRecents="true">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN"/>
+                <category android:name="android.intent.category.DEFAULT" />
                 <category android:name="com.android.internal.category.PLATLOGO" />
             </intent-filter>
         </activity>
@@ -338,10 +356,11 @@
             </intent-filter>
         </activity>
 
-        <!-- I dream of notifications -->
+        <!-- Doze with notifications, run in main sysui process for every user  -->
         <service
             android:name=".doze.DozeService"
             android:exported="true"
+            android:singleUser="true"
             android:permission="android.permission.BIND_DREAM_SERVICE" />
     </application>
 </manifest>
diff --git a/packages/SystemUI/proguard.flags b/packages/SystemUI/proguard.flags
index c9e1618..47e24e8 100644
--- a/packages/SystemUI/proguard.flags
+++ b/packages/SystemUI/proguard.flags
@@ -1,8 +1,11 @@
 -keep class com.android.systemui.statusbar.policy.KeyButtonView {
   public float getDrawingAlpha();
+  public void setDrawingAlpha(float);
+}
+
+-keep class com.android.systemui.statusbar.policy.KeyButtonRipple {
   public float getGlowAlpha();
   public float getGlowScale();
-  public void setDrawingAlpha(float);
   public void setGlowAlpha(float);
   public void setGlowScale(float);
 }
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect1_scale.xml b/packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect1_scale.xml
similarity index 100%
rename from core/res/res/anim/progress_indeterminate_horizontal_rect1_scale.xml
rename to packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect1_scale.xml
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect1_translate.xml b/packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect1_translate.xml
similarity index 100%
rename from core/res/res/anim/progress_indeterminate_horizontal_rect1_translate.xml
rename to packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect1_translate.xml
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect2_scale.xml b/packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect2_scale.xml
similarity index 100%
rename from core/res/res/anim/progress_indeterminate_horizontal_rect2_scale.xml
rename to packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect2_scale.xml
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect2_translate.xml b/packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect2_translate.xml
similarity index 100%
rename from core/res/res/anim/progress_indeterminate_horizontal_rect2_translate.xml
rename to packages/SystemUI/res/anim/progress_indeterminate_horizontal_rect2_translate.xml
diff --git a/packages/SystemUI/res/anim/recents_from_launcher_enter.xml b/packages/SystemUI/res/anim/recents_from_launcher_enter.xml
index 305a82f..b191e62 100644
--- a/packages/SystemUI/res/anim/recents_from_launcher_enter.xml
+++ b/packages/SystemUI/res/anim/recents_from_launcher_enter.xml
@@ -20,9 +20,9 @@
 <set xmlns:android="http://schemas.android.com/apk/res/android"
      android:shareInterpolator="false"
      android:zAdjustment="normal">
-  <alpha android:fromAlpha="1.0" android:toAlpha="1.0"
+  <alpha android:fromAlpha="0.0" android:toAlpha="1.0"
          android:fillEnabled="true"
          android:fillBefore="true" android:fillAfter="true"
          android:interpolator="@android:interpolator/linear"
-         android:duration="200"/>
+         android:duration="150"/>
 </set>
diff --git a/packages/SystemUI/res/anim/recents_from_launcher_exit.xml b/packages/SystemUI/res/anim/recents_from_launcher_exit.xml
index 863591f..fa6caf2 100644
--- a/packages/SystemUI/res/anim/recents_from_launcher_exit.xml
+++ b/packages/SystemUI/res/anim/recents_from_launcher_exit.xml
@@ -24,5 +24,5 @@
          android:fillEnabled="true"
          android:fillBefore="true" android:fillAfter="true"
          android:interpolator="@android:interpolator/linear_out_slow_in"
-         android:duration="200"/>
+         android:duration="150"/>
 </set>
diff --git a/packages/SystemUI/res/anim/recents_from_search_launcher_enter.xml b/packages/SystemUI/res/anim/recents_from_search_launcher_enter.xml
new file mode 100644
index 0000000..20e7764
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_from_search_launcher_enter.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2012, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:shareInterpolator="false"
+     android:zAdjustment="normal">
+  <alpha android:fromAlpha="0.0" android:toAlpha="1.0"
+         android:fillEnabled="true"
+         android:fillBefore="true" android:fillAfter="true"
+         android:interpolator="@android:interpolator/linear"
+         android:duration="50"/>
+</set>
diff --git a/packages/SystemUI/res/anim/recents_from_search_launcher_exit.xml b/packages/SystemUI/res/anim/recents_from_search_launcher_exit.xml
new file mode 100644
index 0000000..92a8882
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_from_search_launcher_exit.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2012, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:shareInterpolator="false"
+     android:zAdjustment="top">
+  <alpha android:fromAlpha="1.0" android:toAlpha="0.0"
+  		 android:startOffset="50"
+         android:fillEnabled="true"
+         android:fillBefore="true" android:fillAfter="true"
+         android:interpolator="@android:interpolator/linear_out_slow_in"
+         android:duration="100"/>
+</set>
diff --git a/packages/SystemUI/res/anim/recents_from_unknown_enter.xml b/packages/SystemUI/res/anim/recents_from_unknown_enter.xml
index f68a143..da1dee0 100644
--- a/packages/SystemUI/res/anim/recents_from_unknown_enter.xml
+++ b/packages/SystemUI/res/anim/recents_from_unknown_enter.xml
@@ -23,6 +23,6 @@
   <alpha android:fromAlpha="0.0" android:toAlpha="1.0"
          android:fillEnabled="true"
          android:fillBefore="true" android:fillAfter="true"
-         android:interpolator="@android:interpolator/fast_out_slow_in"
+         android:interpolator="@android:interpolator/linear"
          android:duration="200"/>
 </set>
diff --git a/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_bounce.xml b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_bounce.xml
new file mode 100644
index 0000000..a571cbc
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_bounce.xml
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="normal">
+
+    <alpha android:fromAlpha="1.0" android:toAlpha="0.6"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:interpolator="@android:interpolator/accelerate_cubic"
+        android:duration="133"/>
+
+    <translate android:fromYDelta="0" android:toYDelta="10%"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:interpolator="@android:interpolator/accelerate_cubic"
+        android:duration="350"/>
+
+    <scale android:fromXScale="1.0" android:toXScale="0.9"
+        android:fromYScale="1.0" android:toYScale="0.9"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:pivotX="50%p" android:pivotY="50%p"
+        android:interpolator="@android:interpolator/fast_out_slow_in"
+        android:duration="350" />
+
+    <alpha android:fromAlpha="1.0" android:toAlpha="1.6666666666"
+        android:fillEnabled="true" android:fillBefore="false" android:fillAfter="true"
+        android:interpolator="@android:interpolator/decelerate_cubic"
+        android:startOffset="350"
+        android:duration="133"/>
+
+    <translate android:fromYDelta="0%" android:toYDelta="-8.8888888888%"
+        android:fillEnabled="true" android:fillBefore="false" android:fillAfter="true"
+        android:interpolator="@android:interpolator/decelerate_cubic"
+        android:startOffset="350"
+        android:duration="350"/>
+
+    <scale android:fromXScale="1.0" android:toXScale="1.1111111111"
+        android:fromYScale="1.0" android:toYScale="1.1111111111"
+        android:fillEnabled="true" android:fillBefore="false" android:fillAfter="true"
+        android:pivotX="50%p" android:pivotY="50%p"
+        android:interpolator="@android:interpolator/decelerate_cubic"
+        android:startOffset="350"
+        android:duration="350" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_source.xml b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_source.xml
new file mode 100644
index 0000000..f0fd684
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_source.xml
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="normal">
+
+    <alpha android:fromAlpha="1.0" android:toAlpha="0.6"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:interpolator="@android:interpolator/accelerate_cubic"
+        android:duration="150"/>
+
+    <scale android:fromXScale="1.0" android:toXScale="0.9"
+        android:fromYScale="1.0" android:toYScale="0.9"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:pivotX="50%p" android:pivotY="50%p"
+        android:interpolator="@android:interpolator/fast_out_slow_in"
+        android:duration="300" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_target.xml b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_target.xml
new file mode 100644
index 0000000..170ac82
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_next_affiliated_task_target.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="top">
+
+    <translate android:fromYDelta="110%" android:toYDelta="0%"
+               android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+               android:interpolator="@android:interpolator/decelerate_quint"
+               android:startOffset="50"
+               android:duration="250" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_bounce.xml b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_bounce.xml
new file mode 100644
index 0000000..46045ac
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_bounce.xml
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="top">
+
+    <translate android:fromYDelta="0%" android:toYDelta="10%"
+               android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+               android:interpolator="@android:interpolator/decelerate_quint"
+               android:duration="300" />
+
+    <translate android:fromYDelta="10%" android:toYDelta="0%"
+               android:fillEnabled="true" android:fillBefore="false" android:fillAfter="true"
+               android:interpolator="@android:interpolator/accelerate_quint"
+               android:startOffset="300"
+               android:duration="300" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_source.xml b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_source.xml
new file mode 100644
index 0000000..ad5341b
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_source.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="top">
+
+    <translate android:fromYDelta="0%" android:toYDelta="110%"
+               android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+               android:interpolator="@android:interpolator/accelerate_quint"
+               android:duration="300" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_target.xml b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_target.xml
new file mode 100644
index 0000000..7687f02
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_launch_prev_affiliated_task_target.xml
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:background="#ff000000" android:shareInterpolator="false" android:zAdjustment="normal">
+
+    <alpha android:fromAlpha="0.6" android:toAlpha="1.0"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:interpolator="@android:interpolator/decelerate_cubic"
+        android:startOffset="75"
+        android:duration="150"/>
+
+    <scale android:fromXScale="0.9" android:toXScale="1.0"
+        android:fromYScale="0.9" android:toYScale="1.0"
+        android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+        android:interpolator="@android:interpolator/linear_out_slow_in"
+        android:pivotX="50%p" android:pivotY="50%p"
+        android:startOffset="75"
+        android:duration="225" />
+</set>
\ No newline at end of file
diff --git a/packages/SystemUI/res/anim/recents_to_launcher_enter.xml b/packages/SystemUI/res/anim/recents_to_launcher_enter.xml
index adcefe0..b191e62 100644
--- a/packages/SystemUI/res/anim/recents_to_launcher_enter.xml
+++ b/packages/SystemUI/res/anim/recents_to_launcher_enter.xml
@@ -23,6 +23,6 @@
   <alpha android:fromAlpha="0.0" android:toAlpha="1.0"
          android:fillEnabled="true"
          android:fillBefore="true" android:fillAfter="true"
-         android:interpolator="@android:interpolator/fast_out_linear_in"
-         android:duration="200"/>
+         android:interpolator="@android:interpolator/linear"
+         android:duration="150"/>
 </set>
diff --git a/packages/SystemUI/res/anim/recents_to_launcher_exit.xml b/packages/SystemUI/res/anim/recents_to_launcher_exit.xml
index 863591f..fa6caf2 100644
--- a/packages/SystemUI/res/anim/recents_to_launcher_exit.xml
+++ b/packages/SystemUI/res/anim/recents_to_launcher_exit.xml
@@ -24,5 +24,5 @@
          android:fillEnabled="true"
          android:fillBefore="true" android:fillAfter="true"
          android:interpolator="@android:interpolator/linear_out_slow_in"
-         android:duration="200"/>
+         android:duration="150"/>
 </set>
diff --git a/packages/SystemUI/res/anim/recents_to_search_launcher_enter.xml b/packages/SystemUI/res/anim/recents_to_search_launcher_enter.xml
new file mode 100644
index 0000000..4e1d66d
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_to_search_launcher_enter.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2012, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:shareInterpolator="false"
+     android:zAdjustment="normal">
+  <alpha android:fromAlpha="0.0" android:toAlpha="1.0"
+         android:fillEnabled="true"
+         android:fillBefore="true" android:fillAfter="true"
+         android:interpolator="@android:interpolator/linear"
+         android:duration="100"/>
+</set>
diff --git a/packages/SystemUI/res/anim/recents_to_search_launcher_exit.xml b/packages/SystemUI/res/anim/recents_to_search_launcher_exit.xml
new file mode 100644
index 0000000..d7a12a4
--- /dev/null
+++ b/packages/SystemUI/res/anim/recents_to_search_launcher_exit.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2012, 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.
+*/
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android"
+     android:shareInterpolator="false"
+     android:zAdjustment="top">
+  <alpha android:fromAlpha="1.0" android:toAlpha="0.0"
+  		 android:startOffset="100"
+         android:fillEnabled="true"
+         android:fillBefore="true" android:fillAfter="true"
+         android:interpolator="@android:interpolator/linear"
+         android:duration="50"/>
+</set>
diff --git a/packages/SystemUI/res/anim/search_launch_enter.xml b/packages/SystemUI/res/anim/search_launch_enter.xml
index f3333b7..19c0a95 100644
--- a/packages/SystemUI/res/anim/search_launch_enter.xml
+++ b/packages/SystemUI/res/anim/search_launch_enter.xml
@@ -17,16 +17,8 @@
 */
 -->
 
-<set xmlns:android="http://schemas.android.com/apk/res/android"
-        android:shareInterpolator="false" android:zAdjustment="top">
-
-    <alpha android:fromAlpha="0" android:toAlpha="1.0"
-            android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
-            android:interpolator="@android:interpolator/decelerate_cubic"
-            android:duration="300"/>
-
-    <translate android:fromYDelta="100%" android:toYDelta="0"
-            android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
-            android:interpolator="@android:interpolator/decelerate_cubic"
-            android:duration="300" />
-</set>
+<alpha xmlns:android="http://schemas.android.com/apk/res/android"
+       android:fromAlpha="0" android:toAlpha="1.0"
+       android:fillEnabled="true" android:fillBefore="true" android:fillAfter="true"
+       android:interpolator="@android:interpolator/decelerate_cubic"
+       android:duration="300"/>
\ No newline at end of file
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_ime_switcher_default.png b/packages/SystemUI/res/drawable-hdpi/ic_ime_switcher_default.png
deleted file mode 100644
index 369c88d..0000000
--- a/packages/SystemUI/res/drawable-hdpi/ic_ime_switcher_default.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_available.png b/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_available.png
deleted file mode 100644
index f256fbb..0000000
--- a/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_available.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_connected.png b/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_connected.png
deleted file mode 100644
index b946ec9..0000000
--- a/packages/SystemUI/res/drawable-hdpi/ic_qs_cast_connected.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back.png
index b28624f..5be74ec 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_ime.png
index 9ce434d..305c9fb 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_land.png
index 51dce69..3e676ab 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home.png
index 3f3e288..d3e1f7a 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home_land.png
index 9856cbf..d632600 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu.png
index 6910456..8984a49d 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu_land.png
index e8c6ec6..2e8f8f0 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent.png
index 06dcd20..ec499d4 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent_land.png
index 240f536..13e8a4f 100644
--- a/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-hdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/stat_notify_more.png b/packages/SystemUI/res/drawable-hdpi/stat_notify_more.png
deleted file mode 100644
index 2fa0293..0000000
--- a/packages/SystemUI/res/drawable-hdpi/stat_notify_more.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/stat_sys_device_access_location_found.png b/packages/SystemUI/res/drawable-hdpi/stat_sys_device_access_location_found.png
deleted file mode 100644
index d43d1dc..0000000
--- a/packages/SystemUI/res/drawable-hdpi/stat_sys_device_access_location_found.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-hdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-hdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index dcf86c0..0000000
--- a/packages/SystemUI/res/drawable-hdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back.png
index e464347..c697da7 100644
--- a/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back_land.png
index f8b59e8..94404df 100644
--- a/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-hdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-hdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-ldrtl-hdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 5171333..0000000
--- a/packages/SystemUI/res/drawable-ldrtl-hdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back.png
index 1b578a6..9d0014d 100644
--- a/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back_land.png
index 80ecaba..9a8b0e9 100644
--- a/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-mdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-mdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-ldrtl-mdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 1b45762..0000000
--- a/packages/SystemUI/res/drawable-ldrtl-mdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back.png
index c7bf2c7..80d60af 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back_land.png
index 278de42..2dfe964 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-hdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back.png
index 464831c..fd1cc27 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back_land.png
index c24132c..183aa0d 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-mdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back.png
index bc84f22..6f763a4 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back_land.png
index f4e219e..3dc75a3 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back.png
index ece2e37..83040fd 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back_land.png
index d524dcf..9917be4 100644
--- a/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-sw600dp-xxhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back.png
index 373e84a..c116bbe 100644
--- a/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back_land.png
index e5a102a..1446850 100644
--- a/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-xhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xhdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-ldrtl-xhdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index fcbfac1..0000000
--- a/packages/SystemUI/res/drawable-ldrtl-xhdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back.png
index 6b19593..83040fd 100644
--- a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back_land.png
index a5e0686..9917be4 100644
--- a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-ldrtl-xxhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-ldrtl-xxhdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 4555731..0000000
--- a/packages/SystemUI/res/drawable-ldrtl-xxhdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_ime_switcher_default.png b/packages/SystemUI/res/drawable-mdpi/ic_ime_switcher_default.png
deleted file mode 100644
index 7d97eb5..0000000
--- a/packages/SystemUI/res/drawable-mdpi/ic_ime_switcher_default.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_available.png b/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_available.png
deleted file mode 100644
index b1e984c..0000000
--- a/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_available.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_connected.png b/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_connected.png
deleted file mode 100644
index ceda1bb..0000000
--- a/packages/SystemUI/res/drawable-mdpi/ic_qs_cast_connected.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back.png
index f878093..447c655 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_ime.png
index 7780b16..d5ca622 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_land.png
index 343d0dd..47985de 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home.png
index 8e9583b..7b5fe8b 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home_land.png
index 7d38703..9fcb705 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu.png
index 6e186a3..23c24ba 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu_land.png
index 12b4042..41c1acb 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent.png
index e2a89c3..11a92f0 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent_land.png
index 311720b..7fb14a8 100644
--- a/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-mdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/stat_notify_more.png b/packages/SystemUI/res/drawable-mdpi/stat_notify_more.png
deleted file mode 100644
index d7a48f2..0000000
--- a/packages/SystemUI/res/drawable-mdpi/stat_notify_more.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/stat_sys_device_access_location_found.png b/packages/SystemUI/res/drawable-mdpi/stat_sys_device_access_location_found.png
deleted file mode 100644
index 61d7511..0000000
--- a/packages/SystemUI/res/drawable-mdpi/stat_sys_device_access_location_found.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-mdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-mdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 14d1060..0000000
--- a/packages/SystemUI/res/drawable-mdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back.png
index 67e4ee7..eaac305 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_ime.png
index dfef430..b5d3739 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_land.png
index de6d109..9915260 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home.png
index 7d0c3fbe..4a349e2 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home_land.png
index 3baeb52..d14da80 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu.png
index d5b48e8..4f5e723 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu_land.png
index 26d7e7b..05b9b44 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent.png
index c49198d..2035323 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent_land.png
index 2a21f29..69b541b 100644
--- a/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-hdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back.png
index 538d7d1..3f2b8b4 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_ime.png
index eb8e80b..23e5e8f 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_land.png
index 1c2c35a..4b7f3ac 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home.png
index eec613f..41054f6 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home_land.png
index 1c0bad8..e4a7181 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu.png
index 1293fa8..be678e0 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu_land.png
index 96a9cce..24d37e0 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent.png
index 9ffc80a..9443656 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent_land.png
index aa9b57b..c3c64f4 100644
--- a/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-mdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back.png
index b343522..0ab43ce 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_ime.png
index f2f7b50..3c58211 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_land.png
index 383398c..14ff6d3 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home.png
index 53444ab..eb74d0d 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home_land.png
index 4294937..e29c9d0 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu.png
index 7cb3ee4..cfecdcf 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu_land.png
index b017946..d98208a 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent.png
index e8dd07c..71cc61b 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent_land.png
index f396ea9..bdecf06 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xhdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back.png
index 1b817cf..01edd86 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_ime.png
index 21b7a06..52bd6e8 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_land.png
index 676fc14..b0dd0f0 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home.png
index 26f4ba9..b5c189d 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home_land.png
index ea21b60..42e9e31 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu.png
index c7d77c2..669d8ba 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu_land.png
index ae12cfd..0fbf1f6 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent.png
index 8c27d45..023b94c 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent_land.png
index c98827c..5884492 100644
--- a/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-sw600dp-xxhdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_ime_switcher_default.png b/packages/SystemUI/res/drawable-xhdpi/ic_ime_switcher_default.png
deleted file mode 100644
index 900801a..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/ic_ime_switcher_default.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_available.png b/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_available.png
deleted file mode 100644
index 47be502..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_available.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_connected.png b/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_connected.png
deleted file mode 100644
index 4b12809..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/ic_qs_cast_connected.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back.png
index ec2951d..4956aad 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_ime.png
index 5103190..e9a6223 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_land.png
index 818aa4f..e9767a1 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home.png
index 254f757..acaf32d 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home_land.png
index f0de417..20cb101 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu.png
index 97f1526..cc620a2 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu_land.png
index 773fa94..aa8a60e 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent.png
index 8a8e941..88d6a41 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent_land.png
index ad7dfc3..8acdd3c 100644
--- a/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-xhdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/stat_notify_more.png b/packages/SystemUI/res/drawable-xhdpi/stat_notify_more.png
deleted file mode 100644
index 64327ba..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/stat_notify_more.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/stat_sys_device_access_location_found.png b/packages/SystemUI/res/drawable-xhdpi/stat_sys_device_access_location_found.png
deleted file mode 100644
index 192d3f7..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/stat_sys_device_access_location_found.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xhdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-xhdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 95c217c..0000000
--- a/packages/SystemUI/res/drawable-xhdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_ime_switcher_default.png b/packages/SystemUI/res/drawable-xxhdpi/ic_ime_switcher_default.png
deleted file mode 100644
index 6c8222e..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_ime_switcher_default.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_available.png b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_available.png
deleted file mode 100644
index 8e225af..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_available.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_connected.png b/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_connected.png
deleted file mode 100644
index 937202b..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_qs_cast_connected.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back.png
index 77969b8..01edd86 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_ime.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_ime.png
index b171f92..52bd6e8 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_ime.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_ime.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_land.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_land.png
index ad35c65..b0dd0f0 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_land.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_back_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home.png
index d60229f..b5c189d 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home_land.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home_land.png
index 8fffa8e..42e9e31 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home_land.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_home_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu.png
index 9215055..669d8ba 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu_land.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu_land.png
index bcf7eb1..0fbf1f6 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu_land.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_menu_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent.png
index a261f85..023b94c 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent_land.png b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent_land.png
index 4c612f7..5884492 100644
--- a/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent_land.png
+++ b/packages/SystemUI/res/drawable-xxhdpi/ic_sysbar_recent_land.png
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/stat_notify_more.png b/packages/SystemUI/res/drawable-xxhdpi/stat_notify_more.png
deleted file mode 100644
index 3c33a56..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/stat_notify_more.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/stat_sys_device_access_location_found.png b/packages/SystemUI/res/drawable-xxhdpi/stat_sys_device_access_location_found.png
deleted file mode 100644
index 1e5f15f..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/stat_sys_device_access_location_found.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/stat_sys_signal_flightmode.png b/packages/SystemUI/res/drawable-xxhdpi/stat_sys_signal_flightmode.png
deleted file mode 100644
index 155c222..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/stat_sys_signal_flightmode.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable-xxhdpi/title_bar_shadow.9.png b/packages/SystemUI/res/drawable-xxhdpi/title_bar_shadow.9.png
deleted file mode 100644
index e86f891..0000000
--- a/packages/SystemUI/res/drawable-xxhdpi/title_bar_shadow.9.png
+++ /dev/null
Binary files differ
diff --git a/packages/SystemUI/res/drawable/android.xml b/packages/SystemUI/res/drawable/android.xml
new file mode 100644
index 0000000..750de05
--- /dev/null
+++ b/packages/SystemUI/res/drawable/android.xml
@@ -0,0 +1,37 @@
+<!--
+Copyright (C) 2014 The Android Open Source Project
+
+   Licensed under the Apache License, Version 2 (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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48dp"
+        android:height="48dp"
+        android:viewportWidth="48"
+        android:viewportHeight="48">
+    <path
+        android:name="torso"
+        android:pathData="M12,36c0,1.1 0.9,2 2,2l2,0l0,7c0,1.7 1.3,3 3,3c1.7,0 3,-1.3 3,-3l0,-7l4,0l0,7c0,1.7 1.3,3 3,3c1.7,0 3,-1.3 3,-3l0,-7l2,0c1.1,0 2,-0.9 2,-2L36,16L12,16L12,36z"
+        android:fillColor="#FFFFFF"/>
+    <path
+        android:name="leftArm"
+        android:pathData="M7,16c-1.7,0 -3,1.3 -3,3l0,14c0,1.7 1.3,3 3,3c1.7,0 3,-1.3 3,-3L10,19C10,17.3 8.7,16 7,16z"
+        android:fillColor="#FFFFFF"/>
+    <path
+        android:name="rightArm"
+        android:pathData="M41,16c-1.7,0 -3,1.3 -3,3l0,14c0,1.7 1.3,3 3,3c1.7,0 3,-1.3 3,-3L44,19C44,17.3 42.7,16 41,16z"
+        android:fillColor="#FFFFFF"/>
+    <path
+        android:name="illFormTheHead"
+        android:pathData="M31.1,4.3l2.6,-2.6c0.4,-0.4 0.4,-1 0,-1.4c-0.4,-0.4 -1,-0.4 -1.4,0l-3,3C27.7,2.5 25.9,2 24,2c-1.9,0 -3.7,0.5 -5.3,1.3l-3,-3c-0.4,-0.4 -1,-0.4 -1.4,0c-0.4,0.4 -0.4,1 0,1.4l2.6,2.6C13.9,6.5 12,10 12,14l24,0C36,10 34.1,6.5 31.1,4.3zM20.31,9c0,0.72 -0.59,1.31 -1.31,1.31c-0.72,0 -1.31,-0.59 -1.31,-1.31c0,-0.72 0.59,-1.31 1.31,-1.31C19.72,7.69 20.31,8.28 20.31,9zM30.31,9c0,0.72 -0.59,1.31 -1.31,1.31c-0.73,0 -1.31,-0.59 -1.31,-1.31c0,-0.72 0.59,-1.31 1.31,-1.31C29.72,7.69 30.31,8.28 30.31,9z"
+        android:fillColor="#FFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/cloud.xml b/packages/SystemUI/res/drawable/cloud.xml
new file mode 100644
index 0000000..17e4ad2
--- /dev/null
+++ b/packages/SystemUI/res/drawable/cloud.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:pathData="M38.700001,20.100000C37.299999,13.200000 31.299999,8.000000 24.000000,8.000000c-5.800000,0.000000 -10.800000,3.300000 -13.300000,8.100000C4.700000,16.700001 0.000000,21.799999 0.000000,28.000000c0.000000,6.600000 5.400000,12.000000 12.000000,12.000000l26.000000,0.000000c5.500000,0.000000 10.000000,-4.500000 10.000000,-10.000000C48.000000,24.700001 43.900002,20.400000 38.700001,20.100000z"
+        android:fillColor="#FFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/cloud_off.xml b/packages/SystemUI/res/drawable/cloud_off.xml
new file mode 100644
index 0000000..b15ea5f
--- /dev/null
+++ b/packages/SystemUI/res/drawable/cloud_off.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M19.400000,10.000000c-0.700000,-3.400000 -3.700000,-6.000000 -7.400000,-6.000000c-1.500000,0.000000 -2.900000,0.400000 -4.000000,1.200000l1.500000,1.500000C10.200000,6.200000 11.100000,6.000000 12.000000,6.000000c3.000000,0.000000 5.500000,2.500000 5.500000,5.500000L17.500000,12.000000L19.000000,12.000000c1.700000,0.000000 3.000000,1.300000 3.000000,3.000000c0.000000,1.100000 -0.600000,2.100000 -1.600000,2.600000l1.500000,1.500000c1.300000,-0.900000 2.100000,-2.400000 2.100000,-4.100000C24.000000,12.400000 21.900000,10.200000 19.400000,10.000000zM3.000000,5.300000L5.800000,8.000000C2.600000,8.200000 0.000000,10.800000 0.000000,14.000000c0.000000,3.300000 2.700000,6.000000 6.000000,6.000000l11.700000,0.000000l2.000000,2.000000l1.300000,-1.300000L4.300000,4.000000L3.000000,5.300000zM7.700000,10.000000l8.000000,8.000000L6.000000,18.000000c-2.200000,0.000000 -4.000000,-1.800000 -4.000000,-4.000000c0.000000,-2.200000 1.800000,-4.000000 4.000000,-4.000000L7.700000,10.000000z"
+        android:fillColor="#FFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_account_circle.xml b/packages/SystemUI/res/drawable/ic_account_circle.xml
deleted file mode 100644
index d8649e5..0000000
--- a/packages/SystemUI/res/drawable/ic_account_circle.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-<!--
-Copyright (C) 2014 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.
--->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="24dp"
-        android:height="24dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
-
-    <group
-        android:scaleX="1.2"
-        android:scaleY="1.2"
-        android:pivotX="12.0"
-        android:pivotY="12.0">
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M12.0,2.0C6.5,2.0 2.0,6.5 2.0,12.0s4.5,10.0 10.0,10.0c5.5,0.0 10.0,-4.5 10.0,-10.0S17.5,2.0 12.0,2.0zM12.0,5.0c1.7,0.0 3.0,1.3 3.0,3.0c0.0,1.7 -1.3,3.0 -3.0,3.0c-1.7,0.0 -3.0,-1.3 -3.0,-3.0C9.0,6.3 10.3,5.0 12.0,5.0zM12.0,19.2c-2.5,0.0 -4.7,-1.3 -6.0,-3.2c0.0,-2.0 4.0,-3.1 6.0,-3.1c2.0,0.0 6.0,1.1 6.0,3.1C16.7,17.9 14.5,19.2 12.0,19.2z"/>
-    </group>
-</vector>
diff --git a/packages/SystemUI/res/drawable/ic_account_circle_qs.xml b/packages/SystemUI/res/drawable/ic_account_circle_qs.xml
deleted file mode 100644
index d10a96d..0000000
--- a/packages/SystemUI/res/drawable/ic_account_circle_qs.xml
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<!--
-  ~ Copyright (C) 2014 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
-  -->
-
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="24dp"
-        android:height="24dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
-
-    <group
-            android:scaleX="1.2"
-            android:scaleY="1.2"
-            android:pivotX="12.0"
-            android:pivotY="12.0">
-        <path
-                android:fillColor="@color/qs_user_detail_icon_muted"
-                android:pathData="M12.0,2.0C6.5,2.0 2.0,6.5 2.0,12.0s4.5,10.0 10.0,10.0c5.5,0.0 10.0,-4.5 10.0,-10.0S17.5,2.0 12.0,2.0zM12.0,5.0c1.7,0.0 3.0,1.3 3.0,3.0c0.0,1.7 -1.3,3.0 -3.0,3.0c-1.7,0.0 -3.0,-1.3 -3.0,-3.0C9.0,6.3 10.3,5.0 12.0,5.0zM12.0,19.2c-2.5,0.0 -4.7,-1.3 -6.0,-3.2c0.0,-2.0 4.0,-3.1 6.0,-3.1c2.0,0.0 6.0,1.1 6.0,3.1C16.7,17.9 14.5,19.2 12.0,19.2z"/>
-    </group>
-</vector>
diff --git a/packages/SystemUI/res/drawable/ic_android.xml b/packages/SystemUI/res/drawable/ic_android.xml
new file mode 100644
index 0000000..19ee9a7
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_android.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M6.000000,18.000000c0.000000,0.600000 0.400000,1.000000 1.000000,1.000000l1.000000,0.000000l0.000000,3.500000C8.000000,23.299999 8.700000,24.000000 9.500000,24.000000c0.800000,0.000000 1.500000,-0.700000 1.500000,-1.500000L11.000000,19.000000l2.000000,0.000000l0.000000,3.500000c0.000000,0.800000 0.700000,1.500000 1.500000,1.500000c0.800000,0.000000 1.500000,-0.700000 1.500000,-1.500000L16.000000,19.000000l1.000000,0.000000c0.600000,0.000000 1.000000,-0.400000 1.000000,-1.000000L18.000000,8.000000L6.000000,8.000000L6.000000,18.000000zM3.500000,8.000000C2.700000,8.000000 2.000000,8.700000 2.000000,9.500000l0.000000,7.000000C2.000000,17.299999 2.700000,18.000000 3.500000,18.000000C4.300000,18.000000 5.000000,17.299999 5.000000,16.500000l0.000000,-7.000000C5.000000,8.700000 4.300000,8.000000 3.500000,8.000000zM20.500000,8.000000C19.700001,8.000000 19.000000,8.700000 19.000000,9.500000l0.000000,7.000000c0.000000,0.800000 0.700000,1.500000 1.500000,1.500000c0.800000,0.000000 1.500000,-0.700000 1.500000,-1.500000l0.000000,-7.000000C22.000000,8.700000 21.299999,8.000000 20.500000,8.000000zM15.500000,2.200000l1.300000,-1.300000c0.200000,-0.200000 0.200000,-0.500000 0.000000,-0.700000c-0.200000,-0.200000 -0.500000,-0.200000 -0.700000,0.000000l-1.500000,1.500000C13.900000,1.200000 13.000000,1.000000 12.000000,1.000000c-1.000000,0.000000 -1.900000,0.200000 -2.700000,0.600000L7.900000,0.100000C7.700000,0.000000 7.300000,0.000000 7.100000,0.100000C7.000000,0.300000 7.000000,0.700000 7.100000,0.900000l1.300000,1.300000C7.000000,3.300000 6.000000,5.000000 6.000000,7.000000l12.000000,0.000000C18.000000,5.000000 17.000000,3.200000 15.500000,2.200000zM10.000000,5.000000L9.000000,5.000000L9.000000,4.000000l1.000000,0.000000L10.000000,5.000000zM15.000000,5.000000l-1.000000,0.000000L14.000000,4.000000l1.000000,0.000000L15.000000,5.000000z"
+        android:fillColor="#ffffffff"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_close.xml b/packages/SystemUI/res/drawable/ic_close.xml
new file mode 100644
index 0000000..7d93d45
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_close.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M19.000000,6.400000l-1.400000,-1.400000 -5.600000,5.600000 -5.600000,-5.600000 -1.400000,1.400000 5.600000,5.600000 -5.600000,5.600000 1.400000,1.400000 5.600000,-5.600000 5.600000,5.600000 1.400000,-1.400000 -5.600000,-5.600000z"
+        android:fillColor="#FF000000"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_ime_switcher_default.xml b/packages/SystemUI/res/drawable/ic_ime_switcher_default.xml
new file mode 100644
index 0000000..4d9ca88
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_ime_switcher_default.xml
@@ -0,0 +1,25 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M20.000000,5.000000L4.000000,5.000000C2.900000,5.000000 2.000000,5.900000 2.000000,7.000000l0.000000,10.000000c0.000000,1.100000 0.900000,2.000000 2.000000,2.000000l16.000000,0.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L22.000000,7.000000C22.000000,5.900000 21.100000,5.000000 20.000000,5.000000zM11.000000,8.000000l2.000000,0.000000l0.000000,2.000000l-2.000000,0.000000L11.000000,8.000000zM11.000000,11.000000l2.000000,0.000000l0.000000,2.000000l-2.000000,0.000000L11.000000,11.000000zM8.000000,8.000000l2.000000,0.000000l0.000000,2.000000L8.000000,10.000000L8.000000,8.000000zM8.000000,11.000000l2.000000,0.000000l0.000000,2.000000L8.000000,13.000000L8.000000,11.000000zM7.000000,13.000000L5.000000,13.000000l0.000000,-2.000000l2.000000,0.000000L7.000000,13.000000zM7.000000,10.000000L5.000000,10.000000L5.000000,8.000000l2.000000,0.000000L7.000000,10.000000zM16.000000,17.000000L8.000000,17.000000l0.000000,-2.000000l8.000000,0.000000L16.000000,17.000000zM16.000000,13.000000l-2.000000,0.000000l0.000000,-2.000000l2.000000,0.000000L16.000000,13.000000zM16.000000,10.000000l-2.000000,0.000000L14.000000,8.000000l2.000000,0.000000L16.000000,10.000000zM19.000000,13.000000l-2.000000,0.000000l0.000000,-2.000000l2.000000,0.000000L19.000000,13.000000zM19.000000,10.000000l-2.000000,0.000000L17.000000,8.000000l2.000000,0.000000L19.000000,10.000000z"
+        android:fillColor="@color/navigation_bar_icon_color"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_info.xml b/packages/SystemUI/res/drawable/ic_info.xml
new file mode 100644
index 0000000..65e7bf5
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_info.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="24.0dp"
+        android:height="24.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M12.000000,2.000000C6.500000,2.000000 2.000000,6.500000 2.000000,12.000000s4.500000,10.000000 10.000000,10.000000c5.500000,0.000000 10.000000,-4.500000 10.000000,-10.000000S17.500000,2.000000 12.000000,2.000000zM13.000000,17.000000l-2.000000,0.000000l0.000000,-6.000000l2.000000,0.000000L13.000000,17.000000zM13.000000,9.000000l-2.000000,0.000000L11.000000,7.000000l2.000000,0.000000L13.000000,9.000000z"
+        android:fillColor="#FFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_qs_bugreport.xml b/packages/SystemUI/res/drawable/ic_qs_bugreport.xml
deleted file mode 100644
index 0df1a96..0000000
--- a/packages/SystemUI/res/drawable/ic_qs_bugreport.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
-Copyright (C) 2014 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.
--->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="64dp"
-        android:height="64dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
-
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M20.0,8.0l-2.8,0.0c-0.5,-0.8 -1.1,-1.5 -1.8,-2.0L17.0,4.4L15.6,3.0l-2.2,2.2C13.0,5.1 12.5,5.0 12.0,5.0s-1.0,0.1 -1.4,0.2L8.4,3.0L7.0,4.4L8.6,6.0C7.9,6.5 7.3,7.2 6.8,8.0L4.0,8.0l0.0,2.0l2.1,0.0C6.0,10.3 6.0,10.7 6.0,11.0l0.0,1.0L4.0,12.0l0.0,2.0l2.0,0.0l0.0,1.0c0.0,0.3 0.0,0.7 0.1,1.0L4.0,16.0l0.0,2.0l2.8,0.0c1.0,1.8 3.0,3.0 5.2,3.0s4.2,-1.2 5.2,-3.0L20.0,18.0l0.0,-2.0l-2.1,0.0c0.1,-0.3 0.1,-0.7 0.1,-1.0l0.0,-1.0l2.0,0.0l0.0,-2.0l-2.0,0.0l0.0,-1.0c0.0,-0.3 0.0,-0.7 -0.1,-1.0L20.0,10.0L20.0,8.0zM14.0,16.0l-4.0,0.0l0.0,-2.0l4.0,0.0L14.0,16.0zM14.0,12.0l-4.0,0.0l0.0,-2.0l4.0,0.0L14.0,12.0z"/>
-</vector>
diff --git a/packages/SystemUI/res/drawable/ic_qs_no_sim.xml b/packages/SystemUI/res/drawable/ic_qs_no_sim.xml
new file mode 100644
index 0000000..bd46012
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_qs_no_sim.xml
@@ -0,0 +1,25 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="32dp"
+        android:height="32dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+
+    <path
+        android:fillColor="#4DFFFFFF"
+        android:pathData="M19.0,5.0c0.0,-1.1 -0.9,-2.0 -2.0,-2.0l-7.0,0.0L7.7,5.3L19.0,16.7L19.0,5.0zM3.7,3.9L2.4,5.2L5.0,7.8L5.0,19.0c0.0,1.1 0.9,2.0 2.0,2.0l10.0,0.0c0.4,0.0 0.7,-0.1 1.0,-0.3l1.9,1.9l1.3,-1.3L3.7,3.9z"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/ic_qs_vpn.xml b/packages/SystemUI/res/drawable/ic_qs_vpn.xml
index e9141ef..e7ef02a 100644
--- a/packages/SystemUI/res/drawable/ic_qs_vpn.xml
+++ b/packages/SystemUI/res/drawable/ic_qs_vpn.xml
@@ -18,8 +18,7 @@
         android:height="12.0dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
-
     <path
         android:fillColor="#4DFFFFFF"
-        android:pathData="M22.000000,4.000000L22.000000,3.500000C22.000000,2.100000 20.900000,1.000000 19.500000,1.000000C18.100000,1.000000 17.000000,2.100000 17.000000,3.500000L17.000000,4.000000c-0.600000,0.000000 -1.000000,0.400000 -1.000000,1.000000l0.000000,4.000000c0.000000,0.600000 0.400000,1.000000 1.000000,1.000000l5.000000,0.000000c0.600000,0.000000 1.000000,-0.400000 1.000000,-1.000000L23.000000,5.000000C23.000000,4.400000 22.600000,4.000000 22.000000,4.000000zM21.200001,4.000000l-3.400000,0.000000L17.800001,3.500000c0.000000,-0.900000 0.800000,-1.700000 1.700000,-1.700000c0.900000,0.000000 1.700000,0.800000 1.700000,1.700000L21.200003,4.000000zM18.900000,12.000000c0.000000,0.300000 0.100000,0.700000 0.100000,1.000000c0.000000,2.100000 -0.800000,4.000000 -2.100000,5.400000c-0.300000,-0.800000 -1.000000,-1.400000 -1.900000,-1.400000l-1.000000,0.000000l0.000000,-3.000000c0.000000,-0.600000 -0.400000,-1.000000 -1.000000,-1.000000L7.000000,13.000000l0.000000,-2.000000l2.000000,0.000000c0.600000,0.000000 1.000000,-0.400000 1.000000,-1.000000L10.000000,8.000000l2.000000,0.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L14.000000,3.500000C13.100000,3.200000 12.000000,3.000000 11.000000,3.000000C5.500000,3.000000 1.000000,7.500000 1.000000,13.000000c0.000000,5.500000 4.500000,10.000000 10.000000,10.000000c5.500000,0.000000 10.000000,-4.500000 10.000000,-10.000000c0.000000,-0.300000 0.000000,-0.700000 -0.100000,-1.000000L18.900000,12.000000zM10.000000,20.900000c-3.900000,-0.500000 -7.000000,-3.900000 -7.000000,-7.900000c0.000000,-0.600000 0.100000,-1.200000 0.200000,-1.800000L8.000000,16.000000l0.000000,1.000000c0.000000,1.100000 0.900000,2.000000 2.000000,2.000000L10.000000,20.900000z"/>
+        android:pathData="M12.700000,10.000000c-0.800000,-2.300000 -3.000000,-4.000000 -5.700000,-4.000000c-3.300000,0.000000 -6.000000,2.700000 -6.000000,6.000000s2.700000,6.000000 6.000000,6.000000c2.600000,0.000000 4.800000,-1.700000 5.700000,-4.000000L17.000000,14.000000l0.000000,4.000000l4.000000,0.000000l0.000000,-4.000000l2.000000,0.000000l0.000000,-4.000000L12.700000,10.000000zM7.000000,14.000000c-1.100000,0.000000 -2.000000,-0.900000 -2.000000,-2.000000c0.000000,-1.100000 0.900000,-2.000000 2.000000,-2.000000s2.000000,0.900000 2.000000,2.000000C9.000000,13.100000 8.100000,14.000000 7.000000,14.000000z"/>
 </vector>
diff --git a/packages/SystemUI/res/drawable/ic_ringer_mute.xml b/packages/SystemUI/res/drawable/ic_ringer_mute.xml
new file mode 100644
index 0000000..dee6018
--- /dev/null
+++ b/packages/SystemUI/res/drawable/ic_ringer_mute.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="32dp"
+        android:height="32dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:fillColor="#FFFFFFFF"
+        android:pathData="M23.000000,44.000000c2.200000,0.000000 4.000000,-1.800000 4.000000,-4.000000l-8.000000,0.000000C19.000000,42.200001 20.799999,44.000000 23.000000,44.000000zM36.000000,21.000000c0.000000,-6.100000 -4.300000,-11.300000 -10.000000,-12.600000L26.000000,7.000000c0.000000,-1.700000 -1.300000,-3.000000 -3.000000,-3.000000c-1.700000,0.000000 -3.000000,1.300000 -3.000000,3.000000l0.000000,1.400000c-1.000000,0.200000 -2.000000,0.600000 -2.900000,1.100000L36.000000,28.400000L36.000000,21.000000zM35.500000,38.000000l4.000000,4.000000l2.500000,-2.500000L8.500000,6.000000L6.000000,8.500000l5.800000,5.800000C10.700000,16.299999 10.000000,18.600000 10.000000,21.000000l0.000000,11.000000l-4.000000,4.000000l0.000000,2.000000L35.500000,38.000000z"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/indeterminate_anim.xml b/packages/SystemUI/res/drawable/indeterminate_anim.xml
index 52c6d16..13b1ccf 100644
--- a/packages/SystemUI/res/drawable/indeterminate_anim.xml
+++ b/packages/SystemUI/res/drawable/indeterminate_anim.xml
@@ -18,15 +18,15 @@
 
     <target
         android:name="path1"
-        android:animation="@*android:anim/progress_indeterminate_horizontal_rect1_translate" />
+        android:animation="@anim/progress_indeterminate_horizontal_rect1_translate" />
     <target
         android:name="path1"
-        android:animation="@*android:anim/progress_indeterminate_horizontal_rect1_scale" />
+        android:animation="@anim/progress_indeterminate_horizontal_rect1_scale" />
 
     <target
         android:name="path2"
-        android:animation="@*android:anim/progress_indeterminate_horizontal_rect2_translate" />
+        android:animation="@anim/progress_indeterminate_horizontal_rect2_translate" />
     <target
         android:name="path2"
-        android:animation="@*android:anim/progress_indeterminate_horizontal_rect2_scale" />
+        android:animation="@anim/progress_indeterminate_horizontal_rect2_scale" />
 </animated-vector>
diff --git a/packages/SystemUI/res/drawable/moon.xml b/packages/SystemUI/res/drawable/moon.xml
new file mode 100644
index 0000000..4ee6286
--- /dev/null
+++ b/packages/SystemUI/res/drawable/moon.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:pathData="M18.000000,4.000000c-2.100000,0.000000 -4.100000,0.300000 -6.000000,0.900000C20.100000,7.500000 26.000000,15.000000 26.000000,24.000000s-5.900000,16.500000 -14.000000,19.100000c1.900000,0.600000 3.900000,0.900000 6.000000,0.900000c11.000000,0.000000 20.000000,-9.000000 20.000000,-20.000000S29.000000,4.000000 18.000000,4.000000z"
+        android:fillColor="#FFF2F2FF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/notification_guts_bg.xml b/packages/SystemUI/res/drawable/notification_guts_bg.xml
index 07932d1..1730dce 100644
--- a/packages/SystemUI/res/drawable/notification_guts_bg.xml
+++ b/packages/SystemUI/res/drawable/notification_guts_bg.xml
@@ -17,5 +17,6 @@
 
 <shape xmlns:android="http://schemas.android.com/apk/res/android">
     <solid android:color="@color/notification_guts_bg_color" />
-    <corners android:radius="@dimen/notification_material_rounded_rect_radius" />
+    <!--The radius is 1dp smaller than the notification one, to avoid aliasing bugs on the corners -->
+    <corners android:radius="1dp" />
 </shape>
diff --git a/packages/SystemUI/res/drawable/notification_material_bg_dim.xml b/packages/SystemUI/res/drawable/notification_material_bg_dim.xml
index b04394d..6581942 100644
--- a/packages/SystemUI/res/drawable/notification_material_bg_dim.xml
+++ b/packages/SystemUI/res/drawable/notification_material_bg_dim.xml
@@ -14,7 +14,11 @@
   ~ See the License for the specific language governing permissions and
   ~ limitations under the License
   -->
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="@color/notification_material_background_dimmed_color" />
-    <corners android:radius="@dimen/notification_material_rounded_rect_radius" />
-</shape>
+<ripple xmlns:android="http://schemas.android.com/apk/res/android">
+    <item>
+        <shape>
+            <solid android:color="@color/notification_material_background_dimmed_color" />
+            <corners android:radius="@dimen/notification_material_rounded_rect_radius" />
+        </shape>
+    </item>
+</ripple>
diff --git a/packages/SystemUI/res/drawable/placeholder.xml b/packages/SystemUI/res/drawable/placeholder.xml
new file mode 100644
index 0000000..1933145
--- /dev/null
+++ b/packages/SystemUI/res/drawable/placeholder.xml
@@ -0,0 +1,51 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="100dp"
+        android:height="400dp"
+        android:viewportWidth="100"
+        android:viewportHeight="400">
+
+    <!-- future site of real artwork -->
+
+    <path android:fillColor="#FFFFFF00"
+        android:pathData="M 0,0 L 100,0 L 100,400 L 0,400 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,0 L 100,25 L 100,50 L 0,25 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,50 L 100,75 L 100,100 L 0,75 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,100 L 100,125 L 100,150 L 0,125 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,150 L 100,175 L 100,200 L 0,175 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,200 L 100,225 L 100,250 L 0,225 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,250 L 100,275 L 100,300 L 0,275 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,300 L 100,325 L 100,350 L 0,325 z" />
+    <path
+        android:fillColor="#FF000000"
+        android:pathData="M 0,350 L 100,375 L 100,400 L 0,375 z" />
+</vector>
+
diff --git a/packages/SystemUI/res/drawable/recents_button_bg.xml b/packages/SystemUI/res/drawable/recents_button_bg.xml
index a4cb088..7456365 100644
--- a/packages/SystemUI/res/drawable/recents_button_bg.xml
+++ b/packages/SystemUI/res/drawable/recents_button_bg.xml
@@ -15,4 +15,5 @@
 -->
 
 <ripple xmlns:android="http://schemas.android.com/apk/res/android"
-    android:color="?android:attr/colorControlHighlight" />
\ No newline at end of file
+    android:color="#40ffffff">
+</ripple>
diff --git a/packages/SystemUI/res/drawable/recents_task_view_header_bg_color.xml b/packages/SystemUI/res/drawable/recents_task_view_header_bg_color.xml
new file mode 100644
index 0000000..5f9341c
--- /dev/null
+++ b/packages/SystemUI/res/drawable/recents_task_view_header_bg_color.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+
+<shape xmlns:android="http://schemas.android.com/apk/res/android"
+       android:shape="rectangle">
+    <corners android:topLeftRadius="@dimen/recents_task_view_rounded_corners_radius"
+             android:topRightRadius="@dimen/recents_task_view_rounded_corners_radius"/>
+    <solid android:color="#00000000" />
+</shape>
\ No newline at end of file
diff --git a/packages/SystemUI/res/drawable/scorecard.xml b/packages/SystemUI/res/drawable/scorecard.xml
new file mode 100644
index 0000000..707449a
--- /dev/null
+++ b/packages/SystemUI/res/drawable/scorecard.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle"
+    >
+    <corners
+        android:radius="8dp" />
+    <solid
+        android:color="#ffffffff" />
+</shape>
diff --git a/packages/SystemUI/res/drawable/scorecard_gameover.xml b/packages/SystemUI/res/drawable/scorecard_gameover.xml
new file mode 100644
index 0000000..f663a66
--- /dev/null
+++ b/packages/SystemUI/res/drawable/scorecard_gameover.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<shape
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:shape="rectangle"
+    >
+    <corners
+        android:radius="8dp" />
+    <solid
+        android:color="#ffff0000" />
+</shape>
diff --git a/packages/SystemUI/res/drawable/search_panel_card_bg.xml b/packages/SystemUI/res/drawable/search_panel_card_bg.xml
deleted file mode 100644
index c19f900..0000000
--- a/packages/SystemUI/res/drawable/search_panel_card_bg.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<!--
-  ~ Copyright (C) 2014 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
-  -->
-<shape xmlns:android="http://schemas.android.com/apk/res/android">
-    <solid android:color="@color/search_panel_card_color" />
-    <corners android:radius="@dimen/notification_material_rounded_rect_radius" />
-</shape>
diff --git a/packages/SystemUI/res/drawable/star.xml b/packages/SystemUI/res/drawable/star.xml
new file mode 100644
index 0000000..73ca04a
--- /dev/null
+++ b/packages/SystemUI/res/drawable/star.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:pathData="M30.250000,17.750000L24.000000,4.000000l-6.250000,13.750000L4.000000,24.000000l13.750000,6.250000L24.000000,44.000000l6.250000,-13.750000L44.000000,24.000000L30.250000,17.750000z"
+        android:fillColor="#FFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/stat_notify_more.xml b/packages/SystemUI/res/drawable/stat_notify_more.xml
new file mode 100644
index 0000000..50f1286
--- /dev/null
+++ b/packages/SystemUI/res/drawable/stat_notify_more.xml
@@ -0,0 +1,24 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="16dp"
+        android:height="16dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:pathData="M22.000000,3.000000L7.000000,3.000000C6.300000,3.000000 5.800000,3.400000 5.400000,3.900000L0.000000,12.000000l5.400000,8.100000c0.400000,0.500000 1.000000,0.900000 1.700000,0.900000L22.000000,21.000000c1.100000,0.000000 2.000000,-0.900000 2.000000,-2.000000L24.000000,5.000000C24.000000,3.900000 23.100000,3.000000 22.000000,3.000000zM9.000000,13.500000c-0.800000,0.000000 -1.500000,-0.700000 -1.500000,-1.500000s0.700000,-1.500000 1.500000,-1.500000c0.800000,0.000000 1.500000,0.700000 1.500000,1.500000S9.800000,13.500000 9.000000,13.500000zM14.000000,13.500000c-0.800000,0.000000 -1.500000,-0.700000 -1.500000,-1.500000s0.700000,-1.500000 1.500000,-1.500000c0.800000,0.000000 1.500000,0.700000 1.500000,1.500000S14.800000,13.500000 14.000000,13.500000zM19.000000,13.500000c-0.800000,0.000000 -1.500000,-0.700000 -1.500000,-1.500000s0.700000,-1.500000 1.500000,-1.500000c0.800000,0.000000 1.500000,0.700000 1.500000,1.500000S19.799999,13.500000 19.000000,13.500000z"
+        android:fillColor="#FFFFFFFF"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/stat_sys_airplane_mode.xml b/packages/SystemUI/res/drawable/stat_sys_airplane_mode.xml
new file mode 100644
index 0000000..433da5f
--- /dev/null
+++ b/packages/SystemUI/res/drawable/stat_sys_airplane_mode.xml
@@ -0,0 +1,28 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="17.25dp"
+        android:height="18dp"
+        android:viewportWidth="46.0"
+        android:viewportHeight="48.0">
+
+    <path
+        android:fillColor="#FFFFFFFF"
+        android:pathData="M20.4,18.0"/>
+    <path
+        android:fillColor="#FFFFFFFF"
+        android:pathData="M42.0,32.0l0.0,-4.0L26.0,18.0L26.0,7.0c0.0,-1.7 -1.3,-3.0 -3.0,-3.0c-1.7,0.0 -3.0,1.3 -3.0,3.0l0.0,11.0L4.0,28.0l0.0,4.0l16.0,-5.0l0.0,11.0l-4.0,3.0l0.0,3.0l7.0,-2.0l7.0,2.0l0.0,-3.0l-4.0,-3.0L26.0,27.0L42.0,32.0z"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/stat_sys_alarm.xml b/packages/SystemUI/res/drawable/stat_sys_alarm.xml
index 3b2bc31..5754569 100644
--- a/packages/SystemUI/res/drawable/stat_sys_alarm.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_alarm.xml
@@ -13,13 +13,17 @@
   ~ See the License for the specific language governing permissions and
   ~ limitations under the License
   -->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-    android:width="18dp"
-    android:height="18dp"
-    android:viewportWidth="24.0"
-    android:viewportHeight="24.0">
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="2.5dp"
+    android:insetRight="2.5dp">
+    <vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="22dp"
+        android:height="17dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
 
-    <path
-        android:fillColor="#ffffffff"
-        android:pathData="M22.0,5.7l-4.6,-3.9l-1.3,1.5l4.6,3.9L22.0,5.7zM7.9,3.4L6.6,1.9L2.0,5.7l1.3,1.5L7.9,3.4zM12.5,8.0L11.0,8.0l0.0,6.0l4.7,2.9l0.8,-1.2l-4.0,-2.4L12.5,8.0zM12.0,4.0c-5.0,0.0 -9.0,4.0 -9.0,9.0c0.0,5.0 4.0,9.0 9.0,9.0s9.0,-4.0 9.0,-9.0C21.0,8.0 17.0,4.0 12.0,4.0zM12.0,20.0c-3.9,0.0 -7.0,-3.1 -7.0,-7.0c0.0,-3.9 3.1,-7.0 7.0,-7.0c3.9,0.0 7.0,3.1 7.0,7.0C19.0,16.9 15.9,20.0 12.0,20.0z"/>
-</vector>
+        <path
+            android:fillColor="#ffffffff"
+            android:pathData="M22.0,5.7l-4.6,-3.9l-1.3,1.5l4.6,3.9L22.0,5.7zM7.9,3.4L6.6,1.9L2.0,5.7l1.3,1.5L7.9,3.4zM12.5,8.0L11.0,8.0l0.0,6.0l4.7,2.9l0.8,-1.2l-4.0,-2.4L12.5,8.0zM12.0,4.0c-5.0,0.0 -9.0,4.0 -9.0,9.0c0.0,5.0 4.0,9.0 9.0,9.0s9.0,-4.0 9.0,-9.0C21.0,8.0 17.0,4.0 12.0,4.0zM12.0,20.0c-3.9,0.0 -7.0,-3.1 -7.0,-7.0c0.0,-3.9 3.1,-7.0 7.0,-7.0c3.9,0.0 7.0,3.1 7.0,7.0C19.0,16.9 15.9,20.0 12.0,20.0z"/>
+    </vector>
+</inset>
\ No newline at end of file
diff --git a/packages/SystemUI/res/drawable/stat_sys_cast.xml b/packages/SystemUI/res/drawable/stat_sys_cast.xml
new file mode 100644
index 0000000..df28638
--- /dev/null
+++ b/packages/SystemUI/res/drawable/stat_sys_cast.xml
@@ -0,0 +1,28 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="2.5dp"
+    android:insetRight="2.5dp">
+    <vector android:width="22dp"
+            android:height="17dp"
+            android:viewportWidth="48.0"
+            android:viewportHeight="48.0">
+
+        <path
+            android:fillColor="#FFFFFFFF"
+            android:pathData="M2.0,36.0l0.0,6.0l6.0,0.0C8.0,38.7 5.3,36.0 2.0,36.0zM2.0,28.0l0.0,4.0c5.5,0.0 10.0,4.5 10.0,10.0l4.0,0.0C16.0,34.3 9.7,28.0 2.0,28.0zM38.0,14.0L10.0,14.0l0.0,3.3c7.9,2.6 14.2,8.8 16.7,16.7L38.0,34.0L38.0,14.0zM2.0,20.0l0.0,4.0c9.9,0.0 18.0,8.1 18.0,18.0l4.0,0.0C24.0,29.8 14.1,20.0 2.0,20.0zM42.0,6.0L6.0,6.0c-2.2,0.0 -4.0,1.8 -4.0,4.0l0.0,6.0l4.0,0.0l0.0,-6.0l36.0,0.0l0.0,28.0L28.0,38.0l0.0,4.0l14.0,0.0c2.2,0.0 4.0,-1.8 4.0,-4.0L46.0,10.0C46.0,7.8 44.2,6.0 42.0,6.0z"/>
+    </vector>
+</inset>
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_bluetooth.xml b/packages/SystemUI/res/drawable/stat_sys_data_bluetooth.xml
index f53f0e4..e2d3539 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_bluetooth.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_bluetooth.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="48.0"
         android:viewportHeight="48.0">
 
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_bluetooth_connected.xml b/packages/SystemUI/res/drawable/stat_sys_data_bluetooth_connected.xml
index 2aac4ee..94c40ba 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_bluetooth_connected.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_bluetooth_connected.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="48.0"
         android:viewportHeight="48.0">
 
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_1x.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_1x.xml
index 26d2632..d7463a4 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_1x.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_1x.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="9.0dp"
-        android:height="18dp"
+        android:width="8.5dp"
+        android:height="17dp"
         android:viewportWidth="12.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_3g.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_3g.xml
index 5aaf93b..6309b6d 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_3g.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_3g.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="9.75dp"
-        android:height="18dp"
+        android:width="9.208dp"
+        android:height="17dp"
         android:viewportWidth="13.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_4g.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_4g.xml
index b7d84f0..4067ae5 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_4g.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_4g.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="9.0dp"
-        android:height="18dp"
+        android:width="8.5dp"
+        android:height="17dp"
         android:viewportWidth="12.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_e.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_e.xml
index 7111457..acaa9b1 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_e.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_e.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="3.75dp"
-        android:height="18dp"
+        android:width="3.541dp"
+        android:height="17dp"
         android:viewportWidth="5.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_g.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_g.xml
index 97962b2..7985237 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_g.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_g.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="5.25dp"
-        android:height="18dp"
+        android:width="4.958dp"
+        android:height="17dp"
         android:viewportWidth="7.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_h.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_h.xml
index 4859c14..fda8761 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_h.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_h.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="4.5dp"
-        android:height="18dp"
+        android:width="4.25dp"
+        android:height="17dp"
         android:viewportWidth="6.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_lte.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_lte.xml
index d6446db..c08ff20 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_lte.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_lte.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="9.75dp"
-        android:height="18dp"
+        android:width="9.208dp"
+        android:height="17dp"
         android:viewportWidth="13.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_roam.xml b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_roam.xml
index 7f7d5fc..363e231 100644
--- a/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_roam.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_data_fully_connected_roam.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="4.5dp"
-        android:height="18dp"
+        android:width="4.25dp"
+        android:height="17dp"
         android:viewportWidth="6.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_location.xml b/packages/SystemUI/res/drawable/stat_sys_location.xml
new file mode 100644
index 0000000..433f73b
--- /dev/null
+++ b/packages/SystemUI/res/drawable/stat_sys_location.xml
@@ -0,0 +1,29 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="1.5dp"
+    android:insetRight="1.5dp">
+        <vector
+            android:width="20dp"
+            android:height="17dp"
+            android:viewportWidth="48.0"
+            android:viewportHeight="48.0">
+
+        <path
+            android:fillColor="#FFFFFFFF"
+            android:pathData="M24.0,4.0c-7.7,0.0 -14.0,6.3 -14.0,14.0c0.0,10.5 14.0,26.0 14.0,26.0s14.0,-15.5 14.0,-26.0C38.0,10.3 31.7,4.0 24.0,4.0zM24.0,23.0c-2.8,0.0 -5.0,-2.2 -5.0,-5.0s2.2,-5.0 5.0,-5.0c2.8,0.0 5.0,2.2 5.0,5.0S26.8,23.0 24.0,23.0z"/>
+        </vector>
+</inset>
\ No newline at end of file
diff --git a/packages/SystemUI/res/drawable/stat_sys_no_sim.xml b/packages/SystemUI/res/drawable/stat_sys_no_sim.xml
deleted file mode 100644
index 22d1d4b..0000000
--- a/packages/SystemUI/res/drawable/stat_sys_no_sim.xml
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
-Copyright (C) 2014 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.
--->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="18dp"
-        android:height="18dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
-
-    <path
-        android:fillColor="#4DFFFFFF"
-        android:pathData="M19.0,5.0c0.0,-1.1 -0.9,-2.0 -2.0,-2.0l-7.0,0.0L7.7,5.3L19.0,16.7L19.0,5.0zM3.7,3.9L2.4,5.2L5.0,7.8L5.0,19.0c0.0,1.1 0.9,2.0 2.0,2.0l10.0,0.0c0.4,0.0 0.7,-0.1 1.0,-0.3l1.9,1.9l1.3,-1.3L3.7,3.9z"/>
-</vector>
diff --git a/packages/SystemUI/res/drawable/stat_sys_ringer_vibrate.xml b/packages/SystemUI/res/drawable/stat_sys_ringer_vibrate.xml
index 352d86f..f017d58 100644
--- a/packages/SystemUI/res/drawable/stat_sys_ringer_vibrate.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_ringer_vibrate.xml
@@ -13,13 +13,16 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="20dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="3dp"
+    android:insetRight="3dp">
+    <vector android:width="24dp"
+            android:height="18dp"
+            android:viewportWidth="24.0"
+            android:viewportHeight="24.0">
 
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M0.0,15.0l2.0,0.0L2.0,9.0L0.0,9.0L0.0,15.0zM3.0,17.0l2.0,0.0L5.0,7.0L3.0,7.0L3.0,17.0zM22.0,9.0l0.0,6.0l2.0,0.0L24.0,9.0L22.0,9.0zM19.0,17.0l2.0,0.0L21.0,7.0l-2.0,0.0L19.0,17.0zM16.5,3.0l-9.0,0.0C6.7,3.0 6.0,3.7 6.0,4.5l0.0,15.0C6.0,20.3 6.7,21.0 7.5,21.0l9.0,0.0c0.8,0.0 1.5,-0.7 1.5,-1.5l0.0,-15.0C18.0,3.7 17.3,3.0 16.5,3.0zM16.0,19.0L8.0,19.0L8.0,5.0l8.0,0.0L16.0,19.0z"/>
-</vector>
+        <path
+            android:fillColor="#FFFFFFFF"
+            android:pathData="M0.0,15.0l2.0,0.0L2.0,9.0L0.0,9.0L0.0,15.0zM3.0,17.0l2.0,0.0L5.0,7.0L3.0,7.0L3.0,17.0zM22.0,9.0l0.0,6.0l2.0,0.0L24.0,9.0L22.0,9.0zM19.0,17.0l2.0,0.0L21.0,7.0l-2.0,0.0L19.0,17.0zM16.5,3.0l-9.0,0.0C6.7,3.0 6.0,3.7 6.0,4.5l0.0,15.0C6.0,20.3 6.7,21.0 7.5,21.0l9.0,0.0c0.8,0.0 1.5,-0.7 1.5,-1.5l0.0,-15.0C18.0,3.7 17.3,3.0 16.5,3.0zM16.0,19.0L8.0,19.0L8.0,5.0l8.0,0.0L16.0,19.0z"/>
+    </vector>
+</inset>
\ No newline at end of file
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_0.xml b/packages/SystemUI/res/drawable/stat_sys_signal_0.xml
index 67d9259..e1e81fd 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_0.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_0.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_0_fully.xml b/packages/SystemUI/res/drawable/stat_sys_signal_0_fully.xml
index 3bbb800..c0dfcf4 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_0_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_0_fully.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_1.xml b/packages/SystemUI/res/drawable/stat_sys_signal_1.xml
index 55f764a..a53e946 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_1.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_1.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_1_fully.xml b/packages/SystemUI/res/drawable/stat_sys_signal_1_fully.xml
index b82e428..6bc55cd 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_1_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_1_fully.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_2.xml b/packages/SystemUI/res/drawable/stat_sys_signal_2.xml
index ca0eeb3..537c788 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_2.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_2.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_2_fully.xml b/packages/SystemUI/res/drawable/stat_sys_signal_2_fully.xml
index abc8dd1..7d9376e 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_2_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_2_fully.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_3.xml b/packages/SystemUI/res/drawable/stat_sys_signal_3.xml
index 2b3e571..09fe33a 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_3.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_3.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_3_fully.xml b/packages/SystemUI/res/drawable/stat_sys_signal_3_fully.xml
index d47f167..8ec5500 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_3_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_3_fully.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_4.xml b/packages/SystemUI/res/drawable/stat_sys_signal_4.xml
index 7d4dd8a..bb98541 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_4.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_4.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_4_fully.xml b/packages/SystemUI/res/drawable/stat_sys_signal_4_fully.xml
index 5b1bac3..a468410 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_4_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_4_fully.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_signal_null.xml b/packages/SystemUI/res/drawable/stat_sys_signal_null.xml
index 45d34a2..d25fc1c 100644
--- a/packages/SystemUI/res/drawable/stat_sys_signal_null.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_signal_null.xml
@@ -15,8 +15,8 @@
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
         android:autoMirrored="true"
-        android:width="18dp"
-        android:height="18dp"
+        android:width="17dp"
+        android:height="17dp"
         android:viewportWidth="24.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_vpn_ic.xml b/packages/SystemUI/res/drawable/stat_sys_vpn_ic.xml
new file mode 100644
index 0000000..7ca8c40
--- /dev/null
+++ b/packages/SystemUI/res/drawable/stat_sys_vpn_ic.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="17.0dp"
+        android:height="17.0dp"
+        android:viewportWidth="24.0"
+        android:viewportHeight="24.0">
+    <path
+        android:fillColor="#FFFFFFFF"
+        android:pathData="M12.700000,10.000000c-0.800000,-2.300000 -3.000000,-4.000000 -5.700000,-4.000000c-3.300000,0.000000 -6.000000,2.700000 -6.000000,6.000000s2.700000,6.000000 6.000000,6.000000c2.600000,0.000000 4.800000,-1.700000 5.700000,-4.000000L17.000000,14.000000l0.000000,4.000000l4.000000,0.000000l0.000000,-4.000000l2.000000,0.000000l0.000000,-4.000000L12.700000,10.000000zM7.000000,14.000000c-1.100000,0.000000 -2.000000,-0.900000 -2.000000,-2.000000c0.000000,-1.100000 0.900000,-2.000000 2.000000,-2.000000s2.000000,0.900000 2.000000,2.000000C9.000000,13.100000 8.100000,14.000000 7.000000,14.000000z"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0.xml
index 4965674..be930e8 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0_fully.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0_fully.xml
index e9cad0e..b2691f6 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_0_fully.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1.xml
index 7d588a3..dde781d 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1_fully.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1_fully.xml
index 348f963..65931f4 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_1_fully.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2.xml
index 4fbdd69..63d9dca 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2_fully.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2_fully.xml
index 66588f0..7ba4895 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_2_fully.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3.xml
index 1f3de74..7d393b4 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3_fully.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3_fully.xml
index aa5d2ed..e2cde53 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_3_fully.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4.xml
index ca53b56..ec8137f 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4_fully.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4_fully.xml
index 1c7a539..9d02980 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4_fully.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_4_fully.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_null.xml b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_null.xml
index c68fb49..95c6531 100644
--- a/packages/SystemUI/res/drawable/stat_sys_wifi_signal_null.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_wifi_signal_null.xml
@@ -14,8 +14,8 @@
     limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="18dp"
+        android:width="18.41dp"
+        android:height="17dp"
         android:viewportWidth="26.0"
         android:viewportHeight="24.0">
     <path
diff --git a/packages/SystemUI/res/drawable/stat_sys_zen_important.xml b/packages/SystemUI/res/drawable/stat_sys_zen_important.xml
index 73d7cba..9dabb03 100644
--- a/packages/SystemUI/res/drawable/stat_sys_zen_important.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_zen_important.xml
@@ -13,13 +13,16 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="20dp"
-        android:height="20dp"
-        android:viewportWidth="24.0"
-        android:viewportHeight="24.0">
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="2.5dp"
+    android:insetRight="2.5dp">
+    <vector android:width="23dp"
+            android:height="18dp"
+            android:viewportWidth="24.0"
+            android:viewportHeight="24.0">
 
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M12.0,17.273l6.1800003,3.7269993 -1.6350002,-7.0290003 5.455,-4.7269993 -7.191,-0.6170006 -2.809,-6.627 -2.809,6.627 -7.191,0.6170006 5.455,4.7269993 -1.6349998,7.0290003z"/>
-</vector>
+        <path
+            android:fillColor="#FFFFFFFF"
+            android:pathData="M12.0,17.273l6.1800003,3.7269993 -1.6350002,-7.0290003 5.455,-4.7269993 -7.191,-0.6170006 -2.809,-6.627 -2.809,6.627 -7.191,0.6170006 5.455,4.7269993 -1.6349998,7.0290003z"/>
+    </vector>
+</inset>
diff --git a/packages/SystemUI/res/drawable/stat_sys_zen_none.xml b/packages/SystemUI/res/drawable/stat_sys_zen_none.xml
index d8ab078..7573de0 100644
--- a/packages/SystemUI/res/drawable/stat_sys_zen_none.xml
+++ b/packages/SystemUI/res/drawable/stat_sys_zen_none.xml
@@ -13,13 +13,16 @@
     See the License for the specific language governing permissions and
     limitations under the License.
 -->
-<vector xmlns:android="http://schemas.android.com/apk/res/android"
-        android:width="19dp"
-        android:height="19dp"
-        android:viewportWidth="48.0"
-        android:viewportHeight="48.0">
+<inset xmlns:android="http://schemas.android.com/apk/res/android"
+    android:insetLeft="2.5dp"
+    android:insetRight="2.5dp">
+    <vector android:width="22dp"
+            android:height="17dp"
+            android:viewportWidth="48.0"
+            android:viewportHeight="48.0">
 
-    <path
-        android:fillColor="#FFFFFFFF"
-        android:pathData="M24.0,4.0C13.0,4.0 4.0,13.0 4.0,24.0c0.0,11.0 9.0,20.0 20.0,20.0c11.0,0.0 20.0,-9.0 20.0,-20.0C44.0,13.0 35.0,4.0 24.0,4.0zM24.0,40.0c-8.8,0.0 -16.0,-7.2 -16.0,-16.0c0.0,-3.7 1.3,-7.1 3.4,-9.8l22.4,22.4C31.1,38.7 27.7,40.0 24.0,40.0zM36.6,33.8L14.2,11.4C16.9,9.3 20.3,8.0 24.0,8.0c8.8,0.0 16.0,7.2 16.0,16.0C40.0,27.7 38.7,31.1 36.6,33.8z"/>
-</vector>
+        <path
+            android:fillColor="#FFFFFFFF"
+            android:pathData="M24.0,4.0C13.0,4.0 4.0,13.0 4.0,24.0c0.0,11.0 9.0,20.0 20.0,20.0c11.0,0.0 20.0,-9.0 20.0,-20.0C44.0,13.0 35.0,4.0 24.0,4.0zM24.0,40.0c-8.8,0.0 -16.0,-7.2 -16.0,-16.0c0.0,-3.7 1.3,-7.1 3.4,-9.8l22.4,22.4C31.1,38.7 27.7,40.0 24.0,40.0zM36.6,33.8L14.2,11.4C16.9,9.3 20.3,8.0 24.0,8.0c8.8,0.0 16.0,7.2 16.0,16.0C40.0,27.7 38.7,31.1 36.6,33.8z"/>
+    </vector>
+</inset>
diff --git a/packages/SystemUI/res/drawable/sun.xml b/packages/SystemUI/res/drawable/sun.xml
new file mode 100644
index 0000000..3e4a233
--- /dev/null
+++ b/packages/SystemUI/res/drawable/sun.xml
@@ -0,0 +1,29 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <group>
+        <path
+            android:pathData="M 24,8 A 16,16 0 1,0 24.0001,8 z"
+            android:fillColor="#FFFFFFCC" />
+        <path
+            android:pathData="M40.0,30.6l6.6,-6.6L40.0,17.4L40.0,8.0l-9.4,0.0L24.0,1.4L17.4,8.0L8.0,8.0l0.0,9.4L1.4,24.0L8.0,30.6L8.0,40.0l9.4,0.0l6.6,6.6l6.6,-6.6L40.0,40.0L40.0,30.6zM24.0,36.0c-6.6,0.0 -12.0,-5.4 -12.0,-12.0s5.4,-12.0 12.0,-12.0c6.6,0.0 12.0,5.4 12.0,12.0S30.6,36.0 24.0,36.0z"
+            android:fillColor="#FFFFFF40"/>
+    </group>
+</vector>
diff --git a/packages/SystemUI/res/drawable/sun2.xml b/packages/SystemUI/res/drawable/sun2.xml
new file mode 100644
index 0000000..6d2d504
--- /dev/null
+++ b/packages/SystemUI/res/drawable/sun2.xml
@@ -0,0 +1,24 @@
+<!--
+Copyright (C) 2014 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="48.0dp"
+        android:height="48.0dp"
+        android:viewportWidth="48.0"
+        android:viewportHeight="48.0">
+    <path
+        android:pathData="M40.000000,17.400000L40.000000,8.000000l-9.400000,0.000000L24.000000,1.400000L17.400000,8.000000L8.000000,8.000000l0.000000,9.400000L1.400000,24.000000L8.000000,30.600000L8.000000,40.000000l9.400000,0.000000l6.600000,6.600000l6.600000,-6.600000L40.000000,40.000000l0.000000,-9.400000l6.600000,-6.600000L40.000000,17.400000zM24.000000,36.000000c-6.600000,0.000000 -12.000000,-5.400000 -12.000000,-12.000000s5.400000,-12.000000 12.000000,-12.000000c6.600000,0.000000 12.000000,5.400000 12.000000,12.000000S30.600000,36.000000 24.000000,36.000000zM24.000000,16.000000c-4.400000,0.000000 -8.000000,3.600000 -8.000000,8.000000c0.000000,4.400000 3.600000,8.000000 8.000000,8.000000s8.000000,-3.600000 8.000000,-8.000000C32.000000,19.600000 28.400000,16.000000 24.000000,16.000000z"
+        android:fillColor="#FF000000"/>
+</vector>
diff --git a/packages/SystemUI/res/drawable/trust_circle.xml b/packages/SystemUI/res/drawable/trust_circle.xml
deleted file mode 100644
index 56fc62e..0000000
--- a/packages/SystemUI/res/drawable/trust_circle.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-
-<!--
-  ~ Copyright (C) 2014 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
-  -->
-
-<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="ring"
-        android:innerRadius="22dp" android:thickness="2dp">
-    <solid android:color="#4cffffff" />
-</shape>
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout-ldrtl/navigation_bar.xml b/packages/SystemUI/res/layout-ldrtl/navigation_bar.xml
deleted file mode 100644
index a291495..0000000
--- a/packages/SystemUI/res/layout-ldrtl/navigation_bar.xml
+++ /dev/null
@@ -1,328 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-/* apps/common/assets/default/default/skins/StatusBar.xml
-**
-** Copyright 2011, 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.
-*/
--->
-
-<com.android.systemui.statusbar.phone.NavigationBarView
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:systemui="http://schemas.android.com/apk/res/com.android.systemui"
-    android:layout_height="match_parent"
-    android:layout_width="match_parent"
-    android:background="@drawable/system_bar_background"
-    >
-
-    <FrameLayout android:id="@+id/rot0"
-        android:layout_height="match_parent"
-        android:layout_width="match_parent"
-        >
-
-        <LinearLayout
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            android:orientation="horizontal"
-            android:clipChildren="false"
-            android:clipToPadding="false"
-            android:id="@+id/nav_buttons"
-            android:animateLayoutChanges="true"
-            >
-
-            <!-- navigation controls -->
-            <View
-                android:layout_width="@dimen/navigation_extra_key_width"
-                android:layout_height="match_parent"
-                android:layout_weight="0"
-                android:visibility="invisible"
-                />
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/back"
-                android:layout_width="@dimen/navigation_key_width"
-                android:layout_height="match_parent"
-                android:src="@drawable/ic_sysbar_back"
-                systemui:keyCode="4"
-                android:layout_weight="0"
-                android:scaleType="center"
-                android:background="@drawable/ripple_drawable"
-                android:contentDescription="@string/accessibility_back"
-                />
-            <View 
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/home"
-                android:layout_width="@dimen/navigation_key_width"
-                android:layout_height="match_parent"
-                android:src="@drawable/ic_sysbar_home"
-                systemui:keyCode="3"
-                systemui:keyRepeat="false"
-                android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
-                android:contentDescription="@string/accessibility_home"
-                />
-            <View 
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/recent_apps"
-                android:layout_width="@dimen/navigation_key_width"
-                android:layout_height="match_parent"
-                android:src="@drawable/ic_sysbar_recent"
-                android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
-                android:contentDescription="@string/accessibility_recent"
-                />
-            <FrameLayout
-                android:layout_width="@dimen/navigation_extra_key_width"
-                android:layout_height="match_parent"
-                android:layout_weight="0" >
-                <com.android.systemui.statusbar.policy.KeyButtonView
-                    android:id="@+id/menu"
-                    android:layout_width="@dimen/navigation_extra_key_width"
-                    android:layout_height="match_parent"
-                    android:contentDescription="@string/accessibility_menu"
-                    android:src="@drawable/ic_sysbar_menu"
-                    android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable"
-                    systemui:keyCode="82" />
-                <com.android.systemui.statusbar.policy.KeyButtonView
-                    android:id="@+id/ime_switcher"
-                    android:layout_width="@dimen/navigation_extra_key_width"
-                    android:layout_height="match_parent"
-                    android:contentDescription="@string/accessibility_ime_switch_button"
-                    android:scaleType="centerInside"
-                    android:src="@drawable/ic_ime_switcher_default"
-                    android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable" />
-            </FrameLayout>
-        </LinearLayout>
-
-        <!-- lights out layout to match exactly -->
-        <LinearLayout
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            android:orientation="horizontal"
-            android:id="@+id/lights_out"
-            android:visibility="gone"
-            >
-            <ImageView
-                android:layout_width="80dp"
-                android:layout_height="match_parent"
-                android:layout_marginStart="40dp"
-                android:src="@drawable/ic_sysbar_lights_out_dot_small"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-            <View 
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <ImageView
-                android:layout_width="80dp"
-                android:layout_height="match_parent"
-                android:src="@drawable/ic_sysbar_lights_out_dot_large"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-            <View 
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <ImageView
-                android:layout_width="80dp"
-                android:layout_marginEnd="40dp"
-                android:layout_height="match_parent"
-                android:src="@drawable/ic_sysbar_lights_out_dot_small"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-        </LinearLayout>
-
-        <com.android.systemui.statusbar.policy.DeadZone
-            android:id="@+id/deadzone"
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            systemui:minSize="@dimen/navigation_bar_deadzone_size"
-            systemui:maxSize="@dimen/navigation_bar_deadzone_size_max"
-            systemui:holdTime="@integer/navigation_bar_deadzone_hold"
-            systemui:decayTime="@integer/navigation_bar_deadzone_decay"
-            systemui:orientation="horizontal"
-            android:layout_gravity="top"
-            />
-    </FrameLayout>
-
-    <FrameLayout android:id="@+id/rot90"
-        android:layout_height="match_parent"
-        android:layout_width="match_parent"
-        android:visibility="gone"
-        android:paddingTop="0dp"
-        >
-
-        <LinearLayout 
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            android:orientation="vertical"
-            android:clipChildren="false"
-            android:clipToPadding="false"
-            android:id="@+id/nav_buttons"
-            android:animateLayoutChanges="true"
-            >
-            
-            <!-- navigation controls -->
-            <FrameLayout
-                android:layout_width="@dimen/navigation_extra_key_width"
-                android:layout_height="match_parent"
-                android:layout_weight="0" >
-                <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/menu"
-                    android:layout_height="@dimen/navigation_extra_key_width"
-                    android:layout_width="match_parent"
-                    android:src="@drawable/ic_sysbar_menu_land"
-                    systemui:keyCode="82"
-                    android:layout_weight="0"
-                    android:visibility="invisible"
-                    android:contentDescription="@string/accessibility_menu"
-                    android:background="@drawable/ripple_drawable" />
-                <com.android.systemui.statusbar.policy.KeyButtonView
-                    android:id="@+id/ime_switcher"
-                    android:layout_height="@dimen/navigation_extra_key_width"
-                    android:layout_width="match_parent"
-                    android:contentDescription="@string/accessibility_ime_switch_button"
-                    android:scaleType="centerInside"
-                    android:src="@drawable/ic_ime_switcher_default"
-                    android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable" />
-            </FrameLayout>
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/back"
-                android:layout_height="80dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_back_land"
-                android:scaleType="center"
-                systemui:keyCode="4"
-                android:layout_weight="0"
-                android:contentDescription="@string/accessibility_back"
-                android:background="@drawable/ripple_drawable"
-                />
-            <View
-                android:layout_height="match_parent"
-                android:layout_width="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/home"
-                android:layout_height="80dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_home_land"
-                systemui:keyCode="3"
-                systemui:keyRepeat="false"
-                android:layout_weight="0"
-                android:contentDescription="@string/accessibility_home"
-                android:background="@drawable/ripple_drawable"
-                />
-            <View 
-                android:layout_height="match_parent"
-                android:layout_width="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/recent_apps"
-                android:layout_height="80dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_recent_land"
-                android:layout_weight="0"
-                android:contentDescription="@string/accessibility_recent"
-                android:background="@drawable/ripple_drawable"
-                />
-            <View
-                android:layout_height="40dp"
-                android:layout_width="match_parent"
-                android:layout_weight="0"
-                android:visibility="invisible"
-                />
-        </LinearLayout>
-
-        <!-- lights out layout to match exactly -->
-        <LinearLayout 
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            android:orientation="vertical"
-            android:id="@+id/lights_out"
-            android:visibility="gone"
-            >
-            <ImageView
-                android:layout_height="80dp"
-                android:layout_marginTop="40dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_lights_out_dot_small"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-            <View 
-                android:layout_height="match_parent"
-                android:layout_width="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <ImageView
-                android:layout_height="80dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_lights_out_dot_large"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-            <View 
-                android:layout_height="match_parent"
-                android:layout_width="match_parent"
-                android:layout_weight="1"
-                android:visibility="invisible"
-                />
-            <ImageView
-                android:layout_height="80dp"
-                android:layout_marginBottom="40dp"
-                android:layout_width="match_parent"
-                android:src="@drawable/ic_sysbar_lights_out_dot_small"
-                android:scaleType="center"
-                android:layout_weight="0"
-                />
-        </LinearLayout>
-
-        <com.android.systemui.statusbar.policy.DeadZone
-            android:id="@+id/deadzone"
-            android:layout_height="match_parent"
-            android:layout_width="match_parent"
-            systemui:minSize="@dimen/navigation_bar_deadzone_size"
-            systemui:maxSize="@dimen/navigation_bar_deadzone_size_max"
-            systemui:holdTime="@integer/navigation_bar_deadzone_hold"
-            systemui:decayTime="@integer/navigation_bar_deadzone_decay"
-            systemui:orientation="vertical"
-            android:layout_gravity="top"
-            />
-    </FrameLayout>
-
-    <!-- not used -->
-    <View android:id="@+id/rot270"
-        android:layout_height="match_parent"
-        android:layout_width="match_parent"
-        android:visibility="gone"
-        />
-
-</com.android.systemui.statusbar.phone.NavigationBarView>
diff --git a/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml b/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml
index f8b7bae..c2733fb 100644
--- a/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml
+++ b/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml
@@ -59,7 +59,6 @@
                 android:src="@drawable/ic_sysbar_back"
                 systemui:keyCode="4"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_back"
                 />
             <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/home"
@@ -69,7 +68,6 @@
                 systemui:keyCode="3"
                 systemui:keyRepeat="true"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_home"
                 />
             <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/recent_apps"
@@ -77,7 +75,6 @@
                 android:layout_height="match_parent"
                 android:src="@drawable/ic_sysbar_recent"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_recent"
                 />
             <Space 
@@ -98,7 +95,6 @@
                     systemui:keyCode="82"
                     android:visibility="invisible"
                     android:contentDescription="@string/accessibility_menu"
-                    android:background="@drawable/ripple_drawable"
                     />
                 <com.android.systemui.statusbar.policy.KeyButtonView
                     android:id="@+id/ime_switcher"
@@ -108,8 +104,7 @@
                     android:scaleType="centerInside"
                     android:src="@drawable/ic_ime_switcher_default"
                     android:visibility="invisible"
-                    android:contentDescription="@string/accessibility_ime_switch_button"
-                    android:background="@drawable/ripple_drawable" />
+                    android:contentDescription="@string/accessibility_ime_switch_button" />
             </FrameLayout>
         </LinearLayout>
 
@@ -205,7 +200,6 @@
                 android:src="@drawable/ic_sysbar_back"
                 systemui:keyCode="4"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_back"
                 />
             <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/home"
@@ -215,7 +209,6 @@
                 systemui:keyCode="3"
                 systemui:keyRepeat="true"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_home"
                 />
             <com.android.systemui.statusbar.policy.KeyButtonView android:id="@+id/recent_apps"
@@ -223,7 +216,6 @@
                 android:layout_height="match_parent"
                 android:src="@drawable/ic_sysbar_recent"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_recent"
                 />
             <Space 
@@ -243,9 +235,7 @@
                     android:src="@drawable/ic_sysbar_menu"
                     systemui:keyCode="82"
                     android:visibility="invisible"
-                    android:contentDescription="@string/accessibility_menu"
-                    android:background="@drawable/ripple_drawable"
-                    />
+                    android:contentDescription="@string/accessibility_menu" />
                 <com.android.systemui.statusbar.policy.KeyButtonView
                     android:id="@+id/ime_switcher"
                     android:layout_width="@dimen/navigation_extra_key_width"
@@ -254,8 +244,7 @@
                     android:src="@drawable/ic_ime_switcher_default"
                     android:visibility="invisible"
                     android:contentDescription="@string/accessibility_ime_switch_button"
-                    android:scaleType="centerInside"
-                    android:background="@drawable/ripple_drawable" />
+                    android:scaleType="centerInside" />
             </FrameLayout>
         </LinearLayout>
 
@@ -314,12 +303,4 @@
             android:layout_gravity="top"
             />
     </FrameLayout>
-
-    <!-- not used -->
-    <View android:id="@+id/rot270"
-        android:layout_height="match_parent"
-        android:layout_width="match_parent"
-        android:visibility="gone"
-        />
-
 </com.android.systemui.statusbar.phone.NavigationBarView>
diff --git a/packages/SystemUI/res/layout/data_usage.xml b/packages/SystemUI/res/layout/data_usage.xml
index 8831a05..c943f3d 100644
--- a/packages/SystemUI/res/layout/data_usage.xml
+++ b/packages/SystemUI/res/layout/data_usage.xml
@@ -14,7 +14,7 @@
      See the License for the specific language governing permissions and
      limitations under the License.
 -->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<com.android.systemui.qs.tiles.DataUsageDetailView xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
     android:paddingTop="16dp"
@@ -82,4 +82,4 @@
             android:textAppearance="@style/TextAppearance.QS.DataUsage.Secondary" />
     </LinearLayout>
 
-</LinearLayout>
\ No newline at end of file
+</com.android.systemui.qs.tiles.DataUsageDetailView>
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout/keyguard_bottom_area.xml b/packages/SystemUI/res/layout/keyguard_bottom_area.xml
index 8e9b501..ca07c87 100644
--- a/packages/SystemUI/res/layout/keyguard_bottom_area.xml
+++ b/packages/SystemUI/res/layout/keyguard_bottom_area.xml
@@ -31,7 +31,7 @@
         android:layout_gravity="bottom|center_horizontal"
         android:textStyle="italic"
         android:textColor="#ffffff"
-        android:textAppearance="?android:attr/textAppearanceSmall"/>
+        android:textAppearance="?android:attr/textAppearanceSmall" />
 
     <FrameLayout
         android:id="@+id/preview_container"
@@ -66,6 +66,7 @@
         android:layout_gravity="bottom|center_horizontal"
         android:src="@drawable/ic_lock_24dp"
         android:scaleType="center"
-        android:tint="#ffffffff" />
+        android:tint="#ffffffff"
+        android:contentDescription="@string/accessibility_unlock_button" />
 
 </com.android.systemui.statusbar.phone.KeyguardBottomAreaView>
diff --git a/packages/SystemUI/res/layout/keyguard_status_bar.xml b/packages/SystemUI/res/layout/keyguard_status_bar.xml
index fcc0f4a..b5f917a 100644
--- a/packages/SystemUI/res/layout/keyguard_status_bar.xml
+++ b/packages/SystemUI/res/layout/keyguard_status_bar.xml
@@ -44,7 +44,7 @@
         android:layout_toStartOf="@id/multi_user_switch"
         android:layout_alignWithParentIfMissing="true"
         android:layout_marginStart="16dp"
-        android:paddingEnd="2dp">
+        android:paddingEnd="@dimen/system_icons_keyguard_padding_end">
         <FrameLayout android:id="@+id/system_icons_container"
             android:layout_width="wrap_content"
             android:layout_height="@dimen/status_bar_height"
@@ -60,7 +60,8 @@
             android:paddingEnd="@dimen/battery_level_padding_end"
             android:textColor="#ffffff"
             android:visibility="gone"
-            android:textSize="@dimen/battery_level_text_size"/>
+            android:textSize="@dimen/battery_level_text_size"
+            android:importantForAccessibility="noHideDescendants"/>
     </LinearLayout>
 
     <com.android.keyguard.CarrierText
diff --git a/packages/SystemUI/res/layout/keyguard_user_switcher.xml b/packages/SystemUI/res/layout/keyguard_user_switcher.xml
index 7c918c2..3730bbe 100644
--- a/packages/SystemUI/res/layout/keyguard_user_switcher.xml
+++ b/packages/SystemUI/res/layout/keyguard_user_switcher.xml
@@ -14,7 +14,7 @@
   ~ See the License for the specific language governing permissions and
   ~ limitations under the License
   -->
-<com.android.systemui.statusbar.AlphaOptimizedLinearLayout
+<com.android.keyguard.AlphaOptimizedLinearLayout
         xmlns:android="http://schemas.android.com/apk/res/android"
         android:id="@+id/keyguard_user_switcher"
         android:orientation="vertical"
@@ -23,4 +23,4 @@
         android:gravity="end"
         android:visibility="gone"
         android:paddingTop="4dp">
-</com.android.systemui.statusbar.AlphaOptimizedLinearLayout>
+</com.android.keyguard.AlphaOptimizedLinearLayout>
diff --git a/packages/SystemUI/res/layout/lland.xml b/packages/SystemUI/res/layout/lland.xml
new file mode 100644
index 0000000..053225d
--- /dev/null
+++ b/packages/SystemUI/res/layout/lland.xml
@@ -0,0 +1,53 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+     Copyright (C) 2014 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.
+-->
+<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              android:orientation="vertical"
+              android:layout_width="match_parent"
+              android:layout_height="match_parent"
+        >
+    <com.android.systemui.egg.LLand
+            android:id="@+id/world"
+            android:layout_width="match_parent"
+            android:layout_height="match_parent">
+    </com.android.systemui.egg.LLand>
+    <TextView
+            android:id="@+id/score"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:textSize="32sp"
+            android:textColor="#FFAAAAAA"
+            android:layout_marginTop="32dp"
+            android:layout_marginLeft="16dp"
+            android:layout_gravity="top|left"
+            android:paddingLeft="16dp"
+            android:paddingRight="16dp"
+            android:paddingTop="8dp"
+            android:paddingBottom="8dp"
+            android:background="@drawable/scorecard"
+            />
+    <TextView
+            android:id="@+id/welcome"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:textSize="30sp"
+            android:textColor="#FFFFFFFF"
+            android:layout_gravity="center"
+            android:layout_marginTop="70dp"
+            android:visibility="gone"
+            />
+</FrameLayout>
+
diff --git a/packages/SystemUI/res/layout/navigation_bar.xml b/packages/SystemUI/res/layout/navigation_bar.xml
index 7616cb1..16027d9 100644
--- a/packages/SystemUI/res/layout/navigation_bar.xml
+++ b/packages/SystemUI/res/layout/navigation_bar.xml
@@ -55,7 +55,6 @@
                 systemui:keyCode="4"
                 android:layout_weight="0"
                 android:scaleType="center"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_back"
                 />
             <View 
@@ -71,7 +70,6 @@
                 systemui:keyCode="3"
                 systemui:keyRepeat="false"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_home"
                 />
             <View 
@@ -85,7 +83,6 @@
                 android:layout_height="match_parent"
                 android:src="@drawable/ic_sysbar_recent"
                 android:layout_weight="0"
-                android:background="@drawable/ripple_drawable"
                 android:contentDescription="@string/accessibility_recent"
                 />
             <FrameLayout
@@ -99,7 +96,6 @@
                     android:contentDescription="@string/accessibility_menu"
                     android:src="@drawable/ic_sysbar_menu"
                     android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable"
                     systemui:keyCode="82" />
 
                 <com.android.systemui.statusbar.policy.KeyButtonView
@@ -109,8 +105,7 @@
                     android:contentDescription="@string/accessibility_ime_switch_button"
                     android:scaleType="centerInside"
                     android:src="@drawable/ic_ime_switcher_default"
-                    android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable" />
+                    android:visibility="invisible" />
             </FrameLayout>
 
         </LinearLayout>
@@ -202,8 +197,7 @@
                     android:contentDescription="@string/accessibility_ime_switch_button"
                     android:scaleType="centerInside"
                     android:src="@drawable/ic_ime_switcher_default"
-                    android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable" />
+                    android:visibility="invisible" />
 
                 <com.android.systemui.statusbar.policy.KeyButtonView
                     android:id="@+id/menu"
@@ -212,7 +206,6 @@
                     android:contentDescription="@string/accessibility_menu"
                     android:src="@drawable/ic_sysbar_menu_land"
                     android:visibility="invisible"
-                    android:background="@drawable/ripple_drawable"
                     systemui:keyCode="82" />
             </FrameLayout>
 
@@ -222,7 +215,6 @@
                 android:src="@drawable/ic_sysbar_recent_land"
                 android:layout_weight="0"
                 android:contentDescription="@string/accessibility_recent"
-                android:background="@drawable/ripple_drawable"
                 />
             <View 
                 android:layout_height="match_parent"
@@ -238,7 +230,6 @@
                 systemui:keyRepeat="false"
                 android:layout_weight="0"
                 android:contentDescription="@string/accessibility_home"
-                android:background="@drawable/ripple_drawable"
                 />
             <View 
                 android:layout_height="match_parent"
@@ -254,7 +245,6 @@
                 systemui:keyCode="4"
                 android:layout_weight="0"
                 android:contentDescription="@string/accessibility_back"
-                android:background="@drawable/ripple_drawable"
                 />
             <View
                 android:layout_height="40dp"
@@ -322,11 +312,4 @@
             />
     </FrameLayout>
 
-    <!-- not used -->
-    <View android:id="@+id/rot270"
-        android:layout_height="match_parent"
-        android:layout_width="match_parent"
-        android:visibility="gone"
-        />
-
 </com.android.systemui.statusbar.phone.NavigationBarView>
diff --git a/packages/SystemUI/res/layout/notification_guts.xml b/packages/SystemUI/res/layout/notification_guts.xml
index d65a23e..d52c274 100644
--- a/packages/SystemUI/res/layout/notification_guts.xml
+++ b/packages/SystemUI/res/layout/notification_guts.xml
@@ -15,11 +15,10 @@
     limitations under the License.
 -->
 
-<FrameLayout
+<com.android.systemui.statusbar.NotificationGuts
     xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
-    android:background="@drawable/notification_guts_bg"
     android:id="@+id/notification_guts"
     android:visibility="gone"
     android:clickable="true"
@@ -53,7 +52,7 @@
                     android:layout_height="wrap_content"
                     android:layout_gravity="center_vertical|start"
                     android:layout_weight="1"
-                    android:textAppearance="@*android:style/TextAppearance.StatusBar.Material.EventContent.Title"
+                    android:textAppearance="@*android:style/TextAppearance.Material.Notification.Title"
                     android:textColor="@color/notification_guts_title_color"
                     />
             <DateTimeView
@@ -62,7 +61,7 @@
                     android:layout_height="wrap_content"
                     android:layout_weight="0"
                     android:layout_gravity="center_vertical|start"
-                    android:textAppearance="@*android:style/TextAppearance.StatusBar.Material.EventContent.Time"
+                    android:textAppearance="@*android:style/TextAppearance.Material.Notification.Time"
                     android:textColor="@color/notification_guts_text_color"
                     />
             <TextView
@@ -70,7 +69,7 @@
                     android:layout_height="wrap_content"
                     android:id="@+id/debug_info"
                     android:layout_weight="0"
-                    android:textAppearance="@*android:style/TextAppearance.StatusBar.Material.EventContent.Time"
+                    android:textAppearance="@*android:style/TextAppearance.Material.Notification.Time"
                     android:layout_gravity="bottom|start"
                     android:visibility="gone"
                     android:textColor="@color/notification_guts_text_color"
@@ -78,13 +77,23 @@
         </LinearLayout>
 
         <ImageButton style="@android:style/Widget.Material.Light.Button.Borderless.Small"
+                 android:id="@+id/notification_inspect_app_provided_settings"
+                 android:layout_width="52dp"
+                 android:layout_height="match_parent"
+                 android:layout_weight="0"
+                 android:gravity="center"
+                 android:src="@drawable/ic_settings"
+                 android:visibility="gone"
+                />
+
+        <ImageButton style="@android:style/Widget.Material.Light.Button.Borderless.Small"
                 android:id="@+id/notification_inspect_item"
                 android:layout_width="52dp"
                 android:layout_height="match_parent"
                 android:layout_weight="0"
                 android:gravity="center"
                 android:contentDescription="@string/status_bar_notification_inspect_item_title"
-                android:src="@drawable/ic_settings"
+                android:src="@drawable/ic_info"
                 />
     </LinearLayout>
-</FrameLayout>
+</com.android.systemui.statusbar.NotificationGuts>
diff --git a/packages/SystemUI/res/layout/notification_public_default.xml b/packages/SystemUI/res/layout/notification_public_default.xml
new file mode 100644
index 0000000..acfc4bb
--- /dev/null
+++ b/packages/SystemUI/res/layout/notification_public_default.xml
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:internal="http://schemas.android.com/apk/prv/res/android"
+    android:id="@+id/status_bar_latest_event_content"
+    android:layout_width="match_parent"
+    android:layout_height="64dp"
+    internal:layout_minHeight="64dp"
+    internal:layout_maxHeight="64dp"
+    >
+    <ImageView android:id="@+id/icon"
+        android:layout_width="40dp"
+        android:layout_height="40dp"
+        android:layout_marginTop="12dp"
+        android:layout_marginStart="12dp"
+        android:layout_marginEnd="12dp"
+        android:scaleType="centerInside"
+        />
+    <DateTimeView android:id="@+id/time"
+        android:textAppearance="@android:style/TextAppearance.Material.Notification.Time"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginEnd="8dp"
+        android:layout_alignParentEnd="true"
+        android:layout_alignBaseline="@id/title"
+        android:singleLine="true"
+        android:gravity="center"
+        android:paddingStart="8dp"
+        android:visibility="gone"
+        />
+    <TextView android:id="@+id/title"
+        android:textAppearance="@android:style/TextAppearance.Material.Notification.Title"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_toEndOf="@id/icon"
+        android:layout_toStartOf="@id/time"
+        android:singleLine="true"
+        android:ellipsize="marquee"
+        android:fadingEdge="horizontal"
+        />
+    <ImageView android:id="@+id/profile_badge_line3"
+        android:layout_width="@*android:dimen/notification_badge_size"
+        android:layout_height="@*android:dimen/notification_badge_size"
+        android:layout_below="@id/title"
+        android:layout_marginStart="4dp"
+        android:layout_marginEnd="8dp"
+        android:layout_alignParentEnd="true"
+        android:scaleType="fitCenter"
+        android:visibility="gone"
+        />
+    <TextView android:id="@+id/text"
+        android:textAppearance="@android:style/TextAppearance.Material.Notification"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_alignStart="@id/title"
+        android:layout_below="@id/title"
+        android:layout_toStartOf="@id/profile_badge_line3"
+        android:singleLine="true"
+        android:ellipsize="marquee"
+        android:fadingEdge="horizontal"
+        />
+</RelativeLayout>
diff --git a/packages/SystemUI/res/layout/qs_detail.xml b/packages/SystemUI/res/layout/qs_detail.xml
index 5869bf3..2eb99ba 100644
--- a/packages/SystemUI/res/layout/qs_detail.xml
+++ b/packages/SystemUI/res/layout/qs_detail.xml
@@ -40,8 +40,8 @@
                 android:layout_height="wrap_content"
                 android:layout_marginEnd="8dp"
                 android:minWidth="132dp"
-                android:text="@string/quick_settings_more_settings"
-                android:textAppearance="@style/TextAppearance.QS.DetailButton" />
+                android:textAppearance="@style/TextAppearance.QS.DetailButton"
+                android:focusable="true" />
 
         <TextView
                 android:id="@android:id/button1"
@@ -49,8 +49,8 @@
                 android:layout_width="wrap_content"
                 android:layout_height="wrap_content"
                 android:minWidth="88dp"
-                android:text="@string/quick_settings_done"
-                android:textAppearance="@style/TextAppearance.QS.DetailButton" />
+                android:textAppearance="@style/TextAppearance.QS.DetailButton"
+                android:focusable="true"/>
 
     </LinearLayout>
-</LinearLayout>
\ No newline at end of file
+</LinearLayout>
diff --git a/packages/SystemUI/res/layout/qs_detail_header.xml b/packages/SystemUI/res/layout/qs_detail_header.xml
index f3f1918..48bb213 100644
--- a/packages/SystemUI/res/layout/qs_detail_header.xml
+++ b/packages/SystemUI/res/layout/qs_detail_header.xml
@@ -19,6 +19,7 @@
     android:layout_height="wrap_content"
     android:layout_alignParentBottom="true"
     android:padding="@dimen/qs_panel_padding"
+    android:visibility="invisible"
     android:background="@drawable/btn_borderless_rect" >
 
     <TextView
diff --git a/packages/SystemUI/res/layout/qs_user_detail_item.xml b/packages/SystemUI/res/layout/qs_user_detail_item.xml
index 2322f16..af22f03 100644
--- a/packages/SystemUI/res/layout/qs_user_detail_item.xml
+++ b/packages/SystemUI/res/layout/qs_user_detail_item.xml
@@ -44,7 +44,7 @@
             android:id="@+id/user_name"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
-            android:textSize="14sp"
+            android:textSize="@dimen/qs_detail_item_secondary_text_size"
             android:textColor="@color/qs_user_detail_name"
             android:gravity="center_horizontal" />
 
diff --git a/packages/SystemUI/res/layout/recents_empty.xml b/packages/SystemUI/res/layout/recents_empty.xml
index 1ef9cad..4b68e77 100644
--- a/packages/SystemUI/res/layout/recents_empty.xml
+++ b/packages/SystemUI/res/layout/recents_empty.xml
@@ -23,6 +23,6 @@
     android:textSize="16sp"
     android:textColor="#ffffffff"
     android:text="@string/recents_empty_message"
-    android:fontFamily="sans-serif-light"
+    android:fontFamily="sans-serif"
     android:background="#80000000"
     android:visibility="gone" />
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout/recents_task_view.xml b/packages/SystemUI/res/layout/recents_task_view.xml
index 828065b..d1d3828 100644
--- a/packages/SystemUI/res/layout/recents_task_view.xml
+++ b/packages/SystemUI/res/layout/recents_task_view.xml
@@ -15,67 +15,34 @@
 -->
 <com.android.systemui.recents.views.TaskView
     xmlns:android="http://schemas.android.com/apk/res/android"
-    android:layout_width="match_parent" 
+    android:layout_width="match_parent"
     android:layout_height="match_parent"
-    android:focusable="true"
-    android:background="#FFffffff">
-    <com.android.systemui.recents.views.TaskViewThumbnail
-        android:id="@+id/task_view_thumbnail"
+    android:focusable="true">
+    <FrameLayout
+        android:id="@+id/task_view_content"
         android:layout_width="match_parent"
-        android:layout_height="match_parent" />
-    <com.android.systemui.recents.views.TaskViewHeader
-        android:id="@+id/task_view_bar"
-        android:layout_width="match_parent"
-        android:layout_height="@dimen/recents_task_bar_height"
-        android:layout_gravity="top|center_horizontal">
-        <com.android.systemui.recents.views.FixedSizeImageView
-            android:id="@+id/application_icon"
-            android:layout_width="@dimen/recents_task_view_application_icon_size"
-            android:layout_height="@dimen/recents_task_view_application_icon_size"
-            android:layout_marginStart="8dp"
-            android:layout_gravity="center_vertical|start"
-            android:padding="8dp"
-            android:background="@drawable/recents_button_bg" />
-        <TextView
-            android:id="@+id/activity_description"
+        android:layout_height="match_parent">
+        <com.android.systemui.recents.views.TaskViewThumbnail
+            android:id="@+id/task_view_thumbnail"
             android:layout_width="match_parent"
-            android:layout_height="wrap_content"
-            android:layout_gravity="center_vertical|start"
-            android:layout_marginStart="64dp"
-            android:layout_marginEnd="64dp"
-            android:textSize="16sp"
-            android:textColor="#ffffffff"
-            android:text="@string/recents_empty_message"
-            android:fontFamily="sans-serif-medium"
-            android:singleLine="true"
-            android:maxLines="2"
-            android:ellipsize="marquee"
-            android:fadingEdge="horizontal" />
-        <com.android.systemui.recents.views.FixedSizeImageView
-            android:id="@+id/dismiss_task"
+            android:layout_height="match_parent" />
+        <include layout="@layout/recents_task_view_header" />
+        <FrameLayout
+            android:id="@+id/lock_to_app_fab"
             android:layout_width="48dp"
             android:layout_height="48dp"
-            android:layout_marginEnd="4dp"
-            android:layout_gravity="center_vertical|end"
-            android:padding="12dp"
-            android:background="@drawable/recents_button_bg"
-            android:visibility="invisible"
-            android:src="@drawable/recents_dismiss_light" />
-    </com.android.systemui.recents.views.TaskViewHeader>
-    <FrameLayout
-        android:id="@+id/lock_to_app_fab"
-        android:layout_width="48dp"
-        android:layout_height="48dp"
-        android:layout_gravity="bottom|right"
-        android:layout_marginRight="15dp"
-        android:layout_marginBottom="15dp"
-        android:contentDescription="@string/recents_lock_to_app_button_label"
-        android:background="@drawable/recents_lock_to_task_button_bg">
-        <ImageView
-            android:layout_width="24dp"
-            android:layout_height="24dp"
-            android:layout_gravity="center"
-            android:src="@drawable/recents_lock_to_app_pin" />
+            android:layout_gravity="bottom|right"
+            android:layout_marginRight="15dp"
+            android:layout_marginBottom="15dp"
+            android:translationZ="2dp"
+            android:contentDescription="@string/recents_lock_to_app_button_label"
+            android:background="@drawable/recents_lock_to_task_button_bg">
+            <ImageView
+                android:layout_width="24dp"
+                android:layout_height="24dp"
+                android:layout_gravity="center"
+                android:src="@drawable/recents_lock_to_app_pin" />
+        </FrameLayout>
     </FrameLayout>
 </com.android.systemui.recents.views.TaskView>
 
diff --git a/packages/SystemUI/res/layout/recents_task_view_header.xml b/packages/SystemUI/res/layout/recents_task_view_header.xml
new file mode 100644
index 0000000..f1d8ad0
--- /dev/null
+++ b/packages/SystemUI/res/layout/recents_task_view_header.xml
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2014 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.
+-->
+<com.android.systemui.recents.views.TaskViewHeader
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@+id/task_view_bar"
+    android:layout_width="match_parent"
+    android:layout_height="@dimen/recents_task_bar_height"
+    android:layout_gravity="top|center_horizontal">
+    <com.android.systemui.recents.views.FixedSizeImageView
+        android:id="@+id/application_icon"
+        android:layout_width="@dimen/recents_task_view_application_icon_size"
+        android:layout_height="@dimen/recents_task_view_application_icon_size"
+        android:layout_marginStart="8dp"
+        android:layout_gravity="center_vertical|start"
+        android:padding="8dp"
+        android:background="@drawable/recents_button_bg" />
+    <TextView
+        android:id="@+id/activity_description"
+        android:layout_width="match_parent"
+        android:layout_height="wrap_content"
+        android:layout_gravity="center_vertical|start"
+        android:layout_marginStart="64dp"
+        android:layout_marginEnd="64dp"
+        android:textSize="16sp"
+        android:textColor="#ffffffff"
+        android:text="@string/recents_empty_message"
+        android:fontFamily="sans-serif-medium"
+        android:singleLine="true"
+        android:maxLines="2"
+        android:ellipsize="marquee"
+        android:fadingEdge="horizontal" />
+    <com.android.systemui.recents.views.FixedSizeImageView
+        android:id="@+id/dismiss_task"
+        android:layout_width="48dp"
+        android:layout_height="48dp"
+        android:layout_marginEnd="4dp"
+        android:layout_gravity="center_vertical|end"
+        android:padding="12dp"
+        android:background="@drawable/recents_button_bg"
+        android:visibility="invisible"
+        android:src="@drawable/recents_dismiss_light" />
+</com.android.systemui.recents.views.TaskViewHeader>
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout/signal_cluster_view.xml b/packages/SystemUI/res/layout/signal_cluster_view.xml
index ae54f8c..5889c55 100644
--- a/packages/SystemUI/res/layout/signal_cluster_view.xml
+++ b/packages/SystemUI/res/layout/signal_cluster_view.xml
@@ -25,6 +25,13 @@
     android:gravity="center_vertical"
     android:orientation="horizontal"
     >
+    <ImageView
+        android:id="@+id/vpn"
+        android:layout_height="wrap_content"
+        android:layout_width="wrap_content"
+        android:paddingEnd="6dp"
+        android:src="@drawable/stat_sys_vpn_ic"
+        />
     <FrameLayout
         android:id="@+id/wifi_combo"
         android:layout_height="wrap_content"
@@ -37,20 +44,15 @@
             />
     </FrameLayout>
     <View
-        android:layout_height="6dp"
-        android:layout_width="6dp"
+        android:id="@+id/wifi_signal_spacer"
+        android:layout_width="4dp"
+        android:layout_height="4dp"
         android:visibility="gone"
-        android:id="@+id/spacer"
         />
     <FrameLayout
         android:layout_height="wrap_content"
         android:layout_width="wrap_content"
         >
-        <View
-            android:layout_height="6dp"
-            android:layout_width="6dp"
-            android:visibility="invisible"
-            />
         <FrameLayout
             android:id="@+id/mobile_combo"
             android:layout_width="wrap_content"
@@ -68,6 +70,12 @@
                 />
         </FrameLayout>
     </FrameLayout>
+    <View
+        android:id="@+id/wifi_airplane_spacer"
+        android:layout_width="4dp"
+        android:layout_height="4dp"
+        android:visibility="gone"
+        />
     <ImageView
         android:id="@+id/airplane"
         android:layout_height="wrap_content"
diff --git a/packages/SystemUI/res/layout/split_clock_view.xml b/packages/SystemUI/res/layout/split_clock_view.xml
index 87b7051..808460a 100644
--- a/packages/SystemUI/res/layout/split_clock_view.xml
+++ b/packages/SystemUI/res/layout/split_clock_view.xml
@@ -39,6 +39,7 @@
 
     <!-- Empty text view so we have the same height when expanded/collapsed-->
     <TextView
+        android:id="@+id/empty_time_view"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
         android:visibility="invisible"
diff --git a/packages/SystemUI/res/layout/status_bar.xml b/packages/SystemUI/res/layout/status_bar.xml
index beb8e00..245c128 100644
--- a/packages/SystemUI/res/layout/status_bar.xml
+++ b/packages/SystemUI/res/layout/status_bar.xml
@@ -43,8 +43,8 @@
     <LinearLayout android:id="@+id/status_bar_contents"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
-        android:paddingStart="6dip"
-        android:paddingEnd="6dip"
+        android:paddingStart="6dp"
+        android:paddingEnd="8dp"
         android:orientation="horizontal"
         >
 
@@ -57,7 +57,7 @@
             >
             <!-- The alpha of this area is both controlled from PhoneStatusBarTransitions and
                  PhoneStatusBar (DISABLE_NOTIFICATION_ICONS), so we need two views here. -->
-            <com.android.systemui.statusbar.AlphaOptimizedLinearLayout
+            <com.android.keyguard.AlphaOptimizedLinearLayout
                 android:id="@+id/notification_icon_area_inner"
                 android:layout_width="match_parent"
                 android:layout_height="match_parent"
@@ -74,10 +74,10 @@
                     android:layout_alignParentStart="true"
                     android:gravity="center_vertical"
                     android:orientation="horizontal"/>
-            </com.android.systemui.statusbar.AlphaOptimizedLinearLayout>
+            </com.android.keyguard.AlphaOptimizedLinearLayout>
         </com.android.systemui.statusbar.AlphaOptimizedFrameLayout>
 
-        <com.android.systemui.statusbar.AlphaOptimizedLinearLayout android:id="@+id/system_icon_area"
+        <com.android.keyguard.AlphaOptimizedLinearLayout android:id="@+id/system_icon_area"
             android:layout_width="wrap_content"
             android:layout_height="match_parent"
             android:orientation="horizontal"
@@ -91,10 +91,10 @@
                 android:layout_width="wrap_content"
                 android:layout_height="match_parent"
                 android:singleLine="true"
-                android:paddingStart="6dip"
+                android:paddingStart="7dp"
                 android:gravity="center_vertical|start"
                 />
-        </com.android.systemui.statusbar.AlphaOptimizedLinearLayout>
+        </com.android.keyguard.AlphaOptimizedLinearLayout>
     </LinearLayout>
 
     <ViewStub
diff --git a/packages/SystemUI/res/layout/status_bar_expanded.xml b/packages/SystemUI/res/layout/status_bar_expanded.xml
index cc449c5..96f9b91 100644
--- a/packages/SystemUI/res/layout/status_bar_expanded.xml
+++ b/packages/SystemUI/res/layout/status_bar_expanded.xml
@@ -50,10 +50,6 @@
         android:visibility="gone"
         />
 
-    <include
-        layout="@layout/keyguard_bottom_area"
-        android:visibility="gone" />
-
     <com.android.systemui.statusbar.phone.NotificationsQuickSettingsContainer
         android:layout_width="match_parent"
         android:layout_height="match_parent"
@@ -101,7 +97,7 @@
             android:layout_width="@dimen/notification_panel_width"
             android:layout_height="match_parent"
             android:layout_gravity="@integer/notification_panel_layout_gravity"
-            android:layout_marginBottom="@dimen/close_handle_underlap"/>
+            android:layout_marginBottom="@dimen/close_handle_underlap" />
 
         <ViewStub
             android:id="@+id/keyguard_user_switcher"
@@ -117,6 +113,10 @@
 
     </com.android.systemui.statusbar.phone.NotificationsQuickSettingsContainer>
 
+    <include
+            layout="@layout/keyguard_bottom_area"
+            android:visibility="gone" />
+
     <include layout="@layout/status_bar_expanded_header" />
 
     <com.android.systemui.statusbar.AlphaOptimizedView
diff --git a/packages/SystemUI/res/layout/status_bar_expanded_header.xml b/packages/SystemUI/res/layout/status_bar_expanded_header.xml
index 079b97b..7ea9145 100644
--- a/packages/SystemUI/res/layout/status_bar_expanded_header.xml
+++ b/packages/SystemUI/res/layout/status_bar_expanded_header.xml
@@ -36,7 +36,7 @@
         android:layout_width="@dimen/multi_user_switch_width_collapsed"
         android:layout_height="@dimen/status_bar_header_height"
         android:layout_alignParentEnd="true"
-        android:background="@drawable/ripple_drawable">
+        android:background="@drawable/ripple_drawable" >
         <ImageView android:id="@+id/multi_user_avatar"
             android:layout_width="24dp"
             android:layout_height="24dp"
@@ -44,14 +44,14 @@
             android:scaleType="centerInside"/>
     </com.android.systemui.statusbar.phone.MultiUserSwitch>
 
-    <ImageButton android:id="@+id/settings_button"
+    <com.android.keyguard.AlphaOptimizedImageButton android:id="@+id/settings_button"
         style="@android:style/Widget.Material.Button.Borderless"
         android:layout_toStartOf="@id/multi_user_switch"
         android:layout_width="48dp"
         android:layout_height="@dimen/status_bar_header_height"
         android:background="@drawable/ripple_drawable"
         android:src="@drawable/ic_settings"
-        android:contentDescription="@string/accessibility_desc_settings"/>
+        android:contentDescription="@string/accessibility_desc_settings" />
 
     <LinearLayout android:id="@+id/system_icons_super_container"
         android:layout_width="wrap_content"
@@ -60,11 +60,14 @@
         android:layout_alignWithParentIfMissing="true"
         android:layout_marginStart="16dp"
         android:background="@drawable/ripple_drawable"
-        android:paddingEnd="2dp">
+        android:paddingEnd="4dp" >
         <FrameLayout android:id="@+id/system_icons_container"
             android:layout_width="wrap_content"
             android:layout_height="@dimen/status_bar_height"
-            android:layout_gravity="center_vertical"/>
+            android:layout_gravity="center_vertical"
+            >
+            <include layout="@layout/system_icons" />
+        </FrameLayout>
         <TextView android:id="@+id/battery_level"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
@@ -72,7 +75,8 @@
             android:layout_marginStart="@dimen/header_battery_margin_expanded"
             android:paddingEnd="@dimen/battery_level_padding_end"
             android:textColor="#ffffff"
-            android:textSize="@dimen/battery_level_text_size"/>
+            android:textSize="@dimen/battery_level_text_size"
+            android:importantForAccessibility="noHideDescendants"/>
     </LinearLayout>
 
     <TextView
@@ -86,6 +90,7 @@
         android:visibility="gone"
         android:textAppearance="@style/TextAppearance.StatusBar.Expanded.EmergencyCallsOnly"
         android:text="@*android:string/emergency_calls_only"
+        android:singleLine="true"
         android:gravity="center_vertical" />
 
     <FrameLayout
@@ -101,6 +106,7 @@
             android:singleLine="true"
             android:textAppearance="@style/TextAppearance.StatusBar.Expanded.Date"
             android:layout_below="@id/clock"
+            systemui:datePattern="@string/abbrev_wday_month_day_no_year_alarm"
             />
 
         <com.android.systemui.statusbar.policy.DateView android:id="@+id/date_expanded"
diff --git a/packages/SystemUI/res/layout/status_bar_notification_dismiss_all.xml b/packages/SystemUI/res/layout/status_bar_notification_dismiss_all.xml
index f506adc..9e0f82cb 100644
--- a/packages/SystemUI/res/layout/status_bar_notification_dismiss_all.xml
+++ b/packages/SystemUI/res/layout/status_bar_notification_dismiss_all.xml
@@ -21,11 +21,12 @@
         android:layout_height="wrap_content"
         android:visibility="gone"
         >
-    <ImageButton
+    <com.android.systemui.statusbar.DismissViewImageButton
             android:id="@+id/dismiss_text"
             android:layout_width="48dp"
             android:layout_height="48dp"
             android:layout_gravity="end"
             android:src="@drawable/ic_dismiss_all"
-            android:background="@drawable/ripple_drawable" />
+            android:background="@drawable/ripple_drawable"
+            android:contentDescription="@string/accessibility_clear_all" />
 </com.android.systemui.statusbar.DismissView>
diff --git a/packages/SystemUI/res/layout/status_bar_notification_keyguard_overflow.xml b/packages/SystemUI/res/layout/status_bar_notification_keyguard_overflow.xml
index eff3758..ef85847 100644
--- a/packages/SystemUI/res/layout/status_bar_notification_keyguard_overflow.xml
+++ b/packages/SystemUI/res/layout/status_bar_notification_keyguard_overflow.xml
@@ -38,8 +38,8 @@
             android:id="@+id/more_text"
             android:layout_width="32dp"
             android:layout_height="32dp"
-            android:layout_marginStart="20dp"
-            android:layout_marginEnd="16dp"
+            android:layout_marginStart="16dp"
+            android:layout_marginEnd="12dp"
             android:layout_gravity="center_vertical"
             android:background="@drawable/keyguard_overflow_number_background"
             android:gravity="center"
@@ -64,9 +64,4 @@
             />
     </LinearLayout>
 
-    <com.android.systemui.statusbar.NotificationScrimView
-        android:id="@+id/scrim_view"
-        android:layout_width="match_parent"
-        android:layout_height="match_parent" />
-
 </com.android.systemui.statusbar.NotificationOverflowContainer>
diff --git a/packages/SystemUI/res/layout/status_bar_notification_row.xml b/packages/SystemUI/res/layout/status_bar_notification_row.xml
index ef4e27c..e9d86d6 100644
--- a/packages/SystemUI/res/layout/status_bar_notification_row.xml
+++ b/packages/SystemUI/res/layout/status_bar_notification_row.xml
@@ -52,16 +52,12 @@
         android:paddingStart="8dp"
         />
 
-    <include
-        layout="@layout/notification_guts"
-        android:id="@+id/notification_guts"
+    <ViewStub
+        android:layout="@layout/notification_guts"
+        android:id="@+id/notification_guts_stub"
+        android:inflatedId="@+id/notification_guts"
         android:layout_width="match_parent"
         android:layout_height="match_parent"
         />
 
-    <com.android.systemui.statusbar.NotificationScrimView
-        android:id="@+id/scrim_view"
-        android:layout_width="match_parent"
-        android:layout_height="match_parent" />
-
 </com.android.systemui.statusbar.ExpandableNotificationRow>
diff --git a/packages/SystemUI/res/layout/status_bar_search_panel.xml b/packages/SystemUI/res/layout/status_bar_search_panel.xml
index f025abd..e0520ef6 100644
--- a/packages/SystemUI/res/layout/status_bar_search_panel.xml
+++ b/packages/SystemUI/res/layout/status_bar_search_panel.xml
@@ -30,17 +30,14 @@
         android:id="@+id/search_panel_scrim"
         android:background="@drawable/search_panel_scrim" />
 
-    <FrameLayout
-        style="@style/SearchPanelCard"
-        android:id="@+id/search_panel_card"
-        android:background="@drawable/search_panel_card_bg"
-        android:elevation="12dp">
+    <com.android.systemui.SearchPanelCircleView
+        style="@style/SearchPanelCircle"
+        android:id="@+id/search_panel_circle">
 
         <ImageView
-            style="@style/SearchPanelLogo"
             android:layout_width="wrap_content"
             android:layout_height="wrap_content"
             android:id="@+id/search_logo" />
-    </FrameLayout>
+    </com.android.systemui.SearchPanelCircleView>
 
 </com.android.systemui.SearchPanelView>
diff --git a/packages/SystemUI/res/layout/super_status_bar.xml b/packages/SystemUI/res/layout/super_status_bar.xml
index 365a7d2..29fec41 100644
--- a/packages/SystemUI/res/layout/super_status_bar.xml
+++ b/packages/SystemUI/res/layout/super_status_bar.xml
@@ -26,22 +26,6 @@
     android:fitsSystemWindows="true"
     android:descendantFocusability="afterDescendants">
 
-    <FrameLayout android:id="@+id/brightness_mirror"
-            android:layout_width="@dimen/notification_panel_width"
-            android:layout_height="wrap_content"
-            android:layout_gravity="@integer/notification_panel_layout_gravity"
-            android:paddingLeft="@dimen/notification_side_padding"
-            android:paddingRight="@dimen/notification_side_padding"
-            android:visibility="gone">
-        <FrameLayout
-                android:layout_width="match_parent"
-                android:layout_height="match_parent"
-                android:elevation="2dp"
-                android:background="@drawable/brightness_mirror_background">
-            <include layout="@layout/quick_settings_brightness_dialog" />
-        </FrameLayout>
-    </FrameLayout>
-
     <com.android.systemui.statusbar.AlphaOptimizedFrameLayout
             android:id="@+id/backdrop"
             android:layout_width="match_parent"
@@ -67,6 +51,24 @@
         android:layout_width="match_parent"
         android:layout_height="@dimen/status_bar_height" />
 
+    <FrameLayout android:id="@+id/brightness_mirror"
+                 android:layout_width="@dimen/notification_panel_width"
+                 android:layout_height="wrap_content"
+                 android:layout_gravity="@integer/notification_panel_layout_gravity"
+                 android:paddingLeft="@dimen/notification_side_padding"
+                 android:paddingRight="@dimen/notification_side_padding"
+                 android:visibility="gone">
+        <FrameLayout
+                android:layout_width="match_parent"
+                android:layout_height="match_parent"
+                android:elevation="2dp"
+                android:background="@drawable/brightness_mirror_background">
+            <include layout="@layout/quick_settings_brightness_dialog"
+                     android:layout_width="match_parent"
+                     android:layout_height="wrap_content" />
+        </FrameLayout>
+    </FrameLayout>
+
     <com.android.systemui.statusbar.phone.PanelHolder
         android:id="@+id/panel_holder"
         android:layout_width="match_parent"
diff --git a/packages/SystemUI/res/layout/system_icons.xml b/packages/SystemUI/res/layout/system_icons.xml
index 69f9c142..21386ef 100644
--- a/packages/SystemUI/res/layout/system_icons.xml
+++ b/packages/SystemUI/res/layout/system_icons.xml
@@ -20,7 +20,7 @@
     android:layout_height="match_parent"
     android:gravity="center_vertical">
 
-    <com.android.systemui.statusbar.AlphaOptimizedLinearLayout android:id="@+id/statusIcons"
+    <com.android.keyguard.AlphaOptimizedLinearLayout android:id="@+id/statusIcons"
         android:layout_width="wrap_content"
         android:layout_height="match_parent"
         android:gravity="center_vertical"
@@ -30,12 +30,12 @@
         android:id="@+id/signal_cluster"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:layout_marginStart="2dp"/>
+        android:layout_marginStart="2.5dp"/>
 
     <!-- battery must be padded below to match assets -->
     <com.android.systemui.BatteryMeterView android:id="@+id/battery"
-        android:layout_height="16dp"
-        android:layout_width="10.5dp"
-        android:layout_marginBottom="0.33dp"
-        android:layout_marginStart="4dip"/>
+        android:layout_height="14.5dp"
+        android:layout_width="9.5dp"
+        android:layout_marginBottom="@dimen/battery_margin_bottom"
+        android:layout_marginStart="7dp"/>
 </LinearLayout>
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout/volume_panel.xml b/packages/SystemUI/res/layout/volume_panel.xml
index c85a750..4d8aaa7 100644
--- a/packages/SystemUI/res/layout/volume_panel.xml
+++ b/packages/SystemUI/res/layout/volume_panel.xml
@@ -25,7 +25,7 @@
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:background="@color/system_secondary_color"
-        android:paddingTop="12dp"
+        android:paddingTop="8dp"
         android:paddingLeft="8dp"
         android:paddingRight="8dp"
         android:clipChildren="false" />
diff --git a/packages/SystemUI/res/layout/volume_panel_item.xml b/packages/SystemUI/res/layout/volume_panel_item.xml
index 18b496c..85e3fb3 100644
--- a/packages/SystemUI/res/layout/volume_panel_item.xml
+++ b/packages/SystemUI/res/layout/volume_panel_item.xml
@@ -29,14 +29,30 @@
         android:background="@drawable/btn_borderless_rect"
         android:contentDescription="@null" />
 
-    <SeekBar
-        android:id="@+id/seekbar"
+    <FrameLayout
         android:layout_width="0dp"
         android:layout_height="wrap_content"
-        android:layout_weight="1"
-        android:paddingBottom="0dp"
-        android:paddingEnd="16dp"
-        android:paddingStart="8dp"
-        android:paddingTop="0dip" />
+        android:layout_weight="1" >
 
+        <TextView
+            android:id="@+id/suppressor"
+            android:visibility="gone"
+            android:textAppearance="@style/TextAppearance.QS.VolumeSuppressor"
+            android:paddingStart="8dp"
+            android:paddingEnd="8dp"
+            android:singleLine="true"
+            android:ellipsize="end"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content" />
+
+        <SeekBar
+            android:id="@+id/seekbar"
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:paddingBottom="0dp"
+            android:paddingEnd="16dp"
+            android:paddingStart="8dp"
+            android:paddingTop="0dp" />
+
+    </FrameLayout>
 </LinearLayout>
\ No newline at end of file
diff --git a/packages/SystemUI/res/layout/zen_mode_panel.xml b/packages/SystemUI/res/layout/zen_mode_panel.xml
index 9d5f7bd..bfeac9d 100644
--- a/packages/SystemUI/res/layout/zen_mode_panel.xml
+++ b/packages/SystemUI/res/layout/zen_mode_panel.xml
@@ -35,12 +35,12 @@
             android:layout_height="wrap_content"
             android:layout_marginLeft="@dimen/qs_panel_padding"
             android:layout_marginRight="@dimen/qs_panel_padding"
-            android:layout_marginTop="8dp"
-            android:layout_marginBottom="12dp"
+            android:layout_marginTop="4dp"
+            android:layout_marginBottom="8dp"
             android:clipChildren="false" />
     </FrameLayout>
 
-    <FrameLayout
+    <RelativeLayout
         android:id="@+id/zen_subhead"
         android:layout_width="match_parent"
         android:layout_height="62dp"
@@ -73,13 +73,14 @@
             android:id="@+id/zen_more_settings"
             android:layout_width="48dp"
             android:layout_height="48dp"
-            android:layout_gravity="end|center_vertical"
+            android:layout_alignParentEnd="true"
             android:background="@drawable/btn_borderless_rect"
             android:clickable="true"
             android:contentDescription="@null"
             android:scaleType="center"
             android:src="@drawable/ic_settings" />
-    </FrameLayout>
+
+    </RelativeLayout>
 
     <LinearLayout
         android:id="@+id/zen_conditions"
@@ -88,14 +89,4 @@
         android:orientation="vertical"
         android:paddingBottom="@dimen/qs_panel_padding" />
 
-    <TextView
-        android:id="@+id/zen_alarm_warning"
-        android:layout_width="match_parent"
-        android:layout_height="wrap_content"
-        android:layout_marginBottom="@dimen/qs_panel_padding"
-        android:paddingLeft="@dimen/qs_panel_padding"
-        android:paddingRight="@dimen/qs_panel_padding"
-        android:paddingTop="4dp"
-        android:paddingBottom="4dp"
-        android:textAppearance="@style/TextAppearance.QS.Subhead" />
 </com.android.systemui.volume.ZenModePanel>
diff --git a/packages/SystemUI/res/values-af/config.xml b/packages/SystemUI/res/values-af/config.xml
new file mode 100644
index 0000000..38497cf
--- /dev/null
+++ b/packages/SystemUI/res/values-af/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 s,10 s,30 s,60 s,120 s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-af/strings.xml b/packages/SystemUI/res/values-af/strings.xml
index a514324..b5c8722 100644
--- a/packages/SystemUI/res/values-af/strings.xml
+++ b/packages/SystemUI/res/values-af/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Maak skoon"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Verwyder uit lys"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Program Info"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Jou onlangse skerms verskyn hier"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Maak onlangse programme toe"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 onlangse program"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Terug"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Tuis"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Kieslys"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Onlangse skerms"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Deursoek"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Foon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Ontsluit"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ontsluit"</string>
+    <string name="phone_label" msgid="2320074140205331708">"maak foon oop"</string>
+    <string name="camera_label" msgid="7261107956054836961">"maak kamera oop"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Knoppie vir wissel van invoermetode."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Versoenbaarheid-zoem se knoppie."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoem kleiner na groter skerm."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi twee stawe."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi drie stawe."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi-sein vol."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Gekoppel aan <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Gekoppel aan <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Geen WiMAX nie."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX een strepie."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX twee strepies."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter geaktiveer."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Luitoestel-vibreer."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Luitoestel stil."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Maak <xliff:g id="APP">%s</xliff:g> toe."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> verwerp."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Begin tans <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Kennisgewing is toegemaak."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Kennisgewingskerm."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Vinnige instellings."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Sluitskerm."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Instellings"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Onlangse skerms."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Gebruiker <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi afgeskakel."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi aangeskakel."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobiele <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Battery <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Vliegtuigmodus <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Ligging <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Vliegtuigmodus af."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Vliegtuigmodus aan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Vliegtuigmodus afgeskakel."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Vliegtuigmodus aangeskakel."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth af."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth aan."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth koppel tans."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth gekoppel."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth afgeskakel."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth aangeskakel."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Liggingverslaggewing af."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Liggingverslaggewing aan."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Liggingverslaggewing afgeskakel."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Liggingverslaggewing aangeskakel."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Wekker gestel vir <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Maak paneel toe"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Meer tyd"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Minder tyd"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Maak paneel toe."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Meer tyd."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Minder tyd."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Flitslig af."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Flitslig aan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Flitslig afgeskakel."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Flitslig aangeskakel."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Kleuromkering afgeskakel."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Kleuromkering aangeskakel."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobiele warmkol afgeskakel."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobiele warmkol aangeskakel."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Uitsaai van skerm gestaak."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Skermhelderheid"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G-data is af"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-data is af"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Sellulêre data is af"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Ligging deur GPS gestel"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Liggingversoeke aktief"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Verwyder alle kennisgewings."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Instellings"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Kennisgewingsinstellings"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>-instellings"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Die skerm sal outomaties draai."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skerm is in landskapsoriëntasie gesluit."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skerm is in portretoriëntasie gesluit."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skerm sal nou outomaties draai."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skerm is nou in landskapsoriëntering gesluit."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skerm is nou in portretoriëntering gesluit."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Nageregkas"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Sluimer"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Selfoondata"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Datagebruik"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Oorblywende data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Oor die limiet"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limiet bereik – datagebruik laat wag"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> gebruik"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g>-limiet"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> waarskuwing"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Jou onlangse skerms verskyn hier"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Programinligting"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"sluit na program"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"soek"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Soek"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Gly op vir <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Gly links vir <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Gee onderbrekings, insluitend wekkers, nie"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Geen onderbrekings nie. Nie eens wekkers nie."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Geen onderbrekings nie"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Net prioriteitonderbrekings"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Jou volgende wekker is om <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Jy sal nie jou wekker om <xliff:g id="ALARM_TIME">%s</xliff:g> hoor nie"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Minder dringende kennisgewings hieronder"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Raak weer om oop te maak"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Sleep op om te ontsluit"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Sleep regs vir foon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Sleep links vir kamera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Onbepaalde tyd"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Geen"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioriteit"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alles"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Laai tans (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> tot vol)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Wissel gebruiker"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Wissel gebruiker, huidige gebruiker <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Wys profiel"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Voeg gebruiker by"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nuwe gebruiker"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gas"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Voeg gas by"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Verwyder gas"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Verlaat gassessie?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"As die gassessie verlaat word, sal plaaslike data verwyder word."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Verwyder gas?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alle programme en data in hierdie sessie sal uitgevee word."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Verwyder"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Welkom terug, gas!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Een minuut lank"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d minute lank"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Een uur lank"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d uur lank"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Wiil jy jou sessie voortsit?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Begin van voor af"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, gaan voort"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Voeg nuwe gebruiker by?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Wanneer jy \'n nuwe gebruiker byvoeg, moet daardie persoon hul spasie opstel.\n\nEnige gebruiker kan programme vir al die ander gebruikers opdateer."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Batteryspaarder is aan"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Verminder werkverrigting en agtergronddata"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Skakel batterybespaarder af"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Begin nou"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Geen kennisgewings nie"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Toestel kan gemonitor word"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profiel kan gemonitor word"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Netwerk kan dalk gemonitor word"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Toestelmonitering"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profielmonitering"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Netwerkmonitering"</string>
-    <string name="open_app" msgid="4011771120339160755">"Maak program oop"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Deaktiveer VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Ontkoppel VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Hierdie toestel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur kan jou toestel en netwerkaktiwiteit monitor, insluitend e-posse, programme en veilige webwerwe.\n\nKontak jou administrateur vir meer inligting."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Jy het \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" toestemming gegee om \'n VPN-verbinding op te stel.\n\nHierdie program kan jou toestel en netwerkaktiwiteit monitor, insluitend e-posse, programme en veilige webwerwe."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Jy is aan \'n VPN gekoppel (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nJou VPN-diensverskaffer kan jou toestel en netwerkaktiwiteit monitor, insluitend e-posse, programme en veilige webwerwe."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Hierdie toestel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur kan jou netwerkaktiwiteit monitor, insluitend e-posse, programme en veilige webwerwe. Kontak jou administrateur vir meer inligting.\n\nJy het ook \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" toestemming gegee om \'n VPN-verbinding op te stel. Die program kan ook jou netwerkaktiwiteit monitor."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Hierdie toestel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur is in staat om jou netwerkaktiwiteit te monitor, insluitend e-posse, programme en veilige webwerwe. Kontak jou administrateur vir meer inligting.\n\nJy is ook aan \'n VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") gekoppel. Jou VPN-diensverskaffer kan ook jou netwerkaktiwiteit monitor."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Hierdie profiel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur kan jou toestel en netwerkaktiwiteit, insluitend e-posse, programme en veilige webwerwe, monitor.\n\nKontak jou administrateur vir meer inligting."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Hierdie toestel word bestuur deur:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJou profiel word bestuur deur:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJou administrateur kan jou toestel en netwerkaktiwiteit, insluitend e-posse, programme en veilige webwerwe, monitor.\n\nKontak jou administrateur vir meer inligting."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Hierdie profiel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur kan jou netwerkaktiwiteit, insluitend e-posse, programme en veilige webwerwe, monitor. Kontak jou administrateur vir meer inligting.\n\nOok het jy \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" toestemming gegee om \'n VPN-verbinding op te stel. Hierdie program kan ook netwerkaktiwiteit monitor."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Hierdie profiel word bestuur deur:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJou administrateur kan jou netwerkaktiwiteit, insluitend e-posse, programme en veilige webwerwe, monitor. Kontak jou administrateur vir meer inligting.\n\nJy is ook gekoppel aan \'n VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Jou VPN-diensverskaffer kan ook netwerkaktiwiteit monitor."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Dié toestel word bestuur deur:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJou profiel word bestuur deur:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJou administrateur kan netwerkaktiwiteit, soos e-pos, programme en veilige webwerwe, monitor. Kontak jou administrateur vir meer inligting.\n\nOok het jy \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" toegelaat om \'n VPN-verbinding te skep. Dié program kan ook netwerkaktiwiteit monitor."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Dié toestel word bestuur deur:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJou profiel word bestuur deur:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJou administrateur kan jou netwerkaktiwiteit, soos e-posse, programme en veilige webwerwe, monitor. Kontak jou administrateur vir meer inligting.\n\nJy is ook gekoppel aan \'n VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Jou VPN-diensverskaffer kan ook netwerkaktiwiteit monitor."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Toestel sal gesluit bly totdat jy dit handmatig ontsluit"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Kry kennisgewings vinniger"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Sien hulle voordat jy ontsluit"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nee dankie"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Stel op"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Gedemp deur <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-am/config.xml b/packages/SystemUI/res/values-am/config.xml
new file mode 100644
index 0000000..97e30c9
--- /dev/null
+++ b/packages/SystemUI/res/values-am/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s፣10s፣30s፣60s፣120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-am/strings.xml b/packages/SystemUI/res/values-am/strings.xml
index bbc6613..2683999 100644
--- a/packages/SystemUI/res/values-am/strings.xml
+++ b/packages/SystemUI/res/values-am/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"አጽዳ"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"ከዝርዝር አስወግድ"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"የትግበራ መረጃ"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"የቅርብ ጊዜ ማያ ገጾችዎ እዚህ ይታያሉ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"የቅርብ ጊዜ መተግበሪያዎችን ሰርዝ"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 የቅርብ ጊዜ መተግበሪያ"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"ተመለስ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"መነሻ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"ምናሌ"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"የቅርብ ጊዜ ማያ ገጾች"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ፈልግ"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ካሜራ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ስልክ"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ክፈት"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ክፈት"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ስልክ ክፈት"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ካሜራ ክፈት"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"የግቤት ስልት አዝራር ቀይር"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"የተኳኋኝአጉላ አዝራር።"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"አነስተኛውን ማያ ወደ ትልቅ አጉላ።"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"ሁለት የWiFi አሞሌዎች።"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"ሦስት የWiFi አሞሌዎች።"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"የWiFi ምልክት ሙሉ ነው።"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"ከ<xliff:g id="WIFI">%s</xliff:g> ጋር ተገናኝቷል።"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"ከ<xliff:g id="BLUETOOTH">%s</xliff:g> ጋር ተገናኝቷል።"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"ምንም WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX አንድ አሞሌ።"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX ሁለት አሞሌዎች።"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter ነቅቷል።"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"የስልክ ጥሪ ይንዘር።"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"የስልክ ጥሪ ፀጥታ።"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> አስወግድ።"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ተሰናብቷል::"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> በመጀመር ላይ።"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"ማሳወቂያ ተወግዷል።"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"የማሳወቂያ ጥላ።"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ፈጣን ቅንብሮች።"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ማያ ገጽ ቆልፍ።"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ቅንብሮች"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"የቅርብ ጊዜ ማያ ገጾች።"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ተጠቃሚ <xliff:g id="USER">%s</xliff:g>።"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>። <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>።"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi በርቷል።"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"ተንቀሳቃሽ ስልክ <xliff:g id="SIGNAL">%1$s</xliff:g>። <xliff:g id="TYPE">%2$s</xliff:g>። <xliff:g id="NETWORK">%3$s</xliff:g>።"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ባትሪ <xliff:g id="STATE">%s</xliff:g>።"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"የአውሮፕላን ሁነታ <xliff:g id="STATE">%s</xliff:g>።"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ብሉቱዝ <xliff:g id="STATE">%s</xliff:g>።"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"አካባቢ <xliff:g id="STATE">%s</xliff:g>።"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"የአውሮፕላን ሁነታ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"የአውሮፕላን ሁነታ በርቷል።"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"የአውሮፕላን ሁነታ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"የአውሮፕላን ሁነታ በርቷል።"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"ብሉቱዝ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"ብሉቱዝ በርቷል።"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ብሉቱዝ በመገናኘት ላይ።"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"ብሉቱዝ ተገናኝቷል።"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ብሉቱዝ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ብሉቱዝ በርቷል።"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"አካባቢን ሪፖርት ማድረግ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"አካባቢን ሪፖርት ማድረግ በርቷል።"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"አካባቢን ሪፖርት ማድረግ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"አካባቢን ሪፖርት ማድረግ በርቷል።"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"ማንቂያ ለ<xliff:g id="TIME">%s</xliff:g> ተዋቅሯል።"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"ፓነል ዝጋ"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"ተጨማሪ ጊዜ"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"ያነሰ ጊዜ"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ፓነል ዝጋ።"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"ተጨማሪ ጊዜ።"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"ያነሰ ጊዜ።"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"የባትሪ ብርሃን ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"የባትሪ ብርሃን በርቷል።"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"የባትሪ ብርሃን ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"የባትሪ ብርሃን በርቷል።"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"የቀለም ግልበጣ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"የቀለም ግልበጣ በርቷል።"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"የተንቀሳቃሽ ስልክ መገናኛ ነጥብ ጠፍቷል።"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"የተንቀሳቃሽ ስልክ መገናኛ ነጥብ በርቷል።"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"ማያ ገጽ መውሰድ ቆሟል።"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ብሩህነት ያሳዩ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2ጂ-3ጂ ውሂብ ጠፍቷል"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4ጂ ውሂብ ጠፍቷል"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"የተንቀሳቃሽ ስልክ ውሂብ ጠፍቷል"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"በ GPS የተዘጋጀ ሥፍራ"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"የአካባቢ ጥያቄዎች ነቅተዋል"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"ሁሉንም ማሳወቂያዎች አጽዳ"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ቅንብሮች"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"የማሳወቂያ ቅንብሮች"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"የ<xliff:g id="APP_NAME">%s</xliff:g> ቅንብሮች"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"ማያ ገጽ በራስ ሰር ይዞራል።"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ማያ ገጽ በወርድ ገፅ አቀማመጥ ተቆልፏል።"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ማያ ገጽ በቁም ገፅ አቀማመጥ ተቆልፏል።"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ማያ ገጽ አሁን በራስ-ሰር ይሽከረከራል።"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ማያ ገጽ አሁን በወርድ አቀማመጠ-ገፅ ተቆልፏል።"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ማያ ገጽ አሁን በቁም አቀማመጠ-ገፅ ተቆልፏል።"</string>
     <string name="dessert_case" msgid="1295161776223959221">"የማወራረጃ ምግቦች መያዣ"</string>
     <string name="start_dreams" msgid="7219575858348719790">"የቀን ህልም"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ኤተርኔት"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"የተንቀሳቃሽ ስልክ ውሂብ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"የውሂብ አጠቃቀም"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ቀሪ ውሂብ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"ከገደብ በላይ"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ገደብ ላይ ተደርሷል – የውሂብ አጠቃቀም ለአፍታ ቆሟል"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ጥቅም ላይ ውሏል"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ገደብ"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"የ<xliff:g id="DATA_LIMIT">%s</xliff:g> ማስጠንቀቂያ"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"የቅርብ ጊዜ ማያ ገጾችዎ እዚህ ይታያሉ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"የመተግበሪያ መረጃ"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"መተግበሪያ-ጋር-ቆልፍ"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ፈልግ"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"ፍለጋ"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"ለ<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ወደ ላይ አንሸራትት።"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"ለ<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ወደ ግራ አንሸራትት።"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ምንም ማቋረጦች የሉም፣ ማንቂያዎችን ጨምሮ"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ምንም ማቋረጦች የሉም። ማንቂያዎችም እንኳ።"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"ምንም ማቋረጦች የሉም"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"ቅድሚያ የሚሰጣቸው ማቋረጦች ብቻ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ቀጣዩ ማንቂያ ደውልዎ በ<xliff:g id="ALARM_TIME">%s</xliff:g> ነው"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"በ<xliff:g id="ALARM_TIME">%s</xliff:g> ያለውን ማንቂያ ደውልዎን አይሰሙትም"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"በጣም አስቸካይ ያልሆኑ ማሳወቂያዎች ከታች"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"ለመክፈት ዳግም ይንኩ"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"ለማስከፈት ወደ ላይ ያንሸራትቱ"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ለስልክ ወደቀኝ ያንሸራትቱ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ለካሜራ ወደግራ ያንሸራትቱ"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"ያለገደብ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ምንም"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ቅድሚያ"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ሁሉም"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ሃይል በመሙላት ላይ (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> እስከሚሞላ ድረስ)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ተጠቃሚ ቀይር"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ተጠቃሚ ይለውጡ፣ የአሁን ተጠቃሚ <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"መገለጫ አሳይ"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ተጠቃሚ አክል"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"አዲስ ተጠቃሚ"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"እንግዳ"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"እንግዳ አክል"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"እንግዳ አስወግድ"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ከእንግዳ ክፍለ ጊዜው እየወጡ ነው?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"ከእንግዳ ክፍለ-ጊዜ መውጣት አካባቢያዊ ውሂብ ያስወግዳል።"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"እንግዳ ይወገድ?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"በዚህ ክፍለ-ጊዜ ውስጥ ያሉ ሁሉም መተግበሪያዎች እና ውሂብ ይሰረዛሉ።"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"አስወግድ"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"እንኳን በደህና ተመለሱ እንግዳ!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ለአንድ ደቂቃ"</item>
-    <item quantity="other" msgid="6924190729213550991">"ለ%d ደቂቃዎች"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ለአንድ ሰዓት"</item>
-    <item quantity="other" msgid="5408537517529822157">"ለ%d ሰዓቶች"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"ክፍለ-ጊዜዎን መቀጠል ይፈልጋሉ?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"እንደገና ጀምር"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"አዎ፣ ቀጥል"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"አዲስ ተጠቃሚ ይታከል?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"እርስዎ አንድ አዲስ ተጠቃሚ ሲያክሉ ያ ሰው የራሱ ቦታ ማዘጋጀት አለበት።\n\nማንኛውም ተጠቃሚ መተግበሪያዎችን ለሌሎች ተጠቃሚዎች ሁሉ ሊያዘምን ይችላል።"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"የባትሪ ኃይል ቆጣቢ በርቷል"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"አፈጻጸምን እና የጀርባ ውሂብ ይቀንሳል"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ባትሪ ቆጣቢን አጥፋ"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"አሁን ጀምር"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"ምንም ማሳወቂያ የለም"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"መሣሪያው ክትትል የሚደረግበት ሊሆን ይችላል"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"መገለጫ ክትትል ሊደረግበት ይችላል"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"አውታረ መረብ በክትትል እየተደረገበት ሊሆን ይችላል"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"የመሣሪያ ክትትል"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"መገለጫን መከታተል"</string>
     <string name="monitoring_title" msgid="169206259253048106">"የአውታረ መረብ ክትትል"</string>
-    <string name="open_app" msgid="4011771120339160755">"መተግበሪያን ክፈት"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN አሰናክል"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"የVPN ግንኙነት አቋርጥ"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን መከታተል ይችላል።\n\nተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"«<xliff:g id="APPLICATION">%1$s</xliff:g>» አንድ የVPN ግንኙነት እንዲያዋቅር ፍቃድ ሰጥተዋቸዋል።\n\nይህ መተግበሪያ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን መከታተል ይችላል።"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"ከአንድ VPN («<xliff:g id="APPLICATION">%1$s</xliff:g>») ጋር ተገናኝተዋል።\n\nየእርስዎ VPN አገልግሎት አቅራቢ መሣሪያዎን እና ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን መከታተል ይችላል።"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን መከታተል ይችላል። ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም፣ «<xliff:g id="APPLICATION">%2$s</xliff:g>» አንድ የVPN ግንኙነት እንዲያዋቅር ፍቃድ ሰጥተዋቸዋል። ይህ መተግበሪያም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን መከታተል ይችላል። ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም ከአንድ VPN («<xliff:g id="APPLICATION">%2$s</xliff:g>») ጋር ተገናኝተዋል። የእርስዎ የVPN አገልግሎት አቅራቢዎም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የእርስዎን መሣሪያ እና የአውታረ መረብ እንቅስቃሴ የመከታተል ችሎታ አላቸው።\n\nተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nየእርስዎ መገለጫ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የእርስዎን መሣሪያ እና የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።\n\nተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ይህ መገለጫ የሚቀናበረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን የመከታተል ችሎታ አላቸው። ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም «<xliff:g id="APPLICATION">%2$s</xliff:g>» የቪፒኤን ግንኙነት የማዋቀር ፍቃድ ሰጥተውታል። ይህ መተግበሪያ እንዲሁም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የእርስዎን መሣሪያ እና የአውታረ መረብ እንቅስቃሴ የመከታተል ችሎታ አላቸው።ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም ከአንድ ቪፒኤን («<xliff:g id="APPLICATION">%2$s</xliff:g>») ጋር ተገናኝተዋል። የእርስዎ የቪፒኤን አገልግሎት አቅራቢም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ይህ መሣሪያ የሚቀናበረው በ፦\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nየእርስዎ መገለጫ የሚቀናበረው በ፦\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የአውታረ መረብ እንቅስቃሴዎን የመከታተል ችሎታ አላቸው። ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም «<xliff:g id="APPLICATION">%3$s</xliff:g>» የቪፒኤን ግንኙነት የማዋቀር ፍቃድ ሰጥተውታል። ይህ መተግበሪያ እንዲሁም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ይህ መሣሪያ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nየእርስዎ መገለጫ የሚተዳደረው በ፦\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nየእርስዎ አስተዳዳሪ ኢሜይሎችን፣ መተግበሪያዎችን እና ደህንነታቸው የተጠበቁ ድር ጣቢያዎችን ጨምሮ የእርስዎን መሣሪያ እና የአውታረ መረብ እንቅስቃሴ የመከታተል ችሎታ ይኖራቸዋል።ተጨማሪ መረጃ ለማግኘት አስተዳዳሪዎን ያነጋግሩ።\n\nእንዲሁም ከአንድ ቪፒኤን («<xliff:g id="APPLICATION">%3$s</xliff:g>») ጋር ተገናኝተዋል። የእርስዎ የቪፒኤን አገልግሎት አቅራቢም የአውታረ መረብ እንቅስቃሴ መከታተል ይችላል።"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"እራስዎ እስኪከፍቱት ድረስ መሣሪያ እንደተቆለፈ ይቆያል"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"ማሳወቂያዎችን ፈጥነው ያግኙ"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ከመክፈትዎ በፊት ይመልከቷቸው"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"አይ፣ አመሰግናለሁ"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"አዋቅር"</string>
+    <string name="muted_by" msgid="6147073845094180001">"ድምጽ በ<xliff:g id="THIRD_PARTY">%1$s</xliff:g> ተዘግቷል"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ar/config.xml b/packages/SystemUI/res/values-ar/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-ar/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-ar/strings.xml b/packages/SystemUI/res/values-ar/strings.xml
index 468867c..ba44c63 100644
--- a/packages/SystemUI/res/values-ar/strings.xml
+++ b/packages/SystemUI/res/values-ar/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"محو"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"إزالة من القائمة"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"معلومات التطبيق"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"تظهر شاشاتك المعروضة مؤخرًا هنا"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"إزالة التطبيقات الحديثة"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"تطبيق حديث واحد"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"رجوع"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"الرئيسية"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"القائمة"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"الشاشات المعروضة مؤخرًا"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"بحث"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"الكاميرا"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"الهاتف"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"إلغاء القفل"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"إلغاء القفل"</string>
+    <string name="phone_label" msgid="2320074140205331708">"فتح الهاتف"</string>
+    <string name="camera_label" msgid="7261107956054836961">"فتح الكاميرا"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"زر تبديل طريقة الإدخال."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"زر تكبير/تصغير للتوافق."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"استخدام التكبير/التصغير لتحويل شاشة صغيرة إلى شاشة أكبر"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"‏إشارة Wi-Fi تتكون من شريطين."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"‏إشارة Wi-Fi تتكون من ثلاثة أشرطة."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"‏إشارة Wi-Fi كاملة."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"متصل بـ <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"متصل بـ <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"‏ليس هناك WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"‏شريط WiMAX واحد."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"‏شريطا WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"تم تمكين المبرقة الكاتبة."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"رنين مع الاهتزاز."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"رنين صامت."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"إزالة <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"تمت إزالة <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"جارٍ بدء <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"تم تجاهل الإشعار."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"مركز الإشعارات."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"الإعدادات السريعة."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"شاشة التأمين."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"الإعدادات"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"الشاشات المعروضة مؤخرًا."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"المستخدم <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"‏تم إيقاف Wifi."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"‏تم تشغيل Wifi."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"الجوال <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"البطارية <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"وضع الطائرة <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"البلوتوث <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"حالة الموقع: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"إيقاف وضع الطائرة."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"تشغيل وضع الطائرة."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"تم إيقاف وضع الطائرة."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"تم تشغيل وضع الطائرة."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"إيقاف البلوتوث."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"تشغيل البلوتوث."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"جارٍ توصيل البلوتوث."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"تم توصيل البلوتوث."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"تم إيقاف البلوتوث."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"تم تشغيل البلوتوث."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"إيقاف الإبلاغ عن الموقع."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"تشغيل الإبلاغ عن الموقع."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"تم إيقاف الإبلاغ عن الموقع."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"تم تشغيل الإبلاغ عن الموقع."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"تم ضبط المنبه على <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"إغلاق اللوحة"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"وقت أكثر"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"وقت أقل"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"إغلاق اللوحة."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"وقت أكثر."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"وقت أقل."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"إيقاف الفلاش."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"تشغيل الفلاش."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"تم إيقاف الفلاش."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"تم تشغيل الفلاش."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"تم إيقاف انعكاس اللون."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"تم تشغيل انعكاس اللون."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"تم إيقاف نقطة اتصال الجوّال."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"تم تشغيل نقطة اتصال الجوّال."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"توقف إرسال الشاشة."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"سطوع الشاشة"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2-3 غيغابايت من البيانات المعطلة"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4 غيغابايت من البيانات المعطلة"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"البيانات الخلوية معطلة"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"‏تم تعيين الموقع بواسطة GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"طلبات الموقع نشطة"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"محو جميع الإشعارات."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"الإعدادات"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"إعدادات الإشعارات"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"إعدادات <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"سيتم تدوير الشاشة تلقائيًا."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"تم تأمين الشاشة في الاتجاه الأفقي."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"تم تأمين الشاشة في الاتجاه العمودي."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"سيتم الآن تدوير الشاشة تلقائيًا."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"تم قفل الشاشة الآن في الاتجاه الأفقي."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"تم قفل الشاشة الآن في الاتجاه الرأسي."</string>
     <string name="dessert_case" msgid="1295161776223959221">"حالة الحلويات"</string>
     <string name="start_dreams" msgid="7219575858348719790">"حلم اليقظة"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"البيانات الخلوية"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"استخدام البيانات"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"البيانات المتبقية"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"فوق القيد"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"تم بلوغ الحد – تم إيقاف استخدام البيانات مؤقتًا"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> مستخدم"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"قيد <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"تحذير <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"تظهر شاشاتك المعروضة مؤخرًا هنا"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"معلومات التطبيق"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"تقييد بالتطبيق"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"بحث"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"بحث"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"تمرير لأعلى لـ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"تمرير لليسار لـ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"بدون إزعاج، بما في ذلك المنبهات"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"عدم المقاطعة، ولا بالتنبيهات كذلك."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"بدون مقاطعات"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"المقاطعات ذات الأولوية فقط"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"التنبيه المقبل في <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"لن تسمع المنبهات في <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"الإشعارات الأقل إلحاحًا أدناه"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"المس مرة أخرى للفتح"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"مرر سريعًا لأعلى لإلغاء القفل"</string>
     <string name="phone_hint" msgid="3101468054914424646">"مرر سريعًا إلى اليسار لفتح الهاتف"</string>
     <string name="camera_hint" msgid="5241441720959174226">"مرر سريعًا إلى اليمين لفتح الكاميرا"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"إلى أجل غير مسمى"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"بدون"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"الأولوية"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"الكل"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"جارٍ الشحن (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> حتى الامتلاء)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"تبديل المستخدم"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"تبديل المستخدم، المستخدم الحالي <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"عرض الملف الشخصي"</string>
     <string name="user_add_user" msgid="5110251524486079492">"إضافة مستخدم"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"مستخدم جديد"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"المدعو"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"إضافة مدعو"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"إزالة جلسة الضيف"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"هل تريد الخروج من جلسة الضيف؟"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"سيؤدي الخروج من جلسة الضيف إلى إزالة البيانات المحلية."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"هل تريد إزالة جلسة الضيف؟"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"سيتم حذف كل التطبيقات والبيانات في هذه الجلسة."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"إزالة"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"مرحبًا بك مجددًا في جلسة الضيف"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"لمدة دقيقة واحدة"</item>
-    <item quantity="other" msgid="6924190729213550991">"‏لمدة %d من الدقائق"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"لمدة ساعة واحدة"</item>
-    <item quantity="other" msgid="5408537517529822157">"‏لمدة %d من الساعات"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"هل تريد متابعة جلستك؟"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"البدء من جديد"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"نعم، متابعة."</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"هل تريد إضافة مستخدم جديد؟"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"عند إضافة مستخدم جديد، يلزمه إعداد مساحته.\n\nعلمًا بأنه يُمكن لأي مستخدم تحديث التطبيقات لجميع المستخدمين الآخرين."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"وضع توفير الطاقة قيد التشغيل"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"لخفض مستوى الأداء وبيانات الخلفية"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"إيقاف توفير شحن البطارية"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"البدء الآن"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"ليس هناك أي اشعارات"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ربما تتم مراقبة الجهاز"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ربما تتم مراقبة الملف الشخصي"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"قد تكون الشبكة خاضعة للمراقبة"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"مراقبة الأجهزة"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"مراقبة الملف الشخصي"</string>
     <string name="monitoring_title" msgid="169206259253048106">"مراقبة الشبكات"</string>
-    <string name="open_app" msgid="4011771120339160755">"فتح التطبيق"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"تعطيل الشبكة الظاهرية الخاصة"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"‏قطع الاتصال بشبكة VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"تتم إدارة هذا الجهاز عن طريق:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيمكن للمشرف مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة.\n\nللحصول على المزيد من المعلومات، اتصل بالمشرف."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"لقد منحت \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" إذنًا لإعداد اتصال عبر شبكة ظاهرية خاصة.\n\nيمكن لهذا التطبيق مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"أنت متصل بشبكة ظاهرية خاصة (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nيمكن لموفر خدمة الشبكة الظاهرية الخاصة مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"هذا الجهاز تتم إدارته بواسطة:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيمكن للمشرف مراقبة نشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات اتصل بالمشرف.\n\nوكذلك، فإنك منحت \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" إذنًا لإعداد الاتصال بالشبكة الظاهرية الخاصة. ويمكن لهذا التطبيق مراقبة نشاط الشبكة أيضًا."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"هذا الجهاز تتم إدارته بواسطة:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيمكن للمشرف مراقبة نشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات اتصل بالمشرف.\n\nوكذلك، فإنك متصل بالشبكة الظاهرية الخاصة (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). ويمكن لمزوّد خدمة الشبكة الظاهرية الخاصة مراقبة نشاط الشبكة أيضًا."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"تتم إدارة هذا الملف الشخصي بواسطة:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة.\n\nللحصول على مزيد من المعلومات، اتصل بالمشرف."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"تتم إدارة هذا الجهاز بواسطة:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nتتم إدارة ملفك الشخصي بواسطة:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة.\n\nللحصول على مزيد من المعلومات، اتصل بالمشرف."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"تتم إدارة هذا الملف الشخصي بواسطة:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات، اتصل بالمشرف.\n\nوكذلك، فإنك منحت \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" إذنًا لإعداد اتصال بشبكة ظاهرية خاصة. يتمكن هذا التطبيق من مراقبة نشاط الشبكة كذلك."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"تتم إدارة هذا الجهاز بواسطة:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات، اتصل بالمشرف.\n\nوكذلك، فإنك متصل بشبكة ظاهرية خاصة (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). يتمكن موفر خدمة الشبكة الظاهرية الخاصة من مراقبة نشاط الشبكة كذلك."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"تتم إدارة هذا الجهاز بواسطة:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nتتم إدارة ملفك الشخصي بواسطة:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات، اتصل بالمشرف.\n\nوكذلك، فإنك منحت \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" إذنًا لإعداد اتصال بشبكة ظاهرية خاصة. يتمكن هذا التطبيق من مراقبة نشاط الشبكة كذلك."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"‏تتم إدارة هذا الجهاز بواسطة:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nتتم إدارة ملفك الشخصي بواسطة:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nيتمكن المشرف من مراقبة جهازك ونشاط الشبكة، بما في ذلك الرسائل الإلكترونية والتطبيقات ومواقع الويب الآمنة. للحصول على مزيد من المعلومات، اتصل بالمشرف.\n\nوكذلك، فإنك متصل بشبكة ظاهرية خاصة VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). يتمكن موفر خدمة الشبكة الظاهرية الخاصة من مراقبة نشاط الشبكة كذلك."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"سيظل الجهاز مقفلاً إلى أن يتم إلغاء قفله يدويًا"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"الحصول على الإشعارات بشكل أسرع"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"الاطلاع عليها قبل إلغاء القفل"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"لا، شكرًا"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"إعداد"</string>
+    <string name="muted_by" msgid="6147073845094180001">"تم كتم الصوت بواسطة <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-bg/config.xml b/packages/SystemUI/res/values-bg/config.xml
new file mode 100644
index 0000000..3a6872f
--- /dev/null
+++ b/packages/SystemUI/res/values-bg/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 с, 10 с, 30 с, 60 с, 120 с"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-bg/strings.xml b/packages/SystemUI/res/values-bg/strings.xml
index 4022c80..af76911 100644
--- a/packages/SystemUI/res/values-bg/strings.xml
+++ b/packages/SystemUI/res/values-bg/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Изчистване"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Премахване от списъка"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Информация за приложението"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Скорошните ви екрани се показват тук"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Отхвърляне на скорошните приложения"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 скорошно приложение"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Назад"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Начало"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Скорошни екрани"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Търсене"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Отключване"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"отключване"</string>
+    <string name="phone_label" msgid="2320074140205331708">"отваряне на телефона"</string>
+    <string name="camera_label" msgid="7261107956054836961">"отваряне на камерата"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Бутон за превключване на метода на въвеждане."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Бутон за промяна на мащаба с цел съвместимост."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Промяна на мащаба на екрана от по-малък до по-голям."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi е с две чертички."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi е с три чертички."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Сигналът за Wi-Fi е пълен."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Има връзка с <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Има връзка с <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Няма WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX е с една чертичка."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX е с две чертички."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter бе активиран."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Вибрира при звънене."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Звънът е заглушен."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Отхвърляне на <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Приложението <xliff:g id="APP">%s</xliff:g> е отхвърлено."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> се стартира."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Известието е отхвърлено."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Падащ панел с известия."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Бързи настройки."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Заключване на екрана."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Настройки"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Скорошни екрани."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Потребител: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Функцията за Wi-Fi се изключи."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Функцията за Wi-Fi се включи."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобилно устройство: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батерия: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Самолетен режим: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Местоположението е <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Самолетният режим е изключен."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Самолетният режим е включен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Самолетният режим се изключи."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Самолетният режим се включи."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Функцията за Bluetooth е изключена."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Функцията за Bluetooth е включена."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Установява се връзка през Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Установена е връзка през Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Функцията за Bluetooth се изключи."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Функцията за Bluetooth се включи."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Функцията „Отчитане на местоположението“ е изключена."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Функцията „Отчитане на местоположението“ е включена."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Функцията „Отчитане на местоположението“ се изключи."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Функцията „Отчитане на местоположението“ се включи."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Будилникът е навит за <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Затваряне на панела"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Повече време"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"По-малко време"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Затваряне на панела."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Повече време."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"По-малко време."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Светкавицата е изключена."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Светкавицата е включена."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Светкавицата се изключи."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Светкавицата се включи."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Функцията за инвертиране на цветовете се изключи."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Функцията за инвертиране на цветовете се включи."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобилната точка за достъп се изключи."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобилната точка за достъп се включи."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Предаването на съдържанието от екрана спря."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Яркост на екрана"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Данните от 2G – 3G са изключени"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Данните от 4G са изключени"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Мобилните данни са изключени"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Местоположението е зададено от GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Активни заявки за местоположение"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Изчистване на всички известия."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Настройки"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Настройки за известия"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Настройки за <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Екранът ще се завърта автоматично."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Екранът е заключен в хоризонтална ориентация."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Екранът е заключен във вертикална ориентация."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Екранът ще се завърта автоматично."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Екранът е заключен в хоризонтална ориентация."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Екранът е заключен във вертикална ориентация."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Витрина с десерти"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Мечта"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Мобилни данни"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Пренос на данни"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Оставащи данни"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Над ограничението"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Достигнат лимит – преносът на данни е поставен на пауза"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Използвано: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Ограничение от <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Предупреждение: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Скорошните ви екрани се показват тук"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Информация за приложението"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"заключване в приложението"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"търсене"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Търсене"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Плъзнете нагоре за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Плъзнете наляво за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Без прекъсвания, включително будилници"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Без прекъсвания. Дори без будилници."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Без прекъсвания"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Само приоритетни прекъсвания"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Следващият ви будилник е в <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Няма да чуете будилника си в <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Ппоказване на по-малко спешните известия по-долу"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Докоснете отново за отваряне"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Прекарайте пръст нагоре, за да отключите"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Прекарайте пръст надясно, за да използвате телефона"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Прекарайте пръст наляво, за да включите камерата"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"За неопределено време"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Няма"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Приоритет"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Всички"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Зарежда се (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> до пълно зареждане)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Превключване между потребителите"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Превключване на потребителя – текущият е <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Показване на потребителския профил"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Добавяне на потребител"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Нов потребител"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Гост"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Добавяне на гост"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Премахване на госта"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Да се излезе ли от сесията като гост?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Излизането от сесията като гост ще премахне локалните данни."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Да се премахне ли гостът?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Всички приложения и данни в тази сесия ще бъдат изтрити."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Премахване"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Добре дошли отново в сесията като гост!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"За една минута"</item>
-    <item quantity="other" msgid="6924190729213550991">"За %d минути"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"За един час"</item>
-    <item quantity="other" msgid="5408537517529822157">"За %d часа"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Искате ли да продължите сесията си?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Започване отначало"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Да, продължавам"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Да се добави ли нов потреб.?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Когато добавите нов потребител, той трябва да настрои работното си пространство.\n\nВсеки потребител може да актуализира приложенията за всички останали потребители."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Режимът за запазване на батерията е включен"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Намалява ефективността и данните на заден план"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Изключване на режима за запазване на батерията"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Стартиране сега"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Няма известия"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Устройството може да се наблюдава"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Възможно е потребителският профил да се наблюдава"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Мрежата може да се наблюдава"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Наблюдение на устройството"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Наблюдаване на потр. профил"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Наблюдение на мрежата"</string>
-    <string name="open_app" msgid="4011771120339160755">"Отваряне на приложението"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Деактивиране на VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Прекратяване на връзката с VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Това устройство се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да го наблюдава, както и активността ви в мрежата, включително имейлите, приложенията и защитените уебсайтове.\n\nЗа повече информация се свържете с него."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Дадохте на „<xliff:g id="APPLICATION">%1$s</xliff:g>“ разрешение да настрои връзка с виртуална частна мрежа (VPN).\n\nТова приложение може да наблюдава устройството ви и активността ви в мрежата, включително имейлите, приложенията и защитените уебсайтове."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Свързани сте с виртуална частна мрежа („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nДоставчикът ви на услуги за VPN може да наблюдава устройството ви и активността ви в мрежата, включително имейлите, приложенията и защитените уебсайтове."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"У-вото се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да наблюдава активн. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За повече информация се свържете с него.\n\nСъщо така дадохте на „<xliff:g id="APPLICATION">%2$s</xliff:g>“ разрешение да настрои връзка с вирт. частна мрежа (VPN). Прилож. може да наблюдава и активн. в мрежата."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"У-вото се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да наблюдава активн. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За повече информация се свържете с него.\n\nСъщо така сте свързани с вирт. частна мрежа (VPN) („<xliff:g id="APPLICATION">%2$s</xliff:g>“). Доставчикът ви на услуги за VPN може да наблюдава и активн. ви в мрежата."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Този потребителски профил се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да наблюдава устройството ви и активността ви в мрежата, включително имейлите, приложенията и защитените уебсайтове.\n\nЗа още информация се свържете с него."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Това устройство се управлява от:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПотребителският ви профил се управлява от:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистраторът ви може да наблюдава устройството ви и активността ви в мрежата, включително имейлите, приложенията и защитените уебсайтове.\n\nЗа още информация се свържете с него."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Този потр. профил се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да наблюдава акт. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За още информация се свържете с него.\n\nСъщо така дадохте на <xliff:g id="APPLICATION">%2$s</xliff:g> разрешение да настрои връзка с вирт. частна мрежа (VPN). Прилож. може да наблюдава и акт. в мрежата."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Този потр. профил се управлява от:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторът ви може да наблюдава акт. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За още информация се свържете с него.\n\nСъщо така сте свързани с вирт. частна мрежа (VPN) (<xliff:g id="APPLICATION">%2$s</xliff:g>). Доставчикът ви на услуги за VPN може да наблюдава и акт. ви в мрежата."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Това у-во се управлява от:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПотр. ви профил се управлява от:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистр. ви може да наблюдава акт. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За още информация се свържете с него.\n\nСъщо така дадохте на <xliff:g id="APPLICATION">%3$s</xliff:g> разрешение да настрои връзка с VPN. Приложението може да наблюдава и акт. в мрежата."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"У-вото се управлява от:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПотр. ви профил се управлява от:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистраторът ви може да наблюдава акт. ви в мрежата, вкл. имейлите, прилож. и защитените уебсайтове. За още информация се свържете с него.\n\nСъщо така сте свързани с VPN (<xliff:g id="APPLICATION">%3$s</xliff:g>). Доставчикът ви на услуги за VPN може да наблюдава и акт. ви в мрежата."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Устройството ще остане заключено, докато не го отключите ръчно"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Получавайте известия по-бързо"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Вижте известията, преди да отключите"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Няма нужда"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Настройване"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Заглушено от <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-bn-rBD/config.xml b/packages/SystemUI/res/values-bn-rBD/config.xml
new file mode 100644
index 0000000..be49df5
--- /dev/null
+++ b/packages/SystemUI/res/values-bn-rBD/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"১সে.,১০সে.,৩০সে.,৬০সে.,১২০সে."</string>
+</resources>
diff --git a/packages/SystemUI/res/values-bn-rBD/strings.xml b/packages/SystemUI/res/values-bn-rBD/strings.xml
index 12970bb..044bbda 100644
--- a/packages/SystemUI/res/values-bn-rBD/strings.xml
+++ b/packages/SystemUI/res/values-bn-rBD/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"সাফ করুন"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"তালিকা থেকে সরান"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"অ্যাপ্লিকেশানের তথ্য"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"আপনার সাম্প্রতিক স্ক্রীনগুলো এখানে দেখা যাবে"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"সাম্প্রতিক অ্যাপ্লিকেশানগুলি খারিজ করুন"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"১টি সাম্প্রতিক অ্যাপ্লিকেশান"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"ফিরুন"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"হোম"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"মেনু"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"সাম্প্রতিক স্ক্রীনগুলি"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"অনুসন্ধান করুন"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ক্যামেরা"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ফোন"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"আনলক করুন"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"আনলক করুন"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ফোন খুলুন"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ক্যামেরা খুলুন"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ইনপুট পদ্ধতির বোতাম পরিবর্তন করুন৷"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"সামঞ্জস্যের জুম বোতাম৷"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ছোট থেকে বৃহৎ স্ক্রীণে জুম করুন৷"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi এ দুইটি দণ্ড৷"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi এ তিনটি দণ্ড৷"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi এ সম্পূর্ণ সিগন্যাল৷"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> এর সাথে সংযুক্ত।"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>এ সংযুক্ত হয়ে আছে।"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX অনুপলব্ধ৷"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX এ একটি দণ্ড৷"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX এ দুইটি দণ্ড৷"</string>
@@ -139,7 +143,7 @@
     <string name="accessibility_data_connection_roaming" msgid="5977362333466556094">"রোমিং"</string>
     <string name="accessibility_data_connection_edge" msgid="4477457051631979278">"Edge"</string>
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"Wi-Fi"</string>
-    <string name="accessibility_no_sim" msgid="8274017118472455155">"কোনো SIM নেই৷"</string>
+    <string name="accessibility_no_sim" msgid="8274017118472455155">"কোনো সিম নেই৷"</string>
     <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Bluetooth টিথারিং৷"</string>
     <string name="accessibility_airplane_mode" msgid="834748999790763092">"বিমান মোড৷"</string>
     <string name="accessibility_battery_level" msgid="7451474187113371965">"<xliff:g id="NUMBER">%d</xliff:g> শতাংশ ব্যাটারি রয়েছে৷"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"টেলি টাইপরাইটার সক্ষম করা আছে৷"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"রিং বাজার সাথে স্পন্দিত করুন৷"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"রিং বাজানো বন্ধ করুন৷"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> খারিজ করুন।"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> খারিজ করা হয়েছে৷"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> তারাঙ্কিত করা হচ্ছে।"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"বিজ্ঞপ্তি খারিজ করা হয়েছে৷"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"বিজ্ঞপ্তি শেড৷"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"দ্রুত সেটিংস৷"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"লক স্ক্রীন।"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"সেটিংস"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"সাম্প্রতিক স্ক্রীনগুলি।"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ব্যবহারকারী <xliff:g id="USER">%s</xliff:g>৷"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>৷ <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>।"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WiFi বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WiFi চালু হয়েছে।"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"মোবাইল <xliff:g id="SIGNAL">%1$s</xliff:g>৷ <xliff:g id="TYPE">%2$s</xliff:g>৷ <xliff:g id="NETWORK">%3$s</xliff:g>৷"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ব্যাটারি <xliff:g id="STATE">%s</xliff:g>৷"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"বিমান মোড <xliff:g id="STATE">%s</xliff:g>৷"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>৷"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"অবস্থান <xliff:g id="STATE">%s</xliff:g>৷"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"বিমান মোড বন্ধ আছে।"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"বিমান মোড চালু আছে।"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"বিমান মোড বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"বিমান মোড চালু হয়েছে।"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth বন্ধ আছে।"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth চালু আছে।"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth সংযুক্ত হচ্ছে।"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth সংযুক্ত হয়েছে৷"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth চালু হয়েছে।"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"অবস্থানের প্রতিবেদন বন্ধ আছে।"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"অবস্থানের প্রতিবেদন চালু আছে।"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"অবস্থানের প্রতিবেদন বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"অবস্থানের প্রতিবেদন চালু হয়েছে।"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> এ অ্যালার্ম সেট করা হয়েছে৷"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"প্যানেল বন্ধ করুন"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"বেশি সময়"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"কম সময়"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"প্যানেল বন্ধ করুন।"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"বেশি সময়।"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"কম সময়।"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ফ্ল্যাশলাইট বন্ধ আছে।"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ফ্ল্যাশলাইট চালু আছে।"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ফ্ল্যাশলাইট বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ফ্ল্যাশলাইট চালু হয়েছে।"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"রঙ বিলোমক্রিয়া বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"রঙ বিলোমক্রিয়া চালু হয়েছে।"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"মোবাইল হটস্পট বন্ধ হয়েছে।"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"মোবাইল হটস্পট চালু হয়েছে।"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"স্ক্রীন কাস্ট করা থেমেছে।"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"প্রদর্শনের উজ্জ্বলতা"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G ডেটা বন্ধ"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G ডেটা বন্ধ"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"সেলুলার ডেটা বন্ধ"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS এর দ্বারা সেট করা অবস্থান"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"অবস্থান অনুরোধ সক্রিয় রয়েছে"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"সমস্ত বিজ্ঞপ্তি সাফ করুন৷"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"সেটিংস"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"বিজ্ঞপ্তির সেটিংস"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> সেটিংস"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"স্ক্রীন স্বয়ংক্রিয়ভাবে ঘুরে যাবে৷"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ভূদৃশ্য সজ্জাতে স্ক্রীন লক করা আছে৷"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"প্রতিকৃতি সজ্জাতে স্ক্রীন লক করা আছে৷"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"স্ক্রিন এখন স্বয়ংক্রিয়ভাবে ঘুরবে।"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"এখন ভূদৃশ্য সজ্জাতে স্ক্রীন লক হয়েছে।"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"এখন প্রতিকৃতি সজ্জাতে স্ক্রীন লক হয়েছে।"</string>
     <string name="dessert_case" msgid="1295161776223959221">"ডেজার্ট কেস"</string>
     <string name="start_dreams" msgid="7219575858348719790">"দিবাস্বপ্ন"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ইথারনেট"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"সেলুলার ডেটা"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ডেটার ব্যবহার"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"অবশিষ্ট ডেটা"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"সীমার উর্ধ্বে"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"সীমা ছাড়িয়েছে - ডেটা ব্যবহার সাময়িক ভাবে থামানো হয়েছে"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ব্যবহৃত হয়েছে"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"সীমা <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> সতর্কতা"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"আপনার সাম্প্রতিক স্ক্রীনগুলো এখানে দেখা যাবে"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"অ্যাপ্লিকেশানের তথ্য"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"অ্যাপ্লিকেশানে লক করুন"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"অনুসন্ধান"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"অনুসন্ধান করুন"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> এর জন্য উপরের দিকে স্লাইড করুন৷"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> এর জন্য বাম দিকে স্লাইড করুন৷"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ব্যাঘাত ছাড়াই, অ্যালার্মও নেই"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ব্যাঘাত ছাড়াই। এমনকি অ্যালার্মও নেই।"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"কোনো বাধা নয়"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"শুধুমাত্র প্রাধান্য বাধাগুলি"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"আপনার পরবর্তী অ্যালার্মের সময় <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> বাজলে আপনি অ্যালার্ম শুনতে পাবেন না"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"নিচে অপেক্ষাকৃত কম জরুরী বিজ্ঞপ্তিগুলি"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"খোলার জন্য আবার স্পর্শ করুন"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"আনলক করতে উপরের দিকে সোয়াইপ করুন"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ফোনের জন্য ডানদিকে সোয়াইপ করুন"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ক্যামেরার জন্য ডানদিকে সোয়াইপ করুন"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"অনির্দিষ্টভাবে"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"কোনো কিছুই নয়"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"অগ্রাধিকার"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"সমস্ত"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"চার্জ হচ্ছে (পূর্ণ হতে <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> সময় বাকি)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ব্যবহারকারী পাল্টে দিন"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ব্যবহারকারী পাল্টান, বর্তমান ব্যবহারকারী <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"প্রোফাইল দেখান"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ব্যবহারকারী জুড়ুন"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"নতুন ব্যবহারকারী"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"অতিথি"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"অতিথি যোগ করুন"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"অতিথি সরান"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"অতিথি সেশন ত্যাগ করছেন?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"অতিথি সেশন থেকে প্রস্থান করা হলে স্থানীয় ডেটা মুছে যাবে।"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"অতিথি সরাবেন?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"এই সেশনের সব অ্যাপ্লিকেশান ও ডেটা মুছে ফেলা হবে।"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"সরান"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"অতিথি, আপনি ফিরে আসায় আপনাকে স্বাগত!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"এক মিনিটের জন্য"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d মিনিটের জন্য"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"এক ঘন্টার জন্য"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d ঘন্টার জন্য"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"আপনি কি আপনার সেশনটি অবিরত রাখতে চান?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"আবার শুরু করুন"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"হ্যাঁ, অবিরত থাকুন"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"নতুন ব্যবহারকারীকে যোগ করবেন?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"আপনি একজন নতুন ব্যবহারকারী যোগ করলে তাকে তার জায়গা সেট আপ করে নিতে হবে৷\n\nযেকোনো ব্যবহারকারী অন্য সব ব্যবহারকারীর জন্য অ্যাপ্লিকেশান আপডেট করতে পারবেন৷"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ব্যাটারি সেভার চালু রয়েছে"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"কার্য-সম্পাদনা ও পশ্চাদপট ডেটাকে কমিয়ে দেয়"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ব্যাটারি সঞ্চয়কারী বন্ধ করুন"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"এখন শুরু করুন"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"কোনো বিজ্ঞপ্তি নেই"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ডিভাইসটি নিরীক্ষণ করা হতে পারে"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"প্রোফাইল পর্যবেক্ষণ করা হতে পারে"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"নেটওয়ার্ক নিরীক্ষণ করা হতে পারে"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ডিভাইস নিরীক্ষণ"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"প্রোফাইল পর্যবেক্ষণ করা"</string>
     <string name="monitoring_title" msgid="169206259253048106">"নেটওয়ার্ক নিরীক্ষণ"</string>
-    <string name="open_app" msgid="4011771120339160755">"অ্যাপ্লিকেশান খুলুন"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN অক্ষম করুন"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN এর সংযোগ বিচ্ছিন্ন করুন"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে পারেন।\n\nআরো তথ্যের জন্য আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"আপনি \"<xliff:g id="APPLICATION">%1$s</xliff:g>\"-কে একটি VPN সংযোগ সেট আপ করার অনুমতি দিয়েছেন।\n\nএই অ্যাপ্লিকেশান ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে পারে।"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"আপনি একটি VPN (“<xliff:g id="APPLICATION">%1$s</xliff:g>”) এর সঙ্গে সংযুক্ত আছেন।\n\nআপনার VPN পরিষেবা প্রদানকারী ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে পারেন।"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nআপনি \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"-কে একটি VPN সংযোগ সেট আপ করার অনুমতি দিয়েছেন। এই অ্যাপ্লিকেশান নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nএছাড়াও, আপনি একটি VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") এ সংযুক্ত আছেন। আপনার VPN পরিষেবা প্রদানকারী নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"এই প্রোফাইলটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে পারেন।\n\nআরো তথ্যের জন্য আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"এই ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nআপনার প্রোফাইলটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nআপনার প্রশাসক ইমেল,অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম।\n\nআরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"এই ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nআপনি \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"-কে একটি VPN সংযোগ সেট আপ করার অনুমতিও দিয়েছেন। এই অ্যাপ্লিকেশান নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"এই প্রোফাইলটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nআপনার প্রশাসক ইমেল, অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nএছাড়াও, আপনি একটি VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") এ সংযুক্ত আছেন। আপনার VPN পরিষেবা প্রদানকারী নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"এই ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nআপনার প্রোফাইলটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nআপনার প্রশাসক ইমেল,অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nআপনি \"<xliff:g id="APPLICATION">%3$s</xliff:g>\"-কে একটি VPN সংযোগ সেট আপ করার অনুমতিও দিয়েছেন। এই অ্যাপ্লিকেশান নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"এই ডিভাইসটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nআপনার প্রোফাইলটি পরিচালনা করছে:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nআপনার প্রশাসক ইমেল,অ্যাপ্লিকেশান ও নিরাপদ ওয়েবসাইটগুলি সহ আপনার নেটওয়ার্ক ক্রিয়াকলাপ নিরীক্ষণ করতে সক্ষম। আরো তথ্যের জন্য, আপনার প্রশাসকের সঙ্গে যোগাযোগ করুন।\n\nএছাড়াও, আপনি একটি VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") এ সংযুক্ত আছেন। আপনার VPN পরিষেবা প্রদানকারী নেটওয়ার্ক ক্রিয়াকলাপও নিরীক্ষণ করতে পারে।"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"আপনি নিজে আনলক না করা পর্যন্ত ডিভাইসটি লক হয়ে থাকবে"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"বিজ্ঞপ্তিগুলি আরো দ্রুত পান"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"আপনি আনলক করার আগে ওগুলো দেখুন"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"না থাক"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"সেট আপ"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> দ্বারা নিঃশব্দ করা হয়েছে"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ca/strings.xml b/packages/SystemUI/res/values-ca/strings.xml
index e8d8e03..c9d1cf5 100644
--- a/packages/SystemUI/res/values-ca/strings.xml
+++ b/packages/SystemUI/res/values-ca/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Esborra"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Elimina de la llista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informació de l\'aplicació"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Aquí es mostren les teves pantalles recents."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Omet les aplicacions recents"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Una aplicació recent"</item>
@@ -35,7 +34,7 @@
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"Notificacions"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"Queda poca bateria"</string>
     <string name="battery_low_percent_format" msgid="1077244949318261761">"<xliff:g id="NUMBER">%d%%</xliff:g> restant"</string>
-    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"Queda un <xliff:g id="NUMBER">%d%%</xliff:g>. La funció Estalvi de bateria està activada."</string>
+    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"Queda un <xliff:g id="NUMBER">%d%%</xliff:g>. Estalvi de bateria està activat."</string>
     <string name="invalid_charger" msgid="4549105996740522523">"Càrrega d\'USB no admesa.\nUtilitza només el carregador proporcionat."</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"La càrrega per USB no és compatible."</string>
     <string name="invalid_charger_text" msgid="5474997287953892710">"Fes servir només el carregador proporcionat amb el dispositiu."</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Enrere"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Pàgina d\'inici"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Pantalles recents"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Cerca"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Càmera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telèfon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloqueja"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloqueja"</string>
+    <string name="phone_label" msgid="2320074140205331708">"obre el telèfon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"obre la càmera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Botó de canvi del mètode d\'entrada."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botó de zoom de compatibilitat."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Amplia menys com més gran sigui la pantalla."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Senyal Wi-Fi: dues barres."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Senyal Wi-Fi: tres barres."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Senyal Wi-Fi: complet."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"S\'ha connectat a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"S\'ha connectat a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Sense WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Una barra de WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dues barres de WiMAX."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Teletip activat."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Mode vibració."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Mode silenci."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Descarta <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"S\'ha omès <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"S\'està iniciant <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificació omesa."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Àrea de notificacions"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Configuració ràpida."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Pantalla de bloqueig"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Configuració"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Pantalles recents"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Usuari <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"La xarxa Wi-Fi està desactivada."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"La xarxa Wi-Fi està activada."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mòbil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateria <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mode d\'avió <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Ubicació: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"El Mode d\'avió està desactivat."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"El Mode d\'avió està activat."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"S\'ha desactivat el Mode d\'avió."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"S\'ha activat el Mode d\'avió."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"El Bluetooth està desactivat."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"El Bluetooth està activat."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"S\'està connectant el Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"El Bluetooth està connectat."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"El Bluetooth està desactivat."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"El Bluetooth està activat."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Informes d\'ubicació desactivats"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Informes d\'ubicació activats"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Els informes d\'ubicació estan desactivats."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Els informes d\'ubicació estan activats."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarma establerta a les <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Tanca el tauler."</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Més temps"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menys temps"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Tanca el tauler."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Més temps"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menys temps"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Llanterna desactivada"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Llanterna activada"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Llanterna desactivada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Llanterna activada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"La inversió de color està desactivada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"La inversió de color està activada."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"El punt d\'accés mòbil està desactivat."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"El punt d\'accés mòbil està activat."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"S\'ha aturat l\'emissió de la pantalla."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brillantor de la pantalla"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"L\'ús de dades 2G-3G està desactivat"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"L\'ús de dades 4G està desactivat"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Les dades mòbils estan desactivades"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"S\'ha establert la ubicació per GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Sol·licituds d\'ubicació actives"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Esborra totes les notificacions."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Configuració"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Configuració de les notificacions"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Configuració de l\'aplicació <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"La pantalla girarà automàticament."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"La pantalla està bloquejada en orientació horitzontal."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"La pantalla està bloquejada en orientació vertical."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ara la pantalla girarà automàticament."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ara la pantalla està bloquejada en orientació horitzontal."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ara la pantalla està bloquejada en orientació vertical."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Capsa de postres"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Estalvi de pantalla"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -202,7 +233,7 @@
     <string name="quick_settings_bluetooth_off_label" msgid="8159652146149219937">"Bluetooth desactivat"</string>
     <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"No hi ha dispositius emparellats disponibles."</string>
     <string name="quick_settings_brightness_label" msgid="6968372297018755815">"Brillantor"</string>
-    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"Rotació automàtica"</string>
+    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"Gira automàticament"</string>
     <string name="quick_settings_rotation_locked_label" msgid="6359205706154282377">"Rotació bloquejada"</string>
     <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"Vertical"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"Horitzontal"</string>
@@ -222,7 +253,7 @@
     <string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"No hi ha cap xarxa"</string>
     <string name="quick_settings_wifi_off_label" msgid="7558778100843885864">"Wi-Fi desconnectada"</string>
     <string name="quick_settings_wifi_detail_empty_text" msgid="2831702993995222755">"No hi ha cap xarxa desada disponible."</string>
-    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Pantalla d\'emissió"</string>
+    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Envia pantalla"</string>
     <string name="quick_settings_casting" msgid="6601710681033353316">"En emissió"</string>
     <string name="quick_settings_cast_device_default_name" msgid="5367253104742382945">"Dispositiu sense nom"</string>
     <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"A punt per a l\'emissió"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Dades mòbils"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Ús de dades"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Dades restants"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Límit excedit"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Límit assolit: ús de dades aturat"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Utilitzats: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Límit: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advertiment: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Aquí es mostren les teves pantalles recents."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informació de l\'aplicació"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"bloqueig d\'aplicació"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"cerca"</string>
@@ -259,52 +289,40 @@
     <string name="description_target_search" msgid="3091587249776033139">"Cerca"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Fes lliscar el dit cap amunt per <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Fes lliscar el dit cap a l\'esquerra per <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sense interrupcions (incloses les alarmes)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Sense interrupcions (ni tan sols alarmes)"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Cap interrupció"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Només les interrupcions prioritàries"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Només interrupcions amb prioritat"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"La propera alarma és a les <xliff:g id="ALARM_TIME">%s</xliff:g>."</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"Propera alarma: <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"No sentiràs l\'alarma a les <xliff:g id="ALARM_TIME">%s</xliff:g>."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificacions menys urgents a continuació"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Torna a tocar per obrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Fes lliscar el dit cap amunt per desbloquejar el teclat."</string>
     <string name="phone_hint" msgid="3101468054914424646">"Fes lliscar el dit cap a la dreta per obrir el telèfon."</string>
     <string name="camera_hint" msgid="5241441720959174226">"Fes lliscar el dit cap a l\'esquerra per obrir la càmera."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidament"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Cap"</string>
-    <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritàries"</string>
+    <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritat"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Totes"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Carregant (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> per completar la càrrega)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Canvia d\'usuari"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Canvia l\'usuari. Usuari actual: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostra el perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Afegeix un usuari"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Usuari nou"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Convidat"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Afegeix un convidat"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Suprimeix l\'usuari"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Vols sortir de la sessió de convidat?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Si surts de la sessió de convidat, se suprimiran dades locals."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Vols suprimir el convidat?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Totes les aplicacions i les dades d\'aquesta sessió se suprimiran."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Suprimeix"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Benvingut de nou, convidat."</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Durant un minut"</item>
-    <item quantity="other" msgid="6924190729213550991">"Durant %d minuts"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Durant una hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Durant %d hores"</item>
-  </plurals>
-    <string name="battery_saver_notification_title" msgid="237918726750955859">"La funció Estalvi de bateria està activada."</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vols continuar amb la sessió?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Torna a començar"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sí, continua"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Vols afegir un usuari nou?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Quan s\'afegeix un usuari nou, aquest usuari ha de configurar-se l\'espai.\n\nQualsevol usuari pot actualitzar les aplicacions de la resta d\'usuaris."</string>
+    <string name="battery_saver_notification_title" msgid="237918726750955859">"Estalvi de bateria activada"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Redueix el rendiment i l\'ús de les dades en segon pla."</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desactiva l\'estalvi de bateria"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Comença ara"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Cap notificació"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"És possible que el dispositiu estigui supervisat."</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"El perfil es pot supervisar"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"És possible que la xarxa estigui supervisada."</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Supervisió del dispositiu"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Supervisió del perfil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Supervisió de la xarxa"</string>
-    <string name="open_app" msgid="4011771120339160755">"Obre l\'aplicació"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Desactiva la VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desconnecta la VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Aquest dispositiu està gestionar per:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'administrador pot supervisar el dispositiu i l\'activitat de la xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs.\n\nPer obtenir més informació, contacta amb el teu administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Has donat permís a \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" per configurar una connexió de VPN.\n\nAquesta aplicació pot supervisar el dispositiu i l\'activitat de la xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Estàs connectat a una VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nEl proveïdor de serveis de VPN pot supervisar el dispositiu i l\'activitat de la xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Administrador del dispositiu:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'administrador pot supervisar la teva activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per obtenir més informació, contacta amb l\'administrador.\n\nA més, has donat permís a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" per configurar una connexió VPN. Aquesta aplicació també pot supervisar l\'activitat de xarxa."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Administrador del dispositiu:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'administrador pot supervisar la teva activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per obtenir més informació, contacta amb l\'administrador.\n\nA més, estàs connectat a una VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). El proveïdor del servei VPN també pot supervisar l\'activitat de xarxa."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Administrador del perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'administrador pot supervisar el dispositiu i la teva activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs.\n\nPer obtenir més informació, contacta amb l\'administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Administrador del dispositiu:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador del perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'administrador pot supervisar el dispositiu i la teva activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs webs segurs.\n\nPer obtenir més informació, contacta amb l\'administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Admin. perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'admin. pot supervisar l\'activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per obtenir més informació, contacta amb l\'admin.\n\nHas donat permís a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" per configurar una connexió VPN. Aquesta aplicació també pot supervisar l\'activitat de xarxa."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Admin. dispositiu:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'admin. pot supervisar l\'activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per obtenir més informació, contacta amb l\'administrador.\n\nEstàs connectat a una VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). El proveïdor del servei VPN també pot supervisar l\'activitat de xarxa."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Admin. dispositiu:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdmin. perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'admin. pot supervisar l\'activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per a més informació, contacta amb l\'admin.\n\nHas donat permís a \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" per configurar una connexió VPN. L\'aplicació pot supervisar l\'activitat de xarxa."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Admin. dispos.:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdmin. perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'admin. pot supervisar l\'activitat de xarxa, inclosos els correus electrònics, les aplicacions i els llocs web segurs. Per a més informació, contacta amb l\'administrador.\n\nEstàs connectat a una VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). El prov. del servei VPN també pot supervisar l\'activitat de xarxa."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"El dispositiu continuarà bloquejat fins que no el desbloquegis manualment."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Obtén notificacions més ràpidament"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Mostra-les abans de desbloquejar"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configura"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Silenciat per <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-cs/strings.xml b/packages/SystemUI/res/values-cs/strings.xml
index bd7e77b..878673c 100644
--- a/packages/SystemUI/res/values-cs/strings.xml
+++ b/packages/SystemUI/res/values-cs/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Vymazat"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Odebrat ze seznamu"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informace o aplikaci"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Zde budou zobrazeny vaše poslední obrazovky"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Zavřít nové aplikace"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 nová aplikace"</item>
@@ -45,7 +44,7 @@
     <string name="battery_saver_start_action" msgid="5576697451677486320">"Zapnout úsporu baterie"</string>
     <string name="status_bar_settings_settings_button" msgid="3023889916699270224">"Nastavení"</string>
     <string name="status_bar_settings_wifi_button" msgid="1733928151698311923">"Wi-Fi"</string>
-    <string name="status_bar_settings_airplane" msgid="4879879698500955300">"Režim V letadle"</string>
+    <string name="status_bar_settings_airplane" msgid="4879879698500955300">"Režim Letadlo"</string>
     <string name="status_bar_settings_auto_rotation" msgid="3790482541357798421">"Autom. otočení obrazovky"</string>
     <string name="status_bar_settings_mute_label" msgid="554682549917429396">"ZTLUM."</string>
     <string name="status_bar_settings_auto_brightness_label" msgid="511453614962324674">"AUTOM."</string>
@@ -70,7 +69,7 @@
     <string name="screenshot_saving_ticker" msgid="7403652894056693515">"Ukládání snímku obrazovky..."</string>
     <string name="screenshot_saving_title" msgid="8242282144535555697">"Ukládání snímku obrazovky..."</string>
     <string name="screenshot_saving_text" msgid="2419718443411738818">"Probíhá ukládání snímku obrazovky."</string>
-    <string name="screenshot_saved_title" msgid="6461865960961414961">"Snímek obrazovky zachycen."</string>
+    <string name="screenshot_saved_title" msgid="6461865960961414961">"Snímek obrazovky Snímek obrazovky pořízen."</string>
     <string name="screenshot_saved_text" msgid="1152839647677558815">"Snímek obrazovky zobrazíte dotykem."</string>
     <string name="screenshot_failed_title" msgid="705781116746922771">"Snímek obrazovky se nepodařilo zachytit."</string>
     <string name="screenshot_failed_text" msgid="1260203058661337274">"Snímek obrazovky nelze pořídit kvůli nedostatku místa, nebo to aplikace či vaše organizace zakazuje."</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Zpět"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Domů"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Poslední obrazovky"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Hledat"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparát"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Odemknout"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"odemknout"</string>
+    <string name="phone_label" msgid="2320074140205331708">"otevřít telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"spustit fotoaparát"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Tlačítko přepnutí metody zadávání"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Tlačítko úpravy velikosti z důvodu kompatibility"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zvětšit menší obrázek na větší obrazovku."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dvě čárky signálu sítě Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tři čárky signálu sítě Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Plný signál sítě Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Připojeno k zařízení <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Připojeno k zařízení <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Žádný signál sítě WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Jedna čárka signálu sítě WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dvě čárky signálu sítě WiMAX."</string>
@@ -140,8 +144,8 @@
     <string name="accessibility_data_connection_edge" msgid="4477457051631979278">"Edge"</string>
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"Wi-Fi"</string>
     <string name="accessibility_no_sim" msgid="8274017118472455155">"Žádná SIM karta."</string>
-    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Tethering přes Bluetooth."</string>
-    <string name="accessibility_airplane_mode" msgid="834748999790763092">"Režim V letadle."</string>
+    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Sdílené připojení přes Bluetooth."</string>
+    <string name="accessibility_airplane_mode" msgid="834748999790763092">"Režim Letadlo."</string>
     <!-- String.format failed for translation -->
     <!-- no translation found for accessibility_battery_level (7451474187113371965) -->
     <skip />
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Rozhraní TeleTypewriter zapnuto."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibrační vyzvánění."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Tiché vyzvánění."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Zavřít aplikaci <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Aplikace <xliff:g id="APP">%s</xliff:g> byla odebrána."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Spouštění aplikace <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Oznámení je zavřeno."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Panel oznámení."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Rychlé nastavení."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Obrazovka uzamčení"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Nastavení"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Poslední obrazovky."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Uživatel <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Připojení Wi-Fi je vypnuto."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Připojení Wi-Fi je zapnuto."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Baterie: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Režim V letadle: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Poloha: <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Režim Letadlo je vypnutý."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Režim Letadlo je zapnutý."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Režim Letadlo je vypnutý."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Režim Letadlo je zapnutý."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Rozhraní Bluetooth je vypnuto."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Rozhraní Bluetooth je zapnuto."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Probíhá připojování rozhraní Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Rozhraní Bluetooth je připojeno."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Rozhraní Bluetooth je vypnuto."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Rozhraní Bluetooth je zapnuto."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Hlášení polohy je vypnuto."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Hlášení polohy je zapnuto."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Hlášení polohy je vypnuto."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Hlášení polohy je zapnuto."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Budík je nastaven na <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Zavřít panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Delší doba"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Kratší doba"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Zavřít panel"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Delší doba"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kratší doba"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Svítilna je vypnutá."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Svítilna je zapnutá."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Svítilna je vypnutá."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Svítilna je zapnutá."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Převrácení barev je vypnuto."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Převrácení barev je zapnuto."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobile hotspot je vypnutý."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobile hotspot je zapnutý."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Odesílání obrazovky zastaveno."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Jas displeje"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Data 2G a 3G jsou vypnuta"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Data 4G jsou vypnuta"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobilní data jsou vypnuta"</string>
@@ -187,14 +214,18 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Poloha nastavena pomocí systému GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktivní žádosti o polohu"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Vymazat všechna oznámení."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Nastavení"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Nastavení oznámení"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Nastavení aplikace <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Obrazovka se automaticky otočí."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Obrazovka je uzamčena v orientaci na šířku."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Obrazovka je uzamčena v orientaci na výšku."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Obrazovka se nyní otáčí automaticky."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Obrazovka je nyní uzamčena v orientaci na šířku."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Obrazovka je nyní uzamčena v orientaci na výšku."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Pult se sladkostmi"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Spořič obrazovky"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
-    <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"Režim V letadle"</string>
+    <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"Režim Letadlo"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"Nabíjení, <xliff:g id="NUMBER">%d</xliff:g> <xliff:g id="PERCENT">%%</xliff:g>"</string>
     <string name="quick_settings_battery_charged_label" msgid="8865413079414246081">"Nabito"</string>
     <string name="quick_settings_bluetooth_label" msgid="6304190285170721401">"Bluetooth"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobilní data"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Využití dat"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Zbývající data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Překročen limit"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Dosáhli jste limitu – využití dat pozastaveno"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Využito: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limit: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Upozornění při <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Zde budou zobrazeny vaše poslední obrazovky"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informace o aplikaci"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"uzamknout v aplikaci"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"vyhledat"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Vyhledávání"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Přejeďte prstem nahoru: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Přejeďte prstem doleva: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Žádná přerušení, ani budíky"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Žádná vyrušení, dokonce ani budíky."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Žádná vyrušení"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Pouze prioritní vyrušení"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Další budík je nastaven na: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Neuslyšíte budík v <xliff:g id="ALARM_TIME">%s</xliff:g>."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Méně urgentní oznámení níže"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Otevřete opětovným klepnutím"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Zařízení odemknete přejetím prstem nahoru"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefon otevřete přejetím prstem vpravo."</string>
     <string name="camera_hint" msgid="5241441720959174226">"Fotoaparát otevřete přejetím prstem vlevo."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Na dobu neurčitou"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Žádné"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritní"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Vše"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Nabíjení (plně nabito za <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Přepnout uživatele"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Přepnout uživatele, aktuální uživatel: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Zobrazit profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Přidat uživatele"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nový uživatel"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Host"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Přidat hosta"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Odstranit hosta"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Ukončit relaci hosta?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Po ukončení relace hosta budou odstraněna místní data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Odstranit hosta?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Veškeré aplikace a data v této relaci budou vymazána."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Odstranit"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Vítejte zpět v relaci hosta!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Na jednu minutu"</item>
-    <item quantity="other" msgid="6924190729213550991">"Na %d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Na jednu hodinu"</item>
-    <item quantity="other" msgid="5408537517529822157">"Na %d h"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Chcete v relaci pokračovat?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Začít znovu"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ano, pokračovat"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Přidat nového uživatele?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Když přidáte nového uživatele, musí si nastavit vlastní prostor.\n\nJakýkoli uživatel může aktualizovat aplikace všech ostatních uživatelů."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Režim Úspora baterie je zapnutý."</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Omezuje výkon a data na pozadí"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Vypnout úsporu baterie"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Spustit"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Žádná oznámení"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Zařízení může být sledováno"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil může být monitorován"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Síť může být sledována"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Sledování zařízení"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitoring profilu"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Sledování sítě"</string>
-    <string name="open_app" msgid="4011771120339160755">"Spustit aplikaci"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Deaktivovat VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Odpojit VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Toto zařízení je spravováno následující organizací:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávce může sledovat vaši aktivitu v síti, včetně e-mailů, aplikací a zabezpečených webových stránek.\n\nChcete-li získat další informace, kontaktujte svého správce."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Aplikaci <xliff:g id="APPLICATION">%1$s</xliff:g> jste udělili oprávnění k nastavení připojení VPN.\n\nSprávce může sledovat vaši aktivitu zařízení a aktivitu v síti, včetně e-mailů, aplikací a zabezpečených webových stránek."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Jste připojeni k síti VPN (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nPoskytovatel připojení VPN může sledovat vaši aktivitu zařízení a aktivitu v síti, včetně e-mailů, aplikací a zabezpečených webových stránek."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Toto zařízení je spravováno následující organizací:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávce může sledovat vaši aktivitu v síti, včetně e-mailů, aplikací a zabezpečených webových stránek. Další informace získáte od svého správce.\n\nNavíc jste aplikaci <xliff:g id="APPLICATION">%2$s</xliff:g> udělili oprávnění k nastavení připojení VPN. Aktivitu v síti může sledovat také tato aplikace."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Toto zařízení je spravováno následující organizací:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávce může sledovat vaši aktivitu v síti, včetně e-mailů, aplikací a zabezpečených webových stránek. Další informace získáte od svého správce.\n\nNavíc jste připojeni také k síti VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Vaši aktivitu v síti může sledovat také poskytovatel připojení VPN."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Tento profil spravuje organizace:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrátor může monitorovat vaše zařízení a síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů.\n\nO další informace požádejte svého administrátora."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Toto zařízení spravuje organizace:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizace:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrátor může monitorovat vaše zařízení a síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů.\n\nO další informace požádejte svého administrátora."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Tento profil spravuje organizace:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrátor může monitorovat vaši síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů. O další informace požádejte svého administrátora.\n\nTaké jste aplikaci <xliff:g id="APPLICATION">%2$s</xliff:g> dali oprávnění nastavit připojení VPN. Tato aplikace může síťovou aktivitu monitorovat také."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Tento profil spravuje organizace:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrátor může monitorovat vaši síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů. O další informace požádejte svého administrátora.\n\nJste také připojeni k síti VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>“). Síťovou aktivitu může monitorovat i poskytovatel služby VPN."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Toto zařízení spravuje organizace:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizace:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrátor může monitorovat vaši síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů. O další informace požádejte svého administrátora.\n\nTaké jste aplikaci <xliff:g id="APPLICATION">%3$s</xliff:g> dali oprávnění nastavit připojení VPN. Tato aplikace může síťovou aktivitu monitorovat také."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Toto zařízení spravuje organizace:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizace:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrátor může monitorovat vaši síťovou aktivitu, včetně e-mailů, aplikací a zabezpečených webů. O další informace požádejte svého administrátora.\n\nJste také připojeni k síti VPN („<xliff:g id="APPLICATION">%3$s</xliff:g>“). Síťovou aktivitu může monitorovat i poskytovatel služby VPN."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Zařízení zůstane uzamčeno, dokud je ručně neodemknete"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Čtěte si oznámení rychleji"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Můžete si je přečíst před odemčením obrazovky."</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ne, děkuji"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Nastavit"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Ignorováno stranou <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-da/strings.xml b/packages/SystemUI/res/values-da/strings.xml
index 178197b..b40bd49 100644
--- a/packages/SystemUI/res/values-da/strings.xml
+++ b/packages/SystemUI/res/values-da/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Ryd"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Fjern fra listen"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Oplysninger om appen"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Dine seneste skærme vises her"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Luk de seneste apps"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 seneste app"</item>
@@ -35,7 +34,7 @@
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"Underretninger"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"Batteriniveauet er lavt"</string>
     <string name="battery_low_percent_format" msgid="1077244949318261761">"<xliff:g id="NUMBER">%d%%</xliff:g> tilbage"</string>
-    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> tilbage. Batteribesparende er slået til."</string>
+    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> tilbage. Batteribesparelse er slået til."</string>
     <string name="invalid_charger" msgid="4549105996740522523">"Opladning via USB understøttes ikke.\nBrug kun den medfølgende oplader."</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"USB-opladning understøttes ikke."</string>
     <string name="invalid_charger_text" msgid="5474997287953892710">"Brug kun den oplader, der føler med."</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Tilbage"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Startskærm"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Seneste skærme"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Søg"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Lås op"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"lås op"</string>
+    <string name="phone_label" msgid="2320074140205331708">"åbn telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"åbn kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Skift indtastningsmetode-knappen."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Knap for kompatibilitetszoom."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom mindre til større skærm."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi to bjælker."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi tre bjælker."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi fuldt signal."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Tilsluttet <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Tilsluttet <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ingen WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX en bjælke."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX to bjælker."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter aktiveret."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Ringervibration."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Lydløs."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Afvis <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> er annulleret."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> startes."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Underretningen er annulleret."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Underretningspanel."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Hurtige indstillinger."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Låseskærm."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Indstillinger"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Seneste skærme."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Bruger <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi er slået fra."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi er slået til."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batteri <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Flytilstand <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Placering <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Flytilstand er slået fra."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Flytilstand er slået til."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Flytilstand er slået fra."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Flytilstand er slået til."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth er slået fra."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth er slået til."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Opretter forbindelse til Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Der er oprettet forbindelse til Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth er slået fra."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth er slået til."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Placeringsrapportering er slået fra."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Placeringsrapportering er slået til."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Placeringsrapportering er slået fra."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Placeringsrapportering er slået til."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarmen er indstillet til <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Luk panelet"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mere tid"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mindre tid"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Luk panelet."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mere tid."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mindre tid."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lommelygten er slået fra."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lommelygten er slået til."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lommelygten er slået fra."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lommelygten er slået til."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Invertering af farver er slået fra."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Invertering af farver er slået til."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilhotspot er slået fra."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilhotspot er slået til."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Casting af din skærm er stoppet."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Skærmens lysstyrke"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G-data er deaktiveret"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-data er deaktiveret"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobildata er deaktiveret"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Placeringen er angivet ved hjælp af GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktive placeringsanmodninger"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Ryd alle underretninger."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Indstillinger"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Underretningsindstillinger"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Indstillinger for <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skærmen roterer automatisk."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skærmen er nu låst i liggende retning."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skærmen er nu låst i stående retning."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skærmen roteres nu automatisk."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skærmen er nu låst i liggende tilstand."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skærmen er nu låst i stående tilstand."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessertcase"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Dagdrøm"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobildata"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Dataforbrug"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Resterende data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Over grænsen"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Grænsen er nået – dataforbruget er midlertidigt afbrudt"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> brugt"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Grænse: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advarsel ved <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Dine seneste skærme vises her"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Oplysninger om applikationen"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"Bliv i app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"søg"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Søgning"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Glid op for at <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Glid til venstre for at <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Ingen afbrydelser, heller ikke alarmer"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Ingen afbrydelser. Ikke engang alarmer."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Ingen afbrydelser"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Kun prioriterede afbrydelser"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Dit næste alarm er indstillet til kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,44 +295,32 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Du vil ikke kunne høre din alarm kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Mindre presserende underretninger nedenfor"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Tryk igen for at åbne"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Stryg for at låse op"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Stryg til højre for at bruge telefonen"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Stryg til venstre for at åbne kameraet"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Uendeligt"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ingen"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alle"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Opladning (fuldt opladet om <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Skift bruger"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Skift bruger. Nuværende bruger er <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Vis profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Tilføj bruger"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Ny bruger"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gæst"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Tilføj gæst"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Fjern gæst"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Vil du afslutte gæstesessionen?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Når gæstesessionen afsluttes, fjernes lokale data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Vil du fjerne gæsten?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alle apps og data i denne session slettes."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Fjern"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Velkommen tilbage, gæst!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"I ét minut"</item>
-    <item quantity="other" msgid="6924190729213550991">"I %d minutter"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"I én time"</item>
-    <item quantity="other" msgid="5408537517529822157">"I %d timer"</item>
-  </plurals>
-    <string name="battery_saver_notification_title" msgid="237918726750955859">"Batteribesparende er slået til"</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vil du fortsætte din session?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Start forfra"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, fortsæt"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Vil du tilføje den nye bruger?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Når du tilføjer en ny bruger, skal personen konfigurere sit område.\n\nEnhver bruger kan opdatere apps for alle andre brugere."</string>
+    <string name="battery_saver_notification_title" msgid="237918726750955859">"Batteribesparelse er slået til"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reducerer ydeevne og baggrundsdata"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Deaktiver batterisparefunktion"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g> %%"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Start nu"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ingen underretninger"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Enheden kan være overvåget"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilen kan overvåges"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Netværket kan være overvåget"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Overvågning af enhed"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilovervågning"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Overvågning af netværk"</string>
-    <string name="open_app" msgid="4011771120339160755">"Åbn app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Deaktiver VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Afbryd VPN-forbindelse"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Denne enhed administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din enhed og netværksaktivitet, herunder e-mails, apps og sikre websites.\n\nKontakt din administrator, hvis du vil have flere oplysninger."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Du har givet \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" tilladelse til at konfigurere en VPN-forbindelse.\n\nDenne app kan overvåge din netværksaktivitet, herunder e-mails, apps og sikre websites."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Du har forbindelse til et VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nDin VPN-udbyder kan overvåge din enhed og netværksaktivitet, herunder e-mails, apps og sikre websites."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Denne enhed administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din netværksaktivitet, f.eks. e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu gav også \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" tilladelse til at konfigurere en VPN-forbindelse. Denne app kan også overvåge netværksaktiviteten."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Denne enhed administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din netværksaktivitet, f.eks. e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu har også forbindelse til et VPN-netværk (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Din VPN-udbyder kan også overvåge netværksaktiviteten."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Denne profil administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din enhed og netværksaktivitet, herunder e-mails, apps og sikre websites.\n\nKontakt administratoren for at få flere oplysninger."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Denne enhed administreres af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil administreres af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nDin administrator kan overvåge din enhed og netværksaktivitet, herunder e-mails, apps og sikre websites.\n\nKontakt administratoren for at få flere oplysninger."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Denne enhed administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din netværksaktivitet, f.eks. e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu har også givet \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" tilladelse til at konfigurere en VPN-forbindelse. Denne app kan også overvåge netværksaktiviteten."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Denne profil administreres af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administrator kan overvåge din netværksaktivitet, herunder e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu har desuden forbindelse til et VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Din VPN-udbyder kan også overvåge din netværksaktivitet."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Enheden administreres af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil administreres af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoren kan overvåge din netværksaktivitet, herunder e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu har desuden givet \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" tilladelse til at konfigurere en VPN-forbindelse. Denne app kan også overvåge netværksaktivitet."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Enheden administreres af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil administreres af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoren kan overvåge din netværksaktivitet, herunder e-mails, apps og sikre websites. Kontakt administratoren for at få flere oplysninger.\n\nDu har desuden forbindelse til et VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Din VPN-udbyder kan også overvåge din netværksaktivitet."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Enheden vil forblive låst, indtil du manuelt låser den op"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Modtag underretninger hurtigere"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Se dem, før du låser op"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nej tak"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Konfigurer"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Lyden blev afbrudt af <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-de/config.xml b/packages/SystemUI/res/values-de/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-de/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-de/strings.xml b/packages/SystemUI/res/values-de/strings.xml
index 527ac56..a742d87 100644
--- a/packages/SystemUI/res/values-de/strings.xml
+++ b/packages/SystemUI/res/values-de/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Löschen"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Aus Liste entfernen"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"App-Info"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Hier sehen Sie Ihre zuletzt geöffneten Apps."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Kürzlich geöffnete Apps schließen"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 kürzlich geöffnete App"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Zurück"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Startbildschirm"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Zuletzt geöffnete Apps"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Suchen"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefonnummer"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Entsperren"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"Entsperren"</string>
+    <string name="phone_label" msgid="2320074140205331708">"Telefon öffnen"</string>
+    <string name="camera_label" msgid="7261107956054836961">"Kamera öffnen"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Schaltfläche zum Ändern der Eingabemethode"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Schaltfläche für Kompatibilitätszoom"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom auf einen größeren Bildschirm"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WLAN: zwei Balken"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WLAN: drei Balken"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Volle WLAN-Signalstärke"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Mit <xliff:g id="WIFI">%s</xliff:g> verbunden"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Mit <xliff:g id="BLUETOOTH">%s</xliff:g> verbunden"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Kein WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX - ein Balken"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX - zwei Balken"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Schreibtelefonie aktiviert"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Klingeltonmodus \"Vibration\""</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Klingelton lautlos"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> beenden"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> entfernt"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> wird gestartet."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Benachrichtigung geschlossen"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Benachrichtigungsleiste"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Schnelleinstellungen"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Sperrbildschirm"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Einstellungen"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Zuletzt geöffnete Apps"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Nutzer: <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WLAN ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WLAN ist aktiviert."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobilfunkverbindung: <xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="TYPE">%2$s</xliff:g>, <xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Akku: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Flugmodus: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Standort <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Flugmodus deaktiviert"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Flugmodus aktiviert"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Der Flugmodus ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Der Flugmodus ist aktiviert."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth deaktiviert"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth aktiviert"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Verbindung mit Bluetooth wird hergestellt."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Mit Bluetooth verbunden"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth ist aktiviert."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Standortbericht deaktiviert"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Standortbericht aktiviert"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Der Standortbericht ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Der Standortbericht ist aktiviert."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Wecker gestellt für <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Fenster schließen"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mehr Zeit"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Weniger Zeit"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Bereich schließen"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mehr Zeit"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Weniger Zeit"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Taschenlampe deaktiviert"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Taschenlampe aktiviert"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Die Taschenlampe ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Die Taschenlampe ist aktiviert."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Die Farbumkehr ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Die Farbumkehr ist aktiviert."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Der mobile Hotspot ist deaktiviert."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Der mobile Hotspot ist aktiviert."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Die Bildschirmübertragung wurde angehalten."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Helligkeit des Displays"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G/3G-Daten deaktiviert"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-Daten deaktiviert"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobilfunkdaten deaktiviert"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Standort durch GPS festgelegt"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Standortanfragen aktiv"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Alle Benachrichtigungen löschen"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Einstellungen"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Benachrichtigungseinstellungen"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Einstellungen von <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Bildschirm wird automatisch gedreht."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Bildschirm bleibt im Querformat."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Bildschirm bleibt im Hochformat."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Bildschirm wird jetzt automatisch gedreht."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Bildschirm bleibt jetzt im Querformat."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Bildschirm bleibt jetzt im Hochformat."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessertbehälter"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobilfunkdaten"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Datennutzung"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Verbleibende Daten"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limit überschritten"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limit erreicht – Datennutzung pausiert"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> verwendet"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> Datenlimit"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Warnung für <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Hier sehen Sie Ihre zuletzt geöffneten Apps."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"App-Info"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"App-Verriegelung"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"Suche"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Suche"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Zum <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> nach oben schieben"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Zum <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> nach links schieben"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Unterbrechungsfrei, gilt auch für Alarme"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Keine Unterbrechungen. Auch keine Weckrufe."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Keine Unterbrechungen"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Nur wichtige Unterbrechungen"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Nächster Weckruf: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Lautloser Weckruf um <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Weniger dringende Benachrichtigungen unten"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Zum Öffnen erneut berühren"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Zum Entsperren nach oben wischen"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Zum Öffnen des Telefons nach rechts wischen"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Zum Öffnen der Kamera nach links wischen"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Unbegrenzt"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Keine"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Wichtig"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alle"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Wird aufgeladen (voll in <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Nutzer wechseln"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Nutzer wechseln. Aktueller Nutzer: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Profil öffnen"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Nutzer hinzufügen"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Neuer Nutzer"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gast"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Gast hinzufügen"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Gast entfernen"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Gastsitzung beenden?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Wenn Sie die Gastsitzung verlassen, werden alle lokal gespeicherten Daten entfernt."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Gast entfernen?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alle Apps und Daten in dieser Sitzung werden gelöscht."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Entfernen"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Willkommen zurück im Gastmodus"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Für eine Minute"</item>
-    <item quantity="other" msgid="6924190729213550991">"Für %d Minuten"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Für eine Stunde"</item>
-    <item quantity="other" msgid="5408537517529822157">"Für %d Stunden"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Möchten Sie Ihre Sitzung fortsetzen?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Von vorn"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, weiter"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Neuen Nutzer hinzufügen?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Wenn Sie einen neuen Nutzer hinzufügen, muss dieser seinen Bereich einrichten.\n\nJeder Nutzer kann Apps für alle anderen Nutzer aktualisieren."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Energiesparmodus ist aktiviert"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduzierung der Leistung und Hintergrunddaten"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Energiesparmodus deaktivieren"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Jetzt starten"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Keine Benachrichtigungen"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Das Gerät wird möglicherweise überwacht."</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil wird möglicherweise überwacht."</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Das Netzwerk wird möglicherweise überwacht."</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Geräteüberwachung"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilüberwachung"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Netzwerküberwachung"</string>
-    <string name="open_app" msgid="4011771120339160755">"App öffnen"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN deaktivieren"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN-Verbindung trennen"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihr Gerät und Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites.\n\nWeitere Informationen erhalten Sie bei Ihrem Administrator."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Sie haben \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" gestattet, eine VPN-Verbindung herzustellen.\n\nDiese App kann Ihr Gerät und Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Sie sind mit einem VPN verbunden: <xliff:g id="APPLICATION">%1$s</xliff:g>.\n\nIhr VPN-Anbieter kann Ihr Gerät und Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivitäten überwachen, darunter E-Mails, Apps und sichere Websites. Mehr erfahren Sie von Ihrem Administrator.\n\nSie haben zudem \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" gestattet, eine VPN-Verbindung herzustellen. Diese App kann auch Ihre Netzwerkaktivitäten überwachen."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivitäten überwachen, einschließlich E-Mails, Apps und sicherer Websites. Mehr erfahren Sie von Ihrem Administrator.\n\nSie sind zudem mit einem VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") verbunden. Ihr VPN-Anbieter kann ebenfalls Ihre Netzwerkaktivitäten überwachen."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Dieses Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihr Gerät und Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites.\n\nWeitere Informationen erhalten Sie von Ihrem Administrator."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIhr Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nIhr Administrator kann Ihr Gerät und Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites.\n\nWeitere Informationen erhalten Sie von Ihrem Administrator."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Dieses Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivität überwachen, darunter E-Mails, Apps und sichere Websites. Mehr erfahren Sie von Ihrem Administrator.\n\nSie haben zudem \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" gestattet, eine VPN-Verbindung herzustellen. Diese App kann Ihre Netzwerkaktivität auch überwachen."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Dieses Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivitäten überwachen, einschließlich E-Mails, Apps und sicherer Websites. Mehr erfahren Sie von Ihrem Administrator.\n\nSie sind zudem mit einem VPN verbunden (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Ihr VPN-Anbieter kann die Netzwerkaktivität ebenfalls überwachen."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIhr Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites. Weitere Informationen erhalten Sie von Ihrem Administrator.\n\nSie haben zudem \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" das Herstellen einer VPN-Verbindung gestattet. Diese App kann die Netzwerkaktivität auch überwachen."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Dieses Gerät wird verwaltet von:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIhr Profil wird verwaltet von:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nIhr Administrator kann Ihre Netzwerkaktivität überwachen, einschließlich E-Mails, Apps und sicherer Websites. Weitere Informationen erhalten Sie von Ihrem Administrator.\n\nSie sind zudem mit einem VPN verbunden (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Ihr VPN-Anbieter kann die Netzwerkaktivität ebenfalls überwachen."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Das Gerät bleibt gesperrt, bis Sie es manuell entsperren."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Benachrichtigungen schneller erhalten"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Vor dem Entsperren anzeigen"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nein danke"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Einrichten"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Stummgeschaltet durch <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-el/config.xml b/packages/SystemUI/res/values-el/config.xml
new file mode 100644
index 0000000..f3cccde
--- /dev/null
+++ b/packages/SystemUI/res/values-el/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 δ, 10 δ, 30 δ, 60 δ, 120 δ"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-el/strings.xml b/packages/SystemUI/res/values-el/strings.xml
index 49169e6..5cba90d 100644
--- a/packages/SystemUI/res/values-el/strings.xml
+++ b/packages/SystemUI/res/values-el/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Εκκαθάριση"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Κατάργηση από τη λίστα"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Πληροφορίες εφαρμογής"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Οι πρόσφατες οθόνες σας εμφανίζονται εδώ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Παράβλεψη πρόσφατων εφαρμογών"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 πρόσφατη εφαρμογή"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Πίσω"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Αρχική σελίδα"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Μενού"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Πρόσφατες οθόνες"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Αναζήτηση"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Φωτογραφική μηχανή"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Τηλέφωνο"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Ξεκλείδωμα"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ξεκλείδωμα"</string>
+    <string name="phone_label" msgid="2320074140205331708">"άνοιγμα τηλεφώνου"</string>
+    <string name="camera_label" msgid="7261107956054836961">"άνοιγμα φωτογραφικής μηχανής"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Κουμπί εναλλαγής μεθόδου εισόδου"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Κουμπί εστίασης συμβατότητας."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Ζουμ από μικρότερη σε μεγαλύτερη οθόνη."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Δύο γραμμές WiFi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Τρεις γραμμές WiFi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Πλήρες σήμα WiFi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Συνδέθηκε στο <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Συνδέθηκε στο <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Δεν υπάρχει σήμα WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Σήμα WiMAX μία γραμμή."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Σήμα WiMAX δύο γραμμές."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Το TeleTypewriter ενεργοποιήθηκε."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Δόνηση ειδοποίησης ήχου."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Ειδοποίηση ήχου στο αθόρυβο."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Παράβλεψη <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Απορρίφθηκαν <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Έναρξη <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Η ειδοποίηση έχει απορριφθεί."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Πλαίσιο σκίασης ειδοποιήσεων."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Γρήγορες ρυθμίσεις."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Κλείδωμα οθόνης."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Ρυθμίσεις"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Πρόσφατες οθόνες."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Χρήστης <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Το Wi-fi απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Το  Wi-fi ενεργοποιήθηκε."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Κινητό <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Μπαταρία <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Λειτουργία πτήσης <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Τοποθεσία <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Ανενεργή λειτουργία πτήσης."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Ενεργή λειτουργία πτήσης."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Η λειτουργία πτήσης απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Ενεργή λειτουργία πτήσης."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Ανενεργό Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Ενεργό Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Σύνδεση Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Το Bluetooth είναι συνδεδεμένο."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Το Bluetooth απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Το Bluetooth ενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Ανενεργή αναφορά τοποθεσίας."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Ενεργή αναφορά τοποθεσίας."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Η Αναφορά τοποθεσίας απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Η Αναφορά τοποθεσίας ενεργοποιήθηκε."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Το ξυπνητήρι έχει οριστεί στις <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Κλείσιμο παραθύρου"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Περισσότερος χρόνος"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Λιγότερος χρόνος"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Κλείσιμο παραθύρου."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Περισσότερη ώρα."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Λιγότερη ώρα."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Ανενεργός φακός."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Ενεργός φακός."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Ο φακός απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Ο φακός ενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Η αντιστροφή χρωμάτων απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Η αντιστροφή χρωμάτων ενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Το σημείο πρόσβασης κινητής συσκευής απενεργοποιήθηκε."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Το σημείο πρόσβασης κινητής συσκευής ενεργοποιήθηκε."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Η μετάδοση της οθόνης διακόπηκε."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Φωτεινότητα οθόνης"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Τα δεδομένα 2G-3G είναι ανενεργά"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Τα δεδομένα 4G είναι ανενεργά"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Τα δεδομένα κινητής τηλεφωνίας είναι ανενεργά"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Ρύθμιση τοποθεσίας με GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Τα αιτήματα τοποθεσίας έχουν ενεργοποιηθεί"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Εκκαθάριση όλων των ειδοποιήσεων."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Ρυθμίσεις"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Ρυθμίσεις ειδοποιήσεων"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Ρυθμίσεις <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Θα γίνεται αυτόματη περιστροφή της οθόνης."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Η οθόνη έχει κλειδωθεί σε οριζόντιο προσανατολισμό."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Η οθόνη έχει κλειδωθεί σε κατακόρυφο προσανατολισμό."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Θα γίνεται πλέον αυτόματη περιστροφή της οθόνης."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Η οθόνη έχει κλειδωθεί σε οριζόντιο προσανατολισμό."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Η οθόνη έχει κλειδωθεί σε κατακόρυφο προσανατολισμό."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Επιδόρπιο"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Δεδομένα κινητής τηλεφωνίας"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Χρήση δεδομένων"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Υπολειπόμενα δεδομένα"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Υπέρβαση ορίου"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Συμπλήρωση του ορίου – παύση χρήσης δεδομένων"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Χρησιμοποιούνται <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Όριο <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Προειδοποίηση για <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Οι πρόσφατες οθόνες σας εμφανίζονται εδώ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Πληροφορίες εφαρμογής"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lock to app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"αναζήτηση"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Αναζήτηση"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Κύλιση προς τα επάνω για <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Κύλιση προς τα αριστερά για <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Χωρίς διακοπές, συμπεριλαμβανομένων των ξυπνητηριών"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Χωρίς διακοπές. Ούτε ειδοποιήσεις,"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Χωρίς διακοπές"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Μόνο διακοπές προτεραιότητας"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Το επόμενο ξυπνητήρι είναι στις <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Δεν θα ακούτε το ξυπνητήρι σας στις <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Λιγότερο επείγουσες ειδοποιήσεις παρακάτω"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Αγγίξτε ξανά για άνοιγμα"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Σύρετε για να ξεκλειδώσετε"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Σύρετε προς τα δεξιά για το τηλέφωνο"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Σύρετε αριστερά για τη φωτογραφική μηχανή"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Επ\' αόριστον"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Κανένα"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Προτεραιότητα"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Όλα"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Φόρτιση (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> για πλήρη φόρτιση)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Εναλλαγή χρήστη"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Εναλλαγή χρήστη, τρέχων χρήστης <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Εμφάνιση προφίλ"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Προσθήκη χρήστη"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Νέος χρήστης"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Επισκέπτης"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Προσθήκη επισκέπτη"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Κατάργηση επισκέπτη"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Έξοδος από την περίοδο σύνδεσης επισκέπτη;"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Η έξοδος από την περίοδο σύνδεσης επισκέπτη θα καταργήσει τα τοπικά δεδομένα."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Κατάργηση επισκέπτη;"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Όλες οι εφαρμογές και τα δεδομένα αυτής της περιόδου σύνδεσης θα διαγραφούν."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Κατάργηση"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Επισκέπτη , καλώς όρισες ξανά!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Για ένα λεπτό"</item>
-    <item quantity="other" msgid="6924190729213550991">"Για %d λεπτά"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Για μία ώρα"</item>
-    <item quantity="other" msgid="5408537517529822157">"Για %d ώρες"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Θέλετε να συνεχίσετε την περίοδο σύνδεσής σας;"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Έναρξη από την αρχή"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ναι, συνέχεια"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Προσθήκη νέου χρήστη;"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Κατά την προσθήκη ενός νέου χρήστη, αυτός θα πρέπει να ρυθμίσει το χώρο του.\n\nΟποιοσδήποτε χρήστης μπορεί να ενημερώσει τις εφαρμογές για όλους τους άλλους χρήστες."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Η Εξοικονόμηση μπαταρίας είναι ενεργή"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Μειώνει την απόδοση και τα δεδομένα παρασκηνίου"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Απενεργοποίηση εξοικονόμησης μπαταρίας"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Έναρξη τώρα"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Δεν υπάρχουν ειδοποιήσεις"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Η συσκευή μπορεί να παρακολουθείται"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Το προφίλ ενδέχεται να παρακολουθείται"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Το δίκτυο ενδέχεται να παρακολουθείται"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Παρακολούθηση συσκευής"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Παρακολούθηση προφίλ"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Παρακολούθηση δικτύου"</string>
-    <string name="open_app" msgid="4011771120339160755">"Άνοιγμα εφαρμογής"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Απενεργοποίηση VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Αποσύνδεση VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Η διαχείριση αυτής της συσκευής πραγματοποιείται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής σας μπορεί να παρακολουθεί τη δραστηριότητα της συσκευής σας και του δικτύου, συμπεριλαμβανομένων των μηνυμάτων ηλεκτρονικού ταχυδρομείου, των εφαρμογών και των ασφαλών ιστότοπων.\n\nΓια περισσότερες πληροφορίες, επικοινωνήστε με το διαχειριστή σας."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Παραχωρήσατε στην εφαρμογή \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" άδεια για τη δημιουργία σύνδεσης VPN.\n\nΑυτή η εφαρμογή μπορεί να παρακολουθεί τη δραστηριότητα της συσκευής σας και του δικτύου, συμπεριλαμβανομένων των μηνυμάτων ηλεκτρονικού ταχυδρομείου, των εφαρμογών και των ασφαλών ιστότοπων."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Είστε συνδεδεμένοι σε VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nΟ πάροχος της υπηρεσίας VPN μπορεί να παρακολουθεί τη δραστηριότητα της συσκευής σας και του δικτύου, συμπεριλαμβανομένων των μηνυμάτων ηλεκτρονικού ταχυδρομείου, των εφαρμογών και των ασφαλών ιστότοπων."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Η διαχ. της συσκευής γίνεται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακ. τη δραστ. του δικτύου, όπως τα μην. ηλ. ταχυδρ., τις εφαρ. και τους ασφ. ιστότ. Για περισ. πληροφορίες, επικοιν. με το διαχειριστή.\n\nΕπίσης, επιτρέψατε στο \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" να ρυθμίσει σύνδεση VPN. Αυτή η εφαρ. μπορεί να παρακ. τη δραστ. του δικτύου."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Η διαχείριση της συσκευής γίνεται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολ. τη δραστ. του δικτύου, όπως τα μην. ηλεκ. ταχυδρ., τις εφαρμογές και τους ασφαλείς ιστότοπους. Για περισ. πληροφορίες, επικοιν. με το διαχειριστή.\n\nΕπίσης, είστε συνδεδ. σε VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Ο παροχέας VPN μπορεί να παρακολ. τη δραστ. του δικτύου."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Η διαχείριση του προφίλ γίνεται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και δραστηριότητα δικτύου, email, εφαρμογές και ασφαλείς ιστότοπους.\n\nΓια πληροφορίες, επικοινωνήστε με το διαχειριστή."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Η διαχείριση της συσκευής γίνεται από:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nΗ διαχείριση του προφίλ σας γίνεται από:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και τη δραστηριότητα δικτύου σας, τα μηνύματα ηλεκτρονικού ταχυδρομείου, τις εφαρμογές και τους ασφαλείς ιστότοπους.\n\nΓια πληροφορίες, επικοινωνήστε με το διαχειριστή."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Η διαχείριση του προφίλ γίνεται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και δραστηριότητα δικτύου, email, εφαρμογές και ασφαλείς ιστότοπους. Για πληροφορίες, επικοινωνήστε με το διαχειριστή.\n\nΠαραχωρήσατε άδεια \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" για ρύθμιση σύνδεσης VPN. Η εφαρμογή μπορεί να παρακολουθεί τη δραστηριότητα δικτύου."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Η διαχείριση του προφίλ γίνεται από:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και δραστηριότητα δικτύου, email, εφαρμογές και ασφαλείς ιστότοπους. Για πληροφορίες, επικοινωνήστε με το διαχειριστή.\n\nΕπίσης, συνδεθήκατε σε VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Ο πάροχος VPN μπορεί να παρακολουθεί τη δραστηριότητα δικτύου."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Η διαχείριση της συσκευής γίνεται από:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nΗ διαχείριση του προφίλ γίνεται από:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και δραστηριότητα δικτύου, email, εφαρμογές και ασφαλείς ιστότοπους. Για πληροφορίες, επικοινωνήστε με το διαχειριστή.\n\nΠαραχωρήσατε άδεια \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" για ρύθμιση σύνδεσης VPN. Η εφαρμογή μπορεί να παρακολουθεί τη δραστηριότητα δικτύου."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Η διαχείριση της συσκευής γίνεται από:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nΗ διαχείριση του προφίλ γίνεται από:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nΟ διαχειριστής μπορεί να παρακολουθεί τη συσκευή και τη δραστηριότητα δικτύου σας, τα email, εφαρμογές και ασφαλείς ιστότοπους.\n\nΕπίσης, συνδεθήκατε σε VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Ο πάροχος VPN μπορεί να παρακολουθεί τη δραστηριότητα δικτύου σας."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Η συσκευή θα παραμείνει κλειδωμένη έως ότου την ξεκλειδώσετε μη αυτόματα"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Λάβετε ειδοποιήσεις γρηγορότερα"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Εμφάνιση πριν το ξεκλείδωμα"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Όχι"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Ρύθμιση"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Σίγαση από <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-en-rGB/strings.xml b/packages/SystemUI/res/values-en-rGB/strings.xml
index b7af804..0418ae0 100644
--- a/packages/SystemUI/res/values-en-rGB/strings.xml
+++ b/packages/SystemUI/res/values-en-rGB/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Clear"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Remove from list"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"App info"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Your recent screens appear here"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Dismiss recent apps"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 recent app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Back"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Home"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Recent screens"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Search"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Phone"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Unlock"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"unlock"</string>
+    <string name="phone_label" msgid="2320074140205331708">"open phone"</string>
+    <string name="camera_label" msgid="7261107956054836961">"open camera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Switch input method button."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Compatibility zoom button."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom smaller to larger screen."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi two bars."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi three bars."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi signal full."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Connected to <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Connected to <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"No WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX one bar."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX two bars."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter enabled."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Ringer vibrate."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Ringer silent."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Dismiss <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> dismissed."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Starting <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notification dismissed."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Notification shade."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Quick settings."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lock screen."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Settings"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Recent screens."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"User <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi turned off."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi turned on."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobile <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Battery <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Aeroplane Mode <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Location <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Aeroplane mode off."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Aeroplane mode on."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Aeroplane mode turned off."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Aeroplane mode turned on."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth off."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth on."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth connecting."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth connected."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth turned off."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth turned on."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Location reporting off."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Location reporting on."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Location reporting turned off."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Location reporting turned on."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm set for <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Close panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"More time"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Less time"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Close panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"More time."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Less time."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Torch off."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Torch on."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Torch turned off."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Torch turned on."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Colour inversion turned off."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Colour inversion turned on."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobile hotspot turned off."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobile hotspot turned on."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Screen casting stopped."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Display brightness"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G data is off"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G data is off"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobile data is off"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Location set by GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Location requests active"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Clear all notifications."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Settings"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Notification settings"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> settings"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Screen will rotate automatically."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Screen is locked in landscape orientation."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Screen is locked in portrait orientation."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Screen will now rotate automatically."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Screen is now locked in landscape orientation."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Screen is now locked in portrait orientation."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobile data"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Data usage"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Remaining data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Over limit"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limit reached – data usage paused"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> used"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> limit"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> warning"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Your recent screens appear here"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Application Info"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lock to app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"search"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Search"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Slide up for <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Slide left for <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"No interruptions, including alarms"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"No interruptions. Not even alarms."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"No interruptions"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Priority interruptions only"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Your next alarm is at <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"You won\'t hear your alarm at <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Less urgent notifications below"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Touch again to open"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Swipe up to unlock"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Swipe right for phone"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Swipe left for camera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinitely"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"None"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Priority"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"All"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Charging (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> until full)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Switch user"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Switch user, current user <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Show profile"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Add user"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"New user"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Guest"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Add guest"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Remove guest"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Exiting guest session?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Exiting the guest session will remove local data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Remove guest?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"All apps and data in this session will be deleted."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Remove"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Welcome back, guest!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"For one minute"</item>
-    <item quantity="other" msgid="6924190729213550991">"For %d minutes"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"For one hour"</item>
-    <item quantity="other" msgid="5408537517529822157">"For %d hours"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Do you want to continue your session?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Start again"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Yes, continue"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Add new user?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"When you add a new user, that person needs to set up their space.\n\nAny user can update apps for all other users."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Battery saver is on"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduces performance and background data"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Turn off battery saver"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Start now"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"No notifications"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Device may be monitored"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profile may be monitored"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Network may be monitored"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Device monitoring"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profile monitoring"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Network monitoring"</string>
-    <string name="open_app" msgid="4011771120339160755">"Open app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Disable VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Disconnect VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"You gave \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" permission to set up a VPN connection.\n\nThis app can monitor your device and network activity, including emails, apps and secure websites."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"You\'re connected to a VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nYour VPN service provider can monitor your device and network activity including emails, apps and secure websites."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Device will stay locked until you manually unlock"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Get notifications faster"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"See them before you unlock"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No, thanks"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Setup"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Muted by <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-en-rIN/strings.xml b/packages/SystemUI/res/values-en-rIN/strings.xml
index b7af804..0418ae0 100644
--- a/packages/SystemUI/res/values-en-rIN/strings.xml
+++ b/packages/SystemUI/res/values-en-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Clear"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Remove from list"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"App info"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Your recent screens appear here"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Dismiss recent apps"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 recent app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Back"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Home"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Recent screens"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Search"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Phone"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Unlock"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"unlock"</string>
+    <string name="phone_label" msgid="2320074140205331708">"open phone"</string>
+    <string name="camera_label" msgid="7261107956054836961">"open camera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Switch input method button."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Compatibility zoom button."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom smaller to larger screen."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi two bars."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi three bars."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi signal full."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Connected to <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Connected to <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"No WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX one bar."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX two bars."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter enabled."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Ringer vibrate."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Ringer silent."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Dismiss <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> dismissed."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Starting <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notification dismissed."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Notification shade."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Quick settings."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lock screen."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Settings"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Recent screens."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"User <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi turned off."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi turned on."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobile <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Battery <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Aeroplane Mode <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Location <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Aeroplane mode off."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Aeroplane mode on."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Aeroplane mode turned off."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Aeroplane mode turned on."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth off."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth on."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth connecting."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth connected."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth turned off."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth turned on."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Location reporting off."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Location reporting on."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Location reporting turned off."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Location reporting turned on."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm set for <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Close panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"More time"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Less time"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Close panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"More time."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Less time."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Torch off."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Torch on."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Torch turned off."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Torch turned on."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Colour inversion turned off."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Colour inversion turned on."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobile hotspot turned off."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobile hotspot turned on."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Screen casting stopped."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Display brightness"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G data is off"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G data is off"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobile data is off"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Location set by GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Location requests active"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Clear all notifications."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Settings"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Notification settings"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> settings"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Screen will rotate automatically."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Screen is locked in landscape orientation."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Screen is locked in portrait orientation."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Screen will now rotate automatically."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Screen is now locked in landscape orientation."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Screen is now locked in portrait orientation."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobile data"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Data usage"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Remaining data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Over limit"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limit reached – data usage paused"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> used"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> limit"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> warning"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Your recent screens appear here"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Application Info"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lock to app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"search"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Search"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Slide up for <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Slide left for <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"No interruptions, including alarms"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"No interruptions. Not even alarms."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"No interruptions"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Priority interruptions only"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Your next alarm is at <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"You won\'t hear your alarm at <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Less urgent notifications below"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Touch again to open"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Swipe up to unlock"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Swipe right for phone"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Swipe left for camera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinitely"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"None"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Priority"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"All"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Charging (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> until full)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Switch user"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Switch user, current user <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Show profile"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Add user"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"New user"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Guest"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Add guest"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Remove guest"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Exiting guest session?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Exiting the guest session will remove local data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Remove guest?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"All apps and data in this session will be deleted."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Remove"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Welcome back, guest!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"For one minute"</item>
-    <item quantity="other" msgid="6924190729213550991">"For %d minutes"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"For one hour"</item>
-    <item quantity="other" msgid="5408537517529822157">"For %d hours"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Do you want to continue your session?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Start again"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Yes, continue"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Add new user?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"When you add a new user, that person needs to set up their space.\n\nAny user can update apps for all other users."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Battery saver is on"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduces performance and background data"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Turn off battery saver"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Start now"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"No notifications"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Device may be monitored"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profile may be monitored"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Network may be monitored"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Device monitoring"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profile monitoring"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Network monitoring"</string>
-    <string name="open_app" msgid="4011771120339160755">"Open app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Disable VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Disconnect VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"You gave \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" permission to set up a VPN connection.\n\nThis app can monitor your device and network activity, including emails, apps and secure websites."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"You\'re connected to a VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nYour VPN service provider can monitor your device and network activity including emails, apps and secure websites."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"This device is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Device will stay locked until you manually unlock"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Get notifications faster"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"See them before you unlock"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No, thanks"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Setup"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Muted by <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-es-rUS/strings.xml b/packages/SystemUI/res/values-es-rUS/strings.xml
index 71c9919..ebce179 100644
--- a/packages/SystemUI/res/values-es-rUS/strings.xml
+++ b/packages/SystemUI/res/values-es-rUS/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Eliminar"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Eliminar de la lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Información de la aplicación"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Las pantallas recientes aparecen aquí."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Rechazar aplicaciones recientes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicación reciente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Atrás"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Página principal"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Pantallas recientes"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Teléfono"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloquear"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloquear"</string>
+    <string name="phone_label" msgid="2320074140205331708">"abrir teléfono"</string>
+    <string name="camera_label" msgid="7261107956054836961">"abrir cámara"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Botón Cambiar método de entrada"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botón de zoom de compatibilidad"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom de pantalla más pequeña a más grande"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dos barras de Wi-Fi"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tres barras de Wi-Fi"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Señal de Wi-Fi excelente"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Conectado a <xliff:g id="WIFI">%s</xliff:g>"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Conectado a <xliff:g id="BLUETOOTH">%s</xliff:g>"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Sin conexión WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Una barra de WiMAX"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dos barras de WiMAX"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter habilitado"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Timbre en vibración"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Timbre en silencio"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Rechazar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> descartada."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Iniciando <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificación ignorada"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Pantalla de notificaciones"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Configuración rápida"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Pantalla bloqueada"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Configuración"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Pantallas recientes"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Usuario <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi desactivado"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi activado"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Móvil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batería <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modo avión <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Ubicación <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modo de avión: desactivado"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modo de avión: activado"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Modo de avión desactivado"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Modo de avión activado"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth desactivado"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth activado"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth conectándose"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth conectado"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth desactivado"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth activado"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Informes de Ubicación desactivados"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Informes de Ubicación activados"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Informes de Ubicación desactivados"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Informes de Ubicación activados"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarma: <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Cerrar panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Más tiempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menos tiempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Cerrar panel"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Más tiempo"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menos tiempo"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Linterna desactivada"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Linterna activada"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Linterna desactivada"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Linterna activada"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversión de color desactivada"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversión de color activada"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Zona móvil desactivada"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Zona móvil activada"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Transmisión de pantalla detenida"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brillo de pantalla"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Datos 2G-3G desactivados"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Datos 4G desactivados"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Datos móviles desactivados"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"La ubicación se estableció por GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Solicitudes de ubicación activas"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Eliminar todas las notificaciones"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Configuración"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Configuración de notificaciones"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Configuración de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"La pantalla girará automáticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"La pantalla está bloqueada en modo horizontal."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"La pantalla está bloqueada en modo vertical."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"La pantalla ahora rotará automáticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"La pantalla está bloqueada en orientación paisaje."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"La pantalla está bloqueada en orientación retrato."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Caja para postres"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Activar protector"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Datos móviles"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Uso de datos"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Datos restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Límite superado"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Límite alcanzado: uso de datos pausado"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Utilizados: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Límite de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advertencia de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Las pantallas recientes aparecen aquí."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Información de la aplicación"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"fijar aplicación"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"buscar"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Buscar"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Desliza el dedo hacia arriba para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Desliza el dedo hacia la izquierda para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sin interrupciones, incluidas las alarmas"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Sin interrupciones (ni siquiera alarmas)"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Sin interrupciones"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Solo interrupciones de prioridad"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Próxima alarma a la(s) <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"No oirás la alarma a la(s) <xliff:g id="ALARM_TIME">%s</xliff:g>."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificaciones menos urgentes abajo"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Vuelve a tocar para abrir."</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Deslizar el dedo hacia arriba para desbloquear"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Desliza hacia la derecha para abrir el teléfono."</string>
     <string name="camera_hint" msgid="5241441720959174226">"Desliza hacia la izquierda para acceder a la cámara."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ninguno"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioridad"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Todo"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Cargando (faltan <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> para completar)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Cambiar usuario"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Cambiar de usuario (usuario actual: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostrar perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Agregar usuario"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Usuario nuevo"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Invitado"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Agregar invitado"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Eliminar invitado"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"¿Deseas salir de la sesión de invitado?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Si sales de la sesión de invitado, se eliminarán los datos locales."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"¿Eliminar invitado?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Se eliminarán las aplicaciones y los datos de esta sesión."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Eliminar"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bienvenido nuevamente, invitado."</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Durante una hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"¿Quieres retomar la sesión?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Volver a empezar"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sí, continuar"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"¿Agregar usuario nuevo?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Cuando agregas un nuevo usuario, esa persona debe configurar su espacio.\n\nCualquier usuario puede actualizar aplicaciones para todos los usuarios."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Ahorro de batería activado"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduce el rendimiento y el uso de datos en segundo plano."</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desactivar el ahorro de batería"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Comenzar ahora"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"No hay notificaciones"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Es posible que el dispositivo esté supervisado."</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Es posible que se supervise el perfil."</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Es posible que la red esté supervisada."</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Supervisión del dispositivo"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Supervisión del perfil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Supervisión de red"</string>
-    <string name="open_app" msgid="4011771120339160755">"Abrir aplicación"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Inhabilitar VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desconectar VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Este dispositivo está administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar la actividad de la red y del dispositivo, incluidos el correo electrónico, las aplicaciones y los sitios web seguros.\n\nPara obtener más información, comunícate con el administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Permitiste que \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" configure una conexión VPN.\n\nEsta aplicación puede supervisar la actividad de la red y del dispositivo, incluidos el correo electrónico, las aplicaciones y los sitios web seguros."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Estás conectado a una VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nEl proveedor de servicios de VPN puede supervisar la actividad de la red y del dispositivo, incluidos el correo electrónico, las aplicaciones y los sitios web seguros."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Dispositivo está administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red (correo electrónico, aplicaciones y sitios web seguros). Para más información, comunícate con el administrador.\n\nY permitiste que \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" configure una VPN. La aplicación también puede supervisar la actividad de red."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Dispositivo administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red (correo electrónico, aplicaciones y sitios web seguros). Para más información, comunícate con el administrador.\n\nY estás conectado a una VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). El proveedor de servicios de VPN puede supervisar la actividad de red."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Administrador de este perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar el dispositivo y la actividad de red, incluidos correos electrónicos, aplicaciones y sitios web seguros.\n\nPara más información, comunícate con el administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Administrador de este dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador de tu perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nEl administrador puede supervisar el dispositivo y la actividad de red, incluidos correos electrónicos, aplicaciones y sitios web seguros.\n\nPara más información, comunícate con el administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Administrador de perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red, como correos electrónicos, aplicaciones y sitios web seguros. Para más información, comunícate con el administrador.\n\nPermitiste que \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" configure una conexión VPN; también puede supervisar la actividad de red."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Administrador perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red, como correos electrónicos, aplicaciones y sitios web seguros. Para más información, comunícate con el administrador.\n\nEstás conectado a una VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). El proveedor de servicios VPN también puede supervisar la actividad de red."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Administrador dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red, como correos, aplicaciones y sitios web seguros. Para más información, comunícate con el administrador.\n\nPermitiste que \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" configure una conexión VPN; también puede supervisar la actividad de red."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Administrador dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nEl administrador puede supervisar la actividad de red, como correos, aplicaciones y sitios seguros. Para más información, comunícate con el administrador.\n\nEstás conectado a una VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). El proveedor de servicios VPN puede supervisar la actividad de red."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"El dispositivo permanecerá bloqueado hasta que lo desbloquees manualmente."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Recibe notificaciones más rápido"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ver antes de desbloquear"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurar"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Silenciados por <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-es/strings.xml b/packages/SystemUI/res/values-es/strings.xml
index c732090..4328c5b 100644
--- a/packages/SystemUI/res/values-es/strings.xml
+++ b/packages/SystemUI/res/values-es/strings.xml
@@ -19,12 +19,11 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="7164937344850004466">"IU sistema"</string>
+    <string name="app_label" msgid="7164937344850004466">"Interfaz de usuario del sistema"</string>
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Borrar"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Eliminar de la lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Información de la aplicación"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Aquí aparecerán tus pantallas recientes"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Ignorar aplicaciones recientes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicación reciente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Atrás"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Inicio"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Pantallas recientes"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Teléfono"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloquear"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloquear"</string>
+    <string name="phone_label" msgid="2320074140205331708">"abrir teléfono"</string>
+    <string name="camera_label" msgid="7261107956054836961">"abrir cámara"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Botón Cambiar método de entrada"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botón de zoom de compatibilidad"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom de pantalla más pequeña a más grande"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dos barras de Wi-Fi"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tres barras de Wi-Fi"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Señal de Wi-Fi al máximo"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Conectado a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Conectado a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Sin conexión WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Una barra de WiMAX"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dos barras de WiMAX"</string>
@@ -140,7 +144,7 @@
     <string name="accessibility_data_connection_edge" msgid="4477457051631979278">"Tipo Edge"</string>
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"Wi-Fi"</string>
     <string name="accessibility_no_sim" msgid="8274017118472455155">"Sin tarjeta SIM"</string>
-    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Anclaje de Bluetooth"</string>
+    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Anclaje por Bluetooth"</string>
     <string name="accessibility_airplane_mode" msgid="834748999790763092">"Modo avión"</string>
     <string name="accessibility_battery_level" msgid="7451474187113371965">"<xliff:g id="NUMBER">%d</xliff:g> por ciento de batería"</string>
     <string name="accessibility_settings_button" msgid="799583911231893380">"Ajustes del sistema"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Teletipo habilitado"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Modo vibración"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Modo silencio"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Ignorar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Se ha eliminado <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Iniciando <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificación ignorada"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Pantalla de notificaciones"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Ajustes rápidos"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Pantalla de bloqueo."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Ajustes"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Pantallas recientes."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Usuario <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi desactivado."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi activado."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Móvil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batería <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modo avión <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Ubicación <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modo avión desactivado."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modo avión activado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Modo avión desactivado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Modo avión activado."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth desactivado."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth activado."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Conectando Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth conectado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth desactivado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth activado."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Informes de Ubicación desactivados."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Informes de Ubicación activados."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Informes de Ubicación desactivados."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Informes de Ubicación activados."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"La alarma sonará a la(s) <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Cerrar panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Más tiempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menos tiempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Cerrar panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Más tiempo."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menos tiempo."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Linterna desactivada."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Linterna activada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Linterna desactivada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Linterna activada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversión de color desactivada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversión de color activada."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Punto de acceso móvil desactivado."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Punto de acceso móvil activado."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Envío de pantalla detenido."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brillo de la pantalla"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Datos 2G-3G desactivados"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Datos 4G desactivados"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Datos móviles desactivados"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Ubicación definida por GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Solicitudes de ubicación activas"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Borrar todas las notificaciones"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Ajustes"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Ajustes de notificaciones"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Ajustes de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"La pantalla girará automáticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"La pantalla está bloqueada en modo horizontal."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"La pantalla está bloqueada en modo vertical."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ahora la pantalla girará automáticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ahora la pantalla está bloqueada en orientación horizontal."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ahora la pantalla está bloqueada en orientación vertical."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Caja para postres"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Salvapantallas"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Datos móviles"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Uso de datos"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Datos restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Límite superado"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Límite alcanzado: uso de datos pausado"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> utilizado"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Límite de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advertencia de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Aquí aparecerán tus pantallas recientes"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Información de la aplicación"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"bloqueo de aplicación"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"buscar"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Buscar"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Desliza el dedo hacia arriba para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Desliza el dedo hacia la izquierda para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sin interrupciones, incluidas alarmas"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Sin interrupciones, ni siquiera alarmas."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Sin interrupciones"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Solo interrupciones de prioridad"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Siguiente alarma: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"No oirás tu alarma a las <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificaciones menos urgente abajo"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Vuelve a tocar para abrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Desliza el dedo hacia arriba para desbloquear"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Desliza el dedo hacia la izquierda para acceder al teléfono"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Desliza el dedo hacia la izquierda para acceder a la cámara"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
-    <string name="interruption_level_none" msgid="3831278883136066646">"Ninguno"</string>
+    <string name="interruption_level_none" msgid="3831278883136066646">"Nada"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioridad"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Todo"</string>
-    <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Cargando (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> hasta completar)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Cargando (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> para completar)"</string>
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Cambiar de usuario"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Cambiar de usuario (usuario actual <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostrar perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Añadir usuario"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nuevo usuario"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Invitado"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Añadir invitado"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Eliminar invitado"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"¿Quieres salir de la sesión de invitado?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Si sales de la sesión de invitado, se eliminarán los datos locales."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"¿Eliminar invitado?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Se eliminarán las aplicaciones y los datos de esta sesión."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Eliminar"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Hola de nuevo, invitado"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Durante una hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"¿Quieres continuar con la sesión?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Volver a empezar"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sí, continuar"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"¿Añadir usuario nuevo?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Al añadir un usuario nuevo, este debe configurar su espacio.\n\nCualquier usuario puede actualizar las aplicaciones del resto de usuarios."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Ahorro de batería activado"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduce el rendimiento y el envío de datos en segundo plano"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desactivar ahorro de batería"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Iniciar ahora"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ninguna notificación"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Es posible que este dispositivo esté supervisado"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Es posible que se supervise el perfil"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Puede que la red esté supervisada"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Supervisión de dispositivo"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Supervisión del perfil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Supervisión de red"</string>
-    <string name="open_app" msgid="4011771120339160755">"Abrir aplicación"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Inhabilitar VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desconectar VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Este dispositivo está administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTu administrador puede supervisar la actividad de tu red y de tu dispositivo, incluidos correos electrónicos, aplicaciones y sitios web seguros.\n\nPara obtener más información, ponte en contacto con tu administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Has concedido permiso a \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" para configurar una conexión VPN.\n\nEsta aplicación puede supervisar la actividad de tu red y de tu dispositivo, incluidos correos electrónicos, aplicaciones y sitios web seguros."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Estás conectado a una red VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nTu proveedor de servicios de VPN puede supervisar la actividad de tu red y de tu dispositivo, incluidos correos electrónicos, aplicaciones y sitios web seguros."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Este dispositivo está administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTu administrador puede supervisar la actividad de tu red, incluidos correos electrónicos, aplicaciones y sitios web seguros. Para obtener más información, ponte en contacto con tu administrador.\n\nAdemás, has concedido permiso a <xliff:g id="APPLICATION">%2$s</xliff:g> para configurar una red VPN. Esta aplicación también puede supervisar tu red."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Este dispositivo está administrado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTu administrador puede supervisar la actividad de tu red, incluidos correos electrónicos, aplicaciones y sitios web seguros. Para obtener más información, ponte en contacto con tu administrador.\n\nAdemás, estás conectado a una red VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). El proveedor de servicios de VPN también puede supervisar la actividad de la red."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Administrador de este perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nEl administrador puede supervisar tu dispositivo y actividad de red, como correos electrónicos, aplicaciones y sitios web seguros.\n\nPara obtener más información, ponte en contacto con el administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Administrador de este dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador de tu perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nEl administrador puede supervisar tu dispositivo y actividad de red, como correos electrónicos, aplicaciones y sitios web seguros.\n\nPara obtener más información, ponte en contacto con el administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Administrador perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrador puede supervisar actividad red, como correos electrónicos, aplicaciones y sitios web seguros. Para obtener más información, ponte en contacto con administrador.\n\nHas concedido permiso a <xliff:g id="APPLICATION">%2$s</xliff:g> para configurar conexión VPN, por lo que también puede supervisar actividad red."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Administrador del perfil:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrador puede supervisar actividad red, como correos electrónicos, aplicaciones y sitios web seguros. Para obtener más información, ponte en contacto con administrador.\n\nEstás conectado a red VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"), por lo que proveedor servicios VPN puede supervisar actividad red."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Administrador dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrador puede supervisar actividad red, como correos electrónicos, aplicaciones y sitios web seguros. Para info, ponte en contacto con administrador.\n\nHas concedido permiso a <xliff:g id="APPLICATION">%3$s</xliff:g> para configurar conexión VPN y también puede supervisar actividad red."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Administrador dispositivo:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAdministrador perfil:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrador puede supervisar actividad red, como correos electrónicos, aplicaciones y sitios web seguros. Para más info, ponte en contacto con administrador.\n\nEstás conectado a VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"), por lo que proveedor servicios VPN puede supervisar actividad red."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"El dispositivo permanecerá bloqueado hasta que se desbloquee manualmente"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Recibe notificaciones más rápido"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ver antes de desbloquear"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No, gracias"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurar"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Silenciado por <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-et-rEE/strings.xml b/packages/SystemUI/res/values-et-rEE/strings.xml
index f4a01f3..af22a98 100644
--- a/packages/SystemUI/res/values-et-rEE/strings.xml
+++ b/packages/SystemUI/res/values-et-rEE/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Kustuta"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Loendist eemaldamine"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Rakenduse teave"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Teie viimane ekraanikuva ilmub siia"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Loobu hiljutistest rakendustest"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 hiljutine rakendus"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Tagasi"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Kodu"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menüü"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Hiljutised ekraanikuvad"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Otsing"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kaamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Luku avamine"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ava lukk"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ava telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ava kaamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Sisestusmeetodi vahetamise nupp."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Sobivussuumi nupp."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Suumi suuremale ekraanile vähem."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi: kaks pulka."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi: kolm pulka."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"WiFi-signaal on tugev."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Ühendatud: <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Ühendatud: <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX-i pole."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX-i on üks riba."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX-i on kaks riba."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter lubatud."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibreeriv kõlisti."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Vaikne kõlisti."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Rakendusest <xliff:g id="APP">%s</xliff:g> loobumine."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Loobusite rakendusest <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Rakenduse <xliff:g id="APP">%s</xliff:g> käivitamine."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Märguandest on loobutud."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Märguande vari."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Kiirseaded."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Kuva lukustamine."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Seaded"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Hiljutised ekraanikuvad."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Kasutaja <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WiFi on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WiFi on sisse lülitatud."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobiili <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Aku: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Lennukirežiim: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Asukoht: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Lennukirežiim on väljas."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Lennukirežiim on sees."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Lennukirežiim on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Lennukirežiim on sisse lülitatud."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth on väljas."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth on sees."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetoothi ühendatakse."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth on ühendatud."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth on sisse lülitatud."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Asukohateavitus on väljas."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Asukohateavitus on sees."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Asukohateavitus on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Asukohateavitus on sisse lülitatud."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Määratud äratus: <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Sule paneel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Rohkem aega"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Vähem aega"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Paneeli sulgemine."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Pikem aeg."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Lühem aeg."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Taskulamp on väljas."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Taskulamp on sees."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Taskulamp on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Taskulamp on sisse lülitatud."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Värvi ümberpööramine on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Värvi ümberpööramine on sisse lülitatud."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobiilside leviala on välja lülitatud."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobiilside leviala on sisse lülitatud."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ekraanikuva ülekandmine on peatatud."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ekraani heledus"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G–3G andmeside on väljalülitatud"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G andmeside on väljalülitatud"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mob. andmeside väljalülitatud"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS-i määratud asukoht"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Asukoha taotlused on aktiivsed"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Kustuta kõik teatised."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Seaded"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Märguandeseaded"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Rakenduse <xliff:g id="APP_NAME">%s</xliff:g> seaded"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekraani pööramine toimub automaatselt."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ekraan on lukustatud horisontaalsuunas."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ekraan on lukustatud vertikaalsuunas."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ekraanikuva pööramine toimub nüüd automaatselt."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ekraanikuva on nüüd lukustatud horisontaalasendisse."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ekraanikuva on nüüd lukustatud vertikaalasendisse."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Maiustusekorv"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Unistus"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobiilne andmeside"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Andmekasutus"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Järelejäänud andmemaht"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Üle limiidi"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limiit on täis – andmeside kasutamine on peatatud"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> on kasutatud"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limiit: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> hoiatus"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Teie viimane ekraanikuva ilmub siia"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Rakenduste teave"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lukusta rakendusele"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"otsing"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Otsing"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Lohistage üles: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Lohistage vasakule: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Ei mingeid katkestusi, k.a äratus"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Katkestusi pole. Pole isegi hoiatusi."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Mitte ühtegi katkestust"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Ainult prioriteetsed katkestused"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Teie järgmine äratus on <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Te ei kuule äratust <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Vähem kiireloomulised märguanded on allpool"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Avamiseks puudutage uuesti"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Lukustuse tühistamiseks pühkige üles"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefoni kasutamiseks pühkige paremale"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Kaamera kasutamiseks pühkige vasakule"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Määramata ajaks"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Puudub"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioriteet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Kõik"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Laadimine (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>, kuni seade on täis)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Kasutaja vahetamine"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Kasutaja vahetamine, praegune kasutaja: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Kuva profiil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Kasutaja lisamine"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Uus kasutaja"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Külaline"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Lisa külaline"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Eemalda külaline"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Kas soovite väljuda külastajaseansist?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Külastajaseansist väljumisel eemaldatakse kohalikud andmed."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Kas eemaldada külaline?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Seansi kõik rakendused ja andmed kustutatakse."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Eemalda"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Tere tulemast tagasi, külaline!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Üheks minutiks"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d minutiks"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Üheks tunniks"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d tunniks"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Kas soovite seansiga jätkata?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Alusta uuesti"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Jah, jätka"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Kas lisada uus kasutaja?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kui lisate uue kasutaja, siis peab ta seadistama oma ruumi.\n\nIga kasutaja saab värskendada rakendusi kõigi kasutajate jaoks."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Akusäästja on sisse lülitatud"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Vähendab jõudlust ja taustaandmeid"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Akusäästja väljalülitamine"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Alusta kohe"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Märguandeid pole"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Seadet võidakse jälgida"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profiili võidakse jälgida"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Võrku võidakse jälgida"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Seadme jälgimine"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profiili jälgimine"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Võrgu jälgimine"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ava rakendus"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Keela VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Katkesta VPN-i ühendus"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Seadet haldab:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTeie administraator võib jälgida teie seadet ja võrgutegevust, sh meile, rakendusi ja turvalisi veebisaite.\n\nLisateabe saamiseks võtke ühendust administraatoriga."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Andsite rakendusele „<xliff:g id="APPLICATION">%1$s</xliff:g>” loa seadistada VPN-i ühenduse.\n\nSee rakendus saab jälgida teie seadet ja võrgutegevust, sh meile, rakendusi ja turvalisi veebisaite."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Olete ühendatud VPN-iga („<xliff:g id="APPLICATION">%1$s</xliff:g>”).\n\nTeie VPN-i teenusepakkuja võib jälgida teie seadet ja võrgutegevust, sh meile, rakendusi ja turvalisi veebisaite."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Seda seadet haldab\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutegevust, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke ühendust administraatoriga.\n\nLisaks andsite rakendusele „<xliff:g id="APPLICATION">%2$s</xliff:g>” loa seadistada VPN-i ühendus. See rakendus võib ka jälgida teie võrgutegevust."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Seda seadet haldab\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutegevust, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke ühendust administraatoriga.\n\nSamuti olete ühendatud VPN-iga („<xliff:g id="APPLICATION">%2$s</xliff:g>”). VPN-i teenusepakkuja saab ka teie võrgutegevust jälgida."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Seda profiili haldab\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministraator saab jälgida teie seadet ja võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite.\n\nLisateabe saamiseks võtke administraatoriga ühendust."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Seda seadet haldab\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nTeie profiili haldab\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministraator saab jälgida teie seadet ja võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite.\n\nLisateabe saamiseks võtke administraatoriga ühendust."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Seda profiili haldab\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke administraatoriga ühendust.\n\nLisaks andsite rakendusele „<xliff:g id="APPLICATION">%2$s</xliff:g>” loa VPN-ühenduse seadistamiseks. Ka see rakendus saab teie võrgutoiminguid jälgida."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Seda profiili haldab\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke administraatoriga ühendust.\n\nLisaks olete ühendatud VPN-iga („<xliff:g id="APPLICATION">%2$s</xliff:g>”). Ka teie VPN-i teenusepakkuja saab teie võrgutoiminguid jälgida."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Seda seadet haldab\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nTeie profiili haldab\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke administraatoriga ühendust.\n\nLisaks andsite rakendusele „<xliff:g id="APPLICATION">%3$s</xliff:g>” loa VPN-ühenduse seadistamiseks. Ka see rakendus saab teie võrgutoiminguid jälgida."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Seda seadet haldab\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nTeie profiili haldab\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministraator saab jälgida teie võrgutoiminguid, sh meile, rakendusi ja turvalisi veebisaite. Lisateabe saamiseks võtke administraatoriga ühendust.\n\nLisaks olete ühendatud VPN-iga („<xliff:g id="APPLICATION">%3$s</xliff:g>”). Ka teie VPN-i teenusepakkuja saab teie võrgutoiminguid jälgida."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Seade jääb lukku, kuni selle käsitsi avate"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Saate märguandeid kiiremini"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Näete neid enne avamist"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Tänan, ei"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Seadistus"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> vaigistas"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-eu-rES/strings.xml b/packages/SystemUI/res/values-eu-rES/strings.xml
index 185ee30..ae83468 100644
--- a/packages/SystemUI/res/values-eu-rES/strings.xml
+++ b/packages/SystemUI/res/values-eu-rES/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Garbitu"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Kendu zerrendatik"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Aplikazioaren informazioa"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Ikusitako azken pantailak erakusten dira hemen"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Baztertu azken aplikazioak"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Aplikazio bat duela gutxi"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Atzera"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Hasiera"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menua"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Azken pantailak"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Bilatu"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefonoa"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desblokeatu"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desblokeatu"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ireki telefonoan"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ireki kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Idazketa-metodoa aldatzeko botoia."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Zoom-bateragarritasunaren botoia."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Handiagotu pantaila txikia."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi sarearen bi barra."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi sarearen hiru barra."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi sarearen seinalea osoa."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> sarera konektatuta."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> gailura konektatuta."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX gabe."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX sarearen barra bat."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX sarearen bi barra."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter gaituta."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Tonu-jotzailea dardara moduan."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Tonu-jotzailea isilik."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Baztertu <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> baztertu da."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> hasten."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Jakinarazpena baztertu da."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Jakinarazpenen panela."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Ezarpen bizkorrak."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Pantaila blokeatzeko aukera."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Ezarpenak"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Azken pantailak."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"<xliff:g id="USER">%s</xliff:g> erabiltzailea."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi konexioa desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi konexioa aktibatu egin da."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Datu mugikorrak: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateria <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Hegaldi modua <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetootha <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Uneko kokapena <xliff:g id="STATE">%s</xliff:g> da."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Hegaldi modua desaktibatuta dago."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Hegaldi modua aktibatuta dago."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Hegaldi modua desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Hegaldi modua aktibatu egin da."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth konexioa desaktibatuta dago."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth konexioa aktibatuta dago."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth bidez konektatzen ari da."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth bidez konektatuta dago."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth konexioa desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth konexioa aktibatu egin da."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Kokapena hautemateko aukera desaktibatuta dago."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Kokapena hautemateko aukera aktibatuta dago."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Kokapena hautemateko aukera desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Kokapena hautemateko aukera aktibatu egin da."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarmaren ordua: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Itxi panela"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Denbora gehiagoz"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Denbora gutxiagoz"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Itxi panela."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Denbora gehiago."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Denbora gutxiago."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Flasha desaktibatuta dago."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Flasha aktibatuta dago."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Flasha desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Flasha aktibatu egin da."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Koloreak alderantzikatzeko aukera desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Koloreak alderantzikatzeko aukera aktibatu egin da."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Konexioa partekatzeko aukera desaktibatu egin da."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Konexioa partekatzeko aukera aktibatu egin da."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Pantaila igortzeari utzi zaio."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Bistaratu distira"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G datu-konexioa desaktibatuta dago"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G datu-konexioa desaktibatuta dago"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Datu mugikorrak desaktibatuta daude"</string>
@@ -185,17 +212,21 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Kokapena GPS bidez ezarri da"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aplikazioen kokapen-eskaerak aktibo daude"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Garbitu jakinarazpen guztiak."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Ezarpenak"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Jakinarazpenen ezarpenak"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ezarpenak"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Pantaila automatikoki biratuko da."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Pantaila horizontalki blokeatuta dago."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Pantaila bertikalki blokeatuta dago."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Hemendik aurrera, pantaila automatikoki biratuko da."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Pantaila horizontalki blokeatuta dago."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Pantaila bertikalki blokeatuta dago."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Postreen kutxa"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Pantaila-babeslea"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
     <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"Hegaldi modua"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"Kargatzen: <xliff:g id="PERCENT">%%</xliff:g> <xliff:g id="NUMBER">%d</xliff:g>"</string>
     <string name="quick_settings_battery_charged_label" msgid="8865413079414246081">"Kargatuta"</string>
-    <string name="quick_settings_bluetooth_label" msgid="6304190285170721401">"Bluetootha"</string>
+    <string name="quick_settings_bluetooth_label" msgid="6304190285170721401">"Bluetooth"</string>
     <string name="quick_settings_bluetooth_multiple_devices_label" msgid="3912245565613684735">"Bluetootha (<xliff:g id="NUMBER">%d</xliff:g> gailu)"</string>
     <string name="quick_settings_bluetooth_off_label" msgid="8159652146149219937">"Bluetootha desaktibatuta"</string>
     <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"Ez dago parekatutako gailurik erabilgarri"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Datu mugikorrak"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Datuen erabilera"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Geratzen diren datuak"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Mugaren gainetik"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Mugara iritsi zara. Datuen erabilera eten egin da."</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> erabilita"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Muga: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Abisua: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Ikusitako azken pantailak erakusten dira hemen"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Aplikazioaren informazioa"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"aplikazio bakarreko modua"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"bilatu"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Bilatu"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Lerratu gora hau egiteko: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Lerratu ezkerrera hau egiteko: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Etenaldirik ez, ezta alarmenak ere"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Etenaldirik ez, ezta alarmaren bat bada ere."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Etenaldirik gabe"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Lehentasun-etenaldiak soilik"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Hurrengo alarma: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Ez duzu entzungo alarma ordu honetan: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Horren premiazkoak ez diren jakinarazpenak daude behean"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Irekitzeko, ukitu berriro"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Desblokeatzeko, pasatu hatza gorantz"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefonoa irekitzeko, pasatu hatza eskuinera."</string>
     <string name="camera_hint" msgid="5241441720959174226">"Kamera irekitzeko, pasatu hatza ezkerrera."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Mugagabea"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Bat ere ez"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Lehentasuna"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Guztiak"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Kargatzen (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> guztiz kargatu arte)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Aldatu erabiltzailea"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Aldatu erabiltzailez. <xliff:g id="CURRENT_USER_NAME">%s</xliff:g> da saioa hasita duena."</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Erakutsi profila"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Gehitu erabiltzailea"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Erabiltzaile berria"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gonbidatua"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Gehitu gonbidatua"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Kendu gonbidatua"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Gonbidatuentzako saiotik irten nahi duzu?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Gonbidatuentzako saiotik irteten bazara, datu lokalak kenduko dira."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Gonbidatua kendu nahi duzu?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Saioko aplikazio eta datu guztiak ezabatuko dira."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Kendu"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Ongi etorri berriro, gonbidatu hori!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Minutu batez"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d minutuz"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Ordubetez"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d orduz"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Saioarekin jarraitu nahi duzu?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Hasi berriro"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Bai, jarraitu"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Beste erabiltzaile bat gehitu nahi duzu?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Erabiltzaile bat gehitzen duzunean, horrek bere eremua konfiguratu beharko du.\n\nEdozein erabiltzailek egunera ditzake beste erabiltzaile guztien aplikazioak."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Bateria aurrezlea aktibatuta dago"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Errendimendua eta atzeko planoko datuak murrizten ditu"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desaktibatu bateria aurrezteko aukera"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Hasi"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ez dago jakinarazpenik"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Baliteke gailua kontrolatuta egotea"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Baliteke profila kontrolatuta egotea"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Baliteke sarea kontrolatuta egotea"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Gailuen kontrola"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profila kontrolatzeko aukera"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Sareen kontrola"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ireki aplikazioa"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Desgaitu VPN konexioa"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Deskonektatu VPN sarea"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak gailua eta sarean egiten dituzun jarduerak kontrola ditzake, mezu elektronikoak, aplikazioak eta webgune seguruak barne.\n\nInformazio gehiago lortzeko, jarri administratzailearekin harremanetan."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"VPN konexioa konfiguratzeko baimena eman diozu \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" aplikazioari.\n\nAplikazioak gailua eta sarean egiten dituzun jarduerak kontrola ditzake, mezu elektronikoak, aplikazioak eta webgune seguruak barne."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN sarera konektatuta zaude (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nVPN zerbitzu-hornitzaileak gailua eta sarean egiten dituzun jarduerak kontrola ditzake, mezu elektronikoak, aplikazioak eta webgune seguruak barne."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezu elektronikoak, aplikazioak eta webgune seguruak barne.Informazio gehiago lortzeko, jarri administratzailearekin harremanetan.\n\nGainera, VPN konexio bat ezartzeko baimena eman diozu \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" aplikazioari. Aplikazioak ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezu elektronikoak, aplikazioak eta webgune seguruak barne. Informazio gehiago lortzeko, jarri administratzailearekin harremanetan.\n\nGainera, VPN sare batera konektatuta zaude (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). VPN hornitzaileak ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Honek kudeatzen du profila:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak gailua eta sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne.\n\nInformazio gehiago lortzeko, jo administratzailearengana."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHonek kudeatzen du profila:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratzaileak gailua eta sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne.\n\nInformazio gehiago lortzeko, jo administratzailearengana."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Honek kudeatzen du profila:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne. Info. gehiago lortzeko, jo administratzailearengana.\n\nGainera, VPN konexioa konfiguratzeko \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" baimena eman duzu. Aplikazio horrek ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Honek kudeatzen du profila:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne. Info. gehiago lortzeko, jo administratzailearengana.\n\nGainera, VPN sare batera konektatuta zaude (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). VPN hornitzaileak ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHonek kudeatzen du profila:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne. Info. gehiago lortzeko, jo administratzailearengana.\n\nGainera, VPN konexioa konfiguratzeko \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" baimena eman duzu. Aplikazio horrek ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Honek kudeatzen du gailua:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHonek kudeatzen du profila:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratzaileak sarean egiten dituzun jarduerak kontrola ditzake, mezuak, aplikazioak eta webgune seguruak barne. Info. gehiago lortzeko, jo administratzailearengana.\n\nGainera, VPN sare batera konektatuta zaude (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). VPN hornitzaileak ere kontrola ditzake sarean egiten dituzun jarduerak."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Gailua blokeatuta egongo da eskuz desblokeatu arte"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Eskuratu jakinarazpenak azkarrago"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ikusi desblokeatu baino lehen"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ez, eskerrik asko"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Konfiguratu"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Audioa desaktibatu da (<xliff:g id="THIRD_PARTY">%1$s</xliff:g>)"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-fa/strings.xml b/packages/SystemUI/res/values-fa/strings.xml
index 7caba87..7130c89 100644
--- a/packages/SystemUI/res/values-fa/strings.xml
+++ b/packages/SystemUI/res/values-fa/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"پاک کردن"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"حذف از لیست"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"اطلاعات برنامه"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"صفحه‌های اخیر شما اینجا نمایان می‌شوند"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"رد کردن برنامه‌های اخیر"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 برنامه اخیر"</item>
@@ -71,7 +70,7 @@
     <string name="screenshot_saving_title" msgid="8242282144535555697">"در حال ذخیره تصویر صفحه..."</string>
     <string name="screenshot_saving_text" msgid="2419718443411738818">"تصویر صفحه ذخیره شد."</string>
     <string name="screenshot_saved_title" msgid="6461865960961414961">"تصویر صفحه گرفته شد."</string>
-    <string name="screenshot_saved_text" msgid="1152839647677558815">"برای مشاهده تصویر صفحه خود، لمس کنید."</string>
+    <string name="screenshot_saved_text" msgid="1152839647677558815">"برای مشاهده عکس صفحه‌نمایشتان، لمس کنید."</string>
     <string name="screenshot_failed_title" msgid="705781116746922771">"تصویر صفحه گرفته نشد."</string>
     <string name="screenshot_failed_text" msgid="1260203058661337274">"به دلیل فضای ذخیره‌سازی کم یا عدم اجازه برنامه یا سازمانتان، نمی‌توان از صفحه عکس گرفت."</string>
     <string name="usb_preference_title" msgid="6551050377388882787">"‏گزینه‌های انتقال فایل USB"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"برگشت"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"صفحهٔ اصلی"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"منو"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"صفحه‌های اخیر"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"جستجو"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"دوربین"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"تلفن"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"باز کردن قفل"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"بازکردن قفل"</string>
+    <string name="phone_label" msgid="2320074140205331708">"باز کردن تلفن"</string>
+    <string name="camera_label" msgid="7261107956054836961">"باز کردن دوربین"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"کلید تغییر روش ورود متن."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"دکمه بزرگنمایی سازگار."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"بزرگنمایی از صفحه‌های کوچک تا بزرگ."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"‏دو نوار برای Wi‑Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"‏سه نوار برای Wi‑Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"‏قدرت سیگنال Wi‑Fi کامل است."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"به <xliff:g id="WIFI">%s</xliff:g> متصل شد."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"به <xliff:g id="BLUETOOTH">%s</xliff:g> متصل شد."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"‏WiMAX وجود ندارد."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"‏WiMAX دارای یک نوار است."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"‏WiMAX دارای دو نوار است."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"‏TeleTypewriter فعال شد."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"زنگ لرزشی."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"زنگ بی‌صدا."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"رد کردن <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> نادیده گرفته شد."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> در حال شروع به کار است."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"اعلان ردشد."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"مجموعه اعلان."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"تنظیمات سریع."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"صفحه در حالت قفل."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"تنظیمات"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"صفحه‌های اخیر."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"کاربر <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"‏Wi-Fi خاموش شد."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"‏Wi-Fi روشن شد."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"تلفن همراه <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"باتری <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"حالت هواپیما <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"بلوتوث <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"مکان <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"حالت هواپیما خاموش است."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"حالت هواپیما روشن است."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"حالت هواپیما خاموش شد."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"حالت هواپیما روشن شد."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"بلوتوث خاموش است."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"بلوتوث روشن است."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"بلوتوث در حال اتصال است."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"بلوتوث متصل است."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"بلوتوث خاموش شد."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"بلوتوث روشن شد."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"گزارش موقعیت مکانی خاموش است."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"گزارش موقعیت مکانی روشن است."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"گزارش موقعیت مکانی خاموش شد."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"گزارش موقعیت مکانی روشن شد."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"هشدار برای <xliff:g id="TIME">%s</xliff:g> تنظیم شد."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"بستن پانل"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"زمان بیشتر"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"زمان کمتر"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"پانل را ببندید."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"زمان بیشتر."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"زمان کمتر."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"چراغ قوه خاموش است."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"چراغ قوه روشن است."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"چراغ قوه خاموش شد."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"چراغ قوه روشن شد."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"وارونگی رنگ خاموش شد."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"وارونگی رنگ روشن شد."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"نقطه اتصال دستگاه همراه خاموش شد."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"نقطه اتصال دستگاه همراه روشن شد."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"فرستادن صفحه نمایش متوقف شد."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"روشنایی نمایشگر"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"‏داده 2G-3G خاموش است"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"‏داده 4G خاموش است"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"داده شبکه سلولی خاموش است"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"‏مکان تنظیم شده توسط GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"درخواست‌های موقعیت مکانی فعال است"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"پاک کردن تمام اعلان‌ها"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"تنظیمات"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"تنظیمات اعلان"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"تنظیمات <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"صفحه به صورت خودکار می‌چرخد."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"صفحه اکنون در جهت افقی قفل است."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"صفحه اکنون در جهت عمودی قفل است."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"صفحه اکنون به صورت خودکار می‌چرخد."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"صفحه اکنون روی جهت افقی قفل شده است."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"صفحه اکنون روی جهت عمودی قفل شده است."</string>
     <string name="dessert_case" msgid="1295161776223959221">"ویترین دسر"</string>
     <string name="start_dreams" msgid="7219575858348719790">"رویاپردازی"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"اترنت"</string>
@@ -200,7 +231,7 @@
     <string name="quick_settings_bluetooth_off_label" msgid="8159652146149219937">"بلوتوث خاموش"</string>
     <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"هیچ دستگاه مرتبط شده‌ای موجود نیست"</string>
     <string name="quick_settings_brightness_label" msgid="6968372297018755815">"روشنایی"</string>
-    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"چرخش اتوماتیک"</string>
+    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"چرخش خودکار"</string>
     <string name="quick_settings_rotation_locked_label" msgid="6359205706154282377">"چرخش قفل شد"</string>
     <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"عمودی"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"افقی"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"داده‌های شبکه تلفن همراه"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"مصرف داده"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"داده‌های باقی‌مانده"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"بیش از حد مجاز"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"به حد مجاز رسیدید – استفاده از داده موقتاً متوقف شد"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> استفاده شده"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> محدودیت"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"هشدار <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"صفحه‌های اخیر شما اینجا نمایان می‌شوند"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"اطلاعات برنامه"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"قفل به برنامه"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"جستجو"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"جستجو"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"لغزاندن به بالا برای <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"لغزاندن به چپ برای <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"بدون قطع شدن، شامل هشدارها"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"بدون قطعی. حتی هشدارها قطع نمی‌شوند."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"بدون وقفه"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"فقط وقفه‌های اولویت‌دار"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"هشدار بعدی شما در ساعت <xliff:g id="ALARM_TIME">%s</xliff:g> است"</string>
@@ -265,47 +295,35 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"هشدارتان را در ساعت <xliff:g id="ALARM_TIME">%s</xliff:g> نخواهید شنید"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"اعلان‌های کمتر فوری در زیر"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"برای باز کردن دوباره لمس کنید"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"برای باز کردن قفل سریع به بالا بکشید"</string>
     <string name="phone_hint" msgid="3101468054914424646">"برای تلفن انگشت را تند به سمت چپ بکشید"</string>
     <string name="camera_hint" msgid="5241441720959174226">"برای دوربین انگشت را تند به سمت راست بکشید"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"نامحدود"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"هیچ‌کدام"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"اولویت"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"همه"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"در حال شارژ (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> تا شارژ کامل)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"تغییر کاربر"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"تعویض کاربر، کاربر کنونی <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"نمایش نمایه"</string>
     <string name="user_add_user" msgid="5110251524486079492">"افزودن کاربر"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"کاربر جدید"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"مهمان"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"افزودن مهمان"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"حذف مهمان"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"از جلسه مهمان خارج می‌شوید؟"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"خروج از جلسه مهمان، داده‌های محلی را حذف خواهد کرد."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"مهمان حذف شود؟"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"همه برنامه‌ها و داده‌های این جلسه حذف خواهد شد."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"حذف"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"مهمان گرامی، بازگشتتان را خوش آمد می‌گوییم!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"برای یک دقیقه"</item>
-    <item quantity="other" msgid="6924190729213550991">"‏برای %d دقیقه"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"برای یک ساعت"</item>
-    <item quantity="other" msgid="5408537517529822157">"‏برای %d ساعت"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"آیا می‌خواهید جلسه‌تان را ادامه دهید؟"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"شروع مجدد"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"بله، ادامه داده شود"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"کاربر جدیدی اضافه می‌کنید؟"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"وقتی کاربر جدیدی را اضافه می‌کنید آن فرد باید فضای خودش را تنظیم کند.\n\nهر کاربری می‌تواند برنامه‌ها را برای همه کاربران دیگر به‌روزرسانی کند."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ذخیره کننده باتری روشن است."</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"عملکرد و اطلاعات پس‌زمینه را کاهش می‌دهد"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"خاموش کردن ذخیره‌کننده باتری"</string>
-    <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>٪٪"</string>
+    <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
     <string name="notification_hidden_text" msgid="1135169301897151909">"محتواها پنهان هستند"</string>
     <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> شروع به ضبط هر چیزی می‌کند که در صفحه‌نمایش شما نمایش داده می‌شود."</string>
     <string name="media_projection_remember_text" msgid="3103510882172746752">"دوباره نشان داده نشود"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"اکنون شروع شود"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"اعلانی موجود نیست"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ممکن است دستگاه کنترل شود"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"شاید نمایه کنترل شود"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"ممکن است شبکه کنترل شود"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"کنترل دستگاه"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"کنترل نمایه"</string>
     <string name="monitoring_title" msgid="169206259253048106">"کنترل شبکه"</string>
-    <string name="open_app" msgid="4011771120339160755">"باز کردن برنامه"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"‏غیرفعال کردن VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"‏قطع اتصال VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند دستگاه‌ و فعالیت شبکه‌تان را کنترل کند، از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن.\n\nبرای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"‏به \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" اجازه دادید اتصال VPN را تنظیم کند.\n\nاین برنامه می‌تواند دستگاه و فعالیت شبکه‌تان را کنترل کند، از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"‏به VPN ‏(\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") وصل هستید.\n\nارائه‌دهنده سرویس VPN می‌تواند دستگاه‌ و فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"‏مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند، از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید.\n\nهمچنین، به \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" اجازه دادید تا اتصال VPN را تنظیم کند. این برنامه می‌تواند فعالیت شبکه را نیز کنترل کند."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"‏مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها، و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید.\n\nهمچنین، به VPN‏ ‎‏(\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") وصل هستید. ارائه‌دهنده سرویس VPN شما می‌تواند فعالیت شبکه را نیز کنترل کند."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"مدیریت این نمایه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه و دستگاهتان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن.\n\nبرای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nمدیریت نمایه‌تان توسط:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه و دستگاهتان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن.\n\nبرای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"‏مدیریت این نمایه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید.\n\nهمچنین به «<xliff:g id="APPLICATION">%2$s</xliff:g>» اجازه دادید اتصال VPN را تنظیم کند. این برنامه می‌تواند فعالیت شبکه را نیز کنترل کند."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"‏مدیریت این نمایه توسط:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر با سرپرستتان تماس بگیرید.\n\nهمچنین به VPN ‏(«<xliff:g id="APPLICATION">%2$s</xliff:g>») وصل هستید. ارائه‌دهنده سرویس VPN شما می‌تواند فعالیت شبکه را نیز کنترل کند."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"‏مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nمدیریت نمایه‌تان توسط:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید.\n\nهمچنین، به «<xliff:g id="APPLICATION">%3$s</xliff:g>» اجازه دادید اتصال VPN را تنظیم کند. این برنامه می‌تواند فعالیت شبکه‌ را نیز کنترل کند."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"‏مدیریت این دستگاه توسط:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nمدیریت نمایه‌تان توسط:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nسرپرستتان می‌تواند فعالیت شبکه‌تان را کنترل کند از جمله ایمیل‌ها، برنامه‌ها و وب‌سایت‌های ایمن. برای کسب اطلاعات بیشتر، با سرپرستتان تماس بگیرید.\n\nهمچنین، به VPN ‏(«<xliff:g id="APPLICATION">%3$s</xliff:g>») وصل هستید. ارائه‌دهنده سرویس VPN شما می‌تواند فعالیت شبکه را نیز کنترل کند."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"دستگاه قفل باقی می‌ماند تا زمانی که قفل آن را به صورت دستی باز کنید"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"دریافت سریع‌تر اعلان‌ها"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"قبل از باز کردن قفل آنها را مشاهده کنید"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"خیر، سپاسگزارم"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"راه‌اندازی"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> آن را بی‌صدا کرد"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-fi/strings.xml b/packages/SystemUI/res/values-fi/strings.xml
index 37c3b7d..a174237 100644
--- a/packages/SystemUI/res/values-fi/strings.xml
+++ b/packages/SystemUI/res/values-fi/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Tyhjennä"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Poista luettelosta"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Sovelluksen tiedot"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Äskettäin käytetyt ruudut näkyvät tässä"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Hylkää viimeaikaiset sovellukset"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 viimeaikainen sovellus"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Takaisin"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Aloituspainike"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Valikko"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Aikaisemmat ruudut"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Haku"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Puhelin"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Avaa lukitus"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"avaa lukitus"</string>
+    <string name="phone_label" msgid="2320074140205331708">"avaa puhelin"</string>
+    <string name="camera_label" msgid="7261107956054836961">"avaa kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Syöttötavan vaihtopainike."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Yhteensopivuuszoomaus-painike."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoomaa pienemmältä suuremmalle ruudulle."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi-signaali – kaksi palkkia."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi-signaali – kolme palkkia."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Vahva wifi-signaali."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Yhteys: <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Yhteys: <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ei WiMAX-yhteyttä."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: yksi palkki."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: kaksi palkkia."</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Tekstipuhelin käytössä."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Soittoääni: värinä."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Soittoääni: äänetön."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Hylätään <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> hylättiin."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Käynnistetään <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Ilmoitus hylätty."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Ilmoitusalue."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Pika-asetukset."</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lukitse näyttö."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"Asetukset"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Aikaisemmat ruudut."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Käyttäjä: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi otettiin käyttöön."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobiiliverkkoyhteys: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Akku: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Lentokonetila <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Sijainti <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Lentokonetila on pois päältä."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Lentokonetila on päällä."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Lentokonetila poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Lentokonetila otettiin käyttöön."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth on pois päältä."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth on päällä."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetoothia yhdistetään."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth yhdistetty."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth otettiin käyttöön."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Sijainnin ilmoittaminen on pois päältä."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Sijainnin ilmoittaminen on päällä."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Sijainnin ilmoittaminen poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Sijainnin ilmoittaminen otettiin käyttöön."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Hälytys asetettu, aika: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Sulje paneeli"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Lisää aikaa"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Vähennä aikaa"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Sulje paneeli"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Lisää aikaa."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Vähennä aikaa."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Taskulamppu on pois päältä."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Taskulamppu on päällä."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Taskulamppu poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Taskulamppu otettiin käyttöön."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Käänteiset värit poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Käänteiset värit otettiin käyttöön."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobiiliyhteyden hotspot poistettiin käytöstä."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobiiliyhteyden hotspot otettiin käyttöön."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ruudun lähetys pysäytettiin."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Näytön kirkkaus"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G–3G-tiedonsiirto ei ole käytössä"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-tiedonsiirto ei ole käytössä"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobiilitiedonsiirto ei ole käytössä"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Sijainti määritetty GPS:n avulla"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Sijaintipyynnöt aktiiviset"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Tyhjennä kaikki ilmoitukset."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Asetukset"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Ilmoitusasetukset"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Asetukset – <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ruutu kääntyy automaattisesti."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ruutu on lukittu vaakasuuntaan."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ruutu on lukittu pystysuuntaan."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ruutu kiertyy nyt automaattisesti."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ruutu on nyt lukittu vaakasuuntaan."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ruutu on nyt lukittu pystysuuntaan."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Jälkiruokavitriini"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Unelmat"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobiilitiedonsiirto"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Datakäyttö"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Käytettävissä"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Kiintiö ylitetty"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Raja saavutettu - tietojen käyttö keskeytetty"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"käytetty <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"kiintiö <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> – varoitus"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Äskettäin käytetyt ruudut näkyvät tässä"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Sovellustiedot"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lukitse sovellukseen"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"haku"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Haku"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Liu\'uta ylös ja <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Liu\'uta vasemmalle ja <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Ei keskeytyksiä tai hälytyksiä"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Ei keskeytyksiä, ei edes herätyksiä."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Ei häiriöitä"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Vain tärkeät häiriöt"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Seuraava hälytysaika on <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Et kuule hälytystä klo <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Vähemmän kiireelliset ilmoitukset ovat alla"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Avaa koskettamalla uudelleen"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Avaa lukitus pyyhkäisemällä ylös"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Avaa puhelin pyyhkäisemällä oikealle"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Avaa kamera pyyhkäisemällä oikealle"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Toistaiseksi"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ei mitään"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Tärkeät"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Kaikki"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Ladataan (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> kunnes täynnä)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Vaihda käyttäjää"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Vaihda käyttäjä (nyt <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Näytä profiili"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Lisää käyttäjä"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Uusi käyttäjä"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Vieras"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Lopetetaanko vierasistunto?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Vierasistunnon lopettaminen poistaa paikalliset tiedot."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Lisää vieras"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Poista vieras"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Poistetaaanko vieras?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Kaikki sovellukset ja tämän istunnon tiedot poistetaan."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Poista"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Tervetuloa takaisin!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Minuutiksi"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d minuutiksi"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Tunniksi"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d tunniksi"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Haluatko jatkaa istuntoa?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Aloita alusta"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Kyllä, haluan jatkaa"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Lisätäänkö uusi käyttäjä?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kun lisäät uuden käyttäjän, hänen tulee määrittää oman tilansa asetukset.\n\nKaikki käyttäjät voivat päivittää sovelluksia muille käyttäjille."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Virransäästö on käytössä"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Rajoittaa suorituskykyä ja taustatiedonsiirtoa"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Poista virransäästö käytöstä"</string>
@@ -317,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Aloita nyt"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ei ilmoituksia"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Laitetta voidaan valvoa"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profiilia saatetaan valvoa"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Verkkoa saatetaan valvoa"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Laitteiden valvonta"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profiilin valvonta"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Verkon valvonta"</string>
-    <string name="open_app" msgid="4011771120339160755">"Avaa sovellus"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Poista VPN käytöstä"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Katkaise VPN-yhteys"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Tätä laitetta hallinnoi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja saattaa tarkkailla laitteesi ja verkon toimintaa, kuten sähköposteja, sovelluksia ja turvallisia sivustoja.\n\nKysy lisätietoja järjestelmänvalvojalta."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Annoit sovellukselle \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" luvan muodostaa VPN-yhteys.\n\nTämä sovellus saattaa tarkkailla laitteesi ja verkon toimintaa, kuten sähköposteja, sovelluksia ja turvallisia sivustoja."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Sinulla on VPN-yhteys (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nVPN-palveluntarjoaja saattaa tarkkailla laitteesi ja verkon toimintaa, kuten sähköposteja, sovelluksia ja turvallisia sivustoja."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Tämän laitteen hallinnoija on \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja pystyy valvomaan toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nAnnoit sovellukselle <xliff:g id="APPLICATION">%2$s</xliff:g> luvan VPN-yhteyden määrittämiseen. Myös se pystyy valvomaan toimiasi verkossa."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Tämän laitteen hallinnoija on \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja pystyy valvomaan toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nLisäksi on muodostettu VPN-yhteys (<xliff:g id="APPLICATION">%2$s</xliff:g>). VPN-palveluntarjoaja voi myös valvoa toimiasi verkossa."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profiilisi hallinnoija: \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä.\n\nSaat lisätietoja järjestelmänvalvojalta."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Laitteen hallinnoija: \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfiilisi hallinnoija: \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä.\n\nSaat lisätietoja järjestelmänvalvojalta."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profiilin hallinnoija: \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nAnnoit sovellukselle <xliff:g id="APPLICATION">%2$s</xliff:g> luvan VPN-yhteyden määrittämiseen. Myös se voi valvoa toimiasi."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profiilisi hallinnoija: \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nKäytät VPN-yhteyttä (<xliff:g id="APPLICATION">%2$s</xliff:g>). VPN-palveluntarjoaja voi myös valvoa toimiasi."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Laitteen hallinnoija: \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfiilisi hallinnoija: \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nAnnoit sovellukselle <xliff:g id="APPLICATION">%3$s</xliff:g> luvan VPN-yhteyden määrittämiseen. Myös se voi valvoa toimiasi."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Laitteen hallinnoija: \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfiilisi hallinnoija: \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJärjestelmänvalvoja voi valvoa toimiasi verkossa, esimerkiksi sähköpostin, sovellusten ja turvallisten verkkosivustojen käyttöä. Saat lisätietoja järjestelmänvalvojalta.\n\nKäytät VPN-yhteyttä (<xliff:g id="APPLICATION">%3$s</xliff:g>). VPN-palveluntarjoaja voi myös valvoa toimiasi."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Laite pysyy lukittuna, kunnes se avataan käsin"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Näe ilmoitukset nopeammin"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Näytä ennen lukituksen avaamista"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ei kiitos"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Määritä asetukset"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Mykistänyt <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-fr-rCA/strings.xml b/packages/SystemUI/res/values-fr-rCA/strings.xml
index c8dead8..4c6e9fa 100644
--- a/packages/SystemUI/res/values-fr-rCA/strings.xml
+++ b/packages/SystemUI/res/values-fr-rCA/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Effacer"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Supprimer de la liste"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informations sur l\'application"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Vos écrans récents s\'affichent ici"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Masquer les applications récentes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 application récente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Précédent"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Domicile"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Écrans récents"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Rechercher"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Appareil photo"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Téléphone"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Déverrouiller"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"déverrouiller"</string>
+    <string name="phone_label" msgid="2320074140205331708">"Ouvrir le téléphone"</string>
+    <string name="camera_label" msgid="7261107956054836961">"Ouvrir l\'appareil photo"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Bouton \"Changer le mode de saisie\""</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Bouton \"Zoom de compatibilité\""</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom de compatibilité avec la taille de l\'écran"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Signal Wi-Fi moyen"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Signal Wi-Fi bon"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Signal Wi-Fi excellent"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Connecté à : <xliff:g id="WIFI">%s</xliff:g>"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Connecté à : <xliff:g id="BLUETOOTH">%s</xliff:g>"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Aucun signal WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Signal WiMAX : faible"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Signal WiMAX : moyen"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Téléscripteur activé"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Sonnerie en mode vibreur"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Sonnerie en mode silencieux"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Supprimer <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Application \"<xliff:g id="APP">%s</xliff:g>\" ignorée."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Lancement de <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notification masquée"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Volet des notifications"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Paramètres rapides"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Écran de verrouillage"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Paramètres"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Écrans récents."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Utilisateur : <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi désactivé"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi activé."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Signal mobile : <xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="TYPE">%2$s</xliff:g>, <xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batterie : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mode Avion : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Localisation <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Mode Avion : désactivé"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Mode Avion : activé"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Le mode Avion est désactivé."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Le mode Avion est activé."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth désactivé."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth activé."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Connexion Bluetooth en cours..."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth connecté."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth désactivé."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth activé."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Signalement de position désactivé."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Signalement de position activé."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Signalement de position désactivé."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Signalement de position activé."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarme réglée sur <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Fermer le panneau"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Plus longtemps"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Moins longtemps"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Fermer le panneau."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Plus longtemps"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Moins longtemps."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lampe de poche désactivée."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lampe de poche activée."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lampe de poche désactivée."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lampe de poche activée."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversion des couleurs désactivée."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversion des couleurs activée."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Point d\'accès mobile désactivé."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Point d\'accès mobile activé."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Diffusion d\'écran arrêtée."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Luminosité de l\'écran"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Données 2G/3G désactivées"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Données 4G désactivées"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Données cellulaire désactivées"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Position définie par GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Demandes de localisation actives"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Supprimer toutes les notifications"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Paramètres"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Paramètres de notification"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Paramètres de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"L\'écran pivote automatiquement."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"L\'écran est verrouillé en mode paysage."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"L\'écran est verrouillé en mode portrait."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"L\'écran va maintenant pivoter automatiquement."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"L\'écran est maintenant verrouillé en mode paysage."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"L\'écran est maintenant verrouillé en mode portrait."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vitrine des desserts"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Écran de veille"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Données cellulaires"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Utilisation de données"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Données restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limite dépassée"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limite atteinte : utilisation des données suspendue"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Quantité de données utilisées :<xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limite : <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Avertissement : <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Vos écrans récents s\'affichent ici"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Détails de l\'application"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"verrouiller sur l\'application"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"rechercher"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Recherche"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Faire glisser le doigt vers le haut : <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Faites glisser votre doigt vers la gauche pour <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Aucune interruption, y compris les alarmes"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Aucune interruption. Même pas pour les alarmes."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Aucune interruption"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Interruptions prioritaires seulement"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Prochaine alarme : <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Vous n\'entendrez pas votre alarme à <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notifications moins urgentes affichées ci-dessous"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Touchez à nouveau pour ouvrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Glissez vers le haut pour déverrouiller"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Balayez l\'écran vers la droite pour accéder au téléphone"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Balayez l\'écran vers la gauche pour accéder à l\'appareil photo"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indéfiniment"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Aucun"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Priorité"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Tous"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Charge en cours... (chargée à 100 % dans <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Changer d\'utilisateur"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Changer d\'utilisateur (utilisateur actuel <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Afficher le profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Ajouter un utilisateur"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nouvel utilisateur"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Invité"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Ajouter un invité"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Supprimer l\'invité"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Désirez-vous quitter la session Invité?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Si vous quittez la session Invité, les données locales seront supprimées."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Supprimer l\'invité?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Toutes les applications et les données de cette session seront supprimées."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Supprimer"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bienvenue à nouveau dans la session Invité"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Pendant une minute"</item>
-    <item quantity="other" msgid="6924190729213550991">"Pendant %d minutes"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Pendant une heure"</item>
-    <item quantity="other" msgid="5408537517529822157">"Pendant %d heures"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Voulez-vous poursuivre la session?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Recommencer"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Oui, continuer"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Ajouter un utilisateur?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Lorsque vous ajoutez un utilisateur, celui-ci doit configurer son espace.\n\nN\'importe quel utilisateur peut mettre à jour les applications pour tous les autres utilisateurs."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"La fonction Économie d\'énergie est activée"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Réduire les performances et de fond"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Désactiver l\'économiseur d\'énergie"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Commencer maintenant"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Aucune notification"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Il est possible que cet appareil soit surveillé."</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"le profil peut être contrôlé"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Le réseau peut être surveillé"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Surveillance d\'appareils"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Contrôle de profil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Surveillance réseau"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ouvrir l\'application"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Désactiver le RPV"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Déconnecter le RPV"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Cet appareil est géré par : \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre appareil et votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés.\n\nPour en savoir plus, communiquez avec votre administrateur."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Vous avez donné à « <xliff:g id="APPLICATION">%1$s</xliff:g> » l\'autorisation de configurer une connexion RPV.\n\nCette application peut surveiller votre appareil et votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Vous êtes connecté à un RPV (« <xliff:g id="APPLICATION">%1$s</xliff:g> »).\n\nVotre fournisseur de services RPV peut surveiller votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés. Pour en savoir plus à ce sujet, communiquez avec votre administrateur réseau.\n\nVous avez aussi autorisé « <xliff:g id="APPLICATION">%2$s</xliff:g> » à créer une connexion RPV. Cette application peut aussi surveiller votre activité réseau."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre activité (courriels, applications, sites Web sécurisés, etc.). Pour en savoir plus, communiquez avec votre administrateur.\n\nVous êtes également connecté à un RPV (<xliff:g id="APPLICATION">%2$s</xliff:g>). Votre fournisseur RPV peut aussi surveiller votre activité réseau."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Ce profil est géré par : \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre appareil et votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés.\n\nPour en savoir plus, communiquez avec votre administrateur."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Cet appareil est géré par : \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVotre profil est géré par : \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut surveiller l\'activité de votre appareil et votre activité réseau, y compris les courriels, les applications et les sites Web sécurisés. \n\n Pour en savoir plus, communiquez avec votre administrateur."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profil géré par : \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre activité réseau (courriels, applications et sites sécurisés). Communiquez avec votre administrateur.\n\nEn outre, vous avez autorisé <xliff:g id="APPLICATION">%2$s</xliff:g> à créer une connexion RPV. Cette application peut aussi surveiller l\'activité réseau."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profil géré par : \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller l\'acti. de votre appareil et votre act. réseau (courriels, applications et sites sécurisés). Communiquez avec votre administrateur.\n\n Vous êtes aussi connecté à un RPV (<xliff:g id="APPLICATION">%2$s</xliff:g>). Votre fournisseur de services RPV peut lui aussi surveiller votre act. réseau."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Appareil géré par : \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil géré par : \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut surveiller votre activité réseau (courriels, applications et sites sécurisés). Communiquez avec votre administrateur.\n\nEn outre, vous avez autorisé <xliff:g id="APPLICATION">%3$s</xliff:g> à créer une connexion RPV. Cette application peut aussi surveiller l\'activité réseau."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Appareil géré par : \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil géré par : \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut surveiller l\'act. de votre appareil et votre act. réseau (courriels, applications et sites sécurisés). Communiquez avec votre administrateur.\n\nVous êtes aussi connecté à un RPV (<xliff:g id="APPLICATION">%3$s</xliff:g>). Votre admin RPV peut lui aussi surveiller votre act. réseau."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"L\'appareil restera verrouillé jusqu\'à ce que vous le déverrouilliez manuellement"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Voir les notifications plus rapidement"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Afficher les notifications avant de déverrouiller l\'appareil"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Non, merci"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurer"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Mis en sourdine par <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-fr/strings.xml b/packages/SystemUI/res/values-fr/strings.xml
index 9a3b185..fc41386 100644
--- a/packages/SystemUI/res/values-fr/strings.xml
+++ b/packages/SystemUI/res/values-fr/strings.xml
@@ -19,12 +19,11 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="7164937344850004466">"IU système"</string>
+    <string name="app_label" msgid="7164937344850004466">"Interface du système"</string>
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Effacer"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Supprimer de la liste"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informations sur l\'application"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Vos écrans récents s\'affichent ici"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Masquer les applications récentes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 application récente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Retour"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Accueil"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Écrans récents"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Rechercher"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Appareil photo"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Téléphoner"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Déverrouiller"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"déverrouiller"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ouvrir le téléphone"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ouvrir l\'appareil photo"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Bouton \"Changer le mode de saisie\""</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Bouton \"Zoom de compatibilité\""</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom de compatibilité avec la taille de l\'écran"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Signal Wi-Fi moyen"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Signal Wi-Fi bon"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Signal Wi-Fi excellent"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Connecté à : <xliff:g id="WIFI">%s</xliff:g>"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Connecté à : <xliff:g id="BLUETOOTH">%s</xliff:g>"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Aucun signal WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Signal WiMAX : faible"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Signal WiMAX : moyen"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Téléscripteur activé"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Sonnerie en mode vibreur"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Sonnerie en mode silencieux"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Supprimer <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Application \"<xliff:g id="APP">%s</xliff:g>\" ignorée."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Lancement de <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notification masquée"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Volet des notifications"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Paramètres rapides"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Écran de verrouillage"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Paramètres"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Écrans récents"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Utilisateur <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi désactivé."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi activé."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Signal mobile : <xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="TYPE">%2$s</xliff:g>, <xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batterie : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mode Avion : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth : <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Localisation <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Mode Avion désactivé"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Mode Avion activé"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Le mode Avion est désactivé."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Le mode Avion est activé."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth désactivé."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth activé."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Connexion Bluetooth en cours..."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth connecté."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth désactivé."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth activé."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Mise à jour de la position désactivée."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Mise à jour de la position activée."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Mise à jour de la position désactivée."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Mise à jour de la position activée."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarme réglée sur <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Fermer le panneau"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Plus longtemps"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Moins longtemps"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Fermer le panneau"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Plus longtemps"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Moins longtemps"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lampe de poche désactivée."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lampe de poche activée."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lampe de poche désactivée."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lampe de poche activée."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversion des couleurs désactivée."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversion des couleurs activée."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Point d\'accès mobile désactivé."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Point d\'accès mobile activé."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Diffusion d\'écran interrompue."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Luminosité de l\'affichage"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Données 2G-3G désactivées"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Données 4G désactivées"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Données mobiles désactivées"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Position définie par GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Demandes de localisation actives"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Supprimer toutes les notifications"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Paramètres"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Paramètres de notification"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Paramètres de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"L\'écran pivote automatiquement."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"L\'écran est verrouillé en mode paysage."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"L\'écran est verrouillé en mode portrait."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"L\'écran pivote désormais automatiquement."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"L\'écran est désormais verrouillé en format paysage."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"L\'écran est maintenant verrouillé en format portrait."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vitrine des desserts"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Écran de veille interactif"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Données mobiles"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Consommation des données"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Données restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limite dépassée"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limite atteinte : utilisation des données suspendue"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> utilisés"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> au maximum"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Avertissement : <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Vos écrans récents s\'affichent ici"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informations sur l\'application"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"verrouiller sur l\'application"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"rechercher"</string>
@@ -259,51 +289,39 @@
     <string name="description_target_search" msgid="3091587249776033139">"Rechercher"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Faites glisser vers le haut pour <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Faites glisser vers la gauche pour <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Aucune interruption, pas même pour les alarmes"</string>
-    <string name="zen_no_interruptions" msgid="7970973750143632592">"Aucune interruption"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Interruptions prioritaires seulement"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Aucune sonnerie, pas même pour les alarmes"</string>
+    <string name="zen_no_interruptions" msgid="7970973750143632592">"Aucune sonnerie"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Sonneries prioritaires uniquement"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Prochaine alarme : <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"Prochaine alarme : <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Vous n\'entendrez pas votre alarme à <xliff:g id="ALARM_TIME">%s</xliff:g>."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notifications moins urgentes ci-dessous"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Appuyer à nouveau pour ouvrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Faire glisser pour déverrouiller"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Balayer l\'écran vers la droite pour accéder au téléphone"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Balayer l\'écran vers la gauche pour accéder à l\'appareil photo"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indéfiniment"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Aucune"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritaire"</string>
-    <string name="interruption_level_all" msgid="1330581184930945764">"Toutes"</string>
+    <string name="interruption_level_all" msgid="1330581184930945764">"Toujours"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Charge en cours… (chargé à 100 %% dans <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Changer d\'utilisateur"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Changer d\'utilisateur (utilisateur actuel : <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Afficher le profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Ajouter un utilisateur"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nouvel utilisateur"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Invité"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Ajouter un invité"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Supprimer l\'invité"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Quitter la session Invité ?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Si vous quittez la session Invité, les données locales seront supprimées."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Supprimer l\'invité ?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Toutes les applications et les données de cette session seront supprimées."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Supprimer"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bienvenue à nouveau dans la session Invité"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Pendant une minute"</item>
-    <item quantity="other" msgid="6924190729213550991">"Pendant %d minutes"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Pendant une heure"</item>
-    <item quantity="other" msgid="5408537517529822157">"Pendant %d heures"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Voulez-vous poursuivre la dernière session ?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Non, nouvelle session"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Oui, continuer"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Ajouter un utilisateur ?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Lorsque vous ajoutez un utilisateur, celui-ci doit configurer son espace.\n\nN\'importe quel utilisateur peut mettre à jour les applications pour tous les autres utilisateurs."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"L\'économiseur de batterie est activé"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Limite les performances et les données en arrière-plan."</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Désactiver l\'économiseur de batterie"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Commencer"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Aucune notification"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Il est possible que cet appareil soit surveillé."</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Le profil peut être contrôlé."</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Il est possible que le réseau soit surveillé."</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Contrôle des appareils"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Contrôle du profil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Contrôle du réseau"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ouvrir l\'application"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Désactiver le VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Déconnecter le VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut surveiller votre activité réseau, y compris les e-mails, les applications et les sites Web sécurisés.\n\nPour en savoir plus, contactez votre administrateur."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Vous avez autorisé l\'application \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" à configurer une connexion VPN.\n\nCette application peut surveiller votre activité réseau, y compris les e-mails, les applications et les sites Web sécurisés."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Vous êtes connecté à un VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nVotre fournisseur de services VPN peut surveiller votre activité réseau, y compris les e-mails, les applications et les sites Web sécurisés."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applis et sites Web sécurisés). Pour en savoir plus, contactez votre administrateur.\n\nVous avez autorisé l\'appli \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" à configurer une connexion VPN. Cette appli peut également contrôler votre activité réseau."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applications et sites sécurisés). Pour en savoir plus, contactez votre administrateur.\n\nVous êtes aussi connecté à un VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Votre fournisseur de services VPN peut également contrôler l\'activité réseau."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Ce profil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut contrôler l\'activité de votre appareil et votre activité réseau (e-mails, applications et sites sécurisés).\n\nPour en savoir plus, contactez votre administrateur."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVotre profil est géré par :\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut contrôler l\'activité de votre appareil et votre activité réseau (e-mails, applications et sites sécurisés).\n\nPour en savoir plus, contactez votre administrateur."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profil géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applications et sites sécurisés). Pour en savoir plus, contactez votre administrateur.\n\nVous avez donné à l\'appli \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" l\'autorisation de configurer une connexion VPN. Cette appli peut contrôler votre activité réseau."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Cet appareil est géré par :\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applications et sites sécurisés). Pour en savoir plus, contactez votre administrateur.\n\nVous êtes aussi connecté à un VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Votre fournisseur de services VPN peut également contrôler l\'activité réseau."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Appareil géré par :\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil géré par :\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applications et sites sécurisés). Pour en savoir plus, contactez votre admin.\n\nVous avez donné à l\'appli \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" l\'autorisation de configurer une connexion VPN. Cette appli peut contrôler votre activité réseau."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Appareil géré par :\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil géré par :\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVotre administrateur peut contrôler votre activité réseau (e-mails, applications et sites sécurisés). Pour en savoir plus, contactez votre administrateur.\n\nVous êtes aussi connecté à un VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Votre fournisseur de services VPN peut également contrôler l\'activité réseau."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"L\'appareil restera verrouillé jusqu\'à ce que vous le déverrouilliez manuellement."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Recevoir les notifications plus vite"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Afficher les notifications avant de déverrouiller l\'appareil"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Non, merci"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurer"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Son coupé par : <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-gl-rES/strings.xml b/packages/SystemUI/res/values-gl-rES/strings.xml
index 17ae0f3..c94e04f 100644
--- a/packages/SystemUI/res/values-gl-rES/strings.xml
+++ b/packages/SystemUI/res/values-gl-rES/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Borrar"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Quitar da lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Información da aplicación"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"As túas pantallas recentes aparecen aquí"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Rexeitar aplicacións recentes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicación recente"</item>
@@ -35,14 +34,14 @@
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"Notificacións"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"Queda pouca batería"</string>
     <string name="battery_low_percent_format" msgid="1077244949318261761">"<xliff:g id="NUMBER">%d%%</xliff:g> restante"</string>
-    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"Queda un <xliff:g id="NUMBER">%d%%</xliff:g>. O aforrador de batería está activado."</string>
+    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"Queda un <xliff:g id="NUMBER">%d%%</xliff:g>. O aforro de batería está activado."</string>
     <string name="invalid_charger" msgid="4549105996740522523">"Non compatible coa carga por USB.\nUtiliza só o cargador proporcionado."</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"Non se admite a carga mediante USB."</string>
     <string name="invalid_charger_text" msgid="5474997287953892710">"Utiliza soamente o cargador fornecido."</string>
     <string name="battery_low_why" msgid="4553600287639198111">"Configuración"</string>
-    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"Queres activar o aforrador de batería?"</string>
+    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"Queres activar o aforro de batería?"</string>
     <string name="battery_saver_confirmation_ok" msgid="7507968430447930257">"Activar"</string>
-    <string name="battery_saver_start_action" msgid="5576697451677486320">"Activar o aforrador de batería"</string>
+    <string name="battery_saver_start_action" msgid="5576697451677486320">"Activar o aforro de batería"</string>
     <string name="status_bar_settings_settings_button" msgid="3023889916699270224">"Configuración"</string>
     <string name="status_bar_settings_wifi_button" msgid="1733928151698311923">"Wi-Fi"</string>
     <string name="status_bar_settings_airplane" msgid="4879879698500955300">"Modo avión"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Volver"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Inicio"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Pantallas recentes"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Teléfono"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloquear"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloquear"</string>
+    <string name="phone_label" msgid="2320074140205331708">"abrir teléfono"</string>
+    <string name="camera_label" msgid="7261107956054836961">"abrir cámara"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Cambiar o botón do método de entrada."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botón de zoom de compatibilidade"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom de compatibilidade co tamaño da pantalla."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dúas barras de wifi"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tres barras de wifi"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Sinal completo de wifi"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Conectado a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Conectado a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Non hai WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Unha barra de WiMAX"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dúas barras de WiMAX"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter activado"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Timbre en vibración"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Timbre silenciado"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Rexeitar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Rexeitouse <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Iniciando <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificación rexeitada"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Sombra de notificación"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Configuración rápida"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Pantalla de bloqueo."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Configuración"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Pantallas recentes."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Usuario <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi desactivada."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi activada."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Móbil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batería <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modo avión <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Localización <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modo avión desactivado."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modo avión activado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Desactivouse o modo avión."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Activouse o modo avión."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth desactivado."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth activado."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth conectando."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth conectado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth desactivado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth activado."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Informes de localización desactivados."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Informes de localización activados."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Desactiváronse os Informes de localización."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Activáronse os Informes de localización."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarma definida para as <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Pecha o panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Máis tempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menos tempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Pechar panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Máis tempo."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menos tempo."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lanterna desactivada."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lanterna activada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Desactivouse a lanterna."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Activouse a lanterna."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Desactivouse a inversión da cor."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Activouse a inversión da cor."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Desactivouse a zona interactiva móbil."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Activouse a zona interactiva móbil."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Detívose a emisión en pantalla."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brillo de pantalla"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Os datos 2G-3G están desactivados"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Os datos 4G están desactivados"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Os datos móbiles están desactivados"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Localización establecida polo GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Solicitudes de localización activas"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Eliminar todas as notificacións."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Configuración"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Configuración das notificacións"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Configuración de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"A pantalla xirará automaticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"A pantalla está bloqueada en orientación horizontal."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"A pantalla está bloqueada en orientación vertical."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Agora a pantalla xirará automaticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Agora a pantalla está bloqueada en orientación horizontal."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Agora a pantalla está bloqueada en orientación vertical."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Caixa de sobremesa"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Protector pantalla"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Datos móbiles"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Uso de datos"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Datos restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Superouse o límite"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Límite acadado: pausouse o uso de datos"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> usados"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Límite de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advertencia <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"As túas pantallas recentes aparecen aquí"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Información da aplicación"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"bloqueo de aplicación"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"buscar"</string>
@@ -259,54 +289,42 @@
     <string name="description_target_search" msgid="3091587249776033139">"Buscar"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Pasa o dedo cara arriba para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Pasa o dedo cara a esquerda para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sen interrupcións, incluídas as alarmas"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Non hai interrupcións nin alarmas."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Sen interrupcións"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Só interrupcións de prioridade"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Só interrupcións prioritarias"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"A túa próxima alarma ten lugar ás <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"A túa próxima alarma ten lugar o <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Non escoitarás a túa alarma ás <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificacións menos urxentes abaixo"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Toca outra vez para abrir o elemento"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Pasa o dedo cara arriba para desbloquear"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Pasa o dedo cara á dereita para acceder ao teléfono"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Pasa o dedo cara á esquerda para abrir a cámara"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
-    <string name="interruption_level_none" msgid="3831278883136066646">"Nunca"</string>
+    <string name="interruption_level_none" msgid="3831278883136066646">"Ningún"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioridade"</string>
-    <string name="interruption_level_all" msgid="1330581184930945764">"Sempre"</string>
+    <string name="interruption_level_all" msgid="1330581184930945764">"Todas"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Cargando (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> para finalizar a carga)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Cambiar usuario"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Cambiar usuario, usuario actual: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostrar perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Engadir usuario"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Novo usuario"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Convidado"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Engadir invitado"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Eliminar invitado"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Queres saír da sesión de convidado?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Ao saír da sesión de convidado, eliminaranse os datos locais."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Queres eliminar o invitado?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Eliminaranse todas as aplicacións e datos desta sesión."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Eliminar"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Benvido de novo, convidado."</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Durante un minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Durante unha hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
-  </plurals>
-    <string name="battery_saver_notification_title" msgid="237918726750955859">"O aforrador de batería está activado"</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Queres continuar coa túa sesión?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Comezar de novo"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Si, continuar"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Engadir un usuario novo?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Cando engadas un usuario novo, este deberá configurar o seu espazo\n\nCalquera usuario pode actualizar as aplicacións para todos os demais usuarios."</string>
+    <string name="battery_saver_notification_title" msgid="237918726750955859">"O aforro de batería está activado"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduce o rendemento e os datos en segundo plano"</string>
-    <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desactivar o aforrador de batería"</string>
+    <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desactivar o aforro de batería"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
     <string name="notification_hidden_text" msgid="1135169301897151909">"Contido oculto"</string>
     <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> comezará a capturar todo o que apareza na túa pantalla."</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Iniciar agora"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Non hai notificacións"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"É posible que se supervise o dispositivo"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"O perfil pódese supervisar"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"É posible que se supervise a rede"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Supervisión de dispositivos"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Supervisión do perfil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Supervisión de rede"</string>
-    <string name="open_app" msgid="4011771120339160755">"Abrir aplicación"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Desactivar VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desconectar VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"O teu dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode controlar a actividade da rede e o dispositivo, incluídos os correos electrónicos, as aplicacións e os sitios web seguros.\n\nPara obter máis información, contacta co administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Outorgaches permiso a \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" para configurar unha conexión VPN.\n\nEsta aplicación pode controlar a actividade da rede e do dispositivo, incluídos os correos electrónicos, as aplicacións e os sitios web seguros."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Estás conectado a unha VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nO teu provedor de servizo de VPN pode controlar a actividade da rede e o dispositivo, incluídos os correos electrónicos, as aplicacións e os sitios web seguros."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Este dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode supervisar a actividade da túa rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, outorgaches permiso a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" para configurar unha conexión VPN. Esta aplicación tamén pode supervisar a actividade da rede."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Este dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode supervisar a actividade da túa rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, estás conectado a unha VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). O fornecedor de servizos da VPN tamén pode supervisar a actividade da rede."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Este perfil está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode supervisar o teu dispositivo e a actividade da rede e o dispositivo, incluídos os correos electrónicos, as aplicacións e os sitios web seguros.\n\nPara obter máis información, contacta co administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Este dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO teu perfil está xestionado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO teu administrador pode supervisar o teu dispositivo e a actividade da rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros.\n\nPara obter máis información, contacta co teu administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Este perfil está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode supervisar a túa actividade da rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, outorgaches permiso a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" para configurar unha conexión VPN. Esta aplicación tamén pode supervisar a actividade da rede."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Este perfil está xestionado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO teu administrador pode supervisar a túa actividade da rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, estás conectado a unha VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). O provedor de servizos VPN tamén pode supervisar a actividade da rede."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Este dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO teu perfil está xestionado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO teu administrador pode supervisar a túa actividade da rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, outorgaches permiso a \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" para configurar unha conexión VPN. Esta aplicación tamén pode supervisar a actividade da rede."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Este dispositivo está xestionado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO teu perfil está xestionado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO teu administrador pode supervisar a túa actividade da rede, incluídos os correos electrónicos, as aplicacións e os sitios web seguros. Para obter máis información, contacta co teu administrador.\n\nAdemais, estás conectado a unha VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). O provedor de servizos VPN tamén pode supervisar a actividade da rede."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"O dispositivo permanecerá bloqueado ata que o desbloquees manualmente"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Recibir notificacións máis rápido"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Consúltaas antes de desbloquear"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Non grazas"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurar"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Silenciado por <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-h650dp/config.xml b/packages/SystemUI/res/values-h650dp/config.xml
new file mode 100644
index 0000000..ee641b4
--- /dev/null
+++ b/packages/SystemUI/res/values-h650dp/config.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<resources>
+    <!-- The maximum count of notifications on Keyguard. The rest will be collapsed in an overflow
+     card. -->
+    <integer name="keyguard_max_notification_count">5</integer>
+</resources>
+
diff --git a/packages/SystemUI/res/values-h650dp/dimens.xml b/packages/SystemUI/res/values-h650dp/dimens.xml
new file mode 100644
index 0000000..fbfca46
--- /dev/null
+++ b/packages/SystemUI/res/values-h650dp/dimens.xml
@@ -0,0 +1,23 @@
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<resources>
+    <dimen name="keyguard_clock_notifications_margin_min">32dp</dimen>
+    <dimen name="keyguard_clock_notifications_margin_max">36dp</dimen>
+
+    <fraction name="keyguard_clock_y_fraction_max">32.5%</fraction>
+    <fraction name="keyguard_clock_y_fraction_min">18.5%</fraction>
+</resources>
\ No newline at end of file
diff --git a/packages/SystemUI/res/values-hdpi/dimens.xml b/packages/SystemUI/res/values-hdpi/dimens.xml
new file mode 100644
index 0000000..10b00eb
--- /dev/null
+++ b/packages/SystemUI/res/values-hdpi/dimens.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<resources>
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <fraction name="battery_button_height_fraction">10.5%</fraction>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+         fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">20%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">12%</fraction>
+
+    <dimen name="battery_margin_bottom">1px</dimen>
+</resources>
diff --git a/packages/SystemUI/res/values-hi/config.xml b/packages/SystemUI/res/values-hi/config.xml
new file mode 100644
index 0000000..000d96f
--- /dev/null
+++ b/packages/SystemUI/res/values-hi/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 से,10 से, 30 से, 60 से, 120 से"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-hi/strings.xml b/packages/SystemUI/res/values-hi/strings.xml
index b140fa6..74e4d27 100644
--- a/packages/SystemUI/res/values-hi/strings.xml
+++ b/packages/SystemUI/res/values-hi/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"साफ़ करें"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"सूची से निकालें"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"ऐप्स की जानकारी"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"आपकी हाल की स्‍क्रीन यहां दिखाई देती हैं"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"हाल ही के ऐप्स  खारिज करें"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 हाल ही का ऐप्स"</item>
@@ -73,7 +72,7 @@
     <string name="screenshot_saved_title" msgid="6461865960961414961">"स्‍क्रीनशॉट कैप्‍चर किया गया."</string>
     <string name="screenshot_saved_text" msgid="1152839647677558815">"अपना स्‍क्रीनशॉट देखने के लिए स्‍पर्श करें."</string>
     <string name="screenshot_failed_title" msgid="705781116746922771">"स्क्रीनशॉट को कैप्चर नहीं किया जा सका."</string>
-    <string name="screenshot_failed_text" msgid="1260203058661337274">"सीमित संग्रहण स्थान के कारण स्क्रीनशॉट नहीं ले सकते, या ऐप्स या आपके संगठन द्वारा ऐसा अनुमत नहीं है."</string>
+    <string name="screenshot_failed_text" msgid="1260203058661337274">"सीमित मेमोरी स्थान के कारण स्क्रीनशॉट नहीं ले सकते, या ऐप्स या आपके संगठन द्वारा ऐसा अनुमत नहीं है."</string>
     <string name="usb_preference_title" msgid="6551050377388882787">"USB फ़ाइल स्थानांतरण विकल्प"</string>
     <string name="use_mtp_button_title" msgid="4333504413563023626">"मीडिया प्लेयर के रूप में माउंट करें (MTP)"</string>
     <string name="use_ptp_button_title" msgid="7517127540301625751">"कैमरे के रूप में माउंट करें (PTP)"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"वापस जाएं"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"होम"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"मेनू"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"हाल ही की स्‍क्रीन"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"खोजें"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"कैमरा"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"फ़ोन"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"अनलॉक करें"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"अनलॉक करें"</string>
+    <string name="phone_label" msgid="2320074140205331708">"फ़ोन खोलें"</string>
+    <string name="camera_label" msgid="7261107956054836961">"कैमरा खोलें"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"इनपुट पद्धति‍ बटन स्विच करें."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"संगतता ज़ूम बटन."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"छोटी से बड़ी स्‍क्रीन पर ज़ूम करें."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi दो बार."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi तीन बार."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"पूर्ण WiFi सि‍ग्‍नल."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> से कनेक्ट किया गया."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> से कनेक्ट किया गया."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX नहीं."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX एक बार."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX दो बार."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"टेलीटाइपराइटर सक्षम."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"रिंगर कंपन."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"रिंगर मौन."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> को ख़ारिज करें."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> खा़रिज कर दिया गया."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> प्रारंभ हो रहा है."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"सूचना खारिज की गई."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"सूचना शेड."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"त्वरित सेटिंग."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"लॉक स्क्रीन."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"सेटिंग"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"हाल ही की स्‍क्रीन."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"उपयोगकर्ता <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"वाई-फ़ाई को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"वाई-फ़ाई को चालू किया गया."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"मोबाइल <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"बैटरी <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"हवाई जहाज़ मोड <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ब्लूटूथ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"स्थान <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"हवाई जहाज़ मोड बंद है."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"हवाई जहाज़ मोड चालू है."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"हवाई जहाज़ मोड को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"हवाई जहाज़ मोड को चालू किया गया."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"ब्लूटूथ बंद है."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"ब्लूटूथ चालू है."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ब्लूटूथ कनेक्‍ट हो रहा है."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"ब्लूटूथ कनेक्ट है."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ब्लूटूथ को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ब्लूटूथ को चालू किया गया."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"स्‍थान रिपोर्टिंग बंद है."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"स्‍थान रिपोर्टिंग चालू है."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"स्‍थान रिपोर्टिंग को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"स्‍थान रिपोर्टिंग को चालू किया गया."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> के लिए अलार्म सेट किया गया."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"फलक बंद करें"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"अधिक समय"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"कम समय"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"फलक बंद करें."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"अधिक समय."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"कम समय."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"फ़्लैशलाइट बंद है."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"फ़्लैशलाइट चालू है."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"फ़्लैशलाइट को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"फ़्लैशलाइट को चालू किया गया."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"रंग व्‍युत्‍क्रमण को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"रंग व्‍युत्‍क्रमण को चालू किया गया."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"मोबाइल हॉटस्‍पॉट को बंद किया गया."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"मोबाइल हॉटस्‍पॉट को चालू किया गया."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"स्‍क्रीन कास्‍ट करना रुक गया."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"स्क्रीन की चमक"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G डेटा बंद है"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G डेटा बंद है"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"सेल्युलर डेटा बंद है"</string>
@@ -185,12 +212,16 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS द्वारा सेट किया गया स्‍थान"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"स्थान अनुरोध सक्रिय"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"सभी सूचनाएं साफ़ करें."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"सेटिंग"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"सूचना सेटिंग"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> सेटिंग"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"स्‍क्रीन स्‍वचालित रूप से घूमेगी."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"स्‍क्रीन लैंडस्केप अभिविन्यास में लॉक है."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"स्‍क्रीन पोर्ट्रेट अभिविन्‍यास में लॉक है."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"स्‍क्रीन अब अपने आप घूमेगी."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"स्‍क्रीन को अब भू-दृश्य अभिविन्यास में लॉक कर दिया गया है."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"स्‍क्रीन को अब पोर्ट्रेट अभिविन्‍यास में लॉक की दिया गया है."</string>
     <string name="dessert_case" msgid="1295161776223959221">"मिठाई का डिब्बा"</string>
-    <string name="start_dreams" msgid="7219575858348719790">"दिवास्वप्न"</string>
+    <string name="start_dreams" msgid="7219575858348719790">"स्क्रीनसेवर"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ईथरनेट"</string>
     <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"हवाई जहाज़ मोड"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"चार्ज हो रही है, <xliff:g id="NUMBER">%d</xliff:g><xliff:g id="PERCENT">%%</xliff:g>"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"सेल्यूलर डेटा"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"डेटा उपयोग"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"शेष डेटा"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"सीमा से अधिक"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"सीमा पूर्ण हो गई – डेटा उपयोग रोका गया"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> उपयोग किया गया"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> सीमा"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> चेतावनी"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"आपकी हाल की स्‍क्रीन यहां दिखाई देती हैं"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"एप्‍लिकेशन जानकारी"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"ऐप्स पर लॉक करें"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"खोज"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"खोजें"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> के लिए ऊपर स्‍लाइड करें."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> के लिए बाएं स्‍लाइड करें."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"अलार्म सहित कोई बाधा नहीं है"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"कोई बाधा नहीं. यहां तक कि अलार्म भी नहीं."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"कोई अवरोध नहीं"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"केवल प्राथमिक अवरोध"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"आपका अगला अलार्म <xliff:g id="ALARM_TIME">%s</xliff:g> पर है"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"आपको <xliff:g id="ALARM_TIME">%s</xliff:g> पर अपना अलार्म सुनाई नहीं देगा"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"कम अत्यावश्यक सूचनाएं नीचे दी गई हैं"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"खोलने के लिए पुन: स्पर्श करें"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"अनलॉक करने के लिए ऊपर स्वाइप करें"</string>
     <string name="phone_hint" msgid="3101468054914424646">"फ़ोन के लिए दाएं स्वाइप करें"</string>
     <string name="camera_hint" msgid="5241441720959174226">"कैमरे के लिए बाएं स्वाइप करें"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्चित समय तक"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"कोई नहीं"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"प्राथमिकता"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"सभी"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"चार्ज हो रहा है (पूर्ण होने में <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> शेष)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"उपयोगकर्ता स्विच करें"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"उपयोगकर्ता स्विच करें, वर्तमान उपयोगकर्ता <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"प्रोफ़ाइल दिखाएं"</string>
     <string name="user_add_user" msgid="5110251524486079492">"उपयोगकर्ता जोड़ें"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"नया उपयोगकर्ता"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"अतिथि"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"अतिथि जोड़ें"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"अतिथि को निकालें"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"अतिथि सत्र से बाहर निकलना है?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"अतिथि सत्र से बाहर निकलने से स्थानीय डेटा निकल जाएगा."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"अतिथि को निकालें?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"इस सत्र के सभी ऐप्स और डेटा को हटा दिया जाएगा."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"निकालें"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"अतिथि, आपका पुन: स्वागत है!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"एक मिनट के लिए"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d मिनट के लिए"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"एक घंटे के लिए"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d घंटे के लिए"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"क्‍या आप अपना सत्र जारी रखना चाहते हैं?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"पुन: प्रारंभ करें"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"हां, जारी रखें"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"नया उपयोगकर्ता जोड़ें?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"जब आप कोई नया उपयोगकर्ता जोड़ते हैं तो उस व्यक्ति को अपना स्थान सेट करना होता है.\n\nकोई भी उपयोगकर्ता अन्य सभी उपयोगकर्ताओं के लिए ऐप्स अपडेट कर सकता है."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"बैटरी सेवर चालू है"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"निष्‍पादन और पृष्ठभूमि डेटा को कम करता है"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"बैटरी बचतकर्ता को बंद करें"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"अब प्रारंभ करें"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"कोई सूचना नहीं"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"उपकरण को मॉनीटर किया जा सकता है"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"प्रोफ़ाइल को मॉनीटर किया जा सकता है"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"नेटवर्क को मॉनीटर किया जा सकता है"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"उपकरण को मॉनीटर करना"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"प्रोफ़ाइल को मॉनीटर करना"</string>
     <string name="monitoring_title" msgid="169206259253048106">"नेटवर्क को मॉनीटर करना"</string>
-    <string name="open_app" msgid="4011771120339160755">"ऐप्स खोलें"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN अक्षम करें"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN डिस्‍कनेक्‍ट करें"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"यह उपकरण इसके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्‍यवस्‍थापक ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि की निगरानी कर सकता है.\n\nअधिक जानकारी के लिए, अपने व्‍यवस्‍थापक से संपर्क करें."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"आपने \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" को VPN कनेक्‍शन सेट करने की अनुमति दी है.\n\nयह ऐप्‍स ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपके उपकरण और नेटवर्क गतिविधि की निगरानी कर सकता है."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"आप VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") से कनेक्‍ट हैं.\n\nआपका VPN सेवा प्रदाता ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपके उपकरण और नेटवर्क गतिविधि की निगरानी कर सकता है."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"यह उपकरण इसके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्‍यवस्‍थापक ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि को मॉनीटर कर सकता है. अधिक जानकारी के लिए, अपने व्‍यवस्‍थापक से संपर्क करें.\n\nसाथ ही, आपने VPN कनेक्‍शन सेट करने के लिए \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" अनुमति भी दी है. यह ऐप्‍स नेटवर्क गतिविधि को भी मॉनीटर कर सकता है."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"यह उपकरण इसके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्‍यवस्‍थापक, ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि को मॉनीटर कर सकता है. अधिक जानकारी के लिए, अपने व्‍यवस्‍थापक से संपर्क करें.\n\nसाथ ही, आप VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") से कनेक्‍ट हैं. आपका VPN सेवा प्रदाता नेटवर्क गतिविधि को भी मॉनीटर कर सकता है."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"यह प्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्यवस्थापक ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपकी उपकरण और नेटवर्क गतिविधि को मॉनीटर कर सकता है.\n\nअधिक जानकारी के लिए, अपने व्‍यवस्‍थापक से संपर्क करें."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"यह उपकरण इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nआपकी प्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nआपका व्यवस्थापक ईमेल, ऐप्स और सुरक्षित वेबसाइटों सहित आपकी उपकरण और नेटवर्क गतिविधि को मॉनीटर कर सकता है.\n\nअधिक जानकारी के लिए, अपने व्यवस्थापक से संपर्क करें."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"यह प्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्‍यवस्‍थापक ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि को मॉनीटर करने में सक्षम है. अधिक जानकारी के लिए, अपने व्यवस्थापक से संपर्क करें.\n\nसाथ ही, आपने \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" को VPN कनेक्शन सेट करने की अनुमति दी है. यह ऐप्स नेटवर्क गतिविधि भी मॉनीटर कर सकता है."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"यह प्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपका व्यवस्थापक ईमेल, ऐप्स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि को मॉनीटर करने में सक्षम है. अधिक जानकारी के लिए, अपने व्यवस्थापक से संपर्क करें.\n\nसाथ ही, आप VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") से भी कनेक्ट हैं. आपका VPN सेवा प्रदाता नेटवर्क गतिविधि भी मॉनीटर कर सकता है."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"उपकरण इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nप्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nव्यवस्थापक ईमेल, ऐप्‍स और सुरक्षित वेबसाइटों सहित नेटवर्क गतिविधि मॉनीटर कर सकते हैं. अधिक जानकारी हेतु, व्‍यवस्‍थापक से संपर्क करें.\n\nसाथ ही, आपने \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" को VPN कनेक्शन सेट करने की अनुमति दी है. यह ऐप्स नेटवर्क गतिविधि भी मॉनीटर कर सकता है."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"यह उपकरण इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nआपकी प्रोफ़ाइल इनके द्वारा प्रबंधित है:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nआपका व्यवस्थापक ईमेल, ऐप्स और सुरक्षित वेबसाइटों सहित आपकी नेटवर्क गतिविधि को मॉनीटर करने में सक्षम है. अधिक जानकारी के लिए, अपने व्यवस्थापक से संपर्क करें.\n\nसाथ ही, आप VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") से भी कनेक्ट हैं. आपका VPN सेवा प्रदाता नेटवर्क गतिविधि भी मॉनीटर कर सकता है."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"जब तक कि आप मैन्‍युअल रूप से अनलॉक नहीं करते तब तक उपकरण लॉक रहेगा"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"सूचनाएं अधिक तेज़ी से प्राप्त करें"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"आपके द्वारा उन्हें अनलॉक किए जाने से पहले देखें"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"नहीं धन्यवाद"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"सेट करें"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> द्वारा म्यूट किया गया"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-hr/strings.xml b/packages/SystemUI/res/values-hr/strings.xml
index 1894188..bb40070 100644
--- a/packages/SystemUI/res/values-hr/strings.xml
+++ b/packages/SystemUI/res/values-hr/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Očisti"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Ukloni s popisa"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informacije o aplikaciji"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Ovdje se pojavljuju vaši nedavni zasloni"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Odbaci nedavne aplikacije"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 nedavna aplikacija"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Natrag"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Početna"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Izbornik"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Nedavni zasloni"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Pretraži"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparat"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Otključavanje"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"otključavanje"</string>
+    <string name="phone_label" msgid="2320074140205331708">"otvaranje telefona"</string>
+    <string name="camera_label" msgid="7261107956054836961">"otvaranje fotoaparata"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Gumb za promjenu načina unosa."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Gumb za kompatibilnost zumiranja."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zumiranje manjeg zaslona na veći."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi signal ima dva stupca."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi signal ima tri stupca."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi signal je pun."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Spojen na <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Spojen na <xliff:g id="BLUETOOTH">%s</xliff:g> ."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Nema signala WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX s jednim stupcem."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX s dva stupca."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter je omogućen."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibracija softvera zvona."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Softver zvona utišan."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Odbacivanje aplikacije <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Aplikacija <xliff:g id="APP">%s</xliff:g> odbačena je."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Pokretanje aplikacije <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Obavijest je odbačena."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Zaslon obavijesti."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Brze postavke."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Zaključavanje zaslona."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Postavke"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Nedavni zasloni."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Korisnik <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi isključen."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi uključen."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobitel <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Baterija – <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Način rada u zrakoplovu <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth – <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokacija <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Način rada u zrakoplovu isključen."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Način rada u zrakoplovu uključen."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Način rada u zrakoplovu isključen."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Način rada u zrakoplovu uključen."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth isključen."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth uključen."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth se povezuje."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth povezan."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth isključen."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth uključen."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Izvješćivanje o lokaciji isključeno."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Izvješćivanje o lokaciji uključeno."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Izvješćivanje o lokaciji isključeno."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Izvješćivanje o lokaciji uključeno."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Vrijeme alarma: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Zatvori ploču"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Više vremena"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Manje vremena"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Zatvaranje ploče."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Više vremena."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Manje vremena."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Svjetiljka isključena."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Svjetiljka uključena."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Svjetiljka isključena."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Svjetiljka uključena."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inverzija boja isključena."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inverzija boja uključena."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilna žarišna točka isključena."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilna žarišna točka uključena."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Emitiranje zaslona zaustavljeno."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Svjetlina zaslona"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G podaci isključeni"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G podaci isključeni"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobilni podaci isključeni"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokaciju utvrdio GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Zahtjevi za lokaciju aktivni su"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Brisanje svih obavijesti."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Postavke"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Postavke obavijesti"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Postavke aplikacije <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Zaslon će se automatski zakrenuti."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Zaslon je zaključan u pejzažnoj orijentaciji."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Zaslon je zaključan u portretnoj orijentaciji."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Zaslon će se sada automatski zakrenuti."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Zaslon je sada zaključan u vodoravnom usmjerenju."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Zaslona je sada zaključan u okomitom usmjerenju."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Izlog za slastice"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Sanjarenje"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -236,16 +267,15 @@
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"Dijeljenje veze"</string>
     <string name="quick_settings_hotspot_label" msgid="6046917934974004879">"Žarišna točka"</string>
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"Obavijesti"</string>
-    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Bljeskalica"</string>
+    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Svjetiljka"</string>
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobilni podaci"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Potrošnja podataka"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Preostali podaci"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Iznad ograničenja"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Dostignuto je ograničenje i upotreba podataka pauzirana je"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> iskorišteno"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Ograničenje od <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Upozorenje <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Ovdje se pojavljuju vaši nedavni zasloni"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informacije o aplikaciji"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"zaključaj na aplikaciju"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"pretraži"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Pretraživanje"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Kliznite prema gore za <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Kliznite lijevo za <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Bez prekida, uključujući alarme"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Bez prekida, čak ni za alarme."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Bez prekida"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Samo prioritetni prekidi"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Vaš sljedeći alarm bit će u <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Nećete čuti alarm u <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Manje hitne obavijesti pri dnu"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Dodirnite ponovo da biste otvorili"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Prijeđite prstom prema gore za otključavanje"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Prijeđite prstom udesno za telefon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Prijeđite prstom ulijevo za fotoaparat"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Neodređeno"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ništa"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Sve"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Punjenje (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> do napunjenosti)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Promjena korisnika"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Promjena korisnika, trenutačni korisnik <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Prikaz profila"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Dodavanje korisnika"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Novi korisnik"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gost"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Dodaj gosta"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Uklanjanje gosta"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Želite li napustiti gostujuću sesiju?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Zatvaranjem gostujuće sesije uklonit će se lokalni podaci."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Ukloniti gosta?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Sve aplikacije i podaci u ovoj sesiji bit će izbrisani."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Ukloni"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Dobro došli natrag, gostu!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Jednu minutu"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Jedan sat"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d h"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Želite li nastaviti sesiju?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Počni ispočetka"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Da, nastavi"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Dodati novog korisnika?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kada dodate novog korisnika, ta osoba mora postaviti vlastiti prostor.\n\nBilo koji korisnik može ažurirati aplikacije za sve ostale korisnike."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Štednja baterije je uključena"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Smanjuje količinu rada i pozadinske podatke"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Isključi uštedu baterije"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Započni sad"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nema obavijesti"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Uređaj se možda nadzire"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil se možda nadzire"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Mreža se možda nadzire"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Nadzor uređaja"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Nadzor profila"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Nadzor mreže"</string>
-    <string name="open_app" msgid="4011771120339160755">"Otvori aplikaciju"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Onemogući VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Prekini vezu s VPN-om"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vaš uređaj i aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije.\n\nZa više informacija obratite se administratoru."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Dali ste aplikaciji \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" dopuštenje za postavljanje VPN veze.\n\nTa aplikacija može pratiti vaš uređaj i aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Povezani ste s VPN-om (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nDavatelj usluge VPN-a može pratiti vaš uređaj i aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više informacija možete saznati od administratora.\n\nOsim toga, dali ste aplikaciji \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" dopuštenje za postavljanje VPN veze, pa i ona može pratiti vašu aktivnost na mreži."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više informacija možete saznati od administratora.\n\nOsim toga, povezani ste s VPN-om (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Davatelj usluge VPN-a također može pratiti vašu aktivnost na mreži."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profilom upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vaš uređaj i aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije.\n\nViše informacija možete saznati od administratora."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVašim profilom upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVaš administrator može pratiti vaš uređaj i aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije.\n\nViše informacija možete saznati od administratora."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profilom upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više informacija možete saznati od administratora.\n\nOsim toga, \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" može uspostaviti VPN vezu. Ta aplikacija također može pratiti aktivnost na mreži."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profilom upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš administrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više informacija možete saznati od administratora.\n\nOsim toga, povezani ste s VPN-om (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Davatelj usluge VPN-a također može pratiti vašu aktivnost na mreži."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVašim profilom upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVaš administrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više informacija možete saznati od administratora.\n\nOsim toga, \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" može uspostaviti VPN vezu. Ta aplikacija također može pratiti aktivnost na mreži."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Uređajem upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVašim profilom upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrator može pratiti vašu aktivnost na mreži, uključujući e-poštu, aplikacije i sigurne web-lokacije. Više možete saznati od administratora.\n\nOsim toga, povezani ste s VPN-om (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Davatelj usluge VPN-a također može pratiti aktivnost na mreži."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Uređaj će ostati zaključan dok ga ručno ne otključate"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Primajte obavijesti brže"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Pogledajte ih prije otključavanja"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ne, hvala"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Postavi"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Zvuk je isklj. treća strana <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-hu/config.xml b/packages/SystemUI/res/values-hu/config.xml
new file mode 100644
index 0000000..f5ccf75
--- /dev/null
+++ b/packages/SystemUI/res/values-hu/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1, 10, 30, 60, 120"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-hu/strings.xml b/packages/SystemUI/res/values-hu/strings.xml
index 36f7053..0c57c37 100644
--- a/packages/SystemUI/res/values-hu/strings.xml
+++ b/packages/SystemUI/res/values-hu/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Törlés"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Eltávolítás a listából"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Alkalmazásinformáció"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"A legutóbbi képernyők itt jelennek meg"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Újabb alkalmazások elvetése"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 újabb alkalmazás"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Vissza"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Főoldal"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Legutóbbi képernyők"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Keresés"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Feloldás"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"feloldás"</string>
+    <string name="phone_label" msgid="2320074140205331708">"telefon megnyitása"</string>
+    <string name="camera_label" msgid="7261107956054836961">"kamera megnyitása"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Beviteli mód váltása gomb."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Kompatibilitási zoom gomb."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Kicsinyítsen a nagyobb képernyőhöz."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi jel: két sáv."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi jel: három sáv."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi jel teljes."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Csatlakoztatva a következőhöz: <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Csatlakoztatva a következőhöz: <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Nincs WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX-jel: egy sáv."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX-jel: két sáv."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter engedélyezve."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Csengő rezeg."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Csengő néma."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"A(z) <xliff:g id="APP">%s</xliff:g> elvetése."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> eltávolítva."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"A(z) <xliff:g id="APP">%s</xliff:g> indítása."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Értesítés elvetve."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Értesítési felület."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Gyorsbeállítások."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lezárási képernyő."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Beállítások"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Legutóbbi képernyők."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Felhasználó: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi kikapcsolva."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi bekapcsolva."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Akkumulátor <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Repülős üzemmód <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Helyadatok: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Repülős üzemmód kikapcsolva."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Repülős üzemmód bekapcsolva."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Repülős üzemmód kikapcsolva."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Repülős üzemmód bekapcsolva."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth kikapcsolva."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth bekapcsolva."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth csatlakoztatása folyamatban."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth csatlakoztatva."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth kikapcsolva."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth bekapcsolva."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Tartózkodási hely jelentése kikapcsolva."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Tartózkodási hely jelentése bekapcsolva."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"A tartózkodási hely jelentése kikapcsolva."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"A tartózkodási hely jelentése bekapcsolva."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Ébresztés időpontja: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Panel bezárása"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Több idő"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Kevesebb idő"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Panel bezárása."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Több idő."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kevesebb idő."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Vaku kikapcsolva."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Vaku bekapcsolva."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Vaku kikapcsolva."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Vaku bekapcsolva."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"A színek invertálása kikapcsolva."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"A színek invertálása bekapcsolva."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"A mobil hotspot kikapcsolva."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"A mobil hotspot bekapcsolva."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"A képernyő átküldése leállítva."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"A kijelző fényereje"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"A 2G-s és 3G-s adatkapcsolat nem használható"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"A 4G-s adatkapcsolat nem használható"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"A mobiladat-kapcsolat nem használható"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"A GPS beállította a helyet"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktív helylekérések"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Minden értesítés törlése"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Beállítások"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Értesítési beállítások"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> beállításai"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"A képernyő automatikusan forogni fog."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"A képernyő zárolva van fekvő tájolásban."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"A képernyő zárolva van álló tájolásban."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"A képernyő mostantól automatikusan elfordul."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"A képernyő zárolva van fekvő tájolásban."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"A képernyő zárolva van álló tájolásban."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Álmodozás"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobiladat-kapcsolat"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Adathasználat"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Fennmaradó adatmennyiség"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Túllépte a korlátot"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Korlát elérve – adathasználat szünetel"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> felhasználva"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> korlát"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Figyelem! <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"A legutóbbi képernyők itt jelennek meg"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Az alkalmazás adatai"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"alkalmazászárolás"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"keresés"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Keresés"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"A(z) <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> művelethez csúsztassa felfelé."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"A(z) <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> művelethez csúsztassa balra."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Nincs megszakítás, még ébresztés sem"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Semmi sem zavarja meg, még a riasztások sem."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Ne zavarjon"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Csak prioritást élvező zavaró üzenetek"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"A következő ébresztés ideje: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Nem fogja hallani az ébresztést ekkor: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"A kevésbé sürgős értesítések lentebb vannak"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Érintse meg ismét a megnyitáshoz"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Húzza felfelé az ujját a feloldáshoz"</string>
     <string name="phone_hint" msgid="3101468054914424646">"A telefon eléréséhez csúsztassa ujját jobbra"</string>
     <string name="camera_hint" msgid="5241441720959174226">"A fényképezőgép eléréséhez csúsztassa ujját balra"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Határozatlan ideig"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nincs"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritást élvező"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Összes"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Töltés (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> a teljes töltöttségig)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Felhasználóváltás"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Felhasználóváltás (a jelenlegi felhasználó: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Profil megjelenítése"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Felhasználó hozzáadása"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Új felhasználó"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Vendég"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Vendég hozzáadása"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Vendég munkamenet eltávolítása"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Kilép a vendég-munkafolyamatból?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"A vendég-munkafolyamatból való kilépéssel eltávolítja a helyi adatokat."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Eltávolítja a vendég munkamenetet?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"A munkamenetben található összes alkalmazás és adat törlődni fog."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Eltávolítás"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Örülünk, hogy visszatért, vendég!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Egy percen át"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d percen át"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Egy órán át"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d órán át"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Folytatja a munkamenetet?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Újrakezdés"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Igen, folytatom"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Új felhasználó hozzáadása?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Ha új felhasználót ad hozzá, az illetőnek be kell állítania saját tárterületét.\n\nBármely felhasználó frissítheti az alkalmazásokat valamennyi felhasználó számára."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Akkumulátorkímélő mód bekapcsolva"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Csökkenti a teljesítményt és a háttéradatok használatát"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Akkumulátorkímélő mód kikapcsolása"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Indítás most"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nincs értesítés"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Lehet, hogy az eszközt figyelik"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilját felügyelhetik"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Lehet, hogy a hálózatot figyelik"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Eszközfigyelés"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilfelügyelet"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Hálózatfigyelés"</string>
-    <string name="open_app" msgid="4011771120339160755">"Alkalmazás megnyitása"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN letiltása"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN-kapcsolat bontása"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Az eszköz kezelője:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nRendszergazdája figyelheti az Ön eszköz- és hálózati tevékenységét, beleértve az e-maileket, az alkalmazásokat és a biztonságos webhelyeket.\n\nTovábbi információért forduljon rendszergazdájához."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Ön engedélyt adott a(z) „<xliff:g id="APPLICATION">%1$s</xliff:g>” alkalmazásnak VPN-kapcsolat létesítésére.\n\nAz alkalmazás figyelheti az Ön eszköz- és hálózati tevékenységét, beleértve az e-maileket, az alkalmazásokat és a biztonságos webhelyeket."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Ön egy VPN-hez kapcsolódott („<xliff:g id="APPLICATION">%1$s</xliff:g>”).\n\nVPN-szolgáltatója figyelheti az Ön eszköz- és hálózati tevékenységét, beleértve az e-maileket, az alkalmazásokat és a biztonságos webhelyeket."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Ezt az eszközt a következő felügyeli:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nA rendszergazda figyelheti a hálózati tevékenységet, beleértve az e-mailt, az alkalmazásokat és a biztonságos webhelyeket. További információért forduljon a rendszergazdához.\n\nEzenfelül engedélyt adott „<xliff:g id="APPLICATION">%2$s</xliff:g>” számára VPN-kapcsolat beállítására. Ez az alkalmazás is figyelheti a hálózati tevékenységet."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Ezt az eszközt a következő felügyeli:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nA rendszergazda figyelheti a hálózati tevékenységet, beleértve az e-mailt, az alkalmazásokat és a biztonságos webhelyeket. További információért forduljon a rendszergazdához.\n\nEzenfelül VPN-hez is csatlakozik („<xliff:g id="APPLICATION">%2$s</xliff:g>”). VPN-szolgáltatója is figyelheti hálózati tevékenységét."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profilját felügyeli:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét eszközén és a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek).\n\nTovábbi információért forduljon rendszergazdájához."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Az eszközt felügyeli:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilját felügyeli:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét eszközén és a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek).\n\nTovábbi információért forduljon rendszergazdájához."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profilját felügyeli:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek). További információért forduljon rendszergazdájához.\n\nEzenfelül engedélyt adott „<xliff:g id="APPLICATION">%2$s</xliff:g>” alkalmazásnak, hogy VPN-kapcsolatot létesítsen. Ez az alkalmazás is megfigyelheti hálózati tevékenységét."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profilját felügyeli:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek). További információért forduljon rendszergazdájához.\n\nEzenfelül VPN-hez („<xliff:g id="APPLICATION">%2$s</xliff:g>”) is kapcsolódik. VPN-szolgáltatója is megfigyelheti hálózati tevékenységét."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Az eszközt felügyeli:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilját felügyeli:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek). További információért forduljon rendszergazdájához.\n\nEzenfelül engedélyt adott „<xliff:g id="APPLICATION">%3$s</xliff:g>” alkalmazásnak, hogy VPN-kapcsolatot létesítsen. Ez az alkalmazás is megfigyelheti hálózati tevékenységét."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Az eszközt felügyeli:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilját felügyeli:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nRendszergazdája felügyelheti tevékenységét a hálózaton (pl. e-mailek, alkalmazások és biztonságos webhelyek). További információért forduljon rendszergazdájához.\n\nEzenfelül VPN-hez („<xliff:g id="APPLICATION">%3$s</xliff:g>”) is kapcsolódik. VPN-szolgáltatója is megfigyelheti hálózati tevékenységét."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Az eszköz addig zárolva marad, amíg kézileg fel nem oldja"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Gyorsabban megkaphatja az értesítéseket"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Már a képernyőzár feloldása előtt megtekintheti őket"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nem, köszönöm"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Beállítás"</string>
+    <string name="muted_by" msgid="6147073845094180001">"A(z) <xliff:g id="THIRD_PARTY">%1$s</xliff:g> elnémította"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-hy-rAM/strings.xml b/packages/SystemUI/res/values-hy-rAM/strings.xml
index 7a8e741..9901c88 100644
--- a/packages/SystemUI/res/values-hy-rAM/strings.xml
+++ b/packages/SystemUI/res/values-hy-rAM/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Մաքրել"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Հեռացնել ցանկից"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Տեղեկություններ ծրագրի մասին"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Ձեր վերջին էկրանները տեսանելի են այստեղ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Անտեսել վերջին ծրագրերը"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 նոր ծրագիր"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Հետ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Տուն"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Ցանկ"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Վերջին էկրանները"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Որոնել"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Ֆոտոխցիկ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Հեռախոս"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Ապակողպել"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ապակողպել"</string>
+    <string name="phone_label" msgid="2320074140205331708">"բացել հեռախոսը"</string>
+    <string name="camera_label" msgid="7261107956054836961">"բացել ֆոտոխցիկը"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Միացնել մուտքագրման եղանակի կոճակը:"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Համատեղելիության խոշորացման կոճակը:"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Դիտափոխել փոքրից ավելի մեծ էկրան:"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi-ի երկու գիծ:"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi-ի երեք գիծ:"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi-ի ազդանշանը լիքն է:"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Միացված է <xliff:g id="WIFI">%s</xliff:g>-ին:"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Կապակցված է <xliff:g id="BLUETOOTH">%s</xliff:g>-ին:"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX չկա:"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX-ի մեկ գիծ:"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX-ի երկու գիծ:"</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Հեռամուտքագրիչը միացված է:"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Զանգի թրթռոց:"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Զանգակը լռեցված է:"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Անտեսել <xliff:g id="APP">%s</xliff:g>-ը:"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g>-ը անտեսված է:"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Մեկնարկել <xliff:g id="APP">%s</xliff:g>-ը:"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Ծանուցումը անտեսվեց:"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Ծանուցումների վահանակ:"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Արագ կարգավորումներ:"</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Էկրանի կողպում:"</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"Կարգավորումներ"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Վերջին էկրանները:"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Օգտվող <xliff:g id="USER">%s</xliff:g>:"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>: <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>:"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi-ն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi-ը միացավ:"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Շարժական <xliff:g id="SIGNAL">%1$s</xliff:g>: <xliff:g id="TYPE">%2$s</xliff:g>: <xliff:g id="NETWORK">%3$s</xliff:g>:"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Մարտկոցը <xliff:g id="STATE">%s</xliff:g> է:"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Ինքնաթիռային ռեժիմը <xliff:g id="STATE">%s</xliff:g> է:"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth-ը <xliff:g id="STATE">%s</xliff:g> է:"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Տեղադրությունը՝ <xliff:g id="STATE">%s</xliff:g>:"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Ինքնաթիռային ռեժիմն անջատված է:"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Ինքնաթիռային ռեժիմը միացված է:"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Ինքնաթիռային ռեժիմն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Ինքնաթիռային ռեժիմը միացավ:"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth-ն անջատված է:"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth-ը միացված է:"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth-ը միանում է:"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth-ը միացված է:"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth-ն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth-ը միացավ:"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Տեղադրության ծանուցումն անջատված է:"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Տեղադրության ծանուցումը միացված է:"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Տեղադրության ծանուցումն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Տեղադրության ծանուցումը միացավ:"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Զարթուցիչը դրված է <xliff:g id="TIME">%s</xliff:g>-ին:"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Փակել վահանակը"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Ավելացնել ժամանակը"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Քչացնել ժամանակը"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Փակել վահանակը:"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Ավելացնել ժամանակը:"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Պակասեցնել ժամանակը:"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Լապտերն անջատված է:"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Լապտերը միացված է:"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Լապտերն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Լապտերը միացավ:"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Գունաշրջումն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Գունաշրջումը միացավ:"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Շարժական կապի WiFi ցրիչն անջատվեց:"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Շարժական կապի WiFi ցրիչը միացավ:"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Էկրանի հեռարձակումն ընդհատվեց:"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ցուցադրել պայծառությունը"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G տվյալների կապն անջատված է"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G տվյալների կապն անջատված է"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Բջջային տվյալներն անջատված են"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Տեղադրությունը կարգավորվել է GPS-ի կողմից"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Տեղադրության հարցումներն ակտիվ են"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Մաքրել բոլոր ծանուցումները:"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Կարգավորումներ"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Ծանուցման կարգավորումներ"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>-ի կարգավորումներ"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Էկրանը ինքնուրույն կպտտվի:"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Էկրանը կողպված է հորիզոնական դիրքավորման մեջ:"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Էկրանը կողպված է ուղղաձիգ դիրքավորմամբ:"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Էկրանն այժմ ավտոմատ կպտտվի:"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Էկրանն այժմ կողպված է հորիզոնական դիրքում:"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Էկրանն այժմ կողպված է ուղղահայաց դիրքում:"</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Ցերեկային ռեժիմ"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Բջջային տվյալներ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Տվյալների օգտագործումը"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Մնացած տվյալները"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Սահմանաչափը գերազանցված է"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Սահմանաչափը սպառվել է. տվյալների օգտագործումը դադարեցվել է"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Օգտագործված է՝ <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Սահմանաչափ՝ <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> զգուշացում"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Ձեր վերջին էկրանները տեսանելի են այստեղ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Հավելվածի մասին"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"Lock-to-app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"որոնել"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Որոնել"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Սահեցրեք վերև <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>-ի համար:"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Սահեցրեք ձախ` <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>-ի համար:"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Առանց ընդհատումների՝ ներառյալ զարթուցիչները"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Առանց ընդհատումների՝ ներառյալ զարթուցիչները:"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Առանց ընդհատումների"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Միայն կարևոր ընդհատումներ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Ձեր հաջորդ զարթուցիչի ժամն է՝ <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Դուք չեք լսի ձեր զարթուցիչը <xliff:g id="ALARM_TIME">%s</xliff:g>-ին:"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Պակաս հրատապ ծանուցումները ստորև"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Կրկին հպեք՝ բացելու համար"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Սահեցրեք վերև` ապակողպելու համար"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Հեռախոսի համար սահեցրեք աջ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Խցիկի համար սահեցրեք ձախ"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Անորոշ ժամանակով"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"-"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Կարևորություն"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Բոլորը"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Լիցքավորում (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> մինչև լրիվ լիցքավորումը)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Անջատել օգտվողին"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Փոխել օգտվողին. ներկայիս օգտվողն է՝ <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Ցույց տալ դիտարկումը"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Ավելացնել օգտվող"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Նոր օգտվող"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Հյուր"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Դուրս գա՞լ հյուրի ռեժիմից:"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Հյուրի ռեժիմից դուրս գալուց հետո ձեր տեղական տվյալները կջնջվեն:"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Հյուր ավելացնել"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Հեռացնել հյուրին"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Հեռացնե՞լ հյուրին:"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Այս աշխատաշրջանի բոլոր ծրագրերն ու տվյալները կջնջվեն:"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Հեռացնել"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Բարի վերադարձ, հյուր:"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Մեկ րոպե"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d րոպե"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Մեկ ժամ"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d ժամ"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Դուք ցանկանու՞մ եք շարունակել ձեր գործողությունը:"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Սկսել"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Այո, շարունակել"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Ավելացնե՞լ նոր պրոֆիլ:"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Երբ նոր օգտվող եք ավելացնում, նա պետք է կարգավորի իր պրոֆիլը:\n\nՑանկացած օգտվող կարող է թարմացնել հավելվածները մյուս բոլոր հաշիվների համար:"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Մարտկոցի տնտեսումը միացված է"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Նվազեցնում է ծանրաբեռնվածությունը և ֆոնային տվյալները"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Անջատել մարտկոցի տնտեսումը"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Մեկնարկել հիմա"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ծանուցումներ չկան"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Սարքը կարող է վերահսկվել"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Պրոֆիլը կարող է վերահսկվել"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Ցանցը կարող է վերահսկվել"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Սարքի մշտադիտարկում"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Պրոֆիլի վերահսկում"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Ցանցի մշտադիտարկում"</string>
-    <string name="open_app" msgid="4011771120339160755">"Բացել ծրագիրը"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Անջատել VPN-ը"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Անջատել VPN-ը"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Այս սարքը կառավարող ընկերությունն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nՁեր ադմինիստրատորը կարող է վերահսկել ձեր սարքի և ցանցի գործունեությունը, այդ թվում՝ նամակները, ծրագրերը և վստահելի կայքերը:\n\nԼրացուցիչ տեղեկությունների համար դիմեք ձեր ադմինիստրատորին:"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Դուք «<xliff:g id="APPLICATION">%1$s</xliff:g>» ծրագրին թույլ եք տվել ստեղծել VPN կապ:\n\nԱյս ծրագիրը կարող է վերահսկել ձեր սարքի և ցանցի գործունեությունը, այդ թվում՝ նամակները, ծրագրերը և վստահելի կայքերը:"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Դուք միացած եք VPN-ին («<xliff:g id="APPLICATION">%1$s</xliff:g>»):\n\nՁեզ VPN ծառայություն մատուցողը կարող է վերահսկել ձեր սարքի և ցանցի գործունեությունը, այդ թվում` նամակները, ծրագրերը և վստահելի կայքերը:"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Այս սարքը կառավարիչն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nՁեր ադմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը, այդ թվում՝ նամակները, ծրագրերը և վստահելի կայքերը: Լրացուցիչ տեղեկությունների համար դիմեք ձեր ադմինիստրատորին:\n\n Բացի այդ, դուք «<xliff:g id="APPLICATION">%2$s</xliff:g>» ծրագրին թույլատրել եք ստեղծել VPN կապ: Այդ ծրագիրը նույնպես կարող է վերահսկել ձեր ցանցային գործունեությունը:"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Այս սարքը կառավարիչն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nՁեր ադմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը, այդ թվում՝ նամակները, ծրագրերը և վստահելի կայքերը: Լրացուցիչ տեղեկությունների համար դիմեք ձեր ադմինիստրատորին:\n\nԲացի այդ, դուք միացած եք VPN-ին («<xliff:g id="APPLICATION">%2$s</xliff:g>»): Ձեզ VPN ծառայություն մատուցողը նույնպես կարող է վերահսկել ցանցային գործունեությունը:"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Այս պրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը, այդ թվում՝ նամակները, հավելվածները և վստահելի կայքերը:\n\nԼրացուցիչ տեղեկությունների համար դիմեք ձեր ադմինիստրատորին:"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Սարքի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nՊրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր սարքի և ցանցի գործունեությունը՝ նամակները, հավելվածները և վստահելի կայքերը:\n\nՀավելյալ տեղեկությունների համար դիմեք ադմինիստրատորին:"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Այս պրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը, այդ թվում՝ նամակները, հավելվածները և վստահելի կայքերը: Լրացուցիչ տեղեկությունների համար դիմեք ադմինիստրատորին:\n\nԴուք նաև «<xliff:g id="APPLICATION">%2$s</xliff:g>» հավելվածին թույլատրել եք ստեղծել VPN: Այն նույնպես կարող է վերահսկել ցանցային գործունեությունը:"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Այս պրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը՝ նամակները, հավելվածները և վստահելի կայքերը: Լրացուցիչ տեղեկությունների համար դիմեք ձեր ադմինիստրատորին:\n\nԴուք նաև միացած եք VPN-ին («<xliff:g id="APPLICATION">%2$s</xliff:g>»): VPN ծառայություն մատուցողը նույնպես կարող է վերահսկել ցանցային գործունեությունը:"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Սարքի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nՊրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը՝ նամակները, հավելվածները և վստահելի կայքերը: Լրացուցիչ տեղեկությունների համար դիմեք ադմինիստրատորին:\n\nԴուք նաև «<xliff:g id="APPLICATION">%3$s</xliff:g>»-ին թույլատրել եք ստեղծել VPN: Այն նույնպես կարող է վերահսկել ցանցային գործունեությունը:"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Սարքի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nՊրոֆիլի կառավարիչն է՝\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nԱդմինիստրատորը կարող է վերահսկել ձեր ցանցային գործունեությունը՝ նամակները, հավելվածները և վստահելի կայքերը: Այլ տեղեկությունների համար դիմեք ադմինիստրատորին:\n\nԴուք նաև միացած եք VPN-ին («<xliff:g id="APPLICATION">%3$s</xliff:g>»): VPN ծառայություն մատուցողը նույնպես կարող է վերահսկել ցանցային գործունեությունը:"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Սարքը կմնա արգելափակված՝ մինչև ձեռքով չբացեք"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Ավելի արագ ստացեք ծանուցումները"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Տեսեք դրանք մինչև ապակողպելը"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ոչ, շնորհակալություն"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Կարգավորել"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Համրեցվել է <xliff:g id="THIRD_PARTY">%1$s</xliff:g>-ի կողմից"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-in/config.xml b/packages/SystemUI/res/values-in/config.xml
new file mode 100644
index 0000000..2aa4b09
--- /dev/null
+++ b/packages/SystemUI/res/values-in/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1dtk,10dtk,30dtk,60dtk,120dtk"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-in/strings.xml b/packages/SystemUI/res/values-in/strings.xml
index 10b08e7..cb3146c 100644
--- a/packages/SystemUI/res/values-in/strings.xml
+++ b/packages/SystemUI/res/values-in/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Bersihkan"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Hapus dari daftar"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Info apl"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Layar terkini Anda muncul di sini"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Tutup aplikasi terbaru"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 apl terbaru"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Kembali"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Utama"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Layar terkini"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Telusuri"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telepon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Buka kunci"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"buka kunci"</string>
+    <string name="phone_label" msgid="2320074140205331708">"buka ponsel"</string>
+    <string name="camera_label" msgid="7261107956054836961">"buka kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Tombol beralih metode masukan."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Tombol perbesar/perkecil kompatibilitas."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Perbesar dari layar kecil ke besar."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi dua batang.aris"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi tiga baris."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Sinyal Wi-Fi penuh."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Tersambung ke <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Tersambung ke <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Tidak ada WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX satu batang."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX dua batang."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter diaktifkan."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Pendering bergetar."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Pendering senyap."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Menyingkirkan <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> disingkirkan."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Memulai <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Pemberitahuan disingkirkan."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Bayangan pemberitahuan."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Setelan cepat."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Layar kunci."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Setelan"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Layar terkini."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Pengguna <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi diaktifkan."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Seluler <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Baterai <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mode Pesawat <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokasi <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Mode pesawat nonaktif."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Mode pesawat aktif."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Mode pesawat dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Mode pesawat diaktifkan."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth nonaktif."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth aktif."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth menyambung."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth tersambung."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth diaktifkan."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Pelaporan lokasi nonaktif."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Pelaporan lokasi aktif."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Pelaporan lokasi dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Pelaporan lokasi diaktifkan."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm disetel ke <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Tutup panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Lebih lama"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Lebih cepat"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Tutup panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Lebih lama."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Lebih cepat."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Senter nonaktif."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Senter aktif."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Senter dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Senter diaktifkan."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversi warna dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversi warna diaktifkan."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Hotspot seluler dinonaktifkan."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Hotspot seluler diaktifkan."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Transmisi layar berhenti."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Kecerahan tampilan"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Data 2G-3G nonaktif"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Data 4G nonaktif"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Data seluler nonaktif"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokasi yang disetel oleh GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Permintaan lokasi aktif"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Menghapus semua pemberitahuan."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Setelan"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Setelan pemberitahuan"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> setelan"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Layar akan diputar secara otomatis."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Layar dikunci dalam orientasi lanskap."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Layar dikunci dalam orientasi potret."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Sekarang layar akan berputar secara otomatis."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Sekarang layar dikunci dalam orientasi lanskap."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Sekarang layar dikunci dalam orientasi potret."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Etalase Hidangan Penutup"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Lamunan"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Data seluler"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Penggunaan data"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Data tersisa"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Melebihi batas"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Batas terlampaui – penggunaan data dijeda"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> digunakan"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Batas <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Peringatan <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Layar terkini Anda muncul di sini"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Info Aplikasi"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"kunci ke aplikasi"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"telusuri"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Telusuri"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Geser ke atas untuk <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Geser ke kiri untuk <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Tanpa gangguan, termasuk alarm"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Tanpa gangguan, termasuk alarm."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Tidak ada interupsi"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Hanya interupsi prioritas"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Alarm Anda berikutnya pukul <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Anda tidak akan mendengar alarm pukul <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Pemberitahuan kurang darurat di bawah"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Sentuh lagi untuk membuka"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Gesek ke atas untuk membuka kunci"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Gesek ke kanan untuk menelepon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Gesek ke kiri untuk kamera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Tidak ditentukan"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Tidak ada"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritas"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Semua"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Mengisi daya (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> hingga penuh)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Beralih pengguna"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Ganti pengguna, pengguna saat ini <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Tampilkan profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Tambahkan pengguna"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Pengguna baru"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Tamu"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Tambahkan tamu"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Buang tamu"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Keluar dari sesi tamu?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Dengan keluar dari sesi tamu, Anda akan membuang data lokal."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Hapus tamu?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Semua aplikasi dan data di sesi ini akan dihapus."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Hapus"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Selamat datang kembali, tamu!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Selama satu menit"</item>
-    <item quantity="other" msgid="6924190729213550991">"Selama %d menit"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Selama satu jam"</item>
-    <item quantity="other" msgid="5408537517529822157">"Selama %d jam"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Lanjutkan sesi Anda?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Mulai"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ya, lanjutkan"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Tambahkan pengguna baru?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Saat Anda menambahkan pengguna baru, orang tersebut perlu menyiapkan ruangnya sendiri.\n\n1Pengguna mana pun dapat memperbarui aplikasi untuk semua pengguna lain."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Penghemat baterai aktif"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Mengurangi kinerja dan data latar belakang"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Nonaktifkan penghemat baterai"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Mulai sekarang"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Tidak ada pemberitahuan"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Perangkat mungkin dipantau"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil dapat dipantau"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Jaringan mungkin dipantau"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Pemantauan perangkat"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Pemantauan profil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Pemantauan jaringan"</string>
-    <string name="open_app" msgid="4011771120339160755">"Buka aplikasi"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Nonaktifkan VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Putuskan sambungan VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau perangkat serta aktivitas jaringan, termasuk email, aplikasi, dan situs web aman.\n\nUntuk informasi selengkapnya, hubungi administrator Anda."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Anda memberikan izin pada \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" untuk menyiapkan sambungan VPN.\n\nAplikasi ini dapat memantau perangkat dan aktivitas jaringan, termasuk email, aplikasi, dan situs web aman."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Anda tersambung ke VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nPenyedia layanan VPN dapat memantau perangkat dan aktivitas jaringan termasuk email, aplikasi, dan situs web aman."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan termasuk email, aplikasi, dan situs web aman. Untuk informasi selengkapnya, hubungi administrator Anda.\n\nAnda juga memberikan izin pada \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" untuk menyiapkan sambungan VPN. Aplikasi ini juga memantau aktivitas jaringan."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan termasuk email, aplikasi, dan situs web aman. Untuk informasi selengkapnya, hubungi administrator Anda.\n\nAnda juga tersambung ke VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Penyedia layanan VPN Anda dapat memantau aktivitas jaringan juga."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profil ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan dan perangkat Anda, termasuk email, aplikasi, dan situs web aman.\n\nUntuk informasi selengkapnya, hubungi administrator Anda."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil Anda dikelola oleh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan dan perangkat, termasuk email, aplikasi, dan situs web yang aman.\n\nUntuk informasi selengkapnya, hubungi administrator Anda."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profil ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan termasuk email, aplikasi, dan situs web aman. Untuk informasi selengkapnya, hubungi administrator Anda.\n\nSelain itu, Anda mengizinkan \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" menyiapkan sambungan VPN. Aplikasi juga dapat memantau aktivitas jaringan."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profil ini dikelola oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan termasuk email, aplikasi, dan situs web aman. Untuk informasi selengkapnya, hubungi administrator Anda.\n\nSelain itu, Anda tersambung ke VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Penyedia layanan VPN Anda juga dapat memantau aktivitas jaringan."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil Anda dikelola oleh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrator dapat memantau aktivitas jaringan termasuk email, aplikasi, dan situs web aman. Untuk informasi selengkapnya, hubungi administrator.\n\nAnda juga mengizinkan \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" menyiapkan sambungan VPN. Aplikasi juga dapat memantau aktivitas jaringan."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Perangkat ini dikelola oleh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil Anda dikelola oleh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrator Anda dapat memantau aktivitas jaringan termasuk email, aplikasi &amp; situs web aman. Untuk info selengkapnya, hubungi administrator.\n\nSelain itu, Anda tersambung ke VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Penyedia layanan VPN juga dapat memantau aktivitas jaringan."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Perangkat akan tetap terkunci hingga Anda membukanya secara manual"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Dapatkan pemberitahuan lebih cepat"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Lihat sebelum membuka kunci"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Tidak"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Siapkan"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Dinonaktifkan oleh <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-is-rIS/config.xml b/packages/SystemUI/res/values-is-rIS/config.xml
new file mode 100644
index 0000000..46f7456
--- /dev/null
+++ b/packages/SystemUI/res/values-is-rIS/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 sek.,10 sek., 30 sek., 60 sek.,120 sek."</string>
+</resources>
diff --git a/packages/SystemUI/res/values-is-rIS/strings.xml b/packages/SystemUI/res/values-is-rIS/strings.xml
index c2565ce..37ac042 100644
--- a/packages/SystemUI/res/values-is-rIS/strings.xml
+++ b/packages/SystemUI/res/values-is-rIS/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Hreinsa"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Fjarlægja af lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Upplýsingar um forrit"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Nýlegar skjámyndir birtast hér"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Hunsa nýleg forrit"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Eitt nýlegt forrit"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Til baka"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Heim"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Valmynd"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Nýlegar skjámyndir"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Leita"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Myndavél"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Sími"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Taka úr lás"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"taka úr lás"</string>
+    <string name="phone_label" msgid="2320074140205331708">"opna síma"</string>
+    <string name="camera_label" msgid="7261107956054836961">"opna myndavél"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Hnappur til að skipta um innsláttaraðferð."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Hnappur fyrir samhæfisaðdrátt."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Aðlaga forrit fyrir lítinn skjá að stærri skjá."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: Tvö strik."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: Þrjú strik."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Fullur Wi-Fi sendistyrkur."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Tengt við <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Tengt við <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Engin WiMAX-tenging."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: Eitt strik."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: Tvö strik."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Fjarriti virkur."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Titrar við hringingu."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Engin hringing."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Hunsa <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> vísað frá."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Ræsir <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Tilkynningu lokað."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Tilkynningasvæði."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Flýtistillingar."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lásskjár."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Stillingar"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Nýlegar skjámyndir."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Notandi: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Slökkt á Wi-Fi."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Kveikt á Wi-Fi."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Farsímagögn: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Rafhlaða: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Flugstilling: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Staðsetning: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Slökkt á flugstillingu."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Kveikt á flugstillingu."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Slökkt á flugstillingu."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Kveikt á flugstillingu."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Slökkt á Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Kveikt á Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth tengist."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth tengt."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Slökkt á Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Kveikt á Bluetooth."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Slökkt á staðsetningartilkynningum."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Kveikt á staðsetningartilkynningum."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Slökkt á staðsetningartilkynningum."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Kveikt á staðsetningartilkynningum."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Vekjari stilltur á <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Loka glugga"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Meiri tími"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Minni tími"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Loka glugga."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Meiri tími."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Minni tími."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Slökkt á vasaljósi."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Kveikt á vasaljósi."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Slökkt á vasaljósi."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Kveikt á vasaljósi."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Slökkt á umsnúningi lita."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Kveikt á umsnúningi lita."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Slökkt á farsímaaðgangsstað."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Kveikt á farsímaaðgangsstað."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Skjáútsendingu hætt."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Birtustig skjás"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Slökkt er á 2G- og 3G-gögnum"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Slökkt er á 4G-gögnum"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Slökkt er á farsímagögnum"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Staðsetning valin með GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Staðsetningarbeiðnir virkar"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Hreinsa allar tilkynningar."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Stillingar"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Tilkynningastillingar"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Stillingar fyrir <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skjárinn snýst sjálfkrafa."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skjárinn er læstur í langsniði."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skjárinn er læstur í skammsniði."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skjárinn snýst nú sjálfkrafa."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skjárinn er nú læstur á langsniði."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skjárinn er nú læstur á skammsniði."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Eftirréttaborð"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Skjávari"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -220,7 +251,7 @@
     <string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"Ekkert net"</string>
     <string name="quick_settings_wifi_off_label" msgid="7558778100843885864">"Slökkt á Wi-Fi"</string>
     <string name="quick_settings_wifi_detail_empty_text" msgid="2831702993995222755">"Engin vistuð net til staðar"</string>
-    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Útsendingarskjár"</string>
+    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Skjáútsending"</string>
     <string name="quick_settings_casting" msgid="6601710681033353316">"Sendir út"</string>
     <string name="quick_settings_cast_device_default_name" msgid="5367253104742382945">"Ónefnt tæki"</string>
     <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"Tilbúið í útsendingu"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Farsímagögn"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Gagnanotkun"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Gögn eftir"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Yfir mörkum"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Hámarki náð – gagnanotkun í bið"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> notuð"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> hámark"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> viðvörun"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Nýlegar skjámyndir birtast hér"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Forritsupplýsingar"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"forritslæsing"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"leita"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Leita"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Strjúktu upp til að <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Strjúktu til vinstri til að <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Engar truflanir, þ. á m. vekjarar"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Engar truflanir. Ekki einu sinni vekjarar."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Engin truflun"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Aðeins forgangstruflanir"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Næsti vekjari er kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Ekki mun heyrast í vekjaranum kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Minna áríðandi tilkynningar fyrir neðan"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Snertu aftur til að opna"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Strjúktu upp til að opna"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Strjúktu til hægri fyrir síma"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Strjúktu til vinstri fyrir myndavél"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Án tímatakmarkana"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Engar"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Forgangur"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Allar"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Í hleðslu (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> fram að fullri hleðslu)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Skipta um notanda"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Skipta um notanda; núverandi notandi er <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Sýna snið"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Bæta notanda við"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nýr notandi"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gestur"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Bæta gesti við"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Fjarlægja gest"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Ljúka gestalotu?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Staðbundin gögn verða fjarlægð þegar gestalotu lýkur."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Fjarlægja gest?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Öllum forritum og gögnum í þessari lotu verður eytt."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Fjarlægja"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Velkominn aftur, gestur!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Í eina mínútu"</item>
-    <item quantity="other" msgid="6924190729213550991">"Í %d mínútur"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Í eina klukkustund"</item>
-    <item quantity="other" msgid="5408537517529822157">"Í %d klukkustundir"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Viltu halda áfram með lotuna?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Byrja upp á nýtt"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Já, halda áfram"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Bæta nýjum notanda við?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Þegar þú bætir nýjum notanda við þarf sá notandi að setja upp svæðið sitt.\n\nHvaða notandi sem er getur uppfært forrit fyrir alla aðra notendur."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Kveikt er á rafhlöðusparnaði"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Dregur úr afköstum og bakgrunnsgögnum"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Slökkva á rafhlöðusparnaði"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Byrja núna"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Engar tilkynningar"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Hugsanlega er fylgst með tækjum"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Hugsanlega er fylgst með þessu sniði"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Hugsanlega er fylgst með netinu"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Tækjaeftirlit"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Fylgst með sniði"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Neteftirlit"</string>
-    <string name="open_app" msgid="4011771120339160755">"Opna forrit"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Slökkva á VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Aftengja VPN-net"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Þessu tæki er stjórnað af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nStjórnandinn getur fylgst með virkni þinni í tækinu og á netinu, þar á meðal tölvupósti, forritum og öruggum vefsvæðum.\n\nHafðu samband við stjórnandann til að fá frekari upplýsingar."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Þú veittir „<xliff:g id="APPLICATION">%1$s</xliff:g>“ heimild til að koma á VPN-tengingu.\n\nÞetta forrit getur fylgst með virkni þinni í tækinu og á netinu, þar á meðal tölvupósti, forritum og öruggum vefsvæðum."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Þú ert með tengingu við VPN-net („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nVPN-þjónustuaðilinn þinn getur fylgst með virkni þinni í tækinu og á netinu, þar á meðal tölvupósti, forritum og öruggum vefsvæðum."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Stjórnandi þessa tækis er:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nStjórnandinn getur fylgst með netvirkni þinni, þ. á m. tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við stjórnandann til að fá frekari upplýsingar.\n\nÞú veittir „<xliff:g id="APPLICATION">%2$s</xliff:g>“ einnig  heimild til að setja upp VPN-tengingu. Þetta forrit getur líka fylgst með netvirkni þinni."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Stjórnandi þessa tækis er:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nStjórnandinn getur fylgst með netvirkni þinni, þ. á m. tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við stjórnandann til að fá frekari upplýsingar.\n\nÞú ert einnig tengd(ur) VPN-neti („<xliff:g id="APPLICATION">%2$s</xliff:g>“). VPN-þjónustuaðilinn þinn getur líka fylgst með netvirkni þinni."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Þessu sniði er stjórnað af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með tækinu og netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum.\n\nHafðu samband við kerfisstjórann til að fá frekari upplýsingar."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Þessu tæki er stjórnað af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSniðinu þínu er stjórnað af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með tækinu og netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum.\n\nHafðu samband við kerfisstjórann til að fá frekari upplýsingar."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Þessu tæki er stjórnað af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við kerfisstjórann til að fá frekari upplýsingar.\n\nÞú hefur einnig gefið „<xliff:g id="APPLICATION">%2$s</xliff:g>“ heimild til að setja upp VPN-tengingu. Þetta forrit getur einnig fylgst með netnotkun."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Þessu sniði er stjórnað af:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við kerfisstjórann til að fá frekari upplýsingar.\n\nÞú ert einnig með tengingu við VPN-net („<xliff:g id="APPLICATION">%2$s</xliff:g>“). VPN-þjónustuaðilinn getur einnig fylgst með netnotkun."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Þessu tæki er stjórnað af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSniðinu þínu er stjórnað af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við kerfisstjórann til að fá frekari upplýsingar.\n\nÞú hefur einnig gefið „<xliff:g id="APPLICATION">%3$s</xliff:g>“ heimild til að setja upp VPN-tengingu. Þetta forrit getur einnig fylgst með netnotkun."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Þessu tæki er stjórnað af:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSniðinu þínu er stjórnað af:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nKerfisstjórinn þinn getur fylgst með netnotkun þinni, þar á meðal tölvupósti, forritum og öruggum vefsvæðum. Hafðu samband við kerfisstjórann til að fá frekari upplýsingar.\n\nÞú ert einnig með tengingu við VPN-net („<xliff:g id="APPLICATION">%3$s</xliff:g>“). VPN-þjónustuaðilinn getur einnig fylgst með netnotkun."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Tækið verður læst þar til þú opnar það handvirkt"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Fáðu tilkynningar hraðar"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Sjáðu þær áður en þú opnar"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nei, takk"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Setja upp"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> tók hljóðið af"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-it/config.xml b/packages/SystemUI/res/values-it/config.xml
new file mode 100644
index 0000000..f87a0a3
--- /dev/null
+++ b/packages/SystemUI/res/values-it/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 s, 10 s, 30 s, 60 s, 120 s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-it/strings.xml b/packages/SystemUI/res/values-it/strings.xml
index 9844f95..8879cfd 100644
--- a/packages/SystemUI/res/values-it/strings.xml
+++ b/packages/SystemUI/res/values-it/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Cancella"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Rimuovi dall\'elenco"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informazioni applicazione"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Le tue schermate recenti vengono visualizzate in questa sezione"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Ignora app recenti"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 app recente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Indietro"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Home"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Schermate recenti"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Cerca"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotocamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefono"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Sblocca"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"sblocca"</string>
+    <string name="phone_label" msgid="2320074140205331708">"apri telefono"</string>
+    <string name="camera_label" msgid="7261107956054836961">"apri fotocamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Pulsante per cambiare metodo di immissione."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Pulsante zoom compatibilità."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom inferiore per schermo più grande."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: due barre."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: tre barre."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Massimo segnale Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Connesso a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Connesso a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Nessun segnale WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: una barra."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: due barre."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Telescrivente abilitata."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Suoneria vibrazione."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Suoneria silenziosa."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Elimina <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> eliminata."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Avvio di <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notifica eliminata."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Area notifiche."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Impostazioni rapide."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Schermata di blocco."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Impostazioni"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Schermate recenti."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Utente <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi disattivato."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi attivato."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Cellulare: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batteria: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modalità aereo: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Posizione: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modalità aereo non attiva."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modalità aereo attiva."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Modalità aereo disattivata."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Modalità aereo attivata."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth non attivo."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth attivo."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Collegamento Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth collegato."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth disattivato."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth attivato."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Segnalazione della posizione non attiva."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Segnalazione della posizione attiva."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Segnalazione della posizione disattivata."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Segnalazione della posizione attivata."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Sveglia impostata per le <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Chiudi riquadro"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Più tempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Meno tempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Chiudi il riquadro."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Più tempo."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Meno tempo."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Torcia spenta."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Torcia accesa."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Torcia disattivata."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Torcia attivata."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversione colori disattivata."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversione colori attivata."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Hotspot mobile disattivato."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Hotspot mobile attivato."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Trasmissione dello schermo interrotta."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Luminosità dello schermo"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Dati 2G-3G disattivati"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Dati 4G disattivati"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Rete dati disattivata"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Posizione stabilita dal GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Richieste di accesso alla posizione attive"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Cancella tutte le notifiche."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Impostazioni"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Impostazioni di notifica"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Impostazioni di <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Lo schermo ruoterà automaticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Lo schermo è bloccato in orientamento orizzontale."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Lo schermo è bloccato in orientamento verticale."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ora lo schermo ruoterà automaticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ora lo schermo è bloccato nell\'orientamento orizzontale."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ora lo schermo è bloccato nell\'orientamento verticale."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vetrina di dolci"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -238,16 +269,15 @@
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"Tethering"</string>
     <string name="quick_settings_hotspot_label" msgid="6046917934974004879">"Hotspot"</string>
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"Notifiche"</string>
-    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Flashlight"</string>
+    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Torcia"</string>
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Rete dati"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Utilizzo dati"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Dati rimanenti"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limite superato"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limite raggiunto: utilizzo dei dati sospeso"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> utilizzati"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limite di <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Avviso <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Le tue schermate recenti vengono visualizzate in questa sezione"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informazioni sull\'applicazione"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"blocca su app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"cerca"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Ricerca"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Su per <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"A sinistra per <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Nessuna interruzione, allarmi compresi"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Senza interruzioni. Neanche sveglie."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Nessuna interruzione"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Solo interruzioni con priorità"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Il tuo prossimo allarme è alle ore <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Il tuo allarme non suonerà alle <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notifiche meno urgenti in basso"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Tocca di nuovo per aprire"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Scorri verso l\'alto per sbloccare"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Scorri verso destra per accedere al telefono"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Scorri verso sinistra per accedere alla fotocamera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"In modo indefinito"</string>
-    <string name="interruption_level_none" msgid="3831278883136066646">"Nessuno"</string>
+    <string name="interruption_level_none" msgid="3831278883136066646">"Nessuna"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Priorità"</string>
-    <string name="interruption_level_all" msgid="1330581184930945764">"Tutti"</string>
+    <string name="interruption_level_all" msgid="1330581184930945764">"Tutte"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"In carica (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> al termine)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Cambio utente"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Cambia utente, utente corrente <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostra profilo"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Aggiungi utente"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nuovo utente"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Ospite"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <string name="guest_exit_guest" msgid="7187359342030096885">"Rimuovi invitato"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Uscire dalla sessione Ospite?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Se esci dalla sessione Ospite verranno rimossi i dati locali."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Aggiungi ospite"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Rimuovi ospite"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Rimuovere l\'ospite?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Tutte le app e i dati di questa sessione verranno eliminati."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Rimuovi"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bentornato, ospite."</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Per un minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Per %d minuti"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Per un\'ora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Per %d ore"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vuoi continuare la sessione?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Ricomincia"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sì, continua"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Aggiungere un nuovo utente?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Il nuovo utente, una volta aggiunto, deve impostare il proprio spazio.\n\nQualsiasi utente può aggiornare le app per tutti gli altri."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Risparmio batteria attivo"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Riduce le prestazioni e i dati in background"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Disattiva risparmio energetico"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Avvia adesso"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nessuna notifica"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Il dispositivo potrebbe essere monitorato"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Il profilo potrebbe essere monitorato"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"La rete potrebbe essere monitorata"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Monitoraggio del dispositivo"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitoraggio del profilo"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Monitoraggio rete"</string>
-    <string name="open_app" msgid="4011771120339160755">"Apri app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Disattiva VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Scollega VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Questo dispositivo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIl tuo amministratore può monitorare la tua attività di rete e sul dispositivo, inclusi email, app e siti web protetti.\n\nPer ulteriori informazioni, contatta l\'amministratore."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Hai autorizzato \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" a configurare una connessione VPN.\n\nQuesta app può monitorare la tua attività di rete e sul dispositivo, inclusi email, app e siti web protetti."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Sei collegato a una rete VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nIl tuo provider di servizi VPN può monitorare la tua attività di rete e sul dispositivo, inclusi email, app e siti web protetti."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Il dispositivo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIl tuo amministratore può monitorare la tua attività di rete, inclusi email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nInoltre, hai autorizzato \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" a configurare una connessione VPN. Questa app può monitorare anche l\'attività di rete."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Il dispositivo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nIl tuo amministratore può monitorare la tua attività di rete, inclusi email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nInoltre, sei collegato a una rete VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Il tuo provider di servizi VPN può monitorare anche l\'attività di rete."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Questo profilo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'amministratore può monitorare il tuo dispositivo e l\'attività di rete, incluse email, app e siti web protetti.\n\nPer ulteriori informazioni, contatta l\'amministratore."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Questo dispositivo è gestito da:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIl tuo profilo è gestito da:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'amministratore può monitorare il tuo dispositivo e l\'attività di rete, incluse email, app e siti web protetti.\n\nPer ulteriori informazioni, contatta l\'amministratore."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Questo profilo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'amministratore può monitorare la tua attività di rete, incluse email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nHai autorizzato \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" a configurare una connessione VPN. Questa app può monitorare l\'attività di rete."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Questo profilo è gestito da:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nL\'amministratore può monitorare la tua attività di rete, incluse email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nSei collegato a una rete VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Anche il fornitore del servizio VPN può monitorare l\'attività di rete."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Il dispositivo è gestito da:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIl tuo profilo è gestito da:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'amministratore può monitorare la tua attività di rete, incluse email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nHai autorizzato \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" a configurare una connessione VPN. Questa app può monitorare l\'attività di rete."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Il dispositivo è gestito da:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIl tuo profilo è gestito da:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nL\'amministratore può monitorare l\'attività di rete, incluse email, app e siti web protetti. Per ulteriori informazioni, contatta l\'amministratore.\n\nSei collegato a una rete VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Anche il fornitore del servizio VPN può monitorare l\'attività di rete."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Il dispositivo resterà bloccato fino allo sblocco manuale"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Ricevi notifiche più velocemente"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Visualizza prima di sbloccare"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"No, grazie"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configura"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Audio disattivato da <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-iw/strings.xml b/packages/SystemUI/res/values-iw/strings.xml
index 6b58398..a59e61a 100644
--- a/packages/SystemUI/res/values-iw/strings.xml
+++ b/packages/SystemUI/res/values-iw/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"נקה"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"הסר מהרשימה"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"פרטי אפליקציה"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"המסכים האחרונים מופיעים כאן"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"סגור אפליקציות אחרונות"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"אפליקציה אחרונה אחת"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"הקודם"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"בית"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"תפריט"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"מסכים אחרונים"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"חפש"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"מצלמה"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"טלפון"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ביטול נעילה"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"בטל את הנעילה"</string>
+    <string name="phone_label" msgid="2320074140205331708">"פתח את הטלפון"</string>
+    <string name="camera_label" msgid="7261107956054836961">"פתח את המצלמה"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"לחצן החלפת שיטת קלט."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"לחצן מרחק מתצוגה של תאימות."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"שנה מרחק מתצוגה של מסך קטן לגדול יותר."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"‏שני פסים של Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"‏שלושה פסים של Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"‏אות ה-Wi-Fi מלא."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"מחובר אל <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"מחובר אל <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"‏ללא WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"‏פס אחד של WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"‏שני פסים של WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"‏TeleTypewriter מופעל"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"צלצול ורטט."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"צלצול שקט."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"סגור את <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> נדחה."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"מפעיל את <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"הודעה נדחתה."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"לוח הודעות."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"הגדרות מהירות."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"מסך נעילה."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"הגדרות"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"מסכים אחרונים."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"משתמש <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>‏. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"‏Wifi כבוי."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"‏Wifi מופעל."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"נייד <xliff:g id="SIGNAL">%1$s</xliff:g>.‏ <xliff:g id="TYPE">%2$s</xliff:g>.‏ <xliff:g id="NETWORK">%3$s</xliff:g>.‏"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"סוללה <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"מצב טיסה <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"‏Bluetooth ‏<xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"המיקום <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"מצב טיסה כבוי."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"מצב טיסה מופעל."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"מצב טיסה נכבה."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"מצב טיסה הופעל."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"‏Bluetooth כבוי."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"‏Bluetooth מופעל."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"‏Bluetooth מתחבר."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"‏Bluetooth מחובר."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"‏Bluetooth נכבה."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"‏Bluetooth הופעל."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"דיווח מיקום כבוי."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"דיווח מיקום מופעל."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"דיווח מיקום נכבה."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"דיווח מיקום הופעל."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"ההתראה נקבעה ל-<xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"סגור חלונית"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"יותר זמן"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"פחות זמן"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"סגור לוח."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"יותר זמן."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"פחות זמן."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"הפנס כבוי."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"הפנס מופעל."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"הפנס נכבה."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"הפנס הופעל."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"היפוך צבעים כבוי."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"היפוך צבעים מופעל."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"נקודה לשיתוף אינטרנט בנייד כבויה."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"נקודה לשיתוף אינטרנט בנייד מופעלת."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"העברת המסך הופסקה."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"בהירות תצוגה"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"‏נתונים בחיבור 2G-3G כובו"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"‏נתונים בחיבור 4G כובו"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"נתונים בחיבור סלולרי כובו"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"‏מיקום מוגדר על ידי GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"בקשות מיקום פעילות"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"נקה את כל ההתראות."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"הגדרות"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"הגדרות עבור הודעות"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"הגדרות <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"המסך יסתובב באופן אוטומטי."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"המסך נעול כעת לרוחב."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"המסך נעול כעת לאורך."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"המסך יסתובב כעת באופן אוטומטי."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"המסך נעול כעת לרוחב."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"המסך נעול כעת לאורך."</string>
     <string name="dessert_case" msgid="1295161776223959221">"מזנון קינוחים"</string>
     <string name="start_dreams" msgid="7219575858348719790">"חלום בהקיץ"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"נתונים סלולריים"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"שימוש בנתונים"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"מכסת נתונים נותרת"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"חריגה מההגבלה"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"הגעת למגבלה - השימוש בנתונים הושהה"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> בשימוש"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"הגבלה של <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"אזהרה - <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"המסכים האחרונים מופיעים כאן"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"מידע על האפליקציה"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"נעל לאפליקציה"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"חפש"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"חיפוש"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"הסט למעלה כדי להציג <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"הסט שמאלה כדי להציג <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ללא הפרעות, כולל התראות"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ללא הפרעות. גם לא התראות."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"ללא הפרעות"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"רק הפרעות בעדיפות גבוהה"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ההתראה הבאה שלך היא ב-<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"לא תשמע את ההתראה שלך ב-<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"הודעות בדחיפות נמוכה יותר בהמשך"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"גע שוב כדי לפתוח"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"החלק מעלה כדי לבטל את הנעילה"</string>
     <string name="phone_hint" msgid="3101468054914424646">"החלק ימינה להפעלת הטלפון"</string>
     <string name="camera_hint" msgid="5241441720959174226">"החלק ימינה להפעלת המצלמה"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"ללא הגבלה"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ללא"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"עדיפות"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"הכל"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"טוען (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> עד לסיום)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"החלפת משתמש"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"החלף משתמש. המשתמש הנוכחי הוא <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"הצג פרופיל"</string>
     <string name="user_add_user" msgid="5110251524486079492">"הוסף משתמש"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"משתמש חדש"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"אורח"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"הוסף אורח"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"הסר אורח"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"האם לצאת מהפעלת האורח?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"יציאה מהפעלת האורח תסיר נתונים מקומיים."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"להסיר אורח?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"כל האפליקציות והנתונים בפעילות זו באתר יימחקו."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"הסר"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"ברוך שובך, אורח!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"למשך דקה אחת"</item>
-    <item quantity="other" msgid="6924190729213550991">"‏למשך %d דקות"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"למשך שעה אחת"</item>
-    <item quantity="other" msgid="5408537517529822157">"‏למשך %d שעות"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"האם ברצונך להמשיך בפעילות באתר?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"התחל מחדש"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"כן, המשך"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"האם להוסיף משתמש חדש?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"בעת הוספת משתמש חדש, על משתמש זה להגדיר את השטח שלו.\n\nכל משתמש יכול לעדכן אפליקציות עבור כל המשתמשים האחרים."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"תכונת \'חיסכון בסוללה\' פועלת"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"מפחית את הביצועים ונתונים ברקע"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"כבה את החיסכון בסוללה"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"התחל כעת"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"אין הודעות"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ייתכן שהמכשיר נמצא במעקב"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ייתכן שהפרופיל נתון למעקב"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"ייתכן שהרשת נמצאת במעקב"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"מעקב אחר מכשיר"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"מעקב אחר פרופיל"</string>
     <string name="monitoring_title" msgid="169206259253048106">"מעקב אחר פעילות ברשת"</string>
-    <string name="open_app" msgid="4011771120339160755">"פתח את האפליקציה"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"‏השבת VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"‏נתק את ה-VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"המכשיר הזה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת שלך יכול לעקוב אחר המכשיר והפעילות שלך ברשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים.\n\nלמידע נוסף, צור קשר עם מנהל המערכת."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"‏נתת ל-\"<xliff:g id="APPLICATION">%1$s</xliff:g>\" הרשאה להגדרת חיבור VPN‏‏.\n\nהאפליקציה הזו יכולה לעקוב אחר המכשיר והפעילות שלך ברשת, כולל הודעות דוא\"ל, אפליקציות, ואתרים מאובטחים."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"‏אתה מחובר ל-VPN ‏‏(\"<xliff:g id="APPLICATION">%1$s</xliff:g>\")‏‏.\n\nספק שירות ה-VPN שלך יכול לעקוב אחר המכשיר והפעילות שלך ברשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"‏מכשיר זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת שלך יכול לעקוב אחר הפעילות שלך ברשת, כולל הודעות דוא\"ל, אפליקציות, ואתרים מאובטחים. למידע נוסף, צור קשר עם מנהל המערכת שלך.\n\nכמו כן, נתת ל-\"<xliff:g id="APPLICATION">%2$s</xliff:g>\" הרשאה להגדרת חיבור VPN. גם אפליקציה זו יכולה לעקוב אחר הפעילות שלך ברשת."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"‏מכשיר זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת שלך יכול לעקוב אחר הפעילות שלך ברשת, כולל הודעות דוא\"ל, אפליקציות, ואתרים מאובטחים. למידע נוסף, צור קשר עם מנהל המערכת שלך.\n\nכמו כן, אתה מחובר ל-VPN ‏‏(\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). גם ספק שירות ה-VPN שלך יכול לעקוב אחר הפעילות שלך ברשת."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"פרופיל זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים.\n\nלמידע נוסף, פנה למנהל מערכת."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"מכשיר זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nהפרופיל שלך מנוהל על ידי:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים.\n\nלמידע נוסף, פנה למנהל מערכת."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"‏פרופיל זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים. למידע נוסף, פנה למנהל מערכת.\n\n בנוסף, הענקת הרשאת \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" כדי להגדיר חיבור VPN. אפליקציה זו יכולה גם לעקוב אחר פעילות הרשת."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"‏פרופיל זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים. למידע נוסף, פנה למנהל מערכת.\n\nבנוסף, אתה מחובר אל VPN ‏(\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). גם ספק השירות של VPN יכול לעקוב אחר פעילות הרשת."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"‏מכשיר זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nהפרופיל שלך מנוהל על ידי:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים. למידע נוסף, פנה למנהל מערכת.\n\nבנוסף, הענקת הרשאת \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" כדי להגדיר חיבור VPN. אפליקציה זו יכולה גם לעקוב אחר פעילות הרשת."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"‏מכשיר זה מנוהל על ידי:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nהפרופיל שלך מנוהל על ידי:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nמנהל המערכת יכול לעקוב אחר פעילות המכשיר והרשת, כולל הודעות דוא\"ל, אפליקציות ואתרים מאובטחים. למידע נוסף, פנה למנהל מערכת.\n\nבנוסף, אתה מחובר אל VPN‏ (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). גם ספק השירות של VPN יכול לעקוב אחר פעילות הרשת."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"המכשיר יישאר נעול עד שתבטל את נעילתו באופן ידני"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"קבל התראות מהר יותר"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"צפה בהן לפני שתבטל נעילה"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"לא, תודה"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"הגדר"</string>
+    <string name="muted_by" msgid="6147073845094180001">"הושתק על ידי <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ja/strings.xml b/packages/SystemUI/res/values-ja/strings.xml
index fadc94f..2d92684 100644
--- a/packages/SystemUI/res/values-ja/strings.xml
+++ b/packages/SystemUI/res/values-ja/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"通知を消去"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"リストから削除"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"アプリ情報"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"ここに最近の画面が表示されます"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"最近使ったアプリをクリア"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"最近使ったアプリ: 1"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"戻る"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"ホーム"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"メニュー"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"最近の画面"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"検索"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"カメラ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"電話"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ロック解除"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ロック解除"</string>
+    <string name="phone_label" msgid="2320074140205331708">"電話を起動"</string>
+    <string name="camera_label" msgid="7261107956054836961">"カメラを起動"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"入力方法の切り替えボタン。"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"互換ズームボタン。"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"小さい画面から大きい画面に拡大。"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fiレベル2"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fiレベル3"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi電波フル"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>に接続しました。"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>に接続しました。"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX電波状態:圏外"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX電波状態:レベル1"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX電波状態:レベル2"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"テレタイプライターが有効です。"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"バイブレーション着信。"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"マナーモード着信。"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>を削除します。"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g>は削除されました。"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>を開始しています。"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"通知が削除されました。"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"通知シェード"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"クイック設定"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ロック画面"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"設定"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"最近の画面。"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ユーザー: <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>、<xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-FiをOFFにしました。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-FiをONにしました。"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"モバイル: <xliff:g id="SIGNAL">%1$s</xliff:g>、<xliff:g id="TYPE">%2$s</xliff:g>、<xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"電池<xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"機内モード<xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"現在地: <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"機内モードがOFFです。"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"機内モードがONです。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"機内モードをOFFにしました。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"機内モードをONにしました。"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"BluetoothがOFFです。"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"BluetoothがONです。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetoothに接続しています。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetoothに接続しました。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"BluetoothをOFFにしました。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"BluetoothをONにしました。"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"現在地送信機能がOFFです。"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"現在地送信機能がONです。"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"現在地送信機能をOFFにしました。"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"現在地送信機能をONにしました。"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"アラームは<xliff:g id="TIME">%s</xliff:g>に設定されています。"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"パネルを閉じる"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"長くする"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"短くする"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"パネルを閉じます。"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"長くします。"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"短くします。"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ライトがOFFです。"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ライトがONです。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ライトをOFFにしました。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ライトをONにしました。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"色反転をOFFにしました。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"色反転をONにしました。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"モバイルアクセスポイントをOFFにしました。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"モバイルアクセスポイントをONにしました。"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"画面のキャストが停止しました。"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ディスプレイの明るさ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G~3Gデータが無効になりました"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4Gデータが無効になりました"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"モバイルデータが無効になりました"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPSにより現在地が設定されました"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"現在地リクエストがアクティブ"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"通知をすべて消去。"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"設定"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"通知設定"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>の設定"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"画面は自動的に回転します。"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"画面は横向きにロックされています。"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"画面は縦向きにロックされています。"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"画面が自動的に回転します。"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"画面を横向きにロックしました。"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"画面を縦向きにロックしました。"</string>
     <string name="dessert_case" msgid="1295161776223959221">"デザートケース"</string>
     <string name="start_dreams" msgid="7219575858348719790">"スクリーンセーバー"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"イーサネット"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"モバイルデータ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"データ使用量"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"残りのデータ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"上限オーバー"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"上限に達しました – データの利用は一時停止"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g>使用中"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"上限: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"警告: 上限は<xliff:g id="DATA_LIMIT">%s</xliff:g>です"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"ここに最近の画面が表示されます"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"アプリ情報"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"アプリロック"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"検索"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"検索します"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"上にスライドして<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>を行います。"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"左にスライドして<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>を行います。"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"サイレント(アラームなど)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"サイレント(アラームも鳴りません)"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"サイレント"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"重要な通知のみ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"次のアラームは<xliff:g id="ALARM_TIME">%s</xliff:g>です"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g>のアラームは鳴りません"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"緊急度の低い通知を下に表示"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"開くにはもう一度タップしてください"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"ロック解除するには上にスワイプしてください"</string>
     <string name="phone_hint" msgid="3101468054914424646">"右にスワイプして電話を表示"</string>
     <string name="camera_hint" msgid="5241441720959174226">"左にスワイプしてカメラを表示"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"制限なし"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"なし"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"重要"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"すべて"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"充電中(フル充電まで<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ユーザーを切り替える"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ユーザーを切り替える、現在のユーザーは<xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"プロフィールを表示"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ユーザーを追加"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"新しいユーザー"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"ゲスト"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"ゲストを追加"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"ゲストを削除"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ゲストセッションを終了しますか?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"ゲストセッションを終了すると、ローカルデータが削除されます。"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"ゲストを削除しますか?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"このセッションでのアプリとデータはすべて削除されます。"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"削除"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"おかえりなさい、ゲストさん"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1分"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d分"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1時間"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d時間"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"セッションを続行しますか?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"最初から再生"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"次へ進む"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"新しいユーザーを追加しますか?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"新しいユーザーを追加したら、そのユーザーは自分のスペースをセットアップする必要があります。\n\nすべてのユーザーは他のユーザーに代わってアプリを更新できます。"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"バッテリーセーバーがON"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"パフォーマンスとバックグラウンドデータを制限します"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"バッテリーセーバーをOFFにします"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"今すぐ開始"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"通知はありません"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"端末が監視されている可能性があります"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"プロフィールが監視されている可能性があります"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"ネットワークが監視されている可能性があります"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"端末の監視"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"プロフィールの監視"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ネットワーク監視"</string>
-    <string name="open_app" msgid="4011771120339160755">"アプリを開く"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPNを無効にする"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPNを切断"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"この端末は<xliff:g id="ORGANIZATION">%1$s</xliff:g>によって管理されています。\n\n\n管理者はあなたの端末やネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。\n\n詳しくは管理者にお問い合わせください。"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"「<xliff:g id="APPLICATION">%1$s</xliff:g>」にVPN接続のセットアップを許可しました。\n\nこのアプリはあなたの端末やネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN(「<xliff:g id="APPLICATION">%1$s</xliff:g>」)に接続しています。\n\nVPNサービスプロバイダはあなたの端末やネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"この端末は<xliff:g id="ORGANIZATION">%1$s</xliff:g>によって管理されています。\n\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、「<xliff:g id="APPLICATION">%2$s</xliff:g>」にVPN接続のセットアップを許可しています。このアプリもネットワークアクティビティを監視できます。"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"この端末は<xliff:g id="ORGANIZATION">%1$s</xliff:g>によって管理されています。\n\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、VPN(「<xliff:g id="APPLICATION">%2$s</xliff:g>」)に接続しています。VPNサービスプロバイダーもネットワークアクティビティを監視できます。"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"このプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n管理者はあなたの端末やネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。\n\n詳しくは管理者にお問い合わせください。"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"この端末は次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nあなたのプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n管理者はあなたの端末やネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。\n\n詳しくは管理者にお問い合わせください。"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"このプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、VPN接続を設定する権限を「<xliff:g id="APPLICATION">%2$s</xliff:g>」に付与しているため、このアプリもネットワークアクティビティを監視できます。"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"このプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、VPN(「<xliff:g id="APPLICATION">%2$s</xliff:g>」)に接続しているため、VPNサービスプロバイダもネットワークアクティビティを監視できます。"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"この端末は次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nあなたのプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、VPN接続を設定する権限を「<xliff:g id="APPLICATION">%3$s</xliff:g>」に付与しているため、このアプリもネットワークアクティビティを監視できます。"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"この端末は次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nあなたのプロフィールは次の組織によって管理されています。\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n管理者はあなたのネットワークアクティビティ(メール、アプリ、保護されたウェブサイトなど)を監視できます。詳しくは管理者にお問い合わせください。\n\nまた、VPN(「<xliff:g id="APPLICATION">%3$s</xliff:g>」)に接続しているため、VPNサービスプロバイダもネットワークアクティビティを監視できます。"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"手動でロックを解除するまでロックされたままとなります"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"通知をすばやく確認できます"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ロックを解除する前にご確認ください"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"キャンセル"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"設定"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g>によりミュートになっています"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ka-rGE/strings.xml b/packages/SystemUI/res/values-ka-rGE/strings.xml
index 86d6116..039cdd0 100644
--- a/packages/SystemUI/res/values-ka-rGE/strings.xml
+++ b/packages/SystemUI/res/values-ka-rGE/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"გასუფთავება"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"სიიდან ამოშლა"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"აპის შესახებ"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"თქვენი ბოლო ეკრანები აქ გამოჩნდება"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"ბოლო აპების გაუქმება"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ბოლო აპი"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"უკან"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"საწყისი"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"მენიუ"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"ბოლო ეკრანები"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ძიება"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"კამერა"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ტელეფონი"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"განბლოკვა"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"განბლოკვა"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ტელეფონის გახსნა"</string>
+    <string name="camera_label" msgid="7261107956054836961">"კამერის გახსნა"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"შეყვანის მეთოდის გადართვის ღილაკი."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"თავსებადი მასშტაბირების ღილაკი."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"შეცვალეთ პატარა ეკრანი უფრო დიდით."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi სიგნალი ორ ზოლზეა."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi სამი ზოლი."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi სიგნალი სრულია."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"დაკავშირებულია <xliff:g id="WIFI">%s</xliff:g>-თან."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"დაკავშირებულია <xliff:g id="BLUETOOTH">%s</xliff:g>-თან."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX არ არის."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ერთი სვეტი."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX-ის ორი ზოლი."</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"ტელეტაიპი ჩართულია."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"ვიბრაციის რეჟიმი."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"უხმო რეჟიმი."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>-ის უგულებელყოფა."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ამოშლილია სიიდან."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> იწყება."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"შეტყობინება წაიშალა."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"შეტყობინებების ფარდა"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"სწრაფი პარამეტრები"</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ეკრანის დაბლოკვა."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"პარამეტრები"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"ბოლო ეკრანები."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"მომხმარებელი: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi გამორთულია."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi ჩართულია."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"მობილურის <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ელემენტი: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"თვითმფრინავის რეჟიმი <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"მდებარეობა <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"თვითმფრინავის რეჟიმი გამორთულია."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"თვითმფრინავის რეჟიმი ჩართულია."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"თვითმფრინავის რეჟიმი გამოირთო."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"თვითმფრინავის რეჟიმი ჩაირთო."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth გამორთულია."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth ჩართულია."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"მიმდინარეობს Bluetooth-თან დაკავშირება."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth დაკავშირებულია."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth გამოირთო."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth ჩაირთო."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"მდებარეობის შეტყობინება გამორთულია."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"მდებარეობის შეტყობინება ჩართულია."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"მდებარეობის შეტყობინება გამოირთო."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"მდებარეობის შეტყობინება ჩაირთო."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"მაღვიძარა დაყენებულია: <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"არეს დახურვა"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"მეტი დრო"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"ნაკლები დრო"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"არეს დახურვა."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"მეტი დრო."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"ნაკლები დრო."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ფანარი გამორთულია."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ფანარი ჩართულია."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ფანარი გამოირთო."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ფანარი ჩაირთო."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"ფერის ინვერსია გამოირთო."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"ფერის ინვერსია ჩაირთო."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"მობილური ქსელის წერტილი გამოირთო."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"მობილური ქსელის წერტილი ჩაირთო."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"ეკრანის გადაცემა შეჩერებულია."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ეკრანის სიკაშკაშე"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G მონაც. გადაცემა გამორთულია"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G მონაც. გადაცემა გამორთულია"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ფიჭური ინტერნეტი გამორთულია"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS-ით დადგენილი მდებარეობა"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"მდებარეობის მოთხოვნები აქტიურია"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"ყველა შეტყობინების წაშლა"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"პარამეტრები"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"შეტყობინების პარამეტრები"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> პარამეტრები"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"ეკრანი შეტრიალდება ავტომატურად."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ეკრანი დაბლოკილია თარაზულ ორიენტაციაში"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ეკრანი დაბლოკილია პორტრეტის ორიენტაციაში."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ეკრანი უკვე ავტომატურად შეტრიალდება."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ეკრანი ამჟამად ჩაკეტილია ლანდშაფტის ორიენტაციაზე."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ეკრანი ამჟამად ჩაკეტილია პორტრეტის ორიენტაციაზე."</string>
     <string name="dessert_case" msgid="1295161776223959221">"სადესერტო ყუთი"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ეთერნეტი"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"მობილური ინტერნეტი"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"მონაცემთა მოხმარება"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"დარჩენილი მონაცემები"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"ლიმიტი გადაჭარბებულია"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ლიმიტი ამოიწურა - მონაცემთა გამოყენება შეჩერებულია."</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"გამოყენებულია: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"ლიმიტი: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> გაფრთხილება"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"თქვენი ბოლო ეკრანები აქ გამოჩნდება"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"აპლიკაციის შესახებ"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"აპზე ფიქსაცია"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ძიება"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"ძიება"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"გაასრიალეთ ზემოთ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>-თვის."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"გაასრიალეთ მარცხნივ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>-თვის."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"შეწყვეტების გარეშე, მაღვიძარების ჩათვლით"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"წყვეტების გარეშე. მაღვიძარების შემთხვევაშიც კი."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"შეწყვეტების გარეშე"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"მხოლოდ პრიორიტეტული შეწყვეტები"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"თქვენი შემდეგი მაღვიძარაა <xliff:g id="ALARM_TIME">%s</xliff:g>-ზე"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"თქვენს მაღვიძარას <xliff:g id="ALARM_TIME">%s</xliff:g>-ზე ვერ გაიგონებთ"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"ქვემოთ მითითებულია ნაკლებად სასწრაფო შეტყობინებები"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"შეეხეთ ისევ გასახსნელად"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"გაასრიალეთ ზევით განსაბლოკად"</string>
     <string name="phone_hint" msgid="3101468054914424646">"გადაფურცლეთ მარჯვნივ ტელეფონისთვის"</string>
     <string name="camera_hint" msgid="5241441720959174226">"კამერისთვის მარცხენა შენაცვლება"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"სამუდამოდ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"არცერთი"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"პრიორიტეტი"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ყველა"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"(<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>-ის შეცვლა დასრულებამდე)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"მომხმარებლის გადართვა"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"მომხმარებლის გდართვა. ამჟამინდელი მომხმარებელი <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"პროფილის ჩვენება"</string>
     <string name="user_add_user" msgid="5110251524486079492">"მომხმარებლის დამატება"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"ახალი მომხმარებელი"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"სტუმარი"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"გსურთ სტუმრის სესიიდან გამოსვლა?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"სტუმრის სესიიდან გამოსვლით ლოკალური მონაცემები ამოიშლება."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"სტუმრის დამატება"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"სტუმრის ამოშლა"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"სტუმრის ამოშლა?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ამ სესიის ყველა აპი და მონაცემი წაიშლება."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ამოშლა"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"სტუმარო, გვიხარია, რომ დაბრუნდით!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ერთი წუთით"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d წუთით"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ერთი საათით"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d საათით"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"გსურთ, თქვენი სესიის გაგრძელება?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"ხელახლა დაწყება"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"დიახ, გავაგრძელოთ"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"დაემატოს ახალი მომხმარებელი?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"ახალი მომხმარებლის დამატებისას, ამ მომხმარებელს საკუთარი სივრცის შექმნა მოუწევს.\n\nნებისმიერ მომხმარებელს შეუძლია აპები ყველა სხვა მომხმარებლისათვის განაახლოს."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ბატარეის დამზოგი ჩართულია"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ამცირებს წარმადობას და უკანა ფონის მონაცემებს"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ბატარეის დაზოგვის გამორთვა"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"დაწყება ახლავე"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"შეტყობინებები არ არის."</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"შესაძლოა მოწყობილობის მონიტორინგი არ ხორციელდება"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"შესაძლოა პროფილზე ხორციელდებოდეს მონიტორინგი"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"შესაძლოა ქსელზე ხორციელდება მონიტორინგი"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"მოწყობილობის მონიტორინგი"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"პროფილის მონიტორინგი"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ქსელის მონიტორინგი"</string>
-    <string name="open_app" msgid="4011771120339160755">"აპის გახსნა"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN-ის გაუქმება"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN-ის გათიშვა"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ამ მოწყობილობის მმართველი არის:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების.\n\nდამატებითი ინფორმაციისათვის, დაუკავშირდით თქვენს ადმინისტრატორს."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"თქვენ მიეცით ნებართვა „<xliff:g id="APPLICATION">%1$s</xliff:g>“-ს დააყენოს VPN კავშირი.\n\nამ აპს შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"თქვენ დაკავშირებული ხართ VPN-თან („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nთქვენი VPN სერვისის პროვაიდერს  შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ამ მოწყობილობის მმართველია:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების. დამატებითი ინფორმაციისათვის, დაუკავშირდით თქვენს ადმინისტრატორს.\n\nთქვენ მიეცით ნებართვა „<xliff:g id="APPLICATION">%2$s</xliff:g>“-ს დააყენოს VPN კავშირი. ამ აპს შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ამ მოწყობილობის მმართველი არის:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების. დამატებითი ინფორმაციისათვის, დაუკავშირდით თქვენს ადმინისტრატორს.\n\nასევე, თქვენ დაკავშირებული ხართ VPN-თან („<xliff:g id="APPLICATION">%2$s</xliff:g>“). თქვენს VPN სერვისის პროვაიდერს ასევე შეუძლია თქვენი ქსელის აქტივობის მონიტორინგი."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ამ პროფილის მმართველია:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი მოწყობილობისა და ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტის, აპების და უსაფრთხო საიტების.\n\nდამატებითი ინფორმაციისათვის, დაუკავშირდით ადმინისტრატორს."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ამ მოწყობილობის მმართველია:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nთქვენი პროფილის მმართველია:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი მოწყობილობისა და ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტის, აპების და უსაფრთხო საიტების.\n\nდამატებითი ინფორმაციისათვის, დაუკავშირდით ადმინისტრატორს."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ამ პროფილის მმართველია:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინისტრატორს შეუძლია თქვენი მოწყობილობისა და ქსელის აქტივობის მონიტორინგი, მათ შორის ელფოსტის, აპების და უსაფრთხო საიტების. დამატებითი ინფორმაციისათვის, დაუკავშირდით ადმინისტრატორს.\n\nასევე, თქვენ მიანიჭეთ „<xliff:g id="APPLICATION">%2$s</xliff:g>“-ს VPN კავშირის დაყენება. ამ აპს ასევე შეუძლია ქსელის მონიტორ."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ამ პროფილის მმართველია:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nთქვენს ადმინ.-ს შეუძლია თქვენი ქსელის აქტივობის მონიტორ., მათ შორის ელფოსტების, აპების და უსაფრთხო საიტების. დამატ. ინფორმ.-თვის, დაუკავშირდით თქვენს ადმინ.-ს.\n\nასევე, თქვ. დაკავშ.-ლი ხართ VPN-თან („<xliff:g id="APPLICATION">%2$s</xliff:g>“). თქვენს VPN სერვისის მომწოდებელს ასევე შეუძლია თქვ. ქსელის აქტივობის მონიტორ."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ამ მოწყობილობის მმართველია:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nთქვ. პროფილის მმართველია:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nთქვენს ადმინ.-ს შეუძლია თქვ. მოწყ.-ისა და ქსელის აქტივობის მონიტ., მათ შორის ელფოსტის, აპების და უსაფრთხო საიტების. დამატებითი ინფორმ.-თვის, დაუკავშირდით ადმინ.-ს.\n\nასევე, თქვენ მიანიჭეთ „<xliff:g id="APPLICATION">%3$s</xliff:g>“-ს VPN კავშირის დაყენება. ამ აპს ასევე შეუძლია ქსელის მონიტ."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ამ მოწყ.-ის მმართ.-ია:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nთქვ. პროფ-ის მმართ-ია:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nთქვ. ადმინ.-ს შეუძლია თქვ. მოწყ.-ისა და ქსელის აქტივ.-ის მონიტ., მ. შ. ელფოსტის, აპების და უსაფრთხო საიტების. დამატებ. ინფორმ.-თვის, დაუკავშირდით ადმინ.-ს.\n\nასევე, თქვ. დაკავშირ. ხართ VPN-თან („<xliff:g id="APPLICATION">%3$s</xliff:g>“). თქვ. VPN სრვს-ის მომწ.-ს ასევე შეუძლია თქვ. ქსელის აქტ.-ის მონიტორ.."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"მოწყობილობის დარჩება ჩაკეტილი, სანამ ხელით არ გახსნით"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"შეტყობინებების უფრო სწრაფად მიღება"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"იხილეთ განბლოკვამდე"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"არა, გმადლობთ"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"დაყენება"</string>
+    <string name="muted_by" msgid="6147073845094180001">"დადუმებულია <xliff:g id="THIRD_PARTY">%1$s</xliff:g>-ის მიერ"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-kk-rKZ/strings.xml b/packages/SystemUI/res/values-kk-rKZ/strings.xml
index 18af59d..489a634 100644
--- a/packages/SystemUI/res/values-kk-rKZ/strings.xml
+++ b/packages/SystemUI/res/values-kk-rKZ/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Тазалау"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Тізімнен алу"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Қолданба ақпараты"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Мұнда жақындағы экрандар көрсетіледі"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Жуықта қолданылған қолданбаларды қоспау"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 жуықта қолданылған қолданба"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Артқа"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Үй"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Mәзір"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Жақындағы экрандар"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Іздеу"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Бекітпесін ашу"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"бекітпесін ашу"</string>
+    <string name="phone_label" msgid="2320074140205331708">"телефонды ашу"</string>
+    <string name="camera_label" msgid="7261107956054836961">"камераны ашу"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Енгізу әдісі түймесін ауыстыру."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Үйлесімділік ұлғайту түймесі."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Үлкендеу экранда кішірейту."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi екі жолақ."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi үш жолақ."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi сигналы толық."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> қосылған."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> қосылған."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX сигналы жоқ."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX бір жолақ."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX екі жолақ."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Телетайп қосылған."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Қоңырау тербелісі."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Қоңырау үнсіз."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> қолданбасынан бас тарту."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> алынып тасталған."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> іске қосылуда."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Хабар алынып тасталды."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Хабарландыру тақтасы"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Жылдам параметрлер."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Бекіту экраны."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Параметрлер"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Жақындағы экрандар."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Пайдаланушы <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi өшірілді."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi қосылды."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Ұялы <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батарея <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Ұшақ режимі <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Аймақ <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Ұшақ режимі өшірулі."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Ұшақ режимі қосулы."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Ұшақ режимі өшірілді."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Ұшақ режимі қосылды."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth өшірулі."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth қосулы."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth қосылуда."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth қосылған."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth өшірілді."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth қосылды."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Орындар туралы есептер өшірулі."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Орындар туралы есептер қосулы."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Орындар туралы есептер өшірілді."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Орындар туралы есептер қосылды."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Дабыл <xliff:g id="TIME">%s</xliff:g> уақытына реттелген."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Тақтаны жабу"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Көбірек уақыт"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Азырақ уақыт"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Тақтаны жабу."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Көбірек уақыт."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Азырақ уақыт."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Қол шам өшірулі."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Қол шам қосулы."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Қол шам өшірілді."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Қол шам қосылды."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Түстердің инверсиясы өшірілді."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Түстердің инверсиясы қосылды."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобильді хотспот өшірілді."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобильді хотспот қосылды."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Экранды трансляциялау тоқтатылды."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Дисплей жарықтығы"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G деректері өшірулі"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G деректері өшірулі"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Ұялы деректер өшірулі"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Аймақ GPS арқылы орнатылған"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Аймақ өтініштері қосылған"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Барлық хабарларды жойыңыз."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Параметрлер"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Хабарландыру параметрлері"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> параметрлері"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Экран автоматты түрде бұрылады."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Экран ландшафт бағытында бекітілген."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Экран портрет бағытында бекітілген."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Экран енді автоматты түрде бұрылады."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Экран енді альбомдық бағдарда бекітілді."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Экран енді портреттік бағдарда бекітілді."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Десерт жағдайы"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Қалғу"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Этернет"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Ұялы деректер"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Деректерді пайдалану"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Қалған деректер"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Шектен асу"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Шекке жеттіңіз – деректерді пайдалану кідіртілді"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> пайдаланылған"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> шегі"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> туралы ескерту"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Мұнда жақындағы экрандар көрсетіледі"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Қолданба туралы ақпарат"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"қолданбаға бекіту"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"іздеу"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Іздеу"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> үшін жоғары сырғыту."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> үшін солға сырғыту."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Үзілістерсіз, соның ішінде, дабылдарсыз"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Үзілулер болмайды. Тіпті дабылдар да."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Үзулерсіз"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Тек басым үзулер"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Келесі дабыл — <xliff:g id="ALARM_TIME">%s</xliff:g> уақытында"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> уақытында дабылды естімейсіз"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Шұғылдығы азырақ хабарландырулар төменде"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Ашу үшін қайтадан түртіңіз"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Бекітпесін ашу үшін жанаңыз"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Телефон үшін оңға жанаңыз"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Камера үшін солға жанаңыз"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Белгісіз уақыт бойы"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ешқандай"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Басымдық"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Барлығы"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Зарядталуда (толғанша <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Пайдаланушыны ауыстыру"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Пайдаланушыны ауыстыру, ағымдағы пайдаланушы <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Профильді көрсету"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Пайдаланушы қосу"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Жаңа пайдаланушы"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Қонақ"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Қонақ қосу"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Қонақты жою"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Қонақ сеансынан шығып жатырсыз ба?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Қонақ сеансынан шығу жергілікті деректерді жояды."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Қонақты жою керек пе?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Осы сеанстағы барлық қолданбалар мен деректер жойылады."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Алып тастау"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Қош келдіңіз, қонақ"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Бір минут бойы"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d минут бойы"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Бір сағат бойы"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d сағат бойы"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Сеансты жалғастыру керек пе?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Қайта бастау"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Иә, жалғастыру"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Жаңа пайд-ны қосу керек пе?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Жаңа пайдаланушыны қосқанда сол адам өз кеңістігін реттеуі керек.\n\nКез келген пайдаланушы барлық басқа пайдаланушылар үшін қолданбаларды жаңарта алады."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Батарея үнемдегіш қосулы"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Өнімділікті және фондық деректерді азайтады"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Батарея үнемдегішті өшіру"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Қазір бастау"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Хабарландырулар жоқ"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Құрылғы бақылануы мүмкін"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профиль бақылануы мүмкін"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Желі бақылауда болуы мүмкін"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Құрылғыны бақылау"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Профильді бақылау"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Желіні бақылау"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ашық қолданба"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN функциясын өшіру"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN желісін ажырату"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Бұл құрылғыны басқаратын ұйым:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылауы мүмкін.\n\nҚосымша ақпарат алу үшін әкімшіге хабарласыңыз."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Сіз «<xliff:g id="APPLICATION">%1$s</xliff:g>» қолданбасына VPN байланысын орнату рұқсатын бердіңіз.\n\nБұл қолданба құрылғыңызды және желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылауы мүмкін."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Сіз VPN («<xliff:g id="APPLICATION">%1$s</xliff:g>») желісіне қосылғансыз.\n\nVPN қызмет жеткізушісі құрылғыңызды және желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылауы мүмкін."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Бұл құр. келесі ұйым бас.:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хаб-ды, қолд-ды және қорғалған веб-сайттарды бақ. мүмкін. Қосымша ақпарат алу үшін әкімшіге хабарласыңыз.\n\nСондай-ақ, сіз «<xliff:g id="APPLICATION">%2$s</xliff:g>» қолд-на VPN байланысын орнатуға рұқсат еттіңіз. Бұл қолд. да желілік белс-ті бақылауы мүмкін."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Бұл құрылғыны келесі ұйым басқарады:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылауы мүмкін. Қосымша ақпарат алу үшін әкімшіге хабарласыңыз.\n\nСондай-ақ, сіз VPN («<xliff:g id="APPLICATION">%2$s</xliff:g>») желісіне қосылғансыз. VPN қызмет жет-сі де жел. белс-ті бақ. мүм."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Бұл профильді басқаратын:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылай алады.\n\nҚосымша ақпарат алу үшін әкімшіге хабарласыңыз."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Бұл құрылғыны басқаратын:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nБұл профильді басқаратын:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nӘкімші құрылғыны және желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылай алады.\n\nҚосымша ақпарат алу үшін әкімшіге хабарласыңыз."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Бұл профильді басқаратын:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хабарларды, қолданбаларды және қорғалған веб-сайттарды бақылай алады. Қосымша ақпарат алу үшін әкімшіге хабарласыңыз.\n\nСондай-ақ, сіз «<xliff:g id="APPLICATION">%2$s</xliff:g>» VPN байл. орнату рұқ. бердіңіз. Бұл қолданба да желілік белсенділікті бақылай алады."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Бұл профильді басқаратын:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, электрондық хабарларды, қол-ды және қорғалған веб-сайттарды бақылай алады. Қосымша ақпарат алу үшін әкімшіге хабарласыңыз.\n\nСондай-ақ, сіз VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") қызметіне қосылғансыз. VPN қызметін жеткізуші де желілік белсенділікті бақылай алады."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Бұл құрылғыны басқаратын:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПрофиліңізді басқаратын:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nӘкімші желілік белс-ті, соның ішінде, эл. хаб-ды, қол-ды және қорғалған веб-сайттарды бақылай алады. Қосымша ақпар. алу үшін әкімшіге хаб-з.\n\nСондай-ақ, сіз «<xliff:g id="APPLICATION">%3$s</xliff:g>» VPN байланысын орнату рұқсатын бердіңіз. Бұл қолданба да желілік белсенділікті бақылай алады."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Бұл құр. басқаратын:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПрофиліңізді басқаратын:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nӘкімші желілік белсенділікті, соның ішінде, эл. хаб-ды, қолд-ды және қорғалған веб-сайттарды бақылай алады. Қосымша ақпарат алу үшін әкімшіге хаб-ңыз.\n\nСондай-ақ, VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") қызметіне қосылғансыз. VPN қызметін жеткізуші де желілік белсенділікті бақылай алады."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Қолмен бекітпесін ашқанша құрылғы бекітілген күйде қалады"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Хабарландыруларды тезірек алу"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Бекітпесін ашу алдында оларды көру"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Жоқ, рақмет"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Реттеу"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> үнін өшірген"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-km-rKH/strings.xml b/packages/SystemUI/res/values-km-rKH/strings.xml
index 5ca2339..e49dd34 100644
--- a/packages/SystemUI/res/values-km-rKH/strings.xml
+++ b/packages/SystemUI/res/values-km-rKH/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"សម្អាត"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"យក​ចេញ​ពី​បញ្ជី"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"ព័ត៌មាន​កម្មវិធី"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"អេក្រង់​បច្ចុប្បន្ន​របស់​អ្នក​បង្ហាញ​នៅ​ទីនេះ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"បដិសេធ​កម្មវិធី​ថ្មីៗ"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"កម្មវិធី​ថ្មី ១"</item>
@@ -70,7 +69,7 @@
     <string name="screenshot_saving_ticker" msgid="7403652894056693515">"កំពុង​រក្សាទុក​រូបថត​អេក្រង់…"</string>
     <string name="screenshot_saving_title" msgid="8242282144535555697">"កំពុង​រក្សាទុក​រូបថត​អេក្រង់..."</string>
     <string name="screenshot_saving_text" msgid="2419718443411738818">"រូបថត​អេក្រង់​កំពុង​ត្រូវ​បាន​រក្សាទុក។"</string>
-    <string name="screenshot_saved_title" msgid="6461865960961414961">"បាន​ចាប់​យក​រូបថត​អេក្រង់។"</string>
+    <string name="screenshot_saved_title" msgid="6461865960961414961">"បាន​ចាប់​យក​រូបថត​អេក្រង់។​"</string>
     <string name="screenshot_saved_text" msgid="1152839647677558815">"ប៉ះ ​ដើម្បី​មើល​រូបថត​អេក្រង់​របស់​អ្នក​។"</string>
     <string name="screenshot_failed_title" msgid="705781116746922771">"មិន​អាច​ចាប់​យក​រូប​ថត​អេក្រង់​។"</string>
     <string name="screenshot_failed_text" msgid="1260203058661337274">"មិនអាចថតអេក្រង់ដោយសារតែទំហំផ្ទុកមានដែនកំណត់ ឬវាមិនត្រូវបានអនុញ្ញាត​ដោយកម្មវិធី ឬ​ស្ថាប័ន​របស់​អ្នក។"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"ថយក្រោយ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"គេហ​ទំព័រ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"ម៉ឺនុយ"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"អេក្រង់​ថ្មីៗ"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ស្វែងរក"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ម៉ាស៊ីន​ថត"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ទូរស័ព្ទ"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ដោះ​​សោ"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ដោះ​សោ"</string>
+    <string name="phone_label" msgid="2320074140205331708">"បើក​ទូរស័ព្ទ"</string>
+    <string name="camera_label" msgid="7261107956054836961">"បើក​ម៉ាស៊ីន​ថត"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ប្ដូរ​ប៊ូតុង​វិធីសាស្ត្រ​បញ្ចូល។"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"ប៊ូតុង​ពង្រីក​ត្រូវ​គ្នា។"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ពង្រីក/បង្រួម​​អេក្រង់​ពី​​ទៅធំ"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"សេវា​វ៉ាយហ្វាយ​ពីរ​កាំ។"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"វ៉ាយហ្វាយ​បី​កាំ។"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"សញ្ញា​វ៉ាយហ្វាយ​ពេញ។"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"បាន​ភ្ជាប់​ទៅ <xliff:g id="WIFI">%s</xliff:g> ។"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"បាន​ភ្ជាប់​ទៅ <xliff:g id="BLUETOOTH">%s</xliff:g> ។"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"គ្មាន WiMAX ។"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX មួយ​កាំ។"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX ពីរ​កាំ។"</string>
@@ -148,32 +152,54 @@
     <string name="accessibility_remove_notification" msgid="3603099514902182350">"សម្អាត​ការ​ជូន​ដំណឹង។"</string>
     <string name="accessibility_gps_enabled" msgid="3511469499240123019">"បាន​បើក GPS ។"</string>
     <string name="accessibility_gps_acquiring" msgid="8959333351058967158">"ទទួល​​ GPS ។"</string>
-    <string name="accessibility_tty_enabled" msgid="4613200365379426561">"បាន​បើក​ម៉ាស៊ីន​អង្គុលីលេខ"</string>
+    <string name="accessibility_tty_enabled" msgid="4613200365379426561">"បាន​បើក​ម៉ាស៊ីន​អង្គុលីលេខ​"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"កម្មវិធី​រោទ៍​ញ័រ។"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"កម្មវិធី​រោទ៍​ស្ងាត់។"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"បោះបង់ <xliff:g id="APP">%s</xliff:g> ។"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> បដិសេធ។"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"ចាប់ផ្ដើម <xliff:g id="APP">%s</xliff:g> ។"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"បាន​បដិសេធ​ការ​ជូនដំណឹង"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"ពណ៌​ការ​ជូន​ដំណឹង"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ការ​កំណត់​រហ័ស។"</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ចាក់​សោ​អេក្រង់។"</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"ការកំណត់"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"អេក្រង់​ថ្មីៗ។"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"អ្នក​ប្រើ <xliff:g id="USER">%s</xliff:g> ។"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"បាន​បិទ​វ៉ាយហ្វាយ។"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"បាន​បើក​វ៉ាយហ្វាយ។"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"ចល័ត <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ថ្ម <xliff:g id="STATE">%s</xliff:g> ។"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"របៀបពេល​ជិះ​យន្ត​ហោះ <xliff:g id="STATE">%s</xliff:g> ។"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ប៊្លូធូស <xliff:g id="STATE">%s</xliff:g> ។"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"ទីតាំង <xliff:g id="STATE">%s</xliff:g> ។"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"បិទ​របៀប​ជិះ​យន្តហោះ។"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"បើក​របៀប​ជិះ​យន្តហោះ។"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"បាន​បិទ​របៀប​ជិះ​យន្តហោះ។"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"បាន​បើក​របៀប​ជិះ​យន្តហោះ។"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"បិទ​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"បើក​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ការ​​​ភ្ជាប់​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"បាន​​ភ្ជាប់​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"បាន​បិទ​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"បាន​បើក​ប៊្លូធូស។"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"បិទ​ការ​រាយការណ៍​ទីតាំង។"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"បើក​ការ​រាយការណ៍​ទីតាំង។"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"បាន​បិទ​ការ​រាយការណ៍​ទីតាំង។"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"បាន​បើក​ការ​រាយការណ៍​ទីតាំង។"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"កំណត់​សំឡេង​រោទ៍​សម្រាប់ <xliff:g id="TIME">%s</xliff:g> ។"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"បិទ​បន្ទះ"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"ពេល​ច្រើនជាង"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"ពេល​តិចជាង"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"បិទ​ផ្ទាំង។"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"ច្រើនជាង"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"តិច​ជាង"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"បិទ​ពិល។"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"បើក​ពិល។"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"បាន​បិទ​ពិល។"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"បាន​បើក​ពិល។"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"បាន​បិទ​ការ​បញ្ច្រាស​ពណ៌។"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"បាន​បើក​ការ​បញ្ច្រាស​ពណ៌។"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"បាន​បិទ​ហតស្ប៉ត​ចល័ត។"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"បាន​បើក​ហតស្ប៉ត​ចល័ត។"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"បាន​បញ្ឈប់​ការ​ចាត់​ថ្នាក់​អេក្រង់។"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ពន្លឺ​ការ​បង្ហាញ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"ទិន្នន័យ 2G-3G បាន​បិទ"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"ទិន្នន័យ 4G បាន​បិទ"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ទិន្នន័យ​ចល័ត​បាន​បិទ"</string>
@@ -186,12 +212,16 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"ទីតាំង​​​​​កំណត់​ដោយ GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"សំណើ​ទីតាំង​សកម្ម"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"សម្អាត​ការ​ជូន​ដំណឹង​ទាំងអស់។"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ការកំណត់"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"​កំណត់​ការ​ជូនដំណឹង"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"ការ​កំណត់ <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"នឹង​បង្វិល​អេក្រង់​ស្វ័យ​ប្រវត្តិ។"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"អេក្រង់​ជាប់​សោ​ក្នុង​ទិស​ផ្ដេក។"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"បា​ន​ចាក់​សោ​អេក្រង់​​ក្នុង​ទិស​បញ្ឈរ។"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ឥឡូវនេះ​អេក្រង់​នឹង​បង្វិល​ដោយ​ស្វ័យប្រវត្តិ។"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ឥឡូវ​អេក្រង់​​ជាប់​សោ​ក្នុង​ទិស​ផ្ដេក។"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ឥឡូវ​អេក្រង់​​ជាប់​សោ​ក្នុង​ទិស​បញ្ឈរ។"</string>
     <string name="dessert_case" msgid="1295161776223959221">"ករណី Dessert"</string>
-    <string name="start_dreams" msgid="7219575858348719790">"ស្រមើ​ស្រមៃ"</string>
+    <string name="start_dreams" msgid="7219575858348719790">"ធាតុ​រក្សា​អេក្រង់"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"អ៊ីសឺរណិត"</string>
     <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"របៀបពេល​​ជិះ​យន្តហោះ"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"បញ្ចូល​ថ្ម <xliff:g id="NUMBER">%d</xliff:g> <xliff:g id="PERCENT">%%</xliff:g>"</string>
@@ -206,7 +236,7 @@
     <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"បញ្ឈរ"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"ទេសភាព"</string>
     <string name="quick_settings_ime_label" msgid="7073463064369468429">"វិធីសាស្ត្រ​បញ្ចូល"</string>
-    <string name="quick_settings_location_label" msgid="5011327048748762257">"ទី​តាំង"</string>
+    <string name="quick_settings_location_label" msgid="5011327048748762257">"ទី​តាំង​"</string>
     <string name="quick_settings_location_off_label" msgid="7464544086507331459">"ទីតាំង​បាន​បិទ"</string>
     <string name="quick_settings_media_device_label" msgid="1302906836372603762">"ឧបករណ៍​មេឌៀ"</string>
     <string name="quick_settings_rssi_label" msgid="7725671335550695589">"RSSI"</string>
@@ -221,7 +251,7 @@
     <string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"គ្មាន​បណ្ដាញ"</string>
     <string name="quick_settings_wifi_off_label" msgid="7558778100843885864">"វ៉ាយហ្វាយ​បានបិទ"</string>
     <string name="quick_settings_wifi_detail_empty_text" msgid="2831702993995222755">"មិន​មាន​បណ្ដាញ​ដែល​បាន​រក្សាទុក"</string>
-    <string name="quick_settings_cast_title" msgid="1893629685050355115">"ចាត់​ថ្នាក់​អេក្រង់"</string>
+    <string name="quick_settings_cast_title" msgid="1893629685050355115">"ខាស​អេក្រង់"</string>
     <string name="quick_settings_casting" msgid="6601710681033353316">"ការ​ចាត់​ថ្នាក់"</string>
     <string name="quick_settings_cast_device_default_name" msgid="5367253104742382945">"ឧបករណ៍​​ដែល​មិន​មាន​ឈ្មោះ"</string>
     <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"ត្រៀម​រួចរាល់​ដើម្បី​ចាត់​ថ្នាក់"</string>
@@ -241,24 +271,23 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"ទិន្នន័យ​ចល័ត"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ការ​ប្រើ​ទិន្នន័យ"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ទិន្នន័យ​នៅសល់"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"លើស​ដែន​កំណត់"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"បាន​ដល់​ដែន​កំណត់ – បា​ន​ផ្អាក​ការ​ប្រើ​ទិន្នន័យ"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"បាន​ប្រើ <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"ដែន​កំណត់ <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ការ​ព្រមាន"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"អេក្រង់​បច្ចុប្បន្ន​របស់​អ្នក​បង្ហាញ​នៅ​ទីនេះ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"ព័ត៌មាន​កម្មវិធី"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"ចាក់​សោ​ទៅ​កម្មវិធី"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ស្វែងរក"</string>
-    <string name="expanded_header_battery_charged" msgid="5945855970267657951">"បាន​បញ្ចូល​ថ្ម"</string>
+    <string name="expanded_header_battery_charged" msgid="5945855970267657951">"បាន​បញ្ចូល​ថ្ម​​"</string>
     <string name="expanded_header_battery_charging" msgid="205623198487189724">"កំពុង​បញ្ចូល​ថ្ម"</string>
     <string name="expanded_header_battery_charging_with_time" msgid="457559884275395376">"<xliff:g id="CHARGING_TIME">%s</xliff:g> រហូត​ដល់ពេញ"</string>
     <string name="expanded_header_battery_not_charging" msgid="4798147152367049732">"មិន​កំពុង​បញ្ចូល​ថ្ម"</string>
-    <string name="ssl_ca_cert_warning" msgid="9005954106902053641">"បណ្ដាញ​អាច​\nត្រូវ​បាន​ត្រួតពិនិត្យ"</string>
+    <string name="ssl_ca_cert_warning" msgid="9005954106902053641">"បណ្ដាញ​អាច​\nត្រូវ​បាន​ត្រួតពិនិត្យ​"</string>
     <string name="description_target_search" msgid="3091587249776033139">"ស្វែងរក"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"រុញ​ឡើង​លើ​ដើម្បី <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ។"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"រុញ​ទៅ​ឆ្វេង​ដើម្បី <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ។"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"មិន​មានការ​ផ្អាក រួម​ទាំង​ការ​ជូនដំណឹង"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"គ្មាន​ការ​ផ្អាក។ គ្មាន​ការ​ជូនដំណឹង​ពី​ព្រឹត្តិការណ៍។"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"គ្មាន​ការ​ផ្អាក"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"តែ​ការ​ផ្អាក​អាទិភាព​ប៉ុណ្ណោះ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ការ​ជូនដំណឹង​បន្ទាប់​របស់​អ្នក​គឺនៅម៉ោង <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"អ្នកនឹងមិនឮការជូន​ដំណឹងរបស់អ្នកនៅម៉ោង <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"ការ​ជូន​ដំណឹង​​មិន​សូវ​បន្ទាន់​ខាង​ក្រោម"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"ប៉ះ​ម្ដង​ទៀត​ដើម្បី​បើក"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"អូស​ឡើង​លើ ដើម្បី​ដោះ​សោ"</string>
     <string name="phone_hint" msgid="3101468054914424646">"អូស​ទៅ​ស្ដាំ​ដើម្បី​បើក​​ទូរស័ព្ទ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"អូស​ទៅ​ឆ្វេង​​ដើម្បី​ប្រើ​​ម៉ាស៊ីន​ថត"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"គ្មាន​​កំណត់"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"គ្មាន"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"អាទិភាព"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ទាំងអស់"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"កំពុង​បញ្ចូល​ថ្ម (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> ទើប​ពេញ)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ប្ដូរ​អ្នក​ប្រើ"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ប្ដូរ​អ្នកប្រើ ​អ្នកប្រើ​បច្ចុប្បន្ន <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"បង្ហាញ​ប្រវត្តិរូប"</string>
     <string name="user_add_user" msgid="5110251524486079492">"បន្ថែម​អ្នកប្រើ"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"អ្នកប្រើ​ថ្មី"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"ភ្ញៀវ"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ចេញ​ពី​សម័យ​ភ្ញៀវ?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"ការ​ចេញ​ពី​សម័យ​ភ្ញៀវ​នឹង​លុប​ទិន្នន័យ​មូលដ្ឋាន។"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"បន្ថែម​ភ្ញៀវ"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"លុប​សម័យ​ភ្ញៀវ"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"លុប​ភ្ញៀវ​?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ទិន្នន័យ និង​កម្មវិធី​ទាំងអស់​ក្នុង​សម័យ​នេះ​នឹង​ត្រូវ​បាន​លុប។"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"លុបចេញ"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"សូម​ស្វាគមន៍​ការ​ត្រឡប់​មកវិញ, ភ្ញៀវ!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"សម្រាប់​មួយ​នាទី"</item>
-    <item quantity="other" msgid="6924190729213550991">"សម្រាប់ %d នាទី"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"សម្រាប់​មួយ​ម៉ោង"</item>
-    <item quantity="other" msgid="5408537517529822157">"សម្រាប់ %d ម៉ោង"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"តើ​អ្នក​ចង់​បន្ត​សម័យ​របស់​អ្នក​?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"ចាប់ផ្ដើម"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"បាទ​/ចាស ​បន្ត"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"បន្ថែម​អ្នកប្រើ​ថ្មី?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"ពេល​អ្នក​បន្ថែម​អ្នកប្រើ​ថ្មី អ្នកប្រើ​នោះ​ត្រូវ​កំណត់​ទំហំ​ផ្ទាល់​របស់​គេ។\n\nអ្នក​ប្រើ​ណាមួយ​ក៏​អាច​ធ្វើ​បច្ចុប្បន្នភាព​កម្មវិធី​សម្រាប់​អ្នកប្រើ​ផ្សេង​បាន​ដែរ។"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"កម្មវិធី​សន្សំ​ថ្ម​គឺ​បើក"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ការ​បន្ថយ​ការ​ប្រតិបត្តិ និង​ទិន្នន័យ​ផ្ទៃ​ខាងក្រោយ"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"បិទ​ធាតុ​រក្សា​ថាមពល​ថ្ម"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"ចាប់ផ្ដើម​ឥឡូវ"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"គ្មាន​ការ​ជូនដំណឹង"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ឧបករណ៍​អាច​ត្រូវ​បាន​ត្រួតពិនិត្យ"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ប្រវត្តិរូបអាចត្រូវបានតាមដាន"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"បណ្ដាញ​អាច​ត្រូវ​បាន​ត្រួតពិនិត្យ"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ការ​ត្រួតពិនិត្យ​ឧបករណ៍"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"តាមដានប្រវត្ថិរូប"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ការ​ត្រួតពិនិត្យ​បណ្ដាញ"</string>
-    <string name="open_app" msgid="4011771120339160755">"បើក​កម្មវិធី"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"បិទ VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"ផ្ដាច់ VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ឧបករណ៍​នេះ​ត្រូវ​បាន​គ្រប់គ្រង​ដោយ៖\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nអ្នកគ្រប់គ្រង​របស់​អ្នក​អាច​ពិនិត្យ​ឧបករណ៍ និង​សកម្មភាព​បណ្ដាញ​របស់​អ្នក​រួម​មាន​​ អ៊ីមែល, កម្មវិធី និង​តំបន់បណ្ដាញ​មាន​សុវត្ថិភាព។\n\nចំពោះ​ព័ត៌មាន​បន្ថែម សូម​ទាក់ទង​អ្នក​គ្រប់គ្រង​របស់​អ្នក។"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"អ្នក​បាន​ផ្ដល់​សិទ្ធិ \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ដើម្បី​រៀបចំ​ការ​ភ្ជាប់ VPN ។\n\nកម្មវិធី​នេះ​អាច​ពិនិត្យ​ឧបករណ៍ និង​សកម្មភាព​បណ្ដាញ​របស់​អ្នក​រួមមាន អ៊ីមែល, កម្មវិធី និង​តំបន់បណ្ដាញ​មាន​សុវត្ថិភាព។"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"អ្នក​​បាន​ភ្ជាប់​ទៅ VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\")។\n\nក្រុមហ៊ុន​ផ្ដល់​សេវាកម្ម VPN របស់​អ្នក​​អាច​ពិនិត្យ​ឧបករណ៍ និង​សកម្មភាព​បណ្ដាញ​របស់​អ្នក​​រួមមាន អ៊ីមែល, កម្មវិធី និង​តំបន់​បណ្ដាញ​មាន​សុវត្ថិភាព។"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ឧបករណ៍នេះត្រូវបានគ្រប់គ្រងដោយ​ \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n អ្នកគ្រប់គ្រងរបស់អ្នកមានសមត្ថភាពក្នុងការត្រួតពិនិត្យសកម្មភាពបណ្ដាញរបស់អ្នក រួមមានអ៊ីមែល​, កម្មវិធី​, និងតំបន់បណ្ដាញសុវត្ថិភាព​។ សម្រាប់ព័ត៌មានបន្ថែមសូមទាក់ទងអ្នកគ្រប់គ្រងរបស់អ្នក​។ \n\n អ្នកបានផ្ដល់សិទ្ធិ\"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ដើម្បីរៀបចំការតភ្ជាប់ VPN ។ កម្មវិធីនេះអាចតាមដានសកម្មភាពបណ្ដាញ។"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ឧបករណ៍នេះត្រូវបានគ្រប់គ្រងដោយ \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n អ្នកគ្រប់គ្រងរបស់អ្នកមានសមត្ថភាពក្នុងការត្រួតពិនិត្យសកម្មភាពបណ្ដាញរបស់អ្នករួមមានអ៊ីមែល​, កម្មវិធី និងតំបន់បណ្ដាញសុវត្ថិភាព។ សម្រាប់ព័ត៌មានបន្ថែមសូមទាក់ទងអ្នកគ្រប់គ្រងរបស់អ្នក។ \n\n ​អ្នកត្រូវបានតភ្ជាប់ទៅ VPN (\" <xliff:g id="APPLICATION">%2$s</xliff:g> \") ។ ក្រុមហ៊ុនផ្ដល់​សេវា VPN របស់អ្នកអាចតាមដានសកម្មភាពរបស់​អ្នក។"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ប្រវត្តិរូបនេះត្រូវបានគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nអ្នក​គ្រប់គ្រង​របស់​អ្នក​អាច​តាមដាន​ឧបករណ៍ និង​សកម្មភាព​បណ្ដាញ​របស់​អ្នក រួមមាន​កម្មវិធី និង​តំបន់​បណ្ដាញ​មាន​សុវត្ថិភាព។\n\nចំពោះ​ព័ត៌មាន ទាក់ទង​អ្នកគ្រប់គ្រង​របស់​អ្នក។"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ឧបករណ៍នេះត្រូវបានគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nប្រវត្តិរូបរបស់អ្នកត្រូវបានគ្រប់គ្រង​ដោយ៖\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nអ្នកគ្រប់គ្រងរបស់អ្នកអាចតាមដានឧបករណ៍​ និងសកម្មភាព​បណ្ដាញរបស់អ្នក រួមមានអ៊ីមែល, កម្មវិធី និងតំបន់បណ្ដាញមានសុវត្ថិភាព។\n\nចំពោះ​ព័ត៌មាន​បន្ថែម ទាក់ទង​អ្នក​គ្រប់គ្រង​របស់​អ្នក។"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ប្រវត្តិរូបនេះត្រូវបានគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nអ្នកគ្រប់គ្រងរបស់អ្នកអាចតាមដានសកម្មភាពបណ្ដាញរួមមាន អ៊ីមែល, កម្មវិធី និងតំបន់បណ្ដាញមានសុវត្ថិភាព។ ចំពោះព័ត៌មានបន្ថែម ទាក់ទងអ្នកគ្រប់គ្រងរបស់អ្នក។\n\nអ្នកបានផ្ដល់សិទ្ធិ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ឲ្យកំណត់ការភ្ជាប់ VPN ។ កម្មវិធីនេះអាចតាមដានសកម្មភាពបណ្ដាញផងដែរ។"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ប្រវត្តិ​រូបនេះត្រូវបានគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nអ្នកគ្រប់គ្រងរបស់អ្នកអាចតាមដាន​សកម្មភាពបណ្ដាញរបស់អ្នករួមមានអ៊ីមែល, កម្មវិធី និងតំបន់បណ្ដាញមានសុវត្ថិភាព។ ចំពោះព័ត៌មានបន្ថែម ទាក់ទង​អ្នកគ្រប់គ្រងរបស់​អ្នក។\n\nអ្នកត្រូវបាន​ភ្ជាប់ទៅ​ VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") ។ ក្រុមហ៊ុនផ្ដល់សេវាកម្ម VPN របស់អ្នកអាចតាមដានសកម្មភាពបណ្ដាញរបស់អ្នក​បានផងដែរ។"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ឧបករណ៍នេះត្រូវបានគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nប្រវត្តិរូបរបស់អ្នកត្រូវបានគ្រប់គ្រង៖\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nអ្នកគ្រប់គ្រងរបស់អ្នកអាចតាមដានសកម្មភាពបណ្ដាញ រួមមានអ៊ីមែល កម្មវិធី និងតំបន់បណ្ដាញមានសុវត្ថិភាព។ ចំពោះព័ត៌មានបន្ថែម ទាក់ទងអ្នកគ្រប់គ្រងរបស់អ្នក។\n\nអ្នកបានផ្ដល់សិទ្ធិ \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ឲ្យកំណត់ការភ្ជាប់ VPN ។ កម្មវិធីនេះអាចតាមដានសកម្មភាពបណ្ដាញផងដែរ។"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ឧបករណ៍នេះត្រូវបា​នគ្រប់គ្រងដោយ៖\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nប្រវត្តិរូបរបស់អ្នកត្រូវបានគ្រប់គ្រង​ដោយ៖\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nអ្នកគ្រប់គ្រងរបស់អ្នកអាចតាមដានសកម្មភាពបណ្ដាញរបស់អ្នក  រួមមានអ៊ីមែល, កម្មវិធី និងតំបន់បណ្ដាញមានសុវត្ថិភាព​​​។ ចំពោះព័ត៌មានបន្ថែម ទាក់ទង​អ្នកគ្រប់គ្រងរបស់​អ្នក។\n\nអ្នកក៏បានភ្ជាប់ទៅ​ VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") ។ ក្រុមហ៊ុនផ្ដល់សេវាកម្ម VPN របស់អ្នកអាចតាមដានសកម្មភាពបណ្ដាញបានផងដែរ។"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"ឧបករណ៍​នឹង​ចាក់​សោ​រហូត​ដល់​អ្នក​ដោះ​សោ​ដោយ​ដៃ"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"ទទួល​បាន​ការ​ជូន​ដំណឹង​កាន់តែ​លឿន"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ឃើញ​ពួកវា​មុន​ពេល​ដោះ​សោ"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"ទេ អរគុណ!"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"រៀបចំ"</string>
+    <string name="muted_by" msgid="6147073845094180001">"បាន​បិទ​សំឡេង​ដោយ <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-kn-rIN/config.xml b/packages/SystemUI/res/values-kn-rIN/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-kn-rIN/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-kn-rIN/strings.xml b/packages/SystemUI/res/values-kn-rIN/strings.xml
index 45d32b2..f9f4ff9 100644
--- a/packages/SystemUI/res/values-kn-rIN/strings.xml
+++ b/packages/SystemUI/res/values-kn-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"ತೆರವುಮಾಡು"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"ಪಟ್ಟಿಯಿಂದ ತೆಗೆದುಹಾಕು"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"ಅಪ್ಲಿಕೇಶನ್ ಮಾಹಿತಿ"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"ನಿಮ್ಮ ಇತ್ತೀಚಿನ ಪರದೆಗಳು ಇಲ್ಲಿ ಕಾಣಿಸಿಕೊಳ್ಳುತ್ತವೆ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"ಇತ್ತೀಚಿನ ಅಪ್ಲಿಕೇಶನ್‌ಗಳನ್ನು ವಜಾಗೊಳಿಸು"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ಇತ್ತೀಚಿನ ಅಪ್ಲಿಕೇಶನ್"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"ಹಿಂದೆ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"ಮುಖಪುಟ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"ಮೆನು"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"ಇತ್ತೀಚಿನ ಪರದೆಗಳು"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ಹುಡುಕು"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ಕ್ಯಾಮರಾ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ಫೋನ್"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ಅನ್‌ಲಾಕ್"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ಅನ್‌ಲಾಕ್ ಮಾಡು"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ಫೋನ್ ತೆರೆಯಿರಿ"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ಕ್ಯಾಮರಾ ತೆರೆಯಿರಿ"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ಇನ್‌ಪುಟ್ ವಿಧಾನ ಬದಲಿಸು ಬಟನ್."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"ಹೊಂದಾಣಿಕೆಯ ಝೂಮ್ ಬಟನ್."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ಚಿಕ್ಕ ಪರದೆಯಿಂದ ದೊಡ್ಡ ಪರದೆಗೆ ಝೂಮ್ ಮಾಡು."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi ಎರಡು ಪಟ್ಟಿಗಳು."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi ಮೂರು ಪಟ್ಟಿಗಳು."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi ಸಿಗ್ನಲ್‌‌ ಪೂರ್ತಿ ಇದೆ."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> ಗೆ ಸಂಪರ್ಕಪಡಿಸಲಾಗಿದೆ."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> ಗೆ ಸಂಪರ್ಕಪಡಿಸಲಾಗಿದೆ."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX ಸಂಕೇತವಿಲ್ಲ."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ಒಂದು ಪಟ್ಟಿ."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX ಎರಡು ಪಟ್ಟಿಗಳು."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"ಟೆಲಿಟೈಪ್‌ರೈಟರ್ ಸಕ್ರಿಯವಾಗಿದೆ."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"ರಿಂಗರ್ ಕಂಪನ."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"ರಿಂಗರ್ ಶಾಂತ."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> ವಜಾಗೊಳಿಸು."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ವಜಾಗೊಳಿಸಲಾಗಿದೆ."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> ಪ್ರಾರಂಭಿಸಲಾಗುತ್ತಿದೆ."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"ಅಧಿಸೂಚನೆ ವಜಾಗೊಂಡಿದೆ."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"ಅಧಿಸೂಚನೆಯ ಛಾಯೆ."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ತ್ವರಿತ ಸೆಟ್ಟಿಂಗ್‍ಗಳು."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ಲಾಕ್‌ ಪರದೆ."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ಸೆಟ್ಟಿಂಗ್‌ಗಳು"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"ಇತ್ತೀಚಿನ ಪರದೆಗಳು."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ಬಳಕೆದಾರ <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"ಮೊಬೈಲ್ <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ಬ್ಯಾಟರಿ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"ಏರ್‌ಪ್ಲೇನ್ ಮೋಡ್ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ಬ್ಲೂಟೂತ್‌‌ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"ಸ್ಥಾನ <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"ಏರ್‌ಪ್ಲೇನ್ ಮೋಡ್ ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"ಏರ್‌ಪ್ಲೇನ್ ಮೋಡ್ ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"ಏರ್‌ಪ್ಲೇನ್ ಮೋಡ್ ಅನ್ನು ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"ಏರ್‌ಪ್ಲೇನ್ ಮೋಡ್ ಅನ್ನು ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"ಬ್ಲೂಟೂತ್ ಆಫ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"ಬ್ಲೂಟೂತ್ ಆನ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ಬ್ಲೂಟೂತ್ ಸಂಪರ್ಕಪಡಿಸಲಾಗುತ್ತಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth ಸಂಪರ್ಕಗೊಂಡಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ಬ್ಲೂಟೂತ್ ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ಬ್ಲೂಟೂತ್ ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"ಸ್ಥಳ ವರದಿಮಾಡುವಿಕೆಯು ಆಫ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"ಸ್ಥಳ ವರದಿಮಾಡುವಿಕೆಯು ಆನ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"ಸ್ಥಳ ವರದಿಮಾಡುವಿಕೆಯನ್ನು ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"ಸ್ಥಳ ವರದಿಮಾಡುವಿಕೆಯನ್ನು ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> ಗಂಟೆಗೆ ಅಲಾರಾಂ ಹೊಂದಿಸಲಾಗಿದೆ."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"ಫಲಕವನ್ನು ಮುಚ್ಚು"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"ಹೆಚ್ಚು ಸಮಯ"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"ಕಡಿಮೆ ಸಮಯ"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ಪ್ಯಾನಲ್ ಮುಚ್ಚಿ."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"ಹೆಚ್ಚು ಸಮಯ."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"ಕಡಿಮೆ ಸಮಯ."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ಫ್ಲ್ಯಾಶ್‌ಲೈಟ್ ಆಫ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ಫ್ಲ್ಯಾಶ್‌ಲೈಟ್ ಆನ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ಫ್ಲ್ಯಾಶ್‌ಲೈಟ್ ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ಫ್ಲ್ಯಾಶ್‌ಲೈಟ್ ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"ಬಣ್ಣ ತಿರುಗಿಸುವಿಕೆಯನ್ನು ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"ಬಣ್ಣ ತಿರುಗಿಸುವಿಕೆಯನ್ನು ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"ಮೊಬೈಲ್ ಹಾಟ್‌ಸ್ಪಾಟ್ ಆಫ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"ಮೊಬೈಲ್ ಹಾಟ್‌ಸ್ಪಾಟ್ ಆನ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"ಸ್ಕ್ರೀನ್ ಪ್ರಸಾರವನ್ನು ನಿಲ್ಲಿಸಲಾಗಿದೆ."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ಹೊಳಪನ್ನು ಪ್ರದರ್ಶಿಸಿ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ಸೆಲ್ಯುಲಾರ್ ಡೇಟಾ ಆಫ್ ಆಗಿದೆ"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"ಸ್ಥಾನವನ್ನು GPS ಮೂಲಕ ಹೊಂದಿಸಲಾಗಿದೆ"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"ಸ್ಥಾನ ವಿನಂತಿಗಳು ಸಕ್ರಿಯವಾಗಿವೆ"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"ಎಲ್ಲಾ ಅಧಿಸೂಚನೆಗಳನ್ನು ತೆರವುಗೊಳಿಸು."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ಸೆಟ್ಟಿಂಗ್‌ಗಳು"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"ಅಧಿಸೂಚನೆ ಸೆಟ್ಟಿಂಗ್‌ಗಳು"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ಸೆಟ್ಟಿಂಗ್‌ಗಳು"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"ಪರದೆಯು ಸ್ವಯಂಚಾಲಿತವಾಗಿ ತಿರುಗುತ್ತದೆ."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ಪರದೆಯನ್ನು ಲ್ಯಾಂಡ್‌ಸ್ಕೇಪ್ ಓರಿಯಂಟೇಶನ್‍ನಲ್ಲಿ ಲಾಕ್ ಮಾಡಲಾಗಿದೆ."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ಪರದೆಯನ್ನು ಪೋಟ್ರೇಟ್ ಓರಿಯಂಟೇಶನ್‍ನಲ್ಲಿ ಲಾಕ್ ಮಾಡಲಾಗಿದೆ."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ಪರದೆಯು ಈಗ ಸ್ವಯಂಚಾಲಿತವಾಗಿ ತಿರುಗುತ್ತದೆ."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ಪರದೆಯು ಇದೀಗ ಲ್ಯಾಂಡ್‌ಸ್ಕೇಪ್ ಒರಿಯಂಟೇಶನ್‌ನಲ್ಲಿ ಲಾಕ್ ಆಗಿದೆ."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ಪರದೆಯು ಇದೀಗ ಪೋಟ್ರೇಟ್ ಒರಿಯಂಟೇಶನ್‌ನಲ್ಲಿ ಲಾಕ್ ಆಗಿದೆ."</string>
     <string name="dessert_case" msgid="1295161776223959221">"ಡೆಸರ್ಟ್ ಕೇಸ್"</string>
     <string name="start_dreams" msgid="7219575858348719790">"ಡೇಡ್ರೀಮ್"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ಇಥರ್ನೆಟ್"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"ಸೆಲ್ಯುಲಾರ್ ಡೇಟಾ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ಡೇಟಾ ಬಳಕೆ"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ಉಳಿದಿರುವ ಡೇಟಾ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"ಮಿತಿ ಮೀರಿದೆ"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ಮಿತಿ ತಲುಪಿದೆ – ಡೇಟಾ ಬಳಕೆಯನ್ನು ವಿರಾಮಗೊಳಿಸಲಾಗಿದೆ"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ಬಳಸಲಾಗಿದೆ"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ಮಿತಿ"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ಎಚ್ಚರಿಕೆ"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"ನಿಮ್ಮ ಇತ್ತೀಚಿನ ಪರದೆಗಳು ಇಲ್ಲಿ ಕಾಣಿಸಿಕೊಳ್ಳುತ್ತವೆ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"ಅಪ್ಲಿಕೇಶನ್ ಮಾಹಿತಿ"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"ಅಪ್ಲಿಕೇಶನ್‌‌ಗೆ ಲಾಕ್‌"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ಹುಡುಕಾಟ"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"ಹುಡುಕಿ"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ಗಾಗಿ ಮೇಲಕ್ಕೆ ಸ್ಲೈಡ್ ಮಾಡಿ."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ಗಾಗಿ ಎಡಕ್ಕೆ ಸ್ಲೈಡ್ ಮಾಡಿ."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ಅಲಾರಂಗಳನ್ನು ಸೇರಿದಂತೆ, ಯಾವುದೇ ಅಡಚಣೆಗಳಿಲ್ಲ"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ಅಲಾರಂಗಳನ್ನು ಸೇರಿದಂತೆ ಯಾವುದೇ ಅಡಚಣೆಗಳಿಲ್ಲ."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"ಯಾವುದೇ ಅಡಚಣೆಗಳಿಲ್ಲ"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"ಆದ್ಯತೆಯ ಅಡಚಣೆಗಳು ಮಾತ್ರ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ನಿಮ್ಮ ಮುಂದಿನ ಅಲಾರಂ <xliff:g id="ALARM_TIME">%s</xliff:g> ಗೆ ಆಗಿದೆ"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> ಗೆ ನೀವು ನಿಮ್ಮ ಅಲಾರಂ ಆಲಿಸುವುದಿಲ್ಲ"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"ಕೆಳಗೆ ಕಡಿಮೆ ಅವಸರದ ಅಧಿಸೂಚನೆಗಳು"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"ತೆರೆಯಲು ಮತ್ತೊಮ್ಮೆ ಸ್ಪರ್ಶಿಸಿ"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"ಅನ್‌ಲಾಕ್‌ ಮಾಡಲು ಸ್ವೈಪ್‌ ಮಾಡಿ"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ಫೋನ್‌ಗಾಗಿ ಬಲಕ್ಕೆ ಸ್ವೈಪ್ ಮಾಡಿ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ಕ್ಯಾಮರಾಗಾಗಿ ಎಡಕ್ಕೆ ಸ್ವೈಪ್ ಮಾಡಿ"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"ಅನಿರ್ದಿಷ್ಟವಾಗಿ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ಯಾವುದೂ ಇಲ್ಲ"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ಆದ್ಯತೆ"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ಎಲ್ಲ"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ಚಾರ್ಜ್ ಆಗುತ್ತಿದೆ ( ಪೂರ್ತಿ ಆಗುವವರೆಗೆ <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ಬಳಕೆದಾರರನ್ನು ಬದಲಿಸಿ"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ಬಳಕೆದಾರರನ್ನು ಬದಲಿಸಿ, ಪ್ರಸ್ತುತ ಬಳಕೆದಾರ <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"ಪ್ರೊಫೈಲ್‌ ತೋರಿಸು"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ಬಳಕೆದಾರರನ್ನು ಸೇರಿಸಿ"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"ಹೊಸ ಬಳಕೆದಾರರು"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"ಅತಿಥಿ"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"ಅತಿಥಿ ಸೇರಿಸಿ"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"ಅತಿಥಿಯನ್ನು ತೆಗೆದುಹಾಕಿ"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ಅತಿಥಿ ಅವಧಿಯನ್ನು ನಿರ್ಗಮಿಸಬೇಕೆ?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"ಅತಿಥಿ ಅವಧಿಯಿಂದ ನಿರ್ಗಮಿಸುವುದರಿಂದ ಸ್ಥಳೀಯ ಡೇಟಾವನ್ನು ತೆಗೆದುಹಾಕಲಾಗುವುದು."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"ಅತಿಥಿಯನ್ನು ತೆಗೆದುಹಾಕುವುದೇ?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ಈ ಸೆಷನ್‌ನಲ್ಲಿನ ಎಲ್ಲ ಅಪ್ಲಿಕೇಶನ್‌ಗಳು ಮತ್ತು ಡೇಟಾವನ್ನು ಅಳಿಸಲಾಗುತ್ತದೆ."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ತೆಗೆದುಹಾಕಿ"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"ಮತ್ತೆ ಸುಸ್ವಾಗತ, ಅತಿಥಿ!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ಒಂದು ನಿಮಿಷದವರೆಗೆ"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d ನಿಮಿಷಗಳವರೆಗೆ"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ಒಂದು ಗಂಟೆಯವರೆಗೆ"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d ಗಂಟೆಗಳವರೆಗೆ"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"ನಿಮ್ಮ ಸೆಷನ್‌ ಮುಂದುವರಿಸಲು ಇಚ್ಚಿಸುವಿರಾ?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"ಪ್ರಾರಂಭಿಸಿ"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"ಹೌದು, ಮುಂದುವರಿ"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"ಹೊಸ ಬಳಕೆದಾರರನ್ನು ಸೇರಿಸುವುದೇ?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"ನೀವು ಒಬ್ಬ ಹೊಸ ಬಳಕೆದಾರರನ್ನು ಸೇರಿಸಿದಾಗ, ಆ ವ್ಯಕ್ತಿಯು ಅವರ ಸ್ಥಳವನ್ನು ಸ್ಥಾಪಿಸಬೇಕಾಗುತ್ತದೆ.\n\nಯಾವುದೇ ಬಳಕೆದಾರರು ಎಲ್ಲಾ ಇತರೆ ಬಳಕೆದಾರರಿಗಾಗಿ ಅಪ್ಲಿಕೇಶನ್‌ಗಳನ್ನು ನವೀಕರಿಸಬಹುದು."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ಬ್ಯಾಟರಿ ರಕ್ಷಕ ಆನ್ ಆಗಿದೆ"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ಕಾರ್ಯಕ್ಷಮತೆ ಮತ್ತು ಹಿನ್ನೆಲೆ ಡೇಟಾವನ್ನು ಕಡಿಮೆ ಮಾಡುತ್ತದೆ"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ಬ್ಯಾಟರಿ ಉಳಿತಾಯವನ್ನು ಆಫ್ ಮಾಡಿ"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"ಈಗ ಪ್ರಾರಂಭಿಸಿ"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"ಯಾವುದೇ ಅಧಿಸೂಚನೆಗಳಿಲ್ಲ"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ಸಾಧನವನ್ನು ಪರಿವೀಕ್ಷಿಸಬಹುದಾಗಿದೆ"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ಪ್ರೊಫೈಲ್ ಅನ್ನು ಪರಿವೀಕ್ಷಿಸಬಹುದಾಗಿದೆ"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"ನೆಟ್‌ವರ್ಕ್ ಅನ್ನು ವೀಕ್ಷಿಸಬಹುದಾಗಿ"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ಸಾಧನ ಪರಿವೀಕ್ಷಣೆ"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"ಪ್ರೊಫೈಲ್ ಮೇಲ್ವಿಚಾರಣೆ"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ನೆಟ್‌ವರ್ಕ್‌ ಪರಿವೀಕ್ಷಣೆ"</string>
-    <string name="open_app" msgid="4011771120339160755">"ಅಪ್ಲಿಕೇಶನ್ ತೆರೆಯಿರಿ"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಿ"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN ಸಂಪರ್ಕಕಡಿತಗೊಳಿಸಿ"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ಈ ಸಾಧನವನ್ನು ಇವರು ನಿರ್ವಹಿಸಿದ್ದಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್‌ ಚಟುವಟಿಕೆಯನ್ನು ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು.\n\nಇನ್ನಷ್ಟು ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"ನೀವು VPN ಸಂಪರ್ಕ ಹೊಂದಿಸಲು \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ಗೆ ಅನುಮತಿ ನೀಡಿರುವಿರಿ.\n\n ಈ ಅಪ್ಲಿಕೇಶನ್ ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"ನೀವು VPN ಗೆ ಸಂಪರ್ಕಗೊಂಡಿರುವಿರಿ (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nನಿಮ್ಮ VPN ಸೇವೆ ಒದಗಿಸುವವರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ಇವರು ಈ ಸಾಧನವನ್ನು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೇ, ನೀವು VPN ಸಂಪರ್ಕ ಹೊಂದಿಸಲು \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ಗೆ ಅನುಮತಿ ನೀಡಿರುವಿರಿ. ಈ ಅಪ್ಲಿಕೇಶನ್ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನು ಸಹ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ಇವರು ಈ ಸಾಧನವನ್ನು ಇವರು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೇ, ನೀವು VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") ಗೆ ಸಂಪರ್ಕಗೊಂಡಿರುವಿರಿ. ನಿಮ್ಮ VPN ಸೇವೆ ಒದಗಿಸುವವರು ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನು ಸಹ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ಈ ಪ್ರೊಫೈಲ್ ಅನ್ನು ಇವರು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ಸಾಧನ ಮತ್ತು ನೆಟ್‌ವರ್ಕ್‌ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು.\n\nಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿರಿ."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ಈ ಸಾಧನವನ್ನು ಇವರಿಂದ ನಿರ್ವಹಿಸಲಾಗಿದೆ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nನಿಮ್ಮ ಪ್ರೊಫೈಲ್ ಇವರಿಂದ ನಿರ್ವಹಿಸಲಾಗಿದೆ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ಸಾಧನ ಹಾಗೂ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು.\n\nಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ಇವರು ಈ ಪ್ರೊಫೈಲ್ ಅನ್ನು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n.ನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್‌ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಹೊಂದಿದ್ದಾರೆ. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೆ, VPN ಗೆ ಸಂಪರ್ಕವನ್ನು ಹೊಂದಿಸಲು ನೀವು \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ಗೆ ಅನುಮತಿಸಿರುವಿರಿ. ಈ ಅಪ್ಲಿಕೇಶನ್ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನು ಸಹ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ಈ ಪ್ರೊಫೈಲ್ ಅನ್ನು ಇವರು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಹೊಂದಿದ್ದಾರೆ. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೆ, ನೀವು VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") ಗೆ ಗೆ ಸಂಪರ್ಕವನ್ನು ಹೊಂದಿರುವಿರಿ. ನಿಮ್ಮ VPN ಸೇವೆ ಪೂರೈಕೆದಾರರು ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನೂ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ಈ ಸಾಧನವನ್ನು ಇವರು ನಿರ್ವಹಿಸುತ್ತಾರೆ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nನಿಮ್ಮ ಪ್ರೊಫೈಲ್ ಇವರಿಂದ ನಿರ್ವಹಿಸಲಾಗಿದೆ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n.ನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು, ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್‌ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಹೊಂದಿದ್ದಾರೆ. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೆ, VPN ಗೆ ಸಂಪರ್ಕವನ್ನು ಹೊಂದಿಸಲು ನೀವು \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ಗೆ ಅನುಮತಿಸಿರುವಿರಿ. ಈ ಅಪ್ಲಿಕೇಶನ್ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನು ಸಹ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ಈ ಸಾಧನವನ್ನು ಇವರಿಂದ ನಿರ್ವಹಿಸಲಾಗಿದೆ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nನಿಮ್ಮ ಪ್ರೊಫೈಲ್ ಅನ್ನು ಇವರಿಂದ ನಿರ್ವಹಿಸಲಾಗಿದೆ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nನಿಮ್ಮ ನಿರ್ವಾಹಕರು ಇಮೇಲ್‌ಗಳು, ಅಪ್ಲಿಕೇಶನ್‌ಗಳು ಮತ್ತು ಸುರಕ್ಷಿತ ವೆಬ್‌ಸೈಟ್‌ಗಳನ್ನು ಒಳಗೊಂಡಂತೆ ನಿಮ್ಮ ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡುವ ಸಾಮರ್ಥ್ಯವನ್ನು ಹೊಂದಿದ್ದಾರೆ. ಹೆಚ್ಚಿನ ಮಾಹಿತಿಗಾಗಿ, ನಿಮ್ಮ ನಿರ್ವಾಹಕರನ್ನು ಸಂಪರ್ಕಿಸಿ.\n\nಅಲ್ಲದೆ, ನೀವು VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") ಗೆ ಸಂಪರ್ಕವನ್ನು ಹೊಂದಿರುವಿರಿ. ನಿಮ್ಮ VPN ಸೇವೆ ಪೂರೈಕೆದಾರರು ನೆಟ್‌ವರ್ಕ್ ಚಟುವಟಿಕೆಯನ್ನೂ ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಬಹುದು."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"ನೀವಾಗಿಯೇ ಅನ್‌ಲಾಕ್‌ ಮಾಡುವವರೆಗೆ ಸಾಧನವು ಲಾಕ್‌ ಆಗಿಯೇ ಇರುತ್ತದೆ"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"ವೇಗವಾಗಿ ಅಧಿಸೂಚನೆಗಳನ್ನು ಪಡೆದುಕೊಳ್ಳಿ"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ನೀವು ಅನ್‌ಲಾಕ್‌ ಮಾಡುವ ಮೊದಲೇ ಅವುಗಳನ್ನು ನೋಡಿ"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"ಬೇಡ ಧನ್ಯವಾದಗಳು"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"ಹೊಂದಿಸು"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> ಅವರಿಂದ ಮ್ಯೂಟ್‌ ಮಾಡಲಾಗಿದೆ"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ko/strings.xml b/packages/SystemUI/res/values-ko/strings.xml
index fa2d05c..6a39c1a 100644
--- a/packages/SystemUI/res/values-ko/strings.xml
+++ b/packages/SystemUI/res/values-ko/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"지우기"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"목록에서 삭제"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"앱 정보"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"여기에 최근 화면이 표시됩니다."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"최근에 사용한 앱 숨기기"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"최근에 사용한 앱 1개"</item>
@@ -83,11 +82,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"뒤로"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"홈"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"메뉴"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"최근 화면"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"검색"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"카메라"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"전화"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"잠금 해제"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"잠금 해제"</string>
+    <string name="phone_label" msgid="2320074140205331708">"휴대전화 열기"</string>
+    <string name="camera_label" msgid="7261107956054836961">"카메라 열기"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"입력 방법 버튼을 전환합니다."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"호환성 확대/축소 버튼입니다."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"작은 화면을 큰 화면으로 확대합니다."</string>
@@ -114,6 +116,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi 신호 막대가 두 개입니다."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi 신호 막대가 세 개입니다."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi 신호가 강합니다."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>에 연결되었습니다."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>에 연결되었습니다."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX가 없습니다."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX 신호 막대가 하나입니다."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX 신호 막대가 두 개입니다."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"전신 타자기(TTY)가 사용 설정되었습니다."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"벨소리가 진동입니다."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"벨소리가 무음입니다."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>을(를) 숨깁니다."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g>이(가) 제거되었습니다."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>을(를) 시작하는 중입니다."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"알림이 제거되었습니다."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"알림 세부정보"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"빠른 설정"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"화면을 잠급니다."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"설정"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"최근 화면"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"사용자 <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi가 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi를 사용합니다."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"모바일 <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"배터리 <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"비행기 모드가 <xliff:g id="STATE">%s</xliff:g> 상태입니다."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"블루투스 <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"위치 <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"비행기 모드: 사용 안함"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"비행기 모드: 사용"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"비행기 모드가 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"비행기 모드를 사용합니다."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"블루투스: 사용 안함"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"블루투스: 사용"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"블루투스에 연결 중입니다."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"블루투스가 연결되었습니다."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"블루투스가 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"블루투스를 사용합니다."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"위치 정보 전송: 사용 안함"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"위치 정보 전송: 사용"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"위치 정보 전송이 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"위치 정보 전송을 사용합니다."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"알람이 <xliff:g id="TIME">%s</xliff:g>(으)로 설정되었습니다."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"패널 닫기"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"시간 늘리기"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"시간 줄이기"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"패널을 닫습니다."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"시간 늘리기"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"시간 줄이기"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"손전등: 사용 중지"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"손전등: 사용"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"손전등이 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"손전등을 사용합니다."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"색상 반전이 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"색상 반전을 사용합니다."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"모바일 핫스팟이 사용 중지되었습니다."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"모바일 핫스팟을 사용합니다."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"화면 전송이 중지되었습니다."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"디스플레이 밝기"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G 데이터 사용 중지됨"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G 데이터 사용 중지됨"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"이동통신 데이터 사용 중지됨"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS에서 위치 설정"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"위치 요청 있음"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"모든 알림 지우기"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"설정"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"알림 설정"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> 설정"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"화면이 자동으로 회전됩니다."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"화면이 가로 방향으로 잠겨 있습니다."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"화면이 세로 방향으로 잠겨 있습니다."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"화면이 자동으로 회전합니다."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"화면이 가로 방향으로 잠깁니다."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"화면이 세로 방향으로 잠깁니다."</string>
     <string name="dessert_case" msgid="1295161776223959221">"디저트 케이스"</string>
     <string name="start_dreams" msgid="7219575858348719790">"화면 보호기"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"이더넷"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"모바일 데이터"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"데이터 사용"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"잔여 데이터"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"한도 초과"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"한도에 도달 – 데이터 사용 일시중지됨"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> 사용됨"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"한도: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> 경고"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"여기에 최근 화면이 표시됩니다."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"애플리케이션 정보"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"앱에 잠금"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"검색"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"검색"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>하려면 위로 슬라이드"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>하려면 왼쪽으로 슬라이드"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"방해 금지(알람 포함)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"어떤 방해도 받지 않습니다. 알람도 울리지 않습니다."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"모든 알림 차단"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"최우선 알림만 수신"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"다음 알람 시각: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g>에 알람을 들을 수 없습니다."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"아래에 덜 급한 알림 표시"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"다시 터치하여 열기"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"위로 스와이프하여 잠금 해제"</string>
     <string name="phone_hint" msgid="3101468054914424646">"전화 기능을 사용하려면 오른쪽으로 스와이프하세요."</string>
     <string name="camera_hint" msgid="5241441720959174226">"카메라를 사용하려면 왼쪽으로 스와이프하세요."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"무제한"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"수신 안함"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"최우선만 수신"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"모두 수신"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"충전 중(<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> 후 충전 완료)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"사용자 전환"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"사용자 전환, 현재 사용자 <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"프로필 표시"</string>
     <string name="user_add_user" msgid="5110251524486079492">"사용자 추가"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"새 사용자"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"손님"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"게스트 추가"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"손님 삭제"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"손님 세션을 종료하시겠습니까?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"손님 세션을 종료하면 로컬 데이터가 삭제됩니다."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"손님을 삭제하시겠습니까?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"이 세션에 있는 모든 앱과 데이터가 삭제됩니다."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"삭제"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"손님 세션 다시 시작"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1분 동안"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d분 동안"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1시간 동안"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d시간 동안"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"세션을 계속 진행하시겠습니까?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"다시 시작"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"예, 계속합니다."</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"새 사용자를 추가할까요?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"추가된 새로운 사용자는 자신의 공간을 설정해야 합니다.\n\n모든 사용자는 다른 사용자들을 위하여 앱을 업데이트할 수 있습니다."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"배터리 세이버 사용 중"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"성능 및 백그라운드 데이터를 줄입니다."</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"배터리 절약 기능 사용 중지"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"시작하기"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"알림 없음"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"기기가 모니터링될 수 있음"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"프로필이 모니터링될 수 있음"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"네트워크가 모니터링될 수 있음"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"기기 모니터링"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"프로필 모니터링"</string>
     <string name="monitoring_title" msgid="169206259253048106">"네트워크 모니터링"</string>
-    <string name="open_app" msgid="4011771120339160755">"앱 열기"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN 사용 중지"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN 연결 해제"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"이 기기는 \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n에서 관리합니다. 관리자가 이메일, 앱 및 보안 웹사이트 등의 네트워크 활동을 모니터링할 수 있습니다.\n\n자세한 내용은 관리자에게 문의하세요."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"\'<xliff:g id="APPLICATION">%1$s</xliff:g>\'에 VPN 연결을 설정할 수 있는 권한을 부여했습니다.\n\n이 앱에서 내 기기와 이메일과 앱, 보안 웹사이트 등의 네트워크 활동을 모니터링할 수 있습니다."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN(\'<xliff:g id="APPLICATION">%1$s</xliff:g>\')에 연결되었습니다.\n\nVPN 서비스 제공업체에서 내 기기와 이메일, 앱, 보안 웹사이트 등의 네트워크 활동을 모니터링할 수 있습니다."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"이 기기는 \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>에서 관리합니다.\n\n관리자가 이메일, 앱, 보안 웹사이트 등의 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 \'<xliff:g id="APPLICATION">%2$s</xliff:g>\'에 VPN 연결을 설정할 수 있는 권한을 부여했습니다. 이 앱에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"이 기기는 \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>에서 관리합니다.\n\n관리자가 이메일, 앱, 보안 웹사이트 등의 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 VPN에도 연결되었습니다(\'<xliff:g id="APPLICATION">%2$s</xliff:g>\'). VPN 서비스 제공업체에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"프로필 관리자:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 네트워크 활동과 내 기기를 모니터링할 수 있습니다.\n\n자세한 정보는 관리자에게 문의하세요."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"기기 관리자:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n프로필 관리자:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 네트워크 활동과 내 기기를 모니터링할 수 있습니다.\n\n자세한 정보는 관리자에게 문의하세요."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"프로필 관리자:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 내 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 \'<xliff:g id="APPLICATION">%2$s</xliff:g>\'에 VPN 연결을 설정할 수 있는 권한을 부여했습니다. 이 앱에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"프로필 관리자:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 내 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 현재 VPN(\'<xliff:g id="APPLICATION">%2$s</xliff:g>\')에 연결되어 있습니다. VPN 서비스 제공업체에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"기기 관리자:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n프로필 관리자:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 내 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 \'<xliff:g id="APPLICATION">%3$s</xliff:g>\'에 VPN 연결을 설정할 수 있는 권한을 부여했습니다. 이 앱에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"기기 관리자:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n프로필 관리자:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n관리자는 이메일, 앱, 보안 웹사이트를 비롯한 내 네트워크 활동을 모니터링할 수 있습니다. 자세한 정보는 관리자에게 문의하세요.\n\n또한 현재 VPN(\'<xliff:g id="APPLICATION">%3$s</xliff:g>\')에 연결되어 있습니다. VPN 서비스 제공업체에서도 네트워크 활동을 모니터링할 수 있습니다."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"수동으로 잠금 해제할 때까지 기기가 잠금 상태로 유지됩니다."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"알림을 더욱 빠르게 받기"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"잠금 해제하기 전에 알림을 봅니다."</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"사용 안함"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"설정"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g>에서 알림음 음소거"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ky-rKG/strings.xml b/packages/SystemUI/res/values-ky-rKG/strings.xml
index d3fc508..c11f2cf 100644
--- a/packages/SystemUI/res/values-ky-rKG/strings.xml
+++ b/packages/SystemUI/res/values-ky-rKG/strings.xml
@@ -25,8 +25,7 @@
     <skip />
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Тизмеден алып салуу"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Колдонмо тууралуу"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Акыркы экрандарыңыз бул жерден көрүнөт"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Акыркы колдонмолорду жок кылуу"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 акыркы колдонмо"</item>
@@ -107,11 +106,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Артка"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Үйгө"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Акыркы экрандар"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Издөө"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Кулпусун ачуу"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"кулпуну ачуу"</string>
+    <string name="phone_label" msgid="2320074140205331708">"телефонду ачуу"</string>
+    <string name="camera_label" msgid="7261107956054836961">"камераны ачуу"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Киргизүү ыкмасын которуу баскычы."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Масштабды сыйыштыруу баскычы."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Кичинекейди чоң экранга масштабдоо."</string>
@@ -138,6 +140,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi эки таякча."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi үч таякча."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi сигналы толук."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> менен туташкан."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> менен туташкан."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX туташуусу жок."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX бир таякча."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX эки таякча."</string>
@@ -177,28 +181,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"ТелеТайп терүүсү жандырылган."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Шыңгыраганда титирөө."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Үнсүз шыңгыроо."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> этибарга албоо."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> жок болду."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> иштеп баштоодо."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Эскертме жок кылынды."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Эскертмелер көшөгөсү."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Тез тууралоолор."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Кулпуланган экран."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Жөндөөлөр"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Акыркы экрандар."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Колдонуучу <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi күйгүзүлдү."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобилдик түйүн <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батарей: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Учак тартиби <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Жайгаштыруу <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Учак режими өчүк."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Учак режими күйүк."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Учак режими өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Учак режими күйгүзүлдү."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth өчүк."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth күйүк."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth туташууда."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth туташты."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth күйгүзүлдү."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Жайгашкан жерди кабарлоо өчүк."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Жайгашкан жерди кабарлоо күйүк."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Жайгашкан жерди кабарлоо өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Жайгашкан жерди кабарлоо күйгүзүлдү."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Ойготкуч кийинкиге коюлган: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Тактаны жабуу"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Көбүрөөк убакыт"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Азыраак убакыт"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Тактаны жабуу."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Көбүрөөк убакыт."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Азыраак убакыт."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Колчырак өчүк."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Колчырак күйүк."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Колчырак өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Колчырак күйгүзүлдү."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Түстү өзгөртүү аракети өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Түстү өзгөртүү аракети күйгүзүлдү."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобилдик байланыш түйүнү өчүрүлдү."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобилдик байланыш түйүнү күйгүзүлдү."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Тышкы экранга чыгаруу аракети токтотулду."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Жарыктыгын көрсөтүү"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2Гб-3Гб көлөмдөгү дайындар өчүрүлдү."</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4Гб көлөмдөгү дайындар өчүрүлдү"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Уюктук дайындар тармагы өчүк"</string>
@@ -211,10 +238,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS боюнча аныкталган жайгашуу"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Жайгаштыруу талаптары иштелүүдө"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Бардык эскертмелерди тазалоо."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Жөндөөлөр"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Эскертме жөндөөлөрү"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> жөндөөлөрү"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Экран автоматтык түрдө бурулат."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Экран туурасынан турган бойдон бекитилген."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Экран тикесинен турган бойдон бекитилген."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Экран эми автоматтык түрдө айланып турат."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Экран азыр туурасынан кулпуланган."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Экран азыр тигинен кулпуланган."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Десерт себети"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Кыялдануу"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -266,12 +297,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Дайындарды өткөрүүчү уюктук тутум"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Дайындарды колдонуу"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Калган дайындар"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Чектен ашты"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Чегине жетти – дайындарды пайдалануу бир азга токтотулду"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> колдонулду"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> чектөө"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> эскертүү"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Акыркы экрандарыңыз бул жерден көрүнөт"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Колдонмо жөнүндө маалымат"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"колдонмого кулпулоо"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"издөө"</string>
@@ -283,7 +313,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Издөө"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> үчүн жогору жылмыштырыңыз."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> үчүн солго жылмыштырыңыз."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Үзгүлтүктөр, ошондой эле үн ишараттары болбойт"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Үзгүлтүктөр жок. Ойготкучтар дагы жок."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Үзгүлтүксүз"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Артыкчылыктуу үзгүлтүктөр гана"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Кийинки үн ишараты саат <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -291,43 +321,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Саат <xliff:g id="ALARM_TIME">%s</xliff:g> үн ишаратын укпайсыз."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Анчейин шашылыш эмес эскертмелер төмөндө"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Ачуу үчүн кайра тийиңиз"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Кулпуну ачуу үчүн серпип коюңуз"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Телефонду колдонуу үчүн оңго серпип коюңуз"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Камераны ачуу үчүн солго серпип коюңуз"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Белгисиз"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Эч нерсе жок"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Артыкчылыктуу"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Бардыгы"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Кубатталууда (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> толгонго чейин)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Колдонуучуну которуу"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Колдонуучуну күйгүзүү, учурдагы колдонуучу <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Профилди көрсөтүү"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Колдонуучу кошуу"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Жаңы колдонуучу"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Конок"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Конок кошуу"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Конокту алып салуу"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Конок сеансынан чыгасызбы?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Конок сеансынан чыкканда, жергиликтүү дайындар өчүрүлөт."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Конокту алып саласызбы?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Бул сеанстагы бардык колдонмолор жана дайындар жок кылынат."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Алып салуу"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Кайтып келишиңиз менен, конок!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Бир мүнөткө"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d мүнөткө"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Бир саатка"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d саатка"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Сеансыңызды улантасызбы?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Кайра баштоо"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ооба, уланта берели"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Жаңы колдонуучу кошосузбу?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Жаңы колдонуучу кошулганда, ал өз мейкиндигин түзүп алышы керек.\n\nКолдонмолорду бир колдонуучу жаңыртканда, ал калган бардык колдонуучулар үчүн да жаңырат."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Батареяны үнөмдөгүч күйгүзүлдү"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Иштин майнаптуулугун начарлатып, фондук дайындарды чектейт"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Батареянын кубатын үнөмдөгүчтү өчүрүп коюу"</string>
@@ -339,16 +357,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Азыр баштоо"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Эскертмелер жок"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Түзмөктү көзөмөлдөсө болот"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профилди көзөмөлдөсө болот"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Тармак көзөмөлдөнүшү мүмкүн"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Түзмөккө көз салуу"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Профилди көзөмөлдөө"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Тармакка көз салуу"</string>
-    <string name="open_app" msgid="4011771120339160755">"Колдонмону ачуу"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN\'ди өчүрүү"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN\'ди ажыратуу"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Бул түзмөк төмөнкү тарабынан башкарылат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторуңуз түзмөгүңүздү жана тармактагы аракетиңизди, анын ичинде email-дер, колдонмолор жана коопсуз вебсайттарды көзөмөлдөй алат.\n\nКөбүрөөк маалымат үчүн администраторуңузга кайрылыңыз."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"\"<xliff:g id="APPLICATION">%1$s</xliff:g>\" VPN туташуу орнотуусуна уруксат бердиңиз.\n\nБул колдонмо түзмөгүңүздү жана тармактагы аракетиңизди, анын ичинде email-дер, колдонмолор жана коопсуз вебсайттарды көзөмөлдөй алат."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Сиз VPN-ге туташкансыз (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nVPN кызмат камсыздоочуңуз түзмөгүңүздү жана тармактагы аракетиңизди, анын ичинде email-дер, колдонмолор жана коопсуз вебсайттарды көзөмөлдөй алат."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Бул түзмөк төмөнкүчө башкарылат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор электрондук почталар, колдонмолор жана коопсуз вебсайттар сыяктуу тармактгы аракеттрге көз салып турт. Көбүрөөк билүү үчн, администратрго кайрылңз.\n\nОшондой эле \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" VPN туташуусн орнотууга урукст бердиңз. Бул колдонмо тармактгы аракеттерңзге дагы көз салат."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Бул түзмөк төмөнкүчө башкарылат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор электрондук почта, колдонмолор жана коопсуз вебсайттар сыяктуу тармактагы аракеттериңизге көз салып турат. Көбүрөөк билүү үчүн, администраторго кайрылыңыз.\n\nОшондой эле VPN\'ге туташып турасыз. (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). VPN кызмат көрсөтүүчү тармактагы аракетиңизге көз салат."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Бул профилди төмөнкү башкарат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторңуз түзмөгүңүз жана тармактагы аракетиңизди, анын ичинде email-дер, колдонмолор жана коопсуз вебсайттарды, көзөмөлдөй алат.\n\nДагы маалымат үчүн, администраторуңузга кайрылыңыз."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Бул түзмөктү төмөнкү башкарат:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПрофилиңизди төмөнкү башкарат:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистраторуңуз түзмөгүңүз жана тармактагы аракетиңизди, анын ичинде email-дер, колдонмолор жана коопсуз вебсайттарды, көзөмөлдөй алат.\n\nДагы маалымат үчүн, администраторуңузга кайрылыңыз."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Бул профилди төмөнкү башкарат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдмин-ңуздун тармак ар-ңизди, анын ичинде email-дер, колд-лор жана коопсуз вебсайттарды, көзөмөлдөө мүмкүнчүлүгү бар. Дагы маалымат үчүн, админ-ңузга кайрылыңыз.\n\n\"<xliff:g id="APPLICATION">%2$s</xliff:g>\" VPN туташуусун орнотуусуна да уруксат бердиңиз. Бул колдонмо тармак аракетин да көзөмөлдөй алат."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Бул профилди төмөнкү башкарат:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдмин-ңуздун тармак ар-ңизди, анын ичинде email-дер, колд-лор жана коопсуз вебсайттарды, көзөмөлдөө мүмкүнчүлүгү бар. Дагы маалымат үчүн, админ-ңузга кайрылыңыз.\n\nСиз VPN-ге (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") да туташкансыз. VPN тейлөөчүңүз да тармак аракетин көзөмөлдөй алат."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Бул түзмөктү төмөнкү башк-т:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПрофилиңизди төмөнкү башк-т:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдмин-ңуздун тармак ар-ңизди, анын ичинде email-дер, колд-лор жана коопсуз вебс-ды, көз-дөө мүмк-гү бар. Дагы маалымат үчүн, админ-ңузга кайр-з.\n\n\"<xliff:g id="APPLICATION">%3$s</xliff:g>\" VPN туташуусун орнотуусуна да уруксат бердиңиз. Бул колдонмо тармак аракетин да көзөмөлдөй алат."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Түзмөктү тө-кү башк-т:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nПрофилди тө-кү башк-т:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдмин-ңуздун тармак ар-ңизди, анын ичинде email-дер, колд-лор жана коопсуз вебс-ды, көзөмөлдөө мүмкүнчүлүгү бар. Дагы маалымат үчүн, админ-ңузга кайрылыңыз.\n\nСиз VPN-ге (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") да туташкансыз. VPN тейлөөчүңүз да тармак аракетин көзөмөлдөй алат."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Түзмөктүн кулпусу кол менен ачылмайынча кулпуланган бойдон алат"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Эскертмелерди тезирээк алуу"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Аларды кулпудан чыгараардан мурун көрүңүз"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Жок, рахмат"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Орнотуу"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> тарабынан үнсүздөлдү"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-land/dimens.xml b/packages/SystemUI/res/values-land/dimens.xml
index 9b772bd..a9e7735 100644
--- a/packages/SystemUI/res/values-land/dimens.xml
+++ b/packages/SystemUI/res/values-land/dimens.xml
@@ -39,7 +39,7 @@
     <dimen name="status_bar_recents_app_icon_top_margin">8dp</dimen>
 
     <!-- The side padding for the task stack as a percentage of the width. -->
-    <item name="recents_stack_width_padding_percentage" format="float" type="dimen">0.2229</item>
+    <item name="recents_stack_width_padding_percentage" format="float" type="dimen">0.26</item>
 
     <!-- Standard notification width + gravity -->
     <dimen name="notification_panel_width">@dimen/standard_notification_panel_width</dimen>
diff --git a/packages/SystemUI/res/values-land/styles.xml b/packages/SystemUI/res/values-land/styles.xml
index 682998d..e58fbb1 100644
--- a/packages/SystemUI/res/values-land/styles.xml
+++ b/packages/SystemUI/res/values-land/styles.xml
@@ -19,18 +19,6 @@
         <item name="android:layout_width">360dp</item>
     </style>
 
-    <style name="SearchPanelCard">
-        <item name="android:layout_width">@dimen/search_panel_card_height</item>
-        <item name="android:layout_height">match_parent</item>
-        <item name="android:layout_marginTop">16dp</item>
-        <item name="android:layout_marginBottom">16dp</item>
-        <item name="android:layout_gravity">right</item>
-    </style>
-
-    <style name="SearchPanelLogo">
-        <item name="android:layout_gravity">top|left</item>
-    </style>
-
     <style name="SearchPanelScrim">
         <item name="android:layout_width">@dimen/search_panel_scrim_height</item>
         <item name="android:layout_height">match_parent</item>
diff --git a/packages/SystemUI/res/values-lo-rLA/strings.xml b/packages/SystemUI/res/values-lo-rLA/strings.xml
index f7dfb89..fdc0a602 100644
--- a/packages/SystemUI/res/values-lo-rLA/strings.xml
+++ b/packages/SystemUI/res/values-lo-rLA/strings.xml
@@ -84,6 +84,10 @@
     <string name="accessibility_search_light" msgid="1103867596330271848">"ຊອກຫາ"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ກ້ອງ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ໂທລະສັບ"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ປົດລັອກ"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ປົດລັອກ"</string>
+    <string name="phone_label" msgid="2320074140205331708">"​ເປີດ​​ແປ້ນ​ໂທ​ລະ​ສັບ"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ເປີດ​ກ້ອງ"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ປຸ່ມສະລັບຮູບແບບການປ້ອນຂໍ້ມູນ."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"ປຸ່ມຊູມທີ່ໃຊ້ຮ່ວມກັນໄດ້."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ຊູມຈໍນ້ອຍໄປເປັນຈໍຂະຫນາດໃຫຍ່."</string>
@@ -110,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"ສັນຍານ Wi-Fi ສອງຂີດ."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi ສາມຂີດ."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"ສັນຍານ Wi-Fi ເຕັມ"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"ເຊື່ອມ​ຕໍ່​ຫາ <xliff:g id="WIFI">%s</xliff:g> ແລ້ວ."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"ເຊື່ອມ​ຕໍ່​ຫາ <xliff:g id="BLUETOOTH">%s</xliff:g> ແລ້ວ."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"ບໍ່ມີ WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ນຶ່ງຂີດ."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX ສອງຂີດ."</string>
@@ -149,27 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter ຖືກເປີດຢູ່."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"ສັ່ນເຕືອນພ້ອມສຽງເອີ້ນເຂົ້າ."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"ປິດສຽງ."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"ປິດ <xliff:g id="APP">%s</xliff:g> ໄວ້."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"ປິດ <xliff:g id="APP">%s</xliff:g> ແລ້ວ."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"ກຳ​ລັງ​ເປີດ <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"ປິດການແຈ້ງເຕືອນແລ້ວ."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"ໜ້າຈໍແຈ້ງເຕືອນ."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ການຕັ້ງຄ່າດ່ວນ."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ລັອກ​ໜ້າ​ຈໍ."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ການ​ຕັ້ງ​ຄ່າ"</string>
     <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"ໜ້າ​ຈໍ​​ເມື່ອບໍ່​ດົນ​ມາ​ນີ້."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ຜູ່ໃຊ້ <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"ປິດ Wi-Fi ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"ເປີດ Wi-Fi ແລ້ວ."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"ມືຖື <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ແບັດເຕີຣີ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"ໂໝດໃນຍົນ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"ສະ​ຖານ​ທີ່ <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"ປິດ​ໂໝດ​ຢູ່​ໃນ​ຍົນ."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"ເປີດ​ໂໝດ​ຢູ່​ໃນ​ຍົນ."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"ປິດ​ໂໝດ​ຢູ່​ໃນ​ຍົນ​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"ເປີດ​ໂໝດ​ຢູ່​ໃນ​ຍົນ​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth ປິດ."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth ເປີດ."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ກຳ​ລັງ​ເຊື່ອມ​ຕໍ່ Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"ເຊື່ອມຕໍ່ Bluetooth ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ປິດ Bluetooth ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ເປີດ Bluetooth ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"​ການ​ລາຍ​ງານ​ສະ​ຖານ​ທີ່​ປິດ."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"​ການ​ລາຍ​ງານ​ສະ​ຖານ​ທີ່​ເປີດ."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"ປິດ​ການ​ລາຍ​ງານ​ສະ​ຖານ​ທີ່​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"ເປີດ​ການ​ລາຍ​ງານ​ສະ​ຖານ​ທີ່​ແລ້ວ."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"ຕັ້ງໂມງປຸກ <xliff:g id="TIME">%s</xliff:g> ແລ້ວ."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"​ປິດ​ແຖບ"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"​ເພີ່ມ​ເວ​ລາ"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"ຫຼຸດ​ເວ​ລາ"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ປິດ​ແຖບ."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"​ເພີ່ມ​ເວ​ລາ."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"ຫຼຸດ​ເວ​ລາ."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ໄຟ​ສາຍ​ປິດ."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ໄຟ​ສາຍ​ເປີດ."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ປິດ​ໄຟ​ສາຍ​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"​ເປີດ​ໄຟ​ສາຍ​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"​ປິດ​ການ​ສະ​ລັບ​ສີ."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"ເປີດ​ການ​ສຳ​ລັບ​ສີ."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"ປິດ​ຮັອດ​ສະ​ປອດ​ເຄື່ອນ​ທີ່​ແລ້ວ."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"ເປີດ​ຮັອດ​ສະ​ປອດ​ເຄື່ອນ​ທີ່​ແລ້ວ."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"ຢຸດ​ການ​ສົ່ງ​​ພາບ​ໜ້າ​ຈໍ​ແລ້ວ."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"​ຄວາມ​ແຈ້ງ​​ຂອງ​ຈໍ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"ຂໍ້​ມູນ 2G-3G ​ແມ່ນ​ປິດ"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"ຂໍ້​ມູນ 4G ແມ່ນ​ປິດ"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ຂໍ້​ມູ​ນມ​ື​ຖື​ຖືກ​ປິດ"</string>
@@ -182,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"ສະຖານທີ່ກຳນົດໂດຍ GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"ການຮ້ອງຂໍສະຖານທີ່ທີ່ເຮັດວຽກຢູ່"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"ລຶບການແຈ້ງເຕືອນທັງໝົດ."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ການ​ຕັ້ງ​ຄ່າ"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"​ການ​ຕັ້ງ​ຄ່າ​ການ​ແຈ້ງ​ເຕືອນ"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"ການ​ຕັ້ງ​ຄ່າ <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"ໜ້າຈໍຈະໝຸນໂດຍອັດຕະໂນມັດ."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ໜ້າຈໍຖືກລັອກໃນລວງນອນ."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ໜ້າຈໍຖືກລັອກຢູ່ໃນໂໝດແນວຕັ້ງ."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"​ໜ້າ​ຈໍ​ຈະ​​ໝຸນ​ອັດ​ຕະ​ໂນ​ມັດ."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ໜ້າ​ຈໍ​ຕອນ​ນີ້​ຖືກ​ລັອກ​ໄວ້​ໃນ​ລວງ​ນອນ."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ໜ້າ​ຈໍ​ຕອນ​ນີ້​ຖືກ​ລັອກ​ໄວ້​ໃນ​ລວງ​ຕັ້ງ."</string>
     <string name="dessert_case" msgid="1295161776223959221">"ກ່ອງຂອງຫວານ"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -237,7 +271,7 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"​ຂໍ້​ມູນ​ອິນ​ເຕີ​ເນັດ​ມື​ຖື"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"​ການ​​ນຳ​ໃຊ້​​ຂໍ້​ມູນ"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"​ຂໍ້​ມູນ​ທີ່​ຍັງ​ເຫຼືອ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"​ເກີນ​ຂີດ​ຈຳ​ກັດ"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ໃຊ້​ຂໍ້​ມູນ​ຮອດ​ຈຳ​ນວນ​ທີ່​ຈຳ​ກັດ​ແລ້ວ – ຢຸດ​ການ​ນຳ​ໃຊ້​ຂໍ້​ມູນ​ຊົ່ວ​ຄາວ"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"ໃຊ້​ໄປ​ແລ້ວ <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"ຈຳ​ກັດ <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"ຄຳ​ເຕືອນ <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
@@ -253,70 +287,72 @@
     <string name="description_target_search" msgid="3091587249776033139">"ຊອກຫາ"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"ເລື່ອນຂຶ້ນເພື່ອ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"ເລື່ອນໄປທາງຊ້າຍເພື່ອ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ບໍ່​ມີ​ການ​ລົບ​ກວນດ ຮວມ​ເຖິງ​ໂມງ​ປຸກ​ນຳ"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ບໍ່​ມີ​ການ​ລົບ​ກວນ. ບໍ່​ວ່າ​ຈະ​ເປັນ​​ໂມງ​ປຸກ​ກໍ​ຕາມ."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"ບໍ່​ມີ​ການ​ລົບກວນ"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"ການ​ລົບກວນ​ທີ່​ສຳຄັນ​ເທົ່າ​ນັ້ນ"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"ສະເພາະ​ເລື່ອງ​ສຳຄັນ​ເທົ່ານັນ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ໂມງ​ປຸກ​ຖັດ​ໄປ​ຂອງ​ທ່ານ​ແມ່ນ <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"ໂມງ​ປຸກ​ຖັດ​ໄປ​ຂອງ​ທ່ານ​ແມ່ນ <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"ທ່ານ​ຈະ​ບໍ່​ໄດ້​ຍິນ​ສຽງ​ໂມງ​ປຸກ​ໃນ​ເວ​ລາ <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"ການ​ແຈ້ງເຕືອນ​ທີ່​ສຳຄັນ​ໜ້ອຍ​ກວ່າ​ຢູ່​ດ້ານ​ລຸ່ມ"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"​ແຕະ​ອີກ​ເທື່ອ​ນຶ່ງ​ເພື່ອ​ເປີດ"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"ເລື່ອນ​ຂຶ້ນ​ເພື່ອ​ປົດ​ລັອກ"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ປັດ​ຂວາ​ເພື່ອ​ໃຊ້​ໂທ​ລະ​ສັບ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ປັດ​ຊ້າຍ​ເພື່ອ​ໃຊ້​ກ້ອງ"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"ຢ່າງ​ບໍ່​ມີ​ກຳນົດ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ບໍ່ມີ"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ລະດັບຄວາມສຳຄັນ"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ທັງໝົດ"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ກຳ​ລັງ​ສາກ​ໄຟ (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> ກວ່າ​ຈ​ະ​ເຕັມ)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ສະ​ລັບ​ຜູ່ໃຊ້"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ປ່ຽນຜູ່ໃຊ້, ຜູ່ໃຊ້ປະຈຸບັນ <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"​ສະ​ແດງ​ໂປຣ​ໄຟລ໌"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ເພີ່ມຜູ່ໃຊ້"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"ຜູ່ໃຊ້ໃໝ່"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"ແຂກ"</string>
-    <string name="guest_new_guest" msgid="600537543078847803">"Add guest"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"ເພີ່ມແຂກ"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"​ລຶບ​ແຂກ"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ສິ້ນ​ສຸດ​ການ​ນຳ​ໃຊ້​ຂອງ​ຜູ່​ຢ້ຽມ​ຢາມບໍ່?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"​ການ​ອອກ​ຈາກ​ເຊດ​ຊັນ​ຜູ່​ຢ້ຽມ​ຢາມ​ຈະ​ເປັນ​ການ​ລຶບ​ຂໍ້​ມູນ​ໃນ​ເຄື່ອງອອ."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"ລຶບ​ແຂກ​ບໍ?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ແອັບຯ​ແລະ​ຂໍ້​ມູນ​ທັງ​ໝົດ​ໃນ​ເຊດ​ຊັນ​ນີ້​ຈະ​ຖືກ​ລຶບ​ອອກ."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ລຶບ​"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"ຍິນ​ດີ​ຕ້ອນ​ຮັບ​ກັບ​ມາ, ຜູ່​ຢ້ຽມ​ຢາມ!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ເປັນ​ເວລາ​ນຶ່ງ​ນາ​ທີ"</item>
-    <item quantity="other" msgid="6924190729213550991">"ເປັນ​ເວລາ %d ນາ​ທີ"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ເປັນ​ເວລາ​ນຶ່ງ​ຊົ່ວ​ໂມງ"</item>
-    <item quantity="other" msgid="5408537517529822157">"ເປັນ​ເວລາ %d ຊົ່ວ​ໂມງ"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"ທ່ານ​ຕ້ອງ​ການ​ສືບ​ຕໍ່​ເຊດ​ຊັນ​ຂອງ​ທ່ານບໍ່?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"ເລີ່ມຕົ້ນໃຫມ່"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"​ຕົກ​ລົງ, ດຳ​ເນີນ​ການ​ຕໍ່"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"ເພີ່ມ​ຜູ່​ໃຊ້​ໃໝ່​ບໍ?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"ເມື່ອ​ທ່ານ​ເພີ່ມ​ຜູ່​ໃຊ້​ໃໝ່, ຜູ່​ໃຊ້​ນັ້ນ​ຈະ​ຕ້ອງ​ຕັ້ງ​ຄ່າ​ພື້ນ​ທີ່​ບ່ອນ​ຈັດ​ເກັບ​ຂໍ້​ມູນ​ຂອງ​ລາວ.\n\nຜູ່​ໃຊ້​ທຸກ​ຄົນ​ສາ​ມາດ​ອັບ​ເດດ​ແອັບຯ​ຂອງ​ຜູ່​ໃຊ້​ຄົນ​ອື່ນ​ທັງ​ໝົດ​ໄດ້."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ເປີດ​ໃຊ້​ໂຕ​ປະຢັດ​ແບັດເຕີຣີ​ແລ້ວ"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ຫຼຸດ​ປະ​ສິ​ທິ​ພາບ​ແລະ​ການ​ນຳ​ໃຊ້​ຂໍ້​ມູນ​ພື້ນຫຼັງ"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ປິດ​ໂຕ​ປະ​ຢັດ​ແບັດ​ເຕີ​ຣີ"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
-    <string name="notification_hidden_text" msgid="1135169301897151909">"​ເນື້ອ​ຫາ​ຖືກ​ເຊື່ອງ​ແລ້ວ"</string>
+    <string name="notification_hidden_text" msgid="1135169301897151909">"ເນື້ອຫາ​ຖືກ​ເຊື່ອງ​ໄວ້"</string>
     <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> ​ຈະ​ເລີ່ມ​ບັນ​ທຶກ​ທຸກ​ຢ່າງ​ທີ່​ສະ​ແດງ​ຜົນ​ໃນ​ໜ້າ​ຈໍ​ທ່ານ."</string>
     <string name="media_projection_remember_text" msgid="3103510882172746752">"ບໍ່​ຕ້ອງ​ສະ​ແດງ​ອີກ"</string>
     <string name="clear_all_notifications_text" msgid="814192889771462828">"ລຶບລ້າງທັງໝົດ"</string>
     <string name="media_projection_action_text" msgid="8470872969457985954">"ເລີ່ມດຽວນີ້"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"ບໍ່ມີການແຈ້ງເຕືອນ"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ອຸ​ປະ​ກອນ​ອາດ​ມີ​ການ​ເຝົ້າ​ຕິດ​ຕາມ"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ໂປຣ​ໄຟລ໌​ອາດ​ຖືກ​ເຝົ້າ​ຕິດ​ຕາມ​ຢູ່"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"​ເຄືອ​ຂ່າຍ​ອາດ​ມີ​ການ​ເຝົ້າ​ຕິດ​ຕາມ"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ການກວດ​ສອບ​ຕິດ​ຕາມ​ອຸ​ປະ​ກອນ"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"ການ​ຕິດ​ຕາມ​ໂປຣ​ໄຟລ໌"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ການກວດ​ສອບ​ຕິດ​ຕາມ​ເຄືອ​ຂ່າຍ"</string>
-    <string name="open_app" msgid="4011771120339160755">"ເປີດແອັບຯ"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"ປິດ​ການ​ໃຊ້ VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"ຕັດ​ການ​ເຊື່ອມ​ຕໍ່ VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ອຸ​ປະ​ກອນ​ນີ້​​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມ​ອຸ​ປະ​ກອນ​ແລະ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​ຫັດ.\n\nສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"ທ່ານ​ໃຫ້​ສິດ​ອະ​ນຸ​ຍາດ​ກັບ \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ເພື່ອ​ຕັ້ງ​ຄ່າ​ການ​ເຊື່ອມ​ຕໍ່ VPN.\n\nແອັບຯ​ນີ້​ຈະ​ສາ​ມາດເຝົ້າ​ຕິດ​ຕາມອຸ​ປະ​ກອນ​ແລະ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​ຫັດ."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"ທ່ານ​ເຊື່ອມ​ຕ​ໍ່​ຫາ VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") ແລ້ວ.\n\n​ຜູ່​ໃຫ້​ບໍ​ລິ​ການ VPN ຂອງ​ທ່ານ​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມອຸ​ປະ​ກອນ​ແລະ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​ຫັດ."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nອີກ​ຢ່າງ​ນຶ່ງ, ທ່ານມອບ​ສິດ​ອະ​ນຸ​ຍາດໃຫ້ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ເພື່ອ​ຕັ້ງ​ຄ່າ​ການ​ເຊື່ອມ​ຕໍ່ VPN. ແອັບຯ​ນີ້​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nນອກ​ຈາກ​ນັ້ນ, ທ່ານ​​ໄດ້​ເຊື່ອມ​ຕໍ່​ຫາ VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). ຜູ່​ໃຫ້​ບໍ​ລິ​ການ VPN ຂອງ​ທ່ານ​ສາ​ມາດ​ເຝົ້າ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້​ເຊັ່ນ​ກັນ."</string>
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ໂປຣ​ໄຟລ໌​ນີ້​ແມ່ນ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ຂອງ​ທ່ານ​ມີ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ໃນ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ: ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​​ທີ່​ເຂົ້າ​ລະ​ຫັດ. \n\nສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ອຸ​ປະ​ກອນ​ນີ້​ເບິ່ງ​ແຍງ​ໂດຍ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nໂປຣ​ໄຟລ໌​ຂອງ​ທ່ານ​ແມ່​ນ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ​ສາ​​ມາດ​ຕິດ​ຕາມ​ອຸ​ປະ​ກອນ​ຂອງ​ທ່ານ ແລະ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​​ຂ່າຍ ຮວມ​ເຖິງ: ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​ທີ່​ເຂົ້າ​ລະ​ຫັດ.\n\nສຳ​ລັບ​ຂ​ໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ຂອງ​ທ່ານ​ມີ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ໃນ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ: ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​​ທີ່​ເຂົ້າ​ລະ​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nນອກ​ຈາກ​ນັ້ນ, ທ່ານ​ໄດ້​ອະ​ນຸ​ຍາດ​ໃຫ້ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ສາ​ມາດ​ຕັ້ງ​ຄ່າ​ການ​ເຊື່ອມ​ຕໍ່ VPN ໄດ້. ແອັບຯ​ນີ້​​ສາ​ມາດ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້​ເຊັ່ນ​ກັນ."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ໂປຣ​ໄຟລ໌​ນີ້​ແມ່ນ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ຂອງ​ທ່ານ​ມີ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ໃນ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ: ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​​ທີ່​ເຂົ້າ​ລະ​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nນອກ​ຈາກ​ນັ້ນ, ທ່ານ​ໄ​ດ້​ເຊື່ອມ​ຕໍ່​ຫາ VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). ຜູ່​ໃຫ້​ບໍ​ລິ​ການ VPN ​ຂອງ​ທ່ານ​ສາ​ມາດ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ໄດ້​ເຊັ່ນ​ກັນ."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ອຸ​ປະ​ກອນ​ນີ້​ແມ່ນ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nໂປຣ​ໄຟລ໌​ຂອງ​ທ່ານ​ແມ່ນ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ຂອງ​ທ່ານ​ມີ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ໃນ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ: ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​​ທີ່​ເຂົ້າ​ລະ​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nນອກ​ຈາກ​ນັ້ນ, ທ່ານ​ໄດ້​ອະ​ນຸ​ຍາດ​ໃຫ້ \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ​ສາ​ມາດ​ຕັ້ງ​ຄ່າ​ການ​ເຊື່ອມ​ຕໍ່ VPN ໄດ້. ແອັບຯ​ນີ້​​ສາ​ມາດ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້​ເຊັ່ນ​ກັນ."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ອຸ​ປະ​ກອນ​ນີ້​ແມ່ນ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nໂປຣ​ໄຟລ໌​ຂອງ​ທ່ານ​ແມ່ນ​ຖືກ​ຈັດ​ການ​ໂດຍ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nຜູ່​ເບິ່ງ​ແຍງ​ຂອງ​ທ່ານ​ມີ​ຄວາມ​ສາ​ມາດ​ໃນ​ການ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ໃນ​ເຄືອ​ຂ່າຍ​ຂອງ​ທ່ານ​ໄດ້ ຮວມ​ເຖິງ: ​ອີ​ເມວ, ແອັບຯ ແລະ​ເວັບ​ໄຊ​​ທີ່​ເຂົ້າ​ລະ​ຫັດ. ສຳ​ລັບ​ຂໍ້​ມູນ​ເພີ່ມ​ເຕີມ, ໃຫ້​ຕິດ​ຕໍ່​ຜູ່​ເບິ່ງ​ແຍງ​ລະ​ບົບ​ຂອງ​ທ່ານ.\n\nນອກ​ຈາກ​ນັ້ນ, ທ່ານ​ໄ​ດ້​ເຊື່ອມ​ຕໍ່​ຫາ VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). ຜູ່​ໃຫ້​ບໍ​ລິ​ການ VPN ​ຂອງ​ທ່ານ​ສາ​ມາດ​ຕິດ​ຕາມ​ການ​ເຄື່ອນ​ໄຫວ​ເຄືອ​ຂ່າຍ​ໄດ້​ເຊັ່ນ​ກັນ."</string>
     <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Device will stay locked until you manually unlock"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"ຮັບເອົາການ​ແຈ້ງເຕືອນ​ໄວຂຶ້ນ"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ເບິ່ງພວກ​ມັນກ່ອນ​ທ່ານຈະ​ປົດລັອກ"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"ບໍ່, ຂອບໃຈ"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"ຕັ້ງຄ່າ"</string>
+    <string name="muted_by" msgid="6147073845094180001">"ຖືກ​ປິດ​ສຽງ​ໂດຍ <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-lt/config.xml b/packages/SystemUI/res/values-lt/config.xml
new file mode 100644
index 0000000..edfec94
--- /dev/null
+++ b/packages/SystemUI/res/values-lt/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 sek., 10 sek., 30 sek., 60 sek., 120 sek."</string>
+</resources>
diff --git a/packages/SystemUI/res/values-lt/strings.xml b/packages/SystemUI/res/values-lt/strings.xml
index 98155d9..9439dc8 100644
--- a/packages/SystemUI/res/values-lt/strings.xml
+++ b/packages/SystemUI/res/values-lt/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Išvalyti"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Pašalinti iš sąrašo"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Programos informacija"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Čia rodomi naujausi ekranai"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Atsisakyti naujausių programų"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 naujausia programa"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Atgal"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Pagrindinis"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Meniu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Naujausi ekranai"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Ieškoti"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparatas"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefonas"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Atrakinti"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"atrakinti"</string>
+    <string name="phone_label" msgid="2320074140205331708">"atidaryti telefoną"</string>
+    <string name="camera_label" msgid="7261107956054836961">"atidaryti fotoaparatą"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Perjungti įvesties metodo mygtuką."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Suderinamumo priartinimo mygtukas."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Padidinti ekraną."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dvi „Wi-Fi“ juostos."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Trys „Wi-Fi“ juostos."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Stiprus „Wi-Fi“ signalas."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Prisijungta prie „<xliff:g id="WIFI">%s</xliff:g>“."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Prisijungta prie „<xliff:g id="BLUETOOTH">%s</xliff:g>“."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Nėra „WiMAX“ signalo."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Viena „WiMAX“ signalo juosta."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dvi „WiMAX“ signalo juostos."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"„TeleTypewriter“ įgalinta."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibracija skambinant."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Skambutis tylus."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Atsisakyti <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Atsisakyta programos „<xliff:g id="APP">%s</xliff:g>“."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Paleidžiama <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Pranešimo atsisakyta."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Pranešimų gaubtas."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Spartieji nustatymai."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Užrakinimo ekranas."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Nustatymai"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Naujausi ekranai."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Naudotojas <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"„Wi-Fi“ ryšys išjungtas."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"„Wi-Fi“ ryšys įjungtas."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobilusis ryšys <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Akumuliatorius <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Lėktuvo režimas <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"„Bluetooth“ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Vietovė – <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Lėktuvo režimas išjungtas."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Lėktuvo režimas įjungtas."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Lėktuvo režimas išjungtas."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Lėktuvo režimas įjungtas."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"„Bluetooth“ išjungtas."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"„Bluetooth“ įjungtas."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Prijungiamas „Bluetooth“."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"„Bluetooth“ prijungtas."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"„Bluetooth“ išjungtas."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"„Bluetooth“ įjungtas."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Vietovių ataskaitų teikimas išjungtas."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Vietovių ataskaitų teikimas įjungtas."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Vietovių ataskaitų teikimas išjungtas."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Vietovių ataskaitų teikimas įjungtas."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Signalas nustatytas <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Uždaryti skydelį"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Daugiau laiko"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mažiau laiko"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Uždaryti skydelį."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Daugiau laiko."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mažiau laiko."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Blykstė išjungta."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Blykstė įjungta."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Blykstė išjungta."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Blykstė įjungta."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Spalvų inversija išjungta."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Spalvų inversija įjungta."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobiliojo ryšio viešosios interneto prieigos taškas išjungtas."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobiliojo ryšio viešosios interneto prieigos taškas įjungtas."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ekrano perdavimas sustabdytas."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ekrano ryškumas"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G–3G duomenys išjungti"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G duomenys išjungti"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobiliojo ryšio duomenys išjungti"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS nustatyta vieta"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Vietovės užklausos aktyvios"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Išvalyti visus pranešimus."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Nustatymai"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Pranešimų nustatymai"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"„<xliff:g id="APP_NAME">%s</xliff:g>“ nustatymai"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekranas bus sukamas automatiškai."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Užrakintas ekranas yra horizontalios orientacijos."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Užrakintas ekranas yra vertikalios orientacijos."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Dabar ekranas bus sukamas automatiškai."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Dabar ekranas užrakintas nustačius gulsčią orientaciją."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Dabar ekranas užrakintas nustačius stačią orientaciją."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Desertų dėklas"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Svajonė"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Eternetas"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobiliojo ryšio duomenys"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Duomenų naudojimas"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Likę duomenys"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Viršytas limitas"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Pasiektas apribojimas – duomenų naudojimas pristabdytas"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Išnaudota: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limitas: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> įspėjimas"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Čia rodomi naujausi ekranai"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Programos informacija"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"Programos užrakinimo funkcija"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"paieška"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Paieška"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Slyskite aukštyn link <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Slyskite į kairę link <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Jokių pertraukčių, įskaitant signalus"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Nėra trikdžių. Nėra net įspėjimų."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Jokių pertraukčių"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Tik prioritetinės pertrauktys"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Kito signalo laikas: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> signalo negirdėsite"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Mažiau skubūs pranešimai toliau"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Palieskite dar kartą, kad atidarytumėte"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Perbraukite aukštyn, kad atrakintumėte"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Perbraukite į dešinę, kad galėtumėte skambinti"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Perbraukite į kairę, kad būtų įjungtas fotoaparatas"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Neapibrėžta"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nėra"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritetas"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Visi"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Kraunama (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> iki visiško įkrovimo)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Perjungti naudotoją"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Perjungti naudotoją, dabartinis naudotojas <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Rodyti profilį"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Naudotojo pridėjimas"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Naujas naudotojas"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Svečias"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Pridėti svečią"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Pašalinti svečią"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Išeinate iš svečio sesijos?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Išėjus iš svečio sesijos bus pašalinti vietiniai duomenys."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Pašalinti svečią?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Bus ištrintos visos šios sesijos programos ir duomenys."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Pašalinti"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Sveiki sugrįžę, svety!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 min."</item>
-    <item quantity="other" msgid="6924190729213550991">"%d min."</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 val."</item>
-    <item quantity="other" msgid="5408537517529822157">"%d val."</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Ar norite tęsti sesiją?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Pradėti iš naujo"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Taip, tęsti"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Pridėti naują naudotoją?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kai pridedate naują naudotoją, šis asmuo turi nustatyti savo erdvę.\n\nBet kuris naudotojas gali atnaujinti visų kitų naudotojų programas."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Akumuliatoriaus tausojimo priemonė įjungta"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Sumažinamas našumas ir foninių duomenų naudojimas"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Išjungti Akumuliatoriaus tausojimo priemonę"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Pradėti dabar"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nėra įspėjimų"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Įrenginys gali būti stebimas"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilis gali būti stebimas"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Tinklas gali būti stebimas"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Įrenginio stebėjimas"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilio stebėjimas"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Tinklo stebėjimas"</string>
-    <string name="open_app" msgid="4011771120339160755">"Atidaryti programą"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Išjungti VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Atjungti VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Šį įrenginį tvarko\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nJūsų administratorius gali stebėti įrenginio ir tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines.\n\nJei reikia daugiau informacijos, susisiekite su administratoriumi."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Suteikėte leidimą „<xliff:g id="APPLICATION">%1$s</xliff:g>“ užmegzti VPN ryšį.\n\nŠi programa gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Esate prisijungę prie VPN („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nVPN paslaugos teikėjas gali stebėti įrenginį ir tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Šį įrenginį tvarko:\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nAdministratorius gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Kad gautumėte daugiau informacijos, susisiekite su administratoriumi.\n\nSuteikėte leidimą „<xliff:g id="APPLICATION">%2$s</xliff:g>“ užmegzti VPN ryšį. Ši programa taip pat gali stebėti tinklo veiklą."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Šį įrenginį tvarko:\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nAdministratorius gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Kad gautumėte daugiau informacijos, susisiekite su administratoriumi.\n\nBe to, esate prisijungę prie VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>“). VPN paslaugos teikėjas taip pat gali stebėti tinklo veiklą."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Šį profilį tvarko:\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nAdministratorius gali stebėti įrenginio ir tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines.\n\nJei reikia daugiau informacijos, susisiekite su administratoriumi."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Šį įrenginį tvarko:\n„<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>“\nJūsų profilį tvarko:\n„<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>“\n\nAdministratorius gali stebėti įrenginio ir tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines.\n\nJei reikia daugiau informacijos, susisiekite su administratoriumi."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Šį profilį tvarko:\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nAdministratorius gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Jei reikia daugiau informacijos, susisiekite su administratoriumi.\n\nBe to, „<xliff:g id="APPLICATION">%2$s</xliff:g>“ suteikėte leidimą nustatyti VPN ryšį. Ši programa taip pat gali stebėti tinklo veiklą."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Šį profilį tvarko:\n„<xliff:g id="ORGANIZATION">%1$s</xliff:g>“\n\nAdministratorius gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Jei reikia daugiau informacijos, susisiekite su administratoriumi.\n\nBe to, esate prisijungę prie VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>“). VPN paslaugos teikėjas taip pat gali stebėti tinklo veiklą."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Šį įrenginį tvarko:\n„<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>“\nJūsų profilį tvarko:\n„<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>“\n\nAdmin. gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Jei reikia daugiau informacijos, susisiekite su administratoriumi.\n\nBe to, „<xliff:g id="APPLICATION">%3$s</xliff:g>“ suteikėte leidimą nustatyti VPN ryšį. Ši programa taip pat gali stebėti tinklo veiklą."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Šį įrenginį tvarko:\n„<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>“\nJūsų profilį tvarko:\n„<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>“\n\nAdmin. gali stebėti tinklo veiklą, įskaitant el. laiškus, programas ir saugias svetaines. Jei reikia daugiau informacijos, susisiekite su administratoriumi.\n\nBe to, esate prisijungę prie VPN („<xliff:g id="APPLICATION">%3$s</xliff:g>“). VPN paslaugos teikėjas taip pat gali stebėti tinklo veiklą."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Įrenginys liks užrakintas, kol neatrakinsite jo neautomatiniu būdu"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Greičiau gaukite pranešimus"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Peržiūrėti prieš atrakinant"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ne, ačiū"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Nustatyti"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Nutildė <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-lv/strings.xml b/packages/SystemUI/res/values-lv/strings.xml
index 387b850..778c64b 100644
--- a/packages/SystemUI/res/values-lv/strings.xml
+++ b/packages/SystemUI/res/values-lv/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Notīrīt"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Noņemšana no saraksta"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Lietotnes informācija"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Jūsu pēdējie ekrāni tiek rādīti šeit."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Nerādīt nesen izmantotās lietotnes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 nesen izmantotā lietotne"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Atpakaļ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Sākums"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Izvēlne"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Pēdējie ekrāni"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Meklēt"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Tālruņa numurs"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Atbloķēt"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"atbloķēt"</string>
+    <string name="phone_label" msgid="2320074140205331708">"atvērt tālruni"</string>
+    <string name="camera_label" msgid="7261107956054836961">"atvērt kameru"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Ievades metodes maiņas poga."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Saderības tālummaiņas poga."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Veikt tālummaiņu no mazāka ekrāna uz lielāku."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: divas joslas"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: trīs joslas"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Pilna piekļuve Wi-Fi signālam"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Ir izveidots savienojums ar <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Ir izveidots savienojum ar <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Bez WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX viena josla."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX divas joslas."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Teletaips ir iespējots."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Zvana signāls — vibrācija."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Zvana signāls — kluss."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Nerādīt lietotni <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Lietotne <xliff:g id="APP">%s</xliff:g> vairs netiek rādīta."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Notiek lietotnes <xliff:g id="APP">%s</xliff:g> palaišana."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Paziņojums netiek rādīts."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Paziņojumu panelis"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Ātrie iestatījumi"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Bloķēšanas ekrāns."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Iestatījumi"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Pēdējie ekrāni."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Lietotājs: <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi ir izslēgts."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi ir ieslēgts."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobilo sakaru tīkls. <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Akumulatora statuss: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Lidojuma režīma statuss: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth statuss: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Atrašanās vieta: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Lidojuma režīms ir izslēgts."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Lidojuma režīms ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Lidojuma režīms ir izslēgts."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Lidojuma režīms ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth savienojums ir izslēgts."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth savienojums ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Notiek Bluetooth savienojuma izveide."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth savienojums ir izveidots."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth savienojums ir izslēgts."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth savienojums ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Ziņošana par atrašanās vietu ir izslēgta."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Ziņošana par atrašanās vietu ir ieslēgta."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Ziņošana par atrašanās vietu ir izslēgta."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Ziņošana par atrašanās vietu ir ieslēgta."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Signāls ir iestatīts uz: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Aizvērt paneli"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Ilgāk"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mazāks laiks"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Aizvērt paneli."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Vairāk laika."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mazāk laika."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Apgaismojums ir izslēgts."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Apgaismojums ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Apgaismojums ir izslēgts."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Apgaismojums ir ieslēgts."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Krāsu inversija ir izslēgta."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Krāsu inversija ir ieslēgta."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilais tīklājs ir izslēgts."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilais tīklājs ir ieslēgts."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ekrāna apraidīšana ir apturēta."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ekrāna spilgtums"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G–3G dati ir atslēgti"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G dati ir atslēgti"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobilie dati ir atslēgti"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS iestatītā atrašanās vieta"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktīvi atrašanās vietu pieprasījumi"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Notīrīt visus paziņojumus"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Iestatījumi"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Paziņojumu iestatījumi"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> iestatījumi"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekrāns tiks pagriezts automātiski."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ekrāns tagad ir bloķēts ainavas orientācijā."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ekrāns tagad ir bloķēts portreta orientācijā."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ekrāns tagad tiks pagriezts automātiski."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ekrāns tagad ir bloķēts ainavas orientācijā."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ekrāns tagad ir bloķēts portreta orientācijā."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Saldo ēdienu stends"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Ekrānsaudzētājs"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Tīkls Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobilie dati"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Datu lietojums"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Atlikušie dati"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Pārsniegts ierobežojums"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Sasniegts ierobežojums — datu lietošana ir pārtraukta"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Tiek izmantots: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Ierobežojums: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> brīdinājums"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Jūsu pēdējie ekrāni tiek rādīti šeit."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informācija par lietojumprogrammu"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"fiksēt lietotni"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"Meklēt"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Meklēt"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Velciet uz augšu, lai veiktu šādu darbību: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Velciet pa kreisi, lai veiktu šādu darbību: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Bez pārtraukumiem, tostarp bez signāliem"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Bez traucējumiem. Pat bez brīdinājumiem"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Nepārtraukt"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Tikai prioritārie pārtraukumi"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Jūsu nākamā signāla laiks: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Jūs nedzirdēsiet iestatīto signālu: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Mazāk steidzami paziņojumi tiek rādīti tālāk"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Pieskarieties vēlreiz, lai atvērtu."</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Velciet uz augšu, lai atbloķētu"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Lai lietotu tālruni, velciet pa labi."</string>
     <string name="camera_hint" msgid="5241441720959174226">"Lai lietotu kameru, velciet pa kreisi."</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Uz nenoteiktu laiku"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nav"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritāte"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Visi"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Notiek uzlāde (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> līdz pilnīgai uzlādei)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Mainīt lietotāju"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Pārslēgt lietotāju; pašreizējais lietotājs: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Parādīt profilu"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Lietotāja pievienošana"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Jauns lietotājs"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Viesis"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Pievienot viesi"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Noņemt viesi"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Vai iziet no viesa sesijas?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Pārtraucot viesa sesiju, tiks noņemti lokālie dati."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Vai noņemt viesi?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Tiks dzēstas visas šīs sesijas lietotnes un dati."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Noņemt"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Laipni lūdzam atpakaļ, viesi!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Vienu minūti"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Vienu stundu"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d h"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vai vēlaties turpināt savu sesiju?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Sākt no sākuma"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Jā, turpināt"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Vai pievienot jaunu lietotāju?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kad pievienosiet jaunu lietotāju, viņam būs jāizveido savs profils.\n\nIkviens lietotājs var atjaunināt lietotnes citu lietotāju vietā."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Ieslēgts akumulatora enerģijas taupīšanas režīms"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Samazina veiktspēju un fona datus"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Izslēgt akumulatora jaudas taupīšanu"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Sākt tūlīt"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nav paziņojumu"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Ierīci var pārraudzīt"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilu var pārraudzīt"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Iespējams, tīklā veiktās darbības tiek pārraudzītas."</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Ierīces pārraudzība"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profila pārraudzība"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Tīkla pārraudzība"</string>
-    <string name="open_app" msgid="4011771120339160755">"Atvērt lietotni"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Atspējot VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Atvienot VPN tīklu"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Šo ierīci pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes. \n\nLai iegūtu plašāku informāciju, sazinieties ar administratoru."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Jūs piešķīrāt lietotnei “<xliff:g id="APPLICATION">%1$s</xliff:g>” atļauju izveidot savienojumu ar VPN tīklu\n\nŠī lietotne var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Ir izveidots savienojums ar VPN tīklu (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nJūsu VPN pakalpojumu sniedzējs var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Šo ierīci pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt tīklā veiktās darbības, arī e-pastus, lietotnes un drošās vietnes. Lai uzzinātu vairāk, sazinieties ar administratoru.\n\nJūs arī piešķīrāt atļauju izveidot savienojumu ar VPN tīklu lietotnei “<xliff:g id="APPLICATION">%2$s</xliff:g>”. Šī lietotne arī var pārraudzīt jūsu tīklā veiktās darbības."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Šo ierīci pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu tīklā veiktās darbības, arī e-pastus, lietotnes un drošās vietnes. Lai uzzinātu vairāk, sazinieties ar administratoru.\n\nIr arī izveidots savienojums ar VPN tīklu (“<xliff:g id="APPLICATION">%2$s</xliff:g>”). Tīklā veiktās darbības var pārraudzīt arī jūsu VPN pakalpojumu sniedzējs."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Šo profilu pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes.\n\nLai iegūtu plašāku informāciju, sazinieties ar administratoru."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Šo ierīci pārvalda:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJūsu profilu pārvalda:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes.\n\nLai iegūtu plašāku informāciju, sazinieties ar administratoru."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Šo profilu pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes. Papildinformāciju jautājiet administratoram.\n\nJūs piešķīrāt lietotnei “<xliff:g id="APPLICATION">%2$s</xliff:g>” atļauju izveidot savienojumu ar VPN tīklu. Arī šī lietotne var pārraudzīt tīklā veiktās darbības."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Šo profilu pārvalda:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nJūsu administrators var pārraudzīt jūsu tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes. Lai iegūtu plašāku informāciju, sazinieties ar administr.\n\nIr arī izveidots savienojums ar VPN tīklu (<xliff:g id="APPLICATION">%2$s</xliff:g>). Jūsu veiktās darbības var pārraudzīt arī VPN pakalpojumu sniedzējs."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Ierīci pārvalda:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJūsu profilu pārvalda:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nJūsu administr. var pārraudzīt jūsu tīklā veiktās darbības, tostarp e-pastu, liet. un dr. vietnes. Papildinform.: jautājiet administratoram.\n\nJūs piešķīrāt lietotnei “<xliff:g id="APPLICATION">%3$s</xliff:g>” atļauju izveidot savien. ar VPN tīklu. Arī šī lietotne var pārraudzīt tīklā veiktās darbības."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Ierīci pārvalda:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nJūsu profilu pārvalda:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministrators var pārraudzīt jūsu ierīcē un tīklā veiktās darbības, tostarp e-pastu, lietotnes un drošās vietnes. Papildinform.: jautājiet administratoram.\n\nIr arī izveidots savienojums ar VPN tīklu (<xliff:g id="APPLICATION">%3$s</xliff:g>). Jūsu veiktās darbības var pārraudzīt arī VPN pakalp. sniedz."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Ierīce būs bloķēta, līdz to manuāli atbloķēsiet."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Saņemiet paziņojumus ātrāk"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Skatiet tos pirms atbloķēšanas."</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nē"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Iestatīt"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Skaņu izslēdza <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-mdpi/dimens.xml b/packages/SystemUI/res/values-mdpi/dimens.xml
new file mode 100644
index 0000000..aa85d69
--- /dev/null
+++ b/packages/SystemUI/res/values-mdpi/dimens.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<resources>
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <fraction name="battery_button_height_fraction">12%</fraction>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+         fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">10%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">10%</fraction>
+
+    <dimen name="battery_margin_bottom">1px</dimen>
+</resources>
diff --git a/packages/SystemUI/res/values-mk-rMK/config.xml b/packages/SystemUI/res/values-mk-rMK/config.xml
new file mode 100644
index 0000000..024f528
--- /dev/null
+++ b/packages/SystemUI/res/values-mk-rMK/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1сек., 10 сек., 30 сек., 60 сек., 120 сек."</string>
+</resources>
diff --git a/packages/SystemUI/res/values-mk-rMK/strings.xml b/packages/SystemUI/res/values-mk-rMK/strings.xml
index 6f41457..7225f37 100644
--- a/packages/SystemUI/res/values-mk-rMK/strings.xml
+++ b/packages/SystemUI/res/values-mk-rMK/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Исчисти"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Отстрани од списокот"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Информации за апликацијата"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Вашите неодамнешни екрани се појавуваат тука"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Отфрли ги скорешните апликации"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 скорешна апликација"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Назад"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Почетна страница"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Мени"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Неодамнешни екрани"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Пребарај"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Фотоапарат"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Отклучување"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"отклучи"</string>
+    <string name="phone_label" msgid="2320074140205331708">"отвори телефон"</string>
+    <string name="camera_label" msgid="7261107956054836961">"отвори камера"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Копче за префрање метод на внес."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Копче за компатибилност на зум."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Зумот е помал на поголем екран."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi две цртички."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi три цртички."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Полн сигнал на WiFi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Поврзано со <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Поврзано со <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Нема WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX една цртичка."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX две цртички."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Овозможен е телепринтер."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Ѕвонче на вибрации."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Ѕвонче на тивко."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Отфрли <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> е отфрлена."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Се стартува <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Известувањето е отфрлено."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Панел за известување"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Брзи подесувања."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Заклучи екран."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Поставки"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Неодамнешни екрани."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Корисник <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi е исклученo."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi е вклученo."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобилен <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батерија <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Режим на работа во авион <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Локација <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Авионскиот режим е исклучен."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Авионскиот режим е вклучен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Авионскиот режим е исклучен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Авионскиот режим е вклучен."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth е исклучен."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth е вклучен."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth се поврзува."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth е поврзан."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth е исклучен."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth е вклучен."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Известувањето за локација е исклучено."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Известувањето за локација е вклучено."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Известувањето за локација е исклучено."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Известувањето за локација е вклучено."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Аларм наместен за <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Затвори ја плочата"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Повеќе време"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Помалку време"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Затвори ја таблата."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Повеќе време."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Помалку време."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Блицот е исклучен."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Блицот е вклучен."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Блицот е исклучен."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Блицот е вклучен."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Инверзијата на бои е исклучена."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Инверзијата на бои е вклучена."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобилната точка на пристап е исклучена."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобилната точка на пристап е вклучена."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Емитувањето на екранот запре."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Осветленост на екранот"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Податоците 2G-3G се исклучени"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Податоците 4G се исклучени"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Мобилните податоци се исклучени"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Локацијата е поставена со ГПС"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Активни барања за локација"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Исчисти ги сите известувања."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Поставки"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Поставки на известувања"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Поставки на <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Екранот ќе ротира автоматски."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Екранот е заклучен во ориентација на пејзаж."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Екранот е заклучен во ориентација на портрет."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Сега екранот ќе се ротира автоматски."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Сега екранот е заклучен во хоризонтална ориентација."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Сега екранот е заклучен во вертикална ориентација."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Етернет"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Мобилни податоци"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Користење податоци"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Преостанати податоци"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Над лимитот"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Достигнат лимит – паузирано користење податоци"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Искористено: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Лимит: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Предупредување за <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Вашите неодамнешни екрани се појавуваат тука"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Информации за апликацијата"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"заклучи на апликација"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"пребарај"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Пребарај"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Лизгај нагоре за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Лизгај налево за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Без прекини, вклучувајќи аларми"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Без прекини. Дури и без аларми."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Без прекини"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Само приоритетни прекини"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Следниот аларм е во <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Нема да го слушнете алармот во <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Долу се помалку итни известувања"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Допрете повторно за да отворите"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Повлечете за да се отклучи"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Повлечете надесно за телефон"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Повлечете налево за камера"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Неодредено време"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ништо"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Приоритет"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Сѐ"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Се полни (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> додека не се наполни)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Промени го корисникот"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Промени го корисникот, тековен корисник <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Прикажи го профилот"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Додај корисник"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Нов корисник"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Гостин"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Додај гостин"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Отстрани гостин"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Да излеземе од гостинската сесија?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Излегувањето од гостинската сесија ќе ги отстрани локалните податоци."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Да се отстрани гостинот?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Сите апликации и податоци во сесијата ќе се избришат."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Отстрани"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Добредојде назад, гостине!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"За една минута"</item>
-    <item quantity="other" msgid="6924190729213550991">"За %d минути"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"За еден час"</item>
-    <item quantity="other" msgid="5408537517529822157">"За %d часа"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Дали сакате да продолжите со сесијата?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Почни одново"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Да, продолжи"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Да се додаде нов корисник?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Кога додавате нов корисник, тоа лице треба да го постави својот простор.\n\nСекој корисник може да ажурира апликации за сите други корисници."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Штедачот на батерија е вклучен"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Ја намалува изведбата и податоците во заднина"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Исклучете го штедачот на батерија"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Започни сега"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Нема известувања"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Уредот може да се следи"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профилот можеби се следи"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Мрежата може да се следи"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Следење на уредот"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Следење профил"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Следење на мрежата"</string>
-    <string name="open_app" msgid="4011771120339160755">"Отвори апликација"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Оневозможи ВПН"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Исклучи ВПН"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Со уредот управува:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nВашиот администратор може да ги следи уредот и мрежната активност, заедно со е-пораките, апликациите и безбедните веб-локации.\n\nЗа повеќе информации, контактирајте со администраторот."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Дозволивте „<xliff:g id="APPLICATION">%1$s</xliff:g>“ да постави поврзување ВПН.\n\nОваа апликација може да ги следи уредот и мрежната активност, заедно со е-пораките, апликациите и безбедните веб-локации."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Поврзани сте на ВПН („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nОператорот на услугата ВПН може да ги следи уредот и мрежната активност, заедно со е-пораките, апликациите и безбедните веб-локации."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Уредот е управуван од:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n}Администраторот е во состојба да ја следи вашата активност на мрежата, вклучувајќи ги е-пораките, апликациите и безбедните веб-локации.За повеќе информации, контактирајте со администраторот.\n\nДозволивте „<xliff:g id="APPLICATION">%2$s</xliff:g>“ да постави поврзување со ВПН.Оваа апликација може да ја следи вашата активност на мрежата исто така."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Уредот е управуван од:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторот е во состојба да ја следи вашата активност на мрежата, вклучувајќи ги е-пораките, апликациите и безбедните веб-локации.За повеќе информации, контактирајте со администраторот.\n\nПоврзани сте и на ВПН („<xliff:g id="APPLICATION">%2$s</xliff:g>“)Давателот на услуги на ВПН може да ја следи активноста на мрежата исто така."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Со овој профил управува:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторот може да ги следи вашиот уред и мрежната активност, вклучувајќи е-пошта, апликации и безбедни веб-локации.\n\nЗа повеќе информации, контактирајте со него."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Со овој уред управува:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nСо вашиот профил управува:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nВашиот администратор може да ги следи вашиот уред и мрежната активност, вклучувајќи ги е-поштата, апликациите и безбедните веб-локации.\n\nЗа повеќе информации, контактирајте со администраторот."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Со вашиот профил управува:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторот може да ја следи мрежната активност, вклучувајќи е-пошта, апликации и безбедни веб-локации. За повеќе информации, контактирајте со него.\n\n}Дадовте дозвола „<xliff:g id="APPLICATION">%2$s</xliff:g>}“ да постави ВПН-конекција. И оваа апликација може да ја следи мрежната активност."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Со овој профил управува:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистраторот може да ја следи мрежната активност, вклучувајќи е-пошта, апликации и безбедни веб-локации. За повеќе информации, контактирајте со него.\n\nИсто така, поврзани сте со ВПН („<xliff:g id="APPLICATION">%2$s</xliff:g>“). И операторот на ВПН-услуги може да ја следи мрежната активност."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Со овој уред управува:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nСо вашиот профил управува:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистраторот може да ја следи мрежната активност, вклучувајќи е-пошта, апликации и безбедни веб-локации. За повеќе информации, контактирајте со него.\n\nДадовте дозвола „<xliff:g id="APPLICATION">%3$s</xliff:g>“ да постави ВПН-конекција. И оваа апликација може да ја следи мрежната активност."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Со овој уред управува:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nСо вашиот профил управува:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистраторот може да ја следи мрежната активност, вклучувајќи е-пошта, апликации и безбедни веб-локации. За повеќе информации, контактирајте со него.\n\nИсто така, поврзани сте со ВПН („<xliff:g id="APPLICATION">%3$s</xliff:g>“). И операторот на ВПН-услуги може да ја следи мрежната активност."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Уредот ќе остане заклучен додека рачно не го отклучите"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Добивајте известувања побрзо"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Видете ги пред да отклучите"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Не, фала"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Постави"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Звукот го исклучи <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ml-rIN/config.xml b/packages/SystemUI/res/values-ml-rIN/config.xml
new file mode 100644
index 0000000..d2d29f9
--- /dev/null
+++ b/packages/SystemUI/res/values-ml-rIN/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1സെ,10സെ,30സെ,60സെ,120സെ"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-ml-rIN/strings.xml b/packages/SystemUI/res/values-ml-rIN/strings.xml
index 74ff0a8..e10963d 100644
--- a/packages/SystemUI/res/values-ml-rIN/strings.xml
+++ b/packages/SystemUI/res/values-ml-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"മായ്‌ക്കുക"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"ലിസ്‌റ്റിൽ നിന്നും നീക്കംചെയ്യുക"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"അപ്ലിക്കേഷൻ വിവരം"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"നിങ്ങളുടെ പുതിയ സ്ക്രീനുകൾ ഇവിടെ ദൃശ്യമാകുന്നു"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"സമീപകാല അപ്ലിക്കേഷനുകൾ നിരസിക്കുക"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"ഒരു സമീപകാല അപ്ലിക്കേഷൻ"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"മടങ്ങുക"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"ഹോം"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"മെനു"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"പുതിയ സ്ക്രീനുകൾ"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"തിരയൽ"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ക്യാമറ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ഫോണ്‍"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"അണ്‍ലോക്ക് ചെയ്യുക"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"അൺലോക്കുചെയ്യുക"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ഫോൺ തുറക്കുക"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ക്യാമറ തുറക്കുക"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ടൈപ്പുചെയ്യൽ രീതി ബട്ടൺ മാറുക."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"അനുയോജ്യതാ സൂം ബട്ടൺ."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ചെറുതിൽ നിന്ന് വലിയ സ്‌ക്രീനിലേക്ക് സൂം ചെയ്യുക."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi രണ്ട് ബാറുകൾ."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi മൂന്ന് ബാറുകൾ."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi മികച്ച സിഗ്‌നൽ."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> എന്നതിലേക്ക് കണക്‌റ്റുചെയ്‌തു."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> എന്നതിലേക്ക് കണക്‌റ്റുചെയ്‌തു."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX ഇല്ല."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ഒരു ബാർ."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX രണ്ട് ബാറുകൾ."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter പ്രവർത്തനക്ഷമമാണ്."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"റിംഗർ വൈബ്രേറ്റ് ചെയ്യുന്നു."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"റിംഗർ നിശ്ശബ്‌ദമാണ്."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> നിരസിക്കുക."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> നിരസിച്ചു."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> ആരംഭിക്കുന്നു."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"അറിയിപ്പ് നിരസിച്ചു."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"അറിയിപ്പ് ഷെയ്‌ഡ്."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ദ്രുത ക്രമീകരണങ്ങൾ."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ലോക്ക് സ്‌ക്രീൻ."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ക്രമീകരണങ്ങൾ"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"പുതിയ സ്ക്രീനുകൾ."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ഉപയോക്താവ് <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi ഓണാക്കി."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"മൊബൈൽ <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ബാറ്ററി <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"വിമാന മോഡ് <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"ലൊക്കേഷൻ <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"വിമാന മോഡ് ഓഫാണ്."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"വിമാന മോഡ് ഓണാണ്."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"വിമാന മോഡ് ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"വിമാന മോഡ് ഓണാക്കി."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth ഓഫാണ്."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth ഓണാണ്."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth കണക്‌റ്റുചെയ്യുന്നു."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth കണക്‌റ്റുചെയ്തു."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth ഓണാക്കി."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"ലൊക്കേഷൻ റിപ്പോർട്ടുചെയ്യൽ ഓഫാണ്."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"ലൊക്കേഷൻ റിപ്പോർട്ടുചെയ്യൽ ഓണാണ്."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"ലൊക്കേഷൻ റിപ്പോർട്ടുചെയ്യൽ ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"ലൊക്കേഷൻ റിപ്പോർട്ടുചെയ്യൽ ഓണാക്കി."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g>-ന് അലാറം സജ്ജീകരിച്ചു."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"പാനൽ അടയ്‌ക്കുക"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"കൂടുതൽ സമയം"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"കുറഞ്ഞ സമയം"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"പാനൽ അടയ്‌ക്കുക."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"കൂടുതൽ സമയം."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"സമയം കുറയ്‌ക്കുക."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ഫ്ലാഷ്‌ലൈറ്റ് ഓഫാണ്."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ഫ്ലാഷ്‌ലൈറ്റ് ഓണാണ്."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ഫ്ലാഷ്‌ലൈറ്റ് ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ഫ്ലാഷ്‌ലൈറ്റ് ഓണാക്കി."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"വർണ്ണ വൈപരീത്യം ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"വർണ്ണ വൈപരീത്യം ഓണാക്കി."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"മൊബൈൽ ഹോട്ട്‌സ്‌പോട്ട് ഓഫാക്കി."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"മൊബൈൽ ഹോട്ട്‌സ്‌പോട്ട് ഓണാക്കി."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"സ്ക്രീൻ കാസ്‌റ്റുചെയ്യൽ നിർത്തി."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ഡിസ്പ്ലേ തെളിച്ചം"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G ഡാറ്റ ഓഫാണ്"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G ഡാറ്റ ഓഫാണ്"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"സെല്ലുലാർ ഡാറ്റ ഓഫാണ്"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"ലൊക്കേഷൻ സജ്ജീകരിച്ചത് GPS ആണ്"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"ലൊക്കേഷൻ അഭ്യർത്ഥനകൾ സജീവമാണ്"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"എല്ലാ വിവരങ്ങളും മായ്‌ക്കുക."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ക്രമീകരണങ്ങൾ"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"അറിയിപ്പ് ക്രമീകരണങ്ങൾ"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ക്രമീകരണങ്ങൾ"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"സ്‌ക്രീൻ യാന്ത്രികമായി തിരിയും."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"സ്‌ക്രീൻ ലാൻഡ്‌സ്‌കേപ്പ് ഓറിയന്റേഷനിൽ ലോക്കുചെയ്‌തു."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"സ്‌ക്രീൻ പോർട്രെയ്‌റ്റ് ഓറിയന്റേഷനിൽ ലോക്കുചെയ്‌തു."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"സ്ക്രീൻ ഇപ്പോൾ യാന്ത്രികമായി തിരിയും."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ലാൻഡ്‌സ്‌കേപ്പ് ഓറിയന്റേഷനിൽ ഇപ്പോൾ സ്ക്രീൻ ലോക്കുചെയ്‌തു."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"പോർട്രെയ്‌റ്റ് ഓറിയന്റേഷനിൽ ഇപ്പോൾ സ്ക്രീൻ ലോക്കുചെയ്‌തു."</string>
     <string name="dessert_case" msgid="1295161776223959221">"ഡെസേർട്ട് കെയ്സ്"</string>
     <string name="start_dreams" msgid="7219575858348719790">"ഡേഡ്രീം"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ഇതർനെറ്റ്"</string>
@@ -200,7 +231,7 @@
     <string name="quick_settings_bluetooth_off_label" msgid="8159652146149219937">"Bluetooth ഓഫുചെയ്യുക"</string>
     <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"ജോടിയാക്കിയ ഉപകരണങ്ങളൊന്നും ലഭ്യമല്ല"</string>
     <string name="quick_settings_brightness_label" msgid="6968372297018755815">"തെളിച്ചം"</string>
-    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"യാന്ത്രിക റൊട്ടേറ്റ്"</string>
+    <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"ഓട്ടോ റൊട്ടേറ്റ്"</string>
     <string name="quick_settings_rotation_locked_label" msgid="6359205706154282377">"റൊട്ടേഷൻ ലോക്കുചെയ്‌തു"</string>
     <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"പോർട്രെയ്‌റ്റ്"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"ലാൻഡ്‌സ്‌കേപ്പ്"</string>
@@ -236,16 +267,15 @@
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"ടെതറിംഗ്"</string>
     <string name="quick_settings_hotspot_label" msgid="6046917934974004879">"ഹോട്ട്‌സ്‌പോട്ട്"</string>
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"അറിയിപ്പുകൾ"</string>
-    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"ഫ്‌ലാഷ്‌ലൈറ്റ്"</string>
+    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"ഫ്ലാഷ്‌ലൈറ്റ്"</string>
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"സെല്ലുലാർ ഡാറ്റ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ഡാറ്റ ഉപയോഗം"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ശേഷിക്കുന്ന ഡാറ്റ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"പരിധി കഴിഞ്ഞു"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"പരിധിയെത്തി – ഡാറ്റ ഉപയോഗം താൽക്കാലികമായി നിർത്തി"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ഉപയോഗിച്ചു"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> പരിധി"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> മുന്നറിയിപ്പ്"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"നിങ്ങളുടെ പുതിയ സ്ക്രീനുകൾ ഇവിടെ ദൃശ്യമാകുന്നു"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"അപ്ലിക്കേഷൻ വിവരം"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"അപ്ലിക്കേഷനിലേക്ക് ലോക്കുചെയ്യൽ"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"തിരയുക"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"തിരയൽ"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> എന്നതിനായി മുകളിലേയ്‌ക്ക് സ്ലൈഡുചെയ്യുക."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> എന്നതിനായി ഇടത്തേയ്‌ക്ക് സ്ലൈഡുചെയ്യുക."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"അലാറങ്ങൾ ഉൾപ്പടെ തടസ്സങ്ങളൊന്നുമില്ല"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"തടസ്സങ്ങളൊന്നുമില്ല. അലാറങ്ങൾ പോലുമില്ല."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"തടസ്സങ്ങളൊന്നുമില്ല"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"മുൻഗണനാ തടസ്സങ്ങൾ മാത്രം"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"നിങ്ങളുടെ അടുത്ത അലാറം <xliff:g id="ALARM_TIME">%s</xliff:g>-നാണ്"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"നിങ്ങൾ <xliff:g id="ALARM_TIME">%s</xliff:g>-ന് അലാറം കേൾക്കില്ല"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"ആവശ്യം കുറഞ്ഞ അറിയിപ്പുകൾ ചുവടെ നൽകിയിരിക്കുന്നു"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"തുറക്കുന്നതിന് വീണ്ടും സ്‌പർശിക്കുക"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"അൺലോക്കുചെയ്യുന്നതിന് മുകളിലേക്ക് സ്വൈപ്പുചെയ്യുക"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ഫോണിനായി വലതുവശത്ത് സ്വൈപ്പുചെയ്യുക"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ക്യാമറയ്‌ക്കായി ഇടതുവശത്ത് സ്വൈപ്പുചെയ്യുക"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"അവ്യക്തം"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ഒന്നുമില്ല"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"മുന്‍‌ഗണന"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"എല്ലാം"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ചാർജ്ജുചെയ്യുന്നു (പൂർണ്ണമാകുന്നതിന്, <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"ഉപയോക്താവ് മാറുക"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"ഉപയോക്താവിനെ മാറ്റുക, <xliff:g id="CURRENT_USER_NAME">%s</xliff:g> എന്നയാളാണ് നിലവിലുള്ള ഉപയോക്താവ്"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"പ്രൊഫൈൽ കാണിക്കുക"</string>
     <string name="user_add_user" msgid="5110251524486079492">"ഉപയോക്താവിനെ ചേര്‍ക്കുക"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"പുതിയ ഉപയോക്താവ്"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"അതിഥി"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"അതിഥിയെ ചേർക്കുക"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"അതിഥിയെ നീക്കംചെയ്യുക"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"അതിഥി സെഷനിൽ നിന്ന് പുറത്തുകടക്കണോ?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"അതിഥി സെഷനിൽ നിന്ന് പുറത്തുകടക്കുന്നത് പ്രാദേശിക ഡാറ്റയെ നീക്കംചെയ്യും."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"അതിഥിയെ നീക്കംചെയ്യണോ?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ഈ സെഷനിലെ എല്ലാ അപ്ലിക്കേഷനുകളും ഡാറ്റയും ഇല്ലാതാക്കും."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"നീക്കംചെയ്യുക"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"അതിഥിയ്‌ക്ക് വീണ്ടും സ്വാഗതം!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ഒരു മിനിറ്റ് ദൈർഘ്യം"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d മിനിറ്റ് ദൈർഘ്യം"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ഒരു മണിക്കൂർ ദൈർഘ്യം"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d മണിക്കൂർ ദൈർഘ്യം"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"നിങ്ങളുടെ സെഷൻ തുടരണോ?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"പുനരാംരംഭിക്കുക"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"അതെ, തുടരുക"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"പുതിയ ഉപയോക്താവിനെ ചേർക്കണോ?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"നിങ്ങൾ ഒരു പുതിയ ഉപയോക്താവിനെ ചേർക്കുമ്പോൾ, ആ വ്യക്തിയ്‌ക്ക് അവരുടെ ഇടം സജ്ജീകരിക്കേണ്ടതുണ്ട്.\n\nമറ്റ് എല്ലാ ഉപയോക്താക്കൾക്കുമായി ഏതൊരു ഉപയോക്താവിനും അപ്ലിക്കേഷനുകൾ അപ്‌ഡേറ്റുചെയ്യാനാവും."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ബാറ്ററി സേവർ ഓണാണ്"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"പ്രവർത്തനവും പശ്ചാത്തല ഡാറ്റയും കുറയ്‌ക്കുന്നു"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ബാറ്ററി സേവർ ഓഫാക്കുക"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"ഇപ്പോൾ ആരംഭിക്കുക"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"അറിയിപ്പുകൾ ഒന്നുമില്ല"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ഉപകരണം നിരീക്ഷിക്കപ്പെടാം"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"പ്രൊഫൈൽ നിരീക്ഷിക്കപ്പെടാം"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"നെറ്റ്‌വർക്ക് നിരീക്ഷിക്കപ്പെടാം"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ഉപകരണം നിരീക്ഷിക്കൽ"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"പ്രൊഫൈൽ നിരീക്ഷിക്കൽ"</string>
     <string name="monitoring_title" msgid="169206259253048106">"നെറ്റ്‌വർക്ക് നിരീക്ഷിക്കൽ"</string>
-    <string name="open_app" msgid="4011771120339160755">"അപ്ലിക്കേഷൻ തുറക്കുക"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN പ്രവർത്തനരഹിതമാക്കുക"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN വിച്‌ഛേദിക്കുക"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"നിങ്ങളുടെ ഉപകരണം നിയന്ത്രിക്കുന്നത് ഇതാണ്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nനിങ്ങളുടെ അഡ്‌മിനിസ്ട്രേറ്റർക്ക് ഇമെയിലുകളും അപ്ലിക്കേഷനുകളും വെബ്‌സൈറ്റുകൾ സുരക്ഷിതമാക്കലും ഉൾപ്പെടെയുള്ള നിങ്ങളുടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനങ്ങൾ നിരീക്ഷിക്കാനാകും.\n\nകൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്ട്രേറ്ററെ ബന്ധപ്പെടുക."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"VPN കണക്ഷൻ സജ്ജീകരിക്കാൻ നിങ്ങൾ \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" എന്നതിന് അനുമതി നൽകി.\n\n ഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, വെബ്‌സൈറ്റുകൾ സുരക്ഷിതമാക്കൽ എന്നിവ ഉൾപ്പെടെയുള്ള നിങ്ങളുടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനങ്ങൾ ഈ അപ്ലിക്കേഷന് നിരീക്ഷിക്കാനാകും."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"നിങ്ങൾ VPN-ൽ (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") കണക്റ്റുചെയ്‌തിരിക്കുന്നു.\n\nഇമെയിലുകളും അപ്ലിക്കേഷനുകളും വെബ്‌സൈറ്റുകൾ സുരക്ഷിതമാക്കലും ഉൾപ്പെടെയുള്ള നെറ്റ്‌വർക്ക് പ്രവർത്തനങ്ങൾ നിരീക്ഷിക്കാൻ നിങ്ങളുടെ VPN സേവന ദാതാവിന് കഴിയും."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"നിങ്ങളുടെ ഉപകരണം നിയന്ത്രിക്കുന്നത് ഇതാണ്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nനിങ്ങളുടെ അഡ്‌മിനിസ്ട്രേറ്റർ ഇമെയിലുകളും അപ്ലിക്കേഷനുകളും വെബ്‌സൈറ്റുകൾ സുരക്ഷിതമാക്കലും ഉൾപ്പെടെയുള്ള നിങ്ങളുടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനങ്ങൾ നിരീക്ഷിക്കുന്നതിന് പ്രാപ്‌തമാണ്. കൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്ട്രേറ്ററെ ബന്ധപ്പെടുക.\n\nഅതോടൊപ്പം, നിങ്ങൾ ഒരു VPN കണക്ഷൻ സജ്ജീകരിക്കാൻ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" എന്നതിന് അനുമതിയും നൽകി. ഈ അപ്ലിക്കേഷന് നെറ്റ്‌വർക്ക് പ്രവർത്തനവും നിരീക്ഷിക്കാനാകും."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"നിങ്ങളുടെ ഉപകരണം നിയന്ത്രിക്കുന്നത് ഇതാണ്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nനിങ്ങളുടെ അഡ്‌മിനിസ്ട്രേറ്റർ ഇമെയിലുകളും അപ്ലിക്കേഷനുകളും വെബ്‌സൈറ്റുകൾ സുരക്ഷിതമാക്കലും ഉൾപ്പെടെയുള്ള നിങ്ങളുടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനങ്ങൾ നിരീക്ഷിക്കുന്നതിന് പ്രാപ്‌തമാണ്. കൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്ട്രേറ്ററെ ബന്ധപ്പെടുക.\n\nഅതോടൊപ്പം, നിങ്ങൾ ഒരു VPN-ലും (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") കണക്റ്റുചെയ്തിരിക്കുന്നു. നിങ്ങളുടെ VPN സേവന ദാതാവിന് നെറ്റ്‌വർക്ക് പ്രവർത്തനവും നിരീക്ഷിക്കാനാകും."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ഈ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നിങ്ങളുടെ ഉപകരണവും നെറ്റ്‌വർക്ക് പ്രവർത്തനവും അഡ്‌മിനിസ്‌ട്രേറ്റർക്ക് നിരീക്ഷിക്കാനാകും.\n\nകൂടുതൽ വിവരങ്ങൾക്ക് നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്ററെ ബന്ധപ്പെടുക."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ഈ ഉപകരണത്തെ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nനിങ്ങളുടെ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നിങ്ങളുടെ ഉപകരണവും നെറ്റ്‌വർക്ക് പ്രവർത്തനവും അഡ്‌മിനിസ്‌ട്രേറ്റർക്ക് നിരീക്ഷിക്കാനാകും.\n\nകൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്‌ട്രേറ്ററെ ബന്ധപ്പെടുക."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ഈ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനം നിരീക്ഷിക്കാൻ നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്റർ പ്രാപ്‌തനാണ്. കൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്‌ട്രേറ്ററെ ബന്ധപ്പെടുക.\n\nഒരു VPN കണക്ഷൻ സജ്ജമാക്കാൻ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" അനുമതിയും നിങ്ങൾ നൽകി. നെറ്റ്‌വർക്കും പ്രവർത്തനവും നിരീക്ഷിക്കാൻ ഈ അപ്ലിക്കേഷനാകും."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ഈ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനം നിരീക്ഷിക്കാൻ നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്റർ പ്രാപ്‌തനാണ്. കൂടുതൽ വിവരങ്ങൾക്ക് നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്ററെ ബന്ധപ്പെടുക.\n\nഒരു VPN-ലേക്കും (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") കണക്‌റ്റുചെയ്‌തിരിക്കുന്നു. നിങ്ങളുടെ VPN സേവന ദാതാവിന് നെറ്റ്‌വർക്ക് പ്രവർത്തനവും നിരീക്ഷിക്കാനാകും."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ഈ ഉപകരണത്തെ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nനിങ്ങളുടെ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനം നിരീക്ഷിക്കാൻ നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്റർ പ്രാപ്‌തനാണ്. കൂടുതൽ വിവരങ്ങൾക്ക് അഡ്‌മിനിസ്‌ട്രേറ്ററെ ബന്ധപ്പെടുക.\n\nഒരു VPN കണക്ഷൻ സജ്ജമാക്കാൻ \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" അനുമതിയും നിങ്ങൾ നൽകി. നെറ്റ്‌വർക്കും പ്രവർത്തനവും നിരീക്ഷിക്കാൻ ഈ അപ്ലിക്കേഷനാകും."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ഈ ഉപകരണത്തെ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nനിങ്ങളുടെ പ്രൊഫൈൽ നിയന്ത്രിക്കുന്നത്:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nഇമെയിലുകൾ, അപ്ലിക്കേഷനുകൾ, സുരക്ഷാ വെബ്‌സൈറ്റുകൾ എന്നിവ ഉൾപ്പെടെ നെറ്റ്‌വർക്ക് പ്രവർത്തനം നിരീക്ഷിക്കാൻ നിങ്ങളുടെ അഡ്‌മിനിസ്‌ട്രേറ്റർ പ്രാപ്‌തനാണ്.\n\nഒരു VPN-ലേക്കും (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\")കണക്‌റ്റുചെയ്‌തിരിക്കുന്നു. നിങ്ങളുടെ VPN സേവന ദാതാവിന് നെറ്റ്‌വർക്ക് പ്രവർത്തനവും നിരീക്ഷിക്കാനാകും."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"നിങ്ങൾ സ്വമേധയാ അൺലോക്കുചെയ്യുന്നതുവരെ ഉപകരണം ലോക്കുചെയ്‌തതായി തുടരും"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"അറിയിപ്പുകൾ വേഗത്തിൽ നേടുക"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"അൺലോക്കുചെയ്യുന്നതിന് മുമ്പ് അവ കാണുക"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"വേണ്ട, നന്ദി"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"സജ്ജീകരിക്കുക"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g>, മ്യൂട്ടുചെയ്‌തു"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-mn-rMN/strings.xml b/packages/SystemUI/res/values-mn-rMN/strings.xml
index 7cd48a0..7d53269 100644
--- a/packages/SystemUI/res/values-mn-rMN/strings.xml
+++ b/packages/SystemUI/res/values-mn-rMN/strings.xml
@@ -84,6 +84,10 @@
     <string name="accessibility_search_light" msgid="1103867596330271848">"Хайх"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камер"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Утас"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Тайлах"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"тайлах"</string>
+    <string name="phone_label" msgid="2320074140205331708">"утас нээх"</string>
+    <string name="camera_label" msgid="7261107956054836961">"камер нээх"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Оруулах аргыг сэлгэх товч."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Тохиромжтой өсгөх товч."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Жижгээс том дэлгэцрүү өсгөх."</string>
@@ -110,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi хоёр баганатай."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi гурван баганатай."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi дохио дүүрэн."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>-тай холбогдсон."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>-тай холбогдсон."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX байхгүй."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX нэг багана."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX хоёр баганатай."</string>
@@ -149,27 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter идэвхтэй болов."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Хонхны чичиргээ."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Хонхыг хаах."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>-г хаах."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> байхгүй."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>-г эхлүүлж байна."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Мэдэгдэл хаагдсан."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Мэдэгдлийн хураангуй самбар"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Шуурхай тохиргоо."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Дэлгэц түгжих."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Тохиргоо"</string>
     <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Саяхны дэлгэцүүд."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Хэрэглэгч <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi унтраасан."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi асаасан."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобайл <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батерей <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Нислэгийн горим <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Блютүүт <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Байршил <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Нислэгийн горим идэвхгүй."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Нислэгийн горим идэвхтэй."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Нислэгийн горимыг унтраасан."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Нислэгийн горимыг асаасан."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Блютүүт идэвхгүй."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Блютүүт идэвхтэй."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Блютүүтийг холбож байна."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Блютүүт холбогдсон."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Блютүүтийг унтраасан."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Блютүүтийг асаасан."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Байршил мэдээлэлт идэвхгүй."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Байршил мэдээлэлт идэвхтэй."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Байршил мэдээлэлтийг унтраасан."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Байршил мэдээлэлтийг асаасан."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Сэрүүлгийг <xliff:g id="TIME">%s</xliff:g>-д тохируулсан."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Самбарыг хаах"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Цаг нэмэх"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Цаг хасах"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Самбарыг хаах."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Хугацаа нэмэх."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Хугацаа хасах."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Флаш гэрэл унтарсан."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Флаш гэрэл ассан."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Флаш гэрлийг унтраасан."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Флаш гэрлийг асаасан."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Өнгө урвуулагчийг унтраасан."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Өнгө урвуулагчийг асаасан."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобайл хотспотыг унтраасан."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобайл хотспотыг асаасан."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Дэлгэц дамжуулалт зогссон."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Дэлгэцийн гэрэлтэлт"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G дата идэвхгүй"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G дата идэвхгүй"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Үүрэн дата идэвхгүй"</string>
@@ -182,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS байршил"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Байршлын хүсэлтүүд идэвхтэй"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Бүх мэдэгдлийг цэвэрлэх."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Тохиргоо"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Мэдэгдлийн тохиргоо"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> тохиргоо"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Дэлгэц автоматаар эргэнэ."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Дэлгэц хэвтээ чиглэлд түгжигдсэн."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Дэлгэц босоо чиглэлээр түгжигдсэн."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Дэлгэц автоматаар эргэнэ."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Дэлгэц хэвтээ чиглэлд түгжигдсэн."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Дэлгэц босоо чиглэлд түгжигдсэн."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Амттаны хайрцаг"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Этернет"</string>
@@ -237,7 +271,7 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Үүрэн дата"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Дата ашиглалт"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Үлдсэн дата"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Хязгаараас хэтэрсэн"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Хязгаарт хүрсэн – дата ашиглалтыг түр зогсоосон"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ашигласан"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> хязгаар"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> анхааруулга"</string>
@@ -253,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Хайх"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>-г гулсуулах."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> хийх зүүнлүү гулсуулах."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Саад болохгүй, сэрүүлгийг бас"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Тасалдал байхгүй. Сэрүүлэг ч байхгүй."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Ямар ч тасалдалгүй"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Зөвхөн нэн тэргүүний тасалдалд"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Таны дараагийн сэрүүлгийн цаг <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -261,42 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Та <xliff:g id="ALARM_TIME">%s</xliff:g>-д өөрийн сэрүүлгээ сонсохгүй"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Яаралтай биш мэдэгдлүүдийг доор"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Нээхийн тулд дахин хүрнэ үү"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Түгжээг тайлах бол шудрана уу"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Утас гаргахын тулд баруун шударна уу"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Камер гаргахын тулд зүүн шударна уу"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Тодорхойгүй"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Хоосон"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Нэн тэргүүний"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Бүгд"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Цэнэглэж байна (дүүргэхэд <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Хэрэглэгчийг сэлгэх"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Хэрэглэгчийг сэлгэх, одоогийн хэрэглэгч <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Профайлыг харуулах"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Хэрэглэгч нэмэх"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Шинэ хэрэглэгч"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Зочин"</string>
     <string name="guest_new_guest" msgid="600537543078847803">"Зочин нэмэх"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Зочныг хасах"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Зочны нэвтрэлтээс гарч байна уу?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Зочны нэвтрэлтээс гарснаар локал датаг арилгах болно."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Зочныг хасах уу?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Энэ сешний бүх апп болон дата устах болно."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Хасах"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Тавтай морилно уу!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Нэг минутын турш"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d минутын турш"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Нэг цагийн турш"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d цагийн турш"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Та үргэлжлүүлэхийг хүсэж байна уу?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Дахин эхлүүлэх"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Тийм, үргэлжлүүлэх"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Шинэ хэрэглэгч нэмэх үү?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Та шинэ хэрэглэгч нэмбэл, тухайн хүн өөрийн профайлыг тохируулах шаардлагатай.\n\nАль ч хэрэглэгч бүх хэрэглэгчийн апп-уудыг шинэчлэх боломжтой."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Батерей хэмнэгч асаалттай"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Ажиллагаа болон далд датаг бууруулна"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Батерей хэмнэгчийг унтраах"</string>
@@ -308,15 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Одоо эхлүүлэх"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Мэдэгдэл байхгүй"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Төхөөрөмжийг хянах боломжтой"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профайлыг хянаж байж болзошгүй"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Сүлжээ хянагдаж байж болзошгүй"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Төхөөрөмжийн хяналт"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Профайл хяналт"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Сүлжээний хяналт"</string>
-    <string name="open_app" msgid="4011771120339160755">"Апп нээх"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN идэвхгүйжүүлэх"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN таслах"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n удирдаж байна.\nТаны админ таны төхөөрөмж болон имэйл, апп-ууд болон аюулгүй вебсайтууд зэрэг таны сүлжээний үйл ажиллагааг хянах боломжтой.\n\nДэлгэрэнгүй мэдээллийг админаас авна уу."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Та \"<xliff:g id="APPLICATION">%1$s</xliff:g>\"-д VPN холболт үүсгэх зөвшөөрөл өгсөн.\n\nЭнэ апп таны төхөөрөмж болон имэйл, апп-ууд болон аюулгүй вэбсайтууд зэрэг сүлжээний үйл ажиллагааг хянах боломжтой."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Та VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") холбогдсон байна.\n\nТаны VPN үйлчилгээ үзүүлэгч нь таны төхөөрөмж болон имэйл, апп-ууд болон аюулгүй вэбсайтууд зэрэг таны сүлжээний үйл ажиллагааг хянах боломжтой."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n удирдаж байна \n Танай админ имэйл, апп-ууд, аюулгүй вэбсайтууд зэргийг оруулан таны сүлжээний үйл ажиллагааг хянах боломжтой. Дэлгэрэнгүй мэдээллийг админаас авна уу.\n\nМөн та <xliff:g id="APPLICATION">%2$s</xliff:g>-д VPN холболт үүсгэх зөвшөөрөл өгсөн байна. Энэ апп мөн сүлжээний үйл ажиллагааг хянах боломжтой."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n удирдаж байна \nТанай админ имэйл, апп-ууд, аюулгүй вэбсайтууд зэргийг оруулан таны сүлжээний үйл ажиллагааг хянах боломжтой. Дэлгэрэнгүй мэдээллийг админаас авна уу.\n\nМөн та VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\")-д холбогдсон байна. VPN үйлчилгээ үзүүлэгч таны сүлжээний үйл ажиллагааг мөн хянах боломжтой."</string>
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Энэ профайлыг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\nудирдаж байна\nТаны админ таны төхөөрөмж, сүлжээний идэвхжилт, имэйл, апп-ууд болон аюулгүй вебсайтуудыг хянах боломжтой.\n\nДэлгэрэнгүй мэдээллийг админаасаа авна уу."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n удирддаг. Таны профайлыг \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n удирддаг\nТаны админ таны төхөөрөмж, сүлжээний идэвхжилт, имэйл, апп-ууд болон аюулгүй вебсайтуудыг хянах боломжтой.\n\nДэлгэрэнгүй мэдээллийг админаасаа авна уу."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Энэ профайлыг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\nудирдаж байна\nТаны админ сүлжээний идэвхжилт, имэйл, апп-ууд болон аюулгүй вебсайтуудыг хянах боломжтой. Дэлгэрэнгүй мэдээллийг админаасаа авна уу.\n\nМөн та \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"-д VPN холболт үүсгэх зөвшөөрөл өгсөн. Энэ апп сүлжээний идэвхжилтийг хянах боломжтой."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Энэ профайлыг \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\nудирдаж байна\nТаны админ таны сүлжээний үйл ажиллагаа, имэйл, апп-ууд, аюулгүй вебсайтуудыг хянах боломжтой. Дэлгэрэнгүй мэдээллийг админаасаа авна уу.\n\nМөн та VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\")-д холбогдсон байна. Таны VPN үйлчилгээ үзүүлэгч таны сүлжээний идэвхжилтийг хянах боломжтой."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n удирдаж байна. Таны профайлыг \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\nудирдаж байна\nТаны админ таны сүлжээний идэвхжилт, имэйл, апп-ууд, аюулгүй вэбсайтуудыг хянах боломжтой. Дэлгэрэнгүй мэдээллийг админаасаа авна уу.\n\nМөн та \"<xliff:g id="APPLICATION">%3$s</xliff:g>\"-д VPN холболт үүсгэх зөвшөөрөл өгсөн. Энэ апп нь таны сүлжээний идэвхжилтийг хянах боломжтой."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Энэ төхөөрөмжийг \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n удирддаг. Таны профайлыг \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n удирддаг\nТаны админ таны төхөөрөмж, сүлжээний идэвхжилт, имэйл, апп-ууд болон аюулгүй вебсайтуудыг хянах боломжтой.Дэлгэрэнгүй мэдээллийг админаасаа авна уу.\n\nМөн та VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\")-д холбогдсон байна. Таны VPN үйлчилгээ үзүүлэгч таны сүлжээний идэвхжилтийг хянах боломжтой."</string>
     <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Таныг гараар онгойлгох хүртэл төхөөрөмж түгжээтэй байх болно"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Мэдэгдлийг хурдан авах"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Түгжээг тайлахын өмнө үзнэ үү"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Үгүй"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Тохируулах"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g>-с хаасан"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-mr-rIN/config.xml b/packages/SystemUI/res/values-mr-rIN/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-mr-rIN/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-mr-rIN/strings.xml b/packages/SystemUI/res/values-mr-rIN/strings.xml
index d7931f5..9a611ca 100644
--- a/packages/SystemUI/res/values-mr-rIN/strings.xml
+++ b/packages/SystemUI/res/values-mr-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"साफ करा"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"सूचीमधून काढा"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"अॅप माहिती"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"आपल्या अलीकडील स्क्रीन येथे दिसतात"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"अलीकडील अॅप्स डिसमिस करा"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 अलीकडील अ‍ॅप"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"परत"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"मुख्‍यपृष्‍ठ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"मेनू"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"अलीकडील स्क्रीन"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"शोधा"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"कॅमेरा"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"फोन"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"अनलॉक करा"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"अनलॉक करा"</string>
+    <string name="phone_label" msgid="2320074140205331708">"फोन उघडा"</string>
+    <string name="camera_label" msgid="7261107956054836961">"कॅमेरा उघडा"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"इनपुट पद्धत स्‍विच करा बटण."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"सुसंगतता झूम बटण."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"लहानपासून मोठ्‍या स्‍क्रीनवर झूम करा."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi दोन बार."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi तीन बार."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"WiFi सिग्नल पूर्ण."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> शी कनेक्‍ट केले."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> शी कनेक्‍ट केले."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX नाही."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX एक बार."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX दोन बार."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter सक्षम केले."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"रिंगर कंपन."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"रिंगर मूक."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> डिसमिस करा."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> डिसमिस केला."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> प्रारंभ करीत आहे."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"सूचना डिसमिस केल्या."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"सूचना शेड."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"द्रुत सेटिंग्ज."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"लॉक स्क्रीन."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"सेटिंग्ज"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"अलीकडील स्क्रीन."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"वापरकर्ता <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi बंद झाले."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi चालू झाले."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"मोबाईल <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"बॅटरी <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"विमान मोड <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"स्‍थान <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"विमान मोड बंद."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"विमान मोड चालू."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"विमान मोड बंद केला."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"विमान मोड चालू केला."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth बंद."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth चालू."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth कनेक्ट करत आहे."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth कनेक्‍ट केले."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth बंद केले."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth चालू केले."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"स्थान अहवाल बंद."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"स्थान अहवाल चालू."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"स्थान अहवाल बंद केला."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"स्थान अहवाल चालू केला."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> साठी अलार्म सेट केला."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"पॅनेल बंद करा"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"अधिक वेळ"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"कमी वेळ"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"पॅनेल बंद करा."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"अधिक वेळ."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"कमी वेळ."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"फ्लॅशलाइट बंद."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"फ्लॅशलाइट चालू."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"फ्लॅशलाइट बंद केला."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"फ्लॅशलाइट चालू केला."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"रंग उत्क्रमण बंद केले."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"रंग उत्क्रमण चालू केले."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"मोबाईल हॉटस्पॉट बंद केला."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"मोबाईल हॉटस्पॉट चालू केला."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"स्क्रीन कास्ट करणे थांबले."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"प्रदर्शन चमक"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G डेटा बंद आहे"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G डेटा बंद आहे"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"सेल्युलर डेटा बंद आहे"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS द्वारे स्थान सेट केले"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"स्थान विनंत्या सक्रिय"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"सर्व सूचना साफ करा."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"सेटिंग्ज"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"सूचना सेटिंग्ज"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> सेटिंग्ज"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"स्क्रीन स्वयंचलितपणे फिरेल."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"भूदृश्य अभिमुखतेमध्ये स्क्रीन लॉक केली आहे."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"पोर्ट्रेट अभिमुखतेमध्ये स्क्रीन लॉक केली आहे."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"स्क्रीन आता स्वयंचलितपणे फिरेल."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"स्‍क्रीन आता भूदृश्य अभिमुखतेत लॉक केली आहे."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"स्क्रीन आता पोर्ट्रेट अभिमुखतेत लॉक केली आहे."</string>
     <string name="dessert_case" msgid="1295161776223959221">"मिष्ठान्न प्रकरण"</string>
     <string name="start_dreams" msgid="7219575858348719790">"डेड्रीम"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"इथरनेट"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"सेल्युलर डेटा"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"डेटा वापर"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"शिल्लक डेटा"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"मर्यादेबाहेर"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"मर्यादा गाठली – डेटा वापरास विराम दिला"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> वापरले"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> मर्यादा"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> चेतावणी"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"आपल्या अलीकडील स्क्रीन येथे दिसतात"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"अनुप्रयोग माहिती"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"अ‍ॅप-लॉक-करणे"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"शोधा"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"शोध"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> साठी वर स्लाइड करा."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> साठी डावीकडे स्लाइड करा."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"अलार्मसह, कोणतेही व्‍यत्यय नाही"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"कोणतेही व्यत्यय नाहीत. अगदी अलार्मचे देखील नाहीत."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"कोणतेही व्यत्यय नाही"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"प्राधान्य व्‍यत्यय केवळ"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"आपला पुढील अलार्म <xliff:g id="ALARM_TIME">%s</xliff:g> वाजता आहे"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"आपण आपला अलार्म <xliff:g id="ALARM_TIME">%s</xliff:g> वाजता ऐकणार नाही"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"खाली कमी तातडीच्या सूचना"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"उघडण्यासाठी पुन्हा स्पर्श करा"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"अनलॉक करण्यासाठी स्वाइप करा"</string>
     <string name="phone_hint" msgid="3101468054914424646">"फोन साठी उजवीकडे स्वाइप करा"</string>
     <string name="camera_hint" msgid="5241441720959174226">"कॅमेर्‍यासाठी डावीकडे स्वाइप करा"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्‍चितपणे"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"काहीही नाही"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"प्राधान्य"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"सर्व"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"(<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> पूर्ण होईपर्यंत) चार्ज होत आहे"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"वापरकर्ता स्विच करा"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"वापरकर्ता स्विच करा, वर्तमान वापरकर्ता <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"प्रोफाईल दर्शवा"</string>
     <string name="user_add_user" msgid="5110251524486079492">"वापरकर्ता जोडा"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"नवीन वापरकर्ता"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"अतिथी"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"अतिथी जोडा"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"अतिथी काढा"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"अतिथी सत्रातून निर्गमन करायचे?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"अतिथी सत्रातून निर्गमन केल्‍याने स्‍थानिक डेटा काढला जाईल."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"अतिथी काढायचे?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"या सत्रातील सर्व अ‍ॅप्स आणि डेटा हटविला जाईल."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"काढा"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"अतिथी, आपले पुन्‍हा स्‍वागत आहे!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"एक मिनिटासाठी"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d मिनिटांसाठी"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"एका तासासाठी"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d तासांसाठी"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"आपण आपले सत्र सुरु ठेवू इच्छिता?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"येथून प्रारंभ करा"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"होय, सुरु ठेवा"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"नवीन वापरकर्ता जोडायचा?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"आपण एक नवीन वापरकर्ता जोडता तेव्हा, त्या व्यक्तीने त्यांचे स्थान सेट करणे आवश्यक असते.\n\nकोणताही वापरकर्ता इतर सर्व वापरकर्त्यांसाठी अॅप्स अद्यतनित करू शकतो."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"बॅटरी बचतकर्ता चालू आहे"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"कार्यप्रदर्शन आणि पार्श्वभूमी डेटा कमी करते"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"बॅटरी बचतकर्ता बंद करा"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"आता प्रारंभ करा"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"सूचना नाहीत"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"डिव्हाइसचे परीक्षण केले जाऊ शकते"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"प्रोफाईलचे परीक्षण केले जाऊ शकते"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"नेटवर्कचे परीक्षण केले जाऊ शकते"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"डिव्हाइस परीक्षण"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"प्रोफाईल परीक्षण"</string>
     <string name="monitoring_title" msgid="169206259253048106">"नेटवर्क परीक्षण"</string>
-    <string name="open_app" msgid="4011771120339160755">"अ‍ॅप उघडा"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN अक्षम करा"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN डिस्कनेक्ट करा"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"हे डिव्हाइस याद्वारे व्यवस्थापित केले जाते:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइट यासह, आपल्या डिव्हाइस आणि नेटवर्क क्रियाकलापाचे परीक्षण करू शकतो.\n\nअधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"आपण VPN कनेक्शन सेट करण्यासाठी \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ला परवानगी दिली आहे.\n\nहा अॅप ईमेल, अॅप्स आणि सुरक्षित वेबसाइट यासह, आपल्या डिव्हाइस आणि नेटवर्क क्रियाकलापाचे परीक्षण करू शकतो."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"आपण VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") कनेक्ट केले आहे.\n\nआपला VPN सेवा प्रदाता ईमेल, अॅप्स आणि सुरक्षित वेबसाइट यासह, आपल्या डिव्हाइस आणि नेटवर्क क्रियाकलापाचे परीक्षण करू शकतो."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"हे डिव्हाइस याद्वारे व्यवस्थापित केले जाते:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइट, यासह आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, आपण VPN कनेक्शन सेट करण्यासाठी \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ला परवानगी दिली आहे. हा अॅप नेटवर्क क्रियाकलापाचे देखील परीक्षण करू शकतो."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"हे डिव्हाइस याद्वारे व्यवस्थापित केले जाते:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइट यासह आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, आपण एका VPN शी कनेक्ट केले आहे (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). आपला VPN सेवा प्रदाता नेटवर्क क्रियाकलापाचे देखील परीक्षण करू शकतो."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"हे प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या डिव्हाइसचे आणि नेटवर्क क्रियाकलापाचे परीक्षण करू शकतो.\n\nअधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"हे डिव्हाइस याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nआपले प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या डिव्हाइसचे आणि नेटवर्क क्रियाकलापाचे परीक्षण करू शकतो.\n\nअधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"हे प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, VPN कनेक्शन सेट करण्यासाठी आपण \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ला परवानगी दिली आहे. हा अॅप नेटवर्क क्रियाकलापाचे देखील परीक्षण करू शकतो."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"हे प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, आपण एका VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") शी कनेक्ट केलेले आहे. आपला VPN सेवा प्रदाता नेटवर्क क्रियाकलापाचे देखील परीक्षण करू शकतो."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"हे डिव्हाइस याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nआपले प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, VPN कनेक्शन सेट करण्यासाठी आपण \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ला परवानगी दिली आहे. हा अॅप नेटवर्क क्रियाकलापाचे परीक्षण देखील करू शकतो."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"हे डिव्हाइस याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nआपले प्रोफाईल याद्वारे व्यवस्थापित केले आहे:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nआपला प्रशासक ईमेल, अॅप्स आणि सुरक्षित वेबसाइटसह, आपल्या नेटवर्क क्रियाकलापाचे परीक्षण करण्यास सक्षम आहे. अधिक माहितीसाठी, आपल्या प्रशासकाशी संपर्क साधा.\n\nतसेच, आपण एका VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") शी कनेक्ट केलेले आहे. आपला VPN सेवा प्रदाता नेटवर्क क्रियाकलापाचे देखील परीक्षण करू शकतो."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"आपण व्यक्तिचलितपणे अनलॉक करेपर्यंत डिव्हाइस लॉक केलेले राहील"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"सूचना अधिक जलद मिळवा"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"आपण अनलॉक करण्‍यापूर्वी त्यांना पहा"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"नाही धन्यवाद"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"सेट अप"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> द्वारे नि:शब्द केले"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ms-rMY/strings.xml b/packages/SystemUI/res/values-ms-rMY/strings.xml
index f4b29f6..8527881 100644
--- a/packages/SystemUI/res/values-ms-rMY/strings.xml
+++ b/packages/SystemUI/res/values-ms-rMY/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Pdm bersih"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Alih keluar dari senarai"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Maklumat aplikasi"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Skrin terbaru anda terpapar di sini"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Buang aplikasi terbaharu"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplikasi terbaharu"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Kembali"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Rumah"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Skrin terbaru"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Cari"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Buka kunci"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"buka kunci"</string>
+    <string name="phone_label" msgid="2320074140205331708">"buka telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"buka kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Butang tukar kaedah input."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Butang zum keserasian."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Skrin zum lebih kecil kepada lebih besar."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi dua bar."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi tiga bar."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Isyarat WiFi penuh."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Disambungkan kepada <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Disambungkan kepada <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Tiada WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX satu bar."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX dua bar."</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Mesin Teletaip didayakan."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Pendering bergetar."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Pendering senyap."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Ketepikan <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ditolak."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Memulakan <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Pemberitahuan diketepikan."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Bidai pemberitahuan."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Tetapan pantas."</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Kunci skrin."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"Tetapan"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Skrin terbaru."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Pengguna <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi dimatikan."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi dihidupkan."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mudah Alih <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateri <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mod Pesawat <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokasi <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Mod pesawat dimatikan."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Mod pesawat dihidupkan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Mod pesawat dimatikan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Mod pesawat dihidupkan."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth dimatikan."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth dihidupkan."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth menyambung."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth disambungkan."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth dimatikan."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth dihidupkan."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Pelaporan lokasi dimatikan."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Pelaporan lokasi dihidupkan."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Pelaporan lokasi dimatikan."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Pelaporan lokasi dihidupkan."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Penggera ditetapkan pada <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Tutup panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Lagi masa"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Kurang masa"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Tutup panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Lagi masa."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kurang masa."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lampu suluh dimatikan."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lampu suluh dihidupkan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lampu suluh dimatikan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lampu suluh dihidupkan."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Penyongsangan warna dimatikan."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Penyongsangan warna dihidupkan."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Tempat liputan mudah alih bergerak dimatikan."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Tempat liputan mudah alih bergerak dihidupkan."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Penghantaran skrin dihentikan."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Kecerahan paparan"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Data 2G-3G dimatikan"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Data 4G dimatikan"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Data selular dimatikan"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokasi ditetapkan oleh GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Permintaan lokasi aktif"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Padamkan semua pemberitahuan."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Tetapan"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Tetapan pemberitahuan"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> tetapan"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skrin akan berputar secara automatik."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skrin dikunci dalam orientasi landskap."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skrin dikunci dalam orientasi potret."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skrin kini akan berputar secara automatik."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skrin kini dikunci dalam orientasi landskap."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skrin kini dikunci dalam orientasi potret."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Bekas Pencuci Mulut"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Lamun"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Data selular"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Penggunaan data"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Baki data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Melebihi had"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Mencapai had - penggunaan data dijeda"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> digunakan"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> had"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Amaran <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Skrin terbaru anda terpapar di sini"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Maklumat Aplikasi"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"kunci ke apl"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"cari"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Carian"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Luncurkan ke atas untuk <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Luncurkan ke kiri untuk <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Tiada gangguan, termasuk penggera"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Tiada gangguan, walau penggera sekalipun."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Tiada gangguan"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Gangguan keutamaan sahaja"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Penggera anda yang seterusnya pada <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Anda tdk akan mdgr penggera anda pd <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Pemberitahuan kurang penting di bawah"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Sentuh sekali lagi untuk membuka"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Leret ke atas untuk membuka kunci"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Leret ke kanan untuk telefon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Leret ke kiri untuk kamera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Selama-lamanya"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Tiada"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Keutamaan"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Semua"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Mengecas (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> sehingga penuh)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Tukar pengguna"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Tukar pengguna, pengguna semasa <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Tunjuk profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Tambah pengguna"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Pengguna baharu"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Tetamu"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Keluar dari sesi tetamu?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Data tempatan akan dialih keluar apabila anda keluar dari sesi tetamu."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Tambah tetamu"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Alih keluar tetamu"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Alih keluar tetamu?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Semua apl dan data dalam sesi ini akan dipadam."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Alih keluar"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Selamat kembali, tetamu!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Selama satu minit"</item>
-    <item quantity="other" msgid="6924190729213550991">"Selama %d minit"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Selama satu jam"</item>
-    <item quantity="other" msgid="5408537517529822157">"Selama %d jam"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Adakah anda ingin meneruskan sesi anda?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Mulakan semula"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ya, teruskan"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Tambah pengguna baharu?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Apabila anda menambah pengguna baharu, orang itu perlu menyediakan ruang mereka.\n\nMana-mana pengguna boleh mengemas kini apl untuk semua pengguna lain."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Penjimat bateri dihidupkan"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Mengurangkan prestasi dan data latar belakang"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Matikan penjimat bateri"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Mulakan sekarang"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Tiada pemberitahuan"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Peranti mungkin dipantau"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil mungkin dipantau"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Rangkaian mungkin dipantau"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Pemantauan peranti"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Pemantauan profil"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Pemantauan rangkaian"</string>
-    <string name="open_app" msgid="4011771120339160755">"Buka apl"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Lumpuhkan VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Putuskan sambungan VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Peranti ini diurus oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda boleh mengawasi aktiviti peranti dan rangkaian anda, termasuk e-mel, apl dan tapak web selamat.\n\nUntuk maklumat lanjut, hubungi pentadbir anda."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Anda memberi \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" kebenaran untuk menyediakan sambungan VPN.\n\nApl ini boleh memantau aktiviti peranti dan rangkaian anda, termasuk e-mel, apl dan tapak web yang selamat."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Anda disambungkan ke VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nPembekal perkhidmatan VPN anda boleh memantau aktiviti peranti dan rangkaian anda termasuk e-mel, apl dan tapak web selamat."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Peranti ini diuruskan oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda berkemampuan memantau aktiviti rangkaian anda termasuk e-mel, apl dan tapak web yang selamat. Untuk maklumat lanjut, hubungi pentadbir anda.\n\nAnda juga memberikan \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" kebenaran untuk menyediakan rangkaian VPN. Apl ini juga boleh memantau aktiviti rangkaian."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Peranti ini diuruskan oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda berkemampuan memantau aktiviti rangkaian anda termasuk e-mel, apl dan tapak web yang selamat. Untuk maklumat lanjut, hubungi pentadbir anda.\n\nAnda juga disambungkan ke VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Pembekal perkhidmatan VPN anda juga boleh memantau aktiviti rangkaian."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profil ini diurus oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda boleh mengawasi aktiviti peranti dan rangkaian anda, termasuk e-mel, apl dan tapak web selamat.\n\nUntuk mdptkn maklumat lanjut, hubungi pentadbir anda."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Peranti ini diurus oleh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil anda diurus oleh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nPentadbir anda boleh memantau peranti dan aktiviti rangkaian anda, termasuk e-mel, apl dan tapak web yg selamat.\n\nUtk mndapatkan mklumat lanjut, hubungi pentadbir anda."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profil ini diurus oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda berkemampuan memantau aktiviti rangkaian anda termasuk e-mel, apl dan tapak web yang selamat. Untuk mdptkn maklumat lanjut, hubungi pentadbir anda.\n\nAnda juga memberi \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"kebenaran untuk menyediakan rangkaian VPN. Apl ini juga boleh memantau aktiviti rangkaian."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profil ini diurus oleh:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nPentadbir anda berkemampuan memantau aktibiti rangkaian anda termasuk e-mel, apl dan tapak web yang selamat. Untuk mdptkn maklumat lanjut, hubungi pentadbir anda.\n\nAnda jg disambung ke VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Pmbekal pkhidmatn VPN anda juga boleh memantau aktiviti rangkaian."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Peranti ini diurus olh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil anda diurus olh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nPentadbir anda bkemampuan mmantau aktiviti rgkaian anda tmasuk e-mel, apl dan tapak web yg slmt. Untuk mdptkn maklumat lanjut, hubungi pentadbir anda.\n\nAnda jg mberi \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" kebenaran utk menyediakan smbungn VPN. Apl ini jg blh mmantau aktiviti rngkaian."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Peranti ini diurus olh:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil anda diurus olh:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nPentadbir anda blh mmantau pranti dn aktiviti rgkaian anda, tmasuk e-mel, apl dan tapak web yg slmt. Utk mdapatkan mklumat lanjut, hubungi pentadbir anda.\n\nAnda juga disambungkn ke VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Pmbekal perkhidmatan VPN anda jg blh memantau rangkaian aktiviti."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Peranti akan kekal terkunci sehingga anda membuka kunci secara manual"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Dapatkan pemberitahuan lebih cepat"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Lihat sebelum anda membuka kunci"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Tidak"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Sediakan"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Diredam oleh <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-my-rMM/config.xml b/packages/SystemUI/res/values-my-rMM/config.xml
new file mode 100644
index 0000000..805d893
--- /dev/null
+++ b/packages/SystemUI/res/values-my-rMM/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"၁စက္ကန့်၊ ၁၀စက္ကန့်၊ ၃၀စက္ကန့်၊ 60စက္ကန့်၊ ၁၂၀စက္ကန့်"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-my-rMM/strings.xml b/packages/SystemUI/res/values-my-rMM/strings.xml
index f6a89e0..30f53f9 100644
--- a/packages/SystemUI/res/values-my-rMM/strings.xml
+++ b/packages/SystemUI/res/values-my-rMM/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"ရှင်းလင်းရန်"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"စာရင်းမှ ဖယ်မည်"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"အပ်ပလီကေးရှင်း အချက်အလက်များ"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"သင်၏ မကြာမီက မျက်နှာပြင်များ ဒီမှာ ပေါ်လာကြမည်"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"လတ်တလောအပ်ပလီကေးရှင်းများအား ဖယ်ထုတ်မည်"</string>
     <!-- String.format failed for translation -->
     <!-- no translation found for status_bar_accessibility_recent_apps:other (1040784359794890744) -->
@@ -33,29 +32,29 @@
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"အကြောင်းကြားချက်များ။"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"ဘက်ထရီ အားနည်းနေ"</string>
     <string name="battery_low_percent_format" msgid="1077244949318261761">"<xliff:g id="NUMBER">%d%%</xliff:g> ကျန်ရှိသည်"</string>
-    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> ကျန်နေ။ ဘက်ထရီ ချွေတာသူ ဖွင့်ထား။"</string>
+    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> ကျန်နေ။ ဘက်ထရီ ချွေတာသူ ဖွင့်ထား။"</string>
     <string name="invalid_charger" msgid="4549105996740522523">"လက်ရှိUSBအားသွင်းခြင်း အသုံးမပြုနိုင်ပါ \n ပေးထားသောအားသွင်းကိရိယာကိုသာ အသုံးပြုပါ"</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"USB အားသွင်းမှု မပံ့ပိုးပါ။"</string>
-    <string name="invalid_charger_text" msgid="5474997287953892710">"ပေးခဲ့သည့် အားသွင်းစက်ကိုသာ အသုံးပြုပါ"</string>
+    <string name="invalid_charger_text" msgid="5474997287953892710">"ပေးခဲ့သည့် အားသွင်းစက်ကိုသာ အသုံးပြုပါ"</string>
     <string name="battery_low_why" msgid="4553600287639198111">"ဆက်တင်များ"</string>
-    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"ဘက်ထရီ ချွေတာမှုကို ဖွင့်ရမလား?"</string>
-    <string name="battery_saver_confirmation_ok" msgid="7507968430447930257">"ဖွင့်ရန်"</string>
-    <string name="battery_saver_start_action" msgid="5576697451677486320">"ဘက်ထရီ ချွေတာမှုကို ဖွင့်ရန်"</string>
+    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"ဘက်ထရီ ချွေတာမှုကို ဖွင့်ရမလား?"</string>
+    <string name="battery_saver_confirmation_ok" msgid="7507968430447930257">"ဖွင့်ရန်"</string>
+    <string name="battery_saver_start_action" msgid="5576697451677486320">"ဘက်ထရီ ချွေတာမှုကို ဖွင့်ရန်"</string>
     <string name="status_bar_settings_settings_button" msgid="3023889916699270224">"အပြင်အဆင်များ"</string>
     <string name="status_bar_settings_wifi_button" msgid="1733928151698311923">"ဝိုင်ဖိုင်"</string>
     <string name="status_bar_settings_airplane" msgid="4879879698500955300">"လေယာဥ်ပျံပေါ်အသုံးပြုသောစနစ်"</string>
-    <string name="status_bar_settings_auto_rotation" msgid="3790482541357798421">"မျက်နှာပြင်အလိုအလျောက်လှည့်ရန်"</string>
+    <string name="status_bar_settings_auto_rotation" msgid="3790482541357798421">"မျက်နှာပြင်အလိုအလျောက်လှည့်ရန်"</string>
     <string name="status_bar_settings_mute_label" msgid="554682549917429396">"MUTE"</string>
     <string name="status_bar_settings_auto_brightness_label" msgid="511453614962324674">"AUTO"</string>
     <string name="status_bar_settings_notifications" msgid="397146176280905137">"သတိပေးချက်များ"</string>
-    <string name="bluetooth_tethered" msgid="7094101612161133267">"ဘလူးတုသ်မှတဆင့်ပြန်လည်ချိတ်ဆက်ခြင်း"</string>
-    <string name="status_bar_input_method_settings_configure_input_methods" msgid="3504292471512317827">"ထည့်သွင်းနည်းများ သတ်မှတ်ခြင်း"</string>
+    <string name="bluetooth_tethered" msgid="7094101612161133267">"ဘလူးတုသ်မှတဆင့်ပြန်လည်ချိတ်ဆက်ခြင်း"</string>
+    <string name="status_bar_input_method_settings_configure_input_methods" msgid="3504292471512317827">"ထည့်သွင်းနည်းများ သတ်မှတ်ခြင်း"</string>
     <string name="status_bar_use_physical_keyboard" msgid="7551903084416057810">"ခလုတ်ပါဝင်သော ကီးဘုတ်"</string>
-    <string name="usb_device_permission_prompt" msgid="834698001271562057">"<xliff:g id="APPLICATION">%1$s</xliff:g>အပ်ပလီကေးရှင်းအား USBပစ္စည်းကို ချိတ်ဆက်ရန်ခွင့်ပြုမည်လား"</string>
-    <string name="usb_accessory_permission_prompt" msgid="5171775411178865750">"<xliff:g id="APPLICATION">%1$s</xliff:g> အပ်ပလီကေးရှင်းကို USB တွဲဖက်ပစ္စည်းများအား ဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုသည်"</string>
-    <string name="usb_device_confirm_prompt" msgid="5161205258635253206">"<xliff:g id="ACTIVITY">%1$s</xliff:g> အားUSBပစ္စည်း ချိတ်ဆက်နေစဥ် ဖွင့်မည်လား"</string>
-    <string name="usb_accessory_confirm_prompt" msgid="3808984931830229888">"<xliff:g id="ACTIVITY">%1$s</xliff:g> အား USBတွဲဖက်ပစ္စည်း ချိတ်ဆက်ထားစဥ် ဖွင့်မည်"</string>
-    <string name="usb_accessory_uri_prompt" msgid="513450621413733343">"ဒီUSBပစ္စည်းနှင့်ဘယ်အပ်ပလီကေးရှင်းမှ အလုပ်မလုပ်ပါ။ ပိုမိုသိရန် <xliff:g id="URL">%1$s</xliff:g>တွင် လေ့လာပါ"</string>
+    <string name="usb_device_permission_prompt" msgid="834698001271562057">"<xliff:g id="APPLICATION">%1$s</xliff:g>အပ်ပလီကေးရှင်းအား USBပစ္စည်းကို ချိတ်ဆက်ရန်ခွင့်ပြုမည်လား"</string>
+    <string name="usb_accessory_permission_prompt" msgid="5171775411178865750">"<xliff:g id="APPLICATION">%1$s</xliff:g> အပ်ပလီကေးရှင်းကို USB တွဲဖက်ပစ္စည်းများအား ဝင်ရောက်ကြည့်ရှုရန်ခွင့်ပြုသည်"</string>
+    <string name="usb_device_confirm_prompt" msgid="5161205258635253206">"<xliff:g id="ACTIVITY">%1$s</xliff:g> အားUSBပစ္စည်း ချိတ်ဆက်နေစဥ် ဖွင့်မည်လား"</string>
+    <string name="usb_accessory_confirm_prompt" msgid="3808984931830229888">"<xliff:g id="ACTIVITY">%1$s</xliff:g> အား USBတွဲဖက်ပစ္စည်း ချိတ်ဆက်ထားစဥ် ဖွင့်မည်"</string>
+    <string name="usb_accessory_uri_prompt" msgid="513450621413733343">"ဒီUSBပစ္စည်းနှင့်ဘယ်အပ်ပလီကေးရှင်းမှ အလုပ်မလုပ်ပါ။ ပိုမိုသိရန် <xliff:g id="URL">%1$s</xliff:g>တွင် လေ့လာပါ"</string>
     <string name="title_usb_accessory" msgid="4966265263465181372">"USBတွဲဖက်ပစ္စည်းများ"</string>
     <string name="label_view" msgid="6304565553218192990">"မြင်ကွင်း"</string>
     <string name="always_use_device" msgid="1450287437017315906">"ဤUSBပစ္စည်းများအတွက် မူရင်းအတိုင်း အသုံးပြုပါ။"</string>
@@ -63,28 +62,31 @@
     <string name="usb_debugging_title" msgid="4513918393387141949">"USB အမှားရှာဖွေပြင်ဆင်ခြင်း ခွင့်ပြုပါမည်လား?"</string>
     <string name="usb_debugging_message" msgid="2220143855912376496">"ဒီကွန်ပျူတာရဲ့ RSA key fingerprint ကတော့:\n<xliff:g id="FINGERPRINT">%1$s</xliff:g> ဖြစ်ပါသည်"</string>
     <string name="usb_debugging_always" msgid="303335496705863070">"ဒီကွန်ပျူတာမှ အမြဲခွင့်ပြုရန်"</string>
-    <string name="compat_mode_on" msgid="6623839244840638213">"ဖန်သားပြင်ပြည့် ချဲ့ခြင်း"</string>
-    <string name="compat_mode_off" msgid="4434467572461327898">"ဖန်သားပြင်အပြည့်ဆန့်ခြင်း"</string>
+    <string name="compat_mode_on" msgid="6623839244840638213">"ဖန်သားပြင်ပြည့် ချဲ့ခြင်း"</string>
+    <string name="compat_mode_off" msgid="4434467572461327898">"ဖန်သားပြင်အပြည့်ဆန့်ခြင်း"</string>
     <string name="screenshot_saving_ticker" msgid="7403652894056693515">"ဖန်သားပြင်ဓါတ်ပုံသိမ်းစဉ်.."</string>
     <string name="screenshot_saving_title" msgid="8242282144535555697">"ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား သိမ်းဆည်းပါမည်"</string>
     <string name="screenshot_saving_text" msgid="2419718443411738818">"ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား သိမ်းဆည်းပြီးပါပြီ"</string>
     <string name="screenshot_saved_title" msgid="6461865960961414961">"ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား ဖမ်းယူပြီး"</string>
-    <string name="screenshot_saved_text" msgid="1152839647677558815">"သင့်ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား ကြည့်ရှုရန် ထိပါ"</string>
+    <string name="screenshot_saved_text" msgid="1152839647677558815">"သင့်ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား ကြည့်ရှုရန် ထိပါ"</string>
     <string name="screenshot_failed_title" msgid="705781116746922771">"ဖန်သားပြင်ဓါတ်ပုံရိုက်ခြင်းအား မဖမ်းစီးနိုင်ပါ"</string>
-    <string name="screenshot_failed_text" msgid="1260203058661337274">"မျက်နှာပြင်လျှပ်တပြက်ပုံကို မရုက်နိုင်ခဲ့ပါ၊ သိုလှောင်မှု နေရာ အကန့်အသတ် ရှိနေ၍ သို့မဟုတ် app သို့မဟုတ် သင်၏ အဖွဲ့အစည်းက ခွင့်မပြု၍ ဖြစ်နိုင်သည်။"</string>
+    <string name="screenshot_failed_text" msgid="1260203058661337274">"မျက်နှာပြင်လျှပ်တပြက်ပုံကို မရုက်နိုင်ခဲ့ပါ၊ သိုလှောင်မှု နေရာ အကန့်အသတ် ရှိနေ၍ သို့မဟုတ် app သို့မဟုတ် သင်၏ အဖွဲ့အစည်းက ခွင့်မပြု၍ ဖြစ်နိုင်သည်။"</string>
     <string name="usb_preference_title" msgid="6551050377388882787">"USB ဖိုင်ပြောင်း ရွေးမှုများ"</string>
-    <string name="use_mtp_button_title" msgid="4333504413563023626">"မီဒီယာပလေရာအနေဖြင့် တပ်ဆင်ရန် (MTP)"</string>
-    <string name="use_ptp_button_title" msgid="7517127540301625751">"ကင်မရာအနေဖြင့် တပ်ဆင်ရန် (PTP)"</string>
+    <string name="use_mtp_button_title" msgid="4333504413563023626">"မီဒီယာပလေရာအနေဖြင့် တပ်ဆင်ရန် (MTP)"</string>
+    <string name="use_ptp_button_title" msgid="7517127540301625751">"ကင်မရာအနေဖြင့် တပ်ဆင်ရန် (PTP)"</string>
     <string name="installer_cd_button_title" msgid="2312667578562201583">"Macအတွက်Andriodဖိုင်ပြောင်းအပ်ပလီကေးရှင်းထည့်ခြင်း"</string>
     <string name="accessibility_back" msgid="567011538994429120">"နောက်သို့"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"ပင်မစာမျက်နှာ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"မီနူး"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"မကြာမီက မျက်နှာပြင်များ"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ရှာဖွေရန်"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"ကင်မရာ"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ဖုန်း"</string>
-    <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ထည့်သွင်းခြင်းခလုတ်အား ပြောင်းခြင်း"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"သော့ဖွင့်ရန်"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"သော့ဖွင့်ရန်"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ဖုန်းကို ဖွင့်ရန်"</string>
+    <string name="camera_label" msgid="7261107956054836961">"ကင်မရာ ဖွင့်ရန်"</string>
+    <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ထည့်သွင်းခြင်းခလုတ်အား ပြောင်းခြင်း"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"အံ့ဝင်သောချုံ့ချဲ့ခလုတ်"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ဖန်သားပြင်ပေါ်တွင် အသေးမှအကြီးသို့ချဲ့ခြင်း"</string>
     <string name="accessibility_bluetooth_connected" msgid="2707027633242983370">"ဘလူးတုသ်ချိတ်ဆက်ထားမှု"</string>
@@ -93,23 +95,25 @@
     <string name="accessibility_battery_one_bar" msgid="7774887721891057523">"ဘတ္တရီတစ်ဘား။"</string>
     <string name="accessibility_battery_two_bars" msgid="8500650438735009973">"ဘတ္တရီနှစ်ဘား။"</string>
     <string name="accessibility_battery_three_bars" msgid="2302983330865040446">"ဘတ္တရီသုံးဘား။"</string>
-    <string name="accessibility_battery_full" msgid="8909122401720158582">"ဘတ္တရီအပြည့်။"</string>
+    <string name="accessibility_battery_full" msgid="8909122401720158582">"ဘတ္တရီအပြည့်။"</string>
     <string name="accessibility_no_phone" msgid="4894708937052611281">"ဖုန်းလိုင်းမရှိပါ။"</string>
     <string name="accessibility_phone_one_bar" msgid="687699278132664115">"ဖုန်းလိုင်းတစ်ဘား။"</string>
     <string name="accessibility_phone_two_bars" msgid="8384905382804815201">"ဖုန်းလိုင်းနှစ်ဘား။"</string>
     <string name="accessibility_phone_three_bars" msgid="8521904843919971885">"ဖုန်းလိုင်းသုံးဘား။"</string>
-    <string name="accessibility_phone_signal_full" msgid="6471834868580757898">"ဖုန်းလိုင်းအပြည့်။"</string>
+    <string name="accessibility_phone_signal_full" msgid="6471834868580757898">"ဖုန်းလိုင်းအပြည့်။"</string>
     <string name="accessibility_no_data" msgid="4791966295096867555">"ဒေတာမရှိပါ။"</string>
     <string name="accessibility_data_one_bar" msgid="1415625833238273628">"ဒေတာတစ်ဘား။"</string>
-    <string name="accessibility_data_two_bars" msgid="6166018492360432091">"ဒေတာထုတ်လွှင့်မှု ၂ဘားဖမ်းမိခြင်း။"</string>
+    <string name="accessibility_data_two_bars" msgid="6166018492360432091">"ဒေတာထုတ်လွှင့်မှု ၂ဘားဖမ်းမိခြင်း။"</string>
     <string name="accessibility_data_three_bars" msgid="9167670452395038520">"ဒေတာသုံးဘား။"</string>
-    <string name="accessibility_data_signal_full" msgid="2708384608124519369">"ဒေတာထုတ်လွှင့်မှုအပြည့်ဖမ်းမိခြင်း"</string>
+    <string name="accessibility_data_signal_full" msgid="2708384608124519369">"ဒေတာထုတ်လွှင့်မှုအပြည့်ဖမ်းမိခြင်း"</string>
     <string name="accessibility_wifi_off" msgid="3177380296697933627">"ဝိုင်ဖိုင် မရှိ"</string>
     <string name="accessibility_no_wifi" msgid="1425476551827924474">"ဝိုင်ဖိုင် ချိတ်ဆက်ထားမှု မရှိပါ"</string>
     <string name="accessibility_wifi_one_bar" msgid="7735893178010724377">"ဝိုင်ဖိုင် ၁ ဘားရှိ"</string>
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"ဝိုင်ဖိုင် ၂ ဘား"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"ဝိုင်ဖိုင် ၃ ဘား"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"ဝိုင်ဖိုင် အပြည့်ရှိ"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>သို့ ချိတ်ဆက်ထား။"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>သို့ ချိတ်ဆက်ထား"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"ဝိုက်မက်စ် မရှိပါ"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"ဝိုက်မက်စ် ၁ ဘား"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"ဝိုင်မက်စ် ၂ ဘားရှိ"</string>
@@ -121,7 +125,7 @@
     <string name="accessibility_one_bar" msgid="1685730113192081895">"တစ်တုံး"</string>
     <string name="accessibility_two_bars" msgid="6437363648385206679">"၂ ဘား"</string>
     <string name="accessibility_three_bars" msgid="2648241415119396648">"၃ ဘား"</string>
-    <string name="accessibility_signal_full" msgid="9122922886519676839">"ဒေတာထုတ်လွှင့်မှုအပြည့်ဖမ်းမိခြင်း"</string>
+    <string name="accessibility_signal_full" msgid="9122922886519676839">"ဒေတာထုတ်လွှင့်မှုအပြည့်ဖမ်းမိခြင်း"</string>
     <string name="accessibility_desc_on" msgid="2385254693624345265">"ဖွင့်ထားသည်"</string>
     <string name="accessibility_desc_off" msgid="6475508157786853157">"ပိတ်ထားသည်"</string>
     <string name="accessibility_desc_connected" msgid="8366256693719499665">"ဆက်သွယ်ထားပြီး"</string>
@@ -138,7 +142,7 @@
     <string name="accessibility_data_connection_edge" msgid="4477457051631979278">"EDGE"</string>
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"ဝိုင်ဖိုင်"</string>
     <string name="accessibility_no_sim" msgid="8274017118472455155">"ဆင်းကဒ်မရှိပါ။"</string>
-    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"ဘလူးတုသ်မှတဆင့်ပြန်လည်ချိတ်ဆက်ခြင်း"</string>
+    <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"ဘလူးတုသ်မှတဆင့်ပြန်လည်ချိတ်ဆက်ခြင်း"</string>
     <string name="accessibility_airplane_mode" msgid="834748999790763092">"လေယာဥ်ပျံပေါ်အသုံးပြုသောစနစ်။"</string>
     <string name="accessibility_battery_level" msgid="7451474187113371965">"ဘတ္တရီ <xliff:g id="NUMBER">%d</xliff:g> ရာခိုင်နှုန်း။"</string>
     <string name="accessibility_settings_button" msgid="799583911231893380">"စနစ်အပြင်အဆင်များ"</string>
@@ -149,44 +153,71 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter ရရှိသည်။"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"တုန်ခါခြင်း ဖုန်းမြည်သံ"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"ဖုန်းမြည်သံပိတ်သည်။"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>ကို ပယ်လိုက်ရန်"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ထုတ်ထားသည်။"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>ကို စတင်နေသည်။"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"အကြောင်းကြားချက်ကိုဖယ်ရှားပြီး"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"အ​ကြောင်းကြားစာအကွက်"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"အမြန်လုပ် အပြင်အဆင်"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"မျက်နှာပြင် သော့ပိတ်ရန်"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ဆက်တင်များ"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"မကြာမီက မျက်နှာပြင်များ"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"သုံးစွဲသူ <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>။"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"ကြိုးမဲ့ ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"ကြိုးမဲ့ ဖွင့်ထား။"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"မိုဘိုင်းလ် <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ဘက်ထရီ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"လေယာဉ်ပေါ်သုံး စနစ် <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ဘလူးတုသ် <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"တည်နေရာ<xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"လေယာဉ် မုဒ် ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"လေယာဉ် မုဒ်ကို ဖွင့်ထား။"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"လေယာဉ် မုဒ်ကို ပိတ်ထားလိုက်ပြီ။"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"လေယာဉ် မုဒ်ကို ဖွင့်ထားလိုက်ပြီ။"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"ဘလူးတုသ် ပိတ်ထား."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"ဘလူးတုသ် ဖွင့်ထား။"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ဘလူးတုသ် ချိတ်ဆက်နေ။"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"ဘလူးတုသ် ချိတ်ဆက်ထား။"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ဘလူးတုသ် ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ဘလူးတုသ် ဖွင့်ထား။"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"တည်နေရာ သတင်းပို့မှု ပိတ်ရန်။"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"တည်နေရာ သတင်းပို့မှု ဖွင့်ရန်။"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"တည်နေရာ သတင်းပို့မှု ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"တည်နေရာ သတင်းပို့မှု ဖွင့်ထား။"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"နိုးစက်ပေးထားသော အချိန် <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"ပိတ်ရန် အကွက်"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"အချိန် တိုးရန်"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"အချိန် လျှော့ရန်"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ဘောင်ကွက် ပိတ်ရန်။"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"အချိန် တိုး"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"အချိန် လျှော့"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ဖလက်ရှမီး ပိတ်ထား"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ဖလက်ရှမီး ဖွင့်ထား။"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ဖလက်ရှမီး ပိတ်ထားသည်။"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ဖလက်ရှမီး ဖွင့်ထားသည်။"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"အရောင် ပြောင်းပြန်လှန်မှု ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"အရောင် ပြောင်းပြန်လှန်မှု ဖွင့်ထား။"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"မိုဘိုင်း ဟော့စပေါ့ ပိတ်ထား။"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"မိုဘိုင်း ဟော့စပေါ့ ဖွင့်ထား။"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"မျက်နှာပြင် ကာစ်တင် လုပ်မှု ရပ်လိုက်ပြီ။"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"တောက်ပမှုကို ပြရန်"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G ဒေတာ ပိတ်ထား"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G ဒေတာ ပိတ်ထား"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ဆယ်လူလာ ဒေတာကို ပိတ်ထား"</string>
     <string name="data_usage_disabled_dialog_title" msgid="8723412000355709802">"ဒေတာ ပိတ်ထား"</string>
-    <string name="data_usage_disabled_dialog" msgid="6468718338038876604">"သင်၏ ကိရိယာသည် သင်က သတ်မှတ်ခဲ့သည့် ကန့်သတ်ချက်ကို ပြည့်မီသွား၍ ပိတ်သွားသည်။ \n\n၎င်းကို ပြန်ပြီး ဖွင့်မှုအတွက် သင်၏ စီမံပေးသူ ထံမှ ငွေတောင်းခံ လာနိုင်ပါသည်။"</string>
-    <string name="data_usage_disabled_dialog_enable" msgid="5538068036107372895">"ဒေတာ ဖွင့်ပေးရန်"</string>
+    <string name="data_usage_disabled_dialog" msgid="6468718338038876604">"သင်၏ ကိရိယာသည် သင်က သတ်မှတ်ခဲ့သည့် ကန့်သတ်ချက်ကို ပြည့်မီသွား၍ ပိတ်သွားသည်။ \n\n၎င်းကို ပြန်ပြီး ဖွင့်မှုအတွက် သင်၏ စီမံပေးသူ ထံမှ ငွေတောင်းခံ လာနိုင်ပါသည်။"</string>
+    <string name="data_usage_disabled_dialog_enable" msgid="5538068036107372895">"ဒေတာ ဖွင့်ပေးရန်"</string>
     <string name="status_bar_settings_signal_meter_disconnected" msgid="1940231521274147771">"အင်တာနက်မရှိ"</string>
     <string name="status_bar_settings_signal_meter_wifi_nossid" msgid="6557486452774597820">"ကြိုးမဲ့ဆက်သွယ်မှု"</string>
     <string name="gps_notification_searching_text" msgid="8574247005642736060">"GPSအားရှာဖွေသည်"</string>
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPSမှတည်နေရာကိုအတည်ပြုသည်"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"တည်နေရာပြ တောင်းဆိုချက်များ အသက်ဝင်ရန်"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"သတိပေးချက်အားလုံးအား ဖယ်ရှားခြင်း။"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ဆက်တင်များ"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"အကြောင်းကြားချက် ဆက်တင်များ"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ဆက်တင်များ"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"ဖန်သားပြင်ပေါ်မှာ ပြသမှုက အလိုအလျောက် လှည့်သွားပါမည်"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ဖန်သားပြင် အနေအထားက အလျားလိုက်အဖြစ် ပုံသေ လုပ်ထားပါသည်"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ဖန်သားပြင် အနေအထားက ဒေါင်လိုက်အဖြစ် ပုံသေ လုပ်ထားပါသည်"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ယခုတော့ မျက်နှာပြင်သည် အလိုအလျောက် လည်နေမည်။"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"မျက်နှာပြင် အနေအထားကို ဘေးတိုက် အဖြစ် သော့ချထားသည်။"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"မျက်နှာပြင် အနေအထားကို ဒေါင်လိုက် အဖြစ် သော့ချထားသည်။"</string>
     <string name="dessert_case" msgid="1295161776223959221">"မုန့်ထည့်သော ပုံး"</string>
     <string name="start_dreams" msgid="7219575858348719790">"ဒေးဒရင်းမ်"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"အီသာနက်"</string>
@@ -196,13 +227,13 @@
     <string name="quick_settings_bluetooth_label" msgid="6304190285170721401">"ဘလူးတု"</string>
     <string name="quick_settings_bluetooth_multiple_devices_label" msgid="3912245565613684735">"ဘလူးတု (<xliff:g id="NUMBER">%d</xliff:g> စက်များ)"</string>
     <string name="quick_settings_bluetooth_off_label" msgid="8159652146149219937">"ဘလူးတု ပိတ်ထားရန်"</string>
-    <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"ချိတ်တွဲထားသည့် ကိရိယာများ မရှိ"</string>
+    <string name="quick_settings_bluetooth_detail_empty_text" msgid="4910015762433302860">"ချိတ်တွဲထားသည့် ကိရိယာများ မရှိ"</string>
     <string name="quick_settings_brightness_label" msgid="6968372297018755815">"အလင်းတောက်ပမှု"</string>
     <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"အော်တို-လည်"</string>
     <string name="quick_settings_rotation_locked_label" msgid="6359205706154282377">"လည်မှု သော့ပိတ်ထား"</string>
     <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"ဒေါင်လိုက်"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"ဘေးတိုက်"</string>
-    <string name="quick_settings_ime_label" msgid="7073463064369468429">"ထည့်သွင်းရန်နည်းလမ်း"</string>
+    <string name="quick_settings_ime_label" msgid="7073463064369468429">"ထည့်သွင်းရန်နည်းလမ်း"</string>
     <string name="quick_settings_location_label" msgid="5011327048748762257">"တည်နေရာ"</string>
     <string name="quick_settings_location_off_label" msgid="7464544086507331459">"တည်နေရာပြမှု မရှိ"</string>
     <string name="quick_settings_media_device_label" msgid="1302906836372603762">"မီဒီယာ စက်ပစ္စည်း"</string>
@@ -221,7 +252,7 @@
     <string name="quick_settings_cast_title" msgid="1893629685050355115">"ကာစ်တ် မျက်နှာပြင်"</string>
     <string name="quick_settings_casting" msgid="6601710681033353316">"ကာစ်တင်"</string>
     <string name="quick_settings_cast_device_default_name" msgid="5367253104742382945">"အမည်မတပ် ကိရိယာ"</string>
-    <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"ကာစ်တ် လုပ်ရန် အသင့် ရှိနေပြီ"</string>
+    <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"ကာစ်တ် လုပ်ရန် အသင့် ရှိနေပြီ"</string>
     <string name="quick_settings_cast_detail_empty_text" msgid="311785821261640623">"ကိရိယာများ မရှိ"</string>
     <string name="quick_settings_brightness_dialog_title" msgid="8599674057673605368">"အလင်းတောက်ပမှု"</string>
     <string name="quick_settings_brightness_dialog_auto_brightness_label" msgid="5064982743784071218">"အလိုအလျောက်"</string>
@@ -238,87 +269,88 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"ဆယ်လူလာ ဒေတာ"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ဒေတာ သုံးစွဲမှု"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ကျန်ရှိ ဒေတာ"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"ကန့်သတ်ချက် ကျော်လွန်"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ကန့်သတ်ချက် ပြည့်မီသွားပြီ - ဒေတာ  သုံးစွဲမှု ဆိုင်းငံ့ထားပြီ"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> သုံးထား"</string>
-    <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ကန့်သတ်ချက်"</string>
+    <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ကန့်သတ်ချက်"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> သတိပေးချက်"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"သင်၏ မကြာမီက မျက်နှာပြင်များ ဒီမှာ ပေါ်လာကြမည်"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"အပလီကေးရှင်း အင်ဖို"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"appသို့ သော့ခတ်ထားရန်"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ရှာဖွေရန်"</string>
     <string name="expanded_header_battery_charged" msgid="5945855970267657951">"အားသွင်းပြီး"</string>
     <string name="expanded_header_battery_charging" msgid="205623198487189724">"အားသွင်းနေ"</string>
-    <string name="expanded_header_battery_charging_with_time" msgid="457559884275395376">"<xliff:g id="CHARGING_TIME">%s</xliff:g> ပြည်သည့် အထိ"</string>
+    <string name="expanded_header_battery_charging_with_time" msgid="457559884275395376">"<xliff:g id="CHARGING_TIME">%s</xliff:g> ပြည်သည့် အထိ"</string>
     <string name="expanded_header_battery_not_charging" msgid="4798147152367049732">"အား မသွင်းပါ"</string>
     <string name="ssl_ca_cert_warning" msgid="9005954106902053641">"ကွန်ယက်ကို\n စောင့်ကြည့်စစ်ဆေးခံရနိုင်သည်"</string>
     <string name="description_target_search" msgid="3091587249776033139">"ရှာဖွေရန်"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> အတွက် အပေါ်ကို ပွတ်ဆွဲပါ"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> အတွက် ဖယ်ဘက်ကို ပွတ်ဆွဲပါ"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"နှိုးစက်များ အပါအဝင် ကြားဖြတ်ဝင်မှုများ မလို"</string>
-    <string name="zen_no_interruptions" msgid="7970973750143632592">"ကြားဖြတ်ဝင်မှု ခွင့်မပြုရန်"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ကြားဖြတ်ဝင်မှုများ မရှိခဲ့။ နှိုးစက်ပင် မရှိခဲ့။"</string>
+    <string name="zen_no_interruptions" msgid="7970973750143632592">"ကြားဖြတ်ဝင်မှု ခွင့်မပြုရန်"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"ဦးစားပေး ကြားဖြတ်ဝင်မှုများ သာလျှင်"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"သင်၏ နောက် နှိုးစက်၏ အချိန်မှာ<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"သင်၏ နောက် နှိုးစက်မှာ <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"သင်သည် သင်၏ <xliff:g id="ALARM_TIME">%s</xliff:g> နှိုးစက်ကို ကြားရမည် မဟုတ်"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
-    <string name="speed_bump_explanation" msgid="1288875699658819755">"အရေးပါမှု နည်းသည့် အကြောင်းကြားချက်များ အောက်မှာ"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
-    <string name="keyguard_unlock" msgid="8043466894212841998">"သော့ဖွင့်ရန် အပေါ်သို့ ပွတ်ဆွဲပါ"</string>
+    <string name="speed_bump_explanation" msgid="1288875699658819755">"အရေးပါမှု နည်းသည့် အကြောင်းကြားချက်များ အောက်မှာ"</string>
+    <string name="notification_tap_again" msgid="8524949573675922138">"ဖွင့်ရန် ထပ်ပြီး ထိပါ"</string>
+    <string name="keyguard_unlock" msgid="8043466894212841998">"သော့ဖွင့်ရန် အပေါ်သို့ ပွတ်ဆွဲပါ"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ဖုန်း အတွက် ညာသို့ ပွတ်ဆွဲပါ"</string>
     <string name="camera_hint" msgid="5241441720959174226">"ကင်မရာ အတွက် ဘယ်သို့ ပွတ်ဆွဲပါ"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"အကန့်အသတ်မရှိစွာ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"မရှိ"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ဦးစားပေးမှု"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"အားလုံး"</string>
-    <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"(<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> အပြည့် အထိ) အားသွင်းနေ"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"(<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> အပြည့် အထိ) အားသွင်းနေ"</string>
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"အသုံးပြုသူကို ပြောင်းလဲရန်"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"အသုံးပြုသူကို ပြောင်းရန်၊ လက်ရှိ အသုံးပြုသူ <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"ပရိုဖိုင်ကို ပြရန်"</string>
     <string name="user_add_user" msgid="5110251524486079492">"သုံးသူ ထပ်ထည့်ရန်"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"အသုံးပြုသူ အသစ်"</string>
-    <string name="guest_nickname" msgid="8059989128963789678">"ဧည့်သည်"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <string name="guest_exit_guest" msgid="7187359342030096885">"ဧည့်သည်ကို ဖယ်ထုတ်ရန်"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ဧည့်သည် ချိတ်ဆက်မှုထဲက ထွက်မလား?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"ဧည့်သည် ချိတ်ဆက်မှု ထဲမှ ထွက်လိုက်ခြင်းက စက်တွင်း ဒေတာကို ဖယ်ရှားပစ်မည်။"</string>
-    <string name="guest_wipe_session_title" msgid="6419439912885956132">"ပြန်လာတာ ကြိုဆိုပါသည်၊ ဧည့်သည်!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"တစ်မိနစ် အတွင်း"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d မိနစ် အတွင်း"</item>
-  </plurals>
-    <!-- String.format failed for translation -->
-    <!-- no translation found for zen_mode_duration_hours:other (5408537517529822157) -->
-    <string name="battery_saver_notification_title" msgid="237918726750955859">"ဘက်ထရီ ချွေတာသူ ဖွင့်ထား"</string>
-    <string name="battery_saver_notification_text" msgid="820318788126672692">"လုပ်ကိုင်မှုကို လျှော့ချလျက် နောက်ခံ ဒေတာကို ကန့်သတ်သည်"</string>
+    <string name="guest_nickname" msgid="8059989128963789678">"ဧည့်သည်"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"ဧည့်သည့်ကို ထည့်ပေးရန်"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"ဧည့်သည်ကို ဖယ်ထုတ်ရန်"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"ဧည့်သည်ကို ဖယ်ထုတ်လိုက်ရမလား?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ဒီချိတ်ဆက်မှု ထဲက appများ အားလုံး နှင့် ဒေတာကို ဖျက်ပစ်မည်။"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ဖယ်ထုတ်ပါ"</string>
+    <string name="guest_wipe_session_title" msgid="6419439912885956132">"ပြန်လာတာ ကြိုဆိုပါသည်၊ ဧည့်သည်!"</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"သင်သည် သင်၏ ချိတ်ဆက်မှုကို ဆက်ပြုလုပ် လိုပါသလား?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"အစမှ ပြန်စပါ"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"ဟုတ်ကဲ့၊ ဆက်လုပ်ပါ"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"အသုံးပြုသူ အသစ်ကို ထည့်ရမလား?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"သင်က အသုံးပြုသူ အသစ် တစ်ဦးကို ထည့်ပေးလိုက်လျှင်၊ ထိုသူသည် ၎င်း၏ နေရာကို သတ်မှတ်စီစဉ်ရန် လိုအပ်မည်။\n\n အသုံးပြုသူ မည်သူမဆို ကျန်အသုံးပြုသူ အားလုံးတို့အတွက် appများကို မွမ်းမံပေးနိုင်သည်။"</string>
+    <string name="battery_saver_notification_title" msgid="237918726750955859">"ဘက်ထရီ ချွေတာသူ ဖွင့်ထား"</string>
+    <string name="battery_saver_notification_text" msgid="820318788126672692">"လုပ်ကိုင်မှုကို လျှော့ချလျက် နောက်ခံ ဒေတာကို ကန့်သတ်သည်"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ဘက်ထရီ ချွေတာမှုကို ပိတ်ထားရန်"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
     <string name="notification_hidden_text" msgid="1135169301897151909">"အကြောင်းအရာများ ဝှက်ထား"</string>
-    <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> က သင်၏ မျက်နှာပြင် ပေါ်မှာ ပြသထားသည့် အရာတိုင်းကို စတင် ဖမ်းယူမည်။"</string>
+    <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> က သင်၏ မျက်နှာပြင် ပေါ်မှာ ပြသထားသည့် အရာတိုင်းကို စတင် ဖမ်းယူမည်။"</string>
     <string name="media_projection_remember_text" msgid="3103510882172746752">"နောက်ထပ် မပြပါနှင့်"</string>
     <string name="clear_all_notifications_text" msgid="814192889771462828">"အားလုံး ရှင်းလင်းရန်"</string>
     <string name="media_projection_action_text" msgid="8470872969457985954">"ယခု စတင်ပါ"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"အကြောင်းကြားချက်များ မရှိ"</string>
-    <string name="device_owned_footer" msgid="3802752663326030053">"ကိရိယာကို စောင့်ကြပ် နိုင်ပါသည်"</string>
-    <string name="vpn_footer" msgid="2388611096129106812">"ကွန်ရက်ကို ကို စောင့်ကြပ် နိုင်ပါသည်"</string>
+    <string name="device_owned_footer" msgid="3802752663326030053">"ကိရိယာကို စောင့်ကြပ် နိုင်ပါသည်"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ပရိုဖိုင်ကို စောင့်ကြပ်နိုင်သည်"</string>
+    <string name="vpn_footer" msgid="2388611096129106812">"ကွန်ရက်ကို ကို စောင့်ကြပ် နိုင်ပါသည်"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"ကိရိယာကို စောင့်ကြပ်ခြင်း"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"ပရိုဖိုင် စောင့်ကြပ်မှု"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ကွန်ရက်ကို စောင့်ကြပ်ခြင်း"</string>
-    <string name="open_app" msgid="4011771120339160755">"appကို ဖွင့်ရန်"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN ကို ပိတ်ထားရန်"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN ကို အဆက်ဖြတ်ရန်"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ဤစက်ပစ္စည်းကို စီမံခန့်ခွဲသူ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင့်အက်ဒ်မင်သည် သင့်စက်ပစ္စည်းနှင့် အီးမေးများ၊ app များ နှင့် လုံခြုံသည့်ဝက်ဘ်ဆိုက် အပါအဝင် ကွန်ယက် လှုပ်ှရားမှုများကို စောင့်ကြည့်နိုင်သည်။\n\nနောက်ထပ်အချက်အလက်များအတွက်၊ သင့်အက်ဒ်မင်ကို ဆက်သွယ်ပါ။"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"သင် \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ကို VPN စတင်သုံးခွင့်ပေးလိုက်သည်။ \n\n ဤ app သည် သင့်စက်ပစ္စည်းနှင့် အီးမေးများ၊ app များ နှင့် လုံခြုံသည့်ဝက်ဘ်ဆိုက် အပါအဝင် ကွန်ယက် လှုပ်ှရားမှုများကို စောင့်ကြည့်နိုင်သည်။"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") ကို သင်ချိတ်ဆက်မိ၏။\n\nသင့် VPN ဝန်ဆောင်မှုပေးသူသည် သင့်စက်ပစ္စည်းနှင့် အီးမေးများ၊ app များ နှင့် လုံခြုံသည့်ဝက်ဘ်ဆိုက် အပါအဝင် ကွန်ယက် လှုပ်ှရားမှုများကို စောင့်ကြည့်နိုင်သည်။"</string>
-    <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ဒီကိရိယာကို စီမံကွပ်ကဲသူမှာ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင်၏ စီမံအုပ်ချုပ်သူက သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ် နိုင်ပါသည်။ အချက်အလက်များ ပိုပြီး ရယူရန်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\n ထို့အပြင် သင်သည် \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" အား VPN ချိတ်ဆက်မှု စဖွင့်လုပ်ကိုင်ရန် ခွင့်ပြုခဲ့သည်။ ဒီ  appကပါ သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ် နိုင်ပါသည်။"</string>
-    <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ဒီကိရိယာကို စီမံကွပ်ကဲသူမှာ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင်၏  စီမံအုပ်ချုပ်သူက သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ် နိုင်ပါသည်။ အချက်အလက်များ ပိုပြီး ရယူရန်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\nထို့အပြင်၊ သင်သည် VPN  (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") သို့ ချိတ်ဆက်ထားသည်။ သင်၏ VPN ဝန်ဆောင်မှုကို စီမံပေးသူကပါ ကွန်ရက် လှုပ်ရှားမှုများကို စောင့်ကြပ်နိုင်သေးသည်။"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ဒီကိရိယာကို စီမံကွပ်ကဲသူမှာ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင်၏ စီမံအုပ်ချုပ်သူက သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ် နိုင်ပါသည်။ အချက်အလက်များ ပိုပြီး ရယူရန်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\n ထို့အပြင် သင်သည် \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" အား VPN ချိတ်ဆက်မှု စဖွင့်လုပ်ကိုင်ရန် ခွင့်ပြုခဲ့သည်။ ဒီ  appကပါ သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ် နိုင်ပါသည်။"</string>
+    <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ဒီကိရိယာကို စီမံကွပ်ကဲသူမှာ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင်၏  စီမံအုပ်ချုပ်သူက သင်၏ ကွန်ရက် လှုပ်ရှားမှုကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ် နိုင်ပါသည်။ အချက်အလက်များ ပိုပြီး ရယူရန်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\nထို့အပြင်၊ သင်သည် VPN  (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") သို့ ချိတ်ဆက်ထားသည်။ သင်၏ VPN ဝန်ဆောင်မှုကို စီမံပေးသူကပါ ကွန်ရက် လှုပ်ရှားမှုများကို စောင့်ကြပ်နိုင်သေးသည်။"</string>
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ဒီပရိုဖိုင်ကို စီမံကွပ်ကဲပေးသူ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင်၏ စီမံအုပ်ချုပ်သူသည် သင်၏ ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှုများကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ်နိုင်သည်။ \n\n နောက်ထပ် သိလိုလျှင်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ဒီကိရိယာကို စီမံကွပ်ကဲပေးသူ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nသင့် ပရိုဖိုင်ကို စီမံကွပ်ကဲပေးသူ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nသင်၏ စီမံအုပ်ချုပ်သူသည် သင်၏ ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှုများကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို၊ စောင့်ကြပ်နိုင်သည်။\n\nနောက်ထပ် သိလိုလျှင်၊ သင်၏ စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ပရိုဖိုင်ကို စီမံပေးသူ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင့် စီမံအုပ်ချုပ်သူက သင့် ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှုကို၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်၊ စောင့်ကြပ်နိုင်သည်။ ထပ် သိလိုလျှင်၊ သင့် စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\n သင်သည် \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" အား VPN ချိတ်ဆက်မှု ထူထောင်ခွင့် ပေးခဲ့သည်။ ဒီappကပါ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ်နိုင်သည်။"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ပရိုဖိုင်ကို စီမံပေးသူ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nသင့်စီမံအုပ်ချုပ်သူက သင့် ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှု၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို စောင့်ကြပ်နိုင်သည်။ ထပ် သိလိုလျှင်၊ သင့်စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။\n\nသင်သည် VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") သို့ပါ ချိတ်ထားသည်။ သင်၏ VPN စီမံပေးသူကပါ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ်နိုင်သည်။"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ကိရိယာကို စီမံပေးသူ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nသင့်ပရိုဖိုင်ကို စီမံပေးသူ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nသင့်စီမံအုပ်ချုပ်သူသည် သင့် ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှု၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို စောင့်ကြပ်နိုင်သည်။\n\nသင်သည် \"<xliff:g id="APPLICATION">%3$s</xliff:g>\"အား VPN ချိတ်ဆက်မှု ထူထောင်ခွင့် ပေးခဲ့သည်။ ဒီappကပါ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ်နိုင်သည်။"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ဒီကိရိယာ စီမံပေးသူ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nသင့် ပရိုဖိုင် စီမံပေးသူ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n စီမံအုပ်ချုပ်သူသည် သင့် ကိရိယာ နှင့် ကွန်ရက် လှုပ်ရှားမှု၊ အီးမေးလ်များ၊ appများ နှင့် လုံခြုံသည့် ဝက်ဘ်ဆိုက်များ အပါအဝင်ကို စောင့်ကြပ်နိုင်သည်။\n\nထပ် သိလိုလျှင်၊ သင့်စီမံအုပ်ချုပ်သူကို ဆက်သွယ်ပါ။ သင်သည် VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") သို့ပါ ချိတ်ထားသည်။ သင်၏ VPN စီမံပေးသူကပါ ကွန်ရက် လှုပ်ရှားမှုကို စောင့်ကြပ်နိုင်သည်။"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"သင်က လက်ဖြင့် သော့မဖွင့်မချင်း ကိရိယာမှာ သော့ပိတ်လျက် ရှိနေမည်"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"အကြောင်းကြားချက်များ မြန်မြန်ရရန်"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"မဖွင့်ခင် ၎င်းတို့ကို ကြည့်ပါ"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"မလိုအပ်ပါ"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"သတ်မှတ်ရန်"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> အသံပိတ်သည်"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-nb/strings.xml b/packages/SystemUI/res/values-nb/strings.xml
index 896cb50..9891984 100644
--- a/packages/SystemUI/res/values-nb/strings.xml
+++ b/packages/SystemUI/res/values-nb/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Fjern"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Fjern fra listen"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Info om appen"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"De sist brukte skjermene dine vises her"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Avvis nylige apper"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Én nylig app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Tilbake"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Startside"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Meny"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Sist brukte skjermer"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Søk"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefonnummer"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Lås opp"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"lås opp"</string>
+    <string name="phone_label" msgid="2320074140205331708">"åpne telefonen"</string>
+    <string name="camera_label" msgid="7261107956054836961">"åpne kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Bytt knapp for inndatametode."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Zoomknapp for kompatibilitet."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom fra mindre til større skjerm."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi – to stolper."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi – tre stolper."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi-signal er ved full styrke."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Koblet til <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Koblet til <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ingen WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX – én stolpe."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX – to stolper."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter er aktivert."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibreringsmodus."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Stille modus."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Avvis <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> avvist."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Starter <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Varselet ble skjult."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Varselskygge."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Hurtiginnstillinger."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Låseskjerm."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Innstillinger"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Sist brukte skjermer."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Bruker: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi er slått av."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi er slått på."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil – <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batteri – <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Flymodus – <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth – <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Posisjon <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Flymodus er av."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Flymodus er på."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Flymodus er slått av."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Flymodus er slått på."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth er av."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth er på."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth kobler til."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth er tilkoblet."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth er av."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth er på."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Posisjonsrapportering er av."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Posisjonsrapportering er på."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Posisjonsrapportering er slått av."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Posisjonsrapportering er slått på."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarmen ble stilt for <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Lukk panelet"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mer tid"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mindre tid"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Lukk panelet."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mer tid."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mindre tid."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lommelykten er av."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lommelykten er på."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lommelykten er slått av."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lommelykten er slått på."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inverterte farger er slått av."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inverterte farger er slått på."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobil Wi-Fi-sone er slått av."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobil Wi-Fi-sone er slått på."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Skjermcastingen er stoppet."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Lysstyrken på skjermen"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G- og 3G-data er slått av"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-datatrafikk er slått av"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobildatatrafikk er slått av"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Posisjon angitt av GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktive stedsforespørsler"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Fjern alle varslinger."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Innstillinger"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Varselinnstillinger"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>-innstillinger"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skjermen roterer automatisk."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skjermen er låst i liggende retning."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skjermen er låst i stående retning."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skjermen roterer automatisk."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skjermen er nå låst i liggende retning."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skjermen er nå låst i stående retning."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessertmonter"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Dagdrøm"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobildata"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Databruk"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Gjenværende data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Over grensen"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Grensen er nådd – databruk er stanset midlertidig"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> brukt"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Grense på <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Advarsel for <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"De sist brukte skjermene dine vises her"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Appinformasjon"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lås til app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"Søk"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Søk"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Dra opp for å <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Dra til venstre for å <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Ingen forstyrrelser – inkludert alarmer"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Ingen forstyrrelser, ikke engang alarmer."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Ingen forstyrrelser"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Bare prioriterte forstyrrelser"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Den neste alarmen din er stilt inn kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Du kommer ikke til å høre alarmen kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Mindre presserende varsler nedenfor"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Trykk på nytt for å åpne"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Sveip oppover for å låse opp"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Sveip mot høyre for å åpne telefonen"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Sveip mot venstre for å åpne kameraet"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"På ubestemt tid"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ingen"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alle"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Lader (fulladet om <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Bytt bruker"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Bytt bruker, gjeldende bruker er <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Vis profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Legg til brukere"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Ny bruker"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gjest"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Legg til gjest"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Fjern gjesten"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Vil du avslutte gjesteøkten?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Hvis du avslutter gjesteøkten, fjernes lokale data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Vil du fjerne gjesten?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alle appene og all informasjon i denne økten slettes."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Fjern"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Velkommen tilbake, gjest!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"I ett minutt"</item>
-    <item quantity="other" msgid="6924190729213550991">"I %d minutter"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"I én time"</item>
-    <item quantity="other" msgid="5408537517529822157">"I %d timer"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vil du fortsette økten?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Start på nytt"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, fortsett"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Vil du legge til en ny bruker?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Når du legger til en ny bruker, må vedkommende konfigurere sitt eget område.\n\nAlle brukere kan oppdatere apper for alle andre brukere."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Batterisparing er på"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduserer ytelsen og begrenser bakgrunnsdataene"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Slå av batterisparing"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Start nå"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ingen varsler"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Enheten kan være overvåket"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilen kan overvåkes"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Nettverket kan være overvåket"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Enhetsovervåking"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilovervåking"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Nettverksovervåking"</string>
-    <string name="open_app" msgid="4011771120339160755">"Åpne appen"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Deaktiver VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Koble fra VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke enheten og nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder.\n\nTa kontakt med administratoren for mer informasjon."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Du ga «<xliff:g id="APPLICATION">%1$s</xliff:g>» tillatelse til å konfigurere en VPN-tilkobling.\n\nDenne appen kan overvåke nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Enheten er koblet til et VPN-nettverk («<xliff:g id="APPLICATION">%1$s</xliff:g>»).\n\nVPN-tjenesteleverandøren din kan overvåke nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke nettverksaktiviteten din, inkludert e-poster, apper og sikre nettsteder. Ta kontakt med administratoren din for mer om dette.\n\nI tillegg ga du «<xliff:g id="APPLICATION">%2$s</xliff:g>» tillatelse til å konfigurere en VPN-tilkobling. Denne appen kan også overvåke nettverksaktiviteten din."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke nettverksaktiviteten din, inkludert e-poster, apper og sikre nettsteder. Ta kontakt med administratoren din for mer om dette.\n\nI tillegg er enheten koblet til et VPN-nettverk («<xliff:g id="APPLICATION">%2$s</xliff:g>»). VPN-tjenesteleverandøren kan også overvåke nettverksaktiviteten din."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Denne profilen administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke enheten og nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder.\n\nHvis du vil ha mer informasjon, kan du kontakte administratoren."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilen din administreres av:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoren din kan overvåke enheten og nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder.\n\nHvis du vil ha mer informasjon, kan du kontakte administratoren."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Denne profilen administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke enheten og nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder. Hvis du vil ha mer informasjon, kan du kontakte administratoren.\n\n Du har også gitt «<xliff:g id="APPLICATION">%2$s</xliff:g>» tillatelse til å konfigurere en VPN-tilkobling. Denne appen kan også overvåke nettverksaktiviteten."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Denne profilen administreres av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoren din kan overvåke nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder. Hvis du vil ha mer informasjon, kan du kontakte administratoren.\n\nDu er også koblet til et VPN («<xliff:g id="APPLICATION">%2$s</xliff:g>»). VPN-leverandøren din kan også overvåke nettverksaktiviteten."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilen din administreres av:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoren din kan overvåke nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder. Hvis du vil ha mer informasjon, kan du kontakte administratoren.\n\nDu har også gitt «<xliff:g id="APPLICATION">%3$s</xliff:g>» tillatelse til å konfigurere en VPN-tilkobling. Denne appen kan også overvåke nettverksaktiviteten."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Denne enheten administreres av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n Profilen din administreres av: \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoren din kan overvåke enheten og nettverksaktiviteten din, inkludert e-post, apper og sikre nettsteder. Hvis du vil ha mer informasjon, kan du kontakte administratoren.\n\nDu er også koblet til et VPN («<xliff:g id="APPLICATION">%3$s</xliff:g>»). VPN-leverandøren din kan også overvåke nettverksaktiviteten."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Enheten forblir låst til du låser den opp manuelt"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Motta varsler raskere"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Se dem før du låser opp"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nei takk"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Konfigurer"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> har kuttet lyden"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ne-rNP/strings.xml b/packages/SystemUI/res/values-ne-rNP/strings.xml
index 5f2c7ba..dd3eb27 100644
--- a/packages/SystemUI/res/values-ne-rNP/strings.xml
+++ b/packages/SystemUI/res/values-ne-rNP/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"हटाउनुहोस्"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"सूचीबाट हटाउनुहोस्"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"अनुप्रयोगको जानकारी"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"तपाईँको हालको स्क्रिन यहाँ प्रकट हुन्छ"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"नयाँ अनुप्रयोगहरू खारेज गर्नुहोस्"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"१ भरखरै अनुप्रयोग"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"पछाडि"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"गृह"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"मेनु"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"हालको स्क्रीन"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"खोज्नुहोस्"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"क्यामेरा"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"फोन"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"खोल्नुहोस्"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"खोल्नुहोस्"</string>
+    <string name="phone_label" msgid="2320074140205331708">"फोन खोल्नुहोस्"</string>
+    <string name="camera_label" msgid="7261107956054836961">"क्यामेरा खोल्नुहोस्"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"इनपुट विधि बटन स्विच गर्नुहोस्।"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"मिलाउने जुम बटन।"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"स्क्रिनलाई सानोबाट ठूलो पार्नुहोस्।"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"वाइफाइ दुई पट्टि।"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"वाइफाइ तिन बारहरू।"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"वाइफाइ सङ्केत भरिएको।"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> मा जडित।"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> मा जडित।"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"वाइम्यास छैन।"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX एउटा पट्टि।"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"वाइम्याक्स दुईवटा बारहरू।"</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"टेलि टाइपराइटर सक्षम गरियो।"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"बज्ने कम्पन हुन्छ।"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"घन्टी मौन।"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> खारेज गर्नुहोस्।"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> खारेज गरिएको छ।"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>सुरु गर्दै।"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"सूचना खारेज।"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"सूचना कक्ष।"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"द्रुत सेटिङहरू"</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"स्क्रीन बन्द गर्नुहोस्।"</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"सेटिङहरू"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"हालको स्क्रीन।"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"प्रयोगकर्ता <xliff:g id="USER">%s</xliff:g>।"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>। <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>।"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"वाइफाइ बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"वाइफाइ खुला गरियो।"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"मोवाइल <xliff:g id="SIGNAL">%1$s</xliff:g>। <xliff:g id="TYPE">%2$s</xliff:g>। <xliff:g id="NETWORK">%3$s</xliff:g>।"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"ब्याट्रि <xliff:g id="STATE">%s</xliff:g>।"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"हवाजहाज मोड <xliff:g id="STATE">%s</xliff:g>।"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"ब्लुटुथ <xliff:g id="STATE">%s</xliff:g>।"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"स्थान <xliff:g id="STATE">%s</xliff:g>।"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"हवाइजहाज मोड बन्द।"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"हवाइजहाज मोड खुला।"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"हवाइजहाज मोड बन्द छ।"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"हवाइजहाज मोड खोलियो।"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"ब्लुटुथ बन्द छ।"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"ब्लुटुथ खुला छ।"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"ब्लुटुथ जोडीदै।"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"ब्लुटुथ जडान भयो।"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ब्लुटुथ बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"ब्लुटुथ चालू गरियो।"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"स्थान रिपोर्टिङ बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"स्थान रिपोर्टिङ खुला गरियो।"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"स्थान रिपोर्टिङ बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"स्थान रिपोर्टिङ खुला गरियो।"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g>को लागि सङ्केत घन्टी सेट गरिएको"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"प्यानल बन्द गर्नुहोस्"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"थप समय"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"कम समय"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"प्यानल बन्द गर्नुहोस्।"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"थप समय।"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"कम समय।"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"टर्च बन्द छ।"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"टर्च खुला छ।"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"टर्च बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"टर्च खुला गरियो।"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"रङ उल्टाउने बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"रङ उल्टाउने खुला गरियो।"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"मोबाइल हटस्पट बन्द गरियो।"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"मोबाइल हटस्पट खुला गरियो।"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"स्क्रिन कास्टिङ रोकियो।"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"प्रदर्शन चमक"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G डेटा बन्द छ"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G डेटा बन्द छ"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"सेलुलर डेटा बन्द छ"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS द्वारा स्थान सेट गरिएको"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"स्थान अनुरोधहरू सक्रिय"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"सबै सूचनाहरू हटाउनुहोस्।"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"सेटिङ्हरू"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"अधिसूचना सेटिङ्हरू"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> सेटिङ्हरू"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"स्क्रिन स्वतः घुम्ने छ।"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"स्क्रिनलाई ल्यान्डस्केप अवस्थामा बन्द गरिएको छ।"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"स्क्रिन पोर्टेट अभिमूखमा लक गरिएको छ।"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"स्क्रिन अहिले स्वतः घुम्नेछ।"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"स्क्रिन अहिले परिदृश्य रूपरेखामा बन्द छ।"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"स्क्रिन अहिले पोट्रेट रूपरेखामा बन्द छ।"</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"दिवासपना"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"सेलुलर डेटा"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"डेटा प्रयोग"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"बाँकी डेटा"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"सीमाभन्दा बढी"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"सीमा पुग्यो - डेटा उपयोग रोकिएको छ"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> प्रयोग गरियो"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> सीमा"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> चेतावनी दिँदै"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"तपाईँको हालको स्क्रिन यहाँ प्रकट हुन्छ"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"अनुप्रयोग जानकारी"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"अनुप्रयोग बन्द गर्न"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"खोजी गर्नुहोस्"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"खोज्नुहोस्"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>को लागि माथि धिसार्नुहोस्"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"स्लाइड <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>को लागि बायाँ।"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"बिना रोकटोक, सचेतक सहित"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"कुनै रुकावट छैन। चेतावनी समेत छैन।"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"कुनै रुकावटहरू छैन"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"प्राथमिकता रुकावटहरूमा मात्र"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"तपाईंको अर्को सचेतक <xliff:g id="ALARM_TIME">%s</xliff:g> मा छ"</string>
@@ -266,44 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> मा तपाईंले आफ्नो सचेतक सुन्नुहुने छैन"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"तल कम जरुरी सूचनाहरू"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"खोल्न फेरि छुनुहोस्"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"अनलक गर्न स्वाप गर्नुहोस्"</string>
     <string name="phone_hint" msgid="3101468054914424646">"फोनका लागि दाँया स्वाइप"</string>
     <string name="camera_hint" msgid="5241441720959174226">"क्यामेराका लागि बाँया स्वाइप"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"अनिश्चित"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"कुनै पनि होइन"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"प्राथमिकता"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"सबै"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"चार्ज हुँदै (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> पूर्ण भएसम्म)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"प्रयोगकर्ता फेर्नुहोस्"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"प्रयोगकर्ता, हालको प्रयोगकर्ता <xliff:g id="CURRENT_USER_NAME">%s</xliff:g> मा स्विच गर्नुहोस्"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"प्रोफाइल देखाउनुहोस्"</string>
     <string name="user_add_user" msgid="5110251524486079492">"प्रयोगकर्ता थप्नुहोस्"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"नयाँ प्रयोगकर्ता"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"अतिथि"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"अतिथि सत्र बाहिरिंदै छ?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"अतिथि सत्र अन्त्यले स्थानीय डेटा हटाउने छ।"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"अतिथि थप्नुहोस्"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"अतिथि हटाउनुहोस्"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"अतिथि हटाउने हो?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"यस सत्रमा सबै अनुप्रयोगहरू र डेटा मेटाइनेछ।"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"हटाउनुहोस्"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"पुनः स्वागत, अतिथि!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"एक मिनेटको लागि"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d मिनेटको लागि"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"एक घण्टाको लागि"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d घण्टाको लागि"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"तपाईँ आफ्नो सत्र जारी गर्न चाहनुहुन्छ?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"सुरु गर्नुहोस्"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"हो, जारी राख्नुहोस्"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"नयाँ प्रयोगकर्ता थप्नुहुन्छ?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"जब तपाईँले नयाँ प्रयोगकर्ता थप्नुहुन्छ, त्यस प्रयोगकर्ताले आफ्नो स्थान स्थापना गर्न पर्ने छ।\n\nकुनै पनि प्रयोगकर्ताले सबै अन्य प्रयोगकर्ताहरूका लागि अनुप्रयोगहरू अद्यावधिक गर्न सक्छन्।"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"ब्याट्रि सेभर चालु छ"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"प्रदर्शन र पृष्ठभूमि डेटा घटाउँनुहोस्"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ब्याट्री बचत बन्द गर्नुहोस्"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"अहिले सुरु गर्नुहोस्"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"कुनै सूचनाहरू छैनन्"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"उपकरण अनुगमन हुन सक्छ"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"प्रोफाइल अनुगमन हुन सक्छ"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"सञ्जाल अनुगमित हुन सक्छ"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"उपकरण अनुगमन"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"प्रोफाइल अनुगमन गर्दै"</string>
     <string name="monitoring_title" msgid="169206259253048106">"सञ्जाल अनुगमन"</string>
-    <string name="open_app" msgid="4011771120339160755">"अनुप्रयोग खोल्नुहोस्"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN असक्षम गर्नुहोस्"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"विच्छेद VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"यो उपकरण निम्न द्वारा व्यवस्थित छ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nतपाईंको प्रशासनले इमेल, अनुप्रयोग र सुरक्षित वेबसाइटहरू सहित आफ्नो उपकरण र सञ्जाल गतिविधि निगरानी गर्न सक्छन्।\n\nथप जानकारीको लागि, आफ्नो प्रशासक सँग सम्पर्क गर्नुहोस्।"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"तपाईंले एउटा VPN जडान स्थापित गर्न \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" अनुमति दिनुभयो।\n\nयो अनुप्रयोगले तपाईंको इमेल, अनुप्रयोगहरू, र सुरक्षित वेबसाइट सहित आफ्नो उपकरण र सञ्जाल गतिविधि निगरानी गर्न सक्छ।"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"तपाईं VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") मा जडित हुनुहुन्छ।\n\nतपाईंको VPN सेवा प्रदायकले इमेल, अनुप्रयोगहरू, र सुरक्षित वेबसाइट सहित आफ्नो उपकरण र सञ्जाल गतिविधि निगरानी गर्न सक्छन्।"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"यो उपकरण व्यवस्थित गरिएको छ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nतपाईंको प्रशासनले इमेल, अनुप्रयोग र सुरक्षित वेबसाइटहरू सहित आफ्नो सञ्जाल गतिविधि निगरानी गर्न सक्षम छ। थप जानकारीको लागि, आफ्नो प्रशासन सँग सम्पर्क गर्नुहोस्।\n\nसाथै, तपाईंले एउटा VPN जडान स्थापित गर्न \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" अनुमति दिनुभयो। यो अनुप्रयोगले सञ्जाल गतिविधि पनि निगरानी गर्न सक्छन्।"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"यो उपकरण व्यवस्थित गरिएको छ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nतपाईंको प्रशासनले इमेल, अनुप्रयोग र सुरक्षित वेबसाइटहरू सहित आफ्नो सञ्जाल गतिविधि निगरानी गर्न सक्षम छ। थप जानकारीको लागि, आफ्नो प्रशासन सँग सम्पर्क गर्नुहोस्।\n\nतपाईं VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") मा जडित हुनुहुन्छ। तपाईंको VPN सेवा प्रदायकले आफ्नो सञ्जाल गतिविधि पनि निगरानी गर्न सक्छन्।"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"यो प्रोफाइल व्यवस्थित गरिएकोछ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n तपाईँको प्रशासकले इमेल, अनुप्रयोग र सुरक्षित वेबसाइट सहित, तपाईँको उपकरण र सञ्जाल गतिविधि निगरानी गर्न सक्छ।\n\nथप जानकारीको लागि, आफ्नो प्रशासक संग सम्पर्क गर्नुहोस्।"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"यो उपकरण व्यवस्थित गरिएको छ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n तपाईँको प्रोफाइल व्यवस्थित गरिएको छ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n तपाईँको प्रशासकले इमेल, अनुप्रयोग र सुरक्षित वेबसाइट सहित, तपाईँको उपकरण र सञ्जाल गतिविधि निगरानी गर्न सक्छ।\n\n थप जानकारीको लागि, आफ्नो प्रशासक संग सम्पर्क गर्नुहोस्।"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"यो प्रोफाइल व्यवस्थित गरिएको छ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nतपाईँको प्रशासकले इमेल, अनुप्रयोग र सुरक्षित वेबसाइट सहित तपाईँको सञ्जाल गतिविधि निगरानी गर्न सक्षम छ। थप जानकारीको लागि, आफ्नो प्रशासक संग सम्पर्क गर्नुहोस्।\n\nसाथै, तपाईँले एउटा VPN जडान स्थापित गर्न \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" अनुमति दिनुभयो। यो अनुप्रयोगले सञ्जाल गतिविधि पनि निगरानी गर्न सक्छ।"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"यो प्रोफाइल व्यवस्थित गरिएकोछ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n तपाईँको प्रशासकले इमेल, अनुप्रयोग र सुरक्षित वेबसाइट सहित, तपाईँको सञ्जाल गतिविधि निगरानी गर्न सक्षम छ। थप जानकारीको लागि, आफ्नो प्रशासक संग सम्पर्क गर्नुहोस्।\n\nसाथै, तपाईँ एउटा VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") मा जडित हुनुहुन्छ। तपाईँको VPN सेवा प्रदायकले सञ्जाल गतिविधि पनि निगरानी गर्न सक्छ।"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"यस उपकरण र तपाईँको प्रोफाइल \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n र \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n ले व्यवस्थित गरिएको छ। तपाईँको प्रशासकले सञ्जाल गतिविधि निगरानी गर्न सक्षम छन् जस्तै इमेल, अनुप्रयोग र सुरक्षित वेबसाइट। थप जान्न प्रशासकलाई सम्पर्क गर्नुहोला।\n\nसाथै, तपाईँले VPN जडान स्थापित गर्न \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" अनुमति दिनुभयो। यो अनुप्रयोगले संजालको निगरानी पनि गर्न सक्छ।"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"यो उपकरणको व्यवस्थित \n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n ले गरेको छ। तपाईँको प्रोफाइल \n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n ले व्यवस्थित गरिएको छ। तपाईँको प्रशासकले सञ्जाल गतिविधि निगरानी गर्न सक्षम छन् जसमा इमेल, अनुप्रयोग र सुरक्षित वेबसाइट छ। थप जान्न प्रशासकलाई सम्पर्क गर्नुहोला।\n\nसाथै, तपाईँ VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") मा जडित हुनुहुन्छ। जुन सेवा प्रदायकले निगरानी गर्न सक्ने छन्।"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"तपाईँले नखोले सम्म उपकरण बन्द रहनेछ"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"छिटो सूचनाहरू प्राप्त गर्नुहोस्"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"तपाईँले अनलक गर्नअघि तिनीहरूलाई हेर्नुहोस्"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"धन्यवाद पर्दैन"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"सेटअप गर्नुहोस्"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> द्वारा मौन गरिएको"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-nl/config.xml b/packages/SystemUI/res/values-nl/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-nl/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-nl/strings.xml b/packages/SystemUI/res/values-nl/strings.xml
index 009d977..06bbfe1 100644
--- a/packages/SystemUI/res/values-nl/strings.xml
+++ b/packages/SystemUI/res/values-nl/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Wissen"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Verwijderen uit lijst"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"App-info"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Uw recente schermen worden hier weergegeven"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Recente apps negeren"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 recente app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Terug"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Startpagina"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Recente schermen"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Zoeken"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefoon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Ontgrendelen"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ontgrendelen"</string>
+    <string name="phone_label" msgid="2320074140205331708">"telefoon openen"</string>
+    <string name="camera_label" msgid="7261107956054836961">"camera openen"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Knop voor wijzigen invoermethode."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Knop voor compatibiliteitszoom."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Kleiner scherm uitzoomen naar groter scherm."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi: twee streepjes."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi: drie streepjes."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi-signaal is op volledige sterkte."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Verbonden met <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Verbonden met <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Geen WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: één streepje."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: twee streepjes."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter ingeschakeld."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Belsoftware trilt."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Belsoftware stil."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> sluiten."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> verwijderd."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> starten."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Melding verwijderd."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Meldingenpaneel."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Snelle instellingen."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Vergrendelingsscherm."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Instellingen"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Recente schermen."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Gebruiker: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi ingeschakeld."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobiel <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Accu: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Vliegmodus: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Locatie <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Vliegmodus uit."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Vliegmodus aan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Vliegmodus uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Vliegmodus ingeschakeld."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth uit."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth aan."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth-verbinding wordt gemaakt."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth-verbinding gemaakt."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth ingeschakeld."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Locatiemelding uit."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Locatiemelding aan."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Locatiemelding uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Locatiemelding ingeschakeld."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm is ingesteld op <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Deelvenster sluiten"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Meer tijd"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Minder tijd"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Paneel sluiten."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Meer tijd."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Minder tijd."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Zaklamp uit."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Zaklamp aan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Zaklamp uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Zaklamp ingeschakeld."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Kleurinversie uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Kleurinversie ingeschakeld."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobiele hotspot uitgeschakeld."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobiele hotspot ingeschakeld."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Casten van scherm gestopt."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Helderheid van het scherm"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G/3G-data zijn uitgeschakeld"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-data zijn uitgeschakeld"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobiele data zijn uitgeschakeld"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Locatie bepaald met GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Locatieverzoeken actief"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Alle meldingen wissen."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Instellingen"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Instellingen voor meldingen"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>-instellingen"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Scherm wordt automatisch geroteerd."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Het scherm is nu vergrendeld in liggende stand."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Het scherm is nu vergrendeld in staande stand."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Het scherm wordt nu automatisch gedraaid."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Het scherm is nu vergrendeld in liggende stand."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Het scherm is nu vergrendeld in staande stand."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessertshowcase"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Dagdroom"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobiele gegevens"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Gegevensgebruik"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Resterende gegevens"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limiet overschreden"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limiet bereikt – gegevensgebruik onderbroken"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> gebruikt"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limiet van <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Waarschuwing voor <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Uw recente schermen worden hier weergegeven"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"App-informatie"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"app-slot"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"zoeken"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Zoeken"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Veeg omhoog voor <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Veeg naar links voor <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Geen onderbrekingen, waaronder alarmen"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Geen onderbrekingen. Zelfs geen alarm."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Geen onderbrekingen"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Alleen prioriteitsonderbrekingen"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Uw volgende alarm is om <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"U hoort uw alarm niet om <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Minder urgente meldingen onderaan"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Raak opnieuw aan om te openen"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Veeg omhoog om te ontgrendelen"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Veeg naar rechts voor telefoon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Veeg naar links voor camera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Voor onbepaalde tijd"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Geen"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioriteit"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alle"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Opladen (vol over <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Gebruiker wijzigen"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Schakelen tussen gebruikers, huidige gebruiker <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Profiel weergeven"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Gebruiker toevoegen"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nieuwe gebruiker"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gast"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Gast toevoegen"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Gast verwijderen"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Gastsessie sluiten?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Als u de gastsessie sluit, worden lokale gegevens verwijderd."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Gast verwijderen?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alle apps en gegevens in deze sessie worden verwijderd."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Verwijderen"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Welkom terug, gast!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Eén minuut"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d minuten"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Eén uur"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d uur"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Wilt u doorgaan met uw sessie?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Opnieuw starten"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, doorgaan"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Nieuwe gebruiker toevoegen?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Wanneer u een nieuwe gebruiker toevoegt, moet die persoon zijn eigen profiel instellen.\n\n1Elke gebruiker kan apps bijwerken voor alle andere gebruikers."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Accubesparing is ingeschakeld"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Vermindert de prestaties en achtergrondgegevens"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Accubesparing uitschakelen"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Nu starten"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Geen meldingen"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Apparaat wordt mogelijk gecontroleerd"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profiel kan worden gecontroleerd"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Netwerk kan worden gecontroleerd"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Apparaatcontrole"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profielcontrole"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Netwerkcontrole"</string>
-    <string name="open_app" msgid="4011771120339160755">"App openen"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN uitschakelen"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Verbinding met VPN verbreken"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw apparaat- en netwerkactiviteit bijhouden, waaronder e-mails, apps en beveiligde websites.\n\nNeem voor meer informatie contact op met uw beheerder."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"U heeft \'<xliff:g id="APPLICATION">%1$s</xliff:g>\' toestemming gegeven een VPN-verbinding in te stellen.\n\nDeze app kan uw apparaat- en netwerkactiviteit bijhouden, waaronder e-mails, apps en beveiligde websites."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"U heeft verbinding met een VPN (\'<xliff:g id="APPLICATION">%1$s</xliff:g>\').\n\nUw VPN-provider kan uw apparaat- en netwerkactiviteit bijhouden, waaronder e-mails, apps en beveiligde websites."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw netwerkactiviteit beheren, waaronder e-mails, apps en beveiligde websites. Neem voor meer informatie contact op met uw beheerder.\n\nDaarnaast heeft u \'<xliff:g id="APPLICATION">%2$s</xliff:g>\' toestemming gegeven een VPN-verbinding in te stellen. Deze app kan uw netwerkactiviteit ook controleren."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw netwerkactiviteit beheren, waaronder e-mails, apps en beveiligde websites. Neem voor meer informatie contact op met uw beheerder.\n\nDaarnaast bent u verbonden met een VPN (\'<xliff:g id="APPLICATION">%2$s</xliff:g>\'). Uw VPN-serviceprovider kan uw netwerkactiviteit ook controleren."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Dit profiel wordt beheer door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites.\n\nNeem contact op met uw beheerder voor meer informatie."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nUw profiel wordt beheerd door:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites.\n\nNeem contact op met uw beheerder voor meer informatie."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Dit profiel wordt beheerd door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites. Neem contact op met uw beheerder voor meer informatie.\n\nU heeft \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ook toestemming gegeven een VPN-verbinding in te stellen. Deze app kan ook netwerkactiviteit controleren."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Dit profiel wordt beheerd door:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites. Neem contact op met uw beheerder voor meer informatie.\n\nDaarnaast bent u verbonden met een VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Uw VPN-serviceprovider kan ook netwerkactiviteit controleren."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nUw profiel wordt beheerd door:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites. Neem contact op met uw beheerder voor meer informatie.\n\nU heeft \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ook toestemming gegeven een VPN-verbinding in te stellen. Deze app kan ook netwerkactiviteit controleren."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Dit apparaat wordt beheerd door:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nUw profiel wordt beheerd door:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUw beheerder kan uw apparaat en netwerkactiviteit controleren, inclusief e-mails, apps en veilige websites. Neem contact op met uw beheerder voor meer informatie.\n\nDaarnaast bent u verbonden met een VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Uw VPN-serviceprovider kan ook netwerkactiviteit controleren."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Het apparaat blijft vergrendeld totdat u het handmatig ontgrendelt"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Sneller meldingen ontvangen"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Weergeven voordat u ontgrendelt"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nee, bedankt"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configureren"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Gedempt door <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-pl/config.xml b/packages/SystemUI/res/values-pl/config.xml
new file mode 100644
index 0000000..f87a0a3
--- /dev/null
+++ b/packages/SystemUI/res/values-pl/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 s, 10 s, 30 s, 60 s, 120 s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-pl/strings.xml b/packages/SystemUI/res/values-pl/strings.xml
index 6f0e1ec..ab2983f 100644
--- a/packages/SystemUI/res/values-pl/strings.xml
+++ b/packages/SystemUI/res/values-pl/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Wyczyść"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Usuń z listy"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informacje o aplikacji"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Tutaj pojawią się ostatnie ekrany"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Ukryj ostatnie aplikacje"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ostatnia aplikacja"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Wróć"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Ekran główny"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Ostatnie ekrany"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Szukaj"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Aparat"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Odblokuj"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"odblokuj"</string>
+    <string name="phone_label" msgid="2320074140205331708">"otwórz telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"otwórz aparat"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Przycisk przełączania metody wprowadzania."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Przycisk powiększenia na potrzeby zgodności."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Powiększa mniejszy ekran do większego."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: dwa paski."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: trzy paski."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi: pełna moc sygnału."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Połączono z <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Połączono z <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX: brak"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: jeden pasek"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: dwa paski"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Dalekopis (TTY) włączony."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Dzwonek z wibracjami."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Dzwonek wyciszony."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Usuń stąd <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g>: zamknięto."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Uruchamiam <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Zamknięto powiadomienie."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Obszar powiadomień."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Szybkie ustawienia."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Ekran blokady."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Ustawienia"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Ostatnie ekrany."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Użytkownik: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi wyłączone."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi włączone."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Sieć komórkowa: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateria: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Tryb samolotowy: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokalizacja <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Tryb samolotowy jest wyłączony."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Tryb samolotowy jest włączony."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Tryb samolotowy został wyłączony."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Tryb samolotowy został włączony."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth wyłączony."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth włączony."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Nawiązywanie połączenia Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth połączony."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth jest wyłączony."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth jest włączony."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Raportowanie lokalizacji wyłączone."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Raportowanie lokalizacji włączone."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Raportowanie lokalizacji zostało wyłączone."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Raportowanie lokalizacji zostało włączone."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm ustawiony na <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Zamknij panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Więcej czasu"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mniej czasu"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Zamknij panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Więcej czasu."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mniej czasu."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Latarka wyłączona."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Latarka włączona."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Latarka została wyłączona."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Latarka została włączona."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Odwrócenie kolorów zostało wyłączone."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Odwrócenie kolorów zostało włączone."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilny hotspot został wyłączony."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilny hotspot został włączony."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Zatrzymano przesyłanie ekranu."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Jasność wyświetlacza"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Połączenie danych 2G-3G wyłączone"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Połączenie danych 4G wyłączone"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Komórkowe połączenie danych jest wyłączone"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokalizacja z GPSa"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Prośby o lokalizację są aktywne"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Usuń wszystkie powiadomienia."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Ustawienia"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Ustawienia powiadomień"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Ustawienia aplikacji <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekran zostanie obrócony automatycznie."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ekran jest zablokowany w orientacji poziomej."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ekran jest zablokowany w orientacji pionowej."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ekran będzie teraz obracać się automatycznie."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ekran jest teraz zablokowany w orientacji poziomej."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ekran jest teraz zablokowany w orientacji pionowej."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Półka ze słodkościami"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Wygaszacz ekranu"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Transmisja danych komórkowych"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Użycie danych"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Pozostały limit"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Przekroczono limit"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Osiągnięto limit – korzystanie z danych wstrzymane"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Wykorzystano <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limit <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Ostrzeżenie: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Tutaj pojawią się ostatnie ekrany"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informacje o aplikacji"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"zablokuj na aplikacji"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"szukaj"</string>
@@ -257,51 +287,39 @@
     <string name="description_target_search" msgid="3091587249776033139">"Szukaj"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Przesuń w górę: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Przesuń w lewo: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Żadnego przeszkadzania, w tym alarmów"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Żadnych powiadomień. Nawet alarmów."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Bez przerw"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Tylko priorytetowe przerwy"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Tylko przerwy priorytetowe"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Następny alarm o <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"Następny alarm: <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Nie usłyszysz alarmu o <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Poniżej widać mniej pilne powiadomienia"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Kliknij ponownie, by otworzyć"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Przesuń w górę, by odblokować"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Przesuń w prawo, by przełączyć się na telefon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Przesuń w lewo, by przełączyć się na aparat"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Na czas nieokreślony"</string>
-    <string name="interruption_level_none" msgid="3831278883136066646">"Brak"</string>
+    <string name="interruption_level_none" msgid="3831278883136066646">"Żadne"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Priorytet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Wszystkie"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Ładuje się (pełne naładowanie za <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Przełącz użytkownika"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Przełącz użytkownika. Bieżący użytkownik: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Pokaż profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Dodaj użytkownika"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nowy użytkownik"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gość"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Dodaj gościa"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Usuń gościa"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Zakończyć sesję gościa?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Zakończenie sesji gościa spowoduje usunięcie danych lokalnych."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Usunąć gościa?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Wszystkie aplikacje i dane w tej sesji zostaną usunięte."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Usuń"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Witaj ponownie, gościu!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Przez minutę"</item>
-    <item quantity="other" msgid="6924190729213550991">"Przez %d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Przez godzinę"</item>
-    <item quantity="other" msgid="5408537517529822157">"Przez %d godz."</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Chcesz kontynuować sesję?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Rozpocznij nową"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Tak, kontynuuj"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Dodać nowego użytkownika?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Gdy dodasz nowego użytkownika, musi on skonfigurować swój profil.\n\nKażdy użytkownik może aktualizować aplikacje wszystkich innych użytkowników."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Oszczędzanie baterii jest włączone"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Zmniejsza wydajność i ogranicza dane w tle"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Wyłącz oszczędzanie baterii"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Rozpocznij teraz"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Brak powiadomień"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Urządzenie może być monitorowane"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil może być monitorowany"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Sieć może być monitorowana"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Monitorowanie urządzeń"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitorowanie profilu"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Monitorowanie sieci"</string>
-    <string name="open_app" msgid="4011771120339160755">"Otwórz aplikację"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Wyłącz VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Rozłącz z VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Urządzeniem zarządza:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator może monitorować Twoją aktywność na urządzeniu i w sieci, w tym e-maile, aplikacje i bezpieczne strony internetowe.\n\nSkontaktuj się z nim, by dowiedzieć się więcej."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Aplikacji „<xliff:g id="APPLICATION">%1$s</xliff:g>” nadałeś uprawnienie do konfigurowania połączenia VPN.\n\nMoże ona monitorować Twoją aktywność na urządzeniu i w sieci, w tym e-maile, aplikacje i bezpieczne strony internetowe."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Łączysz się z siecią VPN („<xliff:g id="APPLICATION">%1$s</xliff:g>”).\n\nDostawca usługi VPN może monitorować Twoją aktywność na urządzeniu i w sieci, w tym e-maile, aplikacje i bezpieczne strony internetowe."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Urządzeniem zarządza:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator ma możliwość monitorowania Twojej aktywności w sieci, w tym e-maili, aplikacji i bezpiecznych witryn. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nDałeś też aplikacji „<xliff:g id="APPLICATION">%2$s</xliff:g>” uprawnienia do skonfigurowania połączenia VPN. Ona również może monitorować aktywność sieciową."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Urządzeniem zarządza:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministrator ma możliwość monitorowania Twojej aktywności w sieci, w tym e-maili, aplikacji i bezpiecznych witryn. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nŁączysz się też z siecią VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>”). Dostawca usługi VPN również może monitorować aktywność sieciową."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Ten profil jest zarządzany przez:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTwój administrator może monitorować Twoje urządzenie i aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony internetowe.\n\nAby dowiedzieć się więcej, skontaktuj się z administratorem."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"To urządzenie jest zarządzane przez:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nTwój profil jest zarządzany przez:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nTwój administrator może monitorować Twoje urządzenie i aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony internetowe.\n\nAby dowiedzieć się więcej, skontaktuj się z administratorem."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Ten profil jest zarządzany przez:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTwój administrator może monitorować aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nPozwalasz też aplikacji „<xliff:g id="APPLICATION">%2$s</xliff:g>” na nawiązanie połączenia VPN. Ona również może monitorować aktywność w sieci."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profil jest zarządzany przez:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nTwój administrator może monitorować aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nUżywasz też połączenia VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Twój operator VPN również może monitorować aktywność w sieci."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Urządzenie jest zarządzane przez:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil jest zarządzany przez:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nTwój administrator może monitorować aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nPozwalasz też aplikacji „<xliff:g id="APPLICATION">%3$s</xliff:g>” na nawiązanie połączenia VPN. Ona również może monitorować aktywność w sieci."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Urządzenie jest zarządzane przez:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil jest zarządzany przez:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nTwój administrator może monitorować aktywność w sieci, w tym e-maile, aplikacje i bezpieczne strony. Skontaktuj się z nim, by dowiedzieć się więcej.\n\nUżywasz też połączenia VPN („<xliff:g id="APPLICATION">%3$s</xliff:g>”). Twój operator VPN również może monitorować aktywność w sieci."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Urządzenie pozostanie zablokowane, aż odblokujesz je ręcznie"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Szybszy dostęp do powiadomień"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Zobacz powiadomienia, jeszcze zanim odblokujesz ekran"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nie, dziękuję"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Skonfiguruj"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Ściszone przez: <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-pt-rPT/config.xml b/packages/SystemUI/res/values-pt-rPT/config.xml
new file mode 100644
index 0000000..f87a0a3
--- /dev/null
+++ b/packages/SystemUI/res/values-pt-rPT/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 s, 10 s, 30 s, 60 s, 120 s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-pt-rPT/strings.xml b/packages/SystemUI/res/values-pt-rPT/strings.xml
index b7222eb..28dcc55 100644
--- a/packages/SystemUI/res/values-pt-rPT/strings.xml
+++ b/packages/SystemUI/res/values-pt-rPT/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Limpar"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Remover da lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informações da aplicação"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Os ecrãs recentes aparecem aqui"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Ignorar aplicações recentes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicação recente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Anterior"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Página inicial"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Ecrãs recentes"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Pesquisar"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Câmara"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telemóvel"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloquear"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloquear"</string>
+    <string name="phone_label" msgid="2320074140205331708">"abrir telemóvel"</string>
+    <string name="camera_label" msgid="7261107956054836961">"abrir câmara"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Alternar botão de método de introdução."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botão zoom de compatibilidade."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zoom menor para ecrã maior."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Duas barras de Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Três barras de Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Sinal Wi-Fi completo."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Ligado a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Ligado a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Sem WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Uma barra de WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Duas barras de WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Teletipo ativado."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Campainha em vibração."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Campainha em silêncio."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Ignorar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ignorado."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"A iniciar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificação ignorada."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Painel de notificações."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Definições rápidas."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Ecrã de bloqueio."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Definições"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Ecrãs recentes."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Utilizador <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi desligado."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi ligado."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Dispositivo Móvel <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateria <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modo de Avião <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Localização <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modo de avião desligado."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modo de avião ligado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Modo de avião desligado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Modo de avião ligado."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth desligado."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth ligado."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"A ligar o Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth ligado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth desligado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth ligado."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Relatórios de localização desligados."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Relatórios de localização ligados."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Relatórios de localização desligados."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Relatórios de localização ligados."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarme definido para <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Fechar painel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mais tempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menos tempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Fechar o painel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mais tempo."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menos tempo."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lanterna desligada."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lanterna ligada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lanterna desligada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lanterna ligada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversão de cores desligada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversão de cores ligada."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Zona Wi-Fi móvel desligada."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Zona Wi-Fi móvel ligada."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Transmissão do ecrã interrompida."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brilho do visor"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Dados 2G-3G desligados"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Dados 4G desligados"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Dados de rede móvel desligados"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Localização definida por GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Pedidos de localização ativos"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Limpar todas as notificações."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Definições"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Definições de notificação"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Definições do <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"O ecrã será rodado automaticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"O ecrã está bloqueado na orientação horizontal."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"O ecrã está bloqueado na orientação vertical."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"O ecrã irá agora rodar automaticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"O ecrã está agora bloqueado na orientação de paisagem."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"O ecrã está agora bloqueado na orientação de retrato."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vitrina de sobremesas"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -209,7 +240,7 @@
     <string name="quick_settings_location_off_label" msgid="7464544086507331459">"Localização Desativada"</string>
     <string name="quick_settings_media_device_label" msgid="1302906836372603762">"Dispositivo multimédia"</string>
     <string name="quick_settings_rssi_label" msgid="7725671335550695589">"RSSI"</string>
-    <string name="quick_settings_rssi_emergency_only" msgid="2713774041672886750">"Apenas Chamadas de Emergência"</string>
+    <string name="quick_settings_rssi_emergency_only" msgid="2713774041672886750">"Apenas chamadas de emergência"</string>
     <string name="quick_settings_settings_label" msgid="5326556592578065401">"Definições"</string>
     <string name="quick_settings_time_label" msgid="4635969182239736408">"Hora"</string>
     <string name="quick_settings_user_label" msgid="5238995632130897840">"Eu"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Dados de rede móvel"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Utilização de dados"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Dados restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Acima do limite"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limite atingido – utilização de dados interrompida"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> utilizado(s)"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limite de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Aviso de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Os ecrãs recentes aparecem aqui"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informações da aplicação"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"bloquear numa aplicação"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"pesquisar"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Pesquisar"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Deslize para cima para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Deslize para a esquerda para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sem interrupções, incluindo alarmes"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Sem interrupções. Nem mesmo alarmes."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Sem interrupções"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Apenas interrupções com prioridade"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"O próximo alarme é à(s) <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Não vai ouvir o alarme à(s) <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificações menos urgentes abaixo"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Tocar novamente para abrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Deslizar rapidamente com o dedo para cima para desbloquear"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Deslize rapidamente para a direita para aceder ao telemóvel"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Deslize rapidamente para a esquerda para aceder à câmara"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nenhum"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioridade"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Tudo"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"A carregar (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> até à carga máxima)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Mudar utilizador"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Mudar de utilizador; o utilizador atual é <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostrar perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Adicionar utilizador"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Novo utilizador"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Convidado"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Adicionar convidado"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Remover convidado"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Pretende sair da sessão de convidado?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Ao terminar a sessão de convidado, os dados locais serão removidos."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Pretende remover o convidado?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Todas as aplicações e dados desta sessão serão eliminados."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Remover"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bem-vindo(a) de volta, caro(a) convidado(a)!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Durante um minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Durante %d minutos"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Durante uma hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Durante %d horas"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Pretende continuar a sessão?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Recomeçar"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sim, continuar"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Adicionar um novo utilizador?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Ao adicionar um novo utilizador, essa pessoa tem de configurar o respetivo espaço.\n\nQualquer utilizador pode atualizar aplicações para todos os outros utilizadores."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"A poupança de bateria está ligada"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduz o desempenho e os dados de segundo plano"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desativar a poupança de bateria"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Começar agora"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Sem notificações"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"O dispositivo pode ser monitorizado"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"O perfil pode ser monitorizado"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"A rede pode ser monitorizada"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Monitorização de dispositivos"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitorização de perfis"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Monitorização da rede"</string>
-    <string name="open_app" msgid="4011771120339160755">"Abrir aplicação"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Desativar a VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desligar VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Este dispositivo é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorizar a atividade do dispositivo e da rede, incluindo emails, aplicações e Websites seguros.\n\nPara mais informações, contacte o administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Concedeu autorização a \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" para configurar uma ligação VPN.\n\nEsta aplicação pode monitorizar a atividade do dispositivo e da rede, incluindo emails, aplicações e Websites seguros."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Está ligado a uma VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nO fornecedor de serviços VPN pode monitorizar a atividade do dispositivo e da rede, incluindo emails, aplicações e Websites seguros."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Este dispositivo é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\no admin. pode monitorizar a atividade da rede, incluindo emails, aplicações e Websites seguros. Para mais informações, contacte o administrador.\n\nAlém disso, deu permissão a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" para configurar uma ligação VPN. Esta aplicação pode também monitorizar a atividade da rede."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Este dispositivo é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\no administrador pode monitorizar a atividade da rede, incluindo emails, aplicações e Websites seguros. Para mais informações, contacte o administrador.\n\nAlém disso, está ligado a uma VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). O fornecedor de serviços VPN pode também monitorizar a atividade da rede."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Este perfil é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO seu administrador pode monitorizar o seu dispositivo e a atividade de rede, incluindo emails, aplicações e Websites seguros.\n\nPara obter mais informações, contacte o seu administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Este dispositivo é gerido por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO seu perfil é gerido por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO seu administrador pode monitorizar o seu dispositivo e a atividade de rede, incluindo emails, aplicações e Websites seguros.\n\nPara obter mais informações, contacte o seu administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Este perfil é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO seu admin. pode monitorizar a sua atividade de rede, incluindo emails, aplic. e Websites seguros. Para obter mais informações, contacte o seu admin.\n\nPara além disso, deu autorização a \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" para configurar uma ligação VPN. Esta aplic. também pode monitorizar a ativ. de rede."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Este perfil é gerido por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO seu admin. pode monitorizar a sua atividade de rede, incluindo emails, aplicações e Websites seguros. Para obter mais informações, contacte o seu admin.\n\nPara além disso, está ligado a uma VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). O seu fornecedor de serviço VPN também pode monitorizar a ativ. de rede."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Este disp. é gerido por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO seu perfil é gerido por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO seu admin. pode monitorizar a sua ativ. de rede, incluindo emails, aplicações e Websites seguros. Para obter mais informações, contacte o seu admin.\n\nPara além disso, deu autorização a \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" para configurar uma ligação VPN. Esta aplicação também pode monitorizar a ativ. de rede."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Este dispositivo é gerido por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nO seu perfil é gerido por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO seu admin. pode monitorizar a sua ativ. de rede, incluindo emails, aplic. e Websites seguros. Para obter mais informações, contacte o seu admin.\n\nPara além disso, está ligado a uma VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). O seu forn. de serviço VPN também pode monitorizar a ativ. de rede."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"O dispositivo permanecerá bloqueado até ser desbloqueado manualmente"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Receber notificações mais rapidamente"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ver antes de desbloquear"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Não, obrigado"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurar"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Som desativado por <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-pt/strings.xml b/packages/SystemUI/res/values-pt/strings.xml
index 51c0526..480c490 100644
--- a/packages/SystemUI/res/values-pt/strings.xml
+++ b/packages/SystemUI/res/values-pt/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Limpar"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Remover da lista"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informações do aplicativo"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Suas telas recentes aparecem aqui"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Dispensar aplicativos recentes"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicativo recente"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Voltar"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Página inicial"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Telas recentes"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Pesquisar"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Câmera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefone"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Desbloquear"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"desbloquear"</string>
+    <string name="phone_label" msgid="2320074140205331708">"abrir smartphone"</string>
+    <string name="camera_label" msgid="7261107956054836961">"abrir câmera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Alterar botão do método de entrada."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Botão de zoom da compatibilidade."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Aumentar a tela com zoom."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Duas barras de sinal Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Três barras de sinal Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Sinal Wi-Fi cheio."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Conectado a <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Conectado a <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Sem WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Uma barra do WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Duas barras do WiMAX."</string>
@@ -153,29 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTYpewriter ativado."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibração da campainha."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Campainha silenciosa."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Descartar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> descartado."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Iniciando <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificação dispensada."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Aba de notificações."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Configurações rápidas."</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Tela de bloqueio."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"Configurações"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Telas recentes."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Usuário <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"O Wi-Fi foi desativado."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"O Wi-Fi foi ativado."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Celular <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Bateria <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Modo avião <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Localização <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modo avião desativado."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modo avião ativado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"O modo avião foi desativado."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"O modo avião foi ativado."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth desativado."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth ativado."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Conectando Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth conectado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"O Bluetooth foi desativado."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"O Bluetooth foi ativado."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Relatório de Localização desativado."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Relatório de Localização ativado."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"O Relatório de Localização foi desativado."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"O Relatório de Localização foi ativado."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarme definido para <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Fechar painel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mais tempo"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Menos tempo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Fechar painel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mais tempo."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Menos tempo."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lanterna desativada."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lanterna ativada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"A lanterna foi desativada."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"A lanterna foi ativada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"A inversão de cores foi desativada."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"A inversão de cores foi ativada."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"O ponto de acesso móvel foi desativado."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"O ponto de acesso móvel foi ativado."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"A transmissão de tela foi interrompida."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Brilho da tela"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Os dados 2G-3G foram desativados"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Os dados 4G foram desativados"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Os dados da rede celular foram desativados"</string>
@@ -188,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Local definido por GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Solicitações de localização ativas"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Limpar todas as notificações."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Configurações"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Configurações de notificação"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Configurações de <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"A tela girará automaticamente."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"A tela está bloqueada na orientação paisagem."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"A tela está bloqueada na orientação retrato."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Agora a tela vai girar automaticamente."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"A tela está bloqueada na orientação cenário."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"A tela está bloqueada na orientação retrato."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Mostruário de sobremesas"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -243,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Dados da rede celular"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Uso de dados"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Dados restantes"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limite excedido"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Limite atingido – uso de dados pausado"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Usados: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limite: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Aviso de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Suas telas recentes aparecem aqui"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informações do aplicativo"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"bloquear no app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"pesquisar"</string>
@@ -260,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Pesquisar"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>, deslize para cima."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Para <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>, deslize para a esquerda."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Sem interrupções, incluindo alarmes"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Sem interrupções. Nem mesmo alarmes."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Sem interrupções"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Apenas interrupções prioritárias"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Seu próximo alarme será às <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -268,44 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Você não ouvirá o alarme às <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificações menos urgentes abaixo"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Toque novamente para abrir"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Deslize para cima para desbloquear"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Deslize para a esquerda para usar o telefone"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Deslize para a esquerda para usar a câmera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Indefinidamente"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nenhum"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioridade"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Tudo"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Carregando (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> até concluir)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Trocar usuário"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Alternar usuário. Usuário atual <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Mostrar perfil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Adicionar usuário"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Novo usuário"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Convidado"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Sair da sessão de convidado?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Sair da sessão de convidado removerá os dados locais."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Adicionar convidado"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Remover convidado"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Remover convidado?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Todos os apps e dados nesta sessão serão excluídos."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Remover"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bem-vindo, convidado."</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Por 1 minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Por %d minutos"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Por 1 hora"</item>
-    <item quantity="other" msgid="5408537517529822157">"Por %d horas"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Deseja continuar a sessão?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Recomeçar"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Sim, continuar"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Adicionar novo usuário?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Quando você adiciona um novo usuário, essa pessoa precisa configurar o próprio espaço.\n\nQualquer usuário pode atualizar apps para os demais usuários."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"A Economia de bateria está ativada"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduz o desempenho e os dados em segundo plano"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Desativar a economia de bateria"</string>
@@ -317,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Iniciar agora"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Sem notificações"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"O dispositivo pode ser monitorado"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"O perfil pode ser monitorado"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"A rede pode ser monitorada"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Monitoramento de dispositivos"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitoramento de perfis"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Monitoramento de rede"</string>
-    <string name="open_app" msgid="4011771120339160755">"Abrir app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Desativar VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Desconectar VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar seu dispositivo e a atividade na rede, incluindo e-mails, apps e websites seguros.\n\nPara mais informações, entre em contato com o administrador."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Você autorizou \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" a configurar uma conexão VPN.\n\nEste app pode monitorar seu dispositivo e a atividade na rede, incluindo e-mails, apps e websites seguros."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Você está conectado a uma VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nO provedor de serviços de VPN pode monitorar seu dispositivo e a atividade na rede, incluindo e-mails, apps e websites seguros."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, incluindo e-mails, apps e websites seguros. Para mais informações, entre em contato com o administrador.\n\nAlém disso, você autorizou \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" a configurar uma conexão VPN. Esse app também pode monitorar a atividade na rede."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, incluindo e-mails, apps e websites seguros. Para mais informações, entre em contato com o administrador.\n\nAlém disso, você está conectado a uma VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). O provedor de serviços de VPN também pode monitorar a atividade na rede."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Este perfil é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar seu dispositivo e a atividade na rede, incluindo e-mails, apps e sites seguros.\n\nPara mais informações, entre em contato com o administrador."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSeu perfil é gerenciado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO administrador pode monitorar sua atividade no dispositivo e na rede, incluindo e-mails, apps e sites seguros.\n\nPara mais informações, contate o administrador."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Este perfil é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, incluindo e-mails, apps e sites seguros. Para mais informações, entre em contato com o administrador.\n\nVocê autorizou \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" a fazer conexões VPN e este app também pode monitorar atividades de rede."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Este perfil é gerenciado por:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, incluindo e-mails, apps e sites seguros. Para mais informações, contate o administrador.\n\nVocê está conectado a uma VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") e o provedor de serviços de VPN também pode monitorar atividades de rede."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSeu perfil é gerenciado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, como e-mails, apps e sites seguros. Para mais informações, contate o administrador.\n\nVocê autorizou \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" a fazer conexões VPN e o provedor de serviços de VPN também pode monitorar atividades de rede."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Este dispositivo é gerenciado por:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nSeu perfil é gerenciado por:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nO administrador pode monitorar sua atividade na rede, como e-mails, apps e sites seguros. Para mais informações, contate o administrador.\n\nVocê está conectado a uma VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") e o provedor de serviços de VPN também pode monitorar atividades de rede."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"O dispositivo permanecerá bloqueado até que você o desbloqueie manualmente"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Receba notificações mais rápido"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Veja-as antes de desbloquear"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Não, obrigado"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Configurar"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Som desativado por <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ro/strings.xml b/packages/SystemUI/res/values-ro/strings.xml
index 9da5cc5..4e8880e 100644
--- a/packages/SystemUI/res/values-ro/strings.xml
+++ b/packages/SystemUI/res/values-ro/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Ștergeţi"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Eliminaţi din listă"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informaţii despre aplicaţie"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Ecranele dvs. recente apar aici"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Renunţaţi la aplicaţiile recente"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 aplicaţie recentă"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Înapoi"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Ecranul de pornire"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Meniu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Ecrane recente"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Căutați"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Cameră foto"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Deblocați"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"deblocați"</string>
+    <string name="phone_label" msgid="2320074140205331708">"deschideți telefonul"</string>
+    <string name="camera_label" msgid="7261107956054836961">"deschideți camera foto"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Buton pentru comutarea metodei de introducere."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Buton zoom pentru compatibilitate."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Faceţi zoom de la o imagine mai mică la una mai mare."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Semnal Wi-Fi: două bare."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Semnal Wi-Fi: trei bare."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Semnal Wi-Fi: complet."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Conectat la <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Conectat la <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Fără WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX o bară."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX două bare."</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter activat."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibrare sonerie."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Sonerie silenţioasă."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Închideți <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> a fost eliminată."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Se inițiază <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Notificarea a fost închisă."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Fereastră pentru notificări."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Setări rapide."</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Ecranul de blocare."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"Setări"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Ecrane recente."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Utilizatorul <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Conexiunea prin Wi-Fi este dezactivată."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Conexiunea prin Wi-Fi este activată."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Semnal mobil: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Baterie <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Mod Avion <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Locație: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Modul Avion este dezactivat."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Modul Avion este activat."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Modul Avion este dezactivat."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Modul Avion este activat."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Conexiunea prin Bluetooth este dezactivată."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Conexiunea prin Bluetooth este activată."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Se conectează prin Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Conectat prin Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Conexiunea prin Bluetooth este dezactivată."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Conexiunea prin Bluetooth este activată."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Raportarea locației este dezactivată."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Raportarea locației este activată."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Raportarea locației este dezactivată."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Raportarea locației este activată."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarmă setată pentru <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Închideți panoul"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Mai mult timp"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mai puțin timp"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Închideți panoul."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Mai mult timp."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mai puțin timp."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Lanterna este dezactivată."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Lanterna este activată."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Lanterna este dezactivată."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Lanterna este activată."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inversarea culorilor este dezactivată."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inversarea culorilor este activată."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Hotspotul mobil este dezactivat."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Hotspotul mobil este activat."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Transmiterea ecranului a fost oprită."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Luminozitatea ecranului"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Datele 2G-3G sunt dezactivate"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Datele 4G sunt dezactivate"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Datele mobile sunt dezactivate"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Locaţie setată prin GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Solicitări locație active"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Ștergeţi toate notificările."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Setări"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Setări pentru notificări"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Setări <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ecranul se va roti în mod automat."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ecranul este blocat în orientarea de tip peisaj."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ecranul este blocat în orientarea de tip portret."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Acum, ecranul se va roti în mod automat."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ecranul este acum blocat în orientarea de tip peisaj."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ecranul este acum blocat în orientarea de tip portret."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vitrina cu dulciuri"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Date mobile"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Utilizarea datelor"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Date rămase"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Peste limită"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"S-a atins limita – s-a întrerupt utilizarea datelor"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> utilizați"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limită de <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Avertizare: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Ecranele dvs. recente apar aici"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informații despre aplicație"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"blocare la aplicație"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"căutare"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Căutaţi"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Glisaţi în sus pentru <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Glisaţi spre stânga pentru <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Fără întreruperi, inclusiv alarme"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Fără întreruperi. Nici măcar alarme."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Fără întreruperi"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Numai întreruperi cu prioritate"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Următoarea alarmă este setată la <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -266,47 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Nu veți auzi alarma la <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Notificările mai puțin urgente mai jos"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Atingeți din nou pentru a deschide"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Glisați în sus pentru a debloca"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Glisați la dreapta pentru a acesa telefonul"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Glisați la stânga pentru a accesa camera foto"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Nedefinit"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Niciuna"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritate"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Toate"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Se încarcă (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> până la finalizare)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Comutați între utilizatori"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Schimbați utilizatorul (utilizator actual <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Afișați profilul"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Adăugați un utilizator"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Utilizator nou"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Invitat"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest_dialog_title (7587460301980067285) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest_dialog_message (10255285459589280) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_title (6419439912885956132) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Timp de un minut"</item>
-    <item quantity="other" msgid="6924190729213550991">"Timp de %d (de) minute"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Timp de o oră"</item>
-    <item quantity="other" msgid="5408537517529822157">"Timp de %d (de) ore"</item>
-  </plurals>
+    <string name="guest_new_guest" msgid="600537543078847803">"Adăugați un oaspete"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"Eliminați invitatul"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Ștergeți invitatul?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Toate aplicațiile și datele din această sesiune vor fi șterse."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Ștergeți"</string>
+    <string name="guest_wipe_session_title" msgid="6419439912885956132">"Bine ați revenit în sesiunea pentru invitați!"</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vreți să continuați sesiunea?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Începeți din nou"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Da, continuați"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Adăugați utilizator nou?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Când adăugați un utilizator nou, acesta trebuie să-și configureze spațiul.\n\nOrice utilizator poate actualiza aplicațiile pentru toți ceilalți utilizatori."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Economisirea bateriei este activată"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Reduce performanța și datele de fundal"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Dezactivați economisirea bateriei"</string>
@@ -318,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Începeți acum"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Nicio notificare"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Dispozitivul poate fi monitorizat"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profilul poate fi monitorizat"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Rețeaua poate fi monitorizată"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Monitorizarea dispozitivului"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitorizarea profilului"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Monitorizarea rețelei"</string>
-    <string name="open_app" msgid="4011771120339160755">"Deschideți aplicația"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Dezactivați conexiunea prin VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Deconectați rețeaua VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Acest dispozitiv este administrat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul vă poate monitoriza activitatea pe dispozitiv și în rețea, inclusiv e-mailurile, aplicațiile și site-urile securizate.\n\nPentru mai multe informații, contactați administratorul."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Ați acordat aplicației „<xliff:g id="APPLICATION">%1$s</xliff:g>” permisiunea de a configura o conexiune VPN.\n\nAceastă aplicație vă poate monitoriza activitatea pe dispozitiv și în rețea, inclusiv email-urile, aplicațiile și site-urile securizate."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Sunteți conectat(ă) la o rețea VPN („<xliff:g id="APPLICATION">%1$s</xliff:g>”).\n\nFurnizorul de servicii VPN vă poate monitoriza activitatea pe dispozitiv și în rețea, inclusiv email-urile, aplicațiile și site-urile securizate."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Dispozitiv administrat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul vă poate monitoriza activitatea în rețea, inclusiv e-mailurile, aplicațiile și site-urile securizate. Pentru detalii, contactați administratorul.\n\nAți permis aplicației „<xliff:g id="APPLICATION">%2$s</xliff:g>” să configureze o conexiune VPN. Aplicația vă poate monitoriza activitatea în rețea."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Dispozitiv administrat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul vă poate monitoriza activitatea în rețea, inclusiv e-mailurile, aplicațiile și site-urile securizate. Pentru detalii, contactați administratorul.\n\nSunteți conectat(ă) la o rețea VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>”). Furnizorul de servicii VPN vă poate monitoriza activitatea în rețea."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profilul este gestionat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul poate monitoriza dispozitivul și activitatea în rețea, inclusiv e-mailurile, aplicațiile și site-urile securizate.\n\nPentru mai multe informații, contactați administratorul."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Dispozitivul este gestionat de:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilul este gestionat de:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratorul poate monitoriza dispozitivul și activitatea în rețea, inclusiv e-mailurile, aplicațiile și site-urile securizate.\n\nPentru mai multe informații, contactați administratorul."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Profilul este gestionat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul poate monitoriza activitatea în rețea (e-mailurile, aplicațiile și site-urile securizate). Pentru mai multe informații, contactați admin.\n\nÎn plus, ați permis aplicației „<xliff:g id="APPLICATION">%2$s</xliff:g>” să configureze o conexiune VPN. Și aceasta poate monitoriza activitatea în rețea."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Profilul este gestionat de:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratorul poate monitoriza activitatea în rețea (e-mailurile, aplicațiile și site-urile securizate). Pentru mai multe informații, contactați administratorul.\n\nSunteți conectat(ă) și la VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>”). Și furnizorul de servicii VPN poate monitoriza activitatea în rețea."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Disp. este gestionat de:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilul este gestionat de:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdm. poate monitoriza activitatea în rețea (e-mailurile, aplicațiile și site-urile securizate). Pt. mai multe informații, contactați adm.\n\nÎn plus, ați permis aplicației „<xliff:g id="APPLICATION">%3$s</xliff:g>” să config. o conexiune VPN. Și aceasta poate monitoriza activitatea în rețea."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Dispozitivul este gestionat de:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilul este gestionat de:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdm. poate monitoriza activitatea în rețea (e-mailurile, aplicațiile și site-urile securizate). Pt. mai multe informații, contactați adm.\n\nSunteți conectat(ă) și la VPN („<xliff:g id="APPLICATION">%3$s</xliff:g>”). Și furnizorul de servicii VPN poate monitoriza activitatea în rețea."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Dispozitivul va rămâne blocat până când îl deblocați manual"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Obțineți notificări mai rapid"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Doresc să se afișeze înainte de deblocare"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nu, mulț."</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Config."</string>
+    <string name="muted_by" msgid="6147073845094180001">"Dezactivate de <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ru/strings.xml b/packages/SystemUI/res/values-ru/strings.xml
index d24f356..f83d7f9 100644
--- a/packages/SystemUI/res/values-ru/strings.xml
+++ b/packages/SystemUI/res/values-ru/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Очистить"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Удалить из списка"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"О приложении"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Здесь будут показаны недавние приложения."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Закрыть недавние приложения"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Недавних приложений: 1"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Назад"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Домой"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Недавние приложения."</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Поиск"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон."</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Разблокировать."</string>
+    <string name="unlock_label" msgid="8779712358041029439">"Разблокировать."</string>
+    <string name="phone_label" msgid="2320074140205331708">"Открыть телефон."</string>
+    <string name="camera_label" msgid="7261107956054836961">"Открыть камеру."</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Кнопка переключения способа ввода."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Кнопка масштабирования (режим совместимости)"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Уменьшение изображения для увеличения свободного места на экране."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: два деления"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: три деления"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi: надежный сигнал"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>: подключено."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>: подключено."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Нет сигнала WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Сигнал WiMAX: одно деление."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Сигнал WiMAX: два деления."</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Телетайп включен."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Вибровызов."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Беззвучный режим."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Удаление приложения <xliff:g id="APP">%s</xliff:g> из списка."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Приложение \"<xliff:g id="APP">%s</xliff:g>\" удалено из списка."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Запуск приложения <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Уведомление закрыто"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Панель уведомлений"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Быстрые настройки"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Заблокированный экран."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Настройки"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Недавние приложения."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Пользователь <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="NETWORK">%2$s</xliff:g>: <xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Модуль Wi-Fi отключен."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Модуль Wi-Fi включен."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобильная сеть: <xliff:g id="NETWORK">%3$s</xliff:g> (<xliff:g id="TYPE">%2$s</xliff:g>, <xliff:g id="SIGNAL">%1$s</xliff:g>)"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батарея: <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Режим полета <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Доступ к геоданным <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Режим полета отключен."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Режим полета включен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Режим полета отключен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Режим полета включен."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Модуль Bluetooth отключен."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Модуль Bluetooth включен."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth-соединение устанавливается."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth-соединение установлено."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Модуль Bluetooth отключен."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Модуль Bluetooth включен."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Отправка геоданных отключена."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Отправка геоданных включена."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Отправка геоданных отключена."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Отправка геоданных включена."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Будильник установлен на <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Закрыть панель."</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Увеличить продолжительность."</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Уменьшить продолжительность."</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Закрыть панель."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Увеличить время."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Уменьшить время."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Фонарик отключен."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Фонарик включен."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Фонарик отключен."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Фонарик включен."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Инверсия цвета отключена."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Инверсия цвета включена."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Точка доступа отключена."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Точка доступа включена."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Трансляция прекращена."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Яркость экрана"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Передача данных 2G/3G отключена"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Передача данных 4G отключена"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Передача мобильных данных отключена"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Координаты по GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Есть активные запросы на определение местоположения"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Удалить все уведомления"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Настройки"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Настройки уведомлений"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Настройки приложения \"<xliff:g id="APP_NAME">%s</xliff:g>\""</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Экран будет поворачиваться автоматически."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Выбрана только альбомная ориентация экрана."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Выбрана только книжная ориентация экрана."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Автоповорот экрана включен."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Экран зафиксирован в горизонтальном положении."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Экран зафиксирован в вертикальном положении."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Коробка со сладостями"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Заставка"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Передача данных"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Передача данных"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Остается данных"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Ограничение превышено"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Достигнут лимит, передача данных приостановлена"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Использовано: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Ограничение: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Предупреждение: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Здесь будут показаны недавние приложения"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Сведения о приложении"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"Блокировать в приложении"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"поиск"</string>
@@ -259,53 +289,41 @@
     <string name="description_target_search" msgid="3091587249776033139">"Поиск"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Проведите вверх, чтобы <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Проведите влево, чтобы <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Режим \"Не беспокоить\" (звук будильника отключен)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Никаких оповещений, даже от будильника."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Не беспокоить"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Только приоритетные оповещения"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Только важные оповещения"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Следующий будильник: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"Следующий будильник: <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Следующий будильник: <xliff:g id="ALARM_TIME">%s</xliff:g>. Звук отключен."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Показать менее важные оповещения"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Нажмите ещё раз, чтобы открыть"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Для разблокировки проведите пальцем по экрану"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Чтобы открыть приложение \"Телефон\", пролистните вправо"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Чтобы включить камеру, пролистните влево"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Не определено"</string>
-    <string name="interruption_level_none" msgid="3831278883136066646">"–"</string>
-    <string name="interruption_level_priority" msgid="6517366750688942030">"Приоритет"</string>
+    <string name="interruption_level_none" msgid="3831278883136066646">"Не беспокоить"</string>
+    <string name="interruption_level_priority" msgid="6517366750688942030">"Важные"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Все"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Зарядка батареи (осталось <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Сменить пользователя."</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Сменить аккаунт. Вход выполнен под именем <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>."</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Показать профиль."</string>
     <string name="user_add_user" msgid="5110251524486079492">"Добавить пользователя"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Новый пользователь"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Гость"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Добавить гостя"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Удалить аккаунт гостя"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Выйти из гостевого режима?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"При выходе из гостевого режима локальные данные будут удалены."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Удалить аккаунт гостя?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Все приложения и данные этого профиля будут удалены."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Удалить"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Рады видеть вас снова!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 мин."</item>
-    <item quantity="other" msgid="6924190729213550991">"%d мин."</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 ч."</item>
-    <item quantity="other" msgid="5408537517529822157">"%d ч."</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Продолжить сеанс?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Начать заново"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Да, продолжить"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Добавить пользователя?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"После создания профиля его необходимо настроить.\n\nОбновлять приложения для всех аккаунтов может любой пользователь устройства."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Включен режим энергосбережения"</string>
-    <string name="battery_saver_notification_text" msgid="820318788126672692">"Прекращение передачи данных в фоновом режиме"</string>
+    <string name="battery_saver_notification_text" msgid="820318788126672692">"Откл. фоновой передачи данных"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Отключить режим энергосбережения"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
     <string name="notification_hidden_text" msgid="1135169301897151909">"Содержимое скрыто"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Начать"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Нет уведомлений"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Устройство может контролироваться"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Действия в профиле могут отслеживаться"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Сеть может отслеживаться"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Отслеживание устройств"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Мониторинг профиля"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Отслеживание сетей"</string>
-    <string name="open_app" msgid="4011771120339160755">"Открыть приложение"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Отключить VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Отключить VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Этим устройством управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать ваши действия в Интернете, включая работу с электронной почтой, приложениями и защищенными веб-сайтами.\n\nЗа дополнительной информацией обратитесь к администратору."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Вы разрешили приложению \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" подключаться к сети VPN.\n\nЭто приложение может отслеживать использование устройства и ваши действия в Интернете, включая работу с электронной почтой, приложениями и защищенными веб-сайтами."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Устройство подключено к сети VPN (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nПоставщик услуг VPN может отслеживать ваши действия в Интернете, включая работу с электронной почтой, приложениями и защищенными веб-сайтами."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Этим устройством управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать вашу работу с электронной почтой, приложениями и защищенными веб-сайтами. Обратитесь к нему за дополнительной информацией.\n\nВаши действия в сети также доступны приложению \"<xliff:g id="APPLICATION">%2$s</xliff:g>\", которому вы разрешили подключаться к сети VPN."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Этим устройством управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать вашу работу с электронной почтой, приложениями и защищенными веб-сайтами. Обратитесь к нему за дополнительной информацией.\n\nУстройство подключено к сети VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Ваши действия также доступны поставщику услуг VPN."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Этим профилем управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать ваши действия в Интернете, включая работу с электронной почтой, приложениями и защищенными веб-сайтами.\n\nЗа дополнительной информацией обращайтесь к администратору."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Устройством управляет организация:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилем управляет организация:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор может отслеживать ваши действия в Интернете, включая работу с электронной почтой, приложениями и защищенными веб-сайтами.\n\nЗа дополнительной информацией обращайтесь к администратору."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Этим профилем управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать ваши действия в Интернете, включая работу с эл. почтой, приложениями и защищенными веб-сайтами. Обратитесь к нему за дополнительной информацией.\n\nВы разрешили приложению \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" подключаться к VPN, и ему также доступны эти сведения."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Этим профилем управляет организация:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор может отслеживать ваши действия в Сети, включая работу с эл. почтой, приложениями и защищенными веб-сайтами Обратитесь к нему за дополнительной информацией.\n\nУстройство подключено к сети VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Поставщику услуг VPN также видны ваши действия в Сети."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Устройством управляет организация:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилем управляет организация:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор может отслеживать вашу работу с эл. почтой, приложениями и защищенными веб-сайтами. Обратитесь к нему за дополнительной информацией.\n\nВы разрешили приложению \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" подключаться к VPN, и ему также доступны эти сведения."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Устройством управляет организация:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилем управляет организация:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор может отслеживать вашу работу с почтой, приложениями и защищенными веб-сайтами. Обратитесь к нему за дополнительной информацией.\n\nУстройство подключено к сети VPN (<xliff:g id="APPLICATION">%3$s</xliff:g>). Поставщику услуг VPN видны ваши действия в Сети."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Устройство необходимо будет разблокировать вручную"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Быстрый доступ к уведомлениям"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Просматривайте уведомления на заблокированном экране."</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Закрыть"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Настроить"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Звук отключен приложением \"<xliff:g id="THIRD_PARTY">%1$s</xliff:g>\""</string>
 </resources>
diff --git a/packages/SystemUI/res/values-si-rLK/strings.xml b/packages/SystemUI/res/values-si-rLK/strings.xml
index 18601a0..cff1265 100644
--- a/packages/SystemUI/res/values-si-rLK/strings.xml
+++ b/packages/SystemUI/res/values-si-rLK/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"හිස් කරන්න"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"ලැයිස්තුවෙන් ඉවත් කරන්න"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"යෙදුම් තොරතුරු"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"මෙහි ඔබගේ මෑතක තිර පෙන්නුම් කරයි"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"මෑත යෙදුම් ඉවතලන්න"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"මෑත යෙදුම් 1 ක්"</item>
@@ -35,7 +34,7 @@
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"දැනුම්දීම්"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"බැටරිය අඩුය"</string>
     <string name="battery_low_percent_format" msgid="1077244949318261761">"<xliff:g id="NUMBER">%d%%</xliff:g> ක් ඉතිරියි"</string>
-    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> ක් ඉතිරියි. බැටරි ඉතිරි කරන්නා සක්‍රීයයි."</string>
+    <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"<xliff:g id="NUMBER">%d%%</xliff:g> ක් ඉතිරියි. බැටරිය සුරකින්නා සක්‍රීයයි."</string>
     <string name="invalid_charger" msgid="4549105996740522523">"USB ආරෝපණය සහය නොදක්වයි.\nසපයන ලද ආරෝපකය පමණක් භාවිතා කරන්න."</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"USB ආරෝපණය කිරීම සහාය නොදක්වයි."</string>
     <string name="invalid_charger_text" msgid="5474997287953892710">"සපයන ලද අරෝපකය පමණක් භාවිතා කරන්න."</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"ආපසු"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"මුල් පිටුව"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"මෙනුව"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"මෑතක තිර"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"සොයන්න"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"කැමරාව"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"දුරකථනය"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"අඟුල අරින්න"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"අඟුල අරින්න"</string>
+    <string name="phone_label" msgid="2320074140205331708">"දුරකථනය විවෘත කරන්න"</string>
+    <string name="camera_label" msgid="7261107956054836961">"කැමරාව විවෘත කරන්න"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ආදාන ක්‍රමය මාරු කිරීමේ බොත්තම."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"ගැළපෙන විශාලන බොත්තම."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"විශාල තිරය වෙත කුඩාව විශාලනය කරන්න."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi තීරු දෙකයි."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi තීරු තුනයි."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi සංඥාව පිරී ඇත."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> වෙත සම්බන්ධ කරන ලදි."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> වෙත සම්බන්ධ කරන ලදි."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX නැත."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX තීරු එකයි."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX තීරු දෙකයි."</string>
@@ -151,29 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter ක්‍රියාත්මකයි."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"හඬ නඟනය කම්පනය වේ."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"හඬ නඟනය නිශ්ශබ්දයි."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> ඉවතලන්න."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> අස් කර ඇත."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> ආරම්භ කරමින්."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"දැනුම්දීම නිෂ්ප්‍රභා කරඇත."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"දැනුම්දීම් ආවරණය."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"ක්ෂණික සැකසීම්."</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"අගුළු තිරය."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"සැකසීම්"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"මෑතක තිර."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"පරිශීලකයා <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi සක්‍රියයි."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"ජංගම <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"බැටරිය <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"අහස්යානා ආකාරය <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"බ්ලූටූත් <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"ස්ථානය <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"අහස්යානා අකාරය අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"අහස්යානා ආකාරය සක්‍රීයයි."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"අහස්යානා අකාරය අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"අහස්යානා ආකාරය සක්‍රීයයි."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"බ්ලූටූත් අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"බ්ලූටූත් සක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"බ්ලූටූත් සම්බන්ධවෙමින්."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"බ්ලූටූත් සම්බන්ධිතයි."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"බ්ලූටූත් අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"බ්ලූටූත් සක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"ස්ථානය වාර්තාකරණය අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"ස්ථානය වාර්තාකරණය සක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"ස්ථානය වාර්තාකරණය අක්‍රියයි."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"ස්ථානය වාර්තාකරණය සක්‍රියයි."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> සඳහා සීනුව සකස් කර ඇත."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"පැනලය වහන්න"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"වේලාව වැඩියෙන්"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"වේලාව අඩුවෙන්"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"පැනලය වහන්න."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"වේලාව වැඩියෙන්."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"වේලාව අඩුවෙන්."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"සැණෙළි ආලෝකය අක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"සැණෙළි ආලෝකය සක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"සැණෙළි ආලෝකය අක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"සැණෙළි ආලෝකය සක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"වර්ණ අපවර්තනය අක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"වර්ණ අපවර්තනය සක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"ජංගම හොට්ස්පොටය අක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"ජංගම හොට්ස්පොටය සක්‍රිය කරන ලදි."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"තිරය විකාශය කිරීම නැවත් වන ලදි."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"දීප්තිය දර්ශනය කරන්න"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G දත්ත අක්‍රියයි"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G දත්ත අක්‍රියයි"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"සෙලියුලර් දත්ත අක්‍රියයි"</string>
@@ -186,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS මඟින් ස්ථානය සකසා ඇත"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"පිහිටීම් ඉල්ලීම් සක්‍රියයි"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"සියලු දැනුම්දීම් හිස් කරන්න."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"සැකසීම්"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"දැනුම්දීම් සැකසීම්"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> සැකසීම්"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"තිරය ස්වයංක්‍රීයව කරකැවේ."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"තිරය තිරස් දිශානතියෙහි අගුළු දමා ඇත."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"තිරය සිරස් දිශානතිය තුළ අගුළු වැටී ඇත."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"තිරය ස්වයංක්‍රීයව කරකැවේ."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"තිරය දැන් තිරස් දිශානතිය අගුළු දමා ඇත."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"තිරය සිරස් දිශානතිය තුළ අගුළු වැටී ඇත."</string>
     <string name="dessert_case" msgid="1295161776223959221">"අතුරුපස අවස්තාව"</string>
     <string name="start_dreams" msgid="7219575858348719790">"දවල් හීනය"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ඊතර නෙට්"</string>
@@ -241,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"සෙලියුලර් දත්ත"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"දත්ත භාවිතය"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ඉතිරි ඇති දත්ත"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"සීමාවට වඩා වැඩිය"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"සීමාවට ළඟාවී ඇත – දත්ත භාවිතය විරාමය කරන ලදී"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> භාවිතා කර තිබේ"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> සීමිත"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> අවවාද කිරීම"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"මෙහි ඔබගේ මෑතක තිර පෙන්නුම් කරයි"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"යෙදුම් තොරතුරු"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"යෙදුමට අඟුළු දැමීම"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"සෙවීම"</string>
@@ -258,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"සෙවීම"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> සඳහා උඩට සර්පණය කරන්න."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> සඳහා වමට සර්පණය කරන්න."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"සීනු ඇතුළුව, අතුරු බිඳීම් නැත"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"අතුරු බිඳීම් නැත. අඩුම තරමේ අනතුරු ඇඟවීමක්වත් නැත."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"අතුරු බිදුම් නැත"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"ප්‍රමුඛ අතුරු බිඳීම් පමණයි"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"ඔබගේ ඊළඟ සීනුව <xliff:g id="ALARM_TIME">%s</xliff:g> තිබේ"</string>
@@ -266,45 +295,32 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> හි තිබෙන ඔබගේ සීනුව ඔබට ඇසෙන්නේ නැත"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"හදිසිය අඩු දැනුම් දීම් පහත"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"විවෘත කිරීමට නැවත ස්පර්ශ කරන්න"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"අගුළු ඇරීමට ස්වයිප් කරන්න."</string>
     <string name="phone_hint" msgid="3101468054914424646">"දුරකථන සඳහා දකුණට ස්වයිප් කරන්න"</string>
     <string name="camera_hint" msgid="5241441720959174226">"කැමරාව සඳහා දකුණට ස්වයිප් කරන්න"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"අනියත ආකාරයට"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"කිසිවක් නැත"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ප්‍රමුඛතාව"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"සියලු"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ආරෝපණය වෙමින් (සම්පුර්ණ වන තෙක් <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"පරිශීලක මාරුව"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"පරිශීලකයා මාරු කරන්න,දැන් සිටින පරිශීලකයා <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"පැතිකඩ පෙන්වන්න"</string>
     <string name="user_add_user" msgid="5110251524486079492">"පරිශීලකයෙක් එක් කරන්න"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"නව පරිශීලකයා"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"අමුත්තා"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"අමුත්තාගේ සැසියෙන් පිටවෙයිද?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"අමුත්තාගේ සැසිය අවසන් කිරීමෙන් පෙදෙසි දත්ත සියල්ලම පිට කරයි."</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"ආගන්තුකයා එකතු කරන්න"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"අමුත්තාන් ඉවත් කරන්න"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"අමුත්තාන් ඉවත් කරන්නද?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"මෙම සැසියේ සියළුම යෙදුම් සහ දත්ත මකාවී."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ඉවත් කරන්න"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"නැවත සාදරයෙන් පිළිගනිමු, අමුත්තා!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"විනාඩි එකක් සඳහා"</item>
-    <item quantity="other" msgid="6924190729213550991">"විනාඩි %d සඳහා"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"පැයක් සඳහා"</item>
-    <item quantity="other" msgid="5408537517529822157">"පැය %d ක් සඳහා"</item>
-  </plurals>
-    <string name="battery_saver_notification_title" msgid="237918726750955859">"බැටරි ඉතිරි කරන්නා සක්‍රීයයි"</string>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"ඔබගේ සැසිය දිගටම කරගෙන යෑමට ඔබට අවශ්‍යද?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"යළි මුල සිට අරඹන්න"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"ඔව්, දිගටම කරගෙන යන්න"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"අලුත් පරිශීලකයෙක් එකතු කරන්නද?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"ඔබ අලුත් පරිශීලකයෙක් එකතු කරන විට, එම පුද්ගලයා ඔහුගේ වැඩ කරන ඉඩ සකසා ගත යුතුය.\n\nසියළුම අනෙක් පරිශීලකයින් සඳහා ඕනෑම පරිශීලකයෙකුට යාවත්කාලීන කළ හැක."</string>
+    <string name="battery_saver_notification_title" msgid="237918726750955859">"බැටරිය සුරකින්නා සක්‍රීයයි"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ක්‍රියාකාරිත්වය සහ පසුබිම් දත්ත අඩු කරන්න"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"බැටරි සුරැකීම අක්‍රිය කරන්න"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
@@ -315,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"දැන් අරඹන්න"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"දැනුම්දීම් නැත"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"ඇතැම් විට උපාංගය නිරීක්ෂණය විය හැක"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ඇතැම් විට පැතිකඩ නිරීක්ෂණය කරන ලදි"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"ඇතැම් විට ජාලය නිරීක්ෂණය විය හැක"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"උපාංගය නිරීක්ෂණය"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"පැතිකඩ නිරීක්ෂණය කිරීම"</string>
     <string name="monitoring_title" msgid="169206259253048106">"ජාල නිරීක්ෂණය"</string>
-    <string name="open_app" msgid="4011771120339160755">"යෙදුම විවෘත කරන්න"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN අබල කරන්න."</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN විසන්ධි කරන්න"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"මෙම උපාංගය කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-මේල්, යෙදුම්, සහ ආරක්ෂාකාරී වෙබ් අඩවි ඇතුළු, ඔබගේ ජාල ක්‍රියාකාරකම නිරීක්ෂණය කිරීමට ඔබගේ පරිපාලකට හැක.\n\nවැඩිදුර විස්තර සඳහා, ඔබගේ පරිපාලක අමතන්න."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"VPN සම්බන්ධතාව සකස් කරගැනීමට \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" අවසර ඔබ දෙන ලදි.\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට මෙම යෙදුමට හැකිය."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") වෙත ඔබ සම්බන්ධ වී තිබේ.\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ VPN සේවාවේ සපයන්නාට ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කළ හැක."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"මෙම උපාංගය පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට ඔබගේ පාලකයාට හැකියාව තිබේ. වැඩිපුර තොරතුරු සඳහා ඔබගේ පාලකයා සම්බන්ධ කර ගන්න.\n\nතවද, VPN සම්බන්ධතාව සකස් කරගැනීමට \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" අවසර ඔබ දෙන ලදි. මෙම යෙදුම ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කරයි."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"මෙම උපාංගය පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට ඔබගේ පාලකයාට හැකියාව තිබේ. වැඩිපුර තොරතුරු සඳහා ඔබගේ පාලකයා සම්බන්ධ කර ගන්න.\n\nතවද, VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") වෙත ඔබ සම්බන්ධ වී තිබේ. තවද ඔබගේ VPN සේවාවේ සපයන්නාට ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කළ හැක."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"මෙම පැතිකඩ කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-මේල්, යෙදුම්, සහ ආරක්ෂාකාරී වෙබ් අඩවි ඇතුළු, ඔබගේ ජාල ක්‍රියාකාරකම නිරීක්ෂණය කිරීමට ඔබගේ පරිපාලකට හැක.\n\nවැඩිදුර විස්තර සඳහා, ඔබගේ පරිපාලක අමතන්න."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"මෙම උපාංගය කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nමෙම පැතිකඩ කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nඊ-මේල්, යෙදුම්, සහ ආරක්ෂාකාරී වෙබ් අඩවි ඇතුළු, ඔබගේ ජාල ක්‍රියාකාරකම නිරීක්ෂණය කිරීමට ඔබගේ පරිපාලකට හැක.\n\nවැඩිදුර විස්තර සඳහා, ඔබගේ පරිපාලක අමතන්න."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"මෙම පැතිකඩ පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට ඔබගේ පාලකයාට හැකියාව තිබේ. වැඩිපුර තොරතුරු සඳහා ඔබගේ පාලකයා සම්බන්ධ කර ගන්න.\n\nතවද, VPN සම්බන්ධතාව සකස් කරගැනීමට \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" අවසර ඔබ දෙන ලදි. මෙම යෙදුම ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කරයි."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"මෙම පැතිකඩ පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට ඔබගේ පාලකයාට හැකියාව තිබේ. වැඩිපුර තොරතුරු සඳහා ඔබගේ පාලකයා සම්බන්ධ කර ගන්න.\n\nතවද, VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") වෙත ඔබ සම්බන්ධ වී තිබේ. තවද ඔබගේ VPN සේවාවේ සපයන්නාට ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කළ හැක."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"මෙම උපාංගය පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nමෙම පැතිකඩ පාලනය කරන්නේ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nඊ-තැපැල්, යෙදුම්, සහ අරක්ෂිත වෙබ් අඩවි ඇතුළුව ඔබගේ ජාලයේ ක්‍රියාකාරකම් නිරීක්ෂණය කිරීමට ඔබගේ පාලකයාට හැකියාව තිබේ. වැඩිපුර තොරතුරු සඳහා ඔබගේ පාලකයා සම්බන්ධ කර ගන්න.\n\nතවද, VPN සම්බන්ධතාව සකස් කරගැනීමට \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" අවසර ඔබ දෙන ලදි. මෙම යෙදුම ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කරයි."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"මෙම උපාංගය කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nමෙම පැතිකඩ කළමනාකරණය කරනු ලබන්නේ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nඊ-මේල්, යෙදුම්, සහ ආරක්ෂාකාරී වෙබ් අඩවි ඇතුළු, ඔබගේ ජාල ක්‍රියාකාරකම නිරීක්ෂණය කිරීමට ඔබගේ පරිපාලකට හැක. වැඩිදුර විස්තර සඳහා, ඔබගේ පරිපාලක අමතන්න.\n\nතවද,VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") වෙත ඔබ සම්බන්ධ වී තිබේ. තවද ඔබගේ VPN සේවාවේ සපයන්නාට ජාල ක්‍රියාකාරකම් නිරීක්ෂණය කළ හැක."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"ඔබ අතින් අගුළු අරින තුරු උපකරණය අගුළු වැටි තිබේ"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"දැනුම්දීම් ඉක්මනින් ලබාගන්න"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ඔබ අඟුළු හැරීමට කලින් ඒවා බලන්න"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"එපා ස්තූතියි"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"සකසන්න"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> විසින් නිශ්ශබ්ද කරන ලදි"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sk/strings.xml b/packages/SystemUI/res/values-sk/strings.xml
index 89235b0..d782dd7 100644
--- a/packages/SystemUI/res/values-sk/strings.xml
+++ b/packages/SystemUI/res/values-sk/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Vymazať"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Odstrániť zo zoznamu"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Informácie o aplikácii"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Vaše nedávne obrazovky sa zobrazia tu."</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Zatvoriť nedávne aplikácie"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 nová aplikácia"</item>
@@ -45,7 +44,7 @@
     <string name="battery_saver_start_action" msgid="5576697451677486320">"Zapnúť šetrič batérie"</string>
     <string name="status_bar_settings_settings_button" msgid="3023889916699270224">"Nastavenia"</string>
     <string name="status_bar_settings_wifi_button" msgid="1733928151698311923">"Wi-Fi"</string>
-    <string name="status_bar_settings_airplane" msgid="4879879698500955300">"Režim V lietadle"</string>
+    <string name="status_bar_settings_airplane" msgid="4879879698500955300">"Režim v lietadle"</string>
     <string name="status_bar_settings_auto_rotation" msgid="3790482541357798421">"Automatické otočenie obrazovky"</string>
     <string name="status_bar_settings_mute_label" msgid="554682549917429396">"STLMIŤ"</string>
     <string name="status_bar_settings_auto_brightness_label" msgid="511453614962324674">"AUTO"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Späť"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Plocha"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Nedávne obrazovky"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Hľadať"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparát"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefón"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Odomknúť"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"odomknúť"</string>
+    <string name="phone_label" msgid="2320074140205331708">"otvoriť telefón"</string>
+    <string name="camera_label" msgid="7261107956054836961">"spustiť fotoaparát"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Tlačidlo prepnutia metódy vstupu."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Tlačidlo úpravy veľkosti z dôvodu kompatibility."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zväčšiť menší obrázok na väčšiu obrazovku."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Dve čiarky signálu siete Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tri čiarky signálu siete Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Plný signál siete Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Pripojené k zariadeniu <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Pripojené k zariadeniu <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Žiadna sieť WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Jeden stĺpec signálu siete WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Dva stĺpce signálu siete WiMAX."</string>
@@ -141,7 +145,7 @@
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"Wi-Fi"</string>
     <string name="accessibility_no_sim" msgid="8274017118472455155">"Žiadna karta SIM."</string>
     <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"Pripojenie cez Bluetooth."</string>
-    <string name="accessibility_airplane_mode" msgid="834748999790763092">"Režim V lietadle."</string>
+    <string name="accessibility_airplane_mode" msgid="834748999790763092">"Režim v lietadle."</string>
     <!-- String.format failed for translation -->
     <!-- no translation found for accessibility_battery_level (7451474187113371965) -->
     <skip />
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Rozhranie TeleTypewriter je povolené."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibračné zvonenie."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Tiché zvonenie."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Zrušiť aplikáciu <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Aplikácia <xliff:g id="APP">%s</xliff:g> bola zrušená."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Spúšťa sa aplikácia <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Upozornenie bolo zrušené."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Panel upozornení."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Rýchle nastavenia."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Uzamknutá obrazovka"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Nastavenia"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Nedávne obrazovky"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Používateľ: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Pripojenie Wi-Fi je vypnuté."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Pripojenie Wi-Fi je zapnuté."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batéria: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Režim V lietadle: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Poloha: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Režim v lietadle je vypnutý."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Režim v lietadle je zapnutý."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Režim v lietadle je vypnutý."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Režim v lietadle je zapnutý."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Rozhranie Bluetooth je vypnuté."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Rozhranie Bluetooth je zapnuté."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Rozhranie Bluetooth sa pripája."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Rozhranie Bluetooth je pripojené."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Rozhranie Bluetooth je vypnuté."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Rozhranie Bluetooth je zapnuté."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Nahlasovanie polohy je vypnuté."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Nahlasovanie polohy je zapnuté."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Nahlasovanie polohy je vypnuté."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Nahlasovanie polohy je zapnuté."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Budík nastavený na <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Zavrieť panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Dlhší čas"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Kratší čas"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Zavrieť panel"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Dlhší čas"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kratší čas"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Svietidlo je vypnuté."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Svietidlo je zapnuté."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Svietidlo je vypnuté."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Svietidlo je zapnuté."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Prevrátenie farieb je vypnuté."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Prevrátenie farieb je zapnuté."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilný hotspot je vypnutý."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilný hotspot je zapnutý."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Prenášanie bolo zastavené."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Jas displeja"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"dáta 2G–3G sú vypnuté"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"dáta 4G sú vypnuté"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobilné dáta sú vypnuté"</string>
@@ -187,14 +214,18 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Poloha nastavená pomocou GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Žiadosti o polohu sú aktívne"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Vymazať všetky upozornenia."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Nastavenia"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Nastavenia upozornení"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Nastavenia aplikácie <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Obrazovka sa automaticky otočí."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Obrazovka je uzamknutá v orientácii na šírku."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Obrazovka je uzamknutá v orientácii na výšku."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Obrazovka sa teraz bude otáčať automaticky."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Obrazovka je teraz uzamknutá v orientácii na šírku."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Obrazovka je teraz uzamknutá v orientácii na výšku."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Pult s dezertami"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Šetrič obrazovky"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
-    <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"Režim V lietadle"</string>
+    <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"Režim v lietadle"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"Nabíjanie, <xliff:g id="NUMBER">%d</xliff:g><xliff:g id="PERCENT">%%</xliff:g>"</string>
     <string name="quick_settings_battery_charged_label" msgid="8865413079414246081">"Nabité"</string>
     <string name="quick_settings_bluetooth_label" msgid="6304190285170721401">"Bluetooth"</string>
@@ -222,7 +253,7 @@
     <string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"Žiadna sieť"</string>
     <string name="quick_settings_wifi_off_label" msgid="7558778100843885864">"Sieť Wi-Fi je vypnutá"</string>
     <string name="quick_settings_wifi_detail_empty_text" msgid="2831702993995222755">"Nie sú k dispozícii žiadne uložené siete"</string>
-    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Vzdialená obrazovka"</string>
+    <string name="quick_settings_cast_title" msgid="1893629685050355115">"Prenos obrazovky"</string>
     <string name="quick_settings_casting" msgid="6601710681033353316">"Prenáša sa"</string>
     <string name="quick_settings_cast_device_default_name" msgid="5367253104742382945">"Nepomenované zariadenie"</string>
     <string name="quick_settings_cast_device_default_description" msgid="2484573682378634413">"Pripravené na prenášanie"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobilné dáta"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Využitie dát"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Zostávajúce údaje"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limit bol prekročený"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Bol dosiahnutý limit – využívanie údajov bolo pozastavené"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Využité: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Limit: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Upozornenie pri <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Vaše nedávne obrazovky sa zobrazia tu."</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Informácie o aplikácii"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"Uzamknutie v aplikácii"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"hľadať"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Vyhľadávanie"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Prejdite prstom nahor: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Prejdite prstom doľava: <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Žiadne prerušenia vrátane budíkov"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Žiadne prerušenia. Dokonca ani budíky"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Žiadne prerušenia"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Iba prioritné prerušenia"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Ďalší budík: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Váš budík o <xliff:g id="ALARM_TIME">%s</xliff:g> sa nespustí"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Menej naliehavé upozornenia sa nachádzajú nižšie"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Otvorte opätovným klepnutím"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Zariadenie odomknete prejdením prstom nahor"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefón otvoríte prejdením prstom doľava"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Fotoaparát otvoríte prejdením prstom doľava"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Natrvalo"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Žiadne"</string>
-    <string name="interruption_level_priority" msgid="6517366750688942030">"Priorita"</string>
+    <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritné"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Všetky"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Nabíja sa (úplné nabitie o <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Prepnutie používateľa"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Prepnúť používateľa (súčasný používateľ: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>)"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Zobraziť profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Pridať používateľa"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nový používateľ"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Hosť"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Pridať hosťa"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Odstrániť hosťa"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Chcete ukončiť reláciu hosťa?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Ukončením relácie hosťa sa odstránia mieste údaje."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Odstrániť hosťa?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Všetky aplikácie a údaje v tejto relácii budú odstránené."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Odstrániť"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Hosť, vitajte späť!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Na jednu minútu"</item>
-    <item quantity="other" msgid="6924190729213550991">"Na %d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Na jednu hodinu"</item>
-    <item quantity="other" msgid="5408537517529822157">"Na %d h"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Chcete v relácii pokračovať?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Začať odznova"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Áno, pokračovať"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Pridať nového používateľa?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Keď pridáte nového používateľa, musí si nastaviť vlastný priestor.\n\nAkýkoľvek používateľ môže aktualizovať aplikácie všetkých ostatných používateľov."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Šetrič batérie je zapnutý"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Obmedzí výkonnosť a prenos údajov na pozadí"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Vypnúť šetrič batérie"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Spustiť"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Žiadne upozornenia"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Zariadenie môže byť sledované"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil môže byť monitorovaný"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Sieť môže byť sledovaná"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Sledovanie zariadenia"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Monitorovanie profilu"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Sledovanie siete"</string>
-    <string name="open_app" msgid="4011771120339160755">"Otvoriť aplikáciu"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Deaktivovať VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Odpojiť sieť VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vaše zariadenie a aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok.\n\nĎalšie informácie získate od svojho správcu."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Aplikácii <xliff:g id="APPLICATION">%1$s</xliff:g> ste povolili nastaviť pripojenie VPN.\n\nTáto aplikácia môže sledovať vaše zariadenie a aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Ste pripojený/-á k sieti VPN (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nPoskytovateľ služby VPN môže sledovať vaše zariadenie a aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane e-mailov, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste aplikácii <xliff:g id="APPLICATION">%2$s</xliff:g> povolili nastaviť pripojenie VPN. Táto aplikácia môže tiež sledovať vašu aktivitu v sieti."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane e-mailov, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste pripojený/-á aj k sieti VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Poskytovateľ služby VPN môže tiež sledovať vašu aktivitu v sieti."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Tento profil spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vaše zariadenie a aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok.\n\nĎalšie informácie získate od svojho správcu."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizácia:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nSprávca môže sledovať vaše zariadenie a aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok.\n\nĎalšie informácie získate od svojho správcu."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Tento profil spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste aplikácii <xliff:g id="APPLICATION">%2$s</xliff:g> povolili možnosť nastaviť pripojenie VPN. Táto aplikácia tiež môže sledovať vašu aktivitu v sieti."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Tento profil spravuje organizácia:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste pripojený/-á k sieti VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Poskytovateľ služby VPN môže tiež sledovať vašu aktivitu v sieti."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizácia:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste aplikácii <xliff:g id="APPLICATION">%3$s</xliff:g> povolili možnosť nastaviť pripojenie VPN. Táto aplikácia tiež môže sledovať vašu aktivitu v sieti."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Toto zariadenie spravuje organizácia:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVáš profil spravuje organizácia:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nSprávca môže sledovať vašu aktivitu v sieti vrátane správ, aplikácií a zabezpečených webových stránok. Ďalšie informácie získate od svojho správcu.\n\nZároveň ste pripojený/-á k sieti VPN (<xliff:g id="APPLICATION">%3$s</xliff:g>). Poskytovateľ služby VPN môže tiež sledovať vašu aktivitu v sieti."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Zariadenie zostane uzamknuté, dokým ho ručne neodomknete."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Získavať upozornenia rýchlejšie"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Zobraziť pred odomknutím"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nie, vďaka"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Nastaviť"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Stlmené aplikáciou <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sl/strings.xml b/packages/SystemUI/res/values-sl/strings.xml
index 22fb1c6..e913e91 100644
--- a/packages/SystemUI/res/values-sl/strings.xml
+++ b/packages/SystemUI/res/values-sl/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Počisti"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Odstrani s seznama"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Podatki o programu"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Vaši nedavni zasloni so prikazani tu"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Zapre nedavne programe"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 nedavni program"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Nazaj"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Začetni zaslon"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Meni"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Nedavni zasloni"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Iskanje"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparat"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Odkleni"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"odkleni"</string>
+    <string name="phone_label" msgid="2320074140205331708">"odpri telefon"</string>
+    <string name="camera_label" msgid="7261107956054836961">"odpri fotoaparat"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Gumb za preklop načina vnosa."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Gumb povečave za združljivost."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Povečava manjšega na večji zaslon."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi z dvema črticama."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi s tremi črticami."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Poln signal Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Povezava vzpostavljena z: <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Povezava vzpostavljena z: <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ni signala WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Signal WiMAX: ena črtica."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Signal WiMAX: dve črtici."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter omogočen."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Zvonjenje z vibriranjem."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Zvonjenje izklopljeno."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Opusti aplikacijo <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Program <xliff:g id="APP">%s</xliff:g> je bil odstranjen."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Zaganjanje aplikacije <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Obvestilo je bilo odstranjeno."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Zaslon z obvestili."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Hitre nastavitve."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Zaklenjen zaslon"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Nastavitve"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Nedavni zasloni."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Uporabnik: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi je izklopljen."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi je vklopljen."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobilni telefon: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Baterija: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Letalski način: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokacija: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Način za letalo je izklopljen."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Način za letalo je vklopljen."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Način za letalo je izklopljen."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Način za letalo je vklopljen."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth je izklopljen."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth je vklopljen."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Povezava Bluetooth se vzpostavlja."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Povezava Bluetooth je vzpostavljena."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth je izklopljen."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth je vklopljen."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Poročanje o lokaciji je izklopljeno."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Poročanje o lokaciji je vklopljeno."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Poročanje o lokaciji je izklopljeno."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Poročanje o lokaciji je vklopljeno."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm je nastavljen na <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Zapri podokno"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Daljši čas"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Krajši čas"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Zapri podokno."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Daljši čas."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Krajši čas."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Svetilka je izklopljena."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Svetilka je vklopljena."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Svetilka je izklopljena."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Svetilka je vklopljena."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Inverzija barv je izklopljena."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Inverzija barv je vklopljena."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobilna dostopna točka je izklopljena."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobilna dostopna točka je vklopljena."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Predvajanje zaslona je ustavljeno."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Svetlost zaslona"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Prenos podatkov v omrežjih 2G/3G je izklopljen"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Prenos podatkov v omrežjih 4G je izklopljen"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Prenos podatkov v mobilnih omrežjih je izklopljen"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokacija nastavljena z GPS-om"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktivne zahteve za lokacijo"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Izbriši vsa obvestila."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Nastavitve"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Nastavitve obvestil"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Nastavitve aplikacije <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Zaslon se bo samodejno zasukal."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Zaslon je zaklenjen v ležeči usmerjenosti."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Zaslon je zaklenjen v pokončni usmerjenosti."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Zaslon se bo samodejno zasukal."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Zaslon je zaklenjen v ležeči usmerjenosti."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Zaslon je zaklenjen v pokončni usmerjenosti."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Vitrina za sladice"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Sanjarjenje"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Prenos podatkov v mobilnih omrežjih"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Poraba podatkov"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Preostala količina podatkov"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Omejitev prekoračena"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Dosežena je omejitev – prenos podatkov je začasno ustavljen"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Porabljeno: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Omejitev: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Opozorilo – <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Vaši nedavni zasloni so prikazani tu"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Podatki o aplikaciji"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"zakleni v aplikacijo"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"iskanje"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Iskanje"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Povlecite navzgor za <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Povlecite v levo za <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Brez prekinitev, vključno z alarmi"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Brez motenj. Celo brez alarmov."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Brez prekinitev"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Samo prednostne prekinitve"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Vaš naslednji alarm je ob <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Alarma ob <xliff:g id="ALARM_TIME">%s</xliff:g> ne boste slišali"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Manj nujna obvestila spodaj"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Dotaknite se znova, če želite odpreti"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Povlecite, da odklenete"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Povlecite v desno za telefon"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Povlecite v levo za fotoaparat"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Za nedoločen čas"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Nič"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prednost"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Vse"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Polnjenje (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> do napolnjenosti)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Preklop med uporabniki"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Preklop med uporabniki, trenutni uporabnik <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Prikaz profila"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Dodajanje uporabnika"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Nov uporabnik"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gost"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Dodajanje gosta"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Odstranitev gosta"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Želite končati sejo gosta?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Če končate sejo gosta, bodo lokalni podatki izbrisani."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Želite odstraniti gosta?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Vse aplikacije in podatki v tej seji bodo izbrisani."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Odstrani"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Znova pozdravljeni, gost!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Za eno minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Za %d min"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Za eno uro"</item>
-    <item quantity="other" msgid="5408537517529822157">"Za %d h"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Želite nadaljevati sejo?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Začni znova"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Da, nadaljuj"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Dodajanje novega uporabnika?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Ko dodate novega uporabnika, mora ta nastaviti svoj prostor.\n\nVsak uporabnik lahko posodobi aplikacije za vse druge uporabnike."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Varčevanje z energijo akumulatorja je vklopljeno"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Omeji zmogljivost delovanja in prenos podatkov v ozadju"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Izklop varčevanja z energijo akumulatorja"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Začni zdaj"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Ni obvestil"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Naprava je morda nadzorovana"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil je morda nadziran"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Omrežje je lahko nadzorovano"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Nadzor naprave"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Nadzor nad profilom"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Nadzor omrežja"</string>
-    <string name="open_app" msgid="4011771120339160755">"Odpri aplikacijo"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Onemogoči VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Prekini povezavo z VPN-jem"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"To napravo upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSkrbnik lahko nadzira vašo napravo in dejavnost v omrežju, vključno z e-pošto, aplikacijami in varnimi spletnimi mesti.\n\nČe želite več informacij, se obrnite na skrbnika."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Aplikaciji »<xliff:g id="APPLICATION">%1$s</xliff:g>« ste dovolili vzpostavitev povezave z omrežjem VPN.\n\nTa aplikacija lahko nadzira vašo napravo in dejavnost v omrežju, vključno z e-pošto, aplikacijami in varnimi spletnimi mesti."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Povezani ste v omrežje VPN (»<xliff:g id="APPLICATION">%1$s</xliff:g>«).\n\nPonudnik omrežja VPN lahko nadzira vašo napravo in dejavnost v omrežju, vključno z e-pošto, aplikacijami in varnimi spletnimi mesti."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"To napravo upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSkrbnik lahko nadzira vašo dejavnost v omrežju, vključno z e-pošto, aplikacijami in varnimi spletnimi mesti. Če želite več informacij, se obrnite na skrbnika.\n\nPoleg tega ste aplikaciji »<xliff:g id="APPLICATION">%2$s</xliff:g>« dovolili vzpostavitev povezave z omrežjem VPN. Vašo dejavnost v omrežju lahko nadzoruje tudi ta aplikacija."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"To napravo upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nSkrbnik lahko nadzira vašo dejavnost v omrežju, vključno z e-pošto, aplikacijami in varnimi spletnimi mesti. Če želite več informacij, se obrnite na skrbnika.\n\nPoleg tega ste povezani v omrežje VPN (»<xliff:g id="APPLICATION">%2$s</xliff:g>«). Vašo dejavnost v omrežju lahko nadzira tudi ponudnik omrežja VPN."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Ta profil upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo napravo in omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti.\n\nZa več informacij se obrnite na skrbnika."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"To napravo upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVaš profil upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo napravo in omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti.\n\nZa več informacij se obrnite na skrbnika."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Ta profil upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti. Za več informacij se obrnite na skrbnika.\n\nAplikaciji »<xliff:g id="APPLICATION">%2$s</xliff:g>« ste dovolili vzpostavitev povezave VPN. Tudi ta aplikacija lahko nadzira omrežno dejavnost."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Ta profil upravlja:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti. Za več informacij se obrnite na skrbnika.\n\nPovezani ste tudi v VPN (»<xliff:g id="APPLICATION">%2$s</xliff:g>«). Tudi ponudnik storitve VPN lahko nadzira omrežno dejavnost."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"To napravo upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVaš profil upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti. Za več informacij se obrnite na skrbnika.\n\n. Aplikaciji »<xliff:g id="APPLICATION">%3$s</xliff:g>« ste dovolili vzpostavitev povezave VPN. Tudi ta aplikacija lahko nadzira omrežno dejavnost."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"To napravo upravlja:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nVaš profil upravlja:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nVaš skrbnik lahko nadzira vašo omrežno dejavnost, vključno z e-poštnimi sporočili, aplikacijami in varnimi spletnimi mesti. Za več informacij se obrnite na skrbnika.\n\nPovezani ste tudi v VPN (»<xliff:g id="APPLICATION">%3$s</xliff:g>«). Tudi ponudnik storitve VPN lahko nadzira omrežno dejavnost."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Naprava bo ostala zaklenjena, dokler je ročno ne odklenete."</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Hitrejše prejemanje obvestil"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Oglejte si jih pred odklepanjem"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ne, hvala"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Nastavitev"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Izklop zvoka: <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sr/strings.xml b/packages/SystemUI/res/values-sr/strings.xml
index 0f305c5..9db6f9f 100644
--- a/packages/SystemUI/res/values-sr/strings.xml
+++ b/packages/SystemUI/res/values-sr/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Обриши"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Уклањање са листе"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Информације о апликацији"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Недавни екрани се појављују овде"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Одбаци недавне апликације"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 недавна апликација"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Назад"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Почетна"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Мени"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Недавни екрани"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Претражите"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Телефон"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Откључајте"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"откључај"</string>
+    <string name="phone_label" msgid="2320074140205331708">"отвори телефон"</string>
+    <string name="camera_label" msgid="7261107956054836961">"отвори камеру"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Дугме Промени метод уноса."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Дугме Зум компатибилности."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Зумирање са мањег на већи екран."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi сигнал од две црте."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi сигнал од три црте."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi сигнал је најјачи."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Повезани сте са <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Повезани сте са <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Нема WiMAX сигнала."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX сигнал има једну црту."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX сигнал има две црте."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter је омогућен."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Вибрација звона."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Нечујно звоно."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Одбаците <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Апликација <xliff:g id="APP">%s</xliff:g> је одбачена."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Покрећемо <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Обавештење је одбачено."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Прозор са обавештењима."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Брза подешавања."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Закључани екран."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Подешавања"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Недавни екрани."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Корисник: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi је искључен."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi је укључен."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобилна мрежа: <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Батерија: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Режим рада у авиону: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Локација је <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Режим рада у авиону је искључен."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Режим рада у авиону је укључен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Режим рада у авиону је искључен."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Режим рада у авиону је укључен."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth је искључен."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth је укључен."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth се повезује."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth је повезан."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth је искључен."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth је укључен."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Извештавање о локацији је искључено."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Извештавање о локацији је укључено."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Извештавање о локацији је искључено."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Извештавање о локацији је укључено."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Аларм је подешен за <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Затворите таблу"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Више времена"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Мање времена"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Затворите таблу."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Више времена."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Мање времена."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Батеријска лампа је искључена."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Батеријска лампа је укључена."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Батеријска лампа је искључена."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Батеријска лампа је укључена."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Инверзија боја је искључена."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Инверзија боја је укључена."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобилни хотспот је искључен."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобилни хотспот је укључен."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Пребацивање екрана је заустављено."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Осветљеност екрана"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G–3G подаци су искључени"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G подаци су искључени"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Мобилни пренос података је искључен"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Локацију је подесио GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Има активних захтева за локацију"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Обриши сва обавештења."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Подешавања"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Подешавања обавештења"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Подешавања за <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Екран ће се аутоматски ротирати."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Екран је закључан у хоризонталном положају."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Екран је закључан у вертикалном положају."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Екран ће се сада аутоматски ротирати."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Екран је сада закључан у вертикалном положају."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Екран је сада закључан у хоризонталном положају."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Витрина са посластицама"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Сањарење"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Етернет"</string>
@@ -232,7 +263,7 @@
     <string name="quick_settings_more_settings" msgid="326112621462813682">"Још подешавања"</string>
     <string name="quick_settings_done" msgid="3402999958839153376">"Готово"</string>
     <string name="quick_settings_connected" msgid="1722253542984847487">"Повезан"</string>
-    <string name="quick_settings_connecting" msgid="47623027419264404">"Повезивање..."</string>
+    <string name="quick_settings_connecting" msgid="47623027419264404">"Повезује се..."</string>
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"Повезивање"</string>
     <string name="quick_settings_hotspot_label" msgid="6046917934974004879">"Хотспот"</string>
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"Обавештења"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Подаци за мобилне уређаје"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Потрошња података"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Преостала количина података"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Преко ограничења"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Достигнуто је ограничење – коришћење података је паузирано"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Искористили сте <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Ограничење од <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Упозорење за <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Недавни екрани се појављују овде"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Информације о апликацији"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"закључај апликацију"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"претражи"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Претрага"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Превуците нагоре за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Превуците улево за <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Без прекида, укључујући аларме"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Нема прекида. Чак ни аларма."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Без прекида"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Само приоритетни прекиди"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Следећи аларм је у <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Нећете чути аларм у <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Мање хитна обавештења су у наставку"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Додирните поново да бисте отворили"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Превуците нагоре да бисте откључали"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Превуците удесно за телефон"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Превуците улево за камеру"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Бесконачно"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ниједан"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Приоритет"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Све"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Пуњење (пун је за <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Замени корисника"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Промените корисника, актуелни корисник је <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Прикажи профил"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Додај корисника"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Нови корисник"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Гост"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Додај госта"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Уклони госта"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Желите ли да изађете из сесије госта?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Изласком из сесије госта уклонићете локалне податке."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Желите ли да уклоните госта?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Све апликације и подаци у овој сесији ће бити избрисани."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Уклони"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Добро дошли назад, госте!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Један минут"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d мин"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Један сат"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d с"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Желите ли да наставите сесију?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Почни из почетка"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Да, настави"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Додајете новог корисника?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Када додате новог корисника, та особа треба да подеси сопствени простор.\n\nСваки корисник може да ажурира апликације за све остале кориснике."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Штедња батерије је укључена"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Смањује перформансе и позадинске податке"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Искључи штедњу батерије"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Започни одмах"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Нема обавештења"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Уређај се можда надгледа"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профил се можда надгледа"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Мрежа се можда надгледа"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Надгледање уређаја"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Надгледање профила"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Надгледање мреже"</string>
-    <string name="open_app" msgid="4011771120339160755">"Отвори апликацију"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Онемогући VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Прекини везу са VPN-ом"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа уређај и мрежне активности, укључујући имејлове, апликације и безбедне веб-сајтове.\n\nВише информација потражите од администратора."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Дали сте дозволу апликацији „<xliff:g id="APPLICATION">%1$s</xliff:g>“ да подешава VPN везу.\n\nТа апликација може да надгледа уређај и мрежне активности, укључујући имејлове, апликације и безбедне веб-сајтове."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Повезани сте са VPN-ом („<xliff:g id="APPLICATION">%1$s</xliff:g>“).\n\nДобављач VPN услуге може да надгледа уређај и мрежне активности, укључујући имејлове, апликације и безбедне веб-сајтове."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа мрежне активности, укључујући имејлове, апликације и безбедне веб-сајтове. Више информација потражите од администратора.\n\nДали сте и дозволу апликацији <xliff:g id="APPLICATION">%2$s</xliff:g> да подешава VPN везу. И та апликација може да надгледа мрежне активности."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа мрежне активности, укључујући имејлове, апликације и безбедне веб-сајтове. Више информација потражите од администратора.\n\nПовезани сте и са VPN-ом („<xliff:g id="APPLICATION">%2$s</xliff:g>“). И добављач VPN услуге може да надгледа мрежне активности."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Овим профилом управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа уређај и мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове.\n\nЗа више информација контактирајте администратора."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилом управља:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор може да надгледа уређај и мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове.\n\nЗа више информација контактирајте администратора."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Овим профилом управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове. За више информација контактирајте администратора.\n\nТакође сте дали дозволу да „<xliff:g id="APPLICATION">%2$s</xliff:g>“ подеси VPN везу. Ова апликација такође може да надгледа мрежну активност."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Овим профилом управља:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдминистратор може да надгледа мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове. За више информација контактирајте администратора.\n\nТакође, повезани сте на VPN („<xliff:g id="APPLICATION">%2$s</xliff:g>“). Добављач услуге за VPN такође може да надгледа мрежну активност."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилом управља:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор може да надгледа мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове. За више информација контактирајте администратора.\n\nТакође сте дали дозволу да „<xliff:g id="APPLICATION">%3$s</xliff:g>“ подеси VPN везу. Ова апликација такође може да надгледа мрежну активност."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Овим уређајем управља:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профилом управља:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдминистратор може да надгледа мрежну активност, укључујући имејлове, апликације и безбедне веб-сајтове. За више информација контактирајте администратора.\n\nТакође, повезани сте на VPN („<xliff:g id="APPLICATION">%3$s</xliff:g>“). Добављач услуге за VPN такође може да надгледа мрежну активност."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Уређај ће остати закључан док га не откључате ручно"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Брже добијајте обавештења"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Прегледајте их пре откључавања"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Не, хвала"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Подеси"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Звук је искључио/ла <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sv/config.xml b/packages/SystemUI/res/values-sv/config.xml
new file mode 100644
index 0000000..3b683a8
--- /dev/null
+++ b/packages/SystemUI/res/values-sv/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 sek,10 sek, 30 sek, 60 sek,120 sek"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-sv/strings.xml b/packages/SystemUI/res/values-sv/strings.xml
index bfa9fdc..1aebac0 100644
--- a/packages/SystemUI/res/values-sv/strings.xml
+++ b/packages/SystemUI/res/values-sv/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Ta bort"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Ta bort från listan"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Info om appen"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Dina senaste skärmar visas här"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Avvisa nya appar"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ny app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Tillbaka"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Startsida"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Meny"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Nya skärmar"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Sök"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Mobil"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Lås upp"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"lås upp"</string>
+    <string name="phone_label" msgid="2320074140205331708">"öppna mobilen"</string>
+    <string name="camera_label" msgid="7261107956054836961">"öppna kameran"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Knapp för byte av inmatningsmetod."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Knapp för kompatibilitetszoom."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Zooma mindre skärm till större."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi: två staplar."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi: tre staplar."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Full signalstyrka för Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Ansluten till <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Ansluten till <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ingen WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX: en stapel."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX: två staplar."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter aktiverad."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibrerande ringsignal."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Tyst ringsignal."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Ta bort <xliff:g id="APP">%s</xliff:g> från listan."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> togs bort permanent."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Startar <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Meddelandet ignorerades."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Meddelandepanel."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Snabbinställningar."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Låsskärm."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Inställningar"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Nya skärmar."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Användare <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi har inaktiverats."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi har aktiverats."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batteri <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Flygplansläge <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Plats <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Flygplansläge av."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Flygplansläge på."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Flygplansläget har inaktiverats."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Flygplansläget har aktiverats."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth av."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth på."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Ansluter Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth har anslutits."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth har inaktiverats."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth har aktiverats."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Platsrapportering av."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Platsrapportering på."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Platsrapporteringen har inaktiverats."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Platsrapporteringen har aktiverats."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarmet ringer <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Stäng panelen"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Längre tid"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Kortare tid"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Stäng panelen."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Längre tid."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kortare tid."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Ficklampa av."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Ficklampa på."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Ficklampan har inaktiverats."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Ficklampan har aktiverats."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Färginverteringen har inaktiverats."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Färginverteringen har aktiverats."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Den mobila trådlösa surfzonen har inaktiverats."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Den mobila trådlösa surfzonen har aktiverats."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Castningen av skärmen har stoppats."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Skärmens ljusstyrka"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-/3G-data har inaktiverats"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G-data har inaktiverats"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobildata har inaktiverats"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Platsen har identifierats av GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Det finns aktiva platsbegäranden"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Ta bort alla meddelanden."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Inställningar"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Aviseringsinställningar"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Inställningar för <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skärmen roteras automatiskt."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Bildskärmens riktning är nu låst i liggande format."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Bildskärmens riktning är nu låst i stående format."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skärmen roteras nu automatiskt."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Bildskärmens riktning är nu låst i liggande format."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Bildskärmens riktning är nu låst i stående format."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessertdisken"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Dagdröm"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobildata"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Dataanvändning"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Återstående data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Över gräns"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Datagränsen har uppnåtts – dataanvändningen har pausats"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> används"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Gräns: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Varning <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Dina senaste skärmar visas här"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Appinformation"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lås till app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"sök"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Sök"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Dra uppåt för <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Dra åt vänster för <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Inga avbrott, inklusive alarm"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Inga avbrott. Inte ens alarm."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Inga avbrott"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Endast prioriterade avbrott"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Nästa alarm är kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Alarmet kommer inte att höras kl. <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Mindre brådskande aviseringar nedan"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Tryck igen för att öppna"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Dra uppåt om du vill låsa upp"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Dra åt höger om du vill visa telefonen"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Dra åt vänster om du vill visa kameran"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"För alltid"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Ingen"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prioritet"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Alla"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Laddar (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> tills batteriet är fulladdat)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Byt användare"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Byt användare. Aktuell användare: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Visa profil"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Lägg till användare"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Ny användare"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Gäst"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Lägg till gäst"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Ta bort gäst"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Vill du avsluta gästsessionen?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Om du avslutar gästsessionen kommer lokala uppgifter att tas bort."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Vill du ta bort gästen?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Alla appar och data i denna session kommer att raderas."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Ta bort"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Välkommen tillbaka gäst!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"I en minut"</item>
-    <item quantity="other" msgid="6924190729213550991">"I %d minuter"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"I en timme"</item>
-    <item quantity="other" msgid="5408537517529822157">"I %d timmar"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Vill du fortsätta sessionen?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Börja om"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ja, fortsätt"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Lägga till ny användare?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"När du lägger till en ny användare måste den personen konfigurera sitt utrymme.\n\nAlla användare kan uppdatera appar för samtliga användares räkning."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Batterisparläget har aktiverats"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Minskar prestanda och bakgrundsdata"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Inaktivera batterisparläget"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Starta nu"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Inga aviseringar"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Enheten kan övervakas"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Det kan hända att profilen övervakas"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Nätverket kan vara övervakat"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Enhetsövervakning"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilövervakning"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Nätverksövervakning"</string>
-    <string name="open_app" msgid="4011771120339160755">"Öppna appen"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Inaktivera VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Koppla från VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Den här enheten administreras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratören kan övervaka enheten och din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser.\n\nKontakta administratören om du vill veta mer."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Du har gett <xliff:g id="APPLICATION">%1$s</xliff:g> tillåtelse att skapa en VPN-anslutning.\n\nAppen kan övervaka enheten och din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Du är ansluten till ett VPN (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nVPN-tjänsteleverantören kan övervaka enheten och din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Den här enheten administreras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administratör kan övervaka din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser. Kontakta din administratör för mer information.\n\nDu har också gett <xliff:g id="APPLICATION">%2$s</xliff:g> tillåtelse att skapa en VPN-anslutning. Även den här appen kan övervaka nätverksaktivitet."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Den här enheten administreras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administratör kan övervaka din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser. Kontakta din administratör för mer information.\n\nDu är även ansluten till VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Även din VPN-tjänsteleverantör kan övervaka nätverksaktiviteten."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Den här profilen hanteras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratören kan övervaka enheten och din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser.\n\nKontakta administratören för mer information."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Den här enheten hanteras av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil hanteras av:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratören kan övervaka enheten och nätverksaktiviteten, inklusive e-post, appar och säkra webbplatser.\n\nKontakta administratören för mer information."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Den här profilen hanteras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administratör kan övervaka din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser. Kontakta din administratör för mer information.\n\nDu har också gett <xliff:g id="APPLICATION">%2$s</xliff:g> tillåtelse att konfigurera en VPN-anslutning. Även den här appen kan övervaka nätverksaktivitet."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Den här profilen hanteras av:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nDin administratör kan övervaka din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser. Kontakta din administratör för mer information.\n\nDu är även ansluten till VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Även din VPN-tjänsteleverantör kan övervaka nätverksaktiviteten."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Den här enheten hanteras av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil hanteras av:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratören kan övervaka din nätverksaktivitet, inklusive e-post, appar och säkra webbplatser. Kontakta administratören för mer information.\n\nDu har också gett <xliff:g id="APPLICATION">%3$s</xliff:g> tillåtelse att konfigurera en VPN-anslutning. Även den här appen kan övervaka nätverksaktivitet."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Den här enheten hanteras av:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nDin profil hanteras av:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratören kan övervaka din nätverksaktivitet, till exempel e-post, appar och säkra webbplatser. Kontakta administratören för mer information.\n\nDu är även ansluten till VPN (<xliff:g id="APPLICATION">%3$s</xliff:g>). Även din VPN-tjänsteleverantör kan övervaka nätverksaktiviteten."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Enheten förblir låst tills du låser upp den manuellt"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Få aviseringar snabbare"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Visa dem innan du låser upp"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Nej tack"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Konfig."</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> har stängt av ljudet"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sw/strings.xml b/packages/SystemUI/res/values-sw/strings.xml
index 32b1c28..5d03ad8 100644
--- a/packages/SystemUI/res/values-sw/strings.xml
+++ b/packages/SystemUI/res/values-sw/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Futa"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Ondoa kwenye orodha"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Taarifa za programu-matumizi"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Skrini zako za hivi majuzi huonekana hapa"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Ondosha programu za hivi karibuni"</string>
     <!-- String.format failed for translation -->
     <!-- no translation found for status_bar_accessibility_recent_apps:other (1040784359794890744) -->
@@ -79,11 +78,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Nyuma"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Nyumbani"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menyu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Skrini za hivi karibuni"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Tafuta"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Simu"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Fungua"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"fungua"</string>
+    <string name="phone_label" msgid="2320074140205331708">"fungua simu"</string>
+    <string name="camera_label" msgid="7261107956054836961">"fungua kamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Swichi kitufe cha mbinu ingizi."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Kichupo cha kukuza kwa utangamanifu"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Kuza kidogo kwa skrini kubwa."</string>
@@ -110,6 +112,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Vipima mtandao viwili vya Wifi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Vipima mtandao vitatu vya Wifi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Nguvu kamili ya mtandao wa Wifi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Imeunganishwa kwenye <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Imeunganishwa kwenye <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Hakuna WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Pau moja ya WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Pau mbili za WiMAX."</string>
@@ -149,28 +153,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Kichapishaji cha Tele kimewezeshwa."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Mtetemo wa mlio"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Mlio wa simu uko kimya."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Ondoa <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> imeondolewa."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Inaanzisha <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Arifa imetupwa."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Kivuli cha arifa."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Mipangilio ya haraka."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Skrini iliyofungwa."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Mipangilio"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Skrini za hivi karibuni."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Mtumiaji <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi imezimwa."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi imewashwa."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Simu <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Betri <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Hali ya Ndege <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Mahali <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Hali ya ndegeni imezimwa."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Hali ya ndegeni imewashwa."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Hali ya ndegeni imezimwa."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Hali ya ndegeni imewashwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth imezimwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth imewashwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth inaunganishwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth imeunganishwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth imezimwa."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth imewashwa."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Programu ya Kuonyesha mahali ulipo imezimwa."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Programu ya Kuonyesha mahali ulipo inawaka."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Programu ya Kuonyesha mahali ulipo imezimwa."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Programu ya Kuonyesha mahali ulipo imewashwa."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Kengele imewekwa <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Funga paneli ya maelezo"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Muda zaidi"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Muda kidogo"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Funga paneli."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Muda zaidi."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Muda kidogo"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Tochi imezimwa."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Tochi inawaka."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Tochi imezimwa."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Tochi imewashwa."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Ugeuzaji rangi umezimwa."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Ugeuzaji rangi umewashwa."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mtandao-hewa unaoweza kuhamishika umezimwa."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mtandao-hewa unaoweza kuhamishika umewashwa."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Utumaji wa skrini umesitishwa."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ung\'aavu wa skrini"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Data ya 2G-3G imezimwa"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Data ya 4G imezimwa"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Data ya simu ya mkononi imezimwa"</string>
@@ -183,10 +210,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Mahali pamewekwa na GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Maombi ya eneo yanatumika"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Futa arifa zote."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Mipangilio"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Mipangilio ya arifa"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Mipangilio ya <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Skrini itazunguka kiotomatiki."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Skrini imefungwa sasa katika uelekezo wa mandhari."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Skrini imefungwa katika uelekeo wa picha."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Skrini sasa itazunguka kiotomatiki."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Skrini sasa imefungwa katika mkao wa ulalo."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Skrini sasa imefungwa katika mkao wa wima."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Sanduku la Vitindamlo"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Hali Tulivu"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -228,7 +259,7 @@
     <string name="quick_settings_inversion_label" msgid="8790919884718619648">"Pindua rangi"</string>
     <string name="quick_settings_color_space_label" msgid="853443689745584770">"Hali ya kusahihisha rangi"</string>
     <string name="quick_settings_more_settings" msgid="326112621462813682">"Mipangilio zaidi"</string>
-    <string name="quick_settings_done" msgid="3402999958839153376">"Imemaliza"</string>
+    <string name="quick_settings_done" msgid="3402999958839153376">"Nimemaliza"</string>
     <string name="quick_settings_connected" msgid="1722253542984847487">"Imeunganishwa"</string>
     <string name="quick_settings_connecting" msgid="47623027419264404">"Inaunganisha..."</string>
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"Kusambaza mtandao"</string>
@@ -238,12 +269,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Data ya simu ya mkononi"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Matumizi ya data"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Data iliyosalia"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Imezidi kikomo"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Kikomo kimefikiwa – matumizi ya data yamesitishwa"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> imetumika"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"kikomo <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Onyo <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Skrini zako za hivi majuzi huonekana hapa"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Maelezo ya Programu"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lazimisha kutumia programu"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"tafuta"</string>
@@ -255,51 +285,39 @@
     <string name="description_target_search" msgid="3091587249776033139">"Tafuta"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Sogeza juu kwa <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Sogeza kushoto kwa <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> ."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Hakuna kukatizwa, hata kutoka kwenye kengele"</string>
-    <string name="zen_no_interruptions" msgid="7970973750143632592">"Hakuna katizo"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"Katizo za kipaumbele pekee"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Hakuna kukatizwa. Hata kama ni kengele."</string>
+    <string name="zen_no_interruptions" msgid="7970973750143632592">"Hakuna kukatizwa"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"Mambo yenye kipaumbele pekee yakatize"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Kengele yako inayofuata itakuwa saa <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"Kengele yako inayofuata itakuwa <xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Hutasikia kengele yako ifikapo <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>+"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Arifa zisizo za dharura sana ziko hapo chini"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Gusa tena ili ufungue"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Telezesha kidole ili ufungue"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telezesha kidole kulia ili ufikie simu"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Telezesha kidole kushoto ili ufikie kamera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Bila kikomo"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Hamna"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Kipaumbele"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Zote"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Inachaji (Imebakisha <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> ijae)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Badili mtumiaji"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Badili mtumiaji, mtumiaji wa sasa <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Onyesha wasifu"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Ongeza mtumiaji"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Mtumiaji mpya"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Aliyealikwa"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Ongeza aliyealikwa"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Ondoa aliyealikwa"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Je, ungependa kuondoa kipindi cha aliyealikwa?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Kuondoa kipindi cha aliyealikwa kutaondoa data yako."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Ungependa kumwondoa aliyealikwa?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Programu zote na data katika kipindi hiki zitafutwa."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Ondoa"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Karibu tena, mwalikwa!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Kwa dakika moja"</item>
-    <item quantity="other" msgid="6924190729213550991">"Kwa dakika %d"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Kwa saa moja"</item>
-    <item quantity="other" msgid="5408537517529822157">"Kwa saa %d"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Je, unataka kuendelea na kipindi chako?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Anza tena"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ndiyo, endelea"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Ungependa kuongeza mtumiaji?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Unapomwongeza mtumiaji mpya, mtu huyo anahitaji kusanidi nafasi yake.\n\nMtumiaji yoyote anaweza kusasisha programu kwa ajili ya watumiaji wengine wote."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Kiokoa betri kimewashwa"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Hupunguza utendaji na data ya chini chini"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Zima kiokoa betri"</string>
@@ -311,16 +329,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Anza sasa"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Hakuna arifa"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Huenda kifaa kinafuatiliwa"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Huenda wasifu ukafuatiliwa"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Huenda mtandao unafuatiliwa"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Ufuatiliaji wa kifaa"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Ufuatiliaji wasifu"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Ufuatiliaji wa mtandao"</string>
-    <string name="open_app" msgid="4011771120339160755">"Fungua programu"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Zima VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Ondoa VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Kifaa kinasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia shughuli ya kifaa na mtandao wako, ikiwa ni pamoja na barua pepe, programu na tovuti salama.\n\nKwa maelezo zaidi, wasiliana na msimamizi wako."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Umeruhusu \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" isanidi muunganisho wa VPN.\n\nProgramu hii inaweza kufuatilia shughuli za kifaa na mtandao wako, ikiwa ni pamoja na barua pepe, programu na tovuti salama."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Umeunganishwa kwenye VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nMtoa huduma wako wa VPN anaweza kufuatilia kifaa na shughuli za kifaa na mtandao wako, ikiwa ni pamoja na barua pepe, programu na tovuti salama."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi anaweza kufuatilia shughuli za mtandao wako ikiwa ni pamoja na barua pepe, programu na tovuti salama. Kwa maelezo zaidi, wasiliana na msimamizi wako.\n\nPia, umeruhusu \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" isanidi muunganisho wa VPN. Programu hii pia inaweza kufuatilia shughuli za mtandao wako."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi anaweza kufuatilia shughuli za mtandao wako ikiwa ni pamoja na barua pepe, programu na tovuti salama. Kwa maelezo zaidi, wasiliana na msimamizi wako.\n\nPia, umeunganishwa kwenye VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Mtoa huduma wako wa VPN pia anaweza kufuatilia shughuli za mtandao."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Wasifu huu unasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia kifaa chako na shughuli kwenye mtandao, ikiwa ni pamoja na barua pepe na tovuti salama.\n\nKwa maelezo zaidi, wasiliana na msimamizi wako."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nWasifu wako unasimamiwa na:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia kifaa chako na shughuli kwenye mtandao, ikiwa ni pamoja na barua pepe na tovuti salama.\n\nKwa maelezo zaidi, wasiliana na msimamizi wako."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Wasifu huu unasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia shughuli zako kwenye mtandao, ikiwa ni pamoja na barua pepe, programu na na tovuti salama. Kwa maelezo zaidi, wasiliana na msimamizi wako.\n\nPia, uliruhusu \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" isanidi muunganisho wa VPN. Programu hii pia inaweza kufuatilia shughuli kwenye mtandao."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia shughuli zako kwenye mtandao ikiwa ni pamoja na barua pepe, programu na tovuti salama. Kwa maelezo zaidi, wasiliana na msimamizi wako.\n\nPia, umeunganishwa kwenye VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Mtoa huduma wako wa VPN pia anaweza kufuatilia shughuli kwenye mtandao."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nWasifu wako unasimamiwa na:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia shughuli zako kwenye mtandao, ikiwa ni pamoja na barua pepe, programu na na tovuti salama\n\nPia, uliruhusu \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" isanidi muunganisho wa VPN. Programu hii pia inaweza kufuatilia shughuli kwenye mtandao."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Kifaa hiki kinasimamiwa na:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nWasifu wako unasimamiwa na:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nMsimamizi wako anaweza kufuatilia shughuli zako kwenye mtandao, ikiwa ni pamoja na barua pepe, programu na tovuti salama. Kwa maelezo zaidi, wasiliana na msimamizi wako.\n\nPia, umeunganishwa kwenye VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Mtoa huduma wako wa VPN pia anaweza kufuatilia shughuli kwenye mtandao."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Kifaa kitaendelea kuwa katika hali ya kufungwa hadi utakapokifungua mwenyewe"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Pata arifa kwa haraka"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Zitazame kabla hujafungua"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Hapana, asante"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Sanidi"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Sauti imezimwa na <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-sw600dp/config.xml b/packages/SystemUI/res/values-sw600dp/config.xml
index 4f6d209..83477c0 100644
--- a/packages/SystemUI/res/values-sw600dp/config.xml
+++ b/packages/SystemUI/res/values-sw600dp/config.xml
@@ -32,4 +32,9 @@
 
     <!-- Set to true to enable the user switcher on the keyguard. -->
     <bool name="config_keyguardUserSwitcher">true</bool>
+
+    <!-- Transposes the search bar layout in landscape. -->
+    <bool name="recents_has_transposed_search_bar">true</bool>
+    <!-- Transposes the nav bar in landscape (only used for purposes of layout). -->
+    <bool name="recents_has_transposed_nav_bar">false</bool>
 </resources>
diff --git a/packages/SystemUI/res/values-sw600dp/dimens.xml b/packages/SystemUI/res/values-sw600dp/dimens.xml
index 9901e44..d3b5580 100644
--- a/packages/SystemUI/res/values-sw600dp/dimens.xml
+++ b/packages/SystemUI/res/values-sw600dp/dimens.xml
@@ -46,6 +46,9 @@
     <!-- The side padding for the task stack as a percentage of the width. -->
     <item name="recents_stack_width_padding_percentage" format="float" type="dimen">0.075</item>
 
+    <!-- The height of the search bar space. -->
+    <dimen name="recents_search_bar_space_height">72dp</dimen>
+
     <!-- The fraction of the screen height where the clock on the Keyguard has its center. The
          max value is used when no notifications are displaying, and the min value is when the
          highest possible number of notifications are showing. -->
@@ -81,4 +84,7 @@
     <dimen name="edge_tap_area_width">80dp</dimen>
 
     <dimen name="keyguard_indication_margin_bottom">90dp</dimen>
+
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <dimen name="system_icons_keyguard_padding_end">2dp</dimen>
 </resources>
diff --git a/packages/SystemUI/res/values-sw600dp/styles.xml b/packages/SystemUI/res/values-sw600dp/styles.xml
index 9e5b1d6..156fa65 100644
--- a/packages/SystemUI/res/values-sw600dp/styles.xml
+++ b/packages/SystemUI/res/values-sw600dp/styles.xml
@@ -19,16 +19,6 @@
         <item name="android:layout_width">480dp</item>
     </style>
 
-    <style name="SearchPanelCard">
-        <item name="android:layout_width">550dp</item>
-        <item name="android:layout_height">@dimen/search_panel_card_height</item>
-        <item name="android:layout_gravity">center_horizontal|bottom</item>
-    </style>
-
-    <style name="SearchPanelLogo">
-        <item name="android:layout_gravity">top|center_horizontal</item>
-    </style>
-
     <style name="SearchPanelScrim">
         <item name="android:layout_width">match_parent</item>
         <item name="android:layout_height">@dimen/search_panel_scrim_height</item>
diff --git a/packages/SystemUI/res/values-sw720dp/config.xml b/packages/SystemUI/res/values-sw720dp/config.xml
index fbc0d1d..fbeadcd 100644
--- a/packages/SystemUI/res/values-sw720dp/config.xml
+++ b/packages/SystemUI/res/values-sw720dp/config.xml
@@ -40,7 +40,9 @@
          card. -->
     <integer name="keyguard_max_notification_count">5</integer>
 
-    <!-- Transposes the recents layout in landscape. -->
-    <bool name="recents_transpose_layout_with_orientation">false</bool>
+    <!-- Transposes the search bar layout in landscape. -->
+    <bool name="recents_has_transposed_search_bar">false</bool>
+    <!-- Transposes the nav bar in landscape (only used for purposes of layout). -->
+    <bool name="recents_has_transposed_nav_bar">false</bool>
 </resources>
 
diff --git a/packages/SystemUI/res/values-sw720dp/dimens.xml b/packages/SystemUI/res/values-sw720dp/dimens.xml
index 3cd5f67..dd158c2 100644
--- a/packages/SystemUI/res/values-sw720dp/dimens.xml
+++ b/packages/SystemUI/res/values-sw720dp/dimens.xml
@@ -58,6 +58,9 @@
     <!-- Size of fading edge for scrolling -->
     <dimen name="status_bar_recents_scroll_fading_edge_length">10dip</dimen>
 
+    <!-- The radius of the rounded corners on a task view. -->
+    <dimen name="recents_task_view_rounded_corners_radius">3dp</dimen>
+
     <!-- Where to place the app icon over the thumbnail -->
     <dimen name="status_bar_recents_app_icon_left_margin">0dp</dimen>
     <dimen name="status_bar_recents_app_icon_top_margin">8dp</dimen>
diff --git a/packages/SystemUI/res/values-ta-rIN/strings.xml b/packages/SystemUI/res/values-ta-rIN/strings.xml
index 6c47bdc7..0838e60 100644
--- a/packages/SystemUI/res/values-ta-rIN/strings.xml
+++ b/packages/SystemUI/res/values-ta-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"அழி"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"பட்டியலில் இருந்து அகற்று"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"பயன்பாட்டுத் தகவல்"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"சமீபத்திய திரைகள் இங்கு தோன்றும்"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"சமீபத்திய பயன்பாடுகளை நிராகரி"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 சமீபத்திய பயன்பாடு"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"பின்செல்"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"முகப்பு"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"மெனு"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"சமீபத்திய திரைகள்"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"தேடு"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"கேமரா"</string>
-    <string name="accessibility_phone_button" msgid="6738112589538563574">"மொபைல்"</string>
+    <string name="accessibility_phone_button" msgid="6738112589538563574">"ஃபோன்"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"திற"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"திற"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ஃபோனைத் திற"</string>
+    <string name="camera_label" msgid="7261107956054836961">"கேமராவைத் திற"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"உள்ளீட்டு முறையை மாற்றும் பொத்தான்."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"பொருந்துமாறு அளவை மாற்றும் பொத்தான்."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"சிறியதிலிருந்து பெரிய திரைக்கு அளவை மாற்றும்."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi இரண்டு கோடுகள்."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi மூன்று கோடுகள்."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi சிக்னல் முழுமையாக உள்ளது."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>க்கு இணைக்கப்பட்டது."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>க்கு இணைக்கப்பட்டது."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX இல்லை."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ஒரு கோடு."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX இரண்டு கோடுகள்."</string>
@@ -139,7 +143,7 @@
     <string name="accessibility_data_connection_roaming" msgid="5977362333466556094">"ரோமிங்"</string>
     <string name="accessibility_data_connection_edge" msgid="4477457051631979278">"Edge"</string>
     <string name="accessibility_data_connection_wifi" msgid="2324496756590645221">"வைஃபை"</string>
-    <string name="accessibility_no_sim" msgid="8274017118472455155">"SIM இல்லை."</string>
+    <string name="accessibility_no_sim" msgid="8274017118472455155">"சிம் இல்லை."</string>
     <string name="accessibility_bluetooth_tether" msgid="4102784498140271969">"புளூடூத் இணைப்பு முறை."</string>
     <string name="accessibility_airplane_mode" msgid="834748999790763092">"விமானப் பயன்முறை."</string>
     <string name="accessibility_battery_level" msgid="7451474187113371965">"பேட்டரி சக்தி <xliff:g id="NUMBER">%d</xliff:g> சதவிகிதம் உள்ளது."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter இயக்கப்பட்டது."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"ரிங்கர் அதிர்வு."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"ரிங்கர் நிசப்தம்."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> ஐ நிராகரி."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> விலக்கப்பட்டது."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> ஐத் தொடங்குகிறது."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"அறிவிப்பு நிராகரிக்கப்பட்டது."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"அறிவிப்பு விவரம்."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"உடனடி அமைப்பு."</string>
-    <string name="accessibility_desc_settings" msgid="3417884241751434521">"அமைப்புகள்"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"பூட்டுத் திரை."</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"அமைப்பு"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"சமீபத்திய திரைகள்."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"பயனர் <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"வைஃபை முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"வைஃபை இயக்கப்பட்டது."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"மொபைல் <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"பேட்டரி <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"விமானப் பயன்முறை <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"புளூடூத் <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"இருப்பிடம் <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"விமானப் பயன்முறை முடக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"விமானப் பயன்முறை இயக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"விமானப் பயன்முறை முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"விமானப் பயன்முறை இயக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"புளூடூத் முடக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"புளூடூத் இயக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"புளூடூத் இணைக்கப்படுகிறது."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"புளூடூத் இணைக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"புளூடூத் முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"புளூடூத் இயக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"இருப்பிட அறிக்கையிடல் முடக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"இருப்பிட அறிக்கையிடல் இயக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"இருப்பிட அறிக்கையிடல் முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"இருப்பிட அறிக்கையிடல் இயக்கப்பட்டது."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g> மணிக்கு அலாரம் அமைக்கப்பட்டது."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"பேனலை மூடு"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"நேரத்தை அதிகரி"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"நேரத்தைக் குறை"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"பேனலை மூடு."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"நேரத்தை அதிகரி."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"நேரத்தைக் குறை."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ஃபிளாஷ்லைட் முடக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ஃபிளாஷ்லைட் இயக்கத்தில்."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ஃபிளாஷ்லைட் முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ஃபிளாஷ்லைட் இயக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"வண்ண நேர்மாறு முறை முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"வண்ண நேர்மாறு முறை இயக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"மொபைல் ஹாட்ஸ்பாட் முடக்கப்பட்டது."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"மொபைல் ஹாட்ஸ்பாட் இயக்கப்பட்டது."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"திரையை அனுப்புதல் நிறுத்தப்பட்டது."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"திரை பிரகாசம்"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G தரவு முடக்கப்பட்டது"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G தரவு முடக்கப்பட்டது"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"செல்லுலார் தரவு முடக்கப்பட்டது"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS அமைத்த இருப்பிடம்"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"இருப்பிடக் கோரிக்கைகள் இயக்கப்பட்டன"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"எல்லா அறிவிப்புகளையும் அழி."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"அமைப்புகள்"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"அறிவிப்பு அமைப்புகள்"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> அமைப்புகள்"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"திரை தானாகச் சுழலும்."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"நிலத்தோற்ற திசையமைப்பில் திரைப் பூட்டப்பட்டுள்ளது."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"உருவப்பட திசையமைப்பில் திசை பூட்டப்பட்டுள்ளது."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"இப்போது திரை தானாகச் சுழலும்."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"தற்போது திரை அகலவாக்குத் திசையமைப்பில் பூட்டப்பட்டுள்ளது."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"தற்போது திரை நீளவாக்குத் திசையமைப்பில் பூட்டப்பட்டுள்ளது."</string>
     <string name="dessert_case" msgid="1295161776223959221">"இனிப்பு வடிவங்கள்"</string>
     <string name="start_dreams" msgid="7219575858348719790">"முழுநேர இயக்கம்"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ஈதர்நெட்"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"செல்லுலார் தரவு"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"தரவுப் பயன்பாடு"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"மீதமுள்ள தரவு"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"வரம்பைக் கடந்தது"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"வரம்பை அடைந்தது – தரவுப் பயன்பாடு இடைநிறுத்தப்பட்டது"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"பயன்படுத்தியது - <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> வரம்பு"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> எச்சரிக்கை"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"சமீபத்திய திரைகள் இங்கு தோன்றும்"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"பயன்பாட்டு தகவல்"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"லாக்-டு-ஆப்"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"தேடு"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"தேடு"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> க்கு மேலாக இழுக்கவும்."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> க்கு இடதுபக்கமாக இழுக்கவும்."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"அலாரம் உட்பட குறுக்கீடுகள் வேண்டாம்"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"குறுக்கீடுகளும் இல்லை. அலாரங்களும் இல்லை."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"குறுக்கீடுகள் இல்லை"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"முதன்மையான குறுக்கீடுகள் மட்டும்"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"அடுத்த அலாரம் - <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> க்கு அலாரத்தைக் கேட்க மாட்டீர்கள்"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"அவசர நிலைக் குறைவான அறிவிப்புகள் கீழே உள்ளன"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"திறக்க, மீண்டும் தட்டவும்"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"திறக்க, மேலே ஸ்வைப் செய்யவும்"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ஃபோனுக்கு, வலப்புறம் ஸ்வைப் செய்க"</string>
     <string name="camera_hint" msgid="5241441720959174226">"கேமராவிற்கு இடப்புறம் ஸ்வைப் செய்க"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"வரையறையற்றது"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ஏதுமில்லை"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"முன்னுரிமை"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"எல்லாம்"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"சார்ஜாகிறது (முழு சார்ஜிற்கு <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> ஆகும்)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"பயனரை மாற்று"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"பயனரை மாற்று, தற்போதைய பயனர் <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"சுயவிவரத்தைக் காட்டு"</string>
     <string name="user_add_user" msgid="5110251524486079492">"பயனரைச் சேர்"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"புதியவர்"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"அழைக்கப்பட்டவர்"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"அழைக்கப்பட்டவரைச் சேர்"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"அழைக்கப்பட்டவரை அகற்று"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"விருந்தினர் அமர்விலிருந்து வெளியேறவா?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"விருந்தினர் அமர்விலிருந்து வெளியேறுவது அகத் தரவை அகற்றும்."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"அழைக்கப்பட்டவரை அகற்றவா?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"இந்த அமர்வின் எல்லா பயன்பாடுகளும், தரவும் நீக்கப்படும்."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"அகற்று"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"வரவேற்கிறோம்!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ஒரு நிமிடம்"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d நிமிடங்கள்"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ஒரு மணி நேரம்"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d மணிநேரம்"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"உங்கள் அமர்வைத் தொடர விருப்பமா?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"மீண்டும் தொடங்கு"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"தொடரவும்"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"புதியவரைச் சேர்க்கவா?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"புதிய பயனரைச் சேர்க்கும்போது, அவர் தனக்கான இடத்தை அமைக்க வேண்டும்.\n\nஎந்தவொரு பயனரும், மற்ற எல்லா பயனர்களுக்காகவும் பயன்பாடுகளைப் புதுப்பிக்கலாம்."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"பேட்டரி சேமிப்பான் இயக்கத்தில் உள்ளது"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"செயல்திறனையும் பின்புலத் தரவையும் குறைக்கிறது"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"பேட்டரி சேமிப்பானை முடக்கு"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"இப்போது தொடங்கு"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"அறிவிப்புகள் இல்லை"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"சாதனம் கண்காணிக்கப்படலாம்"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"சுயவிவரம் கண்காணிக்கப்படலாம்"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"நெட்வொர்க் கண்காணிக்கப்படலாம்"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"சாதனத்தைக் கண்காணித்தல்"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"சுயவிவரத்தைக் கண்காணித்தல்"</string>
     <string name="monitoring_title" msgid="169206259253048106">"நெட்வொர்க்கைக் கண்காணித்தல்"</string>
-    <string name="open_app" msgid="4011771120339160755">"பயன்பாட்டைத் திற"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPNஐ முடக்கு"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPNஐத் துண்டி"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"சாதனத்தை நிர்வகிப்பது:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பான இணையதளங்கள் உள்ளிட்ட சாதனம் மற்றும் நெட்வொர்க் செயல்பாட்டை உங்கள் நிர்வாகியால் கண்காணிக்க முடியும்.\n\nமேலும் தகவலுக்கு உங்கள் நிர்வாகியைத் தொடர்புகொள்ளவும்."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"VPN இணைப்பை அமைக்க \"<xliff:g id="APPLICATION">%1$s</xliff:g>\"க்கு அனுமதி வழங்கியுள்ளீர்கள்.\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பான இணையதளங்கள் உள்ளிட்ட சாதனம் மற்றும் நெட்வொர்க் செயல்பாட்டை இந்தப் பயன்பாட்டினால் கண்காணிக்க முடியும்."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") உடன் இணைக்கப்பட்டீர்கள்.\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பான இணையதளங்கள் உள்ளிட்ட சாதனம் மற்றும் நெட்வொர்க் செயல்பாட்டை உங்கள் VPN சேவை வழங்குநரால் கண்காணிக்க முடியும்."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"சாதனத்தை நிர்வகிப்பது:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பான இணையதளங்கள் உட்பட நெட்வொர்க் செயல்பாட்டை உங்கள் நிர்வாகியால் கண்காணிக்க முடியும். மேலும் தகவலுக்கு உங்கள் நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும் VPN இணைப்பை அமைக்க, \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"க்கு அனுமதி வழங்கியுள்ளீர்கள். இந்தப் பயன்பாட்டினால் நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"சாதனத்தை நிர்வகிப்பது:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பான இணையதளங்கள் உட்பட நெட்வொர்க் செயல்பாட்டை உங்கள் நிர்வாகியால் கண்காணிக்க முடியும். மேலும் தகவலுக்கு உங்கள் நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும் (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") உடன் இணைக்கப்பட்டீர்கள். VPN சேவை வழங்குநரும் நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"உங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் உங்கள் நிர்வாகியால் கண்காணிக்க முடியும்.\n\nமேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"சாதனத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nஉங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் உங்கள் நிர்வாகியால் கண்காணிக்க முடியும்.\n\nமேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"உங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் கண்காணிக்கும் திறன் உங்கள் நிர்வாகியிடம் உள்ளது. மேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும் VPN இணைப்பிற்காக \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" அனுமதியைக் கொடுத்துள்ளீர்கள். இந்தப் பயன்பாட்டால் நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"உங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் கண்காணிக்கும் திறன் உங்கள் நிர்வாகியிடம் உள்ளது. மேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும், VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") இல் இணைக்கப்பட்டுள்ளீர்கள். உங்கள் VPN சேவை வழங்குநராலும், நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"சாதனத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nஉங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் கண்காணிக்கும் திறன் உங்கள் நிர்வாகியிடம் உள்ளது. மேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும் VPN இணைப்பிற்காக \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" அனுமதியைக் கொடுத்துள்ளீர்கள். இந்தப் பயன்பாட்டால் நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"சாதனத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nஉங்கள் சுயவிவரத்தை நிர்வகிப்பவர்:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nமின்னஞ்சல்கள், பயன்பாடுகள் மற்றும் பாதுகாப்பு இணையதளங்கள் உட்பட உங்கள் சாதனத்தையும், நெட்வொர்க் செயல்பாட்டையும் கண்காணிக்கும் திறன் உங்கள் நிர்வாகியிடம் உள்ளது. மேலும் தகவலுக்கு, நிர்வாகியைத் தொடர்புகொள்ளவும்.\n\nமேலும், VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") இல் இணைக்கப்பட்டுள்ளீர்கள். உங்கள் VPN சேவை வழங்குநராலும், நெட்வொர்க் செயல்பாட்டைக் கண்காணிக்க முடியும்."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"நீங்கள் கைமுறையாகத் திறக்கும் வரை, சாதனம் பூட்டப்பட்டிருக்கும்"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"விரைவாக அறிவிப்புகளைப் பெறுதல்"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"திறக்கும் முன் அவற்றைப் பார்க்கவும்"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"வேண்டாம்"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"அமை"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> ஒலியடக்கினார்"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-te-rIN/config.xml b/packages/SystemUI/res/values-te-rIN/config.xml
new file mode 100644
index 0000000..7a4c0cb
--- /dev/null
+++ b/packages/SystemUI/res/values-te-rIN/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1సె,10సె,30సె,60సె,120సె"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-te-rIN/strings.xml b/packages/SystemUI/res/values-te-rIN/strings.xml
index 42fc147..302e5ac 100644
--- a/packages/SystemUI/res/values-te-rIN/strings.xml
+++ b/packages/SystemUI/res/values-te-rIN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"క్లియర్ చేయండి"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"జాబితా నుండి తీసివేయండి"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"అనువర్తన సమాచారం"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"మీ ఇటీవలి స్క్రీన్‌లు ఇక్కడ కనిపిస్తాయి"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"ఇటీవలి అనువర్తనాలను తీసివేయండి"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ఇటీవలి అనువర్తనం"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"వెనుకకు"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"హోమ్"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"మెను"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"ఇటీవలి స్క్రీన్‌లు"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"శోధించు"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"కెమెరా"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"ఫోన్"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"అన్‌లాక్ చేయి"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"అన్‌లాక్ చేయి"</string>
+    <string name="phone_label" msgid="2320074140205331708">"ఫోన్‌ను తెరువు"</string>
+    <string name="camera_label" msgid="7261107956054836961">"కెమెరాను తెరువు"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ఇన్‌పుట్ పద్ధతి మార్చే బటన్."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"అనుకూలత జూమ్ బటన్."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"చిన్న స్క్రీన్ నుండి పెద్దదానికి జూమ్ చేయండి."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wifi రెండు బార్‌లు కలిగి ఉంది."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wifi మూడు బార్‌లు కలిగి ఉంది."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wifi సిగ్నల్ పూర్తిగా ఉంది."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g>కి కనెక్ట్ చేయబడింది."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g>కి కనెక్ట్ చేయబడింది."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX లేదు."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX ఒక బార్ కలిగి ఉంది."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX రెండు బార్‌లు కలిగి ఉంది."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"టెలిటైప్‌రైటర్ ప్రారంభించబడింది."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"రింగర్ వైబ్రేట్‌లో ఉంది."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"రింగర్ నిశ్శబ్దంలో ఉంది."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g>ని తీసివేయండి."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> తీసివేయబడింది."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g>ని ప్రారంభిస్తోంది."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"నోటిఫికేషన్ తీసివేయబడింది."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"నోటిఫికేషన్ షేడ్."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"శీఘ్ర సెట్టింగ్‌లు."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"లాక్ స్క్రీన్."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"సెట్టింగ్‌లు"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"ఇటీవలి స్క్రీన్‌లు."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"వినియోగదారు <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wifi ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wifi ఆన్ చేయబడింది."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"మొబైల్ <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"బ్యాటరీ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"ఎయిర్‌ప్లేన్ మోడ్ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"బ్లూటూత్ <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"స్థానం <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"ఎయిర్‌ప్లైన్ మోడ్ ఆఫ్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"ఎయిర్‌ప్లైన్ మోడ్ ఆన్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"ఎయిర్‌ప్లైన్ మోడ్ ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"ఎయిర్‌ప్లైన్ మోడ్ ఆన్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"బ్లూటూత్ ఆఫ్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"బ్లూటూత్ ఆన్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"బ్లూటూత్ కనెక్ట్ అవుతోంది."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"బ్లూటూత్ కనెక్ట్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"బ్లూటూత్ ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"బ్లూటూత్ ఆన్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"స్థాన నివేదన ఆఫ్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"స్థాన నివేదన ఆన్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"స్థాన నివేదన ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"స్థాన నివేదన ఆన్ చేయబడింది."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"<xliff:g id="TIME">%s</xliff:g>కి అలారం సెట్ చేయబడింది."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"ప్యానెల్‌ని మూసివేయి"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"ఎక్కువ సమయం"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"తక్కువ సమయం"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ప్యానెల్‌ను మూసివేయి."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"ఎక్కువ సమయం."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"తక్కువ సమయం."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ఫ్లాష్‌లైట్ ఆఫ్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ఫ్లాష్‌లైట్ ఆన్‌లో ఉంది."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ఫ్లాష్‌లైట్ ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"ఫ్లాష్‌లైట్ ఆన్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"రంగు విలోమం ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"రంగు విలోమం ఆన్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"మొబైల్ హాట్‌స్పాట్ ఆఫ్ చేయబడింది."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"మొబైల్ హాట్‌స్పాట్ ఆన్ చేయబడింది."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"స్క్రీన్ ప్రసారం ఆపివేయబడింది."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ప్రదర్శన ప్రకాశం"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G డేటా ఆఫ్‌లో ఉంది"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G డేటా ఆఫ్‌లో ఉంది"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"సెల్యూలార్ డేటా ఆఫ్‌లో ఉంది"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"స్థానం GPS ద్వారా సెట్ చేయబడింది"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"స్థాన అభ్యర్థనలు సక్రియంగా ఉన్నాయి"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"అన్ని నోటిఫికేషన్‌లను క్లియర్ చేయండి."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"సెట్టింగ్‌లు"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"నోటిఫికేషన్ సెట్టింగ్‌లు"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> సెట్టింగ్‌లు"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"స్క్రీన్ స్వయంచాలకంగా తిప్పబడుతుంది."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"స్క్రీన్ ల్యాండ్‌స్కేప్ దృగ్విన్యాసంలో లాక్ చేయబడుతుంది."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"స్క్రీన్ పోర్ట్రెయిట్ దృగ్విన్యాసంలో లాక్ చేయబడుతుంది."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"స్క్రీన్ ఇప్పుడు స్వయంచాలకంగా తిరుగుతుంది."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"స్క్రీన్ ఇప్పుడు ల్యాండ్‌స్కేప్ దృగ్విన్యాసంలో లాక్ చేయబడింది."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"స్క్రీన్ ఇప్పుడు పోర్ట్రెయిట్ దృగ్విన్యాసంలో లాక్ చేయబడింది."</string>
     <string name="dessert_case" msgid="1295161776223959221">"డెజర్ట్ కేస్"</string>
     <string name="start_dreams" msgid="7219575858348719790">"డేడ్రీమ్"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ఈథర్‌నెట్"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"సెల్యులార్ డేటా"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"డేటా వినియోగం"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"మిగిలిన డేటా"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"పరిమితి మించిపోయింది"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"పరిమితిని చేరుకుంది – డేటా వినియోగం పాజ్ చేయబడింది"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> వినియోగించబడింది"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> పరిమితి"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> హెచ్చరిక"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"మీ ఇటీవలి స్క్రీన్‌లు ఇక్కడ కనిపిస్తాయి"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"అనువర్తన సమాచారం"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"లాక్ టు యాప్"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"శోధించు"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"శోధించండి"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> కోసం పైకి స్లైడ్ చేయండి."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> కోసం ఎడమవైపుకు స్లైడ్ చేయండి."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"అలారాలతో సహా ఎటువంటి అంతరాయాలు ఉండవు"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"అంతరాయాలు లేవు. అలారాలు కూడా లేవు."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"అంతరాయాలు లేకుండా"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"ప్రాధాన్య అంతరాయాలు మాత్రమే"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"మీ తదుపరి అలారం <xliff:g id="ALARM_TIME">%s</xliff:g>కి ఉంది"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"మీరు <xliff:g id="ALARM_TIME">%s</xliff:g>కి సెట్ చేసిన అలారం మీకు వినిపించదు"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"తక్కువ అత్యవసర నోటిఫికేషన్‌లు దిగువన"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"తెరవడానికి మళ్లీ తాకండి"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"అన్‌లాక్ చేయడానికి ఎగువకు స్వైప్ చేయండి"</string>
     <string name="phone_hint" msgid="3101468054914424646">"ఫోన్ కోసం కుడివైపుకి స్వైప్ చేయండి"</string>
     <string name="camera_hint" msgid="5241441720959174226">"కెమెరా కోసం ఎడమవైపుకి స్వైప్ చేయండి"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"నిరవధికంగా"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"వేటికీ వద్దు"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ప్రాధాన్యత"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"అన్నిటికీ"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"ఛార్జ్ అవుతోంది (పూర్తిగా నిండటానికి <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"వినియోగదారుని మార్చు"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"వినియోగదారుని మార్చు, ప్రస్తుత వినియోగదారు <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"ప్రొఫైల్‌ని చూపు"</string>
     <string name="user_add_user" msgid="5110251524486079492">"వినియోగదారుని జోడించండి"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"కొత్త వినియోగదారు"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"అతిథి"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"అతిథిని జోడించండి"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"అతిథిని తీసివేయండి"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"అతిథి సెషన్ నుండి నిష్క్రమిస్తున్నారా?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"అతిథి సెషన్ నుండి నిష్క్రమించడం వలన స్థానిక డేటా తీసివేయబడుతుంది."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"అతిథిని తీసివేయాలా?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ఈ సెషన్‌లోని అన్ని అనువర్తనాలు మరియు డేటా తొలగించబడతాయి."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"తీసివేయి"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"పునఃస్వాగతం, అతిథి!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ఒక నిమిషానికి"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d నిమిషాలకి"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ఒక గంటకు"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d గంటలకు"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"మీరు మీ సెషన్‌ని కొనసాగించాలనుకుంటున్నారా?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"మొదటి నుండి ప్రారంభించు"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"అవును, కొనసాగించు"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"కొత్త వినియోగదారుని జోడించాలా?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"మీరు కొత్త వినియోగదారుని జోడించినప్పుడు, ఆ వ్యక్తి తన స్థలాన్ని సెటప్ చేసుకోవాలి.\n\nఏ వినియోగదారు అయినా మిగతా అందరు వినియోగదారుల కోసం అనువర్తనాలను నవీకరించగలరు."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"బ్యాటర్ సేవర్ ఆన్ చేయబడింది"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"పనితీరుని మరియు నేపథ్య డేటాను తగ్గిస్తుంది"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"బ్యాటరీ సేవర్‌ను ఆఫ్ చేయి"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"ఇప్పుడే ప్రారంభించు"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"నోటిఫికేషన్‌లు లేవు"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"పరికరం పర్యవేక్షించబడవచ్చు"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"ప్రొఫైల్‌ని పర్యవేక్షించవచ్చు"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"నెట్‌వర్క్ పర్యవేక్షించబడవచ్చు"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"పరికర పర్యవేక్షణ"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"ప్రొఫైల్ పర్యవేక్షణ"</string>
     <string name="monitoring_title" msgid="169206259253048106">"నెట్‌వర్క్ పర్యవేక్షణ"</string>
-    <string name="open_app" msgid="4011771120339160755">"అనువర్తనాన్ని తెరువు"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPNని నిలిపివేయి"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPNను డిస్‌కనెక్ట్ చేయి"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"ఈ పరికరం దీని నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వాహకుడు ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ పరికరాన్ని మరియు నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు.\n\nమరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"మీరు VPN కనెక్షన్‌ను సెటప్ చేయడానికి \"<xliff:g id="APPLICATION">%1$s</xliff:g>\"కి అనుమతి ఇచ్చారు.\n\nఈ అనువర్తనం ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ పరికరాన్ని మరియు నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలదు."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"మీరు VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\")కి కనెక్ట్ చేయబడ్డారు.\n\nమీ VPN సేవా ప్రదాత ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ పరికరాన్ని మరియు నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"ఈ పరికరం దీని నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వాహకుడు ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు. మరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి.\n\nఅలాగే, మీరు VPN కనెక్షన్‌ను సెటప్ చేయడానికి \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"ని అనుమతించారు. కనుక ఈ అనువర్తనం కూడా నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలదు."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"ఈ పరికరం దీని నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వాహకుడు ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు. మరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి.\n\nఅలాగే, మీరు VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\")కి కనెక్ట్ చేయబడ్డారు. కనుక మీ VPN సేవా ప్రదాత కూడా నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"ఈ ప్రొఫైల్ వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వాహకుడు ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ పరికరం మరియు నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు.\n\nమరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"ఈ పరికరం వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nమీ ప్రొఫైల్ వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nమీ నిర్వాహకుడు ఇమెయిల్‌లు, అనువర్తనాలు మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ పరికరం మరియు నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు.\n\nమరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"ఈ ప్రొఫైల్ వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వాహ. ఇమెయి., అనువ. మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ నెట్‌వ. కార్యాచరణను పర్యవేక్షించగలరు. మరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి.\n\nఅలాగే, మీరు VPN కనెక్షన్‌ని సెటప్ చేయడానికి \"<xliff:g id="APPLICATION">%2$s</xliff:g>\"కి అనుమతి ఇచ్చారు. కాబట్టి, ఈ అనువ. కూడా నెట్‌. కార్యా. పర్యవేక్షించగలదు."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"ఈ ప్రొఫైల్ వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nమీ నిర్వా. ఇమెయి., అనువ. మరియు సురక్షిత వెబ్‌సైట్‌లతో సహా మీ నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు. మరింత సమాచారం కోసం, మీ నిర్వాహకుడిని సంప్రదించండి.\n\nఅలాగే, మీరు VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\")కి కనెక్ట్ చేయబడ్డారు. కాబట్టి, మీ VPN సేవ ప్రదాత కూడా నెట్‌వర్క్ కార్యాచరణను పర్యవేక్షించగలరు."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"ఈ పరి. వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nమీ ప్రొఫైల్ వీరి నిర్వ. ఉంది:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nమీ నిర్వాహ. ఇమెయి., అనువ. మరియు సురక్షిత వెబ్‌సై. సహా మీ నెట్‌. కార్యా. పర్యవేక్షించగలరు. మరింత సమా. కోసం, మీ నిర్వాహ. సంప్ర..\n\nఅలాగే, మీరు VPN కనెక్షన్ సెటప్ చేయడా. \"<xliff:g id="APPLICATION">%3$s</xliff:g>\"కి అనుమతి ఇచ్చారు. కాబట్టి, ఈ అనువ. కూడా నెట్‌వర్క్ కార్యా. పర్యవేక్షించగలదు."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"ఈ పరి. వీరి నిర్వహణలో ఉంది:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nమీ ప్రొఫైల్ వీరి నిర్వ. ఉంది:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nమీ నిర్వా. ఇమెయి., అనువ. మరియు సురక్షిత వెబ్‌‌సైట్‌లతో సహా మీ నెట్‌వ. కార్యా. పర్యవేక్షించగలరు. మరింత సమా. కోసం, మీ నిర్వాహ. సంప్రదించండి.\n\nఅలాగే, మీరు VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\")కి కనెక్ట్ చేయబ.. కాబట్టి, మీ VPN సేవ ప్రదాత కూడా నెట్‌వర్క్ కార్యా. పర్యవేక్షించగలరు."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"మీరు మాన్యువల్‌గా అన్‌లాక్ చేస్తే మినహా పరికరం లాక్ చేయబడి ఉంటుంది"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"నోటిఫికేషన్‌లను వేగంగా పొందండి"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"వీటిని మీరు అన్‌లాక్ చేయకముందే చూడండి"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"వద్దు, ధన్యవాదాలు"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"సెటప్ చేయి"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> ద్వారా మ్యూట్ చేయబడింది"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-th/strings.xml b/packages/SystemUI/res/values-th/strings.xml
index 61d8cef..09a8530 100644
--- a/packages/SystemUI/res/values-th/strings.xml
+++ b/packages/SystemUI/res/values-th/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"ล้างข้อมูล"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"ลบจากรายการ"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"ข้อมูลแอปพลิเคชัน"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"หน้าจอล่าสุดของคุณแสดงที่นี่"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"ปิดแอปพลิเคชันล่าสุด"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 แอปพลิเคชันล่าสุด"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"กลับ"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"หน้าแรก"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"เมนู"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"หน้าจอล่าสุด"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"ค้นหา"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"กล้องถ่ายรูป"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"โทรศัพท์"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"ปลดล็อก"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"ปลดล็อก"</string>
+    <string name="phone_label" msgid="2320074140205331708">"เปิดโทรศัพท์"</string>
+    <string name="camera_label" msgid="7261107956054836961">"เปิดกล้อง"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"ปุ่มสลับวิธีการป้อนข้อมูล"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"ปุ่มซูมที่ใช้งานร่วมกันได้"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"ซูมหน้าจอให้มีขนาดใหญ่ขึ้น"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"สัญญาณ WiFi สองขีด"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"สัญญาณ WiFi สามขีด"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"สัญญาณ WiFi เต็ม"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"เชื่อมต่อ <xliff:g id="WIFI">%s</xliff:g> แล้ว"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"เชื่อมต่อกับ <xliff:g id="BLUETOOTH">%s</xliff:g> แล้ว"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"ไม่มีสัญญาณ WiMAX"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"สัญญาณ WiMAX หนึ่งขีด"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"สัญญาณ WiMAX สองขีด"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"เปิดใช้งาน TeleTypewriter อยู่"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"เสียงเรียกเข้าแบบสั่น"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"เสียงเรียกเข้าแบบปิดเสียง"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"ยกเลิก <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ถูกลบไปแล้ว"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"กำลังเริ่มต้น <xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"ปิดการแจ้งเตือนแล้ว"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"หน้าต่างแจ้งเตือน"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"การตั้งค่าด่วน"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"ล็อกหน้าจอ"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"การตั้งค่า"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"หน้าจอล่าสุด"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"ผู้ใช้ <xliff:g id="USER">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g> <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"ปิด Wi-Fi แล้ว"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"เปิด Wi-Fi แล้ว"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"มือถือ <xliff:g id="SIGNAL">%1$s</xliff:g> <xliff:g id="TYPE">%2$s</xliff:g> <xliff:g id="NETWORK">%3$s</xliff:g>"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"แบตเตอรี่ <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"โหมดใช้บนเครื่องบิน <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"บลูทูธ <xliff:g id="STATE">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"สถานที่ <xliff:g id="STATE">%s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"โหมดบนเครื่องบินปิดอยู่"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"โหมดบนเครื่องบินเปิดอยู่"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"ปิดโหมดบนเครื่องบินแล้ว"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"เปิดโหมดบนเครื่องบินแล้ว"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"บลูทูธปิดอยู่"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"บลูทูธเปิดอยู่"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"กำลังเชื่อมต่อบลูทูธ"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"เชื่อมต่อบลูทูธแล้ว"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"ปิดบลูทูธแล้ว"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"เปิดบลูทูธแล้ว"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"การรายงานตำแหน่งปิดอยู่"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"การรายงานตำแหน่งเปิดอยู่"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"ปิดการรายงานตำแหน่งแล้ว"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"เปิดการรายงานตำแหน่งแล้ว"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"ตั้งเวลาปลุกไว้ที่ <xliff:g id="TIME">%s</xliff:g>"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"ปิดแผงควบคุม"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"เวลามากขึ้น"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"เวลาน้อยลง"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"ปิดแผงควบคุม"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"เวลามากขึ้น"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"เวลาน้อยลง"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"ไฟฉายปิดอยู่"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"ไฟฉายเปิดอยู่"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"ปิดไฟฉายแล้ว"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"เปิดไฟฉายแล้ว"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"ปิดการกลับสีแล้ว"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"เปิดการกลับสีแล้ว"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"ปิดฮอตสปอตเคลื่อนที่แล้ว"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"เปิดฮอตสปอตเคลื่อนที่แล้ว"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"หยุดการส่งหน้าจอแล้ว"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ความสว่างของหน้าจอ"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"ข้อมูล 2G-3G ปิดอยู่"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"ข้อมูล 4G ปิดอยู่"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"ข้อมูลมือถือปิดอยู่"</string>
@@ -185,12 +212,16 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"ตำแหน่งที่กำหนดโดย GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"คำขอตำแหน่งที่มีการใช้งาน"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"ล้างการแจ้งเตือนทั้งหมด"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"การตั้งค่า"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"การตั้งค่าการแจ้งเตือน"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"การตั้งค่า <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"หน้าจอจะหมุนโดยอัตโนมัติ"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"ขณะนี้หน้าจอถูกล็อกให้วางในแนวนอน"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"ขณะนี้หน้าจอถูกล็อกให้วางในแนวตั้ง"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"ขณะนี้หน้าจอจะหมุนโดยอัตโนมัติ"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"ขณะนี้หน้าจอล็อกอยู่ในแนวนอน"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"ขณะนี้หน้าจอล็อกอยู่ในแนวตั้ง"</string>
     <string name="dessert_case" msgid="1295161776223959221">"ชั้นแสดงของหวาน"</string>
-    <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
+    <string name="start_dreams" msgid="7219575858348719790">"เดย์ดรีม"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"อีเทอร์เน็ต"</string>
     <string name="quick_settings_airplane_mode_label" msgid="5510520633448831350">"โหมดใช้บนเครื่องบิน"</string>
     <string name="quick_settings_battery_charging_label" msgid="490074774465309209">"กำลังชาร์จ, <xliff:g id="NUMBER">%d</xliff:g><xliff:g id="PERCENT">%%</xliff:g>"</string>
@@ -202,7 +233,7 @@
     <string name="quick_settings_brightness_label" msgid="6968372297018755815">"ความสว่าง"</string>
     <string name="quick_settings_rotation_unlocked_label" msgid="7305323031808150099">"หมุนอัตโนมัติ"</string>
     <string name="quick_settings_rotation_locked_label" msgid="6359205706154282377">"ล็อกการหมุน"</string>
-    <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"บุคคล"</string>
+    <string name="quick_settings_rotation_locked_portrait_label" msgid="5102691921442135053">"แนวตั้ง"</string>
     <string name="quick_settings_rotation_locked_landscape_label" msgid="8553157770061178719">"แนวนอน"</string>
     <string name="quick_settings_ime_label" msgid="7073463064369468429">"วิธีป้อนข้อมูล"</string>
     <string name="quick_settings_location_label" msgid="5011327048748762257">"ตำแหน่ง"</string>
@@ -238,14 +269,13 @@
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"การแจ้งเตือน"</string>
     <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"ไฟฉาย"</string>
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"ข้อมูลมือถือ"</string>
-    <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"การใช้ข้อมูล"</string>
+    <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"การใช้อินเทอร์เน็ต"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"ข้อมูลที่เหลืออยู่"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"เกินขีดจำกัด"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"ถึงขีดจำกัดแล้ว – หยุดการใช้งานข้อมูลชั่วคราวแล้ว"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"ใช้ไปแล้ว <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"ขีดจำกัด <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"คำเตือน <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"หน้าจอล่าสุดของคุณแสดงที่นี่"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"ข้อมูลแอปพลิเคชัน"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"การล็อกแอป"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ค้นหา"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"ค้นหา"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"เลื่อนขึ้นเพื่อ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"เลื่อนไปทางซ้ายเพื่อ <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"ไม่มีการรบกวนรวมถึงเสียงปลุก"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"ไม่มีการรบกวน แม้แต่นาฬิกาปลุก"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"ไม่มีการรบกวน"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"เฉพาะเรื่องสำคัญเท่านั้น"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"การปลุกครั้งถัดไปของคุณคือเวลา <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,64 +295,64 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"คุณจะไม่ได้ยินเสียงปลุกในเวลา <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"การแจ้งเตือนที่เร่งด่วนน้อยด้านล่าง"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"แตะอีกครั้งเพื่อเปิด"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"กวาดขึ้นเพื่อปลดล็อก"</string>
     <string name="phone_hint" msgid="3101468054914424646">"กวาดไปทางขวาเพื่อใช้โทรศัพท์"</string>
     <string name="camera_hint" msgid="5241441720959174226">"กวาดไปทางซ้ายเพื่อใช้กล้องถ่ายรูป"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"ไม่มีกำหนด"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"ไม่มี"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"สำคัญ"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"ทั้งหมด"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"กำลังชาร์จ (อีก <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> เต็ม)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"สลับผู้ใช้"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"เปลี่ยนผู้ใช้จากผู้ใช้ปัจจุบัน <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"แสดงโปรไฟล์"</string>
     <string name="user_add_user" msgid="5110251524486079492">"เพิ่มผู้ใช้"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"ผู้ใช้ใหม่"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"ผู้เข้าร่วม"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"เพิ่มผู้เข้าร่วม"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"นำผู้เข้าร่วมออก"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"ต้องการออกจากเซสชันผู้เยี่ยมชมไหม"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"การออกจากเซสชันผู้เยี่ยมชมจะนำข้อมูลในเครื่องออก"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"ต้องการนำผู้เข้าร่วมออกไหม"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"ระบบจะลบแอปและข้อมูลทั้งหมดในเซสชันนี้"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"นำออก"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"ยินดีต้อนรับท่านผู้เยี่ยมชมกลับมาอีกครั้ง!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 นาที"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d นาที"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 ชั่วโมง"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d ชั่วโมง"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"คุณต้องการอยู่ในเซสชันต่อไปไหม"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"เริ่มต้นใหม่"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"ใช่ ดำเนินการต่อ"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"ต้องการเพิ่มผู้ใช้ใหม่ใช่ไหม"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"เมื่อคุณเพิ่มผู้ใช้ใหม่ ผู้ใช้ดังกล่าวจะต้องตั้งค่าพื้นที่ของตนเอง\n\nผู้ใช้ทุกคนสามารถอัปเดตแอปสำหรับผู้ใช้รายอื่นทุกคนได้"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"เปิดโหมดประหยัดแบตเตอรี่อยู่"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"ลดการใช้แบตเตอรี่และข้อมูลแบ็กกราวด์"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"ปิดโหมดประหยัดแบตเตอรี่"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
-    <string name="notification_hidden_text" msgid="1135169301897151909">"เนื้อหาที่ซ่อน"</string>
+    <string name="notification_hidden_text" msgid="1135169301897151909">"เนื้อหาถูกซ่อนไว้"</string>
     <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> จะเริ่มจับภาพทุกอย่างที่แสดงบนหน้าจอ"</string>
     <string name="media_projection_remember_text" msgid="3103510882172746752">"ไม่ต้องแสดงข้อความนี้อีก"</string>
     <string name="clear_all_notifications_text" msgid="814192889771462828">"ล้างทั้งหมด"</string>
     <string name="media_projection_action_text" msgid="8470872969457985954">"เริ่มเลย"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"ไม่มีการแจ้งเตือน"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"อาจมีการตรวจสอบอุปกรณ์"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"อาจมีการตรวจสอบโปรไฟล์"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"เครือข่ายอาจได้รับการตรวจสอบ"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"การตรวจสอบอุปกรณ์"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"การตรวจสอบโปรไฟล์"</string>
     <string name="monitoring_title" msgid="169206259253048106">"การตรวจสอบเครือข่าย"</string>
-    <string name="open_app" msgid="4011771120339160755">"เปิดแอป"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"ปิดใช้ VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"ยกเลิกการเชื่อมต่อ VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"อุปกรณ์นี้จัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่าย รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย\n\nสำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบ"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"คุณให้สิทธิ์ \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" ในการตั้งค่าการเชื่อมต่อ VPN\n\nแอปนี้สามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่าย รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"คุณเชื่อมต่อกับ VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") อยู่\n\nผู้ให้บริการ VPN สามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่าย รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัยได้"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"อุปกรณ์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบของคุณสามารถตรวจสอบกิจกรรมในเครือข่ายของคุณได้ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบของคุณ\n\nนอกจากนี้ คุณได้ให้สิทธิ์ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" เพื่อตั้งค่าการเชื่อมต่อ VPN แอปนี้สามารถตรวจสอบกิจกรรมในเครือข่ายได้เช่นกัน"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"อุปกรณ์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบของคุณสามารถตรวจสอบกิจกรรมในเครือข่ายของคุณได้ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบของคุณ\n\nนอกจากนี้ คุณเชื่อมต่อกับ VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") ผู้ให้บริการ VPN ของคุณสามารถตรวจสอบกิจกรรมในเครือข่ายของคุณได้เช่นกัน"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"โปรไฟล์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่ายของคุณ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย\n\nสำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบ"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"อุปกรณ์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nโปรไฟล์ของคุณได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nผู้ดูแลระบบของคุณสามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่าย รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย\n\nสำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบ"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"โปร์ไฟล์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบกิจกรรมเครือข่ายของคุณได้ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบของคุณ\n\nนอกจากนี้ คุณได้ให้สิทธิ์ \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" ในการตั้งค่าการเชื่อมต่อ VPN แอปนี้สามารถตรวจสอบกิจกรรมเครือข่ายได้เช่นกัน"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"โปรไฟล์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบกิจกรรมเครือข่ายของคุณได้ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบของคุณ\n\nคุณยังได้เชื่อมต่อกับ VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") ผู้ให้บริการ VPN สามารถตรวจสอบกิจกรรมเครือข่ายของคุณได้เช่นกัน"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"อุปกรณ์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nโปรไฟล์ของคุณได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบอุปกรณ์และกิจกรรมเครือข่าย รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบ\n\nคุณยังได้ให้สิทธิ์ \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" ในการตั้งค่าการเชื่อมต่อ VPN แอปนี้จะสามารถตรวจสอบกิจกรรมเครือข่ายได้เช่นกัน"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"อุปกรณ์นี้ได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nโปรไฟล์ของคุณได้รับการจัดการโดย:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nผู้ดูแลระบบสามารถตรวจสอบกิจกรรมเครือข่ายของคุณ รวมถึงอีเมล แอป และเว็บไซต์ที่ปลอดภัย สำหรับข้อมูลเพิ่มเติม โปรดติดต่อผู้ดูแลระบบของคุณ\n\nคุณยังได้เชื่อมต่อกับ VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") ผู้ให้บริการ VPN สามารถตรวจสอบกิจกรรมเครือข่ายของคุณได้เช่นกัน"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"อุปกรณ์จะล็อกจนกว่าคุณจะปลดล็อกด้วยตนเอง"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"รับการแจ้งเตือนเร็วขึ้น"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"ดูก่อนปลดล็อก"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"ไม่เป็นไร"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"ตั้งค่า"</string>
+    <string name="muted_by" msgid="6147073845094180001">"ปิดเสียงโดย <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-tl/strings.xml b/packages/SystemUI/res/values-tl/strings.xml
index 96dfdd7..a0f94fd 100644
--- a/packages/SystemUI/res/values-tl/strings.xml
+++ b/packages/SystemUI/res/values-tl/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"I-clear"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Alisin mula sa listahan"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Impormasyon ng app"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Lumalabas dito ang iyong kamakailang screen"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Huwag pansinin ang kamakailang apps"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 kamakailang app"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Bumalik"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Home"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Mga kamakailang screen"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Hanapin"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telepono"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"I-unlock"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"i-unlock"</string>
+    <string name="phone_label" msgid="2320074140205331708">"buksan ang telepono"</string>
+    <string name="camera_label" msgid="7261107956054836961">"buksan ang camera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Ilipat ang button na pamamaraan ng pag-input."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Button ng zoom ng pagiging tugma."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Mag-zoom nang mas maliit sa mas malaking screen."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"May dalawang bar ang Wifi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"May tatlong bar ang Wifi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Puno ang signal ng WiFi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Nakakonekta sa <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Nakakonekta sa <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Walang WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX na isang bar."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX na dalawang bar."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Pinapagana ang TeleTypewriter."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Pag-vibrate ng ringer."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Naka-silent ang ringer."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"I-dismiss ang <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Hindi pinansin ang <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Sinisimulan ang <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Na-dismiss ang notification."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Notification shade."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Mga mabilisang setting."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Lock screen."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Mga Setting"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Mga kamakailang screen."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"User na si <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Na-off ang wifi."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Na-on ang wifi."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobile <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"<xliff:g id="STATE">%s</xliff:g> ng baterya."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"<xliff:g id="STATE">%s</xliff:g> ng Airplane Mode."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"<xliff:g id="STATE">%s</xliff:g> ng Bluetooth."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Lokasyon <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Naka-off ang Airplane mode."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Naka-on ang Airplane mode."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Na-off ang Airplane mode."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Na-on ang Airplane mode."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Naka-off ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Naka-on ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Kumokonekta ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Nakakonekta ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Na-off ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Na-on ang Bluetooth."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Naka-off ang pag-uulat ng lokasyon."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Naka-on ang pag-uulat ng lokasyon."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Na-off ang pag-uulat ng lokasyon."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Na-on ang pag-uulat ng lokasyon."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm set para sa <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Isara ang panel"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Higit pang oras"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Mas kaunting oras"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Isara ang panel."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Higit pang oras."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Mas kaunting oras."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Naka-off ang flashlight."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Naka-on ang flashlight."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Na-off ang flashlight."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Na-on ang flashlight."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Na-off ang pag-invert ng kulay."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Na-on ang pag-invert ng kulay."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Na-off ang mobile hotspot."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Na-on ang mobile hotspot."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Itinigil ang pagka-cast sa screen."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Liwanag ng display"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Naka-off ang 2G-3G data"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Naka-off ang 4G data"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Naka-off ang cellular data"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Lokasyong itinatakda ng GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Aktibo ang mga kahilingan ng lokasyon"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"I-clear ang lahat ng notification."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Mga Setting"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Mga setting ng notification"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Mg setting ng <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Awtomatikong iikot ang screen."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Naka-lock ang screen sa pahigang oryentasyon."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Naka-lock ang screen sa patayong oryentasyon."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Awtomatiko nang iikot ngayon ang screen."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Naka-lock na ngayon ang screen sa landscape na oryentasyon."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Naka-lock na ngayon ang screen sa portrait na oryentasyon."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Cellular data"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Paggamit ng data"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Natitirang data"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Lumampas sa limitasyon"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Naabot na ang limitasyon – na-pause ang paggamit ng data"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> ang nagamit"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> ang limitasyon"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Babala sa <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Lumalabas dito ang iyong mga kamakailang screen"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Impormasyon ng Application"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"lock to app"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"maghanap"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Maghanap"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Mag-slide pataas para sa <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Mag-slide pakaliwa para sa <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Walang mga pagkaantala, kabilang na ang mga alarma"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Walang mga pagkaantala. Kahit mga alarma."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Walang mga paggambala"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Mga may priyoridad na paggambala lang"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Ang susunod mong alarma ay sa <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Hindi mo maririnig ang alarma mo ng <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Nasa ibaba ang mga notification na hindi masyadong mahalaga"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Pinduting muli upang buksan"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Mag-swipe pataas upang i-unlock"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Mag-swipe pakanan para sa telepono"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Mag-swipe pakaliwa para sa camera"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Walang tiyak na katapusan"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Wala"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Prayoridad"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Lahat"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Nagtsa-charge (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> hanggang mapuno)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Magpalit ng user"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Magpalit ng user, kasalukuyang user <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Ipakita ang profile"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Magdagdag ng user"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Bagong user"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Bisita"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Magdagdag ng bisita"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Alisin ang bisita"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Lalabas sa session ng bisita?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Maaalis ng paglabas sa session ng bisita ang lokal na data."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Alisin ang bisita?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Ide-delete ang lahat ng app at data sa session na ito."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Alisin"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Maligayang pagbabalik, bisita!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Sa loob ng isang minuto"</item>
-    <item quantity="other" msgid="6924190729213550991">"Sa loob ng %d (na) minuto"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Sa loob ng isang oras"</item>
-    <item quantity="other" msgid="5408537517529822157">"Sa loob ng %d (na) oras"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Gusto mo bang ipagpatuloy ang iyong session?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Magsimulang muli"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Oo, magpatuloy"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Magdagdag ng bagong user?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Kapag nagdagdag ka ng bagong user, kailangang i-set up ng taong iyon ang kanyang espasyo.\n\nAng sinumang user ay maaaring mag-update ng mga app para sa lahat ng iba pang user."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Naka-on ang tagatipid ng baterya"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Binabawasan ang pagganap at data sa background"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"I-off ang pagtitipid ng baterya"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Magsimula ngayon"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Walang mga notification"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Maaaring subaybayan ang device"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Maaaring subaybayan ang profile"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Maaaring sinusubaybayan ang network"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Pagsubaybay sa device"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Pagsubaybay sa Profile"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Pagsubaybay sa network"</string>
-    <string name="open_app" msgid="4011771120339160755">"Buksan ang app"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"I-disable ang VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Idiskonekta ang VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Ang device na ito ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMaaaring subaybayan ng iyong administrator ang iyong device at aktibidad sa network, kabilang ang mga email, app at secure na website.\n\nPara sa higit pang impormasyon, makipag-ugnayan sa iyong administrator."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Pinahintulutan mo ang \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" na mag-set up ng koneksyon sa VPN.\n\nMaaaring subaybayan ng app na ito ang iyong device at aktibidad sa network, kabilang ang mga email, app at secure na website."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Nakakonekta ka sa isang VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nMaaaring subaybayan ng iyong VPN service provider ang iyong device at aktibidad sa network kabilang ang mga email, app at secure na website."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Ang device ay pinapamahalaan ng:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMay kakayahan ang iyong administrator na subaybayan ang iyong aktibidad sa network kabilang ang mga email, apps at secure na website. Para sa higit pang impormasyon, makipag-ugnayan sa iyong administrator.\n\nGayundin, pinahintulutan mo ang \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" na mag-set up ng koneksyon sa VPN. Maaari ding subaybayan ng app na ito ang aktibidad sa network."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Ang device ay pinapamahalaan ng:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMay kakayahan ang iyong administrator na subaybayan ang iyong aktibidad sa network kabilang ang mga email, apps at secure na website. Para sa higit pang impormasyon, makipag-ugnayan sa iyong administrator.\n\nGayundin, nakakonekta ka sa isang VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Maaari ding subaybayan ng iyong VPN service provider ang mga aktibidad sa network."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Ang profile na ito ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMaaaring subaybayan ng administrator mo ang iyong device at aktibidad sa network, kabilang na ang mga email, app at secure na website.\n\nPara sa higit pang impormasyon, makipag-ugnayan sa iyong administrator."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Ang device na ito ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAng iyong profile ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nMaaaring subaybayan ng administrator ang iyong device at aktibidad sa network, kabilang na ang mga email, app at secure na website.\n\nPara sa higit pang impormasyon, makipag-ugnayan sa iyong administrator."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"This profile is managed by:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Ang profile na ito ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nMay kakayahan ang iyong administrator na subaybayan ang iyong aktibidad sa network kabilang na ang mga email, app, at secure na website. Para sa higit pang impormasyon, makipag-ugnayan sa iyong administrator.\n\nGayundin, nakakonekta ka sa isang VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Magagawa rin ng iyong VPN service provider na subaybayan ang aktibidad sa network."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Ang device na ito ay pinamamahalaan ng\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nAng profile mo ay pinamamahalaan ng:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nMay kakayahan ang iyong administrator na subaybayan ang iyong aktibidad sa network, kabilang na ang mga email, app at secure na website. Para sa higit pang impormasyon, makipag-ugnayan sa iyong administrator.\n\nGayundin, binigyan mo ng pahintulot ang \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" na mag-set up ng koneksyong VPN. Maaari ring sumubaybay ng aktibidad sa network ang app na ito."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"This device is managed by:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Your VPN service provider can monitor network activity too."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Mananatiling naka-lock ang device hanggang sa manu-mano mong i-unlock"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Kunin ang notification nang mas mabilis"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Tingnan ang mga ito bago ka mag-unlock"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Hindi"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"I-set up"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Na-mute ng <xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-tr/strings.xml b/packages/SystemUI/res/values-tr/strings.xml
index de21586..bab860b 100644
--- a/packages/SystemUI/res/values-tr/strings.xml
+++ b/packages/SystemUI/res/values-tr/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Temizle"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Listeden kaldır"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Uygulama bilgileri"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Son ekranlarınız burada görünür"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Son uygulamaları kapat"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 tane son uygulama"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Geri"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Ana sayfa"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Son ekranlar"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Ara"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Kilidi aç"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"kilidi aç"</string>
+    <string name="phone_label" msgid="2320074140205331708">"telefonu aç"</string>
+    <string name="camera_label" msgid="7261107956054836961">"kamerayı aç"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Giriş yöntemini değiştirme düğmesi."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Uyumluluk zum düğmesi."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Daha büyük ekrana daha küçük yakınlaştır."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Kablosuz sinyali iki çubuk."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Kablosuz sinyali üç çubuk."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Kablosuz sinyali tam."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> ile bağlı."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> ile bağlı."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX yok."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX tek çubuk."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX iki çubuk."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter etkin."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Telefon zili titreşim."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Telefon zili sessiz."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> uygulamasını kapat."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> kaldırıldı."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> başlatılıyor."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Bildirim kapatıldı."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Bildirim gölgesi."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Hızlı ayarlar."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Kilit ekranı"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Ayarlar"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Son ekranlar."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Kullanıcı: <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Kablosuz kapatıldı."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Kablosuz açıldı."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Mobil <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Pil <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Uçak Modu <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Konum: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Uçak modu kapalı."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Uçak modu açık."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Uçak modu kapatıldı."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Uçak modu açıldı."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth kapalı."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth açık."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth bağlanıyor."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth bağlandı."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth kapatıldı."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth açıldı."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Konum Bildirme kapalı."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Konum Bildirme açık."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Konum Bildirme kapatıldı."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Konum Bildirme açıldı."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Alarm saati: <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Paneli kapatın"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Daha uzun süre"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Daha kısa süre"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Paneli kapat."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Daha uzun süre."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Daha kısa süre."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Flaş ışığı kapalı."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Flaş ışığı açık."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Flaş ışığı kapatıldı."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Flaş ışığı açıldı."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Renkleri ters çevirme işlevi kapatıldı."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Renkleri ters çevirme işlevi açıldı."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobil hotspot kapatıldı."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobil hotspot açıldı."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ekran yayını durduruldu."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ekran parlaklığı"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G veri kullanımı kapalı"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G veri kullanımı kapalı"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Hücresel veri kapalı"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Konum GPS ile belirlendi"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Konum bilgisi istekleri etkin"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Tüm bildirimleri temizle"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Ayarlar"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Bildirim ayarları"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ayarları"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekran otomatik olarak dönecektir."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ekran yatay yönde kilitlendi."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ekran dikey yönde kilitlendi."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ekran şimdi otomatik olarak döndürülecek."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ekran yatay yönde kilitlendi"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ekran dikey yönde kilitlendi"</string>
     <string name="dessert_case" msgid="1295161776223959221">"Tatlı Kutusu"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Hafif uyku"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Hücresel veriler"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Veri kullanımı"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Kalan veri"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Sınır aşıldı"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Sınıra ulaşıldı – veri kullanımı duraklatıldı"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> kullanıldı"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Sınır: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> uyarısı"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Son ekranlarınız burada görünür"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Uygulama Bilgileri"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"uygulamaya kilitle"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"ara"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Ara"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> için yukarı kaydırın."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> için sola kaydırın."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Alarmlar dahil hiç kesinti yok"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Kesinti yok. Uyarı bile yok."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Kesinti yok"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Sadece öncelikli kesintiler"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Bir sonraki alarmın saati: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"<xliff:g id="ALARM_TIME">%s</xliff:g> olarak ayarlanan alarmı duymayacaksınız"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Daha az acil bildirimler aşağıdadır"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Açmak için tekrar dokunun"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Kilidi açmak için hızlıca yukarı kaydırın"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefon için sağa kaydırın"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Kamera için sola kaydırın"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Süresiz"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Yok"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Öncelik"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Tümü"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Şarj oluyor (tamamen dolmasına <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> kaldı)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Kullanıcı değiştirme"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Kullanıcı değiştir. Geçerli kullanıcı: <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Profili göster"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Kullanıcı ekle"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Yeni kullanıcı"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Misafir"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Misafir ekle"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Misafir oturumunu kaldır"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Misafir oturumundan çıkılsın mı?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Misafir oturumundan çıkmak tüm yerel verileri kaldıracaktır."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Misafir oturumu kaldırılsın mı?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Bu oturumdaki tüm uygulamalar ve veriler silinecek."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Kaldır"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Tekrar hoş geldiniz sayın misafir!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Bir dakika süreyle"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d dakika süreyle"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Bir saat süreyle"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d saat süreyle"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Oturumunuza devam etmek istiyor musunuz?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Baştan başla"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Evet, devam et"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Yeni kullanıcı eklensin mi?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Yeni bir kullanıcı eklediğinizde, bu kişinin kendi alanını ayarlaması gerekir.\n\nHerhangi bir kullanıcı, diğer tüm kullanıcılar için uygulamaları güncelleyebilir."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Pil tasarrufu açık"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Performansı ve arka plan verilerini azaltır"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Pil tasarrufunu kapat"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Şimdi başla"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Bildirim yok"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Cihaz izlenebilir"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil izlenebilir"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Ağ etkinliği izlenebilir"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Cihaz izleme"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profil izleme"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Ağ izleme"</string>
-    <string name="open_app" msgid="4011771120339160755">"Uygulamayı aç"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN\'yi devre dışı bırak"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN bağlantısını kes"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYöneticiniz e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir.\n\nDaha fazla bilgi edinmek için yöneticinizle iletişim kurun."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"\"<xliff:g id="APPLICATION">%1$s</xliff:g>\" uygulamasına bir VPN bağlantısı kurma izni verdiniz.\n\nBu uygulama e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Bir VPN\'ye (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\") bağlısınız.\n\nVPN servis sağlayıcınız e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYöneticiniz e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir.\n\nAyrıca \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" uygulamasına VPN bağlantısı kurma izni de verdiniz. Bu uygulama da ağ etkinliğini izleyebilir."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n.Yöneticiniz e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir. Daha fazla bilgi için yöneticinizle iletişim kurun.\n\n Ayrıca bir VPN\'ye de (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") bağlısınız. VPN servis sağlayıcınız da ağ etkinliğini izleyebilir."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Bu profili yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYöneticiniz; e-postalar, uygulamalar ve güvenli web siteleri de dahil olmak üzere ağ etkinliğinizi izleyebilir.\n\nDaha fazla bilgi için yöneticinize başvurun."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilinizi yöneten kuruluş:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYöneticiniz; e-postalar, uygulamalar ve güvenli web siteleri de dahil olmak üzere cihazınızı ve ağ etkinliğinizi izleyebilir.\n\nDaha fazla bilgi için yöneticinize başvurun."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Bu profili yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYöneticiniz e-postalar, uygulamalar ve güvenli web siteleri dahil olmak üzere ağ etkinliğinizi izleyebilir.\n\nAyrıca \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" uygulamasına VPN bağlantısı kurma izni de verdiniz. Bu uygulama da ağ etkinliğini izleyebilir."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Bu profili yöneten kuruluş:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nYöneticiniz; e-postalar, uygulamalar ve güvenli web siteleri de dahil olmak üzere ağ etkinliğinizi izleyebilir. Daha fazla bilgi için yöneticinize başvurun.\n\nAyrıca, bir VPN\'ye (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") bağlısınız. VPN hizmet sağlayıcınız da ağ etkinliğini izleyebilir."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilinizi yöneten kuruluş:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYöneticiniz; e-postalar, uygulamalar ve güvenli web siteleri de dahil olmak üzere ağ etkinliğinizi izleyebilir. Daha fazla bilgi için yöneticinize başvurun.\n\nAyrıca \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" uygulamasına VPN kurma izni verdiniz. Bu uygulama da ağ etkinliğini izleyebilir."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Bu cihazı yöneten kuruluş:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilinizi yöneten kuruluş:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nYöneticiniz; e-postalar, uygulamalar ve güvenli web siteleri de dahil olmak üzere ağ etkinliğinizi izleyebilir. Daha fazla bilgi için yöneticinize başvurun.\n\nAyrıca, bir VPN\'ye (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") bağlısınız. VPN hizmet sağlayıcınız da ağ etkinliğini izleyebilir."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Cihazınızın kilidini manuel olarak açmadıkça cihaz kilitli kalacak"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Bildirimleri daha hızlı alın"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Kilidi açmadan bildirimleri görün"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Hayır, teşekkürler"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Kur"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> tarafından kapatıldı"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-tvdpi/dimens.xml b/packages/SystemUI/res/values-tvdpi/dimens.xml
new file mode 100644
index 0000000..5327cee
--- /dev/null
+++ b/packages/SystemUI/res/values-tvdpi/dimens.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<resources>
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <fraction name="battery_button_height_fraction">12%</fraction>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+     fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">10%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">10%</fraction>
+
+    <dimen name="battery_margin_bottom">1px</dimen>
+</resources>
diff --git a/packages/SystemUI/res/values-uk/config.xml b/packages/SystemUI/res/values-uk/config.xml
new file mode 100644
index 0000000..3a6872f
--- /dev/null
+++ b/packages/SystemUI/res/values-uk/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1 с, 10 с, 30 с, 60 с, 120 с"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-uk/strings.xml b/packages/SystemUI/res/values-uk/strings.xml
index 8cf85bd..cbbdbe9 100644
--- a/packages/SystemUI/res/values-uk/strings.xml
+++ b/packages/SystemUI/res/values-uk/strings.xml
@@ -22,9 +22,8 @@
     <string name="app_label" msgid="7164937344850004466">"Інтерфейс системи"</string>
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Очист."</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Видалити зі списку"</string>
-    <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Інформація про програму"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Про додаток"</string>
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Ваші останні екрани відображаються тут"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Відхилити останні програми"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 остання програма"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Назад"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Головна"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Останні екрани"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Пошук"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Номер телефону"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Розблокувати"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"розблокувати"</string>
+    <string name="phone_label" msgid="2320074140205331708">"відкрити телефон"</string>
+    <string name="camera_label" msgid="7261107956054836961">"відкрити камеру"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Кнопка перемикання методу введення."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Кнопка масштабування сумісності."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Збільшення екрана."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Дві смужки сигналу Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Три смужки сигналу Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Максимальний сигнал Wi-Fi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Підключено до <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Підключено до <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Немає сигналу WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Одна смужка сигналу WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Дві смужки сигналу WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Телетайп увімкнено."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Дзвінок на вібросигналі."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Дзвінок беззвучний."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Видалити додаток <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"Програму <xliff:g id="APP">%s</xliff:g> закрито."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Запуск додатка <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Сповіщення відхилено."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Панель сповіщень."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Швидке налаштування."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Заблокований екран."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Налаштування"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Останні екрани."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Користувач <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi вимкнено."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi увімкнено."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Мобільне передавання даних: <xliff:g id="SIGNAL">%1$s</xliff:g>, <xliff:g id="TYPE">%2$s</xliff:g>, <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Акумулятор: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Режим польоту: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth: <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Місцезнаходження <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Режим польоту вимк."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Режим польоту ввімк."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Режим польоту вимкнено."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Режим польоту ввімкнено."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth вимк."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth увімк."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Під’єднання Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth під’єднано."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth вимкнено."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth увімкнено."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Надсилання геоданих вимк."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Надсилання геоданих увімк."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Надсилання геоданих вимкнено."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Надсилання геоданих увімкнено."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Сигнал установлено на <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Закрити панель"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Більше часу"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Менше часу"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Закрити панель."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Більше часу."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Менше часу."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Ліхтарик вимк."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Ліхтарик увімк."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Ліхтарик вимкнено."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Ліхтарик увімкнено."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Інверсію кольорів вимкнено."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Інверсію кольорів увімкнено."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Мобільну точку доступу вимкнено."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Мобільну точку доступу ввімкнено."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Трансляцію екрана зупинено."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Яскравість дисплея"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Дані 2G–3G вимкнено"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Дані 4G вимкнено"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Мобільні дані вимкнено"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Місцезнаходження встановлено за допомогою GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Запити про місцезнаходження активні"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Очистити всі сповіщення."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Налаштування"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Налаштування сповіщень"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Налаштування додатка <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Екран обертатиметься автоматично."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Екран заблоковано в альбомній орієнтації."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Екран заблоковано в книжковій орієнтації."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Екран тепер обертатиметься автоматично."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Екран заблоковано в альбомній орієнтації."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Екран заблоковано в книжковій орієнтації."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Вітрина десертів"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Заставка"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -236,16 +267,15 @@
     <string name="quick_settings_tethering_label" msgid="7153452060448575549">"Режим модема"</string>
     <string name="quick_settings_hotspot_label" msgid="6046917934974004879">"Точка доступу"</string>
     <string name="quick_settings_notifications_label" msgid="4818156442169154523">"Сповіщення"</string>
-    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Світловий сигнал"</string>
+    <string name="quick_settings_flashlight_label" msgid="2133093497691661546">"Ліхтарик"</string>
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Мобільні дані"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Використання даних"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Залишилося даних"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Обмеження перевищено"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Досягнуто ліміту. Передавання даних призупинено"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Використовується: <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Обмеження: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Застереження: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Ваші останні екрани відображаються тут"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Інформація про додаток"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"блокування в додатку"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"пошук"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Пошук"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Проведіть пальцем угору, щоб <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Проведіть пальцем ліворуч, щоб <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Без сповіщень, зокрема сигналів будильника"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Без сповіщень і сигналів будильника."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Без сповіщень"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Лише пріоритетні сповіщення"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Наступний сигнал: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Сигнал не лунатиме о <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Менше термінових сповіщень нижче"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Торкніться знову, щоб відкрити"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Проведіть пальцем угору, щоб розблокувати"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Проведіть пальцем праворуч, щоб скористатися телефоном"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Проведіть пальцем ліворуч, щоб скористатися камерою"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Без обмежень"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Немає"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Пріоритетні"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Усі"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Заряджання (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> до повного зарядження)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Змінити користувача"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Змінити користувача, поточний користувач – <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Показати профіль"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Додати користувача"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Новий користувач"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Гість"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Додати гостя"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Видалити гостя"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Закінчити сеанс у режимі \"Гість\"?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Якщо закінчити сеанс у режимі \"Гість\", локальні дані буде видалено."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Вийти з режиму гостя?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Усі додатки й дані з цього сеансу буде видалено."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Вийти"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"З поверненням!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Протягом хвилини"</item>
-    <item quantity="other" msgid="6924190729213550991">"Протягом %d хв"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Протягом години"</item>
-    <item quantity="other" msgid="5408537517529822157">"Протягом %d год"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Продовжити сеанс?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Почати знову"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Так, продовжити"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Додати нового користувача?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Користувач має налаштувати свій профіль після створення.\n\nБудь-який користувач пристрою може оновлювати додатки для решти користувачів."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Режим заощадження заряду акумулятора ввімкнено"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Знижується продуктивність і обмежуються фонові дані"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Вимкнути режим заощадження заряду акумулятора"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Почати зараз"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Сповіщень немає"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Дії на пристрої можуть відстежуватися"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Профіль може відстежуватись"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Дії в мережі можуть відстежуватися"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Відстеження дій на пристрої"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Відстеження профілю"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Відстеження дій у мережі"</string>
-    <string name="open_app" msgid="4011771120339160755">"Відкрити додаток"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Вимкнути VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Від’єднатися від мережі VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Цим пристроєм керує \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати пристрій та дії в мережі, зокрема листування, роботу в додатках і на захищених веб-сайтах.\n\nЩоб дізнатися більше, зверніться до адміністратора."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Ви дозволили додатку <xliff:g id="APPLICATION">%1$s</xliff:g> під’єднуватися до мережі VPN.\n\nДодаток може відстежувати ваш пристрій та дії в мережі, зокрема листування, роботу в додатках і на захищених веб-сайтах."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Ви під’єднані до мережі VPN (<xliff:g id="APPLICATION">%1$s</xliff:g>).\n\nПостачальник послуг VPN може відстежувати пристрій та дії в мережі, зокрема листування, роботу в додатках і на захищених веб-сайтах."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Цим пристроєм керує \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених веб-сайтах. Щоб дізнатися більше, зверніться до адміністратора.\n\nВи також дозволили додатку <xliff:g id="APPLICATION">%2$s</xliff:g> під’єднатися до мережі VPN. Цей додаток теж може відстежувати ваші дії в мережі."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Цим пристроєм керує \n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених веб-сайтах. Щоб дізнатися більше, зверніться до адміністратора.\n\nВаш пристрій також під’єднаний до мережі VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Постачальник послуг VPN може відстежувати ваші дії в мережі."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Цим профілем керує\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії на пристрої та в мережі, зокрема листування, роботу в додатках і на захищених сайтах.\n\nЗв’яжіться з адміністратором, щоб дізнатися більше."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Цим пристроєм керує\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профілем керує\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії на пристрої та в мережі, зокрема листування, роботу в додатках і на захищених сайтах.\n\nЗв’яжіться з адміністратором, щоб дізнатися більше."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Цим профілем керує\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених сайтах. Зв’яжіться з адміністратором, щоб дізнатися більше.\n\nВи дозволили додатку <xliff:g id="APPLICATION">%2$s</xliff:g> під’єднатися до мережі VPN. Цей додаток може відстежувати ваші дії в мережі."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Цим профілем керує\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених сайтах. Зв’яжіться з адміністратором, щоб дізнатися більше.\n\nПристрій під’єднано до мережі VPN (<xliff:g id="APPLICATION">%2$s</xliff:g>). Постачальник послуг VPN може відстежувати ваші дії в мережі."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Цим пристроєм керує\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профілем керує\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених сайтах. Зв’яжіться з адміністратором, щоб дізнатися більше.\n\nВи дозволили додатку <xliff:g id="APPLICATION">%3$s</xliff:g> під’єднатися до мережі VPN. Цей додаток може відстежувати ваші дії в мережі."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Цим пристроєм керує\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nВашим профілем керує\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nАдміністратор може відстежувати ваші дії в мережі, зокрема листування, роботу в додатках і на захищених сайтах. Зв’яжіться з адміністратором, щоб дізнатися більше.\n\nПристрій під’єднано до мережі VPN (<xliff:g id="APPLICATION">%3$s</xliff:g>). Постачальник послуг VPN може відстежувати ваші дії в мережі."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Пристрій залишатиметься заблокованим, доки ви не розблокуєте його вручну"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Швидше отримуйте сповіщення"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Переглядайте сповіщення, перш ніж розблокувати екран"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ні, дякую"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Налаштув."</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> вимикає звук"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-ur-rPK/strings.xml b/packages/SystemUI/res/values-ur-rPK/strings.xml
index cb92e83..13fad3f 100644
--- a/packages/SystemUI/res/values-ur-rPK/strings.xml
+++ b/packages/SystemUI/res/values-ur-rPK/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"صاف کریں"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"فہرست سے ہٹائیں"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"ایپ کی معلومات"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"آپ کی حالیہ اسکرینز یہاں ظاہر ہوتی ہیں"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"حالیہ ایپس برخاست کریں"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 حالیہ ایپ"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"واپس جائیں"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"ہوم"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"مینو"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"حالیہ اسکرینز"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"تلاش کریں"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"کیمرا"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"فون"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"غیر مقفل کریں"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"غیر مقفل کریں"</string>
+    <string name="phone_label" msgid="2320074140205331708">"فون کھولیں"</string>
+    <string name="camera_label" msgid="7261107956054836961">"کیمرا کھولیں"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"اندراج کا طریقہ سوئچ کرنے کا بٹن۔"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"مطابقت پذیری زوم بٹن۔"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"چھوٹی سے بڑی اسکرین پر زوم کریں۔"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"‏Wifi دو بارز۔"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"‏Wifi تین بارز۔"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"‏Wifi سگنل پورا ہے۔"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"<xliff:g id="WIFI">%s</xliff:g> سے منسلک ہیں۔"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"<xliff:g id="BLUETOOTH">%s</xliff:g> سے منسلک ہیں۔"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"‏کوئی WiMAX نہیں ہے۔"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"‏WiMAX ایک بار۔"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"‏WiMAX دو بارز۔"</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"ٹیلی ٹائپ رائٹر فعال ہے۔"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"رنگر وائبریٹ۔"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"رنگر خاموش۔"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"<xliff:g id="APP">%s</xliff:g> کو مسترد کریں۔"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> کو ہٹا دیا گیا۔"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> شروع ہو رہی ہے۔"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"اطلاع مسترد ہوگئی۔"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"اطلاعاتی شیڈ۔"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"فوری ترتیبات۔"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"مقفل اسکرین۔"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"ترتیبات"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"حالیہ اسکرینز۔"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"صارف <xliff:g id="USER">%s</xliff:g>۔"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>۔ <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>۔"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"‏Wifi کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"‏Wifi کو آن کر دیا گیا۔"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"موبائل <xliff:g id="SIGNAL">%1$s</xliff:g>۔ <xliff:g id="TYPE">%2$s</xliff:g>۔ <xliff:g id="NETWORK">%3$s</xliff:g>۔"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"بیٹری <xliff:g id="STATE">%s</xliff:g>۔"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"ہوائی جہاز وضع <xliff:g id="STATE">%s</xliff:g>۔"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"بلوٹوتھ <xliff:g id="STATE">%s</xliff:g>۔"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"مقام <xliff:g id="STATE">%s</xliff:g>۔"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"ہوائی جہاز وضع آف ہے۔"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"ہوائی جہاز وضع آن ہے۔"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"ہوائی جہاز وضع کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"ہوائی جہاز وضع کو آن کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"بلوٹوتھ آف ہے۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"بلوٹوتھ آن ہے۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"بلوٹوتھ منسلک ہو رہا ہے۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"بلوٹوتھ منسلک ہے۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"بلوٹوتھ کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"بلوٹوتھ کو آن کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"مقام کی اطلاع دہندگی آف ہے۔"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"مقام کی اطلاع دہندگی آن ہے۔"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"مقام کی اطلاع دہندگی کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"مقام کی اطلاع دہندگی کو آن کر دیا گیا۔"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"الارم <xliff:g id="TIME">%s</xliff:g> کیلئے سیٹ ہے۔"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"پینل بند کریں"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"مزید وقت"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"کم وقت"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"پینل بند کریں۔"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"مزید وقت۔"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"کم وقت۔"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"فلیش لائٹ آف ہے۔"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"فلیش لائٹ آن ہے۔"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"فلیش لائٹ کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"فلیش لائٹ کو آن کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"رنگ کی تبدیلی کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"رنگ کی تبدیلی کو آن کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"موبائل ہاٹ اسپاٹ کو آف کر دیا گیا۔"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"موبائل ہاٹ اسپاٹ کو آن کر دیا گیا۔"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"اسکرین کو کاسٹ کرنا بند کر دیا۔"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"ڈسپلے کی چمک"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"‏2G-3G ڈیٹا آف ہے"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"‏4G ڈیٹا آف ہے"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"سیلولر ڈیٹا آف ہے"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"‏مقام متعین کیا گیا بذریعہ GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"مقام کی درخواستیں فعال ہیں"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"سبھی اطلاعات صاف کریں۔"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"ترتیبات"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"اطلاع کی ترتیبات"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> ترتیبات"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"اسکرین خود بخود گردش کرے گی۔"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"اسکرین لینڈ اسکیپ سمت بندی میں مقفل ہے۔"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"اسکرین پورٹریٹ سمت بندی میں مقفل ہے۔"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"اسکرین اب خود بخود گردش کرے گی۔"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"اسکرین اب لینڈ اسکیپ سمت بندی میں مقفل ہے۔"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"اسکرین اب پورٹریٹ سمت بندی میں مقفل ہے۔"</string>
     <string name="dessert_case" msgid="1295161776223959221">"ڈیزرٹ کیس"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"ایتھرنیٹ"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"سیلولر ڈیٹا"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"ڈیٹا کا استعمال"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"باقی ڈیٹا"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"حد سے زیادہ"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"حد تک پہنچ گیا – ڈیٹا کا استعمال موقوف ہوگیا"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> استعمال کردہ"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> حد"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> وارننگ"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"آپ کی حالیہ اسکرینز یہاں ظاہر ہوتی ہیں"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"ایپلیکیشن کی معلومات"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"لاک ٹو ایپ"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"تلاش کریں"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"تلاش کریں"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> کیلئے اوپر سلائیڈ کریں۔"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> کیلئے بائیں سلائیڈ کریں۔"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"الارمز کے بشمول، کوئی مداخلتیں نہیں ہیں"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"کوئی مداخلتیں نہیں ہیں۔ یہاں تک کہ الارمز بھی نہیں ہیں۔"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"کوئی مداخلتیں نہیں ہیں"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"صرف ترجیحی مداخلتیں"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"آپ کا اگلا الارم <xliff:g id="ALARM_TIME">%s</xliff:g> بجے ہے"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"آپ کو <xliff:g id="ALARM_TIME">%s</xliff:g> بجے اپنا الارم سنائی نہیں دیگا"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"‎+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>‎"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"کم اہم اطلاعات ذیل میں ہیں"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"کھولنے کیلئے دوبارہ ٹچ کریں"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"غیر مقفل کرنے کیلئے اوپر سوائپ کریں"</string>
     <string name="phone_hint" msgid="3101468054914424646">"فون کیلئے دائیں سوائپ کریں"</string>
     <string name="camera_hint" msgid="5241441720959174226">"کیمرہ کیلئے بائیں سوائپ کریں"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"غیر متعینہ"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"کوئی نہیں"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"ترجیح"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"سبھی"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"چارج ہو رہا ہے (مکمل ہونے تک <xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> باقی ہیں)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"صارف سوئچ کریں"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"صارف سوئچ کریں، موجودہ صارف <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"پروفائل دکھائیں"</string>
     <string name="user_add_user" msgid="5110251524486079492">"صارف کو شامل کریں"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"نیا صارف"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"مہمان"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"مہمان کو شامل کریں"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"مہمان کو ہٹائیں"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"مہمان سیشن سے باہر نکل رہے ہیں؟"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"مہمان سیشن سے باہر نکلنے سے مقامی ڈیٹا ہٹ جائے گا۔"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"مہمان کو ہٹائیں؟"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"اس سیشن میں موجود سبھی ایپس اور ڈیٹا کو حذف کر دیا جائے گا۔"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"ہٹائیں"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"مہمان، پھر سے خوش آمدید!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"ایک منٹ کیلئے"</item>
-    <item quantity="other" msgid="6924190729213550991">"‏%d منٹ کیلئے"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"ایک گھنٹے کیلئے"</item>
-    <item quantity="other" msgid="5408537517529822157">"‏%d گھنٹوں کیلئے"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"کیا آپ اپنا سیشن جاری رکھنا چاہتے ہیں؟"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"دوبارہ شروع کریں"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"ہاں، جاری رکھیں"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"نیا صارف شامل کریں؟"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"جب آپ ایک نیا صارف شامل کرتے ہیں تو اس شخص کو اپنی جگہ کو ترتیب دینے کی ضرورت ہوتی ہے۔\n\nکوئی بھی صارف دیگر سبھی صارفین کیلئے ایپس کو اپ ڈیٹ کر سکتا ہے۔"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"بیٹری سیور آن ہے"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"کارکردگی اور پس منظر کا ڈیٹا کم کر دیتا ہے"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"بیٹری کی بچت آف کریں"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"ابھی شروع کریں"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"کوئی اطلاعات نہیں ہیں"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"آلہ کو مانیٹر کیا جا سکتا ہے"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"پروفائل کو مانیٹر کیا جا سکتا ہے"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"نیٹ ورک کو مانیٹر کیا جا سکتا ہے"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"آلہ کو مانیٹر کرنا"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"پروفائل کو مانیٹر کرنا"</string>
     <string name="monitoring_title" msgid="169206259253048106">"نیٹ ورک کو مانیٹر کرنا"</string>
-    <string name="open_app" msgid="4011771120339160755">"ایپ کھولیں"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"‏VPN کو غیر فعال کریں"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"‏VPN کو غیر منسلک کریں"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"اس آلہ کا نظم مندرجہ ذیل کے ذریعے کیا جاتا ہے:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کے آلہ اور نیٹ ورک کی سرگرمی، بشمول ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔\n\nمزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"‏آپ نے \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" کو ایک VPN کنکشن سیٹ اپ کرنے کی اجازت دی ہے۔\n\nیہ ایپ ای میلز، ایپس اور محفوظ ویب سائٹس کے بشمول آپ کے آلہ اور نیٹ ورک کی سرگرمی کو مانیٹر کر سکتی ہے۔"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"‏آپ ایک VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\")‎ سے منسلک ہیں۔\n\nآپ کا VPN سروس فراہم کنندہ ای میلز، ایپس اور محفوظ ویب سائٹس کے بشمول آپ کے آلہ اور نیٹ ورک کی سرگرمی کو مانیٹر کر سکتا ہے۔"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"‏اس آلہ کا نظم مندرجہ ذیل کے ذریعے کیا جاتا ہے:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی بشمول ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کرنے کا اہل ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ نے \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" کو ایک VPN کنکشن ترتیب دینے کی اجازت دی ہے۔ یہ ایپ نیٹ ورک کی سرگرمی بھی مانیٹر کر سکتی ہے۔"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"‏اس آلہ کا نظم مندرجہ ذیل کے ذریعے کیا جاتا ہے:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی بشمول ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کرنے کا اہل ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ ایک VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") سے منسلک ہیں۔ آپ کی VPN سروس کا فراہم کنندہ نیٹورک کی سرگرمی کو بھی مانیٹر کر سکتا ہے۔"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"اس پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کا آلہ اور نیٹ ورک کی سرگرمی بشمول، ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔\n\nمزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"اس آلہ کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nآپ کے پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nآپ کا منتظم آپ کے آلہ اور نیٹ ورک کی سرگرمی، بشمول ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔\n\nمزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"‏اس پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی بشمول، ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ نے \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" کو ایک VPN کنکشن کو ترتیب دینے کی اجازت دی ہے۔ یہ ایپ نیٹ ورک کی سرگرمی بھی مانیٹر کر سکتی ہے۔"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"‏اس پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی بشمول، ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ ایک VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\") سے منسلک ہیں۔ آپ کا VPN سروس فراہم کنندہ نیٹ ورک کی سرگرمی بھی مانیٹر کر سکتا ہے۔"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"‏اس آلہ کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nآپ کے پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی بشمول، ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ نے \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" کو ایک VPN کنکشن ترتیب دینے کی اجازت دی ہے۔ یہ ایپ نیٹ ورک کی سرگرمی بھی مانیٹر کر سکتی ہے۔"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"‏اس آلہ کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nآپ کے پروفائل کا نظم کیا جاتا ہے بذریعہ:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nآپ کا منتظم آپ کے نیٹ ورک کی سرگرمی، بشمول ای میلز، ایپس اور محفوظ ویب سائٹس کو مانیٹر کر سکتا ہے۔ مزید معلومات کیلئے، اپنے منتظم سے رابطہ کریں۔\n\nنیز، آپ ایک VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\") سے منسلک ہیں۔ آپ کا VPN سروس فراہم کنندہ نیٹ ورک کی سرگرمی کو بھی مانیٹر کر سکتا ہے۔"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"آلہ اس وقت تک مقفل رہے گا جب تک آپ دستی طور پر اسے غیر مقفل نہ کریں"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"تیزی سے اطلاعات حاصل کریں"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"غیر مقفل کرنے سے پہلے انہیں دیکھیں"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"نہیں شکریہ"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"ترتیب دیں"</string>
+    <string name="muted_by" msgid="6147073845094180001">"<xliff:g id="THIRD_PARTY">%1$s</xliff:g> کے ذریعے خاموش کردہ"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-uz-rUZ/strings.xml b/packages/SystemUI/res/values-uz-rUZ/strings.xml
index 369c6ee..4cf823b 100644
--- a/packages/SystemUI/res/values-uz-rUZ/strings.xml
+++ b/packages/SystemUI/res/values-uz-rUZ/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Tozalash"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Ro‘yxatdan o‘chirish"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Ilova xaqida"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Yaqinda ish-gan ilovalar bu yerda ko‘rinadi"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"So‘nggi dasturlarni tozalash"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ta so‘nggi foydalanilgan dastur"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Orqaga"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Uyga"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menyu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Yaqinda ishlatilganlar"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Izlash"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Telefon"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Qulfdan chiqarish"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"qulfdan chiqarish"</string>
+    <string name="phone_label" msgid="2320074140205331708">"telefonni ochish"</string>
+    <string name="camera_label" msgid="7261107956054836961">"kamerani ochish"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Kiritish uslubi tugmasini almashtirish."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Kattalashtirish tugmasi mosligi."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Kattaroq ekran uchun kichikroqni kattalashtirish."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Ikkita ustunli Wifi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Uchta ustunli Wifi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"To‘liq signalli Wifi."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Ulangan: <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Ulangan: <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"WiMAX tarmog‘i yo‘q."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Bitta ustunli WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Ikkita ustunli WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter yoqildi."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Vibratsiyali qo‘ng‘iroq"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Ovozsiz qo‘ng‘iroq."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Olib tashlash: <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> olib tashlangan."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"<xliff:g id="APP">%s</xliff:g> ishga tushirilmoqda."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Xabarnoma e‘tiborsiz qoldirildi."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Xabarnoma soyasi."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Tezkor sozlamalar."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Qulflash ekrani."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Sozlamalar"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Yaqinda ishlatilganlar."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Foydalanuvchi <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Wi-Fi o‘chirildi."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Wi-Fi yoqildi."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Uyali <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Batareya <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Parvoz rejimi <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Joylashuv: <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Parvoz rejimi o‘chirilgan."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Parvoz rejimi yoqilgan."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Parvoz rejimi o‘chirildi."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Parvoz rejimi yoqildi."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth o‘chirilgan."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth yoqilgan."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Bluetooth ulanmoqda."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Bluetooth ulangan."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Bluetooth o‘chirildi."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Bluetooth yoqildi."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Joylashuv ma’lumotini yuborish o‘chirilgan."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Joylashuv ma’lumotini yuborish yoqilgan."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Joylashuv ma’lumotini yuborish o‘chirildi."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Joylashuv ma’lumotini yuborish yoqildi."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Signal <xliff:g id="TIME">%s</xliff:g> ga o‘rnatildi."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Panelni yopish"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Vaqtni ko‘paytirish"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Vaqtni kamaytirish"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Panelni yopish."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Ko‘proq vaqt."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Kamroq vaqt."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Fonar o‘chirilgan."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Fonar yoqilgan."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Fonar o‘chirildi."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Fonar yoqildi."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Ranglarni akslantirish o‘chirildi."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Ranglarni akslantirish yoqildi."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Mobil ulanish nuqtasi o‘chirildi."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Mobil ulanish nuqtasi yoqildi."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ekranni translatsiya qilish to‘xtadi."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Ekran yorqinligi"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G/3G internet o‘chirib qo‘yildi"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G internet o‘chirib qo‘yildi"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Mobil internet o‘chirib qo‘yildi"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS yordamida manzilni o‘rnatish"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Joylashuv so‘rovlari yoniq"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Barcha eslatmalarni tozalash."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Sozlamalar"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Bildirishnoma sozlamalari"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> sozlamalari"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Ekran avtomatik ravishda aylanadi."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Ekran eniga holatida qulflandi."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Ekran bo‘yiga holatida qulflandi."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Ekran endi avtomatik ravishda aylanadi."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Ekran yotiq holatda aylanmaydigan qilindi."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Ekran tik holatda aylanmaydigan qilindi."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Tush kurish"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Mobil internet"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Trafik sarfi"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Qolayotgan ma\'lumot"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Limitdan oshgan"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Cheklovga yetdi – internetdan foydalanish to‘xtatildi"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> foydalanilgan"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> chegarasi"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Ogohlantirish: <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Siz yaqinda ishlatgan ilova ekranlari bu yerda ko‘rinadi"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Ilova haqida ma’lumot"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"ilovaga qulflash"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"qidirish"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Izlash"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> uchun yuqoriga suring."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g> uchun chapga suring."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"“Bezovta qilmaslik” rejimi (uyg‘otkich ovozi o‘chirilgan)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Hech narsa bezovta qilmaydi, hatto uyg‘otkichlar ham."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Tanaffuslarsiz"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Faqat ustuvor tanaffuslar"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Keyingi uyg‘otkich: <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Keyingi uyg‘otkich: <xliff:g id="ALARM_TIME">%s</xliff:g>. Ovoz eshitilmaydi."</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Kam ahamiyatli bildirishnomalarni pastda ko‘rsatish"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Ochish uchun yana bosing"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Qulfdan chiqarish uchun yuqoriga suring"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Telefonni ochish uchun o‘ngga"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Kamerani ochish uchun chapga suring"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Uzluksiz ravishda"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Hech biri"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Ustuvorlik"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Barchasi"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Quvvat olmoqda (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>da to‘ladi)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Foydalanuvchini almashtirish"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Foydalanuvchini o‘zgartirish. Joriy foydalanuvchi – <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Profilni ko‘rsatish"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Foydalanuvchi qo‘shish"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Yangi foydalanuvchi"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Mehmon"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Yangi mehmon qo‘shish"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Mehmon rejimini o‘chirish"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Mehmon rejimidan chiqilsinmi?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Qurilmadagi mehmon rejimida saqlangan ma’lumotlar o‘chib ketadi."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Mehmon hisobi o‘chirib tashlansinmi?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Ushbu seansdagi barcha ilovalar va ma’lumotlar o‘chirib tashlanadi."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"O‘chirish"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Xush kelibsiz, mehmon!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 daqiqa"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d daqiqa"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 soat"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d soat"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Seansni davom ettirmoqchimisiz?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Boshidan boshlansin"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Ha, davom ettirilsin"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Yangi foyd-chi qo‘shilsinmi?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Yangi foydalanuvchi qo‘shilgach, o‘sha shaxs o‘z hududini sozlashi lozim bo‘ladi.\n\nHar qanday foydalanuvchi ilovalarni barcha foydalanuvchilar uchun yangilashi mumkin."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Quvvat tejash yoqilgan"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Unumdorlikni pasaytiradi va fonda int-dan foyd-ni cheklaydi"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Quvvat tejash funksiyasini o‘chiring"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Boshlash"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Bildirishnomalar yo‘q"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Qurilma kuzatilishi mumkin"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Profil kuzatilishi mumkin"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Tarmoq kuzatuv ostida bo‘lishi mumkin"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Qurilmalarni kuzatish"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Profilni kuzatish"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Tarmoqlarni kuzatish"</string>
-    <string name="open_app" msgid="4011771120339160755">"Ilovani ochish"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"VPN tarmog‘ini o‘chirish"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"VPN ulanishini uzish"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoringiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakatlaringizni kuzatishi mumkin.\n\nQo‘shimcha ma’lumot olish uchun administratoringizga murojaat qiling."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Siz “<xliff:g id="APPLICATION">%1$s</xliff:g>” ilovasiga VPN ulanishini o‘rnatishga ruxsat bergansiz.\n\nShuning uchun, ushbu ilova qurilmangiz va tarmoqdagi faolligingizni, jumladan, e-pochta, ilovalar va xavfsiz veb-saytlar bilan ishlashingizni kuzatishi mumkin."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Qurilma VPN tarmog‘iga ulangan (“<xliff:g id="APPLICATION">%1$s</xliff:g>”).\n\nXatti-harakatlaringiz VPN xizmati ta’minotchisiga ham ko‘rinadi."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakat-ni kuzatishi m-n. Qo‘shimcha ma’lumot olish u-n admin-ga murojaat qiling.\n\nSiz “<xliff:g id="APPLICATION">%2$s</xliff:g>” ilovasiga VPN ulanishini sozlash u-n ruxsat berdingiz. U ham tarmoqdagi faolligingizni kuzatishi mumkin."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakat-ni kuzatishi m-n. Qo‘shimcha ma’lumot olish u-n admin-ga murojaat qiling.\n\nSiz VPN tarmog‘iga ham ulangansiz (“<xliff:g id="APPLICATION">%2$s</xliff:g>”). VPN xizmati ta’minotchingiz ham tarmoqdagi faollingizni kuzatishi m-n."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Profil boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdministratoringiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakatlaringizni kuzatishi mumkin.\n\nQo‘shimcha ma’lumot olish uchun administratoringizga murojaat qiling."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfilingiz boshqaruvchisi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdministratoringiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakatlaringizni kuzatishi mumkin.\n\nQo‘shimcha ma’lumot olish uchun administratoringizga murojaat qiling."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Bu profil boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakatlaringizni kuzatishi mumkin. Qo‘shimcha ma’lumot olish uchun admin-ga murojaat qiling.\n\nSiz “<xliff:g id="APPLICATION">%2$s</xliff:g>” ilovasiga VPN ulanishini sozlash u-n ruxsat bergansiz. U ham tarmoqdagi faollikni kuzatishi m-n."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi harakatlaringizni kuzatishi mumkin. Qo‘shimcha ma’lumot olish u-n admin-ga murojaat qiling.\n\nSiz VPN tarmog‘iga (“<xliff:g id="APPLICATION">%2$s</xliff:g>”) ulangansiz. VPN xizmati ta’minotchingiz ham tarmoqdagi faollikni kuzatishi m-n."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil boshqaruvchisi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi har-ni kuzatishi m-n. Qo‘sh. ma’l. olish u-n admin-ga murojaat qiling.\n\nSiz “<xliff:g id="APPLICATION">%3$s</xliff:g>” ilovasiga VPN ulanishini sozlash u-n ruxsat bergansiz. U ham tarmoqdagi faollikni kuzatishi m-n."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Bu qurilma boshqaruvchisi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nProfil boshqaruvchisi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nAdmin-ngiz tarmoqdagi faollik – e-pochta, ilova va xavfsiz veb-saytlardagi har-ni kuzatishi m-n.\n\nQo‘sh. ma’l. olish u-n admin-ga murojaat qiling. Siz VPN tarmog‘iga (“<xliff:g id="APPLICATION">%3$s</xliff:g>”) ulangansiz. VPN xizmati ta’minotchingiz ham tarmoqdagi faollikni kuzatishi m-n."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Qurilma qo‘lda qulfdan chiqarilmaguncha qulflangan holatda qoladi"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Bildirishnomalarni tezroq oling"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ularni qulfdan chiqarishdan oldin ko‘ring"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Yo‘q, kerak emas"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Sozlash"</string>
+    <string name="muted_by" msgid="6147073845094180001">"“<xliff:g id="THIRD_PARTY">%1$s</xliff:g>” tomonidan ovozsiz qilingan"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-vi/strings.xml b/packages/SystemUI/res/values-vi/strings.xml
index acbcbaa..f0f1268 100644
--- a/packages/SystemUI/res/values-vi/strings.xml
+++ b/packages/SystemUI/res/values-vi/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Xóa"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Xóa khỏi danh sách"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Thông tin về ứng dụng"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Màn hình gần đây của bạn sẽ xuất hiện tại đây"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Loại bỏ các ứng dụng gần đây"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 ứng dụng gần đây"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Quay lại"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Trang chủ"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Màn hình gần đây"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Tìm kiếm"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Máy ảnh"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Điện thoại"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Mở khóa"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"mở khóa"</string>
+    <string name="phone_label" msgid="2320074140205331708">"mở điện thoại"</string>
+    <string name="camera_label" msgid="7261107956054836961">"mở máy ảnh"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Nút chuyển phương thức nhập."</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Nút thu phóng khả năng tương thích."</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Thu phóng màn hình lớn hơn hoặc nhỏ hơn."</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Tín hiệu Wi-Fi hai vạch."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Tín hiệu Wi-Fi ba vạch."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Tín hiệu Wi-Fi đầy đủ."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Đã kết nối với <xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Đã kết nối với <xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Không có WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX một vạch."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX hai vạch."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"Đã bật TeleTypewriter."</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Chuông rung."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Chuông im lặng."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Xóa bỏ <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> đã bị loại bỏ."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Bắt đầu <xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Đã loại bỏ thông báo."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Bóng thông báo."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Cài đặt nhanh."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Màn hình khóa."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Cài đặt"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Màn hình gần đây."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Người dùng <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"Đã tắt Wifi."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"Đã bật Wifi."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Di động <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Pin <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Chế độ trên máy bay <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Vị trí <xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Chế độ trên máy bay tắt."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Chế độ trên máy bay bật."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Đã tắt chế độ trên máy bay."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Đã bật chế độ trên máy bay."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"Bluetooth tắt."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"Bluetooth bật."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"Đang kết nối Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"Đã kết nối Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"Đã tắt Bluetooth."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"Đã bật Bluetooth."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Báo cáo vị trí tắt."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Báo cáo vị trí bật."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Đã tắt Báo cáo vị trí."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Đã bật Báo cáo vị trí."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"Báo thức được đặt cho <xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Đóng bảng điều khiển"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Nhiều thời gian hơn"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Ít thời gian hơn"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Đóng bảng điều khiển."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Nhiều thời gian hơn."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Ít thời gian hơn."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"Đèn pin tắt."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"Đèn pin bật."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"Đã tắt đèn pin."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"Đã bật đèn pin."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Đã tắt đảo màu."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Đã bật đảo màu."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"Đã tắt điểm phát sóng di động."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"Đã bật điểm phát sóng di động."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Đã ngừng truyền màn hình."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Độ sáng màn hình"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Dữ liệu 2G-3G bị tắt"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Dữ liệu 4G bị tắt"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Dữ liệu di động bị tắt"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Vị trí đặt bởi GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Yêu cầu về thông tin vị trí đang hoạt động"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Xóa tất cả thông báo."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Cài đặt"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Cài đặt thông báo"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"Cài đặt <xliff:g id="APP_NAME">%s</xliff:g>"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Màn hình sẽ xoay tự động."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Màn hình hiện bị khóa theo hướng ngang."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Màn hình hiện bị khóa theo hướng dọc."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Màn hình giờ đây sẽ xoay tự động."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Màn hình hiện bị khóa theo hướng ngang."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Màn hình hiện bị khóa theo hướng dọc."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Tủ trưng bày bánh ngọt"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Chế độ ngủ"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Dữ liệu di động"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Sử dụng dữ liệu"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Dữ liệu còn lại"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Vượt quá giới hạn"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Đã đạt tới giới hạn - sử dụng dữ liệu bị tạm ngừng"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"Đã sử dụng <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"Giới hạn <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"Cảnh báo <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Màn hình gần đây của bạn sẽ xuất hiện tại đây"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Thông tin ứng dụng"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"khóa trong ứng dụng"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"tìm kiếm"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Tìm kiếm"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Trượt lên để <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Trượt sang trái để <xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Không có gián đoạn, bao gồm báo thức"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Không có gián đoạn. Thậm chí không có cảnh báo."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Không có gián đoạn nào"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Chỉ các gián đoạn ưu tiên"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"Lần báo thức tiếp theo của bạn vào lúc <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Bạn sẽ không nghe thấy báo thức lúc <xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Thông báo ít khẩn cấp hơn bên dưới"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Chạm lại để mở"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Vuốt lên để mở khóa"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Vuốt sang phải để mở điện thoại"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Vuốt sang trái để mở máy ảnh"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Không giới hạn"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Không có"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Ưu tiên"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Tất cả"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Đang sạc (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> cho đến khi đầy)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Chuyển đổi người dùng"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Chuyển người dùng, người dùng hiện tại <xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Hiển thị hồ sơ"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Thêm người dùng"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Người dùng mới"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"Khách"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"Thêm khách"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Xóa phiên khách"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Bạn có muốn thoát khỏi phiên khách không?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Thoát khỏi phiên khách sẽ xóa dữ liệu cục bộ."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Xóa phiên khách?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Tất cả ứng dụng và dữ liệu trong phiên này sẽ bị xóa."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Xóa"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Chào mừng bạn trở lại!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Trong một phút"</item>
-    <item quantity="other" msgid="6924190729213550991">"Trong %d phút"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Trong một giờ"</item>
-    <item quantity="other" msgid="5408537517529822157">"Trong %d giờ"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Bạn có muốn tiếp tục phiên của mình không?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Bắt đầu lại"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Có, tiếp tục"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Thêm người dùng mới?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Khi bạn thêm người dùng mới, người dùng đó cần thiết lập dung lượng lưu trữ của mình.\n\nMọi người dùng đều có thể cập nhật ứng dụng cho tất cả người dùng khác."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Trình tiết kiệm pin đang bật"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Giảm hiệu suất và dữ liệu nền"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Tắt trình tiết kiệm pin"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Bắt đầu ngay"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Không có thông báo nào"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Thiết bị có thể được giám sát"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Hồ sơ có thể được giám sát"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Mạng có thể được giám sát"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Giám sát thiết bị"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Giám sát hồ sơ"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Giám sát mạng"</string>
-    <string name="open_app" msgid="4011771120339160755">"Mở ứng dụng"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Tắt VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Ngắt kết nối VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng và thiết bị của bạn, bao gồm email, ứng dụng và các trang web an toàn.\n\nĐể biết thêm thông tin, hãy liên hệ với quản trị viên của bạn."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Bạn đã cấp cho \"<xliff:g id="APPLICATION">%1$s</xliff:g>\" quyền thiết lập kết nối VPN.\n\nỨng dụng này có thể giám sát hoạt động mạng và thiết bị của bạn, bao gồm email, ứng dụng và các trang web an toàn."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Bạn đang kết nối với VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nNhà cung cấp dịch vụ VPN có thể giám sát hoạt động mạng và thiết bị của bạn bao gồm email, ứng dụng và các trang web an toàn."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng gồm email, ứng dụng và trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên.\n\nNgoài ra, bạn đã cấp cho \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" quyền thiết lập kết nối VPN. Ứng dụng này có thể giám sát hoạt động mạng."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng của bạn bao gồm email, ứng dụng và các trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên của bạn.\n\nNgoài ra, bạn được kết nối với VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Nhà cung cấp dịch vụ VPN cũng có thể giám sát hoạt động mạng."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Hồ sơ này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát thiết bị và hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn.\n\nĐể biết thêm thông tin, hãy liên hệ với quản trị viên của bạn."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHồ sơ của bạn được quản lý bởi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nQuản trị viên có thể giám sát thiết bị và hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn.\n\nĐể biết thêm thông tin, hãy liên hệ với quản trị viên của bạn."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Hồ sơ này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên của bạn.\n\nNgoài ra, bạn đã cấp cho \"<xliff:g id="APPLICATION">%2$s</xliff:g>\" quyền thiết lập kết nối VPN. Ứng dụng này cũng có thể giám sát hoạt động mạng."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Hồ sơ này được quản lý bởi:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên của bạn.\n\nNgoài ra, bạn được kết nối với VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Nhà cung cấp dịch vụ VPN của bạn cũng có thể giám sát hoạt động mạng."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHồ sơ của bạn được quản lý bởi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nQuản trị viên có thể giám sát hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên của bạn.\n\nNgoài ra, bạn đã cấp cho \"<xliff:g id="APPLICATION">%3$s</xliff:g>\" quyền thiết lập kết nối VPN. Ứng dụng này cũng có thể giám sát hoạt động mạng."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Thiết bị này được quản lý bởi:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nHồ sơ của bạn được quản lý bởi:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nQuản trị viên có thể giám sát thiết bị và hoạt động mạng của bạn, bao gồm email, ứng dụng và các trang web an toàn. Để biết thêm thông tin, hãy liên hệ với quản trị viên của bạn.\n\nNgoài ra, bạn được kết nối với VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Nhà cung cấp dịch vụ VPN của bạn cũng có thể giám sát hoạt động mạng."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Thiết bị sẽ vẫn bị khóa cho tới khi bạn mở khóa theo cách thủ công"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Nhận thông báo nhanh hơn"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Xem thông báo trước khi bạn mở khóa"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Ko, cảm ơn"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Thiết lập"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Do <xliff:g id="THIRD_PARTY">%1$s</xliff:g> tắt tiếng"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-xhdpi/dimens.xml b/packages/SystemUI/res/values-xhdpi/dimens.xml
new file mode 100644
index 0000000..144b225
--- /dev/null
+++ b/packages/SystemUI/res/values-xhdpi/dimens.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<resources>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+         fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">25%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">12.5%</fraction>
+
+    <dimen name="battery_margin_bottom">0dp</dimen>
+</resources>
diff --git a/packages/SystemUI/res/values-xxhdpi/dimens.xml b/packages/SystemUI/res/values-xxhdpi/dimens.xml
new file mode 100644
index 0000000..26c8437
--- /dev/null
+++ b/packages/SystemUI/res/values-xxhdpi/dimens.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+
+<resources>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+         fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">33%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">33%</fraction>
+</resources>
diff --git a/packages/SystemUI/res/values-zh-rCN/strings.xml b/packages/SystemUI/res/values-zh-rCN/strings.xml
index c09209c..97886c9 100644
--- a/packages/SystemUI/res/values-zh-rCN/strings.xml
+++ b/packages/SystemUI/res/values-zh-rCN/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"清除"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"从列表中删除"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"应用信息"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"您最近浏览过的屏幕会显示在此处"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"关闭最近运行的应用"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 个最近运行的应用"</item>
@@ -34,7 +33,7 @@
     <string name="status_bar_ongoing_events_title" msgid="1682504513316879202">"正在进行的"</string>
     <string name="status_bar_latest_events_title" msgid="6594767438577593172">"通知"</string>
     <string name="battery_low_title" msgid="6456385927409742437">"电池电量偏低"</string>
-    <string name="battery_low_percent_format" msgid="1077244949318261761">"还剩 <xliff:g id="NUMBER">%d%%</xliff:g>"</string>
+    <string name="battery_low_percent_format" msgid="1077244949318261761">"还剩<xliff:g id="NUMBER">%d%%</xliff:g>"</string>
     <string name="battery_low_percent_format_saver_started" msgid="6534746636002666456">"电量还剩<xliff:g id="NUMBER">%d%%</xliff:g>。节电助手已开启。"</string>
     <string name="invalid_charger" msgid="4549105996740522523">"不支持USB充电功能。\n只能使用随附的充电器充电。"</string>
     <string name="invalid_charger_title" msgid="3515740382572798460">"不支持USB充电。"</string>
@@ -75,17 +74,20 @@
     <string name="screenshot_failed_title" msgid="705781116746922771">"无法抓取屏幕截图。"</string>
     <string name="screenshot_failed_text" msgid="1260203058661337274">"无法进行屏幕截图,原因可能是存储空间不足,或者该应用或您所属的单位不允许执行此操作。"</string>
     <string name="usb_preference_title" msgid="6551050377388882787">"USB文件传输选项"</string>
-    <string name="use_mtp_button_title" msgid="4333504413563023626">"作为媒体播放器 (MTP) 装载"</string>
-    <string name="use_ptp_button_title" msgid="7517127540301625751">"作为摄像头 (PTP) 装载"</string>
+    <string name="use_mtp_button_title" msgid="4333504413563023626">"作为媒体播放器(MTP)装载"</string>
+    <string name="use_ptp_button_title" msgid="7517127540301625751">"作为相机(PTP)装载"</string>
     <string name="installer_cd_button_title" msgid="2312667578562201583">"安装适用于Mac的Android文件传输应用"</string>
     <string name="accessibility_back" msgid="567011538994429120">"返回"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"主屏幕"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"菜单"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"最近浏览过的屏幕"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"搜索"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"相机"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"电话"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"解锁"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"解锁"</string>
+    <string name="phone_label" msgid="2320074140205331708">"打开电话"</string>
+    <string name="camera_label" msgid="7261107956054836961">"打开相机"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"输入法切换按钮。"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"兼容性缩放按钮。"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"将小屏幕的图片放大在较大屏幕上显示。"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WLAN信号强度为两格。"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WLAN信号强度为三格。"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"WLAN信号满格。"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"已连接到<xliff:g id="WIFI">%s</xliff:g>。"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"已连接到<xliff:g id="BLUETOOTH">%s</xliff:g>。"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"无 WiMAX 信号。"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX 信号强度为一格。"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX 信号强度为两格。"</string>
@@ -153,29 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"电传打字机已启用。"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"振铃器振动。"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"振铃器静音。"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"移除<xliff:g id="APP">%s</xliff:g>。"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"已删除<xliff:g id="APP">%s</xliff:g>"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"正在启动<xliff:g id="APP">%s</xliff:g>。"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"已关闭通知。"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"通知栏。"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"快捷设置。"</string>
-    <!-- no translation found for accessibility_desc_settings (3417884241751434521) -->
-    <skip />
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"锁定屏幕。"</string>
+    <string name="accessibility_desc_settings" msgid="3417884241751434521">"设置"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"最近浏览过的屏幕。"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"用户:<xliff:g id="USER">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>,<xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WLAN已关闭。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WLAN已开启。"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"移动数据连接:<xliff:g id="SIGNAL">%1$s</xliff:g>,<xliff:g id="TYPE">%2$s</xliff:g>,<xliff:g id="NETWORK">%3$s</xliff:g>。"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"电池电量:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"飞行模式:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"蓝牙:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"位置信息服务<xliff:g id="STATE">%s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"飞行模式关闭。"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"飞行模式开启。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"飞行模式已关闭。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"飞行模式已开启。"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"蓝牙关闭。"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"蓝牙开启。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"蓝牙连接中。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"蓝牙已连接。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"蓝牙已关闭。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"蓝牙已开启。"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"位置报告功能关闭。"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"位置报告功能开启。"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"位置报告功能已关闭。"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"位置报告功能已开启。"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"闹钟已设置为:<xliff:g id="TIME">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"关闭面板"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"更长时间"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"更短时间"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"关闭面板。"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"延长时间。"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"缩短时间。"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"手电筒关闭。"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"手电筒打开。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"手电筒已关闭。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"手电筒已打开。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"颜色反转功能已关闭。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"颜色反转功能已开启。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"移动热点已关闭。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"移动热点已开启。"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"屏幕投射已停止。"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"屏幕亮度"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G数据网络已关闭"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G数据网络已关闭"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"移动数据网络已关闭"</string>
@@ -188,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"已通过GPS确定位置"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"应用发出了有效位置信息请求"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"清除所有通知。"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"设置"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"通知设置"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>设置"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"屏幕会自动旋转。"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"屏幕锁定为横向模式。"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"屏幕锁定为纵向模式。"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"屏幕将会自动旋转。"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"屏幕现已锁定为横向模式。"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"屏幕现已锁定为纵向模式。"</string>
     <string name="dessert_case" msgid="1295161776223959221">"甜品盒"</string>
     <string name="start_dreams" msgid="7219575858348719790">"互动屏保"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"有线网络"</string>
@@ -243,14 +273,13 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"移动数据网络"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"流量使用情况"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"剩余流量"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"超出上限"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"达到上限 - 已暂停流量使用"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"已使用<xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"上限为<xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g>警告"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"您最近浏览过的屏幕会显示在此处"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"应用信息"</string>
-    <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"开启单应用模式"</string>
+    <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"固定屏幕"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"搜索"</string>
     <string name="expanded_header_battery_charged" msgid="5945855970267657951">"充电完成"</string>
     <string name="expanded_header_battery_charging" msgid="205623198487189724">"正在充电"</string>
@@ -260,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"搜索"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"向上滑动以<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"向左滑动以<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"禁止打扰(包括闹钟)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"零打扰(甚至不发出闹钟提醒)。"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"禁止打扰"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"仅限优先打扰内容"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"下次闹钟响铃时间:<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -268,44 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"您在<xliff:g id="ALARM_TIME">%s</xliff:g>将不会听到闹钟响铃"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"不太紧急的通知会显示在下方"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"再次触摸即可打开"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"向上滑动即可解锁"</string>
     <string name="phone_hint" msgid="3101468054914424646">"向右滑动可打开拨号界面"</string>
     <string name="camera_hint" msgid="5241441720959174226">"向左滑动可打开相机"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"无限期"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"无"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"优先"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"全部"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"正在充电(还需<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>充满)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"切换用户"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"切换用户,当前用户为<xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"显示个人资料"</string>
     <string name="user_add_user" msgid="5110251524486079492">"添加用户"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"新用户"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"访客"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
-    <!-- no translation found for guest_exit_guest (7187359342030096885) -->
-    <skip />
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"要退出访客模式吗?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"退出访客模式将移除本地数据。"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"添加访客"</string>
+    <string name="guest_exit_guest" msgid="7187359342030096885">"移除访客"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"要移除访客吗?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"此会话中的所有应用和数据都将被删除。"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"移除"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"访客,欢迎回来!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1分钟"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d分钟"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1小时"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d小时"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"要继续您的会话吗?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"重新开始"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"是,继续"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"要添加新用户吗?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"当您添加新用户时,该用户必须设置自己的空间。\n\n任何用户均可为其他所有用户更新应用。"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"节电助手已开启"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"降低性能并限制后台流量"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"关闭节电助手"</string>
@@ -317,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"立即开始"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"没有通知"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"设备可能会受到监控"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"资料可能会受到监控"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"网络可能会受到监控"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"设备监测"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"资料监控"</string>
     <string name="monitoring_title" msgid="169206259253048106">"网络监控"</string>
-    <string name="open_app" msgid="4011771120339160755">"打开应用"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"关闭VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"断开VPN连接"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的设备和网络活动,包括收发电子邮件、使用应用和浏览安全网站。\n\n若要了解详情,请与您的管理员联系。"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"您已授权“<xliff:g id="APPLICATION">%1$s</xliff:g>”设置VPN连接。\n\n此应用可以监控您的设备和网络活动,包括收发电子邮件、使用应用和浏览安全网站。"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"您已连接到VPN(“<xliff:g id="APPLICATION">%1$s</xliff:g>”)。\n\n您的VPN服务提供商可以监控您的设备和网络活动,包括收发电子邮件、使用应用和浏览安全网站。"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已授权“<xliff:g id="APPLICATION">%2$s</xliff:g>”设置VPN连接。此应用也可以监控网络活动。"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已连接到VPN(“<xliff:g id="APPLICATION">%2$s</xliff:g>”)。您的VPN服务提供商也可以监控您的网络活动。"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"此资料由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的设备和网络活动,包括收发电子邮件、使用应用和浏览安全网站。\n\n若要了解详情,请与您的管理员联系。"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的资料由以下单位管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理员可以监控您的设备和网络活动,包括收发电子邮件、使用应用和浏览安全网站。\n\n若要了解详情,请与您的管理员联系。"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"此资料由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已授权“<xliff:g id="APPLICATION">%2$s</xliff:g>”设置VPN连接。此应用也可以监控网络活动。"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"此资料由以下单位管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已连接到VPN(“<xliff:g id="APPLICATION">%2$s</xliff:g>”)。您的VPN服务提供商也可以监控您的网络活动。"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的资料由以下单位管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已授权“<xliff:g id="APPLICATION">%3$s</xliff:g>”设置VPN连接。此应用也可以监控网络活动。"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"此设备由以下单位管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的资料由以下单位管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理员可以监控您的网络活动,包括收发电子邮件、使用应用和浏览安全网站。若要了解详情,请与您的管理员联系。\n\n此外,您已连接到VPN(“<xliff:g id="APPLICATION">%3$s</xliff:g>”)。您的VPN服务提供商也可以监控您的网络活动。"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"在您手动解锁之前,设备会保持锁定状态"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"更快捷地查看通知"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"无需解锁即可查看通知"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"不用了"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"设置"</string>
+    <string name="muted_by" msgid="6147073845094180001">"已被<xliff:g id="THIRD_PARTY">%1$s</xliff:g>设为静音"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-zh-rHK/strings.xml b/packages/SystemUI/res/values-zh-rHK/strings.xml
index 26b6aa0..31191c1 100644
--- a/packages/SystemUI/res/values-zh-rHK/strings.xml
+++ b/packages/SystemUI/res/values-zh-rHK/strings.xml
@@ -19,12 +19,11 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="7164937344850004466">"系統用戶介面"</string>
+    <string name="app_label" msgid="7164937344850004466">"系統使用者介面"</string>
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"清除"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"從清單中移除"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"應用程式資訊"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"您最近的螢幕顯示在這裡"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"關閉最近使用的應用程式"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 個最近使用的應用程式"</item>
@@ -40,9 +39,9 @@
     <string name="invalid_charger_title" msgid="3515740382572798460">"不支援 USB 充電功能。"</string>
     <string name="invalid_charger_text" msgid="5474997287953892710">"僅限使用裝置隨附的充電器。"</string>
     <string name="battery_low_why" msgid="4553600287639198111">"設定"</string>
-    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"要開啟節約電池用量模式嗎?"</string>
+    <string name="battery_saver_confirmation_title" msgid="5299585433050361634">"要開啟省電模式嗎?"</string>
     <string name="battery_saver_confirmation_ok" msgid="7507968430447930257">"開啟"</string>
-    <string name="battery_saver_start_action" msgid="5576697451677486320">"開啟節約電池用量模式"</string>
+    <string name="battery_saver_start_action" msgid="5576697451677486320">"開啟省電模式"</string>
     <string name="status_bar_settings_settings_button" msgid="3023889916699270224">"設定"</string>
     <string name="status_bar_settings_wifi_button" msgid="1733928151698311923">"Wi-Fi"</string>
     <string name="status_bar_settings_airplane" msgid="4879879698500955300">"飛行模式"</string>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"返回"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"首頁"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"選單"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"最近的螢幕"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"搜尋"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"相機"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"電話"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"解鎖"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"解鎖"</string>
+    <string name="phone_label" msgid="2320074140205331708">"開啟電話"</string>
+    <string name="camera_label" msgid="7261107956054836961">"開啟相機"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"切換輸入法按鈕。"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"相容性縮放按鈕。"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"將較小螢幕的畫面放大在較大螢幕上顯示。"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"WiFi 訊號強度為兩格。"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"WiFi 訊號強度為三格。"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"WiFi 訊號已滿。"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"已連線至<xliff:g id="WIFI">%s</xliff:g>。"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"已連線至<xliff:g id="BLUETOOTH">%s</xliff:g>。"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"沒有 WiMAX 訊號。"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX 訊號強度一格。"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX 訊號強度兩格。"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter (TTY) 已啟用。"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"鈴聲震動。"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"鈴聲靜音。"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"關閉「<xliff:g id="APP">%s</xliff:g>」。"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"「<xliff:g id="APP">%s</xliff:g>」已關閉。"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"正在啟動「<xliff:g id="APP">%s</xliff:g>」。"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"通知已關閉。"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"通知欄。"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"快速設定。"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"上鎖畫面。"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"設定"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
-    <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"用戶:<xliff:g id="USER">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>、<xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"最近的螢幕。"</string>
+    <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"使用者:<xliff:g id="USER">%s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WiFi 已關閉。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WiFi 已開啟。"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"流動數據連線:<xliff:g id="SIGNAL">%1$s</xliff:g>、<xliff:g id="TYPE">%2$s</xliff:g>、<xliff:g id="NETWORK">%3$s</xliff:g>。"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"電池電量:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"飛航模式:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"藍牙:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"定位服務<xliff:g id="STATE">%s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"飛行模式已關閉。"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"飛行模式已開啟。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"飛行模式已關閉。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"飛行模式已開啟。"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"藍牙已關閉。"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"藍牙已開啟。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"正在建立藍牙連線。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"藍牙連線已建立。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"藍牙已關閉。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"藍牙已開啟。"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"位置報告已關閉。"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"位置報告已開啟。"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"位置報告已關閉。"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"位置報告已開啟。"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"鬧鐘已設定為:<xliff:g id="TIME">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"關閉面板"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"更多時間"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"較少時間"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"關閉面板。"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"增加時間。"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"減少時間。"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"閃光燈已關閉。"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"閃光燈已開啟。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"閃光燈已關閉。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"閃光燈已開啟。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"色彩反轉模式已關閉。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"色彩反轉模式已開啟。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"流動熱點已關閉。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"流動熱點已開啟。"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"已停止投放螢幕。"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"顯示光暗度"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G 數據連線已關閉"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G 數據連線已關閉"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"流動數據連線已關閉"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS 已定位"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"位置要求啟動中"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"清除所有通知。"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"設定"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"通知設定"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>設定"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"螢幕會自動旋轉。"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"螢幕已鎖定為橫向模式。"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"螢幕已鎖定為垂直模式。"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"螢幕現在會自動旋轉。"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"螢幕現已鎖定為橫向模式"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"螢幕現已鎖定為縱向模式。"</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Daydream"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"以太網"</string>
@@ -215,8 +246,8 @@
     <string name="quick_settings_settings_label" msgid="5326556592578065401">"設定"</string>
     <string name="quick_settings_time_label" msgid="4635969182239736408">"時間"</string>
     <string name="quick_settings_user_label" msgid="5238995632130897840">"我"</string>
-    <string name="quick_settings_user_title" msgid="4467690427642392403">"用戶"</string>
-    <string name="quick_settings_user_new_user" msgid="9030521362023479778">"新用戶"</string>
+    <string name="quick_settings_user_title" msgid="4467690427642392403">"使用者"</string>
+    <string name="quick_settings_user_new_user" msgid="9030521362023479778">"新使用者"</string>
     <string name="quick_settings_wifi_label" msgid="9135344704899546041">"Wi-Fi"</string>
     <string name="quick_settings_wifi_not_connected" msgid="7171904845345573431">"未連線"</string>
     <string name="quick_settings_wifi_no_network" msgid="2221993077220856376">"沒有網絡"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"流動數據"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"數據用量"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"剩餘資料"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"超過上限"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"達到流量上限:已暫停使用數據連線"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"已使用 <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"上限為 <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> 警告"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"您最近的螢幕顯示在這裡"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"應用程式資料"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"應用程式鎖定"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"搜尋"</string>
@@ -259,54 +289,42 @@
     <string name="description_target_search" msgid="3091587249776033139">"搜尋"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"向上滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"向左滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"不允許干擾 (包含鬧鐘)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"不干擾 (即使鬧鐘也不例外)。"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"不允許干擾"</string>
-    <string name="zen_important_interruptions" msgid="3477041776609757628">"僅限優先干擾"</string>
+    <string name="zen_important_interruptions" msgid="3477041776609757628">"只限重要干擾"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"下次鬧鐘時間:<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_information_day_time" msgid="8422733576255047893">"下次鬧鐘時間:<xliff:g id="ALARM_DAY_AND_TIME">%s</xliff:g>"</string>
     <string name="zen_alarm_warning" msgid="6873910860111498041">"您不會聽到<xliff:g id="ALARM_TIME">%s</xliff:g> 的鬧鐘"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"還有 <xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g> 則通知"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"不太緊急的通知會在下方顯示"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"再次輕觸即可開啟"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"向上快速滑動即可解鎖"</string>
     <string name="phone_hint" msgid="3101468054914424646">"向右快速滑動即可使用手機功能"</string>
     <string name="camera_hint" msgid="5241441720959174226">"向左快速滑動即可使用相機功能"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"無限期"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"無"</string>
-    <string name="interruption_level_priority" msgid="6517366750688942030">"優先順序"</string>
+    <string name="interruption_level_priority" msgid="6517366750688942030">"重要"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"全部"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"充電中 (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>後完成充電)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"切換使用者"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"切換使用者,目前使用者是<xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"顯示個人檔案"</string>
     <string name="user_add_user" msgid="5110251524486079492">"新增使用者"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"新使用者"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"訪客"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"新增訪客"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"移除訪客"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"要結束訪客工作階段嗎?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"結束訪客工作階段後,本機資料將被移除。"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"移除訪客?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"這個工作階段中的所有應用程式和資料都會被刪除。"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"移除"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"訪客您好,歡迎回來!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 分鐘"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d 分鐘"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 小時"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d 小時"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"您要繼續您的工作階段嗎?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"重新開始"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"是的,請繼續"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"新增使用者?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"新增的使用者需要自行設定個人空間。\n\n任何使用者均可為其他所有使用者更新應用程式。"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"省電模式已開啟"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"降低效能並限制背景數據傳輸"</string>
-    <string name="battery_saver_notification_action_text" msgid="109158658238110382">"關閉節約電池用量模式"</string>
+    <string name="battery_saver_notification_action_text" msgid="109158658238110382">"關閉省電模式"</string>
     <string name="battery_level_template" msgid="1609636980292580020">"<xliff:g id="LEVEL">%d</xliff:g>%%"</string>
     <string name="notification_hidden_text" msgid="1135169301897151909">"內容已隱藏"</string>
     <string name="media_projection_dialog_text" msgid="3071431025448218928">"<xliff:g id="APP_SEEKING_PERMISSION">%s</xliff:g> 將開始擷取您的螢幕上顯示的內容。"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"立即開始"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"沒有通知"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"裝置可能會受到監控"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"個人檔案可能受到監控"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"網絡可能會受到監控"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"裝置監控"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"個人檔案監控"</string>
     <string name="monitoring_title" msgid="169206259253048106">"網絡監控"</string>
-    <string name="open_app" msgid="4011771120339160755">"開啟應用程式"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"停用 VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"中斷 VPN 連線"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"這部裝置由下列機構管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n。您的管理員可以監控您的裝置和網絡活動,包括收發電郵、使用應用程式和瀏覽安全網站。\n\n如需更多資料,請與您的管理員聯絡。"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"您已授權「<xliff:g id="APPLICATION">%1$s</xliff:g>」設定 VPN 連線。\n\n這個應用程式可以監控您的裝置和網絡活動,包括收發電郵、使用應用程式和瀏覽安全網站。"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"您已連線至 VPN (「<xliff:g id="APPLICATION">%1$s</xliff:g>」)。\n\n您的 VPN 服務供應商可以監控您的裝置和網絡活動,包括收發電郵、使用應用程式和瀏覽安全網站。"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"這部裝置由下列網域管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>。\n\n您的管理員可以監控您的網絡活動,包括收發電郵、使用應用程式和瀏覽安全網站。如需更多資料,請與您的管理員聯絡。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%2$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網絡活動。"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"這部裝置由下列網域管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>。\n\n您的管理員可以監控您的網絡活動,包括收發電郵、使用應用程式和瀏覽安全網站。如需更多資料,請與您的管理員聯絡。\n\n同時,您的裝置已連線至 VPN (「<xliff:g id="APPLICATION">%2$s</xliff:g>」),因此您的 VPN 服務供應商也能監控您的網絡活動。"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"這個個人檔案的管理機構:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的裝置和網絡活動,包括電郵、應用程式及安全網站。\n\n如需瞭解詳情,請聯絡您的管理員。"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"這部裝置的管理機構:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的個人檔案的管理機構:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的裝置和網絡活動,包括電郵、應用程式及安全網站。\n\n如需瞭解詳情,請聯絡您的管理員。"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"這個個人檔案的管理機構:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的網絡活動,包括電郵、應用程式及安全網站。如需瞭解詳情,請聯絡您的管理員。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%2$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網絡活動。"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"這個個人檔案的管理機構:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的網絡活動,包括電郵、應用程式及安全網站。如需瞭解詳情,請聯絡您的管理員。\n\n同時,由於您的裝置已與 VPN (「<xliff:g id="APPLICATION">%2$s</xliff:g>」) 連線,因此您的 VPN 服務供應商也能監控您的網絡活動。"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"這部裝置的管理機構:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的個人檔案的管理機構:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的網絡活動,包括電郵、應用程式及安全網站。如需瞭解詳情,請聯絡您的管理員。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%3$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網絡活動。"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"這部裝置的管理機構:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的個人檔案的管理機構:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的網絡活動,包括電郵、應用程式及安全網站。如需瞭解詳情,請聯絡您的管理員。\n\n同時,由於您的裝置已與 VPN (「<xliff:g id="APPLICATION">%3$s</xliff:g>」) 連線,因此您的 VPN 服務供應商也能監控您的網絡活動。"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"裝置將保持上鎖,直到您手動解鎖"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"更快取得通知"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"解鎖前顯示"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"不用了,謝謝"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"設定"</string>
+    <string name="muted_by" msgid="6147073845094180001">"靜音設定者:<xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-zh-rTW/strings.xml b/packages/SystemUI/res/values-zh-rTW/strings.xml
index 4a82dc7..f6f8620 100644
--- a/packages/SystemUI/res/values-zh-rTW/strings.xml
+++ b/packages/SystemUI/res/values-zh-rTW/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"清除"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"從清單中移除"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"應用程式資訊"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"您最近的螢幕會顯示在這裡"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"關閉最近使用的應用程式"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"1 個最近使用的應用程式"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"返回"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"主螢幕"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"選單"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"最近的螢幕"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"搜尋"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"相機"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"電話"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"解除鎖定"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"解除鎖定"</string>
+    <string name="phone_label" msgid="2320074140205331708">"開啟電話"</string>
+    <string name="camera_label" msgid="7261107956054836961">"開啟攝影機"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"切換輸入法按鈕。"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"相容性縮放按鈕。"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"將較小螢幕的畫面放大在較大螢幕上顯示。"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Wi-Fi 訊號強度兩格。"</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Wi-Fi 訊號強度三格。"</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Wi-Fi 訊號滿格。"</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"已連線至<xliff:g id="WIFI">%s</xliff:g>。"</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"已連線至<xliff:g id="BLUETOOTH">%s</xliff:g>。"</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"沒有 WiMAX 訊號。"</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"WiMAX 訊號一格。"</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"WiMAX 訊號兩格。"</string>
@@ -153,28 +157,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"TeleTypewriter (TTY) 已啟用。"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"鈴聲震動。"</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"鈴聲靜音。"</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"關閉「<xliff:g id="APP">%s</xliff:g>」。"</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"「<xliff:g id="APP">%s</xliff:g>」已關閉。"</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"正在啟動「<xliff:g id="APP">%s</xliff:g>」。"</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"已關閉通知。"</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"通知欄。"</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"快速設定。"</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"螢幕鎖定。"</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"設定"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"最近的螢幕。"</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"使用者:<xliff:g id="USER">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>,<xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"WiFi 已關閉。"</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"WiFi 已開啟。"</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"行動數據連線:<xliff:g id="SIGNAL">%1$s</xliff:g>,<xliff:g id="TYPE">%2$s</xliff:g>,<xliff:g id="NETWORK">%3$s</xliff:g>。"</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"電池電量:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"飛航模式:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"藍牙:<xliff:g id="STATE">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"定位服務<xliff:g id="STATE">%s</xliff:g>。"</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"飛航模式已關閉。"</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"飛航模式已開啟。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"飛航模式已關閉。"</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"飛航模式已開啟。"</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"藍牙已關閉。"</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"藍牙已開啟。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"正在建立藍牙連線。"</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"藍牙連線已建立。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"藍牙已關閉。"</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"藍牙已開啟。"</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"位置回報設定已關閉。"</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"位置回報設定已開啟。"</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"位置回報設定已關閉。"</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"位置回報設定已開啟。"</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"鬧鐘已設定為:<xliff:g id="TIME">%s</xliff:g>。"</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"關閉面板"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"更多時間"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"更少時間"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"關閉面板。"</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"增加時間。"</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"減少時間。"</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"閃光燈已關閉。"</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"閃光燈已開啟。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"閃光燈已關閉。"</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"閃光燈已開啟。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"色彩反轉模式已關閉。"</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"色彩反轉模式已開啟。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"可攜式無線基地台已關閉。"</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"可攜式無線基地台已開啟。"</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"已停止投放螢幕。"</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"螢幕亮度"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"2G-3G 數據連線已關閉"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"4G 數據連線已關閉"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"行動數據連線已關閉"</string>
@@ -187,10 +214,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"GPS 已定位"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"有位置資訊要求"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"清除所有通知。"</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"設定"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"通知設定"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g>設定"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"螢幕會自動旋轉。"</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"螢幕已鎖定為橫向模式。"</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"螢幕已鎖定為垂直模式。"</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"螢幕現在會自動旋轉。"</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"螢幕現已鎖定為橫向模式。"</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"螢幕現已鎖定為縱向模式。"</string>
     <string name="dessert_case" msgid="1295161776223959221">"Dessert Case"</string>
     <string name="start_dreams" msgid="7219575858348719790">"休眠模式"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"乙太網路"</string>
@@ -242,12 +273,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"行動數據"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"數據用量"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"剩餘資料"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"超過上限"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"達到流量上限:已暫停使用數據連線"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"已使用 <xliff:g id="DATA_USED">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"上限為 <xliff:g id="DATA_LIMIT">%s</xliff:g>"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> 警告"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"您最近的螢幕會顯示在這裡"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"應用程式資訊"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"應用程式鎖定"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"搜尋"</string>
@@ -259,7 +289,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"搜尋"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"向上滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
     <string name="description_direction_left" msgid="7207478719805562165">"向左滑動即可<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>。"</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"不允許干擾 (包含鬧鐘)"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"不干擾 (即使鬧鐘也不例外)。"</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"不允許干擾"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"僅限優先干擾"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"下次鬧鐘時間:<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -267,43 +297,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"您不會聽到<xliff:g id="ALARM_TIME">%s</xliff:g> 的鬧鐘"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"還有 <xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g> 則通知"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"較不緊急的通知會顯示在下方"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"再次輕觸即可開啟"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"向上滑動即可解鎖"</string>
     <string name="phone_hint" msgid="3101468054914424646">"向左滑動可使用手機功能"</string>
     <string name="camera_hint" msgid="5241441720959174226">"向左滑動可使用相機功能"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"無限期"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"無"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"優先"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"全部"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"充電中 (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g>後充飽)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"切換使用者"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"切換使用者,目前使用者是<xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"顯示設定檔"</string>
     <string name="user_add_user" msgid="5110251524486079492">"新增使用者"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"新使用者"</string>
     <string name="guest_nickname" msgid="8059989128963789678">"訪客"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_new_guest" msgid="600537543078847803">"新增邀請對象"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"移除訪客"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"結束訪客工作階段?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"訪客工作階段結束後,本機資料將遭到刪除。"</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"移除訪客?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"這個工作階段中的所有應用程式和資料都會遭到刪除。"</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"移除"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"訪客您好,歡迎回來!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"1 分鐘"</item>
-    <item quantity="other" msgid="6924190729213550991">"%d 分鐘"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"1 小時"</item>
-    <item quantity="other" msgid="5408537517529822157">"%d 小時"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"您要繼續這個工作階段嗎?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"重新開始"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"是,請繼續"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"新增使用者?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"新增的使用者需要自行設定個人空間。\n\n任何使用者皆可為其他所有使用者更新應用程式。"</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"節約耗電量模式已啟用"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"降低效能並限制背景數據傳輸"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"關閉節約耗電量模式"</string>
@@ -315,16 +333,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"立即開始"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"沒有通知"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"裝置可能會受到監控"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"設定檔可能會受到監控"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"網路可能會受到監控"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"裝置監控"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"設定檔監控"</string>
     <string name="monitoring_title" msgid="169206259253048106">"網路監控"</string>
-    <string name="open_app" msgid="4011771120339160755">"開啟應用程式"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"停用 VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"中斷 VPN 連線"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"這個裝置由下列機構管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的裝置和網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。\n\n如需詳細資訊,請與您的管理員聯絡。"</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"您已授權「<xliff:g id="APPLICATION">%1$s</xliff:g>」設定 VPN 連線。\n\n這個應用程式可以監控您的裝置和網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。"</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"您已連線至 VPN (「<xliff:g id="APPLICATION">%1$s</xliff:g>」)。\n\n您的 VPN 服務供應商可以監控您的裝置和網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。"</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"這個裝置由下列網域管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>。\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請與您的管理員聯絡。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%2$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網路活動。"</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"這個裝置由下列網域管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>。\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請與您的管理員聯絡。\n\n同時,由於您的裝置已連線至 VPN (「<xliff:g id="APPLICATION">%2$s</xliff:g>」),因此您的 VPN 服務供應商也能監控您的網路活動。"</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"這個設定檔由下列機構管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的裝置和網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。\n\n如需詳細資訊,請洽您的管理員。"</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"這個裝置由下列機構管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的設定檔由下列機構管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。\n\n如需詳細資訊,請洽您的管理員。"</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"這個設定檔由下列機構管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請洽您的管理員。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%2$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網路活動。"</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"這個設定檔由下列機構管理:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請洽您的管理員。\n\n同時,由於您的裝置已連線至 VPN (「<xliff:g id="APPLICATION">%2$s</xliff:g>」),因此您的 VPN 服務供應商也能監控您的網路活動。"</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"這個裝置由下列機構管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的設定檔由下列機構管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請洽您的管理員。\n\n同時,由於您已授權「<xliff:g id="APPLICATION">%3$s</xliff:g>」設定 VPN 連線,因此這個應用程式也能監控您的網路活動。"</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"這個裝置由下列機構管理:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\n您的設定檔由以下機構管理:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\n您的管理員可以監控您的網路活動,包括收發電子郵件、使用應用程式和瀏覽安全網站。如需詳細資訊,請洽您的管理員。\n\n同時,由於您的裝置已連線至 VPN (「<xliff:g id="APPLICATION">%3$s</xliff:g>」),因此您的 VPN 服務供應商也能監控您的網路活動。"</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"在您手動解鎖前,裝置將保持鎖定狀態"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"更快取得通知"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"解鎖前顯示"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"不用了,謝謝"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"設定"</string>
+    <string name="muted_by" msgid="6147073845094180001">"由 <xliff:g id="THIRD_PARTY">%1$s</xliff:g> 設為靜音"</string>
 </resources>
diff --git a/packages/SystemUI/res/values-zu/config.xml b/packages/SystemUI/res/values-zu/config.xml
new file mode 100644
index 0000000..4bbdea2
--- /dev/null
+++ b/packages/SystemUI/res/values-zu/config.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- 
+/*
+** Copyright 2009, 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.
+*/
+ -->
+
+<!--  These resources are around just to allow their values to be customized
+     for different hardware and product builds.  -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+    xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <string name="doze_pulse_schedule" msgid="1301215615981695214">"1s,10s,30s,60s,120s"</string>
+</resources>
diff --git a/packages/SystemUI/res/values-zu/strings.xml b/packages/SystemUI/res/values-zu/strings.xml
index 935ff63..d0cfb5b 100644
--- a/packages/SystemUI/res/values-zu/strings.xml
+++ b/packages/SystemUI/res/values-zu/strings.xml
@@ -23,8 +23,7 @@
     <string name="status_bar_clear_all_button" msgid="7774721344716731603">"Sula"</string>
     <string name="status_bar_recent_remove_item_title" msgid="6026395868129852968">"Susa ohlwini"</string>
     <string name="status_bar_recent_inspect_item_title" msgid="7793624864528818569">"Ulwazi lwensiza"</string>
-    <!-- no translation found for status_bar_no_recent_apps (7374907845131203189) -->
-    <skip />
+    <string name="status_bar_no_recent_apps" msgid="7374907845131203189">"Izikrini zakho zakamuva zivela lapha"</string>
     <string name="status_bar_accessibility_dismiss_recents" msgid="4576076075226540105">"Susa izinhlelo zokusebenza zakamumva"</string>
   <plurals name="status_bar_accessibility_recent_apps">
     <item quantity="one" msgid="5854176083865845541">"Insiza eyi-1 yakamumva"</item>
@@ -81,11 +80,14 @@
     <string name="accessibility_back" msgid="567011538994429120">"Emuva"</string>
     <string name="accessibility_home" msgid="8217216074895377641">"Ekhaya"</string>
     <string name="accessibility_menu" msgid="316839303324695949">"Imenyu"</string>
-    <!-- no translation found for accessibility_recent (1606470783629913980) -->
-    <skip />
+    <string name="accessibility_recent" msgid="1606470783629913980">"Izikrini zakamuva"</string>
     <string name="accessibility_search_light" msgid="1103867596330271848">"Sesha"</string>
     <string name="accessibility_camera_button" msgid="8064671582820358152">"Ikhamela"</string>
     <string name="accessibility_phone_button" msgid="6738112589538563574">"Ifoni"</string>
+    <string name="accessibility_unlock_button" msgid="128158454631118828">"Vula"</string>
+    <string name="unlock_label" msgid="8779712358041029439">"vula"</string>
+    <string name="phone_label" msgid="2320074140205331708">"vula ifoni"</string>
+    <string name="camera_label" msgid="7261107956054836961">"vula ikhamera"</string>
     <string name="accessibility_ime_switch_button" msgid="5032926134740456424">"Vula indlela yokungena yenkinobho"</string>
     <string name="accessibility_compatibility_zoom_button" msgid="8461115318742350699">"Inkinobho evumelekile yokusondeza"</string>
     <string name="accessibility_compatibility_zoom_example" msgid="4220687294564945780">"Sondeza kancane esikrinini esikhudlwana"</string>
@@ -112,6 +114,8 @@
     <string name="accessibility_wifi_two_bars" msgid="4994274250497262434">"Amabha amabili we-Wi-Fi."</string>
     <string name="accessibility_wifi_three_bars" msgid="3495755044276588384">"Amabha amathathu we-Wi-Fi."</string>
     <string name="accessibility_wifi_signal_full" msgid="6853561303586480376">"Isiginali ye-Wi-Fi igcwele."</string>
+    <string name="accessibility_wifi_name" msgid="7202151365171148501">"Xhuma ku-<xliff:g id="WIFI">%s</xliff:g>."</string>
+    <string name="accessibility_bluetooth_name" msgid="8441517146585531676">"Xhuma ku-<xliff:g id="BLUETOOTH">%s</xliff:g>."</string>
     <string name="accessibility_no_wimax" msgid="4329180129727630368">"Ayikho i-WiMAX."</string>
     <string name="accessibility_wimax_one_bar" msgid="4170994299011863648">"Ibha eyodwa ye-WiMAX."</string>
     <string name="accessibility_wimax_two_bars" msgid="9176236858336502288">"Amabha amabili we-WiMAX."</string>
@@ -151,28 +155,51 @@
     <string name="accessibility_tty_enabled" msgid="4613200365379426561">"i-TeleTypewriter inikwe amandla"</string>
     <string name="accessibility_ringer_vibrate" msgid="666585363364155055">"Ukudlidliza kweringa."</string>
     <string name="accessibility_ringer_silent" msgid="9061243307939135383">"Isikhali sithulile."</string>
+    <!-- no translation found for accessibility_casting (6887382141726543668) -->
+    <skip />
     <string name="accessibility_recents_item_will_be_dismissed" msgid="395770242498031481">"Cashisa i-<xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_recents_item_dismissed" msgid="6803574935084867070">"<xliff:g id="APP">%s</xliff:g> ivaliwe."</string>
     <string name="accessibility_recents_item_launched" msgid="7616039892382525203">"Iqala i-<xliff:g id="APP">%s</xliff:g>."</string>
     <string name="accessibility_notification_dismissed" msgid="854211387186306927">"Isaziso sichithiwe."</string>
     <string name="accessibility_desc_notification_shade" msgid="4690274844447504208">"Umthunzi wesaziso."</string>
     <string name="accessibility_desc_quick_settings" msgid="6186378411582437046">"Izilingiselelo ezisheshayo."</string>
+    <string name="accessibility_desc_lock_screen" msgid="5625143713611759164">"Khiya isikrini."</string>
     <string name="accessibility_desc_settings" msgid="3417884241751434521">"Izilungiselelo"</string>
-    <!-- no translation found for accessibility_desc_recent_apps (8376953390514779637) -->
-    <skip />
+    <string name="accessibility_desc_recent_apps" msgid="8376953390514779637">"Izikrini zakamuva."</string>
     <string name="accessibility_quick_settings_user" msgid="1104846699869476855">"Umsebenzisi <xliff:g id="USER">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_wifi" msgid="6099781031669728709">"<xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="NETWORK">%2$s</xliff:g>"</string>
+    <string name="accessibility_quick_settings_wifi" msgid="5518210213118181692">"<xliff:g id="SIGNAL">%1$s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_wifi_changed_off" msgid="8716484460897819400">"I-Wifi ivaliwe."</string>
+    <string name="accessibility_quick_settings_wifi_changed_on" msgid="6440117170789528622">"I-Wifi ivuliwe."</string>
     <string name="accessibility_quick_settings_mobile" msgid="4876806564086241341">"Iselula <xliff:g id="SIGNAL">%1$s</xliff:g>. <xliff:g id="TYPE">%2$s</xliff:g>. <xliff:g id="NETWORK">%3$s</xliff:g>."</string>
     <string name="accessibility_quick_settings_battery" msgid="1480931583381408972">"Ibhethri <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_airplane" msgid="4196876722090224753">"Imodi yendiza <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_bluetooth" msgid="5749054971341882340">"I-Bluetooth <xliff:g id="STATE">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_location" msgid="4577282329866813100">"Indawo i-<xliff:g id="STATE">%s</xliff:g>."</string>
+    <string name="accessibility_quick_settings_airplane_off" msgid="7786329360056634412">"Imodi yendiza ivaliwe."</string>
+    <string name="accessibility_quick_settings_airplane_on" msgid="6406141469157599296">"Imodi yendiza ivuliwe."</string>
+    <string name="accessibility_quick_settings_airplane_changed_off" msgid="66846307818850664">"Imodi yendiza ivaliwe."</string>
+    <string name="accessibility_quick_settings_airplane_changed_on" msgid="8983005603505087728">"Imodi yendiza ivuliwe."</string>
+    <string name="accessibility_quick_settings_bluetooth_off" msgid="2133631372372064339">"I-Bluetooth ivaliwe."</string>
+    <string name="accessibility_quick_settings_bluetooth_on" msgid="7681999166216621838">"I-Bluetooth ivuliwe."</string>
+    <string name="accessibility_quick_settings_bluetooth_connecting" msgid="6953242966685343855">"I-Bluetooth iyaxhuma."</string>
+    <string name="accessibility_quick_settings_bluetooth_connected" msgid="4306637793614573659">"I-Bluetooth ixhunyiwe."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_off" msgid="2730003763480934529">"I-Bluetooth ivaliwe."</string>
+    <string name="accessibility_quick_settings_bluetooth_changed_on" msgid="8722351798763206577">"I-Bluetooth ivuliwe."</string>
+    <string name="accessibility_quick_settings_location_off" msgid="5119080556976115520">"Ukubikwa kwendawo kuvaliwe."</string>
+    <string name="accessibility_quick_settings_location_on" msgid="5809937096590102036">"Ukubikwa kwendawo kuvuliwe."</string>
+    <string name="accessibility_quick_settings_location_changed_off" msgid="8526845571503387376">"Ukubikwa kwendawo kuvaliwe."</string>
+    <string name="accessibility_quick_settings_location_changed_on" msgid="339403053079338468">"Ukubikwa kwendawo kuvuliwe."</string>
     <string name="accessibility_quick_settings_alarm" msgid="3959908972897295660">"I-alamu isethiwe ngo-<xliff:g id="TIME">%s</xliff:g>."</string>
-    <string name="accessibility_quick_settings_close" msgid="2571790856136835943">"Vala iphaneli"</string>
-    <string name="accessibility_quick_settings_more_time" msgid="5778794273488176726">"Isikhathi esiningi"</string>
-    <string name="accessibility_quick_settings_less_time" msgid="101026945195230084">"Isikhathi esingaphansi"</string>
-    <!-- no translation found for accessibility_brightness (8003681285547803095) -->
-    <skip />
+    <string name="accessibility_quick_settings_close" msgid="3115847794692516306">"Vala iphaneli."</string>
+    <string name="accessibility_quick_settings_more_time" msgid="3659274935356197708">"Isikhathi esiningi."</string>
+    <string name="accessibility_quick_settings_less_time" msgid="2404728746293515623">"Isikhathi esincane."</string>
+    <string name="accessibility_quick_settings_flashlight_off" msgid="4936432000069786988">"I-Flashlight ivaliwe."</string>
+    <string name="accessibility_quick_settings_flashlight_on" msgid="2003479320007841077">"I-Flashlight ivuliwe."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_off" msgid="3303701786768224304">"I-Flashlight ivaliwe."</string>
+    <string name="accessibility_quick_settings_flashlight_changed_on" msgid="6531793301533894686">"I-Flashlight ivuliwe."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_off" msgid="4406577213290173911">"Ukufakwa kombhala kuvaliwe."</string>
+    <string name="accessibility_quick_settings_color_inversion_changed_on" msgid="6897462320184911126">"Ukufakwa kombhala kuvuliwe."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_off" msgid="5004708003447561394">"I-hotspot ivaliwe."</string>
+    <string name="accessibility_quick_settings_hotspot_changed_on" msgid="2890951609226476206">"I-hotspot ivuliwe."</string>
+    <string name="accessibility_casting_turned_off" msgid="1430668982271976172">"Ukusakaza kwesikrini kumisiwe."</string>
+    <string name="accessibility_brightness" msgid="8003681285547803095">"Bonisa ukukhanya"</string>
     <string name="data_usage_disabled_dialog_3g_title" msgid="2626865386971800302">"Idatha ye-2G-3G ivaliwe"</string>
     <string name="data_usage_disabled_dialog_4g_title" msgid="4629078114195977196">"Idatha ye-4G ivaliwe"</string>
     <string name="data_usage_disabled_dialog_mobile_title" msgid="5793456071535876132">"Idatha yeselula ivaliwe"</string>
@@ -185,10 +212,14 @@
     <string name="gps_notification_found_text" msgid="4619274244146446464">"Indawo ihlelwe i-GPS"</string>
     <string name="accessibility_location_active" msgid="2427290146138169014">"Izicelo zendawo ziyasebenza"</string>
     <string name="accessibility_clear_all" msgid="5235938559247164925">"Susa zonke izaziso."</string>
-    <string name="status_bar_notification_inspect_item_title" msgid="5386295743469882227">"Izilungiselelo"</string>
+    <string name="status_bar_notification_inspect_item_title" msgid="5668348142410115323">"Izilungiselelo zesaziso"</string>
+    <string name="status_bar_notification_app_settings_title" msgid="5525260160341558869">"<xliff:g id="APP_NAME">%s</xliff:g> izilungiselelo"</string>
     <string name="accessibility_rotation_lock_off" msgid="4062780228931590069">"Isikrini sizophenduka ngokuzenzakalela."</string>
     <string name="accessibility_rotation_lock_on_landscape" msgid="6731197337665366273">"Isikrini sikhiyelwe ngomumo we-landscape."</string>
     <string name="accessibility_rotation_lock_on_portrait" msgid="5809367521644012115">"Isikrini sikhiyelwe ngomumo we-portrait."</string>
+    <string name="accessibility_rotation_lock_off_changed" msgid="8134601071026305153">"Isikrini manje sizophenduka ngokuzenzakalelayo."</string>
+    <string name="accessibility_rotation_lock_on_landscape_changed" msgid="3135965553707519743">"Isikrini okwamanje sivaliwe ekujikelezeni okumile."</string>
+    <string name="accessibility_rotation_lock_on_portrait_changed" msgid="8922481981834012126">"Isikrini manje sikhiyelwe kumumo wokuma ngobude."</string>
     <string name="dessert_case" msgid="1295161776223959221">"Isikhwama soswidi"</string>
     <string name="start_dreams" msgid="7219575858348719790">"Ukuphupha emini"</string>
     <string name="ethernet_label" msgid="7967563676324087464">"I-Ethernet"</string>
@@ -240,12 +271,11 @@
     <string name="quick_settings_cellular_detail_title" msgid="8575062783675171695">"Idatha yeselula"</string>
     <string name="quick_settings_cellular_detail_data_usage" msgid="1964260360259312002">"Ukusetshenziswa kwedatha"</string>
     <string name="quick_settings_cellular_detail_remaining_data" msgid="722715415543541249">"Idatha esele"</string>
-    <string name="quick_settings_cellular_detail_over_limit" msgid="967669665390990427">"Ingaphezulu komkhawulo"</string>
+    <string name="quick_settings_cellular_detail_over_limit" msgid="3242930457130971204">"Umkhawulo ufinyelelwe – ukusetshenziswa kwedatha kumisiwe okwesikhashana"</string>
     <string name="quick_settings_cellular_detail_data_used" msgid="1476810587475761478">"<xliff:g id="DATA_USED">%s</xliff:g> isetshenzisiwe"</string>
     <string name="quick_settings_cellular_detail_data_limit" msgid="56011158504994128">"<xliff:g id="DATA_LIMIT">%s</xliff:g> umkhawulo"</string>
     <string name="quick_settings_cellular_detail_data_warning" msgid="2440098045692399009">"<xliff:g id="DATA_LIMIT">%s</xliff:g> isexwayiso"</string>
-    <!-- no translation found for recents_empty_message (8682129509540827999) -->
-    <skip />
+    <string name="recents_empty_message" msgid="8682129509540827999">"Izikrini zakho zakamuva zivela lapha"</string>
     <string name="recents_app_info_button_label" msgid="2890317189376000030">"Ulwazi lohlelo lokusebenza"</string>
     <string name="recents_lock_to_app_button_label" msgid="4793991421811647489">"ukukhiya kuhlelo lokusebenza"</string>
     <string name="recents_search_bar_label" msgid="8074997400187836677">"sesha"</string>
@@ -257,7 +287,7 @@
     <string name="description_target_search" msgid="3091587249776033139">"Sesha"</string>
     <string name="description_direction_up" msgid="7169032478259485180">"Shelelisela ngenhla ku-<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
     <string name="description_direction_left" msgid="7207478719805562165">"Shelelisela ngakwesokunxele ku-<xliff:g id="TARGET_DESCRIPTION">%s</xliff:g>."</string>
-    <string name="zen_no_interruptions_with_warning" msgid="2522931836819051293">"Akukho ukuphazamisa, kufaka phakathi ama-alamu"</string>
+    <string name="zen_no_interruptions_with_warning" msgid="4396898053735625287">"Akukho ukuphazamiseka. Nama-alamu imbala."</string>
     <string name="zen_no_interruptions" msgid="7970973750143632592">"Azikho iziphazamiso"</string>
     <string name="zen_important_interruptions" msgid="3477041776609757628">"Iziphazamiso ezibalulekile kuphela"</string>
     <string name="zen_alarm_information_time" msgid="5235772206174372272">"I-alamu yakho elandelayo ingo<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
@@ -265,43 +295,31 @@
     <string name="zen_alarm_warning" msgid="6873910860111498041">"Ngeke uzwe i-alamu yakho ngo-<xliff:g id="ALARM_TIME">%s</xliff:g>"</string>
     <string name="keyguard_more_overflow_text" msgid="9195222469041601365">"+<xliff:g id="NUMBER_OF_NOTIFICATIONS">%d</xliff:g>"</string>
     <string name="speed_bump_explanation" msgid="1288875699658819755">"Izaziso ezingasheshi kakhulu ezingezansi"</string>
-    <!-- no translation found for notification_tap_again (8524949573675922138) -->
-    <skip />
+    <string name="notification_tap_again" msgid="8524949573675922138">"Thinta futhi ukuze uvule"</string>
     <string name="keyguard_unlock" msgid="8043466894212841998">"Swayiphela phezulu ukuze uvule"</string>
     <string name="phone_hint" msgid="3101468054914424646">"Swayiphela ngakwesokudla ukuze uthole ifoni"</string>
     <string name="camera_hint" msgid="5241441720959174226">"Swayiphela ngakwesokunxele ukuze uthole ikhamela"</string>
-    <string name="zen_mode_forever" msgid="4316804956488785559">"Unaphakade"</string>
     <string name="interruption_level_none" msgid="3831278883136066646">"Lutho"</string>
     <string name="interruption_level_priority" msgid="6517366750688942030">"Okubalulekile"</string>
     <string name="interruption_level_all" msgid="1330581184930945764">"Konke"</string>
     <string name="keyguard_indication_charging_time" msgid="1757251776872835768">"Iyashaja (<xliff:g id="CHARGING_TIME_LEFT">%s</xliff:g> ize igcwale)"</string>
-    <!-- no translation found for accessibility_multi_user_switch_switcher (7305948938141024937) -->
-    <skip />
-    <!-- no translation found for accessibility_multi_user_switch_quick_contact (3020367729287990475) -->
-    <skip />
+    <string name="accessibility_multi_user_switch_switcher" msgid="7305948938141024937">"Shintsha umsebenzisi"</string>
+    <string name="accessibility_multi_user_switch_switcher_with_current" msgid="8434880595284601601">"Shintsha umsebenzisi, umsebenzisi wamanje ngu-<xliff:g id="CURRENT_USER_NAME">%s</xliff:g>"</string>
+    <string name="accessibility_multi_user_switch_quick_contact" msgid="3020367729287990475">"Bonisa iphrofayela"</string>
     <string name="user_add_user" msgid="5110251524486079492">"Engeza umsebenzisi"</string>
     <string name="user_new_user_name" msgid="426540612051178753">"Umsebenzisi omusha"</string>
-    <string name="guest_nickname" msgid="8059989128963789678">"Isihambeli"</string>
-    <!-- no translation found for guest_new_guest (600537543078847803) -->
-    <skip />
+    <string name="guest_nickname" msgid="8059989128963789678">"Isivakashi"</string>
+    <string name="guest_new_guest" msgid="600537543078847803">"Engeza isivakashi"</string>
     <string name="guest_exit_guest" msgid="7187359342030096885">"Susa isivakashi"</string>
-    <string name="guest_exit_guest_dialog_title" msgid="7587460301980067285">"Phuma kusikhathi sesivakashi?"</string>
-    <string name="guest_exit_guest_dialog_message" msgid="10255285459589280">"Ukuphuma kusikhathi sesivakashi kuzosusa idatha yendawo."</string>
+    <string name="guest_exit_guest_dialog_title" msgid="8480693520521766688">"Susa isivakashi?"</string>
+    <string name="guest_exit_guest_dialog_message" msgid="4155503224769676625">"Zonke izinhlelo zokusebenza nedatha kulesi sikhathi zizosuswa."</string>
+    <string name="guest_exit_guest_dialog_remove" msgid="7402231963862520531">"Susa"</string>
     <string name="guest_wipe_session_title" msgid="6419439912885956132">"Siyakwamukela futhi, sivakashi!"</string>
-    <!-- no translation found for guest_wipe_session_message (8476238178270112811) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_wipe (5065558566939858884) -->
-    <skip />
-    <!-- no translation found for guest_wipe_session_dontwipe (1401113462524894716) -->
-    <skip />
-  <plurals name="zen_mode_duration_minutes">
-    <item quantity="one" msgid="9040808414992812341">"Iminithi elilodwa"</item>
-    <item quantity="other" msgid="6924190729213550991">"Amaminithi angu-%d"</item>
-  </plurals>
-  <plurals name="zen_mode_duration_hours">
-    <item quantity="one" msgid="3480040795582254384">"Ihora elilodwa"</item>
-    <item quantity="other" msgid="5408537517529822157">"Amahora angu-%d"</item>
-  </plurals>
+    <string name="guest_wipe_session_message" msgid="8476238178270112811">"Ingabe ufuna ukuqhubeka ngesikhathi sakho?"</string>
+    <string name="guest_wipe_session_wipe" msgid="5065558566939858884">"Qala phansi"</string>
+    <string name="guest_wipe_session_dontwipe" msgid="1401113462524894716">"Yebo, qhubeka"</string>
+    <string name="user_add_user_title" msgid="4553596395824132638">"Engeza umsebenzisi omusha?"</string>
+    <string name="user_add_user_message_short" msgid="2161624834066214559">"Uma ungeza umsebenzisi omusha, loyo muntu udinga ukusetha isikhala sakhe.\n\nNoma yimuphi umsebenzisi angabuyekeza izinhlelo zokusebenza kubo bonke abasebenzisi."</string>
     <string name="battery_saver_notification_title" msgid="237918726750955859">"Isilondolozi sebhethri sivuliwe"</string>
     <string name="battery_saver_notification_text" msgid="820318788126672692">"Sehlisa ukusebenza nedatha yasemuva"</string>
     <string name="battery_saver_notification_action_text" msgid="109158658238110382">"Vala isilondolozi sebhethri"</string>
@@ -313,16 +331,28 @@
     <string name="media_projection_action_text" msgid="8470872969457985954">"Qala manje"</string>
     <string name="empty_shade_text" msgid="708135716272867002">"Azikho izaziso"</string>
     <string name="device_owned_footer" msgid="3802752663326030053">"Idivayisi inganganyelwa"</string>
+    <string name="profile_owned_footer" msgid="8021888108553696069">"Iphrofayela ingaqashwa"</string>
     <string name="vpn_footer" msgid="2388611096129106812">"Inethiwekhi kungenzeka iqashiwe"</string>
     <string name="monitoring_title_device_owned" msgid="7121079311903859610">"Ukwengamela idivayisi"</string>
+    <string name="monitoring_title_profile_owned" msgid="6790109874733501487">"Ukuqapha iphrofayela"</string>
     <string name="monitoring_title" msgid="169206259253048106">"Ukuqashwa kwenethiwekhi"</string>
-    <string name="open_app" msgid="4011771120339160755">"Vula uhlelo lokusebenza"</string>
+    <string name="disable_vpn" msgid="4435534311510272506">"Khubaza i-VPN"</string>
     <string name="disconnect_vpn" msgid="1324915059568548655">"Nqamula i-VPN"</string>
     <string name="monitoring_description_device_owned" msgid="7512371572956715493">"Le divayisi iphethwe i-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmqondisi wakho angangamela idivayisi yakho nomsebenzi wenethiwekhi, kufaka phakathi ama-imeyili, izinhlelo zokusebenza, nnamawebhusayithi aphephile.\n\nNgolwazi olubanzi, xhumana nomqondisi wakho."</string>
     <string name="monitoring_description_vpn" msgid="7288268682714305659">"Unike i-\"<xliff:g id="APPLICATION">%1$s</xliff:g>\" imvume yokusetha uxhumo le-VPN.\n\nLolu hlelo lokusebenza lungangamela idivayisi yakho nomsebenzi wenethiwekhi, kufaka phakathi ama-imeyili, izinhlelo zokusebenza, namawebhusayithi aphephile."</string>
     <string name="monitoring_description_legacy_vpn" msgid="4740349017929725435">"Uxhumekile ku-VPN (\"<xliff:g id="APPLICATION">%1$s</xliff:g>\").\n\nUmhlinzeki wakho wesevisi ye-VPN angangamela idivayisi yakho nomsebenzi wenethiwekhi kufaka phakathi ama-imeyili, izinhlelo zokusebenza, namawebhusayithi aphephile."</string>
     <string name="monitoring_description_vpn_device_owned" msgid="696121105616356493">"Le divayisi iphethwe i-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmqondisi wakho uyakwazi ukwengamela umsebenzi wakho wenethiwekhi kufaka phakathi ama-imeyili, izinhlelo zokusebenza, namawebhusayithi aphephile. Ngolwazi olubanzi, xhumana nomqondisi wakho.\n\nFuthi, unike i-\"<xliff:g id="APPLICATION">%2$s</xliff:g>\" imvume yokusetha uxhumo le-VPN. Lolu hlelo lokusebenza lungangamela futhi umsebenzi wenethiwekhi."</string>
     <string name="monitoring_description_legacy_vpn_device_owned" msgid="649791650224064248">"Le divayisi iphathwe i-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmqondisi wakho uyakwazi ukwengamela umsebenzi wenethiwekhi yakho kufaka phakathi ama-imeyili, izinhlelo zokusebenza, namawebhusayithi aphephile. Ngolwazi olubanzi, xhumana nomqondisi wakho.\n\nFuthi, uxhumekile ku-VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Umhlinzeki wakho wesevisi ye-VPN angangamela futhi umsebenzi wenethiwekhi."</string>
-    <!-- no translation found for keyguard_indication_trust_disabled (7412534203633528135) -->
-    <skip />
+    <string name="monitoring_description_profile_owned" msgid="2370062794285691713">"Le phrofayela iphethwe yi-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmlawuli wakho angaqapha idivayisi yakho nomsebenzi wenethiwekhi, ofaka ama-imeyili, izinhlelo zokusebenza namawebhusayithi avikelekile.\n\nUkuze uthole olunye ulwazi, xhumana nomlawuli wakho."</string>
+    <string name="monitoring_description_device_and_profile_owned" msgid="8685301493845456293">"Le divayisi iphethwe yi-:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIphrofayela yakho iphethwe yi-:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUmlawuli wakho angaqapha idivayisi yakho kanye nomsebenzi wenethiwekhi, okufaka ama-imeyili, izinhlelo zokusebenza namawebhusayithi avikelekile.\n\nUkuze uthole olunye ulwazi, xhumana nomlawuli wakho."</string>
+    <string name="monitoring_description_vpn_profile_owned" msgid="847491346263295767">"Le phrofayela iphethwe yi-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmlawuli wakho uyakwazi ukuqapha umsebenzi wakho wenethiwekhi ofaka ama-imeyili, izinhlelo zokusebenza, namawebhusayithi avikelekile. Ukuze uthole olunye ulwazi, xhumana nomlawuli wakho.\n\nFuthi, unikeze i-\"<xliff:g id="APPLICATION">%2$s</xliff:g>\" imvume yokusetha ukuxhumeka kwe-VPN. Lolu hlelo lokusebenza lungaphinda luqaphe umsebenzi wakho."</string>
+    <string name="monitoring_description_legacy_vpn_profile_owned" msgid="4095516964132237051">"Le phrofayela iphethwe yi-:\n<xliff:g id="ORGANIZATION">%1$s</xliff:g>\n\nUmlawuli wakho uyakwazi ukuqapha umsebenzi wenethiwekhi yakho ofaka ama-imeyili, izinhlelo zokusebenza, namawebhusayithi avikelekile. Ukuze uthole ulwazi olungeziwe, xhumana nomlawuli wakho.\n\nFuthi, uxhumeke ku-VPN (\"<xliff:g id="APPLICATION">%2$s</xliff:g>\"). Umhlinzeki wakho wesevisi ye-VPN angaphinda aqaphele nomsebenzi wenethiwekhi."</string>
+    <string name="monitoring_description_vpn_device_and_profile_owned" msgid="9193588924767232909">"Le divayisi iphethwe yi-:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIphrofayela yakho iphethwe yi-:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUmlawuli wakho uyakwazi ukuqapha umsebenzi wakho wenethiwekhi ofaka ama-imeyili, izinhlelo zokusebenza namawebhusayithi avikelekile. Ukuze uthole olunye ulwazi, xhumana nomlawuli wakho.\n\nFuthi unikeze i-\"<xliff:g id="APPLICATION">%3$s</xliff:g>\" imvume yokusetha ukuxhumeka kwe-VPN. Lolu hlelo lokusebenza lungaqapha nomsebenzi wenethiwekhi."</string>
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned" msgid="6935475023447698473">"Le divayisi iphethwe yi-:\n<xliff:g id="ORGANIZATION_0">%1$s</xliff:g>\nIphrofayela yakho iphethwe yi-:\n<xliff:g id="ORGANIZATION_1">%2$s</xliff:g>\n\nUmlawuli wakho uyakwazi ukuqapha umsebenzi wakho wenethiwekhi ofaka ama-imeyili, izinhlelo zokusebenza, namawebhusayithi avikelekile. Ukuze uthole olunye ulwazi, xhumana nomlawuli wakho.\n\nFuthi, uxhumeke ku-VPN (\"<xliff:g id="APPLICATION">%3$s</xliff:g>\"). Umhlinzeki wakho wesevisi ye-VPN angaqapha nomsebenzi wenethiwekhi."</string>
+    <string name="keyguard_indication_trust_disabled" msgid="7412534203633528135">"Idivayisi izohlala ikhiyekile uze uyivule ngokwenza"</string>
+    <string name="hidden_notifications_title" msgid="7139628534207443290">"Thola izaziso ngokushesha"</string>
+    <string name="hidden_notifications_text" msgid="2326409389088668981">"Ibone ngaphambi kokuthi uyivule"</string>
+    <string name="hidden_notifications_cancel" msgid="3690709735122344913">"Cha ngiyabonga"</string>
+    <string name="hidden_notifications_setup" msgid="41079514801976810">"Lungisa"</string>
+    <string name="muted_by" msgid="6147073845094180001">"Ithuliswe ngu-<xliff:g id="THIRD_PARTY">%1$s</xliff:g>"</string>
 </resources>
diff --git a/packages/SystemUI/res/values/arrays.xml b/packages/SystemUI/res/values/arrays.xml
index 630a48d..6102aa6 100644
--- a/packages/SystemUI/res/values/arrays.xml
+++ b/packages/SystemUI/res/values/arrays.xml
@@ -25,7 +25,7 @@
         <item>100</item>
     </array>
     <array name="batterymeter_color_values">
-        <item>#FFFF3300</item>
+        <item>@*android:color/battery_saver_mode_color</item>
         <item>#FFFFFFFF</item>
     </array>
     <array name="batterymeter_bolt_points">
diff --git a/packages/SystemUI/res/values/colors.xml b/packages/SystemUI/res/values/colors.xml
index e9c7deb..82dccd2 100644
--- a/packages/SystemUI/res/values/colors.xml
+++ b/packages/SystemUI/res/values/colors.xml
@@ -23,7 +23,6 @@
     <color name="system_bar_background_opaque">#ff000000</color>
     <color name="system_bar_background_semi_transparent">#66000000</color> <!-- 40% black -->
     <color name="system_bar_background_transparent">#00000000</color>
-    <color name="system_bar_background_warning">#fff4511e</color><!-- deep orange 600 -->
     <color name="notification_panel_solid_background">#ff000000</color>
     <drawable name="status_bar_recents_app_thumbnail_background">#88000000</drawable>
     <color name="status_bar_recents_app_label_color">#ffffffff</color>
@@ -86,8 +85,15 @@
     <!-- The color of the material notification background when low priority -->
     <color name="notification_material_background_low_priority_color">#ffe0e0e0</color>
 
+    <!-- The color of the material notification background for media notifications when no custom
+         color is specified -->
+    <color name="notification_material_background_media_default_color">#ff424242</color>
+
     <!-- The color of the ripples on the untinted notifications -->
-    <color name="notification_ripple_untinted_color">#20000000</color>
+    <color name="notification_ripple_untinted_color">#28000000</color>
+
+    <!-- The color of the ripples on the low priority notifications -->
+    <color name="notification_ripple_color_low_priority">#30000000</color>
 
     <!-- The color of the ripples on the tinted notifications -->
     <color name="notification_ripple_tinted_color">#30ffffff</color>
@@ -98,12 +104,23 @@
     <color name="segmented_button_text_inactive">#99afbdc4</color><!-- 60% -->
 
     <!-- The "inside" of a notification, reached via longpress -->
-    <color name="notification_guts_bg_color">#ff424242</color><!-- grey 800 -->
+    <color name="notification_guts_bg_color">@color/system_secondary_color</color>
     <color name="notification_guts_title_color">#FFFFFFFF</color>
-    <color name="notification_guts_text_color">#99FFFFFF</color>
+    <color name="notification_guts_text_color">#b2FFFFFF</color>
     <color name="notification_guts_btn_color">#FFFFFFFF</color>
 
-    <color name="search_panel_card_color">#ffffff</color>
+    <color name="search_panel_circle_color">#ffffff</color>
+    <color name="search_panel_ripple_color">#ffbbbbbb</color>
 
     <color name="keyguard_user_switcher_background_gradient_color">#77000000</color>
+    <color name="doze_small_icon_background_color">#ff434343</color>
+
+    <!-- The color of the navigation bar icons. Need to be in sync with ic_sysbar_* -->
+    <color name="navigation_bar_icon_color">#E5FFFFFF</color>
+
+    <!-- Shadow color for the first pixels around the fake shadow for recents. -->
+    <color name="fake_shadow_start_color">#44000000</color>
+
+    <!-- Shadow color for the furthest pixels around the fake shadow for recents. -->
+    <color name="fake_shadow_end_color">#03000000</color>
 </resources>
diff --git a/packages/SystemUI/res/values/config.xml b/packages/SystemUI/res/values/config.xml
index f628039..9346906 100644
--- a/packages/SystemUI/res/values/config.xml
+++ b/packages/SystemUI/res/values/config.xml
@@ -29,6 +29,22 @@
      ImageView -->
     <bool name="config_recents_thumbnail_image_fits_to_xy">false</bool>
 
+    <!-- Whether recents should use hardware layers for its taskviews. This flag can be enabled
+    for devices where the java drawing of round rects may be slow -->
+    <bool name="config_recents_use_hardware_layers">false</bool>
+
+    <!-- The number of app thumbnails we keep in memory -->
+    <integer name="config_recents_max_thumbnail_count">10</integer>
+
+    <!-- The number of app icons we keep in memory -->
+    <integer name="config_recents_max_icon_count">20</integer>
+
+    <!-- Whether to use cheap, less good looking shadows for recents -->
+    <bool name="config_recents_fake_shadows">false</bool>
+
+    <!-- The theme to use for RecentsActivity. -->
+    <item type="style" name="config_recents_activity_theme">@style/RecentsTheme.Wallpaper</item>
+
     <!-- Control whether status bar should distinguish HSPA data icon form UMTS
     data icon on devices -->
     <bool name="config_hspa_data_distinguishable">false</bool>
@@ -62,6 +78,9 @@
     <!-- Vibration duration for GlowPadView used in SearchPanelView -->
     <integer translatable="false" name="config_search_panel_view_vibration_duration">20</integer>
 
+    <!-- Show camera affordance on Keyguard -->
+    <bool name="config_keyguardShowCameraAffordance">true</bool>
+
     <!-- The length of the vibration when the notification pops open. -->
     <integer name="one_finger_pop_duration_ms">10</integer>
 
@@ -92,7 +111,7 @@
 
     <!-- The default tiles to display in QuickSettings -->
     <string name="quick_settings_tiles_default" translatable="false">
-        wifi,bt,inversion,cell,airplane,rotation,flashlight,location,cast
+        wifi,bt,inversion,cell,airplane,rotation,flashlight,location,cast,hotspot
     </string>
 
     <!-- The tiles to display in QuickSettings -->
@@ -111,7 +130,7 @@
     <bool name="config_show4GForLTE">true</bool>
 
     <!-- milliseconds before the heads up notification auto-dismisses. -->
-    <integer name="heads_up_notification_decay">3700</integer>
+    <integer name="heads_up_notification_decay">10000</integer>
 
     <!-- milliseconds before the heads up notification accepts touches. -->
     <integer name="heads_up_sensitivity_delay">700</integer>
@@ -123,18 +142,24 @@
     <!-- The min animation duration for animating views that are newly visible. -->
     <integer name="recents_filter_animate_new_views_duration">250</integer>
     <!-- The min animation duration for animating the task bar in. -->
-    <integer name="recents_animate_task_bar_enter_duration">275</integer>
+    <integer name="recents_animate_task_bar_enter_duration">225</integer>
     <!-- The animation delay for animating the first task in. This should roughly be the animation
      duration of the transition in to recents. -->
-    <integer name="recents_animate_task_bar_enter_delay">225</integer>
+    <integer name="recents_animate_task_bar_enter_delay">275</integer>
     <!-- The min animation duration for animating the task bar out. -->
     <integer name="recents_animate_task_exit_to_home_duration">225</integer>
     <!-- The min animation duration for animating the task bar out. -->
     <integer name="recents_animate_task_bar_exit_duration">125</integer>
+    <!-- The animation delay for animating the first task in. This should roughly be the animation
+     duration of the transition in to recents from home. -->
+    <integer name="recents_animate_task_enter_from_home_delay">150</integer>
     <!-- The min animation duration for animating the task in when transitioning from home. -->
-    <integer name="recents_animate_task_enter_from_home_duration">275</integer>
-    <!-- The animation stagger to apply to each task animation when transitioning from home. -->
-    <integer name="recents_animate_task_enter_from_home_delay">10</integer>
+    <integer name="recents_animate_task_enter_from_home_duration">200</integer>
+    <!-- The total animation stagger delay when entering from home. -->
+    <integer name="recents_animate_task_enter_from_home_stagger_delay">110</integer>
+    <!-- The total animation duration added to the last card when entering from home.
+    This value is partialy also added to the previous tasks -->
+    <integer name="recents_animate_task_enter_from_home_stagger_duration">72</integer>
     <!-- The short duration when animating in/out the lock to app button. -->
     <integer name="recents_animate_lock_to_app_button_short_duration">150</integer>
     <!-- The long duration when animating in/out the lock to app button. -->
@@ -143,14 +168,16 @@
     <integer name="recents_nav_bar_scrim_enter_duration">400</integer>
     <!-- The animation duration for animating the removal of a task view. -->
     <integer name="recents_animate_task_view_remove_duration">250</integer>
+    <!-- The animation duration for scrolling the stack to a particular item. -->
+    <integer name="recents_animate_task_stack_scroll_duration">225</integer>
     <!-- The minimum alpha for the dim applied to cards that go deeper into the stack. -->
     <integer name="recents_max_task_stack_view_dim">96</integer>
-    <!-- The number of tasks that RecentsTaskLoader should load. -->
-    <integer name="recents_max_num_tasks_to_load">50</integer>
     <!-- The delay to enforce between each alt-tab key press. -->
     <integer name="recents_alt_tab_key_delay">200</integer>
-    <!-- Transposes the recents layout in landscape. -->
-    <bool name="recents_transpose_layout_with_orientation">true</bool>
+    <!-- Transposes the search bar layout in landscape. -->
+    <bool name="recents_has_transposed_search_bar">true</bool>
+    <!-- Transposes the nav bar in landscape (only used for purposes of layout). -->
+    <bool name="recents_has_transposed_nav_bar">true</bool>
 
     <!-- Whether to enable KeyguardService or not -->
     <bool name="config_enableKeyguardService">true</bool>
@@ -180,19 +207,37 @@
     <!-- Doze: should the pickup sensor be used as a pulse signal? -->
     <bool name="doze_pulse_on_pick_up">false</bool>
 
-    <!-- Doze: maximum brightness to use when pulsing -->
-    <integer name="doze_pulse_brightness">40</integer>
+    <!-- Doze: should notifications be used as a pulse signal? -->
+    <bool name="doze_pulse_on_notifications">true</bool>
 
-    <!-- Doze: number of pulses when doing multiple pulses in quick succession -->
-    <integer name="doze_multipulse_count">3</integer>
+    <!-- Doze: when to pulse after a buzzworthy notification arrives -->
+    <string name="doze_pulse_schedule">1s,10s,30s,60s,120s</string>
 
-    <!-- Doze: interval between pulses when following the notification light -->
-    <integer name="doze_notification_pulse_interval">30000</integer>
+    <!-- Doze: maximum number of times the notification pulse schedule can be reset -->
+    <integer name="doze_pulse_schedule_resets">3</integer>
+
+    <!-- Doze: duration to avoid false pickup gestures triggered by notification vibrations -->
+    <integer name="doze_pickup_vibration_threshold">2000</integer>
+
+    <!-- Doze: pulse parameter - how long does it take to fade in? -->
+    <integer name="doze_pulse_duration_in">1000</integer>
+
+    <!-- Doze: pulse parameter - once faded in, how long does it stay visible? -->
+    <integer name="doze_pulse_duration_visible">3000</integer>
+
+    <!-- Doze: pulse parameter - how long does it take to fade out? -->
+    <integer name="doze_pulse_duration_out">1000</integer>
+
+    <!-- Doze: alpha to apply to small icons when dozing -->
+    <integer name="doze_small_icon_alpha">222</integer><!-- 87% of 0xff -->
 
     <!-- Volume: time to delay dismissing the volume panel after a click is performed -->
     <integer name="volume_panel_dismiss_delay">200</integer>
 
     <!-- Tiles with feature timeouts: number of days to show after feature is used. -->
     <integer name="days_to_show_timeout_tiles">30</integer>
+
+    <!-- Number of times to show the strong alarm warning text in the volume dialog -->
+    <integer name="zen_mode_alarm_warning_threshold">5</integer>
 </resources>
 
diff --git a/packages/SystemUI/res/values/dimens.xml b/packages/SystemUI/res/values/dimens.xml
index 5415d19..c690ef4 100644
--- a/packages/SystemUI/res/values/dimens.xml
+++ b/packages/SystemUI/res/values/dimens.xml
@@ -73,6 +73,9 @@
     <!-- Height of notification icons in the status bar -->
     <dimen name="status_bar_icon_size">@*android:dimen/status_bar_icon_size</dimen>
 
+    <!-- The font size for the clock -->
+    <dimen name="status_bar_clock_size">14sp</dimen>
+
     <!-- Height of a small notification in the status bar -->
     <dimen name="notification_min_height">64dp</dimen>
 
@@ -86,10 +89,10 @@
     <dimen name="notification_summary_height">44dp</dimen>
 
     <!-- size at which Notification icons will be drawn in the status bar -->
-    <dimen name="status_bar_icon_drawing_size">18dip</dimen>
+    <dimen name="status_bar_icon_drawing_size">17dip</dimen>
 
     <!-- opacity at which Notification icons will be drawn in the status bar -->
-    <item type="dimen" name="status_bar_icon_drawing_alpha">75%</item>
+    <item type="dimen" name="status_bar_icon_drawing_alpha">90%</item>
 
     <!-- gap on either side of status bar notification icons -->
     <dimen name="status_bar_icon_padding">0dp</dimen>
@@ -115,9 +118,6 @@
     <!-- Diameter of outer shape drawable shown in navbar search. Should be 1/2 of above value -->
     <dimen name="navbar_search_outerring_radius">170dp</dimen>
 
-    <!-- Threshold for swipe-up gesture to activate search dialog -->
-    <dimen name="navbar_search_up_threshhold">40dip</dimen>
-
     <!-- Height of search panel including navigation bar height -->
     <dimen name="navbar_search_panel_height">230dip</dimen>
 
@@ -168,7 +168,8 @@
     <dimen name="qs_dual_tile_height">112dp</dimen>
     <dimen name="qs_dual_tile_padding_vertical">8dp</dimen>
     <dimen name="qs_dual_tile_padding_horizontal">6dp</dimen>
-    <dimen name="qs_tile_padding_top">16dp</dimen>
+    <dimen name="qs_tile_padding_top">14dp</dimen>
+    <dimen name="qs_tile_padding_top_large_text">4dp</dimen>
     <dimen name="qs_tile_padding_below_icon">12dp</dimen>
     <dimen name="qs_tile_padding_bottom">16dp</dimen>
     <dimen name="qs_tile_spacing">4dp</dimen>
@@ -176,7 +177,13 @@
     <dimen name="qs_detail_item_height">48dp</dimen>
     <dimen name="qs_detail_item_height_twoline">72dp</dimen>
     <dimen name="qs_brightness_padding_top">6dp</dimen>
-
+    <dimen name="qs_detail_header_text_size">20sp</dimen>
+    <dimen name="qs_detail_button_text_size">14sp</dimen>
+    <dimen name="qs_detail_item_primary_text_size">16sp</dimen>
+    <dimen name="qs_detail_item_secondary_text_size">14sp</dimen>
+    <dimen name="qs_detail_empty_text_size">14sp</dimen>
+    <dimen name="qs_data_usage_text_size">14sp</dimen>
+    <dimen name="qs_data_usage_usage_text_size">36sp</dimen>
 
     <dimen name="segmented_button_spacing">4dp</dimen>
     <dimen name="segmented_button_radius">2dp</dimen>
@@ -198,17 +205,14 @@
     <!-- The size of the application icon in the recents task view. -->
     <dimen name="recents_task_view_application_icon_size">48dp</dimen>
 
-    <!-- The size of the activity icon in the recents task view. -->
-    <dimen name="recents_task_view_activity_icon_size">60dp</dimen>
-
     <!-- The radius of the rounded corners on a task view. -->
     <dimen name="recents_task_view_rounded_corners_radius">2dp</dimen>
 
     <!-- The min translation in the Z index for the last task. -->
-    <dimen name="recents_task_view_z_min">5dp</dimen>
+    <dimen name="recents_task_view_z_min">20dp</dimen>
 
     <!-- The max translation in the Z index for the last task. -->
-    <dimen name="recents_task_view_z_max">65dp</dimen>
+    <dimen name="recents_task_view_z_max">80dp</dimen>
 
     <!-- The amount to translate when animating the removal of a task. -->
     <dimen name="recents_task_view_remove_anim_translation_x">100dp</dimen>
@@ -234,6 +238,9 @@
     <!-- The side padding for the task stack as a percentage of the width. -->
     <item name="recents_stack_width_padding_percentage" format="float" type="dimen">0.04444</item>
 
+    <!-- The overscroll percentage allowed on the stack. -->
+    <item name="recents_stack_overscroll_percentage" format="float" type="dimen">0.0875</item>
+
     <!-- The top offset for the task stack. -->
     <dimen name="recents_stack_top_padding">16dp</dimen>
 
@@ -281,8 +288,14 @@
     <!-- The height of the speed bump view. -->
     <dimen name="speed_bump_height">16dp</dimen>
 
-    <!-- Lockscreen affordance drag distance for camera and phone. -->
-    <dimen name="affordance_drag_distance">100dp</dimen>
+    <!-- Lockscreen unlocking falsing threshold. -->
+    <dimen name="unlock_falsing_threshold">80dp</dimen>
+
+    <!-- Lockscreen falsing threshold for quick settings. -->
+    <dimen name="qs_falsing_threshold">40dp</dimen>
+
+    <!-- Falsing threshold used when dismissing notifications from the lockscreen. -->
+    <dimen name="swipe_helper_falsing_threshold">70dp</dimen>
 
     <dimen name="notifications_top_padding">8dp</dimen>
     
@@ -302,7 +315,7 @@
     <dimen name="heads_up_window_height">250dp</dimen>
 
     <!-- The minimum amount the user needs to swipe to go to the camera / phone. -->
-    <dimen name="keyguard_min_swipe_amount">75dp</dimen>
+    <dimen name="keyguard_min_swipe_amount">90dp</dimen>
 
     <!-- The minimum background radius when swiping to a side for the camera / phone affordances. -->
     <dimen name="keyguard_affordance_min_background_radius">30dp</dimen>
@@ -365,6 +378,9 @@
     <!-- The padding bottom of the clock group when QS is collapsed. -->
     <dimen name="clock_collapsed_bottom_margin">10dp</dimen>
 
+    <!-- The padding bottom of the clock group when QS is collapsed for large text -->
+    <dimen name="clock_collapsed_bottom_margin_large_text">6dp</dimen>
+
     <!-- The width of the multi user switch on keyguard and collapsed QS header. -->
     <dimen name="multi_user_switch_width_collapsed">34dp</dimen>
 
@@ -386,8 +402,14 @@
     <!-- The font size of the time when expanded in QS -->
     <dimen name="qs_time_expanded_size">20sp</dimen>
 
-    <!-- Battery level padding end when in expanded QS (but not on Keyguard) -->
-    <dimen name="battery_level_padding_end">4dp</dimen>
+    <!-- The font size of the "emergency calls only" label in QS -->
+    <dimen name="qs_emergency_calls_only_text_size">12sp</dimen>
+
+    <!-- The font size of the date in QS -->
+    <dimen name="qs_date_collapsed_size">14sp</dimen>
+
+    <!-- Battery level text padding end when in expanded QS and on Keyguard -->
+    <dimen name="battery_level_padding_end">2dp</dimen>
 
     <!-- The top padding of the clear all button -->
     <dimen name="clear_all_padding_top">12dp</dimen>
@@ -400,34 +422,84 @@
     <dimen name="keyguard_carrier_text_margin">16dp</dimen>
 
     <!-- Margin on the left side of the battery % in the header. -->
-    <dimen name="header_battery_margin_expanded">8dp</dimen>
+    <dimen name="header_battery_margin_expanded">6dp</dimen>
 
     <!-- Margin on the left side of the battery % when on Keyguard. -->
     <dimen name="header_battery_margin_keyguard">6dp</dimen>
 
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <dimen name="system_icons_keyguard_padding_end">4dp</dimen>
+
     <!-- Additional translation (downwards) for appearing notifications when going to the full shade
          from Keyguard. -->
     <dimen name="go_to_full_shade_appearing_translation">200dp</dimen>
 
-    <!-- The height of the search panel card. -->
-    <dimen name="search_panel_card_height">300dp</dimen>
+    <!-- The diameter of the search panel circle. -->
+    <dimen name="search_panel_circle_size">88dp</dimen>
 
-    <!-- The height of the scrim behind the search panel card. -->
+    <!-- The margin to the edge of the screen from where the circle starts to appear -->
+    <dimen name="search_panel_circle_base_margin">80dp</dimen>
+
+    <!-- The amount the circle translates when appearing -->
+    <dimen name="search_panel_circle_travel_distance">80dp</dimen>
+
+    <!-- The elevation of the search panel circle -->
+    <dimen name="search_panel_circle_elevation">12dp</dimen>
+
+    <!-- The height of the scrim behind the search panel circle. -->
     <dimen name="search_panel_scrim_height">250dp</dimen>
 
-    <!-- How much from the bottom of the screen the card should peek in when activating the search
-         panel -->
-    <dimen name="search_card_peek_height">100dp</dimen>
-
     <!-- How far the user needs to drag up to invoke search. -->
-    <dimen name="search_panel_threshold">150dp</dimen>
+    <dimen name="search_panel_threshold">100dp</dimen>
 
-    <!-- The width/height of the phone/camera/unlock icon on keyguard. -->
+    <!-- The width/height of the phone/camera/unlock icon view on keyguard. -->
     <dimen name="keyguard_affordance_height">56dp</dimen>
     <dimen name="keyguard_affordance_width">56dp</dimen>
 
+    <!-- The width/height of the phone/camera/unlock icon drawable on keyguard. -->
+    <dimen name="keyguard_affordance_icon_height">24dp</dimen>
+    <dimen name="keyguard_affordance_icon_width">24dp</dimen>
+
     <dimen name="keyguard_indication_margin_bottom">65dp</dimen>
 
     <!-- The text size for battery level -->
     <dimen name="battery_level_text_size">12sp</dimen>
+
+    <!-- TrustDrawable: Minimum inner radius of the breathing animation -->
+    <dimen name="trust_circle_inner_radius_visible_min">22dp</dimen>
+    <!-- TrustDrawable: Maximum inner radius of the breathing animation -->
+    <dimen name="trust_circle_inner_radius_visible_max">24dp</dimen>
+    <!-- TrustDrawable: Inner radius at the end of the exit animation -->
+    <dimen name="trust_circle_inner_radius_exit">38dp</dimen>
+    <!-- TrustDrawable: Inner radius at the beginning of the enter animation -->
+    <dimen name="trust_circle_inner_radius_enter">18dp</dimen>
+    <!-- TrustDrawable: Thickness of the circle -->
+    <dimen name="trust_circle_thickness">2dp</dimen>
+
+    <!-- Margin on the right side of the system icon group on Keyguard. -->
+    <fraction name="battery_button_height_fraction">10.5%</fraction>
+
+    <!-- Fraction value to smooth the edges of the battery icon. The path will be inset by this
+         fraction of a pixel.-->
+    <fraction name="battery_subpixel_smoothing_left">0%</fraction>
+    <fraction name="battery_subpixel_smoothing_right">0%</fraction>
+
+    <dimen name="battery_margin_bottom">0dp</dimen>
+
+    <!-- Extra padding between the mobile data type icon and the strength indicator when the data
+         type icon is wide. -->
+    <dimen name="wide_type_icon_start_padding">2dp</dimen>
+
+    <!-- Extra padding between the mobile data type icon and the strength indicator when the data
+         type icon is wide for the tile in quick settings. -->
+    <dimen name="wide_type_icon_start_padding_qs">3dp</dimen>
+
+    <!-- The maximum width of the navigation bar ripples. -->
+    <dimen name="key_button_ripple_max_width">95dp</dimen>
+    
+    <!-- Inset shadow for FakeShadowDrawable. It is used to avoid gaps between the card
+         and the shadow. -->
+    <dimen name="fake_shadow_inset">1dp</dimen>
+
+    <dimen name="fake_shadow_size">8dp</dimen>
 </resources>
diff --git a/packages/SystemUI/res/values/ids.xml b/packages/SystemUI/res/values/ids.xml
index 6418930..4e93cd8 100644
--- a/packages/SystemUI/res/values/ids.xml
+++ b/packages/SystemUI/res/values/ids.xml
@@ -34,5 +34,6 @@
     <item type="id" name="alpha_animator_start_value_tag"/>
     <item type="id" name="top_inset_animator_start_value_tag"/>
     <item type="id" name="height_animator_start_value_tag"/>
+    <item type="id" name="doze_saved_filter_tag"/>
 </resources>
 
diff --git a/packages/SystemUI/res/values/lland_config.xml b/packages/SystemUI/res/values/lland_config.xml
new file mode 100644
index 0000000..56125a5
--- /dev/null
+++ b/packages/SystemUI/res/values/lland_config.xml
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+** Copyright 2014, 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.
+*/
+-->
+
+<resources>
+    <dimen name="obstacle_spacing">380dp</dimen>
+    <dimen name="translation_per_sec">100dp</dimen>
+    <dimen name="boost_dv">600dp</dimen>
+    <dimen name="player_hit_size">40dp</dimen>
+    <dimen name="player_size">40dp</dimen>
+    <dimen name="obstacle_width">80dp</dimen>
+    <dimen name="obstacle_gap">170dp</dimen>
+    <dimen name="obstacle_height_min">40dp</dimen>
+    <dimen name="building_width_min">20dp</dimen>
+    <dimen name="building_width_max">250dp</dimen>
+    <dimen name="building_height_min">20dp</dimen>
+    <dimen name="cloud_size_min">10dp</dimen>
+    <dimen name="cloud_size_max">100dp</dimen>
+    <dimen name="sun_size">45dp</dimen>
+    <dimen name="moon_size">30dp</dimen>
+    <dimen name="star_size_min">3dp</dimen>
+    <dimen name="star_size_max">5dp</dimen>
+    <dimen name="G">30dp</dimen>
+    <dimen name="max_v">1000dp</dimen>
+    <dimen name="scenery_z">6dp</dimen>
+    <dimen name="obstacle_z">15dp</dimen>
+    <dimen name="player_z">15dp</dimen>
+    <dimen name="player_z_boost">18dp</dimen>
+    <dimen name="hud_z">35dp</dimen>
+</resources>
diff --git a/packages/SystemUI/res/values/lland_strings.xml b/packages/SystemUI/res/values/lland_strings.xml
new file mode 100644
index 0000000..ce88157
--- /dev/null
+++ b/packages/SystemUI/res/values/lland_strings.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/**
+ * Copyright (c) 2014, 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.
+ */
+-->
+<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+    <!-- Name of the L Land easter egg. DO NOT TRANSLATE -->
+    <string name="lland">L Land</string>
+</resources>
diff --git a/packages/SystemUI/res/values/strings.xml b/packages/SystemUI/res/values/strings.xml
index d145172..0445fe8 100644
--- a/packages/SystemUI/res/values/strings.xml
+++ b/packages/SystemUI/res/values/strings.xml
@@ -213,6 +213,14 @@
     <string name="accessibility_camera_button">Camera</string>
     <!-- Content description of the phone button for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_phone_button">Phone</string>
+    <!-- Content description of the unlock button for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_unlock_button">Unlock</string>
+    <!-- Click action label for accessibility for the unlock button. [CHAR LIMIT=NONE] -->
+    <string name="unlock_label">unlock</string>
+    <!-- Click action label for accessibility for the phone button. [CHAR LIMIT=NONE] -->
+    <string name="phone_label">open phone</string>
+    <!-- Click action label for accessibility for the phone button. [CHAR LIMIT=NONE] -->
+    <string name="camera_label">open camera</string>
 
     <!-- Content description of the switch input method button for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_ime_switch_button">Switch input method button.</string>
@@ -273,6 +281,13 @@
     <!-- Content description of the WIFI signal when it is full for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_wifi_signal_full">Wifi signal full.</string>
 
+    <!-- Content description of the wifi label showing what we are connected to. [CHAR LIMIT=NONE] -->
+    <string name="accessibility_wifi_name">Connected to <xliff:g id="wifi" example="Home Network">%s</xliff:g>.</string>
+
+    <!-- Content description of the bluetooth label showing what we are connected to. [CHAR LIMIT=NONE] -->
+    <string name="accessibility_bluetooth_name">Connected to <xliff:g id="bluetooth" example="Car Audio">%s</xliff:g>.</string>
+
+
     <!-- Content description of the WiMAX signal when no signal for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_no_wimax">No WiMAX.</string>
     <!-- Content description of the WiMAX signal when it is one bar for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
@@ -377,6 +392,9 @@
     <!-- Content description of the ringer silent icon in the notification panel for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_ringer_silent">Ringer silent.</string>
 
+    <!-- Content description of the cast icon in the notification panel for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_casting">@string/quick_settings_casting</string>
+
     <!-- Content description to tell the user that this button will remove an application from recents -->
     <string name="accessibility_recents_item_will_be_dismissed">Dismiss <xliff:g id="app" example="Calendar">%s</xliff:g>.</string>
     <!-- Content description to tell the user an application has been removed from recents -->
@@ -390,6 +408,8 @@
     <string name="accessibility_desc_notification_shade">Notification shade.</string>
     <!-- Content description for the quick settings panel (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_desc_quick_settings">Quick settings.</string>
+    <!-- Content description for the lock screen (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_desc_lock_screen">Lock screen.</string>
     <!-- Content description for the settings button in the status bar header. [CHAR LIMIT=NONE] -->
     <string name="accessibility_desc_settings">Settings</string>
     <!-- Content description for the recent apps panel (not shown on the screen). [CHAR LIMIT=NONE] -->
@@ -398,25 +418,69 @@
     <!-- Content description of the user tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_quick_settings_user">User <xliff:g id="user" example="John Doe">%s</xliff:g>.</string>
     <!-- Content description of the wifi tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_wifi"><xliff:g id="signal" example="Three bars">%1$s</xliff:g>. <xliff:g id="network" example="MyWifiNetwork">%2$s</xliff:g></string>
+    <string name="accessibility_quick_settings_wifi"><xliff:g id="signal" example="Three bars">%1$s</xliff:g>.</string>
+    <!-- Announcement made when the wifi is turned off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_wifi_changed_off">Wifi turned off.</string>
+    <!-- Announcement made when the wifi is turned on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_wifi_changed_on">Wifi turned on.</string>
     <!-- Content description of the mobile data tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_quick_settings_mobile">Mobile <xliff:g id="signal" example="Three bars">%1$s</xliff:g>. <xliff:g id="type" example="4G">%2$s</xliff:g>. <xliff:g id="network" example="T-Mobile">%3$s</xliff:g>.</string>
     <!-- Content description of the battery tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_quick_settings_battery">Battery <xliff:g id="state" example="50% charging">%s</xliff:g>.</string>
-    <!-- Content description of the airplane mode tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_airplane">Airplane Mode <xliff:g id="state" example="Off">%s</xliff:g>.</string>
-    <!-- Content description of the bluetooth tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_bluetooth">Bluetooth <xliff:g id="state" example="Off">%s</xliff:g>.</string>
-    <!-- Content description of the location tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_location">Location <xliff:g id="state" example="Off">%s</xliff:g>.</string>
+    <!-- Content description of the airplane mode tile in quick settings when off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_airplane_off">Airplane mode off.</string>
+    <!-- Content description of the airplane mode tile in quick settings when on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_airplane_on">Airplane mode on.</string>
+    <!-- Announcement made when the airplane mode changes to off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_airplane_changed_off">Airplane mode turned off.</string>
+    <!-- Announcement made when the airplane mode changes to on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_airplane_changed_on">Airplane mode turned on.</string>
+    <!-- Content description of the bluetooth tile in quick settings when off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_off">Bluetooth off.</string>
+    <!-- Content description of the bluetooth tile in quick settings when on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_on">Bluetooth on.</string>
+    <!-- Content description of the bluetooth tile in quick settings when connecting (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_connecting">Bluetooth connecting.</string>
+    <!-- Content description of the bluetooth tile in quick settings when connected (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_connected">Bluetooth connected.</string>
+    <!-- Announcement made when the bluetooth is turned off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_changed_off">Bluetooth turned off.</string>
+    <!-- Announcement made when the bluetooth is turned on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_bluetooth_changed_on">Bluetooth turned on.</string>
+    <!-- Content description of the location tile in quick settings when off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_location_off">Location reporting off.</string>
+    <!-- Content description of the location tile in quick settings when on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_location_on">Location reporting on.</string>
+    <!-- Announcement made when the location tile changes to off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_location_changed_off">Location reporting turned off.</string>
+    <!-- Announcement made when the location tile changes to on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_location_changed_on">Location reporting turned on.</string>
     <!-- Content description of the alarm tile in quick settings (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_quick_settings_alarm">Alarm set for <xliff:g id="time" example="Wed 3:30 PM">%s</xliff:g>.</string>
     <!-- Content description of quick settings detail panel close button (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_close">Close panel</string>
+    <string name="accessibility_quick_settings_close">Close panel.</string>
     <!-- Content description of zen mode time condition plus button (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_more_time">More time</string>
+    <string name="accessibility_quick_settings_more_time">More time.</string>
     <!-- Content description of zen mode time condition minus button (not shown on the screen). [CHAR LIMIT=NONE] -->
-    <string name="accessibility_quick_settings_less_time">Less time</string>
+    <string name="accessibility_quick_settings_less_time">Less time.</string>
+    <!-- Content description of the flashlight tile in quick settings when off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_flashlight_off">Flashlight off.</string>
+    <!-- Content description of the flashlight tile in quick settings when on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_flashlight_on">Flashlight on.</string>
+    <!-- Announcement made when the flashlight state changes to off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_flashlight_changed_off">Flashlight turned off.</string>
+    <!-- Announcement made when the flashlight state changes to on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_flashlight_changed_on">Flashlight turned on.</string>
+    <!-- Announcement made when the color inversion state changes to off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_color_inversion_changed_off">Color inversion turned off.</string>
+    <!-- Announcement made when the color inversion state changes to on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_color_inversion_changed_on">Color inversion turned on.</string>
+    <!-- Announcement made when the hotspot state changes to off (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_hotspot_changed_off">Mobile hotspot turned off.</string>
+    <!-- Announcement made when the hotspot state changes to on (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_quick_settings_hotspot_changed_on">Mobile hotspot turned on.</string>
+    <!-- Announcement made when the screen stopped casting (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_casting_turned_off">Screen casting stopped.</string>
 
     <!-- Content description of the display brightness slider (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_brightness">Display brightness</string>
@@ -458,9 +522,13 @@
     <!-- Content description of the clear button in the notification panel for accessibility (not shown on the screen). [CHAR LIMIT=NONE] -->
     <string name="accessibility_clear_all">Clear all notifications.</string>
 
-    <!-- Title shown in notification popup for inspecting the responsible
-         application [CHAR LIMIT=30] -->
-    <string name="status_bar_notification_inspect_item_title">Settings</string>
+    <!-- Content description of button in notification inspector for system settings relating to
+         notifications from this application [CHAR LIMIT=NONE] -->
+    <string name="status_bar_notification_inspect_item_title">Notification settings</string>
+
+    <!-- Content description of button in notification inspetor for application-provided settings
+         for its own notifications [CHAR LIMIT=NONE] -->
+    <string name="status_bar_notification_app_settings_title"><xliff:g id="app_name" example="Calendar">%s</xliff:g> settings</string>
 
     <!-- Description of the button in the phone-style notification panel that controls auto-rotation, when auto-rotation is on. [CHAR LIMIT=NONE] -->
     <string name="accessibility_rotation_lock_off">Screen will rotate automatically.</string>
@@ -471,6 +539,15 @@
     <!-- Description of the button in the phone-style notification panel that controls auto-rotation, when auto-rotation is off. [CHAR LIMIT=NONE] -->
     <string name="accessibility_rotation_lock_on_portrait">Screen is locked in portrait orientation.</string>
 
+    <!-- Announcement made when the screen is rotating automatically again (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_rotation_lock_off_changed">Screen will now rotate automatically.</string>
+
+    <!-- Announcement made when the rotation lock state changes to landscape only (not shown on the screen). [CHAR LIMIT=NONE] -->
+    <string name="accessibility_rotation_lock_on_landscape_changed">Screen is now locked in landscape orientation.</string>
+
+    <!-- Announcement made when the rotation lock state changes to portrait only (not shown on the screen).  [CHAR LIMIT=NONE] -->
+    <string name="accessibility_rotation_lock_on_portrait_changed">Screen is now locked in portrait orientation.</string>
+
     <!-- Name of the K-release easter egg: a display case for all our tastiest desserts. [CHAR LIMIT=30] -->
     <string name="dessert_case">Dessert Case</string>
 
@@ -577,7 +654,7 @@
     <!-- QuickSettings: Cellular detail panel, remaining data title [CHAR LIMIT=NONE] -->
     <string name="quick_settings_cellular_detail_remaining_data">Remaining data</string>
     <!-- QuickSettings: Cellular detail panel, over limit title [CHAR LIMIT=NONE] -->
-    <string name="quick_settings_cellular_detail_over_limit">Over limit</string>
+    <string name="quick_settings_cellular_detail_over_limit">Limit reached &#8211; data usage paused</string>
     <!-- QuickSettings: Cellular detail panel, data used format string [CHAR LIMIT=NONE] -->
     <string name="quick_settings_cellular_detail_data_used"><xliff:g id="data_used" example="2.0 GB">%s</xliff:g> used</string>
     <!-- QuickSettings: Cellular detail panel, data limit format string [CHAR LIMIT=NONE] -->
@@ -624,7 +701,7 @@
     <string name="description_direction_left">"Slide left for <xliff:g id="target_description" example="Unlock">%s</xliff:g>.</string>
 
     <!-- Zen mode: No interruptions title, with a warning about alarms. [CHAR LIMIT=60] -->
-    <string name="zen_no_interruptions_with_warning">No interruptions, including alarms</string>
+    <string name="zen_no_interruptions_with_warning">No interruptions. Not even alarms.</string>
 
     <!-- Zen mode: No interruptions. [CHAR LIMIT=40] -->
     <string name="zen_no_interruptions">No interruptions</string>
@@ -659,11 +736,6 @@
     <!-- Shows when people have clicked at the right edge of the screen to explain how to open the phone. In right-to-left languages, this is the opposite direction. [CHAR LIMIT=60] -->
     <string name="camera_hint">Swipe left for camera</string>
 
-    <string name="bugreport_tile_extended" translatable="false">%s\n%s (%s)</string>
-
-    <!-- Zen mode condition: no exit criteria. [CHAR LIMIT=NONE] -->
-    <string name="zen_mode_forever">Indefinitely</string>
-
     <!-- Interruption level: None. [CHAR LIMIT=20] -->
     <string name="interruption_level_none">None</string>
 
@@ -681,6 +753,9 @@
     <!-- Accessibility label for the button that opens the user switcher. -->
     <string name="accessibility_multi_user_switch_switcher">Switch user</string>
 
+    <!-- Accessibility label for the button that opens the user switcher and announces the current user. -->
+    <string name="accessibility_multi_user_switch_switcher_with_current">Switch user, current user <xliff:g id="current_user_name" example="John Doe">%s</xliff:g></string>
+
     <!-- Accessibility label for the button that opens the quick contact of the user. -->
     <string name="accessibility_multi_user_switch_quick_contact">Show profile</string>
 
@@ -700,10 +775,13 @@
     <string name="guest_exit_guest">Remove guest</string>
 
     <!-- Title of the confirmation dialog when exiting guest session [CHAR LIMIT=NONE] -->
-    <string name="guest_exit_guest_dialog_title">Exiting guest session?</string>
+    <string name="guest_exit_guest_dialog_title">Remove guest?</string>
 
     <!-- Message of the confirmation dialog when exiting guest session [CHAR LIMIT=NONE] -->
-    <string name="guest_exit_guest_dialog_message">Exiting the guest session will remove local data.</string>
+    <string name="guest_exit_guest_dialog_message">All apps and data in this session will be deleted.</string>
+
+    <!-- Label for button in confirmation dialog when exiting guest session [CHAR LIMIT=35] -->
+    <string name="guest_exit_guest_dialog_remove">Remove</string>
 
     <!-- Title of the notification when resuming an existing guest session [CHAR LIMIT=NONE] -->
     <string name="guest_wipe_session_title">Welcome back, guest!</string>
@@ -717,18 +795,12 @@
     <!-- Notification when resuming an existing guest session: Action that continues with the current session [CHAR LIMIT=35] -->
     <string name="guest_wipe_session_dontwipe">Yes, continue</string>
 
+    <!-- Title for add user confirmation dialog [CHAR LIMIT=30] -->
+    <string name="user_add_user_title" msgid="2108112641783146007">Add new user?</string>
 
-    <!-- Zen mode condition: time duration in minutes. [CHAR LIMIT=NONE] -->
-    <plurals name="zen_mode_duration_minutes">
-        <item quantity="one">For one minute</item>
-        <item quantity="other">For %d minutes</item>
-    </plurals>
+    <!-- Message for add user confirmation dialog - short version. [CHAR LIMIT=none] -->
+    <string name="user_add_user_message_short" msgid="1511354412249044381">When you add a new user, that person needs to set up their space.\n\nAny user can update apps for all other users. </string>
 
-    <!-- Zen mode condition: time duration in hours. [CHAR LIMIT=NONE] -->
-    <plurals name="zen_mode_duration_hours">
-        <item quantity="one">For one hour</item>
-        <item quantity="other">For %d hours</item>
-    </plurals>
 
     <!-- Battery saver notification title. [CHAR LIMIT=60]-->
     <string name="battery_saver_notification_title">Battery saver is on</string>
@@ -763,17 +835,23 @@
     <!-- Footer device owned text [CHAR LIMIT=50] -->
     <string name="device_owned_footer">Device may be monitored</string>
 
+    <!-- Footer profile owned text [CHAR LIMIT=50] -->
+    <string name="profile_owned_footer">Profile may be monitored</string>
+
     <!-- Footer vpn present text [CHAR LIMIT=50] -->
     <string name="vpn_footer">Network may be monitored</string>
 
     <!-- Monitoring dialog title for device owned devices [CHAR LIMIT=35] -->
     <string name="monitoring_title_device_owned">Device monitoring</string>
 
+    <!-- Monitoring dialog title for profile owned devices [CHAR LIMIT=35] -->
+    <string name="monitoring_title_profile_owned">Profile monitoring</string>
+
     <!-- Monitoring dialog title for normal devices  [CHAR LIMIT=35]-->
     <string name="monitoring_title">Network monitoring</string>
 
-    <!-- Monitoring dialog open app button [CHAR LIMIT=30] -->
-    <string name="open_app">Open app</string>
+    <!-- Monitoring dialog disable vpn button [CHAR LIMIT=30] -->
+    <string name="disable_vpn">Disable VPN</string>
 
     <!-- Monitoring dialog disconnect vpn button [CHAR LIMIT=30] -->
     <string name="disconnect_vpn">Disconnect VPN</string>
@@ -793,7 +871,39 @@
     <!-- Monitoring dialog legacy VPN with device owner text [CHAR LIMIT=300] -->
     <string name="monitoring_description_legacy_vpn_device_owned">This device is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="application">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too.</string>
 
+    <!-- Monitoring dialog profile owner body text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_profile_owned">This profile is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator.</string>
+
+    <!-- Monitoring dialog device and profile owner body text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_device_and_profile_owned">This device is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="organization">%2$s</xliff:g>\n\nYour administrator can monitor your device and network activity, including emails, apps and secure websites.\n\nFor more information, contact your administrator.</string>
+
+    <!-- Monitoring dialog non-legacy VPN with profile owner text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_vpn_profile_owned">This profile is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="application">%2$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too.</string>
+
+    <!-- Monitoring dialog legacy VPN with profile owner text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_legacy_vpn_profile_owned">This profile is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="application">%2$s</xliff:g>\"). Your VPN service provider can monitor network activity too.</string>
+
+    <!-- Monitoring dialog non-legacy VPN with device and profile owner text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_vpn_device_and_profile_owned">This device is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="organization">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you gave \"<xliff:g id="application">%3$s</xliff:g>\" permission to set up a VPN connection. This app can monitor network activity too.</string>
+
+    <!-- Monitoring dialog legacy VPN with device and profile owner text [CHAR LIMIT=300] -->
+    <string name="monitoring_description_legacy_vpn_device_and_profile_owned">This device is managed by:\n<xliff:g id="organization">%1$s</xliff:g>\nYour profile is managed by:\n<xliff:g id="organization">%2$s</xliff:g>\n\nYour administrator is capable of monitoring your network activity including emails, apps, and secure websites. For more information, contact your administrator.\n\nAlso, you\'re connected to a VPN (\"<xliff:g id="application">%3$s</xliff:g>\"). Your VPN service provider can monitor network activity too.</string>
+
     <!-- Indication on the keyguard that appears when the user disables trust agents until the next time they unlock manually. [CHAR LIMIT=NONE] -->
     <string name="keyguard_indication_trust_disabled">Device will stay locked until you manually unlock</string>
 
+    <!-- Title of notification educating the user about enabling notifications on the lockscreen. [CHAR LIMIT=40] -->
+    <string name="hidden_notifications_title">Get notifications faster</string>
+
+    <!-- Body of notification educating the user about enabling notifications on the lockscreen. [CHAR LIMIT=60] -->
+    <string name="hidden_notifications_text">See them before you unlock</string>
+
+    <!-- Cancel action for notification educating the user about enabling notifications on the lockscreen. [CHAR LIMIT=10] -->
+    <string name="hidden_notifications_cancel">No thanks</string>
+
+    <!-- continue action for notification educating the user about enabling notifications on the lockscreen. [CHAR LIMIT=10] -->
+    <string name="hidden_notifications_setup">Set up</string>
+
+    <!-- Indication that the current volume and other effects (vibration) are being suppressed by a third party, such as a notification listener. [CHAR LIMIT=30] -->
+    <string name="muted_by">Muted by <xliff:g id="third_party">%1$s</xliff:g></string>
 </resources>
diff --git a/packages/SystemUI/res/values/styles.xml b/packages/SystemUI/res/values/styles.xml
index 27e58a4..46e7587 100644
--- a/packages/SystemUI/res/values/styles.xml
+++ b/packages/SystemUI/res/values/styles.xml
@@ -20,12 +20,29 @@
         <item name="android:windowAnimationStyle">@style/Animation.RecentsActivity</item>
     </style>
 
-    <!-- Alternate Recents theme -->
-    <style name="RecentsTheme" parent="@android:style/Theme.DeviceDefault.Wallpaper.NoTitleBar">
+    <style name="RecentsTheme" parent="@android:style/Theme">
+        <!-- NoTitle -->
+        <item name="android:windowNoTitle">true</item>
+        <!-- Misc -->
         <item name="android:statusBarColor">@android:color/transparent</item>
         <item name="android:navigationBarColor">@android:color/transparent</item>
         <item name="android:windowDrawsSystemBarBackgrounds">true</item>
         <item name="android:windowAnimationStyle">@style/Animation.RecentsActivity</item>
+        <item name="android:ambientShadowAlpha">0.35</item>
+    </style>
+
+
+    <!-- Alternate Recents theme -->
+    <style name="RecentsTheme.Wallpaper">
+        <!-- Wallpaper -->
+        <item name="android:windowBackground">@color/transparent</item>
+        <item name="android:colorBackgroundCacheHint">@null</item>
+        <item name="android:windowShowWallpaper">true</item>
+    </style>
+
+    <!-- Performance optimized alternate Recents theme (no wallpaper) -->
+    <style name="RecentsTheme.NoWallpaper">
+        <item name="android:windowBackground">@android:color/black</item>
     </style>
 
     <!-- Animations for a non-full-screen window or activity. -->
@@ -61,8 +78,7 @@
     </style>
 
     <style name="TextAppearance.StatusBar.Clock" parent="@*android:style/TextAppearance.StatusBar.Icon">
-        <!-- Note: must be dp to fit in status bar -->
-        <item name="android:textSize">16dp</item>
+        <item name="android:textSize">@dimen/status_bar_clock_size</item>
         <item name="android:fontFamily">sans-serif-medium</item>
         <item name="android:textColor">@color/status_bar_clock_color</item>
     </style>
@@ -76,13 +92,13 @@
     </style>
 
     <style name="TextAppearance.StatusBar.Expanded.Date">
-        <item name="android:textSize">14sp</item>
+        <item name="android:textSize">@dimen/qs_date_collapsed_size</item>
         <item name="android:textStyle">normal</item>
         <item name="android:textColor">#b2ffffff</item>
     </style>
 
     <style name="TextAppearance.StatusBar.Expanded.AboveDateTime">
-        <item name="android:textSize">12dp</item>
+        <item name="android:textSize">@dimen/qs_emergency_calls_only_text_size</item>
         <item name="android:textStyle">normal</item>
         <item name="android:textColor">#66ffffff</item>
     </style>
@@ -116,28 +132,33 @@
     </style>
 
     <style name="TextAppearance.QS.DetailHeader">
-        <item name="android:textSize">20sp</item>
+        <item name="android:textSize">@dimen/qs_detail_header_text_size</item>
         <item name="android:fontFamily">sans-serif-medium</item>
     </style>
 
     <style name="TextAppearance.QS.DetailItemPrimary">
-        <item name="android:textSize">16sp</item>
+        <item name="android:textSize">@dimen/qs_detail_item_primary_text_size</item>
     </style>
 
     <style name="TextAppearance.QS.DetailItemSecondary">
-        <item name="android:textSize">14sp</item>
+        <item name="android:textSize">@dimen/qs_detail_item_secondary_text_size</item>
         <item name="android:textColor">@color/system_accent_color</item>
     </style>
 
-    <style name="TextAppearance.QS.DetailButton">
+    <style name="TextAppearance.QS.VolumeSuppressor">
         <item name="android:textSize">14sp</item>
+        <item name="android:textColor">@color/qs_tile_text</item>
+    </style>
+
+    <style name="TextAppearance.QS.DetailButton">
+        <item name="android:textSize">@dimen/qs_detail_button_text_size</item>
         <item name="android:textAllCaps">true</item>
         <item name="android:fontFamily">sans-serif-medium</item>
         <item name="android:gravity">center</item>
     </style>
 
     <style name="TextAppearance.QS.DetailEmpty">
-        <item name="android:textSize">14sp</item>
+        <item name="android:textSize">@dimen/qs_detail_empty_text_size</item>
         <item name="android:textColor">@color/qs_subhead</item>
     </style>
 
@@ -153,11 +174,11 @@
     </style>
 
     <style name="TextAppearance.QS.DataUsage">
-        <item name="android:textSize">14sp</item>
+        <item name="android:textSize">@dimen/qs_data_usage_text_size</item>
     </style>
 
     <style name="TextAppearance.QS.DataUsage.Usage">
-        <item name="android:textSize">36sp</item>
+        <item name="android:textSize">@dimen/qs_data_usage_usage_text_size</item>
         <item name="android:textColor">@color/system_accent_color</item>
     </style>
 
@@ -221,22 +242,15 @@
         <item name="android:windowExitAnimation">@*android:anim/popup_exit_material</item>
     </style>
 
-    <style name="TextAppearance.StatusBar.Material.EventContent.Parenthetical"
-           parent="@*android:style/TextAppearance.StatusBar.Material.EventContent">
+    <style name="TextAppearance.Material.Notification.Parenthetical"
+           parent="@*android:style/TextAppearance.Material.Notification">
         <item name="android:textStyle">italic</item>
         <item name="android:textColor">#60000000</item>
     </style>
 
-    <style name="SearchPanelCard">
+    <style name="SearchPanelCircle">
         <item name="android:layout_width">match_parent</item>
-        <item name="android:layout_height">@dimen/search_panel_card_height</item>
-        <item name="android:layout_marginStart">8dp</item>
-        <item name="android:layout_marginEnd">8dp</item>
-        <item name="android:layout_gravity">bottom</item>
-    </style>
-
-    <style name="SearchPanelLogo">
-        <item name="android:layout_gravity">top|center_horizontal</item>
+        <item name="android:layout_height">match_parent</item>
     </style>
 
     <style name="SearchPanelScrim">
diff --git a/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java b/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java
index b9ffdbb..7bdbd0a 100755
--- a/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java
+++ b/packages/SystemUI/src/com/android/systemui/BatteryMeterView.java
@@ -33,7 +33,10 @@
 import android.util.AttributeSet;
 import android.view.View;
 
-public class BatteryMeterView extends View implements DemoMode {
+import com.android.systemui.statusbar.policy.BatteryController;
+
+public class BatteryMeterView extends View implements DemoMode,
+        BatteryController.BatteryStateChangeCallback {
     public static final String TAG = BatteryMeterView.class.getSimpleName();
     public static final String ACTION_LEVEL_TEST = "com.android.systemui.BATTERY_LEVEL_TEST";
 
@@ -43,12 +46,14 @@
 
     private static final int FULL = 96;
 
-    private static final float SUBPIXEL = 0.4f;  // inset rects for softer edges
     private static final float BOLT_LEVEL_THRESHOLD = 0.3f;  // opaque bolt below this fraction
 
     private final int[] mColors;
 
     boolean mShowPercent = true;
+    private float mButtonHeightFraction;
+    private float mSubpixelSmoothingLeft;
+    private float mSubpixelSmoothingRight;
     private final Paint mFramePaint, mBatteryPaint, mWarningTextPaint, mTextPaint, mBoltPaint;
     private float mTextHeight, mWarningTextHeight;
 
@@ -68,6 +73,9 @@
     private final Path mClipPath = new Path();
     private final Path mTextPath = new Path();
 
+    private BatteryController mBatteryController;
+    private boolean mPowerSaveEnabled;
+
     private class BatteryTracker extends BroadcastReceiver {
         public static final int UNKNOWN_LEVEL = -1;
 
@@ -155,6 +163,7 @@
             // preload the battery level
             mTracker.onReceive(getContext(), sticky);
         }
+        mBatteryController.addStateChangedCallback(this);
     }
 
     @Override
@@ -162,6 +171,7 @@
         super.onDetachedFromWindow();
 
         getContext().unregisterReceiver(mTracker);
+        mBatteryController.removeStateChangedCallback(this);
     }
 
     public BatteryMeterView(Context context) {
@@ -197,6 +207,12 @@
         mWarningString = context.getString(R.string.battery_meter_very_low_overlay_symbol);
         mCriticalLevel = mContext.getResources().getInteger(
                 com.android.internal.R.integer.config_criticalBatteryWarningLevel);
+        mButtonHeightFraction = context.getResources().getFraction(
+                R.fraction.battery_button_height_fraction, 1, 1);
+        mSubpixelSmoothingLeft = context.getResources().getFraction(
+                R.fraction.battery_subpixel_smoothing_left, 1, 1);
+        mSubpixelSmoothingRight = context.getResources().getFraction(
+                R.fraction.battery_subpixel_smoothing_right, 1, 1);
 
         mFramePaint = new Paint(Paint.ANTI_ALIAS_FLAG);
         mFramePaint.setColor(frameColor);
@@ -227,6 +243,22 @@
         mBoltPoints = loadBoltPoints(res);
     }
 
+    public void setBatteryController(BatteryController batteryController) {
+        mBatteryController = batteryController;
+        mPowerSaveEnabled = mBatteryController.isPowerSave();
+    }
+
+    @Override
+    public void onBatteryLevelChanged(int level, boolean pluggedIn, boolean charging) {
+        // TODO: Use this callback instead of own broadcast receiver.
+    }
+
+    @Override
+    public void onPowerSaveChanged() {
+        mPowerSaveEnabled = mBatteryController.isPowerSave();
+        invalidate();
+    }
+
     private static float[] loadBoltPoints(Resources res) {
         final int[] pts = res.getIntArray(R.array.batterymeter_bolt_points);
         int maxX = 0, maxY = 0;
@@ -251,6 +283,11 @@
     }
 
     private int getColorForLevel(int percent) {
+
+        // If we are in power save mode, always use the normal color.
+        if (mPowerSaveEnabled) {
+            return mColors[mColors.length-1];
+        }
         int thresh, color = 0;
         for (int i=0; i<mColors.length; i+=2) {
             thresh = mColors[i];
@@ -275,28 +312,28 @@
         final int height = mHeight - pt - pb;
         final int width = mWidth - pl - pr;
 
-        final int buttonHeight = (int) (height * 0.12f);
+        final int buttonHeight = (int) (height * mButtonHeightFraction);
 
         mFrame.set(0, 0, width, height);
         mFrame.offset(pl, pt);
 
         // button-frame: area above the battery body
         mButtonFrame.set(
-                mFrame.left + width * 0.25f,
+                mFrame.left + Math.round(width * 0.25f),
                 mFrame.top,
-                mFrame.right - width * 0.25f,
+                mFrame.right - Math.round(width * 0.25f),
                 mFrame.top + buttonHeight);
 
-        mButtonFrame.top += SUBPIXEL;
-        mButtonFrame.left += SUBPIXEL;
-        mButtonFrame.right -= SUBPIXEL;
+        mButtonFrame.top += mSubpixelSmoothingLeft;
+        mButtonFrame.left += mSubpixelSmoothingLeft;
+        mButtonFrame.right -= mSubpixelSmoothingRight;
 
         // frame: battery body area
         mFrame.top += buttonHeight;
-        mFrame.left += SUBPIXEL;
-        mFrame.top += SUBPIXEL;
-        mFrame.right -= SUBPIXEL;
-        mFrame.bottom -= SUBPIXEL;
+        mFrame.left += mSubpixelSmoothingLeft;
+        mFrame.top += mSubpixelSmoothingLeft;
+        mFrame.right -= mSubpixelSmoothingRight;
+        mFrame.bottom -= mSubpixelSmoothingRight;
 
         // set the battery charging color
         mBatteryPaint.setColor(tracker.plugged ? mChargeColor : getColorForLevel(level));
diff --git a/packages/SystemUI/src/com/android/systemui/FontSizeUtils.java b/packages/SystemUI/src/com/android/systemui/FontSizeUtils.java
new file mode 100644
index 0000000..35a70a5
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/FontSizeUtils.java
@@ -0,0 +1,40 @@
+/*
+ * Copyright (C) 2014 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.systemui;
+
+import android.util.TypedValue;
+import android.view.View;
+import android.widget.TextView;
+
+/**
+ * Utility class to update the font size when the configuration has changed.
+ */
+public class FontSizeUtils {
+
+    public static final float LARGE_TEXT_SCALE = 1.3f;
+
+    public static void updateFontSize(View parent, int viewId, int dimensId) {
+        updateFontSize((TextView) parent.findViewById(viewId), dimensId);
+    }
+
+    public static void updateFontSize(TextView v, int dimensId) {
+        if (v != null) {
+            v.setTextSize(TypedValue.COMPLEX_UNIT_PX,
+                    v.getResources().getDimensionPixelSize(dimensId));
+        }
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/GuestResumeSessionReceiver.java b/packages/SystemUI/src/com/android/systemui/GuestResumeSessionReceiver.java
index 7f5ed6a..714b0a8 100644
--- a/packages/SystemUI/src/com/android/systemui/GuestResumeSessionReceiver.java
+++ b/packages/SystemUI/src/com/android/systemui/GuestResumeSessionReceiver.java
@@ -112,17 +112,23 @@
             return;
         }
 
-        userManager.removeUser(currentUser.id);
+        boolean marked = userManager.markGuestForDeletion(currentUser.id);
+        if (!marked) {
+            Log.w(TAG, "Couldn't mark the guest for deletion for user " + userId);
+            return;
+        }
         UserInfo newGuest = userManager.createGuest(context, currentUser.name);
 
         try {
             if (newGuest == null) {
                 Log.e(TAG, "Could not create new guest, switching back to owner");
                 ActivityManagerNative.getDefault().switchUser(UserHandle.USER_OWNER);
+                userManager.removeUser(currentUser.id);
                 WindowManagerGlobal.getWindowManagerService().lockNow(null /* options */);
                 return;
             }
             ActivityManagerNative.getDefault().switchUser(newGuest.id);
+            userManager.removeUser(currentUser.id);
         } catch (RemoteException e) {
             Log.e(TAG, "Couldn't wipe session because ActivityManager or WindowManager is dead");
             return;
diff --git a/packages/SystemUI/src/com/android/systemui/SearchPanelCircleView.java b/packages/SystemUI/src/com/android/systemui/SearchPanelCircleView.java
new file mode 100644
index 0000000..d8fb6da
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/SearchPanelCircleView.java
@@ -0,0 +1,592 @@
+/*
+ * Copyright (C) 2014 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.systemui;
+
+import android.animation.Animator;
+import android.animation.AnimatorListenerAdapter;
+import android.animation.PropertyValuesHolder;
+import android.animation.ValueAnimator;
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.Outline;
+import android.graphics.Paint;
+import android.graphics.Rect;
+import android.util.AttributeSet;
+import android.view.View;
+import android.view.ViewOutlineProvider;
+import android.view.animation.AnimationUtils;
+import android.view.animation.Interpolator;
+import android.view.animation.LinearInterpolator;
+import android.widget.FrameLayout;
+import android.widget.ImageView;
+import com.android.systemui.statusbar.phone.PhoneStatusBar;
+
+import java.util.ArrayList;
+
+public class SearchPanelCircleView extends FrameLayout {
+
+    private final int mCircleMinSize;
+    private final int mBaseMargin;
+    private final int mStaticOffset;
+    private final Paint mBackgroundPaint = new Paint();
+    private final Paint mRipplePaint = new Paint();
+    private final Rect mCircleRect = new Rect();
+    private final Rect mStaticRect = new Rect();
+    private final Interpolator mFastOutSlowInInterpolator;
+    private final Interpolator mAppearInterpolator;
+    private final Interpolator mDisappearInterpolator;
+
+    private boolean mClipToOutline;
+    private final int mMaxElevation;
+    private boolean mAnimatingOut;
+    private float mOutlineAlpha;
+    private float mOffset;
+    private float mCircleSize;
+    private boolean mHorizontal;
+    private boolean mCircleHidden;
+    private ImageView mLogo;
+    private boolean mDraggedFarEnough;
+    private boolean mOffsetAnimatingIn;
+    private float mCircleAnimationEndValue;
+    private ArrayList<Ripple> mRipples = new ArrayList<Ripple>();
+
+    private ValueAnimator mOffsetAnimator;
+    private ValueAnimator mCircleAnimator;
+    private ValueAnimator mFadeOutAnimator;
+    private ValueAnimator.AnimatorUpdateListener mCircleUpdateListener
+            = new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            applyCircleSize((float) animation.getAnimatedValue());
+            updateElevation();
+        }
+    };
+    private AnimatorListenerAdapter mClearAnimatorListener = new AnimatorListenerAdapter() {
+        @Override
+        public void onAnimationEnd(Animator animation) {
+            mCircleAnimator = null;
+        }
+    };
+    private ValueAnimator.AnimatorUpdateListener mOffsetUpdateListener
+            = new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            setOffset((float) animation.getAnimatedValue());
+        }
+    };
+
+
+    public SearchPanelCircleView(Context context) {
+        this(context, null);
+    }
+
+    public SearchPanelCircleView(Context context, AttributeSet attrs) {
+        this(context, attrs, 0);
+    }
+
+    public SearchPanelCircleView(Context context, AttributeSet attrs, int defStyleAttr) {
+        this(context, attrs, defStyleAttr, 0);
+    }
+
+    public SearchPanelCircleView(Context context, AttributeSet attrs, int defStyleAttr,
+            int defStyleRes) {
+        super(context, attrs, defStyleAttr, defStyleRes);
+        setOutlineProvider(new ViewOutlineProvider() {
+            @Override
+            public void getOutline(View view, Outline outline) {
+                if (mCircleSize > 0.0f) {
+                    outline.setOval(mCircleRect);
+                } else {
+                    outline.setEmpty();
+                }
+                outline.setAlpha(mOutlineAlpha);
+            }
+        });
+        setWillNotDraw(false);
+        mCircleMinSize = context.getResources().getDimensionPixelSize(
+                R.dimen.search_panel_circle_size);
+        mBaseMargin = context.getResources().getDimensionPixelSize(
+                R.dimen.search_panel_circle_base_margin);
+        mStaticOffset = context.getResources().getDimensionPixelSize(
+                R.dimen.search_panel_circle_travel_distance);
+        mMaxElevation = context.getResources().getDimensionPixelSize(
+                R.dimen.search_panel_circle_elevation);
+        mAppearInterpolator = AnimationUtils.loadInterpolator(mContext,
+                android.R.interpolator.linear_out_slow_in);
+        mFastOutSlowInInterpolator = AnimationUtils.loadInterpolator(mContext,
+                android.R.interpolator.fast_out_slow_in);
+        mDisappearInterpolator = AnimationUtils.loadInterpolator(mContext,
+                android.R.interpolator.fast_out_linear_in);
+        mBackgroundPaint.setAntiAlias(true);
+        mBackgroundPaint.setColor(getResources().getColor(R.color.search_panel_circle_color));
+        mRipplePaint.setColor(getResources().getColor(R.color.search_panel_ripple_color));
+        mRipplePaint.setAntiAlias(true);
+    }
+
+    @Override
+    protected void onDraw(Canvas canvas) {
+        super.onDraw(canvas);
+        drawBackground(canvas);
+        drawRipples(canvas);
+    }
+
+    private void drawRipples(Canvas canvas) {
+        for (int i = 0; i < mRipples.size(); i++) {
+            Ripple ripple = mRipples.get(i);
+            ripple.draw(canvas);
+        }
+    }
+
+    private void drawBackground(Canvas canvas) {
+        canvas.drawCircle(mCircleRect.centerX(), mCircleRect.centerY(), mCircleSize / 2,
+                mBackgroundPaint);
+    }
+
+    @Override
+    protected void onFinishInflate() {
+        super.onFinishInflate();
+        mLogo = (ImageView) findViewById(R.id.search_logo);
+    }
+
+    @Override
+    protected void onLayout(boolean changed, int l, int t, int r, int b) {
+        mLogo.layout(0, 0, mLogo.getMeasuredWidth(), mLogo.getMeasuredHeight());
+        if (changed) {
+            updateCircleRect(mStaticRect, mStaticOffset, true);
+        }
+    }
+
+    public void setCircleSize(float circleSize) {
+        setCircleSize(circleSize, false, null, 0, null);
+    }
+
+    public void setCircleSize(float circleSize, boolean animated, final Runnable endRunnable,
+            int startDelay, Interpolator interpolator) {
+        boolean isAnimating = mCircleAnimator != null;
+        boolean animationPending = isAnimating && !mCircleAnimator.isRunning();
+        boolean animatingOut = isAnimating && mCircleAnimationEndValue == 0;
+        if (animated || animationPending || animatingOut) {
+            if (isAnimating) {
+                if (circleSize == mCircleAnimationEndValue) {
+                    return;
+                }
+                mCircleAnimator.cancel();
+            }
+            mCircleAnimator = ValueAnimator.ofFloat(mCircleSize, circleSize);
+            mCircleAnimator.addUpdateListener(mCircleUpdateListener);
+            mCircleAnimator.addListener(mClearAnimatorListener);
+            mCircleAnimator.addListener(new AnimatorListenerAdapter() {
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    if (endRunnable != null) {
+                        endRunnable.run();
+                    }
+                }
+            });
+            Interpolator desiredInterpolator = interpolator != null ? interpolator
+                    : circleSize == 0 ? mDisappearInterpolator : mAppearInterpolator;
+            mCircleAnimator.setInterpolator(desiredInterpolator);
+            mCircleAnimator.setDuration(300);
+            mCircleAnimator.setStartDelay(startDelay);
+            mCircleAnimator.start();
+            mCircleAnimationEndValue = circleSize;
+        } else {
+            if (isAnimating) {
+                float diff = circleSize - mCircleAnimationEndValue;
+                PropertyValuesHolder[] values = mCircleAnimator.getValues();
+                values[0].setFloatValues(diff, circleSize);
+                mCircleAnimator.setCurrentPlayTime(mCircleAnimator.getCurrentPlayTime());
+                mCircleAnimationEndValue = circleSize;
+            } else {
+                applyCircleSize(circleSize);
+                updateElevation();
+            }
+        }
+    }
+
+    private void applyCircleSize(float circleSize) {
+        mCircleSize = circleSize;
+        updateLayout();
+    }
+
+    private void updateElevation() {
+        float t = (mStaticOffset - mOffset) / (float) mStaticOffset;
+        t = 1.0f - Math.max(t, 0.0f);
+        float offset = t * mMaxElevation;
+        setElevation(offset);
+    }
+
+    /**
+     * Sets the offset to the edge of the screen. By default this not not animated.
+     *
+     * @param offset The offset to apply.
+     */
+    public void setOffset(float offset) {
+        setOffset(offset, false, 0, null, null);
+    }
+
+    /**
+     * Sets the offset to the edge of the screen.
+     *
+     * @param offset The offset to apply.
+     * @param animate Whether an animation should be performed.
+     * @param startDelay The desired start delay if animated.
+     * @param interpolator The desired interpolator if animated. If null,
+     *                     a default interpolator will be taken designed for appearing or
+     *                     disappearing.
+     * @param endRunnable The end runnable which should be executed when the animation is finished.
+     */
+    private void setOffset(float offset, boolean animate, int startDelay,
+            Interpolator interpolator, final Runnable endRunnable) {
+        if (!animate) {
+            mOffset = offset;
+            updateLayout();
+            if (endRunnable != null) {
+                endRunnable.run();
+            }
+        } else {
+            if (mOffsetAnimator != null) {
+                mOffsetAnimator.removeAllListeners();
+                mOffsetAnimator.cancel();
+            }
+            mOffsetAnimator = ValueAnimator.ofFloat(mOffset, offset);
+            mOffsetAnimator.addUpdateListener(mOffsetUpdateListener);
+            mOffsetAnimator.addListener(new AnimatorListenerAdapter() {
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    mOffsetAnimator = null;
+                    if (endRunnable != null) {
+                        endRunnable.run();
+                    }
+                }
+            });
+            Interpolator desiredInterpolator = interpolator != null ?
+                    interpolator : offset == 0 ? mDisappearInterpolator : mAppearInterpolator;
+            mOffsetAnimator.setInterpolator(desiredInterpolator);
+            mOffsetAnimator.setStartDelay(startDelay);
+            mOffsetAnimator.setDuration(300);
+            mOffsetAnimator.start();
+            mOffsetAnimatingIn = offset != 0;
+        }
+    }
+
+    private void updateLayout() {
+        updateCircleRect();
+        updateLogo();
+        invalidateOutline();
+        invalidate();
+        updateClipping();
+    }
+
+    private void updateClipping() {
+        boolean clip = mCircleSize < mCircleMinSize || !mRipples.isEmpty();
+        if (clip != mClipToOutline) {
+            setClipToOutline(clip);
+            mClipToOutline = clip;
+        }
+    }
+
+    private void updateLogo() {
+        boolean exitAnimationRunning = mFadeOutAnimator != null;
+        Rect rect = exitAnimationRunning ? mCircleRect : mStaticRect;
+        float translationX = (rect.left + rect.right) / 2.0f - mLogo.getWidth() / 2.0f;
+        float translationY = (rect.top + rect.bottom) / 2.0f - mLogo.getHeight() / 2.0f;
+        float t = (mStaticOffset - mOffset) / (float) mStaticOffset;
+        if (!exitAnimationRunning) {
+            if (mHorizontal) {
+                translationX += t * mStaticOffset * 0.3f;
+            } else {
+                translationY += t * mStaticOffset * 0.3f;
+            }
+            float alpha = 1.0f-t;
+            alpha = Math.max((alpha - 0.5f) * 2.0f, 0);
+            mLogo.setAlpha(alpha);
+        } else {
+            translationY += (mOffset - mStaticOffset) / 2;
+        }
+        mLogo.setTranslationX(translationX);
+        mLogo.setTranslationY(translationY);
+    }
+
+    private void updateCircleRect() {
+        updateCircleRect(mCircleRect, mOffset, false);
+    }
+
+    private void updateCircleRect(Rect rect, float offset, boolean useStaticSize) {
+        int left, top;
+        float circleSize = useStaticSize ? mCircleMinSize : mCircleSize;
+        if (mHorizontal) {
+            left = (int) (getWidth() - circleSize / 2 - mBaseMargin - offset);
+            top = (int) ((getHeight() - circleSize) / 2);
+        } else {
+            left = (int) (getWidth() - circleSize) / 2;
+            top = (int) (getHeight() - circleSize / 2 - mBaseMargin - offset);
+        }
+        rect.set(left, top, (int) (left + circleSize), (int) (top + circleSize));
+    }
+
+    public void setHorizontal(boolean horizontal) {
+        mHorizontal = horizontal;
+        updateCircleRect(mStaticRect, mStaticOffset, true);
+        updateLayout();
+    }
+
+    public void setDragDistance(float distance) {
+        if (!mAnimatingOut && (!mCircleHidden || mDraggedFarEnough)) {
+            float circleSize = mCircleMinSize + rubberband(distance);
+            setCircleSize(circleSize);
+        }
+
+    }
+
+    private float rubberband(float diff) {
+        return (float) Math.pow(Math.abs(diff), 0.6f);
+    }
+
+    public void startAbortAnimation(Runnable endRunnable) {
+        if (mAnimatingOut) {
+            if (endRunnable != null) {
+                endRunnable.run();
+            }
+            return;
+        }
+        setCircleSize(0, true, null, 0, null);
+        setOffset(0, true, 0, null, endRunnable);
+        mCircleHidden = true;
+    }
+
+    public void startEnterAnimation() {
+        if (mAnimatingOut) {
+            return;
+        }
+        applyCircleSize(0);
+        setOffset(0);
+        setCircleSize(mCircleMinSize, true, null, 50, null);
+        setOffset(mStaticOffset, true, 50, null, null);
+        mCircleHidden = false;
+    }
+
+
+    public void startExitAnimation(final Runnable endRunnable) {
+        if (!mHorizontal) {
+            float offset = getHeight() / 2.0f;
+            setOffset(offset - mBaseMargin, true, 50, mFastOutSlowInInterpolator, null);
+            float xMax = getWidth() / 2;
+            float yMax = getHeight() / 2;
+            float maxRadius = (float) Math.ceil(Math.hypot(xMax, yMax) * 2);
+            setCircleSize(maxRadius, true, null, 50, mFastOutSlowInInterpolator);
+            performExitFadeOutAnimation(50, 300, endRunnable);
+        } else {
+
+            // when in landscape, we don't wan't the animation as it interferes with the general
+            // rotation animation to the homescreen.
+            endRunnable.run();
+        }
+    }
+
+    private void performExitFadeOutAnimation(int startDelay, int duration,
+            final Runnable endRunnable) {
+        mFadeOutAnimator = ValueAnimator.ofFloat(mBackgroundPaint.getAlpha() / 255.0f, 0.0f);
+
+        // Linear since we are animating multiple values
+        mFadeOutAnimator.setInterpolator(new LinearInterpolator());
+        mFadeOutAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
+            @Override
+            public void onAnimationUpdate(ValueAnimator animation) {
+                float animatedFraction = animation.getAnimatedFraction();
+                float logoValue = animatedFraction > 0.5f ? 1.0f : animatedFraction / 0.5f;
+                logoValue = PhoneStatusBar.ALPHA_OUT.getInterpolation(1.0f - logoValue);
+                float backgroundValue = animatedFraction < 0.2f ? 0.0f :
+                        PhoneStatusBar.ALPHA_OUT.getInterpolation((animatedFraction - 0.2f) / 0.8f);
+                backgroundValue = 1.0f - backgroundValue;
+                mBackgroundPaint.setAlpha((int) (backgroundValue * 255));
+                mOutlineAlpha = backgroundValue;
+                mLogo.setAlpha(logoValue);
+                invalidateOutline();
+                invalidate();
+            }
+        });
+        mFadeOutAnimator.addListener(new AnimatorListenerAdapter() {
+            @Override
+            public void onAnimationEnd(Animator animation) {
+                if (endRunnable != null) {
+                    endRunnable.run();
+                }
+                mLogo.setAlpha(1.0f);
+                mBackgroundPaint.setAlpha(255);
+                mOutlineAlpha = 1.0f;
+                mFadeOutAnimator = null;
+            }
+        });
+        mFadeOutAnimator.setStartDelay(startDelay);
+        mFadeOutAnimator.setDuration(duration);
+        mFadeOutAnimator.start();
+    }
+
+    public void setDraggedFarEnough(boolean farEnough) {
+        if (farEnough != mDraggedFarEnough) {
+            if (farEnough) {
+                if (mCircleHidden) {
+                    startEnterAnimation();
+                }
+                if (mOffsetAnimator == null) {
+                    addRipple();
+                } else {
+                    postDelayed(new Runnable() {
+                        @Override
+                        public void run() {
+                            addRipple();
+                        }
+                    }, 100);
+                }
+            } else {
+                startAbortAnimation(null);
+            }
+            mDraggedFarEnough = farEnough;
+        }
+
+    }
+
+    private void addRipple() {
+        if (mRipples.size() > 1) {
+            // we only want 2 ripples at the time
+            return;
+        }
+        float xInterpolation, yInterpolation;
+        if (mHorizontal) {
+            xInterpolation = 0.75f;
+            yInterpolation = 0.5f;
+        } else {
+            xInterpolation = 0.5f;
+            yInterpolation = 0.75f;
+        }
+        float circleCenterX = mStaticRect.left * (1.0f - xInterpolation)
+                + mStaticRect.right * xInterpolation;
+        float circleCenterY = mStaticRect.top * (1.0f - yInterpolation)
+                + mStaticRect.bottom * yInterpolation;
+        float radius = Math.max(mCircleSize, mCircleMinSize * 1.25f) * 0.75f;
+        Ripple ripple = new Ripple(circleCenterX, circleCenterY, radius);
+        ripple.start();
+    }
+
+    public void reset() {
+        mDraggedFarEnough = false;
+        mAnimatingOut = false;
+        mCircleHidden = true;
+        mClipToOutline = false;
+        if (mFadeOutAnimator != null) {
+            mFadeOutAnimator.cancel();
+        }
+        mBackgroundPaint.setAlpha(255);
+        mOutlineAlpha = 1.0f;
+    }
+
+    /**
+     * Check if an animation is currently running
+     *
+     * @param enterAnimation Is the animating queried the enter animation.
+     */
+    public boolean isAnimationRunning(boolean enterAnimation) {
+        return mOffsetAnimator != null && (enterAnimation == mOffsetAnimatingIn);
+    }
+
+    public void performOnAnimationFinished(final Runnable runnable) {
+        if (mOffsetAnimator != null) {
+            mOffsetAnimator.addListener(new AnimatorListenerAdapter() {
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    if (runnable != null) {
+                        runnable.run();
+                    }
+                }
+            });
+        } else {
+            if (runnable != null) {
+                runnable.run();
+            }
+        }
+    }
+
+    public void setAnimatingOut(boolean animatingOut) {
+        mAnimatingOut = animatingOut;
+    }
+
+    /**
+     * @return Whether the circle is currently launching to the search activity or aborting the
+     * interaction
+     */
+    public boolean isAnimatingOut() {
+        return mAnimatingOut;
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+        // not really true but it's ok during an animation, as it's never permanent
+        return false;
+    }
+
+    private class Ripple {
+        float x;
+        float y;
+        float radius;
+        float endRadius;
+        float alpha;
+
+        Ripple(float x, float y, float endRadius) {
+            this.x = x;
+            this.y = y;
+            this.endRadius = endRadius;
+        }
+
+        void start() {
+            ValueAnimator animator = ValueAnimator.ofFloat(0.0f, 1.0f);
+
+            // Linear since we are animating multiple values
+            animator.setInterpolator(new LinearInterpolator());
+            animator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
+                @Override
+                public void onAnimationUpdate(ValueAnimator animation) {
+                    alpha = 1.0f - animation.getAnimatedFraction();
+                    alpha = mDisappearInterpolator.getInterpolation(alpha);
+                    radius = mAppearInterpolator.getInterpolation(animation.getAnimatedFraction());
+                    radius *= endRadius;
+                    invalidate();
+                }
+            });
+            animator.addListener(new AnimatorListenerAdapter() {
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    mRipples.remove(Ripple.this);
+                    updateClipping();
+                }
+
+                public void onAnimationStart(Animator animation) {
+                    mRipples.add(Ripple.this);
+                    updateClipping();
+                }
+            });
+            animator.setDuration(400);
+            animator.start();
+        }
+
+        public void draw(Canvas canvas) {
+            mRipplePaint.setAlpha((int) (alpha * 255));
+            canvas.drawCircle(x, y, radius, mRipplePaint);
+        }
+    }
+
+}
diff --git a/packages/SystemUI/src/com/android/systemui/SearchPanelView.java b/packages/SystemUI/src/com/android/systemui/SearchPanelView.java
index 7d0ca14..445b499 100644
--- a/packages/SystemUI/src/com/android/systemui/SearchPanelView.java
+++ b/packages/SystemUI/src/com/android/systemui/SearchPanelView.java
@@ -16,10 +16,6 @@
 
 package com.android.systemui;
 
-import android.animation.Animator;
-import android.animation.AnimatorListenerAdapter;
-import android.animation.ObjectAnimator;
-import android.animation.PropertyValuesHolder;
 import android.app.ActivityOptions;
 import android.app.SearchManager;
 import android.content.ActivityNotFoundException;
@@ -38,8 +34,6 @@
 import android.util.Log;
 import android.view.MotionEvent;
 import android.view.View;
-import android.view.animation.AnimationUtils;
-import android.view.animation.Interpolator;
 import android.widget.FrameLayout;
 import android.widget.ImageView;
 
@@ -62,26 +56,19 @@
     private final Context mContext;
     private BaseStatusBar mBar;
 
-    private View mCard;
+    private SearchPanelCircleView mCircle;
     private ImageView mLogo;
     private View mScrim;
 
-    private int mPeekHeight;
     private int mThreshold;
     private boolean mHorizontal;
-    private final Interpolator mLinearOutSlowInInterpolator;
-    private final Interpolator mFastOutLinearInInterpolator;
 
-    private boolean mAnimatingIn;
-    private boolean mAnimatingOut;
+    private boolean mLaunching;
     private boolean mDragging;
     private boolean mDraggedFarEnough;
     private float mStartTouch;
     private float mStartDrag;
-
-    private ObjectAnimator mEnterAnimator;
-
-    private boolean mStartExitAfterAnimatingIn;
+    private boolean mLaunchPending;
 
     public SearchPanelView(Context context, AttributeSet attrs) {
         this(context, attrs, 0);
@@ -90,12 +77,7 @@
     public SearchPanelView(Context context, AttributeSet attrs, int defStyle) {
         super(context, attrs, defStyle);
         mContext = context;
-        mPeekHeight = context.getResources().getDimensionPixelSize(R.dimen.search_card_peek_height);
         mThreshold = context.getResources().getDimensionPixelSize(R.dimen.search_panel_threshold);
-        mLinearOutSlowInInterpolator =
-                AnimationUtils.loadInterpolator(context, android.R.interpolator.linear_out_slow_in);
-        mFastOutLinearInInterpolator =
-                AnimationUtils.loadInterpolator(context, android.R.interpolator.fast_out_linear_in);
     }
 
     private void startAssistActivity() {
@@ -128,7 +110,7 @@
     protected void onFinishInflate() {
         super.onFinishInflate();
         mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
-        mCard = findViewById(R.id.search_panel_card);
+        mCircle = (SearchPanelCircleView) findViewById(R.id.search_panel_circle);
         mLogo = (ImageView) findViewById(R.id.search_logo);
         mScrim = findViewById(R.id.search_panel_scrim);
     }
@@ -170,16 +152,9 @@
         v.setImageDrawable(null);
     }
 
-    private boolean pointInside(int x, int y, View v) {
-        final int l = v.getLeft();
-        final int r = v.getRight();
-        final int t = v.getTop();
-        final int b = v.getBottom();
-        return x >= l && x < r && y >= t && y < b;
-    }
-
+    @Override
     public boolean isInContentArea(int x, int y) {
-        return pointInside(x, y, mCard);
+        return true;
     }
 
     private void vibrate() {
@@ -199,16 +174,10 @@
             if (getVisibility() != View.VISIBLE) {
                 setVisibility(View.VISIBLE);
                 vibrate();
-                mCard.setAlpha(1f);
                 if (animate) {
                     startEnterAnimation();
                 } else {
                     mScrim.setAlpha(1f);
-                    if (mHorizontal) {
-                        mCard.setX(getWidth() - mPeekHeight);
-                    } else {
-                        mCard.setY(getHeight() - mPeekHeight);
-                    }
                 }
             }
             setFocusable(true);
@@ -224,30 +193,7 @@
     }
 
     private void startEnterAnimation() {
-        if (mHorizontal) {
-            mCard.setX(getWidth());
-        } else {
-            mCard.setY(getHeight());
-        }
-        mAnimatingIn = true;
-        mCard.animate().cancel();
-        mEnterAnimator = ObjectAnimator.ofFloat(mCard, mHorizontal ? View.X : View.Y,
-                mHorizontal ? mCard.getX() : mCard.getY(),
-                mHorizontal ? getWidth() - mPeekHeight : getHeight() - mPeekHeight);
-        mEnterAnimator.setDuration(300);
-        mEnterAnimator.setStartDelay(50);
-        mEnterAnimator.setInterpolator(mLinearOutSlowInInterpolator);
-        mEnterAnimator.addListener(new AnimatorListenerAdapter() {
-            @Override
-            public void onAnimationEnd(Animator animation) {
-                mEnterAnimator = null;
-                mAnimatingIn = false;
-                if (mStartExitAfterAnimatingIn) {
-                    startExitAnimation();
-                }
-            }
-        });
-        mEnterAnimator.start();
+        mCircle.startEnterAnimation();
         mScrim.setAlpha(0f);
         mScrim.animate()
                 .alpha(1f)
@@ -259,26 +205,17 @@
     }
 
     private void startAbortAnimation() {
-        mCard.animate().cancel();
-        mAnimatingOut = true;
-        if (mHorizontal) {
-            mCard.animate().x(getWidth());
-        } else {
-            mCard.animate().y(getHeight());
-        }
-        mCard.animate()
-                .setDuration(150)
-                .setInterpolator(mFastOutLinearInInterpolator)
-                .withEndAction(new Runnable() {
+        mCircle.startAbortAnimation(new Runnable() {
                     @Override
                     public void run() {
-                        mAnimatingOut = false;
+                        mCircle.setAnimatingOut(false);
                         setVisibility(View.INVISIBLE);
                     }
                 });
+        mCircle.setAnimatingOut(true);
         mScrim.animate()
                 .alpha(0f)
-                .setDuration(150)
+                .setDuration(300)
                 .setStartDelay(0)
                 .setInterpolator(PhoneStatusBar.ALPHA_OUT);
     }
@@ -314,7 +251,7 @@
      * when the animation is done.
      */
     public boolean isShowing() {
-        return getVisibility() == View.VISIBLE && !mAnimatingOut;
+        return getVisibility() == View.VISIBLE && !mCircle.isAnimatingOut();
     }
 
     public void setBar(BaseStatusBar bar) {
@@ -326,60 +263,46 @@
                 .getAssistIntent(mContext, false, UserHandle.USER_CURRENT) != null;
     }
 
-    private float rubberband(float diff) {
-        return Math.signum(diff) * (float) Math.pow(Math.abs(diff), 0.8f);
-    }
-
     @Override
     public boolean onTouchEvent(MotionEvent event) {
+        if (mLaunching || mLaunchPending) {
+            return false;
+        }
         int action = event.getActionMasked();
         switch (action) {
             case MotionEvent.ACTION_DOWN:
                 mStartTouch = mHorizontal ? event.getX() : event.getY();
                 mDragging = false;
                 mDraggedFarEnough = false;
-                mStartExitAfterAnimatingIn = false;
+                mCircle.reset();
                 break;
             case MotionEvent.ACTION_MOVE:
                 float currentTouch = mHorizontal ? event.getX() : event.getY();
                 if (getVisibility() == View.VISIBLE && !mDragging &&
-                        (!mAnimatingIn || Math.abs(mStartTouch - currentTouch) > mThreshold)) {
+                        (!mCircle.isAnimationRunning(true /* enterAnimation */)
+                                || Math.abs(mStartTouch - currentTouch) > mThreshold)) {
                     mStartDrag = currentTouch;
                     mDragging = true;
                 }
-                if (!mDraggedFarEnough && Math.abs(mStartTouch - currentTouch) > mThreshold) {
-                    mDraggedFarEnough = true;
-                }
                 if (mDragging) {
-                    if (!mAnimatingIn && !mAnimatingOut) {
-                        if (Math.abs(currentTouch - mStartDrag) > mThreshold) {
-                            startExitAnimation();
-                        } else {
-                            if (mHorizontal) {
-                                mCard.setX(getWidth() - mPeekHeight + rubberband(
-                                        currentTouch - mStartDrag));
-                            } else {
-                                mCard.setY(getHeight() - mPeekHeight + rubberband(
-                                        currentTouch - mStartDrag));
-                            }
-                        }
-                    } else if (mAnimatingIn ) {
-                        float diff = rubberband(currentTouch - mStartDrag);
-                        PropertyValuesHolder[] values = mEnterAnimator.getValues();
-                        values[0].setFloatValues(
-                                mHorizontal ? getWidth() + diff : getHeight() + diff,
-                                mHorizontal
-                                        ? getWidth() - mPeekHeight + diff
-                                        : getHeight() - mPeekHeight + diff);
-                        mEnterAnimator.setCurrentPlayTime(mEnterAnimator.getCurrentPlayTime());
-                    }
+                    float offset = Math.max(mStartDrag - currentTouch, 0.0f);
+                    mCircle.setDragDistance(offset);
+                    mDraggedFarEnough = Math.abs(mStartTouch - currentTouch) > mThreshold;
+                    mCircle.setDraggedFarEnough(mDraggedFarEnough);
                 }
                 break;
             case MotionEvent.ACTION_UP:
             case MotionEvent.ACTION_CANCEL:
                 if (mDraggedFarEnough) {
-                    if (mAnimatingIn) {
-                        mStartExitAfterAnimatingIn = true;
+                    if (mCircle.isAnimationRunning(true  /* enterAnimation */)) {
+                        mLaunchPending = true;
+                        mCircle.setAnimatingOut(true);
+                        mCircle.performOnAnimationFinished(new Runnable() {
+                            @Override
+                            public void run() {
+                                startExitAnimation();
+                            }
+                        });
                     } else {
                         startExitAnimation();
                     }
@@ -392,35 +315,31 @@
     }
 
     private void startExitAnimation() {
-        if (mAnimatingOut || getVisibility() != View.VISIBLE) {
+        mLaunchPending = false;
+        if (mLaunching || getVisibility() != View.VISIBLE) {
             return;
         }
-        if (mEnterAnimator != null) {
-            mEnterAnimator.cancel();
-        }
-        mAnimatingOut = true;
+        mLaunching = true;
         startAssistActivity();
         vibrate();
-        mCard.animate()
-                .alpha(0f)
-                .withLayer()
-                .setDuration(250)
-                .setInterpolator(PhoneStatusBar.ALPHA_OUT)
-                .withEndAction(new Runnable() {
+        mCircle.setAnimatingOut(true);
+        mCircle.startExitAnimation(new Runnable() {
                     @Override
                     public void run() {
-                        mAnimatingOut = false;
+                        mLaunching = false;
+                        mCircle.setAnimatingOut(false);
                         setVisibility(View.INVISIBLE);
                     }
                 });
         mScrim.animate()
                 .alpha(0f)
-                .setDuration(250)
+                .setDuration(300)
                 .setStartDelay(0)
                 .setInterpolator(PhoneStatusBar.ALPHA_OUT);
     }
 
     public void setHorizontal(boolean horizontal) {
         mHorizontal = horizontal;
+        mCircle.setHorizontal(horizontal);
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/SwipeHelper.java b/packages/SystemUI/src/com/android/systemui/SwipeHelper.java
index a18b0c0..8e603ba 100644
--- a/packages/SystemUI/src/com/android/systemui/SwipeHelper.java
+++ b/packages/SystemUI/src/com/android/systemui/SwipeHelper.java
@@ -81,6 +81,8 @@
     private long mLongPressTimeout;
 
     final private int[] mTmpPos = new int[2];
+    private int mFalsingThreshold;
+    private boolean mTouchAboveFalsingThreshold;
 
     public SwipeHelper(int swipeDirection, Callback callback, Context context) {
         mCallback = callback;
@@ -93,6 +95,8 @@
         mLongPressTimeout = (long) (ViewConfiguration.getLongPressTimeout() * 1.5f); // extra long-press!
         mFastOutLinearInInterpolator = AnimationUtils.loadInterpolator(context,
                 android.R.interpolator.fast_out_linear_in);
+        mFalsingThreshold = context.getResources().getDimensionPixelSize(
+                R.dimen.swipe_helper_falsing_threshold);
     }
 
     public void setLongPressListener(LongPressListener listener) {
@@ -222,6 +226,7 @@
 
         switch (action) {
             case MotionEvent.ACTION_DOWN:
+                mTouchAboveFalsingThreshold = false;
                 mDragging = false;
                 mLongPressSent = false;
                 mCurrView = mCallback.getChildAtPosition(ev);
@@ -406,12 +411,16 @@
             case MotionEvent.ACTION_MOVE:
                 if (mCurrView != null) {
                     float delta = getPos(ev) - mInitialTouchPos;
+                    float absDelta = Math.abs(delta);
+                    if (absDelta >= mFalsingThreshold) {
+                        mTouchAboveFalsingThreshold = true;
+                    }
                     // don't let items that can't be dismissed be dragged more than
                     // maxScrollDistance
                     if (CONSTRAIN_SWIPE && !mCallback.canChildBeDismissed(mCurrView)) {
                         float size = getSize(mCurrAnimView);
                         float maxScrollDistance = 0.15f * size;
-                        if (Math.abs(delta) >= size) {
+                        if (absDelta >= size) {
                             delta = delta > 0 ? maxScrollDistance : -maxScrollDistance;
                         } else {
                             delta = maxScrollDistance * (float) Math.sin((delta/size)*(Math.PI/2));
@@ -437,9 +446,11 @@
                     boolean childSwipedFastEnough = (Math.abs(velocity) > escapeVelocity) &&
                             (Math.abs(velocity) > Math.abs(perpendicularVelocity)) &&
                             (velocity > 0) == (getTranslation(mCurrAnimView) > 0);
+                    boolean falsingDetected = mCallback.isAntiFalsingNeeded()
+                            && !mTouchAboveFalsingThreshold;
 
-                    boolean dismissChild = mCallback.canChildBeDismissed(mCurrView) &&
-                            (childSwipedFastEnough || childSwipedFarEnough);
+                    boolean dismissChild = mCallback.canChildBeDismissed(mCurrView)
+                            && !falsingDetected && (childSwipedFastEnough || childSwipedFarEnough);
 
                     if (dismissChild) {
                         // flingadingy
@@ -462,6 +473,8 @@
 
         boolean canChildBeDismissed(View v);
 
+        boolean isAntiFalsingNeeded();
+
         void onBeginDrag(View v);
 
         void onChildDismissed(View v);
diff --git a/packages/SystemUI/src/com/android/systemui/doze/DozeService.java b/packages/SystemUI/src/com/android/systemui/doze/DozeService.java
index 74c0328..e2c8ff9 100644
--- a/packages/SystemUI/src/com/android/systemui/doze/DozeService.java
+++ b/packages/SystemUI/src/com/android/systemui/doze/DozeService.java
@@ -16,16 +16,12 @@
 
 package com.android.systemui.doze;
 
-import static android.os.PowerManager.BRIGHTNESS_OFF;
-import static android.os.PowerManager.BRIGHTNESS_ON;
-
 import android.app.AlarmManager;
 import android.app.PendingIntent;
 import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
 import android.content.IntentFilter;
-import android.content.res.Resources;
 import android.hardware.Sensor;
 import android.hardware.SensorManager;
 import android.hardware.TriggerEvent;
@@ -33,15 +29,14 @@
 import android.media.AudioAttributes;
 import android.os.Handler;
 import android.os.PowerManager;
-import android.os.SystemProperties;
 import android.os.Vibrator;
 import android.service.dreams.DreamService;
 import android.util.Log;
-import android.util.MathUtils;
 import android.view.Display;
 
-import com.android.systemui.R;
 import com.android.systemui.SystemUIApplication;
+import com.android.systemui.statusbar.phone.DozeParameters;
+import com.android.systemui.statusbar.phone.DozeParameters.PulseSchedule;
 
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
@@ -54,11 +49,11 @@
     private static final String ACTION_BASE = "com.android.systemui.doze";
     private static final String PULSE_ACTION = ACTION_BASE + ".pulse";
     private static final String NOTIFICATION_PULSE_ACTION = ACTION_BASE + ".notification_pulse";
-    private static final String EXTRA_PULSES = "pulses";
 
     private final String mTag = String.format(TAG + ".%08x", hashCode());
     private final Context mContext = this;
     private final Handler mHandler = new Handler();
+    private final DozeParameters mDozeParameters = new DozeParameters(mContext);
 
     private Host mHost;
     private SensorManager mSensors;
@@ -67,15 +62,15 @@
     private PowerManager mPowerManager;
     private PowerManager.WakeLock mWakeLock;
     private AlarmManager mAlarmManager;
-    private int mMaxBrightness;
     private boolean mDreaming;
     private boolean mBroadcastReceiverRegistered;
     private boolean mDisplayStateSupported;
     private int mDisplayStateWhenOn;
     private boolean mNotificationLightOn;
     private PendingIntent mNotificationPulseIntent;
-    private int mMultipulseCount;
-    private int mNotificationPulseInterval;
+    private boolean mPowerSaveActive;
+    private long mNotificationPulseTime;
+    private int mScheduleResetsRemaining;
 
     public DozeService() {
         if (DEBUG) Log.d(mTag, "new DozeService()");
@@ -86,14 +81,16 @@
     protected void dumpOnHandler(FileDescriptor fd, PrintWriter pw, String[] args) {
         super.dumpOnHandler(fd, pw, args);
         pw.print("  mDreaming: "); pw.println(mDreaming);
+        pw.print("  mHost: "); pw.println(mHost);
         pw.print("  mBroadcastReceiverRegistered: "); pw.println(mBroadcastReceiverRegistered);
         pw.print("  mSigMotionSensor: "); pw.println(mSigMotionSensor);
         pw.print("  mPickupSensor:"); pw.println(mPickupSensor);
-        pw.print("  mMaxBrightness: "); pw.println(mMaxBrightness);
         pw.print("  mDisplayStateSupported: "); pw.println(mDisplayStateSupported);
         pw.print("  mNotificationLightOn: "); pw.println(mNotificationLightOn);
-        pw.print("  mMultipulseCount: "); pw.println(mMultipulseCount);
-        pw.print("  mNotificationPulseInterval: "); pw.println(mNotificationPulseInterval);
+        pw.print("  mPowerSaveActive: "); pw.println(mPowerSaveActive);
+        pw.print("  mNotificationPulseTime: "); pw.println(mNotificationPulseTime);
+        pw.print("  mScheduleResetsRemaining: "); pw.println(mScheduleResetsRemaining);
+        mDozeParameters.dump(pw);
     }
 
     @Override
@@ -105,31 +102,24 @@
             final SystemUIApplication app = (SystemUIApplication) getApplication();
             mHost = app.getComponent(Host.class);
         }
+        if (mHost == null) Log.w(TAG, "No doze service host found.");
 
         setWindowless(true);
 
         mSensors = (SensorManager) mContext.getSystemService(Context.SENSOR_SERVICE);
-        mSigMotionSensor = new TriggerSensor(Sensor.TYPE_SIGNIFICANT_MOTION, "doze.pulse.sigmotion",
-                R.bool.doze_pulse_on_significant_motion);
-        mPickupSensor = new TriggerSensor(Sensor.TYPE_PICK_UP_GESTURE, "doze.pulse.pickup",
-                R.bool.doze_pulse_on_pick_up);
+        mSigMotionSensor = new TriggerSensor(Sensor.TYPE_SIGNIFICANT_MOTION,
+                mDozeParameters.getPulseOnSigMotion(), mDozeParameters.getVibrateOnSigMotion());
+        mPickupSensor = new TriggerSensor(Sensor.TYPE_PICK_UP_GESTURE,
+                mDozeParameters.getPulseOnPickup(), mDozeParameters.getVibrateOnPickup());
         mPowerManager = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
         mWakeLock = mPowerManager.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, mTag);
         mAlarmManager = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE);
-        final Resources res = mContext.getResources();
-        mDisplayStateSupported = SystemProperties.getBoolean("doze.display.supported",
-                res.getBoolean(R.bool.doze_display_state_supported));
-        mMaxBrightness = MathUtils.constrain(res.getInteger(R.integer.doze_pulse_brightness),
-                BRIGHTNESS_OFF, BRIGHTNESS_ON);
+        mDisplayStateSupported = mDozeParameters.getDisplayStateSupported();
         mNotificationPulseIntent = PendingIntent.getBroadcast(mContext, 0,
                 new Intent(NOTIFICATION_PULSE_ACTION).setPackage(getPackageName()),
-                PendingIntent.FLAG_CANCEL_CURRENT);
-        mMultipulseCount = SystemProperties.getInt("doze.multipulses",
-                res.getInteger(R.integer.doze_multipulse_count));
-        mNotificationPulseInterval = SystemProperties.getInt("doze.notification.pulse",
-                res.getInteger(R.integer.doze_notification_pulse_interval));
+                PendingIntent.FLAG_UPDATE_CURRENT);
         mDisplayStateWhenOn = mDisplayStateSupported ? Display.STATE_DOZE : Display.STATE_ON;
-        setDozeScreenState(mDisplayStateWhenOn);
+        mDisplayOff.run();
     }
 
     @Override
@@ -141,17 +131,24 @@
     @Override
     public void onDreamingStarted() {
         super.onDreamingStarted();
-        if (DEBUG) Log.d(mTag, "onDreamingStarted canDoze=" + canDoze());
+        mPowerSaveActive = mHost != null && mHost.isPowerSaveActive();
+        if (DEBUG) Log.d(mTag, "onDreamingStarted canDoze=" + canDoze() + " mPowerSaveActive="
+                + mPowerSaveActive);
+        if (mPowerSaveActive) {
+            finishToSavePower();
+            return;
+        }
         mDreaming = true;
         listenForPulseSignals(true);
+        rescheduleNotificationPulse(false /*predicate*/);  // cancel any pending pulse alarms
         requestDoze();
     }
 
     public void stayAwake(long millis) {
         if (mDreaming && millis > 0) {
+            if (DEBUG) Log.d(mTag, "stayAwake millis=" + millis);
             mWakeLock.acquire(millis);
             setDozeScreenState(mDisplayStateWhenOn);
-            setDozeScreenBrightness(mMaxBrightness);
             rescheduleOff(millis);
         }
     }
@@ -162,16 +159,6 @@
         mHandler.postDelayed(mDisplayOff, millis);
     }
 
-    public void startDozing() {
-        if (DEBUG) Log.d(mTag, "startDozing mDreaming=" + mDreaming);
-        if (!mDreaming) {
-            Log.w(mTag, "Not dozing, no longer dreaming");
-            return;
-        }
-
-        super.startDozing();
-    }
-
     @Override
     public void onDreamingStopped() {
         if (DEBUG) Log.d(mTag, "onDreamingStopped isDozing=" + isDozing());
@@ -182,24 +169,14 @@
             mWakeLock.release();
         }
         listenForPulseSignals(false);
-        stopDozing();
         dozingStopped();
+        mHandler.removeCallbacks(mDisplayOff);
     }
 
     @Override
-    public void onDetachedFromWindow() {
-        if (DEBUG) Log.d(mTag, "onDetachedFromWindow");
-        super.onDetachedFromWindow();
-
-        dozingStopped();
-    }
-
-    @Override
-    public void onDestroy() {
-        if (DEBUG) Log.d(mTag, "onDestroy");
-        super.onDestroy();
-
-        dozingStopped();
+    public void startDozing() {
+        if (DEBUG) Log.d(mTag, "startDozing");
+        super.startDozing();
     }
 
     private void requestDoze() {
@@ -208,21 +185,9 @@
         }
     }
 
-    private void requestMultipulse() {
-        requestPulse(mMultipulseCount);
-    }
-
     private void requestPulse() {
-        requestPulse(1);
-    }
-
-    private void requestPulse(int pulses) {
-        requestPulse(pulses, true /*delayed*/);
-    }
-
-    private void requestPulse(int pulses, boolean delayed) {
         if (mHost != null) {
-            mHost.requestPulse(pulses, delayed, this);
+            mHost.requestPulse(this);
         }
     }
 
@@ -232,6 +197,11 @@
         }
     }
 
+    private void finishToSavePower() {
+        Log.w(mTag, "Exiting ambient mode due to low power battery saver");
+        finish();
+    }
+
     private void listenForPulseSignals(boolean listen) {
         if (DEBUG) Log.d(mTag, "listenForPulseSignals: " + listen);
         mSigMotionSensor.setListening(listen);
@@ -257,19 +227,61 @@
     private void listenForNotifications(boolean listen) {
         if (mHost == null) return;
         if (listen) {
+            resetNotificationResets();
             mHost.addCallback(mHostCallback);
         } else {
             mHost.removeCallback(mHostCallback);
         }
     }
 
-    private void rescheduleNotificationPulse() {
-        mAlarmManager.cancel(mNotificationPulseIntent);
-        if (mNotificationLightOn) {
-            final long time = System.currentTimeMillis() + mNotificationPulseInterval;
-            if (DEBUG) Log.d(TAG, "Scheduling pulse for " + new Date(time));
-            mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, time, mNotificationPulseIntent);
+    private void resetNotificationResets() {
+        if (DEBUG) Log.d(TAG, "resetNotificationResets");
+        mScheduleResetsRemaining = mDozeParameters.getPulseScheduleResets();
+    }
+
+    private void updateNotificationPulse() {
+        if (DEBUG) Log.d(TAG, "updateNotificationPulse");
+        if (!mDozeParameters.getPulseOnNotifications()) return;
+        if (mScheduleResetsRemaining <= 0) {
+            if (DEBUG) Log.d(TAG, "No more schedule resets remaining");
+            return;
         }
+        final long now = System.currentTimeMillis();
+        if ((now - mNotificationPulseTime) < mDozeParameters.getPulseDuration()) {
+            if (DEBUG) Log.d(TAG, "Recently updated, not resetting schedule");
+            return;
+        }
+        mScheduleResetsRemaining--;
+        if (DEBUG) Log.d(TAG, "mScheduleResetsRemaining = " + mScheduleResetsRemaining);
+        mNotificationPulseTime = now;
+        rescheduleNotificationPulse(true /*predicate*/);
+    }
+
+    private void rescheduleNotificationPulse(boolean predicate) {
+        if (DEBUG) Log.d(TAG, "rescheduleNotificationPulse predicate=" + predicate);
+        mAlarmManager.cancel(mNotificationPulseIntent);
+        if (!predicate) {
+            if (DEBUG) Log.d(TAG, "  don't reschedule: predicate is false");
+            return;
+        }
+        final PulseSchedule schedule = mDozeParameters.getPulseSchedule();
+        if (schedule == null) {
+            if (DEBUG) Log.d(TAG, "  don't reschedule: schedule is null");
+            return;
+        }
+        final long now = System.currentTimeMillis();
+        final long time = schedule.getNextTime(now, mNotificationPulseTime);
+        if (time <= 0) {
+            if (DEBUG) Log.d(TAG, "  don't reschedule: time is " + time);
+            return;
+        }
+        final long delta = time - now;
+        if (delta <= 0) {
+            if (DEBUG) Log.d(TAG, "  don't reschedule: delta is " + delta);
+            return;
+        }
+        if (DEBUG) Log.d(TAG, "Scheduling pulse in " + delta + "ms for " + new Date(time));
+        mAlarmManager.setExact(AlarmManager.RTC_WAKEUP, time, mNotificationPulseIntent);
     }
 
     private static String triggerEventToString(TriggerEvent event) {
@@ -290,7 +302,6 @@
         public void run() {
             if (DEBUG) Log.d(TAG, "Display off");
             setDozeScreenState(Display.STATE_OFF);
-            setDozeScreenBrightness(PowerManager.BRIGHTNESS_DEFAULT);
         }
     };
 
@@ -299,12 +310,12 @@
         public void onReceive(Context context, Intent intent) {
             if (PULSE_ACTION.equals(intent.getAction())) {
                 if (DEBUG) Log.d(mTag, "Received pulse intent");
-                requestPulse(intent.getIntExtra(EXTRA_PULSES, mMultipulseCount));
+                requestPulse();
             }
             if (NOTIFICATION_PULSE_ACTION.equals(intent.getAction())) {
                 if (DEBUG) Log.d(mTag, "Received notification pulse intent");
                 requestPulse();
-                rescheduleNotificationPulse();
+                rescheduleNotificationPulse(mNotificationLightOn);
             }
         }
     };
@@ -319,7 +330,7 @@
         @Override
         public void onBuzzBeepBlinked() {
             if (DEBUG) Log.d(mTag, "onBuzzBeepBlinked");
-            requestMultipulse();
+            updateNotificationPulse();
         }
 
         @Override
@@ -327,7 +338,17 @@
             if (DEBUG) Log.d(mTag, "onNotificationLight on=" + on);
             if (mNotificationLightOn == on) return;
             mNotificationLightOn = on;
-            rescheduleNotificationPulse();
+            if (mNotificationLightOn) {
+                updateNotificationPulse();
+            }
+        }
+
+        @Override
+        public void onPowerSaveChanged(boolean active) {
+            mPowerSaveActive = active;
+            if (mPowerSaveActive && mDreaming) {
+                finishToSavePower();
+            }
         }
     };
 
@@ -335,26 +356,29 @@
         void addCallback(Callback callback);
         void removeCallback(Callback callback);
         void requestDoze(DozeService dozeService);
-        void requestPulse(int pulses, boolean delayed, DozeService dozeService);
+        void requestPulse(DozeService dozeService);
         void dozingStopped(DozeService dozeService);
+        boolean isPowerSaveActive();
 
         public interface Callback {
             void onNewNotifications();
             void onBuzzBeepBlinked();
             void onNotificationLight(boolean on);
+            void onPowerSaveChanged(boolean active);
         }
     }
 
     private class TriggerSensor extends TriggerEventListener {
         private final Sensor mSensor;
         private final boolean mConfigured;
+        private final boolean mDebugVibrate;
 
         private boolean mEnabled;
 
-        public TriggerSensor(int type, String sysPropConfig, int resConfig) {
+        public TriggerSensor(int type, boolean configured, boolean debugVibrate) {
             mSensor = mSensors.getDefaultSensor(type);
-            mConfigured = SystemProperties.getBoolean(sysPropConfig,
-                    mContext.getResources().getBoolean(resConfig));
+            mConfigured = configured;
+            mDebugVibrate = debugVibrate;
         }
 
         public void setListening(boolean listen) {
@@ -370,13 +394,14 @@
         @Override
         public String toString() {
             return new StringBuilder("{mEnabled=").append(mEnabled).append(", mConfigured=")
-                    .append(mConfigured).append(", mSensor=").append(mSensor).append("}").toString();
+                    .append(mConfigured).append(", mDebugVibrate=").append(mDebugVibrate)
+                    .append(", mSensor=").append(mSensor).append("}").toString();
         }
 
         @Override
         public void onTrigger(TriggerEvent event) {
             if (DEBUG) Log.d(mTag, "onTrigger: " + triggerEventToString(event));
-            if (DEBUG) {
+            if (mDebugVibrate) {
                 final Vibrator v = (Vibrator) mContext.getSystemService(Context.VIBRATOR_SERVICE);
                 if (v != null) {
                     v.vibrate(1000, new AudioAttributes.Builder()
@@ -384,8 +409,17 @@
                             .setUsage(AudioAttributes.USAGE_ASSISTANCE_SONIFICATION).build());
                 }
             }
-            requestPulse(1, false /*delayed*/);
+            requestPulse();
             setListening(true);  // reregister, this sensor only fires once
+
+            // reset the notification pulse schedule, but only if we think we were not triggered
+            // by a notification-related vibration
+            final long timeSinceNotification = System.currentTimeMillis() - mNotificationPulseTime;
+            if (timeSinceNotification < mDozeParameters.getPickupVibrationThreshold()) {
+               if (DEBUG) Log.d(mTag, "Not resetting schedule, recent notification");
+            } else {
+                resetNotificationResets();
+            }
         }
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/egg/LLand.java b/packages/SystemUI/src/com/android/systemui/egg/LLand.java
new file mode 100644
index 0000000..d1c02dd
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/egg/LLand.java
@@ -0,0 +1,748 @@
+/*
+ * Copyright (C) 2014 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.systemui.egg;
+
+import android.animation.TimeAnimator;
+import android.content.Context;
+import android.content.res.Resources;
+import android.graphics.*;
+import android.graphics.drawable.Drawable;
+import android.graphics.drawable.GradientDrawable;
+import android.util.AttributeSet;
+import android.util.Log;
+import android.view.*;
+import android.view.animation.DecelerateInterpolator;
+import android.widget.FrameLayout;
+import android.widget.ImageView;
+import android.widget.TextView;
+
+import java.util.ArrayList;
+
+import com.android.systemui.R;
+
+public class LLand extends FrameLayout {
+    public static final String TAG = "LLand";
+
+    public static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
+    public static final boolean DEBUG_DRAW = false && DEBUG;
+
+    public static final void L(String s, Object ... objects) {
+        if (DEBUG) {
+            Log.d(TAG, String.format(s, objects));
+        }
+    }
+
+    public static final boolean AUTOSTART = true;
+    public static final boolean HAVE_STARS = true;
+
+    public static final float DEBUG_SPEED_MULTIPLIER = 1f; // 0.1f;
+    public static final boolean DEBUG_IDDQD = false;
+
+    private static class Params {
+        public float TRANSLATION_PER_SEC;
+        public int OBSTACLE_SPACING, OBSTACLE_PERIOD;
+        public int BOOST_DV;
+        public int PLAYER_HIT_SIZE;
+        public int PLAYER_SIZE;
+        public int OBSTACLE_WIDTH;
+        public int OBSTACLE_GAP;
+        public int OBSTACLE_MIN;
+        public int BUILDING_WIDTH_MIN, BUILDING_WIDTH_MAX;
+        public int BUILDING_HEIGHT_MIN;
+        public int CLOUD_SIZE_MIN, CLOUD_SIZE_MAX;
+        public int STAR_SIZE_MIN, STAR_SIZE_MAX;
+        public int G;
+        public int MAX_V;
+            public float SCENERY_Z, OBSTACLE_Z, PLAYER_Z, PLAYER_Z_BOOST, HUD_Z;
+        public Params(Resources res) {
+            TRANSLATION_PER_SEC = res.getDimension(R.dimen.translation_per_sec);
+            OBSTACLE_SPACING = res.getDimensionPixelSize(R.dimen.obstacle_spacing);
+            OBSTACLE_PERIOD = (int) (OBSTACLE_SPACING / TRANSLATION_PER_SEC);
+            BOOST_DV = res.getDimensionPixelSize(R.dimen.boost_dv);
+            PLAYER_HIT_SIZE = res.getDimensionPixelSize(R.dimen.player_hit_size);
+            PLAYER_SIZE = res.getDimensionPixelSize(R.dimen.player_size);
+            OBSTACLE_WIDTH = res.getDimensionPixelSize(R.dimen.obstacle_width);
+            OBSTACLE_GAP = res.getDimensionPixelSize(R.dimen.obstacle_gap);
+            OBSTACLE_MIN = res.getDimensionPixelSize(R.dimen.obstacle_height_min);
+            BUILDING_HEIGHT_MIN = res.getDimensionPixelSize(R.dimen.building_height_min);
+            BUILDING_WIDTH_MIN = res.getDimensionPixelSize(R.dimen.building_width_min);
+            BUILDING_WIDTH_MAX = res.getDimensionPixelSize(R.dimen.building_width_max);
+            CLOUD_SIZE_MIN = res.getDimensionPixelSize(R.dimen.cloud_size_min);
+            CLOUD_SIZE_MAX = res.getDimensionPixelSize(R.dimen.cloud_size_max);
+            STAR_SIZE_MIN = res.getDimensionPixelSize(R.dimen.star_size_min);
+            STAR_SIZE_MAX = res.getDimensionPixelSize(R.dimen.star_size_max);
+
+            G = res.getDimensionPixelSize(R.dimen.G);
+            MAX_V = res.getDimensionPixelSize(R.dimen.max_v);
+
+            SCENERY_Z = res.getDimensionPixelSize(R.dimen.scenery_z);
+            OBSTACLE_Z = res.getDimensionPixelSize(R.dimen.obstacle_z);
+            PLAYER_Z = res.getDimensionPixelSize(R.dimen.player_z);
+            PLAYER_Z_BOOST = res.getDimensionPixelSize(R.dimen.player_z_boost);
+            HUD_Z = res.getDimensionPixelSize(R.dimen.hud_z);
+        }
+    }
+
+    private TimeAnimator mAnim;
+
+    private TextView mScoreField;
+    private View mSplash;
+
+    private Player mDroid;
+    private ArrayList<Obstacle> mObstaclesInPlay = new ArrayList<Obstacle>();
+
+    private float t, dt;
+
+    private int mScore;
+    private float mLastPipeTime; // in sec
+    private int mWidth, mHeight;
+    private boolean mAnimating, mPlaying;
+    private boolean mFrozen; // after death, a short backoff
+
+    private int mTimeOfDay;
+    private static final int DAY = 0, NIGHT = 1, TWILIGHT = 2, SUNSET = 3;
+    private static final int[][] SKIES = {
+            { 0xFFc0c0FF, 0xFFa0a0FF }, // DAY
+            { 0xFF000010, 0xFF000000 }, // NIGHT
+            { 0xFF000040, 0xFF000010 }, // TWILIGHT
+            { 0xFF805010, 0xFF202080 }, // SUNSET
+    };
+
+    private static Params PARAMS;
+
+    public LLand(Context context) {
+        this(context, null);
+    }
+
+    public LLand(Context context, AttributeSet attrs) {
+        this(context, attrs, 0);
+    }
+
+    public LLand(Context context, AttributeSet attrs, int defStyle) {
+        super(context, attrs, defStyle);
+        setFocusable(true);
+        PARAMS = new Params(getResources());
+        mTimeOfDay = irand(0, SKIES.length);
+    }
+
+    @Override
+    public boolean willNotDraw() {
+        return !DEBUG;
+    }
+
+    public int getGameWidth() { return mWidth; }
+    public int getGameHeight() { return mHeight; }
+    public float getGameTime() { return t; }
+    public float getLastTimeStep() { return dt; }
+
+    public void setScoreField(TextView tv) {
+        mScoreField = tv;
+        if (tv != null) {
+            tv.setTranslationZ(PARAMS.HUD_Z);
+            if (!(mAnimating && mPlaying)) {
+                tv.setTranslationY(-500);
+            }
+        }
+    }
+
+    public void setSplash(View v) {
+        mSplash = v;
+    }
+
+    @Override
+    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
+        stop();
+        reset();
+        if (AUTOSTART) {
+            start(false);
+        }
+    }
+
+    final float hsv[] = {0, 0, 0};
+
+    private void reset() {
+        L("reset");
+        final Drawable sky = new GradientDrawable(
+                GradientDrawable.Orientation.BOTTOM_TOP,
+                SKIES[mTimeOfDay]
+        );
+        sky.setDither(true);
+        setBackground(sky);
+
+        setScaleX(frand() > 0.5f ? 1 : -1);
+
+        setScore(0);
+
+        int i = getChildCount();
+        while (i-->0) {
+            final View v = getChildAt(i);
+            if (v instanceof GameView) {
+                removeViewAt(i);
+            }
+        }
+
+        mObstaclesInPlay.clear();
+
+        mWidth = getWidth();
+        mHeight = getHeight();
+
+        boolean showingSun = (mTimeOfDay == DAY || mTimeOfDay == SUNSET) && frand() > 0.25;
+        if (showingSun) {
+            final Star sun = new Star(getContext());
+            sun.setBackgroundResource(R.drawable.sun);
+            final int w = getResources().getDimensionPixelSize(R.dimen.sun_size);
+            sun.setTranslationX(frand(w, mWidth-w));
+            if (mTimeOfDay == DAY) {
+                sun.setTranslationY(frand(w, (mHeight * 0.66f)));
+                sun.getBackground().setTint(0);
+            } else {
+                sun.setTranslationY(frand(mHeight * 0.66f, mHeight - w));
+                sun.getBackground().setTintMode(PorterDuff.Mode.SRC_ATOP);
+                sun.getBackground().setTint(0xC0FF8000);
+
+            }
+            addView(sun, new LayoutParams(w, w));
+        }
+        if (!showingSun) {
+            final boolean dark = mTimeOfDay == NIGHT || mTimeOfDay == TWILIGHT;
+            final float ff = frand();
+            if ((dark && ff < 0.75f) || ff < 0.5f) {
+                final Star moon = new Star(getContext());
+                moon.setBackgroundResource(R.drawable.moon);
+                moon.getBackground().setAlpha(dark ? 255 : 128);
+                moon.setScaleX(frand() > 0.5 ? -1 : 1);
+                moon.setRotation(moon.getScaleX() * frand(5, 30));
+                final int w = getResources().getDimensionPixelSize(R.dimen.sun_size);
+                moon.setTranslationX(frand(w, mWidth - w));
+                moon.setTranslationY(frand(w, mHeight - w));
+                addView(moon, new LayoutParams(w, w));
+            }
+        }
+
+        final int mh = mHeight / 6;
+        final boolean cloudless = frand() < 0.25;
+        final int N = 20;
+        for (i=0; i<N; i++) {
+            final float r1 = frand();
+            final Scenery s;
+            if (HAVE_STARS && r1 < 0.3 && mTimeOfDay != DAY) {
+                s = new Star(getContext());
+            } else if (r1 < 0.6 && !cloudless) {
+                s = new Cloud(getContext());
+            } else {
+                s = new Building(getContext());
+
+                s.z = (float)i/N;
+                s.setTranslationZ(PARAMS.SCENERY_Z * (1+s.z));
+                s.v = 0.85f * s.z; // buildings move proportional to their distance
+                hsv[0] = 175;
+                hsv[1] = 0.25f;
+                hsv[2] = 1 * s.z;
+                s.setBackgroundColor(Color.HSVToColor(hsv));
+                s.h = irand(PARAMS.BUILDING_HEIGHT_MIN, mh);
+            }
+            final LayoutParams lp = new LayoutParams(s.w, s.h);
+            if (s instanceof Building) {
+                lp.gravity = Gravity.BOTTOM;
+            } else {
+                lp.gravity = Gravity.TOP;
+                final float r = frand();
+                if (s instanceof Star) {
+                    lp.topMargin = (int) (r * r * mHeight);
+                } else {
+                    lp.topMargin = (int) (1 - r*r * mHeight/2) + mHeight/2;
+                }
+            }
+
+            addView(s, lp);
+            s.setTranslationX(frand(-lp.width, mWidth + lp.width));
+        }
+
+        mDroid = new Player(getContext());
+        mDroid.setX(mWidth / 2);
+        mDroid.setY(mHeight / 2);
+        addView(mDroid, new LayoutParams(PARAMS.PLAYER_SIZE, PARAMS.PLAYER_SIZE));
+        if (mAnim != null) {
+            Log.wtf(TAG, "reseting while animating??!?");
+        }
+        mAnim = new TimeAnimator();
+        mAnim.setTimeListener(new TimeAnimator.TimeListener() {
+            @Override
+            public void onTimeUpdate(TimeAnimator timeAnimator, long t, long dt) {
+                step(t, dt);
+            }
+        });
+    }
+
+    private void setScore(int score) {
+        mScore = score;
+        if (mScoreField != null) mScoreField.setText(String.valueOf(score));
+    }
+
+    private void addScore(int incr) {
+        setScore(mScore + incr);
+    }
+
+    private void start(boolean startPlaying) {
+        L("start(startPlaying=%s)", startPlaying?"true":"false");
+        if (startPlaying) {
+            mPlaying = true;
+
+            t = 0;
+            mLastPipeTime = getGameTime() - PARAMS.OBSTACLE_PERIOD; // queue up a obstacle
+
+            if (mSplash != null && mSplash.getAlpha() > 0f) {
+                mSplash.setTranslationZ(PARAMS.HUD_Z);
+                mSplash.animate().alpha(0).translationZ(0).setDuration(400);
+
+                mScoreField.animate().translationY(0)
+                        .setInterpolator(new DecelerateInterpolator())
+                        .setDuration(1500);
+            }
+
+            mScoreField.setTextColor(0xFFAAAAAA);
+            mScoreField.setBackgroundResource(R.drawable.scorecard);
+            mDroid.setVisibility(View.VISIBLE);
+            mDroid.setX(mWidth / 2);
+            mDroid.setY(mHeight / 2);
+        } else {
+            mDroid.setVisibility(View.GONE);
+        }
+        if (!mAnimating) {
+            mAnim.start();
+            mAnimating = true;
+        }
+    }
+
+    private void stop() {
+        if (mAnimating) {
+            mAnim.cancel();
+            mAnim = null;
+            mAnimating = false;
+            mScoreField.setTextColor(0xFFFFFFFF);
+            mScoreField.setBackgroundResource(R.drawable.scorecard_gameover);
+            mTimeOfDay = irand(0, SKIES.length); // for next reset
+            mFrozen = true;
+            postDelayed(new Runnable() {
+                    @Override
+                    public void run() {
+                        mFrozen = false;
+                    }
+                }, 250);
+        }
+    }
+
+    public static final float lerp(float x, float a, float b) {
+        return (b - a) * x + a;
+    }
+
+    public static final float rlerp(float v, float a, float b) {
+        return (v - a) / (b - a);
+    }
+
+    public static final float clamp(float f) {
+        return f < 0f ? 0f : f > 1f ? 1f : f;
+    }
+
+    public static final float frand() {
+        return (float) Math.random();
+    }
+
+    public static final float frand(float a, float b) {
+        return lerp(frand(), a, b);
+    }
+
+    public static final int irand(int a, int b) {
+        return (int) lerp(frand(), (float) a, (float) b);
+    }
+
+    private void step(long t_ms, long dt_ms) {
+        t = t_ms / 1000f; // seconds
+        dt = dt_ms / 1000f;
+
+        if (DEBUG) {
+            t *= DEBUG_SPEED_MULTIPLIER;
+            dt *= DEBUG_SPEED_MULTIPLIER;
+        }
+
+        // 1. Move all objects and update bounds
+        final int N = getChildCount();
+        int i = 0;
+        for (; i<N; i++) {
+            final View v = getChildAt(i);
+            if (v instanceof GameView) {
+                ((GameView) v).step(t_ms, dt_ms, t, dt);
+            }
+        }
+
+        // 2. Check for altitude
+        if (mPlaying && mDroid.below(mHeight)) {
+            if (DEBUG_IDDQD) {
+                poke();
+            } else {
+                L("player hit the floor");
+                stop();
+            }
+        }
+
+        // 3. Check for obstacles
+        boolean passedBarrier = false;
+        for (int j = mObstaclesInPlay.size(); j-->0;) {
+            final Obstacle ob = mObstaclesInPlay.get(j);
+            if (mPlaying && ob.intersects(mDroid) && !DEBUG_IDDQD) {
+                L("player hit an obstacle");
+                stop();
+            } else if (ob.cleared(mDroid)) {
+                passedBarrier = true;
+                mObstaclesInPlay.remove(j);
+            }
+        }
+
+        if (mPlaying && passedBarrier) {
+            addScore(1);
+        }
+
+        // 4. Handle edge of screen
+        // Walk backwards to make sure removal is safe
+        while (i-->0) {
+            final View v = getChildAt(i);
+            if (v instanceof Obstacle) {
+                if (v.getTranslationX() + v.getWidth() < 0) {
+                    removeViewAt(i);
+                }
+            } else if (v instanceof Scenery) {
+                final Scenery s = (Scenery) v;
+                if (v.getTranslationX() + s.w < 0) {
+                    v.setTranslationX(getWidth());
+                }
+            }
+        }
+
+        // 3. Time for more obstacles!
+        if (mPlaying && (t - mLastPipeTime) > PARAMS.OBSTACLE_PERIOD) {
+            mLastPipeTime = t;
+            final int obstacley = (int) (Math.random()
+                    * (mHeight - 2*PARAMS.OBSTACLE_MIN - PARAMS.OBSTACLE_GAP)) + PARAMS.OBSTACLE_MIN;
+
+            final Obstacle p1 = new Obstacle(getContext(), obstacley);
+            addView(p1, new LayoutParams(
+                    PARAMS.OBSTACLE_WIDTH,
+                    mHeight,
+                    Gravity.TOP|Gravity.LEFT));
+            p1.setTranslationX(mWidth);
+            p1.setTranslationY(-mHeight);
+            p1.setTranslationZ(0);
+            p1.animate()
+                    .translationY(-mHeight+p1.h)
+                    .translationZ(PARAMS.OBSTACLE_Z)
+                    .setStartDelay(irand(0,250))
+                    .setDuration(250);
+            mObstaclesInPlay.add(p1);
+
+            final Obstacle p2 = new Obstacle(getContext(),
+                    mHeight - obstacley - PARAMS.OBSTACLE_GAP);
+            addView(p2, new LayoutParams(
+                    PARAMS.OBSTACLE_WIDTH,
+                    mHeight,
+                    Gravity.TOP|Gravity.LEFT));
+            p2.setTranslationX(mWidth);
+            p2.setTranslationY(mHeight);
+            p2.setTranslationZ(0);
+            p2.animate()
+                    .translationY(mHeight-p2.h)
+                    .translationZ(PARAMS.OBSTACLE_Z)
+                    .setStartDelay(irand(0,100))
+                    .setDuration(400);
+            mObstaclesInPlay.add(p2);
+        }
+
+        if (DEBUG) {
+            final Rect r = new Rect();
+            mDroid.getHitRect(r);
+            r.inset(-4, -4);
+            invalidate(r);
+        }
+    }
+    
+    @Override
+    public boolean onTouchEvent(MotionEvent ev) {
+        if (DEBUG) L("touch: %s", ev);
+        if (ev.getAction() == MotionEvent.ACTION_DOWN) {
+            poke();
+            return true;
+        }
+        return false;
+    }
+
+    @Override
+    public boolean onTrackballEvent(MotionEvent ev) {
+        if (DEBUG) L("trackball: %s", ev);
+        if (ev.getAction() == MotionEvent.ACTION_DOWN) {
+            poke();
+            return true;
+        }
+        return false;
+    }
+
+    @Override
+    public boolean onKeyDown(int keyCode, KeyEvent ev) {
+        if (DEBUG) L("keyDown: %d", keyCode);
+        switch (keyCode) {
+            case KeyEvent.KEYCODE_DPAD_CENTER:
+            case KeyEvent.KEYCODE_DPAD_UP:
+            case KeyEvent.KEYCODE_SPACE:
+            case KeyEvent.KEYCODE_ENTER:
+            case KeyEvent.KEYCODE_BUTTON_A:
+                poke();
+                return true;
+        }
+        return false;
+    }
+
+    @Override
+    public boolean onGenericMotionEvent (MotionEvent ev) {
+        if (DEBUG) L("generic: %s", ev);
+        return false;
+    }
+
+    private void poke() {
+        L("poke");
+        if (mFrozen) return;
+        if (!mAnimating) {
+            reset();
+            start(true);
+        } else if (!mPlaying) {
+            start(true);
+        }
+        mDroid.boost();
+        if (DEBUG) {
+            mDroid.dv *= DEBUG_SPEED_MULTIPLIER;
+            mDroid.animate().setDuration((long) (200/DEBUG_SPEED_MULTIPLIER));
+        }
+    }
+
+    @Override
+    public void onDraw(Canvas c) {
+        super.onDraw(c);
+
+        if (!DEBUG_DRAW) return;
+
+        final Paint pt = new Paint();
+        pt.setColor(0xFFFFFFFF);
+        final int L = mDroid.corners.length;
+        final int N = L/2;
+        for (int i=0; i<N; i++) {
+            final int x = (int) mDroid.corners[i*2];
+            final int y = (int) mDroid.corners[i*2+1];
+            c.drawCircle(x, y, 4, pt);
+            c.drawLine(x, y,
+                    mDroid.corners[(i*2+2)%L],
+                    mDroid.corners[(i*2+3)%L],
+                    pt);
+        }
+
+        final int M = getChildCount();
+        pt.setColor(0x6000FF00);
+        for (int i=0; i<M; i++) {
+            final View v = getChildAt(i);
+            if (v == mDroid) continue;
+            if (!(v instanceof GameView)) continue;
+            final Rect r = new Rect();
+            v.getHitRect(r);
+            c.drawRect(r, pt);
+        }
+
+        pt.setColor(Color.BLACK);
+        final StringBuilder sb = new StringBuilder("obstacles: ");
+        for (Obstacle ob : mObstaclesInPlay) {
+            sb.append(ob.hitRect.toShortString());
+            sb.append(" ");
+        }
+        pt.setTextSize(20f);
+        c.drawText(sb.toString(), 20, 100, pt);
+    }
+
+    static final Rect sTmpRect = new Rect();
+
+    private interface GameView {
+        public void step(long t_ms, long dt_ms, float t, float dt);
+    }
+
+    private class Player extends ImageView implements GameView {
+        public float dv;
+
+        private final float[] sHull = new float[] {
+                0.3f,  0f,    // left antenna
+                0.7f,  0f,    // right antenna
+                0.92f, 0.33f, // off the right shoulder of Orion
+                0.92f, 0.75f, // right hand (our right, not his right)
+                0.6f,  1f,    // right foot
+                0.4f,  1f,    // left foot BLUE!
+                0.08f, 0.75f, // sinistram
+                0.08f, 0.33f,  // cold shoulder
+        };
+        public final float[] corners = new float[sHull.length];
+
+        public Player(Context context) {
+            super(context);
+
+            setBackgroundResource(R.drawable.android);
+            getBackground().setTintMode(PorterDuff.Mode.SRC_ATOP);
+            getBackground().setTint(0xFF00FF00);
+            setOutlineProvider(new ViewOutlineProvider() {
+                @Override
+                public void getOutline(View view, Outline outline) {
+                    final int w = view.getWidth();
+                    final int h = view.getHeight();
+                    final int ix = (int) (w * 0.3f);
+                    final int iy = (int) (h * 0.2f);
+                    outline.setRect(ix, iy, w - ix, h - iy);
+                }
+            });
+        }
+
+        public void prepareCheckIntersections() {
+            final int inset = (PARAMS.PLAYER_SIZE - PARAMS.PLAYER_HIT_SIZE)/2;
+            final int scale = PARAMS.PLAYER_HIT_SIZE;
+            final int N = sHull.length/2;
+            for (int i=0; i<N; i++) {
+                corners[i*2]   = scale * sHull[i*2]   + inset;
+                corners[i*2+1] = scale * sHull[i*2+1] + inset;
+            }
+            final Matrix m = getMatrix();
+            m.mapPoints(corners);
+        }
+
+        public boolean below(int h) {
+            final int N = corners.length/2;
+            for (int i=0; i<N; i++) {
+                final int y = (int) corners[i*2+1];
+                if (y >= h) return true;
+            }
+            return false;
+        }
+
+        public void step(long t_ms, long dt_ms, float t, float dt) {
+            if (getVisibility() != View.VISIBLE) return; // not playing yet
+
+            dv += PARAMS.G;
+            if (dv < -PARAMS.MAX_V) dv = -PARAMS.MAX_V;
+            else if (dv > PARAMS.MAX_V) dv = PARAMS.MAX_V;
+
+            final float y = getTranslationY() + dv * dt;
+            setTranslationY(y < 0 ? 0 : y);
+            setRotation(
+                    90 + lerp(clamp(rlerp(dv, PARAMS.MAX_V, -1 * PARAMS.MAX_V)), 90, -90));
+
+            prepareCheckIntersections();
+        }
+
+        public void boost() {
+            dv = -PARAMS.BOOST_DV;
+            setTranslationZ(PARAMS.PLAYER_Z_BOOST);
+            setScaleX(1.25f);
+            setScaleY(1.25f);
+            animate()
+                .scaleX(1f)
+                .scaleY(1f)
+                .translationZ(PARAMS.PLAYER_Z)
+                .setDuration(200);
+        }
+    }
+
+    private class Obstacle extends View implements GameView {
+        public float h;
+
+        public final Rect hitRect = new Rect();
+
+        public Obstacle(Context context, float h) {
+            super(context);
+            setBackgroundResource(R.drawable.placeholder);
+            this.h = h;
+        }
+
+        public boolean intersects(Player p) {
+            final int N = p.corners.length/2;
+            for (int i=0; i<N; i++) {
+                final int x = (int) p.corners[i*2];
+                final int y = (int) p.corners[i*2+1];
+                if (hitRect.contains(x, y)) return true;
+            }
+            return false;
+        }
+
+        public boolean cleared(Player p) {
+            final int N = p.corners.length/2;
+            for (int i=0; i<N; i++) {
+                final int x = (int) p.corners[i*2];
+                if (hitRect.right >= x) return false;
+            }
+            return true;
+        }
+
+        @Override
+        public void step(long t_ms, long dt_ms, float t, float dt) {
+            setTranslationX(getTranslationX()-PARAMS.TRANSLATION_PER_SEC*dt);
+            getHitRect(hitRect);
+        }
+    }
+
+    private class Scenery extends FrameLayout implements GameView {
+        public float z;
+        public float v;
+        public int h, w;
+        public Scenery(Context context) {
+            super(context);
+        }
+
+        @Override
+        public void step(long t_ms, long dt_ms, float t, float dt) {
+            setTranslationX(getTranslationX() - PARAMS.TRANSLATION_PER_SEC * dt * v);
+        }
+    }
+
+    private class Building extends Scenery {
+        public Building(Context context) {
+            super(context);
+
+            w = irand(PARAMS.BUILDING_WIDTH_MIN, PARAMS.BUILDING_WIDTH_MAX);
+            h = 0; // will be setup later, along with z
+
+            setTranslationZ(PARAMS.SCENERY_Z);
+        }
+    }
+
+    private class Cloud extends Scenery {
+        public Cloud(Context context) {
+            super(context);
+            setBackgroundResource(frand() < 0.01f ? R.drawable.cloud_off : R.drawable.cloud);
+            getBackground().setAlpha(0x40);
+            w = h = irand(PARAMS.CLOUD_SIZE_MIN, PARAMS.CLOUD_SIZE_MAX);
+            z = 0;
+            v = frand(0.15f,0.5f);
+        }
+    }
+
+    private class Star extends Scenery {
+        public Star(Context context) {
+            super(context);
+            setBackgroundResource(R.drawable.star);
+            w = h = irand(PARAMS.STAR_SIZE_MIN, PARAMS.STAR_SIZE_MAX);
+            v = z = 0;
+        }
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/egg/LLandActivity.java b/packages/SystemUI/src/com/android/systemui/egg/LLandActivity.java
new file mode 100644
index 0000000..88fd952
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/egg/LLandActivity.java
@@ -0,0 +1,36 @@
+/*
+ * Copyright (C) 2014 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.systemui.egg;
+
+import android.app.Activity;
+import android.os.Bundle;
+import android.util.Log;
+import android.widget.TextView;
+
+import com.android.systemui.R;
+
+public class LLandActivity extends Activity {
+    @Override
+    public void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+        setContentView(R.layout.lland);
+        LLand world = (LLand) findViewById(R.id.world);
+        world.setScoreField((TextView) findViewById(R.id.score));
+        world.setSplash(findViewById(R.id.welcome));
+        Log.v(LLand.TAG, "focus: " + world.requestFocus());
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
index ad568b8..4af8499 100644
--- a/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
+++ b/packages/SystemUI/src/com/android/systemui/keyguard/KeyguardViewMediator.java
@@ -17,6 +17,7 @@
 package com.android.systemui.keyguard;
 
 import android.app.Activity;
+import android.app.ActivityManager;
 import android.app.ActivityManagerNative;
 import android.app.AlarmManager;
 import android.app.PendingIntent;
@@ -27,6 +28,7 @@
 import android.content.Context;
 import android.content.Intent;
 import android.content.IntentFilter;
+import android.content.pm.UserInfo;
 import android.media.AudioManager;
 import android.media.SoundPool;
 import android.os.Bundle;
@@ -168,6 +170,8 @@
     private boolean mSwitchingUser;
 
     private boolean mSystemReady;
+    private boolean mBootCompleted;
+    private boolean mBootSendUserPresent;
 
     // Whether the next call to playSounds() should be skipped.  Defaults to
     // true because the first lock (on boot) should be silent.
@@ -302,6 +306,13 @@
         @Override
         public void onUserSwitchComplete(int userId) {
             mSwitchingUser = false;
+            if (userId != UserHandle.USER_OWNER) {
+                UserInfo info = UserManager.get(mContext).getUserInfo(userId);
+                if (info != null && info.isGuest()) {
+                    // If we just switched to a guest, try to dismiss keyguard.
+                    dismiss();
+                }
+            }
         }
 
         @Override
@@ -479,7 +490,7 @@
         mUpdateMonitor = KeyguardUpdateMonitor.getInstance(mContext);
 
         mLockPatternUtils = new LockPatternUtils(mContext);
-        mLockPatternUtils.setCurrentUser(UserHandle.USER_OWNER);
+        mLockPatternUtils.setCurrentUser(ActivityManager.getCurrentUser());
 
         // Assume keyguard is showing (unless it's disabled) until we know for sure...
         mShowing = (mUpdateMonitor.isDeviceProvisioned() || mLockPatternUtils.isSecure())
@@ -581,6 +592,8 @@
             final boolean lockImmediately =
                 mLockPatternUtils.getPowerButtonInstantlyLocks() || !mLockPatternUtils.isSecure();
 
+            notifyScreenOffLocked();
+
             if (mExitSecureCallback != null) {
                 if (DEBUG) Log.d(TAG, "pending exit secure callback cancelled");
                 try {
@@ -593,7 +606,6 @@
                     hideLocked();
                 }
             } else if (mShowing) {
-                notifyScreenOffLocked();
                 resetStateLocked();
             } else if (why == WindowManagerPolicy.OFF_BECAUSE_OF_TIMEOUT
                    || (why == WindowManagerPolicy.OFF_BECAUSE_OF_USER && !lockImmediately)) {
@@ -673,8 +685,7 @@
     }
 
     private void maybeSendUserPresentBroadcast() {
-        if (mSystemReady && mLockPatternUtils.isLockScreenDisabled()
-                && !mUserManager.isUserSwitcherEnabled()) {
+        if (mSystemReady && mLockPatternUtils.isLockScreenDisabled()) {
             // Lock screen is disabled because the user has set the preference to "None".
             // In this case, send out ACTION_USER_PRESENT here instead of in
             // handleKeyguardDone()
@@ -1133,12 +1144,17 @@
         }
 
         handleHide();
-        sendUserPresentBroadcast();
     }
 
     private void sendUserPresentBroadcast() {
-        final UserHandle currentUser = new UserHandle(mLockPatternUtils.getCurrentUser());
-        mContext.sendBroadcastAsUser(USER_PRESENT_INTENT, currentUser);
+        synchronized (this) {
+            if (mBootCompleted) {
+                final UserHandle currentUser = new UserHandle(mLockPatternUtils.getCurrentUser());
+                mContext.sendBroadcastAsUser(USER_PRESENT_INTENT, currentUser);
+            } else {
+                mBootSendUserPresent = true;
+            }
+        }
     }
 
     /**
@@ -1304,6 +1320,7 @@
             mHideAnimationRun = false;
             updateActivityLockScreenState();
             adjustStatusBarLocked();
+            sendUserPresentBroadcast();
         }
     }
 
@@ -1323,9 +1340,7 @@
                 // (like recents). Temporary enable/disable (e.g. the "back" button) are
                 // done in KeyguardHostView.
                 flags |= StatusBarManager.DISABLE_RECENT;
-                if (!isAssistantAvailable()) {
-                    flags |= StatusBarManager.DISABLE_SEARCH;
-                }
+                flags |= StatusBarManager.DISABLE_SEARCH;
             }
             if (isShowingAndNotOccluded()) {
                 flags |= StatusBarManager.DISABLE_HOME;
@@ -1399,6 +1414,12 @@
 
     public void onBootCompleted() {
         mUpdateMonitor.dispatchBootCompleted();
+        synchronized (this) {
+            mBootCompleted = true;
+            if (mBootSendUserPresent) {
+                sendUserPresentBroadcast();
+            }
+        }
     }
 
     public StatusBarKeyguardViewManager registerStatusBar(PhoneStatusBar phoneStatusBar,
diff --git a/packages/SystemUI/src/com/android/systemui/net/NetworkOverLimitActivity.java b/packages/SystemUI/src/com/android/systemui/net/NetworkOverLimitActivity.java
index 1ac8295..b3c0783 100644
--- a/packages/SystemUI/src/com/android/systemui/net/NetworkOverLimitActivity.java
+++ b/packages/SystemUI/src/com/android/systemui/net/NetworkOverLimitActivity.java
@@ -63,13 +63,13 @@
                 });
 
         final Dialog dialog = builder.create();
+        dialog.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ALERT);
         dialog.setOnDismissListener(new DialogInterface.OnDismissListener() {
             public void onDismiss(DialogInterface dialog) {
                 finish();
             }
         });
 
-        dialog.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ALERT);
         dialog.show();
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/power/PowerDialogWarnings.java b/packages/SystemUI/src/com/android/systemui/power/PowerDialogWarnings.java
deleted file mode 100644
index 8420dc0c..0000000
--- a/packages/SystemUI/src/com/android/systemui/power/PowerDialogWarnings.java
+++ /dev/null
@@ -1,219 +0,0 @@
-/*
- * Copyright (C) 2014 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.systemui.power;
-
-import android.app.AlertDialog;
-import android.content.ContentResolver;
-import android.content.Context;
-import android.content.DialogInterface;
-import android.content.Intent;
-import android.media.AudioManager;
-import android.media.Ringtone;
-import android.media.RingtoneManager;
-import android.net.Uri;
-import android.os.SystemClock;
-import android.provider.Settings;
-import android.util.Slog;
-import android.view.ContextThemeWrapper;
-import android.view.WindowManager;
-
-import com.android.systemui.R;
-import com.android.systemui.statusbar.phone.PhoneStatusBar;
-
-import java.io.PrintWriter;
-
-public class PowerDialogWarnings implements PowerUI.WarningsUI {
-    private static final String TAG = PowerUI.TAG + ".Dialog";
-    private static final boolean DEBUG = PowerUI.DEBUG;
-
-    private final Context mContext;
-    private final PhoneStatusBar mPhoneStatusBar;
-
-    private int mBatteryLevel;
-    private int mBucket;
-    private long mScreenOffTime;
-    private boolean mSaver;
-
-    private AlertDialog mInvalidChargerDialog;
-    private AlertDialog mLowBatteryDialog;
-
-    public PowerDialogWarnings(Context context, PhoneStatusBar phoneStatusBar) {
-        mContext = new ContextThemeWrapper(context, android.R.style.Theme_DeviceDefault_Light);
-        mPhoneStatusBar = phoneStatusBar;
-    }
-
-    @Override
-    public void dump(PrintWriter pw) {
-        pw.print("mInvalidChargerDialog=");
-        pw.println(mInvalidChargerDialog == null ? "null" : mInvalidChargerDialog.toString());
-        pw.print("mLowBatteryDialog=");
-        pw.println(mLowBatteryDialog == null ? "null" : mLowBatteryDialog.toString());
-    }
-
-    @Override
-    public void update(int batteryLevel, int bucket, long screenOffTime) {
-        mBatteryLevel = batteryLevel;
-        mBucket = bucket;
-        mScreenOffTime = screenOffTime;
-    }
-
-    @Override
-    public boolean isInvalidChargerWarningShowing() {
-        return mInvalidChargerDialog != null;
-    }
-
-    @Override
-    public void updateLowBatteryWarning() {
-        if (mLowBatteryDialog != null) {
-            showLowBatteryWarning(false /*playSound*/);
-        }
-    }
-
-    @Override
-    public void dismissLowBatteryWarning() {
-        if (mLowBatteryDialog != null) {
-            Slog.i(TAG, "closing low battery warning: level=" + mBatteryLevel);
-            mLowBatteryDialog.dismiss();
-        }
-    }
-
-    @Override
-    public void showLowBatteryWarning(boolean playSound) {
-        Slog.i(TAG,
-                ((mLowBatteryDialog == null) ? "showing" : "updating")
-                + " low battery warning: level=" + mBatteryLevel
-                + " [" + mBucket + "]");
-
-        final int textRes = mSaver ? R.string.battery_low_percent_format_saver_started
-                : R.string.battery_low_percent_format;
-        final CharSequence levelText = mContext.getString(textRes, mBatteryLevel);
-
-        if (mLowBatteryDialog != null) {
-            mLowBatteryDialog.setMessage(levelText);
-        } else {
-            AlertDialog.Builder b = new AlertDialog.Builder(mContext);
-            b.setCancelable(true);
-            b.setTitle(R.string.battery_low_title);
-            b.setMessage(levelText);
-            b.setPositiveButton(android.R.string.ok, null);
-
-            final Intent intent = new Intent(Intent.ACTION_POWER_USAGE_SUMMARY);
-            intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK
-                    | Intent.FLAG_ACTIVITY_MULTIPLE_TASK
-                    | Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS
-                    | Intent.FLAG_ACTIVITY_NO_HISTORY);
-            if (intent.resolveActivity(mContext.getPackageManager()) != null) {
-                b.setNegativeButton(R.string.battery_low_why,
-                        new DialogInterface.OnClickListener() {
-                    @Override
-                    public void onClick(DialogInterface dialog, int which) {
-                        mPhoneStatusBar.startActivity(intent, true /* dismissShade */);
-                        dismissLowBatteryWarning();
-                    }
-                });
-            }
-
-            AlertDialog d = b.create();
-            d.setOnDismissListener(new DialogInterface.OnDismissListener() {
-                    @Override
-                    public void onDismiss(DialogInterface dialog) {
-                        mLowBatteryDialog = null;
-                    }
-                });
-            d.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ERROR);
-            d.getWindow().getAttributes().privateFlags |=
-                    WindowManager.LayoutParams.PRIVATE_FLAG_SHOW_FOR_ALL_USERS;
-            d.show();
-            mLowBatteryDialog = d;
-            if (playSound) {
-                playLowBatterySound();
-            }
-        }
-    }
-
-    private void playLowBatterySound() {
-        final ContentResolver cr = mContext.getContentResolver();
-
-        final int silenceAfter = Settings.Global.getInt(cr,
-                Settings.Global.LOW_BATTERY_SOUND_TIMEOUT, 0);
-        final long offTime = SystemClock.elapsedRealtime() - mScreenOffTime;
-        if (silenceAfter > 0
-                && mScreenOffTime > 0
-                && offTime > silenceAfter) {
-            Slog.i(TAG, "screen off too long (" + offTime + "ms, limit " + silenceAfter
-                    + "ms): not waking up the user with low battery sound");
-            return;
-        }
-
-        if (DEBUG) {
-            Slog.d(TAG, "playing low battery sound. pick-a-doop!"); // WOMP-WOMP is deprecated
-        }
-
-        if (Settings.Global.getInt(cr, Settings.Global.POWER_SOUNDS_ENABLED, 1) == 1) {
-            final String soundPath = Settings.Global.getString(cr,
-                    Settings.Global.LOW_BATTERY_SOUND);
-            if (soundPath != null) {
-                final Uri soundUri = Uri.parse("file://" + soundPath);
-                if (soundUri != null) {
-                    final Ringtone sfx = RingtoneManager.getRingtone(mContext, soundUri);
-                    if (sfx != null) {
-                        sfx.setStreamType(AudioManager.STREAM_SYSTEM);
-                        sfx.play();
-                    }
-                }
-            }
-        }
-    }
-
-    @Override
-    public void dismissInvalidChargerWarning() {
-        if (mInvalidChargerDialog != null) {
-            mInvalidChargerDialog.dismiss();
-        }
-    }
-
-    @Override
-    public void showInvalidChargerWarning() {
-        Slog.d(TAG, "showing invalid charger dialog");
-
-        dismissLowBatteryWarning();
-
-        AlertDialog.Builder b = new AlertDialog.Builder(mContext);
-        b.setCancelable(true);
-        b.setTitle(R.string.invalid_charger_title);
-        b.setMessage(R.string.invalid_charger_text);
-        b.setPositiveButton(android.R.string.ok, null);
-
-        AlertDialog d = b.create();
-            d.setOnDismissListener(new DialogInterface.OnDismissListener() {
-                    public void onDismiss(DialogInterface dialog) {
-                        mInvalidChargerDialog = null;
-                    }
-                });
-
-        d.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ERROR);
-        d.getWindow().getAttributes().privateFlags |=
-                WindowManager.LayoutParams.PRIVATE_FLAG_SHOW_FOR_ALL_USERS;
-        d.show();
-        mInvalidChargerDialog = d;
-    }
-
-    @Override
-    public void showSaverMode(boolean mode) {
-        mSaver = mode;
-    }
-}
diff --git a/packages/SystemUI/src/com/android/systemui/power/PowerNotificationWarnings.java b/packages/SystemUI/src/com/android/systemui/power/PowerNotificationWarnings.java
index d455cec..f184ad2 100644
--- a/packages/SystemUI/src/com/android/systemui/power/PowerNotificationWarnings.java
+++ b/packages/SystemUI/src/com/android/systemui/power/PowerNotificationWarnings.java
@@ -31,6 +31,7 @@
 import android.net.Uri;
 import android.os.AsyncTask;
 import android.os.Handler;
+import android.os.PowerManager;
 import android.os.SystemClock;
 import android.os.UserHandle;
 import android.provider.Settings;
@@ -49,7 +50,6 @@
 
     private static final String TAG_NOTIFICATION = "low_battery";
     private static final int ID_NOTIFICATION = 100;
-    private static final int AUTO_DISMISS_MS = 10000;
 
     private static final int SHOWING_NOTHING = 0;
     private static final int SHOWING_WARNING = 1;
@@ -62,8 +62,6 @@
         "SHOWING_INVALID_CHARGER",
     };
 
-    private static final String ACTION_SHOW_FALLBACK_WARNING = "PNW.warningFallback";
-    private static final String ACTION_SHOW_FALLBACK_CHARGER = "PNW.chargerFallback";
     private static final String ACTION_SHOW_BATTERY_SETTINGS = "PNW.batterySettings";
     private static final String ACTION_START_SAVER = "PNW.startSaver";
     private static final String ACTION_STOP_SAVER = "PNW.stopSaver";
@@ -75,8 +73,8 @@
 
     private final Context mContext;
     private final NotificationManager mNoMan;
+    private final PowerManager mPowerMan;
     private final Handler mHandler = new Handler();
-    private final PowerDialogWarnings mFallbackDialogs;
     private final Receiver mReceiver = new Receiver();
     private final Intent mOpenBatterySettings = settings(Intent.ACTION_POWER_USAGE_SUMMARY);
     private final Intent mOpenSaverSettings = settings(Settings.ACTION_BATTERY_SAVER_SETTINGS);
@@ -97,7 +95,7 @@
     public PowerNotificationWarnings(Context context, PhoneStatusBar phoneStatusBar) {
         mContext = context;
         mNoMan = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
-        mFallbackDialogs = new PowerDialogWarnings(context, phoneStatusBar);
+        mPowerMan = (PowerManager) context.getSystemService(Context.POWER_SERVICE);
         mReceiver.init();
     }
 
@@ -121,7 +119,6 @@
         }
         mBucket = bucket;
         mScreenOffTime = screenOffTime;
-        mFallbackDialogs.update(batteryLevel, bucket, screenOffTime);
     }
 
     @Override
@@ -134,8 +131,8 @@
     }
 
     private void updateNotification() {
-        if (DEBUG) Slog.d(TAG, "updateNotification mWarning=" + mWarning
-                + " mSaver=" + mSaver + " mInvalidCharger=" + mInvalidCharger);
+        if (DEBUG) Slog.d(TAG, "updateNotification mWarning=" + mWarning + " mPlaySound="
+                + mPlaySound + " mSaver=" + mSaver + " mInvalidCharger=" + mInvalidCharger);
         if (mInvalidCharger) {
             showInvalidChargerNotification();
             mShowing = SHOWING_INVALID_CHARGER;
@@ -162,7 +159,8 @@
                 .setPriority(Notification.PRIORITY_MAX)
                 .setCategory(Notification.CATEGORY_SYSTEM)
                 .setVisibility(Notification.VISIBILITY_PUBLIC)
-                .setFullScreenIntent(pendingBroadcast(ACTION_SHOW_FALLBACK_CHARGER), true);
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
         final Notification n = nb.build();
         if (n.headsUpContentView != null) {
             n.headsUpContentView.setViewVisibility(com.android.internal.R.id.right_icon, View.GONE);
@@ -180,12 +178,12 @@
                 .setShowWhen(false)
                 .setContentTitle(mContext.getString(R.string.battery_low_title))
                 .setContentText(mContext.getString(textRes, mBatteryLevel))
-                .setOngoing(true)
                 .setOnlyAlertOnce(true)
                 .setPriority(Notification.PRIORITY_MAX)
                 .setCategory(Notification.CATEGORY_SYSTEM)
                 .setVisibility(Notification.VISIBILITY_PUBLIC)
-                .setFullScreenIntent(pendingBroadcast(ACTION_SHOW_FALLBACK_WARNING), true);
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.battery_saver_mode_color));
         if (hasBatterySettings()) {
             nb.setContentIntent(pendingBroadcast(ACTION_SHOW_BATTERY_SETTINGS));
         }
@@ -198,6 +196,7 @@
         }
         if (mPlaySound) {
             attachLowBatterySound(nb);
+            mPlaySound = false;
         }
         final Notification n = nb.build();
         if (n.headsUpContentView != null) {
@@ -214,7 +213,9 @@
                 .setOngoing(true)
                 .setShowWhen(false)
                 .setCategory(Notification.CATEGORY_SYSTEM)
-                .setVisibility(Notification.VISIBILITY_PUBLIC);
+                .setVisibility(Notification.VISIBILITY_PUBLIC)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.battery_saver_mode_color));
         addStopSaverAction(nb);
         if (hasSaverSettings()) {
             nb.setContentIntent(pendingActivity(mOpenSaverSettings));
@@ -260,14 +261,12 @@
     @Override
     public void updateLowBatteryWarning() {
         updateNotification();
-        mFallbackDialogs.updateLowBatteryWarning();
     }
 
     @Override
     public void dismissLowBatteryWarning() {
         if (DEBUG) Slog.d(TAG, "dismissing low battery warning: level=" + mBatteryLevel);
         dismissLowBatteryNotification();
-        mFallbackDialogs.dismissLowBatteryWarning();
     }
 
     private void dismissLowBatteryNotification() {
@@ -288,12 +287,10 @@
     public void showLowBatteryWarning(boolean playSound) {
         Slog.i(TAG,
                 "show low battery warning: level=" + mBatteryLevel
-                + " [" + mBucket + "]");
+                + " [" + mBucket + "] playSound=" + playSound);
         mPlaySound = playSound;
         mWarning = true;
         updateNotification();
-        mHandler.removeCallbacks(mDismissLowBatteryNotification);
-        mHandler.postDelayed(mDismissLowBatteryNotification, AUTO_DISMISS_MS);
     }
 
     private void attachLowBatterySound(Notification.Builder b) {
@@ -330,7 +327,6 @@
     @Override
     public void dismissInvalidChargerWarning() {
         dismissInvalidChargerNotification();
-        mFallbackDialogs.dismissInvalidChargerWarning();
     }
 
     private void dismissInvalidChargerNotification() {
@@ -363,17 +359,14 @@
         mSaverConfirmation = d;
     }
 
-    private void setSaverSetting(boolean mode) {
-        final int val = mode ? 1 : 0;
-        Settings.Global.putInt(mContext.getContentResolver(), Settings.Global.LOW_POWER_MODE, val);
+    private void setSaverMode(boolean mode) {
+        mPowerMan.setPowerSaveMode(mode);
     }
 
     private final class Receiver extends BroadcastReceiver {
 
         public void init() {
             IntentFilter filter = new IntentFilter();
-            filter.addAction(ACTION_SHOW_FALLBACK_WARNING);
-            filter.addAction(ACTION_SHOW_FALLBACK_CHARGER);
             filter.addAction(ACTION_SHOW_BATTERY_SETTINGS);
             filter.addAction(ACTION_START_SAVER);
             filter.addAction(ACTION_STOP_SAVER);
@@ -384,13 +377,7 @@
         public void onReceive(Context context, Intent intent) {
             final String action = intent.getAction();
             Slog.i(TAG, "Received " + action);
-            if (action.equals(ACTION_SHOW_FALLBACK_WARNING)) {
-                dismissLowBatteryNotification();
-                mFallbackDialogs.showLowBatteryWarning(false /*playSound*/);
-            } else if (action.equals(ACTION_SHOW_FALLBACK_CHARGER)) {
-                dismissInvalidChargerNotification();
-                mFallbackDialogs.showInvalidChargerWarning();
-            } else if (action.equals(ACTION_SHOW_BATTERY_SETTINGS)) {
+            if (action.equals(ACTION_SHOW_BATTERY_SETTINGS)) {
                 dismissLowBatteryNotification();
                 mContext.startActivityAsUser(mOpenBatterySettings, UserHandle.CURRENT);
             } else if (action.equals(ACTION_START_SAVER)) {
@@ -399,7 +386,7 @@
             } else if (action.equals(ACTION_STOP_SAVER)) {
                 dismissSaverNotification();
                 dismissLowBatteryNotification();
-                setSaverSetting(false);
+                setSaverMode(false);
             }
         }
     }
@@ -410,16 +397,9 @@
             AsyncTask.execute(new Runnable() {
                 @Override
                 public void run() {
-                    setSaverSetting(true);
+                    setSaverMode(true);
                 }
             });
         }
     };
-
-    private final Runnable mDismissLowBatteryNotification = new Runnable() {
-        @Override
-        public void run() {
-            dismissLowBatteryNotification();
-        }
-    };
 }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSDetailClipper.java b/packages/SystemUI/src/com/android/systemui/qs/QSDetailClipper.java
index 9c1ff9d..eb4560d 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSDetailClipper.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSDetailClipper.java
@@ -46,7 +46,11 @@
         r = (int) Math.max(r, Math.ceil(Math.sqrt(w * w + y * y)));
         r = (int) Math.max(r, Math.ceil(Math.sqrt(w * w + h * h)));
         r = (int) Math.max(r, Math.ceil(Math.sqrt(x * x + h * h)));
-        mAnimator = ViewAnimationUtils.createCircularReveal(mDetail, x, y, 0, r);
+        if (in) {
+            mAnimator = ViewAnimationUtils.createCircularReveal(mDetail, x, y, 0, r);
+        } else {
+            mAnimator = ViewAnimationUtils.createCircularReveal(mDetail, x, y, r, 0);
+        }
         mAnimator.setDuration((long)(mAnimator.getDuration() * 1.5));
         if (listener != null) {
             mAnimator.addListener(listener);
@@ -55,12 +59,11 @@
         if (in) {
             mBackground.startTransition((int)(mAnimator.getDuration() * 0.6));
             mAnimator.addListener(mVisibleOnStart);
-            mAnimator.start();
         } else {
             mDetail.postDelayed(mReverseBackground, (long)(mAnimator.getDuration() * 0.65));
             mAnimator.addListener(mGoneOnEnd);
-            mAnimator.reverse();
         }
+        mAnimator.start();
     }
 
     private final Runnable mReverseBackground = new Runnable() {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSDetailItems.java b/packages/SystemUI/src/com/android/systemui/qs/QSDetailItems.java
index 24c1378..ce0d5f4 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSDetailItems.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSDetailItems.java
@@ -17,12 +17,14 @@
 package com.android.systemui.qs;
 
 import android.content.Context;
+import android.content.res.Configuration;
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
 import android.text.TextUtils;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.util.TypedValue;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -31,6 +33,7 @@
 import android.widget.LinearLayout;
 import android.widget.TextView;
 
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 
 /**
@@ -76,6 +79,20 @@
         mEmptyIcon = (ImageView) mEmpty.findViewById(android.R.id.icon);
     }
 
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        FontSizeUtils.updateFontSize(mEmptyText, R.dimen.qs_detail_empty_text_size);
+        int count = mItems.getChildCount();
+        for (int i = 0; i < count; i++) {
+            View item = mItems.getChildAt(i);
+            FontSizeUtils.updateFontSize(item, android.R.id.title,
+                    R.dimen.qs_detail_item_primary_text_size);
+            FontSizeUtils.updateFontSize(item, android.R.id.summary,
+                    R.dimen.qs_detail_item_secondary_text_size);
+        }
+    }
+
     public void setTagSuffix(String suffix) {
         mTag = TAG + "." + suffix;
     }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSDualTileLabel.java b/packages/SystemUI/src/com/android/systemui/qs/QSDualTileLabel.java
index 377fcc0..a9fdc86 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSDualTileLabel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSDualTileLabel.java
@@ -23,7 +23,6 @@
 import android.text.TextUtils.TruncateAt;
 import android.view.Gravity;
 import android.view.View;
-import android.widget.FrameLayout;
 import android.widget.ImageView;
 import android.widget.LinearLayout;
 import android.widget.TextView;
@@ -41,7 +40,7 @@
  *               truncate.
  *   Second line: ellipsis if necessary
  */
-public class QSDualTileLabel extends FrameLayout {
+public class QSDualTileLabel extends LinearLayout {
 
     private final Context mContext;
     private final TextView mFirstLine;
@@ -54,12 +53,13 @@
     public QSDualTileLabel(Context context) {
         super(context);
         mContext = context;
+        setOrientation(LinearLayout.VERTICAL);
 
         mHorizontalPaddingPx = mContext.getResources()
                 .getDimensionPixelSize(R.dimen.qs_dual_tile_padding_horizontal);
 
         mFirstLine = initTextView();
-        mFirstLine.setPadding(mHorizontalPaddingPx, 0, 0, 0);
+        mFirstLine.setPadding(mHorizontalPaddingPx, 0, mHorizontalPaddingPx, 0);
         final LinearLayout firstLineLayout = new LinearLayout(mContext);
         firstLineLayout.setPadding(0, 0, 0, 0);
         firstLineLayout.setOrientation(LinearLayout.HORIZONTAL);
@@ -70,13 +70,13 @@
         mFirstLineCaret.setScaleType(ImageView.ScaleType.MATRIX);
         mFirstLineCaret.setClickable(false);
         firstLineLayout.addView(mFirstLineCaret);
-        addView(firstLineLayout, newFrameLayoutParams());
+        addView(firstLineLayout, newLinearLayoutParams());
 
         mSecondLine = initTextView();
         mSecondLine.setPadding(mHorizontalPaddingPx, 0, mHorizontalPaddingPx, 0);
         mSecondLine.setEllipsize(TruncateAt.END);
         mSecondLine.setVisibility(GONE);
-        addView(mSecondLine, newFrameLayoutParams());
+        addView(mSecondLine, newLinearLayoutParams());
 
         addOnLayoutChangeListener(new OnLayoutChangeListener() {
             @Override
@@ -89,7 +89,7 @@
         });
     }
 
-    private static LayoutParams newFrameLayoutParams() {
+    private static LayoutParams newLinearLayoutParams() {
         final LayoutParams lp =
                 new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT);
         lp.gravity = Gravity.CENTER_HORIZONTAL;
@@ -104,6 +104,7 @@
             lp.topMargin = h * 4 / 5;
             mSecondLine.setLayoutParams(lp);
             mFirstLine.setMinHeight(h);
+            mFirstLine.setPadding(mHorizontalPaddingPx, 0, 0, 0);
         }
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSFooter.java b/packages/SystemUI/src/com/android/systemui/qs/QSFooter.java
index f04a7b6..a0b6e82 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSFooter.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSFooter.java
@@ -18,23 +18,23 @@
 import android.app.AlertDialog;
 import android.content.Context;
 import android.content.DialogInterface;
+import android.content.res.Configuration;
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
 import android.util.Log;
-import android.view.ContextThemeWrapper;
+import android.util.TypedValue;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.View.OnClickListener;
-import android.view.WindowManager;
 import android.widget.ImageView;
 import android.widget.TextView;
 
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.statusbar.phone.QSTileHost;
 import com.android.systemui.statusbar.phone.SystemUIDialog;
 import com.android.systemui.statusbar.policy.SecurityController;
-import com.android.systemui.statusbar.policy.SecurityController.VpnCallback;
 
 public class QSFooter implements OnClickListener, DialogInterface.OnClickListener {
     protected static final String TAG = "QSFooter";
@@ -50,6 +50,11 @@
     private AlertDialog mDialog;
     private QSTileHost mHost;
     private Handler mHandler;
+    private final Handler mMainHandler;
+
+    private boolean mIsVisible;
+    private boolean mIsIconVisible;
+    private int mFooterTextId;
 
     public QSFooter(QSPanel qsPanel, Context context) {
         mRootView = LayoutInflater.from(context)
@@ -58,6 +63,7 @@
         mFooterText = (TextView) mRootView.findViewById(R.id.footer_text);
         mFooterIcon = (ImageView) mRootView.findViewById(R.id.footer_icon);
         mContext = context;
+        mMainHandler = new Handler();
     }
 
     public void setHost(QSTileHost host) {
@@ -74,6 +80,10 @@
         }
     }
 
+    public void onConfigurationChanged() {
+        FontSizeUtils.updateFontSize(mFooterText, R.dimen.qs_tile_text_size);
+    }
+
     public View getView() {
         return mRootView;
     }
@@ -99,26 +109,28 @@
 
     private void handleRefreshState() {
         if (mSecurityController.hasDeviceOwner()) {
-            mFooterText.setText(R.string.device_owned_footer);
-            mRootView.setVisibility(View.VISIBLE);
-            mFooterIcon.setVisibility(View.INVISIBLE);
+            mFooterTextId = R.string.device_owned_footer;
+            mIsVisible = true;
+            mIsIconVisible = false;
+        } else if (mSecurityController.hasProfileOwner()) {
+            mFooterTextId = R.string.profile_owned_footer;
+            mIsVisible = true;
+            mIsIconVisible = false;
         } else if (mSecurityController.isVpnEnabled()) {
-            mFooterText.setText(R.string.vpn_footer);
-            mRootView.setVisibility(View.VISIBLE);
-            mFooterIcon.setVisibility(View.VISIBLE);
+            mFooterTextId = R.string.vpn_footer;
+            mIsVisible = true;
+            mIsIconVisible = true;
         } else {
-            mRootView.setVisibility(View.GONE);
+            mIsVisible = false;
+            mIsIconVisible = false;
         }
+        mMainHandler.post(mUpdateDisplayState);
     }
 
     @Override
     public void onClick(DialogInterface dialog, int which) {
         if (which == DialogInterface.BUTTON_NEGATIVE) {
-            if (mSecurityController.isLegacyVpn()) {
-                mSecurityController.disconnectFromLegacyVpn();
-            } else {
-                mSecurityController.openVpnApp();
-            }
+            mSecurityController.disconnectFromVpn();
         }
     }
 
@@ -137,7 +149,7 @@
         if (mSecurityController.isLegacyVpn()) {
             return mContext.getString(R.string.disconnect_vpn);
         } else {
-            return mContext.getString(R.string.open_app);
+            return mContext.getString(R.string.disable_vpn);
         }
     }
 
@@ -147,20 +159,61 @@
 
     private String getMessage() {
         if (mSecurityController.hasDeviceOwner()) {
+            if (mSecurityController.hasProfileOwner()) {
+                if (mSecurityController.isVpnEnabled()) {
+                    if (mSecurityController.isLegacyVpn()) {
+                        return mContext.getString(
+                                R.string.monitoring_description_legacy_vpn_device_and_profile_owned,
+                                mSecurityController.getDeviceOwnerName(),
+                                mSecurityController.getProfileOwnerName(),
+                                mSecurityController.getLegacyVpnName());
+                    } else {
+                        return mContext.getString(
+                                R.string.monitoring_description_vpn_device_and_profile_owned,
+                                mSecurityController.getDeviceOwnerName(),
+                                mSecurityController.getProfileOwnerName(),
+                                mSecurityController.getVpnApp());
+                    }
+                } else {
+                    return mContext.getString(
+                            R.string.monitoring_description_device_and_profile_owned,
+                            mSecurityController.getDeviceOwnerName(),
+                            mSecurityController.getProfileOwnerName());
+                }
+            } else {
+                if (mSecurityController.isVpnEnabled()) {
+                    if (mSecurityController.isLegacyVpn()) {
+                        return mContext.getString(
+                                R.string.monitoring_description_legacy_vpn_device_owned,
+                                mSecurityController.getDeviceOwnerName(),
+                                mSecurityController.getLegacyVpnName());
+                    } else {
+                        return mContext.getString(R.string.monitoring_description_vpn_device_owned,
+                                mSecurityController.getDeviceOwnerName(),
+                                mSecurityController.getVpnApp());
+                    }
+                } else {
+                    return mContext.getString(R.string.monitoring_description_device_owned,
+                            mSecurityController.getDeviceOwnerName());
+                }
+            }
+        } else if (mSecurityController.hasProfileOwner()) {
             if (mSecurityController.isVpnEnabled()) {
                 if (mSecurityController.isLegacyVpn()) {
                     return mContext.getString(
-                            R.string.monitoring_description_legacy_vpn_device_owned,
-                            mSecurityController.getDeviceOwnerName(),
+                            R.string.monitoring_description_legacy_vpn_profile_owned,
+                            mSecurityController.getProfileOwnerName(),
                             mSecurityController.getLegacyVpnName());
                 } else {
-                    return mContext.getString(R.string.monitoring_description_vpn_device_owned,
-                            mSecurityController.getDeviceOwnerName(),
+                    return mContext.getString(
+                            R.string.monitoring_description_vpn_profile_owned,
+                            mSecurityController.getProfileOwnerName(),
                             mSecurityController.getVpnApp());
                 }
             } else {
-                return mContext.getString(R.string.monitoring_description_device_owned,
-                        mSecurityController.getDeviceOwnerName());
+                return mContext.getString(
+                        R.string.monitoring_description_profile_owned,
+                        mSecurityController.getProfileOwnerName());
             }
         } else {
             if (mSecurityController.isLegacyVpn()) {
@@ -178,12 +231,26 @@
         if (mSecurityController.hasDeviceOwner()) {
             return R.string.monitoring_title_device_owned;
         }
+        if (mSecurityController.hasProfileOwner()) {
+            return R.string.monitoring_title_profile_owned;
+        }
         return R.string.monitoring_title;
     }
 
-    private class Callback implements VpnCallback {
+    private final Runnable mUpdateDisplayState = new Runnable() {
         @Override
-        public void onVpnStateChanged() {
+        public void run() {
+            if (mFooterTextId != 0) {
+                mFooterText.setText(mFooterTextId);
+            }
+            mRootView.setVisibility(mIsVisible ? View.VISIBLE : View.GONE);
+            mFooterIcon.setVisibility(mIsIconVisible ? View.VISIBLE : View.INVISIBLE);
+        }
+    };
+
+    private class Callback implements SecurityController.SecurityControllerCallback {
+        @Override
+        public void onStateChanged() {
             refreshState();
         }
     }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
index 1fa97bd..2fafb2c 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
@@ -21,15 +21,19 @@
 import android.animation.AnimatorListenerAdapter;
 import android.content.Context;
 import android.content.Intent;
+import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.os.Handler;
 import android.os.Message;
 import android.util.AttributeSet;
+import android.util.TypedValue;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
 import android.widget.ImageView;
+import android.widget.TextView;
 
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.qs.QSTile.DetailAdapter;
 import com.android.systemui.settings.BrightnessController;
@@ -48,8 +52,8 @@
     private final ArrayList<TileRecord> mRecords = new ArrayList<TileRecord>();
     private final View mDetail;
     private final ViewGroup mDetailContent;
-    private final View mDetailSettingsButton;
-    private final View mDetailDoneButton;
+    private final TextView mDetailSettingsButton;
+    private final TextView mDetailDoneButton;
     private final View mBrightnessView;
     private final QSDetailClipper mClipper;
     private final H mHandler = new H();
@@ -71,6 +75,7 @@
     private QSTileHost mHost;
 
     private QSFooter mFooter;
+    private boolean mGridContentVisible = true;
 
     public QSPanel(Context context) {
         this(context, null);
@@ -82,8 +87,9 @@
 
         mDetail = LayoutInflater.from(context).inflate(R.layout.qs_detail, this, false);
         mDetailContent = (ViewGroup) mDetail.findViewById(android.R.id.content);
-        mDetailSettingsButton = mDetail.findViewById(android.R.id.button2);
-        mDetailDoneButton = mDetail.findViewById(android.R.id.button1);
+        mDetailSettingsButton = (TextView) mDetail.findViewById(android.R.id.button2);
+        mDetailDoneButton = (TextView) mDetail.findViewById(android.R.id.button1);
+        updateDetailText();
         mDetail.setVisibility(GONE);
         mDetail.setClickable(true);
         mBrightnessView = LayoutInflater.from(context).inflate(
@@ -107,6 +113,11 @@
         });
     }
 
+    private void updateDetailText() {
+        mDetailDoneButton.setText(R.string.quick_settings_done);
+        mDetailSettingsButton.setText(R.string.quick_settings_more_settings);
+    }
+
     public void setBrightnessMirror(BrightnessMirrorController c) {
         super.onFinishInflate();
         ToggleSlider brightnessSlider = (ToggleSlider) findViewById(R.id.brightness_slider);
@@ -145,6 +156,25 @@
         if (mListening) {
             refreshAllTiles();
         }
+        updateDetailText();
+    }
+
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        FontSizeUtils.updateFontSize(mDetailDoneButton, R.dimen.qs_detail_button_text_size);
+        FontSizeUtils.updateFontSize(mDetailSettingsButton, R.dimen.qs_detail_button_text_size);
+
+        // We need to poke the detail views as well as they might not be attached to the view
+        // hierarchy but reused at a later point.
+        int count = mRecords.size();
+        for (int i = 0; i < count; i++) {
+            View detailView = mRecords.get(i).detailView;
+            if (detailView != null) {
+                detailView.dispatchConfigurationChanged(newConfig);
+            }
+        }
+        mFooter.onConfigurationChanged();
     }
 
     public void setExpanded(boolean expanded) {
@@ -189,13 +219,13 @@
         mHandler.obtainMessage(H.SHOW_DETAIL, show ? 1 : 0, 0, r).sendToTarget();
     }
 
-    private void setTileVisibility(View v, boolean visible) {
-        mHandler.obtainMessage(H.SET_TILE_VISIBILITY, visible ? 1 : 0, 0, v).sendToTarget();
+    private void setTileVisibility(View v, int visibility) {
+        mHandler.obtainMessage(H.SET_TILE_VISIBILITY, visibility, 0, v).sendToTarget();
     }
 
-    private void handleSetTileVisibility(View v, boolean visible) {
-        if (visible == (v.getVisibility() == VISIBLE)) return;
-        v.setVisibility(visible ? VISIBLE : GONE);
+    private void handleSetTileVisibility(View v, int visibility) {
+        if (visibility == v.getVisibility()) return;
+        v.setVisibility(visibility);
     }
 
     public void setTiles(Collection<QSTile<?>> tiles) {
@@ -219,7 +249,14 @@
         final QSTile.Callback callback = new QSTile.Callback() {
             @Override
             public void onStateChanged(QSTile.State state) {
-                setTileVisibility(r.tileView, state.visible);
+                int visibility = state.visible ? VISIBLE : GONE;
+                if (state.visible && !mGridContentVisible) {
+
+                    // We don't want to show it if the content is hidden,
+                    // then we just set it to invisible, to ensure that it gets visible again
+                    visibility = INVISIBLE;
+                }
+                setTileVisibility(r.tileView, visibility);
                 r.tileView.onStateChanged(state);
             }
             @Override
@@ -239,6 +276,11 @@
                     fireScanStateChanged(r.scanState);
                 }
             }
+
+            @Override
+            public void onAnnouncementRequested(CharSequence announcement) {
+                announceForAccessibility(announcement);
+            }
         };
         r.tile.setCallback(callback);
         final View.OnClickListener click = new View.OnClickListener() {
@@ -312,7 +354,9 @@
             mDetail.bringToFront();
             mDetailContent.addView(r.detailView);
             setDetailRecord(r);
+            listener = mHideGridContentWhenDone;
         } else {
+            setGridContentVisibility(true);
             listener = mTeardownDetailWhenDone;
             fireScanStateChanged(false);
         }
@@ -320,6 +364,18 @@
         mClipper.animateCircularClip(x, y, show, listener);
     }
 
+    private void setGridContentVisibility(boolean visible) {
+        int newVis = visible ? VISIBLE : INVISIBLE;
+        for (int i = 0; i < mRecords.size(); i++) {
+            TileRecord tileRecord = mRecords.get(i);
+            if (tileRecord.tileView.getVisibility() != GONE) {
+                tileRecord.tileView.setVisibility(newVis);
+            }
+        }
+        mBrightnessView.setVisibility(newVis);
+        mGridContentVisible = visible;
+    }
+
     @Override
     protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
         final int width = MeasureSpec.getSize(widthMeasureSpec);
@@ -347,8 +403,8 @@
         }
 
         for (TileRecord record : mRecords) {
-            if (record.tileView.getVisibility() == GONE) continue;
             record.tileView.setDual(record.tile.supportsDualTargets());
+            if (record.tileView.getVisibility() == GONE) continue;
             final int cw = record.row == 0 ? mLargeCellWidth : mCellWidth;
             final int ch = record.row == 0 ? mLargeCellHeight : mCellHeight;
             record.tileView.measure(exactly(cw), exactly(ch));
@@ -374,16 +430,23 @@
         mBrightnessView.layout(0, mBrightnessPaddingTop,
                 mBrightnessView.getMeasuredWidth(),
                 mBrightnessPaddingTop + mBrightnessView.getMeasuredHeight());
+        boolean isRtl = getLayoutDirection() == LAYOUT_DIRECTION_RTL;
         for (TileRecord record : mRecords) {
             if (record.tileView.getVisibility() == GONE) continue;
             final int cols = getColumnCount(record.row);
             final int cw = record.row == 0 ? mLargeCellWidth : mCellWidth;
             final int extra = (w - cw * cols) / (cols + 1);
-            final int left = record.col * cw + (record.col + 1) * extra;
+            int left = record.col * cw + (record.col + 1) * extra;
             final int top = getRowTop(record.row);
-            record.tileView.layout(left, top,
-                    left + record.tileView.getMeasuredWidth(),
-                    top + record.tileView.getMeasuredHeight());
+            int right;
+            int tileWith = record.tileView.getMeasuredWidth();
+            if (isRtl) {
+                right = w - left;
+                left = right - tileWith;
+            } else {
+                right = left + tileWith;
+            }
+            record.tileView.layout(left, top, right, top + record.tileView.getMeasuredHeight());
         }
         final int dh = Math.max(mDetail.getMeasuredHeight(), getMeasuredHeight());
         mDetail.layout(0, 0, mDetail.getMeasuredWidth(), dh);
@@ -443,7 +506,7 @@
             if (msg.what == SHOW_DETAIL) {
                 handleShowDetail((Record)msg.obj, msg.arg1 != 0);
             } else if (msg.what == SET_TILE_VISIBILITY) {
-                handleSetTileVisibility((View)msg.obj, msg.arg1 != 0);
+                handleSetTileVisibility((View)msg.obj, msg.arg1);
             }
         }
     }
@@ -468,6 +531,19 @@
         };
     };
 
+    private final AnimatorListenerAdapter mHideGridContentWhenDone = new AnimatorListenerAdapter() {
+        public void onAnimationCancel(Animator animation) {
+            // If we have been cancelled, remove the listener so that onAnimationEnd doesn't get
+            // called, this will avoid accidentally turning off the grid when we don't want to.
+            animation.removeListener(this);
+        };
+
+        @Override
+        public void onAnimationEnd(Animator animation) {
+            setGridContentVisibility(false);
+        }
+    };
+
     public interface Callback {
         void onShowingDetail(QSTile.DetailAdapter detail);
         void onToggleStateChanged(boolean state);
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSTile.java b/packages/SystemUI/src/com/android/systemui/qs/QSTile.java
index 6975541..cb685fe 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSTile.java
@@ -60,6 +60,7 @@
     private Callback mCallback;
     protected final TState mState = newTileState();
     private final TState mTmpState = newTileState();
+    private boolean mAnnounceNextStateChange;
 
     abstract protected TState newTileState();
     abstract protected void handleClick();
@@ -161,9 +162,25 @@
     }
 
     private void handleStateChanged() {
+        boolean delayAnnouncement = shouldAnnouncementBeDelayed();
         if (mCallback != null) {
             mCallback.onStateChanged(mState);
+            if (mAnnounceNextStateChange && !delayAnnouncement) {
+                String announcement = composeChangeAnnouncement();
+                if (announcement != null) {
+                    mCallback.onAnnouncementRequested(announcement);
+                }
+            }
         }
+        mAnnounceNextStateChange = mAnnounceNextStateChange && delayAnnouncement;
+    }
+
+    protected boolean shouldAnnouncementBeDelayed() {
+        return false;
+    }
+
+    protected String composeChangeAnnouncement() {
+        return null;
     }
 
     private void handleShowDetail(boolean show) {
@@ -217,6 +234,7 @@
                     handleSetCallback((QSTile.Callback)msg.obj);
                 } else if (msg.what == CLICK) {
                     name = "handleClick";
+                    mAnnounceNextStateChange = true;
                     handleClick();
                 } else if (msg.what == SECONDARY_CLICK) {
                     name = "handleSecondaryClick";
@@ -255,6 +273,7 @@
         void onShowDetail(boolean show);
         void onToggleStateChanged(boolean state);
         void onScanStateChanged(boolean state);
+        void onAnnouncementRequested(CharSequence announcement);
     }
 
     public interface Host {
@@ -286,6 +305,8 @@
         public Drawable icon;
         public String label;
         public String contentDescription;
+        public String dualLabelContentDescription;
+        public boolean autoMirrorDrawable = true;
 
         public boolean copyTo(State other) {
             if (other == null) throw new IllegalArgumentException();
@@ -294,12 +315,17 @@
                     || other.iconId != iconId
                     || !Objects.equals(other.icon, icon)
                     || !Objects.equals(other.label, label)
-                    || !Objects.equals(other.contentDescription, contentDescription);
+                    || !Objects.equals(other.contentDescription, contentDescription)
+                    || !Objects.equals(other.autoMirrorDrawable, autoMirrorDrawable)
+                    || !Objects.equals(other.dualLabelContentDescription,
+                    dualLabelContentDescription);
             other.visible = visible;
             other.iconId = iconId;
             other.icon = icon;
             other.label = label;
             other.contentDescription = contentDescription;
+            other.dualLabelContentDescription = dualLabelContentDescription;
+            other.autoMirrorDrawable = autoMirrorDrawable;
             return changed;
         }
 
@@ -315,6 +341,8 @@
             sb.append(",icon=").append(icon);
             sb.append(",label=").append(label);
             sb.append(",contentDescription=").append(contentDescription);
+            sb.append(",dualLabelContentDescription=").append(dualLabelContentDescription);
+            sb.append(",autoMirrorDrawable=").append(autoMirrorDrawable);
             return sb.append(']');
         }
     }
@@ -345,6 +373,7 @@
         public boolean activityOut;
         public int overlayIconId;
         public boolean filter;
+        public boolean isOverlayIconWide;
 
         @Override
         public boolean copyTo(State other) {
@@ -352,13 +381,15 @@
             final boolean changed = o.enabled != enabled
                     || o.connected != connected || o.activityIn != activityIn
                     || o.activityOut != activityOut
-                    || o.overlayIconId != overlayIconId;
+                    || o.overlayIconId != overlayIconId
+                    || o.isOverlayIconWide != isOverlayIconWide;
             o.enabled = enabled;
             o.connected = connected;
             o.activityIn = activityIn;
             o.activityOut = activityOut;
             o.overlayIconId = overlayIconId;
             o.filter = filter;
+            o.isOverlayIconWide = isOverlayIconWide;
             return super.copyTo(other) || changed;
         }
 
@@ -371,6 +402,7 @@
             rt.insert(rt.length() - 1, ",activityOut=" + activityOut);
             rt.insert(rt.length() - 1, ",overlayIconId=" + overlayIconId);
             rt.insert(rt.length() - 1, ",filter=" + filter);
+            rt.insert(rt.length() - 1, ",wideOverlayIcon=" + isOverlayIconWide);
             return rt;
         }
     }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java b/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
index 597bb93..8d7edb9 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSTileView.java
@@ -17,6 +17,7 @@
 package com.android.systemui.qs;
 
 import android.content.Context;
+import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.content.res.TypedArray;
 import android.graphics.Typeface;
@@ -25,6 +26,7 @@
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
+import android.util.MathUtils;
 import android.util.TypedValue;
 import android.view.Gravity;
 import android.view.View;
@@ -33,6 +35,7 @@
 import android.widget.ImageView.ScaleType;
 import android.widget.TextView;
 
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.qs.QSTile.State;
 
@@ -47,9 +50,10 @@
     private final H mHandler = new H();
     private final int mIconSizePx;
     private final int mTileSpacingPx;
-    private final int mTilePaddingTopPx;
+    private int mTilePaddingTopPx;
     private final int mTilePaddingBelowIconPx;
     private final int mDualTileVerticalPaddingPx;
+    private final View mTopBackgroundView;
 
     private TextView mLabel;
     private QSDualTileLabel mDualLabel;
@@ -65,13 +69,15 @@
         final Resources res = context.getResources();
         mIconSizePx = res.getDimensionPixelSize(R.dimen.qs_tile_icon_size);
         mTileSpacingPx = res.getDimensionPixelSize(R.dimen.qs_tile_spacing);
-        mTilePaddingTopPx = res.getDimensionPixelSize(R.dimen.qs_tile_padding_top);
         mTilePaddingBelowIconPx =  res.getDimensionPixelSize(R.dimen.qs_tile_padding_below_icon);
         mDualTileVerticalPaddingPx =
                 res.getDimensionPixelSize(R.dimen.qs_dual_tile_padding_vertical);
         recreateLabel();
         setClipChildren(false);
 
+        mTopBackgroundView = new View(context);
+        addView(mTopBackgroundView);
+
         mIcon = createIcon();
         addView(mIcon);
 
@@ -82,11 +88,34 @@
         addView(mDivider);
 
         setClickable(true);
-        setBackground(getTileBackground());
+
+        updateTopPadding();
+    }
+
+    private void updateTopPadding() {
+        Resources res = getResources();
+        int padding = res.getDimensionPixelSize(R.dimen.qs_tile_padding_top);
+        int largePadding = res.getDimensionPixelSize(R.dimen.qs_tile_padding_top_large_text);
+        float largeFactor = (MathUtils.constrain(getResources().getConfiguration().fontScale,
+                1.0f, FontSizeUtils.LARGE_TEXT_SCALE) - 1f) / (FontSizeUtils.LARGE_TEXT_SCALE - 1f);
+        mTilePaddingTopPx = Math.round((1 - largeFactor) * padding + largeFactor * largePadding);
+        requestLayout();
+    }
+
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        updateTopPadding();
+        FontSizeUtils.updateFontSize(mLabel, R.dimen.qs_tile_text_size);
+        if (mDualLabel != null) {
+            mDualLabel.setTextSize(TypedValue.COMPLEX_UNIT_PX,
+                    getResources().getDimensionPixelSize(R.dimen.qs_tile_text_size));
+        }
     }
 
     private void recreateLabel() {
         CharSequence labelText = null;
+        CharSequence labelDescription = null;
         if (mLabel != null) {
             labelText = mLabel.getText();
             removeView(mLabel);
@@ -94,6 +123,7 @@
         }
         if (mDualLabel != null) {
             labelText = mDualLabel.getText();
+            labelDescription = mLabel.getContentDescription();
             removeView(mDualLabel);
             mDualLabel = null;
         }
@@ -102,7 +132,6 @@
             mDualLabel = new QSDualTileLabel(mContext);
             mDualLabel.setId(android.R.id.title);
             mDualLabel.setBackgroundResource(R.drawable.btn_borderless_rect);
-            mDualLabel.setFirstLineCaret(res.getDrawable(R.drawable.qs_dual_tile_caret));
             mDualLabel.setTextColor(res.getColor(R.color.qs_tile_text));
             mDualLabel.setPadding(0, mDualTileVerticalPaddingPx, 0, mDualTileVerticalPaddingPx);
             mDualLabel.setTypeface(CONDENSED);
@@ -110,9 +139,13 @@
                     res.getDimensionPixelSize(R.dimen.qs_tile_text_size));
             mDualLabel.setClickable(true);
             mDualLabel.setOnClickListener(mClickSecondary);
+            mDualLabel.setFocusable(true);
             if (labelText != null) {
                 mDualLabel.setText(labelText);
             }
+            if (labelDescription != null) {
+                mDualLabel.setContentDescription(labelDescription);
+            }
             addView(mDualLabel);
         } else {
             mLabel = new TextView(mContext);
@@ -138,11 +171,36 @@
         if (changed) {
             recreateLabel();
         }
-        setOnClickListener(mClickPrimary);
+        Drawable tileBackground = getTileBackground();
+        if (tileBackground instanceof RippleDrawable) {
+            setRipple((RippleDrawable) tileBackground);
+        }
+        if (dual) {
+            mTopBackgroundView.setOnClickListener(mClickPrimary);
+            setOnClickListener(null);
+            setClickable(false);
+            setImportantForAccessibility(View.IMPORTANT_FOR_ACCESSIBILITY_NO);
+            mTopBackgroundView.setBackground(tileBackground);
+        } else {
+            mTopBackgroundView.setOnClickListener(null);
+            mTopBackgroundView.setClickable(false);
+            setOnClickListener(mClickPrimary);
+            setImportantForAccessibility(View.IMPORTANT_FOR_ACCESSIBILITY_YES);
+            setBackground(tileBackground);
+        }
+        mTopBackgroundView.setFocusable(dual);
+        setFocusable(!dual);
         mDivider.setVisibility(dual ? VISIBLE : GONE);
         postInvalidate();
     }
 
+    private void setRipple(RippleDrawable tileBackground) {
+        mRipple = tileBackground;
+        if (getWidth() != 0) {
+            updateRippleSize(getWidth(), getHeight());
+        }
+    }
+
     public void init(OnClickListener clickPrimary, OnClickListener clickSecondary) {
         mClickPrimary = clickPrimary;
         mClickSecondary = clickSecondary;
@@ -160,9 +218,6 @@
         final TypedArray ta = mContext.obtainStyledAttributes(attrs);
         final Drawable d = ta.getDrawable(0);
         ta.recycle();
-        if (d instanceof RippleDrawable) {
-            mRipple = (RippleDrawable) d;
-        }
         return d;
     }
 
@@ -175,11 +230,14 @@
         final int w = MeasureSpec.getSize(widthMeasureSpec);
         final int h = MeasureSpec.getSize(heightMeasureSpec);
         final int iconSpec = exactly(mIconSizePx);
-        mIcon.measure(iconSpec, iconSpec);
+        mIcon.measure(MeasureSpec.makeMeasureSpec(w, MeasureSpec.AT_MOST), iconSpec);
         labelView().measure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(h, MeasureSpec.AT_MOST));
         if (mDual) {
             mDivider.measure(widthMeasureSpec, exactly(mDivider.getLayoutParams().height));
         }
+        int heightSpec = exactly(
+                mIconSizePx + mTilePaddingBelowIconPx + mTilePaddingTopPx);
+        mTopBackgroundView.measure(widthMeasureSpec, heightSpec);
         setMeasuredDimension(w, h);
     }
 
@@ -192,17 +250,16 @@
         final int w = getMeasuredWidth();
         final int h = getMeasuredHeight();
 
+        layout(mTopBackgroundView, 0, mTileSpacingPx);
+
         int top = 0;
         top += mTileSpacingPx;
         top += mTilePaddingTopPx;
         final int iconLeft = (w - mIcon.getMeasuredWidth()) / 2;
         layout(mIcon, iconLeft, top);
         if (mRipple != null) {
-            // center the touch feedback on the center of the icon, and dial it down a bit
-            final int cx = w / 2;
-            final int cy = mDual ? mIcon.getTop() + mIcon.getHeight() / 2 : h / 2;
-            final int rad = (int)(mIcon.getHeight() * 1.25);
-            mRipple.setHotspotBounds(cx - rad, cy - rad, cx + rad, cy + rad);
+            updateRippleSize(w, h);
+
         }
         top = mIcon.getBottom();
         top += mTilePaddingBelowIconPx;
@@ -213,6 +270,14 @@
         layout(labelView(), 0, top);
     }
 
+    private void updateRippleSize(int width, int height) {
+        // center the touch feedback on the center of the icon, and dial it down a bit
+        final int cx = width / 2;
+        final int cy = mDual ? mIcon.getTop() + mIcon.getHeight() / 2 : height / 2;
+        final int rad = (int)(mIcon.getHeight() * 1.25f);
+        mRipple.setHotspotBounds(cx - rad, cy - rad, cx + rad, cy + rad);
+    }
+
     private static void layout(View child, int left, int top) {
         child.layout(left, top, left + child.getMeasuredWidth(), top + child.getMeasuredHeight());
     }
@@ -225,9 +290,14 @@
             } else if (state.iconId > 0) {
                 iv.setImageResource(state.iconId);
             }
+            Drawable drawable = iv.getDrawable();
+            if (state.autoMirrorDrawable && drawable != null) {
+                drawable.setAutoMirrored(true);
+            }
         }
         if (mDual) {
             mDualLabel.setText(state.label);
+            mDualLabel.setContentDescription(state.dualLabelContentDescription);
         } else {
             mLabel.setText(state.label);
         }
@@ -250,4 +320,4 @@
             }
         }
     }
-}
\ No newline at end of file
+}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/SignalTileView.java b/packages/SystemUI/src/com/android/systemui/qs/SignalTileView.java
index 1df3d20..cfcd74e 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/SignalTileView.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/SignalTileView.java
@@ -18,6 +18,7 @@
 
 import android.animation.ValueAnimator;
 import android.content.Context;
+import android.graphics.drawable.Drawable;
 import android.view.View;
 import android.widget.FrameLayout;
 import android.widget.ImageView;
@@ -36,11 +37,16 @@
     private ImageView mIn;
     private ImageView mOut;
 
+    private int mWideOverlayIconStartPadding;
+
     public SignalTileView(Context context) {
         super(context);
 
         mIn = addTrafficView(R.drawable.ic_qs_signal_in);
         mOut = addTrafficView(R.drawable.ic_qs_signal_out);
+
+        mWideOverlayIconStartPadding = context.getResources().getDimensionPixelSize(
+                R.dimen.wide_type_icon_start_padding_qs);
     }
 
     private ImageView addTrafficView(int icon) {
@@ -78,10 +84,19 @@
     }
 
     private void layoutIndicator(View indicator) {
+        boolean isRtl = getLayoutDirection() == LAYOUT_DIRECTION_RTL;
+        int left, right;
+        if (isRtl) {
+            right = mIconFrame.getLeft();
+            left = right - indicator.getMeasuredWidth();
+        } else {
+            left = mIconFrame.getRight();
+            right = left + indicator.getMeasuredWidth();
+        }
         indicator.layout(
-                mIconFrame.getRight(),
+                left,
                 mIconFrame.getBottom() - indicator.getMeasuredHeight(),
-                mIconFrame.getRight() + indicator.getMeasuredWidth(),
+                right,
                 mIconFrame.getBottom());
     }
 
@@ -96,6 +111,15 @@
         } else {
             mOverlay.setVisibility(GONE);
         }
+        if (s.overlayIconId > 0 && s.isOverlayIconWide) {
+            mSignal.setPaddingRelative(mWideOverlayIconStartPadding, 0, 0, 0);
+        } else {
+            mSignal.setPaddingRelative(0, 0, 0, 0);
+        }
+        Drawable drawable = mSignal.getDrawable();
+        if (state.autoMirrorDrawable && drawable != null) {
+            drawable.setAutoMirrored(true);
+        }
         final boolean shown = isShown();
         setVisibility(mIn, shown, s.activityIn);
         setVisibility(mOut, shown, s.activityOut);
@@ -108,10 +132,9 @@
             view.animate()
                 .setDuration(visible ? SHORT_DURATION : DEFAULT_DURATION)
                 .alpha(newAlpha)
-                .withLayer()
                 .start();
         } else {
             view.setAlpha(newAlpha);
         }
     }
-}
\ No newline at end of file
+}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java
index 5d1fa80..51401c8 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/AirplaneModeTile.java
@@ -70,13 +70,20 @@
         if (airplaneMode) {
             state.iconId =  R.drawable.ic_qs_airplane_on;
             state.contentDescription =  mContext.getString(
-                    R.string.accessibility_quick_settings_airplane,
-                    mContext.getString(R.string.accessibility_desc_on));
+                    R.string.accessibility_quick_settings_airplane_on);
         } else {
             state.iconId = R.drawable.ic_qs_airplane_off;
             state.contentDescription =  mContext.getString(
-                    R.string.accessibility_quick_settings_airplane,
-                    mContext.getString(R.string.accessibility_desc_off));
+                    R.string.accessibility_quick_settings_airplane_off);
+        }
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(R.string.accessibility_quick_settings_airplane_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_airplane_changed_off);
         }
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/BluetoothTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/BluetoothTile.java
index 1b2c0b0..0b83878 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/BluetoothTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/BluetoothTile.java
@@ -77,7 +77,7 @@
 
     @Override
     protected void handleSecondaryClick() {
-        showDetail(true);
+        mHost.startSettingsActivity(BLUETOOTH_SETTINGS);
     }
 
     @Override
@@ -88,21 +88,23 @@
         final boolean connecting = mController.isBluetoothConnecting();
         state.visible = supported;
         state.value = enabled;
-        final String stateContentDescription;
+        state.autoMirrorDrawable = false;
         if (enabled) {
             state.label = null;
             if (connected) {
                 state.iconId = R.drawable.ic_qs_bluetooth_connected;
-                stateContentDescription = mContext.getString(R.string.accessibility_desc_connected);
+                state.contentDescription = mContext.getString(
+                        R.string.accessibility_quick_settings_bluetooth_connected);
                 state.label = mController.getLastDeviceName();
             } else if (connecting) {
                 state.iconId = R.drawable.ic_qs_bluetooth_connecting;
-                stateContentDescription =
-                        mContext.getString(R.string.accessibility_desc_connecting);
+                state.contentDescription = mContext.getString(
+                        R.string.accessibility_quick_settings_bluetooth_connecting);
                 state.label = mContext.getString(R.string.quick_settings_bluetooth_label);
             } else {
                 state.iconId = R.drawable.ic_qs_bluetooth_on;
-                stateContentDescription = mContext.getString(R.string.accessibility_desc_on);
+                state.contentDescription = mContext.getString(
+                        R.string.accessibility_quick_settings_bluetooth_on);
             }
             if (TextUtils.isEmpty(state.label)) {
                 state.label = mContext.getString(R.string.quick_settings_bluetooth_label);
@@ -110,10 +112,25 @@
         } else {
             state.iconId = R.drawable.ic_qs_bluetooth_off;
             state.label = mContext.getString(R.string.quick_settings_bluetooth_label);
-            stateContentDescription = mContext.getString(R.string.accessibility_desc_off);
+            state.contentDescription = mContext.getString(
+                    R.string.accessibility_quick_settings_bluetooth_off);
         }
-        state.contentDescription = mContext.getString(
-                R.string.accessibility_quick_settings_bluetooth, stateContentDescription);
+
+        String bluetoothName = state.label;
+        if (connected) {
+            bluetoothName = state.dualLabelContentDescription = mContext.getString(
+                    R.string.accessibility_bluetooth_name, state.label);
+        }
+        state.dualLabelContentDescription = bluetoothName;
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(R.string.accessibility_quick_settings_bluetooth_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_bluetooth_changed_off);
+        }
     }
 
     private final BluetoothController.Callback mCallback = new BluetoothController.Callback() {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/BugreportTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/BugreportTile.java
deleted file mode 100644
index a308e84..0000000
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/BugreportTile.java
+++ /dev/null
@@ -1,115 +0,0 @@
-/*
- * Copyright (C) 2014 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.systemui.qs.tiles;
-
-import android.app.ActivityManagerNative;
-import android.app.AlertDialog;
-import android.app.Dialog;
-import android.content.DialogInterface;
-import android.content.DialogInterface.OnClickListener;
-import android.os.Build;
-import android.os.RemoteException;
-import android.provider.Settings.Global;
-import android.view.WindowManager;
-import android.view.WindowManagerGlobal;
-
-import com.android.systemui.R;
-import com.android.systemui.qs.GlobalSetting;
-import com.android.systemui.qs.QSTile;
-
-/** Quick settings tile: Bug report **/
-public class BugreportTile extends QSTile<QSTile.State> {
-
-    private final GlobalSetting mSetting;
-
-    public BugreportTile(Host host) {
-        super(host);
-        mSetting = new GlobalSetting(mContext, mHandler, Global.BUGREPORT_IN_POWER_MENU) {
-            @Override
-            protected void handleValueChanged(int value) {
-                handleRefreshState(null);
-            }
-        };
-    }
-
-    @Override
-    protected State newTileState() {
-        return new State();
-    }
-
-    @Override
-    public void setListening(boolean listening) {
-        mSetting.setListening(listening);
-    }
-
-    @Override
-    protected void handleClick() {
-        mHandler.post(new Runnable() {
-            @Override
-            public void run() {
-                mHost.collapsePanels();
-                mUiHandler.post(mShowDialog);
-            }
-        });
-    }
-
-    @Override
-    protected void handleUpdateState(State state, Object pushArg) {
-        state.visible = mSetting.getValue() != 0;
-        state.iconId = R.drawable.ic_qs_bugreport;
-        state.label = mContext.getString(
-                R.string.bugreport_tile_extended,
-                mContext.getString(com.android.internal.R.string.bugreport_title),
-                Build.VERSION.RELEASE,
-                Build.ID);
-    }
-
-    private final Runnable mShowDialog = new Runnable() {
-        @Override
-        public void run() {
-            final AlertDialog.Builder builder = new AlertDialog.Builder(mContext);
-            builder.setPositiveButton(com.android.internal.R.string.report, new OnClickListener() {
-                @Override
-                public void onClick(DialogInterface dialog, int which) {
-                    if (which == DialogInterface.BUTTON_POSITIVE) {
-                        // Add a little delay before executing, to give the
-                        // dialog a chance to go away before it takes a
-                        // screenshot.
-                        mHandler.postDelayed(new Runnable() {
-                            @Override public void run() {
-                                try {
-                                    ActivityManagerNative.getDefault().requestBugReport();
-                                } catch (RemoteException e) {
-                                }
-                            }
-                        }, 500);
-                    }
-                }
-            });
-            builder.setMessage(com.android.internal.R.string.bugreport_message);
-            builder.setTitle(com.android.internal.R.string.bugreport_title);
-            builder.setCancelable(true);
-            final Dialog dialog = builder.create();
-            dialog.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ALERT);
-            try {
-                WindowManagerGlobal.getWindowManagerService().dismissKeyguard();
-            } catch (RemoteException e) {
-            }
-            dialog.show();
-        }
-    };
-}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/CastTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/CastTile.java
index 531ac31..8304291 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/CastTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/CastTile.java
@@ -37,8 +37,8 @@
 
 /** Quick settings tile: Cast **/
 public class CastTile extends QSTile<QSTile.BooleanState> {
-    private static final Intent WIFI_DISPLAY_SETTINGS =
-            new Intent(Settings.ACTION_WIFI_DISPLAY_SETTINGS);
+    private static final Intent CAST_SETTINGS =
+            new Intent(Settings.ACTION_CAST_SETTINGS);
 
     private final CastController mController;
     private final CastDetailAdapter mDetailAdapter;
@@ -93,6 +93,7 @@
         state.visible = !(mKeyguard.isSecure() && mKeyguard.isShowing());
         state.label = mContext.getString(R.string.quick_settings_cast_title);
         state.value = false;
+        state.autoMirrorDrawable = false;
         final Set<CastDevice> devices = mController.getCastDevices();
         boolean connecting = false;
         for (CastDevice device : devices) {
@@ -110,6 +111,15 @@
         mDetailAdapter.updateItems(devices);
     }
 
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (!mState.value) {
+            // We only announce when it's turned off to avoid vocal overflow.
+            return mContext.getString(R.string.accessibility_casting_turned_off);
+        }
+        return null;
+    }
+
     private String getDeviceName(CastDevice device) {
         return device.name != null ? device.name
                 : mContext.getString(R.string.quick_settings_cast_device_default_name);
@@ -144,7 +154,7 @@
 
         @Override
         public Intent getSettingsIntent() {
-            return WIFI_DISPLAY_SETTINGS;
+            return CAST_SETTINGS;
         }
 
         @Override
@@ -230,7 +240,8 @@
         @Override
         public void onDetailItemDisconnect(Item item) {
             if (item == null || item.tag == null) return;
-            mController.stopCasting();
+            final CastDevice device = (CastDevice) item.tag;
+            mController.stopCasting(device);
         }
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/CellularTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/CellularTile.java
index ce42d47..359a259 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/CellularTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/CellularTile.java
@@ -23,10 +23,8 @@
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
-import android.widget.TextView;
 
 import com.android.systemui.R;
-import com.android.systemui.qs.DataUsageGraph;
 import com.android.systemui.qs.QSTile;
 import com.android.systemui.qs.QSTileView;
 import com.android.systemui.qs.SignalTileView;
@@ -34,8 +32,6 @@
 import com.android.systemui.statusbar.policy.NetworkController.DataUsageInfo;
 import com.android.systemui.statusbar.policy.NetworkController.NetworkSignalChangedCallback;
 
-import java.text.DecimalFormat;
-
 /** Quick settings tile: Cellular **/
 public class CellularTile extends QSTile<QSTile.SignalState> {
     private static final Intent CELLULAR_SETTINGS = new Intent().setComponent(new ComponentName(
@@ -91,14 +87,16 @@
         if (cb == null) return;
 
         final Resources r = mContext.getResources();
-        state.iconId = cb.noSim ? R.drawable.stat_sys_no_sim
+        state.iconId = cb.noSim ? R.drawable.ic_qs_no_sim
                 : !cb.enabled || cb.airplaneModeEnabled ? R.drawable.ic_qs_signal_disabled
                 : cb.mobileSignalIconId > 0 ? cb.mobileSignalIconId
                 : R.drawable.ic_qs_signal_no_signal;
+        state.isOverlayIconWide = cb.isDataTypeIconWide;
+        state.autoMirrorDrawable = !cb.noSim;
         state.overlayIconId = cb.enabled && (cb.dataTypeIconId > 0) && !cb.wifiConnected
                 ? cb.dataTypeIconId
                 : 0;
-        state.filter = state.iconId != R.drawable.stat_sys_no_sim;
+        state.filter = state.iconId != R.drawable.ic_qs_no_sim;
         state.activityIn = cb.enabled && cb.activityIn;
         state.activityOut = cb.enabled && cb.activityOut;
 
@@ -141,6 +139,7 @@
         boolean activityOut;
         String enabledDesc;
         boolean noSim;
+        boolean isDataTypeIconWide;
     }
 
     private final NetworkSignalChangedCallback mCallback = new NetworkSignalChangedCallback() {
@@ -161,7 +160,8 @@
                 int mobileSignalIconId,
                 String mobileSignalContentDescriptionId, int dataTypeIconId,
                 boolean activityIn, boolean activityOut,
-                String dataTypeContentDescriptionId, String description, boolean noSim) {
+                String dataTypeContentDescriptionId, String description, boolean noSim,
+                boolean isDataTypeIconWide) {
             final CallbackInfo info = new CallbackInfo();  // TODO pool?
             info.enabled = enabled;
             info.wifiEnabled = mWifiEnabled;
@@ -175,6 +175,7 @@
             info.activityOut = activityOut;
             info.enabledDesc = description;
             info.noSim = noSim;
+            info.isDataTypeIconWide = isDataTypeIconWide;
             refreshState(info);
         }
 
@@ -189,11 +190,6 @@
     };
 
     private final class CellularDetailAdapter implements DetailAdapter {
-        private static final double KB = 1024;
-        private static final double MB = 1024 * KB;
-        private static final double GB = 1024 * MB;
-
-        private final DecimalFormat FORMAT = new DecimalFormat("#.##");
 
         @Override
         public int getTitle() {
@@ -217,80 +213,17 @@
 
         @Override
         public View createDetailView(Context context, View convertView, ViewGroup parent) {
-            final View v = convertView != null ? convertView : LayoutInflater.from(mContext)
-                    .inflate(R.layout.data_usage, parent, false);
+            final DataUsageDetailView v = (DataUsageDetailView) (convertView != null
+                    ? convertView
+                    : LayoutInflater.from(mContext).inflate(R.layout.data_usage, parent, false));
             final DataUsageInfo info = mController.getDataUsageInfo();
             if (info == null) return v;
-            final Resources res = mContext.getResources();
-            final int titleId;
-            final long bytes;
-            int usageColor = R.color.system_accent_color;
-            final String top;
-            String bottom = null;
-            if (info.usageLevel < info.warningLevel || info.limitLevel <= 0) {
-                // under warning, or no limit
-                titleId = R.string.quick_settings_cellular_detail_data_usage;
-                bytes = info.usageLevel;
-                top = res.getString(R.string.quick_settings_cellular_detail_data_warning,
-                        formatBytes(info.warningLevel));
-            } else if (info.usageLevel <= info.limitLevel) {
-                // over warning, under limit
-                titleId = R.string.quick_settings_cellular_detail_remaining_data;
-                bytes = info.limitLevel - info.usageLevel;
-                top = res.getString(R.string.quick_settings_cellular_detail_data_used,
-                        formatBytes(info.usageLevel));
-                bottom = res.getString(R.string.quick_settings_cellular_detail_data_limit,
-                        formatBytes(info.limitLevel));
-            } else {
-                // over limit
-                titleId = R.string.quick_settings_cellular_detail_over_limit;
-                bytes = info.usageLevel - info.limitLevel;
-                top = res.getString(R.string.quick_settings_cellular_detail_data_used,
-                        formatBytes(info.usageLevel));
-                bottom = res.getString(R.string.quick_settings_cellular_detail_data_limit,
-                        formatBytes(info.limitLevel));
-                usageColor = R.color.system_warning_color;
-            }
-
-            final TextView title = (TextView) v.findViewById(android.R.id.title);
-            title.setText(titleId);
-            final TextView usage = (TextView) v.findViewById(R.id.usage_text);
-            usage.setText(formatBytes(bytes));
-            usage.setTextColor(res.getColor(usageColor));
-            final DataUsageGraph graph = (DataUsageGraph) v.findViewById(R.id.usage_graph);
-            graph.setLevels(info.limitLevel, info.warningLevel, info.usageLevel);
-            final TextView carrier = (TextView) v.findViewById(R.id.usage_carrier_text);
-            carrier.setText(info.carrier);
-            final TextView period = (TextView) v.findViewById(R.id.usage_period_text);
-            period.setText(info.period);
-            final TextView infoTop = (TextView) v.findViewById(R.id.usage_info_top_text);
-            infoTop.setVisibility(top != null ? View.VISIBLE : View.GONE);
-            infoTop.setText(top);
-            final TextView infoBottom = (TextView) v.findViewById(R.id.usage_info_bottom_text);
-            infoBottom.setVisibility(bottom != null ? View.VISIBLE : View.GONE);
-            infoBottom.setText(bottom);
+            v.bind(info);
             return v;
         }
 
         public void setMobileDataEnabled(boolean enabled) {
             fireToggleStateChanged(enabled);
         }
-
-        private String formatBytes(long bytes) {
-            final long b = Math.abs(bytes);
-            double val;
-            String suffix;
-            if (b > 100 * MB) {
-                val = b / GB;
-                suffix = "GB";
-            } else if (b > 100 * KB) {
-                val = b / MB;
-                suffix = "MB";
-            } else {
-                val = b / KB;
-                suffix = "KB";
-            }
-            return FORMAT.format(val * (bytes < 0 ? -1 : 1)) + " " + suffix;
-        }
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
index 21254d4..a62bbff 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
@@ -29,6 +29,8 @@
     private final SecureSetting mSetting;
     private final UsageTracker mUsageTracker;
 
+    private boolean mListening;
+
     public ColorInversionTile(Host host) {
         super(host);
 
@@ -36,18 +38,25 @@
                 Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED) {
             @Override
             protected void handleValueChanged(int value) {
-                handleRefreshState(value);
                 mUsageTracker.trackUsage();
+                if (mListening) {
+                    handleRefreshState(value);
+                }
             }
         };
         mUsageTracker = new UsageTracker(host.getContext(), ColorInversionTile.class);
+        if (mSetting.getValue() != 0 && !mUsageTracker.isRecentlyUsed()) {
+            mUsageTracker.trackUsage();
+        }
         mUsageTracker.setListening(true);
+        mSetting.setListening(true);
     }
 
     @Override
     protected void handleDestroy() {
         super.handleDestroy();
         mUsageTracker.setListening(false);
+        mSetting.setListening(false);
     }
 
     @Override
@@ -57,7 +66,7 @@
 
     @Override
     public void setListening(boolean listening) {
-        mSetting.setListening(listening);
+        mListening = listening;
     }
 
     @Override
@@ -79,4 +88,15 @@
         state.label = mContext.getString(R.string.quick_settings_inversion_label);
         state.iconId = enabled ? R.drawable.ic_qs_inversion_on : R.drawable.ic_qs_inversion_off;
     }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(
+                    R.string.accessibility_quick_settings_color_inversion_changed_on);
+        } else {
+            return mContext.getString(
+                    R.string.accessibility_quick_settings_color_inversion_changed_off);
+        }
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/DataUsageDetailView.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/DataUsageDetailView.java
new file mode 100644
index 0000000..7bdb58f
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/DataUsageDetailView.java
@@ -0,0 +1,131 @@
+/*
+ * Copyright (C) 2014 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.systemui.qs.tiles;
+
+import android.content.Context;
+import android.content.res.Configuration;
+import android.content.res.Resources;
+import android.util.AttributeSet;
+import android.util.TypedValue;
+import android.view.View;
+import android.widget.LinearLayout;
+import android.widget.TextView;
+
+import com.android.systemui.FontSizeUtils;
+import com.android.systemui.R;
+import com.android.systemui.qs.DataUsageGraph;
+import com.android.systemui.statusbar.policy.NetworkController;
+
+import java.text.DecimalFormat;
+
+/**
+ * Layout for the data usage detail in quick settings.
+ */
+public class DataUsageDetailView extends LinearLayout {
+
+    private static final double KB = 1024;
+    private static final double MB = 1024 * KB;
+    private static final double GB = 1024 * MB;
+
+    private final DecimalFormat FORMAT = new DecimalFormat("#.##");
+
+    public DataUsageDetailView(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        FontSizeUtils.updateFontSize(this, android.R.id.title, R.dimen.qs_data_usage_text_size);
+        FontSizeUtils.updateFontSize(this, R.id.usage_text, R.dimen.qs_data_usage_usage_text_size);
+        FontSizeUtils.updateFontSize(this, R.id.usage_carrier_text,
+                R.dimen.qs_data_usage_text_size);
+        FontSizeUtils.updateFontSize(this, R.id.usage_info_top_text,
+                R.dimen.qs_data_usage_text_size);
+        FontSizeUtils.updateFontSize(this, R.id.usage_period_text, R.dimen.qs_data_usage_text_size);
+        FontSizeUtils.updateFontSize(this, R.id.usage_info_bottom_text,
+                R.dimen.qs_data_usage_text_size);
+    }
+
+    public void bind(NetworkController.DataUsageInfo info) {
+        final Resources res = mContext.getResources();
+        final int titleId;
+        final long bytes;
+        int usageColor = R.color.system_accent_color;
+        final String top;
+        String bottom = null;
+        if (info.usageLevel < info.warningLevel || info.limitLevel <= 0) {
+            // under warning, or no limit
+            titleId = R.string.quick_settings_cellular_detail_data_usage;
+            bytes = info.usageLevel;
+            top = res.getString(R.string.quick_settings_cellular_detail_data_warning,
+                    formatBytes(info.warningLevel));
+        } else if (info.usageLevel <= info.limitLevel) {
+            // over warning, under limit
+            titleId = R.string.quick_settings_cellular_detail_remaining_data;
+            bytes = info.limitLevel - info.usageLevel;
+            top = res.getString(R.string.quick_settings_cellular_detail_data_used,
+                    formatBytes(info.usageLevel));
+            bottom = res.getString(R.string.quick_settings_cellular_detail_data_limit,
+                    formatBytes(info.limitLevel));
+        } else {
+            // over limit
+            titleId = R.string.quick_settings_cellular_detail_over_limit;
+            bytes = info.usageLevel - info.limitLevel;
+            top = res.getString(R.string.quick_settings_cellular_detail_data_used,
+                    formatBytes(info.usageLevel));
+            bottom = res.getString(R.string.quick_settings_cellular_detail_data_limit,
+                    formatBytes(info.limitLevel));
+            usageColor = R.color.system_warning_color;
+        }
+
+        final TextView title = (TextView) findViewById(android.R.id.title);
+        title.setText(titleId);
+        final TextView usage = (TextView) findViewById(R.id.usage_text);
+        usage.setText(formatBytes(bytes));
+        usage.setTextColor(res.getColor(usageColor));
+        final DataUsageGraph graph = (DataUsageGraph) findViewById(R.id.usage_graph);
+        graph.setLevels(info.limitLevel, info.warningLevel, info.usageLevel);
+        final TextView carrier = (TextView) findViewById(R.id.usage_carrier_text);
+        carrier.setText(info.carrier);
+        final TextView period = (TextView) findViewById(R.id.usage_period_text);
+        period.setText(info.period);
+        final TextView infoTop = (TextView) findViewById(R.id.usage_info_top_text);
+        infoTop.setVisibility(top != null ? View.VISIBLE : View.GONE);
+        infoTop.setText(top);
+        final TextView infoBottom = (TextView) findViewById(R.id.usage_info_bottom_text);
+        infoBottom.setVisibility(bottom != null ? View.VISIBLE : View.GONE);
+        infoBottom.setText(bottom);
+    }
+
+    private String formatBytes(long bytes) {
+        final long b = Math.abs(bytes);
+        double val;
+        String suffix;
+        if (b > 100 * MB) {
+            val = b / GB;
+            suffix = "GB";
+        } else if (b > 100 * KB) {
+            val = b / MB;
+            suffix = "MB";
+        } else {
+            val = b / KB;
+            suffix = "KB";
+        }
+        return FORMAT.format(val * (bytes < 0 ? -1 : 1)) + " " + suffix;
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/FlashlightTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/FlashlightTile.java
index 3ddf5e3..e6b7f02 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/FlashlightTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/FlashlightTile.java
@@ -94,6 +94,19 @@
         state.label = mHost.getContext().getString(R.string.quick_settings_flashlight_label);
         state.iconId = state.value
                 ? R.drawable.ic_qs_flashlight_on : R.drawable.ic_qs_flashlight_off;
+        int onOrOffId = state.value
+                ? R.string.accessibility_quick_settings_flashlight_on
+                : R.string.accessibility_quick_settings_flashlight_off;
+        state.contentDescription = mContext.getString(onOrOffId);
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(R.string.accessibility_quick_settings_flashlight_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_flashlight_changed_off);
+        }
     }
 
     @Override
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/HotspotTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/HotspotTile.java
index 96333a3..9984fca 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/HotspotTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/HotspotTile.java
@@ -74,6 +74,15 @@
                 : R.drawable.ic_qs_hotspot_off;
     }
 
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(R.string.accessibility_quick_settings_hotspot_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_hotspot_changed_off);
+        }
+    }
+
     private final class Callback implements HotspotController.Callback {
         @Override
         public void onHotspotChanged(boolean enabled) {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/LocationTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/LocationTile.java
index c4dd643..d1dc5d2 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/LocationTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/LocationTile.java
@@ -54,31 +54,37 @@
     @Override
     protected void handleClick() {
         final boolean wasEnabled = (Boolean) mState.value;
-        final boolean changed = mController.setLocationEnabled(!wasEnabled);
-        if (!wasEnabled && changed) {
-            // If we've successfully switched from location off to on, close the
-            // notifications tray to show the network location provider consent dialog.
-            mHost.collapsePanels();
-        }
+        mController.setLocationEnabled(!wasEnabled);
     }
 
     @Override
     protected void handleUpdateState(BooleanState state, Object arg) {
         final boolean locationEnabled =  mController.isLocationEnabled();
-        state.visible = !(mKeyguard.isSecure() && mKeyguard.isShowing());
+
+        // Work around for bug 15916487: don't show location tile on top of lock screen. After the
+        // bug is fixed, this should be reverted to only hiding it on secure lock screens:
+        // state.visible = !(mKeyguard.isSecure() && mKeyguard.isShowing());
+        state.visible = !mKeyguard.isShowing();
         state.value = locationEnabled;
         if (locationEnabled) {
             state.iconId = R.drawable.ic_qs_location_on;
             state.label = mContext.getString(R.string.quick_settings_location_label);
             state.contentDescription = mContext.getString(
-                    R.string.accessibility_quick_settings_location,
-                    mContext.getString(R.string.accessibility_desc_on));
+                    R.string.accessibility_quick_settings_location_on);
         } else {
             state.iconId = R.drawable.ic_qs_location_off;
             state.label = mContext.getString(R.string.quick_settings_location_label);
             state.contentDescription = mContext.getString(
-                    R.string.accessibility_quick_settings_location,
-                    mContext.getString(R.string.accessibility_desc_off));
+                    R.string.accessibility_quick_settings_location_off);
+        }
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.value) {
+            return mContext.getString(R.string.accessibility_quick_settings_location_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_location_changed_off);
         }
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/RotationLockTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/RotationLockTile.java
index 21cf9ec..ae40a4d 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/RotationLockTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/RotationLockTile.java
@@ -74,6 +74,38 @@
             state.label = mContext.getString(R.string.quick_settings_rotation_unlocked_label);
             state.icon = res.getDrawable(R.drawable.ic_qs_rotation_unlocked);
         }
+        state.contentDescription = getAccessibilityString(
+                R.string.accessibility_rotation_lock_on_portrait,
+                R.string.accessibility_rotation_lock_on_landscape,
+                R.string.accessibility_rotation_lock_off);
+    }
+
+    /**
+     * Get the correct accessibility string based on the state
+     *
+     * @param idWhenPortrait The id which should be used when locked in portrait.
+     * @param idWhenLandscape The id which should be used when locked in landscape.
+     * @param idWhenOff The id which should be used when the rotation lock is off.
+     * @return
+     */
+    private String getAccessibilityString(int idWhenPortrait, int idWhenLandscape, int idWhenOff) {
+        int stringID;
+        if (mState.value) {
+            final boolean portrait = mContext.getResources().getConfiguration().orientation
+                    != Configuration.ORIENTATION_LANDSCAPE;
+            stringID = portrait ? idWhenPortrait: idWhenLandscape;
+        } else {
+            stringID = idWhenOff;
+        }
+        return mContext.getString(stringID);
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        return getAccessibilityString(
+                R.string.accessibility_rotation_lock_on_portrait_changed,
+                R.string.accessibility_rotation_lock_on_landscape_changed,
+                R.string.accessibility_rotation_lock_off_changed);
     }
 
     private final RotationLockControllerCallback mCallback = new RotationLockControllerCallback() {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/UserDetailItemView.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/UserDetailItemView.java
index a56b7a7..c55cbccb 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/UserDetailItemView.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/UserDetailItemView.java
@@ -17,15 +17,18 @@
 package com.android.systemui.qs.tiles;
 
 import com.android.internal.util.ArrayUtils;
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.statusbar.phone.UserAvatarView;
 
 import android.content.Context;
+import android.content.res.Configuration;
 import android.content.res.TypedArray;
 import android.graphics.Bitmap;
 import android.graphics.Typeface;
 import android.graphics.drawable.Drawable;
 import android.util.AttributeSet;
+import android.util.TypedValue;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -107,6 +110,12 @@
     }
 
     @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        FontSizeUtils.updateFontSize(mName, R.dimen.qs_detail_item_secondary_text_size);
+    }
+
+    @Override
     protected void drawableStateChanged() {
         super.drawableStateChanged();
         updateTypeface();
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/WifiTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/WifiTile.java
index 5651d49..0985812 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/WifiTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/WifiTile.java
@@ -40,6 +40,7 @@
 
     private final NetworkController mController;
     private final WifiDetailAdapter mDetailAdapter;
+    private final QSTile.SignalState mStateBeforeClick = newTileState();
 
     public WifiTile(Host host) {
         super(host);
@@ -80,16 +81,13 @@
 
     @Override
     protected void handleClick() {
+        mState.copyTo(mStateBeforeClick);
         mController.setWifiEnabled(!mState.enabled);
     }
 
     @Override
     protected void handleSecondaryClick() {
-        if (!mState.enabled) {
-            mController.setWifiEnabled(true);
-            mState.enabled = true;
-        }
-        showDetail(true);
+        mHost.startSettingsActivity(WIFI_SETTINGS);
     }
 
     @Override
@@ -132,8 +130,26 @@
         }
         state.contentDescription = mContext.getString(
                 R.string.accessibility_quick_settings_wifi,
-                signalContentDescription,
-                state.connected ? state.label : "");
+                signalContentDescription);
+        String wifiName = state.label;
+        if (state.connected) {
+            wifiName = r.getString(R.string.accessibility_wifi_name, state.label);
+        }
+        state.dualLabelContentDescription = wifiName;
+    }
+
+    @Override
+    protected boolean shouldAnnouncementBeDelayed() {
+        return mStateBeforeClick.enabled == mState.enabled;
+    }
+
+    @Override
+    protected String composeChangeAnnouncement() {
+        if (mState.enabled) {
+            return mContext.getString(R.string.accessibility_quick_settings_wifi_changed_on);
+        } else {
+            return mContext.getString(R.string.accessibility_quick_settings_wifi_changed_off);
+        }
     }
 
     private static String removeDoubleQuotes(String string) {
@@ -190,7 +206,8 @@
                 int mobileSignalIconId,
                 String mobileSignalContentDescriptionId, int dataTypeIconId,
                 boolean activityIn, boolean activityOut,
-                String dataTypeContentDescriptionId, String description, boolean noSim) {
+                String dataTypeContentDescriptionId, String description, boolean noSim,
+                boolean isDataTypeIconWide) {
             // noop
         }
 
diff --git a/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java b/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
index 3e2ef94..34430d9 100644
--- a/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
+++ b/packages/SystemUI/src/com/android/systemui/recent/RecentTasksLoader.java
@@ -34,14 +34,12 @@
 import android.os.Process;
 import android.os.RemoteException;
 import android.os.UserHandle;
-import android.os.UserManager;
 import android.util.Log;
 import android.view.MotionEvent;
 import android.view.View;
 
 import com.android.systemui.R;
 import com.android.systemui.recents.misc.SystemServicesProxy;
-import com.android.systemui.recents.misc.Utilities;
 import com.android.systemui.statusbar.phone.PhoneStatusBar;
 
 import java.util.ArrayList;
@@ -205,8 +203,7 @@
         Drawable icon = getFullResIcon(td.resolveInfo, pm);
         if (td.userId != UserHandle.myUserId()) {
             // Need to badge the icon
-            final UserManager um = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
-            icon = um.getBadgedDrawableForUser(icon, new UserHandle(td.userId));
+            icon = mContext.getPackageManager().getUserBadgedIcon(icon, new UserHandle(td.userId));
         }
         if (DEBUG) Log.v(TAG, "Loaded bitmap for task "
                 + td + ": " + thumbnail);
diff --git a/packages/SystemUI/src/com/android/systemui/recent/RecentsHorizontalScrollView.java b/packages/SystemUI/src/com/android/systemui/recent/RecentsHorizontalScrollView.java
index 25a62ae..bdb0ad3 100644
--- a/packages/SystemUI/src/com/android/systemui/recent/RecentsHorizontalScrollView.java
+++ b/packages/SystemUI/src/com/android/systemui/recent/RecentsHorizontalScrollView.java
@@ -191,6 +191,11 @@
         return true;
     }
 
+    @Override
+    public boolean isAntiFalsingNeeded() {
+        return false;
+    }
+
     public void dismissChild(View v) {
         mSwipeHelper.dismissChild(v, 0);
     }
diff --git a/packages/SystemUI/src/com/android/systemui/recent/RecentsVerticalScrollView.java b/packages/SystemUI/src/com/android/systemui/recent/RecentsVerticalScrollView.java
index e8e9d52..47c096f 100644
--- a/packages/SystemUI/src/com/android/systemui/recent/RecentsVerticalScrollView.java
+++ b/packages/SystemUI/src/com/android/systemui/recent/RecentsVerticalScrollView.java
@@ -199,6 +199,11 @@
         return true;
     }
 
+    @Override
+    public boolean isAntiFalsingNeeded() {
+        return false;
+    }
+
     public void dismissChild(View v) {
         mSwipeHelper.dismissChild(v, 0);
     }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/AlternateRecentsComponent.java b/packages/SystemUI/src/com/android/systemui/recents/AlternateRecentsComponent.java
index 354eb55..787de4e 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/AlternateRecentsComponent.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/AlternateRecentsComponent.java
@@ -16,9 +16,12 @@
 
 package com.android.systemui.recents;
 
+import android.app.Activity;
 import android.app.ActivityManager;
 import android.app.ActivityOptions;
+import android.appwidget.AppWidgetProviderInfo;
 import android.content.ActivityNotFoundException;
+import android.content.BroadcastReceiver;
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
@@ -29,18 +32,19 @@
 import android.graphics.Rect;
 import android.os.Handler;
 import android.os.UserHandle;
+import android.view.LayoutInflater;
 import android.view.View;
 import com.android.systemui.R;
 import com.android.systemui.RecentsComponent;
 import com.android.systemui.recents.misc.Console;
 import com.android.systemui.recents.misc.SystemServicesProxy;
-import com.android.systemui.recents.misc.Utilities;
 import com.android.systemui.recents.model.RecentsTaskLoader;
 import com.android.systemui.recents.model.Task;
 import com.android.systemui.recents.model.TaskGrouping;
 import com.android.systemui.recents.model.TaskStack;
 import com.android.systemui.recents.views.TaskStackView;
 import com.android.systemui.recents.views.TaskStackViewLayoutAlgorithm;
+import com.android.systemui.recents.views.TaskViewHeader;
 import com.android.systemui.recents.views.TaskViewTransform;
 
 import java.util.ArrayList;
@@ -51,6 +55,7 @@
 public class AlternateRecentsComponent implements ActivityOptions.OnAnimationStartedListener {
 
     final public static String EXTRA_FROM_HOME = "recents.triggeredOverHome";
+    final public static String EXTRA_FROM_SEARCH_HOME = "recents.triggeredOverSearchHome";
     final public static String EXTRA_FROM_APP_THUMBNAIL = "recents.animatingWithThumbnail";
     final public static String EXTRA_FROM_APP_FULL_SCREENSHOT = "recents.thumbnail";
     final public static String EXTRA_FROM_TASK_ID = "recents.activeTaskId";
@@ -61,7 +66,7 @@
     final public static String ACTION_TOGGLE_RECENTS_ACTIVITY = "action_toggle_recents_activity";
     final public static String ACTION_HIDE_RECENTS_ACTIVITY = "action_hide_recents_activity";
 
-    final static int sMinToggleDelay = 425;
+    final static int sMinToggleDelay = 350;
 
     final static String sToggleRecentsAction = "com.android.systemui.recents.SHOW_RECENTS";
     final static String sRecentsPackage = "com.android.systemui";
@@ -71,6 +76,7 @@
     static RecentsComponent.Callbacks sRecentsComponentCallbacks;
 
     Context mContext;
+    LayoutInflater mInflater;
     SystemServicesProxy mSystemServicesProxy;
     Handler mHandler;
     boolean mBootCompleted;
@@ -86,37 +92,31 @@
     int mNavBarHeight;
     int mNavBarWidth;
 
+    // Header (for transition)
+    TaskViewHeader mHeaderBar;
+    TaskStackView mDummyStackView;
+
     // Variables to keep track of if we need to start recents after binding
     View mStatusBarView;
     boolean mTriggeredFromAltTab;
     long mLastToggleTime;
 
     public AlternateRecentsComponent(Context context) {
-        Resources res = context.getResources();
+        RecentsTaskLoader.initialize(context);
+        mInflater = LayoutInflater.from(context);
         mContext = context;
         mSystemServicesProxy = new SystemServicesProxy(context);
         mHandler = new Handler();
-        mConfig = RecentsConfiguration.reinitialize(context, mSystemServicesProxy);
-        mWindowRect = mSystemServicesProxy.getWindowRect();
         mTaskStackBounds = new Rect();
-        mStatusBarHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.status_bar_height);
-        mNavBarHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.navigation_bar_height);
-        mNavBarWidth = res.getDimensionPixelSize(com.android.internal.R.dimen.navigation_bar_width);
-        mConfig.getTaskStackBounds(mWindowRect.width(), mWindowRect.height(), mStatusBarHeight,
-                mNavBarWidth, mTaskStackBounds);
-        if (mConfig.isLandscape && mConfig.transposeRecentsLayoutWithOrientation) {
-            mSystemInsets.set(0, mStatusBarHeight, mNavBarWidth, 0);
-        } else {
-            mSystemInsets.set(0, mStatusBarHeight, 0, mNavBarHeight);
-        }
     }
 
-    public void onStart() {
-        // Initialize some static datastructures
-        TaskStackViewLayoutAlgorithm.initializeCurve();
-    }
+    public void onStart() {}
 
     public void onBootCompleted() {
+        // Initialize some static datastructures
+        TaskStackViewLayoutAlgorithm.initializeCurve();
+        // Load the header bar layout
+        reloadHeaderBarLayout();
         mBootCompleted = true;
     }
 
@@ -139,7 +139,8 @@
                 // Notify recents to hide itself
                 Intent intent = new Intent(ACTION_HIDE_RECENTS_ACTIVITY);
                 intent.setPackage(mContext.getPackageName());
-                intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
+                intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT |
+                        Intent.FLAG_RECEIVER_FOREGROUND);
                 intent.putExtra(EXTRA_TRIGGERED_FROM_ALT_TAB, triggeredFromAltTab);
                 intent.putExtra(EXTRA_TRIGGERED_FROM_HOME_KEY, triggeredFromHomeKey);
                 mContext.sendBroadcastAsUser(intent, UserHandle.CURRENT);
@@ -168,8 +169,9 @@
     }
 
     void showRelativeAffiliatedTask(boolean showNextTask) {
-        TaskStack stack = RecentsTaskLoader.getShallowTaskStack(mSystemServicesProxy,
-                Integer.MAX_VALUE);
+        RecentsTaskLoader loader = RecentsTaskLoader.getInstance();
+        TaskStack stack = loader.getTaskStack(mSystemServicesProxy, mContext.getResources(),
+                -1, -1, false, null, null);
         // Return early if there are no tasks
         if (stack.getTaskCount() == 0) return;
 
@@ -189,10 +191,14 @@
                 Task.TaskKey toTaskKey;
                 if (showNextTask) {
                     toTaskKey = group.getNextTaskInGroup(task);
-                    // XXX: We will actually set the appropriate launch animations here
+                    launchOpts = ActivityOptions.makeCustomAnimation(mContext,
+                            R.anim.recents_launch_next_affiliated_task_target,
+                            R.anim.recents_launch_next_affiliated_task_source);
                 } else {
                     toTaskKey = group.getPrevTaskInGroup(task);
-                    // XXX: We will actually set the appropriate launch animations here
+                    launchOpts = ActivityOptions.makeCustomAnimation(mContext,
+                            R.anim.recents_launch_prev_affiliated_task_target,
+                            R.anim.recents_launch_prev_affiliated_task_source);
                 }
                 if (toTaskKey != null) {
                     toTask = stack.findTaskWithId(toTaskKey.id);
@@ -203,7 +209,11 @@
 
         // Return early if there is no next task
         if (toTask == null) {
-            // XXX: We will actually show a bounce animation here
+            if (showNextTask) {
+                // XXX: Show the next-task bounce animation
+            } else {
+                // XXX: Show the prev-task bounce animation
+            }
             return;
         }
 
@@ -212,21 +222,9 @@
             // Bring an active task to the foreground
             mSystemServicesProxy.moveTaskToFront(toTask.key.id, launchOpts);
         } else {
-            // Launch the activity anew with the desired animation
-            boolean isDocument = Utilities.isDocument(toTask.key.baseIntent);
-            Intent intent = new Intent(toTask.key.baseIntent);
-            intent.addFlags(Intent.FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY
-                    | Intent.FLAG_ACTIVITY_TASK_ON_HOME);
-            if (!isDocument) {
-                intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-            }
             try {
                 mSystemServicesProxy.startActivityFromRecents(toTask.key.id, launchOpts);
             } catch (ActivityNotFoundException anfe) {}
-
-            // Remove the old task from activity manager
-            RecentsTaskLoader.getInstance().getSystemServicesProxy().removeTask(toTask.key.id,
-                    isDocument);
         }
     }
 
@@ -239,17 +237,43 @@
     }
 
     public void onConfigurationChanged(Configuration newConfig) {
+        // Reload the header bar layout
+        reloadHeaderBarLayout();
+        sLastScreenshot = null;
+    }
+
+    /** Prepares the header bar layout. */
+    void reloadHeaderBarLayout() {
+        Resources res = mContext.getResources();
+        mWindowRect = mSystemServicesProxy.getWindowRect();
+        mStatusBarHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.status_bar_height);
+        mNavBarHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.navigation_bar_height);
+        mNavBarWidth = res.getDimensionPixelSize(com.android.internal.R.dimen.navigation_bar_width);
         mConfig = RecentsConfiguration.reinitialize(mContext, mSystemServicesProxy);
         mConfig.updateOnConfigurationChange();
-        mWindowRect = mSystemServicesProxy.getWindowRect();
         mConfig.getTaskStackBounds(mWindowRect.width(), mWindowRect.height(), mStatusBarHeight,
-                mNavBarWidth, mTaskStackBounds);
-        if (mConfig.isLandscape && mConfig.transposeRecentsLayoutWithOrientation) {
+                (mConfig.hasTransposedNavBar ? mNavBarWidth : 0), mTaskStackBounds);
+        if (mConfig.isLandscape && mConfig.hasTransposedNavBar) {
             mSystemInsets.set(0, mStatusBarHeight, mNavBarWidth, 0);
         } else {
             mSystemInsets.set(0, mStatusBarHeight, 0, mNavBarHeight);
         }
-        sLastScreenshot = null;
+
+        // Inflate the header bar layout so that we can rebind and draw it for the transition
+        TaskStack stack = new TaskStack();
+        mDummyStackView = new TaskStackView(mContext, stack);
+        TaskStackViewLayoutAlgorithm algo = mDummyStackView.getStackAlgorithm();
+        Rect taskStackBounds = new Rect(mTaskStackBounds);
+        taskStackBounds.bottom -= mSystemInsets.bottom;
+        algo.computeRects(mWindowRect.width(), mWindowRect.height(), taskStackBounds);
+        Rect taskViewSize = algo.getUntransformedTaskViewSize();
+        int taskBarHeight = res.getDimensionPixelSize(R.dimen.recents_task_bar_height);
+        mHeaderBar = (TaskViewHeader) mInflater.inflate(R.layout.recents_task_view_header, null,
+                false);
+        mHeaderBar.measure(
+                View.MeasureSpec.makeMeasureSpec(taskViewSize.width(), View.MeasureSpec.EXACTLY),
+                View.MeasureSpec.makeMeasureSpec(taskBarHeight, View.MeasureSpec.EXACTLY));
+        mHeaderBar.layout(0, 0, taskViewSize.width(), taskBarHeight);
     }
 
     /** Gets the top task. */
@@ -301,7 +325,8 @@
             // Notify recents to toggle itself
             Intent intent = new Intent(ACTION_TOGGLE_RECENTS_ACTIVITY);
             intent.setPackage(mContext.getPackageName());
-            intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
+            intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT |
+                    Intent.FLAG_RECEIVER_FOREGROUND);
             mContext.sendBroadcastAsUser(intent, UserHandle.CURRENT);
             mLastToggleTime = System.currentTimeMillis();
             return;
@@ -334,8 +359,13 @@
     /**
      * Creates the activity options for a home->recents transition.
      */
-    ActivityOptions getHomeTransitionActivityOptions() {
+    ActivityOptions getHomeTransitionActivityOptions(boolean fromSearchHome) {
         mStartAnimationTriggered = false;
+        if (fromSearchHome) {
+            return ActivityOptions.makeCustomAnimation(mContext,
+                    R.anim.recents_from_search_launcher_enter,
+                    R.anim.recents_from_search_launcher_exit, mHandler, this);
+        }
         return ActivityOptions.makeCustomAnimation(mContext,
                 R.anim.recents_from_launcher_enter,
                 R.anim.recents_from_launcher_exit, mHandler, this);
@@ -361,27 +391,30 @@
             }
         }
 
-        // If the screenshot fails, then load the first task thumbnail and use that
-        Bitmap firstThumbnail = mSystemServicesProxy.getTaskThumbnail(topTask.id);
-        if (firstThumbnail != null) {
-            // Update the destination rect
-            Rect toTaskRect = getThumbnailTransitionRect(topTask.id, isTopTaskHome);
-            if (toTaskRect.width() > 0 && toTaskRect.height() > 0) {
-                // Create the new thumbnail for the animation down
-                // XXX: We should find a way to optimize this so we don't need to create a new bitmap
-                Bitmap thumbnail = Bitmap.createBitmap(toTaskRect.width(), toTaskRect.height(),
-                        Bitmap.Config.ARGB_8888);
-                int size = Math.min(firstThumbnail.getWidth(), firstThumbnail.getHeight());
+        // Update the destination rect
+        Task toTask = new Task();
+        TaskViewTransform toTransform = getThumbnailTransitionTransform(topTask.id, isTopTaskHome,
+                toTask);
+        if (toTransform != null && toTask.key != null) {
+            Rect toTaskRect = toTransform.rect;
+            int toHeaderWidth = (int) (mHeaderBar.getMeasuredWidth() * toTransform.scale);
+            int toHeaderHeight = (int) (mHeaderBar.getMeasuredHeight() * toTransform.scale);
+            Bitmap thumbnail = Bitmap.createBitmap(toHeaderWidth, toHeaderHeight,
+                    Bitmap.Config.ARGB_8888);
+            if (Constants.DebugFlags.App.EnableTransitionThumbnailDebugMode) {
+                thumbnail.eraseColor(0xFFff0000);
+            } else {
                 Canvas c = new Canvas(thumbnail);
-                c.drawBitmap(firstThumbnail, new Rect(0, 0, size, size),
-                        new Rect(0, 0, toTaskRect.width(), toTaskRect.height()), null);
+                c.scale(toTransform.scale, toTransform.scale);
+                mHeaderBar.rebindToTask(toTask);
+                mHeaderBar.draw(c);
                 c.setBitmap(null);
-                // Recycle the old thumbnail
-                firstThumbnail.recycle();
-                mStartAnimationTriggered = false;
-                return ActivityOptions.makeThumbnailScaleDownAnimation(mStatusBarView,
-                        thumbnail, toTaskRect.left, toTaskRect.top, this);
             }
+
+            mStartAnimationTriggered = false;
+            return ActivityOptions.makeThumbnailAspectScaleDownAnimation(mStatusBarView,
+                    thumbnail, toTaskRect.left, toTaskRect.top, toTaskRect.width(),
+                    toTaskRect.height(), this);
         }
 
         // If both the screenshot and thumbnail fails, then just fall back to the default transition
@@ -389,22 +422,16 @@
     }
 
     /** Returns the transition rect for the given task id. */
-    Rect getThumbnailTransitionRect(int runningTaskId, boolean isTopTaskHome) {
+    TaskViewTransform getThumbnailTransitionTransform(int runningTaskId, boolean isTopTaskHome,
+                                                      Task runningTaskOut) {
         // Get the stack of tasks that we are animating into
-        TaskStack stack = RecentsTaskLoader.getShallowTaskStack(mSystemServicesProxy, -1);
+        RecentsTaskLoader loader = RecentsTaskLoader.getInstance();
+        TaskStack stack = loader.getTaskStack(mSystemServicesProxy, mContext.getResources(),
+                runningTaskId, -1, false, null, null);
         if (stack.getTaskCount() == 0) {
-            return new Rect();
+            return null;
         }
 
-        // Get the stack
-        TaskStackView tsv = new TaskStackView(mContext, stack);
-        TaskStackViewLayoutAlgorithm algo = tsv.getStackAlgorithm();
-        Rect taskStackBounds = new Rect(mTaskStackBounds);
-        taskStackBounds.bottom -= mSystemInsets.bottom;
-        tsv.computeRects(mWindowRect.width(), mWindowRect.height(), taskStackBounds,
-                mTriggeredFromAltTab, isTopTaskHome);
-        tsv.getScroller().setStackScrollToInitialState();
-
         // Find the running task in the TaskStack
         Task task = null;
         ArrayList<Task> tasks = stack.getTasks();
@@ -415,6 +442,7 @@
                 Task t = tasks.get(i);
                 if (t.key.id == runningTaskId) {
                     task = t;
+                    runningTaskOut.copyFrom(t);
                     break;
                 }
             }
@@ -425,8 +453,11 @@
         }
 
         // Get the transform for the running task
-        mTmpTransform = algo.getStackTransform(task, tsv.getScroller().getStackScroll(), mTmpTransform, null);
-        return new Rect(mTmpTransform.rect);
+        mDummyStackView.updateMinMaxScrollForStack(stack, mTriggeredFromAltTab, isTopTaskHome);
+        mDummyStackView.getScroller().setStackScrollToInitialState();
+        mTmpTransform = mDummyStackView.getStackAlgorithm().getStackTransform(task,
+                mDummyStackView.getScroller().getStackScroll(), mTmpTransform, null);
+        return mTmpTransform;
     }
 
     /** Starts the recents activity */
@@ -460,8 +491,30 @@
             // If there is no thumbnail transition, but is launching from home into recents, then
             // use a quick home transition and do the animation from home
             if (hasRecentTasks) {
-                ActivityOptions opts = getHomeTransitionActivityOptions();
-                startAlternateRecentsActivity(topTask, opts, EXTRA_FROM_HOME);
+                // Get the home activity info
+                String homeActivityPackage = mSystemServicesProxy.getHomeActivityPackageName();
+                // Get the search widget info
+                AppWidgetProviderInfo searchWidget = null;
+                String searchWidgetPackage = null;
+                if (mConfig.hasSearchBarAppWidget()) {
+                    searchWidget = mSystemServicesProxy.getAppWidgetInfo(
+                            mConfig.searchBarAppWidgetId);
+                } else {
+                    searchWidget = mSystemServicesProxy.resolveSearchAppWidget();
+                }
+                if (searchWidget != null && searchWidget.provider != null) {
+                    searchWidgetPackage = searchWidget.provider.getPackageName();
+                }
+                // Determine whether we are coming from a search owned home activity
+                boolean fromSearchHome = false;
+                if (homeActivityPackage != null && searchWidgetPackage != null &&
+                        homeActivityPackage.equals(searchWidgetPackage)) {
+                    fromSearchHome = true;
+                }
+
+                ActivityOptions opts = getHomeTransitionActivityOptions(fromSearchHome);
+                startAlternateRecentsActivity(topTask, opts,
+                        fromSearchHome ? EXTRA_FROM_SEARCH_HOME : EXTRA_FROM_HOME);
             } else {
                 // Otherwise we do the normal fade from an unknown source
                 ActivityOptions opts = getUnknownTransitionActivityOptions();
@@ -522,11 +575,35 @@
     public void onAnimationStarted() {
         // Notify recents to start the enter animation
         if (!mStartAnimationTriggered) {
+            // There can be a race condition between the start animation callback and
+            // the start of the new activity (where we register the receiver that listens
+            // to this broadcast, so we add our own receiver and if that gets called, then
+            // we know the activity has not yet started and we can retry sending the broadcast.
+            BroadcastReceiver fallbackReceiver = new BroadcastReceiver() {
+                @Override
+                public void onReceive(Context context, Intent intent) {
+                    if (getResultCode() == Activity.RESULT_OK) {
+                        mStartAnimationTriggered = true;
+                        return;
+                    }
+
+                    // Schedule for the broadcast to be sent again after some time
+                    mHandler.postDelayed(new Runnable() {
+                        @Override
+                        public void run() {
+                            onAnimationStarted();
+                        }
+                    }, 75);
+                }
+            };
+
+            // Send the broadcast to notify Recents that the animation has started
             Intent intent = new Intent(ACTION_START_ENTER_ANIMATION);
             intent.setPackage(mContext.getPackageName());
-            intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
-            mContext.sendBroadcastAsUser(intent, UserHandle.CURRENT);
-            mStartAnimationTriggered = true;
+            intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT |
+                    Intent.FLAG_RECEIVER_FOREGROUND);
+            mContext.sendOrderedBroadcastAsUser(intent, UserHandle.CURRENT, null,
+                    fallbackReceiver, null, Activity.RESULT_CANCELED, null, null);
         }
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/Constants.java b/packages/SystemUI/src/com/android/systemui/recents/Constants.java
index 3709c43..103f96f 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/Constants.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/Constants.java
@@ -27,18 +27,18 @@
         public static class App {
             // Enables the screenshot app->Recents transition
             public static final boolean EnableScreenshotAppTransition = false;
+            // Enables debug drawing for the transition thumbnail
+            public static final boolean EnableTransitionThumbnailDebugMode = false;
             // Enables the filtering of tasks according to their grouping
             public static final boolean EnableTaskFiltering = false;
             // Enables clipping of tasks against each other
-            public static final boolean EnableTaskStackClipping = false;
+            public static final boolean EnableTaskStackClipping = true;
             // Enables tapping on the TaskBar to launch the task
             public static final boolean EnableTaskBarTouchEvents = true;
             // Enables app-info pane on long-pressing the icon
             public static final boolean EnableDevAppInfoOnLongPress = true;
             // Enables the search bar layout
             public static final boolean EnableSearchLayout = true;
-            // Enables the dynamic shadows behind each task
-            public static final boolean EnableShadows = true;
             // Enables the thumbnail alpha on the front-most task
             public static final boolean EnableThumbnailAlphaOnFrontmost = false;
             // This disables the bitmap and icon caches
@@ -66,7 +66,7 @@
 
         public static class RecentsTaskLoader {
             // XXX: This should be calculated on the first load
-            public static final int PreloadFirstTasksCount = 5;
+            public static final int PreloadFirstTasksCount = 6;
         }
 
         public static class TaskStackView {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java
index 7fafe7a..8f92027 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsActivity.java
@@ -107,9 +107,9 @@
             // Finish Recents
             if (mLaunchIntent != null) {
                 if (mLaunchOpts != null) {
-                    startActivityAsUser(mLaunchIntent, UserHandle.CURRENT);
-                } else {
                     startActivityAsUser(mLaunchIntent, mLaunchOpts.toBundle(), UserHandle.CURRENT);
+                } else {
+                    startActivityAsUser(mLaunchIntent, UserHandle.CURRENT);
                 }
             } else {
                 finish();
@@ -146,6 +146,9 @@
                 ReferenceCountedTrigger t = new ReferenceCountedTrigger(context, null, null, null);
                 mRecentsView.startEnterRecentsAnimation(new ViewAnimation.TaskViewEnterContext(t));
                 onEnterAnimationTriggered();
+                // Notify the fallback receiver that we have successfully got the broadcast
+                // See AlternateRecentsComponent.onAnimationStarted()
+                setResultCode(Activity.RESULT_OK);
             }
         }
     };
@@ -188,7 +191,9 @@
         }
 
         // Update the configuration based on the launch intent
-        mConfig.launchedFromHome = launchIntent.getBooleanExtra(
+        boolean fromSearchHome = launchIntent.getBooleanExtra(
+                AlternateRecentsComponent.EXTRA_FROM_SEARCH_HOME, false);
+        mConfig.launchedFromHome = fromSearchHome || launchIntent.getBooleanExtra(
                 AlternateRecentsComponent.EXTRA_FROM_HOME, false);
         mConfig.launchedFromAppWithThumbnail = launchIntent.getBooleanExtra(
                 AlternateRecentsComponent.EXTRA_FROM_APP_THUMBNAIL, false);
@@ -200,6 +205,18 @@
                 AlternateRecentsComponent.EXTRA_TRIGGERED_FROM_ALT_TAB, false);
         mConfig.launchedWithNoRecentTasks = !root.hasTasks();
 
+        // Create the home intent runnable
+        Intent homeIntent = new Intent(Intent.ACTION_MAIN, null);
+        homeIntent.addCategory(Intent.CATEGORY_HOME);
+        homeIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK |
+                Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED);
+        mFinishLaunchHomeRunnable = new FinishRecentsRunnable(homeIntent,
+            ActivityOptions.makeCustomAnimation(this,
+                fromSearchHome ? R.anim.recents_to_search_launcher_enter :
+                        R.anim.recents_to_launcher_enter,
+                fromSearchHome ? R.anim.recents_to_search_launcher_exit :
+                        R.anim.recents_to_launcher_exit));
+
         // Mark the task that is the launch target
         int taskStackCount = stacks.size();
         if (mConfig.launchedToTaskId != -1) {
@@ -282,7 +299,7 @@
                         mSearchAppWidgetInfo);
                 Bundle opts = new Bundle();
                 opts.putInt(AppWidgetManager.OPTION_APPWIDGET_HOST_CATEGORY,
-                        AppWidgetProviderInfo.WIDGET_CATEGORY_RECENTS);
+                        AppWidgetProviderInfo.WIDGET_CATEGORY_SEARCHBOX);
                 mSearchAppWidgetHostView.updateAppWidgetOptions(opts);
                 // Set the padding to 0 for this search widget
                 mSearchAppWidgetHostView.setPadding(0, 0, 0, 0);
@@ -341,21 +358,13 @@
     @Override
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
+        // For the non-primary user, ensure that the SystemSericesProxy is initialized
+        RecentsTaskLoader.initialize(this);
 
         // Initialize the loader and the configuration
-        RecentsTaskLoader.initialize(this);
         mConfig = RecentsConfiguration.reinitialize(this,
                 RecentsTaskLoader.getInstance().getSystemServicesProxy());
 
-        // Create the home intent runnable
-        Intent homeIntent = new Intent(Intent.ACTION_MAIN, null);
-        homeIntent.addCategory(Intent.CATEGORY_HOME);
-        homeIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK |
-                            Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED);
-        mFinishLaunchHomeRunnable = new FinishRecentsRunnable(homeIntent,
-                ActivityOptions.makeCustomAnimation(this, R.anim.recents_to_launcher_enter,
-                        R.anim.recents_to_launcher_exit));
-
         // Initialize the widget host (the host id is static and does not change)
         mAppWidgetHost = new RecentsAppWidgetHost(this, Constants.Values.App.AppWidgetHostId);
 
@@ -384,7 +393,6 @@
 
         // Private API calls to make the shadows look better
         try {
-            Utilities.setShadowProperty("ambientShadowStrength", String.valueOf(35f));
             Utilities.setShadowProperty("ambientRatio", String.valueOf(1.5f));
         } catch (IllegalAccessException e) {
             e.printStackTrace();
diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
index b7f6451..4696c82 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
@@ -16,6 +16,7 @@
 
 package com.android.systemui.recents;
 
+import android.app.ActivityManager;
 import android.content.Context;
 import android.content.SharedPreferences;
 import android.content.res.Configuration;
@@ -56,7 +57,8 @@
 
     /** Layout */
     boolean isLandscape;
-    boolean transposeRecentsLayoutWithOrientation;
+    boolean hasTransposedSearchBar;
+    boolean hasTransposedNavBar;
 
     /** Loading */
     public int maxNumTasksToLoad;
@@ -66,13 +68,17 @@
     public int searchBarSpaceHeightPx;
 
     /** Task stack */
+    public int taskStackScrollDuration;
     public int taskStackMaxDim;
     public int taskStackTopPaddingPx;
     public float taskStackWidthPaddingPct;
+    public float taskStackOverscrollPct;
 
     /** Task view animation and styles */
-    public int taskViewEnterFromHomeDuration;
     public int taskViewEnterFromHomeDelay;
+    public int taskViewEnterFromHomeDuration;
+    public int taskViewEnterFromHomeStaggerDelay;
+    public int taskViewEnterFromHomeStaggerDuration;
     public int taskViewExitToHomeDuration;
     public int taskViewRemoveAnimDuration;
     public int taskViewRemoveAnimTranslationXPx;
@@ -114,7 +120,9 @@
     public int launchedToTaskId;
 
     /** Misc **/
+    public boolean useHardwareLayers;
     public int altTabKeyDelay;
+    public boolean fakeShadows;
 
     /** Dev options and global settings */
     public boolean lockToAppEnabled;
@@ -170,8 +178,8 @@
 
         // Layout
         isLandscape = res.getConfiguration().orientation == Configuration.ORIENTATION_LANDSCAPE;
-        transposeRecentsLayoutWithOrientation =
-                res.getBoolean(R.bool.recents_transpose_layout_with_orientation);
+        hasTransposedSearchBar = res.getBoolean(R.bool.recents_has_transposed_search_bar);
+        hasTransposedNavBar = res.getBoolean(R.bool.recents_has_transposed_nav_bar);
 
         // Insets
         displayRect.set(0, 0, dm.widthPixels, dm.heightPixels);
@@ -187,24 +195,33 @@
                 res.getInteger(R.integer.recents_filter_animate_new_views_duration);
 
         // Loading
-        maxNumTasksToLoad = res.getInteger(R.integer.recents_max_num_tasks_to_load);
+        maxNumTasksToLoad = ActivityManager.getMaxRecentTasksStatic();
 
         // Search Bar
         searchBarSpaceHeightPx = res.getDimensionPixelSize(R.dimen.recents_search_bar_space_height);
         searchBarAppWidgetId = settings.getInt(Constants.Values.App.Key_SearchAppWidgetId, -1);
 
         // Task stack
+        taskStackScrollDuration =
+                res.getInteger(R.integer.recents_animate_task_stack_scroll_duration);
         TypedValue widthPaddingPctValue = new TypedValue();
         res.getValue(R.dimen.recents_stack_width_padding_percentage, widthPaddingPctValue, true);
         taskStackWidthPaddingPct = widthPaddingPctValue.getFloat();
+        TypedValue stackOverscrollPctValue = new TypedValue();
+        res.getValue(R.dimen.recents_stack_overscroll_percentage, stackOverscrollPctValue, true);
+        taskStackOverscrollPct = stackOverscrollPctValue.getFloat();
         taskStackMaxDim = res.getInteger(R.integer.recents_max_task_stack_view_dim);
         taskStackTopPaddingPx = res.getDimensionPixelSize(R.dimen.recents_stack_top_padding);
 
         // Task view animation and styles
-        taskViewEnterFromHomeDuration =
-                res.getInteger(R.integer.recents_animate_task_enter_from_home_duration);
         taskViewEnterFromHomeDelay =
                 res.getInteger(R.integer.recents_animate_task_enter_from_home_delay);
+        taskViewEnterFromHomeDuration =
+                res.getInteger(R.integer.recents_animate_task_enter_from_home_duration);
+        taskViewEnterFromHomeStaggerDelay =
+                res.getInteger(R.integer.recents_animate_task_enter_from_home_stagger_delay);
+        taskViewEnterFromHomeStaggerDuration =
+                res.getInteger(R.integer.recents_animate_task_enter_from_home_stagger_duration);
         taskViewExitToHomeDuration =
                 res.getInteger(R.integer.recents_animate_task_exit_to_home_duration);
         taskViewRemoveAnimDuration =
@@ -259,7 +276,9 @@
                 res.getInteger(R.integer.recents_nav_bar_scrim_enter_duration);
 
         // Misc
+        useHardwareLayers = res.getBoolean(R.bool.config_recents_use_hardware_layers);
         altTabKeyDelay = res.getInteger(R.integer.recents_alt_tab_key_delay);
+        fakeShadows = res.getBoolean(R.bool.config_recents_fake_shadows);
     }
 
     /** Updates the system insets */
@@ -318,13 +337,12 @@
     /** Returns whether the nav bar scrim should be visible. */
     public boolean hasNavBarScrim() {
         // Only show the scrim if we have recent tasks, and if the nav bar is not transposed
-        return !launchedWithNoRecentTasks &&
-                (!transposeRecentsLayoutWithOrientation || !isLandscape);
+        return !launchedWithNoRecentTasks && (!hasTransposedNavBar || !isLandscape);
     }
 
     /** Returns whether the current layout is horizontal. */
     public boolean hasHorizontalLayout() {
-        return isLandscape && transposeRecentsLayoutWithOrientation;
+        return isLandscape && hasTransposedSearchBar;
     }
 
     /**
@@ -335,9 +353,9 @@
                                    Rect taskStackBounds) {
         Rect searchBarBounds = new Rect();
         getSearchBarBounds(windowWidth, windowHeight, topInset, searchBarBounds);
-        if (isLandscape && transposeRecentsLayoutWithOrientation) {
-            // In landscape, the search bar appears on the left
-            taskStackBounds.set(searchBarBounds.right, topInset, windowWidth - rightInset, windowHeight);
+        if (isLandscape && hasTransposedSearchBar) {
+            // In landscape, the search bar appears on the left, but we overlay it on top
+            taskStackBounds.set(0, topInset, windowWidth - rightInset, windowHeight);
         } else {
             // In portrait, the search bar appears on the top (which already has the inset)
             taskStackBounds.set(0, searchBarBounds.bottom, windowWidth, windowHeight);
@@ -356,7 +374,7 @@
             searchBarSize = 0;
         }
 
-        if (isLandscape && transposeRecentsLayoutWithOrientation) {
+        if (isLandscape && hasTransposedSearchBar) {
             // In landscape, the search bar appears on the left
             searchBarSpaceBounds.set(0, topInset, searchBarSize, windowHeight);
         } else {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java
index fb77751..11b7b8b 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java
@@ -32,6 +32,7 @@
 import android.content.pm.ActivityInfo;
 import android.content.pm.IPackageManager;
 import android.content.pm.PackageManager;
+import android.content.pm.ResolveInfo;
 import android.content.res.Resources;
 import android.graphics.Bitmap;
 import android.graphics.BitmapFactory;
@@ -48,7 +49,6 @@
 import android.os.ParcelFileDescriptor;
 import android.os.RemoteException;
 import android.os.UserHandle;
-import android.os.UserManager;
 import android.provider.Settings;
 import android.util.Log;
 import android.util.Pair;
@@ -56,6 +56,7 @@
 import android.view.DisplayInfo;
 import android.view.SurfaceControl;
 import android.view.WindowManager;
+import android.view.accessibility.AccessibilityManager;
 import com.android.systemui.recents.Constants;
 
 import java.io.IOException;
@@ -71,12 +72,14 @@
 public class SystemServicesProxy {
     final static String TAG = "SystemServicesProxy";
 
+    final static BitmapFactory.Options sBitmapOptions;
+
+    AccessibilityManager mAccm;
     ActivityManager mAm;
     IActivityManager mIam;
     AppWidgetManager mAwm;
     PackageManager mPm;
     IPackageManager mIpm;
-    UserManager mUm;
     SearchManager mSm;
     WindowManager mWm;
     Display mDisplay;
@@ -89,13 +92,18 @@
     Paint mBgProtectionPaint;
     Canvas mBgProtectionCanvas;
 
+    static {
+        sBitmapOptions = new BitmapFactory.Options();
+        sBitmapOptions.inMutable = true;
+    }
+
     /** Private constructor */
     public SystemServicesProxy(Context context) {
+        mAccm = AccessibilityManager.getInstance(context);
         mAm = (ActivityManager) context.getSystemService(Context.ACTIVITY_SERVICE);
         mIam = ActivityManagerNative.getDefault();
         mAwm = AppWidgetManager.getInstance(context);
         mPm = context.getPackageManager();
-        mUm = (UserManager) context.getSystemService(Context.USER_SERVICE);
         mIpm = AppGlobals.getPackageManager();
         mSm = (SearchManager) context.getSystemService(Context.SEARCH_SERVICE);
         mWm = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
@@ -167,9 +175,16 @@
         int minNumTasksToQuery = 10;
         int numTasksToQuery = Math.max(minNumTasksToQuery, numLatestTasks);
         List<ActivityManager.RecentTaskInfo> tasks = mAm.getRecentTasksForUser(numTasksToQuery,
+                ActivityManager.RECENT_IGNORE_HOME_STACK_TASKS |
                 ActivityManager.RECENT_IGNORE_UNAVAILABLE |
                 ActivityManager.RECENT_INCLUDE_PROFILES |
                 ActivityManager.RECENT_WITH_EXCLUDED, userId);
+
+        // Break early if we can't get a valid set of tasks
+        if (tasks == null) {
+            return new ArrayList<ActivityManager.RecentTaskInfo>();
+        }
+
         boolean isFirstValidTask = true;
         Iterator<ActivityManager.RecentTaskInfo> iter = tasks.iterator();
         while (iter.hasNext()) {
@@ -178,11 +193,6 @@
             // NOTE: The order of these checks happens in the expected order of the traversal of the
             // tasks
 
-            // Skip tasks from this Recents package
-            if (t.baseIntent.getComponent().getPackageName().equals(mRecentsPackage)) {
-                iter.remove();
-                continue;
-            }
             // Check the first non-recents task, include this task even if it is marked as excluded
             // from recents.  In other words, only remove excluded tasks if it is not the first task
             boolean isExcluded = (t.baseIntent.getFlags() & Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS)
@@ -192,11 +202,6 @@
                 continue;
             }
             isFirstValidTask = false;
-            // Skip tasks in the home stack
-            if (isInHomeStack(t.persistentId)) {
-                iter.remove();
-                continue;
-            }
         }
 
         return tasks.subList(0, Math.min(tasks.size(), numLatestTasks));
@@ -258,7 +263,8 @@
         Bitmap thumbnail = taskThumbnail.mainThumbnail;
         ParcelFileDescriptor descriptor = taskThumbnail.thumbnailFileDescriptor;
         if (thumbnail == null && descriptor != null) {
-            thumbnail = BitmapFactory.decodeFileDescriptor(descriptor.getFileDescriptor());
+            thumbnail = BitmapFactory.decodeFileDescriptor(descriptor.getFileDescriptor(),
+                    null, sBitmapOptions);
         }
         if (descriptor != null) {
             try {
@@ -343,7 +349,7 @@
      * necessary.
      */
     public Drawable getActivityIcon(ActivityInfo info, int userId) {
-        if (mPm == null || mUm == null) return null;
+        if (mPm == null) return null;
 
         // If we are mocking, then return a mock label
         if (Constants.DebugFlags.App.EnableSystemServicesProxy) {
@@ -359,11 +365,48 @@
      */
     public Drawable getBadgedIcon(Drawable icon, int userId) {
         if (userId != UserHandle.myUserId()) {
-            icon = mUm.getBadgedDrawableForUser(icon, new UserHandle(userId));
+            icon = mPm.getUserBadgedIcon(icon, new UserHandle(userId));
         }
         return icon;
     }
 
+    /** Returns the package name of the home activity. */
+    public String getHomeActivityPackageName() {
+        if (mPm == null) return null;
+        if (Constants.DebugFlags.App.EnableSystemServicesProxy) return null;
+
+        ArrayList<ResolveInfo> homeActivities = new ArrayList<ResolveInfo>();
+        ComponentName defaultHomeActivity = mPm.getHomeActivities(homeActivities);
+        if (defaultHomeActivity != null) {
+            return defaultHomeActivity.getPackageName();
+        } else if (homeActivities.size() == 1) {
+            ResolveInfo info = homeActivities.get(0);
+            if (info.activityInfo != null) {
+                return info.activityInfo.packageName;
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Resolves and returns the first Recents widget from the same package as the global
+     * assist activity.
+     */
+    public AppWidgetProviderInfo resolveSearchAppWidget() {
+        if (mAwm == null) return null;
+        if (mAssistComponent == null) return null;
+
+        // Find the first Recents widget from the same package as the global assist activity
+        List<AppWidgetProviderInfo> widgets = mAwm.getInstalledProviders(
+                AppWidgetProviderInfo.WIDGET_CATEGORY_SEARCHBOX);
+        for (AppWidgetProviderInfo info : widgets) {
+            if (info.provider.getPackageName().equals(mAssistComponent.getPackageName())) {
+                return info;
+            }
+        }
+        return null;
+    }
+
     /**
      * Resolves and binds the search app widget that is to appear in the recents.
      */
@@ -372,15 +415,7 @@
         if (mAssistComponent == null) return null;
 
         // Find the first Recents widget from the same package as the global assist activity
-        List<AppWidgetProviderInfo> widgets = mAwm.getInstalledProviders(
-                AppWidgetProviderInfo.WIDGET_CATEGORY_RECENTS);
-        AppWidgetProviderInfo searchWidgetInfo = null;
-        for (AppWidgetProviderInfo info : widgets) {
-            if (info.provider.getPackageName().equals(mAssistComponent.getPackageName())) {
-                searchWidgetInfo = info;
-                break;
-            }
-        }
+        AppWidgetProviderInfo searchWidgetInfo = resolveSearchAppWidget();
 
         // Return early if there is no search widget
         if (searchWidgetInfo == null) return null;
@@ -389,7 +424,7 @@
         int searchWidgetId = host.allocateAppWidgetId();
         Bundle opts = new Bundle();
         opts.putInt(AppWidgetManager.OPTION_APPWIDGET_HOST_CATEGORY,
-                AppWidgetProviderInfo.WIDGET_CATEGORY_RECENTS);
+                AppWidgetProviderInfo.WIDGET_CATEGORY_SEARCHBOX);
         if (!mAwm.bindAppWidgetIdIfAllowed(searchWidgetId, searchWidgetInfo.provider, opts)) {
             return null;
         }
@@ -416,6 +451,15 @@
     }
 
     /**
+     * Returns whether touch exploration is currently enabled.
+     */
+    public boolean isTouchExplorationEnabled() {
+        if (mAccm == null) return false;
+
+        return mAccm.isEnabled() && mAccm.isTouchExplorationEnabled();
+    }
+
+    /**
      * Returns a global setting.
      */
     public int getGlobalSetting(Context context, String setting) {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java b/packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java
index 4c6b389..f01d17c 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/misc/Utilities.java
@@ -18,11 +18,14 @@
 
 import android.content.Intent;
 import android.graphics.Color;
+import android.graphics.Matrix;
 import android.graphics.Rect;
+import android.view.View;
 import com.android.systemui.recents.RecentsConfiguration;
 
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
+import java.util.ArrayList;
 
 /* Common code */
 public class Utilities {
@@ -68,6 +71,80 @@
         }
     }
 
+    /** Maps a coorindate in a descendant view into the parent. */
+    public static float mapCoordInDescendentToSelf(View descendant, View root,
+            float[] coord, boolean includeRootScroll) {
+        ArrayList<View> ancestorChain = new ArrayList<View>();
+
+        float[] pt = {coord[0], coord[1]};
+
+        View v = descendant;
+        while(v != root && v != null) {
+            ancestorChain.add(v);
+            v = (View) v.getParent();
+        }
+        ancestorChain.add(root);
+
+        float scale = 1.0f;
+        int count = ancestorChain.size();
+        for (int i = 0; i < count; i++) {
+            View v0 = ancestorChain.get(i);
+            // For TextViews, scroll has a meaning which relates to the text position
+            // which is very strange... ignore the scroll.
+            if (v0 != descendant || includeRootScroll) {
+                pt[0] -= v0.getScrollX();
+                pt[1] -= v0.getScrollY();
+            }
+
+            v0.getMatrix().mapPoints(pt);
+            pt[0] += v0.getLeft();
+            pt[1] += v0.getTop();
+            scale *= v0.getScaleX();
+        }
+
+        coord[0] = pt[0];
+        coord[1] = pt[1];
+        return scale;
+    }
+
+    /** Maps a coordinate in the root to a descendent. */
+    public static float mapCoordInSelfToDescendent(View descendant, View root,
+            float[] coord, Matrix tmpInverseMatrix) {
+        ArrayList<View> ancestorChain = new ArrayList<View>();
+
+        float[] pt = {coord[0], coord[1]};
+
+        View v = descendant;
+        while(v != root) {
+            ancestorChain.add(v);
+            v = (View) v.getParent();
+        }
+        ancestorChain.add(root);
+
+        float scale = 1.0f;
+        int count = ancestorChain.size();
+        tmpInverseMatrix.set(Matrix.IDENTITY_MATRIX);
+        for (int i = count - 1; i >= 0; i--) {
+            View ancestor = ancestorChain.get(i);
+            View next = i > 0 ? ancestorChain.get(i-1) : null;
+
+            pt[0] += ancestor.getScrollX();
+            pt[1] += ancestor.getScrollY();
+
+            if (next != null) {
+                pt[0] -= next.getLeft();
+                pt[1] -= next.getTop();
+                next.getMatrix().invert(tmpInverseMatrix);
+                tmpInverseMatrix.mapPoints(pt);
+                scale *= next.getScaleX();
+            }
+        }
+
+        coord[0] = pt[0];
+        coord[1] = pt[1];
+        return scale;
+    }
+
     /** Calculates the constrast between two colors, using the algorithm provided by the WCAG v2. */
     public static float computeContrastBetweenColors(int bg, int fg) {
         float bgR = Color.red(bg) / 255f;
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/BitmapLruCache.java b/packages/SystemUI/src/com/android/systemui/recents/model/BitmapLruCache.java
index 757c07f..624a8ff 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/BitmapLruCache.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/BitmapLruCache.java
@@ -25,10 +25,4 @@
     public BitmapLruCache(int cacheSize) {
         super(cacheSize);
     }
-
-    @Override
-    protected int computeSize(Bitmap b) {
-        // The cache size will be measured in kilobytes rather than number of items
-        return b.getAllocationByteCount();
-    }
 }
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/DrawableLruCache.java b/packages/SystemUI/src/com/android/systemui/recents/model/DrawableLruCache.java
index 5b50358..01a515b 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/DrawableLruCache.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/DrawableLruCache.java
@@ -25,12 +25,4 @@
     public DrawableLruCache(int cacheSize) {
         super(cacheSize);
     }
-
-    @Override
-    protected int computeSize(Drawable d) {
-        // The cache size will be measured in kilobytes rather than number of items
-        // NOTE: this isn't actually correct, as the icon may be smaller
-        int maxBytes = (d.getIntrinsicWidth() * d.getIntrinsicHeight() * 4);
-        return maxBytes;
-    }
 }
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/KeyStoreLruCache.java b/packages/SystemUI/src/com/android/systemui/recents/model/KeyStoreLruCache.java
index bb4dc76..7ccefc6 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/KeyStoreLruCache.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/KeyStoreLruCache.java
@@ -34,10 +34,6 @@
 
     public KeyStoreLruCache(int cacheSize) {
         mCache = new LruCache<Integer, V>(cacheSize) {
-            @Override
-            protected int sizeOf(Integer taskId, V v) {
-                return computeSize(v);
-            }
 
             @Override
             protected void entryRemoved(boolean evicted, Integer taskId, V oldV, V newV) {
@@ -46,11 +42,6 @@
         };
     }
 
-    /** Computes the size of a value. */
-    protected int computeSize(V value) {
-        return 0;
-    }
-
     /** Gets a specific entry in the cache. */
     final V get(Task.TaskKey key) {
         return mCache.get(key.id);
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/RecentsPackageMonitor.java b/packages/SystemUI/src/com/android/systemui/recents/model/RecentsPackageMonitor.java
index 31011ae..60e89bf 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/RecentsPackageMonitor.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/RecentsPackageMonitor.java
@@ -16,7 +16,6 @@
 
 package com.android.systemui.recents.model;
 
-import android.app.ActivityManager;
 import android.content.ComponentName;
 import android.content.Context;
 import android.os.Looper;
@@ -36,7 +35,7 @@
     }
 
     PackageCallbacks mCb;
-    List<ActivityManager.RecentTaskInfo> mTasks;
+    List<Task.TaskKey> mTasks;
     SystemServicesProxy mSystemServicesProxy;
 
     /** Registers the broadcast receivers with the specified callbacks. */
@@ -64,7 +63,7 @@
     }
 
     /** Sets the list of tasks to match against package broadcast changes. */
-    void setTasks(List<ActivityManager.RecentTaskInfo> tasks) {
+    void setTasks(List<Task.TaskKey> tasks) {
         mTasks = tasks;
     }
 
@@ -75,7 +74,7 @@
         // Identify all the tasks that should be removed as a result of the package being removed.
         // Using a set to ensure that we callback once per unique component.
         HashSet<ComponentName> componentsToRemove = new HashSet<ComponentName>();
-        for (ActivityManager.RecentTaskInfo t : mTasks) {
+        for (Task.TaskKey t : mTasks) {
             ComponentName cn = t.baseIntent.getComponent();
             if (cn.getPackageName().equals(packageName)) {
                 componentsToRemove.add(cn);
@@ -99,7 +98,7 @@
         // Using a set to ensure that we callback once per unique component.
         HashSet<ComponentName> componentsKnownToExist = new HashSet<ComponentName>();
         HashSet<ComponentName> componentsToRemove = new HashSet<ComponentName>();
-        for (ActivityManager.RecentTaskInfo t : mTasks) {
+        for (Task.TaskKey t : mTasks) {
             ComponentName cn = t.baseIntent.getComponent();
             if (cn.getPackageName().equals(packageName)) {
                 if (componentsKnownToExist.contains(cn)) {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/RecentsTaskLoader.java b/packages/SystemUI/src/com/android/systemui/recents/model/RecentsTaskLoader.java
index 0e2f370..d4b403d 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/RecentsTaskLoader.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/RecentsTaskLoader.java
@@ -27,17 +27,26 @@
 import android.os.Handler;
 import android.os.HandlerThread;
 import android.os.UserHandle;
+import android.util.Log;
+
+import com.android.systemui.R;
 import com.android.systemui.recents.Constants;
 import com.android.systemui.recents.RecentsConfiguration;
 import com.android.systemui.recents.misc.SystemServicesProxy;
 
+import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
-import java.util.LinkedHashSet;
+import java.util.HashMap;
 import java.util.List;
 import java.util.concurrent.ConcurrentLinkedQueue;
 
 
+/** Handle to an ActivityInfo */
+class ActivityInfoHandle {
+    ActivityInfo info;
+}
+
 /** A bitmap load queue */
 class TaskResourceLoadQueue {
     ConcurrentLinkedQueue<Task> mQueue = new ConcurrentLinkedQueue<Task>();
@@ -115,8 +124,8 @@
         mDefaultThumbnail = defaultThumbnail;
         mDefaultApplicationIcon = defaultApplicationIcon;
         mMainThreadHandler = new Handler();
-        mLoadThread = new HandlerThread("Recents-TaskResourceLoader");
-        mLoadThread.setPriority(Thread.NORM_PRIORITY - 1);
+        mLoadThread = new HandlerThread("Recents-TaskResourceLoader",
+                android.os.Process.THREAD_PRIORITY_BACKGROUND);
         mLoadThread.start();
         mLoadThreadHandler = new Handler(mLoadThread.getLooper());
         mLoadThreadHandler.post(this);
@@ -171,9 +180,9 @@
                     // Load the application icon if it is stale or we haven't cached one yet
                     if (cachedIcon == null) {
                         ActivityInfo info = ssp.getActivityInfo(t.key.baseIntent.getComponent(),
-                                t.userId);
+                                t.key.userId);
                         if (info != null) {
-                            cachedIcon = ssp.getActivityIcon(info, t.userId);
+                            cachedIcon = ssp.getActivityIcon(info, t.key.userId);
                         }
                         if (cachedIcon == null) {
                             cachedIcon = mDefaultApplicationIcon;
@@ -195,7 +204,8 @@
                     if (!mCancelled) {
                         // Notify that the task data has changed
                         final Drawable newIcon = cachedIcon;
-                        final Bitmap newThumbnail = cachedThumbnail;
+                        final Bitmap newThumbnail = cachedThumbnail == mDefaultThumbnail
+                                ? null : cachedThumbnail;
                         mMainThreadHandler.post(new Runnable() {
                             @Override
                             public void run() {
@@ -225,11 +235,14 @@
 /* Recents task loader
  * NOTE: We should not hold any references to a Context from a static instance */
 public class RecentsTaskLoader {
+    private static final String TAG = "RecentsTaskLoader";
+
     static RecentsTaskLoader sInstance;
 
     SystemServicesProxy mSystemServicesProxy;
     DrawableLruCache mApplicationIconCache;
     BitmapLruCache mThumbnailCache;
+    StringLruCache mActivityLabelCache;
     TaskResourceLoadQueue mLoadQueue;
     TaskResourceLoader mLoader;
 
@@ -240,16 +253,13 @@
 
     BitmapDrawable mDefaultApplicationIcon;
     Bitmap mDefaultThumbnail;
-    Bitmap mLoadingThumbnail;
 
     /** Private Constructor */
     private RecentsTaskLoader(Context context) {
-        // Calculate the cache sizes, we just use a reasonable number here similar to those
-        // suggested in the Android docs, 1/6th for the thumbnail cache and 1/30 of the max memory
-        // for icons.
-        int maxMemory = (int) Runtime.getRuntime().maxMemory();
-        mMaxThumbnailCacheSize = maxMemory / 6;
-        mMaxIconCacheSize = mMaxThumbnailCacheSize / 5;
+        mMaxThumbnailCacheSize = context.getResources().getInteger(
+                R.integer.config_recents_max_thumbnail_count);
+        mMaxIconCacheSize = context.getResources().getInteger(
+                R.integer.config_recents_max_icon_count);
         int iconCacheSize = Constants.DebugFlags.App.DisableBackgroundCache ? 1 :
                 mMaxIconCacheSize;
         int thumbnailCacheSize = Constants.DebugFlags.App.DisableBackgroundCache ? 1 :
@@ -261,9 +271,6 @@
         mDefaultThumbnail = Bitmap.createBitmap(1, 1, Bitmap.Config.ARGB_8888);
         mDefaultThumbnail.setHasAlpha(false);
         mDefaultThumbnail.eraseColor(0xFFffffff);
-        mLoadingThumbnail = Bitmap.createBitmap(1, 1, Bitmap.Config.ARGB_8888);
-        mLoadingThumbnail.setHasAlpha(false);
-        mLoadingThumbnail.eraseColor(0xFFffffff);
         mDefaultApplicationIcon = new BitmapDrawable(context.getResources(), icon);
 
         // Initialize the proxy, cache and loaders
@@ -272,6 +279,7 @@
         mLoadQueue = new TaskResourceLoadQueue();
         mApplicationIconCache = new DrawableLruCache(iconCacheSize);
         mThumbnailCache = new BitmapLruCache(thumbnailCacheSize);
+        mActivityLabelCache = new StringLruCache(100);
         mLoader = new TaskResourceLoader(mLoadQueue, mApplicationIconCache, mThumbnailCache,
                 mDefaultThumbnail, mDefaultApplicationIcon);
     }
@@ -295,127 +303,187 @@
     }
 
     /** Gets the list of recent tasks, ordered from back to front. */
-    private static List<ActivityManager.RecentTaskInfo> getRecentTasks(SystemServicesProxy ssp,
-            int numTasks) {
-        // Set a default number of tasks to query if none is provided
-        if (numTasks < 0) {
-            RecentsConfiguration config = RecentsConfiguration.getInstance();
-            numTasks = config.maxNumTasksToLoad;
-        }
+    private static List<ActivityManager.RecentTaskInfo> getRecentTasks(SystemServicesProxy ssp) {
+        RecentsConfiguration config = RecentsConfiguration.getInstance();
         List<ActivityManager.RecentTaskInfo> tasks =
-                ssp.getRecentTasks(numTasks, UserHandle.CURRENT.getIdentifier());
+                ssp.getRecentTasks(config.maxNumTasksToLoad,
+                        UserHandle.CURRENT.getIdentifier());
         Collections.reverse(tasks);
         return tasks;
     }
 
+    /** Returns the activity icon using as many cached values as we can. */
+    public Drawable getAndUpdateActivityIcon(Task.TaskKey taskKey,
+             ActivityManager.TaskDescription td, SystemServicesProxy ssp,
+             Resources res, ActivityInfoHandle infoHandle, boolean preloadTask) {
+        // Return the cached activity icon if it exists
+        Drawable icon = mApplicationIconCache.getAndInvalidateIfModified(taskKey);
+        if (icon != null) {
+            return icon;
+        }
+        // Return the task description icon if it exists
+        if (td != null && td.getIcon() != null) {
+            icon = ssp.getBadgedIcon(new BitmapDrawable(res, td.getIcon()), taskKey.userId);
+            mApplicationIconCache.put(taskKey, icon);
+            return icon;
+        }
+        // If we are preloading this task, continue to load the activity icon
+        if (preloadTask) {
+            // All short paths failed, load the icon from the activity info and cache it
+            if (infoHandle.info == null) {
+                infoHandle.info = ssp.getActivityInfo(taskKey.baseIntent.getComponent(),
+                        taskKey.userId);
+            }
+            if (infoHandle.info != null) {
+                icon = ssp.getActivityIcon(infoHandle.info, taskKey.userId);
+                if (icon != null) {
+                    mApplicationIconCache.put(taskKey, icon);
+                    return icon;
+                }
+            }
+        }
+        // If we couldn't load any icon, return null
+        return null;
+    }
+
+    /** Returns the activity label using as many cached values as we can. */
+    public String getAndUpdateActivityLabel(Task.TaskKey taskKey,
+            ActivityManager.TaskDescription td, SystemServicesProxy ssp,
+            ActivityInfoHandle infoHandle) {
+        // Return the task description label if it exists
+        if (td != null && td.getLabel() != null) {
+            return td.getLabel();
+        }
+        // Return the cached activity label if it exists
+        String label = mActivityLabelCache.getAndInvalidateIfModified(taskKey);
+        if (label != null) {
+            return label;
+        }
+        // All short paths failed, load the label from the activity info and cache it
+        if (infoHandle.info == null) {
+            infoHandle.info = ssp.getActivityInfo(taskKey.baseIntent.getComponent(),
+                    taskKey.userId);
+        }
+        if (infoHandle.info != null) {
+            label = ssp.getActivityLabel(infoHandle.info);
+            mActivityLabelCache.put(taskKey, label);
+        } else {
+            Log.w(TAG, "Missing ActivityInfo for " + taskKey.baseIntent.getComponent()
+                    + " u=" + taskKey.userId);
+        }
+        return label;
+    }
+
+    /** Returns the activity's primary color. */
+    public int getActivityPrimaryColor(ActivityManager.TaskDescription td,
+            RecentsConfiguration config) {
+        if (td != null && td.getPrimaryColor() != 0) {
+            return td.getPrimaryColor();
+        }
+        return config.taskBarViewDefaultBackgroundColor;
+    }
+
     /** Reload the set of recent tasks */
     public SpaceNode reload(Context context, int preloadCount) {
-        RecentsConfiguration config = RecentsConfiguration.getInstance();
-        Resources res = context.getResources();
-        LinkedHashSet<Task> tasksToLoad = new LinkedHashSet<Task>();
-        TaskStack stack = new TaskStack();
+        ArrayList<Task.TaskKey> taskKeys = new ArrayList<Task.TaskKey>();
+        ArrayList<Task> tasksToLoad = new ArrayList<Task>();
+        TaskStack stack = getTaskStack(mSystemServicesProxy, context.getResources(),
+                -1, preloadCount, true, taskKeys, tasksToLoad);
         SpaceNode root = new SpaceNode();
         root.setStack(stack);
 
-        // Get the recent tasks
-        SystemServicesProxy ssp = mSystemServicesProxy;
-        List<ActivityManager.RecentTaskInfo> tasks = getRecentTasks(ssp, -1);
-
-        // From back to front, add each task to the task stack
-        int taskCount = tasks.size();
-        for (int i = 0; i < taskCount; i++) {
-            ActivityManager.RecentTaskInfo t = tasks.get(i);
-            ActivityInfo info = ssp.getActivityInfo(t.baseIntent.getComponent(), t.userId);
-            if (info == null) continue;
-
-            ActivityManager.TaskDescription av = t.taskDescription;
-            String activityLabel = null;
-            Drawable activityIcon = mDefaultApplicationIcon;
-            int activityColor = config.taskBarViewDefaultBackgroundColor;
-            if (av != null) {
-                activityLabel = (av.getLabel() != null ? av.getLabel() : ssp.getActivityLabel(info));
-                activityIcon = (av.getIcon() != null) ?
-                        ssp.getBadgedIcon(new BitmapDrawable(res, av.getIcon()), t.userId) : null;
-                if (av.getPrimaryColor() != 0) {
-                    activityColor = av.getPrimaryColor();
-                }
-            } else {
-                activityLabel = ssp.getActivityLabel(info);
-            }
-
-            // Create a new task
-            Task task = new Task(t.persistentId, (t.id > -1), t.baseIntent, t.affiliatedTaskId,
-                    t.affiliatedTaskColor, activityLabel, activityIcon, activityColor, t.userId,
-                    t.firstActiveTime, t.lastActiveTime, (i == (taskCount - 1)),
-                    config.lockToAppEnabled);
-
-            // Preload the specified number of apps
-            if (i >= (taskCount - preloadCount)) {
-                // Load the icon from the cache if possible
-                task.applicationIcon = mApplicationIconCache.getAndInvalidateIfModified(task.key);
-                if (task.applicationIcon == null) {
-                    // Load the icon from the system
-                    task.applicationIcon = ssp.getActivityIcon(info, task.userId);
-                    if (task.applicationIcon != null) {
-                        mApplicationIconCache.put(task.key, task.applicationIcon);
-                    }
-                }
-                if (task.applicationIcon == null) {
-                    // Either the task has changed since the last active time, or it was not
-                    // previously cached, so try and load the task anew.
-                    tasksToLoad.add(task);
-                }
-
-                // Load the thumbnail from the cache if possible
-                task.thumbnail = mThumbnailCache.getAndInvalidateIfModified(task.key);
-                if (task.thumbnail == null) {
-                    // Load the thumbnail from the system
-                    task.thumbnail = ssp.getTaskThumbnail(task.key.id);
-                    if (task.thumbnail != null) {
-                        task.thumbnail.setHasAlpha(false);
-                        mThumbnailCache.put(task.key, task.thumbnail);
-                    }
-                }
-                if (task.thumbnail == null) {
-                    // Either the task has changed since the last active time, or it was not
-                    // previously cached, so try and load the task anew.
-                    tasksToLoad.add(task);
-                }
-            }
-
-            // Add the task to the stack
-            stack.addTask(task);
-        }
-
-        // Simulate the groupings that we describe
-        stack.createAffiliatedGroupings(config);
-
         // Start the task loader and add all the tasks we need to load
         mLoader.start(context);
         mLoadQueue.addTasks(tasksToLoad);
 
         // Update the package monitor with the list of packages to listen for
-        mPackageMonitor.setTasks(tasks);
+        mPackageMonitor.setTasks(taskKeys);
 
         return root;
     }
 
     /** Creates a lightweight stack of the current recent tasks, without thumbnails and icons. */
-    public static TaskStack getShallowTaskStack(SystemServicesProxy ssp, int numTasks) {
+    public TaskStack getTaskStack(SystemServicesProxy ssp, Resources res,
+            int preloadTaskId, int preloadTaskCount,
+            boolean loadTaskThumbnails, List<Task.TaskKey> taskKeysOut,
+            List<Task> tasksToLoadOut) {
         RecentsConfiguration config = RecentsConfiguration.getInstance();
-        List<ActivityManager.RecentTaskInfo> tasks = getRecentTasks(ssp, numTasks);
+        List<ActivityManager.RecentTaskInfo> tasks = getRecentTasks(ssp);
+        HashMap<Task.ComponentNameKey, ActivityInfoHandle> activityInfoCache =
+                new HashMap<Task.ComponentNameKey, ActivityInfoHandle>();
+        ArrayList<Task> tasksToAdd = new ArrayList<Task>();
         TaskStack stack = new TaskStack();
 
         int taskCount = tasks.size();
         for (int i = 0; i < taskCount; i++) {
             ActivityManager.RecentTaskInfo t = tasks.get(i);
-            ActivityInfo info = ssp.getActivityInfo(t.baseIntent.getComponent(), t.userId);
-            if (info == null) continue;
 
-            stack.addTask(new Task(t.persistentId, true, t.baseIntent, t.affiliatedTaskId,
-                    t.affiliatedTaskColor, null, null, 0, 0, t.firstActiveTime, t.lastActiveTime,
-                    (i == (taskCount - 1)), config.lockToAppEnabled));
+            // Compose the task key
+            Task.TaskKey taskKey = new Task.TaskKey(t.persistentId, t.baseIntent, t.userId,
+                    t.firstActiveTime, t.lastActiveTime);
+
+            // Get an existing activity info handle if possible
+            Task.ComponentNameKey cnKey = taskKey.getComponentNameKey();
+            ActivityInfoHandle infoHandle;
+            boolean hasCachedActivityInfo = false;
+            if (activityInfoCache.containsKey(cnKey)) {
+                infoHandle = activityInfoCache.get(cnKey);
+                hasCachedActivityInfo = true;
+            } else {
+                infoHandle = new ActivityInfoHandle();
+            }
+
+            // Determine whether to preload this task
+            boolean preloadTask = false;
+            if (preloadTaskId > 0) {
+                preloadTask = (t.id == preloadTaskId);
+            } else if (preloadTaskCount > 0) {
+                preloadTask = (i >= (taskCount - preloadTaskCount));
+            }
+
+            // Load the label, icon, and color
+            String activityLabel  = getAndUpdateActivityLabel(taskKey, t.taskDescription,
+                    ssp, infoHandle);
+            Drawable activityIcon = getAndUpdateActivityIcon(taskKey, t.taskDescription,
+                    ssp, res, infoHandle, preloadTask);
+            int activityColor = getActivityPrimaryColor(t.taskDescription, config);
+
+            // Update the activity info cache
+            if (!hasCachedActivityInfo && infoHandle.info != null) {
+                activityInfoCache.put(cnKey, infoHandle);
+            }
+
+            // Add the task to the stack
+            Task task = new Task(taskKey, (t.id > -1), t.affiliatedTaskId, t.affiliatedTaskColor,
+                    activityLabel, activityIcon, activityColor, (i == (taskCount - 1)),
+                    config.lockToAppEnabled);
+
+            if (preloadTask && loadTaskThumbnails) {
+                // Load the thumbnail from the cache if possible
+                task.thumbnail = mThumbnailCache.getAndInvalidateIfModified(taskKey);
+                if (task.thumbnail == null) {
+                    // Load the thumbnail from the system
+                    task.thumbnail = ssp.getTaskThumbnail(taskKey.id);
+                    if (task.thumbnail != null) {
+                        task.thumbnail.setHasAlpha(false);
+                        mThumbnailCache.put(taskKey, task.thumbnail);
+                    }
+                }
+                if (task.thumbnail == null && tasksToLoadOut != null) {
+                    // Either the task has changed since the last active time, or it was not
+                    // previously cached, so try and load the task anew.
+                    tasksToLoadOut.add(task);
+                }
+            }
+
+            // Add to the list of task keys
+            if (taskKeysOut != null) {
+                taskKeysOut.add(taskKey);
+            }
+            // Add the task to the stack
+            tasksToAdd.add(task);
         }
+        stack.setTasks(tasksToAdd);
         stack.createAffiliatedGroupings(config);
         return stack;
     }
@@ -429,17 +497,16 @@
         // use the default assets in their place until they load
         boolean requiresLoad = (applicationIcon == null) || (thumbnail == null);
         applicationIcon = applicationIcon != null ? applicationIcon : mDefaultApplicationIcon;
-        thumbnail = thumbnail != null ? thumbnail : mDefaultThumbnail;
         if (requiresLoad) {
             mLoadQueue.addTask(t);
         }
-        t.notifyTaskDataLoaded(thumbnail, applicationIcon);
+        t.notifyTaskDataLoaded(thumbnail == mDefaultThumbnail ? null : thumbnail, applicationIcon);
     }
 
     /** Releases the task resource data back into the pool. */
     public void unloadTaskData(Task t) {
         mLoadQueue.removeTask(t);
-        t.notifyTaskDataUnloaded(mDefaultThumbnail, mDefaultApplicationIcon);
+        t.notifyTaskDataUnloaded(null, mDefaultApplicationIcon);
     }
 
     /** Completely removes the resource data from the pool. */
@@ -448,7 +515,7 @@
         mThumbnailCache.remove(t.key);
         mApplicationIconCache.remove(t.key);
         if (notifyTaskDataUnloaded) {
-            t.notifyTaskDataUnloaded(mDefaultThumbnail, mDefaultApplicationIcon);
+            t.notifyTaskDataUnloaded(null, mDefaultApplicationIcon);
         }
     }
 
@@ -478,6 +545,12 @@
             case ComponentCallbacks2.TRIM_MEMORY_UI_HIDDEN:
                 // Stop the loader immediately when the UI is no longer visible
                 stopLoader();
+                mThumbnailCache.trimToSize(Math.max(
+                        Constants.Values.RecentsTaskLoader.PreloadFirstTasksCount,
+                        mMaxThumbnailCacheSize / 2));
+                mApplicationIconCache.trimToSize(Math.max(
+                        Constants.Values.RecentsTaskLoader.PreloadFirstTasksCount,
+                        mMaxIconCacheSize / 2));
                 break;
             case ComponentCallbacks2.TRIM_MEMORY_RUNNING_MODERATE:
             case ComponentCallbacks2.TRIM_MEMORY_BACKGROUND:
@@ -496,6 +569,8 @@
                 // We are low on memory, so release everything
                 mThumbnailCache.evictAll();
                 mApplicationIconCache.evictAll();
+                // The cache is small, only clear the label cache when we are critical
+                mActivityLabelCache.evictAll();
                 break;
             default:
                 break;
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/StringLruCache.java b/packages/SystemUI/src/com/android/systemui/recents/model/StringLruCache.java
new file mode 100644
index 0000000..6769716
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/StringLruCache.java
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2014 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.systemui.recents.model;
+
+/**
+ * The String LRU cache.
+ */
+class StringLruCache extends KeyStoreLruCache<String> {
+    public StringLruCache(int cacheSize) {
+        super(cacheSize);
+    }
+}
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/Task.java b/packages/SystemUI/src/com/android/systemui/recents/model/Task.java
index f6c3a7e..406e03f 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/Task.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/Task.java
@@ -16,12 +16,15 @@
 
 package com.android.systemui.recents.model;
 
+import android.content.ComponentName;
 import android.content.Intent;
 import android.graphics.Bitmap;
 import android.graphics.Color;
 import android.graphics.drawable.Drawable;
 import com.android.systemui.recents.misc.Utilities;
 
+import java.util.Objects;
+
 
 /**
  * A task represents the top most task in the system's task stack.
@@ -35,8 +38,35 @@
         public void onTaskDataUnloaded();
     }
 
+    /** The ComponentNameKey represents the unique primary key for a component
+     * belonging to a specified user. */
+    public static class ComponentNameKey {
+        final ComponentName component;
+        final int userId;
+
+        public ComponentNameKey(ComponentName cn, int user) {
+            component = cn;
+            userId = user;
+        }
+
+        @Override
+        public int hashCode() {
+            return Objects.hash(component, userId);
+        }
+
+        @Override
+        public boolean equals(Object o) {
+            if (!(o instanceof ComponentNameKey)) {
+                return false;
+            }
+            return component.equals(((ComponentNameKey) o).component) &&
+                    userId == ((ComponentNameKey) o).userId;
+        }
+    }
+
     /* The Task Key represents the unique primary key for the task */
     public static class TaskKey {
+        final ComponentNameKey mComponentNameKey;
         public final int id;
         public final Intent baseIntent;
         public final int userId;
@@ -44,6 +74,7 @@
         public long lastActiveTime;
 
         public TaskKey(int id, Intent intent, int userId, long firstActiveTime, long lastActiveTime) {
+            mComponentNameKey = new ComponentNameKey(intent.getComponent(), userId);
             this.id = id;
             this.baseIntent = intent;
             this.userId = userId;
@@ -51,6 +82,11 @@
             this.lastActiveTime = lastActiveTime;
         }
 
+        /** Returns the component name key for this task. */
+        public ComponentNameKey getComponentNameKey() {
+            return mComponentNameKey;
+        }
+
         @Override
         public boolean equals(Object o) {
             if (!(o instanceof TaskKey)) {
@@ -88,7 +124,6 @@
     public boolean isActive;
     public boolean lockToThisTask;
     public boolean lockToTaskEnabled;
-    public int userId;
 
     TaskCallbacks mCb;
 
@@ -96,13 +131,12 @@
         // Only used by RecentsService for task rect calculations.
     }
 
-    public Task(int id, boolean isActive, Intent intent, int taskAffiliation, int taskAffiliationColor,
-                String activityTitle, Drawable activityIcon, int colorPrimary, int userId,
-                long firstActiveTime, long lastActiveTime, boolean lockToThisTask,
-                boolean lockToTaskEnabled) {
-        boolean isInAffiliationGroup = (taskAffiliation != id);
+    public Task(TaskKey key, boolean isActive, int taskAffiliation, int taskAffiliationColor,
+                String activityTitle, Drawable activityIcon, int colorPrimary,
+                boolean lockToThisTask, boolean lockToTaskEnabled) {
+        boolean isInAffiliationGroup = (taskAffiliation != key.id);
         boolean hasAffiliationGroupColor = isInAffiliationGroup && (taskAffiliationColor != 0);
-        this.key = new TaskKey(id, intent, userId, firstActiveTime, lastActiveTime);
+        this.key = key;
         this.taskAffiliation = taskAffiliation;
         this.taskAffiliationColor = taskAffiliationColor;
         this.activityLabel = activityTitle;
@@ -113,7 +147,20 @@
         this.isActive = isActive;
         this.lockToThisTask = lockToTaskEnabled && lockToThisTask;
         this.lockToTaskEnabled = lockToTaskEnabled;
-        this.userId = userId;
+    }
+
+    /** Copies the other task. */
+    public void copyFrom(Task o) {
+        this.key = o.key;
+        this.taskAffiliation = o.taskAffiliation;
+        this.taskAffiliationColor = o.taskAffiliationColor;
+        this.activityLabel = o.activityLabel;
+        this.activityIcon = o.activityIcon;
+        this.colorPrimary = o.colorPrimary;
+        this.useLightOnPrimaryColor = o.useLightOnPrimaryColor;
+        this.isActive = o.isActive;
+        this.lockToThisTask = o.lockToThisTask;
+        this.lockToTaskEnabled = o.lockToTaskEnabled;
     }
 
     /** Set the callbacks */
diff --git a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
index 98bf151..1e47b50 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/model/TaskStack.java
@@ -92,7 +92,10 @@
 
     /** Returns the index of this task in the list of filtered tasks */
     int indexOf(Task t) {
-        return mTaskIndices.get(t.key);
+        if (mTaskIndices.containsKey(t.key)) {
+            return mTaskIndices.get(t.key);
+        }
+        return -1;
     }
 
     /** Returns the size of the list of filtered tasks */
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/AnimateableViewBounds.java b/packages/SystemUI/src/com/android/systemui/recents/views/AnimateableViewBounds.java
index 34f73c6..d2fdaff 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/AnimateableViewBounds.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/AnimateableViewBounds.java
@@ -22,6 +22,7 @@
 import android.graphics.Rect;
 import android.view.View;
 import android.view.ViewOutlineProvider;
+
 import com.android.systemui.recents.RecentsConfiguration;
 
 /* An outline provider that has a clip and outline that can be animated. */
@@ -29,20 +30,23 @@
 
     RecentsConfiguration mConfig;
 
-    View mSourceView;
+    TaskView mSourceView;
+    Rect mTmpRect = new Rect();
     Rect mClipRect = new Rect();
+    Rect mClipBounds = new Rect();
     Rect mOutlineClipRect = new Rect();
     int mCornerRadius;
+    float mAlpha = 1f;
+    final float mMinAlpha = 0.25f;
 
     ObjectAnimator mClipTopAnimator;
     ObjectAnimator mClipRightAnimator;
     ObjectAnimator mClipBottomAnimator;
 
-    public AnimateableViewBounds(View source, int cornerRadius) {
+    public AnimateableViewBounds(TaskView source, int cornerRadius) {
         mConfig = RecentsConfiguration.getInstance();
         mSourceView = source;
         mCornerRadius = cornerRadius;
-        mSourceView.setClipToOutline(true);
         setClipTop(getClipTop());
         setClipRight(getClipRight());
         setClipBottom(getClipBottom());
@@ -51,13 +55,22 @@
 
     @Override
     public void getOutline(View view, Outline outline) {
+        outline.setAlpha(mMinAlpha + mAlpha / (1f - mMinAlpha));
         outline.setRoundRect(Math.max(mClipRect.left, mOutlineClipRect.left),
                 Math.max(mClipRect.top, mOutlineClipRect.top),
-                mSourceView.getMeasuredWidth() - Math.max(mClipRect.right, mOutlineClipRect.right),
-                mSourceView.getMeasuredHeight() - Math.max(mClipRect.bottom, mOutlineClipRect.bottom),
+                mSourceView.getWidth() - Math.max(mClipRect.right, mOutlineClipRect.right),
+                mSourceView.getHeight() - Math.max(mClipRect.bottom, mOutlineClipRect.bottom),
                 mCornerRadius);
     }
 
+    /** Sets the view outline alpha. */
+    void setAlpha(float alpha) {
+        if (Float.compare(alpha, mAlpha) != 0) {
+            mAlpha = alpha;
+            mSourceView.invalidateOutline();
+        }
+    }
+
     /** Animates the top clip. */
     void animateClipTop(int top, int duration, ValueAnimator.AnimatorUpdateListener updateListener) {
         if (mClipTopAnimator != null) {
@@ -78,6 +91,7 @@
         if (top != mClipRect.top) {
             mClipRect.top = top;
             mSourceView.invalidateOutline();
+            updateClipBounds();
         }
     }
 
@@ -103,6 +117,7 @@
         if (right != mClipRect.right) {
             mClipRect.right = right;
             mSourceView.invalidateOutline();
+            updateClipBounds();
         }
     }
 
@@ -128,6 +143,11 @@
         if (bottom != mClipRect.bottom) {
             mClipRect.bottom = bottom;
             mSourceView.invalidateOutline();
+            updateClipBounds();
+            if (!mConfig.useHardwareLayers) {
+                mSourceView.mThumbnailView.updateVisibility(
+                        bottom - mSourceView.getPaddingBottom());
+            }
         }
     }
 
@@ -148,4 +168,11 @@
     public int getOutlineClipBottom() {
         return mOutlineClipRect.bottom;
     }
+
+    private void updateClipBounds() {
+        mClipBounds.set(mClipRect.left, mClipRect.top,
+                mSourceView.getWidth() - mClipRect.right,
+                mSourceView.getHeight() - mClipRect.bottom);
+        mSourceView.setClipBounds(mClipBounds);
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/FakeShadowDrawable.java b/packages/SystemUI/src/com/android/systemui/recents/views/FakeShadowDrawable.java
new file mode 100644
index 0000000..72f9001
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/FakeShadowDrawable.java
@@ -0,0 +1,286 @@
+/*
+ * Copyright (C) 2014 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.systemui.recents.views;
+
+import android.content.res.Resources;
+import android.graphics.Canvas;
+import android.graphics.ColorFilter;
+import android.graphics.LinearGradient;
+import android.graphics.Paint;
+import android.graphics.Path;
+import android.graphics.PixelFormat;
+import android.graphics.RadialGradient;
+import android.graphics.Rect;
+import android.graphics.RectF;
+import android.graphics.Shader;
+import android.graphics.drawable.Drawable;
+import android.util.Log;
+
+import com.android.systemui.R;
+import com.android.systemui.recents.RecentsConfiguration;
+
+/**
+ * A rounded rectangle drawable which also includes a shadow around. This is mostly copied from
+ * frameworks/support/v7/cardview/eclair-mr1/android/support/v7/widget/
+ * RoundRectDrawableWithShadow.java revision c42ba8c000d1e6ce85e152dfc17089a0a69e739f with a few
+ * modifications to suit our needs in SystemUI.
+ */
+class FakeShadowDrawable extends Drawable {
+    // used to calculate content padding
+    final static double COS_45 = Math.cos(Math.toRadians(45));
+
+    final static float SHADOW_MULTIPLIER = 1.5f;
+
+    final float mInsetShadow; // extra shadow to avoid gaps between card and shadow
+
+    Paint mCornerShadowPaint;
+
+    Paint mEdgeShadowPaint;
+
+    final RectF mCardBounds;
+
+    float mCornerRadius;
+
+    Path mCornerShadowPath;
+
+    // updated value with inset
+    float mMaxShadowSize;
+
+    // actual value set by developer
+    float mRawMaxShadowSize;
+
+    // multiplied value to account for shadow offset
+    float mShadowSize;
+
+    // actual value set by developer
+    float mRawShadowSize;
+
+    private boolean mDirty = true;
+
+    private final int mShadowStartColor;
+
+    private final int mShadowEndColor;
+
+    private boolean mAddPaddingForCorners = true;
+
+    /**
+     * If shadow size is set to a value above max shadow, we print a warning
+     */
+    private boolean mPrintedShadowClipWarning = false;
+
+    public FakeShadowDrawable(Resources resources, RecentsConfiguration config) {
+        mShadowStartColor = resources.getColor(R.color.fake_shadow_start_color);
+        mShadowEndColor = resources.getColor(R.color.fake_shadow_end_color);
+        mInsetShadow = resources.getDimension(R.dimen.fake_shadow_inset);
+        setShadowSize(resources.getDimensionPixelSize(R.dimen.fake_shadow_size),
+                resources.getDimensionPixelSize(R.dimen.fake_shadow_size));
+        mCornerShadowPaint = new Paint(Paint.ANTI_ALIAS_FLAG | Paint.DITHER_FLAG);
+        mCornerShadowPaint.setStyle(Paint.Style.FILL);
+        mCornerShadowPaint.setDither(true);
+        mCornerRadius = config.taskViewRoundedCornerRadiusPx;
+        mCardBounds = new RectF();
+        mEdgeShadowPaint = new Paint(mCornerShadowPaint);
+    }
+
+    @Override
+    public void setAlpha(int alpha) {
+        mCornerShadowPaint.setAlpha(alpha);
+        mEdgeShadowPaint.setAlpha(alpha);
+    }
+
+    @Override
+    protected void onBoundsChange(Rect bounds) {
+        super.onBoundsChange(bounds);
+        mDirty = true;
+    }
+
+    void setShadowSize(float shadowSize, float maxShadowSize) {
+        if (shadowSize < 0 || maxShadowSize < 0) {
+            throw new IllegalArgumentException("invalid shadow size");
+        }
+        if (shadowSize > maxShadowSize) {
+            shadowSize = maxShadowSize;
+            if (!mPrintedShadowClipWarning) {
+                Log.w("CardView", "Shadow size is being clipped by the max shadow size. See "
+                        + "{CardView#setMaxCardElevation}.");
+                mPrintedShadowClipWarning = true;
+            }
+        }
+        if (mRawShadowSize == shadowSize && mRawMaxShadowSize == maxShadowSize) {
+            return;
+        }
+        mRawShadowSize = shadowSize;
+        mRawMaxShadowSize = maxShadowSize;
+        mShadowSize = shadowSize * SHADOW_MULTIPLIER + mInsetShadow;
+        mMaxShadowSize = maxShadowSize + mInsetShadow;
+        mDirty = true;
+        invalidateSelf();
+    }
+
+    @Override
+    public boolean getPadding(Rect padding) {
+        int vOffset = (int) Math.ceil(calculateVerticalPadding(mRawMaxShadowSize, mCornerRadius,
+                mAddPaddingForCorners));
+        int hOffset = (int) Math.ceil(calculateHorizontalPadding(mRawMaxShadowSize, mCornerRadius,
+                mAddPaddingForCorners));
+        padding.set(hOffset, vOffset, hOffset, vOffset);
+        return true;
+    }
+
+    static float calculateVerticalPadding(float maxShadowSize, float cornerRadius,
+            boolean addPaddingForCorners) {
+        if (addPaddingForCorners) {
+            return (float) (maxShadowSize * SHADOW_MULTIPLIER + (1 - COS_45) * cornerRadius);
+        } else {
+            return maxShadowSize * SHADOW_MULTIPLIER;
+        }
+    }
+
+    static float calculateHorizontalPadding(float maxShadowSize, float cornerRadius,
+            boolean addPaddingForCorners) {
+        if (addPaddingForCorners) {
+            return (float) (maxShadowSize + (1 - COS_45) * cornerRadius);
+        } else {
+            return maxShadowSize;
+        }
+    }
+
+    @Override
+    public void setColorFilter(ColorFilter cf) {
+        mCornerShadowPaint.setColorFilter(cf);
+        mEdgeShadowPaint.setColorFilter(cf);
+    }
+
+    @Override
+    public int getOpacity() {
+        return PixelFormat.OPAQUE;
+    }
+
+    @Override
+    public void draw(Canvas canvas) {
+        if (mDirty) {
+            buildComponents(getBounds());
+            mDirty = false;
+        }
+        canvas.translate(0, mRawShadowSize / 4);
+        drawShadow(canvas);
+        canvas.translate(0, -mRawShadowSize / 4);
+    }
+
+    private void drawShadow(Canvas canvas) {
+        final float edgeShadowTop = -mCornerRadius - mShadowSize;
+        final float inset = mCornerRadius + mInsetShadow + mRawShadowSize / 2;
+        final boolean drawHorizontalEdges = mCardBounds.width() - 2 * inset > 0;
+        final boolean drawVerticalEdges = mCardBounds.height() - 2 * inset > 0;
+        // LT
+        int saved = canvas.save();
+        canvas.translate(mCardBounds.left + inset, mCardBounds.top + inset);
+        canvas.drawPath(mCornerShadowPath, mCornerShadowPaint);
+        if (drawHorizontalEdges) {
+            canvas.drawRect(0, edgeShadowTop,
+                    mCardBounds.width() - 2 * inset, -mCornerRadius,
+                    mEdgeShadowPaint);
+        }
+        canvas.restoreToCount(saved);
+        // RB
+        saved = canvas.save();
+        canvas.translate(mCardBounds.right - inset, mCardBounds.bottom - inset);
+        canvas.rotate(180f);
+        canvas.drawPath(mCornerShadowPath, mCornerShadowPaint);
+        if (drawHorizontalEdges) {
+            canvas.drawRect(0, edgeShadowTop,
+                    mCardBounds.width() - 2 * inset, -mCornerRadius + mShadowSize,
+                    mEdgeShadowPaint);
+        }
+        canvas.restoreToCount(saved);
+        // LB
+        saved = canvas.save();
+        canvas.translate(mCardBounds.left + inset, mCardBounds.bottom - inset);
+        canvas.rotate(270f);
+        canvas.drawPath(mCornerShadowPath, mCornerShadowPaint);
+        if (drawVerticalEdges) {
+            canvas.drawRect(0, edgeShadowTop,
+                    mCardBounds.height() - 2 * inset, -mCornerRadius, mEdgeShadowPaint);
+        }
+        canvas.restoreToCount(saved);
+        // RT
+        saved = canvas.save();
+        canvas.translate(mCardBounds.right - inset, mCardBounds.top + inset);
+        canvas.rotate(90f);
+        canvas.drawPath(mCornerShadowPath, mCornerShadowPaint);
+        if (drawVerticalEdges) {
+            canvas.drawRect(0, edgeShadowTop,
+                    mCardBounds.height() - 2 * inset, -mCornerRadius, mEdgeShadowPaint);
+        }
+        canvas.restoreToCount(saved);
+    }
+
+    private void buildShadowCorners() {
+        RectF innerBounds = new RectF(-mCornerRadius, -mCornerRadius, mCornerRadius, mCornerRadius);
+        RectF outerBounds = new RectF(innerBounds);
+        outerBounds.inset(-mShadowSize, -mShadowSize);
+
+        if (mCornerShadowPath == null) {
+            mCornerShadowPath = new Path();
+        } else {
+            mCornerShadowPath.reset();
+        }
+        mCornerShadowPath.setFillType(Path.FillType.EVEN_ODD);
+        mCornerShadowPath.moveTo(-mCornerRadius, 0);
+        mCornerShadowPath.rLineTo(-mShadowSize, 0);
+        // outer arc
+        mCornerShadowPath.arcTo(outerBounds, 180f, 90f, false);
+        // inner arc
+        mCornerShadowPath.arcTo(innerBounds, 270f, -90f, false);
+        mCornerShadowPath.close();
+
+        float startRatio = mCornerRadius / (mCornerRadius + mShadowSize);
+        mCornerShadowPaint.setShader(new RadialGradient(0, 0, mCornerRadius + mShadowSize,
+                new int[]{mShadowStartColor, mShadowStartColor, mShadowEndColor},
+                new float[]{0f, startRatio, 1f}
+                , Shader.TileMode.CLAMP));
+
+        // we offset the content shadowSize/2 pixels up to make it more realistic.
+        // this is why edge shadow shader has some extra space
+        // When drawing bottom edge shadow, we use that extra space.
+        mEdgeShadowPaint.setShader(new LinearGradient(0, -mCornerRadius + mShadowSize, 0,
+                -mCornerRadius - mShadowSize,
+                new int[]{mShadowStartColor, mShadowStartColor, mShadowEndColor},
+                new float[]{0f, .5f, 1f}, Shader.TileMode.CLAMP));
+    }
+
+    private void buildComponents(Rect bounds) {
+        // Card is offset SHADOW_MULTIPLIER * maxShadowSize to account for the shadow shift.
+        // We could have different top-bottom offsets to avoid extra gap above but in that case
+        // center aligning Views inside the CardView would be problematic.
+        final float verticalOffset = mMaxShadowSize * SHADOW_MULTIPLIER;
+        mCardBounds.set(bounds.left + mMaxShadowSize, bounds.top + verticalOffset,
+                bounds.right - mMaxShadowSize, bounds.bottom - verticalOffset);
+        buildShadowCorners();
+    }
+
+    float getMinWidth() {
+        final float content = 2 *
+                Math.max(mRawMaxShadowSize, mCornerRadius + mInsetShadow + mRawMaxShadowSize / 2);
+        return content + (mRawMaxShadowSize + mInsetShadow) * 2;
+    }
+
+    float getMinHeight() {
+        final float content = 2 * Math.max(mRawMaxShadowSize, mCornerRadius + mInsetShadow
+                        + mRawMaxShadowSize * SHADOW_MULTIPLIER / 2);
+        return content + (mRawMaxShadowSize * SHADOW_MULTIPLIER + mInsetShadow) * 2;
+    }
+}
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
index 07a7e74..e6d0280 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/RecentsView.java
@@ -67,6 +67,7 @@
     ArrayList<TaskStack> mStacks;
     View mSearchBar;
     RecentsViewCallbacks mCb;
+    boolean mAlreadyLaunchingTask;
 
     public RecentsView(Context context) {
         super(context);
@@ -120,6 +121,9 @@
             }
             addView(stackView);
         }
+
+        // Reset the launched state
+        mAlreadyLaunchingTask = false;
     }
 
     /** Removes all the task stack views from this recents view. */
@@ -381,10 +385,15 @@
         if (mCb != null) {
             mCb.onTaskViewClicked();
         }
+        // Skip if we are already launching tasks
+        if (mAlreadyLaunchingTask) {
+            return;
+        }
+        mAlreadyLaunchingTask = true;
 
         // Upfront the processing of the thumbnail
         TaskViewTransform transform = new TaskViewTransform();
-        View sourceView = tv;
+        View sourceView;
         int offsetX = 0;
         int offsetY = 0;
         float stackScroll = stackView.getScroller().getStackScroll();
@@ -397,6 +406,7 @@
             offsetX = transform.rect.left;
             offsetY = mConfig.displayRect.height();
         } else {
+            sourceView = tv.mThumbnailView;
             transform = stackView.getStackAlgorithm().getStackTransform(task, stackScroll, transform, null);
         }
 
@@ -404,18 +414,32 @@
         final SystemServicesProxy ssp =
                 RecentsTaskLoader.getInstance().getSystemServicesProxy();
         ActivityOptions opts = null;
-        int thumbnailWidth = transform.rect.width();
-        int thumbnailHeight = transform.rect.height();
-        if (task.thumbnail != null && thumbnailWidth > 0 && thumbnailHeight > 0 &&
-                task.thumbnail.getWidth() > 0 && task.thumbnail.getHeight() > 0) {
-            // Resize the thumbnail to the size of the view that we are animating from
-            Bitmap b = Bitmap.createBitmap(thumbnailWidth, thumbnailHeight,
-                    Bitmap.Config.ARGB_8888);
-            Canvas c = new Canvas(b);
-            c.drawBitmap(task.thumbnail,
-                    new Rect(0, 0, task.thumbnail.getWidth(), task.thumbnail.getHeight()),
-                    new Rect(0, 0, thumbnailWidth, thumbnailHeight), null);
-            c.setBitmap(null);
+        if (task.thumbnail != null && task.thumbnail.getWidth() > 0 &&
+                task.thumbnail.getHeight() > 0) {
+            Bitmap b;
+            if (tv != null) {
+                // Disable any focused state before we draw the header
+                if (tv.isFocusedTask()) {
+                    tv.unsetFocusedTask();
+                }
+
+                float scale = tv.getScaleX();
+                int fromHeaderWidth = (int) (tv.mHeaderView.getMeasuredWidth() * scale);
+                int fromHeaderHeight = (int) (tv.mHeaderView.getMeasuredHeight() * scale);
+                b = Bitmap.createBitmap(fromHeaderWidth, fromHeaderHeight,
+                        Bitmap.Config.ARGB_8888);
+                if (Constants.DebugFlags.App.EnableTransitionThumbnailDebugMode) {
+                    b.eraseColor(0xFFff0000);
+                } else {
+                    Canvas c = new Canvas(b);
+                    c.scale(tv.getScaleX(), tv.getScaleY());
+                    tv.mHeaderView.draw(c);
+                    c.setBitmap(null);
+                }
+            } else {
+                // Notify the system to skip the thumbnail layer by using an ALPHA_8 bitmap
+                b = Bitmap.createBitmap(1, 1, Bitmap.Config.ALPHA_8);
+            }
             ActivityOptions.OnAnimationStartedListener animStartedListener = null;
             if (lockToTask) {
                 animStartedListener = new ActivityOptions.OnAnimationStartedListener() {
@@ -434,8 +458,9 @@
                     }
                 };
             }
-            opts = ActivityOptions.makeThumbnailScaleUpAnimation(sourceView,
-                    b, offsetX, offsetY, animStartedListener);
+            opts = ActivityOptions.makeThumbnailAspectScaleUpAnimation(sourceView,
+                    b, offsetX, offsetY, transform.rect.width(), transform.rect.height(),
+                    animStartedListener);
         }
 
         final ActivityOptions launchOpts = opts;
@@ -446,13 +471,6 @@
                     // Bring an active task to the foreground
                     ssp.moveTaskToFront(task.key.id, launchOpts);
                 } else {
-                    // Launch the activity anew with the desired animation
-                    Intent i = new Intent(task.key.baseIntent);
-                    i.addFlags(Intent.FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY
-                            | Intent.FLAG_ACTIVITY_TASK_ON_HOME);
-                    if (!Utilities.isDocument(i)) {
-                        i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-                    }
                     try {
                         ssp.startActivityFromRecents(task.key.id, launchOpts);
                         if (launchOpts == null && lockToTask) {
@@ -461,9 +479,6 @@
                     } catch (ActivityNotFoundException anfe) {
                         Console.logError(getContext(), "Could not start Activity");
                     }
-
-                    // And clean up the old task
-                    onTaskViewDismissed(task);
                 }
             }
         };
@@ -472,7 +487,15 @@
         if (tv == null) {
             post(launchRunnable);
         } else {
-            stackView.startLaunchTaskAnimation(tv, launchRunnable);
+            if (!task.group.isFrontMostTask(task)) {
+                // For affiliated tasks that are behind other tasks, we must animate the front cards
+                // out of view before starting the task transition
+                stackView.startLaunchTaskAnimation(tv, launchRunnable, lockToTask);
+            } else {
+                // Otherwise, we can start the task transition immediately
+                stackView.startLaunchTaskAnimation(tv, null, lockToTask);
+                postDelayed(launchRunnable, 17);
+            }
         }
     }
 
@@ -485,7 +508,7 @@
         intent.setComponent(intent.resolveActivity(getContext().getPackageManager()));
         TaskStackBuilder.create(getContext())
                 .addNextIntentWithParentStack(intent).startActivities(null,
-                new UserHandle(t.userId));
+                new UserHandle(t.key.userId));
     }
 
     @Override
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/SwipeHelper.java b/packages/SystemUI/src/com/android/systemui/recents/views/SwipeHelper.java
index e0298ab..fa44551 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/SwipeHelper.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/SwipeHelper.java
@@ -28,6 +28,7 @@
 import android.view.VelocityTracker;
 import android.view.View;
 import android.view.animation.LinearInterpolator;
+import com.android.systemui.recents.RecentsConfiguration;
 
 /**
  * This class facilitates swipe to dismiss. It defines an interface to be implemented by the
@@ -50,7 +51,7 @@
     private int DEFAULT_ESCAPE_ANIMATION_DURATION = 75; // ms
     private int MAX_ESCAPE_ANIMATION_DURATION = 150; // ms
     private int MAX_DISMISS_VELOCITY = 2000; // dp/sec
-    private static final int SNAP_ANIM_LEN = SLOW_ANIMATIONS ? 1000 : 150; // ms
+    private static final int SNAP_ANIM_LEN = SLOW_ANIMATIONS ? 1000 : 250; // ms
 
     public static float ALPHA_FADE_START = 0.15f; // fraction of thumbnail width
                                                  // where fade starts
@@ -265,6 +266,7 @@
         ValueAnimator anim = createTranslationAnimation(view, 0);
         int duration = SNAP_ANIM_LEN;
         anim.setDuration(duration);
+        anim.setInterpolator(RecentsConfiguration.getInstance().linearOutSlowInInterpolator);
         anim.addUpdateListener(new AnimatorUpdateListener() {
             @Override
             public void onAnimationUpdate(ValueAnimator animation) {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java b/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java
index 5b17b41..162897e 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/SystemBarScrimViews.java
@@ -97,6 +97,14 @@
      * going home).
      */
     public void startExitRecentsAnimation() {
+        if (mHasStatusBarScrim && mShouldAnimateStatusBarScrim) {
+            mStatusBarScrimView.animate()
+                    .translationY(-mStatusBarScrimView.getMeasuredHeight())
+                    .setStartDelay(0)
+                    .setDuration(mConfig.taskBarExitAnimDuration)
+                    .setInterpolator(mConfig.fastOutSlowInInterpolator)
+                    .start();
+        }
         if (mHasNavBarScrim && mShouldAnimateNavBarScrim) {
             mNavBarScrimView.animate()
                     .translationY(mNavBarScrimView.getMeasuredHeight())
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java
index aee558f..e1e4068 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackView.java
@@ -16,17 +16,23 @@
 
 package com.android.systemui.recents.views;
 
+import android.animation.ValueAnimator;
 import android.content.ComponentName;
 import android.content.Context;
+import android.graphics.Matrix;
 import android.graphics.Rect;
 import android.view.LayoutInflater;
 import android.view.MotionEvent;
 import android.view.View;
+import android.view.ViewTreeObserver;
+import android.view.accessibility.AccessibilityEvent;
 import android.widget.FrameLayout;
 import com.android.systemui.R;
 import com.android.systemui.recents.Constants;
 import com.android.systemui.recents.RecentsConfiguration;
 import com.android.systemui.recents.misc.DozeTrigger;
+import com.android.systemui.recents.misc.SystemServicesProxy;
+import com.android.systemui.recents.misc.Utilities;
 import com.android.systemui.recents.model.RecentsPackageMonitor;
 import com.android.systemui.recents.model.RecentsTaskLoader;
 import com.android.systemui.recents.model.Task;
@@ -67,19 +73,33 @@
     DebugOverlayView mDebugOverlay;
     Rect mTaskStackBounds = new Rect();
     int mFocusedTaskIndex = -1;
+    int mPrevAccessibilityFocusedIndex = -1;
 
     // Optimizations
     int mStackViewsAnimationDuration;
     boolean mStackViewsDirty = true;
+    boolean mStackViewsClipDirty = true;
     boolean mAwaitingFirstLayout = true;
     boolean mStartEnterAnimationRequestedAfterLayout;
     boolean mStartEnterAnimationCompleted;
     ViewAnimation.TaskViewEnterContext mStartEnterAnimationContext;
     int[] mTmpVisibleRange = new int[2];
+    float[] mTmpCoord = new float[2];
+    Matrix mTmpMatrix = new Matrix();
+    Rect mTmpRect = new Rect();
     TaskViewTransform mTmpTransform = new TaskViewTransform();
     HashMap<Task, TaskView> mTmpTaskViewMap = new HashMap<Task, TaskView>();
     LayoutInflater mInflater;
 
+    // A convenience update listener to request updating clipping of tasks
+    ValueAnimator.AnimatorUpdateListener mRequestUpdateClippingListener =
+            new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            requestUpdateStackViewsClip();
+        }
+    };
+
     // A convenience runnable to return all views to the pool
     Runnable mReturnAllViewsToPoolRunnable = new Runnable() {
         @Override
@@ -105,7 +125,7 @@
         mFilterAlgorithm = new TaskStackViewFilterAlgorithm(mConfig, this, mViewPool);
         mStackScroller = new TaskStackViewScroller(context, mConfig, mLayoutAlgorithm);
         mStackScroller.setCallbacks(this);
-        mTouchHandler = new TaskStackViewTouchHandler(context, this, mStackScroller);
+        mTouchHandler = new TaskStackViewTouchHandler(context, this, mConfig, mStackScroller);
         mUIDozeTrigger = new DozeTrigger(mConfig.taskBarDismissDozeDelaySeconds, new Runnable() {
             @Override
             public void run() {
@@ -146,6 +166,14 @@
         }
     }
 
+    /** Requests that the views clipping be updated. */
+    void requestUpdateStackViewsClip() {
+        if (!mStackViewsClipDirty) {
+            invalidate();
+            mStackViewsClipDirty = true;
+        }
+    }
+
     /** Finds the child view given a specific task. */
     public TaskView getChildViewForTask(Task t) {
         int childCount = getChildCount();
@@ -244,6 +272,9 @@
     /** Synchronizes the views with the model */
     boolean synchronizeStackViewsWithModel() {
         if (mStackViewsDirty) {
+            RecentsTaskLoader loader = RecentsTaskLoader.getInstance();
+            SystemServicesProxy ssp = loader.getSystemServicesProxy();
+
             // Get all the task transforms
             ArrayList<Task> tasks = mStack.getTasks();
             float stackScroll = mStackScroller.getStackScroll();
@@ -292,12 +323,25 @@
 
                 // Animate the task into place
                 tv.updateViewPropertiesToTaskTransform(mCurrentTaskTransforms.get(taskIndex),
-                        mStackViewsAnimationDuration);
+                        mStackViewsAnimationDuration, mRequestUpdateClippingListener);
+
+                // Request accessibility focus on the next view if we removed the task
+                // that previously held accessibility focus
+                childCount = getChildCount();
+                if (childCount > 0 && ssp.isTouchExplorationEnabled()) {
+                    TaskView atv = (TaskView) getChildAt(childCount - 1);
+                    int indexOfTask = mStack.indexOfTask(atv.getTask());
+                    if (mPrevAccessibilityFocusedIndex != indexOfTask) {
+                        tv.requestAccessibilityFocus();
+                        mPrevAccessibilityFocusedIndex = indexOfTask;
+                    }
+                }
             }
 
             // Reset the request-synchronize params
             mStackViewsAnimationDuration = 0;
             mStackViewsDirty = false;
+            mStackViewsClipDirty = true;
             return true;
         }
         return false;
@@ -328,10 +372,13 @@
                     // stacked and we can make assumptions about the visibility of the this
                     // task relative to the ones in front of it.
                     if (nextTv != null) {
-                        // We can reuse the current task transforms to find the task rects
-                        TaskViewTransform transform = mCurrentTaskTransforms.get(mStack.indexOfTask(tv.getTask()));
-                        TaskViewTransform nextTransform = mCurrentTaskTransforms.get(mStack.indexOfTask(nextTv.getTask()));
-                        clipBottom = transform.rect.bottom - nextTransform.rect.top;
+                        // Map the top edge of next task view into the local space of the current
+                        // task view to find the clip amount in local space
+                        mTmpCoord[0] = mTmpCoord[1] = 0;
+                        Utilities.mapCoordInDescendentToSelf(nextTv, this, mTmpCoord, false);
+                        Utilities.mapCoordInSelfToDescendent(tv, this, mTmpCoord, mTmpMatrix);
+                        clipBottom = (int) Math.floor(tv.getMeasuredHeight() - mTmpCoord[1]
+                                - nextTv.getPaddingTop() - 1);
                     }
                 }
                 tv.getViewBounds().setClipBottom(clipBottom);
@@ -342,6 +389,7 @@
                 tv.getViewBounds().setClipBottom(0);
             }
         }
+        mStackViewsClipDirty = false;
     }
 
     /** The stack insets to apply to the stack contents */
@@ -432,6 +480,22 @@
     }
 
     @Override
+    public void onInitializeAccessibilityEvent(AccessibilityEvent event) {
+        super.onInitializeAccessibilityEvent(event);
+        int childCount = getChildCount();
+        if (childCount > 0) {
+            TaskView backMostTask = (TaskView) getChildAt(0);
+            TaskView frontMostTask = (TaskView) getChildAt(childCount - 1);
+            event.setFromIndex(mStack.indexOfTask(backMostTask.getTask()));
+            event.setToIndex(mStack.indexOfTask(frontMostTask.getTask()));
+            event.setContentDescription(frontMostTask.getTask().activityLabel);
+        }
+        event.setItemCount(mStack.getTaskCount());
+        event.setScrollY(mStackScroller.mScroller.getCurrY());
+        event.setMaxScrollY(mStackScroller.progressToScrollRange(mLayoutAlgorithm.mMaxScrollP));
+    }
+
+    @Override
     public boolean onInterceptTouchEvent(MotionEvent ev) {
         return mTouchHandler.onInterceptTouchEvent(ev);
     }
@@ -447,6 +511,8 @@
         // Synchronize the views
         synchronizeStackViewsWithModel();
         clipTaskViews();
+        // Notify accessibility
+        sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_SCROLLED);
     }
 
     /** Computes the stack and task rects */
@@ -460,7 +526,17 @@
     }
 
     /**
-     * This is called with the full window width and height to allow stack view children to 
+     * This is ONLY used from AlternateRecentsComponent to update the dummy stack view for purposes
+     * of getting the task rect to animate to.
+     */
+    public void updateMinMaxScrollForStack(TaskStack stack, boolean launchedWithAltTab,
+            boolean launchedFromHome) {
+        mStack = stack;
+        updateMinMaxScroll(false, launchedWithAltTab, launchedFromHome);
+    }
+
+    /**
+     * This is called with the full window width and height to allow stack view children to
      * perform the full screen transition down.
      */
     @Override
@@ -489,10 +565,17 @@
             if (tv.isFullScreenView()) {
                 tv.measure(widthMeasureSpec, heightMeasureSpec);
             } else {
+                if (tv.getBackground() != null) {
+                    tv.getBackground().getPadding(mTmpRect);
+                } else {
+                    mTmpRect.setEmpty();
+                }
                 tv.measure(
-                    MeasureSpec.makeMeasureSpec(mLayoutAlgorithm.mTaskRect.width(),
+                    MeasureSpec.makeMeasureSpec(
+                            mLayoutAlgorithm.mTaskRect.width() + mTmpRect.left + mTmpRect.right,
                             MeasureSpec.EXACTLY),
-                    MeasureSpec.makeMeasureSpec(mLayoutAlgorithm.mTaskRect.height() +
+                    MeasureSpec.makeMeasureSpec(
+                            mLayoutAlgorithm.mTaskRect.height() + mTmpRect.top + mTmpRect.bottom +
                             tv.getMaxFooterHeight(), MeasureSpec.EXACTLY));
             }
         }
@@ -514,8 +597,15 @@
             if (tv.isFullScreenView()) {
                 tv.layout(left, top, left + tv.getMeasuredWidth(), top + tv.getMeasuredHeight());
             } else {
-                tv.layout(mLayoutAlgorithm.mTaskRect.left, mLayoutAlgorithm.mTaskRect.top,
-                        mLayoutAlgorithm.mTaskRect.right, mLayoutAlgorithm.mTaskRect.bottom +
+                if (tv.getBackground() != null) {
+                    tv.getBackground().getPadding(mTmpRect);
+                } else {
+                    mTmpRect.setEmpty();
+                }
+                tv.layout(mLayoutAlgorithm.mTaskRect.left - mTmpRect.left,
+                        mLayoutAlgorithm.mTaskRect.top - mTmpRect.top,
+                        mLayoutAlgorithm.mTaskRect.right + mTmpRect.right,
+                        mLayoutAlgorithm.mTaskRect.bottom + mTmpRect.bottom +
                                 tv.getMaxFooterHeight());
             }
         }
@@ -602,6 +692,7 @@
                 ctx.currentTaskRect = mLayoutAlgorithm.mTaskRect;
                 ctx.currentTaskOccludesLaunchTarget = (launchTargetTask != null) &&
                         launchTargetTask.group.isTaskAboveTask(task, launchTargetTask);
+                ctx.updateListener = mRequestUpdateClippingListener;
                 mLayoutAlgorithm.getStackTransform(task, mStackScroller.getStackScroll(), ctx.currentTaskTransform, null);
                 tv.startEnterRecentsAnimation(ctx);
             }
@@ -613,6 +704,15 @@
                     mStartEnterAnimationCompleted = true;
                     // Start dozing
                     mUIDozeTrigger.startDozing();
+                    // Focus the first view if accessibility is enabled
+                    RecentsTaskLoader loader = RecentsTaskLoader.getInstance();
+                    SystemServicesProxy ssp = loader.getSystemServicesProxy();
+                    int childCount = getChildCount();
+                    if (childCount > 0 && ssp.isTouchExplorationEnabled()) {
+                        TaskView tv = ((TaskView) getChildAt(childCount - 1));
+                        tv.requestAccessibilityFocus();
+                        mPrevAccessibilityFocusedIndex = mStack.indexOfTask(tv.getTask());
+                    }
                 }
             });
         }
@@ -637,17 +737,17 @@
     }
 
     /** Animates a task view in this stack as it launches. */
-    public void startLaunchTaskAnimation(TaskView tv, final Runnable r) {
+    public void startLaunchTaskAnimation(TaskView tv, Runnable r, boolean lockToTask) {
         Task launchTargetTask = tv.getTask();
         int childCount = getChildCount();
         for (int i = 0; i < childCount; i++) {
             TaskView t = (TaskView) getChildAt(i);
             if (t == tv) {
-                t.startLaunchTaskAnimation(r, true, true);
+                t.startLaunchTaskAnimation(r, true, true, lockToTask);
             } else {
                 boolean occludesLaunchTarget = launchTargetTask.group.isTaskAboveTask(t.getTask(),
                         launchTargetTask);
-                t.startLaunchTaskAnimation(null, false, occludesLaunchTarget);
+                t.startLaunchTaskAnimation(null, false, occludesLaunchTarget, lockToTask);
             }
         }
     }
@@ -802,6 +902,11 @@
     public void prepareViewToEnterPool(TaskView tv) {
         Task task = tv.getTask();
 
+        // Clear the accessibility focus for that view
+        if (tv.isAccessibilityFocused()) {
+            tv.clearAccessibilityFocus();
+        }
+
         // Report that this tasks's data is no longer being used
         RecentsTaskLoader.getInstance().unloadTaskData(task);
 
@@ -926,7 +1031,9 @@
 
     @Override
     public void onTaskViewClipStateChanged(TaskView tv) {
-        invalidate();
+        if (!mStackViewsDirty) {
+            invalidate();
+        }
     }
 
     @Override
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewLayoutAlgorithm.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewLayoutAlgorithm.java
index 667faa7..31fc701 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewLayoutAlgorithm.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewLayoutAlgorithm.java
@@ -33,7 +33,7 @@
 public class TaskStackViewLayoutAlgorithm {
 
     // These are all going to change
-    static final float StackPeekMinScale = 0.825f; // The min scale of the last card in the peek area
+    static final float StackPeekMinScale = 0.8f; // The min scale of the last card in the peek area
 
     RecentsConfiguration mConfig;
 
@@ -53,7 +53,7 @@
 
     // Log function
     static final float XScale = 1.75f;  // The large the XScale, the longer the flat area of the curve
-    static final float LogBase = 300;
+    static final float LogBase = 3000;
     static final int PrecisionSteps = 250;
     static float[] xp;
     static float[] px;
@@ -84,7 +84,7 @@
                 left + size, mStackRect.top + size);
 
         // Update the affiliation offsets
-        float visibleTaskPct = 0.55f;
+        float visibleTaskPct = 0.5f;
         mWithinAffiliationOffset = mConfig.taskBarHeight;
         mBetweenAffiliationOffset = (int) (visibleTaskPct * mTaskRect.height());
     }
@@ -157,7 +157,7 @@
     public TaskViewTransform getStackTransform(Task task, float stackScroll, TaskViewTransform transformOut,
             TaskViewTransform prevTransform) {
         // Return early if we have an invalid index
-        if (task == null) {
+        if (task == null || !mTaskProgressMap.containsKey(task.key)) {
             transformOut.reset();
             return transformOut;
         }
@@ -200,6 +200,15 @@
     }
 
     /**
+     * Returns the untransformed task view size.
+     */
+    public Rect getUntransformedTaskViewSize() {
+        Rect tvSize = new Rect(mTaskRect);
+        tvSize.offsetTo(0, 0);
+        return tvSize;
+    }
+
+    /**
      * Returns the scroll to such task top = 1f;
      */
     float getStackScrollForTask(Task t) {
@@ -312,4 +321,4 @@
         }
         return px[xFloorIndex] + pFraction;
     }
-}
\ No newline at end of file
+}
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewScroller.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewScroller.java
index 2c0dc44..5852b88 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewScroller.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewScroller.java
@@ -133,12 +133,8 @@
         stopBoundScrollAnimation();
 
         mScrollAnimator = ObjectAnimator.ofFloat(this, "stackScroll", curScroll, newScroll);
-        mScrollAnimator.setDuration(200);
-        // We would have to project the difference into the screen coords, and then use that as the
-        // duration
-//        mScrollAnimator.setDuration(Utilities.calculateTranslationAnimationDuration(newScroll -
-//                curScroll, 250));
-        mScrollAnimator.setInterpolator(mConfig.fastOutSlowInInterpolator);
+        mScrollAnimator.setDuration(mConfig.taskStackScrollDuration);
+        mScrollAnimator.setInterpolator(mConfig.linearOutSlowInInterpolator);
         mScrollAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
             @Override
             public void onAnimationUpdate(ValueAnimator animation) {
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java
index 374a27f..8f9b4c2 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskStackViewTouchHandler.java
@@ -23,11 +23,13 @@
 import android.view.ViewConfiguration;
 import android.view.ViewParent;
 import com.android.systemui.recents.Constants;
+import com.android.systemui.recents.RecentsConfiguration;
 
 /* Handles touch events for a TaskStackView. */
 class TaskStackViewTouchHandler implements SwipeHelper.Callback {
     static int INACTIVE_POINTER_ID = -1;
 
+    RecentsConfiguration mConfig;
     TaskStackView mSv;
     TaskStackViewScroller mScroller;
     VelocityTracker mVelocityTracker;
@@ -52,7 +54,8 @@
     SwipeHelper mSwipeHelper;
     boolean mInterceptedBySwipeHelper;
 
-    public TaskStackViewTouchHandler(Context context, TaskStackView sv, TaskStackViewScroller scroller) {
+    public TaskStackViewTouchHandler(Context context, TaskStackView sv,
+            RecentsConfiguration config, TaskStackViewScroller scroller) {
         ViewConfiguration configuration = ViewConfiguration.get(context);
         mMinimumVelocity = configuration.getScaledMinimumFlingVelocity();
         mMaximumVelocity = configuration.getScaledMaximumFlingVelocity();
@@ -60,6 +63,7 @@
         mPagingTouchSlop = configuration.getScaledPagingTouchSlop();
         mSv = sv;
         mScroller = scroller;
+        mConfig = config;
 
         float densityScale = context.getResources().getDisplayMetrics().density;
         mSwipeHelper = new SwipeHelper(SwipeHelper.X, this, densityScale, mPagingTouchSlop);
@@ -258,7 +262,7 @@
                     if (Float.compare(overScrollAmount, 0f) != 0) {
                         // Bound the overscroll to a fixed amount, and inversely scale the y-movement
                         // relative to how close we are to the max overscroll
-                        float maxOverScroll = 0.25f;
+                        float maxOverScroll = mConfig.taskStackOverscrollPct;
                         deltaP *= (1f - (Math.min(maxOverScroll, overScrollAmount)
                                 / maxOverScroll));
                     }
@@ -280,7 +284,6 @@
                 velocityTracker.computeCurrentVelocity(1000, mMaximumVelocity);
                 int velocity = (int) velocityTracker.getYVelocity(mActivePointerId);
                 if (mIsScrolling && (Math.abs(velocity) > mMinimumVelocity)) {
-                    // XXX: Should this be calculated as a percentage of a curve?
                     int overscrollRange = (int) (Math.min(1f,
                             Math.abs((float) velocity / mMaximumVelocity)) *
                             Constants.Values.TaskStackView.TaskStackOverscrollRange);
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
index 5914b39..1750804 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskView.java
@@ -20,13 +20,12 @@
 import android.animation.ObjectAnimator;
 import android.animation.ValueAnimator;
 import android.content.Context;
-import android.graphics.Color;
-import android.graphics.Paint;
-import android.graphics.PorterDuff;
-import android.graphics.PorterDuffColorFilter;
-import android.graphics.Rect;
+import android.graphics.*;
+import android.graphics.drawable.Drawable;
+import android.graphics.drawable.LayerDrawable;
 import android.util.AttributeSet;
 import android.view.View;
+import android.view.ViewOutlineProvider;
 import android.view.animation.AccelerateInterpolator;
 import android.widget.FrameLayout;
 import com.android.systemui.R;
@@ -39,6 +38,7 @@
 /* A task view */
 public class TaskView extends FrameLayout implements Task.TaskCallbacks,
         TaskViewFooter.TaskFooterViewCallbacks, View.OnClickListener, View.OnLongClickListener {
+
     /** The TaskView callbacks */
     interface TaskViewCallbacks {
         public void onTaskViewAppIconClicked(TaskView tv);
@@ -57,7 +57,7 @@
     ObjectAnimator mDimAnimator;
     float mMaxDimScale;
     int mDim;
-    AccelerateInterpolator mDimInterpolator = new AccelerateInterpolator(1.25f);
+    AccelerateInterpolator mDimInterpolator = new AccelerateInterpolator(1f);
     PorterDuffColorFilter mDimColorFilter = new PorterDuffColorFilter(0, PorterDuff.Mode.MULTIPLY);
 
     Task mTask;
@@ -69,6 +69,7 @@
     AnimateableViewBounds mViewBounds;
     Paint mLayerPaint = new Paint();
 
+    View mContent;
     TaskViewThumbnail mThumbnailView;
     TaskViewHeader mHeaderView;
     TaskViewFooter mFooterView;
@@ -103,9 +104,12 @@
         mMaxDimScale = mConfig.taskStackMaxDim / 255f;
         mClipViewInStack = true;
         mViewBounds = new AnimateableViewBounds(this, mConfig.taskViewRoundedCornerRadiusPx);
-        setOutlineProvider(mViewBounds);
         setTaskProgress(getTaskProgress());
         setDim(getDim());
+        if (mConfig.fakeShadows) {
+            setBackground(new FakeShadowDrawable(context.getResources(), mConfig));
+        }
+        setOutlineProvider(mViewBounds);
     }
 
     /** Set callback */
@@ -126,9 +130,18 @@
     @Override
     protected void onFinishInflate() {
         // Bind the views
+        mContent = findViewById(R.id.task_view_content);
         mHeaderView = (TaskViewHeader) findViewById(R.id.task_view_bar);
         mThumbnailView = (TaskViewThumbnail) findViewById(R.id.task_view_thumbnail);
+        mThumbnailView.enableTaskBarClip(mHeaderView);
         mActionButtonView = findViewById(R.id.lock_to_app_fab);
+        mActionButtonView.setOutlineProvider(new ViewOutlineProvider() {
+            @Override
+            public void getOutline(View view, Outline outline) {
+                // Set the outline to match the FAB background
+                outline.setOval(0, 0, mActionButtonView.getWidth(), mActionButtonView.getHeight());
+            }
+        });
         if (mFooterView != null) {
             mFooterView.setCallbacks(this);
         }
@@ -139,24 +152,35 @@
         int width = MeasureSpec.getSize(widthMeasureSpec);
         int height = MeasureSpec.getSize(heightMeasureSpec);
 
+        int widthWithoutPadding = width - mPaddingLeft - mPaddingRight;
+        int heightWithoutPadding = height - mPaddingTop - mPaddingBottom;
+
+        // Measure the content
+        mContent.measure(MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY),
+                MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY));
+
         // Measure the bar view, thumbnail, and footer
-        mHeaderView.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY),
+        mHeaderView.measure(MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY),
                 MeasureSpec.makeMeasureSpec(mConfig.taskBarHeight, MeasureSpec.EXACTLY));
         if (mFooterView != null) {
-            mFooterView.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY),
+            mFooterView.measure(
+                    MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY),
                     MeasureSpec.makeMeasureSpec(mConfig.taskViewLockToAppButtonHeight,
                             MeasureSpec.EXACTLY));
         }
-        mActionButtonView.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.AT_MOST),
-                MeasureSpec.makeMeasureSpec(height, MeasureSpec.AT_MOST));
+        mActionButtonView.measure(
+                MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.AT_MOST),
+                MeasureSpec.makeMeasureSpec(heightWithoutPadding, MeasureSpec.AT_MOST));
         if (mIsFullScreenView) {
             // Measure the thumbnail height to be the full dimensions
-            mThumbnailView.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY),
-                    MeasureSpec.makeMeasureSpec(height, MeasureSpec.EXACTLY));
+            mThumbnailView.measure(
+                    MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY),
+                    MeasureSpec.makeMeasureSpec(heightWithoutPadding, MeasureSpec.EXACTLY));
         } else {
             // Measure the thumbnail to be square
-            mThumbnailView.measure(MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY),
-                    MeasureSpec.makeMeasureSpec(width, MeasureSpec.EXACTLY));
+            mThumbnailView.measure(
+                    MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY),
+                    MeasureSpec.makeMeasureSpec(widthWithoutPadding, MeasureSpec.EXACTLY));
         }
         setMeasuredDimension(width, height);
         invalidateOutline();
@@ -164,10 +188,15 @@
 
     /** Synchronizes this view's properties with the task's transform */
     void updateViewPropertiesToTaskTransform(TaskViewTransform toTransform, int duration) {
+        updateViewPropertiesToTaskTransform(toTransform, duration, null);
+    }
+
+    void updateViewPropertiesToTaskTransform(TaskViewTransform toTransform, int duration,
+                                             ValueAnimator.AnimatorUpdateListener updateCallback) {
         // If we are a full screen view, then only update the Z to keep it in order
         // XXX: Also update/animate the dim as well
         if (mIsFullScreenView) {
-            if (Constants.DebugFlags.App.EnableShadows &&
+            if (!mConfig.fakeShadows &&
                     toTransform.hasTranslationZChangedFrom(getTranslationZ())) {
                 setTranslationZ(toTransform.translationZ);
             }
@@ -175,7 +204,8 @@
         }
 
         // Apply the transform
-        toTransform.applyToTaskView(this, duration, mConfig.fastOutSlowInInterpolator, false);
+        toTransform.applyToTaskView(this, duration, mConfig.fastOutSlowInInterpolator, false,
+                !mConfig.fakeShadows, updateCallback);
 
         // Update the task progress
         if (mTaskProgressAnimator != null) {
@@ -225,7 +255,6 @@
         int initialDim = getDim();
         if (mConfig.launchedFromAppWithScreenshot) {
             if (isTaskViewLaunchTargetTask) {
-                mHeaderView.prepareEnterRecentsAnimation();
                 // Hide the footer during the transition in, and animate it out afterwards?
                 if (mFooterView != null) {
                     mFooterView.animateFooterVisibility(false, 0);
@@ -236,8 +265,6 @@
 
         } else if (mConfig.launchedFromAppWithThumbnail) {
             if (isTaskViewLaunchTargetTask) {
-                // Hide the front most task bar view so we can animate it in
-                mHeaderView.prepareEnterRecentsAnimation();
                 // Hide the action button if it exists
                 mActionButtonView.setAlpha(0f);
                 // Set the dim to 0 so we can animate it in
@@ -250,9 +277,7 @@
         } else if (mConfig.launchedFromHome) {
             // Move the task view off screen (below) so we can animate it in
             setTranslationY(offscreenY);
-            if (Constants.DebugFlags.App.EnableShadows) {
-                setTranslationZ(0);
-            }
+            setTranslationZ(0);
             setScaleX(1f);
             setScaleY(1f);
         }
@@ -277,7 +302,7 @@
                 float scaledWindowInsetTop = (int) (taskScale * windowInsetTop);
                 float scaledTranslationY = taskRect.top + transform.translationY -
                         (scaledWindowInsetTop + scaledYOffset);
-                startDelay = mConfig.taskViewEnterFromHomeDelay;
+                startDelay = mConfig.taskViewEnterFromHomeStaggerDelay;
 
                 // Animate the top clip
                 mViewBounds.animateClipTop(windowInsetTop, duration,
@@ -296,7 +321,6 @@
                     mViewBounds.animateClipBottom(getMeasuredHeight() - (windowInsetTop + size), duration);
                 }
                 // Animate the task bar of the first task view
-                mHeaderView.startEnterRecentsAnimation(0, null);
                 animate()
                         .scaleX(taskScale)
                         .scaleY(taskScale)
@@ -314,8 +338,6 @@
                                 mViewBounds.setClipRight(0);
                                 // Reset the bar translation
                                 mHeaderView.setTranslationY(0);
-                                // Enable the thumbnail clip
-                                mThumbnailView.enableTaskBarClip(mHeaderView);
                                 // Animate the footer into view (if it is the front most task)
                                 animateFooterVisibility(true, mConfig.taskBarEnterAnimDuration);
 
@@ -332,9 +354,6 @@
                         })
                         .start();
             } else {
-                // Otherwise, just enable the thumbnail clip
-                mThumbnailView.enableTaskBarClip(mHeaderView);
-
                 // Animate the footer into view
                 animateFooterVisibility(true, 0);
             }
@@ -342,9 +361,6 @@
 
         } else if (mConfig.launchedFromAppWithThumbnail) {
             if (mTask.isLaunchTarget) {
-                // Animate the task bar of the first task view
-                mHeaderView.startEnterRecentsAnimation(mConfig.taskBarEnterAnimDelay,
-                        mThumbnailView.enableTaskBarClipAsRunnable(mHeaderView));
                 // Animate the dim/overlay
                 if (Constants.DebugFlags.App.EnableThumbnailAlphaOnFrontmost) {
                     // Animate the thumbnail alpha before the dim animation (to prevent updating the
@@ -376,8 +392,6 @@
                         .withLayer()
                         .start();
             } else {
-                // Enable the task bar clip
-                mThumbnailView.enableTaskBarClip(mHeaderView);
                 // Animate the task up if it was occluding the launch target
                 if (ctx.currentTaskOccludesLaunchTarget) {
                     setTranslationY(transform.translationY + mConfig.taskViewAffiliateGroupEnterOffsetPx);
@@ -391,7 +405,6 @@
                             .withEndAction(new Runnable() {
                                 @Override
                                 public void run() {
-                                    mThumbnailView.enableTaskBarClip(mHeaderView);
                                     // Decrement the post animation trigger
                                     ctx.postAnimationTrigger.decrement();
                                 }
@@ -405,9 +418,12 @@
         } else if (mConfig.launchedFromHome) {
             // Animate the tasks up
             int frontIndex = (ctx.currentStackViewCount - ctx.currentStackViewIndex - 1);
-            int delay = mConfig.taskBarEnterAnimDelay +
-                    frontIndex * mConfig.taskViewEnterFromHomeDelay;
-            if (Constants.DebugFlags.App.EnableShadows) {
+            float fraction = (float) frontIndex / (ctx.currentStackViewCount - 1);
+            fraction = (float) Math.pow(fraction, 0.85f);
+            int delay = (int) (mConfig.taskViewEnterFromHomeDelay +
+                                fraction * mConfig.taskViewEnterFromHomeStaggerDelay);
+            long delayIncrease = (long) (fraction * mConfig.taskViewEnterFromHomeStaggerDuration);
+            if (!mConfig.fakeShadows) {
                 animate().translationZ(transform.translationZ);
             }
             animate()
@@ -415,13 +431,12 @@
                     .scaleY(transform.scale)
                     .translationY(transform.translationY)
                     .setStartDelay(delay)
-                    .setUpdateListener(null)
+                    .setUpdateListener(ctx.updateListener)
                     .setInterpolator(mConfig.quintOutInterpolator)
-                    .setDuration(mConfig.taskViewEnterFromHomeDuration)
+                    .setDuration(mConfig.taskViewEnterFromHomeDuration + delayIncrease)
                     .withEndAction(new Runnable() {
                         @Override
                         public void run() {
-                            mThumbnailView.enableTaskBarClip(mHeaderView);
                             // Decrement the post animation trigger
                             ctx.postAnimationTrigger.decrement();
                         }
@@ -434,9 +449,6 @@
             startDelay = delay;
 
         } else {
-            // Otherwise, just enable the thumbnail clip
-            mThumbnailView.enableTaskBarClip(mHeaderView);
-
             // Animate the footer into view
             animateFooterVisibility(true, 0);
         }
@@ -465,13 +477,11 @@
     }
 
     /** Animates this task view as it exits recents */
-    void startLaunchTaskAnimation(final Runnable r, boolean isLaunchingTask,
-            boolean occludesLaunchTarget) {
+    void startLaunchTaskAnimation(final Runnable postAnimRunnable, boolean isLaunchingTask,
+            boolean occludesLaunchTarget, boolean lockToTask) {
         if (isLaunchingTask) {
-            // Disable the thumbnail clip and animate the bar out for the window animation out
-            mHeaderView.startLaunchTaskAnimation(mThumbnailView.disableTaskBarClipAsRunnable(), r);
             // Animate the thumbnail alpha back into full opacity for the window animation out
-            mThumbnailView.startLaunchTaskAnimation();
+            mThumbnailView.startLaunchTaskAnimation(postAnimRunnable);
 
             // Animate the dim
             if (mDim > 0) {
@@ -482,7 +492,14 @@
             }
 
             // Animate the action button away
-            mActionButtonView.animate().alpha(0f)
+            if (!lockToTask) {
+                float toScale = 0.9f;
+                mActionButtonView.animate()
+                        .scaleX(toScale)
+                        .scaleY(toScale);
+            }
+            mActionButtonView.animate()
+                    .alpha(0f)
                     .setStartDelay(0)
                     .setDuration(mConfig.taskBarExitAnimDuration)
                     .setInterpolator(mConfig.fastOutLinearInInterpolator)
@@ -612,6 +629,7 @@
     /** Sets the current task progress. */
     public void setTaskProgress(float p) {
         mTaskProgress = p;
+        mViewBounds.setAlpha(p);
         updateDimFromTaskProgress();
     }
 
@@ -623,17 +641,31 @@
     /** Returns the current dim. */
     public void setDim(int dim) {
         mDim = dim;
-        // Defer setting hardware layers if we have not yet measured, or there is no dim to draw
-        if (getMeasuredWidth() > 0 && getMeasuredHeight() > 0 && dim > 0) {
-            if (mDimAnimator != null) {
-                mDimAnimator.removeAllListeners();
-                mDimAnimator.cancel();
-            }
+        if (mDimAnimator != null) {
+            mDimAnimator.removeAllListeners();
+            mDimAnimator.cancel();
+        }
+        if (mConfig.useHardwareLayers) {
+            // Defer setting hardware layers if we have not yet measured, or there is no dim to draw
+            if (getMeasuredWidth() > 0 && getMeasuredHeight() > 0) {
+                if (mDimAnimator != null) {
+                    mDimAnimator.removeAllListeners();
+                    mDimAnimator.cancel();
+                }
 
-            int inverse = 255 - mDim;
-            mDimColorFilter.setColor(Color.argb(0xFF, inverse, inverse, inverse));
-            mLayerPaint.setColorFilter(mDimColorFilter);
-            setLayerType(LAYER_TYPE_HARDWARE, mLayerPaint);
+                int inverse = 255 - mDim;
+                mDimColorFilter.setColor(Color.argb(0xFF, inverse, inverse, inverse));
+                mLayerPaint.setColorFilter(mDimColorFilter);
+                mContent.setLayerType(LAYER_TYPE_HARDWARE, mLayerPaint);
+            }
+        } else {
+            float dimAlpha = mDim / 255.0f;
+            if (mThumbnailView != null) {
+                mThumbnailView.setDimAlpha(dimAlpha);
+            }
+            if (mHeaderView != null) {
+                mHeaderView.setDimAlpha(dim);
+            }
         }
     }
 
@@ -695,22 +727,30 @@
     }
 
     /**
+     * Unsets the focused task explicitly.
+     */
+    void unsetFocusedTask() {
+        mIsFocused = false;
+        if (mFocusAnimationsEnabled) {
+            // Un-focus the header bar
+            mHeaderView.onTaskViewFocusChanged(false);
+        }
+
+        // Update the thumbnail alpha with the focus
+        mThumbnailView.onFocusChanged(false);
+        // Call the callback
+        mCb.onTaskViewFocusChanged(this, false);
+        invalidate();
+    }
+
+    /**
      * Updates the explicitly focused state when the view focus changes.
      */
     @Override
     protected void onFocusChanged(boolean gainFocus, int direction, Rect previouslyFocusedRect) {
         super.onFocusChanged(gainFocus, direction, previouslyFocusedRect);
         if (!gainFocus) {
-            mIsFocused = false;
-            if (mFocusAnimationsEnabled) {
-                // Un-focus the header bar
-                mHeaderView.onTaskViewFocusChanged(false);
-            }
-            // Update the thumbnail alpha with the focus
-            mThumbnailView.onFocusChanged(false);
-            // Call the callback
-            mCb.onTaskViewFocusChanged(this, false);
-            invalidate();
+            unsetFocusedTask();
         }
     }
 
@@ -818,21 +858,28 @@
 
     @Override
      public void onClick(final View v) {
-        // We purposely post the handler delayed to allow for the touch feedback to draw
         final TaskView tv = this;
-        postDelayed(new Runnable() {
-            @Override
-            public void run() {
-                if (Constants.DebugFlags.App.EnableTaskFiltering && v == mHeaderView.mApplicationIcon) {
-                    mCb.onTaskViewAppIconClicked(tv);
-                } else if (v == mHeaderView.mDismissButton) {
-                    dismissTask();
-                } else {
-                    mCb.onTaskViewClicked(tv, tv.getTask(),
-                            (v == mFooterView || v == mActionButtonView));
+        final boolean delayViewClick = (v != this) && (v != mActionButtonView);
+        if (delayViewClick) {
+            // We purposely post the handler delayed to allow for the touch feedback to draw
+            postDelayed(new Runnable() {
+                @Override
+                public void run() {
+                    if (Constants.DebugFlags.App.EnableTaskFiltering && v == mHeaderView.mApplicationIcon) {
+                        mCb.onTaskViewAppIconClicked(tv);
+                    } else if (v == mHeaderView.mDismissButton) {
+                        dismissTask();
+                    }
                 }
+            }, 125);
+        } else {
+            if (v == mActionButtonView) {
+                // Reset the translation of the action button before we animate it out
+                mActionButtonView.setTranslationZ(0f);
             }
-        }, 125);
+            mCb.onTaskViewClicked(tv, tv.getTask(),
+                    (v == mFooterView || v == mActionButtonView));
+        }
     }
 
     /**** View.OnLongClickListener Implementation ****/
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewHeader.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewHeader.java
index 4b09549..396d441 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewHeader.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewHeader.java
@@ -18,7 +18,9 @@
 
 import android.animation.Animator;
 import android.animation.AnimatorListenerAdapter;
+import android.animation.AnimatorSet;
 import android.animation.ArgbEvaluator;
+import android.animation.ObjectAnimator;
 import android.animation.ValueAnimator;
 import android.content.Context;
 import android.content.res.ColorStateList;
@@ -28,10 +30,13 @@
 import android.graphics.Outline;
 import android.graphics.Paint;
 import android.graphics.PorterDuff;
+import android.graphics.PorterDuffColorFilter;
 import android.graphics.PorterDuffXfermode;
 import android.graphics.drawable.ColorDrawable;
 import android.graphics.drawable.Drawable;
+import android.graphics.drawable.GradientDrawable;
 import android.graphics.drawable.RippleDrawable;
+import android.graphics.drawable.ShapeDrawable;
 import android.util.AttributeSet;
 import android.view.MotionEvent;
 import android.view.View;
@@ -47,7 +52,7 @@
 
 
 /* The task bar view */
-class TaskViewHeader extends FrameLayout {
+public class TaskViewHeader extends FrameLayout {
 
     RecentsConfiguration mConfig;
 
@@ -56,16 +61,20 @@
     TextView mActivityDescription;
 
     RippleDrawable mBackground;
-    ColorDrawable mBackgroundColor;
+    GradientDrawable mBackgroundColorDrawable;
+    int mBackgroundColor;
     Drawable mLightDismissDrawable;
     Drawable mDarkDismissDrawable;
-    ValueAnimator mBackgroundColorAnimator;
+    AnimatorSet mFocusAnimator;
+    ValueAnimator backgroundColorAnimator;
+    PorterDuffColorFilter mDimFilter = new PorterDuffColorFilter(0, PorterDuff.Mode.SRC_ATOP);
 
     boolean mIsFullscreen;
     boolean mCurrentPrimaryColorIsDark;
     int mCurrentPrimaryColor;
 
     static Paint sHighlightPaint;
+    private Paint mDimPaint = new Paint();
 
     public TaskViewHeader(Context context) {
         this(context, null);
@@ -117,6 +126,14 @@
 
     @Override
     protected void onFinishInflate() {
+        // Set the outline provider
+        setOutlineProvider(new ViewOutlineProvider() {
+            @Override
+            public void getOutline(View view, Outline outline) {
+                outline.setRect(0, 0, getMeasuredWidth(), getMeasuredHeight());
+            }
+        });
+
         // Initialize the icon and description views
         mApplicationIcon = (ImageView) findViewById(R.id.application_icon);
         mActivityDescription = (TextView) findViewById(R.id.activity_description);
@@ -129,13 +146,14 @@
             }
         }
 
-        mBackgroundColor = new ColorDrawable(0);
+        mBackgroundColorDrawable = (GradientDrawable) getContext().getDrawable(R.drawable
+                .recents_task_view_header_bg_color);
         // Copy the ripple drawable since we are going to be manipulating it
         mBackground = (RippleDrawable)
-                getResources().getDrawable(R.drawable.recents_task_view_header_bg);
+                getContext().getDrawable(R.drawable.recents_task_view_header_bg);
         mBackground = (RippleDrawable) mBackground.mutate().getConstantState().newDrawable();
         mBackground.setColor(ColorStateList.valueOf(0));
-        mBackground.setDrawableByLayerId(mBackground.getId(0), mBackgroundColor);
+        mBackground.setDrawableByLayerId(mBackground.getId(0), mBackgroundColorDrawable);
         setBackground(mBackground);
     }
 
@@ -145,8 +163,11 @@
             // Draw the highlight at the top edge (but put the bottom edge just out of view)
             float offset = (float) Math.ceil(mConfig.taskViewHighlightPx / 2f);
             float radius = mConfig.taskViewRoundedCornerRadiusPx;
+            int count = canvas.save(Canvas.CLIP_SAVE_FLAG);
+            canvas.clipRect(0, 0, getMeasuredWidth(), getMeasuredHeight());
             canvas.drawRoundRect(-offset, 0f, (float) getMeasuredWidth() + offset,
                     getMeasuredHeight() + radius, radius, radius, sHighlightPaint);
+            canvas.restoreToCount(count);
         }
     }
 
@@ -167,7 +188,7 @@
     }
 
     /** Binds the bar view to the task */
-    void rebindToTask(Task t) {
+    public void rebindToTask(Task t) {
         // If an activity icon is defined, then we use that as the primary icon to show in the bar,
         // otherwise, we fall back to the application icon
         if (t.activityIcon != null) {
@@ -183,7 +204,8 @@
         int existingBgColor = (getBackground() instanceof ColorDrawable) ?
                 ((ColorDrawable) getBackground()).getColor() : 0;
         if (existingBgColor != t.colorPrimary) {
-            mBackgroundColor.setColor(t.colorPrimary);
+            mBackgroundColorDrawable.setColor(t.colorPrimary);
+            mBackgroundColor = t.colorPrimary;
         }
         mCurrentPrimaryColor = t.colorPrimary;
         mCurrentPrimaryColorIsDark = t.useLightOnPrimaryColor;
@@ -201,44 +223,6 @@
         mApplicationIcon.setImageDrawable(null);
     }
 
-    /** Prepares this task view for the enter-recents animations.  This is called earlier in the
-     * first layout because the actual animation into recents may take a long time. */
-    void prepareEnterRecentsAnimation() {
-        setVisibility(View.INVISIBLE);
-    }
-
-    /** Animates this task bar as it enters recents */
-    void startEnterRecentsAnimation(int delay, Runnable postAnimRunnable) {
-        // Animate the task bar of the first task view
-        setVisibility(View.VISIBLE);
-        setTranslationY(-getMeasuredHeight());
-        animate()
-                .translationY(0)
-                .setStartDelay(delay)
-                .setInterpolator(mConfig.fastOutSlowInInterpolator)
-                .setDuration(mConfig.taskBarEnterAnimDuration)
-                .withEndAction(postAnimRunnable)
-                .start();
-    }
-
-    /** Animates this task bar as it exits recents */
-    void startLaunchTaskAnimation(Runnable preAnimRunnable, final Runnable postAnimRunnable) {
-        // Animate the task bar out of the first task view
-        animate()
-                .translationY(-getMeasuredHeight())
-                .setStartDelay(0)
-                .setInterpolator(mConfig.fastOutLinearInInterpolator)
-                .setDuration(mConfig.taskBarExitAnimDuration)
-                .withStartAction(preAnimRunnable)
-                .withEndAction(new Runnable() {
-                    @Override
-                    public void run() {
-                        post(postAnimRunnable);
-                    }
-                })
-                .start();
-    }
-
     /** Animates this task bar dismiss button when launching a task. */
     void startLaunchTaskDismissAnimation() {
         if (mDismissButton.getVisibility() == View.VISIBLE) {
@@ -275,13 +259,21 @@
         }
     }
 
+    @Override
+    protected int[] onCreateDrawableState(int extraSpace) {
+
+        // Don't forward our state to the drawable - we do it manually in onTaskViewFocusChanged.
+        // This is to prevent layer trashing when the view is pressed.
+        return new int[] {};
+    }
+
     /** Notifies the associated TaskView has been focused. */
     void onTaskViewFocusChanged(boolean focused) {
         boolean isRunning = false;
-        if (mBackgroundColorAnimator != null) {
-            isRunning = mBackgroundColorAnimator.isRunning();
-            mBackgroundColorAnimator.removeAllUpdateListeners();
-            mBackgroundColorAnimator.cancel();
+        if (mFocusAnimator != null) {
+            isRunning = mFocusAnimator.isRunning();
+            mFocusAnimator.removeAllListeners();
+            mFocusAnimator.cancel();
         }
         if (focused) {
             int secondaryColor = getSecondaryColor(mCurrentPrimaryColor, mCurrentPrimaryColorIsDark);
@@ -300,45 +292,68 @@
             mBackground.setColor(new ColorStateList(states, colors));
             mBackground.setState(newStates);
             // Pulse the background color
-            int currentColor = mBackgroundColor.getColor();
+            int currentColor = mBackgroundColor;
             int lightPrimaryColor = getSecondaryColor(mCurrentPrimaryColor, mCurrentPrimaryColorIsDark);
-            mBackgroundColorAnimator = ValueAnimator.ofObject(new ArgbEvaluator(), lightPrimaryColor,
-                    currentColor);
-            mBackgroundColorAnimator.addListener(new AnimatorListenerAdapter() {
+            ValueAnimator backgroundColor = ValueAnimator.ofObject(new ArgbEvaluator(),
+                    lightPrimaryColor, currentColor);
+            backgroundColor.addListener(new AnimatorListenerAdapter() {
                 @Override
                 public void onAnimationStart(Animator animation) {
-                    mBackground.setState(new int[] {});
+                    mBackground.setState(new int[]{});
                 }
             });
-            mBackgroundColorAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
+            backgroundColor.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
                 @Override
                 public void onAnimationUpdate(ValueAnimator animation) {
-                    mBackgroundColor.setColor((Integer) animation.getAnimatedValue());
+                    int color = (int) animation.getAnimatedValue();
+                    mBackgroundColorDrawable.setColor(color);
+                    mBackgroundColor = color;
                 }
             });
-            mBackgroundColorAnimator.setRepeatCount(ValueAnimator.INFINITE);
-            mBackgroundColorAnimator.setRepeatMode(ValueAnimator.REVERSE);
-            mBackgroundColorAnimator.setStartDelay(750);
-            mBackgroundColorAnimator.setDuration(750);
-            mBackgroundColorAnimator.start();
+            backgroundColor.setRepeatCount(ValueAnimator.INFINITE);
+            backgroundColor.setRepeatMode(ValueAnimator.REVERSE);
+            // Pulse the translation
+            ObjectAnimator translation = ObjectAnimator.ofFloat(this, "translationZ", 15f);
+            translation.setRepeatCount(ValueAnimator.INFINITE);
+            translation.setRepeatMode(ValueAnimator.REVERSE);
+
+            mFocusAnimator = new AnimatorSet();
+            mFocusAnimator.playTogether(backgroundColor, translation);
+            mFocusAnimator.setStartDelay(750);
+            mFocusAnimator.setDuration(750);
+            mFocusAnimator.start();
         } else {
             if (isRunning) {
                 // Restore the background color
-                int currentColor = mBackgroundColor.getColor();
-                mBackgroundColorAnimator = ValueAnimator.ofObject(new ArgbEvaluator(), currentColor,
-                        mCurrentPrimaryColor);
-                mBackgroundColorAnimator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
+                int currentColor = mBackgroundColor;
+                ValueAnimator backgroundColor = ValueAnimator.ofObject(new ArgbEvaluator(),
+                        currentColor, mCurrentPrimaryColor);
+                backgroundColor.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
                     @Override
                     public void onAnimationUpdate(ValueAnimator animation) {
-                        mBackgroundColor.setColor((Integer) animation.getAnimatedValue());
+                        int color = (int) animation.getAnimatedValue();
+                        mBackgroundColorDrawable.setColor(color);
+                        mBackgroundColor = color;
                     }
                 });
-                mBackgroundColorAnimator.setRepeatCount(0);
-                mBackgroundColorAnimator.setDuration(150);
-                mBackgroundColorAnimator.start();
+                // Restore the translation
+                ObjectAnimator translation = ObjectAnimator.ofFloat(this, "translationZ", 0f);
+
+                mFocusAnimator = new AnimatorSet();
+                mFocusAnimator.playTogether(backgroundColor, translation);
+                mFocusAnimator.setDuration(150);
+                mFocusAnimator.start();
             } else {
                 mBackground.setState(new int[] {});
+                setTranslationZ(0f);
             }
         }
     }
+
+    public void setDimAlpha(int alpha) {
+        int color = Color.argb(alpha, 0, 0, 0);
+        mDimFilter.setColor(color);
+        mDimPaint.setColorFilter(mDimFilter);
+        setLayerType(LAYER_TYPE_HARDWARE, mDimPaint);
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewThumbnail.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewThumbnail.java
index f223bf3..a946a84 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewThumbnail.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewThumbnail.java
@@ -16,9 +16,20 @@
 
 package com.android.systemui.recents.views;
 
+import android.animation.Animator;
+import android.animation.AnimatorListenerAdapter;
+import android.animation.ValueAnimator;
 import android.content.Context;
 import android.graphics.Bitmap;
+import android.graphics.BitmapShader;
+import android.graphics.Canvas;
+import android.graphics.Color;
+import android.graphics.LightingColorFilter;
+import android.graphics.Matrix;
+import android.graphics.Paint;
 import android.graphics.Rect;
+import android.graphics.RectF;
+import android.graphics.Shader;
 import android.util.AttributeSet;
 import android.view.View;
 import com.android.systemui.recents.RecentsConfiguration;
@@ -26,12 +37,32 @@
 
 
 /** The task thumbnail view */
-public class TaskViewThumbnail extends FixedSizeImageView {
+public class TaskViewThumbnail extends View {
 
+    private final int mCornerRadius;
+    private final Matrix mScaleMatrix = new Matrix();
     RecentsConfiguration mConfig;
 
     // Task bar clipping
     Rect mClipRect = new Rect();
+    Paint mDrawPaint = new Paint();
+    LightingColorFilter mLightingColorFilter = new LightingColorFilter(0xffffffff, 0);
+    private final RectF mBitmapRect = new RectF();
+    private final RectF mLayoutRect = new RectF();
+    private BitmapShader mBitmapShader;
+    private float mBitmapAlpha;
+    private float mDimAlpha;
+    private View mTaskBar;
+    private boolean mInvisible;
+    private ValueAnimator mAlphaAnimator;
+    private ValueAnimator.AnimatorUpdateListener mAlphaUpdateListener
+            = new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            mBitmapAlpha = (float) animation.getAnimatedValue();
+            updateFilter();
+        }
+    };
 
     public TaskViewThumbnail(Context context) {
         this(context, null);
@@ -48,50 +79,75 @@
     public TaskViewThumbnail(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
         super(context, attrs, defStyleAttr, defStyleRes);
         mConfig = RecentsConfiguration.getInstance();
-        setScaleType(ScaleType.FIT_XY);
+        mCornerRadius = mConfig.taskViewRoundedCornerRadiusPx;
+        mDrawPaint.setColorFilter(mLightingColorFilter);
+        mDrawPaint.setFilterBitmap(true);
+        mDrawPaint.setAntiAlias(true);
+    }
+
+    @Override
+    protected void onDraw(Canvas canvas) {
+        if (mInvisible) {
+            return;
+        }
+        canvas.drawRoundRect(0,
+                0,
+                getWidth(),
+                getHeight(),
+                mCornerRadius,
+                mCornerRadius,
+                mDrawPaint);
     }
 
     @Override
     protected void onFinishInflate() {
-        setAlpha(0.9f);
+        mBitmapAlpha = 0.9f;
+        updateFilter();
+    }
+
+    private void updateFilter() {
+        if (mInvisible) {
+            return;
+        }
+        int mul = (int) ((1.0f - mDimAlpha) * mBitmapAlpha * 255);
+        int add = (int) ((1.0f - mDimAlpha) * (1 - mBitmapAlpha) * 255);
+        if (mBitmapShader != null) {
+            mLightingColorFilter.setColorMultiply(Color.argb(255, mul, mul, mul));
+            mLightingColorFilter.setColorAdd(Color.argb(0, add, add, add));
+            mDrawPaint.setColorFilter(mLightingColorFilter);
+            mDrawPaint.setColor(0xffffffff);
+        } else {
+            mDrawPaint.setColorFilter(null);
+            int grey = mul + add;
+            mDrawPaint.setColor(Color.argb(255, grey, grey, grey));
+        }
+        invalidate();
     }
 
     /** Updates the clip rect based on the given task bar. */
     void enableTaskBarClip(View taskBar) {
+        mTaskBar = taskBar;
         int top = (int) Math.max(0, taskBar.getTranslationY() +
                 taskBar.getMeasuredHeight() - 1);
         mClipRect.set(0, top, getMeasuredWidth(), getMeasuredHeight());
         setClipBounds(mClipRect);
     }
 
-    /** Convenience method to enable task bar clipping as a runnable. */
-    Runnable enableTaskBarClipAsRunnable(final View taskBar) {
-        return new Runnable() {
-            @Override
-            public void run() {
-                enableTaskBarClip(taskBar);
+    void updateVisibility(int clipBottom) {
+        boolean invisible = mTaskBar != null && getHeight() - clipBottom < mTaskBar.getHeight();
+        if (invisible != mInvisible) {
+            mInvisible = invisible;
+            if (!mInvisible) {
+                updateFilter();
             }
-        };
-    }
-
-    /** Disables the task bar clipping. */
-    Runnable disableTaskBarClipAsRunnable() {
-        return new Runnable() {
-            @Override
-            public void run() {
-                mClipRect.set(0, 0, getMeasuredWidth(), getMeasuredHeight());
-                setClipBounds(mClipRect);
-            }
-        };
+            invalidate();
+        }
     }
 
     /** Binds the thumbnail view to the screenshot. */
     boolean bindToScreenshot(Bitmap ss) {
-        if (ss != null) {
-            setImageBitmap(ss);
-            return true;
-        }
-        return false;
+        setImageBitmap(ss);
+        return ss != null;
     }
 
     /** Unbinds the thumbnail view from the screenshot. */
@@ -103,12 +159,49 @@
     void rebindToTask(Task t) {
         if (t.thumbnail != null) {
             setImageBitmap(t.thumbnail);
+        } else {
+            setImageBitmap(null);
         }
     }
 
+    public void setImageBitmap(Bitmap bm) {
+        if (bm != null) {
+            mBitmapShader = new BitmapShader(bm, Shader.TileMode.CLAMP,
+                    Shader.TileMode.CLAMP);
+            mDrawPaint.setShader(mBitmapShader);
+            mBitmapRect.set(0, 0, bm.getWidth(), bm.getHeight());
+            updateBitmapScale();
+        } else {
+            mBitmapShader = null;
+            mDrawPaint.setShader(null);
+        }
+        updateFilter();
+    }
+
+    @Override
+    protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
+        super.onLayout(changed, left, top, right, bottom);
+        if (changed) {
+            mLayoutRect.set(0, 0, getWidth(), getHeight());
+            updateBitmapScale();
+        }
+    }
+
+    private void updateBitmapScale() {
+        if (mBitmapShader != null) {
+            mScaleMatrix.setRectToRect(mBitmapRect, mLayoutRect, Matrix.ScaleToFit.FILL);
+            mBitmapShader.setLocalMatrix(mScaleMatrix);
+        }
+    }
+
+    public void setDimAlpha(float dimAlpha) {
+        mDimAlpha = dimAlpha;
+        updateFilter();
+    }
+
     /** Unbinds the thumbnail view from the task */
     void unbindFromTask() {
-        setImageDrawable(null);
+        setImageBitmap(null);
     }
 
     /** Handles focus changes. */
@@ -127,10 +220,11 @@
     /** Prepares for the enter recents animation. */
     void prepareEnterRecentsAnimation(boolean isTaskViewLaunchTargetTask) {
         if (isTaskViewLaunchTargetTask) {
-            setAlpha(1f);
+            mBitmapAlpha = 1f;
         } else {
-            setAlpha(mConfig.taskViewThumbnailAlpha);
+            mBitmapAlpha = mConfig.taskViewThumbnailAlpha;
         }
+        updateFilter();
     }
 
     /** Animates this task thumbnail as it enters recents */
@@ -140,21 +234,37 @@
     }
 
     /** Animates this task thumbnail as it exits recents */
-    void startLaunchTaskAnimation() {
-        startFadeAnimation(1f, 0, mConfig.taskBarExitAnimDuration, null);
+    void startLaunchTaskAnimation(Runnable postAnimRunnable) {
+        startFadeAnimation(1f, 0, mConfig.taskBarExitAnimDuration, postAnimRunnable);
     }
 
     /** Animates the thumbnail alpha. */
-    void startFadeAnimation(float finalAlpha, int delay, int duration, Runnable postAnimRunnable) {
-        if (postAnimRunnable != null) {
-            animate().withEndAction(postAnimRunnable);
+    void startFadeAnimation(float finalAlpha, int delay, int duration, final Runnable postAnimRunnable) {
+        if (mAlphaAnimator != null) {
+            mAlphaAnimator.cancel();
         }
-        animate()
-                .alpha(finalAlpha)
-                .setStartDelay(delay)
-                .setInterpolator(mConfig.fastOutSlowInInterpolator)
-                .setDuration(duration)
-                .withLayer()
-                .start();
+        mAlphaAnimator = ValueAnimator.ofFloat(mBitmapAlpha, finalAlpha);
+        mAlphaAnimator.addUpdateListener(mAlphaUpdateListener);
+        mAlphaAnimator.setStartDelay(delay);
+        mAlphaAnimator.setInterpolator(mConfig.fastOutSlowInInterpolator);
+        mAlphaAnimator.setDuration(duration);
+        mAlphaAnimator.start();
+        if (postAnimRunnable != null) {
+            mAlphaAnimator.addListener(new AnimatorListenerAdapter() {
+                public boolean mCancelled;
+
+                @Override
+                public void onAnimationCancel(Animator animation) {
+                    mCancelled = true;
+                }
+
+                @Override
+                public void onAnimationEnd(Animator animation) {
+                    if (!mCancelled) {
+                        postAnimRunnable.run();
+                    }
+                }
+            });
+        }
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewTransform.java b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewTransform.java
index ce2e80b..42c0f9f 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewTransform.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/TaskViewTransform.java
@@ -77,7 +77,8 @@
     }
 
     /** Applies this transform to a view. */
-    public void applyToTaskView(View v, int duration, Interpolator interp, boolean allowLayers) {
+    public void applyToTaskView(View v, int duration, Interpolator interp, boolean allowLayers,
+            boolean allowShadows, ValueAnimator.AnimatorUpdateListener updateCallback) {
         // Check to see if any properties have changed, and update the task view
         if (duration > 0) {
             ViewPropertyAnimator anim = v.animate();
@@ -87,8 +88,7 @@
             if (hasTranslationYChangedFrom(v.getTranslationY())) {
                 anim.translationY(translationY);
             }
-            if (Constants.DebugFlags.App.EnableShadows &&
-                    hasTranslationZChangedFrom(v.getTranslationZ())) {
+            if (allowShadows && hasTranslationZChangedFrom(v.getTranslationZ())) {
                 anim.translationZ(translationZ);
             }
             if (hasScaleChangedFrom(v.getScaleX())) {
@@ -104,6 +104,11 @@
             if (requiresLayers && allowLayers) {
                 anim.withLayer();
             }
+            if (updateCallback != null) {
+                anim.setUpdateListener(updateCallback);
+            } else {
+                anim.setUpdateListener(null);
+            }
             anim.setStartDelay(startDelay)
                     .setDuration(duration)
                     .setInterpolator(interp)
@@ -113,8 +118,7 @@
             if (hasTranslationYChangedFrom(v.getTranslationY())) {
                 v.setTranslationY(translationY);
             }
-            if (Constants.DebugFlags.App.EnableShadows &&
-                    hasTranslationZChangedFrom(v.getTranslationZ())) {
+            if (allowShadows && hasTranslationZChangedFrom(v.getTranslationZ())) {
                 v.setTranslationZ(translationZ);
             }
             if (hasScaleChangedFrom(v.getScaleX())) {
@@ -131,9 +135,7 @@
     public static void reset(View v) {
         v.setTranslationX(0f);
         v.setTranslationY(0f);
-        if (Constants.DebugFlags.App.EnableShadows) {
-            v.setTranslationZ(0f);
-        }
+        v.setTranslationZ(0f);
         v.setScaleX(1f);
         v.setScaleY(1f);
         v.setAlpha(1f);
diff --git a/packages/SystemUI/src/com/android/systemui/recents/views/ViewAnimation.java b/packages/SystemUI/src/com/android/systemui/recents/views/ViewAnimation.java
index a1fc40f..4586f12 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/views/ViewAnimation.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/views/ViewAnimation.java
@@ -16,6 +16,7 @@
 
 package com.android.systemui.recents.views;
 
+import android.animation.ValueAnimator;
 import android.graphics.Rect;
 import com.android.systemui.recents.misc.ReferenceCountedTrigger;
 
@@ -27,6 +28,8 @@
         // A trigger to run some logic when all the animations complete.  This works around the fact
         // that it is difficult to coordinate ViewPropertyAnimators
         ReferenceCountedTrigger postAnimationTrigger;
+        // An update listener to notify as the enter animation progresses (used for the home transition)
+        ValueAnimator.AnimatorUpdateListener updateListener;
 
         // These following properties are updated for each task view we start the enter animation on
 
diff --git a/packages/SystemUI/src/com/android/systemui/screenshot/GlobalScreenshot.java b/packages/SystemUI/src/com/android/systemui/screenshot/GlobalScreenshot.java
index d4c8ce3..d9fea47 100644
--- a/packages/SystemUI/src/com/android/systemui/screenshot/GlobalScreenshot.java
+++ b/packages/SystemUI/src/com/android/systemui/screenshot/GlobalScreenshot.java
@@ -164,7 +164,8 @@
             .setContentTitle(r.getString(R.string.screenshot_saving_title))
             .setContentText(r.getString(R.string.screenshot_saving_text))
             .setSmallIcon(R.drawable.stat_notify_image)
-            .setWhen(now);
+            .setWhen(now)
+            .setColor(r.getColor(com.android.internal.R.color.system_notification_accent_color));
 
         mNotificationStyle = new Notification.BigPictureStyle()
             .bigPicture(preview);
@@ -177,7 +178,9 @@
                 .setContentText(r.getString(R.string.screenshot_saving_text))
                 .setSmallIcon(R.drawable.stat_notify_image)
                 .setCategory(Notification.CATEGORY_PROGRESS)
-                .setWhen(now);
+                .setWhen(now)
+                .setColor(r.getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
 
         mNotificationBuilder.setPublicVersion(mPublicNotificationBuilder.build());
 
@@ -304,7 +307,9 @@
                 .setContentText(r.getString(R.string.screenshot_saved_text))
                 .setContentIntent(PendingIntent.getActivity(params.context, 0, launchIntent, 0))
                 .setWhen(now)
-                .setAutoCancel(true);
+                .setAutoCancel(true)
+                .setColor(r.getColor(
+                        com.android.internal.R.color.system_notification_accent_color));;
 
             // Update the text in the public version as well
             mPublicNotificationBuilder
@@ -312,7 +317,9 @@
                 .setContentText(r.getString(R.string.screenshot_saved_text))
                 .setContentIntent(PendingIntent.getActivity(params.context, 0, launchIntent, 0))
                 .setWhen(now)
-                .setAutoCancel(true);
+                .setAutoCancel(true)
+                .setColor(r.getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
 
             mNotificationBuilder.setPublicVersion(mPublicNotificationBuilder.build());
 
@@ -717,7 +724,9 @@
             .setWhen(System.currentTimeMillis())
             .setVisibility(Notification.VISIBILITY_PUBLIC) // ok to show outside lockscreen
             .setCategory(Notification.CATEGORY_ERROR)
-            .setAutoCancel(true);
+            .setAutoCancel(true)
+            .setColor(context.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
         Notification n =
             new Notification.BigTextStyle(b)
                 .bigText(r.getString(R.string.screenshot_failed_text))
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ActivatableNotificationView.java b/packages/SystemUI/src/com/android/systemui/statusbar/ActivatableNotificationView.java
index ca290e4..c869ba4 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ActivatableNotificationView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ActivatableNotificationView.java
@@ -88,6 +88,9 @@
             = new PathInterpolator(0.6f, 0, 0.5f, 1);
     private static final Interpolator ACTIVATE_INVERSE_ALPHA_INTERPOLATOR
             = new PathInterpolator(0, 0, 0.5f, 1);
+    private final int mTintedRippleColor;
+    private final int mLowPriorityRippleColor;
+    private final int mNormalRippleColor;
 
     private boolean mDimmed;
     private boolean mDark;
@@ -118,7 +121,6 @@
 
     private NotificationBackgroundView mBackgroundNormal;
     private NotificationBackgroundView mBackgroundDimmed;
-    private NotificationScrimView mScrimView;
     private ObjectAnimator mBackgroundAnimator;
     private RectF mAppearAnimationRect = new RectF();
     private PorterDuffColorFilter mAppearAnimationFilter;
@@ -153,6 +155,12 @@
         mNormalColor = getResources().getColor(R.color.notification_material_background_color);
         mLowPriorityColor = getResources().getColor(
                 R.color.notification_material_background_low_priority_color);
+        mTintedRippleColor = context.getResources().getColor(
+                R.color.notification_ripple_tinted_color);
+        mLowPriorityRippleColor = context.getResources().getColor(
+                R.color.notification_ripple_color_low_priority);
+        mNormalRippleColor = context.getResources().getColor(
+                R.color.notification_ripple_untinted_color);
     }
 
     @Override
@@ -164,8 +172,6 @@
         mBackgroundDimmed.setCustomBackground(R.drawable.notification_material_bg_dim);
         updateBackground();
         updateBackgroundTint();
-        mScrimView = (NotificationScrimView) findViewById(R.id.scrim_view);
-        setScrimAmount(0);
     }
 
     private final Runnable mTapTimeoutRunnable = new Runnable() {
@@ -191,6 +197,16 @@
         }
     }
 
+    @Override
+    protected void drawableStateChanged() {
+        super.drawableStateChanged();
+        if (mDimmed) {
+            mBackgroundDimmed.setState(getDrawableState());
+        } else {
+            mBackgroundNormal.setState(getDrawableState());
+        }
+    }
+
     private boolean handleTouchEventDimmed(MotionEvent event) {
         int action = event.getActionMasked();
         switch (action) {
@@ -243,9 +259,14 @@
         int widthHalf = mBackgroundNormal.getWidth()/2;
         int heightHalf = mBackgroundNormal.getActualHeight()/2;
         float radius = (float) Math.sqrt(widthHalf*widthHalf + heightHalf*heightHalf);
-        Animator animator =
-                ViewAnimationUtils.createCircularReveal(mBackgroundNormal,
-                        widthHalf, heightHalf, 0, radius);
+        Animator animator;
+        if (reverse) {
+            animator = ViewAnimationUtils.createCircularReveal(mBackgroundNormal,
+                    widthHalf, heightHalf, radius, 0);
+        } else {
+            animator = ViewAnimationUtils.createCircularReveal(mBackgroundNormal,
+                    widthHalf, heightHalf, 0, radius);
+        }
         mBackgroundNormal.setVisibility(View.VISIBLE);
         Interpolator interpolator;
         Interpolator alphaInterpolator;
@@ -268,7 +289,7 @@
                     }
                 }
             });
-            animator.reverse();
+            animator.start();
         } else {
             mBackgroundNormal.setAlpha(0.4f);
             animator.start();
@@ -367,12 +388,15 @@
 
     private void updateBackgroundTint() {
         int color = getBackgroundColor();
+        int rippleColor = getRippleColor();
         if (color == mNormalColor) {
             // We don't need to tint a normal notification
             color = 0;
         }
         mBackgroundDimmed.setTint(color);
         mBackgroundNormal.setTint(color);
+        mBackgroundDimmed.setRippleColor(rippleColor);
+        mBackgroundNormal.setRippleColor(rippleColor);
     }
 
     private void fadeBackground() {
@@ -438,7 +462,6 @@
         setPivotY(actualHeight / 2);
         mBackgroundNormal.setActualHeight(actualHeight);
         mBackgroundDimmed.setActualHeight(actualHeight);
-        mScrimView.setActualHeight(actualHeight);
     }
 
     @Override
@@ -446,7 +469,6 @@
         super.setClipTopAmount(clipTopAmount);
         mBackgroundNormal.setClipTopAmount(clipTopAmount);
         mBackgroundDimmed.setClipTopAmount(clipTopAmount);
-        mScrimView.setClipTopAmount(clipTopAmount);
     }
 
     @Override
@@ -456,6 +478,8 @@
         if (mDrawingAppearAnimation) {
             startAppearAnimation(false /* isAppearing */, translationDirection,
                     0, duration, onFinishedRunnable);
+        } else if (onFinishedRunnable != null) {
+            onFinishedRunnable.run();
         }
     }
 
@@ -467,11 +491,6 @@
         }
     }
 
-    @Override
-    public void setScrimAmount(float scrimAmount) {
-        mScrimView.setAlpha(scrimAmount);
-    }
-
     private void startAppearAnimation(boolean isAppearing, float translationDirection, long delay,
             long duration, final Runnable onFinishedRunnable) {
         if (mAppearAnimator != null) {
@@ -611,6 +630,18 @@
         }
     }
 
+    private int getRippleColor() {
+        if (mBgTint != 0) {
+            return mTintedRippleColor;
+        } else if (mShowingLegacyBackground) {
+            return mTintedRippleColor;
+        } else if (mIsBelowSpeedBump) {
+            return mLowPriorityRippleColor;
+        } else {
+            return mNormalRippleColor;
+        }
+    }
+
     /**
      * When we draw the appear animation, we render the view in a bitmap and render this bitmap
      * as a shader of a rect. This call creates the Bitmap and switches the drawing mode,
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/AlphaOptimizedLinearLayout.java b/packages/SystemUI/src/com/android/systemui/statusbar/AlphaOptimizedLinearLayout.java
deleted file mode 100644
index 9f4c3a9..0000000
--- a/packages/SystemUI/src/com/android/systemui/statusbar/AlphaOptimizedLinearLayout.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Copyright (C) 2014 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.systemui.statusbar;
-
-import android.content.Context;
-import android.util.AttributeSet;
-import android.view.View;
-import android.widget.LinearLayout;
-
-/**
- * A linear layout which does not have overlapping renderings commands and therefore does not need a
- * layer when alpha is changed.
- */
-public class AlphaOptimizedLinearLayout extends LinearLayout
-{
-    public AlphaOptimizedLinearLayout(Context context) {
-        super(context);
-    }
-
-    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs) {
-        super(context, attrs);
-    }
-
-    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs, int defStyleAttr) {
-        super(context, attrs, defStyleAttr);
-    }
-
-    public AlphaOptimizedLinearLayout(Context context, AttributeSet attrs, int defStyleAttr,
-            int defStyleRes) {
-        super(context, attrs, defStyleAttr, defStyleRes);
-    }
-
-    @Override
-    public boolean hasOverlappingRendering() {
-        return false;
-    }
-}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
index 53bdcbf..aa75fd4 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/BaseStatusBar.java
@@ -21,8 +21,8 @@
 import android.animation.TimeInterpolator;
 import android.app.ActivityManager;
 import android.app.ActivityManagerNative;
-import android.app.ActivityThread;
 import android.app.Notification;
+import android.app.NotificationManager;
 import android.app.PendingIntent;
 import android.app.TaskStackBuilder;
 import android.app.admin.DevicePolicyManager;
@@ -32,16 +32,15 @@
 import android.content.Intent;
 import android.content.IntentFilter;
 import android.content.pm.ApplicationInfo;
-import android.content.pm.IPackageManager;
-import android.content.pm.PackageInfo;
 import android.content.pm.PackageManager;
 import android.content.pm.PackageManager.NameNotFoundException;
+import android.content.pm.ResolveInfo;
 import android.content.pm.UserInfo;
 import android.content.res.Configuration;
+import android.content.res.Resources;
 import android.database.ContentObserver;
-import android.graphics.Rect;
+import android.graphics.PorterDuff;
 import android.graphics.drawable.Drawable;
-import android.net.Uri;
 import android.os.AsyncTask;
 import android.os.Build;
 import android.os.Handler;
@@ -70,8 +69,10 @@
 import android.view.ViewAnimationUtils;
 import android.view.ViewGroup;
 import android.view.ViewGroup.LayoutParams;
+import android.view.ViewStub;
 import android.view.WindowManager;
 import android.view.WindowManagerGlobal;
+import android.view.accessibility.AccessibilityManager;
 import android.view.animation.AnimationUtils;
 import android.widget.DateTimeView;
 import android.widget.ImageView;
@@ -83,6 +84,7 @@
 import com.android.internal.statusbar.StatusBarIcon;
 import com.android.internal.statusbar.StatusBarIconList;
 import com.android.internal.util.NotificationColorUtil;
+import com.android.internal.widget.LockPatternUtils;
 import com.android.systemui.R;
 import com.android.systemui.RecentsComponent;
 import com.android.systemui.SearchPanelView;
@@ -90,11 +92,15 @@
 import com.android.systemui.SystemUI;
 import com.android.systemui.statusbar.NotificationData.Entry;
 import com.android.systemui.statusbar.phone.KeyguardTouchDelegate;
+import com.android.systemui.statusbar.phone.PhoneStatusBar;
+import com.android.systemui.statusbar.phone.NavigationBarView;
 import com.android.systemui.statusbar.phone.StatusBarKeyguardViewManager;
 import com.android.systemui.statusbar.policy.HeadsUpNotificationView;
+import com.android.systemui.statusbar.policy.PreviewInflater;
 import com.android.systemui.statusbar.stack.NotificationStackScrollLayout;
 
 import java.util.ArrayList;
+import java.util.List;
 import java.util.Locale;
 
 import static com.android.keyguard.KeyguardHostView.OnDismissAction;
@@ -114,7 +120,6 @@
     protected static final int MSG_CANCEL_PRELOAD_RECENT_APPS = 1023;
     protected static final int MSG_SHOW_NEXT_AFFILIATED_TASK = 1024;
     protected static final int MSG_SHOW_PREV_AFFILIATED_TASK = 1025;
-    protected static final int MSG_OPEN_SEARCH_PANEL = 1026;
     protected static final int MSG_CLOSE_SEARCH_PANEL = 1027;
     protected static final int MSG_SHOW_HEADS_UP = 1028;
     protected static final int MSG_HIDE_HEADS_UP = 1029;
@@ -132,6 +137,12 @@
     public static final int EXPANDED_LEAVE_ALONE = -10000;
     public static final int EXPANDED_FULL_OPEN = -10001;
 
+    private static final int HIDDEN_NOTIFICATION_ID = 10000;
+    private static final String BANNER_ACTION_CANCEL =
+            "com.android.systemui.statusbar.banner_action_cancel";
+    private static final String BANNER_ACTION_SETUP =
+            "com.android.systemui.statusbar.banner_action_setup";
+
     protected CommandQueue mCommandQueue;
     protected IStatusBarService mBarService;
     protected H mHandler = createHandler();
@@ -154,6 +165,10 @@
     final protected SparseArray<UserInfo> mCurrentProfiles = new SparseArray<UserInfo>();
 
     protected int mLayoutDirection = -1; // invalid
+    protected AccessibilityManager mAccessibilityManager;
+
+    // on-screen navigation buttons
+    protected NavigationBarView mNavigationBarView = null;
     private Locale mLocale;
     private float mFontScale;
 
@@ -171,7 +186,7 @@
     // public mode, private notifications, etc
     private boolean mLockscreenPublicMode = false;
     private final SparseBooleanArray mUsersAllowingPrivateNotifications = new SparseBooleanArray();
-    private NotificationColorUtil mNotificationColorUtil = NotificationColorUtil.getInstance();
+    private NotificationColorUtil mNotificationColorUtil;
 
     private UserManager mUserManager;
 
@@ -197,7 +212,7 @@
     protected int mZenMode;
 
     // which notification is currently being longpress-examined by the user
-    private View mNotificationGutsExposed;
+    private NotificationGuts mNotificationGutsExposed;
 
     private TimeInterpolator mLinearOutSlowIn, mFastOutLinearIn;
 
@@ -255,10 +270,12 @@
             final boolean isActivity = pendingIntent.isActivity();
             if (isActivity) {
                 final boolean keyguardShowing = mStatusBarKeyguardViewManager.isShowing();
+                final boolean afterKeyguardGone = PreviewInflater.wouldLaunchResolverActivity(
+                        mContext, pendingIntent.getIntent(), mCurrentUserId);
                 dismissKeyguardThenExecute(new OnDismissAction() {
                     @Override
                     public boolean onDismiss() {
-                        if (keyguardShowing) {
+                        if (keyguardShowing && !afterKeyguardGone) {
                             try {
                                 ActivityManagerNative.getDefault()
                                         .keyguardWaitingForActivityDrawn();
@@ -272,17 +289,21 @@
                         }
 
                         boolean handled = superOnClickHandler(view, pendingIntent, fillInIntent);
-                        overrideActivityPendingAppTransition(keyguardShowing);
+                        overrideActivityPendingAppTransition(keyguardShowing && !afterKeyguardGone);
 
                         // close the shade if it was open
                         if (handled) {
+                            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                                Log.i(TAG, "Collapsing panel from mOnClickHandler after keyguard"
+                                        + "dismiss");
+                            }
                             animateCollapsePanels(CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
                             visibilityChanged(false);
                         }
                         // Wait for activity start.
                         return handled;
                     }
-                });
+                }, afterKeyguardGone);
                 return true;
             } else {
                 return super.onClickHandler(view, pendingIntent, fillInIntent);
@@ -314,6 +335,23 @@
                 mUsersAllowingPrivateNotifications.clear();
                 updateLockscreenNotificationSetting();
                 updateNotifications();
+            } else if (BANNER_ACTION_CANCEL.equals(action) || BANNER_ACTION_SETUP.equals(action)) {
+                NotificationManager noMan = (NotificationManager)
+                        mContext.getSystemService(Context.NOTIFICATION_SERVICE);
+                noMan.cancel(HIDDEN_NOTIFICATION_ID);
+
+                Settings.Secure.putInt(mContext.getContentResolver(),
+                        Settings.Secure.SHOW_NOTE_ABOUT_NOTIFICATION_HIDING, 0);
+                if (BANNER_ACTION_SETUP.equals(action)) {
+                    if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                        Log.i(TAG, "Animating collapse because of BANNER_ACTION_SETUP");
+                    }
+                    animateCollapsePanels(CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
+                    mContext.startActivity(new Intent(Settings.ACTION_APP_NOTIFICATION_REDACTION)
+                            .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK)
+
+                    );
+                }
             }
         }
     };
@@ -345,6 +383,24 @@
                     Notification n = sbn.getNotification();
                     boolean isUpdate = mNotificationData.get(sbn.getKey()) != null
                             || isHeadsUp(sbn.getKey());
+
+                    // Ignore children of notifications that have a summary, since we're not
+                    // going to show them anyway. This is true also when the summary is canceled,
+                    // because children are automatically canceled by NoMan in that case.
+                    if (n.isGroupChild() &&
+                            mNotificationData.isGroupWithSummary(sbn.getGroupKey())) {
+                        if (DEBUG) {
+                            Log.d(TAG, "Ignoring group child due to existing summary: " + sbn);
+                        }
+
+                        // Remove existing notification to avoid stale data.
+                        if (isUpdate) {
+                            removeNotification(sbn.getKey(), rankingMap);
+                        } else {
+                            mNotificationData.updateRanking(rankingMap);
+                        }
+                        return;
+                    }
                     if (isUpdate) {
                         updateNotification(sbn, rankingMap);
                     } else {
@@ -397,8 +453,13 @@
         mDevicePolicyManager = (DevicePolicyManager)mContext.getSystemService(
                 Context.DEVICE_POLICY_SERVICE);
 
+        mNotificationColorUtil = NotificationColorUtil.getInstance(mContext);
+
         mNotificationData = new NotificationData(this);
 
+        mAccessibilityManager = (AccessibilityManager)
+                mContext.getSystemService(Context.ACCESSIBILITY_SERVICE);
+
         mDreamManager = IDreamManager.Stub.asInterface(
                 ServiceManager.checkService(DreamService.DREAM_SERVICE));
         mPowerManager = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
@@ -496,12 +557,63 @@
         IntentFilter filter = new IntentFilter();
         filter.addAction(Intent.ACTION_USER_SWITCHED);
         filter.addAction(Intent.ACTION_USER_ADDED);
+        filter.addAction(BANNER_ACTION_CANCEL);
+        filter.addAction(BANNER_ACTION_SETUP);
         filter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED);
         mContext.registerReceiver(mBroadcastReceiver, filter);
 
         updateCurrentProfilesCache();
     }
 
+    protected void notifyUserAboutHiddenNotifications() {
+        if (0 != Settings.Secure.getInt(mContext.getContentResolver(),
+                Settings.Secure.SHOW_NOTE_ABOUT_NOTIFICATION_HIDING, 1)) {
+            Log.d(TAG, "user hasn't seen notification about hidden notifications");
+            final LockPatternUtils lockPatternUtils = new LockPatternUtils(mContext);
+            if (!lockPatternUtils.isSecure()) {
+                Log.d(TAG, "insecure lockscreen, skipping notification");
+                Settings.Secure.putInt(mContext.getContentResolver(),
+                        Settings.Secure.SHOW_NOTE_ABOUT_NOTIFICATION_HIDING, 0);
+                return;
+            }
+            Log.d(TAG, "disabling lockecreen notifications and alerting the user");
+            // disable lockscreen notifications until user acts on the banner.
+            Settings.Secure.putInt(mContext.getContentResolver(),
+                    Settings.Secure.LOCK_SCREEN_SHOW_NOTIFICATIONS, 0);
+            Settings.Secure.putInt(mContext.getContentResolver(),
+                    Settings.Secure.LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS, 0);
+
+            final String packageName = mContext.getPackageName();
+            PendingIntent cancelIntent = PendingIntent.getBroadcast(mContext, 0,
+                    new Intent(BANNER_ACTION_CANCEL).setPackage(packageName),
+                    PendingIntent.FLAG_CANCEL_CURRENT);
+            PendingIntent setupIntent = PendingIntent.getBroadcast(mContext, 0,
+                    new Intent(BANNER_ACTION_SETUP).setPackage(packageName),
+                    PendingIntent.FLAG_CANCEL_CURRENT);
+
+            final Resources res = mContext.getResources();
+            final int colorRes = com.android.internal.R.color.system_notification_accent_color;
+            Notification.Builder note = new Notification.Builder(mContext)
+                    .setSmallIcon(R.drawable.ic_android)
+                    .setContentTitle(mContext.getString(R.string.hidden_notifications_title))
+                    .setContentText(mContext.getString(R.string.hidden_notifications_text))
+                    .setPriority(Notification.PRIORITY_HIGH)
+                    .setOngoing(true)
+                    .setColor(res.getColor(colorRes))
+                    .setContentIntent(setupIntent)
+                    .addAction(R.drawable.ic_close,
+                            mContext.getString(R.string.hidden_notifications_cancel),
+                            cancelIntent)
+                    .addAction(R.drawable.ic_settings,
+                            mContext.getString(R.string.hidden_notifications_setup),
+                            setupIntent);
+
+            NotificationManager noMan =
+                    (NotificationManager) mContext.getSystemService(Context.NOTIFICATION_SERVICE);
+            noMan.notify(HIDDEN_NOTIFICATION_ID, note.build());
+        }
+    }
+
     public void userSwitched(int newUserId) {
         // should be overridden
     }
@@ -524,11 +636,17 @@
         }
     }
 
+    @Override
+    public String getCurrentMediaNotificationKey() {
+        return null;
+    }
+
     /**
      * Takes the necessary steps to prepare the status bar for starting an activity, then starts it.
      * @param action A dismiss action that is called if it's safe to start the activity.
+     * @param afterKeyguardGone Whether the action should be executed after the Keyguard is gone.
      */
-    protected void dismissKeyguardThenExecute(OnDismissAction action) {
+    protected void dismissKeyguardThenExecute(OnDismissAction action, boolean afterKeyguardGone) {
         action.onDismiss();
     }
 
@@ -580,19 +698,13 @@
     }
 
 
-    protected void applyLegacyRowBackground(StatusBarNotification sbn,
+    protected void applyColorsAndBackgrounds(StatusBarNotification sbn,
             NotificationData.Entry entry) {
-        int version = 0;
-        try {
-            ApplicationInfo info = mContext.getPackageManager().getApplicationInfo(sbn.getPackageName(), 0);
-            version = info.targetSdkVersion;
-        } catch (NameNotFoundException ex) {
-            Log.e(TAG, "Failed looking up ApplicationInfo for " + sbn.getPackageName(), ex);
-        }
 
         if (entry.expanded.getId() != com.android.internal.R.id.status_bar_latest_event_content) {
             // Using custom RemoteViews
-            if (version >= Build.VERSION_CODES.GINGERBREAD && version < Build.VERSION_CODES.L) {
+            if (entry.targetSdk >= Build.VERSION_CODES.GINGERBREAD
+                    && entry.targetSdk < Build.VERSION_CODES.L) {
                 entry.row.setShowingLegacyBackground(true);
                 entry.legacy = true;
             }
@@ -600,7 +712,18 @@
             // Using platform templates
             final int color = sbn.getNotification().color;
             if (isMediaNotification(entry)) {
-                entry.row.setTintColor(color);
+                entry.row.setTintColor(color == Notification.COLOR_DEFAULT
+                        ? mContext.getResources().getColor(
+                                R.color.notification_material_background_media_default_color)
+                        : color);
+            }
+        }
+
+        if (entry.icon != null) {
+            if (entry.targetSdk >= Build.VERSION_CODES.L) {
+                entry.icon.setColorFilter(mContext.getResources().getColor(android.R.color.white));
+            } else {
+                entry.icon.setColorFilter(null);
             }
         }
     }
@@ -608,15 +731,127 @@
     public boolean isMediaNotification(NotificationData.Entry entry) {
         // TODO: confirm that there's a valid media key
         return entry.expandedBig != null &&
-               entry.expandedBig.findViewById(com.android.internal.R.id.media_action_area) != null;
+               entry.expandedBig.findViewById(com.android.internal.R.id.media_actions) != null;
     }
 
-    private void startAppNotificationSettingsActivity(String packageName, int appUid) {
-        Intent intent = new Intent(Settings.ACTION_APP_NOTIFICATION_SETTINGS);
+    // The gear button in the guts that links to the app's own notification settings
+    private void startAppOwnNotificationSettingsActivity(Intent intent,
+            final int notificationId, final String notificationTag, final int appUid) {
+        intent.putExtra("notification_id", notificationId);
+        intent.putExtra("notification_tag", notificationTag);
+        startNotificationGutsIntent(intent, appUid);
+    }
+
+    // The (i) button in the guts that links to the system notification settings for that app
+    private void startAppNotificationSettingsActivity(String packageName, final int appUid) {
+        final Intent intent = new Intent(Settings.ACTION_APP_NOTIFICATION_SETTINGS);
         intent.putExtra(Settings.EXTRA_APP_PACKAGE, packageName);
         intent.putExtra(Settings.EXTRA_APP_UID, appUid);
-        TaskStackBuilder.create(mContext).addNextIntentWithParentStack(intent)
-                .startActivities(null, new UserHandle(UserHandle.getUserId(appUid)));
+        startNotificationGutsIntent(intent, appUid);
+    }
+
+    private void startNotificationGutsIntent(final Intent intent, final int appUid) {
+        final boolean keyguardShowing = mStatusBarKeyguardViewManager.isShowing();
+        dismissKeyguardThenExecute(new OnDismissAction() {
+            @Override
+            public boolean onDismiss() {
+                AsyncTask.execute(new Runnable() {
+                    public void run() {
+                        try {
+                            if (keyguardShowing) {
+                                ActivityManagerNative.getDefault()
+                                        .keyguardWaitingForActivityDrawn();
+                            }
+                            TaskStackBuilder.create(mContext)
+                                    .addNextIntentWithParentStack(intent)
+                                    .startActivities(null,
+                                            new UserHandle(UserHandle.getUserId(appUid)));
+                            overrideActivityPendingAppTransition(keyguardShowing);
+                        } catch (RemoteException e) {
+                        }
+                    }
+                });
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Collapsing panel from startNotificationGutsIntent after keyguard"
+                            + "dismiss");
+                }
+                animateCollapsePanels(CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
+                return true;
+            }
+        }, false /* afterKeyguardGone */);
+    }
+
+    private void inflateGuts(ExpandableNotificationRow row) {
+        ViewStub stub = (ViewStub) row.findViewById(R.id.notification_guts_stub);
+        if (stub != null) {
+            stub.inflate();
+        }
+        final StatusBarNotification sbn = row.getStatusBarNotification();
+        PackageManager pmUser = getPackageManagerForUser(
+                sbn.getUser().getIdentifier());
+        row.setTag(sbn.getPackageName());
+        final View guts = row.findViewById(R.id.notification_guts);
+        final String pkg = sbn.getPackageName();
+        String appname = pkg;
+        Drawable pkgicon = null;
+        int appUid = -1;
+        try {
+            final ApplicationInfo info = pmUser.getApplicationInfo(pkg,
+                    PackageManager.GET_UNINSTALLED_PACKAGES
+                            | PackageManager.GET_DISABLED_COMPONENTS);
+            if (info != null) {
+                appname = String.valueOf(pmUser.getApplicationLabel(info));
+                pkgicon = pmUser.getApplicationIcon(info);
+                appUid = info.uid;
+            }
+        } catch (NameNotFoundException e) {
+            // app is gone, just show package name and generic icon
+            pkgicon = pmUser.getDefaultActivityIcon();
+        }
+        ((ImageView) row.findViewById(android.R.id.icon)).setImageDrawable(pkgicon);
+        ((DateTimeView) row.findViewById(R.id.timestamp)).setTime(sbn.getPostTime());
+        ((TextView) row.findViewById(R.id.pkgname)).setText(appname);
+        final View settingsButton = guts.findViewById(R.id.notification_inspect_item);
+        final View appSettingsButton
+                = guts.findViewById(R.id.notification_inspect_app_provided_settings);
+        if (appUid >= 0) {
+            final int appUidF = appUid;
+            settingsButton.setOnClickListener(new View.OnClickListener() {
+                public void onClick(View v) {
+                    startAppNotificationSettingsActivity(pkg, appUidF);
+                }
+            });
+
+            final Intent appSettingsQueryIntent
+                    = new Intent(Intent.ACTION_MAIN)
+                    .addCategory(Notification.INTENT_CATEGORY_NOTIFICATION_PREFERENCES)
+                    .setPackage(pkg);
+            List<ResolveInfo> infos = pmUser.queryIntentActivities(appSettingsQueryIntent, 0);
+            if (infos.size() > 0) {
+                appSettingsButton.setVisibility(View.VISIBLE);
+                appSettingsButton.setContentDescription(
+                        mContext.getResources().getString(
+                                R.string.status_bar_notification_app_settings_title,
+                                appname
+                        ));
+                final Intent appSettingsLaunchIntent = new Intent(appSettingsQueryIntent)
+                        .setClassName(pkg, infos.get(0).activityInfo.name);
+                appSettingsButton.setOnClickListener(new View.OnClickListener() {
+                    public void onClick(View v) {
+                        startAppOwnNotificationSettingsActivity(appSettingsLaunchIntent,
+                                sbn.getId(),
+                                sbn.getTag(),
+                                appUidF);
+                    }
+                });
+            } else {
+                appSettingsButton.setVisibility(View.GONE);
+            }
+        } else {
+            settingsButton.setVisibility(View.GONE);
+            appSettingsButton.setVisibility(View.GONE);
+        }
+
     }
 
     protected SwipeHelper.LongPressListener getNotificationLongClicker() {
@@ -625,18 +860,33 @@
             public boolean onLongPress(View v, int x, int y) {
                 dismissPopups();
 
-                if (v.getWindowToken() == null) return false;
+                if (!(v instanceof ExpandableNotificationRow)) {
+                    return false;
+                }
+                if (v.getWindowToken() == null) {
+                    Log.e(TAG, "Trying to show notification guts, but not attached to window");
+                    return false;
+                }
+
+                inflateGuts((ExpandableNotificationRow) v);
 
                 // Assume we are a status_bar_notification_row
-                final View guts = v.findViewById(R.id.notification_guts);
-                if (guts == null) return false;
+                final NotificationGuts guts = (NotificationGuts) v.findViewById(
+                        R.id.notification_guts);
+                if (guts == null) {
+                    // This view has no guts. Examples are the more card or the dismiss all view
+                    return false;
+                }
 
                 // Already showing?
-                if (guts.getVisibility() == View.VISIBLE) return false;
+                if (guts.getVisibility() == View.VISIBLE) {
+                    Log.e(TAG, "Trying to show notification guts, but already visible");
+                    return false;
+                }
 
                 guts.setVisibility(View.VISIBLE);
-                final double horz = Math.max(v.getWidth() - x, x);
-                final double vert = Math.max(v.getHeight() - y, y);
+                final double horz = Math.max(guts.getWidth() - x, x);
+                final double vert = Math.max(guts.getActualHeight() - y, y);
                 final float r = (float) Math.hypot(horz, vert);
                 final Animator a
                         = ViewAnimationUtils.createCircularReveal(guts, x, y, 0, r);
@@ -653,11 +903,13 @@
 
     public void dismissPopups() {
         if (mNotificationGutsExposed != null) {
-            final View v = mNotificationGutsExposed;
+            final NotificationGuts v = mNotificationGutsExposed;
             mNotificationGutsExposed = null;
 
+            if (v.getWindowToken() == null) return;
+
             final int x = (v.getLeft() + v.getRight()) / 2;
-            final int y = (v.getTop() + v.getBottom()) / 2;
+            final int y = (v.getTop() + v.getActualHeight() / 2);
             final Animator a = ViewAnimationUtils.createCircularReveal(v,
                     x, y, x, 0);
             a.setDuration(200);
@@ -728,9 +980,9 @@
 
     @Override
     public void showSearchPanel() {
-        int msg = MSG_OPEN_SEARCH_PANEL;
-        mHandler.removeMessages(msg);
-        mHandler.sendEmptyMessage(msg);
+        if (mSearchPanelView != null && mSearchPanelView.isAssistantAvailable()) {
+            mSearchPanelView.show(true, true);
+        }
     }
 
     @Override
@@ -758,6 +1010,8 @@
         mSearchPanelView.setOnTouchListener(
                  new TouchOutsideListener(MSG_CLOSE_SEARCH_PANEL, mSearchPanelView));
         mSearchPanelView.setVisibility(View.GONE);
+        boolean vertical = mNavigationBarView != null && mNavigationBarView.isVertical();
+        mSearchPanelView.setHorizontal(vertical);
 
         WindowManager.LayoutParams lp = getSearchLayoutParams(mSearchPanelView.getLayoutParams());
 
@@ -943,12 +1197,6 @@
              case MSG_SHOW_PREV_AFFILIATED_TASK:
                   showRecentsPreviousAffiliatedTask();
                   break;
-             case MSG_OPEN_SEARCH_PANEL:
-                 if (DEBUG) Log.d(TAG, "opening search panel");
-                 if (mSearchPanelView != null && mSearchPanelView.isAssistantAvailable()) {
-                     mSearchPanelView.show(true, true);
-                 }
-                 break;
              case MSG_CLOSE_SEARCH_PANEL:
                  if (DEBUG) Log.d(TAG, "closing search panel");
                  if (mSearchPanelView != null && mSearchPanelView.isShowing()) {
@@ -997,7 +1245,7 @@
                 entry.notification.getUser().getIdentifier());
 
         int maxHeight = mRowMaxHeight;
-        StatusBarNotification sbn = entry.notification;
+        final StatusBarNotification sbn = entry.notification;
         RemoteViews contentView = sbn.getNotification().contentView;
         RemoteViews bigContentView = sbn.getNotification().bigContentView;
 
@@ -1043,47 +1291,6 @@
             row.setExpansionLogger(this, entry.notification.getKey());
         }
 
-        // the notification inspector (see SwipeHelper.setLongPressListener)
-        row.setTag(sbn.getPackageName());
-        final View guts = row.findViewById(R.id.notification_guts);
-        final String pkg = entry.notification.getPackageName();
-        String appname = pkg;
-        Drawable pkgicon = null;
-        int appUid = -1;
-        try {
-            final ApplicationInfo info = pmUser.getApplicationInfo(pkg,
-                PackageManager.GET_UNINSTALLED_PACKAGES | PackageManager.GET_DISABLED_COMPONENTS);
-            if (info != null) {
-                appname = String.valueOf(pmUser.getApplicationLabel(info));
-                pkgicon = pmUser.getApplicationIcon(info);
-                appUid = info.uid;
-            }
-        } catch (NameNotFoundException e) {
-            // app is gone, just show package name and generic icon
-            pkgicon = pmUser.getDefaultActivityIcon();
-        }
-        ((ImageView) row.findViewById(android.R.id.icon)).setImageDrawable(pkgicon);
-        ((DateTimeView) row.findViewById(R.id.timestamp)).setTime(entry.notification.getPostTime());
-        ((TextView) row.findViewById(R.id.pkgname)).setText(appname);
-        final View settingsButton = guts.findViewById(R.id.notification_inspect_item);
-        if (appUid >= 0) {
-            final int appUidF = appUid;
-            settingsButton.setOnClickListener(new View.OnClickListener() {
-                public void onClick(View v) {
-                    dismissKeyguardThenExecute(new OnDismissAction() {
-                        public boolean onDismiss() {
-                            startAppNotificationSettingsActivity(pkg, appUidF);
-                            animateCollapsePanels(CommandQueue.FLAG_EXCLUDE_NONE);
-                            visibilityChanged(false);
-                            return true;
-                        }
-                    });
-                }
-            });
-        } else {
-            settingsButton.setVisibility(View.GONE);
-        }
-
         workAroundBadLayerDrawableOpacity(row);
         View vetoButton = updateNotificationVetoButton(row, sbn);
         vetoButton.setContentDescription(mContext.getString(
@@ -1153,13 +1360,23 @@
             }
         }
 
+        // Extract target SDK version.
+        try {
+            ApplicationInfo info = pmUser.getApplicationInfo(sbn.getPackageName(), 0);
+            entry.targetSdk = info.targetSdkVersion;
+        } catch (NameNotFoundException ex) {
+            Log.e(TAG, "Failed looking up ApplicationInfo for " + sbn.getPackageName(), ex);
+        }
+
         if (publicViewLocal == null) {
             // Add a basic notification template
             publicViewLocal = LayoutInflater.from(mContext).inflate(
-                    com.android.internal.R.layout.notification_template_material_base,
-                    expandedPublic, true);
+                    R.layout.notification_public_default,
+                    expandedPublic, false);
+            publicViewLocal.setIsRootNamespace(true);
+            expandedPublic.setContractedChild(publicViewLocal);
 
-            final TextView title = (TextView) publicViewLocal.findViewById(com.android.internal.R.id.title);
+            final TextView title = (TextView) publicViewLocal.findViewById(R.id.title);
             try {
                 title.setText(pmUser.getApplicationLabel(
                         pmUser.getApplicationInfo(entry.notification.getPackageName(), 0)));
@@ -1167,10 +1384,9 @@
                 title.setText(entry.notification.getPackageName());
             }
 
-            final ImageView icon = (ImageView) publicViewLocal.findViewById(
-                    com.android.internal.R.id.icon);
-            final ImageView profileIcon = (ImageView) publicViewLocal.findViewById(
-                    com.android.internal.R.id.profile_icon);
+            final ImageView icon = (ImageView) publicViewLocal.findViewById(R.id.icon);
+            final ImageView profileBadge = (ImageView) publicViewLocal.findViewById(
+                    R.id.profile_badge_line3);
 
             final StatusBarIcon ic = new StatusBarIcon(entry.notification.getPackageName(),
                     entry.notification.getUser(),
@@ -1181,39 +1397,49 @@
 
             Drawable iconDrawable = StatusBarIconView.getIcon(mContext, ic);
             icon.setImageDrawable(iconDrawable);
-            if (mNotificationColorUtil.isGrayscale(iconDrawable)) {
+            if (entry.targetSdk >= Build.VERSION_CODES.L
+                    || mNotificationColorUtil.isGrayscaleIcon(iconDrawable)) {
                 icon.setBackgroundResource(
-                        com.android.internal.R.drawable.notification_icon_legacy_bg_inset);
+                        com.android.internal.R.drawable.notification_icon_legacy_bg);
+                int padding = mContext.getResources().getDimensionPixelSize(
+                        com.android.internal.R.dimen.notification_large_icon_circle_padding);
+                icon.setPadding(padding, padding, padding, padding);
+                if (sbn.getNotification().color != Notification.COLOR_DEFAULT) {
+                    icon.getBackground().setColorFilter(
+                            sbn.getNotification().color, PorterDuff.Mode.SRC_ATOP);
+                }
             }
 
-            if (profileIcon != null) {
-                Drawable profileDrawable
-                        = mUserManager.getBadgeForUser(entry.notification.getUser(), 0);
+            if (profileBadge != null) {
+                Drawable profileDrawable = mContext.getPackageManager().getUserBadgeForDensity(
+                        entry.notification.getUser(), 0);
                 if (profileDrawable != null) {
-                    profileIcon.setImageDrawable(profileDrawable);
-                    profileIcon.setVisibility(View.VISIBLE);
+                    profileBadge.setImageDrawable(profileDrawable);
+                    profileBadge.setVisibility(View.VISIBLE);
                 } else {
-                    profileIcon.setVisibility(View.GONE);
+                    profileBadge.setVisibility(View.GONE);
                 }
             }
 
             final View privateTime = contentViewLocal.findViewById(com.android.internal.R.id.time);
+            final DateTimeView time = (DateTimeView) publicViewLocal.findViewById(R.id.time);
             if (privateTime != null && privateTime.getVisibility() == View.VISIBLE) {
-                final View timeStub = publicViewLocal.findViewById(com.android.internal.R.id.time);
-                timeStub.setVisibility(View.VISIBLE);
-                final DateTimeView dateTimeView = (DateTimeView)
-                        publicViewLocal.findViewById(com.android.internal.R.id.time);
-                dateTimeView.setTime(entry.notification.getNotification().when);
+                time.setVisibility(View.VISIBLE);
+                time.setTime(entry.notification.getNotification().when);
             }
 
-            final TextView text = (TextView) publicViewLocal.findViewById(
-                com.android.internal.R.id.text);
+            final TextView text = (TextView) publicViewLocal.findViewById(R.id.text);
             if (text != null) {
                 text.setText(R.string.notification_hidden_text);
                 text.setTextAppearance(mContext,
-                        R.style.TextAppearance_StatusBar_Material_EventContent_Parenthetical);
+                        R.style.TextAppearance_Material_Notification_Parenthetical);
             }
 
+            int topPadding = Notification.Builder.calculateTopPadding(mContext,
+                    false /* hasThreeLines */,
+                    mContext.getResources().getConfiguration().fontScale);
+            title.setPadding(0, topPadding, 0, 0);
+
             entry.autoRedacted = true;
         }
 
@@ -1233,7 +1459,7 @@
         entry.expandedPublic = publicViewLocal;
         entry.setBigContentView(bigContentViewLocal);
 
-        applyLegacyRowBackground(sbn, entry);
+        applyColorsAndBackgrounds(sbn, entry);
 
         // Restore previous flags.
         if (hasUserChangedExpansion) {
@@ -1242,7 +1468,7 @@
             row.setUserExpanded(userExpanded);
         }
         row.setUserLocked(userLocked);
-
+        row.setStatusBarNotification(entry.notification);
         return true;
     }
 
@@ -1264,6 +1490,9 @@
 
         public void onClick(final View v) {
             final boolean keyguardShowing = mStatusBarKeyguardViewManager.isShowing();
+            final boolean afterKeyguardGone = mIntent.isActivity()
+                    && PreviewInflater.wouldLaunchResolverActivity(mContext, mIntent.getIntent(),
+                            mCurrentUserId);
             dismissKeyguardThenExecute(new OnDismissAction() {
                 public boolean onDismiss() {
                     if (mIsHeadsUp) {
@@ -1272,7 +1501,7 @@
                     AsyncTask.execute(new Runnable() {
                         @Override
                         public void run() {
-                            if (keyguardShowing) {
+                            if (keyguardShowing && !afterKeyguardGone) {
                                 try {
                                     ActivityManagerNative.getDefault()
                                             .keyguardWaitingForActivityDrawn();
@@ -1296,7 +1525,8 @@
                                     // TODO: Dismiss Keyguard.
                                 }
                                 if (mIntent.isActivity()) {
-                                    overrideActivityPendingAppTransition(keyguardShowing);
+                                    overrideActivityPendingAppTransition(keyguardShowing
+                                            && !afterKeyguardGone);
                                 }
                             }
 
@@ -1314,7 +1544,7 @@
 
                     return mIntent != null && mIntent.isActivity();
                 }
-            });
+            }, afterKeyguardGone);
         }
     }
 
@@ -1449,10 +1679,11 @@
                 }
             }
             boolean showOnKeyguard = shouldShowOnKeyguard(entry.notification);
-            if (onKeyguard && (visibleNotifications >= maxKeyguardNotifications
-                    || !showOnKeyguard)) {
+            if ((isLockscreenPublicMode() && !mShowLockscreenNotifications) ||
+                    (onKeyguard && (visibleNotifications >= maxKeyguardNotifications
+                            || !showOnKeyguard))) {
                 entry.row.setVisibility(View.GONE);
-                if (showOnKeyguard) {
+                if (onKeyguard && showOnKeyguard) {
                     mKeyguardIconOverflowContainer.getIconsView().addNotification(entry);
                 }
             } else {
@@ -1599,7 +1830,7 @@
                 oldEntry.notification.getNotification().tickerText);
 
         final boolean shouldInterrupt = shouldInterrupt(notification);
-        final boolean alertAgain = alertAgain(oldEntry);
+        final boolean alertAgain = alertAgain(oldEntry, n);
         boolean updateSuccessful = false;
         if (contentsUnchanged && bigContentsUnchanged && headsUpContentsUnchanged
                 && publicUnchanged) {
@@ -1734,9 +1965,6 @@
                 : null;
 
         // Reapply the RemoteViews
-        if (entry.row != null) {
-            entry.row.resetHeight();
-        }
         contentView.reapply(mContext, entry.expanded, mOnClickHandler);
         if (bigContentView != null && entry.getBigContentView() != null) {
             bigContentView.reapply(mContext, entry.getBigContentView(),
@@ -1754,7 +1982,9 @@
         } else {
             entry.row.setOnClickListener(null);
         }
+        entry.row.setStatusBarNotification(notification);
         entry.row.notifyContentUpdated();
+        entry.row.resetHeight();
     }
 
     protected void notifyHeadsUpScreenOn(boolean screenOn) {
@@ -1763,13 +1993,19 @@
         }
     }
 
-    private boolean alertAgain(Entry entry) {
-        final StatusBarNotification sbn = entry.notification;
-        return entry == null || !entry.hasInterrupted()
-                || (sbn.getNotification().flags & Notification.FLAG_ONLY_ALERT_ONCE) == 0;
+    private boolean alertAgain(Entry oldEntry, Notification newNotification) {
+        return oldEntry == null || !oldEntry.hasInterrupted()
+                || (newNotification.flags & Notification.FLAG_ONLY_ALERT_ONCE) == 0;
     }
 
     protected boolean shouldInterrupt(StatusBarNotification sbn) {
+        if (mNotificationData.shouldFilterOut(sbn)) {
+            if (DEBUG) {
+                Log.d(TAG, "Skipping HUN check for " + sbn.getKey() + " since it's filtered out.");
+            }
+            return false;
+        }
+
         Notification notification = sbn.getNotification();
         // some predicates to make the boolean logic legible
         boolean isNoisy = (notification.defaults & Notification.DEFAULT_SOUND) != 0
@@ -1781,10 +2017,13 @@
         boolean hasTicker = mHeadsUpTicker && !TextUtils.isEmpty(notification.tickerText);
         boolean isAllowed = notification.extras.getInt(Notification.EXTRA_AS_HEADS_UP,
                 Notification.HEADS_UP_ALLOWED) != Notification.HEADS_UP_NEVER;
+        boolean accessibilityForcesLaunch = isFullscreen
+                && mAccessibilityManager.isTouchExplorationEnabled();
 
         final KeyguardTouchDelegate keyguard = KeyguardTouchDelegate.getInstance(mContext);
         boolean interrupt = (isFullscreen || (isHighPriority && (isNoisy || hasTicker)))
                 && isAllowed
+                && !accessibilityForcesLaunch
                 && mPowerManager.isScreenOn()
                 && !keyguard.isShowingAndNotOccluded()
                 && !keyguard.isInputRestricted();
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/DelegateViewHelper.java b/packages/SystemUI/src/com/android/systemui/statusbar/DelegateViewHelper.java
index 3a82753..628aab8 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/DelegateViewHelper.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/DelegateViewHelper.java
@@ -20,8 +20,7 @@
 import android.graphics.RectF;
 import android.view.MotionEvent;
 import android.view.View;
-
-import com.android.systemui.R;
+import android.view.ViewConfiguration;
 
 public class DelegateViewHelper {
     private View mDelegateView;
@@ -107,8 +106,8 @@
     public void setSourceView(View view) {
         mSourceView = view;
         if (mSourceView != null) {
-            mTriggerThreshhold = mSourceView.getContext().getResources()
-                    .getDimension(R.dimen.navbar_search_up_threshhold);
+            mTriggerThreshhold =
+                    ViewConfiguration.get(mSourceView.getContext()).getScaledPagingTouchSlop();
         }
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/DismissViewImageButton.java b/packages/SystemUI/src/com/android/systemui/statusbar/DismissViewImageButton.java
new file mode 100644
index 0000000..d55b0b3
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/DismissViewImageButton.java
@@ -0,0 +1,64 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar;
+
+import android.content.Context;
+import android.graphics.Rect;
+import android.util.AttributeSet;
+import android.view.View;
+import android.view.ViewGroup;
+import android.widget.ImageButton;
+import com.android.systemui.R;
+import com.android.systemui.statusbar.stack.NotificationStackScrollLayout;
+
+public class DismissViewImageButton extends ImageButton {
+    public DismissViewImageButton(Context context) {
+        super(context);
+    }
+
+    public DismissViewImageButton(Context context, AttributeSet attrs) {
+        super(context, attrs);
+    }
+
+    public DismissViewImageButton(Context context, AttributeSet attrs, int defStyleAttr) {
+        super(context, attrs, defStyleAttr);
+    }
+
+    public DismissViewImageButton(Context context, AttributeSet attrs, int defStyleAttr,
+            int defStyleRes) {
+        super(context, attrs, defStyleAttr, defStyleRes);
+    }
+
+    /**
+     * This method returns the drawing rect for the view which is different from the regular
+     * drawing rect, since we layout all children in the {@link NotificationStackScrollLayout} at
+     * position 0 and usually the translation is neglected. The standard implementation doesn't
+     * account for translation.
+     *
+     * @param outRect The (scrolled) drawing bounds of the view.
+     */
+    @Override
+    public void getDrawingRect(Rect outRect) {
+        super.getDrawingRect(outRect);
+        float translationX = ((ViewGroup) mParent).getTranslationX();
+        float translationY = ((ViewGroup) mParent).getTranslationY();
+        outRect.left += translationX;
+        outRect.right += translationX;
+        outRect.top += translationY;
+        outRect.bottom += translationY;
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
index 9ac20a6..9196dc8 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
@@ -17,10 +17,17 @@
 package com.android.systemui.statusbar;
 
 import android.content.Context;
+import android.graphics.drawable.AnimatedVectorDrawable;
+import android.graphics.drawable.AnimationDrawable;
+import android.graphics.drawable.Drawable;
+import android.service.notification.StatusBarNotification;
 import android.util.AttributeSet;
 import android.view.View;
+import android.view.ViewGroup;
+import android.view.ViewStub;
 import android.view.accessibility.AccessibilityEvent;
 
+import android.widget.ImageView;
 import com.android.systemui.R;
 
 public class ExpandableNotificationRow extends ActivatableNotificationView {
@@ -60,6 +67,62 @@
     private ExpansionLogger mLogger;
     private String mLoggingKey;
     private boolean mWasReset;
+    private NotificationGuts mGuts;
+
+    private StatusBarNotification mStatusBarNotification;
+
+    public void setIconAnimationRunning(boolean running) {
+        setIconAnimationRunning(running, mPublicLayout);
+        setIconAnimationRunning(running, mPrivateLayout);
+    }
+
+    private void setIconAnimationRunning(boolean running, NotificationContentView layout) {
+        if (layout != null) {
+            View contractedChild = layout.getContractedChild();
+            View expandedChild = layout.getExpandedChild();
+            setIconAnimationRunningForChild(running, contractedChild);
+            setIconAnimationRunningForChild(running, expandedChild);
+        }
+    }
+
+    private void setIconAnimationRunningForChild(boolean running, View child) {
+        if (child != null) {
+            ImageView icon = (ImageView) child.findViewById(com.android.internal.R.id.icon);
+            setIconRunning(icon, running);
+            ImageView rightIcon = (ImageView) child.findViewById(
+                    com.android.internal.R.id.right_icon);
+            setIconRunning(rightIcon, running);
+        }
+    }
+
+    private void setIconRunning(ImageView imageView, boolean running) {
+        if (imageView != null) {
+            Drawable drawable = imageView.getDrawable();
+            if (drawable instanceof AnimationDrawable) {
+                AnimationDrawable animationDrawable = (AnimationDrawable) drawable;
+                if (running) {
+                    animationDrawable.start();
+                } else {
+                    animationDrawable.stop();
+                }
+            } else if (drawable instanceof AnimatedVectorDrawable) {
+                AnimatedVectorDrawable animationDrawable = (AnimatedVectorDrawable) drawable;
+                if (running) {
+                    animationDrawable.start();
+                } else {
+                    animationDrawable.stop();
+                }
+            }
+        }
+    }
+
+    public void setStatusBarNotification(StatusBarNotification statusBarNotification) {
+        mStatusBarNotification = statusBarNotification;
+    }
+
+    public StatusBarNotification getStatusBarNotification() {
+        return mStatusBarNotification;
+    }
 
     public interface ExpansionLogger {
         public void logNotificationExpansion(String key, boolean userAction, boolean expanded);
@@ -96,6 +159,7 @@
         mMaxExpandHeight = 0;
         mWasReset = true;
         onHeightReset();
+        requestLayout();
     }
 
     @Override
@@ -103,6 +167,15 @@
         super.onFinishInflate();
         mPublicLayout = (NotificationContentView) findViewById(R.id.expandedPublic);
         mPrivateLayout = (NotificationContentView) findViewById(R.id.expanded);
+        ViewStub gutsStub = (ViewStub) findViewById(R.id.notification_guts_stub);
+        gutsStub.setOnInflateListener(new ViewStub.OnInflateListener() {
+            @Override
+            public void onInflate(ViewStub stub, View inflated) {
+                mGuts = (NotificationGuts) inflated;
+                mGuts.setClipTopAmount(getClipTopAmount());
+                mGuts.setActualHeight(getActualHeight());
+            }
+        });
         mVetoButton = findViewById(R.id.veto);
     }
 
@@ -120,6 +193,15 @@
         return false;
     }
 
+    @Override
+    public void setDark(boolean dark, boolean fade) {
+        super.setDark(dark, fade);
+        final NotificationContentView showing = getShowingLayout();
+        if (showing != null) {
+            showing.setDark(dark, fade);
+        }
+    }
+
     public void setHeightRange(int rowMinHeight, int rowMaxHeight) {
         mRowMinHeight = rowMinHeight;
         mRowMaxHeight = rowMaxHeight;
@@ -265,13 +347,21 @@
     protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
         super.onLayout(changed, left, top, right, bottom);
         boolean updateExpandHeight = mMaxExpandHeight == 0 && !mWasReset;
-        mMaxExpandHeight = mPrivateLayout.getMaxHeight();
+        updateMaxExpandHeight();
         if (updateExpandHeight) {
             applyExpansionToLayout();
         }
         mWasReset = false;
     }
 
+    private void updateMaxExpandHeight() {
+        int intrinsicBefore = getIntrinsicHeight();
+        mMaxExpandHeight = mPrivateLayout.getMaxHeight();
+        if (intrinsicBefore != getIntrinsicHeight()) {
+            notifyHeightChanged();
+        }
+    }
+
     public void setSensitive(boolean sensitive) {
         mSensitive = sensitive;
     }
@@ -316,7 +406,6 @@
         target.animate().cancel();
         source.animate()
                 .alpha(0f)
-                .withLayer()
                 .setStartDelay(delay)
                 .setDuration(duration)
                 .withEndAction(new Runnable() {
@@ -327,7 +416,6 @@
                 });
         target.animate()
                 .alpha(1f)
-                .withLayer()
                 .setStartDelay(delay)
                 .setDuration(duration);
     }
@@ -351,6 +439,9 @@
     public void setActualHeight(int height, boolean notifyListeners) {
         mPrivateLayout.setActualHeight(height);
         mPublicLayout.setActualHeight(height);
+        if (mGuts != null) {
+            mGuts.setActualHeight(height);
+        }
         invalidate();
         super.setActualHeight(height, notifyListeners);
     }
@@ -372,6 +463,9 @@
         super.setClipTopAmount(clipTopAmount);
         mPrivateLayout.setClipTopAmount(clipTopAmount);
         mPublicLayout.setClipTopAmount(clipTopAmount);
+        if (mGuts != null) {
+            mGuts.setClipTopAmount(clipTopAmount);
+        }
     }
 
     public void notifyContentUpdated() {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableOutlineView.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableOutlineView.java
index d882a87..f85d32b 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableOutlineView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableOutlineView.java
@@ -31,11 +31,9 @@
 
     private final Rect mOutlineRect = new Rect();
     private boolean mCustomOutline;
-    private float mDensity;
 
     public ExpandableOutlineView(Context context, AttributeSet attrs) {
         super(context, attrs);
-        mDensity = getResources().getDisplayMetrics().density;
         setOutlineProvider(new ViewOutlineProvider() {
             @Override
             public void getOutline(View view, Outline outline) {
@@ -78,8 +76,8 @@
         mOutlineRect.set((int) left, (int) top, (int) right, (int) bottom);
 
         // Outlines need to be at least 1 dp
-        mOutlineRect.bottom = (int) Math.max(top + mDensity, mOutlineRect.bottom);
-        mOutlineRect.right = (int) Math.max(left + mDensity, mOutlineRect.right);
+        mOutlineRect.bottom = (int) Math.max(top, mOutlineRect.bottom);
+        mOutlineRect.right = (int) Math.max(left, mOutlineRect.right);
 
         invalidateOutline();
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
index 127ff6c..c8f756e 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableView.java
@@ -17,12 +17,14 @@
 package com.android.systemui.statusbar;
 
 import android.content.Context;
+import android.graphics.Rect;
 import android.util.AttributeSet;
 import android.view.MotionEvent;
 import android.view.View;
 import android.view.ViewGroup;
 import android.widget.FrameLayout;
 import com.android.systemui.R;
+import com.android.systemui.statusbar.stack.NotificationStackScrollLayout;
 
 import java.util.ArrayList;
 
@@ -94,7 +96,10 @@
     protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
         super.onLayout(changed, left, top, right, bottom);
         if (!mActualHeightInitialized && mActualHeight == 0) {
-            setActualHeight(getInitialHeight());
+            int initialHeight = getInitialHeight();
+            if (initialHeight != 0) {
+                setActualHeight(initialHeight);
+            }
         }
     }
 
@@ -250,8 +255,6 @@
 
     public abstract void performAddAnimation(long delay, long duration);
 
-    public abstract void setScrimAmount(float scrimAmount);
-
     public void setBelowSpeedBump(boolean below) {
     }
 
@@ -262,6 +265,24 @@
     }
 
     /**
+     * This method returns the drawing rect for the view which is different from the regular
+     * drawing rect, since we layout all children in the {@link NotificationStackScrollLayout} at
+     * position 0 and usually the translation is neglected. Since we are manually clipping this
+     * view,we also need to subtract the clipTopAmount from the top. This is needed in order to
+     * ensure that accessibility and focusing work correctly.
+     *
+     * @param outRect The (scrolled) drawing bounds of the view.
+     */
+    @Override
+    public void getDrawingRect(Rect outRect) {
+        super.getDrawingRect(outRect);
+        outRect.left += getTranslationX();
+        outRect.right += getTranslationX();
+        outRect.bottom = (int) (outRect.top + getTranslationY() + getActualHeight());
+        outRect.top += getTranslationY() + getClipTopAmount();
+    }
+
+    /**
      * A listener notifying when {@link #getActualHeight} changes.
      */
     public interface OnHeightChangedListener {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java b/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java
index 4a6bfa10..a4161f9 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java
@@ -163,6 +163,9 @@
 
     public void setPreviewView(View v) {
         mPreviewView = v;
+        if (mPreviewView != null) {
+            mPreviewView.setVisibility(INVISIBLE);
+        }
     }
 
     private void drawArrow(Canvas canvas) {
@@ -248,15 +251,19 @@
     }
 
     public void setCircleRadius(float circleRadius) {
-        setCircleRadius(circleRadius, false);
+        setCircleRadius(circleRadius, false, false);
+    }
+
+    public void setCircleRadius(float circleRadius, boolean slowAnimation) {
+        setCircleRadius(circleRadius, slowAnimation, false);
     }
 
     public void setCircleRadiusWithoutAnimation(float circleRadius) {
         cancelAnimator(mCircleAnimator);
-        setCircleRadius(circleRadius, true);
+        setCircleRadius(circleRadius, false ,true);
     }
 
-    private void setCircleRadius(float circleRadius, boolean noAnimation) {
+    private void setCircleRadius(float circleRadius, boolean slowAnimation, boolean noAnimation) {
 
         // Check if we need a new animation
         boolean radiusHidden = (mCircleAnimator != null && mCircleWillBeHidden)
@@ -289,13 +296,16 @@
                     ? mDisappearInterpolator
                     : mAppearInterpolator;
             animator.setInterpolator(interpolator);
-            float durationFactor = Math.abs(mCircleRadius - circleRadius)
-                    / (float) mMinBackgroundRadius;
-            long duration = (long) (CIRCLE_APPEAR_DURATION * durationFactor);
-            duration = Math.min(duration, CIRCLE_DISAPPEAR_MAX_DURATION);
+            long duration = 250;
+            if (!slowAnimation) {
+                float durationFactor = Math.abs(mCircleRadius - circleRadius)
+                        / (float) mMinBackgroundRadius;
+                duration = (long) (CIRCLE_APPEAR_DURATION * durationFactor);
+                duration = Math.min(duration, CIRCLE_DISAPPEAR_MAX_DURATION);
+            }
             animator.setDuration(duration);
             animator.start();
-            if (mPreviewView != null) {
+            if (mPreviewView != null && mPreviewView.getVisibility() == View.VISIBLE) {
                 mPreviewView.setVisibility(View.VISIBLE);
                 mPreviewClipper = ViewAnimationUtils.createCircularReveal(
                         mPreviewView, getLeft() + mCenterX, getTop() + mCenterY, mCircleRadius,
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/MirrorView.java b/packages/SystemUI/src/com/android/systemui/statusbar/MirrorView.java
deleted file mode 100644
index 8b0df06..0000000
--- a/packages/SystemUI/src/com/android/systemui/statusbar/MirrorView.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2014 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.systemui.statusbar;
-
-import android.content.Context;
-import android.graphics.Canvas;
-import android.view.View;
-
-/**
- * A view that mirrors the visual contents of another one. Should be used for animation purposes
- * only, as this view doesn't have any input handling.
- */
-public class MirrorView extends View {
-
-    private View mView;
-    private int mFixedWidth;
-    private int mFixedHeight;
-
-    public MirrorView(Context context) {
-        super(context);
-    }
-
-    public void setMirroredView(View v, int width, int height) {
-        mView = v;
-        mFixedWidth = width;
-        mFixedHeight = height;
-        requestLayout();
-        invalidate();
-    }
-
-    @Override
-    protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
-        if (mView != null) {
-            setMeasuredDimension(mFixedWidth, mFixedHeight);
-        } else {
-            setMeasuredDimension(0, 0);
-        }
-    }
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-        if (mView != null) {
-            mView.draw(canvas);
-        }
-    }
-}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationBackgroundView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationBackgroundView.java
index ad274b0..5db680a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationBackgroundView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationBackgroundView.java
@@ -35,15 +35,9 @@
     private Drawable mBackground;
     private int mClipTopAmount;
     private int mActualHeight;
-    private final int mTintedRippleColor;
-    private final int mNormalRippleColor;
 
     public NotificationBackgroundView(Context context, AttributeSet attrs) {
         super(context, attrs);
-        mTintedRippleColor = context.getResources().getColor(
-                R.color.notification_ripple_tinted_color);
-        mNormalRippleColor = context.getResources().getColor(
-                R.color.notification_ripple_untinted_color);
     }
 
     @Override
@@ -103,17 +97,10 @@
     }
 
     public void setTint(int tintColor) {
-        int rippleColor;
         if (tintColor != 0) {
             mBackground.setColorFilter(tintColor, PorterDuff.Mode.SRC_ATOP);
-            rippleColor = mTintedRippleColor;
         } else {
             mBackground.clearColorFilter();
-            rippleColor = mNormalRippleColor;
-        }
-        if (mBackground instanceof RippleDrawable) {
-            RippleDrawable ripple = (RippleDrawable) mBackground;
-            ripple.setColor(ColorStateList.valueOf(rippleColor));
         }
         invalidate();
     }
@@ -138,4 +125,15 @@
         // Prevents this view from creating a layer when alpha is animating.
         return false;
     }
+
+    public void setState(int[] drawableState) {
+        mBackground.setState(drawableState);
+    }
+
+    public void setRippleColor(int color) {
+        if (mBackground instanceof RippleDrawable) {
+            RippleDrawable ripple = (RippleDrawable) mBackground;
+            ripple.setColor(ColorStateList.valueOf(color));
+        }
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java
index f3aba0e..502490f 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationContentView.java
@@ -17,15 +17,20 @@
 package com.android.systemui.statusbar;
 
 import android.content.Context;
+import android.graphics.ColorFilter;
+import android.graphics.ColorMatrix;
+import android.graphics.ColorMatrixColorFilter;
 import android.graphics.Paint;
 import android.graphics.PorterDuff;
 import android.graphics.PorterDuffXfermode;
 import android.graphics.Rect;
+import android.graphics.drawable.Drawable;
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.animation.Interpolator;
 import android.view.animation.LinearInterpolator;
 import android.widget.FrameLayout;
+import android.widget.ImageView;
 
 import com.android.systemui.R;
 
@@ -37,6 +42,8 @@
 public class NotificationContentView extends FrameLayout {
 
     private static final long ANIMATION_DURATION_LENGTH = 170;
+    private static final Paint INVERT_PAINT = createInvertPaint();
+    private static final ColorFilter NO_COLOR_FILTER = new ColorFilter();
 
     private final Rect mClipBounds = new Rect();
 
@@ -50,6 +57,7 @@
     private final Interpolator mLinearInterpolator = new LinearInterpolator();
 
     private boolean mContractedVisible = true;
+    private boolean mDark;
 
     private final Paint mFadePaint = new Paint();
 
@@ -66,6 +74,12 @@
     }
 
     public void reset() {
+        if (mContractedChild != null) {
+            mContractedChild.animate().cancel();
+        }
+        if (mExpandedChild != null) {
+            mExpandedChild.animate().cancel();
+        }
         removeAllViews();
         mContractedChild = null;
         mExpandedChild = null;
@@ -74,8 +88,17 @@
         mContractedVisible = true;
     }
 
+    public View getContractedChild() {
+        return mContractedChild;
+    }
+
+    public View getExpandedChild() {
+        return mExpandedChild;
+    }
+
     public void setContractedChild(View child) {
         if (mContractedChild != null) {
+            mContractedChild.animate().cancel();
             removeView(mContractedChild);
         }
         sanitizeContractedLayoutParams(child);
@@ -86,6 +109,7 @@
 
     public void setExpandedChild(View child) {
         if (mExpandedChild != null) {
+            mExpandedChild.animate().cancel();
             removeView(mExpandedChild);
         }
         addView(child);
@@ -184,4 +208,58 @@
     public boolean isContentExpandable() {
         return mExpandedChild != null;
     }
+
+    public void setDark(boolean dark, boolean fade) {
+        if (mDark == dark || mContractedChild == null) return;
+        mDark = dark;
+        setImageViewDark(dark, fade, com.android.internal.R.id.right_icon);
+        setImageViewDark(dark, fade, com.android.internal.R.id.icon);
+    }
+
+    private void setImageViewDark(boolean dark, boolean fade, int imageViewId) {
+        // TODO: implement fade
+        final ImageView v = (ImageView) mContractedChild.findViewById(imageViewId);
+        if (v == null) return;
+        final Drawable d = v.getBackground();
+        if (dark) {
+            v.setLayerType(LAYER_TYPE_HARDWARE, INVERT_PAINT);
+            if (d != null) {
+                v.setTag(R.id.doze_saved_filter_tag, d.getColorFilter() != null ? d.getColorFilter()
+                        : NO_COLOR_FILTER);
+                d.setColorFilter(getResources().getColor(R.color.doze_small_icon_background_color),
+                        PorterDuff.Mode.SRC_ATOP);
+                v.setImageAlpha(getResources().getInteger(R.integer.doze_small_icon_alpha));
+            }
+        } else {
+            v.setLayerType(LAYER_TYPE_NONE, null);
+            if (d != null)  {
+                final ColorFilter filter = (ColorFilter) v.getTag(R.id.doze_saved_filter_tag);
+                if (filter != null) {
+                    d.setColorFilter(filter == NO_COLOR_FILTER ? null : filter);
+                    v.setTag(R.id.doze_saved_filter_tag, null);
+                }
+                v.setImageAlpha(0xff);
+            }
+        }
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+
+        // This is not really true, but good enough when fading from the contracted to the expanded
+        // layout, and saves us some layers.
+        return false;
+    }
+
+    private static Paint createInvertPaint() {
+        final Paint p = new Paint();
+        final float[] invert = {
+            -1f,  0f,  0f, 1f, 1f,
+             0f, -1f,  0f, 1f, 1f,
+             0f,  0f, -1f, 1f, 1f,
+             0f,  0f,  0f, 1f, 0f
+        };
+        p.setColorFilter(new ColorMatrixColorFilter(new ColorMatrix(invert)));
+        return p;
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationData.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationData.java
index 9408042..34c458a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationData.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationData.java
@@ -17,6 +17,7 @@
 package com.android.systemui.statusbar;
 
 import android.app.Notification;
+import android.service.notification.NotificationListenerService;
 import android.service.notification.NotificationListenerService.Ranking;
 import android.service.notification.NotificationListenerService.RankingMap;
 import android.service.notification.StatusBarNotification;
@@ -47,6 +48,7 @@
         private boolean interruption;
         public boolean autoRedacted; // whether the redacted notification was generated by us
         public boolean legacy; // whether the notification has a legacy, dark background
+        public int targetSdk;
 
         public Entry(StatusBarNotification n, StatusBarIconView ic) {
             this.key = n.getKey();
@@ -89,6 +91,7 @@
 
     private final ArrayMap<String, Entry> mEntries = new ArrayMap<>();
     private final ArrayList<Entry> mSortedAndFiltered = new ArrayList<>();
+    private ArraySet<String> mGroupsWithSummaries = new ArraySet<>();
 
     private RankingMap mRankingMap;
     private final Ranking mTmpRanking = new Ranking();
@@ -98,14 +101,33 @@
 
         @Override
         public int compare(Entry a, Entry b) {
+            // Upsort current media notification.
+            String mediaNotification = mEnvironment.getCurrentMediaNotificationKey();
+            boolean aMedia = a.key.equals(mediaNotification);
+            boolean bMedia = b.key.equals(mediaNotification);
+            if (aMedia != bMedia) {
+                return aMedia ? -1 : 1;
+            }
+
+            final StatusBarNotification na = a.notification;
+            final StatusBarNotification nb = b.notification;
+
+            // Upsort PRIORITY_MAX system notifications
+            boolean aSystemMax = na.getNotification().priority >= Notification.PRIORITY_MAX &&
+                    isSystemNotification(na);
+            boolean bSystemMax = nb.getNotification().priority >= Notification.PRIORITY_MAX &&
+                    isSystemNotification(nb);
+            if (aSystemMax != bSystemMax) {
+                return aSystemMax ? -1 : 1;
+            }
+
+            // RankingMap as received from NoMan.
             if (mRankingMap != null) {
                 mRankingMap.getRanking(a.key, mRankingA);
                 mRankingMap.getRanking(b.key, mRankingB);
                 return mRankingA.getRank() - mRankingB.getRank();
             }
 
-            final StatusBarNotification na = a.notification;
-            final StatusBarNotification nb = b.notification;
             int d = nb.getScore() - na.getScore();
             if (a.interruption != b.interruption) {
                 return a.interruption ? -1 : 1;
@@ -162,6 +184,14 @@
         return false;
     }
 
+    public int getVisibilityOverride(String key) {
+        if (mRankingMap != null) {
+            mRankingMap.getRanking(key, mTmpRanking);
+            return mTmpRanking.getVisibilityOverride();
+        }
+        return NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE;
+    }
+
     private void updateRankingAndSort(RankingMap ranking) {
         if (ranking != null) {
             mRankingMap = ranking;
@@ -173,8 +203,8 @@
     // anything changed, and this class should call back the UI so it updates itself.
     public void filterAndSort() {
         mSortedAndFiltered.clear();
+        mGroupsWithSummaries.clear();
 
-        ArraySet<String> groupsWithSummaries = null;
         final int N = mEntries.size();
         for (int i = 0; i < N; i++) {
             Entry entry = mEntries.valueAt(i);
@@ -185,22 +215,19 @@
             }
 
             if (sbn.getNotification().isGroupSummary()) {
-                if (groupsWithSummaries == null) {
-                    groupsWithSummaries = new ArraySet<>();
-                }
-                groupsWithSummaries.add(sbn.getGroupKey());
+                mGroupsWithSummaries.add(sbn.getGroupKey());
             }
             mSortedAndFiltered.add(entry);
         }
 
         // Second pass: Filter out group children with summary.
-        if (groupsWithSummaries != null) {
+        if (!mGroupsWithSummaries.isEmpty()) {
             final int M = mSortedAndFiltered.size();
             for (int i = M - 1; i >= 0; i--) {
                 Entry ent = mSortedAndFiltered.get(i);
                 StatusBarNotification sbn = ent.notification;
                 if (sbn.getNotification().isGroupChild() &&
-                        groupsWithSummaries.contains(sbn.getGroupKey())) {
+                        mGroupsWithSummaries.contains(sbn.getGroupKey())) {
                     mSortedAndFiltered.remove(i);
                 }
             }
@@ -209,7 +236,11 @@
         Collections.sort(mSortedAndFiltered, mRankingComparator);
     }
 
-    private boolean shouldFilterOut(StatusBarNotification sbn) {
+    public boolean isGroupWithSummary(String groupKey) {
+        return mGroupsWithSummaries.contains(groupKey);
+    }
+
+    boolean shouldFilterOut(StatusBarNotification sbn) {
         if (!(mEnvironment.isDeviceProvisioned() ||
                 showNotificationEvenIfUnprovisioned(sbn))) {
             return true;
@@ -252,18 +283,21 @@
         int N = mSortedAndFiltered.size();
         pw.print(indent);
         pw.println("active notifications: " + N);
-        for (int i = 0; i < N; i++) {
-            NotificationData.Entry e = mSortedAndFiltered.get(i);
-            dumpEntry(pw, indent, i, e);
+        int active;
+        for (active = 0; active < N; active++) {
+            NotificationData.Entry e = mSortedAndFiltered.get(active);
+            dumpEntry(pw, indent, active, e);
         }
 
         int M = mEntries.size();
         pw.print(indent);
-        pw.println("inactive notifications: " + M);
+        pw.println("inactive notifications: " + (M - active));
+        int inactiveCount = 0;
         for (int i = 0; i < M; i++) {
             Entry entry = mEntries.valueAt(i);
             if (!mSortedAndFiltered.contains(entry)) {
-                dumpEntry(pw, indent, i, entry);
+                dumpEntry(pw, indent, inactiveCount, entry);
+                inactiveCount++;
             }
         }
     }
@@ -273,20 +307,26 @@
         pw.println("  [" + i + "] key=" + e.key + " icon=" + e.icon);
         StatusBarNotification n = e.notification;
         pw.print(indent);
-        pw.println("      pkg=" + n.getPackageName() + " id=" + n.getId() + " score=" + n
-                .getScore());
+        pw.println("      pkg=" + n.getPackageName() + " id=" + n.getId() + " score=" +
+                n.getScore());
         pw.print(indent);
         pw.println("      notification=" + n.getNotification());
         pw.print(indent);
         pw.println("      tickerText=\"" + n.getNotification().tickerText + "\"");
     }
 
+    private static boolean isSystemNotification(StatusBarNotification sbn) {
+        String sbnPackage = sbn.getPackageName();
+        return "android".equals(sbnPackage) || "com.android.systemui".equals(sbnPackage);
+    }
+
     /**
      * Provides access to keyguard state and user settings dependent data.
      */
     public interface Environment {
-        public boolean shouldHideSensitiveContents(int userId);
+        public boolean shouldHideSensitiveContents(int userid);
         public boolean isDeviceProvisioned();
         public boolean isNotificationForCurrentProfiles(StatusBarNotification sbn);
+        public String getCurrentMediaNotificationKey();
     }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationGuts.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationGuts.java
new file mode 100644
index 0000000..46e0bf8
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationGuts.java
@@ -0,0 +1,104 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar;
+
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.drawable.Drawable;
+import android.util.AttributeSet;
+import android.widget.FrameLayout;
+import com.android.systemui.R;
+
+/**
+ * The guts of a notification revealed when performing a long press.
+ */
+public class NotificationGuts extends FrameLayout {
+
+    private Drawable mBackground;
+    private int mClipTopAmount;
+    private int mActualHeight;
+
+    public NotificationGuts(Context context, AttributeSet attrs) {
+        super(context, attrs);
+        setWillNotDraw(false);
+    }
+
+    @Override
+    protected void onDraw(Canvas canvas) {
+        draw(canvas, mBackground);
+    }
+
+    private void draw(Canvas canvas, Drawable drawable) {
+        if (drawable != null) {
+            drawable.setBounds(0, mClipTopAmount, getWidth(), mActualHeight);
+            drawable.draw(canvas);
+        }
+    }
+
+    @Override
+    protected void onFinishInflate() {
+        super.onFinishInflate();
+        mBackground = mContext.getDrawable(R.drawable.notification_guts_bg);
+        if (mBackground != null) {
+            mBackground.setCallback(this);
+        }
+    }
+
+    @Override
+    protected boolean verifyDrawable(Drawable who) {
+        return super.verifyDrawable(who) || who == mBackground;
+    }
+
+    @Override
+    protected void drawableStateChanged() {
+        drawableStateChanged(mBackground);
+    }
+
+    private void drawableStateChanged(Drawable d) {
+        if (d != null && d.isStateful()) {
+            d.setState(getDrawableState());
+        }
+    }
+
+    @Override
+    public void drawableHotspotChanged(float x, float y) {
+        if (mBackground != null) {
+            mBackground.setHotspot(x, y);
+        }
+    }
+
+    public void setActualHeight(int actualHeight) {
+        mActualHeight = actualHeight;
+        invalidate();
+    }
+
+    public int getActualHeight() {
+        return mActualHeight;
+    }
+
+    public void setClipTopAmount(int clipTopAmount) {
+        mClipTopAmount = clipTopAmount;
+        invalidate();
+    }
+
+    @Override
+    public boolean hasOverlappingRendering() {
+
+        // Prevents this view from creating a layer when alpha is animating.
+        return false;
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationOverflowIconsView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationOverflowIconsView.java
index c75bd28..c4c9dac 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationOverflowIconsView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationOverflowIconsView.java
@@ -36,7 +36,7 @@
     private TextView mMoreText;
     private int mTintColor;
     private int mIconSize;
-    private NotificationColorUtil mNotificationColorUtil = new NotificationColorUtil();
+    private NotificationColorUtil mNotificationColorUtil;
 
     public NotificationOverflowIconsView(Context context, AttributeSet attrs) {
         super(context, attrs);
@@ -45,6 +45,7 @@
     @Override
     protected void onFinishInflate() {
         super.onFinishInflate();
+        mNotificationColorUtil = NotificationColorUtil.getInstance(getContext());
         mTintColor = getResources().getColor(R.color.keyguard_overflow_content_color);
         mIconSize = getResources().getDimensionPixelSize(
                 com.android.internal.R.dimen.status_bar_icon_size);
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationScrimView.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationScrimView.java
deleted file mode 100644
index 440b2c1..0000000
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationScrimView.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
- * Copyright (C) 2014 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.systemui.statusbar;
-
-import android.content.Context;
-import android.graphics.Canvas;
-import android.graphics.PorterDuff;
-import android.graphics.drawable.Drawable;
-import android.util.AttributeSet;
-import android.view.View;
-
-import com.android.keyguard.R;
-
-/**
- * A view that can be used for both the dimmed and normal background of an notification.
- */
-public class NotificationScrimView extends View {
-
-    private Drawable mBackground;
-    private int mClipTopAmount;
-    private int mActualHeight;
-
-    public NotificationScrimView(Context context, AttributeSet attrs) {
-        super(context, attrs);
-        mBackground = getResources().getDrawable(R.drawable.notification_scrim);
-    }
-
-    @Override
-    protected void onDraw(Canvas canvas) {
-        draw(canvas, mBackground);
-    }
-
-    private void draw(Canvas canvas, Drawable drawable) {
-        if (drawable != null) {
-            drawable.setBounds(0, mClipTopAmount, getWidth(), mActualHeight);
-            drawable.draw(canvas);
-        }
-    }
-
-    @Override
-    protected boolean verifyDrawable(Drawable who) {
-        return super.verifyDrawable(who) || who == mBackground;
-    }
-
-    public void setActualHeight(int actualHeight) {
-        mActualHeight = actualHeight;
-        invalidate();
-    }
-
-    public int getActualHeight() {
-        return mActualHeight;
-    }
-
-    public void setClipTopAmount(int clipTopAmount) {
-        mClipTopAmount = clipTopAmount;
-        invalidate();
-    }
-
-    @Override
-    public boolean hasOverlappingRendering() {
-
-        // Prevents this view from creating a layer when alpha is animating.
-        return false;
-    }
-}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/SignalClusterView.java b/packages/SystemUI/src/com/android/systemui/statusbar/SignalClusterView.java
index fb13126..b71c9bf 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/SignalClusterView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/SignalClusterView.java
@@ -27,17 +27,21 @@
 
 import com.android.systemui.R;
 import com.android.systemui.statusbar.policy.NetworkControllerImpl;
+import com.android.systemui.statusbar.policy.SecurityController;
 
 // Intimately tied to the design of res/layout/signal_cluster_view.xml
 public class SignalClusterView
         extends LinearLayout
-        implements NetworkControllerImpl.SignalCluster {
+        implements NetworkControllerImpl.SignalCluster,
+        SecurityController.SecurityControllerCallback {
 
     static final String TAG = "SignalClusterView";
     static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
 
     NetworkControllerImpl mNC;
+    SecurityController mSC;
 
+    private boolean mVpnVisible = false;
     private boolean mWifiVisible = false;
     private int mWifiStrengthId = 0;
     private boolean mMobileVisible = false;
@@ -45,10 +49,15 @@
     private boolean mIsAirplaneMode = false;
     private int mAirplaneIconId = 0;
     private String mWifiDescription, mMobileDescription, mMobileTypeDescription;
+    private boolean mRoaming;
+    private boolean mIsMobileTypeIconWide;
 
     ViewGroup mWifiGroup, mMobileGroup;
-    ImageView mWifi, mMobile, mMobileType, mAirplane;
-    View mSpacer;
+    ImageView mVpn, mWifi, mMobile, mMobileType, mAirplane;
+    View mWifiAirplaneSpacer;
+    View mWifiSignalSpacer;
+
+    private int mWideTypeIconStartPadding;
 
     public SignalClusterView(Context context) {
         this(context, null);
@@ -67,34 +76,62 @@
         mNC = nc;
     }
 
+    public void setSecurityController(SecurityController sc) {
+        if (DEBUG) Log.d(TAG, "SecurityController=" + sc);
+        mSC = sc;
+        mSC.addCallback(this);
+        mVpnVisible = mSC.isVpnEnabled();
+    }
+
+    @Override
+    protected void onFinishInflate() {
+        super.onFinishInflate();
+        mWideTypeIconStartPadding = getContext().getResources().getDimensionPixelSize(
+                R.dimen.wide_type_icon_start_padding);
+    }
+
     @Override
     protected void onAttachedToWindow() {
         super.onAttachedToWindow();
 
+        mVpn            = (ImageView) findViewById(R.id.vpn);
         mWifiGroup      = (ViewGroup) findViewById(R.id.wifi_combo);
         mWifi           = (ImageView) findViewById(R.id.wifi_signal);
         mMobileGroup    = (ViewGroup) findViewById(R.id.mobile_combo);
         mMobile         = (ImageView) findViewById(R.id.mobile_signal);
         mMobileType     = (ImageView) findViewById(R.id.mobile_type);
-        mSpacer         =             findViewById(R.id.spacer);
         mAirplane       = (ImageView) findViewById(R.id.airplane);
+        mWifiAirplaneSpacer =         findViewById(R.id.wifi_airplane_spacer);
+        mWifiSignalSpacer =           findViewById(R.id.wifi_signal_spacer);
 
         apply();
     }
 
     @Override
     protected void onDetachedFromWindow() {
+        mVpn            = null;
         mWifiGroup      = null;
         mWifi           = null;
         mMobileGroup    = null;
         mMobile         = null;
         mMobileType     = null;
-        mSpacer         = null;
         mAirplane       = null;
 
         super.onDetachedFromWindow();
     }
 
+    // From SecurityController.
+    @Override
+    public void onStateChanged() {
+        post(new Runnable() {
+            @Override
+            public void run() {
+                mVpnVisible = mSC.isVpnEnabled();
+                apply();
+            }
+        });
+    }
+
     @Override
     public void setWifiIndicators(boolean visible, int strengthIcon, String contentDescription) {
         mWifiVisible = visible;
@@ -106,12 +143,15 @@
 
     @Override
     public void setMobileDataIndicators(boolean visible, int strengthIcon, int typeIcon,
-            String contentDescription, String typeContentDescription) {
+            String contentDescription, String typeContentDescription, boolean roaming,
+            boolean isTypeIconWide) {
         mMobileVisible = visible;
         mMobileStrengthId = strengthIcon;
         mMobileTypeId = typeIcon;
         mMobileDescription = contentDescription;
         mMobileTypeDescription = typeContentDescription;
+        mRoaming = roaming;
+        mIsMobileTypeIconWide = isTypeIconWide;
 
         apply();
     }
@@ -167,6 +207,8 @@
     private void apply() {
         if (mWifiGroup == null) return;
 
+        mVpn.setVisibility(mVpnVisible ? View.VISIBLE : View.GONE);
+        if (DEBUG) Log.d(TAG, String.format("vpn: %s", mVpnVisible ? "VISIBLE" : "GONE"));
         if (mWifiVisible) {
             mWifi.setImageResource(mWifiStrengthId);
             mWifiGroup.setContentDescription(mWifiDescription);
@@ -196,19 +238,26 @@
             mAirplane.setVisibility(View.GONE);
         }
 
-        if (mMobileVisible && mWifiVisible && mIsAirplaneMode) {
-            mSpacer.setVisibility(View.INVISIBLE);
+        if (mIsAirplaneMode && mWifiVisible) {
+            mWifiAirplaneSpacer.setVisibility(View.VISIBLE);
         } else {
-            mSpacer.setVisibility(View.GONE);
+            mWifiAirplaneSpacer.setVisibility(View.GONE);
         }
 
+        if (mRoaming && mMobileVisible && mWifiVisible) {
+            mWifiSignalSpacer.setVisibility(View.VISIBLE);
+        } else {
+            mWifiSignalSpacer.setVisibility(View.GONE);
+        }
+
+        mMobile.setPaddingRelative(mIsMobileTypeIconWide ? mWideTypeIconStartPadding : 0, 0, 0, 0);
+
         if (DEBUG) Log.d(TAG,
                 String.format("mobile: %s sig=%d typ=%d",
                     (mMobileVisible ? "VISIBLE" : "GONE"),
                     mMobileStrengthId, mMobileTypeId));
 
-        mMobileType.setVisibility(
-                !mWifiVisible ? View.VISIBLE : View.GONE);
+        mMobileType.setVisibility((mRoaming || mMobileTypeId != 0) ? View.VISIBLE : View.GONE);
     }
 }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/SpeedBumpView.java b/packages/SystemUI/src/com/android/systemui/statusbar/SpeedBumpView.java
index 816612b..1fc8744 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/SpeedBumpView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/SpeedBumpView.java
@@ -126,9 +126,4 @@
         // TODO: Use duration
         performVisibilityAnimation(true, delay);
     }
-
-    @Override
-    public void setScrimAmount(float scrimAmount) {
-        // We don't need to scrim the speedbumps
-    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/StackScrollerDecorView.java b/packages/SystemUI/src/com/android/systemui/statusbar/StackScrollerDecorView.java
index 62a492e..64d80cc 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/StackScrollerDecorView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/StackScrollerDecorView.java
@@ -90,7 +90,6 @@
                     .alpha(endValue)
                     .setInterpolator(interpolator)
                     .setDuration(260)
-                    .withLayer()
                     .withEndAction(new Runnable() {
                         @Override
                         public void run() {
@@ -127,11 +126,6 @@
     }
 
     @Override
-    public void setScrimAmount(float scrimAmount) {
-        // We don't need to scrim the dismissView
-    }
-
-    @Override
     public boolean hasOverlappingRendering() {
         return false;
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/BarTransitions.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/BarTransitions.java
index 152bfdc..32fb567 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/BarTransitions.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/BarTransitions.java
@@ -139,7 +139,7 @@
                 mOpaque = res.getColor(R.color.system_bar_background_opaque);
                 mSemiTransparent = res.getColor(R.color.system_bar_background_semi_transparent);
                 mTransparent = res.getColor(R.color.system_bar_background_transparent);
-                mWarning = res.getColor(R.color.system_bar_background_warning);
+                mWarning = res.getColor(com.android.internal.R.color.battery_saver_mode_color);
             }
             mGradient = res.getDrawable(gradientResourceId);
             mInterpolator = new LinearInterpolator();
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/DemoStatusIcons.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DemoStatusIcons.java
index 936479b..c5d06b9 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/DemoStatusIcons.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DemoStatusIcons.java
@@ -120,6 +120,11 @@
                         : 0;
                 updateSlot("speakerphone", null, iconId);
             }
+            String cast = args.getString("cast");
+            if (cast != null) {
+                int iconId = cast.equals("cast") ? R.drawable.stat_sys_cast : 0;
+                updateSlot("cast", null, iconId);
+            }
         }
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java
new file mode 100644
index 0000000..b566bbc
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/DozeParameters.java
@@ -0,0 +1,171 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar.phone;
+
+import android.content.Context;
+import android.os.SystemProperties;
+import android.text.TextUtils;
+import android.util.Log;
+import android.util.MathUtils;
+
+import com.android.systemui.R;
+
+import java.io.PrintWriter;
+import java.util.Arrays;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+public class DozeParameters {
+    private static final String TAG = "DozeParameters";
+    private static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
+
+    private static final int MAX_DURATION = 10 * 1000;
+
+    private final Context mContext;
+
+    private static PulseSchedule sPulseSchedule;
+
+    public DozeParameters(Context context) {
+        mContext = context;
+    }
+
+    public void dump(PrintWriter pw) {
+        pw.println("  DozeParameters:");
+        pw.print("    getDisplayStateSupported(): "); pw.println(getDisplayStateSupported());
+        pw.print("    getPulseDuration(): "); pw.println(getPulseDuration());
+        pw.print("    getPulseInDuration(): "); pw.println(getPulseInDuration());
+        pw.print("    getPulseInVisibleDuration(): "); pw.println(getPulseVisibleDuration());
+        pw.print("    getPulseOutDuration(): "); pw.println(getPulseOutDuration());
+        pw.print("    getPulseOnSigMotion(): "); pw.println(getPulseOnSigMotion());
+        pw.print("    getVibrateOnSigMotion(): "); pw.println(getVibrateOnSigMotion());
+        pw.print("    getPulseOnPickup(): "); pw.println(getPulseOnPickup());
+        pw.print("    getVibrateOnPickup(): "); pw.println(getVibrateOnPickup());
+        pw.print("    getPulseOnNotifications(): "); pw.println(getPulseOnNotifications());
+        pw.print("    getPulseSchedule(): "); pw.println(getPulseSchedule());
+        pw.print("    getPulseScheduleResets(): "); pw.println(getPulseScheduleResets());
+        pw.print("    getPickupVibrationThreshold(): "); pw.println(getPickupVibrationThreshold());
+    }
+
+    public boolean getDisplayStateSupported() {
+        return getBoolean("doze.display.supported", R.bool.doze_display_state_supported);
+    }
+
+    public int getPulseDuration() {
+        return getPulseInDuration() + getPulseVisibleDuration() + getPulseOutDuration();
+    }
+
+    public int getPulseInDuration() {
+        return getInt("doze.pulse.duration.in", R.integer.doze_pulse_duration_in);
+    }
+
+    public int getPulseVisibleDuration() {
+        return getInt("doze.pulse.duration.visible", R.integer.doze_pulse_duration_visible);
+    }
+
+    public int getPulseOutDuration() {
+        return getInt("doze.pulse.duration.out", R.integer.doze_pulse_duration_out);
+    }
+
+    public boolean getPulseOnSigMotion() {
+        return getBoolean("doze.pulse.sigmotion", R.bool.doze_pulse_on_significant_motion);
+    }
+
+    public boolean getVibrateOnSigMotion() {
+        return SystemProperties.getBoolean("doze.vibrate.sigmotion", false);
+    }
+
+    public boolean getPulseOnPickup() {
+        return getBoolean("doze.pulse.pickup", R.bool.doze_pulse_on_pick_up);
+    }
+
+    public boolean getVibrateOnPickup() {
+        return SystemProperties.getBoolean("doze.vibrate.pickup", false);
+    }
+
+    public boolean getPulseOnNotifications() {
+        return getBoolean("doze.pulse.notifications", R.bool.doze_pulse_on_notifications);
+    }
+
+    public PulseSchedule getPulseSchedule() {
+        final String spec = getString("doze.pulse.schedule", R.string.doze_pulse_schedule);
+        if (sPulseSchedule == null || !sPulseSchedule.mSpec.equals(spec)) {
+            sPulseSchedule = PulseSchedule.parse(spec);
+        }
+        return sPulseSchedule;
+    }
+
+    public int getPulseScheduleResets() {
+        return getInt("doze.pulse.schedule.resets", R.integer.doze_pulse_schedule_resets);
+    }
+
+    public int getPickupVibrationThreshold() {
+        return getInt("doze.pickup.vibration.threshold", R.integer.doze_pickup_vibration_threshold);
+    }
+
+    private boolean getBoolean(String propName, int resId) {
+        return SystemProperties.getBoolean(propName, mContext.getResources().getBoolean(resId));
+    }
+
+    private int getInt(String propName, int resId) {
+        int value = SystemProperties.getInt(propName, mContext.getResources().getInteger(resId));
+        return MathUtils.constrain(value, 0, MAX_DURATION);
+    }
+
+    private String getString(String propName, int resId) {
+        return SystemProperties.get(propName, mContext.getString(resId));
+    }
+
+    public static class PulseSchedule {
+        private static final Pattern PATTERN = Pattern.compile("(\\d+?)s", 0);
+
+        private String mSpec;
+        private int[] mSchedule;
+
+        public static PulseSchedule parse(String spec) {
+            if (TextUtils.isEmpty(spec)) return null;
+            try {
+                final PulseSchedule rt = new PulseSchedule();
+                rt.mSpec = spec;
+                final String[] tokens = spec.split(",");
+                rt.mSchedule = new int[tokens.length];
+                for (int i = 0; i < tokens.length; i++) {
+                    final Matcher m = PATTERN.matcher(tokens[i]);
+                    if (!m.matches()) throw new IllegalArgumentException("Bad token: " + tokens[i]);
+                    rt.mSchedule[i] = Integer.parseInt(m.group(1));
+                }
+                if (DEBUG) Log.d(TAG, "Parsed spec [" + spec + "] as: " + rt);
+                return rt;
+            } catch (RuntimeException e) {
+                Log.w(TAG, "Error parsing spec: " + spec, e);
+                return null;
+            }
+        }
+
+        @Override
+        public String toString() {
+            return Arrays.toString(mSchedule);
+        }
+
+        public long getNextTime(long now, long notificationTime) {
+            for (int i = 0; i < mSchedule.length; i++) {
+                final long time = notificationTime + mSchedule[i] * 1000;
+                if (time > now) return time;
+            }
+            return 0;
+        }
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardAffordanceHelper.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardAffordanceHelper.java
index 20ffba2..a9c701a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardAffordanceHelper.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardAffordanceHelper.java
@@ -20,8 +20,6 @@
 import android.animation.AnimatorListenerAdapter;
 import android.animation.ValueAnimator;
 import android.content.Context;
-import android.os.PowerManager;
-import android.os.SystemClock;
 import android.view.MotionEvent;
 import android.view.VelocityTracker;
 import android.view.View;
@@ -59,9 +57,9 @@
     private int mMinTranslationAmount;
     private int mMinFlingVelocity;
     private int mHintGrowAmount;
-    private final KeyguardAffordanceView mLeftIcon;
-    private final KeyguardAffordanceView mCenterIcon;
-    private final KeyguardAffordanceView mRightIcon;
+    private KeyguardAffordanceView mLeftIcon;
+    private KeyguardAffordanceView mCenterIcon;
+    private KeyguardAffordanceView mRightIcon;
     private Interpolator mAppearInterpolator;
     private Interpolator mDisappearInterpolator;
     private Animator mSwipeAnimator;
@@ -84,15 +82,10 @@
     KeyguardAffordanceHelper(Callback callback, Context context) {
         mContext = context;
         mCallback = callback;
-        mLeftIcon = mCallback.getLeftIcon();
-        mLeftIcon.setIsLeft(true);
-        mCenterIcon = mCallback.getCenterIcon();
-        mRightIcon = mCallback.getRightIcon();
-        mLeftIcon.setPreviewView(mCallback.getLeftPreview());
-        mRightIcon.setPreviewView(mCallback.getRightPreview());
-        updateIcon(mLeftIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false);
-        updateIcon(mCenterIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false);
-        updateIcon(mRightIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false);
+        initIcons();
+        updateIcon(mLeftIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false, false);
+        updateIcon(mCenterIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false, false);
+        updateIcon(mRightIcon, 0.0f, SWIPE_RESTING_ALPHA_AMOUNT, false, false);
         initDimens();
     }
 
@@ -113,6 +106,16 @@
                 android.R.interpolator.fast_out_linear_in);
     }
 
+    private void initIcons() {
+        mLeftIcon = mCallback.getLeftIcon();
+        mLeftIcon.setIsLeft(true);
+        mCenterIcon = mCallback.getCenterIcon();
+        mRightIcon = mCallback.getRightIcon();
+        mRightIcon.setIsLeft(false);
+        mLeftIcon.setPreviewView(mCallback.getLeftPreview());
+        mRightIcon.setPreviewView(mCallback.getRightPreview());
+    }
+
     public boolean onTouchEvent(MotionEvent event) {
         int pointerIndex = event.findPointerIndex(mTrackingPointer);
         if (pointerIndex < 0) {
@@ -290,8 +293,7 @@
         float vel = getCurrentVelocity();
 
         // We snap back if the current translation is not far enough
-        boolean snapBack = Math.abs(mTranslation) < Math.abs(mTranslationOnDown)
-                + mMinTranslationAmount;
+        boolean snapBack = isBelowFalsingThreshold();
 
         // or if the velocity is in the opposite direction.
         boolean velIsInWrongDirection = vel * mTranslation < 0;
@@ -300,6 +302,11 @@
         fling(vel, snapBack || forceSnapBack);
     }
 
+    private boolean isBelowFalsingThreshold() {
+        return Math.abs(mTranslation) < Math.abs(mTranslationOnDown)
+                + mMinTranslationAmount;
+    }
+
     private void fling(float vel, final boolean snapBack) {
         float target = mTranslation < 0 ? -mCallback.getPageWidth() : mCallback.getPageWidth();
         target = snapBack ? 0 : target;
@@ -350,13 +357,14 @@
 
             boolean animateIcons = isReset && animateReset;
             float radius = getRadiusFromTranslation(absTranslation);
+            boolean slowAnimation = isReset && isBelowFalsingThreshold();
             if (!isReset) {
-                updateIcon(targetView, radius, alpha, false);
+                updateIcon(targetView, radius, alpha, false, false);
             } else {
-                updateIcon(targetView, 0.0f, fadeOutAlpha, animateIcons);
+                updateIcon(targetView, 0.0f, fadeOutAlpha, animateIcons, slowAnimation);
             }
-            updateIcon(otherView, 0.0f, fadeOutAlpha, animateIcons);
-            updateIcon(mCenterIcon, 0.0f, fadeOutAlpha, animateIcons);
+            updateIcon(otherView, 0.0f, fadeOutAlpha, animateIcons, slowAnimation);
+            updateIcon(mCenterIcon, 0.0f, fadeOutAlpha, animateIcons, slowAnimation);
 
             mTranslation = translation;
         }
@@ -387,16 +395,16 @@
     }
 
     public void animateHideLeftRightIcon() {
-        updateIcon(mRightIcon, 0f, 0f, true);
-        updateIcon(mLeftIcon, 0f, 0f, true);
+        updateIcon(mRightIcon, 0f, 0f, true, false);
+        updateIcon(mLeftIcon, 0f, 0f, true, false);
     }
 
     private void updateIcon(KeyguardAffordanceView view, float circleRadius, float alpha,
-            boolean animate) {
+            boolean animate, boolean slowRadiusAnimation) {
         if (view.getVisibility() != View.VISIBLE) {
             return;
         }
-        view.setCircleRadius(circleRadius);
+        view.setCircleRadius(circleRadius, slowRadiusAnimation);
         updateIconAlpha(view, alpha, animate);
     }
 
@@ -436,6 +444,7 @@
 
     public void onConfigurationChanged() {
         initDimens();
+        initIcons();
     }
 
     public void reset(boolean animate) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java
index 3e2a398..754fade 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java
@@ -25,18 +25,20 @@
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
 import android.content.res.Configuration;
+import android.graphics.drawable.Drawable;
+import android.graphics.drawable.InsetDrawable;
 import android.os.AsyncTask;
+import android.os.Bundle;
 import android.os.RemoteException;
 import android.os.UserHandle;
-import android.phone.PhoneManager;
 import android.provider.MediaStore;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.util.AttributeSet;
 import android.util.Log;
 import android.util.TypedValue;
 import android.view.View;
 import android.view.ViewGroup;
-import android.view.accessibility.AccessibilityManager;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.FrameLayout;
 import android.widget.TextView;
 
@@ -44,17 +46,23 @@
 import com.android.keyguard.KeyguardUpdateMonitor;
 import com.android.keyguard.KeyguardUpdateMonitorCallback;
 import com.android.systemui.R;
-import com.android.systemui.statusbar.KeyguardIndicationController;
-import com.android.systemui.statusbar.policy.FlashlightController;
+import com.android.systemui.statusbar.CommandQueue;
 import com.android.systemui.statusbar.KeyguardAffordanceView;
+import com.android.systemui.statusbar.KeyguardIndicationController;
+import com.android.systemui.statusbar.policy.AccessibilityController;
+import com.android.systemui.statusbar.policy.FlashlightController;
 import com.android.systemui.statusbar.policy.PreviewInflater;
 
+import static android.view.accessibility.AccessibilityNodeInfo.ACTION_CLICK;
+import static android.view.accessibility.AccessibilityNodeInfo.AccessibilityAction;
+
 /**
  * Implementation for the bottom area of the Keyguard, including camera/phone affordance and status
  * text.
  */
 public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickListener,
-        UnlockMethodCache.OnUnlockMethodChangedListener {
+        UnlockMethodCache.OnUnlockMethodChangedListener,
+        AccessibilityController.AccessibilityStateChangedCallback, View.OnLongClickListener {
 
     final static String TAG = "PhoneStatusBar/KeyguardBottomAreaView";
 
@@ -80,25 +88,68 @@
     private FlashlightController mFlashlightController;
     private PreviewInflater mPreviewInflater;
     private KeyguardIndicationController mIndicationController;
-    private boolean mFaceUnlockRunning;
+    private AccessibilityController mAccessibilityController;
+    private PhoneStatusBar mPhoneStatusBar;
+
+    private final TrustDrawable mTrustDrawable;
+
+    private int mLastUnlockIconRes = 0;
 
     public KeyguardBottomAreaView(Context context) {
-        super(context);
+        this(context, null);
     }
 
     public KeyguardBottomAreaView(Context context, AttributeSet attrs) {
-        super(context, attrs);
+        this(context, attrs, 0);
     }
 
     public KeyguardBottomAreaView(Context context, AttributeSet attrs, int defStyleAttr) {
-        super(context, attrs, defStyleAttr);
+        this(context, attrs, defStyleAttr, 0);
     }
 
     public KeyguardBottomAreaView(Context context, AttributeSet attrs, int defStyleAttr,
             int defStyleRes) {
         super(context, attrs, defStyleAttr, defStyleRes);
+        mTrustDrawable = new TrustDrawable(mContext);
     }
 
+    private AccessibilityDelegate mAccessibilityDelegate = new AccessibilityDelegate() {
+        @Override
+        public void onInitializeAccessibilityNodeInfo(View host, AccessibilityNodeInfo info) {
+            super.onInitializeAccessibilityNodeInfo(host, info);
+            String label = null;
+            if (host == mLockIcon) {
+                label = getResources().getString(R.string.unlock_label);
+            } else if (host == mCameraImageView) {
+                label = getResources().getString(R.string.camera_label);
+            } else if (host == mPhoneImageView) {
+                label = getResources().getString(R.string.phone_label);
+            }
+            info.addAction(new AccessibilityAction(ACTION_CLICK, label));
+        }
+
+        @Override
+        public boolean performAccessibilityAction(View host, int action, Bundle args) {
+            if (action == ACTION_CLICK) {
+                if (host == mLockIcon) {
+                    if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                        Log.i(TAG, "Collapsing panel from lock icon accessibility click");
+                    }
+                    mPhoneStatusBar.animateCollapsePanels(
+                            CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
+                    return true;
+                } else if (host == mCameraImageView) {
+                    launchCamera();
+                    return true;
+                } else if (host == mPhoneImageView) {
+                    launchPhone();
+                    return true;
+                }
+            }
+            return super.performAccessibilityAction(host, action, args);
+        }
+    };
+
     @Override
     protected void onFinishInflate() {
         super.onFinishInflate();
@@ -109,7 +160,6 @@
         mLockIcon = (KeyguardAffordanceView) findViewById(R.id.lock_icon);
         mIndicationText = (TextView) findViewById(R.id.keyguard_indication_text);
         watchForCameraPolicyChanges();
-        watchForAccessibilityChanges();
         updateCameraVisibility();
         updatePhoneVisibility();
         mUnlockMethodCache = UnlockMethodCache.getInstance(getContext());
@@ -120,6 +170,17 @@
         mPreviewInflater = new PreviewInflater(mContext, new LockPatternUtils(mContext));
         inflatePreviews();
         mLockIcon.setOnClickListener(this);
+        mLockIcon.setBackground(mTrustDrawable);
+        mLockIcon.setOnLongClickListener(this);
+        mCameraImageView.setOnClickListener(this);
+        mPhoneImageView.setOnClickListener(this);
+        initAccessibility();
+    }
+
+    private void initAccessibility() {
+        mLockIcon.setAccessibilityDelegate(mAccessibilityDelegate);
+        mPhoneImageView.setAccessibilityDelegate(mAccessibilityDelegate);
+        mCameraImageView.setAccessibilityDelegate(mAccessibilityDelegate);
     }
 
     @Override
@@ -147,6 +208,15 @@
         mFlashlightController = flashlightController;
     }
 
+    public void setAccessibilityController(AccessibilityController accessibilityController) {
+        mAccessibilityController = accessibilityController;
+        accessibilityController.addStateChangedCallback(this);
+    }
+
+    public void setPhoneStatusBar(PhoneStatusBar phoneStatusBar) {
+        mPhoneStatusBar = phoneStatusBar;
+    }
+
     private Intent getCameraIntent() {
         KeyguardUpdateMonitor updateMonitor = KeyguardUpdateMonitor.getInstance(mContext);
         boolean currentUserHasTrust = updateMonitor.getUserHasTrust(
@@ -159,7 +229,8 @@
         ResolveInfo resolved = mContext.getPackageManager().resolveActivityAsUser(getCameraIntent(),
                 PackageManager.MATCH_DEFAULT_ONLY,
                 mLockPatternUtils.getCurrentUser());
-        boolean visible = !isCameraDisabledByDpm() && resolved != null;
+        boolean visible = !isCameraDisabledByDpm() && resolved != null
+                && getResources().getBoolean(R.bool.config_keyguardShowCameraAffordance);
         mCameraImageView.setVisibility(visible ? View.VISIBLE : View.GONE);
     }
 
@@ -200,28 +271,24 @@
         KeyguardUpdateMonitor.getInstance(mContext).registerCallback(mUpdateMonitorCallback);
     }
 
-    private void watchForAccessibilityChanges() {
-        final AccessibilityManager am =
-                (AccessibilityManager) getContext().getSystemService(Context.ACCESSIBILITY_SERVICE);
-
-        // Set the initial state
-        enableAccessibility(am.isTouchExplorationEnabled());
-
-        // Watch for changes
-        am.addTouchExplorationStateChangeListener(
-                new AccessibilityManager.TouchExplorationStateChangeListener() {
-            @Override
-            public void onTouchExplorationStateChanged(boolean enabled) {
-                enableAccessibility(enabled);
-            }
-        });
+    @Override
+    public void onStateChanged(boolean accessibilityEnabled, boolean touchExplorationEnabled) {
+        mCameraImageView.setClickable(touchExplorationEnabled);
+        mPhoneImageView.setClickable(touchExplorationEnabled);
+        mCameraImageView.setFocusable(accessibilityEnabled);
+        mPhoneImageView.setFocusable(accessibilityEnabled);
+        updateLockIconClickability();
     }
 
-    private void enableAccessibility(boolean touchExplorationEnabled) {
-        mCameraImageView.setOnClickListener(touchExplorationEnabled ? this : null);
-        mCameraImageView.setClickable(touchExplorationEnabled);
-        mPhoneImageView.setOnClickListener(touchExplorationEnabled ? this : null);
-        mPhoneImageView.setClickable(touchExplorationEnabled);
+    private void updateLockIconClickability() {
+        if (mAccessibilityController == null) {
+            return;
+        }
+        mLockIcon.setClickable(mUnlockMethodCache.isTrustManaged()
+                || mAccessibilityController.isTouchExplorationEnabled());
+        mLockIcon.setLongClickable(mAccessibilityController.isTouchExplorationEnabled()
+                && mUnlockMethodCache.isTrustManaged());
+        mLockIcon.setFocusable(mAccessibilityController.isAccessibilityEnabled());
     }
 
     @Override
@@ -231,31 +298,49 @@
         } else if (v == mPhoneImageView) {
             launchPhone();
         } if (v == mLockIcon) {
-            mIndicationController.showTransientIndication(
-                    R.string.keyguard_indication_trust_disabled);
-            mLockPatternUtils.requireCredentialEntry(mLockPatternUtils.getCurrentUser());
+            if (!mAccessibilityController.isAccessibilityEnabled()) {
+                handleTrustCircleClick();
+            } else {
+                mPhoneStatusBar.animateCollapsePanels(
+                        CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
+            }
         }
     }
 
+    @Override
+    public boolean onLongClick(View v) {
+        handleTrustCircleClick();
+        return true;
+    }
+
+    private void handleTrustCircleClick() {
+        mIndicationController.showTransientIndication(
+                R.string.keyguard_indication_trust_disabled);
+        mLockPatternUtils.requireCredentialEntry(mLockPatternUtils.getCurrentUser());
+    }
+
     public void launchCamera() {
         mFlashlightController.killFlashlight();
         Intent intent = getCameraIntent();
-        if (intent == SECURE_CAMERA_INTENT &&
-                !mPreviewInflater.wouldLaunchResolverActivity(intent)) {
+        boolean wouldLaunchResolverActivity = PreviewInflater.wouldLaunchResolverActivity(
+                mContext, intent, mLockPatternUtils.getCurrentUser());
+        if (intent == SECURE_CAMERA_INTENT && !wouldLaunchResolverActivity) {
             mContext.startActivityAsUser(intent, UserHandle.CURRENT);
         } else {
+
+            // We need to delay starting the activity because ResolverActivity finishes itself if
+            // launched behind lockscreen.
             mActivityStarter.startActivity(intent, false /* dismissShade */);
         }
     }
 
     public void launchPhone() {
-        TelecommManager tm = TelecommManager.from(mContext);
-        if (tm.isInAPhoneCall()) {
-            final PhoneManager pm = (PhoneManager) mContext.getSystemService(Context.PHONE_SERVICE);
+        final TelecomManager tm = TelecomManager.from(mContext);
+        if (tm.isInCall()) {
             AsyncTask.execute(new Runnable() {
                 @Override
                 public void run() {
-                    pm.showCallScreen(false /* showDialpad */);
+                    tm.showInCallScreen(false /* showDialpad */);
                 }
             });
         } else {
@@ -267,27 +352,56 @@
     @Override
     protected void onVisibilityChanged(View changedView, int visibility) {
         super.onVisibilityChanged(changedView, visibility);
+        if (isShown()) {
+            mTrustDrawable.start();
+        } else {
+            mTrustDrawable.stop();
+        }
         if (changedView == this && visibility == VISIBLE) {
             updateLockIcon();
             updateCameraVisibility();
         }
     }
 
+    @Override
+    protected void onDetachedFromWindow() {
+        super.onDetachedFromWindow();
+        mTrustDrawable.stop();
+    }
+
     private void updateLockIcon() {
-        if (getVisibility() != VISIBLE) {
+        boolean visible = isShown() && KeyguardUpdateMonitor.getInstance(mContext).isScreenOn();
+        if (visible) {
+            mTrustDrawable.start();
+        } else {
+            mTrustDrawable.stop();
+        }
+        if (!visible) {
             return;
         }
         // TODO: Real icon for facelock.
-        int iconRes = mFaceUnlockRunning ? R.drawable.ic_account_circle
+        int iconRes = mUnlockMethodCache.isFaceUnlockRunning()
+                ? com.android.internal.R.drawable.ic_account_circle
                 : mUnlockMethodCache.isMethodInsecure() ? R.drawable.ic_lock_open_24dp
                 : R.drawable.ic_lock_24dp;
-        mLockIcon.setImageResource(iconRes);
+        if (mLastUnlockIconRes != iconRes) {
+            Drawable icon = mContext.getDrawable(iconRes);
+            int iconHeight = getResources().getDimensionPixelSize(
+                    R.dimen.keyguard_affordance_icon_height);
+            int iconWidth = getResources().getDimensionPixelSize(
+                    R.dimen.keyguard_affordance_icon_width);
+            if (icon.getIntrinsicHeight() != iconHeight || icon.getIntrinsicWidth() != iconWidth) {
+                icon = new IntrinsicSizeDrawable(icon, iconWidth, iconHeight);
+            }
+            mLockIcon.setImageDrawable(icon);
+        }
         boolean trustManaged = mUnlockMethodCache.isTrustManaged();
-        mLockIcon.setBackgroundResource(trustManaged && !mFaceUnlockRunning
-                ? R.drawable.trust_circle : 0);
-        mLockIcon.setClickable(trustManaged);
+        mTrustDrawable.setTrustManaged(trustManaged);
+        updateLockIconClickability();
     }
 
+
+
     public KeyguardAffordanceView getPhoneView() {
         return mPhoneImageView;
     }
@@ -355,8 +469,12 @@
         }
 
         @Override
-        public void onFaceUnlockStateChanged(boolean running) {
-            mFaceUnlockRunning = running;
+        public void onScreenTurnedOn() {
+            updateLockIcon();
+        }
+
+        @Override
+        public void onScreenTurnedOff(int why) {
             updateLockIcon();
         }
     };
@@ -365,4 +483,30 @@
             KeyguardIndicationController keyguardIndicationController) {
         mIndicationController = keyguardIndicationController;
     }
+
+
+    /**
+     * A wrapper around another Drawable that overrides the intrinsic size.
+     */
+    private static class IntrinsicSizeDrawable extends InsetDrawable {
+
+        private final int mIntrinsicWidth;
+        private final int mIntrinsicHeight;
+
+        public IntrinsicSizeDrawable(Drawable drawable, int intrinsicWidth, int intrinsicHeight) {
+            super(drawable, 0);
+            mIntrinsicWidth = intrinsicWidth;
+            mIntrinsicHeight = intrinsicHeight;
+        }
+
+        @Override
+        public int getIntrinsicWidth() {
+            return mIntrinsicWidth;
+        }
+
+        @Override
+        public int getIntrinsicHeight() {
+            return mIntrinsicHeight;
+        }
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
index fc737be..5507944 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
@@ -17,14 +17,11 @@
 package com.android.systemui.statusbar.phone;
 
 import android.content.Context;
-import android.os.SystemClock;
+import android.view.Choreographer;
 import android.view.KeyEvent;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
-import android.view.animation.AnimationUtils;
-import android.view.animation.Interpolator;
-import android.view.animation.LinearInterpolator;
 
 import com.android.internal.widget.LockPatternUtils;
 import com.android.keyguard.KeyguardViewBase;
@@ -33,7 +30,7 @@
 import com.android.systemui.keyguard.KeyguardViewMediator;
 
 import static com.android.keyguard.KeyguardHostView.OnDismissAction;
-import static com.android.keyguard.KeyguardSecurityModel.*;
+import static com.android.keyguard.KeyguardSecurityModel.SecurityMode;
 
 /**
  * A class which manages the bouncer on the lockscreen.
@@ -47,7 +44,8 @@
     private StatusBarWindowManager mWindowManager;
     private KeyguardViewBase mKeyguardView;
     private ViewGroup mRoot;
-    private boolean mFadingOut;
+    private boolean mShowingSoon;
+    private Choreographer mChoreographer = Choreographer.getInstance();
 
     public KeyguardBouncer(Context context, ViewMediatorCallback callback,
             LockPatternUtils lockPatternUtils, StatusBarWindowManager windowManager,
@@ -61,17 +59,38 @@
 
     public void show() {
         ensureView();
-        if (mRoot.getVisibility() == View.VISIBLE) {
+        if (mRoot.getVisibility() == View.VISIBLE || mShowingSoon) {
+
+            // show() updates the current security method. This is needed in case we are already
+            // showing and the current security method changed.
+            mKeyguardView.show();
             return;
         }
 
         // Try to dismiss the Keyguard. If no security pattern is set, this will dismiss the whole
         // Keyguard. If we need to authenticate, show the bouncer.
         if (!mKeyguardView.dismiss()) {
+            mShowingSoon = true;
+
+            // Split up the work over multiple frames.
+            mChoreographer.postCallbackDelayed(Choreographer.CALLBACK_ANIMATION, mShowRunnable,
+                    null, 48);
+        }
+    }
+
+    private final Runnable mShowRunnable = new Runnable() {
+        @Override
+        public void run() {
             mRoot.setVisibility(View.VISIBLE);
             mKeyguardView.onResume();
             mKeyguardView.startAppearAnimation();
+            mShowingSoon = false;
         }
+    };
+
+    private void cancelShowRunnable() {
+        mChoreographer.removeCallbacks(Choreographer.CALLBACK_ANIMATION, mShowRunnable, null);
+        mShowingSoon = false;
     }
 
     public void showWithDismissAction(OnDismissAction r) {
@@ -81,7 +100,8 @@
     }
 
     public void hide(boolean destroyView) {
-        if (mKeyguardView != null) {
+        cancelShowRunnable();
+         if (mKeyguardView != null) {
             mKeyguardView.setOnDismissAction(null);
             mKeyguardView.cleanUp();
         }
@@ -107,6 +127,7 @@
      * Reset the state of the view.
      */
     public void reset() {
+        cancelShowRunnable();
         inflateView();
     }
 
@@ -127,7 +148,7 @@
     }
 
     public boolean isShowing() {
-        return mRoot != null && mRoot.getVisibility() == View.VISIBLE && !mFadingOut;
+        return mShowingSoon || (mRoot != null && mRoot.getVisibility() == View.VISIBLE);
     }
 
     public void prepare() {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardStatusBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardStatusBarView.java
index 5e5c3aa..650a14f 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardStatusBarView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardStatusBarView.java
@@ -30,6 +30,7 @@
 import android.widget.RelativeLayout;
 import android.widget.TextView;
 
+import com.android.systemui.BatteryMeterView;
 import com.android.systemui.R;
 import com.android.systemui.statusbar.policy.BatteryController;
 import com.android.systemui.statusbar.policy.KeyguardUserSwitcher;
@@ -135,6 +136,7 @@
 
     public void setBatteryController(BatteryController batteryController) {
         mBatteryController = batteryController;
+        ((BatteryMeterView) findViewById(R.id.battery)).setBatteryController(batteryController);
     }
 
     public void setUserInfoController(UserInfoController userInfoController) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/MultiUserSwitch.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/MultiUserSwitch.java
index d7144da..685c184 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/MultiUserSwitch.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/MultiUserSwitch.java
@@ -30,6 +30,7 @@
 import com.android.systemui.R;
 import com.android.systemui.qs.QSPanel;
 import com.android.systemui.statusbar.policy.KeyguardUserSwitcher;
+import com.android.systemui.statusbar.policy.UserSwitcherController;
 
 /**
  * Container for image of the multi user switcher (tappable).
@@ -73,8 +74,10 @@
                     mKeyguardUserSwitcher.show(true /* animate */);
                 }
             } else {
-                mQsPanel.showDetailAdapter(true,
-                        mQsPanel.getHost().getUserSwitcherController().userDetailAdapter);
+                if (mQsPanel != null) {
+                    mQsPanel.showDetailAdapter(true,
+                            mQsPanel.getHost().getUserSwitcherController().userDetailAdapter);
+                }
             }
         } else {
             Intent intent = ContactsContract.QuickContact.composeQuickContactsIntent(
@@ -90,9 +93,24 @@
 
         if (isClickable()) {
             final UserManager um = UserManager.get(getContext());
-            String text = mContext.getString(um.isUserSwitcherEnabled()
-                    ? R.string.accessibility_multi_user_switch_switcher
-                    : R.string.accessibility_multi_user_switch_quick_contact);
+            String text;
+            if (um.isUserSwitcherEnabled()) {
+                String currentUser = null;
+                if (mQsPanel != null) {
+                    UserSwitcherController controller = mQsPanel.getHost()
+                            .getUserSwitcherController();
+                    currentUser = controller.getCurrentUserName(mContext);
+                }
+                if (TextUtils.isEmpty(currentUser)) {
+                    text = mContext.getString(R.string.accessibility_multi_user_switch_switcher);
+                } else {
+                    text = mContext.getString(
+                            R.string.accessibility_multi_user_switch_switcher_with_current,
+                            currentUser);
+                }
+            } else {
+                text = mContext.getString(R.string.accessibility_multi_user_switch_quick_contact);
+            }
             if (!TextUtils.isEmpty(text)) {
                 event.getText().add(text);
             }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarTransitions.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarTransitions.java
index 50ddeb3..f3930ba 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarTransitions.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarTransitions.java
@@ -79,6 +79,7 @@
         setKeyButtonViewQuiescentAlpha(mView.getHomeButton(), alpha, animate);
         setKeyButtonViewQuiescentAlpha(mView.getRecentsButton(), alpha, animate);
         setKeyButtonViewQuiescentAlpha(mView.getMenuButton(), alpha, animate);
+        setKeyButtonViewQuiescentAlpha(mView.getImeSwitchButton(), alpha, animate);
 
         applyBackButtonQuiescentAlpha(mode, animate);
 
@@ -96,6 +97,7 @@
         backAlpha = maxVisibleQuiescentAlpha(backAlpha, mView.getHomeButton());
         backAlpha = maxVisibleQuiescentAlpha(backAlpha, mView.getRecentsButton());
         backAlpha = maxVisibleQuiescentAlpha(backAlpha, mView.getMenuButton());
+        backAlpha = maxVisibleQuiescentAlpha(backAlpha, mView.getImeSwitchButton());
         if (backAlpha > 0) {
             setKeyButtonViewQuiescentAlpha(mView.getBackButton(), backAlpha, animate);
         }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
index 3592971..88e71e2 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
@@ -23,6 +23,7 @@
 import android.animation.ValueAnimator;
 import android.app.StatusBarManager;
 import android.content.Context;
+import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.graphics.Point;
 import android.graphics.Rect;
@@ -48,13 +49,12 @@
 
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
+import java.util.ArrayList;
 
 public class NavigationBarView extends LinearLayout {
     final static boolean DEBUG = false;
     final static String TAG = "PhoneStatusBar/NavigationBarView";
 
-    final static boolean NAVBAR_ALWAYS_AT_RIGHT = true;
-
     // slippery nav bar when everything is disabled, e.g. during setup
     final static boolean SLIPPERY_WHEN_DISABLED = true;
 
@@ -87,6 +87,8 @@
     private final NavTransitionListener mTransitionListener = new NavTransitionListener();
 
     private OnVerticalChangedListener mOnVerticalChangedListener;
+    private boolean mIsLayoutRtl;
+    private boolean mDelegateIntercepted;
 
     private class NavTransitionListener implements TransitionListener {
         private boolean mBackTransitioning;
@@ -197,27 +199,45 @@
 
     public void setOnVerticalChangedListener(OnVerticalChangedListener onVerticalChangedListener) {
         mOnVerticalChangedListener = onVerticalChangedListener;
+        notifyVerticalChangedListener(mVertical);
     }
 
     @Override
     public boolean onTouchEvent(MotionEvent event) {
-        if (mTaskSwitchHelper.onTouchEvent(event)) {
+        initDownStates(event);
+        if (!mDelegateIntercepted && mTaskSwitchHelper.onTouchEvent(event)) {
             return true;
         }
         if (mDeadZone != null && event.getAction() == MotionEvent.ACTION_OUTSIDE) {
             mDeadZone.poke(event);
         }
-        if (mDelegateHelper != null) {
+        if (mDelegateHelper != null && mDelegateIntercepted) {
             boolean ret = mDelegateHelper.onInterceptTouchEvent(event);
             if (ret) return true;
         }
         return super.onTouchEvent(event);
     }
 
+    private void initDownStates(MotionEvent ev) {
+        if (ev.getAction() == MotionEvent.ACTION_DOWN) {
+            mDelegateIntercepted = false;
+        }
+    }
+
     @Override
     public boolean onInterceptTouchEvent(MotionEvent event) {
-        return mTaskSwitchHelper.onInterceptTouchEvent(event) ||
-                mDelegateHelper.onInterceptTouchEvent(event);
+        initDownStates(event);
+        boolean intercept = mTaskSwitchHelper.onInterceptTouchEvent(event);
+        if (!intercept) {
+            mDelegateIntercepted = mDelegateHelper.onInterceptTouchEvent(event);
+            intercept = mDelegateIntercepted;
+        } else {
+            MotionEvent cancelEvent = MotionEvent.obtain(event);
+            cancelEvent.setAction(MotionEvent.ACTION_CANCEL);
+            mDelegateHelper.onInterceptTouchEvent(cancelEvent);
+            cancelEvent.recycle();
+        }
+        return intercept;
     }
 
     private H mHandler = new H();
@@ -387,13 +407,13 @@
 
         mRotatedViews[Surface.ROTATION_90] = findViewById(R.id.rot90);
 
-        mRotatedViews[Surface.ROTATION_270] = NAVBAR_ALWAYS_AT_RIGHT
-                                                ? findViewById(R.id.rot90)
-                                                : findViewById(R.id.rot270);
+        mRotatedViews[Surface.ROTATION_270] = mRotatedViews[Surface.ROTATION_90];
 
         mCurrentView = mRotatedViews[Surface.ROTATION_0];
 
         getImeSwitchButton().setOnClickListener(mImeSwitcherClickListener);
+
+        updateRTLOrder();
     }
 
     public boolean isVertical() {
@@ -425,12 +445,16 @@
         if (mDelegateHelper != null) {
             mDelegateHelper.setSwapXY(mVertical);
         }
-        boolean isRTL = (getLayoutDirection() == View.LAYOUT_DIRECTION_RTL);
-        mTaskSwitchHelper.setBarState(mVertical, isRTL);
+        updateTaskSwitchHelper();
 
         setNavigationIconHints(mNavigationIconHints, true);
     }
 
+    private void updateTaskSwitchHelper() {
+        boolean isRtl = (getLayoutDirection() == View.LAYOUT_DIRECTION_RTL);
+        mTaskSwitchHelper.setBarState(mVertical, isRtl);
+    }
+
     @Override
     protected void onLayout(boolean changed, int l, int t, int r, int b) {
         super.onLayout(changed, l, t, r, b);
@@ -447,15 +471,70 @@
             mVertical = newVertical;
             //Log.v(TAG, String.format("onSizeChanged: h=%d, w=%d, vert=%s", h, w, mVertical?"y":"n"));
             reorient();
-            if (mOnVerticalChangedListener != null) {
-                mOnVerticalChangedListener.onVerticalChanged(newVertical);
-            }
+            notifyVerticalChangedListener(newVertical);
         }
 
         postCheckForInvalidLayout("sizeChanged");
         super.onSizeChanged(w, h, oldw, oldh);
     }
 
+    private void notifyVerticalChangedListener(boolean newVertical) {
+        if (mOnVerticalChangedListener != null) {
+            mOnVerticalChangedListener.onVerticalChanged(newVertical);
+        }
+    }
+
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        updateRTLOrder();
+        updateTaskSwitchHelper();
+    }
+
+    /**
+     * In landscape, the LinearLayout is not auto mirrored since it is vertical. Therefore we
+     * have to do it manually
+     */
+    private void updateRTLOrder() {
+        boolean isLayoutRtl = getResources().getConfiguration()
+                .getLayoutDirection() == LAYOUT_DIRECTION_RTL;
+        if (mIsLayoutRtl != isLayoutRtl) {
+
+            // We swap all children of the 90 and 270 degree layouts, since they are vertical
+            View rotation90 = mRotatedViews[Surface.ROTATION_90];
+            swapChildrenOrderIfVertical(rotation90.findViewById(R.id.nav_buttons));
+
+            View rotation270 = mRotatedViews[Surface.ROTATION_270];
+            if (rotation90 != rotation270) {
+                swapChildrenOrderIfVertical(rotation270.findViewById(R.id.nav_buttons));
+            }
+            mIsLayoutRtl = isLayoutRtl;
+        }
+    }
+
+
+    /**
+     * Swaps the children order of a LinearLayout if it's orientation is Vertical
+     *
+     * @param group The LinearLayout to swap the children from.
+     */
+    private void swapChildrenOrderIfVertical(View group) {
+        if (group instanceof LinearLayout) {
+            LinearLayout linearLayout = (LinearLayout) group;
+            if (linearLayout.getOrientation() == VERTICAL) {
+                int childCount = linearLayout.getChildCount();
+                ArrayList<View> childList = new ArrayList<>(childCount);
+                for (int i = 0; i < childCount; i++) {
+                    childList.add(linearLayout.getChildAt(i));
+                }
+                linearLayout.removeAllViews();
+                for (int i = childCount - 1; i >= 0; i--) {
+                    linearLayout.addView(childList.get(i));
+                }
+            }
+        }
+    }
+
     /*
     @Override
     protected void onLayout (boolean changed, int left, int top, int right, int bottom) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarViewTaskSwitchHelper.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarViewTaskSwitchHelper.java
index 3c20d1f..c253e19 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarViewTaskSwitchHelper.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarViewTaskSwitchHelper.java
@@ -31,12 +31,12 @@
     private final GestureDetector mTaskSwitcherDetector;
     private final int mScrollTouchSlop;
     private final int mMinFlingVelocity;
-    private boolean mInterceptTouches;
     private int mTouchDownX;
+    private int mTouchDownY;
 
     public NavigationBarViewTaskSwitchHelper(Context context) {
         ViewConfiguration configuration = ViewConfiguration.get(context);
-        mScrollTouchSlop = configuration.getScaledTouchSlop();
+        mScrollTouchSlop = 4 * configuration.getScaledTouchSlop();
         mMinFlingVelocity = configuration.getScaledMinimumFlingVelocity();
         mTaskSwitcherDetector = new GestureDetector(context, this);
     }
@@ -55,30 +55,34 @@
         // task switcher detector
         mTaskSwitcherDetector.onTouchEvent(event);
         int action = event.getAction();
+        boolean intercepted = false;
         switch (action & MotionEvent.ACTION_MASK) {
             case MotionEvent.ACTION_DOWN: {
                 mTouchDownX = (int) event.getX();
-                mInterceptTouches = false;
+                mTouchDownY = (int) event.getY();
                 break;
             }
             case MotionEvent.ACTION_MOVE: {
                 int x = (int) event.getX();
-                if (Math.abs(x - mTouchDownX) > mScrollTouchSlop) {
-                    mInterceptTouches = true;
+                int y = (int) event.getY();
+                int xDiff = Math.abs(x - mTouchDownX);
+                int yDiff = Math.abs(y - mTouchDownY);
+                boolean exceededTouchSlop = !mIsVertical
+                        ? xDiff > mScrollTouchSlop && xDiff > yDiff
+                        : yDiff > mScrollTouchSlop && yDiff > xDiff;
+                if (exceededTouchSlop) {
                     return true;
                 }
                 break;
             }
             case MotionEvent.ACTION_CANCEL:
             case MotionEvent.ACTION_UP:
-                mInterceptTouches = false;
                 break;
         }
-        return mInterceptTouches;
+        return intercepted;
     }
 
     public boolean onTouchEvent(MotionEvent event) {
-        if (!mInterceptTouches) return false;
         return mTaskSwitcherDetector.onTouchEvent(event);
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
index 42ae0c9..c04ca83 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
@@ -23,27 +23,27 @@
 import android.animation.ValueAnimator;
 import android.content.Context;
 import android.content.res.Configuration;
+import android.graphics.Color;
+import android.graphics.drawable.ColorDrawable;
 import android.util.AttributeSet;
 import android.util.MathUtils;
 import android.view.MotionEvent;
 import android.view.VelocityTracker;
 import android.view.View;
-import android.view.ViewGroup;
 import android.view.ViewTreeObserver;
 import android.view.accessibility.AccessibilityEvent;
 import android.view.animation.AnimationUtils;
 import android.view.animation.Interpolator;
 import android.widget.FrameLayout;
-import android.widget.LinearLayout;
 import android.widget.TextView;
 
+import com.android.keyguard.KeyguardStatusView;
 import com.android.systemui.R;
 import com.android.systemui.qs.QSPanel;
 import com.android.systemui.statusbar.ExpandableView;
 import com.android.systemui.statusbar.FlingAnimationUtils;
 import com.android.systemui.statusbar.GestureRecorder;
 import com.android.systemui.statusbar.KeyguardAffordanceView;
-import com.android.systemui.statusbar.MirrorView;
 import com.android.systemui.statusbar.StatusBarState;
 import com.android.systemui.statusbar.policy.KeyguardUserSwitcher;
 import com.android.systemui.statusbar.stack.NotificationStackScrollLayout;
@@ -59,20 +59,23 @@
     private static final int CAP_HEIGHT = 1456;
     private static final int FONT_HEIGHT = 2163;
 
-    private static final float HEADER_RUBBERBAND_FACTOR = 2.15f;
+    private static final float HEADER_RUBBERBAND_FACTOR = 2.05f;
     private static final float LOCK_ICON_ACTIVE_SCALE = 1.2f;
 
+    private static final int DOZE_BACKGROUND_COLOR = 0xff000000;
+    private static final int TAG_KEY_ANIM = R.id.scrim;
+    private static final long DOZE_BACKGROUND_ANIM_DURATION = ScrimController.ANIMATION_DURATION;
+
     private KeyguardAffordanceHelper mAfforanceHelper;
     private StatusBarHeaderView mHeader;
     private KeyguardUserSwitcher mKeyguardUserSwitcher;
     private KeyguardStatusBarView mKeyguardStatusBar;
     private View mQsContainer;
     private QSPanel mQsPanel;
-    private View mKeyguardStatusView;
+    private KeyguardStatusView mKeyguardStatusView;
     private ObservableScrollView mScrollView;
     private TextView mClockView;
     private View mReserveNotificationSpace;
-    private MirrorView mSystemIconsCopy;
     private View mQsNavbarScrim;
     private View mNotificationContainerParent;
     private NotificationStackScrollLayout mNotificationStackScroller;
@@ -160,10 +163,12 @@
     private boolean mShadeEmpty;
 
     private boolean mQsScrimEnabled = true;
+    private boolean mLastAnnouncementWasQuickSettings;
+    private boolean mQsTouchAboveFalsingThreshold;
+    private int mQsFalsingThreshold;
 
     public NotificationPanelView(Context context, AttributeSet attrs) {
         super(context, attrs);
-        mSystemIconsCopy = new MirrorView(context);
     }
 
     public void setStatusBar(PhoneStatusBar bar) {
@@ -176,12 +181,13 @@
         mHeader = (StatusBarHeaderView) findViewById(R.id.header);
         mHeader.setOnClickListener(this);
         mKeyguardStatusBar = (KeyguardStatusBarView) findViewById(R.id.keyguard_header);
-        mKeyguardStatusView = findViewById(R.id.keyguard_status_view);
+        mKeyguardStatusView = (KeyguardStatusView) findViewById(R.id.keyguard_status_view);
         mQsContainer = findViewById(R.id.quick_settings_container);
         mQsPanel = (QSPanel) findViewById(R.id.quick_settings_panel);
         mClockView = (TextView) findViewById(R.id.clock_view);
         mScrollView = (ObservableScrollView) findViewById(R.id.scroll_view);
         mScrollView.setListener(this);
+        mScrollView.setFocusable(false);
         mReserveNotificationSpace = findViewById(R.id.reserve_notification_space);
         mNotificationContainerParent = findViewById(R.id.notification_container_parent);
         mNotificationStackScroller = (NotificationStackScrollLayout)
@@ -229,6 +235,8 @@
         mClockPositionAlgorithm.loadDimens(getResources());
         mNotificationScrimWaitDistance =
                 getResources().getDimensionPixelSize(R.dimen.notification_scrim_wait_distance);
+        mQsFalsingThreshold = getResources().getDimensionPixelSize(
+                R.dimen.qs_falsing_threshold);
     }
 
     public void updateResources() {
@@ -268,6 +276,7 @@
         // Calculate quick setting heights.
         mQsMinExpansionHeight = mKeyguardShowing ? 0 : mHeader.getCollapsedHeight() + mQsPeekHeight;
         mQsMaxExpansionHeight = mHeader.getExpandedHeight() + mQsContainer.getHeight();
+        positionClockAndNotifications();
         if (mQsExpanded) {
             if (mQsFullyExpanded) {
                 mQsExpansionHeight = mQsMaxExpansionHeight;
@@ -275,7 +284,6 @@
             }
         } else {
             setQsExpansion(mQsMinExpansionHeight + mLastOverscroll);
-            positionClockAndNotifications();
             mNotificationStackScroller.setStackHeight(getExpandedHeight());
             updateHeader();
         }
@@ -375,6 +383,7 @@
 
     public void setQsExpansionEnabled(boolean qsExpansionEnabled) {
         mQsExpansionEnabled = qsExpansionEnabled;
+        mHeader.setClickable(qsExpansionEnabled);
     }
 
     @Override
@@ -425,8 +434,8 @@
     @Override
     public boolean dispatchPopulateAccessibilityEvent(AccessibilityEvent event) {
         if (event.getEventType() == AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED) {
-            event.getText()
-                    .add(getContext().getString(R.string.accessibility_desc_notification_shade));
+            event.getText().add(getKeyguardOrLockScreenString());
+            mLastAnnouncementWasQuickSettings = false;
             return true;
         }
 
@@ -524,6 +533,7 @@
     private void resetDownStates(MotionEvent event) {
         if (event.getActionMasked() == MotionEvent.ACTION_DOWN) {
             mOnlyAffordanceInThisMotion = false;
+            mQsTouchAboveFalsingThreshold = mQsFullyExpanded;
         }
     }
 
@@ -544,6 +554,9 @@
     }
 
     private boolean flingExpandsQs(float vel) {
+        if (isBelowFalsingThreshold()) {
+            return false;
+        }
         if (Math.abs(vel) < mFlingAnimationUtils.getMinVelocityPxPerSecond()) {
             return getQsExpansionFraction() > 0.5f;
         } else {
@@ -551,6 +564,10 @@
         }
     }
 
+    private boolean isBelowFalsingThreshold() {
+        return !mQsTouchAboveFalsingThreshold && mStatusBarState == StatusBarState.KEYGUARD;
+    }
+
     private float getQsExpansionFraction() {
         return Math.min(1f, (mQsExpansionHeight - mQsMinExpansionHeight)
                 / (getTempQsMaxExpansion() - mQsMinExpansionHeight));
@@ -571,7 +588,8 @@
             return true;
         }
         if (event.getActionMasked() == MotionEvent.ACTION_DOWN && getExpandedFraction() == 1f
-                && mStatusBar.getBarState() != StatusBarState.KEYGUARD && !mQsExpanded) {
+                && mStatusBar.getBarState() != StatusBarState.KEYGUARD && !mQsExpanded
+                && mQsExpansionEnabled) {
 
             // Down in the empty area while fully expanded - go to QS.
             mQsTracking = true;
@@ -594,7 +612,8 @@
                 || event.getActionMasked() == MotionEvent.ACTION_UP) {
             mConflictingQsExpansionGesture = false;
         }
-        if (event.getActionMasked() == MotionEvent.ACTION_DOWN && mExpandedHeight == 0) {
+        if (event.getActionMasked() == MotionEvent.ACTION_DOWN && mExpandedHeight == 0
+                && mQsExpansionEnabled) {
             mTwoFingerQsExpandPossible = true;
         }
         if (mTwoFingerQsExpandPossible && event.getActionMasked() == MotionEvent.ACTION_POINTER_DOWN
@@ -612,9 +631,10 @@
     }
 
     private boolean isInQsArea(float x, float y) {
-        return mStatusBarState != StatusBarState.SHADE
-                || y <= mNotificationStackScroller.getBottomMostNotificationBottom()
-                || y <= mQsContainer.getY() + mQsContainer.getHeight();
+        return mStatusBarState != StatusBarState.SHADE ||
+                (x >= mScrollView.getLeft() && x <= mScrollView.getRight()) &&
+                        (y <= mNotificationStackScroller.getBottomMostNotificationBottom()
+                                || y <= mQsContainer.getY() + mQsContainer.getHeight());
     }
 
     private void handleQsDown(MotionEvent event) {
@@ -686,6 +706,9 @@
             case MotionEvent.ACTION_MOVE:
                 final float h = y - mInitialTouchY;
                 setQsExpansion(h + mInitialHeightOnTouch);
+                if (h >= mQsFalsingThreshold) {
+                    mQsTouchAboveFalsingThreshold = true;
+                }
                 trackMovement(event);
                 break;
 
@@ -724,6 +747,9 @@
     @Override
     public void onOverscrollTopChanged(float amount, boolean isRubberbanded) {
         cancelAnimation();
+        if (!mQsExpansionEnabled) {
+            amount = 0f;
+        }
         float rounded = amount >= 1f ? amount : 0f;
         mStackScrollerOverscrolling = rounded != 0f && isRubberbanded;
         mQsExpansionFromOverscroll = rounded != 0f;
@@ -734,8 +760,10 @@
 
     @Override
     public void flingTopOverscroll(float velocity, boolean open) {
+        mLastOverscroll = 0f;
         setQsExpansion(mQsExpansionHeight);
-        flingSettings(velocity, open, new Runnable() {
+        flingSettings(!mQsExpansionEnabled && open ? 0f : velocity, open && mQsExpansionEnabled,
+                new Runnable() {
             @Override
             public void run() {
                 mStackScrollerOverscrolling = false;
@@ -987,6 +1015,10 @@
             setQsExpanded(true);
         } else if (height <= mQsMinExpansionHeight && mQsExpanded) {
             setQsExpanded(false);
+            if (mLastAnnouncementWasQuickSettings && !mTracking) {
+                announceForAccessibility(getKeyguardOrLockScreenString());
+                mLastAnnouncementWasQuickSettings = false;
+            }
         }
         mQsExpansionHeight = height;
         mHeader.setExpansion(getHeaderExpansionFraction());
@@ -1000,13 +1032,28 @@
                 && !mStackScrollerOverscrolling && mQsScrimEnabled) {
             mQsNavbarScrim.setAlpha(getQsExpansionFraction());
         }
+
+        // Upon initialisation when we are not layouted yet we don't want to announce that we are
+        // fully expanded, hence the != 0.0f check.
+        if (height != 0.0f && mQsFullyExpanded && !mLastAnnouncementWasQuickSettings) {
+            announceForAccessibility(getContext().getString(
+                    R.string.accessibility_desc_quick_settings));
+            mLastAnnouncementWasQuickSettings = true;
+        }
+    }
+
+    private String getKeyguardOrLockScreenString() {
+        if (mStatusBarState == StatusBarState.KEYGUARD) {
+            return getContext().getString(R.string.accessibility_desc_lock_screen);
+        } else {
+            return getContext().getString(R.string.accessibility_desc_notification_shade);
+        }
     }
 
     private void updateNotificationScrim(float height) {
         int startDistance = mQsMinExpansionHeight + mNotificationScrimWaitDistance;
         float progress = (height - startDistance) / (mQsMaxExpansionHeight - startDistance);
         progress = Math.max(0.0f, Math.min(progress, 1.0f));
-        mNotificationStackScroller.setScrimAlpha(progress);
     }
 
     private float getHeaderExpansionFraction() {
@@ -1085,9 +1132,16 @@
             }
             return;
         }
+        boolean belowFalsingThreshold = isBelowFalsingThreshold();
+        if (belowFalsingThreshold) {
+            vel = 0;
+        }
         mScrollView.setBlockFlinging(true);
         ValueAnimator animator = ValueAnimator.ofFloat(mQsExpansionHeight, target);
         mFlingAnimationUtils.apply(animator, mQsExpansionHeight, target, vel);
+        if (belowFalsingThreshold) {
+            animator.setDuration(350);
+        }
         animator.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
             @Override
             public void onAnimationUpdate(ValueAnimator animation) {
@@ -1128,43 +1182,6 @@
     }
 
     @Override
-    public void setVisibility(int visibility) {
-        int oldVisibility = getVisibility();
-        super.setVisibility(visibility);
-        if (visibility != oldVisibility) {
-            reparentStatusIcons(visibility == VISIBLE);
-        }
-    }
-
-    /**
-     * When the notification panel gets expanded, we need to move the status icons in the header
-     * card.
-     */
-    private void reparentStatusIcons(boolean toHeader) {
-        if (mStatusBar == null) {
-            return;
-        }
-        LinearLayout systemIcons = mStatusBar.getSystemIcons();
-        ViewGroup parent = ((ViewGroup) systemIcons.getParent());
-        if (toHeader) {
-            int index = parent.indexOfChild(systemIcons);
-            parent.removeView(systemIcons);
-            mSystemIconsCopy.setMirroredView(
-                    systemIcons, systemIcons.getWidth(), systemIcons.getHeight());
-            parent.addView(mSystemIconsCopy, index);
-            mHeader.attachSystemIcons(systemIcons);
-        } else {
-            ViewGroup newParent = mStatusBar.getSystemIconArea();
-            int index = newParent.indexOfChild(mSystemIconsCopy);
-            parent.removeView(systemIcons);
-            mHeader.onSystemIconsDetached();
-            mSystemIconsCopy.setMirroredView(null, 0, 0);
-            newParent.removeView(mSystemIconsCopy);
-            newParent.addView(systemIcons, index);
-        }
-    }
-
-    @Override
     protected boolean isScrolledToBottom() {
         if (mStatusBar.getBarState() == StatusBarState.KEYGUARD) {
             return true;
@@ -1268,7 +1285,7 @@
     private void updateNotificationTranslucency() {
         float alpha = (getNotificationsTopY() + mNotificationStackScroller.getItemHeight())
                 / (mQsMinExpansionHeight + mNotificationStackScroller.getBottomStackPeekSize()
-                        + mNotificationStackScroller.getCollapseSecondCardPadding());
+                        - mNotificationStackScroller.getCollapseSecondCardPadding());
         alpha = Math.max(0, Math.min(alpha, 1));
         alpha = (float) Math.pow(alpha, 0.75);
         if (alpha != 1f && mNotificationStackScroller.getLayerType() != LAYER_TYPE_HARDWARE) {
@@ -1636,7 +1653,7 @@
     @Override
     protected boolean fullyExpandedClearAllVisible() {
         return mNotificationStackScroller.isDismissViewNotGone()
-                && mNotificationStackScroller.isScrolledToBottom();
+                && mNotificationStackScroller.isScrolledToBottom() && !mTwoFingerQsExpand;
     }
 
     @Override
@@ -1692,9 +1709,9 @@
     }
 
     public void setEmptyDragAmount(float amount) {
-        float factor = 1f;
+        float factor = 0.8f;
         if (mNotificationStackScroller.getNotGoneChildCount() > 0) {
-            factor = 0.6f;
+            factor = 0.4f;
         } else if (!mStatusBar.hasActiveNotifications()) {
             factor = 0.4f;
         }
@@ -1714,13 +1731,58 @@
         if (dozing == mDozing) return;
         mDozing = dozing;
         if (mDozing) {
-            setBackgroundColor(0xff000000);
+            setBackgroundColorAlpha(this, DOZE_BACKGROUND_COLOR, 0xff, false /*animate*/);
         } else {
-            setBackground(null);
+            setBackgroundColorAlpha(this, DOZE_BACKGROUND_COLOR, 0, true /*animate*/);
         }
         updateKeyguardStatusBarVisibility();
     }
 
+    private static void setBackgroundColorAlpha(final View target, int rgb, int targetAlpha,
+            boolean animate) {
+        int currentAlpha = getBackgroundAlpha(target);
+        if (currentAlpha == targetAlpha) {
+            return;
+        }
+        final int r = Color.red(rgb);
+        final int g = Color.green(rgb);
+        final int b = Color.blue(rgb);
+        Object runningAnim = target.getTag(TAG_KEY_ANIM);
+        if (runningAnim instanceof ValueAnimator) {
+            ((ValueAnimator) runningAnim).cancel();
+        }
+        if (!animate) {
+            target.setBackgroundColor(Color.argb(targetAlpha, r, g, b));
+            return;
+        }
+        ValueAnimator anim = ValueAnimator.ofInt(currentAlpha, targetAlpha);
+        anim.addUpdateListener(new ValueAnimator.AnimatorUpdateListener() {
+            @Override
+            public void onAnimationUpdate(ValueAnimator animation) {
+                int value = (int) animation.getAnimatedValue();
+                target.setBackgroundColor(Color.argb(value, r, g, b));
+            }
+        });
+        anim.setDuration(DOZE_BACKGROUND_ANIM_DURATION);
+        anim.addListener(new AnimatorListenerAdapter() {
+            @Override
+            public void onAnimationEnd(Animator animation) {
+                target.setTag(TAG_KEY_ANIM, null);
+            }
+        });
+        anim.start();
+        target.setTag(TAG_KEY_ANIM, anim);
+    }
+
+    private static int getBackgroundAlpha(View view) {
+        if (view.getBackground() instanceof ColorDrawable) {
+            ColorDrawable drawable = (ColorDrawable) view.getBackground();
+            return Color.alpha(drawable.getColor());
+        } else {
+            return 0;
+        }
+    }
+
     public void setShadeEmpty(boolean shadeEmpty) {
         mShadeEmpty = shadeEmpty;
         updateEmptyShadeView();
@@ -1750,4 +1812,8 @@
             mHeader.updateEverything();
         }
     };
+
+    public void onScreenTurnedOn() {
+        mKeyguardStatusView.refreshTime();
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationsQuickSettingsContainer.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationsQuickSettingsContainer.java
index 57b7401..e7b0c4c 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationsQuickSettingsContainer.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationsQuickSettingsContainer.java
@@ -22,6 +22,7 @@
 import android.util.AttributeSet;
 import android.view.View;
 import android.view.ViewStub;
+import android.view.WindowInsets;
 import android.widget.FrameLayout;
 
 import com.android.systemui.R;
@@ -54,10 +55,9 @@
     }
 
     @Override
-    protected boolean fitSystemWindows(Rect insets) {
-        setPadding(0, 0, 0, insets.bottom);
-        insets.bottom = 0;
-        return true;
+    public WindowInsets onApplyWindowInsets(WindowInsets insets) {
+        setPadding(0, 0, 0, insets.getSystemWindowInsetBottom());
+        return insets;
     }
 
     @Override
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ObservableScrollView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ObservableScrollView.java
index 53361dc..b842a6b 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ObservableScrollView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ObservableScrollView.java
@@ -87,7 +87,9 @@
 
     @Override
     public boolean dispatchTouchEvent(MotionEvent ev) {
-        if (!mTouchEnabled) {
+        boolean isEndGuesture = (ev.getAction() == MotionEvent.ACTION_UP
+                || ev.getAction() == MotionEvent.ACTION_CANCEL);
+        if (!mTouchEnabled && !isEndGuesture) {
             return false;
         }
         return super.dispatchTouchEvent(ev);
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelBar.java
index f74d2f4..ccafbd1 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelBar.java
@@ -140,6 +140,9 @@
         mPanelHolder.setSelectedPanel(mTouchingPanel);
         for (PanelView pv : mPanels) {
             if (pv != panel) {
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Collapsing because opening another panel");
+                }
                 pv.collapse(false /* delayed */);
             }
         }
@@ -191,9 +194,15 @@
         boolean waiting = false;
         for (PanelView pv : mPanels) {
             if (animate && !pv.isFullyCollapsed()) {
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Animating collapse, delayed");
+                }
                 pv.collapse(true /* delayed */);
                 waiting = true;
             } else {
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Collapsing without animation");
+                }
                 pv.resetViews();
                 pv.setExpandedFraction(0); // just in case
                 pv.setVisibility(View.GONE);
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java
index decaeb6..873d528 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PanelView.java
@@ -58,7 +58,7 @@
     private boolean mHasLayoutedSinceDown;
     private float mUpdateFlingVelocity;
     private boolean mUpdateFlingOnLayout;
-    private boolean mTouching;
+    private boolean mPeekTouching;
     private boolean mJustPeeked;
     private boolean mClosing;
     protected boolean mTracking;
@@ -68,6 +68,8 @@
     protected boolean mHintAnimationRunning;
     private boolean mOverExpandedBeforeFling;
     private float mOriginalIndicationY;
+    private boolean mTouchAboveFalsingThreshold;
+    private int mUnlockFalsingThreshold;
 
     private ValueAnimator mHeightAnimator;
     private ObjectAnimator mPeekAnimator;
@@ -84,6 +86,7 @@
     private String mViewName;
     private float mInitialTouchY;
     private float mInitialTouchX;
+    private boolean mTouchDisabled;
 
     private Interpolator mLinearOutSlowInInterpolator;
     private Interpolator mFastOutSlowInInterpolator;
@@ -132,6 +135,9 @@
     }
 
     private void runPeekAnimation() {
+        if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+            Log.i(TAG, "Starting peek animation");
+        }
         mPeekHeight = getPeekHeight();
         if (DEBUG) logf("peek to height=%.1f", mPeekHeight);
         if (mHeightAnimator != null) {
@@ -152,9 +158,15 @@
             public void onAnimationEnd(Animator animation) {
                 mPeekAnimator = null;
                 if (mCollapseAfterPeek && !mCancelled) {
+                    if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                        Log.i(TAG, "Peek animation finished, posting collapse");
+                    }
                     postOnAnimation(new Runnable() {
                         @Override
                         public void run() {
+                            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                                Log.i(TAG, "Peek animation finished, collapsing");
+                            }
                             collapse(false /* delayed */);
                         }
                     });
@@ -183,6 +195,7 @@
         mTouchSlop = configuration.getScaledTouchSlop();
         mHintDistance = res.getDimension(R.dimen.hint_move_distance);
         mEdgeTapAreaWidth = res.getDimensionPixelSize(R.dimen.edge_tap_area_width);
+        mUnlockFalsingThreshold = res.getDimensionPixelSize(R.dimen.unlock_falsing_threshold);
     }
 
     private void trackMovement(MotionEvent event) {
@@ -195,9 +208,13 @@
         event.offsetLocation(-deltaX, -deltaY);
     }
 
+    public void setTouchDisabled(boolean disabled) {
+        mTouchDisabled = disabled;
+    }
+
     @Override
     public boolean onTouchEvent(MotionEvent event) {
-        if (mInstantExpanding) {
+        if (mInstantExpanding || mTouchDisabled) {
             return false;
         }
 
@@ -233,7 +250,8 @@
                 mPanelClosedOnDown = mExpandedHeight == 0.0f;
                 mHasLayoutedSinceDown = false;
                 mUpdateFlingOnLayout = false;
-                mTouching = true;
+                mPeekTouching = mPanelClosedOnDown;
+                mTouchAboveFalsingThreshold = false;
                 if (mVelocityTracker == null) {
                     initVelocityTracker();
                 }
@@ -298,6 +316,9 @@
                     }
                     mJustPeeked = false;
                 }
+                if (-h >= mUnlockFalsingThreshold) {
+                    mTouchAboveFalsingThreshold = true;
+                }
                 if (!mJustPeeked && (!waitForTouchSlop || mTracking) && !isTrackingBlocked()) {
                     setExpandedHeightInternal(newHeight);
                 }
@@ -323,6 +344,9 @@
                     }
                     boolean expand = flingExpands(vel, vectorVel);
                     onTrackingStopped(expand);
+                    if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                        Log.i(TAG, "Flinging: expand=" + expand);
+                    }
                     fling(vel, expand);
                     mUpdateFlingOnLayout = expand && mPanelClosedOnDown && !mHasLayoutedSinceDown;
                     if (mUpdateFlingOnLayout) {
@@ -337,7 +361,7 @@
                     mVelocityTracker.recycle();
                     mVelocityTracker = null;
                 }
-                mTouching = false;
+                mPeekTouching = false;
                 break;
         }
         return !waitForTouchSlop || mTracking;
@@ -399,7 +423,7 @@
                 mPanelClosedOnDown = mExpandedHeight == 0.0f;
                 mHasLayoutedSinceDown = false;
                 mUpdateFlingOnLayout = false;
-                mTouching = true;
+                mTouchAboveFalsingThreshold = false;
                 initVelocityTracker();
                 trackMovement(event);
                 break;
@@ -434,7 +458,6 @@
                 break;
             case MotionEvent.ACTION_CANCEL:
             case MotionEvent.ACTION_UP:
-                mTouching = false;
                 break;
         }
         return false;
@@ -473,6 +496,9 @@
      * @return whether a fling should expands the panel; contracts otherwise
      */
     protected boolean flingExpands(float vel, float vectorVel) {
+        if (isBelowFalsingThreshold()) {
+            return true;
+        }
         if (Math.abs(vectorVel) < mFlingAnimationUtils.getMinVelocityPxPerSecond()) {
             return getExpandedFraction() > 0.5f;
         } else {
@@ -480,6 +506,10 @@
         }
     }
 
+    private boolean isBelowFalsingThreshold() {
+        return !mTouchAboveFalsingThreshold && mStatusBar.isFalsingThresholdNeeded();
+    }
+
     protected void fling(float vel, boolean expand) {
         cancelPeek();
         float target = expand ? getMaxPanelHeight() : 0.0f;
@@ -497,10 +527,20 @@
             notifyExpandingFinished();
             return;
         }
+        if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+            Log.i(TAG, "Executing fling: expand=" + expand + " vel=" + vel);
+        }
         mOverExpandedBeforeFling = getOverExpansionAmount() > 0f;
         ValueAnimator animator = createHeightAnimator(target);
         if (expand) {
+            boolean belowFalsingThreshold = isBelowFalsingThreshold();
+            if (belowFalsingThreshold) {
+                vel = 0;
+            }
             mFlingAnimationUtils.apply(animator, mExpandedHeight, target, vel, getHeight());
+            if (belowFalsingThreshold) {
+                animator.setDuration(350);
+            }
         } else {
             mFlingAnimationUtils.applyDismissing(animator, mExpandedHeight, target, vel,
                     getHeight());
@@ -571,7 +611,7 @@
                 && currentMaxPanelHeight != mExpandedHeight
                 && !mPeekPending
                 && mPeekAnimator == null
-                && !mTouching) {
+                && !mPeekTouching) {
             setExpandedHeight(currentMaxPanelHeight);
         }
     }
@@ -664,25 +704,36 @@
                 removeCallbacks(mPeekRunnable);
                 mPeekRunnable.run();
             }
-        } else if (!isFullyCollapsed() && !mTracking) {
+        } else if (!isFullyCollapsed() && !mTracking && !mClosing) {
             if (mHeightAnimator != null) {
                 mHeightAnimator.cancel();
             }
             mClosing = true;
             notifyExpandingStarted();
             if (delayed) {
-                postDelayed(new Runnable() {
-                    @Override
-                    public void run() {
-                        fling(0, false /* expand */);
-                    }
-                }, 120);
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Posting collapse runnable, will be run in 120ms");
+                }
+                postDelayed(mFlingCollapseRunnable, 120);
             } else {
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Animating collapsing now");
+                }
                 fling(0, false /* expand */);
             }
         }
     }
 
+    private final Runnable mFlingCollapseRunnable = new Runnable() {
+        @Override
+        public void run() {
+            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                Log.i(TAG, "Executing collapse runnable, animating collapsing now");
+            }
+            fling(0, false /* expand */);
+        }
+    };
+
     public void expand() {
         if (DEBUG) logf("expand: " + this);
         if (isFullyCollapsed()) {
@@ -707,10 +758,19 @@
     }
 
     public void instantExpand() {
+        if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+            Log.i(TAG, "Before instant expanding"
+                    + " mTracking=" + mTracking
+                    + " mExpanding=" + mExpanding);
+        }
         mInstantExpanding = true;
+        mUpdateFlingOnLayout = false;
         abortAnimations();
+        cancelPeek();
         if (mTracking) {
             onTrackingStopped(true /* expands */); // The panel is expanded after this call.
+        }
+        if (mExpanding) {
             notifyExpandingFinished();
         }
         setVisibility(VISIBLE);
@@ -723,6 +783,11 @@
                     public void onGlobalLayout() {
                         if (mStatusBar.getStatusBarWindow().getHeight()
                                 != mStatusBar.getStatusBarHeight()) {
+                            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                                Log.i(TAG, "Now instant expanding after layout"
+                                        + " mTracking=" + mTracking
+                                        + " mExpanding=" + mExpanding);
+                            }
                             getViewTreeObserver().removeOnGlobalLayoutListener(this);
                             setExpandedFraction(1f);
                             mInstantExpanding = false;
@@ -739,6 +804,8 @@
         if (mHeightAnimator != null) {
             mHeightAnimator.cancel();
         }
+        removeCallbacks(mPostCollapseRunnable);
+        removeCallbacks(mFlingCollapseRunnable);
     }
 
     protected void startUnlockHintAnimation() {
@@ -867,6 +934,9 @@
     private final Runnable mPostCollapseRunnable = new Runnable() {
         @Override
         public void run() {
+            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                Log.i(TAG, "Collapsing after middle clicked");
+            }
             collapse(false /* delayed */);
         }
     };
@@ -879,6 +949,9 @@
                 mStatusBar.goToKeyguard();
                 return true;
             case StatusBarState.SHADE:
+                if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Middle clicked in shade state, posting collapsing runnable");
+                }
 
                 // This gets called in the middle of the touch handling, where the state is still
                 // that we are tracking the panel. Collapse the panel after this is done.
@@ -893,7 +966,7 @@
 
     public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
         pw.println(String.format("[PanelView(%s): expandedHeight=%f maxPanelHeight=%d closing=%s"
-                + " tracking=%s justPeeked=%s peekAnim=%s%s timeAnim=%s%s"
+                + " tracking=%s justPeeked=%s peekAnim=%s%s timeAnim=%s%s touchDisabled=%s"
                 + "]",
                 this.getClass().getSimpleName(),
                 getExpandedHeight(),
@@ -902,7 +975,8 @@
                 mTracking?"T":"f",
                 mJustPeeked?"T":"f",
                 mPeekAnimator, ((mPeekAnimator!=null && mPeekAnimator.isStarted())?" (started)":""),
-                mHeightAnimator, ((mHeightAnimator !=null && mHeightAnimator.isStarted())?" (started)":"")
+                mHeightAnimator, ((mHeightAnimator !=null && mHeightAnimator.isStarted())?" (started)":""),
+                mTouchDisabled?"T":"f"
         ));
     }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
index 23b55ee..353c887 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
@@ -71,6 +71,7 @@
 import android.os.SystemClock;
 import android.os.UserHandle;
 import android.provider.Settings;
+import android.service.notification.NotificationListenerService;
 import android.service.notification.NotificationListenerService.RankingMap;
 import android.service.notification.StatusBarNotification;
 import android.util.ArraySet;
@@ -109,8 +110,10 @@
 import com.android.internal.statusbar.StatusBarIcon;
 import com.android.keyguard.KeyguardHostView.OnDismissAction;
 import com.android.keyguard.ViewMediatorCallback;
+import com.android.systemui.BatteryMeterView;
 import com.android.systemui.DemoMode;
 import com.android.systemui.EventLogTags;
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.doze.DozeService;
 import com.android.systemui.keyguard.KeyguardViewMediator;
@@ -131,6 +134,7 @@
 import com.android.systemui.statusbar.SpeedBumpView;
 import com.android.systemui.statusbar.StatusBarIconView;
 import com.android.systemui.statusbar.StatusBarState;
+import com.android.systemui.statusbar.policy.AccessibilityController;
 import com.android.systemui.statusbar.policy.BatteryController;
 import com.android.systemui.statusbar.policy.BatteryController.BatteryStateChangeCallback;
 import com.android.systemui.statusbar.policy.BluetoothControllerImpl;
@@ -145,6 +149,7 @@
 import com.android.systemui.statusbar.policy.LocationControllerImpl;
 import com.android.systemui.statusbar.policy.NetworkControllerImpl;
 import com.android.systemui.statusbar.policy.NextAlarmController;
+import com.android.systemui.statusbar.policy.PreviewInflater;
 import com.android.systemui.statusbar.policy.RotationLockControllerImpl;
 import com.android.systemui.statusbar.policy.SecurityControllerImpl;
 import com.android.systemui.statusbar.policy.UserInfoController;
@@ -172,6 +177,7 @@
     public static final boolean DEBUG_GESTURES = false;
     public static final boolean DEBUG_MEDIA = false;
     public static final boolean DEBUG_MEDIA_FAKE_ARTWORK = false;
+    public static final boolean DEBUG_EMPTY_KEYGUARD = true;
 
     public static final boolean DEBUG_WINDOW_STATE = false;
 
@@ -236,6 +242,7 @@
     NextAlarmController mNextAlarmController;
     KeyguardMonitor mKeyguardMonitor;
     BrightnessMirrorController mBrightnessMirrorController;
+    AccessibilityController mAccessibilityController;
 
     int mNaturalBarHeight = -1;
     int mIconSize = -1;
@@ -309,8 +316,6 @@
     int[] mPositionTmp = new int[2];
     boolean mExpandedVisible;
 
-    // on-screen navigation buttons
-    private NavigationBarView mNavigationBarView = null;
     private int mNavigationBarWindowState = WINDOW_STATE_SHOWING;
 
     // the tracker view
@@ -361,9 +366,6 @@
 
             if (userSetup != mUserSetup) {
                 mUserSetup = userSetup;
-                if (mNotificationPanel != null) {
-                    mNotificationPanel.setQsExpansionEnabled(isDeviceProvisioned() && userSetup);
-                }
                 if (!mUserSetup && mStatusBarView != null)
                     animateCollapseQuickSettings();
             }
@@ -400,6 +402,12 @@
     private int mNavigationBarMode;
     private Boolean mScreenOn;
 
+    // The second field is a bit different from the first one because it only listens to screen on/
+    // screen of events from Keyguard. We need this so we don't have a race condition with the
+    // broadcast. In the future, we should remove the first field altogether and rename the second
+    // field.
+    private boolean mScreenOnFromKeyguard;
+
     private ViewMediatorCallback mKeyguardViewMediatorCallback;
     private ScrimController mScrimController;
 
@@ -562,7 +570,7 @@
         addNavigationBar();
 
         // Lastly, call to the icon policy to install/update all the icons.
-        mIconPolicy = new PhoneStatusBarPolicy(mContext);
+        mIconPolicy = new PhoneStatusBarPolicy(mContext, mCastController);
         mSettingsObserver.onChange(false); // set up
 
         mHeadsUpObserver.onChange(true); // set up
@@ -582,6 +590,8 @@
         putComponent(PhoneStatusBar.class, this);
 
         setControllerUsers();
+
+        notifyUserAboutHiddenNotifications();
     }
 
     // ================================================================================
@@ -686,6 +696,7 @@
         mStackScroller = (NotificationStackScrollLayout) mStatusBarWindow.findViewById(
                 R.id.notification_stack_scroller);
         mStackScroller.setLongPressListener(getNotificationLongClicker());
+        mStackScroller.setPhoneStatusBar(this);
 
         mKeyguardIconOverflowContainer =
                 (NotificationOverflowContainer) LayoutInflater.from(mContext).inflate(
@@ -752,6 +763,9 @@
             @Override
             public void onPowerSaveChanged() {
                 mHandler.post(mCheckBarModes);
+                if (mDozeServiceHost != null) {
+                    mDozeServiceHost.firePowerSaveChanged(mBatteryController.isPowerSave());
+                }
             }
             @Override
             public void onBatteryLevelChanged(int level, boolean pluggedIn, boolean charging) {
@@ -773,10 +787,17 @@
                 (SignalClusterView) mStatusBarView.findViewById(R.id.signal_cluster);
         final SignalClusterView signalClusterKeyguard =
                 (SignalClusterView) mKeyguardStatusBar.findViewById(R.id.signal_cluster);
+        final SignalClusterView signalClusterQs =
+                (SignalClusterView) mHeader.findViewById(R.id.signal_cluster);
         mNetworkController.addSignalCluster(signalCluster);
         mNetworkController.addSignalCluster(signalClusterKeyguard);
+        mNetworkController.addSignalCluster(signalClusterQs);
+        signalCluster.setSecurityController(mSecurityController);
         signalCluster.setNetworkController(mNetworkController);
+        signalClusterKeyguard.setSecurityController(mSecurityController);
         signalClusterKeyguard.setNetworkController(mNetworkController);
+        signalClusterQs.setSecurityController(mSecurityController);
+        signalClusterQs.setNetworkController(mNetworkController);
         final boolean isAPhone = mNetworkController.hasVoiceCallingFeature();
         if (isAPhone) {
             mNetworkController.addEmergencyLabelView(mHeader);
@@ -807,6 +828,9 @@
 
         mFlashlightController = new FlashlightController(mContext);
         mKeyguardBottomArea.setFlashlightController(mFlashlightController);
+        mKeyguardBottomArea.setPhoneStatusBar(this);
+        mAccessibilityController = new AccessibilityController(mContext);
+        mKeyguardBottomArea.setAccessibilityController(mAccessibilityController);
         mNextAlarmController = new NextAlarmController(mContext);
         mKeyguardMonitor = new KeyguardMonitor();
         mUserSwitcherController = new UserSwitcherController(mContext, mKeyguardMonitor);
@@ -848,6 +872,8 @@
         mUserInfoController.reloadUserInfo();
 
         mHeader.setBatteryController(mBatteryController);
+        ((BatteryMeterView) mStatusBarView.findViewById(R.id.battery)).setBatteryController(
+                mBatteryController);
         mKeyguardStatusBar.setBatteryController(mBatteryController);
         mHeader.setNextAlarmController(mNextAlarmController);
 
@@ -1061,7 +1087,6 @@
     };
 
     private long mLastLockToAppLongPress;
-    private AccessibilityManager mAccessibilityManager;
     private View.OnLongClickListener mLongPressBackRecentsListener =
             new View.OnLongClickListener() {
         @Override
@@ -1213,11 +1238,12 @@
                 + " icon=" + icon);
         StatusBarIconView view = new StatusBarIconView(mContext, slot, null);
         view.set(icon);
-        mStatusIcons.addView(view, viewIndex, new LinearLayout.LayoutParams(mIconSize, mIconSize));
+        mStatusIcons.addView(view, viewIndex, new LinearLayout.LayoutParams(
+                LayoutParams.WRAP_CONTENT, mIconSize));
         view = new StatusBarIconView(mContext, slot, null);
         view.set(icon);
-        mStatusIconsKeyguard.addView(view, viewIndex,
-                new LinearLayout.LayoutParams(mIconSize, mIconSize));
+        mStatusIconsKeyguard.addView(view, viewIndex, new LinearLayout.LayoutParams(
+                LayoutParams.WRAP_CONTENT, mIconSize));
     }
 
     public void updateIcon(String slot, int index, int viewIndex,
@@ -1349,7 +1375,7 @@
             updateExpandedViewPos(EXPANDED_LEAVE_ALONE);
 
             if (CLOSE_PANEL_WHEN_EMPTIED && !hasActiveNotifications()
-                    && !mNotificationPanel.isTracking()) {
+                    && !mNotificationPanel.isTracking() && !mNotificationPanel.isQsExpanded()) {
                 if (mState == StatusBarState.SHADE) {
                     animateCollapsePanels();
                 } else if (mState == StatusBarState.SHADE_LOCKED) {
@@ -1397,11 +1423,12 @@
             // Display public version of the notification if we need to redact.
             final boolean hideSensitive =
                     !userAllowsPrivateNotificationsInPublic(ent.notification.getUserId());
-            boolean sensitive = vis == Notification.VISIBILITY_PRIVATE;
-            boolean showingPublic = sensitive && hideSensitive && isLockscreenPublicMode();
-            ent.row.setSensitive(sensitive && hideSensitive);
+            boolean sensitiveNote = vis == Notification.VISIBILITY_PRIVATE;
+            boolean sensitivePackage = packageHasVisibilityOverride(ent.notification.getKey());
+            boolean sensitive = (sensitiveNote && hideSensitive) || sensitivePackage;
+            boolean showingPublic = sensitive && isLockscreenPublicMode();
+            ent.row.setSensitive(sensitive);
             if (ent.autoRedacted && ent.legacy) {
-
                 // TODO: Also fade this? Or, maybe easier (and better), provide a dark redacted form
                 // for legacy auto redacted notifications.
                 if (showingPublic) {
@@ -1458,10 +1485,19 @@
         updateClearAll();
         updateEmptyShadeView();
 
-        mNotificationPanel.setQsExpansionEnabled(isDeviceProvisioned() && mUserSetup);
+        // Disable QS if device not provisioned.
+        // If the user switcher is simple then disable QS during setup because
+        // the user intends to use the lock screen user switcher, QS in not needed.
+        mNotificationPanel.setQsExpansionEnabled(isDeviceProvisioned()
+                && (!mUserSwitcherController.isSimpleUserSwitcher() || mUserSetup));
         mShadeUpdates.check();
     }
 
+    private boolean packageHasVisibilityOverride(String key) {
+        return mNotificationData.getVisibilityOverride(key)
+                != NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE;
+    }
+
     private void updateClearAll() {
         boolean showDismissView =
                 mState != StatusBarState.KEYGUARD &&
@@ -1535,8 +1571,9 @@
             }
         }
 
-        for (View remove : toRemove) {
-            mNotificationIcons.removeView(remove);
+        final int toRemoveCount = toRemove.size();
+        for (int i = 0; i < toRemoveCount; i++) {
+            mNotificationIcons.removeView(toRemove.get(i));
         }
 
         for (int i=0; i<toShow.size(); i++) {
@@ -1545,6 +1582,18 @@
                 mNotificationIcons.addView(v, i, params);
             }
         }
+
+        // Resort notification icons
+        final int childCount = mNotificationIcons.getChildCount();
+        for (int i = 0; i < childCount; i++) {
+            View actual = mNotificationIcons.getChildAt(i);
+            StatusBarIconView expected = toShow.get(i);
+            if (actual == expected) {
+                continue;
+            }
+            mNotificationIcons.removeView(expected);
+            mNotificationIcons.addView(expected, i);
+        }
     }
 
     @Override
@@ -1706,12 +1755,12 @@
                     // something old was playing
                     Log.v(TAG, "DEBUG_MEDIA: Disconnecting from old controller: "
                             + mMediaController);
-                    mMediaController.removeCallback(mMediaListener);
+                    mMediaController.unregisterCallback(mMediaListener);
                 }
                 mMediaController = controller;
 
                 if (mMediaController != null) {
-                    mMediaController.addCallback(mMediaListener);
+                    mMediaController.registerCallback(mMediaListener);
                     mMediaMetadata = mMediaController.getMetadata();
                     if (DEBUG_MEDIA) {
                         Log.v(TAG, "DEBUG_MEDIA: insert listener, receive metadata: "
@@ -2007,7 +2056,12 @@
                 .alpha(1f)
                 .setDuration(320)
                 .setInterpolator(ALPHA_IN)
-                .setStartDelay(50);
+                .setStartDelay(50)
+
+                // We need to clean up any pending end action from animateStatusBarHide if we call
+                // both hide and show in the same frame before the animation actually gets started.
+                // cancel() doesn't really remove the end action.
+                .withEndAction(null);
 
         // Synchronize the motion with the Keyguard fading if necessary.
         if (mKeyguardFadingAway) {
@@ -2045,6 +2099,17 @@
         return mNotificationPanel.isQsExpanded();
     }
 
+    public boolean isFalsingThresholdNeeded() {
+        boolean onKeyguard = getBarState() == StatusBarState.KEYGUARD;
+        boolean isMethodInSecure = mUnlockMethodCache.isMethodInsecure();
+        return onKeyguard && isMethodInSecure;
+    }
+
+    @Override  // NotificationData.Environment
+    public String getCurrentMediaNotificationKey() {
+        return mMediaNotificationKey;
+    }
+
     /**
      * All changes to the status bar and notifications funnel through here and are batched.
      */
@@ -2126,6 +2191,7 @@
         // Expand the window to encompass the full screen in anticipation of the drag.
         // This is only possible to do atomically because the status bar is at the top of the screen!
         mStatusBarWindowManager.setStatusBarExpanded(true);
+        mStatusBarView.setFocusable(false);
 
         visibilityChanged(true);
         mWaitingForKeyguardExit = false;
@@ -2181,6 +2247,11 @@
             mStatusBarWindowManager.setStatusBarFocusable(false);
 
             mStatusBarWindow.cancelExpandHelper();
+            if (DEBUG_EMPTY_KEYGUARD) {
+                Log.i(TAG, "Collapsing panel from animateCollapsePanels:"
+                        + " force=" + force
+                        + " mState=" + mState);
+            }
             mStatusBarView.collapseAllPanels(true);
         }
     }
@@ -2268,6 +2339,9 @@
     }
 
     public void animateCollapseQuickSettings() {
+        if (DEBUG_EMPTY_KEYGUARD) {
+            Log.i(TAG, "Collapsing panel from animateCollapseQuickSettings");
+        }
         mStatusBarView.collapseAllPanels(true);
     }
 
@@ -2280,6 +2354,9 @@
         }
 
         // Ensure the panel is fully collapsed (just in case; bug 6765842, 7260868)
+        if (DEBUG_EMPTY_KEYGUARD) {
+            Log.i(TAG, "Collapsing panel from makeExpandedInvisible");
+        }
         mStatusBarView.collapseAllPanels(/*animate=*/ false);
 
         // reset things to their proper state
@@ -2289,8 +2366,6 @@
         mStackScroller.setVisibility(View.VISIBLE);
         mNotificationPanel.setVisibility(View.GONE);
 
-        setAreThereNotifications(); // show the clear button
-
         mNotificationPanel.closeQs();
 
         mExpandedVisible = false;
@@ -2300,6 +2375,7 @@
 
         // Shrink the window to the size of the status bar only
         mStatusBarWindowManager.setStatusBarExpanded(false);
+        mStatusBarView.setFocusable(true);
 
         // Close any "App info" popups that might have snuck on-screen
         dismissPopups();
@@ -2372,6 +2448,9 @@
             mStatusBarWindowState = state;
             if (DEBUG_WINDOW_STATE) Log.d(TAG, "Status bar " + windowStateToString(state));
             if (!showing) {
+                if (DEBUG_EMPTY_KEYGUARD) {
+                    Log.i(TAG, "Collapsing panel from setWindowState");
+                }
                 mStatusBarView.collapseAllPanels(false);
             }
         }
@@ -2905,6 +2984,8 @@
             final boolean dismissShade) {
         if (onlyProvisioned && !isDeviceProvisioned()) return;
 
+        final boolean afterKeyguardGone = PreviewInflater.wouldLaunchResolverActivity(
+                mContext, intent, mCurrentUserId);
         final boolean keyguardShowing = mStatusBarKeyguardViewManager.isShowing();
         dismissKeyguardThenExecute(new OnDismissAction() {
             @Override
@@ -2912,7 +2993,7 @@
                 AsyncTask.execute(new Runnable() {
                     public void run() {
                         try {
-                            if (keyguardShowing) {
+                            if (keyguardShowing && !afterKeyguardGone) {
                                 ActivityManagerNative.getDefault()
                                         .keyguardWaitingForActivityDrawn();
                             }
@@ -2920,17 +3001,22 @@
                                     Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);
                             mContext.startActivityAsUser(
                                     intent, new UserHandle(UserHandle.USER_CURRENT));
-                            overrideActivityPendingAppTransition(keyguardShowing);
+                            overrideActivityPendingAppTransition(
+                                    keyguardShowing && !afterKeyguardGone);
                         } catch (RemoteException e) {
                         }
                     }
                 });
                 if (dismissShade) {
+                    if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                        Log.i(TAG, "Collapsing panel startActivityDismissKeyguard after keyguard"
+                                + "dismiss");
+                    }
                     animateCollapsePanels(CommandQueue.FLAG_EXCLUDE_NONE, true /* force */);
                 }
                 return true;
             }
-        });
+        }, afterKeyguardGone);
     }
 
     private BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
@@ -2992,10 +3078,11 @@
     }
 
     @Override
-    protected void dismissKeyguardThenExecute(final OnDismissAction action) {
+    protected void dismissKeyguardThenExecute(final OnDismissAction action,
+            boolean afterKeyguardGone) {
         if (mStatusBarKeyguardViewManager.isShowing()) {
             if (UnlockMethodCache.getInstance(mContext).isMethodInsecure()
-                    && mNotificationPanel.isLaunchTransitionRunning()) {
+                    && mNotificationPanel.isLaunchTransitionRunning() && !afterKeyguardGone) {
                 action.onDismiss();
                 mNotificationPanel.setLaunchTransitionEndRunnable(new Runnable() {
                     @Override
@@ -3004,7 +3091,7 @@
                     }
                 });
             } else {
-                mStatusBarKeyguardViewManager.dismissWithAction(action);
+                mStatusBarKeyguardViewManager.dismissWithAction(action, afterKeyguardGone);
             }
         } else {
             action.onDismiss();
@@ -3022,6 +3109,7 @@
         updateDisplaySize(); // populates mDisplayMetrics
 
         updateResources();
+        updateClockSize();
         repositionNavigationBar();
         updateExpandedViewPos(EXPANDED_LEAVE_ALONE);
         updateShowSearchHoldoff();
@@ -3093,6 +3181,13 @@
         }
     }
 
+    private void updateClockSize() {
+        if (mStatusBarView == null) return;
+        TextView clock = (TextView) mStatusBarView.findViewById(R.id.clock);
+        if (clock != null) {
+            FontSizeUtils.updateFontSize(clock, R.dimen.status_bar_clock_size);
+        }
+    }
     protected void loadDimens() {
         final Resources res = mContext.getResources();
 
@@ -3377,6 +3472,13 @@
     public void showKeyguard() {
         setBarState(StatusBarState.KEYGUARD);
         updateKeyguardState(false /* goingToFullShade */, false /* fromShadeLocked */);
+        if (!mScreenOnFromKeyguard) {
+
+            // If the screen is off already, we need to disable touch events because these might
+            // collapse the panel after we expanded it, and thus we would end up with a blank
+            // Keyguard.
+            mNotificationPanel.setTouchDisabled(true);
+        }
         instantExpandNotificationsPanel();
         mLeaveOpenOnKeyguardHide = false;
         if (mDraggedDownRow != null) {
@@ -3478,6 +3580,10 @@
         disable(mDisabledUnmodified, true /* animate */);
     }
 
+    public boolean isKeyguardFadingAway() {
+        return mKeyguardFadingAway;
+    }
+
     /**
      * Notifies that the Keyguard fading away animation is done.
      */
@@ -3582,7 +3688,11 @@
     }
 
     public boolean onSpacePressed() {
-        if (mState == StatusBarState.KEYGUARD || mState == StatusBarState.SHADE_LOCKED) {
+        if (mScreenOn != null && mScreenOn
+                && (mState == StatusBarState.KEYGUARD || mState == StatusBarState.SHADE_LOCKED)) {
+            if (PhoneStatusBar.DEBUG_EMPTY_KEYGUARD) {
+                Log.i(TAG, "Collapsing panel from onSpacePressed");
+            }
             animateCollapsePanels(0 /* flags */, true /* force */);
             return true;
         }
@@ -3720,7 +3830,9 @@
             row = (ExpandableNotificationRow) expandView;
             row.setUserExpanded(true);
         }
-        if (isLockscreenPublicMode() && !userAllowsPrivateNotificationsInPublic(mCurrentUserId)) {
+        boolean fullShadeNeedsBouncer = !userAllowsPrivateNotificationsInPublic(mCurrentUserId)
+                || !mShowLockscreenNotifications;
+        if (isLockscreenPublicMode() && fullShadeNeedsBouncer) {
             mLeaveOpenOnKeyguardHide = true;
             showBouncer();
             mDraggedDownRow = row;
@@ -3739,6 +3851,7 @@
      */
     public void goToKeyguard() {
         if (mState == StatusBarState.SHADE_LOCKED) {
+            mStackScroller.onGoToKeyguard();
             setBarState(StatusBarState.KEYGUARD);
             updateKeyguardState(false /* goingToFullShade */, true /* fromShadeLocked*/);
         }
@@ -3774,11 +3887,15 @@
     }
 
     public void onScreenTurnedOff() {
+        mScreenOnFromKeyguard = false;
         mStackScroller.setAnimationsEnabled(false);
     }
 
     public void onScreenTurnedOn() {
+        mScreenOnFromKeyguard = true;
         mStackScroller.setAnimationsEnabled(true);
+        mNotificationPanel.onScreenTurnedOn();
+        mNotificationPanel.setTouchDisabled(false);
     }
 
     /**
@@ -3798,10 +3915,6 @@
         try {
             boolean sendBackLongPress = false;
             IActivityManager activityManager = ActivityManagerNative.getDefault();
-            if (mAccessibilityManager == null) {
-                mAccessibilityManager = (AccessibilityManager)
-                        mContext.getSystemService(Context.ACCESSIBILITY_SERVICE);
-            }
             boolean isAccessiblityEnabled = mAccessibilityManager.isEnabled();
             if (activityManager.isInLockTaskMode() && !isAccessiblityEnabled) {
                 long time = System.currentTimeMillis();
@@ -3877,6 +3990,14 @@
         return !mNotificationData.getActiveNotifications().isEmpty();
     }
 
+    public void wakeUpIfDozing(long time) {
+        if (mDozeServiceHost != null && mDozeServiceHost.isDozing()
+                && mScrimController.isPulsing()) {
+            PowerManager pm = (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
+            pm.wakeUp(time);
+        }
+    }
+
     private final class ShadeUpdates {
         private final ArraySet<String> mVisibleNotifications = new ArraySet<String>();
         private final ArraySet<String> mNewVisibleNotifications = new ArraySet<String>();
@@ -3915,6 +4036,22 @@
 
         private DozeService mCurrentDozeService;
 
+        @Override
+        public String toString() {
+            return "PSB.DozeServiceHost[mCallbacks=" + mCallbacks.size() + " mCurrentDozeService="
+                    + mCurrentDozeService + "]";
+        }
+
+        public boolean isDozing() {
+            return mCurrentDozeService != null;
+        }
+
+        public void firePowerSaveChanged(boolean active) {
+            for (Callback callback : mCallbacks) {
+                callback.onPowerSaveChanged(active);
+            }
+        }
+
         public void fireBuzzBeepBlinked() {
             for (Callback callback : mCallbacks) {
                 callback.onBuzzBeepBlinked();
@@ -3946,25 +4083,27 @@
         @Override
         public void requestDoze(DozeService dozeService) {
             if (dozeService == null) return;
-            dozeService.stayAwake(PROCESSING_TIME);
             mHandler.obtainMessage(H.REQUEST_DOZE, dozeService).sendToTarget();
         }
 
         @Override
-        public void requestPulse(int pulses, boolean delayed, DozeService dozeService) {
+        public void requestPulse(DozeService dozeService) {
             if (dozeService == null) return;
             dozeService.stayAwake(PROCESSING_TIME);
-            mHandler.obtainMessage(H.REQUEST_PULSE, pulses, delayed ? 1 : 0, dozeService)
-                    .sendToTarget();
+            mHandler.obtainMessage(H.REQUEST_PULSE, dozeService).sendToTarget();
         }
 
         @Override
         public void dozingStopped(DozeService dozeService) {
             if (dozeService == null) return;
-            dozeService.stayAwake(PROCESSING_TIME);
             mHandler.obtainMessage(H.DOZING_STOPPED, dozeService).sendToTarget();
         }
 
+        @Override
+        public boolean isPowerSaveActive() {
+            return mBatteryController != null && mBatteryController.isPowerSave();
+        }
+
         private void handleRequestDoze(DozeService dozeService) {
             mCurrentDozeService = dozeService;
             if (!mDozing) {
@@ -3974,9 +4113,9 @@
             mCurrentDozeService.startDozing();
         }
 
-        private void handleRequestPulse(int pulses, boolean delayed, DozeService dozeService) {
+        private void handleRequestPulse(DozeService dozeService) {
             if (!dozeService.equals(mCurrentDozeService)) return;
-            final long stayAwake = mScrimController.pulse(pulses, delayed);
+            final long stayAwake = mScrimController.pulse();
             mCurrentDozeService.stayAwake(stayAwake);
         }
 
@@ -4000,7 +4139,7 @@
                 if (msg.what == REQUEST_DOZE) {
                     handleRequestDoze((DozeService) msg.obj);
                 } else if (msg.what == REQUEST_PULSE) {
-                    handleRequestPulse(msg.arg1, msg.arg2 != 0, (DozeService) msg.obj);
+                    handleRequestPulse((DozeService) msg.obj);
                 } else if (msg.what == DOZING_STOPPED) {
                     handleDozingStopped((DozeService) msg.obj);
                 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java
index bd52cd3..6006217 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBarPolicy.java
@@ -27,12 +27,14 @@
 import android.os.Handler;
 import android.os.UserHandle;
 import android.provider.Settings.Global;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.util.Log;
 
 import com.android.internal.telephony.IccCardConstants;
 import com.android.internal.telephony.TelephonyIntents;
 import com.android.systemui.R;
+import com.android.systemui.statusbar.policy.CastController;
+import com.android.systemui.statusbar.policy.CastController.CastDevice;
 
 /**
  * This class contains all of the policy about which icons are installed in the status
@@ -46,6 +48,7 @@
     private static final boolean SHOW_SYNC_ICON = false;
 
     private static final String SLOT_SYNC_ACTIVE = "sync_active";
+    private static final String SLOT_CAST = "cast";
     private static final String SLOT_BLUETOOTH = "bluetooth";
     private static final String SLOT_TTY = "tty";
     private static final String SLOT_ZEN = "zen";
@@ -56,6 +59,7 @@
     private final Context mContext;
     private final StatusBarManager mService;
     private final Handler mHandler = new Handler();
+    private final CastController mCast;
 
     // Assume it's all good unless we hear otherwise.  We don't always seem
     // to get broadcasts that it *is* there.
@@ -89,7 +93,7 @@
             else if (action.equals(TelephonyIntents.ACTION_SIM_STATE_CHANGED)) {
                 updateSimState(intent);
             }
-            else if (action.equals(TelecommManager.ACTION_CURRENT_TTY_MODE_CHANGED)) {
+            else if (action.equals(TelecomManager.ACTION_CURRENT_TTY_MODE_CHANGED)) {
                 updateTTY(intent);
             }
             else if (action.equals(Intent.ACTION_USER_SWITCHED)) {
@@ -98,8 +102,9 @@
         }
     };
 
-    public PhoneStatusBarPolicy(Context context) {
+    public PhoneStatusBarPolicy(Context context, CastController cast) {
         mContext = context;
+        mCast = cast;
         mService = (StatusBarManager)context.getSystemService(Context.STATUS_BAR_SERVICE);
 
         // listen for broadcasts
@@ -110,7 +115,7 @@
         filter.addAction(BluetoothAdapter.ACTION_STATE_CHANGED);
         filter.addAction(BluetoothAdapter.ACTION_CONNECTION_STATE_CHANGED);
         filter.addAction(TelephonyIntents.ACTION_SIM_STATE_CHANGED);
-        filter.addAction(TelecommManager.ACTION_CURRENT_TTY_MODE_CHANGED);
+        filter.addAction(TelecomManager.ACTION_CURRENT_TTY_MODE_CHANGED);
         filter.addAction(Intent.ACTION_USER_SWITCHED);
         mContext.registerReceiver(mIntentReceiver, filter, null, mHandler);
 
@@ -151,6 +156,11 @@
         mService.setIcon(SLOT_VOLUME, R.drawable.stat_sys_ringer_vibrate, 0, null);
         mService.setIconVisibility(SLOT_VOLUME, false);
         updateVolumeZen();
+
+        // cast
+        mService.setIcon(SLOT_CAST, R.drawable.stat_sys_cast, 0, null);
+        mService.setIconVisibility(SLOT_CAST, false);
+        mCast.addCallback(mCastCallback);
     }
 
     public void setZenMode(int zen) {
@@ -269,9 +279,9 @@
     }
 
     private final void updateTTY(Intent intent) {
-        int currentTtyMode = intent.getIntExtra(TelecommManager.EXTRA_CURRENT_TTY_MODE,
-                TelecommManager.TTY_MODE_OFF);
-        boolean enabled = currentTtyMode != TelecommManager.TTY_MODE_OFF;
+        int currentTtyMode = intent.getIntExtra(TelecomManager.EXTRA_CURRENT_TTY_MODE,
+                TelecomManager.TTY_MODE_OFF);
+        boolean enabled = currentTtyMode != TelecomManager.TTY_MODE_OFF;
 
         if (DEBUG) Log.v(TAG, "updateTTY: enabled: " + enabled);
 
@@ -287,4 +297,28 @@
             mService.setIconVisibility(SLOT_TTY, false);
         }
     }
+
+    private void updateCast() {
+        boolean isCasting = false;
+        for (CastDevice device : mCast.getCastDevices()) {
+            if (device.state == CastDevice.STATE_CONNECTING
+                    || device.state == CastDevice.STATE_CONNECTED) {
+                isCasting = true;
+                break;
+            }
+        }
+        if (DEBUG) Log.v(TAG, "updateCast: isCasting: " + isCasting);
+        if (isCasting) {
+            mService.setIcon(SLOT_CAST, R.drawable.stat_sys_cast, 0,
+                    mContext.getString(R.string.accessibility_casting));
+        }
+        mService.setIconVisibility(SLOT_CAST, isCasting);
+    }
+
+    private final CastController.Callback mCastCallback = new CastController.Callback() {
+        @Override
+        public void onCastDevicesChanged() {
+            updateCast();
+        }
+    };
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/QSTileHost.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/QSTileHost.java
index 729d459..2dc08d4 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/QSTileHost.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/QSTileHost.java
@@ -119,6 +119,7 @@
                 for (QSTile<?> tile : mTiles.values()) {
                     tile.userSwitch(newUserId);
                 }
+                mSecurity.onUserSwitched(newUserId);
                 mObserver.register();
             }
         };
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimController.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimController.java
index 455c336..3ff11d2 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/ScrimController.java
@@ -19,6 +19,7 @@
 import android.animation.Animator;
 import android.animation.AnimatorListenerAdapter;
 import android.animation.ValueAnimator;
+import android.content.Context;
 import android.graphics.Color;
 import android.graphics.drawable.ColorDrawable;
 import android.util.Log;
@@ -36,26 +37,20 @@
  */
 public class ScrimController implements ViewTreeObserver.OnPreDrawListener {
     private static final String TAG = "ScrimController";
-    private static final boolean DEBUG = false;
+    private static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
+
+    public static final long ANIMATION_DURATION = 220;
 
     private static final float SCRIM_BEHIND_ALPHA = 0.62f;
     private static final float SCRIM_BEHIND_ALPHA_KEYGUARD = 0.55f;
     private static final float SCRIM_BEHIND_ALPHA_UNLOCKING = 0.2f;
     private static final float SCRIM_IN_FRONT_ALPHA = 0.75f;
-    private static final long ANIMATION_DURATION = 220;
     private static final int TAG_KEY_ANIM = R.id.scrim;
 
-    private static final long PULSE_IN_ANIMATION_DURATION = 1000;
-    private static final long PULSE_VISIBLE_DURATION = 3000;
-    private static final long PULSE_OUT_ANIMATION_DURATION = 1000;
-    private static final long PULSE_INVISIBLE_DURATION = 1000;
-    private static final long PULSE_DURATION = PULSE_IN_ANIMATION_DURATION
-            + PULSE_VISIBLE_DURATION + PULSE_OUT_ANIMATION_DURATION + PULSE_INVISIBLE_DURATION;
-    private static final long PRE_PULSE_DELAY = 1000;
-
     private final View mScrimBehind;
     private final View mScrimInFront;
     private final UnlockMethodCache mUnlockMethodCache;
+    private final DozeParameters mDozeParameters;
 
     private boolean mKeyguardShowing;
     private float mFraction;
@@ -71,16 +66,18 @@
     private Runnable mOnAnimationFinished;
     private boolean mAnimationStarted;
     private boolean mDozing;
-    private int mPulsesRemaining;
+    private long mPulseEndTime;
     private final Interpolator mInterpolator = new DecelerateInterpolator();
     private final Interpolator mLinearOutSlowInInterpolator;
 
     public ScrimController(View scrimBehind, View scrimInFront) {
         mScrimBehind = scrimBehind;
         mScrimInFront = scrimInFront;
-        mUnlockMethodCache = UnlockMethodCache.getInstance(scrimBehind.getContext());
-        mLinearOutSlowInInterpolator = AnimationUtils.loadInterpolator(scrimBehind.getContext(),
+        final Context context = scrimBehind.getContext();
+        mUnlockMethodCache = UnlockMethodCache.getInstance(context);
+        mLinearOutSlowInInterpolator = AnimationUtils.loadInterpolator(context,
                 android.R.interpolator.linear_out_slow_in);
+        mDozeParameters = new DozeParameters(context);
     }
 
     public void setKeyguardShowing(boolean showing) {
@@ -131,23 +128,33 @@
         mDozing = dozing;
         if (!mDozing) {
             cancelPulsing();
+            mAnimateChange = true;
+        } else {
+            mAnimateChange = false;
         }
         scheduleUpdate();
     }
 
-    /** When dozing, fade screen contents in and out a few times using the front scrim. */
-    public long pulse(int pulses, boolean delayed) {
+    /** When dozing, fade screen contents in and out using the front scrim. */
+    public long pulse() {
         if (!mDozing) return 0;
-        mPulsesRemaining = Math.max(pulses, mPulsesRemaining);
-        final long delay = delayed ? PRE_PULSE_DELAY : 0;
-        mScrimInFront.postDelayed(mPulseIn, delay);
-        return delay + mPulsesRemaining * PULSE_DURATION;
+        final long now = System.currentTimeMillis();
+        if (DEBUG) Log.d(TAG, "pulse mPulseEndTime=" + mPulseEndTime + " now=" + now);
+        if (mPulseEndTime != 0 && mPulseEndTime > now) return mPulseEndTime - now;
+        mScrimInFront.post(mPulseIn);
+        mPulseEndTime = now + mDozeParameters.getPulseDuration();
+        return mPulseEndTime - now;
+    }
+
+    public boolean isPulsing() {
+        return mDozing && mPulseEndTime != 0;
     }
 
     private void cancelPulsing() {
-        mPulsesRemaining = 0;
+        if (DEBUG) Log.d(TAG, "Cancel pulsing");
         mScrimInFront.removeCallbacks(mPulseIn);
         mScrimInFront.removeCallbacks(mPulseOut);
+        mPulseEndTime = 0;
     }
 
     private void scheduleUpdate() {
@@ -163,7 +170,7 @@
         if (mAnimateKeyguardFadingOut) {
             setScrimInFrontColor(0f);
             setScrimBehindColor(0f);
-        }else if (!mKeyguardShowing && !mBouncerShowing) {
+        } else if (!mKeyguardShowing && !mBouncerShowing) {
             updateScrimNormal();
             setScrimInFrontColor(0);
         } else {
@@ -217,8 +224,8 @@
             mScrimInFront.setClickable(false);
         } else {
 
-            // Eat touch events.
-            mScrimInFront.setClickable(true);
+            // Eat touch events (unless dozing).
+            mScrimInFront.setClickable(!mDozing);
         }
     }
 
@@ -300,11 +307,9 @@
     private final Runnable mPulseIn = new Runnable() {
         @Override
         public void run() {
-            if (DEBUG) Log.d(TAG, "Pulse in, mDozing=" + mDozing
-                    + " mPulsesRemaining=" + mPulsesRemaining);
-            if (!mDozing || mPulsesRemaining == 0) return;
-            mPulsesRemaining--;
-            mDurationOverride = PULSE_IN_ANIMATION_DURATION;
+            if (DEBUG) Log.d(TAG, "Pulse in, mDozing=" + mDozing);
+            if (!mDozing) return;
+            mDurationOverride = mDozeParameters.getPulseInDuration();
             mAnimationDelay = 0;
             mAnimateChange = true;
             mOnAnimationFinished = mPulseInFinished;
@@ -317,7 +322,7 @@
         public void run() {
             if (DEBUG) Log.d(TAG, "Pulse in finished, mDozing=" + mDozing);
             if (!mDozing) return;
-            mScrimInFront.postDelayed(mPulseOut, PULSE_VISIBLE_DURATION);
+            mScrimInFront.postDelayed(mPulseOut, mDozeParameters.getPulseVisibleDuration());
         }
     };
 
@@ -326,7 +331,7 @@
         public void run() {
             if (DEBUG) Log.d(TAG, "Pulse out, mDozing=" + mDozing);
             if (!mDozing) return;
-            mDurationOverride = PULSE_OUT_ANIMATION_DURATION;
+            mDurationOverride = mDozeParameters.getPulseOutDuration();
             mAnimationDelay = 0;
             mAnimateChange = true;
             mOnAnimationFinished = mPulseOutFinished;
@@ -337,10 +342,8 @@
     private final Runnable mPulseOutFinished = new Runnable() {
         @Override
         public void run() {
-            if (DEBUG) Log.d(TAG, "Pulse out finished, mPulsesRemaining=" + mPulsesRemaining);
-            if (mPulsesRemaining > 0) {
-                mScrimInFront.postDelayed(mPulseIn, PULSE_INVISIBLE_DURATION);
-            }
+            if (DEBUG) Log.d(TAG, "Pulse out finished");
+            mPulseEndTime = 0;
         }
     };
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/SecureCameraLaunchManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/SecureCameraLaunchManager.java
index 4a5a069..3f5cf3f 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/SecureCameraLaunchManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/SecureCameraLaunchManager.java
@@ -57,8 +57,7 @@
  * the UI thread.
  */
 public class SecureCameraLaunchManager {
-    // TODO(bcolonna): Turn off debugging after running with this change for a while. STOPSHIP
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
     private static final String TAG = "SecureCameraLaunchManager";
 
     // Action sent as a broadcast to tell other apps to stop using the camera.  Other apps that use
@@ -86,12 +85,12 @@
     private KeyguardBottomAreaView mKeyguardBottomArea;
 
     private CameraManager mCameraManager;
-    private CameraAvailabilityListener mCameraAvailabilityListener;
+    private CameraAvailabilityCallback mCameraAvailabilityCallback;
     private Map<String, Boolean> mCameraAvailabilityMap;
     private boolean mWaitingToLaunchSecureCamera;
     private Runnable mLaunchCameraRunnable;
 
-    private class CameraAvailabilityListener extends CameraManager.AvailabilityListener {
+    private class CameraAvailabilityCallback extends CameraManager.AvailabilityCallback {
         @Override
         public void onCameraUnavailable(String cameraId) {
             if (DEBUG) Log.d(TAG, "onCameraUnavailble(" + cameraId + ")");
@@ -124,10 +123,10 @@
         mKeyguardBottomArea = keyguardBottomArea;
 
         mCameraManager = (CameraManager) context.getSystemService(Context.CAMERA_SERVICE);
-        mCameraAvailabilityListener = new CameraAvailabilityListener();
+        mCameraAvailabilityCallback = new CameraAvailabilityCallback();
 
         // An onCameraAvailable() or onCameraUnavailable() callback will be received for each camera
-        // when the availability listener is registered, thus initializing the map.
+        // when the availability callback is registered, thus initializing the map.
         //
         // Keeping track of the state of all cameras using the onCameraAvailable() and
         // onCameraUnavailable() callbacks can get messy when dealing with hot-pluggable cameras.
@@ -151,14 +150,14 @@
      * Initializes the SecureCameraManager and starts listening for camera availability.
      */
     public void create() {
-        mCameraManager.addAvailabilityListener(mCameraAvailabilityListener, mHandler);
+        mCameraManager.registerAvailabilityCallback(mCameraAvailabilityCallback, mHandler);
     }
 
     /**
      * Stops listening for camera availability and cleans up the SecureCameraManager.
      */
     public void destroy() {
-        mCameraManager.removeAvailabilityListener(mCameraAvailabilityListener);
+        mCameraManager.unregisterAvailabilityCallback(mCameraAvailabilityCallback);
     }
 
     /**
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
index 8bc7dd4..cb9abfd 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarHeaderView.java
@@ -20,11 +20,14 @@
 import android.app.PendingIntent;
 import android.content.Context;
 import android.content.Intent;
+import android.content.res.Configuration;
+import android.content.res.Resources;
 import android.graphics.Outline;
 import android.graphics.Rect;
 import android.graphics.drawable.Animatable;
 import android.graphics.drawable.Drawable;
 import android.util.AttributeSet;
+import android.util.MathUtils;
 import android.util.TypedValue;
 import android.view.View;
 import android.view.ViewGroup;
@@ -36,6 +39,8 @@
 import android.widget.TextView;
 
 import com.android.keyguard.KeyguardStatusView;
+import com.android.systemui.BatteryMeterView;
+import com.android.systemui.FontSizeUtils;
 import com.android.systemui.R;
 import com.android.systemui.qs.QSPanel;
 import com.android.systemui.qs.QSTile;
@@ -57,20 +62,19 @@
     private View mDateGroup;
     private View mClock;
     private TextView mTime;
-    private View mAmPm;
+    private TextView mAmPm;
     private MultiUserSwitch mMultiUserSwitch;
     private ImageView mMultiUserAvatar;
-    private View mDateCollapsed;
-    private View mDateExpanded;
+    private TextView mDateCollapsed;
+    private TextView mDateExpanded;
     private LinearLayout mSystemIcons;
-    private View mStatusIcons;
     private View mSignalCluster;
     private View mSettingsButton;
     private View mQsDetailHeader;
     private TextView mQsDetailHeaderTitle;
     private Switch mQsDetailHeaderSwitch;
     private ImageView mQsDetailHeaderProgress;
-    private View mEmergencyCallsOnly;
+    private TextView mEmergencyCallsOnly;
     private TextView mBatteryLevel;
     private TextView mAlarmStatus;
 
@@ -114,6 +118,7 @@
     private final LayoutValues mCurrentValues = new LayoutValues();
 
     private float mCurrentT;
+    private boolean mShowingDetail;
 
     public StatusBarHeaderView(Context context, AttributeSet attrs) {
         super(context, attrs);
@@ -128,11 +133,11 @@
         mDateGroup = findViewById(R.id.date_group);
         mClock = findViewById(R.id.clock);
         mTime = (TextView) findViewById(R.id.time_view);
-        mAmPm = findViewById(R.id.am_pm_view);
+        mAmPm = (TextView) findViewById(R.id.am_pm_view);
         mMultiUserSwitch = (MultiUserSwitch) findViewById(R.id.multi_user_switch);
         mMultiUserAvatar = (ImageView) findViewById(R.id.multi_user_avatar);
-        mDateCollapsed = findViewById(R.id.date_collapsed);
-        mDateExpanded = findViewById(R.id.date_expanded);
+        mDateCollapsed = (TextView) findViewById(R.id.date_collapsed);
+        mDateExpanded = (TextView) findViewById(R.id.date_expanded);
         mSettingsButton = findViewById(R.id.settings_button);
         mSettingsButton.setOnClickListener(this);
         mQsDetailHeader = findViewById(R.id.qs_detail_header);
@@ -140,10 +145,12 @@
         mQsDetailHeaderTitle = (TextView) mQsDetailHeader.findViewById(android.R.id.title);
         mQsDetailHeaderSwitch = (Switch) mQsDetailHeader.findViewById(android.R.id.toggle);
         mQsDetailHeaderProgress = (ImageView) findViewById(R.id.qs_detail_header_progress);
-        mEmergencyCallsOnly = findViewById(R.id.header_emergency_calls_only);
+        mEmergencyCallsOnly = (TextView) findViewById(R.id.header_emergency_calls_only);
         mBatteryLevel = (TextView) findViewById(R.id.battery_level);
         mAlarmStatus = (TextView) findViewById(R.id.alarm_status);
         mAlarmStatus.setOnClickListener(this);
+        mSignalCluster = findViewById(R.id.signal_cluster);
+        mSystemIcons = (LinearLayout) findViewById(R.id.system_icons);
         loadDimens();
         updateVisibilities();
         updateClockScale();
@@ -186,6 +193,41 @@
         mAlarmStatus.setX(mDateGroup.getLeft() + mDateCollapsed.getRight());
     }
 
+    @Override
+    protected void onConfigurationChanged(Configuration newConfig) {
+        super.onConfigurationChanged(newConfig);
+        FontSizeUtils.updateFontSize(mBatteryLevel, R.dimen.battery_level_text_size);
+        FontSizeUtils.updateFontSize(mEmergencyCallsOnly,
+                R.dimen.qs_emergency_calls_only_text_size);
+        FontSizeUtils.updateFontSize(mDateCollapsed, R.dimen.qs_date_collapsed_size);
+        FontSizeUtils.updateFontSize(mDateExpanded, R.dimen.qs_date_collapsed_size);
+        FontSizeUtils.updateFontSize(mAlarmStatus, R.dimen.qs_date_collapsed_size);
+        FontSizeUtils.updateFontSize(this, android.R.id.title, R.dimen.qs_detail_header_text_size);
+        FontSizeUtils.updateFontSize(this, android.R.id.toggle, R.dimen.qs_detail_header_text_size);
+        FontSizeUtils.updateFontSize(mAmPm, R.dimen.qs_time_collapsed_size);
+        FontSizeUtils.updateFontSize(this, R.id.empty_time_view, R.dimen.qs_time_expanded_size);
+
+        mEmergencyCallsOnly.setText(com.android.internal.R.string.emergency_calls_only);
+
+        mClockCollapsedSize = getResources().getDimensionPixelSize(R.dimen.qs_time_collapsed_size);
+        mClockExpandedSize = getResources().getDimensionPixelSize(R.dimen.qs_time_expanded_size);
+        mClockCollapsedScaleFactor = (float) mClockCollapsedSize / (float) mClockExpandedSize;
+
+        updateClockScale();
+        updateClockCollapsedMargin();
+    }
+
+    private void updateClockCollapsedMargin() {
+        Resources res = getResources();
+        int padding = res.getDimensionPixelSize(R.dimen.clock_collapsed_bottom_margin);
+        int largePadding = res.getDimensionPixelSize(
+                R.dimen.clock_collapsed_bottom_margin_large_text);
+        float largeFactor = (MathUtils.constrain(getResources().getConfiguration().fontScale, 1.0f,
+                FontSizeUtils.LARGE_TEXT_SCALE) - 1f) / (FontSizeUtils.LARGE_TEXT_SCALE - 1f);
+        mClockMarginBottomCollapsed = Math.round((1 - largeFactor) * padding + largeFactor * largePadding);
+        requestLayout();
+    }
+
     private void requestCaptureValues() {
         mCaptureValues = true;
         requestLayout();
@@ -199,11 +241,9 @@
                 getResources().getDimensionPixelSize(R.dimen.multi_user_switch_expanded_margin);
         mMultiUserCollapsedMargin =
                 getResources().getDimensionPixelSize(R.dimen.multi_user_switch_collapsed_margin);
-
         mClockMarginBottomExpanded =
                 getResources().getDimensionPixelSize(R.dimen.clock_expanded_bottom_margin);
-        mClockMarginBottomCollapsed =
-                getResources().getDimensionPixelSize(R.dimen.clock_collapsed_bottom_margin);
+        updateClockCollapsedMargin();
         mMultiUserSwitchWidthCollapsed =
                 getResources().getDimensionPixelSize(R.dimen.multi_user_switch_width_collapsed);
         mMultiUserSwitchWidthExpanded =
@@ -223,6 +263,7 @@
 
     public void setBatteryController(BatteryController batteryController) {
         mBatteryController = batteryController;
+        ((BatteryMeterView) findViewById(R.id.battery)).setBatteryController(batteryController);
     }
 
     public void setNextAlarmController(NextAlarmController nextAlarmController) {
@@ -282,7 +323,7 @@
         mDateExpanded.setVisibility(mExpanded && mAlarmShowing ? View.INVISIBLE : View.VISIBLE);
         mAlarmStatus.setVisibility(mExpanded && mAlarmShowing ? View.VISIBLE : View.INVISIBLE);
         mSettingsButton.setVisibility(mExpanded ? View.VISIBLE : View.INVISIBLE);
-        mQsDetailHeader.setVisibility(mExpanded ? View.VISIBLE : View.GONE);
+        mQsDetailHeader.setVisibility(mExpanded && mShowingDetail? View.VISIBLE : View.INVISIBLE);
         if (mSignalCluster != null) {
             updateSignalClusterDetachment();
         }
@@ -375,7 +416,9 @@
 
     private void updateClickTargets() {
         mMultiUserSwitch.setClickable(mExpanded);
+        mMultiUserSwitch.setFocusable(mExpanded);
         mSystemIconsSuperContainer.setClickable(mExpanded);
+        mSystemIconsSuperContainer.setFocusable(mExpanded);
         mAlarmStatus.setClickable(mNextAlarm != null && mNextAlarm.getShowIntent() != null);
     }
 
@@ -438,36 +481,6 @@
         invalidateOutline();
     }
 
-    public void attachSystemIcons(LinearLayout systemIcons) {
-        mSystemIconsContainer.addView(systemIcons);
-        mStatusIcons = systemIcons.findViewById(R.id.statusIcons);
-        mSignalCluster = systemIcons.findViewById(R.id.signal_cluster);
-        mSystemIcons = systemIcons;
-        updateVisibilities();
-        if (mStatusIcons != null) {
-            mStatusIcons.setVisibility(View.GONE);
-        }
-    }
-
-    public void onSystemIconsDetached() {
-        if (mSignalClusterDetached) {
-            reattachSignalCluster();
-            mSignalClusterDetached = false;
-        }
-        if (mStatusIcons != null) {
-            mStatusIcons.setVisibility(View.VISIBLE);
-        }
-        if (mSignalCluster != null) {
-            mSignalCluster.setVisibility(View.VISIBLE);
-            mSignalCluster.setAlpha(1f);
-            mSignalCluster.setTranslationX(0f);
-            mSignalCluster.setTranslationY(0f);
-        }
-        mStatusIcons = null;
-        mSignalCluster = null;
-        mSystemIcons = null;
-    }
-
     public void setUserInfoController(UserInfoController userInfoController) {
         userInfoController.addListener(new UserInfoController.OnUserInfoChangedListener() {
             @Override
@@ -542,7 +555,13 @@
         target.avatarScale = mMultiUserAvatar.getScaleX();
         target.avatarX = mMultiUserSwitch.getLeft() + mMultiUserAvatar.getLeft();
         target.avatarY = mMultiUserSwitch.getTop() + mMultiUserAvatar.getTop();
-        target.batteryX = mSystemIconsSuperContainer.getLeft() + mSystemIconsContainer.getRight();
+        if (getLayoutDirection() == LAYOUT_DIRECTION_LTR) {
+            target.batteryX = mSystemIconsSuperContainer.getLeft()
+                    + mSystemIconsContainer.getRight();
+        } else {
+            target.batteryX = mSystemIconsSuperContainer.getLeft()
+                    + mSystemIconsContainer.getLeft();
+        }
         target.batteryY = mSystemIconsSuperContainer.getTop() + mSystemIconsContainer.getTop();
         target.batteryLevelAlpha = getAlphaForVisibility(mBatteryLevel);
         target.settingsAlpha = getAlphaForVisibility(mSettingsButton);
@@ -579,11 +598,20 @@
         mMultiUserAvatar.setScaleY(values.avatarScale);
         mMultiUserAvatar.setX(values.avatarX - mMultiUserSwitch.getLeft());
         mMultiUserAvatar.setY(values.avatarY - mMultiUserSwitch.getTop());
-        mSystemIconsSuperContainer.setX(values.batteryX - mSystemIconsContainer.getRight());
+        if (getLayoutDirection() == LAYOUT_DIRECTION_LTR) {
+            mSystemIconsSuperContainer.setX(values.batteryX - mSystemIconsContainer.getRight());
+        } else {
+            mSystemIconsSuperContainer.setX(values.batteryX - mSystemIconsContainer.getLeft());
+        }
         mSystemIconsSuperContainer.setY(values.batteryY - mSystemIconsContainer.getTop());
         if (mSignalCluster != null && mExpanded) {
-            mSignalCluster.setX(mSystemIconsSuperContainer.getX()
-                    - mSignalCluster.getWidth());
+            if (getLayoutDirection() == LAYOUT_DIRECTION_LTR) {
+                mSignalCluster.setX(mSystemIconsSuperContainer.getX()
+                        - mSignalCluster.getWidth());
+            } else {
+                mSignalCluster.setX(mSystemIconsSuperContainer.getX()
+                        + mSystemIconsSuperContainer.getWidth());
+            }
             mSignalCluster.setY(
                     mSystemIconsSuperContainer.getY() + mSystemIconsSuperContainer.getHeight()/2
                             - mSignalCluster.getHeight()/2);
@@ -714,7 +742,11 @@
             final boolean showingDetail = detail != null;
             transition(mClock, !showingDetail);
             transition(mDateGroup, !showingDetail);
+            if (mAlarmShowing) {
+                transition(mAlarmStatus, !showingDetail);
+            }
             transition(mQsDetailHeader, showingDetail);
+            mShowingDetail = showingDetail;
             if (showingDetail) {
                 mQsDetailHeaderTitle.setText(detail.getTitle());
                 final Boolean toggleState = detail.getToggleState();
@@ -740,8 +772,20 @@
         private void transition(final View v, final boolean in) {
             if (in) {
                 v.bringToFront();
+                v.setVisibility(VISIBLE);
             }
-            v.animate().alpha(in ? 1 : 0).withLayer().start();
+            v.animate()
+                    .alpha(in ? 1 : 0)
+                    .withLayer()
+                    .withEndAction(new Runnable() {
+                        @Override
+                        public void run() {
+                            if (!in) {
+                                v.setVisibility(INVISIBLE);
+                            }
+                        }
+                    })
+                    .start();
         }
     };
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
index f427ec4..55c861a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
@@ -43,6 +43,10 @@
     // When hiding the Keyguard with timing supplied from WindowManager, better be early than late.
     private static final long HIDE_TIMING_CORRECTION_MS = -3 * 16;
 
+    // Delay for showing the navigation bar when the bouncer appears. This should be kept in sync
+    // with the appear animations of the PIN/pattern/password views.
+    private static final long NAV_BAR_SHOW_DELAY_BOUNCER = 320;
+
     private static String TAG = "StatusBarKeyguardViewManager";
 
     private final Context mContext;
@@ -65,6 +69,7 @@
     private boolean mLastOccluded;
     private boolean mLastBouncerShowing;
     private boolean mLastBouncerDismissible;
+    private OnDismissAction mAfterKeyguardGoneAction;
 
     public StatusBarKeyguardViewManager(Context context, ViewMediatorCallback callback,
             LockPatternUtils lockPatternUtils) {
@@ -118,9 +123,14 @@
         updateStates();
     }
 
-    public void dismissWithAction(OnDismissAction r) {
+    public void dismissWithAction(OnDismissAction r, boolean afterKeyguardGone) {
         if (mShowing) {
-            mBouncer.showWithDismissAction(r);
+            if (!afterKeyguardGone) {
+                mBouncer.showWithDismissAction(r);
+            } else {
+                mBouncer.show();
+                mAfterKeyguardGoneAction = r;
+            }
         }
         updateStates();
     }
@@ -245,6 +255,7 @@
                     mPhoneStatusBar.hideKeyguard();
                     mStatusBarWindowManager.setKeyguardFadingAway(false);
                     mViewMediatorCallback.keyguardGone();
+                    executeAfterKeyguardGoneAction();
                 }
             });
         } else {
@@ -266,11 +277,19 @@
             mStatusBarWindowManager.setKeyguardShowing(false);
             mBouncer.hide(true /* destroyView */);
             mViewMediatorCallback.keyguardGone();
+            executeAfterKeyguardGoneAction();
             updateStates();
         }
 
     }
 
+    private void executeAfterKeyguardGoneAction() {
+        if (mAfterKeyguardGoneAction != null) {
+            mAfterKeyguardGoneAction.onDismiss();
+            mAfterKeyguardGoneAction = null;
+        }
+    }
+
     /**
      * Dismisses the keyguard by going to the next screen or making it gone.
      */
@@ -298,9 +317,7 @@
      */
     public boolean onBackPressed() {
         if (mBouncer.isShowing()) {
-            mBouncer.hide(false /* destroyView */);
-            mPhoneStatusBar.showKeyguard();
-            updateStates();
+            reset();
             return true;
         }
         return false;
@@ -310,12 +327,30 @@
         return mBouncer.isShowing();
     }
 
+    private long getNavBarShowDelay() {
+        if (mPhoneStatusBar.isKeyguardFadingAway()) {
+            return mPhoneStatusBar.getKeyguardFadingAwayDelay();
+        } else {
+
+            // Keyguard is not going away, thus we are showing the navigation bar because the
+            // bouncer is appearing.
+            return NAV_BAR_SHOW_DELAY_BOUNCER;
+        }
+    }
+
+    private Runnable mMakeNavigationBarVisibleRunnable = new Runnable() {
+        @Override
+        public void run() {
+            mPhoneStatusBar.getNavigationBarView().setVisibility(View.VISIBLE);
+        }
+    };
+
     private void updateStates() {
         int vis = mContainer.getSystemUiVisibility();
         boolean showing = mShowing;
         boolean occluded = mOccluded;
         boolean bouncerShowing = mBouncer.isShowing();
-        boolean bouncerDismissible = bouncerShowing && !mBouncer.needsFullscreenBouncer();
+        boolean bouncerDismissible = !mBouncer.needsFullscreenBouncer();
 
         if ((bouncerDismissible || !showing) != (mLastBouncerDismissible || !mLastShowing)
                 || mFirstUpdate) {
@@ -329,8 +364,10 @@
                 != (!(mLastShowing && !mLastOccluded) || mLastBouncerShowing) || mFirstUpdate) {
             if (mPhoneStatusBar.getNavigationBarView() != null) {
                 if (!(showing && !occluded) || bouncerShowing) {
-                    mPhoneStatusBar.getNavigationBarView().setVisibility(View.VISIBLE);
+                    mContainer.postOnAnimationDelayed(mMakeNavigationBarVisibleRunnable,
+                            getNavBarShowDelay());
                 } else {
+                    mContainer.removeCallbacks(mMakeNavigationBarVisibleRunnable);
                     mPhoneStatusBar.getNavigationBarView().setVisibility(View.GONE);
                 }
             }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java
index e1fd779..78554525 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java
@@ -42,6 +42,7 @@
     private DragDownHelper mDragDownHelper;
     private NotificationStackScrollLayout mStackScrollLayout;
     private NotificationPanelView mNotificationPanel;
+    private View mBrightnessMirror;
 
     PhoneStatusBar mService;
 
@@ -54,12 +55,24 @@
     @Override
     protected boolean fitSystemWindows(Rect insets) {
         if (getFitsSystemWindows()) {
-            setPadding(insets.left, insets.top, insets.right, 0);
+            boolean changed = insets.left != getPaddingLeft()
+                    || insets.top != getPaddingTop()
+                    || insets.right != getPaddingRight()
+                    || insets.bottom != getPaddingBottom();
+            if (changed) {
+                setPadding(insets.left, insets.top, insets.right, 0);
+            }
             insets.left = 0;
             insets.top = 0;
             insets.right = 0;
         } else {
-            setPadding(0, 0, 0, 0);
+            boolean changed = getPaddingLeft() != 0
+                    || getPaddingRight() != 0
+                    || getPaddingTop() != 0
+                    || getPaddingBottom() != 0;
+            if (changed) {
+                setPadding(0, 0, 0, 0);
+            }
         }
         return false;
     }
@@ -72,6 +85,7 @@
                 R.id.notification_stack_scroller);
         mNotificationPanel = (NotificationPanelView) findViewById(R.id.notification_panel);
         mDragDownHelper = new DragDownHelper(getContext(), this, mStackScrollLayout, mService);
+        mBrightnessMirror = findViewById(R.id.brightness_mirror);
 
         // We really need to be able to animate while window animations are going on
         // so that activities may be started asynchronously from panel animations
@@ -98,6 +112,11 @@
                 if (!down) {
                     return mService.onSpacePressed();
                 }
+            case KeyEvent.KEYCODE_VOLUME_DOWN:
+            case KeyEvent.KEYCODE_VOLUME_UP:
+                if (down) {
+                    mService.wakeUpIfDozing(event.getEventTime());
+                }
         }
         if (mService.interceptMediaKey(event)) {
             return true;
@@ -106,6 +125,19 @@
     }
 
     @Override
+    public boolean dispatchTouchEvent(MotionEvent ev) {
+        if (mBrightnessMirror != null && mBrightnessMirror.getVisibility() == VISIBLE) {
+            // Disallow new pointers while the brightness mirror is visible. This is so that you
+            // can't touch anything other than the brightness slider while the mirror is showing
+            // and the rest of the panel is transparent.
+            if (ev.getActionMasked() == MotionEvent.ACTION_POINTER_DOWN) {
+                return false;
+            }
+        }
+        return super.dispatchTouchEvent(ev);
+    }
+
+    @Override
     public boolean onInterceptTouchEvent(MotionEvent ev) {
         boolean intercept = false;
         if (mNotificationPanel.isFullyExpanded()
@@ -113,6 +145,10 @@
                 && mService.getBarState() == StatusBarState.KEYGUARD
                 && !mService.isBouncerShowing()) {
             intercept = mDragDownHelper.onInterceptTouchEvent(ev);
+            // wake up on a touch down event, if dozing
+            if (ev.getActionMasked() == MotionEvent.ACTION_DOWN) {
+                mService.wakeUpIfDozing(ev.getEventTime());
+            }
         }
         if (!intercept) {
             super.onInterceptTouchEvent(ev);
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/TrustDrawable.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/TrustDrawable.java
new file mode 100644
index 0000000..dcda2c7
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/TrustDrawable.java
@@ -0,0 +1,297 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar.phone;
+
+import com.android.systemui.R;
+
+import android.animation.Animator;
+import android.animation.AnimatorListenerAdapter;
+import android.animation.AnimatorSet;
+import android.animation.ValueAnimator;
+import android.content.Context;
+import android.content.res.Resources;
+import android.graphics.Canvas;
+import android.graphics.Color;
+import android.graphics.ColorFilter;
+import android.graphics.Paint;
+import android.graphics.PixelFormat;
+import android.graphics.Rect;
+import android.graphics.drawable.Drawable;
+import android.view.animation.AccelerateDecelerateInterpolator;
+import android.view.animation.AnimationUtils;
+import android.view.animation.Interpolator;
+
+public class TrustDrawable extends Drawable {
+
+    private static final long ENTERING_FROM_UNSET_START_DELAY = 200;
+    private static final long VISIBLE_DURATION = 1000;
+    private static final long EXIT_DURATION = 500;
+    private static final long ENTER_DURATION = 500;
+
+    private static final int ALPHA_VISIBLE_MIN = 0x26;
+    private static final int ALPHA_VISIBLE_MAX = 0x4c;
+
+    private static final int STATE_UNSET = -1;
+    private static final int STATE_GONE = 0;
+    private static final int STATE_ENTERING = 1;
+    private static final int STATE_VISIBLE = 2;
+    private static final int STATE_EXITING = 3;
+
+    private int mAlpha;
+    private boolean mAnimating;
+
+    private int mCurAlpha;
+    private float mCurInnerRadius;
+    private Animator mCurAnimator;
+    private int mState = STATE_UNSET;
+    private Paint mPaint;
+    private boolean mTrustManaged;
+
+    private final float mInnerRadiusVisibleMin;
+    private final float mInnerRadiusVisibleMax;
+    private final float mInnerRadiusExit;
+    private final float mInnerRadiusEnter;
+    private final float mThickness;
+
+    private final Animator mVisibleAnimator;
+
+    private final Interpolator mLinearOutSlowInInterpolator;
+    private final Interpolator mFastOutSlowInInterpolator;
+    private final Interpolator mAccelerateDecelerateInterpolator;
+
+    public TrustDrawable(Context context) {
+        Resources r = context.getResources();
+        mInnerRadiusVisibleMin = r.getDimension(R.dimen.trust_circle_inner_radius_visible_min);
+        mInnerRadiusVisibleMax = r.getDimension(R.dimen.trust_circle_inner_radius_visible_max);
+        mInnerRadiusExit = r.getDimension(R.dimen.trust_circle_inner_radius_exit);
+        mInnerRadiusEnter = r.getDimension(R.dimen.trust_circle_inner_radius_enter);
+        mThickness = r.getDimension(R.dimen.trust_circle_thickness);
+
+        mCurInnerRadius = mInnerRadiusEnter;
+
+        mLinearOutSlowInInterpolator = AnimationUtils.loadInterpolator(
+                context, android.R.interpolator.linear_out_slow_in);
+        mFastOutSlowInInterpolator = AnimationUtils.loadInterpolator(
+                context, android.R.interpolator.fast_out_slow_in);
+        mAccelerateDecelerateInterpolator = new AccelerateDecelerateInterpolator();
+
+        mVisibleAnimator = makeVisibleAnimator();
+
+        mPaint = new Paint();
+        mPaint.setStyle(Paint.Style.STROKE);
+        mPaint.setColor(Color.WHITE);
+        mPaint.setAntiAlias(true);
+        mPaint.setStrokeWidth(mThickness);
+    }
+
+    @Override
+    public void draw(Canvas canvas) {
+        int newAlpha = (mCurAlpha * mAlpha) / 256;
+        if (newAlpha == 0) {
+            return;
+        }
+        final Rect r = getBounds();
+        mPaint.setAlpha(newAlpha);
+        canvas.drawCircle(r.exactCenterX(), r.exactCenterY(), mCurInnerRadius, mPaint);
+    }
+
+    @Override
+    public void setAlpha(int alpha) {
+        mAlpha = alpha;
+    }
+
+    @Override
+    public int getAlpha() {
+        return mAlpha;
+    }
+
+    @Override
+    public void setColorFilter(ColorFilter cf) {
+        throw new UnsupportedOperationException("not implemented");
+    }
+
+    @Override
+    public int getOpacity() {
+        return PixelFormat.TRANSLUCENT;
+    }
+
+    public void start() {
+        if (!mAnimating) {
+            mAnimating = true;
+            updateState(true);
+        }
+    }
+
+    public void stop() {
+        if (mAnimating) {
+            mAnimating = false;
+            if (mCurAnimator != null) {
+                mCurAnimator.cancel();
+                mCurAnimator = null;
+            }
+            mState = STATE_UNSET;
+            mCurAlpha = 0;
+            mCurInnerRadius = mInnerRadiusEnter;
+        }
+    }
+
+    public void setTrustManaged(boolean trustManaged) {
+        if (trustManaged == mTrustManaged && mState != STATE_UNSET) return;
+        mTrustManaged = trustManaged;
+        if (mAnimating) {
+            updateState(true);
+        }
+    }
+
+    private void updateState(boolean animate) {
+        int nextState = mState;
+        if (mState == STATE_UNSET) {
+            nextState = mTrustManaged ? STATE_ENTERING : STATE_GONE;
+        } else if (mState == STATE_GONE) {
+            if (mTrustManaged) nextState = STATE_ENTERING;
+        } else if (mState == STATE_ENTERING) {
+            if (!mTrustManaged) nextState = STATE_EXITING;
+        } else if (mState == STATE_VISIBLE) {
+            if (!mTrustManaged) nextState = STATE_EXITING;
+        } else if (mState == STATE_EXITING) {
+            if (mTrustManaged) nextState = STATE_ENTERING;
+        }
+        if (!animate) {
+            if (nextState == STATE_ENTERING) nextState = STATE_VISIBLE;
+            if (nextState == STATE_EXITING) nextState = STATE_GONE;
+        }
+
+        if (nextState != mState) {
+            if (mCurAnimator != null) {
+                mCurAnimator.cancel();
+                mCurAnimator = null;
+            }
+
+            if (nextState == STATE_GONE) {
+                mCurAlpha = 0;
+                mCurInnerRadius = mInnerRadiusEnter;
+            } else if (nextState == STATE_ENTERING) {
+                mCurAnimator = makeEnterAnimator(mCurInnerRadius, mCurAlpha);
+                if (mState == STATE_UNSET) {
+                    mCurAnimator.setStartDelay(ENTERING_FROM_UNSET_START_DELAY);
+                }
+            } else if (nextState == STATE_VISIBLE) {
+                mCurAlpha = ALPHA_VISIBLE_MAX;
+                mCurInnerRadius = mInnerRadiusVisibleMax;
+                mCurAnimator = mVisibleAnimator;
+            } else if (nextState == STATE_EXITING) {
+                mCurAnimator = makeExitAnimator(mCurInnerRadius, mCurAlpha);
+            }
+
+            mState = nextState;
+            if (mCurAnimator != null) {
+                mCurAnimator.start();
+            } else {
+                invalidateSelf();
+            }
+        }
+    }
+
+    private Animator makeVisibleAnimator() {
+        return makeAnimators(mInnerRadiusVisibleMax, mInnerRadiusVisibleMin,
+                ALPHA_VISIBLE_MAX, ALPHA_VISIBLE_MIN, VISIBLE_DURATION,
+                mAccelerateDecelerateInterpolator,
+                true /* repeating */, false /* stateUpdateListener */);
+    }
+
+    private Animator makeEnterAnimator(float radius, int alpha) {
+        return makeAnimators(radius, mInnerRadiusVisibleMax,
+                alpha, ALPHA_VISIBLE_MAX, ENTER_DURATION, mLinearOutSlowInInterpolator,
+                false /* repeating */, true /* stateUpdateListener */);
+    }
+
+    private Animator makeExitAnimator(float radius, int alpha) {
+        return makeAnimators(radius, mInnerRadiusExit,
+                alpha, 0, EXIT_DURATION, mFastOutSlowInInterpolator,
+                false /* repeating */, true /* stateUpdateListener */);
+    }
+
+    private Animator makeAnimators(float startRadius, float endRadius,
+            int startAlpha, int endAlpha, long duration, Interpolator interpolator,
+            boolean repeating, boolean stateUpdateListener) {
+        ValueAnimator alphaAnimator = configureAnimator(
+                ValueAnimator.ofInt(startAlpha, endAlpha),
+                duration, mAlphaUpdateListener, interpolator, repeating);
+        ValueAnimator sizeAnimator = configureAnimator(
+                ValueAnimator.ofFloat(startRadius, endRadius),
+                duration, mRadiusUpdateListener, interpolator, repeating);
+
+        AnimatorSet set = new AnimatorSet();
+        set.playTogether(alphaAnimator, sizeAnimator);
+        if (stateUpdateListener) {
+            set.addListener(new StateUpdateAnimatorListener());
+        }
+        return set;
+    }
+
+    private ValueAnimator configureAnimator(ValueAnimator animator, long duration,
+            ValueAnimator.AnimatorUpdateListener updateListener, Interpolator interpolator,
+            boolean repeating) {
+        animator.setDuration(duration);
+        animator.addUpdateListener(updateListener);
+        animator.setInterpolator(interpolator);
+        if (repeating) {
+            animator.setRepeatCount(ValueAnimator.INFINITE);
+            animator.setRepeatMode(ValueAnimator.REVERSE);
+        }
+        return animator;
+    }
+
+    private final ValueAnimator.AnimatorUpdateListener mAlphaUpdateListener =
+            new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            mCurAlpha = (int) animation.getAnimatedValue();
+            invalidateSelf();
+        }
+    };
+
+    private final ValueAnimator.AnimatorUpdateListener mRadiusUpdateListener =
+            new ValueAnimator.AnimatorUpdateListener() {
+        @Override
+        public void onAnimationUpdate(ValueAnimator animation) {
+            mCurInnerRadius = (float) animation.getAnimatedValue();
+            invalidateSelf();
+        }
+    };
+
+    private class StateUpdateAnimatorListener extends AnimatorListenerAdapter {
+        boolean mCancelled;
+
+        @Override
+        public void onAnimationStart(Animator animation) {
+            mCancelled = false;
+        }
+
+        @Override
+        public void onAnimationCancel(Animator animation) {
+            mCancelled = true;
+        }
+
+        @Override
+        public void onAnimationEnd(Animator animation) {
+            if (!mCancelled) {
+                updateState(false);
+            }
+        }
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockMethodCache.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockMethodCache.java
index 58196f7..e5eef9d 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockMethodCache.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/UnlockMethodCache.java
@@ -38,6 +38,7 @@
     private final ArrayList<OnUnlockMethodChangedListener> mListeners = new ArrayList<>();
     private boolean mMethodInsecure;
     private boolean mTrustManaged;
+    private boolean mFaceUnlockRunning;
 
     private UnlockMethodCache(Context ctx) {
         mLockPatternUtils = new LockPatternUtils(ctx);
@@ -73,10 +74,14 @@
         boolean methodInsecure = !mLockPatternUtils.isSecure() ||
                 mKeyguardUpdateMonitor.getUserHasTrust(user);
         boolean trustManaged = mKeyguardUpdateMonitor.getUserTrustIsManaged(user);
-        boolean changed = methodInsecure != mMethodInsecure || trustManaged != mTrustManaged;
+        boolean faceUnlockRunning = mKeyguardUpdateMonitor.isFaceUnlockRunning(user)
+                && trustManaged;
+        boolean changed = methodInsecure != mMethodInsecure || trustManaged != mTrustManaged
+                || faceUnlockRunning != mFaceUnlockRunning;
         if (changed || updateAlways) {
             mMethodInsecure = methodInsecure;
             mTrustManaged = trustManaged;
+            mFaceUnlockRunning = faceUnlockRunning;
             notifyListeners(mMethodInsecure);
         }
     }
@@ -112,12 +117,21 @@
         public void onFingerprintRecognized(int userId) {
             updateMethodSecure(false /* updateAlways */);
         }
+
+        @Override
+        public void onFaceUnlockStateChanged(boolean running, int userId) {
+            updateMethodSecure(false /* updateAlways */);
+        }
     };
 
     public boolean isTrustManaged() {
         return mTrustManaged;
     }
 
+    public boolean isFaceUnlockRunning() {
+        return mFaceUnlockRunning;
+    }
+
     public static interface OnUnlockMethodChangedListener {
         void onMethodSecureChanged(boolean methodSecure);
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/AccessibilityController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/AccessibilityController.java
new file mode 100644
index 0000000..89ed787
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/AccessibilityController.java
@@ -0,0 +1,90 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar.policy;
+
+import android.content.Context;
+import android.util.Log;
+import android.view.accessibility.AccessibilityManager;
+
+import java.io.FileDescriptor;
+import java.io.PrintWriter;
+import java.util.ArrayList;
+
+public class AccessibilityController implements
+        AccessibilityManager.AccessibilityStateChangeListener,
+        AccessibilityManager.TouchExplorationStateChangeListener {
+
+    private final ArrayList<AccessibilityStateChangedCallback> mChangeCallbacks = new ArrayList<>();
+
+    private boolean mAccessibilityEnabled;
+    private boolean mTouchExplorationEnabled;
+
+    public AccessibilityController(Context context) {
+        AccessibilityManager am =
+                (AccessibilityManager) context.getSystemService(Context.ACCESSIBILITY_SERVICE);
+        am.addTouchExplorationStateChangeListener(this);
+        am.addAccessibilityStateChangeListener(this);
+        mAccessibilityEnabled = am.isEnabled();
+        mTouchExplorationEnabled = am.isTouchExplorationEnabled();
+    }
+
+    public boolean isAccessibilityEnabled() {
+        return mAccessibilityEnabled;
+    }
+
+    public boolean isTouchExplorationEnabled() {
+        return mTouchExplorationEnabled;
+    }
+
+    public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
+        pw.println("AccessibilityController state:");
+        pw.print("  mAccessibilityEnabled="); pw.println(mAccessibilityEnabled);
+        pw.print("  mTouchExplorationEnabled="); pw.println(mTouchExplorationEnabled);
+    }
+
+    public void addStateChangedCallback(AccessibilityStateChangedCallback cb) {
+        mChangeCallbacks.add(cb);
+        cb.onStateChanged(mAccessibilityEnabled, mTouchExplorationEnabled);
+    }
+
+    public void removeStateChangedCallback(AccessibilityStateChangedCallback cb) {
+        mChangeCallbacks.remove(cb);
+    }
+
+    private void fireChanged() {
+        final int N = mChangeCallbacks.size();
+        for (int i = 0; i < N; i++) {
+            mChangeCallbacks.get(i).onStateChanged(mAccessibilityEnabled, mTouchExplorationEnabled);
+        }
+    }
+
+    @Override
+    public void onAccessibilityStateChanged(boolean enabled) {
+        mAccessibilityEnabled = enabled;
+        fireChanged();
+    }
+
+    @Override
+    public void onTouchExplorationStateChanged(boolean enabled) {
+        mTouchExplorationEnabled = enabled;
+        fireChanged();
+    }
+
+    public interface AccessibilityStateChangedCallback {
+        void onStateChanged(boolean accessibilityEnabled, boolean touchExplorationEnabled);
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastController.java
index eb5804a..7713e57 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastController.java
@@ -25,7 +25,7 @@
     void setCurrentUserId(int currentUserId);
     Set<CastDevice> getCastDevices();
     void startCasting(CastDevice device);
-    void stopCasting();
+    void stopCasting(CastDevice device);
 
     public interface Callback {
         void onCastDevicesChanged();
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastControllerImpl.java
index 22179e0..eb0be05 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/CastControllerImpl.java
@@ -19,15 +19,25 @@
 import static android.media.MediaRouter.ROUTE_TYPE_REMOTE_DISPLAY;
 
 import android.content.Context;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
 import android.media.MediaRouter;
 import android.media.MediaRouter.RouteInfo;
+import android.media.projection.MediaProjectionInfo;
+import android.media.projection.MediaProjectionManager;
+import android.os.Handler;
+import android.text.TextUtils;
 import android.util.ArrayMap;
 import android.util.ArraySet;
 import android.util.Log;
 
+import com.android.systemui.R;
+
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.util.ArrayList;
+import java.util.Objects;
 import java.util.Set;
 import java.util.UUID;
 
@@ -41,12 +51,19 @@
     private final MediaRouter mMediaRouter;
     private final ArrayMap<String, RouteInfo> mRoutes = new ArrayMap<>();
     private final Object mDiscoveringLock = new Object();
+    private final MediaProjectionManager mProjectionManager;
+    private final Object mProjectionLock = new Object();
 
     private boolean mDiscovering;
+    private MediaProjectionInfo mProjection;
 
     public CastControllerImpl(Context context) {
         mContext = context;
         mMediaRouter = (MediaRouter) context.getSystemService(Context.MEDIA_ROUTER_SERVICE);
+        mProjectionManager = (MediaProjectionManager)
+                context.getSystemService(Context.MEDIA_PROJECTION_SERVICE);
+        mProjection = mProjectionManager.getActiveProjectionInfo();
+        mProjectionManager.addCallback(mProjectionCallback, new Handler());
         if (DEBUG) Log.d(TAG, "new CastController()");
     }
 
@@ -59,6 +76,7 @@
             final RouteInfo route = mRoutes.valueAt(i);
             pw.print("    "); pw.println(routeToString(route));
         }
+        pw.print("  mProjection="); pw.println(mProjection);
     }
 
     @Override
@@ -95,6 +113,18 @@
     @Override
     public Set<CastDevice> getCastDevices() {
         final ArraySet<CastDevice> devices = new ArraySet<CastDevice>();
+        synchronized (mProjectionLock) {
+            if (mProjection != null) {
+                final CastDevice device = new CastDevice();
+                device.id = mProjection.getPackageName();
+                device.name = getAppName(mProjection.getPackageName());
+                device.description = mContext.getString(R.string.quick_settings_casting);
+                device.state = CastDevice.STATE_CONNECTED;
+                device.tag = mProjection;
+                devices.add(device);
+                return devices;
+            }
+        }
         synchronized(mRoutes) {
             for (RouteInfo route : mRoutes.values()) {
                 final CastDevice device = new CastDevice();
@@ -122,9 +152,55 @@
     }
 
     @Override
-    public void stopCasting() {
-        if (DEBUG) Log.d(TAG, "stopCasting");
-        mMediaRouter.getDefaultRoute().select();
+    public void stopCasting(CastDevice device) {
+        final boolean isProjection = device.tag instanceof MediaProjectionInfo;
+        if (DEBUG) Log.d(TAG, "stopCasting isProjection=" + isProjection);
+        if (isProjection) {
+            final MediaProjectionInfo projection = (MediaProjectionInfo) device.tag;
+            if (Objects.equals(mProjectionManager.getActiveProjectionInfo(), projection)) {
+                mProjectionManager.stopActiveProjection();
+            } else {
+                Log.w(TAG, "Projection is no longer active: " + projection);
+            }
+        } else {
+            mMediaRouter.getDefaultRoute().select();
+        }
+    }
+
+    private void setProjection(MediaProjectionInfo projection, boolean started) {
+        boolean changed = false;
+        final MediaProjectionInfo oldProjection = mProjection;
+        synchronized (mProjectionLock) {
+            final boolean isCurrent = Objects.equals(projection, mProjection);
+            if (started && !isCurrent) {
+                mProjection = projection;
+                changed = true;
+            } else if (!started && isCurrent) {
+                mProjection = null;
+                changed = true;
+            }
+        }
+        if (changed) {
+            if (DEBUG) Log.d(TAG, "setProjection: " + oldProjection + " -> " + mProjection);
+            fireOnCastDevicesChanged();
+        }
+    }
+
+    private String getAppName(String packageName) {
+        final PackageManager pm = mContext.getPackageManager();
+        try {
+            final ApplicationInfo appInfo = pm.getApplicationInfo(packageName, 0);
+            if (appInfo != null) {
+                final CharSequence label = appInfo.loadLabel(pm);
+                if (!TextUtils.isEmpty(label)) {
+                    return label.toString();
+                }
+            }
+            Log.w(TAG, "No label found for package: " + packageName);
+        } catch (NameNotFoundException e) {
+            Log.w(TAG, "Error getting appName for package: " + packageName, e);
+        }
+        return packageName;
     }
 
     private void updateRemoteDisplays() {
@@ -202,4 +278,17 @@
             updateRemoteDisplays();
         }
     };
+
+    private final MediaProjectionManager.Callback mProjectionCallback
+            = new MediaProjectionManager.Callback() {
+        @Override
+        public void onStart(MediaProjectionInfo info) {
+            setProjection(info, true);
+        }
+
+        @Override
+        public void onStop(MediaProjectionInfo info) {
+            setProjection(info, false);
+        }
+    };
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/FlashlightController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/FlashlightController.java
index 70eaa5c..6f021ac 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/FlashlightController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/FlashlightController.java
@@ -81,7 +81,7 @@
 
         if (mCameraId != null) {
             ensureHandler();
-            mCameraManager.addAvailabilityListener(mAvailabilityListener, mHandler);
+            mCameraManager.registerAvailabilityCallback(mAvailabilityCallback, mHandler);
         }
     }
 
@@ -339,8 +339,8 @@
         }
     };
 
-    private final CameraManager.AvailabilityListener mAvailabilityListener =
-            new CameraManager.AvailabilityListener() {
+    private final CameraManager.AvailabilityCallback mAvailabilityCallback =
+            new CameraManager.AvailabilityCallback() {
         @Override
         public void onCameraAvailable(String cameraId) {
             if (DEBUG) Log.d(TAG, "onCameraAvailable(" + cameraId + ")");
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
index 6ae076f..7f155a1d 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/HeadsUpNotificationView.java
@@ -28,6 +28,7 @@
 import android.view.ViewGroup;
 import android.view.ViewOutlineProvider;
 import android.view.ViewTreeObserver;
+import android.view.accessibility.AccessibilityEvent;
 import android.widget.FrameLayout;
 
 import com.android.systemui.ExpandHelper;
@@ -111,6 +112,7 @@
             mContentHolder.setVisibility(View.VISIBLE);
             mContentHolder.setAlpha(mMaxAlpha);
             mContentHolder.addView(mHeadsUp.row);
+            sendAccessibilityEvent(AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED);
 
             mSwipeHelper.snapChild(mContentHolder, 1f);
             mStartTouchTime = System.currentTimeMillis() + mTouchSensitivityDelay;
@@ -126,6 +128,14 @@
         return true;
     }
 
+    @Override
+    protected void onVisibilityChanged(View changedView, int visibility) {
+        super.onVisibilityChanged(changedView, visibility);
+        if (changedView.getVisibility() == VISIBLE) {
+            sendAccessibilityEvent(AccessibilityEvent.TYPE_WINDOW_CONTENT_CHANGED);
+        }
+    }
+
     public boolean isShowing(String key) {
         return mHeadsUp != null && mHeadsUp.key.equals(key);
     }
@@ -301,6 +311,11 @@
     }
 
     @Override
+    public boolean isAntiFalsingNeeded() {
+        return false;
+    }
+
+    @Override
     public void onChildDismissed(View v) {
         Log.v(TAG, "User swiped heads up to dismiss");
         mBar.onHeadsUpDismissed();
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonRipple.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonRipple.java
new file mode 100644
index 0000000..a3765aa
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonRipple.java
@@ -0,0 +1,361 @@
+/*
+ * Copyright (C) 2014 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.systemui.statusbar.policy;
+
+import android.animation.Animator;
+import android.animation.AnimatorListenerAdapter;
+import android.animation.ObjectAnimator;
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.CanvasProperty;
+import android.graphics.ColorFilter;
+import android.graphics.Paint;
+import android.graphics.PixelFormat;
+import android.graphics.drawable.Drawable;
+import android.view.HardwareCanvas;
+import android.view.RenderNodeAnimator;
+import android.view.View;
+import android.view.animation.Interpolator;
+
+import com.android.systemui.R;
+import com.android.systemui.statusbar.phone.PhoneStatusBar;
+
+import java.util.ArrayList;
+import java.util.HashSet;
+
+public class KeyButtonRipple extends Drawable {
+
+    private static final float GLOW_MAX_SCALE_FACTOR = 1.35f;
+    private static final float GLOW_MAX_ALPHA = 0.2f;
+    private static final int ANIMATION_DURATION_SCALE = 350;
+    private static final int ANIMATION_DURATION_FADE = 450;
+
+    private Paint mRipplePaint;
+    private CanvasProperty<Float> mLeftProp;
+    private CanvasProperty<Float> mTopProp;
+    private CanvasProperty<Float> mRightProp;
+    private CanvasProperty<Float> mBottomProp;
+    private CanvasProperty<Float> mRxProp;
+    private CanvasProperty<Float> mRyProp;
+    private CanvasProperty<Paint> mPaintProp;
+    private float mGlowAlpha = 0f;
+    private float mGlowScale = 1f;
+    private boolean mPressed;
+    private boolean mDrawingHardwareGlow;
+    private int mMaxWidth;
+
+    private final Interpolator mInterpolator = new LogInterpolator();
+    private final Interpolator mAlphaExitInterpolator = PhoneStatusBar.ALPHA_OUT;
+    private boolean mSupportHardware;
+    private final View mTargetView;
+
+    private final HashSet<Animator> mRunningAnimations = new HashSet<>();
+    private final ArrayList<Animator> mTmpArray = new ArrayList<>();
+
+    public KeyButtonRipple(Context ctx, View targetView) {
+        mMaxWidth =  ctx.getResources().getDimensionPixelSize(R.dimen.key_button_ripple_max_width);
+        mTargetView = targetView;
+    }
+
+    private Paint getRipplePaint() {
+        if (mRipplePaint == null) {
+            mRipplePaint = new Paint();
+            mRipplePaint.setAntiAlias(true);
+            mRipplePaint.setColor(0xffffffff);
+        }
+        return mRipplePaint;
+    }
+
+    private void drawSoftware(Canvas canvas) {
+        if (mGlowAlpha > 0f) {
+            final Paint p = getRipplePaint();
+            p.setAlpha((int)(mGlowAlpha * 255f));
+
+            final float w = getBounds().width();
+            final float h = getBounds().height();
+            final boolean horizontal = w > h;
+            final float diameter = getRippleSize() * mGlowScale;
+            final float radius = diameter * .5f;
+            final float cx = w * .5f;
+            final float cy = h * .5f;
+            final float rx = horizontal ? radius : cx;
+            final float ry = horizontal ? cy : radius;
+            final float corner = horizontal ? cy : cx;
+
+            canvas.drawRoundRect(cx - rx, cy - ry,
+                    cx + rx, cy + ry,
+                    corner, corner, p);
+        }
+    }
+
+
+    @Override
+    public void draw(Canvas canvas) {
+        mSupportHardware = canvas.isHardwareAccelerated();
+        if (mSupportHardware) {
+            drawHardware((HardwareCanvas) canvas);
+        } else {
+            drawSoftware(canvas);
+        }
+    }
+
+    @Override
+    public void setAlpha(int alpha) {
+        // Not supported.
+    }
+
+    @Override
+    public void setColorFilter(ColorFilter cf) {
+        // Not supported.
+    }
+
+    @Override
+    public int getOpacity() {
+        return PixelFormat.TRANSLUCENT;
+    }
+
+    private boolean isHorizontal() {
+        return getBounds().width() > getBounds().height();
+    }
+
+    private void drawHardware(HardwareCanvas c) {
+        if (mDrawingHardwareGlow) {
+            c.drawRoundRect(mLeftProp, mTopProp, mRightProp, mBottomProp, mRxProp, mRyProp,
+                    mPaintProp);
+        }
+    }
+
+    public float getGlowAlpha() {
+        return mGlowAlpha;
+    }
+
+    public void setGlowAlpha(float x) {
+        mGlowAlpha = x;
+        invalidateSelf();
+    }
+
+    public float getGlowScale() {
+        return mGlowScale;
+    }
+
+    public void setGlowScale(float x) {
+        mGlowScale = x;
+        invalidateSelf();
+    }
+
+    @Override
+    protected boolean onStateChange(int[] state) {
+        boolean pressed = false;
+        for (int i = 0; i < state.length; i++) {
+            if (state[i] == android.R.attr.state_pressed) {
+                pressed = true;
+                break;
+            }
+        }
+        if (pressed != mPressed) {
+            setPressed(pressed);
+            mPressed = pressed;
+            return true;
+        } else {
+            return false;
+        }
+    }
+
+    @Override
+    public boolean isStateful() {
+        return true;
+    }
+
+    public void setPressed(boolean pressed) {
+        if (mSupportHardware) {
+            setPressedHardware(pressed);
+        } else {
+            setPressedSoftware(pressed);
+        }
+    }
+
+    private void cancelAnimations() {
+        mTmpArray.addAll(mRunningAnimations);
+        int size = mTmpArray.size();
+        for (int i = 0; i < size; i++) {
+            Animator a = mTmpArray.get(i);
+            a.cancel();
+        }
+        mTmpArray.clear();
+        mRunningAnimations.clear();
+    }
+
+    private void setPressedSoftware(boolean pressed) {
+        if (pressed) {
+            enterSoftware();
+        } else {
+            exitSoftware();
+        }
+    }
+
+    private void enterSoftware() {
+        cancelAnimations();
+        mGlowAlpha = GLOW_MAX_ALPHA;
+        ObjectAnimator scaleAnimator = ObjectAnimator.ofFloat(this, "glowScale",
+                0f, GLOW_MAX_SCALE_FACTOR);
+        scaleAnimator.setInterpolator(mInterpolator);
+        scaleAnimator.setDuration(ANIMATION_DURATION_SCALE);
+        scaleAnimator.addListener(mAnimatorListener);
+        scaleAnimator.start();
+        mRunningAnimations.add(scaleAnimator);
+    }
+
+    private void exitSoftware() {
+        ObjectAnimator alphaAnimator = ObjectAnimator.ofFloat(this, "glowAlpha", mGlowAlpha, 0f);
+        alphaAnimator.setInterpolator(mAlphaExitInterpolator);
+        alphaAnimator.setDuration(ANIMATION_DURATION_FADE);
+        alphaAnimator.addListener(mAnimatorListener);
+        alphaAnimator.start();
+        mRunningAnimations.add(alphaAnimator);
+    }
+
+    private void setPressedHardware(boolean pressed) {
+        if (pressed) {
+            enterHardware();
+        } else {
+            exitHardware();
+        }
+    }
+
+    /**
+     * Sets the left/top property for the round rect to {@code prop} depending on whether we are
+     * horizontal or vertical mode.
+     */
+    private void setExtendStart(CanvasProperty<Float> prop) {
+        if (isHorizontal()) {
+            mLeftProp = prop;
+        } else {
+            mTopProp = prop;
+        }
+    }
+
+    private CanvasProperty<Float> getExtendStart() {
+        return isHorizontal() ? mLeftProp : mTopProp;
+    }
+
+    /**
+     * Sets the right/bottom property for the round rect to {@code prop} depending on whether we are
+     * horizontal or vertical mode.
+     */
+    private void setExtendEnd(CanvasProperty<Float> prop) {
+        if (isHorizontal()) {
+            mRightProp = prop;
+        } else {
+            mBottomProp = prop;
+        }
+    }
+
+    private CanvasProperty<Float> getExtendEnd() {
+        return isHorizontal() ? mRightProp : mBottomProp;
+    }
+
+    private int getExtendSize() {
+        return isHorizontal() ? getBounds().width() : getBounds().height();
+    }
+
+    private int getRippleSize() {
+        int size = isHorizontal() ? getBounds().width() : getBounds().height();
+        return Math.min(size, mMaxWidth);
+    }
+
+    private void enterHardware() {
+        cancelAnimations();
+        mDrawingHardwareGlow = true;
+        setExtendStart(CanvasProperty.createFloat(getExtendSize() / 2));
+        final RenderNodeAnimator startAnim = new RenderNodeAnimator(getExtendStart(),
+                getExtendSize()/2 - GLOW_MAX_SCALE_FACTOR * getRippleSize()/2);
+        startAnim.setDuration(ANIMATION_DURATION_SCALE);
+        startAnim.setInterpolator(mInterpolator);
+        startAnim.addListener(mAnimatorListener);
+        startAnim.setTarget(mTargetView);
+
+        setExtendEnd(CanvasProperty.createFloat(getExtendSize() / 2));
+        final RenderNodeAnimator endAnim = new RenderNodeAnimator(getExtendEnd(),
+                getExtendSize()/2 + GLOW_MAX_SCALE_FACTOR * getRippleSize()/2);
+        endAnim.setDuration(ANIMATION_DURATION_SCALE);
+        endAnim.setInterpolator(mInterpolator);
+        endAnim.addListener(mAnimatorListener);
+        endAnim.setTarget(mTargetView);
+
+        if (isHorizontal()) {
+            mTopProp = CanvasProperty.createFloat(0f);
+            mBottomProp = CanvasProperty.createFloat(getBounds().height());
+            mRxProp = CanvasProperty.createFloat(getBounds().height()/2);
+            mRyProp = CanvasProperty.createFloat(getBounds().height()/2);
+        } else {
+            mLeftProp = CanvasProperty.createFloat(0f);
+            mRightProp = CanvasProperty.createFloat(getBounds().width());
+            mRxProp = CanvasProperty.createFloat(getBounds().width()/2);
+            mRyProp = CanvasProperty.createFloat(getBounds().width()/2);
+        }
+
+        mGlowScale = GLOW_MAX_SCALE_FACTOR;
+        mGlowAlpha = GLOW_MAX_ALPHA;
+        mRipplePaint = getRipplePaint();
+        mRipplePaint.setAlpha((int) (mGlowAlpha * 255));
+        mPaintProp = CanvasProperty.createPaint(mRipplePaint);
+
+        startAnim.start();
+        endAnim.start();
+        mRunningAnimations.add(startAnim);
+        mRunningAnimations.add(endAnim);
+
+        invalidateSelf();
+    }
+
+    private void exitHardware() {
+        mPaintProp = CanvasProperty.createPaint(getRipplePaint());
+        final RenderNodeAnimator opacityAnim = new RenderNodeAnimator(mPaintProp,
+                RenderNodeAnimator.PAINT_ALPHA, 0);
+        opacityAnim.setDuration(ANIMATION_DURATION_FADE);
+        opacityAnim.setInterpolator(mAlphaExitInterpolator);
+        opacityAnim.addListener(mAnimatorListener);
+        opacityAnim.setTarget(mTargetView);
+
+        opacityAnim.start();
+        mRunningAnimations.add(opacityAnim);
+
+        invalidateSelf();
+    }
+
+    private final AnimatorListenerAdapter mAnimatorListener =
+            new AnimatorListenerAdapter() {
+        @Override
+        public void onAnimationEnd(Animator animation) {
+            mRunningAnimations.remove(animation);
+            if (mRunningAnimations.isEmpty() && !mPressed) {
+                mDrawingHardwareGlow = false;
+                invalidateSelf();
+            }
+        }
+    };
+
+    /**
+     * Interpolator with a smooth log deceleration
+     */
+    private static final class LogInterpolator implements Interpolator {
+        @Override
+        public float getInterpolation(float input) {
+            return 1 - (float) Math.pow(400, -input * 1.4);
+        }
+    }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java
index e9581fc..7cc75da 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java
@@ -17,31 +17,50 @@
 package com.android.systemui.statusbar.policy;
 
 import android.animation.Animator;
+import android.animation.AnimatorSet;
 import android.animation.ObjectAnimator;
+import android.animation.TimeInterpolator;
+import android.app.ActivityManager;
 import android.content.Context;
 import android.content.res.TypedArray;
-import android.graphics.drawable.Drawable;
+import android.graphics.Canvas;
+import android.graphics.CanvasProperty;
+import android.graphics.Paint;
+import android.graphics.RectF;
 import android.hardware.input.InputManager;
+import android.media.AudioManager;
+import android.os.Bundle;
 import android.os.SystemClock;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.util.MathUtils;
 import android.view.HapticFeedbackConstants;
+import android.view.HardwareCanvas;
 import android.view.InputDevice;
 import android.view.KeyCharacterMap;
 import android.view.KeyEvent;
 import android.view.MotionEvent;
+import android.view.RenderNodeAnimator;
 import android.view.SoundEffectConstants;
+import android.view.View;
 import android.view.ViewConfiguration;
 import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityNodeInfo;
 import android.widget.ImageView;
+import java.lang.Math;
+import java.util.ArrayList;
 
 import com.android.systemui.R;
 
+import static android.view.accessibility.AccessibilityNodeInfo.ACTION_CLICK;
+import static android.view.accessibility.AccessibilityNodeInfo.ACTION_LONG_CLICK;
+
 public class KeyButtonView extends ImageView {
     private static final String TAG = "StatusBar.KeyButtonView";
     private static final boolean DEBUG = false;
 
-    public static final float DEFAULT_QUIESCENT_ALPHA = 0.70f;
+    // TODO: Get rid of this
+    public static final float DEFAULT_QUIESCENT_ALPHA = 1f;
 
     private long mDownTime;
     private int mCode;
@@ -49,8 +68,8 @@
     private float mDrawingAlpha = 1f;
     private float mQuiescentAlpha = DEFAULT_QUIESCENT_ALPHA;
     private boolean mSupportsLongpress = true;
+    private AudioManager mAudioManager;
     private Animator mAnimateToQuiescent = new ObjectAnimator();
-    private Drawable mBackground;
 
     private final Runnable mCheckLongPress = new Runnable() {
         public void run() {
@@ -81,11 +100,6 @@
 
         mSupportsLongpress = a.getBoolean(R.styleable.KeyButtonView_keyRepeat, true);
 
-        Drawable d = getBackground();
-        if (d != null) {
-            mBackground = d.mutate();
-            setBackground(mBackground);
-        }
 
         setDrawingAlpha(mQuiescentAlpha);
 
@@ -93,6 +107,37 @@
 
         setClickable(true);
         mTouchSlop = ViewConfiguration.get(context).getScaledTouchSlop();
+        mAudioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
+        setBackground(new KeyButtonRipple(context, this));
+    }
+
+    @Override
+    public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {
+        super.onInitializeAccessibilityNodeInfo(info);
+        if (mCode != 0) {
+            info.addAction(new AccessibilityNodeInfo.AccessibilityAction(ACTION_CLICK, null));
+            if (mSupportsLongpress) {
+                info.addAction(
+                        new AccessibilityNodeInfo.AccessibilityAction(ACTION_LONG_CLICK, null));
+            }
+        }
+    }
+
+    @Override
+    public boolean performAccessibilityAction(int action, Bundle arguments) {
+        if (action == ACTION_CLICK && mCode != 0) {
+            sendEvent(KeyEvent.ACTION_DOWN, 0, SystemClock.uptimeMillis());
+            sendEvent(KeyEvent.ACTION_UP, 0);
+            sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_CLICKED);
+            playSoundEffect(SoundEffectConstants.CLICK);
+            return true;
+        } else if (action == ACTION_LONG_CLICK && mCode != 0 && mSupportsLongpress) {
+            sendEvent(KeyEvent.ACTION_DOWN, KeyEvent.FLAG_LONG_PRESS);
+            sendEvent(KeyEvent.ACTION_UP, 0);
+            sendAccessibilityEvent(AccessibilityEvent.TYPE_VIEW_LONG_CLICKED);
+            return true;
+        }
+        return super.performAccessibilityAction(action, arguments);
     }
 
     public void setQuiescentAlpha(float alpha, boolean animate) {
@@ -101,7 +146,7 @@
         if (alpha == mQuiescentAlpha && alpha == mDrawingAlpha) return;
         mQuiescentAlpha = alpha;
         if (DEBUG) Log.d(TAG, "New quiescent alpha = " + mQuiescentAlpha);
-        if (mBackground != null && animate) {
+        if (animate) {
             mAnimateToQuiescent = animateToQuiescent();
             mAnimateToQuiescent.start();
         } else {
@@ -123,34 +168,9 @@
 
     public void setDrawingAlpha(float x) {
         setImageAlpha((int) (x * 255));
-        if (mBackground != null) {
-            mBackground.setAlpha((int)(x * 255));
-        }
         mDrawingAlpha = x;
     }
 
-    public void setPressed(boolean pressed) {
-        if (mBackground != null) {
-            if (pressed != isPressed()) {
-                if (pressed) {
-                    setDrawingAlpha(1f);
-                } else {
-                    mAnimateToQuiescent.cancel();
-                    mAnimateToQuiescent = animateToQuiescent();
-                    mAnimateToQuiescent.setDuration(500);
-                    mAnimateToQuiescent.start();
-                }
-            }
-        }
-        super.setPressed(pressed);
-    }
-
-    private void setHotspot(float x, float y) {
-        if (mBackground != null) {
-            mBackground.setHotspot(x, y);
-        }
-    }
-
     public boolean onTouchEvent(MotionEvent ev) {
         final int action = ev.getAction();
         int x, y;
@@ -170,7 +190,6 @@
                     removeCallbacks(mCheckLongPress);
                     postDelayed(mCheckLongPress, ViewConfiguration.getLongPressTimeout());
                 }
-                setHotspot(ev.getX(), ev.getY());
                 break;
             case MotionEvent.ACTION_MOVE:
                 x = (int)ev.getX();
@@ -179,7 +198,6 @@
                         && x < getWidth() + mTouchSlop
                         && y >= -mTouchSlop
                         && y < getHeight() + mTouchSlop);
-                setHotspot(ev.getX(), ev.getY());
                 break;
             case MotionEvent.ACTION_CANCEL:
                 setPressed(false);
@@ -216,6 +234,10 @@
         return true;
     }
 
+    public void playSoundEffect(int soundConstant) {
+        mAudioManager.playSoundEffect(soundConstant, ActivityManager.getCurrentUser());
+    };
+
     public void sendEvent(int action, int flags) {
         sendEvent(action, flags, SystemClock.uptimeMillis());
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/LocationControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/LocationControllerImpl.java
index d5b2548..61ed095 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/LocationControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/LocationControllerImpl.java
@@ -42,8 +42,7 @@
     // The name of the placeholder corresponding to the location request status icon.
     // This string corresponds to config_statusBarIcons in core/res/res/values/config.xml.
     public static final String LOCATION_STATUS_ICON_PLACEHOLDER = "location";
-    public static final int LOCATION_STATUS_ICON_ID
-        = R.drawable.stat_sys_device_access_location_found;
+    public static final int LOCATION_STATUS_ICON_ID = R.drawable.stat_sys_location;
 
     private static final int[] mHighPowerRequestAppOpArray
         = new int[] {AppOpsManager.OP_MONITOR_HIGH_POWER_LOCATION};
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkController.java
index b64dcbe..2ed9366 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkController.java
@@ -30,7 +30,8 @@
         void onMobileDataSignalChanged(boolean enabled, int mobileSignalIconId,
                 String mobileSignalContentDescriptionId, int dataTypeIconId,
                 boolean activityIn, boolean activityOut,
-                String dataTypeContentDescriptionId, String description, boolean noSim);
+                String dataTypeContentDescriptionId, String description, boolean noSim,
+                boolean isDataTypeIconWide);
         void onAirplaneModeChanged(boolean enabled);
         void onMobileDataEnabled(boolean enabled);
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java
index 4e9f37d..79d769a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/NetworkControllerImpl.java
@@ -63,8 +63,6 @@
     static final boolean DEBUG = false;
     static final boolean CHATTY = false; // additional diagnostics, but not logspew
 
-    private static final int FLIGHT_MODE_ICON = R.drawable.stat_sys_signal_flightmode;
-
     // telephony
     boolean mHspaDataDistinguishable;
     final TelephonyManager mPhone;
@@ -130,6 +128,8 @@
     private boolean mConnected = false;
     private int mConnectedNetworkType = ConnectivityManager.TYPE_NONE;
     private String mConnectedNetworkTypeName;
+    private int mLastConnectedNetworkType = ConnectivityManager.TYPE_NONE;
+
     private int mInetCondition = 0;
     private int mLastInetCondition = 0;
     private static final int INET_CONDITION_THRESHOLD = 50;
@@ -164,7 +164,8 @@
     public interface SignalCluster {
         void setWifiIndicators(boolean visible, int strengthIcon, String contentDescription);
         void setMobileDataIndicators(boolean visible, int strengthIcon, int typeIcon,
-                String contentDescription, String typeContentDescription);
+                String contentDescription, String typeContentDescription, boolean roaming,
+                boolean isTypeIconWide);
         void setIsAirplaneMode(boolean is, int airplaneIcon);
     }
 
@@ -222,7 +223,7 @@
         filter.addAction(WifiManager.NETWORK_STATE_CHANGED_ACTION);
         filter.addAction(TelephonyIntents.ACTION_SIM_STATE_CHANGED);
         filter.addAction(TelephonyIntents.SPN_STRINGS_UPDATED_ACTION);
-        filter.addAction(ConnectivityManager.CONNECTIVITY_ACTION);
+        filter.addAction(ConnectivityManager.CONNECTIVITY_ACTION_IMMEDIATE);
         filter.addAction(ConnectivityManager.INET_CONDITION_ACTION);
         filter.addAction(Intent.ACTION_CONFIGURATION_CHANGED);
         filter.addAction(Intent.ACTION_AIRPLANE_MODE_CHANGED);
@@ -338,7 +339,9 @@
     @Override
     public DataUsageInfo getDataUsageInfo() {
         final DataUsageInfo info =  mMobileDataController.getDataUsageInfo();
-        info.carrier = mNetworkName;
+        if (info != null) {
+            info.carrier = mNetworkName;
+        }
         return info;
     }
 
@@ -357,6 +360,16 @@
         mMobileDataController.setMobileDataEnabled(enabled);
     }
 
+    private boolean isTypeIconWide(int iconId) {
+        return TelephonyIcons.ICON_LTE == iconId || TelephonyIcons.ICON_1X == iconId
+                || TelephonyIcons.ICON_3G == iconId || TelephonyIcons.ICON_4G == iconId;
+    }
+
+    private boolean isQsTypeIconWide(int iconId) {
+        return TelephonyIcons.QS_ICON_LTE == iconId || TelephonyIcons.QS_ICON_1X == iconId
+                || TelephonyIcons.QS_ICON_3G == iconId || TelephonyIcons.QS_ICON_4G == iconId;
+    }
+
     public void refreshSignalCluster(SignalCluster cluster) {
         if (mDemoMode) return;
         cluster.setWifiIndicators(
@@ -372,7 +385,9 @@
                     mAlwaysShowCdmaRssi ? mPhoneSignalIconId : mWimaxIconId,
                     mDataTypeIconId,
                     mContentDescriptionWimax,
-                    mContentDescriptionDataType);
+                    mContentDescriptionDataType,
+                    mDataTypeIconId == TelephonyIcons.ROAMING_ICON,
+                    false /* isTypeIconWide */ );
         } else {
             // normal mobile data
             cluster.setMobileDataIndicators(
@@ -380,7 +395,9 @@
                     mShowPhoneRSSIForData ? mPhoneSignalIconId : mDataSignalIconId,
                     mDataTypeIconId,
                     mContentDescriptionPhoneSignal,
-                    mContentDescriptionDataType);
+                    mContentDescriptionDataType,
+                    mDataTypeIconId == TelephonyIcons.ROAMING_ICON,
+                    isTypeIconWide(mDataTypeIconId));
         }
         cluster.setIsAirplaneMode(mAirplaneMode, mAirplaneIconId);
     }
@@ -406,18 +423,20 @@
         if (isEmergencyOnly()) {
             cb.onMobileDataSignalChanged(false, mQSPhoneSignalIconId,
                     mContentDescriptionPhoneSignal, mQSDataTypeIconId, mobileIn, mobileOut,
-                    mContentDescriptionDataType, null, mNoSim);
+                    mContentDescriptionDataType, null, mNoSim, isQsTypeIconWide(mQSDataTypeIconId));
         } else {
             if (mIsWimaxEnabled && mWimaxConnected) {
                 // Wimax is special
                 cb.onMobileDataSignalChanged(true, mQSPhoneSignalIconId,
                         mContentDescriptionPhoneSignal, mQSDataTypeIconId, mobileIn, mobileOut,
-                        mContentDescriptionDataType, mNetworkName, mNoSim);
+                        mContentDescriptionDataType, mNetworkName, mNoSim,
+                        isQsTypeIconWide(mQSDataTypeIconId));
             } else {
                 // Normal mobile data
                 cb.onMobileDataSignalChanged(mHasMobileDataFeature, mQSPhoneSignalIconId,
                         mContentDescriptionPhoneSignal, mQSDataTypeIconId, mobileIn, mobileOut,
-                        mContentDescriptionDataType, mNetworkName, mNoSim);
+                        mContentDescriptionDataType, mNetworkName, mNoSim,
+                        isQsTypeIconWide(mQSDataTypeIconId));
             }
         }
         cb.onAirplaneModeChanged(mAirplaneMode);
@@ -445,7 +464,7 @@
                         intent.getBooleanExtra(TelephonyIntents.EXTRA_SHOW_PLMN, false),
                         intent.getStringExtra(TelephonyIntents.EXTRA_PLMN));
             refreshViews();
-        } else if (action.equals(ConnectivityManager.CONNECTIVITY_ACTION) ||
+        } else if (action.equals(ConnectivityManager.CONNECTIVITY_ACTION_IMMEDIATE) ||
                  action.equals(ConnectivityManager.INET_CONDITION_ACTION)) {
             updateConnectivity(intent);
             refreshViews();
@@ -602,6 +621,8 @@
             mPhoneSignalIconId = R.drawable.stat_sys_signal_null;
             mQSPhoneSignalIconId = R.drawable.ic_qs_signal_no_signal;
             mDataSignalIconId = R.drawable.stat_sys_signal_null;
+            mContentDescriptionPhoneSignal = mContext.getString(
+                    AccessibilityContentDescriptions.PHONE_SIGNAL_STRENGTH[0]);
         } else {
             if (mSignalStrength == null) {
                 if (CHATTY) Log.d(TAG, "updateTelephonySignalStrength: mSignalStrength == null");
@@ -650,32 +671,39 @@
         }
     }
 
+    private int inetConditionForNetwork(int networkType) {
+        return (mInetCondition == 1 && mConnectedNetworkType == networkType) ? 1 : 0;
+    }
+
     private final void updateDataNetType() {
+        int inetCondition;
+        mDataTypeIconId = mQSDataTypeIconId = 0;
         if (mIsWimaxEnabled && mWimaxConnected) {
             // wimax is a special 4g network not handled by telephony
-            mDataIconList = TelephonyIcons.DATA_4G[mInetCondition];
+            inetCondition = inetConditionForNetwork(ConnectivityManager.TYPE_WIMAX);
+            mDataIconList = TelephonyIcons.DATA_4G[inetCondition];
             mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_4g;
-            mQSDataTypeIconId = TelephonyIcons.QS_DATA_4G[mInetCondition];
+            mQSDataTypeIconId = TelephonyIcons.QS_DATA_4G[inetCondition];
             mContentDescriptionDataType = mContext.getString(
                     R.string.accessibility_data_connection_4g);
         } else {
+            inetCondition = inetConditionForNetwork(ConnectivityManager.TYPE_MOBILE);
+            final boolean showDataTypeIcon = (inetCondition > 0);
             switch (mDataNetType) {
                 case TelephonyManager.NETWORK_TYPE_UNKNOWN:
                     if (!mShowAtLeastThreeGees) {
-                        mDataIconList = TelephonyIcons.DATA_G[mInetCondition];
-                        mDataTypeIconId = 0;
-                        mQSDataTypeIconId = 0;
-                        mContentDescriptionDataType = mContext.getString(
-                                R.string.accessibility_data_connection_gprs);
+                        mDataIconList = TelephonyIcons.DATA_G[inetCondition];
+                        mContentDescriptionDataType = "";
                         break;
                     } else {
                         // fall through
                     }
                 case TelephonyManager.NETWORK_TYPE_EDGE:
                     if (!mShowAtLeastThreeGees) {
-                        mDataIconList = TelephonyIcons.DATA_E[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_e;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_E[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_E[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_e : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_E[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_edge);
                         break;
@@ -683,9 +711,10 @@
                         // fall through
                     }
                 case TelephonyManager.NETWORK_TYPE_UMTS:
-                    mDataIconList = TelephonyIcons.DATA_3G[mInetCondition];
-                    mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_3g;
-                    mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[mInetCondition];
+                    mDataIconList = TelephonyIcons.DATA_3G[inetCondition];
+                    mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_3g : 0;
+                    mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[inetCondition];
                     mContentDescriptionDataType = mContext.getString(
                             R.string.accessibility_data_connection_3g);
                     break;
@@ -694,15 +723,17 @@
                 case TelephonyManager.NETWORK_TYPE_HSPA:
                 case TelephonyManager.NETWORK_TYPE_HSPAP:
                     if (mHspaDataDistinguishable) {
-                        mDataIconList = TelephonyIcons.DATA_H[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_h;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_H[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_H[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_h : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_H[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_3_5g);
                     } else {
-                        mDataIconList = TelephonyIcons.DATA_3G[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_3g;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_3G[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_3g : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_3g);
                     }
@@ -710,9 +741,10 @@
                 case TelephonyManager.NETWORK_TYPE_CDMA:
                     if (!mShowAtLeastThreeGees) {
                         // display 1xRTT for IS95A/B
-                        mDataIconList = TelephonyIcons.DATA_1X[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_1x;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_1X[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_1X[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_1x : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_1X[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_cdma);
                         break;
@@ -721,9 +753,10 @@
                     }
                 case TelephonyManager.NETWORK_TYPE_1xRTT:
                     if (!mShowAtLeastThreeGees) {
-                        mDataIconList = TelephonyIcons.DATA_1X[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_1x;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_1X[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_1X[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_1x : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_1X[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_cdma);
                         break;
@@ -734,39 +767,43 @@
                 case TelephonyManager.NETWORK_TYPE_EVDO_A:
                 case TelephonyManager.NETWORK_TYPE_EVDO_B:
                 case TelephonyManager.NETWORK_TYPE_EHRPD:
-                    mDataIconList = TelephonyIcons.DATA_3G[mInetCondition];
-                    mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_3g;
-                    mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[mInetCondition];
+                    mDataIconList = TelephonyIcons.DATA_3G[inetCondition];
+                    mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_3g : 0;
+                    mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[inetCondition];
                     mContentDescriptionDataType = mContext.getString(
                             R.string.accessibility_data_connection_3g);
                     break;
                 case TelephonyManager.NETWORK_TYPE_LTE:
                     boolean show4GforLTE = mContext.getResources().getBoolean(R.bool.config_show4GForLTE);
                     if (show4GforLTE) {
-                        mDataIconList = TelephonyIcons.DATA_4G[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_4g;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_4G[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_4G[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_4g : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_4G[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_4g);
                     } else {
-                        mDataIconList = TelephonyIcons.DATA_LTE[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_lte;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_LTE[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_LTE[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ? TelephonyIcons.ICON_LTE : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_LTE[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_lte);
                     }
                     break;
                 default:
                     if (!mShowAtLeastThreeGees) {
-                        mDataIconList = TelephonyIcons.DATA_G[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_g;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_G[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_G[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_g : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_G[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_gprs);
                     } else {
-                        mDataIconList = TelephonyIcons.DATA_3G[mInetCondition];
-                        mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_3g;
-                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[mInetCondition];
+                        mDataIconList = TelephonyIcons.DATA_3G[inetCondition];
+                        mDataTypeIconId = showDataTypeIcon ?
+                                R.drawable.stat_sys_data_fully_connected_3g : 0;
+                        mQSDataTypeIconId = TelephonyIcons.QS_DATA_3G[inetCondition];
                         mContentDescriptionDataType = mContext.getString(
                                 R.string.accessibility_data_connection_3g);
                     }
@@ -776,11 +813,11 @@
 
         if (isCdma()) {
             if (isCdmaEri()) {
-                mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_roam;
+                mDataTypeIconId = TelephonyIcons.ROAMING_ICON;
                 mQSDataTypeIconId = TelephonyIcons.QS_DATA_R[mInetCondition];
             }
         } else if (mPhone.isNetworkRoaming()) {
-                mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_roam;
+                mDataTypeIconId = TelephonyIcons.ROAMING_ICON;
                 mQSDataTypeIconId = TelephonyIcons.QS_DATA_R[mInetCondition];
         }
     }
@@ -829,7 +866,7 @@
                     visible = false;
                 }
             } else {
-                iconId = R.drawable.stat_sys_no_sim;
+                iconId = 0;
                 mNoSim = true;
                 visible = false; // no SIM? no data
             }
@@ -924,8 +961,8 @@
                     intent.getParcelableExtra(WifiManager.EXTRA_NETWORK_INFO);
             boolean wasConnected = mWifiConnected;
             mWifiConnected = networkInfo != null && networkInfo.isConnected();
-            // If we just connected, grab the inintial signal strength and ssid
-            if (mWifiConnected && !wasConnected) {
+            // If Connected grab the signal strength and ssid
+            if (mWifiConnected) {
                 // try getting it out of the intent first
                 WifiInfo info = (WifiInfo) intent.getParcelableExtra(WifiManager.EXTRA_WIFI_INFO);
                 if (info == null) {
@@ -949,9 +986,10 @@
     }
 
     private void updateWifiIcons() {
+        int inetCondition = inetConditionForNetwork(ConnectivityManager.TYPE_WIFI);
         if (mWifiConnected) {
-            mWifiIconId = WifiIcons.WIFI_SIGNAL_STRENGTH[mInetCondition][mWifiLevel];
-            mQSWifiIconId = WifiIcons.QS_WIFI_SIGNAL_STRENGTH[mInetCondition][mWifiLevel];
+            mWifiIconId = WifiIcons.WIFI_SIGNAL_STRENGTH[inetCondition][mWifiLevel];
+            mQSWifiIconId = WifiIcons.QS_WIFI_SIGNAL_STRENGTH[inetCondition][mWifiLevel];
             mContentDescriptionWifi = mContext.getString(
                     AccessibilityContentDescriptions.WIFI_CONNECTION_STRENGTH[mWifiLevel]);
         } else {
@@ -1010,10 +1048,11 @@
     private void updateWimaxIcons() {
         if (mIsWimaxEnabled) {
             if (mWimaxConnected) {
+                int inetCondition = inetConditionForNetwork(ConnectivityManager.TYPE_WIMAX);
                 if (mWimaxIdle)
                     mWimaxIconId = WimaxIcons.WIMAX_IDLE;
                 else
-                    mWimaxIconId = WimaxIcons.WIMAX_SIGNAL_STRENGTH[mInetCondition][mWimaxSignal];
+                    mWimaxIconId = WimaxIcons.WIMAX_SIGNAL_STRENGTH[inetCondition][mWimaxSignal];
                 mContentDescriptionWimax = mContext.getString(
                         AccessibilityContentDescriptions.WIMAX_CONNECTION_STRENGTH[mWimaxSignal]);
             } else {
@@ -1160,7 +1199,7 @@
             // look again; your radios are now airplanes
             mContentDescriptionPhoneSignal = mContext.getString(
                     R.string.accessibility_airplane_mode);
-            mAirplaneIconId = FLIGHT_MODE_ICON;
+            mAirplaneIconId = TelephonyIcons.FLIGHT_MODE_ICON;
             mPhoneSignalIconId = mDataSignalIconId = mDataTypeIconId = mQSDataTypeIconId = 0;
             mQSPhoneSignalIconId = 0;
 
@@ -1190,15 +1229,17 @@
             mContentDescriptionCombinedSignal = mHasMobileDataFeature
                 ? mContentDescriptionDataType : mContentDescriptionWifi;
 
+            int inetCondition = inetConditionForNetwork(ConnectivityManager.TYPE_MOBILE);
+
             mDataTypeIconId = 0;
             mQSDataTypeIconId = 0;
             if (isCdma()) {
                 if (isCdmaEri()) {
-                    mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_roam;
+                    mDataTypeIconId = TelephonyIcons.ROAMING_ICON;
                     mQSDataTypeIconId = TelephonyIcons.QS_DATA_R[mInetCondition];
                 }
             } else if (mPhone.isNetworkRoaming()) {
-                mDataTypeIconId = R.drawable.stat_sys_data_fully_connected_roam;
+                mDataTypeIconId = TelephonyIcons.ROAMING_ICON;
                 mQSDataTypeIconId = TelephonyIcons.QS_DATA_R[mInetCondition];
             }
         }
@@ -1248,7 +1289,8 @@
          || mLastWimaxIconId                != mWimaxIconId
          || mLastDataTypeIconId             != mDataTypeIconId
          || mLastAirplaneMode               != mAirplaneMode
-         || mLastLocale                     != mLocale)
+         || mLastLocale                     != mLocale
+         || mLastConnectedNetworkType       != mConnectedNetworkType)
         {
             // NB: the mLast*s will be updated later
             for (SignalCluster cluster : mSignalClusters) {
@@ -1283,6 +1325,10 @@
             mLastInetCondition = mInetCondition;
         }
 
+        if (mLastConnectedNetworkType != mConnectedNetworkType) {
+            mLastConnectedNetworkType = mConnectedNetworkType;
+        }
+
         // the wimax icon on phones
         if (mLastWimaxIconId != mWimaxIconId) {
             mLastWimaxIconId = mWimaxIconId;
@@ -1505,7 +1551,7 @@
             if (airplane != null) {
                 boolean show = airplane.equals("show");
                 for (SignalCluster cluster : mSignalClusters) {
-                    cluster.setIsAirplaneMode(show, FLIGHT_MODE_ICON);
+                    cluster.setIsAirplaneMode(show, TelephonyIcons.FLIGHT_MODE_ICON);
                 }
             }
             String fully = args.getString("fully");
@@ -1536,24 +1582,23 @@
                 String datatype = args.getString("datatype");
                 if (datatype != null) {
                     mDemoDataTypeIconId =
-                            datatype.equals("1x") ? R.drawable.stat_sys_data_fully_connected_1x :
-                            datatype.equals("3g") ? R.drawable.stat_sys_data_fully_connected_3g :
-                            datatype.equals("4g") ? R.drawable.stat_sys_data_fully_connected_4g :
+                            datatype.equals("1x") ? TelephonyIcons.ICON_1X :
+                            datatype.equals("3g") ? TelephonyIcons.ICON_3G :
+                            datatype.equals("4g") ? TelephonyIcons.ICON_4G :
                             datatype.equals("e") ? R.drawable.stat_sys_data_fully_connected_e :
                             datatype.equals("g") ? R.drawable.stat_sys_data_fully_connected_g :
                             datatype.equals("h") ? R.drawable.stat_sys_data_fully_connected_h :
-                            datatype.equals("lte") ? R.drawable.stat_sys_data_fully_connected_lte :
-                            datatype.equals("roam")
-                                    ? R.drawable.stat_sys_data_fully_connected_roam :
+                            datatype.equals("lte") ? TelephonyIcons.ICON_LTE :
+                            datatype.equals("roam") ? TelephonyIcons.ROAMING_ICON :
                             0;
                     mDemoQSDataTypeIconId =
-                            datatype.equals("1x") ? R.drawable.ic_qs_signal_1x :
-                            datatype.equals("3g") ? R.drawable.ic_qs_signal_3g :
-                            datatype.equals("4g") ? R.drawable.ic_qs_signal_4g :
+                            datatype.equals("1x") ? TelephonyIcons.QS_ICON_1X :
+                            datatype.equals("3g") ? TelephonyIcons.QS_ICON_3G :
+                            datatype.equals("4g") ? TelephonyIcons.QS_ICON_4G :
                             datatype.equals("e") ? R.drawable.ic_qs_signal_e :
                             datatype.equals("g") ? R.drawable.ic_qs_signal_g :
                             datatype.equals("h") ? R.drawable.ic_qs_signal_h :
-                            datatype.equals("lte") ? R.drawable.ic_qs_signal_lte :
+                            datatype.equals("lte") ? TelephonyIcons.QS_ICON_LTE :
                             datatype.equals("roam") ? R.drawable.ic_qs_signal_r :
                             0;
                 }
@@ -1571,7 +1616,9 @@
                             iconId,
                             mDemoDataTypeIconId,
                             "Demo",
-                            "Demo");
+                            "Demo",
+                            mDemoDataTypeIconId == TelephonyIcons.ROAMING_ICON,
+                            isTypeIconWide(mDemoDataTypeIconId));
                 }
                 refreshViews();
             }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/PreviewInflater.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/PreviewInflater.java
index cdbe494..030cd6d 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/PreviewInflater.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/PreviewInflater.java
@@ -20,14 +20,12 @@
 import android.content.Intent;
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
-import android.content.pm.UserInfo;
 import android.os.UserHandle;
 import android.util.Log;
 import android.view.LayoutInflater;
 import android.view.View;
 
 import com.android.internal.widget.LockPatternUtils;
-import com.android.keyguard.KeyguardActivityLauncher;
 import com.android.systemui.statusbar.phone.KeyguardPreviewContainer;
 
 import java.util.List;
@@ -107,20 +105,21 @@
         return info;
     }
 
-    public boolean wouldLaunchResolverActivity(Intent intent) {
-        PackageManager packageManager = mContext.getPackageManager();
+    public static boolean wouldLaunchResolverActivity(Context ctx, Intent intent,
+            int currentUserId) {
+        PackageManager packageManager = ctx.getPackageManager();
         final List<ResolveInfo> appList = packageManager.queryIntentActivitiesAsUser(
-                intent, PackageManager.MATCH_DEFAULT_ONLY, mLockPatternUtils.getCurrentUser());
+                intent, PackageManager.MATCH_DEFAULT_ONLY, currentUserId);
         if (appList.size() == 0) {
             return false;
         }
         ResolveInfo resolved = packageManager.resolveActivityAsUser(intent,
-                PackageManager.MATCH_DEFAULT_ONLY | PackageManager.GET_META_DATA,
-                mLockPatternUtils.getCurrentUser());
+                PackageManager.MATCH_DEFAULT_ONLY | PackageManager.GET_META_DATA, currentUserId);
         return wouldLaunchResolverActivity(resolved, appList);
     }
 
-    private boolean wouldLaunchResolverActivity(ResolveInfo resolved, List<ResolveInfo> appList) {
+    private static boolean wouldLaunchResolverActivity(
+            ResolveInfo resolved, List<ResolveInfo> appList) {
         // If the list contains the above resolved activity, then it can't be
         // ResolverActivity itself.
         for (int i = 0; i < appList.size(); i++) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityController.java
index ede8129..6148feb 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityController.java
@@ -18,19 +18,21 @@
 public interface SecurityController {
 
     boolean hasDeviceOwner();
+    boolean hasProfileOwner();
     String getDeviceOwnerName();
+    String getProfileOwnerName();
     boolean isVpnEnabled();
     String getVpnApp();
     boolean isLegacyVpn();
     String getLegacyVpnName();
-    void openVpnApp();
-    void disconnectFromLegacyVpn();
+    void disconnectFromVpn();
+    void onUserSwitched(int newUserId);
 
-    void addCallback(VpnCallback callback);
-    void removeCallback(VpnCallback callback);
+    void addCallback(SecurityControllerCallback callback);
+    void removeCallback(SecurityControllerCallback callback);
 
-    public interface VpnCallback {
-        void onVpnStateChanged();
+    public interface SecurityControllerCallback {
+        void onStateChanged();
     }
 
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityControllerImpl.java
index 8e04e5e..2fbb812 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/SecurityControllerImpl.java
@@ -15,14 +15,14 @@
  */
 package com.android.systemui.statusbar.policy;
 
+import android.app.ActivityManager;
 import android.app.admin.DevicePolicyManager;
 import android.content.Context;
-import android.content.Intent;
-import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.net.ConnectivityManager;
 import android.net.ConnectivityManager.NetworkCallback;
 import android.net.IConnectivityManager;
+import android.net.Network;
 import android.net.NetworkCapabilities;
 import android.net.NetworkRequest;
 import android.os.RemoteException;
@@ -46,16 +46,20 @@
             .removeCapability(NetworkCapabilities.NET_CAPABILITY_NOT_RESTRICTED)
             .removeCapability(NetworkCapabilities.NET_CAPABILITY_TRUSTED)
             .build();
+    private static final int NO_NETWORK = -1;
+
     private final Context mContext;
     private final ConnectivityManager mConnectivityManager;
     private final IConnectivityManager mConnectivityService = IConnectivityManager.Stub.asInterface(
                 ServiceManager.getService(Context.CONNECTIVITY_SERVICE));
     private final DevicePolicyManager mDevicePolicyManager;
-    private final ArrayList<VpnCallback> mCallbacks = new ArrayList<VpnCallback>();
+    private final ArrayList<SecurityControllerCallback> mCallbacks
+            = new ArrayList<SecurityControllerCallback>();
 
-    private boolean mIsVpnEnabled;
     private VpnConfig mVpnConfig;
     private String mVpnName;
+    private int mCurrentVpnNetworkId = NO_NETWORK;
+    private int mCurrentUserId;
 
     public SecurityControllerImpl(Context context) {
         mContext = context;
@@ -66,11 +70,12 @@
 
         // TODO: re-register network callback on user change.
         mConnectivityManager.registerNetworkCallback(REQUEST, mNetworkCallback);
+        mCurrentUserId = ActivityManager.getCurrentUser();
     }
 
     public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
         pw.println("SecurityController state:");
-        pw.print("  mIsVpnEnabled="); pw.println(mIsVpnEnabled);
+        pw.print("  mCurrentVpnNetworkId="); pw.println(mCurrentVpnNetworkId);
         pw.print("  mVpnConfig="); pw.println(mVpnConfig);
         pw.print("  mVpnName="); pw.println(mVpnName);
     }
@@ -81,16 +86,24 @@
     }
 
     @Override
+    public boolean hasProfileOwner() {
+        return !TextUtils.isEmpty(mDevicePolicyManager.getProfileOwnerNameAsUser(mCurrentUserId));
+    }
+
+    @Override
     public String getDeviceOwnerName() {
         return mDevicePolicyManager.getDeviceOwnerName();
     }
 
     @Override
-    public boolean isVpnEnabled() {
-        // TODO: Remove once using NetworkCallback for updates.
-        updateState();
+    public String getProfileOwnerName() {
+        return mDevicePolicyManager.getProfileOwnerNameAsUser(mCurrentUserId);
+    }
 
-        return mIsVpnEnabled;
+
+    @Override
+    public boolean isVpnEnabled() {
+        return mCurrentVpnNetworkId != NO_NETWORK;
     }
 
     @Override
@@ -109,40 +122,53 @@
     }
 
     @Override
-    public void openVpnApp() {
-        Intent i = mContext.getPackageManager().getLaunchIntentForPackage(mVpnConfig.user);
-        if (i != null) {
-            i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
-            mContext.startActivity(i);
-        }
-    }
-
-    @Override
-    public void disconnectFromLegacyVpn() {
+    public void disconnectFromVpn() {
         try {
-            mConnectivityService.prepareVpn(VpnConfig.LEGACY_VPN, VpnConfig.LEGACY_VPN);
+            if (isLegacyVpn()) {
+                mConnectivityService.prepareVpn(VpnConfig.LEGACY_VPN, VpnConfig.LEGACY_VPN);
+            } else {
+                // Prevent this app from initiating VPN connections in the future without user
+                // intervention.
+                mConnectivityService.setVpnPackageAuthorization(false);
+
+                mConnectivityService.prepareVpn(mVpnConfig.user, VpnConfig.LEGACY_VPN);
+            }
         } catch (Exception e) {
             Log.e(TAG, "Unable to disconnect from VPN", e);
         }
     }
 
     @Override
-    public void addCallback(VpnCallback callback) {
+    public void removeCallback(SecurityControllerCallback callback) {
         if (callback == null) return;
         if (DEBUG) Log.d(TAG, "removeCallback " + callback);
         mCallbacks.remove(callback);
     }
 
     @Override
-    public void removeCallback(VpnCallback callback) {
+    public void addCallback(SecurityControllerCallback callback) {
         if (callback == null || mCallbacks.contains(callback)) return;
         if (DEBUG) Log.d(TAG, "addCallback " + callback);
         mCallbacks.add(callback);
     }
 
+    @Override
+    public void onUserSwitched(int newUserId) {
+        mCurrentUserId = newUserId;
+        fireCallbacks();
+    }
+
+    private void setCurrentNetid(int netId) {
+        if (netId != mCurrentVpnNetworkId) {
+            mCurrentVpnNetworkId = netId;
+            updateState();
+            fireCallbacks();
+        }
+    }
+
     private void fireCallbacks() {
-        for (VpnCallback callback : mCallbacks) {
-            callback.onVpnStateChanged();
+        for (SecurityControllerCallback callback : mCallbacks) {
+            callback.onStateChanged();
         }
     }
 
@@ -150,13 +176,8 @@
         try {
             mVpnConfig = mConnectivityService.getVpnConfig();
 
-            // TODO: Remove once using NetworkCallback for updates.
-            mIsVpnEnabled = mVpnConfig != null;
-
             if (mVpnConfig != null && !mVpnConfig.legacy) {
-                ApplicationInfo info =
-                        mContext.getPackageManager().getApplicationInfo(mVpnConfig.user, 0);
-                mVpnName = mContext.getPackageManager().getApplicationLabel(info).toString();
+                mVpnName = VpnConfig.getVpnLabel(mContext, mVpnConfig.user).toString();
             }
         } catch (RemoteException | NameNotFoundException e) {
             Log.w(TAG, "Unable to get current VPN", e);
@@ -164,13 +185,25 @@
     }
 
     private final NetworkCallback mNetworkCallback = new NetworkCallback() {
-        public void onCapabilitiesChanged(android.net.Network network,
-                android.net.NetworkCapabilities networkCapabilities) {
-            if (DEBUG) Log.d(TAG, "onCapabilitiesChanged " + networkCapabilities);
-            mIsVpnEnabled = networkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_VPN);
-            updateState();
-            fireCallbacks();
-        }
+        @Override
+        public void onAvailable(Network network) {
+            NetworkCapabilities networkCapabilities =
+                    mConnectivityManager.getNetworkCapabilities(network);
+            if (DEBUG) Log.d(TAG, "onAvailable " + network.netId + " : " + networkCapabilities);
+            if (networkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_VPN)) {
+                setCurrentNetid(network.netId);
+            }
+        };
+
+        // TODO Find another way to receive VPN lost.  This may be delayed depending on
+        // how long the VPN connection is held on to.
+        @Override
+        public void onLost(Network network) {
+            if (DEBUG) Log.d(TAG, "onLost " + network.netId);
+            if (mCurrentVpnNetworkId == network.netId) {
+                setCurrentNetid(NO_NETWORK);
+            }
+        };
     };
 
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/TelephonyIcons.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/TelephonyIcons.java
index 84c53ce..1f2b918 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/TelephonyIcons.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/TelephonyIcons.java
@@ -188,5 +188,16 @@
         R.drawable.ic_qs_signal_lte
     };
 
+    static final int FLIGHT_MODE_ICON = R.drawable.stat_sys_airplane_mode;
+    static final int ROAMING_ICON = R.drawable.stat_sys_data_fully_connected_roam;
+    static final int ICON_LTE = R.drawable.stat_sys_data_fully_connected_lte;
+    static final int ICON_3G = R.drawable.stat_sys_data_fully_connected_3g;
+    static final int ICON_4G = R.drawable.stat_sys_data_fully_connected_4g;
+    static final int ICON_1X = R.drawable.stat_sys_data_fully_connected_1x;
+
+    static final int QS_ICON_LTE = R.drawable.ic_qs_signal_lte;
+    static final int QS_ICON_3G = R.drawable.ic_qs_signal_3g;
+    static final int QS_ICON_4G = R.drawable.ic_qs_signal_4g;
+    static final int QS_ICON_1X = R.drawable.ic_qs_signal_1x;
 }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserInfoController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserInfoController.java
index 8cbe272..d50e39f 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserInfoController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserInfoController.java
@@ -17,7 +17,6 @@
 package com.android.systemui.statusbar.policy;
 
 import android.app.ActivityManagerNative;
-import android.bluetooth.BluetoothAdapter;
 import android.content.BroadcastReceiver;
 import android.content.Context;
 import android.content.Intent;
@@ -26,33 +25,21 @@
 import android.content.pm.UserInfo;
 import android.database.Cursor;
 import android.graphics.Bitmap;
-import android.graphics.BitmapShader;
-import android.graphics.Canvas;
-import android.graphics.Matrix;
-import android.graphics.Paint;
-import android.graphics.PorterDuff;
-import android.graphics.PorterDuffXfermode;
-import android.graphics.Rect;
-import android.graphics.RectF;
-import android.graphics.Shader;
 import android.graphics.drawable.BitmapDrawable;
 import android.graphics.drawable.Drawable;
-import android.hardware.display.DisplayManager;
 import android.os.AsyncTask;
 import android.os.RemoteException;
 import android.os.UserHandle;
 import android.os.UserManager;
 import android.provider.ContactsContract;
-import android.security.KeyChain;
 import android.util.Log;
 import android.util.Pair;
 
-import com.android.internal.view.RotationPolicy;
 import com.android.systemui.BitmapHelper;
 import com.android.systemui.R;
+import com.android.internal.util.UserIcons;
 
 import java.util.ArrayList;
-import java.util.concurrent.CopyOnWriteArrayList;
 
 public final class UserInfoController {
 
@@ -142,6 +129,7 @@
             throw new RuntimeException(e);
         }
         final int userId = userInfo.id;
+        final boolean isGuest = userInfo.isGuest();
         final String userName = userInfo.name;
         final int avatarSize
                 = mContext.getResources().getDimensionPixelSize(R.dimen.max_avatar_size);
@@ -161,7 +149,8 @@
                     avatar = new BitmapDrawable(mContext.getResources(),
                             BitmapHelper.createCircularClip(rawAvatar, avatarSize, avatarSize));
                 } else {
-                    avatar = mContext.getResources().getDrawable(R.drawable.ic_account_circle);
+                    avatar = UserIcons.getDefaultUserIcon(isGuest? UserHandle.USER_NULL : userId,
+                            /* light= */ true);
                     mUseDefaultAvatar = true;
                 }
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
index 47e3e73..bbe6622 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
@@ -16,13 +16,6 @@
 
 package com.android.systemui.statusbar.policy;
 
-import com.android.systemui.BitmapHelper;
-import com.android.systemui.GuestResumeSessionReceiver;
-import com.android.systemui.R;
-import com.android.systemui.qs.QSTile;
-import com.android.systemui.qs.tiles.UserDetailView;
-import com.android.systemui.statusbar.phone.SystemUIDialog;
-
 import android.app.ActivityManager;
 import android.app.ActivityManagerNative;
 import android.app.Dialog;
@@ -45,9 +38,16 @@
 import android.util.SparseArray;
 import android.view.View;
 import android.view.ViewGroup;
-import android.view.WindowManagerGlobal;
 import android.widget.BaseAdapter;
 
+import com.android.internal.util.UserIcons;
+import com.android.systemui.BitmapHelper;
+import com.android.systemui.GuestResumeSessionReceiver;
+import com.android.systemui.R;
+import com.android.systemui.qs.QSTile;
+import com.android.systemui.qs.tiles.UserDetailView;
+import com.android.systemui.statusbar.phone.SystemUIDialog;
+
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.lang.ref.WeakReference;
@@ -73,6 +73,7 @@
 
     private ArrayList<UserRecord> mUsers = new ArrayList<>();
     private Dialog mExitGuestDialog;
+    private Dialog mAddUserDialog;
     private int mLastNonGuestUser = UserHandle.USER_OWNER;
     private boolean mSimpleUserSwitcher;
     private boolean mAddUsersWhenLocked;
@@ -158,8 +159,9 @@
                             picture = BitmapHelper.createCircularClip(
                                     picture, avatarSize, avatarSize);
                         }
-                        records.add(new UserRecord(info, picture, false /* isGuest */, isCurrent,
-                                false /* isAddUser */, false /* isRestricted */));
+                        int index = isCurrent ? 0 : records.size();
+                        records.add(index, new UserRecord(info, picture, false /* isGuest */,
+                                isCurrent, false /* isAddUser */, false /* isRestricted */));
                     }
                 }
 
@@ -182,11 +184,12 @@
                                     false /* isAddUser */, createIsRestricted));
                         }
                     } else {
-                        records.add(guestRecord);
+                        int index = guestRecord.isCurrent ? 0 : records.size();
+                        records.add(index, guestRecord);
                     }
                 }
 
-                if (canCreateUser) {
+                if (!mSimpleUserSwitcher && canCreateUser) {
                     records.add(new UserRecord(null /* info */, null /* picture */,
                             false /* isGuest */, false /* isCurrent */, true /* isAddUser */,
                             createIsRestricted));
@@ -224,10 +227,17 @@
         int id;
         if (record.isGuest && record.info == null) {
             // No guest user. Create one.
-            id = mUserManager.createGuest(mContext, mContext.getString(R.string.guest_nickname)).id;
+            UserInfo guest = mUserManager.createGuest(
+                    mContext, mContext.getString(R.string.guest_nickname));
+            if (guest == null) {
+                // Couldn't create guest, most likely because there already exists one, we just
+                // haven't reloaded the user list yet.
+                return;
+            }
+            id = guest.id;
         } else if (record.isAddUser) {
-            id = mUserManager.createUser(
-                    mContext.getString(R.string.user_new_user_name), 0 /* flags */).id;
+            showAddUserDialog();
+            return;
         } else {
             id = record.info.id;
         }
@@ -244,7 +254,6 @@
 
     private void switchToUserId(int id) {
         try {
-            WindowManagerGlobal.getWindowManagerService().lockNow(null);
             ActivityManagerNative.getDefault().switchUser(id);
         } catch (RemoteException e) {
             Log.e(TAG, "Couldn't switch user.", e);
@@ -259,6 +268,14 @@
         mExitGuestDialog.show();
     }
 
+    private void showAddUserDialog() {
+        if (mAddUserDialog != null && mAddUserDialog.isShowing()) {
+            mAddUserDialog.cancel();
+        }
+        mAddUserDialog = new AddUserDialog(mContext);
+        mAddUserDialog.show();
+    }
+
     private void exitGuest(int id) {
         int newId = UserHandle.USER_OWNER;
         if (mLastNonGuestUser != UserHandle.USER_OWNER) {
@@ -333,6 +350,14 @@
         }
     }
 
+    public String getCurrentUserName(Context context) {
+        if (mUsers.isEmpty()) return null;
+        UserRecord item = mUsers.get(0);
+        if (item == null || item.info == null) return null;
+        if (item.isGuest) return context.getString(R.string.guest_nickname);
+        return item.info.name;
+    }
+
     public static abstract class BaseUserAdapter extends BaseAdapter {
 
         final UserSwitcherController mController;
@@ -407,7 +432,8 @@
             if (item.isAddUser) {
                 return context.getDrawable(R.drawable.ic_add_circle_qs);
             }
-            return context.getDrawable(R.drawable.ic_account_circle_qs);
+            return UserIcons.getDefaultUserIcon(item.isGuest ? UserHandle.USER_NULL : item.info.id,
+                    /* light= */ true);
         }
     }
 
@@ -508,9 +534,9 @@
             setTitle(R.string.guest_exit_guest_dialog_title);
             setMessage(context.getString(R.string.guest_exit_guest_dialog_message));
             setButton(DialogInterface.BUTTON_NEGATIVE,
-                    context.getString(android.R.string.no), this);
+                    context.getString(android.R.string.cancel), this);
             setButton(DialogInterface.BUTTON_POSITIVE,
-                    context.getString(android.R.string.yes), this);
+                    context.getString(R.string.guest_exit_guest_dialog_remove), this);
             setCanceledOnTouchOutside(false);
             mGuestId = guestId;
         }
@@ -525,4 +551,39 @@
             }
         }
     }
+
+    private final class AddUserDialog extends SystemUIDialog implements
+            DialogInterface.OnClickListener {
+
+        public AddUserDialog(Context context) {
+            super(context);
+            setTitle(R.string.user_add_user_title);
+            setMessage(context.getString(R.string.user_add_user_message_short));
+            setButton(DialogInterface.BUTTON_NEGATIVE,
+                    context.getString(android.R.string.cancel), this);
+            setButton(DialogInterface.BUTTON_POSITIVE,
+                    context.getString(android.R.string.ok), this);
+        }
+
+        @Override
+        public void onClick(DialogInterface dialog, int which) {
+            if (which == BUTTON_NEGATIVE) {
+                cancel();
+            } else {
+                dismiss();
+                UserInfo user = mUserManager.createUser(
+                        mContext.getString(R.string.user_new_user_name), 0 /* flags */);
+                if (user == null) {
+                    // Couldn't create user, most likely because there are too many, but we haven't
+                    // been able to reload the list yet.
+                    return;
+                }
+                int id = user.id;
+                Bitmap icon = UserIcons.convertToBitmap(UserIcons.getDefaultUserIcon(
+                        id, /* light= */ false));
+                mUserManager.setUserIcon(id, icon);
+                switchToUserId(id);
+            }
+        }
+    }
 }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/WifiAccessPointController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/WifiAccessPointController.java
index 09e7472..b800fbf 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/WifiAccessPointController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/WifiAccessPointController.java
@@ -134,6 +134,9 @@
         final List<AccessPoint> aps = new ArrayList<AccessPoint>(scanResults.size());
         final ArraySet<String> ssids = new ArraySet<String>();
         for (ScanResult scanResult : scanResults) {
+            if (scanResult == null) {
+                continue;
+            }
             final String ssid = scanResult.SSID;
             if (TextUtils.isEmpty(ssid) || ssids.contains(ssid)) continue;
             if (!configured.containsKey(ssid)) continue;
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeController.java
index 7d102ba..600b750 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeController.java
@@ -16,6 +16,7 @@
 
 package com.android.systemui.statusbar.policy;
 
+import android.content.ComponentName;
 import android.service.notification.Condition;
 
 public interface ZenModeController {
@@ -29,6 +30,7 @@
     long getNextAlarm();
     void setUserId(int userId);
     boolean isZenAvailable();
+    ComponentName getEffectsSuppressor();
 
     public static class Callback {
         public void onZenChanged(int zen) {}
@@ -36,5 +38,6 @@
         public void onConditionsChanged(Condition[] conditions) {}
         public void onNextAlarmChanged() {}
         public void onZenAvailableChanged(boolean available) {}
+        public void onEffectsSupressorChanged() {}
     }
 }
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeControllerImpl.java
index b0c8f26..415eb27 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/ZenModeControllerImpl.java
@@ -18,7 +18,9 @@
 
 import android.app.AlarmManager;
 import android.app.INotificationManager;
+import android.app.NotificationManager;
 import android.content.BroadcastReceiver;
+import android.content.ComponentName;
 import android.content.ContentResolver;
 import android.content.Context;
 import android.content.Intent;
@@ -161,12 +163,23 @@
         mSetupObserver.register();
     }
 
+    @Override
+    public ComponentName getEffectsSuppressor() {
+        return NotificationManager.from(mContext).getEffectsSuppressor();
+    }
+
     private void fireNextAlarmChanged() {
         for (Callback cb : mCallbacks) {
             cb.onNextAlarmChanged();
         }
     }
 
+    private void fireEffectsSuppressorChanged() {
+        for (Callback cb : mCallbacks) {
+            cb.onEffectsSupressorChanged();
+        }
+    }
+
     private void fireZenChanged(int zen) {
         for (Callback cb : mCallbacks) {
             cb.onZenChanged(zen);
@@ -219,6 +232,9 @@
             if (AlarmManager.ACTION_NEXT_ALARM_CLOCK_CHANGED.equals(intent.getAction())) {
                 fireNextAlarmChanged();
             }
+            if (NotificationManager.ACTION_EFFECTS_SUPPRESSOR_CHANGED.equals(intent.getAction())) {
+                fireEffectsSuppressorChanged();
+            }
         }
     };
 
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/AmbientState.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/AmbientState.java
index ddb5cb8..8e677f1 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/AmbientState.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/AmbientState.java
@@ -32,7 +32,6 @@
     private float mOverScrollTopAmount;
     private float mOverScrollBottomAmount;
     private int mSpeedBumpIndex = -1;
-    private float mScrimAmount;
     private boolean mDark;
     private boolean mHideSensitive;
 
@@ -105,14 +104,6 @@
         }
     }
 
-    public void setScrimAmount(float scrimAmount) {
-        mScrimAmount = scrimAmount;
-    }
-
-    public float getScrimAmount() {
-        return mScrimAmount;
-    }
-
     public float getOverScrollAmount(boolean top) {
         return top ? mOverScrollTopAmount : mOverScrollBottomAmount;
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java
index 1469d73..67ba8d20 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/NotificationStackScrollLayout.java
@@ -40,6 +40,8 @@
 import com.android.systemui.statusbar.ExpandableNotificationRow;
 import com.android.systemui.statusbar.ExpandableView;
 import com.android.systemui.statusbar.SpeedBumpView;
+import com.android.systemui.statusbar.StatusBarState;
+import com.android.systemui.statusbar.phone.PhoneStatusBar;
 import com.android.systemui.statusbar.policy.ScrollAdapter;
 import com.android.systemui.statusbar.stack.StackScrollState.ViewState;
 
@@ -165,6 +167,7 @@
     private boolean mDontReportNextOverScroll;
     private boolean mRequestViewResizeAnimationOnLayout;
     private boolean mNeedViewResizeAnimation;
+    private boolean mEverythingNeedsAnimation;
 
     /**
      * The maximum scrollPosition which we are allowed to reach when a notification was expanded.
@@ -195,6 +198,7 @@
             return true;
         }
     };
+    private PhoneStatusBar mPhoneStatusBar;
 
     public NotificationStackScrollLayout(Context context) {
         this(context, null);
@@ -577,7 +581,7 @@
             }
             float childTop = slidingChild.getTranslationY();
             float top = childTop + slidingChild.getClipTopAmount();
-            float bottom = top + slidingChild.getActualHeight();
+            float bottom = childTop + slidingChild.getActualHeight();
 
             // Allow the full width of this view to prevent gesture conflict on Keyguard (phone and
             // camera affordance).
@@ -640,6 +644,11 @@
         return (veto != null && veto.getVisibility() != View.GONE);
     }
 
+    @Override
+    public boolean isAntiFalsingNeeded() {
+        return mPhoneStatusBar.getBarState() == StatusBarState.KEYGUARD;
+    }
+
     private void setSwipingInProgress(boolean isSwiped) {
         mSwipingInProgress = isSwiped;
         if(isSwiped) {
@@ -1459,6 +1468,10 @@
             // drawn when removed
             getOverlay().add(child);
         }
+        updateAnimationState(false, child);
+
+        // Make sure the clipRect we might have set is removed
+        child.setClipBounds(null);
     }
 
     /**
@@ -1519,7 +1532,7 @@
                 return position;
             }
             if (child.getVisibility() != View.GONE) {
-                position += child.getHeight();
+                position += getIntrinsicHeight(child);
                 if (i < getChildCount()-1) {
                     position += mPaddingBetweenElements;
                 }
@@ -1534,10 +1547,33 @@
         mStackScrollAlgorithm.notifyChildrenChanged(this);
         ((ExpandableView) child).setOnHeightChangedListener(this);
         generateAddAnimation(child, false /* fromMoreCard */);
+        updateAnimationState(child);
     }
 
     public void setAnimationsEnabled(boolean animationsEnabled) {
         mAnimationsEnabled = animationsEnabled;
+        updateNotificationAnimationStates();
+    }
+
+    private void updateNotificationAnimationStates() {
+        boolean running = mIsExpanded && mAnimationsEnabled;
+        int childCount = getChildCount();
+        for (int i = 0; i < childCount; i++) {
+            View child = getChildAt(i);
+            updateAnimationState(running, child);
+        }
+    }
+
+    private void updateAnimationState(View child) {
+        updateAnimationState(mAnimationsEnabled && mIsExpanded, child);
+    }
+
+
+    private void updateAnimationState(boolean running, View child) {
+        if (child instanceof ExpandableNotificationRow) {
+            ExpandableNotificationRow row = (ExpandableNotificationRow) child;
+            row.setIconAnimationRunning(running);
+        }
     }
 
     public boolean isAddOrRemoveAnimationPending() {
@@ -1609,6 +1645,7 @@
         generateDarkEvent();
         generateGoToFullShadeEvent();
         generateViewResizeEvent();
+        generateAnimateEverythingEvent();
         mNeedsAnimation = false;
     }
 
@@ -1691,6 +1728,14 @@
         mActivateNeedsAnimation = false;
     }
 
+    private void generateAnimateEverythingEvent() {
+        if (mEverythingNeedsAnimation) {
+            mAnimationEvents.add(
+                    new AnimationEvent(null, AnimationEvent.ANIMATION_TYPE_EVERYTHING));
+        }
+        mEverythingNeedsAnimation = false;
+    }
+
     private void generateDimmedEvent() {
         if (mDimmedNeedsAnimation) {
             mAnimationEvents.add(
@@ -1898,8 +1943,12 @@
     }
 
     private void setIsExpanded(boolean isExpanded) {
+        boolean changed = isExpanded != mIsExpanded;
         mIsExpanded = isExpanded;
         mStackScrollAlgorithm.setIsExpanded(isExpanded);
+        if (changed) {
+            updateNotificationAnimationStates();
+        }
     }
 
     @Override
@@ -1913,8 +1962,11 @@
 
     @Override
     public void onReset(ExpandableView view) {
-        mRequestViewResizeAnimationOnLayout = true;
+        if (mIsExpanded && mAnimationsEnabled) {
+            mRequestViewResizeAnimationOnLayout = true;
+        }
         mStackScrollAlgorithm.onReset(view);
+        updateAnimationState(view);
     }
 
     private void updateScrollPositionOnExpandInBottom(ExpandableView view) {
@@ -2049,13 +2101,6 @@
         return true;
     }
 
-    public void setScrimAlpha(float progress) {
-        if (progress != mAmbientState.getScrimAmount()) {
-            mAmbientState.setScrimAmount(progress);
-            requestChildrenUpdate();
-        }
-    }
-
     /**
      * See {@link AmbientState#setDark}.
      */
@@ -2082,15 +2127,16 @@
         int oldVisibility = mEmptyShadeView.willBeGone() ? GONE : mEmptyShadeView.getVisibility();
         int newVisibility = visible ? VISIBLE : GONE;
         if (oldVisibility != newVisibility) {
-            if (oldVisibility == GONE) {
+            if (newVisibility != GONE) {
                 if (mEmptyShadeView.willBeGone()) {
                     mEmptyShadeView.cancelAnimation();
                 } else {
                     mEmptyShadeView.setInvisible();
-                    mEmptyShadeView.setVisibility(newVisibility);
                 }
+                mEmptyShadeView.setVisibility(newVisibility);
                 mEmptyShadeView.setWillBeGone(false);
                 updateContentHeight();
+                notifyHeightChangeListener(mDismissView);
             } else {
                 mEmptyShadeView.setWillBeGone(true);
                 mEmptyShadeView.performVisibilityAnimation(false, new Runnable() {
@@ -2099,6 +2145,7 @@
                         mEmptyShadeView.setVisibility(GONE);
                         mEmptyShadeView.setWillBeGone(false);
                         updateContentHeight();
+                        notifyHeightChangeListener(mDismissView);
                     }
                 });
             }
@@ -2109,15 +2156,16 @@
         int oldVisibility = mDismissView.willBeGone() ? GONE : mDismissView.getVisibility();
         int newVisibility = visible ? VISIBLE : GONE;
         if (oldVisibility != newVisibility) {
-            if (oldVisibility == GONE) {
+            if (newVisibility != GONE) {
                 if (mDismissView.willBeGone()) {
                     mDismissView.cancelAnimation();
                 } else {
                     mDismissView.setInvisible();
-                    mDismissView.setVisibility(newVisibility);
                 }
+                mDismissView.setVisibility(newVisibility);
                 mDismissView.setWillBeGone(false);
                 updateContentHeight();
+                notifyHeightChangeListener(mDismissView);
             } else {
                 mDismissView.setWillBeGone(true);
                 mDismissView.performVisibilityAnimation(false, new Runnable() {
@@ -2126,6 +2174,7 @@
                         mDismissView.setVisibility(GONE);
                         mDismissView.setWillBeGone(false);
                         updateContentHeight();
+                        notifyHeightChangeListener(mDismissView);
                     }
                 });
             }
@@ -2145,7 +2194,15 @@
     }
 
     public int getDismissViewHeight() {
-        return mDismissView.getHeight() + mPaddingBetweenElementsNormal;
+        int height = mDismissView.getHeight() + mPaddingBetweenElementsNormal;
+
+        // Hack: Accommodate for additional distance when we only have one notification and the
+        // dismiss all button.
+        if (getNotGoneChildCount() == 2 && getLastChildNotGone() == mDismissView
+                && getFirstChildNotGone() instanceof ActivatableNotificationView) {
+            height += mCollapseSecondCardPadding;
+        }
+        return height;
     }
 
     public float getBottomMostNotificationBottom() {
@@ -2172,6 +2229,17 @@
         mStackScrollAlgorithm.updateIsSmallScreen(mMaxLayoutHeight - qsMinHeight);
     }
 
+    public void setPhoneStatusBar(PhoneStatusBar phoneStatusBar) {
+        this.mPhoneStatusBar = phoneStatusBar;
+    }
+
+    public void onGoToKeyguard() {
+        if (mIsExpanded && mAnimationsEnabled) {
+            mEverythingNeedsAnimation = true;
+            requestChildrenUpdate();
+        }
+    }
+
     /**
      * A listener that is notified when some child locations might have changed.
      */
@@ -2299,6 +2367,18 @@
                         .animateTopInset()
                         .animateY()
                         .animateZ(),
+
+                // ANIMATION_TYPE_EVERYTHING
+                new AnimationFilter()
+                        .animateAlpha()
+                        .animateDark()
+                        .animateScale()
+                        .animateDimmed()
+                        .animateHideSensitive()
+                        .animateHeight()
+                        .animateTopInset()
+                        .animateY()
+                        .animateZ(),
         };
 
         static int[] LENGTHS = new int[] {
@@ -2341,6 +2421,9 @@
 
                 // ANIMATION_TYPE_VIEW_RESIZE
                 StackStateAnimator.ANIMATION_DURATION_STANDARD,
+
+                // ANIMATION_TYPE_EVERYTHING
+                StackStateAnimator.ANIMATION_DURATION_STANDARD,
         };
 
         static final int ANIMATION_TYPE_ADD = 0;
@@ -2356,6 +2439,7 @@
         static final int ANIMATION_TYPE_GO_TO_FULL_SHADE = 10;
         static final int ANIMATION_TYPE_HIDE_SENSITIVE = 11;
         static final int ANIMATION_TYPE_VIEW_RESIZE = 12;
+        static final int ANIMATION_TYPE_EVERYTHING = 13;
 
         final long eventStartTime;
         final View changingView;
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
index fe855d9..e4a1c27 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollAlgorithm.java
@@ -40,8 +40,6 @@
     private static final int MAX_ITEMS_IN_BOTTOM_STACK = 3;
     private static final int MAX_ITEMS_IN_TOP_STACK = 3;
 
-    /** When a child is activated, the other cards' alpha fade to this value. */
-    private static final float ACTIVATED_INVERSE_ALPHA = 0.9f;
     public static final float DIMMED_SCALE = 0.95f;
 
     private int mPaddingBetweenElements;
@@ -172,7 +170,6 @@
         handleDraggedViews(ambientState, resultState, algorithmState);
         updateDimmedActivatedHideSensitive(ambientState, resultState, algorithmState);
         updateClipping(resultState, algorithmState);
-        updateScrimAmount(resultState, algorithmState, ambientState.getScrimAmount());
         updateSpeedBumpState(resultState, algorithmState, ambientState.getSpeedBumpIndex());
     }
 
@@ -189,16 +186,6 @@
         }
     }
 
-    private void updateScrimAmount(StackScrollState resultState,
-            StackScrollAlgorithmState algorithmState, float scrimAmount) {
-        int childCount = algorithmState.visibleChildren.size();
-        for (int i = 0; i < childCount; i++) {
-            View child = algorithmState.visibleChildren.get(i);
-            StackScrollState.ViewState childViewState = resultState.getViewStateForView(child);
-            childViewState.scrimAmount = scrimAmount;
-        }
-    }
-
     private void updateClipping(StackScrollState resultState,
             StackScrollAlgorithmState algorithmState) {
         float previousNotificationEnd = 0;
@@ -281,12 +268,8 @@
             childViewState.scale = !mScaleDimmed || !dimmed || isActivatedChild
                     ? 1.0f
                     : DIMMED_SCALE;
-            if (dimmed && activatedChild != null) {
-                if (!isActivatedChild) {
-                    childViewState.alpha *= ACTIVATED_INVERSE_ALPHA;
-                } else {
-                    childViewState.zTranslation += 2.0f * mZDistanceBetweenElements;
-                }
+            if (dimmed && isActivatedChild) {
+                childViewState.zTranslation += 2.0f * mZDistanceBetweenElements;
             }
         }
     }
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollState.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollState.java
index f7a2824..0967ecd 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollState.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackScrollState.java
@@ -165,9 +165,6 @@
                 // apply speed bump state
                 child.setBelowSpeedBump(state.belowSpeedBump);
 
-                // apply scrimming
-                child.setScrimAmount(state.scrimAmount);
-
                 // apply clipping
                 float oldClipTopAmount = child.getClipTopAmount();
                 if (oldClipTopAmount != state.clipTopAmount) {
@@ -252,12 +249,6 @@
         boolean belowSpeedBump;
 
         /**
-         * A value between 0 and 1 indicating how much the view should be scrimmed.
-         * 1 means that the notifications will be darkened as much as possible.
-         */
-        float scrimAmount;
-
-        /**
          * The amount which the view should be clipped from the top. This is calculated to
          * perceive consistent shadows.
          */
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackStateAnimator.java b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackStateAnimator.java
index afd7216..a69390e 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackStateAnimator.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/stack/StackStateAnimator.java
@@ -166,6 +166,7 @@
         boolean hasDelays = mAnimationFilter.hasDelays;
         boolean isDelayRelevant = yTranslationChanging || zTranslationChanging || scaleChanging ||
                 alphaChanging || heightChanging || topInsetChanging;
+        boolean noAnimation = wasAdded;
         long delay = 0;
         long duration = mCurrentLength;
         if (hasDelays && isDelayRelevant || wasAdded) {
@@ -183,49 +184,72 @@
 
         // start translationY animation
         if (yTranslationChanging) {
-            startYTranslationAnimation(child, viewState, duration, delay);
+            if (noAnimation && !mAnimationFilter.hasGoToFullShadeEvent) {
+                child.setTranslationY(viewState.yTranslation);
+            } else {
+                startYTranslationAnimation(child, viewState, duration, delay);
+            }
         }
 
         // start translationZ animation
         if (zTranslationChanging) {
-            startZTranslationAnimation(child, viewState, duration, delay);
+            if (noAnimation) {
+                child.setTranslationZ(viewState.zTranslation);
+            } else {
+                startZTranslationAnimation(child, viewState, duration, delay);
+            }
         }
 
         // start scale animation
         if (scaleChanging) {
-            startScaleAnimation(child, viewState, duration);
+            if (noAnimation) {
+                child.setScaleX(viewState.scale);
+                child.setScaleY(viewState.scale);
+            } else {
+                startScaleAnimation(child, viewState, duration);
+            }
         }
 
         // start alpha animation
         if (alphaChanging && child.getTranslationX() == 0) {
-            startAlphaAnimation(child, viewState, duration, delay);
+            if (noAnimation) {
+                child.setAlpha(viewState.alpha);
+            } else {
+                startAlphaAnimation(child, viewState, duration, delay);
+            }
         }
 
         // start height animation
-        if (heightChanging) {
-            startHeightAnimation(child, viewState, duration, delay);
+        if (heightChanging && child.getActualHeight() != 0) {
+            if (noAnimation) {
+                child.setActualHeight(viewState.height, false);
+            } else {
+                startHeightAnimation(child, viewState, duration, delay);
+            }
         }
 
         // start top inset animation
         if (topInsetChanging) {
-            startInsetAnimation(child, viewState, duration, delay);
+            if (noAnimation) {
+                child.setClipTopAmount(viewState.clipTopAmount);
+            } else {
+                startInsetAnimation(child, viewState, duration, delay);
+            }
         }
 
         // start dimmed animation
-        child.setDimmed(viewState.dimmed, mAnimationFilter.animateDimmed && !wasAdded);
+        child.setDimmed(viewState.dimmed, mAnimationFilter.animateDimmed && !wasAdded
+                && !noAnimation);
 
         // start dark animation
-        child.setDark(viewState.dark, mAnimationFilter.animateDark);
+        child.setDark(viewState.dark, mAnimationFilter.animateDark && !noAnimation);
 
         // apply speed bump state
         child.setBelowSpeedBump(viewState.belowSpeedBump);
 
         // start hiding sensitive animation
-        child.setHideSensitive(viewState.hideSensitive,
-                mAnimationFilter.animateHideSensitive && !wasAdded, delay, duration);
-
-        // apply scrimming
-        child.setScrimAmount(viewState.scrimAmount);
+        child.setHideSensitive(viewState.hideSensitive, mAnimationFilter.animateHideSensitive &&
+                !wasAdded && !noAnimation, delay, duration);
 
         if (wasAdded) {
             child.performAddAnimation(delay, mCurrentLength);
@@ -747,6 +771,7 @@
             } else if (event.animationType ==
                     NotificationStackScrollLayout.AnimationEvent.ANIMATION_TYPE_REMOVE) {
                 if (changingView.getVisibility() == View.GONE) {
+                    mHostLayout.getOverlay().remove(changingView);
                     continue;
                 }
 
diff --git a/packages/SystemUI/src/com/android/systemui/usb/StorageNotification.java b/packages/SystemUI/src/com/android/systemui/usb/StorageNotification.java
index 481266b..dce5c37 100644
--- a/packages/SystemUI/src/com/android/systemui/usb/StorageNotification.java
+++ b/packages/SystemUI/src/com/android/systemui/usb/StorageNotification.java
@@ -309,7 +309,8 @@
                 pi = PendingIntent.getBroadcastAsUser(mContext, 0, intent, 0,
                         UserHandle.CURRENT);
             }
-
+            mUsbStorageNotification.color = mContext.getResources().getColor(
+                    com.android.internal.R.color.system_notification_accent_color);
             mUsbStorageNotification.setLatestEventInfo(mContext, title, message, pi);
             mUsbStorageNotification.visibility = Notification.VISIBILITY_PUBLIC;
             mUsbStorageNotification.category = Notification.CATEGORY_SYSTEM;
@@ -403,6 +404,8 @@
             }
 
             mMediaStorageNotification.icon = icon;
+            mMediaStorageNotification.color = mContext.getResources().getColor(
+                    com.android.internal.R.color.system_notification_accent_color);
             mMediaStorageNotification.setLatestEventInfo(mContext, title, message, pi);
             mMediaStorageNotification.visibility = Notification.VISIBILITY_PUBLIC;
             mMediaStorageNotification.category = Notification.CATEGORY_SYSTEM;
diff --git a/packages/SystemUI/src/com/android/systemui/volume/SegmentedButtons.java b/packages/SystemUI/src/com/android/systemui/volume/SegmentedButtons.java
index 6d30bce..66e1e15 100644
--- a/packages/SystemUI/src/com/android/systemui/volume/SegmentedButtons.java
+++ b/packages/SystemUI/src/com/android/systemui/volume/SegmentedButtons.java
@@ -32,6 +32,7 @@
 public class SegmentedButtons extends LinearLayout {
     private static final Typeface MEDIUM = Typeface.create("sans-serif-medium", Typeface.NORMAL);
     private static final Typeface BOLD = Typeface.create("sans-serif", Typeface.BOLD);
+    private static final int LABEL_RES_KEY = R.id.label;
 
     private final Context mContext;
     private final LayoutInflater mInflater;
@@ -69,6 +70,7 @@
 
     public void addButton(int labelResId, Object value) {
         final Button b = (Button) mInflater.inflate(R.layout.segmented_button, this, false);
+        b.setTag(LABEL_RES_KEY, labelResId);
         b.setText(labelResId);
         final LayoutParams lp = (LayoutParams) b.getLayoutParams();
         if (getChildCount() == 0) {
@@ -80,6 +82,14 @@
         b.setOnClickListener(mClick);
     }
 
+    public void updateLocale() {
+        for (int i = 0; i < getChildCount(); i++) {
+            final Button b = (Button) getChildAt(i);
+            final int labelResId = (Integer) b.getTag(LABEL_RES_KEY);
+            b.setText(labelResId);
+        }
+    }
+
     private void fireOnSelected() {
         if (mCallback != null) {
             mCallback.onSelected(mSelectedValue);
diff --git a/packages/SystemUI/src/com/android/systemui/volume/VolumePanel.java b/packages/SystemUI/src/com/android/systemui/volume/VolumePanel.java
index b05c242..fa43f32 100644
--- a/packages/SystemUI/src/com/android/systemui/volume/VolumePanel.java
+++ b/packages/SystemUI/src/com/android/systemui/volume/VolumePanel.java
@@ -19,11 +19,14 @@
 import android.app.AlertDialog;
 import android.app.Dialog;
 import android.content.BroadcastReceiver;
+import android.content.ComponentName;
 import android.content.Context;
 import android.content.DialogInterface;
 import android.content.DialogInterface.OnDismissListener;
 import android.content.Intent;
 import android.content.IntentFilter;
+import android.content.pm.PackageManager;
+import android.content.pm.ServiceInfo;
 import android.content.res.Configuration;
 import android.content.res.Resources;
 import android.content.res.TypedArray;
@@ -37,12 +40,11 @@
 import android.media.ToneGenerator;
 import android.media.VolumeProvider;
 import android.media.session.MediaController;
-import android.media.session.MediaController.VolumeInfo;
+import android.media.session.MediaController.PlaybackInfo;
 import android.net.Uri;
 import android.os.Handler;
 import android.os.Message;
 import android.os.Vibrator;
-import android.provider.Settings.Global;
 import android.util.Log;
 import android.util.SparseArray;
 import android.view.KeyEvent;
@@ -54,9 +56,12 @@
 import android.view.Window;
 import android.view.WindowManager;
 import android.view.WindowManager.LayoutParams;
+import android.view.accessibility.AccessibilityEvent;
+import android.view.accessibility.AccessibilityManager;
 import android.widget.ImageView;
 import android.widget.SeekBar;
 import android.widget.SeekBar.OnSeekBarChangeListener;
+import android.widget.TextView;
 
 import com.android.internal.R;
 import com.android.systemui.statusbar.phone.SystemUIDialog;
@@ -109,6 +114,7 @@
     private static final int MSG_LAYOUT_DIRECTION = 12;
     private static final int MSG_ZEN_MODE_AVAILABLE_CHANGED = 13;
     private static final int MSG_USER_ACTIVITY = 14;
+    private static final int MSG_NOTIFICATION_EFFECTS_SUPPRESSOR_CHANGED = 15;
 
     // Pseudo stream type for master volume
     private static final int STREAM_MASTER = -100;
@@ -155,6 +161,7 @@
     private int mActiveStreamType = -1;
     /** All the slider controls mapped by stream type */
     private SparseArray<StreamControl> mStreamControls;
+    private final AccessibilityManager mAccessibilityManager;
 
     private enum StreamResources {
         BluetoothSCOStream(AudioManager.STREAM_BLUETOOTH_SCO,
@@ -234,8 +241,10 @@
         ViewGroup group;
         ImageView icon;
         SeekBar seekbarView;
+        TextView suppressorView;
         int iconRes;
         int iconMuteRes;
+        int iconSuppressedRes;
     }
 
     // Synchronize when accessing this
@@ -324,6 +333,8 @@
         mContext = context;
         mZenController = zenController;
         mAudioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
+        mAccessibilityManager = (AccessibilityManager) context.getSystemService(
+                Context.ACCESSIBILITY_SERVICE);
 
         // For now, only show master volume if master volume is supported
         final Resources res = context.getResources();
@@ -420,6 +431,9 @@
 
     public void onConfigurationChanged(Configuration newConfig) {
         updateWidth();
+        if (mZenPanel != null) {
+            mZenPanel.updateLocale();
+        }
     }
 
     private void updateWidth() {
@@ -537,8 +551,8 @@
             if (mStreamControls != null) {
                 StreamControl sc = mStreamControls.get(streamType);
                 if (sc != null && sc.controller != null) {
-                    VolumeInfo vi = sc.controller.getVolumeInfo();
-                    return vi.getMaxVolume();
+                    PlaybackInfo ai = sc.controller.getPlaybackInfo();
+                    return ai.getMaxVolume();
                 }
             }
             return -1;
@@ -554,8 +568,8 @@
             if (mStreamControls != null) {
                 StreamControl sc = mStreamControls.get(streamType);
                 if (sc != null && sc.controller != null) {
-                    VolumeInfo vi = sc.controller.getVolumeInfo();
-                    return vi.getCurrentVolume();
+                    PlaybackInfo ai = sc.controller.getPlaybackInfo();
+                    return ai.getCurrentVolume();
                 }
             }
             return -1;
@@ -613,8 +627,12 @@
                         toggle(sc);
                     }
                 });
+                sc.iconSuppressedRes = com.android.systemui.R.drawable.ic_ringer_mute;
             }
             sc.seekbarView = (SeekBar) sc.group.findViewById(com.android.systemui.R.id.seekbar);
+            sc.suppressorView =
+                    (TextView) sc.group.findViewById(com.android.systemui.R.id.suppressor);
+            sc.suppressorView.setVisibility(View.GONE);
             final int plusOne = (streamType == AudioSystem.STREAM_BLUETOOTH_SCO ||
                     streamType == AudioSystem.STREAM_VOICE_CALL) ? 1 : 0;
             sc.seekbarView.setMax(getStreamMaxVolume(streamType) + plusOne);
@@ -678,6 +696,40 @@
         sc.icon.setImageResource(muted ? sc.iconMuteRes : sc.iconRes);
     }
 
+    private void updateSliderSupressor(StreamControl sc) {
+        final ComponentName suppressor = isNotificationOrRing(sc.streamType)
+                ? mZenController.getEffectsSuppressor() : null;
+        if (suppressor == null) {
+            sc.seekbarView.setVisibility(View.VISIBLE);
+            sc.suppressorView.setVisibility(View.GONE);
+        } else {
+            sc.seekbarView.setVisibility(View.GONE);
+            sc.suppressorView.setVisibility(View.VISIBLE);
+            sc.suppressorView.setText(mContext.getString(com.android.systemui.R.string.muted_by,
+                    getSuppressorCaption(suppressor)));
+            sc.icon.setImageResource(sc.iconSuppressedRes);
+        }
+    }
+
+    private String getSuppressorCaption(ComponentName suppressor) {
+        final PackageManager pm = mContext.getPackageManager();
+        try {
+            final ServiceInfo info = pm.getServiceInfo(suppressor, 0);
+            if (info != null) {
+                final CharSequence seq = info.loadLabel(pm);
+                if (seq != null) {
+                    final String str = seq.toString().trim();
+                    if (str.length() > 0) {
+                        return str;
+                    }
+                }
+            }
+        } catch (Throwable e) {
+            Log.w(TAG, "Error loading suppressor caption", e);
+        }
+        return suppressor.getPackageName();
+    }
+
     /** Update the mute and progress state of a slider */
     private void updateSlider(StreamControl sc) {
         updateSliderProgress(sc, -1);
@@ -686,6 +738,7 @@
         sc.icon.setImageDrawable(null);
         updateSliderIcon(sc, muted);
         updateSliderEnabled(sc, muted, false);
+        updateSliderSupressor(sc);
     }
 
     private void updateSliderEnabled(final StreamControl sc, boolean muted, boolean fixedVolume) {
@@ -990,7 +1043,7 @@
                     // We still don't have one, ignore the command.
                     Log.w(mTag, "sent remote volume change without a controller!");
                 } else {
-                    VolumeInfo vi = controller.getVolumeInfo();
+                    PlaybackInfo vi = controller.getPlaybackInfo();
                     index = vi.getCurrentVolume();
                     max = vi.getMaxVolume();
                     if ((vi.getVolumeControl() & VolumeProvider.VOLUME_CONTROL_FIXED) != 0) {
@@ -1006,11 +1059,11 @@
         if (sc != null) {
             if (streamType == STREAM_REMOTE_MUSIC && controller != sc.controller) {
                 if (sc.controller != null) {
-                    sc.controller.removeCallback(mMediaControllerCb);
+                    sc.controller.unregisterCallback(mMediaControllerCb);
                 }
                 sc.controller = controller;
                 if (controller != null) {
-                    sc.controller.addCallback(mMediaControllerCb);
+                    sc.controller.registerCallback(mMediaControllerCb);
                 }
             }
             if (sc.seekbarView.getMax() != max) {
@@ -1029,6 +1082,7 @@
             if (mCallback != null) {
                 mCallback.onVisible(true);
             }
+            announceDialogShown();
         }
 
         // Do a little vibrate if applicable (only when going into vibrate mode)
@@ -1045,6 +1099,10 @@
         }
     }
 
+    private void announceDialogShown() {
+        mView.sendAccessibilityEvent(AccessibilityEvent.TYPE_WINDOW_STATE_CHANGED);
+    }
+
     private boolean isShowing() {
         return mDialog.isShowing();
     }
@@ -1126,7 +1184,7 @@
             StreamControl sc = mStreamControls.get(STREAM_REMOTE_MUSIC);
             if (sc != null) {
                 if (sc.controller != null) {
-                    sc.controller.removeCallback(mMediaControllerCb);
+                    sc.controller.unregisterCallback(mMediaControllerCb);
                     sc.controller = null;
                 }
             }
@@ -1167,7 +1225,12 @@
             }
             updateStates();
         }
-        resetTimeout();
+        if (mAccessibilityManager.isTouchExplorationEnabled()) {
+            removeMessages(MSG_TIMEOUT);
+        } else {
+            updateTimeoutDelay();
+            resetTimeout();
+        }
     }
 
     /**
@@ -1275,7 +1338,9 @@
                 }
                 break;
             }
-            case MSG_RINGER_MODE_CHANGED: {
+
+            case MSG_RINGER_MODE_CHANGED:
+            case MSG_NOTIFICATION_EFFECTS_SUPPRESSOR_CHANGED: {
                 if (isShowing()) {
                     updateStates();
                 }
@@ -1319,10 +1384,12 @@
     private void resetTimeout() {
         if (LOGD) Log.d(mTag, "resetTimeout at " + System.currentTimeMillis()
                 + " delay=" + mTimeoutDelay);
-        removeMessages(MSG_TIMEOUT);
-        sendEmptyMessageDelayed(MSG_TIMEOUT, mTimeoutDelay);
-        removeMessages(MSG_USER_ACTIVITY);
-        sendEmptyMessage(MSG_USER_ACTIVITY);
+        if (sSafetyWarning == null || !mAccessibilityManager.isTouchExplorationEnabled()) {
+            removeMessages(MSG_TIMEOUT);
+            sendEmptyMessageDelayed(MSG_TIMEOUT, mTimeoutDelay);
+            removeMessages(MSG_USER_ACTIVITY);
+            sendEmptyMessage(MSG_USER_ACTIVITY);
+        }
     }
 
     private void forceTimeout(long delay) {
@@ -1356,13 +1423,19 @@
     };
 
     private final ZenModeController.Callback mZenCallback = new ZenModeController.Callback() {
+        @Override
         public void onZenAvailableChanged(boolean available) {
             obtainMessage(MSG_ZEN_MODE_AVAILABLE_CHANGED, available ? 1 : 0, 0).sendToTarget();
         }
+        @Override
+        public void onEffectsSupressorChanged() {
+            obtainMessage(MSG_NOTIFICATION_EFFECTS_SUPPRESSOR_CHANGED,
+                    mZenController.getEffectsSuppressor()).sendToTarget();
+        }
     };
 
     private final MediaController.Callback mMediaControllerCb = new MediaController.Callback() {
-        public void onVolumeInfoChanged(VolumeInfo info) {
+        public void onAudioInfoChanged(PlaybackInfo info) {
             onRemoteVolumeUpdateIfShown();
         }
     };
diff --git a/packages/SystemUI/src/com/android/systemui/volume/ZenModePanel.java b/packages/SystemUI/src/com/android/systemui/volume/ZenModePanel.java
index c99e1fd..2b541d3 100644
--- a/packages/SystemUI/src/com/android/systemui/volume/ZenModePanel.java
+++ b/packages/SystemUI/src/com/android/systemui/volume/ZenModePanel.java
@@ -31,10 +31,9 @@
 import android.provider.Settings.Global;
 import android.service.notification.Condition;
 import android.service.notification.ZenModeConfig;
-import android.text.format.DateFormat;
-import android.text.format.Time;
 import android.util.AttributeSet;
 import android.util.Log;
+import android.util.MathUtils;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.animation.AnimationUtils;
@@ -49,10 +48,7 @@
 import com.android.systemui.R;
 import com.android.systemui.statusbar.policy.ZenModeController;
 
-import java.text.SimpleDateFormat;
 import java.util.Arrays;
-import java.util.Date;
-import java.util.Locale;
 import java.util.Objects;
 
 public class ZenModePanel extends LinearLayout {
@@ -64,7 +60,7 @@
 
     private static final int[] MINUTE_BUCKETS = DEBUG
             ? new int[] { 0, 1, 2, 5, 15, 30, 45, 60, 120, 180, 240, 480 }
-            : new int[] { 15, 30, 45, 60, 120, 180, 240, 480 };
+            : ZenModeConfig.MINUTE_BUCKETS;
     private static final int MIN_BUCKET_MINUTES = MINUTE_BUCKETS[0];
     private static final int MAX_BUCKET_MINUTES = MINUTE_BUCKETS[MINUTE_BUCKETS.length - 1];
     private static final int DEFAULT_BUCKET_INDEX = Arrays.binarySearch(MINUTE_BUCKETS, 60);
@@ -72,17 +68,16 @@
     private static final int TIME_CONDITION_INDEX = 1;
     private static final int FIRST_CONDITION_INDEX = 2;
     private static final float SILENT_HINT_PULSE_SCALE = 1.1f;
-    private static final int ZERO_VALUE_MS = 20 * SECONDS_MS;
 
     public static final Intent ZEN_SETTINGS = new Intent(Settings.ACTION_ZEN_MODE_SETTINGS);
 
     private final Context mContext;
     private final LayoutInflater mInflater;
     private final H mHandler = new H();
-    private final Favorites mFavorites;
+    private final Prefs mPrefs;
     private final Interpolator mFastOutSlowInInterpolator;
-    private final int mHardWarningColor;
-    private final int mSoftWarningColor;
+    private final int mSubheadWarningColor;
+    private final int mSubheadColor;
 
     private String mTag = TAG + "/" + Integer.toHexString(System.identityHashCode(this));
 
@@ -92,7 +87,6 @@
     private TextView mZenSubheadExpanded;
     private View mMoreSettings;
     private LinearLayout mZenConditions;
-    private TextView mAlarmWarning;
 
     private Callback mCallback;
     private ZenModeController mController;
@@ -103,21 +97,21 @@
     private boolean mExpanded;
     private boolean mHidden = false;
     private int mSessionZen;
+    private int mAttachedZen;
     private Condition mSessionExitCondition;
-    private long mNextAlarm;
     private Condition[] mConditions;
     private Condition mTimeCondition;
 
     public ZenModePanel(Context context, AttributeSet attrs) {
         super(context, attrs);
         mContext = context;
-        mFavorites = new Favorites();
+        mPrefs = new Prefs();
         mInflater = LayoutInflater.from(mContext.getApplicationContext());
         mFastOutSlowInInterpolator = AnimationUtils.loadInterpolator(mContext,
                 android.R.interpolator.fast_out_slow_in);
         final Resources res = mContext.getResources();
-        mHardWarningColor = res.getColor(R.color.system_warning_color);
-        mSoftWarningColor = res.getColor(R.color.qs_subhead);
+        mSubheadWarningColor = res.getColor(R.color.system_warning_color);
+        mSubheadColor = res.getColor(R.color.qs_subhead);
         if (DEBUG) Log.d(mTag, "new ZenModePanel");
     }
 
@@ -155,17 +149,16 @@
         });
 
         mZenConditions = (LinearLayout) findViewById(R.id.zen_conditions);
-        mAlarmWarning = (TextView) findViewById(R.id.zen_alarm_warning);
     }
 
     @Override
     protected void onAttachedToWindow() {
         super.onAttachedToWindow();
         if (DEBUG) Log.d(mTag, "onAttachedToWindow");
-        mSessionZen = getSelectedZen(-1);
+        mAttachedZen = getSelectedZen(-1);
+        mSessionZen = mAttachedZen;
         mSessionExitCondition = copy(mExitCondition);
         refreshExitConditionText();
-        refreshNextAlarm();
         updateWidgets();
     }
 
@@ -173,6 +166,8 @@
     protected void onDetachedFromWindow() {
         super.onDetachedFromWindow();
         if (DEBUG) Log.d(mTag, "onDetachedFromWindow");
+        checkForAttachedZenChange();
+        mAttachedZen = -1;
         mSessionZen = -1;
         mSessionExitCondition = null;
         setExpanded(false);
@@ -184,6 +179,17 @@
         updateWidgets();
     }
 
+    private void checkForAttachedZenChange() {
+        final int selectedZen = getSelectedZen(-1);
+        if (DEBUG) Log.d(mTag, "selectedZen=" + selectedZen);
+        if (selectedZen != mAttachedZen) {
+            if (DEBUG) Log.d(mTag, "attachedZen: " + mAttachedZen + " -> " + selectedZen);
+            if (selectedZen == Global.ZEN_MODE_NO_INTERRUPTIONS) {
+                mPrefs.trackNoneSelected();
+            }
+        }
+    }
+
     private void setExpanded(boolean expanded) {
         if (expanded == mExpanded) return;
         mExpanded = expanded;
@@ -206,7 +212,7 @@
                 mBucketIndex = -1;
             } else {
                 mBucketIndex = DEFAULT_BUCKET_INDEX;
-                mTimeCondition = newTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
+                mTimeCondition = ZenModeConfig.toTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
             }
             if (DEBUG) Log.d(mTag, "Initial bucket index: " + mBucketIndex);
             mConditions = null; // reset conditions
@@ -227,6 +233,10 @@
         mController.addCallback(mZenCallback);
     }
 
+    public void updateLocale() {
+        mZenButtons.updateLocale();
+    }
+
     private void setExitCondition(Condition exitCondition) {
         if (sameConditionId(mExitCondition, exitCondition)) return;
         mExitCondition = exitCondition;
@@ -234,10 +244,6 @@
         updateWidgets();
     }
 
-    private Uri getExitConditionId() {
-        return getConditionId(mExitCondition);
-    }
-
     private static Uri getConditionId(Condition condition) {
         return condition != null ? condition.id : null;
     }
@@ -251,7 +257,7 @@
     }
 
     private void refreshExitConditionText() {
-        final String forever = mContext.getString(R.string.zen_mode_forever);
+        final String forever = mContext.getString(com.android.internal.R.string.zen_mode_forever);
         if (mExitCondition == null) {
             mExitConditionText = forever;
         } else if (ZenModeConfig.isValidCountdownConditionId(mExitCondition.id)) {
@@ -301,9 +307,7 @@
         final boolean zenOff = zen == Global.ZEN_MODE_OFF;
         final boolean zenImportant = zen == Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS;
         final boolean zenNone = zen == Global.ZEN_MODE_NO_INTERRUPTIONS;
-        final boolean hasNextAlarm = mNextAlarm != 0;
         final boolean expanded = !mHidden && mExpanded;
-        final boolean showAlarmWarning = zenNone && expanded && hasNextAlarm;
 
         mZenButtons.setVisibility(mHidden ? GONE : VISIBLE);
         mZenSubhead.setVisibility(!mHidden && !zenOff ? VISIBLE : GONE);
@@ -311,26 +315,6 @@
         mZenSubheadCollapsed.setVisibility(!expanded ? VISIBLE : GONE);
         mMoreSettings.setVisibility(zenImportant && expanded ? VISIBLE : GONE);
         mZenConditions.setVisibility(!zenOff && expanded ? VISIBLE : GONE);
-        mAlarmWarning.setVisibility(zenNone && expanded && hasNextAlarm ? VISIBLE : GONE);
-        if (showAlarmWarning) {
-            final long exitTime = ZenModeConfig.tryParseCountdownConditionId(getExitConditionId());
-            final long now = System.currentTimeMillis();
-            final boolean alarmToday = time(mNextAlarm).yearDay == time(now).yearDay;
-            final String skeleton = (alarmToday ? "" : "E")
-                    + (DateFormat.is24HourFormat(mContext) ? "Hm" : "hma");
-            final String pattern = DateFormat.getBestDateTimePattern(Locale.getDefault(), skeleton);
-            final String alarm = new SimpleDateFormat(pattern).format(new Date(mNextAlarm));
-            final boolean isWarning = exitTime > 0 && mNextAlarm > now && mNextAlarm < exitTime;
-            if (isWarning) {
-                mAlarmWarning.setText(mContext.getString(R.string.zen_alarm_warning, alarm));
-                mAlarmWarning.setTextColor(mHardWarningColor);
-            } else {
-                mAlarmWarning.setText(mContext.getString(alarmToday
-                        ? R.string.zen_alarm_information_time
-                        : R.string.zen_alarm_information_day_time, alarm));
-                mAlarmWarning.setTextColor(mSoftWarningColor);
-            }
-        }
 
         if (zenNone) {
             mZenSubheadExpanded.setText(R.string.zen_no_interruptions_with_warning);
@@ -339,12 +323,8 @@
             mZenSubheadExpanded.setText(R.string.zen_important_interruptions);
             mZenSubheadCollapsed.setText(mExitConditionText);
         }
-    }
-
-    private static Time time(long millis) {
-        final Time t = new Time();
-        t.set(millis);
-        return t;
+        mZenSubheadExpanded.setTextColor(zenNone && mPrefs.isNoneDangerous()
+                ? mSubheadWarningColor : mSubheadColor);
     }
 
     private Condition parseExistingTimeCondition(Condition condition) {
@@ -353,33 +333,7 @@
         if (time == 0) return null;
         final long span = time - System.currentTimeMillis();
         if (span <= 0 || span > MAX_BUCKET_MINUTES * MINUTES_MS) return null;
-        return timeCondition(time, Math.round(span / (float)MINUTES_MS));
-    }
-
-    private Condition newTimeCondition(int minutesFromNow) {
-        final long now = System.currentTimeMillis();
-        final long millis = minutesFromNow == 0 ? ZERO_VALUE_MS : minutesFromNow * MINUTES_MS;
-        return timeCondition(now + millis, minutesFromNow);
-    }
-
-    private Condition timeCondition(long time, int minutes) {
-        final int num = minutes < 60 ? minutes : Math.round(minutes / 60f);
-        final int resId = minutes < 60
-                ? R.plurals.zen_mode_duration_minutes
-                : R.plurals.zen_mode_duration_hours;
-        final String caption = mContext.getResources().getQuantityString(resId, num, num);
-        final Uri id = ZenModeConfig.toCountdownConditionId(time);
-        return new Condition(id, caption, "", "", 0, Condition.STATE_TRUE,
-                Condition.FLAG_RELEVANT_NOW);
-    }
-
-    private void refreshNextAlarm() {
-        mNextAlarm = mController.getNextAlarm();
-    }
-
-    private void handleNextAlarmChanged() {
-        refreshNextAlarm();
-        updateWidgets();
+        return ZenModeConfig.toTimeCondition(time, Math.round(span / (float) MINUTES_MS));
     }
 
     private void handleUpdateConditions(Condition[] conditions) {
@@ -429,11 +383,11 @@
             }
         }
         if (DEBUG) Log.d(mTag, "Selecting a default");
-        final int favoriteIndex = mFavorites.getMinuteIndex();
+        final int favoriteIndex = mPrefs.getMinuteIndex();
         if (favoriteIndex == -1) {
             getConditionTagAt(FOREVER_CONDITION_INDEX).rb.setChecked(true);
         } else {
-            mTimeCondition = newTimeCondition(MINUTE_BUCKETS[favoriteIndex]);
+            mTimeCondition = ZenModeConfig.toTimeCondition(MINUTE_BUCKETS[favoriteIndex]);
             mBucketIndex = favoriteIndex;
             bind(mTimeCondition, mZenConditions.getChildAt(TIME_CONDITION_INDEX));
             getConditionTagAt(TIME_CONDITION_INDEX).rb.setChecked(true);
@@ -489,7 +443,7 @@
         });
         final TextView title = (TextView) row.findViewById(android.R.id.title);
         if (condition == null) {
-            title.setText(R.string.zen_mode_forever);
+            title.setText(mContext.getString(com.android.internal.R.string.zen_mode_forever));
         } else {
             title.setText(condition.summary);
         }
@@ -526,7 +480,7 @@
             } else {
                 final long span = time - System.currentTimeMillis();
                 button1.setEnabled(span > MIN_BUCKET_MINUTES * MINUTES_MS);
-                final Condition maxCondition = newTimeCondition(MAX_BUCKET_MINUTES);
+                final Condition maxCondition = ZenModeConfig.toTimeCondition(MAX_BUCKET_MINUTES);
                 button2.setEnabled(!Objects.equals(condition.summary, maxCondition.summary));
             }
 
@@ -552,18 +506,18 @@
                 final long bucketTime = now + bucketMinutes * MINUTES_MS;
                 if (up && bucketTime > time || !up && bucketTime < time) {
                     mBucketIndex = j;
-                    newCondition = timeCondition(bucketTime, bucketMinutes);
+                    newCondition = ZenModeConfig.toTimeCondition(bucketTime, bucketMinutes);
                     break;
                 }
             }
             if (newCondition == null) {
                 mBucketIndex = DEFAULT_BUCKET_INDEX;
-                newCondition = newTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
+                newCondition = ZenModeConfig.toTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
             }
         } else {
             // on a known index, simply increment or decrement
             mBucketIndex = Math.max(0, Math.min(N - 1, mBucketIndex + (up ? 1 : -1)));
-            newCondition = newTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
+            newCondition = ZenModeConfig.toTimeCondition(MINUTE_BUCKETS[mBucketIndex]);
         }
         mTimeCondition = newCondition;
         bind(mTimeCondition, row);
@@ -579,9 +533,9 @@
         }
         setExitCondition(condition);
         if (condition == null) {
-            mFavorites.setMinuteIndex(-1);
+            mPrefs.setMinuteIndex(-1);
         } else if (ZenModeConfig.isValidCountdownConditionId(condition.id) && mBucketIndex != -1) {
-            mFavorites.setMinuteIndex(mBucketIndex);
+            mPrefs.setMinuteIndex(mBucketIndex);
         }
         mSessionExitCondition = copy(condition);
     }
@@ -618,18 +572,12 @@
         public void onExitConditionChanged(Condition exitCondition) {
             mHandler.obtainMessage(H.EXIT_CONDITION_CHANGED, exitCondition).sendToTarget();
         }
-
-        @Override
-        public void onNextAlarmChanged() {
-            mHandler.sendEmptyMessage(H.NEXT_ALARM_CHANGED);
-        }
     };
 
     private final class H extends Handler {
         private static final int UPDATE_CONDITIONS = 1;
         private static final int EXIT_CONDITION_CHANGED = 2;
         private static final int UPDATE_ZEN = 3;
-        private static final int NEXT_ALARM_CHANGED = 4;
 
         private H() {
             super(Looper.getMainLooper());
@@ -643,8 +591,6 @@
                 handleExitConditionChanged((Condition) msg.obj);
             } else if (msg.what == UPDATE_ZEN) {
                 handleUpdateZen(msg.arg1);
-            } else if (msg.what == NEXT_ALARM_CHANGED) {
-                handleNextAlarmChanged();
             }
         }
     }
@@ -661,14 +607,32 @@
         Condition condition;
     }
 
-    private final class Favorites implements OnSharedPreferenceChangeListener {
+    private final class Prefs implements OnSharedPreferenceChangeListener {
         private static final String KEY_MINUTE_INDEX = "minuteIndex";
+        private static final String KEY_NONE_SELECTED = "noneSelected";
+
+        private final int mNoneDangerousThreshold;
 
         private int mMinuteIndex;
+        private int mNoneSelected;
 
-        private Favorites() {
+        private Prefs() {
+            mNoneDangerousThreshold = mContext.getResources()
+                    .getInteger(R.integer.zen_mode_alarm_warning_threshold);
             prefs().registerOnSharedPreferenceChangeListener(this);
             updateMinuteIndex();
+            updateNoneSelected();
+        }
+
+        public boolean isNoneDangerous() {
+            return mNoneSelected < mNoneDangerousThreshold;
+        }
+
+        public void trackNoneSelected() {
+            mNoneSelected = clampNoneSelected(mNoneSelected + 1);
+            if (DEBUG) Log.d(mTag, "Setting none selected: " + mNoneSelected + " threshold="
+                    + mNoneDangerousThreshold);
+            prefs().edit().putInt(KEY_NONE_SELECTED, mNoneSelected).apply();
         }
 
         public int getMinuteIndex() {
@@ -676,9 +640,9 @@
         }
 
         public void setMinuteIndex(int minuteIndex) {
-            minuteIndex = clamp(minuteIndex);
+            minuteIndex = clampIndex(minuteIndex);
             if (minuteIndex == mMinuteIndex) return;
-            mMinuteIndex = clamp(minuteIndex);
+            mMinuteIndex = clampIndex(minuteIndex);
             if (DEBUG) Log.d(mTag, "Setting favorite minute index: " + mMinuteIndex);
             prefs().edit().putInt(KEY_MINUTE_INDEX, mMinuteIndex).apply();
         }
@@ -686,6 +650,7 @@
         @Override
         public void onSharedPreferenceChanged(SharedPreferences prefs, String key) {
             updateMinuteIndex();
+            updateNoneSelected();
         }
 
         private SharedPreferences prefs() {
@@ -693,12 +658,21 @@
         }
 
         private void updateMinuteIndex() {
-            mMinuteIndex = clamp(prefs().getInt(KEY_MINUTE_INDEX, DEFAULT_BUCKET_INDEX));
+            mMinuteIndex = clampIndex(prefs().getInt(KEY_MINUTE_INDEX, DEFAULT_BUCKET_INDEX));
             if (DEBUG) Log.d(mTag, "Favorite minute index: " + mMinuteIndex);
         }
 
-        private int clamp(int index) {
-            return Math.max(-1, Math.min(MINUTE_BUCKETS.length - 1, index));
+        private int clampIndex(int index) {
+            return MathUtils.constrain(index, -1, MINUTE_BUCKETS.length - 1);
+        }
+
+        private void updateNoneSelected() {
+            mNoneSelected = clampNoneSelected(prefs().getInt(KEY_NONE_SELECTED, 0));
+            if (DEBUG) Log.d(mTag, "None selected: " + mNoneSelected);
+        }
+
+        private int clampNoneSelected(int noneSelected) {
+            return MathUtils.constrain(noneSelected, 0, Integer.MAX_VALUE);
         }
     }
 
diff --git a/packages/VpnDialogs/res/drawable-hdpi/ic_vpn_dialog.png b/packages/VpnDialogs/res/drawable-hdpi/ic_vpn_dialog.png
new file mode 100644
index 0000000..a0b4b61
--- /dev/null
+++ b/packages/VpnDialogs/res/drawable-hdpi/ic_vpn_dialog.png
Binary files differ
diff --git a/packages/VpnDialogs/res/drawable-mdpi/ic_vpn_dialog.png b/packages/VpnDialogs/res/drawable-mdpi/ic_vpn_dialog.png
new file mode 100644
index 0000000..df5dfe8
--- /dev/null
+++ b/packages/VpnDialogs/res/drawable-mdpi/ic_vpn_dialog.png
Binary files differ
diff --git a/packages/VpnDialogs/res/drawable-xhdpi/ic_vpn_dialog.png b/packages/VpnDialogs/res/drawable-xhdpi/ic_vpn_dialog.png
new file mode 100644
index 0000000..18d5a3a
--- /dev/null
+++ b/packages/VpnDialogs/res/drawable-xhdpi/ic_vpn_dialog.png
Binary files differ
diff --git a/packages/VpnDialogs/res/drawable-xxhdpi/ic_vpn_dialog.png b/packages/VpnDialogs/res/drawable-xxhdpi/ic_vpn_dialog.png
new file mode 100644
index 0000000..4d475dc
--- /dev/null
+++ b/packages/VpnDialogs/res/drawable-xxhdpi/ic_vpn_dialog.png
Binary files differ
diff --git a/packages/VpnDialogs/res/drawable-xxxhdpi/ic_vpn_dialog.png b/packages/VpnDialogs/res/drawable-xxxhdpi/ic_vpn_dialog.png
new file mode 100644
index 0000000..9d458b4
--- /dev/null
+++ b/packages/VpnDialogs/res/drawable-xxxhdpi/ic_vpn_dialog.png
Binary files differ
diff --git a/packages/VpnDialogs/res/layout/confirm.xml b/packages/VpnDialogs/res/layout/confirm.xml
index ee7f4b8..66fec59 100644
--- a/packages/VpnDialogs/res/layout/confirm.xml
+++ b/packages/VpnDialogs/res/layout/confirm.xml
@@ -18,41 +18,12 @@
 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
         android:layout_width="match_parent"
         android:layout_height="wrap_content">
-    <LinearLayout android:layout_width="match_parent"
+    <TextView android:id="@+id/warning"
+            android:layout_width="fill_parent"
             android:layout_height="wrap_content"
-            android:orientation="vertical"
-            android:padding="3mm">
-
-        <LinearLayout android:layout_width="match_parent"
-                android:layout_height="wrap_content"
-                android:orientation="horizontal"
-                android:gravity="center_vertical">
-
-            <ImageView android:id="@+id/icon"
-                    android:layout_width="@android:dimen/app_icon_size"
-                    android:layout_height="@android:dimen/app_icon_size"
-                    android:paddingRight="1mm"/>
-
-            <TextView android:id="@+id/prompt"
-                    android:layout_width="fill_parent"
-                    android:layout_height="wrap_content"
-                    android:textSize="18sp"/>
-        </LinearLayout>
-
-        <TextView android:id="@+id/warning"
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:paddingTop="1mm"
-                android:paddingBottom="1mm"
-                android:text="@string/warning"
-                android:textSize="18sp"/>
-
-        <CheckBox android:id="@+id/check"
-                android:layout_width="fill_parent"
-                android:layout_height="wrap_content"
-                android:text="@string/accept"
-                android:textSize="20sp"
-                android:filterTouchesWhenObscured="true"
-                android:checked="false"/>
-    </LinearLayout>
+            android:textSize="18sp"
+            android:paddingTop="4mm"
+            android:paddingLeft="3mm"
+            android:paddingRight="3mm"
+            android:paddingBottom="4mm"/>
 </ScrollView>
diff --git a/packages/VpnDialogs/res/layout/manage.xml b/packages/VpnDialogs/res/layout/manage.xml
index 56332c3..6b504e4 100644
--- a/packages/VpnDialogs/res/layout/manage.xml
+++ b/packages/VpnDialogs/res/layout/manage.xml
@@ -43,3 +43,4 @@
     </TableRow>
 
 </TableLayout>
+
diff --git a/packages/VpnDialogs/res/values-af/strings.xml b/packages/VpnDialogs/res/values-af/strings.xml
index 2c23fa3..8c5739c 100644
--- a/packages/VpnDialogs/res/values-af/strings.xml
+++ b/packages/VpnDialogs/res/values-af/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> pogings om \'n VPN-verbinding te skep."</string>
-    <string name="warning" msgid="5470743576660160079">"Deur voort te gaan, gee jy die program toestemming om alle netwerkverkeer te onderskep. "<b>"Moenie aanvaar nie, tensy jy die program vertrou."</b>"Jy loop andersins die risiko dat jou gekompromitteer word deur \'n kwaadwillige sagteware."</string>
-    <string name="accept" msgid="2889226408765810173">"Ek vertrou hierdie program."</string>
+    <string name="prompt" msgid="3183836924226407828">"Verbindingversoek"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> wil \'n VPN-verbinding opstel wat dit sal toelaat om netwerkverkeer te monitor. Aanvaar dit net as jy die bron vertrou. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; verskyn boaan jou skerm as VPN aktief is."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN is gekoppel"</string>
     <string name="configure" msgid="4905518375574791375">"Stel op"</string>
     <string name="disconnect" msgid="971412338304200056">"Ontkoppel"</string>
diff --git a/packages/VpnDialogs/res/values-am/strings.xml b/packages/VpnDialogs/res/values-am/strings.xml
index a305e30..e6fc112 100644
--- a/packages/VpnDialogs/res/values-am/strings.xml
+++ b/packages/VpnDialogs/res/values-am/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> የ VPN ተያያዥ ለመፍጠር ሞክሯል።"</string>
-    <string name="warning" msgid="5470743576660160079">"በማስከተል፣ መተግበሪያው ሁሉንም የአውታረ መረብ ትራፊክ እንዲያጨናግፍ ፈቃድ እየሰጡ ነው።"<b>"  መተግበሪያውን ካላመኑት አይቀበሉ።"</b>"  አለበለዚያ፣ ውሂብዎ በተንኮል አዘል ሶፍትዌር ስጋት ውስጥ ይገኛል።"</string>
-    <string name="accept" msgid="2889226408765810173">"ይህን መተግበሪያ አምናለሁ"</string>
+    <string name="prompt" msgid="3183836924226407828">"የግንኙነት ጥያቄ"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> የአውታረ መረብ መከታተል የሚያስችል የVPN ግንኑነት ማዋቀር ይፈልጋል። ምንጩን የሚያምኑት ብቻ ከሆኑ ይቀበሉ። &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; VPN ገቢር ሲሆን በማያ ገጽዎ ላይኛው ክፍል ላይ ይታያል።"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN ተያይዟል"</string>
     <string name="configure" msgid="4905518375574791375">"አዋቅር"</string>
     <string name="disconnect" msgid="971412338304200056">"አለያይ"</string>
diff --git a/packages/VpnDialogs/res/values-ar/strings.xml b/packages/VpnDialogs/res/values-ar/strings.xml
index bf83a41..d29c407 100644
--- a/packages/VpnDialogs/res/values-ar/strings.xml
+++ b/packages/VpnDialogs/res/values-ar/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"‏يحاول <xliff:g id="APP">%s</xliff:g> إنشاء اتصال شبكة ظاهرية خاصة (VPN)."</string>
-    <string name="warning" msgid="5470743576660160079">"تعد المتابعة بمثابة إذن للتطبيق باعتراض جميع حركات مرور البيانات عبر الشبكة. "<b>"\"لا\" توافق إلا إذا كنت تثق في التطبيق."</b>" وإلا فقد تتعرض بياناتك لخطورة الاختراق بواسطة برامج ضارة."</string>
-    <string name="accept" msgid="2889226408765810173">"أثق في هذا التطبيق."</string>
+    <string name="prompt" msgid="3183836924226407828">"طلب الاتصال"</string>
+    <string name="warning" msgid="809658604548412033">"‏يريد <xliff:g id="APP">%s</xliff:g> إعداد الاتصال بالشبكة الظاهرية الخاصة التي تتيح له مراقبة حركة المرور على الشبكة. فلا توافق إلا إذا كنت تثق في المصدر. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; يظهر في الجزء العلوي من الشاشة عندما تكون الشبكة الظاهرية الخاصة نشطة."</string>
     <string name="legacy_title" msgid="192936250066580964">"‏VPN متصلة"</string>
     <string name="configure" msgid="4905518375574791375">"تهيئة"</string>
     <string name="disconnect" msgid="971412338304200056">"قطع الاتصال"</string>
diff --git a/packages/VpnDialogs/res/values-bg/strings.xml b/packages/VpnDialogs/res/values-bg/strings.xml
index 7ecfac7..d7b265f 100644
--- a/packages/VpnDialogs/res/values-bg/strings.xml
+++ b/packages/VpnDialogs/res/values-bg/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> прави опит за създаване на връзка с VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"С продължаването си давате на приложението разрешение да прехваща целия трафик от мрежата. "<b>"НЕ приемайте, ако нямате доверие на приложението."</b>" В противен случай съществува риск от компрометиране на данните ви от злонамерен софтуер."</string>
-    <string name="accept" msgid="2889226408765810173">"Имам доверие на това приложение."</string>
+    <string name="prompt" msgid="3183836924226407828">"Заявка за свързване"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> иска да настрои връзка с виртуална частна мрежа (VPN), за да може да наблюдава мрежовия трафик. Приемете само ако източникът е надежден. Иконата &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; се показва в долната част на екрана при активирана VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN е свързана"</string>
     <string name="configure" msgid="4905518375574791375">"Конфигуриране"</string>
     <string name="disconnect" msgid="971412338304200056">"Изключване"</string>
diff --git a/packages/VpnDialogs/res/values-bn-rBD/strings.xml b/packages/VpnDialogs/res/values-bn-rBD/strings.xml
index 32eed55..90ce36e 100644
--- a/packages/VpnDialogs/res/values-bn-rBD/strings.xml
+++ b/packages/VpnDialogs/res/values-bn-rBD/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> একটি VPN সংযোগ স্থাপনের চেষ্টা করছে৷"</string>
-    <string name="warning" msgid="5470743576660160079">"চালিয়ে যাওয়ার মাধ্যমে, আপনি অ্যাপ্লিকেশানটিকে সমস্ত নেটওয়ার্ক ট্রাফিক বিচ্ছিন্ন করার অনুমতি প্রদান করছেন৷ "<b>"যদি আপনি অ্যাপ্লিকেশানটিকে বিশ্বাস না করেন তবে স্বীকার করবেন না৷"</b>" অন্যথায় আপনার ডেটা একটি ক্ষতিকারক সফ্টওয়্যারের দ্বারা কোনো বাজে লোকের হাতে চলে যাওয়ার ঝুঁকি থেকে যায়৷"</string>
-    <string name="accept" msgid="2889226408765810173">"আমি এই অ্যাপ্লিকেশানটিকে বিশ্বাস করি৷"</string>
+    <string name="prompt" msgid="3183836924226407828">"সংযোগের অনুরোধ"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> এমন একটি VPN সংযোগ সেট আপ করতে চাচ্ছে যেটি দিয়ে এটি নেটওয়ার্ক ট্রাফিক নিরীক্ষণ করতে পারবে। আপনি যদি উৎসটিকে বিশ্বাস করেন, তাহলেই কেবল এতে সম্মতি দিন। VPN সক্রিয় থাকলে আপনার স্ক্রীনের উপরে &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; দেখা যাবে।"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN সংযুক্ত হয়েছে"</string>
     <string name="configure" msgid="4905518375574791375">"কনফিগার করুন"</string>
     <string name="disconnect" msgid="971412338304200056">"সংযোগ বিচ্ছিন্ন করুন"</string>
diff --git a/packages/VpnDialogs/res/values-ca/strings.xml b/packages/VpnDialogs/res/values-ca/strings.xml
index e5332e0..ab6b50a 100644
--- a/packages/VpnDialogs/res/values-ca/strings.xml
+++ b/packages/VpnDialogs/res/values-ca/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> intents de crear una connexió VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Si continues, dónes permís a l\'aplicació per interceptar tot el trànsit de la xarxa. "<b>"NO ho acceptis si no confies en l\'aplicació."</b>"Si no és així, corres el risc que les teves dades estiguin en perill davant d\'un programari maliciós."</string>
-    <string name="accept" msgid="2889226408765810173">"Confio en aquesta aplicació."</string>
+    <string name="prompt" msgid="3183836924226407828">"Sol·licitud de connexió"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vol configurar una connexió VPN que li permeti controlar el trànsit de xarxa. Accepta la sol·licitud només si prové d\'una font de confiança. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; es mostra a la part superior de la pantalla quan la VPN està activada."</string>
     <string name="legacy_title" msgid="192936250066580964">"La VPN està connectada"</string>
     <string name="configure" msgid="4905518375574791375">"Configura"</string>
     <string name="disconnect" msgid="971412338304200056">"Desconnecta"</string>
diff --git a/packages/VpnDialogs/res/values-cs/strings.xml b/packages/VpnDialogs/res/values-cs/strings.xml
index 28e861f..4f830fb 100644
--- a/packages/VpnDialogs/res/values-cs/strings.xml
+++ b/packages/VpnDialogs/res/values-cs/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Aplikace <xliff:g id="APP">%s</xliff:g> se pokouší připojit k síti VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Pokračováním souhlasíte s tím, aby aplikace sledovala veškerou vaši síťovou aktivitu. "<b>" Pokud aplikaci nevěříte, nepokračujte."</b>" V opačném případě riskujete vystavení svých dat škodlivému softwaru."</string>
-    <string name="accept" msgid="2889226408765810173">"Této aplikaci věřím."</string>
+    <string name="prompt" msgid="3183836924226407828">"Žádost o připojení"</string>
+    <string name="warning" msgid="809658604548412033">"Aplikace <xliff:g id="APP">%s</xliff:g> žádá o nastavení připojení VPN, pomocí kterého bude moci sledovat síťový provoz. Povolte, jen pokud zdroji důvěřujete. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; – když je síť VPN aktivní, v horní části obrazovky se zobrazuje tato ikona."</string>
     <string name="legacy_title" msgid="192936250066580964">"Síť VPN je připojena"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurovat"</string>
     <string name="disconnect" msgid="971412338304200056">"Odpojit"</string>
diff --git a/packages/VpnDialogs/res/values-da/strings.xml b/packages/VpnDialogs/res/values-da/strings.xml
index a226d0e..804982d 100644
--- a/packages/VpnDialogs/res/values-da/strings.xml
+++ b/packages/VpnDialogs/res/values-da/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> forsøger at oprette en VPN-forbindelse."</string>
-    <string name="warning" msgid="5470743576660160079">"Hvis du fortsætter, giver du applikationen tilladelse til at opfange al netværkstrafik. "<b>"Du skal ikke acceptere, medmindre du har tillid til applikationen."</b>" Ellers risikerer du at få dine data kompromitteret af ondsindet software."</string>
-    <string name="accept" msgid="2889226408765810173">"Jeg har tillid til denne applikation."</string>
+    <string name="prompt" msgid="3183836924226407828">"Forbindelsesanmodning"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vil konfigurere en VPN-forbindelse, der giver appen mulighed for at registrere netværkstrafik. Du bør kun acceptere dette, hvis du har tillid til kilden. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; vises øverst på din skærm, når VPN-forbindelsen er aktiv."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN er tilsluttet"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurer"</string>
     <string name="disconnect" msgid="971412338304200056">"Fjern tilknytning"</string>
diff --git a/packages/VpnDialogs/res/values-de/strings.xml b/packages/VpnDialogs/res/values-de/strings.xml
index 124a985..168937b 100644
--- a/packages/VpnDialogs/res/values-de/strings.xml
+++ b/packages/VpnDialogs/res/values-de/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> versucht, eine VPN-Verbindung zu erstellen."</string>
-    <string name="warning" msgid="5470743576660160079">"Wenn Sie fortfahren, gestatten Sie der App, den gesamten Netzwerkverkehr abzufangen. "<b>"Akzeptieren Sie nur, wenn Sie der App vertrauen."</b>" Anderenfalls riskieren Sie, dass Ihre Daten von schädlicher Software manipuliert werden."</string>
-    <string name="accept" msgid="2889226408765810173">"Ich vertraue dieser App."</string>
+    <string name="prompt" msgid="3183836924226407828">"Verbindungsanfrage"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> möchte eine VPN-Verbindung herstellen, über die der Netzwerkverkehr überwacht werden kann. Lassen Sie die Verbindung nur zu, wenn die App vertrauenswürdig ist. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; wird oben am Display angezeigt, wenn VPN aktiv ist."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN ist verbunden"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurieren"</string>
     <string name="disconnect" msgid="971412338304200056">"Verbindung trennen"</string>
diff --git a/packages/VpnDialogs/res/values-el/strings.xml b/packages/VpnDialogs/res/values-el/strings.xml
index 5aefde4..97b4407 100644
--- a/packages/VpnDialogs/res/values-el/strings.xml
+++ b/packages/VpnDialogs/res/values-el/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Η εφαρμογή <xliff:g id="APP">%s</xliff:g> επιχειρεί να δημιουργήσει μια σύνδεση VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Αν συνεχίσετε, θα παραχωρήσετε στην εφαρμογή την άδεια να παρεμβάλλεται σε όλη την κυκλοφορία του δικτύου. "<b>"ΜΗΝ αποδεχθείτε, εκτός και αν θεωρείτε την εφαρμογή αξιόπιστη."</b>" Διαφορετικά, διατρέχετε τον κίνδυνο παραβίασης των δεδομένων σας από κακόβουλο λογισμικό."</string>
-    <string name="accept" msgid="2889226408765810173">"Θεωρώ αυτήν την εφαρμογή αξιόπιστη."</string>
+    <string name="prompt" msgid="3183836924226407828">"Αίτημα σύνδεσης"</string>
+    <string name="warning" msgid="809658604548412033">"Η εφαρμογή <xliff:g id="APP">%s</xliff:g> επιθυμεί να ρυθμίσει μια σύνδεση VPN που της επιτρέπει να παρακολουθεί την επισκεψιμότητα του δικτύου. Αποδεχτείτε το αίτημα μόνο εάν εμπιστεύεστε την πηγή. Το εικονίδιο &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; εμφανίζεται στο επάνω μέρος της οθόνης σας όταν είναι ενεργό το VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"Το VPN συνδέθηκε"</string>
     <string name="configure" msgid="4905518375574791375">"Διαμόρφωση"</string>
     <string name="disconnect" msgid="971412338304200056">"Αποσύνδεση"</string>
diff --git a/packages/VpnDialogs/res/values-en-rGB/strings.xml b/packages/VpnDialogs/res/values-en-rGB/strings.xml
index afc46d8..2c93c78 100644
--- a/packages/VpnDialogs/res/values-en-rGB/strings.xml
+++ b/packages/VpnDialogs/res/values-en-rGB/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> attempts to create a VPN connection."</string>
-    <string name="warning" msgid="5470743576660160079">"By proceeding, you are giving the application permission to intercept all network traffic. "<b>"Do NOT accept unless you trust the application."</b>" Otherwise, you run the risk of having your data compromised by malicious software."</string>
-    <string name="accept" msgid="2889226408765810173">"I trust this application."</string>
+    <string name="prompt" msgid="3183836924226407828">"Connection request"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> wants to set up a VPN connection that allows it to monitor network traffic. Only accept if you trust the source. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; appears at the top of your screen when VPN is active."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN is connected"</string>
     <string name="configure" msgid="4905518375574791375">"Configure"</string>
     <string name="disconnect" msgid="971412338304200056">"Disconnect"</string>
diff --git a/packages/VpnDialogs/res/values-en-rIN/strings.xml b/packages/VpnDialogs/res/values-en-rIN/strings.xml
index afc46d8..2c93c78 100644
--- a/packages/VpnDialogs/res/values-en-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-en-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> attempts to create a VPN connection."</string>
-    <string name="warning" msgid="5470743576660160079">"By proceeding, you are giving the application permission to intercept all network traffic. "<b>"Do NOT accept unless you trust the application."</b>" Otherwise, you run the risk of having your data compromised by malicious software."</string>
-    <string name="accept" msgid="2889226408765810173">"I trust this application."</string>
+    <string name="prompt" msgid="3183836924226407828">"Connection request"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> wants to set up a VPN connection that allows it to monitor network traffic. Only accept if you trust the source. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; appears at the top of your screen when VPN is active."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN is connected"</string>
     <string name="configure" msgid="4905518375574791375">"Configure"</string>
     <string name="disconnect" msgid="971412338304200056">"Disconnect"</string>
diff --git a/packages/VpnDialogs/res/values-es-rUS/strings.xml b/packages/VpnDialogs/res/values-es-rUS/strings.xml
index 4276065..8f0a050 100644
--- a/packages/VpnDialogs/res/values-es-rUS/strings.xml
+++ b/packages/VpnDialogs/res/values-es-rUS/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> intenta crear una conexión VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Al proceder, le estás dando permiso a la aplicación para interceptar todo el tráfico de red. "<b>"NO aceptes a menos que confíes en la aplicación."</b>" De lo contrario, corres el riesgo de que tus datos se vean comprometidos debido a un software malicioso."</string>
-    <string name="accept" msgid="2889226408765810173">"Confío en esta aplicación."</string>
+    <string name="prompt" msgid="3183836924226407828">"Solicitud de conexión"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> quiere configurar una conexión VPN que permite controlar el tráfico de la red. Acéptala solo si confías en la fuente. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; aparece en la parte superior de la pantalla cuando la VPN está activa."</string>
     <string name="legacy_title" msgid="192936250066580964">"La VPN está conectada."</string>
     <string name="configure" msgid="4905518375574791375">"Configurar"</string>
     <string name="disconnect" msgid="971412338304200056">"Desconectar"</string>
diff --git a/packages/VpnDialogs/res/values-es/strings.xml b/packages/VpnDialogs/res/values-es/strings.xml
index 272042a..cc50abe 100644
--- a/packages/VpnDialogs/res/values-es/strings.xml
+++ b/packages/VpnDialogs/res/values-es/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"La aplicación <xliff:g id="APP">%s</xliff:g> intenta crear una conexión VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Si continúas, la aplicación podrá interceptar todo el tráfico de red. "<b>"Si no confías en la aplicación, NO debes instalarla."</b>" En caso contrario, te arriesgas a que el software malintencionado intercepte tus datos."</string>
-    <string name="accept" msgid="2889226408765810173">"Confío en esta aplicación."</string>
+    <string name="prompt" msgid="3183836924226407828">"Solicitud de conexión"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> quiere configurar una conexión VPN para controlar el tráfico de red. Solo debes aceptarla si confías en la fuente. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; aparece en la parte superior de la pantalla cuando se active la conexión VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN conectada"</string>
     <string name="configure" msgid="4905518375574791375">"Configurar"</string>
     <string name="disconnect" msgid="971412338304200056">"Desconectar"</string>
diff --git a/packages/VpnDialogs/res/values-et-rEE/strings.xml b/packages/VpnDialogs/res/values-et-rEE/strings.xml
index c016eb0..ee8f769 100644
--- a/packages/VpnDialogs/res/values-et-rEE/strings.xml
+++ b/packages/VpnDialogs/res/values-et-rEE/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Rakenduse <xliff:g id="APP">%s</xliff:g> katsed luua VPN-ühendust."</string>
-    <string name="warning" msgid="5470743576660160079">"Jätkates annate rakendusele loa jälgida kogu võrguliiklust. "<b>"ÄRGE nõustuge, kui te seda rakendust ei usalda."</b>" Vastasel juhul on oht, et pahavara võib kahjustada teie andmeid."</string>
-    <string name="accept" msgid="2889226408765810173">"Usaldan seda rakendust."</string>
+    <string name="prompt" msgid="3183836924226407828">"Ühendamise taotlus"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> tahab seadistada VPN-i ühenduse, mis võimaldab jälgida võrguliiklust. Nõustuge ainult siis, kui usaldate seda allikat. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; kuvatakse ekraani ülaservas, kui VPN on aktiivne."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN on ühendatud"</string>
     <string name="configure" msgid="4905518375574791375">"Seadistamine"</string>
     <string name="disconnect" msgid="971412338304200056">"Katkesta ühendus"</string>
diff --git a/packages/VpnDialogs/res/values-eu-rES/strings.xml b/packages/VpnDialogs/res/values-eu-rES/strings.xml
index b697391..b716509 100644
--- a/packages/VpnDialogs/res/values-eu-rES/strings.xml
+++ b/packages/VpnDialogs/res/values-eu-rES/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> aplikazioak VPN konexioa sortu nahi du."</string>
-    <string name="warning" msgid="5470743576660160079">"Aurrera jarraitzen baduzu, aplikazioari sareko trafiko guztia atzemateko baimena emango diozu. "<b>"EZ onartu aplikazioa fidagarria ez bada."</b>" Bestela, datuak programa gaizto baten eskuetan jartzeko arriskua duzu."</string>
-    <string name="accept" msgid="2889226408765810173">"Aplikazioa fidagarria da."</string>
+    <string name="prompt" msgid="3183836924226407828">"Konektatzeko eskaera"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> aplikazioak VPN bidezko konexioa ezarri nahi du sareko trafikoa kontrolatzeko. Iturburua fidagarria bada bakarrik baimendu. &lt;br /&gt; &lt;br /&gt; VPN konexioa aktibo dagoenean, &lt;img src=vpn_icon /&gt; agertuko da pantailaren goialdean."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN sarera konektatuta dago"</string>
     <string name="configure" msgid="4905518375574791375">"Konfiguratu"</string>
     <string name="disconnect" msgid="971412338304200056">"Deskonektatu"</string>
diff --git a/packages/VpnDialogs/res/values-fa/strings.xml b/packages/VpnDialogs/res/values-fa/strings.xml
index 7c0aafe..7b17f42 100644
--- a/packages/VpnDialogs/res/values-fa/strings.xml
+++ b/packages/VpnDialogs/res/values-fa/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"‏<xliff:g id="APP">%s</xliff:g> تلاش می‌کند یک اتصال VPN ایجاد کند."</string>
-    <string name="warning" msgid="5470743576660160079">"با ادامه دادن، به برنامهٔ کاربردی اجازه می‌دهید تمام ترافیک شبکه را رهگیری کند. "<b>"تا به برنامه اعتماد نکردید آن را قبول نکنید."</b>" در غیر این صورت، این ریسک را قبول می‌کنید که داده‌های شما توسط یک نرم‌افزار مخرب به خطر بیفتد."</string>
-    <string name="accept" msgid="2889226408765810173">"من به این برنامه اعتماد دارم."</string>
+    <string name="prompt" msgid="3183836924226407828">"درخواست اتصال"</string>
+    <string name="warning" msgid="809658604548412033">"‏<xliff:g id="APP">%s</xliff:g> می‌خواهد یک اتصال VPN راه‌اندازی کند که به آن امکان نظارت بر ترافیک شبکه را می‌دهد. فقط در صورتی بپذیرید که به منبع آن اطمینان دارید. هنگامی که VPN فعال شد، &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; در بالای صفحه نمایش شما نشان داده می‌شود."</string>
     <string name="legacy_title" msgid="192936250066580964">"‏VPN متصل است"</string>
     <string name="configure" msgid="4905518375574791375">"پیکربندی"</string>
     <string name="disconnect" msgid="971412338304200056">"قطع اتصال"</string>
diff --git a/packages/VpnDialogs/res/values-fi/strings.xml b/packages/VpnDialogs/res/values-fi/strings.xml
index 2ca550d..23fae48 100644
--- a/packages/VpnDialogs/res/values-fi/strings.xml
+++ b/packages/VpnDialogs/res/values-fi/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> yrittää luoda VPN-yhteyden."</string>
-    <string name="warning" msgid="5470743576660160079">"Jos jatkat, annat sovellukselle luvan seurata kaikkea verkkoliikennettä. "<b>"ÄLÄ hyväksy ellet luota sovellukseen."</b>"Muuten haittaohjelmat voivat vaarantaa tietosi."</string>
-    <string name="accept" msgid="2889226408765810173">"Luotan tähän sovellukseen."</string>
+    <string name="prompt" msgid="3183836924226407828">"Yhteyspyyntö"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> haluaa tehdä asetukset VPN-yhteydellä, jonka kautta sovellus voi valvoa verkkoliikennettä. Hyväksy vain, jos lähde on luotettava. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; näkyy ruudun yläreunassa, kun VPN on käytössä."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN on yhdistetty"</string>
     <string name="configure" msgid="4905518375574791375">"Asetukset"</string>
     <string name="disconnect" msgid="971412338304200056">"Katkaise yhteys"</string>
diff --git a/packages/VpnDialogs/res/values-fr-rCA/strings.xml b/packages/VpnDialogs/res/values-fr-rCA/strings.xml
index 1028f83..83aef21 100644
--- a/packages/VpnDialogs/res/values-fr-rCA/strings.xml
+++ b/packages/VpnDialogs/res/values-fr-rCA/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tente de créer une connexion VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"En continuant, vous autorisez l\'application à intercepter l\'ensemble du trafic réseau. "<b>"N\'acceptez PAS, sauf si vous avez confiance en l\'application."</b>"Sinon, vos données risquent d\'être piratées par un logiciel malveillant."</string>
-    <string name="accept" msgid="2889226408765810173">"J\'ai confiance en cette application."</string>
+    <string name="prompt" msgid="3183836924226407828">"Demande de connexion"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> veut configurer une connexion RPV qui permet de surveiller le trafic réseau. N\'acceptez que si vous faites confiance à la source. &lt;br /&gt;&lt;br /&gt;&lt;img src=vpn_icon/&gt; s\'affiche dans le haut de votre écran lorsqu\'une connexion  RPV est active."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN connecté"</string>
     <string name="configure" msgid="4905518375574791375">"Configurer"</string>
     <string name="disconnect" msgid="971412338304200056">"Déconnecter"</string>
diff --git a/packages/VpnDialogs/res/values-fr/strings.xml b/packages/VpnDialogs/res/values-fr/strings.xml
index 64334fd..dadb864 100644
--- a/packages/VpnDialogs/res/values-fr/strings.xml
+++ b/packages/VpnDialogs/res/values-fr/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tente de créer une connexion VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"En continuant, vous autorisez l\'application à intercepter l\'ensemble du trafic réseau. "<b>"N\'acceptez PAS, sauf si vous avez confiance en l\'application."</b>"Sinon, vos données risquent d\'être piratées par un logiciel malveillant."</string>
-    <string name="accept" msgid="2889226408765810173">"J\'ai confiance en cette application."</string>
+    <string name="prompt" msgid="3183836924226407828">"Demande de connexion"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> souhaite configurer une connexion VPN qui permet de surveiller le trafic réseau. N\'acceptez que si vous faites confiance à la source. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; s\'affiche en haut de votre écran lorsqu\'une connexion VPN est active."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN connecté"</string>
     <string name="configure" msgid="4905518375574791375">"Configurer"</string>
     <string name="disconnect" msgid="971412338304200056">"Déconnecter"</string>
diff --git a/packages/VpnDialogs/res/values-gl-rES/strings.xml b/packages/VpnDialogs/res/values-gl-rES/strings.xml
index 078aeb6..40f54fc 100644
--- a/packages/VpnDialogs/res/values-gl-rES/strings.xml
+++ b/packages/VpnDialogs/res/values-gl-rES/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tenta crear unha conexión VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Se continúas, concederaslle permiso á aplicación para interceptar todo o tráfico de rede. "<b>"NON aceptes a menos que confíes na aplicación."</b>" Do contrario, arríscaste a que os teus datos queden expostos a software malicioso."</string>
-    <string name="accept" msgid="2889226408765810173">"Confío nesta aplicación."</string>
+    <string name="prompt" msgid="3183836924226407828">"Solicitude de conexión"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> quere configurar unha conexión VPN que lle permite controlar o tráfico da rede. Acepta soamente se confías na fonte. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; aparece na parte superior da pantalla cando se activa a VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"A VPN está conectada"</string>
     <string name="configure" msgid="4905518375574791375">"Configurar"</string>
     <string name="disconnect" msgid="971412338304200056">"Desconectar"</string>
diff --git a/packages/VpnDialogs/res/values-hi/strings.xml b/packages/VpnDialogs/res/values-hi/strings.xml
index b570a6d..15f69c6 100644
--- a/packages/VpnDialogs/res/values-hi/strings.xml
+++ b/packages/VpnDialogs/res/values-hi/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> एक VPN कनेक्‍शन बनाने का प्रयास करता है."</string>
-    <string name="warning" msgid="5470743576660160079">"जारी रखकर, आप ऐप्स  को सभी नेटवर्क ट्रैफ़िक अवरोधित करने की अनुमति देते हैं. "<b>"जब तक आपको ऐप्स  पर विश्वास न हो स्‍वीकार न करें."</b>" अन्‍यथा, आपको अपने डेटा के साथ किसी दुर्भावनापूर्ण सॉफ़्टवेयर द्वारा छेड़छाड़ किए जाने का जोखिम हो सकता है."</string>
-    <string name="accept" msgid="2889226408765810173">"मुझे इस ऐप्स  पर विश्वास है."</string>
+    <string name="prompt" msgid="3183836924226407828">"कनेक्शन अनुरोध"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> VPN कनेक्‍शन सेट करना चाहता है जो उसे नेटवर्क ट्रैफ़िक मॉनीटर करने देता है. केवल तभी स्‍वीकार करें, जबकि आप स्रोत पर विश्वास करते हों. VPN सक्रिय होने पर आपकी स्‍क्रीन पर ऊपर &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; दिखाई देता है."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN कनेक्‍ट है"</string>
     <string name="configure" msgid="4905518375574791375">"कॉन्फ़िगर करें"</string>
     <string name="disconnect" msgid="971412338304200056">"डिस्‍कनेक्‍ट करें"</string>
diff --git a/packages/VpnDialogs/res/values-hr/strings.xml b/packages/VpnDialogs/res/values-hr/strings.xml
index f825bef..d58319d 100644
--- a/packages/VpnDialogs/res/values-hr/strings.xml
+++ b/packages/VpnDialogs/res/values-hr/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> pokušava stvoriti VPN vezu."</string>
-    <string name="warning" msgid="5470743576660160079">"Ako nastavite, dajete aplikaciji dopuštenje da presretne sav mrežni promet. "<b>"NEMOJTE prihvatiti osim ako nemate povjerenje u aplikaciju."</b>" Inače riskirate da vaše podatke ugrozi zlonamjerni softver."</string>
-    <string name="accept" msgid="2889226408765810173">"Vjerujem u ovu aplikaciju."</string>
+    <string name="prompt" msgid="3183836924226407828">"Zahtjev za povezivanje"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> želi postaviti VPN vezu pomoću koje će moći nadzirati mrežni promet. Prihvatite samo ako smatrate izvor pouzdanim. Kada je VPN aktivan, pri vrhu zaslona prikazuje se &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN je spojen"</string>
     <string name="configure" msgid="4905518375574791375">"Konfiguriraj"</string>
     <string name="disconnect" msgid="971412338304200056">"Prekini vezu"</string>
diff --git a/packages/VpnDialogs/res/values-hu/strings.xml b/packages/VpnDialogs/res/values-hu/strings.xml
index cb12f27..2ffdff8 100644
--- a/packages/VpnDialogs/res/values-hu/strings.xml
+++ b/packages/VpnDialogs/res/values-hu/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"A(z) <xliff:g id="APP">%s</xliff:g> megpróbál létrehozni egy VPN-kapcsolatot."</string>
-    <string name="warning" msgid="5470743576660160079">"A folytatással engedélyt ad az alkalmazásnak a hálózati adatforgalom elfogására. "<b>"Csak akkor fogadja el, ha megbízik az alkalmazásban. "</b>"Ellenkező esetben fennállhat annak a kockázata, hogy egy rosszindulatú program feltöri adatait."</string>
-    <string name="accept" msgid="2889226408765810173">"Bízom ebben az alkalmazásban."</string>
+    <string name="prompt" msgid="3183836924226407828">"Kapcsolódási kérés"</string>
+    <string name="warning" msgid="809658604548412033">"A(z) <xliff:g id="APP">%s</xliff:g> VPN kapcsolatot akar beállítani, amelynek segítségével figyelheti a hálózati forgalmat. Csak akkor fogadja el, ha megbízik a forrásban. &lt;br /&gt; &lt;br /&gt; Amikor a VPN aktív, &lt;img src=vpn_icon /&gt; ikon jelenik meg a képernyő tetején."</string>
     <string name="legacy_title" msgid="192936250066580964">"A VPN csatlakoztatva van"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurálás"</string>
     <string name="disconnect" msgid="971412338304200056">"Kapcsolat bontása"</string>
diff --git a/packages/VpnDialogs/res/values-hy-rAM/strings.xml b/packages/VpnDialogs/res/values-hy-rAM/strings.xml
index 85db579..2a27a93 100644
--- a/packages/VpnDialogs/res/values-hy-rAM/strings.xml
+++ b/packages/VpnDialogs/res/values-hy-rAM/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>-ը փորձում է ստեղծել VPN կապ:"</string>
-    <string name="warning" msgid="5470743576660160079">"Շարունակելով` դուք հավելվածին թույլատրում եք կանգնեցնել ամբողջ ցանցային շարժը: "<b>"Մի ընդունեք, եթե չեք վստահում հավելվածին:"</b>" Այլապես ռիսկ կա ձեր տվյալները վտանգելու վնասարար հավելվածների կողմից:"</string>
-    <string name="accept" msgid="2889226408765810173">"Ես վստահում եմ այս ծրագրին:"</string>
+    <string name="prompt" msgid="3183836924226407828">"Միացման հայց"</string>
+    <string name="warning" msgid="809658604548412033">"«<xliff:g id="APP">%s</xliff:g>» հավելվածը ցանկանում է VPN կապ հաստատել՝ ցանցային երթևեկը հսկելու համար: Թույլատրեք, միայն եթե վստահում եք աղբյուրին: Երբ VPN-ն ակտիվ լինի, ձեր էկրանի վերին հատվածում կհայտնվի &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; պատկերը:"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN-ը կապակցված է"</string>
     <string name="configure" msgid="4905518375574791375">"Կարգավորել"</string>
     <string name="disconnect" msgid="971412338304200056">"Անջատել"</string>
diff --git a/packages/VpnDialogs/res/values-in/strings.xml b/packages/VpnDialogs/res/values-in/strings.xml
index 1b5d03a..5553d70 100644
--- a/packages/VpnDialogs/res/values-in/strings.xml
+++ b/packages/VpnDialogs/res/values-in/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> mencoba membuat sambungan VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Dengan melanjutkan, Anda memberikan izin kepada aplikasi untuk mencegat semua lalu lintas jaringan. "<b>"JANGAN memberi izin kecuali Anda mempercayai aplikasi ini."</b>" Jika tidak, data Anda berisiko disusupi oleh perangkat lunak perusak."</string>
-    <string name="accept" msgid="2889226408765810173">"Saya mempercayai aplikasi ini."</string>
+    <string name="prompt" msgid="3183836924226407828">"Permintaan sambungan"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ingin menyiapkan sambungan VPN yang memungkinkannya memantau lalu-lintas jaringan. Terima hanya jika Anda memercayai sumber. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; muncul di bagian atas layar Anda saat VPN aktif."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN tersambung"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurasikan"</string>
     <string name="disconnect" msgid="971412338304200056">"Putuskan sambungan"</string>
diff --git a/packages/VpnDialogs/res/values-is-rIS/strings.xml b/packages/VpnDialogs/res/values-is-rIS/strings.xml
index a6c7215..059c6a9 100644
--- a/packages/VpnDialogs/res/values-is-rIS/strings.xml
+++ b/packages/VpnDialogs/res/values-is-rIS/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tilraunir til að koma á VPN-tengingu."</string>
-    <string name="warning" msgid="5470743576660160079">"Með því að halda áfram veitir þú forritinu heimild til að grípa inn í alla gagnaumferð. "<b>"EKKI leyfa þetta nema þú treystir forritinu."</b>" Annars hættir þú á að spilliforrit stofni gögnunum þínum í hættu."</string>
-    <string name="accept" msgid="2889226408765810173">"Ég treysti þessu forriti."</string>
+    <string name="prompt" msgid="3183836924226407828">"Beiðni um tengingu"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vill setja upp VPN-tengingu til þess að geta fylgst með netumferð. Samþykktu þetta aðeins ef þú treystir upprunanum. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; birtist efst á skjánum þegar VPN er virkt."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN er tengt"</string>
     <string name="configure" msgid="4905518375574791375">"Stilla"</string>
     <string name="disconnect" msgid="971412338304200056">"Aftengja"</string>
diff --git a/packages/VpnDialogs/res/values-it/strings.xml b/packages/VpnDialogs/res/values-it/strings.xml
index 224f083..e601a5f 100644
--- a/packages/VpnDialogs/res/values-it/strings.xml
+++ b/packages/VpnDialogs/res/values-it/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tenta di creare una connessione VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Se procedi, concedi all\'applicazione l\'autorizzazione per intercettare tutto il traffico di rete. "<b>"NON accettare se non consideri l\'applicazione attendibile"</b>", altrimenti corri il rischio che i tuoi dati vengano compromessi da programmi software dannosi."</string>
-    <string name="accept" msgid="2889226408765810173">"Considero questa applicazione attendibile."</string>
+    <string name="prompt" msgid="3183836924226407828">"Richiesta di connessione"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vuole impostare una connessione VPN che le consenta di monitorare il traffico di rete. Accetta soltanto se ritieni la fonte attendibile. Quando la connessione VPN è attiva, nella parte superiore dello schermo viene visualizzata l\'icona &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN connessa"</string>
     <string name="configure" msgid="4905518375574791375">"Configura"</string>
     <string name="disconnect" msgid="971412338304200056">"Disconnetti"</string>
diff --git a/packages/VpnDialogs/res/values-iw/strings.xml b/packages/VpnDialogs/res/values-iw/strings.xml
index 335f5e4..e5d2f89 100644
--- a/packages/VpnDialogs/res/values-iw/strings.xml
+++ b/packages/VpnDialogs/res/values-iw/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"‏<xliff:g id="APP">%s</xliff:g> מנסה ליצור חיבור VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"אם תמשיך, אתה מעניק לאפליקציה הרשאה לעכב את כל התנועה ברשת. "<b>" אל תקבל אלא אם כן אתה סומך על האפליקציה. "</b>" אחרת, אתה חושף את הנתונים שלך לסכנה של פגיעה על-ידי תוכנה זדונית."</string>
-    <string name="accept" msgid="2889226408765810173">"אני סומך על אפליקציה זו."</string>
+    <string name="prompt" msgid="3183836924226407828">"בקשת חיבור"</string>
+    <string name="warning" msgid="809658604548412033">"‏<xliff:g id="APP">%s</xliff:g> רוצה להגדיר חיבור VPN שיאפשר לו לפקח על תעבורת הרשת. אשר את הבקשה רק אם אתה נותן אמון במקור. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; מופיע בחלק העליון של המסך כאשר VPN פעיל."</string>
     <string name="legacy_title" msgid="192936250066580964">"‏VPN מחובר"</string>
     <string name="configure" msgid="4905518375574791375">"הגדר"</string>
     <string name="disconnect" msgid="971412338304200056">"נתק"</string>
diff --git a/packages/VpnDialogs/res/values-ja/strings.xml b/packages/VpnDialogs/res/values-ja/strings.xml
index a88c388..0e65866 100644
--- a/packages/VpnDialogs/res/values-ja/strings.xml
+++ b/packages/VpnDialogs/res/values-ja/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>でVPN接続を作成します。"</string>
-    <string name="warning" msgid="5470743576660160079">"続行すると、すべてのネットワークトラフィックの傍受をアプリケーションに許可することになります。"<b>"信頼できるアプリケーションでない限り、同意しないでください。"</b>"誤って同意した場合は、不正なソフトウェアによりデータが不正使用される危険があります。"</string>
-    <string name="accept" msgid="2889226408765810173">"このアプリケーションを信頼できるものとみなします。"</string>
+    <string name="prompt" msgid="3183836924226407828">"接続リクエスト"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g>がネットワークトラフィックを監視するためVPN接続をセットアップしようとしています。ソースを信頼できる場合にのみ許可してください。&lt;br /&gt; &lt;br /&gt; VPNがアクティブになると画面の上部に&lt;img src=vpn_icon /&gt;が表示されます。"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN接続済み"</string>
     <string name="configure" msgid="4905518375574791375">"設定"</string>
     <string name="disconnect" msgid="971412338304200056">"切断"</string>
diff --git a/packages/VpnDialogs/res/values-ka-rGE/strings.xml b/packages/VpnDialogs/res/values-ka-rGE/strings.xml
index 960d3f6..61f3b0f 100644
--- a/packages/VpnDialogs/res/values-ka-rGE/strings.xml
+++ b/packages/VpnDialogs/res/values-ka-rGE/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> ცდილობს VPN კავშირის შექმნას."</string>
-    <string name="warning" msgid="5470743576660160079">"გაგრძელების შემთხვევაში, აპლიკაციას ექნება ქსელში გადაცემული მონაცემების მოპოვების საშუალება. "<b>"არ განაგრძოთ, თუ არ ენდობით აპლიკაციას."</b>" წინააღმდეგ შემთვევაში შესაძლოა მავნე პროგრამას თქვენ მონაცემებთან წვდომის საშუალება მიეცეს."</string>
-    <string name="accept" msgid="2889226408765810173">"ვენდობი ამ აპლიკაციას."</string>
+    <string name="prompt" msgid="3183836924226407828">"კავშირის მოთხოვნა"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> სურს დააყენოს VPN კავშირი, რაც ქსელის ტრაფიკის მონიტორინგის საშუალებას იძლევა. მიიღოთ მხოლოდ ისეთ შემთხვევაში, თუ წყაროს ენდობით. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; თქვენი ეკრანის სიის თავში გამოჩნდება, როდესაც VPN აქტიურია."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN დაკავშირებულია"</string>
     <string name="configure" msgid="4905518375574791375">"კონფიგურაცია"</string>
     <string name="disconnect" msgid="971412338304200056">"კავშირის გაწყვეტა"</string>
diff --git a/packages/VpnDialogs/res/values-kk-rKZ/strings.xml b/packages/VpnDialogs/res/values-kk-rKZ/strings.xml
index 29a2db8..8514d3c 100644
--- a/packages/VpnDialogs/res/values-kk-rKZ/strings.xml
+++ b/packages/VpnDialogs/res/values-kk-rKZ/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> ВЖЖ байланысын орнату әрекеттері."</string>
-    <string name="warning" msgid="5470743576660160079">"Жалғастыру арқылы барлық желі кептелісін жоюға рұқсат бересіз. "<b>"Егер қолданбаға сенбесеңіз қабылдаМАңыз."</b>" Әйтпесе, деректеріңіз залалды бағдарлама шабуылына ұшырауы мүмкін."</string>
-    <string name="accept" msgid="2889226408765810173">"Мен бұл қолданбаға сенемін."</string>
+    <string name="prompt" msgid="3183836924226407828">"Байланысты сұрау"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> VPN байланысын орнатқысы келеді, бұл оған желілік трафикті бақылауға мүмкіндік береді. Көзге сенсеңіз ғана қабылдаңыз. VPN белсенді болғанда экранның жоғарғы жағында &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; көрсетіледі."</string>
     <string name="legacy_title" msgid="192936250066580964">"ВЖЖ қосылған"</string>
     <string name="configure" msgid="4905518375574791375">"Конфигурациялау"</string>
     <string name="disconnect" msgid="971412338304200056">"Ажырату"</string>
diff --git a/packages/VpnDialogs/res/values-km-rKH/strings.xml b/packages/VpnDialogs/res/values-km-rKH/strings.xml
index 2c79e26..027f104 100644
--- a/packages/VpnDialogs/res/values-km-rKH/strings.xml
+++ b/packages/VpnDialogs/res/values-km-rKH/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> ព្យាយាម​បង្កើត​ការ​តភ្ជាប់ VPN ។"</string>
-    <string name="warning" msgid="5470743576660160079">"ដោយ​បន្ត អ្នក​កំពុង​ផ្ដល់​សិទ្ធិ​ឲ្យ​កម្មវិធី​ទប់ស្កាត់​ចរាចរណ៍​បណ្ដាញ។ "<b>"កុំ​ទទួល​ លុះ​ត្រា​តែ​អ្នក​ទុក​ចិត្ត​កម្មវិធី។"</b>" បើ​មិន​ដូច្នេះ​ទេ អ្នក​ដំណើរការ​ប្រឈម​នឹង​គ្រោះថ្នាក់ ដោយ​ទិន្នន័យ​របស់​អ្នក​បាន​សម្របសម្រួល​ដោយ​កម្មវិធី​ព្យាបាទ។"</string>
-    <string name="accept" msgid="2889226408765810173">"ខ្ញុំ​ទុកចិត្ត​​​កម្មវិធី​នេះ​។"</string>
+    <string name="prompt" msgid="3183836924226407828">"សំណើ​សុំ​ការ​តភ្ជាប់"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ចង់​បង្កើត​ការ​តភ្ជាប់ VPN ដែល​អនុញ្ញាត​ឲ្យ​វា​ត្រួតពិនិត្យ​ចរាចរ​បណ្ដាញ។ ព្រម​ទទួល ប្រសិនបើ​អ្នក​ទុកចិត្ត​លើ​ប្រភព​តែប៉ុណ្ណោះ។ &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; នឹង​លេចឡើង​នៅ​ផ្នែក​ខាងលើ​នៃ​អេក្រង់​របស់​អ្នក ពេល VPN សកម្ម។"</string>
     <string name="legacy_title" msgid="192936250066580964">"បា​ន​ភ្ជាប់ VPN"</string>
     <string name="configure" msgid="4905518375574791375">"កំណត់​រចនាសម្ព័ន្ធ"</string>
     <string name="disconnect" msgid="971412338304200056">"ផ្ដាច់"</string>
diff --git a/packages/VpnDialogs/res/values-kn-rIN/strings.xml b/packages/VpnDialogs/res/values-kn-rIN/strings.xml
index 5793176..b3f5a10 100644
--- a/packages/VpnDialogs/res/values-kn-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-kn-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"VPN ಸಂಪರ್ಕವನ್ನು ರಚಿಸಲು <xliff:g id="APP">%s</xliff:g> ಪ್ರಯತ್ನಿಸಿದೆ."</string>
-    <string name="warning" msgid="5470743576660160079">"ಮುಂದುವರಿಸುವುದರ ಮೂಲಕ, ಎಲ್ಲಾ ನೆಟ್‌ವರ್ಟ್ ದಟ್ಟಣೆಯನ್ನು ಪ್ರತಿಬಂಧಿಸಲು ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ನೀವು ಅನುಮತಿಯನ್ನು ನೀಡುತ್ತಿರುವಿರಿ. "<b>"ನೀವು ಅಪ್ಲಿಕೇಶನ್ ಅನ್ನು ನಂಬದ ಹೊರತು ಸಮ್ಮತಿಸಬೇಡಿ."</b>" ಇಲ್ಲದಿದ್ದರೆ, ದೋಷಪೂರಿತ ಸಾಫ್ಟ್‌ವೇರ್‌ನಿಂದ ನಿಮ್ಮ ಡೇಟಾಗೆ ಧಕ್ಕೆಯುಂಟಾಗುವ ಅಪಾಯಕ್ಕೆ ಒಳಗಾಗುತ್ತೀರಿ."</string>
-    <string name="accept" msgid="2889226408765810173">"ನನಗೆ ಈ ಅಪ್ಲಿಕೇಶನ್ ಮೇಲೆ ನಂಬಿಕೆಯಿದೆ."</string>
+    <string name="prompt" msgid="3183836924226407828">"ಸಂಪರ್ಕ ವಿನಂತಿ"</string>
+    <string name="warning" msgid="809658604548412033">"ನೆಟ್‌ವರ್ಕ್ ಟ್ರಾಫಿಕ್ ಅನ್ನು ಮೇಲ್ವಿಚಾರಣೆ ಮಾಡಲು ಅನುಮತಿಸುವಂತಹ VPN ಸಂಪರ್ಕವನ್ನು ಹೊಂದಿಸಲು <xliff:g id="APP">%s</xliff:g> ಬಯಸುತ್ತದೆ. ನೀವು ಮೂಲವನ್ನು ನಂಬಿದರೆ ಮಾತ್ರ ಸಮ್ಮತಿಸಿ. VPN ಸಕ್ರಿಯವಾಗಿರುವಾಗ ನಿಮ್ಮ ಪರದೆಯ ಮೇಲ್ಭಾಗದಲ್ಲಿ &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; ಗೋರಿಸುತ್ತದೆ."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN ಸಂಪರ್ಕಗೊಂಡಿದೆ"</string>
     <string name="configure" msgid="4905518375574791375">"ಕಾನ್ಫಿಗರ್ ಮಾಡು"</string>
     <string name="disconnect" msgid="971412338304200056">"ಸಂಪರ್ಕ ಕಡಿತಗೊಳಿಸು"</string>
diff --git a/packages/VpnDialogs/res/values-ko/strings.xml b/packages/VpnDialogs/res/values-ko/strings.xml
index 38a5e2e..b9c7ba1 100644
--- a/packages/VpnDialogs/res/values-ko/strings.xml
+++ b/packages/VpnDialogs/res/values-ko/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>이(가) VPN 연결을 만들려고 시도합니다."</string>
-    <string name="warning" msgid="5470743576660160079">"진행하면 애플리케이션이 모든 네트워크 트래픽을 가로채도록 허용하게 됩니다. "<b>"이 애플리케이션을 신뢰하지 않는 한 허용하지 마세요. "</b>"그렇지 않으면 데이터가 악성 소프트웨어에 의해 해킹을 당할 수 있습니다."</string>
-    <string name="accept" msgid="2889226408765810173">"이 애플리케이션을 신뢰합니다."</string>
+    <string name="prompt" msgid="3183836924226407828">"연결 요청"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g>에서 네트워크 트래픽을 모니터링하도록 허용하는 VPN 연결을 설정하려고 합니다. 출처를 신뢰할 수 있는 경우에만 수락하세요. VPN이 활성화되면 &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;이 화면 위에 표시됩니다."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN이 연결되었습니다."</string>
     <string name="configure" msgid="4905518375574791375">"설정"</string>
     <string name="disconnect" msgid="971412338304200056">"연결 끊기"</string>
diff --git a/packages/VpnDialogs/res/values-ky-rKG/strings.xml b/packages/VpnDialogs/res/values-ky-rKG/strings.xml
index c7d56ba..44fbabd 100644
--- a/packages/VpnDialogs/res/values-ky-rKG/strings.xml
+++ b/packages/VpnDialogs/res/values-ky-rKG/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> VPN байланышын түзүүгө аракет кылууда."</string>
-    <string name="warning" msgid="5470743576660160079">"Муну иштетүү менен, сиз колдонмого бардык желе трафигин көрүүгө уруксат бересиз. "<b>"Сиз колдонмого ишенмейинче КАБЫЛ АЛБАҢЫЗ."</b>" Болбосо, зыяндуу софттордун маалыматтарыңызды сыртка чыгаруу коркунучуна кабыласыз."</string>
-    <string name="accept" msgid="2889226408765810173">"Мен бул колдонмого ишенем."</string>
+    <string name="prompt" msgid="3183836924226407828">"Туташуу сурамы"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> тармактык трафикти көзөмөлдөөгө уруксат берген VPN туташуусун орноткусу келет. Аны булакка ишенсеңиз гана кабыл алыңыз. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; VPN иштеп турганда экраныңыздын жогору жагынан көрүнөт."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN байланышта"</string>
     <string name="configure" msgid="4905518375574791375">"Конфигурациялоо"</string>
     <string name="disconnect" msgid="971412338304200056">"Ажыратуу"</string>
diff --git a/packages/VpnDialogs/res/values-lo-rLA/strings.xml b/packages/VpnDialogs/res/values-lo-rLA/strings.xml
index 9f5216b..6248f8d 100644
--- a/packages/VpnDialogs/res/values-lo-rLA/strings.xml
+++ b/packages/VpnDialogs/res/values-lo-rLA/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> ພະຍາຍາມສ້າງການເຊື່ອມຕໍ່ VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"ຖ້າດຳເນີນຕໍ່, ແມ່ນທ່ານກຳລັງຈະໃຫ້ສິດແກ່ແອັບພລິເຄຊັນ ໃນການດັກຂໍ້ມູນຈະລາຈອນໃນເຄືອຂ່າຍທັງໝົດ. "<b>"ຢ່າຍອມຮັບ ນອກຈາກວ່າທ່ານຈະເຊື່ອໃຈແອັບພລິເຄຊັນດັ່ງກ່າວ."</b>" ຖ້າບໍ່ດັ່ງນັ້ນ, ທ່ານຈະຕົກຢູ່ໃນຄວາມສ່ຽງ ທີ່ຂໍ້ມູນຂອງທ່ານຈະຖືກຄຸກຄາມໂດຍຊອບແວທີ່ເປັນອັນຕະລາຍ."</string>
-    <string name="accept" msgid="2889226408765810173">"ຂ້ອຍເຊື່ອແອັບພລິເຄຊັນນີ້."</string>
+    <string name="prompt" msgid="3183836924226407828">"ການ​ຮ້ອງ​ຂໍ​ການ​ເຊື່ອມ​ຕໍ່"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ຕ້ອງ​ການ​ຕັ້​ງ​ຄ່າ​ການ​ເຊື່ອມ​ຕໍ່ VPN ທີ່​ອະ​ນຸ​ຍາດ​ໃຫ້​ຕິດ​ຕາມ​ທຣາບ​ຟິກ​ເຄືອ​ຂ່າຍ​ໄດ້. ​ທ່ານ​​ຄວນ​​ຍິນຍອມ​ສະ​ເພາະ​ໃນ​ກໍ​ລະ​ນີ​ທີ່​ທ່ານ​ເຊື່ອ​ຖື​ແຫລ່ງ​ຂໍ້​ມູນ​ເທົ່າ​ນັ້ນ. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; ຈະ​ປາ​ກົດ​ຢູ່​ດ້ານ​ເທິງ​ຂອງ​ໜ້າ​ຈໍ​ເມື່ອ​ມີ​ການ​ເປີດ​ໃຊ້ VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"ເຊື່ອມຕໍ່ VPN ແລ້ວ"</string>
     <string name="configure" msgid="4905518375574791375">"ປັບຄ່າ"</string>
     <string name="disconnect" msgid="971412338304200056">"ຕັດການເຊື່ອມຕໍ່"</string>
diff --git a/packages/VpnDialogs/res/values-lt/strings.xml b/packages/VpnDialogs/res/values-lt/strings.xml
index 8ed3045..f70d55d 100644
--- a/packages/VpnDialogs/res/values-lt/strings.xml
+++ b/packages/VpnDialogs/res/values-lt/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> bando sukurti VPN ryšį."</string>
-    <string name="warning" msgid="5470743576660160079">"Tęsdami suteikiate programai leidimą perimti visą tinklo srautą. "<b>"SUTIKITE, TIK JEI pasitikite programa."</b>" Priešingu atveju kyla pavojus, kad jūsų duomenims pakenks kenkėjiška programinė įranga."</string>
-    <string name="accept" msgid="2889226408765810173">"Pasitikiu šia programa."</string>
+    <string name="prompt" msgid="3183836924226407828">"Ryšio užklausa"</string>
+    <string name="warning" msgid="809658604548412033">"„<xliff:g id="APP">%s</xliff:g>“ nori nustatyti VPN ryšį, kad galėtų stebėti tinklo srautą. Sutikite, tik jei pasitikite šaltiniu. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; rodoma ekrano viršuje, kai VPN aktyvus."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN prijungtas"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigūruoti"</string>
     <string name="disconnect" msgid="971412338304200056">"Atsijungti"</string>
diff --git a/packages/VpnDialogs/res/values-lv/strings.xml b/packages/VpnDialogs/res/values-lv/strings.xml
index 2f41747..ff59d18 100644
--- a/packages/VpnDialogs/res/values-lv/strings.xml
+++ b/packages/VpnDialogs/res/values-lv/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> mēģina izveidot VPN savienojumu."</string>
-    <string name="warning" msgid="5470743576660160079">"Izvēloties turpināt, jūs ļaujat lietojumprogrammai pārtvert visu tīkla datplūsmu. "<b>"NEPIEKRĪTIET, ja neuzticaties šai lietojumprogrammai."</b>" Pretējā gadījumā pastāv risks, ka jūsu datus var apdraudēt ļaunprātīga programmatūra."</string>
-    <string name="accept" msgid="2889226408765810173">"Es uzticos šai lietojumprogrammai."</string>
+    <string name="prompt" msgid="3183836924226407828">"Savienojuma pieprasījums"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vēlas izveidot VPN savienojumu, kas ļaus pārraudzīt tīkla datplūsmu. Piekrītiet tikai tad, ja uzticaties avotam. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; tiek rādīta ekrāna augšdaļā, kad darbojas VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"Ir izveidots savienojums ar VPN"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurēt"</string>
     <string name="disconnect" msgid="971412338304200056">"Pārtraukt savienojumu"</string>
diff --git a/packages/VpnDialogs/res/values-mk-rMK/strings.xml b/packages/VpnDialogs/res/values-mk-rMK/strings.xml
index 635206f..d835cfc 100644
--- a/packages/VpnDialogs/res/values-mk-rMK/strings.xml
+++ b/packages/VpnDialogs/res/values-mk-rMK/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> се обидува да создаде врска со VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Ако продолжите, ѝ давате дозвола на апликацијата да го пресретнува целиот мрежен сообраќај. "<b>"НЕ прифаќајте, освен ако не ѝ верувате на апликацијата."</b>" Во спротивно, постои ризик злонамерен софтвер да ги компромитира вашите податоци."</string>
-    <string name="accept" msgid="2889226408765810173">"Ѝ верувам на оваа апликација."</string>
+    <string name="prompt" msgid="3183836924226407828">"Барање за поврзување"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> сака да постави поврзување со ВПН коешто му дозволува да го набљудува сообраќајот на мрежата. Прифатете само доколку му верувате на изворот. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; се појавува на врвот на екранот кога ВПН е активна."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN е поврзана"</string>
     <string name="configure" msgid="4905518375574791375">"Конфигурирај"</string>
     <string name="disconnect" msgid="971412338304200056">"Исклучи"</string>
diff --git a/packages/VpnDialogs/res/values-ml-rIN/strings.xml b/packages/VpnDialogs/res/values-ml-rIN/strings.xml
index e1d9e23..3dd76d8 100644
--- a/packages/VpnDialogs/res/values-ml-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-ml-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>, ഒരു VPN കണക്ഷൻ സൃഷ്ടിക്കാൻ ശ്രമിക്കുന്നു."</string>
-    <string name="warning" msgid="5470743576660160079">"തുടരുന്നതിലൂടെ, നിങ്ങൾ അപ്ലിക്കേഷന് എല്ലാ നെറ്റ്‌വർക്ക് ട്രാഫിക്കും തടസ്സപ്പെടുത്താനുള്ള അനുമതി നൽകുന്നു. "<b>"അപ്ലിക്കേഷനെ വിശ്വസിക്കുന്നില്ലെങ്കിൽ അംഗീകരിക്കരുത്."</b>" അല്ലെങ്കിൽ, ഒരു ക്ഷുദ്രകരമായ സോഫ്‌റ്റ്‌വെയർ നിങ്ങളുടെ ഡാറ്റ അപഹരിക്കുന്നതിനുള്ള അപകടസാധ്യതയിലൂടെ നിങ്ങൾ കടന്നുപോകാനിടയുണ്ട്."</string>
-    <string name="accept" msgid="2889226408765810173">"ഞാൻ ഈ അപ്ലിക്കേഷനെ വിശ്വസിക്കുന്നു."</string>
+    <string name="prompt" msgid="3183836924226407828">"കണക്ഷൻ അഭ്യർത്ഥന"</string>
+    <string name="warning" msgid="809658604548412033">"നെറ്റ്‌വർക്ക് ട്രാഫിക്ക് നിരീക്ഷിക്കാൻ അനുവദിക്കുന്ന ഒരു VPN കണക്ഷൻ <xliff:g id="APP">%s</xliff:g> സജ്ജീകരിക്കേണ്ടതുണ്ട്. ഉറവിടം പരിചിതമാണെങ്കിൽ മാത്രം അംഗീകരിക്കുക. VPN സജീവമാകുമ്പോൾ &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; നിങ്ങളുടെ സ്ക്രീനിന്റെ മുകളിൽ ദൃശ്യമാകുന്നു."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN കണക്‌റ്റുചെയ്‌തു"</string>
     <string name="configure" msgid="4905518375574791375">"കോൺഫിഗർ ചെയ്യുക"</string>
     <string name="disconnect" msgid="971412338304200056">"വിച്ഛേദിക്കുക"</string>
diff --git a/packages/VpnDialogs/res/values-mn-rMN/strings.xml b/packages/VpnDialogs/res/values-mn-rMN/strings.xml
index 887bb73..1b6cb6c 100644
--- a/packages/VpnDialogs/res/values-mn-rMN/strings.xml
+++ b/packages/VpnDialogs/res/values-mn-rMN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> VPN холболтыг үүсгэх гэж байна."</string>
-    <string name="warning" msgid="5470743576660160079">"Үргэлжлүүлсэнээр та аппликешнд бүх сүлжээний урсгалыг таслах зөвшөөрлийг өгөх болно. "<b>"Аппикешн баталгаагүй гэж үзсэн тохиолдолд л зөвшөөрч болорхгүй."</b>" Бусад тохиолдолд та өөрийн датаг хортой софтверийн аюулд өртөх эрсдэлийг үүсгэж байна."</string>
-    <string name="accept" msgid="2889226408765810173">"Би энэ аппликешнд итгэж байна."</string>
+    <string name="prompt" msgid="3183836924226407828">"Холболтын хүсэлт"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> нь сүлжээний трафикыг хянах боломж бүхий VPN холболт үүсгэхийг хүсэж байна. Та зөвхөн эх үүсвэрт итгэж байгаа бол зөвшөөрнө үү. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; таны дэлгэц дээр VPN идэвхтэй үед гарч ирнэ."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN холбогдов"</string>
     <string name="configure" msgid="4905518375574791375">"Тохируулах"</string>
     <string name="disconnect" msgid="971412338304200056">"Салгах"</string>
diff --git a/packages/VpnDialogs/res/values-mr-rIN/strings.xml b/packages/VpnDialogs/res/values-mr-rIN/strings.xml
index f78747b..a325b90 100644
--- a/packages/VpnDialogs/res/values-mr-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-mr-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> VPN कनेक्‍शन तयार करण्‍याचा प्रयत्न करतो."</string>
-    <string name="warning" msgid="5470743576660160079">"पुढे सुरु ठेवून, आपण अनुप्रयोगाला सर्व नेटवर्क रहदारी खंडित करण्‍याची परवानगी देता."<b>"आपला अनुप्रयोगावर विश्‍वास नसल्‍यास स्‍वीकार करू नका."</b>" अन्‍यथा, आपण दुर्भावनापूर्ण सॉफ्‍टवेअरद्वारे आपल्‍या डेटाची तडजोड झाल्‍याची जोखीम चालवाल."</string>
-    <string name="accept" msgid="2889226408765810173">"माझा या अनुप्रयोगावर विश्वास आहे."</string>
+    <string name="prompt" msgid="3183836924226407828">"कनेक्‍शन विनंती"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> नेटवर्क रहदारीचे परीक्षण करण्‍यासाठी त्यास अनुमती देणारे VPN कनेक्‍शन सेट करू इच्‍छितो. आपल्याला स्त्रोत विश्वसनीय वाटत असेल तरच स्वीकार करा. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; VPN सक्रिय असताना आपल्‍या स्क्रीनच्या शीर्षावर दिसते."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN कनेक्‍ट केले"</string>
     <string name="configure" msgid="4905518375574791375">"कॉन्फिगर करा"</string>
     <string name="disconnect" msgid="971412338304200056">"‍डिस्कनेक्ट करा"</string>
diff --git a/packages/VpnDialogs/res/values-ms-rMY/strings.xml b/packages/VpnDialogs/res/values-ms-rMY/strings.xml
index 417fbae..8ea682f 100644
--- a/packages/VpnDialogs/res/values-ms-rMY/strings.xml
+++ b/packages/VpnDialogs/res/values-ms-rMY/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> percubaan untuk membuat sambungan VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Dengan meneruskan, anda memberi keizinan kepada aplikasi untuk memintas semua trafik rangkaian. "<b>"JANGAN terima melainkan anda mempercayai aplikasi itu."</b>" Jika tidak, anda akan mengalami risiko data terjejas oleh perisian berniat jahat."</string>
-    <string name="accept" msgid="2889226408765810173">"Saya percayai aplikasi ini."</string>
+    <string name="prompt" msgid="3183836924226407828">"Permintaan sambungan"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ingin menyediakan sambungan VPN yang membenarkan apl memantau trafik rangkaian. Terima hanya jika anda mempercayai sumber. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; terpapar pada bahagian atas skrin anda apabila VPN aktif."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN telah disambungkan"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurasikan"</string>
     <string name="disconnect" msgid="971412338304200056">"Putuskan sambungan"</string>
diff --git a/packages/VpnDialogs/res/values-my-rMM/strings.xml b/packages/VpnDialogs/res/values-my-rMM/strings.xml
index c2aec1d..6456c5e 100644
--- a/packages/VpnDialogs/res/values-my-rMM/strings.xml
+++ b/packages/VpnDialogs/res/values-my-rMM/strings.xml
@@ -16,13 +16,12 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> သည်VPNဆက်သွယ်မှုရရှိရန်ကြိုးစားနေသည်"</string>
-    <string name="warning" msgid="5470743576660160079">"ရှေ့ဆက်လုပ်ဆောင်ခြင်းအားဖြင့် အပ်ပလီကေးရှင်းအား ကွန်ယက်အသွားအလာအားကြားဖြတ်စေရန် ခွင့်ပြုခြင်းဖြစ်သည်။"<b>"အပ်ပလီကေးရှင်းအား မယုံကြည်သရွေ့ လက်မခံပါနှင့်"</b>" သို့မဟုတ်လျှင် မလိုလားအပ်သောဆော့ဖ်ဝဲမှ သင့်ဒေတာများအားအပေးအယူလုပ်နိုင်စေရန် ဘေးအန္တရာယ်ရှိပါသည်"</string>
-    <string name="accept" msgid="2889226408765810173">"ဤအပ်ပလီကေးရှင်းအားယုံကြည်ပါသည်"</string>
-    <string name="legacy_title" msgid="192936250066580964">"VPNနှင့်ချိတ်ဆက်ထားသည်"</string>
+    <string name="prompt" msgid="3183836924226407828">"ချိတ်ဆက်ရန် တောင်းဆိုချက်"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> က ကွန်ရက် လုပ်ငန်းကို စောင့်ကြည့်ခွင့် ပြုမည့် VPN ချိတ်ဆက်မှုကို ထူထောင်လိုသည်။ ရင်းမြစ်ကို သင်က ယုံကြည်မှသာ လက်ခံပါ။ &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; မှာ VPN အလုပ်လုပ်နေလျှင် သင်၏ မျက်နှာပြင် ထိပ်မှာ ပေါ်လာမည်။"</string>
+    <string name="legacy_title" msgid="192936250066580964">"VPNနှင့်ချိတ်ဆက်ထားသည်"</string>
     <string name="configure" msgid="4905518375574791375">"ပုံပေါ်စေသည်"</string>
     <string name="disconnect" msgid="971412338304200056">"ချိတ်ဆက်ခြင်းရပ်ရန်"</string>
-    <string name="session" msgid="6470628549473641030">"သတ်မှတ်ပေးထားသည့်အချိန်:"</string>
+    <string name="session" msgid="6470628549473641030">"သတ်မှတ်ပေးထားသည့်အချိန်:"</string>
     <string name="duration" msgid="3584782459928719435">"အချိန်ကာလ-"</string>
     <string name="data_transmitted" msgid="7988167672982199061">"ပို့သည်-"</string>
     <string name="data_received" msgid="4062776929376067820">"လက်ခံရရှိသည်"</string>
diff --git a/packages/VpnDialogs/res/values-nb/strings.xml b/packages/VpnDialogs/res/values-nb/strings.xml
index 6bffc98..f99c2e7 100644
--- a/packages/VpnDialogs/res/values-nb/strings.xml
+++ b/packages/VpnDialogs/res/values-nb/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> forsøker å etablere en VPN-tilkobling."</string>
-    <string name="warning" msgid="5470743576660160079">"Ved å fortsette gir du appen tillatelse til å fange opp all nettverkstrafikk. "<b>"IKKE godta med mindre du stoler på appen."</b>" Ellers risikerer du at dataene dine kompromitteres av en ondsinnet programvare."</string>
-    <string name="accept" msgid="2889226408765810173">"Jeg stoler på denne appen."</string>
+    <string name="prompt" msgid="3183836924226407828">"Tilkoblingsforespørsel"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ønsker å bruke en VPN-tilkobling som tillater at appen overvåker nettverkstrafikken. Du bør bare godta dette hvis du stoler på kilden. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; vises øverst på skjermen din når VPN er aktivert."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN er tilkoblet"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurer"</string>
     <string name="disconnect" msgid="971412338304200056">"Koble fra"</string>
diff --git a/packages/VpnDialogs/res/values-ne-rNP/strings.xml b/packages/VpnDialogs/res/values-ne-rNP/strings.xml
index 03211cb..d3cf435 100644
--- a/packages/VpnDialogs/res/values-ne-rNP/strings.xml
+++ b/packages/VpnDialogs/res/values-ne-rNP/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> एउटा VPN जडान सिर्जना गर्ने प्रयासहरू।"</string>
-    <string name="warning" msgid="5470743576660160079">"अगाडी बढेर, तपाईँले यस अनुप्रयोगलाई सबै नेटवर्कको ट्राफिक अवरोध गर्न अनुमति दिनु हुँदैछ। "<b>"तपाईँलाई अनुप्रयोगको विश्वास नलागेसम्म यसलाई स्वीकार नगर्नुहोस्।"</b>" अन्यथा, तपाईँ आफ्नो डेटा खराब सफ्टवेरद्वारा जोखिममा पर्नु हुनेछ।"</string>
-    <string name="accept" msgid="2889226408765810173">"म यस अनुप्रयोगलाई विश्वास गर्छु।"</string>
+    <string name="prompt" msgid="3183836924226407828">"जडान अनुरोध"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ले नेटवर्क यातायात अनुगमन गर्न अनुमति दिने VPN जडान स्थापना गर्न चाहन्छ। तपाईँले स्रोत भरोसा छ भने मात्र स्वीकार गर्नुहोस्। &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; जब VPN सक्रिय हुन्छ आफ्नो स्क्रिनको माथि देखा पर्छन्।"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN जोडिएको छ"</string>
     <string name="configure" msgid="4905518375574791375">"कन्फिगर गर्नुहोस्"</string>
     <string name="disconnect" msgid="971412338304200056">"विच्छेदन गर्नुहोस्"</string>
diff --git a/packages/VpnDialogs/res/values-nl/strings.xml b/packages/VpnDialogs/res/values-nl/strings.xml
index 795071e..0f28016 100644
--- a/packages/VpnDialogs/res/values-nl/strings.xml
+++ b/packages/VpnDialogs/res/values-nl/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> pogingen om een VPN-verbinding te maken."</string>
-    <string name="warning" msgid="5470743576660160079">"Als u doorgaat, geeft u de app toestemming om al het netwerkverkeer te onderscheppen. "<b>"Ga NIET akkoord, tenzij u de app vertrouwt."</b>" Anders loopt u het risico dat uw gegevens worden gecomprimeerd door schadelijke software."</string>
-    <string name="accept" msgid="2889226408765810173">"Ik vertrouw deze app."</string>
+    <string name="prompt" msgid="3183836924226407828">"Verbindingsverzoek"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> wil een VPN-verbinding opzetten om netwerkverkeer te controleren. Accepteer het verzoek alleen als u de bron vertrouwt. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; wordt boven aan uw scherm weergegeven wanneer VPN actief is."</string>
     <string name="legacy_title" msgid="192936250066580964">"Verbinding met VPN"</string>
     <string name="configure" msgid="4905518375574791375">"Configureren"</string>
     <string name="disconnect" msgid="971412338304200056">"Verbinding verbreken"</string>
diff --git a/packages/VpnDialogs/res/values-pl/strings.xml b/packages/VpnDialogs/res/values-pl/strings.xml
index a918162..a8c08d51 100644
--- a/packages/VpnDialogs/res/values-pl/strings.xml
+++ b/packages/VpnDialogs/res/values-pl/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Aplikacja <xliff:g id="APP">%s</xliff:g> próbuje nawiązać połączenie VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Kontynuując, udzielasz aplikacji pozwolenia na przechwytywanie całego ruchu sieciowego. "<b>"NIE rób tego, jeśli nie ufasz tej aplikacji."</b>" W przeciwnym razie ryzykujesz, że bezpieczeństwo Twoich danych zostanie naruszone przez złośliwe oprogramowanie."</string>
-    <string name="accept" msgid="2889226408765810173">"Ufam tej aplikacji"</string>
+    <string name="prompt" msgid="3183836924226407828">"Żądanie połączenia"</string>
+    <string name="warning" msgid="809658604548412033">"Aplikacja <xliff:g id="APP">%s</xliff:g> chce utworzyć połączenie VPN, które pozwoli jej na monitorowanie ruchu sieciowego. Zaakceptuj, tylko jeśli masz zaufanie do źródła. Gdy sieć VPN jest aktywna, u góry ekranu pojawia się &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"Połączono z VPN"</string>
     <string name="configure" msgid="4905518375574791375">"Konfiguruj"</string>
     <string name="disconnect" msgid="971412338304200056">"Rozłącz"</string>
diff --git a/packages/VpnDialogs/res/values-pt-rPT/strings.xml b/packages/VpnDialogs/res/values-pt-rPT/strings.xml
index 007cd51..e3727c0 100644
--- a/packages/VpnDialogs/res/values-pt-rPT/strings.xml
+++ b/packages/VpnDialogs/res/values-pt-rPT/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tentativas para criar uma ligação VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Ao continuar estará a dar permissão à aplicação para intercetar todo o tráfego da rede. "<b>"NÃO aceite a menos que confie nesta aplicação."</b>"Caso contrário, corre o risco de ver os seus dados comprometidos por software malicioso."</string>
-    <string name="accept" msgid="2889226408765810173">"Confio nesta aplicação."</string>
+    <string name="prompt" msgid="3183836924226407828">"Pedido de ligação"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> pretende configurar uma ligação VPN que lhe permita monitorizar o tráfego de rede. Aceite apenas se confiar na fonte. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; aparece na parte superior do seu ecrã quando a VPN está ativa."</string>
     <string name="legacy_title" msgid="192936250066580964">"A VPN está ligada"</string>
     <string name="configure" msgid="4905518375574791375">"Configurar"</string>
     <string name="disconnect" msgid="971412338304200056">"Desligar"</string>
diff --git a/packages/VpnDialogs/res/values-pt/strings.xml b/packages/VpnDialogs/res/values-pt/strings.xml
index 07c8482..e4154bc 100644
--- a/packages/VpnDialogs/res/values-pt/strings.xml
+++ b/packages/VpnDialogs/res/values-pt/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> tentativas para criar uma conexão VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Aceitando, você dá ao aplicativo permissão para interceptar todo o tráfego de rede."<b>"Recuse, a menos que você confie no aplicativo."</b>" Caso contrário, você corre o risco de ter seus dados comprometidos por um software malicioso."</string>
-    <string name="accept" msgid="2889226408765810173">"Confio nesse aplicativo."</string>
+    <string name="prompt" msgid="3183836924226407828">"Solicitação de conexão"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> quer configurar uma conexão VPN que permite monitorar o tráfego da rede. Aceite se confiar na origem. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; é exibido na parte superior da tela quando a VPN estiver ativa."</string>
     <string name="legacy_title" msgid="192936250066580964">"O VPN está conectado"</string>
     <string name="configure" msgid="4905518375574791375">"Configurar"</string>
     <string name="disconnect" msgid="971412338304200056">"Desconectar"</string>
diff --git a/packages/VpnDialogs/res/values-ro/strings.xml b/packages/VpnDialogs/res/values-ro/strings.xml
index fbc0d808..f7a6a6a 100644
--- a/packages/VpnDialogs/res/values-ro/strings.xml
+++ b/packages/VpnDialogs/res/values-ro/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> încearcă să creeze o conexiune VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Dacă veţi continua, veţi da acestei aplicaţii permisiunea de a intercepta întregul trafic de reţea. "<b>"NU acceptaţi decât dacă aveţi încredere în această aplicaţie."</b>" În caz contrar, există riscul ca datele dvs. să fie compromise de un software rău intenţionat."</string>
-    <string name="accept" msgid="2889226408765810173">"Am încredere în această aplicaţie."</string>
+    <string name="prompt" msgid="3183836924226407828">"Solicitare de conexiune"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> dorește să configureze o conexiune VPN care să îi permită să monitorizeze traficul în rețea. Acceptați numai dacă aveți încredere în sursă. Atunci când conexiunea VPN este activă, &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; se afișează în partea de sus a ecranului."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN este conectat"</string>
     <string name="configure" msgid="4905518375574791375">"Configuraţi"</string>
     <string name="disconnect" msgid="971412338304200056">"Deconectaţi"</string>
diff --git a/packages/VpnDialogs/res/values-ru/strings.xml b/packages/VpnDialogs/res/values-ru/strings.xml
index b65e9d3..0e89d8e 100644
--- a/packages/VpnDialogs/res/values-ru/strings.xml
+++ b/packages/VpnDialogs/res/values-ru/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> пытается установить VPN-соединение."</string>
-    <string name="warning" msgid="5470743576660160079">"Если продолжить, вы разрешите приложению перехватывать весь сетевой трафик. "<b>"Не делайте этого, если не доверяете приложению."</b>" В противном случае к вашим данным может получить доступ вредоносное ПО."</string>
-    <string name="accept" msgid="2889226408765810173">"Я доверяю этому приложению."</string>
+    <string name="prompt" msgid="3183836924226407828">"Запрос на подключение"</string>
+    <string name="warning" msgid="809658604548412033">"Приложение \"<xliff:g id="APP">%s</xliff:g>\" пытается подключиться к сети VPN, чтобы отслеживать трафик. Этот запрос следует принимать, только если вы доверяете источнику.<br/><br/>Когда подключение VPN активно, в верхней части экрана появляется значок &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN-подключение установлено"</string>
     <string name="configure" msgid="4905518375574791375">"Настроить"</string>
     <string name="disconnect" msgid="971412338304200056">"Разъединить"</string>
diff --git a/packages/VpnDialogs/res/values-si-rLK/strings.xml b/packages/VpnDialogs/res/values-si-rLK/strings.xml
index 67e0ed6..5f54821 100644
--- a/packages/VpnDialogs/res/values-si-rLK/strings.xml
+++ b/packages/VpnDialogs/res/values-si-rLK/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"VPN සම්බන්ධතාවයක් සැදීමට <xliff:g id="APP">%s</xliff:g> උත්සාහ කරයි."</string>
-    <string name="warning" msgid="5470743576660160079">"ඉදිරියට යාමෙන්, සියලු ජාල තදබදය මගදී අල්ලා ගැනීමට ඔබ යෙදුමට අවසර දෙයි. "<b>"ඔබ යෙදුම විශ්වාස නොකරයි නම් පිළිගන්න එපා"</b>" නැතහොත්, අනිෂ්ට මෘදුකාංගයක් මඟින් ඔබගේ දත්ත නිරාවරණය වීමේ අවදානමක් ඔබට ඇත."</string>
-    <string name="accept" msgid="2889226408765810173">"මෙම යෙදුම මට විශ්වාසයි."</string>
+    <string name="prompt" msgid="3183836924226407828">"සම්බන්ධතා ඉල්ලීම"</string>
+    <string name="warning" msgid="809658604548412033">"ජාල තදබදය නිරීක්ෂණය කිරීමට ඉඩ දෙන VPN සම්බන්ධතාවක් සැකසීමට <xliff:g id="APP">%s</xliff:g> අවශ්‍යය වේ. ප්‍රභවය ඔබ විශ්වාස කරන්නේ නම් පමණක් පිළිගන්න. VPN සක්‍රිය විට &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN සම්බන්ධිතයි"</string>
     <string name="configure" msgid="4905518375574791375">"වින්‍යාස කිරීම"</string>
     <string name="disconnect" msgid="971412338304200056">"විසන්ධි කරන්න"</string>
diff --git a/packages/VpnDialogs/res/values-sk/strings.xml b/packages/VpnDialogs/res/values-sk/strings.xml
index 6321bc2..7a06554 100644
--- a/packages/VpnDialogs/res/values-sk/strings.xml
+++ b/packages/VpnDialogs/res/values-sk/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Aplikácia <xliff:g id="APP">%s</xliff:g> sa pokúša vytvoriť pripojenie VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Ak budete pokračovať, dávate aplikácií povolenie na zastavenie celej sieťovej aktivity. "<b>"Ak aplikácii nedôverujete, NEPOKRAČUJTE."</b>" Inak riskujete, že vaše údaje budú zneužité škodlivým softvérom."</string>
-    <string name="accept" msgid="2889226408765810173">"Dôverujem tejto aplikácii."</string>
+    <string name="prompt" msgid="3183836924226407828">"Žiadosť o pripojenie"</string>
+    <string name="warning" msgid="809658604548412033">"Aplikácia <xliff:g id="APP">%s</xliff:g> žiada o nastavenie pripojenia VPN, pomocou ktorého bude môcť sledovať návštevnosť siete. Povoľte iba v prípade, že zdroju dôverujete. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; – keď je sieť VPN aktívna, zobrazuje sa v hornej časti obrazovky."</string>
     <string name="legacy_title" msgid="192936250066580964">"Sieť VPN je pripojená"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurovať"</string>
     <string name="disconnect" msgid="971412338304200056">"Odpojiť"</string>
diff --git a/packages/VpnDialogs/res/values-sl/strings.xml b/packages/VpnDialogs/res/values-sl/strings.xml
index a93b08a..9955c89 100644
--- a/packages/VpnDialogs/res/values-sl/strings.xml
+++ b/packages/VpnDialogs/res/values-sl/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Program <xliff:g id="APP">%s</xliff:g> poskuša ustvariti povezavo VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Če boste nadaljevali, boste programu dovolili prestrezanje prometa v omrežju. "<b>"Če programu ne zaupate, NE sprejmite."</b>" V nasprotnem primeru boste tvegali, da bodo podatki ranljivi za zlonamerno programsko opremo."</string>
-    <string name="accept" msgid="2889226408765810173">"Zaupam temu programu."</string>
+    <string name="prompt" msgid="3183836924226407828">"Zahteva za povezavo"</string>
+    <string name="warning" msgid="809658604548412033">"Aplikacija <xliff:g id="APP">%s</xliff:g> želi nastaviti povezavo VPN, ki omogoča nadzor omrežnega prometa. To sprejmite samo, če zaupate viru. Ko je povezava VPN aktivna, se na vrhu zaslona prikaže ikona &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"Povezava z navideznim zasebnim omrežjem je vzpostavljena"</string>
     <string name="configure" msgid="4905518375574791375">"Konfiguriranje"</string>
     <string name="disconnect" msgid="971412338304200056">"Prekini povezavo"</string>
diff --git a/packages/VpnDialogs/res/values-sr/strings.xml b/packages/VpnDialogs/res/values-sr/strings.xml
index 10a25ef..97d9d9a 100644
--- a/packages/VpnDialogs/res/values-sr/strings.xml
+++ b/packages/VpnDialogs/res/values-sr/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> покушава да направи VPN везу."</string>
-    <string name="warning" msgid="5470743576660160079">"Ако наставите, дајете апликацији дозволу да пресреће сав мрежни саобраћај. "<b>"НЕМОЈТЕ да прихватате ово осим уколико немате поверења у апликацију."</b>" У супротном, ризикујете да вам податке угрози злонамерни софтвер."</string>
-    <string name="accept" msgid="2889226408765810173">"Имам поверења у ову апликацију."</string>
+    <string name="prompt" msgid="3183836924226407828">"Захтев за повезивање"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> жели да подеси VPN везу која омогућава праћење саобраћаја на мрежи. Прихватите само ако верујете извору. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; се приказује у врху екрана када је VPN активан."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN је повезан"</string>
     <string name="configure" msgid="4905518375574791375">"Конфигуриши"</string>
     <string name="disconnect" msgid="971412338304200056">"Прекини везу"</string>
diff --git a/packages/VpnDialogs/res/values-sv/strings.xml b/packages/VpnDialogs/res/values-sv/strings.xml
index fdfc13f..7204ff0 100644
--- a/packages/VpnDialogs/res/values-sv/strings.xml
+++ b/packages/VpnDialogs/res/values-sv/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> försöker skapa en VPN-anslutning."</string>
-    <string name="warning" msgid="5470743576660160079">"Om du fortsätter ger du appen tillåtelse att stoppa all nätverkstrafik. "<b>"Godkänn inte såvida du inte litar på appen."</b>" Annars riskerar du att skadlig programvara kommer åt din information."</string>
-    <string name="accept" msgid="2889226408765810173">"Jag litar på den här appen."</string>
+    <string name="prompt" msgid="3183836924226407828">"Anslutningsförfrågan"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> vill starta en VPN-anslutning som tillåter att appen övervakar nätverkstrafiken. Godkänn endast detta om du litar på källan. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; visas längst upp på skärmen när VPN-anslutningen är aktiv."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN är anslutet"</string>
     <string name="configure" msgid="4905518375574791375">"Konfigurera"</string>
     <string name="disconnect" msgid="971412338304200056">"Koppla från"</string>
diff --git a/packages/VpnDialogs/res/values-sw/strings.xml b/packages/VpnDialogs/res/values-sw/strings.xml
index f987aed..a0fb7c3 100644
--- a/packages/VpnDialogs/res/values-sw/strings.xml
+++ b/packages/VpnDialogs/res/values-sw/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> inajaribu kuunda muunganisho wa VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Kwa kuendelea, unapatia programu kibali cha kuingilia trafiki ya mitandao yote."<b>"USIKUBALI isipokuwa uwe unaamini programu."</b>" La sivyo, utakua katika hatari ya data yako kuathiriwa na programu hasidi."</string>
-    <string name="accept" msgid="2889226408765810173">"Ninaamini programu hii."</string>
+    <string name="prompt" msgid="3183836924226407828">"Ombi la muunganisho"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> inataka kusanidi muunganisho wa VPN utakaoiruhusu kufuatilia trafiki ya mtandao. Kubali ikiwa tu unakiamini chanzo. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; huonekana sehemu ya juu ya skrini yako VPN inapofanya kazi."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN imeunganishwa"</string>
     <string name="configure" msgid="4905518375574791375">"Sanidi"</string>
     <string name="disconnect" msgid="971412338304200056">"Tenganisha"</string>
diff --git a/packages/VpnDialogs/res/values-ta-rIN/strings.xml b/packages/VpnDialogs/res/values-ta-rIN/strings.xml
index b8d32be..f03d3e4 100644
--- a/packages/VpnDialogs/res/values-ta-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-ta-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"VPN இணைப்பை உருவாக்க <xliff:g id="APP">%s</xliff:g> முயற்சிக்கிறது."</string>
-    <string name="warning" msgid="5470743576660160079">"தொடர்வதன்மூலம், எல்லா நெட்வொர்க் ட்ராஃபிக்கையும் இடைமறிக்க பயன்பாட்டிற்கு அனுமதியளிக்கிறீர்கள். "<b>"நீங்கள் பயன்பாட்டை நம்பினால் ஒழிய இதை ஒப்புக்கொள்ள வேண்டாம்."</b>" இல்லையெனில், தீங்குவிளைவிக்கும் மென்பொருள் மூலம் உங்களின் தரவை திருட வாய்ப்பளிக்கிறீர்கள்."</string>
-    <string name="accept" msgid="2889226408765810173">"இந்தப் பயன்பாட்டை நம்புகிறேன்."</string>
+    <string name="prompt" msgid="3183836924226407828">"இணைப்புக் கோரிக்கை"</string>
+    <string name="warning" msgid="809658604548412033">"VPN இணைப்பை அமைக்க <xliff:g id="APP">%s</xliff:g> விழைகிறது அதன்மூலம் இது நெட்வொர்க் ட்ராஃபிக்கைக் கண்காணிக்கும் அனுமதியைப் பெறும். நம்பகமான மூலத்தை மட்டுமே ஏற்கவும். VPN இயக்கத்தில் உள்ளபோது திரையில் மேல் பகுதியில் &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; தோன்றும்."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN இணைக்கப்பட்டது"</string>
     <string name="configure" msgid="4905518375574791375">"உள்ளமை"</string>
     <string name="disconnect" msgid="971412338304200056">"தொடர்பைத் துண்டி"</string>
diff --git a/packages/VpnDialogs/res/values-te-rIN/strings.xml b/packages/VpnDialogs/res/values-te-rIN/strings.xml
index 3b178d2..609b74d 100644
--- a/packages/VpnDialogs/res/values-te-rIN/strings.xml
+++ b/packages/VpnDialogs/res/values-te-rIN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"VPN కనెక్షన్‌ను రూపొందించడానికి <xliff:g id="APP">%s</xliff:g> ప్రయత్నిస్తోంది."</string>
-    <string name="warning" msgid="5470743576660160079">"కొనసాగడం ద్వారా, మీరు నెట్‌వర్క్ ట్రాఫిక్ మొత్తాన్ని అడ్డగించడానికి అనువర్తనానికి అనుమతి ఇస్తున్నారు. "<b>"మీరు అనువర్తనాన్ని విశ్వసిస్తే మినహా ఆమోదించవద్దు."</b>" లేకపోతే, మీరు హానికరమైన సాఫ్ట్‌వేర్ ద్వారా మీ డేటా రాజీపడే ప్రమాదాన్ని ఎదుర్కొంటారు."</string>
-    <string name="accept" msgid="2889226408765810173">"నేను ఈ అనువర్తనాన్ని విశ్వసిస్తున్నాను."</string>
+    <string name="prompt" msgid="3183836924226407828">"కనెక్షన్ అభ్యర్థన"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> నెట్‌వర్క్ ట్రాఫిక్‌ని పర్యవేక్షించగలగడానికి VPN కనెక్షన్‌ను సెటప్ చేయాలనుకుంటోంది. మీరు మూలాన్ని విశ్వసిస్తే మాత్రమే ఆమోదించండి. VPN సక్రియంగా ఉన్నప్పుడు మీ స్క్రీన్ ఎగువన &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; కనిపిస్తుంది."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN కనెక్ట్ చేయబడింది"</string>
     <string name="configure" msgid="4905518375574791375">"కాన్ఫిగర్ చేయి"</string>
     <string name="disconnect" msgid="971412338304200056">"డిస్‌కనెక్ట్ చేయి"</string>
diff --git a/packages/VpnDialogs/res/values-th/strings.xml b/packages/VpnDialogs/res/values-th/strings.xml
index 0b4a31c..1b5f0a8 100644
--- a/packages/VpnDialogs/res/values-th/strings.xml
+++ b/packages/VpnDialogs/res/values-th/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> พยายามจะสร้างการเชื่อมต่อ VPN"</string>
-    <string name="warning" msgid="5470743576660160079">"การดำเนินการต่อหมายถึงคุณอนุญาตให้แอปพลิเคชันเข้าขัดจังหวะการเข้าใช้งานเครือข่ายทั้งหมด "<b>"อย่ายอมรับหากคุณไม่วางใจแอปพลิเคชัน"</b>" มิฉะนั้น คุณอาจเสี่ยงต่อการถูกขโมยข้อมูลจากซอฟต์แวร์ที่เป็นอันตรายได้"</string>
-    <string name="accept" msgid="2889226408765810173">"ฉันวางใจแอปพลิเคชันนี้"</string>
+    <string name="prompt" msgid="3183836924226407828">"ขอการเชื่อมต่อ"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ต้องการติดตั้งการเชื่อมต่อ VPN เพื่อให้แอปสามารถตรวจสอบการเข้าใช้งานเครือข่าย โปรดยอมรับหากคุณเชื่อถือแหล่งที่มานี้เท่านั้น &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; จะปรากฏที่ด้านบนหน้าจอเมื่อมีการใช้งาน VPN อยู่"</string>
     <string name="legacy_title" msgid="192936250066580964">"เชื่อมต่อ VPN แล้ว"</string>
     <string name="configure" msgid="4905518375574791375">"กำหนดค่า"</string>
     <string name="disconnect" msgid="971412338304200056">"ยกเลิกการเชื่อมต่อ"</string>
diff --git a/packages/VpnDialogs/res/values-tl/strings.xml b/packages/VpnDialogs/res/values-tl/strings.xml
index 725a512..a115ae5 100644
--- a/packages/VpnDialogs/res/values-tl/strings.xml
+++ b/packages/VpnDialogs/res/values-tl/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> (na) pagtatangka upang lumikha ng koneksyon ng VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Sa pamamagitan ng pagpapatuloy, binibigyan mo ng pahintulot ang application na harangin ang lahat ng trapiko ng network. "<b>"HUWAG tanggapin maliban kung nagtitiwala ka sa application."</b>" Kung hindi naman, may peligro kang makompromiso ang iyong data ng nakakapanghamak na software."</string>
-    <string name="accept" msgid="2889226408765810173">"Nagtitiwala ako sa application na ito."</string>
+    <string name="prompt" msgid="3183836924226407828">"Kahilingan sa koneksyon"</string>
+    <string name="warning" msgid="809658604548412033">"Gusto ng <xliff:g id="APP">%s</xliff:g> na mag-set up ng koneksyon sa VPN na nagbibigay-daan ditong masubaybayan ang trapiko ng network. Tanggapin lang kung pinagkakatiwalaan mo ang pinagmulan. Lalabas ang &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; sa itaas ng iyong screen kapag aktibo ang VPN."</string>
     <string name="legacy_title" msgid="192936250066580964">"Nakakonekta ang VPN"</string>
     <string name="configure" msgid="4905518375574791375">"I-configure"</string>
     <string name="disconnect" msgid="971412338304200056">"Idiskonekta"</string>
diff --git a/packages/VpnDialogs/res/values-tr/strings.xml b/packages/VpnDialogs/res/values-tr/strings.xml
index 704a8cd..abebeca 100644
--- a/packages/VpnDialogs/res/values-tr/strings.xml
+++ b/packages/VpnDialogs/res/values-tr/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>, VPN bağlantısı kurmaya çalışıyor."</string>
-    <string name="warning" msgid="5470743576660160079">"Devam ederek uygulamaya tüm ağ trafiğini kesme iznini veriyorsunuz. "<b>"Uygulamaya güvenmiyorsanız kabul ETMEYİN."</b>" Aksi halde kötü amaçlı yazılımlar verilerinizin güvenliğini tamamen tehlikeye atabilir."</string>
-    <string name="accept" msgid="2889226408765810173">"Bu uygulamaya güveniyorum."</string>
+    <string name="prompt" msgid="3183836924226407828">"Bağlantı isteği"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ağ trafiğini izlemesine olanak veren bir VPN bağlantısı oluşturmak istiyor. Sadece, ilgili kaynağa güveniyorsanız kabul edin. &lt;br /&gt; &lt;br /&gt; VPN aktif olduğunda ekranınızın üst tarafında &lt;img src=vpn_icon /&gt; simgesi görünür."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN bağlı"</string>
     <string name="configure" msgid="4905518375574791375">"Yapılandır"</string>
     <string name="disconnect" msgid="971412338304200056">"Bağlantıyı kes"</string>
diff --git a/packages/VpnDialogs/res/values-uk/strings.xml b/packages/VpnDialogs/res/values-uk/strings.xml
index b0db053..eed37ee 100644
--- a/packages/VpnDialogs/res/values-uk/strings.xml
+++ b/packages/VpnDialogs/res/values-uk/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"Спроб створити з’єднання з мережею VPN: <xliff:g id="APP">%s</xliff:g>."</string>
-    <string name="warning" msgid="5470743576660160079">"Продовжуючи, ви дозволяєте цій програмі перехоплювати весь трафік мережі. "<b>"НЕ погоджуйтеся, якщо ви не довіряєте цій програмі."</b>" Інакше є небезпека пошкодження ваших даних шкідливим програмним забезпеченням."</string>
-    <string name="accept" msgid="2889226408765810173">"Я довіряю цій програмі."</string>
+    <string name="prompt" msgid="3183836924226407828">"Запит на під’єднання"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> хоче під’єднатися до мережі VPN, щоб контролювати мережевий трафік. Дозволяйте, якщо довіряєте джерелу. Коли мережа VPN активна, угорі екрана відображається значок &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt;."</string>
     <string name="legacy_title" msgid="192936250066580964">"Мережу VPN під’єднано"</string>
     <string name="configure" msgid="4905518375574791375">"Налаштувати"</string>
     <string name="disconnect" msgid="971412338304200056">"Від’єднати"</string>
diff --git a/packages/VpnDialogs/res/values-ur-rPK/strings.xml b/packages/VpnDialogs/res/values-ur-rPK/strings.xml
index 0003d61..34f72c8 100644
--- a/packages/VpnDialogs/res/values-ur-rPK/strings.xml
+++ b/packages/VpnDialogs/res/values-ur-rPK/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"‏<xliff:g id="APP">%s</xliff:g> ایک VPN کنکشن بنانے کی کوشش کرتی ہے۔"</string>
-    <string name="warning" msgid="5470743576660160079">"جاری رکھ کر، آپ ایپلیکیشن کو سبھی نیٹ ورک ٹریفک قطع کرنے کی اجازت دے رہے ہیں۔ "<b>"اس وقت تک قبول نہ کریں جب تک آپ کو اس ایپلیکیشن پر بھروسہ نہ ہو۔"</b>" بصورت دیگر، آپ کے ڈیٹا کو ایک نقصان دہ سافٹ ویئر سے متاثر ہونے کا خطرہ ہے۔"</string>
-    <string name="accept" msgid="2889226408765810173">"مجھے اس ایپلیکیشن پر بھروسہ ہے۔"</string>
+    <string name="prompt" msgid="3183836924226407828">"کنکشن کی درخواست"</string>
+    <string name="warning" msgid="809658604548412033">"‏<xliff:g id="APP">%s</xliff:g> ایک ایسا VPN کنکشن ترتیب دینا چاہتی ہے جو اسے نیٹ ورک ٹریفک کو مانیٹر کرنے کی اجازت دیتا ہے۔ اگر آپ کو ماخذ پر بھروسہ ہے تبھی قبول کریں۔ &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; آپ کی اسکرین کے اوپر اس وقت ظاہر ہوتا ہے جب VPN فعال ہوتا ہے۔"</string>
     <string name="legacy_title" msgid="192936250066580964">"‏VPN مربوط ہے"</string>
     <string name="configure" msgid="4905518375574791375">"ترتیب دیں"</string>
     <string name="disconnect" msgid="971412338304200056">"منقطع کریں"</string>
diff --git a/packages/VpnDialogs/res/values-uz-rUZ/strings.xml b/packages/VpnDialogs/res/values-uz-rUZ/strings.xml
index 34a82b9..9185297 100644
--- a/packages/VpnDialogs/res/values-uz-rUZ/strings.xml
+++ b/packages/VpnDialogs/res/values-uz-rUZ/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> VPN ulanish yaratishga urinib ko‘rdi."</string>
-    <string name="warning" msgid="5470743576660160079">"Davom ettirsangiz, ilova dasturga butun tarmoq trafigidan foydalanish huquqini berasiz. "<b>"Dasturga ishonmasangiz, RUXSAT BERMANG."</b>" Aks holda, xavfli dasturlar yordamida ma\'lumlaringizni yovuz niyatli kishilarga uzatish xavfi tug‘iladi."</string>
-    <string name="accept" msgid="2889226408765810173">"Men ushbu dasturga ishonaman."</string>
+    <string name="prompt" msgid="3183836924226407828">"Ulanish uchun so‘rov"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ilovasi tarmoq trafigini kuzatish uchun VPN ulanishini o‘rnatmoqchi. Agar ilova manbasiga ishonsangiz, unga rozi bo‘ling. VPN faol bo‘lsa, ekran tepasida &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; paydo bo‘ladi."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN ulangan"</string>
     <string name="configure" msgid="4905518375574791375">"Moslash"</string>
     <string name="disconnect" msgid="971412338304200056">"Aloqani uzish"</string>
diff --git a/packages/VpnDialogs/res/values-vi/strings.xml b/packages/VpnDialogs/res/values-vi/strings.xml
index 8cc8e71..c7df53f 100644
--- a/packages/VpnDialogs/res/values-vi/strings.xml
+++ b/packages/VpnDialogs/res/values-vi/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> cố gắng tạo kết nối VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Khi tiếp tục, bạn sẽ cho phép ứng dụng cấp quyền ngăn chặn tất cả lưu lượng mạng. "<b>"KHÔNG chấp nhận trừ khi bạn tin cậy ứng dụng."</b>" Nếu không, bạn có nguy cơ bị phần mềm độc hại xâm phạm dữ liệu."</string>
-    <string name="accept" msgid="2889226408765810173">"Tôi tin cậy ứng dụng này."</string>
+    <string name="prompt" msgid="3183836924226407828">"Yêu cầu kết nối"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> muốn thiết lập kết nối VPN cho phép ứng dụng giám sát lưu lượng truy cập mạng. Chỉ chấp nhận nếu bạn tin tưởng nguồn. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; xuất hiện ở đầu màn hình của bạn khi VPN đang hoạt động."</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN được kết nối"</string>
     <string name="configure" msgid="4905518375574791375">"Định cấu hình"</string>
     <string name="disconnect" msgid="971412338304200056">"Ngắt kết nối"</string>
diff --git a/packages/VpnDialogs/res/values-zh-rCN/strings.xml b/packages/VpnDialogs/res/values-zh-rCN/strings.xml
index b175d0c..a77ba3b 100644
--- a/packages/VpnDialogs/res/values-zh-rCN/strings.xml
+++ b/packages/VpnDialogs/res/values-zh-rCN/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g>尝试创建VPN连接。"</string>
-    <string name="warning" msgid="5470743576660160079">"继续操作即表示您授予此应用拦截所有网络流量的权限。"<b>"除非您信任此应用,否则请勿接受此请求。"</b>"如果您在不信任该应用的情况下接受了此请求,则可能会面临数据遭到恶意软件盗用的风险。"</string>
-    <string name="accept" msgid="2889226408765810173">"我信任此应用。"</string>
+    <string name="prompt" msgid="3183836924226407828">"连接请求"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g>想要设置一个VPN连接(可被用于监控网络流量)。请只在您信任该来源的情况下才接受此请求。在VPN处于活动状态时,您的屏幕顶部会显示 &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; 图标。"</string>
     <string name="legacy_title" msgid="192936250066580964">"已连接VPN"</string>
     <string name="configure" msgid="4905518375574791375">"配置"</string>
     <string name="disconnect" msgid="971412338304200056">"断开连接"</string>
diff --git a/packages/VpnDialogs/res/values-zh-rHK/strings.xml b/packages/VpnDialogs/res/values-zh-rHK/strings.xml
index 8b25d41..fa77c6c 100644
--- a/packages/VpnDialogs/res/values-zh-rHK/strings.xml
+++ b/packages/VpnDialogs/res/values-zh-rHK/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> 嘗試建立 VPN 連線。"</string>
-    <string name="warning" msgid="5470743576660160079">"如果繼續進行,即表示您允許該應用程式攔截所有網絡流量。"<b>"除非您信任該應用程式,否則不應接受。"</b>"不然就會讓您的資料陷於遭惡意程式入侵的風險。"</string>
-    <string name="accept" msgid="2889226408765810173">"我信任這個應用程式。"</string>
+    <string name="prompt" msgid="3183836924226407828">"連線要求"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> 要求設定 VPN 連線以監控網絡流量。除非您信任要求來源,否則請勿隨意接受要求。&lt;br /&gt; &lt;br /&gt;VPN 啟用時,畫面頂端會顯示 &lt;img src=vpn_icon /&gt;。"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN 已連線"</string>
     <string name="configure" msgid="4905518375574791375">"設定"</string>
     <string name="disconnect" msgid="971412338304200056">"中斷連線"</string>
diff --git a/packages/VpnDialogs/res/values-zh-rTW/strings.xml b/packages/VpnDialogs/res/values-zh-rTW/strings.xml
index 080330f..1a7ab35 100644
--- a/packages/VpnDialogs/res/values-zh-rTW/strings.xml
+++ b/packages/VpnDialogs/res/values-zh-rTW/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> 嘗試建立 VPN 連線。"</string>
-    <string name="warning" msgid="5470743576660160079">"如果繼續進行,即表示您允許該應用程式攔截所有網路流量。"<b>"除非您信任該應用程式,否則「請勿」接受,"</b>"以免讓您的資料遭到惡意軟體入侵。"</string>
-    <string name="accept" msgid="2889226408765810173">"我信任這個應用程式。"</string>
+    <string name="prompt" msgid="3183836924226407828">"連線要求"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> 要求設定 VPN 連線,允許此要求即開放該來源監控網路流量。除非您信任該來源,否則請勿任意接受要求。&lt;br /&gt; &lt;br /&gt;VPN 啟用時,畫面頂端會顯示 &lt;img src=vpn_icon /&gt;。"</string>
     <string name="legacy_title" msgid="192936250066580964">"VPN 已連線"</string>
     <string name="configure" msgid="4905518375574791375">"設定"</string>
     <string name="disconnect" msgid="971412338304200056">"中斷連線"</string>
diff --git a/packages/VpnDialogs/res/values-zu/strings.xml b/packages/VpnDialogs/res/values-zu/strings.xml
index 4594748..abe54a9 100644
--- a/packages/VpnDialogs/res/values-zu/strings.xml
+++ b/packages/VpnDialogs/res/values-zu/strings.xml
@@ -16,9 +16,8 @@
 
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="prompt" msgid="8359175999006833462">"<xliff:g id="APP">%s</xliff:g> izama ukwenza uxhumano lwe-VPN."</string>
-    <string name="warning" msgid="5470743576660160079">"Ngokuqhubeka, unikeza uhlelo lokusebenza imvume yokuvimbela ukuphithizela kwenethiwekhi. "<b>"UNGAVUMELI ngaphandle uma wethemba uhlelo lokusebenza."</b>" Noma, ungathatha ingozi yokuba idatha yakho ibe sengcupheni yokufinyelelwa isofthiwe e-malicious."</string>
-    <string name="accept" msgid="2889226408765810173">"Ngiyaluthemba lolu hlelo lokusebenza."</string>
+    <string name="prompt" msgid="3183836924226407828">"Isicelo soxhumo"</string>
+    <string name="warning" msgid="809658604548412033">"<xliff:g id="APP">%s</xliff:g> ifuna ukusetha uxhumo lwe-VPN eyivumela ukwengamela ithrafikhi yenethiwekhi. Yamukela kuphela uma wethemba umthombo. &lt;br /&gt; &lt;br /&gt; &lt;img src=vpn_icon /&gt; ibonakala phezu kwesikrini sakho uma i-VPN isebenza."</string>
     <string name="legacy_title" msgid="192936250066580964">"I-VPN ixhunyiwe"</string>
     <string name="configure" msgid="4905518375574791375">"Misa"</string>
     <string name="disconnect" msgid="971412338304200056">"Ayixhumekile kwi-inthanethi"</string>
diff --git a/packages/VpnDialogs/res/values/strings.xml b/packages/VpnDialogs/res/values/strings.xml
index 3ff767a..406bcc3 100644
--- a/packages/VpnDialogs/res/values/strings.xml
+++ b/packages/VpnDialogs/res/values/strings.xml
@@ -17,21 +17,18 @@
 <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
 
     <!-- Dialog title to identify the request from a VPN application. [CHAR LIMIT=60] -->
-    <string name="prompt"><xliff:g id="app">%s</xliff:g>
-        attempts to create a VPN connection.
-    </string>
+    <string name="prompt">Connection request</string>
 
     <!-- Dialog message to warn about the risk of using a VPN application. [CHAR LIMIT=NONE] -->
-    <string name="warning">By proceeding, you are giving the application
-        permission to intercept all network traffic.
-        <b>Do NOT accept unless you trust the application.</b> Otherwise,
-        you run the risk of having your data compromised by a malicious
-        software.
+    <string name="warning"><xliff:g id="app">%s</xliff:g> wants to set up a VPN connection
+        that allows it to monitor network traffic. Only accept if you trust the source.
+        <![CDATA[
+        <br />
+        <br />
+        <img src="vpn_icon" />
+        ]]> appears at the top of your screen when VPN is active.
     </string>
 
-    <!-- Checkbox label to accept the request from a VPN application. [CHAR LIMIT=60] -->
-    <string name="accept">I trust this application.</string>
-
     <!-- Dialog title for built-in VPN. [CHAR LIMIT=40]  -->
     <string name="legacy_title">VPN is connected</string>
     <!-- Button label to configure the current VPN session. [CHAR LIMIT=20] -->
diff --git a/packages/VpnDialogs/src/com/android/vpndialogs/ConfirmDialog.java b/packages/VpnDialogs/src/com/android/vpndialogs/ConfirmDialog.java
index ddafc66..897c96cf 100644
--- a/packages/VpnDialogs/src/com/android/vpndialogs/ConfirmDialog.java
+++ b/packages/VpnDialogs/src/com/android/vpndialogs/ConfirmDialog.java
@@ -18,21 +18,28 @@
 
 import android.content.Context;
 import android.content.DialogInterface;
+import android.content.Intent;
 import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager;
+import android.content.pm.ResolveInfo;
+import android.graphics.drawable.Drawable;
 import android.net.IConnectivityManager;
+import android.net.VpnService;
 import android.os.ServiceManager;
+import android.text.Html;
+import android.text.Html.ImageGetter;
 import android.util.Log;
 import android.view.View;
 import android.widget.Button;
-import android.widget.CompoundButton;
-import android.widget.ImageView;
 import android.widget.TextView;
 
 import com.android.internal.app.AlertActivity;
+import com.android.internal.net.VpnConfig;
 
-public class ConfirmDialog extends AlertActivity implements
-        CompoundButton.OnCheckedChangeListener, DialogInterface.OnClickListener {
+import java.util.List;
+
+public class ConfirmDialog extends AlertActivity
+        implements DialogInterface.OnClickListener, ImageGetter {
     private static final String TAG = "VpnConfirm";
 
     private String mPackage;
@@ -56,27 +63,22 @@
                 return;
             }
 
-            PackageManager pm = getPackageManager();
-            ApplicationInfo app = pm.getApplicationInfo(mPackage, 0);
-
             View view = View.inflate(this, R.layout.confirm, null);
-            ((ImageView) view.findViewById(R.id.icon)).setImageDrawable(app.loadIcon(pm));
-            ((TextView) view.findViewById(R.id.prompt)).setText(
-                    getString(R.string.prompt, app.loadLabel(pm)));
-            ((CompoundButton) view.findViewById(R.id.check)).setOnCheckedChangeListener(this);
 
-            mAlertParams.mIconAttrId = android.R.attr.alertDialogIcon;
-            mAlertParams.mTitle = getText(android.R.string.dialog_alert_title);
+            ((TextView) view.findViewById(R.id.warning)).setText(
+                    Html.fromHtml(
+                            getString(R.string.warning, VpnConfig.getVpnLabel(this, mPackage)),
+                    this, null /* tagHandler */));
+
+            mAlertParams.mTitle = getText(R.string.prompt);
             mAlertParams.mPositiveButtonText = getText(android.R.string.ok);
             mAlertParams.mPositiveButtonListener = this;
             mAlertParams.mNegativeButtonText = getText(android.R.string.cancel);
-            mAlertParams.mNegativeButtonListener = this;
             mAlertParams.mView = view;
             setupAlert();
 
             getWindow().setCloseOnTouchOutside(false);
             mButton = mAlert.getButton(DialogInterface.BUTTON_POSITIVE);
-            mButton.setEnabled(false);
             mButton.setFilterTouchesWhenObscured(true);
         } catch (Exception e) {
             Log.e(TAG, "onResume", e);
@@ -85,18 +87,24 @@
     }
 
     @Override
-    public void onBackPressed() {
+    public Drawable getDrawable(String source) {
+        // Should only reach this when fetching the VPN icon for the warning string.
+        Drawable icon = getDrawable(R.drawable.ic_vpn_dialog);
+        icon.setBounds(0, 0, icon.getIntrinsicWidth(), icon.getIntrinsicHeight());
+        return icon;
     }
 
     @Override
-    public void onCheckedChanged(CompoundButton button, boolean checked) {
-        mButton.setEnabled(checked);
+    public void onBackPressed() {
     }
 
     @Override
     public void onClick(DialogInterface dialog, int which) {
         try {
-            if (which == DialogInterface.BUTTON_POSITIVE && mService.prepareVpn(null, mPackage)) {
+            if (mService.prepareVpn(null, mPackage)) {
+                // Authorize this app to initiate VPN connections in the future without user
+                // intervention.
+                mService.setVpnPackageAuthorization(true);
                 setResult(RESULT_OK);
             }
         } catch (Exception e) {
diff --git a/packages/VpnDialogs/src/com/android/vpndialogs/ManageDialog.java b/packages/VpnDialogs/src/com/android/vpndialogs/ManageDialog.java
index eb20995..cc8500a 100644
--- a/packages/VpnDialogs/src/com/android/vpndialogs/ManageDialog.java
+++ b/packages/VpnDialogs/src/com/android/vpndialogs/ManageDialog.java
@@ -18,8 +18,6 @@
 
 import android.content.Context;
 import android.content.DialogInterface;
-import android.content.pm.ApplicationInfo;
-import android.content.pm.PackageManager;
 import android.net.IConnectivityManager;
 import android.os.Handler;
 import android.os.Message;
@@ -83,13 +81,9 @@
             mDataRowsHidden = true;
 
             if (mConfig.legacy) {
-                mAlertParams.mIconId = android.R.drawable.ic_dialog_info;
                 mAlertParams.mTitle = getText(R.string.legacy_title);
             } else {
-                PackageManager pm = getPackageManager();
-                ApplicationInfo app = pm.getApplicationInfo(mConfig.user, 0);
-                mAlertParams.mIcon = app.loadIcon(pm);
-                mAlertParams.mTitle = app.loadLabel(pm);
+                mAlertParams.mTitle = VpnConfig.getVpnLabel(this, mConfig.user);
             }
             if (mConfig.configureIntent != null) {
                 mAlertParams.mPositiveButtonText = getText(R.string.configure);
diff --git a/phone/java/android/phone/PhoneManager.java b/phone/java/android/phone/PhoneManager.java
deleted file mode 100644
index f61b054..0000000
--- a/phone/java/android/phone/PhoneManager.java
+++ /dev/null
@@ -1,127 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.phone;
-
-import android.content.Context;
-import android.os.RemoteException;
-import android.os.ServiceManager;
-import android.util.Log;
-
-import com.android.internal.telecomm.ITelecommService;
-
-/**
- * Exposes call-related functionality for use by phone and dialer apps.
- */
-public final class PhoneManager {
-    private static final String TAG = PhoneManager.class.getSimpleName();
-
-    private final Context mContext;
-
-    /**
-     * @hide
-     */
-    public PhoneManager(Context context) {
-        Context appContext = context.getApplicationContext();
-        if (appContext != null) {
-            mContext = appContext;
-        } else {
-            mContext = context;
-        }
-    }
-
-    /**
-     * Processes the specified dial string as an MMI code.
-     * <p>
-     * Requires that the method-caller be set as the system dialer app.
-     * </p>
-     *
-     * @param dialString The digits to dial.
-     * @return True if the digits were processed as an MMI code, false otherwise.
-     */
-    public boolean handlePinMmi(String dialString) {
-        ITelecommService service = getTelecommService();
-        if (service != null) {
-            try {
-                return service.handlePinMmi(dialString);
-            } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#handlePinMmi", e);
-            }
-        }
-        return false;
-    }
-
-    /**
-     * Removes the missed-call notification if one is present.
-     * <p>
-     * Requires that the method-caller be set as the system dialer app.
-     * </p>
-     */
-    public void cancelMissedCallsNotification() {
-        ITelecommService service = getTelecommService();
-        if (service != null) {
-            try {
-                service.cancelMissedCallsNotification();
-            } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#cancelMissedCallsNotification", e);
-            }
-        }
-    }
-
-    /**
-     * Brings the in-call screen to the foreground if there is an ongoing call. If there is
-     * currently no ongoing call, then this method does nothing.
-     * <p>
-     * Requires that the method-caller be set as the system dialer app or have the
-     * {@link android.Manifest.permission#READ_PHONE_STATE} permission.
-     * </p>
-     *
-     * @param showDialpad Brings up the in-call dialpad as part of showing the in-call screen.
-     */
-    public void showCallScreen(boolean showDialpad) {
-        ITelecommService service = getTelecommService();
-        if (service != null) {
-            try {
-                service.showCallScreen(showDialpad);
-            } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#showCallScreen", e);
-            }
-        }
-    }
-
-    /**
-     * Returns whether there is an ongoing phone call.
-     * <p>
-     * Requires permission: {@link android.Manifest.permission#READ_PHONE_STATE}
-     * </p>
-     */
-    public boolean isInAPhoneCall() {
-        ITelecommService service = getTelecommService();
-        if (service != null) {
-            try {
-                return service.isInAPhoneCall();
-            } catch (RemoteException e) {
-                Log.e(TAG, "Error caling ITelecommService#isInAPhoneCall", e);
-            }
-        }
-        return false;
-    }
-
-    private ITelecommService getTelecommService() {
-        return ITelecommService.Stub.asInterface(
-                ServiceManager.getService(Context.TELECOMM_SERVICE));
-    }
-}
diff --git a/policy/src/com/android/internal/policy/impl/EnableAccessibilityController.java b/policy/src/com/android/internal/policy/impl/EnableAccessibilityController.java
index 71b0d53..6f79f58 100644
--- a/policy/src/com/android/internal/policy/impl/EnableAccessibilityController.java
+++ b/policy/src/com/android/internal/policy/impl/EnableAccessibilityController.java
@@ -83,6 +83,7 @@
 
 
     private final Context mContext;
+    private final Runnable mOnAccessibilityEnabledCallback;
     private final UserManager mUserManager;
     private final TextToSpeech mTts;
     private final Ringtone mTone;
@@ -97,8 +98,9 @@
     private float mSecondPointerDownX;
     private float mSecondPointerDownY;
 
-    public EnableAccessibilityController(Context context) {
+    public EnableAccessibilityController(Context context, Runnable onAccessibilityEnabledCallback) {
         mContext = context;
+        mOnAccessibilityEnabledCallback = onAccessibilityEnabledCallback;
         mUserManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
         mTts = new TextToSpeech(context, new TextToSpeech.OnInitListener() {
             @Override
@@ -275,5 +277,7 @@
                 /* ignore */
             }
         }
+
+        mOnAccessibilityEnabledCallback.run();
     }
 }
diff --git a/policy/src/com/android/internal/policy/impl/GlobalActions.java b/policy/src/com/android/internal/policy/impl/GlobalActions.java
index da8ec2a..7b41391 100644
--- a/policy/src/com/android/internal/policy/impl/GlobalActions.java
+++ b/policy/src/com/android/internal/policy/impl/GlobalActions.java
@@ -272,15 +272,19 @@
                 mItems.add(new PowerAction());
             } else if (GLOBAL_ACTION_KEY_AIRPLANE.equals(actionKey)) {
                 mItems.add(mAirplaneModeOn);
-            } else if (GLOBAL_ACTION_KEY_BUGREPORT.equals(actionKey)
-                    && (Settings.Global.getInt(mContext.getContentResolver(),
-                        Settings.Global.BUGREPORT_IN_POWER_MENU, 0) != 0 && isCurrentUserOwner())) {
-                mItems.add(getBugReportAction());
-            } else if (GLOBAL_ACTION_KEY_SILENT.equals(actionKey) && mShowSilentToggle) {
-                mItems.add(mSilentModeAction);
-            } else if (GLOBAL_ACTION_KEY_USERS.equals(actionKey)
-                    && SystemProperties.getBoolean("fw.power_user_switcher", false)) {
-                addUsersToMenu(mItems);
+            } else if (GLOBAL_ACTION_KEY_BUGREPORT.equals(actionKey)) {
+                if (Settings.Global.getInt(mContext.getContentResolver(),
+                        Settings.Global.BUGREPORT_IN_POWER_MENU, 0) != 0 && isCurrentUserOwner()) {
+                    mItems.add(getBugReportAction());
+                }
+            } else if (GLOBAL_ACTION_KEY_SILENT.equals(actionKey)) {
+                if (mShowSilentToggle) {
+                    mItems.add(mSilentModeAction);
+                }
+            } else if (GLOBAL_ACTION_KEY_USERS.equals(actionKey)) {
+                if (SystemProperties.getBoolean("fw.power_user_switcher", false)) {
+                    addUsersToMenu(mItems);
+                }
             } else if (GLOBAL_ACTION_KEY_SETTINGS.equals(actionKey)) {
                 mItems.add(getSettingsAction());
             } else if (GLOBAL_ACTION_KEY_LOCKDOWN.equals(actionKey)) {
@@ -409,7 +413,7 @@
             @Override
             public void onPress() {
                 Intent intent = new Intent(Settings.ACTION_SETTINGS);
-                intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
+                intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP);
                 mContext.startActivity(intent);
             }
 
@@ -1069,7 +1073,13 @@
             // is dismissed on the first down while the global gesture is a long press
             // with two fingers anywhere on the screen.
             if (EnableAccessibilityController.canEnableAccessibilityViaGesture(mContext)) {
-                mEnableAccessibilityController = new EnableAccessibilityController(mContext);
+                mEnableAccessibilityController = new EnableAccessibilityController(mContext,
+                        new Runnable() {
+                    @Override
+                    public void run() {
+                        dismiss();
+                    }
+                });
                 super.setCanceledOnTouchOutside(false);
             } else {
                 mEnableAccessibilityController = null;
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindow.java b/policy/src/com/android/internal/policy/impl/PhoneWindow.java
index 964acbd..57ed619 100644
--- a/policy/src/com/android/internal/policy/impl/PhoneWindow.java
+++ b/policy/src/com/android/internal/policy/impl/PhoneWindow.java
@@ -33,6 +33,7 @@
 import com.android.internal.view.menu.MenuPresenter;
 import com.android.internal.view.menu.MenuView;
 import com.android.internal.widget.ActionBarContextView;
+import com.android.internal.widget.BackgroundFallback;
 import com.android.internal.widget.DecorContentParent;
 import com.android.internal.widget.SwipeDismissLayout;
 
@@ -124,6 +125,7 @@
     private static final int CUSTOM_TITLE_COMPATIBLE_FEATURES = DEFAULT_FEATURES |
             (1 << FEATURE_CUSTOM_TITLE) |
             (1 << FEATURE_CONTENT_TRANSITIONS) |
+            (1 << FEATURE_ACTIVITY_TRANSITIONS) |
             (1 << FEATURE_ACTION_MODE_OVERLAY);
 
     private static final Transition USE_DEFAULT_TRANSITION = new TransitionSet();
@@ -149,6 +151,8 @@
     // mDecor itself, or a child of mDecor where the contents go.
     private ViewGroup mContentParent;
 
+    private ViewGroup mContentRoot;
+
     SurfaceHolder.Callback2 mTakeSurfaceCallback;
 
     InputQueue.Callback mTakeInputQueueCallback;
@@ -208,6 +212,7 @@
     private ProgressBar mHorizontalProgressBar;
 
     private int mBackgroundResource = 0;
+    private int mBackgroundFallbackResource = 0;
 
     private Drawable mBackgroundDrawable;
 
@@ -264,9 +269,10 @@
     private Transition mSharedElementReturnTransition = USE_DEFAULT_TRANSITION;
     private Transition mSharedElementExitTransition = null;
     private Transition mSharedElementReenterTransition = USE_DEFAULT_TRANSITION;
-    private Boolean mAllowExitTransitionOverlap;
+    private Boolean mAllowReturnTransitionOverlap;
     private Boolean mAllowEnterTransitionOverlap;
     private long mBackgroundFadeDurationMillis = -1;
+    private Boolean mSharedElementsUseOverlay;
 
     static class WindowManagerHolder {
         static final IWindowManager sWindowManager = IWindowManager.Stub.asInterface(
@@ -875,6 +881,13 @@
         }
     }
 
+    void doPendingInvalidatePanelMenu() {
+        if (mInvalidatePanelMenuPosted) {
+            mDecor.removeCallbacks(mInvalidatePanelMenuRunnable);
+            mInvalidatePanelMenuRunnable.run();
+        }
+    }
+
     void doInvalidatePanelMenu(int featureId) {
         PanelFeatureState st = getPanelState(featureId, true);
         Bundle savedActionViewStates = null;
@@ -1315,6 +1328,9 @@
             if (mDecor != null) {
                 mDecor.setWindowBackground(drawable);
             }
+            if (mBackgroundFallbackResource != 0) {
+                mDecor.setBackgroundFallback(drawable != null ? 0 : mBackgroundFallbackResource);
+            }
         }
     }
 
@@ -1978,6 +1994,7 @@
             SparseArray<Parcelable> actionBarStates =
                     savedInstanceState.getSparseParcelableArray(ACTION_BAR_TAG);
             if (actionBarStates != null) {
+                doPendingInvalidatePanelMenu();
                 mDecorContentParent.restoreToolbarHierarchyState(actionBarStates);
             } else {
                 Log.w(TAG, "Missing saved instance states for action bar views! " +
@@ -2108,8 +2125,7 @@
         }
     }
 
-    private final class DecorView extends FrameLayout implements RootViewSurfaceTaker,
-            View.OnSystemUiVisibilityChangeListener {
+    private final class DecorView extends FrameLayout implements RootViewSurfaceTaker {
         /* package */int mDefaultOpacity = PixelFormat.OPAQUE;
 
         /** The feature ID of the panel, or -1 if this is the application's DecorView */
@@ -2141,10 +2157,11 @@
 
         private View mStatusColorView;
         private View mNavigationColorView;
+        private final BackgroundFallback mBackgroundFallback = new BackgroundFallback();
 
         private int mLastTopInset = 0;
         private int mLastBottomInset = 0;
-        private int mLastSystemUiVisibility = 0;
+        private int mLastRightInset = 0;
 
 
         public DecorView(Context context, int featureId) {
@@ -2152,6 +2169,17 @@
             mFeatureId = featureId;
         }
 
+        public void setBackgroundFallback(int resId) {
+            mBackgroundFallback.setDrawable(resId != 0 ? getContext().getDrawable(resId) : null);
+            setWillNotDraw(getBackground() == null && !mBackgroundFallback.hasFallback());
+        }
+
+        @Override
+        public void onDraw(Canvas c) {
+            super.onDraw(c);
+            mBackgroundFallback.draw(mContentRoot, c, mContentParent);
+        }
+
         @Override
         public boolean dispatchKeyEvent(KeyEvent event) {
             final int keyCode = event.getKeyCode();
@@ -2714,15 +2742,14 @@
         }
 
         @Override
-        public void onSystemUiVisibilityChange(int visible) {
-            mLastSystemUiVisibility = visible;
+        public void onWindowSystemUiVisibilityChanged(int visible) {
             updateColorViews(null /* insets */);
         }
 
         @Override
         public WindowInsets onApplyWindowInsets(WindowInsets insets) {
             mFrameOffsets.set(insets.getSystemWindowInsets());
-            updateColorViews(insets);
+            insets = updateColorViews(insets);
             insets = updateStatusGuard(insets);
             updateNavigationGuard(insets);
             if (getForeground() != null) {
@@ -2737,29 +2764,78 @@
         }
 
         private WindowInsets updateColorViews(WindowInsets insets) {
+            WindowManager.LayoutParams attrs = getAttributes();
+            int sysUiVisibility = attrs.systemUiVisibility | getWindowSystemUiVisibility();
+
             if (!mIsFloating && ActivityManager.isHighEndGfx()) {
                 if (insets != null) {
-                    mLastTopInset = insets.getStableInsetTop();
-                    mLastBottomInset = insets.getStableInsetBottom();
+                    mLastTopInset = Math.min(insets.getStableInsetTop(),
+                            insets.getSystemWindowInsetTop());
+                    mLastBottomInset = Math.min(insets.getStableInsetBottom(),
+                            insets.getSystemWindowInsetBottom());
+                    mLastRightInset = Math.min(insets.getStableInsetRight(),
+                            insets.getSystemWindowInsetRight());
                 }
-                mStatusColorView = updateColorViewInt(mStatusColorView,
+                mStatusColorView = updateColorViewInt(mStatusColorView, sysUiVisibility,
                         SYSTEM_UI_FLAG_FULLSCREEN, FLAG_TRANSLUCENT_STATUS,
                         mStatusBarColor, mLastTopInset, Gravity.TOP,
-                        STATUS_BAR_BACKGROUND_TRANSITION_NAME);
-                mNavigationColorView = updateColorViewInt(mNavigationColorView,
+                        STATUS_BAR_BACKGROUND_TRANSITION_NAME,
+                        com.android.internal.R.id.statusBarBackground,
+                        (getAttributes().flags & FLAG_FULLSCREEN) != 0);
+                mNavigationColorView = updateColorViewInt(mNavigationColorView, sysUiVisibility,
                         SYSTEM_UI_FLAG_HIDE_NAVIGATION, FLAG_TRANSLUCENT_NAVIGATION,
                         mNavigationBarColor, mLastBottomInset, Gravity.BOTTOM,
-                        NAVIGATION_BAR_BACKGROUND_TRANSITION_NAME);
+                        NAVIGATION_BAR_BACKGROUND_TRANSITION_NAME,
+                        com.android.internal.R.id.navigationBarBackground,
+                        false /* hiddenByWindowFlag */);
             }
+
+            // When we expand the window with FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS, we still need
+            // to ensure that the rest of the view hierarchy doesn't notice it, unless they've
+            // explicitly asked for it.
+
+            boolean consumingNavBar =
+                    (attrs.flags & FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS) != 0
+                            && (sysUiVisibility & SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION) == 0
+                            && (sysUiVisibility & SYSTEM_UI_FLAG_HIDE_NAVIGATION) == 0;
+
+            int consumedRight = consumingNavBar ? mLastRightInset : 0;
+            int consumedBottom = consumingNavBar ? mLastBottomInset : 0;
+
+            if (mContentRoot != null
+                    && mContentRoot.getLayoutParams() instanceof MarginLayoutParams) {
+                MarginLayoutParams lp = (MarginLayoutParams) mContentRoot.getLayoutParams();
+                if (lp.rightMargin != consumedRight || lp.bottomMargin != consumedBottom) {
+                    lp.rightMargin = consumedRight;
+                    lp.bottomMargin = consumedBottom;
+                    mContentRoot.setLayoutParams(lp);
+
+                    if (insets == null) {
+                        // The insets have changed, but we're not currently in the process
+                        // of dispatching them.
+                        requestApplyInsets();
+                    }
+                }
+                if (insets != null) {
+                    insets = insets.replaceSystemWindowInsets(
+                            insets.getSystemWindowInsetLeft(),
+                            insets.getSystemWindowInsetTop(),
+                            insets.getSystemWindowInsetRight() - consumedRight,
+                            insets.getSystemWindowInsetBottom() - consumedBottom);
+                }
+            }
+
             if (insets != null) {
                 insets = insets.consumeStableInsets();
             }
             return insets;
         }
 
-        private View updateColorViewInt(View view, int systemUiHideFlag, int translucentFlag,
-                int color, int height, int verticalGravity, String transitionName) {
-            boolean show = height > 0 && (mLastSystemUiVisibility & systemUiHideFlag) == 0
+        private View updateColorViewInt(View view, int sysUiVis, int systemUiHideFlag,
+                int translucentFlag, int color, int height, int verticalGravity,
+                String transitionName, int id, boolean hiddenByWindowFlag) {
+            boolean show = height > 0 && (sysUiVis & systemUiHideFlag) == 0
+                    && !hiddenByWindowFlag
                     && (getAttributes().flags & translucentFlag) == 0
                     && (color & Color.BLACK) != 0
                     && (getAttributes().flags & FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS) != 0;
@@ -2769,6 +2845,7 @@
                     view = new View(mContext);
                     view.setBackgroundColor(color);
                     view.setTransitionName(transitionName);
+                    view.setId(id);
                     addView(view, new LayoutParams(LayoutParams.MATCH_PARENT, height,
                             Gravity.START | verticalGravity));
                 }
@@ -2878,7 +2955,6 @@
             invalidate();
 
             int opacity = PixelFormat.OPAQUE;
-
             // Note: if there is no background, we will assume opaque. The
             // common case seems to be that an application sets there to be
             // no background so it can draw everything itself. For that,
@@ -3192,13 +3268,18 @@
         if (a.getBoolean(R.styleable.Window_windowContentTransitions, false)) {
             requestFeature(FEATURE_CONTENT_TRANSITIONS);
         }
+        if (a.getBoolean(R.styleable.Window_windowActivityTransitions, false)) {
+            requestFeature(FEATURE_ACTIVITY_TRANSITIONS);
+        }
 
         final WindowManager windowService = (WindowManager) getContext().getSystemService(
                 Context.WINDOW_SERVICE);
         if (windowService != null) {
             final Display display = windowService.getDefaultDisplay();
-            if (display.getDisplayId() == Display.DEFAULT_DISPLAY &&
-                    a.hasValue(R.styleable.Window_windowOutsetBottom)) {
+            final boolean shouldUseBottomOutset =
+                    display.getDisplayId() == Display.DEFAULT_DISPLAY
+                            || (getForcedWindowFlags() & FLAG_FULLSCREEN) != 0;
+            if (shouldUseBottomOutset && a.hasValue(R.styleable.Window_windowOutsetBottom)) {
                 if (mOutsetBottom == null) mOutsetBottom = new TypedValue();
                 a.getValue(R.styleable.Window_windowOutsetBottom,
                         mOutsetBottom);
@@ -3229,7 +3310,6 @@
                 setFlags(FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS,
                         FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS & ~getForcedWindowFlags());
             }
-            decor.setOnSystemUiVisibilityChangeListener(decor);
         }
         if (!mForcedStatusBarColor) {
             mStatusBarColor = a.getColor(R.styleable.Window_statusBarColor, 0xFF000000);
@@ -3283,6 +3363,8 @@
                 if (mFrameResource == 0) {
                     mFrameResource = a.getResourceId(R.styleable.Window_windowFrame, 0);
                 }
+                mBackgroundFallbackResource = a.getResourceId(
+                        R.styleable.Window_windowBackgroundFallback, 0);
                 if (false) {
                     System.out.println("Background: "
                             + Integer.toHexString(mBackgroundResource) + " Frame: "
@@ -3360,6 +3442,7 @@
 
         View in = mLayoutInflater.inflate(layoutResource, null);
         decor.addView(in, new ViewGroup.LayoutParams(MATCH_PARENT, MATCH_PARENT));
+        mContentRoot = (ViewGroup) in;
 
         ViewGroup contentParent = (ViewGroup)findViewById(ID_ANDROID_CONTENT);
         if (contentParent == null) {
@@ -3467,17 +3550,15 @@
                     mDecorContentParent.setLogo(mLogoRes);
                 }
 
-                // Post the panel invalidate for later; avoid application onCreateOptionsMenu
+                // Invalidate if the panel menu hasn't been created before this.
+                // Panel menu invalidation is deferred avoiding application onCreateOptionsMenu
                 // being called in the middle of onCreate or similar.
-                mDecor.post(new Runnable() {
-                    public void run() {
-                        // Invalidate if the panel menu hasn't been created before this.
-                        PanelFeatureState st = getPanelState(FEATURE_OPTIONS_PANEL, false);
-                        if (!isDestroyed() && (st == null || st.menu == null)) {
-                            invalidatePanelMenu(FEATURE_ACTION_BAR);
-                        }
-                    }
-                });
+                // A pending invalidation will typically be resolved before the posted message
+                // would run normally in order to satisfy instance state restoration.
+                PanelFeatureState st = getPanelState(FEATURE_OPTIONS_PANEL, false);
+                if (!isDestroyed() && (st == null || st.menu == null)) {
+                    invalidatePanelMenu(FEATURE_ACTION_BAR);
+                }
             } else {
                 mTitleView = (TextView)findViewById(R.id.title);
                 if (mTitleView != null) {
@@ -3499,9 +3580,13 @@
                 }
             }
 
+            if (mDecor.getBackground() == null && mBackgroundFallbackResource != 0) {
+                mDecor.setBackgroundFallback(mBackgroundFallbackResource);
+            }
+
             // Only inflate or create a new TransitionManager if the caller hasn't
             // already set a custom one.
-            if (hasFeature(FEATURE_CONTENT_TRANSITIONS)) {
+            if (hasFeature(FEATURE_ACTIVITY_TRANSITIONS)) {
                 if (mTransitionManager == null) {
                     final int transitionRes = getWindowStyle().getResourceId(
                             R.styleable.Window_windowContentTransitionManager,
@@ -3537,15 +3622,19 @@
                     mAllowEnterTransitionOverlap = getWindowStyle().getBoolean(
                             R.styleable.Window_windowAllowEnterTransitionOverlap, true);
                 }
-                if (mAllowExitTransitionOverlap == null) {
-                    mAllowExitTransitionOverlap = getWindowStyle().getBoolean(
-                            R.styleable.Window_windowAllowExitTransitionOverlap, true);
+                if (mAllowReturnTransitionOverlap == null) {
+                    mAllowReturnTransitionOverlap = getWindowStyle().getBoolean(
+                            R.styleable.Window_windowAllowReturnTransitionOverlap, true);
                 }
                 if (mBackgroundFadeDurationMillis < 0) {
                     mBackgroundFadeDurationMillis = getWindowStyle().getInteger(
                             R.styleable.Window_windowTransitionBackgroundFadeDuration,
                             DEFAULT_BACKGROUND_FADE_DURATION_MS);
                 }
+                if (mSharedElementsUseOverlay == null) {
+                    mSharedElementsUseOverlay = getWindowStyle().getBoolean(
+                            R.styleable.Window_windowSharedElementsUseOverlay, true);
+                }
             }
         }
     }
@@ -3559,6 +3648,10 @@
         if (transitionId != -1 && transitionId != R.transition.no_transition) {
             TransitionInflater inflater = TransitionInflater.from(getContext());
             transition = inflater.inflateTransition(transitionId);
+            if (transition instanceof TransitionSet &&
+                    ((TransitionSet)transition).getTransitionCount() == 0) {
+                transition = null;
+            }
         }
         return transition;
     }
@@ -3997,13 +4090,13 @@
     }
 
     @Override
-    public void setAllowExitTransitionOverlap(boolean allowExitTransitionOverlap) {
-        mAllowExitTransitionOverlap = allowExitTransitionOverlap;
+    public void setAllowReturnTransitionOverlap(boolean allowExitTransitionOverlap) {
+        mAllowReturnTransitionOverlap = allowExitTransitionOverlap;
     }
 
     @Override
-    public boolean getAllowExitTransitionOverlap() {
-        return (mAllowExitTransitionOverlap == null) ? true : mAllowExitTransitionOverlap;
+    public boolean getAllowReturnTransitionOverlap() {
+        return (mAllowReturnTransitionOverlap == null) ? true : mAllowReturnTransitionOverlap;
     }
 
     @Override
@@ -4020,6 +4113,16 @@
         mBackgroundFadeDurationMillis = fadeDurationMillis;
     }
 
+    @Override
+    public void setSharedElementsUseOverlay(boolean sharedElementsUseOverlay) {
+        mSharedElementsUseOverlay = sharedElementsUseOverlay;
+    }
+
+    @Override
+    public boolean getSharedElementsUseOverlay() {
+        return (mSharedElementsUseOverlay == null) ? true : mSharedElementsUseOverlay;
+    }
+
     private static final class DrawableFeatureState {
         DrawableFeatureState(int _featureId) {
             featureId = _featureId;
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
index 3f7c72e..fbaaf74 100644
--- a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
+++ b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
@@ -46,11 +46,7 @@
 import android.media.IAudioService;
 import android.media.Ringtone;
 import android.media.RingtoneManager;
-import android.media.session.MediaController;
-import android.media.session.MediaSession;
 import android.media.session.MediaSessionLegacyHelper;
-import android.media.session.MediaSessionManager;
-import android.media.session.PlaybackState;
 import android.os.Bundle;
 import android.os.FactoryTest;
 import android.os.Handler;
@@ -66,11 +62,13 @@
 import android.os.UEventObserver;
 import android.os.UserHandle;
 import android.os.Vibrator;
+import android.provider.MediaStore;
 import android.provider.Settings;
 import android.service.dreams.DreamManagerInternal;
 import android.service.dreams.DreamService;
 import android.service.dreams.IDreamManager;
-import android.telecomm.TelecommManager;
+import android.speech.RecognizerIntent;
+import android.telecom.TelecomManager;
 import android.util.DisplayMetrics;
 import android.util.EventLog;
 import android.util.Log;
@@ -99,7 +97,6 @@
 import android.view.WindowManagerPolicy;
 import android.view.accessibility.AccessibilityEvent;
 import android.view.accessibility.AccessibilityManager;
-import android.view.animation.AlphaAnimation;
 import android.view.animation.Animation;
 import android.view.animation.AnimationSet;
 import android.view.animation.AnimationUtils;
@@ -118,14 +115,15 @@
 import java.io.FileReader;
 import java.io.IOException;
 import java.io.PrintWriter;
-import java.util.ArrayList;
 import java.util.HashSet;
-import java.util.List;
 
 import static android.view.WindowManager.LayoutParams.*;
 import static android.view.WindowManagerPolicy.WindowManagerFuncs.LID_ABSENT;
 import static android.view.WindowManagerPolicy.WindowManagerFuncs.LID_OPEN;
 import static android.view.WindowManagerPolicy.WindowManagerFuncs.LID_CLOSED;
+import static android.view.WindowManagerPolicy.WindowManagerFuncs.CAMERA_LENS_COVER_ABSENT;
+import static android.view.WindowManagerPolicy.WindowManagerFuncs.CAMERA_LENS_UNCOVERED;
+import static android.view.WindowManagerPolicy.WindowManagerFuncs.CAMERA_LENS_COVERED;
 
 /**
  * WindowManagerPolicy implementation for the Android phone UI.  This
@@ -226,6 +224,9 @@
                 KeyEvent.KEYCODE_CALCULATOR, Intent.CATEGORY_APP_CALCULATOR);
     }
 
+    /** Amount of time (in milliseconds) to wait for windows drawn before powering on. */
+    static final int WAITING_FOR_DRAWN_TIMEOUT = 1000;
+
     /**
      * Lock protecting internal state.  Must not call out into window
      * manager with lock held.  (This lock will be acquired in places
@@ -314,6 +315,7 @@
     boolean mLanguageSwitchKeyPressed;
 
     int mLidState = LID_ABSENT;
+    int mCameraLensCoverState = CAMERA_LENS_COVER_ABSENT;
     boolean mHaveBuiltInKeyboard;
 
     boolean mSystemReady;
@@ -433,6 +435,7 @@
 
     WindowState mTopFullscreenOpaqueWindowState;
     HashSet<IApplicationToken> mAppsToBeHidden = new HashSet<IApplicationToken>();
+    HashSet<IApplicationToken> mAppsThatDismissKeyguard = new HashSet<IApplicationToken>();
     boolean mTopIsFullscreen;
     boolean mForceStatusBar;
     boolean mForceStatusBarFromKeyguard;
@@ -544,6 +547,7 @@
     private static final int MSG_DISPATCH_SHOW_RECENTS = 9;
     private static final int MSG_DISPATCH_SHOW_GLOBAL_ACTIONS = 10;
     private static final int MSG_HIDE_BOOT_MESSAGE = 11;
+    private static final int MSG_LAUNCH_VOICE_ASSIST_WITH_WAKE_LOCK = 12;
 
     private class PolicyHandler extends Handler {
         @Override
@@ -589,6 +593,9 @@
                 case MSG_HIDE_BOOT_MESSAGE:
                     handleHideBootMessage();
                     break;
+                case MSG_LAUNCH_VOICE_ASSIST_WITH_WAKE_LOCK:
+                    launchVoiceAssistWithWakeLock(msg.arg1 != 0);
+                    break;
             }
         }
     }
@@ -1510,8 +1517,7 @@
 
         if (ActivityManager.isHighEndGfx()
                 && (attrs.flags & FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS) != 0) {
-            attrs.subtreeSystemUiVisibility |= View.SYSTEM_UI_FLAG_LAYOUT_STABLE
-                    | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
+            attrs.subtreeSystemUiVisibility |= View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
                     | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION;
         }
     }
@@ -1520,6 +1526,10 @@
         mLidState = mWindowManagerFuncs.getLidState();
     }
 
+    private void readCameraLensCoverState() {
+        mCameraLensCoverState = mWindowManagerFuncs.getCameraLensCoverState();
+    }
+
     private boolean isHidden(int accessibilityMode) {
         switch (accessibilityMode) {
             case 1:
@@ -1744,6 +1754,11 @@
         }
     }
 
+    @Override
+    public WindowState getWinShowWhenLockedLw() {
+        return mWinShowWhenLocked;
+    }
+
     /** {@inheritDoc} */
     @Override
     public View addStartingWindow(IBinder appToken, String packageName, int theme,
@@ -2114,8 +2129,8 @@
                 ServiceManager.checkService(DreamService.DREAM_SERVICE));
     }
 
-    TelecommManager getTelecommService() {
-        return (TelecommManager) mContext.getSystemService(Context.TELECOMM_SERVICE);
+    TelecomManager getTelecommService() {
+        return (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
     }
 
     static IAudioService getAudioService() {
@@ -2175,7 +2190,7 @@
 
         // Cancel any pending meta actions if we see any other keys being pressed between the down
         // of the meta key and its corresponding up.
-        if (mPendingMetaAction && KeyEvent.isMetaKey(keyCode)) {
+        if (mPendingMetaAction && !KeyEvent.isMetaKey(keyCode)) {
             mPendingMetaAction = false;
         }
 
@@ -2204,8 +2219,8 @@
                 // If an incoming call is ringing, HOME is totally disabled.
                 // (The user is already on the InCallUI at this point,
                 // and his ONLY options are to answer or reject the call.)
-                TelecommManager telecommManager = getTelecommService();
-                if (telecommManager != null && telecommManager.isRinging()) {
+                TelecomManager telecomManager = getTelecommService();
+                if (telecomManager != null && telecomManager.isRinging()) {
                     Log.i(TAG, "Ignoring HOME; there's a ringing incoming call.");
                     return -1;
                 }
@@ -2338,6 +2353,17 @@
                 }
             }
             return -1;
+        } else if (keyCode == KeyEvent.KEYCODE_VOICE_ASSIST) {
+            if (!down) {
+                Intent voiceIntent;
+                if (!keyguardOn) {
+                    voiceIntent = new Intent(RecognizerIntent.ACTION_WEB_SEARCH);
+                } else {
+                    voiceIntent = new Intent(RecognizerIntent.ACTION_VOICE_SEARCH_HANDS_FREE);
+                    voiceIntent.putExtra(RecognizerIntent.EXTRA_SECURE, true);
+                }
+                mContext.startActivityAsUser(voiceIntent, UserHandle.CURRENT_OR_SELF);
+            }
         } else if (keyCode == KeyEvent.KEYCODE_SYSRQ) {
             if (down && repeatCount == 0) {
                 mHandler.post(mScreenshotRunnable);
@@ -2384,7 +2410,7 @@
             if (down) {
                 mPendingMetaAction = true;
             } else if (mPendingMetaAction) {
-                launchAssistAction();
+                launchAssistAction(Intent.EXTRA_ASSIST_INPUT_HINT_KEYBOARD);
             }
             return -1;
         }
@@ -2458,13 +2484,11 @@
             }
         }
 
-        // Display task switcher for ALT-TAB or Meta-TAB.
+        // Display task switcher for ALT-TAB.
         if (down && repeatCount == 0 && keyCode == KeyEvent.KEYCODE_TAB) {
             if (mRecentAppsHeldModifiers == 0 && !keyguardOn) {
                 final int shiftlessModifiers = event.getModifiers() & ~KeyEvent.META_SHIFT_MASK;
-                if (KeyEvent.metaStateHasModifiers(shiftlessModifiers, KeyEvent.META_ALT_ON)
-                        || KeyEvent.metaStateHasModifiers(
-                        shiftlessModifiers, KeyEvent.META_META_ON)) {
+                if (KeyEvent.metaStateHasModifiers(shiftlessModifiers, KeyEvent.META_ALT_ON)) {
                     mRecentAppsHeldModifiers = shiftlessModifiers;
                     showRecentApps(true);
                     return -1;
@@ -2606,10 +2630,17 @@
     }
 
     private void launchAssistAction() {
+        launchAssistAction(null);
+    }
+
+    private void launchAssistAction(String hint) {
         sendCloseSystemWindows(SYSTEM_DIALOG_REASON_ASSIST);
         Intent intent = ((SearchManager) mContext.getSystemService(Context.SEARCH_SERVICE))
                 .getAssistIntent(mContext, true, UserHandle.USER_CURRENT);
         if (intent != null) {
+            if (hint != null) {
+                intent.putExtra(hint, true);
+            }
             intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK
                     | Intent.FLAG_ACTIVITY_SINGLE_TOP
                     | Intent.FLAG_ACTIVITY_CLEAR_TOP);
@@ -2968,7 +2999,10 @@
             boolean immersiveSticky = (sysui & View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY) != 0;
             boolean navAllowedHidden = immersive || immersiveSticky;
             navTranslucent &= !immersiveSticky;  // transient trumps translucent
-            navTranslucent &= areTranslucentBarsAllowed();
+            boolean isKeyguardShowing = isStatusBarKeyguard() && !mHideLockScreen;
+            if (!isKeyguardShowing) {
+                navTranslucent &= areTranslucentBarsAllowed();
+            }
 
             // When the navigation bar isn't visible, we put up a fake
             // input window to catch all touch events.  This way we can
@@ -3092,7 +3126,9 @@
                 boolean statusBarTransient = (sysui & View.STATUS_BAR_TRANSIENT) != 0;
                 boolean statusBarTranslucent = (sysui
                         & (View.STATUS_BAR_TRANSLUCENT | View.SYSTEM_UI_TRANSPARENT)) != 0;
-                statusBarTranslucent &= areTranslucentBarsAllowed();
+                if (!isKeyguardShowing) {
+                    statusBarTranslucent &= areTranslucentBarsAllowed();
+                }
 
                 // If the status bar is hidden, we don't want to cause
                 // windows behind it to scroll.
@@ -3283,6 +3319,16 @@
             // IM dock windows always go to the bottom of the screen.
             attrs.gravity = Gravity.BOTTOM;
             mDockLayer = win.getSurfaceLayer();
+        } else if (win == mStatusBar && (attrs.privateFlags & PRIVATE_FLAG_KEYGUARD) != 0) {
+            pf.left = df.left = of.left = mUnrestrictedScreenLeft;
+            pf.top = df.top = of.top = mUnrestrictedScreenTop;
+            pf.right = df.right = of.right = mUnrestrictedScreenWidth + mUnrestrictedScreenLeft;
+            pf.bottom = df.bottom = of.bottom = mUnrestrictedScreenHeight + mUnrestrictedScreenTop;
+            cf.left = vf.left = mStableLeft;
+            cf.top = vf.top = mStableTop;
+            cf.right = vf.right = mStableRight;
+            vf.bottom = mStableBottom;
+            cf.bottom = mContentBottom;
         } else {
 
             // Default policy decor for the default display
@@ -3488,13 +3534,16 @@
                     pf.bottom = df.bottom = of.bottom = cf.bottom = mOverscanScreenTop
                             + mOverscanScreenHeight;
                 } else if (attrs.type == TYPE_WALLPAPER) {
-                    // The wallpaper also has Real Ultimate Power.
-                    pf.left = df.left = of.left = cf.left = mUnrestrictedScreenLeft;
-                    pf.top = df.top = of.top = cf.top = mUnrestrictedScreenTop;
-                    pf.right = df.right = of.right = cf.right
-                            = mUnrestrictedScreenLeft + mUnrestrictedScreenWidth;
-                    pf.bottom = df.bottom = of.bottom = cf.bottom
-                            = mUnrestrictedScreenTop + mUnrestrictedScreenHeight;
+                    // The wallpaper also has Real Ultimate Power, but we want to tell
+                    // it about the overscan area.
+                    pf.left = df.left = mOverscanScreenLeft;
+                    pf.top = df.top = mOverscanScreenTop;
+                    pf.right = df.right = mOverscanScreenLeft + mOverscanScreenWidth;
+                    pf.bottom = df.bottom = mOverscanScreenTop + mOverscanScreenHeight;
+                    of.left = cf.left = mUnrestrictedScreenLeft;
+                    of.top = cf.top = mUnrestrictedScreenTop;
+                    of.right = cf.right = mUnrestrictedScreenLeft + mUnrestrictedScreenWidth;
+                    of.bottom = cf.bottom = mUnrestrictedScreenTop + mUnrestrictedScreenHeight;
                 } else if ((fl & FLAG_LAYOUT_IN_OVERSCAN) != 0
                         && attrs.type >= WindowManager.LayoutParams.FIRST_APPLICATION_WINDOW
                         && attrs.type <= WindowManager.LayoutParams.LAST_SUB_WINDOW) {
@@ -3608,9 +3657,12 @@
 
         // TYPE_SYSTEM_ERROR is above the NavigationBar so it can't be allowed to extend over it.
         if ((fl & FLAG_LAYOUT_NO_LIMITS) != 0 && attrs.type != TYPE_SYSTEM_ERROR) {
-            df.left = df.top = of.left = of.top = cf.left = cf.top = vf.left = vf.top = -10000;
-            df.right = df.bottom = of.right = of.bottom = cf.right = cf.bottom
-                    = vf.right = vf.bottom = 10000;
+            df.left = df.top = -10000;
+            df.right = df.bottom = 10000;
+            if (attrs.type != TYPE_WALLPAPER) {
+                of.left = of.top = cf.left = cf.top = vf.left = vf.top = -10000;
+                of.right = of.bottom = cf.right = cf.bottom = vf.right = vf.bottom = 10000;
+            }
         }
 
         if (DEBUG_LAYOUT) Slog.v(TAG, "Compute frame " + attrs.getTitle()
@@ -3702,6 +3754,7 @@
     public void beginPostLayoutPolicyLw(int displayWidth, int displayHeight) {
         mTopFullscreenOpaqueWindowState = null;
         mAppsToBeHidden.clear();
+        mAppsThatDismissKeyguard.clear();
         mForceStatusBar = false;
         mForceStatusBarFromKeyguard = false;
         mForcingShowNavBar = false;
@@ -3742,7 +3795,7 @@
                 mShowingLockscreen = true;
             }
             boolean appWindow = attrs.type >= FIRST_APPLICATION_WINDOW
-                    && attrs.type <= LAST_APPLICATION_WINDOW;
+                    && attrs.type < FIRST_SYSTEM_WINDOW;
             if (attrs.type == TYPE_DREAM) {
                 // If the lockscreen was showing when the dream started then wait
                 // for the dream to draw before hiding the lockscreen.
@@ -3757,38 +3810,44 @@
             final boolean dismissKeyguard = (fl & FLAG_DISMISS_KEYGUARD) != 0;
             final boolean secureKeyguard = isKeyguardSecure();
             if (appWindow) {
-                if (showWhenLocked || (dismissKeyguard && !secureKeyguard)) {
+                final IApplicationToken appToken = win.getAppToken();
+                if (showWhenLocked) {
                     // Remove any previous windows with the same appToken.
-                    mAppsToBeHidden.remove(win.getAppToken());
-                    if (mAppsToBeHidden.isEmpty() && showWhenLocked &&
-                            isKeyguardSecureIncludingHidden()) {
+                    mAppsToBeHidden.remove(appToken);
+                    mAppsThatDismissKeyguard.remove(appToken);
+                    if (mAppsToBeHidden.isEmpty() && isKeyguardSecureIncludingHidden()) {
                         mWinShowWhenLocked = win;
                         mHideLockScreen = true;
                         mForceStatusBarFromKeyguard = false;
                     }
+                } else if (dismissKeyguard) {
+                    if (secureKeyguard) {
+                        mAppsToBeHidden.add(appToken);
+                    } else {
+                        mAppsToBeHidden.remove(appToken);
+                    }
+                    mAppsThatDismissKeyguard.add(appToken);
                 } else {
-                    mAppsToBeHidden.add(win.getAppToken());
+                    mAppsToBeHidden.add(appToken);
                 }
                 if (attrs.x == 0 && attrs.y == 0
                         && attrs.width == WindowManager.LayoutParams.MATCH_PARENT
                         && attrs.height == WindowManager.LayoutParams.MATCH_PARENT) {
                     if (DEBUG_LAYOUT) Slog.v(TAG, "Fullscreen window: " + win);
                     mTopFullscreenOpaqueWindowState = win;
-                    if (mAppsToBeHidden.isEmpty()) {
-                        if (showWhenLocked) {
-                            if (DEBUG_LAYOUT) Slog.v(TAG,
-                                    "Setting mHideLockScreen to true by win " + win);
-                            mHideLockScreen = true;
-                            mForceStatusBarFromKeyguard = false;
-                        }
-                        if (dismissKeyguard && mDismissKeyguard == DISMISS_KEYGUARD_NONE) {
-                            if (DEBUG_LAYOUT) Slog.v(TAG,
-                                    "Setting mDismissKeyguard true by win " + win);
-                            mDismissKeyguard = mWinDismissingKeyguard == win ?
-                                    DISMISS_KEYGUARD_CONTINUE : DISMISS_KEYGUARD_START;
-                            mWinDismissingKeyguard = win;
-                            mForceStatusBarFromKeyguard = mShowingLockscreen && secureKeyguard;
-                        }
+                    if (!mAppsThatDismissKeyguard.isEmpty() &&
+                            mDismissKeyguard == DISMISS_KEYGUARD_NONE) {
+                        if (DEBUG_LAYOUT) Slog.v(TAG,
+                                "Setting mDismissKeyguard true by win " + win);
+                        mDismissKeyguard = mWinDismissingKeyguard == win ?
+                                DISMISS_KEYGUARD_CONTINUE : DISMISS_KEYGUARD_START;
+                        mWinDismissingKeyguard = win;
+                        mForceStatusBarFromKeyguard = mShowingLockscreen && secureKeyguard;
+                    } else if (mAppsToBeHidden.isEmpty() && showWhenLocked) {
+                        if (DEBUG_LAYOUT) Slog.v(TAG,
+                                "Setting mHideLockScreen to true by win " + win);
+                        mHideLockScreen = true;
+                        mForceStatusBarFromKeyguard = false;
                     }
                     if ((fl & FLAG_ALLOW_LOCK_WHILE_SCREEN_ON) != 0) {
                         mAllowLockscreenWhenOn = true;
@@ -4026,6 +4085,27 @@
         }
     }
 
+    @Override
+    public void notifyCameraLensCoverSwitchChanged(long whenNanos, boolean lensCovered) {
+        int lensCoverState = lensCovered ? CAMERA_LENS_COVERED : CAMERA_LENS_UNCOVERED;
+        if (mCameraLensCoverState == lensCoverState) {
+            return;
+        }
+        if (mCameraLensCoverState == CAMERA_LENS_COVERED &&
+                lensCoverState == CAMERA_LENS_UNCOVERED) {
+            Intent intent;
+            final boolean keyguardActive = mKeyguardDelegate == null ? false :
+                    mKeyguardDelegate.isShowing();
+            if (keyguardActive) {
+                intent = new Intent(MediaStore.INTENT_ACTION_STILL_IMAGE_CAMERA_SECURE);
+            } else {
+                intent = new Intent(MediaStore.INTENT_ACTION_STILL_IMAGE_CAMERA);
+            }
+            mContext.startActivityAsUser(intent, UserHandle.CURRENT_OR_SELF);
+        }
+        mCameraLensCoverState = lensCoverState;
+    }
+
     void setHdmiPlugged(boolean plugged) {
         if (mHdmiPlugged != plugged) {
             mHdmiPlugged = plugged;
@@ -4175,9 +4255,16 @@
         boolean isWakeKey = (policyFlags & WindowManagerPolicy.FLAG_WAKE) != 0
                 || event.isWakeKey();
         if (interactive || (isInjected && !isWakeKey)) {
-            // When the screen is on or if the key is injected pass the key to the application.
+            // When the device is interactive or the key is injected pass the key to the
+            // application.
             result = ACTION_PASS_TO_USER;
             isWakeKey = false;
+        } else if (!interactive && shouldDispatchInputWhenNonInteractive()) {
+            // If we're currently dozing with the screen on and the keyguard showing, pass the key
+            // to the application but preserve its wake key status to make sure we still move
+            // from dozing to fully interactive if we would normally go from off to fully
+            // interactive.
+            result = ACTION_PASS_TO_USER;
         } else {
             // When the screen is off and the key is not injected, determine whether
             // to wake the device but don't pass the key to the application.
@@ -4233,9 +4320,9 @@
                     }
                 }
                 if (down) {
-                    TelecommManager telecommManager = getTelecommService();
-                    if (telecommManager != null) {
-                        if (telecommManager.isRinging()) {
+                    TelecomManager telecomManager = getTelecommService();
+                    if (telecomManager != null) {
+                        if (telecomManager.isRinging()) {
                             // If an incoming call is ringing, either VOLUME key means
                             // "silence ringer".  We handle these keys here, rather than
                             // in the InCallScreen, to make sure we'll respond to them
@@ -4247,14 +4334,14 @@
 
                             // Silence the ringer.  (It's safe to call this
                             // even if the ringer has already been silenced.)
-                            telecommManager.silenceRinger();
+                            telecomManager.silenceRinger();
 
                             // And *don't* pass this key thru to the current activity
                             // (which is probably the InCallScreen.)
                             result &= ~ACTION_PASS_TO_USER;
                             break;
                         }
-                        if (telecommManager.isInAPhoneCall()
+                        if (telecomManager.isInCall()
                                 && (result & ACTION_PASS_TO_USER) == 0) {
                             // If we are in call but we decided not to pass the key to
                             // the application, just pass it to the session service.
@@ -4280,10 +4367,10 @@
             case KeyEvent.KEYCODE_ENDCALL: {
                 result &= ~ACTION_PASS_TO_USER;
                 if (down) {
-                    TelecommManager telecommManager = getTelecommService();
+                    TelecomManager telecomManager = getTelecommService();
                     boolean hungUp = false;
-                    if (telecommManager != null) {
-                        hungUp = telecommManager.endCall();
+                    if (telecomManager != null) {
+                        hungUp = telecomManager.endCall();
                     }
                     interceptPowerKeyDown(!interactive || hungUp);
                 } else {
@@ -4320,19 +4407,19 @@
                         interceptScreenshotChord();
                     }
 
-                    TelecommManager telecommManager = getTelecommService();
+                    TelecomManager telecomManager = getTelecommService();
                     boolean hungUp = false;
-                    if (telecommManager != null) {
-                        if (telecommManager.isRinging()) {
+                    if (telecomManager != null) {
+                        if (telecomManager.isRinging()) {
                             // Pressing Power while there's a ringing incoming
                             // call should silence the ringer.
-                            telecommManager.silenceRinger();
+                            telecomManager.silenceRinger();
                         } else if ((mIncallPowerBehavior
                                 & Settings.Secure.INCALL_POWER_BUTTON_BEHAVIOR_HANGUP) != 0
-                                && telecommManager.isInAPhoneCall() && interactive) {
+                                && telecomManager.isInCall() && interactive) {
                             // Otherwise, if "Power button ends call" is enabled,
                             // the Power button will hang up any current active call.
-                            hungUp = telecommManager.endCall();
+                            hungUp = telecomManager.endCall();
                         }
                     }
                     interceptPowerKeyDown(!interactive || hungUp
@@ -4370,9 +4457,9 @@
             case KeyEvent.KEYCODE_MEDIA_PAUSE:
             case KeyEvent.KEYCODE_MEDIA_PLAY_PAUSE:
                 if (down) {
-                    TelecommManager telecommManager = getTelecommService();
-                    if (telecommManager != null) {
-                        if (telecommManager.isInAPhoneCall()) {
+                    TelecomManager telecomManager = getTelecommService();
+                    if (telecomManager != null) {
+                        if (telecomManager.isInCall()) {
                             // Suppress PLAY/PAUSE toggle when phone is ringing or in-call
                             // to avoid music playback.
                             break;
@@ -4405,12 +4492,12 @@
 
             case KeyEvent.KEYCODE_CALL: {
                 if (down) {
-                    TelecommManager telecommManager = getTelecommService();
-                    if (telecommManager != null) {
-                        if (telecommManager.isRinging()) {
+                    TelecomManager telecomManager = getTelecommService();
+                    if (telecomManager != null) {
+                        if (telecomManager.isRinging()) {
                             Log.i(TAG, "interceptKeyBeforeQueueing:"
                                   + " CALL key-down while ringing: Answer the call!");
-                            telecommManager.acceptRingingCall();
+                            telecomManager.acceptRingingCall();
 
                             // And *don't* pass this key thru to the current activity
                             // (which is presumably the InCallScreen.)
@@ -4420,6 +4507,19 @@
                 }
                 break;
             }
+            case KeyEvent.KEYCODE_VOICE_ASSIST: {
+                // Only do this if we would otherwise not pass it to the user. In that case,
+                // interceptKeyBeforeDispatching would apply a similar but different policy in
+                // order to invoke voice assist actions. Note that we need to make a copy of the
+                // key event here because the original key event will be recycled when we return.
+                if ((result & ACTION_PASS_TO_USER) == 0 && !down) {
+                    mBroadcastWakeLock.acquire();
+                    Message msg = mHandler.obtainMessage(MSG_LAUNCH_VOICE_ASSIST_WITH_WAKE_LOCK,
+                            keyguardActive ? 1 : 0, 0);
+                    msg.setAsynchronous(true);
+                    msg.sendToTarget();
+                }
+            }
         }
 
         if (useHapticFeedback) {
@@ -4469,14 +4569,22 @@
 
     /** {@inheritDoc} */
     @Override
-    public int interceptWakeMotionBeforeQueueing(long whenNanos, int policyFlags) {
-        // We already know this is a wake motion so just wake up.
-        // Note that we would observe policyFlags containing
-        // FLAG_WAKE and FLAG_INTERACTIVE here.
-        mPowerManager.wakeUp(whenNanos / 1000000);
+    public int interceptMotionBeforeQueueingNonInteractive(long whenNanos, int policyFlags) {
+        if ((policyFlags & FLAG_WAKE) != 0) {
+            mPowerManager.wakeUp(whenNanos / 1000000);
+            return 0;
+        }
+        if (shouldDispatchInputWhenNonInteractive()) {
+            return ACTION_PASS_TO_USER;
+        }
         return 0;
     }
 
+    private boolean shouldDispatchInputWhenNonInteractive() {
+        return keyguardIsShowingTq() && mDisplay != null &&
+                mDisplay.getState() != Display.STATE_OFF;
+    }
+
     void dispatchMediaKeyWithWakeLock(KeyEvent event) {
         if (DEBUG_INPUT) {
             Slog.d(TAG, "dispatchMediaKeyWithWakeLock: " + event);
@@ -4526,6 +4634,14 @@
         }
     }
 
+    void launchVoiceAssistWithWakeLock(boolean keyguardActive) {
+        Intent voiceIntent =
+            new Intent(RecognizerIntent.ACTION_VOICE_SEARCH_HANDS_FREE);
+        voiceIntent.putExtra(RecognizerIntent.EXTRA_SECURE, keyguardActive);
+        mContext.startActivityAsUser(voiceIntent, UserHandle.CURRENT_OR_SELF);
+        mBroadcastWakeLock.release();
+    }
+
     BroadcastReceiver mDockReceiver = new BroadcastReceiver() {
         @Override
         public void onReceive(Context context, Intent intent) {
@@ -4660,7 +4776,8 @@
             if (DEBUG_WAKEUP) Slog.d(TAG, "null mKeyguardDelegate: setting mKeyguardDrawComplete.");
             mKeyguardDrawComplete = true;
         }
-        mWindowManagerInternal.waitForAllWindowsDrawn(mWindowManagerDrawCallback, 500);
+        mWindowManagerInternal.waitForAllWindowsDrawn(mWindowManagerDrawCallback,
+                WAITING_FOR_DRAWN_TIMEOUT);
     }
 
     // Called on the mHandler thread.
@@ -5082,6 +5199,7 @@
         mKeyguardDelegate = new KeyguardServiceDelegate(mContext, null);
         mKeyguardDelegate.onSystemReady();
 
+        readCameraLensCoverState();
         updateUiMode();
         synchronized (mLock) {
             updateOrientationListenerLp();
@@ -5401,7 +5519,7 @@
                                         dock.resolveTypeIfNeeded(mContext.getContentResolver()),
                                         null, null, 0,
                                         ActivityManager.START_FLAG_ONLY_IF_NEEDED,
-                                        null, null, null, UserHandle.USER_CURRENT);
+                                        null, null, UserHandle.USER_CURRENT);
                         if (result == ActivityManager.START_RETURN_INTENT_TO_CALLER) {
                             return false;
                         }
@@ -5412,7 +5530,7 @@
                                 mHomeIntent.resolveTypeIfNeeded(mContext.getContentResolver()),
                                 null, null, 0,
                                 ActivityManager.START_FLAG_ONLY_IF_NEEDED,
-                                null, null, null, UserHandle.USER_CURRENT);
+                                null, null, UserHandle.USER_CURRENT);
                 if (result == ActivityManager.START_RETURN_INTENT_TO_CALLER) {
                     return false;
                 }
@@ -5591,7 +5709,7 @@
             vis = (vis & ~flags) | (oldVis & flags);
         }
 
-        if (!areTranslucentBarsAllowed()) {
+        if (!areTranslucentBarsAllowed() && transWin != mStatusBar) {
             vis &= ~(View.NAVIGATION_BAR_TRANSLUCENT | View.STATUS_BAR_TRANSLUCENT
                     | View.SYSTEM_UI_TRANSPARENT);
         }
@@ -5733,6 +5851,7 @@
                 pw.print(" mSystemBooted="); pw.println(mSystemBooted);
         pw.print(prefix); pw.print("mLidState="); pw.print(mLidState);
                 pw.print(" mLidOpenRotation="); pw.print(mLidOpenRotation);
+                pw.print(" mCameraLensCoverState="); pw.print(mCameraLensCoverState);
                 pw.print(" mHdmiPlugged="); pw.println(mHdmiPlugged);
         if (mLastSystemUiFlags != 0 || mResettingSystemUiFlags != 0
                 || mForceClearedSystemUiFlags != 0) {
diff --git a/policy/src/com/android/internal/policy/impl/PolicyControl.java b/policy/src/com/android/internal/policy/impl/PolicyControl.java
index ffdb520..9abd906 100644
--- a/policy/src/com/android/internal/policy/impl/PolicyControl.java
+++ b/policy/src/com/android/internal/policy/impl/PolicyControl.java
@@ -16,6 +16,7 @@
 
 package com.android.internal.policy.impl;
 
+import android.app.ActivityManager;
 import android.content.Context;
 import android.os.UserHandle;
 import android.provider.Settings;
@@ -104,8 +105,9 @@
     }
 
     public static boolean disableImmersiveConfirmation(String pkg) {
-        return sImmersivePreconfirmationsFilter != null
-                && sImmersivePreconfirmationsFilter.matches(pkg);
+        return (sImmersivePreconfirmationsFilter != null
+                && sImmersivePreconfirmationsFilter.matches(pkg))
+                || ActivityManager.isRunningInTestHarness();
     }
 
     public static void reloadFromSetting(Context context) {
diff --git a/rs/java/android/renderscript/Allocation.java b/rs/java/android/renderscript/Allocation.java
index 7db85f2..3cda6de 100644
--- a/rs/java/android/renderscript/Allocation.java
+++ b/rs/java/android/renderscript/Allocation.java
@@ -1868,7 +1868,7 @@
         }
     }
 
-    static void sendBufferNotification(int id) {
+    static void sendBufferNotification(long id) {
         synchronized(mAllocationMap) {
             Allocation a = mAllocationMap.get(new Long(id));
 
diff --git a/rs/java/android/renderscript/RenderScript.java b/rs/java/android/renderscript/RenderScript.java
index 340efef..6c5c508 100644
--- a/rs/java/android/renderscript/RenderScript.java
+++ b/rs/java/android/renderscript/RenderScript.java
@@ -1156,7 +1156,12 @@
                 }
 
                 if (msg == RS_MESSAGE_TO_CLIENT_NEW_BUFFER) {
-                    Allocation.sendBufferNotification(subID);
+                    if (mRS.nContextGetUserMessage(mRS.mContext, rbuf) !=
+                        RS_MESSAGE_TO_CLIENT_NEW_BUFFER) {
+                        throw new RSDriverException("Error processing message from RenderScript.");
+                    }
+                    long bufferID = ((long)rbuf[1] << 32L) + ((long)rbuf[0] & 0xffffffffL);
+                    Allocation.sendBufferNotification(bufferID);
                     continue;
                 }
 
diff --git a/rs/jni/android_renderscript_RenderScript.cpp b/rs/jni/android_renderscript_RenderScript.cpp
index 16df377..13a649a 100644
--- a/rs/jni/android_renderscript_RenderScript.cpp
+++ b/rs/jni/android_renderscript_RenderScript.cpp
@@ -222,7 +222,7 @@
 nDeviceCreate(JNIEnv *_env, jobject _this)
 {
     LOG_API("nDeviceCreate");
-    return (jlong)rsDeviceCreate();
+    return (jlong)(uintptr_t)rsDeviceCreate();
 }
 
 static void
@@ -243,7 +243,7 @@
 nContextCreate(JNIEnv *_env, jobject _this, jlong dev, jint ver, jint sdkVer, jint ct)
 {
     LOG_API("nContextCreate");
-    return (jlong)rsContextCreate((RsDevice)dev, ver, sdkVer, (RsContextType)ct, 0);
+    return (jlong)(uintptr_t)rsContextCreate((RsDevice)dev, ver, sdkVer, (RsContextType)ct, 0);
 }
 
 static jlong
@@ -267,7 +267,7 @@
     sc.samplesQ = samplesQ;
 
     LOG_API("nContextCreateGL");
-    return (jlong)rsContextCreateGL((RsDevice)dev, ver, sdkVer, sc, dpi);
+    return (jlong)(uintptr_t)rsContextCreateGL((RsDevice)dev, ver, sdkVer, sc, dpi);
 }
 
 static void
@@ -409,7 +409,7 @@
 nElementCreate(JNIEnv *_env, jobject _this, jlong con, jlong type, jint kind, jboolean norm, jint size)
 {
     LOG_API("nElementCreate, con(%p), type(%i), kind(%i), norm(%i), size(%i)", (RsContext)con, type, kind, norm, size);
-    return (jlong)rsElementCreate((RsContext)con, (RsDataType)type, (RsDataKind)kind, norm, size);
+    return (jlong)(uintptr_t)rsElementCreate((RsContext)con, (RsDataType)type, (RsDataKind)kind, norm, size);
 }
 
 static jlong
@@ -435,7 +435,7 @@
     const char **nameArray = names.c_str();
     size_t *sizeArray = names.c_str_len();
 
-    jlong id = (jlong)rsElementCreate2((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsElementCreate2((RsContext)con,
                                      (const RsElement *)ids, fieldCount,
                                      nameArray, fieldCount * sizeof(size_t),  sizeArray,
                                      (const uint32_t *)arraySizes, fieldCount);
@@ -445,7 +445,7 @@
     _env->ReleaseLongArrayElements(_ids, jIds, JNI_ABORT);
     _env->ReleaseIntArrayElements(_arraySizes, jArraySizes, JNI_ABORT);
 
-    return (jlong)id;
+    return (jlong)(uintptr_t)id;
 }
 
 static void
@@ -483,7 +483,7 @@
     rsaElementGetSubElements((RsContext)con, (RsElement)id, ids, names, arraySizes, (uint32_t)dataSize);
 
     for(uint32_t i = 0; i < dataSize; i++) {
-        const jlong id = (jlong)ids[i];
+        const jlong id = (jlong)(uintptr_t)ids[i];
         const jint arraySize = (jint)arraySizes[i];
         _env->SetObjectArrayElement(_names, i, _env->NewStringUTF(names[i]));
         _env->SetLongArrayRegion(_IDs, i, 1, &id);
@@ -504,7 +504,7 @@
     LOG_API("nTypeCreate, con(%p) eid(%p), x(%i), y(%i), z(%i), mips(%i), faces(%i), yuv(%i)",
             (RsContext)con, eid, dimx, dimy, dimz, mips, faces, yuv);
 
-    return (jlong)rsTypeCreate((RsContext)con, (RsElement)eid, dimx, dimy, dimz, mips, faces, yuv);
+    return (jlong)(uintptr_t)rsTypeCreate((RsContext)con, (RsElement)eid, dimx, dimy, dimz, mips, faces, yuv);
 }
 
 static void
@@ -521,7 +521,7 @@
     rsaTypeGetNativeData((RsContext)con, (RsType)id, typeData, 6);
 
     for(jint i = 0; i < elementCount; i ++) {
-        const jlong data = (jlong)typeData[i];
+        const jlong data = (jlong)(uintptr_t)typeData[i];
         _env->SetLongArrayRegion(_typeData, i, 1, &data);
     }
 }
@@ -532,7 +532,7 @@
 nAllocationCreateTyped(JNIEnv *_env, jobject _this, jlong con, jlong type, jint mips, jint usage, jlong pointer)
 {
     LOG_API("nAllocationCreateTyped, con(%p), type(%p), mip(%i), usage(%i), ptr(%p)", (RsContext)con, (RsElement)type, mips, usage, (void *)pointer);
-    return (jlong) rsAllocationCreateTyped((RsContext)con, (RsType)type, (RsAllocationMipmapControl)mips, (uint32_t)usage, (uintptr_t)pointer);
+    return (jlong)(uintptr_t) rsAllocationCreateTyped((RsContext)con, (RsType)type, (RsAllocationMipmapControl)mips, (uint32_t)usage, (uintptr_t)pointer);
 }
 
 static void
@@ -600,7 +600,7 @@
 
     bitmap.lockPixels();
     const void* ptr = bitmap.getPixels();
-    jlong id = (jlong)rsAllocationCreateFromBitmap((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsAllocationCreateFromBitmap((RsContext)con,
                                                   (RsType)type, (RsAllocationMipmapControl)mip,
                                                   ptr, bitmap.getSize(), usage);
     bitmap.unlockPixels();
@@ -616,7 +616,7 @@
 
     bitmap.lockPixels();
     const void* ptr = bitmap.getPixels();
-    jlong id = (jlong)rsAllocationCreateTyped((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsAllocationCreateTyped((RsContext)con,
                                             (RsType)type, (RsAllocationMipmapControl)mip,
                                             (uint32_t)usage, (uintptr_t)ptr);
     bitmap.unlockPixels();
@@ -632,7 +632,7 @@
 
     bitmap.lockPixels();
     const void* ptr = bitmap.getPixels();
-    jlong id = (jlong)rsAllocationCubeCreateFromBitmap((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsAllocationCubeCreateFromBitmap((RsContext)con,
                                                       (RsType)type, (RsAllocationMipmapControl)mip,
                                                       ptr, bitmap.getSize(), usage);
     bitmap.unlockPixels();
@@ -810,7 +810,7 @@
 nAllocationGetType(JNIEnv *_env, jobject _this, jlong con, jlong a)
 {
     LOG_API("nAllocationGetType, con(%p), a(%p)", (RsContext)con, (RsAllocation)a);
-    return (jlong) rsaAllocationGetType((RsContext)con, (RsAllocation)a);
+    return (jlong)(uintptr_t) rsaAllocationGetType((RsContext)con, (RsAllocation)a);
 }
 
 static void
@@ -828,7 +828,7 @@
     Asset* asset = reinterpret_cast<Asset*>(native_asset);
     ALOGV("______nFileA3D %p", asset);
 
-    jlong id = (jlong)rsaFileA3DCreateFromMemory((RsContext)con, asset->getBuffer(false), asset->getLength());
+    jlong id = (jlong)(uintptr_t)rsaFileA3DCreateFromMemory((RsContext)con, asset->getBuffer(false), asset->getLength());
     return id;
 }
 
@@ -846,7 +846,7 @@
         return 0;
     }
 
-    jlong id = (jlong)rsaFileA3DCreateFromAsset((RsContext)con, asset);
+    jlong id = (jlong)(uintptr_t)rsaFileA3DCreateFromAsset((RsContext)con, asset);
     return id;
 }
 
@@ -854,7 +854,7 @@
 nFileA3DCreateFromFile(JNIEnv *_env, jobject _this, jlong con, jstring fileName)
 {
     AutoJavaStringToUTF8 fileNameUTF(_env, fileName);
-    jlong id = (jlong)rsaFileA3DCreateFromFile((RsContext)con, fileNameUTF.c_str());
+    jlong id = (jlong)(uintptr_t)rsaFileA3DCreateFromFile((RsContext)con, fileNameUTF.c_str());
 
     return id;
 }
@@ -887,7 +887,7 @@
 nFileA3DGetEntryByIndex(JNIEnv *_env, jobject _this, jlong con, jlong fileA3D, jint index)
 {
     ALOGV("______nFileA3D %p", (RsFile) fileA3D);
-    jlong id = (jlong)rsaFileA3DGetEntryByIndex((RsContext)con, (uint32_t)index, (RsFile)fileA3D);
+    jlong id = (jlong)(uintptr_t)rsaFileA3DGetEntryByIndex((RsContext)con, (uint32_t)index, (RsFile)fileA3D);
     return id;
 }
 
@@ -898,7 +898,7 @@
                     jstring fileName, jfloat fontSize, jint dpi)
 {
     AutoJavaStringToUTF8 fileNameUTF(_env, fileName);
-    jlong id = (jlong)rsFontCreateFromFile((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsFontCreateFromFile((RsContext)con,
                                          fileNameUTF.c_str(), fileNameUTF.length(),
                                          fontSize, dpi);
 
@@ -912,7 +912,7 @@
     Asset* asset = reinterpret_cast<Asset*>(native_asset);
     AutoJavaStringToUTF8 nameUTF(_env, name);
 
-    jlong id = (jlong)rsFontCreateFromMemory((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsFontCreateFromMemory((RsContext)con,
                                            nameUTF.c_str(), nameUTF.length(),
                                            fontSize, dpi,
                                            asset->getBuffer(false), asset->getLength());
@@ -934,7 +934,7 @@
         return 0;
     }
 
-    jlong id = (jlong)rsFontCreateFromMemory((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsFontCreateFromMemory((RsContext)con,
                                            str.c_str(), str.length(),
                                            fontSize, dpi,
                                            asset->getBuffer(false), asset->getLength());
@@ -1283,7 +1283,7 @@
 
     //rsScriptCSetText((RsContext)con, (const char *)script_ptr, length);
 
-    ret = (jlong)rsScriptCCreate((RsContext)con,
+    ret = (jlong)(uintptr_t)rsScriptCCreate((RsContext)con,
                                 resNameUTF.c_str(), resNameUTF.length(),
                                 cacheDirUTF.c_str(), cacheDirUTF.length(),
                                 (const char *)script_ptr, length);
@@ -1294,28 +1294,28 @@
                 _exception ? JNI_ABORT: 0);
     }
 
-    return (jlong)ret;
+    return (jlong)(uintptr_t)ret;
 }
 
 static jlong
 nScriptIntrinsicCreate(JNIEnv *_env, jobject _this, jlong con, jint id, jlong eid)
 {
     LOG_API("nScriptIntrinsicCreate, con(%p) id(%i) element(%p)", (RsContext)con, id, (void *)eid);
-    return (jlong)rsScriptIntrinsicCreate((RsContext)con, id, (RsElement)eid);
+    return (jlong)(uintptr_t)rsScriptIntrinsicCreate((RsContext)con, id, (RsElement)eid);
 }
 
 static jlong
 nScriptKernelIDCreate(JNIEnv *_env, jobject _this, jlong con, jlong sid, jint slot, jint sig)
 {
     LOG_API("nScriptKernelIDCreate, con(%p) script(%p), slot(%i), sig(%i)", (RsContext)con, (void *)sid, slot, sig);
-    return (jlong)rsScriptKernelIDCreate((RsContext)con, (RsScript)sid, slot, sig);
+    return (jlong)(uintptr_t)rsScriptKernelIDCreate((RsContext)con, (RsScript)sid, slot, sig);
 }
 
 static jlong
 nScriptFieldIDCreate(JNIEnv *_env, jobject _this, jlong con, jlong sid, jint slot)
 {
     LOG_API("nScriptFieldIDCreate, con(%p) script(%p), slot(%i)", (RsContext)con, (void *)sid, slot);
-    return (jlong)rsScriptFieldIDCreate((RsContext)con, (RsScript)sid, slot);
+    return (jlong)(uintptr_t)rsScriptFieldIDCreate((RsContext)con, (RsScript)sid, slot);
 }
 
 static jlong
@@ -1359,7 +1359,7 @@
         typesPtr[i] = (RsType)jTypesPtr[i];
     }
 
-    jlong id = (jlong)rsScriptGroupCreate((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsScriptGroupCreate((RsContext)con,
                                (RsScriptKernelID *)kernelsPtr, kernelsLen * sizeof(RsScriptKernelID),
                                (RsScriptKernelID *)srcPtr, srcLen * sizeof(RsScriptKernelID),
                                (RsScriptKernelID *)dstkPtr, dstkLen * sizeof(RsScriptKernelID),
@@ -1412,7 +1412,7 @@
                     jint depthFunc)
 {
     LOG_API("nProgramStoreCreate, con(%p)", (RsContext)con);
-    return (jlong)rsProgramStoreCreate((RsContext)con, colorMaskR, colorMaskG, colorMaskB, colorMaskA,
+    return (jlong)(uintptr_t)rsProgramStoreCreate((RsContext)con, colorMaskR, colorMaskG, colorMaskB, colorMaskA,
                                       depthMask, ditherEnable, (RsBlendSrcFunc)srcFunc,
                                       (RsBlendDstFunc)destFunc, (RsDepthFunc)depthFunc);
 }
@@ -1461,7 +1461,7 @@
     for(int i = 0; i < paramLen; ++i) {
         paramPtr[i] = (uintptr_t)jParamPtr[i];
     }
-    jlong ret = (jlong)rsProgramFragmentCreate((RsContext)con, shaderUTF.c_str(), shaderUTF.length(),
+    jlong ret = (jlong)(uintptr_t)rsProgramFragmentCreate((RsContext)con, shaderUTF.c_str(), shaderUTF.length(),
                                              nameArray, texCount, sizeArray,
                                              paramPtr, paramLen);
 
@@ -1493,7 +1493,7 @@
         paramPtr[i] = (uintptr_t)jParamPtr[i];
     }
 
-    jlong ret = (jlong)rsProgramVertexCreate((RsContext)con, shaderUTF.c_str(), shaderUTF.length(),
+    jlong ret = (jlong)(uintptr_t)rsProgramVertexCreate((RsContext)con, shaderUTF.c_str(), shaderUTF.length(),
                                            nameArray, texCount, sizeArray,
                                            paramPtr, paramLen);
 
@@ -1508,7 +1508,7 @@
 nProgramRasterCreate(JNIEnv *_env, jobject _this, jlong con, jboolean pointSprite, jint cull)
 {
     LOG_API("nProgramRasterCreate, con(%p), pointSprite(%i), cull(%i)", (RsContext)con, pointSprite, cull);
-    return (jlong)rsProgramRasterCreate((RsContext)con, pointSprite, (RsCullMode)cull);
+    return (jlong)(uintptr_t)rsProgramRasterCreate((RsContext)con, pointSprite, (RsCullMode)cull);
 }
 
 
@@ -1557,7 +1557,7 @@
                jint wrapS, jint wrapT, jint wrapR, jfloat aniso)
 {
     LOG_API("nSamplerCreate, con(%p)", (RsContext)con);
-    return (jlong)rsSamplerCreate((RsContext)con,
+    return (jlong)(uintptr_t)rsSamplerCreate((RsContext)con,
                                  (RsSamplerValue)magFilter,
                                  (RsSamplerValue)minFilter,
                                  (RsSamplerValue)wrapS,
@@ -1572,7 +1572,7 @@
 nPathCreate(JNIEnv *_env, jobject _this, jlong con, jint prim, jboolean isStatic, jlong _vtx, jlong _loop, jfloat q) {
     LOG_API("nPathCreate, con(%p)", (RsContext)con);
 
-    jlong id = (jlong)rsPathCreate((RsContext)con, (RsPathPrimitive)prim, isStatic,
+    jlong id = (jlong)(uintptr_t)rsPathCreate((RsContext)con, (RsPathPrimitive)prim, isStatic,
                                    (RsAllocation)_vtx,
                                    (RsAllocation)_loop, q);
     return id;
@@ -1600,7 +1600,7 @@
     jint primLen = _env->GetArrayLength(_prim);
     jint *primPtr = _env->GetIntArrayElements(_prim, NULL);
 
-    jlong id = (jlong)rsMeshCreate((RsContext)con,
+    jlong id = (jlong)(uintptr_t)rsMeshCreate((RsContext)con,
                                (RsAllocation *)vtxPtr, vtxLen,
                                (RsAllocation *)idxPtr, idxLen,
                                (uint32_t *)primPtr, primLen);
@@ -1640,7 +1640,7 @@
     rsaMeshGetVertices((RsContext)con, (RsMesh)mesh, allocs, (uint32_t)numVtxIDs);
 
     for(jint i = 0; i < numVtxIDs; i ++) {
-        const jlong alloc = (jlong)allocs[i];
+        const jlong alloc = (jlong)(uintptr_t)allocs[i];
         _env->SetLongArrayRegion(_ids, i, 1, &alloc);
     }
 
@@ -1658,7 +1658,7 @@
     rsaMeshGetIndices((RsContext)con, (RsMesh)mesh, allocs, prims, (uint32_t)numIndices);
 
     for(jint i = 0; i < numIndices; i ++) {
-        const jlong alloc = (jlong)allocs[i];
+        const jlong alloc = (jlong)(uintptr_t)allocs[i];
         const jint prim = (jint)prims[i];
         _env->SetLongArrayRegion(_idxIds, i, 1, &alloc);
         _env->SetIntArrayRegion(_primitives, i, 1, &prim);
diff --git a/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java b/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
index b1f1954..24bfba6 100644
--- a/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
+++ b/services/accessibility/java/com/android/server/accessibility/AccessibilityManagerService.java
@@ -42,6 +42,7 @@
 import android.database.ContentObserver;
 import android.graphics.Point;
 import android.graphics.Rect;
+import android.graphics.Region;
 import android.hardware.display.DisplayManager;
 import android.hardware.input.InputManager;
 import android.net.Uri;
@@ -124,6 +125,8 @@
     //       when that accessibility services are bound.
     private static final int WAIT_FOR_USER_STATE_FULLY_INITIALIZED_MILLIS = 3000;
 
+    private static final int WAIT_WINDOWS_TIMEOUT_MILLIS = 5000;
+
     private static final String FUNCTION_REGISTER_UI_TEST_AUTOMATION_SERVICE =
         "registerUiTestAutomationService";
 
@@ -160,6 +163,8 @@
     private final List<AccessibilityServiceInfo> mEnabledServicesForFeedbackTempList =
             new ArrayList<>();
 
+    private final Region mTempRegion = new Region();
+
     private final Rect mTempRect = new Rect();
 
     private final Point mTempPoint = new Point();
@@ -741,14 +746,16 @@
     }
 
     /**
-     * Gets the bounds of the accessibility focus in the active window.
+     * Gets a point within the accessibility focused node where we can send down
+     * and up events to perform a click.
      *
-     * @param outBounds The output to which to write the focus bounds.
-     * @return Whether accessibility focus was found and the bounds are populated.
+     * @param outPoint The click point to populate.
+     * @return Whether accessibility a click point was found and set.
      */
     // TODO: (multi-display) Make sure this works for multiple displays.
-    boolean getAccessibilityFocusBounds(Rect outBounds) {
-        return getInteractionBridgeLocked().getAccessibilityFocusBoundsNotLocked(outBounds);
+    boolean getAccessibilityFocusClickPointInScreen(Point outPoint) {
+        return getInteractionBridgeLocked()
+                .getAccessibilityFocusClickPointInScreenNotLocked(outPoint);
     }
 
     /**
@@ -1367,6 +1374,8 @@
         if (mWindowsForAccessibilityCallback != null) {
             mWindowsForAccessibilityCallback = null;
             mWindowManagerService.setWindowsForAccessibilityCallback(null);
+            // Drop all windows we know about.
+            mSecurityPolicy.clearWindowsLocked();
         }
     }
 
@@ -1631,16 +1640,18 @@
                 pw.println("}]");
                 pw.println();
             }
-            final int windowCount = mSecurityPolicy.mWindows.size();
-            for (int j = 0; j < windowCount; j++) {
-                if (j > 0) {
-                    pw.append(',');
-                    pw.println();
+            if (mSecurityPolicy.mWindows != null) {
+                final int windowCount = mSecurityPolicy.mWindows.size();
+                for (int j = 0; j < windowCount; j++) {
+                    if (j > 0) {
+                        pw.append(',');
+                        pw.println();
+                    }
+                    pw.append("Window[");
+                    AccessibilityWindowInfo window = mSecurityPolicy.mWindows.get(j);
+                    pw.append(window.toString());
+                    pw.append(']');
                 }
-                pw.append("Window[");
-                AccessibilityWindowInfo window = mSecurityPolicy.mWindows.get(j);
-                pw.append(window.toString());
-                pw.append(']');
             }
         }
     }
@@ -1821,6 +1832,39 @@
         return -1;
     }
 
+    private void ensureWindowsAvailableTimed() {
+        synchronized (mLock) {
+            if (mSecurityPolicy.mWindows != null) {
+                return;
+            }
+            // If we have no registered callback, update the state we
+            // we may have to register one but it didn't happen yet.
+            if (mWindowsForAccessibilityCallback == null) {
+                UserState userState = getCurrentUserStateLocked();
+                onUserStateChangedLocked(userState);
+            }
+            // We have no windows but do not care about them, done.
+            if (mWindowsForAccessibilityCallback == null) {
+                return;
+            }
+
+            // Wait for the windows with a timeout.
+            final long startMillis = SystemClock.uptimeMillis();
+            while (mSecurityPolicy.mWindows == null) {
+                final long elapsedMillis = SystemClock.uptimeMillis() - startMillis;
+                final long remainMillis = WAIT_WINDOWS_TIMEOUT_MILLIS - elapsedMillis;
+                if (remainMillis <= 0) {
+                    return;
+                }
+                try {
+                    mLock.wait(remainMillis);
+                } catch (InterruptedException ie) {
+                    /* ignore */
+                }
+            }
+        }
+    }
+
     /**
      * This class represents an accessibility service. It stores all per service
      * data required for the service management, provides API for starting/stopping the
@@ -1876,9 +1920,6 @@
 
         final KeyEventDispatcher mKeyEventDispatcher = new KeyEventDispatcher();
 
-        final SparseArray<AccessibilityWindowInfo> mIntrospectedWindows =
-                new SparseArray<>();
-
         boolean mWasConnectedAndDied;
 
         // Handler only for dispatching accessibility events since we use event
@@ -1946,10 +1987,6 @@
                     & AccessibilityServiceInfo.FLAG_REQUEST_FILTER_KEY_EVENTS) != 0;
             mRetrieveInteractiveWindows = (info.flags
                     & AccessibilityServiceInfo.FLAG_RETRIEVE_INTERACTIVE_WINDOWS) != 0;
-
-            if (!mRetrieveInteractiveWindows) {
-                clearIntrospectedWindows();
-            }
         }
 
         /**
@@ -2065,6 +2102,7 @@
 
         @Override
         public List<AccessibilityWindowInfo> getWindows() {
+            ensureWindowsAvailableTimed();
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its perent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2087,7 +2125,6 @@
                     AccessibilityWindowInfo windowClone =
                             AccessibilityWindowInfo.obtain(window);
                     windowClone.setConnectionId(mId);
-                    mIntrospectedWindows.put(window.getId(), windowClone);
                     windows.add(windowClone);
                 }
                 return windows;
@@ -2096,6 +2133,7 @@
 
         @Override
         public AccessibilityWindowInfo getWindow(int windowId) {
+            ensureWindowsAvailableTimed();
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2115,7 +2153,6 @@
                 if (window != null) {
                     AccessibilityWindowInfo windowClone = AccessibilityWindowInfo.obtain(window);
                     windowClone.setConnectionId(mId);
-                    mIntrospectedWindows.put(windowId, windowClone);
                     return windowClone;
                 }
                 return null;
@@ -2129,6 +2166,7 @@
                 throws RemoteException {
             final int resolvedWindowId;
             IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2150,14 +2188,18 @@
                         return false;
                     }
                 }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
             }
             final int interrogatingPid = Binder.getCallingPid();
             final long identityToken = Binder.clearCallingIdentity();
             MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
             try {
-                connection.findAccessibilityNodeInfosByViewId(accessibilityNodeId,
-                        viewIdResName, interactionId, callback, mFetchFlags, interrogatingPid,
-                        interrogatingTid, spec);
+                connection.findAccessibilityNodeInfosByViewId(accessibilityNodeId, viewIdResName,
+                        partialInteractiveRegion, interactionId, callback, mFetchFlags,
+                        interrogatingPid, interrogatingTid, spec);
                 return true;
             } catch (RemoteException re) {
                 if (DEBUG) {
@@ -2176,6 +2218,7 @@
                 throws RemoteException {
             final int resolvedWindowId;
             IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2197,14 +2240,18 @@
                         return false;
                     }
                 }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
             }
             final int interrogatingPid = Binder.getCallingPid();
             final long identityToken = Binder.clearCallingIdentity();
             MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
             try {
                 connection.findAccessibilityNodeInfosByText(accessibilityNodeId, text,
-                        interactionId, callback, mFetchFlags, interrogatingPid, interrogatingTid,
-                        spec);
+                        partialInteractiveRegion, interactionId, callback, mFetchFlags,
+                        interrogatingPid, interrogatingTid, spec);
                 return true;
             } catch (RemoteException re) {
                 if (DEBUG) {
@@ -2223,6 +2270,7 @@
                 long interrogatingTid) throws RemoteException {
             final int resolvedWindowId;
             IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2244,14 +2292,18 @@
                         return false;
                     }
                 }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
             }
             final int interrogatingPid = Binder.getCallingPid();
             final long identityToken = Binder.clearCallingIdentity();
             MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
             try {
                 connection.findAccessibilityNodeInfoByAccessibilityId(accessibilityNodeId,
-                        interactionId, callback, mFetchFlags | flags, interrogatingPid,
-                        interrogatingTid, spec);
+                        partialInteractiveRegion, interactionId, callback, mFetchFlags | flags,
+                        interrogatingPid, interrogatingTid, spec);
                 return true;
             } catch (RemoteException re) {
                 if (DEBUG) {
@@ -2270,6 +2322,7 @@
                 throws RemoteException {
             final int resolvedWindowId;
             IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2292,13 +2345,18 @@
                         return false;
                     }
                 }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
             }
             final int interrogatingPid = Binder.getCallingPid();
             final long identityToken = Binder.clearCallingIdentity();
             MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
             try {
-                connection.findFocus(accessibilityNodeId, focusType, interactionId, callback,
-                        mFetchFlags, interrogatingPid, interrogatingTid, spec);
+                connection.findFocus(accessibilityNodeId, focusType, partialInteractiveRegion,
+                        interactionId, callback, mFetchFlags, interrogatingPid, interrogatingTid,
+                        spec);
                 return true;
             } catch (RemoteException re) {
                 if (DEBUG) {
@@ -2317,6 +2375,7 @@
                 throws RemoteException {
             final int resolvedWindowId;
             IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
                 // share the accessibility state of the parent. The call below
@@ -2338,13 +2397,18 @@
                         return false;
                     }
                 }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
             }
             final int interrogatingPid = Binder.getCallingPid();
             final long identityToken = Binder.clearCallingIdentity();
             MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
             try {
-                connection.focusSearch(accessibilityNodeId, direction, interactionId, callback,
-                        mFetchFlags, interrogatingPid, interrogatingTid, spec);
+                connection.focusSearch(accessibilityNodeId, direction, partialInteractiveRegion,
+                        interactionId, callback, mFetchFlags, interrogatingPid, interrogatingTid,
+                        spec);
                 return true;
             } catch (RemoteException re) {
                 if (DEBUG) {
@@ -2400,6 +2464,7 @@
             return true;
         }
 
+        @Override
         public boolean performGlobalAction(int action) {
             synchronized (mLock) {
                 // We treat calls from a profile as if made by its parent as profiles
@@ -2441,6 +2506,57 @@
         }
 
         @Override
+        public  boolean computeClickPointInScreen(int accessibilityWindowId,
+                long accessibilityNodeId, int interactionId,
+                IAccessibilityInteractionConnectionCallback callback, long interrogatingTid)
+                throws RemoteException {
+            final int resolvedWindowId;
+            IAccessibilityInteractionConnection connection = null;
+            Region partialInteractiveRegion = mTempRegion;
+            synchronized (mLock) {
+                // We treat calls from a profile as if made by its parent as profiles
+                // share the accessibility state of the parent. The call below
+                // performs the current profile parent resolution.
+                final int resolvedUserId = mSecurityPolicy
+                        .resolveCallingUserIdEnforcingPermissionsLocked(
+                                UserHandle.getCallingUserId());
+                if (resolvedUserId != mCurrentUserId) {
+                    return false;
+                }
+                resolvedWindowId = resolveAccessibilityWindowIdLocked(accessibilityWindowId);
+                final boolean permissionGranted =
+                        mSecurityPolicy.canRetrieveWindowContentLocked(this);
+                if (!permissionGranted) {
+                    return false;
+                } else {
+                    connection = getConnectionLocked(resolvedWindowId);
+                    if (connection == null) {
+                        return false;
+                    }
+                }
+                if (!mSecurityPolicy.computePartialInteractiveRegionForWindowLocked(
+                        resolvedWindowId, partialInteractiveRegion)) {
+                    partialInteractiveRegion = null;
+                }
+            }
+            final int interrogatingPid = Binder.getCallingPid();
+            final long identityToken = Binder.clearCallingIdentity();
+            MagnificationSpec spec = getCompatibleMagnificationSpecLocked(resolvedWindowId);
+            try {
+                connection.computeClickPointInScreen(accessibilityNodeId, partialInteractiveRegion,
+                        interactionId, callback, interrogatingPid, interrogatingTid, spec);
+                return true;
+            } catch (RemoteException re) {
+                if (DEBUG) {
+                    Slog.e(LOG_TAG, "Error computeClickPointInScreen().");
+                }
+            } finally {
+                Binder.restoreCallingIdentity(identityToken);
+            }
+            return false;
+        }
+
+        @Override
         public void dump(FileDescriptor fd, final PrintWriter pw, String[] args) {
             mSecurityPolicy.enforceCallingPermission(Manifest.permission.DUMP, FUNCTION_DUMP);
             synchronized (mLock) {
@@ -2607,19 +2723,10 @@
         }
 
         public void notifyClearAccessibilityNodeInfoCache() {
-            clearIntrospectedWindows();
             mInvocationHandler.sendEmptyMessage(
                     InvocationHandler.MSG_CLEAR_ACCESSIBILITY_CACHE);
         }
 
-        private void clearIntrospectedWindows() {
-            final int windowCount = mIntrospectedWindows.size();
-            for (int i = windowCount - 1; i >= 0; i--) {
-                mIntrospectedWindows.valueAt(i).recycle();
-                mIntrospectedWindows.removeAt(i);
-            }
-        }
-
         private void notifyGestureInternal(int gestureId) {
             final IAccessibilityServiceClient listener;
             synchronized (mLock) {
@@ -2955,6 +3062,9 @@
 
                 // Let the policy update the focused and active windows.
                 mSecurityPolicy.updateWindowsLocked(reportedWindows);
+
+                // Someone may be waiting for the windows - advertise it.
+                mLock.notifyAll();
             }
         }
 
@@ -3065,30 +3175,43 @@
             }
         }
 
-        public boolean getAccessibilityFocusBoundsNotLocked(Rect outBounds) {
+        public boolean getAccessibilityFocusClickPointInScreenNotLocked(Point outPoint) {
             AccessibilityNodeInfo focus = getAccessibilityFocusNotLocked();
             if (focus == null) {
                 return false;
             }
 
             synchronized (mLock) {
-                focus.getBoundsInScreen(outBounds);
+                Point point = mClient.computeClickPointInScreen(mConnectionId,
+                        focus.getWindowId(), focus.getSourceNodeId());
+
+                if (point == null) {
+                    return false;
+                }
 
                 MagnificationSpec spec = getCompatibleMagnificationSpecLocked(focus.getWindowId());
                 if (spec != null && !spec.isNop()) {
-                    outBounds.offset((int) -spec.offsetX, (int) -spec.offsetY);
-                    outBounds.scale(1 / spec.scale);
+                    point.offset((int) -spec.offsetX, (int) -spec.offsetY);
+                    point.x = (int) (point.x * (1 / spec.scale));
+                    point.y = (int) (point.y * (1 / spec.scale));
                 }
 
-                // Clip to the window rectangle.
+                // Make sure the point is within the window.
                 Rect windowBounds = mTempRect;
                 getActiveWindowBounds(windowBounds);
-                outBounds.intersect(windowBounds);
+                if (!windowBounds.contains(point.x, point.y)) {
+                    return false;
+                }
 
-                // Clip to the screen rectangle.
-                mDefaultDisplay.getRealSize(mTempPoint);
-                outBounds.intersect(0, 0, mTempPoint.x, mTempPoint.y);
+                // Make sure the point is within the screen.
+                Point screenSize = mTempPoint;
+                mDefaultDisplay.getRealSize(screenSize);
+                if (point.x < 0 || point.x > screenSize.x
+                        || point.y < 0 || point.y > screenSize.y) {
+                    return false;
+                }
 
+                outPoint.set(point.x, point.y);
                 return true;
             }
         }
@@ -3130,7 +3253,7 @@
             | AccessibilityEvent.TYPE_VIEW_ACCESSIBILITY_FOCUS_CLEARED
             | AccessibilityEvent.TYPE_VIEW_TEXT_TRAVERSED_AT_MOVEMENT_GRANULARITY;
 
-        public final List<AccessibilityWindowInfo> mWindows = new ArrayList<>();
+        public List<AccessibilityWindowInfo> mWindows;
 
         public int mActiveWindowId = INVALID_WINDOW_ID;
         public int mFocusedWindowId = INVALID_WINDOW_ID;
@@ -3154,7 +3277,7 @@
                         // But we still have not gotten the window state from the
                         // window manager, so delay the notification until then.
                         AccessibilityWindowInfo window = findWindowById(event.getWindowId());
-                        if (window == null || !window.isFocused()) {
+                        if (window == null) {
                             mShowingFocusedWindowEvent = AccessibilityEvent.obtain(event);
                             return false;
                         }
@@ -3185,7 +3308,17 @@
             }
         }
 
+        public void clearWindowsLocked() {
+            List<AccessibilityWindowInfo> windows = Collections.emptyList();
+            updateWindowsLocked(windows);
+            mWindows = null;
+        }
+
         public void updateWindowsLocked(List<AccessibilityWindowInfo> windows) {
+            if (mWindows == null) {
+                mWindows = new ArrayList<>();
+            }
+
             final int oldWindowCount = mWindows.size();
             for (int i = oldWindowCount - 1; i >= 0; i--) {
                 mWindows.remove(i).recycle();
@@ -3231,6 +3364,9 @@
                     if (window.getId() == mActiveWindowId) {
                         window.setActive(true);
                     }
+                    if (window.getId() == mAccessibilityFocusedWindowId) {
+                        window.setAccessibilityFocused(true);
+                    }
                 }
             }
 
@@ -3241,7 +3377,7 @@
             if (mShowingFocusedWindowEvent != null) {
                 final int windowId = mShowingFocusedWindowEvent.getWindowId();
                 AccessibilityWindowInfo window = findWindowById(windowId);
-                if (window != null && window.isFocused()) {
+                if (window != null) {
                     // Sending does the recycle.
                     sendAccessibilityEvent(mShowingFocusedWindowEvent, mCurrentUserId);
                 }
@@ -3249,6 +3385,42 @@
             }
         }
 
+        public boolean computePartialInteractiveRegionForWindowLocked(int windowId,
+                Region outRegion) {
+            if (mWindows == null) {
+                return false;
+            }
+
+            // Windows are ordered in z order so start from the botton and find
+            // the window of interest. After that all windows that cover it should
+            // be subtracted from the resulting region. Note that for accessibility
+            // we are returning only interactive windows.
+            Region windowInteractiveRegion = null;
+            boolean windowInteractiveRegionChanged = false;
+
+            final int windowCount = mWindows.size();
+            for (int i = windowCount - 1; i >= 0; i--) {
+                AccessibilityWindowInfo currentWindow = mWindows.get(i);
+                if (windowInteractiveRegion == null) {
+                    if (currentWindow.getId() == windowId) {
+                        Rect currentWindowBounds = mTempRect;
+                        currentWindow.getBoundsInScreen(currentWindowBounds);
+                        outRegion.set(currentWindowBounds);
+                        windowInteractiveRegion = outRegion;
+                        continue;
+                    }
+                } else {
+                    Rect currentWindowBounds = mTempRect;
+                    currentWindow.getBoundsInScreen(currentWindowBounds);
+                    if (windowInteractiveRegion.op(currentWindowBounds, Region.Op.DIFFERENCE)) {
+                        windowInteractiveRegionChanged = true;
+                    }
+                }
+            }
+
+            return windowInteractiveRegionChanged;
+        }
+
         public void updateEventSourceLocked(AccessibilityEvent event) {
             if ((event.getEventType() & RETRIEVAL_ALLOWING_EVENT_TYPES) == 0) {
                 event.setSource(null);
@@ -3298,7 +3470,7 @@
                         if (mAccessibilityFocusedWindowId != windowId) {
                             mMainHandler.obtainMessage(MainHandler.MSG_CLEAR_ACCESSIBILITY_FOCUS,
                                     mAccessibilityFocusedWindowId, 0).sendToTarget();
-                            mAccessibilityFocusedWindowId = windowId;
+                            mSecurityPolicy.setAccessibilityFocusedWindowLocked(windowId);
                             mAccessibilityFocusNodeId = nodeId;
                         }
                     }
@@ -3354,21 +3526,43 @@
         private void setActiveWindowLocked(int windowId) {
             if (mActiveWindowId != windowId) {
                 mActiveWindowId = windowId;
-                final int windowCount = mWindows.size();
-                for (int i = 0; i < windowCount; i++) {
-                    AccessibilityWindowInfo window = mWindows.get(i);
-                    window.setActive(window.getId() == windowId);
+                if (mWindows != null) {
+                    final int windowCount = mWindows.size();
+                    for (int i = 0; i < windowCount; i++) {
+                        AccessibilityWindowInfo window = mWindows.get(i);
+                        window.setActive(window.getId() == windowId);
+                    }
                 }
                 notifyWindowsChanged();
             }
         }
 
+        private void setAccessibilityFocusedWindowLocked(int windowId) {
+            if (mAccessibilityFocusedWindowId != windowId) {
+                mAccessibilityFocusedWindowId = windowId;
+                if (mWindows != null) {
+                    final int windowCount = mWindows.size();
+                    for (int i = 0; i < windowCount; i++) {
+                        AccessibilityWindowInfo window = mWindows.get(i);
+                        window.setAccessibilityFocused(window.getId() == windowId);
+                    }
+                }
+
+                notifyWindowsChanged();
+            }
+        }
+
         private void notifyWindowsChanged() {
-            // Let the client know the windows changed.
-            AccessibilityEvent event = AccessibilityEvent.obtain(
-                    AccessibilityEvent.TYPE_WINDOWS_CHANGED);
-            event.setEventTime(SystemClock.uptimeMillis());
-            sendAccessibilityEvent(event, mCurrentUserId);
+            final long identity = Binder.clearCallingIdentity();
+            try {
+                // Let the client know the windows changed.
+                AccessibilityEvent event = AccessibilityEvent.obtain(
+                        AccessibilityEvent.TYPE_WINDOWS_CHANGED);
+                event.setEventTime(SystemClock.uptimeMillis());
+                sendAccessibilityEvent(event, mCurrentUserId);
+            } finally {
+                Binder.restoreCallingIdentity(identity);
+            }
         }
 
         public boolean canGetAccessibilityNodeInfoLocked(Service service, int windowId) {
@@ -3444,11 +3638,13 @@
         }
 
         private AccessibilityWindowInfo findWindowById(int windowId) {
-            final int windowCount = mWindows.size();
-            for (int i = 0; i < windowCount; i++) {
-                AccessibilityWindowInfo window = mWindows.get(i);
-                if (window.getId() == windowId) {
-                    return window;
+            if (mWindows != null) {
+                final int windowCount = mWindows.size();
+                for (int i = 0; i < windowCount; i++) {
+                    AccessibilityWindowInfo window = mWindows.get(i);
+                    if (window.getId() == windowId) {
+                        return window;
+                    }
                 }
             }
             return null;
diff --git a/services/accessibility/java/com/android/server/accessibility/DisplayAdjustmentUtils.java b/services/accessibility/java/com/android/server/accessibility/DisplayAdjustmentUtils.java
index 394c196..38827d0 100644
--- a/services/accessibility/java/com/android/server/accessibility/DisplayAdjustmentUtils.java
+++ b/services/accessibility/java/com/android/server/accessibility/DisplayAdjustmentUtils.java
@@ -60,15 +60,17 @@
     public static boolean hasAdjustments(Context context, int userId) {
         final ContentResolver cr = context.getContentResolver();
 
-        boolean hasColorTransform = Settings.Secure.getIntForUser(
-                cr, Settings.Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, 0, userId) == 1;
-
-        if (!hasColorTransform) {
-            hasColorTransform |= Settings.Secure.getIntForUser(
-                cr, Settings.Secure.ACCESSIBILITY_DISPLAY_DALTONIZER_ENABLED, 0, userId) == 1;
+        if (Settings.Secure.getIntForUser(cr,
+                Settings.Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, 0, userId) != 0) {
+            return true;
         }
 
-        return hasColorTransform;
+        if (Settings.Secure.getIntForUser(cr,
+                Settings.Secure.ACCESSIBILITY_DISPLAY_DALTONIZER_ENABLED, 0, userId) != 0) {
+            return true;
+        }
+
+        return false;
     }
 
     /**
@@ -76,52 +78,39 @@
      */
     public static void applyAdjustments(Context context, int userId) {
         final ContentResolver cr = context.getContentResolver();
-        float[] colorMatrix = new float[16];
-        float[] outputMatrix = new float[16];
-        boolean hasColorTransform = false;
+        float[] colorMatrix = null;
 
-        Matrix.setIdentityM(colorMatrix, 0);
-
-        final boolean inversionEnabled = Settings.Secure.getIntForUser(
-                cr, Settings.Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, 0, userId) == 1;
-        if (inversionEnabled) {
-            final float[] inversionMatrix = INVERSION_MATRIX_VALUE_ONLY;
-            Matrix.multiplyMM(outputMatrix, 0, colorMatrix, 0, inversionMatrix, 0);
-
-            colorMatrix = outputMatrix;
-            outputMatrix = colorMatrix;
-
-            hasColorTransform = true;
+        if (Settings.Secure.getIntForUser(cr,
+                Settings.Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, 0, userId) != 0) {
+            colorMatrix = multiply(colorMatrix, INVERSION_MATRIX_VALUE_ONLY);
         }
 
-        final boolean daltonizerEnabled = Settings.Secure.getIntForUser(
-                cr, Settings.Secure.ACCESSIBILITY_DISPLAY_DALTONIZER_ENABLED, 0, userId) != 0;
-        if (daltonizerEnabled) {
+        if (Settings.Secure.getIntForUser(cr,
+                Settings.Secure.ACCESSIBILITY_DISPLAY_DALTONIZER_ENABLED, 0, userId) != 0) {
             final int daltonizerMode = Settings.Secure.getIntForUser(cr,
                     Settings.Secure.ACCESSIBILITY_DISPLAY_DALTONIZER, DEFAULT_DISPLAY_DALTONIZER,
                     userId);
             // Monochromacy isn't supported by the native Daltonizer.
             if (daltonizerMode == AccessibilityManager.DALTONIZER_SIMULATE_MONOCHROMACY) {
-                Matrix.multiplyMM(outputMatrix, 0, colorMatrix, 0, GRAYSCALE_MATRIX, 0);
-
-                final float[] temp = colorMatrix;
-                colorMatrix = outputMatrix;
-                outputMatrix = temp;
-
-                hasColorTransform = true;
-                nativeSetDaltonizerMode(AccessibilityManager.DALTONIZER_DISABLED);
+                colorMatrix = multiply(colorMatrix, GRAYSCALE_MATRIX);
+                setDaltonizerMode(AccessibilityManager.DALTONIZER_DISABLED);
             } else {
-                nativeSetDaltonizerMode(daltonizerMode);
+                setDaltonizerMode(daltonizerMode);
             }
         } else {
-            nativeSetDaltonizerMode(AccessibilityManager.DALTONIZER_DISABLED);
+            setDaltonizerMode(AccessibilityManager.DALTONIZER_DISABLED);
         }
 
-        if (hasColorTransform) {
-            nativeSetColorTransform(colorMatrix);
-        } else {
-            nativeSetColorTransform(null);
+        setColorTransform(colorMatrix);
+    }
+
+    private static float[] multiply(float[] matrix, float[] other) {
+        if (matrix == null) {
+            return other;
         }
+        float[] result = new float[16];
+        Matrix.multiplyMM(result, 0, matrix, 0, other, 0);
+        return result;
     }
 
     /**
@@ -130,7 +119,7 @@
      *
      * @param mode new Daltonization mode
      */
-    private static void nativeSetDaltonizerMode(int mode) {
+    private static void setDaltonizerMode(int mode) {
         try {
             final IBinder flinger = ServiceManager.getService("SurfaceFlinger");
             if (flinger != null) {
@@ -152,7 +141,7 @@
      * @param m the float array that holds the transformation matrix, or null to
      *            disable transformation
      */
-    private static void nativeSetColorTransform(float[] m) {
+    private static void setColorTransform(float[] m) {
         try {
             final IBinder flinger = ServiceManager.getService("SurfaceFlinger");
             if (flinger != null) {
diff --git a/services/accessibility/java/com/android/server/accessibility/TouchExplorer.java b/services/accessibility/java/com/android/server/accessibility/TouchExplorer.java
index ac0ca0a..9e63433 100644
--- a/services/accessibility/java/com/android/server/accessibility/TouchExplorer.java
+++ b/services/accessibility/java/com/android/server/accessibility/TouchExplorer.java
@@ -24,6 +24,7 @@
 import android.gesture.GestureStore;
 import android.gesture.GestureStroke;
 import android.gesture.Prediction;
+import android.graphics.Point;
 import android.graphics.Rect;
 import android.os.Handler;
 import android.os.SystemClock;
@@ -171,6 +172,9 @@
     // Temporary rectangle to avoid instantiation.
     private final Rect mTempRect = new Rect();
 
+    // Temporary point to avoid instantiation.
+    private final Point mTempPoint = new Point();
+
     // Context in which this explorer operates.
     private final Context mContext;
 
@@ -1157,18 +1161,18 @@
                 mInjectedPointerTracker.getLastInjectedHoverEventForClick();
             if (lastExploreEvent == null) {
                 // No last touch explored event but there is accessibility focus in
-                // the active window. We click in the middle of the focus bounds.
-                Rect focusBounds = mTempRect;
-                if (mAms.getAccessibilityFocusBounds(focusBounds)) {
-                    clickLocationX = focusBounds.centerX();
-                    clickLocationY = focusBounds.centerY();
+                // the active window. We click in the focus bounds.
+                Point point = mTempPoint;
+                if (mAms.getAccessibilityFocusClickPointInScreen(point)) {
+                    clickLocationX = point.x;
+                    clickLocationY = point.y;
                 } else {
                     // Out of luck - do nothing.
                     return;
                 }
             } else {
                 // If the click is within the active window but not within the
-                // accessibility focus bounds we click in the focus center.
+                // accessibility focus bounds we click in the focus bounds.
                 final int lastExplorePointerIndex = lastExploreEvent.getActionIndex();
                 clickLocationX = (int) lastExploreEvent.getX(lastExplorePointerIndex);
                 clickLocationY = (int) lastExploreEvent.getY(lastExplorePointerIndex);
@@ -1176,12 +1180,10 @@
                 if (mLastTouchedWindowId == mAms.getActiveWindowId()) {
                     mAms.getActiveWindowBounds(activeWindowBounds);
                     if (activeWindowBounds.contains(clickLocationX, clickLocationY)) {
-                        Rect focusBounds = mTempRect;
-                        if (mAms.getAccessibilityFocusBounds(focusBounds)) {
-                            if (!focusBounds.contains(clickLocationX, clickLocationY)) {
-                                clickLocationX = focusBounds.centerX();
-                                clickLocationY = focusBounds.centerY();
-                            }
+                        Point point = mTempPoint;
+                        if (mAms.getAccessibilityFocusClickPointInScreen(point)) {
+                            clickLocationX = point.x;
+                            clickLocationY = point.y;
                         }
                     }
                 }
@@ -1330,18 +1332,18 @@
                 mInjectedPointerTracker.getLastInjectedHoverEventForClick();
             if (lastExploreEvent == null) {
                 // No last touch explored event but there is accessibility focus in
-                // the active window. We click in the middle of the focus bounds.
-                Rect focusBounds = mTempRect;
-                if (mAms.getAccessibilityFocusBounds(focusBounds)) {
-                    clickLocationX = focusBounds.centerX();
-                    clickLocationY = focusBounds.centerY();
+                // the active window. We click in the focus bounds.
+                Point point = mTempPoint;
+                if (mAms.getAccessibilityFocusClickPointInScreen(point)) {
+                    clickLocationX = point.x;
+                    clickLocationY = point.y;
                 } else {
                     // Out of luck - do nothing.
                     return;
                 }
             } else {
                 // If the click is within the active window but not within the
-                // accessibility focus bounds we click in the focus center.
+                // accessibility focus bounds we click in the focus bounds.
                 final int lastExplorePointerIndex = lastExploreEvent.getActionIndex();
                 clickLocationX = (int) lastExploreEvent.getX(lastExplorePointerIndex);
                 clickLocationY = (int) lastExploreEvent.getY(lastExplorePointerIndex);
@@ -1349,12 +1351,10 @@
                 if (mLastTouchedWindowId == mAms.getActiveWindowId()) {
                     mAms.getActiveWindowBounds(activeWindowBounds);
                     if (activeWindowBounds.contains(clickLocationX, clickLocationY)) {
-                        Rect focusBounds = mTempRect;
-                        if (mAms.getAccessibilityFocusBounds(focusBounds)) {
-                            if (!focusBounds.contains(clickLocationX, clickLocationY)) {
-                                clickLocationX = focusBounds.centerX();
-                                clickLocationY = focusBounds.centerY();
-                            }
+                        Point point = mTempPoint;
+                        if (mAms.getAccessibilityFocusClickPointInScreen(point)) {
+                            clickLocationX = point.x;
+                            clickLocationY = point.y;
                         }
                     }
                 }
diff --git a/services/appwidget/java/com/android/server/appwidget/AppWidgetServiceImpl.java b/services/appwidget/java/com/android/server/appwidget/AppWidgetServiceImpl.java
index 609ffda..d05de69 100644
--- a/services/appwidget/java/com/android/server/appwidget/AppWidgetServiceImpl.java
+++ b/services/appwidget/java/com/android/server/appwidget/AppWidgetServiceImpl.java
@@ -18,8 +18,10 @@
 
 import android.app.AlarmManager;
 import android.app.AppGlobals;
+import android.app.AppOpsManager;
 import android.app.PendingIntent;
 import android.app.admin.DevicePolicyManagerInternal;
+import android.app.admin.DevicePolicyManagerInternal.OnCrossProfileWidgetProvidersChangeListener;
 import android.appwidget.AppWidgetManager;
 import android.appwidget.AppWidgetProviderInfo;
 import android.content.BroadcastReceiver;
@@ -102,7 +104,8 @@
 import java.util.Map;
 import java.util.Set;
 
-class AppWidgetServiceImpl extends IAppWidgetService.Stub implements WidgetBackupProvider {
+class AppWidgetServiceImpl extends IAppWidgetService.Stub implements WidgetBackupProvider,
+        OnCrossProfileWidgetProvidersChangeListener {
     private static final String TAG = "AppWidgetServiceImpl";
 
     private static boolean DEBUG = false;
@@ -175,6 +178,7 @@
     private final IPackageManager mPackageManager;
     private final AlarmManager mAlarmManager;
     private final UserManager mUserManager;
+    private final AppOpsManager mAppOpsManager;
 
     private final SecurityPolicy mSecurityPolicy;
 
@@ -193,12 +197,14 @@
         mPackageManager = AppGlobals.getPackageManager();
         mAlarmManager = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE);
         mUserManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
+        mAppOpsManager = (AppOpsManager) mContext.getSystemService(Context.APP_OPS_SERVICE);
         mSaveStateHandler = BackgroundThread.getHandler();
         mCallbackHandler = new CallbackHandler(mContext.getMainLooper());
         mBackupRestoreController = new BackupRestoreController();
         mSecurityPolicy = new SecurityPolicy();
         computeMaximumWidgetBitmapMemory();
         registerBroadcastReceiver();
+        registerOnCrossProfileProvidersChangedListener();
     }
 
     private void computeMaximumWidgetBitmapMemory() {
@@ -243,6 +249,15 @@
                 userFilter, null, null);
     }
 
+    private void registerOnCrossProfileProvidersChangedListener() {
+        DevicePolicyManagerInternal devicePolicyManager = LocalServices.getService(
+                DevicePolicyManagerInternal.class);
+        // The device policy is an optional component.
+        if (devicePolicyManager != null) {
+            devicePolicyManager.addOnCrossProfileWidgetProvidersChangeListener(this);
+        }
+    }
+
     public void setSafeMode(boolean safeMode) {
         mSafeMode = safeMode;
     }
@@ -368,7 +383,7 @@
                 saveGroupStateAsync(userId);
 
                 // If the set of providers has been modified, notify each active AppWidgetHost
-                scheduleNotifyHostsForProvidersChangedLocked();
+                scheduleNotifyGroupHostsForProvidersChangedLocked(userId);
             }
         }
     }
@@ -425,12 +440,10 @@
 
     @Override
     public void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
-        if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.DUMP)
-                != PackageManager.PERMISSION_GRANTED) {
-            throw new SecurityException("Permission Denial: can't dump from from pid="
-                    + Binder.getCallingPid()
-                    + ", uid=" + Binder.getCallingUid());
-        }
+        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.DUMP,
+                                                "Permission Denial: can't dump from from pid="
+                                                + Binder.getCallingPid()
+                                                + ", uid=" + Binder.getCallingUid());
 
         synchronized (mLock) {
             int N = mProviders.size();
@@ -878,6 +891,9 @@
             Slog.i(TAG, "bindRemoteViewsService() " + userId);
         }
 
+        // Make sure the package runs under the caller uid.
+        mSecurityPolicy.enforceCallFromPackage(callingPackage);
+
         synchronized (mLock) {
             ensureGroupStateLoadedLocked(userId);
 
@@ -1527,7 +1543,7 @@
                 widget.views = views;
             }
 
-            scheduleNotifyUpdateAppWidgetLocked(widget);
+            scheduleNotifyUpdateAppWidgetLocked(widget, views);
         }
     }
 
@@ -1599,7 +1615,7 @@
         }
     }
 
-    private void scheduleNotifyUpdateAppWidgetLocked(Widget widget) {
+    private void scheduleNotifyUpdateAppWidgetLocked(Widget widget, RemoteViews updateViews) {
         if (widget == null || widget.provider == null || widget.provider.zombie
                 || widget.host.callbacks == null || widget.host.zombie) {
             return;
@@ -1608,7 +1624,7 @@
         SomeArgs args = SomeArgs.obtain();
         args.arg1 = widget.host;
         args.arg2 = widget.host.callbacks;
-        args.arg3 = widget.views;
+        args.arg3 = updateViews;
         args.argi1 = widget.appWidgetId;
 
         mCallbackHandler.obtainMessage(
@@ -1657,11 +1673,27 @@
         }
     }
 
-    private void scheduleNotifyHostsForProvidersChangedLocked() {
+    private void scheduleNotifyGroupHostsForProvidersChangedLocked(int userId) {
+        final int[] profileIds = mSecurityPolicy.getEnabledGroupProfileIds(userId);
+
         final int N = mHosts.size();
         for (int i = N - 1; i >= 0; i--) {
             Host host = mHosts.get(i);
 
+            boolean hostInGroup = false;
+            final int M = profileIds.length;
+            for (int j = 0; j < M; j++) {
+                final int profileId = profileIds[j];
+                if (host.getUserId() == profileId) {
+                    hostInGroup = true;
+                    break;
+                }
+            }
+
+            if (!hostInGroup) {
+                continue;
+            }
+
             if (host == null || host.zombie || host.callbacks == null) {
                 continue;
             }
@@ -1829,7 +1861,7 @@
 
     private void deleteProviderLocked(Provider provider) {
         int N = provider.widgets.size();
-        for (int i = 0; i < N; i++) {
+        for (int i = N - 1; i >= 0; i--) {
             Widget widget = provider.widgets.remove(i);
             // Call back with empty RemoteViews
             updateAppWidgetInstanceLocked(widget, null, false);
@@ -2617,6 +2649,9 @@
 
     private void onUserStopped(int userId) {
         synchronized (mLock) {
+            boolean providersChanged = false;
+            boolean crossProfileWidgetsChanged = false;
+
             // Remove widgets that have both host and provider in the user.
             final int widgetCount = mWidgets.size();
             for (int i = widgetCount - 1; i >= 0; i--) {
@@ -2645,6 +2680,7 @@
             for (int i = hostCount - 1; i >= 0; i--) {
                 Host host = mHosts.get(i);
                 if (host.getUserId() == userId) {
+                    crossProfileWidgetsChanged |= !host.widgets.isEmpty();
                     deleteHostLocked(host);
                 }
             }
@@ -2654,6 +2690,8 @@
             for (int i = providerCount - 1; i >= 0; i--) {
                 Provider provider = mProviders.get(i);
                 if (provider.getUserId() == userId) {
+                    crossProfileWidgetsChanged |= !provider.widgets.isEmpty();
+                    providersChanged = true;
                     deleteProviderLocked(provider);
                 }
             }
@@ -2678,6 +2716,17 @@
             if (nextIdIndex >= 0) {
                 mNextAppWidgetIds.removeAt(nextIdIndex);
             }
+
+            // Announce removed provider changes to all hosts in the group.
+            if (providersChanged) {
+                scheduleNotifyGroupHostsForProvidersChangedLocked(userId);
+            }
+
+            // Save state if removing a profile changed the group state.
+            // Nothing will be saved if the group parent was removed.
+            if (crossProfileWidgetsChanged) {
+                saveGroupStateAsync(userId);
+            }
         }
     }
 
@@ -2843,6 +2892,31 @@
         }
     }
 
+    @Override
+    public void onCrossProfileWidgetProvidersChanged(int userId, List<String> packages) {
+        final int parentId = mSecurityPolicy.getProfileParent(userId);
+        // We care only if the white-listed package is in a profile of
+        // the group parent as only the parent can add widgets from the
+        // profile and not the other way around.
+        if (parentId != userId) {
+            synchronized (mLock) {
+                boolean providersChanged = false;
+
+                final int packageCount = packages.size();
+                for (int i = 0; i < packageCount; i++) {
+                    String packageName = packages.get(i);
+                    providersChanged |= updateProvidersForPackageLocked(packageName,
+                            userId, null);
+                }
+
+                if (providersChanged) {
+                    saveGroupStateAsync(userId);
+                    scheduleNotifyGroupHostsForProvidersChangedLocked(userId);
+                }
+            }
+        }
+    }
+
     private final class CallbackHandler extends Handler {
         public static final int MSG_NOTIFY_UPDATE_APP_WIDGET = 1;
         public static final int MSG_NOTIFY_PROVIDER_CHANGED = 2;
@@ -2969,26 +3043,7 @@
         }
 
         public void enforceCallFromPackage(String packageName) {
-            if (!isCallFromPackage(packageName)) {
-                throw new SecurityException("Package " + packageName
-                        + " not running under user " + UserHandle.getCallingUserId());
-            }
-        }
-
-        public boolean isCallFromPackage(String packageName) {
-            // System and root call all from anywhere they want.
-            final int callingUid = Binder.getCallingUid();
-            if (callingUid == Process.SYSTEM_UID || callingUid == 0 /* root */) {
-                return true;
-            }
-            // Check if the package is present for the given profile.
-            final int packageUid = getUidForPackage(packageName,
-                    UserHandle.getUserId(callingUid));
-            if (packageUid < 0) {
-                return false;
-            }
-            // Check if the call for a package is coming from that package.
-            return UserHandle.isSameApp(callingUid, packageUid);
+            mAppOpsManager.checkPackage(Binder.getCallingUid(), packageName);
         }
 
         public boolean hasCallerBindPermissionOrBindWhiteListedLocked(String packageName) {
@@ -3981,4 +4036,4 @@
             }
         }
     }
-}
\ No newline at end of file
+}
diff --git a/services/backup/java/com/android/server/backup/BackupManagerService.java b/services/backup/java/com/android/server/backup/BackupManagerService.java
index c44474d..f6e2e67 100644
--- a/services/backup/java/com/android/server/backup/BackupManagerService.java
+++ b/services/backup/java/com/android/server/backup/BackupManagerService.java
@@ -34,7 +34,6 @@
 import android.app.backup.IFullBackupRestoreObserver;
 import android.app.backup.IRestoreObserver;
 import android.app.backup.IRestoreSession;
-import android.app.job.JobParameters;
 import android.content.ActivityNotFoundException;
 import android.content.BroadcastReceiver;
 import android.content.ComponentName;
@@ -76,9 +75,11 @@
 import android.os.WorkSource;
 import android.os.Environment.UserEnvironment;
 import android.os.storage.IMountService;
+import android.os.storage.StorageManager;
 import android.provider.Settings;
 import android.system.ErrnoException;
 import android.system.Os;
+import android.util.ArrayMap;
 import android.util.AtomicFile;
 import android.util.EventLog;
 import android.util.Log;
@@ -308,12 +309,13 @@
     volatile boolean mClearingData;
 
     // Transport bookkeeping
-    final HashMap<String,String> mTransportNames
-            = new HashMap<String,String>();             // component name -> registration name
-    final HashMap<String,IBackupTransport> mTransports
-            = new HashMap<String,IBackupTransport>();   // registration name -> binder
-    final ArrayList<TransportConnection> mTransportConnections
-            = new ArrayList<TransportConnection>();
+    final Intent mTransportServiceIntent = new Intent(SERVICE_ACTION_TRANSPORT_HOST);
+    final ArrayMap<String,String> mTransportNames
+            = new ArrayMap<String,String>();             // component name -> registration name
+    final ArrayMap<String,IBackupTransport> mTransports
+            = new ArrayMap<String,IBackupTransport>();   // registration name -> binder
+    final ArrayMap<String,TransportConnection> mTransportConnections
+            = new ArrayMap<String,TransportConnection>();
     String mCurrentTransport;
     ActiveRestoreSession mActiveRestoreSession;
 
@@ -867,10 +869,12 @@
                         // the timeout is suspended while a restore is in progress.  Clean
                         // up now.
                         Slog.w(TAG, "Restore session timed out; aborting");
+                        mActiveRestoreSession.markTimedOut();
                         post(mActiveRestoreSession.new EndRestoreRunnable(
                                 BackupManagerService.this, mActiveRestoreSession));
                     }
                 }
+                break;
             }
 
             case MSG_FULL_CONFIRMATION_TIMEOUT:
@@ -1061,42 +1065,19 @@
         }
         if (DEBUG) Slog.v(TAG, "Starting with transport " + mCurrentTransport);
 
-        // Find transport hosts and bind to their services
-        Intent transportServiceIntent = new Intent(SERVICE_ACTION_TRANSPORT_HOST);
+        // Find all transport hosts and bind to their services
         List<ResolveInfo> hosts = mPackageManager.queryIntentServicesAsUser(
-                transportServiceIntent, 0, UserHandle.USER_OWNER);
+                mTransportServiceIntent, 0, UserHandle.USER_OWNER);
         if (DEBUG) {
             Slog.v(TAG, "Found transports: " + ((hosts == null) ? "null" : hosts.size()));
         }
         if (hosts != null) {
-            if (MORE_DEBUG) {
-                for (int i = 0; i < hosts.size(); i++) {
-                    ServiceInfo info = hosts.get(i).serviceInfo;
-                    Slog.v(TAG, "   " + info.packageName + "/" + info.name);
-                }
-            }
             for (int i = 0; i < hosts.size(); i++) {
-                try {
-                    ServiceInfo info = hosts.get(i).serviceInfo;
-                    PackageInfo packInfo = mPackageManager.getPackageInfo(info.packageName, 0);
-                    if ((packInfo.applicationInfo.flags & ApplicationInfo.FLAG_PRIVILEGED) != 0) {
-                        ComponentName svcName = new ComponentName(info.packageName, info.name);
-                        if (DEBUG) {
-                            Slog.i(TAG, "Binding to transport host " + svcName);
-                        }
-                        Intent intent = new Intent(transportServiceIntent);
-                        intent.setComponent(svcName);
-                        TransportConnection connection = new TransportConnection();
-                        mTransportConnections.add(connection);
-                        context.bindServiceAsUser(intent,
-                                connection, Context.BIND_AUTO_CREATE,
-                                UserHandle.OWNER);
-                    } else {
-                        Slog.w(TAG, "Transport package not privileged: " + info.packageName);
-                    }
-                } catch (Exception e) {
-                    Slog.e(TAG, "Problem resolving transport service: " + e.getMessage());
+                final ServiceInfo transport = hosts.get(i).serviceInfo;
+                if (MORE_DEBUG) {
+                    Slog.v(TAG, "   " + transport.packageName + "/" + transport.name);
                 }
+                tryBindTransport(transport);
             }
         }
 
@@ -1253,6 +1234,7 @@
         IntentFilter filter = new IntentFilter();
         filter.addAction(Intent.ACTION_PACKAGE_ADDED);
         filter.addAction(Intent.ACTION_PACKAGE_REMOVED);
+        filter.addAction(Intent.ACTION_PACKAGE_CHANGED);
         filter.addDataScheme("package");
         mContext.registerReceiver(mBroadcastReceiver, filter);
         // Register for events related to sdcard installation.
@@ -1450,43 +1432,7 @@
         return array;
     }
 
-    // Backup password management
     boolean passwordMatchesSaved(String algorithm, String candidatePw, int rounds) {
-        // First, on an encrypted device we require matching the device pw
-        final boolean isEncrypted;
-        try {
-            isEncrypted = (mMountService.getEncryptionState() !=
-                    IMountService.ENCRYPTION_STATE_NONE);
-            if (isEncrypted) {
-                if (DEBUG) {
-                    Slog.i(TAG, "Device encrypted; verifying against device data pw");
-                }
-                // 0 means the password validated
-                // -2 means device not encrypted
-                // Any other result is either password failure or an error condition,
-                // so we refuse the match
-                final int result = mMountService.verifyEncryptionPassword(candidatePw);
-                if (result == 0) {
-                    if (MORE_DEBUG) Slog.d(TAG, "Pw verifies");
-                    return true;
-                } else if (result != -2) {
-                    if (MORE_DEBUG) Slog.d(TAG, "Pw mismatch");
-                    return false;
-                } else {
-                    // ...else the device is supposedly not encrypted.  HOWEVER, the
-                    // query about the encryption state said that the device *is*
-                    // encrypted, so ... we may have a problem.  Log it and refuse
-                    // the backup.
-                    Slog.e(TAG, "verified encryption state mismatch against query; no match allowed");
-                    return false;
-                }
-            }
-        } catch (Exception e) {
-            // Something went wrong talking to the mount service.  This is very bad;
-            // assume that we fail password validation.
-            return false;
-        }
-
         if (mPasswordHash == null) {
             // no current password case -- require that 'currentPw' be null or empty
             if (candidatePw == null || "".equals(candidatePw)) {
@@ -1591,14 +1537,7 @@
         mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BACKUP,
                 "hasBackupPassword");
 
-        try {
-            return (mMountService.getEncryptionState() != IMountService.ENCRYPTION_STATE_NONE)
-                || (mPasswordHash != null && mPasswordHash.length() > 0);
-        } catch (Exception e) {
-            // If we can't talk to the mount service we have a serious problem; fail
-            // "secure" i.e. assuming that we require a password
-            return true;
-        }
+        return mPasswordHash != null && mPasswordHash.length() > 0;
     }
 
     private boolean backupPasswordMatches(String currentPw) {
@@ -1750,10 +1689,12 @@
             String action = intent.getAction();
             boolean replacing = false;
             boolean added = false;
+            boolean changed = false;
             Bundle extras = intent.getExtras();
             String pkgList[] = null;
             if (Intent.ACTION_PACKAGE_ADDED.equals(action) ||
-                    Intent.ACTION_PACKAGE_REMOVED.equals(action)) {
+                    Intent.ACTION_PACKAGE_REMOVED.equals(action) ||
+                    Intent.ACTION_PACKAGE_CHANGED.equals(action)) {
                 Uri uri = intent.getData();
                 if (uri == null) {
                     return;
@@ -1762,6 +1703,42 @@
                 if (pkgName != null) {
                     pkgList = new String[] { pkgName };
                 }
+                changed = Intent.ACTION_PACKAGE_CHANGED.equals(action);
+
+                // At package-changed we only care about looking at new transport states
+                if (changed) {
+                    try {
+                        if (MORE_DEBUG) {
+                            Slog.i(TAG, "Package " + pkgName + " changed; rechecking");
+                        }
+                        // unbind existing possibly-stale connections to that package's transports
+                        synchronized (mTransports) {
+                            TransportConnection conn = mTransportConnections.get(pkgName);
+                            if (conn != null) {
+                                final ServiceInfo svc = conn.mTransport;
+                                ComponentName svcName =
+                                        new ComponentName(svc.packageName, svc.name);
+                                String flatName = svcName.flattenToShortString();
+                                Slog.i(TAG, "Unbinding " + svcName);
+
+                                mContext.unbindService(conn);
+                                mTransportConnections.remove(pkgName);
+                                mTransports.remove(mTransportNames.get(flatName));
+                                mTransportNames.remove(flatName);
+                            }
+                        }
+                        // and then (re)bind as appropriate
+                        PackageInfo app = mPackageManager.getPackageInfo(pkgName, 0);
+                        checkForTransportAndBind(app);
+                    } catch (NameNotFoundException e) {
+                        // Nope, can't find it - just ignore
+                        if (MORE_DEBUG) {
+                            Slog.w(TAG, "Can't find changed package " + pkgName);
+                        }
+                    }
+                    return; // nothing more to do in the PACKAGE_CHANGED case
+                }
+
                 added = Intent.ACTION_PACKAGE_ADDED.equals(action);
                 replacing = extras.getBoolean(Intent.EXTRA_REPLACING, false);
             } else if (Intent.ACTION_EXTERNAL_APPLICATIONS_AVAILABLE.equals(action)) {
@@ -1795,6 +1772,21 @@
                             enqueueFullBackup(packageName, now);
                             scheduleNextFullBackupJob();
                         }
+
+                        // Transport maintenance: rebind to known existing transports that have
+                        // just been updated; and bind to any newly-installed transport services.
+                        synchronized (mTransports) {
+                            final TransportConnection conn = mTransportConnections.get(packageName);
+                            if (conn != null) {
+                                if (MORE_DEBUG) {
+                                    Slog.i(TAG, "Transport package changed; rebinding");
+                                }
+                                bindTransport(conn.mTransport);
+                            } else {
+                                checkForTransportAndBind(app);
+                            }
+                        }
+
                     } catch (NameNotFoundException e) {
                         // doesn't really exist; ignore it
                         if (DEBUG) {
@@ -1802,6 +1794,7 @@
                         }
                     }
                 }
+
             } else {
                 if (replacing) {
                     // The package is being updated.  We'll receive a PACKAGE_ADDED shortly.
@@ -1816,6 +1809,12 @@
 
     // ----- Track connection to transports service -----
     class TransportConnection implements ServiceConnection {
+        ServiceInfo mTransport;
+
+        public TransportConnection(ServiceInfo transport) {
+            mTransport = transport;
+        }
+
         @Override
         public void onServiceConnected(ComponentName component, IBinder service) {
             if (DEBUG) Slog.v(TAG, "Connected to transport " + component);
@@ -1839,6 +1838,61 @@
         }
     };
 
+    // Check whether the given package hosts a transport, and bind if so
+    void checkForTransportAndBind(PackageInfo pkgInfo) {
+        Intent intent = new Intent(mTransportServiceIntent)
+                .setPackage(pkgInfo.packageName);
+        List<ResolveInfo> hosts = mPackageManager.queryIntentServicesAsUser(
+                intent, 0, UserHandle.USER_OWNER);
+        final int N = hosts.size();
+        for (int i = 0; i < N; i++) {
+            final ServiceInfo info = hosts.get(i).serviceInfo;
+            tryBindTransport(info);
+        }
+    }
+
+    // Verify that the service exists and is hosted by a privileged app, then proceed to bind
+    boolean tryBindTransport(ServiceInfo info) {
+        try {
+            PackageInfo packInfo = mPackageManager.getPackageInfo(info.packageName, 0);
+            if ((packInfo.applicationInfo.flags & ApplicationInfo.FLAG_PRIVILEGED) != 0) {
+                return bindTransport(info);
+            } else {
+                Slog.w(TAG, "Transport package " + info.packageName + " not privileged");
+            }
+        } catch (NameNotFoundException e) {
+            Slog.w(TAG, "Problem resolving transport package " + info.packageName);
+        }
+        return false;
+    }
+
+    // Actually bind; presumes that we have already validated the transport service
+    boolean bindTransport(ServiceInfo transport) {
+        ComponentName svcName = new ComponentName(transport.packageName, transport.name);
+        if (DEBUG) {
+            Slog.i(TAG, "Binding to transport host " + svcName);
+        }
+        Intent intent = new Intent(mTransportServiceIntent);
+        intent.setComponent(svcName);
+
+        TransportConnection connection;
+        synchronized (mTransports) {
+            connection = mTransportConnections.get(transport.packageName);
+            if (null == connection) {
+                connection = new TransportConnection(transport);
+                mTransportConnections.put(transport.packageName, connection);
+            } else {
+                // This is a rebind due to package upgrade.  The service won't be
+                // automatically relaunched for us until we explicitly rebind, but
+                // we need to unbind the now-orphaned original connection.
+                mContext.unbindService(connection);
+            }
+        }
+        return mContext.bindServiceAsUser(intent,
+                connection, Context.BIND_AUTO_CREATE,
+                UserHandle.OWNER);
+    }
+
     // Add the backup agents in the given packages to our set of known backup participants.
     // If 'packageNames' is null, adds all backup agents in the whole system.
     void addPackageParticipantsLocked(String[] packageNames) {
@@ -1945,8 +1999,9 @@
         return packages;
     }
 
-    // Called from the backup task: record that the given app has been successfully
-    // backed up at least once
+    // Called from the backup tasks: record that the given app has been successfully
+    // backed up at least once.  This includes both key/value and full-data backups
+    // through the transport.
     void logBackupComplete(String packageName) {
         if (packageName.equals(PACKAGE_MANAGER_SENTINEL)) return;
 
@@ -3281,6 +3336,20 @@
         }
     }
 
+    boolean deviceIsEncrypted() {
+        try {
+            return mMountService.getEncryptionState()
+                     != IMountService.ENCRYPTION_STATE_NONE
+                && mMountService.getPasswordType()
+                     != StorageManager.CRYPT_TYPE_DEFAULT;
+        } catch (Exception e) {
+            // If we can't talk to the mount service we have a serious problem; fail
+            // "secure" i.e. assuming that the device is encrypted.
+            Slog.e(TAG, "Unable to communicate with mount service: " + e.getMessage());
+            return true;
+        }
+    }
+
     // Full backup task variant used for adb backup
     class PerformAdbBackupTask extends FullBackupTask {
         FullBackupEngine mBackupEngine;
@@ -3298,7 +3367,7 @@
         ArrayList<String> mPackages;
         String mCurrentPassword;
         String mEncryptPassword;
-        
+
         PerformAdbBackupTask(ParcelFileDescriptor fd, IFullBackupRestoreObserver observer, 
                 boolean includeApks, boolean includeObbs, boolean includeShared,
                 boolean doWidgets, String curPassword, String encryptPassword, boolean doAllApps,
@@ -3495,6 +3564,13 @@
             PackageInfo pkg = null;
             try {
                 boolean encrypting = (mEncryptPassword != null && mEncryptPassword.length() > 0);
+
+                // Only allow encrypted backups of encrypted devices
+                if (deviceIsEncrypted() && !encrypting) {
+                    Slog.e(TAG, "Unencrypted backup of encrypted device; aborting");
+                    return;
+                }
+
                 OutputStream finalOutput = ofstream;
 
                 // Verify that the given password matches the currently-active
@@ -3798,6 +3874,7 @@
                         // Success!
                         EventLog.writeEvent(EventLogTags.FULL_BACKUP_SUCCESS,
                                 currentPackage.packageName);
+                        logBackupComplete(currentPackage.packageName);
                     }
                     cleanUpPipes(transportPipes);
                     cleanUpPipes(enginePipes);
@@ -7538,6 +7615,9 @@
                 }
             }
 
+            // Clear any ongoing session timeout.
+            mBackupHandler.removeMessages(MSG_RESTORE_TIMEOUT);
+
             // If we have a PM token, we must under all circumstances be sure to
             // handshake when we've finished.
             if (mPmToken > 0) {
@@ -7545,6 +7625,11 @@
                 try {
                     mPackageManagerBinder.finishPackageInstall(mPmToken);
                 } catch (RemoteException e) { /* can't happen */ }
+            } else {
+                // We were invoked via an active restore session, not by the Package
+                // Manager, so start up the session timeout again.
+                mBackupHandler.sendEmptyMessageDelayed(MSG_RESTORE_TIMEOUT,
+                        TIMEOUT_RESTORE_INTERVAL);
             }
 
             // Kick off any work that may be needed regarding app widget restores
@@ -7558,11 +7643,6 @@
                 writeRestoreTokens();
             }
 
-            // Furthermore we need to reset the session timeout clock
-            mBackupHandler.removeMessages(MSG_RESTORE_TIMEOUT);
-            mBackupHandler.sendEmptyMessageDelayed(MSG_RESTORE_TIMEOUT,
-                    TIMEOUT_RESTORE_INTERVAL);
-
             // done; we can finally release the wakelock and be legitimately done.
             Slog.i(TAG, "Restore complete.");
             mWakelock.release();
@@ -8272,17 +8352,7 @@
                         params.observer = observer;
                         params.curPassword = curPassword;
 
-                        boolean isEncrypted;
-                        try {
-                            isEncrypted = (mMountService.getEncryptionState() !=
-                                    IMountService.ENCRYPTION_STATE_NONE);
-                            if (isEncrypted) Slog.w(TAG, "Device is encrypted; forcing enc password");
-                        } catch (RemoteException e) {
-                            // couldn't contact the mount service; fail "safe" and assume encryption
-                            Slog.e(TAG, "Unable to contact mount service!");
-                            isEncrypted = true;
-                        }
-                        params.encryptPassword = (isEncrypted) ? curPassword : encPpassword;
+                        params.encryptPassword = encPpassword;
 
                         if (DEBUG) Slog.d(TAG, "Sending conf message with verb " + verb);
                         mWakelock.acquire();
@@ -8361,10 +8431,15 @@
 
         Slog.i(TAG, "Auto restore => " + doAutoRestore);
 
-        synchronized (this) {
-            Settings.Secure.putInt(mContext.getContentResolver(),
-                    Settings.Secure.BACKUP_AUTO_RESTORE, doAutoRestore ? 1 : 0);
-            mAutoRestore = doAutoRestore;
+        final long oldId = Binder.clearCallingIdentity();
+        try {
+            synchronized (this) {
+                Settings.Secure.putInt(mContext.getContentResolver(),
+                        Settings.Secure.BACKUP_AUTO_RESTORE, doAutoRestore ? 1 : 0);
+                mAutoRestore = doAutoRestore;
+            }
+        } finally {
+            Binder.restoreCallingIdentity(oldId);
         }
     }
 
@@ -8423,25 +8498,24 @@
         return list;
     }
 
-    // Select which transport to use for the next backup operation.  If the given
-    // name is not one of the available transports, no action is taken and the method
-    // returns null.
+    // Select which transport to use for the next backup operation.
     public String selectBackupTransport(String transport) {
-        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BACKUP, "selectBackupTransport");
+        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BACKUP,
+                "selectBackupTransport");
 
         synchronized (mTransports) {
-            String prevTransport = null;
-            if (mTransports.get(transport) != null) {
-                prevTransport = mCurrentTransport;
+            final long oldId = Binder.clearCallingIdentity();
+            try {
+                String prevTransport = mCurrentTransport;
                 mCurrentTransport = transport;
                 Settings.Secure.putString(mContext.getContentResolver(),
                         Settings.Secure.BACKUP_TRANSPORT, transport);
                 Slog.v(TAG, "selectBackupTransport() set " + mCurrentTransport
                         + " returning " + prevTransport);
-            } else {
-                Slog.w(TAG, "Attempt to select unavailable transport " + transport);
+                return prevTransport;
+            } finally {
+                Binder.restoreCallingIdentity(oldId);
             }
-            return prevTransport;
         }
     }
 
@@ -8599,10 +8673,9 @@
             skip = true;
         }
 
-        if (!mAutoRestore || !mProvisioned) {
+        if (!mAutoRestore) {
             if (DEBUG) {
-                Slog.w(TAG, "Non-restorable state: auto=" + mAutoRestore
-                        + " prov=" + mProvisioned);
+                Slog.w(TAG, "Non-restorable state: auto=" + mAutoRestore);
             }
             skip = true;
         }
@@ -8734,12 +8807,17 @@
         private IBackupTransport mRestoreTransport = null;
         RestoreSet[] mRestoreSets = null;
         boolean mEnded = false;
+        boolean mTimedOut = false;
 
         ActiveRestoreSession(String packageName, String transport) {
             mPackageName = packageName;
             mRestoreTransport = getTransport(transport);
         }
 
+        public void markTimedOut() {
+            mTimedOut = true;
+        }
+
         // --- Binder interface ---
         public synchronized int getAvailableRestoreSets(IRestoreObserver observer) {
             mContext.enforceCallingOrSelfPermission(android.Manifest.permission.BACKUP,
@@ -8752,6 +8830,11 @@
                 throw new IllegalStateException("Restore session already ended");
             }
 
+            if (mTimedOut) {
+                Slog.i(TAG, "Session already timed out");
+                return -1;
+            }
+
             long oldId = Binder.clearCallingIdentity();
             try {
                 if (mRestoreTransport == null) {
@@ -8783,6 +8866,11 @@
                 throw new IllegalStateException("Restore session already ended");
             }
 
+            if (mTimedOut) {
+                Slog.i(TAG, "Session already timed out");
+                return -1;
+            }
+
             if (mRestoreTransport == null || mRestoreSets == null) {
                 Slog.e(TAG, "Ignoring restoreAll() with no restore set");
                 return -1;
@@ -8857,6 +8945,11 @@
                 throw new IllegalStateException("Restore session already ended");
             }
 
+            if (mTimedOut) {
+                Slog.i(TAG, "Session already timed out");
+                return -1;
+            }
+
             if (mRestoreTransport == null || mRestoreSets == null) {
                 Slog.e(TAG, "Ignoring restoreAll() with no restore set");
                 return -1;
@@ -8905,6 +8998,11 @@
                 throw new IllegalStateException("Restore session already ended");
             }
 
+            if (mTimedOut) {
+                Slog.i(TAG, "Session already timed out");
+                return -1;
+            }
+
             if (mPackageName != null) {
                 if (! mPackageName.equals(packageName)) {
                     Slog.e(TAG, "Ignoring attempt to restore pkg=" + packageName
@@ -9002,6 +9100,11 @@
         public synchronized void endRestoreSession() {
             if (DEBUG) Slog.d(TAG, "endRestoreSession");
 
+            if (mTimedOut) {
+                Slog.i(TAG, "Session already timed out");
+                return;
+            }
+
             if (mEnded) {
                 throw new IllegalStateException("Restore session already ended");
             }
@@ -9057,19 +9160,22 @@
             pw.println("  next scheduled: " + mNextBackupPass);
 
             pw.println("Available transports:");
-            for (String t : listAllTransports()) {
-                pw.println((t.equals(mCurrentTransport) ? "  * " : "    ") + t);
-                try {
-                    IBackupTransport transport = getTransport(t);
-                    File dir = new File(mBaseStateDir, transport.transportDirName());
-                    pw.println("       destination: " + transport.currentDestinationString());
-                    pw.println("       intent: " + transport.configurationIntent());
-                    for (File f : dir.listFiles()) {
-                        pw.println("       " + f.getName() + " - " + f.length() + " state bytes");
+            final String[] transports = listAllTransports();
+            if (transports != null) {
+                for (String t : listAllTransports()) {
+                    pw.println((t.equals(mCurrentTransport) ? "  * " : "    ") + t);
+                    try {
+                        IBackupTransport transport = getTransport(t);
+                        File dir = new File(mBaseStateDir, transport.transportDirName());
+                        pw.println("       destination: " + transport.currentDestinationString());
+                        pw.println("       intent: " + transport.configurationIntent());
+                        for (File f : dir.listFiles()) {
+                            pw.println("       " + f.getName() + " - " + f.length() + " state bytes");
+                        }
+                    } catch (Exception e) {
+                        Slog.e(TAG, "Error in transport", e);
+                        pw.println("        Error: " + e);
                     }
-                } catch (Exception e) {
-                    Slog.e(TAG, "Error in transport", e);
-                    pw.println("        Error: " + e);
                 }
             }
 
diff --git a/services/backup/java/com/android/server/backup/FullBackupJob.java b/services/backup/java/com/android/server/backup/FullBackupJob.java
index deb2293..601f15e 100644
--- a/services/backup/java/com/android/server/backup/FullBackupJob.java
+++ b/services/backup/java/com/android/server/backup/FullBackupJob.java
@@ -20,10 +20,8 @@
 import android.app.job.JobParameters;
 import android.app.job.JobScheduler;
 import android.app.job.JobService;
-import android.app.job.JobInfo.NetworkType;
 import android.content.ComponentName;
 import android.content.Context;
-import android.util.Slog;
 
 public class FullBackupJob extends JobService {
     private static final String TAG = "FullBackupJob";
@@ -40,7 +38,7 @@
         JobScheduler js = (JobScheduler) ctx.getSystemService(Context.JOB_SCHEDULER_SERVICE);
         JobInfo.Builder builder = new JobInfo.Builder(JOB_ID, sIdleService)
                 .setRequiresDeviceIdle(true)
-                .setRequiredNetworkCapabilities(NetworkType.UNMETERED)
+                .setRequiredNetworkType(JobInfo.NETWORK_TYPE_UNMETERED)
                 .setRequiresCharging(true);
         if (minDelay > 0) {
             builder.setMinimumLatency(minDelay);
diff --git a/services/core/java/com/android/server/AlarmManagerService.java b/services/core/java/com/android/server/AlarmManagerService.java
index e9419ad..7716385 100644
--- a/services/core/java/com/android/server/AlarmManagerService.java
+++ b/services/core/java/com/android/server/AlarmManagerService.java
@@ -127,6 +127,7 @@
     long mLastAlarmDeliveryTime;
     long mStartCurrentDelayTime;
     long mNextNonWakeupDeliveryTime;
+    int mNumTimeChanged;
 
     private final SparseArray<AlarmManager.AlarmClockInfo> mNextAlarmClockForUser =
             new SparseArray<>();
@@ -821,6 +822,7 @@
                     pw.print(" = "); pw.println(sdf.format(new Date(nextNonWakeupRTC)));
             pw.print("Next wakeup: "); TimeUtils.formatDuration(mNextWakeup, nowELAPSED, pw);
                     pw.print(" = "); pw.println(sdf.format(new Date(nextWakeupRTC)));
+            pw.print("Num time change events: "); pw.println(mNumTimeChanged);
 
             if (mAlarmBatches.size() > 0) {
                 pw.println();
@@ -1535,7 +1537,7 @@
         for (int i=0; i<triggerList.size(); i++) {
             Alarm alarm = triggerList.get(i);
             try {
-                if (localLOGV) Slog.v(TAG, "sending alarm " + alarm);
+                Slog.v(TAG, "sending alarm " + alarm);
                 alarm.operation.send(getContext(), 0,
                         mBackgroundIntent.putExtra(
                                 Intent.EXTRA_ALARM_COUNT, alarm.count),
@@ -1619,6 +1621,9 @@
                     removeImpl(mTimeTickSender);
                     rebatchAllAlarms();
                     mClockReceiver.scheduleTimeTickEvent();
+                    synchronized (mLock) {
+                        mNumTimeChanged++;
+                    }
                     Intent intent = new Intent(Intent.ACTION_TIME_CHANGED);
                     intent.addFlags(Intent.FLAG_RECEIVER_REPLACE_PENDING
                             | Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
diff --git a/services/core/java/com/android/server/AppOpsService.java b/services/core/java/com/android/server/AppOpsService.java
index ef6e07c..c3465d1 100644
--- a/services/core/java/com/android/server/AppOpsService.java
+++ b/services/core/java/com/android/server/AppOpsService.java
@@ -631,7 +631,7 @@
     @Override
     public int checkPackage(int uid, String packageName) {
         synchronized (this) {
-            if (getOpsLocked(uid, packageName, true) != null) {
+            if (getOpsRawLocked(uid, packageName, true) != null) {
                 return AppOpsManager.MODE_ALLOWED;
             } else {
                 return AppOpsManager.MODE_ERRORED;
@@ -769,6 +769,15 @@
     }
 
     private Ops getOpsLocked(int uid, String packageName, boolean edit) {
+        if (uid == 0) {
+            packageName = "root";
+        } else if (uid == Process.SHELL_UID) {
+            packageName = "com.android.shell";
+        }
+        return getOpsRawLocked(uid, packageName, edit);
+    }
+
+    private Ops getOpsRawLocked(int uid, String packageName, boolean edit) {
         HashMap<String, Ops> pkgOps = mUidOps.get(uid);
         if (pkgOps == null) {
             if (!edit) {
@@ -777,11 +786,6 @@
             pkgOps = new HashMap<String, Ops>();
             mUidOps.put(uid, pkgOps);
         }
-        if (uid == 0) {
-            packageName = "root";
-        } else if (uid == Process.SHELL_UID) {
-            packageName = "com.android.shell";
-        }
         Ops ops = pkgOps.get(packageName);
         if (ops == null) {
             if (!edit) {
diff --git a/services/core/java/com/android/server/BluetoothManagerService.java b/services/core/java/com/android/server/BluetoothManagerService.java
index 07c9048..7b64139 100644
--- a/services/core/java/com/android/server/BluetoothManagerService.java
+++ b/services/core/java/com/android/server/BluetoothManagerService.java
@@ -121,6 +121,7 @@
     private int mState;
     private final BluetoothHandler mHandler;
     private int mErrorRecoveryRetryCounter;
+    private final int mSystemUiUid;
 
     private void registerForAirplaneMode(IntentFilter filter) {
         final ContentResolver resolver = mContext.getContentResolver();
@@ -218,6 +219,15 @@
         if (isBluetoothPersistedStateOn()) {
             mEnableExternal = true;
         }
+
+        int sysUiUid = -1;
+        try {
+            sysUiUid = mContext.getPackageManager().getPackageUid("com.android.systemui",
+                    UserHandle.USER_OWNER);
+        } catch (PackageManager.NameNotFoundException e) {
+            Log.wtf(TAG, "Unable to resolve SystemUI's UID.", e);
+        }
+        mSystemUiUid = sysUiUid;
     }
 
     /**
@@ -1118,7 +1128,8 @@
         try {
             foregroundUser = ActivityManager.getCurrentUser();
             valid = (callingUser == foregroundUser) ||
-                    callingAppId == Process.NFC_UID;
+                    callingAppId == Process.NFC_UID ||
+                    callingAppId == mSystemUiUid;
             if (DBG) {
                 Log.d(TAG, "checkIfCallerIsForegroundUser: valid=" + valid
                     + " callingUser=" + callingUser
diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java
index 5bef4bf..967681b 100644
--- a/services/core/java/com/android/server/ConnectivityService.java
+++ b/services/core/java/com/android/server/ConnectivityService.java
@@ -185,7 +185,7 @@
     private static final String TAG = "ConnectivityService";
 
     private static final boolean DBG = true;
-    private static final boolean VDBG = true; // STOPSHIP
+    private static final boolean VDBG = false;
 
     // network sampling debugging
     private static final boolean SAMPLE_DBG = false;
@@ -251,7 +251,7 @@
 
     private Context mContext;
     private int mNetworkPreference;
-    private int mActiveDefaultNetwork = -1;
+    private int mActiveDefaultNetwork = TYPE_NONE;
     // 0 is full bad, 100 is full good
     private int mDefaultInetConditionPublished = 0;
 
@@ -425,8 +425,8 @@
 
     TelephonyManager mTelephonyManager;
 
-    // sequence number for Networks
-    private final static int MIN_NET_ID = 10; // some reserved marks
+    // sequence number for Networks; keep in sync with system/netd/NetworkController.cpp
+    private final static int MIN_NET_ID = 100; // some reserved marks
     private final static int MAX_NET_ID = 65535;
     private int mNextNetId = MIN_NET_ID;
 
@@ -756,10 +756,20 @@
         return mNextNetworkRequestId++;
     }
 
-    private synchronized int nextNetId() {
-        int netId = mNextNetId;
-        if (++mNextNetId > MAX_NET_ID) mNextNetId = MIN_NET_ID;
-        return netId;
+    private void assignNextNetId(NetworkAgentInfo nai) {
+        synchronized (mNetworkForNetId) {
+            for (int i = MIN_NET_ID; i <= MAX_NET_ID; i++) {
+                int netId = mNextNetId;
+                if (++mNextNetId > MAX_NET_ID) mNextNetId = MIN_NET_ID;
+                // Make sure NetID unused.  http://b/16815182
+                if (mNetworkForNetId.get(netId) == null) {
+                    nai.network = new Network(netId);
+                    mNetworkForNetId.put(netId, nai);
+                    return;
+                }
+            }
+        }
+        throw new IllegalStateException("No free netIds");
     }
 
     private int getConnectivityChangeDelay() {
@@ -783,14 +793,28 @@
     }
 
     /**
-     * Check if UID should be blocked from using the network represented by the
-     * given {@link NetworkStateTracker}.
+     * Check if UID should be blocked from using the network represented by the given networkType.
+     * @deprecated Uses mLegacyTypeTracker; cannot deal with multiple Networks of the same type.
      */
     private boolean isNetworkBlocked(int networkType, int uid) {
+        return isNetworkWithLinkPropertiesBlocked(getLinkPropertiesForType(networkType), uid);
+    }
+
+    /**
+     * Check if UID should be blocked from using the network represented by the given
+     * NetworkAgentInfo.
+     */
+    private boolean isNetworkBlocked(NetworkAgentInfo nai, int uid) {
+        return isNetworkWithLinkPropertiesBlocked(nai.linkProperties, uid);
+    }
+
+    /**
+     * Check if UID should be blocked from using the network with the given LinkProperties.
+     */
+    private boolean isNetworkWithLinkPropertiesBlocked(LinkProperties lp, int uid) {
         final boolean networkCostly;
         final int uidRules;
 
-        LinkProperties lp = getLinkPropertiesForType(networkType);
         final String iface = (lp == null ? "" : lp.getInterfaceName());
         synchronized (mRulesLock) {
             networkCostly = mMeteredIfaces.contains(iface);
@@ -809,12 +833,16 @@
      * Return a filtered {@link NetworkInfo}, potentially marked
      * {@link DetailedState#BLOCKED} based on
      * {@link #isNetworkBlocked}.
+     * @deprecated Uses mLegacyTypeTracker; cannot deal with multiple Networks of the same type.
      */
     private NetworkInfo getFilteredNetworkInfo(int networkType, int uid) {
         NetworkInfo info = getNetworkInfoForType(networkType);
         return getFilteredNetworkInfo(info, networkType, uid);
     }
 
+    /*
+     * @deprecated Uses mLegacyTypeTracker; cannot deal with multiple Networks of the same type.
+     */
     private NetworkInfo getFilteredNetworkInfo(NetworkInfo info, int networkType, int uid) {
         if (isNetworkBlocked(networkType, uid)) {
             // network is blocked; clone and override state
@@ -829,6 +857,21 @@
         return info;
     }
 
+    private NetworkInfo getFilteredNetworkInfo(NetworkAgentInfo nai, int uid) {
+        NetworkInfo info = nai.networkInfo;
+        if (isNetworkBlocked(nai, uid)) {
+            // network is blocked; clone and override state
+            info = new NetworkInfo(info);
+            info.setDetailedState(DetailedState.BLOCKED, null, null);
+            if (DBG) log("returning Blocked NetworkInfo");
+        }
+        if (mLockdownTracker != null) {
+            info = mLockdownTracker.augmentNetworkInfo(info);
+            if (DBG) log("returning Locked NetworkInfo");
+        }
+        return info;
+    }
+
     /**
      * Return NetworkInfo for the active (i.e., connected) network interface.
      * It is assumed that at most one network is active at a time. If more
@@ -843,15 +886,6 @@
         return getNetworkInfo(mActiveDefaultNetwork, uid);
     }
 
-    // only called when the default request is satisfied
-    private void updateActiveDefaultNetwork(NetworkAgentInfo nai) {
-        if (nai != null) {
-            mActiveDefaultNetwork = nai.networkInfo.getType();
-        } else {
-            mActiveDefaultNetwork = TYPE_NONE;
-        }
-    }
-
     /**
      * Find the first Provisioning network.
      *
@@ -936,7 +970,7 @@
         synchronized (nai) {
             if (nai.networkInfo == null) return null;
 
-            return getFilteredNetworkInfo(nai.networkInfo, nai.networkInfo.getType(), uid);
+            return getFilteredNetworkInfo(nai, uid);
         }
     }
 
@@ -957,6 +991,17 @@
     }
 
     @Override
+    public Network getNetworkForType(int networkType) {
+        enforceAccessPermission();
+        final int uid = Binder.getCallingUid();
+        if (isNetworkBlocked(networkType, uid)) {
+            return null;
+        }
+        NetworkAgentInfo nai = mLegacyTypeTracker.getNetworkForType(networkType);
+        return (nai == null) ? null : nai.network;
+    }
+
+    @Override
     public Network[] getAllNetworks() {
         enforceAccessPermission();
         final ArrayList<Network> result = new ArrayList();
@@ -1192,7 +1237,7 @@
                 bestRoute = RouteInfo.makeHostRoute(addr, bestRoute.getGateway(), iface);
             }
         }
-        if (VDBG) log("Adding " + bestRoute + " for interface " + bestRoute.getInterface());
+        if (DBG) log("Adding " + bestRoute + " for interface " + bestRoute.getInterface());
         try {
             mNetd.addLegacyRouteForNetId(netId, bestRoute, uid);
         } catch (Exception e) {
@@ -1294,6 +1339,12 @@
 //        }
     }
 
+    private void enforceInternetPermission() {
+        mContext.enforceCallingOrSelfPermission(
+                android.Manifest.permission.INTERNET,
+                "ConnectivityService");
+    }
+
     private void enforceAccessPermission() {
         mContext.enforceCallingOrSelfPermission(
                 android.Manifest.permission.ACCESS_NETWORK_STATE,
@@ -1306,13 +1357,6 @@
                 "ConnectivityService");
     }
 
-    // TODO Make this a special check when it goes public
-    private void enforceTetherChangePermission() {
-        mContext.enforceCallingOrSelfPermission(
-                android.Manifest.permission.CHANGE_NETWORK_STATE,
-                "ConnectivityService");
-    }
-
     private void enforceTetherAccessPermission() {
         mContext.enforceCallingOrSelfPermission(
                 android.Manifest.permission.ACCESS_NETWORK_STATE,
@@ -1391,7 +1435,7 @@
                 mInitialBroadcast = new Intent(intent);
             }
             intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT);
-            if (VDBG) {
+            if (DBG) {
                 log("sendStickyBroadcast: action=" + intent.getAction());
             }
 
@@ -1548,7 +1592,7 @@
         }
 
         try {
-            if (VDBG) log("Setting MTU size: " + iface + ", " + mtu);
+            if (DBG) log("Setting MTU size: " + iface + ", " + mtu);
             mNetd.setMtu(iface, mtu);
         } catch (Exception e) {
             Slog.e(TAG, "exception in setMtu()" + e);
@@ -1569,7 +1613,7 @@
         }
 
         if (values == null || values.length != 6) {
-            if (VDBG) log("Invalid tcpBufferSizes string: " + tcpBufferSizes +", using defaults");
+            if (DBG) log("Invalid tcpBufferSizes string: " + tcpBufferSizes +", using defaults");
             tcpBufferSizes = DEFAULT_TCP_BUFFER_SIZES;
             values = tcpBufferSizes.split(",");
         }
@@ -1577,7 +1621,7 @@
         if (tcpBufferSizes.equals(mCurrentTcpBufferSizes)) return;
 
         try {
-            if (VDBG) Slog.d(TAG, "Setting tx/rx TCP buffers to " + tcpBufferSizes);
+            if (DBG) Slog.d(TAG, "Setting tx/rx TCP buffers to " + tcpBufferSizes);
 
             final String prefix = "/sys/kernel/ipv4/tcp_";
             FileUtils.stringToFile(prefix + "rmem_min", values[0]);
@@ -1714,7 +1758,7 @@
         pw.println();
 
         synchronized (this) {
-            pw.println("NetworkTranstionWakeLock is currently " +
+            pw.println("NetworkTransitionWakeLock is currently " +
                     (mNetTransitionWakeLock.isHeld() ? "" : "not ") + "held.");
             pw.println("It was last requested for "+mNetTransitionWakeLockCausedBy);
         }
@@ -1733,6 +1777,20 @@
         }
     }
 
+    private boolean isLiveNetworkAgent(NetworkAgentInfo nai, String msg) {
+        if (nai.network == null) return false;
+        final NetworkAgentInfo officialNai;
+        synchronized (mNetworkForNetId) {
+            officialNai = mNetworkForNetId.get(nai.network.netId);
+        }
+        if (officialNai != null && officialNai.equals(nai)) return true;
+        if (officialNai != null || VDBG) {
+            loge(msg + " - isLiveNetworkAgent found mismatched netId: " + officialNai +
+                " - " + nai);
+        }
+        return false;
+    }
+
     // must be stateless - things change under us.
     private class NetworkStateTrackerHandler extends Handler {
         public NetworkStateTrackerHandler(Looper looper) {
@@ -1771,7 +1829,7 @@
                         loge("NetworkAgent not found for EVENT_NETWORK_PROPERTIES_CHANGED");
                     } else {
                         if (VDBG) {
-                            log("Update of Linkproperties for " + nai.name() +
+                            log("Update of LinkProperties for " + nai.name() +
                                     "; created=" + nai.created);
                         }
                         LinkProperties oldLp = nai.linkProperties;
@@ -1860,21 +1918,48 @@
                     }
                     break;
                 }
-                case NetworkMonitor.EVENT_NETWORK_VALIDATED: {
+                case NetworkAgent.EVENT_SET_EXPLICITLY_SELECTED: {
+                    NetworkAgentInfo nai = mNetworkAgentInfos.get(msg.replyTo);
+                    if (nai == null) {
+                        loge("EVENT_SET_EXPLICITLY_SELECTED from unknown NetworkAgent");
+                        break;
+                    }
+                    nai.networkMisc.explicitlySelected = true;
+                    break;
+                }
+                case NetworkMonitor.EVENT_NETWORK_TESTED: {
                     NetworkAgentInfo nai = (NetworkAgentInfo)msg.obj;
-                    handleConnectionValidated(nai);
+                    if (isLiveNetworkAgent(nai, "EVENT_NETWORK_VALIDATED")) {
+                        boolean valid = (msg.arg1 == NetworkMonitor.NETWORK_TEST_RESULT_VALID);
+                        if (valid) {
+                            if (DBG) log("Validated " + nai.name());
+                            nai.validated = true;
+                            rematchNetworkAndRequests(nai);
+                        }
+                        updateInetCondition(nai, valid);
+                        // Let the NetworkAgent know the state of its network
+                        nai.asyncChannel.sendMessage(
+                                android.net.NetworkAgent.CMD_REPORT_NETWORK_STATUS,
+                                (valid ? NetworkAgent.VALID_NETWORK : NetworkAgent.INVALID_NETWORK),
+                                0, null);
+                    }
                     break;
                 }
                 case NetworkMonitor.EVENT_NETWORK_LINGER_COMPLETE: {
                     NetworkAgentInfo nai = (NetworkAgentInfo)msg.obj;
-                    handleLingerComplete(nai);
+                    if (isLiveNetworkAgent(nai, "EVENT_NETWORK_LINGER_COMPLETE")) {
+                        handleLingerComplete(nai);
+                    }
                     break;
                 }
                 case NetworkMonitor.EVENT_PROVISIONING_NOTIFICATION: {
                     if (msg.arg1 == 0) {
                         setProvNotificationVisibleIntent(false, msg.arg2, 0, null, null);
                     } else {
-                        NetworkAgentInfo nai = mNetworkForNetId.get(msg.arg2);
+                        NetworkAgentInfo nai = null;
+                        synchronized (mNetworkForNetId) {
+                            nai = mNetworkForNetId.get(msg.arg2);
+                        }
                         if (nai == null) {
                             loge("EVENT_PROVISIONING_NOTIFICATION from unknown NetworkMonitor");
                             break;
@@ -1977,7 +2062,7 @@
                     if (nri.isRequest == false) continue;
                     NetworkAgentInfo nai = mNetworkForRequestId.get(nri.request.requestId);
                     ac.sendMessage(android.net.NetworkFactory.CMD_REQUEST_NETWORK,
-                            (nai != null ? nai.currentScore : 0), 0, nri.request);
+                            (nai != null ? nai.getCurrentScore() : 0), 0, nri.request);
                 }
             } else {
                 loge("Error connecting NetworkFactory");
@@ -2043,11 +2128,10 @@
             for (int i = 0; i < nai.networkRequests.size(); i++) {
                 NetworkRequest request = nai.networkRequests.valueAt(i);
                 NetworkAgentInfo currentNetwork = mNetworkForRequestId.get(request.requestId);
-                if (VDBG) {
-                    log(" checking request " + request + ", currentNetwork = " +
-                            (currentNetwork != null ? currentNetwork.name() : "null"));
-                }
                 if (currentNetwork != null && currentNetwork.network.netId == nai.network.netId) {
+                    if (DBG) {
+                        log("Checking for replacement network to handle request " + request );
+                    }
                     mNetworkForRequestId.remove(request.requestId);
                     sendUpdatedScoreToFactories(request, 0);
                     NetworkAgentInfo alternative = null;
@@ -2057,12 +2141,15 @@
                                 request.networkCapabilities.satisfiedByNetworkCapabilities(
                                 existing.networkCapabilities) &&
                                 (alternative == null ||
-                                 alternative.currentScore < existing.currentScore)) {
+                                 alternative.getCurrentScore() < existing.getCurrentScore())) {
                             alternative = existing;
                         }
                     }
-                    if (alternative != null && !toActivate.contains(alternative)) {
-                        toActivate.add(alternative);
+                    if (alternative != null) {
+                        if (DBG) log(" found replacement in " + alternative.name());
+                        if (!toActivate.contains(alternative)) {
+                            toActivate.add(alternative);
+                        }
                     }
                 }
             }
@@ -2085,17 +2172,26 @@
         // Check for the best currently alive network that satisfies this request
         NetworkAgentInfo bestNetwork = null;
         for (NetworkAgentInfo network : mNetworkAgentInfos.values()) {
-            if (VDBG) log("handleRegisterNetworkRequest checking " + network.name());
+            if (DBG) log("handleRegisterNetworkRequest checking " + network.name());
             if (newCap.satisfiedByNetworkCapabilities(network.networkCapabilities)) {
-                if (VDBG) log("apparently satisfied.  currentScore=" + network.currentScore);
-                if ((bestNetwork == null) || bestNetwork.currentScore < network.currentScore) {
-                    bestNetwork = network;
+                if (DBG) log("apparently satisfied.  currentScore=" + network.getCurrentScore());
+                if ((bestNetwork == null) ||
+                        bestNetwork.getCurrentScore() < network.getCurrentScore()) {
+                    if (!nri.isRequest) {
+                        // Not setting bestNetwork here as a listening NetworkRequest may be
+                        // satisfied by multiple Networks.  Instead the request is added to
+                        // each satisfying Network and notified about each.
+                        network.addRequest(nri.request);
+                        notifyNetworkCallback(network, nri);
+                    } else {
+                        bestNetwork = network;
+                    }
                 }
             }
         }
         if (bestNetwork != null) {
-            if (VDBG) log("using " + bestNetwork.name());
-            if (nri.isRequest && bestNetwork.networkInfo.isConnected()) {
+            if (DBG) log("using " + bestNetwork.name());
+            if (bestNetwork.networkInfo.isConnected()) {
                 // Cancel any lingering so the linger timeout doesn't teardown this network
                 // even though we have a request for it.
                 bestNetwork.networkLingered.clear();
@@ -2104,8 +2200,8 @@
             bestNetwork.addRequest(nri.request);
             mNetworkForRequestId.put(nri.request.requestId, bestNetwork);
             notifyNetworkCallback(bestNetwork, nri);
-            score = bestNetwork.currentScore;
-            if (nri.isRequest && nri.request.legacyType != TYPE_NONE) {
+            score = bestNetwork.getCurrentScore();
+            if (nri.request.legacyType != TYPE_NONE) {
                 mLegacyTypeTracker.add(nri.request.legacyType, bestNetwork);
             }
         }
@@ -2122,48 +2218,60 @@
     private void handleReleaseNetworkRequest(NetworkRequest request, int callingUid) {
         NetworkRequestInfo nri = mNetworkRequests.get(request);
         if (nri != null) {
-            if (nri.mUid != callingUid) {
+            if (Process.SYSTEM_UID != callingUid && nri.mUid != callingUid) {
                 if (DBG) log("Attempt to release unowned NetworkRequest " + request);
                 return;
             }
             if (DBG) log("releasing NetworkRequest " + request);
             nri.unlinkDeathRecipient();
             mNetworkRequests.remove(request);
-            // tell the network currently servicing this that it's no longer interested
-            NetworkAgentInfo affectedNetwork = mNetworkForRequestId.get(nri.request.requestId);
-            if (affectedNetwork != null) {
-                mNetworkForRequestId.remove(nri.request.requestId);
-                affectedNetwork.networkRequests.remove(nri.request.requestId);
-                if (VDBG) {
-                    log(" Removing from current network " + affectedNetwork.name() + ", leaving " +
-                            affectedNetwork.networkRequests.size() + " requests.");
-                }
-                if (nri.isRequest && nri.request.legacyType != TYPE_NONE) {
-                    mLegacyTypeTracker.remove(nri.request.legacyType, affectedNetwork);
-                }
-            }
-
             if (nri.isRequest) {
+                // Find all networks that are satisfying this request and remove the request
+                // from their request lists.
+                for (NetworkAgentInfo nai : mNetworkAgentInfos.values()) {
+                    if (nai.networkRequests.get(nri.request.requestId) != null) {
+                        nai.networkRequests.remove(nri.request.requestId);
+                        if (DBG) {
+                            log(" Removing from current network " + nai.name() +
+                                    ", leaving " + nai.networkRequests.size() +
+                                    " requests.");
+                        }
+                        // check if has any requests remaining and if not,
+                        // disconnect (unless it's a VPN).
+                        boolean keep = nai.isVPN();
+                        for (int i = 0; i < nai.networkRequests.size() && !keep; i++) {
+                            NetworkRequest r = nai.networkRequests.valueAt(i);
+                            if (mNetworkRequests.get(r).isRequest) keep = true;
+                        }
+                        if (!keep) {
+                            if (DBG) log("no live requests for " + nai.name() + "; disconnecting");
+                            nai.asyncChannel.disconnect();
+                        }
+                    }
+                }
+
+                // Maintain the illusion.  When this request arrived, we might have preteneded
+                // that a network connected to serve it, even though the network was already
+                // connected.  Now that this request has gone away, we might have to pretend
+                // that the network disconnected.  LegacyTypeTracker will generate that
+                // phatom disconnect for this type.
+                NetworkAgentInfo nai = mNetworkForRequestId.get(nri.request.requestId);
+                if (nai != null) {
+                    mNetworkForRequestId.remove(nri.request.requestId);
+                    if (nri.request.legacyType != TYPE_NONE) {
+                        mLegacyTypeTracker.remove(nri.request.legacyType, nai);
+                    }
+                }
+
                 for (NetworkFactoryInfo nfi : mNetworkFactoryInfos.values()) {
                     nfi.asyncChannel.sendMessage(android.net.NetworkFactory.CMD_CANCEL_REQUEST,
                             nri.request);
                 }
-
-                if (affectedNetwork != null) {
-                    // check if this network still has live requests - otherwise, tear down
-                    // TODO - probably push this to the NF/NA
-                    boolean keep = affectedNetwork.isVPN();
-                    for (int i = 0; i < affectedNetwork.networkRequests.size() && !keep; i++) {
-                        NetworkRequest r = affectedNetwork.networkRequests.valueAt(i);
-                        if (mNetworkRequests.get(r).isRequest) {
-                            keep = true;
-                        }
-                    }
-                    if (keep == false) {
-                        if (DBG) log("no live requests for " + affectedNetwork.name() +
-                                "; disconnecting");
-                        affectedNetwork.asyncChannel.disconnect();
-                    }
+            } else {
+                // listens don't have a singular affectedNetwork.  Check all networks to see
+                // if this listen request applies and remove it.
+                for (NetworkAgentInfo nai : mNetworkAgentInfos.values()) {
+                    nai.networkRequests.remove(nri.request.requestId);
                 }
             }
             callCallbackForRequest(nri, null, ConnectivityManager.CALLBACK_RELEASED);
@@ -2274,8 +2382,7 @@
 
     // javadoc from interface
     public int tether(String iface) {
-        enforceTetherChangePermission();
-
+        ConnectivityManager.enforceTetherChangePermission(mContext);
         if (isTetheringSupported()) {
             return mTethering.tether(iface);
         } else {
@@ -2285,7 +2392,7 @@
 
     // javadoc from interface
     public int untether(String iface) {
-        enforceTetherChangePermission();
+        ConnectivityManager.enforceTetherChangePermission(mContext);
 
         if (isTetheringSupported()) {
             return mTethering.untether(iface);
@@ -2334,7 +2441,7 @@
     }
 
     public int setUsbTethering(boolean enable) {
-        enforceTetherChangePermission();
+        ConnectivityManager.enforceTetherChangePermission(mContext);
         if (isTetheringSupported()) {
             return mTethering.setUsbTethering(enable);
         } else {
@@ -2405,7 +2512,23 @@
     }
 
     public void reportBadNetwork(Network network) {
-        //TODO
+        enforceAccessPermission();
+        enforceInternetPermission();
+
+        if (network == null) return;
+
+        final int uid = Binder.getCallingUid();
+        NetworkAgentInfo nai = null;
+        synchronized (mNetworkForNetId) {
+            nai = mNetworkForNetId.get(network.netId);
+        }
+        if (nai == null) return;
+        if (DBG) log("reportBadNetwork(" + nai.name() + ") by " + uid);
+        synchronized (nai) {
+            if (isNetworkBlocked(nai, uid)) return;
+
+            nai.networkMonitor.sendMessage(NetworkMonitor.CMD_FORCE_REEVALUATION, uid);
+        }
     }
 
     public ProxyInfo getProxy() {
@@ -2663,6 +2786,20 @@
     }
 
     /**
+     * Set whether the current VPN package has the ability to launch VPNs without
+     * user intervention. This method is used by system UIs and not available
+     * in ConnectivityManager. Permissions are checked in Vpn class.
+     * @hide
+     */
+    @Override
+    public void setVpnPackageAuthorization(boolean authorized) {
+        int user = UserHandle.getUserId(Binder.getCallingUid());
+        synchronized(mVpns) {
+            mVpns.get(user).setPackageAuthorization(authorized);
+        }
+    }
+
+    /**
      * Configure a TUN interface and return its file descriptor. Parameters
      * are encoded and opaque to this class. This method is used by VpnBuilder
      * and not available in ConnectivityManager. Permissions are checked in
@@ -2798,11 +2935,13 @@
         enforceConnectivityInternalPermission();
 
         if (TextUtils.isEmpty(iface)) return ConnectivityManager.TYPE_NONE;
-        for (NetworkStateTracker tracker : mNetTrackers) {
-            if (tracker != null) {
-                LinkProperties lp = tracker.getLinkProperties();
-                if (lp != null && iface.equals(lp.getInterfaceName())) {
-                    return tracker.getNetworkInfo().getType();
+
+        synchronized(mNetworkForNetId) {
+            for (int i = 0; i < mNetworkForNetId.size(); i++) {
+                NetworkAgentInfo nai = mNetworkForNetId.valueAt(i);
+                LinkProperties lp = nai.linkProperties;
+                if (lp != null && iface.equals(lp.getInterfaceName()) && nai.networkInfo != null) {
+                    return nai.networkInfo.getType();
                 }
             }
         }
@@ -3490,10 +3629,13 @@
             mIsProvisioningNetwork.set(false);
             // Check for  apps that can handle provisioning first
             Intent provisioningIntent = new Intent(TelephonyIntents.ACTION_CARRIER_SETUP);
-            provisioningIntent.addCategory(TelephonyIntents.CATEGORY_MCCMNC_PREFIX
-                    + mTelephonyManager.getSimOperator());
-            if (mContext.getPackageManager().resolveActivity(provisioningIntent, 0 /* flags */)
-                    != null) {
+            List<String> carrierPackages =
+                    mTelephonyManager.getCarrierPackageNamesForIntent(provisioningIntent);
+            if (carrierPackages != null && !carrierPackages.isEmpty()) {
+                if (carrierPackages.size() != 1) {
+                    if (DBG) log("Multiple matching carrier apps found, launching the first.");
+                }
+                provisioningIntent.setPackage(carrierPackages.get(0));
                 provisioningIntent.setFlags(Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT |
                         Intent.FLAG_ACTIVITY_NEW_TASK);
                 mContext.startActivity(provisioningIntent);
@@ -3602,6 +3744,8 @@
             notification.icon = icon;
             notification.flags = Notification.FLAG_AUTO_CANCEL;
             notification.tickerText = title;
+            notification.color = mContext.getResources().getColor(
+                    com.android.internal.R.color.system_notification_accent_color);
             notification.setLatestEventInfo(mContext, title, details, notification.contentIntent);
             notification.contentIntent = intent;
 
@@ -3849,7 +3993,7 @@
 
     private void handleNetworkSamplingTimeout() {
 
-        log("Sampling interval elapsed, updating statistics ..");
+        if (SAMPLE_DBG) log("Sampling interval elapsed, updating statistics ..");
 
         // initialize list of interfaces ..
         Map<String, SamplingDataTracker.SamplingSnapshot> mapIfaceToSample =
@@ -3880,13 +4024,15 @@
             }
         }
 
-        log("Done.");
+        if (SAMPLE_DBG) log("Done.");
 
         int samplingIntervalInSeconds = Settings.Global.getInt(mContext.getContentResolver(),
                 Settings.Global.CONNECTIVITY_SAMPLING_INTERVAL_IN_SECONDS,
                 DEFAULT_SAMPLING_INTERVAL_IN_SECONDS);
 
-        if (DBG) log("Setting timer for " + String.valueOf(samplingIntervalInSeconds) + "seconds");
+        if (SAMPLE_DBG) {
+            log("Setting timer for " + String.valueOf(samplingIntervalInSeconds) + "seconds");
+        }
 
         setAlarm(samplingIntervalInSeconds * 1000, mSampleIntervalElapsedIntent);
     }
@@ -4054,7 +4200,7 @@
     }
 
     private void handleRegisterNetworkFactory(NetworkFactoryInfo nfi) {
-        if (VDBG) log("Got NetworkFactory Messenger for " + nfi.name);
+        if (DBG) log("Got NetworkFactory Messenger for " + nfi.name);
         mNetworkFactoryInfos.put(nfi.messenger, nfi);
         nfi.asyncChannel.connect(mContext, mTrackerHandler, nfi.messenger);
     }
@@ -4068,10 +4214,10 @@
     private void handleUnregisterNetworkFactory(Messenger messenger) {
         NetworkFactoryInfo nfi = mNetworkFactoryInfos.remove(messenger);
         if (nfi == null) {
-            if (VDBG) log("Failed to find Messenger in unregisterNetworkFactory");
+            loge("Failed to find Messenger in unregisterNetworkFactory");
             return;
         }
-        if (VDBG) log("unregisterNetworkFactory for " + nfi.name);
+        if (DBG) log("unregisterNetworkFactory for " + nfi.name);
     }
 
     /**
@@ -4102,23 +4248,21 @@
             int currentScore, NetworkMisc networkMisc) {
         enforceConnectivityInternalPermission();
 
-        NetworkAgentInfo nai = new NetworkAgentInfo(messenger, new AsyncChannel(), nextNetId(),
+        NetworkAgentInfo nai = new NetworkAgentInfo(messenger, new AsyncChannel(),
             new NetworkInfo(networkInfo), new LinkProperties(linkProperties),
             new NetworkCapabilities(networkCapabilities), currentScore, mContext, mTrackerHandler,
-            networkMisc);
+            new NetworkMisc(networkMisc));
         synchronized (this) {
             nai.networkMonitor.systemReady = mSystemReady;
         }
-        if (VDBG) log("registerNetworkAgent " + nai);
+        if (DBG) log("registerNetworkAgent " + nai);
         mHandler.sendMessage(mHandler.obtainMessage(EVENT_REGISTER_NETWORK_AGENT, nai));
     }
 
     private void handleRegisterNetworkAgent(NetworkAgentInfo na) {
         if (VDBG) log("Got NetworkAgent Messenger");
         mNetworkAgentInfos.put(na.messenger, na);
-        synchronized (mNetworkForNetId) {
-            mNetworkForNetId.put(na.network.netId, na);
-        }
+        assignNextNetId(na);
         na.asyncChannel.connect(mContext, mTrackerHandler, na.messenger);
         NetworkInfo networkInfo = na.networkInfo;
         na.networkInfo = null;
@@ -4139,6 +4283,7 @@
         final boolean flushDns = updateRoutes(newLp, oldLp, netId);
         updateDnses(newLp, oldLp, netId, flushDns);
         updateClat(newLp, oldLp, networkAgent);
+        if (isDefaultNetwork(networkAgent)) handleApplyDefaultProxy(newLp.getHttpProxy());
     }
 
     private void updateClat(LinkProperties newLp, LinkProperties oldLp, NetworkAgentInfo na) {
@@ -4171,6 +4316,7 @@
         }
         for (String iface : interfaceDiff.added) {
             try {
+                if (DBG) log("Adding iface " + iface + " to network " + netId);
                 mNetd.addInterfaceToNetwork(iface, netId);
             } catch (Exception e) {
                 loge("Exception adding interface: " + e);
@@ -4178,6 +4324,7 @@
         }
         for (String iface : interfaceDiff.removed) {
             try {
+                if (DBG) log("Removing iface " + iface + " from network " + netId);
                 mNetd.removeInterfaceFromNetwork(iface, netId);
             } catch (Exception e) {
                 loge("Exception removing interface: " + e);
@@ -4202,22 +4349,29 @@
         // do this twice, adding non-nexthop routes first, then routes they are dependent on
         for (RouteInfo route : routeDiff.added) {
             if (route.hasGateway()) continue;
+            if (DBG) log("Adding Route [" + route + "] to network " + netId);
             try {
                 mNetd.addRoute(netId, route);
             } catch (Exception e) {
-                loge("Exception in addRoute for non-gateway: " + e);
+                if ((route.getDestination().getAddress() instanceof Inet4Address) || VDBG) {
+                    loge("Exception in addRoute for non-gateway: " + e);
+                }
             }
         }
         for (RouteInfo route : routeDiff.added) {
             if (route.hasGateway() == false) continue;
+            if (DBG) log("Adding Route [" + route + "] to network " + netId);
             try {
                 mNetd.addRoute(netId, route);
             } catch (Exception e) {
-                loge("Exception in addRoute for gateway: " + e);
+                if ((route.getGateway() instanceof Inet4Address) || VDBG) {
+                    loge("Exception in addRoute for gateway: " + e);
+                }
             }
         }
 
         for (RouteInfo route : routeDiff.removed) {
+            if (DBG) log("Removing Route [" + route + "] from network " + netId);
             try {
                 mNetd.removeRoute(netId, route);
             } catch (Exception e) {
@@ -4236,6 +4390,7 @@
                     loge("no dns provided for netId " + netId + ", so using defaults");
                 }
             }
+            if (DBG) log("Setting Dns servers for network " + netId + " to " + dnses);
             try {
                 mNetd.setDnsServersForNetwork(netId, NetworkUtils.makeStrings(dnses),
                     newLp.getDomains());
@@ -4325,7 +4480,10 @@
         msg.obj = o;
         msg.what = notificationType;
         try {
-            if (VDBG) log("sending notification " + notificationType + " for " + nri.request);
+            if (VDBG) {
+                log("sending notification " + notifyTypeToName(notificationType) +
+                        " for " + nri.request);
+            }
             nri.messenger.send(msg);
         } catch (RemoteException e) {
             // may occur naturally in the race of binder death.
@@ -4338,17 +4496,21 @@
             loge("Unknown NetworkAgentInfo in handleLingerComplete");
             return;
         }
-        if (DBG) log("handleLingerComplete for " + oldNetwork.name());
         if (DBG) {
-            if (oldNetwork.networkRequests.size() != 0) {
-                loge("Dead network still had " + oldNetwork.networkRequests.size() + " requests");
+            log("handleLingerComplete for " + oldNetwork.name());
+            for (int i = 0; i < oldNetwork.networkRequests.size(); i++) {
+                NetworkRequest nr = oldNetwork.networkRequests.valueAt(i);
+                // Ignore listening requests.
+                if (mNetworkRequests.get(nr).isRequest == false) continue;
+                loge("Dead network still had at least " + nr);
+                break;
             }
         }
         oldNetwork.asyncChannel.disconnect();
     }
 
     private void makeDefault(NetworkAgentInfo newNetwork) {
-        if (VDBG) log("Switching to new default network: " + newNetwork);
+        if (DBG) log("Switching to new default network: " + newNetwork);
         mActiveDefaultNetwork = newNetwork.networkInfo.getType();
         setupDataActivityTracking(newNetwork);
         try {
@@ -4360,22 +4522,41 @@
         updateTcpBufferSizes(newNetwork);
     }
 
-    private void handleConnectionValidated(NetworkAgentInfo newNetwork) {
-        if (newNetwork == null) {
-            loge("Unknown NetworkAgentInfo in handleConnectionValidated");
-            return;
-        }
+    // Handles a network appearing or improving its score.
+    //
+    // - Evaluates all current NetworkRequests that can be
+    //   satisfied by newNetwork, and reassigns to newNetwork
+    //   any such requests for which newNetwork is the best.
+    //
+    // - Tears down any Networks that as a result are no longer
+    //   needed. A network is needed if it is the best network for
+    //   one or more NetworkRequests, or if it is a VPN.
+    //
+    // - Tears down newNetwork if it is validated but turns out to be
+    //   unneeded. Does not tear down newNetwork if it is
+    //   unvalidated, because future validation may improve
+    //   newNetwork's score enough that it is needed.
+    //
+    // NOTE: This function only adds NetworkRequests that "newNetwork" could satisfy,
+    // it does not remove NetworkRequests that other Networks could better satisfy.
+    // If you need to handle decreases in score, use {@link rematchAllNetworksAndRequests}.
+    // This function should be used when possible instead of {@code rematchAllNetworksAndRequests}
+    // as it performs better by a factor of the number of Networks.
+    private void rematchNetworkAndRequests(NetworkAgentInfo newNetwork) {
         boolean keep = newNetwork.isVPN();
         boolean isNewDefault = false;
-        if (DBG) log("handleConnectionValidated for "+newNetwork.name());
-        // check if any NetworkRequest wants this NetworkAgent
+        if (DBG) log("rematching " + newNetwork.name());
+        // Find and migrate to this Network any NetworkRequests for
+        // which this network is now the best.
         ArrayList<NetworkAgentInfo> affectedNetworks = new ArrayList<NetworkAgentInfo>();
-        if (VDBG) log(" new Network has: " + newNetwork.networkCapabilities);
+        if (VDBG) log(" network has: " + newNetwork.networkCapabilities);
         for (NetworkRequestInfo nri : mNetworkRequests.values()) {
             NetworkAgentInfo currentNetwork = mNetworkForRequestId.get(nri.request.requestId);
             if (newNetwork == currentNetwork) {
-                if (VDBG) log("Network " + newNetwork.name() + " was already satisfying" +
-                              " request " + nri.request.requestId + ". No change.");
+                if (DBG) {
+                    log("Network " + newNetwork.name() + " was already satisfying" +
+                            " request " + nri.request.requestId + ". No change.");
+                }
                 keep = true;
                 continue;
             }
@@ -4384,22 +4565,29 @@
             if (VDBG) log("  checking if request is satisfied: " + nri.request);
             if (nri.request.networkCapabilities.satisfiedByNetworkCapabilities(
                     newNetwork.networkCapabilities)) {
+                if (!nri.isRequest) {
+                    // This is not a request, it's a callback listener.
+                    // Add it to newNetwork regardless of score.
+                    newNetwork.addRequest(nri.request);
+                    continue;
+                }
+
                 // next check if it's better than any current network we're using for
                 // this request
                 if (VDBG) {
                     log("currentScore = " +
-                            (currentNetwork != null ? currentNetwork.currentScore : 0) +
-                            ", newScore = " + newNetwork.currentScore);
+                            (currentNetwork != null ? currentNetwork.getCurrentScore() : 0) +
+                            ", newScore = " + newNetwork.getCurrentScore());
                 }
                 if (currentNetwork == null ||
-                        currentNetwork.currentScore < newNetwork.currentScore) {
+                        currentNetwork.getCurrentScore() < newNetwork.getCurrentScore()) {
                     if (currentNetwork != null) {
-                        if (VDBG) log("   accepting network in place of " + currentNetwork.name());
+                        if (DBG) log("   accepting network in place of " + currentNetwork.name());
                         currentNetwork.networkRequests.remove(nri.request.requestId);
                         currentNetwork.networkLingered.add(nri.request);
                         affectedNetworks.add(currentNetwork);
                     } else {
-                        if (VDBG) log("   accepting network in place of null");
+                        if (DBG) log("   accepting network in place of null");
                     }
                     mNetworkForRequestId.put(nri.request.requestId, newNetwork);
                     newNetwork.addRequest(nri.request);
@@ -4407,13 +4595,16 @@
                         mLegacyTypeTracker.add(nri.request.legacyType, newNetwork);
                     }
                     keep = true;
+                    // Tell NetworkFactories about the new score, so they can stop
+                    // trying to connect if they know they cannot match it.
                     // TODO - this could get expensive if we have alot of requests for this
                     // network.  Think about if there is a way to reduce this.  Push
                     // netid->request mapping to each factory?
-                    sendUpdatedScoreToFactories(nri.request, newNetwork.currentScore);
+                    sendUpdatedScoreToFactories(nri.request, newNetwork.getCurrentScore());
                     if (mDefaultRequest.requestId == nri.request.requestId) {
                         isNewDefault = true;
-                        updateActiveDefaultNetwork(newNetwork);
+                        // TODO: Remove following line.  It's redundant with makeDefault call.
+                        mActiveDefaultNetwork = newNetwork.networkInfo.getType();
                         if (newNetwork.linkProperties != null) {
                             updateTcpBufferSizes(newNetwork);
                             setDefaultDnsSystemProperties(
@@ -4429,12 +4620,13 @@
                             mLegacyTypeTracker.remove(currentNetwork.networkInfo.getType(),
                                                       currentNetwork);
                         }
-                        mDefaultInetConditionPublished = 100;
+                        mDefaultInetConditionPublished = newNetwork.validated ? 100 : 0;
                         mLegacyTypeTracker.add(newNetwork.networkInfo.getType(), newNetwork);
                     }
                 }
             }
         }
+        // Linger any networks that are no longer needed.
         for (NetworkAgentInfo nai : affectedNetworks) {
             boolean teardown = !nai.isVPN();
             for (int i = 0; i < nai.networkRequests.size() && teardown; i++) {
@@ -4462,6 +4654,7 @@
         }
         if (keep) {
             if (isNewDefault) {
+                // Notify system services that this network is up.
                 makeDefault(newNetwork);
                 synchronized (ConnectivityService.this) {
                     // have a new default network, release the transition wakelock in
@@ -4478,6 +4671,7 @@
 
             // Notify battery stats service about this network, both the normal
             // interface and any stacked links.
+            // TODO: Avoid redoing this; this must only be done once when a network comes online.
             try {
                 final IBatteryStats bs = BatteryStatsService.getService();
                 final int type = newNetwork.networkInfo.getType();
@@ -4493,18 +4687,63 @@
             }
 
             notifyNetworkCallbacks(newNetwork, ConnectivityManager.CALLBACK_AVAILABLE);
-        } else {
+        } else if (newNetwork.validated) {
+            // Only tear down validated networks here.  Leave unvalidated to either become
+            // validated (and get evaluated against peers, one losing here) or
+            // NetworkMonitor reports a bad network and we tear it down then.
+            // TODO: Could teardown unvalidated networks when their NetworkCapabilities
+            // satisfy no NetworkRequests.
             if (DBG && newNetwork.networkRequests.size() != 0) {
                 loge("tearing down network with live requests:");
                 for (int i=0; i < newNetwork.networkRequests.size(); i++) {
                     loge("  " + newNetwork.networkRequests.valueAt(i));
                 }
             }
-            if (VDBG) log("Validated network turns out to be unwanted.  Tear it down.");
+            if (DBG) log("Validated network turns out to be unwanted.  Tear it down.");
             newNetwork.asyncChannel.disconnect();
         }
     }
 
+    // Attempt to rematch all Networks with NetworkRequests.  This may result in Networks
+    // being disconnected.
+    // If only one Network's score or capabilities have been modified since the last time
+    // this function was called, pass this Network in via the "changed" arugment, otherwise
+    // pass null.
+    // If only one Network has been changed but its NetworkCapabilities have not changed,
+    // pass in the Network's score (from getCurrentScore()) prior to the change via
+    // "oldScore", otherwise pass changed.getCurrentScore() or 0 if "changed" is null.
+    private void rematchAllNetworksAndRequests(NetworkAgentInfo changed, int oldScore) {
+        // TODO: This may get slow.  The "changed" parameter is provided for future optimization
+        // to avoid the slowness.  It is not simply enough to process just "changed", for
+        // example in the case where "changed"'s score decreases and another network should begin
+        // satifying a NetworkRequest that "changed" currently satisfies.
+
+        // Optimization: Only reprocess "changed" if its score improved.  This is safe because it
+        // can only add more NetworkRequests satisfied by "changed", and this is exactly what
+        // rematchNetworkAndRequests() handles.
+        if (changed != null && oldScore < changed.getCurrentScore()) {
+            rematchNetworkAndRequests(changed);
+        } else {
+            for (NetworkAgentInfo nai : mNetworkAgentInfos.values()) {
+                rematchNetworkAndRequests(nai);
+            }
+        }
+    }
+
+    private void updateInetCondition(NetworkAgentInfo nai, boolean valid) {
+        // Don't bother updating until we've graduated to validated at least once.
+        if (!nai.validated) return;
+        // For now only update icons for default connection.
+        // TODO: Update WiFi and cellular icons separately. b/17237507
+        if (!isDefaultNetwork(nai)) return;
+
+        int newInetCondition = valid ? 100 : 0;
+        // Don't repeat publish.
+        if (newInetCondition == mDefaultInetConditionPublished) return;
+
+        mDefaultInetConditionPublished = newInetCondition;
+        sendInetConditionBroadcast(nai.networkInfo);
+    }
 
     private void updateNetworkInfo(NetworkAgentInfo networkAgent, NetworkInfo newInfo) {
         NetworkInfo.State state = newInfo.getState();
@@ -4559,12 +4798,14 @@
                 }
                 // TODO: support proxy per network.
             }
-            // Make default network if we have no default.  Any network is better than no network.
+            // Consider network even though it is not yet validated.
+            // TODO: All the if-statement conditions can be removed now that validation only confers
+            // a score increase.
             if (mNetworkForRequestId.get(mDefaultRequest.requestId) == null &&
                     networkAgent.isVPN() == false &&
                     mDefaultRequest.networkCapabilities.satisfiedByNetworkCapabilities(
                     networkAgent.networkCapabilities)) {
-                makeDefault(networkAgent);
+                rematchNetworkAndRequests(networkAgent);
             }
         } else if (state == NetworkInfo.State.DISCONNECTED ||
                 state == NetworkInfo.State.SUSPENDED) {
@@ -4584,26 +4825,21 @@
 
     private void updateNetworkScore(NetworkAgentInfo nai, int score) {
         if (DBG) log("updateNetworkScore for " + nai.name() + " to " + score);
+        if (score < 0) {
+            loge("updateNetworkScore for " + nai.name() + " got a negative score (" + score +
+                    ").  Bumping score to min of 0");
+            score = 0;
+        }
 
-        nai.currentScore = score;
+        final int oldScore = nai.getCurrentScore();
+        nai.setCurrentScore(score);
 
-        // TODO - This will not do the right thing if this network is lowering
-        // its score and has requests that can be served by other
-        // currently-active networks, or if the network is increasing its
-        // score and other networks have requests that can be better served
-        // by this network.
-        //
-        // Really we want to see if any of our requests migrate to other
-        // active/lingered networks and if any other requests migrate to us (depending
-        // on increasing/decreasing currentScore.  That's a bit of work and probably our
-        // score checking/network allocation code needs to be modularized so we can understand
-        // (see handleConnectionValided for an example).
-        //
-        // As a first order approx, lets just advertise the new score to factories.  If
-        // somebody can beat it they will nominate a network and our normal net replacement
-        // code will fire.
+        if (nai.created) rematchAllNetworksAndRequests(nai, oldScore);
+
         for (int i = 0; i < nai.networkRequests.size(); i++) {
             NetworkRequest nr = nai.networkRequests.valueAt(i);
+            // Don't send listening requests to factories. b/17393458
+            if (mNetworkRequests.get(nr).isRequest == false) continue;
             sendUpdatedScoreToFactories(nr, score);
         }
     }
@@ -4671,7 +4907,7 @@
     }
 
     protected void notifyNetworkCallbacks(NetworkAgentInfo networkAgent, int notifyType) {
-        if (VDBG) log("notifyType " + notifyType + " for " + networkAgent.name());
+        if (DBG) log("notifyType " + notifyTypeToName(notifyType) + " for " + networkAgent.name());
         for (int i = 0; i < networkAgent.networkRequests.size(); i++) {
             NetworkRequest nr = networkAgent.networkRequests.valueAt(i);
             NetworkRequestInfo nri = mNetworkRequests.get(nr);
@@ -4680,6 +4916,20 @@
         }
     }
 
+    private String notifyTypeToName(int notifyType) {
+        switch (notifyType) {
+            case ConnectivityManager.CALLBACK_PRECHECK:    return "PRECHECK";
+            case ConnectivityManager.CALLBACK_AVAILABLE:   return "AVAILABLE";
+            case ConnectivityManager.CALLBACK_LOSING:      return "LOSING";
+            case ConnectivityManager.CALLBACK_LOST:        return "LOST";
+            case ConnectivityManager.CALLBACK_UNAVAIL:     return "UNAVAILABLE";
+            case ConnectivityManager.CALLBACK_CAP_CHANGED: return "CAP_CHANGED";
+            case ConnectivityManager.CALLBACK_IP_CHANGED:  return "IP_CHANGED";
+            case ConnectivityManager.CALLBACK_RELEASED:    return "RELEASED";
+        }
+        return "UNKNOWN";
+    }
+
     private LinkProperties getLinkPropertiesForTypeInternal(int networkType) {
         NetworkAgentInfo nai = mLegacyTypeTracker.getNetworkForType(networkType);
         if (nai != null) {
@@ -4700,7 +4950,10 @@
             result.setType(networkType);
             return result;
         } else {
-           return new NetworkInfo(networkType, 0, "Unknown", "");
+            NetworkInfo result = new NetworkInfo(
+                    networkType, 0, ConnectivityManager.getNetworkTypeName(networkType), "");
+            result.setDetailedState(NetworkInfo.DetailedState.DISCONNECTED, null, null);
+            return result;
         }
     }
 
diff --git a/services/core/java/com/android/server/InputMethodManagerService.java b/services/core/java/com/android/server/InputMethodManagerService.java
index e0f9b9c..060c8e3 100644
--- a/services/core/java/com/android/server/InputMethodManagerService.java
+++ b/services/core/java/com/android/server/InputMethodManagerService.java
@@ -66,6 +66,7 @@
 import android.content.res.TypedArray;
 import android.database.ContentObserver;
 import android.inputmethodservice.InputMethodService;
+import android.net.Uri;
 import android.os.Binder;
 import android.os.Environment;
 import android.os.Handler;
@@ -105,6 +106,7 @@
 import android.view.inputmethod.InputMethodInfo;
 import android.view.inputmethod.InputMethodManager;
 import android.view.inputmethod.InputMethodSubtype;
+import android.view.inputmethod.InputMethodSubtype.InputMethodSubtypeBuilder;
 import android.widget.ArrayAdapter;
 import android.widget.CompoundButton;
 import android.widget.CompoundButton.OnCheckedChangeListener;
@@ -392,6 +394,7 @@
     private InputMethodInfo[] mIms;
     private int[] mSubtypeIds;
     private Locale mLastSystemLocale;
+    private boolean mShowImeWithHardKeyboard;
     private final MyPackageMonitor mMyPackageMonitor = new MyPackageMonitor();
     private final IPackageManager mIPackageManager;
 
@@ -407,17 +410,25 @@
                     Settings.Secure.ENABLED_INPUT_METHODS), false, this);
             resolver.registerContentObserver(Settings.Secure.getUriFor(
                     Settings.Secure.SELECTED_INPUT_METHOD_SUBTYPE), false, this);
+            resolver.registerContentObserver(Settings.Secure.getUriFor(
+                    Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD), false, this);
         }
 
-        @Override public void onChange(boolean selfChange) {
+        @Override public void onChange(boolean selfChange, Uri uri) {
+            final Uri showImeUri =
+                    Settings.Secure.getUriFor(Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD);
             synchronized (mMethodMap) {
-                boolean enabledChanged = false;
-                String newEnabled = mSettings.getEnabledInputMethodsStr();
-                if (!mLastEnabled.equals(newEnabled)) {
-                    mLastEnabled = newEnabled;
-                    enabledChanged = true;
+                if (showImeUri.equals(uri)) {
+                    updateKeyboardFromSettingsLocked();
+                } else {
+                    boolean enabledChanged = false;
+                    String newEnabled = mSettings.getEnabledInputMethodsStr();
+                    if (!mLastEnabled.equals(newEnabled)) {
+                        mLastEnabled = newEnabled;
+                        enabledChanged = true;
+                    }
+                    updateInputMethodsFromSettingsLocked(enabledChanged);
                 }
-                updateFromSettingsLocked(enabledChanged);
             }
         }
     }
@@ -598,16 +609,14 @@
     private class HardKeyboardListener
             implements WindowManagerService.OnHardKeyboardStatusChangeListener {
         @Override
-        public void onHardKeyboardStatusChange(boolean available, boolean enabled) {
-            mHandler.sendMessage(mHandler.obtainMessage(
-                    MSG_HARD_KEYBOARD_SWITCH_CHANGED, available ? 1 : 0, enabled ? 1 : 0));
+        public void onHardKeyboardStatusChange(boolean available) {
+            mHandler.sendMessage(mHandler.obtainMessage(MSG_HARD_KEYBOARD_SWITCH_CHANGED,
+                        available ? 1 : 0));
         }
 
-        public void handleHardKeyboardStatusChange(boolean available,
-                boolean showImeWithHardKeyboard) {
+        public void handleHardKeyboardStatusChange(boolean available) {
             if (DEBUG) {
-                Slog.w(TAG, "HardKeyboardStatusChanged: available = " + available
-                        + ", showImeWithHardKeyboard= " + showImeWithHardKeyboard);
+                Slog.w(TAG, "HardKeyboardStatusChanged: available=" + available);
             }
             synchronized(mMethodMap) {
                 if (mSwitchingDialog != null && mSwitchingDialogTitleView != null
@@ -1580,6 +1589,8 @@
                     final CharSequence summary = InputMethodUtils.getImeAndSubtypeDisplayName(
                             mContext, imi, mCurrentSubtype);
 
+                    mImeSwitcherNotification.color = mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color);
                     mImeSwitcherNotification.setLatestEventInfo(
                             mContext, title, summary, mImeSwitchPendingIntent);
                     if ((mNotificationManager != null)
@@ -1657,6 +1668,11 @@
     }
 
     void updateFromSettingsLocked(boolean enabledMayChange) {
+        updateInputMethodsFromSettingsLocked(enabledMayChange);
+        updateKeyboardFromSettingsLocked();
+    }
+
+    void updateInputMethodsFromSettingsLocked(boolean enabledMayChange) {
         if (enabledMayChange) {
             List<InputMethodInfo> enabled = mSettings.getEnabledInputMethodListLocked();
             for (int i=0; i<enabled.size(); i++) {
@@ -1710,6 +1726,18 @@
         // TODO: Make sure that mSwitchingController and mSettings are sharing the
         // the same enabled IMEs list.
         mSwitchingController.resetCircularListLocked(mContext);
+
+    }
+
+    public void updateKeyboardFromSettingsLocked() {
+        mShowImeWithHardKeyboard = mSettings.isShowImeWithHardKeyboardEnabled();
+        if (mSwitchingDialog != null
+                && mSwitchingDialogTitleView != null
+                && mSwitchingDialog.isShowing()) {
+            final Switch hardKeySwitch = (Switch)mSwitchingDialogTitleView.findViewById(
+                    com.android.internal.R.id.hard_keyboard_switch);
+            hardKeySwitch.setChecked(mShowImeWithHardKeyboard);
+        }
     }
 
     /* package */ void setInputMethodLocked(String id, int subtypeId) {
@@ -2579,23 +2607,22 @@
                 return true;
             case MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER: {
                 final int sequenceNumber = msg.arg1;
-                final IInputMethodClient client = (IInputMethodClient)msg.obj;
+                final ClientState clientState = (ClientState)msg.obj;
                 try {
-                    client.setUserActionNotificationSequenceNumber(sequenceNumber);
+                    clientState.client.setUserActionNotificationSequenceNumber(sequenceNumber);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Got RemoteException sending "
                             + "setUserActionNotificationSequenceNumber("
                             + sequenceNumber + ") notification to pid "
-                            + ((ClientState)msg.obj).pid + " uid "
-                            + ((ClientState)msg.obj).uid);
+                            + clientState.pid + " uid "
+                            + clientState.uid);
                 }
                 return true;
             }
 
             // --------------------------------------------------------------
             case MSG_HARD_KEYBOARD_SWITCH_CHANGED:
-                mHardKeyboardListener.handleHardKeyboardStatusChange(
-                        msg.arg1 == 1, msg.arg2 == 1);
+                mHardKeyboardListener.handleHardKeyboardStatusChange(msg.arg1 == 1);
                 return true;
         }
         return false;
@@ -2684,7 +2711,7 @@
             if (!map.containsKey(defaultImiId)) {
                 Slog.w(TAG, "Default IME is uninstalled. Choose new default IME.");
                 if (chooseNewDefaultIMELocked()) {
-                    updateFromSettingsLocked(true);
+                    updateInputMethodsFromSettingsLocked(true);
                 }
             } else {
                 // Double check that the default IME is certainly enabled.
@@ -2811,11 +2838,11 @@
                             ? View.VISIBLE : View.GONE);
             final Switch hardKeySwitch = (Switch)mSwitchingDialogTitleView.findViewById(
                     com.android.internal.R.id.hard_keyboard_switch);
-            hardKeySwitch.setChecked(mWindowManagerService.isShowImeWithHardKeyboardEnabled());
+            hardKeySwitch.setChecked(mShowImeWithHardKeyboard);
             hardKeySwitch.setOnCheckedChangeListener(new OnCheckedChangeListener() {
                 @Override
                 public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
-                    mWindowManagerService.setShowImeWithHardKeyboard(isChecked);
+                    mSettings.setShowImeWithHardKeyboard(isChecked);
                     // Ensure that the input method dialog is dismissed when changing
                     // the hardware keyboard state.
                     hideInputMethodMenu();
@@ -3010,7 +3037,7 @@
         if (mCurClient != null && mCurClient.client != null) {
             executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIO(
                     MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER,
-                    mCurUserActionNotificationSequenceNumber, mCurClient.client));
+                    mCurUserActionNotificationSequenceNumber, mCurClient));
         }
 
         // Set Subtype here
@@ -3429,9 +3456,14 @@
                                 parser.getAttributeValue(null, ATTR_IME_SUBTYPE_EXTRA_VALUE);
                         final boolean isAuxiliary = "1".equals(String.valueOf(
                                 parser.getAttributeValue(null, ATTR_IS_AUXILIARY)));
-                        final InputMethodSubtype subtype =
-                                new InputMethodSubtype(label, icon, imeSubtypeLocale,
-                                        imeSubtypeMode, imeSubtypeExtraValue, isAuxiliary);
+                        final InputMethodSubtype subtype = new InputMethodSubtypeBuilder()
+                                .setSubtypeNameResId(label)
+                                .setSubtypeIconResId(icon)
+                                .setSubtypeLocale(imeSubtypeLocale)
+                                .setSubtypeMode(imeSubtypeMode)
+                                .setSubtypeExtraValue(imeSubtypeExtraValue)
+                                .setIsAuxiliary(isAuxiliary)
+                                .build();
                         tempSubtypesArray.add(subtype);
                     }
                 }
diff --git a/services/core/java/com/android/server/LockSettingsService.java b/services/core/java/com/android/server/LockSettingsService.java
index 86ce961..adfbb16 100644
--- a/services/core/java/com/android/server/LockSettingsService.java
+++ b/services/core/java/com/android/server/LockSettingsService.java
@@ -16,9 +16,12 @@
 
 package com.android.server;
 
+import android.content.BroadcastReceiver;
 import android.content.ContentResolver;
 import android.content.ContentValues;
 import android.content.Context;
+import android.content.Intent;
+import android.content.IntentFilter;
 import android.content.pm.PackageManager;
 import android.content.pm.UserInfo;
 
@@ -31,6 +34,7 @@
 import android.os.Binder;
 import android.os.Environment;
 import android.os.IBinder;
+import android.os.Process;
 import android.os.RemoteException;
 import android.os.storage.IMountService;
 import android.os.ServiceManager;
@@ -41,11 +45,14 @@
 import android.provider.Settings;
 import android.provider.Settings.Secure;
 import android.provider.Settings.SettingNotFoundException;
+import android.security.KeyChain;
+import android.security.KeyChain.KeyChainConnection;
 import android.security.KeyStore;
 import android.text.TextUtils;
 import android.util.Log;
 import android.util.Slog;
 
+import com.android.internal.os.BackgroundThread;
 import com.android.internal.widget.ILockSettings;
 import com.android.internal.widget.ILockSettingsObserver;
 import com.android.internal.widget.LockPatternUtils;
@@ -99,8 +106,30 @@
 
         mLockPatternUtils = new LockPatternUtils(context);
         mFirstCallToVold = true;
+
+        IntentFilter filter = new IntentFilter();
+        filter.addAction(Intent.ACTION_USER_ADDED);
+        mContext.registerReceiverAsUser(mBroadcastReceiver, UserHandle.ALL, filter, null, null);
     }
 
+    private final BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
+        @Override
+        public void onReceive(Context context, Intent intent) {
+            // Update keystore settings for profiles which use the same password as their parent
+            if (Intent.ACTION_USER_ADDED.equals(intent.getAction())) {
+                final int userHandle = intent.getIntExtra(Intent.EXTRA_USER_HANDLE, 0);
+                final UserManager um = (UserManager) mContext.getSystemService(USER_SERVICE);
+                final UserInfo parentInfo = um.getProfileParent(userHandle);
+                if (parentInfo != null) {
+                    final KeyStore ks = KeyStore.getInstance();
+                    final int profileUid = UserHandle.getUid(userHandle, Process.SYSTEM_UID);
+                    final int parentUid = UserHandle.getUid(parentInfo.id, Process.SYSTEM_UID);
+                    ks.syncUid(parentUid, profileUid);
+                }
+            }
+        }
+    };
+
     public void systemReady() {
         migrateOldData();
     }
@@ -275,10 +304,22 @@
         }
     }
 
+    private int getUserParentOrSelfId(int userId) {
+        if (userId != 0) {
+            final UserManager um = (UserManager) mContext.getSystemService(USER_SERVICE);
+            final UserInfo pi = um.getProfileParent(userId);
+            if (pi != null) {
+                return pi.id;
+            }
+        }
+        return userId;
+    }
+
     private String getLockPatternFilename(int userId) {
         String dataSystemDirectory =
                 android.os.Environment.getDataDirectory().getAbsolutePath() +
                 SYSTEM_DIRECTORY;
+        userId = getUserParentOrSelfId(userId);
         if (userId == 0) {
             // Leave it in the same place for user 0
             return dataSystemDirectory + LOCK_PATTERN_FILE;
@@ -289,6 +330,7 @@
     }
 
     private String getLockPasswordFilename(int userId) {
+        userId = getUserParentOrSelfId(userId);
         String dataSystemDirectory =
                 android.os.Environment.getDataDirectory().getAbsolutePath() +
                 SYSTEM_DIRECTORY;
@@ -296,7 +338,7 @@
             // Leave it in the same place for user 0
             return dataSystemDirectory + LOCK_PASSWORD_FILE;
         } else {
-            return  new File(Environment.getUserSystemDirectory(userId), LOCK_PASSWORD_FILE)
+            return new File(Environment.getUserSystemDirectory(userId), LOCK_PASSWORD_FILE)
                     .getAbsolutePath();
         }
     }
@@ -315,16 +357,27 @@
         return new File(getLockPatternFilename(userId)).length() > 0;
     }
 
-    private void maybeUpdateKeystore(String password, int userId) {
-        if (userId == UserHandle.USER_OWNER) {
-            final KeyStore keyStore = KeyStore.getInstance();
-            // Conditionally reset the keystore if empty. If non-empty, we are just
-            // switching key guard type
-            if (TextUtils.isEmpty(password) && keyStore.isEmpty()) {
-                keyStore.reset();
+    private void maybeUpdateKeystore(String password, int userHandle) {
+        final UserManager um = (UserManager) mContext.getSystemService(USER_SERVICE);
+        final KeyStore ks = KeyStore.getInstance();
+
+        final List<UserInfo> profiles = um.getProfiles(userHandle);
+        boolean shouldReset = TextUtils.isEmpty(password);
+
+        // For historical reasons, don't wipe a non-empty keystore if we have a single user with a
+        // single profile.
+        if (userHandle == UserHandle.USER_OWNER && profiles.size() == 1) {
+            if (!ks.isEmpty()) {
+                shouldReset = false;
+            }
+        }
+
+        for (UserInfo pi : profiles) {
+            final int profileUid = UserHandle.getUid(pi.id, Process.SYSTEM_UID);
+            if (shouldReset) {
+                ks.resetUid(profileUid);
             } else {
-                // Update the keystore password
-                keyStore.password(password);
+                ks.passwordUid(password, profileUid);
             }
         }
     }
@@ -457,13 +510,18 @@
 
         SQLiteDatabase db = mOpenHelper.getWritableDatabase();
         try {
-            File file = new File(getLockPasswordFilename(userId));
-            if (file.exists()) {
-                file.delete();
-            }
-            file = new File(getLockPatternFilename(userId));
-            if (file.exists()) {
-                file.delete();
+            final UserManager um = (UserManager) mContext.getSystemService(USER_SERVICE);
+            final UserInfo parentInfo = um.getProfileParent(userId);
+            if (parentInfo == null) {
+                // This user owns its lock settings files - safe to delete them
+                File file = new File(getLockPasswordFilename(userId));
+                if (file.exists()) {
+                    file.delete();
+                }
+                file = new File(getLockPatternFilename(userId));
+                if (file.exists()) {
+                    file.delete();
+                }
             }
 
             db.beginTransaction();
diff --git a/services/core/java/com/android/server/MmsServiceBroker.java b/services/core/java/com/android/server/MmsServiceBroker.java
index df54c7f..0fb80c9 100644
--- a/services/core/java/com/android/server/MmsServiceBroker.java
+++ b/services/core/java/com/android/server/MmsServiceBroker.java
@@ -29,10 +29,12 @@
 import android.content.pm.PackageManager;
 import android.net.Uri;
 import android.os.Binder;
+import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
 import android.os.Message;
 import android.os.RemoteException;
+import android.os.ServiceManager;
 import android.telephony.TelephonyManager;
 import android.util.Slog;
 
@@ -190,59 +192,48 @@
     // Service API calls implementation, proxied to the real MmsService in "com.android.mms.service"
     private final class BinderService extends IMms.Stub {
         @Override
-        public void sendMessage(long subId, String callingPkg, byte[] pdu, String locationUrl,
-                ContentValues configOverrides, PendingIntent sentIntent) throws RemoteException {
+        public void sendMessage(long subId, String callingPkg, Uri contentUri,
+                String locationUrl, Bundle configOverrides, PendingIntent sentIntent)
+                        throws RemoteException {
             mContext.enforceCallingPermission(Manifest.permission.SEND_SMS, "Send MMS message");
             if (getAppOpsManager().noteOp(AppOpsManager.OP_SEND_SMS, Binder.getCallingUid(),
                     callingPkg) != AppOpsManager.MODE_ALLOWED) {
                 return;
             }
-            getServiceGuarded().sendMessage(subId, callingPkg, pdu, locationUrl, configOverrides,
-                    sentIntent);
+            getServiceGuarded().sendMessage(subId, callingPkg, contentUri, locationUrl,
+                    configOverrides, sentIntent);
         }
 
         @Override
         public void downloadMessage(long subId, String callingPkg, String locationUrl,
-                ContentValues configOverrides, PendingIntent downloadedIntent)
-                throws RemoteException {
+                Uri contentUri, Bundle configOverrides,
+                PendingIntent downloadedIntent) throws RemoteException {
             mContext.enforceCallingPermission(Manifest.permission.RECEIVE_MMS,
                     "Download MMS message");
             if (getAppOpsManager().noteOp(AppOpsManager.OP_RECEIVE_MMS, Binder.getCallingUid(),
                     callingPkg) != AppOpsManager.MODE_ALLOWED) {
                 return;
             }
-            getServiceGuarded().downloadMessage(subId, callingPkg, locationUrl, configOverrides,
-                    downloadedIntent);
+            getServiceGuarded().downloadMessage(subId, callingPkg, locationUrl, contentUri,
+                    configOverrides, downloadedIntent);
         }
 
         @Override
-        public void updateMmsSendStatus(int messageRef, boolean success) throws RemoteException {
+        public void updateMmsSendStatus(int messageRef, byte[] pdu, int status)
+                throws RemoteException {
             enforceCarrierPrivilege();
-            getServiceGuarded().updateMmsSendStatus(messageRef, success);
+            getServiceGuarded().updateMmsSendStatus(messageRef, pdu, status);
         }
 
         @Override
-        public void updateMmsDownloadStatus(int messageRef, byte[] pdu) throws RemoteException {
+        public void updateMmsDownloadStatus(int messageRef, int status) throws RemoteException {
             enforceCarrierPrivilege();
-            getServiceGuarded().updateMmsDownloadStatus(messageRef, pdu);
+            getServiceGuarded().updateMmsDownloadStatus(messageRef, status);
         }
 
         @Override
-        public boolean getCarrierConfigBoolean(long subId, String name, boolean defaultValue)
-                throws RemoteException {
-            return getServiceGuarded().getCarrierConfigBoolean(subId, name, defaultValue);
-        }
-
-        @Override
-        public int getCarrierConfigInt(long subId, String name, int defaultValue)
-                throws RemoteException {
-            return getServiceGuarded().getCarrierConfigInt(subId, name, defaultValue);
-        }
-
-        @Override
-        public String getCarrierConfigString(long subId, String name, String defaultValue)
-                throws RemoteException {
-            return getServiceGuarded().getCarrierConfigString(subId, name, defaultValue);
+        public Bundle getCarrierConfigValues(long subId) throws RemoteException {
+            return getServiceGuarded().getCarrierConfigValues(subId);
         }
 
         @Override
@@ -260,8 +251,9 @@
         }
 
         @Override
-        public Uri importMultimediaMessage(String callingPkg, byte[] pdu, String messageId,
-                long timestampSecs, boolean seen, boolean read) throws RemoteException {
+        public Uri importMultimediaMessage(String callingPkg, Uri contentUri,
+                String messageId, long timestampSecs, boolean seen, boolean read)
+                        throws RemoteException {
             mContext.enforceCallingPermission(Manifest.permission.WRITE_SMS, "Import MMS message");
             if (getAppOpsManager().noteOp(AppOpsManager.OP_WRITE_SMS, Binder.getCallingUid(),
                     callingPkg) != AppOpsManager.MODE_ALLOWED) {
@@ -270,7 +262,7 @@
                 return FAKE_MMS_SENT_URI;
             }
             return getServiceGuarded().importMultimediaMessage(
-                    callingPkg, pdu, messageId, timestampSecs, seen, read);
+                    callingPkg, contentUri, messageId, timestampSecs, seen, read);
         }
 
         @Override
@@ -328,7 +320,8 @@
         }
 
         @Override
-        public Uri addMultimediaMessageDraft(String callingPkg, byte[] pdu) throws RemoteException {
+        public Uri addMultimediaMessageDraft(String callingPkg, Uri contentUri)
+                throws RemoteException {
             mContext.enforceCallingPermission(Manifest.permission.WRITE_SMS, "Add MMS draft");
             if (getAppOpsManager().noteOp(AppOpsManager.OP_WRITE_SMS, Binder.getCallingUid(),
                     callingPkg) != AppOpsManager.MODE_ALLOWED) {
@@ -336,12 +329,12 @@
                 // while writing the TelephonyProvider
                 return FAKE_MMS_DRAFT_URI;
             }
-            return getServiceGuarded().addMultimediaMessageDraft(callingPkg, pdu);
+            return getServiceGuarded().addMultimediaMessageDraft(callingPkg, contentUri);
         }
 
         @Override
         public void sendStoredMessage(long subId, String callingPkg, Uri messageUri,
-                ContentValues configOverrides, PendingIntent sentIntent) throws RemoteException {
+                Bundle configOverrides, PendingIntent sentIntent) throws RemoteException {
             mContext.enforceCallingPermission(Manifest.permission.SEND_SMS,
                     "Send stored MMS message");
             if (getAppOpsManager().noteOp(AppOpsManager.OP_SEND_SMS, Binder.getCallingUid(),
diff --git a/services/core/java/com/android/server/MountService.java b/services/core/java/com/android/server/MountService.java
index 50f2ae9..ea24d7c 100644
--- a/services/core/java/com/android/server/MountService.java
+++ b/services/core/java/com/android/server/MountService.java
@@ -33,7 +33,6 @@
 import android.content.res.TypedArray;
 import android.content.res.XmlResourceParser;
 import android.hardware.usb.UsbManager;
-import android.app.admin.DevicePolicyManager;
 import android.net.Uri;
 import android.os.Binder;
 import android.os.Environment;
@@ -1761,6 +1760,21 @@
         return rc;
     }
 
+    @Override
+    public int resizeSecureContainer(String id, int sizeMb, String key) {
+        validatePermission(android.Manifest.permission.ASEC_CREATE);
+        waitForReady();
+        warnOnNotMounted();
+
+        int rc = StorageResultCode.OperationSucceeded;
+        try {
+            mConnector.execute("asec", "resize", id, sizeMb, new SensitiveArg(key));
+        } catch (NativeDaemonConnectorException e) {
+            rc = StorageResultCode.OperationFailedInternalError;
+        }
+        return rc;
+    }
+
     public int finalizeSecureContainer(String id) {
         validatePermission(android.Manifest.permission.ASEC_CREATE);
         warnOnNotMounted();
@@ -1835,7 +1849,7 @@
         return rc;
     }
 
-    public int mountSecureContainer(String id, String key, int ownerUid) {
+    public int mountSecureContainer(String id, String key, int ownerUid, boolean readOnly) {
         validatePermission(android.Manifest.permission.ASEC_MOUNT_UNMOUNT);
         waitForReady();
         warnOnNotMounted();
@@ -1848,7 +1862,8 @@
 
         int rc = StorageResultCode.OperationSucceeded;
         try {
-            mConnector.execute("asec", "mount", id, new SensitiveArg(key), ownerUid);
+            mConnector.execute("asec", "mount", id, new SensitiveArg(key), ownerUid,
+                    readOnly ? "ro" : "rw");
         } catch (NativeDaemonConnectorException e) {
             int code = e.getCode();
             if (code != VoldResponseCode.OpFailedStorageBusy) {
diff --git a/services/core/java/com/android/server/NativeDaemonEvent.java b/services/core/java/com/android/server/NativeDaemonEvent.java
index 2095152..59d50bd 100644
--- a/services/core/java/com/android/server/NativeDaemonEvent.java
+++ b/services/core/java/com/android/server/NativeDaemonEvent.java
@@ -201,20 +201,16 @@
         }
         while (current < length) {
             // find the end of the word
-            if (quoted) {
-                wordEnd = current;
-                while ((wordEnd = rawEvent.indexOf('\"', wordEnd)) != -1) {
-                    if (rawEvent.charAt(wordEnd - 1) != '\\') {
-                        break;
-                    } else {
-                        wordEnd++; // skip this escaped quote and keep looking
-                    }
+            char terminator = quoted ? '\"' : ' ';
+            wordEnd = current;
+            while (wordEnd < length && rawEvent.charAt(wordEnd) != terminator) {
+                if (rawEvent.charAt(wordEnd) == '\\') {
+                    // skip the escaped char
+                    ++wordEnd;
                 }
-            } else {
-                wordEnd = rawEvent.indexOf(' ', current);
+                ++wordEnd;
             }
-            // if we didn't find the end-o-word token, take the rest of the string
-            if (wordEnd == -1) wordEnd = length;
+            if (wordEnd > length) wordEnd = length;
             String word = rawEvent.substring(current, wordEnd);
             current += word.length();
             if (!quoted) {
diff --git a/services/core/java/com/android/server/NetworkManagementService.java b/services/core/java/com/android/server/NetworkManagementService.java
index f9b65b8..1318f66 100644
--- a/services/core/java/com/android/server/NetworkManagementService.java
+++ b/services/core/java/com/android/server/NetworkManagementService.java
@@ -44,6 +44,7 @@
 import android.net.InterfaceConfiguration;
 import android.net.IpPrefix;
 import android.net.LinkAddress;
+import android.net.Network;
 import android.net.NetworkStats;
 import android.net.NetworkUtils;
 import android.net.RouteInfo;
@@ -1200,10 +1201,12 @@
     }
 
     @Override
-    public void setDnsForwarders(String[] dns) {
+    public void setDnsForwarders(Network network, String[] dns) {
         mContext.enforceCallingOrSelfPermission(CONNECTIVITY_INTERNAL, TAG);
 
-        final Command cmd = new Command("tether", "dns", "set");
+        int netId = (network != null) ? network.netId : ConnectivityManager.NETID_UNSET;
+        final Command cmd = new Command("tether", "dns", "set", netId);
+
         for (String s : dns) {
             cmd.appendArg(NetworkUtils.numericToInetAddress(s).getHostAddress());
         }
diff --git a/services/core/java/com/android/server/NsdService.java b/services/core/java/com/android/server/NsdService.java
index cf7e65c..39aa972 100644
--- a/services/core/java/com/android/server/NsdService.java
+++ b/services/core/java/com/android/server/NsdService.java
@@ -397,8 +397,7 @@
                         break;
                     case NsdManager.NATIVE_DAEMON_EVENT:
                         NativeEvent event = (NativeEvent) msg.obj;
-                        if (!handleNativeEvent(event.code, event.raw,
-                                NativeDaemonEvent.unescapeArgs(event.raw))) {
+                        if (!handleNativeEvent(event.code, event.raw, event.cooked)) {
                             result = NOT_HANDLED;
                         }
                         break;
@@ -474,8 +473,14 @@
                     case NativeResponseCode.SERVICE_RESOLVED:
                         /* NNN resolveId fullName hostName port txtlen txtdata */
                         if (DBG) Slog.d(TAG, "SERVICE_RESOLVED Raw: " + raw);
-                        int index = cooked[2].indexOf(".");
-                        if (index == -1) {
+                        int index = 0;
+                        while (index < cooked[2].length() && cooked[2].charAt(index) != '.') {
+                            if (cooked[2].charAt(index) == '\\') {
+                                ++index;
+                            }
+                            ++index;
+                        }
+                        if (index >= cooked[2].length()) {
                             Slog.e(TAG, "Invalid service found " + raw);
                             break;
                         }
@@ -483,6 +488,8 @@
                         String rest = cooked[2].substring(index);
                         String type = rest.replace(".local.", "");
 
+                        name = unescape(name);
+
                         clientInfo.mResolvedService.setServiceName(name);
                         clientInfo.mResolvedService.setServiceType(type);
                         clientInfo.mResolvedService.setPort(Integer.parseInt(cooked[4]));
@@ -541,6 +548,30 @@
        }
     }
 
+    private String unescape(String s) {
+        StringBuilder sb = new StringBuilder(s.length());
+        for (int i = 0; i < s.length(); ++i) {
+            char c = s.charAt(i);
+            if (c == '\\') {
+                if (++i >= s.length()) {
+                    Slog.e(TAG, "Unexpected end of escape sequence in: " + s);
+                    break;
+                }
+                c = s.charAt(i);
+                if (c != '.' && c != '\\') {
+                    if (i + 2 >= s.length()) {
+                        Slog.e(TAG, "Unexpected end of escape sequence in: " + s);
+                        break;
+                    }
+                    c = (char) ((c-'0') * 100 + (s.charAt(i+1)-'0') * 10 + (s.charAt(i+2)-'0'));
+                    i += 2;
+                }
+            }
+            sb.append(c);
+        }
+        return sb.toString();
+    }
+
     private NativeDaemonConnector mNativeConnector;
     private final CountDownLatch mNativeDaemonConnected = new CountDownLatch(1);
 
@@ -625,10 +656,12 @@
     private class NativeEvent {
         final int code;
         final String raw;
+        final String[] cooked;
 
-        NativeEvent(int code, String raw) {
+        NativeEvent(int code, String raw, String[] cooked) {
             this.code = code;
             this.raw = raw;
+            this.cooked = cooked;
         }
     }
 
@@ -644,7 +677,7 @@
         public boolean onEvent(int code, String raw, String[] cooked) {
             // TODO: NDC translates a message to a callback, we could enhance NDC to
             // directly interact with a state machine through messages
-            NativeEvent event = new NativeEvent(code, raw);
+            NativeEvent event = new NativeEvent(code, raw, cooked);
             mNsdStateMachine.sendMessage(NsdManager.NATIVE_DAEMON_EVENT, event);
             return true;
         }
@@ -683,8 +716,9 @@
             for (String key : txtRecords.keySet()) {
                 try {
                     // TODO: Send encoded TXT record as bytes once NDC/netd supports binary data.
+                    byte[] recordValue = txtRecords.get(key);
                     cmd.appendArg(String.format(Locale.US, "%s=%s", key,
-                            new String(txtRecords.get(key), "UTF_8")));
+                            recordValue != null ? new String(recordValue, "UTF_8") : ""));
                 } catch (UnsupportedEncodingException e) {
                     Slog.e(TAG, "Failed to encode txtRecord " + e);
                 }
diff --git a/services/core/java/com/android/server/PersistentDataBlockService.java b/services/core/java/com/android/server/PersistentDataBlockService.java
index 2896f60..6f378fd 100644
--- a/services/core/java/com/android/server/PersistentDataBlockService.java
+++ b/services/core/java/com/android/server/PersistentDataBlockService.java
@@ -17,6 +17,7 @@
 package com.android.server;
 
 import android.Manifest;
+import android.app.ActivityManager;
 import android.content.Context;
 import android.content.pm.PackageManager;
 import android.os.Binder;
@@ -26,7 +27,9 @@
 import android.os.UserHandle;
 import android.service.persistentdata.IPersistentDataBlockService;
 import android.util.Slog;
+
 import com.android.internal.R;
+
 import libcore.io.IoUtils;
 
 import java.io.DataInputStream;
@@ -241,6 +244,10 @@
 
         @Override
         public void setOemUnlockEnabled(boolean enabled) {
+            // do not allow monkey to flip the flag
+            if (ActivityManager.isUserAMonkey()) {
+                return;
+            }
             enforceOemUnlockPermission();
             FileOutputStream outputStream;
             try {
diff --git a/services/core/java/com/android/server/SystemConfig.java b/services/core/java/com/android/server/SystemConfig.java
index fdcb3b9..cf2a49f 100644
--- a/services/core/java/com/android/server/SystemConfig.java
+++ b/services/core/java/com/android/server/SystemConfig.java
@@ -50,19 +50,16 @@
 
     // These are the built-in uid -> permission mappings that were read from the
     // system configuration files.
-    final SparseArray<HashSet<String>> mSystemPermissions =
-            new SparseArray<HashSet<String>>();
+    final SparseArray<HashSet<String>> mSystemPermissions = new SparseArray<>();
 
     // These are the built-in shared libraries that were read from the
     // system configuration files.  Keys are the library names; strings are the
     // paths to the libraries.
-    final ArrayMap<String, String> mSharedLibraries
-            = new ArrayMap<String, String>();
+    final ArrayMap<String, String> mSharedLibraries  = new ArrayMap<>();
 
     // These are the features this devices supports that were read from the
     // system configuration files.
-    final HashMap<String, FeatureInfo> mAvailableFeatures =
-            new HashMap<String, FeatureInfo>();
+    final HashMap<String, FeatureInfo> mAvailableFeatures = new HashMap<>();
 
     public static final class PermissionEntry {
         public final String name;
@@ -75,12 +72,14 @@
 
     // These are the permission -> gid mappings that were read from the
     // system configuration files.
-    final ArrayMap<String, PermissionEntry> mPermissions =
-            new ArrayMap<String, PermissionEntry>();
+    final ArrayMap<String, PermissionEntry> mPermissions = new ArrayMap<>();
 
     // These are the packages that are white-listed to be able to run in the
     // background while in power save mode, as read from the configuration files.
-    final ArraySet<String> mAllowInPowerSave = new ArraySet<String>();
+    final ArraySet<String> mAllowInPowerSave = new ArraySet<>();
+
+    // These are the app package names that should not allow IME switching.
+    final ArraySet<String> mFixedImeApps = new ArraySet<>();
 
     public static SystemConfig getInstance() {
         synchronized (SystemConfig.class) {
@@ -115,6 +114,10 @@
         return mAllowInPowerSave;
     }
 
+    public ArraySet<String> getFixedImeApps() {
+        return mFixedImeApps;
+    }
+
     SystemConfig() {
         // Read configuration from system
         readPermissions(Environment.buildPath(
@@ -298,6 +301,17 @@
                     XmlUtils.skipCurrentTag(parser);
                     continue;
 
+                } else if ("fixed-ime-app".equals(name)) {
+                    String pkgname = parser.getAttributeValue(null, "package");
+                    if (pkgname == null) {
+                        Slog.w(TAG, "<fixed-ime-app> without package at "
+                                + parser.getPositionDescription());
+                    } else {
+                        mFixedImeApps.add(pkgname);
+                    }
+                    XmlUtils.skipCurrentTag(parser);
+                    continue;
+
                 } else {
                     XmlUtils.skipCurrentTag(parser);
                     continue;
diff --git a/services/core/java/com/android/server/TelephonyRegistry.java b/services/core/java/com/android/server/TelephonyRegistry.java
index 7624314..37c23bb 100644
--- a/services/core/java/com/android/server/TelephonyRegistry.java
+++ b/services/core/java/com/android/server/TelephonyRegistry.java
@@ -196,7 +196,7 @@
                     if (VDBG) log("MSG_USER_SWITCHED userId=" + msg.arg1);
                     int numPhones = TelephonyManager.getDefault().getPhoneCount();
                     for (int sub = 0; sub < numPhones; sub++) {
-                        TelephonyRegistry.this.notifyCellLocationUsingSubId(sub,
+                        TelephonyRegistry.this.notifyCellLocationForSubscriber(sub,
                                 mCellLocation[sub]);
                     }
                     break;
@@ -326,7 +326,7 @@
     }
 
     @Override
-    public void listenUsingSubId(long subId, String pkgForDebug, IPhoneStateListener callback,
+    public void listenForSubscriber(long subId, String pkgForDebug, IPhoneStateListener callback,
             int events, boolean notifyNow) {
         listen(pkgForDebug, callback, events, notifyNow, subId, false);
     }
@@ -542,12 +542,12 @@
         broadcastCallStateChanged(state, incomingNumber, mDefaultSubId);
     }
 
-    public void notifyCallStateUsingSubId(long subId, int state, String incomingNumber) {
+    public void notifyCallStateForSubscriber(long subId, int state, String incomingNumber) {
         if (!checkNotifyPermission("notifyCallState()")) {
             return;
         }
         if (VDBG) {
-            log("notifyCallStateUsingSubId: subId=" + subId
+            log("notifyCallStateForSubscriber: subId=" + subId
                 + " state=" + state + " incomingNumber=" + incomingNumber);
         }
         synchronized (mRecords) {
@@ -573,38 +573,38 @@
     }
 
      public void notifyServiceState(ServiceState state) {
-         notifyServiceStateUsingSubId(mDefaultSubId, state);
+         notifyServiceStateForSubscriber(mDefaultSubId, state);
      }
 
-    public void notifyServiceStateUsingSubId(long subId, ServiceState state) {
+    public void notifyServiceStateForSubscriber(long subId, ServiceState state) {
         if (!checkNotifyPermission("notifyServiceState()")){
             return;
         }
         if (subId == SubscriptionManager.DEFAULT_SUB_ID) {
             subId = mDefaultSubId;
-            if (VDBG) log("notifyServiceStateUsingSubId: using mDefaultSubId=" + mDefaultSubId);
+            if (VDBG) log("notifyServiceStateForSubscriber: using mDefaultSubId=" + mDefaultSubId);
         }
         synchronized (mRecords) {
             int phoneId = SubscriptionManager.getPhoneId(subId);
             if (VDBG) {
-                log("notifyServiceStateUsingSubId: subId=" + subId + " phoneId=" + phoneId
+                log("notifyServiceStateForSubscriber: subId=" + subId + " phoneId=" + phoneId
                     + " state=" + state);
             }
             if (validatePhoneId(phoneId)) {
                 mServiceState[phoneId] = state;
-                logServiceStateChanged("notifyServiceStateUsingSubId", subId, phoneId, state);
-                if (VDBG) toStringLogSSC("notifyServiceStateUsingSubId");
+                logServiceStateChanged("notifyServiceStateForSubscriber", subId, phoneId, state);
+                if (VDBG) toStringLogSSC("notifyServiceStateForSubscriber");
 
                 for (Record r : mRecords) {
                     if (VDBG) {
-                        log("notifyServiceStateUsingSubId: r=" + r + " subId=" + subId
+                        log("notifyServiceStateForSubscriber: r=" + r + " subId=" + subId
                                 + " phoneId=" + phoneId + " state=" + state);
                     }
                     if (((r.events & PhoneStateListener.LISTEN_SERVICE_STATE) != 0) &&
                         (r.phoneId == phoneId)) {
                         try {
                             if (DBG) {
-                                log("notifyServiceStateUsingSubId: callback.onSSC r=" + r
+                                log("notifyServiceStateForSubscriber: callback.onSSC r=" + r
                                         + " subId=" + subId + " phoneId=" + phoneId
                                         + " state=" + state);
                             }
@@ -615,7 +615,7 @@
                     }
                 }
             } else {
-                log("notifyServiceStateUsingSubId: INVALID phoneId=" + phoneId);
+                log("notifyServiceStateForSubscriber: INVALID phoneId=" + phoneId);
             }
             handleRemoveListLocked();
         }
@@ -623,33 +623,33 @@
     }
 
     public void notifySignalStrength(SignalStrength signalStrength) {
-        notifySignalStrengthUsingSubId(mDefaultSubId, signalStrength);
+        notifySignalStrengthForSubscriber(mDefaultSubId, signalStrength);
     }
 
-    public void notifySignalStrengthUsingSubId(long subId, SignalStrength signalStrength) {
+    public void notifySignalStrengthForSubscriber(long subId, SignalStrength signalStrength) {
         if (!checkNotifyPermission("notifySignalStrength()")) {
             return;
         }
         if (VDBG) {
-            log("notifySignalStrengthUsingSubId: subId=" + subId
+            log("notifySignalStrengthForSubscriber: subId=" + subId
                 + " signalStrength=" + signalStrength);
-            toStringLogSSC("notifySignalStrengthUsingSubId");
+            toStringLogSSC("notifySignalStrengthForSubscriber");
         }
         synchronized (mRecords) {
             int phoneId = SubscriptionManager.getPhoneId(subId);
             if (validatePhoneId(phoneId)) {
-                if (VDBG) log("notifySignalStrengthUsingSubId: valid phoneId=" + phoneId);
+                if (VDBG) log("notifySignalStrengthForSubscriber: valid phoneId=" + phoneId);
                 mSignalStrength[phoneId] = signalStrength;
                 for (Record r : mRecords) {
                     if (VDBG) {
-                        log("notifySignalStrengthUsingSubId: r=" + r + " subId=" + subId
+                        log("notifySignalStrengthForSubscriber: r=" + r + " subId=" + subId
                                 + " phoneId=" + phoneId + " ss=" + signalStrength);
                     }
                     if (((r.events & PhoneStateListener.LISTEN_SIGNAL_STRENGTHS) != 0) &&
                         (r.phoneId == phoneId)) {
                         try {
                             if (DBG) {
-                                log("notifySignalStrengthUsingSubId: callback.onSsS r=" + r
+                                log("notifySignalStrengthForSubscriber: callback.onSsS r=" + r
                                         + " subId=" + subId + " phoneId=" + phoneId
                                         + " ss=" + signalStrength);
                             }
@@ -664,7 +664,7 @@
                             int gsmSignalStrength = signalStrength.getGsmSignalStrength();
                             int ss = (gsmSignalStrength == 99 ? -1 : gsmSignalStrength);
                             if (DBG) {
-                                log("notifySignalStrengthUsingSubId: callback.onSS r=" + r
+                                log("notifySignalStrengthForSubscriber: callback.onSS r=" + r
                                         + " subId=" + subId + " phoneId=" + phoneId
                                         + " gsmSS=" + gsmSignalStrength + " ss=" + ss);
                             }
@@ -675,7 +675,7 @@
                     }
                 }
             } else {
-                log("notifySignalStrengthUsingSubId: invalid phoneId=" + phoneId);
+                log("notifySignalStrengthForSubscriber: invalid phoneId=" + phoneId);
             }
             handleRemoveListLocked();
         }
@@ -683,15 +683,15 @@
     }
 
     public void notifyCellInfo(List<CellInfo> cellInfo) {
-         notifyCellInfoUsingSubId(mDefaultSubId, cellInfo);
+         notifyCellInfoForSubscriber(mDefaultSubId, cellInfo);
     }
 
-    public void notifyCellInfoUsingSubId(long subId, List<CellInfo> cellInfo) {
+    public void notifyCellInfoForSubscriber(long subId, List<CellInfo> cellInfo) {
         if (!checkNotifyPermission("notifyCellInfo()")) {
             return;
         }
         if (VDBG) {
-            log("notifyCellInfoUsingSubId: subId=" + subId
+            log("notifyCellInfoForSubscriber: subId=" + subId
                 + " cellInfo=" + cellInfo);
         }
 
@@ -743,15 +743,15 @@
     }
 
     public void notifyMessageWaitingChanged(boolean mwi) {
-        notifyMessageWaitingChangedUsingSubId(mDefaultSubId, mwi);
+        notifyMessageWaitingChangedForSubscriber(mDefaultSubId, mwi);
     }
 
-    public void notifyMessageWaitingChangedUsingSubId(long subId, boolean mwi) {
+    public void notifyMessageWaitingChangedForSubscriber(long subId, boolean mwi) {
         if (!checkNotifyPermission("notifyMessageWaitingChanged()")) {
             return;
         }
         if (VDBG) {
-            log("notifyMessageWaitingChangedUsingSubId: subId=" + subId
+            log("notifyMessageWaitingChangedForSubscriber: subId=" + subId
                 + " mwi=" + mwi);
         }
         synchronized (mRecords) {
@@ -774,15 +774,15 @@
     }
 
     public void notifyCallForwardingChanged(boolean cfi) {
-        notifyCallForwardingChangedUsingSubId(mDefaultSubId, cfi);
+        notifyCallForwardingChangedForSubscriber(mDefaultSubId, cfi);
     }
 
-    public void notifyCallForwardingChangedUsingSubId(long subId, boolean cfi) {
+    public void notifyCallForwardingChangedForSubscriber(long subId, boolean cfi) {
         if (!checkNotifyPermission("notifyCallForwardingChanged()")) {
             return;
         }
         if (VDBG) {
-            log("notifyCallForwardingChangedUsingSubId: subId=" + subId
+            log("notifyCallForwardingChangedForSubscriber: subId=" + subId
                 + " cfi=" + cfi);
         }
         synchronized (mRecords) {
@@ -805,10 +805,10 @@
     }
 
     public void notifyDataActivity(int state) {
-        notifyDataActivityUsingSubId(mDefaultSubId, state);
+        notifyDataActivityForSubscriber(mDefaultSubId, state);
     }
 
-    public void notifyDataActivityUsingSubId(long subId, int state) {
+    public void notifyDataActivityForSubscriber(long subId, int state) {
         if (!checkNotifyPermission("notifyDataActivity()" )) {
             return;
         }
@@ -831,12 +831,12 @@
     public void notifyDataConnection(int state, boolean isDataConnectivityPossible,
             String reason, String apn, String apnType, LinkProperties linkProperties,
             NetworkCapabilities networkCapabilities, int networkType, boolean roaming) {
-        notifyDataConnectionUsingSubId(mDefaultSubId, state, isDataConnectivityPossible,
+        notifyDataConnectionForSubscriber(mDefaultSubId, state, isDataConnectivityPossible,
             reason, apn, apnType, linkProperties,
             networkCapabilities, networkType, roaming);
     }
 
-    public void notifyDataConnectionUsingSubId(long subId, int state,
+    public void notifyDataConnectionForSubscriber(long subId, int state,
             boolean isDataConnectivityPossible, String reason, String apn, String apnType,
             LinkProperties linkProperties, NetworkCapabilities networkCapabilities,
             int networkType, boolean roaming) {
@@ -844,7 +844,7 @@
             return;
         }
         if (VDBG) {
-            log("notifyDataConnectionUsingSubId: subId=" + subId
+            log("notifyDataConnectionForSubscriber: subId=" + subId
                 + " state=" + state + " isDataConnectivityPossible=" + isDataConnectivityPossible
                 + " reason='" + reason
                 + "' apn='" + apn + "' apnType=" + apnType + " networkType=" + networkType
@@ -921,16 +921,16 @@
     }
 
     public void notifyDataConnectionFailed(String reason, String apnType) {
-         notifyDataConnectionFailedUsingSubId(mDefaultSubId, reason, apnType);
+         notifyDataConnectionFailedForSubscriber(mDefaultSubId, reason, apnType);
     }
 
-    public void notifyDataConnectionFailedUsingSubId(long subId,
+    public void notifyDataConnectionFailedForSubscriber(long subId,
             String reason, String apnType) {
         if (!checkNotifyPermission("notifyDataConnectionFailed()")) {
             return;
         }
         if (VDBG) {
-            log("notifyDataConnectionFailedUsingSubId: subId=" + subId
+            log("notifyDataConnectionFailedForSubscriber: subId=" + subId
                 + " reason=" + reason + " apnType=" + apnType);
         }
         synchronized (mRecords) {
@@ -954,17 +954,17 @@
     }
 
     public void notifyCellLocation(Bundle cellLocation) {
-         notifyCellLocationUsingSubId(mDefaultSubId, cellLocation);
+         notifyCellLocationForSubscriber(mDefaultSubId, cellLocation);
     }
 
-    public void notifyCellLocationUsingSubId(long subId, Bundle cellLocation) {
-        log("notifyCellLocationUsingSubId: subId=" + subId
+    public void notifyCellLocationForSubscriber(long subId, Bundle cellLocation) {
+        log("notifyCellLocationForSubscriber: subId=" + subId
                 + " cellLocation=" + cellLocation);
         if (!checkNotifyPermission("notifyCellLocation()")) {
             return;
         }
         if (VDBG) {
-            log("notifyCellLocationUsingSubId: subId=" + subId
+            log("notifyCellLocationForSubscriber: subId=" + subId
                 + " cellLocation=" + cellLocation);
         }
         synchronized (mRecords) {
diff --git a/services/core/java/com/android/server/UiModeManagerService.java b/services/core/java/com/android/server/UiModeManagerService.java
index 6ab52c6..d1b4569 100644
--- a/services/core/java/com/android/server/UiModeManagerService.java
+++ b/services/core/java/com/android/server/UiModeManagerService.java
@@ -599,6 +599,8 @@
                 n.defaults = Notification.DEFAULT_LIGHTS;
                 n.flags = Notification.FLAG_ONGOING_EVENT;
                 n.when = 0;
+                n.color = context.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color);
                 n.setLatestEventInfo(
                         context,
                         context.getString(R.string.car_mode_disable_notification_title),
diff --git a/services/core/java/com/android/server/Watchdog.java b/services/core/java/com/android/server/Watchdog.java
index 1ce073a..89e3f49 100644
--- a/services/core/java/com/android/server/Watchdog.java
+++ b/services/core/java/com/android/server/Watchdog.java
@@ -332,6 +332,7 @@
             final ArrayList<HandlerChecker> blockedCheckers;
             final String subject;
             final boolean allowRestart;
+            int debuggerWasConnected = 0;
             synchronized (this) {
                 long timeout = CHECK_INTERVAL;
                 // Make sure we (re)spin the checkers that have become idle within
@@ -341,17 +342,27 @@
                     hc.scheduleCheckLocked();
                 }
 
+                if (debuggerWasConnected > 0) {
+                    debuggerWasConnected--;
+                }
+
                 // NOTE: We use uptimeMillis() here because we do not want to increment the time we
                 // wait while asleep. If the device is asleep then the thing that we are waiting
                 // to timeout on is asleep as well and won't have a chance to run, causing a false
                 // positive on when to kill things.
                 long start = SystemClock.uptimeMillis();
                 while (timeout > 0) {
+                    if (Debug.isDebuggerConnected()) {
+                        debuggerWasConnected = 2;
+                    }
                     try {
                         wait(timeout);
                     } catch (InterruptedException e) {
                         Log.wtf(TAG, e);
                     }
+                    if (Debug.isDebuggerConnected()) {
+                        debuggerWasConnected = 2;
+                    }
                     timeout = CHECK_INTERVAL - (SystemClock.uptimeMillis() - start);
                 }
 
@@ -450,7 +461,12 @@
 
             // Only kill the process if the debugger is not attached.
             if (Debug.isDebuggerConnected()) {
+                debuggerWasConnected = 2;
+            }
+            if (debuggerWasConnected >= 2) {
                 Slog.w(TAG, "Debugger connected: Watchdog is *not* killing the system process");
+            } else if (debuggerWasConnected > 0) {
+                Slog.w(TAG, "Debugger was connected: Watchdog is *not* killing the system process");
             } else if (!allowRestart) {
                 Slog.w(TAG, "Restart not allowed: Watchdog is *not* killing the system process");
             } else {
diff --git a/services/core/java/com/android/server/accounts/AccountManagerService.java b/services/core/java/com/android/server/accounts/AccountManagerService.java
index 2a66baf..888fa1a 100644
--- a/services/core/java/com/android/server/accounts/AccountManagerService.java
+++ b/services/core/java/com/android/server/accounts/AccountManagerService.java
@@ -265,7 +265,11 @@
         mContext.registerReceiver(new BroadcastReceiver() {
             @Override
             public void onReceive(Context context1, Intent intent) {
-                purgeOldGrantsAll();
+                // Don't delete accounts when updating a authenticator's
+                // package.
+                if (!intent.getBooleanExtra(Intent.EXTRA_REPLACING, false)) {
+                    purgeOldGrantsAll();
+                }
             }
         }, intentFilter);
 
@@ -1700,7 +1704,10 @@
             subtitle = titleAndSubtitle.substring(index + 1);
         }
         UserHandle user = new UserHandle(userId);
-        n.setLatestEventInfo(mContext, title, subtitle,
+        Context contextForUser = getContextForUser(user);
+        n.color = contextForUser.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color);
+        n.setLatestEventInfo(contextForUser, title, subtitle,
                 PendingIntent.getActivityAsUser(mContext, 0, intent,
                         PendingIntent.FLAG_CANCEL_CURRENT, null, user));
         installNotification(getCredentialPermissionNotificationId(
@@ -2966,9 +2973,12 @@
                 Notification n = new Notification(android.R.drawable.stat_sys_warning, null,
                         0 /* when */);
                 UserHandle user = new UserHandle(userId);
+                Context contextForUser = getContextForUser(user);
                 final String notificationTitleFormat =
-                        mContext.getText(R.string.notification_title).toString();
-                n.setLatestEventInfo(mContext,
+                        contextForUser.getText(R.string.notification_title).toString();
+                n.color = contextForUser.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color);
+                n.setLatestEventInfo(contextForUser,
                         String.format(notificationTitleFormat, account.name),
                         message, PendingIntent.getActivityAsUser(
                         mContext, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT,
@@ -3474,4 +3484,13 @@
         }
         return authTokensForAccount;
     }
+
+    private Context getContextForUser(UserHandle user) {
+        try {
+            return mContext.createPackageContextAsUser(mContext.getPackageName(), 0, user);
+        } catch (NameNotFoundException e) {
+            // Default to mContext, not finding the package system is running as is unlikely.
+            return mContext;
+        }
+    }
 }
diff --git a/services/core/java/com/android/server/am/ActiveServices.java b/services/core/java/com/android/server/am/ActiveServices.java
index 0bdb964..d38074f 100755
--- a/services/core/java/com/android/server/am/ActiveServices.java
+++ b/services/core/java/com/android/server/am/ActiveServices.java
@@ -29,6 +29,7 @@
 import android.os.Looper;
 import android.os.SystemProperties;
 import android.util.ArrayMap;
+import android.util.ArraySet;
 import com.android.internal.app.ProcessMap;
 import com.android.internal.app.ProcessStats;
 import com.android.internal.os.BatteryStatsImpl;
@@ -308,7 +309,14 @@
             return new ComponentName("!", res.permission != null
                     ? res.permission : "private to package");
         }
+
         ServiceRecord r = res.record;
+
+        if (!mAm.getUserManagerLocked().exists(r.userId)) {
+            Slog.d(TAG, "Trying to start service with non-existent user! " + r.userId);
+            return null;
+        }
+
         NeededUriGrants neededGrants = mAm.checkGrantUriPermissionFromIntentLocked(
                 callingUid, r.packageName, service, service.getFlags(), null, r.userId);
         if (unscheduleServiceRestartLocked(r, callingUid, false)) {
@@ -602,8 +610,25 @@
         mAm.updateProcessForegroundLocked(proc, anyForeground, oomAdj);
     }
 
+    public void updateServiceConnectionActivitiesLocked(ProcessRecord clientProc) {
+        ArraySet<ProcessRecord> updatedProcesses = null;
+        for (int i=0; i<clientProc.connections.size(); i++) {
+            final ConnectionRecord conn = clientProc.connections.valueAt(i);
+            final ProcessRecord proc = conn.binding.service.app;
+            if (proc == null || proc == clientProc) {
+                continue;
+            } else if (updatedProcesses == null) {
+                updatedProcesses = new ArraySet<>();
+            } else if (updatedProcesses.contains(proc)) {
+                continue;
+            }
+            updatedProcesses.add(proc);
+            updateServiceClientActivitiesLocked(proc, null, false);
+        }
+    }
+
     private boolean updateServiceClientActivitiesLocked(ProcessRecord proc,
-            ConnectionRecord modCr) {
+            ConnectionRecord modCr, boolean updateLru) {
         if (modCr != null && modCr.binding.client != null) {
             if (modCr.binding.client.activities.size() <= 0) {
                 // This connection is from a client without activities, so adding
@@ -632,7 +657,9 @@
         }
         if (anyClientActivities != proc.hasClientActivities) {
             proc.hasClientActivities = anyClientActivities;
-            mAm.updateLruProcessLocked(proc, anyClientActivities, null);
+            if (updateLru) {
+                mAm.updateLruProcessLocked(proc, anyClientActivities, null);
+            }
             return true;
         }
         return false;
@@ -744,7 +771,7 @@
                 b.client.hasAboveClient = true;
             }
             if (s.app != null) {
-                updateServiceClientActivitiesLocked(s.app, c);
+                updateServiceClientActivitiesLocked(s.app, c, true);
             }
             clist = mServiceConnections.get(binder);
             if (clist == null) {
@@ -1438,6 +1465,8 @@
 
         requestServiceBindingsLocked(r, execInFg);
 
+        updateServiceClientActivitiesLocked(app, null, true);
+
         // If the service is in the started state, and there are no
         // pending arguments, then fake up one so its onStartCommand() will
         // be called.
@@ -1693,7 +1722,7 @@
                 b.client.updateHasAboveClientLocked();
             }
             if (s.app != null) {
-                updateServiceClientActivitiesLocked(s.app, c);
+                updateServiceClientActivitiesLocked(s.app, c, true);
             }
         }
         clist = mServiceConnections.get(binder);
@@ -2070,6 +2099,38 @@
                         + ": shouldUnbind=" + b.hasBound);
                 b.binder = null;
                 b.requested = b.received = b.hasBound = false;
+                // If this binding is coming from a cached process and is asking to keep
+                // the service created, then we'll kill the cached process as well -- we
+                // don't want to be thrashing around restarting processes that are only
+                // there to be cached.
+                for (int appi=b.apps.size()-1; appi>=0; appi--) {
+                    final ProcessRecord proc = b.apps.keyAt(appi);
+                    // If the process is already gone, skip it.
+                    if (proc.killedByAm || proc.thread == null) {
+                        continue;
+                    }
+                    // Only do this for processes that have an auto-create binding;
+                    // otherwise the binding can be left, because it won't cause the
+                    // service to restart.
+                    final AppBindRecord abind = b.apps.valueAt(appi);
+                    boolean hasCreate = false;
+                    for (int conni=abind.connections.size()-1; conni>=0; conni--) {
+                        ConnectionRecord conn = abind.connections.valueAt(conni);
+                        if ((conn.flags&Context.BIND_AUTO_CREATE) != 0) {
+                            hasCreate = true;
+                            break;
+                        }
+                    }
+                    if (!hasCreate) {
+                        continue;
+                    }
+                    if (proc != null && !proc.persistent && proc.thread != null
+                            && proc.pid != 0 && proc.pid != ActivityManagerService.MY_PID
+                            && proc.setProcState >= ActivityManager.PROCESS_STATE_LAST_ACTIVITY) {
+                        proc.kill("bound to service " + sr.name.flattenToShortString()
+                                + " in dying proc " + (app != null ? app.processName : "??"), true);
+                    }
+                }
             }
         }
 
@@ -2078,6 +2139,7 @@
             ConnectionRecord r = app.connections.valueAt(i);
             removeConnectionLocked(r, app, null);
         }
+        updateServiceConnectionActivitiesLocked(app);
         app.connections.clear();
 
         ServiceMap smap = getServiceMap(app.userId);
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index ecd8f11..6d8e105 100755
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -33,13 +33,18 @@
 
 import android.Manifest;
 import android.app.AppOpsManager;
+import android.app.ApplicationThreadNative;
 import android.app.IActivityContainer;
 import android.app.IActivityContainerCallback;
 import android.app.IAppTask;
+import android.app.ProfilerInfo;
 import android.app.admin.DevicePolicyManager;
 import android.app.usage.UsageEvents;
 import android.app.usage.UsageStatsManagerInternal;
 import android.appwidget.AppWidgetManager;
+import android.content.res.Resources;
+import android.graphics.Bitmap;
+import android.graphics.Point;
 import android.graphics.Rect;
 import android.os.BatteryStats;
 import android.os.PersistableBundle;
@@ -175,6 +180,7 @@
 import android.os.SystemProperties;
 import android.os.UpdateLock;
 import android.os.UserHandle;
+import android.os.UserManager;
 import android.provider.Settings;
 import android.text.format.DateUtils;
 import android.text.format.Time;
@@ -191,6 +197,7 @@
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.WindowManager;
+import dalvik.system.VMRuntime;
 
 import java.io.BufferedInputStream;
 import java.io.BufferedOutputStream;
@@ -261,6 +268,7 @@
     static final boolean DEBUG_VISBILITY = localLOGV || false;
     static final boolean DEBUG_PSS = localLOGV || false;
     static final boolean DEBUG_LOCKSCREEN = localLOGV || false;
+    static final boolean DEBUG_RECENTS = localLOGV || false;
     static final boolean VALIDATE_TOKENS = false;
     static final boolean SHOW_ACTIVITY_START_TIME = true;
 
@@ -278,9 +286,6 @@
 
     static final boolean IS_USER_BUILD = "user".equals(Build.TYPE);
 
-    // Maximum number of recent tasks that we can remember.
-    static final int MAX_RECENT_TASKS = ActivityManager.isLowRamDeviceStatic() ? 100 : 200;
-
     // Maximum number recent bitmaps to keep in memory.
     static final int MAX_RECENT_BITMAPS = 5;
 
@@ -408,7 +413,22 @@
      * List of intents that were used to start the most recent tasks.
      */
     ArrayList<TaskRecord> mRecentTasks;
-    ArraySet<TaskRecord> mTmpRecents = new ArraySet<TaskRecord>();
+    ArrayList<TaskRecord> mTmpRecents = new ArrayList<TaskRecord>();
+
+    /**
+     * For addAppTask: cached of the last activity component that was added.
+     */
+    ComponentName mLastAddedTaskComponent;
+
+    /**
+     * For addAppTask: cached of the last activity uid that was added.
+     */
+    int mLastAddedTaskUid;
+
+    /**
+     * For addAppTask: cached of the last ActivityInfo that was added.
+     */
+    ActivityInfo mLastAddedTaskActivity;
 
     public class PendingAssistExtras extends Binder implements Runnable {
         public final ActivityRecord activity;
@@ -869,6 +889,8 @@
     boolean mProcessesReady = false;
     boolean mSystemReady = false;
     boolean mBooting = false;
+    boolean mCallFinishBooting = false;
+    boolean mBootAnimationComplete = false;
     boolean mWaitingUpdate = false;
     boolean mDidUpdate = false;
     boolean mOnBattery = false;
@@ -915,6 +937,13 @@
     private boolean mRunningVoice = false;
 
     /**
+     * Set while the keyguard is waiting for an activity to draw.
+     * In this state, if we are sleeping, we allow Activities to launch
+     * so that they can draw before Keyguard dismisses itself.
+     */
+    private boolean mKeyguardWaitingForDraw = false;
+
+    /**
      * State of external calls telling us if the device is asleep.
      */
     private boolean mWentToSleep = false;
@@ -1030,8 +1059,9 @@
     ProcessRecord mProfileProc = null;
     String mProfileFile;
     ParcelFileDescriptor mProfileFd;
-    int mProfileType = 0;
+    int mSamplingInterval = 0;
     boolean mAutoStopProfiler = false;
+    int mProfileType = 0;
     String mOpenGlTraceApp = null;
 
     static class ProcessChangeItem {
@@ -1055,13 +1085,16 @@
 
     /**
      * Runtime CPU use collection thread.  This object's lock is used to
-     * protect all related state.
+     * perform synchronization with the thread (notifying it to run).
      */
     final Thread mProcessCpuThread;
 
     /**
-     * Used to collect process stats when showing not responding dialog.
-     * Protected by mProcessCpuThread.
+     * Used to collect per-process CPU use for ANRs, battery stats, etc.
+     * Must acquire this object's lock when accessing it.
+     * NOTE: this lock will be held while doing long operations (trawling
+     * through all processes in /proc), so it should never be acquired by
+     * any critical paths such as when holding the main activity manager lock.
      */
     final ProcessCpuTracker mProcessCpuTracker = new ProcessCpuTracker(
             MONITOR_THREAD_CPU_USAGE);
@@ -1088,7 +1121,12 @@
 
     final ActivityThread mSystemThread;
 
+    // Holds the current foreground user's id
     int mCurrentUserId = 0;
+    // Holds the target user's id during a user switch
+    int mTargetUserId = UserHandle.USER_NULL;
+    // If there are multiple profiles for the current user, their ids are here
+    // Currently only the primary user can have managed profiles
     int[] mCurrentProfileIds = new int[] {UserHandle.USER_OWNER}; // Accessed by ActivityStack
 
     /**
@@ -1160,6 +1198,7 @@
     static final int SYSTEM_USER_CURRENT_MSG = 43;
     static final int ENTER_ANIMATION_COMPLETE_MSG = 44;
     static final int ENABLE_SCREEN_AFTER_BOOT_MSG = 45;
+    static final int START_USER_SWITCH_MSG = 46;
 
     static final int FIRST_ACTIVITY_STACK_MSG = 100;
     static final int FIRST_BROADCAST_QUEUE_MSG = 200;
@@ -1178,8 +1217,12 @@
      */
     private boolean mUserIsMonkey;
 
-    /** Flag whether the device has a recents UI */
-    final boolean mHasRecents;
+    /** Flag whether the device has a Recents UI */
+    boolean mHasRecents;
+
+    /** The dimensions of the thumbnails in the Recents UI. */
+    int mThumbnailWidth;
+    int mThumbnailHeight;
 
     final ServiceThread mHandlerThread;
     final MainHandler mHandler;
@@ -1472,6 +1515,8 @@
                     notification.defaults = 0; // please be quiet
                     notification.sound = null;
                     notification.vibrate = null;
+                    notification.color = mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color);
                     notification.setLatestEventInfo(context, text,
                             mContext.getText(R.string.heavy_weight_notification_detail),
                             PendingIntent.getActivityAsUser(mContext, 0, root.intent,
@@ -1563,7 +1608,7 @@
                             infoMap.put(mi.pid, mi);
                         }
                         updateCpuStatsNow();
-                        synchronized (mProcessCpuThread) {
+                        synchronized (mProcessCpuTracker) {
                             final int N = mProcessCpuTracker.countStats();
                             for (int i=0; i<N; i++) {
                                 ProcessCpuTracker.Stats st = mProcessCpuTracker.getStats(i);
@@ -1747,6 +1792,10 @@
                 thread.start();
                 break;
             }
+            case START_USER_SWITCH_MSG: {
+                showUserSwitchDialog(msg.arg1, (String) msg.obj);
+                break;
+            }
             case REPORT_USER_SWITCH_MSG: {
                 dispatchUserSwitch((UserStartedState) msg.obj, msg.arg1, msg.arg2);
                 break;
@@ -1817,6 +1866,7 @@
                         BatteryStats.HistoryItem.EVENT_USER_FOREGROUND_START,
                         Integer.toString(msg.arg1), msg.arg1);
                 mSystemServiceManager.switchUser(msg.arg1);
+                mLockToAppRequest.clearPrompt();
                 break;
             }
             case ENTER_ANIMATION_COMPLETE_MSG: {
@@ -1857,7 +1907,7 @@
                 if (memInfo != null) {
                     updateCpuStatsNow();
                     long nativeTotalPss = 0;
-                    synchronized (mProcessCpuThread) {
+                    synchronized (mProcessCpuTracker) {
                         final int N = mProcessCpuTracker.countStats();
                         for (int j=0; j<N; j++) {
                             ProcessCpuTracker.Stats st = mProcessCpuTracker.getStats(j);
@@ -1875,7 +1925,7 @@
                         }
                     }
                     memInfo.readMemInfo();
-                    synchronized (this) {
+                    synchronized (ActivityManagerService.this) {
                         if (DEBUG_PSS) Slog.d(TAG, "Collected native and kernel memory in "
                                 + (SystemClock.uptimeMillis()-start) + "ms");
                         mProcessStats.addSysMemUsageLocked(memInfo.getCachedSizeKb(),
@@ -2146,7 +2196,7 @@
                 return;
             }
 
-            synchronized (mActivityManagerService.mProcessCpuThread) {
+            synchronized (mActivityManagerService.mProcessCpuTracker) {
                 pw.print(mActivityManagerService.mProcessCpuTracker.printCurrentLoad());
                 pw.print(mActivityManagerService.mProcessCpuTracker.printCurrentState(
                         SystemClock.uptimeMillis()));
@@ -2227,9 +2277,6 @@
         mConfigurationSeq = mConfiguration.seq = 1;
         mProcessCpuTracker.init();
 
-        mHasRecents = mContext.getResources().getBoolean(
-                com.android.internal.R.bool.config_hasRecents);
-
         mCompatModePackages = new CompatModePackages(this, systemDir, mHandler);
         mIntentFirewall = new IntentFirewall(new IntentFirewallInterface(), mHandler);
         mStackSupervisor = new ActivityStackSupervisor(this);
@@ -2345,7 +2392,7 @@
     }
 
     void updateCpuStatsNow() {
-        synchronized (mProcessCpuThread) {
+        synchronized (mProcessCpuTracker) {
             mProcessCpuMutexFree.set(false);
             final long now = SystemClock.uptimeMillis();
             boolean haveNewCpuStats = false;
@@ -2799,8 +2846,7 @@
             if (proc.baseProcessTracker != null) {
                 proc.baseProcessTracker.reportCachedKill(proc.pkgList, proc.lastCachedPss);
             }
-            killUnneededProcessLocked(proc, Long.toString(proc.lastCachedPss)
-                    + "k from cached");
+            proc.kill(Long.toString(proc.lastCachedPss) + "k from cached", true);
         } else if (proc != null && !keepIfLarge
                 && mLastMemoryLevel > ProcessStats.ADJ_MEM_FACTOR_NORMAL
                 && proc.setProcState >= ActivityManager.PROCESS_STATE_CACHED_EMPTY) {
@@ -2809,8 +2855,7 @@
                 if (proc.baseProcessTracker != null) {
                     proc.baseProcessTracker.reportCachedKill(proc.pkgList, proc.lastCachedPss);
                 }
-                killUnneededProcessLocked(proc, Long.toString(proc.lastCachedPss)
-                        + "k from cached");
+                proc.kill(Long.toString(proc.lastCachedPss) + "k from cached", true);
             }
         }
         return proc;
@@ -2872,9 +2917,11 @@
             boolean knownToBeDead, int intentFlags, String hostingType, ComponentName hostingName,
             boolean allowWhileBooting, boolean isolated, int isolatedUid, boolean keepIfLarge,
             String abiOverride, String entryPoint, String[] entryPointArgs, Runnable crashHandler) {
+        long startTime = SystemClock.elapsedRealtime();
         ProcessRecord app;
         if (!isolated) {
             app = getProcessRecordLocked(processName, info.uid, keepIfLarge);
+            checkTime(startTime, "startProcess: after getProcessRecord");
         } else {
             // If this is an isolated process, it can't re-use an existing process.
             app = null;
@@ -2896,14 +2943,17 @@
                 if (DEBUG_PROCESSES) Slog.v(TAG, "App already running: " + app);
                 // If this is a new package in the process, add the package to the list
                 app.addPackage(info.packageName, info.versionCode, mProcessStats);
+                checkTime(startTime, "startProcess: done, added package to proc");
                 return app;
             }
 
             // An application record is attached to a previous process,
             // clean it up now.
             if (DEBUG_PROCESSES || DEBUG_CLEANUP) Slog.v(TAG, "App died: " + app);
+            checkTime(startTime, "startProcess: bad proc running, killing");
             Process.killProcessGroup(app.info.uid, app.pid);
             handleAppDiedLocked(app, true, true);
+            checkTime(startTime, "startProcess: done killing old proc");
         }
 
         String hostingNameStr = hostingName != null
@@ -2939,6 +2989,7 @@
         }
 
         if (app == null) {
+            checkTime(startTime, "startProcess: creating new process record");
             app = newProcessRecordLocked(info, processName, isolated, isolatedUid);
             app.crashHandler = crashHandler;
             if (app == null) {
@@ -2950,9 +3001,11 @@
             if (isolated) {
                 mIsolatedProcesses.put(app.uid, app);
             }
+            checkTime(startTime, "startProcess: done creating new process record");
         } else {
             // If this is a new package in the process, add the package to the list
             app.addPackage(info.packageName, info.versionCode, mProcessStats);
+            checkTime(startTime, "startProcess: added package to existing proc");
         }
 
         // If the system is not ready yet, then hold off on starting this
@@ -2964,11 +3017,14 @@
                 mProcessesOnHold.add(app);
             }
             if (DEBUG_PROCESSES) Slog.v(TAG, "System not ready, putting on hold: " + app);
+            checkTime(startTime, "startProcess: returning with proc on hold");
             return app;
         }
 
+        checkTime(startTime, "startProcess: stepping in to startProcess");
         startProcessLocked(
                 app, hostingType, hostingNameStr, abiOverride, entryPoint, entryPointArgs);
+        checkTime(startTime, "startProcess: done starting proc!");
         return (app.pid != 0) ? app : null;
     }
 
@@ -2984,11 +3040,14 @@
 
     private final void startProcessLocked(ProcessRecord app, String hostingType,
             String hostingNameStr, String abiOverride, String entryPoint, String[] entryPointArgs) {
+        long startTime = SystemClock.elapsedRealtime();
         if (app.pid > 0 && app.pid != MY_PID) {
+            checkTime(startTime, "startProcess: removing from pids map");
             synchronized (mPidsSelfLocked) {
                 mPidsSelfLocked.remove(app.pid);
                 mHandler.removeMessages(PROC_START_TIMEOUT_MSG, app);
             }
+            checkTime(startTime, "startProcess: done removing from pids map");
             app.setPid(0);
         }
 
@@ -2996,7 +3055,9 @@
                 "startProcessLocked removing on hold: " + app);
         mProcessesOnHold.remove(app);
 
+        checkTime(startTime, "startProcess: starting to update cpu stats");
         updateCpuStats();
+        checkTime(startTime, "startProcess: done updating cpu stats");
 
         try {
             int uid = app.uid;
@@ -3006,10 +3067,12 @@
             if (!app.isolated) {
                 int[] permGids = null;
                 try {
+                    checkTime(startTime, "startProcess: getting gids from package manager");
                     final PackageManager pm = mContext.getPackageManager();
                     permGids = pm.getPackageGids(app.info.packageName);
 
                     if (Environment.isExternalStorageEmulated()) {
+                        checkTime(startTime, "startProcess: checking external storage perm");
                         if (pm.checkPermission(
                                 android.Manifest.permission.ACCESS_ALL_EXTERNAL_STORAGE,
                                 app.info.packageName) == PERMISSION_GRANTED) {
@@ -3035,6 +3098,7 @@
                 gids[0] = UserHandle.getSharedAppGid(UserHandle.getAppId(uid));
                 gids[1] = UserHandle.getUserGid(UserHandle.getUserId(uid));
             }
+            checkTime(startTime, "startProcess: building args");
             if (mFactoryTest != FactoryTest.FACTORY_TEST_OFF) {
                 if (mFactoryTest == FactoryTest.FACTORY_TEST_LOW_LEVEL
                         && mTopComponent != null
@@ -3074,18 +3138,27 @@
                 requiredAbi = Build.SUPPORTED_ABIS[0];
             }
 
+            String instructionSet = null;
+            if (app.info.primaryCpuAbi != null) {
+                instructionSet = VMRuntime.getInstructionSet(app.info.primaryCpuAbi);
+            }
+
             // Start the process.  It will either succeed and return a result containing
             // the PID of the new process, or else throw a RuntimeException.
             boolean isActivityProcess = (entryPoint == null);
             if (entryPoint == null) entryPoint = "android.app.ActivityThread";
+            checkTime(startTime, "startProcess: asking zygote to start proc");
             Process.ProcessStartResult startResult = Process.start(entryPoint,
                     app.processName, uid, uid, gids, debugFlags, mountExternal,
-                    app.info.targetSdkVersion, app.info.seinfo, requiredAbi, entryPointArgs);
+                    app.info.targetSdkVersion, app.info.seinfo, requiredAbi, instructionSet,
+                    entryPointArgs);
+            checkTime(startTime, "startProcess: returned from zygote!");
 
             if (app.isolated) {
                 mBatteryStatsService.addIsolatedUid(app.uid, app.info.uid);
             }
             mBatteryStatsService.noteProcessStart(app.processName, app.info.uid);
+            checkTime(startTime, "startProcess: done updating battery stats");
 
             EventLog.writeEvent(EventLogTags.AM_PROC_START,
                     UserHandle.getUserId(uid), startResult.pid, uid,
@@ -3096,6 +3169,7 @@
                 Watchdog.getInstance().processStarted(app.processName, startResult.pid);
             }
 
+            checkTime(startTime, "startProcess: building log message");
             StringBuilder buf = mStringBuilder;
             buf.setLength(0);
             buf.append("Start proc ");
@@ -3133,6 +3207,7 @@
             app.usingWrapper = startResult.usingWrapper;
             app.removed = false;
             app.killedByAm = false;
+            checkTime(startTime, "startProcess: starting to update pids map");
             synchronized (mPidsSelfLocked) {
                 this.mPidsSelfLocked.put(startResult.pid, app);
                 if (isActivityProcess) {
@@ -3142,6 +3217,7 @@
                             ? PROC_START_TIMEOUT_WITH_WRAPPER : PROC_START_TIMEOUT);
                 }
             }
+            checkTime(startTime, "startProcess: done updating pids map");
         } catch (RuntimeException e) {
             // XXX do better error recovery.
             app.setPid(0);
@@ -3159,7 +3235,6 @@
         if (resumed) {
             if (mUsageStatsService != null) {
                 mUsageStatsService.reportEvent(component.realActivity, component.userId,
-                        System.currentTimeMillis(),
                         UsageEvents.Event.MOVE_TO_FOREGROUND);
             }
             synchronized (stats) {
@@ -3168,7 +3243,6 @@
         } else {
             if (mUsageStatsService != null) {
                 mUsageStatsService.reportEvent(component.realActivity, component.userId,
-                        System.currentTimeMillis(),
                         UsageEvents.Event.MOVE_TO_BACKGROUND);
             }
             synchronized (stats) {
@@ -3286,7 +3360,8 @@
                     intent.setComponent(new ComponentName(
                             ri.activityInfo.packageName, ri.activityInfo.name));
                     mStackSupervisor.startActivityLocked(null, intent, null, ri.activityInfo,
-                            null, null, null, null, 0, 0, 0, null, 0, null, false, null, null);
+                            null, null, null, null, 0, 0, 0, null, 0, 0, 0, null, false, null, null,
+                            null);
                 }
             }
         }
@@ -3302,6 +3377,16 @@
         }
     }
 
+    void enforceShellRestriction(String restriction, int userHandle) {
+        if (Binder.getCallingUid() == Process.SHELL_UID) {
+            if (userHandle < 0
+                    || mUserManager.hasUserRestriction(restriction, userHandle)) {
+                throw new SecurityException("Shell does not have permission to access user "
+                        + userHandle);
+            }
+        }
+    }
+
     @Override
     public int getFrontActivityScreenCompatMode() {
         enforceNotIsolatedCaller("getFrontActivityScreenCompatMode");
@@ -3411,56 +3496,115 @@
 
     @Override
     public final int startActivity(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo,
-            String resultWho, int requestCode, int startFlags,
-            String profileFile, ParcelFileDescriptor profileFd, Bundle options) {
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, ProfilerInfo profilerInfo, Bundle options) {
         return startActivityAsUser(caller, callingPackage, intent, resolvedType, resultTo,
-                resultWho, requestCode,
-                startFlags, profileFile, profileFd, options, UserHandle.getCallingUserId());
+            resultWho, requestCode, startFlags, profilerInfo, options,
+            UserHandle.getCallingUserId());
     }
 
     @Override
     public final int startActivityAsUser(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo,
-            String resultWho, int requestCode, int startFlags,
-            String profileFile, ParcelFileDescriptor profileFd, Bundle options, int userId) {
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, ProfilerInfo profilerInfo, Bundle options, int userId) {
         enforceNotIsolatedCaller("startActivity");
         userId = handleIncomingUser(Binder.getCallingPid(), Binder.getCallingUid(), userId,
                 false, ALLOW_FULL_ONLY, "startActivity", null);
         // TODO: Switch to user app stacks here.
-        return mStackSupervisor.startActivityMayWait(caller, -1, callingPackage, intent, resolvedType,
-                null, null, resultTo, resultWho, requestCode, startFlags, profileFile, profileFd,
-                null, null, options, userId, null);
+        return mStackSupervisor.startActivityMayWait(caller, -1, callingPackage, intent,
+                resolvedType, null, null, resultTo, resultWho, requestCode, startFlags,
+                profilerInfo, null, null, options, userId, null, null);
+    }
+
+    @Override
+    public final int startActivityAsCaller(IApplicationThread caller, String callingPackage,
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, ProfilerInfo profilerInfo, Bundle options) {
+
+        // This is very dangerous -- it allows you to perform a start activity (including
+        // permission grants) as any app that may launch one of your own activities.  So
+        // we will only allow this to be done from activities that are part of the core framework,
+        // and then only when they are running as the system.
+        final ActivityRecord sourceRecord;
+        final int targetUid;
+        final String targetPackage;
+        synchronized (this) {
+            if (resultTo == null) {
+                throw new SecurityException("Must be called from an activity");
+            }
+            sourceRecord = mStackSupervisor.isInAnyStackLocked(resultTo);
+            if (sourceRecord == null) {
+                throw new SecurityException("Called with bad activity token: " + resultTo);
+            }
+            if (!sourceRecord.info.packageName.equals("android")) {
+                throw new SecurityException(
+                        "Must be called from an activity that is declared in the android package");
+            }
+            if (sourceRecord.app == null) {
+                throw new SecurityException("Called without a process attached to activity");
+            }
+            if (UserHandle.getAppId(sourceRecord.app.uid) != Process.SYSTEM_UID) {
+                // This is still okay, as long as this activity is running under the
+                // uid of the original calling activity.
+                if (sourceRecord.app.uid != sourceRecord.launchedFromUid) {
+                    throw new SecurityException(
+                            "Calling activity in uid " + sourceRecord.app.uid
+                                    + " must be system uid or original calling uid "
+                                    + sourceRecord.launchedFromUid);
+                }
+            }
+            targetUid = sourceRecord.launchedFromUid;
+            targetPackage = sourceRecord.launchedFromPackage;
+        }
+
+        // TODO: Switch to user app stacks here.
+        try {
+            int ret = mStackSupervisor.startActivityMayWait(null, targetUid, targetPackage, intent,
+                    resolvedType, null, null, resultTo, resultWho, requestCode, startFlags, null,
+                    null, null, options, UserHandle.getUserId(sourceRecord.app.uid), null, null);
+            return ret;
+        } catch (SecurityException e) {
+            // XXX need to figure out how to propagate to original app.
+            // A SecurityException here is generally actually a fault of the original
+            // calling activity (such as a fairly granting permissions), so propagate it
+            // back to them.
+            /*
+            StringBuilder msg = new StringBuilder();
+            msg.append("While launching");
+            msg.append(intent.toString());
+            msg.append(": ");
+            msg.append(e.getMessage());
+            */
+            throw e;
+        }
     }
 
     @Override
     public final WaitResult startActivityAndWait(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo,
-            String resultWho, int requestCode, int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) {
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, ProfilerInfo profilerInfo, Bundle options, int userId) {
         enforceNotIsolatedCaller("startActivityAndWait");
         userId = handleIncomingUser(Binder.getCallingPid(), Binder.getCallingUid(), userId,
                 false, ALLOW_FULL_ONLY, "startActivityAndWait", null);
         WaitResult res = new WaitResult();
         // TODO: Switch to user app stacks here.
         mStackSupervisor.startActivityMayWait(caller, -1, callingPackage, intent, resolvedType,
-                null, null, resultTo, resultWho, requestCode, startFlags, profileFile, profileFd,
-                res, null, options, userId, null);
+                null, null, resultTo, resultWho, requestCode, startFlags, profilerInfo, res, null,
+                options, userId, null, null);
         return res;
     }
 
     @Override
     public final int startActivityWithConfig(IApplicationThread caller, String callingPackage,
-            Intent intent, String resolvedType, IBinder resultTo,
-            String resultWho, int requestCode, int startFlags, Configuration config,
-            Bundle options, int userId) {
+            Intent intent, String resolvedType, IBinder resultTo, String resultWho, int requestCode,
+            int startFlags, Configuration config, Bundle options, int userId) {
         enforceNotIsolatedCaller("startActivityWithConfig");
         userId = handleIncomingUser(Binder.getCallingPid(), Binder.getCallingUid(), userId,
                 false, ALLOW_FULL_ONLY, "startActivityWithConfig", null);
         // TODO: Switch to user app stacks here.
         int ret = mStackSupervisor.startActivityMayWait(caller, -1, callingPackage, intent,
                 resolvedType, null, null, resultTo, resultWho, requestCode, startFlags,
-                null, null, null, config, options, userId, null);
+                null, null, config, options, userId, null, null);
         return ret;
     }
 
@@ -3499,8 +3643,8 @@
     @Override
     public int startVoiceActivity(String callingPackage, int callingPid, int callingUid,
             Intent intent, String resolvedType, IVoiceInteractionSession session,
-            IVoiceInteractor interactor, int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, Bundle options, int userId) {
+            IVoiceInteractor interactor, int startFlags, ProfilerInfo profilerInfo,
+            Bundle options, int userId) {
         if (checkCallingPermission(Manifest.permission.BIND_VOICE_INTERACTION)
                 != PackageManager.PERMISSION_GRANTED) {
             String msg = "Permission Denial: startVoiceActivity() from pid="
@@ -3517,8 +3661,8 @@
                 false, ALLOW_FULL_ONLY, "startVoiceActivity", null);
         // TODO: Switch to user app stacks here.
         return mStackSupervisor.startActivityMayWait(null, callingUid, callingPackage, intent,
-                resolvedType, session, interactor, null, null, 0, startFlags,
-                profileFile, profileFd, null, null, options, userId, null);
+                resolvedType, session, interactor, null, null, 0, startFlags, profilerInfo, null,
+                null, options, userId, null, null);
     }
 
     @Override
@@ -3615,8 +3759,8 @@
             final long origId = Binder.clearCallingIdentity();
             int res = mStackSupervisor.startActivityLocked(r.app.thread, intent,
                     r.resolvedType, aInfo, null, null, resultTo != null ? resultTo.appToken : null,
-                    resultWho, requestCode, -1, r.launchedFromUid, r.launchedFromPackage, 0,
-                    options, false, null, null);
+                    resultWho, requestCode, -1, r.launchedFromUid, r.launchedFromPackage,
+                    -1, r.launchedFromUid, 0, options, false, null, null, null);
             Binder.restoreCallingIdentity(origId);
 
             r.finishing = wasFinishing;
@@ -3635,36 +3779,42 @@
             Slog.w(TAG, msg);
             throw new SecurityException(msg);
         }
+        return startActivityFromRecentsInner(taskId, options);
+    }
+
+    final int startActivityFromRecentsInner(int taskId, Bundle options) {
+        final TaskRecord task;
         final int callingUid;
         final String callingPackage;
         final Intent intent;
         final int userId;
         synchronized (this) {
-            final TaskRecord task = recentTaskForIdLocked(taskId);
+            task = recentTaskForIdLocked(taskId);
             if (task == null) {
-                throw new ActivityNotFoundException("Task " + taskId + " not found.");
+                throw new IllegalArgumentException("Task " + taskId + " not found.");
             }
             callingUid = task.mCallingUid;
             callingPackage = task.mCallingPackage;
             intent = task.intent;
+            intent.addFlags(Intent.FLAG_ACTIVITY_LAUNCHED_FROM_HISTORY);
             userId = task.userId;
         }
         return startActivityInPackage(callingUid, callingPackage, intent, null, null, null, 0, 0,
-                options, userId, null);
+                options, userId, null, task);
     }
 
     final int startActivityInPackage(int uid, String callingPackage,
             Intent intent, String resolvedType, IBinder resultTo,
             String resultWho, int requestCode, int startFlags, Bundle options, int userId,
-                    IActivityContainer container) {
+            IActivityContainer container, TaskRecord inTask) {
 
         userId = handleIncomingUser(Binder.getCallingPid(), Binder.getCallingUid(), userId,
                 false, ALLOW_FULL_ONLY, "startActivityInPackage", null);
 
         // TODO: Switch to user app stacks here.
-        int ret = mStackSupervisor.startActivityMayWait(null, uid, callingPackage, intent, resolvedType,
-                null, null, resultTo, resultWho, requestCode, startFlags,
-                null, null, null, null, options, userId, container);
+        int ret = mStackSupervisor.startActivityMayWait(null, uid, callingPackage, intent,
+                resolvedType, null, null, resultTo, resultWho, requestCode, startFlags,
+                null, null, null, options, userId, container, inTask);
         return ret;
     }
 
@@ -3705,8 +3855,8 @@
             if (tr.userId == userId) {
                 if(DEBUG_TASKS) Slog.i(TAG, "remove RecentTask " + tr
                         + " when finishing user" + userId);
-                tr.disposeThumbnail();
                 mRecentTasks.remove(i);
+                tr.removedFromRecents(mTaskPersister);
             }
         }
 
@@ -3714,20 +3864,438 @@
         mTaskPersister.wakeup(null, true);
     }
 
+    // Sort by taskId
+    private Comparator<TaskRecord> mTaskRecordComparator = new Comparator<TaskRecord>() {
+        @Override
+        public int compare(TaskRecord lhs, TaskRecord rhs) {
+            return rhs.taskId - lhs.taskId;
+        }
+    };
+
+    // Extract the affiliates of the chain containing mRecentTasks[start].
+    private int processNextAffiliateChain(int start) {
+        final TaskRecord startTask = mRecentTasks.get(start);
+        final int affiliateId = startTask.mAffiliatedTaskId;
+
+        // Quick identification of isolated tasks. I.e. those not launched behind.
+        if (startTask.taskId == affiliateId && startTask.mPrevAffiliate == null &&
+                startTask.mNextAffiliate == null) {
+            // There is still a slim chance that there are other tasks that point to this task
+            // and that the chain is so messed up that this task no longer points to them but
+            // the gain of this optimization outweighs the risk.
+            startTask.inRecents = true;
+            return start + 1;
+        }
+
+        // Remove all tasks that are affiliated to affiliateId and put them in mTmpRecents.
+        mTmpRecents.clear();
+        for (int i = mRecentTasks.size() - 1; i >= start; --i) {
+            final TaskRecord task = mRecentTasks.get(i);
+            if (task.mAffiliatedTaskId == affiliateId) {
+                mRecentTasks.remove(i);
+                mTmpRecents.add(task);
+            }
+        }
+
+        // Sort them all by taskId. That is the order they were create in and that order will
+        // always be correct.
+        Collections.sort(mTmpRecents, mTaskRecordComparator);
+
+        // Go through and fix up the linked list.
+        // The first one is the end of the chain and has no next.
+        final TaskRecord first = mTmpRecents.get(0);
+        first.inRecents = true;
+        if (first.mNextAffiliate != null) {
+            Slog.w(TAG, "Link error 1 first.next=" + first.mNextAffiliate);
+            first.setNextAffiliate(null);
+            mTaskPersister.wakeup(first, false);
+        }
+        // Everything in the middle is doubly linked from next to prev.
+        final int tmpSize = mTmpRecents.size();
+        for (int i = 0; i < tmpSize - 1; ++i) {
+            final TaskRecord next = mTmpRecents.get(i);
+            final TaskRecord prev = mTmpRecents.get(i + 1);
+            if (next.mPrevAffiliate != prev) {
+                Slog.w(TAG, "Link error 2 next=" + next + " prev=" + next.mPrevAffiliate +
+                        " setting prev=" + prev);
+                next.setPrevAffiliate(prev);
+                mTaskPersister.wakeup(next, false);
+            }
+            if (prev.mNextAffiliate != next) {
+                Slog.w(TAG, "Link error 3 prev=" + prev + " next=" + prev.mNextAffiliate +
+                        " setting next=" + next);
+                prev.setNextAffiliate(next);
+                mTaskPersister.wakeup(prev, false);
+            }
+            prev.inRecents = true;
+        }
+        // The last one is the beginning of the list and has no prev.
+        final TaskRecord last = mTmpRecents.get(tmpSize - 1);
+        if (last.mPrevAffiliate != null) {
+            Slog.w(TAG, "Link error 4 last.prev=" + last.mPrevAffiliate);
+            last.setPrevAffiliate(null);
+            mTaskPersister.wakeup(last, false);
+        }
+
+        // Insert the group back into mRecentTasks at start.
+        mRecentTasks.addAll(start, mTmpRecents);
+
+        // Let the caller know where we left off.
+        return start + tmpSize;
+    }
+
+    /**
+     * Update the recent tasks lists: make sure tasks should still be here (their
+     * applications / activities still exist), update their availability, fixup ordering
+     * of affiliations.
+     */
+    void cleanupRecentTasksLocked(int userId) {
+        if (mRecentTasks == null) {
+            // Happens when called from the packagemanager broadcast before boot.
+            return;
+        }
+
+        final HashMap<ComponentName, ActivityInfo> availActCache = new HashMap<>();
+        final HashMap<String, ApplicationInfo> availAppCache = new HashMap<>();
+        final IPackageManager pm = AppGlobals.getPackageManager();
+        final ActivityInfo dummyAct = new ActivityInfo();
+        final ApplicationInfo dummyApp = new ApplicationInfo();
+
+        int N = mRecentTasks.size();
+
+        int[] users = userId == UserHandle.USER_ALL
+                ? getUsersLocked() : new int[] { userId };
+        for (int user : users) {
+            for (int i = 0; i < N; i++) {
+                TaskRecord task = mRecentTasks.get(i);
+                if (task.userId != user) {
+                    // Only look at tasks for the user ID of interest.
+                    continue;
+                }
+                if (task.autoRemoveRecents && task.getTopActivity() == null) {
+                    // This situation is broken, and we should just get rid of it now.
+                    mRecentTasks.remove(i);
+                    task.removedFromRecents(mTaskPersister);
+                    i--;
+                    N--;
+                    Slog.w(TAG, "Removing auto-remove without activity: " + task);
+                    continue;
+                }
+                // Check whether this activity is currently available.
+                if (task.realActivity != null) {
+                    ActivityInfo ai = availActCache.get(task.realActivity);
+                    if (ai == null) {
+                        try {
+                            ai = pm.getActivityInfo(task.realActivity,
+                                    PackageManager.GET_UNINSTALLED_PACKAGES
+                                    | PackageManager.GET_DISABLED_COMPONENTS, user);
+                        } catch (RemoteException e) {
+                            // Will never happen.
+                            continue;
+                        }
+                        if (ai == null) {
+                            ai = dummyAct;
+                        }
+                        availActCache.put(task.realActivity, ai);
+                    }
+                    if (ai == dummyAct) {
+                        // This could be either because the activity no longer exists, or the
+                        // app is temporarily gone.  For the former we want to remove the recents
+                        // entry; for the latter we want to mark it as unavailable.
+                        ApplicationInfo app = availAppCache.get(task.realActivity.getPackageName());
+                        if (app == null) {
+                            try {
+                                app = pm.getApplicationInfo(task.realActivity.getPackageName(),
+                                        PackageManager.GET_UNINSTALLED_PACKAGES
+                                        | PackageManager.GET_DISABLED_COMPONENTS, user);
+                            } catch (RemoteException e) {
+                                // Will never happen.
+                                continue;
+                            }
+                            if (app == null) {
+                                app = dummyApp;
+                            }
+                            availAppCache.put(task.realActivity.getPackageName(), app);
+                        }
+                        if (app == dummyApp || (app.flags&ApplicationInfo.FLAG_INSTALLED) == 0) {
+                            // Doesn't exist any more!  Good-bye.
+                            mRecentTasks.remove(i);
+                            task.removedFromRecents(mTaskPersister);
+                            i--;
+                            N--;
+                            Slog.w(TAG, "Removing no longer valid recent: " + task);
+                            continue;
+                        } else {
+                            // Otherwise just not available for now.
+                            if (task.isAvailable) {
+                                if (DEBUG_RECENTS) Slog.d(TAG, "Making recent unavailable: "
+                                        + task);
+                            }
+                            task.isAvailable = false;
+                        }
+                    } else {
+                        if (!ai.enabled || !ai.applicationInfo.enabled
+                                || (ai.applicationInfo.flags&ApplicationInfo.FLAG_INSTALLED) == 0) {
+                            if (task.isAvailable) {
+                                if (DEBUG_RECENTS) Slog.d(TAG, "Making recent unavailable: "
+                                        + task + " (enabled=" + ai.enabled + "/"
+                                        + ai.applicationInfo.enabled +  " flags="
+                                        + Integer.toHexString(ai.applicationInfo.flags) + ")");
+                            }
+                            task.isAvailable = false;
+                        } else {
+                            if (!task.isAvailable) {
+                                if (DEBUG_RECENTS) Slog.d(TAG, "Making recent available: "
+                                        + task);
+                            }
+                            task.isAvailable = true;
+                        }
+                    }
+                }
+            }
+        }
+
+        // Verify the affiliate chain for each task.
+        for (int i = 0; i < N; i = processNextAffiliateChain(i)) {
+        }
+
+        mTmpRecents.clear();
+        // mRecentTasks is now in sorted, affiliated order.
+    }
+
+    private final boolean moveAffiliatedTasksToFront(TaskRecord task, int taskIndex) {
+        int N = mRecentTasks.size();
+        TaskRecord top = task;
+        int topIndex = taskIndex;
+        while (top.mNextAffiliate != null && topIndex > 0) {
+            top = top.mNextAffiliate;
+            topIndex--;
+        }
+        if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: adding affilliates starting at "
+                + topIndex + " from intial " + taskIndex);
+        // Find the end of the chain, doing a sanity check along the way.
+        boolean sane = top.mAffiliatedTaskId == task.mAffiliatedTaskId;
+        int endIndex = topIndex;
+        TaskRecord prev = top;
+        while (endIndex < N) {
+            TaskRecord cur = mRecentTasks.get(endIndex);
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: looking at next chain @"
+                    + endIndex + " " + cur);
+            if (cur == top) {
+                // Verify start of the chain.
+                if (cur.mNextAffiliate != null || cur.mNextAffiliateTaskId != -1) {
+                    Slog.wtf(TAG, "Bad chain @" + endIndex
+                            + ": first task has next affiliate: " + prev);
+                    sane = false;
+                    break;
+                }
+            } else {
+                // Verify middle of the chain's next points back to the one before.
+                if (cur.mNextAffiliate != prev
+                        || cur.mNextAffiliateTaskId != prev.taskId) {
+                    Slog.wtf(TAG, "Bad chain @" + endIndex
+                            + ": middle task " + cur + " @" + endIndex
+                            + " has bad next affiliate "
+                            + cur.mNextAffiliate + " id " + cur.mNextAffiliateTaskId
+                            + ", expected " + prev);
+                    sane = false;
+                    break;
+                }
+            }
+            if (cur.mPrevAffiliateTaskId == -1) {
+                // Chain ends here.
+                if (cur.mPrevAffiliate != null) {
+                    Slog.wtf(TAG, "Bad chain @" + endIndex
+                            + ": last task " + cur + " has previous affiliate "
+                            + cur.mPrevAffiliate);
+                    sane = false;
+                }
+                if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: end of chain @" + endIndex);
+                break;
+            } else {
+                // Verify middle of the chain's prev points to a valid item.
+                if (cur.mPrevAffiliate == null) {
+                    Slog.wtf(TAG, "Bad chain @" + endIndex
+                            + ": task " + cur + " has previous affiliate "
+                            + cur.mPrevAffiliate + " but should be id "
+                            + cur.mPrevAffiliate);
+                    sane = false;
+                    break;
+                }
+            }
+            if (cur.mAffiliatedTaskId != task.mAffiliatedTaskId) {
+                Slog.wtf(TAG, "Bad chain @" + endIndex
+                        + ": task " + cur + " has affiliated id "
+                        + cur.mAffiliatedTaskId + " but should be "
+                        + task.mAffiliatedTaskId);
+                sane = false;
+                break;
+            }
+            prev = cur;
+            endIndex++;
+            if (endIndex >= N) {
+                Slog.wtf(TAG, "Bad chain ran off index " + endIndex
+                        + ": last task " + prev);
+                sane = false;
+                break;
+            }
+        }
+        if (sane) {
+            if (endIndex < taskIndex) {
+                Slog.wtf(TAG, "Bad chain @" + endIndex
+                        + ": did not extend to task " + task + " @" + taskIndex);
+                sane = false;
+            }
+        }
+        if (sane) {
+            // All looks good, we can just move all of the affiliated tasks
+            // to the top.
+            for (int i=topIndex; i<=endIndex; i++) {
+                if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: moving affiliated " + task
+                        + " from " + i + " to " + (i-topIndex));
+                TaskRecord cur = mRecentTasks.remove(i);
+                mRecentTasks.add(i-topIndex, cur);
+            }
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: done moving tasks  " +  topIndex
+                    + " to " + endIndex);
+            return true;
+        }
+
+        // Whoops, couldn't do it.
+        return false;
+    }
+
     final void addRecentTaskLocked(TaskRecord task) {
+        final boolean isAffiliated = task.mAffiliatedTaskId != task.taskId
+                || task.mNextAffiliateTaskId != -1 || task.mPrevAffiliateTaskId != -1;
+
         int N = mRecentTasks.size();
         // Quick case: check if the top-most recent task is the same.
-        if (N > 0 && mRecentTasks.get(0) == task) {
+        if (!isAffiliated && N > 0 && mRecentTasks.get(0) == task) {
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: already at top: " + task);
+            return;
+        }
+        // Another quick case: check if this is part of a set of affiliated
+        // tasks that are at the top.
+        if (isAffiliated && N > 0 && task.inRecents
+                && task.mAffiliatedTaskId == mRecentTasks.get(0).mAffiliatedTaskId) {
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: affiliated " + mRecentTasks.get(0)
+                    + " at top when adding " + task);
             return;
         }
         // Another quick case: never add voice sessions.
         if (task.voiceSession != null) {
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: not adding voice interaction " + task);
             return;
         }
-        // Remove any existing entries that are the same kind of task.
+
+        boolean needAffiliationFix = false;
+
+        // Slightly less quick case: the task is already in recents, so all we need
+        // to do is move it.
+        if (task.inRecents) {
+            int taskIndex = mRecentTasks.indexOf(task);
+            if (taskIndex >= 0) {
+                if (!isAffiliated) {
+                    // Simple case: this is not an affiliated task, so we just move it to the front.
+                    mRecentTasks.remove(taskIndex);
+                    mRecentTasks.add(0, task);
+                    notifyTaskPersisterLocked(task, false);
+                    if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: moving to top " + task
+                            + " from " + taskIndex);
+                    return;
+                } else {
+                    // More complicated: need to keep all affiliated tasks together.
+                    if (moveAffiliatedTasksToFront(task, taskIndex)) {
+                        // All went well.
+                        return;
+                    }
+
+                    // Uh oh...  something bad in the affiliation chain, try to rebuild
+                    // everything and then go through our general path of adding a new task.
+                    needAffiliationFix = true;
+                }
+            } else {
+                Slog.wtf(TAG, "Task with inRecent not in recents: " + task);
+                needAffiliationFix = true;
+            }
+        }
+
+        if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: trimming tasks for " + task);
+        trimRecentsForTask(task, true);
+
+        N = mRecentTasks.size();
+        while (N >= ActivityManager.getMaxRecentTasksStatic()) {
+            final TaskRecord tr = mRecentTasks.remove(N - 1);
+            tr.removedFromRecents(mTaskPersister);
+            N--;
+        }
+        task.inRecents = true;
+        if (!isAffiliated || needAffiliationFix) {
+            // If this is a simple non-affiliated task, or we had some failure trying to
+            // handle it as part of an affilated task, then just place it at the top.
+            mRecentTasks.add(0, task);
+        } else if (isAffiliated) {
+            // If this is a new affiliated task, then move all of the affiliated tasks
+            // to the front and insert this new one.
+            TaskRecord other = task.mNextAffiliate;
+            if (other == null) {
+                other = task.mPrevAffiliate;
+            }
+            if (other != null) {
+                int otherIndex = mRecentTasks.indexOf(other);
+                if (otherIndex >= 0) {
+                    // Insert new task at appropriate location.
+                    int taskIndex;
+                    if (other == task.mNextAffiliate) {
+                        // We found the index of our next affiliation, which is who is
+                        // before us in the list, so add after that point.
+                        taskIndex = otherIndex+1;
+                    } else {
+                        // We found the index of our previous affiliation, which is who is
+                        // after us in the list, so add at their position.
+                        taskIndex = otherIndex;
+                    }
+                    if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: new affiliated task added at "
+                            + taskIndex + ": " + task);
+                    mRecentTasks.add(taskIndex, task);
+
+                    // Now move everything to the front.
+                    if (moveAffiliatedTasksToFront(task, taskIndex)) {
+                        // All went well.
+                        return;
+                    }
+
+                    // Uh oh...  something bad in the affiliation chain, try to rebuild
+                    // everything and then go through our general path of adding a new task.
+                    needAffiliationFix = true;
+                } else {
+                    if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: couldn't find other affiliation "
+                            + other);
+                    needAffiliationFix = true;
+                }
+            } else {
+                if (DEBUG_RECENTS) Slog.d(TAG,
+                        "addRecent: adding affiliated task without next/prev:" + task);
+                needAffiliationFix = true;
+            }
+        }
+        if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: adding " + task);
+
+        if (needAffiliationFix) {
+            if (DEBUG_RECENTS) Slog.d(TAG, "addRecent: regrouping affiliations");
+            cleanupRecentTasksLocked(task.userId);
+        }
+    }
+
+    /**
+     * If needed, remove oldest existing entries in recents that are for the same kind
+     * of task as the given one.
+     */
+    int trimRecentsForTask(TaskRecord task, boolean doTrim) {
+        int N = mRecentTasks.size();
         final Intent intent = task.intent;
         final boolean document = intent != null && intent.isDocument();
-        final ComponentName comp = intent.getComponent();
 
         int maxRecents = task.maxRecents - 1;
         for (int i=0; i<N; i++) {
@@ -3759,13 +4327,19 @@
                 }
             }
 
+            if (!doTrim) {
+                // If the caller is not actually asking for a trim, just tell them we reached
+                // a point where the trim would happen.
+                return i;
+            }
+
             // Either task and tr are the same or, their affinities match or their intents match
             // and neither of them is a document, or they are documents using the same activity
             // and their maxRecents has been reached.
             tr.disposeThumbnail();
             mRecentTasks.remove(i);
             if (task != tr) {
-                tr.closeRecentsChain();
+                tr.removedFromRecents(mTaskPersister);
             }
             i--;
             N--;
@@ -3776,12 +4350,8 @@
             }
             notifyTaskPersisterLocked(tr, false);
         }
-        if (N >= MAX_RECENT_TASKS) {
-            final TaskRecord tr = mRecentTasks.remove(N - 1);
-            tr.disposeThumbnail();
-            tr.closeRecentsChain();
-        }
-        mRecentTasks.add(0, task);
+
+        return -1;
     }
 
     @Override
@@ -4041,6 +4611,35 @@
     }
 
     @Override
+    public boolean releaseActivityInstance(IBinder token) {
+        synchronized(this) {
+            final long origId = Binder.clearCallingIdentity();
+            try {
+                ActivityRecord r = ActivityRecord.isInStackLocked(token);
+                if (r.task == null || r.task.stack == null) {
+                    return false;
+                }
+                return r.task.stack.safelyDestroyActivityLocked(r, "app-req");
+            } finally {
+                Binder.restoreCallingIdentity(origId);
+            }
+        }
+    }
+
+    @Override
+    public void releaseSomeActivities(IApplicationThread appInt) {
+        synchronized(this) {
+            final long origId = Binder.clearCallingIdentity();
+            try {
+                ProcessRecord app = getRecordForAppLocked(appInt);
+                mStackSupervisor.releaseSomeActivitiesLocked(app, "low-mem");
+            } finally {
+                Binder.restoreCallingIdentity(origId);
+            }
+        }
+    }
+
+    @Override
     public boolean willActivityBeVisible(IBinder token) {
         synchronized(this) {
             ActivityStack stack = ActivityRecord.getStackLocked(token);
@@ -4274,7 +4873,7 @@
         try {
             File tracesDir = tracesFile.getParentFile();
             if (!tracesDir.exists()) {
-                tracesFile.mkdirs();
+                tracesDir.mkdirs();
                 if (!SELinux.restorecon(tracesDir)) {
                     return null;
                 }
@@ -4384,7 +4983,7 @@
             final File tracesTmp = new File(tracesDir, "__tmp__");
             try {
                 if (!tracesDir.exists()) {
-                    tracesFile.mkdirs();
+                    tracesDir.mkdirs();
                     if (!SELinux.restorecon(tracesDir.getPath())) {
                         return;
                     }
@@ -4454,8 +5053,7 @@
                 // 0 == continue, -1 = kill process immediately
                 int res = mController.appEarlyNotResponding(app.processName, app.pid, annotation);
                 if (res < 0 && app.pid != MY_PID) {
-                    Process.killProcess(app.pid);
-                    Process.killProcessGroup(app.info.uid, app.pid);
+                    app.kill("anr", true);
                 }
             } catch (RemoteException e) {
                 mController = null;
@@ -4537,7 +5135,7 @@
         String cpuInfo = null;
         if (MONITOR_CPU_USAGE) {
             updateCpuStatsNow();
-            synchronized (mProcessCpuThread) {
+            synchronized (mProcessCpuTracker) {
                 cpuInfo = mProcessCpuTracker.printCurrentState(anrTime);
             }
             info.append(processCpuTracker.printCurrentLoad());
@@ -4561,8 +5159,7 @@
                 int res = mController.appNotResponding(app.processName, app.pid, info.toString());
                 if (res != 0) {
                     if (res < 0 && app.pid != MY_PID) {
-                        Process.killProcess(app.pid);
-                        Process.killProcessGroup(app.info.uid, app.pid);
+                        app.kill("anr", true);
                     } else {
                         synchronized (this) {
                             mServices.scheduleServiceTimeoutLocked(app);
@@ -4582,7 +5179,7 @@
 
         synchronized (this) {
             if (!showBackground && !app.isInterestingToUserLocked() && app.pid != MY_PID) {
-                killUnneededProcessLocked(app, "background ANR");
+                app.kill("bg anr", true);
                 return;
             }
 
@@ -5306,8 +5903,7 @@
             if (app.isolated) {
                 mBatteryStatsService.removeIsolatedUid(app.uid, app.info.uid);
             }
-            killUnneededProcessLocked(app, reason);
-            Process.killProcessGroup(app.info.uid, app.pid);
+            app.kill(reason, true);
             handleAppDiedLocked(app, true, allowRestart);
             removeLruProcessLocked(app);
 
@@ -5355,7 +5951,7 @@
             checkAppInLaunchingProvidersLocked(app, true);
             // Take care of any services that are waiting for the process.
             mServices.processStartTimedOutLocked(app);
-            killUnneededProcessLocked(app, "start timeout");
+            app.kill("start timeout", true);
             if (mBackupTarget != null && mBackupTarget.app.pid == pid) {
                 Slog.w(TAG, "Unattached app died before backup, skipping");
                 try {
@@ -5467,11 +6063,13 @@
             }
             String profileFile = app.instrumentationProfileFile;
             ParcelFileDescriptor profileFd = null;
+            int samplingInterval = 0;
             boolean profileAutoStop = false;
             if (mProfileApp != null && mProfileApp.equals(processName)) {
                 mProfileProc = app;
                 profileFile = mProfileFile;
                 profileFd = mProfileFd;
+                samplingInterval = mSamplingInterval;
                 profileAutoStop = mAutoStopProfiler;
             }
             boolean enableOpenGlTrace = false;
@@ -5502,9 +6100,10 @@
             if (profileFd != null) {
                 profileFd = profileFd.dup();
             }
-            thread.bindApplication(processName, appInfo, providers,
-                    app.instrumentationClass, profileFile, profileFd, profileAutoStop,
-                    app.instrumentationArguments, app.instrumentationWatcher,
+            ProfilerInfo profilerInfo = profileFile == null ? null
+                    : new ProfilerInfo(profileFile, profileFd, samplingInterval, profileAutoStop);
+            thread.bindApplication(processName, appInfo, providers, app.instrumentationClass,
+                    profilerInfo, app.instrumentationArguments, app.instrumentationWatcher,
                     app.instrumentationUiAutomationConnection, testMode, enableOpenGlTrace,
                     isRestrictedBackupMode || !normalMode, app.persistent,
                     new Configuration(mConfiguration), app.compat, getCommonServicesLocked(),
@@ -5650,6 +6249,7 @@
             synchronized (this) {
                 if (DEBUG_LOCKSCREEN) logLockScreen("");
                 mWindowManager.keyguardWaitingForActivityDrawn();
+                mKeyguardWaitingForDraw = true;
             }
         } finally {
             Binder.restoreCallingIdentity(token);
@@ -5657,6 +6257,14 @@
     }
 
     final void finishBooting() {
+        synchronized (this) {
+            if (!mBootAnimationComplete) {
+                mCallFinishBooting = true;
+                return;
+            }
+            mCallFinishBooting = false;
+        }
+
         // Register receivers to handle package update events
         mPackageMonitor.register(mContext, Looper.getMainLooper(), false);
 
@@ -5715,6 +6323,18 @@
         }
     }
 
+    @Override
+    public void bootAnimationComplete() {
+        final boolean callFinishBooting;
+        synchronized (this) {
+            callFinishBooting = mCallFinishBooting;
+            mBootAnimationComplete = true;
+        }
+        if (callFinishBooting) {
+            finishBooting();
+        }
+    }
+
     final void ensureBootCompleted() {
         boolean booting;
         boolean enableScreen;
@@ -5747,12 +6367,12 @@
     }
 
     @Override
-    public final void activityPaused(IBinder token, PersistableBundle persistentState) {
+    public final void activityPaused(IBinder token) {
         final long origId = Binder.clearCallingIdentity();
         synchronized(this) {
             ActivityStack stack = ActivityRecord.getStackLocked(token);
             if (stack != null) {
-                stack.activityPausedLocked(token, false, persistentState);
+                stack.activityPausedLocked(token, false);
             }
         }
         Binder.restoreCallingIdentity(origId);
@@ -6501,6 +7121,10 @@
         return false;
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public int checkUriPermission(Uri uri, int pid, int uid,
             final int modeFlags, int userId) {
@@ -6653,6 +7277,10 @@
         return targetUid;
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public int checkGrantUriPermission(int callingUid, String targetPkg, Uri uri,
             final int modeFlags, int userId) {
@@ -6837,6 +7465,10 @@
         grantUriPermissionUncheckedFromIntentLocked(needed, owner);
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public void grantUriPermission(IApplicationThread caller, String targetPkg, Uri uri,
             final int modeFlags, int userId) {
@@ -6896,12 +7528,33 @@
 
         // Does the caller have this permission on the URI?
         if (!checkHoldingPermissionsLocked(pm, pi, grantUri, callingUid, modeFlags)) {
-            // Right now, if you are not the original owner of the permission,
-            // you are not allowed to revoke it.
-            //if (!checkUriPermissionLocked(uri, callingUid, modeFlags)) {
-                throw new SecurityException("Uid " + callingUid
-                        + " does not have permission to uri " + grantUri);
-            //}
+            // Have they don't have direct access to the URI, then revoke any URI
+            // permissions that have been granted to them.
+            final ArrayMap<GrantUri, UriPermission> perms = mGrantedUriPermissions.get(callingUid);
+            if (perms != null) {
+                boolean persistChanged = false;
+                for (Iterator<UriPermission> it = perms.values().iterator(); it.hasNext();) {
+                    final UriPermission perm = it.next();
+                    if (perm.uri.sourceUserId == grantUri.sourceUserId
+                            && perm.uri.uri.isPathPrefixMatch(grantUri.uri)) {
+                        if (DEBUG_URI_PERMISSION)
+                            Slog.v(TAG,
+                                    "Revoking " + perm.targetUid + " permission to " + perm.uri);
+                        persistChanged |= perm.revokeModes(
+                                modeFlags | Intent.FLAG_GRANT_PERSISTABLE_URI_PERMISSION);
+                        if (perm.modeFlags == 0) {
+                            it.remove();
+                        }
+                    }
+                }
+                if (perms.isEmpty()) {
+                    mGrantedUriPermissions.remove(callingUid);
+                }
+                if (persistChanged) {
+                    schedulePersistUriGrants();
+                }
+            }
+            return;
         }
 
         boolean persistChanged = false;
@@ -6939,6 +7592,10 @@
         }
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public void revokeUriPermission(IApplicationThread caller, Uri uri, final int modeFlags,
             int userId) {
@@ -7037,9 +7694,16 @@
         }
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param sourceUserId The userId in which the uri is to be resolved.
+     * @param targetUserId The userId of the app that receives the grant.
+     */
     @Override
     public void grantUriPermissionFromOwner(IBinder token, int fromUid, String targetPkg, Uri uri,
             final int modeFlags, int sourceUserId, int targetUserId) {
+        targetUserId = handleIncomingUser(Binder.getCallingPid(), Binder.getCallingUid(),
+                targetUserId, false, ALLOW_FULL_ONLY, "grantUriPermissionFromOwner", null);
         synchronized(this) {
             UriPermissionOwner owner = UriPermissionOwner.fromExternalToken(token);
             if (owner == null) {
@@ -7064,6 +7728,10 @@
         }
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public void revokeUriPermissionFromOwner(IBinder token, Uri uri, int mode, int userId) {
         synchronized(this) {
@@ -7204,6 +7872,10 @@
         }
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public void takePersistableUriPermission(Uri uri, final int modeFlags, int userId) {
         enforceNotIsolatedCaller("takePersistableUriPermission");
@@ -7246,6 +7918,10 @@
         }
     }
 
+    /**
+     * @param uri This uri must NOT contain an embedded userId.
+     * @param userId The userId in which the uri is to be resolved.
+     */
     @Override
     public void releasePersistableUriPermission(Uri uri, final int modeFlags, int userId) {
         enforceNotIsolatedCaller("releasePersistableUriPermission");
@@ -7402,18 +8078,10 @@
     // =========================================================
 
     @Override
-    public List<IAppTask> getAppTasks() {
-        final PackageManager pm = mContext.getPackageManager();
+    public List<IAppTask> getAppTasks(String callingPackage) {
         int callingUid = Binder.getCallingUid();
         long ident = Binder.clearCallingIdentity();
 
-        // Compose the list of packages for this id to test against
-        HashSet<String> packages = new HashSet<String>();
-        String[] uidPackages = pm.getPackagesForUid(callingUid);
-        for (int i = 0; i < uidPackages.length; i++) {
-            packages.add(uidPackages[i]);
-        }
-
         synchronized(this) {
             ArrayList<IAppTask> list = new ArrayList<IAppTask>();
             try {
@@ -7422,13 +8090,21 @@
                 final int N = mRecentTasks.size();
                 for (int i = 0; i < N; i++) {
                     TaskRecord tr = mRecentTasks.get(i);
-                    // Skip tasks that do not match the package name
-                    if (packages.contains(tr.getBaseIntent().getComponent().getPackageName())) {
-                        ActivityManager.RecentTaskInfo taskInfo =
-                                createRecentTaskInfoFromTaskRecord(tr);
-                        AppTaskImpl taskImpl = new AppTaskImpl(taskInfo.persistentId, callingUid);
-                        list.add(taskImpl);
+                    // Skip tasks that do not match the caller.  We don't need to verify
+                    // callingPackage, because we are also limiting to callingUid and know
+                    // that will limit to the correct security sandbox.
+                    if (tr.effectiveUid != callingUid) {
+                        continue;
                     }
+                    Intent intent = tr.getBaseIntent();
+                    if (intent == null ||
+                            !callingPackage.equals(intent.getComponent().getPackageName())) {
+                        continue;
+                    }
+                    ActivityManager.RecentTaskInfo taskInfo =
+                            createRecentTaskInfoFromTaskRecord(tr);
+                    AppTaskImpl taskImpl = new AppTaskImpl(taskInfo.persistentId, callingUid);
+                    list.add(taskImpl);
                 }
             } finally {
                 Binder.restoreCallingIdentity(ident);
@@ -7508,8 +8184,6 @@
                     android.Manifest.permission.GET_DETAILED_TASKS)
                     == PackageManager.PERMISSION_GRANTED;
 
-            IPackageManager pm = AppGlobals.getPackageManager();
-
             final int N = mRecentTasks.size();
             ArrayList<ActivityManager.RecentTaskInfo> res
                     = new ArrayList<ActivityManager.RecentTaskInfo>(
@@ -7523,57 +8197,13 @@
             }
             includedUsers.add(Integer.valueOf(userId));
 
-            // Regroup affiliated tasks together.
-            for (int i = 0; i < N; ) {
-                TaskRecord task = mRecentTasks.remove(i);
-                if (mTmpRecents.contains(task)) {
-                    continue;
-                }
-                int affiliatedTaskId = task.mAffiliatedTaskId;
-                while (true) {
-                    TaskRecord next = task.mNextAffiliate;
-                    if (next == null) {
-                        break;
-                    }
-                    if (next.mAffiliatedTaskId != affiliatedTaskId) {
-                        Slog.e(TAG, "Error in Recents: next.affiliatedTaskId=" +
-                                next.mAffiliatedTaskId + " affiliatedTaskId=" + affiliatedTaskId);
-                        task.setNextAffiliate(null);
-                        if (next.mPrevAffiliate == task) {
-                            next.setPrevAffiliate(null);
-                        }
-                        break;
-                    }
-                    if (next.mPrevAffiliate != task) {
-                        Slog.e(TAG, "Error in Recents chain prev.mNextAffiliate=" +
-                                next.mPrevAffiliate + " task=" + task);
-                        next.setPrevAffiliate(null);
-                        break;
-                    }
-                    if (!mRecentTasks.contains(next)) {
-                        Slog.e(TAG, "Error in Recents: next=" + next + " not in mRecentTasks");
-                        task.setNextAffiliate(null);
-                        if (next.mPrevAffiliate == task) {
-                            next.setPrevAffiliate(null);
-                        }
-                        break;
-                    }
-                    task = next;
-                }
-                // task is now the end of the list
-                do {
-                    mRecentTasks.remove(task);
-                    mRecentTasks.add(i++, task);
-                    mTmpRecents.add(task);
-                } while ((task = task.mPrevAffiliate) != null);
-            }
-            mTmpRecents.clear();
-            // mRecentTasks is now in sorted, affiliated order.
-
             for (int i=0; i<N && maxNum > 0; i++) {
                 TaskRecord tr = mRecentTasks.get(i);
                 // Only add calling user or related users recent tasks
-                if (!includedUsers.contains(Integer.valueOf(tr.userId))) continue;
+                if (!includedUsers.contains(Integer.valueOf(tr.userId))) {
+                    if (DEBUG_RECENTS) Slog.d(TAG, "Skipping, not user: " + tr);
+                    continue;
+                }
 
                 // Return the entry if desired by the caller.  We always return
                 // the first entry, because callers always expect this to be the
@@ -7589,12 +8219,26 @@
                     if (!allowed) {
                         // If the caller doesn't have the GET_TASKS permission, then only
                         // allow them to see a small subset of tasks -- their own and home.
-                        if (!tr.isHomeTask() && tr.creatorUid != callingUid) {
+                        if (!tr.isHomeTask() && tr.effectiveUid != callingUid) {
+                            if (DEBUG_RECENTS) Slog.d(TAG, "Skipping, not allowed: " + tr);
+                            continue;
+                        }
+                    }
+                    if ((flags & ActivityManager.RECENT_IGNORE_HOME_STACK_TASKS) != 0) {
+                        if (tr.stack != null && tr.stack.isHomeStack()) {
+                            if (DEBUG_RECENTS) Slog.d(TAG, "Skipping, home stack task: " + tr);
                             continue;
                         }
                     }
                     if (tr.autoRemoveRecents && tr.getTopActivity() == null) {
                         // Don't include auto remove tasks that are finished or finishing.
+                        if (DEBUG_RECENTS) Slog.d(TAG, "Skipping, auto-remove without activity: "
+                                + tr);
+                        continue;
+                    }
+                    if ((flags&ActivityManager.RECENT_IGNORE_UNAVAILABLE) != 0
+                            && !tr.isAvailable) {
+                        if (DEBUG_RECENTS) Slog.d(TAG, "Skipping, unavail real act: " + tr);
                         continue;
                     }
 
@@ -7603,25 +8247,6 @@
                         rti.baseIntent.replaceExtras((Bundle)null);
                     }
 
-                    if ((flags&ActivityManager.RECENT_IGNORE_UNAVAILABLE) != 0) {
-                        // Check whether this activity is currently available.
-                        try {
-                            if (rti.origActivity != null) {
-                                if (pm.getActivityInfo(rti.origActivity, 0, userId)
-                                        == null) {
-                                    continue;
-                                }
-                            } else if (rti.baseIntent != null) {
-                                if (pm.queryIntentActivities(rti.baseIntent,
-                                        null, 0, userId) == null) {
-                                    continue;
-                                }
-                            }
-                        } catch (RemoteException e) {
-                            // Will never happen.
-                        }
-                    }
-
                     res.add(rti);
                     maxNum--;
                 }
@@ -7655,6 +8280,97 @@
     }
 
     @Override
+    public int addAppTask(IBinder activityToken, Intent intent,
+            ActivityManager.TaskDescription description, Bitmap thumbnail) throws RemoteException {
+        final int callingUid = Binder.getCallingUid();
+        final long callingIdent = Binder.clearCallingIdentity();
+
+        try {
+            synchronized (this) {
+                ActivityRecord r = ActivityRecord.isInStackLocked(activityToken);
+                if (r == null) {
+                    throw new IllegalArgumentException("Activity does not exist; token="
+                            + activityToken);
+                }
+                ComponentName comp = intent.getComponent();
+                if (comp == null) {
+                    throw new IllegalArgumentException("Intent " + intent
+                            + " must specify explicit component");
+                }
+                if (thumbnail.getWidth() != mThumbnailWidth
+                        || thumbnail.getHeight() != mThumbnailHeight) {
+                    throw new IllegalArgumentException("Bad thumbnail size: got "
+                            + thumbnail.getWidth() + "x" + thumbnail.getHeight() + ", require "
+                            + mThumbnailWidth + "x" + mThumbnailHeight);
+                }
+                if (intent.getSelector() != null) {
+                    intent.setSelector(null);
+                }
+                if (intent.getSourceBounds() != null) {
+                    intent.setSourceBounds(null);
+                }
+                if ((intent.getFlags()&Intent.FLAG_ACTIVITY_NEW_DOCUMENT) != 0) {
+                    if ((intent.getFlags()&Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS) == 0) {
+                        // The caller has added this as an auto-remove task...  that makes no
+                        // sense, so turn off auto-remove.
+                        intent.addFlags(Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS);
+                    }
+                } else if ((intent.getFlags()&Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
+                    // Must be a new task.
+                    intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
+                }
+                if (!comp.equals(mLastAddedTaskComponent) || callingUid != mLastAddedTaskUid) {
+                    mLastAddedTaskActivity = null;
+                }
+                ActivityInfo ainfo = mLastAddedTaskActivity;
+                if (ainfo == null) {
+                    ainfo = mLastAddedTaskActivity = AppGlobals.getPackageManager().getActivityInfo(
+                            comp, 0, UserHandle.getUserId(callingUid));
+                    if (ainfo.applicationInfo.uid != callingUid) {
+                        throw new SecurityException(
+                                "Can't add task for another application: target uid="
+                                + ainfo.applicationInfo.uid + ", calling uid=" + callingUid);
+                    }
+                }
+
+                TaskRecord task = new TaskRecord(this, mStackSupervisor.getNextTaskId(), ainfo,
+                        intent, description);
+
+                int trimIdx = trimRecentsForTask(task, false);
+                if (trimIdx >= 0) {
+                    // If this would have caused a trim, then we'll abort because that
+                    // means it would be added at the end of the list but then just removed.
+                    return -1;
+                }
+
+                final int N = mRecentTasks.size();
+                if (N >= (ActivityManager.getMaxRecentTasksStatic()-1)) {
+                    final TaskRecord tr = mRecentTasks.remove(N - 1);
+                    tr.removedFromRecents(mTaskPersister);
+                }
+
+                task.inRecents = true;
+                mRecentTasks.add(task);
+                r.task.stack.addTask(task, false, false);
+
+                task.setLastThumbnail(thumbnail);
+                task.freeLastThumbnail();
+
+                return task.taskId;
+            }
+        } finally {
+            Binder.restoreCallingIdentity(callingIdent);
+        }
+    }
+
+    @Override
+    public Point getAppTaskThumbnailSize() {
+        synchronized (this) {
+            return new Point(mThumbnailWidth,  mThumbnailHeight);
+        }
+    }
+
+    @Override
     public void setTaskDescription(IBinder token, ActivityManager.TaskDescription td) {
         synchronized (this) {
             ActivityRecord r = ActivityRecord.isInStackLocked(token);
@@ -7665,21 +8381,9 @@
         }
     }
 
-    private void killUnneededProcessLocked(ProcessRecord pr, String reason) {
-        if (!pr.killedByAm) {
-            Slog.i(TAG, "Killing " + pr.toShortString() + " (adj " + pr.setAdj + "): " + reason);
-            EventLog.writeEvent(EventLogTags.AM_KILL, pr.userId, pr.pid,
-                    pr.processName, pr.setAdj, reason);
-            pr.killedByAm = true;
-            Process.killProcessQuiet(pr.pid);
-            Process.killProcessGroup(pr.info.uid, pr.pid);
-        }
-    }
-
     private void cleanUpRemovedTaskLocked(TaskRecord tr, int flags) {
-        tr.disposeThumbnail();
         mRecentTasks.remove(tr);
-        tr.closeRecentsChain();
+        tr.removedFromRecents(mTaskPersister);
         final boolean killProcesses = (flags&ActivityManager.REMOVE_TASK_KILL_PROCESS) != 0;
         Intent baseIntent = new Intent(
                 tr.intent != null ? tr.intent : tr.affinityIntent);
@@ -7719,7 +8423,7 @@
                     continue;
                 }
                 if (pr.setSchedGroup == Process.THREAD_GROUP_BG_NONINTERACTIVE) {
-                    killUnneededProcessLocked(pr, "remove task");
+                    pr.kill("remove task", true);
                 } else {
                     pr.waitingToKill = "remove task";
                 }
@@ -7772,32 +8476,36 @@
 
         if (DEBUG_STACK) Slog.d(TAG, "moveTaskToFront: moving taskId=" + taskId);
         synchronized(this) {
-            if (!checkAppSwitchAllowedLocked(Binder.getCallingPid(),
-                    Binder.getCallingUid(), "Task to front")) {
-                ActivityOptions.abort(options);
+            moveTaskToFrontLocked(taskId, flags, options);
+        }
+    }
+
+    void moveTaskToFrontLocked(int taskId, int flags, Bundle options) {
+        if (!checkAppSwitchAllowedLocked(Binder.getCallingPid(),
+                Binder.getCallingUid(), -1, -1, "Task to front")) {
+            ActivityOptions.abort(options);
+            return;
+        }
+        final long origId = Binder.clearCallingIdentity();
+        try {
+            final TaskRecord task = mStackSupervisor.anyTaskForIdLocked(taskId);
+            if (task == null) {
                 return;
             }
-            final long origId = Binder.clearCallingIdentity();
-            try {
-                final TaskRecord task = mStackSupervisor.anyTaskForIdLocked(taskId);
-                if (task == null) {
-                    return;
-                }
-                if (mStackSupervisor.isLockTaskModeViolation(task)) {
-                    mStackSupervisor.showLockTaskToast();
-                    Slog.e(TAG, "moveTaskToFront: Attempt to violate Lock Task Mode");
-                    return;
-                }
-                final ActivityRecord prev = mStackSupervisor.topRunningActivityLocked();
-                if (prev != null && prev.isRecentsActivity()) {
-                    task.setTaskToReturnTo(ActivityRecord.RECENTS_ACTIVITY_TYPE);
-                }
-                mStackSupervisor.findTaskToMoveToFrontLocked(task, flags, options);
-            } finally {
-                Binder.restoreCallingIdentity(origId);
+            if (mStackSupervisor.isLockTaskModeViolation(task)) {
+                mStackSupervisor.showLockTaskToast();
+                Slog.e(TAG, "moveTaskToFront: Attempt to violate Lock Task Mode");
+                return;
             }
-            ActivityOptions.abort(options);
+            final ActivityRecord prev = mStackSupervisor.topRunningActivityLocked();
+            if (prev != null && prev.isRecentsActivity()) {
+                task.setTaskToReturnTo(ActivityRecord.RECENTS_ACTIVITY_TYPE);
+            }
+            mStackSupervisor.findTaskToMoveToFrontLocked(task, flags, options);
+        } finally {
+            Binder.restoreCallingIdentity(origId);
         }
+        ActivityOptions.abort(options);
     }
 
     @Override
@@ -7808,11 +8516,15 @@
         synchronized(this) {
             TaskRecord tr = recentTaskForIdLocked(taskId);
             if (tr != null) {
+                if (tr == mStackSupervisor.mLockTaskModeTask) {
+                    mStackSupervisor.showLockTaskToast();
+                    return;
+                }
                 if (DEBUG_STACK) Slog.d(TAG, "moveTaskToBack: moving task=" + tr);
                 ActivityStack stack = tr.stack;
                 if (stack.mResumedActivity != null && stack.mResumedActivity.task == tr) {
                     if (!checkAppSwitchAllowedLocked(Binder.getCallingPid(),
-                            Binder.getCallingUid(), "Task to back")) {
+                            Binder.getCallingUid(), -1, -1, "Task to back")) {
                         return;
                     }
                 }
@@ -7840,11 +8552,19 @@
         enforceNotIsolatedCaller("moveActivityTaskToBack");
         synchronized(this) {
             final long origId = Binder.clearCallingIdentity();
-            int taskId = ActivityRecord.getTaskForActivityLocked(token, !nonRoot);
-            if (taskId >= 0) {
-                return ActivityRecord.getStackLocked(token).moveTaskToBackLocked(taskId, null);
+            try {
+                int taskId = ActivityRecord.getTaskForActivityLocked(token, !nonRoot);
+                if (taskId >= 0) {
+                    if ((mStackSupervisor.mLockTaskModeTask != null)
+                            && (mStackSupervisor.mLockTaskModeTask.taskId == taskId)) {
+                        mStackSupervisor.showLockTaskToast();
+                        return false;
+                    }
+                    return ActivityRecord.getStackLocked(token).moveTaskToBackLocked(taskId, null);
+                }
+            } finally {
+                Binder.restoreCallingIdentity(origId);
             }
-            Binder.restoreCallingIdentity(origId);
         }
         return false;
     }
@@ -7856,7 +8576,7 @@
 
         synchronized(this) {
             if (!checkAppSwitchAllowedLocked(Binder.getCallingPid(),
-                    Binder.getCallingUid(), "Task backwards")) {
+                    Binder.getCallingUid(), -1, -1, "Task backwards")) {
                 return;
             }
             final long origId = Binder.clearCallingIdentity();
@@ -8085,7 +8805,8 @@
 
     @Override
     public void startLockTaskModeOnCurrent() throws RemoteException {
-        checkCallingPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS);
+        enforceCallingPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS,
+                "startLockTaskModeOnCurrent");
         ActivityRecord r = null;
         synchronized (this) {
             r = mStackSupervisor.topRunningActivityLocked();
@@ -8127,7 +8848,8 @@
 
     @Override
     public void stopLockTaskModeOnCurrent() throws RemoteException {
-        checkCallingPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS);
+        enforceCallingPermission(android.Manifest.permission.MANAGE_ACTIVITY_STACKS,
+                "stopLockTaskModeOnCurrent");
         long ident = Binder.clearCallingIdentity();
         try {
             stopLockTaskMode();
@@ -8378,6 +9100,14 @@
         return false;
     }
 
+    private void checkTime(long startTime, String where) {
+        long now = SystemClock.elapsedRealtime();
+        if ((now-startTime) > 1000) {
+            // If we are taking more than a second, log about it.
+            Slog.w(TAG, "Slow operation: " + (now-startTime) + "ms so far, now at " + where);
+        }
+    }
+
     private final ContentProviderHolder getContentProviderImpl(IApplicationThread caller,
             String name, IBinder token, boolean stable, int userId) {
         ContentProviderRecord cpr;
@@ -8385,6 +9115,8 @@
         ProviderInfo cpi = null;
 
         synchronized(this) {
+            long startTime = SystemClock.elapsedRealtime();
+
             ProcessRecord r = null;
             if (caller != null) {
                 r = getRecordForAppLocked(caller);
@@ -8398,6 +9130,8 @@
 
             boolean checkCrossUser = true;
 
+            checkTime(startTime, "getContentProviderImpl: getProviderByName");
+
             // First check if this content provider has been published...
             cpr = mProviderMap.getProviderByName(name, userId);
             // If that didn't work, check if it exists for user 0 and then
@@ -8422,10 +9156,12 @@
             if (providerRunning) {
                 cpi = cpr.info;
                 String msg;
+                checkTime(startTime, "getContentProviderImpl: before checkContentProviderPermission");
                 if ((msg = checkContentProviderPermissionLocked(cpi, r, userId, checkCrossUser))
                         != null) {
                     throw new SecurityException(msg);
                 }
+                checkTime(startTime, "getContentProviderImpl: after checkContentProviderPermission");
 
                 if (r != null && cpr.canRunHere(r)) {
                     // This provider has been published or is in the process
@@ -8441,6 +9177,8 @@
 
                 final long origId = Binder.clearCallingIdentity();
 
+                checkTime(startTime, "getContentProviderImpl: incProviderCountLocked");
+
                 // In this case the provider instance already exists, so we can
                 // return it right away.
                 conn = incProviderCountLocked(r, cpr, token, stable);
@@ -8450,7 +9188,9 @@
                         // make sure to count it as being accessed and thus
                         // back up on the LRU list.  This is good because
                         // content providers are often expensive to start.
+                        checkTime(startTime, "getContentProviderImpl: before updateLruProcess");
                         updateLruProcessLocked(cpr.proc, false, null);
+                        checkTime(startTime, "getContentProviderImpl: after updateLruProcess");
                     }
                 }
 
@@ -8463,7 +9203,9 @@
                             Process.killProcess(cpr.proc.pid);
                         }
                     }
+                    checkTime(startTime, "getContentProviderImpl: before updateOomAdj");
                     boolean success = updateOomAdjLocked(cpr.proc);
+                    checkTime(startTime, "getContentProviderImpl: after updateOomAdj");
                     if (DEBUG_PROVIDER) Slog.i(TAG, "Adjust success: " + success);
                     // NOTE: there is still a race here where a signal could be
                     // pending on the process even though we managed to update its
@@ -8478,7 +9220,9 @@
                                 "Existing provider " + cpr.name.flattenToShortString()
                                 + " is crashing; detaching " + r);
                         boolean lastRef = decProviderCountLocked(conn, cpr, token, stable);
+                        checkTime(startTime, "getContentProviderImpl: before appDied");
                         appDiedLocked(cpr.proc);
+                        checkTime(startTime, "getContentProviderImpl: after appDied");
                         if (!lastRef) {
                             // This wasn't the last ref our process had on
                             // the provider...  we have now been killed, bail.
@@ -8495,9 +9239,11 @@
             boolean singleton;
             if (!providerRunning) {
                 try {
+                    checkTime(startTime, "getContentProviderImpl: before resolveContentProvider");
                     cpi = AppGlobals.getPackageManager().
                         resolveContentProvider(name,
                             STOCK_PM_FLAGS | PackageManager.GET_URI_PERMISSION_PATTERNS, userId);
+                    checkTime(startTime, "getContentProviderImpl: after resolveContentProvider");
                 } catch (RemoteException ex) {
                 }
                 if (cpi == null) {
@@ -8514,12 +9260,15 @@
                     userId = UserHandle.USER_OWNER;
                 }
                 cpi.applicationInfo = getAppInfoForUser(cpi.applicationInfo, userId);
+                checkTime(startTime, "getContentProviderImpl: got app info for user");
 
                 String msg;
+                checkTime(startTime, "getContentProviderImpl: before checkContentProviderPermission");
                 if ((msg = checkContentProviderPermissionLocked(cpi, r, userId, !singleton))
                         != null) {
                     throw new SecurityException(msg);
                 }
+                checkTime(startTime, "getContentProviderImpl: after checkContentProviderPermission");
 
                 if (!mProcessesReady && !mDidUpdate && !mWaitingUpdate
                         && !cpi.processName.equals("system")) {
@@ -8541,15 +9290,19 @@
                 }
 
                 ComponentName comp = new ComponentName(cpi.packageName, cpi.name);
+                checkTime(startTime, "getContentProviderImpl: before getProviderByClass");
                 cpr = mProviderMap.getProviderByClass(comp, userId);
+                checkTime(startTime, "getContentProviderImpl: after getProviderByClass");
                 final boolean firstClass = cpr == null;
                 if (firstClass) {
                     try {
+                        checkTime(startTime, "getContentProviderImpl: before getApplicationInfo");
                         ApplicationInfo ai =
                             AppGlobals.getPackageManager().
                                 getApplicationInfo(
                                         cpi.applicationInfo.packageName,
                                         STOCK_PM_FLAGS, userId);
+                        checkTime(startTime, "getContentProviderImpl: after getApplicationInfo");
                         if (ai == null) {
                             Slog.w(TAG, "No package info for content provider "
                                     + cpi.name);
@@ -8562,6 +9315,8 @@
                     }
                 }
 
+                checkTime(startTime, "getContentProviderImpl: now have ContentProviderRecord");
+
                 if (r != null && cpr.canRunHere(r)) {
                     // If this is a multiprocess provider, then just return its
                     // info and allow the caller to instantiate it.  Only do
@@ -8595,8 +9350,10 @@
                     try {
                         // Content provider is now in use, its package can't be stopped.
                         try {
+                            checkTime(startTime, "getContentProviderImpl: before set stopped state");
                             AppGlobals.getPackageManager().setPackageStoppedState(
                                     cpr.appInfo.packageName, false, userId);
+                            checkTime(startTime, "getContentProviderImpl: after set stopped state");
                         } catch (RemoteException e) {
                         } catch (IllegalArgumentException e) {
                             Slog.w(TAG, "Failed trying to unstop package "
@@ -8604,22 +9361,26 @@
                         }
 
                         // Use existing process if already started
+                        checkTime(startTime, "getContentProviderImpl: looking for process record");
                         ProcessRecord proc = getProcessRecordLocked(
                                 cpi.processName, cpr.appInfo.uid, false);
                         if (proc != null && proc.thread != null) {
                             if (DEBUG_PROVIDER) {
                                 Slog.d(TAG, "Installing in existing process " + proc);
                             }
+                            checkTime(startTime, "getContentProviderImpl: scheduling install");
                             proc.pubProviders.put(cpi.name, cpr);
                             try {
                                 proc.thread.scheduleInstallProvider(cpi);
                             } catch (RemoteException e) {
                             }
                         } else {
+                            checkTime(startTime, "getContentProviderImpl: before start process");
                             proc = startProcessLocked(cpi.processName,
                                     cpr.appInfo, false, 0, "content provider",
                                     new ComponentName(cpi.applicationInfo.packageName,
                                             cpi.name), false, false, false);
+                            checkTime(startTime, "getContentProviderImpl: after start process");
                             if (proc == null) {
                                 Slog.w(TAG, "Unable to launch app "
                                         + cpi.applicationInfo.packageName + "/"
@@ -8635,6 +9396,8 @@
                     }
                 }
 
+                checkTime(startTime, "getContentProviderImpl: updating data structures");
+
                 // Make sure the provider is published (the same provider class
                 // may be published under multiple names).
                 if (firstClass) {
@@ -8647,6 +9410,7 @@
                     conn.waiting = true;
                 }
             }
+            checkTime(startTime, "getContentProviderImpl: done!");
         }
 
         // Wait for the provider to be published...
@@ -9004,14 +9768,9 @@
         long ident = 0;
         boolean clearedIdentity = false;
         userId = unsafeConvertIncomingUser(userId);
-        if (UserHandle.getUserId(callingUid) != userId) {
-            if (checkComponentPermission(INTERACT_ACROSS_USERS, callingPid,
-                    callingUid, -1, true) == PackageManager.PERMISSION_GRANTED
-                    || checkComponentPermission(INTERACT_ACROSS_USERS_FULL, callingPid,
-                    callingUid, -1, true) == PackageManager.PERMISSION_GRANTED) {
-                clearedIdentity = true;
-                ident = Binder.clearCallingIdentity();
-            }
+        if (canClearIdentity(callingPid, callingUid, userId)) {
+            clearedIdentity = true;
+            ident = Binder.clearCallingIdentity();
         }
         ContentProviderHolder holder = null;
         try {
@@ -9039,6 +9798,19 @@
         return null;
     }
 
+    private boolean canClearIdentity(int callingPid, int callingUid, int userId) {
+        if (UserHandle.getUserId(callingUid) == userId) {
+            return true;
+        }
+        if (checkComponentPermission(INTERACT_ACROSS_USERS, callingPid,
+                callingUid, -1, true) == PackageManager.PERMISSION_GRANTED
+                || checkComponentPermission(INTERACT_ACROSS_USERS_FULL, callingPid,
+                callingUid, -1, true) == PackageManager.PERMISSION_GRANTED) {
+                return true;
+        }
+        return false;
+    }
+
     // =========================================================
     // GLOBAL MANAGEMENT
     // =========================================================
@@ -9171,11 +9943,11 @@
     // Actually is sleeping or shutting down or whatever else in the future
     // is an inactive state.
     public boolean isSleepingOrShuttingDown() {
-        return mSleeping || mShuttingDown;
+        return isSleeping() || mShuttingDown;
     }
 
     public boolean isSleeping() {
-        return mSleeping;
+        return mSleeping && !mKeyguardWaitingForDraw;
     }
 
     void goingToSleep() {
@@ -9197,6 +9969,7 @@
         if (mWentToSleep && !mRunningVoice) {
             if (!mSleeping) {
                 mSleeping = true;
+                mKeyguardWaitingForDraw = false;
                 mStackSupervisor.goingToSleepLocked();
 
                 // Initialize the wake times of all processes.
@@ -9291,7 +10064,7 @@
     }
 
     private void updateEventDispatchingLocked() {
-        mWindowManager.setEventDispatching(mBooted && !mWentToSleep && !mShuttingDown);
+        mWindowManager.setEventDispatching(mBooted && !mShuttingDown);
     }
 
     public void setLockScreenShown(boolean shown) {
@@ -9306,6 +10079,7 @@
             try {
                 if (DEBUG_LOCKSCREEN) logLockScreen(" shown=" + shown);
                 mLockScreenShown = shown;
+                mKeyguardWaitingForDraw = false;
                 comeOutOfSleepIfNeededLocked();
             } finally {
                 Binder.restoreCallingIdentity(ident);
@@ -9346,20 +10120,31 @@
         }
     }
     
-    boolean checkAppSwitchAllowedLocked(int callingPid, int callingUid,
-            String name) {
+    boolean checkAppSwitchAllowedLocked(int sourcePid, int sourceUid,
+            int callingPid, int callingUid, String name) {
         if (mAppSwitchesAllowedTime < SystemClock.uptimeMillis()) {
             return true;
         }
 
-        final int perm = checkComponentPermission(
-                android.Manifest.permission.STOP_APP_SWITCHES, callingPid,
-                callingUid, -1, true);
+        int perm = checkComponentPermission(
+                android.Manifest.permission.STOP_APP_SWITCHES, sourcePid,
+                sourceUid, -1, true);
         if (perm == PackageManager.PERMISSION_GRANTED) {
             return true;
         }
-        
-        Slog.w(TAG, name + " request from " + callingUid + " stopped");
+
+        // If the actual IPC caller is different from the logical source, then
+        // also see if they are allowed to control app switches.
+        if (callingUid != -1 && callingUid != sourceUid) {
+            perm = checkComponentPermission(
+                    android.Manifest.permission.STOP_APP_SWITCHES, callingPid,
+                    callingUid, -1, true);
+            if (perm == PackageManager.PERMISSION_GRANTED) {
+                return true;
+            }
+        }
+
+        Slog.w(TAG, name + " request from " + sourceUid + " stopped");
         return false;
     }
     
@@ -9414,8 +10199,7 @@
         }
     }
 
-    void setProfileApp(ApplicationInfo app, String processName, String profileFile,
-            ParcelFileDescriptor profileFd, boolean autoStopProfiler) {
+    void setProfileApp(ApplicationInfo app, String processName, ProfilerInfo profilerInfo) {
         synchronized (this) {
             boolean isDebuggable = "1".equals(SystemProperties.get(SYSTEM_DEBUGGABLE, "0"));
             if (!isDebuggable) {
@@ -9424,7 +10208,7 @@
                 }
             }
             mProfileApp = processName;
-            mProfileFile = profileFile;
+            mProfileFile = profilerInfo.profileFile;
             if (mProfileFd != null) {
                 try {
                     mProfileFd.close();
@@ -9432,9 +10216,10 @@
                 }
                 mProfileFd = null;
             }
-            mProfileFd = profileFd;
+            mProfileFd = profilerInfo.profileFd;
+            mSamplingInterval = profilerInfo.samplingInterval;
+            mAutoStopProfiler = profilerInfo.autoStopProfiler;
             mProfileType = 0;
-            mAutoStopProfiler = autoStopProfiler;
         }
     }
 
@@ -9446,7 +10231,7 @@
         Settings.Global.putInt(
                 mContext.getContentResolver(),
                 Settings.Global.ALWAYS_FINISH_ACTIVITIES, enabled ? 1 : 0);
-        
+
         synchronized (this) {
             mAlwaysFinishActivities = enabled;
         }
@@ -9660,13 +10445,13 @@
                 if (r == null) {
                     return false;
                 }
-                if (r.changeWindowTranslucency(true)) {
-                    mWindowManager.setAppFullscreen(token, true);
+                final boolean translucentChanged = r.changeWindowTranslucency(true);
+                if (translucentChanged) {
                     r.task.stack.releaseBackgroundResources();
                     mStackSupervisor.ensureActivitiesVisibleLocked(null, 0);
-                    return true;
                 }
-                return false;
+                mWindowManager.setAppFullscreen(token, true);
+                return translucentChanged;
             }
         } finally {
             Binder.restoreCallingIdentity(origId);
@@ -9687,15 +10472,13 @@
                     ActivityRecord under = r.task.mActivities.get(index - 1);
                     under.returningOptions = options;
                 }
-                if (r.changeWindowTranslucency(false)) {
+                final boolean translucentChanged = r.changeWindowTranslucency(false);
+                if (translucentChanged) {
                     r.task.stack.convertToTranslucent(r);
-                    mWindowManager.setAppFullscreen(token, false);
-                    mStackSupervisor.ensureActivitiesVisibleLocked(null, 0);
-                    return true;
-                } else {
-                    mStackSupervisor.ensureActivitiesVisibleLocked(null, 0);
-                    return false;
                 }
+                mStackSupervisor.ensureActivitiesVisibleLocked(null, 0);
+                mWindowManager.setAppFullscreen(token, false);
+                return translucentChanged;
             }
         } finally {
             Binder.restoreCallingIdentity(origId);
@@ -9895,7 +10678,7 @@
                 }
                 int adj = proc.setAdj;
                 if (adj >= worstType && !proc.killedByAm) {
-                    killUnneededProcessLocked(proc, reason);
+                    proc.kill(reason, true);
                     killed = true;
                 }
             }
@@ -9939,7 +10722,7 @@
 
                 final int adj = proc.setAdj;
                 if (adj > belowAdj && !proc.killedByAm) {
-                    killUnneededProcessLocked(proc, reason);
+                    proc.kill(reason, true);
                     killed = true;
                 }
             }
@@ -10058,8 +10841,8 @@
                             && proc.setProcState <= ActivityManager.PROCESS_STATE_SERVICE) {
                         if (doKilling && proc.initialIdlePss != 0
                                 && proc.lastPss > ((proc.initialIdlePss*3)/2)) {
-                            killUnneededProcessLocked(proc, "idle maint (pss " + proc.lastPss
-                                    + " from " + proc.initialIdlePss + ")");
+                            proc.kill("idle maint (pss " + proc.lastPss
+                                    + " from " + proc.initialIdlePss + ")", true);
                         }
                     }
                 } else if (proc.setProcState < ActivityManager.PROCESS_STATE_HOME) {
@@ -10106,6 +10889,14 @@
         }
     }
 
+    /** Loads resources after the current configuration has been set. */
+    private void loadResourcesOnSystemReady() {
+        final Resources res = mContext.getResources();
+        mHasRecents = res.getBoolean(com.android.internal.R.bool.config_hasRecents);
+        mThumbnailWidth = res.getDimensionPixelSize(com.android.internal.R.dimen.thumbnail_width);
+        mThumbnailHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.thumbnail_height);
+    }
+
     public boolean testIsSystemReady() {
         // no need to synchronize(this) just to read & return the value
         return mSystemReady;
@@ -10285,6 +11076,7 @@
                 if (!mRecentTasks.isEmpty()) {
                     mStackSupervisor.createStackForRestoredTaskHistory(mRecentTasks);
                 }
+                cleanupRecentTasksLocked(UserHandle.USER_ALL);
                 mTaskPersister.startPersisting();
             }
 
@@ -10386,6 +11178,7 @@
         }
 
         retrieveSettings();
+        loadResourcesOnSystemReady();
 
         synchronized (this) {
             readGrantedUriPermissionsLocked();
@@ -10528,7 +11321,7 @@
             }
             if (app.pid > 0 && app.pid != MY_PID) {
                 handleAppCrashLocked(app, null, null, null);
-                killUnneededProcessLocked(app, "user request after error");
+                app.kill("user request after error", true);
             }
         }
     }
@@ -10847,12 +11640,13 @@
      * Used by {@link Log} via {@link com.android.internal.os.RuntimeInit} to report serious errors.
      * @param app object of the crashing app, null for the system server
      * @param tag reported by the caller
+     * @param system whether this wtf is coming from the system
      * @param crashInfo describing the context of the error
      * @return true if the process should exit immediately (WTF is fatal)
      */
-    public boolean handleApplicationWtf(IBinder app, String tag,
-            ApplicationErrorReport.CrashInfo crashInfo) {
-        ProcessRecord r = findAppProcess(app, "WTF");
+    public boolean handleApplicationWtf(IBinder app, final String tag, boolean system,
+            final ApplicationErrorReport.CrashInfo crashInfo) {
+        final ProcessRecord r = findAppProcess(app, "WTF");
         final String processName = app == null ? "system_server"
                 : (r == null ? "unknown" : r.processName);
 
@@ -10862,6 +11656,19 @@
                 r == null ? -1 : r.info.flags,
                 tag, crashInfo.exceptionMessage);
 
+        if (system) {
+            // If this is coming from the system, we could very well have low-level
+            // system locks held, so we want to do this all asynchronously.  And we
+            // never want this to become fatal, so there is that too.
+            mHandler.post(new Runnable() {
+                @Override public void run() {
+                    addErrorToDropBox("wtf", r, processName, null, null, tag, null, null,
+                            crashInfo);
+                }
+            });
+            return false;
+        }
+
         addErrorToDropBox("wtf", r, processName, null, null, tag, null, null, crashInfo);
 
         if (r != null && r.pid != Process.myPid() &&
@@ -11032,6 +11839,7 @@
                     try {
                         java.lang.Process logcat = new ProcessBuilder("/system/bin/logcat",
                                 "-v", "time", "-b", "events", "-b", "system", "-b", "main",
+                                "-b", "crash",
                                 "-t", String.valueOf(lines)).redirectErrorStream(true).start();
 
                         try { logcat.getOutputStream().close(); } catch (IOException e) {}
@@ -11095,8 +11903,11 @@
                         } else {
                             Slog.w(TAG, "Force-killing crashed app " + name
                                     + " at watcher's request");
-                            Process.killProcess(pid);
                             if (r != null) {
+                                r.kill("crash", true);
+                            } else {
+                                // Huh.
+                                Process.killProcess(pid);
                                 Process.killProcessGroup(uid, pid);
                             }
                         }
@@ -11402,6 +12213,7 @@
                 pw.println("  [-a] [-c] [-h] [cmd] ...");
                 pw.println("  cmd may be one of:");
                 pw.println("    a[ctivities]: activity stack state");
+                pw.println("    r[recents]: recent activities state");
                 pw.println("    b[roadcasts] [PACKAGE_NAME] [history [-s]]: broadcast state");
                 pw.println("    i[ntents] [PACKAGE_NAME]: pending intent state");
                 pw.println("    p[rocesses] [PACKAGE_NAME]: process state");
@@ -11435,6 +12247,10 @@
                 synchronized (this) {
                     dumpActivitiesLocked(fd, pw, args, opti, true, dumpClient, null);
                 }
+            } else if ("recents".equals(cmd) || "r".equals(cmd)) {
+                synchronized (this) {
+                    dumpRecentsLocked(fd, pw, args, opti, true, null);
+                }
             } else if ("broadcasts".equals(cmd) || "b".equals(cmd)) {
                 String[] newArgs;
                 String name;
@@ -11578,6 +12394,11 @@
             if (dumpAll) {
                 pw.println("-------------------------------------------------------------------------------");
             }
+            dumpRecentsLocked(fd, pw, args, opti, dumpAll, dumpPackage);
+            pw.println();
+            if (dumpAll) {
+                pw.println("-------------------------------------------------------------------------------");
+            }
             dumpActivitiesLocked(fd, pw, args, opti, dumpAll, dumpClient, dumpPackage);
             pw.println();
             if (dumpAll) {
@@ -11612,6 +12433,17 @@
             mStackSupervisor.dump(pw, "  ");
         }
 
+        if (!printedAnything) {
+            pw.println("  (nothing)");
+        }
+    }
+
+    void dumpRecentsLocked(FileDescriptor fd, PrintWriter pw, String[] args,
+            int opti, boolean dumpAll, String dumpPackage) {
+        pw.println("ACTIVITY MANAGER RECENT ACTIVITIES (dumpsys activity recents)");
+
+        boolean printedAnything = false;
+
         if (mRecentTasks.size() > 0) {
             boolean printedHeader = false;
 
@@ -11625,9 +12457,6 @@
                     }
                 }
                 if (!printedHeader) {
-                    if (needSep) {
-                        pw.println();
-                    }
                     pw.println("  Recent tasks:");
                     printedHeader = true;
                     printedAnything = true;
@@ -12001,8 +12830,9 @@
                 }
                 pw.println("  mProfileApp=" + mProfileApp + " mProfileProc=" + mProfileProc);
                 pw.println("  mProfileFile=" + mProfileFile + " mProfileFd=" + mProfileFd);
-                pw.println("  mProfileType=" + mProfileType + " mAutoStopProfiler="
+                pw.println("  mSamplingInterval=" + mSamplingInterval + " mAutoStopProfiler="
                         + mAutoStopProfiler);
+                pw.println("  mProfileType=" + mProfileType);
             }
         }
         if (dumpPackage == null) {
@@ -12994,7 +13824,7 @@
                     findPid = Integer.parseInt(args[opti]);
                 } catch (NumberFormatException e) {
                 }
-                synchronized (mProcessCpuThread) {
+                synchronized (mProcessCpuTracker) {
                     final int N = mProcessCpuTracker.countStats();
                     for (int i=0; i<N; i++) {
                         ProcessCpuTracker.Stats st = mProcessCpuTracker.getStats(i);
@@ -13156,7 +13986,7 @@
             // If we are showing aggregations, also look for native processes to
             // include so that our aggregations are more accurate.
             updateCpuStatsNow();
-            synchronized (mProcessCpuThread) {
+            synchronized (mProcessCpuTracker) {
                 final int N = mProcessCpuTracker.countStats();
                 for (int i=0; i<N; i++) {
                     ProcessCpuTracker.Stats st = mProcessCpuTracker.getStats(i);
@@ -13427,9 +14257,9 @@
                 if (!capp.persistent && capp.thread != null
                         && capp.pid != 0
                         && capp.pid != MY_PID) {
-                    killUnneededProcessLocked(capp, "depends on provider "
+                    capp.kill("depends on provider "
                             + cpr.name.flattenToShortString()
-                            + " in dying proc " + (proc != null ? proc.processName : "??"));
+                            + " in dying proc " + (proc != null ? proc.processName : "??"), true);
                 }
             } else if (capp.thread != null && conn.provider.provider != null) {
                 try {
@@ -13842,6 +14672,14 @@
             throw new IllegalArgumentException(
                     "Call does not support special user #" + targetUserId);
         }
+        // Check shell permission
+        if (callingUid == Process.SHELL_UID && targetUserId >= UserHandle.USER_OWNER) {
+            if (mUserManager.hasUserRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES,
+                    targetUserId)) {
+                throw new SecurityException("Shell does not have permission to access user "
+                        + targetUserId + "\n " + Debug.getCallers(3));
+            }
+        }
         return targetUserId;
     }
 
@@ -13866,13 +14704,10 @@
             }
         } else if ("system".equals(componentProcessName)) {
             result = true;
-        } else if (UserHandle.isSameApp(aInfo.uid, Process.PHONE_UID)
-                && (flags & ServiceInfo.FLAG_SINGLE_USER) != 0) {
-            // Phone app is allowed to export singleuser providers.
-            result = true;
-        } else {
-            // App with pre-defined UID, check if it's a persistent app
-            result = (aInfo.flags & ApplicationInfo.FLAG_PERSISTENT) != 0;
+        } else if ((flags & ServiceInfo.FLAG_SINGLE_USER) != 0) {
+            // Phone app and persistent apps are allowed to export singleuser providers.
+            result = UserHandle.isSameApp(aInfo.uid, Process.PHONE_UID)
+                    || (aInfo.flags & ApplicationInfo.FLAG_PERSISTENT) != 0;
         }
         if (DEBUG_MU) {
             Slog.v(TAG, "isSingleton(" + componentProcessName + ", " + aInfo
@@ -13900,6 +14735,7 @@
             Intent service, String resolvedType,
             IServiceConnection connection, int flags, int userId) {
         enforceNotIsolatedCaller("bindService");
+
         // Refuse possible leaked file descriptors
         if (service != null && service.hasFileDescriptors() == true) {
             throw new IllegalArgumentException("File descriptors passed in Intent");
@@ -14334,12 +15170,18 @@
     }
 
     private List<ResolveInfo> collectReceiverComponents(Intent intent, String resolvedType,
-            int[] users) {
+            int callingUid, int[] users) {
         List<ResolveInfo> receivers = null;
         try {
             HashSet<ComponentName> singleUserReceivers = null;
             boolean scannedFirstReceivers = false;
             for (int user : users) {
+                // Skip users that have Shell restrictions
+                if (callingUid == Process.SHELL_UID
+                        && getUserManagerLocked().hasUserRestriction(
+                                UserManager.DISALLOW_DEBUGGING_FEATURES, user)) {
+                    continue;
+                }
                 List<ResolveInfo> newReceivers = AppGlobals.getPackageManager()
                         .queryIntentReceivers(intent, resolvedType, STOCK_PM_FLAGS, user);
                 if (user != 0 && newReceivers != null) {
@@ -14428,7 +15270,6 @@
         // Make sure that the user who is receiving this broadcast is started.
         // If not, we will just skip it.
 
-
         if (userId != UserHandle.USER_ALL && mStartedUsers.get(userId) == null) {
             if (callingUid != Process.SYSTEM_UID || (intent.getFlags()
                     & Intent.FLAG_RECEIVER_BOOT_UPGRADE) == 0) {
@@ -14497,6 +15338,7 @@
         if (Intent.ACTION_PACKAGE_REMOVED.equals(intent.getAction())
                 || Intent.ACTION_PACKAGE_CHANGED.equals(intent.getAction())
                 || Intent.ACTION_EXTERNAL_APPLICATIONS_UNAVAILABLE.equals(intent.getAction())
+                || Intent.ACTION_EXTERNAL_APPLICATIONS_AVAILABLE.equals(intent.getAction())
                 || uidRemoved) {
             if (checkComponentPermission(
                     android.Manifest.permission.BROADCAST_PACKAGE_REMOVED,
@@ -14523,9 +15365,13 @@
                                 forceStopPackageLocked(pkg, -1, false, true, true, false, false, userId,
                                         "storage unmount");
                             }
+                            cleanupRecentTasksLocked(UserHandle.USER_ALL);
                             sendPackageBroadcastLocked(
                                     IApplicationThread.EXTERNAL_STORAGE_UNAVAILABLE, list, userId);
                         }
+                    } else if (Intent.ACTION_EXTERNAL_APPLICATIONS_AVAILABLE.equals(
+                            intent.getAction())) {
+                        cleanupRecentTasksLocked(UserHandle.USER_ALL);
                     } else {
                         Uri data = intent.getData();
                         String ssp;
@@ -14591,6 +15437,10 @@
             final int is24Hour = intent.getBooleanExtra(
                     Intent.EXTRA_TIME_PREF_24_HOUR_FORMAT, false) ? 1 : 0;
             mHandler.sendMessage(mHandler.obtainMessage(UPDATE_TIME, is24Hour, 0));
+            BatteryStatsImpl stats = mBatteryStatsService.getActiveStatistics();
+            synchronized (stats) {
+                stats.noteCurrentTimeChangedLocked();
+            }
         }
 
         if (Intent.ACTION_CLEAR_DNS_CACHE.equals(intent.getAction())) {
@@ -14684,11 +15534,30 @@
         // Need to resolve the intent to interested receivers...
         if ((intent.getFlags()&Intent.FLAG_RECEIVER_REGISTERED_ONLY)
                  == 0) {
-            receivers = collectReceiverComponents(intent, resolvedType, users);
+            receivers = collectReceiverComponents(intent, resolvedType, callingUid, users);
         }
         if (intent.getComponent() == null) {
-            registeredReceivers = mReceiverResolver.queryIntent(intent,
-                    resolvedType, false, userId);
+            if (userId == UserHandle.USER_ALL && callingUid == Process.SHELL_UID) {
+                // Query one target user at a time, excluding shell-restricted users
+                UserManagerService ums = getUserManagerLocked();
+                for (int i = 0; i < users.length; i++) {
+                    if (ums.hasUserRestriction(
+                            UserManager.DISALLOW_DEBUGGING_FEATURES, users[i])) {
+                        continue;
+                    }
+                    List<BroadcastFilter> registeredReceiversForUser =
+                            mReceiverResolver.queryIntent(intent,
+                                    resolvedType, false, users[i]);
+                    if (registeredReceivers == null) {
+                        registeredReceivers = registeredReceiversForUser;
+                    } else if (registeredReceiversForUser != null) {
+                        registeredReceivers.addAll(registeredReceiversForUser);
+                    }
+                }
+            } else {
+                registeredReceivers = mReceiverResolver.queryIntent(intent,
+                        resolvedType, false, userId);
+            }
         }
 
         final boolean replacePending =
@@ -14850,7 +15719,7 @@
         enforceNotIsolatedCaller("broadcastIntent");
         synchronized(this) {
             intent = verifyBroadcastLocked(intent);
-            
+
             final ProcessRecord callerApp = getRecordForAppLocked(caller);
             final int callingPid = Binder.getCallingPid();
             final int callingUid = Binder.getCallingUid();
@@ -15226,6 +16095,7 @@
                 newConfig.seq = mConfigurationSeq;
                 mConfiguration = newConfig;
                 Slog.i(TAG, "Config changes=" + Integer.toHexString(changes) + " " + newConfig);
+                mUsageStatsService.reportConfigurationChange(newConfig, mCurrentUserId);
                 //mUsageStatsService.noteStartConfig(newConfig);
 
                 final Configuration configCopy = new Configuration(mConfiguration);
@@ -15338,10 +16208,14 @@
     }
 
     @Override
-    public boolean targetTaskAffinityMatchesActivity(IBinder token, String destAffinity) {
-        ActivityRecord srec = ActivityRecord.forToken(token);
-        return srec != null && srec.task.affinity != null &&
-                srec.task.affinity.equals(destAffinity);
+    public boolean shouldUpRecreateTask(IBinder token, String destAffinity) {
+        synchronized (this) {
+            ActivityRecord srec = ActivityRecord.forToken(token);
+            if (srec.task != null && srec.task.stack != null) {
+                return srec.task.stack.shouldUpRecreateTaskLocked(srec, destAffinity);
+            }
+        }
+        return false;
     }
 
     public boolean navigateUpTo(IBinder token, Intent destIntent, int resultCode,
@@ -15551,8 +16425,8 @@
                     // send to process) since there can be an arbitrary number of stopping
                     // processes and they should soon all go into the cached state.
                     if (!r.finishing) {
-                        if (procState > ActivityManager.PROCESS_STATE_CACHED_ACTIVITY) {
-                            procState = ActivityManager.PROCESS_STATE_CACHED_ACTIVITY;
+                        if (procState > ActivityManager.PROCESS_STATE_LAST_ACTIVITY) {
+                            procState = ActivityManager.PROCESS_STATE_LAST_ACTIVITY;
                         }
                     }
                     app.cached = false;
@@ -16281,8 +17155,7 @@
                         stats.reportExcessiveWakeLocked(app.info.uid, app.processName,
                                 realtimeSince, wtimeUsed);
                     }
-                    killUnneededProcessLocked(app, "excessive wake held " + wtimeUsed
-                            + " during " + realtimeSince);
+                    app.kill("excessive wake held " + wtimeUsed + " during " + realtimeSince, true);
                     app.baseProcessTracker.reportExcessiveWake(app.pkgList);
                 } else if (doCpuKills && uptimeSince > 0
                         && ((cputimeUsed*100)/uptimeSince) >= 25) {
@@ -16290,8 +17163,7 @@
                         stats.reportExcessiveCpuLocked(app.info.uid, app.processName,
                                 uptimeSince, cputimeUsed);
                     }
-                    killUnneededProcessLocked(app, "excessive cpu " + cputimeUsed
-                            + " during " + uptimeSince);
+                    app.kill("excessive cpu " + cputimeUsed + " during " + uptimeSince, true);
                     app.baseProcessTracker.reportExcessiveCpu(app.pkgList);
                 } else {
                     app.lastWakeTime = wtime;
@@ -16326,7 +17198,7 @@
                     + " to " + app.curSchedGroup);
             if (app.waitingToKill != null &&
                     app.setSchedGroup == Process.THREAD_GROUP_BG_NONINTERACTIVE) {
-                killUnneededProcessLocked(app, app.waitingToKill);
+                app.kill(app.waitingToKill, true);
                 success = false;
             } else {
                 if (true) {
@@ -16706,19 +17578,19 @@
                         mNumCachedHiddenProcs++;
                         numCached++;
                         if (numCached > cachedProcessLimit) {
-                            killUnneededProcessLocked(app, "cached #" + numCached);
+                            app.kill("cached #" + numCached, true);
                         }
                         break;
                     case ActivityManager.PROCESS_STATE_CACHED_EMPTY:
                         if (numEmpty > ProcessList.TRIM_EMPTY_APPS
                                 && app.lastActivityTime < oldTime) {
-                            killUnneededProcessLocked(app, "empty for "
+                            app.kill("empty for "
                                     + ((oldTime + ProcessList.MAX_EMPTY_TIME - app.lastActivityTime)
-                                    / 1000) + "s");
+                                    / 1000) + "s", true);
                         } else {
                             numEmpty++;
                             if (numEmpty > emptyProcessLimit) {
-                                killUnneededProcessLocked(app, "empty #" + numEmpty);
+                                app.kill("empty #" + numEmpty, true);
                             }
                         }
                         break;
@@ -16734,7 +17606,7 @@
                     // definition not re-use the same process again, and it is
                     // good to avoid having whatever code was running in them
                     // left sitting around after no longer needed.
-                    killUnneededProcessLocked(app, "isolated not needed");
+                    app.kill("isolated not needed", true);
                 }
 
                 if (app.curProcState >= ActivityManager.PROCESS_STATE_HOME
@@ -16942,7 +17814,13 @@
         }
 
         if (DEBUG_OOM_ADJ) {
-            Slog.d(TAG, "Did OOM ADJ in " + (SystemClock.uptimeMillis()-now) + "ms");
+            if (false) {
+                RuntimeException here = new RuntimeException("here");
+                here.fillInStackTrace();
+                Slog.d(TAG, "Did OOM ADJ in " + (SystemClock.uptimeMillis()-now) + "ms", here);
+            } else {
+                Slog.d(TAG, "Did OOM ADJ in " + (SystemClock.uptimeMillis()-now) + "ms");
+            }
         }
     }
 
@@ -16962,11 +17840,7 @@
                         + (app.thread != null ? app.thread.asBinder() : null)
                         + ")\n");
                     if (app.pid > 0 && app.pid != MY_PID) {
-                        EventLog.writeEvent(EventLogTags.AM_KILL, app.userId, app.pid,
-                                app.processName, app.setAdj, "empty");
-                        app.killedByAm = true;
-                        Process.killProcessQuiet(app.pid);
-                        Process.killProcessGroup(app.info.uid, app.pid);
+                        app.kill("empty", false);
                     } else {
                         try {
                             app.thread.scheduleExit();
@@ -17010,10 +17884,9 @@
         }
     }
 
-    private void stopProfilerLocked(ProcessRecord proc, String path, int profileType) {
+    private void stopProfilerLocked(ProcessRecord proc, int profileType) {
         if (proc == null || proc == mProfileProc) {
             proc = mProfileProc;
-            path = mProfileFile;
             profileType = mProfileType;
             clearProfilerLocked();
         }
@@ -17021,7 +17894,7 @@
             return;
         }
         try {
-            proc.thread.profilerControl(false, path, null, profileType);
+            proc.thread.profilerControl(false, null, profileType);
         } catch (RemoteException e) {
             throw new IllegalStateException("Process disappeared");
         }
@@ -17039,10 +17912,11 @@
         mProfileFile = null;
         mProfileType = 0;
         mAutoStopProfiler = false;
+        mSamplingInterval = 0;
     }
 
     public boolean profileControl(String process, int userId, boolean start,
-            String path, ParcelFileDescriptor fd, int profileType) throws RemoteException {
+            ProfilerInfo profilerInfo, int profileType) throws RemoteException {
 
         try {
             synchronized (this) {
@@ -17054,8 +17928,8 @@
                             + android.Manifest.permission.SET_ACTIVITY_WATCHER);
                 }
 
-                if (start && fd == null) {
-                    throw new IllegalArgumentException("null fd");
+                if (start && (profilerInfo == null || profilerInfo.profileFd == null)) {
+                    throw new IllegalArgumentException("null profile info or fd");
                 }
 
                 ProcessRecord proc = null;
@@ -17068,23 +17942,25 @@
                 }
 
                 if (start) {
-                    stopProfilerLocked(null, null, 0);
-                    setProfileApp(proc.info, proc.processName, path, fd, false);
+                    stopProfilerLocked(null, 0);
+                    setProfileApp(proc.info, proc.processName, profilerInfo);
                     mProfileProc = proc;
                     mProfileType = profileType;
+                    ParcelFileDescriptor fd = profilerInfo.profileFd;
                     try {
                         fd = fd.dup();
                     } catch (IOException e) {
                         fd = null;
                     }
-                    proc.thread.profilerControl(start, path, fd, profileType);
+                    profilerInfo.profileFd = fd;
+                    proc.thread.profilerControl(start, profilerInfo, profileType);
                     fd = null;
                     mProfileFd = null;
                 } else {
-                    stopProfilerLocked(proc, path, profileType);
-                    if (fd != null) {
+                    stopProfilerLocked(proc, profileType);
+                    if (profilerInfo != null && profilerInfo.profileFd != null) {
                         try {
-                            fd.close();
+                            profilerInfo.profileFd.close();
                         } catch (IOException e) {
                         }
                     }
@@ -17095,9 +17971,9 @@
         } catch (RemoteException e) {
             throw new IllegalStateException("Process disappeared");
         } finally {
-            if (fd != null) {
+            if (profilerInfo != null && profilerInfo.profileFd != null) {
                 try {
-                    fd.close();
+                    profilerInfo.profileFd.close();
                 } catch (IOException e) {
                 }
             }
@@ -17211,6 +18087,15 @@
     }
 
     /**
+     * Start user, if its not already running, and bring it to foreground.
+     */
+    boolean startUserInForeground(final int userId, Dialog dlg) {
+        boolean result = startUser(userId, /* foreground */ true);
+        dlg.dismiss();
+        return result;
+    }
+
+    /**
      * Refreshes the list of users related to the current user when either a
      * user switch happens or when a new related user is started in the
      * background.
@@ -17248,10 +18133,34 @@
 
     @Override
     public boolean switchUser(final int userId) {
-        return startUser(userId, /* foregound */ true);
+        enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, userId);
+        String userName;
+        synchronized (this) {
+            UserInfo userInfo = getUserManagerLocked().getUserInfo(userId);
+            if (userInfo == null) {
+                Slog.w(TAG, "No user info for user #" + userId);
+                return false;
+            }
+            if (userInfo.isManagedProfile()) {
+                Slog.w(TAG, "Cannot switch to User #" + userId + ": not a full user");
+                return false;
+            }
+            userName = userInfo.name;
+            mTargetUserId = userId;
+        }
+        mHandler.removeMessages(START_USER_SWITCH_MSG);
+        mHandler.sendMessage(mHandler.obtainMessage(START_USER_SWITCH_MSG, userId, 0, userName));
+        return true;
     }
 
-    private boolean startUser(final int userId, boolean foreground) {
+    private void showUserSwitchDialog(int userId, String userName) {
+        // The dialog will show and then initiate the user switch by calling startUserInForeground
+        Dialog d = new UserSwitchingDialog(this, mContext, userId, userName,
+                true /* above system */);
+        d.show();
+    }
+
+    private boolean startUser(final int userId, final boolean foreground) {
         if (checkCallingPermission(INTERACT_ACROSS_USERS_FULL)
                 != PackageManager.PERMISSION_GRANTED) {
             String msg = "Permission Denial: switchUser() from pid="
@@ -17305,6 +18214,7 @@
 
                 if (foreground) {
                     mCurrentUserId = userId;
+                    mTargetUserId = UserHandle.USER_NULL; // reset, mCurrentUserId has caught up
                     updateCurrentProfileIdsLocked();
                     mWindowManager.setCurrentUser(userId, mCurrentProfileIds);
                     // Once the internal notion of the active user has switched, we lock the device
@@ -17375,7 +18285,7 @@
                                     public void performReceive(Intent intent, int resultCode,
                                             String data, Bundle extras, boolean ordered,
                                             boolean sticky, int sendingUser) {
-                                        userInitialized(uss, userId);
+                                        onUserInitialized(uss, foreground, oldUserId, userId);
                                     }
                                 }, 0, null, null, null, AppOpsManager.OP_NONE,
                                 true, false, MY_PID, Process.SYSTEM_UID,
@@ -17387,15 +18297,9 @@
                 }
 
                 if (foreground) {
-                    boolean homeInFront = mStackSupervisor.switchUserLocked(userId, uss);
-                    if (homeInFront) {
-                        startHomeActivityLocked(userId);
-                    } else {
-                        mStackSupervisor.resumeTopActivitiesLocked();
+                    if (!uss.initializing) {
+                        moveUserToForeground(uss, oldUserId, userId);
                     }
-                    EventLogTags.writeAmSwitchUser(userId);
-                    getUserManagerLocked().userForeground(userId);
-                    sendUserSwitchBroadcastsLocked(oldUserId, userId);
                 } else {
                     mStackSupervisor.startBackgroundUserLocked(userId, uss);
                 }
@@ -17521,10 +18425,28 @@
                 oldUserId, newUserId, uss));
     }
 
-    void userInitialized(UserStartedState uss, int newUserId) {
+    void onUserInitialized(UserStartedState uss, boolean foreground, int oldUserId, int newUserId) {
+        synchronized (this) {
+            if (foreground) {
+                moveUserToForeground(uss, oldUserId, newUserId);
+            }
+        }
+
         completeSwitchAndInitalize(uss, newUserId, true, false);
     }
 
+    void moveUserToForeground(UserStartedState uss, int oldUserId, int newUserId) {
+        boolean homeInFront = mStackSupervisor.switchUserLocked(newUserId, uss);
+        if (homeInFront) {
+            startHomeActivityLocked(newUserId);
+        } else {
+            mStackSupervisor.resumeTopActivitiesLocked();
+        }
+        EventLogTags.writeAmSwitchUser(newUserId);
+        getUserManagerLocked().userForeground(newUserId);
+        sendUserSwitchBroadcastsLocked(oldUserId, newUserId);
+    }
+
     void continueUserSwitch(UserStartedState uss, int oldUserId, int newUserId) {
         completeSwitchAndInitalize(uss, newUserId, false, true);
     }
@@ -17653,6 +18575,7 @@
         if (userId <= 0) {
             throw new IllegalArgumentException("Can't stop primary user " + userId);
         }
+        enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, userId);
         synchronized (this) {
             return stopUserLocked(userId, callback);
         }
@@ -17660,7 +18583,7 @@
 
     private int stopUserLocked(final int userId, final IStopUserCallback callback) {
         if (DEBUG_MU) Slog.i(TAG_MU, "stopUserLocked userId=" + userId);
-        if (mCurrentUserId == userId) {
+        if (mCurrentUserId == userId && mTargetUserId == UserHandle.USER_NULL) {
             return ActivityManager.USER_OP_IS_CURRENT;
         }
 
@@ -17800,12 +18723,13 @@
             throw new SecurityException(msg);
         }
         synchronized (this) {
-            return getUserManagerLocked().getUserInfo(mCurrentUserId);
+            int userId = mTargetUserId != UserHandle.USER_NULL ? mTargetUserId : mCurrentUserId;
+            return getUserManagerLocked().getUserInfo(userId);
         }
     }
 
     int getCurrentUserIdLocked() {
-        return mCurrentUserId;
+        return mTargetUserId != UserHandle.USER_NULL ? mTargetUserId : mCurrentUserId;
     }
 
     @Override
@@ -17972,27 +18896,30 @@
             mCallingUid = callingUid;
         }
 
+        private void checkCaller() {
+            if (mCallingUid != Binder.getCallingUid()) {
+                throw new SecurityException("Caller " + mCallingUid
+                        + " does not match caller of getAppTasks(): " + Binder.getCallingUid());
+            }
+        }
+
         @Override
         public void finishAndRemoveTask() {
-            // Ensure that we are called from the same process that created this AppTask
-            if (mCallingUid != Binder.getCallingUid()) {
-                Slog.w(TAG, "finishAndRemoveTask: caller " + mCallingUid
-                        + " does not match caller of getAppTasks(): " + Binder.getCallingUid());
-                return;
-            }
+            checkCaller();
 
             synchronized (ActivityManagerService.this) {
                 long origId = Binder.clearCallingIdentity();
                 try {
                     TaskRecord tr = recentTaskForIdLocked(mTaskId);
-                    if (tr != null) {
-                        // Only kill the process if we are not a new document
-                        int flags = tr.getBaseIntent().getFlags();
-                        boolean isDocument = (flags & Intent.FLAG_ACTIVITY_NEW_DOCUMENT) ==
-                                Intent.FLAG_ACTIVITY_NEW_DOCUMENT;
-                        removeTaskByIdLocked(mTaskId,
-                                !isDocument ? ActivityManager.REMOVE_TASK_KILL_PROCESS : 0);
+                    if (tr == null) {
+                        throw new IllegalArgumentException("Unable to find task ID " + mTaskId);
                     }
+                    // Only kill the process if we are not a new document
+                    int flags = tr.getBaseIntent().getFlags();
+                    boolean isDocument = (flags & Intent.FLAG_ACTIVITY_NEW_DOCUMENT) ==
+                            Intent.FLAG_ACTIVITY_NEW_DOCUMENT;
+                    removeTaskByIdLocked(mTaskId,
+                            !isDocument ? ActivityManager.REMOVE_TASK_KILL_PROCESS : 0);
                 } finally {
                     Binder.restoreCallingIdentity(origId);
                 }
@@ -18001,24 +18928,84 @@
 
         @Override
         public ActivityManager.RecentTaskInfo getTaskInfo() {
-            // Ensure that we are called from the same process that created this AppTask
-            if (mCallingUid != Binder.getCallingUid()) {
-                Slog.w(TAG, "finishAndRemoveTask: caller " + mCallingUid
-                        + " does not match caller of getAppTasks(): " + Binder.getCallingUid());
-                return null;
-            }
+            checkCaller();
 
             synchronized (ActivityManagerService.this) {
                 long origId = Binder.clearCallingIdentity();
                 try {
                     TaskRecord tr = recentTaskForIdLocked(mTaskId);
-                    if (tr != null) {
-                        return createRecentTaskInfoFromTaskRecord(tr);
+                    if (tr == null) {
+                        throw new IllegalArgumentException("Unable to find task ID " + mTaskId);
+                    }
+                    return createRecentTaskInfoFromTaskRecord(tr);
+                } finally {
+                    Binder.restoreCallingIdentity(origId);
+                }
+            }
+        }
+
+        @Override
+        public void moveToFront() {
+            checkCaller();
+
+            final TaskRecord tr;
+            synchronized (ActivityManagerService.this) {
+                tr = recentTaskForIdLocked(mTaskId);
+                if (tr == null) {
+                    throw new IllegalArgumentException("Unable to find task ID " + mTaskId);
+                }
+                if (tr.getRootActivity() != null) {
+                    moveTaskToFrontLocked(tr.taskId, 0, null);
+                }
+            }
+
+            startActivityFromRecentsInner(tr.taskId, null);
+        }
+
+        @Override
+        public int startActivity(IBinder whoThread, String callingPackage,
+                Intent intent, String resolvedType, Bundle options) {
+            checkCaller();
+
+            int callingUser = UserHandle.getCallingUserId();
+            TaskRecord tr;
+            IApplicationThread appThread;
+            synchronized (ActivityManagerService.this) {
+                tr = recentTaskForIdLocked(mTaskId);
+                if (tr == null) {
+                    throw new IllegalArgumentException("Unable to find task ID " + mTaskId);
+                }
+                appThread = ApplicationThreadNative.asInterface(whoThread);
+                if (appThread == null) {
+                    throw new IllegalArgumentException("Bad app thread " + appThread);
+                }
+            }
+            return mStackSupervisor.startActivityMayWait(appThread, -1, callingPackage, intent,
+                    resolvedType, null, null, null, null, 0, 0, null, null,
+                    null, options, callingUser, null, tr);
+        }
+
+        @Override
+        public void setExcludeFromRecents(boolean exclude) {
+            checkCaller();
+
+            synchronized (ActivityManagerService.this) {
+                long origId = Binder.clearCallingIdentity();
+                try {
+                    TaskRecord tr = recentTaskForIdLocked(mTaskId);
+                    if (tr == null) {
+                        throw new IllegalArgumentException("Unable to find task ID " + mTaskId);
+                    }
+                    Intent intent = tr.getBaseIntent();
+                    if (exclude) {
+                        intent.addFlags(Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
+                    } else {
+                        intent.setFlags(intent.getFlags()
+                                & ~Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS);
                     }
                 } finally {
                     Binder.restoreCallingIdentity(origId);
                 }
-                return null;
             }
         }
     }
diff --git a/services/core/java/com/android/server/am/ActivityRecord.java b/services/core/java/com/android/server/am/ActivityRecord.java
index e528d57..adea271 100755
--- a/services/core/java/com/android/server/am/ActivityRecord.java
+++ b/services/core/java/com/android/server/am/ActivityRecord.java
@@ -575,6 +575,10 @@
 
     void makeFinishing() {
         if (!finishing) {
+            if (this == task.stack.getVisibleBehindActivity()) {
+                // A finishing activity should not remain as visible in the background
+                mStackSupervisor.requestVisibleBehindLocked(this, false);
+            }
             finishing = true;
             if (stopped) {
                 clearOptionsLocked();
@@ -694,12 +698,12 @@
                 case ActivityOptions.ANIM_SCALE_UP:
                     service.mWindowManager.overridePendingAppTransitionScaleUp(
                             pendingOptions.getStartX(), pendingOptions.getStartY(),
-                            pendingOptions.getStartWidth(), pendingOptions.getStartHeight());
+                            pendingOptions.getWidth(), pendingOptions.getHeight());
                     if (intent.getSourceBounds() == null) {
                         intent.setSourceBounds(new Rect(pendingOptions.getStartX(),
                                 pendingOptions.getStartY(),
-                                pendingOptions.getStartX()+pendingOptions.getStartWidth(),
-                                pendingOptions.getStartY()+pendingOptions.getStartHeight()));
+                                pendingOptions.getStartX()+pendingOptions.getWidth(),
+                                pendingOptions.getStartY()+pendingOptions.getHeight()));
                     }
                     break;
                 case ActivityOptions.ANIM_THUMBNAIL_SCALE_UP:
@@ -719,6 +723,21 @@
                                         + pendingOptions.getThumbnail().getHeight()));
                     }
                     break;
+                case ActivityOptions.ANIM_THUMBNAIL_ASPECT_SCALE_UP:
+                case ActivityOptions.ANIM_THUMBNAIL_ASPECT_SCALE_DOWN:
+                    service.mWindowManager.overridePendingAppTransitionAspectScaledThumb(
+                            pendingOptions.getThumbnail(),
+                            pendingOptions.getStartX(), pendingOptions.getStartY(),
+                            pendingOptions.getWidth(), pendingOptions.getHeight(),
+                            pendingOptions.getOnAnimationStartListener(),
+                            (animationType == ActivityOptions.ANIM_THUMBNAIL_ASPECT_SCALE_UP));
+                    if (intent.getSourceBounds() == null) {
+                        intent.setSourceBounds(new Rect(pendingOptions.getStartX(),
+                                pendingOptions.getStartY(),
+                                pendingOptions.getStartX() + pendingOptions.getWidth(),
+                                pendingOptions.getStartY() + pendingOptions.getHeight()));
+                    }
+                    break;
                 default:
                     Slog.e(TAG, "applyOptionsLocked: Unknown animationType=" + animationType);
                     break;
@@ -769,8 +788,8 @@
         if (newThumbnail != null) {
             if (ActivityManagerService.DEBUG_THUMBNAILS) Slog.i(ActivityManagerService.TAG,
                     "Setting thumbnail of " + this + " to " + newThumbnail);
-            task.setLastThumbnail(newThumbnail);
-            if (isPersistable()) {
+            boolean thumbnailUpdated = task.setLastThumbnail(newThumbnail);
+            if (thumbnailUpdated && isPersistable()) {
                 mStackSupervisor.mService.notifyTaskPersisterLocked(task, false);
             }
         }
@@ -898,6 +917,7 @@
             if (displayStartTime != 0) {
                 reportLaunchTimeLocked(SystemClock.uptimeMillis());
             }
+            mStackSupervisor.sendWaitingVisibleReportLocked(this);
             startTime = 0;
             finishLaunchTickingLocked();
             if (task != null) {
@@ -1050,8 +1070,26 @@
         return null;
     }
 
-    private static String createImageFilename(ActivityRecord r, int taskId) {
-        return String.valueOf(taskId) + ACTIVITY_ICON_SUFFIX + r.createTime +
+    final boolean isDestroyable() {
+        if (finishing || app == null || state == ActivityState.DESTROYING
+                || state == ActivityState.DESTROYED) {
+            // This would be redundant.
+            return false;
+        }
+        if (task == null || task.stack == null || this == task.stack.mResumedActivity
+                || this == task.stack.mPausingActivity || !haveState || !stopped) {
+            // We're not ready for this kind of thing.
+            return false;
+        }
+        if (visible) {
+            // The user would notice this!
+            return false;
+        }
+        return true;
+    }
+
+    private static String createImageFilename(long createTime, int taskId) {
+        return String.valueOf(taskId) + ACTIVITY_ICON_SUFFIX + createTime +
                 TaskPersister.IMAGE_EXTENSION;
     }
 
@@ -1068,7 +1106,7 @@
         out.attribute(null, ATTR_USERID, String.valueOf(userId));
 
         if (taskDescription != null) {
-            task.saveTaskDescription(taskDescription, createImageFilename(this, task.taskId),
+            task.saveTaskDescription(taskDescription, createImageFilename(createTime, task.taskId),
                     out);
         }
 
@@ -1149,7 +1187,7 @@
 
         final ActivityManagerService service = stackSupervisor.mService;
         final ActivityInfo aInfo = stackSupervisor.resolveActivity(intent, resolvedType, 0, null,
-                null, userId);
+                userId);
         if (aInfo == null) {
             throw new XmlPullParserException("restoreActivity resolver error. Intent=" + intent +
                     " resolvedType=" + resolvedType);
@@ -1161,7 +1199,8 @@
         r.persistentState = persistentState;
 
         if (createTime >= 0) {
-            taskDescription.setIcon(TaskPersister.restoreImage(createImageFilename(r, taskId)));
+            taskDescription.setIcon(TaskPersister.restoreImage(createImageFilename(createTime,
+                    taskId)));
         }
         r.taskDescription = taskDescription;
         r.createTime = createTime;
diff --git a/services/core/java/com/android/server/am/ActivityStack.java b/services/core/java/com/android/server/am/ActivityStack.java
index e309a03..a75fc5a 100755
--- a/services/core/java/com/android/server/am/ActivityStack.java
+++ b/services/core/java/com/android/server/am/ActivityStack.java
@@ -36,11 +36,13 @@
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_ADD_REMOVE;
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_APP;
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_CONTAINERS;
+import static com.android.server.am.ActivityStackSupervisor.DEBUG_RELEASE;
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_SAVED_STATE;
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_SCREENSHOTS;
 import static com.android.server.am.ActivityStackSupervisor.DEBUG_STATES;
 import static com.android.server.am.ActivityStackSupervisor.HOME_STACK_ID;
 
+import android.util.ArraySet;
 import com.android.internal.app.IVoiceInteractor;
 import com.android.internal.os.BatteryStatsImpl;
 import com.android.server.Watchdog;
@@ -227,9 +229,6 @@
     private ActivityRecord mLastScreenshotActivity = null;
     private Bitmap mLastScreenshotBitmap = null;
 
-    int mThumbnailWidth = -1;
-    int mThumbnailHeight = -1;
-
     int mCurrentUser;
 
     final int mStackId;
@@ -242,6 +241,9 @@
     /** Run all ActivityStacks through this */
     final ActivityStackSupervisor mStackSupervisor;
 
+    /** Used to keep resumeTopActivityLocked() from being entered recursively */
+    private boolean inResumeTopActivity;
+
     static final int PAUSE_TIMEOUT_MSG = ActivityManagerService.FIRST_ACTIVITY_STACK_MSG + 1;
     static final int DESTROY_TIMEOUT_MSG = ActivityManagerService.FIRST_ACTIVITY_STACK_MSG + 2;
     static final int LAUNCH_TICK_MSG = ActivityManagerService.FIRST_ACTIVITY_STACK_MSG + 3;
@@ -282,7 +284,7 @@
                         if (r.app != null) {
                             mService.logAppTooSlow(r.app, r.pauseTime, "pausing " + r);
                         }
-                        activityPausedLocked(r.appToken, true, r.persistentState);
+                        activityPausedLocked(r.appToken, true);
                     }
                 } break;
                 case LAUNCH_TICK_MSG: {
@@ -353,10 +355,6 @@
         mWindowManager = mService.mWindowManager;
         mStackId = activityContainer.mStackId;
         mCurrentUser = mService.mCurrentUserId;
-        // Get the activity screenshot thumbnail dimensions
-        Resources res = mService.mContext.getResources();
-        mThumbnailWidth = res.getDimensionPixelSize(com.android.internal.R.dimen.thumbnail_width);
-        mThumbnailHeight = res.getDimensionPixelSize(com.android.internal.R.dimen.thumbnail_height);
     }
 
     /**
@@ -427,13 +425,13 @@
     }
 
     final ActivityRecord topActivity() {
-        // Iterate to find the first non-empty task stack. Note that this code can
-        // be simplified once we stop storing tasks with empty mActivities lists.
         for (int taskNdx = mTaskHistory.size() - 1; taskNdx >= 0; --taskNdx) {
             ArrayList<ActivityRecord> activities = mTaskHistory.get(taskNdx).mActivities;
-            final int topActivityNdx = activities.size() - 1;
-            if (topActivityNdx >= 0) {
-                return activities.get(topActivityNdx);
+            for (int activityNdx = activities.size() - 1; activityNdx >= 0; --activityNdx) {
+                final ActivityRecord r = activities.get(activityNdx);
+                if (!r.finishing) {
+                    return r;
+                }
             }
         }
         return null;
@@ -461,7 +459,7 @@
         final ActivityRecord r = ActivityRecord.forToken(token);
         if (r != null) {
             final TaskRecord task = r.task;
-            if (task.mActivities.contains(r) && mTaskHistory.contains(task)) {
+            if (task != null && task.mActivities.contains(r) && mTaskHistory.contains(task)) {
                 if (task.stack != this) Slog.w(TAG,
                     "Illegal state! task does not point to stack it is in.");
                 return r;
@@ -552,10 +550,10 @@
 
             if (DEBUG_TASKS) Slog.d(TAG, "Comparing existing cls="
                     + taskIntent.getComponent().flattenToShortString()
-                    + "/aff=" + r.task.affinity + " to new cls="
+                    + "/aff=" + r.task.rootAffinity + " to new cls="
                     + intent.getComponent().flattenToShortString() + "/aff=" + info.taskAffinity);
-            if (!isDocument && !taskIsDocument && task.affinity != null) {
-                if (task.affinity.equals(target.taskAffinity)) {
+            if (!isDocument && !taskIsDocument && task.rootAffinity != null) {
+                if (task.rootAffinity.equals(target.taskAffinity)) {
                     if (DEBUG_TASKS) Slog.d(TAG, "Found matching affinity!");
                     return r;
                 }
@@ -714,7 +712,7 @@
             // Still have something resumed; can't sleep until it is paused.
             if (DEBUG_PAUSE) Slog.v(TAG, "Sleep needs to pause " + mResumedActivity);
             if (DEBUG_USER_LEAVING) Slog.v(TAG, "Sleep => pause with userLeaving=false");
-            startPausingLocked(false, true);
+            startPausingLocked(false, true, false, false);
             return true;
         }
         if (mPausingActivity != null) {
@@ -771,8 +769,8 @@
             return null;
         }
 
-        int w = mThumbnailWidth;
-        int h = mThumbnailHeight;
+        int w = mService.mThumbnailWidth;
+        int h = mService.mThumbnailHeight;
         if (w > 0) {
             if (who != mLastScreenshotActivity || mLastScreenshotBitmap == null
                     || mLastScreenshotActivity.state == ActivityState.RESUMED
@@ -792,22 +790,38 @@
         return null;
     }
 
-    final void startPausingLocked(boolean userLeaving, boolean uiSleeping) {
+    /**
+     * Start pausing the currently resumed activity.  It is an error to call this if there
+     * is already an activity being paused or there is no resumed activity.
+     *
+     * @param userLeaving True if this should result in an onUserLeaving to the current activity.
+     * @param uiSleeping True if this is happening with the user interface going to sleep (the
+     * screen turning off).
+     * @param resuming True if this is being called as part of resuming the top activity, so
+     * we shouldn't try to instigate a resume here.
+     * @param dontWait True if the caller does not want to wait for the pause to complete.  If
+     * set to true, we will immediately complete the pause here before returning.
+     * @return Returns true if an activity now is in the PAUSING state, and we are waiting for
+     * it to tell us when it is done.
+     */
+    final boolean startPausingLocked(boolean userLeaving, boolean uiSleeping, boolean resuming,
+            boolean dontWait) {
         if (mPausingActivity != null) {
-            Slog.e(TAG, "Trying to pause when pause is already pending for "
-                  + mPausingActivity, new RuntimeException("here").fillInStackTrace());
+            Slog.wtf(TAG, "Going to pause when pause is already pending for " + mPausingActivity);
+            completePauseLocked(false);
         }
         ActivityRecord prev = mResumedActivity;
         if (prev == null) {
-            Slog.e(TAG, "Trying to pause when nothing is resumed",
-                    new RuntimeException("here").fillInStackTrace());
-            mStackSupervisor.resumeTopActivitiesLocked();
-            return;
+            if (!resuming) {
+                Slog.wtf(TAG, "Trying to pause when nothing is resumed");
+                mStackSupervisor.resumeTopActivitiesLocked();
+            }
+            return false;
         }
 
         if (mActivityContainer.mParentActivity == null) {
             // Top level stack, not a child. Look for child stacks.
-            mStackSupervisor.pauseChildStacks(prev, userLeaving, uiSleeping);
+            mStackSupervisor.pauseChildStacks(prev, userLeaving, uiSleeping, resuming, dontWait);
         }
 
         if (DEBUG_STATES) Slog.v(TAG, "Moving to PAUSING: " + prev);
@@ -836,7 +850,7 @@
                         prev.shortComponentName);
                 mService.updateUsageStats(prev, false);
                 prev.app.thread.schedulePauseActivity(prev.appToken, prev.finishing,
-                        userLeaving, prev.configChangeFlags);
+                        userLeaving, prev.configChangeFlags, dontWait);
             } catch (Exception e) {
                 // Ignore exception, if process died other code will cleanup.
                 Slog.w(TAG, "Exception thrown during pause", e);
@@ -867,39 +881,46 @@
                 if (DEBUG_PAUSE) Slog.v(TAG, "Key dispatch not paused for screen off");
             }
 
-            // Schedule a pause timeout in case the app doesn't respond.
-            // We don't give it much time because this directly impacts the
-            // responsiveness seen by the user.
-            Message msg = mHandler.obtainMessage(PAUSE_TIMEOUT_MSG);
-            msg.obj = prev;
-            prev.pauseTime = SystemClock.uptimeMillis();
-            mHandler.sendMessageDelayed(msg, PAUSE_TIMEOUT);
-            if (DEBUG_PAUSE) Slog.v(TAG, "Waiting for pause to complete...");
+            if (dontWait) {
+                // If the caller said they don't want to wait for the pause, then complete
+                // the pause now.
+                completePauseLocked(false);
+                return false;
+
+            } else {
+                // Schedule a pause timeout in case the app doesn't respond.
+                // We don't give it much time because this directly impacts the
+                // responsiveness seen by the user.
+                Message msg = mHandler.obtainMessage(PAUSE_TIMEOUT_MSG);
+                msg.obj = prev;
+                prev.pauseTime = SystemClock.uptimeMillis();
+                mHandler.sendMessageDelayed(msg, PAUSE_TIMEOUT);
+                if (DEBUG_PAUSE) Slog.v(TAG, "Waiting for pause to complete...");
+                return true;
+            }
+
         } else {
             // This activity failed to schedule the
             // pause, so just treat it as being paused now.
             if (DEBUG_PAUSE) Slog.v(TAG, "Activity not running, resuming next.");
-            mStackSupervisor.getFocusedStack().resumeTopActivityLocked(null);
+            if (!resuming) {
+                mStackSupervisor.getFocusedStack().resumeTopActivityLocked(null);
+            }
+            return false;
         }
     }
 
-    final void activityPausedLocked(IBinder token, boolean timeout,
-            PersistableBundle persistentState) {
+    final void activityPausedLocked(IBinder token, boolean timeout) {
         if (DEBUG_PAUSE) Slog.v(
             TAG, "Activity paused: token=" + token + ", timeout=" + timeout);
 
         final ActivityRecord r = isInStackLocked(token);
         if (r != null) {
             mHandler.removeMessages(PAUSE_TIMEOUT_MSG, r);
-            if (persistentState != null) {
-                r.persistentState = persistentState;
-                mService.notifyTaskPersisterLocked(r.task, false);
-            }
             if (mPausingActivity == r) {
                 if (DEBUG_STATES) Slog.v(TAG, "Moving to PAUSED: " + r
                         + (timeout ? " (due to timeout)" : " (pause complete)"));
-                r.state = ActivityState.PAUSED;
-                completePauseLocked();
+                completePauseLocked(true);
             } else {
                 EventLog.writeEvent(EventLogTags.AM_FAILED_TO_PAUSE,
                         r.userId, System.identityHashCode(r), r.shortComponentName,
@@ -950,11 +971,12 @@
         }
     }
 
-    private void completePauseLocked() {
+    private void completePauseLocked(boolean resumeNext) {
         ActivityRecord prev = mPausingActivity;
         if (DEBUG_PAUSE) Slog.v(TAG, "Complete pause: " + prev);
 
         if (prev != null) {
+            prev.state = ActivityState.PAUSED;
             if (prev.finishing) {
                 if (DEBUG_PAUSE) Slog.v(TAG, "Executing finish of activity: " + prev);
                 prev = finishCurrentActivityLocked(prev, FINISH_AFTER_VISIBLE, false);
@@ -997,19 +1019,21 @@
             mPausingActivity = null;
         }
 
-        final ActivityStack topStack = mStackSupervisor.getFocusedStack();
-        if (!mService.isSleepingOrShuttingDown()) {
-            mStackSupervisor.resumeTopActivitiesLocked(topStack, prev, null);
-        } else {
-            mStackSupervisor.checkReadyForSleepLocked();
-            ActivityRecord top = topStack.topRunningActivityLocked(null);
-            if (top == null || (prev != null && top != prev)) {
-                // If there are no more activities available to run,
-                // do resume anyway to start something.  Also if the top
-                // activity on the stack is not the just paused activity,
-                // we need to go ahead and resume it to ensure we complete
-                // an in-flight app switch.
-                mStackSupervisor.resumeTopActivitiesLocked(topStack, null, null);
+        if (resumeNext) {
+            final ActivityStack topStack = mStackSupervisor.getFocusedStack();
+            if (!mService.isSleepingOrShuttingDown()) {
+                mStackSupervisor.resumeTopActivitiesLocked(topStack, prev, null);
+            } else {
+                mStackSupervisor.checkReadyForSleepLocked();
+                ActivityRecord top = topStack.topRunningActivityLocked(null);
+                if (top == null || (prev != null && top != prev)) {
+                    // If there are no more activities available to run,
+                    // do resume anyway to start something.  Also if the top
+                    // activity on the stack is not the just paused activity,
+                    // we need to go ahead and resume it to ensure we complete
+                    // an in-flight app switch.
+                    mStackSupervisor.resumeTopActivitiesLocked(topStack, null, null);
+                }
             }
         }
 
@@ -1018,11 +1042,8 @@
 
             if (prev.app != null && prev.cpuTimeAtResume > 0
                     && mService.mBatteryStatsService.isOnBattery()) {
-                long diff;
-                synchronized (mService.mProcessCpuThread) {
-                    diff = mService.mProcessCpuTracker.getCpuTimeForPid(prev.app.pid)
-                            - prev.cpuTimeAtResume;
-                }
+                long diff = mService.mProcessCpuTracker.getCpuTimeForPid(prev.app.pid)
+                        - prev.cpuTimeAtResume;
                 if (diff > 0) {
                     BatteryStatsImpl bsi = mService.mBatteryStatsService.getActiveStatistics();
                     synchronized (bsi) {
@@ -1073,9 +1094,7 @@
         // TODO: To be more accurate, the mark should be before the onCreate,
         //       not after the onResume. But for subsequent starts, onResume is fine.
         if (next.app != null) {
-            synchronized (mService.mProcessCpuThread) {
-                next.cpuTimeAtResume = mService.mProcessCpuTracker.getCpuTimeForPid(next.app.pid);
-            }
+            next.cpuTimeAtResume = mService.mProcessCpuTracker.getCpuTimeForPid(next.app.pid);
         } else {
             next.cpuTimeAtResume = 0; // Couldn't get the cpu time of process
         }
@@ -1444,6 +1463,23 @@
     }
 
     final boolean resumeTopActivityLocked(ActivityRecord prev, Bundle options) {
+        if (inResumeTopActivity) {
+            // Don't even start recursing.
+            return false;
+        }
+
+        boolean result = false;
+        try {
+            // Protect against recursion.
+            inResumeTopActivity = true;
+            result = resumeTopActivityInnerLocked(prev, options);
+        } finally {
+            inResumeTopActivity = false;
+        }
+        return result;
+    }
+
+    final boolean resumeTopActivityInnerLocked(ActivityRecord prev, Bundle options) {
         if (ActivityManagerService.DEBUG_LOCKSCREEN) mService.logLockScreen("");
 
         ActivityRecord parent = mActivityContainer.mParentActivity;
@@ -1490,6 +1526,9 @@
             ActivityOptions.abort(options);
             if (DEBUG_STATES) Slog.d(TAG, "resumeTopActivityLocked: Top activity resumed " + next);
             if (DEBUG_STACK) mStackSupervisor.validateTopActivitiesLocked();
+
+            // Make sure to notify Keyguard as well if it is waiting for an activity to be drawn.
+            mStackSupervisor.notifyActivityDrawnForKeyguard();
             return false;
         }
 
@@ -1589,10 +1628,10 @@
 
         // We need to start pausing the current activity so the top one
         // can be resumed...
-        boolean pausing = mStackSupervisor.pauseBackStacks(userLeaving);
+        boolean dontWaitForPause = (next.info.flags&ActivityInfo.FLAG_RESUME_WHILE_PAUSING) != 0;
+        boolean pausing = mStackSupervisor.pauseBackStacks(userLeaving, true, dontWaitForPause);
         if (mResumedActivity != null) {
-            pausing = true;
-            startPausingLocked(userLeaving, false);
+            pausing |= startPausingLocked(userLeaving, false, true, dontWaitForPause);
             if (DEBUG_STATES) Slog.d(TAG, "resumeTopActivityLocked: Pausing " + mResumedActivity);
         }
         if (pausing) {
@@ -2702,7 +2741,7 @@
             if (mPausingActivity == null) {
                 if (DEBUG_PAUSE) Slog.v(TAG, "Finish needs to pause: " + r);
                 if (DEBUG_USER_LEAVING) Slog.v(TAG, "finish() => pause with userLeaving=false");
-                startPausingLocked(false, false);
+                startPausingLocked(false, false, false, false);
             }
 
             if (endTask) {
@@ -2806,6 +2845,42 @@
         }
     }
 
+    final boolean shouldUpRecreateTaskLocked(ActivityRecord srec, String destAffinity) {
+        // Basic case: for simple app-centric recents, we need to recreate
+        // the task if the affinity has changed.
+        if (srec == null || srec.task.affinity == null ||
+                !srec.task.affinity.equals(destAffinity)) {
+            return true;
+        }
+        // Document-centric case: an app may be split in to multiple documents;
+        // they need to re-create their task if this current activity is the root
+        // of a document, unless simply finishing it will return them to the the
+        // correct app behind.
+        if (srec.frontOfTask && srec.task != null) {
+            // Okay, this activity is at the root of its task.  What to do, what to do...
+            if (srec.task.getTaskToReturnTo() != ActivityRecord.APPLICATION_ACTIVITY_TYPE) {
+                // Finishing won't return to an application, so we need to recreate.
+                return true;
+            }
+            // We now need to get the task below it to determine what to do.
+            int taskIdx = mTaskHistory.indexOf(srec.task);
+            if (taskIdx <= 0) {
+                Slog.w(TAG, "shouldUpRecreateTask: task not in history for " + srec);
+                return false;
+            }
+            if (taskIdx == 0) {
+                // At the bottom of the stack, nothing to go back to.
+                return true;
+            }
+            TaskRecord prevTask = mTaskHistory.get(taskIdx);
+            if (!srec.task.affinity.equals(prevTask.affinity)) {
+                // These are different apps, so need to recreate.
+                return true;
+            }
+        }
+        return false;
+    }
+
     final boolean navigateUpToLocked(IBinder token, Intent destIntent, int resultCode,
             Intent resultData) {
         final ActivityRecord srec = ActivityRecord.forToken(token);
@@ -2874,7 +2949,7 @@
                     int res = mStackSupervisor.startActivityLocked(srec.app.thread, destIntent,
                             null, aInfo, null, null, parent.appToken, null,
                             0, -1, parent.launchedFromUid, parent.launchedFromPackage,
-                            0, null, true, null, null);
+                            -1, parent.launchedFromUid, 0, null, true, null, null, null);
                     foundParentInTask = res == ActivityManager.START_SUCCESS;
                 } catch (RemoteException e) {
                     foundParentInTask = false;
@@ -3022,15 +3097,10 @@
                 if (!lastIsOpaque) {
                     continue;
                 }
-                // We can destroy this one if we have its icicle saved and
-                // it is not in the process of pausing/stopping/finishing.
-                if (r.app != null && r != mResumedActivity && r != mPausingActivity
-                        && r.haveState && !r.visible && r.stopped
-                        && r.state != ActivityState.DESTROYING
-                        && r.state != ActivityState.DESTROYED) {
+                if (r.isDestroyable()) {
                     if (DEBUG_SWITCH) Slog.v(TAG, "Destroying " + r + " in state " + r.state
                             + " resumed=" + mResumedActivity
-                            + " pausing=" + mPausingActivity);
+                            + " pausing=" + mPausingActivity + " for reason " + reason);
                     if (destroyActivityLocked(r, true, reason)) {
                         activityRemoved = true;
                     }
@@ -3042,6 +3112,60 @@
         }
     }
 
+    final boolean safelyDestroyActivityLocked(ActivityRecord r, String reason) {
+        if (r.isDestroyable()) {
+            if (DEBUG_SWITCH) Slog.v(TAG, "Destroying " + r + " in state " + r.state
+                    + " resumed=" + mResumedActivity
+                    + " pausing=" + mPausingActivity + " for reason " + reason);
+            return destroyActivityLocked(r, true, reason);
+        }
+        return false;
+    }
+
+    final int releaseSomeActivitiesLocked(ProcessRecord app, ArraySet<TaskRecord> tasks,
+            String reason) {
+        // Iterate over tasks starting at the back (oldest) first.
+        if (DEBUG_RELEASE) Slog.d(TAG, "Trying to release some activities in " + app);
+        int maxTasks = tasks.size() / 4;
+        if (maxTasks < 1) {
+            maxTasks = 1;
+        }
+        int numReleased = 0;
+        for (int taskNdx = 0; taskNdx < mTaskHistory.size() && maxTasks > 0; taskNdx++) {
+            final TaskRecord task = mTaskHistory.get(taskNdx);
+            if (!tasks.contains(task)) {
+                continue;
+            }
+            if (DEBUG_RELEASE) Slog.d(TAG, "Looking for activities to release in " + task);
+            int curNum = 0;
+            final ArrayList<ActivityRecord> activities = task.mActivities;
+            for (int actNdx = 0; actNdx < activities.size(); actNdx++) {
+                final ActivityRecord activity = activities.get(actNdx);
+                if (activity.app == app && activity.isDestroyable()) {
+                    if (DEBUG_RELEASE) Slog.v(TAG, "Destroying " + activity
+                            + " in state " + activity.state + " resumed=" + mResumedActivity
+                            + " pausing=" + mPausingActivity + " for reason " + reason);
+                    destroyActivityLocked(activity, true, reason);
+                    if (activities.get(actNdx) != activity) {
+                        // Was removed from list, back up so we don't miss the next one.
+                        actNdx--;
+                    }
+                    curNum++;
+                }
+            }
+            if (curNum > 0) {
+                numReleased += curNum;
+                maxTasks--;
+                if (mTaskHistory.get(taskNdx) != task) {
+                    // The entire task got removed, back up so we don't miss the next one.
+                    taskNdx--;
+                }
+            }
+        }
+        if (DEBUG_RELEASE) Slog.d(TAG, "Done releasing: did " + numReleased + " activities");
+        return numReleased;
+    }
+
     /**
      * Destroy the current CLIENT SIDE instance of an activity.  This may be
      * called both when actually finishing an activity, or when performing
@@ -3071,6 +3195,9 @@
                             ActivityManagerService.CANCEL_HEAVY_NOTIFICATION_MSG);
                 }
                 if (r.app.activities.isEmpty()) {
+                    // Update any services we are bound to that might care about whether
+                    // their client may have activities.
+                    mService.mServices.updateServiceConnectionActivitiesLocked(r.app);
                     // No longer have activities, so update LRU list and oom adj.
                     mService.updateLruProcessLocked(r.app, false, null);
                     mService.updateOomAdjLocked();
@@ -3763,7 +3890,7 @@
             if (activities.isEmpty()) {
                 continue;
             }
-            if (!allowed && !task.isHomeTask() && task.creatorUid != callingUid) {
+            if (!allowed && !task.isHomeTask() && task.effectiveUid != callingUid) {
                 continue;
             }
             for (int activityNdx = activities.size() - 1; activityNdx >= 0; --activityNdx) {
@@ -3953,7 +4080,7 @@
                 // Task creator asked to remove this when done, or this task was a voice
                 // interaction, so it should not remain on the recent tasks list.
                 mService.mRecentTasks.remove(task);
-                task.closeRecentsChain();
+                task.removedFromRecents(mService.mTaskPersister);
             }
         }
 
diff --git a/services/core/java/com/android/server/am/ActivityStackSupervisor.java b/services/core/java/com/android/server/am/ActivityStackSupervisor.java
index 1107139..482a582 100644
--- a/services/core/java/com/android/server/am/ActivityStackSupervisor.java
+++ b/services/core/java/com/android/server/am/ActivityStackSupervisor.java
@@ -45,6 +45,7 @@
 import android.app.IActivityManager;
 import android.app.IApplicationThread;
 import android.app.PendingIntent;
+import android.app.ProfilerInfo;
 import android.app.ActivityManager.RunningTaskInfo;
 import android.app.IActivityManager.WaitResult;
 import android.app.ResultInfo;
@@ -84,6 +85,7 @@
 import android.provider.Settings;
 import android.provider.Settings.SettingNotFoundException;
 import android.service.voice.IVoiceInteractionSession;
+import android.util.ArraySet;
 import android.util.EventLog;
 import android.util.Slog;
 import android.util.SparseArray;
@@ -115,10 +117,11 @@
     static final boolean DEBUG_APP = DEBUG || false;
     static final boolean DEBUG_CONTAINERS = DEBUG || false;
     static final boolean DEBUG_IDLE = DEBUG || false;
-    static final boolean DEBUG_VISIBLE_BEHIND = DEBUG || false;
+    static final boolean DEBUG_RELEASE = DEBUG || false;
     static final boolean DEBUG_SAVED_STATE = DEBUG || false;
     static final boolean DEBUG_SCREENSHOTS = DEBUG || false;
     static final boolean DEBUG_STATES = DEBUG || false;
+    static final boolean DEBUG_VISIBLE_BEHIND = DEBUG || false;
 
     public static final int HOME_STACK_ID = 0;
 
@@ -347,6 +350,9 @@
             for (int displayNdx = displays.length - 1; displayNdx >= 0; --displayNdx) {
                 final int displayId = displays[displayNdx].getDisplayId();
                 ActivityDisplay activityDisplay = new ActivityDisplay(displayId);
+                if (activityDisplay.mDisplay == null) {
+                    throw new IllegalStateException("Default Display does not exist");
+                }
                 mActivityDisplays.put(displayId, activityDisplay);
             }
 
@@ -589,7 +595,7 @@
      * @param userLeaving Passed to pauseActivity() to indicate whether to call onUserLeaving().
      * @return true if any activity was paused as a result of this call.
      */
-    boolean pauseBackStacks(boolean userLeaving) {
+    boolean pauseBackStacks(boolean userLeaving, boolean resuming, boolean dontWait) {
         boolean someActivityPaused = false;
         for (int displayNdx = mActivityDisplays.size() - 1; displayNdx >= 0; --displayNdx) {
             ArrayList<ActivityStack> stacks = mActivityDisplays.valueAt(displayNdx).mStacks;
@@ -598,8 +604,8 @@
                 if (!isFrontStack(stack) && stack.mResumedActivity != null) {
                     if (DEBUG_STATES) Slog.d(TAG, "pauseBackStacks: stack=" + stack +
                             " mResumedActivity=" + stack.mResumedActivity);
-                    stack.startPausingLocked(userLeaving, false);
-                    someActivityPaused = true;
+                    someActivityPaused |= stack.startPausingLocked(userLeaving, false, resuming,
+                            dontWait);
                 }
             }
         }
@@ -628,7 +634,8 @@
         return pausing;
     }
 
-    void pauseChildStacks(ActivityRecord parent, boolean userLeaving, boolean uiSleeping) {
+    void pauseChildStacks(ActivityRecord parent, boolean userLeaving, boolean uiSleeping,
+            boolean resuming, boolean dontWait) {
         // TODO: Put all stacks in supervisor and iterate through them instead.
         for (int displayNdx = mActivityDisplays.size() - 1; displayNdx >= 0; --displayNdx) {
             ArrayList<ActivityStack> stacks = mActivityDisplays.valueAt(displayNdx).mStacks;
@@ -636,38 +643,54 @@
                 final ActivityStack stack = stacks.get(stackNdx);
                 if (stack.mResumedActivity != null &&
                         stack.mActivityContainer.mParentActivity == parent) {
-                    stack.startPausingLocked(userLeaving, uiSleeping);
+                    stack.startPausingLocked(userLeaving, uiSleeping, resuming, dontWait);
                 }
             }
         }
     }
 
     void reportActivityVisibleLocked(ActivityRecord r) {
+        sendWaitingVisibleReportLocked(r);
+        notifyActivityDrawnForKeyguard();
+    }
+
+    void sendWaitingVisibleReportLocked(ActivityRecord r) {
+        boolean changed = false;
         for (int i = mWaitingActivityVisible.size()-1; i >= 0; i--) {
             WaitResult w = mWaitingActivityVisible.get(i);
-            w.timeout = false;
-            if (r != null) {
-                w.who = new ComponentName(r.info.packageName, r.info.name);
+            if (w.who == null) {
+                changed = true;
+                w.timeout = false;
+                if (r != null) {
+                    w.who = new ComponentName(r.info.packageName, r.info.name);
+                }
+                w.totalTime = SystemClock.uptimeMillis() - w.thisTime;
+                w.thisTime = w.totalTime;
             }
-            w.totalTime = SystemClock.uptimeMillis() - w.thisTime;
-            w.thisTime = w.totalTime;
         }
-        mService.notifyAll();
-        notifyActivityDrawnForKeyguard();
+        if (changed) {
+            mService.notifyAll();
+        }
     }
 
     void reportActivityLaunchedLocked(boolean timeout, ActivityRecord r,
             long thisTime, long totalTime) {
+        boolean changed = false;
         for (int i = mWaitingActivityLaunched.size() - 1; i >= 0; i--) {
             WaitResult w = mWaitingActivityLaunched.remove(i);
-            w.timeout = timeout;
-            if (r != null) {
-                w.who = new ComponentName(r.info.packageName, r.info.name);
+            if (w.who == null) {
+                changed = true;
+                w.timeout = timeout;
+                if (r != null) {
+                    w.who = new ComponentName(r.info.packageName, r.info.name);
+                }
+                w.thisTime = thisTime;
+                w.totalTime = totalTime;
             }
-            w.thisTime = thisTime;
-            w.totalTime = totalTime;
         }
-        mService.notifyAll();
+        if (changed) {
+            mService.notifyAll();
+        }
     }
 
     ActivityRecord topRunningActivityLocked() {
@@ -732,7 +755,7 @@
     }
 
     ActivityInfo resolveActivity(Intent intent, String resolvedType, int startFlags,
-            String profileFile, ParcelFileDescriptor profileFd, int userId) {
+            ProfilerInfo profilerInfo, int userId) {
         // Collect information about the target of the Intent.
         ActivityInfo aInfo;
         try {
@@ -767,11 +790,9 @@
                 }
             }
 
-            if (profileFile != null) {
+            if (profilerInfo != null) {
                 if (!aInfo.processName.equals("system")) {
-                    mService.setProfileApp(aInfo.applicationInfo, aInfo.processName,
-                            profileFile, profileFd,
-                            (startFlags&ActivityManager.START_FLAG_AUTO_STOP_PROFILER) != 0);
+                    mService.setProfileApp(aInfo.applicationInfo, aInfo.processName, profilerInfo);
                 }
             }
         }
@@ -780,16 +801,16 @@
 
     void startHomeActivity(Intent intent, ActivityInfo aInfo) {
         moveHomeStackTaskToTop(HOME_ACTIVITY_TYPE);
-        startActivityLocked(null, intent, null, aInfo, null, null, null, null, 0, 0, 0, null, 0,
-                null, false, null, null);
+        startActivityLocked(null, intent, null, aInfo, null, null, null, null, 0, 0, 0, null,
+                0, 0, 0, null, false, null, null, null);
     }
 
     final int startActivityMayWait(IApplicationThread caller, int callingUid,
             String callingPackage, Intent intent, String resolvedType,
             IVoiceInteractionSession voiceSession, IVoiceInteractor voiceInteractor,
-            IBinder resultTo, String resultWho, int requestCode, int startFlags, String profileFile,
-            ParcelFileDescriptor profileFd, WaitResult outResult, Configuration config,
-            Bundle options, int userId, IActivityContainer iContainer) {
+            IBinder resultTo, String resultWho, int requestCode, int startFlags,
+            ProfilerInfo profilerInfo, WaitResult outResult, Configuration config,
+            Bundle options, int userId, IActivityContainer iContainer, TaskRecord inTask) {
         // Refuse possible leaked file descriptors
         if (intent != null && intent.hasFileDescriptors()) {
             throw new IllegalArgumentException("File descriptors passed in Intent");
@@ -801,16 +822,18 @@
 
         // Collect information about the target of the Intent.
         ActivityInfo aInfo = resolveActivity(intent, resolvedType, startFlags,
-                profileFile, profileFd, userId);
+                profilerInfo, userId);
 
         ActivityContainer container = (ActivityContainer)iContainer;
         synchronized (mService) {
+            final int realCallingPid = Binder.getCallingPid();
+            final int realCallingUid = Binder.getCallingUid();
             int callingPid;
             if (callingUid >= 0) {
                 callingPid = -1;
             } else if (caller == null) {
-                callingPid = Binder.getCallingPid();
-                callingUid = Binder.getCallingUid();
+                callingPid = realCallingPid;
+                callingUid = realCallingUid;
             } else {
                 callingPid = callingUid = -1;
             }
@@ -836,11 +859,11 @@
                     if (mService.mHeavyWeightProcess != null &&
                             (mService.mHeavyWeightProcess.info.uid != aInfo.applicationInfo.uid ||
                             !mService.mHeavyWeightProcess.processName.equals(aInfo.processName))) {
-                        int realCallingUid = callingUid;
+                        int appCallingUid = callingUid;
                         if (caller != null) {
                             ProcessRecord callerApp = mService.getRecordForAppLocked(caller);
                             if (callerApp != null) {
-                                realCallingUid = callerApp.info.uid;
+                                appCallingUid = callerApp.info.uid;
                             } else {
                                 Slog.w(TAG, "Unable to find app for caller " + caller
                                       + " (pid=" + callingPid + ") when starting: "
@@ -852,7 +875,7 @@
 
                         IIntentSender target = mService.getIntentSenderLocked(
                                 ActivityManager.INTENT_SENDER_ACTIVITY, "android",
-                                realCallingUid, userId, null, null, 0, new Intent[] { intent },
+                                appCallingUid, userId, null, null, 0, new Intent[] { intent },
                                 new String[] { resolvedType }, PendingIntent.FLAG_CANCEL_CURRENT
                                 | PendingIntent.FLAG_ONE_SHOT, null);
 
@@ -898,8 +921,9 @@
 
             int res = startActivityLocked(caller, intent, resolvedType, aInfo,
                     voiceSession, voiceInteractor, resultTo, resultWho,
-                    requestCode, callingPid, callingUid, callingPackage, startFlags, options,
-                    componentSpecified, null, container);
+                    requestCode, callingPid, callingUid, callingPackage,
+                    realCallingPid, realCallingUid, startFlags, options,
+                    componentSpecified, null, container, inTask);
 
             Binder.restoreCallingIdentity(origId);
 
@@ -928,7 +952,7 @@
                     } while (!outResult.timeout && outResult.who == null);
                 } else if (res == ActivityManager.START_TASK_TO_FRONT) {
                     ActivityRecord r = stack.topRunningActivityLocked(null);
-                    if (r.nowVisible) {
+                    if (r.nowVisible && r.state == ActivityState.RESUMED) {
                         outResult.timeout = false;
                         outResult.who = new ComponentName(r.info.packageName, r.info.name);
                         outResult.totalTime = 0;
@@ -994,8 +1018,7 @@
                     intent = new Intent(intent);
 
                     // Collect information about the target of the Intent.
-                    ActivityInfo aInfo = resolveActivity(intent, resolvedTypes[i],
-                            0, null, null, userId);
+                    ActivityInfo aInfo = resolveActivity(intent, resolvedTypes[i], 0, null, userId);
                     // TODO: New, check if this is correct
                     aInfo = mService.getActivityInfoForUser(aInfo, userId);
 
@@ -1013,8 +1036,9 @@
                         theseOptions = null;
                     }
                     int res = startActivityLocked(caller, intent, resolvedTypes[i],
-                            aInfo, null, null, resultTo, null, -1, callingPid, callingUid, callingPackage,
-                            0, theseOptions, componentSpecified, outActivity, null);
+                            aInfo, null, null, resultTo, null, -1, callingPid, callingUid,
+                            callingPackage, callingPid, callingUid,
+                            0, theseOptions, componentSpecified, outActivity, null, null);
                     if (res < 0) {
                         return res;
                     }
@@ -1098,13 +1122,11 @@
             r.compat = mService.compatibilityInfoForPackageLocked(r.info.applicationInfo);
             String profileFile = null;
             ParcelFileDescriptor profileFd = null;
-            boolean profileAutoStop = false;
             if (mService.mProfileApp != null && mService.mProfileApp.equals(app.processName)) {
                 if (mService.mProfileProc == null || mService.mProfileProc == app) {
                     mService.mProfileProc = app;
                     profileFile = mService.mProfileFile;
                     profileFd = mService.mProfileFd;
-                    profileAutoStop = mService.mAutoStopProfiler;
                 }
             }
             app.hasShownUi = true;
@@ -1123,13 +1145,15 @@
                 }
             }
 
+            ProfilerInfo profilerInfo = profileFile != null
+                    ? new ProfilerInfo(profileFile, profileFd, mService.mSamplingInterval,
+                    mService.mAutoStopProfiler) : null;
             app.forceProcessStateUpTo(ActivityManager.PROCESS_STATE_TOP);
             app.thread.scheduleLaunchActivity(new Intent(r.intent), r.appToken,
-                    System.identityHashCode(r), r.info,
-                    new Configuration(mService.mConfiguration), r.compat, r.task.voiceInteractor,
-                    app.repProcState, r.icicle, r.persistentState, results, newIntents, !andResume,
-                    mService.isNextTransitionForward(), profileFile, profileFd, profileAutoStop
-            );
+                    System.identityHashCode(r), r.info, new Configuration(mService.mConfiguration),
+                    r.compat, r.task.voiceInteractor, app.repProcState, r.icicle, r.persistentState,
+                    results, newIntents, !andResume, mService.isNextTransitionForward(),
+                    profilerInfo);
 
             if ((app.info.flags&ApplicationInfo.FLAG_CANT_SAVE_STATE) != 0) {
                 // This may be a heavy-weight process!  Note that the package
@@ -1199,6 +1223,10 @@
             mService.startSetupActivityLocked();
         }
 
+        // Update any services we are bound to that might care about whether
+        // their client may have activities.
+        mService.mServices.updateServiceConnectionActivitiesLocked(r.app);
+
         return true;
     }
 
@@ -1240,8 +1268,10 @@
             Intent intent, String resolvedType, ActivityInfo aInfo,
             IVoiceInteractionSession voiceSession, IVoiceInteractor voiceInteractor,
             IBinder resultTo, String resultWho, int requestCode,
-            int callingPid, int callingUid, String callingPackage, int startFlags, Bundle options,
-            boolean componentSpecified, ActivityRecord[] outActivity, ActivityContainer container) {
+            int callingPid, int callingUid, String callingPackage,
+            int realCallingPid, int realCallingUid, int startFlags, Bundle options,
+            boolean componentSpecified, ActivityRecord[] outActivity, ActivityContainer container,
+            TaskRecord inTask) {
         int err = ActivityManager.START_SUCCESS;
 
         ProcessRecord callerApp = null;
@@ -1261,7 +1291,7 @@
         if (err == ActivityManager.START_SUCCESS) {
             final int userId = aInfo != null ? UserHandle.getUserId(aInfo.applicationInfo.uid) : 0;
             Slog.i(TAG, "START u" + userId + " {" + intent.toShortString(true, true, true, false)
-                    + "} from pid " + (callerApp != null ? callerApp.pid : callingPid)
+                    + "} from uid " + callingUid
                     + " on display " + (container == null ? (mFocusedStack == null ?
                             Display.DEFAULT_DISPLAY : mFocusedStack.mDisplayId) :
                             (container.mActivityDisplay == null ? Display.DEFAULT_DISPLAY :
@@ -1284,8 +1314,7 @@
 
         final int launchFlags = intent.getFlags();
 
-        if ((launchFlags&Intent.FLAG_ACTIVITY_FORWARD_RESULT) != 0
-                && sourceRecord != null) {
+        if ((launchFlags&Intent.FLAG_ACTIVITY_FORWARD_RESULT) != 0 && sourceRecord != null) {
             // Transfer the result target from the source activity to the new
             // one being started, including any failures.
             if (requestCode >= 0) {
@@ -1335,8 +1364,8 @@
             if ((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) == 0
                     && sourceRecord.info.applicationInfo.uid != aInfo.applicationInfo.uid) {
                 try {
-                    if (!AppGlobals.getPackageManager().activitySupportsIntent(intent.getComponent(),
-                            intent, resolvedType)) {
+                    if (!AppGlobals.getPackageManager().activitySupportsIntent(
+                            intent.getComponent(), intent, resolvedType)) {
                         err = ActivityManager.START_NOT_VOICE_COMPATIBLE;
                     }
                 } catch (RemoteException e) {
@@ -1430,7 +1459,8 @@
         final ActivityStack stack = getFocusedStack();
         if (voiceSession == null && (stack.mResumedActivity == null
                 || stack.mResumedActivity.info.applicationInfo.uid != callingUid)) {
-            if (!mService.checkAppSwitchAllowedLocked(callingPid, callingUid, "Activity start")) {
+            if (!mService.checkAppSwitchAllowedLocked(callingPid, callingUid,
+                    realCallingPid, realCallingUid, "Activity start")) {
                 PendingActivityLaunch pal =
                         new PendingActivityLaunch(r, sourceRecord, startFlags, stack);
                 mPendingActivityLaunches.add(pal);
@@ -1453,7 +1483,7 @@
         doPendingActivityLaunchesLocked(false);
 
         err = startActivityUncheckedLocked(r, sourceRecord, voiceSession, voiceInteractor,
-                startFlags, true, options);
+                startFlags, true, options, inTask);
 
         if (err < 0) {
             // If someone asked to have the keyguard dismissed on the next
@@ -1536,13 +1566,21 @@
         }
     }
 
-    final int startActivityUncheckedLocked(ActivityRecord r,
-            ActivityRecord sourceRecord,
+    final int startActivityUncheckedLocked(ActivityRecord r, ActivityRecord sourceRecord,
             IVoiceInteractionSession voiceSession, IVoiceInteractor voiceInteractor, int startFlags,
-            boolean doResume, Bundle options) {
+            boolean doResume, Bundle options, TaskRecord inTask) {
         final Intent intent = r.intent;
         final int callingUid = r.launchedFromUid;
 
+        // In some flows in to this function, we retrieve the task record and hold on to it
+        // without a lock before calling back in to here...  so the task at this point may
+        // not actually be in recents.  Check for that, and if it isn't in recents just
+        // consider it invalid.
+        if (inTask != null && !inTask.inRecents) {
+            Slog.w(TAG, "Starting activity in task not in recents: " + inTask);
+            inTask = null;
+        }
+
         final boolean launchSingleTop = r.launchMode == ActivityInfo.LAUNCH_SINGLE_TOP;
         final boolean launchSingleInstance = r.launchMode == ActivityInfo.LAUNCH_SINGLE_INSTANCE;
         final boolean launchSingleTask = r.launchMode == ActivityInfo.LAUNCH_SINGLE_TASK;
@@ -1571,8 +1609,9 @@
             }
         }
 
-        final boolean launchTaskBehind = r.mLaunchTaskBehind &&
-                (launchFlags & Intent.FLAG_ACTIVITY_NEW_DOCUMENT) != 0;
+        final boolean launchTaskBehind = r.mLaunchTaskBehind
+                && !launchSingleTask && !launchSingleInstance
+                && (launchFlags & Intent.FLAG_ACTIVITY_NEW_DOCUMENT) != 0;
 
         if (r.resultTo != null && (launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
             // For whatever reason this activity is being launched into a new
@@ -1591,6 +1630,15 @@
             launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
         }
 
+        // If we are actually going to launch in to a new task, there are some cases where
+        // we further want to do multiple task.
+        if ((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
+            if (launchTaskBehind
+                    || r.info.documentLaunchMode == ActivityInfo.DOCUMENT_LAUNCH_ALWAYS) {
+                launchFlags |= Intent.FLAG_ACTIVITY_MULTIPLE_TASK;
+            }
+        }
+
         // We'll invoke onUserLeaving before onPause only if the launching
         // activity did not explicitly state that this is an automated launch.
         mUserLeaving = (launchFlags & Intent.FLAG_ACTIVITY_NO_USER_ACTION) == 0;
@@ -1621,28 +1669,87 @@
             }
         }
 
-        if (sourceRecord == null) {
-            // This activity is not being started from another...  in this
-            // case we -always- start a new task.
-            if ((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) == 0) {
-                Slog.w(TAG, "startActivity called from non-Activity context; forcing " +
-                        "Intent.FLAG_ACTIVITY_NEW_TASK for: " + intent);
+        boolean addingToTask = false;
+        TaskRecord reuseTask = null;
+
+        // If the caller is not coming from another activity, but has given us an
+        // explicit task into which they would like us to launch the new activity,
+        // then let's see about doing that.
+        if (sourceRecord == null && inTask != null && inTask.stack != null) {
+            final Intent baseIntent = inTask.getBaseIntent();
+            final ActivityRecord root = inTask.getRootActivity();
+            if (baseIntent == null) {
+                ActivityOptions.abort(options);
+                throw new IllegalArgumentException("Launching into task without base intent: "
+                        + inTask);
+            }
+
+            // If this task is empty, then we are adding the first activity -- it
+            // determines the root, and must be launching as a NEW_TASK.
+            if (launchSingleInstance || launchSingleTask) {
+                if (!baseIntent.getComponent().equals(r.intent.getComponent())) {
+                    ActivityOptions.abort(options);
+                    throw new IllegalArgumentException("Trying to launch singleInstance/Task "
+                            + r + " into different task " + inTask);
+                }
+                if (root != null) {
+                    ActivityOptions.abort(options);
+                    throw new IllegalArgumentException("Caller with inTask " + inTask
+                            + " has root " + root + " but target is singleInstance/Task");
+                }
+            }
+
+            // If task is empty, then adopt the interesting intent launch flags in to the
+            // activity being started.
+            if (root == null) {
+                final int flagsOfInterest = Intent.FLAG_ACTIVITY_NEW_TASK
+                        | Intent.FLAG_ACTIVITY_MULTIPLE_TASK | Intent.FLAG_ACTIVITY_NEW_DOCUMENT
+                        | Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS;
+                launchFlags = (launchFlags&~flagsOfInterest)
+                        | (baseIntent.getFlags()&flagsOfInterest);
+                intent.setFlags(launchFlags);
+                inTask.setIntent(r);
+                addingToTask = true;
+
+            // If the task is not empty and the caller is asking to start it as the root
+            // of a new task, then we don't actually want to start this on the task.  We
+            // will bring the task to the front, and possibly give it a new intent.
+            } else if ((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
+                addingToTask = false;
+
+            } else {
+                addingToTask = true;
+            }
+
+            reuseTask = inTask;
+        } else {
+            inTask = null;
+        }
+
+        if (inTask == null) {
+            if (sourceRecord == null) {
+                // This activity is not being started from another...  in this
+                // case we -always- start a new task.
+                if ((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) == 0 && inTask == null) {
+                    Slog.w(TAG, "startActivity called from non-Activity context; forcing " +
+                            "Intent.FLAG_ACTIVITY_NEW_TASK for: " + intent);
+                    launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
+                }
+            } else if (sourceRecord.launchMode == ActivityInfo.LAUNCH_SINGLE_INSTANCE) {
+                // The original activity who is starting us is running as a single
+                // instance...  this new activity it is starting must go on its
+                // own task.
+                launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
+            } else if (launchSingleInstance || launchSingleTask) {
+                // The activity being started is a single instance...  it always
+                // gets launched into its own task.
                 launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
             }
-        } else if (sourceRecord.launchMode == ActivityInfo.LAUNCH_SINGLE_INSTANCE) {
-            // The original activity who is starting us is running as a single
-            // instance...  this new activity it is starting must go on its
-            // own task.
-            launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
-        } else if (launchSingleInstance || launchSingleTask) {
-            // The activity being started is a single instance...  it always
-            // gets launched into its own task.
-            launchFlags |= Intent.FLAG_ACTIVITY_NEW_TASK;
         }
 
         ActivityInfo newTaskInfo = null;
         Intent newTaskIntent = null;
-        final ActivityStack sourceStack;
+        ActivityStack sourceStack;
         if (sourceRecord != null) {
             if (sourceRecord.finishing) {
                 // If the source is finishing, we can't further count it as our source.  This
@@ -1666,19 +1773,24 @@
             sourceStack = null;
         }
 
+        boolean movedHome = false;
+        ActivityStack targetStack;
+
         intent.setFlags(launchFlags);
 
-        boolean addingToTask = false;
-        boolean movedHome = false;
-        TaskRecord reuseTask = null;
-        ActivityStack targetStack;
+        // We may want to try to place the new activity in to an existing task.  We always
+        // do this if the target activity is singleTask or singleInstance; we will also do
+        // this if NEW_TASK has been requested, and there is not an additional qualifier telling
+        // us to still place it in a new task: multi task, always doc mode, or being asked to
+        // launch this as a new task behind the current one.
         if (((launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) != 0 &&
                 (launchFlags & Intent.FLAG_ACTIVITY_MULTIPLE_TASK) == 0)
                 || launchSingleInstance || launchSingleTask) {
-            // If bring to front is requested, and no result is requested, and
+            // If bring to front is requested, and no result is requested and we have not
+            // been given an explicit task to launch in to, and
             // we can find a task that was started with this same
             // component, then instead of launching bring that one to the front.
-            if (r.resultTo == null) {
+            if (inTask == null && r.resultTo == null) {
                 // See if there is a task to bring to the front.  If this is
                 // a SINGLE_INSTANCE activity, there can be one and only one
                 // instance of it in the history, and it is always in its own
@@ -1688,7 +1800,7 @@
                 if (intentActivity != null) {
                     if (isLockTaskModeViolation(intentActivity.task)) {
                         showLockTaskToast();
-                        Slog.e(TAG, "moveTaskToFront: Attempt to violate Lock Task Mode");
+                        Slog.e(TAG, "startActivityUnchecked: Attempt to violate Lock Task Mode");
                         return ActivityManager.START_RETURN_LOCK_TASK_MODE_VIOLATION;
                     }
                     if (r.task == null) {
@@ -1902,7 +2014,7 @@
                 sourceRecord.task : null;
 
         // Should this be considered a new task?
-        if (r.resultTo == null && !addingToTask
+        if (r.resultTo == null && inTask == null && !addingToTask
                 && (launchFlags & Intent.FLAG_ACTIVITY_NEW_TASK) != 0) {
             if (isLockTaskModeViolation(reuseTask)) {
                 Slog.e(TAG, "Attempted Lock Task Mode violation r=" + r);
@@ -1986,6 +2098,47 @@
             if (DEBUG_TASKS) Slog.v(TAG, "Starting new activity " + r
                     + " in existing task " + r.task + " from source " + sourceRecord);
 
+        } else if (inTask != null) {
+            // The calling is asking that the new activity be started in an explicit
+            // task it has provided to us.
+            if (isLockTaskModeViolation(inTask)) {
+                Slog.e(TAG, "Attempted Lock Task Mode violation r=" + r);
+                return ActivityManager.START_RETURN_LOCK_TASK_MODE_VIOLATION;
+            }
+            targetStack = inTask.stack;
+            targetStack.moveTaskToFrontLocked(inTask, r, options);
+            targetStack.moveToFront();
+            mWindowManager.moveTaskToTop(inTask.taskId);
+
+            // Check whether we should actually launch the new activity in to the task,
+            // or just reuse the current activity on top.
+            ActivityRecord top = inTask.getTopActivity();
+            if (top != null && top.realActivity.equals(r.realActivity) && top.userId == r.userId) {
+                if ((launchFlags & Intent.FLAG_ACTIVITY_SINGLE_TOP) != 0
+                        || launchSingleTop || launchSingleTask) {
+                    ActivityStack.logStartActivity(EventLogTags.AM_NEW_INTENT, top, top.task);
+                    if ((startFlags&ActivityManager.START_FLAG_ONLY_IF_NEEDED) != 0) {
+                        // We don't need to start a new activity, and
+                        // the client said not to do anything if that
+                        // is the case, so this is it!
+                        return ActivityManager.START_RETURN_INTENT_TO_CALLER;
+                    }
+                    top.deliverNewIntentLocked(callingUid, r.intent);
+                    return ActivityManager.START_DELIVERED_TO_TOP;
+                }
+            }
+
+            if (!addingToTask) {
+                // We don't actually want to have this activity added to the task, so just
+                // stop here but still tell the caller that we consumed the intent.
+                ActivityOptions.abort(options);
+                return ActivityManager.START_TASK_TO_FRONT;
+            }
+
+            r.setTask(inTask, null);
+            if (DEBUG_TASKS) Slog.v(TAG, "Starting new activity " + r
+                    + " in explicit task " + r.task);
+
         } else {
             // This not being started from an existing activity, and not part
             // of a new task...  just put it in the top task, though these days
@@ -2023,7 +2176,7 @@
         while (!mPendingActivityLaunches.isEmpty()) {
             PendingActivityLaunch pal = mPendingActivityLaunches.remove(0);
             startActivityUncheckedLocked(pal.r, pal.sourceRecord, null, null, pal.startFlags,
-                    doResume && mPendingActivityLaunches.isEmpty(), null);
+                    doResume && mPendingActivityLaunches.isEmpty(), null, null);
         }
     }
 
@@ -2430,7 +2583,6 @@
                         r.userId, r.info.configChanges, task.voiceSession != null,
                         r.mLaunchTaskBehind);
             }
-            mWindowManager.addTask(taskId, stackId, false);
         }
         resumeHomeStackTask(HOME_ACTIVITY_TYPE, null);
     }
@@ -2659,13 +2811,19 @@
         }
 
         // A non-top activity is reporting a visibility change.
-        if (top.fullscreen || top.state != ActivityState.RESUMED || top.app == null ||
-                top.app.thread == null) {
-            // Can't carry out this request.
+        if (visible && top.fullscreen) {
+            // Let the caller know that it can't be seen.
             if (DEBUG_VISIBLE_BEHIND) Slog.d(TAG, "requestVisibleBehind: returning top.fullscreen="
-                    + top.fullscreen+ " top.state=" + top.state + " top.app=" + top.app +
+                    + top.fullscreen + " top.state=" + top.state + " top.app=" + top.app +
                     " top.app.thread=" + top.app.thread);
             return false;
+        } else if (!visible && stack.getVisibleBehindActivity() != r) {
+            // Only the activity set as currently visible behind should actively reset its
+            // visible behind state.
+            if (DEBUG_VISIBLE_BEHIND) Slog.d(TAG, "requestVisibleBehind: returning visible="
+                    + visible + " stack.getVisibleBehindActivity()=" +
+                    stack.getVisibleBehindActivity() + " r=" + r);
+            return false;
         }
 
         stack.setVisibleBehindActivity(visible ? r : null);
@@ -2676,9 +2834,12 @@
                 mService.convertFromTranslucent(next.appToken);
             }
         }
-        try {
-            top.app.thread.scheduleBackgroundVisibleBehindChanged(top.appToken, visible);
-        } catch (RemoteException e) {
+        if (top.app != null && top.app.thread != null) {
+            // Notify the top app of the change.
+            try {
+                top.app.thread.scheduleBackgroundVisibleBehindChanged(top.appToken, visible);
+            } catch (RemoteException e) {
+            }
         }
         return true;
     }
@@ -2719,6 +2880,64 @@
         }
     }
 
+    void releaseSomeActivitiesLocked(ProcessRecord app, String reason) {
+        // Examine all activities currently running in the process.
+        TaskRecord firstTask = null;
+        // Tasks is non-null only if two or more tasks are found.
+        ArraySet<TaskRecord> tasks = null;
+        if (DEBUG_RELEASE) Slog.d(TAG, "Trying to release some activities in " + app);
+        for (int i=0; i<app.activities.size(); i++) {
+            ActivityRecord r = app.activities.get(i);
+            // First, if we find an activity that is in the process of being destroyed,
+            // then we just aren't going to do anything for now; we want things to settle
+            // down before we try to prune more activities.
+            if (r.finishing || r.state == ActivityState.DESTROYING
+                    || r.state == ActivityState.DESTROYED) {
+                if (DEBUG_RELEASE) Slog.d(TAG, "Abort release; already destroying: " + r);
+                return;
+            }
+            // Don't consider any activies that are currently not in a state where they
+            // can be destroyed.
+            if (r.visible || !r.stopped || !r.haveState
+                    || r.state == ActivityState.RESUMED || r.state == ActivityState.PAUSING
+                    || r.state == ActivityState.PAUSED || r.state == ActivityState.STOPPING) {
+                if (DEBUG_RELEASE) Slog.d(TAG, "Not releasing in-use activity: " + r);
+                continue;
+            }
+            if (r.task != null) {
+                if (DEBUG_RELEASE) Slog.d(TAG, "Collecting release task " + r.task
+                        + " from " + r);
+                if (firstTask == null) {
+                    firstTask = r.task;
+                } else if (firstTask != r.task) {
+                    if (tasks == null) {
+                        tasks = new ArraySet<>();
+                        tasks.add(firstTask);
+                    }
+                    tasks.add(r.task);
+                }
+            }
+        }
+        if (tasks == null) {
+            if (DEBUG_RELEASE) Slog.d(TAG, "Didn't find two or more tasks to release");
+            return;
+        }
+        // If we have activities in multiple tasks that are in a position to be destroyed,
+        // let's iterate through the tasks and release the oldest one.
+        final int numDisplays = mActivityDisplays.size();
+        for (int displayNdx = 0; displayNdx < numDisplays; ++displayNdx) {
+            final ArrayList<ActivityStack> stacks = mActivityDisplays.valueAt(displayNdx).mStacks;
+            // Step through all stacks starting from behind, to hit the oldest things first.
+            for (int stackNdx = 0; stackNdx < stacks.size(); stackNdx++) {
+                final ActivityStack stack = stacks.get(stackNdx);
+                // Try to release activities in this stack; if we manage to, we are done.
+                if (stack.releaseSomeActivitiesLocked(app, tasks, reason) > 0) {
+                    return;
+                }
+            }
+        }
+    }
+
     boolean switchUserLocked(int userId, UserStartedState uss) {
         mUserStackInFront.put(mCurrentUser, getFocusedStack().getStackId());
         final int restoreStackId = mUserStackInFront.get(userId, HOME_STACK_ID);
@@ -3070,6 +3289,10 @@
             newDisplay = mActivityDisplays.get(displayId) == null;
             if (newDisplay) {
                 ActivityDisplay activityDisplay = new ActivityDisplay(displayId);
+                if (activityDisplay.mDisplay == null) {
+                    Slog.w(TAG, "Display " + displayId + " gone before initialization complete");
+                    return;
+                }
                 mActivityDisplays.put(displayId, activityDisplay);
             }
         }
@@ -3182,7 +3405,11 @@
 
     void endLockTaskModeIfTaskEnding(TaskRecord task) {
         if (mLockTaskModeTask != null && mLockTaskModeTask == task) {
+            final Message lockTaskMsg = Message.obtain();
+            lockTaskMsg.arg1 = mLockTaskModeTask.userId;
+            lockTaskMsg.what = LOCK_TASK_END_MSG;
             mLockTaskModeTask = null;
+            mHandler.sendMessage(lockTaskMsg);
         }
     }
 
@@ -3462,7 +3689,7 @@
             }
         }
 
-        private void detachLocked() {
+        protected void detachLocked() {
             if (DEBUG_STACK) Slog.d(TAG, "detachLocked: " + this + " from display="
                     + mActivityDisplay + " Callers=" + Debug.getCallers(2));
             if (mActivityDisplay != null) {
@@ -3487,8 +3714,8 @@
                     && "content".equals(intent.getData().getScheme())) {
                 mimeType = mService.getProviderMimeType(intent.getData(), userId);
             }
-            return startActivityMayWait(null, -1, null, intent, mimeType, null, null, null, null, 0, 0, null,
-                    null, null, null, null, userId, this);
+            return startActivityMayWait(null, -1, null, intent, mimeType, null, null, null, null, 0,
+                    0, null, null, null, null, userId, this, null);
         }
 
         @Override
@@ -3514,7 +3741,7 @@
                     resolvedType = mService.getProviderMimeType(intent.getData(), userId);
                 }
             }
-            ActivityInfo aInfo = resolveActivity(intent, resolvedType, 0, null, null, userId);
+            ActivityInfo aInfo = resolveActivity(intent, resolvedType, 0, null, userId);
             if (aInfo != null && (aInfo.flags & ActivityInfo.FLAG_ALLOW_EMBEDDED) == 0) {
                 throw new SecurityException(
                         "Attempt to embed activity that has not set allowEmbedded=\"true\"");
@@ -3586,12 +3813,6 @@
         }
 
         void onTaskListEmptyLocked() {
-            mHandler.removeMessages(CONTAINER_TASK_LIST_EMPTY_TIMEOUT, this);
-            if (!mStack.isHomeStack()) {
-                detachLocked();
-                deleteActivityContainer(this);
-            }
-            mHandler.obtainMessage(CONTAINER_CALLBACK_TASK_LIST_EMPTY, this).sendToTarget();
         }
 
         @Override
@@ -3651,7 +3872,7 @@
                 mContainerState = CONTAINER_STATE_NO_SURFACE;
                 ((VirtualActivityDisplay) mActivityDisplay).setSurface(null);
                 if (mStack.mPausingActivity == null && mStack.mResumedActivity != null) {
-                    mStack.startPausingLocked(false, true);
+                    mStack.startPausingLocked(false, true, false, false);
                 }
             }
 
@@ -3680,6 +3901,13 @@
             return false;
         }
 
+        void onTaskListEmptyLocked() {
+            mHandler.removeMessages(CONTAINER_TASK_LIST_EMPTY_TIMEOUT, this);
+            detachLocked();
+            deleteActivityContainer(this);
+            mHandler.obtainMessage(CONTAINER_CALLBACK_TASK_LIST_EMPTY, this).sendToTarget();
+        }
+
         private void setSurfaceIfReadyLocked() {
             if (DEBUG_STACK) Slog.v(TAG, "setSurfaceIfReadyLocked: mDrawn=" + mDrawn +
                     " mContainerState=" + mContainerState + " mSurface=" + mSurface);
@@ -3707,8 +3935,14 @@
         ActivityDisplay() {
         }
 
+        // After instantiation, check that mDisplay is not null before using this. The alternative
+        // is for this to throw an exception if mDisplayManager.getDisplay() returns null.
         ActivityDisplay(int displayId) {
-            init(mDisplayManager.getDisplay(displayId));
+            final Display display = mDisplayManager.getDisplay(displayId);
+            if (display == null) {
+                return;
+            }
+            init(display);
         }
 
         void init(Display display) {
diff --git a/services/core/java/com/android/server/am/AppBindRecord.java b/services/core/java/com/android/server/am/AppBindRecord.java
index 06265fd..65273c9 100644
--- a/services/core/java/com/android/server/am/AppBindRecord.java
+++ b/services/core/java/com/android/server/am/AppBindRecord.java
@@ -16,8 +16,9 @@
 
 package com.android.server.am;
 
+import android.util.ArraySet;
+
 import java.io.PrintWriter;
-import java.util.HashSet;
 import java.util.Iterator;
 
 /**
@@ -28,7 +29,7 @@
     final IntentBindRecord intent;  // The intent we are bound to.
     final ProcessRecord client;     // Who has started/bound the service.
 
-    final HashSet<ConnectionRecord> connections = new HashSet<ConnectionRecord>();
+    final ArraySet<ConnectionRecord> connections = new ArraySet<>();
                                     // All ConnectionRecord for this client.
 
     void dump(PrintWriter pw, String prefix) {
@@ -38,11 +39,11 @@
     }
 
     void dumpInIntentBind(PrintWriter pw, String prefix) {
-        if (connections.size() > 0) {
+        final int N = connections.size();
+        if (N > 0) {
             pw.println(prefix + "Per-process Connections:");
-            Iterator<ConnectionRecord> it = connections.iterator();
-            while (it.hasNext()) {
-                ConnectionRecord c = it.next();
+            for (int i=0; i<N; i++) {
+                ConnectionRecord c = connections.valueAt(i);
                 pw.println(prefix + "  " + c);
             }
         }
diff --git a/services/core/java/com/android/server/am/AppErrorDialog.java b/services/core/java/com/android/server/am/AppErrorDialog.java
index 0ba62c5..098b0b6 100644
--- a/services/core/java/com/android/server/am/AppErrorDialog.java
+++ b/services/core/java/com/android/server/am/AppErrorDialog.java
@@ -94,6 +94,9 @@
             }
             mResult.set(msg.what);
 
+            // Make sure we don't have time timeout still hanging around.
+            removeMessages(FORCE_QUIT);
+
             // If this is a timeout we won't be automatically closed, so go
             // ahead and explicitly dismiss ourselves just in case.
             dismiss();
diff --git a/services/core/java/com/android/server/am/ContentProviderRecord.java b/services/core/java/com/android/server/am/ContentProviderRecord.java
index ff22764..a37249d 100644
--- a/services/core/java/com/android/server/am/ContentProviderRecord.java
+++ b/services/core/java/com/android/server/am/ContentProviderRecord.java
@@ -166,8 +166,16 @@
         }
         if (full) {
             if (hasExternalProcessHandles()) {
-                pw.print(prefix); pw.print("externals=");
-                        pw.println(externalProcessTokenToHandle.size());
+                pw.print(prefix); pw.print("externals:");
+                if (externalProcessTokenToHandle != null) {
+                    pw.print(" w/token=");
+                    pw.print(externalProcessTokenToHandle.size());
+                }
+                if (externalProcessNoHandleCount > 0) {
+                    pw.print(" notoken=");
+                    pw.print(externalProcessNoHandleCount);
+                }
+                pw.println();
             }
         } else {
             if (connections.size() > 0 || externalProcessNoHandleCount > 0) {
diff --git a/services/core/java/com/android/server/am/IntentBindRecord.java b/services/core/java/com/android/server/am/IntentBindRecord.java
index ba6010a..be290e9 100644
--- a/services/core/java/com/android/server/am/IntentBindRecord.java
+++ b/services/core/java/com/android/server/am/IntentBindRecord.java
@@ -20,6 +20,7 @@
 import android.content.Intent;
 import android.os.IBinder;
 import android.util.ArrayMap;
+import android.util.ArraySet;
 
 import java.io.PrintWriter;
 
@@ -78,11 +79,9 @@
     int collectFlags() {
         int flags = 0;
         for (int i=apps.size()-1; i>=0; i--) {
-            AppBindRecord app = apps.valueAt(i);
-            if (app.connections.size() > 0) {
-                for (ConnectionRecord conn : app.connections) {
-                    flags |= conn.flags;
-                }
+            final ArraySet<ConnectionRecord> connections = apps.valueAt(i).connections;
+            for (int j=connections.size()-1; j>=0; j--) {
+                flags |= connections.valueAt(j).flags;
             }
         }
         return flags;
diff --git a/services/core/java/com/android/server/am/LockTaskNotify.java b/services/core/java/com/android/server/am/LockTaskNotify.java
index cf65243..5768ddb 100644
--- a/services/core/java/com/android/server/am/LockTaskNotify.java
+++ b/services/core/java/com/android/server/am/LockTaskNotify.java
@@ -34,6 +34,7 @@
     private final Context mContext;
     private final H mHandler;
     private AccessibilityManager mAccessibilityManager;
+    private Toast mLastToast;
 
     public LockTaskNotify(Context context) {
         mContext = context;
@@ -52,7 +53,11 @@
         if (!isLocked && mAccessibilityManager.isEnabled()) {
             text = mContext.getString(R.string.lock_to_app_toast_accessible);
         }
-        Toast.makeText(mContext, text, Toast.LENGTH_LONG).show();
+        if (mLastToast != null) {
+            mLastToast.cancel();
+        }
+        mLastToast = Toast.makeText(mContext, text, Toast.LENGTH_LONG);
+        mLastToast.show();
     }
 
     public void show(boolean starting) {
diff --git a/services/core/java/com/android/server/am/LockToAppRequestDialog.java b/services/core/java/com/android/server/am/LockToAppRequestDialog.java
index 12dcf7e..a1eb31e 100644
--- a/services/core/java/com/android/server/am/LockToAppRequestDialog.java
+++ b/services/core/java/com/android/server/am/LockToAppRequestDialog.java
@@ -74,11 +74,15 @@
         return 0;
     }
 
-    public void showLockTaskPrompt(TaskRecord task) {
+    public void clearPrompt() {
         if (mDialog != null) {
             mDialog.dismiss();
             mDialog = null;
         }
+    }
+
+    public void showLockTaskPrompt(TaskRecord task) {
+        clearPrompt();
         mRequestedTask = task;
         final int unlockStringId = getLockString(task.userId);
 
@@ -97,13 +101,14 @@
         mDialog = builder.create();
 
         mDialog.getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ALERT);
+        mDialog.getWindow().getAttributes().privateFlags |=
+                WindowManager.LayoutParams.PRIVATE_FLAG_SHOW_FOR_ALL_USERS;
         mDialog.show();
 
         if (unlockStringId != 0) {
             String unlockString = mContext.getString(unlockStringId);
             mCheckbox = (CheckBox) mDialog.findViewById(R.id.lock_to_app_checkbox);
-            mCheckbox.setText(mContext.getString(R.string.lock_to_app_use_screen_lock,
-                    unlockString));
+            mCheckbox.setText(unlockString);
 
             // Remember state.
             try {
diff --git a/services/core/java/com/android/server/am/PendingIntentRecord.java b/services/core/java/com/android/server/am/PendingIntentRecord.java
index 98999e9..433ab60 100644
--- a/services/core/java/com/android/server/am/PendingIntentRecord.java
+++ b/services/core/java/com/android/server/am/PendingIntentRecord.java
@@ -254,7 +254,7 @@
                             } else {
                                 owner.startActivityInPackage(uid, key.packageName, finalIntent,
                                         resolvedType, resultTo, resultWho, requestCode, 0,
-                                        options, userId, container);
+                                        options, userId, container, null);
                             }
                         } catch (RuntimeException e) {
                             Slog.w(ActivityManagerService.TAG,
diff --git a/services/core/java/com/android/server/am/ProcessList.java b/services/core/java/com/android/server/am/ProcessList.java
index 77c324f..5022b28 100644
--- a/services/core/java/com/android/server/am/ProcessList.java
+++ b/services/core/java/com/android/server/am/ProcessList.java
@@ -21,6 +21,8 @@
 import java.nio.ByteBuffer;
 
 import android.app.ActivityManager;
+import android.os.Build;
+import android.os.SystemClock;
 import com.android.internal.util.MemInfoReader;
 import com.android.server.wm.WindowManagerService;
 
@@ -122,7 +124,7 @@
     // we have no limit on the number of service, visible, foreground, or other such
     // processes and the number of those processes does not count against the cached
     // process limit.
-    static final int MAX_CACHED_APPS = 24;
+    static final int MAX_CACHED_APPS = 32;
 
     // We allow empty processes to stick around for at most 30 minutes.
     static final long MAX_EMPTY_TIME = 30*60*1000;
@@ -136,7 +138,7 @@
 
     // The number of cached at which we don't consider it necessary to do
     // memory trimming.
-    static final int TRIM_CACHED_APPS = ((MAX_CACHED_APPS-MAX_EMPTY_APPS)*2)/3;
+    static final int TRIM_CACHED_APPS = (MAX_CACHED_APPS-MAX_EMPTY_APPS)/3;
 
     // Threshold of number of cached+empty where we consider memory critical.
     static final int TRIM_CRITICAL_THRESHOLD = 3;
@@ -229,21 +231,31 @@
             Slog.i("XXXXXX", "minfree_adj=" + minfree_adj + " minfree_abs=" + minfree_abs);
         }
 
+        final boolean is64bit = Build.SUPPORTED_64_BIT_ABIS.length > 0;
+
         for (int i=0; i<mOomAdj.length; i++) {
             int low = mOomMinFreeLow[i];
             int high = mOomMinFreeHigh[i];
             mOomMinFree[i] = (int)(low + ((high-low)*scale));
+            if (is64bit) {
+                // On 64 bit devices, we consume more baseline RAM, because 64 bit is cool!
+                // To avoid being all pagey and stuff, scale up the memory levels to
+                // give us some breathing room.
+                mOomMinFree[i] = (3*mOomMinFree[i])/2;
+            }
         }
 
         if (minfree_abs >= 0) {
             for (int i=0; i<mOomAdj.length; i++) {
-                mOomMinFree[i] = (int)((float)minfree_abs * mOomMinFree[i] / mOomMinFree[mOomAdj.length - 1]);
+                mOomMinFree[i] = (int)((float)minfree_abs * mOomMinFree[i]
+                        / mOomMinFree[mOomAdj.length - 1]);
             }
         }
 
         if (minfree_adj != 0) {
             for (int i=0; i<mOomAdj.length; i++) {
-                mOomMinFree[i] += (int)((float)minfree_adj * mOomMinFree[i] / mOomMinFree[mOomAdj.length - 1]);
+                mOomMinFree[i] += (int)((float)minfree_adj * mOomMinFree[i]
+                        / mOomMinFree[mOomAdj.length - 1]);
                 if (mOomMinFree[i] < 0) {
                     mOomMinFree[i] = 0;
                 }
@@ -288,7 +300,7 @@
     }
 
     public static int computeEmptyProcessLimit(int totalProcessLimit) {
-        return (totalProcessLimit*2)/3;
+        return totalProcessLimit/2;
     }
 
     private static String buildOomTag(String prefix, String space, int val, int base) {
@@ -528,12 +540,18 @@
         if (amt == UNKNOWN_ADJ)
             return;
 
+        long start = SystemClock.elapsedRealtime();
         ByteBuffer buf = ByteBuffer.allocate(4 * 4);
         buf.putInt(LMK_PROCPRIO);
         buf.putInt(pid);
         buf.putInt(uid);
         buf.putInt(amt);
         writeLmkd(buf);
+        long now = SystemClock.elapsedRealtime();
+        if ((now-start) > 250) {
+            Slog.w("ActivityManager", "SLOW OOM ADJ: " + (now-start) + "ms for pid " + pid
+                    + " = " + amt);
+        }
     }
 
     /*
diff --git a/services/core/java/com/android/server/am/ProcessRecord.java b/services/core/java/com/android/server/am/ProcessRecord.java
index f1bcb60..0817dd8 100644
--- a/services/core/java/com/android/server/am/ProcessRecord.java
+++ b/services/core/java/com/android/server/am/ProcessRecord.java
@@ -17,6 +17,8 @@
 package com.android.server.am;
 
 import android.util.ArraySet;
+import android.util.EventLog;
+import android.util.Slog;
 import com.android.internal.app.ProcessStats;
 import com.android.internal.os.BatteryStatsImpl;
 
@@ -502,6 +504,21 @@
         return adj;
     }
 
+    void kill(String reason, boolean noisy) {
+        if (!killedByAm) {
+            if (noisy) {
+                Slog.i(ActivityManagerService.TAG, "Killing " + toShortString() + " (adj " + setAdj
+                        + "): " + reason);
+            }
+            EventLog.writeEvent(EventLogTags.AM_KILL, userId, pid, processName, setAdj, reason);
+            Process.killProcessQuiet(pid);
+            Process.killProcessGroup(info.uid, pid);
+            if (!persistent) {
+                killedByAm = true;
+            }
+        }
+    }
+
     public String toShortString() {
         if (shortStringName != null) {
             return shortStringName;
diff --git a/services/core/java/com/android/server/am/ServiceRecord.java b/services/core/java/com/android/server/am/ServiceRecord.java
index f79c026..0a66a5c 100644
--- a/services/core/java/com/android/server/am/ServiceRecord.java
+++ b/services/core/java/com/android/server/am/ServiceRecord.java
@@ -450,6 +450,9 @@
                                         appInfo.packageName, null));
                                 PendingIntent pi = PendingIntent.getActivity(ams.mContext, 0,
                                         runningIntent, PendingIntent.FLAG_UPDATE_CURRENT);
+                                localForegroundNoti.color = ams.mContext.getResources().getColor(
+                                        com.android.internal
+                                                .R.color.system_notification_accent_color);
                                 localForegroundNoti.setLatestEventInfo(ctx,
                                         ams.mContext.getString(
                                                 com.android.internal.R.string
diff --git a/services/core/java/com/android/server/am/TaskPersister.java b/services/core/java/com/android/server/am/TaskPersister.java
index 0180db3..df1772a 100644
--- a/services/core/java/com/android/server/am/TaskPersister.java
+++ b/services/core/java/com/android/server/am/TaskPersister.java
@@ -51,6 +51,12 @@
      * task being launched a chance to load its resources without this occupying IO bandwidth. */
     private static final long PRE_TASK_DELAY_MS = 3000;
 
+    /** The maximum number of entries to keep in the queue before draining it automatically. */
+    private static final int MAX_WRITE_QUEUE_LENGTH = 6;
+
+    /** Special value for mWriteTime to mean don't wait, just write */
+    private static final long FLUSH_QUEUE = -1;
+
     private static final String RECENTS_FILENAME = "_task";
     private static final String TASKS_DIRNAME = "recent_tasks";
     private static final String TASK_EXTENSION = ".xml";
@@ -120,6 +126,31 @@
         mLazyTaskWriterThread.start();
     }
 
+    private void removeThumbnails(TaskRecord task) {
+        final String taskString = Integer.toString(task.taskId);
+        for (int queueNdx = mWriteQueue.size() - 1; queueNdx >= 0; --queueNdx) {
+            final WriteQueueItem item = mWriteQueue.get(queueNdx);
+            if (item instanceof ImageWriteQueueItem &&
+                    ((ImageWriteQueueItem) item).mFilename.startsWith(taskString)) {
+                if (DEBUG) Slog.d(TAG, "Removing " + ((ImageWriteQueueItem) item).mFilename +
+                        " from write queue");
+                mWriteQueue.remove(queueNdx);
+            }
+        }
+    }
+
+    private void yieldIfQueueTooDeep() {
+        boolean stall = false;
+        synchronized (this) {
+            if (mNextWriteTime == FLUSH_QUEUE) {
+                stall = true;
+            }
+        }
+        if (stall) {
+            Thread.yield();
+        }
+    }
+
     void wakeup(TaskRecord task, boolean flush) {
         synchronized (this) {
             if (task != null) {
@@ -128,6 +159,10 @@
                     final WriteQueueItem item = mWriteQueue.get(queueNdx);
                     if (item instanceof TaskWriteQueueItem &&
                             ((TaskWriteQueueItem) item).mTask == task) {
+                        if (!task.inRecents) {
+                            // This task is being removed.
+                            removeThumbnails(task);
+                        }
                         break;
                     }
                 }
@@ -138,15 +173,18 @@
                 // Dummy.
                 mWriteQueue.add(new WriteQueueItem());
             }
-            if (flush) {
-                mNextWriteTime = -1;
+            if (flush || mWriteQueue.size() > MAX_WRITE_QUEUE_LENGTH) {
+                mNextWriteTime = FLUSH_QUEUE;
             } else if (mNextWriteTime == 0) {
                 mNextWriteTime = SystemClock.uptimeMillis() + PRE_TASK_DELAY_MS;
             }
             if (DEBUG) Slog.d(TAG, "wakeup: task=" + task + " flush=" + flush + " mNextWriteTime="
-                    + mNextWriteTime + " Callers=" + Debug.getCallers(4));
+                    + mNextWriteTime + " mWriteQueue.size=" + mWriteQueue.size()
+                    + " Callers=" + Debug.getCallers(4));
             notifyAll();
         }
+
+        yieldIfQueueTooDeep();
     }
 
     void saveImage(Bitmap image, String filename) {
@@ -166,7 +204,9 @@
             if (queueNdx < 0) {
                 mWriteQueue.add(new ImageWriteQueueItem(filename, image));
             }
-            if (mNextWriteTime == 0) {
+            if (mWriteQueue.size() > MAX_WRITE_QUEUE_LENGTH) {
+                mNextWriteTime = FLUSH_QUEUE;
+            } else if (mNextWriteTime == 0) {
                 mNextWriteTime = SystemClock.uptimeMillis() + PRE_TASK_DELAY_MS;
             }
             if (DEBUG) Slog.d(TAG, "saveImage: filename=" + filename + " now=" +
@@ -174,6 +214,8 @@
                     mNextWriteTime + " Callers=" + Debug.getCallers(4));
             notifyAll();
         }
+
+        yieldIfQueueTooDeep();
     }
 
     Bitmap getThumbnail(String filename) {
@@ -273,11 +315,14 @@
                         if (TAG_TASK.equals(name)) {
                             final TaskRecord task =
                                     TaskRecord.restoreFromXml(in, mStackSupervisor);
-                            if (true || DEBUG) Slog.d(TAG, "restoreTasksLocked: restored task=" +
+                            if (DEBUG) Slog.d(TAG, "restoreTasksLocked: restored task=" +
                                     task);
                             if (task != null) {
                                 task.isPersistable = true;
-                                mWriteQueue.add(new TaskWriteQueueItem(task));
+                                // XXX Don't add to write queue... there is no reason to write
+                                // out the stuff we just read, if we don't write it we will
+                                // read the same thing again.
+                                //mWriteQueue.add(new TaskWriteQueueItem(task));
                                 tasks.add(task);
                                 final int taskId = task.taskId;
                                 recoveredTaskIds.add(taskId);
@@ -344,6 +389,10 @@
     private static void removeObsoleteFiles(ArraySet<Integer> persistentTaskIds, File[] files) {
         if (DEBUG) Slog.d(TAG, "removeObsoleteFile: persistentTaskIds=" + persistentTaskIds +
                 " files=" + files);
+        if (files == null) {
+            Slog.e(TAG, "File error accessing recents directory (too many files open?).");
+            return;
+        }
         for (int fileNdx = 0; fileNdx < files.length; ++fileNdx) {
             File file = files[fileNdx];
             String filename = file.getName();
@@ -418,7 +467,7 @@
                 // If mNextWriteTime, then don't delay between each call to saveToXml().
                 final WriteQueueItem item;
                 synchronized (TaskPersister.this) {
-                    if (mNextWriteTime >= 0) {
+                    if (mNextWriteTime != FLUSH_QUEUE) {
                         // The next write we don't have to wait so long.
                         mNextWriteTime = SystemClock.uptimeMillis() + INTER_WRITE_DELAY_MS;
                         if (DEBUG) Slog.d(TAG, "Next write time may be in " +
@@ -432,13 +481,14 @@
                             TaskPersister.this.wait();
                         } catch (InterruptedException e) {
                         }
-                        // Invariant: mNextWriteTime is either -1 or PRE_WRITE_DELAY_MS from now.
+                        // Invariant: mNextWriteTime is either FLUSH_QUEUE or PRE_WRITE_DELAY_MS
+                        // from now.
                     }
                     item = mWriteQueue.remove(0);
 
                     long now = SystemClock.uptimeMillis();
                     if (DEBUG) Slog.d(TAG, "LazyTaskWriter: now=" + now + " mNextWriteTime=" +
-                            mNextWriteTime);
+                            mNextWriteTime + " mWriteQueue.size=" + mWriteQueue.size());
                     while (now < mNextWriteTime) {
                         try {
                             if (DEBUG) Slog.d(TAG, "LazyTaskWriter: waiting " +
@@ -477,7 +527,7 @@
                     TaskRecord task = ((TaskWriteQueueItem) item).mTask;
                     if (DEBUG) Slog.d(TAG, "Writing task=" + task);
                     synchronized (mService) {
-                        if (mService.mRecentTasks.contains(task)) {
+                        if (task.inRecents) {
                             // Still there.
                             try {
                                 if (DEBUG) Slog.d(TAG, "Saving task=" + task);
@@ -486,24 +536,24 @@
                             } catch (XmlPullParserException e) {
                             }
                         }
-                        if (stringWriter != null) {
-                            // Write out xml file while not holding mService lock.
-                            FileOutputStream file = null;
-                            AtomicFile atomicFile = null;
-                            try {
-                                atomicFile = new AtomicFile(new File(sTasksDir, String.valueOf(
-                                        task.taskId) + RECENTS_FILENAME + TASK_EXTENSION));
-                                file = atomicFile.startWrite();
-                                file.write(stringWriter.toString().getBytes());
-                                file.write('\n');
-                                atomicFile.finishWrite(file);
-                            } catch (IOException e) {
-                                if (file != null) {
-                                    atomicFile.failWrite(file);
-                                }
-                                Slog.e(TAG, "Unable to open " + atomicFile + " for persisting. " +
-                                        e);
+                    }
+                    if (stringWriter != null) {
+                        // Write out xml file while not holding mService lock.
+                        FileOutputStream file = null;
+                        AtomicFile atomicFile = null;
+                        try {
+                            atomicFile = new AtomicFile(new File(sTasksDir, String.valueOf(
+                                    task.taskId) + RECENTS_FILENAME + TASK_EXTENSION));
+                            file = atomicFile.startWrite();
+                            file.write(stringWriter.toString().getBytes());
+                            file.write('\n');
+                            atomicFile.finishWrite(file);
+                        } catch (IOException e) {
+                            if (file != null) {
+                                atomicFile.failWrite(file);
                             }
+                            Slog.e(TAG, "Unable to open " + atomicFile + " for persisting. " +
+                                    e);
                         }
                     }
                 }
diff --git a/services/core/java/com/android/server/am/TaskRecord.java b/services/core/java/com/android/server/am/TaskRecord.java
index ccca657..f74b795 100644
--- a/services/core/java/com/android/server/am/TaskRecord.java
+++ b/services/core/java/com/android/server/am/TaskRecord.java
@@ -26,11 +26,16 @@
 import android.app.ActivityManager;
 import android.app.ActivityManager.TaskThumbnail;
 import android.app.ActivityOptions;
+import android.app.AppGlobals;
 import android.content.ComponentName;
 import android.content.Intent;
 import android.content.pm.ActivityInfo;
+import android.content.pm.ApplicationInfo;
+import android.content.pm.IPackageManager;
+import android.content.pm.PackageManager;
 import android.graphics.Bitmap;
 import android.os.ParcelFileDescriptor;
+import android.os.RemoteException;
 import android.os.UserHandle;
 import android.service.voice.IVoiceInteractionSession;
 import android.util.Slog;
@@ -53,10 +58,12 @@
     private static final String ATTR_ORIGACTIVITY = "orig_activity";
     private static final String TAG_ACTIVITY = "activity";
     private static final String ATTR_AFFINITY = "affinity";
+    private static final String ATTR_ROOT_AFFINITY = "root_affinity";
     private static final String ATTR_ROOTHASRESET = "root_has_reset";
     private static final String ATTR_AUTOREMOVERECENTS = "auto_remove_recents";
     private static final String ATTR_ASKEDCOMPATMODE = "asked_compat_mode";
     private static final String ATTR_USERID = "user_id";
+    private static final String ATTR_EFFECTIVE_UID = "effective_uid";
     private static final String ATTR_TASKTYPE = "task_type";
     private static final String ATTR_FIRSTACTIVETIME = "first_active_time";
     private static final String ATTR_LASTACTIVETIME = "last_active_time";
@@ -78,15 +85,19 @@
     static final boolean IGNORE_RETURN_TO_RECENTS = true;
 
     final int taskId;       // Unique identifier for this task.
-    String affinity;        // The affinity name for this task, or null.
+    String affinity;        // The affinity name for this task, or null; may change identity.
+    String rootAffinity;    // Initial base affinity, or null; does not change from initial root.
     final IVoiceInteractionSession voiceSession;    // Voice interaction session driving task
     final IVoiceInteractor voiceInteractor;         // Associated interactor to provide to app
     Intent intent;          // The original intent that started the task.
     Intent affinityIntent;  // Intent of affinity-moved activity that started this task.
+    int effectiveUid;       // The current effective uid of the identity of this task.
     ComponentName origActivity; // The non-alias activity component of the intent.
     ComponentName realActivity; // The actual activity component that started the task.
     long firstActiveTime;   // First time this task was active.
     long lastActiveTime;    // Last time this task was active, including sleep.
+    boolean inRecents;      // Actually in the recents list?
+    boolean isAvailable;    // Is the activity available to be launched?
     boolean rootWasReset;   // True if the intent at the root of the task had
                             // the FLAG_ACTIVITY_RESET_TASK_IF_NEEDED flag.
     boolean autoRemoveRecents;  // If true, we should automatically remove the task from
@@ -163,14 +174,45 @@
         mAffiliatedTaskId = _taskId;
         voiceSession = _voiceSession;
         voiceInteractor = _voiceInteractor;
+        isAvailable = true;
         mActivities = new ArrayList<ActivityRecord>();
         setIntent(_intent, info);
     }
 
+    TaskRecord(ActivityManagerService service, int _taskId, ActivityInfo info, Intent _intent,
+            ActivityManager.TaskDescription _taskDescription) {
+        mService = service;
+        mFilename = String.valueOf(_taskId) + TASK_THUMBNAIL_SUFFIX +
+                TaskPersister.IMAGE_EXTENSION;
+        mLastThumbnailFile = new File(TaskPersister.sImagesDir, mFilename);
+        taskId = _taskId;
+        mAffiliatedTaskId = _taskId;
+        voiceSession = null;
+        voiceInteractor = null;
+        isAvailable = true;
+        mActivities = new ArrayList<ActivityRecord>();
+        setIntent(_intent, info);
+
+        taskType = ActivityRecord.APPLICATION_ACTIVITY_TYPE;
+        isPersistable = true;
+        mCallingUid = info.applicationInfo.uid;
+        mCallingPackage = info.packageName;
+        // Clamp to [1, max].
+        maxRecents = Math.min(Math.max(info.maxRecents, 1),
+                ActivityManager.getMaxAppRecentsLimitStatic());
+
+        taskType = APPLICATION_ACTIVITY_TYPE;
+        mTaskToReturnTo = HOME_ACTIVITY_TYPE;
+        userId = UserHandle.getUserId(info.applicationInfo.uid);
+        lastTaskDescription = _taskDescription;
+        mCallingUid = info.applicationInfo.uid;
+        mCallingPackage = info.packageName;
+    }
+
     TaskRecord(ActivityManagerService service, int _taskId, Intent _intent, Intent _affinityIntent,
-            String _affinity, ComponentName _realActivity, ComponentName _origActivity,
-            boolean _rootWasReset, boolean _autoRemoveRecents, boolean _askedCompatMode,
-            int _taskType, int _userId,
+            String _affinity, String _rootAffinity, ComponentName _realActivity,
+            ComponentName _origActivity, boolean _rootWasReset, boolean _autoRemoveRecents,
+            boolean _askedCompatMode, int _taskType, int _userId, int _effectiveUid,
             String _lastDescription, ArrayList<ActivityRecord> activities, long _firstActiveTime,
             long _lastActiveTime, long lastTimeMoved, boolean neverRelinquishIdentity,
             ActivityManager.TaskDescription _lastTaskDescription, int taskAffiliation,
@@ -184,16 +226,19 @@
         intent = _intent;
         affinityIntent = _affinityIntent;
         affinity = _affinity;
+        rootAffinity = _affinity;
         voiceSession = null;
         voiceInteractor = null;
         realActivity = _realActivity;
         origActivity = _origActivity;
         rootWasReset = _rootWasReset;
+        isAvailable = true;
         autoRemoveRecents = _autoRemoveRecents;
         askedCompatMode = _askedCompatMode;
         taskType = _taskType;
         mTaskToReturnTo = HOME_ACTIVITY_TYPE;
         userId = _userId;
+        effectiveUid = _effectiveUid;
         firstActiveTime = _firstActiveTime;
         lastActiveTime = _lastActiveTime;
         lastDescription = _lastDescription;
@@ -237,6 +282,13 @@
         }
 
         affinity = info.taskAffinity;
+        if (intent == null) {
+            // If this task already has an intent associated with it, don't set the root
+            // affinity -- we don't want it changing after initially set, but the initially
+            // set value may be null.
+            rootAffinity = affinity;
+        }
+        effectiveUid = info.applicationInfo.uid;
         stringName = null;
 
         if (info.targetActivity == null) {
@@ -275,20 +327,19 @@
             }
         }
 
-        if (intent != null &&
-                (intent.getFlags()&Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED) != 0) {
+        final int intentFlags = intent == null ? 0 : intent.getFlags();
+        if ((intentFlags & Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED) != 0) {
             // Once we are set to an Intent with this flag, we count this
             // task as having a true root activity.
             rootWasReset = true;
         }
 
         userId = UserHandle.getUserId(info.applicationInfo.uid);
-        creatorUid = info.applicationInfo.uid;
         if ((info.flags & ActivityInfo.FLAG_AUTO_REMOVE_FROM_RECENTS) != 0) {
             // If the activity itself has requested auto-remove, then just always do it.
             autoRemoveRecents = true;
-        } else if ((intent.getFlags()&(Intent.FLAG_ACTIVITY_NEW_DOCUMENT
-                |Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS)) == Intent.FLAG_ACTIVITY_NEW_DOCUMENT) {
+        } else if ((intentFlags & (Intent.FLAG_ACTIVITY_NEW_DOCUMENT
+                | Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS)) == Intent.FLAG_ACTIVITY_NEW_DOCUMENT) {
             // If the caller has not asked for the document to be retained, then we may
             // want to turn on auto-remove, depending on whether the target has set its
             // own document launch mode.
@@ -335,6 +386,15 @@
         setNextAffiliate(null);
     }
 
+    void removedFromRecents(TaskPersister persister) {
+        disposeThumbnail();
+        closeRecentsChain();
+        if (inRecents) {
+            inRecents = false;
+            persister.wakeup(this, false);
+        }
+    }
+
     void setTaskToAffiliateWith(TaskRecord taskToAffiliateWith) {
         closeRecentsChain();
         mAffiliatedTaskId = taskToAffiliateWith.mAffiliatedTaskId;
@@ -358,15 +418,23 @@
         setNextAffiliate(null);
     }
 
-    void setLastThumbnail(Bitmap thumbnail) {
-        mLastThumbnail = thumbnail;
-        if (thumbnail == null) {
-            if (mLastThumbnailFile != null) {
-                mLastThumbnailFile.delete();
+    /**
+     * Sets the last thumbnail.
+     * @return whether the thumbnail was set
+     */
+    boolean setLastThumbnail(Bitmap thumbnail) {
+        if (mLastThumbnail != thumbnail) {
+            mLastThumbnail = thumbnail;
+            if (thumbnail == null) {
+                if (mLastThumbnailFile != null) {
+                    mLastThumbnailFile.delete();
+                }
+            } else {
+                mService.mTaskPersister.saveImage(thumbnail, mFilename);
             }
-        } else {
-            mService.mTaskPersister.saveImage(thumbnail, mFilename);
+            return true;
         }
+        return false;
     }
 
     void getLastThumbnail(TaskThumbnail thumbs) {
@@ -375,7 +443,8 @@
         if (mLastThumbnail == null) {
             thumbs.mainThumbnail = mService.mTaskPersister.getThumbnail(mFilename);
         }
-        if (mLastThumbnailFile.exists()) {
+        // Only load the thumbnail file if we don't have a thumbnail
+        if (thumbs.mainThumbnail == null && mLastThumbnailFile.exists()) {
             try {
                 thumbs.thumbnailFileDescriptor = ParcelFileDescriptor.open(mLastThumbnailFile,
                         ParcelFileDescriptor.MODE_READ_ONLY);
@@ -486,8 +555,9 @@
             isPersistable = r.isPersistable();
             mCallingUid = r.launchedFromUid;
             mCallingPackage = r.launchedFromPackage;
-            // Clamp to [1, 100].
-            maxRecents = Math.min(Math.max(r.info.maxRecents, 1), 100);
+            // Clamp to [1, max].
+            maxRecents = Math.min(Math.max(r.info.maxRecents, 1),
+                    ActivityManager.getMaxAppRecentsLimitStatic());
         } else {
             // Otherwise make all added activities match this one.
             r.mActivityType = taskType;
@@ -764,8 +834,13 @@
         return true;
     }
 
+    private static String createLastTaskDescriptionIconFilename(int taskId, long lastActiveTime) {
+        return String.valueOf(taskId) + LAST_ACTIVITY_ICON_SUFFIX + lastActiveTime +
+                TaskPersister.IMAGE_EXTENSION;
+    }
+
     void saveToXml(XmlSerializer out) throws IOException, XmlPullParserException {
-        Slog.i(TAG, "Saving task=" + this);
+        if (ActivityManagerService.DEBUG_RECENTS) Slog.i(TAG, "Saving task=" + this);
 
         out.attribute(null, ATTR_TASKID, String.valueOf(taskId));
         if (realActivity != null) {
@@ -774,13 +849,23 @@
         if (origActivity != null) {
             out.attribute(null, ATTR_ORIGACTIVITY, origActivity.flattenToShortString());
         }
+        // Write affinity, and root affinity if it is different from affinity.
+        // We use the special string "@" for a null root affinity, so we can identify
+        // later whether we were given a root affinity or should just make it the
+        // same as the affinity.
         if (affinity != null) {
             out.attribute(null, ATTR_AFFINITY, affinity);
+            if (!affinity.equals(rootAffinity)) {
+                out.attribute(null, ATTR_ROOT_AFFINITY, rootAffinity != null ? rootAffinity : "@");
+            }
+        } else if (rootAffinity != null) {
+            out.attribute(null, ATTR_ROOT_AFFINITY, rootAffinity != null ? rootAffinity : "@");
         }
         out.attribute(null, ATTR_ROOTHASRESET, String.valueOf(rootWasReset));
         out.attribute(null, ATTR_AUTOREMOVERECENTS, String.valueOf(autoRemoveRecents));
         out.attribute(null, ATTR_ASKEDCOMPATMODE, String.valueOf(askedCompatMode));
         out.attribute(null, ATTR_USERID, String.valueOf(userId));
+        out.attribute(null, ATTR_EFFECTIVE_UID, String.valueOf(effectiveUid));
         out.attribute(null, ATTR_TASKTYPE, String.valueOf(taskType));
         out.attribute(null, ATTR_FIRSTACTIVETIME, String.valueOf(firstActiveTime));
         out.attribute(null, ATTR_LASTACTIVETIME, String.valueOf(lastActiveTime));
@@ -790,8 +875,8 @@
             out.attribute(null, ATTR_LASTDESCRIPTION, lastDescription.toString());
         }
         if (lastTaskDescription != null) {
-            saveTaskDescription(lastTaskDescription, String.valueOf(taskId) +
-                    LAST_ACTIVITY_ICON_SUFFIX + lastActiveTime, out);
+            saveTaskDescription(lastTaskDescription, createLastTaskDescriptionIconFilename(taskId,
+                    lastActiveTime), out);
         }
         out.attribute(null, ATTR_TASK_AFFILIATION_COLOR, String.valueOf(mAffiliatedTaskColor));
         out.attribute(null, ATTR_TASK_AFFILIATION, String.valueOf(mAffiliatedTaskId));
@@ -834,11 +919,14 @@
         ComponentName realActivity = null;
         ComponentName origActivity = null;
         String affinity = null;
+        String rootAffinity = null;
+        boolean hasRootAffinity = false;
         boolean rootHasReset = false;
         boolean autoRemoveRecents = false;
         boolean askedCompatMode = false;
         int taskType = ActivityRecord.APPLICATION_ACTIVITY_TYPE;
         int userId = 0;
+        int effectiveUid = -1;
         String lastDescription = null;
         long firstActiveTime = -1;
         long lastActiveTime = -1;
@@ -867,6 +955,9 @@
                 origActivity = ComponentName.unflattenFromString(attrValue);
             } else if (ATTR_AFFINITY.equals(attrName)) {
                 affinity = attrValue;
+            } else if (ATTR_ROOT_AFFINITY.equals(attrName)) {
+                rootAffinity = attrValue;
+                hasRootAffinity = true;
             } else if (ATTR_ROOTHASRESET.equals(attrName)) {
                 rootHasReset = Boolean.valueOf(attrValue);
             } else if (ATTR_AUTOREMOVERECENTS.equals(attrName)) {
@@ -875,6 +966,8 @@
                 askedCompatMode = Boolean.valueOf(attrValue);
             } else if (ATTR_USERID.equals(attrName)) {
                 userId = Integer.valueOf(attrValue);
+            } else if (ATTR_EFFECTIVE_UID.equals(attrName)) {
+                effectiveUid = Integer.valueOf(attrValue);
             } else if (ATTR_TASKTYPE.equals(attrName)) {
                 taskType = Integer.valueOf(attrValue);
             } else if (ATTR_FIRSTACTIVETIME.equals(attrName)) {
@@ -933,14 +1026,40 @@
         }
 
         if (lastActiveTime >= 0) {
-            taskDescription.setIcon(TaskPersister.restoreImage(String.valueOf(taskId) +
-                    LAST_ACTIVITY_ICON_SUFFIX + lastActiveTime + TaskPersister.IMAGE_EXTENSION));
+            taskDescription.setIcon(TaskPersister.restoreImage(
+                    createLastTaskDescriptionIconFilename(taskId, lastActiveTime)));
+        }
+
+        if (!hasRootAffinity) {
+            rootAffinity = affinity;
+        } else if ("@".equals(rootAffinity)) {
+            rootAffinity = null;
+        }
+
+        if (effectiveUid <= 0) {
+            Intent checkIntent = intent != null ? intent : affinityIntent;
+            effectiveUid = 0;
+            if (checkIntent != null) {
+                IPackageManager pm = AppGlobals.getPackageManager();
+                try {
+                    ApplicationInfo ai = pm.getApplicationInfo(
+                            checkIntent.getComponent().getPackageName(),
+                            PackageManager.GET_UNINSTALLED_PACKAGES
+                                    | PackageManager.GET_DISABLED_COMPONENTS, userId);
+                    if (ai != null) {
+                        effectiveUid = ai.uid;
+                    }
+                } catch (RemoteException e) {
+                }
+            }
+            Slog.w(TAG, "Updating task #" + taskId + " for " + checkIntent
+                    + ": effectiveUid=" + effectiveUid);
         }
 
         final TaskRecord task = new TaskRecord(stackSupervisor.mService, taskId, intent,
-                affinityIntent, affinity, realActivity, origActivity, rootHasReset,
-                autoRemoveRecents, askedCompatMode, taskType, userId, lastDescription, activities,
-                firstActiveTime, lastActiveTime, lastTimeOnTop, neverRelinquishIdentity,
+                affinityIntent, affinity, rootAffinity, realActivity, origActivity, rootHasReset,
+                autoRemoveRecents, askedCompatMode, taskType, userId, effectiveUid, lastDescription,
+                activities, firstActiveTime, lastActiveTime, lastTimeOnTop, neverRelinquishIdentity,
                 taskDescription, taskAffiliation, prevTaskId, nextTaskId, taskAffiliationColor,
                 callingUid, callingPackage);
 
@@ -948,20 +1067,22 @@
             activities.get(activityNdx).task = task;
         }
 
-        Slog.i(TAG, "Restored task=" + task);
+        if (ActivityManagerService.DEBUG_RECENTS) Slog.d(TAG, "Restored task=" + task);
         return task;
     }
 
     void dump(PrintWriter pw, String prefix) {
-        if (rootWasReset || userId != 0 || numFullscreen != 0) {
-            pw.print(prefix); pw.print(" rootWasReset="); pw.print(rootWasReset);
-                    pw.print(" userId="); pw.print(userId);
-                    pw.print(" taskType="); pw.print(taskType);
-                    pw.print(" numFullscreen="); pw.print(numFullscreen);
-                    pw.print(" mTaskToReturnTo="); pw.println(mTaskToReturnTo);
-        }
-        if (affinity != null) {
-            pw.print(prefix); pw.print("affinity="); pw.println(affinity);
+        pw.print(prefix); pw.print("userId="); pw.print(userId);
+                pw.print(" effectiveUid="); UserHandle.formatUid(pw, effectiveUid);
+                pw.print(" mCallingUid="); UserHandle.formatUid(pw, mCallingUid);
+                pw.print(" mCallingPackage="); pw.println(mCallingPackage);
+        if (affinity != null || rootAffinity != null) {
+            pw.print(prefix); pw.print("affinity="); pw.print(affinity);
+            if (affinity == null || !affinity.equals(rootAffinity)) {
+                pw.print(" root="); pw.println(rootAffinity);
+            } else {
+                pw.println();
+            }
         }
         if (voiceSession != null || voiceInteractor != null) {
             pw.print(prefix); pw.print("VOICE: session=0x");
@@ -991,22 +1112,54 @@
             pw.print(prefix); pw.print("realActivity=");
             pw.println(realActivity.flattenToShortString());
         }
+        if (autoRemoveRecents || isPersistable || taskType != 0 || mTaskToReturnTo != 0
+                || numFullscreen != 0) {
+            pw.print(prefix); pw.print("autoRemoveRecents="); pw.print(autoRemoveRecents);
+                    pw.print(" isPersistable="); pw.print(isPersistable);
+                    pw.print(" numFullscreen="); pw.print(numFullscreen);
+                    pw.print(" taskType="); pw.print(taskType);
+                    pw.print(" mTaskToReturnTo="); pw.println(mTaskToReturnTo);
+        }
+        if (rootWasReset || mNeverRelinquishIdentity || mReuseTask) {
+            pw.print(prefix); pw.print("rootWasReset="); pw.print(rootWasReset);
+                    pw.print(" mNeverRelinquishIdentity="); pw.print(mNeverRelinquishIdentity);
+                    pw.print(" mReuseTask="); pw.println(mReuseTask);
+        }
+        if (mAffiliatedTaskId != taskId || mPrevAffiliateTaskId != -1 || mPrevAffiliate != null
+                || mNextAffiliateTaskId != -1 || mNextAffiliate != null) {
+            pw.print(prefix); pw.print("affiliation="); pw.print(mAffiliatedTaskId);
+                    pw.print(" prevAffiliation="); pw.print(mPrevAffiliateTaskId);
+                    pw.print(" (");
+                    if (mPrevAffiliate == null) {
+                        pw.print("null");
+                    } else {
+                        pw.print(Integer.toHexString(System.identityHashCode(mPrevAffiliate)));
+                    }
+                    pw.print(") nextAffiliation="); pw.print(mNextAffiliateTaskId);
+                    pw.print(" (");
+                    if (mNextAffiliate == null) {
+                        pw.print("null");
+                    } else {
+                        pw.print(Integer.toHexString(System.identityHashCode(mNextAffiliate)));
+                    }
+                    pw.println(")");
+        }
         pw.print(prefix); pw.print("Activities="); pw.println(mActivities);
-        if (!askedCompatMode) {
-            pw.print(prefix); pw.print("askedCompatMode="); pw.println(askedCompatMode);
+        if (!askedCompatMode || !inRecents || !isAvailable) {
+            pw.print(prefix); pw.print("askedCompatMode="); pw.print(askedCompatMode);
+                    pw.print(" inRecents="); pw.print(inRecents);
+                    pw.print(" isAvailable="); pw.println(isAvailable);
         }
         pw.print(prefix); pw.print("lastThumbnail="); pw.print(mLastThumbnail);
-                pw.print(" lastThumbnailFile="); pw.print(mLastThumbnailFile);
-                pw.print(" lastDescription="); pw.println(lastDescription);
+                pw.print(" lastThumbnailFile="); pw.println(mLastThumbnailFile);
+        if (lastDescription != null) {
+            pw.print(prefix); pw.print("lastDescription="); pw.println(lastDescription);
+        }
         pw.print(prefix); pw.print("hasBeenVisible="); pw.print(hasBeenVisible);
                 pw.print(" firstActiveTime="); pw.print(lastActiveTime);
                 pw.print(" lastActiveTime="); pw.print(lastActiveTime);
                 pw.print(" (inactive for ");
                 pw.print((getInactiveDuration()/1000)); pw.println("s)");
-        pw.print(prefix); pw.print("isPersistable="); pw.print(isPersistable);
-                pw.print(" affiliation="); pw.print(mAffiliatedTaskId);
-                pw.print(" prevAffiliation="); pw.print(mPrevAffiliateTaskId);
-                pw.print(" nextAffiliation="); pw.println(mNextAffiliateTaskId);
     }
 
     @Override
diff --git a/services/core/java/com/android/server/am/UserSwitchingDialog.java b/services/core/java/com/android/server/am/UserSwitchingDialog.java
new file mode 100644
index 0000000..dfc8df5
--- /dev/null
+++ b/services/core/java/com/android/server/am/UserSwitchingDialog.java
@@ -0,0 +1,92 @@
+/*
+ * Copyright (C) 2014 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.server.am;
+
+import android.app.AlertDialog;
+import android.app.Service;
+import android.content.ActivityNotFoundException;
+import android.content.Context;
+import android.content.DialogInterface;
+import android.content.Intent;
+import android.content.res.Resources;
+import android.os.Handler;
+import android.os.Message;
+import android.util.Slog;
+import android.view.LayoutInflater;
+import android.view.View;
+import android.view.WindowManager;
+import android.widget.TextView;
+
+import com.android.internal.R;
+
+/**
+ * Dialog to show when a user switch it about to happen. The intent is to snapshot the screen
+ * immediately after the dialog shows so that the user is informed that something is happening
+ * in the background rather than just freeze the screen and not know if the user-switch affordance
+ * was being handled.
+ */
+final class UserSwitchingDialog extends AlertDialog {
+    private static final String TAG = "ActivityManagerUserSwitchingDialog";
+
+    private static final int MSG_START_USER = 1;
+
+    private final ActivityManagerService mService;
+    private final int mUserId;
+
+    public UserSwitchingDialog(ActivityManagerService service, Context context,
+            int userId, String userName, boolean aboveSystem) {
+        super(context);
+
+        mService = service;
+        mUserId = userId;
+
+        // Set up the dialog contents
+        setCancelable(false);
+        Resources res = getContext().getResources();
+        // Custom view due to alignment and font size requirements
+        View view = LayoutInflater.from(getContext()).inflate(R.layout.user_switching_dialog, null);
+        ((TextView) view.findViewById(R.id.message)).setText(
+                res.getString(com.android.internal.R.string.user_switching_message, userName));
+        setView(view);
+
+        if (aboveSystem) {
+            getWindow().setType(WindowManager.LayoutParams.TYPE_SYSTEM_ERROR);
+        }
+        WindowManager.LayoutParams attrs = getWindow().getAttributes();
+        attrs.privateFlags = WindowManager.LayoutParams.PRIVATE_FLAG_SYSTEM_ERROR |
+                WindowManager.LayoutParams.PRIVATE_FLAG_SHOW_FOR_ALL_USERS;
+        getWindow().setAttributes(attrs);
+    }
+
+    @Override
+    public void show() {
+        super.show();
+        // TODO: Instead of just an arbitrary delay, wait for a signal that the window was fully
+        // displayed by the window manager
+        mHandler.sendMessageDelayed(mHandler.obtainMessage(MSG_START_USER), 250);
+    }
+
+    private final Handler mHandler = new Handler() {
+        public void handleMessage(Message msg) {
+            switch (msg.what) {
+                case MSG_START_USER:
+                    mService.startUserInForeground(mUserId, UserSwitchingDialog.this);
+                    break;
+            }
+        }
+    };
+}
diff --git a/services/core/java/com/android/server/connectivity/NetworkAgentInfo.java b/services/core/java/com/android/server/connectivity/NetworkAgentInfo.java
index 4eb2ef1..15ffc0d 100644
--- a/services/core/java/com/android/server/connectivity/NetworkAgentInfo.java
+++ b/services/core/java/com/android/server/connectivity/NetworkAgentInfo.java
@@ -40,13 +40,21 @@
  */
 public class NetworkAgentInfo {
     public NetworkInfo networkInfo;
-    public final Network network;
+    public Network network;
     public LinkProperties linkProperties;
     public NetworkCapabilities networkCapabilities;
-    public int currentScore;
     public final NetworkMonitor networkMonitor;
     public final NetworkMisc networkMisc;
     public boolean created;
+    public boolean validated;
+
+    // This represents the last score received from the NetworkAgent.
+    private int currentScore;
+    // Penalty applied to scores of Networks that have not been validated.
+    private static final int UNVALIDATED_SCORE_PENALTY = 40;
+
+    // Score for explicitly connected network.
+    private static final int EXPLICITLY_SELECTED_NETWORK_SCORE = 100;
 
     // The list of NetworkRequests being satisfied by this Network.
     public final SparseArray<NetworkRequest> networkRequests = new SparseArray<NetworkRequest>();
@@ -55,12 +63,12 @@
     public final Messenger messenger;
     public final AsyncChannel asyncChannel;
 
-    public NetworkAgentInfo(Messenger messenger, AsyncChannel ac, int netId, NetworkInfo info,
+    public NetworkAgentInfo(Messenger messenger, AsyncChannel ac, NetworkInfo info,
             LinkProperties lp, NetworkCapabilities nc, int score, Context context, Handler handler,
             NetworkMisc misc) {
         this.messenger = messenger;
         asyncChannel = ac;
-        network = new Network(netId);
+        network = null;
         networkInfo = info;
         linkProperties = lp;
         networkCapabilities = nc;
@@ -68,6 +76,7 @@
         networkMonitor = new NetworkMonitor(context, handler, this);
         networkMisc = misc;
         created = false;
+        validated = false;
     }
 
     public void addRequest(NetworkRequest networkRequest) {
@@ -78,15 +87,40 @@
         return networkCapabilities.hasTransport(NetworkCapabilities.TRANSPORT_VPN);
     }
 
+    // Get the current score for this Network.  This may be modified from what the
+    // NetworkAgent sent, as it has modifiers applied to it.
+    public int getCurrentScore() {
+        // TODO: We may want to refactor this into a NetworkScore class that takes a base score from
+        // the NetworkAgent and signals from the NetworkAgent and uses those signals to modify the
+        // score.  The NetworkScore class would provide a nice place to centralize score constants
+        // so they are not scattered about the transports.
+
+        int score = currentScore;
+
+        if (!validated) score -= UNVALIDATED_SCORE_PENALTY;
+        if (score < 0) score = 0;
+
+        if (networkMisc.explicitlySelected) score = EXPLICITLY_SELECTED_NETWORK_SCORE;
+
+        return score;
+    }
+
+    public void setCurrentScore(int newScore) {
+        currentScore = newScore;
+    }
+
     public String toString() {
         return "NetworkAgentInfo{ ni{" + networkInfo + "}  network{" +
                 network + "}  lp{" +
                 linkProperties + "}  nc{" +
-                networkCapabilities + "}  Score{" + currentScore + "} }";
+                networkCapabilities + "}  Score{" + getCurrentScore() + "} " +
+                "validated{" + validated + "} created{" + created + "} " +
+                "explicitlySelected{" + networkMisc.explicitlySelected + "} }";
     }
 
     public String name() {
         return "NetworkAgentInfo [" + networkInfo.getTypeName() + " (" +
-                networkInfo.getSubtypeName() + ") - " + network.toString() + "]";
+                networkInfo.getSubtypeName() + ") - " +
+                (network == null ? "null" : network.toString()) + "]";
     }
 }
diff --git a/services/core/java/com/android/server/connectivity/NetworkMonitor.java b/services/core/java/com/android/server/connectivity/NetworkMonitor.java
index 5057994..fab064c 100644
--- a/services/core/java/com/android/server/connectivity/NetworkMonitor.java
+++ b/services/core/java/com/android/server/connectivity/NetworkMonitor.java
@@ -16,6 +16,7 @@
 
 package com.android.server.connectivity;
 
+import android.app.AlarmManager;
 import android.app.PendingIntent;
 import android.content.BroadcastReceiver;
 import android.content.ComponentName;
@@ -26,6 +27,7 @@
 import android.net.Network;
 import android.net.NetworkCapabilities;
 import android.net.NetworkInfo;
+import android.net.TrafficStats;
 import android.net.wifi.WifiInfo;
 import android.net.wifi.WifiManager;
 import android.os.Handler;
@@ -93,6 +95,18 @@
             "android.net.netmon.captive_portal_logged_in";
     private static final String LOGGED_IN_RESULT = "result";
 
+    // After a network has been tested this result can be sent with EVENT_NETWORK_TESTED.
+    // The network should be used as a default internet connection.  It was found to be:
+    // 1. a functioning network providing internet access, or
+    // 2. a captive portal and the user decided to use it as is.
+    public static final int NETWORK_TEST_RESULT_VALID = 0;
+    // After a network has been tested this result can be sent with EVENT_NETWORK_TESTED.
+    // The network should not be used as a default internet connection.  It was found to be:
+    // 1. a captive portal and the user is prompted to sign-in, or
+    // 2. a captive portal and the user did not want to use it, or
+    // 3. a broken network (e.g. DNS failed, connect failed, HTTP request failed).
+    public static final int NETWORK_TEST_RESULT_INVALID = 1;
+
     private static final int BASE = Protocol.BASE_NETWORK_MONITOR;
 
     /**
@@ -102,10 +116,11 @@
     public static final int CMD_NETWORK_CONNECTED = BASE + 1;
 
     /**
-     * Inform ConnectivityService that the network is validated.
+     * Inform ConnectivityService that the network has been tested.
      * obj = NetworkAgentInfo
+     * arg1 = One of the NETWORK_TESTED_RESULT_* constants.
      */
-    public static final int EVENT_NETWORK_VALIDATED = BASE + 2;
+    public static final int EVENT_NETWORK_TESTED = BASE + 2;
 
     /**
      * Inform NetworkMonitor to linger a network.  The Monitor should
@@ -139,34 +154,28 @@
     private static final int CMD_REEVALUATE = BASE + 6;
 
     /**
-     * Message to self indicating network evaluation is complete.
-     * arg1 = Token to ignore old messages.
-     * arg2 = HTTP response code of network evaluation.
-     */
-    private static final int EVENT_REEVALUATION_COMPLETE = BASE + 7;
-
-    /**
      * Inform NetworkMonitor that the network has disconnected.
      */
-    public static final int CMD_NETWORK_DISCONNECTED = BASE + 8;
+    public static final int CMD_NETWORK_DISCONNECTED = BASE + 7;
 
     /**
      * Force evaluation even if it has succeeded in the past.
+     * arg1 = UID responsible for requesting this reeval.  Will be billed for data.
      */
-    public static final int CMD_FORCE_REEVALUATION = BASE + 9;
+    public static final int CMD_FORCE_REEVALUATION = BASE + 8;
 
     /**
      * Message to self indicating captive portal login is complete.
      * arg1 = Token to ignore old messages.
      * arg2 = 1 if we should use this network, 0 otherwise.
      */
-    private static final int CMD_CAPTIVE_PORTAL_LOGGED_IN = BASE + 10;
+    private static final int CMD_CAPTIVE_PORTAL_LOGGED_IN = BASE + 9;
 
     /**
      * Message to self indicating user desires to log into captive portal.
      * arg1 = Token to ignore old messages.
      */
-    private static final int CMD_USER_WANTS_SIGN_IN = BASE + 11;
+    private static final int CMD_USER_WANTS_SIGN_IN = BASE + 10;
 
     /**
      * Request ConnectivityService display provisioning notification.
@@ -174,22 +183,22 @@
      * arg2    = NetID.
      * obj     = Intent to be launched when notification selected by user, null if !arg1.
      */
-    public static final int EVENT_PROVISIONING_NOTIFICATION = BASE + 12;
+    public static final int EVENT_PROVISIONING_NOTIFICATION = BASE + 11;
 
     /**
      * Message to self indicating sign-in app bypassed captive portal.
      */
-    private static final int EVENT_APP_BYPASSED_CAPTIVE_PORTAL = BASE + 13;
+    private static final int EVENT_APP_BYPASSED_CAPTIVE_PORTAL = BASE + 12;
 
     /**
      * Message to self indicating no sign-in app responded.
      */
-    private static final int EVENT_NO_APP_RESPONSE = BASE + 14;
+    private static final int EVENT_NO_APP_RESPONSE = BASE + 13;
 
     /**
      * Message to self indicating sign-in app indicates sign-in is not possible.
      */
-    private static final int EVENT_APP_INDICATES_SIGN_IN_IMPOSSIBLE = BASE + 15;
+    private static final int EVENT_APP_INDICATES_SIGN_IN_IMPOSSIBLE = BASE + 14;
 
     private static final String LINGER_DELAY_PROPERTY = "persist.netmon.linger";
     // Default to 30s linger time-out.
@@ -204,6 +213,8 @@
     private static final int MAX_RETRIES = 10;
     private final int mReevaluateDelayMs;
     private int mReevaluateToken = 0;
+    private static final int INVALID_UID = -1;
+    private int mUidResponsibleForReeval = INVALID_UID;
 
     private int mCaptivePortalLoggedInToken = 0;
     private int mUserPromptedToken = 0;
@@ -213,19 +224,21 @@
     private final NetworkAgentInfo mNetworkAgentInfo;
     private final TelephonyManager mTelephonyManager;
     private final WifiManager mWifiManager;
+    private final AlarmManager mAlarmManager;
 
     private String mServer;
     private boolean mIsCaptivePortalCheckEnabled = false;
 
+    // Set if the user explicitly selected "Do not use this network" in captive portal sign-in app.
+    private boolean mUserDoesNotWant = false;
+
     public boolean systemReady = false;
 
     private State mDefaultState = new DefaultState();
     private State mOfflineState = new OfflineState();
     private State mValidatedState = new ValidatedState();
     private State mEvaluatingState = new EvaluatingState();
-    private State mUninteractiveAppsPromptedState = new UninteractiveAppsPromptedState();
     private State mUserPromptedState = new UserPromptedState();
-    private State mInteractiveAppsPromptedState = new InteractiveAppsPromptedState();
     private State mCaptivePortalState = new CaptivePortalState();
     private State mLingeringState = new LingeringState();
 
@@ -238,17 +251,16 @@
         mNetworkAgentInfo = networkAgentInfo;
         mTelephonyManager = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);
         mWifiManager = (WifiManager) context.getSystemService(Context.WIFI_SERVICE);
+        mAlarmManager = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE);
 
         addState(mDefaultState);
         addState(mOfflineState, mDefaultState);
         addState(mValidatedState, mDefaultState);
         addState(mEvaluatingState, mDefaultState);
-        addState(mUninteractiveAppsPromptedState, mDefaultState);
         addState(mUserPromptedState, mDefaultState);
-        addState(mInteractiveAppsPromptedState, mDefaultState);
         addState(mCaptivePortalState, mDefaultState);
         addState(mLingeringState, mDefaultState);
-        setInitialState(mOfflineState);
+        setInitialState(mDefaultState);
 
         mServer = Settings.Global.getString(mContext.getContentResolver(),
                 Settings.Global.CAPTIVE_PORTAL_SERVER);
@@ -272,31 +284,45 @@
                 case CMD_NETWORK_LINGER:
                     if (DBG) log("Lingering");
                     transitionTo(mLingeringState);
-                    break;
+                    return HANDLED;
                 case CMD_NETWORK_CONNECTED:
                     if (DBG) log("Connected");
                     transitionTo(mEvaluatingState);
-                    break;
+                    return HANDLED;
                 case CMD_NETWORK_DISCONNECTED:
                     if (DBG) log("Disconnected - quitting");
                     quit();
-                    break;
+                    return HANDLED;
                 case CMD_FORCE_REEVALUATION:
                     if (DBG) log("Forcing reevaluation");
+                    mUidResponsibleForReeval = message.arg1;
                     transitionTo(mEvaluatingState);
-                    break;
+                    return HANDLED;
                 default:
-                    break;
+                    return HANDLED;
             }
-            return HANDLED;
         }
     }
 
     private class OfflineState extends State {
         @Override
+        public void enter() {
+            mConnectivityServiceHandler.sendMessage(obtainMessage(EVENT_NETWORK_TESTED,
+                    NETWORK_TEST_RESULT_INVALID, 0, mNetworkAgentInfo));
+        }
+
+        @Override
         public boolean processMessage(Message message) {
             if (DBG) log(getName() + message.toString());
-            return NOT_HANDLED;
+                        switch (message.what) {
+                case CMD_FORCE_REEVALUATION:
+                    // If the user has indicated they explicitly do not want to use this network,
+                    // don't allow a reevaluation as this will be pointless and could result in
+                    // the user being annoyed with repeated unwanted notifications.
+                    return mUserDoesNotWant ? HANDLED : NOT_HANDLED;
+                default:
+                    return NOT_HANDLED;
+            }
         }
     }
 
@@ -304,8 +330,8 @@
         @Override
         public void enter() {
             if (DBG) log("Validated");
-            mConnectivityServiceHandler.sendMessage(
-                    obtainMessage(EVENT_NETWORK_VALIDATED, mNetworkAgentInfo));
+            mConnectivityServiceHandler.sendMessage(obtainMessage(EVENT_NETWORK_TESTED,
+                    NETWORK_TEST_RESULT_VALID, 0, mNetworkAgentInfo));
         }
 
         @Override
@@ -314,31 +340,24 @@
             switch (message.what) {
                 case CMD_NETWORK_CONNECTED:
                     transitionTo(mValidatedState);
-                    break;
+                    return HANDLED;
                 default:
                     return NOT_HANDLED;
             }
-            return HANDLED;
         }
     }
 
     private class EvaluatingState extends State {
         private int mRetries;
 
-        private class EvaluateInternetConnectivity extends Thread {
-            private int mToken;
-            EvaluateInternetConnectivity(int token) {
-                mToken = token;
-            }
-            public void run() {
-                sendMessage(EVENT_REEVALUATION_COMPLETE, mToken, isCaptivePortal());
-            }
-        }
-
         @Override
         public void enter() {
             mRetries = 0;
             sendMessage(CMD_REEVALUATE, ++mReevaluateToken, 0);
+            if (mUidResponsibleForReeval != INVALID_UID) {
+                TrafficStats.setThreadStatsUid(mUidResponsibleForReeval);
+                mUidResponsibleForReeval = INVALID_UID;
+            }
         }
 
         @Override
@@ -347,105 +366,41 @@
             switch (message.what) {
                 case CMD_REEVALUATE:
                     if (message.arg1 != mReevaluateToken)
-                        break;
+                        return HANDLED;
                     if (mNetworkAgentInfo.isVPN()) {
                         transitionTo(mValidatedState);
+                        return HANDLED;
                     }
                     // If network provides no internet connectivity adjust evaluation.
                     if (!mNetworkAgentInfo.networkCapabilities.hasCapability(
                             NetworkCapabilities.NET_CAPABILITY_INTERNET)) {
                         // TODO: Try to verify something works.  Do all gateways respond to pings?
                         transitionTo(mValidatedState);
+                        return HANDLED;
                     }
-                    // Kick off a thread to perform internet connectivity evaluation.
-                    Thread thread = new EvaluateInternetConnectivity(mReevaluateToken);
-                    thread.run();
-                    break;
-                case EVENT_REEVALUATION_COMPLETE:
-                    if (message.arg1 != mReevaluateToken)
-                        break;
-                    int httpResponseCode = message.arg2;
+                    int httpResponseCode = isCaptivePortal();
                     if (httpResponseCode == 204) {
                         transitionTo(mValidatedState);
                     } else if (httpResponseCode >= 200 && httpResponseCode <= 399) {
-                        transitionTo(mUninteractiveAppsPromptedState);
+                        transitionTo(mUserPromptedState);
                     } else if (++mRetries > MAX_RETRIES) {
                         transitionTo(mOfflineState);
                     } else if (mReevaluateDelayMs >= 0) {
                         Message msg = obtainMessage(CMD_REEVALUATE, ++mReevaluateToken, 0);
                         sendMessageDelayed(msg, mReevaluateDelayMs);
                     }
-                    break;
+                    return HANDLED;
+                case CMD_FORCE_REEVALUATION:
+                    // Ignore duplicate requests.
+                    return HANDLED;
                 default:
                     return NOT_HANDLED;
             }
-            return HANDLED;
         }
-    }
 
-    private class AppRespondedBroadcastReceiver extends BroadcastReceiver {
-        private static final int CAPTIVE_PORTAL_UNINITIALIZED_RETURN_CODE = 0;
-        private boolean mCanceled;
-        AppRespondedBroadcastReceiver() {
-            mCanceled = false;
-        }
-        public void send(String action) {
-            Intent intent = new Intent(action);
-            intent.putExtra(ConnectivityManager.EXTRA_NETWORK, mNetworkAgentInfo.network);
-            mContext.sendOrderedBroadcastAsUser(intent, UserHandle.ALL, null, this, getHandler(),
-                    CAPTIVE_PORTAL_UNINITIALIZED_RETURN_CODE, null, null);
-        }
-        public void cancel() {
-            mCanceled = true;
-        }
         @Override
-        public void onReceive(Context context, Intent intent) {
-            if (!mCanceled) {
-                cancel();
-                switch (getResultCode()) {
-                    case ConnectivityManager.CAPTIVE_PORTAL_SIGNED_IN:
-                        sendMessage(EVENT_APP_BYPASSED_CAPTIVE_PORTAL);
-                        break;
-                    case ConnectivityManager.CAPTIVE_PORTAL_DISCONNECT:
-                        sendMessage(EVENT_APP_INDICATES_SIGN_IN_IMPOSSIBLE);
-                        break;
-                    // NOTE: This case label makes compiler enforce no overlap between result codes.
-                    case CAPTIVE_PORTAL_UNINITIALIZED_RETURN_CODE:
-                    default:
-                        sendMessage(EVENT_NO_APP_RESPONSE);
-                        break;
-                }
-            }
-        }
-    }
-
-    private class UninteractiveAppsPromptedState extends State {
-        private AppRespondedBroadcastReceiver mReceiver;
-        @Override
-        public void enter() {
-            mReceiver = new AppRespondedBroadcastReceiver();
-            mReceiver.send(ConnectivityManager.ACTION_CAPTIVE_PORTAL_DETECTED);
-        }
-        @Override
-        public boolean processMessage(Message message) {
-            if (DBG) log(getName() + message.toString());
-            switch (message.what) {
-                case EVENT_APP_BYPASSED_CAPTIVE_PORTAL:
-                    transitionTo(mValidatedState);
-                    break;
-                case EVENT_APP_INDICATES_SIGN_IN_IMPOSSIBLE:
-                    transitionTo(mOfflineState);
-                    break;
-                case EVENT_NO_APP_RESPONSE:
-                    transitionTo(mUserPromptedState);
-                    break;
-                default:
-                    return NOT_HANDLED;
-            }
-            return HANDLED;
-        }
         public void exit() {
-            mReceiver.cancel();
+            TrafficStats.clearThreadStatsUid();
         }
     }
 
@@ -468,6 +423,8 @@
 
         @Override
         public void enter() {
+            mConnectivityServiceHandler.sendMessage(obtainMessage(EVENT_NETWORK_TESTED,
+                    NETWORK_TEST_RESULT_INVALID, 0, mNetworkAgentInfo));
             // Wait for user to select sign-in notifcation.
             mUserRespondedBroadcastReceiver = new UserRespondedBroadcastReceiver(
                     ++mUserPromptedToken);
@@ -488,13 +445,12 @@
             switch (message.what) {
                 case CMD_USER_WANTS_SIGN_IN:
                     if (message.arg1 != mUserPromptedToken)
-                        break;
-                    transitionTo(mInteractiveAppsPromptedState);
-                    break;
+                        return HANDLED;
+                    transitionTo(mCaptivePortalState);
+                    return HANDLED;
                 default:
                     return NOT_HANDLED;
             }
-            return HANDLED;
         }
 
         @Override
@@ -507,36 +463,6 @@
         }
     }
 
-    private class InteractiveAppsPromptedState extends State {
-        private AppRespondedBroadcastReceiver mReceiver;
-        @Override
-        public void enter() {
-            mReceiver = new AppRespondedBroadcastReceiver();
-            mReceiver.send(ConnectivityManager.ACTION_CAPTIVE_PORTAL_SIGN_IN);
-        }
-        @Override
-        public boolean processMessage(Message message) {
-            if (DBG) log(getName() + message.toString());
-            switch (message.what) {
-                case EVENT_APP_BYPASSED_CAPTIVE_PORTAL:
-                    transitionTo(mValidatedState);
-                    break;
-                case EVENT_APP_INDICATES_SIGN_IN_IMPOSSIBLE:
-                    transitionTo(mOfflineState);
-                    break;
-                case EVENT_NO_APP_RESPONSE:
-                    transitionTo(mCaptivePortalState);
-                    break;
-                default:
-                    return NOT_HANDLED;
-            }
-            return HANDLED;
-        }
-        public void exit() {
-            mReceiver.cancel();
-        }
-    }
-
     private class CaptivePortalState extends State {
         private class CaptivePortalLoggedInBroadcastReceiver extends BroadcastReceiver {
             private final int mToken;
@@ -581,18 +507,18 @@
             switch (message.what) {
                 case CMD_CAPTIVE_PORTAL_LOGGED_IN:
                     if (message.arg1 != mCaptivePortalLoggedInToken)
-                        break;
+                        return HANDLED;
                     if (message.arg2 == 0) {
+                        mUserDoesNotWant = true;
                         // TODO: Should teardown network.
                         transitionTo(mOfflineState);
                     } else {
                         transitionTo(mValidatedState);
                     }
-                    break;
+                    return HANDLED;
                 default:
                     return NOT_HANDLED;
             }
-            return HANDLED;
         }
 
         @Override
@@ -603,10 +529,38 @@
     }
 
     private class LingeringState extends State {
+        private static final String ACTION_LINGER_EXPIRED = "android.net.netmon.lingerExpired";
+        private static final String EXTRA_NETID = "lingerExpiredNetId";
+        private static final String EXTRA_TOKEN = "lingerExpiredToken";
+
+        private class LingerExpiredBroadcastReceiver extends BroadcastReceiver {
+            @Override
+            public void onReceive(Context context, Intent intent) {
+                if (intent.getAction().equals(ACTION_LINGER_EXPIRED) &&
+                        Integer.parseInt(intent.getStringExtra(EXTRA_NETID)) ==
+                        mNetworkAgentInfo.network.netId) {
+                    sendMessage(CMD_LINGER_EXPIRED,
+                            Integer.parseInt(intent.getStringExtra(EXTRA_TOKEN)));
+                }
+            }
+        }
+
+        private BroadcastReceiver mBroadcastReceiver;
+        private PendingIntent mIntent;
+
         @Override
         public void enter() {
-            Message message = obtainMessage(CMD_LINGER_EXPIRED, ++mLingerToken, 0);
-            sendMessageDelayed(message, mLingerDelayMs);
+            mBroadcastReceiver = new LingerExpiredBroadcastReceiver();
+            mContext.registerReceiver(mBroadcastReceiver, new IntentFilter(ACTION_LINGER_EXPIRED));
+
+            Intent intent = new Intent(ACTION_LINGER_EXPIRED, null);
+            intent.putExtra(EXTRA_NETID, String.valueOf(mNetworkAgentInfo.network.netId));
+            intent.putExtra(EXTRA_TOKEN, String.valueOf(++mLingerToken));
+            mIntent = PendingIntent.getBroadcast(mContext, 0, intent, 0);
+            long wakeupTime = SystemClock.elapsedRealtime() + mLingerDelayMs;
+            mAlarmManager.setWindow(AlarmManager.ELAPSED_REALTIME_WAKEUP, wakeupTime,
+                    // Give a specific window so we aren't subject to unknown inexactitude.
+                    mLingerDelayMs / 6, mIntent);
         }
 
         @Override
@@ -616,17 +570,28 @@
                 case CMD_NETWORK_CONNECTED:
                     // Go straight to active as we've already evaluated.
                     transitionTo(mValidatedState);
-                    break;
+                    return HANDLED;
                 case CMD_LINGER_EXPIRED:
                     if (message.arg1 != mLingerToken)
-                        break;
+                        return HANDLED;
                     mConnectivityServiceHandler.sendMessage(
                             obtainMessage(EVENT_NETWORK_LINGER_COMPLETE, mNetworkAgentInfo));
-                    break;
+                    return HANDLED;
+                case CMD_FORCE_REEVALUATION:
+                    // Ignore reevaluation attempts when lingering.  A reevaluation could result
+                    // in a transition to the validated state which would abort the linger
+                    // timeout.  Lingering is the result of score assessment; validity is
+                    // irrelevant.
+                    return HANDLED;
                 default:
                     return NOT_HANDLED;
             }
-            return HANDLED;
+        }
+
+        @Override
+        public void exit() {
+            mAlarmManager.cancel(mIntent);
+            mContext.unregisterReceiver(mBroadcastReceiver);
         }
     }
 
@@ -645,8 +610,7 @@
                 log("Checking " + url.toString() + " on " +
                         mNetworkAgentInfo.networkInfo.getExtraInfo());
             }
-            url = mNetworkAgentInfo.network.getBoundURL(url);
-            urlConnection = (HttpURLConnection) url.openConnection();
+            urlConnection = (HttpURLConnection) mNetworkAgentInfo.network.openConnection(url);
             urlConnection.setInstanceFollowRedirects(false);
             urlConnection.setConnectTimeout(SOCKET_TIMEOUT_MS);
             urlConnection.setReadTimeout(SOCKET_TIMEOUT_MS);
@@ -775,6 +739,7 @@
             latencyBroadcast.putExtra(EXTRA_IS_CAPTIVE_PORTAL, isCaptivePortal);
             latencyBroadcast.putExtra(EXTRA_RESPONSE_TIMESTAMP_MS, responseTimestampMs);
         }
-        mContext.sendBroadcast(latencyBroadcast, PERMISSION_ACCESS_NETWORK_CONDITIONS);
+        mContext.sendBroadcastAsUser(latencyBroadcast, UserHandle.CURRENT,
+                PERMISSION_ACCESS_NETWORK_CONDITIONS);
     }
 }
diff --git a/services/core/java/com/android/server/connectivity/Tethering.java b/services/core/java/com/android/server/connectivity/Tethering.java
index fa8626f..7c303ff 100644
--- a/services/core/java/com/android/server/connectivity/Tethering.java
+++ b/services/core/java/com/android/server/connectivity/Tethering.java
@@ -31,6 +31,7 @@
 import android.net.InterfaceConfiguration;
 import android.net.LinkAddress;
 import android.net.LinkProperties;
+import android.net.Network;
 import android.net.NetworkInfo;
 import android.net.NetworkUtils;
 import android.net.RouteInfo;
@@ -56,6 +57,7 @@
 import java.net.InetAddress;
 import java.net.Inet4Address;
 import java.util.ArrayList;
+import java.util.Arrays;
 import java.util.Collection;
 import java.util.HashMap;
 import java.util.Iterator;
@@ -471,6 +473,8 @@
         mTetheredNotification.flags = Notification.FLAG_ONGOING_EVENT;
         mTetheredNotification.tickerText = title;
         mTetheredNotification.visibility = Notification.VISIBILITY_PUBLIC;
+        mTetheredNotification.color = mContext.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color);
         mTetheredNotification.setLatestEventInfo(mContext, title, message, pi);
         mTetheredNotification.category = Notification.CATEGORY_STATUS;
 
@@ -740,7 +744,7 @@
         static final int CMD_IP_FORWARDING_ENABLE_ERROR  =  7;
         // notification from the master SM that it had trouble disabling IP Forwarding
         static final int CMD_IP_FORWARDING_DISABLE_ERROR =  8;
-        // notification from the master SM that it had trouble staring tethering
+        // notification from the master SM that it had trouble starting tethering
         static final int CMD_START_TETHERING_ERROR       =  9;
         // notification from the master SM that it had trouble stopping tethering
         static final int CMD_STOP_TETHERING_ERROR        = 10;
@@ -1233,12 +1237,6 @@
                         return false;
                     }
                 }
-                try {
-                    mNMService.setDnsForwarders(mDefaultDnsServers);
-                } catch (Exception e) {
-                    transitionTo(mSetDnsForwardersErrorState);
-                    return false;
-                }
                 return true;
             }
             protected boolean turnOffMasterTetherSettings() {
@@ -1346,8 +1344,17 @@
                             }
                         }
                         try {
-                            mNMService.setDnsForwarders(dnsServers);
+                            Network network = getConnectivityManager().getNetworkForType(upType);
+                            if (network == null) {
+                                Log.e(TAG, "No Network for upstream type " + upType + "!");
+                            }
+                            if (VDBG) {
+                                Log.d(TAG, "Setting DNS forwarders: Network=" + network +
+                                       ", dnsServers=" + Arrays.toString(dnsServers));
+                            }
+                            mNMService.setDnsForwarders(network, dnsServers);
                         } catch (Exception e) {
+                            Log.e(TAG, "Setting DNS forwarders failed!");
                             transitionTo(mSetDnsForwardersErrorState);
                         }
                     }
diff --git a/services/core/java/com/android/server/connectivity/Vpn.java b/services/core/java/com/android/server/connectivity/Vpn.java
index eddf414..afc2a39 100644
--- a/services/core/java/com/android/server/connectivity/Vpn.java
+++ b/services/core/java/com/android/server/connectivity/Vpn.java
@@ -17,12 +17,12 @@
 package com.android.server.connectivity;
 
 import static android.Manifest.permission.BIND_VPN_SERVICE;
+import static android.os.UserHandle.PER_USER_RANGE;
 import static android.system.OsConstants.AF_INET;
 import static android.system.OsConstants.AF_INET6;
 
 import android.app.AppGlobals;
-import android.app.Notification;
-import android.app.NotificationManager;
+import android.app.AppOpsManager;
 import android.app.PendingIntent;
 import android.content.BroadcastReceiver;
 import android.content.ComponentName;
@@ -35,10 +35,6 @@
 import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.pm.ResolveInfo;
 import android.content.pm.UserInfo;
-import android.graphics.Bitmap;
-import android.graphics.Canvas;
-import android.graphics.drawable.Drawable;
-import android.net.BaseNetworkStateTracker;
 import android.net.ConnectivityManager;
 import android.net.IConnectivityManager;
 import android.net.INetworkManagementEventObserver;
@@ -51,7 +47,6 @@
 import android.net.NetworkInfo;
 import android.net.NetworkInfo.DetailedState;
 import android.net.NetworkMisc;
-import android.net.NetworkUtils;
 import android.net.RouteInfo;
 import android.net.UidRange;
 import android.os.Binder;
@@ -70,15 +65,15 @@
 import android.security.Credentials;
 import android.security.KeyStore;
 import android.util.Log;
-import android.util.SparseBooleanArray;
 
 import com.android.internal.annotations.GuardedBy;
-import com.android.internal.R;
 import com.android.internal.net.LegacyVpnInfo;
 import com.android.internal.net.VpnConfig;
 import com.android.internal.net.VpnProfile;
 import com.android.server.net.BaseNetworkObserver;
 
+import libcore.io.IoUtils;
+
 import java.io.File;
 import java.io.IOException;
 import java.io.InputStream;
@@ -90,10 +85,10 @@
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.List;
+import java.util.SortedSet;
+import java.util.TreeSet;
 import java.util.concurrent.atomic.AtomicInteger;
 
-import libcore.io.IoUtils;
-
 /**
  * @hide
  */
@@ -115,7 +110,6 @@
     private Connection mConnection;
     private LegacyVpnRunner mLegacyVpnRunner;
     private PendingIntent mStatusIntent;
-    private volatile boolean mEnableNotif = true;
     private volatile boolean mEnableTeardown = true;
     private final IConnectivityManager mConnService;
     private final INetworkManagementService mNetd;
@@ -129,38 +123,39 @@
     private List<UidRange> mVpnUsers = null;
     private BroadcastReceiver mUserIntentReceiver = null;
 
-    private final int mUserId;
+    // Handle of user initiating VPN.
+    private final int mUserHandle;
 
     public Vpn(Looper looper, Context context, INetworkManagementService netService,
-            IConnectivityManager connService, int userId) {
+            IConnectivityManager connService, int userHandle) {
         mContext = context;
         mNetd = netService;
         mConnService = connService;
-        mUserId = userId;
+        mUserHandle = userHandle;
         mLooper = looper;
 
         mPackage = VpnConfig.LEGACY_VPN;
-        mOwnerUID = getAppUid(mPackage);
+        mOwnerUID = getAppUid(mPackage, mUserHandle);
 
         try {
             netService.registerObserver(mObserver);
         } catch (RemoteException e) {
             Log.wtf(TAG, "Problem registering observer", e);
         }
-        if (userId == UserHandle.USER_OWNER) {
+        if (userHandle == UserHandle.USER_OWNER) {
             // Owner's VPN also needs to handle restricted users
             mUserIntentReceiver = new BroadcastReceiver() {
                 @Override
                 public void onReceive(Context context, Intent intent) {
                     final String action = intent.getAction();
-                    final int userId = intent.getIntExtra(Intent.EXTRA_USER_HANDLE,
+                    final int userHandle = intent.getIntExtra(Intent.EXTRA_USER_HANDLE,
                             UserHandle.USER_NULL);
-                    if (userId == UserHandle.USER_NULL) return;
+                    if (userHandle == UserHandle.USER_NULL) return;
 
                     if (Intent.ACTION_USER_ADDED.equals(action)) {
-                        onUserAdded(userId);
+                        onUserAdded(userHandle);
                     } else if (Intent.ACTION_USER_REMOVED.equals(action)) {
-                        onUserRemoved(userId);
+                        onUserRemoved(userHandle);
                     }
                 }
             };
@@ -180,14 +175,6 @@
     }
 
     /**
-     * Set if this object is responsible for showing its own notifications. When
-     * {@code false}, notifications are handled externally by someone else.
-     */
-    public void setEnableNotifications(boolean enableNotif) {
-        mEnableNotif = enableNotif;
-    }
-
-    /**
      * Set if this object is responsible for watching for {@link NetworkInfo}
      * teardown. When {@code false}, teardown is handled externally by someone
      * else.
@@ -228,6 +215,20 @@
     public synchronized boolean prepare(String oldPackage, String newPackage) {
         // Return false if the package does not match.
         if (oldPackage != null && !oldPackage.equals(mPackage)) {
+            // The package doesn't match. If this VPN was not previously authorized, return false
+            // to force user authorization. Otherwise, revoke the VPN anyway.
+            if (!oldPackage.equals(VpnConfig.LEGACY_VPN) && isVpnUserPreConsented(oldPackage)) {
+                long token = Binder.clearCallingIdentity();
+                try {
+                    // This looks bizarre, but it is what ConfirmDialog in VpnDialogs is doing when
+                    // the user clicks through to allow the VPN to consent. So we are emulating the
+                    // action of the dialog without actually showing it.
+                    prepare(null, oldPackage);
+                } finally {
+                    Binder.restoreCallingIdentity(token);
+                }
+                return true;
+            }
             return false;
         }
 
@@ -240,11 +241,9 @@
         // Check if the caller is authorized.
         enforceControlPermission();
 
-        // Reset the interface and hide the notification.
+        // Reset the interface.
         if (mInterface != null) {
-            for (UidRange uidRange : mVpnUsers) {
-                hideNotification(uidRange.getStartUser());
-            }
+            mStatusIntent = null;
             agentDisconnect();
             jniReset(mInterface);
             mInterface = null;
@@ -277,7 +276,7 @@
 
         Log.i(TAG, "Switched from " + mPackage + " to " + newPackage);
         mPackage = newPackage;
-        mOwnerUID = getAppUid(newPackage);
+        mOwnerUID = getAppUid(newPackage, mUserHandle);
         token = Binder.clearCallingIdentity();
         try {
             mNetd.allowProtect(mOwnerUID);
@@ -287,18 +286,52 @@
             Binder.restoreCallingIdentity(token);
         }
         mConfig = null;
+
         updateState(DetailedState.IDLE, "prepare");
         return true;
     }
 
-    private int getAppUid(String app) {
-        if (app == VpnConfig.LEGACY_VPN) {
+    /**
+     * Set whether the current package has the ability to launch VPNs without user intervention.
+     */
+    public void setPackageAuthorization(boolean authorized) {
+        // Check if the caller is authorized.
+        enforceControlPermission();
+
+        if (mPackage == null || VpnConfig.LEGACY_VPN.equals(mPackage)) {
+            return;
+        }
+
+        long token = Binder.clearCallingIdentity();
+        try {
+            AppOpsManager appOps =
+                    (AppOpsManager) mContext.getSystemService(Context.APP_OPS_SERVICE);
+            appOps.setMode(AppOpsManager.OP_ACTIVATE_VPN, mOwnerUID, mPackage,
+                    authorized ? AppOpsManager.MODE_ALLOWED : AppOpsManager.MODE_IGNORED);
+        } catch (Exception e) {
+            Log.wtf(TAG, "Failed to set app ops for package " + mPackage, e);
+        } finally {
+            Binder.restoreCallingIdentity(token);
+        }
+    }
+
+    private boolean isVpnUserPreConsented(String packageName) {
+        AppOpsManager appOps =
+                (AppOpsManager) mContext.getSystemService(Context.APP_OPS_SERVICE);
+
+        // Verify that the caller matches the given package and has permission to activate VPNs.
+        return appOps.noteOpNoThrow(AppOpsManager.OP_ACTIVATE_VPN, Binder.getCallingUid(),
+                packageName) == AppOpsManager.MODE_ALLOWED;
+    }
+
+    private int getAppUid(String app, int userHandle) {
+        if (VpnConfig.LEGACY_VPN.equals(app)) {
             return Process.myUid();
         }
         PackageManager pm = mContext.getPackageManager();
         int result;
         try {
-            result = pm.getPackageUid(app, mUserId);
+            result = pm.getPackageUid(app, userHandle);
         } catch (NameNotFoundException e) {
             result = -1;
         }
@@ -355,9 +388,10 @@
         try {
             mNetworkAgent = new NetworkAgent(mLooper, mContext, NETWORKTYPE,
                     mNetworkInfo, mNetworkCapabilities, lp, 0, networkMisc) {
+                            @Override
                             public void unwanted() {
                                 // We are user controlled, not driven by NetworkRequest.
-                            };
+                            }
                         };
         } finally {
             Binder.restoreCallingIdentity(token);
@@ -370,9 +404,9 @@
             mNetworkAgent.blockAddressFamily(AF_INET6);
         }
 
-        addVpnUserLocked(mUserId);
+        addVpnUserLocked(mUserHandle);
         // If we are owner assign all Restricted Users to this VPN
-        if (mUserId == UserHandle.USER_OWNER) {
+        if (mUserHandle == UserHandle.USER_OWNER) {
             token = Binder.clearCallingIdentity();
             List<UserInfo> users;
             try {
@@ -429,13 +463,13 @@
         long token = Binder.clearCallingIdentity();
         try {
             // Restricted users are not allowed to create VPNs, they are tied to Owner
-            UserInfo user = mgr.getUserInfo(mUserId);
+            UserInfo user = mgr.getUserInfo(mUserHandle);
             if (user.isRestricted() || mgr.hasUserRestriction(UserManager.DISALLOW_CONFIG_VPN)) {
                 throw new SecurityException("Restricted users cannot establish VPNs");
             }
 
             ResolveInfo info = AppGlobals.getPackageManager().resolveService(intent,
-                                                                        null, 0, mUserId);
+                                                                        null, 0, mUserHandle);
             if (info == null) {
                 throw new SecurityException("Cannot find " + config.user);
             }
@@ -474,7 +508,7 @@
             }
             Connection connection = new Connection();
             if (!mContext.bindServiceAsUser(intent, connection, Context.BIND_AUTO_CREATE,
-                        new UserHandle(mUserId))) {
+                        new UserHandle(mUserHandle))) {
                 throw new IllegalStateException("Cannot bind " + config.user);
             }
 
@@ -532,72 +566,92 @@
         return mVpnUsers != null;
     }
 
+    // Note: Return type guarantees results are deduped and sorted, which callers require.
+    private SortedSet<Integer> getAppsUids(List<String> packageNames, int userHandle) {
+        SortedSet<Integer> uids = new TreeSet<Integer>();
+        for (String app : packageNames) {
+            int uid = getAppUid(app, userHandle);
+            if (uid != -1) uids.add(uid);
+        }
+        return uids;
+    }
+
     // Note: This function adds to mVpnUsers but does not publish list to NetworkAgent.
-    private void addVpnUserLocked(int user) {
+    private void addVpnUserLocked(int userHandle) {
         if (!isRunningLocked()) {
             throw new IllegalStateException("VPN is not active");
         }
 
-        // add the user
-        mVpnUsers.add(UidRange.createForUser(user));
-
-        // show the notification
-        if (!mPackage.equals(VpnConfig.LEGACY_VPN)) {
-            // Load everything for the user's notification
-            PackageManager pm = mContext.getPackageManager();
-            ApplicationInfo app = null;
-            final long token = Binder.clearCallingIdentity();
-            try {
-                app = AppGlobals.getPackageManager().getApplicationInfo(mPackage, 0, mUserId);
-            } catch (RemoteException e) {
-                throw new IllegalStateException("Invalid application");
-            } finally {
-                Binder.restoreCallingIdentity(token);
+        if (mConfig.allowedApplications != null) {
+            // Add ranges covering all UIDs for allowedApplications.
+            int start = -1, stop = -1;
+            for (int uid : getAppsUids(mConfig.allowedApplications, userHandle)) {
+                if (start == -1) {
+                    start = uid;
+                } else if (uid != stop + 1) {
+                    mVpnUsers.add(new UidRange(start, stop));
+                    start = uid;
+                }
+                stop = uid;
             }
-            String label = app.loadLabel(pm).toString();
-            // Load the icon and convert it into a bitmap.
-            Drawable icon = app.loadIcon(pm);
-            Bitmap bitmap = null;
-            if (icon.getIntrinsicWidth() > 0 && icon.getIntrinsicHeight() > 0) {
-                int width = mContext.getResources().getDimensionPixelSize(
-                        android.R.dimen.notification_large_icon_width);
-                int height = mContext.getResources().getDimensionPixelSize(
-                        android.R.dimen.notification_large_icon_height);
-                icon.setBounds(0, 0, width, height);
-                bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888);
-                Canvas c = new Canvas(bitmap);
-                icon.draw(c);
-                c.setBitmap(null);
+            if (start != -1) mVpnUsers.add(new UidRange(start, stop));
+        } else if (mConfig.disallowedApplications != null) {
+            // Add all ranges for user skipping UIDs for disallowedApplications.
+            final UidRange userRange = UidRange.createForUser(userHandle);
+            int start = userRange.start;
+            for (int uid : getAppsUids(mConfig.disallowedApplications, userHandle)) {
+                if (uid == start) {
+                    start++;
+                } else {
+                    mVpnUsers.add(new UidRange(start, uid - 1));
+                    start = uid + 1;
+                }
             }
-            showNotification(label, bitmap, user);
+            if (start <= userRange.stop) mVpnUsers.add(new UidRange(start, userRange.stop));
         } else {
-            showNotification(null, null, user);
+            // Add all UIDs for the user.
+            mVpnUsers.add(UidRange.createForUser(userHandle));
         }
+
+        prepareStatusIntent();
     }
 
-    private void removeVpnUserLocked(int user) {
-            if (!isRunningLocked()) {
-                throw new IllegalStateException("VPN is not active");
+    // Returns the subset of the full list of active UID ranges the VPN applies to (mVpnUsers) that
+    // apply to userHandle.
+    private List<UidRange> uidRangesForUser(int userHandle) {
+        final UidRange userRange = UidRange.createForUser(userHandle);
+        final List<UidRange> ranges = new ArrayList<UidRange>();
+        for (UidRange range : mVpnUsers) {
+            if (range.start >= userRange.start && range.stop <= userRange.stop) {
+                ranges.add(range);
             }
-            UidRange uidRange = UidRange.createForUser(user);
-            if (mNetworkAgent != null) {
-                mNetworkAgent.removeUidRanges(new UidRange[] { uidRange });
-            }
-            mVpnUsers.remove(uidRange);
-            hideNotification(user);
+        }
+        return ranges;
     }
 
-    private void onUserAdded(int userId) {
+    private void removeVpnUserLocked(int userHandle) {
+        if (!isRunningLocked()) {
+            throw new IllegalStateException("VPN is not active");
+        }
+        final List<UidRange> ranges = uidRangesForUser(userHandle);
+        if (mNetworkAgent != null) {
+            mNetworkAgent.removeUidRanges(ranges.toArray(new UidRange[ranges.size()]));
+        }
+        mVpnUsers.removeAll(ranges);
+        mStatusIntent = null;
+    }
+
+    private void onUserAdded(int userHandle) {
         // If the user is restricted tie them to the owner's VPN
         synchronized(Vpn.this) {
             UserManager mgr = UserManager.get(mContext);
-            UserInfo user = mgr.getUserInfo(userId);
+            UserInfo user = mgr.getUserInfo(userHandle);
             if (user.isRestricted()) {
                 try {
-                    addVpnUserLocked(userId);
+                    addVpnUserLocked(userHandle);
                     if (mNetworkAgent != null) {
-                        UidRange uidRange = UidRange.createForUser(userId);
-                        mNetworkAgent.addUidRanges(new UidRange[] { uidRange });
+                        final List<UidRange> ranges = uidRangesForUser(userHandle);
+                        mNetworkAgent.addUidRanges(ranges.toArray(new UidRange[ranges.size()]));
                     }
                 } catch (Exception e) {
                     Log.wtf(TAG, "Failed to add restricted user to owner", e);
@@ -606,14 +660,14 @@
         }
     }
 
-    private void onUserRemoved(int userId) {
+    private void onUserRemoved(int userHandle) {
         // clean up if restricted
         synchronized(Vpn.this) {
             UserManager mgr = UserManager.get(mContext);
-            UserInfo user = mgr.getUserInfo(userId);
+            UserInfo user = mgr.getUserInfo(userHandle);
             if (user.isRestricted()) {
                 try {
-                    removeVpnUserLocked(userId);
+                    removeVpnUserLocked(userHandle);
                 } catch (Exception e) {
                     Log.wtf(TAG, "Failed to remove restricted user to owner", e);
                 }
@@ -652,9 +706,7 @@
         public void interfaceRemoved(String interfaze) {
             synchronized (Vpn.this) {
                 if (interfaze.equals(mInterface) && jniCheck(interfaze) == 0) {
-                    for (UidRange uidRange : mVpnUsers) {
-                        hideNotification(uidRange.getStartUser());
-                    }
+                    mStatusIntent = null;
                     mVpnUsers = null;
                     mInterface = null;
                     if (mConnection != null) {
@@ -712,54 +764,15 @@
         }
     }
 
-    private void showNotification(String label, Bitmap icon, int user) {
-        if (!mEnableNotif) return;
+    private void prepareStatusIntent() {
         final long token = Binder.clearCallingIdentity();
         try {
             mStatusIntent = VpnConfig.getIntentForStatusPanel(mContext);
-
-            NotificationManager nm = (NotificationManager)
-                    mContext.getSystemService(Context.NOTIFICATION_SERVICE);
-
-            if (nm != null) {
-                String title = (label == null) ? mContext.getString(R.string.vpn_title) :
-                        mContext.getString(R.string.vpn_title_long, label);
-                String text = (mConfig.session == null) ? mContext.getString(R.string.vpn_text) :
-                        mContext.getString(R.string.vpn_text_long, mConfig.session);
-
-                Notification notification = new Notification.Builder(mContext)
-                        .setSmallIcon(R.drawable.vpn_connected)
-                        .setLargeIcon(icon)
-                        .setContentTitle(title)
-                        .setContentText(text)
-                        .setContentIntent(mStatusIntent)
-                        .setDefaults(0)
-                        .setOngoing(true)
-                        .build();
-                nm.notifyAsUser(null, R.drawable.vpn_connected, notification, new UserHandle(user));
-            }
         } finally {
             Binder.restoreCallingIdentity(token);
         }
     }
 
-    private void hideNotification(int user) {
-        if (!mEnableNotif) return;
-        mStatusIntent = null;
-
-        NotificationManager nm = (NotificationManager)
-                mContext.getSystemService(Context.NOTIFICATION_SERVICE);
-
-        if (nm != null) {
-            final long token = Binder.clearCallingIdentity();
-            try {
-                nm.cancelAsUser(null, R.drawable.vpn_connected, new UserHandle(user));
-            } finally {
-                Binder.restoreCallingIdentity(token);
-            }
-        }
-    }
-
     public synchronized boolean addAddress(String address, int prefixLength) {
         if (Binder.getCallingUid() != mOwnerUID || mInterface == null || mNetworkAgent == null) {
             return false;
@@ -829,7 +842,7 @@
             throw new IllegalStateException("KeyStore isn't unlocked");
         }
         UserManager mgr = UserManager.get(mContext);
-        UserInfo user = mgr.getUserInfo(mUserId);
+        UserInfo user = mgr.getUserInfo(mUserHandle);
         if (user.isRestricted() || mgr.hasUserRestriction(UserManager.DISALLOW_CONFIG_VPN)) {
             throw new SecurityException("Restricted users cannot establish VPNs");
         }
@@ -1261,6 +1274,7 @@
                 }
             } catch (Exception e) {
                 Log.i(TAG, "Aborting", e);
+                updateState(DetailedState.FAILED, e.getMessage());
                 exit();
             } finally {
                 // Kill the daemons if they fail to stop.
diff --git a/services/core/java/com/android/server/content/ContentService.java b/services/core/java/com/android/server/content/ContentService.java
index 64d3dc5..165148b 100644
--- a/services/core/java/com/android/server/content/ContentService.java
+++ b/services/core/java/com/android/server/content/ContentService.java
@@ -255,7 +255,7 @@
             for (int i=0; i<numCalls; i++) {
                 ObserverCall oc = calls.get(i);
                 try {
-                    oc.mObserver.onChange(oc.mSelfChange, uri);
+                    oc.mObserver.onChange(oc.mSelfChange, uri, userHandle);
                     if (Log.isLoggable(TAG, Log.VERBOSE)) {
                         Log.v(TAG, "Notified " + oc.mObserver + " of " + "update at " + uri);
                     }
diff --git a/services/core/java/com/android/server/content/SyncManager.java b/services/core/java/com/android/server/content/SyncManager.java
index 08d6fc9..9292d45 100644
--- a/services/core/java/com/android/server/content/SyncManager.java
+++ b/services/core/java/com/android/server/content/SyncManager.java
@@ -16,6 +16,7 @@
 
 package com.android.server.content;
 
+import android.Manifest;
 import android.accounts.Account;
 import android.accounts.AccountAndUser;
 import android.accounts.AccountManager;
@@ -46,6 +47,7 @@
 import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageInfo;
 import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.pm.ProviderInfo;
 import android.content.pm.RegisteredServicesCache;
 import android.content.pm.RegisteredServicesCacheListener;
@@ -152,7 +154,10 @@
      */
     private static final int DELAY_RETRY_SYNC_IN_PROGRESS_IN_SECONDS = 10;
 
-    private static final int INITIALIZATION_UNBIND_DELAY_MS = 5000;
+    /**
+     * How long to wait before considering an active sync to have timed-out, and cancelling it.
+     */
+    private static final long ACTIVE_SYNC_TIMEOUT_MILLIS = 30L * 60 * 1000;  // 30 mins.
 
     private static final String SYNC_WAKE_LOCK_PREFIX = "*sync*/";
     private static final String HANDLE_SYNC_ALARM_WAKE_LOCK = "SyncManagerHandleSyncAlarm";
@@ -474,7 +479,7 @@
             mContext.registerReceiverAsUser(mAccountsUpdatedReceiver,
                     UserHandle.ALL,
                     new IntentFilter(AccountManager.LOGIN_ACCOUNTS_CHANGED_ACTION),
-                    null, null);
+                    Manifest.permission.ACCOUNT_MANAGER, null);
         }
 
         // Pick a random second in a day to seed all periodic syncs
@@ -851,6 +856,31 @@
         mSyncHandler.sendMessage(msg);
     }
 
+    /**
+     * Post a delayed message to the handler that will result in the cancellation of the provided
+     * running sync's context.
+     */
+    private void postSyncExpiryMessage(ActiveSyncContext activeSyncContext) {
+        if (Log.isLoggable(TAG, Log.VERBOSE)) {
+            Log.v(TAG, "posting MESSAGE_SYNC_EXPIRED in " +
+                    (ACTIVE_SYNC_TIMEOUT_MILLIS/1000) + "s");
+        }
+        Message msg = mSyncHandler.obtainMessage();
+        msg.what = SyncHandler.MESSAGE_SYNC_EXPIRED;
+        msg.obj = activeSyncContext;
+        mSyncHandler.sendMessageDelayed(msg, ACTIVE_SYNC_TIMEOUT_MILLIS);
+    }
+
+    /**
+     * Remove any time-outs previously posted for the provided active sync.
+     */
+    private void removeSyncExpiryMessage(ActiveSyncContext activeSyncContext) {
+        if (Log.isLoggable(TAG, Log.VERBOSE)) {
+            Log.v(TAG, "removing all MESSAGE_SYNC_EXPIRED for " + activeSyncContext.toString());
+        }
+        mSyncHandler.removeMessages(SyncHandler.MESSAGE_SYNC_EXPIRED, activeSyncContext);
+    }
+
     class SyncHandlerMessagePayload {
         public final ActiveSyncContext activeSyncContext;
         public final SyncResult syncResult;
@@ -1902,6 +1932,8 @@
         private static final int MESSAGE_SERVICE_CONNECTED = 4;
         private static final int MESSAGE_SERVICE_DISCONNECTED = 5;
         private static final int MESSAGE_CANCEL = 6;
+        /** Posted delayed in order to expire syncs that are long-running. */
+        private static final int MESSAGE_SYNC_EXPIRED = 7;
 
         public final SyncNotificationInfo mSyncNotificationInfo = new SyncNotificationInfo();
         private Long mAlarmScheduleTime = null;
@@ -2000,10 +2032,21 @@
                 // to also take into account the periodic syncs.
                 earliestFuturePollTime = scheduleReadyPeriodicSyncs();
                 switch (msg.what) {
+                    case SyncHandler.MESSAGE_SYNC_EXPIRED:
+                        ActiveSyncContext expiredContext = (ActiveSyncContext) msg.obj;
+                        if (Log.isLoggable(TAG, Log.DEBUG)) {
+                            Log.d(TAG, "handleSyncHandlerMessage: MESSAGE_SYNC_EXPIRED: expiring "
+                                    + expiredContext);
+                        }
+                        cancelActiveSync(expiredContext.mSyncOperation.target,
+                                expiredContext.mSyncOperation.extras);
+                        nextPendingSyncTime = maybeStartNextSyncLocked();
+                        break;
+
                     case SyncHandler.MESSAGE_CANCEL: {
                         SyncStorageEngine.EndPoint payload = (SyncStorageEngine.EndPoint) msg.obj;
                         Bundle extras = msg.peekData();
-                        if (Log.isLoggable(TAG, Log.VERBOSE)) {
+                        if (Log.isLoggable(TAG, Log.DEBUG)) {
                             Log.d(TAG, "handleSyncHandlerMessage: MESSAGE_SERVICE_CANCEL: "
                                     + payload + " bundle: " + extras);
                         }
@@ -2653,6 +2696,13 @@
                     new ActiveSyncContext(op, insertStartSyncEvent(op), targetUid);
             activeSyncContext.mSyncInfo = mSyncStorageEngine.addActiveSync(activeSyncContext);
             mActiveSyncContexts.add(activeSyncContext);
+            if (!activeSyncContext.mSyncOperation.isInitialization() &&
+                    !activeSyncContext.mSyncOperation.isExpedited() &&
+                    !activeSyncContext.mSyncOperation.isManual() &&
+                    !activeSyncContext.mSyncOperation.isIgnoreSettings()) {
+                // Post message to expire this sync if it runs for too long.
+                postSyncExpiryMessage(activeSyncContext);
+            }
             if (Log.isLoggable(TAG, Log.VERBOSE)) {
                 Log.v(TAG, "dispatchSyncOperation: starting " + activeSyncContext);
             }
@@ -2757,9 +2807,7 @@
                 } else {
                     Log.d(TAG, "failed sync operation " + syncOperation + ", " + syncResult);
                     // the operation failed so increase the backoff time
-                    if (!syncResult.syncAlreadyInProgress) {
-                        increaseBackoffSetting(syncOperation);
-                    }
+                    increaseBackoffSetting(syncOperation);
                     // reschedule the sync if so indicated by the syncResult
                     maybeRescheduleSync(syncResult, syncOperation);
                     historyMessage = ContentResolver.syncErrorToString(
@@ -2768,7 +2816,6 @@
                     downstreamActivity = 0;
                     upstreamActivity = 0;
                 }
-
                 setDelayUntilTime(syncOperation, syncResult.delayUntil);
             } else {
                 if (isLoggable) {
@@ -2794,7 +2841,6 @@
 
             stopSyncEvent(activeSyncContext.mHistoryRowId, syncOperation, historyMessage,
                     upstreamActivity, downstreamActivity, elapsedTime);
-
             // Check for full-resync and schedule it after closing off the last sync.
             if (info.target_provider) {
                 if (syncResult != null && syncResult.tooManyDeletions) {
@@ -2833,6 +2879,7 @@
             mActiveSyncContexts.remove(activeSyncContext);
             mSyncStorageEngine.removeActiveSync(activeSyncContext.mSyncInfo,
                     activeSyncContext.mSyncOperation.target.userId);
+            removeSyncExpiryMessage(activeSyncContext);
         }
 
         /**
@@ -3053,24 +3100,28 @@
                 return;
             }
 
+            UserHandle user = new UserHandle(userId);
             final PendingIntent pendingIntent = PendingIntent
                     .getActivityAsUser(mContext, 0, clickIntent,
-                            PendingIntent.FLAG_CANCEL_CURRENT, null, new UserHandle(userId));
+                            PendingIntent.FLAG_CANCEL_CURRENT, null, user);
 
             CharSequence tooManyDeletesDescFormat = mContext.getResources().getText(
                     R.string.contentServiceTooManyDeletesNotificationDesc);
 
+            Context contextForUser = getContextForUser(user);
             Notification notification =
                 new Notification(R.drawable.stat_notify_sync_error,
                         mContext.getString(R.string.contentServiceSync),
                         System.currentTimeMillis());
-            notification.setLatestEventInfo(mContext,
-                    mContext.getString(R.string.contentServiceSyncNotificationTitle),
+            notification.color = contextForUser.getResources().getColor(
+                    com.android.internal.R.color.system_notification_accent_color);
+            notification.setLatestEventInfo(contextForUser,
+                    contextForUser.getString(R.string.contentServiceSyncNotificationTitle),
                     String.format(tooManyDeletesDescFormat.toString(), authorityName),
                     pendingIntent);
             notification.flags |= Notification.FLAG_ONGOING_EVENT;
             mNotificationMgr.notifyAsUser(null, account.hashCode() ^ authority.hashCode(),
-                    notification, new UserHandle(userId));
+                    notification, user);
         }
 
         /**
@@ -3258,4 +3309,13 @@
             return mTable.size();
         }
     }
+
+    private Context getContextForUser(UserHandle user) {
+        try {
+            return mContext.createPackageContextAsUser(mContext.getPackageName(), 0, user);
+        } catch (NameNotFoundException e) {
+            // Default to mContext, not finding the package system is running as is unlikely.
+            return mContext;
+        }
+    }
 }
diff --git a/services/core/java/com/android/server/content/SyncOperation.java b/services/core/java/com/android/server/content/SyncOperation.java
index 9a4abce..35827cc 100644
--- a/services/core/java/com/android/server/content/SyncOperation.java
+++ b/services/core/java/com/android/server/content/SyncOperation.java
@@ -273,6 +273,14 @@
         return extras.getBoolean(ContentResolver.SYNC_EXTRAS_DISALLOW_METERED, false);
     }
 
+    public boolean isManual() {
+        return extras.getBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, false);
+    }
+
+    public boolean isIgnoreSettings() {
+        return extras.getBoolean(ContentResolver.SYNC_EXTRAS_IGNORE_SETTINGS, false);
+    }
+
     /** Changed in V3. */
     public static String toKey(SyncStorageEngine.EndPoint info, Bundle extras) {
         StringBuilder sb = new StringBuilder();
diff --git a/services/core/java/com/android/server/display/DisplayManagerService.java b/services/core/java/com/android/server/display/DisplayManagerService.java
index e31f177..e609701 100644
--- a/services/core/java/com/android/server/display/DisplayManagerService.java
+++ b/services/core/java/com/android/server/display/DisplayManagerService.java
@@ -29,7 +29,7 @@
 import android.hardware.display.DisplayManagerInternal.DisplayTransactionListener;
 import android.hardware.display.IDisplayManager;
 import android.hardware.display.IDisplayManagerCallback;
-import android.hardware.display.IVirtualDisplayCallbacks;
+import android.hardware.display.IVirtualDisplayCallback;
 import android.hardware.display.WifiDisplayStatus;
 import android.hardware.input.InputManagerInternal;
 import android.media.projection.IMediaProjection;
@@ -491,7 +491,7 @@
         }
     }
 
-    private int createVirtualDisplayInternal(IVirtualDisplayCallbacks callbacks,
+    private int createVirtualDisplayInternal(IVirtualDisplayCallback callback,
             IMediaProjection projection, int callingUid, String packageName,
             String name, int width, int height, int densityDpi, Surface surface, int flags) {
         synchronized (mSyncRoot) {
@@ -502,7 +502,7 @@
             }
 
             DisplayDevice device = mVirtualDisplayAdapter.createVirtualDisplayLocked(
-                    callbacks, projection, callingUid, packageName,
+                    callback, projection, callingUid, packageName,
                     name, width, height, densityDpi, surface, flags);
             if (device == null) {
                 return -1;
@@ -517,7 +517,7 @@
             // Something weird happened and the logical display was not created.
             Slog.w(TAG, "Rejecting request to create virtual display "
                     + "because the logical display was not created.");
-            mVirtualDisplayAdapter.releaseVirtualDisplayLocked(callbacks.asBinder());
+            mVirtualDisplayAdapter.releaseVirtualDisplayLocked(callback.asBinder());
             handleDisplayDeviceRemovedLocked(device);
         }
         return -1;
@@ -1251,14 +1251,14 @@
         }
 
         @Override // Binder call
-        public int createVirtualDisplay(IVirtualDisplayCallbacks callbacks,
+        public int createVirtualDisplay(IVirtualDisplayCallback callback,
                 IMediaProjection projection, String packageName, String name,
                 int width, int height, int densityDpi, Surface surface, int flags) {
             final int callingUid = Binder.getCallingUid();
             if (!validatePackageName(callingUid, packageName)) {
                 throw new SecurityException("packageName must match the calling uid");
             }
-            if (callbacks == null) {
+            if (callback == null) {
                 throw new IllegalArgumentException("appToken must not be null");
             }
             if (TextUtils.isEmpty(name)) {
@@ -1306,7 +1306,7 @@
 
             final long token = Binder.clearCallingIdentity();
             try {
-                return createVirtualDisplayInternal(callbacks, projection, callingUid,
+                return createVirtualDisplayInternal(callback, projection, callingUid,
                         packageName, name, width, height, densityDpi, surface, flags);
             } finally {
                 Binder.restoreCallingIdentity(token);
@@ -1314,31 +1314,31 @@
         }
 
         @Override // Binder call
-        public void resizeVirtualDisplay(IVirtualDisplayCallbacks callbacks,
+        public void resizeVirtualDisplay(IVirtualDisplayCallback callback,
                 int width, int height, int densityDpi) {
             final long token = Binder.clearCallingIdentity();
             try {
-                resizeVirtualDisplayInternal(callbacks.asBinder(), width, height, densityDpi);
+                resizeVirtualDisplayInternal(callback.asBinder(), width, height, densityDpi);
             } finally {
                 Binder.restoreCallingIdentity(token);
             }
         }
 
         @Override // Binder call
-        public void setVirtualDisplaySurface(IVirtualDisplayCallbacks callbacks, Surface surface) {
+        public void setVirtualDisplaySurface(IVirtualDisplayCallback callback, Surface surface) {
             final long token = Binder.clearCallingIdentity();
             try {
-                setVirtualDisplaySurfaceInternal(callbacks.asBinder(), surface);
+                setVirtualDisplaySurfaceInternal(callback.asBinder(), surface);
             } finally {
                 Binder.restoreCallingIdentity(token);
             }
         }
 
         @Override // Binder call
-        public void releaseVirtualDisplay(IVirtualDisplayCallbacks callbacks) {
+        public void releaseVirtualDisplay(IVirtualDisplayCallback callback) {
             final long token = Binder.clearCallingIdentity();
             try {
-                releaseVirtualDisplayInternal(callbacks.asBinder());
+                releaseVirtualDisplayInternal(callback.asBinder());
             } finally {
                 Binder.restoreCallingIdentity(token);
             }
diff --git a/services/core/java/com/android/server/display/DisplayPowerController.java b/services/core/java/com/android/server/display/DisplayPowerController.java
index 46cb6c3..b4009ca 100644
--- a/services/core/java/com/android/server/display/DisplayPowerController.java
+++ b/services/core/java/com/android/server/display/DisplayPowerController.java
@@ -87,7 +87,7 @@
     private static final int SCREEN_DIM_MINIMUM_REDUCTION = 10;
 
     private static final int COLOR_FADE_ON_ANIMATION_DURATION_MILLIS = 250;
-    private static final int COLOR_FADE_OFF_ANIMATION_DURATION_MILLIS = 600;
+    private static final int COLOR_FADE_OFF_ANIMATION_DURATION_MILLIS = 400;
 
     private static final int MSG_UPDATE_POWER_STATE = 1;
     private static final int MSG_PROXIMITY_SENSOR_DEBOUNCED = 2;
@@ -139,6 +139,9 @@
     // The dim screen brightness.
     private final int mScreenBrightnessDimConfig;
 
+    // The minimum screen brightness to use in a very dark room.
+    private final int mScreenBrightnessDarkConfig;
+
     // The minimum allowed brightness.
     private final int mScreenBrightnessRangeMinimum;
 
@@ -247,6 +250,8 @@
         mContext = context;
 
         final Resources resources = context.getResources();
+        final int screenBrightnessSettingMinimum = clampAbsoluteBrightness(resources.getInteger(
+                com.android.internal.R.integer.config_screenBrightnessSettingMinimum));
 
         mScreenBrightnessDozeConfig = clampAbsoluteBrightness(resources.getInteger(
                 com.android.internal.R.integer.config_screenBrightnessDoze));
@@ -254,9 +259,23 @@
         mScreenBrightnessDimConfig = clampAbsoluteBrightness(resources.getInteger(
                 com.android.internal.R.integer.config_screenBrightnessDim));
 
-        int screenBrightnessRangeMinimum = clampAbsoluteBrightness(Math.min(resources.getInteger(
-                com.android.internal.R.integer.config_screenBrightnessSettingMinimum),
-                mScreenBrightnessDimConfig));
+        mScreenBrightnessDarkConfig = clampAbsoluteBrightness(resources.getInteger(
+                com.android.internal.R.integer.config_screenBrightnessDark));
+        if (mScreenBrightnessDarkConfig > mScreenBrightnessDimConfig) {
+            Slog.w(TAG, "Expected config_screenBrightnessDark ("
+                    + mScreenBrightnessDarkConfig + ") to be less than or equal to "
+                    + "config_screenBrightnessDim (" + mScreenBrightnessDimConfig + ").");
+        }
+        if (mScreenBrightnessDarkConfig > mScreenBrightnessDimConfig) {
+            Slog.w(TAG, "Expected config_screenBrightnessDark ("
+                    + mScreenBrightnessDarkConfig + ") to be less than or equal to "
+                    + "config_screenBrightnessSettingMinimum ("
+                    + screenBrightnessSettingMinimum + ").");
+        }
+
+        int screenBrightnessRangeMinimum = Math.min(Math.min(
+                screenBrightnessSettingMinimum, mScreenBrightnessDimConfig),
+                mScreenBrightnessDarkConfig);
 
         mScreenBrightnessRangeMaximum = PowerManager.BRIGHTNESS_ON;
 
@@ -280,8 +299,15 @@
                         + "Auto-brightness will be disabled.");
                 mUseSoftwareAutoBrightnessConfig = false;
             } else {
-                if (screenBrightness[0] < screenBrightnessRangeMinimum) {
-                    screenBrightnessRangeMinimum = clampAbsoluteBrightness(screenBrightness[0]);
+                int bottom = clampAbsoluteBrightness(screenBrightness[0]);
+                if (mScreenBrightnessDarkConfig > bottom) {
+                    Slog.w(TAG, "config_screenBrightnessDark (" + mScreenBrightnessDarkConfig
+                            + ") should be less than or equal to the first value of "
+                            + "config_autoBrightnessLcdBacklightValues ("
+                            + bottom + ").");
+                }
+                if (bottom < screenBrightnessRangeMinimum) {
+                    screenBrightnessRangeMinimum = bottom;
                 }
                 mAutomaticBrightnessController = new AutomaticBrightnessController(this,
                         handler.getLooper(), sensorManager, screenAutoBrightnessSpline,
@@ -471,9 +497,11 @@
         // We might override this below based on other factors.
         int state;
         int brightness = PowerManager.BRIGHTNESS_DEFAULT;
+        boolean performScreenOffTransition = false;
         switch (mPowerRequest.policy) {
             case DisplayPowerRequest.POLICY_OFF:
                 state = Display.STATE_OFF;
+                performScreenOffTransition = true;
                 break;
             case DisplayPowerRequest.POLICY_DOZE:
                 if (mPowerRequest.dozeScreenState != Display.STATE_UNKNOWN) {
@@ -489,6 +517,7 @@
                 state = Display.STATE_ON;
                 break;
         }
+        assert(state != Display.STATE_UNKNOWN);
 
         // Apply the proximity sensor.
         if (mProximitySensor != null) {
@@ -665,7 +694,7 @@
             // Wait for previous on animation to complete beforehand.
             unblockScreenOn();
             if (!mColorFadeOnAnimator.isStarted()) {
-                if (mPowerRequest.policy == DisplayPowerRequest.POLICY_OFF) {
+                if (performScreenOffTransition) {
                     // Perform screen off animation.
                     if (!mColorFadeOffAnimator.isStarted()) {
                         if (mPowerState.getColorFadeLevel() == 0.0f) {
@@ -905,10 +934,11 @@
         pw.println("Display Power Controller Configuration:");
         pw.println("  mScreenBrightnessDozeConfig=" + mScreenBrightnessDozeConfig);
         pw.println("  mScreenBrightnessDimConfig=" + mScreenBrightnessDimConfig);
+        pw.println("  mScreenBrightnessDarkConfig=" + mScreenBrightnessDarkConfig);
         pw.println("  mScreenBrightnessRangeMinimum=" + mScreenBrightnessRangeMinimum);
         pw.println("  mScreenBrightnessRangeMaximum=" + mScreenBrightnessRangeMaximum);
-        pw.println("  mUseSoftwareAutoBrightnessConfig="
-                + mUseSoftwareAutoBrightnessConfig);
+        pw.println("  mUseSoftwareAutoBrightnessConfig=" + mUseSoftwareAutoBrightnessConfig);
+        pw.println("  mColorFadeFadesConfig=" + mColorFadeFadesConfig);
 
         mHandler.runWithScissors(new Runnable() {
             @Override
@@ -982,7 +1012,7 @@
                 y[i] = normalizeAbsoluteBrightness(brightness[i]);
             }
 
-            Spline spline = Spline.createMonotoneCubicSpline(x, y);
+            Spline spline = Spline.createSpline(x, y);
             if (DEBUG) {
                 Slog.d(TAG, "Auto-brightness spline: " + spline);
                 for (float v = 1f; v < lux[lux.length - 1] * 1.25f; v *= 1.25f) {
diff --git a/services/core/java/com/android/server/display/VirtualDisplayAdapter.java b/services/core/java/com/android/server/display/VirtualDisplayAdapter.java
index e39f0b1..a6a9a89 100644
--- a/services/core/java/com/android/server/display/VirtualDisplayAdapter.java
+++ b/services/core/java/com/android/server/display/VirtualDisplayAdapter.java
@@ -18,7 +18,7 @@
 
 import android.content.Context;
 import android.hardware.display.DisplayManager;
-import android.hardware.display.IVirtualDisplayCallbacks;
+import android.hardware.display.IVirtualDisplayCallback;
 import android.media.projection.IMediaProjection;
 import android.media.projection.IMediaProjectionCallback;
 import android.os.Handler;
@@ -55,21 +55,21 @@
         mHandler = handler;
     }
 
-    public DisplayDevice createVirtualDisplayLocked(IVirtualDisplayCallbacks callbacks,
+    public DisplayDevice createVirtualDisplayLocked(IVirtualDisplayCallback callback,
             IMediaProjection projection, int ownerUid, String ownerPackageName,
             String name, int width, int height, int densityDpi, Surface surface, int flags) {
         boolean secure = (flags & DisplayManager.VIRTUAL_DISPLAY_FLAG_SECURE) != 0;
-        IBinder appToken = callbacks.asBinder();
+        IBinder appToken = callback.asBinder();
         IBinder displayToken = SurfaceControl.createDisplay(name, secure);
         VirtualDisplayDevice device = new VirtualDisplayDevice(displayToken, appToken,
                 ownerUid, ownerPackageName, name, width, height, densityDpi, surface, flags,
-                new Callbacks(callbacks, mHandler));
+                new Callback(callback, mHandler));
 
         mVirtualDisplayDevices.put(appToken, device);
 
         try {
             if (projection != null) {
-                projection.addCallback(new MediaProjectionCallback(appToken));
+                projection.registerCallback(new MediaProjectionCallback(appToken));
             }
             appToken.linkToDeath(device, 0);
         } catch (RemoteException ex) {
@@ -139,7 +139,7 @@
         final String mOwnerPackageName;
         final String mName;
         private final int mFlags;
-        private final Callbacks mCallbacks;
+        private final Callback mCallback;
 
         private int mWidth;
         private int mHeight;
@@ -153,7 +153,7 @@
         public VirtualDisplayDevice(IBinder displayToken, IBinder appToken,
                 int ownerUid, String ownerPackageName,
                 String name, int width, int height, int densityDpi, Surface surface, int flags,
-                Callbacks callbacks) {
+                Callback callback) {
             super(VirtualDisplayAdapter.this, displayToken);
             mAppToken = appToken;
             mOwnerUid = ownerUid;
@@ -164,7 +164,7 @@
             mDensityDpi = densityDpi;
             mSurface = surface;
             mFlags = flags;
-            mCallbacks = callbacks;
+            mCallback = callback;
             mDisplayState = Display.STATE_UNKNOWN;
             mPendingChanges |= PENDING_SURFACE_CHANGE;
         }
@@ -184,7 +184,7 @@
                 mSurface = null;
             }
             SurfaceControl.destroyDisplay(getDisplayTokenLocked());
-            mCallbacks.dispatchDisplayStopped();
+            mCallback.dispatchDisplayStopped();
         }
 
         @Override
@@ -192,9 +192,9 @@
             if (state != mDisplayState) {
                 mDisplayState = state;
                 if (state == Display.STATE_OFF) {
-                    mCallbacks.dispatchDisplayPaused();
+                    mCallback.dispatchDisplayPaused();
                 } else {
-                    mCallbacks.dispatchDisplayResumed();
+                    mCallback.dispatchDisplayResumed();
                 }
             }
         }
@@ -287,16 +287,16 @@
         }
     }
 
-    private static class Callbacks extends Handler {
+    private static class Callback extends Handler {
         private static final int MSG_ON_DISPLAY_PAUSED = 0;
         private static final int MSG_ON_DISPLAY_RESUMED = 1;
         private static final int MSG_ON_DISPLAY_STOPPED = 2;
 
-        private final IVirtualDisplayCallbacks mCallbacks;
+        private final IVirtualDisplayCallback mCallback;
 
-        public Callbacks(IVirtualDisplayCallbacks callbacks, Handler handler) {
+        public Callback(IVirtualDisplayCallback callback, Handler handler) {
             super(handler.getLooper());
-            mCallbacks = callbacks;
+            mCallback = callback;
         }
 
         @Override
@@ -304,13 +304,13 @@
             try {
                 switch (msg.what) {
                     case MSG_ON_DISPLAY_PAUSED:
-                        mCallbacks.onDisplayPaused();
+                        mCallback.onPaused();
                         break;
                     case MSG_ON_DISPLAY_RESUMED:
-                        mCallbacks.onDisplayResumed();
+                        mCallback.onResumed();
                         break;
                     case MSG_ON_DISPLAY_STOPPED:
-                        mCallbacks.onDisplayStopped();
+                        mCallback.onStopped();
                         break;
                 }
             } catch (RemoteException e) {
diff --git a/services/core/java/com/android/server/display/WifiDisplayAdapter.java b/services/core/java/com/android/server/display/WifiDisplayAdapter.java
index a05bf2c..9d008b9 100644
--- a/services/core/java/com/android/server/display/WifiDisplayAdapter.java
+++ b/services/core/java/com/android/server/display/WifiDisplayAdapter.java
@@ -502,6 +502,8 @@
                         .addAction(android.R.drawable.ic_menu_close_clear_cancel,
                                 r.getString(R.string.wifi_display_notification_disconnect),
                                 mDisconnectPendingIntent)
+                        .setColor(r.getColor(
+                                com.android.internal.R.color.system_notification_accent_color))
                         .build();
             } else {
                 notification = new Notification.Builder(context)
@@ -516,6 +518,8 @@
                         .addAction(android.R.drawable.ic_menu_close_clear_cancel,
                                 r.getString(R.string.wifi_display_notification_disconnect),
                                 mDisconnectPendingIntent)
+                        .setColor(r.getColor(
+                                com.android.internal.R.color.system_notification_accent_color))
                         .build();
             }
             mNotificationManager.notifyAsUser(null,
diff --git a/services/core/java/com/android/server/hdmi/Constants.java b/services/core/java/com/android/server/hdmi/Constants.java
index 4b812cf..b0a3a66 100644
--- a/services/core/java/com/android/server/hdmi/Constants.java
+++ b/services/core/java/com/android/server/hdmi/Constants.java
@@ -159,6 +159,8 @@
     static final int TRUE = 1;
     static final int FALSE = 0;
 
+    // Internal abort error code. It's the same as success.
+    static final int ABORT_NO_ERROR = -1;
     // Constants related to operands of HDMI CEC commands.
     // Refer to CEC Table 29 in HDMI Spec v1.4b.
     // [Abort Reason]
@@ -210,8 +212,13 @@
     //       in config.xml to allow customization.
     static final int IRT_MS = 300;
 
-    static final String PROPERTY_PREFERRED_ADDRESS_PLAYBACK = "hdmi_cec.prefaddr.playback";
-    static final String PROPERTY_PREFERRED_ADDRESS_TV = "hdmi_cec.prefaddr.tv";
+    static final String PROPERTY_PREFERRED_ADDRESS_PLAYBACK = "persist.sys.hdmi.addr.playback";
+    static final String PROPERTY_PREFERRED_ADDRESS_TV = "persist.sys.hdmi.addr.tv";
+
+    // Property name for the local device configurations.
+    // TODO(OEM): OEM should provide this property, and the value is the comma separated integer
+    //     values which denotes the device type in HDMI Spec 1.4.
+    static final String PROPERTY_DEVICE_TYPE = "ro.hdmi.device_type";
 
     static final int RECORDING_TYPE_DIGITAL_RF = 1;
     static final int RECORDING_TYPE_ANALOGUE_RF = 2;
@@ -248,42 +255,5 @@
     static final int DISABLED = 0;
     static final int ENABLED = 1;
 
-    // --------------------------------------------------
-    // MHL sub command message types.
-    static final int MHL_MSG_MSGE  = 0x02;
-    static final int MHL_MSG_RCP   = 0x10;
-    static final int MHL_MSG_RCPK  = 0x11;
-    static final int MHL_MSG_RCPE  = 0x12;
-    static final int MHL_MSG_RAP   = 0x20;
-    static final int MHL_MSG_RAPK  = 0x21;
-
-    // MHL RAP messages.
-    static final int MHL_RAP_ACTION_POLL = 0x00;
-    static final int MHL_RAP_ACTION_CONTENT_ON = 0x10;
-    static final int MHL_RAP_ACTION_CONTENT_OFF = 0x11;
-
-    // MHL RAPK messages.
-    static final int MHL_RAPK_NO_ERROR = 0x00;
-    static final int MHL_RAPK_UNRECOGNIZED_ACTION = 0x01;
-    static final int MHL_RAPK_UNSUPPORTED_ACTION = 0x02;
-    static final int MHL_RAPK_RESPONDER_BUSY = 0x03;
-
-    static final int MHL_INVALID_ADOPTER_ID = -1;
-    static final int MHL_INVALID_DEVICE_ID = -1;
-
-    static final int MHL_CBUS_MODE_OCBUS = 1;
-    static final int MHL_CBUS_MODE_ECBUS_S = 2;
-    static final int MHL_CBUS_MODE_ECBUS_D = 3;
-
-    // Property name for the local device configurations.
-    // TODO(OEM): OEM should provide this property, and the value is the comma separated integer
-    //     values which denotes the device type in HDMI Spec 1.4.
-    static final String PROPERTY_DEVICE_TYPE = "ro.hdmi.device_type";
-
-    // MHL RCPE messages
-    static final int MHL_RCPE_NO_ERROR = 0x00;
-    static final int MHL_RCPE_INEFFECTIVE_KEYCODE = 0x01;
-    static final int MHL_RCPE_RESPONDER_BUSY = 0x02;
-
     private Constants() { /* cannot be instantiated */ }
 }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecController.java b/services/core/java/com/android/server/hdmi/HdmiCecController.java
index cf06ca8..0e8788a 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecController.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecController.java
@@ -23,6 +23,7 @@
 import android.util.Slog;
 import android.util.SparseArray;
 
+import com.android.internal.util.IndentingPrintWriter;
 import com.android.internal.util.Predicate;
 import com.android.server.hdmi.HdmiAnnotations.IoThreadOnly;
 import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly;
@@ -31,6 +32,7 @@
 import libcore.util.EmptyArray;
 
 import java.util.ArrayList;
+import java.util.LinkedList;
 import java.util.List;
 
 /**
@@ -202,6 +204,8 @@
         }
 
         final int assignedAddress = logicalAddress;
+        HdmiLogger.debug("New logical address for device [%d]: [preferred:%d, assigned:%d]",
+                        deviceType, preferredAddress, assignedAddress);
         if (callback != null) {
             runOnServiceThread(new Runnable() {
                 @Override
@@ -364,7 +368,8 @@
 
         // Extract polling candidates. No need to poll against local devices.
         List<Integer> pollingCandidates = pickPollCandidates(pickStrategy);
-        runDevicePolling(sourceAddress, pollingCandidates, retryCount, callback);
+        ArrayList<Integer> allocated = new ArrayList<>();
+        runDevicePolling(sourceAddress, pollingCandidates, retryCount, callback, allocated);
     }
 
     /**
@@ -392,7 +397,7 @@
         }
 
         int iterationStrategy = pickStrategy & Constants.POLL_ITERATION_STRATEGY_MASK;
-        ArrayList<Integer> pollingCandidates = new ArrayList<>();
+        LinkedList<Integer> pollingCandidates = new LinkedList<>();
         switch (iterationStrategy) {
             case Constants.POLL_ITERATION_IN_ORDER:
                 for (int i = Constants.ADDR_TV; i <= Constants.ADDR_SPECIFIC_USE; ++i) {
@@ -427,25 +432,32 @@
     @ServiceThreadOnly
     private void runDevicePolling(final int sourceAddress,
             final List<Integer> candidates, final int retryCount,
-            final DevicePollingCallback callback) {
+            final DevicePollingCallback callback, final List<Integer> allocated) {
         assertRunOnServiceThread();
+        if (candidates.isEmpty()) {
+            if (callback != null) {
+                HdmiLogger.debug("[P]:AllocatedAddress=%s", allocated.toString());
+                callback.onPollingFinished(allocated);
+            }
+            return;
+        }
+
+        final Integer candidate = candidates.remove(0);
+        // Proceed polling action for the next address once polling action for the
+        // previous address is done.
         runOnIoThread(new Runnable() {
             @Override
             public void run() {
-                final ArrayList<Integer> allocated = new ArrayList<>();
-                for (Integer address : candidates) {
-                    if (sendPollMessage(sourceAddress, address, retryCount)) {
-                        allocated.add(address);
+                if (sendPollMessage(sourceAddress, candidate, retryCount)) {
+                    allocated.add(candidate);
+                }
+                runOnServiceThread(new Runnable() {
+                    @Override
+                    public void run() {
+                        runDevicePolling(sourceAddress, candidates, retryCount, callback,
+                                allocated);
                     }
-                }
-                if (callback != null) {
-                    runOnServiceThread(new Runnable() {
-                        @Override
-                        public void run() {
-                            callback.onPollingFinished(allocated);
-                        }
-                    });
-                }
+                });
             }
         });
     }
@@ -539,6 +551,7 @@
         runOnIoThread(new Runnable() {
             @Override
             public void run() {
+                HdmiLogger.debug("[S]:" + cecMessage);
                 byte[] body = buildBody(cecMessage.getOpcode(), cecMessage.getParams());
                 int i = 0;
                 int errorCode = Constants.SEND_RESULT_SUCCESS;
@@ -572,7 +585,9 @@
     @ServiceThreadOnly
     private void handleIncomingCecCommand(int srcAddress, int dstAddress, byte[] body) {
         assertRunOnServiceThread();
-        onReceiveCommand(HdmiCecMessageBuilder.of(srcAddress, dstAddress, body));
+        HdmiCecMessage command = HdmiCecMessageBuilder.of(srcAddress, dstAddress, body);
+        HdmiLogger.debug("[R]:" + command);
+        onReceiveCommand(command);
     }
 
     /**
@@ -581,9 +596,19 @@
     @ServiceThreadOnly
     private void handleHotplug(int port, boolean connected) {
         assertRunOnServiceThread();
+        HdmiLogger.debug("Hotplug event:[port:%d, connected:%b]", port, connected);
         mService.onHotplug(port, connected);
     }
 
+    void dump(final IndentingPrintWriter pw) {
+        for (int i = 0; i < mLocalDevices.size(); ++i) {
+            pw.println("HdmiCecLocalDevice #" + i + ":");
+            pw.increaseIndent();
+            mLocalDevices.valueAt(i).dump(pw);
+            pw.decreaseIndent();
+        }
+    }
+
     private static native long nativeInit(HdmiCecController handler, MessageQueue messageQueue);
     private static native int nativeSendCecCommand(long controllerPtr, int srcAddress,
             int dstAddress, byte[] body);
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecFeatureAction.java b/services/core/java/com/android/server/hdmi/HdmiCecFeatureAction.java
index 26d2cde..b2300a6 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecFeatureAction.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecFeatureAction.java
@@ -261,10 +261,7 @@
     }
 
     protected final void sendUserControlPressedAndReleased(int targetAddress, int uiCommand) {
-        sendCommand(HdmiCecMessageBuilder.buildUserControlPressed(
-                getSourceAddress(), targetAddress, uiCommand));
-        sendCommand(HdmiCecMessageBuilder.buildUserControlReleased(
-                getSourceAddress(), targetAddress));
+        mSource.sendUserControlPressedAndReleased(targetAddress, uiCommand);
     }
 
     protected final void addOnFinishedCallback(HdmiCecFeatureAction action, Runnable runnable) {
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecKeycode.java b/services/core/java/com/android/server/hdmi/HdmiCecKeycode.java
index 46b2b3e..61c9424 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecKeycode.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecKeycode.java
@@ -155,7 +155,7 @@
     }
 
     /**
-     * A mapping between andorid and cec keycode.
+     * A mapping between Android and CEC keycode.
      *
      * <p>Normal implementation of this looks like
      * <pre>
@@ -174,43 +174,28 @@
     private static class KeycodeEntry {
         private final int mAndroidKeycode;
         private final int mCecKeycode;
-        private final int mParam;
         private final boolean mIsRepeatable;
 
-        private KeycodeEntry(int androidKeycode, int cecKeycode, int param, boolean isRepeatable) {
+        private KeycodeEntry(int androidKeycode, int cecKeycode, boolean isRepeatable) {
             mAndroidKeycode = androidKeycode;
             mCecKeycode = cecKeycode;
-            mParam = param;
             mIsRepeatable = isRepeatable;
         }
 
         private KeycodeEntry(int androidKeycode, int cecKeycode) {
-            this(androidKeycode, cecKeycode, NO_PARAM, true);
+            this(androidKeycode, cecKeycode, true);
         }
 
-        private KeycodeEntry(int androidKeycode, int cecKeycode, boolean isRepeatable) {
-            this(androidKeycode, cecKeycode, NO_PARAM, isRepeatable);
-        }
-
-        private byte[] toCecKeycodeIfMatched(int androidKeycode) {
+        private int toCecKeycodeIfMatched(int androidKeycode) {
             if (mAndroidKeycode == androidKeycode) {
-                if (mParam == NO_PARAM) {
-                    return new byte[] {
-                        (byte) (mCecKeycode & 0xFF)
-                    };
-                } else {
-                    return new byte[] {
-                        (byte) (mCecKeycode & 0xFF),
-                        (byte) (mParam & 0xFF)
-                    };
-                }
+                return mCecKeycode;
             } else {
-                return null;
+                return UNSUPPORTED_KEYCODE;
             }
         }
 
-        private int toAndroidKeycodeIfMatched(int cecKeycode, int param) {
-            if (cecKeycode == mCecKeycode && mParam == param) {
+        private int toAndroidKeycodeIfMatched(int cecKeycode) {
+            if (cecKeycode == mCecKeycode) {
                 return mAndroidKeycode;
             } else {
                 return UNSUPPORTED_KEYCODE;
@@ -365,29 +350,28 @@
      * Translate Android keycode to Hdmi Cec keycode.
      *
      * @param keycode Android keycode. For details, refer {@link KeyEvent}
-     * @return array of byte which contains cec keycode and param if it has;
-     *         return null if failed to find matched cec keycode
+     * @return single byte CEC keycode if matched.
      */
-    static byte[] androidKeyToCecKey(int keycode) {
+    static int androidKeyToCecKey(int keycode) {
         for (int i = 0; i < KEYCODE_ENTRIES.length; ++i) {
-            byte[] cecKeycode = KEYCODE_ENTRIES[i].toCecKeycodeIfMatched(keycode);
-            if (cecKeycode != null) {
+            int cecKeycode = KEYCODE_ENTRIES[i].toCecKeycodeIfMatched(keycode);
+            if (cecKeycode != UNSUPPORTED_KEYCODE) {
                 return cecKeycode;
             }
         }
-        return null;
+        return UNSUPPORTED_KEYCODE;
     }
 
     /**
      * Translate Hdmi CEC keycode to Android keycode.
      *
-     * @param keycode Cec keycode. If has no param, put {@link #NO_PARAM}
+     * @param keycode CEC keycode
      * @return cec keycode corresponding to the given android keycode.
      *         If finds no matched keycode, return {@link #UNSUPPORTED_KEYCODE}
      */
-    static int cecKeyToAndroidKey(int keycode, int param) {
+    static int cecKeyToAndroidKey(int keycode) {
         for (int i = 0; i < KEYCODE_ENTRIES.length; ++i) {
-            int androidKey = KEYCODE_ENTRIES[i].toAndroidKeycodeIfMatched(keycode, param);
+            int androidKey = KEYCODE_ENTRIES[i].toAndroidKeycodeIfMatched(keycode);
             if (androidKey != UNSUPPORTED_KEYCODE) {
                 return androidKey;
             }
@@ -410,4 +394,12 @@
         }
         return false;
     }
+
+    /**
+     * Returns {@code true} if given Android keycode is supported, otherwise {@code false}.
+     */
+    static boolean isSupportedKeycode(int androidKeycode) {
+        return HdmiCecKeycode.androidKeyToCecKey(androidKeycode)
+                != HdmiCecKeycode.UNSUPPORTED_KEYCODE;
+  }
 }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecLocalDevice.java b/services/core/java/com/android/server/hdmi/HdmiCecLocalDevice.java
index 4862f93..41ac589 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecLocalDevice.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecLocalDevice.java
@@ -28,6 +28,7 @@
 import android.view.KeyEvent;
 
 import com.android.internal.annotations.GuardedBy;
+import com.android.internal.util.IndentingPrintWriter;
 import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly;
 
 import java.util.ArrayList;
@@ -97,6 +98,17 @@
         public int hashCode() {
             return logicalAddress * 29 + physicalAddress;
         }
+        @Override
+        public String toString() {
+            StringBuffer s = new StringBuffer();
+            String logicalAddressString = (logicalAddress == Constants.ADDR_INVALID)
+                    ? "invalid" : String.format("0x%02x", logicalAddress);
+            s.append("logical_address: ").append(logicalAddressString);
+            String physicalAddressString = (physicalAddress == Constants.INVALID_PHYSICAL_ADDRESS)
+                    ? "invalid" : String.format("0x%04x", physicalAddress);
+            s.append(", physical_address: ").append(physicalAddressString);
+            return s.toString();
+        }
     }
     // Logical address of the active source.
     @GuardedBy("mLock")
@@ -251,7 +263,9 @@
             case Constants.MESSAGE_GIVE_DEVICE_POWER_STATUS:
                 return handleGiveDevicePowerStatus(message);
             case Constants.MESSAGE_MENU_REQUEST:
-                return handleGiveDeviceMenuStatus(message);
+                return handleMenuRequest(message);
+            case Constants.MESSAGE_MENU_STATUS:
+                return handleMenuStatus(message);
             case Constants.MESSAGE_VENDOR_COMMAND:
                 return handleVendorCommand(message);
             case Constants.MESSAGE_VENDOR_COMMAND_WITH_ID:
@@ -262,6 +276,12 @@
                 return handleRecordTvScreen(message);
             case Constants.MESSAGE_TIMER_CLEARED_STATUS:
                 return handleTimerClearedStatus(message);
+            case Constants.MESSAGE_REPORT_POWER_STATUS:
+                return handleReportPowerStatus(message);
+            case Constants.MESSAGE_TIMER_STATUS:
+                return handleTimerStatus(message);
+            case Constants.MESSAGE_RECORD_STATUS:
+                return handleRecordStatus(message);
             default:
                 return false;
         }
@@ -405,8 +425,9 @@
 
         final long downTime = SystemClock.uptimeMillis();
         final byte[] params = message.getParams();
-        final int keycode = HdmiCecKeycode.cecKeyToAndroidKey(params[0],
-                params.length > 1 ? params[1] : HdmiCecKeycode.NO_PARAM);
+        // Note that we don't support parameterized keycode now.
+        // TODO: translate parameterized keycode as well.
+        final int keycode = HdmiCecKeycode.cecKeyToAndroidKey(params[0]);
         int keyRepeatCount = 0;
         if (mLastKeycode != HdmiCecKeycode.UNSUPPORTED_KEYCODE) {
             if (keycode == mLastKeycode) {
@@ -484,16 +505,24 @@
         return true;
     }
 
-    protected boolean handleGiveDeviceMenuStatus(HdmiCecMessage message) {
+    protected boolean handleMenuRequest(HdmiCecMessage message) {
         // Always report menu active to receive Remote Control.
         mService.sendCecCommand(HdmiCecMessageBuilder.buildReportMenuStatus(
                 mAddress, message.getSource(), Constants.MENU_STATE_ACTIVATED));
         return true;
     }
 
+    protected boolean handleMenuStatus(HdmiCecMessage message) {
+        return false;
+    }
+
     protected boolean handleVendorCommand(HdmiCecMessage message) {
-        mService.invokeVendorCommandListeners(mDeviceType, message.getSource(),
-                message.getParams(), false);
+        if (!mService.invokeVendorCommandListeners(mDeviceType, message.getSource(),
+                message.getParams(), false)) {
+            // Vendor command listener may not have been registered yet. Respond with
+            // <Feature Abort> [NOT_IN_CORRECT_MODE] so that the sender can try again later.
+            mService.maySendFeatureAbortCommand(message, Constants.ABORT_NOT_IN_CORRECT_MODE);
+        }
         return true;
     }
 
@@ -501,7 +530,10 @@
         byte[] params = message.getParams();
         int vendorId = HdmiUtils.threeBytesToInt(params);
         if (vendorId == mService.getVendorId()) {
-            mService.invokeVendorCommandListeners(mDeviceType, message.getSource(), params, true);
+            if (!mService.invokeVendorCommandListeners(mDeviceType, message.getSource(), params,
+                    true)) {
+                mService.maySendFeatureAbortCommand(message, Constants.ABORT_NOT_IN_CORRECT_MODE);
+            }
         } else if (message.getDestination() != Constants.ADDR_BROADCAST &&
                 message.getSource() != Constants.ADDR_UNREGISTERED) {
             Slog.v(TAG, "Wrong direct vendor command. Replying with <Feature Abort>");
@@ -512,6 +544,10 @@
         return true;
     }
 
+    protected void sendStandby(int deviceId) {
+        // Do nothing.
+    }
+
     protected boolean handleSetOsdName(HdmiCecMessage message) {
         // The default behavior of <Set Osd Name> is doing nothing.
         return true;
@@ -528,6 +564,18 @@
         return false;
     }
 
+    protected boolean handleReportPowerStatus(HdmiCecMessage message) {
+        return false;
+    }
+
+    protected boolean handleTimerStatus(HdmiCecMessage message) {
+        return false;
+    }
+
+    protected boolean handleRecordStatus(HdmiCecMessage message) {
+        return false;
+    }
+
     @ServiceThreadOnly
     final void handleAddressAllocated(int logicalAddress, int reason) {
         assertRunOnServiceThread();
@@ -536,6 +584,10 @@
         setPreferredAddress(logicalAddress);
     }
 
+    int getType() {
+        return mDeviceType;
+    }
+
     @ServiceThreadOnly
     HdmiDeviceInfo getDeviceInfo() {
         assertRunOnServiceThread();
@@ -690,6 +742,7 @@
             mActiveSource.logicalAddress = logicalAddress;
             mActiveSource.physicalAddress = physicalAddress;
         }
+        mService.setLastInputForMhl(Constants.INVALID_PORT_ID);
     }
 
     int getActivePath() {
@@ -791,4 +844,23 @@
     protected void sendKeyEvent(int keyCode, boolean isPressed) {
         Slog.w(TAG, "sendKeyEvent not implemented");
     }
+
+    void sendUserControlPressedAndReleased(int targetAddress, int cecKeycode) {
+        mService.sendCecCommand(HdmiCecMessageBuilder.buildUserControlPressed(
+                mAddress, targetAddress, cecKeycode));
+        mService.sendCecCommand(HdmiCecMessageBuilder.buildUserControlReleased(
+                mAddress, targetAddress));
+    }
+
+    /**
+     * Dump internal status of HdmiCecLocalDevice object.
+     */
+    protected void dump(final IndentingPrintWriter pw) {
+        pw.println("mDeviceType: " + mDeviceType);
+        pw.println("mAddress: " + mAddress);
+        pw.println("mPreferredAddress: " + mPreferredAddress);
+        pw.println("mDeviceInfo: " + mDeviceInfo);
+        pw.println("mActiveSource: " + mActiveSource);
+        pw.println(String.format("mActiveRoutingPath: 0x%04x", mActiveRoutingPath));
+    }
 }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecLocalDevicePlayback.java b/services/core/java/com/android/server/hdmi/HdmiCecLocalDevicePlayback.java
index 5a2fa9c..3bd0bcf 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecLocalDevicePlayback.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecLocalDevicePlayback.java
@@ -23,6 +23,7 @@
 import android.os.SystemProperties;
 import android.util.Slog;
 
+import com.android.internal.util.IndentingPrintWriter;
 import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly;
 
 /**
@@ -120,7 +121,7 @@
     void onHotplug(int portId, boolean connected) {
         assertRunOnServiceThread();
         mCecMessageCache.flushAll();
-        mIsActiveSource = false;
+        // We'll not clear mIsActiveSource on the hotplug event to pass CETC 11.2.2-2 ~ 3.
         if (connected && mService.isPowerStandbyOrTransient()) {
             mService.wakeUp();
         }
@@ -219,4 +220,10 @@
         mIsActiveSource = false;
         checkIfPendingActionsCleared();
     }
+
+    @Override
+    protected void dump(final IndentingPrintWriter pw) {
+        super.dump(pw);
+        pw.println("mIsActiveSource: " + mIsActiveSource);
+    }
 }
\ No newline at end of file
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecLocalDeviceTv.java b/services/core/java/com/android/server/hdmi/HdmiCecLocalDeviceTv.java
index 809fef4..bd9f04b 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecLocalDeviceTv.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecLocalDeviceTv.java
@@ -22,6 +22,7 @@
 import static android.hardware.hdmi.HdmiControlManager.ONE_TOUCH_RECORD_CEC_DISABLED;
 import static android.hardware.hdmi.HdmiControlManager.ONE_TOUCH_RECORD_CHECK_RECORDER_CONNECTION;
 import static android.hardware.hdmi.HdmiControlManager.ONE_TOUCH_RECORD_FAIL_TO_RECORD_DISPLAYED_SCREEN;
+import static android.hardware.hdmi.HdmiControlManager.OSD_MESSAGE_ARC_CONNECTED_INVALID_PORT;
 import static android.hardware.hdmi.HdmiControlManager.TIMER_RECORDING_RESULT_EXTRA_CEC_DISABLED;
 import static android.hardware.hdmi.HdmiControlManager.TIMER_RECORDING_RESULT_EXTRA_CHECK_RECORDER_CONNECTION;
 import static android.hardware.hdmi.HdmiControlManager.TIMER_RECORDING_RESULT_EXTRA_FAIL_TO_RECORD_SELECTED_SOURCE;
@@ -29,7 +30,6 @@
 import static android.hardware.hdmi.HdmiControlManager.TIMER_RECORDING_TYPE_DIGITAL;
 import static android.hardware.hdmi.HdmiControlManager.TIMER_RECORDING_TYPE_EXTERNAL;
 
-import android.content.Intent;
 import android.hardware.hdmi.HdmiControlManager;
 import android.hardware.hdmi.HdmiDeviceInfo;
 import android.hardware.hdmi.HdmiRecordSources;
@@ -39,13 +39,13 @@
 import android.media.AudioSystem;
 import android.os.RemoteException;
 import android.os.SystemProperties;
-import android.os.UserHandle;
 import android.provider.Settings.Global;
 import android.util.ArraySet;
 import android.util.Slog;
 import android.util.SparseArray;
 
 import com.android.internal.annotations.GuardedBy;
+import com.android.internal.util.IndentingPrintWriter;
 import com.android.server.hdmi.DeviceDiscoveryAction.DeviceDiscoveryCallback;
 import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly;
 import com.android.server.hdmi.HdmiControlService.SendMessageCallback;
@@ -57,7 +57,6 @@
 import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
-import java.util.Locale;
 
 /**
  * Represent a logical device of type TV residing in Android system.
@@ -70,8 +69,9 @@
     @ServiceThreadOnly
     private boolean mArcEstablished = false;
 
-    // Whether ARC feature is enabled or not.
-    private boolean mArcFeatureEnabled = false;
+    // Whether ARC feature is enabled or not. The default value is true.
+    // TODO: once adding system setting for it, read the value to it.
+    private boolean mArcFeatureEnabled = true;
 
     // Whether System audio mode is activated or not.
     // This becomes true only when all system audio sequences are finished.
@@ -112,6 +112,10 @@
 
     private final HdmiCecStandbyModeHandler mStandbyHandler;
 
+    // If true, do not do routing control/send active source for internal source.
+    // Set to true when the device was woken up by <Text/Image View On>.
+    private boolean mSkipRoutingControl;
+
     // Set of physical addresses of CEC switches on the CEC bus. Managed independently from
     // other CEC devices since they might not have logical address.
     private final ArraySet<Integer> mCecSwitches = new ArraySet<Integer>();
@@ -134,6 +138,7 @@
         mService.sendCecCommand(HdmiCecMessageBuilder.buildDeviceVendorIdCommand(
                 mAddress, mService.getVendorId()));
         mCecSwitches.add(mService.getPhysicalAddress());  // TV is a CEC switch too.
+        mSkipRoutingControl = (reason == HdmiControlService.INITIATED_BY_WAKE_UP_MESSAGE);
         launchRoutingControl(reason != HdmiControlService.INITIATED_BY_ENABLE_CEC &&
                 reason != HdmiControlService.INITIATED_BY_BOOT_UP);
         launchDeviceDiscovery();
@@ -178,7 +183,6 @@
             invokeCallback(callback, HdmiControlManager.RESULT_TARGET_NOT_AVAILABLE);
             return;
         }
-        // TODO: Handle MHL device
         int targetAddress = targetDevice.getLogicalAddress();
         ActiveSource active = getActiveSource();
         if (active.isValid() && targetAddress == active.logicalAddress) {
@@ -208,7 +212,10 @@
         // Seq #18
         if (mService.isControlEnabled() && mActiveSource.logicalAddress != mAddress) {
             updateActiveSource(mAddress, mService.getPhysicalAddress());
-            // TODO: Check if this comes from <Text/Image View On> - if true, do nothing.
+            if (mSkipRoutingControl) {
+                mSkipRoutingControl = false;
+                return;
+            }
             HdmiCecMessage activeSource = HdmiCecMessageBuilder.buildActiveSource(
                     mAddress, mService.getPhysicalAddress());
             mService.sendCecCommand(activeSource);
@@ -272,7 +279,6 @@
             return;
         }
         setPrevPortId(getActivePortId());
-        int portId = mService.pathToPortId(path);
         setActivePath(path);
         // TODO: Handle PAP/PIP case.
         // Show OSD port change banner
@@ -280,7 +286,7 @@
             ActiveSource activeSource = getActiveSource();
             HdmiDeviceInfo info = getCecDeviceInfo(activeSource.logicalAddress);
             if (info == null) {
-                info = new HdmiDeviceInfo(Constants.ADDR_INVALID, path, portId,
+                info = new HdmiDeviceInfo(Constants.ADDR_INVALID, path, getActivePortId(),
                         HdmiDeviceInfo.DEVICE_RESERVED, 0, null);
             }
             mService.invokeInputChangeListener(info);
@@ -305,20 +311,24 @@
             invokeCallback(callback, HdmiControlManager.RESULT_INCORRECT_MODE);
             return;
         }
-        // TODO: Return immediately if the operation is triggered by <Text/Image View On>
-        // and this is the first notification about the active input after power-on
-        // (switch to HDMI didn't happen so far but is expected to happen soon).
         int oldPath = getActivePortId() != Constants.INVALID_PORT_ID
                 ? mService.portIdToPath(getActivePortId()) : getDeviceInfo().getPhysicalAddress();
+        setActivePath(oldPath);
+        if (mSkipRoutingControl) {
+            mSkipRoutingControl = false;
+            return;
+        }
         int newPath = mService.portIdToPath(portId);
         HdmiCecMessage routingChange =
                 HdmiCecMessageBuilder.buildRoutingChange(mAddress, oldPath, newPath);
         mService.sendCecCommand(routingChange);
         removeAction(RoutingControlAction.class);
-        addAndStartAction(new RoutingControlAction(this, newPath, false, callback));
+        addAndStartAction(new RoutingControlAction(this, newPath, true, callback));
     }
 
+    @ServiceThreadOnly
     int getPowerStatus() {
+        assertRunOnServiceThread();
         return mService.getPowerStatus();
     }
 
@@ -332,6 +342,10 @@
     @ServiceThreadOnly
     protected void sendKeyEvent(int keyCode, boolean isPressed) {
         assertRunOnServiceThread();
+        if (!HdmiCecKeycode.isSupportedKeycode(keyCode)) {
+            Slog.w(TAG, "Unsupported key: " + keyCode);
+            return;
+        }
         List<SendKeyAction> action = getActions(SendKeyAction.class);
         if (!action.isEmpty()) {
             action.get(0).processKeyEvent(keyCode, isPressed);
@@ -419,17 +433,24 @@
     @ServiceThreadOnly
     protected boolean handleGetMenuLanguage(HdmiCecMessage message) {
         assertRunOnServiceThread();
-        HdmiCecMessage command = HdmiCecMessageBuilder.buildSetMenuLanguageCommand(
-                mAddress, Locale.getDefault().getISO3Language());
-        // TODO: figure out how to handle failed to get language code.
-        if (command != null) {
-            mService.sendCecCommand(command);
-        } else {
+        if (!broadcastMenuLanguage(mService.getLanguage())) {
             Slog.w(TAG, "Failed to respond to <Get Menu Language>: " + message.toString());
         }
         return true;
     }
 
+    @ServiceThreadOnly
+    boolean broadcastMenuLanguage(String language) {
+        assertRunOnServiceThread();
+        HdmiCecMessage command = HdmiCecMessageBuilder.buildSetMenuLanguageCommand(
+                mAddress, language);
+        if (command != null) {
+            mService.sendCecCommand(command);
+            return true;
+        }
+        return false;
+    }
+
     @Override
     @ServiceThreadOnly
     protected boolean handleReportPhysicalAddress(HdmiCecMessage message) {
@@ -446,13 +467,32 @@
             return true;
         }
 
-        if (!isInDeviceList(path, address)) {
+        if (!isInDeviceList(address, path)) {
             handleNewDeviceAtTheTailOfActivePath(path);
         }
         startNewDeviceAction(ActiveSource.of(address, path));
         return true;
     }
 
+    @Override
+    protected boolean handleReportPowerStatus(HdmiCecMessage command) {
+        int newStatus = command.getParams()[0] & 0xFF;
+        updateDevicePowerStatus(command.getSource(), newStatus);
+        return true;
+    }
+
+    @Override
+    protected boolean handleTimerStatus(HdmiCecMessage message) {
+        // Do nothing.
+        return true;
+    }
+
+    @Override
+    protected boolean handleRecordStatus(HdmiCecMessage message) {
+        // Do nothing.
+        return true;
+    }
+
     boolean updateCecSwitchInfo(int address, int type, int path) {
         if (address == Constants.ADDR_UNREGISTERED
                 && type == HdmiDeviceInfo.DEVICE_PURE_CEC_SWITCH) {
@@ -559,8 +599,6 @@
         if (mService.isPowerStandbyOrTransient() && mAutoWakeup) {
             mService.wakeUp();
         }
-        // TODO: Connect to Hardware input manager to invoke TV App with the appropriate channel
-        //       that represents the source device.
         return true;
     }
 
@@ -626,19 +664,26 @@
                         // If there is AVR, initiate System Audio Auto initiation action,
                         // which turns on and off system audio according to last system
                         // audio setting.
-                        if (mSystemAudioActivated && getAvrDeviceInfo() != null) {
-                            addAndStartAction(new SystemAudioAutoInitiationAction(
-                                    HdmiCecLocalDeviceTv.this,
-                                    getAvrDeviceInfo().getLogicalAddress()));
-                            if (mArcEstablished) {
-                                startArcAction(true);
-                            }
+                        HdmiDeviceInfo avr = getAvrDeviceInfo();
+                        if (avr != null) {
+                            onNewAvrAdded(avr);
                         }
                     }
                 });
         addAndStartAction(action);
     }
 
+    @ServiceThreadOnly
+    void onNewAvrAdded(HdmiDeviceInfo avr) {
+        assertRunOnServiceThread();
+        if (getSystemAudioModeSetting()) {
+            addAndStartAction(new SystemAudioAutoInitiationAction(this, avr.getLogicalAddress()));
+        }
+        if (isArcFeatureEnabled()) {
+            startArcAction(true);
+        }
+    }
+
     // Clear all device info.
     @ServiceThreadOnly
     private void clearDeviceInfoList() {
@@ -672,6 +717,8 @@
 
     // # Seq 25
     void setSystemAudioMode(boolean on, boolean updateSetting) {
+        HdmiLogger.debug("System Audio Mode change[old:%b new:%b]", mSystemAudioActivated, on);
+
         if (updateSetting) {
             mService.writeBooleanSetting(Global.HDMI_SYSTEM_AUDIO_ENABLED, on);
         }
@@ -685,8 +732,8 @@
     }
 
     private void updateAudioManagerForSystemAudio(boolean on) {
-        // TODO: remove output device, once update AudioManager api.
-        mService.getAudioManager().setHdmiSystemAudioSupported(on);
+        int device = mService.getAudioManager().setHdmiSystemAudioSupported(on);
+        HdmiLogger.debug("[A]UpdateSystemAudio mode[on=%b] output=[%X]", on, device);
     }
 
     boolean isSystemAudioActivated() {
@@ -710,6 +757,8 @@
     @ServiceThreadOnly
     boolean setArcStatus(boolean enabled) {
         assertRunOnServiceThread();
+
+        HdmiLogger.debug("Set Arc Status[old:%b new:%b]", mArcEstablished, enabled);
         boolean oldStatus = mArcEstablished;
         // 1. Enable/disable ARC circuit.
         mService.setAudioReturnChannel(enabled);
@@ -741,6 +790,7 @@
         assertRunOnServiceThread();
 
         if (mArcFeatureEnabled != enabled) {
+            mArcFeatureEnabled = enabled;
             if (enabled) {
                 if (!mArcEstablished) {
                     startArcAction(true);
@@ -750,7 +800,6 @@
                     startArcAction(false);
                 }
             }
-            mArcFeatureEnabled = enabled;
         }
     }
 
@@ -761,13 +810,18 @@
     }
 
     @ServiceThreadOnly
-    private void startArcAction(boolean enabled) {
+    void startArcAction(boolean enabled) {
         assertRunOnServiceThread();
         HdmiDeviceInfo info = getAvrDeviceInfo();
         if (info == null) {
+            Slog.w(TAG, "Failed to start arc action; No AVR device.");
             return;
         }
-        if (!isConnectedToArcPort(info.getPhysicalAddress())) {
+        if (!canStartArcUpdateAction(info.getLogicalAddress(), enabled)) {
+            Slog.w(TAG, "Failed to start arc action; ARC configuration check failed.");
+            if (enabled && !isConnectedToArcPort(info.getPhysicalAddress())) {
+                displayOsd(OSD_MESSAGE_ARC_CONNECTED_INVALID_PORT);
+            }
             return;
         }
 
@@ -785,6 +839,10 @@
         }
     }
 
+    private boolean isDirectConnectAddress(int physicalAddress) {
+        return (physicalAddress & Constants.ROUTING_PATH_TOP_MASK) == physicalAddress;
+    }
+
     void setAudioStatus(boolean mute, int volume) {
         synchronized (mLock) {
             mSystemAudioMute = mute;
@@ -793,6 +851,8 @@
                     AudioManager.STREAM_MUSIC);
             mService.setAudioStatus(mute,
                     VolumeControlAction.scaleToCustomVolume(volume, maxVolume));
+            displayOsd(HdmiControlManager.OSD_MESSAGE_AVR_VOLUME_CHANGED,
+                    mute ? HdmiControlManager.AVR_VOLUME_MUTED : volume);
         }
     }
 
@@ -816,31 +876,50 @@
             }
         }
 
-        // Remove existing volume action.
-        removeAction(VolumeControlAction.class);
-
-        HdmiDeviceInfo avr = getAvrDeviceInfo();
-        addAndStartAction(VolumeControlAction.ofVolumeChange(this, avr.getLogicalAddress(),
-                cecVolume, delta > 0));
+        List<VolumeControlAction> actions = getActions(VolumeControlAction.class);
+        if (actions.isEmpty()) {
+            addAndStartAction(new VolumeControlAction(this,
+                    getAvrDeviceInfo().getLogicalAddress(), delta > 0));
+        } else {
+            actions.get(0).handleVolumeChange(delta > 0);
+        }
     }
 
     @ServiceThreadOnly
     void changeMute(boolean mute) {
         assertRunOnServiceThread();
+        HdmiLogger.debug("[A]:Change mute:%b", mute);
+        synchronized (mLock) {
+            if (mSystemAudioMute == mute) {
+                HdmiLogger.debug("No need to change mute.");
+                return;
+            }
+        }
         if (!isSystemAudioActivated()) {
+            HdmiLogger.debug("[A]:System audio is not activated.");
             return;
         }
 
         // Remove existing volume action.
         removeAction(VolumeControlAction.class);
-        HdmiDeviceInfo avr = getAvrDeviceInfo();
-        addAndStartAction(VolumeControlAction.ofMute(this, avr.getLogicalAddress(), mute));
+        sendUserControlPressedAndReleased(getAvrDeviceInfo().getLogicalAddress(),
+                mute ? HdmiCecKeycode.CEC_KEYCODE_MUTE_FUNCTION :
+                        HdmiCecKeycode.CEC_KEYCODE_RESTORE_VOLUME_FUNCTION);
     }
 
     @Override
     @ServiceThreadOnly
     protected boolean handleInitiateArc(HdmiCecMessage message) {
         assertRunOnServiceThread();
+
+        if (!canStartArcUpdateAction(message.getSource(), true)) {
+            mService.maySendFeatureAbortCommand(message, Constants.ABORT_REFUSED);
+            if (!isConnectedToArcPort(message.getSource())) {
+                displayOsd(OSD_MESSAGE_ARC_CONNECTED_INVALID_PORT);
+            }
+            return true;
+        }
+
         // In case where <Initiate Arc> is started by <Request ARC Initiation>
         // need to clean up RequestArcInitiationAction.
         removeAction(RequestArcInitiationAction.class);
@@ -850,10 +929,29 @@
         return true;
     }
 
+    private boolean canStartArcUpdateAction(int avrAddress, boolean shouldCheckArcFeatureEnabled) {
+        HdmiDeviceInfo avr = getAvrDeviceInfo();
+        if (avr != null
+                && (avrAddress == avr.getLogicalAddress())
+                && isConnectedToArcPort(avr.getPhysicalAddress())
+                && isDirectConnectAddress(avr.getPhysicalAddress())) {
+            if (shouldCheckArcFeatureEnabled) {
+                return isArcFeatureEnabled();
+            } else {
+                return true;
+            }
+        } else {
+            return false;
+        }
+    }
+
     @Override
     @ServiceThreadOnly
     protected boolean handleTerminateArc(HdmiCecMessage message) {
         assertRunOnServiceThread();
+        // In cast of termination, do not check ARC configuration in that AVR device
+        // might be removed already.
+
         // In case where <Terminate Arc> is started by <Request ARC Termination>
         // need to clean up RequestArcInitiationAction.
         removeAction(RequestArcTerminationAction.class);
@@ -868,7 +966,9 @@
     protected boolean handleSetSystemAudioMode(HdmiCecMessage message) {
         assertRunOnServiceThread();
         if (!isMessageForSystemAudio(message)) {
-            return false;
+            HdmiLogger.warning("Invalid <Set System Audio Mode> message:" + message);
+            mService.maySendFeatureAbortCommand(message, Constants.ABORT_REFUSED);
+            return true;
         }
         SystemAudioActionFromAvr action = new SystemAudioActionFromAvr(this,
                 message.getSource(), HdmiUtils.parseCommandParamSystemAudioStatus(message), null);
@@ -881,7 +981,9 @@
     protected boolean handleSystemAudioModeStatus(HdmiCecMessage message) {
         assertRunOnServiceThread();
         if (!isMessageForSystemAudio(message)) {
-            return false;
+            HdmiLogger.warning("Invalid <System Audio Mode Status> message:" + message);
+            // Ignore this message.
+            return true;
         }
         setSystemAudioMode(HdmiUtils.parseCommandParamSystemAudioStatus(message), true);
         return true;
@@ -904,7 +1006,10 @@
 
         int recorderAddress = message.getSource();
         byte[] recordSource = mService.invokeRecordRequestListener(recorderAddress);
-        startOneTouchRecord(recorderAddress, recordSource);
+        int reason = startOneTouchRecord(recorderAddress, recordSource);
+        if (reason != Constants.ABORT_NO_ERROR) {
+            mService.maySendFeatureAbortCommand(message, reason);
+        }
         return true;
     }
 
@@ -929,13 +1034,11 @@
     }
 
     private boolean isMessageForSystemAudio(HdmiCecMessage message) {
-        if (message.getSource() != Constants.ADDR_AUDIO_SYSTEM
-                || message.getDestination() != Constants.ADDR_TV
-                || getAvrDeviceInfo() == null) {
-            Slog.w(TAG, "Skip abnormal CecMessage: " + message);
-            return false;
-        }
-        return true;
+        return mService.isControlEnabled()
+                && message.getSource() == Constants.ADDR_AUDIO_SYSTEM
+                && (message.getDestination() == Constants.ADDR_TV
+                        || message.getDestination() == Constants.ADDR_BROADCAST)
+                && getAvrDeviceInfo() != null;
     }
 
     /**
@@ -984,13 +1087,13 @@
      * Return a list of all {@link HdmiDeviceInfo}.
      *
      * <p>Declared as package-private. accessed by {@link HdmiControlService} only.
-     * This is not thread-safe. For thread safety, call {@link #getSafeExternalInputs} which
+     * This is not thread-safe. For thread safety, call {@link #getSafeExternalInputsLocked} which
      * does not include local device.
      */
     @ServiceThreadOnly
-    List<HdmiDeviceInfo> getDeviceInfoList(boolean includelLocalDevice) {
+    List<HdmiDeviceInfo> getDeviceInfoList(boolean includeLocalDevice) {
         assertRunOnServiceThread();
-        if (includelLocalDevice) {
+        if (includeLocalDevice) {
             return HdmiUtils.sparseArrayToList(mDeviceInfos);
         } else {
             ArrayList<HdmiDeviceInfo> infoList = new ArrayList<>();
@@ -1007,10 +1110,8 @@
     /**
      * Return external input devices.
      */
-    List<HdmiDeviceInfo> getSafeExternalInputs() {
-        synchronized (mLock) {
-            return mSafeExternalInputs;
-        }
+    List<HdmiDeviceInfo> getSafeExternalInputsLocked() {
+        return mSafeExternalInputs;
     }
 
     @ServiceThreadOnly
@@ -1102,7 +1203,7 @@
      *
      * This is not thread-safe. For thread safety, call {@link #getSafeCecDeviceInfo(int)}.
      *
-     * @param address logical address of the device to be retrieved
+     * @param logicalAddress logical address of the device to be retrieved
      * @return {@link HdmiDeviceInfo} matched with the given {@code logicalAddress}.
      *         Returns null if no logical address matched
      */
@@ -1178,7 +1279,8 @@
             int newPath = mService.portIdToPath(getActivePortId());
             mService.sendCecCommand(HdmiCecMessageBuilder.buildRoutingChange(
                     mAddress, getActivePath(), newPath));
-            addAndStartAction(new RoutingControlAction(this, getActivePortId(), true, null));
+            mActiveSource.invalidate();
+            addAndStartAction(new RoutingControlAction(this, getActivePath(), true, null));
         }
     }
 
@@ -1241,7 +1343,7 @@
      * @return true if exist; otherwise false
      */
     @ServiceThreadOnly
-    boolean isInDeviceList(int logicalAddress, int physicalAddress) {
+    private boolean isInDeviceList(int logicalAddress, int physicalAddress) {
         assertRunOnServiceThread();
         HdmiDeviceInfo device = getCecDeviceInfo(logicalAddress);
         if (device == null) {
@@ -1374,38 +1476,44 @@
         return mService.isPowerStandbyOrTransient();
     }
 
+    @ServiceThreadOnly
     void displayOsd(int messageId) {
-        Intent intent = new Intent(HdmiControlManager.ACTION_OSD_MESSAGE);
-        intent.putExtra(HdmiControlManager.EXTRA_MESSAGE_ID, messageId);
-        mService.getContext().sendBroadcastAsUser(intent, UserHandle.ALL,
-                HdmiControlService.PERMISSION);
+        assertRunOnServiceThread();
+        mService.displayOsd(messageId);
+    }
+
+    @ServiceThreadOnly
+    void displayOsd(int messageId, int extra) {
+        assertRunOnServiceThread();
+        mService.displayOsd(messageId, extra);
     }
 
     // Seq #54 and #55
     @ServiceThreadOnly
-    void startOneTouchRecord(int recorderAddress, byte[] recordSource) {
+    int startOneTouchRecord(int recorderAddress, byte[] recordSource) {
         assertRunOnServiceThread();
         if (!mService.isControlEnabled()) {
             Slog.w(TAG, "Can not start one touch record. CEC control is disabled.");
             announceOneTouchRecordResult(ONE_TOUCH_RECORD_CEC_DISABLED);
-            return;
+            return Constants.ABORT_NOT_IN_CORRECT_MODE;
         }
 
         if (!checkRecorder(recorderAddress)) {
             Slog.w(TAG, "Invalid recorder address:" + recorderAddress);
             announceOneTouchRecordResult(ONE_TOUCH_RECORD_CHECK_RECORDER_CONNECTION);
-            return;
+            return Constants.ABORT_NOT_IN_CORRECT_MODE;
         }
 
         if (!checkRecordSource(recordSource)) {
             Slog.w(TAG, "Invalid record source." + Arrays.toString(recordSource));
             announceOneTouchRecordResult(ONE_TOUCH_RECORD_FAIL_TO_RECORD_DISPLAYED_SCREEN);
-            return;
+            return Constants.ABORT_UNABLE_TO_DETERMINE;
         }
 
         addAndStartAction(new OneTouchRecordAction(this, recorderAddress, recordSource));
         Slog.i(TAG, "Start new [One Touch Record]-Target:" + recorderAddress + ", recordSource:"
                 + Arrays.toString(recordSource));
+        return Constants.ABORT_NO_ERROR;
     }
 
     @ServiceThreadOnly
@@ -1547,4 +1655,38 @@
 
         invokeDeviceEventListener(newInfo, HdmiControlManager.DEVICE_EVENT_UPDATE_DEVICE);
     }
+
+    @Override
+    protected boolean handleMenuStatus(HdmiCecMessage message) {
+        // Do nothing and just return true not to prevent from responding <Feature Abort>.
+        return true;
+    }
+
+    @Override
+    protected void sendStandby(int deviceId) {
+        HdmiDeviceInfo targetDevice = mDeviceInfos.get(deviceId);
+        if (targetDevice == null) {
+            return;
+        }
+        int targetAddress = targetDevice.getLogicalAddress();
+        mService.sendCecCommand(HdmiCecMessageBuilder.buildStandby(mAddress, targetAddress));
+    }
+
+    @Override
+    protected void dump(final IndentingPrintWriter pw) {
+        super.dump(pw);
+        pw.println("mArcEstablished: " + mArcEstablished);
+        pw.println("mArcFeatureEnabled: " + mArcFeatureEnabled);
+        pw.println("mSystemAudioActivated: " + mSystemAudioActivated);
+        pw.println("mSystemAudioMute: " + mSystemAudioMute);
+        pw.println("mAutoDeviceOff: " + mAutoDeviceOff);
+        pw.println("mAutoWakeup: " + mAutoWakeup);
+        pw.println("mSkipRoutingControl: " + mSkipRoutingControl);
+        pw.println("CEC devices:");
+        pw.increaseIndent();
+        for (HdmiDeviceInfo info : mSafeAllDeviceInfos) {
+            pw.println(info);
+        }
+        pw.decreaseIndent();
+    }
 }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecMessage.java b/services/core/java/com/android/server/hdmi/HdmiCecMessage.java
index 433e93f..fd0ff9d 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecMessage.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecMessage.java
@@ -103,26 +103,146 @@
         switch (opcode) {
             case Constants.MESSAGE_FEATURE_ABORT:
                 return "Feature Abort";
+            case Constants.MESSAGE_IMAGE_VIEW_ON:
+                return "Image View On";
+            case Constants.MESSAGE_TUNER_STEP_INCREMENT:
+                return "Tuner Step Increment";
+            case Constants.MESSAGE_TUNER_STEP_DECREMENT:
+                return "Tuner Step Decrement";
+            case Constants.MESSAGE_TUNER_DEVICE_STATUS:
+                return "Tuner Device Staus";
+            case Constants.MESSAGE_GIVE_TUNER_DEVICE_STATUS:
+                return "Give Tuner Device Status";
+            case Constants.MESSAGE_RECORD_ON:
+                return "Record On";
+            case Constants.MESSAGE_RECORD_STATUS:
+                return "Record Status";
+            case Constants.MESSAGE_RECORD_OFF:
+                return "Record Off";
+            case Constants.MESSAGE_TEXT_VIEW_ON:
+                return "Text View On";
+            case Constants.MESSAGE_RECORD_TV_SCREEN:
+                return "Record Tv Screen";
+            case Constants.MESSAGE_GIVE_DECK_STATUS:
+                return "Give Deck Status";
+            case Constants.MESSAGE_DECK_STATUS:
+                return "Deck Status";
+            case Constants.MESSAGE_SET_MENU_LANGUAGE:
+                return "Set Menu Language";
+            case Constants.MESSAGE_CLEAR_ANALOG_TIMER:
+                return "Clear Analog Timer";
+            case Constants.MESSAGE_SET_ANALOG_TIMER:
+                return "Set Analog Timer";
+            case Constants.MESSAGE_TIMER_STATUS:
+                return "Timer Status";
+            case Constants.MESSAGE_STANDBY:
+                return "Standby";
+            case Constants.MESSAGE_PLAY:
+                return "Play";
+            case Constants.MESSAGE_DECK_CONTROL:
+                return "Deck Control";
+            case Constants.MESSAGE_TIMER_CLEARED_STATUS:
+                return "Timer Cleared Status";
+            case Constants.MESSAGE_USER_CONTROL_PRESSED:
+                return "User Control Pressed";
+            case Constants.MESSAGE_USER_CONTROL_RELEASED:
+                return "User Control Release";
+            case Constants.MESSAGE_GIVE_OSD_NAME:
+                return "Give Osd Name";
+            case Constants.MESSAGE_SET_OSD_NAME:
+                return "Set Osd Name";
+            case Constants.MESSAGE_SET_OSD_STRING:
+                return "Set Osd String";
+            case Constants.MESSAGE_SET_TIMER_PROGRAM_TITLE:
+                return "Set Timer Program Title";
+            case Constants.MESSAGE_SYSTEM_AUDIO_MODE_REQUEST:
+                return "System Audio Mode Request";
+            case Constants.MESSAGE_GIVE_AUDIO_STATUS:
+                return "Give Audio Status";
+            case Constants.MESSAGE_SET_SYSTEM_AUDIO_MODE:
+                return "Set System Audio Mode";
+            case Constants.MESSAGE_REPORT_AUDIO_STATUS:
+                return "Report Audio Status";
+            case Constants.MESSAGE_GIVE_SYSTEM_AUDIO_MODE_STATUS:
+                return "Give System Audio Mode Status";
+            case Constants.MESSAGE_SYSTEM_AUDIO_MODE_STATUS:
+                return "System Audio Mode Status";
+            case Constants.MESSAGE_ROUTING_CHANGE:
+                return "Routing Change";
+            case Constants.MESSAGE_ROUTING_INFORMATION:
+                return "Routing Information";
+            case Constants.MESSAGE_ACTIVE_SOURCE:
+                return "Active Source";
+            case Constants.MESSAGE_GIVE_PHYSICAL_ADDRESS:
+                return "Give Physical Address";
+            case Constants.MESSAGE_REPORT_PHYSICAL_ADDRESS:
+                return "Report Physical Address";
+            case Constants.MESSAGE_REQUEST_ACTIVE_SOURCE:
+                return "Request Active Source";
+            case Constants.MESSAGE_SET_STREAM_PATH:
+                return "Set Stream Path";
+            case Constants.MESSAGE_DEVICE_VENDOR_ID:
+                return "Device Vendor Id";
+            case Constants.MESSAGE_VENDOR_COMMAND:
+                return "Vendor Commandn";
+            case Constants.MESSAGE_VENDOR_REMOTE_BUTTON_DOWN:
+                return "Vendor Remote Button Down";
+            case Constants.MESSAGE_VENDOR_REMOTE_BUTTON_UP:
+                return "Vendor Remote Button Up";
+            case Constants.MESSAGE_GIVE_DEVICE_VENDOR_ID:
+                return "Give Device Vendor Id";
+            case Constants.MESSAGE_MENU_REQUEST:
+                return "Menu REquest";
+            case Constants.MESSAGE_MENU_STATUS:
+                return "Menu Status";
+            case Constants.MESSAGE_GIVE_DEVICE_POWER_STATUS:
+                return "Give Device Power Status";
+            case Constants.MESSAGE_REPORT_POWER_STATUS:
+                return "Report Power Status";
+            case Constants.MESSAGE_GET_MENU_LANGUAGE:
+                return "Get Menu Language";
+            case Constants.MESSAGE_SELECT_ANALOG_SERVICE:
+                return "Select Analog Service";
+            case Constants.MESSAGE_SELECT_DIGITAL_SERVICE:
+                return "Select Digital Service";
+            case Constants.MESSAGE_SET_DIGITAL_TIMER:
+                return "Set Digital Timer";
+            case Constants.MESSAGE_CLEAR_DIGITAL_TIMER:
+                return "Clear Digital Timer";
+            case Constants.MESSAGE_SET_AUDIO_RATE:
+                return "Set Audio Rate";
+            case Constants.MESSAGE_INACTIVE_SOURCE:
+                return "InActive Source";
             case Constants.MESSAGE_CEC_VERSION:
-                return "CEC Version";
-            case Constants.MESSAGE_REQUEST_ARC_INITIATION:
-                return "Request ARC Initiation";
-            case Constants.MESSAGE_REQUEST_ARC_TERMINATION:
-                return "Request ARC Termination";
+                return "Cec Version";
+            case Constants.MESSAGE_GET_CEC_VERSION:
+                return "Get Cec Version";
+            case Constants.MESSAGE_VENDOR_COMMAND_WITH_ID:
+                return "Vendor Command With Id";
+            case Constants.MESSAGE_CLEAR_EXTERNAL_TIMER:
+                return "Clear External Timer";
+            case Constants.MESSAGE_SET_EXTERNAL_TIMER:
+                return "Set External Timer";
+            case Constants.MESSAGE_REPORT_SHORT_AUDIO_DESCRIPTOR:
+                return "Repot Short Audio Descriptor";
+            case Constants.MESSAGE_REQUEST_SHORT_AUDIO_DESCRIPTOR:
+                return "Request Short Audio Descriptor";
+            case Constants.MESSAGE_INITIATE_ARC:
+                return "Initiate ARC";
             case Constants.MESSAGE_REPORT_ARC_INITIATED:
                 return "Report ARC Initiated";
             case Constants.MESSAGE_REPORT_ARC_TERMINATED:
                 return "Report ARC Terminated";
-            case Constants.MESSAGE_TEXT_VIEW_ON:
-                return "Text View On";
-            case Constants.MESSAGE_ACTIVE_SOURCE:
-                return "Active Source";
-            case Constants.MESSAGE_GIVE_DEVICE_POWER_STATUS:
-                return "Give Device Power Status";
-            case Constants.MESSAGE_VENDOR_COMMAND:
-                return "Vendor Command";
-            case Constants.MESSAGE_VENDOR_COMMAND_WITH_ID:
-                return "Vendor Command With ID";
+            case Constants.MESSAGE_REQUEST_ARC_INITIATION:
+                return "Request ARC Initiation";
+            case Constants.MESSAGE_REQUEST_ARC_TERMINATION:
+                return "Request ARC Termination";
+            case Constants.MESSAGE_TERMINATE_ARC:
+                return "Terminate ARC";
+            case Constants.MESSAGE_CDC_MESSAGE:
+                return "Cdc Message";
+            case Constants.MESSAGE_ABORT:
+                return "Abort";
             default:
                 return String.format("Opcode: %02X", opcode);
         }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecMessageBuilder.java b/services/core/java/com/android/server/hdmi/HdmiCecMessageBuilder.java
index b53cd45..9a51e3c 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecMessageBuilder.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecMessageBuilder.java
@@ -54,8 +54,8 @@
     static HdmiCecMessage buildFeatureAbortCommand(int src, int dest, int originalOpcode,
             int reason) {
         byte[] params = new byte[] {
-                (byte) originalOpcode,
-                (byte) reason,
+                (byte) (originalOpcode & 0xFF),
+                (byte) (reason & 0xFF),
         };
         return buildCommand(src, dest, Constants.MESSAGE_FEATURE_ABORT, params);
     }
@@ -110,9 +110,9 @@
         // Hdmi CEC uses lower-cased ISO 639-2 (3 letters code).
         String normalized = language.toLowerCase();
         byte[] params = new byte[] {
-                (byte) normalized.charAt(0),
-                (byte) normalized.charAt(1),
-                (byte) normalized.charAt(2),
+                (byte) (normalized.charAt(0) & 0xFF),
+                (byte) (normalized.charAt(1) & 0xFF),
+                (byte) (normalized.charAt(2) & 0xFF),
         };
         // <Set Menu Language> is broadcast message.
         return buildCommand(src, Constants.ADDR_BROADCAST,
@@ -155,7 +155,7 @@
                 (byte) ((address >> 8) & 0xFF),
                 (byte) (address & 0xFF),
                 // One byte device type
-                (byte) deviceType
+                (byte) (deviceType & 0xFF)
         };
         // <Report Physical Address> is broadcast message.
         return buildCommand(src, Constants.ADDR_BROADCAST,
@@ -194,7 +194,7 @@
      */
     static HdmiCecMessage buildCecVersion(int src, int dest, int version) {
         byte[] params = new byte[] {
-                (byte) version
+                (byte) (version & 0xFF)
         };
         return buildCommand(src, dest, Constants.MESSAGE_CEC_VERSION, params);
     }
@@ -332,7 +332,7 @@
      */
     static HdmiCecMessage buildReportPowerStatus(int src, int dest, int powerStatus) {
         byte[] param = new byte[] {
-                (byte) (powerStatus)
+                (byte) (powerStatus & 0xFF)
         };
         return buildCommand(src, dest, Constants.MESSAGE_REPORT_POWER_STATUS, param);
     }
@@ -347,7 +347,7 @@
      */
     static HdmiCecMessage buildReportMenuStatus(int src, int dest, int menuStatus) {
         byte[] param = new byte[] {
-                (byte) (menuStatus)
+                (byte) (menuStatus & 0xFF)
         };
         return buildCommand(src, dest, Constants.MESSAGE_MENU_STATUS, param);
     }
@@ -391,7 +391,7 @@
      * @return newly created {@link HdmiCecMessage}
      */
     static HdmiCecMessage buildUserControlPressed(int src, int dest, int uiCommand) {
-        return buildUserControlPressed(src, dest, new byte[] { (byte) uiCommand });
+        return buildUserControlPressed(src, dest, new byte[] { (byte) (uiCommand & 0xFF) });
     }
 
     /**
@@ -594,7 +594,7 @@
 
     private static byte[] physicalAddressToParam(int physicalAddress) {
         return new byte[] {
-                (byte) (physicalAddress >> 8),
+                (byte) ((physicalAddress >> 8) & 0xFF),
                 (byte) (physicalAddress & 0xFF)
         };
     }
diff --git a/services/core/java/com/android/server/hdmi/HdmiCecMessageValidator.java b/services/core/java/com/android/server/hdmi/HdmiCecMessageValidator.java
index 4c88ce0..d703989 100644
--- a/services/core/java/com/android/server/hdmi/HdmiCecMessageValidator.java
+++ b/services/core/java/com/android/server/hdmi/HdmiCecMessageValidator.java
@@ -17,7 +17,6 @@
 package com.android.server.hdmi;
 
 import android.hardware.hdmi.HdmiDeviceInfo;
-import android.util.Slog;
 import android.util.SparseArray;
 
 /**
@@ -26,6 +25,11 @@
 public final class HdmiCecMessageValidator {
     private static final String TAG = "HdmiCecMessageValidator";
 
+    static final int OK = 0;
+    static final int ERROR_SOURCE = 1;
+    static final int ERROR_DESTINATION = 2;
+    static final int ERROR_PARAMETER = 3;
+
     private final HdmiControlService mService;
 
     interface ParameterValidator {
@@ -141,7 +145,9 @@
         addValidationInfo(Constants.MESSAGE_SET_OSD_STRING, maxLengthValidator, DEST_DIRECT);
         addValidationInfo(Constants.MESSAGE_SET_OSD_NAME, maxLengthValidator, DEST_DIRECT);
 
-        // TODO: Handle messages for the Device Menu Control.
+        // Messages for the Device Menu Control.
+        addValidationInfo(Constants.MESSAGE_MENU_REQUEST, oneByteValidator, DEST_DIRECT);
+        addValidationInfo(Constants.MESSAGE_MENU_STATUS, oneByteValidator, DEST_DIRECT);
 
         // Messages for the Remote Control Passthrough.
         // TODO: Parse the first parameter and determine if it can have the next parameter.
@@ -179,39 +185,39 @@
         mValidationInfo.append(opcode, new ValidationInfo(validator, addrType));
     }
 
-    boolean isValid(HdmiCecMessage message) {
+    int isValid(HdmiCecMessage message) {
         int opcode = message.getOpcode();
         ValidationInfo info = mValidationInfo.get(opcode);
         if (info == null) {
-            Slog.w(TAG, "No validation information for the message: " + message);
-            return true;
+            HdmiLogger.warning("No validation information for the message: " + message);
+            return OK;
         }
 
         // Check the source field.
         if (message.getSource() == Constants.ADDR_UNREGISTERED &&
                 (info.addressType & SRC_UNREGISTERED) == 0) {
-            Slog.w(TAG, "Unexpected source: " + message);
-            return false;
+            HdmiLogger.warning("Unexpected source: " + message);
+            return ERROR_SOURCE;
         }
         // Check the destination field.
         if (message.getDestination() == Constants.ADDR_BROADCAST) {
             if ((info.addressType & DEST_BROADCAST) == 0) {
-                Slog.w(TAG, "Unexpected broadcast message: " + message);
-                return false;
+                HdmiLogger.warning("Unexpected broadcast message: " + message);
+                return ERROR_DESTINATION;
             }
         } else {  // Direct addressing.
             if ((info.addressType & DEST_DIRECT) == 0) {
-                Slog.w(TAG, "Unexpected direct message: " + message);
-                return false;
+                HdmiLogger.warning("Unexpected direct message: " + message);
+                return ERROR_DESTINATION;
             }
         }
 
         // Check the parameter type.
         if (!info.parameterValidator.isValid(message.getParams())) {
-            Slog.w(TAG, "Unexpected parameters: " + message);
-            return false;
+            HdmiLogger.warning("Unexpected parameters: " + message);
+            return ERROR_PARAMETER;
         }
-        return true;
+        return OK;
     }
 
     private static class FixedLengthValidator implements ParameterValidator {
diff --git a/services/core/java/com/android/server/hdmi/HdmiControlService.java b/services/core/java/com/android/server/hdmi/HdmiControlService.java
index 14c066e..4d9b4e9 100644
--- a/services/core/java/com/android/server/hdmi/HdmiControlService.java
+++ b/services/core/java/com/android/server/hdmi/HdmiControlService.java
@@ -16,6 +16,8 @@
 
 package com.android.server.hdmi;
 
+import static android.hardware.hdmi.HdmiControlManager.DEVICE_EVENT_ADD_DEVICE;
+import static android.hardware.hdmi.HdmiControlManager.DEVICE_EVENT_REMOVE_DEVICE;
 import static com.android.server.hdmi.Constants.DISABLED;
 import static com.android.server.hdmi.Constants.ENABLED;
 import static com.android.server.hdmi.Constants.OPTION_CEC_AUTO_WAKEUP;
@@ -41,6 +43,7 @@
 import android.hardware.hdmi.IHdmiDeviceEventListener;
 import android.hardware.hdmi.IHdmiHotplugEventListener;
 import android.hardware.hdmi.IHdmiInputChangeListener;
+import android.hardware.hdmi.IHdmiMhlVendorCommandListener;
 import android.hardware.hdmi.IHdmiRecordListener;
 import android.hardware.hdmi.IHdmiSystemAudioModeChangeListener;
 import android.hardware.hdmi.IHdmiVendorCommandListener;
@@ -64,6 +67,7 @@
 import android.util.SparseIntArray;
 
 import com.android.internal.annotations.GuardedBy;
+import com.android.internal.util.IndentingPrintWriter;
 import com.android.server.SystemService;
 import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly;
 import com.android.server.hdmi.HdmiCecController.AllocateAddressCallback;
@@ -72,10 +76,13 @@
 
 import libcore.util.EmptyArray;
 
+import java.io.FileDescriptor;
+import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
 import java.util.List;
+import java.util.Locale;
 
 /**
  * Provides a service for sending and processing HDMI control messages,
@@ -91,6 +98,7 @@
     static final int INITIATED_BY_BOOT_UP = 1;
     static final int INITIATED_BY_SCREEN_ON = 2;
     static final int INITIATED_BY_WAKE_UP_MESSAGE = 3;
+    static final int INITIATED_BY_HOTPLUG = 4;
 
     /**
      * Interface to report send result.
@@ -121,9 +129,11 @@
         void onPollingFinished(List<Integer> ackedAddress);
     }
 
-    private class PowerStateReceiver extends BroadcastReceiver {
+    private class HdmiControlBroadcastReceiver extends BroadcastReceiver {
+        @ServiceThreadOnly
         @Override
         public void onReceive(Context context, Intent intent) {
+            assertRunOnServiceThread();
             switch (intent.getAction()) {
                 case Intent.ACTION_SCREEN_OFF:
                     if (isPowerOnOrTransient()) {
@@ -135,6 +145,12 @@
                         onWakeUp();
                     }
                     break;
+                case Intent.ACTION_CONFIGURATION_CHANGED:
+                    String language = Locale.getDefault().getISO3Language();
+                    if (!mLanguage.equals(language)) {
+                        onLanguageChanged(language);
+                    }
+                    break;
             }
         }
     }
@@ -150,41 +166,25 @@
     // Type of logical devices hosted in the system. Stored in the unmodifiable list.
     private final List<Integer> mLocalDevices;
 
-    // List of listeners registered by callers that want to get notified of
-    // hotplug events.
-    @GuardedBy("mLock")
-    private final ArrayList<IHdmiHotplugEventListener> mHotplugEventListeners = new ArrayList<>();
-
     // List of records for hotplug event listener to handle the the caller killed in action.
     @GuardedBy("mLock")
     private final ArrayList<HotplugEventListenerRecord> mHotplugEventListenerRecords =
             new ArrayList<>();
 
-    // List of listeners registered by callers that want to get notified of
-    // device status events.
-    @GuardedBy("mLock")
-    private final ArrayList<IHdmiDeviceEventListener> mDeviceEventListeners = new ArrayList<>();
-
-    // List of records for device event listener to handle the the caller killed in action.
+    // List of records for device event listener to handle the caller killed in action.
     @GuardedBy("mLock")
     private final ArrayList<DeviceEventListenerRecord> mDeviceEventListenerRecords =
             new ArrayList<>();
 
-    // List of records for vendor command listener to handle the the caller killed in action.
+    // List of records for vendor command listener to handle the caller killed in action.
     @GuardedBy("mLock")
     private final ArrayList<VendorCommandListenerRecord> mVendorCommandListenerRecords =
             new ArrayList<>();
 
     @GuardedBy("mLock")
-    private IHdmiInputChangeListener mInputChangeListener;
-
-    @GuardedBy("mLock")
     private InputChangeListenerRecord mInputChangeListenerRecord;
 
     @GuardedBy("mLock")
-    private IHdmiRecordListener mRecordListener;
-
-    @GuardedBy("mLock")
     private HdmiRecordListenerRecord mRecordListenerRecord;
 
     // Set to true while HDMI control is enabled. If set to false, HDMI-CEC/MHL protocol
@@ -198,14 +198,6 @@
     @GuardedBy("mLock")
     private boolean mProhibitMode;
 
-    // Set to true while the input change by MHL is allowed.
-    @GuardedBy("mLock")
-    private boolean mMhlInputChangeEnabled;
-
-    // List of listeners registered by callers that want to get notified of
-    // system audio mode changes.
-    private final ArrayList<IHdmiSystemAudioModeChangeListener>
-            mSystemAudioModeChangeListeners = new ArrayList<>();
     // List of records for system audio mode change to handle the the caller killed in action.
     private final ArrayList<SystemAudioModeChangeListenerRecord>
             mSystemAudioModeChangeListenerRecords = new ArrayList<>();
@@ -215,11 +207,11 @@
 
     private final SettingsObserver mSettingsObserver;
 
-    @Nullable
-    private HdmiCecController mCecController;
+    private final HdmiControlBroadcastReceiver
+            mHdmiControlBroadcastReceiver = new HdmiControlBroadcastReceiver();
 
     @Nullable
-    private HdmiMhlController mMhlController;
+    private HdmiCecController mCecController;
 
     // HDMI port information. Stored in the unmodifiable list to keep the static information
     // from being modified.
@@ -231,14 +223,18 @@
     // Map from port ID to HdmiPortInfo.
     private UnmodifiableSparseArray<HdmiPortInfo> mPortInfoMap;
 
-    private HdmiCecMessageValidator mMessageValidator;
+    // Map from port ID to HdmiDeviceInfo.
+    private UnmodifiableSparseArray<HdmiDeviceInfo> mPortDeviceMap;
 
-    private final PowerStateReceiver mPowerStateReceiver = new PowerStateReceiver();
+    private HdmiCecMessageValidator mMessageValidator;
 
     @ServiceThreadOnly
     private int mPowerStatus = HdmiControlManager.POWER_STATUS_STANDBY;
 
     @ServiceThreadOnly
+    private String mLanguage = Locale.getDefault().getISO3Language();
+
+    @ServiceThreadOnly
     private boolean mStandbyMessageReceived = false;
 
     @ServiceThreadOnly
@@ -247,6 +243,27 @@
     @ServiceThreadOnly
     private int mActivePortId = Constants.INVALID_PORT_ID;
 
+    // Set to true while the input change by MHL is allowed.
+    @GuardedBy("mLock")
+    private boolean mMhlInputChangeEnabled;
+
+    // List of records for MHL Vendor command listener to handle the caller killed in action.
+    @GuardedBy("mLock")
+    private final ArrayList<HdmiMhlVendorCommandListenerRecord>
+            mMhlVendorCommandListenerRecords = new ArrayList<>();
+
+    @GuardedBy("mLock")
+    private List<HdmiDeviceInfo> mMhlDevices;
+
+    @Nullable
+    private HdmiMhlControllerStub mMhlController;
+
+    // Last input port before switching to the MHL port. Should switch back to this port
+    // when the mobile device sends the request one touch play with off.
+    // Gets invalidated if we go to other port/input.
+    @ServiceThreadOnly
+    private int mLastInputMhl = Constants.INVALID_PORT_ID;
+
     public HdmiControlService(Context context) {
         super(context);
         mLocalDevices = getIntList(SystemProperties.get(Constants.PROPERTY_DEVICE_TYPE));
@@ -288,20 +305,23 @@
             Slog.i(TAG, "Device does not support HDMI-CEC.");
         }
 
-        mMhlController = HdmiMhlController.create(this);
-        if (mMhlController == null) {
+        mMhlController = HdmiMhlControllerStub.create(this);
+        if (!mMhlController.isReady()) {
             Slog.i(TAG, "Device does not support MHL-control.");
         }
+        mMhlDevices = Collections.emptyList();
+
         initPortInfo();
         mMessageValidator = new HdmiCecMessageValidator(this);
         publishBinderService(Context.HDMI_CONTROL_SERVICE, new BinderService());
 
         // Register broadcast receiver for power state change.
-        if (mCecController != null || mMhlController != null) {
+        if (mCecController != null) {
             IntentFilter filter = new IntentFilter();
             filter.addAction(Intent.ACTION_SCREEN_OFF);
             filter.addAction(Intent.ACTION_SCREEN_ON);
-            getContext().registerReceiver(mPowerStateReceiver, filter);
+            filter.addAction(Intent.ACTION_CONFIGURATION_CHANGED);
+            getContext().registerReceiver(mHdmiControlBroadcastReceiver, filter);
         }
     }
 
@@ -320,7 +340,6 @@
         }
     }
 
-
     private void registerContentObserver() {
         ContentResolver resolver = getContext().getContentResolver();
         String[] settings = new String[] {
@@ -330,7 +349,7 @@
                 Global.MHL_INPUT_SWITCHING_ENABLED,
                 Global.MHL_POWER_CHARGE_ENABLED
         };
-        for (String s: settings) {
+        for (String s : settings) {
             resolver.registerContentObserver(Global.getUriFor(s), false, mSettingsObserver,
                     UserHandle.USER_ALL);
         }
@@ -341,6 +360,7 @@
             super(handler);
         }
 
+        // onChange is set up to run in service thread.
         @Override
         public void onChange(boolean selfChange, Uri uri) {
             String option = uri.getLastPathSegment();
@@ -351,7 +371,7 @@
                     break;
                 case Global.HDMI_CONTROL_AUTO_WAKEUP_ENABLED:
                     tv().setAutoWakeup(enabled);
-                    setOption(OPTION_CEC_AUTO_WAKEUP, toInt(enabled));
+                    setCecOption(OPTION_CEC_AUTO_WAKEUP, toInt(enabled));
                     break;
                 case Global.HDMI_CONTROL_AUTO_DEVICE_OFF_ENABLED:
                     tv().setAutoDeviceOff(enabled);
@@ -361,9 +381,7 @@
                     setMhlInputChangeEnabled(enabled);
                     break;
                 case Global.MHL_POWER_CHARGE_ENABLED:
-                    if (mMhlController != null) {
-                        mMhlController.setOption(OPTION_MHL_POWER_CHARGE, toInt(enabled));
-                    }
+                    mMhlController.setOption(OPTION_MHL_POWER_CHARGE, toInt(enabled));
                     break;
             }
         }
@@ -389,20 +407,32 @@
 
     private void initializeCec(int initiatedBy) {
         mCecController.setOption(OPTION_CEC_SERVICE_CONTROL, ENABLED);
-        initializeLocalDevices(mLocalDevices, initiatedBy);
+        initializeLocalDevices(initiatedBy);
     }
 
     @ServiceThreadOnly
-    private void initializeLocalDevices(final List<Integer> deviceTypes, final int initiatedBy) {
+    private void initializeLocalDevices(final int initiatedBy) {
         assertRunOnServiceThread();
-        // A container for [Logical Address, Local device info].
-        final SparseArray<HdmiCecLocalDevice> devices = new SparseArray<>();
-        final int[] finished = new int[1];
+        // A container for [Device type, Local device info].
+        ArrayList<HdmiCecLocalDevice> localDevices = new ArrayList<>();
         clearLocalDevices();
-        for (int type : deviceTypes) {
+        for (int type : mLocalDevices) {
             final HdmiCecLocalDevice localDevice = HdmiCecLocalDevice.create(this, type);
             localDevice.init();
-            mCecController.allocateLogicalAddress(type,
+            localDevices.add(localDevice);
+        }
+        allocateLogicalAddress(localDevices, initiatedBy);
+    }
+
+    @ServiceThreadOnly
+    private void allocateLogicalAddress(final ArrayList<HdmiCecLocalDevice> allocatingDevices,
+            final int initiatedBy) {
+        assertRunOnServiceThread();
+        mCecController.clearLogicalAddress();
+        final ArrayList<HdmiCecLocalDevice> allocatedDevices = new ArrayList<>();
+        final int[] finished = new int[1];
+        for (final HdmiCecLocalDevice localDevice : allocatingDevices) {
+            mCecController.allocateLogicalAddress(localDevice.getType(),
                     localDevice.getPreferredAddress(), new AllocateAddressCallback() {
                 @Override
                 public void onAllocated(int deviceType, int logicalAddress) {
@@ -416,13 +446,17 @@
                         localDevice.setDeviceInfo(deviceInfo);
                         mCecController.addLocalDevice(deviceType, localDevice);
                         mCecController.addLogicalAddress(logicalAddress);
-                        devices.append(logicalAddress, localDevice);
+                        allocatedDevices.add(localDevice);
                     }
 
                     // Address allocation completed for all devices. Notify each device.
-                    if (deviceTypes.size() == ++finished[0]) {
-                        onInitializeCecComplete();
-                        notifyAddressAllocated(devices, initiatedBy);
+                    if (allocatingDevices.size() == ++finished[0]) {
+                        if (initiatedBy != INITIATED_BY_HOTPLUG) {
+                            // In case of the hotplug we don't call onInitializeCecComplete()
+                            // since we reallocate the logical address only.
+                            onInitializeCecComplete();
+                        }
+                        notifyAddressAllocated(allocatedDevices, initiatedBy);
                     }
                 }
             });
@@ -430,11 +464,10 @@
     }
 
     @ServiceThreadOnly
-    private void notifyAddressAllocated(SparseArray<HdmiCecLocalDevice> devices, int initiatedBy) {
+    private void notifyAddressAllocated(ArrayList<HdmiCecLocalDevice> devices, int initiatedBy) {
         assertRunOnServiceThread();
-        for (int i = 0; i < devices.size(); ++i) {
-            int address = devices.keyAt(i);
-            HdmiCecLocalDevice device = devices.valueAt(i);
+        for (HdmiCecLocalDevice device : devices) {
+            int address = device.getDeviceInfo().getLogicalAddress();
             device.handleAddressAllocated(address, initiatedBy);
         }
     }
@@ -457,37 +490,44 @@
 
         SparseArray<HdmiPortInfo> portInfoMap = new SparseArray<>();
         SparseIntArray portIdMap = new SparseIntArray();
+        SparseArray<HdmiDeviceInfo> portDeviceMap = new SparseArray<>();
         for (HdmiPortInfo info : cecPortInfo) {
             portIdMap.put(info.getAddress(), info.getId());
             portInfoMap.put(info.getId(), info);
+            portDeviceMap.put(info.getId(), new HdmiDeviceInfo(info.getAddress(), info.getId()));
         }
         mPortIdMap = new UnmodifiableSparseIntArray(portIdMap);
         mPortInfoMap = new UnmodifiableSparseArray<>(portInfoMap);
+        mPortDeviceMap = new UnmodifiableSparseArray<>(portDeviceMap);
 
-        if (mMhlController == null) {
+        HdmiPortInfo[] mhlPortInfo = mMhlController.getPortInfos();
+        ArraySet<Integer> mhlSupportedPorts = new ArraySet<Integer>(mhlPortInfo.length);
+        for (HdmiPortInfo info : mhlPortInfo) {
+            if (info.isMhlSupported()) {
+                mhlSupportedPorts.add(info.getId());
+            }
+        }
+
+        // Build HDMI port info list with CEC port info plus MHL supported flag. We can just use
+        // cec port info if we do not have have port that supports MHL.
+        if (mhlSupportedPorts.isEmpty()) {
             mPortInfo = Collections.unmodifiableList(Arrays.asList(cecPortInfo));
             return;
-        } else {
-            HdmiPortInfo[] mhlPortInfo = mMhlController.getPortInfos();
-            ArraySet<Integer> mhlSupportedPorts = new ArraySet<Integer>(mhlPortInfo.length);
-            for (HdmiPortInfo info : mhlPortInfo) {
-                if (info.isMhlSupported()) {
-                    mhlSupportedPorts.add(info.getId());
-                }
-            }
-
-            // Build HDMI port info list with CEC port info plus MHL supported flag.
-            ArrayList<HdmiPortInfo> result = new ArrayList<>(cecPortInfo.length);
-            for (HdmiPortInfo info : cecPortInfo) {
-                if (mhlSupportedPorts.contains(info.getId())) {
-                    result.add(new HdmiPortInfo(info.getId(), info.getType(), info.getAddress(),
-                            info.isCecSupported(), true, info.isArcSupported()));
-                } else {
-                    result.add(info);
-                }
-            }
-            mPortInfo = Collections.unmodifiableList(result);
         }
+        ArrayList<HdmiPortInfo> result = new ArrayList<>(cecPortInfo.length);
+        for (HdmiPortInfo info : cecPortInfo) {
+            if (mhlSupportedPorts.contains(info.getId())) {
+                result.add(new HdmiPortInfo(info.getId(), info.getType(), info.getAddress(),
+                        info.isCecSupported(), true, info.isArcSupported()));
+            } else {
+                result.add(info);
+            }
+        }
+        mPortInfo = Collections.unmodifiableList(result);
+    }
+
+    List<HdmiPortInfo> getPortInfo() {
+        return mPortInfo;
     }
 
     /**
@@ -582,7 +622,7 @@
      * Whether a device of the specified physical address is connected to ARC enabled port.
      */
     boolean isConnectedToArcPort(int physicalAddress) {
-        int portId = mPortIdMap.get(physicalAddress);
+        int portId = pathToPortId(physicalAddress);
         if (portId != Constants.INVALID_PORT_ID) {
             return mPortInfoMap.get(portId).isArcSupported();
         }
@@ -612,10 +652,10 @@
     @ServiceThreadOnly
     void sendCecCommand(HdmiCecMessage command, @Nullable SendMessageCallback callback) {
         assertRunOnServiceThread();
-        if (mMessageValidator.isValid(command)) {
+        if (mMessageValidator.isValid(command) == HdmiCecMessageValidator.OK) {
             mCecController.sendCommand(command, callback);
         } else {
-            Slog.e(TAG, "Invalid message type:" + command);
+            HdmiLogger.error("Invalid message type:" + command);
             if (callback != null) {
                 callback.onSendCompleted(Constants.SEND_RESULT_FAILURE);
             }
@@ -628,18 +668,6 @@
         sendCecCommand(command, null);
     }
 
-    @ServiceThreadOnly
-    void sendMhlSubcommand(int portId, HdmiMhlSubcommand command) {
-        assertRunOnServiceThread();
-        sendMhlSubcommand(portId, command, null);
-    }
-
-    @ServiceThreadOnly
-    void sendMhlSubcommand(int portId, HdmiMhlSubcommand command, SendMessageCallback callback) {
-        assertRunOnServiceThread();
-        mMhlController.sendSubcommand(portId, command, callback);
-    }
-
     /**
      * Send <Feature Abort> command on the given CEC message if possible.
      * If the aborted message is invalid, then it wont send the message.
@@ -655,8 +683,13 @@
     @ServiceThreadOnly
     boolean handleCecCommand(HdmiCecMessage message) {
         assertRunOnServiceThread();
-        if (!mMessageValidator.isValid(message)) {
-            return false;
+        int errorCode = mMessageValidator.isValid(message);
+        if (errorCode != HdmiCecMessageValidator.OK) {
+            // We'll not response on the messages with the invalid source or destination.
+            if (errorCode == HdmiCecMessageValidator.ERROR_PARAMETER) {
+                maySendFeatureAbortCommand(message, Constants.ABORT_INVALID_OPERAND);
+            }
+            return true;
         }
         return dispatchMessageToLocalDevice(message);
     }
@@ -676,7 +709,7 @@
         }
 
         if (message.getDestination() != Constants.ADDR_BROADCAST) {
-            Slog.w(TAG, "Unhandled cec command:" + message);
+            HdmiLogger.warning("Unhandled cec command:" + message);
         }
         return false;
     }
@@ -684,16 +717,32 @@
     /**
      * Called when a new hotplug event is issued.
      *
-     * @param portNo hdmi port number where hot plug event issued.
+     * @param portId hdmi port number where hot plug event issued.
      * @param connected whether to be plugged in or not
      */
     @ServiceThreadOnly
-    void onHotplug(int portNo, boolean connected) {
+    void onHotplug(int portId, boolean connected) {
         assertRunOnServiceThread();
-        for (HdmiCecLocalDevice device : mCecController.getLocalDeviceList()) {
-            device.onHotplug(portNo, connected);
+
+        ArrayList<HdmiCecLocalDevice> localDevices = new ArrayList<>();
+        for (int type : mLocalDevices) {
+            if (type == HdmiDeviceInfo.DEVICE_TV) {
+                // Skip the reallocation of the logical address on TV.
+                continue;
+            }
+            HdmiCecLocalDevice localDevice = mCecController.getLocalDevice(type);
+            if (localDevice == null) {
+                localDevice = HdmiCecLocalDevice.create(this, type);
+                localDevice.init();
+            }
+            localDevices.add(localDevice);
         }
-        announceHotplugEvent(portNo, connected);
+        allocateLogicalAddress(localDevices, INITIATED_BY_HOTPLUG);
+
+        for (HdmiCecLocalDevice device : mCecController.getLocalDeviceList()) {
+            device.onHotplug(portId, connected);
+        }
+        announceHotplugEvent(portId, connected);
     }
 
     /**
@@ -749,14 +798,16 @@
             // FLAG_HDMI_SYSTEM_AUDIO_VOLUME prevents audio manager from announcing
             // volume change notification back to hdmi control service.
             audioManager.setStreamVolume(AudioManager.STREAM_MUSIC, volume,
-                    AudioManager.FLAG_SHOW_UI |
-                    AudioManager.FLAG_HDMI_SYSTEM_AUDIO_VOLUME);
+                    AudioManager.FLAG_SHOW_UI | AudioManager.FLAG_HDMI_SYSTEM_AUDIO_VOLUME);
         }
     }
 
     void announceSystemAudioModeChange(boolean enabled) {
-        for (IHdmiSystemAudioModeChangeListener listener : mSystemAudioModeChangeListeners) {
-            invokeSystemAudioModeChange(listener, enabled);
+        synchronized (mLock) {
+            for (SystemAudioModeChangeListenerRecord record :
+                    mSystemAudioModeChangeListenerRecords) {
+                invokeSystemAudioModeChangeLocked(record.mListener, enabled);
+            }
         }
     }
 
@@ -769,73 +820,109 @@
     }
 
     @ServiceThreadOnly
-    boolean handleMhlSubcommand(int portId, HdmiMhlSubcommand message) {
-        assertRunOnServiceThread();
-
-        HdmiMhlLocalDevice device = mMhlController.getLocalDevice(portId);
-        if (device != null) {
-            return device.handleSubcommand(message);
-        }
-        Slog.w(TAG, "No mhl device exists[portId:" + portId + ", message:" + message);
-        return false;
-    }
-
-    @ServiceThreadOnly
     void handleMhlHotplugEvent(int portId, boolean connected) {
         assertRunOnServiceThread();
         if (connected) {
-            HdmiMhlLocalDevice newDevice = new HdmiMhlLocalDevice(this, portId);
-            HdmiMhlLocalDevice oldDevice = mMhlController.addLocalDevice(newDevice);
+            HdmiMhlLocalDeviceStub newDevice = new HdmiMhlLocalDeviceStub(this, portId);
+            HdmiMhlLocalDeviceStub oldDevice = mMhlController.addLocalDevice(newDevice);
             if (oldDevice != null) {
                 oldDevice.onDeviceRemoved();
                 Slog.i(TAG, "Old device of port " + portId + " is removed");
             }
         } else {
-            HdmiMhlLocalDevice device = mMhlController.removeLocalDevice(portId);
+            HdmiMhlLocalDeviceStub device = mMhlController.removeLocalDevice(portId);
             if (device != null) {
                 device.onDeviceRemoved();
+                // There is no explicit event for device removal.
+                // Hence we remove the device on hotplug event.
+                HdmiDeviceInfo deviceInfo = device.getInfo();
+                if (deviceInfo != null) {
+                    invokeDeviceEventListeners(deviceInfo, DEVICE_EVENT_REMOVE_DEVICE);
+                    updateSafeMhlInput();
+                }
             } else {
                 Slog.w(TAG, "No device to remove:[portId=" + portId);
             }
         }
+        announceHotplugEvent(portId, connected);
     }
 
     @ServiceThreadOnly
-    void handleMhlCbusModeChanged(int portId, int cbusmode) {
+    void handleMhlBusModeChanged(int portId, int busmode) {
         assertRunOnServiceThread();
-        HdmiMhlLocalDevice device = mMhlController.getLocalDevice(portId);
+        HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(portId);
         if (device != null) {
-            device.setCbusMode(cbusmode);
+            device.setBusMode(busmode);
         } else {
-            Slog.w(TAG, "No mhl device exists for cbus mode change[portId:" + portId +
-                    ", cbusmode:" + cbusmode + "]");
+            Slog.w(TAG, "No mhl device exists for bus mode change[portId:" + portId +
+                    ", busmode:" + busmode + "]");
         }
     }
 
     @ServiceThreadOnly
-    void handleMhlVbusOvercurrent(int portId, boolean on) {
+    void handleMhlBusOvercurrent(int portId, boolean on) {
         assertRunOnServiceThread();
-        HdmiMhlLocalDevice device = mMhlController.getLocalDevice(portId);
+        HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(portId);
         if (device != null) {
-            device.onVbusOvercurrentDetected(on);
+            device.onBusOvercurrentDetected(on);
         } else {
-            Slog.w(TAG, "No mhl device exists for vbus overcurrent event[portId:" + portId + "]");
+            Slog.w(TAG, "No mhl device exists for bus overcurrent event[portId:" + portId + "]");
         }
     }
 
     @ServiceThreadOnly
-    void handleCapabilityRegisterChanged(int portId, int adopterId, int deviceId) {
+    void handleMhlDeviceStatusChanged(int portId, int adopterId, int deviceId) {
         assertRunOnServiceThread();
-        HdmiMhlLocalDevice device = mMhlController.getLocalDevice(portId);
-        // Hot plug event should be called before capability register change event.
+        HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(portId);
+
+        // Hotplug event should already have been called before device status change event.
         if (device != null) {
-            device.setCapabilityRegister(adopterId, deviceId);
+            device.setDeviceStatusChange(adopterId, deviceId);
+            invokeDeviceEventListeners(device.getInfo(), DEVICE_EVENT_ADD_DEVICE);
+            updateSafeMhlInput();
         } else {
-            Slog.w(TAG, "No mhl device exists for capability register change event[portId:"
+            Slog.w(TAG, "No mhl device exists for device status event[portId:"
                     + portId + ", adopterId:" + adopterId + ", deviceId:" + deviceId + "]");
         }
     }
 
+    @ServiceThreadOnly
+    private void updateSafeMhlInput() {
+        assertRunOnServiceThread();
+        List<HdmiDeviceInfo> inputs = Collections.emptyList();
+        SparseArray<HdmiMhlLocalDeviceStub> devices = mMhlController.getAllLocalDevices();
+        for (int i = 0; i < devices.size(); ++i) {
+            HdmiMhlLocalDeviceStub device = devices.valueAt(i);
+            HdmiDeviceInfo info = device.getInfo();
+            if (info != null) {
+                if (inputs.isEmpty()) {
+                    inputs = new ArrayList<>();
+                }
+                inputs.add(device.getInfo());
+            }
+        }
+        synchronized (mLock) {
+            mMhlDevices = inputs;
+        }
+    }
+
+    private List<HdmiDeviceInfo> getMhlDevicesLocked() {
+        return mMhlDevices;
+    }
+
+    private class HdmiMhlVendorCommandListenerRecord implements IBinder.DeathRecipient {
+        private final IHdmiMhlVendorCommandListener mListener;
+
+        public HdmiMhlVendorCommandListenerRecord(IHdmiMhlVendorCommandListener listener) {
+            mListener = listener;
+        }
+
+        @Override
+        public void binderDied() {
+            mMhlVendorCommandListenerRecords.remove(this);
+        }
+    }
+
     // Record class that monitors the event of the caller of being killed. Used to clean up
     // the listener list and record list accordingly.
     private final class HotplugEventListenerRecord implements IBinder.DeathRecipient {
@@ -849,7 +936,6 @@
         public void binderDied() {
             synchronized (mLock) {
                 mHotplugEventListenerRecords.remove(this);
-                mHotplugEventListeners.remove(mListener);
             }
         }
     }
@@ -865,7 +951,6 @@
         public void binderDied() {
             synchronized (mLock) {
                 mDeviceEventListenerRecords.remove(this);
-                mDeviceEventListeners.remove(mListener);
             }
         }
     }
@@ -881,7 +966,6 @@
         public void binderDied() {
             synchronized (mLock) {
                 mSystemAudioModeChangeListenerRecords.remove(this);
-                mSystemAudioModeChangeListeners.remove(mListener);
             }
         }
     }
@@ -904,10 +988,16 @@
     }
 
     private class HdmiRecordListenerRecord implements IBinder.DeathRecipient {
+        private final IHdmiRecordListener mListener;
+
+        public HdmiRecordListenerRecord(IHdmiRecordListener listener) {
+            mListener = listener;
+        }
+
         @Override
         public void binderDied() {
             synchronized (mLock) {
-                mRecordListener = null;
+                mRecordListenerRecord = null;
             }
         }
     }
@@ -964,6 +1054,19 @@
                         invokeCallback(callback, HdmiControlManager.RESULT_SOURCE_NOT_AVAILABLE);
                         return;
                     }
+                    HdmiMhlLocalDeviceStub device = mMhlController.getLocalDeviceById(deviceId);
+                    if (device != null) {
+                        if (device.getPortId() == tv.getActivePortId()) {
+                            invokeCallback(callback, HdmiControlManager.RESULT_SUCCESS);
+                            return;
+                        }
+                        // Upon selecting MHL device, we send RAP[Content On] to wake up
+                        // the connected mobile device, start routing control to switch ports.
+                        // callback is handled by MHL action.
+                        device.turnOn(callback);
+                        tv.doManualPortSwitching(device.getPortId(), null);
+                        return;
+                    }
                     tv.deviceSelect(deviceId, callback);
                 }
             });
@@ -996,12 +1099,10 @@
             runOnServiceThread(new Runnable() {
                 @Override
                 public void run() {
-                    if (mMhlController != null) {
-                        HdmiMhlLocalDevice device = mMhlController.getLocalDevice(mActivePortId);
-                        if (device != null) {
-                            device.sendKeyEvent(keyCode, isPressed);
-                            return;
-                        }
+                    HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(mActivePortId);
+                    if (device != null) {
+                        device.sendKeyEvent(keyCode, isPressed);
+                        return;
                     }
                     if (mCecController != null) {
                         HdmiCecLocalDevice localDevice = mCecController.getLocalDevice(deviceType);
@@ -1040,40 +1141,25 @@
         @Override
         public void addHotplugEventListener(final IHdmiHotplugEventListener listener) {
             enforceAccessPermission();
-            runOnServiceThread(new Runnable() {
-                @Override
-                public void run() {
-                    HdmiControlService.this.addHotplugEventListener(listener);
-                }
-            });
+            HdmiControlService.this.addHotplugEventListener(listener);
         }
 
         @Override
         public void removeHotplugEventListener(final IHdmiHotplugEventListener listener) {
             enforceAccessPermission();
-            runOnServiceThread(new Runnable() {
-                @Override
-                public void run() {
-                    HdmiControlService.this.removeHotplugEventListener(listener);
-                }
-            });
+            HdmiControlService.this.removeHotplugEventListener(listener);
         }
 
         @Override
         public void addDeviceEventListener(final IHdmiDeviceEventListener listener) {
             enforceAccessPermission();
-            runOnServiceThread(new Runnable() {
-                @Override
-                public void run() {
-                    HdmiControlService.this.addDeviceEventListener(listener);
-                }
-            });
+            HdmiControlService.this.addDeviceEventListener(listener);
         }
 
         @Override
         public List<HdmiPortInfo> getPortInfo() {
             enforceAccessPermission();
-            return mPortInfo;
+            return HdmiControlService.this.getPortInfo();
         }
 
         @Override
@@ -1139,10 +1225,12 @@
             // No need to hold the lock for obtaining TV device as the local device instance
             // is preserved while the HDMI control is enabled.
             HdmiCecLocalDeviceTv tv = tv();
-            if (tv == null) {
-                return Collections.emptyList();
+            synchronized (mLock) {
+                List<HdmiDeviceInfo> cecDevices = (tv == null)
+                        ? Collections.<HdmiDeviceInfo>emptyList()
+                        : tv.getSafeExternalInputsLocked();
+                return HdmiUtils.mergeToUnmodifiableList(cecDevices, getMhlDevicesLocked());
             }
-            return tv.getSafeExternalInputs();
         }
 
         @Override
@@ -1206,12 +1294,7 @@
         public void addVendorCommandListener(final IHdmiVendorCommandListener listener,
                 final int deviceType) {
             enforceAccessPermission();
-            runOnServiceThread(new Runnable() {
-                @Override
-                public void run() {
-                    HdmiControlService.this.addVendorCommandListener(listener, deviceType);
-                }
-            });
+            HdmiControlService.this.addVendorCommandListener(listener, deviceType);
         }
 
         @Override
@@ -1239,6 +1322,22 @@
         }
 
         @Override
+        public void sendStandby(final int deviceType, final int deviceId) {
+            enforceAccessPermission();
+            runOnServiceThread(new Runnable() {
+                @Override
+                public void run() {
+                    HdmiCecLocalDevice device = mCecController.getLocalDevice(deviceType);
+                    if (device == null) {
+                        Slog.w(TAG, "Local device not available");
+                        return;
+                    }
+                    device.sendStandby(deviceId);
+                }
+            });
+        }
+
+        @Override
         public void setHdmiRecordListener(IHdmiRecordListener listener) {
             HdmiControlService.this.setHdmiRecordListener(listener);
         }
@@ -1300,6 +1399,56 @@
                 }
             });
         }
+
+        @Override
+        public void sendMhlVendorCommand(final int portId, final int offset, final int length,
+                final byte[] data) {
+            enforceAccessPermission();
+            runOnServiceThread(new Runnable() {
+                @Override
+                public void run() {
+                    if (!isControlEnabled()) {
+                        Slog.w(TAG, "Hdmi control is disabled.");
+                        return ;
+                    }
+                    HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(portId);
+                    if (device == null) {
+                        Slog.w(TAG, "Invalid port id:" + portId);
+                        return;
+                    }
+                    mMhlController.sendVendorCommand(portId, offset, length, data);
+                }
+            });
+        }
+
+        @Override
+        public void addHdmiMhlVendorCommandListener(
+                IHdmiMhlVendorCommandListener listener) {
+            enforceAccessPermission();
+            HdmiControlService.this.addHdmiMhlVendorCommandListener(listener);
+        }
+
+        @Override
+        protected void dump(FileDescriptor fd, final PrintWriter writer, String[] args) {
+            getContext().enforceCallingOrSelfPermission(android.Manifest.permission.DUMP, TAG);
+            final IndentingPrintWriter pw = new IndentingPrintWriter(writer, "  ");
+
+            pw.println("mHdmiControlEnabled: " + mHdmiControlEnabled);
+            pw.println("mProhibitMode: " + mProhibitMode);
+            if (mCecController != null) {
+                pw.println("mCecController: ");
+                pw.increaseIndent();
+                mCecController.dump(pw);
+                pw.decreaseIndent();
+            }
+            pw.println("mPortInfo: ");
+            pw.increaseIndent();
+            for (HdmiPortInfo hdmiPortInfo : mPortInfo) {
+                pw.println("- " + hdmiPortInfo);
+            }
+            pw.decreaseIndent();
+            pw.println("mPowerStatus: " + mPowerStatus);
+        }
     }
 
     @ServiceThreadOnly
@@ -1336,7 +1485,6 @@
         }
         synchronized (mLock) {
             mHotplugEventListenerRecords.add(record);
-            mHotplugEventListeners.add(listener);
         }
     }
 
@@ -1349,7 +1497,6 @@
                     break;
                 }
             }
-            mHotplugEventListeners.remove(listener);
         }
     }
 
@@ -1362,16 +1509,15 @@
             return;
         }
         synchronized (mLock) {
-            mDeviceEventListeners.add(listener);
             mDeviceEventListenerRecords.add(record);
         }
     }
 
     void invokeDeviceEventListeners(HdmiDeviceInfo device, int status) {
         synchronized (mLock) {
-            for (IHdmiDeviceEventListener listener : mDeviceEventListeners) {
+            for (DeviceEventListenerRecord record : mDeviceEventListenerRecords) {
                 try {
-                    listener.onStatusChanged(device, status);
+                    record.mListener.onStatusChanged(device, status);
                 } catch (RemoteException e) {
                     Slog.e(TAG, "Failed to report device event:" + e);
                 }
@@ -1389,7 +1535,6 @@
             return;
         }
         synchronized (mLock) {
-            mSystemAudioModeChangeListeners.add(listener);
             mSystemAudioModeChangeListenerRecords.add(record);
         }
     }
@@ -1404,37 +1549,41 @@
                     break;
                 }
             }
-            mSystemAudioModeChangeListeners.remove(listener);
         }
     }
 
     private final class InputChangeListenerRecord implements IBinder.DeathRecipient {
+        private final IHdmiInputChangeListener mListener;
+
+        public InputChangeListenerRecord(IHdmiInputChangeListener listener) {
+            mListener = listener;
+        }
+
         @Override
         public void binderDied() {
             synchronized (mLock) {
-                mInputChangeListener = null;
+                mInputChangeListenerRecord = null;
             }
         }
     }
 
     private void setInputChangeListener(IHdmiInputChangeListener listener) {
         synchronized (mLock) {
-            mInputChangeListenerRecord = new InputChangeListenerRecord();
+            mInputChangeListenerRecord = new InputChangeListenerRecord(listener);
             try {
                 listener.asBinder().linkToDeath(mInputChangeListenerRecord, 0);
             } catch (RemoteException e) {
                 Slog.w(TAG, "Listener already died");
                 return;
             }
-            mInputChangeListener = listener;
         }
     }
 
     void invokeInputChangeListener(HdmiDeviceInfo info) {
         synchronized (mLock) {
-            if (mInputChangeListener != null) {
+            if (mInputChangeListenerRecord != null) {
                 try {
-                    mInputChangeListener.onChanged(info);
+                    mInputChangeListenerRecord.mListener.onChanged(info);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Exception thrown by IHdmiInputChangeListener: " + e);
                 }
@@ -1444,21 +1593,20 @@
 
     private void setHdmiRecordListener(IHdmiRecordListener listener) {
         synchronized (mLock) {
-            mRecordListenerRecord = new HdmiRecordListenerRecord();
+            mRecordListenerRecord = new HdmiRecordListenerRecord(listener);
             try {
                 listener.asBinder().linkToDeath(mRecordListenerRecord, 0);
             } catch (RemoteException e) {
                 Slog.w(TAG, "Listener already died.", e);
             }
-            mRecordListener = listener;
         }
     }
 
     byte[] invokeRecordRequestListener(int recorderAddress) {
         synchronized (mLock) {
-            if (mRecordListener != null) {
+            if (mRecordListenerRecord != null) {
                 try {
-                    return mRecordListener.getOneTouchRecordSource(recorderAddress);
+                    return mRecordListenerRecord.mListener.getOneTouchRecordSource(recorderAddress);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Failed to start record.", e);
                 }
@@ -1469,9 +1617,9 @@
 
     void invokeOneTouchRecordResult(int result) {
         synchronized (mLock) {
-            if (mRecordListener != null) {
+            if (mRecordListenerRecord != null) {
                 try {
-                    mRecordListener.onOneTouchRecordResult(result);
+                    mRecordListenerRecord.mListener.onOneTouchRecordResult(result);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Failed to call onOneTouchRecordResult.", e);
                 }
@@ -1481,9 +1629,9 @@
 
     void invokeTimerRecordingResult(int result) {
         synchronized (mLock) {
-            if (mRecordListener != null) {
+            if (mRecordListenerRecord != null) {
                 try {
-                    mRecordListener.onTimerRecordingResult(result);
+                    mRecordListenerRecord.mListener.onTimerRecordingResult(result);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Failed to call onTimerRecordingResult.", e);
                 }
@@ -1493,9 +1641,9 @@
 
     void invokeClearTimerRecordingResult(int result) {
         synchronized (mLock) {
-            if (mRecordListener != null) {
+            if (mRecordListenerRecord != null) {
                 try {
-                    mRecordListener.onClearTimerRecordingResult(result);
+                    mRecordListenerRecord.mListener.onClearTimerRecordingResult(result);
                 } catch (RemoteException e) {
                     Slog.w(TAG, "Failed to call onClearTimerRecordingResult.", e);
                 }
@@ -1511,7 +1659,7 @@
         }
     }
 
-    private void invokeSystemAudioModeChange(IHdmiSystemAudioModeChangeListener listener,
+    private void invokeSystemAudioModeChangeLocked(IHdmiSystemAudioModeChangeListener listener,
             boolean enabled) {
         try {
             listener.onStatusChanged(enabled);
@@ -1523,8 +1671,8 @@
     private void announceHotplugEvent(int portId, boolean connected) {
         HdmiHotplugEvent event = new HdmiHotplugEvent(portId, connected);
         synchronized (mLock) {
-            for (IHdmiHotplugEventListener listener : mHotplugEventListeners) {
-                invokeHotplugEventListenerLocked(listener, event);
+            for (HotplugEventListenerRecord record : mHotplugEventListenerRecords) {
+                invokeHotplugEventListenerLocked(record.mListener, event);
             }
         }
     }
@@ -1561,21 +1709,29 @@
         }
     }
 
+    @ServiceThreadOnly
     int getPowerStatus() {
+        assertRunOnServiceThread();
         return mPowerStatus;
     }
 
+    @ServiceThreadOnly
     boolean isPowerOnOrTransient() {
+        assertRunOnServiceThread();
         return mPowerStatus == HdmiControlManager.POWER_STATUS_ON
                 || mPowerStatus == HdmiControlManager.POWER_STATUS_TRANSIENT_TO_ON;
     }
 
+    @ServiceThreadOnly
     boolean isPowerStandbyOrTransient() {
+        assertRunOnServiceThread();
         return mPowerStatus == HdmiControlManager.POWER_STATUS_STANDBY
                 || mPowerStatus == HdmiControlManager.POWER_STATUS_TRANSIENT_TO_STANDBY;
     }
 
+    @ServiceThreadOnly
     boolean isPowerStandby() {
+        assertRunOnServiceThread();
         return mPowerStatus == HdmiControlManager.POWER_STATUS_STANDBY;
     }
 
@@ -1599,11 +1755,6 @@
         // the intent, the sequence will continue at onStandby().
     }
 
-    void nap() {
-        PowerManager pm = (PowerManager) getContext().getSystemService(Context.POWER_SERVICE);
-        pm.nap(SystemClock.uptimeMillis());
-    }
-
     @ServiceThreadOnly
     private void onWakeUp() {
         assertRunOnServiceThread();
@@ -1643,16 +1794,36 @@
         });
     }
 
-    private void disableDevices(PendingActionClearedCallback callback) {
-        for (HdmiCecLocalDevice device : mCecController.getLocalDeviceList()) {
-            device.disableDevice(mStandbyMessageReceived, callback);
-        }
+    @ServiceThreadOnly
+    private void onLanguageChanged(String language) {
+        assertRunOnServiceThread();
+        mLanguage = language;
+
         if (isTvDevice()) {
-            unregisterSettingsObserver();
+            tv().broadcastMenuLanguage(language);
         }
     }
 
     @ServiceThreadOnly
+    String getLanguage() {
+        assertRunOnServiceThread();
+        return mLanguage;
+    }
+
+    private void disableDevices(PendingActionClearedCallback callback) {
+        if (mCecController != null) {
+            for (HdmiCecLocalDevice device : mCecController.getLocalDeviceList()) {
+                device.disableDevice(mStandbyMessageReceived, callback);
+            }
+            if (isTvDevice()) {
+                unregisterSettingsObserver();
+            }
+        }
+
+        mMhlController.clearAllLocalDevices();
+    }
+
+    @ServiceThreadOnly
     private void clearLocalDevices() {
         assertRunOnServiceThread();
         if (mCecController == null) {
@@ -1691,9 +1862,12 @@
         }
     }
 
-    void invokeVendorCommandListeners(int deviceType, int srcAddress, byte[] params,
+    boolean invokeVendorCommandListeners(int deviceType, int srcAddress, byte[] params,
             boolean hasVendorId) {
         synchronized (mLock) {
+            if (mVendorCommandListenerRecords.isEmpty()) {
+                return false;
+            }
             for (VendorCommandListenerRecord record : mVendorCommandListenerRecords) {
                 if (record.mDeviceType != deviceType) {
                     continue;
@@ -1704,6 +1878,34 @@
                     Slog.e(TAG, "Failed to notify vendor command reception", e);
                 }
             }
+            return true;
+        }
+    }
+
+    private void addHdmiMhlVendorCommandListener(IHdmiMhlVendorCommandListener listener) {
+        HdmiMhlVendorCommandListenerRecord record =
+                new HdmiMhlVendorCommandListenerRecord(listener);
+        try {
+            listener.asBinder().linkToDeath(record, 0);
+        } catch (RemoteException e) {
+            Slog.w(TAG, "Listener already died.");
+            return;
+        }
+
+        synchronized (mLock) {
+            mMhlVendorCommandListenerRecords.add(record);
+        }
+    }
+
+    void invokeMhlVendorCommandListeners(int portId, int offest, int length, byte[] data) {
+        synchronized (mLock) {
+            for (HdmiMhlVendorCommandListenerRecord record : mMhlVendorCommandListenerRecords) {
+                try {
+                    record.mListener.onReceived(portId, offest, length, data);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "Failed to notify MHL vendor command", e);
+                }
+            }
         }
     }
 
@@ -1720,7 +1922,7 @@
     }
 
     @ServiceThreadOnly
-    void setOption(int key, int value) {
+    void setCecOption(int key, int value) {
         assertRunOnServiceThread();
         mCecController.setOption(key, value);
     }
@@ -1731,9 +1933,7 @@
 
         int value = toInt(enabled);
         mCecController.setOption(OPTION_CEC_ENABLE, value);
-        if (mMhlController != null) {
-            mMhlController.setOption(OPTION_MHL_ENABLE, value);
-        }
+        mMhlController.setOption(OPTION_MHL_ENABLE, value);
 
         synchronized (mLock) {
             mHdmiControlEnabled = enabled;
@@ -1756,12 +1956,61 @@
     void setActivePortId(int portId) {
         assertRunOnServiceThread();
         mActivePortId = portId;
+
+        // Resets last input for MHL, which stays valid only after the MHL device was selected,
+        // and no further switching is done.
+        setLastInputForMhl(Constants.INVALID_PORT_ID);
     }
 
-    void setMhlInputChangeEnabled(boolean enabled) {
-        if (mMhlController != null) {
-            mMhlController.setOption(OPTION_MHL_INPUT_SWITCHING, toInt(enabled));
-        }
+    @ServiceThreadOnly
+    void setLastInputForMhl(int portId) {
+        assertRunOnServiceThread();
+        mLastInputMhl = portId;
+    }
+
+    @ServiceThreadOnly
+    int getLastInputForMhl() {
+        assertRunOnServiceThread();
+        return mLastInputMhl;
+    }
+
+    /**
+     * Performs input change, routing control for MHL device.
+     *
+     * @param portId MHL port, or the last port to go back to if {@code contentOn} is false
+     * @param contentOn {@code true} if RAP data is content on; otherwise false
+     */
+    @ServiceThreadOnly
+    void changeInputForMhl(int portId, boolean contentOn) {
+        assertRunOnServiceThread();
+        final int lastInput = contentOn ? tv().getActivePortId() : Constants.INVALID_PORT_ID;
+        tv().doManualPortSwitching(portId, new IHdmiControlCallback.Stub() {
+            @Override
+            public void onComplete(int result) throws RemoteException {
+                // Keep the last input to switch back later when RAP[ContentOff] is received.
+                // This effectively sets the port to invalid one if the switching is for
+                // RAP[ContentOff].
+                setLastInputForMhl(lastInput);
+            }
+        });
+
+        // MHL device is always directly connected to the port. Update the active port ID to avoid
+        // unnecessary post-routing control task.
+        tv().setActivePortId(portId);
+
+        // The port is either the MHL-enabled port where the mobile device is connected, or
+        // the last port to go back to when turnoff command is received. Note that the last port
+        // may not be the MHL-enabled one. In this case the device info to be passed to
+        // input change listener should be the one describing the corresponding HDMI port.
+        HdmiMhlLocalDeviceStub device = mMhlController.getLocalDevice(portId);
+        HdmiDeviceInfo info = (device != null && device.getInfo() != null)
+                ? device.getInfo()
+                : mPortDeviceMap.get(portId);
+        invokeInputChangeListener(info);
+    }
+
+   void setMhlInputChangeEnabled(boolean enabled) {
+       mMhlController.setOption(OPTION_MHL_INPUT_SWITCHING, toInt(enabled));
 
         synchronized (mLock) {
             mMhlInputChangeEnabled = enabled;
@@ -1773,4 +2022,23 @@
             return mMhlInputChangeEnabled;
         }
     }
+
+    @ServiceThreadOnly
+    void displayOsd(int messageId) {
+        assertRunOnServiceThread();
+        Intent intent = new Intent(HdmiControlManager.ACTION_OSD_MESSAGE);
+        intent.putExtra(HdmiControlManager.EXTRA_MESSAGE_ID, messageId);
+        getContext().sendBroadcastAsUser(intent, UserHandle.ALL,
+                HdmiControlService.PERMISSION);
+    }
+
+    @ServiceThreadOnly
+    void displayOsd(int messageId, int extra) {
+        assertRunOnServiceThread();
+        Intent intent = new Intent(HdmiControlManager.ACTION_OSD_MESSAGE);
+        intent.putExtra(HdmiControlManager.EXTRA_MESSAGE_ID, messageId);
+        intent.putExtra(HdmiControlManager.EXTRA_MESSAGE_EXTRAM_PARAM1, extra);
+        getContext().sendBroadcastAsUser(intent, UserHandle.ALL,
+                HdmiControlService.PERMISSION);
+    }
 }
diff --git a/services/core/java/com/android/server/hdmi/HdmiLogger.java b/services/core/java/com/android/server/hdmi/HdmiLogger.java
new file mode 100644
index 0000000..2562ffc
--- /dev/null
+++ b/services/core/java/com/android/server/hdmi/HdmiLogger.java
@@ -0,0 +1,138 @@
+/*
+ * Copyright (C) 2014 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.server.hdmi;
+
+import android.annotation.Nullable;
+import android.os.SystemClock;
+import android.util.Pair;
+import android.util.Slog;
+
+import java.util.HashMap;
+
+/**
+ * A logger that prevents spammy log. For the same log message, it logs once every 20seconds.
+ * This class is not thread-safe.
+ * <p>
+ * For convenience, use single character prefix for all messages.
+ * Here are common acronyms
+ * <ul>
+ *   <li>[T]: Timout
+ *   <li>[R]: Received message
+ *   <li>[S]: Sent message
+ *   <li>[P]: Device polling result
+ * </ul>
+ */
+final class HdmiLogger {
+    private static final String TAG = "HDMI";
+    // Logging duration for same error message.
+    private static final long ERROR_LOG_DURATTION_MILLIS = 20 * 1000;  // 20s
+
+    private static final boolean DEBUG = false;
+
+    private static final ThreadLocal<HdmiLogger> sLogger = new ThreadLocal<>();
+
+    // Key (String): log message.
+    // Value (Pair(Long, Integer)): a pair of last log time millis and the number of logMessage.
+    // Cache for warning.
+    private final HashMap<String, Pair<Long, Integer>> mWarningTimingCache = new HashMap<>();
+    // Cache for error.
+    private final HashMap<String, Pair<Long, Integer>> mErrorTimingCache = new HashMap<>();
+
+    private HdmiLogger() {
+    }
+
+    static final void warning(String logMessage, Object... objs) {
+        getLogger().warningInternal(toLogString(logMessage, objs));
+    }
+
+    private void warningInternal(String logMessage) {
+        String log = updateLog(mWarningTimingCache, logMessage);
+        if (!log.isEmpty()) {
+            Slog.w(TAG, log);
+        }
+    }
+
+    static final void error(String logMessage, Object... objs) {
+        getLogger().errorInternal(toLogString(logMessage, objs));
+    }
+
+    private void errorInternal(String logMessage) {
+        String log = updateLog(mErrorTimingCache, logMessage);
+        if (!log.isEmpty()) {
+            Slog.e(TAG, log);
+        }
+    }
+
+    static final void debug(String logMessage, Object... objs) {
+        getLogger().debugInternal(toLogString(logMessage, objs));
+    }
+
+    private void debugInternal(String logMessage) {
+        if (!DEBUG) {
+            return;
+        }
+        Slog.d(TAG, logMessage);
+    }
+
+    private static final String toLogString(String logMessage, Object[] objs) {
+        if (objs.length > 0) {
+            return String.format(logMessage, objs);
+        } else {
+            return logMessage;
+        }
+    }
+
+    private static HdmiLogger getLogger() {
+        HdmiLogger logger = sLogger.get();
+        if (logger == null) {
+            logger = new HdmiLogger();
+            sLogger.set(logger);
+        }
+        return logger;
+    }
+
+    private static String updateLog(HashMap<String, Pair<Long, Integer>> cache, String logMessage) {
+        long curTime = SystemClock.uptimeMillis();
+        Pair<Long, Integer> timing = cache.get(logMessage);
+        if (shouldLogNow(timing, curTime)) {
+            String log = buildMessage(logMessage, timing);
+            cache.put(logMessage, new Pair<>(curTime, 1));
+            return log;
+        } else {
+            increaseLogCount(cache, logMessage);
+        }
+        return "";
+    }
+
+    private static String buildMessage(String message, @Nullable Pair<Long, Integer> timing) {
+        return new StringBuilder()
+                .append("[").append(timing == null ? 1 : timing.second).append("]:")
+                .append(message).toString();
+    }
+
+    private static void increaseLogCount(HashMap<String, Pair<Long, Integer>> cache,
+            String message) {
+        Pair<Long, Integer> timing = cache.get(message);
+        if (timing != null) {
+            cache.put(message, new Pair<>(timing.first, timing.second + 1));
+        }
+    }
+
+    private static boolean shouldLogNow(@Nullable Pair<Long, Integer> timing, long curTime) {
+        return timing == null || curTime - timing.first > ERROR_LOG_DURATTION_MILLIS;
+    }
+}
diff --git a/services/core/java/com/android/server/hdmi/HdmiMhlControllerStub.java b/services/core/java/com/android/server/hdmi/HdmiMhlControllerStub.java
new file mode 100644
index 0000000..708aee6
--- /dev/null
+++ b/services/core/java/com/android/server/hdmi/HdmiMhlControllerStub.java
@@ -0,0 +1,138 @@
+/*
+ * Copyright (C) 2014 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.server.hdmi;
+
+import android.hardware.hdmi.HdmiPortInfo;
+import android.util.SparseArray;
+
+import com.android.server.hdmi.HdmiControlService.SendMessageCallback;
+
+/**
+ * A handler class for MHL control command. It converts user's command into MHL command and pass it
+ * to MHL HAL layer.
+ * <p>
+ * It can be created only by {@link HdmiMhlControllerStub#create}.
+ */
+final class HdmiMhlControllerStub {
+
+    private static final SparseArray<HdmiMhlLocalDeviceStub> mLocalDevices = new SparseArray<>();
+    private static final HdmiPortInfo[] EMPTY_PORT_INFO = new HdmiPortInfo[0];
+    private static final int INVALID_MHL_VERSION = 0;
+    private static final int NO_SUPPORTED_FEATURES = 0;
+    private static final int INVALID_DEVICE_ROLES = 0;
+
+    // Private constructor. Use HdmiMhlControllerStub.create().
+    private HdmiMhlControllerStub(HdmiControlService service) {
+    }
+
+    // Returns true if MHL controller is initialized and ready to use.
+    boolean isReady() {
+        return false;
+    }
+
+    static HdmiMhlControllerStub create(HdmiControlService service) {
+        return new HdmiMhlControllerStub(service);
+    }
+
+    HdmiPortInfo[] getPortInfos() {
+        return EMPTY_PORT_INFO;
+    }
+
+    /**
+     * Return {@link HdmiMhlLocalDeviceStub} matched with the given port id.
+     *
+     * @return null if has no matched port id
+     */
+    HdmiMhlLocalDeviceStub getLocalDevice(int portId) {
+        return null;
+    }
+
+    /**
+     * Return {@link HdmiMhlLocalDeviceStub} matched with the given device id.
+     *
+     * @return null if has no matched id
+     */
+    HdmiMhlLocalDeviceStub getLocalDeviceById(int deviceId) {
+        return null;
+    }
+
+    SparseArray<HdmiMhlLocalDeviceStub> getAllLocalDevices() {
+        return mLocalDevices;
+    }
+
+    /**
+     * Remove a {@link HdmiMhlLocalDeviceStub} matched with the given port id.
+     *
+     * @return removed {@link HdmiMhlLocalDeviceStub}. Return null if no matched port id.
+     */
+    HdmiMhlLocalDeviceStub removeLocalDevice(int portId) {
+        return null;
+    }
+
+    /**
+     * Add a new {@link HdmiMhlLocalDeviceStub}.
+     *
+     * @return old {@link HdmiMhlLocalDeviceStub} having same port id
+     */
+    HdmiMhlLocalDeviceStub addLocalDevice(HdmiMhlLocalDeviceStub device) {
+        return null;
+    }
+
+    void clearAllLocalDevices() {
+    }
+
+    void sendVendorCommand(int portId, int offset, int length, byte[] data) {
+    }
+
+    void setOption(int flag, int value) {
+    }
+
+    /**
+     * Get the MHL version supported by underlying hardware port of the given {@code portId}.
+     * MHL specification version 2.0 returns 0x20, 3.0 will return 0x30 respectively.
+     * The return value is stored in 'version'. Return INVALID_VERSION if MHL hardware layer
+     * is not ready.
+     */
+    int getMhlVersion(int portId) {
+        return INVALID_MHL_VERSION;
+    }
+
+    /**
+     * Get MHL version of a device which is connected to a port of the given {@code portId}.
+     * MHL specification version 2.0 returns 0x20, 3.0 will return 0x30 respectively.
+     * The return value is stored in 'version'.
+     */
+    int getPeerMhlVersion(int portId) {
+        return INVALID_MHL_VERSION;
+    }
+
+    /**
+     * Get the bit flags describing the features supported by the system. Refer to feature support
+     * flag register info in MHL specification.
+     */
+    int getSupportedFeatures(int portId) {
+        return NO_SUPPORTED_FEATURES;
+    }
+
+    /**
+     * Get the bit flags describing the roles which ECBUS device can play. Refer to the
+     * ECBUS_DEV_ROLES Register info MHL3.0 specification
+     */
+    int getEcbusDeviceRoles(int portId) {
+        return INVALID_DEVICE_ROLES;
+    }
+}
diff --git a/services/core/java/com/android/server/hdmi/HdmiMhlLocalDeviceStub.java b/services/core/java/com/android/server/hdmi/HdmiMhlLocalDeviceStub.java
new file mode 100644
index 0000000..53a7c5c
--- /dev/null
+++ b/services/core/java/com/android/server/hdmi/HdmiMhlLocalDeviceStub.java
@@ -0,0 +1,46 @@
+package com.android.server.hdmi;
+
+import android.hardware.hdmi.HdmiDeviceInfo;
+import android.hardware.hdmi.IHdmiControlCallback;
+
+/**
+ * Stub class that models a logical mhl device hosted in this system.
+ */
+final class HdmiMhlLocalDeviceStub {
+
+    private static final HdmiDeviceInfo INFO = new HdmiDeviceInfo(
+            Constants.INVALID_PHYSICAL_ADDRESS, Constants.INVALID_PORT_ID, -1, -1);
+    private final HdmiControlService mService;
+    private final int mPortId;
+
+    protected HdmiMhlLocalDeviceStub(HdmiControlService service, int portId) {
+        mService = service;
+        mPortId = portId;
+    }
+
+    void onDeviceRemoved() {
+    }
+
+    HdmiDeviceInfo getInfo() {
+        return INFO;
+    }
+
+    void setBusMode(int cbusmode) {
+    }
+
+    void onBusOvercurrentDetected(boolean on) {
+    }
+
+    void setDeviceStatusChange(int adopterId, int deviceId) {
+    }
+
+    int getPortId() {
+        return mPortId;
+    }
+
+    void turnOn(IHdmiControlCallback callback) {
+    }
+
+    void sendKeyEvent(int keycode, boolean isPressed) {
+    }
+}
diff --git a/services/core/java/com/android/server/hdmi/HdmiUtils.java b/services/core/java/com/android/server/hdmi/HdmiUtils.java
index 23f19ff..22a519b 100644
--- a/services/core/java/com/android/server/hdmi/HdmiUtils.java
+++ b/services/core/java/com/android/server/hdmi/HdmiUtils.java
@@ -206,6 +206,22 @@
         return list;
     }
 
+    static <T> List<T> mergeToUnmodifiableList(List<T> a, List<T> b) {
+        if (a.isEmpty() && b.isEmpty()) {
+            return Collections.emptyList();
+        }
+        if (a.isEmpty()) {
+            return Collections.unmodifiableList(b);
+        }
+        if (b.isEmpty()) {
+            return Collections.unmodifiableList(a);
+        }
+        List<T> newList = new ArrayList<>();
+        newList.addAll(a);
+        newList.addAll(b);
+        return Collections.unmodifiableList(newList);
+    }
+
     /**
      * See if the new path is affecting the active path.
      *
diff --git a/services/core/java/com/android/server/hdmi/NewDeviceAction.java b/services/core/java/com/android/server/hdmi/NewDeviceAction.java
index a5fdbea..2074085 100644
--- a/services/core/java/com/android/server/hdmi/NewDeviceAction.java
+++ b/services/core/java/com/android/server/hdmi/NewDeviceAction.java
@@ -103,8 +103,8 @@
                 requestVendorId();
                 return true;
             } else if (opcode == Constants.MESSAGE_FEATURE_ABORT) {
-                int requestOpcode = params[1] & 0xFF;
-                if (requestOpcode == Constants.MESSAGE_SET_OSD_NAME) {
+                int requestOpcode = params[0] & 0xFF;
+                if (requestOpcode == Constants.MESSAGE_GIVE_OSD_NAME) {
                     requestVendorId();
                     return true;
                 }
@@ -116,8 +116,8 @@
                 finish();
                 return true;
             } else if (opcode == Constants.MESSAGE_FEATURE_ABORT) {
-                int requestOpcode = params[1] & 0xFF;
-                if (requestOpcode == Constants.MESSAGE_DEVICE_VENDOR_ID) {
+                int requestOpcode = params[0] & 0xFF;
+                if (requestOpcode == Constants.MESSAGE_GIVE_DEVICE_VENDOR_ID) {
                     addDeviceInfo();
                     finish();
                     return true;
@@ -152,30 +152,19 @@
         if (mDisplayName == null) {
             mDisplayName = HdmiUtils.getDefaultDeviceName(mDeviceLogicalAddress);
         }
-        tv().addCecDevice(new HdmiDeviceInfo(
+        HdmiDeviceInfo deviceInfo = new HdmiDeviceInfo(
                 mDeviceLogicalAddress, mDevicePhysicalAddress,
                 tv().getPortId(mDevicePhysicalAddress),
                 HdmiUtils.getTypeFromAddress(mDeviceLogicalAddress),
-                mVendorId, mDisplayName));
+                mVendorId, mDisplayName);
+        tv().addCecDevice(deviceInfo);
 
         if (HdmiUtils.getTypeFromAddress(mDeviceLogicalAddress)
                 == HdmiDeviceInfo.DEVICE_AUDIO_SYSTEM) {
-            if (tv().getSystemAudioModeSetting()) {
-                addAndStartAction(new SystemAudioAutoInitiationAction(localDevice(),
-                        mDeviceLogicalAddress));
-            }
-
-            if (shouldTryArcInitiation()) {
-                addAndStartAction(new RequestArcInitiationAction(localDevice(),
-                        mDeviceLogicalAddress));
-            }
+            tv().onNewAvrAdded(deviceInfo);
         }
     }
 
-    private boolean shouldTryArcInitiation() {
-        return tv().isConnectedToArcPort(mDevicePhysicalAddress) && tv().isArcFeatureEnabled();
-    }
-
     @Override
     public void handleTimerEvent(int state) {
         if (mState == STATE_NONE || mState != state) {
diff --git a/services/core/java/com/android/server/hdmi/PowerStatusMonitorAction.java b/services/core/java/com/android/server/hdmi/PowerStatusMonitorAction.java
index 03fbb95..1e29fd6 100644
--- a/services/core/java/com/android/server/hdmi/PowerStatusMonitorAction.java
+++ b/services/core/java/com/android/server/hdmi/PowerStatusMonitorAction.java
@@ -77,7 +77,7 @@
             // if no device exists for incoming message, hands it over to other actions.
             return false;
         }
-        int newStatus = cmd.getParams()[0];
+        int newStatus = cmd.getParams()[0] & 0xFF;
         updatePowerStatus(sourceAddress, newStatus, true);
         return true;
     }
diff --git a/services/core/java/com/android/server/hdmi/RequestArcAction.java b/services/core/java/com/android/server/hdmi/RequestArcAction.java
index 9c530a3..31322a9 100644
--- a/services/core/java/com/android/server/hdmi/RequestArcAction.java
+++ b/services/core/java/com/android/server/hdmi/RequestArcAction.java
@@ -17,7 +17,6 @@
 package com.android.server.hdmi;
 
 import android.hardware.hdmi.HdmiDeviceInfo;
-
 import android.util.Slog;
 
 /**
@@ -57,13 +56,17 @@
         switch (opcode) {
             // Handles only <Feature Abort> here and, both <Initiate ARC> and <Terminate ARC>
             // are handled in HdmiControlService itself because both can be
-            // received wihtout <Request ARC Initiation> or <Request ARC Termination>.
+            // received without <Request ARC Initiation> or <Request ARC Termination>.
             case Constants.MESSAGE_FEATURE_ABORT:
-                disableArcTransmission();
-                finish();
-                return true;
-            default:
-                Slog.w(TAG, "Unsupported opcode:" + cmd.toString());
+                int originalOpcode = cmd.getParams()[0] & 0xFF;
+                if (originalOpcode == Constants.MESSAGE_REQUEST_ARC_INITIATION
+                        || originalOpcode == Constants.MESSAGE_REQUEST_ARC_TERMINATION) {
+                    disableArcTransmission();
+                    finish();
+                    return true;
+                } else {
+                    return false;
+                }
         }
         return false;
     }
@@ -80,6 +83,7 @@
         if (mState != state || state != STATE_WATING_FOR_REQUEST_ARC_REQUEST_RESPONSE) {
             return;
         }
+        HdmiLogger.debug("[T]RequestArcAction.");
         disableArcTransmission();
         finish();
     }
diff --git a/services/core/java/com/android/server/hdmi/RequestArcInitiationAction.java b/services/core/java/com/android/server/hdmi/RequestArcInitiationAction.java
index f25363d..d9e1f24 100644
--- a/services/core/java/com/android/server/hdmi/RequestArcInitiationAction.java
+++ b/services/core/java/com/android/server/hdmi/RequestArcInitiationAction.java
@@ -35,15 +35,15 @@
 
     @Override
     boolean start() {
+        mState = STATE_WATING_FOR_REQUEST_ARC_REQUEST_RESPONSE;
+        addTimer(mState, HdmiConfig.TIMEOUT_MS);
+
         HdmiCecMessage command = HdmiCecMessageBuilder.buildRequestArcInitiation(
                 getSourceAddress(), mAvrAddress);
         sendCommand(command, new HdmiControlService.SendMessageCallback() {
             @Override
             public void onSendCompleted(int error) {
-                if (error == Constants.SEND_RESULT_SUCCESS) {
-                    mState = STATE_WATING_FOR_REQUEST_ARC_REQUEST_RESPONSE;
-                    addTimer(mState, HdmiConfig.TIMEOUT_MS);
-                } else {
+                if (error != Constants.SEND_RESULT_SUCCESS) {
                     // If failed to send <Request ARC Initiation>, start "Disabled"
                     // ARC transmission action.
                     disableArcTransmission();
diff --git a/services/core/java/com/android/server/hdmi/RequestArcTerminationAction.java b/services/core/java/com/android/server/hdmi/RequestArcTerminationAction.java
index 1491c72..f5a0115 100644
--- a/services/core/java/com/android/server/hdmi/RequestArcTerminationAction.java
+++ b/services/core/java/com/android/server/hdmi/RequestArcTerminationAction.java
@@ -35,15 +35,15 @@
 
     @Override
     boolean start() {
+        mState = STATE_WATING_FOR_REQUEST_ARC_REQUEST_RESPONSE;
+        addTimer(mState, HdmiConfig.TIMEOUT_MS);
+
         HdmiCecMessage command =
                 HdmiCecMessageBuilder.buildRequestArcTermination(getSourceAddress(), mAvrAddress);
         sendCommand(command, new HdmiControlService.SendMessageCallback() {
             @Override
             public void onSendCompleted(int error) {
-                if (error == Constants.SEND_RESULT_SUCCESS) {
-                    mState = STATE_WATING_FOR_REQUEST_ARC_REQUEST_RESPONSE;
-                    addTimer(mState, HdmiConfig.TIMEOUT_MS);
-                } else {
+                if (error != Constants.SEND_RESULT_SUCCESS) {
                     // If failed to send <Request ARC Termination>, start "Disabled" ARC
                     // transmission action.
                     disableArcTransmission();
diff --git a/services/core/java/com/android/server/hdmi/SendKeyAction.java b/services/core/java/com/android/server/hdmi/SendKeyAction.java
index 9f09eb4..ed978e0 100644
--- a/services/core/java/com/android/server/hdmi/SendKeyAction.java
+++ b/services/core/java/com/android/server/hdmi/SendKeyAction.java
@@ -109,12 +109,12 @@
     }
 
     private void sendKeyDown(int keycode) {
-        byte[] keycodeAndParam = getCecKeycodeAndParam(keycode);
-        if (keycodeAndParam == null) {
+        int cecKeycode = HdmiCecKeycode.androidKeyToCecKey(keycode);
+        if (cecKeycode == HdmiCecKeycode.UNSUPPORTED_KEYCODE) {
             return;
         }
         sendCommand(HdmiCecMessageBuilder.buildUserControlPressed(getSourceAddress(),
-                mTargetAddress, keycodeAndParam));
+                mTargetAddress, new byte[] { (byte) (cecKeycode & 0xFF) }));
     }
 
     private void sendKeyUp() {
@@ -141,13 +141,4 @@
         sendKeyDown(mLastKeycode);
         addTimer(mState, IRT_MS);
     }
-
-    // Converts the Android key code to corresponding CEC key code definition. Those CEC keys
-    // with additional parameters should be mapped from individual Android key code. 'Select
-    // Broadcast' with the parameter 'cable', for instance, shall have its counterpart such as
-    // KeyEvent.KEYCODE_TV_BROADCAST_CABLE.
-    // The return byte array contains both UI command (keycode) and optional parameter.
-    private byte[] getCecKeycodeAndParam(int keycode) {
-        return HdmiCecKeycode.androidKeyToCecKey(keycode);
-    }
 }
diff --git a/services/core/java/com/android/server/hdmi/SetArcTransmissionStateAction.java b/services/core/java/com/android/server/hdmi/SetArcTransmissionStateAction.java
index 9f7f98a..bffa854 100644
--- a/services/core/java/com/android/server/hdmi/SetArcTransmissionStateAction.java
+++ b/services/core/java/com/android/server/hdmi/SetArcTransmissionStateAction.java
@@ -53,6 +53,18 @@
     @Override
     boolean start() {
         if (mEnabled) {
+            // Enable ARC status immediately after sending <Report Arc Initiated>.
+            // If AVR responds with <Feature Abort>, disable ARC status again.
+            // This is different from spec that says that turns ARC status to
+            // "Enabled" if <Report ARC Initiated> is acknowledged and no
+            // <Feature Abort> is received.
+            // But implemented this way to save the time having to wait for
+            // <Feature Abort>.
+            setArcStatus(true);
+            // If succeeds to send <Report ARC Initiated>, wait general timeout
+            // to check whether there is no <Feature Abort> for <Report ARC Initiated>.
+            mState = STATE_WAITING_TIMEOUT;
+            addTimer(mState, HdmiConfig.TIMEOUT_MS);
             sendReportArcInitiated();
         } else {
             setArcStatus(false);
@@ -67,23 +79,11 @@
         sendCommand(command, new HdmiControlService.SendMessageCallback() {
             @Override
             public void onSendCompleted(int error) {
-                if (error == Constants.SEND_RESULT_SUCCESS) {
-                    // Enable ARC status immediately after sending <Report Arc Initiated>.
-                    // If AVR responds with <Feature Abort>, disable ARC status again.
-                    // This is different from spec that says that turns ARC status to
-                    // "Enabled" if <Report ARC Initiated> is acknowledged and no
-                    // <Feature Abort> is received.
-                    // But implemented this way to save the time having to wait for
-                    // <Feature Abort>.
-                    setArcStatus(true);
-                    // If succeeds to send <Report ARC Initiated>, wait general timeout
-                    // to check whether there is no <Feature Abort> for <Report ARC Initiated>.
-                    mState = STATE_WAITING_TIMEOUT;
-                    addTimer(mState, HdmiConfig.TIMEOUT_MS);
-                } else {
+                if (error != Constants.SEND_RESULT_SUCCESS) {
                     // If fails to send <Report ARC Initiated>, disable ARC and
                     // send <Report ARC Terminated> directly.
                     setArcStatus(false);
+                    HdmiLogger.debug("Failed to send <Report Arc Initiated>.");
                     finish();
                 }
             }
@@ -92,7 +92,7 @@
 
     private void setArcStatus(boolean enabled) {
         boolean wasEnabled = tv().setArcStatus(enabled);
-        Slog.i(TAG, "Change arc status [old:" + wasEnabled + " ,new:" + enabled);
+        Slog.i(TAG, "Change arc status [old:" + wasEnabled + ", new:" + enabled + "]");
 
         // If enabled before and set to "disabled" and send <Report Arc Terminated> to
         // av reciever.
@@ -110,10 +110,15 @@
 
         int opcode = cmd.getOpcode();
         if (opcode == Constants.MESSAGE_FEATURE_ABORT) {
-            setArcStatus(false);
+            int originalOpcode = cmd.getParams()[0] & 0xFF;
+            if (originalOpcode == Constants.MESSAGE_REPORT_ARC_INITIATED) {
+                HdmiLogger.debug("Feature aborted for <Report Arc Initiated>");
+                setArcStatus(false);
+                finish();
+                return true;
+            }
         }
-        finish();
-        return true;
+        return false;
     }
 
     @Override
diff --git a/services/core/java/com/android/server/hdmi/SystemAudioAction.java b/services/core/java/com/android/server/hdmi/SystemAudioAction.java
index 7e45a99..0871194 100644
--- a/services/core/java/com/android/server/hdmi/SystemAudioAction.java
+++ b/services/core/java/com/android/server/hdmi/SystemAudioAction.java
@@ -73,9 +73,9 @@
 
     // Seq #27
     protected void sendSystemAudioModeRequest() {
-        mState = STATE_CHECK_ROUTING_IN_PRGRESS;
         List<RoutingControlAction> routingActions = getActions(RoutingControlAction.class);
         if (!routingActions.isEmpty()) {
+            mState = STATE_CHECK_ROUTING_IN_PRGRESS;
             // Should have only one Routing Control Action
             RoutingControlAction routingAction = routingActions.get(0);
             routingAction.addOnFinishedCallback(this, new Runnable() {
@@ -97,20 +97,21 @@
         sendCommand(command, new HdmiControlService.SendMessageCallback() {
             @Override
             public void onSendCompleted(int error) {
-                if (error == Constants.SEND_RESULT_SUCCESS) {
-                    mState = STATE_WAIT_FOR_SET_SYSTEM_AUDIO_MODE;
-                    addTimer(mState, mTargetAudioStatus ? ON_TIMEOUT_MS : OFF_TIMEOUT_MS);
-                } else {
+                if (error != Constants.SEND_RESULT_SUCCESS) {
+                    HdmiLogger.debug("Failed to send <System Audio Mode Request>:" + error);
                     setSystemAudioMode(false);
                     finishWithCallback(HdmiControlManager.RESULT_COMMUNICATION_FAILED);
                 }
             }
         });
+        mState = STATE_WAIT_FOR_SET_SYSTEM_AUDIO_MODE;
+        addTimer(mState, mTargetAudioStatus ? ON_TIMEOUT_MS : OFF_TIMEOUT_MS);
     }
 
     private void handleSendSystemAudioModeRequestTimeout() {
         if (!mTargetAudioStatus  // Don't retry for Off case.
                 || mSendRetryCount++ >= MAX_SEND_RETRY_COUNT) {
+            HdmiLogger.debug("[T]:wait for <Set System Audio Mode>.");
             setSystemAudioMode(false);
             finishWithCallback(HdmiControlManager.RESULT_TIMEOUT);
             return;
@@ -127,7 +128,9 @@
         switch (mState) {
             case STATE_WAIT_FOR_SET_SYSTEM_AUDIO_MODE:
                 if (cmd.getOpcode() == Constants.MESSAGE_FEATURE_ABORT
-                        && cmd.getParams()[0] == Constants.MESSAGE_SYSTEM_AUDIO_MODE_REQUEST) {
+                        && (cmd.getParams()[0] & 0xFF)
+                                == Constants.MESSAGE_SYSTEM_AUDIO_MODE_REQUEST) {
+                    HdmiLogger.debug("Failed to start system audio mode request.");
                     setSystemAudioMode(false);
                     finishWithCallback(HdmiControlManager.RESULT_EXCEPTION);
                     return true;
@@ -142,6 +145,7 @@
                     startAudioStatusAction();
                     return true;
                 } else {
+                    HdmiLogger.debug("Unexpected system audio mode request:" + receivedStatus);
                     // Unexpected response, consider the request is newly initiated by AVR.
                     // To return 'false' will initiate new SystemAudioActionFromAvr by the control
                     // service.
diff --git a/services/core/java/com/android/server/hdmi/VolumeControlAction.java b/services/core/java/com/android/server/hdmi/VolumeControlAction.java
index 01c6f3e..4338fc7 100644
--- a/services/core/java/com/android/server/hdmi/VolumeControlAction.java
+++ b/services/core/java/com/android/server/hdmi/VolumeControlAction.java
@@ -17,66 +17,35 @@
 package com.android.server.hdmi;
 
 import static com.android.server.hdmi.Constants.IRT_MS;
+import static com.android.server.hdmi.Constants.MESSAGE_FEATURE_ABORT;
+import static com.android.server.hdmi.Constants.MESSAGE_REPORT_AUDIO_STATUS;
+import static com.android.server.hdmi.Constants.MESSAGE_USER_CONTROL_PRESSED;
 
-import com.android.internal.util.Preconditions;
+import android.media.AudioManager;
 
 /**
  * Feature action that transmits volume change to Audio Receiver.
  * <p>
- * This action is created when a user pressed volume up/down. However, Since Android only provides a
- * listener for delta of some volume change, we will set a target volume, and check reported volume
- * from Audio Receiver(AVR). If TV receives no &lt;Report Audio Status&gt; from AVR, this action
- * will be finished in {@link #IRT_MS} * {@link #VOLUME_CHANGE_TIMEOUT_MAX_COUNT} (ms).
+ * This action is created when a user pressed volume up/down. However, Android only provides a
+ * listener for delta of some volume change instead of individual key event. Also it's hard to know
+ * Audio Receiver's number of volume steps for a single volume control key. Because of this, it
+ * sends key-down event until IRT timeout happens, and it will send key-up event if no additional
+ * volume change happens; otherwise, it will send again key-down as press and hold feature does.
  */
 final class VolumeControlAction extends HdmiCecFeatureAction {
     private static final String TAG = "VolumeControlAction";
 
-    private static final int VOLUME_MUTE = 101;
-    private static final int VOLUME_RESTORE = 102;
+    // State that wait for next volume press.
+    private static final int STATE_WAIT_FOR_NEXT_VOLUME_PRESS = 1;
     private static final int MAX_VOLUME = 100;
-    private static final int MIN_VOLUME = 0;
 
-    // State where to wait for <Report Audio Status>
-    private static final int STATE_WAIT_FOR_REPORT_VOLUME_STATUS = 1;
-
-    // Maximum count of time out used to finish volume action.
-    private static final int VOLUME_CHANGE_TIMEOUT_MAX_COUNT = 2;
+    private static final int UNKNOWN_AVR_VOLUME = -1;
 
     private final int mAvrAddress;
-    private final int mTargetVolume;
-    private final boolean mIsVolumeUp;
-    private int mTimeoutCount;
-
-    /**
-     * Create a {@link VolumeControlAction} for mute/restore change
-     *
-     * @param source source device sending volume change
-     * @param avrAddress address of audio receiver
-     * @param mute whether to mute sound or not. {@code true} for mute on; {@code false} for mute
-     *            off, i.e restore volume
-     * @return newly created {@link VolumeControlAction}
-     */
-    public static VolumeControlAction ofMute(HdmiCecLocalDevice source, int avrAddress,
-            boolean mute) {
-        return new VolumeControlAction(source, avrAddress, mute ? VOLUME_MUTE : VOLUME_RESTORE,
-                false);
-    }
-
-    /**
-     * Create a {@link VolumeControlAction} for volume up/down change
-     *
-     * @param source source device sending volume change
-     * @param avrAddress address of audio receiver
-     * @param targetVolume target volume to be set to AVR. It should be in range of [0-100]
-     * @param isVolumeUp whether to volume up or not. {@code true} for volume up; {@code false} for
-     *            volume down
-     * @return newly created {@link VolumeControlAction}
-     */
-    public static VolumeControlAction ofVolumeChange(HdmiCecLocalDevice source, int avrAddress,
-            int targetVolume, boolean isVolumeUp) {
-        Preconditions.checkArgumentInRange(targetVolume, MIN_VOLUME, MAX_VOLUME, "volume");
-        return new VolumeControlAction(source, avrAddress, targetVolume, isVolumeUp);
-    }
+    private boolean mIsVolumeUp;
+    private long mLastKeyUpdateTime;
+    private int mLastAvrVolume;
+    private boolean mSentKeyPressed;
 
     /**
      * Scale a custom volume value to cec volume scale.
@@ -94,119 +63,141 @@
      *
      * @param cecVolume volume value in cec volume scale. It should be in a range of [0-100]
      * @param scale scale of custom volume (max volume)
-     * @return a volume value scaled to custom volume range
+     * @return a volume scaled to custom volume range
      */
     public static int scaleToCustomVolume(int cecVolume, int scale) {
         return (cecVolume * scale) / MAX_VOLUME;
     }
 
-    private VolumeControlAction(HdmiCecLocalDevice source, int avrAddress, int targetVolume,
-            boolean isVolumeUp) {
+    VolumeControlAction(HdmiCecLocalDevice source, int avrAddress, boolean isVolumeUp) {
         super(source);
-
         mAvrAddress = avrAddress;
-        mTargetVolume = targetVolume;
         mIsVolumeUp = isVolumeUp;
+        mLastAvrVolume = UNKNOWN_AVR_VOLUME;
+        mSentKeyPressed = false;
+
+        updateLastKeyUpdateTime();
+    }
+
+    private void updateLastKeyUpdateTime() {
+        mLastKeyUpdateTime = System.currentTimeMillis();
     }
 
     @Override
     boolean start() {
-        if (isForMute()) {
-            sendMuteChange(mTargetVolume == VOLUME_MUTE);
-            finish();
-            return true;
-        }
-
-        startVolumeChange();
+        mState = STATE_WAIT_FOR_NEXT_VOLUME_PRESS;
+        sendVolumeKeyPressed();
+        resetTimer();
         return true;
     }
 
-
-    private boolean isForMute() {
-        return mTargetVolume == VOLUME_MUTE || mTargetVolume == VOLUME_RESTORE;
-    }
-
-    private void startVolumeChange() {
-        mTimeoutCount = 0;
-        sendVolumeChange(mIsVolumeUp);
-        mState = STATE_WAIT_FOR_REPORT_VOLUME_STATUS;
-        addTimer(mState, IRT_MS);
-    }
-
-    private void sendVolumeChange(boolean up) {
+    private void sendVolumeKeyPressed() {
         sendCommand(HdmiCecMessageBuilder.buildUserControlPressed(getSourceAddress(), mAvrAddress,
-                up ? HdmiCecKeycode.CEC_KEYCODE_VOLUME_UP
+                mIsVolumeUp ? HdmiCecKeycode.CEC_KEYCODE_VOLUME_UP
                         : HdmiCecKeycode.CEC_KEYCODE_VOLUME_DOWN));
+        mSentKeyPressed = true;
     }
 
-    private void sendMuteChange(boolean mute) {
-        sendUserControlPressedAndReleased(mAvrAddress,
-                mute ? HdmiCecKeycode.CEC_KEYCODE_MUTE_FUNCTION :
-                        HdmiCecKeycode.CEC_KEYCODE_RESTORE_VOLUME_FUNCTION);
+    private void resetTimer() {
+        mActionTimer.clearTimerMessage();
+        addTimer(STATE_WAIT_FOR_NEXT_VOLUME_PRESS, IRT_MS);
+    }
+
+    void handleVolumeChange(boolean isVolumeUp) {
+        if (mIsVolumeUp != isVolumeUp) {
+            HdmiLogger.debug("Volume Key Status Changed[old:%b new:%b]", mIsVolumeUp, isVolumeUp);
+            sendVolumeKeyReleased();
+            mIsVolumeUp = isVolumeUp;
+        }
+        updateLastKeyUpdateTime();
+    }
+
+    private void sendVolumeKeyReleased() {
+        sendCommand(HdmiCecMessageBuilder.buildUserControlReleased(
+                getSourceAddress(), mAvrAddress));
+        mSentKeyPressed = false;
     }
 
     @Override
     boolean processCommand(HdmiCecMessage cmd) {
-        if (mState != STATE_WAIT_FOR_REPORT_VOLUME_STATUS) {
+        if (mState != STATE_WAIT_FOR_NEXT_VOLUME_PRESS || cmd.getSource() != mAvrAddress) {
             return false;
         }
 
         switch (cmd.getOpcode()) {
-            case Constants.MESSAGE_REPORT_AUDIO_STATUS:
-                handleReportAudioStatus(cmd);
-                return true;
-            case Constants.MESSAGE_FEATURE_ABORT:
-                // TODO: handle feature abort.
-                finish();
-                return true;
+            case MESSAGE_REPORT_AUDIO_STATUS:
+                return handleReportAudioStatus(cmd);
+            case MESSAGE_FEATURE_ABORT:
+                return handleFeatureAbort(cmd);
             default:
                 return false;
         }
     }
 
-    private void handleReportAudioStatus(HdmiCecMessage cmd) {
-        byte[] params = cmd.getParams();
+    private boolean handleReportAudioStatus(HdmiCecMessage cmd) {
+        byte params[] = cmd.getParams();
+        boolean mute = (params[0] & 0x80) == 0x80;
         int volume = params[0] & 0x7F;
-        // Update volume with new value.
-        // Note that it will affect system volume change.
-        tv().setAudioStatus(false, volume);
-        if (mIsVolumeUp) {
-            if (mTargetVolume <= volume) {
-                finishWithVolumeChangeRelease();
-                return;
-            }
-        } else {
-            if (mTargetVolume >= volume) {
-                finishWithVolumeChangeRelease();
-                return;
-            }
+        mLastAvrVolume = volume;
+        if (shouldUpdateAudioVolume(mute)) {
+            HdmiLogger.debug("Force volume change[mute:%b, volume=%d]", mute, volume);
+            tv().setAudioStatus(mute, volume);
         }
-
-        // Clear action status and send another volume change command.
-        clear();
-        startVolumeChange();
+        return true;
     }
 
-    private void finishWithVolumeChangeRelease() {
-        sendCommand(HdmiCecMessageBuilder.buildUserControlReleased(
-                getSourceAddress(), mAvrAddress));
-        finish();
+    private boolean shouldUpdateAudioVolume(boolean mute) {
+        // Do nothing if in mute.
+        if (mute) {
+            return true;
+        }
+
+        // Update audio status if current volume position is edge of volume bar,
+        // i.e max or min volume.
+        AudioManager audioManager = tv().getService().getAudioManager();
+        int currentVolume = audioManager.getStreamVolume(AudioManager.STREAM_MUSIC);
+        if (mIsVolumeUp) {
+            int maxVolume = audioManager.getStreamMaxVolume(AudioManager.STREAM_MUSIC);
+            return currentVolume == maxVolume;
+        } else {
+            return currentVolume == 0;
+        }
+    }
+
+    private boolean handleFeatureAbort(HdmiCecMessage cmd) {
+        int originalOpcode = cmd.getParams()[0] & 0xFF;
+        // Since it sends <User Control Released> only when it finishes this action,
+        // it takes care of <User Control Pressed> only here.
+        if (originalOpcode == MESSAGE_USER_CONTROL_PRESSED) {
+            finish();
+            return true;
+        }
+        return false;
+    }
+
+    @Override
+    protected void clear() {
+        super.clear();
+        if (mSentKeyPressed) {
+            sendVolumeKeyReleased();
+        }
+        if (mLastAvrVolume != UNKNOWN_AVR_VOLUME) {
+            tv().setAudioStatus(false, mLastAvrVolume);
+            mLastAvrVolume = UNKNOWN_AVR_VOLUME;
+        }
     }
 
     @Override
     void handleTimerEvent(int state) {
-        if (mState != STATE_WAIT_FOR_REPORT_VOLUME_STATUS) {
+        if (state != STATE_WAIT_FOR_NEXT_VOLUME_PRESS) {
             return;
         }
 
-        // If no report volume action after IRT * VOLUME_CHANGE_TIMEOUT_MAX_COUNT just stop volume
-        // action.
-        if (++mTimeoutCount == VOLUME_CHANGE_TIMEOUT_MAX_COUNT) {
-            finishWithVolumeChangeRelease();
-            return;
+        if (System.currentTimeMillis() - mLastKeyUpdateTime >= IRT_MS) {
+            finish();
+        } else {
+            sendVolumeKeyPressed();
+            resetTimer();
         }
-
-        sendVolumeChange(mIsVolumeUp);
-        addTimer(mState, IRT_MS);
     }
 }
diff --git a/services/core/java/com/android/server/input/InputManagerService.java b/services/core/java/com/android/server/input/InputManagerService.java
index 7c1681c..81b579d 100644
--- a/services/core/java/com/android/server/input/InputManagerService.java
+++ b/services/core/java/com/android/server/input/InputManagerService.java
@@ -241,6 +241,9 @@
     /** Switch code: Headphone/Microphone Jack.  When set, something is inserted. */
     public static final int SW_JACK_PHYSICAL_INSERT = 0x07;
 
+    /** Switch code: Camera lens cover. When set the lens is covered. */
+    public static final int SW_CAMERA_LENS_COVER = 0x09;
+
     public static final int SW_LID_BIT = 1 << SW_LID;
     public static final int SW_KEYPAD_SLIDE_BIT = 1 << SW_KEYPAD_SLIDE;
     public static final int SW_HEADPHONE_INSERT_BIT = 1 << SW_HEADPHONE_INSERT;
@@ -249,6 +252,7 @@
     public static final int SW_JACK_PHYSICAL_INSERT_BIT = 1 << SW_JACK_PHYSICAL_INSERT;
     public static final int SW_JACK_BITS =
             SW_HEADPHONE_INSERT_BIT | SW_MICROPHONE_INSERT_BIT | SW_JACK_PHYSICAL_INSERT_BIT | SW_LINEOUT_INSERT_BIT;
+    public static final int SW_CAMERA_LENS_COVER_BIT = 1 << SW_CAMERA_LENS_COVER;
 
     /** Whether to use the dev/input/event or uevent subsystem for the audio jack. */
     final boolean mUseDevInputEventForAudioJack;
@@ -693,7 +697,9 @@
             synchronized (mDataStore) {
                 for (int i = 0; i < numFullKeyboards; i++) {
                     final InputDevice inputDevice = mTempFullKeyboards.get(i);
-                    if (mDataStore.getCurrentKeyboardLayout(inputDevice.getDescriptor()) == null) {
+                    final String layout =
+                            getCurrentKeyboardLayoutForInputDevice(inputDevice.getIdentifier());
+                    if (layout == null) {
                         missingLayoutForExternalKeyboard = true;
                         if (i < numFullKeyboardsAdded) {
                             missingLayoutForExternalKeyboardAdded = true;
@@ -774,6 +780,8 @@
                     .setContentIntent(mKeyboardLayoutIntent)
                     .setSmallIcon(R.drawable.ic_settings_language)
                     .setPriority(Notification.PRIORITY_LOW)
+                    .setColor(mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color))
                     .build();
             mNotificationManager.notifyAsUser(null,
                     R.string.select_keyboard_layout_notification_title,
@@ -1378,6 +1386,11 @@
             mWindowManagerCallbacks.notifyLidSwitchChanged(whenNanos, lidOpen);
         }
 
+        if ((switchMask & SW_CAMERA_LENS_COVER_BIT) != 0) {
+            final boolean lensCovered = ((switchValues & SW_CAMERA_LENS_COVER_BIT) != 0);
+            mWindowManagerCallbacks.notifyCameraLensCoverSwitchChanged(whenNanos, lensCovered);
+        }
+
         if (mUseDevInputEventForAudioJack && (switchMask & SW_JACK_BITS) != 0) {
             mWiredAccessoryCallbacks.notifyWiredAccessoryChanged(whenNanos, switchValues,
                     switchMask);
@@ -1418,8 +1431,8 @@
     }
 
     // Native callback.
-    private int interceptWakeMotionBeforeQueueing(long whenNanos, int policyFlags) {
-        return mWindowManagerCallbacks.interceptWakeMotionBeforeQueueing(
+    private int interceptMotionBeforeQueueingNonInteractive(long whenNanos, int policyFlags) {
+        return mWindowManagerCallbacks.interceptMotionBeforeQueueingNonInteractive(
                 whenNanos, policyFlags);
     }
 
@@ -1573,6 +1586,8 @@
 
         public void notifyLidSwitchChanged(long whenNanos, boolean lidOpen);
 
+        public void notifyCameraLensCoverSwitchChanged(long whenNanos, boolean lensCovered);
+
         public void notifyInputChannelBroken(InputWindowHandle inputWindowHandle);
 
         public long notifyANR(InputApplicationHandle inputApplicationHandle,
@@ -1580,7 +1595,7 @@
 
         public int interceptKeyBeforeQueueing(KeyEvent event, int policyFlags);
 
-        public int interceptWakeMotionBeforeQueueing(long whenNanos, int policyFlags);
+        public int interceptMotionBeforeQueueingNonInteractive(long whenNanos, int policyFlags);
 
         public long interceptKeyBeforeDispatching(InputWindowHandle focus,
                 KeyEvent event, int policyFlags);
diff --git a/services/core/java/com/android/server/job/JobSchedulerService.java b/services/core/java/com/android/server/job/JobSchedulerService.java
index 14457ec..30154d7 100644
--- a/services/core/java/com/android/server/job/JobSchedulerService.java
+++ b/services/core/java/com/android/server/job/JobSchedulerService.java
@@ -117,6 +117,8 @@
      */
     final ArrayList<JobStatus> mPendingJobs = new ArrayList<JobStatus>();
 
+    final ArrayList<Integer> mStartedUsers = new ArrayList();
+
     final JobHandler mHandler;
     final JobSchedulerStub mJobSchedulerStub;
 
@@ -151,6 +153,18 @@
         }
     };
 
+    @Override
+    public void onStartUser(int userHandle) {
+        mStartedUsers.add(userHandle);
+        // Let's kick any outstanding jobs for this user.
+        mHandler.obtainMessage(MSG_CHECK_JOB).sendToTarget();
+    }
+
+    @Override
+    public void onStopUser(int userHandle) {
+        mStartedUsers.remove(Integer.valueOf(userHandle));
+    }
+
     /**
      * Entry point from client to schedule the provided job.
      * This cancels the job if it's already been scheduled, and replaces it with the one provided.
@@ -162,6 +176,7 @@
         JobStatus jobStatus = new JobStatus(job, uId);
         cancelJob(uId, job.getId());
         startTrackingJob(jobStatus);
+        mHandler.obtainMessage(MSG_CHECK_JOB).sendToTarget();
         return JobScheduler.RESULT_SUCCESS;
     }
 
@@ -184,9 +199,6 @@
             List<JobStatus> jobsForUser = mJobs.getJobsByUser(userHandle);
             for (int i=0; i<jobsForUser.size(); i++) {
                 JobStatus toRemove = jobsForUser.get(i);
-                if (DEBUG) {
-                    Slog.d(TAG, "Cancelling: " + toRemove);
-                }
                 cancelJobLocked(toRemove);
             }
         }
@@ -204,9 +216,6 @@
             List<JobStatus> jobsForUid = mJobs.getJobsByUid(uid);
             for (int i=0; i<jobsForUid.size(); i++) {
                 JobStatus toRemove = jobsForUid.get(i);
-                if (DEBUG) {
-                    Slog.d(TAG, "Cancelling: " + toRemove);
-                }
                 cancelJobLocked(toRemove);
             }
         }
@@ -392,26 +401,26 @@
         final JobInfo job = failureToReschedule.getJob();
 
         final long initialBackoffMillis = job.getInitialBackoffMillis();
-        final int backoffAttempt = failureToReschedule.getNumFailures() + 1;
-        long newEarliestRuntimeElapsed = elapsedNowMillis;
+        final int backoffAttempts = failureToReschedule.getNumFailures() + 1;
+        long delayMillis;
 
         switch (job.getBackoffPolicy()) {
-            case JobInfo.BackoffPolicy.LINEAR:
-                newEarliestRuntimeElapsed += initialBackoffMillis * backoffAttempt;
+            case JobInfo.BACKOFF_POLICY_LINEAR:
+                delayMillis = initialBackoffMillis * backoffAttempts;
                 break;
             default:
                 if (DEBUG) {
                     Slog.v(TAG, "Unrecognised back-off policy, defaulting to exponential.");
                 }
-            case JobInfo.BackoffPolicy.EXPONENTIAL:
-                newEarliestRuntimeElapsed +=
-                        Math.pow(initialBackoffMillis * 0.001, backoffAttempt) * 1000;
+            case JobInfo.BACKOFF_POLICY_EXPONENTIAL:
+                delayMillis =
+                        (long) Math.scalb(initialBackoffMillis, backoffAttempts - 1);
                 break;
         }
-        newEarliestRuntimeElapsed =
-                Math.min(newEarliestRuntimeElapsed, JobInfo.MAX_BACKOFF_DELAY_MILLIS);
-        return new JobStatus(failureToReschedule, newEarliestRuntimeElapsed,
-                JobStatus.NO_LATEST_RUNTIME, backoffAttempt);
+        delayMillis =
+                Math.min(delayMillis, JobInfo.MAX_BACKOFF_DELAY_MILLIS);
+        return new JobStatus(failureToReschedule, elapsedNowMillis + delayMillis,
+                JobStatus.NO_LATEST_RUNTIME, backoffAttempts);
     }
 
     /**
@@ -507,7 +516,9 @@
                 case MSG_JOB_EXPIRED:
                     synchronized (mJobs) {
                         JobStatus runNow = (JobStatus) message.obj;
-                        if (!mPendingJobs.contains(runNow)) {
+                        // runNow can be null, which is a controller's way of indicating that its
+                        // state is such that all ready jobs should be run immediately.
+                        if (runNow != null && !mPendingJobs.contains(runNow)) {
                             mPendingJobs.add(runNow);
                         }
                     }
@@ -530,14 +541,28 @@
         private void queueReadyJobsForExecutionH() {
             synchronized (mJobs) {
                 ArraySet<JobStatus> jobs = mJobs.getJobs();
+                if (DEBUG) {
+                    Slog.d(TAG, "queuing all ready jobs for execution:");
+                }
                 for (int i=0; i<jobs.size(); i++) {
                     JobStatus job = jobs.valueAt(i);
                     if (isReadyToBeExecutedLocked(job)) {
+                        if (DEBUG) {
+                            Slog.d(TAG, "    queued " + job.toShortString());
+                        }
                         mPendingJobs.add(job);
                     } else if (isReadyToBeCancelledLocked(job)) {
                         stopJobOnServiceContextLocked(job);
                     }
                 }
+                if (DEBUG) {
+                    final int queuedJobs = mPendingJobs.size();
+                    if (queuedJobs == 0) {
+                        Slog.d(TAG, "No jobs pending.");
+                    } else {
+                        Slog.d(TAG, queuedJobs + " jobs queued.");
+                    }
+                }
             }
         }
 
@@ -607,9 +632,20 @@
          *      - It's ready.
          *      - It's not pending.
          *      - It's not already running on a JSC.
+         *      - The user that requested the job is running.
          */
         private boolean isReadyToBeExecutedLocked(JobStatus job) {
-              return job.isReady() && !mPendingJobs.contains(job) && !isCurrentlyActiveLocked(job);
+            final boolean jobReady = job.isReady();
+            final boolean jobPending = mPendingJobs.contains(job);
+            final boolean jobActive = isCurrentlyActiveLocked(job);
+            final boolean userRunning = mStartedUsers.contains(job.getUserId());
+
+            if (DEBUG) {
+                Slog.v(TAG, "isReadyToBeExecutedLocked: " + job.toShortString()
+                        + " ready=" + jobReady + " pending=" + jobPending
+                        + " active=" + jobActive + " userRunning=" + userRunning);
+            }
+            return userRunning && jobReady && !jobPending && !jobActive;
         }
 
         /**
@@ -629,6 +665,9 @@
         private void maybeRunPendingJobsH() {
             synchronized (mJobs) {
                 Iterator<JobStatus> it = mPendingJobs.iterator();
+                if (DEBUG) {
+                    Slog.d(TAG, "pending queue: " + mPendingJobs.size() + " jobs.");
+                }
                 while (it.hasNext()) {
                     JobStatus nextPending = it.next();
                     JobServiceContext availableContext = null;
@@ -791,7 +830,13 @@
     };
 
     void dumpInternal(PrintWriter pw) {
+        final long now = SystemClock.elapsedRealtime();
         synchronized (mJobs) {
+            pw.print("Started users: ");
+            for (int i=0; i<mStartedUsers.size(); i++) {
+                pw.print("u" + mStartedUsers.get(i) + " ");
+            }
+            pw.println();
             pw.println("Registered jobs:");
             if (mJobs.size() > 0) {
                 ArraySet<JobStatus> jobs = mJobs.getJobs();
@@ -800,15 +845,14 @@
                     job.dump(pw, "  ");
                 }
             } else {
-                pw.println();
-                pw.println("No jobs scheduled.");
+                pw.println("  None.");
             }
             for (int i=0; i<mControllers.size(); i++) {
                 pw.println();
                 mControllers.get(i).dumpControllerState(pw);
             }
             pw.println();
-            pw.println("Pending");
+            pw.println("Pending:");
             for (int i=0; i<mPendingJobs.size(); i++) {
                 pw.println(mPendingJobs.get(i).hashCode());
             }
@@ -819,10 +863,14 @@
                 if (jsc.isAvailable()) {
                     continue;
                 } else {
-                    pw.println(jsc.getRunningJob().hashCode() + " for: " +
-                            (SystemClock.elapsedRealtime()
-                                    - jsc.getExecutionStartTimeElapsed())/1000 + "s " +
-                            "timeout: " + jsc.getTimeoutElapsed());
+                    final long timeout = jsc.getTimeoutElapsed();
+                    pw.print("Running for: ");
+                    pw.print((now - jsc.getExecutionStartTimeElapsed())/1000);
+                    pw.print("s timeout=");
+                    pw.print(timeout);
+                    pw.print(" fromnow=");
+                    pw.println(timeout-now);
+                    jsc.getRunningJob().dump(pw, "  ");
                 }
             }
             pw.println();
diff --git a/services/core/java/com/android/server/job/JobServiceContext.java b/services/core/java/com/android/server/job/JobServiceContext.java
index 5297911..9df21a2 100644
--- a/services/core/java/com/android/server/job/JobServiceContext.java
+++ b/services/core/java/com/android/server/job/JobServiceContext.java
@@ -153,10 +153,12 @@
             }
 
             mRunningJob = job;
-            mParams = new JobParameters(job.getJobId(), job.getExtras(), this);
+            mParams = new JobParameters(this, job.getJobId(), job.getExtras(),
+                    !job.isConstraintsSatisfied());
             mExecutionStartTimeElapsed = SystemClock.elapsedRealtime();
 
             mVerb = VERB_BINDING;
+            scheduleOpTimeOut();
             final Intent intent = new Intent().setComponent(job.getServiceComponent());
             boolean binding = mContext.bindServiceAsUser(intent, this,
                     Context.BIND_AUTO_CREATE | Context.BIND_NOT_FOREGROUND,
@@ -168,6 +170,7 @@
                 mRunningJob = null;
                 mParams = null;
                 mExecutionStartTimeElapsed = 0L;
+                removeOpTimeOut();
                 return false;
             }
             try {
@@ -253,8 +256,6 @@
             return;
         }
         this.service = IJobService.Stub.asInterface(service);
-        // Remove all timeouts.
-        mCallbackHandler.removeMessages(MSG_TIMEOUT);
         final PowerManager pm =
                 (PowerManager) mContext.getSystemService(Context.POWER_SERVICE);
         mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, mRunningJob.getTag());
@@ -299,6 +300,7 @@
         public void handleMessage(Message message) {
             switch (message.what) {
                 case MSG_SERVICE_BOUND:
+                    removeOpTimeOut();
                     handleServiceBoundH();
                     break;
                 case MSG_CALLBACK:
@@ -306,7 +308,7 @@
                         Slog.d(TAG, "MSG_CALLBACK of : " + mRunningJob + " v:" +
                                 (mVerb >= 0 ? VERB_STRINGS[mVerb] : "[invalid]"));
                     }
-                    removeMessages(MSG_TIMEOUT);
+                    removeOpTimeOut();
 
                     if (mVerb == VERB_STARTING) {
                         final boolean workOngoing = message.arg2 == 1;
@@ -337,6 +339,9 @@
 
         /** Start the job on the service. */
         private void handleServiceBoundH() {
+            if (DEBUG) {
+                Slog.d(TAG, "MSG_SERVICE_BOUND for " + mRunningJob.toShortString());
+            }
             if (mVerb != VERB_BINDING) {
                 Slog.e(TAG, "Sending onStartJob for a job that isn't pending. "
                         + VERB_STRINGS[mVerb]);
@@ -456,42 +461,36 @@
 
         /** Process MSG_TIMEOUT here. */
         private void handleOpTimeoutH() {
-            if (JobSchedulerService.DEBUG) {
-                Slog.d(TAG, "MSG_TIMEOUT of " +
-                        mRunningJob.getServiceComponent().getShortClassName() + " : "
-                        + mParams.getJobId());
-            }
-
-            final int jobId = mParams.getJobId();
             switch (mVerb) {
+                case VERB_BINDING:
+                    Slog.e(TAG, "Time-out while trying to bind " + mRunningJob.toShortString() +
+                            ", dropping.");
+                    closeAndCleanupJobH(false /* needsReschedule */);
+                    break;
                 case VERB_STARTING:
                     // Client unresponsive - wedged or failed to respond in time. We don't really
                     // know what happened so let's log it and notify the JobScheduler
                     // FINISHED/NO-RETRY.
                     Slog.e(TAG, "No response from client for onStartJob '" +
-                            mRunningJob.getServiceComponent().getShortClassName() + "' jId: "
-                            + jobId);
+                            mRunningJob.toShortString());
                     closeAndCleanupJobH(false /* needsReschedule */);
                     break;
                 case VERB_STOPPING:
                     // At least we got somewhere, so fail but ask the JobScheduler to reschedule.
                     Slog.e(TAG, "No response from client for onStopJob, '" +
-                            mRunningJob.getServiceComponent().getShortClassName() + "' jId: "
-                            + jobId);
+                            mRunningJob.toShortString());
                     closeAndCleanupJobH(true /* needsReschedule */);
                     break;
                 case VERB_EXECUTING:
                     // Not an error - client ran out of time.
                     Slog.i(TAG, "Client timed out while executing (no jobFinished received)." +
-                            " sending onStop. "  +
-                            mRunningJob.getServiceComponent().getShortClassName() + "' jId: "
-                            + jobId);
+                            " sending onStop. "  + mRunningJob.toShortString());
                     sendStopMessageH();
                     break;
                 default:
-                    Slog.e(TAG, "Handling timeout for an unknown active job state: "
-                            + mRunningJob);
-                    return;
+                    Slog.e(TAG, "Handling timeout for an invalid job state: " +
+                            mRunningJob.toShortString() + ", dropping.");
+                    closeAndCleanupJobH(false /* needsReschedule */);
             }
         }
 
@@ -500,7 +499,7 @@
          * VERB_STOPPING.
          */
         private void sendStopMessageH() {
-            mCallbackHandler.removeMessages(MSG_TIMEOUT);
+            removeOpTimeOut();
             if (mVerb != VERB_EXECUTING) {
                 Slog.e(TAG, "Sending onStopJob for a job that isn't started. " + mRunningJob);
                 closeAndCleanupJobH(false /* reschedule */);
@@ -530,7 +529,9 @@
                 } catch (RemoteException e) {
                     // Whatever.
                 }
-                mWakeLock.release();
+                if (mWakeLock != null) {
+                    mWakeLock.release();
+                }
                 mContext.unbindService(JobServiceContext.this);
                 mWakeLock = null;
                 mRunningJob = null;
@@ -540,32 +541,37 @@
                 service = null;
                 mAvailable = true;
             }
-            removeMessages(MSG_TIMEOUT);
+            removeOpTimeOut();
             removeMessages(MSG_CALLBACK);
             removeMessages(MSG_SERVICE_BOUND);
             removeMessages(MSG_CANCEL);
             removeMessages(MSG_SHUTDOWN_EXECUTION);
             mCompletedListener.onJobCompleted(completedJob, reschedule);
         }
+    }
 
-        /**
-         * Called when sending a message to the client, over whose execution we have no control. If
-         * we haven't received a response in a certain amount of time, we want to give up and carry
-         * on with life.
-         */
-        private void scheduleOpTimeOut() {
-            mCallbackHandler.removeMessages(MSG_TIMEOUT);
+    /**
+     * Called when sending a message to the client, over whose execution we have no control. If
+     * we haven't received a response in a certain amount of time, we want to give up and carry
+     * on with life.
+     */
+    private void scheduleOpTimeOut() {
+        removeOpTimeOut();
 
-            final long timeoutMillis = (mVerb == VERB_EXECUTING) ?
-                    EXECUTING_TIMESLICE_MILLIS : OP_TIMEOUT_MILLIS;
-            if (DEBUG) {
-                Slog.d(TAG, "Scheduling time out for '" +
-                        mRunningJob.getServiceComponent().getShortClassName() + "' jId: " +
-                        mParams.getJobId() + ", in " + (timeoutMillis / 1000) + " s");
-            }
-            Message m = mCallbackHandler.obtainMessage(MSG_TIMEOUT);
-            mCallbackHandler.sendMessageDelayed(m, timeoutMillis);
-            mTimeoutElapsed = SystemClock.elapsedRealtime() + timeoutMillis;
+        final long timeoutMillis = (mVerb == VERB_EXECUTING) ?
+                EXECUTING_TIMESLICE_MILLIS : OP_TIMEOUT_MILLIS;
+        if (DEBUG) {
+            Slog.d(TAG, "Scheduling time out for '" +
+                    mRunningJob.getServiceComponent().getShortClassName() + "' jId: " +
+                    mParams.getJobId() + ", in " + (timeoutMillis / 1000) + " s");
         }
+        Message m = mCallbackHandler.obtainMessage(MSG_TIMEOUT);
+        mCallbackHandler.sendMessageDelayed(m, timeoutMillis);
+        mTimeoutElapsed = SystemClock.elapsedRealtime() + timeoutMillis;
+    }
+
+
+    private void removeOpTimeOut() {
+        mCallbackHandler.removeMessages(MSG_TIMEOUT);
     }
 }
diff --git a/services/core/java/com/android/server/job/JobStore.java b/services/core/java/com/android/server/job/JobStore.java
index 46f557f..df12e1a 100644
--- a/services/core/java/com/android/server/job/JobStore.java
+++ b/services/core/java/com/android/server/job/JobStore.java
@@ -515,7 +515,7 @@
             // Read out job identifier attributes.
             try {
                 jobBuilder = buildBuilderFromXml(parser);
-                jobBuilder.setIsPersisted(true);
+                jobBuilder.setPersisted(true);
                 uid = Integer.valueOf(parser.getAttributeValue(null, "uid"));
             } catch (NumberFormatException e) {
                 Slog.e(TAG, "Error parsing job's required fields, skipping");
@@ -622,11 +622,11 @@
         private void buildConstraintsFromXml(JobInfo.Builder jobBuilder, XmlPullParser parser) {
             String val = parser.getAttributeValue(null, "unmetered");
             if (val != null) {
-                jobBuilder.setRequiredNetworkCapabilities(JobInfo.NetworkType.UNMETERED);
+                jobBuilder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_UNMETERED);
             }
             val = parser.getAttributeValue(null, "connectivity");
             if (val != null) {
-                jobBuilder.setRequiredNetworkCapabilities(JobInfo.NetworkType.ANY);
+                jobBuilder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_ANY);
             }
             val = parser.getAttributeValue(null, "idle");
             if (val != null) {
diff --git a/services/core/java/com/android/server/job/StateChangedListener.java b/services/core/java/com/android/server/job/StateChangedListener.java
index 90c203a..97dfad3 100644
--- a/services/core/java/com/android/server/job/StateChangedListener.java
+++ b/services/core/java/com/android/server/job/StateChangedListener.java
@@ -33,7 +33,8 @@
     /**
      * Called by the controller to notify the JobManager that regardless of the state of the task,
      * it must be run immediately.
-     * @param jobStatus The state of the task which is to be run immediately.
+     * @param jobStatus The state of the task which is to be run immediately. <strong>null
+     *                  indicates to the scheduler that any ready jobs should be flushed.</strong>
      */
     public void onRunJobNow(JobStatus jobStatus);
 }
diff --git a/services/core/java/com/android/server/job/controllers/BatteryController.java b/services/core/java/com/android/server/job/controllers/BatteryController.java
index 538a252..309e034 100644
--- a/services/core/java/com/android/server/job/controllers/BatteryController.java
+++ b/services/core/java/com/android/server/job/controllers/BatteryController.java
@@ -84,15 +84,15 @@
 
     @Override
     public void maybeStartTrackingJob(JobStatus taskStatus) {
+        final boolean isOnStablePower = mChargeTracker.isOnStablePower();
         if (taskStatus.hasChargingConstraint()) {
-            final boolean isOnStablePower = mChargeTracker.isOnStablePower();
             synchronized (mTrackedTasks) {
                 mTrackedTasks.add(taskStatus);
                 taskStatus.chargingConstraintSatisfied.set(isOnStablePower);
             }
-            if (isOnStablePower) {
-                mStateChangedListener.onControllerStateChanged();
-            }
+        }
+        if (isOnStablePower) {
+            mChargeTracker.setStableChargingAlarm();
         }
     }
 
@@ -119,9 +119,15 @@
                 }
             }
         }
+        // Let the scheduler know that state has changed. This may or may not result in an
+        // execution.
         if (reportChange) {
             mStateChangedListener.onControllerStateChanged();
         }
+        // Also tell the scheduler that any ready jobs should be flushed.
+        if (stablePower) {
+            mStateChangedListener.onRunJobNow(null);
+        }
     }
 
     public class ChargingTracker extends BroadcastReceiver {
@@ -196,9 +202,7 @@
                 }
                 // Set up an alarm for ACTION_CHARGING_STABLE - we don't want to kick off tasks
                 // here if the user unplugs the phone immediately.
-                mAlarm.set(AlarmManager.ELAPSED_REALTIME_WAKEUP,
-                        SystemClock.elapsedRealtime() + STABLE_CHARGING_THRESHOLD_MILLIS,
-                        mStableChargingTriggerIntent);
+                setStableChargingAlarm();
                 mCharging = true;
             } else if (Intent.ACTION_POWER_DISCONNECTED.equals(action)) {
                 if (DEBUG) {
@@ -211,7 +215,7 @@
             }else if (ACTION_CHARGING_STABLE.equals(action)) {
                 // Here's where we actually do the notify for a task being ready.
                 if (DEBUG) {
-                    Slog.d(TAG, "Battery connected fired @ " + SystemClock.elapsedRealtime()
+                    Slog.d(TAG, "Stable charging fired @ " + SystemClock.elapsedRealtime()
                             + " charging: " + mCharging);
                 }
                 if (mCharging) {  // Should never receive this intent if mCharging is false.
@@ -219,6 +223,17 @@
                 }
             }
         }
+
+        void setStableChargingAlarm() {
+            final long alarmTriggerElapsed =
+                    SystemClock.elapsedRealtime() + STABLE_CHARGING_THRESHOLD_MILLIS;
+            if (DEBUG) {
+                Slog.d(TAG, "Setting stable alarm to go off in " +
+                        (STABLE_CHARGING_THRESHOLD_MILLIS / 1000) + "s");
+            }
+            mAlarm.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, alarmTriggerElapsed,
+                    mStableChargingTriggerIntent);
+        }
     }
 
     @Override
diff --git a/services/core/java/com/android/server/job/controllers/JobStatus.java b/services/core/java/com/android/server/job/controllers/JobStatus.java
index 652d8f8..e3c55b6 100644
--- a/services/core/java/com/android/server/job/controllers/JobStatus.java
+++ b/services/core/java/com/android/server/job/controllers/JobStatus.java
@@ -21,6 +21,7 @@
 import android.os.PersistableBundle;
 import android.os.SystemClock;
 import android.os.UserHandle;
+import android.text.format.DateUtils;
 
 import java.io.PrintWriter;
 import java.util.concurrent.atomic.AtomicBoolean;
@@ -41,6 +42,7 @@
     public static final long NO_EARLIEST_RUNTIME = 0L;
 
     final JobInfo job;
+    /** Uid of the package requesting this job. */
     final int uId;
     final String name;
     final String tag;
@@ -157,11 +159,11 @@
     }
 
     public boolean hasConnectivityConstraint() {
-        return job.getNetworkCapabilities() == JobInfo.NetworkType.ANY;
+        return job.getNetworkType() == JobInfo.NETWORK_TYPE_ANY;
     }
 
     public boolean hasUnmeteredConstraint() {
-        return job.getNetworkCapabilities() == JobInfo.NetworkType.UNMETERED;
+        return job.getNetworkType() == JobInfo.NETWORK_TYPE_UNMETERED;
     }
 
     public boolean hasChargingConstraint() {
@@ -193,16 +195,23 @@
     }
 
     /**
-     * @return Whether or not this job is ready to run, based on its requirements.
+     * @return Whether or not this job is ready to run, based on its requirements. This is true if
+     * the constraints are satisfied <strong>or</strong> the deadline on the job has expired.
      */
     public synchronized boolean isReady() {
+        return isConstraintsSatisfied()
+                || (hasDeadlineConstraint() && deadlineConstraintSatisfied.get());
+    }
+
+    /**
+     * @return Whether the constraints set on this job are satisfied.
+     */
+    public synchronized boolean isConstraintsSatisfied() {
         return (!hasChargingConstraint() || chargingConstraintSatisfied.get())
                 && (!hasTimingDelayConstraint() || timeDelayConstraintSatisfied.get())
                 && (!hasConnectivityConstraint() || connectivityConstraintSatisfied.get())
                 && (!hasUnmeteredConstraint() || unmeteredConstraintSatisfied.get())
-                && (!hasIdleConstraint() || idleConstraintSatisfied.get())
-                // Also ready if the deadline has expired - special case.
-                || (hasDeadlineConstraint() && deadlineConstraintSatisfied.get());
+                && (!hasIdleConstraint() || idleConstraintSatisfied.get());
     }
 
     public boolean matches(int uid, int jobId) {
@@ -214,14 +223,42 @@
         return String.valueOf(hashCode()).substring(0, 3) + ".."
                 + ":[" + job.getService()
                 + ",jId=" + job.getId()
-                + ",R=(" + earliestRunTimeElapsedMillis + "," + latestRunTimeElapsedMillis + ")"
-                + ",N=" + job.getNetworkCapabilities() + ",C=" + job.isRequireCharging()
+                + ",u" + getUserId()
+                + ",R=(" + formatRunTime(earliestRunTimeElapsedMillis, NO_EARLIEST_RUNTIME)
+                + "," + formatRunTime(latestRunTimeElapsedMillis, NO_LATEST_RUNTIME) + ")"
+                + ",N=" + job.getNetworkType() + ",C=" + job.isRequireCharging()
                 + ",I=" + job.isRequireDeviceIdle() + ",F=" + numFailures
+                + ",P=" + job.isPersisted()
                 + (isReady() ? "(READY)" : "")
                 + "]";
     }
+
+    private String formatRunTime(long runtime, long  defaultValue) {
+        if (runtime == defaultValue) {
+            return "none";
+        } else {
+            long elapsedNow = SystemClock.elapsedRealtime();
+            long nextRuntime = runtime - elapsedNow;
+            if (nextRuntime > 0) {
+                return DateUtils.formatElapsedTime(nextRuntime / 1000);
+            } else {
+                return "-" + DateUtils.formatElapsedTime(nextRuntime / -1000);
+            }
+        }
+    }
+
+    /**
+     * Convenience function to identify a job uniquely without pulling all the data that
+     * {@link #toString()} returns.
+     */
+    public String toShortString() {
+        return job.getService().flattenToShortString() + " jId=" + job.getId() +
+                ", u" + getUserId();
+    }
+
     // Dumpsys infrastructure
     public void dump(PrintWriter pw, String prefix) {
+        pw.print(prefix);
         pw.println(this.toString());
     }
 }
diff --git a/services/core/java/com/android/server/job/controllers/TimeController.java b/services/core/java/com/android/server/job/controllers/TimeController.java
index e46226c..4c6cb17 100644
--- a/services/core/java/com/android/server/job/controllers/TimeController.java
+++ b/services/core/java/com/android/server/job/controllers/TimeController.java
@@ -49,8 +49,6 @@
     private final PendingIntent mDeadlineExpiredAlarmIntent;
     /** Set an alarm for the next job delay expiry. This*/
     private final PendingIntent mNextDelayExpiredAlarmIntent;
-    /** Constant time determining how near in the future we'll set an alarm for. */
-    private static final long MIN_WAKEUP_INTERVAL_MILLIS = 15 * 1000;
 
     private long mNextJobExpiredElapsedMillis;
     private long mNextDelayExpiredElapsedMillis;
@@ -218,11 +216,7 @@
      * This alarm <b>will not</b> wake up the phone.
      */
     private void setDelayExpiredAlarm(long alarmTimeElapsedMillis) {
-        final long earliestWakeupTimeElapsed =
-                SystemClock.elapsedRealtime() + MIN_WAKEUP_INTERVAL_MILLIS;
-        if (alarmTimeElapsedMillis < earliestWakeupTimeElapsed) {
-            alarmTimeElapsedMillis = earliestWakeupTimeElapsed;
-        }
+        alarmTimeElapsedMillis = maybeAdjustAlarmTime(alarmTimeElapsedMillis);
         mNextDelayExpiredElapsedMillis = alarmTimeElapsedMillis;
         updateAlarmWithPendingIntent(mNextDelayExpiredAlarmIntent, mNextDelayExpiredElapsedMillis);
     }
@@ -233,15 +227,19 @@
      * This alarm <b>will</b> wake up the phone.
      */
     private void setDeadlineExpiredAlarm(long alarmTimeElapsedMillis) {
-        final long earliestWakeupTimeElapsed =
-                SystemClock.elapsedRealtime() + MIN_WAKEUP_INTERVAL_MILLIS;
-        if (alarmTimeElapsedMillis < earliestWakeupTimeElapsed) {
-            alarmTimeElapsedMillis = earliestWakeupTimeElapsed;
-        }
+        alarmTimeElapsedMillis = maybeAdjustAlarmTime(alarmTimeElapsedMillis);
         mNextJobExpiredElapsedMillis = alarmTimeElapsedMillis;
         updateAlarmWithPendingIntent(mDeadlineExpiredAlarmIntent, mNextJobExpiredElapsedMillis);
     }
 
+    private long maybeAdjustAlarmTime(long proposedAlarmTimeElapsedMillis) {
+        final long earliestWakeupTimeElapsed = SystemClock.elapsedRealtime();
+        if (proposedAlarmTimeElapsedMillis < earliestWakeupTimeElapsed) {
+            return earliestWakeupTimeElapsed;
+        }
+        return proposedAlarmTimeElapsedMillis;
+    }
+
     private void updateAlarmWithPendingIntent(PendingIntent pi, long alarmTimeElapsed) {
         ensureAlarmService();
         if (alarmTimeElapsed == Long.MAX_VALUE) {
diff --git a/services/core/java/com/android/server/location/GpsLocationProvider.java b/services/core/java/com/android/server/location/GpsLocationProvider.java
index 753ae39..f1c5a6c 100644
--- a/services/core/java/com/android/server/location/GpsLocationProvider.java
+++ b/services/core/java/com/android/server/location/GpsLocationProvider.java
@@ -22,6 +22,7 @@
 import com.android.internal.location.GpsNetInitiatedHandler.GpsNiNotification;
 import com.android.internal.location.ProviderProperties;
 import com.android.internal.location.ProviderRequest;
+import com.android.internal.R;
 import com.android.internal.telephony.Phone;
 import com.android.internal.telephony.PhoneConstants;
 
@@ -76,6 +77,7 @@
 import android.util.Log;
 import android.util.NtpTrustedTime;
 
+import java.io.ByteArrayOutputStream;
 import java.io.File;
 import java.io.FileDescriptor;
 import java.io.FileInputStream;
@@ -138,7 +140,7 @@
     private static final int LOCATION_HAS_BEARING = 8;
     private static final int LOCATION_HAS_ACCURACY = 16;
 
-// IMPORTANT - the GPS_DELETE_* symbols here must match constants in gps.h
+    // IMPORTANT - the GPS_DELETE_* symbols here must match constants in gps.h
     private static final int GPS_DELETE_EPHEMERIS = 0x0001;
     private static final int GPS_DELETE_ALMANAC = 0x0002;
     private static final int GPS_DELETE_POSITION = 0x0004;
@@ -160,6 +162,10 @@
     private static final int GPS_CAPABILITY_SINGLE_SHOT = 0x0000008;
     private static final int GPS_CAPABILITY_ON_DEMAND_TIME = 0x0000010;
 
+    // The AGPS SUPL mode
+    private static final int AGPS_SUPL_MODE_MSA = 0x02;
+    private static final int AGPS_SUPL_MODE_MSB = 0x01;
+
     // these need to match AGpsType enum in gps.h
     private static final int AGPS_TYPE_SUPL = 1;
     private static final int AGPS_TYPE_C2K = 2;
@@ -329,6 +335,7 @@
     private int mSuplServerPort;
     private String mC2KServerHost;
     private int mC2KServerPort;
+    private boolean mSuplEsEnabled = false;
 
     private final Context mContext;
     private final NtpTrustedTime mNtpTime;
@@ -367,6 +374,10 @@
     // Alarms
     private final static String ALARM_WAKEUP = "com.android.internal.location.ALARM_WAKEUP";
     private final static String ALARM_TIMEOUT = "com.android.internal.location.ALARM_TIMEOUT";
+
+    // SIM/Carrier info.
+    private final static String SIM_STATE_CHANGED = "android.intent.action.SIM_STATE_CHANGED";
+
     private final PowerManager mPowerManager;
     private final AlarmManager mAlarmManager;
     private final PendingIntent mWakeupIntent;
@@ -443,15 +454,14 @@
         return mGpsNavigationMessageProvider;
     }
 
-    private final BroadcastReceiver mBroadcastReciever = new BroadcastReceiver() {
+    private final BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
         @Override public void onReceive(Context context, Intent intent) {
             String action = intent.getAction();
 
+            if (DEBUG) Log.d(TAG, "receive broadcast intent, action: " + action);
             if (action.equals(ALARM_WAKEUP)) {
-                if (DEBUG) Log.d(TAG, "ALARM_WAKEUP");
                 startNavigating(false);
             } else if (action.equals(ALARM_TIMEOUT)) {
-                if (DEBUG) Log.d(TAG, "ALARM_TIMEOUT");
                 hibernate();
             } else if (action.equals(Intents.DATA_SMS_RECEIVED_ACTION)) {
                 checkSmsSuplInit(intent);
@@ -477,6 +487,17 @@
                     || Intent.ACTION_SCREEN_OFF.equals(action)
                     || Intent.ACTION_SCREEN_ON.equals(action)) {
                 updateLowPowerMode();
+            } else if (action.equals(SIM_STATE_CHANGED)) {
+                TelephonyManager phone = (TelephonyManager)
+                        mContext.getSystemService(Context.TELEPHONY_SERVICE);
+                String mccMnc = phone.getSimOperator();
+                if (!TextUtils.isEmpty(mccMnc)) {
+                    Log.d(TAG, "SIM MCC/MNC is available: " + mccMnc);
+                    synchronized (mLock) {
+                        reloadGpsProperties(context, mProperties);
+                        mNIHandler.setSuplEsEnabled(mSuplEsEnabled);
+                    }
+                }
             }
         }
     };
@@ -514,37 +535,84 @@
         return native_is_supported();
     }
 
-    private boolean loadPropertiesFile(String filename) {
-        mProperties = new Properties();
+    private void reloadGpsProperties(Context context, Properties properties) {
+        Log.d(TAG, "Reset GPS properties, previous size = " + properties.size());
+        loadPropertiesFromResource(context, properties);
+        boolean isPropertiesLoadedFromFile = false;
+        final String gpsHardware = SystemProperties.get("ro.hardware.gps");
+        if (!TextUtils.isEmpty(gpsHardware)) {
+            final String propFilename =
+                    PROPERTIES_FILE_PREFIX + "." + gpsHardware + PROPERTIES_FILE_SUFFIX;
+            isPropertiesLoadedFromFile =
+                    loadPropertiesFromFile(propFilename, properties);
+        }
+        if (!isPropertiesLoadedFromFile) {
+            loadPropertiesFromFile(DEFAULT_PROPERTIES_FILE, properties);
+        }
+        Log.d(TAG, "GPS properties reloaded, size = " + properties.size());
+
+        // TODO: we should get rid of C2K specific setting.
+        setSuplHostPort(properties.getProperty("SUPL_HOST"),
+                        properties.getProperty("SUPL_PORT"));
+        mC2KServerHost = properties.getProperty("C2K_HOST");
+        String portString = properties.getProperty("C2K_PORT");
+        if (mC2KServerHost != null && portString != null) {
+            try {
+                mC2KServerPort = Integer.parseInt(portString);
+            } catch (NumberFormatException e) {
+                Log.e(TAG, "unable to parse C2K_PORT: " + portString);
+            }
+        }
+
+        try {
+            // Convert properties to string contents and send it to HAL.
+            ByteArrayOutputStream baos = new ByteArrayOutputStream(4096);
+            properties.store(baos, null);
+            native_configuration_update(baos.toString());
+            Log.d(TAG, "final config = " + baos.toString());
+        } catch (IOException ex) {
+            Log.w(TAG, "failed to dump properties contents");
+        }
+
+        // SUPL_ES configuration.
+        String suplESProperty = mProperties.getProperty("SUPL_ES");
+        if (suplESProperty != null) {
+            try {
+                mSuplEsEnabled = (Integer.parseInt(suplESProperty) == 1);
+            } catch (NumberFormatException e) {
+                Log.e(TAG, "unable to parse SUPL_ES: " + suplESProperty);
+            }
+        }
+    }
+
+    private void loadPropertiesFromResource(Context context,
+                                            Properties properties) {
+        String[] configValues = context.getResources().getStringArray(
+                com.android.internal.R.array.config_gpsParameters);
+        for (String item : configValues) {
+            Log.d(TAG, "GpsParamsResource: " + item);
+            // We need to support "KEY =", but not "=VALUE".
+            String[] split = item.split("=");
+            if (split.length == 2) {
+                properties.setProperty(split[0].trim().toUpperCase(), split[1]);
+            } else {
+                Log.w(TAG, "malformed contents: " + item);
+            }
+        }
+    }
+
+    private boolean loadPropertiesFromFile(String filename,
+                                           Properties properties) {
         try {
             File file = new File(filename);
             FileInputStream stream = null;
             try {
                 stream = new FileInputStream(file);
-                mProperties.load(stream);
+                properties.load(stream);
             } finally {
                 IoUtils.closeQuietly(stream);
             }
 
-            mSuplServerHost = mProperties.getProperty("SUPL_HOST");
-            String portString = mProperties.getProperty("SUPL_PORT");
-            if (mSuplServerHost != null && portString != null) {
-                try {
-                    mSuplServerPort = Integer.parseInt(portString);
-                } catch (NumberFormatException e) {
-                    Log.e(TAG, "unable to parse SUPL_PORT: " + portString);
-                }
-            }
-
-            mC2KServerHost = mProperties.getProperty("C2K_HOST");
-            portString = mProperties.getProperty("C2K_PORT");
-            if (mC2KServerHost != null && portString != null) {
-                try {
-                    mC2KServerPort = Integer.parseInt(portString);
-                } catch (NumberFormatException e) {
-                    Log.e(TAG, "unable to parse C2K_PORT: " + portString);
-                }
-            }
         } catch (IOException e) {
             Log.w(TAG, "Could not open GPS configuration file " + filename);
             return false;
@@ -557,7 +625,6 @@
         mContext = context;
         mNtpTime = NtpTrustedTime.getInstance(context);
         mILocationManager = ilocationManager;
-        mNIHandler = new GpsNetInitiatedHandler(context);
 
         mLocation.setExtras(mLocationExtras);
 
@@ -580,16 +647,14 @@
         mBatteryStats = IBatteryStats.Stub.asInterface(ServiceManager.getService(
                 BatteryStats.SERVICE_NAME));
 
-        boolean propertiesLoaded = false;
-        final String gpsHardware = SystemProperties.get("ro.hardware.gps");
-        if (!TextUtils.isEmpty(gpsHardware)) {
-            final String propFilename = PROPERTIES_FILE_PREFIX + "." + gpsHardware + PROPERTIES_FILE_SUFFIX;
-            propertiesLoaded = loadPropertiesFile(propFilename);
-        }
+        // Load GPS configuration.
+        mProperties = new Properties();
+        reloadGpsProperties(mContext, mProperties);
 
-        if (!propertiesLoaded) {
-            loadPropertiesFile(DEFAULT_PROPERTIES_FILE);
-        }
+        // Create a GPS net-initiated handler.
+        mNIHandler = new GpsNetInitiatedHandler(context,
+                                                mNetInitiatedListener,
+                                                mSuplEsEnabled);
 
         // construct handler, listen for events
         mHandler = new ProviderHandler(looper);
@@ -625,7 +690,7 @@
         intentFilter.addAction(Intents.DATA_SMS_RECEIVED_ACTION);
         intentFilter.addDataScheme("sms");
         intentFilter.addDataAuthority("localhost","7275");
-        mContext.registerReceiver(mBroadcastReciever, intentFilter, null, mHandler);
+        mContext.registerReceiver(mBroadcastReceiver, intentFilter, null, mHandler);
 
         intentFilter = new IntentFilter();
         intentFilter.addAction(Intents.WAP_PUSH_RECEIVED_ACTION);
@@ -634,7 +699,7 @@
         } catch (IntentFilter.MalformedMimeTypeException e) {
             Log.w(TAG, "Malformed SUPL init mime type");
         }
-        mContext.registerReceiver(mBroadcastReciever, intentFilter, null, mHandler);
+        mContext.registerReceiver(mBroadcastReceiver, intentFilter, null, mHandler);
 
         intentFilter = new IntentFilter();
         intentFilter.addAction(ALARM_WAKEUP);
@@ -643,7 +708,8 @@
         intentFilter.addAction(PowerManager.ACTION_POWER_SAVE_MODE_CHANGED);
         intentFilter.addAction(Intent.ACTION_SCREEN_OFF);
         intentFilter.addAction(Intent.ACTION_SCREEN_ON);
-        mContext.registerReceiver(mBroadcastReciever, intentFilter, null, mHandler);
+        intentFilter.addAction(SIM_STATE_CHANGED);
+        mContext.registerReceiver(mBroadcastReceiver, intentFilter, null, mHandler);
     }
 
     /**
@@ -844,6 +910,52 @@
         sendMessage(ENABLE, 1, null);
     }
 
+    private void setSuplHostPort(String hostString, String portString) {
+        if (hostString != null) {
+            mSuplServerHost = hostString;
+        }
+        if (portString != null) {
+            try {
+                mSuplServerPort = Integer.parseInt(portString);
+            } catch (NumberFormatException e) {
+                Log.e(TAG, "unable to parse SUPL_PORT: " + portString);
+            }
+        }
+    }
+
+    /**
+     * Checks what SUPL mode to use, according to the AGPS mode as well as the
+     * allowed mode from properties.
+     *
+     * @param properties GPS properties
+     * @param agpsEnabled whether AGPS is enabled by settings value
+     * @param singleShot whether "singleshot" is needed
+     * @return SUPL mode (MSA vs MSB vs STANDALONE)
+     */
+    private int getSuplMode(Properties properties, boolean agpsEnabled, boolean singleShot) {
+        if (agpsEnabled) {
+            String modeString = properties.getProperty("SUPL_MODE");
+            int suplMode = 0;
+            if (!TextUtils.isEmpty(modeString)) {
+                try {
+                    suplMode = Integer.parseInt(modeString);
+                } catch (NumberFormatException e) {
+                    Log.e(TAG, "unable to parse SUPL_MODE: " + modeString);
+                    return GPS_POSITION_MODE_STANDALONE;
+                }
+            }
+            if (singleShot
+                    && hasCapability(GPS_CAPABILITY_MSA)
+                    && (suplMode & AGPS_SUPL_MODE_MSA) != 0) {
+                return GPS_POSITION_MODE_MS_ASSISTED;
+            } else if (hasCapability(GPS_CAPABILITY_MSB)
+                    && (suplMode & AGPS_SUPL_MODE_MSB) != 0) {
+                return GPS_POSITION_MODE_MS_BASED;
+            }
+        }
+        return GPS_POSITION_MODE_STANDALONE;
+    }
+
     private void handleEnable() {
         if (DEBUG) Log.d(TAG, "handleEnable");
 
@@ -1121,14 +1233,10 @@
             mSingleShot = singleShot;
             mPositionMode = GPS_POSITION_MODE_STANDALONE;
 
-             if (Settings.Global.getInt(mContext.getContentResolver(),
-                    Settings.Global.ASSISTED_GPS_ENABLED, 1) != 0) {
-                if (singleShot && hasCapability(GPS_CAPABILITY_MSA)) {
-                    mPositionMode = GPS_POSITION_MODE_MS_ASSISTED;
-                } else if (hasCapability(GPS_CAPABILITY_MSB)) {
-                    mPositionMode = GPS_POSITION_MODE_MS_BASED;
-                }
-            }
+            boolean agpsEnabled =
+                    (Settings.Global.getInt(mContext.getContentResolver(),
+                                            Settings.Global.ASSISTED_GPS_ENABLED, 1) != 0);
+            mPositionMode = getSuplMode(mProperties, agpsEnabled, singleShot);
 
             if (DEBUG) {
                 String mode;
@@ -2055,5 +2163,8 @@
     private static native boolean native_is_navigation_message_supported();
     private native boolean native_start_navigation_message_collection();
     private native boolean native_stop_navigation_message_collection();
+
+    // GNSS Configuration
+    private static native void native_configuration_update(String configData);
 }
 
diff --git a/services/core/java/com/android/server/location/GpsXtraDownloader.java b/services/core/java/com/android/server/location/GpsXtraDownloader.java
index 9dedb35..a5eef6a 100644
--- a/services/core/java/com/android/server/location/GpsXtraDownloader.java
+++ b/services/core/java/com/android/server/location/GpsXtraDownloader.java
@@ -19,6 +19,7 @@
 import android.content.Context;
 import android.net.Proxy;
 import android.net.http.AndroidHttpClient;
+import android.text.TextUtils;
 import android.util.Log;
 
 import org.apache.http.HttpEntity;
@@ -42,12 +43,14 @@
 public class GpsXtraDownloader {
 
     private static final String TAG = "GpsXtraDownloader";
-    static final boolean DEBUG = false;
-    
-    private Context mContext;
-    private String[] mXtraServers;
+    private static final boolean DEBUG = Log.isLoggable(TAG, Log.DEBUG);
+    private static final String DEFAULT_USER_AGENT = "Android";
+
+    private final Context mContext;
+    private final String[] mXtraServers;
     // to load balance our server requests
     private int mNextServerIndex;
+    private final String mUserAgent;
 
     GpsXtraDownloader(Context context, Properties properties) {
         mContext = context;
@@ -60,9 +63,18 @@
         if (server1 != null) count++;
         if (server2 != null) count++;
         if (server3 != null) count++;
-        
+
+        // Set User Agent from properties, if possible.
+        String agent = properties.getProperty("XTRA_USER_AGENT");
+        if (TextUtils.isEmpty(agent)) {
+            mUserAgent = DEFAULT_USER_AGENT;
+        } else {
+            mUserAgent = agent;
+        }
+
         if (count == 0) {
             Log.e(TAG, "No XTRA servers were specified in the GPS configuration");
+            mXtraServers = null;
             return;
         } else {
             mXtraServers = new String[count];
@@ -74,7 +86,7 @@
             // randomize first server
             Random random = new Random();
             mNextServerIndex = random.nextInt(count);
-        }       
+        }
     }
 
     byte[] downloadXtraData() {
@@ -91,7 +103,7 @@
         // load balance our requests among the available servers
         while (result == null) {
             result = doDownload(mXtraServers[mNextServerIndex], useProxy, proxyHost, proxyPort);
-            
+
             // increment mNextServerIndex and wrap around if necessary
             mNextServerIndex++;
             if (mNextServerIndex == mXtraServers.length) {
@@ -100,17 +112,18 @@
             // break if we have tried all the servers
             if (mNextServerIndex == startIndex) break;
         }
-    
+
         return result;
     }
 
-    protected static byte[] doDownload(String url, boolean isProxySet, 
+    protected byte[] doDownload(String url, boolean isProxySet,
             String proxyHost, int proxyPort) {
         if (DEBUG) Log.d(TAG, "Downloading XTRA data from " + url);
 
         AndroidHttpClient client = null;
         try {
-            client = AndroidHttpClient.newInstance("Android");
+            if (DEBUG) Log.d(TAG, "XTRA user agent: " + mUserAgent);
+            client = AndroidHttpClient.newInstance(mUserAgent);
             HttpUriRequest req = new HttpGet(url);
 
             if (isProxySet) {
diff --git a/services/core/java/com/android/server/media/MediaSessionRecord.java b/services/core/java/com/android/server/media/MediaSessionRecord.java
index f820a3c..5097927 100644
--- a/services/core/java/com/android/server/media/MediaSessionRecord.java
+++ b/services/core/java/com/android/server/media/MediaSessionRecord.java
@@ -23,17 +23,16 @@
 import android.content.pm.ParceledListSlice;
 import android.media.AudioManager;
 import android.media.AudioManagerInternal;
+import android.media.MediaDescription;
 import android.media.MediaMetadata;
 import android.media.Rating;
 import android.media.VolumeProvider;
-import android.media.routing.IMediaRouter;
-import android.media.routing.IMediaRouterDelegate;
-import android.media.routing.IMediaRouterStateCallback;
 import android.media.session.ISession;
 import android.media.session.ISessionCallback;
 import android.media.session.ISessionController;
 import android.media.session.ISessionControllerCallback;
 import android.media.session.MediaController;
+import android.media.session.MediaController.PlaybackInfo;
 import android.media.session.MediaSession;
 import android.media.session.ParcelableVolumeInfo;
 import android.media.session.PlaybackState;
@@ -96,7 +95,6 @@
             new ArrayList<ISessionControllerCallback>();
 
     private long mFlags;
-    private IMediaRouter mMediaRouter;
     private PendingIntent mMediaButtonReceiver;
     private PendingIntent mLaunchIntent;
 
@@ -115,7 +113,7 @@
     private AudioAttributes mAudioAttrs;
     private AudioManager mAudioManager;
     private AudioManagerInternal mAudioManagerInternal;
-    private int mVolumeType = MediaSession.PLAYBACK_TYPE_LOCAL;
+    private int mVolumeType = PlaybackInfo.PLAYBACK_TYPE_LOCAL;
     private int mVolumeControlType = VolumeProvider.VOLUME_CONTROL_ABSOLUTE;
     private int mMaxVolume = 0;
     private int mCurrentVolume = 0;
@@ -231,9 +229,15 @@
      * {@link AudioManager#ADJUST_SAME}.
      *
      * @param direction The direction to adjust volume in.
+     * @param flags Any of the flags from {@link AudioManager}.
+     * @param packageName The package that made the original volume request.
+     * @param uid The uid that made the original volume request.
+     * @param useSuggested True to use adjustSuggestedStreamVolume instead of
+     *            adjustStreamVolume.
      */
-    public void adjustVolume(int direction, int flags, String packageName, int uid) {
-        if (isPlaybackActive(false)) {
+    public void adjustVolume(int direction, int flags, String packageName, int uid,
+            boolean useSuggested) {
+        if (isPlaybackActive(false) || hasFlag(MediaSession.FLAG_EXCLUSIVE_GLOBAL_PRIORITY)) {
             flags &= ~AudioManager.FLAG_PLAY_SOUND;
         }
         if (direction > 1) {
@@ -241,10 +245,15 @@
         } else if (direction < -1) {
             direction = -1;
         }
-        if (mVolumeType == MediaSession.PLAYBACK_TYPE_LOCAL) {
+        if (mVolumeType == PlaybackInfo.PLAYBACK_TYPE_LOCAL) {
             int stream = AudioAttributes.toLegacyStreamType(mAudioAttrs);
-            mAudioManagerInternal.adjustStreamVolumeForUid(stream, direction, flags, packageName,
-                    uid);
+            if (useSuggested) {
+                mAudioManagerInternal.adjustSuggestedStreamVolumeForUid(stream, direction, flags,
+                        packageName, uid);
+            } else {
+                mAudioManagerInternal.adjustStreamVolumeForUid(stream, direction, flags,
+                        packageName, uid);
+            }
         } else {
             if (mVolumeControlType == VolumeProvider.VOLUME_CONTROL_FIXED) {
                 // Nothing to do, the volume cannot be changed
@@ -269,7 +278,7 @@
     }
 
     public void setVolumeTo(int value, int flags, String packageName, int uid) {
-        if (mVolumeType == MediaSession.PLAYBACK_TYPE_LOCAL) {
+        if (mVolumeType == PlaybackInfo.PLAYBACK_TYPE_LOCAL) {
             int stream = AudioAttributes.toLegacyStreamType(mAudioAttrs);
             mAudioManagerInternal.setStreamVolumeForUid(stream, value, flags, packageName, uid);
         } else {
@@ -444,7 +453,7 @@
 
     private String getShortMetadataString() {
         int fields = mMetadata == null ? 0 : mMetadata.size();
-        MediaMetadata.Description description = mMetadata == null ? null : mMetadata
+        MediaDescription description = mMetadata == null ? null : mMetadata
                 .getDescription();
         return "size=" + fields + ", description=" + description;
     }
@@ -692,12 +701,6 @@
         }
 
         @Override
-        public void setMediaRouter(IMediaRouter router) {
-            mMediaRouter = router;
-            mHandler.post(MessageHandler.MSG_UPDATE_SESSION_STATE);
-        }
-
-        @Override
         public void setMediaButtonReceiver(PendingIntent pi) {
             mMediaButtonReceiver = pi;
         }
@@ -758,8 +761,8 @@
         public void setPlaybackToLocal(AudioAttributes attributes) {
             boolean typeChanged;
             synchronized (mLock) {
-                typeChanged = mVolumeType == MediaSession.PLAYBACK_TYPE_REMOTE;
-                mVolumeType = MediaSession.PLAYBACK_TYPE_LOCAL;
+                typeChanged = mVolumeType == PlaybackInfo.PLAYBACK_TYPE_REMOTE;
+                mVolumeType = PlaybackInfo.PLAYBACK_TYPE_LOCAL;
                 if (attributes != null) {
                     mAudioAttrs = attributes;
                 } else {
@@ -775,8 +778,8 @@
         public void setPlaybackToRemote(int control, int max) {
             boolean typeChanged;
             synchronized (mLock) {
-                typeChanged = mVolumeType == MediaSession.PLAYBACK_TYPE_LOCAL;
-                mVolumeType = MediaSession.PLAYBACK_TYPE_REMOTE;
+                typeChanged = mVolumeType == PlaybackInfo.PLAYBACK_TYPE_LOCAL;
+                mVolumeType = PlaybackInfo.PLAYBACK_TYPE_REMOTE;
                 mVolumeControlType = control;
                 mMaxVolume = max;
             }
@@ -829,9 +832,9 @@
             }
         }
 
-        public void playUri(Uri uri, Bundle extras) {
+        public void playFromMediaId(String mediaId, Bundle extras) {
             try {
-                mCb.onPlayUri(uri, extras);
+                mCb.onPlayFromMediaId(mediaId, extras);
             } catch (RemoteException e) {
                 Slog.e(TAG, "Remote failure in playUri.", e);
             }
@@ -1008,7 +1011,7 @@
                 int type;
                 int max;
                 int current;
-                if (mVolumeType == MediaSession.PLAYBACK_TYPE_REMOTE) {
+                if (mVolumeType == PlaybackInfo.PLAYBACK_TYPE_REMOTE) {
                     type = mVolumeControlType;
                     max = mMaxVolume;
                     current = mOptimisticVolume != -1 ? mOptimisticVolume
@@ -1028,7 +1031,7 @@
             int uid = Binder.getCallingUid();
             final long token = Binder.clearCallingIdentity();
             try {
-                MediaSessionRecord.this.adjustVolume(direction, flags, packageName, uid);
+                MediaSessionRecord.this.adjustVolume(direction, flags, packageName, uid, false);
             } finally {
                 Binder.restoreCallingIdentity(token);
             }
@@ -1051,8 +1054,8 @@
         }
 
         @Override
-        public void playUri(Uri uri, Bundle extras) throws RemoteException {
-            mSessionCb.playUri(uri, extras);
+        public void playFromMediaId(String mediaId, Bundle extras) throws RemoteException {
+            mSessionCb.playFromMediaId(mediaId, extras);
         }
 
         @Override
@@ -1061,7 +1064,7 @@
         }
 
         @Override
-        public void skipToTrack(long id) {
+        public void skipToQueueItem(long id) {
             mSessionCb.skipToTrack(id);
         }
 
@@ -1147,13 +1150,6 @@
         public boolean isTransportControlEnabled() {
             return MediaSessionRecord.this.isTransportControlEnabled();
         }
-
-        @Override
-        public IMediaRouterDelegate createMediaRouterDelegate(
-                IMediaRouterStateCallback callback) {
-            // todo
-            return null;
-        }
     }
 
     private class MessageHandler extends Handler {
diff --git a/services/core/java/com/android/server/media/MediaSessionService.java b/services/core/java/com/android/server/media/MediaSessionService.java
index 1221aa4..aaa29fc 100644
--- a/services/core/java/com/android/server/media/MediaSessionService.java
+++ b/services/core/java/com/android/server/media/MediaSessionService.java
@@ -31,12 +31,14 @@
 import android.content.pm.PackageManager;
 import android.database.ContentObserver;
 import android.media.AudioManager;
+import android.media.AudioSystem;
 import android.media.IAudioService;
 import android.media.IRemoteVolumeController;
 import android.media.session.IActiveSessionsListener;
 import android.media.session.ISession;
 import android.media.session.ISessionCallback;
 import android.media.session.ISessionManager;
+import android.media.session.MediaController.PlaybackInfo;
 import android.media.session.MediaSession;
 import android.net.Uri;
 import android.os.Binder;
@@ -799,7 +801,8 @@
 
             }
             if (session == null) {
-                if ((flags & AudioManager.FLAG_ACTIVE_MEDIA_ONLY) != 0) {
+                if ((flags & AudioManager.FLAG_ACTIVE_MEDIA_ONLY) != 0
+                        && !AudioSystem.isStreamActive(AudioManager.STREAM_MUSIC, 0)) {
                     if (DEBUG) {
                         Log.d(TAG, "No active session to adjust, skipping media only volume event");
                     }
@@ -813,8 +816,8 @@
                 }
             } else {
                 session.adjustVolume(direction, flags, getContext().getPackageName(),
-                        UserHandle.myUserId());
-                if (session.getPlaybackType() == MediaSession.PLAYBACK_TYPE_REMOTE
+                        UserHandle.myUserId(), true);
+                if (session.getPlaybackType() == PlaybackInfo.PLAYBACK_TYPE_REMOTE
                         && mRvc != null) {
                     try {
                         mRvc.remoteVolumeChanged(session.getControllerBinder(), flags);
diff --git a/services/core/java/com/android/server/media/MediaSessionStack.java b/services/core/java/com/android/server/media/MediaSessionStack.java
index fec11fba..a9bc818 100644
--- a/services/core/java/com/android/server/media/MediaSessionStack.java
+++ b/services/core/java/com/android/server/media/MediaSessionStack.java
@@ -16,6 +16,7 @@
 
 package com.android.server.media;
 
+import android.media.session.MediaController.PlaybackInfo;
 import android.media.session.PlaybackState;
 import android.media.session.MediaSession;
 import android.os.UserHandle;
@@ -209,7 +210,7 @@
         int size = records.size();
         for (int i = 0; i < size; i++) {
             MediaSessionRecord record = records.get(i);
-            if (record.getPlaybackType() == MediaSession.PLAYBACK_TYPE_REMOTE) {
+            if (record.getPlaybackType() == PlaybackInfo.PLAYBACK_TYPE_REMOTE) {
                 return record;
             }
         }
diff --git a/services/core/java/com/android/server/media/projection/MediaProjectionManagerService.java b/services/core/java/com/android/server/media/projection/MediaProjectionManagerService.java
index 289b5aa..8a1f3ad 100644
--- a/services/core/java/com/android/server/media/projection/MediaProjectionManagerService.java
+++ b/services/core/java/com/android/server/media/projection/MediaProjectionManagerService.java
@@ -26,6 +26,8 @@
 import android.media.projection.IMediaProjectionManager;
 import android.media.projection.IMediaProjection;
 import android.media.projection.IMediaProjectionCallback;
+import android.media.projection.IMediaProjectionWatcherCallback;
+import android.media.projection.MediaProjectionInfo;
 import android.media.projection.MediaProjectionManager;
 import android.os.Binder;
 import android.os.Handler;
@@ -34,6 +36,7 @@
 import android.os.Looper;
 import android.os.Message;
 import android.os.RemoteException;
+import android.os.UserHandle;
 import android.util.ArrayMap;
 import android.util.Slog;
 
@@ -59,15 +62,20 @@
     private static final String TAG = "MediaProjectionManagerService";
 
     private final Object mLock = new Object(); // Protects the list of media projections
-    private final Map<IBinder, MediaProjection> mProjectionGrants;
+    private final Map<IBinder, IBinder.DeathRecipient> mDeathEaters;
+    private final CallbackDelegate mCallbackDelegate;
 
     private final Context mContext;
     private final AppOpsManager mAppOps;
 
+    private IBinder mProjectionToken;
+    private MediaProjection mProjectionGrant;
+
     public MediaProjectionManagerService(Context context) {
         super(context);
         mContext = context;
-        mProjectionGrants = new ArrayMap<IBinder, MediaProjection>();
+        mDeathEaters = new ArrayMap<IBinder, IBinder.DeathRecipient>();
+        mCallbackDelegate = new CallbackDelegate();
         mAppOps = (AppOpsManager) mContext.getSystemService(Context.APP_OPS_SERVICE);
         Watchdog.getInstance().addMonitor(this);
     }
@@ -83,13 +91,96 @@
         synchronized (mLock) { /* check for deadlock */ }
     }
 
+    private void startProjectionLocked(final MediaProjection projection) {
+        if (mProjectionGrant != null) {
+            mProjectionGrant.stop();
+        }
+        mProjectionToken = projection.asBinder();
+        mProjectionGrant = projection;
+        dispatchStart(projection);
+    }
+
+    private void stopProjectionLocked(final MediaProjection projection) {
+        mProjectionToken = null;
+        mProjectionGrant = null;
+        dispatchStop(projection);
+    }
+
+    private void addCallback(final IMediaProjectionWatcherCallback callback) {
+        IBinder.DeathRecipient deathRecipient = new IBinder.DeathRecipient() {
+            @Override
+            public void binderDied() {
+                synchronized (mLock) {
+                    removeCallback(callback);
+                }
+            }
+        };
+        synchronized (mLock) {
+            mCallbackDelegate.add(callback);
+            linkDeathRecipientLocked(callback, deathRecipient);
+        }
+    }
+
+    private void removeCallback(IMediaProjectionWatcherCallback callback) {
+        synchronized (mLock) {
+            unlinkDeathRecipientLocked(callback);
+            mCallbackDelegate.remove(callback);
+        }
+    }
+
+    private void linkDeathRecipientLocked(IMediaProjectionWatcherCallback callback,
+            IBinder.DeathRecipient deathRecipient) {
+        try {
+            final IBinder token = callback.asBinder();
+            token.linkToDeath(deathRecipient, 0);
+            mDeathEaters.put(token, deathRecipient);
+        } catch (RemoteException e) {
+            Slog.e(TAG, "Unable to link to death for media projection monitoring callback", e);
+        }
+    }
+
+    private void unlinkDeathRecipientLocked(IMediaProjectionWatcherCallback callback) {
+        final IBinder token = callback.asBinder();
+        IBinder.DeathRecipient deathRecipient = mDeathEaters.remove(token);
+        if (deathRecipient != null) {
+            token.unlinkToDeath(deathRecipient, 0);
+        }
+    }
+
+    private void dispatchStart(MediaProjection projection) {
+        mCallbackDelegate.dispatchStart(projection);
+    }
+
+    private void dispatchStop(MediaProjection projection) {
+        mCallbackDelegate.dispatchStop(projection);
+    }
+
+    private boolean isValidMediaProjection(IBinder token) {
+        synchronized (mLock) {
+            if (mProjectionToken != null) {
+                return mProjectionToken.equals(token);
+            }
+            return false;
+        }
+    }
+
+    private MediaProjectionInfo getActiveProjectionInfo() {
+        synchronized (mLock) {
+            if (mProjectionGrant == null) {
+                return null;
+            }
+            return mProjectionGrant.getProjectionInfo();
+        }
+    }
+
     private void dump(final PrintWriter pw) {
         pw.println("MEDIA PROJECTION MANAGER (dumpsys media_projection)");
         synchronized (mLock) {
-            Collection<MediaProjection> projections = mProjectionGrants.values();
-            pw.println("Media Projections: size=" + projections.size());
-            for (MediaProjection mp : projections) {
-                mp.dump(pw, "  ");
+            pw.println("Media Projection: ");
+            if (mProjectionGrant != null ) {
+                mProjectionGrant.dump(pw);
+            } else {
+                pw.println("null");
             }
         }
     }
@@ -115,11 +206,14 @@
         @Override // Binder call
         public IMediaProjection createProjection(int uid, String packageName, int type,
                 boolean isPermanentGrant) {
-            if (mContext.checkCallingPermission(Manifest.permission.CREATE_MEDIA_PROJECTION)
+            if (mContext.checkCallingPermission(Manifest.permission.MANAGE_MEDIA_PROJECTION)
                         != PackageManager.PERMISSION_GRANTED) {
-                throw new SecurityException("Requires CREATE_MEDIA_PROJECTION in order to grant "
+                throw new SecurityException("Requires MANAGE_MEDIA_PROJECTION in order to grant "
                         + "projection permission");
             }
+            if (packageName == null || packageName.isEmpty()) {
+                throw new IllegalArgumentException("package name must not be empty");
+            }
             long callingToken = Binder.clearCallingIdentity();
             MediaProjection projection;
             try {
@@ -136,7 +230,71 @@
 
         @Override // Binder call
         public boolean isValidMediaProjection(IMediaProjection projection) {
-            return mProjectionGrants.containsKey(projection.asBinder());
+            return MediaProjectionManagerService.this.isValidMediaProjection(
+                    projection.asBinder());
+        }
+
+        @Override // Binder call
+        public MediaProjectionInfo getActiveProjectionInfo() {
+            if (mContext.checkCallingPermission(Manifest.permission.MANAGE_MEDIA_PROJECTION)
+                        != PackageManager.PERMISSION_GRANTED) {
+                throw new SecurityException("Requires MANAGE_MEDIA_PROJECTION in order to add "
+                        + "projection callbacks");
+            }
+            final long token = Binder.clearCallingIdentity();
+            try {
+                return MediaProjectionManagerService.this.getActiveProjectionInfo();
+            } finally {
+                Binder.restoreCallingIdentity(token);
+            }
+        }
+
+        @Override // Binder call
+        public void stopActiveProjection() {
+            if (mContext.checkCallingPermission(Manifest.permission.MANAGE_MEDIA_PROJECTION)
+                        != PackageManager.PERMISSION_GRANTED) {
+                throw new SecurityException("Requires MANAGE_MEDIA_PROJECTION in order to add "
+                        + "projection callbacks");
+            }
+            final long token = Binder.clearCallingIdentity();
+            try {
+                if (mProjectionGrant != null) {
+                    mProjectionGrant.stop();
+                }
+            } finally {
+                Binder.restoreCallingIdentity(token);
+            }
+
+        }
+
+        @Override //Binder call
+        public void addCallback(final IMediaProjectionWatcherCallback callback) {
+            if (mContext.checkCallingPermission(Manifest.permission.MANAGE_MEDIA_PROJECTION)
+                        != PackageManager.PERMISSION_GRANTED) {
+                throw new SecurityException("Requires MANAGE_MEDIA_PROJECTION in order to add "
+                        + "projection callbacks");
+            }
+            final long token = Binder.clearCallingIdentity();
+            try {
+                MediaProjectionManagerService.this.addCallback(callback);
+            } finally {
+                Binder.restoreCallingIdentity(token);
+            }
+        }
+
+        @Override
+        public void removeCallback(IMediaProjectionWatcherCallback callback) {
+            if (mContext.checkCallingPermission(Manifest.permission.MANAGE_MEDIA_PROJECTION)
+                        != PackageManager.PERMISSION_GRANTED) {
+                throw new SecurityException("Requires MANAGE_MEDIA_PROJECTION in order to remove "
+                        + "projection callbacks");
+            }
+            final long token = Binder.clearCallingIdentity();
+            try {
+                MediaProjectionManagerService.this.removeCallback(callback);
+            } finally {
+                Binder.restoreCallingIdentity(token);
+            }
         }
 
         @Override // Binder call
@@ -157,25 +315,27 @@
             }
         }
 
+
         private boolean checkPermission(String packageName, String permission) {
             return mContext.getPackageManager().checkPermission(permission, packageName)
                     == PackageManager.PERMISSION_GRANTED;
         }
     }
 
-    private final class MediaProjection extends IMediaProjection.Stub implements DeathRecipient {
-        public int uid;
-        public String packageName;
+    private final class MediaProjection extends IMediaProjection.Stub {
+        public final int uid;
+        public final String packageName;
+        public final UserHandle userHandle;
 
         private IBinder mToken;
+        private IBinder.DeathRecipient mDeathEater;
         private int mType;
-        private CallbackDelegate mCallbackDelegate;
 
         public MediaProjection(int type, int uid, String packageName) {
             mType = type;
             this.uid = uid;
             this.packageName = packageName;
-            mCallbackDelegate = new CallbackDelegate();
+            userHandle = new UserHandle(UserHandle.getUserId(uid));
         }
 
         @Override // Binder call
@@ -220,50 +380,51 @@
         }
 
         @Override // Binder call
-        public void start(IMediaProjectionCallback callback) {
+        public void start(final IMediaProjectionCallback callback) {
             if (callback == null) {
                 throw new IllegalArgumentException("callback must not be null");
             }
             synchronized (mLock) {
-                if (mProjectionGrants.containsKey(asBinder())) {
+                if (isValidMediaProjection(asBinder())) {
                     throw new IllegalStateException(
                             "Cannot start already started MediaProjection");
                 }
-                addCallback(callback);
+                registerCallback(callback);
                 try {
                     mToken = callback.asBinder();
-                    mToken.linkToDeath(this, 0);
+                    mDeathEater = new IBinder.DeathRecipient() {
+                        @Override
+                        public void binderDied() {
+                            mCallbackDelegate.remove(callback);
+                            stop();
+                        }
+                    };
+                    mToken.linkToDeath(mDeathEater, 0);
                 } catch (RemoteException e) {
                     Slog.w(TAG,
                             "MediaProjectionCallbacks must be valid, aborting MediaProjection", e);
                     return;
                 }
-                mProjectionGrants.put(asBinder(), this);
+                startProjectionLocked(this);
             }
         }
 
         @Override // Binder call
         public void stop() {
             synchronized (mLock) {
-                if (!mProjectionGrants.containsKey(asBinder())) {
+                if (!isValidMediaProjection(asBinder())) {
                     Slog.w(TAG, "Attempted to stop inactive MediaProjection "
                             + "(uid=" + Binder.getCallingUid() + ", "
                             + "pid=" + Binder.getCallingPid() + ")");
                     return;
                 }
-                mToken.unlinkToDeath(this, 0);
-                mCallbackDelegate.dispatchStop();
-                mProjectionGrants.remove(asBinder());
+                mToken.unlinkToDeath(mDeathEater, 0);
+                stopProjectionLocked(this);
             }
         }
 
         @Override
-        public void binderDied() {
-            stop();
-        }
-
-        @Override
-        public void addCallback(IMediaProjectionCallback callback) {
+        public void registerCallback(IMediaProjectionCallback callback) {
             if (callback == null) {
                 throw new IllegalArgumentException("callback must not be null");
             }
@@ -271,59 +432,150 @@
         }
 
         @Override
-        public void removeCallback(IMediaProjectionCallback callback) {
+        public void unregisterCallback(IMediaProjectionCallback callback) {
             if (callback == null) {
                 throw new IllegalArgumentException("callback must not be null");
             }
             mCallbackDelegate.remove(callback);
         }
 
-        public void dump(PrintWriter pw, String prefix) {
-            pw.println(prefix + "(" + packageName + ", uid=" + uid + "): " + typeToString(mType));
+        public MediaProjectionInfo getProjectionInfo() {
+            return new MediaProjectionInfo(packageName, userHandle);
+        }
+
+        public void dump(PrintWriter pw) {
+            pw.println("(" + packageName + ", uid=" + uid + "): " + typeToString(mType));
         }
     }
 
+
     private static class CallbackDelegate {
-        private static final int MSG_ON_STOP = 0;
-        private List<IMediaProjectionCallback> mCallbacks;
+        private Map<IBinder, IMediaProjectionCallback> mClientCallbacks;
+        private Map<IBinder, IMediaProjectionWatcherCallback> mWatcherCallbacks;
         private Handler mHandler;
         private Object mLock = new Object();
 
         public CallbackDelegate() {
             mHandler = new Handler(Looper.getMainLooper(), null, true /*async*/);
-            mCallbacks = new ArrayList<IMediaProjectionCallback>();
+            mClientCallbacks = new ArrayMap<IBinder, IMediaProjectionCallback>();
+            mWatcherCallbacks = new ArrayMap<IBinder, IMediaProjectionWatcherCallback>();
         }
 
         public void add(IMediaProjectionCallback callback) {
             synchronized (mLock) {
-                mCallbacks.add(callback);
+                mClientCallbacks.put(callback.asBinder(), callback);
+            }
+        }
+
+        public void add(IMediaProjectionWatcherCallback callback) {
+            synchronized (mLock) {
+                mWatcherCallbacks.put(callback.asBinder(), callback);
             }
         }
 
         public void remove(IMediaProjectionCallback callback) {
             synchronized (mLock) {
-                mCallbacks.remove(callback);
+                mClientCallbacks.remove(callback.asBinder());
             }
         }
 
-        public void dispatchStop() {
+        public void remove(IMediaProjectionWatcherCallback callback) {
             synchronized (mLock) {
-                for (final IMediaProjectionCallback callback : mCallbacks) {
-                    mHandler.post(new Runnable() {
-                        @Override
-                        public void run() {
-                            try {
-                                callback.onStop();
-                            } catch (RemoteException e) {
-                                Slog.w(TAG, "Failed to notify media projection has stopped", e);
-                            }
-                        }
-                    });
+                mWatcherCallbacks.remove(callback.asBinder());
+            }
+        }
+
+        public void dispatchStart(MediaProjection projection) {
+            if (projection == null) {
+                Slog.e(TAG, "Tried to dispatch start notification for a null media projection."
+                        + " Ignoring!");
+                return;
+            }
+            synchronized (mLock) {
+                for (IMediaProjectionWatcherCallback callback : mWatcherCallbacks.values()) {
+                    MediaProjectionInfo info = projection.getProjectionInfo();
+                    mHandler.post(new WatcherStartCallback(info, callback));
+                }
+            }
+        }
+
+        public void dispatchStop(MediaProjection projection) {
+            if (projection == null) {
+                Slog.e(TAG, "Tried to dispatch stop notification for a null media projection."
+                        + " Ignoring!");
+                return;
+            }
+            synchronized (mLock) {
+                for (IMediaProjectionCallback callback : mClientCallbacks.values()) {
+                    mHandler.post(new ClientStopCallback(callback));
+                }
+
+                for (IMediaProjectionWatcherCallback callback : mWatcherCallbacks.values()) {
+                    MediaProjectionInfo info = projection.getProjectionInfo();
+                    mHandler.post(new WatcherStopCallback(info, callback));
                 }
             }
         }
     }
 
+    private static final class WatcherStartCallback implements Runnable {
+        private IMediaProjectionWatcherCallback mCallback;
+        private MediaProjectionInfo mInfo;
+
+        public WatcherStartCallback(MediaProjectionInfo info,
+                IMediaProjectionWatcherCallback callback) {
+            mInfo = info;
+            mCallback = callback;
+        }
+
+        @Override
+        public void run() {
+            try {
+                mCallback.onStart(mInfo);
+            } catch (RemoteException e) {
+                Slog.w(TAG, "Failed to notify media projection has stopped", e);
+            }
+        }
+    }
+
+    private static final class WatcherStopCallback implements Runnable {
+        private IMediaProjectionWatcherCallback mCallback;
+        private MediaProjectionInfo mInfo;
+
+        public WatcherStopCallback(MediaProjectionInfo info,
+                IMediaProjectionWatcherCallback callback) {
+            mInfo = info;
+            mCallback = callback;
+        }
+
+        @Override
+        public void run() {
+            try {
+                mCallback.onStop(mInfo);
+            } catch (RemoteException e) {
+                Slog.w(TAG, "Failed to notify media projection has stopped", e);
+            }
+        }
+    }
+
+    private static final class ClientStopCallback implements Runnable {
+        private IMediaProjectionCallback mCallback;
+
+        public ClientStopCallback(IMediaProjectionCallback callback) {
+            mCallback = callback;
+        }
+
+        @Override
+        public void run() {
+            try {
+                mCallback.onStop();
+            } catch (RemoteException e) {
+                Slog.w(TAG, "Failed to notify media projection has stopped", e);
+            }
+        }
+    }
+
+
     private static String typeToString(int type) {
         switch (type) {
             case MediaProjectionManager.TYPE_SCREEN_CAPTURE:
diff --git a/services/core/java/com/android/server/net/IpConfigStore.java b/services/core/java/com/android/server/net/IpConfigStore.java
index 907eeb2..857b9e9 100644
--- a/services/core/java/com/android/server/net/IpConfigStore.java
+++ b/services/core/java/com/android/server/net/IpConfigStore.java
@@ -20,10 +20,10 @@
 import android.net.IpConfiguration.IpAssignment;
 import android.net.IpConfiguration.ProxySettings;
 import android.net.LinkAddress;
-import android.net.LinkProperties;
 import android.net.NetworkUtils;
 import android.net.ProxyInfo;
 import android.net.RouteInfo;
+import android.net.StaticIpConfiguration;
 import android.os.Handler;
 import android.os.HandlerThread;
 import android.text.TextUtils;
@@ -41,6 +41,7 @@
 import java.io.FileOutputStream;
 import java.io.IOException;
 import java.net.InetAddress;
+import java.net.Inet4Address;
 import java.util.Map;
 
 public class IpConfigStore {
@@ -69,40 +70,32 @@
     }
 
     private boolean writeConfig(DataOutputStream out, int configKey,
-                                  IpConfiguration config) throws IOException {
+                                IpConfiguration config) throws IOException {
         boolean written = false;
 
         try {
-            LinkProperties linkProperties = config.linkProperties;
             switch (config.ipAssignment) {
                 case STATIC:
                     out.writeUTF(IP_ASSIGNMENT_KEY);
                     out.writeUTF(config.ipAssignment.toString());
-                    for (LinkAddress linkAddr : linkProperties.getLinkAddresses()) {
-                        out.writeUTF(LINK_ADDRESS_KEY);
-                        out.writeUTF(linkAddr.getAddress().getHostAddress());
-                        out.writeInt(linkAddr.getPrefixLength());
-                    }
-                    for (RouteInfo route : linkProperties.getRoutes()) {
-                        out.writeUTF(GATEWAY_KEY);
-                        LinkAddress dest = route.getDestinationLinkAddress();
-                        if (dest != null) {
-                            out.writeInt(1);
-                            out.writeUTF(dest.getAddress().getHostAddress());
-                            out.writeInt(dest.getPrefixLength());
-                        } else {
-                            out.writeInt(0);
+                    StaticIpConfiguration staticIpConfiguration = config.staticIpConfiguration;
+                    if (staticIpConfiguration != null) {
+                        if (staticIpConfiguration.ipAddress != null) {
+                            LinkAddress ipAddress = staticIpConfiguration.ipAddress;
+                            out.writeUTF(LINK_ADDRESS_KEY);
+                            out.writeUTF(ipAddress.getAddress().getHostAddress());
+                            out.writeInt(ipAddress.getPrefixLength());
                         }
-                        if (route.getGateway() != null) {
-                            out.writeInt(1);
-                            out.writeUTF(route.getGateway().getHostAddress());
-                        } else {
-                            out.writeInt(0);
+                        if (staticIpConfiguration.gateway != null) {
+                            out.writeUTF(GATEWAY_KEY);
+                            out.writeInt(0);  // Default route.
+                            out.writeInt(1);  // Have a gateway.
+                            out.writeUTF(staticIpConfiguration.gateway.getHostAddress());
                         }
-                    }
-                    for (InetAddress inetAddr : linkProperties.getDnsServers()) {
-                        out.writeUTF(DNS_KEY);
-                        out.writeUTF(inetAddr.getHostAddress());
+                        for (InetAddress inetAddr : staticIpConfiguration.dnsServers) {
+                            out.writeUTF(DNS_KEY);
+                            out.writeUTF(inetAddr.getHostAddress());
+                        }
                     }
                     written = true;
                     break;
@@ -121,7 +114,7 @@
 
             switch (config.proxySettings) {
                 case STATIC:
-                    ProxyInfo proxyProperties = linkProperties.getHttpProxy();
+                    ProxyInfo proxyProperties = config.httpProxy;
                     String exclusionList = proxyProperties.getExclusionListAsString();
                     out.writeUTF(PROXY_SETTINGS_KEY);
                     out.writeUTF(config.proxySettings.toString());
@@ -134,7 +127,7 @@
                     written = true;
                     break;
                 case PAC:
-                    ProxyInfo proxyPacProperties = linkProperties.getHttpProxy();
+                    ProxyInfo proxyPacProperties = config.httpProxy;
                     out.writeUTF(PROXY_SETTINGS_KEY);
                     out.writeUTF(config.proxySettings.toString());
                     out.writeUTF(PROXY_PAC_FILE);
@@ -159,7 +152,7 @@
                 out.writeInt(configKey);
             }
         } catch (NullPointerException e) {
-            loge("Failure in writing " + config.linkProperties + e);
+            loge("Failure in writing " + config + e);
         }
         out.writeUTF(EOS);
 
@@ -196,7 +189,7 @@
                 // Default is DHCP with no proxy
                 IpAssignment ipAssignment = IpAssignment.DHCP;
                 ProxySettings proxySettings = ProxySettings.NONE;
-                LinkProperties linkProperties = new LinkProperties();
+                StaticIpConfiguration staticIpConfiguration = new StaticIpConfiguration();
                 String proxyHost = null;
                 String pacFileUrl = null;
                 int proxyPort = -1;
@@ -213,13 +206,23 @@
                         } else if (key.equals(LINK_ADDRESS_KEY)) {
                             LinkAddress linkAddr = new LinkAddress(
                                     NetworkUtils.numericToInetAddress(in.readUTF()), in.readInt());
-                            linkProperties.addLinkAddress(linkAddr);
+                            if (linkAddr.getAddress() instanceof Inet4Address &&
+                                    staticIpConfiguration.ipAddress == null) {
+                                staticIpConfiguration.ipAddress = linkAddr;
+                            } else {
+                                loge("Non-IPv4 or duplicate address: " + linkAddr);
+                            }
                         } else if (key.equals(GATEWAY_KEY)) {
                             LinkAddress dest = null;
                             InetAddress gateway = null;
                             if (version == 1) {
                                 // only supported default gateways - leave the dest/prefix empty
                                 gateway = NetworkUtils.numericToInetAddress(in.readUTF());
+                                if (staticIpConfiguration.gateway == null) {
+                                    staticIpConfiguration.gateway = gateway;
+                                } else {
+                                    loge("Duplicate gateway: " + gateway.getHostAddress());
+                                }
                             } else {
                                 if (in.readInt() == 1) {
                                     dest = new LinkAddress(
@@ -229,10 +232,16 @@
                                 if (in.readInt() == 1) {
                                     gateway = NetworkUtils.numericToInetAddress(in.readUTF());
                                 }
+                                RouteInfo route = new RouteInfo(dest, gateway);
+                                if (route.isIPv4Default() &&
+                                        staticIpConfiguration.gateway == null) {
+                                    staticIpConfiguration.gateway = gateway;
+                                } else {
+                                    loge("Non-IPv4 default or duplicate route: " + route);
+                                }
                             }
-                            linkProperties.addRoute(new RouteInfo(dest, gateway));
                         } else if (key.equals(DNS_KEY)) {
-                            linkProperties.addDnsServer(
+                            staticIpConfiguration.dnsServers.add(
                                     NetworkUtils.numericToInetAddress(in.readUTF()));
                         } else if (key.equals(PROXY_SETTINGS_KEY)) {
                             proxySettings = ProxySettings.valueOf(in.readUTF());
@@ -258,9 +267,11 @@
                     IpConfiguration config = new IpConfiguration();
                     networks.put(id, config);
 
-                    config.linkProperties = linkProperties;
                     switch (ipAssignment) {
                         case STATIC:
+                            config.staticIpConfiguration = staticIpConfiguration;
+                            config.ipAssignment = ipAssignment;
+                            break;
                         case DHCP:
                             config.ipAssignment = ipAssignment;
                             break;
@@ -276,16 +287,15 @@
 
                     switch (proxySettings) {
                         case STATIC:
-                            config.proxySettings = proxySettings;
-                            ProxyInfo ProxyInfo =
+                            ProxyInfo proxyInfo =
                                     new ProxyInfo(proxyHost, proxyPort, exclusionList);
-                            linkProperties.setHttpProxy(ProxyInfo);
+                            config.proxySettings = proxySettings;
+                            config.httpProxy = proxyInfo;
                             break;
                         case PAC:
+                            ProxyInfo proxyPacProperties = new ProxyInfo(pacFileUrl);
                             config.proxySettings = proxySettings;
-                            ProxyInfo proxyPacProperties =
-                                    new ProxyInfo(pacFileUrl);
-                            linkProperties.setHttpProxy(proxyPacProperties);
+                            config.httpProxy = proxyPacProperties;
                             break;
                         case NONE:
                             config.proxySettings = proxySettings;
diff --git a/services/core/java/com/android/server/net/LockdownVpnTracker.java b/services/core/java/com/android/server/net/LockdownVpnTracker.java
index a2e9d676..04df3e7 100644
--- a/services/core/java/com/android/server/net/LockdownVpnTracker.java
+++ b/services/core/java/com/android/server/net/LockdownVpnTracker.java
@@ -205,7 +205,6 @@
     private void initLocked() {
         Slog.d(TAG, "initLocked()");
 
-        mVpn.setEnableNotifications(false);
         mVpn.setEnableTeardown(false);
 
         final IntentFilter resetFilter = new IntentFilter(ACTION_LOCKDOWN_RESET);
@@ -249,7 +248,6 @@
         hideNotification();
 
         mContext.unregisterReceiver(mResetReceiver);
-        mVpn.setEnableNotifications(true);
         mVpn.setEnableTeardown(true);
     }
 
@@ -304,16 +302,18 @@
     }
 
     private void showNotification(int titleRes, int iconRes) {
-        final Notification.Builder builder = new Notification.Builder(mContext);
-        builder.setWhen(0);
-        builder.setSmallIcon(iconRes);
-        builder.setContentTitle(mContext.getString(titleRes));
-        builder.setContentText(mContext.getString(R.string.vpn_lockdown_config));
-        builder.setContentIntent(mConfigIntent);
-        builder.setPriority(Notification.PRIORITY_LOW);
-        builder.setOngoing(true);
-        builder.addAction(
-                R.drawable.ic_menu_refresh, mContext.getString(R.string.reset), mResetIntent);
+        final Notification.Builder builder = new Notification.Builder(mContext)
+                .setWhen(0)
+                .setSmallIcon(iconRes)
+                .setContentTitle(mContext.getString(titleRes))
+                .setContentText(mContext.getString(R.string.vpn_lockdown_config))
+                .setContentIntent(mConfigIntent)
+                .setPriority(Notification.PRIORITY_LOW)
+                .setOngoing(true)
+                .addAction(R.drawable.ic_menu_refresh, mContext.getString(R.string.reset),
+                        mResetIntent)
+                .setColor(mContext.getResources().getColor(
+                        com.android.internal.R.color.system_notification_accent_color));
 
         NotificationManager.from(mContext).notify(TAG, 0, builder.build());
     }
diff --git a/services/core/java/com/android/server/net/NetworkPolicyManagerService.java b/services/core/java/com/android/server/net/NetworkPolicyManagerService.java
index bb5243c..cf19416 100644
--- a/services/core/java/com/android/server/net/NetworkPolicyManagerService.java
+++ b/services/core/java/com/android/server/net/NetworkPolicyManagerService.java
@@ -433,14 +433,12 @@
 
         // listen for configured wifi networks to be removed
         final IntentFilter wifiConfigFilter = new IntentFilter(CONFIGURED_NETWORKS_CHANGED_ACTION);
-        mContext.registerReceiver(
-                mWifiConfigReceiver, wifiConfigFilter, CONNECTIVITY_INTERNAL, mHandler);
+        mContext.registerReceiver(mWifiConfigReceiver, wifiConfigFilter, null, mHandler);
 
         // listen for wifi state changes to catch metered hint
         final IntentFilter wifiStateFilter = new IntentFilter(
                 WifiManager.NETWORK_STATE_CHANGED_ACTION);
-        mContext.registerReceiver(
-                mWifiStateReceiver, wifiStateFilter, CONNECTIVITY_INTERNAL, mHandler);
+        mContext.registerReceiver(mWifiStateReceiver, wifiStateFilter, null, mHandler);
 
     }
 
@@ -791,6 +789,8 @@
         final Notification.Builder builder = new Notification.Builder(mContext);
         builder.setOnlyAlertOnce(true);
         builder.setWhen(0L);
+        builder.setColor(mContext.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color));
 
         final Resources res = mContext.getResources();
         switch (type) {
@@ -916,6 +916,8 @@
         builder.setTicker(title);
         builder.setContentTitle(title);
         builder.setContentText(body);
+        builder.setColor(mContext.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color));
 
         final Intent intent = buildAllowBackgroundDataIntent();
         builder.setContentIntent(
diff --git a/services/core/java/com/android/server/net/NetworkStatsService.java b/services/core/java/com/android/server/net/NetworkStatsService.java
index f995dee..b5aa4d8 100644
--- a/services/core/java/com/android/server/net/NetworkStatsService.java
+++ b/services/core/java/com/android/server/net/NetworkStatsService.java
@@ -318,7 +318,7 @@
 
         // watch for tethering changes
         final IntentFilter tetherFilter = new IntentFilter(ACTION_TETHER_STATE_CHANGED);
-        mContext.registerReceiver(mTetherReceiver, tetherFilter, CONNECTIVITY_INTERNAL, mHandler);
+        mContext.registerReceiver(mTetherReceiver, tetherFilter, null, mHandler);
 
         // listen for periodic polling events
         final IntentFilter pollFilter = new IntentFilter(ACTION_NETWORK_STATS_POLL);
diff --git a/services/core/java/com/android/server/notification/ConditionProviders.java b/services/core/java/com/android/server/notification/ConditionProviders.java
index 189131c..05ad1fe 100644
--- a/services/core/java/com/android/server/notification/ConditionProviders.java
+++ b/services/core/java/com/android/server/notification/ConditionProviders.java
@@ -545,8 +545,9 @@
                 setZenModeCondition(condition, "downtime");
             }
             // exit downtime
-            if (!inDowntime && mode == Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS
-                    && mDowntime.isDowntimeCondition(mExitCondition)) {
+            if (!inDowntime && mDowntime.isDowntimeCondition(mExitCondition)
+                    && (mode == Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS
+                                || mode == Global.ZEN_MODE_NO_INTERRUPTIONS)) {
                 mZenModeHelper.setZenMode(Global.ZEN_MODE_OFF, "downtimeExit");
             }
         }
diff --git a/services/core/java/com/android/server/notification/DowntimeConditionProvider.java b/services/core/java/com/android/server/notification/DowntimeConditionProvider.java
index 317ebef..b71bad8 100644
--- a/services/core/java/com/android/server/notification/DowntimeConditionProvider.java
+++ b/services/core/java/com/android/server/notification/DowntimeConditionProvider.java
@@ -43,6 +43,7 @@
 import java.util.Date;
 import java.util.Locale;
 import java.util.Objects;
+import java.util.TimeZone;
 
 /** Built-in zen condition provider for managing downtime */
 public class DowntimeConditionProvider extends ConditionProviderService {
@@ -275,6 +276,9 @@
                 final long schTime = intent.getLongExtra(EXTRA_TIME, 0);
                 if (DEBUG) Slog.d(TAG, String.format("%s scheduled for %s, fired at %s, delta=%s",
                         action, ts(schTime), ts(now), now - schTime));
+            } else if (Intent.ACTION_TIMEZONE_CHANGED.equals(action)) {
+                if (DEBUG) Slog.d(TAG, "timezone changed to " + TimeZone.getDefault());
+                mCalendar.setTimeZone(TimeZone.getDefault());
             } else {
                 if (DEBUG) Slog.d(TAG, action + " fired at " + now);
             }
diff --git a/services/core/java/com/android/server/notification/GlobalSortKeyComparator.java b/services/core/java/com/android/server/notification/GlobalSortKeyComparator.java
new file mode 100644
index 0000000..ce976d2
--- /dev/null
+++ b/services/core/java/com/android/server/notification/GlobalSortKeyComparator.java
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2014 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.server.notification;
+
+import java.util.Comparator;
+
+/**
+ * Sorts notifications by their global sort key.
+ */
+public class GlobalSortKeyComparator implements Comparator<NotificationRecord> {
+    @Override
+    public int compare(NotificationRecord left, NotificationRecord right) {
+        if (left.getGlobalSortKey() == null) {
+            throw new IllegalStateException("Missing left global sort key: " + left);
+        }
+        if (right.getGlobalSortKey() == null) {
+            throw new IllegalStateException("Missing right global sort key: " + right);
+        }
+        return left.getGlobalSortKey().compareTo(right.getGlobalSortKey());
+    }
+}
diff --git a/services/core/java/com/android/server/notification/GroupedNotificationComparator.java b/services/core/java/com/android/server/notification/GroupedNotificationComparator.java
deleted file mode 100644
index 608d55c..0000000
--- a/services/core/java/com/android/server/notification/GroupedNotificationComparator.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*
- * Copyright (C) 2014 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.server.notification;
-
-import android.text.TextUtils;
-import android.util.Log;
-
-/**
- * Sorts notifications, accounting for groups and sort keys.
- */
-public class GroupedNotificationComparator extends NotificationComparator {
-    private static final String TAG = "GroupedNotificationComparator";
-
-    @Override
-    public int compare(NotificationRecord left, NotificationRecord right) {
-        // "recently intrusive" is an ad hoc group that temporarily claims noisy notifications
-        if (left.isRecentlyIntrusive() != right.isRecentlyIntrusive()) {
-            return left.isRecentlyIntrusive() ? -1 : 1;
-        }
-
-        final NotificationRecord leftProxy = left.getRankingProxy();
-        if (leftProxy == null) {
-            throw new RuntimeException("left proxy cannot be null: " + left.getKey());
-        }
-        final NotificationRecord rightProxy = right.getRankingProxy();
-        if (rightProxy == null) {
-            throw new RuntimeException("right proxy cannot be null: " + right.getKey());
-        }
-        final String leftSortKey = left.getNotification().getSortKey();
-        final String rightSortKey = right.getNotification().getSortKey();
-        if (leftProxy != rightProxy) {
-            // between groups, compare proxies
-            return Integer.compare(leftProxy.getAuthoritativeRank(),
-                    rightProxy.getAuthoritativeRank());
-        } else if (TextUtils.isEmpty(leftSortKey) || TextUtils.isEmpty(rightSortKey)) {
-            // missing sort keys, use prior rank
-            return Integer.compare(left.getAuthoritativeRank(),
-                    right.getAuthoritativeRank());
-        } else {
-            // use sort keys within group
-            return leftSortKey.compareTo(rightSortKey);
-        }
-    }
-}
diff --git a/services/core/java/com/android/server/notification/ManagedServices.java b/services/core/java/com/android/server/notification/ManagedServices.java
index f647037..13fbf6c 100644
--- a/services/core/java/com/android/server/notification/ManagedServices.java
+++ b/services/core/java/com/android/server/notification/ManagedServices.java
@@ -87,6 +87,10 @@
     // Just the packages from mEnabledServicesForCurrentProfiles
     private ArraySet<String> mEnabledServicesPackageNames = new ArraySet<String>();
 
+    // Kept to de-dupe user change events (experienced after boot, when we receive a settings and a
+    // user change).
+    private int[] mLastSeenProfileIds;
+
     public ManagedServices(Context context, Handler handler, Object mutex,
             UserProfiles userProfiles) {
         mContext = context;
@@ -159,6 +163,15 @@
         }
     }
 
+    public void onUserSwitched() {
+        if (DEBUG) Slog.d(TAG, "onUserSwitched");
+        if (Arrays.equals(mLastSeenProfileIds, mUserProfiles.getCurrentProfileIds())) {
+            if (DEBUG) Slog.d(TAG, "Current profile IDs didn't change, skipping rebindServices().");
+            return;
+        }
+        rebindServices();
+    }
+
     public ManagedServiceInfo checkServiceTokenLocked(IInterface service) {
         checkNotNull(service);
         final IBinder token = service.asBinder();
@@ -321,6 +334,8 @@
                 registerService(component, userIds[i]);
             }
         }
+
+        mLastSeenProfileIds = mUserProfiles.getCurrentProfileIds();
     }
 
     /**
@@ -523,6 +538,8 @@
 
         private void update(Uri uri) {
             if (uri == null || mSecureSettingsUri.equals(uri)) {
+                if (DEBUG) Slog.d(TAG, "Setting changed: mSecureSettingsUri=" + mSecureSettingsUri +
+                        " / uri=" + uri);
                 rebindServices();
             }
         }
diff --git a/services/core/java/com/android/server/notification/NotificationDelegate.java b/services/core/java/com/android/server/notification/NotificationDelegate.java
index 1b59f52..97f0a1e 100644
--- a/services/core/java/com/android/server/notification/NotificationDelegate.java
+++ b/services/core/java/com/android/server/notification/NotificationDelegate.java
@@ -16,8 +16,6 @@
 
 package com.android.server.notification;
 
-import android.os.IBinder;
-
 public interface NotificationDelegate {
     void onSetDisabled(int status);
     void onClearAll(int callingUid, int callingPid, int userId);
@@ -29,7 +27,6 @@
             int uid, int initialPid, String message, int userId);
     void onPanelRevealed();
     void onPanelHidden();
-    boolean allowDisable(int what, IBinder token, String pkg);
     void onNotificationVisibilityChanged(
             String[] newlyVisibleKeys, String[] noLongerVisibleKeys);
     void onNotificationExpansionChanged(String key, boolean userAction, boolean expanded);
diff --git a/services/core/java/com/android/server/notification/NotificationManagerService.java b/services/core/java/com/android/server/notification/NotificationManagerService.java
index f2ac963..14587e6 100644
--- a/services/core/java/com/android/server/notification/NotificationManagerService.java
+++ b/services/core/java/com/android/server/notification/NotificationManagerService.java
@@ -17,6 +17,8 @@
 package com.android.server.notification;
 
 import static android.service.notification.NotificationListenerService.HINT_HOST_DISABLE_EFFECTS;
+import static android.service.notification.NotificationListenerService.TRIM_FULL;
+import static android.service.notification.NotificationListenerService.TRIM_LIGHT;
 import static org.xmlpull.v1.XmlPullParser.END_DOCUMENT;
 import static org.xmlpull.v1.XmlPullParser.END_TAG;
 import static org.xmlpull.v1.XmlPullParser.START_TAG;
@@ -29,7 +31,7 @@
 import android.app.INotificationManager;
 import android.app.ITransientNotification;
 import android.app.Notification;
-import android.app.Notification.Builder;
+import android.app.NotificationManager;
 import android.app.PendingIntent;
 import android.app.StatusBarManager;
 import android.content.BroadcastReceiver;
@@ -47,10 +49,11 @@
 import android.database.ContentObserver;
 import android.media.AudioAttributes;
 import android.media.AudioManager;
+import android.media.AudioSystem;
 import android.media.IRingtonePlayer;
 import android.net.Uri;
 import android.os.Binder;
-import android.os.Build;
+import android.os.Bundle;
 import android.os.Environment;
 import android.os.Handler;
 import android.os.HandlerThread;
@@ -67,6 +70,7 @@
 import android.service.notification.IConditionListener;
 import android.service.notification.IConditionProvider;
 import android.service.notification.INotificationListener;
+import android.service.notification.IStatusBarNotificationHolder;
 import android.service.notification.NotificationListenerService;
 import android.service.notification.NotificationRankingUpdate;
 import android.service.notification.StatusBarNotification;
@@ -111,6 +115,7 @@
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.NoSuchElementException;
+import java.util.Objects;
 
 /** {@hide} */
 public class NotificationManagerService extends SystemService {
@@ -126,6 +131,7 @@
     static final int MESSAGE_RANKING_CONFIG_CHANGE = 5;
     static final int MESSAGE_SEND_RANKING_UPDATE = 6;
     static final int MESSAGE_LISTENER_HINTS_CHANGED = 7;
+    static final int MESSAGE_LISTENER_NOTIFICATION_FILTER_CHANGED = 8;
 
     static final int LONG_DELAY = 3500; // 3.5 seconds
     static final int SHORT_DELAY = 2000; // 2 seconds
@@ -175,7 +181,9 @@
     NotificationRecord mVibrateNotification;
 
     private final ArraySet<ManagedServiceInfo> mListenersDisablingEffects = new ArraySet<>();
+    private ComponentName mEffectsSuppressor;
     private int mListenerHints;  // right now, all hints are global
+    private int mInterruptionFilter;  // current ZEN mode as communicated to listeners
 
     // for enabling and disabling notification pulse behavior
     private boolean mScreenOn = true;
@@ -585,11 +593,6 @@
         }
 
         @Override
-        public boolean allowDisable(int what, IBinder token, String pkg) {
-            return mZenModeHelper.allowDisable(what, token, pkg);
-        }
-
-        @Override
         public void onNotificationVisibilityChanged(
                 String[] newlyVisibleKeys, String[] noLongerVisibleKeys) {
             // Using ';' as separator since eventlogs uses ',' to separate
@@ -715,6 +718,9 @@
                 // reload per-user settings
                 mSettingsObserver.update(null);
                 mUserProfiles.updateCache(context);
+                // Refresh managed services
+                mConditionProviders.onUserSwitched();
+                mListeners.onUserSwitched();
             } else if (action.equals(Intent.ACTION_USER_ADDED)) {
                 mUserProfiles.updateCache(context);
             }
@@ -809,7 +815,7 @@
             @Override
             void onZenModeChanged() {
                 synchronized(mNotificationList) {
-                    updateListenerHintsLocked();
+                    updateInterruptionFilterLocked();
                 }
             }
         });
@@ -941,13 +947,28 @@
     }
 
     private void updateListenerHintsLocked() {
-        final int hints = (mListenersDisablingEffects.isEmpty() ? 0 : HINT_HOST_DISABLE_EFFECTS) |
-                mZenModeHelper.getZenModeListenerHint();
+        final int hints = mListenersDisablingEffects.isEmpty() ? 0 : HINT_HOST_DISABLE_EFFECTS;
         if (hints == mListenerHints) return;
         mListenerHints = hints;
         scheduleListenerHintsChanged(hints);
     }
 
+    private void updateEffectsSuppressorLocked() {
+        final ComponentName suppressor = !mListenersDisablingEffects.isEmpty()
+                ? mListenersDisablingEffects.valueAt(0).component : null;
+        if (Objects.equals(suppressor, mEffectsSuppressor)) return;
+        mEffectsSuppressor = suppressor;
+        getContext().sendBroadcast(new Intent(NotificationManager.ACTION_EFFECTS_SUPPRESSOR_CHANGED)
+                .addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY));
+    }
+
+    private void updateInterruptionFilterLocked() {
+        int interruptionFilter = mZenModeHelper.getZenModeListenerInterruptionFilter();
+        if (interruptionFilter == mInterruptionFilter) return;
+        mInterruptionFilter = interruptionFilter;
+        scheduleInterruptionFilterChanged(interruptionFilter);
+    }
+
     private final IBinder mService = new INotificationManager.Stub() {
         // Toasts
         // ============================================================================
@@ -1110,6 +1131,19 @@
             return mRankingHelper.getPackagePriority(pkg, uid);
         }
 
+        @Override
+        public void setPackageVisibilityOverride(String pkg, int uid, int visibility) {
+            checkCallerIsSystem();
+            mRankingHelper.setPackageVisibilityOverride(pkg, uid, visibility);
+            savePolicyFile();
+        }
+
+        @Override
+        public int getPackageVisibilityOverride(String pkg, int uid) {
+            checkCallerIsSystem();
+            return mRankingHelper.getPackageVisibilityOverride(pkg, uid);
+        }
+
         /**
          * System-only API for getting a list of current (i.e. not cleared) notifications.
          *
@@ -1205,17 +1239,16 @@
                         final int N = keys.length;
                         for (int i = 0; i < N; i++) {
                             NotificationRecord r = mNotificationsByKey.get(keys[i]);
+                            if (r == null) continue;
                             final int userId = r.sbn.getUserId();
                             if (userId != info.userid && userId != UserHandle.USER_ALL &&
                                     !mUserProfiles.isCurrentProfile(userId)) {
                                 throw new SecurityException("Disallowed call from listener: "
                                         + info.service);
                             }
-                            if (r != null) {
-                                cancelNotificationFromListenerLocked(info, callingUid, callingPid,
-                                        r.sbn.getPackageName(), r.sbn.getTag(), r.sbn.getId(),
-                                        userId);
-                            }
+                            cancelNotificationFromListenerLocked(info, callingUid, callingPid,
+                                    r.sbn.getPackageName(), r.sbn.getTag(), r.sbn.getId(),
+                                    userId);
                         }
                     } else {
                         cancelAllLocked(callingUid, callingPid, info.userid,
@@ -1271,22 +1304,29 @@
          * should be used.
          *
          * @param token The binder for the listener, to check that the caller is allowed
+         * @param keys An array of notification keys to fetch, or null to fetch everything
          * @returns The return value will contain the notifications specified in keys, in that
          *      order, or if keys is null, all the notifications, in natural order.
          */
         @Override
         public ParceledListSlice<StatusBarNotification> getActiveNotificationsFromListener(
-                INotificationListener token) {
+                INotificationListener token, String[] keys, int trim) {
             synchronized (mNotificationList) {
                 final ManagedServiceInfo info = mListeners.checkServiceTokenLocked(token);
+                final boolean getKeys = keys != null;
+                final int N = getKeys ? keys.length : mNotificationList.size();
                 final ArrayList<StatusBarNotification> list
-                        = new ArrayList<StatusBarNotification>();
-                final int N = mNotificationList.size();
+                        = new ArrayList<StatusBarNotification>(N);
                 for (int i=0; i<N; i++) {
-                    StatusBarNotification sbn = mNotificationList.get(i).sbn;
-                    if (isVisibleToListener(sbn, info)) {
-                        list.add(sbn);
-                    }
+                    final NotificationRecord r = getKeys
+                            ? mNotificationsByKey.get(keys[i])
+                            : mNotificationList.get(i);
+                    if (r == null) continue;
+                    StatusBarNotification sbn = r.sbn;
+                    if (!isVisibleToListener(sbn, info)) continue;
+                    StatusBarNotification sbnToSend =
+                            (trim == TRIM_FULL) ? sbn : sbn.cloneLight();
+                    list.add(sbnToSend);
                 }
                 return new ParceledListSlice<StatusBarNotification>(list);
             }
@@ -1304,8 +1344,8 @@
                     } else {
                         mListenersDisablingEffects.remove(info);
                     }
-                    mZenModeHelper.requestFromListener(hints);
                     updateListenerHintsLocked();
+                    updateEffectsSuppressorLocked();
                 }
             } finally {
                 Binder.restoreCallingIdentity(identity);
@@ -1320,6 +1360,39 @@
         }
 
         @Override
+        public void requestInterruptionFilterFromListener(INotificationListener token,
+                int interruptionFilter) throws RemoteException {
+            final long identity = Binder.clearCallingIdentity();
+            try {
+                synchronized (mNotificationList) {
+                    mListeners.checkServiceTokenLocked(token);
+                    mZenModeHelper.requestFromListener(interruptionFilter);
+                    updateInterruptionFilterLocked();
+                }
+            } finally {
+                Binder.restoreCallingIdentity(identity);
+            }
+        }
+
+        @Override
+        public int getInterruptionFilterFromListener(INotificationListener token)
+                throws RemoteException {
+            synchronized (mNotificationLight) {
+                return mInterruptionFilter;
+            }
+        }
+
+        @Override
+        public void setOnNotificationPostedTrimFromListener(INotificationListener token, int trim)
+                throws RemoteException {
+            synchronized (mNotificationList) {
+                final ManagedServiceInfo info = mListeners.checkServiceTokenLocked(token);
+                if (info == null) return;
+                mListeners.setOnNotificationPostedTrimLocked(info, trim);
+            }
+        }
+
+        @Override
         public ZenModeConfig getZenModeConfig() {
             enforceSystemOrSystemUI("INotificationManager.getZenModeConfig");
             return mZenModeHelper.getConfig();
@@ -1383,7 +1456,7 @@
         protected void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
             if (getContext().checkCallingOrSelfPermission(android.Manifest.permission.DUMP)
                     != PackageManager.PERMISSION_GRANTED) {
-                pw.println("Permission Denial: can't dump NotificationManager from from pid="
+                pw.println("Permission Denial: can't dump NotificationManager from pid="
                         + Binder.getCallingPid()
                         + ", uid=" + Binder.getCallingUid());
                 return;
@@ -1391,6 +1464,19 @@
 
             dumpImpl(pw, DumpFilter.parseFromArguments(args));
         }
+
+        @Override
+        public ComponentName getEffectsSuppressor() {
+            enforceSystemOrSystemUI("INotificationManager.getEffectsSuppressor");
+            return mEffectsSuppressor;
+        }
+
+        @Override
+        public boolean matchesCallFilter(Bundle extras) {
+            enforceSystemOrSystemUI("INotificationManager.matchesCallFilter");
+            return mZenModeHelper.matchesCallFilter(UserHandle.getCallingUserHandle(), extras,
+                    mRankingHelper.findExtractor(ValidateNotificationPeople.class));
+        }
     };
 
     private String[] getActiveNotificationKeys(INotificationListener token) {
@@ -1535,14 +1621,15 @@
         }
         checkCallerIsSystemOrSameApp(pkg);
         final boolean isSystemNotification = isUidSystem(callingUid) || ("android".equals(pkg));
+        final boolean isNotificationFromListener = mListeners.isListenerPackage(pkg);
 
         final int userId = ActivityManager.handleIncomingUser(callingPid,
                 callingUid, incomingUserId, true, false, "enqueueNotification", pkg);
         final UserHandle user = new UserHandle(userId);
 
         // Limit the number of notifications that any given package except the android
-        // package can enqueue.  Prevents DOS attacks and deals with leaks.
-        if (!isSystemNotification) {
+        // package or a registered listener can enqueue.  Prevents DOS attacks and deals with leaks.
+        if (!isSystemNotification && !isNotificationFromListener) {
             synchronized (mNotificationList) {
                 int count = 0;
                 final int N = mNotificationList.size();
@@ -1583,55 +1670,66 @@
             @Override
             public void run() {
 
-                // === Scoring ===
-
-                // 0. Sanitize inputs
-                notification.priority = clamp(notification.priority, Notification.PRIORITY_MIN,
-                        Notification.PRIORITY_MAX);
-                // Migrate notification flags to scores
-                if (0 != (notification.flags & Notification.FLAG_HIGH_PRIORITY)) {
-                    if (notification.priority < Notification.PRIORITY_MAX) {
-                        notification.priority = Notification.PRIORITY_MAX;
-                    }
-                } else if (SCORE_ONGOING_HIGHER &&
-                        0 != (notification.flags & Notification.FLAG_ONGOING_EVENT)) {
-                    if (notification.priority < Notification.PRIORITY_HIGH) {
-                        notification.priority = Notification.PRIORITY_HIGH;
-                    }
-                }
-
-                // 1. initial score: buckets of 10, around the app [-20..20]
-                final int score = notification.priority * NOTIFICATION_PRIORITY_MULTIPLIER;
-
-                // 2. extract ranking signals from the notification data
-                final StatusBarNotification n = new StatusBarNotification(
-                        pkg, opPkg, id, tag, callingUid, callingPid, score, notification,
-                        user);
-                NotificationRecord r = new NotificationRecord(n, score);
-                NotificationRecord old = mNotificationsByKey.get(n.getKey());
-                if (old != null) {
-                    // Retain ranking information from previous record
-                    r.copyRankingInformation(old);
-                }
-                mRankingHelper.extractSignals(r);
-
-                // 3. Apply local rules
-
-                // blocked apps
-                if (ENABLE_BLOCKED_NOTIFICATIONS && !noteNotificationOp(pkg, callingUid)) {
-                    if (!isSystemNotification) {
-                        r.score = JUNK_SCORE;
-                        Slog.e(TAG, "Suppressing notification from package " + pkg
-                                + " by user request.");
-                    }
-                }
-
-                if (r.score < SCORE_DISPLAY_THRESHOLD) {
-                    // Notification will be blocked because the score is too low.
-                    return;
-                }
-
                 synchronized (mNotificationList) {
+
+                    // === Scoring ===
+
+                    // 0. Sanitize inputs
+                    notification.priority = clamp(notification.priority, Notification.PRIORITY_MIN,
+                            Notification.PRIORITY_MAX);
+                    // Migrate notification flags to scores
+                    if (0 != (notification.flags & Notification.FLAG_HIGH_PRIORITY)) {
+                        if (notification.priority < Notification.PRIORITY_MAX) {
+                            notification.priority = Notification.PRIORITY_MAX;
+                        }
+                    } else if (SCORE_ONGOING_HIGHER &&
+                            0 != (notification.flags & Notification.FLAG_ONGOING_EVENT)) {
+                        if (notification.priority < Notification.PRIORITY_HIGH) {
+                            notification.priority = Notification.PRIORITY_HIGH;
+                        }
+                    }
+
+                    // 1. initial score: buckets of 10, around the app [-20..20]
+                    final int score = notification.priority * NOTIFICATION_PRIORITY_MULTIPLIER;
+
+                    // 2. extract ranking signals from the notification data
+                    final StatusBarNotification n = new StatusBarNotification(
+                            pkg, opPkg, id, tag, callingUid, callingPid, score, notification,
+                            user);
+                    NotificationRecord r = new NotificationRecord(n, score);
+                    NotificationRecord old = mNotificationsByKey.get(n.getKey());
+                    if (old != null) {
+                        // Retain ranking information from previous record
+                        r.copyRankingInformation(old);
+                    }
+                    mRankingHelper.extractSignals(r);
+
+                    // 3. Apply local rules
+
+                    // blocked apps
+                    if (ENABLE_BLOCKED_NOTIFICATIONS && !noteNotificationOp(pkg, callingUid)) {
+                        if (!isSystemNotification) {
+                            r.score = JUNK_SCORE;
+                            Slog.e(TAG, "Suppressing notification from package " + pkg
+                                    + " by user request.");
+                        }
+                    }
+
+                    if (r.score < SCORE_DISPLAY_THRESHOLD) {
+                        // Notification will be blocked because the score is too low.
+                        return;
+                    }
+
+                    // Clear out group children of the old notification if the update causes the
+                    // group summary to go away. This happens when the old notification was a
+                    // summary and the new one isn't, or when the old notification was a summary
+                    // and its group key changed.
+                    if (old != null && old.getNotification().isGroupSummary() &&
+                            (!notification.isGroupSummary() ||
+                                    !old.getGroupKey().equals(r.getGroupKey()))) {
+                        cancelGroupChildrenLocked(old, callingUid, callingPid, null);
+                    }
+
                     int index = indexOfNotificationLocked(n.getKey());
                     if (index < 0) {
                         mNotificationList.add(r);
@@ -1656,24 +1754,7 @@
                     }
 
                     applyZenModeLocked(r);
-
-                    try {
-                        mRankingHelper.sort(mNotificationList);
-                    } catch (RuntimeException ex) {
-                        // Don't crash the system server if something bad happened.
-                        Log.e(TAG, "Extreme badness during notification sort", ex);
-                        Log.e(TAG, "Current notification list: ");
-                        for (int ii=0; ii < mNotificationList.size(); ii++) {
-                            NotificationRecord nr = mNotificationList.get(ii);
-                            Log.e(TAG, String.format(
-                                    "  [%d] %s (group %s, rank %d, sortkey %s, proxy %s)",
-                                    ii, nr, nr.getGroupKey(), nr.getAuthoritativeRank(),
-                                    nr.getNotification().getSortKey(),
-                                    nr.getRankingProxy()));
-                        }
-                        // STOPSHIP: remove once b/16626175 is found
-                        throw ex;
-                    }
+                    mRankingHelper.sort(mNotificationList);
 
                     if (notification.icon != 0) {
                         StatusBarNotification oldSbn = (old != null) ? old.sbn : null;
@@ -1860,14 +1941,19 @@
     }
 
     private static AudioAttributes audioAttributesForNotification(Notification n) {
-        if (n.audioAttributes != null
-                && !Notification.AUDIO_ATTRIBUTES_DEFAULT.equals(n.audioAttributes)) {
+        if (n.audioAttributes != null) {
             return n.audioAttributes;
+        } else if (n.audioStreamType >= 0 && n.audioStreamType < AudioSystem.getNumStreamTypes()) {
+            // the stream type is valid, use it
+            return new AudioAttributes.Builder()
+                    .setInternalLegacyStreamType(n.audioStreamType)
+                    .build();
+        } else if (n.audioStreamType == AudioSystem.STREAM_DEFAULT) {
+            return Notification.AUDIO_ATTRIBUTES_DEFAULT;
+        } else {
+            Log.w(TAG, String.format("Invalid stream type: %d", n.audioStreamType));
+            return Notification.AUDIO_ATTRIBUTES_DEFAULT;
         }
-        return new AudioAttributes.Builder()
-                .setLegacyStreamType(n.audioStreamType)
-                .setUsage(AudioAttributes.usageForLegacyStreamType(n.audioStreamType))
-                .build();
     }
 
     void showNextToastLocked() {
@@ -1981,12 +2067,15 @@
             }
             int indexBefore = findNotificationRecordIndexLocked(record);
             boolean interceptBefore = record.isIntercepted();
+            int visibilityBefore = record.getPackageVisibilityOverride();
             recon.applyChangesLocked(record);
             applyZenModeLocked(record);
             mRankingHelper.sort(mNotificationList);
             int indexAfter = findNotificationRecordIndexLocked(record);
             boolean interceptAfter = record.isIntercepted();
-            changed = indexBefore != indexAfter || interceptBefore != interceptAfter;
+            int visibilityAfter = record.getPackageVisibilityOverride();
+            changed = indexBefore != indexAfter || interceptBefore != interceptAfter
+                    || visibilityBefore != visibilityAfter;
             if (interceptBefore && !interceptAfter) {
                 buzzBeepBlinkLocked(record);
             }
@@ -2000,14 +2089,18 @@
         synchronized (mNotificationList) {
             final int N = mNotificationList.size();
             ArrayList<String> orderBefore = new ArrayList<String>(N);
+            int[] visibilities = new int[N];
             for (int i = 0; i < N; i++) {
                 final NotificationRecord r = mNotificationList.get(i);
                 orderBefore.add(r.getKey());
+                visibilities[i] = r.getPackageVisibilityOverride();
                 mRankingHelper.extractSignals(r);
             }
-            mRankingHelper.sort(mNotificationList);
             for (int i = 0; i < N; i++) {
-                if (!orderBefore.get(i).equals(mNotificationList.get(i).getKey())) {
+                mRankingHelper.sort(mNotificationList);
+                final NotificationRecord r = mNotificationList.get(i);
+                if (!orderBefore.get(i).equals(r.getKey())
+                        || visibilities[i] != r.getPackageVisibilityOverride()) {
                     scheduleSendRankingUpdate();
                     return;
                 }
@@ -2042,12 +2135,26 @@
         mHandler.obtainMessage(MESSAGE_LISTENER_HINTS_CHANGED, state, 0).sendToTarget();
     }
 
+    private void scheduleInterruptionFilterChanged(int listenerInterruptionFilter) {
+        mHandler.removeMessages(MESSAGE_LISTENER_NOTIFICATION_FILTER_CHANGED);
+        mHandler.obtainMessage(
+                MESSAGE_LISTENER_NOTIFICATION_FILTER_CHANGED,
+                listenerInterruptionFilter,
+                0).sendToTarget();
+    }
+
     private void handleListenerHintsChanged(int hints) {
         synchronized (mNotificationList) {
             mListeners.notifyListenerHintsChangedLocked(hints);
         }
     }
 
+    private void handleListenerInterruptionFilterChanged(int interruptionFilter) {
+        synchronized (mNotificationList) {
+            mListeners.notifyInterruptionFilterChanged(interruptionFilter);
+        }
+    }
+
     private final class WorkerHandler extends Handler
     {
         @Override
@@ -2067,6 +2174,9 @@
                 case MESSAGE_LISTENER_HINTS_CHANGED:
                     handleListenerHintsChanged(msg.arg1);
                     break;
+                case MESSAGE_LISTENER_NOTIFICATION_FILTER_CHANGED:
+                    handleListenerInterruptionFilterChanged(msg.arg1);
+                    break;
             }
         }
 
@@ -2382,10 +2492,9 @@
         final int N = mNotificationList.size();
         for (int i = N - 1; i >= 0; i--) {
             NotificationRecord childR = mNotificationList.get(i);
-            Notification childN = childR.getNotification();
             StatusBarNotification childSbn = childR.sbn;
-            if (childR.getUserId() == userId && pkg.equals(childSbn.getPackageName()) &&
-                    n.getGroup().equals(childN.getGroup())) {
+            if (childR.getNotification().isGroupChild() &&
+                    childR.getGroupKey().equals(r.getGroupKey())) {
                 EventLogTags.writeNotificationCancel(callingUid, callingPid,
                         pkg, childSbn.getId(), childSbn.getTag(), userId, 0, 0,
                         REASON_GROUP_SUMMARY_CANCELED, listenerName);
@@ -2521,6 +2630,7 @@
         final int N = mNotificationList.size();
         ArrayList<String> keys = new ArrayList<String>(N);
         ArrayList<String> interceptedKeys = new ArrayList<String>(N);
+        Bundle visibilityOverrides = new Bundle();
         for (int i = 0; i < N; i++) {
             NotificationRecord record = mNotificationList.get(i);
             if (!isVisibleToListener(record.sbn, info)) {
@@ -2530,14 +2640,28 @@
             if (record.isIntercepted()) {
                 interceptedKeys.add(record.sbn.getKey());
             }
+            if (record.getPackageVisibilityOverride()
+                    != NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE) {
+                visibilityOverrides.putInt(record.sbn.getKey(),
+                        record.getPackageVisibilityOverride());
+            }
+            // Find first min-prio notification for speedbump placement.
             if (speedBumpIndex == -1 &&
+                    // Intrusiveness trumps priority, hence ignore intrusives.
+                    !record.isRecentlyIntrusive() &&
+                    // Currently, package priority is either PRIORITY_DEFAULT or PRIORITY_MAX, so
+                    // scanning for PRIORITY_MIN within the package bucket PRIORITY_DEFAULT
+                    // (or lower as a safeguard) is sufficient to find the speedbump index.
+                    // We'll have to revisit this when more package priority buckets are introduced.
+                    record.getPackagePriority() <= Notification.PRIORITY_DEFAULT &&
                     record.sbn.getNotification().priority == Notification.PRIORITY_MIN) {
                 speedBumpIndex = keys.size() - 1;
             }
         }
         String[] keysAr = keys.toArray(new String[keys.size()]);
         String[] interceptedKeysAr = interceptedKeys.toArray(new String[interceptedKeys.size()]);
-        return new NotificationRankingUpdate(keysAr, interceptedKeysAr, speedBumpIndex);
+        return new NotificationRankingUpdate(keysAr, interceptedKeysAr, visibilityOverrides,
+                speedBumpIndex);
     }
 
     private boolean isVisibleToListener(StatusBarNotification sbn, ManagedServiceInfo listener) {
@@ -2550,6 +2674,8 @@
 
     public class NotificationListeners extends ManagedServices {
 
+        private final ArraySet<ManagedServiceInfo> mLightTrimListeners = new ArraySet<>();
+
         public NotificationListeners() {
             super(getContext(), mHandler, mNotificationList, mUserProfiles);
         }
@@ -2590,6 +2716,20 @@
             if (mListenersDisablingEffects.remove(removed)) {
                 updateListenerHintsLocked();
             }
+            mLightTrimListeners.remove(removed);
+        }
+
+        public void setOnNotificationPostedTrimLocked(ManagedServiceInfo info, int trim) {
+            if (trim == TRIM_LIGHT) {
+                mLightTrimListeners.add(info);
+            } else {
+                mLightTrimListeners.remove(info);
+            }
+        }
+
+        public int getOnNotificationPostedTrim(ManagedServiceInfo info) {
+            return mLightTrimListeners.contains(info) ? TRIM_LIGHT : TRIM_FULL;
+
         }
 
         /**
@@ -2600,8 +2740,10 @@
          * but isn't anymore.
          */
         public void notifyPostedLocked(StatusBarNotification sbn, StatusBarNotification oldSbn) {
-            // make a copy in case changes are made to the underlying Notification object
-            final StatusBarNotification sbnClone = sbn.clone();
+            // Lazily initialized snapshots of the notification.
+            StatusBarNotification sbnClone = null;
+            StatusBarNotification sbnCloneLight = null;
+
             for (final ManagedServiceInfo info : mServices) {
                 boolean sbnVisible = isVisibleToListener(sbn, info);
                 boolean oldSbnVisible = oldSbn != null ? isVisibleToListener(oldSbn, info) : false;
@@ -2623,10 +2765,20 @@
                     continue;
                 }
 
+                final int trim = mListeners.getOnNotificationPostedTrim(info);
+
+                if (trim == TRIM_LIGHT && sbnCloneLight == null) {
+                    sbnCloneLight = sbn.cloneLight();
+                } else if (trim == TRIM_FULL && sbnClone == null) {
+                    sbnClone = sbn.clone();
+                }
+                final StatusBarNotification sbnToPost =
+                        (trim == TRIM_FULL) ? sbnClone : sbnCloneLight;
+
                 mHandler.post(new Runnable() {
                     @Override
                     public void run() {
-                        notifyPosted(info, sbnClone, update);
+                        notifyPosted(info, sbnToPost, update);
                     }
                 });
             }
@@ -2686,11 +2838,26 @@
             }
         }
 
+        public void notifyInterruptionFilterChanged(final int interruptionFilter) {
+            for (final ManagedServiceInfo serviceInfo : mServices) {
+                if (!serviceInfo.isEnabledForCurrentProfiles()) {
+                    continue;
+                }
+                mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        notifyInterruptionFilterChanged(serviceInfo, interruptionFilter);
+                    }
+                });
+            }
+        }
+
         private void notifyPosted(final ManagedServiceInfo info,
                 final StatusBarNotification sbn, NotificationRankingUpdate rankingUpdate) {
             final INotificationListener listener = (INotificationListener)info.service;
+            StatusBarNotificationHolder sbnHolder = new StatusBarNotificationHolder(sbn);
             try {
-                listener.onNotificationPosted(sbn, rankingUpdate);
+                listener.onNotificationPosted(sbnHolder, rankingUpdate);
             } catch (RemoteException ex) {
                 Log.e(TAG, "unable to notify listener (posted): " + listener, ex);
             }
@@ -2702,8 +2869,9 @@
                 return;
             }
             final INotificationListener listener = (INotificationListener) info.service;
+            StatusBarNotificationHolder sbnHolder = new StatusBarNotificationHolder(sbn);
             try {
-                listener.onNotificationRemoved(sbn, rankingUpdate);
+                listener.onNotificationRemoved(sbnHolder, rankingUpdate);
             } catch (RemoteException ex) {
                 Log.e(TAG, "unable to notify listener (removed): " + listener, ex);
             }
@@ -2727,6 +2895,31 @@
                 Log.e(TAG, "unable to notify listener (listener hints): " + listener, ex);
             }
         }
+
+        private void notifyInterruptionFilterChanged(ManagedServiceInfo info,
+                int interruptionFilter) {
+            final INotificationListener listener = (INotificationListener) info.service;
+            try {
+                listener.onInterruptionFilterChanged(interruptionFilter);
+            } catch (RemoteException ex) {
+                Log.e(TAG, "unable to notify listener (interruption filter): " + listener, ex);
+            }
+        }
+
+        private boolean isListenerPackage(String packageName) {
+            if (packageName == null) {
+                return false;
+            }
+            // TODO: clean up locking object later
+            synchronized (mNotificationList) {
+                for (final ManagedServiceInfo serviceInfo : mServices) {
+                    if (packageName.equals(serviceInfo.component.getPackageName())) {
+                        return true;
+                    }
+                }
+            }
+            return false;
+        }
     }
 
     public static final class DumpFilter {
@@ -2766,4 +2959,25 @@
             return zen ? "zen" : ('\'' + pkgFilter + '\'');
         }
     }
+
+    /**
+     * Wrapper for a StatusBarNotification object that allows transfer across a oneway
+     * binder without sending large amounts of data over a oneway transaction.
+     */
+    private static final class StatusBarNotificationHolder
+            extends IStatusBarNotificationHolder.Stub {
+        private StatusBarNotification mValue;
+
+        public StatusBarNotificationHolder(StatusBarNotification value) {
+            mValue = value;
+        }
+
+        /** Get the held value and clear it. This function should only be called once per holder */
+        @Override
+        public StatusBarNotification get() {
+            StatusBarNotification value = mValue;
+            mValue = null;
+            return value;
+        }
+    }
 }
diff --git a/services/core/java/com/android/server/notification/NotificationRecord.java b/services/core/java/com/android/server/notification/NotificationRecord.java
index 0186b8c..fd34aa5 100644
--- a/services/core/java/com/android/server/notification/NotificationRecord.java
+++ b/services/core/java/com/android/server/notification/NotificationRecord.java
@@ -21,6 +21,7 @@
 import android.content.res.Resources;
 import android.graphics.Bitmap;
 import android.media.AudioAttributes;
+import android.os.UserHandle;
 import android.service.notification.StatusBarNotification;
 
 import com.android.internal.annotations.VisibleForTesting;
@@ -63,9 +64,9 @@
     public boolean isUpdate;
     private int mPackagePriority;
 
-    // The record that ranking should use for comparisons outside the group.
-    private NotificationRecord mRankingProxy;
     private int mAuthoritativeRank;
+    private String mGlobalSortKey;
+    private int mPackageVisibility;
 
     @VisibleForTesting
     public NotificationRecord(StatusBarNotification sbn, int score)
@@ -80,16 +81,18 @@
         mContactAffinity = previous.mContactAffinity;
         mRecentlyIntrusive = previous.mRecentlyIntrusive;
         mPackagePriority = previous.mPackagePriority;
+        mPackageVisibility = previous.mPackageVisibility;
         mIntercept = previous.mIntercept;
-        mRankingProxy = previous.mRankingProxy;
         mRankingTimeMs = calculateRankingTimeMs(previous.getRankingTimeMs());
-        // Don't copy mGroupKey, recompute it, in case it has changed
+        // Don't copy mGlobalSortKey, recompute it.
     }
 
     public Notification getNotification() { return sbn.getNotification(); }
     public int getFlags() { return sbn.getNotification().flags; }
-    public int getUserId() { return sbn.getUserId(); }
+    public UserHandle getUser() { return sbn.getUser(); }
     public String getKey() { return sbn.getKey(); }
+    /** @deprecated Use {@link #getUser()} instead. */
+    public int getUserId() { return sbn.getUserId(); }
 
     void dump(PrintWriter pw, String prefix, Context baseContext) {
         final Notification notification = sbn.getNotification();
@@ -157,8 +160,9 @@
         pw.println(prefix + "  mContactAffinity=" + mContactAffinity);
         pw.println(prefix + "  mRecentlyIntrusive=" + mRecentlyIntrusive);
         pw.println(prefix + "  mPackagePriority=" + mPackagePriority);
+        pw.println(prefix + "  mPackageVisibility=" + mPackageVisibility);
         pw.println(prefix + "  mIntercept=" + mIntercept);
-        pw.println(prefix + "  mRankingProxy=" + getRankingProxy().getKey());
+        pw.println(prefix + "  mGlobalSortKey=" + mGlobalSortKey);
         pw.println(prefix + "  mRankingTimeMs=" + mRankingTimeMs);
     }
 
@@ -218,6 +222,14 @@
         return mPackagePriority;
     }
 
+    public void setPackageVisibilityOverride(int packageVisibility) {
+        mPackageVisibility = packageVisibility;
+    }
+
+    public int getPackageVisibilityOverride() {
+        return mPackageVisibility;
+    }
+
     public boolean setIntercepted(boolean intercept) {
         mIntercept = intercept;
         return mIntercept;
@@ -265,12 +277,12 @@
         return sbn.getPostTime();
     }
 
-    public NotificationRecord getRankingProxy() {
-        return mRankingProxy;
+    public void setGlobalSortKey(String globalSortKey) {
+        mGlobalSortKey = globalSortKey;
     }
 
-    public void setRankingProxy(NotificationRecord proxy) {
-        mRankingProxy = proxy;
+    public String getGlobalSortKey() {
+        return mGlobalSortKey;
     }
 
     public void setAuthoritativeRank(int authoritativeRank) {
diff --git a/services/core/java/com/android/server/notification/NotificationUsageStats.java b/services/core/java/com/android/server/notification/NotificationUsageStats.java
index 4a7a971..8278c4f 100644
--- a/services/core/java/com/android/server/notification/NotificationUsageStats.java
+++ b/services/core/java/com/android/server/notification/NotificationUsageStats.java
@@ -46,7 +46,12 @@
  * {@hide}
  */
 public class NotificationUsageStats {
-    private static final boolean ENABLE_SQLITE_LOG = true;
+    // WARNING: Aggregated stats can grow unboundedly with pkg+id+tag.
+    // Don't enable on production builds.
+    private static final boolean ENABLE_AGGREGATED_IN_MEMORY_STATS = false;
+    private static final boolean ENABLE_SQLITE_LOG = false;
+
+    private static final AggregatedStats[] EMPTY_AGGREGATED_STATS = new AggregatedStats[0];
 
     // Guarded by synchronized(this).
     private final Map<String, AggregatedStats> mStats = new HashMap<String, AggregatedStats>();
@@ -147,6 +152,10 @@
 
     // Locked by this.
     private AggregatedStats[] getAggregatedStatsLocked(NotificationRecord record) {
+        if (!ENABLE_AGGREGATED_IN_MEMORY_STATS) {
+            return EMPTY_AGGREGATED_STATS;
+        }
+
         StatusBarNotification n = record.sbn;
 
         String user = String.valueOf(n.getUserId());
@@ -171,9 +180,12 @@
     }
 
     public synchronized void dump(PrintWriter pw, String indent, DumpFilter filter) {
-        for (AggregatedStats as : mStats.values()) {
-            if (filter != null && !filter.matches(as.key)) continue;
-            as.dump(pw, indent);
+        if (ENABLE_AGGREGATED_IN_MEMORY_STATS) {
+            for (AggregatedStats as : mStats.values()) {
+                if (filter != null && !filter.matches(as.key))
+                    continue;
+                as.dump(pw, indent);
+            }
         }
         if (ENABLE_SQLITE_LOG) {
             mSQLiteLog.dump(pw, indent, filter);
diff --git a/services/core/java/com/android/server/notification/PackageVisibilityExtractor.java b/services/core/java/com/android/server/notification/PackageVisibilityExtractor.java
new file mode 100644
index 0000000..f720f9f
--- /dev/null
+++ b/services/core/java/com/android/server/notification/PackageVisibilityExtractor.java
@@ -0,0 +1,53 @@
+/*
+* Copyright (C) 2014 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.server.notification;
+
+import android.content.Context;
+import android.util.Slog;
+
+public class PackageVisibilityExtractor implements NotificationSignalExtractor {
+    private static final String TAG = "PackageVisibilityExtractor";
+    private static final boolean DBG = false;
+
+    private RankingConfig mConfig;
+
+    public void initialize(Context ctx) {
+        if (DBG) Slog.d(TAG, "Initializing  " + getClass().getSimpleName() + ".");
+    }
+
+    public RankingReconsideration process(NotificationRecord record) {
+        if (record == null || record.getNotification() == null) {
+            if (DBG) Slog.d(TAG, "skipping empty notification");
+            return null;
+        }
+
+        if (mConfig == null) {
+            if (DBG) Slog.d(TAG, "missing config");
+            return null;
+        }
+
+        final int packageVisibility = mConfig.getPackageVisibilityOverride(
+                record.sbn.getPackageName(), record.sbn.getUid());
+        record.setPackageVisibilityOverride(packageVisibility);
+
+        return null;
+    }
+
+    @Override
+    public void setConfig(RankingConfig config) {
+        mConfig = config;
+    }
+}
diff --git a/services/core/java/com/android/server/notification/RankingConfig.java b/services/core/java/com/android/server/notification/RankingConfig.java
index 7d0bd59..aea137b 100644
--- a/services/core/java/com/android/server/notification/RankingConfig.java
+++ b/services/core/java/com/android/server/notification/RankingConfig.java
@@ -19,4 +19,8 @@
     int getPackagePriority(String packageName, int uid);
 
     void setPackagePriority(String packageName, int uid, int priority);
+
+    int getPackageVisibilityOverride(String packageName, int uid);
+
+    void setPackageVisibilityOverride(String packageName, int uid, int visibility);
 }
diff --git a/services/core/java/com/android/server/notification/RankingHelper.java b/services/core/java/com/android/server/notification/RankingHelper.java
index d59e17b..aeddecb 100644
--- a/services/core/java/com/android/server/notification/RankingHelper.java
+++ b/services/core/java/com/android/server/notification/RankingHelper.java
@@ -17,12 +17,14 @@
 
 import android.app.Notification;
 import android.content.Context;
-import android.net.Uri;
 import android.os.Handler;
 import android.os.Message;
 import android.os.UserHandle;
+import android.service.notification.NotificationListenerService;
 import android.text.TextUtils;
 import android.util.ArrayMap;
+import android.util.ArraySet;
+import android.util.Log;
 import android.util.Slog;
 import android.util.SparseIntArray;
 import org.xmlpull.v1.XmlPullParser;
@@ -33,6 +35,7 @@
 import java.io.PrintWriter;
 import java.util.ArrayList;
 import java.util.Collections;
+import java.util.Set;
 import java.util.concurrent.TimeUnit;
 
 public class RankingHelper implements RankingConfig {
@@ -48,13 +51,15 @@
     private static final String ATT_NAME = "name";
     private static final String ATT_UID = "uid";
     private static final String ATT_PRIORITY = "priority";
+    private static final String ATT_VISIBILITY = "visibility";
 
     private final NotificationSignalExtractor[] mSignalExtractors;
     private final NotificationComparator mPreliminaryComparator = new NotificationComparator();
-    private final NotificationComparator mFinalComparator = new GroupedNotificationComparator();
+    private final GlobalSortKeyComparator mFinalComparator = new GlobalSortKeyComparator();
 
     // Package name to uid, to priority. Would be better as Table<String, Int, Int>
     private final ArrayMap<String, SparseIntArray> mPackagePriorities;
+    private final ArrayMap<String, SparseIntArray> mPackageVisibilities;
     private final ArrayMap<String, NotificationRecord> mProxyByGroupTmp;
 
     private final Context mContext;
@@ -64,6 +69,7 @@
         mContext = context;
         mRankingHandler = rankingHandler;
         mPackagePriorities = new ArrayMap<String, SparseIntArray>();
+        mPackageVisibilities = new ArrayMap<String, SparseIntArray>();
 
         final int N = extractorNames.length;
         mSignalExtractors = new NotificationSignalExtractor[N];
@@ -86,6 +92,17 @@
         mProxyByGroupTmp = new ArrayMap<String, NotificationRecord>();
     }
 
+    public <T extends NotificationSignalExtractor> T findExtractor(Class<T> extractorClass) {
+        final int N = mSignalExtractors.length;
+        for (int i = 0; i < N; i++) {
+            final NotificationSignalExtractor extractor = mSignalExtractors[i];
+            if (extractorClass.equals(extractor.getClass())) {
+                return (T) extractor;
+            }
+        }
+        return null;
+    }
+
     public void extractSignals(NotificationRecord r) {
         final int N = mSignalExtractors.length;
         for (int i = 0; i < N; i++) {
@@ -120,15 +137,27 @@
                 if (TAG_PACKAGE.equals(tag)) {
                     int uid = safeInt(parser, ATT_UID, UserHandle.USER_ALL);
                     int priority = safeInt(parser, ATT_PRIORITY, Notification.PRIORITY_DEFAULT);
+                    int vis = safeInt(parser, ATT_VISIBILITY,
+                            NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE);
                     String name = parser.getAttributeValue(null, ATT_NAME);
 
-                    if (!TextUtils.isEmpty(name) && priority != Notification.PRIORITY_DEFAULT) {
-                        SparseIntArray priorityByUid = mPackagePriorities.get(name);
-                        if (priorityByUid == null) {
-                            priorityByUid = new SparseIntArray();
-                            mPackagePriorities.put(name, priorityByUid);
+                    if (!TextUtils.isEmpty(name)) {
+                        if (priority != Notification.PRIORITY_DEFAULT) {
+                            SparseIntArray priorityByUid = mPackagePriorities.get(name);
+                            if (priorityByUid == null) {
+                                priorityByUid = new SparseIntArray();
+                                mPackagePriorities.put(name, priorityByUid);
+                            }
+                            priorityByUid.put(uid, priority);
                         }
-                        priorityByUid.put(uid, priority);
+                        if (vis != NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE) {
+                            SparseIntArray visibilityByUid = mPackageVisibilities.get(name);
+                            if (visibilityByUid == null) {
+                                visibilityByUid = new SparseIntArray();
+                                mPackageVisibilities.put(name, visibilityByUid);
+                            }
+                            visibilityByUid.put(uid, vis);
+                        }
                     }
                 }
             }
@@ -140,18 +169,43 @@
         out.startTag(null, TAG_RANKING);
         out.attribute(null, ATT_VERSION, Integer.toString(XML_VERSION));
 
-        final int N = mPackagePriorities.size();
-        for (int i = 0; i < N; i ++) {
-            String name = mPackagePriorities.keyAt(i);
-            SparseIntArray priorityByUid = mPackagePriorities.get(name);
-            final int M = priorityByUid.size();
-            for (int j = 0; j < M; j++) {
-                int uid = priorityByUid.keyAt(j);
-                int priority = priorityByUid.get(uid);
+        final Set<String> packageNames = new ArraySet<>(mPackagePriorities.size()
+                + mPackageVisibilities.size());
+        packageNames.addAll(mPackagePriorities.keySet());
+        packageNames.addAll(mPackageVisibilities.keySet());
+        final Set<Integer> packageUids = new ArraySet<>();
+        for (String packageName : packageNames) {
+            packageUids.clear();
+            SparseIntArray priorityByUid = mPackagePriorities.get(packageName);
+            SparseIntArray visibilityByUid = mPackageVisibilities.get(packageName);
+            if (priorityByUid != null) {
+                final int M = priorityByUid.size();
+                for (int j = 0; j < M; j++) {
+                    packageUids.add(priorityByUid.keyAt(j));
+                }
+            }
+            if (visibilityByUid != null) {
+                final int M = visibilityByUid.size();
+                for (int j = 0; j < M; j++) {
+                    packageUids.add(visibilityByUid.keyAt(j));
+                }
+            }
+            for (Integer uid : packageUids) {
                 out.startTag(null, TAG_PACKAGE);
-                out.attribute(null, ATT_NAME, name);
+                out.attribute(null, ATT_NAME, packageName);
+                if (priorityByUid != null) {
+                    final int priority = priorityByUid.get(uid);
+                    if (priority != Notification.PRIORITY_DEFAULT) {
+                        out.attribute(null, ATT_PRIORITY, Integer.toString(priority));
+                    }
+                }
+                if (visibilityByUid != null) {
+                    final int visibility = visibilityByUid.get(uid);
+                    if (visibility != NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE) {
+                        out.attribute(null, ATT_VISIBILITY, Integer.toString(visibility));
+                    }
+                }
                 out.attribute(null, ATT_UID, Integer.toString(uid));
-                out.attribute(null, ATT_PRIORITY, Integer.toString(priority));
                 out.endTag(null, TAG_PACKAGE);
             }
         }
@@ -168,34 +222,75 @@
 
     public void sort(ArrayList<NotificationRecord> notificationList) {
         final int N = notificationList.size();
-        // clear group proxies
+        // clear global sort keys
         for (int i = N - 1; i >= 0; i--) {
-            notificationList.get(i).setRankingProxy(null);
+            notificationList.get(i).setGlobalSortKey(null);
         }
 
-        // rank each record individually
-        Collections.sort(notificationList, mPreliminaryComparator);
-
-        // record inidivdual ranking result and nominate proxies for each group
-        for (int i = N - 1; i >= 0; i--) {
-            final NotificationRecord record = notificationList.get(i);
-            record.setAuthoritativeRank(i);
-            final String groupKey = record.getGroupKey();
-            boolean isGroupSummary = record.getNotification().getGroup() != null
-                    && (record.getNotification().flags & Notification.FLAG_GROUP_SUMMARY) != 0;
-            if (isGroupSummary || mProxyByGroupTmp.get(groupKey) == null) {
-                mProxyByGroupTmp.put(groupKey, record);
+        try {
+            // rank each record individually
+            Collections.sort(notificationList, mPreliminaryComparator);
+        } catch (RuntimeException ex) {
+            // Don't crash the system server if something bad happened.
+            Log.e(TAG, "Extreme badness during notification sort", ex);
+            Log.e(TAG, "Current notification list: ");
+            for (int i = 0; i < N; i++) {
+                NotificationRecord nr = notificationList.get(i);
+                Log.e(TAG, String.format(
+                        "  [%d] %s (group %s, rank %d, sortkey %s)",
+                        i, nr, nr.getGroupKey(), nr.getAuthoritativeRank(),
+                        nr.getNotification().getSortKey()));
             }
+            // STOPSHIP: remove once b/16626175 is found
+            throw ex;
         }
-        // assign nominated proxies to each notification
-        for (int i = 0; i < N; i++) {
-            final NotificationRecord record = notificationList.get(i);
-            record.setRankingProxy(mProxyByGroupTmp.get(record.getGroupKey()));
+
+        synchronized (mProxyByGroupTmp) {
+            // record individual ranking result and nominate proxies for each group
+            for (int i = N - 1; i >= 0; i--) {
+                final NotificationRecord record = notificationList.get(i);
+                record.setAuthoritativeRank(i);
+                final String groupKey = record.getGroupKey();
+                boolean isGroupSummary = record.getNotification().isGroupSummary();
+                if (isGroupSummary || !mProxyByGroupTmp.containsKey(groupKey)) {
+                    mProxyByGroupTmp.put(groupKey, record);
+                }
+            }
+            // assign global sort key:
+            //   is_recently_intrusive:group_rank:is_group_summary:group_sort_key:rank
+            for (int i = 0; i < N; i++) {
+                final NotificationRecord record = notificationList.get(i);
+                NotificationRecord groupProxy = mProxyByGroupTmp.get(record.getGroupKey());
+                String groupSortKey = record.getNotification().getSortKey();
+
+                // We need to make sure the developer provided group sort key (gsk) is handled
+                // correctly:
+                //   gsk="" < gsk=non-null-string < gsk=null
+                //
+                // We enforce this by using different prefixes for these three cases.
+                String groupSortKeyPortion;
+                if (groupSortKey == null) {
+                    groupSortKeyPortion = "nsk";
+                } else if (groupSortKey.equals("")) {
+                    groupSortKeyPortion = "esk";
+                } else {
+                    groupSortKeyPortion = "gsk=" + groupSortKey;
+                }
+
+                boolean isGroupSummary = record.getNotification().isGroupSummary();
+                record.setGlobalSortKey(
+                        String.format("intrsv=%c:grnk=0x%04x:gsmry=%c:%s:rnk=0x%04x",
+                        record.isRecentlyIntrusive() ? '0' : '1',
+                        groupProxy.getAuthoritativeRank(),
+                        isGroupSummary ? '0' : '1',
+                        groupSortKeyPortion,
+                        record.getAuthoritativeRank()));
+            }
+            mProxyByGroupTmp.clear();
         }
+
         // Do a second ranking pass, using group proxies
         Collections.sort(notificationList, mFinalComparator);
-
-        mProxyByGroupTmp.clear();
     }
 
     public int indexOf(ArrayList<NotificationRecord> notificationList, NotificationRecord target) {
@@ -240,6 +335,31 @@
         updateConfig();
     }
 
+    @Override
+    public int getPackageVisibilityOverride(String packageName, int uid) {
+        int visibility = NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE;
+        SparseIntArray visibilityByUid = mPackageVisibilities.get(packageName);
+        if (visibilityByUid != null) {
+            visibility = visibilityByUid.get(uid,
+                    NotificationListenerService.Ranking.VISIBILITY_NO_OVERRIDE);
+        }
+        return visibility;
+    }
+
+    @Override
+    public void setPackageVisibilityOverride(String packageName, int uid, int visibility) {
+        if (visibility == getPackageVisibilityOverride(packageName, uid)) {
+            return;
+        }
+        SparseIntArray visibilityByUid = mPackageVisibilities.get(packageName);
+        if (visibilityByUid == null) {
+            visibilityByUid = new SparseIntArray();
+            mPackageVisibilities.put(packageName, visibilityByUid);
+        }
+        visibilityByUid.put(uid, visibility);
+        updateConfig();
+    }
+
     public void dump(PrintWriter pw, String prefix, NotificationManagerService.DumpFilter filter) {
         if (filter == null) {
             final int N = mSignalExtractors.length;
diff --git a/services/core/java/com/android/server/notification/ValidateNotificationPeople.java b/services/core/java/com/android/server/notification/ValidateNotificationPeople.java
index bdc364c..1c1a034 100644
--- a/services/core/java/com/android/server/notification/ValidateNotificationPeople.java
+++ b/services/core/java/com/android/server/notification/ValidateNotificationPeople.java
@@ -18,18 +18,25 @@
 
 import android.app.Notification;
 import android.content.Context;
+import android.content.pm.PackageManager;
+import android.database.ContentObserver;
 import android.database.Cursor;
 import android.net.Uri;
 import android.os.Bundle;
+import android.os.Handler;
+import android.os.UserHandle;
 import android.provider.ContactsContract;
 import android.provider.ContactsContract.Contacts;
 import android.provider.Settings;
 import android.text.TextUtils;
+import android.util.ArrayMap;
+import android.util.Log;
 import android.util.LruCache;
 import android.util.Slog;
 
 import java.util.ArrayList;
 import java.util.LinkedList;
+import java.util.Map;
 
 /**
  * This {@link NotificationSignalExtractor} attempts to validate
@@ -65,14 +72,110 @@
     static final float STARRED_CONTACT = 1f;
 
     protected boolean mEnabled;
-    private Context mContext;
+    private Context mBaseContext;
 
     // maps raw person handle to resolved person object
     private LruCache<String, LookupResult> mPeopleCache;
+    private Map<Integer, Context> mUserToContextMap;
+    private Handler mHandler;
+    private ContentObserver mObserver;
+    private int mEvictionCount;
 
-    private RankingReconsideration validatePeople(final NotificationRecord record) {
+    public void initialize(Context context) {
+        if (DEBUG) Slog.d(TAG, "Initializing  " + getClass().getSimpleName() + ".");
+        mUserToContextMap = new ArrayMap<>();
+        mBaseContext = context;
+        mPeopleCache = new LruCache<String, LookupResult>(PEOPLE_CACHE_SIZE);
+        mEnabled = ENABLE_PEOPLE_VALIDATOR && 1 == Settings.Global.getInt(
+                mBaseContext.getContentResolver(), SETTING_ENABLE_PEOPLE_VALIDATOR, 1);
+        if (mEnabled) {
+            mHandler = new Handler();
+            mObserver = new ContentObserver(mHandler) {
+                @Override
+                public void onChange(boolean selfChange, Uri uri, int userId) {
+                    super.onChange(selfChange, uri, userId);
+                    if (DEBUG || mEvictionCount % 100 == 0) {
+                        if (INFO) Slog.i(TAG, "mEvictionCount: " + mEvictionCount);
+                    }
+                    mPeopleCache.evictAll();
+                    mEvictionCount++;
+                }
+            };
+            mBaseContext.getContentResolver().registerContentObserver(Contacts.CONTENT_URI, true,
+                    mObserver, UserHandle.USER_ALL);
+        }
+    }
+
+    public RankingReconsideration process(NotificationRecord record) {
+        if (!mEnabled) {
+            if (INFO) Slog.i(TAG, "disabled");
+            return null;
+        }
+        if (record == null || record.getNotification() == null) {
+            if (INFO) Slog.i(TAG, "skipping empty notification");
+            return null;
+        }
+        if (record.getUserId() == UserHandle.USER_ALL) {
+            if (INFO) Slog.i(TAG, "skipping global notification");
+            return null;
+        }
+        Context context = getContextAsUser(record.getUser());
+        if (context == null) {
+            if (INFO) Slog.i(TAG, "skipping notification that lacks a context");
+            return null;
+        }
+        return validatePeople(context, record);
+    }
+
+    @Override
+    public void setConfig(RankingConfig config) {
+        // ignore: config has no relevant information yet.
+    }
+
+    public float getContactAffinity(UserHandle userHandle, Bundle extras) {
+        if (DEBUG) Slog.d(TAG, "checking affinity for " + userHandle);
+        if (extras == null) return NONE;
+        final String key = Long.toString(System.nanoTime());
+        final float[] affinityOut = new float[1];
+        Context context = getContextAsUser(userHandle);
+        if (context == null) {
+            return NONE;
+        }
+        final PeopleRankingReconsideration prr = validatePeople(context, key, extras, affinityOut);
+        float affinity = affinityOut[0];
+        if (prr != null) {
+            prr.work();
+            affinity = Math.max(prr.getContactAffinity(), affinity);
+        }
+        return affinity;
+    }
+
+    private Context getContextAsUser(UserHandle userHandle) {
+        Context context = mUserToContextMap.get(userHandle.getIdentifier());
+        if (context == null) {
+            try {
+                context = mBaseContext.createPackageContextAsUser("android", 0, userHandle);
+                mUserToContextMap.put(userHandle.getIdentifier(), context);
+            } catch (PackageManager.NameNotFoundException e) {
+                Log.e(TAG, "failed to create package context for lookups", e);
+            }
+        }
+        return context;
+    }
+
+    private RankingReconsideration validatePeople(Context context,
+            final NotificationRecord record) {
+        final String key = record.getKey();
+        final Bundle extras = record.getNotification().extras;
+        final float[] affinityOut = new float[1];
+        final RankingReconsideration rr = validatePeople(context, key, extras, affinityOut);
+        record.setContactAffinity(affinityOut[0]);
+        return rr;
+    }
+
+    private PeopleRankingReconsideration validatePeople(Context context, String key, Bundle extras,
+            float[] affinityOut) {
         float affinity = NONE;
-        Bundle extras = record.getNotification().extras;
         if (extras == null) {
             return null;
         }
@@ -82,14 +185,15 @@
             return null;
         }
 
-        if (INFO) Slog.i(TAG, "Validating: " + record.sbn.getKey());
+        if (INFO) Slog.i(TAG, "Validating: " + key);
         final LinkedList<String> pendingLookups = new LinkedList<String>();
         for (int personIdx = 0; personIdx < people.length && personIdx < MAX_PEOPLE; personIdx++) {
             final String handle = people[personIdx];
             if (TextUtils.isEmpty(handle)) continue;
 
             synchronized (mPeopleCache) {
-                LookupResult lookupResult = mPeopleCache.get(handle);
+                final String cacheKey = getCacheKey(context.getUserId(), handle);
+                LookupResult lookupResult = mPeopleCache.get(cacheKey);
                 if (lookupResult == null || lookupResult.isExpired()) {
                     pendingLookups.add(handle);
                 } else {
@@ -102,51 +206,19 @@
         }
 
         // record the best available data, so far:
-        record.setContactAffinity(affinity);
+        affinityOut[0] = affinity;
 
         if (pendingLookups.isEmpty()) {
             if (INFO) Slog.i(TAG, "final affinity: " + affinity);
             return null;
         }
 
-        if (DEBUG) Slog.d(TAG, "Pending: future work scheduled for: " + record.sbn.getKey());
-        return new RankingReconsideration(record.getKey()) {
-            float mContactAffinity = NONE;
-            @Override
-            public void work() {
-                if (INFO) Slog.i(TAG, "Executing: validation for: " + record.getKey());
-                for (final String handle: pendingLookups) {
-                    LookupResult lookupResult = null;
-                    final Uri uri = Uri.parse(handle);
-                    if ("tel".equals(uri.getScheme())) {
-                        if (DEBUG) Slog.d(TAG, "checking telephone URI: " + handle);
-                        lookupResult = resolvePhoneContact(uri.getSchemeSpecificPart());
-                    } else if ("mailto".equals(uri.getScheme())) {
-                        if (DEBUG) Slog.d(TAG, "checking mailto URI: " + handle);
-                        lookupResult = resolveEmailContact(uri.getSchemeSpecificPart());
-                    } else if (handle.startsWith(Contacts.CONTENT_LOOKUP_URI.toString())) {
-                        if (DEBUG) Slog.d(TAG, "checking lookup URI: " + handle);
-                        lookupResult = searchContacts(uri);
-                    } else {
-                        lookupResult = new LookupResult();  // invalid person for the cache
-                        Slog.w(TAG, "unsupported URI " + handle);
-                    }
-                    if (lookupResult != null) {
-                        synchronized (mPeopleCache) {
-                            mPeopleCache.put(handle, lookupResult);
-                        }
-                        mContactAffinity = Math.max(mContactAffinity, lookupResult.getAffinity());
-                    }
-                }
-            }
+        if (DEBUG) Slog.d(TAG, "Pending: future work scheduled for: " + key);
+        return new PeopleRankingReconsideration(context, key, pendingLookups);
+    }
 
-            @Override
-            public void applyChangesLocked(NotificationRecord operand) {
-                float affinityBound = operand.getContactAffinity();
-                operand.setContactAffinity(Math.max(mContactAffinity, affinityBound));
-                if (INFO) Slog.i(TAG, "final affinity: " + operand.getContactAffinity());
-            }
-        };
+    private String getCacheKey(int userId, String handle) {
+        return Integer.toString(userId) + ":" + handle;
     }
 
     // VisibleForTesting
@@ -212,24 +284,24 @@
         return null;
     }
 
-    private LookupResult resolvePhoneContact(final String number) {
+    private LookupResult resolvePhoneContact(Context context, final String number) {
         Uri phoneUri = Uri.withAppendedPath(ContactsContract.PhoneLookup.CONTENT_FILTER_URI,
                 Uri.encode(number));
-        return searchContacts(phoneUri);
+        return searchContacts(context, phoneUri);
     }
 
-    private LookupResult resolveEmailContact(final String email) {
+    private LookupResult resolveEmailContact(Context context, final String email) {
         Uri numberUri = Uri.withAppendedPath(
                 ContactsContract.CommonDataKinds.Email.CONTENT_LOOKUP_URI,
                 Uri.encode(email));
-        return searchContacts(numberUri);
+        return searchContacts(context, numberUri);
     }
 
-    private LookupResult searchContacts(Uri lookupUri) {
+    private LookupResult searchContacts(Context context, Uri lookupUri) {
         LookupResult lookupResult = new LookupResult();
         Cursor c = null;
         try {
-            c = mContext.getContentResolver().query(lookupUri, LOOKUP_PROJECTION, null, null, null);
+            c = context.getContentResolver().query(lookupUri, LOOKUP_PROJECTION, null, null, null);
             if (c != null && c.getCount() > 0) {
                 c.moveToFirst();
                 lookupResult.readContact(c);
@@ -244,31 +316,6 @@
         return lookupResult;
     }
 
-    public void initialize(Context context) {
-        if (DEBUG) Slog.d(TAG, "Initializing  " + getClass().getSimpleName() + ".");
-        mContext = context;
-        mPeopleCache = new LruCache<String, LookupResult>(PEOPLE_CACHE_SIZE);
-        mEnabled = ENABLE_PEOPLE_VALIDATOR && 1 == Settings.Global.getInt(
-                mContext.getContentResolver(), SETTING_ENABLE_PEOPLE_VALIDATOR, 1);
-    }
-
-    public RankingReconsideration process(NotificationRecord record) {
-        if (!mEnabled) {
-            if (INFO) Slog.i(TAG, "disabled");
-            return null;
-        }
-        if (record == null || record.getNotification() == null) {
-            if (INFO) Slog.i(TAG, "skipping empty notification");
-            return null;
-        }
-        return validatePeople(record);
-    }
-
-    @Override
-    public void setConfig(RankingConfig config) {
-        // ignore: config has no relevant information yet.
-    }
-
     private static class LookupResult {
         private static final long CONTACT_REFRESH_MILLIS = 60 * 60 * 1000;  // 1hr
         public static final int INVALID_ID = -1;
@@ -328,5 +375,58 @@
             return this;
         }
     }
+
+    private class PeopleRankingReconsideration extends RankingReconsideration {
+        private final LinkedList<String> mPendingLookups;
+        private final Context mContext;
+
+        private float mContactAffinity = NONE;
+
+        private PeopleRankingReconsideration(Context context, String key, LinkedList<String> pendingLookups) {
+            super(key);
+            mContext = context;
+            mPendingLookups = pendingLookups;
+        }
+
+        @Override
+        public void work() {
+            if (INFO) Slog.i(TAG, "Executing: validation for: " + mKey);
+            for (final String handle: mPendingLookups) {
+                LookupResult lookupResult = null;
+                final Uri uri = Uri.parse(handle);
+                if ("tel".equals(uri.getScheme())) {
+                    if (DEBUG) Slog.d(TAG, "checking telephone URI: " + handle);
+                    lookupResult = resolvePhoneContact(mContext, uri.getSchemeSpecificPart());
+                } else if ("mailto".equals(uri.getScheme())) {
+                    if (DEBUG) Slog.d(TAG, "checking mailto URI: " + handle);
+                    lookupResult = resolveEmailContact(mContext, uri.getSchemeSpecificPart());
+                } else if (handle.startsWith(Contacts.CONTENT_LOOKUP_URI.toString())) {
+                    if (DEBUG) Slog.d(TAG, "checking lookup URI: " + handle);
+                    lookupResult = searchContacts(mContext, uri);
+                } else {
+                    lookupResult = new LookupResult();  // invalid person for the cache
+                    Slog.w(TAG, "unsupported URI " + handle);
+                }
+                if (lookupResult != null) {
+                    synchronized (mPeopleCache) {
+                        final String cacheKey = getCacheKey(mContext.getUserId(), handle);
+                        mPeopleCache.put(cacheKey, lookupResult);
+                    }
+                    mContactAffinity = Math.max(mContactAffinity, lookupResult.getAffinity());
+                }
+            }
+        }
+
+        @Override
+        public void applyChangesLocked(NotificationRecord operand) {
+            float affinityBound = operand.getContactAffinity();
+            operand.setContactAffinity(Math.max(mContactAffinity, affinityBound));
+            if (INFO) Slog.i(TAG, "final affinity: " + operand.getContactAffinity());
+        }
+
+        public float getContactAffinity() {
+            return mContactAffinity;
+        }
+    }
 }
 
diff --git a/services/core/java/com/android/server/notification/ZenLog.java b/services/core/java/com/android/server/notification/ZenLog.java
index 525f5f8..f84409e 100644
--- a/services/core/java/com/android/server/notification/ZenLog.java
+++ b/services/core/java/com/android/server/notification/ZenLog.java
@@ -30,10 +30,7 @@
 
 import java.io.PrintWriter;
 import java.text.SimpleDateFormat;
-import java.util.Arrays;
 import java.util.Date;
-import java.util.HashSet;
-import java.util.Set;
 
 public class ZenLog {
     private static final String TAG = "ZenLog";
@@ -45,10 +42,6 @@
     private static final String[] MSGS = new String[SIZE];
 
     private static final SimpleDateFormat FORMAT = new SimpleDateFormat("MM-dd HH:mm:ss.SSS");
-    private static final Set<String> SYSTEM_PACKAGES = new HashSet<String>(Arrays.asList(
-            "android",
-            "com.android.systemui"
-            ));
 
     private static final int TYPE_INTERCEPTED = 1;
     private static final int TYPE_ALLOW_DISABLE = 2;
@@ -76,11 +69,6 @@
         append(TYPE_NOT_INTERCEPTED, record.getKey() + "," + reason);
     }
 
-    public static void traceAllowDisable(String pkg, boolean allowDisable, String reason) {
-        if (SYSTEM_PACKAGES.contains(pkg)) return;
-        append(TYPE_ALLOW_DISABLE, allowDisable + "," + pkg + "," + reason);
-    }
-
     public static void traceSetRingerMode(int ringerMode) {
         append(TYPE_SET_RINGER_MODE, ringerModeToString(ringerMode));
     }
diff --git a/services/core/java/com/android/server/notification/ZenModeHelper.java b/services/core/java/com/android/server/notification/ZenModeHelper.java
index 758f334..479af89 100644
--- a/services/core/java/com/android/server/notification/ZenModeHelper.java
+++ b/services/core/java/com/android/server/notification/ZenModeHelper.java
@@ -18,7 +18,6 @@
 
 import static android.media.AudioAttributes.USAGE_ALARM;
 import static android.media.AudioAttributes.USAGE_NOTIFICATION_RINGTONE;
-import static android.media.AudioAttributes.USAGE_UNKNOWN;
 
 import android.app.AppOpsManager;
 import android.app.Notification;
@@ -34,14 +33,14 @@
 import android.media.AudioAttributes;
 import android.media.AudioManager;
 import android.net.Uri;
+import android.os.Bundle;
 import android.os.Handler;
-import android.os.IBinder;
 import android.os.UserHandle;
 import android.provider.Settings.Global;
 import android.provider.Settings.Secure;
 import android.service.notification.NotificationListenerService;
 import android.service.notification.ZenModeConfig;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.util.Log;
 import android.util.Slog;
 
@@ -116,35 +115,35 @@
         mAudioManager = audioManager;
     }
 
-    public int getZenModeListenerHint() {
-        switch(mZenMode) {
+    public int getZenModeListenerInterruptionFilter() {
+        switch (mZenMode) {
             case Global.ZEN_MODE_OFF:
-                return NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_ALL;
+                return NotificationListenerService.INTERRUPTION_FILTER_ALL;
             case Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS:
-                return NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_PRIORITY;
+                return NotificationListenerService.INTERRUPTION_FILTER_PRIORITY;
             case Global.ZEN_MODE_NO_INTERRUPTIONS:
-                return NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_NONE;
+                return NotificationListenerService.INTERRUPTION_FILTER_NONE;
             default:
                 return 0;
         }
     }
 
-    private static int zenFromListenerHint(int hints, int defValue) {
-        final int level = hints & NotificationListenerService.HOST_INTERRUPTION_LEVEL_MASK;
-        switch(level) {
-            case NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_ALL:
+    private static int zenModeFromListenerInterruptionFilter(int listenerInterruptionFilter,
+            int defValue) {
+        switch (listenerInterruptionFilter) {
+            case NotificationListenerService.INTERRUPTION_FILTER_ALL:
                 return Global.ZEN_MODE_OFF;
-            case NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_PRIORITY:
+            case NotificationListenerService.INTERRUPTION_FILTER_PRIORITY:
                 return Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS;
-            case NotificationListenerService.HINT_HOST_INTERRUPTION_LEVEL_NONE:
+            case NotificationListenerService.INTERRUPTION_FILTER_NONE:
                 return Global.ZEN_MODE_NO_INTERRUPTIONS;
             default:
                 return defValue;
         }
     }
 
-    public void requestFromListener(int hints) {
-        final int newZen = zenFromListenerHint(hints, -1);
+    public void requestFromListener(int interruptionFilter) {
+        final int newZen = zenModeFromListenerInterruptionFilter(interruptionFilter, -1);
         if (newZen != -1) {
             setZenMode(newZen, "listener");
         }
@@ -190,7 +189,7 @@
     }
 
     private boolean shouldInterceptAudience(NotificationRecord record) {
-        if (!audienceMatches(record)) {
+        if (!audienceMatches(record.getContactAffinity())) {
             ZenLog.traceIntercepted(record, "!audienceMatches");
             return true;
         }
@@ -225,11 +224,6 @@
                 muteCalls ? AppOpsManager.MODE_IGNORED : AppOpsManager.MODE_ALLOWED,
                 exceptionPackages);
 
-        // restrict vibrations with no hints
-        mAppOps.setRestriction(AppOpsManager.OP_VIBRATE, USAGE_UNKNOWN,
-                zen ? AppOpsManager.MODE_IGNORED : AppOpsManager.MODE_ALLOWED,
-                exceptionPackages);
-
         // alarm restrictions
         final boolean muteAlarms = mZenMode == Global.ZEN_MODE_NO_INTERRUPTIONS;
         mAppOps.setRestriction(AppOpsManager.OP_VIBRATE, USAGE_ALARM,
@@ -265,18 +259,6 @@
         dispatchOnZenModeChanged();
     }
 
-    public boolean allowDisable(int what, IBinder token, String pkg) {
-        // TODO(cwren): delete this API before the next release. Bug:15344099
-        boolean allowDisable = true;
-        String reason = null;
-        if (isDefaultPhoneApp(pkg)) {
-            allowDisable = mZenMode == Global.ZEN_MODE_OFF || mConfig.allowCalls;
-            reason = mZenMode == Global.ZEN_MODE_OFF ? "zenOff" : "allowCalls";
-        }
-        ZenLog.traceAllowDisable(pkg, allowDisable, reason);
-        return allowDisable;
-    }
-
     public void dump(PrintWriter pw, String prefix) {
         pw.print(prefix); pw.print("mZenMode=");
         pw.println(Global.zenModeToString(mZenMode));
@@ -319,8 +301,8 @@
             final int ringerMode = mAudioManager.getRingerMode();
             int newZen = -1;
             if (ringerMode == AudioManager.RINGER_MODE_SILENT) {
-                if (mZenMode != Global.ZEN_MODE_NO_INTERRUPTIONS) {
-                    newZen = Global.ZEN_MODE_NO_INTERRUPTIONS;
+                if (mZenMode == Global.ZEN_MODE_OFF) {
+                    newZen = Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS;
                 }
             } else if ((ringerMode == AudioManager.RINGER_MODE_NORMAL
                     || ringerMode == AudioManager.RINGER_MODE_VIBRATE)
@@ -364,8 +346,8 @@
 
     private boolean isDefaultPhoneApp(String pkg) {
         if (mDefaultPhoneApp == null) {
-            final TelecommManager telecomm =
-                    (TelecommManager) mContext.getSystemService(Context.TELECOMM_SERVICE);
+            final TelecomManager telecomm =
+                    (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
             mDefaultPhoneApp = telecomm != null ? telecomm.getDefaultPhoneApp() : null;
             if (DEBUG) Slog.d(TAG, "Default phone app: " + mDefaultPhoneApp);
         }
@@ -385,14 +367,28 @@
         return record.isCategory(Notification.CATEGORY_MESSAGE) || isDefaultMessagingApp(record);
     }
 
-    private boolean audienceMatches(NotificationRecord record) {
+    public boolean matchesCallFilter(UserHandle userHandle, Bundle extras,
+            ValidateNotificationPeople validator) {
+        final int zen = mZenMode;
+        if (zen == Global.ZEN_MODE_NO_INTERRUPTIONS) return false; // nothing gets through
+        if (zen == Global.ZEN_MODE_IMPORTANT_INTERRUPTIONS) {
+            if (!mConfig.allowCalls) return false; // no calls get through
+            if (validator != null) {
+                final float contactAffinity = validator.getContactAffinity(userHandle, extras);
+                return audienceMatches(contactAffinity);
+            }
+        }
+        return true;
+    }
+
+    private boolean audienceMatches(float contactAffinity) {
         switch (mConfig.allowFrom) {
             case ZenModeConfig.SOURCE_ANYONE:
                 return true;
             case ZenModeConfig.SOURCE_CONTACT:
-                return record.getContactAffinity() >= ValidateNotificationPeople.VALID_CONTACT;
+                return contactAffinity >= ValidateNotificationPeople.VALID_CONTACT;
             case ZenModeConfig.SOURCE_STAR:
-                return record.getContactAffinity() >= ValidateNotificationPeople.STARRED_CONTACT;
+                return contactAffinity >= ValidateNotificationPeople.STARRED_CONTACT;
             default:
                 Slog.w(TAG, "Encountered unknown source: " + mConfig.allowFrom);
                 return true;
diff --git a/services/core/java/com/android/server/pm/BackgroundDexOptService.java b/services/core/java/com/android/server/pm/BackgroundDexOptService.java
index 355f34f..a7eebf8 100644
--- a/services/core/java/com/android/server/pm/BackgroundDexOptService.java
+++ b/services/core/java/com/android/server/pm/BackgroundDexOptService.java
@@ -75,7 +75,7 @@
                         schedule(BackgroundDexOptService.this);
                         return;
                     }
-                    pm.performDexOpt(pkg, null /* instruction set */, false);
+                    pm.performDexOpt(pkg, null /* instruction set */, true);
                 }
                 // ran to completion, so we abandon our timeslice and do not reschedule
                 jobFinished(jobParams, false);
diff --git a/services/core/java/com/android/server/pm/Installer.java b/services/core/java/com/android/server/pm/Installer.java
index d1e03ec..ca11862 100644
--- a/services/core/java/com/android/server/pm/Installer.java
+++ b/services/core/java/com/android/server/pm/Installer.java
@@ -61,17 +61,7 @@
             return -1;
         }
 
-        StringBuilder builder = new StringBuilder("patchoat");
-        builder.append(' ');
-        builder.append(apkPath);
-        builder.append(' ');
-        builder.append(uid);
-        builder.append(isPublic ? " 1" : " 0");
-        builder.append(' ');
-        builder.append(pkgName);
-        builder.append(' ');
-        builder.append(instructionSet);
-        return mInstaller.execute(builder.toString());
+        return mInstaller.patchoat(apkPath, uid, isPublic, pkgName, instructionSet);
     }
 
     public int patchoat(String apkPath, int uid, boolean isPublic, String instructionSet) {
@@ -93,23 +83,13 @@
     }
 
     public int dexopt(String apkPath, int uid, boolean isPublic, String pkgName,
-            String instructionSet) {
+            String instructionSet, boolean vmSafeMode) {
         if (!isValidInstructionSet(instructionSet)) {
             Slog.e(TAG, "Invalid instruction set: " + instructionSet);
             return -1;
         }
 
-        StringBuilder builder = new StringBuilder("dexopt");
-        builder.append(' ');
-        builder.append(apkPath);
-        builder.append(' ');
-        builder.append(uid);
-        builder.append(isPublic ? " 1" : " 0");
-        builder.append(' ');
-        builder.append(pkgName);
-        builder.append(' ');
-        builder.append(instructionSet);
-        return mInstaller.execute(builder.toString());
+        return mInstaller.dexopt(apkPath, uid, isPublic, pkgName, instructionSet, vmSafeMode);
     }
 
     public int idmap(String targetApkPath, String overlayApkPath, int uid) {
@@ -244,10 +224,6 @@
         }
     }
 
-    public int pruneDexCache(String cacheSubDir) {
-        return mInstaller.execute("prunedexcache " + cacheSubDir);
-    }
-
     public int freeCache(long freeStorageSize) {
         StringBuilder builder = new StringBuilder("freecache");
         builder.append(' ');
diff --git a/services/core/java/com/android/server/pm/KeySetManagerService.java b/services/core/java/com/android/server/pm/KeySetManagerService.java
index 37bedf3..4a8e318 100644
--- a/services/core/java/com/android/server/pm/KeySetManagerService.java
+++ b/services/core/java/com/android/server/pm/KeySetManagerService.java
@@ -538,14 +538,17 @@
                     pw.println("");
                 }
                 printedLabel = false;
-                for (long keySetId : pkg.keySetData.getSigningKeySets()) {
-                    if (!printedLabel) {
-                        pw.print("      Signing KeySets: ");
-                        printedLabel = true;
-                    } else {
-                        pw.print(", ");
+                final long[] signingKeySets = pkg.keySetData.getSigningKeySets();
+                if (signingKeySets != null) {
+                    for (long keySetId : signingKeySets) {
+                        if (!printedLabel) {
+                            pw.print("      Signing KeySets: ");
+                            printedLabel = true;
+                        } else {
+                            pw.print(", ");
+                        }
+                        pw.print(Long.toString(keySetId));
                     }
-                    pw.print(Long.toString(keySetId));
                 }
                 if (printedLabel) {
                     pw.println("");
diff --git a/services/core/java/com/android/server/pm/LauncherAppsService.java b/services/core/java/com/android/server/pm/LauncherAppsService.java
index b7b1c23..dcc4f8d 100644
--- a/services/core/java/com/android/server/pm/LauncherAppsService.java
+++ b/services/core/java/com/android/server/pm/LauncherAppsService.java
@@ -199,8 +199,7 @@
             mainIntent.setPackage(packageName);
             long ident = Binder.clearCallingIdentity();
             try {
-                List<ResolveInfo> apps = mPm.queryIntentActivitiesAsUser(mainIntent,
-                        PackageManager.NO_CROSS_PROFILE, // We only want the apps for this user
+                List<ResolveInfo> apps = mPm.queryIntentActivitiesAsUser(mainIntent, 0 /* flags */,
                         user.getIdentifier());
                 return apps;
             } finally {
@@ -288,8 +287,7 @@
                 // as calling startActivityAsUser ignores the category and just
                 // resolves based on the component if present.
                 List<ResolveInfo> apps = mPm.queryIntentActivitiesAsUser(launchIntent,
-                        PackageManager.NO_CROSS_PROFILE, // We only want the apps for this user
-                        user.getIdentifier());
+                        0 /* flags */, user.getIdentifier());
                 final int size = apps.size();
                 for (int i = 0; i < size; ++i) {
                     ActivityInfo activityInfo = apps.get(i).activityInfo;
diff --git a/services/core/java/com/android/server/pm/PackageInstallerService.java b/services/core/java/com/android/server/pm/PackageInstallerService.java
index dca8ad4..c106546 100644
--- a/services/core/java/com/android/server/pm/PackageInstallerService.java
+++ b/services/core/java/com/android/server/pm/PackageInstallerService.java
@@ -16,9 +16,6 @@
 
 package com.android.server.pm;
 
-import static android.content.pm.PackageManager.INSTALL_ALL_USERS;
-import static android.content.pm.PackageManager.INSTALL_FROM_ADB;
-import static android.content.pm.PackageManager.INSTALL_REPLACE_EXISTING;
 import static com.android.internal.util.XmlUtils.readBitmapAttribute;
 import static com.android.internal.util.XmlUtils.readBooleanAttribute;
 import static com.android.internal.util.XmlUtils.readIntAttribute;
@@ -75,13 +72,14 @@
 import android.util.Log;
 import android.util.Slog;
 import android.util.SparseArray;
+import android.util.SparseBooleanArray;
 import android.util.Xml;
 
 import com.android.internal.annotations.GuardedBy;
+import com.android.internal.content.PackageHelper;
 import com.android.internal.util.FastXmlSerializer;
 import com.android.internal.util.IndentingPrintWriter;
 import com.android.server.IoThread;
-import com.android.server.pm.PackageInstallerSession.Snapshot;
 import com.google.android.collect.Sets;
 
 import libcore.io.IoUtils;
@@ -104,10 +102,11 @@
 
 public class PackageInstallerService extends IPackageInstaller.Stub {
     private static final String TAG = "PackageInstaller";
-    private static final boolean LOGD = true;
+    private static final boolean LOGD = false;
 
     // TODO: remove outstanding sessions when installer package goes away
     // TODO: notify listeners in other users when package has been installed there
+    // TODO: purge expired sessions periodically in addition to at reboot
 
     /** XML constants used in {@link #mSessionsFile} */
     private static final String TAG_SESSIONS = "sessions";
@@ -115,8 +114,11 @@
     private static final String ATTR_SESSION_ID = "sessionId";
     private static final String ATTR_USER_ID = "userId";
     private static final String ATTR_INSTALLER_PACKAGE_NAME = "installerPackageName";
+    private static final String ATTR_INSTALLER_UID = "installerUid";
     private static final String ATTR_CREATED_MILLIS = "createdMillis";
     private static final String ATTR_SESSION_STAGE_DIR = "sessionStageDir";
+    private static final String ATTR_SESSION_STAGE_CID = "sessionStageCid";
+    private static final String ATTR_PREPARED = "prepared";
     private static final String ATTR_SEALED = "sealed";
     private static final String ATTR_MODE = "mode";
     private static final String ATTR_INSTALL_FLAGS = "installFlags";
@@ -142,6 +144,7 @@
 
     private final File mStagingDir;
     private final HandlerThread mInstallThread;
+    private final Handler mInstallHandler;
 
     private final Callbacks mCallbacks;
 
@@ -165,10 +168,14 @@
     @GuardedBy("mSessions")
     private final SparseArray<PackageInstallerSession> mHistoricalSessions = new SparseArray<>();
 
+    /** Sessions allocated to legacy users */
+    @GuardedBy("mSessions")
+    private final SparseBooleanArray mLegacySessions = new SparseBooleanArray();
+
     private static final FilenameFilter sStageFilter = new FilenameFilter() {
         @Override
         public boolean accept(File dir, String name) {
-            return name.startsWith("vmdl") && name.endsWith(".tmp");
+            return isStageName(name);
         }
     };
 
@@ -182,6 +189,8 @@
         mInstallThread = new HandlerThread(TAG);
         mInstallThread.start();
 
+        mInstallHandler = new Handler(mInstallThread.getLooper());
+
         mCallbacks = new Callbacks(mInstallThread.getLooper());
 
         mSessionsFile = new AtomicFile(
@@ -190,13 +199,16 @@
         synchronized (mSessions) {
             readSessionsLocked();
 
-            // Clean up orphaned staging directories
-            final ArraySet<File> stages = Sets.newArraySet(mStagingDir.listFiles(sStageFilter));
+            final ArraySet<File> unclaimed = Sets.newArraySet(mStagingDir.listFiles(sStageFilter));
+
+            // Ignore stages claimed by active sessions
             for (int i = 0; i < mSessions.size(); i++) {
                 final PackageInstallerSession session = mSessions.valueAt(i);
-                stages.remove(session.sessionStageDir);
+                unclaimed.remove(session.stageDir);
             }
-            for (File stage : stages) {
+
+            // Clean up orphaned staging directories
+            for (File stage : unclaimed) {
                 Slog.w(TAG, "Deleting orphan stage " + stage);
                 if (stage.isDirectory()) {
                     FileUtils.deleteContents(stage);
@@ -206,22 +218,66 @@
         }
     }
 
-    public static boolean isStageFile(File file) {
-        return sStageFilter.accept(null, file.getName());
+    public void onSecureContainersAvailable() {
+        synchronized (mSessions) {
+            final ArraySet<String> unclaimed = new ArraySet<>();
+            for (String cid : PackageHelper.getSecureContainerList()) {
+                if (isStageName(cid)) {
+                    unclaimed.add(cid);
+                }
+            }
+
+            // Ignore stages claimed by active sessions
+            for (int i = 0; i < mSessions.size(); i++) {
+                final PackageInstallerSession session = mSessions.valueAt(i);
+                final String cid = session.stageCid;
+
+                if (unclaimed.remove(cid)) {
+                    // Claimed by active session, mount it
+                    PackageHelper.mountSdDir(cid, PackageManagerService.getEncryptKey(),
+                            Process.SYSTEM_UID);
+                }
+            }
+
+            // Clean up orphaned staging containers
+            for (String cid : unclaimed) {
+                Slog.w(TAG, "Deleting orphan container " + cid);
+                PackageHelper.destroySdDir(cid);
+            }
+        }
+    }
+
+    public static boolean isStageName(String name) {
+        final boolean isFile = name.startsWith("vmdl") && name.endsWith(".tmp");
+        final boolean isContainer = name.startsWith("smdl") && name.endsWith(".tmp");
+        final boolean isLegacyContainer = name.startsWith("smdl2tmp");
+        return isFile || isContainer || isLegacyContainer;
     }
 
     @Deprecated
-    public File allocateSessionDir() throws IOException {
+    public File allocateInternalStageDirLegacy() throws IOException {
         synchronized (mSessions) {
             try {
                 final int sessionId = allocateSessionIdLocked();
-                return prepareSessionStageDir(sessionId);
+                mLegacySessions.put(sessionId, true);
+                final File stageDir = buildInternalStageDir(sessionId);
+                prepareInternalStageDir(stageDir);
+                return stageDir;
             } catch (IllegalStateException e) {
                 throw new IOException(e);
             }
         }
     }
 
+    @Deprecated
+    public String allocateExternalStageCidLegacy() {
+        synchronized (mSessions) {
+            final int sessionId = allocateSessionIdLocked();
+            mLegacySessions.put(sessionId, true);
+            return "smdl" + sessionId + ".tmp";
+        }
+    }
+
     private void readSessionsLocked() {
         if (LOGD) Slog.v(TAG, "readSessionsLocked()");
 
@@ -246,9 +302,10 @@
                             Slog.w(TAG, "Abandoning old session first created at "
                                     + session.createdMillis);
                             valid = false;
-                        } else if (!session.sessionStageDir.exists()) {
-                            Slog.w(TAG, "Abandoning session with missing stage "
-                                    + session.sessionStageDir);
+                        } else if (session.stageDir != null
+                                && !session.stageDir.exists()) {
+                            Slog.w(TAG, "Abandoning internal session with missing stage "
+                                    + session.stageDir);
                             valid = false;
                         } else {
                             valid = true;
@@ -280,8 +337,13 @@
         final int sessionId = readIntAttribute(in, ATTR_SESSION_ID);
         final int userId = readIntAttribute(in, ATTR_USER_ID);
         final String installerPackageName = readStringAttribute(in, ATTR_INSTALLER_PACKAGE_NAME);
+        final int installerUid = readIntAttribute(in, ATTR_INSTALLER_UID,
+                mPm.getPackageUid(installerPackageName, userId));
         final long createdMillis = readLongAttribute(in, ATTR_CREATED_MILLIS);
-        final File sessionStageDir = new File(readStringAttribute(in, ATTR_SESSION_STAGE_DIR));
+        final String stageDirRaw = readStringAttribute(in, ATTR_SESSION_STAGE_DIR);
+        final File stageDir = (stageDirRaw != null) ? new File(stageDirRaw) : null;
+        final String stageCid = readStringAttribute(in, ATTR_SESSION_STAGE_CID);
+        final boolean prepared = readBooleanAttribute(in, ATTR_PREPARED, true);
         final boolean sealed = readBooleanAttribute(in, ATTR_SEALED);
 
         final SessionParams params = new SessionParams(
@@ -298,8 +360,8 @@
         params.abiOverride = readStringAttribute(in, ATTR_ABI_OVERRIDE);
 
         return new PackageInstallerSession(mInternalCallback, mContext, mPm,
-                mInstallThread.getLooper(), sessionId, userId, installerPackageName, params,
-                createdMillis, sessionStageDir, sealed);
+                mInstallThread.getLooper(), sessionId, userId, installerPackageName, installerUid,
+                params, createdMillis, stageDir, stageCid, prepared, sealed);
     }
 
     private void writeSessionsLocked() {
@@ -332,7 +394,6 @@
     private void writeSessionLocked(XmlSerializer out, PackageInstallerSession session)
             throws IOException {
         final SessionParams params = session.params;
-        final Snapshot snapshot = session.snapshot();
 
         out.startTag(null, TAG_SESSION);
 
@@ -340,10 +401,17 @@
         writeIntAttribute(out, ATTR_USER_ID, session.userId);
         writeStringAttribute(out, ATTR_INSTALLER_PACKAGE_NAME,
                 session.installerPackageName);
+        writeIntAttribute(out, ATTR_INSTALLER_UID, session.installerUid);
         writeLongAttribute(out, ATTR_CREATED_MILLIS, session.createdMillis);
-        writeStringAttribute(out, ATTR_SESSION_STAGE_DIR,
-                session.sessionStageDir.getAbsolutePath());
-        writeBooleanAttribute(out, ATTR_SEALED, snapshot.sealed);
+        if (session.stageDir != null) {
+            writeStringAttribute(out, ATTR_SESSION_STAGE_DIR,
+                    session.stageDir.getAbsolutePath());
+        }
+        if (session.stageCid != null) {
+            writeStringAttribute(out, ATTR_SESSION_STAGE_CID, session.stageCid);
+        }
+        writeBooleanAttribute(out, ATTR_PREPARED, session.isPrepared());
+        writeBooleanAttribute(out, ATTR_SEALED, session.isSealed());
 
         writeIntAttribute(out, ATTR_MODE, params.mode);
         writeIntAttribute(out, ATTR_INSTALL_FLAGS, params.installFlags);
@@ -372,33 +440,31 @@
 
     @Override
     public int createSession(SessionParams params, String installerPackageName, int userId) {
-        final int callingUid = Binder.getCallingUid();
-        mPm.enforceCrossUserPermission(callingUid, userId, true, "createSession");
+        try {
+            return createSessionInternal(params, installerPackageName, userId);
+        } catch (IOException e) {
+            throw ExceptionUtils.wrap(e);
+        }
+    }
 
-        if (mPm.isUserRestricted(UserHandle.getUserId(callingUid),
-                UserManager.DISALLOW_INSTALL_APPS)) {
+    private int createSessionInternal(SessionParams params, String installerPackageName, int userId)
+            throws IOException {
+        final int callingUid = Binder.getCallingUid();
+        mPm.enforceCrossUserPermission(callingUid, userId, true, true, "createSession");
+
+        if (mPm.isUserRestricted(userId, UserManager.DISALLOW_INSTALL_APPS)) {
             throw new SecurityException("User restriction prevents installing");
         }
 
         if ((callingUid == Process.SHELL_UID) || (callingUid == Process.ROOT_UID)) {
-            installerPackageName = "com.android.shell";
-
-            params.installFlags |= INSTALL_FROM_ADB;
+            params.installFlags |= PackageManager.INSTALL_FROM_ADB;
 
         } else {
             mAppOps.checkPackage(callingUid, installerPackageName);
 
-            params.installFlags &= ~INSTALL_FROM_ADB;
-            params.installFlags &= ~INSTALL_ALL_USERS;
-            params.installFlags |= INSTALL_REPLACE_EXISTING;
-        }
-
-        switch (params.mode) {
-            case SessionParams.MODE_FULL_INSTALL:
-            case SessionParams.MODE_INHERIT_EXISTING:
-                break;
-            default:
-                throw new IllegalArgumentException("Params must have valid mode set");
+            params.installFlags &= ~PackageManager.INSTALL_FROM_ADB;
+            params.installFlags &= ~PackageManager.INSTALL_ALL_USERS;
+            params.installFlags |= PackageManager.INSTALL_REPLACE_EXISTING;
         }
 
         // Defensively resize giant app icons
@@ -413,13 +479,28 @@
             }
         }
 
-        // Sanity check that install could fit
-        if (params.sizeBytes > 0) {
+        if (params.mode == SessionParams.MODE_FULL_INSTALL
+                || params.mode == SessionParams.MODE_INHERIT_EXISTING) {
+            // Resolve best location for install, based on combination of
+            // requested install flags, delta size, and manifest settings.
+            final long ident = Binder.clearCallingIdentity();
             try {
-                mPm.freeStorage(params.sizeBytes);
-            } catch (IOException e) {
-                throw ExceptionUtils.wrap(e);
+                final int resolved = PackageHelper.resolveInstallLocation(mContext,
+                        params.appPackageName, params.installLocation, params.sizeBytes,
+                        params.installFlags);
+
+                if (resolved == PackageHelper.RECOMMEND_INSTALL_INTERNAL) {
+                    params.setInstallFlagsInternal();
+                } else if (resolved == PackageHelper.RECOMMEND_INSTALL_EXTERNAL) {
+                    params.setInstallFlagsExternal();
+                } else {
+                    throw new IOException("No storage with enough free space; res=" + resolved);
+                }
+            } finally {
+                Binder.restoreCallingIdentity(ident);
             }
+        } else {
+            throw new IllegalArgumentException("Invalid install mode: " + params.mode);
         }
 
         final int sessionId;
@@ -437,14 +518,21 @@
                         "Too many historical sessions for UID " + callingUid);
             }
 
+            final long createdMillis = System.currentTimeMillis();
             sessionId = allocateSessionIdLocked();
 
-            final long createdMillis = System.currentTimeMillis();
-            final File sessionStageDir = prepareSessionStageDir(sessionId);
+            // We're staging to exactly one location
+            File stageDir = null;
+            String stageCid = null;
+            if ((params.installFlags & PackageManager.INSTALL_INTERNAL) != 0) {
+                stageDir = buildInternalStageDir(sessionId);
+            } else {
+                stageCid = buildExternalStageCid(sessionId);
+            }
 
             session = new PackageInstallerSession(mInternalCallback, mContext, mPm,
-                    mInstallThread.getLooper(), sessionId, userId, installerPackageName, params,
-                    createdMillis, sessionStageDir, false);
+                    mInstallThread.getLooper(), sessionId, userId, installerPackageName, callingUid,
+                    params, createdMillis, stageDir, stageCid, false, false);
             mSessions.put(sessionId, session);
         }
 
@@ -454,18 +542,56 @@
     }
 
     @Override
-    public IPackageInstallerSession openSession(int sessionId) {
+    public void updateSessionAppIcon(int sessionId, Bitmap appIcon) {
         synchronized (mSessions) {
             final PackageInstallerSession session = mSessions.get(sessionId);
-            if (session == null) {
-                throw new IllegalStateException("Missing session " + sessionId);
-            }
-            if (!isCallingUidOwner(session)) {
+            if (session == null || !isCallingUidOwner(session)) {
                 throw new SecurityException("Caller has no access to session " + sessionId);
             }
-            if (session.openCount.getAndIncrement() == 0) {
-                mCallbacks.notifySessionOpened(sessionId, session.userId);
+            session.params.appIcon = appIcon;
+            mInternalCallback.onSessionBadgingChanged(session);
+        }
+    }
+
+    @Override
+    public void updateSessionAppLabel(int sessionId, String appLabel) {
+        synchronized (mSessions) {
+            final PackageInstallerSession session = mSessions.get(sessionId);
+            if (session == null || !isCallingUidOwner(session)) {
+                throw new SecurityException("Caller has no access to session " + sessionId);
             }
+            session.params.appLabel = appLabel;
+            mInternalCallback.onSessionBadgingChanged(session);
+        }
+    }
+
+    @Override
+    public void abandonSession(int sessionId) {
+        synchronized (mSessions) {
+            final PackageInstallerSession session = mSessions.get(sessionId);
+            if (session == null || !isCallingUidOwner(session)) {
+                throw new SecurityException("Caller has no access to session " + sessionId);
+            }
+            session.abandon();
+        }
+    }
+
+    @Override
+    public IPackageInstallerSession openSession(int sessionId) {
+        try {
+            return openSessionInternal(sessionId);
+        } catch (IOException e) {
+            throw ExceptionUtils.wrap(e);
+        }
+    }
+
+    private IPackageInstallerSession openSessionInternal(int sessionId) throws IOException {
+        synchronized (mSessions) {
+            final PackageInstallerSession session = mSessions.get(sessionId);
+            if (session == null || !isCallingUidOwner(session)) {
+                throw new SecurityException("Caller has no access to session " + sessionId);
+            }
+            session.open();
             return session;
         }
     }
@@ -475,7 +601,8 @@
         int sessionId;
         do {
             sessionId = mRandom.nextInt(Integer.MAX_VALUE - 1) + 1;
-            if (mSessions.get(sessionId) == null && mHistoricalSessions.get(sessionId) == null) {
+            if (mSessions.get(sessionId) == null && mHistoricalSessions.get(sessionId) == null
+                    && !mLegacySessions.get(sessionId, false)) {
                 return sessionId;
             }
         } while (n++ < 32);
@@ -483,43 +610,50 @@
         throw new IllegalStateException("Failed to allocate session ID");
     }
 
-    private File prepareSessionStageDir(int sessionId) {
-        final File file = new File(mStagingDir, "vmdl" + sessionId + ".tmp");
+    private File buildInternalStageDir(int sessionId) {
+        return new File(mStagingDir, "vmdl" + sessionId + ".tmp");
+    }
 
-        if (file.exists()) {
-            throw new IllegalStateException("Session dir already exists: " + file);
+    static void prepareInternalStageDir(File stageDir) throws IOException {
+        if (stageDir.exists()) {
+            throw new IOException("Session dir already exists: " + stageDir);
         }
 
         try {
-            Os.mkdir(file.getAbsolutePath(), 0755);
-            Os.chmod(file.getAbsolutePath(), 0755);
+            Os.mkdir(stageDir.getAbsolutePath(), 0755);
+            Os.chmod(stageDir.getAbsolutePath(), 0755);
         } catch (ErrnoException e) {
             // This purposefully throws if directory already exists
-            throw new IllegalStateException("Failed to prepare session dir", e);
+            throw new IOException("Failed to prepare session dir: " + stageDir, e);
         }
 
-        if (!SELinux.restorecon(file)) {
-            throw new IllegalStateException("Failed to restorecon session dir");
+        if (!SELinux.restorecon(stageDir)) {
+            throw new IOException("Failed to restorecon session dir: " + stageDir);
         }
+    }
 
-        return file;
+    private String buildExternalStageCid(int sessionId) {
+        return "smdl" + sessionId + ".tmp";
+    }
+
+    static void prepareExternalStageCid(String stageCid, long sizeBytes) throws IOException {
+        if (PackageHelper.createSdDir(sizeBytes, stageCid, PackageManagerService.getEncryptKey(),
+                Process.SYSTEM_UID, true) == null) {
+            throw new IOException("Failed to create session cid: " + stageCid);
+        }
     }
 
     @Override
     public SessionInfo getSessionInfo(int sessionId) {
         synchronized (mSessions) {
             final PackageInstallerSession session = mSessions.get(sessionId);
-            if (!isCallingUidOwner(session)) {
-                enforceCallerCanReadSessions();
-            }
             return session != null ? session.generateInfo() : null;
         }
     }
 
     @Override
     public List<SessionInfo> getAllSessions(int userId) {
-        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "getAllSessions");
-        enforceCallerCanReadSessions();
+        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false, "getAllSessions");
 
         final List<SessionInfo> result = new ArrayList<>();
         synchronized (mSessions) {
@@ -535,7 +669,7 @@
 
     @Override
     public List<SessionInfo> getMySessions(String installerPackageName, int userId) {
-        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "getMySessions");
+        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false, "getMySessions");
         mAppOps.checkPackage(Binder.getCallingUid(), installerPackageName);
 
         final List<SessionInfo> result = new ArrayList<>();
@@ -553,10 +687,10 @@
 
     @Override
     public void uninstall(String packageName, int flags, IntentSender statusReceiver, int userId) {
-        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "uninstall");
+        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, true, "uninstall");
 
         final PackageDeleteObserverAdapter adapter = new PackageDeleteObserverAdapter(mContext,
-                statusReceiver);
+                statusReceiver, packageName);
         if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.DELETE_PACKAGES)
                 == PackageManager.PERMISSION_GRANTED) {
             // Sweet, call straight through!
@@ -582,9 +716,7 @@
 
     @Override
     public void registerCallback(IPackageInstallerCallback callback, int userId) {
-        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "registerCallback");
-        enforceCallerCanReadSessions();
-
+        mPm.enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false, "registerCallback");
         mCallbacks.register(callback, userId);
     }
 
@@ -615,35 +747,24 @@
         }
     }
 
-    /**
-     * We allow those with permission, or the current home app.
-     */
-    private void enforceCallerCanReadSessions() {
-        final boolean hasPermission = (mContext.checkCallingOrSelfPermission(
-                android.Manifest.permission.READ_INSTALL_SESSIONS)
-                == PackageManager.PERMISSION_GRANTED);
-        final boolean isHomeApp = mPm.checkCallerIsHomeApp();
-        if (hasPermission || isHomeApp) {
-            return;
-        } else {
-            throw new SecurityException("Caller must be current home app to read install sessions");
-        }
-    }
-
     static class PackageDeleteObserverAdapter extends PackageDeleteObserver {
         private final Context mContext;
         private final IntentSender mTarget;
+        private final String mPackageName;
 
-        public PackageDeleteObserverAdapter(Context context, IntentSender target) {
+        public PackageDeleteObserverAdapter(Context context, IntentSender target,
+                String packageName) {
             mContext = context;
             mTarget = target;
+            mPackageName = packageName;
         }
 
         @Override
         public void onUserActionRequired(Intent intent) {
             final Intent fillIn = new Intent();
+            fillIn.putExtra(PackageInstaller.EXTRA_PACKAGE_NAME, mPackageName);
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS,
-                    PackageInstaller.STATUS_USER_ACTION_REQUIRED);
+                    PackageInstaller.STATUS_PENDING_USER_ACTION);
             fillIn.putExtra(Intent.EXTRA_INTENT, intent);
             try {
                 mTarget.sendIntent(mContext, 0, fillIn, null, null);
@@ -654,6 +775,7 @@
         @Override
         public void onPackageDeleted(String basePackageName, int returnCode, String msg) {
             final Intent fillIn = new Intent();
+            fillIn.putExtra(PackageInstaller.EXTRA_PACKAGE_NAME, mPackageName);
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS,
                     PackageManager.deleteStatusToPublicStatus(returnCode));
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS_MESSAGE,
@@ -669,17 +791,20 @@
     static class PackageInstallObserverAdapter extends PackageInstallObserver {
         private final Context mContext;
         private final IntentSender mTarget;
+        private final int mSessionId;
 
-        public PackageInstallObserverAdapter(Context context, IntentSender target) {
+        public PackageInstallObserverAdapter(Context context, IntentSender target, int sessionId) {
             mContext = context;
             mTarget = target;
+            mSessionId = sessionId;
         }
 
         @Override
         public void onUserActionRequired(Intent intent) {
             final Intent fillIn = new Intent();
+            fillIn.putExtra(PackageInstaller.EXTRA_SESSION_ID, mSessionId);
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS,
-                    PackageInstaller.STATUS_USER_ACTION_REQUIRED);
+                    PackageInstaller.STATUS_PENDING_USER_ACTION);
             fillIn.putExtra(Intent.EXTRA_INTENT, intent);
             try {
                 mTarget.sendIntent(mContext, 0, fillIn, null, null);
@@ -691,6 +816,7 @@
         public void onPackageInstalled(String basePackageName, int returnCode, String msg,
                 Bundle extras) {
             final Intent fillIn = new Intent();
+            fillIn.putExtra(PackageInstaller.EXTRA_SESSION_ID, mSessionId);
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS,
                     PackageManager.installStatusToPublicStatus(returnCode));
             fillIn.putExtra(PackageInstaller.EXTRA_STATUS_MESSAGE,
@@ -700,8 +826,7 @@
                 final String existing = extras.getString(
                         PackageManager.EXTRA_FAILURE_EXISTING_PACKAGE);
                 if (!TextUtils.isEmpty(existing)) {
-                    fillIn.putExtra(PackageInstaller.EXTRA_PACKAGE_NAMES, new String[] {
-                            existing });
+                    fillIn.putExtra(PackageInstaller.EXTRA_OTHER_PACKAGE_NAME, existing);
                 }
             }
             try {
@@ -713,9 +838,9 @@
 
     private static class Callbacks extends Handler {
         private static final int MSG_SESSION_CREATED = 1;
-        private static final int MSG_SESSION_OPENED = 2;
-        private static final int MSG_SESSION_PROGRESS_CHANGED = 3;
-        private static final int MSG_SESSION_CLOSED = 4;
+        private static final int MSG_SESSION_BADGING_CHANGED = 2;
+        private static final int MSG_SESSION_ACTIVE_CHANGED = 3;
+        private static final int MSG_SESSION_PROGRESS_CHANGED = 4;
         private static final int MSG_SESSION_FINISHED = 5;
 
         private final RemoteCallbackList<IPackageInstallerCallback>
@@ -758,15 +883,15 @@
                 case MSG_SESSION_CREATED:
                     callback.onSessionCreated(sessionId);
                     break;
-                case MSG_SESSION_OPENED:
-                    callback.onSessionOpened(sessionId);
+                case MSG_SESSION_BADGING_CHANGED:
+                    callback.onSessionBadgingChanged(sessionId);
+                    break;
+                case MSG_SESSION_ACTIVE_CHANGED:
+                    callback.onSessionActiveChanged(sessionId, (boolean) msg.obj);
                     break;
                 case MSG_SESSION_PROGRESS_CHANGED:
                     callback.onSessionProgressChanged(sessionId, (float) msg.obj);
                     break;
-                case MSG_SESSION_CLOSED:
-                    callback.onSessionClosed(sessionId);
-                    break;
                 case MSG_SESSION_FINISHED:
                     callback.onSessionFinished(sessionId, (boolean) msg.obj);
                     break;
@@ -777,18 +902,18 @@
             obtainMessage(MSG_SESSION_CREATED, sessionId, userId).sendToTarget();
         }
 
-        private void notifySessionOpened(int sessionId, int userId) {
-            obtainMessage(MSG_SESSION_OPENED, sessionId, userId).sendToTarget();
+        private void notifySessionBadgingChanged(int sessionId, int userId) {
+            obtainMessage(MSG_SESSION_BADGING_CHANGED, sessionId, userId).sendToTarget();
+        }
+
+        private void notifySessionActiveChanged(int sessionId, int userId, boolean active) {
+            obtainMessage(MSG_SESSION_ACTIVE_CHANGED, sessionId, userId, active).sendToTarget();
         }
 
         private void notifySessionProgressChanged(int sessionId, int userId, float progress) {
             obtainMessage(MSG_SESSION_PROGRESS_CHANGED, sessionId, userId, progress).sendToTarget();
         }
 
-        private void notifySessionClosed(int sessionId, int userId) {
-            obtainMessage(MSG_SESSION_CLOSED, sessionId, userId).sendToTarget();
-        }
-
         public void notifySessionFinished(int sessionId, int userId, boolean success) {
             obtainMessage(MSG_SESSION_FINISHED, sessionId, userId, success).sendToTarget();
         }
@@ -817,25 +942,56 @@
             }
             pw.println();
             pw.decreaseIndent();
+
+            pw.println("Legacy install sessions:");
+            pw.increaseIndent();
+            pw.println(mLegacySessions.toString());
+            pw.decreaseIndent();
         }
     }
 
     class InternalCallback {
+        public void onSessionBadgingChanged(PackageInstallerSession session) {
+            mCallbacks.notifySessionBadgingChanged(session.sessionId, session.userId);
+            writeSessionsAsync();
+        }
+
+        public void onSessionActiveChanged(PackageInstallerSession session, boolean active) {
+            mCallbacks.notifySessionActiveChanged(session.sessionId, session.userId, active);
+        }
+
         public void onSessionProgressChanged(PackageInstallerSession session, float progress) {
             mCallbacks.notifySessionProgressChanged(session.sessionId, session.userId, progress);
         }
 
-        public void onSessionClosed(PackageInstallerSession session) {
-            mCallbacks.notifySessionClosed(session.sessionId, session.userId);
+        public void onSessionFinished(final PackageInstallerSession session, boolean success) {
+            mCallbacks.notifySessionFinished(session.sessionId, session.userId, success);
+
+            mInstallHandler.post(new Runnable() {
+                @Override
+                public void run() {
+                    synchronized (mSessions) {
+                        mSessions.remove(session.sessionId);
+                        mHistoricalSessions.put(session.sessionId, session);
+                        writeSessionsLocked();
+                    }
+                }
+            });
         }
 
-        public void onSessionFinished(PackageInstallerSession session, boolean success) {
-            mCallbacks.notifySessionFinished(session.sessionId, session.userId, success);
-            synchronized (mSessions) {
-                mSessions.remove(session.sessionId);
-                mHistoricalSessions.put(session.sessionId, session);
-            }
+        public void onSessionPrepared(PackageInstallerSession session) {
+            // We prepared the destination to write into; we want to persist
+            // this, but it's not critical enough to block for.
             writeSessionsAsync();
         }
+
+        public void onSessionSealedBlocking(PackageInstallerSession session) {
+            // It's very important that we block until we've recorded the
+            // session as being sealed, since we never want to allow mutation
+            // after sealing.
+            synchronized (mSessions) {
+                writeSessionsLocked();
+            }
+        }
     }
 }
diff --git a/services/core/java/com/android/server/pm/PackageInstallerSession.java b/services/core/java/com/android/server/pm/PackageInstallerSession.java
index 5ef24f2..fb0e357 100644
--- a/services/core/java/com/android/server/pm/PackageInstallerSession.java
+++ b/services/core/java/com/android/server/pm/PackageInstallerSession.java
@@ -17,13 +17,15 @@
 package com.android.server.pm;
 
 import static android.content.pm.PackageManager.INSTALL_FAILED_ABORTED;
-import static android.content.pm.PackageManager.INSTALL_FAILED_ALREADY_EXISTS;
+import static android.content.pm.PackageManager.INSTALL_FAILED_CONTAINER_ERROR;
+import static android.content.pm.PackageManager.INSTALL_FAILED_INSUFFICIENT_STORAGE;
 import static android.content.pm.PackageManager.INSTALL_FAILED_INTERNAL_ERROR;
 import static android.content.pm.PackageManager.INSTALL_FAILED_INVALID_APK;
-import static android.content.pm.PackageManager.INSTALL_FAILED_PACKAGE_CHANGED;
 import static android.system.OsConstants.O_CREAT;
 import static android.system.OsConstants.O_RDONLY;
 import static android.system.OsConstants.O_WRONLY;
+import static com.android.server.pm.PackageInstallerService.prepareExternalStageCid;
+import static com.android.server.pm.PackageInstallerService.prepareInternalStageDir;
 
 import android.content.Context;
 import android.content.Intent;
@@ -37,6 +39,7 @@
 import android.content.pm.PackageManager;
 import android.content.pm.PackageParser;
 import android.content.pm.PackageParser.ApkLite;
+import android.content.pm.PackageParser.PackageLite;
 import android.content.pm.PackageParser.PackageParserException;
 import android.content.pm.Signature;
 import android.os.Bundle;
@@ -46,6 +49,7 @@
 import android.os.Looper;
 import android.os.Message;
 import android.os.ParcelFileDescriptor;
+import android.os.Process;
 import android.os.RemoteException;
 import android.os.UserHandle;
 import android.system.ErrnoException;
@@ -58,17 +62,21 @@
 import android.util.Slog;
 
 import com.android.internal.annotations.GuardedBy;
+import com.android.internal.content.NativeLibraryHelper;
+import com.android.internal.content.PackageHelper;
 import com.android.internal.util.ArrayUtils;
 import com.android.internal.util.IndentingPrintWriter;
 import com.android.internal.util.Preconditions;
 import com.android.server.pm.PackageInstallerService.PackageInstallObserverAdapter;
 
+import libcore.io.IoUtils;
 import libcore.io.Libcore;
 
 import java.io.File;
 import java.io.FileDescriptor;
 import java.io.IOException;
 import java.util.ArrayList;
+import java.util.List;
 import java.util.concurrent.atomic.AtomicInteger;
 
 public class PackageInstallerSession extends IPackageInstallerSession.Stub {
@@ -79,9 +87,6 @@
 
     // TODO: enforce INSTALL_ALLOW_TEST
     // TODO: enforce INSTALL_ALLOW_DOWNGRADE
-    // TODO: handle INSTALL_EXTERNAL, INSTALL_INTERNAL
-
-    // TODO: treat INHERIT_EXISTING as installExistingPackage()
 
     private final PackageInstallerService.InternalCallback mCallback;
     private final Context mContext;
@@ -91,25 +96,31 @@
     final int sessionId;
     final int userId;
     final String installerPackageName;
+    final int installerUid;
     final SessionParams params;
     final long createdMillis;
-    final File sessionStageDir;
 
-    /** Note that UID is not persisted; it's always derived at runtime. */
-    final int installerUid;
+    /** Staging location where client data is written. */
+    final File stageDir;
+    final String stageCid;
 
-    AtomicInteger openCount = new AtomicInteger();
+    private final AtomicInteger mActiveCount = new AtomicInteger();
 
     private final Object mLock = new Object();
 
     @GuardedBy("mLock")
     private float mClientProgress = 0;
     @GuardedBy("mLock")
+    private float mInternalProgress = 0;
+
+    @GuardedBy("mLock")
     private float mProgress = 0;
     @GuardedBy("mLock")
     private float mReportedProgress = -1;
 
     @GuardedBy("mLock")
+    private boolean mPrepared = false;
+    @GuardedBy("mLock")
     private boolean mSealed = false;
     @GuardedBy("mLock")
     private boolean mPermissionsAccepted = false;
@@ -119,17 +130,6 @@
     private int mFinalStatus;
     private String mFinalMessage;
 
-    /**
-     * Path to the resolved base APK for this session, which may point at an APK
-     * inside the session (when the session defines the base), or it may point
-     * at the existing base APK (when adding splits to an existing app).
-     * <p>
-     * This is used when confirming permissions, since we can't fully stage the
-     * session inside an ASEC before confirming with user.
-     */
-    @GuardedBy("mLock")
-    private String mResolvedBaseCodePath;
-
     @GuardedBy("mLock")
     private ArrayList<FileBridge> mBridges = new ArrayList<>();
 
@@ -141,6 +141,25 @@
     private int mVersionCode;
     private Signature[] mSignatures;
 
+    /**
+     * Path to the validated base APK for this session, which may point at an
+     * APK inside the session (when the session defines the base), or it may
+     * point at the existing base APK (when adding splits to an existing app).
+     * <p>
+     * This is used when confirming permissions, since we can't fully stage the
+     * session inside an ASEC before confirming with user.
+     */
+    @GuardedBy("mLock")
+    private File mResolvedBaseFile;
+
+    @GuardedBy("mLock")
+    private File mResolvedStageDir;
+
+    @GuardedBy("mLock")
+    private final List<File> mResolvedStagedFiles = new ArrayList<>();
+    @GuardedBy("mLock")
+    private final List<File> mResolvedInheritedFiles = new ArrayList<>();
+
     private final Handler.Callback mHandlerCallback = new Handler.Callback() {
         @Override
         public boolean handleMessage(Message msg) {
@@ -152,9 +171,10 @@
                 try {
                     commitLocked();
                 } catch (PackageManagerException e) {
-                    Slog.e(TAG, "Install failed: " + e);
+                    final String completeMsg = ExceptionUtils.getCompleteMessage(e);
+                    Slog.e(TAG, "Commit of session " + sessionId + " failed: " + completeMsg);
                     destroyInternal();
-                    dispatchSessionFinished(e.error, e.getMessage(), null);
+                    dispatchSessionFinished(e.error, completeMsg, null);
                 }
 
                 return true;
@@ -164,8 +184,8 @@
 
     public PackageInstallerSession(PackageInstallerService.InternalCallback callback,
             Context context, PackageManagerService pm, Looper looper, int sessionId, int userId,
-            String installerPackageName, SessionParams params, long createdMillis,
-            File sessionStageDir, boolean sealed) {
+            String installerPackageName, int installerUid, SessionParams params, long createdMillis,
+            File stageDir, String stageCid, boolean prepared, boolean sealed) {
         mCallback = callback;
         mContext = context;
         mPm = pm;
@@ -174,77 +194,117 @@
         this.sessionId = sessionId;
         this.userId = userId;
         this.installerPackageName = installerPackageName;
+        this.installerUid = installerUid;
         this.params = params;
         this.createdMillis = createdMillis;
-        this.sessionStageDir = sessionStageDir;
+        this.stageDir = stageDir;
+        this.stageCid = stageCid;
 
+        if ((stageDir == null) == (stageCid == null)) {
+            throw new IllegalArgumentException(
+                    "Exactly one of stageDir or stageCid stage must be set");
+        }
+
+        mPrepared = prepared;
         mSealed = sealed;
 
-        // Always derived at runtime
-        installerUid = mPm.getPackageUid(installerPackageName, userId);
-
-        if (mPm.checkPermission(android.Manifest.permission.INSTALL_PACKAGES,
-                installerPackageName) == PackageManager.PERMISSION_GRANTED) {
+        if ((mPm.checkUidPermission(android.Manifest.permission.INSTALL_PACKAGES, installerUid)
+                == PackageManager.PERMISSION_GRANTED) || (installerUid == Process.ROOT_UID)) {
             mPermissionsAccepted = true;
         } else {
             mPermissionsAccepted = false;
         }
-
-        computeProgressLocked();
     }
 
     public SessionInfo generateInfo() {
         final SessionInfo info = new SessionInfo();
+        synchronized (mLock) {
+            info.sessionId = sessionId;
+            info.installerPackageName = installerPackageName;
+            info.resolvedBaseCodePath = (mResolvedBaseFile != null) ?
+                    mResolvedBaseFile.getAbsolutePath() : null;
+            info.progress = mProgress;
+            info.sealed = mSealed;
+            info.active = mActiveCount.get() > 0;
 
-        info.sessionId = sessionId;
-        info.installerPackageName = installerPackageName;
-        info.resolvedBaseCodePath = mResolvedBaseCodePath;
-        info.progress = mProgress;
-        info.sealed = mSealed;
-        info.open = openCount.get() > 0;
-
-        info.mode = params.mode;
-        info.sizeBytes = params.sizeBytes;
-        info.appPackageName = params.appPackageName;
-        info.appIcon = params.appIcon;
-        info.appLabel = params.appLabel;
-
+            info.mode = params.mode;
+            info.sizeBytes = params.sizeBytes;
+            info.appPackageName = params.appPackageName;
+            info.appIcon = params.appIcon;
+            info.appLabel = params.appLabel;
+        }
         return info;
     }
 
-    private void assertNotSealed(String cookie) {
+    public boolean isPrepared() {
         synchronized (mLock) {
+            return mPrepared;
+        }
+    }
+
+    public boolean isSealed() {
+        synchronized (mLock) {
+            return mSealed;
+        }
+    }
+
+    private void assertPreparedAndNotSealed(String cookie) {
+        synchronized (mLock) {
+            if (!mPrepared) {
+                throw new IllegalStateException(cookie + " before prepared");
+            }
             if (mSealed) {
                 throw new SecurityException(cookie + " not allowed after commit");
             }
         }
     }
 
+    /**
+     * Resolve the actual location where staged data should be written. This
+     * might point at an ASEC mount point, which is why we delay path resolution
+     * until someone actively works with the session.
+     */
+    private File resolveStageDir() throws IOException {
+        synchronized (mLock) {
+            if (mResolvedStageDir == null) {
+                if (stageDir != null) {
+                    mResolvedStageDir = stageDir;
+                } else {
+                    final String path = PackageHelper.getSdDir(stageCid);
+                    if (path != null) {
+                        mResolvedStageDir = new File(path);
+                    } else {
+                        throw new IOException("Failed to resolve path to container " + stageCid);
+                    }
+                }
+            }
+            return mResolvedStageDir;
+        }
+    }
+
     @Override
     public void setClientProgress(float progress) {
         synchronized (mLock) {
+            // Always publish first staging movement
+            final boolean forcePublish = (mClientProgress == 0);
             mClientProgress = progress;
-            computeProgressLocked();
+            computeProgressLocked(forcePublish);
         }
-        maybePublishProgress();
     }
 
     @Override
     public void addClientProgress(float progress) {
         synchronized (mLock) {
-            mClientProgress += progress;
-            computeProgressLocked();
+            setClientProgress(mClientProgress + progress);
         }
-        maybePublishProgress();
     }
 
-    private void computeProgressLocked() {
-        mProgress = MathUtils.constrain(mClientProgress * 0.8f, 0f, 0.8f);
-    }
+    private void computeProgressLocked(boolean forcePublish) {
+        mProgress = MathUtils.constrain(mClientProgress * 0.8f, 0f, 0.8f)
+                + MathUtils.constrain(mInternalProgress * 0.2f, 0f, 0.2f);
 
-    private void maybePublishProgress() {
         // Only publish when meaningful change
-        if (Math.abs(mProgress - mReportedProgress) > 0.01) {
+        if (forcePublish || Math.abs(mProgress - mReportedProgress) >= 0.01) {
             mReportedProgress = mProgress;
             mCallback.onSessionProgressChanged(this, mProgress);
         }
@@ -252,8 +312,12 @@
 
     @Override
     public String[] getNames() {
-        assertNotSealed("getNames");
-        return sessionStageDir.list();
+        assertPreparedAndNotSealed("getNames");
+        try {
+            return resolveStageDir().list();
+        } catch (IOException e) {
+            throw ExceptionUtils.wrap(e);
+        }
     }
 
     @Override
@@ -267,14 +331,12 @@
 
     private ParcelFileDescriptor openWriteInternal(String name, long offsetBytes, long lengthBytes)
             throws IOException {
-        // TODO: relay over to DCS when installing to ASEC
-
         // Quick sanity check of state, and allocate a pipe for ourselves. We
         // then do heavy disk allocation outside the lock, but this open pipe
         // will block any attempted install transitions.
         final FileBridge bridge;
         synchronized (mLock) {
-            assertNotSealed("openWrite");
+            assertPreparedAndNotSealed("openWrite");
 
             bridge = new FileBridge();
             mBridges.add(bridge);
@@ -285,8 +347,10 @@
             if (!FileUtils.isValidExtFilename(name)) {
                 throw new IllegalArgumentException("Invalid name: " + name);
             }
-            final File target = new File(sessionStageDir, name);
+            final File target = new File(resolveStageDir(), name);
 
+            // TODO: this should delegate to DCS so the system process avoids
+            // holding open FDs into containers.
             final FileDescriptor targetFd = Libcore.os.open(target.getAbsolutePath(),
                     O_CREAT | O_WRONLY, 0644);
             Os.chmod(target.getAbsolutePath(), 0644);
@@ -296,7 +360,8 @@
             if (lengthBytes > 0) {
                 final StructStat stat = Libcore.os.fstat(targetFd);
                 final long deltaBytes = lengthBytes - stat.st_size;
-                if (deltaBytes > 0) {
+                // Only need to free up space when writing to internal stage
+                if (stageDir != null && deltaBytes > 0) {
                     mPm.freeStorage(deltaBytes);
                 }
                 Libcore.os.posix_fallocate(targetFd, 0, lengthBytes);
@@ -325,13 +390,13 @@
     }
 
     private ParcelFileDescriptor openReadInternal(String name) throws IOException {
-        assertNotSealed("openRead");
+        assertPreparedAndNotSealed("openRead");
 
         try {
             if (!FileUtils.isValidExtFilename(name)) {
                 throw new IllegalArgumentException("Invalid name: " + name);
             }
-            final File target = new File(sessionStageDir, name);
+            final File target = new File(resolveStageDir(), name);
 
             final FileDescriptor targetFd = Libcore.os.open(target.getAbsolutePath(), O_RDONLY, 0);
             return new ParcelFileDescriptor(targetFd);
@@ -345,28 +410,53 @@
     public void commit(IntentSender statusReceiver) {
         Preconditions.checkNotNull(statusReceiver);
 
+        final boolean wasSealed;
+        synchronized (mLock) {
+            wasSealed = mSealed;
+            if (!mSealed) {
+                // Verify that all writers are hands-off
+                for (FileBridge bridge : mBridges) {
+                    if (!bridge.isClosed()) {
+                        throw new SecurityException("Files still open");
+                    }
+                }
+                mSealed = true;
+            }
+
+            // Client staging is fully done at this point
+            mClientProgress = 1f;
+            computeProgressLocked(true);
+        }
+
+        if (!wasSealed) {
+            // Persist the fact that we've sealed ourselves to prevent
+            // mutations of any hard links we create. We do this without holding
+            // the session lock, since otherwise it's a lock inversion.
+            mCallback.onSessionSealedBlocking(this);
+        }
+
+        // This ongoing commit should keep session active, even though client
+        // will probably close their end.
+        mActiveCount.incrementAndGet();
+
         final PackageInstallObserverAdapter adapter = new PackageInstallObserverAdapter(mContext,
-                statusReceiver);
+                statusReceiver, sessionId);
         mHandler.obtainMessage(MSG_COMMIT, adapter.getBinder()).sendToTarget();
     }
 
     private void commitLocked() throws PackageManagerException {
         if (mDestroyed) {
-            throw new PackageManagerException(INSTALL_FAILED_ALREADY_EXISTS, "Invalid session");
+            throw new PackageManagerException(INSTALL_FAILED_INTERNAL_ERROR, "Session destroyed");
+        }
+        if (!mSealed) {
+            throw new PackageManagerException(INSTALL_FAILED_INTERNAL_ERROR, "Session not sealed");
         }
 
-        // Verify that all writers are hands-off
-        if (!mSealed) {
-            for (FileBridge bridge : mBridges) {
-                if (!bridge.isClosed()) {
-                    throw new PackageManagerException(INSTALL_FAILED_PACKAGE_CHANGED,
-                            "Files still open");
-                }
-            }
-            mSealed = true;
-
-            // TODO: persist disabled mutations before going forward, since
-            // beyond this point we may have hardlinks to the valid install
+        try {
+            resolveStageDir();
+        } catch (IOException e) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to resolve stage location", e);
         }
 
         // Verify that stage looks sane with respect to existing application.
@@ -376,7 +466,7 @@
 
         Preconditions.checkNotNull(mPackageName);
         Preconditions.checkNotNull(mSignatures);
-        Preconditions.checkNotNull(mResolvedBaseCodePath);
+        Preconditions.checkNotNull(mResolvedBaseFile);
 
         if (!mPermissionsAccepted) {
             // User needs to accept permissions; give installer an intent they
@@ -388,19 +478,49 @@
                 mRemoteObserver.onUserActionRequired(intent);
             } catch (RemoteException ignored) {
             }
+
+            // Commit was keeping session marked as active until now; release
+            // that extra refcount so session appears idle.
+            close();
             return;
         }
 
+        if (stageCid != null) {
+            // Figure out the final installed size and resize the container once
+            // and for all. Internally the parser handles straddling between two
+            // locations when inheriting.
+            final long finalSize = calculateInstalledSize();
+            resizeContainer(stageCid, finalSize);
+        }
+
         // Inherit any packages and native libraries from existing install that
         // haven't been overridden.
         if (params.mode == SessionParams.MODE_INHERIT_EXISTING) {
-            spliceExistingFilesIntoStage();
+            try {
+                if (stageCid != null) {
+                    // TODO: this should delegate to DCS so the system process
+                    // avoids holding open FDs into containers.
+                    copyFiles(mResolvedInheritedFiles, resolveStageDir());
+                } else {
+                    linkFiles(mResolvedInheritedFiles, resolveStageDir());
+                }
+            } catch (IOException e) {
+                throw new PackageManagerException(INSTALL_FAILED_INSUFFICIENT_STORAGE,
+                        "Failed to inherit existing install", e);
+            }
         }
 
         // TODO: surface more granular state from dexopt
-        mCallback.onSessionProgressChanged(this, 0.9f);
+        mInternalProgress = 0.5f;
+        computeProgressLocked(true);
 
-        // TODO: for ASEC based applications, grow and stream in packages
+        // Unpack native libraries
+        extractNativeLibraries(mResolvedStageDir, params.abiOverride);
+
+        // Container is ready to go, let's seal it up!
+        if (stageCid != null) {
+            finalizeAndFixContainer(stageCid);
+        }
 
         // We've reached point of no return; call into PMS to install the stage.
         // Regardless of success or failure we always destroy session.
@@ -418,86 +538,102 @@
             }
         };
 
-        mPm.installStage(mPackageName, this.sessionStageDir, localObserver, params,
-                installerPackageName, installerUid, new UserHandle(userId));
+        final UserHandle user;
+        if ((params.installFlags & PackageManager.INSTALL_ALL_USERS) != 0) {
+            user = UserHandle.ALL;
+        } else {
+            user = new UserHandle(userId);
+        }
+
+        mPm.installStage(mPackageName, stageDir, stageCid, localObserver, params,
+                installerPackageName, installerUid, user);
     }
 
     /**
      * Validate install by confirming that all application packages are have
      * consistent package name, version code, and signing certificates.
      * <p>
+     * Clears and populates {@link #mResolvedBaseFile},
+     * {@link #mResolvedStagedFiles}, and {@link #mResolvedInheritedFiles}.
+     * <p>
      * Renames package files in stage to match split names defined inside.
+     * <p>
+     * Note that upgrade compatibility is still performed by
+     * {@link PackageManagerService}.
      */
     private void validateInstallLocked() throws PackageManagerException {
         mPackageName = null;
         mVersionCode = -1;
         mSignatures = null;
-        mResolvedBaseCodePath = null;
 
-        final File[] files = sessionStageDir.listFiles();
+        mResolvedBaseFile = null;
+        mResolvedStagedFiles.clear();
+        mResolvedInheritedFiles.clear();
+
+        final File[] files = mResolvedStageDir.listFiles();
         if (ArrayUtils.isEmpty(files)) {
             throw new PackageManagerException(INSTALL_FAILED_INVALID_APK, "No packages staged");
         }
 
-        final ArraySet<String> seenSplits = new ArraySet<>();
-
         // Verify that all staged packages are internally consistent
+        final ArraySet<String> stagedSplits = new ArraySet<>();
         for (File file : files) {
-            final ApkLite info;
+
+            // Installers can't stage directories, so it's fine to ignore
+            // entries like "lost+found".
+            if (file.isDirectory()) continue;
+
+            final ApkLite apk;
             try {
-                info = PackageParser.parseApkLite(file, PackageParser.PARSE_GET_SIGNATURES);
+                apk = PackageParser.parseApkLite(file, PackageParser.PARSE_COLLECT_CERTIFICATES);
             } catch (PackageParserException e) {
-                throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
-                        "Failed to parse " + file + ": " + e);
+                throw PackageManagerException.from(e);
             }
 
-            if (!seenSplits.add(info.splitName)) {
+            if (!stagedSplits.add(apk.splitName)) {
                 throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
-                        "Split " + info.splitName + " was defined multiple times");
+                        "Split " + apk.splitName + " was defined multiple times");
             }
 
             // Use first package to define unknown values
             if (mPackageName == null) {
-                mPackageName = info.packageName;
-                mVersionCode = info.versionCode;
+                mPackageName = apk.packageName;
+                mVersionCode = apk.versionCode;
             }
             if (mSignatures == null) {
-                mSignatures = info.signatures;
+                mSignatures = apk.signatures;
             }
 
-            assertPackageConsistent(String.valueOf(file), info.packageName, info.versionCode,
-                    info.signatures);
+            assertApkConsistent(String.valueOf(file), apk);
 
             // Take this opportunity to enforce uniform naming
             final String targetName;
-            if (info.splitName == null) {
+            if (apk.splitName == null) {
                 targetName = "base.apk";
             } else {
-                targetName = "split_" + info.splitName + ".apk";
+                targetName = "split_" + apk.splitName + ".apk";
             }
             if (!FileUtils.isValidExtFilename(targetName)) {
                 throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
                         "Invalid filename: " + targetName);
             }
 
-            final File targetFile = new File(sessionStageDir, targetName);
+            final File targetFile = new File(mResolvedStageDir, targetName);
             if (!file.equals(targetFile)) {
                 file.renameTo(targetFile);
             }
 
             // Base is coming from session
-            if (info.splitName == null) {
-                mResolvedBaseCodePath = targetFile.getAbsolutePath();
+            if (apk.splitName == null) {
+                mResolvedBaseFile = targetFile;
             }
-        }
 
-        // TODO: shift package signature verification to installer; we're
-        // currently relying on PMS to do this.
-        // TODO: teach about compatible upgrade keysets.
+            mResolvedStagedFiles.add(targetFile);
+        }
 
         if (params.mode == SessionParams.MODE_FULL_INSTALL) {
             // Full installs must include a base package
-            if (!seenSplits.contains(null)) {
+            if (!stagedSplits.contains(null)) {
                 throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
                         "Full install must include a base package");
             }
@@ -510,67 +646,200 @@
                         "Missing existing base package for " + mPackageName);
             }
 
-            // Base might be inherited from existing install
-            if (mResolvedBaseCodePath == null) {
-                mResolvedBaseCodePath = app.getBaseCodePath();
-            }
-
-            final ApkLite info;
+            final PackageLite existing;
+            final ApkLite existingBase;
             try {
-                info = PackageParser.parseApkLite(new File(app.getBaseCodePath()),
-                        PackageParser.PARSE_GET_SIGNATURES);
+                existing = PackageParser.parsePackageLite(new File(app.getCodePath()), 0);
+                existingBase = PackageParser.parseApkLite(new File(app.getBaseCodePath()),
+                        PackageParser.PARSE_COLLECT_CERTIFICATES);
             } catch (PackageParserException e) {
-                throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
-                        "Failed to parse existing base " + app.getBaseCodePath() + ": " + e);
+                throw PackageManagerException.from(e);
             }
 
-            assertPackageConsistent("Existing base", info.packageName, info.versionCode,
-                    info.signatures);
+            assertApkConsistent("Existing base", existingBase);
+
+            // Inherit base if not overridden
+            if (mResolvedBaseFile == null) {
+                mResolvedBaseFile = new File(app.getBaseCodePath());
+                mResolvedInheritedFiles.add(mResolvedBaseFile);
+            }
+
+            // Inherit splits if not overridden
+            if (!ArrayUtils.isEmpty(existing.splitNames)) {
+                for (int i = 0; i < existing.splitNames.length; i++) {
+                    final String splitName = existing.splitNames[i];
+                    final File splitFile = new File(existing.splitCodePaths[i]);
+
+                    if (!stagedSplits.contains(splitName)) {
+                        mResolvedInheritedFiles.add(splitFile);
+                    }
+                }
+            }
         }
     }
 
-    private void assertPackageConsistent(String tag, String packageName, int versionCode,
-            Signature[] signatures) throws PackageManagerException {
-        if (!mPackageName.equals(packageName)) {
+    private void assertApkConsistent(String tag, ApkLite apk) throws PackageManagerException {
+        if (!mPackageName.equals(apk.packageName)) {
             throw new PackageManagerException(INSTALL_FAILED_INVALID_APK, tag + " package "
-                    + packageName + " inconsistent with " + mPackageName);
+                    + apk.packageName + " inconsistent with " + mPackageName);
         }
-        if (mVersionCode != versionCode) {
+        if (mVersionCode != apk.versionCode) {
             throw new PackageManagerException(INSTALL_FAILED_INVALID_APK, tag
-                    + " version code " + versionCode + " inconsistent with "
+                    + " version code " + apk.versionCode + " inconsistent with "
                     + mVersionCode);
         }
-        if (!Signature.areExactMatch(mSignatures, signatures)) {
+        if (!Signature.areExactMatch(mSignatures, apk.signatures)) {
             throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
                     tag + " signatures are inconsistent");
         }
     }
 
     /**
-     * Application is already installed; splice existing files that haven't been
-     * overridden into our stage.
+     * Calculate the final install footprint size, combining both staged and
+     * existing APKs together and including unpacked native code from both.
      */
-    private void spliceExistingFilesIntoStage() throws PackageManagerException {
-        final ApplicationInfo app = mPm.getApplicationInfo(mPackageName, 0, userId);
+    private long calculateInstalledSize() throws PackageManagerException {
+        Preconditions.checkNotNull(mResolvedBaseFile);
 
-        int n = 0;
-        final File[] oldFiles = new File(app.getCodePath()).listFiles();
-        if (!ArrayUtils.isEmpty(oldFiles)) {
-            for (File oldFile : oldFiles) {
-                if (!PackageParser.isApkFile(oldFile)) continue;
+        final ApkLite baseApk;
+        try {
+            baseApk = PackageParser.parseApkLite(mResolvedBaseFile, 0);
+        } catch (PackageParserException e) {
+            throw PackageManagerException.from(e);
+        }
 
-                final File newFile = new File(sessionStageDir, oldFile.getName());
-                try {
-                    Os.link(oldFile.getAbsolutePath(), newFile.getAbsolutePath());
-                    n++;
-                } catch (ErrnoException e) {
-                    throw new PackageManagerException(INSTALL_FAILED_INTERNAL_ERROR,
-                            "Failed to splice into stage", e);
-                }
+        final List<String> splitPaths = new ArrayList<>();
+        for (File file : mResolvedStagedFiles) {
+            if (mResolvedBaseFile.equals(file)) continue;
+            splitPaths.add(file.getAbsolutePath());
+        }
+        for (File file : mResolvedInheritedFiles) {
+            if (mResolvedBaseFile.equals(file)) continue;
+            splitPaths.add(file.getAbsolutePath());
+        }
+
+        // This is kind of hacky; we're creating a half-parsed package that is
+        // straddled between the inherited and staged APKs.
+        final PackageLite pkg = new PackageLite(null, baseApk, null,
+                splitPaths.toArray(new String[splitPaths.size()]));
+        final boolean isForwardLocked =
+                (params.installFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
+
+        try {
+            return PackageHelper.calculateInstalledSize(pkg, isForwardLocked, params.abiOverride);
+        } catch (IOException e) {
+            throw new PackageManagerException(INSTALL_FAILED_INVALID_APK,
+                    "Failed to calculate install size", e);
+        }
+    }
+
+    private static void linkFiles(List<File> fromFiles, File toDir) throws IOException {
+        for (File fromFile : fromFiles) {
+            final File toFile = new File(toDir, fromFile.getName());
+            try {
+                if (LOGD) Slog.d(TAG, "Linking " + fromFile + " to " + toFile);
+                Os.link(fromFile.getAbsolutePath(), toFile.getAbsolutePath());
+            } catch (ErrnoException e) {
+                throw new IOException("Failed to link " + fromFile + " to " + toFile, e);
+            }
+        }
+        Slog.d(TAG, "Linked " + fromFiles.size() + " files into " + toDir);
+    }
+
+    private static void copyFiles(List<File> fromFiles, File toDir) throws IOException {
+        // Remove any partial files from previous attempt
+        for (File file : toDir.listFiles()) {
+            if (file.getName().endsWith(".tmp")) {
+                file.delete();
             }
         }
 
-        if (LOGD) Slog.d(TAG, "Spliced " + n + " existing APKs into stage");
+        for (File fromFile : fromFiles) {
+            final File tmpFile = File.createTempFile("inherit", ".tmp", toDir);
+            if (LOGD) Slog.d(TAG, "Copying " + fromFile + " to " + tmpFile);
+            if (!FileUtils.copyFile(fromFile, tmpFile)) {
+                throw new IOException("Failed to copy " + fromFile + " to " + tmpFile);
+            }
+
+            final File toFile = new File(toDir, fromFile.getName());
+            if (LOGD) Slog.d(TAG, "Renaming " + tmpFile + " to " + toFile);
+            if (!tmpFile.renameTo(toFile)) {
+                throw new IOException("Failed to rename " + tmpFile + " to " + toFile);
+            }
+        }
+        Slog.d(TAG, "Copied " + fromFiles.size() + " files into " + toDir);
+    }
+
+    private static void extractNativeLibraries(File packageDir, String abiOverride)
+            throws PackageManagerException {
+        // Always start from a clean slate
+        final File libDir = new File(packageDir, NativeLibraryHelper.LIB_DIR_NAME);
+        NativeLibraryHelper.removeNativeBinariesFromDirLI(libDir, true);
+
+        NativeLibraryHelper.Handle handle = null;
+        try {
+            handle = NativeLibraryHelper.Handle.create(packageDir);
+            final int res = NativeLibraryHelper.copyNativeBinariesWithOverride(handle, libDir,
+                    abiOverride);
+            if (res != PackageManager.INSTALL_SUCCEEDED) {
+                throw new PackageManagerException(res,
+                        "Failed to extract native libraries, res=" + res);
+            }
+        } catch (IOException e) {
+            throw new PackageManagerException(INSTALL_FAILED_INTERNAL_ERROR,
+                    "Failed to extract native libraries", e);
+        } finally {
+            IoUtils.closeQuietly(handle);
+        }
+    }
+
+    private static void resizeContainer(String cid, long targetSize)
+            throws PackageManagerException {
+        String path = PackageHelper.getSdDir(cid);
+        if (path == null) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to find mounted " + cid);
+        }
+
+        final long currentSize = new File(path).getTotalSpace();
+        if (currentSize > targetSize) {
+            Slog.w(TAG, "Current size " + currentSize + " is larger than target size "
+                    + targetSize + "; skipping resize");
+            return;
+        }
+
+        if (!PackageHelper.unMountSdDir(cid)) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to unmount " + cid + " before resize");
+        }
+
+        if (!PackageHelper.resizeSdDir(targetSize, cid,
+                PackageManagerService.getEncryptKey())) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to resize " + cid + " to " + targetSize + " bytes");
+        }
+
+        path = PackageHelper.mountSdDir(cid, PackageManagerService.getEncryptKey(),
+                Process.SYSTEM_UID, false);
+        if (path == null) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to mount " + cid + " after resize");
+        }
+    }
+
+    private void finalizeAndFixContainer(String cid) throws PackageManagerException {
+        if (!PackageHelper.finalizeSdDir(cid)) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to finalize container " + cid);
+        }
+
+        final int uid = mPm.getPackageUid(PackageManagerService.DEFAULT_CONTAINER_PACKAGE,
+                UserHandle.USER_OWNER);
+        final int gid = UserHandle.getSharedAppGid(uid);
+        if (!PackageHelper.fixSdPermissions(cid, gid, null)) {
+            throw new PackageManagerException(INSTALL_FAILED_CONTAINER_ERROR,
+                    "Failed to fix permissions on container " + cid);
+        }
     }
 
     void setPermissionsResult(boolean accepted) {
@@ -588,10 +857,36 @@
         }
     }
 
+    public void open() throws IOException {
+        if (mActiveCount.getAndIncrement() == 0) {
+            mCallback.onSessionActiveChanged(this, true);
+        }
+
+        synchronized (mLock) {
+            if (!mPrepared) {
+                if (stageDir != null) {
+                    prepareInternalStageDir(stageDir);
+                } else if (stageCid != null) {
+                    prepareExternalStageCid(stageCid, params.sizeBytes);
+
+                    // TODO: deliver more granular progress for ASEC allocation
+                    mInternalProgress = 0.25f;
+                    computeProgressLocked(true);
+                } else {
+                    throw new IllegalArgumentException(
+                            "Exactly one of stageDir or stageCid stage must be set");
+                }
+
+                mPrepared = true;
+                mCallback.onSessionPrepared(this);
+            }
+        }
+    }
+
     @Override
     public void close() {
-        if (openCount.decrementAndGet() == 0) {
-            mCallback.onSessionClosed(this);
+        if (mActiveCount.decrementAndGet() == 0) {
+            mCallback.onSessionActiveChanged(this, false);
         }
     }
 
@@ -620,12 +915,28 @@
         synchronized (mLock) {
             mSealed = true;
             mDestroyed = true;
+
+            // Force shut down all bridges
+            for (FileBridge bridge : mBridges) {
+                bridge.forceClose();
+            }
         }
-        FileUtils.deleteContents(sessionStageDir);
-        sessionStageDir.delete();
+        if (stageDir != null) {
+            FileUtils.deleteContents(stageDir);
+            stageDir.delete();
+        }
+        if (stageCid != null) {
+            PackageHelper.destroySdDir(stageCid);
+        }
     }
 
     void dump(IndentingPrintWriter pw) {
+        synchronized (mLock) {
+            dumpLocked(pw);
+        }
+    }
+
+    private void dumpLocked(IndentingPrintWriter pw) {
         pw.println("Session " + sessionId + ":");
         pw.increaseIndent();
 
@@ -633,7 +944,8 @@
         pw.printPair("installerPackageName", installerPackageName);
         pw.printPair("installerUid", installerUid);
         pw.printPair("createdMillis", createdMillis);
-        pw.printPair("sessionStageDir", sessionStageDir);
+        pw.printPair("stageDir", stageDir);
+        pw.printPair("stageCid", stageCid);
         pw.println();
 
         params.dump(pw);
@@ -650,18 +962,4 @@
 
         pw.decreaseIndent();
     }
-
-    Snapshot snapshot() {
-        return new Snapshot(this);
-    }
-
-    static class Snapshot {
-        final float clientProgress;
-        final boolean sealed;
-
-        public Snapshot(PackageInstallerSession session) {
-            clientProgress = session.mClientProgress;
-            sealed = session.mSealed;
-        }
-    }
 }
diff --git a/services/core/java/com/android/server/pm/PackageManagerException.java b/services/core/java/com/android/server/pm/PackageManagerException.java
index 0cbdcdc..a41636e 100644
--- a/services/core/java/com/android/server/pm/PackageManagerException.java
+++ b/services/core/java/com/android/server/pm/PackageManagerException.java
@@ -16,6 +16,8 @@
 
 package com.android.server.pm;
 
+import android.content.pm.PackageParser.PackageParserException;
+
 /** {@hide} */
 public class PackageManagerException extends Exception {
     public final int error;
@@ -29,4 +31,9 @@
         super(detailMessage, throwable);
         this.error = error;
     }
+
+    public static PackageManagerException from(PackageParserException e)
+            throws PackageManagerException {
+        throw new PackageManagerException(e.error, e.getMessage(), e.getCause());
+    }
 }
diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java
index c1f7e85..79c9955 100644
--- a/services/core/java/com/android/server/pm/PackageManagerService.java
+++ b/services/core/java/com/android/server/pm/PackageManagerService.java
@@ -48,13 +48,10 @@
 import static android.os.Process.SYSTEM_UID;
 import static android.system.OsConstants.O_CREAT;
 import static android.system.OsConstants.O_RDWR;
-import static android.system.OsConstants.S_IRGRP;
-import static android.system.OsConstants.S_IROTH;
-import static android.system.OsConstants.S_IRWXU;
-import static android.system.OsConstants.S_IXGRP;
-import static android.system.OsConstants.S_IXOTH;
 import static com.android.internal.app.IntentForwarderActivity.FORWARD_INTENT_TO_MANAGED_PROFILE;
 import static com.android.internal.app.IntentForwarderActivity.FORWARD_INTENT_TO_USER_OWNER;
+import static com.android.internal.content.NativeLibraryHelper.LIB64_DIR_NAME;
+import static com.android.internal.content.NativeLibraryHelper.LIB_DIR_NAME;
 import static com.android.internal.util.ArrayUtils.appendInt;
 import static com.android.internal.util.ArrayUtils.removeInt;
 
@@ -70,7 +67,6 @@
 import com.android.internal.util.FastPrintWriter;
 import com.android.internal.util.FastXmlSerializer;
 import com.android.internal.util.IndentingPrintWriter;
-import com.android.internal.util.Preconditions;
 import com.android.server.EventLogTags;
 import com.android.server.IntentResolver;
 import com.android.server.LocalServices;
@@ -108,6 +104,7 @@
 import android.content.pm.IPackageMoveObserver;
 import android.content.pm.IPackageStatsObserver;
 import android.content.pm.InstrumentationInfo;
+import android.content.pm.KeySet;
 import android.content.pm.ManifestDigest;
 import android.content.pm.PackageCleanItem;
 import android.content.pm.PackageInfo;
@@ -140,6 +137,8 @@
 import android.os.Bundle;
 import android.os.Environment;
 import android.os.Environment.UserEnvironment;
+import android.os.storage.StorageManager;
+import android.os.Debug;
 import android.os.FileUtils;
 import android.os.Handler;
 import android.os.IBinder;
@@ -211,6 +210,7 @@
 import dalvik.system.VMRuntime;
 
 import libcore.io.IoUtils;
+import libcore.util.EmptyArray;
 
 /**
  * Keep track of all those .apks everywhere.
@@ -253,11 +253,6 @@
     // package apks to install directory.
     private static final String INSTALL_PACKAGE_SUFFIX = "-";
 
-    // Special value for {@code PackageParser.Package#cpuAbiOverride} to indicate
-    // that the cpuAbiOverride must be clear.
-    private static final String CLEAR_ABI_OVERRIDE = "-";
-
-    static final int SCAN_MONITOR = 1<<0;
     static final int SCAN_NO_DEX = 1<<1;
     static final int SCAN_FORCE_DEX = 1<<2;
     static final int SCAN_UPDATE_SIGNATURE = 1<<3;
@@ -268,6 +263,7 @@
     static final int SCAN_BOOTING = 1<<8;
     static final int SCAN_TRUSTED_OVERLAY = 1<<9;
     static final int SCAN_DELETE_DATA_ON_FAILURES = 1<<10;
+    static final int SCAN_REPLACING = 1<<11;
 
     static final int REMOVE_CHATTY = 1<<16;
 
@@ -306,13 +302,8 @@
 
     private static final String PACKAGE_MIME_TYPE = "application/vnd.android.package-archive";
 
-    private static final String LIB_DIR_NAME = "lib";
-    private static final String LIB64_DIR_NAME = "lib64";
-
     private static final String VENDOR_OVERLAY_DIR = "/vendor/overlay";
 
-    static final String mTempContainerPrefix = "smdl2tmp";
-
     private static String sPreferredInstructionSet;
 
     final ServiceThread mHandlerThread;
@@ -322,11 +313,18 @@
 
     final PackageHandler mHandler;
 
+    /**
+     * Messages for {@link #mHandler} that need to wait for system ready before
+     * being dispatched.
+     */
+    private ArrayList<Message> mPostSystemReadyMessages;
+
     final int mSdkVersion = Build.VERSION.SDK_INT;
 
     final Context mContext;
     final boolean mFactoryTest;
     final boolean mOnlyCore;
+    final boolean mLazyDexOpt;
     final DisplayMetrics mMetrics;
     final int mDefParseFlags;
     final String[] mSeparateProcesses;
@@ -364,12 +362,6 @@
     // the suffix "LI".
     final Object mInstallLock = new Object();
 
-    // These are the directories in the 3rd party applications installed dir
-    // that we have currently loaded packages from.  Keys are the application's
-    // installed zip file (absolute codePath), and values are Package.
-    final HashMap<String, PackageParser.Package> mAppDirs =
-            new HashMap<String, PackageParser.Package>();
-
     // ----------------------------------------------------------------
 
     // Keys are String (package name), values are Package.  This also serves
@@ -461,9 +453,9 @@
     /** Token for keys in mPendingVerification. */
     private int mPendingVerificationToken = 0;
 
-    boolean mSystemReady;
-    boolean mSafeMode;
-    boolean mHasSystemUidErrors;
+    volatile boolean mSystemReady;
+    volatile boolean mSafeMode;
+    volatile boolean mHasSystemUidErrors;
 
     ApplicationInfo mAndroidApplication;
     final ActivityInfo mResolveActivity = new ActivityInfo();
@@ -1131,7 +1123,7 @@
 
                     if ((state != null) && !state.timeoutExtended()) {
                         final InstallArgs args = state.getInstallArgs();
-                        final Uri originUri = Uri.fromFile(args.originFile);
+                        final Uri originUri = Uri.fromFile(args.origin.resolvedFile);
 
                         Slog.i(TAG, "Verification timed out for " + originUri);
                         mPendingVerification.remove(verificationId);
@@ -1178,7 +1170,7 @@
                         mPendingVerification.remove(verificationId);
 
                         final InstallArgs args = state.getInstallArgs();
-                        final Uri originUri = Uri.fromFile(args.originFile);
+                        final Uri originUri = Uri.fromFile(args.origin.resolvedFile);
 
                         int ret;
                         if (state.isInstallAllowed()) {
@@ -1282,6 +1274,7 @@
         mContext = context;
         mFactoryTest = factoryTest;
         mOnlyCore = onlyCore;
+        mLazyDexOpt = "eng".equals(SystemProperties.get("ro.build.type"));
         mMetrics = new DisplayMetrics();
         mSettings = new Settings(context);
         mSettings.addSharedUserLPw("android.uid.system", Process.SYSTEM_UID,
@@ -1385,7 +1378,7 @@
 
             // Set flag to monitor and not change apk file paths when
             // scanning install directories.
-            int scanMode = SCAN_MONITOR | SCAN_NO_PATHS | SCAN_DEFER_DEX | SCAN_BOOTING;
+            int scanFlags = SCAN_NO_PATHS | SCAN_DEFER_DEX | SCAN_BOOTING;
 
             final HashSet<String> alreadyDexOpted = new HashSet<String>();
 
@@ -1514,53 +1507,30 @@
                 }
             }
 
-            if (didDexOptLibraryOrTool) {
-                // If we dexopted a library or tool, then something on the system has
-                // changed. Consider this significant, and wipe away all other
-                // existing dexopt files to ensure we don't leave any dangling around.
-                //
-                // TODO: This should be revisited because it isn't as good an indicator
-                // as it used to be. It used to include the boot classpath but at some point
-                // DexFile.isDexOptNeeded started returning false for the boot
-                // class path files in all cases. It is very possible in a
-                // small maintenance release update that the library and tool
-                // jars may be unchanged but APK could be removed resulting in
-                // unused dalvik-cache files.
-                for (String dexCodeInstructionSet : dexCodeInstructionSets) {
-                    mInstaller.pruneDexCache(dexCodeInstructionSet);
-                }
-
-                // Additionally, delete all dex files from the root directory
-                // since there shouldn't be any there anyway, unless we're upgrading
-                // from an older OS version or a build that contained the "old" style
-                // flat scheme.
-                mInstaller.pruneDexCache(".");
-            }
-
             // Collect vendor overlay packages.
             // (Do this before scanning any apps.)
             // For security and version matching reason, only consider
             // overlay packages if they reside in VENDOR_OVERLAY_DIR.
             File vendorOverlayDir = new File(VENDOR_OVERLAY_DIR);
             scanDirLI(vendorOverlayDir, PackageParser.PARSE_IS_SYSTEM
-                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanMode | SCAN_TRUSTED_OVERLAY, 0);
+                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanFlags | SCAN_TRUSTED_OVERLAY, 0);
 
             // Find base frameworks (resource packages without code).
             scanDirLI(frameworkDir, PackageParser.PARSE_IS_SYSTEM
                     | PackageParser.PARSE_IS_SYSTEM_DIR
                     | PackageParser.PARSE_IS_PRIVILEGED,
-                    scanMode | SCAN_NO_DEX, 0);
+                    scanFlags | SCAN_NO_DEX, 0);
 
             // Collected privileged system packages.
             File privilegedAppDir = new File(Environment.getRootDirectory(), "priv-app");
             scanDirLI(privilegedAppDir, PackageParser.PARSE_IS_SYSTEM
                     | PackageParser.PARSE_IS_SYSTEM_DIR
-                    | PackageParser.PARSE_IS_PRIVILEGED, scanMode, 0);
+                    | PackageParser.PARSE_IS_PRIVILEGED, scanFlags, 0);
 
             // Collect ordinary system packages.
             File systemAppDir = new File(Environment.getRootDirectory(), "app");
             scanDirLI(systemAppDir, PackageParser.PARSE_IS_SYSTEM
-                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanMode, 0);
+                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanFlags, 0);
 
             // Collect all vendor packages.
             File vendorAppDir = new File("/vendor/app");
@@ -1570,12 +1540,12 @@
                 // failed to look up canonical path, continue with original one
             }
             scanDirLI(vendorAppDir, PackageParser.PARSE_IS_SYSTEM
-                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanMode, 0);
+                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanFlags, 0);
 
             // Collect all OEM packages.
             File oemAppDir = new File(Environment.getOemDirectory(), "app");
             scanDirLI(oemAppDir, PackageParser.PARSE_IS_SYSTEM
-                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanMode, 0);
+                    | PackageParser.PARSE_IS_SYSTEM_DIR, scanFlags, 0);
 
             if (DEBUG_UPGRADE) Log.v(TAG, "Running installd update commands");
             mInstaller.moveFiles();
@@ -1647,10 +1617,10 @@
             if (!mOnlyCore) {
                 EventLog.writeEvent(EventLogTags.BOOT_PROGRESS_PMS_DATA_SCAN_START,
                         SystemClock.uptimeMillis());
-                scanDirLI(mAppInstallDir, 0, scanMode, 0);
+                scanDirLI(mAppInstallDir, 0, scanFlags, 0);
 
                 scanDirLI(mDrmAppPrivateInstallDir, PackageParser.PARSE_FORWARD_LOCK,
-                        scanMode, 0);
+                        scanFlags, 0);
 
                 /**
                  * Remove disable package settings for any updated system
@@ -1823,19 +1793,17 @@
     void cleanupInstallFailedPackage(PackageSetting ps) {
         Slog.i(TAG, "Cleaning up incompletely installed app: " + ps.name);
         removeDataDirsLI(ps.name);
-
-        // TODO: try cleaning up codePath directory contents first, since it
-        // might be a cluster
-
         if (ps.codePath != null) {
-            if (!ps.codePath.delete()) {
-                Slog.w(TAG, "Unable to remove old code file: " + ps.codePath);
+            if (ps.codePath.isDirectory()) {
+                FileUtils.deleteContents(ps.codePath);
             }
+            ps.codePath.delete();
         }
-        if (ps.resourcePath != null) {
-            if (!ps.resourcePath.delete() && !ps.resourcePath.equals(ps.codePath)) {
-                Slog.w(TAG, "Unable to remove old code file: " + ps.resourcePath);
+        if (ps.resourcePath != null && !ps.resourcePath.equals(ps.codePath)) {
+            if (ps.resourcePath.isDirectory()) {
+                FileUtils.deleteContents(ps.resourcePath);
             }
+            ps.resourcePath.delete();
         }
         mSettings.removePackageLPw(ps.name);
     }
@@ -1876,7 +1844,7 @@
     @Override
     public boolean isPackageAvailable(String packageName, int userId) {
         if (!sUserManager.exists(userId)) return false;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "is package available");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "is package available");
         synchronized (mPackages) {
             PackageParser.Package p = mPackages.get(packageName);
             if (p != null) {
@@ -1895,7 +1863,7 @@
     @Override
     public PackageInfo getPackageInfo(String packageName, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get package info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get package info");
         // reader
         synchronized (mPackages) {
             PackageParser.Package p = mPackages.get(packageName);
@@ -1940,7 +1908,7 @@
     @Override
     public int getPackageUid(String packageName, int userId) {
         if (!sUserManager.exists(userId)) return -1;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get package uid");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get package uid");
         // reader
         synchronized (mPackages) {
             PackageParser.Package p = mPackages.get(packageName);
@@ -2090,7 +2058,7 @@
     @Override
     public ApplicationInfo getApplicationInfo(String packageName, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get application info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get application info");
         // writer
         synchronized (mPackages) {
             PackageParser.Package p = mPackages.get(packageName);
@@ -2181,7 +2149,7 @@
     @Override
     public ActivityInfo getActivityInfo(ComponentName component, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get activity info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get activity info");
         synchronized (mPackages) {
             PackageParser.Activity a = mActivities.mActivities.get(component);
 
@@ -2220,7 +2188,7 @@
     @Override
     public ActivityInfo getReceiverInfo(ComponentName component, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get receiver info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get receiver info");
         synchronized (mPackages) {
             PackageParser.Activity a = mReceivers.mActivities.get(component);
             if (DEBUG_PACKAGE_INFO) Log.v(
@@ -2238,7 +2206,7 @@
     @Override
     public ServiceInfo getServiceInfo(ComponentName component, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get service info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get service info");
         synchronized (mPackages) {
             PackageParser.Service s = mServices.mServices.get(component);
             if (DEBUG_PACKAGE_INFO) Log.v(
@@ -2256,7 +2224,7 @@
     @Override
     public ProviderInfo getProviderInfo(ComponentName component, int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "get provider info");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "get provider info");
         synchronized (mPackages) {
             PackageParser.Provider p = mProviders.mProviders.get(component);
             if (DEBUG_PACKAGE_INFO) Log.v(
@@ -2360,13 +2328,17 @@
     /**
      * Checks if the request is from the system or an app that has INTERACT_ACROSS_USERS
      * or INTERACT_ACROSS_USERS_FULL permissions, if the userid is not for the caller.
+     * @param checkShell TODO(yamasani):
      * @param message the message to log on security exception
      */
     void enforceCrossUserPermission(int callingUid, int userId, boolean requireFullPermission,
-            String message) {
+            boolean checkShell, String message) {
         if (userId < 0) {
             throw new IllegalArgumentException("Invalid userId " + userId);
         }
+        if (checkShell) {
+            enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, callingUid, userId);
+        }
         if (userId == UserHandle.getUserId(callingUid)) return;
         if (callingUid != Process.SYSTEM_UID && callingUid != 0) {
             if (requireFullPermission) {
@@ -2384,6 +2356,19 @@
         }
     }
 
+    void enforceShellRestriction(String restriction, int callingUid, int userHandle) {
+        if (callingUid == Process.SHELL_UID) {
+            if (userHandle >= 0
+                    && sUserManager.hasUserRestriction(restriction, userHandle)) {
+                throw new SecurityException("Shell does not have permission to access user "
+                        + userHandle);
+            } else if (userHandle < 0) {
+                Slog.e(TAG, "Unable to check shell permission for user " + userHandle + "\n\t"
+                        + Debug.getCallers(3));
+            }
+        }
+    }
+
     private BasePermission findPermissionTreeLP(String permName) {
         for(BasePermission bp : mSettings.mPermissionTrees.values()) {
             if (permName.startsWith(bp.name) &&
@@ -2907,7 +2892,7 @@
     public ResolveInfo resolveIntent(Intent intent, String resolvedType,
             int flags, int userId) {
         if (!sUserManager.exists(userId)) return null;
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "resolve intent");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "resolve intent");
         List<ResolveInfo> query = queryIntentActivities(intent, resolvedType, flags, userId);
         return chooseBestActivity(intent, resolvedType, flags, query, userId);
     }
@@ -3074,115 +3059,125 @@
                             (flags & PackageManager.MATCH_DEFAULT_ONLY) != 0, userId)
                     : null;
             if (prefs != null && prefs.size() > 0) {
-                // First figure out how good the original match set is.
-                // We will only allow preferred activities that came
-                // from the same match quality.
-                int match = 0;
+                boolean changed = false;
+                try {
+                    // First figure out how good the original match set is.
+                    // We will only allow preferred activities that came
+                    // from the same match quality.
+                    int match = 0;
 
-                if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Figuring out best match...");
+                    if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Figuring out best match...");
 
-                final int N = query.size();
-                for (int j=0; j<N; j++) {
-                    final ResolveInfo ri = query.get(j);
-                    if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Match for " + ri.activityInfo
-                            + ": 0x" + Integer.toHexString(match));
-                    if (ri.match > match) {
-                        match = ri.match;
-                    }
-                }
-
-                if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Best match: 0x"
-                        + Integer.toHexString(match));
-
-                match &= IntentFilter.MATCH_CATEGORY_MASK;
-                final int M = prefs.size();
-                for (int i=0; i<M; i++) {
-                    final PreferredActivity pa = prefs.get(i);
-                    if (DEBUG_PREFERRED || debug) {
-                        Slog.v(TAG, "Checking PreferredActivity ds="
-                                + (pa.countDataSchemes() > 0 ? pa.getDataScheme(0) : "<none>")
-                                + "\n  component=" + pa.mPref.mComponent);
-                        pa.dump(new LogPrinter(Log.VERBOSE, TAG, Log.LOG_ID_SYSTEM), "  ");
-                    }
-                    if (pa.mPref.mMatch != match) {
-                        if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Skipping bad match "
-                                + Integer.toHexString(pa.mPref.mMatch));
-                        continue;
-                    }
-                    // If it's not an "always" type preferred activity and that's what we're
-                    // looking for, skip it.
-                    if (always && !pa.mPref.mAlways) {
-                        if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Skipping mAlways=false entry");
-                        continue;
-                    }
-                    final ActivityInfo ai = getActivityInfo(pa.mPref.mComponent,
-                            flags | PackageManager.GET_DISABLED_COMPONENTS, userId);
-                    if (DEBUG_PREFERRED || debug) {
-                        Slog.v(TAG, "Found preferred activity:");
-                        if (ai != null) {
-                            ai.dump(new LogPrinter(Log.VERBOSE, TAG, Log.LOG_ID_SYSTEM), "  ");
-                        } else {
-                            Slog.v(TAG, "  null");
-                        }
-                    }
-                    if (ai == null) {
-                        // This previously registered preferred activity
-                        // component is no longer known.  Most likely an update
-                        // to the app was installed and in the new version this
-                        // component no longer exists.  Clean it up by removing
-                        // it from the preferred activities list, and skip it.
-                        Slog.w(TAG, "Removing dangling preferred activity: "
-                                + pa.mPref.mComponent);
-                        pir.removeFilter(pa);
-                        continue;
-                    }
+                    final int N = query.size();
                     for (int j=0; j<N; j++) {
                         final ResolveInfo ri = query.get(j);
-                        if (!ri.activityInfo.applicationInfo.packageName
-                                .equals(ai.applicationInfo.packageName)) {
+                        if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Match for " + ri.activityInfo
+                                + ": 0x" + Integer.toHexString(match));
+                        if (ri.match > match) {
+                            match = ri.match;
+                        }
+                    }
+
+                    if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Best match: 0x"
+                            + Integer.toHexString(match));
+
+                    match &= IntentFilter.MATCH_CATEGORY_MASK;
+                    final int M = prefs.size();
+                    for (int i=0; i<M; i++) {
+                        final PreferredActivity pa = prefs.get(i);
+                        if (DEBUG_PREFERRED || debug) {
+                            Slog.v(TAG, "Checking PreferredActivity ds="
+                                    + (pa.countDataSchemes() > 0 ? pa.getDataScheme(0) : "<none>")
+                                    + "\n  component=" + pa.mPref.mComponent);
+                            pa.dump(new LogPrinter(Log.VERBOSE, TAG, Log.LOG_ID_SYSTEM), "  ");
+                        }
+                        if (pa.mPref.mMatch != match) {
+                            if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Skipping bad match "
+                                    + Integer.toHexString(pa.mPref.mMatch));
                             continue;
                         }
-                        if (!ri.activityInfo.name.equals(ai.name)) {
+                        // If it's not an "always" type preferred activity and that's what we're
+                        // looking for, skip it.
+                        if (always && !pa.mPref.mAlways) {
+                            if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Skipping mAlways=false entry");
                             continue;
                         }
-
-                        if (removeMatches) {
-                            pir.removeFilter(pa);
-                            if (DEBUG_PREFERRED) {
-                                Slog.v(TAG, "Removing match " + pa.mPref.mComponent);
+                        final ActivityInfo ai = getActivityInfo(pa.mPref.mComponent,
+                                flags | PackageManager.GET_DISABLED_COMPONENTS, userId);
+                        if (DEBUG_PREFERRED || debug) {
+                            Slog.v(TAG, "Found preferred activity:");
+                            if (ai != null) {
+                                ai.dump(new LogPrinter(Log.VERBOSE, TAG, Log.LOG_ID_SYSTEM), "  ");
+                            } else {
+                                Slog.v(TAG, "  null");
                             }
-                            break;
                         }
-
-                        // Okay we found a previously set preferred or last chosen app.
-                        // If the result set is different from when this
-                        // was created, we need to clear it and re-ask the
-                        // user their preference, if we're looking for an "always" type entry.
-                        if (always && !pa.mPref.sameSet(query, priority)) {
-                            Slog.i(TAG, "Result set changed, dropping preferred activity for "
-                                    + intent + " type " + resolvedType);
-                            if (DEBUG_PREFERRED) {
-                                Slog.v(TAG, "Removing preferred activity since set changed "
-                                        + pa.mPref.mComponent);
-                            }
+                        if (ai == null) {
+                            // This previously registered preferred activity
+                            // component is no longer known.  Most likely an update
+                            // to the app was installed and in the new version this
+                            // component no longer exists.  Clean it up by removing
+                            // it from the preferred activities list, and skip it.
+                            Slog.w(TAG, "Removing dangling preferred activity: "
+                                    + pa.mPref.mComponent);
                             pir.removeFilter(pa);
-                            // Re-add the filter as a "last chosen" entry (!always)
-                            PreferredActivity lastChosen = new PreferredActivity(
-                                    pa, pa.mPref.mMatch, null, pa.mPref.mComponent, false);
-                            pir.addFilter(lastChosen);
-                            mSettings.writePackageRestrictionsLPr(userId);
-                            return null;
+                            changed = true;
+                            continue;
                         }
+                        for (int j=0; j<N; j++) {
+                            final ResolveInfo ri = query.get(j);
+                            if (!ri.activityInfo.applicationInfo.packageName
+                                    .equals(ai.applicationInfo.packageName)) {
+                                continue;
+                            }
+                            if (!ri.activityInfo.name.equals(ai.name)) {
+                                continue;
+                            }
 
-                        // Yay! Either the set matched or we're looking for the last chosen
-                        if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Returning preferred activity: "
-                                + ri.activityInfo.packageName + "/" + ri.activityInfo.name);
+                            if (removeMatches) {
+                                pir.removeFilter(pa);
+                                changed = true;
+                                if (DEBUG_PREFERRED) {
+                                    Slog.v(TAG, "Removing match " + pa.mPref.mComponent);
+                                }
+                                break;
+                            }
+
+                            // Okay we found a previously set preferred or last chosen app.
+                            // If the result set is different from when this
+                            // was created, we need to clear it and re-ask the
+                            // user their preference, if we're looking for an "always" type entry.
+                            if (always && !pa.mPref.sameSet(query, priority)) {
+                                Slog.i(TAG, "Result set changed, dropping preferred activity for "
+                                        + intent + " type " + resolvedType);
+                                if (DEBUG_PREFERRED) {
+                                    Slog.v(TAG, "Removing preferred activity since set changed "
+                                            + pa.mPref.mComponent);
+                                }
+                                pir.removeFilter(pa);
+                                // Re-add the filter as a "last chosen" entry (!always)
+                                PreferredActivity lastChosen = new PreferredActivity(
+                                        pa, pa.mPref.mMatch, null, pa.mPref.mComponent, false);
+                                pir.addFilter(lastChosen);
+                                changed = true;
+                                return null;
+                            }
+
+                            // Yay! Either the set matched or we're looking for the last chosen
+                            if (DEBUG_PREFERRED || debug) Slog.v(TAG, "Returning preferred activity: "
+                                    + ri.activityInfo.packageName + "/" + ri.activityInfo.name);
+                            return ri;
+                        }
+                    }
+                } finally {
+                    if (changed) {
+                        if (DEBUG_PREFERRED) {
+                            Slog.v(TAG, "Preferred activity bookkeeping changed; writing restrictions");
+                        }
                         mSettings.writePackageRestrictionsLPr(userId);
-                        return ri;
                     }
                 }
             }
-            mSettings.writePackageRestrictionsLPr(userId);
         }
         if (DEBUG_PREFERRED || debug) Slog.v(TAG, "No preferred activity to return");
         return null;
@@ -3204,26 +3199,6 @@
                 if (matches.get(i).getTargetUserId() == targetUserId) return true;
             }
         }
-
-        ArrayList<String> packageNames = null;
-        SparseArray<ArrayList<String>> fromSource =
-                mSettings.mCrossProfilePackageInfo.get(sourceUserId);
-        if (fromSource != null) {
-            packageNames = fromSource.get(targetUserId);
-        }
-        if (packageNames != null && packageNames.contains(intent.getPackage())) {
-            return true;
-        }
-        // We need the package name, so we try to resolve with the loosest flags possible
-        List<ResolveInfo> resolveInfos = mActivities.queryIntent(
-                intent, resolvedType, PackageManager.GET_UNINSTALLED_PACKAGES, targetUserId);
-        int count = resolveInfos.size();
-        for (int i = 0; i < count; i++) {
-            ResolveInfo resolveInfo = resolveInfos.get(i);
-            if (packageNames.contains(resolveInfo.activityInfo.packageName)) {
-                return true;
-            }
-        }
         return false;
     }
 
@@ -3240,7 +3215,7 @@
     public List<ResolveInfo> queryIntentActivities(Intent intent,
             String resolvedType, int flags, int userId) {
         if (!sUserManager.exists(userId)) return Collections.emptyList();
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, "query intent activities");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, false, false, "query intent activities");
         ComponentName comp = intent.getComponent();
         if (comp == null) {
             if (intent.getSelector() != null) {
@@ -3263,51 +3238,32 @@
         // reader
         synchronized (mPackages) {
             final String pkgName = intent.getPackage();
-            boolean queryCrossProfile = (flags & PackageManager.NO_CROSS_PROFILE) == 0;
             if (pkgName == null) {
-                ResolveInfo resolveInfo = null;
-                if (queryCrossProfile) {
-                    // Check if the intent needs to be forwarded to another user for this package
-                    ArrayList<ResolveInfo> crossProfileResult =
-                            queryIntentActivitiesCrossProfilePackage(
-                                    intent, resolvedType, flags, userId);
-                    if (!crossProfileResult.isEmpty()) {
-                        // Skip the current profile
-                        return crossProfileResult;
-                    }
-                    List<CrossProfileIntentFilter> matchingFilters =
-                            getMatchingCrossProfileIntentFilters(intent, resolvedType, userId);
-                    // Check for results that need to skip the current profile.
-                    resolveInfo = querySkipCurrentProfileIntents(matchingFilters, intent,
-                            resolvedType, flags, userId);
-                    if (resolveInfo != null) {
-                        List<ResolveInfo> result = new ArrayList<ResolveInfo>(1);
-                        result.add(resolveInfo);
-                        return result;
-                    }
-                    // Check for cross profile results.
-                    resolveInfo = queryCrossProfileIntents(
-                            matchingFilters, intent, resolvedType, flags, userId);
+                List<CrossProfileIntentFilter> matchingFilters =
+                        getMatchingCrossProfileIntentFilters(intent, resolvedType, userId);
+                // Check for results that need to skip the current profile.
+                ResolveInfo resolveInfo  = querySkipCurrentProfileIntents(matchingFilters, intent,
+                        resolvedType, flags, userId);
+                if (resolveInfo != null) {
+                    List<ResolveInfo> result = new ArrayList<ResolveInfo>(1);
+                    result.add(resolveInfo);
+                    return result;
                 }
+                // Check for cross profile results.
+                resolveInfo = queryCrossProfileIntents(
+                        matchingFilters, intent, resolvedType, flags, userId);
+
                 // Check for results in the current profile.
                 List<ResolveInfo> result = mActivities.queryIntent(
                         intent, resolvedType, flags, userId);
                 if (resolveInfo != null) {
                     result.add(resolveInfo);
+                    Collections.sort(result, mResolvePrioritySorter);
                 }
                 return result;
             }
             final PackageParser.Package pkg = mPackages.get(pkgName);
             if (pkg != null) {
-                if (queryCrossProfile) {
-                    ArrayList<ResolveInfo> crossProfileResult =
-                            queryIntentActivitiesCrossProfilePackage(
-                                    intent, resolvedType, flags, userId, pkg, pkgName);
-                    if (!crossProfileResult.isEmpty()) {
-                        // Skip the current profile
-                        return crossProfileResult;
-                    }
-                }
                 return mActivities.queryIntentForPackage(intent, resolvedType, flags,
                         pkg.activities, userId);
             }
@@ -3336,56 +3292,6 @@
         return null;
     }
 
-    private ArrayList<ResolveInfo> queryIntentActivitiesCrossProfilePackage(
-            Intent intent, String resolvedType, int flags, int userId) {
-        ArrayList<ResolveInfo> matchingResolveInfos = new ArrayList<ResolveInfo>();
-        SparseArray<ArrayList<String>> sourceForwardingInfo =
-                mSettings.mCrossProfilePackageInfo.get(userId);
-        if (sourceForwardingInfo != null) {
-            int NI = sourceForwardingInfo.size();
-            for (int i = 0; i < NI; i++) {
-                int targetUserId = sourceForwardingInfo.keyAt(i);
-                ArrayList<String> packageNames = sourceForwardingInfo.valueAt(i);
-                List<ResolveInfo> resolveInfos = mActivities.queryIntent(
-                        intent, resolvedType, flags, targetUserId);
-                int NJ = resolveInfos.size();
-                for (int j = 0; j < NJ; j++) {
-                    ResolveInfo resolveInfo = resolveInfos.get(j);
-                    if (packageNames.contains(resolveInfo.activityInfo.packageName)) {
-                        matchingResolveInfos.add(createForwardingResolveInfo(
-                                resolveInfo.filter, userId, targetUserId));
-                    }
-                }
-            }
-        }
-        return matchingResolveInfos;
-    }
-
-    private ArrayList<ResolveInfo> queryIntentActivitiesCrossProfilePackage(
-            Intent intent, String resolvedType, int flags, int userId, PackageParser.Package pkg,
-            String packageName) {
-        ArrayList<ResolveInfo> matchingResolveInfos = new ArrayList<ResolveInfo>();
-        SparseArray<ArrayList<String>> sourceForwardingInfo =
-                mSettings.mCrossProfilePackageInfo.get(userId);
-        if (sourceForwardingInfo != null) {
-            int NI = sourceForwardingInfo.size();
-            for (int i = 0; i < NI; i++) {
-                int targetUserId = sourceForwardingInfo.keyAt(i);
-                if (sourceForwardingInfo.valueAt(i).contains(packageName)) {
-                    List<ResolveInfo> resolveInfos = mActivities.queryIntentForPackage(
-                            intent, resolvedType, flags, pkg.activities, targetUserId);
-                    int NJ = resolveInfos.size();
-                    for (int j = 0; j < NJ; j++) {
-                        ResolveInfo resolveInfo = resolveInfos.get(j);
-                        matchingResolveInfos.add(createForwardingResolveInfo(
-                                resolveInfo.filter, userId, targetUserId));
-                    }
-                }
-            }
-        }
-        return matchingResolveInfos;
-    }
-
     // Return matching ResolveInfo if any for skip current profile intent filters.
     private ResolveInfo queryCrossProfileIntents(
             List<CrossProfileIntentFilter> matchingFilters, Intent intent, String resolvedType,
@@ -3456,7 +3362,7 @@
             String resolvedType, int flags, int userId) {
         if (!sUserManager.exists(userId)) return Collections.emptyList();
         enforceCrossUserPermission(Binder.getCallingUid(), userId, false,
-                "query intent activity options");
+                false, "query intent activity options");
         final String resultsAction = intent.getAction();
 
         List<ResolveInfo> results = queryIntentActivities(intent, resolvedType, flags
@@ -3752,7 +3658,7 @@
     public ParceledListSlice<PackageInfo> getInstalledPackages(int flags, int userId) {
         final boolean listUninstalled = (flags & PackageManager.GET_UNINSTALLED_PACKAGES) != 0;
 
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "get installed packages");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false, "get installed packages");
 
         // writer
         synchronized (mPackages) {
@@ -3805,21 +3711,25 @@
         } else {
             pi = generatePackageInfoFromSettingsLPw(ps.name, flags, userId);
         }
-        if ((flags&PackageManager.GET_PERMISSIONS) == 0) {
-            if (numMatch == permissions.length) {
-                pi.requestedPermissions = permissions;
-            } else {
-                pi.requestedPermissions = new String[numMatch];
-                numMatch = 0;
-                for (int i=0; i<permissions.length; i++) {
-                    if (tmp[i]) {
-                        pi.requestedPermissions[numMatch] = permissions[i];
-                        numMatch++;
+        // The above might return null in cases of uninstalled apps or install-state
+        // skew across users/profiles.
+        if (pi != null) {
+            if ((flags&PackageManager.GET_PERMISSIONS) == 0) {
+                if (numMatch == permissions.length) {
+                    pi.requestedPermissions = permissions;
+                } else {
+                    pi.requestedPermissions = new String[numMatch];
+                    numMatch = 0;
+                    for (int i=0; i<permissions.length; i++) {
+                        if (tmp[i]) {
+                            pi.requestedPermissions[numMatch] = permissions[i];
+                            numMatch++;
+                        }
                     }
                 }
             }
+            list.add(pi);
         }
-        list.add(pi);
     }
 
     @Override
@@ -4089,7 +3999,7 @@
         return true;
     }
 
-    private void scanDirLI(File dir, int flags, int scanMode, long currentTime) {
+    private void scanDirLI(File dir, int parseFlags, int scanFlags, long currentTime) {
         final File[] files = dir.listFiles();
         if (ArrayUtils.isEmpty(files)) {
             Log.d(TAG, "No files in app dir " + dir);
@@ -4097,27 +4007,30 @@
         }
 
         if (DEBUG_PACKAGE_SCANNING) {
-            Log.d(TAG, "Scanning app dir " + dir + " scanMode=" + scanMode
-                    + " flags=0x" + Integer.toHexString(flags));
+            Log.d(TAG, "Scanning app dir " + dir + " scanFlags=" + scanFlags
+                    + " flags=0x" + Integer.toHexString(parseFlags));
         }
 
         for (File file : files) {
             final boolean isPackage = (isApkFile(file) || file.isDirectory())
-                    && !PackageInstallerService.isStageFile(file);
+                    && !PackageInstallerService.isStageName(file.getName());
             if (!isPackage) {
-                // Ignore entries which are not apk's
+                // Ignore entries which are not packages
                 continue;
             }
             try {
-                scanPackageLI(file, flags | PackageParser.PARSE_MUST_BE_APK, scanMode, currentTime, null);
+                scanPackageLI(file, parseFlags | PackageParser.PARSE_MUST_BE_APK,
+                        scanFlags, currentTime, null);
             } catch (PackageManagerException e) {
                 Slog.w(TAG, "Failed to parse " + file + ": " + e.getMessage());
 
-                // Don't mess around with apps in system partition.
-                if ((flags & PackageParser.PARSE_IS_SYSTEM) == 0 &&
+                // Delete invalid userdata apps
+                if ((parseFlags & PackageParser.PARSE_IS_SYSTEM) == 0 &&
                         e.error == PackageManager.INSTALL_FAILED_INVALID_APK) {
-                    // Delete the apk
-                    Slog.w(TAG, "Cleaning up failed install of " + file);
+                    Slog.w(TAG, "Deleting invalid package at " + file);
+                    if (file.isDirectory()) {
+                        FileUtils.deleteContents(file);
+                    }
                     file.delete();
                 }
             }
@@ -4180,8 +4093,7 @@
             pp.collectCertificates(pkg, parseFlags);
             pp.collectManifestDigest(pkg);
         } catch (PackageParserException e) {
-            throw new PackageManagerException(e.error, "Failed to collect certificates for "
-                    + pkg.packageName + ": " + e.getMessage());
+            throw PackageManagerException.from(e);
         }
     }
 
@@ -4189,7 +4101,7 @@
      *  Scan a package and return the newly parsed package.
      *  Returns null in case of errors and the error code is stored in mLastScanError
      */
-    private PackageParser.Package scanPackageLI(File scanFile, int parseFlags, int scanMode,
+    private PackageParser.Package scanPackageLI(File scanFile, int parseFlags, int scanFlags,
             long currentTime, UserHandle user) throws PackageManagerException {
         if (DEBUG_INSTALL) Slog.d(TAG, "Parsing: " + scanFile);
         parseFlags |= mDefParseFlags;
@@ -4198,7 +4110,7 @@
         pp.setOnlyCoreApps(mOnlyCore);
         pp.setDisplayMetrics(mMetrics);
 
-        if ((scanMode & SCAN_TRUSTED_OVERLAY) != 0) {
+        if ((scanFlags & SCAN_TRUSTED_OVERLAY) != 0) {
             parseFlags |= PackageParser.PARSE_TRUSTED_OVERLAY;
         }
 
@@ -4206,8 +4118,7 @@
         try {
             pkg = pp.parsePackage(scanFile, parseFlags);
         } catch (PackageParserException e) {
-            throw new PackageManagerException(e.error,
-                    "Failed to scan " + scanFile + ": " + e.getMessage());
+            throw PackageManagerException.from(e);
         }
 
         PackageSetting ps = null;
@@ -4279,7 +4190,7 @@
 
                     InstallArgs args = createInstallArgsForExisting(packageFlagsToInstallFlags(ps),
                             ps.codePathString, ps.resourcePathString, ps.legacyNativeLibraryPathString,
-                            getAppDexInstructionSets(ps), isMultiArch(ps));
+                            getAppDexInstructionSets(ps));
                     synchronized (mInstallLock) {
                         args.cleanUpResourcesLI();
                     }
@@ -4342,7 +4253,7 @@
                             + " better than installed " + ps.versionCode);
                     InstallArgs args = createInstallArgsForExisting(packageFlagsToInstallFlags(ps),
                             ps.codePathString, ps.resourcePathString, ps.legacyNativeLibraryPathString,
-                            getAppDexInstructionSets(ps), isMultiArch(ps));
+                            getAppDexInstructionSets(ps));
                     synchronized (mInstallLock) {
                         args.cleanUpResourcesLI();
                     }
@@ -4385,7 +4296,7 @@
         pkg.applicationInfo.setSplitResourcePaths(pkg.splitCodePaths);
 
         // Note that we invoke the following method only if we are about to unpack an application
-        PackageParser.Package scannedPkg = scanPackageLI(pkg, parseFlags, scanMode
+        PackageParser.Package scannedPkg = scanPackageLI(pkg, parseFlags, scanFlags
                 | SCAN_UPDATE_SIGNATURE, currentTime, user);
 
         /*
@@ -4400,7 +4311,7 @@
                  * grantPermissions will assume the package update is trying to
                  * expand its permissions.
                  */
-                grantPermissionsLPw(pkg, true);
+                grantPermissionsLPw(pkg, true, pkg.packageName);
                 mSettings.disableSystemPackageLPw(pkg.packageName);
             }
         }
@@ -4478,13 +4389,12 @@
         if (pkgs != null) {
             // Filter out packages that aren't recently used.
             //
-            // The exception is first boot of a non-eng device, which
+            // The exception is first boot of a non-eng device (aka !mLazyDexOpt), which
             // should do a full dexopt.
-            boolean eng = "eng".equals(SystemProperties.get("ro.build.type"));
-            if (eng || (!isFirstBoot() && mPackageUsage.isHistoricalPackageUsageAvailable())) {
+            if (mLazyDexOpt || (!isFirstBoot() && mPackageUsage.isHistoricalPackageUsageAvailable())) {
                 // TODO: add a property to control this?
                 long dexOptLRUThresholdInMinutes;
-                if (eng) {
+                if (mLazyDexOpt) {
                     dexOptLRUThresholdInMinutes = 30; // only last 30 minutes of apps for eng builds.
                 } else {
                     dexOptLRUThresholdInMinutes = 7 * 24 * 60; // apps used in the 7 days for users.
@@ -4538,7 +4448,7 @@
 
     @Override
     public boolean performDexOptIfNeeded(String packageName, String instructionSet) {
-        return performDexOpt(packageName, instructionSet, true);
+        return performDexOpt(packageName, instructionSet, false);
     }
 
     private static String getPrimaryInstructionSet(ApplicationInfo info) {
@@ -4549,7 +4459,13 @@
         return VMRuntime.getInstructionSet(info.primaryCpuAbi);
     }
 
-    public boolean performDexOpt(String packageName, String instructionSet, boolean updateUsage) {
+    public boolean performDexOpt(String packageName, String instructionSet, boolean backgroundDexopt) {
+        boolean dexopt = mLazyDexOpt || backgroundDexopt;
+        boolean updateUsage = !backgroundDexopt;  // Don't update usage if this is just a backgroundDexopt
+        if (!dexopt && !updateUsage) {
+            // We aren't going to dexopt or update usage, so bail early.
+            return false;
+        }
         PackageParser.Package p;
         final String targetInstructionSet;
         synchronized (mPackages) {
@@ -4561,6 +4477,10 @@
                 p.mLastPackageUsageTimeInMills = System.currentTimeMillis();
             }
             mPackageUsage.write(false);
+            if (!dexopt) {
+                // We aren't going to dexopt, so bail early.
+                return false;
+            }
 
             targetInstructionSet = instructionSet != null ? instructionSet :
                     getPrimaryInstructionSet(p.applicationInfo);
@@ -4643,6 +4563,8 @@
             return DEX_OPT_SKIPPED;
         }
 
+        final boolean vmSafeMode = (pkg.applicationInfo.flags & ApplicationInfo.FLAG_VM_SAFE_MODE) != 0;
+
         final List<String> paths = pkg.getAllCodePathsExcludingResourceOnly();
         boolean performedDexOpt = false;
         // There are three basic cases here:
@@ -4666,10 +4588,11 @@
                             pkg.packageName, dexCodeInstructionSet, defer);
                     if (forceDex || (!defer && isDexOptNeeded == DexFile.DEXOPT_NEEDED)) {
                         Log.i(TAG, "Running dexopt on: " + path + " pkg="
-                                + pkg.applicationInfo.packageName + " isa=" + dexCodeInstructionSet);
+                                + pkg.applicationInfo.packageName + " isa=" + dexCodeInstructionSet
+                                + " vmSafeMode=" + vmSafeMode);
                         final int sharedGid = UserHandle.getSharedAppGid(pkg.applicationInfo.uid);
                         final int ret = mInstaller.dexopt(path, sharedGid, !isForwardLocked(pkg),
-                                pkg.packageName, dexCodeInstructionSet);
+                                pkg.packageName, dexCodeInstructionSet, vmSafeMode);
 
                         if (ret < 0) {
                             // Don't bother running dexopt again if we failed, it will probably
@@ -5020,7 +4943,7 @@
     private static String deriveAbiOverride(String abiOverride, PackageSetting settings) {
         String cpuAbiOverride = null;
 
-        if (CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
+        if (NativeLibraryHelper.CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
             cpuAbiOverride = null;
         } else if (abiOverride != null) {
             cpuAbiOverride = abiOverride;
@@ -5032,8 +4955,22 @@
     }
 
     private PackageParser.Package scanPackageLI(PackageParser.Package pkg, int parseFlags,
-            int scanMode, long currentTime, UserHandle user)
-            throws PackageManagerException {
+            int scanFlags, long currentTime, UserHandle user) throws PackageManagerException {
+        boolean success = false;
+        try {
+            final PackageParser.Package res = scanPackageDirtyLI(pkg, parseFlags, scanFlags,
+                    currentTime, user);
+            success = true;
+            return res;
+        } finally {
+            if (!success && (scanFlags & SCAN_DELETE_DATA_ON_FAILURES) != 0) {
+                removeDataDirsLI(pkg.packageName);
+            }
+        }
+    }
+
+    private PackageParser.Package scanPackageDirtyLI(PackageParser.Package pkg, int parseFlags,
+            int scanFlags, long currentTime, UserHandle user) throws PackageManagerException {
         final File scanFile = new File(pkg.codePath);
         if (pkg.applicationInfo.getCodePath() == null ||
                 pkg.applicationInfo.getResourcePath() == null) {
@@ -5287,7 +5224,7 @@
             // that conflict with existing packages.  Only do this if the
             // package isn't already installed, since we don't want to break
             // things that are installed.
-            if ((scanMode&SCAN_NEW_INSTALL) != 0) {
+            if ((scanFlags & SCAN_NEW_INSTALL) != 0) {
                 final int N = pkg.providers.size();
                 int i;
                 for (i=0; i<N; i++) {
@@ -5331,7 +5268,7 @@
         final String pkgName = pkg.packageName;
         
         final long scanFileTime = scanFile.lastModified();
-        final boolean forceDex = (scanMode&SCAN_FORCE_DEX) != 0;
+        final boolean forceDex = (scanFlags & SCAN_FORCE_DEX) != 0;
         pkg.applicationInfo.processName = fixProcessName(
                 pkg.applicationInfo.packageName,
                 pkg.applicationInfo.processName,
@@ -5340,7 +5277,8 @@
         File dataPath;
         if (mPlatformPackage == pkg) {
             // The system package is special.
-            dataPath = new File (Environment.getDataDirectory(), "system");
+            dataPath = new File(Environment.getDataDirectory(), "system");
+
             pkg.applicationInfo.dataDir = dataPath.getPath();
 
         } else {
@@ -5348,7 +5286,6 @@
             dataPath = getDataPathForPackage(pkg.packageName, 0);
 
             boolean uidError = false;
-
             if (dataPath.exists()) {
                 int currentUid = 0;
                 try {
@@ -5377,7 +5314,7 @@
                         }
                     }
                     if (!recovered && ((parseFlags&PackageParser.PARSE_IS_SYSTEM) != 0
-                            || (scanMode&SCAN_BOOTING) != 0)) {
+                            || (scanFlags&SCAN_BOOTING) != 0)) {
                         // If this is a system app, we can at least delete its
                         // current data so the application will still work.
                         int ret = removeDataDirsLI(pkgName);
@@ -5524,7 +5461,8 @@
                     // Warn if we've set an abiOverride for multi-lib packages..
                     // By definition, we need to copy both 32 and 64 bit libraries for
                     // such packages.
-                    if (pkg.cpuAbiOverride != null && !CLEAR_ABI_OVERRIDE.equals(pkg.cpuAbiOverride)) {
+                    if (pkg.cpuAbiOverride != null
+                            && !NativeLibraryHelper.CLEAR_ABI_OVERRIDE.equals(pkg.cpuAbiOverride)) {
                         Slog.w(TAG, "Ignoring abiOverride for multi arch application.");
                     }
 
@@ -5534,8 +5472,9 @@
                         if (isAsec) {
                             abi32 = NativeLibraryHelper.findSupportedAbi(handle, Build.SUPPORTED_32_BIT_ABIS);
                         } else {
-                            abi32 = copyNativeLibrariesForInternalApp(handle,
-                                    nativeLibraryRoot, Build.SUPPORTED_32_BIT_ABIS, useIsaSpecificSubdirs);
+                            abi32 = NativeLibraryHelper.copyNativeBinariesForSupportedAbi(handle,
+                                    nativeLibraryRoot, Build.SUPPORTED_32_BIT_ABIS,
+                                    useIsaSpecificSubdirs);
                         }
                     }
 
@@ -5546,8 +5485,9 @@
                         if (isAsec) {
                             abi64 = NativeLibraryHelper.findSupportedAbi(handle, Build.SUPPORTED_64_BIT_ABIS);
                         } else {
-                            abi64 = copyNativeLibrariesForInternalApp(handle,
-                                    nativeLibraryRoot, Build.SUPPORTED_64_BIT_ABIS, useIsaSpecificSubdirs);
+                            abi64 = NativeLibraryHelper.copyNativeBinariesForSupportedAbi(handle,
+                                    nativeLibraryRoot, Build.SUPPORTED_64_BIT_ABIS,
+                                    useIsaSpecificSubdirs);
                         }
                     }
 
@@ -5585,8 +5525,8 @@
                     if (isAsec) {
                         copyRet = NativeLibraryHelper.findSupportedAbi(handle, abiList);
                     } else {
-                        copyRet = copyNativeLibrariesForInternalApp(handle, nativeLibraryRoot, abiList,
-                                useIsaSpecificSubdirs);
+                        copyRet = NativeLibraryHelper.copyNativeBinariesForSupportedAbi(handle,
+                                nativeLibraryRoot, abiList, useIsaSpecificSubdirs);
                     }
 
                     if (copyRet < 0 && copyRet != PackageManager.NO_NATIVE_LIBRARIES) {
@@ -5661,7 +5601,7 @@
                     " secondary=" + pkg.applicationInfo.secondaryCpuAbi);
         }
 
-        if ((scanMode&SCAN_BOOTING) == 0 && pkgSetting.sharedUser != null) {
+        if ((scanFlags&SCAN_BOOTING) == 0 && pkgSetting.sharedUser != null) {
             // We don't do this here during boot because we can do it all
             // at once after scanning all existing packages.
             //
@@ -5669,16 +5609,12 @@
             // we can avoid redundant dexopts, and also to make sure we've got the
             // code and package path correct.
             adjustCpuAbisForSharedUserLPw(pkgSetting.sharedUser.packages,
-                    pkg, forceDex, (scanMode & SCAN_DEFER_DEX) != 0);
+                    pkg, forceDex, (scanFlags & SCAN_DEFER_DEX) != 0);
         }
 
-        if ((scanMode&SCAN_NO_DEX) == 0) {
-            if (performDexOptLI(pkg, null /* instruction sets */, forceDex, (scanMode&SCAN_DEFER_DEX) != 0, false)
-                    == DEX_OPT_FAILED) {
-                if ((scanMode & SCAN_DELETE_DATA_ON_FAILURES) != 0) {
-                    removeDataDirsLI(pkg.packageName);
-                }
-
+        if ((scanFlags & SCAN_NO_DEX) == 0) {
+            if (performDexOptLI(pkg, null /* instruction sets */, forceDex,
+                    (scanFlags & SCAN_DEFER_DEX) != 0, false) == DEX_OPT_FAILED) {
                 throw new PackageManagerException(INSTALL_FAILED_DEXOPT, "scanPackageLI");
             }
         }
@@ -5735,7 +5671,7 @@
                                     + name + " that is not declared on system image; skipping");
                         }
                     }
-                    if ((scanMode&SCAN_BOOTING) == 0) {
+                    if ((scanFlags&SCAN_BOOTING) == 0) {
                         // If we are not booting, we need to update any applications
                         // that are clients of our shared library.  If we are booting,
                         // this will all be done once the scan is complete.
@@ -5749,16 +5685,11 @@
         // if these fail, we should abort the install since installing the library will
         // result in some apps being broken.
         if (clientLibPkgs != null) {
-            if ((scanMode&SCAN_NO_DEX) == 0) {
-                for (int i=0; i<clientLibPkgs.size(); i++) {
+            if ((scanFlags & SCAN_NO_DEX) == 0) {
+                for (int i = 0; i < clientLibPkgs.size(); i++) {
                     PackageParser.Package clientPkg = clientLibPkgs.get(i);
-                    if (performDexOptLI(clientPkg, null /* instruction sets */,
-                            forceDex, (scanMode&SCAN_DEFER_DEX) != 0, false)
-                            == DEX_OPT_FAILED) {
-                        if ((scanMode & SCAN_DELETE_DATA_ON_FAILURES) != 0) {
-                            removeDataDirsLI(pkg.packageName);
-                        }
-
+                    if (performDexOptLI(clientPkg, null /* instruction sets */, forceDex,
+                            (scanFlags & SCAN_DEFER_DEX) != 0, false) == DEX_OPT_FAILED) {
                         throw new PackageManagerException(INSTALL_FAILED_DEXOPT,
                                 "scanPackageLI failed to dexopt clientLibPkgs");
                     }
@@ -5769,21 +5700,7 @@
         // Request the ActivityManager to kill the process(only for existing packages)
         // so that we do not end up in a confused state while the user is still using the older
         // version of the application while the new one gets installed.
-        if ((parseFlags & PackageManager.INSTALL_REPLACE_EXISTING) != 0) {
-            // If the package lives in an asec, tell everyone that the container is going
-            // away so they can clean up any references to its resources (which would prevent
-            // vold from being able to unmount the asec)
-            if (isForwardLocked(pkg) || isExternal(pkg)) {
-                if (DEBUG_INSTALL) {
-                    Slog.i(TAG, "upgrading pkg " + pkg + " is ASEC-hosted -> UNAVAILABLE");
-                }
-                final int[] uidArray = new int[] { pkg.applicationInfo.uid };
-                final ArrayList<String> pkgList = new ArrayList<String>(1);
-                pkgList.add(pkg.applicationInfo.packageName);
-                sendResourcesChangedBroadcast(false, true, pkgList, uidArray, null);
-            }
-
-            // Post the request that it be killed now that the going-away broadcast is en route
+        if ((scanFlags & SCAN_REPLACING) != 0) {
             killApplication(pkg.applicationInfo.packageName,
                         pkg.applicationInfo.uid, "update pkg");
         }
@@ -5799,10 +5716,8 @@
 
         // writer
         synchronized (mPackages) {
-            // We don't expect installation to fail beyond this point,
-            if ((scanMode&SCAN_MONITOR) != 0) {
-                mAppDirs.put(pkg.codePath, pkg);
-            }
+            // We don't expect installation to fail beyond this point
+
             // Add the new setting to mSettings
             mSettings.insertPackageSettingLPw(pkgSetting, pkg);
             // Add the new setting to mPackages
@@ -5820,7 +5735,7 @@
             if (currentTime != 0) {
                 if (pkgSetting.firstInstallTime == 0) {
                     pkgSetting.firstInstallTime = pkgSetting.lastUpdateTime = currentTime;
-                } else if ((scanMode&SCAN_UPDATE_TIME) != 0) {
+                } else if ((scanFlags&SCAN_UPDATE_TIME) != 0) {
                     pkgSetting.lastUpdateTime = currentTime;
                 }
             } else if (pkgSetting.firstInstallTime == 0) {
@@ -6469,58 +6384,6 @@
         }
     }
 
-    private static void createNativeLibrarySubdir(File path) throws IOException {
-        if (!path.isDirectory()) {
-            path.delete();
-
-            if (!path.mkdir()) {
-                throw new IOException("Cannot create " + path.getPath());
-            }
-
-            try {
-                Os.chmod(path.getPath(), S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH);
-            } catch (ErrnoException e) {
-                throw new IOException("Cannot chmod native library directory "
-                        + path.getPath(), e);
-            }
-        } else if (!SELinux.restorecon(path)) {
-            throw new IOException("Cannot set SELinux context for " + path.getPath());
-        }
-    }
-
-    private static int copyNativeLibrariesForInternalApp(NativeLibraryHelper.Handle handle,
-            final File nativeLibraryRoot, String[] abiList, boolean useIsaSubdir) throws IOException {
-        createNativeLibrarySubdir(nativeLibraryRoot);
-
-        /*
-         * If this is an internal application or our nativeLibraryPath points to
-         * the app-lib directory, unpack the libraries if necessary.
-         */
-        int abi = NativeLibraryHelper.findSupportedAbi(handle, abiList);
-        if (abi >= 0) {
-            /*
-             * If we have a matching instruction set, construct a subdir under the native
-             * library root that corresponds to this instruction set.
-             */
-            final String instructionSet = VMRuntime.getInstructionSet(abiList[abi]);
-            final File subDir;
-            if (useIsaSubdir) {
-                final File isaSubdir = new File(nativeLibraryRoot, instructionSet);
-                createNativeLibrarySubdir(isaSubdir);
-                subDir = isaSubdir;
-            } else {
-                subDir = nativeLibraryRoot;
-            }
-
-            int copyRet = NativeLibraryHelper.copyNativeBinariesIfNeededLI(handle, subDir, abiList[abi]);
-            if (copyRet != PackageManager.INSTALL_SUCCEEDED) {
-                return copyRet;
-            }
-        }
-
-        return abi;
-    }
-
     private void killApplication(String pkgName, int appId, String reason) {
         // Request the ActivityManager to kill the process(only for existing packages)
         // so that we do not end up in a confused state while the user is still using the older
@@ -6543,10 +6406,6 @@
         // writer
         synchronized (mPackages) {
             mPackages.remove(ps.name);
-            if (ps.codePathString != null) {
-                mAppDirs.remove(ps.codePathString);
-            }
-
             final PackageParser.Package pkg = ps.pkg;
             if (pkg != null) {
                 cleanPackageDataStructuresLILPw(pkg, chatty);
@@ -6563,9 +6422,6 @@
         // writer
         synchronized (mPackages) {
             mPackages.remove(pkg.applicationInfo.packageName);
-            if (pkg.codePath != null) {
-                mAppDirs.remove(pkg.codePath);
-            }
             cleanPackageDataStructuresLILPw(pkg, chatty);
         }
     }
@@ -6840,17 +6696,19 @@
         if ((flags&UPDATE_PERMISSIONS_ALL) != 0) {
             for (PackageParser.Package pkg : mPackages.values()) {
                 if (pkg != pkgInfo) {
-                    grantPermissionsLPw(pkg, (flags&UPDATE_PERMISSIONS_REPLACE_ALL) != 0);
+                    grantPermissionsLPw(pkg, (flags&UPDATE_PERMISSIONS_REPLACE_ALL) != 0,
+                            changingPkg);
                 }
             }
         }
         
         if (pkgInfo != null) {
-            grantPermissionsLPw(pkgInfo, (flags&UPDATE_PERMISSIONS_REPLACE_PKG) != 0);
+            grantPermissionsLPw(pkgInfo, (flags&UPDATE_PERMISSIONS_REPLACE_PKG) != 0, changingPkg);
         }
     }
 
-    private void grantPermissionsLPw(PackageParser.Package pkg, boolean replace) {
+    private void grantPermissionsLPw(PackageParser.Package pkg, boolean replace,
+            String packageOfInterest) {
         final PackageSetting ps = (PackageSetting) pkg.mExtras;
         if (ps == null) {
             return;
@@ -6884,8 +6742,10 @@
             }
 
             if (bp == null || bp.packageSetting == null) {
-                Slog.w(TAG, "Unknown permission " + name
-                        + " in package " + pkg.packageName);
+                if (packageOfInterest == null || packageOfInterest.equals(pkg.packageName)) {
+                    Slog.w(TAG, "Unknown permission " + name
+                            + " in package " + pkg.packageName);
+                }
                 continue;
             }
 
@@ -6950,9 +6810,11 @@
                         gp.gids = appendInts(gp.gids, bp.gids);
                     }
                 } else {
-                    Slog.w(TAG, "Not granting permission " + perm
-                            + " to package " + pkg.packageName
-                            + " because it was previously installed without");
+                    if (packageOfInterest == null || packageOfInterest.equals(pkg.packageName)) {
+                        Slog.w(TAG, "Not granting permission " + perm
+                                + " to package " + pkg.packageName
+                                + " because it was previously installed without");
+                    }
                 }
             } else {
                 if (gp.grantedPermissions.remove(perm)) {
@@ -6966,11 +6828,13 @@
                 } else if ((bp.protectionLevel&PermissionInfo.PROTECTION_FLAG_APPOP) == 0) {
                     // Don't print warning for app op permissions, since it is fine for them
                     // not to be granted, there is a UI for the user to decide.
-                    Slog.w(TAG, "Not granting permission " + perm
-                            + " to package " + pkg.packageName
-                            + " (protectionLevel=" + bp.protectionLevel
-                            + " flags=0x" + Integer.toHexString(pkg.applicationInfo.flags)
-                            + ")");
+                    if (packageOfInterest == null || packageOfInterest.equals(pkg.packageName)) {
+                        Slog.w(TAG, "Not granting permission " + perm
+                                + " to package " + pkg.packageName
+                                + " (protectionLevel=" + bp.protectionLevel
+                                + " flags=0x" + Integer.toHexString(pkg.applicationInfo.flags)
+                                + ")");
+                    }
                 }
             }
         }
@@ -7771,16 +7635,18 @@
     }
 
     void schedulePackageCleaning(String packageName, int userId, boolean andCode) {
-        if (false) {
-            RuntimeException here = new RuntimeException("here");
-            here.fillInStackTrace();
-            Slog.d(TAG, "Schedule cleaning " + packageName + " user=" + userId
-                    + " andCode=" + andCode, here);
+        final Message msg = mHandler.obtainMessage(START_CLEANING_PACKAGE,
+                userId, andCode ? 1 : 0, packageName);
+        if (mSystemReady) {
+            msg.sendToTarget();
+        } else {
+            if (mPostSystemReadyMessages == null) {
+                mPostSystemReadyMessages = new ArrayList<>();
+            }
+            mPostSystemReadyMessages.add(msg);
         }
-        mHandler.sendMessage(mHandler.obtainMessage(START_CLEANING_PACKAGE,
-                userId, andCode ? 1 : 0, packageName));
     }
-    
+
     void startCleaningPackages() {
         // reader
         synchronized (mPackages) {
@@ -7803,15 +7669,23 @@
     }
 
     @Override
-    public void installPackage(String originPath, IPackageInstallObserver2 observer, int flags,
-            String installerPackageName, VerificationParams verificationParams,
+    public void installPackage(String originPath, IPackageInstallObserver2 observer,
+            int installFlags, String installerPackageName, VerificationParams verificationParams,
             String packageAbiOverride) {
-        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.INSTALL_PACKAGES,
-                null);
+        installPackageAsUser(originPath, observer, installFlags, installerPackageName, verificationParams,
+                packageAbiOverride, UserHandle.getCallingUserId());
+    }
 
-        final File originFile = new File(originPath);
-        final int uid = Binder.getCallingUid();
-        if (isUserRestricted(UserHandle.getUserId(uid), UserManager.DISALLOW_INSTALL_APPS)) {
+    @Override
+    public void installPackageAsUser(String originPath, IPackageInstallObserver2 observer,
+            int installFlags, String installerPackageName, VerificationParams verificationParams,
+            String packageAbiOverride, int userId) {
+        mContext.enforceCallingOrSelfPermission(android.Manifest.permission.INSTALL_PACKAGES, null);
+
+        final int callingUid = Binder.getCallingUid();
+        enforceCrossUserPermission(callingUid, userId, true, true, "installPackageAsUser");
+
+        if (isUserRestricted(userId, UserManager.DISALLOW_INSTALL_APPS)) {
             try {
                 if (observer != null) {
                     observer.onPackageInstalled("", INSTALL_FAILED_USER_RESTRICTED, null, null);
@@ -7821,39 +7695,50 @@
             return;
         }
 
+        if ((callingUid == Process.SHELL_UID) || (callingUid == Process.ROOT_UID)) {
+            installFlags |= PackageManager.INSTALL_FROM_ADB;
+
+        } else {
+            // Caller holds INSTALL_PACKAGES permission, so we're less strict
+            // about installerPackageName.
+
+            installFlags &= ~PackageManager.INSTALL_FROM_ADB;
+            installFlags &= ~PackageManager.INSTALL_ALL_USERS;
+        }
+
         UserHandle user;
-        if ((flags&PackageManager.INSTALL_ALL_USERS) != 0) {
+        if ((installFlags & PackageManager.INSTALL_ALL_USERS) != 0) {
             user = UserHandle.ALL;
         } else {
-            user = new UserHandle(UserHandle.getUserId(uid));
+            user = new UserHandle(userId);
         }
 
-        final int filteredFlags;
-        if (uid == Process.SHELL_UID || uid == 0) {
-            if (DEBUG_INSTALL) {
-                Slog.v(TAG, "Install from ADB");
-            }
-            filteredFlags = flags | PackageManager.INSTALL_FROM_ADB;
-        } else {
-            filteredFlags = flags & ~PackageManager.INSTALL_FROM_ADB;
-        }
+        verificationParams.setInstallerUid(callingUid);
 
-        verificationParams.setInstallerUid(uid);
+        final File originFile = new File(originPath);
+        final OriginInfo origin = OriginInfo.fromUntrustedFile(originFile);
 
         final Message msg = mHandler.obtainMessage(INIT_COPY);
-        msg.obj = new InstallParams(originFile, false, observer, filteredFlags,
+        msg.obj = new InstallParams(origin, observer, installFlags,
                 installerPackageName, verificationParams, user, packageAbiOverride);
         mHandler.sendMessage(msg);
     }
 
-    void installStage(String packageName, File stageDir, IPackageInstallObserver2 observer,
-            PackageInstaller.SessionParams params, String installerPackageName, int installerUid,
-            UserHandle user) {
+    void installStage(String packageName, File stagedDir, String stagedCid,
+            IPackageInstallObserver2 observer, PackageInstaller.SessionParams params,
+            String installerPackageName, int installerUid, UserHandle user) {
         final VerificationParams verifParams = new VerificationParams(null, params.originatingUri,
                 params.referrerUri, installerUid, null);
 
+        final OriginInfo origin;
+        if (stagedDir != null) {
+            origin = OriginInfo.fromStagedFile(stagedDir);
+        } else {
+            origin = OriginInfo.fromStagedContainer(stagedCid);
+        }
+
         final Message msg = mHandler.obtainMessage(INIT_COPY);
-        msg.obj = new InstallParams(stageDir, true, observer, params.installFlags,
+        msg.obj = new InstallParams(origin, observer, params.installFlags,
                 installerPackageName, verifParams, user, params.abiOverride);
         mHandler.sendMessage(msg);
     }
@@ -7890,11 +7775,8 @@
         mContext.enforceCallingOrSelfPermission(android.Manifest.permission.MANAGE_USERS, null);
         PackageSetting pkgSetting;
         final int uid = Binder.getCallingUid();
-        if (UserHandle.getUserId(uid) != userId) {
-            mContext.enforceCallingOrSelfPermission(
-                    android.Manifest.permission.INTERACT_ACROSS_USERS_FULL,
-                    "setApplicationHiddenSetting for user " + userId);
-        }
+        enforceCrossUserPermission(uid, userId, true, true,
+                "setApplicationHiddenSetting for user " + userId);
 
         if (hidden && isPackageDeviceAdmin(packageName, userId)) {
             Slog.w(TAG, "Not hiding package " + packageName + ": has active device admin");
@@ -7953,7 +7835,7 @@
     public boolean getApplicationHiddenSettingAsUser(String packageName, int userId) {
         mContext.enforceCallingOrSelfPermission(android.Manifest.permission.MANAGE_USERS, null);
         enforceCrossUserPermission(Binder.getCallingUid(), userId, true,
-                "getApplicationHidden for user " + userId);
+                false, "getApplicationHidden for user " + userId);
         PackageSetting pkgSetting;
         long callingId = Binder.clearCallingIdentity();
         try {
@@ -7979,7 +7861,8 @@
                 null);
         PackageSetting pkgSetting;
         final int uid = Binder.getCallingUid();
-        enforceCrossUserPermission(uid, userId, true, "installExistingPackage for user " + userId);
+        enforceCrossUserPermission(uid, userId, true, true, "installExistingPackage for user "
+                + userId);
         if (isUserRestricted(userId, UserManager.DISALLOW_INSTALL_APPS)) {
             return PackageManager.INSTALL_FAILED_USER_RESTRICTED;
         }
@@ -8214,7 +8097,7 @@
      *
      * @return true if verification should be performed
      */
-    private boolean isVerificationEnabled(int userId, int flags) {
+    private boolean isVerificationEnabled(int userId, int installFlags) {
         if (!DEFAULT_VERIFY_ENABLE) {
             return false;
         }
@@ -8222,7 +8105,7 @@
         boolean ensureVerifyAppsEnabled = isUserRestricted(userId, UserManager.ENSURE_VERIFY_APPS);
 
         // Check if installing from ADB
-        if ((flags & PackageManager.INSTALL_FROM_ADB) != 0) {
+        if ((installFlags & PackageManager.INSTALL_FROM_ADB) != 0) {
             // Do not run verification in a test harness environment
             if (ActivityManager.isRunningInTestHarness()) {
                 return false;
@@ -8341,7 +8224,7 @@
                 if (res.returnCode == PackageManager.INSTALL_SUCCEEDED) {
                     args.doPreInstall(res.returnCode);
                     synchronized (mInstallLock) {
-                        installPackageLI(args, true, res);
+                        installPackageLI(args, res);
                     }
                     args.doPostInstall(res.returnCode, res.uid);
                 }
@@ -8546,37 +8429,87 @@
         }
     }
 
-    class InstallParams extends HandlerParams {
+    static class OriginInfo {
         /**
          * Location where install is coming from, before it has been
          * copied/renamed into place. This could be a single monolithic APK
          * file, or a cluster directory. This location may be untrusted.
          */
-        final File originFile;
+        final File file;
+        final String cid;
 
         /**
-         * Flag indicating that {@link #originFile} has already been staged,
-         * meaning downstream users don't need to defensively copy the contents.
+         * Flag indicating that {@link #file} or {@link #cid} has already been
+         * staged, meaning downstream users don't need to defensively copy the
+         * contents.
          */
-        boolean originStaged;
+        final boolean staged;
 
+        /**
+         * Flag indicating that {@link #file} or {@link #cid} is an already
+         * installed app that is being moved.
+         */
+        final boolean existing;
+
+        final String resolvedPath;
+        final File resolvedFile;
+
+        static OriginInfo fromNothing() {
+            return new OriginInfo(null, null, false, false);
+        }
+
+        static OriginInfo fromUntrustedFile(File file) {
+            return new OriginInfo(file, null, false, false);
+        }
+
+        static OriginInfo fromExistingFile(File file) {
+            return new OriginInfo(file, null, false, true);
+        }
+
+        static OriginInfo fromStagedFile(File file) {
+            return new OriginInfo(file, null, true, false);
+        }
+
+        static OriginInfo fromStagedContainer(String cid) {
+            return new OriginInfo(null, cid, true, false);
+        }
+
+        private OriginInfo(File file, String cid, boolean staged, boolean existing) {
+            this.file = file;
+            this.cid = cid;
+            this.staged = staged;
+            this.existing = existing;
+
+            if (cid != null) {
+                resolvedPath = PackageHelper.getSdDir(cid);
+                resolvedFile = new File(resolvedPath);
+            } else if (file != null) {
+                resolvedPath = file.getAbsolutePath();
+                resolvedFile = file;
+            } else {
+                resolvedPath = null;
+                resolvedFile = null;
+            }
+        }
+    }
+
+    class InstallParams extends HandlerParams {
+        final OriginInfo origin;
         final IPackageInstallObserver2 observer;
-        int flags;
+        int installFlags;
         final String installerPackageName;
         final VerificationParams verificationParams;
         private InstallArgs mArgs;
         private int mRet;
         final String packageAbiOverride;
-        boolean multiArch;
 
-        InstallParams(File originFile, boolean originStaged, IPackageInstallObserver2 observer,
-                int flags, String installerPackageName, VerificationParams verificationParams,
-                UserHandle user, String packageAbiOverride) {
+        InstallParams(OriginInfo origin, IPackageInstallObserver2 observer, int installFlags,
+                String installerPackageName, VerificationParams verificationParams, UserHandle user,
+                String packageAbiOverride) {
             super(user);
-            this.originFile = Preconditions.checkNotNull(originFile);
-            this.originStaged = originStaged;
+            this.origin = origin;
             this.observer = observer;
-            this.flags = flags;
+            this.installFlags = installFlags;
             this.installerPackageName = installerPackageName;
             this.verificationParams = verificationParams;
             this.packageAbiOverride = packageAbiOverride;
@@ -8584,9 +8517,8 @@
 
         @Override
         public String toString() {
-            return "InstallParams{"
-                + Integer.toHexString(System.identityHashCode(this))
-                + " " + originFile + "}";
+            return "InstallParams{" + Integer.toHexString(System.identityHashCode(this))
+                    + " file=" + origin.file + " cid=" + origin.cid + "}";
         }
 
         public ManifestDigest getManifestDigest() {
@@ -8596,17 +8528,17 @@
             return verificationParams.getManifestDigest();
         }
 
-        private int installLocationPolicy(PackageInfoLite pkgLite, int flags) {
+        private int installLocationPolicy(PackageInfoLite pkgLite) {
             String packageName = pkgLite.packageName;
             int installLocation = pkgLite.installLocation;
-            boolean onSd = (flags & PackageManager.INSTALL_EXTERNAL) != 0;
+            boolean onSd = (installFlags & PackageManager.INSTALL_EXTERNAL) != 0;
             // reader
             synchronized (mPackages) {
                 PackageParser.Package pkg = mPackages.get(packageName);
                 if (pkg != null) {
-                    if ((flags & PackageManager.INSTALL_REPLACE_EXISTING) != 0) {
+                    if ((installFlags & PackageManager.INSTALL_REPLACE_EXISTING) != 0) {
                         // Check for downgrading.
-                        if ((flags & PackageManager.INSTALL_ALLOW_DOWNGRADE) == 0) {
+                        if ((installFlags & PackageManager.INSTALL_ALLOW_DOWNGRADE) == 0) {
                             if (pkgLite.versionCode < pkg.mVersionCode) {
                                 Slog.w(TAG, "Can't install update of " + packageName
                                         + " update version " + pkgLite.versionCode
@@ -8655,15 +8587,6 @@
             return pkgLite.recommendedInstallLocation;
         }
 
-        private long getMemoryLowThreshold() {
-            final DeviceStorageMonitorInternal
-                    dsm = LocalServices.getService(DeviceStorageMonitorInternal.class);
-            if (dsm == null) {
-                return 0L;
-            }
-            return dsm.getMemoryLowThreshold();
-        }
-
         /*
          * Invoke remote method to get package information and install
          * location values. Override install location based on default
@@ -8672,8 +8595,23 @@
          */
         public void handleStartCopy() throws RemoteException {
             int ret = PackageManager.INSTALL_SUCCEEDED;
-            final boolean onSd = (flags & PackageManager.INSTALL_EXTERNAL) != 0;
-            final boolean onInt = (flags & PackageManager.INSTALL_INTERNAL) != 0;
+
+            // If we're already staged, we've firmly committed to an install location
+            if (origin.staged) {
+                if (origin.file != null) {
+                    installFlags |= PackageManager.INSTALL_INTERNAL;
+                    installFlags &= ~PackageManager.INSTALL_EXTERNAL;
+                } else if (origin.cid != null) {
+                    installFlags |= PackageManager.INSTALL_EXTERNAL;
+                    installFlags &= ~PackageManager.INSTALL_INTERNAL;
+                } else {
+                    throw new IllegalStateException("Invalid stage location");
+                }
+            }
+
+            final boolean onSd = (installFlags & PackageManager.INSTALL_EXTERNAL) != 0;
+            final boolean onInt = (installFlags & PackageManager.INSTALL_INTERNAL) != 0;
+
             PackageInfoLite pkgLite = null;
 
             if (onInt && onSd) {
@@ -8681,33 +8619,28 @@
                 Slog.w(TAG, "Conflicting flags specified for installing on both internal and external");
                 ret = PackageManager.INSTALL_FAILED_INVALID_INSTALL_LOCATION;
             } else {
-                final long lowThreshold = getMemoryLowThreshold();
-                if (lowThreshold == 0L) {
-                    Log.w(TAG, "Couldn't get low memory threshold; no free limit imposed");
-                }
-
-                // Remote call to find out default install location
-                final String originPath = originFile.getAbsolutePath();
-                pkgLite = mContainerService.getMinimalPackageInfo(originPath, flags, lowThreshold,
+                pkgLite = mContainerService.getMinimalPackageInfo(origin.resolvedPath, installFlags,
                         packageAbiOverride);
-                // Keep track of whether this package is a multiArch package until
-                // we perform a full scan of it. We need to do this because we might
-                // end up extracting the package shared libraries before we perform
-                // a full scan.
-                multiArch = pkgLite.multiArch;
 
                 /*
                  * If we have too little free space, try to free cache
                  * before giving up.
                  */
-                if (pkgLite.recommendedInstallLocation
+                if (!origin.staged && pkgLite.recommendedInstallLocation
                         == PackageHelper.RECOMMEND_FAILED_INSUFFICIENT_STORAGE) {
-                    final long size = mContainerService.calculateInstalledSize(
-                            originPath, isForwardLocked(), packageAbiOverride);
-                    if (mInstaller.freeCache(size + lowThreshold) >= 0) {
-                        pkgLite = mContainerService.getMinimalPackageInfo(originPath, flags,
-                                lowThreshold, packageAbiOverride);
+                    // TODO: focus freeing disk space on the target device
+                    final StorageManager storage = StorageManager.from(mContext);
+                    final long lowThreshold = storage.getStorageLowBytes(
+                            Environment.getDataDirectory());
+
+                    final long sizeBytes = mContainerService.calculateInstalledSize(
+                            origin.resolvedPath, isForwardLocked(), packageAbiOverride);
+
+                    if (mInstaller.freeCache(sizeBytes + lowThreshold) >= 0) {
+                        pkgLite = mContainerService.getMinimalPackageInfo(origin.resolvedPath,
+                                installFlags, packageAbiOverride);
                     }
+
                     /*
                      * The cache free must have deleted the file we
                      * downloaded to install.
@@ -8739,20 +8672,20 @@
                     ret = PackageManager.INSTALL_FAILED_MEDIA_UNAVAILABLE;
                 } else {
                     // Override with defaults if needed.
-                    loc = installLocationPolicy(pkgLite, flags);
+                    loc = installLocationPolicy(pkgLite);
                     if (loc == PackageHelper.RECOMMEND_FAILED_VERSION_DOWNGRADE) {
                         ret = PackageManager.INSTALL_FAILED_VERSION_DOWNGRADE;
                     } else if (!onSd && !onInt) {
                         // Override install location with flags
                         if (loc == PackageHelper.RECOMMEND_INSTALL_EXTERNAL) {
                             // Set the flag to install on external media.
-                            flags |= PackageManager.INSTALL_EXTERNAL;
-                            flags &= ~PackageManager.INSTALL_INTERNAL;
+                            installFlags |= PackageManager.INSTALL_EXTERNAL;
+                            installFlags &= ~PackageManager.INSTALL_INTERNAL;
                         } else {
                             // Make sure the flag for installing on external
                             // media is unset
-                            flags |= PackageManager.INSTALL_INTERNAL;
-                            flags &= ~PackageManager.INSTALL_EXTERNAL;
+                            installFlags |= PackageManager.INSTALL_INTERNAL;
+                            installFlags &= ~PackageManager.INSTALL_EXTERNAL;
                         }
                     }
                 }
@@ -8768,7 +8701,7 @@
                  */
                 int userIdentifier = getUser().getIdentifier();
                 if (userIdentifier == UserHandle.USER_ALL
-                        && ((flags & PackageManager.INSTALL_FROM_ADB) != 0)) {
+                        && ((installFlags & PackageManager.INSTALL_FROM_ADB) != 0)) {
                     userIdentifier = UserHandle.USER_OWNER;
                 }
 
@@ -8778,11 +8711,12 @@
                  */
                 final int requiredUid = mRequiredVerifierPackage == null ? -1
                         : getPackageUid(mRequiredVerifierPackage, userIdentifier);
-                if (requiredUid != -1 && isVerificationEnabled(userIdentifier, flags)) {
-                    // TODO: send verifier the install session instead of uri
+                if (!origin.existing && requiredUid != -1
+                        && isVerificationEnabled(userIdentifier, installFlags)) {
                     final Intent verification = new Intent(
                             Intent.ACTION_PACKAGE_NEEDS_VERIFICATION);
-                    verification.setDataAndType(Uri.fromFile(originFile), PACKAGE_MIME_TYPE);
+                    verification.setDataAndType(Uri.fromFile(new File(origin.resolvedPath)),
+                            PACKAGE_MIME_TYPE);
                     verification.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
 
                     final List<ResolveInfo> receivers = queryIntentReceivers(verification,
@@ -8802,7 +8736,8 @@
                     verification.putExtra(PackageManager.EXTRA_VERIFICATION_INSTALLER_PACKAGE,
                             installerPackageName);
 
-                    verification.putExtra(PackageManager.EXTRA_VERIFICATION_INSTALL_FLAGS, flags);
+                    verification.putExtra(PackageManager.EXTRA_VERIFICATION_INSTALL_FLAGS,
+                            installFlags);
 
                     verification.putExtra(PackageManager.EXTRA_VERIFICATION_PACKAGE_NAME,
                             pkgLite.packageName);
@@ -8919,123 +8854,21 @@
         }
 
         public boolean isForwardLocked() {
-            return (flags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
-        }
-    }
-
-    /*
-     * Utility class used in movePackage api.
-     * srcArgs and targetArgs are not set for invalid flags and make
-     * sure to do null checks when invoking methods on them.
-     * We probably want to return ErrorPrams for both failed installs
-     * and moves.
-     */
-    class MoveParams extends HandlerParams {
-        final IPackageMoveObserver observer;
-        final int flags;
-        final String packageName;
-        final InstallArgs srcArgs;
-        final InstallArgs targetArgs;
-        int uid;
-        int mRet;
-
-        MoveParams(InstallArgs srcArgs, IPackageMoveObserver observer, int flags,
-                String packageName, String[] instructionSets, int uid, UserHandle user,
-                boolean isMultiArch) {
-            super(user);
-            this.srcArgs = srcArgs;
-            this.observer = observer;
-            this.flags = flags;
-            this.packageName = packageName;
-            this.uid = uid;
-            if (srcArgs != null) {
-                final String codePath = srcArgs.getCodePath();
-                targetArgs = createInstallArgsForMoveTarget(codePath, flags, packageName,
-                        instructionSets, isMultiArch);
-            } else {
-                targetArgs = null;
-            }
-        }
-
-        @Override
-        public String toString() {
-            return "MoveParams{"
-                + Integer.toHexString(System.identityHashCode(this))
-                + " " + packageName + "}";
-        }
-
-        public void handleStartCopy() throws RemoteException {
-            mRet = PackageManager.INSTALL_FAILED_INSUFFICIENT_STORAGE;
-            // Check for storage space on target medium
-            if (!targetArgs.checkFreeStorage(mContainerService)) {
-                Log.w(TAG, "Insufficient storage to install");
-                return;
-            }
-
-            mRet = srcArgs.doPreCopy();
-            if (mRet != PackageManager.INSTALL_SUCCEEDED) {
-                return;
-            }
-
-            mRet = targetArgs.copyApk(mContainerService, false);
-            if (mRet != PackageManager.INSTALL_SUCCEEDED) {
-                srcArgs.doPostCopy(uid);
-                return;
-            }
-
-            mRet = srcArgs.doPostCopy(uid);
-            if (mRet != PackageManager.INSTALL_SUCCEEDED) {
-                return;
-            }
-
-            mRet = targetArgs.doPreInstall(mRet);
-            if (mRet != PackageManager.INSTALL_SUCCEEDED) {
-                return;
-            }
-
-            if (DEBUG_SD_INSTALL) {
-                StringBuilder builder = new StringBuilder();
-                if (srcArgs != null) {
-                    builder.append("src: ");
-                    builder.append(srcArgs.getCodePath());
-                }
-                if (targetArgs != null) {
-                    builder.append(" target : ");
-                    builder.append(targetArgs.getCodePath());
-                }
-                Log.i(TAG, builder.toString());
-            }
-        }
-
-        @Override
-        void handleReturnCode() {
-            targetArgs.doPostInstall(mRet, uid);
-            int currentStatus = PackageManager.MOVE_FAILED_INTERNAL_ERROR;
-            if (mRet == PackageManager.INSTALL_SUCCEEDED) {
-                currentStatus = PackageManager.MOVE_SUCCEEDED;
-            } else if (mRet == PackageManager.INSTALL_FAILED_INSUFFICIENT_STORAGE){
-                currentStatus = PackageManager.MOVE_FAILED_INSUFFICIENT_STORAGE;
-            }
-            processPendingMove(this, currentStatus);
-        }
-
-        @Override
-        void handleServiceError() {
-            mRet = PackageManager.INSTALL_FAILED_INTERNAL_ERROR;
+            return (installFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
         }
     }
 
     /**
      * Used during creation of InstallArgs
      *
-     * @param flags package installation flags
+     * @param installFlags package installation flags
      * @return true if should be installed on external storage
      */
-    private static boolean installOnSd(int flags) {
-        if ((flags & PackageManager.INSTALL_INTERNAL) != 0) {
+    private static boolean installOnSd(int installFlags) {
+        if ((installFlags & PackageManager.INSTALL_INTERNAL) != 0) {
             return false;
         }
-        if ((flags & PackageManager.INSTALL_EXTERNAL) != 0) {
+        if ((installFlags & PackageManager.INSTALL_EXTERNAL) != 0) {
             return true;
         }
         return false;
@@ -9044,17 +8877,15 @@
     /**
      * Used during creation of InstallArgs
      *
-     * @param flags package installation flags
+     * @param installFlags package installation flags
      * @return true if should be installed as forward locked
      */
-    private static boolean installForwardLocked(int flags) {
-        return (flags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
+    private static boolean installForwardLocked(int installFlags) {
+        return (installFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
     }
 
     private InstallArgs createInstallArgs(InstallParams params) {
-        // TODO: extend to support incoming zero-copy locations
-
-        if (installOnSd(params.flags) || params.isForwardLocked()) {
+        if (installOnSd(params.installFlags) || params.isForwardLocked()) {
             return new AsecInstallArgs(params);
         } else {
             return new FileInstallArgs(params);
@@ -9065,14 +8896,13 @@
      * Create args that describe an existing installed package. Typically used
      * when cleaning up old installs, or used as a move source.
      */
-    private InstallArgs createInstallArgsForExisting(int flags, String codePath,
-            String resourcePath, String nativeLibraryRoot, String[] instructionSets,
-            boolean isMultiArch) {
+    private InstallArgs createInstallArgsForExisting(int installFlags, String codePath,
+            String resourcePath, String nativeLibraryRoot, String[] instructionSets) {
         final boolean isInAsec;
-        if (installOnSd(flags)) {
+        if (installOnSd(installFlags)) {
             /* Apps on SD card are always in ASEC containers. */
             isInAsec = true;
-        } else if (installForwardLocked(flags)
+        } else if (installForwardLocked(installFlags)
                 && !codePath.startsWith(mDrmAppPrivateInstallDir.getAbsolutePath())) {
             /*
              * Forward-locked apps are only in ASEC containers if they're the
@@ -9085,62 +8915,41 @@
 
         if (isInAsec) {
             return new AsecInstallArgs(codePath, instructionSets,
-                    installOnSd(flags), installForwardLocked(flags), isMultiArch);
+                    installOnSd(installFlags), installForwardLocked(installFlags));
         } else {
             return new FileInstallArgs(codePath, resourcePath, nativeLibraryRoot,
-                    instructionSets, isMultiArch);
-        }
-    }
-
-    private InstallArgs createInstallArgsForMoveTarget(String codePath, int flags, String pkgName,
-            String[] instructionSets, boolean isMultiArch) {
-        final File codeFile = new File(codePath);
-        if (installOnSd(flags) || installForwardLocked(flags)) {
-            String cid = getNextCodePath(codePath, pkgName, "/"
-                    + AsecInstallArgs.RES_FILE_NAME);
-            return new AsecInstallArgs(codeFile, cid, instructionSets, installOnSd(flags),
-                    installForwardLocked(flags), isMultiArch);
-        } else {
-            return new FileInstallArgs(codeFile, instructionSets, isMultiArch);
+                    instructionSets);
         }
     }
 
     static abstract class InstallArgs {
-        /** @see InstallParams#originFile */
-        final File originFile;
-        /** @see InstallParams#originStaged */
-        final boolean originStaged;
-
-        // TODO: define inherit location
+        /** @see InstallParams#origin */
+        final OriginInfo origin;
 
         final IPackageInstallObserver2 observer;
         // Always refers to PackageManager flags only
-        final int flags;
+        final int installFlags;
         final String installerPackageName;
         final ManifestDigest manifestDigest;
         final UserHandle user;
         final String abiOverride;
-        final boolean multiArch;
 
         // The list of instruction sets supported by this app. This is currently
         // only used during the rmdex() phase to clean up resources. We can get rid of this
         // if we move dex files under the common app path.
         /* nullable */ String[] instructionSets;
 
-        InstallArgs(File originFile, boolean originStaged, IPackageInstallObserver2 observer,
-                    int flags, String installerPackageName, ManifestDigest manifestDigest,
-                    UserHandle user, String[] instructionSets,
-                    String abiOverride, boolean multiArch) {
-            this.originFile = originFile;
-            this.originStaged = originStaged;
-            this.flags = flags;
+        InstallArgs(OriginInfo origin, IPackageInstallObserver2 observer, int installFlags,
+                String installerPackageName, ManifestDigest manifestDigest, UserHandle user,
+                String[] instructionSets, String abiOverride) {
+            this.origin = origin;
+            this.installFlags = installFlags;
             this.observer = observer;
             this.installerPackageName = installerPackageName;
             this.manifestDigest = manifestDigest;
             this.user = user;
             this.instructionSets = instructionSets;
             this.abiOverride = abiOverride;
-            this.multiArch = multiArch;
         }
 
         abstract int copyApk(IMediaContainerService imcs, boolean temp) throws RemoteException;
@@ -9185,7 +8994,11 @@
         }
 
         protected boolean isFwdLocked() {
-            return (flags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
+            return (installFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0;
+        }
+
+        protected boolean isExternal() {
+            return (installFlags & PackageManager.INSTALL_EXTERNAL) != 0;
         }
 
         UserHandle getUser() {
@@ -9211,10 +9024,9 @@
 
         /** New install */
         FileInstallArgs(InstallParams params) {
-            super(params.originFile, params.originStaged, params.observer, params.flags,
+            super(params.origin, params.observer, params.installFlags,
                     params.installerPackageName, params.getManifestDigest(), params.getUser(),
-                    null /* instruction sets */, params.packageAbiOverride,
-                    params.multiArch);
+                    null /* instruction sets */, params.packageAbiOverride);
             if (isFwdLocked()) {
                 throw new IllegalArgumentException("Forward locking only supported in ASEC");
             }
@@ -9222,130 +9034,73 @@
 
         /** Existing install */
         FileInstallArgs(String codePath, String resourcePath, String legacyNativeLibraryPath,
-                String[] instructionSets, boolean isMultiArch) {
-            super(null, false, null, 0, null, null, null, instructionSets, null, isMultiArch);
+                String[] instructionSets) {
+            super(OriginInfo.fromNothing(), null, 0, null, null, null, instructionSets, null);
             this.codeFile = (codePath != null) ? new File(codePath) : null;
             this.resourceFile = (resourcePath != null) ? new File(resourcePath) : null;
             this.legacyNativeLibraryPath = (legacyNativeLibraryPath != null) ?
                     new File(legacyNativeLibraryPath) : null;
         }
 
-        /** New install from existing */
-        FileInstallArgs(File originFile, String[] instructionSets, boolean isMultiArch) {
-            super(originFile, false, null, 0, null, null, null, instructionSets, null,
-                    isMultiArch);
-        }
-
         boolean checkFreeStorage(IMediaContainerService imcs) throws RemoteException {
-            final long lowThreshold;
+            final long sizeBytes = imcs.calculateInstalledSize(origin.file.getAbsolutePath(),
+                    isFwdLocked(), abiOverride);
 
-            final DeviceStorageMonitorInternal
-                    dsm = LocalServices.getService(DeviceStorageMonitorInternal.class);
-            if (dsm == null) {
-                Log.w(TAG, "Couldn't get low memory threshold; no free limit imposed");
-                lowThreshold = 0L;
-            } else {
-                if (dsm.isMemoryLow()) {
-                    Log.w(TAG, "Memory is reported as being too low; aborting package install");
-                    return false;
-                }
-
-                lowThreshold = dsm.getMemoryLowThreshold();
-            }
-
-            return imcs.checkInternalFreeStorage(originFile.getAbsolutePath(), isFwdLocked(),
-                    lowThreshold);
+            final StorageManager storage = StorageManager.from(mContext);
+            return (sizeBytes <= storage.getStorageBytesUntilLow(Environment.getDataDirectory()));
         }
 
         int copyApk(IMediaContainerService imcs, boolean temp) throws RemoteException {
-            int ret = PackageManager.INSTALL_SUCCEEDED;
+            if (origin.staged) {
+                Slog.d(TAG, origin.file + " already staged; skipping copy");
+                codeFile = origin.file;
+                resourceFile = origin.file;
+                return PackageManager.INSTALL_SUCCEEDED;
+            }
 
-            if (originStaged) {
-                Slog.d(TAG, originFile + " already staged; skipping copy");
-                codeFile = originFile;
-                resourceFile = originFile;
-            } else {
-                try {
-                    final File tempDir = mInstallerService.allocateSessionDir();
-                    codeFile = tempDir;
-                    resourceFile = tempDir;
-                } catch (IOException e) {
-                    Slog.w(TAG, "Failed to create copy file: " + e);
-                    return PackageManager.INSTALL_FAILED_INSUFFICIENT_STORAGE;
-                }
+            try {
+                final File tempDir = mInstallerService.allocateInternalStageDirLegacy();
+                codeFile = tempDir;
+                resourceFile = tempDir;
+            } catch (IOException e) {
+                Slog.w(TAG, "Failed to create copy file: " + e);
+                return PackageManager.INSTALL_FAILED_INSUFFICIENT_STORAGE;
+            }
 
-                final IParcelFileDescriptorFactory target = new IParcelFileDescriptorFactory.Stub() {
-                    @Override
-                    public ParcelFileDescriptor open(String name, int mode) throws RemoteException {
-                        if (!FileUtils.isValidExtFilename(name)) {
-                            throw new IllegalArgumentException("Invalid filename: " + name);
-                        }
-                        try {
-                            final File file = new File(codeFile, name);
-                            final FileDescriptor fd = Os.open(file.getAbsolutePath(),
-                                    O_RDWR | O_CREAT, 0644);
-                            Os.chmod(file.getAbsolutePath(), 0644);
-                            return new ParcelFileDescriptor(fd);
-                        } catch (ErrnoException e) {
-                            throw new RemoteException("Failed to open: " + e.getMessage());
-                        }
+            final IParcelFileDescriptorFactory target = new IParcelFileDescriptorFactory.Stub() {
+                @Override
+                public ParcelFileDescriptor open(String name, int mode) throws RemoteException {
+                    if (!FileUtils.isValidExtFilename(name)) {
+                        throw new IllegalArgumentException("Invalid filename: " + name);
                     }
-                };
-
-                ret = imcs.copyPackage(originFile.getAbsolutePath(), target);
-                if (ret != PackageManager.INSTALL_SUCCEEDED) {
-                    Slog.e(TAG, "Failed to copy package");
-                    return ret;
+                    try {
+                        final File file = new File(codeFile, name);
+                        final FileDescriptor fd = Os.open(file.getAbsolutePath(),
+                                O_RDWR | O_CREAT, 0644);
+                        Os.chmod(file.getAbsolutePath(), 0644);
+                        return new ParcelFileDescriptor(fd);
+                    } catch (ErrnoException e) {
+                        throw new RemoteException("Failed to open: " + e.getMessage());
+                    }
                 }
+            };
+
+            int ret = PackageManager.INSTALL_SUCCEEDED;
+            ret = imcs.copyPackage(origin.file.getAbsolutePath(), target);
+            if (ret != PackageManager.INSTALL_SUCCEEDED) {
+                Slog.e(TAG, "Failed to copy package");
+                return ret;
             }
 
             final File libraryRoot = new File(codeFile, LIB_DIR_NAME);
             NativeLibraryHelper.Handle handle = null;
             try {
                 handle = NativeLibraryHelper.Handle.create(codeFile);
-                if (multiArch) {
-                    // Warn if we've set an abiOverride for multi-lib packages..
-                    // By definition, we need to copy both 32 and 64 bit libraries for
-                    // such packages.
-                    if (abiOverride != null &&  !CLEAR_ABI_OVERRIDE.equals(abiOverride)) {
-                        Slog.w(TAG, "Ignoring abiOverride for multi arch application.");
-                    }
-
-                    int copyRet = PackageManager.NO_NATIVE_LIBRARIES;
-                    if (Build.SUPPORTED_32_BIT_ABIS.length > 0) {
-                        copyRet = copyNativeLibrariesForInternalApp(handle, libraryRoot,
-                                Build.SUPPORTED_32_BIT_ABIS, true /* use isa specific subdirs */);
-                        maybeThrowExceptionForMultiArchCopy("Failure copying 32 bit native libraries", copyRet);
-                    }
-
-                    if (Build.SUPPORTED_64_BIT_ABIS.length > 0) {
-                        copyRet = copyNativeLibrariesForInternalApp(handle, libraryRoot,
-                                Build.SUPPORTED_64_BIT_ABIS, true /* use isa specific subdirs */);
-                        maybeThrowExceptionForMultiArchCopy("Failure copying 64 bit native libraries", copyRet);
-                    }
-                } else {
-                    final String cpuAbiOverride = deriveAbiOverride(this.abiOverride, null /* package setting */);
-                    String[] abiList = (cpuAbiOverride != null) ?
-                            new String[] { cpuAbiOverride } : Build.SUPPORTED_ABIS;
-
-                    if (Build.SUPPORTED_64_BIT_ABIS.length > 0 && cpuAbiOverride == null &&
-                            NativeLibraryHelper.hasRenderscriptBitcode(handle)) {
-                        abiList = Build.SUPPORTED_32_BIT_ABIS;
-                    }
-
-                    int copyRet = copyNativeLibrariesForInternalApp(handle, libraryRoot, abiList,
-                            true /* use isa specific subdirs */);
-                    if (copyRet < 0 && copyRet != PackageManager.NO_NATIVE_LIBRARIES) {
-                        Slog.w(TAG, "Failure copying native libraries [errorCode=" + copyRet + "]");
-                        return copyRet;
-                    }
-                }
+                ret = NativeLibraryHelper.copyNativeBinariesWithOverride(handle, libraryRoot,
+                        abiOverride);
             } catch (IOException e) {
                 Slog.e(TAG, "Copying native libraries failed", e);
                 ret = PackageManager.INSTALL_FAILED_INTERNAL_ERROR;
-            } catch (PackageManagerException pme) {
-                Slog.e(TAG, "Copying native libraries failed", pme);
-                ret = pme.error;
             } finally {
                 IoUtils.closeQuietly(handle);
             }
@@ -9520,8 +9275,6 @@
      * renaming logic.
      */
     class AsecInstallArgs extends InstallArgs {
-        // TODO: teach about handling cluster directories
-
         static final String RES_FILE_NAME = "pkg.apk";
         static final String PUBLIC_RES_FILE_NAME = "res.zip";
 
@@ -9532,58 +9285,66 @@
 
         /** New install */
         AsecInstallArgs(InstallParams params) {
-            super(params.originFile, params.originStaged, params.observer, params.flags,
+            super(params.origin, params.observer, params.installFlags,
                     params.installerPackageName, params.getManifestDigest(),
                     params.getUser(), null /* instruction sets */,
-                    params.packageAbiOverride, params.multiArch);
+                    params.packageAbiOverride);
         }
 
         /** Existing install */
         AsecInstallArgs(String fullCodePath, String[] instructionSets,
-                        boolean isExternal, boolean isForwardLocked, boolean isMultiArch) {
-            super(null, false, null, (isExternal ? INSTALL_EXTERNAL : 0)
+                        boolean isExternal, boolean isForwardLocked) {
+            super(OriginInfo.fromNothing(), null, (isExternal ? INSTALL_EXTERNAL : 0)
                     | (isForwardLocked ? INSTALL_FORWARD_LOCK : 0), null, null, null,
-                    instructionSets, null, isMultiArch);
+                    instructionSets, null);
+            // Hackily pretend we're still looking at a full code path
+            if (!fullCodePath.endsWith(RES_FILE_NAME)) {
+                fullCodePath = new File(fullCodePath, RES_FILE_NAME).getAbsolutePath();
+            }
+
             // Extract cid from fullCodePath
             int eidx = fullCodePath.lastIndexOf("/");
             String subStr1 = fullCodePath.substring(0, eidx);
             int sidx = subStr1.lastIndexOf("/");
             cid = subStr1.substring(sidx+1, eidx);
-            setCachePath(subStr1);
+            setMountPath(subStr1);
         }
 
-        AsecInstallArgs(String cid, String[] instructionSets, boolean isForwardLocked,
-                        boolean isMultiArch) {
-            super(null, false, null, (isAsecExternal(cid) ? INSTALL_EXTERNAL : 0)
+        AsecInstallArgs(String cid, String[] instructionSets, boolean isForwardLocked) {
+            super(OriginInfo.fromNothing(), null, (isAsecExternal(cid) ? INSTALL_EXTERNAL : 0)
                     | (isForwardLocked ? INSTALL_FORWARD_LOCK : 0), null, null, null,
-                    instructionSets, null, isMultiArch);
+                    instructionSets, null);
             this.cid = cid;
-            setCachePath(PackageHelper.getSdDir(cid));
-        }
-
-        /** New install from existing */
-        AsecInstallArgs(File originPackageFile, String cid, String[] instructionSets,
-                boolean isExternal, boolean isForwardLocked, boolean isMultiArch) {
-            super(originPackageFile, false, null, (isExternal ? INSTALL_EXTERNAL : 0)
-                    | (isForwardLocked ? INSTALL_FORWARD_LOCK : 0), null, null, null,
-                    instructionSets, null, isMultiArch);
-            this.cid = cid;
+            setMountPath(PackageHelper.getSdDir(cid));
         }
 
         void createCopyFile() {
-            cid = getTempContainerId();
+            cid = mInstallerService.allocateExternalStageCidLegacy();
         }
 
         boolean checkFreeStorage(IMediaContainerService imcs) throws RemoteException {
-            return imcs.checkExternalFreeStorage(originFile.getAbsolutePath(), isFwdLocked(),
+            final long sizeBytes = imcs.calculateInstalledSize(packagePath, isFwdLocked(),
                     abiOverride);
-        }
 
-        private final boolean isExternal() {
-            return (flags & PackageManager.INSTALL_EXTERNAL) != 0;
+            final File target;
+            if (isExternal()) {
+                target = new UserEnvironment(UserHandle.USER_OWNER).getExternalStorageDirectory();
+            } else {
+                target = Environment.getDataDirectory();
+            }
+
+            final StorageManager storage = StorageManager.from(mContext);
+            return (sizeBytes <= storage.getStorageBytesUntilLow(target));
         }
 
         int copyApk(IMediaContainerService imcs, boolean temp) throws RemoteException {
+            if (origin.staged) {
+                Slog.d(TAG, origin.cid + " already staged; skipping copy");
+                cid = origin.cid;
+                setMountPath(PackageHelper.getSdDir(cid));
+                return PackageManager.INSTALL_SUCCEEDED;
+            }
+
             if (temp) {
                 createCopyFile();
             } else {
@@ -9594,12 +9355,12 @@
                 PackageHelper.destroySdDir(cid);
             }
 
-            final String newCachePath = imcs.copyPackageToContainer(
-                    originFile.getAbsolutePath(), cid, getEncryptKey(), isExternal(),
+            final String newMountPath = imcs.copyPackageToContainer(
+                    origin.file.getAbsolutePath(), cid, getEncryptKey(), isExternal(),
                     isFwdLocked(), deriveAbiOverride(abiOverride, null /* settings */));
 
-            if (newCachePath != null) {
-                setCachePath(newCachePath);
+            if (newMountPath != null) {
+                setMountPath(newMountPath);
                 return PackageManager.INSTALL_SUCCEEDED;
             } else {
                 return PackageManager.INSTALL_FAILED_CONTAINER_ERROR;
@@ -9628,10 +9389,10 @@
             } else {
                 boolean mounted = PackageHelper.isContainerMounted(cid);
                 if (!mounted) {
-                    String newCachePath = PackageHelper.mountSdDir(cid, getEncryptKey(),
+                    String newMountPath = PackageHelper.mountSdDir(cid, getEncryptKey(),
                             Process.SYSTEM_UID);
-                    if (newCachePath != null) {
-                        setCachePath(newCachePath);
+                    if (newMountPath != null) {
+                        setMountPath(newMountPath);
                     } else {
                         return PackageManager.INSTALL_FAILED_CONTAINER_ERROR;
                     }
@@ -9642,7 +9403,7 @@
 
         boolean doRename(int status, PackageParser.Package pkg, String oldCodePath) {
             String newCacheId = getNextCodePath(oldCodePath, pkg.packageName, "/" + RES_FILE_NAME);
-            String newCachePath = null;
+            String newMountPath = null;
             if (PackageHelper.isContainerMounted(cid)) {
                 // Unmount the container
                 if (!PackageHelper.unMountSdDir(cid)) {
@@ -9667,46 +9428,59 @@
             }
             if (!PackageHelper.isContainerMounted(newCacheId)) {
                 Slog.w(TAG, "Mounting container " + newCacheId);
-                newCachePath = PackageHelper.mountSdDir(newCacheId,
+                newMountPath = PackageHelper.mountSdDir(newCacheId,
                         getEncryptKey(), Process.SYSTEM_UID);
             } else {
-                newCachePath = PackageHelper.getSdDir(newCacheId);
+                newMountPath = PackageHelper.getSdDir(newCacheId);
             }
-            if (newCachePath == null) {
+            if (newMountPath == null) {
                 Slog.w(TAG, "Failed to get cache path for  " + newCacheId);
                 return false;
             }
             Log.i(TAG, "Succesfully renamed " + cid +
                     " to " + newCacheId +
-                    " at new path: " + newCachePath);
+                    " at new path: " + newMountPath);
             cid = newCacheId;
-            setCachePath(newCachePath);
 
-            // TODO: extend to support split APKs
-            pkg.codePath = getCodePath();
-            pkg.baseCodePath = getCodePath();
-            pkg.splitCodePaths = null;
+            final File beforeCodeFile = new File(packagePath);
+            setMountPath(newMountPath);
+            final File afterCodeFile = new File(packagePath);
 
-            pkg.applicationInfo.setCodePath(getCodePath());
-            pkg.applicationInfo.setBaseCodePath(getCodePath());
-            pkg.applicationInfo.setSplitCodePaths(null);
-            pkg.applicationInfo.setResourcePath(getResourcePath());
-            pkg.applicationInfo.setBaseResourcePath(getResourcePath());
-            pkg.applicationInfo.setSplitResourcePaths(null);
+            // Reflect the rename in scanned details
+            pkg.codePath = afterCodeFile.getAbsolutePath();
+            pkg.baseCodePath = FileUtils.rewriteAfterRename(beforeCodeFile, afterCodeFile,
+                    pkg.baseCodePath);
+            pkg.splitCodePaths = FileUtils.rewriteAfterRename(beforeCodeFile, afterCodeFile,
+                    pkg.splitCodePaths);
+
+            // Reflect the rename in app info
+            pkg.applicationInfo.setCodePath(pkg.codePath);
+            pkg.applicationInfo.setBaseCodePath(pkg.baseCodePath);
+            pkg.applicationInfo.setSplitCodePaths(pkg.splitCodePaths);
+            pkg.applicationInfo.setResourcePath(pkg.codePath);
+            pkg.applicationInfo.setBaseResourcePath(pkg.baseCodePath);
+            pkg.applicationInfo.setSplitResourcePaths(pkg.splitCodePaths);
 
             return true;
         }
 
-        private void setCachePath(String newCachePath) {
-            File cachePath = new File(newCachePath);
-            legacyNativeLibraryDir = new File(cachePath, LIB_DIR_NAME).getPath();
-            packagePath = new File(cachePath, RES_FILE_NAME).getPath();
+        private void setMountPath(String mountPath) {
+            final File mountFile = new File(mountPath);
 
-            if (isFwdLocked()) {
-                resourcePath = new File(cachePath, PUBLIC_RES_FILE_NAME).getPath();
+            final File monolithicFile = new File(mountFile, RES_FILE_NAME);
+            if (monolithicFile.exists()) {
+                packagePath = monolithicFile.getAbsolutePath();
+                if (isFwdLocked()) {
+                    resourcePath = new File(mountFile, PUBLIC_RES_FILE_NAME).getAbsolutePath();
+                } else {
+                    resourcePath = packagePath;
+                }
             } else {
+                packagePath = mountFile.getAbsolutePath();
                 resourcePath = packagePath;
             }
+
+            legacyNativeLibraryDir = new File(mountFile, LIB_DIR_NAME).getAbsolutePath();
         }
 
         int doPostInstall(int status, int uid) {
@@ -9745,23 +9519,43 @@
             PackageHelper.destroySdDir(cid);
         }
 
-        void cleanUpResourcesLI() {
-            String sourceFile = getCodePath();
-            // Remove dex file
-            if (instructionSets == null) {
-                throw new IllegalStateException("instructionSet == null");
-            }
-            String[] dexCodeInstructionSets = getDexCodeInstructionSets(instructionSets);
-            for (String dexCodeInstructionSet : dexCodeInstructionSets) {
-                int retCode = mInstaller.rmdex(sourceFile, dexCodeInstructionSet);
-                if (retCode < 0) {
-                    Slog.w(TAG, "Couldn't remove dex file for package: "
-                            + " at location "
-                            + sourceFile.toString() + ", retcode=" + retCode);
-                    // we don't consider this to be a failure of the core package deletion
+        private List<String> getAllCodePaths() {
+            final File codeFile = new File(getCodePath());
+            if (codeFile != null && codeFile.exists()) {
+                try {
+                    final PackageLite pkg = PackageParser.parsePackageLite(codeFile, 0);
+                    return pkg.getAllCodePaths();
+                } catch (PackageParserException e) {
+                    // Ignored; we tried our best
                 }
             }
+            return Collections.EMPTY_LIST;
+        }
+
+        void cleanUpResourcesLI() {
+            // Enumerate all code paths before deleting
+            cleanUpResourcesLI(getAllCodePaths());
+        }
+
+        private void cleanUpResourcesLI(List<String> allCodePaths) {
             cleanUp();
+
+            if (!allCodePaths.isEmpty()) {
+                if (instructionSets == null) {
+                    throw new IllegalStateException("instructionSet == null");
+                }
+                String[] dexCodeInstructionSets = getDexCodeInstructionSets(instructionSets);
+                for (String codePath : allCodePaths) {
+                    for (String dexCodeInstructionSet : dexCodeInstructionSets) {
+                        int retCode = mInstaller.rmdex(codePath, dexCodeInstructionSet);
+                        if (retCode < 0) {
+                            Slog.w(TAG, "Couldn't remove dex file for package: "
+                                    + " at location " + codePath + ", retcode=" + retCode);
+                            // we don't consider this to be a failure of the core package deletion
+                        }
+                    }
+                }
+            }
         }
 
         boolean matchContainer(String app) {
@@ -9776,16 +9570,19 @@
         }
 
         boolean doPostDeleteLI(boolean delete) {
-            boolean ret = false;
+            if (DEBUG_SD_INSTALL) Slog.i(TAG, "doPostDeleteLI() del=" + delete);
+            final List<String> allCodePaths = getAllCodePaths();
             boolean mounted = PackageHelper.isContainerMounted(cid);
             if (mounted) {
                 // Unmount first
-                ret = PackageHelper.unMountSdDir(cid);
+                if (PackageHelper.unMountSdDir(cid)) {
+                    mounted = false;
+                }
             }
-            if (ret && delete) {
-                cleanUpResourcesLI();
+            if (!mounted && delete) {
+                cleanUpResourcesLI(allCodePaths);
             }
-            return ret;
+            return !mounted;
         }
 
         @Override
@@ -9946,7 +9743,7 @@
      * Install a non-existing package.
      */
     private void installNewPackageLI(PackageParser.Package pkg,
-            int parseFlags, int scanMode, UserHandle user,
+            int parseFlags, int scanFlags, UserHandle user,
             String installerPackageName, PackageInstalledInfo res) {
         // Remember this for later, in case we need to rollback this install
         String pkgName = pkg.packageName;
@@ -9964,7 +9761,7 @@
                         + mSettings.mRenamedPackages.get(pkgName));
                 return;
             }
-            if (mPackages.containsKey(pkgName) || mAppDirs.containsKey(pkg.codePath)) {
+            if (mPackages.containsKey(pkgName)) {
                 // Don't allow installation over an existing package with the same name.
                 res.setError(INSTALL_FAILED_ALREADY_EXISTS, "Attempt to re-install " + pkgName
                         + " without first uninstalling.");
@@ -9973,7 +9770,7 @@
         }
 
         try {
-            PackageParser.Package newPackage = scanPackageLI(pkg, parseFlags, scanMode,
+            PackageParser.Package newPackage = scanPackageLI(pkg, parseFlags, scanFlags,
                     System.currentTimeMillis(), user);
 
             updateSettingsLI(newPackage, installerPackageName, null, null, res);
@@ -10009,7 +9806,7 @@
     }
 
     private void replacePackageLI(PackageParser.Package pkg,
-            int parseFlags, int scanMode, UserHandle user,
+            int parseFlags, int scanFlags, UserHandle user,
             String installerPackageName, PackageInstalledInfo res) {
         PackageParser.Package oldPackage;
         String pkgName = pkg.packageName;
@@ -10048,16 +9845,16 @@
 
         boolean sysPkg = (isSystemApp(oldPackage));
         if (sysPkg) {
-            replaceSystemPackageLI(oldPackage, pkg, parseFlags, scanMode,
+            replaceSystemPackageLI(oldPackage, pkg, parseFlags, scanFlags,
                     user, allUsers, perUserInstalled, installerPackageName, res);
         } else {
-            replaceNonSystemPackageLI(oldPackage, pkg, parseFlags, scanMode,
+            replaceNonSystemPackageLI(oldPackage, pkg, parseFlags, scanFlags,
                     user, allUsers, perUserInstalled, installerPackageName, res);
         }
     }
 
     private void replaceNonSystemPackageLI(PackageParser.Package deletedPackage,
-            PackageParser.Package pkg, int parseFlags, int scanMode, UserHandle user,
+            PackageParser.Package pkg, int parseFlags, int scanFlags, UserHandle user,
             int[] allUsers, boolean[] perUserInstalled,
             String installerPackageName, PackageInstalledInfo res) {
         String pkgName = deletedPackage.packageName;
@@ -10080,11 +9877,24 @@
             res.setError(INSTALL_FAILED_REPLACE_COULDNT_DELETE, "replaceNonSystemPackageLI");
             deletedPkg = false;
         } else {
-            // Successfully deleted the old package. Now proceed with re-installation
+            // Successfully deleted the old package; proceed with replace.
+
+            // If deleted package lived in a container, give users a chance to
+            // relinquish resources before killing.
+            if (isForwardLocked(deletedPackage) || isExternal(deletedPackage)) {
+                if (DEBUG_INSTALL) {
+                    Slog.i(TAG, "upgrading pkg " + deletedPackage + " is ASEC-hosted -> UNAVAILABLE");
+                }
+                final int[] uidArray = new int[] { deletedPackage.applicationInfo.uid };
+                final ArrayList<String> pkgList = new ArrayList<String>(1);
+                pkgList.add(deletedPackage.applicationInfo.packageName);
+                sendResourcesChangedBroadcast(false, true, pkgList, uidArray, null);
+            }
+
             deleteCodeCacheDirsLI(pkgName);
             try {
                 final PackageParser.Package newPackage = scanPackageLI(pkg, parseFlags,
-                        scanMode | SCAN_UPDATE_TIME, System.currentTimeMillis(), user);
+                        scanFlags | SCAN_UPDATE_TIME, System.currentTimeMillis(), user);
                 updateSettingsLI(newPackage, installerPackageName, allUsers, perUserInstalled, res);
                 updatedSettings = true;
             } catch (PackageManagerException e) {
@@ -10114,10 +9924,9 @@
                 int oldParseFlags  = mDefParseFlags | PackageParser.PARSE_CHATTY |
                         (isForwardLocked(deletedPackage) ? PackageParser.PARSE_FORWARD_LOCK : 0) |
                         (oldOnSd ? PackageParser.PARSE_ON_SDCARD : 0);
-                int oldScanMode = (oldOnSd ? 0 : SCAN_MONITOR) | SCAN_UPDATE_SIGNATURE
-                        | SCAN_UPDATE_TIME;
+                int oldScanFlags = SCAN_UPDATE_SIGNATURE | SCAN_UPDATE_TIME;
                 try {
-                    scanPackageLI(restoreFile, oldParseFlags, oldScanMode, origUpdateTime, null);
+                    scanPackageLI(restoreFile, oldParseFlags, oldScanFlags, origUpdateTime, null);
                 } catch (PackageManagerException e) {
                     Slog.e(TAG, "Failed to restore package : " + pkgName + " after failed upgrade: "
                             + e.getMessage());
@@ -10137,14 +9946,13 @@
     }
 
     private void replaceSystemPackageLI(PackageParser.Package deletedPackage,
-            PackageParser.Package pkg, int parseFlags, int scanMode, UserHandle user,
+            PackageParser.Package pkg, int parseFlags, int scanFlags, UserHandle user,
             int[] allUsers, boolean[] perUserInstalled,
             String installerPackageName, PackageInstalledInfo res) {
         if (DEBUG_INSTALL) Slog.d(TAG, "replaceSystemPackageLI: new=" + pkg
                 + ", old=" + deletedPackage);
         boolean updatedSettings = false;
-        parseFlags |= PackageManager.INSTALL_REPLACE_EXISTING |
-                PackageParser.PARSE_IS_SYSTEM;
+        parseFlags |= PackageParser.PARSE_IS_SYSTEM;
         if ((deletedPackage.applicationInfo.flags&ApplicationInfo.FLAG_PRIVILEGED) != 0) {
             parseFlags |= PackageParser.PARSE_IS_PRIVILEGED;
         }
@@ -10184,8 +9992,7 @@
                         deletedPackage.applicationInfo.getCodePath(),
                         deletedPackage.applicationInfo.getResourcePath(),
                         deletedPackage.applicationInfo.nativeLibraryRootDir,
-                        getAppDexInstructionSets(deletedPackage.applicationInfo),
-                        isMultiArch(deletedPackage.applicationInfo));
+                        getAppDexInstructionSets(deletedPackage.applicationInfo));
             } else {
                 res.removedInfo.args = null;
             }
@@ -10199,7 +10006,7 @@
 
         PackageParser.Package newPackage = null;
         try {
-            newPackage = scanPackageLI(pkg, parseFlags, scanMode, 0, user);
+            newPackage = scanPackageLI(pkg, parseFlags, scanFlags, 0, user);
             if (newPackage.mExtras != null) {
                 final PackageSetting newPkgSetting = (PackageSetting) newPackage.mExtras;
                 newPkgSetting.firstInstallTime = oldPkgSetting.firstInstallTime;
@@ -10231,7 +10038,7 @@
             }
             // Add back the old system package
             try {
-                scanPackageLI(oldPkg, parseFlags, SCAN_MONITOR | SCAN_UPDATE_SIGNATURE, 0, user);
+                scanPackageLI(oldPkg, parseFlags, SCAN_UPDATE_SIGNATURE, 0, user);
             } catch (PackageManagerException e) {
                 Slog.e(TAG, "Failed to restore original package: " + e.getMessage());
             }
@@ -10247,33 +10054,6 @@
         }
     }
 
-    // Utility method used to move dex files during install.
-    private int moveDexFilesLI(String oldCodePath, PackageParser.Package newPackage) {
-        // TODO: extend to move split APK dex files
-        if ((newPackage.applicationInfo.flags&ApplicationInfo.FLAG_HAS_CODE) != 0) {
-            final String[] instructionSets = getAppDexInstructionSets(newPackage.applicationInfo);
-            String[] dexCodeInstructionSets = getDexCodeInstructionSets(instructionSets);
-            for (String dexCodeInstructionSet : dexCodeInstructionSets) {
-                int retCode = mInstaller.movedex(oldCodePath, newPackage.baseCodePath,
-                        dexCodeInstructionSet);
-                if (retCode != 0) {
-                /*
-                 * Programs may be lazily run through dexopt, so the
-                 * source may not exist. However, something seems to
-                 * have gone wrong, so note that dexopt needs to be
-                 * run again and remove the source file. In addition,
-                 * remove the target to make sure there isn't a stale
-                 * file from a previous version of the package.
-                 */
-                    newPackage.mDexOptPerformed.clear();
-                    mInstaller.rmdex(oldCodePath, dexCodeInstructionSet);
-                    mInstaller.rmdex(newPackage.baseCodePath, dexCodeInstructionSet);
-                }
-            }
-        }
-        return PackageManager.INSTALL_SUCCEEDED;
-    }
-
     private void updateSettingsLI(PackageParser.Package newPackage, String installerPackageName,
             int[] allUsers, boolean[] perUserInstalled,
             PackageInstalledInfo res) {
@@ -10333,21 +10113,20 @@
         }
     }
 
-    private void installPackageLI(InstallArgs args, boolean newInstall, PackageInstalledInfo res) {
-        int pFlags = args.flags;
+    private void installPackageLI(InstallArgs args, PackageInstalledInfo res) {
+        final int installFlags = args.installFlags;
         String installerPackageName = args.installerPackageName;
         File tmpPackageFile = new File(args.getCodePath());
-        boolean forwardLocked = ((pFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0);
-        boolean onSd = ((pFlags & PackageManager.INSTALL_EXTERNAL) != 0);
+        boolean forwardLocked = ((installFlags & PackageManager.INSTALL_FORWARD_LOCK) != 0);
+        boolean onSd = ((installFlags & PackageManager.INSTALL_EXTERNAL) != 0);
         boolean replace = false;
-        int scanMode = (onSd ? 0 : SCAN_MONITOR) | SCAN_FORCE_DEX | SCAN_UPDATE_SIGNATURE
-                | (newInstall ? SCAN_NEW_INSTALL : 0);
+        final int scanFlags = SCAN_NEW_INSTALL | SCAN_FORCE_DEX | SCAN_UPDATE_SIGNATURE;
         // Result object to be returned
         res.returnCode = PackageManager.INSTALL_SUCCEEDED;
 
         if (DEBUG_INSTALL) Slog.d(TAG, "installPackageLI: path=" + tmpPackageFile);
         // Retrieve PackageSettings and parse package
-        int parseFlags = mDefParseFlags | PackageParser.PARSE_CHATTY
+        final int parseFlags = mDefParseFlags | PackageParser.PARSE_CHATTY
                 | (forwardLocked ? PackageParser.PARSE_FORWARD_LOCK : 0)
                 | (onSd ? PackageParser.PARSE_ON_SDCARD : 0);
         PackageParser pp = new PackageParser();
@@ -10367,7 +10146,7 @@
 
         String pkgName = res.name = pkg.packageName;
         if ((pkg.applicationInfo.flags&ApplicationInfo.FLAG_TEST_ONLY) != 0) {
-            if ((pFlags&PackageManager.INSTALL_ALLOW_TEST) == 0) {
+            if ((installFlags & PackageManager.INSTALL_ALLOW_TEST) == 0) {
                 res.setError(INSTALL_FAILED_TEST_ONLY, "installPackageLI");
                 return;
             }
@@ -10413,8 +10192,18 @@
                 if (bp != null) {
                     // If the defining package is signed with our cert, it's okay.  This
                     // also includes the "updating the same package" case, of course.
-                    if (compareSignatures(bp.packageSetting.signatures.mSignatures,
-                            pkg.mSignatures) != PackageManager.SIGNATURE_MATCH) {
+                    // "updating same package" could also involve key-rotation.
+                    final boolean sigsOk;
+                    if (!bp.sourcePackage.equals(pkg.packageName)
+                            || !(bp.packageSetting instanceof PackageSetting)
+                            || !bp.packageSetting.keySetData.isUsingUpgradeKeySets()
+                            || ((PackageSetting) bp.packageSetting).sharedUser != null) {
+                        sigsOk = compareSignatures(bp.packageSetting.signatures.mSignatures,
+                                pkg.mSignatures) == PackageManager.SIGNATURE_MATCH;
+                    } else {
+                        sigsOk = checkUpgradeKeySetLP((PackageSetting) bp.packageSetting, pkg);
+                    }
+                    if (!sigsOk) {
                         // If the owning package is the system itself, we log but allow
                         // install to proceed; we fail the install on all other permission
                         // redefinitions.
@@ -10436,7 +10225,7 @@
             }
 
             // Check if installing already existing package
-            if ((pFlags&PackageManager.INSTALL_REPLACE_EXISTING) != 0) {
+            if ((installFlags & PackageManager.INSTALL_REPLACE_EXISTING) != 0) {
                 String oldName = mSettings.mRenamedPackages.get(pkgName);
                 if (pkg.mOriginalPackages != null
                         && pkg.mOriginalPackages.contains(oldName)
@@ -10482,11 +10271,11 @@
         }
 
         if (replace) {
-            replacePackageLI(pkg, parseFlags, scanMode, args.user,
+            replacePackageLI(pkg, parseFlags, scanFlags | SCAN_REPLACING, args.user,
                     installerPackageName, res);
         } else {
-            installNewPackageLI(pkg, parseFlags, scanMode | SCAN_DELETE_DATA_ON_FAILURES, args.user,
-                    installerPackageName, res);
+            installNewPackageLI(pkg, parseFlags, scanFlags | SCAN_DELETE_DATA_ON_FAILURES,
+                    args.user, installerPackageName, res);
         }
         synchronized (mPackages) {
             final PackageSetting ps = mSettings.mPackages.get(pkgName);
@@ -10922,7 +10711,7 @@
 
         final PackageParser.Package newPkg;
         try {
-            newPkg = scanPackageLI(disabledPs.codePath, parseFlags, SCAN_MONITOR | SCAN_NO_PATHS, 0, null);
+            newPkg = scanPackageLI(disabledPs.codePath, parseFlags, SCAN_NO_PATHS, 0, null);
         } catch (PackageManagerException e) {
             Slog.w(TAG, "Failed to restore system package:" + newPs.name + ": " + e.getMessage());
             return false;
@@ -10971,7 +10760,8 @@
         if (deleteCodeAndResources && (outInfo != null)) {
             outInfo.args = createInstallArgsForExisting(packageFlagsToInstallFlags(ps),
                     ps.codePathString, ps.resourcePathString, ps.legacyNativeLibraryPathString,
-                    getAppDexInstructionSets(ps), isMultiArch(ps));
+                    getAppDexInstructionSets(ps));
+            if (DEBUG_SD_INSTALL) Slog.i(TAG, "args=" + outInfo.args);
         }
         return true;
     }
@@ -11196,7 +10986,7 @@
             final IPackageDataObserver observer, final int userId) {
         mContext.enforceCallingOrSelfPermission(
                 android.Manifest.permission.CLEAR_APP_USER_DATA, null);
-        enforceCrossUserPermission(Binder.getCallingUid(), userId, true, "clear application data");
+        enforceCrossUserPermission(Binder.getCallingUid(), userId, true, false, "clear application data");
         // Queue up an async operation since the package deletion may take a little while.
         mHandler.post(new Runnable() {
             public void run() {
@@ -11230,45 +11020,53 @@
             Slog.w(TAG, "Attempt to delete null packageName.");
             return false;
         }
-        PackageParser.Package p;
-        boolean dataOnly = false;
-        final int appId;
+
+        // Try finding details about the requested package
+        PackageParser.Package pkg;
         synchronized (mPackages) {
-            p = mPackages.get(packageName);
-            if (p == null) {
-                dataOnly = true;
-                PackageSetting ps = mSettings.mPackages.get(packageName);
-                if ((ps == null) || (ps.pkg == null)) {
-                    Slog.w(TAG, "Package named '" + packageName + "' doesn't exist.");
-                    return false;
+            pkg = mPackages.get(packageName);
+            if (pkg == null) {
+                final PackageSetting ps = mSettings.mPackages.get(packageName);
+                if (ps != null) {
+                    pkg = ps.pkg;
                 }
-                p = ps.pkg;
-            }
-            if (!dataOnly) {
-                // need to check this only for fully installed applications
-                if (p == null) {
-                    Slog.w(TAG, "Package named '" + packageName + "' doesn't exist.");
-                    return false;
-                }
-                final ApplicationInfo applicationInfo = p.applicationInfo;
-                if (applicationInfo == null) {
-                    Slog.w(TAG, "Package " + packageName + " has no applicationInfo.");
-                    return false;
-                }
-            }
-            if (p != null && p.applicationInfo != null) {
-                appId = p.applicationInfo.uid;
-            } else {
-                appId = -1;
             }
         }
+
+        if (pkg == null) {
+            Slog.w(TAG, "Package named '" + packageName + "' doesn't exist.");
+        }
+
+        // Always delete data directories for package, even if we found no other
+        // record of app. This helps users recover from UID mismatches without
+        // resorting to a full data wipe.
         int retCode = mInstaller.clearUserData(packageName, userId);
         if (retCode < 0) {
-            Slog.w(TAG, "Couldn't remove cache files for package: "
-                    + packageName);
+            Slog.w(TAG, "Couldn't remove cache files for package: " + packageName);
             return false;
         }
-        removeKeystoreDataIfNeeded(userId, appId);
+
+        if (pkg == null) {
+            return false;
+        }
+
+        if (pkg != null && pkg.applicationInfo != null) {
+            final int appId = pkg.applicationInfo.uid;
+            removeKeystoreDataIfNeeded(userId, appId);
+        }
+
+        // Create a native library symlink only if we have native libraries
+        // and if the native libraries are 32 bit libraries. We do not provide
+        // this symlink for 64 bit libraries.
+        if (pkg != null && pkg.applicationInfo.primaryCpuAbi != null &&
+                !VMRuntime.is64BitAbi(pkg.applicationInfo.primaryCpuAbi)) {
+            final String nativeLibPath = pkg.applicationInfo.nativeLibraryDir;
+            if (mInstaller.linkNativeLibraryDirectory(pkg.packageName, nativeLibPath, userId) < 0) {
+                Slog.w(TAG, "Failed linking native library dir");
+                return false;
+            }
+        }
+
         return true;
     }
 
@@ -11483,7 +11281,7 @@
             String opname) {
         // writer
         int callingUid = Binder.getCallingUid();
-        enforceCrossUserPermission(callingUid, userId, true, "add preferred activity");
+        enforceCrossUserPermission(callingUid, userId, true, false, "add preferred activity");
         if (filter.countActions() == 0) {
             Slog.w(TAG, "Cannot set a preferred activity with no filter actions");
             return;
@@ -11528,7 +11326,7 @@
         }
 
         final int callingUid = Binder.getCallingUid();
-        enforceCrossUserPermission(callingUid, userId, true, "replace preferred activity");
+        enforceCrossUserPermission(callingUid, userId, true, false, "replace preferred activity");
         synchronized (mPackages) {
             if (mContext.checkCallingOrSelfPermission(
                     android.Manifest.permission.SET_PREFERRED_APPLICATIONS)
@@ -11582,18 +11380,20 @@
                     }
                 }
 
-                if (DEBUG_PREFERRED) {
-                    Slog.i(TAG, existing.size() + " existing preferred matches for:");
-                    filter.dump(new LogPrinter(Log.INFO, TAG), "  ");
-                }
-                for (int i = 0; i < existing.size(); i++) {
-                    PreferredActivity pa = existing.get(i);
+                if (existing != null) {
                     if (DEBUG_PREFERRED) {
-                        Slog.i(TAG, "Removing existing preferred activity "
-                                + pa.mPref.mComponent + ":");
-                        pa.dump(new LogPrinter(Log.INFO, TAG), "  ");
+                        Slog.i(TAG, existing.size() + " existing preferred matches for:");
+                        filter.dump(new LogPrinter(Log.INFO, TAG), "  ");
                     }
-                    pir.removeFilter(pa);
+                    for (int i = 0; i < existing.size(); i++) {
+                        PreferredActivity pa = existing.get(i);
+                        if (DEBUG_PREFERRED) {
+                            Slog.i(TAG, "Removing existing preferred activity "
+                                    + pa.mPref.mComponent + ":");
+                            pa.dump(new LogPrinter(Log.INFO, TAG), "  ");
+                        }
+                        pir.removeFilter(pa);
+                    }
                 }
             }
             addPreferredActivityInternal(filter, match, set, activity, true, userId,
@@ -11667,6 +11467,7 @@
 
     @Override
     public void resetPreferredActivities(int userId) {
+        /* TODO: Actually use userId. Why is it being passed in? */
         mContext.enforceCallingOrSelfPermission(
                 android.Manifest.permission.SET_PREFERRED_APPLICATIONS, null);
         // writer
@@ -11781,6 +11582,7 @@
                         android.Manifest.permission.INTERACT_ACROSS_USERS_FULL, null);
         int callingUid = Binder.getCallingUid();
         enforceOwnerRights(ownerPackage, ownerUserId, callingUid);
+        enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, callingUid, sourceUserId);
         if (intentFilter.countActions() == 0) {
             Slog.w(TAG, "Cannot set a crossProfile intent filter with no filter actions");
             return;
@@ -11794,30 +11596,13 @@
     }
 
     @Override
-    public void addCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId) {
-        mContext.enforceCallingOrSelfPermission(
-                        android.Manifest.permission.INTERACT_ACROSS_USERS_FULL, null);
-        mSettings.addCrossProfilePackage(packageName, sourceUserId, targetUserId);
-        mSettings.writePackageRestrictionsLPr(sourceUserId);
-    }
-
-    @Override
-    public void removeCrossProfileIntentsForPackage(String packageName,
-            int sourceUserId, int targetUserId) {
-        mContext.enforceCallingOrSelfPermission(
-                        android.Manifest.permission.INTERACT_ACROSS_USERS_FULL, null);
-        mSettings.removeCrossProfilePackage(packageName, sourceUserId, targetUserId);
-        mSettings.writePackageRestrictionsLPr(sourceUserId);
-    }
-
-    @Override
     public void clearCrossProfileIntentFilters(int sourceUserId, String ownerPackage,
             int ownerUserId) {
         mContext.enforceCallingOrSelfPermission(
                         android.Manifest.permission.INTERACT_ACROSS_USERS_FULL, null);
         int callingUid = Binder.getCallingUid();
         enforceOwnerRights(ownerPackage, ownerUserId, callingUid);
+        enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, callingUid, sourceUserId);
         int callingUserId = UserHandle.getUserId(callingUid);
         synchronized (mPackages) {
             CrossProfileIntentResolver resolver =
@@ -11880,47 +11665,6 @@
                         preferred.activityInfo.name);
     }
 
-    /**
-     * Check if calling UID is the current home app. This handles both the case
-     * where the user has selected a specific home app, and where there is only
-     * one home app.
-     */
-    public boolean checkCallerIsHomeApp() {
-        final Intent intent = new Intent(Intent.ACTION_MAIN);
-        intent.addCategory(Intent.CATEGORY_HOME);
-
-        final int callingUid = Binder.getCallingUid();
-        final int callingUserId = UserHandle.getCallingUserId();
-        final List<ResolveInfo> allHomes = queryIntentActivities(intent, null, 0, callingUserId);
-        final ResolveInfo preferredHome = findPreferredActivity(intent, null, 0, allHomes, 0, true,
-                false, false, callingUserId);
-
-        if (preferredHome != null) {
-            if (callingUid == preferredHome.activityInfo.applicationInfo.uid) {
-                return true;
-            }
-        } else {
-            for (ResolveInfo info : allHomes) {
-                if (callingUid == info.activityInfo.applicationInfo.uid) {
-                    return true;
-                }
-            }
-        }
-
-        return false;
-    }
-
-    /**
-     * Enforce that calling UID is the current home app. This handles both the
-     * case where the user has selected a specific home app, and where there is
-     * only one home app.
-     */
-    public void enforceCallerIsHomeApp() {
-        if (!checkCallerIsHomeApp()) {
-            throw new SecurityException("Caller is not currently selected home app");
-        }
-    }
-
     @Override
     public void setApplicationEnabledSetting(String appPackageName,
             int newState, int flags, int userId, String callingPackage) {
@@ -11953,7 +11697,7 @@
         final int uid = Binder.getCallingUid();
         final int permission = mContext.checkCallingOrSelfPermission(
                 android.Manifest.permission.CHANGE_COMPONENT_ENABLED_STATE);
-        enforceCrossUserPermission(uid, userId, false, "set enabled");
+        enforceCrossUserPermission(uid, userId, false, true, "set enabled");
         final boolean allowedByPermission = (permission == PackageManager.PERMISSION_GRANTED);
         boolean sendNow = false;
         boolean isApp = (className == null);
@@ -12087,7 +11831,7 @@
         final int permission = mContext.checkCallingOrSelfPermission(
                 android.Manifest.permission.CHANGE_COMPONENT_ENABLED_STATE);
         final boolean allowedByPermission = (permission == PackageManager.PERMISSION_GRANTED);
-        enforceCrossUserPermission(uid, userId, true, "stop package");
+        enforceCrossUserPermission(uid, userId, true, true, "stop package");
         // writer
         synchronized (mPackages) {
             if (mSettings.setPackageStoppedStateLPw(packageName, stopped, allowedByPermission,
@@ -12109,7 +11853,7 @@
     public int getApplicationEnabledSetting(String packageName, int userId) {
         if (!sUserManager.exists(userId)) return COMPONENT_ENABLED_STATE_DISABLED;
         int uid = Binder.getCallingUid();
-        enforceCrossUserPermission(uid, userId, false, "get enabled");
+        enforceCrossUserPermission(uid, userId, false, false, "get enabled");
         // reader
         synchronized (mPackages) {
             return mSettings.getApplicationEnabledSettingLPr(packageName, userId);
@@ -12120,7 +11864,7 @@
     public int getComponentEnabledSetting(ComponentName componentName, int userId) {
         if (!sUserManager.exists(userId)) return COMPONENT_ENABLED_STATE_DISABLED;
         int uid = Binder.getCallingUid();
-        enforceCrossUserPermission(uid, userId, false, "get component enabled");
+        enforceCrossUserPermission(uid, userId, false, false, "get component enabled");
         // reader
         synchronized (mPackages) {
             return mSettings.getComponentEnabledSettingLPr(componentName, userId);
@@ -12180,6 +11924,14 @@
             }
         }
         sUserManager.systemReady();
+
+        // Kick off any messages waiting for system ready
+        if (mPostSystemReadyMessages != null) {
+            for (Message msg : mPostSystemReadyMessages) {
+                msg.sendToTarget();
+            }
+            mPostSystemReadyMessages = null;
+        }
     }
 
     @Override
@@ -12374,14 +12126,14 @@
                 dumpState.setDump(DumpState.DUMP_VERSION);
             } else if ("k".equals(cmd) || "keysets".equals(cmd)) {
                 dumpState.setDump(DumpState.DUMP_KEYSETS);
+            } else if ("installs".equals(cmd)) {
+                dumpState.setDump(DumpState.DUMP_INSTALLS);
             } else if ("write".equals(cmd)) {
                 synchronized (mPackages) {
                     mSettings.writeLPr();
                     pw.println("Settings written.");
                     return;
                 }
-            } else if ("installs".equals(cmd)) {
-                dumpState.setDump(DumpState.DUMP_INSTALLS);
             }
         }
 
@@ -12613,7 +12365,9 @@
                 mSettings.dumpSharedUsersLPr(pw, packageName, dumpState);
             }
 
-            if (!checkin && dumpState.isDumping(DumpState.DUMP_INSTALLS)) {
+            if (!checkin && dumpState.isDumping(DumpState.DUMP_INSTALLS) && packageName == null) {
+                // XXX should handle packageName != null by dumping only install data that
+                // the given package is involved with.
                 if (dumpState.onTitlePrinted()) pw.println();
                 mInstallerService.dump(new IndentingPrintWriter(pw, "  ", 120));
             }
@@ -12655,7 +12409,7 @@
 
     private boolean mMediaMounted = false;
 
-    private String getEncryptKey() {
+    static String getEncryptKey() {
         try {
             String sdEncKey = SystemKeyStore.getInstance().retrieveKeyHexString(
                     SD_ENCRYPTION_KEYSTORE_NAME);
@@ -12675,30 +12429,6 @@
             Slog.e(TAG, "Failed to retrieve encryption keys with exception: " + ioe);
             return null;
         }
-
-    }
-
-    /* package */static String getTempContainerId() {
-        int tmpIdx = 1;
-        String list[] = PackageHelper.getSecureContainerList();
-        if (list != null) {
-            for (final String name : list) {
-                // Ignore null and non-temporary container entries
-                if (name == null || !name.startsWith(mTempContainerPrefix)) {
-                    continue;
-                }
-
-                String subStr = name.substring(mTempContainerPrefix.length());
-                try {
-                    int cid = Integer.parseInt(subStr);
-                    if (cid >= tmpIdx) {
-                        tmpIdx = cid + 1;
-                    }
-                } catch (NumberFormatException e) {
-                }
-            }
-        }
-        return mTempContainerPrefix + tmpIdx;
     }
 
     /*
@@ -12756,31 +12486,27 @@
      */
     private void updateExternalMediaStatusInner(boolean isMounted, boolean reportStatus,
             boolean externalStorage) {
-        // Collection of uids
-        int uidArr[] = null;
-        // Collection of stale containers
-        HashSet<String> removeCids = new HashSet<String>();
-        // Collection of packages on external media with valid containers.
-        HashMap<AsecInstallArgs, String> processCids = new HashMap<AsecInstallArgs, String>();
-        // Get list of secure containers.
-        final String list[] = PackageHelper.getSecureContainerList();
-        if (list == null || list.length == 0) {
-            Log.i(TAG, "No secure containers on sdcard");
+        ArrayMap<AsecInstallArgs, String> processCids = new ArrayMap<>();
+        int[] uidArr = EmptyArray.INT;
+
+        final String[] list = PackageHelper.getSecureContainerList();
+        if (ArrayUtils.isEmpty(list)) {
+            Log.i(TAG, "No secure containers found");
         } else {
             // Process list of secure containers and categorize them
             // as active or stale based on their package internal state.
-            int uidList[] = new int[list.length];
-            int num = 0;
+
             // reader
             synchronized (mPackages) {
                 for (String cid : list) {
+                    // Leave stages untouched for now; installer service owns them
+                    if (PackageInstallerService.isStageName(cid)) continue;
+
                     if (DEBUG_SD_INSTALL)
                         Log.i(TAG, "Processing container " + cid);
                     String pkgName = getAsecPackageName(cid);
                     if (pkgName == null) {
-                        if (DEBUG_SD_INSTALL)
-                            Log.i(TAG, "Container : " + cid + " stale");
-                        removeCids.add(cid);
+                        Slog.i(TAG, "Found stale container " + cid + " with no package name");
                         continue;
                     }
                     if (DEBUG_SD_INSTALL)
@@ -12788,8 +12514,7 @@
 
                     final PackageSetting ps = mSettings.mPackages.get(pkgName);
                     if (ps == null) {
-                        Log.i(TAG, "Deleting container with no matching settings " + cid);
-                        removeCids.add(cid);
+                        Slog.i(TAG, "Found stale container " + cid + " with no matching settings");
                         continue;
                     }
 
@@ -12802,10 +12527,11 @@
                     }
 
                     final AsecInstallArgs args = new AsecInstallArgs(cid,
-                            getAppDexInstructionSets(ps), isForwardLocked(ps), isMultiArch(ps));
+                            getAppDexInstructionSets(ps), isForwardLocked(ps));
                     // The package status is changed only if the code path
                     // matches between settings and the container id.
-                    if (ps.codePathString != null && ps.codePathString.equals(args.getCodePath())) {
+                    if (ps.codePathString != null
+                            && ps.codePathString.startsWith(args.getCodePath())) {
                         if (DEBUG_SD_INSTALL) {
                             Log.i(TAG, "Container : " + cid + " corresponds to pkg : " + pkgName
                                     + " at code path: " + ps.codePathString);
@@ -12815,35 +12541,25 @@
                         processCids.put(args, ps.codePathString);
                         final int uid = ps.appId;
                         if (uid != -1) {
-                            uidList[num++] = uid;
+                            uidArr = ArrayUtils.appendInt(uidArr, uid);
                         }
                     } else {
-                        Log.i(TAG, "Deleting stale container for " + cid);
-                        removeCids.add(cid);
+                        Slog.i(TAG, "Found stale container " + cid + ": expected codePath="
+                                + ps.codePathString);
                     }
                 }
             }
 
-            if (num > 0) {
-                // Sort uid list
-                Arrays.sort(uidList, 0, num);
-                // Throw away duplicates
-                uidArr = new int[num];
-                uidArr[0] = uidList[0];
-                int di = 0;
-                for (int i = 1; i < num; i++) {
-                    if (uidList[i - 1] != uidList[i]) {
-                        uidArr[di++] = uidList[i];
-                    }
-                }
-            }
+            Arrays.sort(uidArr);
         }
+
         // Process packages with valid entries.
         if (isMounted) {
             if (DEBUG_SD_INSTALL)
                 Log.i(TAG, "Loading packages");
-            loadMediaPackages(processCids, uidArr, removeCids);
+            loadMediaPackages(processCids, uidArr);
             startCleaningPackages();
+            mInstallerService.onSecureContainersAvailable();
         } else {
             if (DEBUG_SD_INSTALL)
                 Log.i(TAG, "Unloading packages");
@@ -12851,8 +12567,8 @@
         }
     }
 
-   private void sendResourcesChangedBroadcast(boolean mediaStatus, boolean replacing,
-           ArrayList<String> pkgList, int uidArr[], IIntentReceiver finishedReceiver) {
+    private void sendResourcesChangedBroadcast(boolean mediaStatus, boolean replacing,
+            ArrayList<String> pkgList, int uidArr[], IIntentReceiver finishedReceiver) {
         int size = pkgList.size();
         if (size > 0) {
             // Send broadcasts here
@@ -12877,11 +12593,10 @@
      * the cid is added to list of removeCids. We currently don't delete stale
      * containers.
      */
-   private void loadMediaPackages(HashMap<AsecInstallArgs, String> processCids, int uidArr[],
-            HashSet<String> removeCids) {
+    private void loadMediaPackages(ArrayMap<AsecInstallArgs, String> processCids, int[] uidArr) {
         ArrayList<String> pkgList = new ArrayList<String>();
         Set<AsecInstallArgs> keys = processCids.keySet();
-        boolean doGc = false;
+
         for (AsecInstallArgs args : keys) {
             String codePath = processCids.get(args);
             if (DEBUG_SD_INSTALL)
@@ -12895,7 +12610,7 @@
                     continue;
                 }
                 // Check code path here.
-                if (codePath == null || !codePath.equals(args.getCodePath())) {
+                if (codePath == null || !codePath.startsWith(args.getCodePath())) {
                     Slog.e(TAG, "Container " + args.cid + " cachepath " + args.getCodePath()
                             + " does not match one in settings " + codePath);
                     continue;
@@ -12909,7 +12624,6 @@
                     parseFlags |= PackageParser.PARSE_FORWARD_LOCK;
                 }
 
-                doGc = true;
                 synchronized (mInstallLock) {
                     PackageParser.Package pkg = null;
                     try {
@@ -12939,9 +12653,7 @@
 
             } finally {
                 if (retCode != PackageManager.INSTALL_SUCCEEDED) {
-                    // Don't destroy container here. Wait till gc clears things
-                    // up.
-                    removeCids.add(args.cid);
+                    Log.w(TAG, "Container " + args.cid + " is stale, retCode=" + retCode);
                 }
             }
         }
@@ -12976,21 +12688,6 @@
         if (pkgList.size() > 0) {
             sendResourcesChangedBroadcast(true, false, pkgList, uidArr, null);
         }
-        // Force gc to avoid any stale parser references that we might have.
-        if (doGc) {
-            Runtime.getRuntime().gc();
-        }
-        // List stale containers and destroy stale temporary containers.
-        if (removeCids != null) {
-            for (String cid : removeCids) {
-                if (cid.startsWith(mTempContainerPrefix)) {
-                    Log.i(TAG, "Destroying stale temporary container " + cid);
-                    PackageHelper.destroySdDir(cid);
-                } else {
-                    Log.w(TAG, "Container " + cid + " is stale");
-               }
-           }
-        }
     }
 
    /*
@@ -13014,7 +12711,7 @@
      * that we always have to post this message if status has been requested no
      * matter what.
      */
-    private void unloadMediaPackages(HashMap<AsecInstallArgs, String> processCids, int uidArr[],
+    private void unloadMediaPackages(ArrayMap<AsecInstallArgs, String> processCids, int uidArr[],
             final boolean reportStatus) {
         if (DEBUG_SD_INSTALL)
             Log.i(TAG, "unloading media packages");
@@ -13075,12 +12772,18 @@
         mContext.enforceCallingOrSelfPermission(android.Manifest.permission.MOVE_PACKAGE, null);
         UserHandle user = new UserHandle(UserHandle.getCallingUserId());
         int returnCode = PackageManager.MOVE_SUCCEEDED;
-        int currFlags = 0;
-        int newFlags = 0;
+        int currInstallFlags = 0;
+        int newInstallFlags = 0;
+
+        File codeFile = null;
+        String installerPackageName = null;
+        String packageAbiOverride = null;
+
         // reader
         synchronized (mPackages) {
-            PackageParser.Package pkg = mPackages.get(packageName);
-            if (pkg == null) {
+            final PackageParser.Package pkg = mPackages.get(packageName);
+            final PackageSetting ps = mSettings.mPackages.get(packageName);
+            if (pkg == null || ps == null) {
                 returnCode = PackageManager.MOVE_FAILED_DOESNT_EXIST;
             } else {
                 // Disable moving fwd locked apps and system packages
@@ -13097,18 +12800,18 @@
                         Slog.w(TAG, "Ambigous flags specified for move location.");
                         returnCode = PackageManager.MOVE_FAILED_INVALID_LOCATION;
                     } else {
-                        newFlags = (flags & PackageManager.MOVE_EXTERNAL_MEDIA) != 0 ? PackageManager.INSTALL_EXTERNAL
-                                : PackageManager.INSTALL_INTERNAL;
-                        currFlags = isExternal(pkg) ? PackageManager.INSTALL_EXTERNAL
-                                : PackageManager.INSTALL_INTERNAL;
+                        newInstallFlags = (flags & PackageManager.MOVE_EXTERNAL_MEDIA) != 0
+                                ? PackageManager.INSTALL_EXTERNAL : PackageManager.INSTALL_INTERNAL;
+                        currInstallFlags = isExternal(pkg)
+                                ? PackageManager.INSTALL_EXTERNAL : PackageManager.INSTALL_INTERNAL;
 
-                        if (newFlags == currFlags) {
+                        if (newInstallFlags == currInstallFlags) {
                             Slog.w(TAG, "No move required. Trying to move to same location");
                             returnCode = PackageManager.MOVE_FAILED_INVALID_LOCATION;
                         } else {
                             if (isForwardLocked(pkg)) {
-                                currFlags |= PackageManager.INSTALL_FORWARD_LOCK;
-                                newFlags |= PackageManager.INSTALL_FORWARD_LOCK;
+                                currInstallFlags |= PackageManager.INSTALL_FORWARD_LOCK;
+                                newInstallFlags |= PackageManager.INSTALL_FORWARD_LOCK;
                             }
                         }
                     }
@@ -13116,217 +12819,67 @@
                         pkg.mOperationPending = true;
                     }
                 }
-            }
 
-            /*
-             * TODO this next block probably shouldn't be inside the lock. We
-             * can't guarantee these won't change after this is fired off
-             * anyway.
-             */
-            if (returnCode != PackageManager.MOVE_SUCCEEDED) {
-                processPendingMove(new MoveParams(null, observer, 0, packageName, null, -1, user, false),
-                        returnCode);
-            } else {
-                Message msg = mHandler.obtainMessage(INIT_COPY);
-                final String[] instructionSets = getAppDexInstructionSets(pkg.applicationInfo);
-                final boolean multiArch = isMultiArch(pkg.applicationInfo);
-                InstallArgs srcArgs = createInstallArgsForExisting(currFlags,
-                        pkg.applicationInfo.getCodePath(), pkg.applicationInfo.getResourcePath(),
-                        pkg.applicationInfo.nativeLibraryRootDir, instructionSets, multiArch);
-                MoveParams mp = new MoveParams(srcArgs, observer, newFlags, packageName,
-                        instructionSets, pkg.applicationInfo.uid, user, multiArch);
-                msg.obj = mp;
-                mHandler.sendMessage(msg);
+                codeFile = new File(pkg.codePath);
+                installerPackageName = ps.installerPackageName;
+                packageAbiOverride = ps.cpuAbiOverrideString;
             }
         }
-    }
 
-    private void processPendingMove(final MoveParams mp, final int currentStatus) {
-        // Queue up an async operation since the package deletion may take a
-        // little while.
-        mHandler.post(new Runnable() {
-            public void run() {
-                // TODO fix this; this does nothing.
-                mHandler.removeCallbacks(this);
-                int returnCode = currentStatus;
-                if (currentStatus == PackageManager.MOVE_SUCCEEDED) {
-                    int uidArr[] = null;
-                    ArrayList<String> pkgList = null;
-                    synchronized (mPackages) {
-                        PackageParser.Package pkg = mPackages.get(mp.packageName);
-                        if (pkg == null) {
-                            Slog.w(TAG, " Package " + mp.packageName
-                                    + " doesn't exist. Aborting move");
-                            returnCode = PackageManager.MOVE_FAILED_DOESNT_EXIST;
-                        } else if (!mp.srcArgs.getCodePath().equals(
-                                pkg.applicationInfo.getCodePath())) {
-                            Slog.w(TAG, "Package " + mp.packageName + " code path changed from "
-                                    + mp.srcArgs.getCodePath() + " to "
-                                    + pkg.applicationInfo.getCodePath()
-                                    + " Aborting move and returning error");
-                            returnCode = PackageManager.MOVE_FAILED_INTERNAL_ERROR;
-                        } else {
-                            uidArr = new int[] {
-                                pkg.applicationInfo.uid
-                            };
-                            pkgList = new ArrayList<String>();
-                            pkgList.add(mp.packageName);
-                        }
-                    }
-                    if (returnCode == PackageManager.MOVE_SUCCEEDED) {
-                        // Send resources unavailable broadcast
-                        sendResourcesChangedBroadcast(false, true, pkgList, uidArr, null);
-                        // Update package code and resource paths
-                        synchronized (mInstallLock) {
-                            synchronized (mPackages) {
-                                PackageParser.Package pkg = mPackages.get(mp.packageName);
-                                // Recheck for package again.
-                                if (pkg == null) {
-                                    Slog.w(TAG, " Package " + mp.packageName
-                                            + " doesn't exist. Aborting move");
-                                    returnCode = PackageManager.MOVE_FAILED_DOESNT_EXIST;
-                                } else if (!mp.srcArgs.getCodePath().equals(
-                                        pkg.applicationInfo.getCodePath())) {
-                                    Slog.w(TAG, "Package " + mp.packageName
-                                            + " code path changed from " + mp.srcArgs.getCodePath()
-                                            + " to " + pkg.applicationInfo.getCodePath()
-                                            + " Aborting move and returning error");
-                                    returnCode = PackageManager.MOVE_FAILED_INTERNAL_ERROR;
-                                } else {
-                                    final String oldCodePath = pkg.codePath;
-                                    final String newCodePath = mp.targetArgs.getCodePath();
-                                    final String newResPath = mp.targetArgs.getResourcePath();
-                                    // TODO: This assumes the new style of installation.
-                                    // should we look at legacyNativeLibraryPath ?
-                                    final String newNativeRoot = new File(pkg.codePath, LIB_DIR_NAME).getAbsolutePath();
-                                    final File newNativeDir = new File(newNativeRoot);
+        if (returnCode != PackageManager.MOVE_SUCCEEDED) {
+            try {
+                observer.packageMoved(packageName, returnCode);
+            } catch (RemoteException ignored) {
+            }
+            return;
+        }
 
-                                    if (!isForwardLocked(pkg) && !isExternal(pkg)) {
-                                        // TODO(multiArch): Fix this so that it looks at the existing
-                                        // recorded CPU abis from the package. There's no need for a separate
-                                        // round of ABI scanning here.
-                                        NativeLibraryHelper.Handle handle = null;
-                                        try {
-                                            handle = NativeLibraryHelper.Handle.create(
-                                                    new File(newCodePath));
-                                            final int abi = NativeLibraryHelper.findSupportedAbi(
-                                                    handle, Build.SUPPORTED_ABIS);
-                                            if (abi >= 0) {
-                                                NativeLibraryHelper.copyNativeBinariesIfNeededLI(
-                                                        handle, newNativeDir, Build.SUPPORTED_ABIS[abi]);
-                                            }
-                                        } catch (IOException ioe) {
-                                            Slog.w(TAG, "Unable to extract native libs for package :"
-                                                    + mp.packageName, ioe);
-                                            returnCode = PackageManager.MOVE_FAILED_INTERNAL_ERROR;
-                                        } finally {
-                                            IoUtils.closeQuietly(handle);
-                                        }
-                                    }
+        final IPackageInstallObserver2 installObserver = new IPackageInstallObserver2.Stub() {
+            @Override
+            public void onUserActionRequired(Intent intent) throws RemoteException {
+                throw new IllegalStateException();
+            }
 
-                                    final int[] users = sUserManager.getUserIds();
-                                    if (returnCode == PackageManager.MOVE_SUCCEEDED) {
-                                        for (int user : users) {
-                                            // TODO(multiArch): Fix this so that it links to the
-                                            // correct directory. We're currently pointing to root. but we
-                                            // must point to the arch specific subdirectory (if applicable).
-                                            //
-                                            // TODO(multiArch): Bogus reference to nativeLibraryDir.
-                                            if (mInstaller.linkNativeLibraryDirectory(pkg.packageName,
-                                                    newNativeRoot, user) < 0) {
-                                                returnCode = PackageManager.MOVE_FAILED_INSUFFICIENT_STORAGE;
-                                            }
-                                        }
-                                    }
+            @Override
+            public void onPackageInstalled(String basePackageName, int returnCode, String msg,
+                    Bundle extras) throws RemoteException {
+                Slog.d(TAG, "Install result for move: "
+                        + PackageManager.installStatusToString(returnCode, msg));
 
-                                    if (returnCode == PackageManager.MOVE_SUCCEEDED) {
-                                        pkg.codePath = newCodePath;
-                                        pkg.baseCodePath = newCodePath;
-                                        // Move dex files around
-                                        if (moveDexFilesLI(oldCodePath, pkg) != PackageManager.INSTALL_SUCCEEDED) {
-                                            // Moving of dex files failed. Set
-                                            // error code and abort move.
-                                            pkg.codePath = oldCodePath;
-                                            pkg.baseCodePath = oldCodePath;
-                                            returnCode = PackageManager.MOVE_FAILED_INSUFFICIENT_STORAGE;
-                                        }
-                                    }
-
-                                    if (returnCode == PackageManager.MOVE_SUCCEEDED) {
-                                        pkg.applicationInfo.setCodePath(newCodePath);
-                                        pkg.applicationInfo.setBaseCodePath(newCodePath);
-                                        pkg.applicationInfo.setSplitCodePaths(null);
-                                        pkg.applicationInfo.setResourcePath(newResPath);
-                                        pkg.applicationInfo.setBaseResourcePath(newResPath);
-                                        pkg.applicationInfo.setSplitResourcePaths(null);
-
-                                        PackageSetting ps = (PackageSetting) pkg.mExtras;
-                                        ps.codePath = new File(pkg.applicationInfo.getCodePath());
-                                        ps.codePathString = ps.codePath.getPath();
-                                        ps.resourcePath = new File(pkg.applicationInfo.getResourcePath());
-                                        ps.resourcePathString = ps.resourcePath.getPath();
-
-                                        // Note that we don't have to recalculate the primary and secondary
-                                        // CPU ABIs because they must already have been calculated during the
-                                        // initial install of the app.
-                                        ps.legacyNativeLibraryPathString = null;
-
-                                        // Set the application info flag
-                                        // correctly.
-                                        if ((mp.flags & PackageManager.INSTALL_EXTERNAL) != 0) {
-                                            pkg.applicationInfo.flags |= ApplicationInfo.FLAG_EXTERNAL_STORAGE;
-                                        } else {
-                                            pkg.applicationInfo.flags &= ~ApplicationInfo.FLAG_EXTERNAL_STORAGE;
-                                        }
-                                        ps.setFlags(pkg.applicationInfo.flags);
-                                        mAppDirs.remove(oldCodePath);
-                                        mAppDirs.put(newCodePath, pkg);
-                                        // Persist settings
-                                        mSettings.writeLPr();
-                                    }
-                                }
-                            }
-                        }
-                        // Send resources available broadcast
-                        sendResourcesChangedBroadcast(true, false, pkgList, uidArr, null);
-                    }
-                }
-                if (returnCode != PackageManager.MOVE_SUCCEEDED) {
-                    // Clean up failed installation
-                    if (mp.targetArgs != null) {
-                        mp.targetArgs.doPostInstall(PackageManager.INSTALL_FAILED_INTERNAL_ERROR,
-                                -1);
-                    }
-                } else {
-                    // Force a gc to clear things up.
-                    Runtime.getRuntime().gc();
-                    // Delete older code
-                    synchronized (mInstallLock) {
-                        mp.srcArgs.doPostDeleteLI(true);
+                // We usually have a new package now after the install, but if
+                // we failed we need to clear the pending flag on the original
+                // package object.
+                synchronized (mPackages) {
+                    final PackageParser.Package pkg = mPackages.get(packageName);
+                    if (pkg != null) {
+                        pkg.mOperationPending = false;
                     }
                 }
 
-                // Allow more operations on this file if we didn't fail because
-                // an operation was already pending for this package.
-                if (returnCode != PackageManager.MOVE_FAILED_OPERATION_PENDING) {
-                    synchronized (mPackages) {
-                        PackageParser.Package pkg = mPackages.get(mp.packageName);
-                        if (pkg != null) {
-                            pkg.mOperationPending = false;
-                       }
-                   }
-                }
-
-                IPackageMoveObserver observer = mp.observer;
-                if (observer != null) {
-                    try {
-                        observer.packageMoved(mp.packageName, returnCode);
-                    } catch (RemoteException e) {
-                        Log.i(TAG, "Observer no longer exists.");
-                    }
+                final int status = PackageManager.installStatusToPublicStatus(returnCode);
+                switch (status) {
+                    case PackageInstaller.STATUS_SUCCESS:
+                        observer.packageMoved(packageName, PackageManager.MOVE_SUCCEEDED);
+                        break;
+                    case PackageInstaller.STATUS_FAILURE_STORAGE:
+                        observer.packageMoved(packageName, PackageManager.MOVE_FAILED_INSUFFICIENT_STORAGE);
+                        break;
+                    default:
+                        observer.packageMoved(packageName, PackageManager.MOVE_FAILED_INTERNAL_ERROR);
+                        break;
                 }
             }
-        });
+        };
+
+        // Treat a move like reinstalling an existing app, which ensures that we
+        // process everythign uniformly, like unpacking native libraries.
+        newInstallFlags |= PackageManager.INSTALL_REPLACE_EXISTING;
+
+        final Message msg = mHandler.obtainMessage(INIT_COPY);
+        final OriginInfo origin = OriginInfo.fromExistingFile(codeFile);
+        msg.obj = new InstallParams(origin, installObserver, newInstallFlags,
+                installerPackageName, null, user, packageAbiOverride);
+        mHandler.sendMessage(msg);
     }
 
     @Override
@@ -13353,7 +12906,7 @@
     }
 
     /** Called by UserManagerService */
-    void cleanUpUserLILPw(int userHandle) {
+    void cleanUpUserLILPw(UserManagerService userManager, int userHandle) {
         mDirtyUsers.remove(userHandle);
         mSettings.removeUserLPw(userHandle);
         mPendingBroadcasts.remove(userHandle);
@@ -13364,6 +12917,53 @@
             mInstaller.removeUserDataDirs(userHandle);
         }
         mUserNeedsBadging.delete(userHandle);
+        removeUnusedPackagesLILPw(userManager, userHandle);
+    }
+
+    /**
+     * We're removing userHandle and would like to remove any downloaded packages
+     * that are no longer in use by any other user.
+     * @param userHandle the user being removed
+     */
+    private void removeUnusedPackagesLILPw(UserManagerService userManager, final int userHandle) {
+        final boolean DEBUG_CLEAN_APKS = false;
+        int [] users = userManager.getUserIdsLPr();
+        Iterator<PackageSetting> psit = mSettings.mPackages.values().iterator();
+        while (psit.hasNext()) {
+            PackageSetting ps = psit.next();
+            if (ps.pkg == null) {
+                continue;
+            }
+            final String packageName = ps.pkg.packageName;
+            // Skip over if system app
+            if ((ps.pkgFlags & ApplicationInfo.FLAG_SYSTEM) != 0) {
+                continue;
+            }
+            if (DEBUG_CLEAN_APKS) {
+                Slog.i(TAG, "Checking package " + packageName);
+            }
+            boolean keep = false;
+            for (int i = 0; i < users.length; i++) {
+                if (users[i] != userHandle && ps.getInstalled(users[i])) {
+                    keep = true;
+                    if (DEBUG_CLEAN_APKS) {
+                        Slog.i(TAG, "  Keeping package " + packageName + " for user "
+                                + users[i]);
+                    }
+                    break;
+                }
+            }
+            if (!keep) {
+                if (DEBUG_CLEAN_APKS) {
+                    Slog.i(TAG, "  Removing package " + packageName);
+                }
+                mHandler.post(new Runnable() {
+                    public void run() {
+                        deletePackageX(packageName, userHandle, 0);
+                    } //end run
+                });
+            }
+        }
     }
 
     /** Called by UserManagerService */
@@ -13463,7 +13063,7 @@
     }
 
     @Override
-    public KeySetHandle getKeySetByAlias(String packageName, String alias) {
+    public KeySet getKeySetByAlias(String packageName, String alias) {
         if (packageName == null || alias == null) {
             return null;
         }
@@ -13473,18 +13073,13 @@
                 Slog.w(TAG, "KeySet requested for unknown package:" + packageName);
                 throw new IllegalArgumentException("Unknown package: " + packageName);
             }
-            if (pkg.applicationInfo.uid != Binder.getCallingUid()
-                    && Process.SYSTEM_UID != Binder.getCallingUid()) {
-                throw new SecurityException("May not access KeySets defined by"
-                        + " aliases in other applications.");
-            }
             KeySetManagerService ksms = mSettings.mKeySetManagerService;
-            return ksms.getKeySetByAliasAndPackageNameLPr(packageName, alias);
+            return new KeySet(ksms.getKeySetByAliasAndPackageNameLPr(packageName, alias));
         }
     }
 
     @Override
-    public KeySetHandle getSigningKeySet(String packageName) {
+    public KeySet getSigningKeySet(String packageName) {
         if (packageName == null) {
             return null;
         }
@@ -13499,12 +13094,12 @@
                 throw new SecurityException("May not access signing KeySet of other apps.");
             }
             KeySetManagerService ksms = mSettings.mKeySetManagerService;
-            return ksms.getSigningKeySetByPackageNameLPr(packageName);
+            return new KeySet(ksms.getSigningKeySetByPackageNameLPr(packageName));
         }
     }
 
     @Override
-    public boolean isPackageSignedByKeySet(String packageName, IBinder ks) {
+    public boolean isPackageSignedByKeySet(String packageName, KeySet ks) {
         if (packageName == null || ks == null) {
             return false;
         }
@@ -13514,16 +13109,17 @@
                 Slog.w(TAG, "KeySet requested for unknown package:" + packageName);
                 throw new IllegalArgumentException("Unknown package: " + packageName);
             }
-            if (ks instanceof KeySetHandle) {
+            IBinder ksh = ks.getToken();
+            if (ksh instanceof KeySetHandle) {
                 KeySetManagerService ksms = mSettings.mKeySetManagerService;
-                return ksms.packageIsSignedByLPr(packageName, (KeySetHandle) ks);
+                return ksms.packageIsSignedByLPr(packageName, (KeySetHandle) ksh);
             }
             return false;
         }
     }
 
     @Override
-    public boolean isPackageSignedByKeySetExactly(String packageName, IBinder ks) {
+    public boolean isPackageSignedByKeySetExactly(String packageName, KeySet ks) {
         if (packageName == null || ks == null) {
             return false;
         }
@@ -13533,9 +13129,10 @@
                 Slog.w(TAG, "KeySet requested for unknown package:" + packageName);
                 throw new IllegalArgumentException("Unknown package: " + packageName);
             }
-            if (ks instanceof KeySetHandle) {
+            IBinder ksh = ks.getToken();
+            if (ksh instanceof KeySetHandle) {
                 KeySetManagerService ksms = mSettings.mKeySetManagerService;
-                return ksms.packageIsSignedByExactlyLPr(packageName, (KeySetHandle) ks);
+                return ksms.packageIsSignedByExactlyLPr(packageName, (KeySetHandle) ksh);
             }
             return false;
         }
diff --git a/services/core/java/com/android/server/pm/Settings.java b/services/core/java/com/android/server/pm/Settings.java
index c346f71..0dadee7 100644
--- a/services/core/java/com/android/server/pm/Settings.java
+++ b/services/core/java/com/android/server/pm/Settings.java
@@ -138,10 +138,6 @@
             "persistent-preferred-activities";
     static final String TAG_CROSS_PROFILE_INTENT_FILTERS =
             "crossProfile-intent-filters";
-    private static final String TAG_CROSS_PROFILE_PACKAGE_INFO = "cross-profile-package-info";
-    private static final String CROSS_PROFILE_PACKAGE_INFO_ATTR_TARGET_USER_ID = "target-user-id";
-    private static final String CROSS_PROFILE_PACKAGE_INFO_TAG_PACKAGE_NAME = "package-name";
-    private static final String CROSS_PROFILE_PACKAGE_INFO_ATTR_PACKAGE_NAME = "value";
 
     private static final String ATTR_NAME = "name";
     private static final String ATTR_USER = "user";
@@ -249,23 +245,15 @@
      */
     private final ArrayList<PendingPackage> mPendingPackages = new ArrayList<PendingPackage>();
 
-    private final Context mContext;
-
     private final File mSystemDir;
 
     public final KeySetManagerService mKeySetManagerService = new KeySetManagerService(mPackages);
 
-    // A mapping of (sourceUserId, targetUserId, packageNames) for forwarding the intents of a
-    // package.
-    final SparseArray<SparseArray<ArrayList<String>>>
-            mCrossProfilePackageInfo = new SparseArray<SparseArray<ArrayList<String>>>();
-
     Settings(Context context) {
         this(context, Environment.getDataDirectory());
     }
 
     Settings(Context context, File dataDir) {
-        mContext = context;
         mSystemDir = new File(dataDir, "system");
         mSystemDir.mkdirs();
         FileUtils.setPermissions(mSystemDir.toString(),
@@ -282,47 +270,6 @@
         mBackupStoppedPackagesFilename = new File(mSystemDir, "packages-stopped-backup.xml");
     }
 
-    public void addCrossProfilePackage(
-            String packageName, int sourceUserId, int targetUserId) {
-        synchronized(mCrossProfilePackageInfo) {
-            SparseArray<ArrayList<String>> sourceForwardingInfo =
-                    mCrossProfilePackageInfo.get(sourceUserId);
-            if (sourceForwardingInfo == null) {
-                sourceForwardingInfo = new SparseArray<ArrayList<String>>();
-                mCrossProfilePackageInfo.put(sourceUserId, sourceForwardingInfo);
-            }
-            ArrayList<String> packageNames = sourceForwardingInfo.get(targetUserId);
-            if (packageNames == null) {
-                packageNames = new ArrayList<String>();
-                sourceForwardingInfo.put(targetUserId, packageNames);
-            }
-            if (!packageNames.contains(packageName)) {
-                packageNames.add(packageName);
-            }
-        }
-    }
-
-    public void removeCrossProfilePackage(
-            String packageName, int sourceUserId, int targetUserId) {
-        synchronized(mCrossProfilePackageInfo) {
-            SparseArray<ArrayList<String>> sourceForwardingInfo =
-                    mCrossProfilePackageInfo.get(sourceUserId);
-            if (sourceForwardingInfo == null) {
-                return;
-            }
-            ArrayList<String> packageNames = sourceForwardingInfo.get(targetUserId);
-            if (packageNames != null && packageNames.contains(packageName)) {
-                packageNames.remove(packageName);
-                if (packageNames.isEmpty()) {
-                    sourceForwardingInfo.remove(targetUserId);
-                    if (sourceForwardingInfo.size() == 0) {
-                        mCrossProfilePackageInfo.remove(sourceUserId);
-                    }
-                }
-            }
-        }
-    }
-
     PackageSetting getPackageLPw(PackageParser.Package pkg, PackageSetting origPackage,
             String realName, SharedUserSetting sharedUser, File codePath, File resourcePath,
             String legacyNativeLibraryPathString, String primaryCpuAbi, String secondaryCpuAbi,
@@ -517,6 +464,7 @@
             int vc, int pkgFlags, UserHandle installUser, boolean add,
             boolean allowInstall) {
         PackageSetting p = mPackages.get(name);
+        UserManagerService userManager = UserManagerService.getInstance();
         if (p != null) {
             p.primaryCpuAbiString = primaryCpuAbiString;
             p.secondaryCpuAbiString = secondaryCpuAbiString;
@@ -594,6 +542,7 @@
                         Slog.i(PackageManagerService.TAG, "Stopping package " + name, e);
                     }
                     List<UserInfo> users = getAllUsers();
+                    final int installUserId = installUser != null ? installUser.getIdentifier() : 0;
                     if (users != null && allowInstall) {
                         for (UserInfo user : users) {
                             // By default we consider this app to be installed
@@ -602,12 +551,10 @@
                             // original default value is true), or we are being
                             // asked to install for all users, or this is the
                             // user we are installing for.
-                            // In this context all users (USER_ALL) implies an adb install,
-                            // so we additionally check whether that is allowed for this user.
                             final boolean installed = installUser == null
-                                    || (installUser.getIdentifier() == UserHandle.USER_ALL
-                                            && (!isUnknownSourcesDisallowed(user.id)))
-                                    || installUser.getIdentifier() == user.id;
+                                    || (installUserId == UserHandle.USER_ALL
+                                        && !isAdbInstallDisallowed(userManager, user.id))
+                                    || installUserId == user.id;
                             p.setUserState(user.id, COMPONENT_ENABLED_STATE_DEFAULT,
                                     installed,
                                     true, // stopped,
@@ -673,10 +620,8 @@
                 List<UserInfo> users = getAllUsers();
                 if (users != null) {
                     for (UserInfo user : users) {
-                        // Installing for USER_ALL implies an adb install, so we
-                        // additionally check whether that is allowed for this user.
                         if ((installUser.getIdentifier() == UserHandle.USER_ALL
-                                        && (!isUnknownSourcesDisallowed(user.id)))
+                                    && !isAdbInstallDisallowed(userManager, user.id))
                                 || installUser.getIdentifier() == user.id) {
                             boolean installed = p.getInstalled(user.id);
                             if (!installed) {
@@ -691,10 +636,9 @@
         return p;
     }
 
-    boolean isUnknownSourcesDisallowed(int userId) {
-        UserManager um = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
-        return um.getUserRestrictions(new UserHandle(userId)).getBoolean(
-                UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES, false);
+    boolean isAdbInstallDisallowed(UserManagerService userManager, int userId) {
+        return userManager.hasUserRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES,
+                userId);
     }
 
     void insertPackageSettingLPw(PackageSetting p, PackageParser.Package pkg) {
@@ -1080,68 +1024,6 @@
         }
     }
 
-    private void readCrossProfilePackageInfoLPw(XmlPullParser parser, int userId)
-            throws XmlPullParserException, IOException {
-        int outerDepth = parser.getDepth();
-        int type;
-        while ((type = parser.next()) != XmlPullParser.END_DOCUMENT
-                && (type != XmlPullParser.END_TAG || parser.getDepth() > outerDepth)) {
-            if (type == XmlPullParser.END_TAG || type == XmlPullParser.TEXT) {
-                continue;
-            }
-            String tagName = parser.getName();
-            if (tagName.equals(TAG_ITEM)) {
-                String targetUserIdString = parser.getAttributeValue(null,
-                        CROSS_PROFILE_PACKAGE_INFO_ATTR_TARGET_USER_ID);
-                if (targetUserIdString == null) {
-                    String msg = "Missing element under " + TAG +": "
-                            + CROSS_PROFILE_PACKAGE_INFO_ATTR_TARGET_USER_ID + " at " +
-                            parser.getPositionDescription();
-                    PackageManagerService.reportSettingsProblem(Log.WARN, msg);
-                    continue;
-                }
-                int targetUserId = Integer.parseInt(targetUserIdString);
-                readCrossProfilePackageInfoForTargetLPw(parser, userId, targetUserId);
-            } else {
-                String msg = "Unknown element under " +  TAG_CROSS_PROFILE_PACKAGE_INFO + ": " +
-                        parser.getName();
-                PackageManagerService.reportSettingsProblem(Log.WARN, msg);
-                XmlUtils.skipCurrentTag(parser);
-            }
-        }
-    }
-
-    private void readCrossProfilePackageInfoForTargetLPw(
-            XmlPullParser parser, int sourceUserId, int targetUserId)
-            throws XmlPullParserException, IOException {
-        int outerDepth = parser.getDepth();
-        int type;
-        while ((type = parser.next()) != XmlPullParser.END_DOCUMENT
-                && (type != XmlPullParser.END_TAG || parser.getDepth() > outerDepth)) {
-            if (type == XmlPullParser.END_TAG || type == XmlPullParser.TEXT) {
-                continue;
-            }
-            String tagName = parser.getName();
-            if (tagName.equals(CROSS_PROFILE_PACKAGE_INFO_TAG_PACKAGE_NAME)) {
-                String packageName = parser.getAttributeValue(
-                        null, CROSS_PROFILE_PACKAGE_INFO_ATTR_PACKAGE_NAME);
-                if (packageName == null) {
-                    String msg = "Missing element under " + TAG +": "
-                            + CROSS_PROFILE_PACKAGE_INFO_TAG_PACKAGE_NAME + " at " +
-                            parser.getPositionDescription();
-                    PackageManagerService.reportSettingsProblem(Log.WARN, msg);
-                    continue;
-                }
-                addCrossProfilePackage(packageName, sourceUserId, targetUserId);
-            } else {
-                String msg = "Unknown element under " +  TAG_ITEM + ": " +
-                        parser.getName();
-                PackageManagerService.reportSettingsProblem(Log.WARN, msg);
-                XmlUtils.skipCurrentTag(parser);
-            }
-        }
-    }
-
     void readPackageRestrictionsLPr(int userId) {
         if (DEBUG_MU) {
             Log.i(TAG, "Reading package restrictions for user=" + userId);
@@ -1283,8 +1165,6 @@
                     readPersistentPreferredActivitiesLPw(parser, userId);
                 } else if (tagName.equals(TAG_CROSS_PROFILE_INTENT_FILTERS)) {
                     readCrossProfileIntentFiltersLPw(parser, userId);
-                } else if (tagName.equals(TAG_CROSS_PROFILE_PACKAGE_INFO)){
-                    readCrossProfilePackageInfoLPw(parser, userId);
                 } else {
                     Slog.w(PackageManagerService.TAG, "Unknown element under <stopped-packages>: "
                           + parser.getName());
@@ -1376,32 +1256,6 @@
         serializer.endTag(null, TAG_CROSS_PROFILE_INTENT_FILTERS);
     }
 
-    void writeCrossProfilePackageInfoLPr(XmlSerializer serializer, int userId)
-            throws IllegalArgumentException, IllegalStateException, IOException {
-        SparseArray<ArrayList<String>> sourceForwardingInfo = mCrossProfilePackageInfo.get(userId);
-        if (sourceForwardingInfo == null) {
-            return;
-        }
-        serializer.startTag(null, TAG_CROSS_PROFILE_PACKAGE_INFO);
-        int NI = sourceForwardingInfo.size();
-        for (int i = 0; i < NI; i++) {
-            int targetUserId = sourceForwardingInfo.keyAt(i);
-            ArrayList<String> packageNames = sourceForwardingInfo.valueAt(i);
-            serializer.startTag(null, TAG_ITEM);
-            serializer.attribute(null, CROSS_PROFILE_PACKAGE_INFO_ATTR_TARGET_USER_ID,
-                    Integer.toString(targetUserId));
-            int NJ = packageNames.size();
-            for (int j = 0; j < NJ; j++) {
-                serializer.startTag(null, CROSS_PROFILE_PACKAGE_INFO_TAG_PACKAGE_NAME);
-                serializer.attribute(null, CROSS_PROFILE_PACKAGE_INFO_ATTR_PACKAGE_NAME,
-                        packageNames.get(j));
-                serializer.endTag(null, CROSS_PROFILE_PACKAGE_INFO_TAG_PACKAGE_NAME);
-            }
-            serializer.endTag(null, TAG_ITEM);
-        }
-        serializer.endTag(null, TAG_CROSS_PROFILE_PACKAGE_INFO);
-    }
-
     void writePackageRestrictionsLPr(int userId) {
         if (DEBUG_MU) {
             Log.i(TAG, "Writing package restrictions for user=" + userId);
@@ -1506,8 +1360,6 @@
 
             writeCrossProfileIntentFiltersLPr(serializer, userId);
 
-            writeCrossProfilePackageInfoLPr(serializer, userId);
-
             serializer.endTag(null, TAG_PACKAGE_RESTRICTIONS);
 
             serializer.endDocument();
@@ -3192,7 +3044,6 @@
         file = getUserPackagesStateBackupFile(userId);
         file.delete();
         removeCrossProfileIntentFiltersLPw(userId);
-        removeCrossProfilePackagesLPw(userId);
     }
 
     void removeCrossProfileIntentFiltersLPw(int userId) {
@@ -3223,27 +3074,6 @@
         }
     }
 
-    public void removeCrossProfilePackagesLPw(int userId) {
-        synchronized(mCrossProfilePackageInfo) {
-            // userId is the source user
-            if (mCrossProfilePackageInfo.get(userId) != null) {
-                mCrossProfilePackageInfo.remove(userId);
-                writePackageRestrictionsLPr(userId);
-            }
-            // userId is the target user
-            int count = mCrossProfilePackageInfo.size();
-            for (int i = 0; i < count; i++) {
-                int sourceUserId = mCrossProfilePackageInfo.keyAt(i);
-                SparseArray<ArrayList<String>> sourceForwardingInfo =
-                        mCrossProfilePackageInfo.valueAt(i);
-                if (sourceForwardingInfo.get(userId) != null) {
-                    sourceForwardingInfo.remove(userId);
-                    writePackageRestrictionsLPr(sourceUserId);
-                }
-            }
-        }
-    }
-
     // This should be called (at least) whenever an application is removed
     private void setFirstAvailableUid(int uid) {
         if (uid > mFirstAvailableUid) {
diff --git a/services/core/java/com/android/server/pm/UserManagerService.java b/services/core/java/com/android/server/pm/UserManagerService.java
index ad87993..26e0db3 100644
--- a/services/core/java/com/android/server/pm/UserManagerService.java
+++ b/services/core/java/com/android/server/pm/UserManagerService.java
@@ -21,7 +21,6 @@
 import android.app.Activity;
 import android.app.ActivityManager;
 import android.app.ActivityManagerNative;
-import android.app.ActivityThread;
 import android.app.IStopUserCallback;
 import android.content.BroadcastReceiver;
 import android.content.Context;
@@ -34,6 +33,7 @@
 import android.graphics.BitmapFactory;
 import android.os.Binder;
 import android.os.Bundle;
+import android.os.Debug;
 import android.os.Environment;
 import android.os.FileUtils;
 import android.os.Handler;
@@ -92,6 +92,7 @@
     private static final String ATTR_SERIAL_NO = "serialNumber";
     private static final String ATTR_NEXT_SERIAL_NO = "nextSerialNumber";
     private static final String ATTR_PARTIAL = "partial";
+    private static final String ATTR_GUEST_TO_REMOVE = "guestToRemove";
     private static final String ATTR_USER_VERSION = "version";
     private static final String ATTR_PROFILE_GROUP_ID = "profileGroupId";
     private static final String TAG_GUEST_RESTRICTIONS = "guestRestrictions";
@@ -228,7 +229,7 @@
                 ArrayList<UserInfo> partials = new ArrayList<UserInfo>();
                 for (int i = 0; i < mUsers.size(); i++) {
                     UserInfo ui = mUsers.valueAt(i);
-                    if (ui.partial && i != 0) {
+                    if ((ui.partial || ui.guestToRemove) && i != 0) {
                         partials.add(ui);
                     }
                 }
@@ -293,6 +294,10 @@
     private List<UserInfo> getProfilesLocked(int userId, boolean enabledOnly) {
         UserInfo user = getUserInfoLocked(userId);
         ArrayList<UserInfo> users = new ArrayList<UserInfo>(mUsers.size());
+        if (user == null) {
+            // Probably a dying user
+            return users;
+        }
         for (int i = 0; i < mUsers.size(); i++) {
             UserInfo profile = mUsers.valueAt(i);
             if (!isProfileOf(user, profile)) {
@@ -476,6 +481,14 @@
     }
 
     @Override
+    public boolean hasUserRestriction(String restrictionKey, int userId) {
+        synchronized (mPackagesLock) {
+            Bundle restrictions = mUserRestrictions.get(userId);
+            return restrictions != null ? restrictions.getBoolean(restrictionKey) : false;
+        }
+    }
+
+    @Override
     public Bundle getUserRestrictions(int userId) {
         // checkManageUsersPermission("getUserRestrictions");
 
@@ -515,7 +528,7 @@
         for (int i = 0; i < totalUserCount; i++) {
             UserInfo user = mUsers.valueAt(i);
             if (!mRemovingUserIds.get(user.id)
-                    && !user.isGuest()) {
+                    && !user.isGuest() && !user.partial) {
                 aliveUserCount++;
             }
         }
@@ -755,6 +768,9 @@
             if (userInfo.partial) {
                 serializer.attribute(null, ATTR_PARTIAL, "true");
             }
+            if (userInfo.guestToRemove) {
+                serializer.attribute(null, ATTR_GUEST_TO_REMOVE, "true");
+            }
             if (userInfo.profileGroupId != UserInfo.NO_PROFILE_GROUP_ID) {
                 serializer.attribute(null, ATTR_PROFILE_GROUP_ID,
                         Integer.toString(userInfo.profileGroupId));
@@ -802,7 +818,7 @@
             serializer.attribute(null, ATTR_NEXT_SERIAL_NO, Integer.toString(mNextSerialNumber));
             serializer.attribute(null, ATTR_USER_VERSION, Integer.toString(mUserVersion));
 
-            serializer.startTag(null,  TAG_GUEST_RESTRICTIONS);
+            serializer.startTag(null, TAG_GUEST_RESTRICTIONS);
             writeRestrictionsLocked(serializer, mGuestRestrictions);
             serializer.endTag(null, TAG_GUEST_RESTRICTIONS);
             for (int i = 0; i < mUsers.size(); i++) {
@@ -851,6 +867,8 @@
         writeBoolean(serializer, restrictions, UserManager.DISALLOW_OUTGOING_CALLS);
         writeBoolean(serializer, restrictions, UserManager.DISALLOW_SMS);
         writeBoolean(serializer, restrictions, UserManager.DISALLOW_CREATE_WINDOWS);
+        writeBoolean(serializer, restrictions, UserManager.DISALLOW_CROSS_PROFILE_COPY_PASTE);
+        writeBoolean(serializer, restrictions, UserManager.DISALLOW_OUTGOING_BEAM);
         serializer.endTag(null, TAG_RESTRICTIONS);
     }
 
@@ -867,6 +885,7 @@
         int profileGroupId = UserInfo.NO_PROFILE_GROUP_ID;
         long lastAttemptTime = 0L;
         boolean partial = false;
+        boolean guestToRemove = false;
         Bundle restrictions = new Bundle();
 
         FileInputStream fis = null;
@@ -914,6 +933,10 @@
                 if ("true".equals(valueString)) {
                     partial = true;
                 }
+                valueString = parser.getAttributeValue(null, ATTR_GUEST_TO_REMOVE);
+                if ("true".equals(valueString)) {
+                    guestToRemove = true;
+                }
 
                 int outerDepth = parser.getDepth();
                 while ((type = parser.next()) != XmlPullParser.END_DOCUMENT
@@ -938,6 +961,7 @@
             userInfo.creationTime = creationTime;
             userInfo.lastLoggedInTime = lastLoggedInTime;
             userInfo.partial = partial;
+            userInfo.guestToRemove = guestToRemove;
             userInfo.profileGroupId = profileGroupId;
             mUserRestrictions.append(id, restrictions);
             if (salt != 0L) {
@@ -995,6 +1019,8 @@
         readBoolean(parser, restrictions, UserManager.DISALLOW_OUTGOING_CALLS);
         readBoolean(parser, restrictions, UserManager.DISALLOW_SMS);
         readBoolean(parser, restrictions, UserManager.DISALLOW_CREATE_WINDOWS);
+        readBoolean(parser, restrictions, UserManager.DISALLOW_CROSS_PROFILE_COPY_PASTE);
+        readBoolean(parser, restrictions, UserManager.DISALLOW_OUTGOING_BEAM);
     }
 
     private void readBoolean(XmlPullParser parser, Bundle restrictions,
@@ -1115,7 +1141,7 @@
                         return null;
                     }
                     // If we're adding a guest and there already exists one, bail.
-                    if (isGuest && numberOfUsersOfTypeLocked(UserInfo.FLAG_GUEST, true) > 0) {
+                    if (isGuest && findCurrentGuestUserLocked() != null) {
                         return null;
                     }
                     // Limit number of managed profiles that can be created
@@ -1176,6 +1202,65 @@
     }
 
     /**
+     * Find the current guest user. If the Guest user is partial,
+     * then do not include it in the results as it is about to die.
+     * This is different than {@link #numberOfUsersOfTypeLocked(int, boolean)} due to
+     * the special handling of Guests being removed.
+     */
+    private UserInfo findCurrentGuestUserLocked() {
+        final int size = mUsers.size();
+        for (int i = 0; i < size; i++) {
+            final UserInfo user = mUsers.valueAt(i);
+            if (user.isGuest() && !user.guestToRemove && !mRemovingUserIds.get(user.id)) {
+                return user;
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Mark this guest user for deletion to allow us to create another guest
+     * and switch to that user before actually removing this guest.
+     * @param userHandle the userid of the current guest
+     * @return whether the user could be marked for deletion
+     */
+    public boolean markGuestForDeletion(int userHandle) {
+        checkManageUsersPermission("Only the system can remove users");
+        if (getUserRestrictions(UserHandle.getCallingUserId()).getBoolean(
+                UserManager.DISALLOW_REMOVE_USER, false)) {
+            Log.w(LOG_TAG, "Cannot remove user. DISALLOW_REMOVE_USER is enabled.");
+            return false;
+        }
+
+        long ident = Binder.clearCallingIdentity();
+        try {
+            final UserInfo user;
+            synchronized (mPackagesLock) {
+                user = mUsers.get(userHandle);
+                if (userHandle == 0 || user == null || mRemovingUserIds.get(userHandle)) {
+                    return false;
+                }
+                if (!user.isGuest()) {
+                    return false;
+                }
+                // We set this to a guest user that is to be removed. This is a temporary state
+                // where we are allowed to add new Guest users, even if this one is still not
+                // removed. This user will still show up in getUserInfo() calls.
+                // If we don't get around to removing this Guest user, it will be purged on next
+                // startup.
+                user.guestToRemove = true;
+                // Mark it as disabled, so that it isn't returned any more when
+                // profiles are queried.
+                user.flags |= UserInfo.FLAG_DISABLED;
+                writeUserLocked(user);
+            }
+        } finally {
+            Binder.restoreCallingIdentity(ident);
+        }
+        return true;
+    }
+
+    /**
      * Removes a user and all data directories created for that user. This method should be called
      * after the user's processes have been terminated.
      * @param userHandle the user's id
@@ -1280,7 +1365,7 @@
 
     private void removeUserStateLocked(final int userHandle) {
         // Cleanup package manager settings
-        mPm.cleanUpUserLILPw(userHandle);
+        mPm.cleanUpUserLILPw(this, userHandle);
 
         // Remove this user from the list
         mUsers.remove(userHandle);
@@ -1576,6 +1661,7 @@
                     String valType = parser.getAttributeValue(null, ATTR_VALUE_TYPE);
                     String multiple = parser.getAttributeValue(null, ATTR_MULTIPLE);
                     if (multiple != null) {
+                        values.clear();
                         int count = Integer.parseInt(multiple);
                         while (count > 0 && (type = parser.next()) != XmlPullParser.END_DOCUMENT) {
                             if (type == XmlPullParser.START_TAG
diff --git a/services/core/java/com/android/server/power/PowerManagerService.java b/services/core/java/com/android/server/power/PowerManagerService.java
index 9734bd4..c79a6d6 100644
--- a/services/core/java/com/android/server/power/PowerManagerService.java
+++ b/services/core/java/com/android/server/power/PowerManagerService.java
@@ -20,8 +20,8 @@
 import com.android.internal.app.IBatteryStats;
 import com.android.internal.os.BackgroundThread;
 import com.android.server.EventLogTags;
-import com.android.server.LocalServices;
 import com.android.server.ServiceThread;
+import com.android.server.SystemService;
 import com.android.server.am.BatteryStatsService;
 import com.android.server.lights.Light;
 import com.android.server.lights.LightsManager;
@@ -55,7 +55,6 @@
 import android.os.RemoteException;
 import android.os.SystemClock;
 import android.os.SystemProperties;
-import android.os.SystemService;
 import android.os.Trace;
 import android.os.UserHandle;
 import android.os.WorkSource;
@@ -78,7 +77,7 @@
  * The power manager service is responsible for coordinating power management
  * functions on the device.
  */
-public final class PowerManagerService extends com.android.server.SystemService
+public final class PowerManagerService extends SystemService
         implements Watchdog.Monitor {
     private static final String TAG = "PowerManagerService";
 
@@ -91,8 +90,6 @@
     private static final int MSG_SANDMAN = 2;
     // Message: Sent when the screen on blocker is released.
     private static final int MSG_SCREEN_ON_BLOCKER_RELEASED = 3;
-    // Message: Sent to poll whether the boot animation has terminated.
-    private static final int MSG_CHECK_IF_BOOT_ANIMATION_FINISHED = 4;
 
     // Dirty bit: mWakeLocks changed
     private static final int DIRTY_WAKE_LOCKS = 1 << 0;
@@ -154,15 +151,9 @@
     // provider populates the actual default value (R.integer.def_screen_off_timeout).
     private static final int DEFAULT_SCREEN_OFF_TIMEOUT = 15 * 1000;
 
-    // The name of the boot animation service in init.rc.
-    private static final String BOOT_ANIMATION_SERVICE = "bootanim";
-
-    // Poll interval in milliseconds for watching boot animation finished.
-    private static final int BOOT_ANIMATION_POLL_INTERVAL = 200;
-
-    // Used to send the hint to the PowerHAL indicating transitions
-    // from and to the low power mode.
-    private static final int POWER_HINT_LOW_POWER_MODE = 5;
+    // Power hints defined in hardware/libhardware/include/hardware/power.h.
+    private static final int POWER_HINT_INTERACTION = 2;
+    private static final int POWER_HINT_LOW_POWER = 5;
 
     private final Context mContext;
     private final ServiceThread mHandlerThread;
@@ -223,6 +214,9 @@
     private long mLastUserActivityTime;
     private long mLastUserActivityTimeNoChangeLights;
 
+    // Timestamp of last interactive power hint.
+    private long mLastInteractivePowerHintTime;
+
     // A bitfield that summarizes the effect of the user activity timer.
     // A zero value indicates that the user activity timer has expired.
     private int mUserActivitySummary;
@@ -334,6 +328,9 @@
     // True if dreams should be activated on dock.
     private boolean mDreamsActivateOnDockSetting;
 
+    // True if doze should not be started until after the screen off transition.
+    private boolean mDozeAfterScreenOffConfig;
+
     // The minimum screen off timeout, in milliseconds.
     private int mMinimumScreenOffTimeoutConfig;
 
@@ -419,9 +416,9 @@
     private boolean mLowPowerModeSetting;
 
     // Current state of whether the settings are allowing auto low power mode.
-    private boolean mAutoLowPowerModeEnabled;
+    private boolean mAutoLowPowerModeConfigured;
 
-   // The user turned off low power mode below the trigger level
+    // The user turned off low power mode below the trigger level
     private boolean mAutoLowPowerModeSnoozing;
 
     // True if the battery level is currently considered low.
@@ -475,14 +472,15 @@
 
     @Override
     public void onBootPhase(int phase) {
-        if (phase == PHASE_BOOT_COMPLETED) {
-            // This is our early signal that the system thinks it has finished booting.
-            // However, the boot animation may still be running for a few more seconds
-            // since it is ultimately in charge of when it terminates.
-            // Defer transitioning into the boot completed state until the animation exits.
-            // We do this so that the screen does not start to dim prematurely before
-            // the user has actually had a chance to interact with the device.
-            startWatchingForBootAnimationFinished();
+        synchronized (mLock) {
+            if (phase == PHASE_BOOT_COMPLETED) {
+                final long now = SystemClock.uptimeMillis();
+                mBootCompleted = true;
+                mDirty |= DIRTY_BOOT_COMPLETED;
+                userActivityNoUpdateLocked(
+                        now, PowerManager.USER_ACTIVITY_EVENT_OTHER, 0, Process.SYSTEM_UID);
+                updatePowerStateLocked();
+            }
         }
     }
 
@@ -607,6 +605,8 @@
                 com.android.internal.R.integer.config_dreamsBatteryLevelMinimumWhenNotPowered);
         mDreamsBatteryLevelDrainCutoffConfig = resources.getInteger(
                 com.android.internal.R.integer.config_dreamsBatteryLevelDrainCutoff);
+        mDozeAfterScreenOffConfig = resources.getBoolean(
+                com.android.internal.R.bool.config_dozeAfterScreenOff);
         mMinimumScreenOffTimeoutConfig = resources.getInteger(
                 com.android.internal.R.integer.config_minimumScreenOffTimeout);
         mMaximumScreenDimDurationConfig = resources.getInteger(
@@ -659,26 +659,12 @@
 
         final boolean lowPowerModeEnabled = Settings.Global.getInt(resolver,
                 Settings.Global.LOW_POWER_MODE, 0) != 0;
-        final boolean autoLowPowerModeEnabled = Settings.Global.getInt(resolver,
+        final boolean autoLowPowerModeConfigured = Settings.Global.getInt(resolver,
                 Settings.Global.LOW_POWER_MODE_TRIGGER_LEVEL, 0) != 0;
         if (lowPowerModeEnabled != mLowPowerModeSetting
-                || autoLowPowerModeEnabled != mAutoLowPowerModeEnabled) {
-            if (lowPowerModeEnabled != mLowPowerModeSetting) {
-                if (!mAutoLowPowerModeSnoozing && !lowPowerModeEnabled && !mIsPowered
-                        && mAutoLowPowerModeEnabled) {
-                    if (DEBUG_SPEW) {
-                        Slog.d(TAG, "updateSettingsLocked: snoozing low power mode");
-                    }
-                    mAutoLowPowerModeSnoozing = true;
-                } else if (mAutoLowPowerModeSnoozing && lowPowerModeEnabled) {
-                    if (DEBUG_SPEW) {
-                        Slog.d(TAG, "updateSettingsLocked: no longer snoozing low power mode");
-                    }
-                    mAutoLowPowerModeSnoozing = true;
-                }
-            }
+                || autoLowPowerModeConfigured != mAutoLowPowerModeConfigured) {
             mLowPowerModeSetting = lowPowerModeEnabled;
-            mAutoLowPowerModeEnabled = autoLowPowerModeEnabled;
+            mAutoLowPowerModeConfigured = autoLowPowerModeConfigured;
             updateLowPowerModeLocked();
         }
 
@@ -694,21 +680,14 @@
             Settings.Global.putInt(mContext.getContentResolver(),
                     Settings.Global.LOW_POWER_MODE, 0);
             mLowPowerModeSetting = false;
-        } else if (!mIsPowered && mAutoLowPowerModeEnabled && !mAutoLowPowerModeSnoozing
-                && mBatteryLevelLow && !mLowPowerModeSetting) {
-            if (DEBUG_SPEW) {
-                Slog.d(TAG, "updateLowPowerModeLocked: trigger level reached, turning setting on");
-            }
-            // Turn setting on if trigger level is enabled, and we're now below it
-            Settings.Global.putInt(mContext.getContentResolver(),
-                    Settings.Global.LOW_POWER_MODE, 1);
-            mLowPowerModeSetting = true;
         }
-        final boolean lowPowerModeEnabled = mLowPowerModeSetting;
+        final boolean autoLowPowerModeEnabled = !mIsPowered && mAutoLowPowerModeConfigured
+                && !mAutoLowPowerModeSnoozing && mBatteryLevelLow;
+        final boolean lowPowerModeEnabled = mLowPowerModeSetting || autoLowPowerModeEnabled;
+
         if (mLowPowerModeEnabled != lowPowerModeEnabled) {
             mLowPowerModeEnabled = lowPowerModeEnabled;
-            powerHintInternal(POWER_HINT_LOW_POWER_MODE, lowPowerModeEnabled ? 1 : 0);
-            mLowPowerModeEnabled = lowPowerModeEnabled;
+            powerHintInternal(POWER_HINT_LOW_POWER, lowPowerModeEnabled ? 1 : 0);
             BackgroundThread.getHandler().post(new Runnable() {
                 @Override
                 public void run() {
@@ -818,7 +797,7 @@
                         + " [" + wakeLock.mTag + "], flags=0x" + Integer.toHexString(flags));
             }
 
-            if ((flags & PowerManager.WAIT_FOR_PROXIMITY_NEGATIVE) != 0) {
+            if ((flags & PowerManager.RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY) != 0) {
                 mRequestWaitForNegativeProximity = true;
             }
 
@@ -969,15 +948,25 @@
         }
 
         if (eventTime < mLastSleepTime || eventTime < mLastWakeTime
-                || mWakefulness == WAKEFULNESS_ASLEEP || mWakefulness == WAKEFULNESS_DOZING
                 || !mBootCompleted || !mSystemReady) {
             return false;
         }
 
         Trace.traceBegin(Trace.TRACE_TAG_POWER, "userActivity");
         try {
+            if (eventTime > mLastInteractivePowerHintTime) {
+                powerHintInternal(POWER_HINT_INTERACTION, 0);
+                mLastInteractivePowerHintTime = eventTime;
+            }
+
             mNotifier.onUserActivity(event, uid);
 
+            if (mWakefulness == WAKEFULNESS_ASLEEP
+                    || mWakefulness == WAKEFULNESS_DOZING
+                    || (flags & PowerManager.USER_ACTIVITY_FLAG_INDIRECT) != 0) {
+                return false;
+            }
+
             if ((flags & PowerManager.USER_ACTIVITY_FLAG_NO_CHANGE_LIGHTS) != 0) {
                 if (eventTime > mLastUserActivityTimeNoChangeLights
                         && eventTime > mLastUserActivityTime) {
@@ -1236,16 +1225,18 @@
                 }
             }
 
-            // Phase 2: Update dreams and display power state.
-            updateDreamLocked(dirtyPhase2);
-            updateDisplayPowerStateLocked(dirtyPhase2);
+            // Phase 2: Update display power state.
+            boolean displayBecameReady = updateDisplayPowerStateLocked(dirtyPhase2);
 
-            // Phase 3: Send notifications, if needed.
+            // Phase 3: Update dream state (depends on display ready signal).
+            updateDreamLocked(dirtyPhase2, displayBecameReady);
+
+            // Phase 4: Send notifications, if needed.
             if (mDisplayReady) {
                 finishInteractiveStateChangeLocked();
             }
 
-            // Phase 4: Update suspend blocker.
+            // Phase 5: Update suspend blocker.
             // Because we might release the last suspend blocker here, we need to make sure
             // we finished everything else first!
             updateSuspendBlockerLocked();
@@ -1597,7 +1588,7 @@
     /**
      * Determines whether to post a message to the sandman to update the dream state.
      */
-    private void updateDreamLocked(int dirty) {
+    private void updateDreamLocked(int dirty, boolean displayBecameReady) {
         if ((dirty & (DIRTY_WAKEFULNESS
                 | DIRTY_USER_ACTIVITY
                 | DIRTY_WAKE_LOCKS
@@ -1606,8 +1597,10 @@
                 | DIRTY_IS_POWERED
                 | DIRTY_STAY_ON
                 | DIRTY_PROXIMITY_POSITIVE
-                | DIRTY_BATTERY_STATE)) != 0) {
-            scheduleSandmanLocked();
+                | DIRTY_BATTERY_STATE)) != 0 || displayBecameReady) {
+            if (mDisplayReady) {
+                scheduleSandmanLocked();
+            }
         }
     }
 
@@ -1634,7 +1627,7 @@
         synchronized (mLock) {
             mSandmanScheduled = false;
             wakefulness = mWakefulness;
-            if (mSandmanSummoned) {
+            if (mSandmanSummoned && mDisplayReady) {
                 startDreaming = ((wakefulness == WAKEFULNESS_DREAMING && canDreamLocked())
                         || wakefulness == WAKEFULNESS_DOZING);
                 mSandmanSummoned = false;
@@ -1766,8 +1759,11 @@
      * has been updated so we come back here to double-check and finish up.
      *
      * This function recalculates the display power state each time.
+     *
+     * @return True if the display became ready.
      */
-    private void updateDisplayPowerStateLocked(int dirty) {
+    private boolean updateDisplayPowerStateLocked(int dirty) {
+        final boolean oldDisplayReady = mDisplayReady;
         if ((dirty & (DIRTY_WAKE_LOCKS | DIRTY_USER_ACTIVITY | DIRTY_WAKEFULNESS
                 | DIRTY_ACTUAL_DISPLAY_POWER_STATE_UPDATED | DIRTY_BOOT_COMPLETED
                 | DIRTY_SETTINGS | DIRTY_SCREEN_ON_BLOCKER_RELEASED)) != 0) {
@@ -1833,6 +1829,7 @@
                         + ", mBootCompleted=" + mBootCompleted);
             }
         }
+        return mDisplayReady && !oldDisplayReady;
     }
 
     private static boolean isValidBrightness(int value) {
@@ -1849,8 +1846,15 @@
             return DisplayPowerRequest.POLICY_OFF;
         }
 
-        if ((mWakeLockSummary & WAKE_LOCK_DOZE) != 0) {
-            return DisplayPowerRequest.POLICY_DOZE;
+        if (mWakefulness == WAKEFULNESS_DOZING) {
+            if ((mWakeLockSummary & WAKE_LOCK_DOZE) != 0) {
+                return DisplayPowerRequest.POLICY_DOZE;
+            }
+            if (mDozeAfterScreenOffConfig) {
+                return DisplayPowerRequest.POLICY_OFF;
+            }
+            // Fall through and preserve the current screen policy if not configured to
+            // doze after screen off.  This causes the screen off transition to be skipped.
         }
 
         if ((mWakeLockSummary & WAKE_LOCK_SCREEN_BRIGHT) != 0
@@ -2058,43 +2062,40 @@
         }
     }
 
+    private boolean setLowPowerModeInternal(boolean mode) {
+        synchronized (mLock) {
+            if (DEBUG) Slog.d(TAG, "setLowPowerModeInternal " + mode + " mIsPowered=" + mIsPowered);
+            if (mIsPowered) {
+                return false;
+            }
+            Settings.Global.putInt(mContext.getContentResolver(),
+                    Settings.Global.LOW_POWER_MODE, mode ? 1 : 0);
+            mLowPowerModeSetting = mode;
+
+            if (mAutoLowPowerModeConfigured && mBatteryLevelLow) {
+                if (mode && mAutoLowPowerModeSnoozing) {
+                    if (DEBUG_SPEW) {
+                        Slog.d(TAG, "setLowPowerModeInternal: clearing low power mode snooze");
+                    }
+                    mAutoLowPowerModeSnoozing = false;
+                } else if (!mode && !mAutoLowPowerModeSnoozing) {
+                    if (DEBUG_SPEW) {
+                        Slog.d(TAG, "setLowPowerModeInternal: snoozing low power mode");
+                    }
+                    mAutoLowPowerModeSnoozing = true;
+                }
+            }
+
+            updateLowPowerModeLocked();
+            return true;
+        }
+    }
+
     private void handleBatteryStateChangedLocked() {
         mDirty |= DIRTY_BATTERY_STATE;
         updatePowerStateLocked();
     }
 
-    private void startWatchingForBootAnimationFinished() {
-        mHandler.sendEmptyMessage(MSG_CHECK_IF_BOOT_ANIMATION_FINISHED);
-    }
-
-    private void checkIfBootAnimationFinished() {
-        if (DEBUG) {
-            Slog.d(TAG, "Check if boot animation finished...");
-        }
-
-        if (SystemService.isRunning(BOOT_ANIMATION_SERVICE)) {
-            mHandler.sendEmptyMessageDelayed(MSG_CHECK_IF_BOOT_ANIMATION_FINISHED,
-                    BOOT_ANIMATION_POLL_INTERVAL);
-            return;
-        }
-
-        synchronized (mLock) {
-            if (!mBootCompleted) {
-                Slog.i(TAG, "Boot animation finished.");
-                handleBootCompletedLocked();
-            }
-        }
-    }
-
-    private void handleBootCompletedLocked() {
-        final long now = SystemClock.uptimeMillis();
-        mBootCompleted = true;
-        mDirty |= DIRTY_BOOT_COMPLETED;
-        userActivityNoUpdateLocked(
-                now, PowerManager.USER_ACTIVITY_EVENT_OTHER, 0, Process.SYSTEM_UID);
-        updatePowerStateLocked();
-    }
-
     private void shutdownOrRebootInternal(final boolean shutdown, final boolean confirm,
             final String reason, boolean wait) {
         if (mHandler == null || !mSystemReady) {
@@ -2319,6 +2320,8 @@
             pw.println("  mLastUserActivityTime=" + TimeUtils.formatUptime(mLastUserActivityTime));
             pw.println("  mLastUserActivityTimeNoChangeLights="
                     + TimeUtils.formatUptime(mLastUserActivityTimeNoChangeLights));
+            pw.println("  mLastInteractivePowerHintTime="
+                    + TimeUtils.formatUptime(mLastInteractivePowerHintTime));
             pw.println("  mDisplayReady=" + mDisplayReady);
             pw.println("  mHoldingWakeLockSuspendBlocker=" + mHoldingWakeLockSuspendBlocker);
             pw.println("  mHoldingDisplaySuspendBlocker=" + mHoldingDisplaySuspendBlocker);
@@ -2350,8 +2353,9 @@
             pw.println("  mDreamsEnabledSetting=" + mDreamsEnabledSetting);
             pw.println("  mDreamsActivateOnSleepSetting=" + mDreamsActivateOnSleepSetting);
             pw.println("  mDreamsActivateOnDockSetting=" + mDreamsActivateOnDockSetting);
+            pw.println("  mDozeAfterScreenOffConfig=" + mDozeAfterScreenOffConfig);
             pw.println("  mLowPowerModeSetting=" + mLowPowerModeSetting);
-            pw.println("  mAutoLowPowerModeEnabled=" + mAutoLowPowerModeEnabled);
+            pw.println("  mAutoLowPowerModeConfigured=" + mAutoLowPowerModeConfigured);
             pw.println("  mAutoLowPowerModeSnoozing=" + mAutoLowPowerModeSnoozing);
             pw.println("  mMinimumScreenOffTimeoutConfig=" + mMinimumScreenOffTimeoutConfig);
             pw.println("  mMaximumScreenDimDurationConfig=" + mMaximumScreenDimDurationConfig);
@@ -2513,9 +2517,6 @@
                 case MSG_SCREEN_ON_BLOCKER_RELEASED:
                     handleScreenOnBlockerReleased();
                     break;
-                case MSG_CHECK_IF_BOOT_ANIMATION_FINISHED:
-                    checkIfBootAnimationFinished();
-                    break;
             }
         }
     }
@@ -2774,6 +2775,10 @@
             PowerManager.validateWakeLockParameters(flags, tag);
 
             mContext.enforceCallingOrSelfPermission(android.Manifest.permission.WAKE_LOCK, null);
+            if ((flags & PowerManager.DOZE_WAKE_LOCK) != 0) {
+                mContext.enforceCallingOrSelfPermission(
+                        android.Manifest.permission.DEVICE_POWER, null);
+            }
             if (ws != null && ws.size() != 0) {
                 mContext.enforceCallingOrSelfPermission(
                         android.Manifest.permission.UPDATE_DEVICE_STATS, null);
@@ -2859,7 +2864,10 @@
         public void userActivity(long eventTime, int event, int flags) {
             final long now = SystemClock.uptimeMillis();
             if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.DEVICE_POWER)
-                    != PackageManager.PERMISSION_GRANTED) {
+                    != PackageManager.PERMISSION_GRANTED
+                    && mContext.checkCallingOrSelfPermission(
+                            android.Manifest.permission.USER_ACTIVITY)
+                            != PackageManager.PERMISSION_GRANTED) {
                 // Once upon a time applications could call userActivity().
                 // Now we require the DEVICE_POWER permission.  Log a warning and ignore the
                 // request instead of throwing a SecurityException so we don't break old apps.
@@ -2867,8 +2875,8 @@
                     if (now >= mLastWarningAboutUserActivityPermission + (5 * 60 * 1000)) {
                         mLastWarningAboutUserActivityPermission = now;
                         Slog.w(TAG, "Ignoring call to PowerManager.userActivity() because the "
-                                + "caller does not have DEVICE_POWER permission.  "
-                                + "Please fix your app!  "
+                                + "caller does not have DEVICE_POWER or USER_ACTIVITY "
+                                + "permission.  Please fix your app!  "
                                 + " pid=" + Binder.getCallingPid()
                                 + " uid=" + Binder.getCallingUid());
                     }
@@ -2963,6 +2971,18 @@
             }
         }
 
+        @Override // Binder call
+        public boolean setPowerSaveMode(boolean mode) {
+            mContext.enforceCallingOrSelfPermission(
+                    android.Manifest.permission.DEVICE_POWER, null);
+            final long ident = Binder.clearCallingIdentity();
+            try {
+                return setLowPowerModeInternal(mode);
+            } finally {
+                Binder.restoreCallingIdentity(ident);
+            }
+        }
+
         /**
          * Reboots the device.
          *
diff --git a/services/core/java/com/android/server/power/ShutdownThread.java b/services/core/java/com/android/server/power/ShutdownThread.java
index 5f3da07..da11387 100644
--- a/services/core/java/com/android/server/power/ShutdownThread.java
+++ b/services/core/java/com/android/server/power/ShutdownThread.java
@@ -430,10 +430,10 @@
                 }
 
                 try {
-                    radioOff = phone == null || !phone.isRadioOn();
+                    radioOff = phone == null || !phone.needMobileRadioShutdown();
                     if (!radioOff) {
-                        Log.w(TAG, "Turning off radio...");
-                        phone.setRadio(false);
+                        Log.w(TAG, "Turning off cellular radios...");
+                        phone.shutdownMobileRadios();
                     }
                 } catch (RemoteException ex) {
                     Log.e(TAG, "RemoteException during radio shutdown", ex);
@@ -456,7 +456,7 @@
                     }
                     if (!radioOff) {
                         try {
-                            radioOff = !phone.isRadioOn();
+                            radioOff = !phone.needMobileRadioShutdown();
                         } catch (RemoteException ex) {
                             Log.e(TAG, "RemoteException during radio shutdown", ex);
                             radioOff = true;
@@ -472,7 +472,7 @@
                             Log.e(TAG, "RemoteException during NFC shutdown", ex);
                             nfcOff = true;
                         }
-                        if (radioOff) {
+                        if (nfcOff) {
                             Log.i(TAG, "NFC turned off.");
                         }
                     }
diff --git a/services/core/java/com/android/server/statusbar/StatusBarManagerService.java b/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
index 297dacf..f85e2d9 100644
--- a/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
+++ b/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
@@ -22,7 +22,6 @@
 import android.os.IBinder;
 import android.os.RemoteException;
 import android.os.UserHandle;
-import android.service.notification.StatusBarNotification;
 import android.content.Context;
 import android.content.pm.PackageManager;
 import android.content.res.Resources;
@@ -39,9 +38,7 @@
 import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.util.ArrayList;
-import java.util.HashMap;
 import java.util.List;
-import java.util.Map;
 
 
 /**
@@ -187,10 +184,6 @@
 
     @Override
     public void disable(int what, IBinder token, String pkg) {
-        if (!mNotificationDelegate.allowDisable(what, token, pkg)) {
-            if (SPEW) Slog.d(TAG, "Blocking disable request from " + pkg);
-            return;
-        }
         disableInternal(mCurrentUserId, what, token, pkg);
     }
 
diff --git a/services/core/java/com/android/server/storage/DeviceStorageMonitorService.java b/services/core/java/com/android/server/storage/DeviceStorageMonitorService.java
index eb38f4a..468a344 100644
--- a/services/core/java/com/android/server/storage/DeviceStorageMonitorService.java
+++ b/services/core/java/com/android/server/storage/DeviceStorageMonitorService.java
@@ -453,6 +453,8 @@
         notification.icon = com.android.internal.R.drawable.stat_notify_disk_full;
         notification.tickerText = title;
         notification.flags |= Notification.FLAG_NO_CLEAR;
+        notification.color = context.getResources().getColor(
+                com.android.internal.R.color.system_notification_accent_color);
         notification.setLatestEventInfo(context, title, details, intent);
         notification.visibility = Notification.VISIBILITY_PUBLIC;
         notification.category = Notification.CATEGORY_SYSTEM;
diff --git a/services/core/java/com/android/server/trust/TrustAgentWrapper.java b/services/core/java/com/android/server/trust/TrustAgentWrapper.java
index 0523af7..b1c918d 100644
--- a/services/core/java/com/android/server/trust/TrustAgentWrapper.java
+++ b/services/core/java/com/android/server/trust/TrustAgentWrapper.java
@@ -16,16 +16,22 @@
 
 package com.android.server.trust;
 
+import android.app.AlarmManager;
+import android.app.PendingIntent;
 import android.app.admin.DevicePolicyManager;
+import android.content.BroadcastReceiver;
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
+import android.content.IntentFilter;
 import android.content.ServiceConnection;
+import android.net.Uri;
 import android.os.Binder;
 import android.os.Bundle;
 import android.os.Handler;
 import android.os.IBinder;
 import android.os.Message;
+import android.os.PatternMatcher;
 import android.os.RemoteException;
 import android.os.SystemClock;
 import android.os.UserHandle;
@@ -43,6 +49,9 @@
  * TrustManager and the actual TrustAgent.
  */
 public class TrustAgentWrapper {
+    private static final String EXTRA_COMPONENT_NAME = "componentName";
+    private static final String TRUST_EXPIRED_ACTION = "android.server.trust.TRUST_EXPIRED_ACTION";
+    private static final String PERMISSION = android.Manifest.permission.PROVIDE_TRUST_AGENT;
     private static final boolean DEBUG = false;
     private static final String TAG = "TrustAgentWrapper";
 
@@ -72,6 +81,7 @@
     private ITrustAgentService mTrustAgentService;
     private boolean mBound;
     private long mScheduledRestartUptimeMillis;
+    private long mMaximumTimeToLock; // from DevicePolicyManager
 
     // Trust state
     private boolean mTrusted;
@@ -79,6 +89,21 @@
     private boolean mTrustDisabledByDpm;
     private boolean mManagingTrust;
     private IBinder mSetTrustAgentFeaturesToken;
+    private AlarmManager mAlarmManager;
+    private final Intent mAlarmIntent;
+    private PendingIntent mAlarmPendingIntent;
+
+    private final BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
+        @Override
+        public void onReceive(Context context, Intent intent) {
+            ComponentName component = intent.getParcelableExtra(EXTRA_COMPONENT_NAME);
+            if (TRUST_EXPIRED_ACTION.equals(intent.getAction())
+                    && mName.equals(component)) {
+                mHandler.removeMessages(MSG_TRUST_TIMEOUT);
+                mHandler.sendEmptyMessage(MSG_TRUST_TIMEOUT);
+            }
+        }
+    };
 
     private final Handler mHandler = new Handler() {
         @Override
@@ -95,8 +120,25 @@
                     boolean initiatedByUser = msg.arg1 != 0;
                     long durationMs = msg.getData().getLong(DATA_DURATION);
                     if (durationMs > 0) {
-                        mHandler.removeMessages(MSG_TRUST_TIMEOUT);
-                        mHandler.sendEmptyMessageDelayed(MSG_TRUST_TIMEOUT, durationMs);
+                        final long duration;
+                        if (mMaximumTimeToLock != 0) {
+                            // Enforce DevicePolicyManager timeout.  This is here as a safeguard to
+                            // ensure trust agents are evaluating trust state at least as often as
+                            // the policy dictates. Admins that want more guarantees should be using
+                            // DevicePolicyManager#KEYGUARD_DISABLE_TRUST_AGENTS.
+                            duration = Math.min(durationMs, mMaximumTimeToLock);
+                            if (DEBUG) {
+                                Log.v(TAG, "DPM lock timeout in effect. Timeout adjusted from "
+                                    + durationMs + " to " + duration);
+                            }
+                        } else {
+                            duration = durationMs;
+                        }
+                        long expiration = SystemClock.elapsedRealtime() + duration;
+                        mAlarmPendingIntent = PendingIntent.getBroadcast(mContext, 0, mAlarmIntent,
+                                PendingIntent.FLAG_CANCEL_CURRENT);
+                        mAlarmManager.set(AlarmManager.ELAPSED_REALTIME_WAKEUP, expiration,
+                                mAlarmPendingIntent);
                     }
                     mTrustManagerService.mArchive.logGrantTrust(mUserId, mName,
                             (mMessage != null ? mMessage.toString() : null),
@@ -106,6 +148,7 @@
                 case MSG_TRUST_TIMEOUT:
                     if (DEBUG) Slog.v(TAG, "Trust timed out : " + mName.flattenToShortString());
                     mTrustManagerService.mArchive.logTrustTimeout(mUserId, mName);
+                    onTrustTimeout();
                     // Fall through.
                 case MSG_REVOKE_TRUST:
                     mTrusted = false;
@@ -212,8 +255,20 @@
             Intent intent, UserHandle user) {
         mContext = context;
         mTrustManagerService = trustManagerService;
+        mAlarmManager = (AlarmManager) mContext.getSystemService(Context.ALARM_SERVICE);
         mUserId = user.getIdentifier();
         mName = intent.getComponent();
+
+        mAlarmIntent = new Intent(TRUST_EXPIRED_ACTION).putExtra(EXTRA_COMPONENT_NAME, mName);
+        mAlarmIntent.setData(Uri.parse(mAlarmIntent.toUri(Intent.URI_INTENT_SCHEME)));
+        mAlarmIntent.setPackage(context.getPackageName());
+
+        final IntentFilter alarmFilter = new IntentFilter(TRUST_EXPIRED_ACTION);
+        alarmFilter.addDataScheme(mAlarmIntent.getScheme());
+        final String pathUri = mAlarmIntent.toUri(Intent.URI_INTENT_SCHEME);
+        alarmFilter.addDataPath(pathUri, PatternMatcher.PATTERN_LITERAL);
+        mContext.registerReceiver(mBroadcastReceiver, alarmFilter, PERMISSION, null);
+
         // Schedules a restart for when connecting times out. If the connection succeeds,
         // the restart is canceled in mCallback's onConnected.
         scheduleRestart();
@@ -227,6 +282,13 @@
         Slog.w(TAG , "Remote Exception", e);
     }
 
+    private void onTrustTimeout() {
+        try {
+            if (mTrustAgentService != null) mTrustAgentService.onTrustTimeout();
+        } catch (RemoteException e) {
+            onError(e);
+        }
+    }
     /**
      * @see android.service.trust.TrustAgentService#onUnlockAttempt(boolean)
      */
@@ -275,6 +337,17 @@
                                 mSetTrustAgentFeaturesToken);
                     }
                 }
+                final long maxTimeToLock = dpm.getMaximumTimeToLock(null);
+                if (maxTimeToLock != mMaximumTimeToLock) {
+                    // If the timeout changes, cancel the alarm and send a timeout event to have
+                    // the agent re-evaluate trust.
+                    mMaximumTimeToLock = maxTimeToLock;
+                    if (mAlarmPendingIntent != null) {
+                        mAlarmManager.cancel(mAlarmPendingIntent);
+                        mAlarmPendingIntent = null;
+                        mHandler.sendEmptyMessage(MSG_TRUST_TIMEOUT);
+                    }
+                }
             }
         } catch (RemoteException e) {
             onError(e);
diff --git a/services/core/java/com/android/server/trust/TrustManagerService.java b/services/core/java/com/android/server/trust/TrustManagerService.java
index 490536e..fefbe0a 100644
--- a/services/core/java/com/android/server/trust/TrustManagerService.java
+++ b/services/core/java/com/android/server/trust/TrustManagerService.java
@@ -33,6 +33,7 @@
 import android.content.Context;
 import android.content.Intent;
 import android.content.IntentFilter;
+import android.content.pm.ApplicationInfo;
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
 import android.content.pm.UserInfo;
@@ -48,6 +49,7 @@
 import android.os.SystemClock;
 import android.os.UserHandle;
 import android.os.UserManager;
+import android.provider.Settings;
 import android.service.trust.TrustAgentService;
 import android.util.ArraySet;
 import android.util.AttributeSet;
@@ -97,6 +99,7 @@
     private final SparseBooleanArray mUserHasAuthenticatedSinceBoot = new SparseBooleanArray();
     /* package */ final TrustArchive mArchive = new TrustArchive();
     private final Context mContext;
+    private final LockPatternUtils mLockPatternUtils;
 
     private UserManager mUserManager;
 
@@ -104,6 +107,7 @@
         super(context);
         mContext = context;
         mUserManager = (UserManager) mContext.getSystemService(Context.USER_SERVICE);
+        mLockPatternUtils = new LockPatternUtils(context);
     }
 
     @Override
@@ -116,7 +120,8 @@
         if (phase == SystemService.PHASE_SYSTEM_SERVICES_READY && !isSafeMode()) {
             mPackageMonitor.register(mContext, mHandler.getLooper(), UserHandle.ALL, true);
             mReceiver.register(mContext);
-            refreshAgentList();
+            maybeEnableFactoryTrustAgents(mLockPatternUtils, UserHandle.USER_OWNER);
+            refreshAgentList(UserHandle.USER_ALL);
         }
     }
 
@@ -157,17 +162,32 @@
         dispatchOnTrustChanged(aggregateIsTrusted(userId), userId, initiatedByUser);
     }
 
-    void refreshAgentList() {
+    void refreshAgentList(int userId) {
         if (DEBUG) Slog.d(TAG, "refreshAgentList()");
+        if (userId != UserHandle.USER_ALL && userId < UserHandle.USER_OWNER) {
+            Log.e(TAG, "refreshAgentList(userId=" + userId + "): Invalid user handle,"
+                    + " must be USER_ALL or a specific user.", new Throwable("here"));
+            userId = UserHandle.USER_ALL;
+        }
         PackageManager pm = mContext.getPackageManager();
 
-        List<UserInfo> userInfos = mUserManager.getUsers(true /* excludeDying */);
-        LockPatternUtils lockPatternUtils = new LockPatternUtils(mContext);
+        List<UserInfo> userInfos;
+        if (userId == UserHandle.USER_ALL) {
+            userInfos = mUserManager.getUsers(true /* excludeDying */);
+        } else {
+            userInfos = new ArrayList<>();
+            userInfos.add(mUserManager.getUserInfo(userId));
+        }
+        LockPatternUtils lockPatternUtils = mLockPatternUtils;
 
         ArraySet<AgentInfo> obsoleteAgents = new ArraySet<>();
         obsoleteAgents.addAll(mActiveAgents);
 
         for (UserInfo userInfo : userInfos) {
+            if (!userInfo.supportsSwitchTo()) continue;
+            if (lockPatternUtils.getKeyguardStoredPasswordQuality(userInfo.id)
+                    == DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED) continue;
+            if (!mUserHasAuthenticatedSinceBoot.get(userInfo.id)) continue;
             DevicePolicyManager dpm = lockPatternUtils.getDevicePolicyManager();
             int disabledFeatures = dpm.getKeyguardDisabledFeatures(null, userInfo.id);
             final boolean disableTrustAgents =
@@ -177,22 +197,11 @@
             if (enabledAgents == null) {
                 continue;
             }
-            List<ResolveInfo> resolveInfos = pm.queryIntentServicesAsUser(TRUST_AGENT_INTENT,
-                    PackageManager.GET_META_DATA, userInfo.id);
+            List<ResolveInfo> resolveInfos = resolveAllowedTrustAgents(pm, userInfo.id);
             for (ResolveInfo resolveInfo : resolveInfos) {
-                if (resolveInfo.serviceInfo == null) continue;
-
-                String packageName = resolveInfo.serviceInfo.packageName;
-                if (pm.checkPermission(PERMISSION_PROVIDE_AGENT, packageName)
-                        != PackageManager.PERMISSION_GRANTED) {
-                    Log.w(TAG, "Skipping agent because package " + packageName
-                            + " does not have permission " + PERMISSION_PROVIDE_AGENT + ".");
-                    continue;
-                }
-
                 ComponentName name = getComponentName(resolveInfo);
-                if (!enabledAgents.contains(name)) continue;
 
+                if (!enabledAgents.contains(name)) continue;
                 if (disableTrustAgents) {
                     List<String> features =
                             dpm.getTrustAgentFeaturesEnabled(null /* admin */, name);
@@ -219,11 +228,13 @@
         boolean trustMayHaveChanged = false;
         for (int i = 0; i < obsoleteAgents.size(); i++) {
             AgentInfo info = obsoleteAgents.valueAt(i);
-            if (info.agent.isManagingTrust()) {
-                trustMayHaveChanged = true;
+            if (userId == UserHandle.USER_ALL || userId == info.userId) {
+                if (info.agent.isManagingTrust()) {
+                    trustMayHaveChanged = true;
+                }
+                info.agent.unbind();
+                mActiveAgents.remove(info);
             }
-            info.agent.unbind();
-            mActiveAgents.remove(info);
         }
 
         if (trustMayHaveChanged) {
@@ -231,7 +242,7 @@
         }
     }
 
-    void updateDevicePolicyFeatures(int userId) {
+    void updateDevicePolicyFeatures() {
         for (int i = 0; i < mActiveAgents.size(); i++) {
             AgentInfo info = mActiveAgents.valueAt(i);
             if (info.agent.isConnected()) {
@@ -274,7 +285,7 @@
         if (trustMayHaveChanged) {
             updateTrust(userId, false);
         }
-        refreshAgentList();
+        refreshAgentList(userId);
     }
 
     private ComponentName getSettingsComponentName(PackageManager pm, ResolveInfo resolveInfo) {
@@ -333,6 +344,54 @@
         return new ComponentName(resolveInfo.serviceInfo.packageName, resolveInfo.serviceInfo.name);
     }
 
+    private void maybeEnableFactoryTrustAgents(LockPatternUtils utils, int userId) {
+        if (0 != Settings.Secure.getIntForUser(mContext.getContentResolver(),
+                Settings.Secure.TRUST_AGENTS_INITIALIZED, 0, userId)) {
+            return;
+        }
+        PackageManager pm = mContext.getPackageManager();
+        List<ResolveInfo> resolveInfos = resolveAllowedTrustAgents(pm, userId);
+        ArraySet<ComponentName> discoveredAgents = new ArraySet<>();
+        for (ResolveInfo resolveInfo : resolveInfos) {
+            ComponentName componentName = getComponentName(resolveInfo);
+            int applicationInfoFlags = resolveInfo.serviceInfo.applicationInfo.flags;
+            if ((applicationInfoFlags & ApplicationInfo.FLAG_SYSTEM) == 0) {
+                Log.i(TAG, "Leaving agent " + componentName + " disabled because package "
+                        + "is not a system package.");
+                continue;
+            }
+            discoveredAgents.add(componentName);
+        }
+
+        List<ComponentName> previouslyEnabledAgents = utils.getEnabledTrustAgents(userId);
+        if (previouslyEnabledAgents != null) {
+            discoveredAgents.addAll(previouslyEnabledAgents);
+        }
+        utils.setEnabledTrustAgents(discoveredAgents, userId);
+        Settings.Secure.putIntForUser(mContext.getContentResolver(),
+                Settings.Secure.TRUST_AGENTS_INITIALIZED, 1, userId);
+    }
+
+    private List<ResolveInfo> resolveAllowedTrustAgents(PackageManager pm, int userId) {
+        List<ResolveInfo> resolveInfos = pm.queryIntentServicesAsUser(TRUST_AGENT_INTENT,
+                0 /* flags */, userId);
+        ArrayList<ResolveInfo> allowedAgents = new ArrayList<>(resolveInfos.size());
+        for (ResolveInfo resolveInfo : resolveInfos) {
+            if (resolveInfo.serviceInfo == null) continue;
+            if (resolveInfo.serviceInfo.applicationInfo == null) continue;
+            String packageName = resolveInfo.serviceInfo.packageName;
+            if (pm.checkPermission(PERMISSION_PROVIDE_AGENT, packageName)
+                    != PackageManager.PERMISSION_GRANTED) {
+                ComponentName name = getComponentName(resolveInfo);
+                Log.w(TAG, "Skipping agent " + name + " because package does not have"
+                        + " permission " + PERMISSION_PROVIDE_AGENT + ".");
+                continue;
+            }
+            allowedAgents.add(resolveInfo);
+        }
+        return allowedAgents;
+    }
+
     // Agent dispatch and aggregation
 
     private boolean aggregateIsTrusted(int userId) {
@@ -381,7 +440,7 @@
     private void updateUserHasAuthenticated(int userId) {
         if (!mUserHasAuthenticatedSinceBoot.get(userId)) {
             mUserHasAuthenticatedSinceBoot.put(userId, true);
-            updateTrust(userId, false);
+            refreshAgentList(userId);
         }
     }
 
@@ -389,10 +448,10 @@
     private void requireCredentialEntry(int userId) {
         if (userId == UserHandle.USER_ALL) {
             mUserHasAuthenticatedSinceBoot.clear();
-            updateTrustAll();
+            refreshAgentList(UserHandle.USER_ALL);
         } else {
             mUserHasAuthenticatedSinceBoot.put(userId, false);
-            updateTrust(userId, false);
+            refreshAgentList(userId);
         }
     }
 
@@ -405,6 +464,7 @@
             }
         }
         mTrustListeners.add(listener);
+        updateTrustAll();
     }
 
     private void removeListener(ITrustListener listener) {
@@ -576,7 +636,7 @@
                     dispatchUnlockAttempt(msg.arg1 != 0, msg.arg2);
                     break;
                 case MSG_ENABLED_AGENTS_CHANGED:
-                    refreshAgentList();
+                    refreshAgentList(UserHandle.USER_ALL);
                     break;
                 case MSG_REQUIRE_CREDENTIAL_ENTRY:
                     requireCredentialEntry(msg.arg1);
@@ -588,7 +648,7 @@
     private final PackageMonitor mPackageMonitor = new PackageMonitor() {
         @Override
         public void onSomePackagesChanged() {
-            refreshAgentList();
+            refreshAgentList(UserHandle.USER_ALL);
         }
 
         @Override
@@ -607,12 +667,19 @@
 
         @Override
         public void onReceive(Context context, Intent intent) {
-            if (DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED.equals(
-                    intent.getAction())) {
-                refreshAgentList();
-                updateDevicePolicyFeatures(getSendingUserId());
-            } else if (Intent.ACTION_USER_PRESENT.equals(intent.getAction())) {
+            String action = intent.getAction();
+            if (DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED.equals(action)) {
+                refreshAgentList(getSendingUserId());
+                updateDevicePolicyFeatures();
+            } else if (Intent.ACTION_USER_PRESENT.equals(action)) {
                 updateUserHasAuthenticated(getSendingUserId());
+            } else if (Intent.ACTION_USER_ADDED.equals(action)) {
+                int userId = intent.getIntExtra(Intent.EXTRA_USER_HANDLE, -100);
+                if (userId > 0) {
+                    maybeEnableFactoryTrustAgents(mLockPatternUtils, userId);
+                } else {
+                    Log.wtf(TAG, "EXTRA_USER_HANDLE missing or invalid, value=" + userId);
+                }
             }
         }
 
@@ -620,6 +687,7 @@
             IntentFilter filter = new IntentFilter();
             filter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED);
             filter.addAction(Intent.ACTION_USER_PRESENT);
+            filter.addAction(Intent.ACTION_USER_ADDED);
             context.registerReceiverAsUser(this,
                     UserHandle.ALL,
                     filter,
diff --git a/services/core/java/com/android/server/tv/TvInputHal.java b/services/core/java/com/android/server/tv/TvInputHal.java
index e7dd82d..558ffb5 100644
--- a/services/core/java/com/android/server/tv/TvInputHal.java
+++ b/services/core/java/com/android/server/tv/TvInputHal.java
@@ -19,12 +19,11 @@
 import android.media.tv.TvInputHardwareInfo;
 import android.media.tv.TvStreamConfig;
 import android.os.Handler;
-import android.os.HandlerThread;
 import android.os.Message;
-import android.view.Surface;
 import android.util.Slog;
 import android.util.SparseArray;
 import android.util.SparseIntArray;
+import android.view.Surface;
 
 import java.util.LinkedList;
 import java.util.Queue;
@@ -33,8 +32,7 @@
  * Provides access to the low-level TV input hardware abstraction layer.
  */
 final class TvInputHal implements Handler.Callback {
-    // STOPSHIP: Turn debugging off
-    private final static boolean DEBUG = true;
+    private final static boolean DEBUG = false;
     private final static String TAG = TvInputHal.class.getSimpleName();
 
     public final static int SUCCESS = 0;
@@ -64,12 +62,12 @@
             int generation);
     private static native void nativeClose(long ptr);
 
-    private Object mLock = new Object();
+    private final Object mLock = new Object();
     private long mPtr = 0;
     private final Callback mCallback;
     private final Handler mHandler;
-    private SparseIntArray mStreamConfigGenerations = new SparseIntArray();
-    private SparseArray<TvStreamConfig[]> mStreamConfigs = new SparseArray<>();;
+    private final SparseIntArray mStreamConfigGenerations = new SparseIntArray();
+    private final SparseArray<TvStreamConfig[]> mStreamConfigs = new SparseArray<>();
 
     public TvInputHal(Callback callback) {
         mCallback = callback;
@@ -153,7 +151,7 @@
 
     // Handler.Callback implementation
 
-    private Queue<Message> mPendingMessageQueue = new LinkedList<Message>();
+    private final Queue<Message> mPendingMessageQueue = new LinkedList<Message>();
 
     @Override
     public boolean handleMessage(Message msg) {
diff --git a/services/core/java/com/android/server/tv/TvInputHardwareManager.java b/services/core/java/com/android/server/tv/TvInputHardwareManager.java
index ae9ae13..77ab33b 100644
--- a/services/core/java/com/android/server/tv/TvInputHardwareManager.java
+++ b/services/core/java/com/android/server/tv/TvInputHardwareManager.java
@@ -20,14 +20,12 @@
 import static android.media.tv.TvInputManager.INPUT_STATE_DISCONNECTED;
 
 import android.content.Context;
-import android.content.Intent;
 import android.hardware.hdmi.HdmiControlManager;
 import android.hardware.hdmi.HdmiDeviceInfo;
 import android.hardware.hdmi.HdmiHotplugEvent;
 import android.hardware.hdmi.IHdmiControlService;
 import android.hardware.hdmi.IHdmiDeviceEventListener;
 import android.hardware.hdmi.IHdmiHotplugEventListener;
-import android.hardware.hdmi.IHdmiInputChangeListener;
 import android.hardware.hdmi.IHdmiSystemAudioModeChangeListener;
 import android.media.AudioDevicePort;
 import android.media.AudioFormat;
@@ -39,7 +37,6 @@
 import android.media.AudioPortConfig;
 import android.media.tv.ITvInputHardware;
 import android.media.tv.ITvInputHardwareCallback;
-import android.media.tv.TvContract;
 import android.media.tv.TvInputHardwareInfo;
 import android.media.tv.TvInputInfo;
 import android.media.tv.TvStreamConfig;
@@ -77,7 +74,6 @@
 class TvInputHardwareManager implements TvInputHal.Callback {
     private static final String TAG = TvInputHardwareManager.class.getSimpleName();
 
-    private final Context mContext;
     private final Listener mListener;
     private final TvInputHal mHal = new TvInputHal(this);
     private final SparseArray<Connection> mConnections = new SparseArray<>();
@@ -107,7 +103,6 @@
     private final Object mLock = new Object();
 
     public TvInputHardwareManager(Context context, Listener listener) {
-        mContext = context;
         mListener = listener;
         mAudioManager = (AudioManager) context.getSystemService(Context.AUDIO_SERVICE);
         mHal.init();
@@ -963,7 +958,7 @@
                 Object obj = null;
                 switch (status) {
                     case HdmiControlManager.DEVICE_EVENT_ADD_DEVICE: {
-                        if (!mHdmiDeviceList.contains(deviceInfo)) {
+                        if (findHdmiDeviceInfo(deviceInfo.getId()) == null) {
                             mHdmiDeviceList.add(deviceInfo);
                         } else {
                             Slog.w(TAG, "The list already contains " + deviceInfo + "; ignoring.");
@@ -974,7 +969,8 @@
                         break;
                     }
                     case HdmiControlManager.DEVICE_EVENT_REMOVE_DEVICE: {
-                        if (!mHdmiDeviceList.remove(deviceInfo)) {
+                        HdmiDeviceInfo originalDeviceInfo = findHdmiDeviceInfo(deviceInfo.getId());
+                        if (!mHdmiDeviceList.remove(originalDeviceInfo)) {
                             Slog.w(TAG, "The list doesn't contain " + deviceInfo + "; ignoring.");
                             return;
                         }
@@ -983,13 +979,14 @@
                         break;
                     }
                     case HdmiControlManager.DEVICE_EVENT_UPDATE_DEVICE: {
-                        if (!mHdmiDeviceList.remove(deviceInfo)) {
+                        HdmiDeviceInfo originalDeviceInfo = findHdmiDeviceInfo(deviceInfo.getId());
+                        if (!mHdmiDeviceList.remove(originalDeviceInfo)) {
                             Slog.w(TAG, "The list doesn't contain " + deviceInfo + "; ignoring.");
                             return;
                         }
                         mHdmiDeviceList.add(deviceInfo);
                         messageType = ListenerHandler.HDMI_DEVICE_UPDATED;
-                        String inputId = mHdmiInputIdMap.get(deviceInfo.getLogicalAddress());
+                        String inputId = mHdmiInputIdMap.get(deviceInfo.getId());
                         SomeArgs args = SomeArgs.obtain();
                         args.arg1 = inputId;
                         args.arg2 = deviceInfo;
@@ -1006,6 +1003,15 @@
                 }
             }
         }
+
+        private HdmiDeviceInfo findHdmiDeviceInfo(int id) {
+            for (HdmiDeviceInfo info : mHdmiDeviceList) {
+                if (info.getId() == id) {
+                    return info;
+                }
+            }
+            return null;
+        }
     }
 
     private final class HdmiSystemAudioModeChangeListener extends
@@ -1015,7 +1021,9 @@
             synchronized (mLock) {
                 for (int i = 0; i < mConnections.size(); ++i) {
                     TvInputHardwareImpl impl = mConnections.valueAt(i).getHardwareImplLocked();
-                    impl.handleAudioSinkUpdated();
+                    if (impl != null) {
+                        impl.handleAudioSinkUpdated();
+                    }
                 }
             }
         }
diff --git a/services/core/java/com/android/server/tv/TvInputManagerService.java b/services/core/java/com/android/server/tv/TvInputManagerService.java
index 88ce860..dc355c4 100644
--- a/services/core/java/com/android/server/tv/TvInputManagerService.java
+++ b/services/core/java/com/android/server/tv/TvInputManagerService.java
@@ -33,6 +33,7 @@
 import android.content.IntentFilter;
 import android.content.OperationApplicationException;
 import android.content.ServiceConnection;
+import android.content.pm.ActivityInfo;
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
 import android.content.pm.ServiceInfo;
@@ -49,9 +50,11 @@
 import android.media.tv.ITvInputSession;
 import android.media.tv.ITvInputSessionCallback;
 import android.media.tv.TvContentRating;
+import android.media.tv.TvContentRatingSystemInfo;
 import android.media.tv.TvContract;
 import android.media.tv.TvInputHardwareInfo;
 import android.media.tv.TvInputInfo;
+import android.media.tv.TvInputManager;
 import android.media.tv.TvInputService;
 import android.media.tv.TvStreamConfig;
 import android.media.tv.TvTrackInfo;
@@ -82,6 +85,7 @@
 import java.io.IOException;
 import java.io.PrintWriter;
 import java.util.ArrayList;
+import java.util.Arrays;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
@@ -91,8 +95,7 @@
 
 /** This class provides a system service that manages television inputs. */
 public final class TvInputManagerService extends SystemService {
-    // STOPSHIP: Turn debugging off.
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
     private static final String TAG = "TvInputManagerService";
 
     private final Context mContext;
@@ -116,7 +119,7 @@
 
         mContext = context;
         mContentResolver = context.getContentResolver();
-        mWatchLogHandler = new WatchLogHandler(IoThread.get().getLooper());
+        mWatchLogHandler = new WatchLogHandler(mContentResolver, IoThread.get().getLooper());
 
         mTvInputHardwareManager = new TvInputHardwareManager(context, new HardwareListener());
 
@@ -136,7 +139,8 @@
             registerBroadcastReceivers();
         } else if (phase == SystemService.PHASE_THIRD_PARTY_APPS_CAN_START) {
             synchronized (mLock) {
-                buildTvInputListLocked(mCurrentUserId);
+                buildTvInputListLocked(mCurrentUserId, null);
+                buildTvContentRatingSystemListLocked(mCurrentUserId);
             }
         }
         mTvInputHardwareManager.onBootPhase(phase);
@@ -144,17 +148,64 @@
 
     private void registerBroadcastReceivers() {
         PackageMonitor monitor = new PackageMonitor() {
+            private void buildTvInputList(String[] packages) {
+                synchronized (mLock) {
+                    buildTvInputListLocked(getChangingUserId(), packages);
+                    buildTvContentRatingSystemListLocked(getChangingUserId());
+                }
+            }
+
+            @Override
+            public void onPackageUpdateFinished(String packageName, int uid) {
+                if (DEBUG) Slog.d(TAG, "onPackageUpdateFinished(packageName=" + packageName + ")");
+                // This callback is invoked when the TV input is reinstalled.
+                // In this case, isReplacing() always returns true.
+                buildTvInputList(new String[] { packageName });
+            }
+
+            @Override
+            public void onPackagesAvailable(String[] packages) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onPackagesAvailable(packages=" + Arrays.toString(packages) + ")");
+                }
+                // This callback is invoked when the media on which some packages exist become
+                // available.
+                if (isReplacing()) {
+                    buildTvInputList(packages);
+                }
+            }
+
+            @Override
+            public void onPackagesUnavailable(String[] packages) {
+                // This callback is invoked when the media on which some packages exist become
+                // unavailable.
+                if (DEBUG)  {
+                    Slog.d(TAG, "onPackagesUnavailable(packages=" + Arrays.toString(packages)
+                            + ")");
+                }
+                if (isReplacing()) {
+                    buildTvInputList(packages);
+                }
+            }
+
             @Override
             public void onSomePackagesChanged() {
-                synchronized (mLock) {
-                    buildTvInputListLocked(mCurrentUserId);
+                // TODO: Use finer-grained methods(e.g. onPackageAdded, onPackageRemoved) to manage
+                // the TV inputs.
+                if (DEBUG) Slog.d(TAG, "onSomePackagesChanged()");
+                if (isReplacing()) {
+                    if (DEBUG) Slog.d(TAG, "Skipped building TV input list due to replacing");
+                    // When the package is updated, buildTvInputListLocked is called in other
+                    // methods instead.
+                    return;
                 }
+                buildTvInputList(null);
             }
 
             @Override
             public void onPackageRemoved(String packageName, int uid) {
                 synchronized (mLock) {
-                    UserState userState = getUserStateLocked(mCurrentUserId);
+                    UserState userState = getUserStateLocked(getChangingUserId());
                     if (!userState.packageSet.contains(packageName)) {
                         // Not a TV input package.
                         return;
@@ -179,7 +230,7 @@
                 try {
                     results = mContentResolver.applyBatch(TvContract.AUTHORITY, operations);
                 } catch (RemoteException | OperationApplicationException e) {
-                    Slog.e(TAG, "error in applyBatch" + e);
+                    Slog.e(TAG, "error in applyBatch", e);
                 }
 
                 if (DEBUG) {
@@ -212,7 +263,7 @@
                 component.getPackageName()) == PackageManager.PERMISSION_GRANTED;
     }
 
-    private void buildTvInputListLocked(int userId) {
+    private void buildTvInputListLocked(int userId, String[] updatedPackages) {
         UserState userState = getUserStateLocked(userId);
         userState.packageSet.clear();
 
@@ -239,58 +290,89 @@
                     // let it add TvInputInfo objects to mInputList if there's any.
                     serviceState = new ServiceState(component, userId);
                     userState.serviceStateMap.put(component, serviceState);
+                    updateServiceConnectionLocked(component, userId);
                 } else {
-                    inputList.addAll(serviceState.mInputList);
+                    inputList.addAll(serviceState.inputList);
                 }
             } else {
                 try {
                     inputList.add(TvInputInfo.createTvInputInfo(mContext, ri));
                 } catch (XmlPullParserException | IOException e) {
-                    Slog.e(TAG, "Failed to load TV input " + si.name, e);
+                    Slog.e(TAG, "failed to load TV input " + si.name, e);
                     continue;
                 }
             }
-
-            // Reconnect the service if existing input is updated.
-            updateServiceConnectionLocked(component, userId);
             userState.packageSet.add(si.packageName);
         }
 
         Map<String, TvInputState> inputMap = new HashMap<String, TvInputState>();
         for (TvInputInfo info : inputList) {
-            if (DEBUG) Slog.d(TAG, "add " + info.getId());
+            if (DEBUG) {
+                Slog.d(TAG, "add " + info.getId());
+            }
             TvInputState state = userState.inputMap.get(info.getId());
             if (state == null) {
                 state = new TvInputState();
             }
-            state.mInfo = info;
+            state.info = info;
             inputMap.put(info.getId(), state);
         }
 
         for (String inputId : inputMap.keySet()) {
             if (!userState.inputMap.containsKey(inputId)) {
                 notifyInputAddedLocked(userState, inputId);
+            } else if (updatedPackages != null) {
+                // Notify the package updates
+                ComponentName component = inputMap.get(inputId).info.getComponent();
+                for (String updatedPackage : updatedPackages) {
+                    if (component.getPackageName().equals(updatedPackage)) {
+                        updateServiceConnectionLocked(component, userId);
+                        notifyInputUpdatedLocked(userState, inputId);
+                        break;
+                    }
+                }
             }
         }
 
         for (String inputId : userState.inputMap.keySet()) {
             if (!inputMap.containsKey(inputId)) {
+                TvInputInfo info = userState.inputMap.get(inputId).info;
+                ServiceState serviceState = userState.serviceStateMap.get(info.getComponent());
+                if (serviceState != null) {
+                    abortPendingCreateSessionRequestsLocked(serviceState, inputId, userId);
+                }
                 notifyInputRemovedLocked(userState, inputId);
             }
         }
 
         userState.inputMap.clear();
         userState.inputMap = inputMap;
+    }
 
-        userState.ratingSystemXmlUriSet.clear();
-        userState.ratingSystemXmlUriSet.add(TvContentRating.SYSTEM_CONTENT_RATING_SYSTEM_XML);
-        for (TvInputState state : userState.inputMap.values()) {
-            Uri ratingSystemXmlUri = state.mInfo.getRatingSystemXmlUri();
-            if (ratingSystemXmlUri != null) {
-                // TODO: need to check the validation of xml format and the duplication of rating
-                // systems.
-                userState.ratingSystemXmlUriSet.add(state.mInfo.getRatingSystemXmlUri());
+    private void buildTvContentRatingSystemListLocked(int userId) {
+        UserState userState = getUserStateLocked(userId);
+        userState.contentRatingSystemList.clear();
+
+        final PackageManager pm = mContext.getPackageManager();
+        Intent intent = new Intent(TvInputManager.ACTION_QUERY_CONTENT_RATING_SYSTEMS);
+        for (ResolveInfo resolveInfo :
+                pm.queryBroadcastReceivers(intent, PackageManager.GET_META_DATA)) {
+            ActivityInfo receiver = resolveInfo.activityInfo;
+            Bundle metaData = receiver.metaData;
+            if (metaData == null) {
+                continue;
             }
+
+            int xmlResId = metaData.getInt(TvInputManager.META_DATA_CONTENT_RATING_SYSTEMS);
+            if (xmlResId == 0) {
+                Slog.w(TAG, "Missing meta-data '"
+                        + TvInputManager.META_DATA_CONTENT_RATING_SYSTEMS + "' on receiver "
+                        + receiver.packageName + "/" + receiver.name);
+                continue;
+            }
+            userState.contentRatingSystemList.add(
+                    TvContentRatingSystemInfo.createTvContentRatingSystemInfo(xmlResId,
+                            receiver.applicationInfo));
         }
     }
 
@@ -308,7 +390,8 @@
                 userState = new UserState(mContext, userId);
             }
             mUserStates.put(userId, userState);
-            buildTvInputListLocked(userId);
+            buildTvInputListLocked(userId, null);
+            buildTvContentRatingSystemListLocked(userId);
         }
     }
 
@@ -320,9 +403,9 @@
             }
             // Release created sessions.
             for (SessionState state : userState.sessionStateMap.values()) {
-                if (state.mSession != null) {
+                if (state.session != null) {
                     try {
-                        state.mSession.release();
+                        state.session.release();
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in release", e);
                     }
@@ -332,18 +415,24 @@
 
             // Unregister all callbacks and unbind all services.
             for (ServiceState serviceState : userState.serviceStateMap.values()) {
-                if (serviceState.mCallback != null) {
+                if (serviceState.callback != null) {
                     try {
-                        serviceState.mService.unregisterCallback(serviceState.mCallback);
+                        serviceState.service.unregisterCallback(serviceState.callback);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in unregisterCallback", e);
                     }
                 }
-                mContext.unbindService(serviceState.mConnection);
+                mContext.unbindService(serviceState.connection);
             }
             userState.serviceStateMap.clear();
 
+            // Clear everything else.
+            userState.inputMap.clear();
+            userState.packageSet.clear();
+            userState.contentRatingSystemList.clear();
             userState.clientStateMap.clear();
+            userState.callbackSet.clear();
+            userState.mainSessionToken = null;
 
             mUserStates.remove(userId);
         }
@@ -374,7 +463,7 @@
             throw new IllegalArgumentException("Session state not found for token " + sessionToken);
         }
         // Only the application that requested this session or the system can access it.
-        if (callingUid != Process.SYSTEM_UID && callingUid != sessionState.mCallingUid) {
+        if (callingUid != Process.SYSTEM_UID && callingUid != sessionState.callingUid) {
             throw new SecurityException("Illegal access to the session with token " + sessionToken
                     + " from uid " + callingUid);
         }
@@ -386,10 +475,10 @@
     }
 
     private ITvInputSession getSessionLocked(SessionState sessionState) {
-        ITvInputSession session = sessionState.mSession;
+        ITvInputSession session = sessionState.session;
         if (session == null) {
             throw new IllegalStateException("Session not yet created for token "
-                    + sessionState.mSessionToken);
+                    + sessionState.sessionToken);
         }
         return session;
     }
@@ -401,8 +490,8 @@
     }
 
     private static boolean shouldMaintainConnection(ServiceState serviceState) {
-        return !serviceState.mSessionTokens.isEmpty() || serviceState.mIsHardware;
-        // TODO: Find a way to maintain connection only when necessary.
+        return !serviceState.sessionTokens.isEmpty() || serviceState.isHardware;
+        // TODO: Find a way to maintain connection to hardware TV input service only when necessary.
     }
 
     private void updateServiceConnectionLocked(ComponentName component, int userId) {
@@ -411,18 +500,18 @@
         if (serviceState == null) {
             return;
         }
-        if (serviceState.mReconnecting) {
-            if (!serviceState.mSessionTokens.isEmpty()) {
+        if (serviceState.reconnecting) {
+            if (!serviceState.sessionTokens.isEmpty()) {
                 // wait until all the sessions are removed.
                 return;
             }
-            serviceState.mReconnecting = false;
+            serviceState.reconnecting = false;
         }
         boolean maintainConnection = shouldMaintainConnection(serviceState);
-        if (serviceState.mService == null && maintainConnection && userId == mCurrentUserId) {
+        if (serviceState.service == null && maintainConnection && userId == mCurrentUserId) {
             // This means that the service is not yet connected but its state indicates that we
             // have pending requests. Then, connect the service.
-            if (serviceState.mBound) {
+            if (serviceState.bound) {
                 // We have already bound to the service so we don't try to bind again until after we
                 // unbind later on.
                 return;
@@ -432,249 +521,59 @@
             }
 
             Intent i = new Intent(TvInputService.SERVICE_INTERFACE).setComponent(component);
-            // Binding service may fail if the service is updating.
-            // In that case, the connection will be revived in buildTvInputListLocked called by
-            // onSomePackagesChanged.
-            serviceState.mBound = mContext.bindServiceAsUser(
-                    i, serviceState.mConnection, Context.BIND_AUTO_CREATE, new UserHandle(userId));
-        } else if (serviceState.mService != null && !maintainConnection) {
+            serviceState.bound = mContext.bindServiceAsUser(
+                    i, serviceState.connection, Context.BIND_AUTO_CREATE, new UserHandle(userId));
+        } else if (serviceState.service != null && !maintainConnection) {
             // This means that the service is already connected but its state indicates that we have
             // nothing to do with it. Then, disconnect the service.
             if (DEBUG) {
                 Slog.d(TAG, "unbindService(service=" + component + ")");
             }
-            mContext.unbindService(serviceState.mConnection);
+            mContext.unbindService(serviceState.connection);
             userState.serviceStateMap.remove(component);
         }
     }
 
-    private ClientState createClientStateLocked(IBinder clientToken, int userId) {
+    private void abortPendingCreateSessionRequestsLocked(ServiceState serviceState,
+            String inputId, int userId) {
+        // Let clients know the create session requests are failed.
         UserState userState = getUserStateLocked(userId);
-        ClientState clientState = new ClientState(clientToken, userId);
-        try {
-            clientToken.linkToDeath(clientState, 0);
-        } catch (RemoteException e) {
-            Slog.e(TAG, "Client is already died.");
+        List<SessionState> sessionsToAbort = new ArrayList<>();
+        for (IBinder sessionToken : serviceState.sessionTokens) {
+            SessionState sessionState = userState.sessionStateMap.get(sessionToken);
+            if (sessionState.session == null && (inputId == null
+                    || sessionState.info.getId().equals(inputId))) {
+                sessionsToAbort.add(sessionState);
+            }
         }
-        userState.clientStateMap.put(clientToken, clientState);
-        return clientState;
+        for (SessionState sessionState : sessionsToAbort) {
+            removeSessionStateLocked(sessionState.sessionToken, sessionState.userId);
+            sendSessionTokenToClientLocked(sessionState.client,
+                    sessionState.info.getId(), null, null, sessionState.seq);
+        }
+        updateServiceConnectionLocked(serviceState.component, userId);
     }
 
-    private void createSessionInternalLocked(ITvInputService service, final IBinder sessionToken,
-            final int userId) {
-        final UserState userState = getUserStateLocked(userId);
-        final SessionState sessionState = userState.sessionStateMap.get(sessionToken);
+    private void createSessionInternalLocked(ITvInputService service, IBinder sessionToken,
+            int userId) {
+        UserState userState = getUserStateLocked(userId);
+        SessionState sessionState = userState.sessionStateMap.get(sessionToken);
         if (DEBUG) {
-            Slog.d(TAG, "createSessionInternalLocked(inputId=" + sessionState.mInfo.getId() + ")");
+            Slog.d(TAG, "createSessionInternalLocked(inputId=" + sessionState.info.getId() + ")");
         }
-
-        final InputChannel[] channels = InputChannel.openInputChannelPair(sessionToken.toString());
+        InputChannel[] channels = InputChannel.openInputChannelPair(sessionToken.toString());
 
         // Set up a callback to send the session token.
-        ITvInputSessionCallback callback = new ITvInputSessionCallback.Stub() {
-            @Override
-            public void onSessionCreated(ITvInputSession session, IBinder harewareSessionToken) {
-                if (DEBUG) {
-                    Slog.d(TAG, "onSessionCreated(inputId=" + sessionState.mInfo.getId() + ")");
-                }
-                synchronized (mLock) {
-                    sessionState.mSession = session;
-                    sessionState.mHardwareSessionToken = harewareSessionToken;
-                    if (session == null) {
-                        removeSessionStateLocked(sessionToken, userId);
-                        sendSessionTokenToClientLocked(sessionState.mClient,
-                                sessionState.mInfo.getId(), null, null, sessionState.mSeq);
-                    } else {
-                        try {
-                            session.asBinder().linkToDeath(sessionState, 0);
-                        } catch (RemoteException e) {
-                            Slog.e(TAG, "Session is already died.");
-                        }
-
-                        IBinder clientToken = sessionState.mClient.asBinder();
-                        ClientState clientState = userState.clientStateMap.get(clientToken);
-                        if (clientState == null) {
-                            clientState = createClientStateLocked(clientToken, userId);
-                        }
-                        clientState.mSessionTokens.add(sessionState.mSessionToken);
-
-                        sendSessionTokenToClientLocked(sessionState.mClient,
-                                sessionState.mInfo.getId(), sessionToken, channels[0],
-                                sessionState.mSeq);
-                    }
-                    channels[0].dispose();
-                }
-            }
-
-            @Override
-            public void onChannelRetuned(Uri channelUri) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onChannelRetuned(" + channelUri + ")");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        // TODO: Consider adding this channel change in the watch log. When we do
-                        // that, how we can protect the watch log from malicious tv inputs should
-                        // be addressed. e.g. add a field which represents where the channel change
-                        // originated from.
-                        sessionState.mClient.onChannelRetuned(channelUri, sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onChannelRetuned");
-                    }
-                }
-            }
-
-            @Override
-            public void onTracksChanged(List<TvTrackInfo> tracks) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onTracksChanged(" + tracks + ")");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onTracksChanged(tracks, sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onTracksChanged");
-                    }
-                }
-            }
-
-            @Override
-            public void onTrackSelected(int type, String trackId) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onTrackSelected(type=" + type + ", trackId=" + trackId + ")");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onTrackSelected(type, trackId, sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onTrackSelected");
-                    }
-                }
-            }
-
-            @Override
-            public void onVideoAvailable() {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onVideoAvailable()");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onVideoAvailable(sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onVideoAvailable");
-                    }
-                }
-            }
-
-            @Override
-            public void onVideoUnavailable(int reason) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onVideoUnavailable(" + reason + ")");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onVideoUnavailable(reason, sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onVideoUnavailable");
-                    }
-                }
-            }
-
-            @Override
-            public void onContentAllowed() {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onContentAllowed()");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onContentAllowed(sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onContentAllowed");
-                    }
-                }
-            }
-
-            @Override
-            public void onContentBlocked(String rating) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onContentBlocked()");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onContentBlocked(rating, sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onContentBlocked");
-                    }
-                }
-            }
-
-            @Override
-            public void onLayoutSurface(int left, int top, int right, int bottom) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onLayoutSurface (left=" + left + ", top=" + top
-                                + ", right=" + right + ", bottom=" + bottom + ",)");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onLayoutSurface(left, top, right, bottom,
-                                sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onLayoutSurface");
-                    }
-                }
-            }
-
-            @Override
-            public void onSessionEvent(String eventType, Bundle eventArgs) {
-                synchronized (mLock) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "onEvent(what=" + eventType + ", data=" + eventArgs + ")");
-                    }
-                    if (sessionState.mSession == null || sessionState.mClient == null) {
-                        return;
-                    }
-                    try {
-                        sessionState.mClient.onSessionEvent(eventType, eventArgs,
-                                sessionState.mSeq);
-                    } catch (RemoteException e) {
-                        Slog.e(TAG, "error in onSessionEvent");
-                    }
-                }
-            }
-        };
+        ITvInputSessionCallback callback = new SessionCallback(sessionState, channels);
 
         // Create a session. When failed, send a null token immediately.
         try {
-            service.createSession(channels[1], callback, sessionState.mInfo.getId());
+            service.createSession(channels[1], callback, sessionState.info.getId());
         } catch (RemoteException e) {
             Slog.e(TAG, "error in createSession", e);
             removeSessionStateLocked(sessionToken, userId);
-            sendSessionTokenToClientLocked(sessionState.mClient, sessionState.mInfo.getId(), null,
-                    null, sessionState.mSeq);
+            sendSessionTokenToClientLocked(sessionState.client, sessionState.info.getId(), null,
+                    null, sessionState.seq);
         }
         channels[1].dispose();
     }
@@ -683,20 +582,24 @@
             IBinder sessionToken, InputChannel channel, int seq) {
         try {
             client.onSessionCreated(inputId, sessionToken, channel, seq);
-        } catch (RemoteException exception) {
-            Slog.e(TAG, "error in onSessionCreated", exception);
+        } catch (RemoteException e) {
+            Slog.e(TAG, "error in onSessionCreated", e);
         }
     }
 
     private void releaseSessionLocked(IBinder sessionToken, int callingUid, int userId) {
         SessionState sessionState = getSessionStateLocked(sessionToken, callingUid, userId);
-        if (sessionState.mSession != null) {
-            try {
-                sessionState.mSession.release();
-            } catch (RemoteException e) {
-                Slog.w(TAG, "session is already disapeared", e);
+        if (sessionState.session != null) {
+            UserState userState = getUserStateLocked(userId);
+            if (sessionToken == userState.mainSessionToken) {
+                setMainLocked(sessionToken, false, callingUid, userId);
             }
-            sessionState.mSession = null;
+            try {
+                sessionState.session.release();
+            } catch (RemoteException e) {
+                Slog.e(TAG, "session process has already died", e);
+            }
+            sessionState.session = null;
         }
         removeSessionStateLocked(sessionToken, userId);
     }
@@ -704,6 +607,9 @@
     private void removeSessionStateLocked(IBinder sessionToken, int userId) {
         UserState userState = getUserStateLocked(userId);
         if (sessionToken == userState.mainSessionToken) {
+            if (DEBUG) {
+                Slog.d(TAG, "mainSessionToken=null");
+            }
             userState.mainSessionToken = null;
         }
 
@@ -716,22 +622,22 @@
 
         // Also remove the session token from the session token list of the current client and
         // service.
-        ClientState clientState = userState.clientStateMap.get(sessionState.mClient.asBinder());
+        ClientState clientState = userState.clientStateMap.get(sessionState.client.asBinder());
         if (clientState != null) {
-            clientState.mSessionTokens.remove(sessionToken);
+            clientState.sessionTokens.remove(sessionToken);
             if (clientState.isEmpty()) {
-                userState.clientStateMap.remove(sessionState.mClient.asBinder());
+                userState.clientStateMap.remove(sessionState.client.asBinder());
             }
         }
 
-        TvInputInfo info = sessionState.mInfo;
+        TvInputInfo info = sessionState.info;
         if (info != null) {
             ServiceState serviceState = userState.serviceStateMap.get(info.getComponent());
             if (serviceState != null) {
-                serviceState.mSessionTokens.remove(sessionToken);
+                serviceState.sessionTokens.remove(sessionToken);
             }
         }
-        updateServiceConnectionLocked(sessionState.mInfo.getComponent(), userId);
+        updateServiceConnectionLocked(sessionState.info.getComponent(), userId);
 
         // Log the end of watch.
         SomeArgs args = SomeArgs.obtain();
@@ -740,28 +646,59 @@
         mWatchLogHandler.obtainMessage(WatchLogHandler.MSG_LOG_WATCH_END, args).sendToTarget();
     }
 
+    private void setMainLocked(IBinder sessionToken, boolean isMain, int callingUid, int userId) {
+        SessionState sessionState = getSessionStateLocked(sessionToken, callingUid, userId);
+        if (sessionState.hardwareSessionToken != null) {
+            sessionState = getSessionStateLocked(sessionState.hardwareSessionToken,
+                    Process.SYSTEM_UID, userId);
+        }
+        ServiceState serviceState = getServiceStateLocked(sessionState.info.getComponent(), userId);
+        if (!serviceState.isHardware) {
+            return;
+        }
+        ITvInputSession session = getSessionLocked(sessionState);
+        try {
+            session.setMain(isMain);
+        } catch (RemoteException e) {
+            Slog.e(TAG, "error in setMain", e);
+        }
+    }
+
     private void notifyInputAddedLocked(UserState userState, String inputId) {
         if (DEBUG) {
-            Slog.d(TAG, "notifyInputAdded: inputId = " + inputId);
+            Slog.d(TAG, "notifyInputAddedLocked(inputId=" + inputId + ")");
         }
         for (ITvInputManagerCallback callback : userState.callbackSet) {
             try {
                 callback.onInputAdded(inputId);
             } catch (RemoteException e) {
-                Slog.e(TAG, "Failed to report added input to callback.");
+                Slog.e(TAG, "failed to report added input to callback", e);
             }
         }
     }
 
     private void notifyInputRemovedLocked(UserState userState, String inputId) {
         if (DEBUG) {
-            Slog.d(TAG, "notifyInputRemovedLocked: inputId = " + inputId);
+            Slog.d(TAG, "notifyInputRemovedLocked(inputId=" + inputId + ")");
         }
         for (ITvInputManagerCallback callback : userState.callbackSet) {
             try {
                 callback.onInputRemoved(inputId);
             } catch (RemoteException e) {
-                Slog.e(TAG, "Failed to report removed input to callback.");
+                Slog.e(TAG, "failed to report removed input to callback", e);
+            }
+        }
+    }
+
+    private void notifyInputUpdatedLocked(UserState userState, String inputId) {
+        if (DEBUG) {
+            Slog.d(TAG, "notifyInputUpdatedLocked(inputId=" + inputId + ")");
+        }
+        for (ITvInputManagerCallback callback : userState.callbackSet) {
+            try {
+                callback.onInputUpdated(inputId);
+            } catch (RemoteException e) {
+                Slog.e(TAG, "failed to report updated input to callback", e);
             }
         }
     }
@@ -769,22 +706,22 @@
     private void notifyInputStateChangedLocked(UserState userState, String inputId,
             int state, ITvInputManagerCallback targetCallback) {
         if (DEBUG) {
-            Slog.d(TAG, "notifyInputStateChangedLocked: inputId = " + inputId
-                    + "; state = " + state);
+            Slog.d(TAG, "notifyInputStateChangedLocked(inputId=" + inputId
+                    + ", state=" + state + ")");
         }
         if (targetCallback == null) {
             for (ITvInputManagerCallback callback : userState.callbackSet) {
                 try {
                     callback.onInputStateChanged(inputId, state);
                 } catch (RemoteException e) {
-                    Slog.e(TAG, "Failed to report state change to callback.");
+                    Slog.e(TAG, "failed to report state change to callback", e);
                 }
             }
         } else {
             try {
                 targetCallback.onInputStateChanged(inputId, state);
             } catch (RemoteException e) {
-                Slog.e(TAG, "Failed to report state change to callback.");
+                Slog.e(TAG, "failed to report state change to callback", e);
             }
         }
     }
@@ -792,10 +729,10 @@
     private void setStateLocked(String inputId, int state, int userId) {
         UserState userState = getUserStateLocked(userId);
         TvInputState inputState = userState.inputMap.get(inputId);
-        ServiceState serviceState = userState.serviceStateMap.get(inputState.mInfo.getComponent());
-        int oldState = inputState.mState;
-        inputState.mState = state;
-        if (serviceState != null && serviceState.mService == null
+        ServiceState serviceState = userState.serviceStateMap.get(inputState.info.getComponent());
+        int oldState = inputState.state;
+        inputState.state = state;
+        if (serviceState != null && serviceState.service == null
                 && shouldMaintainConnection(serviceState)) {
             // We don't notify state change while reconnecting. It should remain disconnected.
             return;
@@ -816,7 +753,7 @@
                     UserState userState = getUserStateLocked(resolvedUserId);
                     List<TvInputInfo> inputList = new ArrayList<TvInputInfo>();
                     for (TvInputState state : userState.inputMap.values()) {
-                        inputList.add(state.mInfo);
+                        inputList.add(state.info);
                     }
                     return inputList;
                 }
@@ -834,7 +771,7 @@
                 synchronized (mLock) {
                     UserState userState = getUserStateLocked(resolvedUserId);
                     TvInputState state = userState.inputMap.get(inputId);
-                    return state == null ? null : state.mInfo;
+                    return state == null ? null : state.info;
                 }
             } finally {
                 Binder.restoreCallingIdentity(identity);
@@ -842,16 +779,14 @@
         }
 
         @Override
-        public List<Uri> getTvContentRatingSystemXmls(int userId) {
+        public List<TvContentRatingSystemInfo> getTvContentRatingSystemList(int userId) {
             final int resolvedUserId = resolveCallingUserId(Binder.getCallingPid(),
-                    Binder.getCallingUid(), userId, "getTvContentRatingSystemXmls");
+                    Binder.getCallingUid(), userId, "getTvContentRatingSystemList");
             final long identity = Binder.clearCallingIdentity();
             try {
                 synchronized (mLock) {
                     UserState userState = getUserStateLocked(resolvedUserId);
-                    List<Uri> ratingSystemXmlUriList = new ArrayList<Uri>();
-                    ratingSystemXmlUriList.addAll(userState.ratingSystemXmlUriSet);
-                    return ratingSystemXmlUriList;
+                    return userState.contentRatingSystemList;
                 }
             } finally {
                 Binder.restoreCallingIdentity(identity);
@@ -865,11 +800,25 @@
             final long identity = Binder.clearCallingIdentity();
             try {
                 synchronized (mLock) {
-                    UserState userState = getUserStateLocked(resolvedUserId);
+                    final UserState userState = getUserStateLocked(resolvedUserId);
                     userState.callbackSet.add(callback);
+                    try {
+                        callback.asBinder().linkToDeath(new IBinder.DeathRecipient() {
+                            @Override
+                            public void binderDied() {
+                                synchronized (mLock) {
+                                    if (userState.callbackSet != null) {
+                                        userState.callbackSet.remove(callback);
+                                    }
+                                }
+                            }
+                        }, 0);
+                    } catch (RemoteException e) {
+                        Slog.e(TAG, "client process has already died", e);
+                    }
                     for (TvInputState state : userState.inputMap.values()) {
-                        notifyInputStateChangedLocked(userState, state.mInfo.getId(),
-                                state.mState, callback);
+                        notifyInputStateChangedLocked(userState, state.info.getId(), state.state,
+                                callback);
                     }
                 }
             } finally {
@@ -994,13 +943,12 @@
         }
 
         private void ensureParentalControlsPermission() {
-            // STOPSHIP: Uncomment when b/16984416 is resolved.
-            //if (mContext.checkCallingPermission(
-            //        android.Manifest.permission.MODIFY_PARENTAL_CONTROLS)
-            //        != PackageManager.PERMISSION_GRANTED) {
-            //    throw new SecurityException(
-            //            "The caller does not have parental controls permission");
-            //}
+            if (mContext.checkCallingPermission(
+                    android.Manifest.permission.MODIFY_PARENTAL_CONTROLS)
+                    != PackageManager.PERMISSION_GRANTED) {
+                throw new SecurityException(
+                        "The caller does not have parental controls permission");
+            }
         }
 
         @Override
@@ -1013,14 +961,20 @@
             try {
                 synchronized (mLock) {
                     UserState userState = getUserStateLocked(resolvedUserId);
-                    TvInputInfo info = userState.inputMap.get(inputId).mInfo;
+                    TvInputState inputState = userState.inputMap.get(inputId);
+                    if (inputState == null) {
+                        Slog.w(TAG, "Failed to find input state for inputId=" + inputId);
+                        sendSessionTokenToClientLocked(client, inputId, null, null, seq);
+                        return;
+                    }
+                    TvInputInfo info = inputState.info;
                     ServiceState serviceState = userState.serviceStateMap.get(info.getComponent());
                     if (serviceState == null) {
                         serviceState = new ServiceState(info.getComponent(), resolvedUserId);
                         userState.serviceStateMap.put(info.getComponent(), serviceState);
                     }
                     // Send a null token immediately while reconnecting.
-                    if (serviceState.mReconnecting == true) {
+                    if (serviceState.reconnecting == true) {
                         sendSessionTokenToClientLocked(client, inputId, null, null, seq);
                         return;
                     }
@@ -1034,10 +988,10 @@
                     userState.sessionStateMap.put(sessionToken, sessionState);
 
                     // Also, add them to the session state map of the current service.
-                    serviceState.mSessionTokens.add(sessionToken);
+                    serviceState.sessionTokens.add(sessionToken);
 
-                    if (serviceState.mService != null) {
-                        createSessionInternalLocked(serviceState.mService, sessionToken,
+                    if (serviceState.service != null) {
+                        createSessionInternalLocked(serviceState.service, sessionToken,
                                 resolvedUserId);
                     } else {
                         updateServiceConnectionLocked(info.getComponent(), resolvedUserId);
@@ -1050,6 +1004,9 @@
 
         @Override
         public void releaseSession(IBinder sessionToken, int userId) {
+            if (DEBUG) {
+                Slog.d(TAG, "releaseSession(sessionToken=" + sessionToken + ")");
+            }
             final int callingUid = Binder.getCallingUid();
             final int resolvedUserId = resolveCallingUserId(Binder.getCallingPid(), callingUid,
                     userId, "releaseSession");
@@ -1065,6 +1022,9 @@
 
         @Override
         public void setMainSession(IBinder sessionToken, int userId) {
+            if (DEBUG) {
+                Slog.d(TAG, "setMainSession(sessionToken=" + sessionToken + ")");
+            }
             final int callingUid = Binder.getCallingUid();
             final int resolvedUserId = resolveCallingUserId(Binder.getCallingPid(), callingUid,
                     userId, "setMainSession");
@@ -1075,50 +1035,19 @@
                     if (userState.mainSessionToken == sessionToken) {
                         return;
                     }
-
-                    SessionState newMainSessionState = getSessionStateLocked(
-                            sessionToken, callingUid, resolvedUserId);
-                    if (newMainSessionState.mHardwareSessionToken != null) {
-                        newMainSessionState = getSessionStateLocked(
-                                newMainSessionState.mHardwareSessionToken,
-                                Process.SYSTEM_UID, resolvedUserId);
+                    if (DEBUG) {
+                        Slog.d(TAG, "mainSessionToken=" + sessionToken);
                     }
-                    ServiceState newMainServiceState = getServiceStateLocked(
-                            newMainSessionState.mInfo.getComponent(), resolvedUserId);
-                    ITvInputSession newMainSession = getSessionLocked(newMainSessionState);
-
-                    ServiceState oldMainServiceState = null;
-                    ITvInputSession oldMainSession = null;
-                    if (userState.mainSessionToken != null) {
-                        SessionState oldMainSessionState = getSessionStateLocked(
-                                userState.mainSessionToken, Process.SYSTEM_UID, resolvedUserId);
-                        if (oldMainSessionState.mHardwareSessionToken != null) {
-                            oldMainSessionState = getSessionStateLocked(
-                                    oldMainSessionState.mHardwareSessionToken,
-                                    Process.SYSTEM_UID, resolvedUserId);
-                        }
-                        oldMainServiceState = getServiceStateLocked(
-                                oldMainSessionState.mInfo.getComponent(), resolvedUserId);
-                        oldMainSession = getSessionLocked(oldMainSessionState);
-                    }
-
+                    IBinder oldMainSessionToken = userState.mainSessionToken;
                     userState.mainSessionToken = sessionToken;
 
                     // Inform the new main session first.
-                    // See {@link TvInputService#onSetMainSession}.
-                    if (newMainServiceState.mIsHardware) {
-                        try {
-                            newMainSession.setMainSession(true);
-                        } catch (RemoteException e) {
-                            Slog.e(TAG, "error in setMainSession", e);
-                        }
+                    // See {@link TvInputService.Session#onSetMain}.
+                    if (sessionToken != null) {
+                        setMainLocked(sessionToken, true, callingUid, userId);
                     }
-                    if (oldMainSession != null && oldMainServiceState.mIsHardware) {
-                        try {
-                            oldMainSession.setMainSession(false);
-                        } catch (RemoteException e) {
-                            Slog.e(TAG, "error in setMainSession", e);
-                        }
+                    if (oldMainSessionToken != null) {
+                        setMainLocked(oldMainSessionToken, false, Process.SYSTEM_UID, userId);
                     }
                 }
             } finally {
@@ -1137,10 +1066,10 @@
                     try {
                         SessionState sessionState = getSessionStateLocked(sessionToken, callingUid,
                                 resolvedUserId);
-                        if (sessionState.mHardwareSessionToken == null) {
+                        if (sessionState.hardwareSessionToken == null) {
                             getSessionLocked(sessionState).setSurface(surface);
                         } else {
-                            getSessionLocked(sessionState.mHardwareSessionToken,
+                            getSessionLocked(sessionState.hardwareSessionToken,
                                     Process.SYSTEM_UID, resolvedUserId).setSurface(surface);
                         }
                     } catch (RemoteException e) {
@@ -1168,9 +1097,10 @@
                     try {
                         SessionState sessionState = getSessionStateLocked(sessionToken, callingUid,
                                 resolvedUserId);
-                        getSessionLocked(sessionState).dispatchSurfaceChanged(format, width, height);
-                        if (sessionState.mHardwareSessionToken != null) {
-                            getSessionLocked(sessionState.mHardwareSessionToken, Process.SYSTEM_UID,
+                        getSessionLocked(sessionState).dispatchSurfaceChanged(format, width,
+                                height);
+                        if (sessionState.hardwareSessionToken != null) {
+                            getSessionLocked(sessionState.hardwareSessionToken, Process.SYSTEM_UID,
                                     resolvedUserId).dispatchSurfaceChanged(format, width, height);
                         }
                     } catch (RemoteException e) {
@@ -1196,10 +1126,10 @@
                         SessionState sessionState = getSessionStateLocked(sessionToken, callingUid,
                                 resolvedUserId);
                         getSessionLocked(sessionState).setVolume(volume);
-                        if (sessionState.mHardwareSessionToken != null) {
+                        if (sessionState.hardwareSessionToken != null) {
                             // Here, we let the hardware session know only whether volume is on or
                             // off to prevent that the volume is controlled in the both side.
-                            getSessionLocked(sessionState.mHardwareSessionToken,
+                            getSessionLocked(sessionState.hardwareSessionToken,
                                     Process.SYSTEM_UID, resolvedUserId).setVolume((volume > 0.0f)
                                             ? REMOTE_VOLUME_ON : REMOTE_VOLUME_OFF);
                         }
@@ -1233,7 +1163,7 @@
 
                         // Log the start of watch.
                         SomeArgs args = SomeArgs.obtain();
-                        args.arg1 = sessionState.mInfo.getComponent().getPackageName();
+                        args.arg1 = sessionState.info.getComponent().getPackageName();
                         args.arg2 = System.currentTimeMillis();
                         args.arg3 = ContentUris.parseId(channelUri);
                         args.arg4 = params;
@@ -1263,7 +1193,7 @@
                         getSessionLocked(sessionToken, callingUid, resolvedUserId)
                                 .requestUnblockContent(unblockedRating);
                     } catch (RemoteException e) {
-                        Slog.e(TAG, "error in unblockContent", e);
+                        Slog.e(TAG, "error in requestUnblockContent", e);
                     }
                 }
             } finally {
@@ -1324,7 +1254,7 @@
                         getSessionLocked(sessionToken, callingUid, resolvedUserId)
                                 .appPrivateCommand(command, data);
                     } catch (RemoteException e) {
-                        Slog.e(TAG, "error in sendAppPrivateCommand", e);
+                        Slog.e(TAG, "error in appPrivateCommand", e);
                     }
                 }
             } finally {
@@ -1489,14 +1419,14 @@
                 synchronized (mLock) {
                     UserState userState = getUserStateLocked(resolvedUserId);
                     if (userState.inputMap.get(inputId) == null) {
-                        Slog.e(TAG, "Input not found for " + inputId);
+                        Slog.e(TAG, "input not found for " + inputId);
                         return false;
                     }
                     for (SessionState sessionState : userState.sessionStateMap.values()) {
-                        if (sessionState.mInfo.getId().equals(inputId)
-                                && sessionState.mHardwareSessionToken != null) {
+                        if (sessionState.info.getId().equals(inputId)
+                                && sessionState.hardwareSessionToken != null) {
                             hardwareInputId = userState.sessionStateMap.get(
-                                    sessionState.mHardwareSessionToken).mInfo.getId();
+                                    sessionState.hardwareSessionToken).info.getId();
                             break;
                         }
                     }
@@ -1525,8 +1455,8 @@
                         SessionState[] sessionStates = userState.sessionStateMap.values().toArray(
                                 new SessionState[0]);
                         // Check if there is a wrapper input.
-                        if (sessionStates[0].mHardwareSessionToken != null
-                                || sessionStates[1].mHardwareSessionToken != null) {
+                        if (sessionStates[0].hardwareSessionToken != null
+                                || sessionStates[1].hardwareSessionToken != null) {
                             return true;
                         }
                     }
@@ -1586,15 +1516,15 @@
 
                         pw.increaseIndent();
 
-                        pw.println("mSessionTokens:");
+                        pw.println("sessionTokens:");
                         pw.increaseIndent();
-                        for (IBinder token : client.mSessionTokens) {
+                        for (IBinder token : client.sessionTokens) {
                             pw.println("" + token);
                         }
                         pw.decreaseIndent();
 
-                        pw.println("mClientTokens: " + client.mClientToken);
-                        pw.println("mUserId: " + client.mUserId);
+                        pw.println("clientTokens: " + client.clientToken);
+                        pw.println("userId: " + client.userId);
 
                         pw.decreaseIndent();
                     }
@@ -1609,17 +1539,17 @@
 
                         pw.increaseIndent();
 
-                        pw.println("mSessionTokens:");
+                        pw.println("sessionTokens:");
                         pw.increaseIndent();
-                        for (IBinder token : service.mSessionTokens) {
+                        for (IBinder token : service.sessionTokens) {
                             pw.println("" + token);
                         }
                         pw.decreaseIndent();
 
-                        pw.println("mService: " + service.mService);
-                        pw.println("mCallback: " + service.mCallback);
-                        pw.println("mBound: " + service.mBound);
-                        pw.println("mReconnecting: " + service.mReconnecting);
+                        pw.println("service: " + service.service);
+                        pw.println("callback: " + service.callback);
+                        pw.println("bound: " + service.bound);
+                        pw.println("reconnecting: " + service.reconnecting);
 
                         pw.decreaseIndent();
                     }
@@ -1633,15 +1563,15 @@
                         pw.println(entry.getKey() + ": " + session);
 
                         pw.increaseIndent();
-                        pw.println("mInfo: " + session.mInfo);
-                        pw.println("mClient: " + session.mClient);
-                        pw.println("mSeq: " + session.mSeq);
-                        pw.println("mCallingUid: " + session.mCallingUid);
-                        pw.println("mUserId: " + session.mUserId);
-                        pw.println("mSessionToken: " + session.mSessionToken);
-                        pw.println("mSession: " + session.mSession);
-                        pw.println("mLogUri: " + session.mLogUri);
-                        pw.println("mHardwareSessionToken: " + session.mHardwareSessionToken);
+                        pw.println("info: " + session.info);
+                        pw.println("client: " + session.client);
+                        pw.println("seq: " + session.seq);
+                        pw.println("callingUid: " + session.callingUid);
+                        pw.println("userId: " + session.userId);
+                        pw.println("sessionToken: " + session.sessionToken);
+                        pw.println("session: " + session.session);
+                        pw.println("logUri: " + session.logUri);
+                        pw.println("hardwareSessionToken: " + session.hardwareSessionToken);
                         pw.decreaseIndent();
                     }
                     pw.decreaseIndent();
@@ -1660,19 +1590,6 @@
         }
     }
 
-    private static final class TvInputState {
-        // A TvInputInfo object which represents the TV input.
-        private TvInputInfo mInfo;
-
-        // The state of TV input. Connected by default.
-        private int mState = INPUT_STATE_CONNECTED;
-
-        @Override
-        public String toString() {
-            return "mInfo: " + mInfo + "; mState: " + mState;
-        }
-    }
-
     private static final class UserState {
         // A mapping from the TV input id to its TvInputState.
         private Map<String, TvInputState> inputMap = new HashMap<String, TvInputState>();
@@ -1680,8 +1597,9 @@
         // A set of all TV input packages.
         private final Set<String> packageSet = new HashSet<String>();
 
-        // A set of all TV content rating system xml uris.
-        private final Set<Uri> ratingSystemXmlUriSet = new HashSet<Uri>();
+        // A list of all TV content rating systems defined.
+        private final List<TvContentRatingSystemInfo>
+                contentRatingSystemList = new ArrayList<TvContentRatingSystemInfo>();
 
         // A mapping from the token of a client to its state.
         private final Map<IBinder, ClientState> clientStateMap =
@@ -1712,107 +1630,117 @@
     }
 
     private final class ClientState implements IBinder.DeathRecipient {
-        private final List<IBinder> mSessionTokens = new ArrayList<IBinder>();
+        private final List<IBinder> sessionTokens = new ArrayList<IBinder>();
 
-        private IBinder mClientToken;
-        private final int mUserId;
+        private IBinder clientToken;
+        private final int userId;
 
         ClientState(IBinder clientToken, int userId) {
-            mClientToken = clientToken;
-            mUserId = userId;
+            this.clientToken = clientToken;
+            this.userId = userId;
         }
 
         public boolean isEmpty() {
-            return mSessionTokens.isEmpty();
+            return sessionTokens.isEmpty();
         }
 
         @Override
         public void binderDied() {
             synchronized (mLock) {
-                UserState userState = getUserStateLocked(mUserId);
+                UserState userState = getUserStateLocked(userId);
                 // DO NOT remove the client state of clientStateMap in this method. It will be
                 // removed in releaseSessionLocked().
-                ClientState clientState = userState.clientStateMap.get(mClientToken);
+                ClientState clientState = userState.clientStateMap.get(clientToken);
                 if (clientState != null) {
-                    while (clientState.mSessionTokens.size() > 0) {
+                    while (clientState.sessionTokens.size() > 0) {
                         releaseSessionLocked(
-                                clientState.mSessionTokens.get(0), Process.SYSTEM_UID, mUserId);
+                                clientState.sessionTokens.get(0), Process.SYSTEM_UID, userId);
                     }
                 }
-                mClientToken = null;
+                clientToken = null;
             }
         }
     }
 
     private final class ServiceState {
-        private final List<IBinder> mSessionTokens = new ArrayList<IBinder>();
-        private final ServiceConnection mConnection;
-        private final ComponentName mComponent;
-        private final boolean mIsHardware;
-        private final List<TvInputInfo> mInputList = new ArrayList<TvInputInfo>();
+        private final List<IBinder> sessionTokens = new ArrayList<IBinder>();
+        private final ServiceConnection connection;
+        private final ComponentName component;
+        private final boolean isHardware;
+        private final List<TvInputInfo> inputList = new ArrayList<TvInputInfo>();
 
-        private ITvInputService mService;
-        private ServiceCallback mCallback;
-        private boolean mBound;
-        private boolean mReconnecting;
+        private ITvInputService service;
+        private ServiceCallback callback;
+        private boolean bound;
+        private boolean reconnecting;
 
         private ServiceState(ComponentName component, int userId) {
-            mComponent = component;
-            mConnection = new InputServiceConnection(component, userId);
-            mIsHardware = hasHardwarePermission(mContext.getPackageManager(), mComponent);
+            this.component = component;
+            this.connection = new InputServiceConnection(component, userId);
+            this.isHardware = hasHardwarePermission(mContext.getPackageManager(), component);
+        }
+    }
+
+    private static final class TvInputState {
+        // A TvInputInfo object which represents the TV input.
+        private TvInputInfo info;
+
+        // The state of TV input. Connected by default.
+        private int state = INPUT_STATE_CONNECTED;
+
+        @Override
+        public String toString() {
+            return "info: " + info + "; state: " + state;
         }
     }
 
     private final class SessionState implements IBinder.DeathRecipient {
-        private final TvInputInfo mInfo;
-        private final ITvInputClient mClient;
-        private final int mSeq;
-        private final int mCallingUid;
-        private final int mUserId;
-        private final IBinder mSessionToken;
-        private ITvInputSession mSession;
-        private Uri mLogUri;
+        private final TvInputInfo info;
+        private final ITvInputClient client;
+        private final int seq;
+        private final int callingUid;
+        private final int userId;
+        private final IBinder sessionToken;
+        private ITvInputSession session;
+        private Uri logUri;
         // Not null if this session represents an external device connected to a hardware TV input.
-        private IBinder mHardwareSessionToken;
+        private IBinder hardwareSessionToken;
 
         private SessionState(IBinder sessionToken, TvInputInfo info, ITvInputClient client,
                 int seq, int callingUid, int userId) {
-            mSessionToken = sessionToken;
-            mInfo = info;
-            mClient = client;
-            mSeq = seq;
-            mCallingUid = callingUid;
-            mUserId = userId;
+            this.sessionToken = sessionToken;
+            this.info = info;
+            this.client = client;
+            this.seq = seq;
+            this.callingUid = callingUid;
+            this.userId = userId;
         }
 
         @Override
         public void binderDied() {
             synchronized (mLock) {
-                mSession = null;
-                if (mClient != null) {
+                session = null;
+                if (client != null) {
                     try {
-                        mClient.onSessionReleased(mSeq);
+                        client.onSessionReleased(seq);
                     } catch(RemoteException e) {
                         Slog.e(TAG, "error in onSessionReleased", e);
                     }
                 }
                 // If there are any other sessions based on this session, they should be released.
-                UserState userState = getUserStateLocked(mUserId);
+                UserState userState = getUserStateLocked(userId);
                 for (SessionState sessionState : userState.sessionStateMap.values()) {
-                    if (mSessionToken == sessionState.mHardwareSessionToken) {
+                    if (sessionToken == sessionState.hardwareSessionToken) {
+                        releaseSessionLocked(sessionState.sessionToken, Process.SYSTEM_UID,
+                                userId);
                         try {
-                            sessionState.mSession.release();
-                        } catch (RemoteException e) {
-                            Slog.e(TAG, "error in release", e);
-                        }
-                        try {
-                            sessionState.mClient.onSessionReleased(sessionState.mSeq);
+                            sessionState.client.onSessionReleased(sessionState.seq);
                         } catch (RemoteException e) {
                             Slog.e(TAG, "error in onSessionReleased", e);
                         }
                     }
                 }
-                removeSessionStateLocked(mSessionToken, mUserId);
+                removeSessionStateLocked(sessionToken, userId);
             }
         }
     }
@@ -1834,37 +1762,37 @@
             synchronized (mLock) {
                 UserState userState = getUserStateLocked(mUserId);
                 ServiceState serviceState = userState.serviceStateMap.get(mComponent);
-                serviceState.mService = ITvInputService.Stub.asInterface(service);
+                serviceState.service = ITvInputService.Stub.asInterface(service);
 
                 // Register a callback, if we need to.
-                if (serviceState.mIsHardware && serviceState.mCallback == null) {
-                    serviceState.mCallback = new ServiceCallback(mComponent, mUserId);
+                if (serviceState.isHardware && serviceState.callback == null) {
+                    serviceState.callback = new ServiceCallback(mComponent, mUserId);
                     try {
-                        serviceState.mService.registerCallback(serviceState.mCallback);
+                        serviceState.service.registerCallback(serviceState.callback);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in registerCallback", e);
                     }
                 }
 
                 // And create sessions, if any.
-                for (IBinder sessionToken : serviceState.mSessionTokens) {
-                    createSessionInternalLocked(serviceState.mService, sessionToken, mUserId);
+                for (IBinder sessionToken : serviceState.sessionTokens) {
+                    createSessionInternalLocked(serviceState.service, sessionToken, mUserId);
                 }
 
                 for (TvInputState inputState : userState.inputMap.values()) {
-                    if (inputState.mInfo.getComponent().equals(component)
-                            && inputState.mState != INPUT_STATE_DISCONNECTED) {
-                        notifyInputStateChangedLocked(userState, inputState.mInfo.getId(),
-                                inputState.mState, null);
+                    if (inputState.info.getComponent().equals(component)
+                            && inputState.state != INPUT_STATE_DISCONNECTED) {
+                        notifyInputStateChangedLocked(userState, inputState.info.getId(),
+                                inputState.state, null);
                     }
                 }
 
-                if (serviceState.mIsHardware) {
+                if (serviceState.isHardware) {
                     List<TvInputHardwareInfo> hardwareInfoList =
                             mTvInputHardwareManager.getHardwareList();
                     for (TvInputHardwareInfo hardwareInfo : hardwareInfoList) {
                         try {
-                            serviceState.mService.notifyHardwareAdded(hardwareInfo);
+                            serviceState.service.notifyHardwareAdded(hardwareInfo);
                         } catch (RemoteException e) {
                             Slog.e(TAG, "error in notifyHardwareAdded", e);
                         }
@@ -1874,7 +1802,7 @@
                             mTvInputHardwareManager.getHdmiDeviceList();
                     for (HdmiDeviceInfo deviceInfo : deviceInfoList) {
                         try {
-                            serviceState.mService.notifyHdmiDeviceAdded(deviceInfo);
+                            serviceState.service.notifyHdmiDeviceAdded(deviceInfo);
                         } catch (RemoteException e) {
                             Slog.e(TAG, "error in notifyHdmiDeviceAdded", e);
                         }
@@ -1896,28 +1824,19 @@
                 UserState userState = getUserStateLocked(mUserId);
                 ServiceState serviceState = userState.serviceStateMap.get(mComponent);
                 if (serviceState != null) {
-                    serviceState.mReconnecting = true;
-                    serviceState.mBound = false;
-                    serviceState.mService = null;
-                    serviceState.mCallback = null;
+                    serviceState.reconnecting = true;
+                    serviceState.bound = false;
+                    serviceState.service = null;
+                    serviceState.callback = null;
 
-                    // Send null tokens for not finishing create session events.
-                    for (IBinder sessionToken : serviceState.mSessionTokens) {
-                        SessionState sessionState = userState.sessionStateMap.get(sessionToken);
-                        if (sessionState.mSession == null) {
-                            removeSessionStateLocked(sessionToken, sessionState.mUserId);
-                            sendSessionTokenToClientLocked(sessionState.mClient,
-                                    sessionState.mInfo.getId(), null, null, sessionState.mSeq);
-                        }
-                    }
+                    abortPendingCreateSessionRequestsLocked(serviceState, null, mUserId);
 
                     for (TvInputState inputState : userState.inputMap.values()) {
-                        if (inputState.mInfo.getComponent().equals(component)) {
-                            notifyInputStateChangedLocked(userState, inputState.mInfo.getId(),
+                        if (inputState.info.getComponent().equals(component)) {
+                            notifyInputStateChangedLocked(userState, inputState.info.getId(),
                                     INPUT_STATE_DISCONNECTED, null);
                         }
                     }
-                    updateServiceConnectionLocked(mComponent, mUserId);
                 }
             }
         }
@@ -1947,8 +1866,8 @@
 
         private void addTvInputLocked(TvInputInfo inputInfo) {
             ServiceState serviceState = getServiceStateLocked(mComponent, mUserId);
-            serviceState.mInputList.add(inputInfo);
-            buildTvInputListLocked(mUserId);
+            serviceState.inputList.add(inputInfo);
+            buildTvInputListLocked(mUserId, null);
         }
 
         @Override
@@ -1977,7 +1896,7 @@
             synchronized (mLock) {
                 ServiceState serviceState = getServiceStateLocked(mComponent, mUserId);
                 boolean removed = false;
-                for (Iterator<TvInputInfo> it = serviceState.mInputList.iterator();
+                for (Iterator<TvInputInfo> it = serviceState.inputList.iterator();
                         it.hasNext(); ) {
                     if (it.next().getId().equals(inputId)) {
                         it.remove();
@@ -1986,16 +1905,231 @@
                     }
                 }
                 if (removed) {
-                    buildTvInputListLocked(mUserId);
+                    buildTvInputListLocked(mUserId, null);
                     mTvInputHardwareManager.removeTvInput(inputId);
                 } else {
-                    Slog.e(TAG, "TvInputInfo with inputId=" + inputId + " not found.");
+                    Slog.e(TAG, "failed to remove input " + inputId);
                 }
             }
         }
     }
 
-    private final class WatchLogHandler extends Handler {
+    private final class SessionCallback extends ITvInputSessionCallback.Stub {
+        private final SessionState mSessionState;
+        private final InputChannel[] mChannels;
+
+        SessionCallback(SessionState sessionState, InputChannel[] channels) {
+            mSessionState = sessionState;
+            mChannels = channels;
+        }
+
+        @Override
+        public void onSessionCreated(ITvInputSession session, IBinder harewareSessionToken) {
+            if (DEBUG) {
+                Slog.d(TAG, "onSessionCreated(inputId=" + mSessionState.info.getId() + ")");
+            }
+            synchronized (mLock) {
+                mSessionState.session = session;
+                mSessionState.hardwareSessionToken = harewareSessionToken;
+                if (session != null && addSessionTokenToClientStateLocked(session)) {
+                    sendSessionTokenToClientLocked(mSessionState.client,
+                            mSessionState.info.getId(), mSessionState.sessionToken, mChannels[0],
+                            mSessionState.seq);
+                } else {
+                    removeSessionStateLocked(mSessionState.sessionToken, mSessionState.userId);
+                    sendSessionTokenToClientLocked(mSessionState.client,
+                            mSessionState.info.getId(), null, null, mSessionState.seq);
+                }
+                mChannels[0].dispose();
+            }
+        }
+
+        private boolean addSessionTokenToClientStateLocked(ITvInputSession session) {
+            try {
+                session.asBinder().linkToDeath(mSessionState, 0);
+            } catch (RemoteException e) {
+                Slog.e(TAG, "session process has already died", e);
+                return false;
+            }
+
+            IBinder clientToken = mSessionState.client.asBinder();
+            UserState userState = getUserStateLocked(mSessionState.userId);
+            ClientState clientState = userState.clientStateMap.get(clientToken);
+            if (clientState == null) {
+                clientState = new ClientState(clientToken, mSessionState.userId);
+                try {
+                    clientToken.linkToDeath(clientState, 0);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "client process has already died", e);
+                    return false;
+                }
+                userState.clientStateMap.put(clientToken, clientState);
+            }
+            clientState.sessionTokens.add(mSessionState.sessionToken);
+            return true;
+        }
+
+        @Override
+        public void onChannelRetuned(Uri channelUri) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onChannelRetuned(" + channelUri + ")");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    // TODO: Consider adding this channel change in the watch log. When we do
+                    // that, how we can protect the watch log from malicious tv inputs should
+                    // be addressed. e.g. add a field which represents where the channel change
+                    // originated from.
+                    mSessionState.client.onChannelRetuned(channelUri, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onChannelRetuned", e);
+                }
+            }
+        }
+
+        @Override
+        public void onTracksChanged(List<TvTrackInfo> tracks) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onTracksChanged(" + tracks + ")");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onTracksChanged(tracks, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onTracksChanged", e);
+                }
+            }
+        }
+
+        @Override
+        public void onTrackSelected(int type, String trackId) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onTrackSelected(type=" + type + ", trackId=" + trackId + ")");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onTrackSelected(type, trackId, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onTrackSelected", e);
+                }
+            }
+        }
+
+        @Override
+        public void onVideoAvailable() {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onVideoAvailable()");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onVideoAvailable(mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onVideoAvailable", e);
+                }
+            }
+        }
+
+        @Override
+        public void onVideoUnavailable(int reason) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onVideoUnavailable(" + reason + ")");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onVideoUnavailable(reason, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onVideoUnavailable", e);
+                }
+            }
+        }
+
+        @Override
+        public void onContentAllowed() {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onContentAllowed()");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onContentAllowed(mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onContentAllowed", e);
+                }
+            }
+        }
+
+        @Override
+        public void onContentBlocked(String rating) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onContentBlocked()");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onContentBlocked(rating, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onContentBlocked", e);
+                }
+            }
+        }
+
+        @Override
+        public void onLayoutSurface(int left, int top, int right, int bottom) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onLayoutSurface (left=" + left + ", top=" + top
+                            + ", right=" + right + ", bottom=" + bottom + ",)");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onLayoutSurface(left, top, right, bottom,
+                            mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onLayoutSurface", e);
+                }
+            }
+        }
+
+        @Override
+        public void onSessionEvent(String eventType, Bundle eventArgs) {
+            synchronized (mLock) {
+                if (DEBUG) {
+                    Slog.d(TAG, "onEvent(what=" + eventType + ", data=" + eventArgs + ")");
+                }
+                if (mSessionState.session == null || mSessionState.client == null) {
+                    return;
+                }
+                try {
+                    mSessionState.client.onSessionEvent(eventType, eventArgs, mSessionState.seq);
+                } catch (RemoteException e) {
+                    Slog.e(TAG, "error in onSessionEvent", e);
+                }
+            }
+        }
+    }
+
+    private static final class WatchLogHandler extends Handler {
         // There are only two kinds of watch events that can happen on the system:
         // 1. The current TV input session is tuned to a new channel.
         // 2. The session is released for some reason.
@@ -2007,8 +2141,11 @@
         private static final int MSG_LOG_WATCH_START = 1;
         private static final int MSG_LOG_WATCH_END = 2;
 
-        public WatchLogHandler(Looper looper) {
+        private final ContentResolver mContentResolver;
+
+        public WatchLogHandler(ContentResolver contentResolver, Looper looper) {
             super(looper);
+            mContentResolver = contentResolver;
         }
 
         @Override
@@ -2094,7 +2231,7 @@
         }
     }
 
-    final class HardwareListener implements TvInputHardwareManager.Listener {
+    private final class HardwareListener implements TvInputHardwareManager.Listener {
         @Override
         public void onStateChanged(String inputId, int state) {
             synchronized (mLock) {
@@ -2108,9 +2245,9 @@
                 UserState userState = getUserStateLocked(mCurrentUserId);
                 // Broadcast the event to all hardware inputs.
                 for (ServiceState serviceState : userState.serviceStateMap.values()) {
-                    if (!serviceState.mIsHardware || serviceState.mService == null) continue;
+                    if (!serviceState.isHardware || serviceState.service == null) continue;
                     try {
-                        serviceState.mService.notifyHardwareAdded(info);
+                        serviceState.service.notifyHardwareAdded(info);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in notifyHardwareAdded", e);
                     }
@@ -2124,9 +2261,9 @@
                 UserState userState = getUserStateLocked(mCurrentUserId);
                 // Broadcast the event to all hardware inputs.
                 for (ServiceState serviceState : userState.serviceStateMap.values()) {
-                    if (!serviceState.mIsHardware || serviceState.mService == null) continue;
+                    if (!serviceState.isHardware || serviceState.service == null) continue;
                     try {
-                        serviceState.mService.notifyHardwareRemoved(info);
+                        serviceState.service.notifyHardwareRemoved(info);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in notifyHardwareRemoved", e);
                     }
@@ -2140,9 +2277,9 @@
                 UserState userState = getUserStateLocked(mCurrentUserId);
                 // Broadcast the event to all hardware inputs.
                 for (ServiceState serviceState : userState.serviceStateMap.values()) {
-                    if (!serviceState.mIsHardware || serviceState.mService == null) continue;
+                    if (!serviceState.isHardware || serviceState.service == null) continue;
                     try {
-                        serviceState.mService.notifyHdmiDeviceAdded(deviceInfo);
+                        serviceState.service.notifyHdmiDeviceAdded(deviceInfo);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in notifyHdmiDeviceAdded", e);
                     }
@@ -2156,9 +2293,9 @@
                 UserState userState = getUserStateLocked(mCurrentUserId);
                 // Broadcast the event to all hardware inputs.
                 for (ServiceState serviceState : userState.serviceStateMap.values()) {
-                    if (!serviceState.mIsHardware || serviceState.mService == null) continue;
+                    if (!serviceState.isHardware || serviceState.service == null) continue;
                     try {
-                        serviceState.mService.notifyHdmiDeviceRemoved(deviceInfo);
+                        serviceState.service.notifyHdmiDeviceRemoved(deviceInfo);
                     } catch (RemoteException e) {
                         Slog.e(TAG, "error in notifyHdmiDeviceRemoved", e);
                     }
diff --git a/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java b/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java
index 3eb2d5f..a8245e7 100644
--- a/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java
+++ b/services/core/java/com/android/server/wallpaper/WallpaperManagerService.java
@@ -42,6 +42,7 @@
 import android.content.pm.UserInfo;
 import android.content.res.Resources;
 import android.graphics.Point;
+import android.graphics.Rect;
 import android.os.Binder;
 import android.os.Bundle;
 import android.os.Environment;
@@ -85,6 +86,7 @@
 import com.android.internal.content.PackageMonitor;
 import com.android.internal.util.FastXmlSerializer;
 import com.android.internal.util.JournaledFile;
+import com.android.internal.R;
 
 public class WallpaperManagerService extends IWallpaperManager.Stub {
     static final String TAG = "WallpaperManagerService";
@@ -99,12 +101,6 @@
     static final long MIN_WALLPAPER_CRASH_TIME = 10000;
     static final String WALLPAPER = "wallpaper";
     static final String WALLPAPER_INFO = "wallpaper_info.xml";
-    /**
-     * Name of the component used to display bitmap wallpapers from either the gallery or
-     * built-in wallpapers.
-     */
-    static final ComponentName IMAGE_WALLPAPER = new ComponentName("com.android.systemui",
-            "com.android.systemui.ImageWallpaper");
 
     /**
      * Observes the wallpaper for changes and notifies all IWallpaperServiceCallbacks
@@ -146,7 +142,7 @@
                         if (event == CLOSE_WRITE) {
                             mWallpaper.imageWallpaperPending = false;
                         }
-                        bindWallpaperComponentLocked(IMAGE_WALLPAPER, true,
+                        bindWallpaperComponentLocked(mImageWallpaper, true,
                                 false, mWallpaper, null);
                         saveSettingsLocked(mWallpaper);
                     }
@@ -161,6 +157,12 @@
     final MyPackageMonitor mMonitor;
     WallpaperData mLastWallpaper;
 
+    /**
+     * Name of the component used to display bitmap wallpapers from either the gallery or
+     * built-in wallpapers.
+     */
+    final ComponentName mImageWallpaper;
+
     SparseArray<WallpaperData> mWallpaperMap = new SparseArray<WallpaperData>();
 
     int mCurrentUserId;
@@ -205,6 +207,8 @@
         int width = -1;
         int height = -1;
 
+        final Rect padding = new Rect(0, 0, 0, 0);
+
         WallpaperData(int userId) {
             this.userId = userId;
             wallpaperFile = new File(getWallpaperDir(userId), WALLPAPER);
@@ -221,6 +225,7 @@
         IRemoteCallback mReply;
 
         boolean mDimensionsChanged = false;
+        boolean mPaddingChanged = false;
 
         public WallpaperConnection(WallpaperInfo info, WallpaperData wallpaper) {
             mInfo = info;
@@ -282,6 +287,14 @@
                     }
                     mDimensionsChanged = false;
                 }
+                if (mPaddingChanged) {
+                    try {
+                        mEngine.setDisplayPadding(mWallpaper.padding);
+                    } catch (RemoteException e) {
+                        Slog.w(TAG, "Failed to set wallpaper padding", e);
+                    }
+                    mPaddingChanged = false;
+                }
             }
         }
 
@@ -447,6 +460,8 @@
     public WallpaperManagerService(Context context) {
         if (DEBUG) Slog.v(TAG, "WallpaperService startup");
         mContext = context;
+        mImageWallpaper = ComponentName.unflattenFromString(
+                context.getResources().getString(R.string.image_wallpaper_component));
         mIWindowManager = IWindowManager.Stub.asInterface(
                 ServiceManager.getService(Context.WINDOW_SERVICE));
         mIPackageManager = AppGlobals.getPackageManager();
@@ -599,33 +614,35 @@
             f.delete();
         }
         final long ident = Binder.clearCallingIdentity();
-        RuntimeException e = null;
         try {
-            wallpaper.imageWallpaperPending = false;
-            if (userId != mCurrentUserId) return;
-            if (bindWallpaperComponentLocked(defaultFailed
-                    ? IMAGE_WALLPAPER
-                    : null, true, false, wallpaper, reply)) {
-                return;
+            RuntimeException e = null;
+            try {
+                wallpaper.imageWallpaperPending = false;
+                if (userId != mCurrentUserId) return;
+                if (bindWallpaperComponentLocked(defaultFailed
+                        ? mImageWallpaper
+                                : null, true, false, wallpaper, reply)) {
+                    return;
+                }
+            } catch (IllegalArgumentException e1) {
+                e = e1;
             }
-        } catch (IllegalArgumentException e1) {
-            e = e1;
+
+            // This can happen if the default wallpaper component doesn't
+            // exist.  This should be a system configuration problem, but
+            // let's not let it crash the system and just live with no
+            // wallpaper.
+            Slog.e(TAG, "Default wallpaper component not found!", e);
+            clearWallpaperComponentLocked(wallpaper);
+            if (reply != null) {
+                try {
+                    reply.sendResult(null);
+                } catch (RemoteException e1) {
+                }
+            }
         } finally {
             Binder.restoreCallingIdentity(ident);
         }
-        
-        // This can happen if the default wallpaper component doesn't
-        // exist.  This should be a system configuration problem, but
-        // let's not let it crash the system and just live with no
-        // wallpaper.
-        Slog.e(TAG, "Default wallpaper component not found!", e);
-        clearWallpaperComponentLocked(wallpaper);
-        if (reply != null) {
-            try {
-                reply.sendResult(null);
-            } catch (RemoteException e1) {
-            }
-        }
     }
 
     public boolean hasNamedWallpaper(String name) {
@@ -714,6 +731,40 @@
         }
     }
 
+    public void setDisplayPadding(Rect padding) {
+        checkPermission(android.Manifest.permission.SET_WALLPAPER_HINTS);
+        synchronized (mLock) {
+            int userId = UserHandle.getCallingUserId();
+            WallpaperData wallpaper = mWallpaperMap.get(userId);
+            if (wallpaper == null) {
+                throw new IllegalStateException("Wallpaper not yet initialized for user " + userId);
+            }
+            if (padding.left < 0 || padding.top < 0 || padding.right < 0 || padding.bottom < 0) {
+                throw new IllegalArgumentException("padding must be positive: " + padding);
+            }
+
+            if (!padding.equals(wallpaper.padding)) {
+                wallpaper.padding.set(padding);
+                saveSettingsLocked(wallpaper);
+                if (mCurrentUserId != userId) return; // Don't change the properties now
+                if (wallpaper.connection != null) {
+                    if (wallpaper.connection.mEngine != null) {
+                        try {
+                            wallpaper.connection.mEngine.setDisplayPadding(padding);
+                        } catch (RemoteException e) {
+                        }
+                        notifyCallbacksLocked(wallpaper);
+                    } else if (wallpaper.connection.mService != null) {
+                        // We've attached to the service but the engine hasn't attached back to us
+                        // yet. This means it will be created with the previous dimensions, so we
+                        // need to update it to the new dimensions once it attaches.
+                        wallpaper.connection.mPaddingChanged = true;
+                    }
+                }
+            }
+        }
+    }
+
     public ParcelFileDescriptor getWallpaper(IWallpaperManagerCallback cb,
             Bundle outParams) {
         synchronized (mLock) {
@@ -792,7 +843,7 @@
             }
             File file = new File(dir, WALLPAPER);
             ParcelFileDescriptor fd = ParcelFileDescriptor.open(file,
-                    MODE_CREATE|MODE_READ_WRITE);
+                    MODE_CREATE|MODE_READ_WRITE|MODE_TRUNCATE);
             if (!SELinux.restorecon(file)) {
                 return null;
             }
@@ -848,7 +899,7 @@
                 componentName = WallpaperManager.getDefaultWallpaperComponent(mContext);
                 if (componentName == null) {
                     // Fall back to static image wallpaper
-                    componentName = IMAGE_WALLPAPER;
+                    componentName = mImageWallpaper;
                     //clearWallpaperComponentLocked();
                     //return;
                     if (DEBUG) Slog.v(TAG, "Using image wallpaper");
@@ -876,7 +927,7 @@
             WallpaperInfo wi = null;
             
             Intent intent = new Intent(WallpaperService.SERVICE_INTERFACE);
-            if (componentName != null && !componentName.equals(IMAGE_WALLPAPER)) {
+            if (componentName != null && !componentName.equals(mImageWallpaper)) {
                 // Make sure the selected service is actually a wallpaper service.
                 List<ResolveInfo> ris =
                         mIPackageManager.queryIntentServices(intent,
@@ -1001,7 +1052,7 @@
         try {
             conn.mService.attach(conn, conn.mToken,
                     WindowManager.LayoutParams.TYPE_WALLPAPER, false,
-                    wallpaper.width, wallpaper.height);
+                    wallpaper.width, wallpaper.height, wallpaper.padding);
         } catch (RemoteException e) {
             Slog.w(TAG, "Failed attaching wallpaper; clearing", e);
             if (!wallpaper.wallpaperUpdating) {
@@ -1050,9 +1101,21 @@
             out.startTag(null, "wp");
             out.attribute(null, "width", Integer.toString(wallpaper.width));
             out.attribute(null, "height", Integer.toString(wallpaper.height));
+            if (wallpaper.padding.left != 0) {
+                out.attribute(null, "paddingLeft", Integer.toString(wallpaper.padding.left));
+            }
+            if (wallpaper.padding.top != 0) {
+                out.attribute(null, "paddingTop", Integer.toString(wallpaper.padding.top));
+            }
+            if (wallpaper.padding.right != 0) {
+                out.attribute(null, "paddingRight", Integer.toString(wallpaper.padding.right));
+            }
+            if (wallpaper.padding.bottom != 0) {
+                out.attribute(null, "paddingBottom", Integer.toString(wallpaper.padding.bottom));
+            }
             out.attribute(null, "name", wallpaper.name);
             if (wallpaper.wallpaperComponent != null
-                    && !wallpaper.wallpaperComponent.equals(IMAGE_WALLPAPER)) {
+                    && !wallpaper.wallpaperComponent.equals(mImageWallpaper)) {
                 out.attribute(null, "component",
                         wallpaper.wallpaperComponent.flattenToShortString());
             }
@@ -1086,6 +1149,14 @@
         }
     }
 
+    private int getAttributeInt(XmlPullParser parser, String name, int defValue) {
+        String value = parser.getAttributeValue(null, name);
+        if (value == null) {
+            return defValue;
+        }
+        return Integer.parseInt(value);
+    }
+
     private void loadSettingsLocked(int userId) {
         if (DEBUG) Slog.v(TAG, "loadSettingsLocked");
         
@@ -1116,6 +1187,10 @@
                         wallpaper.width = Integer.parseInt(parser.getAttributeValue(null, "width"));
                         wallpaper.height = Integer.parseInt(parser
                                 .getAttributeValue(null, "height"));
+                        wallpaper.padding.left = getAttributeInt(parser, "paddingLeft", 0);
+                        wallpaper.padding.top = getAttributeInt(parser, "paddingTop", 0);
+                        wallpaper.padding.right = getAttributeInt(parser, "paddingRight", 0);
+                        wallpaper.padding.bottom = getAttributeInt(parser, "paddingBottom", 0);
                         wallpaper.name = parser.getAttributeValue(null, "name");
                         String comp = parser.getAttributeValue(null, "component");
                         wallpaper.nextWallpaperComponent = comp != null
@@ -1124,7 +1199,7 @@
                         if (wallpaper.nextWallpaperComponent == null
                                 || "android".equals(wallpaper.nextWallpaperComponent
                                         .getPackageName())) {
-                            wallpaper.nextWallpaperComponent = IMAGE_WALLPAPER;
+                            wallpaper.nextWallpaperComponent = mImageWallpaper;
                         }
                           
                         if (DEBUG) {
@@ -1162,6 +1237,7 @@
         if (!success) {
             wallpaper.width = -1;
             wallpaper.height = -1;
+            wallpaper.padding.set(0, 0, 0, 0);
             wallpaper.name = "";
         }
 
@@ -1196,7 +1272,7 @@
             loadSettingsLocked(0);
             wallpaper = mWallpaperMap.get(0);
             if (wallpaper.nextWallpaperComponent != null
-                    && !wallpaper.nextWallpaperComponent.equals(IMAGE_WALLPAPER)) {
+                    && !wallpaper.nextWallpaperComponent.equals(mImageWallpaper)) {
                 if (!bindWallpaperComponentLocked(wallpaper.nextWallpaperComponent, false, false,
                         wallpaper, null)) {
                     // No such live wallpaper or other failure; fall back to the default
@@ -1325,13 +1401,12 @@
                 WallpaperData wallpaper = mWallpaperMap.valueAt(i);
                 pw.println(" User " + wallpaper.userId + ":");
                 pw.print("  mWidth=");
-                pw.print(wallpaper.width);
-                pw.print(" mHeight=");
-                pw.println(wallpaper.height);
-                pw.print("  mName=");
-                pw.println(wallpaper.name);
-                pw.print("  mWallpaperComponent=");
-                pw.println(wallpaper.wallpaperComponent);
+                    pw.print(wallpaper.width);
+                    pw.print(" mHeight=");
+                    pw.println(wallpaper.height);
+                pw.print("  mPadding="); pw.println(wallpaper.padding);
+                pw.print("  mName=");  pw.println(wallpaper.name);
+                pw.print("  mWallpaperComponent="); pw.println(wallpaper.wallpaperComponent);
                 if (wallpaper.connection != null) {
                     WallpaperConnection conn = wallpaper.connection;
                     pw.print("  Wallpaper connection ");
diff --git a/services/core/java/com/android/server/wm/AccessibilityController.java b/services/core/java/com/android/server/wm/AccessibilityController.java
index d05d0c7..fa1c0ff 100644
--- a/services/core/java/com/android/server/wm/AccessibilityController.java
+++ b/services/core/java/com/android/server/wm/AccessibilityController.java
@@ -412,8 +412,9 @@
 
             private final WindowManager mWindowManager;
 
-            private final int mBorderWidth;
+            private final float mBorderWidth;
             private final int mHalfBorderWidth;
+            private final int mDrawBorderInset;
 
             private final ViewportWindow mWindow;
 
@@ -421,10 +422,11 @@
 
             public MagnifiedViewport() {
                 mWindowManager = (WindowManager) mContext.getSystemService(Service.WINDOW_SERVICE);
-                mBorderWidth = (int) TypedValue.applyDimension(
+                mBorderWidth = TypedValue.applyDimension(
                         TypedValue.COMPLEX_UNIT_DIP, DEFAUTLT_BORDER_WIDTH_DIP,
                                 mContext.getResources().getDisplayMetrics());
-                mHalfBorderWidth = (int) (mBorderWidth + 0.5) / 2;
+                mHalfBorderWidth = (int) Math.ceil(mBorderWidth / 2);
+                mDrawBorderInset = (int) mBorderWidth / 2;
                 mWindow = new ViewportWindow(mContext);
                 recomputeBoundsLocked();
             }
@@ -437,7 +439,8 @@
                 }
                 // If this message is pending we are in a rotation animation and do not want
                 // to show the border. We will do so when the pending message is handled.
-                if (!mHandler.hasMessages(MyHandler.MESSAGE_SHOW_MAGNIFIED_REGION_BOUNDS_IF_NEEDED)) {
+                if (!mHandler.hasMessages(
+                        MyHandler.MESSAGE_SHOW_MAGNIFIED_REGION_BOUNDS_IF_NEEDED)) {
                     setMagnifiedRegionBorderShownLocked(isMagnifyingLocked(), true);
                 }
             }
@@ -454,7 +457,7 @@
                 availableBounds.set(0, 0, screenWidth, screenHeight);
 
                 Region nonMagnifiedBounds = mTempRegion4;
-                nonMagnifiedBounds.set(0,  0,  0,  0);
+                nonMagnifiedBounds.set(0, 0, 0, 0);
 
                 SparseArray<WindowState> visibleWindows = mTempWindowStates;
                 visibleWindows.clear();
@@ -513,8 +516,8 @@
 
                 visibleWindows.clear();
 
-                magnifiedBounds.op(mHalfBorderWidth, mHalfBorderWidth,
-                        screenWidth - mHalfBorderWidth, screenHeight - mHalfBorderWidth,
+                magnifiedBounds.op(mDrawBorderInset, mDrawBorderInset,
+                        screenWidth - mDrawBorderInset, screenHeight - mDrawBorderInset,
                         Region.Op.INTERSECT);
 
                 if (!mOldMagnifiedBounds.equals(magnifiedBounds)) {
@@ -527,8 +530,8 @@
                     Rect dirtyRect = mTempRect1;
                     if (mFullRedrawNeeded) {
                         mFullRedrawNeeded = false;
-                        dirtyRect.set(mHalfBorderWidth, mHalfBorderWidth,
-                                screenWidth - mHalfBorderWidth, screenHeight - mHalfBorderWidth);
+                        dirtyRect.set(mDrawBorderInset, mDrawBorderInset,
+                                screenWidth - mDrawBorderInset, screenHeight - mDrawBorderInset);
                         mWindow.invalidate(dirtyRect);
                     } else {
                         Region dirtyRegion = mTempRegion3;
@@ -563,7 +566,7 @@
             public void setMagnifiedRegionBorderShownLocked(boolean shown, boolean animate) {
                 if (shown) {
                     mFullRedrawNeeded = true;
-                    mOldMagnifiedBounds.set(0,  0,  0,  0);
+                    mOldMagnifiedBounds.set(0, 0, 0, 0);
                 }
                 mWindow.setShown(shown, animate);
             }
@@ -611,19 +614,15 @@
             private final class ViewportWindow {
                 private static final String SURFACE_TITLE = "Magnification Overlay";
 
-                private static final String PROPERTY_NAME_ALPHA = "alpha";
-
-                private static final int MIN_ALPHA = 0;
-                private static final int MAX_ALPHA = 255;
-
                 private final Region mBounds = new Region();
                 private final Rect mDirtyRect = new Rect();
                 private final Paint mPaint = new Paint();
 
-                private final ValueAnimator mShowHideFrameAnimator;
                 private final SurfaceControl mSurfaceControl;
                 private final Surface mSurface = new Surface();
 
+                private final AnimationController mAnimationController;
+
                 private boolean mShown;
                 private int mAlpha;
 
@@ -648,6 +647,9 @@
                     mSurfaceControl.setPosition(0, 0);
                     mSurface.copyFrom(mSurfaceControl);
 
+                    mAnimationController = new AnimationController(context,
+                            mWindowManagerService.mH.getLooper());
+
                     TypedValue typedValue = new TypedValue();
                     context.getTheme().resolveAttribute(R.attr.colorActivatedHighlight,
                             typedValue, true);
@@ -657,14 +659,6 @@
                     mPaint.setStrokeWidth(mBorderWidth);
                     mPaint.setColor(borderColor);
 
-                    Interpolator interpolator = new DecelerateInterpolator(2.5f);
-                    final long longAnimationDuration = context.getResources().getInteger(
-                            com.android.internal.R.integer.config_longAnimTime);
-
-                    mShowHideFrameAnimator = ObjectAnimator.ofInt(this, PROPERTY_NAME_ALPHA,
-                            MIN_ALPHA, MAX_ALPHA);
-                    mShowHideFrameAnimator.setInterpolator(interpolator);
-                    mShowHideFrameAnimator.setDuration(longAnimationDuration);
                     mInvalidated = true;
                 }
 
@@ -674,24 +668,7 @@
                             return;
                         }
                         mShown = shown;
-                        if (animate) {
-                            if (mShowHideFrameAnimator.isRunning()) {
-                                mShowHideFrameAnimator.reverse();
-                            } else {
-                                if (shown) {
-                                    mShowHideFrameAnimator.start();
-                                } else {
-                                    mShowHideFrameAnimator.reverse();
-                                }
-                            }
-                        } else {
-                            mShowHideFrameAnimator.cancel();
-                            if (shown) {
-                                setAlpha(MAX_ALPHA);
-                            } else {
-                                setAlpha(MIN_ALPHA);
-                            }
-                        }
+                        mAnimationController.onFrameShownStateChanged(shown, animate);
                         if (DEBUG_VIEWPORT_WINDOW) {
                             Slog.i(LOG_TAG, "ViewportWindow shown: " + mShown);
                         }
@@ -798,6 +775,64 @@
                     mSurfaceControl.release();
                     mSurface.release();
                 }
+
+                private final class AnimationController extends Handler {
+                    private static final String PROPERTY_NAME_ALPHA = "alpha";
+
+                    private static final int MIN_ALPHA = 0;
+                    private static final int MAX_ALPHA = 255;
+
+                    private static final int MSG_FRAME_SHOWN_STATE_CHANGED = 1;
+
+                    private final ValueAnimator mShowHideFrameAnimator;
+
+                    public AnimationController(Context context, Looper looper) {
+                        super(looper);
+                        mShowHideFrameAnimator = ObjectAnimator.ofInt(ViewportWindow.this,
+                                PROPERTY_NAME_ALPHA, MIN_ALPHA, MAX_ALPHA);
+
+                        Interpolator interpolator = new DecelerateInterpolator(2.5f);
+                        final long longAnimationDuration = context.getResources().getInteger(
+                                com.android.internal.R.integer.config_longAnimTime);
+
+                        mShowHideFrameAnimator.setInterpolator(interpolator);
+                        mShowHideFrameAnimator.setDuration(longAnimationDuration);
+                    }
+
+                    public void onFrameShownStateChanged(boolean shown, boolean animate) {
+                        obtainMessage(MSG_FRAME_SHOWN_STATE_CHANGED,
+                                shown ? 1 : 0, animate ? 1 : 0).sendToTarget();
+                    }
+
+                    @Override
+                    public void handleMessage(Message message) {
+                        switch (message.what) {
+                            case MSG_FRAME_SHOWN_STATE_CHANGED: {
+                                final boolean shown = message.arg1 == 1;
+                                final boolean animate = message.arg2 == 1;
+
+                                if (animate) {
+                                    if (mShowHideFrameAnimator.isRunning()) {
+                                        mShowHideFrameAnimator.reverse();
+                                    } else {
+                                        if (shown) {
+                                            mShowHideFrameAnimator.start();
+                                        } else {
+                                            mShowHideFrameAnimator.reverse();
+                                        }
+                                    }
+                                } else {
+                                    mShowHideFrameAnimator.cancel();
+                                    if (shown) {
+                                        setAlpha(MAX_ALPHA);
+                                    } else {
+                                        setAlpha(MIN_ALPHA);
+                                    }
+                                }
+                            } break;
+                        }
+                    }
+                }
             }
         }
 
diff --git a/services/core/java/com/android/server/wm/AppTransition.java b/services/core/java/com/android/server/wm/AppTransition.java
index f6ec86d..bfc7659 100644
--- a/services/core/java/com/android/server/wm/AppTransition.java
+++ b/services/core/java/com/android/server/wm/AppTransition.java
@@ -19,7 +19,6 @@
 import android.content.Context;
 import android.content.res.Configuration;
 import android.graphics.Bitmap;
-import android.graphics.Point;
 import android.graphics.Rect;
 import android.os.Debug;
 import android.os.Handler;
@@ -46,7 +45,7 @@
 import static com.android.internal.R.styleable.WindowAnimation_activityCloseExitAnimation;
 import static com.android.internal.R.styleable.WindowAnimation_taskOpenEnterAnimation;
 import static com.android.internal.R.styleable.WindowAnimation_taskOpenExitAnimation;
-import static com.android.internal.R.styleable.WindowAnimation_launchTaskBehindBackgroundAnimation;
+import static com.android.internal.R.styleable.WindowAnimation_launchTaskBehindTargetAnimation;
 import static com.android.internal.R.styleable.WindowAnimation_launchTaskBehindSourceAnimation;
 import static com.android.internal.R.styleable.WindowAnimation_taskCloseEnterAnimation;
 import static com.android.internal.R.styleable.WindowAnimation_taskCloseExitAnimation;
@@ -111,11 +110,14 @@
      * The new window will show briefly and then be gone. */
     public static final int TRANSIT_TASK_OPEN_BEHIND = 16;
 
+    /** Fraction of animation at which the recents thumbnail stays completely transparent */
+    private static final float RECENTS_THUMBNAIL_FADEIN_FRACTION = 0.7f;
     /** Fraction of animation at which the recents thumbnail becomes completely transparent */
-    private static final float RECENTS_THUMBNAIL_FADEOUT_FRACTION = 0.25f;
+    private static final float RECENTS_THUMBNAIL_FADEOUT_FRACTION = 0.3f;
 
     private static final int DEFAULT_APP_TRANSITION_DURATION = 250;
-    private static final int THUMBNAIL_APP_TRANSITION_DURATION = 275;
+    private static final int THUMBNAIL_APP_TRANSITION_DURATION = 300;
+    private static final int THUMBNAIL_APP_TRANSITION_ALPHA_DURATION = 325;
 
     private final Context mContext;
     private final Handler mH;
@@ -127,6 +129,8 @@
     private static final int NEXT_TRANSIT_TYPE_SCALE_UP = 2;
     private static final int NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_UP = 3;
     private static final int NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_DOWN = 4;
+    private static final int NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP = 5;
+    private static final int NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN = 6;
     private int mNextAppTransitionType = NEXT_TRANSIT_TYPE_NONE;
 
     // These are the possible states for the enter/exit activities during a thumbnail transition
@@ -146,6 +150,7 @@
     private int mNextAppTransitionStartY;
     private int mNextAppTransitionStartWidth;
     private int mNextAppTransitionStartHeight;
+    private Rect mNextAppTransitionInsets = new Rect();
 
     private Rect mTmpFromClipRect = new Rect();
     private Rect mTmpToClipRect = new Rect();
@@ -158,7 +163,8 @@
 
     private final int mConfigShortAnimTime;
     private final Interpolator mDecelerateInterpolator;
-    private final Interpolator mThumbnailFadeoutInterpolator;
+    private final Interpolator mThumbnailFadeInInterpolator;
+    private final Interpolator mThumbnailFadeOutInterpolator;
     private final Interpolator mThumbnailFastOutSlowInInterpolator;
 
     private int mCurrentUserId = 0;
@@ -172,14 +178,25 @@
                 com.android.internal.R.interpolator.decelerate_cubic);
         mThumbnailFastOutSlowInInterpolator = AnimationUtils.loadInterpolator(context,
                 com.android.internal.R.interpolator.fast_out_slow_in);
-        mThumbnailFadeoutInterpolator = new Interpolator() {
+        mThumbnailFadeInInterpolator = new Interpolator() {
+            @Override
+            public float getInterpolation(float input) {
+                // Linear response for first fraction, then complete after that.
+                if (input < RECENTS_THUMBNAIL_FADEIN_FRACTION) {
+                    return 0f;
+                }
+                return (input - RECENTS_THUMBNAIL_FADEIN_FRACTION) /
+                        (1f - RECENTS_THUMBNAIL_FADEIN_FRACTION);
+            }
+        };
+        mThumbnailFadeOutInterpolator = new Interpolator() {
             @Override
             public float getInterpolation(float input) {
                 // Linear response for first fraction, then complete after that.
                 if (input < RECENTS_THUMBNAIL_FADEOUT_FRACTION) {
                     return input / RECENTS_THUMBNAIL_FADEOUT_FRACTION;
                 }
-                return 1.0f;
+                return 1f;
             }
         };
     }
@@ -233,9 +250,23 @@
         return mNextAppTransitionThumbnail;
     }
 
-    void getStartingPoint(Point outPoint) {
-        outPoint.x = mNextAppTransitionStartX;
-        outPoint.y = mNextAppTransitionStartY;
+    /** Returns whether the next thumbnail transition is aspect scaled up. */
+    boolean isNextThumbnailTransitionAspectScaled() {
+        return mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP ||
+                mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN;
+    }
+
+    /** Returns whether the next thumbnail transition is scaling up. */
+    boolean isNextThumbnailTransitionScaleUp() {
+        return mNextAppTransitionScaleUp;
+    }
+
+    int getStartingX() {
+        return mNextAppTransitionStartX;
+    }
+
+    int getStartingY() {
+        return mNextAppTransitionStartY;
     }
 
     void prepare() {
@@ -372,7 +403,7 @@
             scale.setInterpolator(mDecelerateInterpolator);
 
             Animation alpha = new AlphaAnimation(0, 1);
-            alpha.setInterpolator(mThumbnailFadeoutInterpolator);
+            alpha.setInterpolator(mThumbnailFadeOutInterpolator);
 
             AnimationSet set = new AnimationSet(false);
             set.addAnimation(scale);
@@ -417,7 +448,9 @@
      */
     Animation prepareThumbnailAnimationWithDuration(Animation a, int appWidth, int appHeight,
             int duration, Interpolator interpolator) {
-        a.setDuration(duration);
+        if (duration > 0) {
+            a.setDuration(duration);
+        }
         a.setFillAfter(true);
         a.setInterpolator(interpolator);
         a.initialize(appWidth, appHeight, appWidth, appHeight);
@@ -468,54 +501,77 @@
      * This animation runs for the thumbnail that gets cross faded with the enter/exit activity
      * when a thumbnail is specified with the activity options.
      */
-    Animation createThumbnailScaleAnimationLocked(int appWidth, int appHeight, int transit) {
+    Animation createThumbnailAspectScaleAnimationLocked(int appWidth, int appHeight,
+            int deviceWidth, int transit) {
         Animation a;
         final int thumbWidthI = mNextAppTransitionThumbnail.getWidth();
         final float thumbWidth = thumbWidthI > 0 ? thumbWidthI : 1;
         final int thumbHeightI = mNextAppTransitionThumbnail.getHeight();
         final float thumbHeight = thumbHeightI > 0 ? thumbHeightI : 1;
 
+        float scaleW = deviceWidth / thumbWidth;
+        float unscaledWidth = deviceWidth;
+        float unscaledHeight = thumbHeight * scaleW;
+        float unscaledStartY = mNextAppTransitionStartY - (unscaledHeight - thumbHeight) / 2f;
         if (mNextAppTransitionScaleUp) {
-            // Animation for the thumbnail zooming from its initial size to the full screen
-            float scaleW = appWidth / thumbWidth;
-            float scaleH = appHeight / thumbHeight;
-            Animation scale = new ScaleAnimation(1, scaleW, 1, scaleH,
-                    computePivot(mNextAppTransitionStartX, 1 / scaleW),
-                    computePivot(mNextAppTransitionStartY, 1 / scaleH));
-            scale.setInterpolator(mDecelerateInterpolator);
-
+            // Animation up from the thumbnail to the full screen
+            Animation scale = new ScaleAnimation(1f, scaleW, 1f, scaleW,
+                    mNextAppTransitionStartX + (thumbWidth / 2f),
+                    mNextAppTransitionStartY + (thumbHeight / 2f));
+            scale.setInterpolator(mThumbnailFastOutSlowInInterpolator);
+            scale.setDuration(THUMBNAIL_APP_TRANSITION_DURATION);
             Animation alpha = new AlphaAnimation(1, 0);
-            alpha.setInterpolator(mThumbnailFadeoutInterpolator);
+            alpha.setInterpolator(mThumbnailFadeOutInterpolator);
+            alpha.setDuration(THUMBNAIL_APP_TRANSITION_ALPHA_DURATION);
+            Animation translate = new TranslateAnimation(0, 0, 0, -unscaledStartY +
+                    mNextAppTransitionInsets.top);
+            translate.setInterpolator(mThumbnailFastOutSlowInInterpolator);
+            translate.setDuration(THUMBNAIL_APP_TRANSITION_DURATION);
 
             // This AnimationSet uses the Interpolators assigned above.
             AnimationSet set = new AnimationSet(false);
             set.addAnimation(scale);
             set.addAnimation(alpha);
+            set.addAnimation(translate);
             a = set;
         } else {
-            // Animation for the thumbnail zooming down from the full screen to its final size
-            float scaleW = appWidth / thumbWidth;
-            float scaleH = appHeight / thumbHeight;
-            a = new ScaleAnimation(scaleW, 1, scaleH, 1,
-                    computePivot(mNextAppTransitionStartX, 1 / scaleW),
-                    computePivot(mNextAppTransitionStartY, 1 / scaleH));
-        }
+            // Animation down from the full screen to the thumbnail
+            Animation scale = new ScaleAnimation(scaleW, 1f, scaleW, 1f,
+                    mNextAppTransitionStartX + (thumbWidth / 2f),
+                    mNextAppTransitionStartY + (thumbHeight / 2f));
+            scale.setInterpolator(mThumbnailFastOutSlowInInterpolator);
+            scale.setDuration(THUMBNAIL_APP_TRANSITION_DURATION);
+            Animation alpha = new AlphaAnimation(0f, 1f);
+            alpha.setInterpolator(mThumbnailFadeInInterpolator);
+            alpha.setDuration(THUMBNAIL_APP_TRANSITION_ALPHA_DURATION);
+            Animation translate = new TranslateAnimation(0, 0, -unscaledStartY +
+                    mNextAppTransitionInsets.top, 0);
+            translate.setInterpolator(mThumbnailFastOutSlowInInterpolator);
+            translate.setDuration(THUMBNAIL_APP_TRANSITION_DURATION);
 
-        return prepareThumbnailAnimation(a, appWidth, appHeight, transit);
+            // This AnimationSet uses the Interpolators assigned above.
+            AnimationSet set = new AnimationSet(false);
+            set.addAnimation(scale);
+            set.addAnimation(alpha);
+            set.addAnimation(translate);
+            a = set;
+
+        }
+        return prepareThumbnailAnimationWithDuration(a, appWidth, appHeight, 0,
+                mThumbnailFastOutSlowInInterpolator);
     }
 
     /**
      * This alternate animation is created when we are doing a thumbnail transition, for the
      * activity that is leaving, and the activity that is entering.
      */
-    Animation createAlternateThumbnailEnterExitAnimationLocked(int thumbTransitState, int appWidth,
-                                                    int appHeight, int orientation, int transit,
-                                                    Rect containingFrame, Rect contentInsets,
-                                                    boolean isFullScreen) {
+    Animation createAspectScaledThumbnailEnterExitAnimationLocked(int thumbTransitState,
+            int appWidth, int appHeight, int orientation, int transit, Rect containingFrame,
+            Rect contentInsets, boolean isFullScreen) {
         Animation a;
-        final int thumbWidthI = mNextAppTransitionThumbnail.getWidth();
+        final int thumbWidthI = mNextAppTransitionStartWidth;
         final float thumbWidth = thumbWidthI > 0 ? thumbWidthI : 1;
-        final int thumbHeightI = mNextAppTransitionThumbnail.getHeight();
+        final int thumbHeightI = mNextAppTransitionStartHeight;
         final float thumbHeight = thumbHeightI > 0 ? thumbHeightI : 1;
 
         // Used for the ENTER_SCALE_UP and EXIT_SCALE_DOWN transitions
@@ -524,7 +580,7 @@
 
         switch (thumbTransitState) {
             case THUMBNAIL_TRANSITION_ENTER_SCALE_UP: {
-                // Entering app scales up with the thumbnail
+                // App window scaling up to become full screen
                 if (orientation == Configuration.ORIENTATION_PORTRAIT) {
                     // In portrait, we scale the width and clip to the top/left square
                     scale = thumbWidth / appWidth;
@@ -550,16 +606,15 @@
                     mTmpFromClipRect.right = (mTmpFromClipRect.left + unscaledThumbWidth);
                     mTmpToClipRect.set(containingFrame);
                 }
+                mNextAppTransitionInsets.set(contentInsets);
 
                 Animation scaleAnim = new ScaleAnimation(scale, 1, scale, 1,
                         computePivot(mNextAppTransitionStartX, scale),
                         computePivot(mNextAppTransitionStartY, scale));
-                Animation alphaAnim = new AlphaAnimation(1, 1);
                 Animation clipAnim = new ClipRectAnimation(mTmpFromClipRect, mTmpToClipRect);
                 Animation translateAnim = new TranslateAnimation(0, 0, -scaledTopDecor, 0);
 
                 AnimationSet set = new AnimationSet(true);
-                set.addAnimation(alphaAnim);
                 set.addAnimation(clipAnim);
                 set.addAnimation(scaleAnim);
                 set.addAnimation(translateAnim);
@@ -567,26 +622,29 @@
                 break;
             }
             case THUMBNAIL_TRANSITION_EXIT_SCALE_UP: {
-                // Exiting app while the thumbnail is scaling up should fade
+                // Previous app window during the scale up
                 if (transit == TRANSIT_WALLPAPER_INTRA_OPEN) {
-                    // Fade out while bringing up selected activity. This keeps the
-                    // current activity from showing through a launching wallpaper
+                    // Fade out the source activity if we are animating to a wallpaper
                     // activity.
                     a = new AlphaAnimation(1, 0);
                 } else {
-                    // noop animation
                     a = new AlphaAnimation(1, 1);
                 }
                 break;
             }
             case THUMBNAIL_TRANSITION_ENTER_SCALE_DOWN: {
-                // Entering the other app, it should just be visible while we scale the thumbnail
-                // down above it
-                a = new AlphaAnimation(1, 1);
+                // Target app window during the scale down
+                if (transit == TRANSIT_WALLPAPER_INTRA_OPEN) {
+                    // Fade in the destination activity if we are animating from a wallpaper
+                    // activity.
+                    a = new AlphaAnimation(0, 1);
+                } else {
+                    a = new AlphaAnimation(1, 1);
+                }
                 break;
             }
             case THUMBNAIL_TRANSITION_EXIT_SCALE_DOWN: {
-                // Exiting the current app, the app should scale down with the thumbnail
+                // App window scaling down from full screen
                 if (orientation == Configuration.ORIENTATION_PORTRAIT) {
                     // In portrait, we scale the width and clip to the top/left square
                     scale = thumbWidth / appWidth;
@@ -612,16 +670,15 @@
                     }
                     mTmpToClipRect.right = (mTmpToClipRect.left + unscaledThumbWidth);
                 }
+                mNextAppTransitionInsets.set(contentInsets);
 
                 Animation scaleAnim = new ScaleAnimation(1, scale, 1, scale,
                         computePivot(mNextAppTransitionStartX, scale),
                         computePivot(mNextAppTransitionStartY, scale));
-                Animation alphaAnim = new AlphaAnimation(1, 1);
                 Animation clipAnim = new ClipRectAnimation(mTmpFromClipRect, mTmpToClipRect);
                 Animation translateAnim = new TranslateAnimation(0, 0, 0, -scaledTopDecor);
 
                 AnimationSet set = new AnimationSet(true);
-                set.addAnimation(alphaAnim);
                 set.addAnimation(clipAnim);
                 set.addAnimation(scaleAnim);
                 set.addAnimation(translateAnim);
@@ -639,6 +696,46 @@
     }
 
     /**
+     * This animation runs for the thumbnail that gets cross faded with the enter/exit activity
+     * when a thumbnail is specified with the activity options.
+     */
+    Animation createThumbnailScaleAnimationLocked(int appWidth, int appHeight, int transit) {
+        Animation a;
+        final int thumbWidthI = mNextAppTransitionThumbnail.getWidth();
+        final float thumbWidth = thumbWidthI > 0 ? thumbWidthI : 1;
+        final int thumbHeightI = mNextAppTransitionThumbnail.getHeight();
+        final float thumbHeight = thumbHeightI > 0 ? thumbHeightI : 1;
+
+        if (mNextAppTransitionScaleUp) {
+            // Animation for the thumbnail zooming from its initial size to the full screen
+            float scaleW = appWidth / thumbWidth;
+            float scaleH = appHeight / thumbHeight;
+            Animation scale = new ScaleAnimation(1, scaleW, 1, scaleH,
+                    computePivot(mNextAppTransitionStartX, 1 / scaleW),
+                    computePivot(mNextAppTransitionStartY, 1 / scaleH));
+            scale.setInterpolator(mDecelerateInterpolator);
+
+            Animation alpha = new AlphaAnimation(1, 0);
+            alpha.setInterpolator(mThumbnailFadeOutInterpolator);
+
+            // This AnimationSet uses the Interpolators assigned above.
+            AnimationSet set = new AnimationSet(false);
+            set.addAnimation(scale);
+            set.addAnimation(alpha);
+            a = set;
+        } else {
+            // Animation for the thumbnail zooming down from the full screen to its final size
+            float scaleW = appWidth / thumbWidth;
+            float scaleH = appHeight / thumbHeight;
+            a = new ScaleAnimation(scaleW, 1, scaleH, 1,
+                    computePivot(mNextAppTransitionStartX, 1 / scaleW),
+                    computePivot(mNextAppTransitionStartY, 1 / scaleH));
+        }
+
+        return prepareThumbnailAnimation(a, appWidth, appHeight, transit);
+    }
+
+    /**
      * This animation is created when we are doing a thumbnail transition, for the activity that is
      * leaving, and the activity that is entering.
      */
@@ -747,12 +844,26 @@
                 mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_DOWN) {
             mNextAppTransitionScaleUp =
                     (mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_UP);
-            a = createAlternateThumbnailEnterExitAnimationLocked(
+            a = createThumbnailEnterExitAnimationLocked(getThumbnailTransitionState(enter),
+                    appWidth, appHeight, transit);
+            if (DEBUG_APP_TRANSITIONS || DEBUG_ANIM) {
+                String animName = mNextAppTransitionScaleUp ?
+                        "ANIM_THUMBNAIL_SCALE_UP" : "ANIM_THUMBNAIL_SCALE_DOWN";
+                Slog.v(TAG, "applyAnimation:"
+                        + " anim=" + a + " nextAppTransition=" + animName
+                        + " transit=" + transit + " isEntrance=" + enter
+                        + " Callers=" + Debug.getCallers(3));
+            }
+        } else if (mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP ||
+                mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN) {
+            mNextAppTransitionScaleUp =
+                    (mNextAppTransitionType == NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP);
+            a = createAspectScaledThumbnailEnterExitAnimationLocked(
                     getThumbnailTransitionState(enter), appWidth, appHeight, orientation,
                     transit, containingFrame, contentInsets, isFullScreen);
             if (DEBUG_APP_TRANSITIONS || DEBUG_ANIM) {
                 String animName = mNextAppTransitionScaleUp ?
-                        "ANIM_THUMBNAIL_SCALE_UP" : "ANIM_THUMBNAIL_SCALE_DOWN";
+                        "ANIM_THUMBNAIL_ASPECT_SCALE_UP" : "ANIM_THUMBNAIL_ASPECT_SCALE_DOWN";
                 Slog.v(TAG, "applyAnimation:"
                         + " anim=" + a + " nextAppTransition=" + animName
                         + " transit=" + transit + " isEntrance=" + enter
@@ -814,7 +925,7 @@
                 case TRANSIT_TASK_OPEN_BEHIND:
                     animAttr = enter
                             ? WindowAnimation_launchTaskBehindSourceAnimation
-                            : WindowAnimation_launchTaskBehindBackgroundAnimation;
+                            : WindowAnimation_launchTaskBehindTargetAnimation;
             }
             a = animAttr != 0 ? loadAnimationAttr(lp, animAttr) : null;
             if (DEBUG_APP_TRANSITIONS || DEBUG_ANIM) Slog.v(TAG,
@@ -881,6 +992,25 @@
         }
     }
 
+    void overridePendingAppTransitionAspectScaledThumb(Bitmap srcThumb, int startX, int startY,
+            int targetWidth, int targetHeight, IRemoteCallback startedCallback, boolean scaleUp) {
+        if (isTransitionSet()) {
+            mNextAppTransitionType = scaleUp ? NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP
+                    : NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN;
+            mNextAppTransitionPackage = null;
+            mNextAppTransitionThumbnail = srcThumb;
+            mNextAppTransitionScaleUp = scaleUp;
+            mNextAppTransitionStartX = startX;
+            mNextAppTransitionStartY = startY;
+            mNextAppTransitionStartWidth = targetWidth;
+            mNextAppTransitionStartHeight = targetHeight;
+            postAnimationCallback();
+            mNextAppTransitionCallback = startedCallback;
+        } else {
+            postAnimationCallback();
+        }
+    }
+
     @Override
     public String toString() {
         return "mNextAppTransition=0x" + Integer.toHexString(mNextAppTransition);
@@ -966,6 +1096,10 @@
                 return "NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_UP";
             case NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_DOWN:
                 return "NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_DOWN";
+            case NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP:
+                return "NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP";
+            case NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN:
+                return "NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN";
             default:
                 return "unknown type=" + mNextAppTransitionType;
         }
@@ -998,12 +1132,18 @@
                 break;
             case NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_UP:
             case NEXT_TRANSIT_TYPE_THUMBNAIL_SCALE_DOWN:
+            case NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_UP:
+            case NEXT_TRANSIT_TYPE_THUMBNAIL_ASPECT_SCALE_DOWN:
                 pw.print("  mNextAppTransitionThumbnail=");
                         pw.print(mNextAppTransitionThumbnail);
                         pw.print(" mNextAppTransitionStartX=");
                         pw.print(mNextAppTransitionStartX);
                         pw.print(" mNextAppTransitionStartY=");
                         pw.println(mNextAppTransitionStartY);
+                        pw.print(" mNextAppTransitionStartWidth=");
+                        pw.print(mNextAppTransitionStartWidth);
+                        pw.print(" mNextAppTransitionStartHeight=");
+                        pw.println(mNextAppTransitionStartHeight);
                 pw.print("  mNextAppTransitionScaleUp="); pw.println(mNextAppTransitionScaleUp);
                 break;
         }
diff --git a/services/core/java/com/android/server/wm/AppWindowAnimator.java b/services/core/java/com/android/server/wm/AppWindowAnimator.java
index 5b05d53..69c9144 100644
--- a/services/core/java/com/android/server/wm/AppWindowAnimator.java
+++ b/services/core/java/com/android/server/wm/AppWindowAnimator.java
@@ -64,8 +64,17 @@
     int thumbnailX;
     int thumbnailY;
     int thumbnailLayer;
+    int thumbnailForceAboveLayer;
     Animation thumbnailAnimation;
     final Transformation thumbnailTransformation = new Transformation();
+    // This flag indicates that the destruction of the thumbnail surface is synchronized with
+    // another animation, so do not pre-emptively destroy the thumbnail surface when the animation
+    // completes
+    boolean deferThumbnailDestruction;
+    // This is the thumbnail surface that has been bestowed upon this animator, and when the
+    // surface for this animator's animation is complete, we will destroy the thumbnail surface
+    // as well.  Do not animate or do anything with this surface.
+    SurfaceControl deferredThumbnail;
 
     /** WindowStateAnimator from mAppAnimator.allAppWindows as of last performLayout */
     ArrayList<WindowStateAnimator> mAllAppWinAnimators = new ArrayList<WindowStateAnimator>();
@@ -105,6 +114,10 @@
         transformation.clear();
         transformation.setAlpha(mAppToken.isVisible() ? 1 : 0);
         hasTransformation = true;
+
+        if (!mAppToken.appFullscreen) {
+            anim.setBackgroundColor(0);
+        }
     }
 
     public void setDummyAnimation() {
@@ -121,7 +134,9 @@
             animation = null;
             animating = true;
         }
-        clearThumbnail();
+        if (!deferThumbnailDestruction) {
+            clearThumbnail();
+        }
         if (mAppToken.deferClearAllDrawn) {
             mAppToken.allDrawn = false;
             mAppToken.deferClearAllDrawn = false;
@@ -135,6 +150,13 @@
         }
     }
 
+    public void clearDeferredThumbnail() {
+        if (deferredThumbnail != null) {
+            deferredThumbnail.destroy();
+            deferredThumbnail = null;
+        }
+    }
+
     void updateLayers() {
         final int N = mAppToken.allAppWindows.size();
         final int adj = animLayerAdjustment;
@@ -184,10 +206,14 @@
                 + "][" + tmpFloats[Matrix.MSKEW_X]
                 + "," + tmpFloats[Matrix.MSCALE_Y] + "]", null);
         thumbnail.setAlpha(thumbnailTransformation.getAlpha());
-        // The thumbnail is layered below the window immediately above this
-        // token's anim layer.
-        thumbnail.setLayer(thumbnailLayer + WindowManagerService.WINDOW_LAYER_MULTIPLIER
-                - WindowManagerService.LAYER_OFFSET_THUMBNAIL);
+        if (thumbnailForceAboveLayer > 0) {
+            thumbnail.setLayer(thumbnailForceAboveLayer + 1);
+        } else {
+            // The thumbnail is layered below the window immediately above this
+            // token's anim layer.
+            thumbnail.setLayer(thumbnailLayer + WindowManagerService.WINDOW_LAYER_MULTIPLIER
+                    - WindowManagerService.LAYER_OFFSET_THUMBNAIL);
+        }
         thumbnail.setMatrix(tmpFloats[Matrix.MSCALE_X], tmpFloats[Matrix.MSKEW_Y],
                 tmpFloats[Matrix.MSKEW_X], tmpFloats[Matrix.MSCALE_Y]);
     }
@@ -202,7 +228,9 @@
             TAG, "Stepped animation in " + mAppToken + ": more=" + more + ", xform=" + transformation);
         if (!more) {
             animation = null;
-            clearThumbnail();
+            if (!deferThumbnailDestruction) {
+                clearThumbnail();
+            }
             if (WindowManagerService.DEBUG_ANIM) Slog.v(
                 TAG, "Finished animation in " + mAppToken + " @ " + currentTime);
         }
diff --git a/services/core/java/com/android/server/wm/CircularDisplayMask.java b/services/core/java/com/android/server/wm/CircularDisplayMask.java
index 64b852b..a7d41fa 100644
--- a/services/core/java/com/android/server/wm/CircularDisplayMask.java
+++ b/services/core/java/com/android/server/wm/CircularDisplayMask.java
@@ -63,8 +63,14 @@
 
         SurfaceControl ctrl = null;
         try {
-            ctrl = new SurfaceControl(session, "CircularDisplayMask",
-                mScreenSize.x, mScreenSize.y, PixelFormat.TRANSLUCENT, SurfaceControl.HIDDEN);
+            if (WindowManagerService.DEBUG_SURFACE_TRACE) {
+                ctrl = new WindowStateAnimator.SurfaceTrace(session, "CircularDisplayMask",
+                        mScreenSize.x, mScreenSize.y, PixelFormat.TRANSLUCENT,
+                        SurfaceControl.HIDDEN);
+            } else {
+                ctrl = new SurfaceControl(session, "CircularDisplayMask", mScreenSize.x,
+                        mScreenSize.y, PixelFormat.TRANSLUCENT, SurfaceControl.HIDDEN);
+            }
             ctrl.setLayerStack(display.getLayerStack());
             ctrl.setLayer(zOrder);
             ctrl.setPosition(0, 0);
diff --git a/services/core/java/com/android/server/wm/DisplayContent.java b/services/core/java/com/android/server/wm/DisplayContent.java
index d4bcd5c..0c51160 100644
--- a/services/core/java/com/android/server/wm/DisplayContent.java
+++ b/services/core/java/com/android/server/wm/DisplayContent.java
@@ -328,6 +328,7 @@
                     for (int tokenNdx = tokens.size() - 1; tokenNdx >= 0; --tokenNdx) {
                         AppWindowToken wtoken = tokens.get(tokenNdx);
                         if (wtoken.mDeferRemoval) {
+                            stack.mExitingAppTokens.remove(wtoken);
                             wtoken.mDeferRemoval = false;
                             mService.removeAppFromTaskLocked(wtoken);
                         }
diff --git a/services/core/java/com/android/server/wm/EmulatorDisplayOverlay.java b/services/core/java/com/android/server/wm/EmulatorDisplayOverlay.java
new file mode 100644
index 0000000..62f2b48
--- /dev/null
+++ b/services/core/java/com/android/server/wm/EmulatorDisplayOverlay.java
@@ -0,0 +1,127 @@
+/*
+ * Copyright (C) 2014 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.server.wm;
+
+
+import android.content.Context;
+import android.graphics.Canvas;
+import android.graphics.Color;
+import android.graphics.PixelFormat;
+import android.graphics.Point;
+import android.graphics.PorterDuff;
+import android.graphics.Rect;
+import android.graphics.drawable.Drawable;
+import android.util.Slog;
+import android.view.Display;
+import android.view.Surface;
+import android.view.Surface.OutOfResourcesException;
+import android.view.SurfaceControl;
+import android.view.SurfaceSession;
+
+class EmulatorDisplayOverlay {
+    private static final String TAG = "EmulatorDisplayOverlay";
+
+    // Display dimensions
+    private Point mScreenSize;
+
+    private final SurfaceControl mSurfaceControl;
+    private final Surface mSurface = new Surface();
+    private int mLastDW;
+    private int mLastDH;
+    private boolean mDrawNeeded;
+    private Drawable mOverlay;
+    private int mRotation;
+    private boolean mVisible;
+
+    public EmulatorDisplayOverlay(Context context, Display display, SurfaceSession session,
+            int zOrder) {
+        mScreenSize = new Point();
+        display.getSize(mScreenSize);
+
+        SurfaceControl ctrl = null;
+        try {
+            if (WindowManagerService.DEBUG_SURFACE_TRACE) {
+                ctrl = new WindowStateAnimator.SurfaceTrace(session, "EmulatorDisplayOverlay",
+                        mScreenSize.x, mScreenSize.y, PixelFormat.TRANSLUCENT,
+                        SurfaceControl.HIDDEN);
+            } else {
+                ctrl = new SurfaceControl(session, "EmulatorDisplayOverlay", mScreenSize.x,
+                        mScreenSize.y, PixelFormat.TRANSLUCENT, SurfaceControl.HIDDEN);
+            }
+            ctrl.setLayerStack(display.getLayerStack());
+            ctrl.setLayer(zOrder);
+            ctrl.setPosition(0, 0);
+            ctrl.show();
+            mSurface.copyFrom(ctrl);
+        } catch (OutOfResourcesException e) {
+        }
+        mSurfaceControl = ctrl;
+        mDrawNeeded = true;
+        mOverlay = context.getDrawable(
+                com.android.internal.R.drawable.emulator_circular_window_overlay);
+    }
+
+    private void drawIfNeeded() {
+        if (!mDrawNeeded || !mVisible) {
+            return;
+        }
+        mDrawNeeded = false;
+
+        Rect dirty = new Rect(0, 0, mScreenSize.x, mScreenSize.y);
+        Canvas c = null;
+        try {
+            c = mSurface.lockCanvas(dirty);
+        } catch (IllegalArgumentException e) {
+        } catch (OutOfResourcesException e) {
+        }
+        if (c == null) {
+            return;
+        }
+        c.drawColor(Color.TRANSPARENT, PorterDuff.Mode.SRC);
+        mSurfaceControl.setPosition(0, 0);
+        mOverlay.setBounds(0, 0, mScreenSize.x, mScreenSize.y);
+        mOverlay.draw(c);
+        mSurface.unlockCanvasAndPost(c);
+    }
+
+    // Note: caller responsible for being inside
+    // Surface.openTransaction() / closeTransaction()
+    public void setVisibility(boolean on) {
+        if (mSurfaceControl == null) {
+            return;
+        }
+        mVisible = on;
+        drawIfNeeded();
+        if (on) {
+            mSurfaceControl.show();
+        } else {
+            mSurfaceControl.hide();
+        }
+    }
+
+    void positionSurface(int dw, int dh, int rotation) {
+        if (mLastDW == dw && mLastDH == dh && mRotation == rotation) {
+            return;
+        }
+        mLastDW = dw;
+        mLastDH = dh;
+        mDrawNeeded = true;
+        mRotation = rotation;
+        drawIfNeeded();
+    }
+
+}
diff --git a/services/core/java/com/android/server/wm/InputMonitor.java b/services/core/java/com/android/server/wm/InputMonitor.java
index f02c0e6..46aefb6 100644
--- a/services/core/java/com/android/server/wm/InputMonitor.java
+++ b/services/core/java/com/android/server/wm/InputMonitor.java
@@ -352,6 +352,12 @@
         mService.mPolicy.notifyLidSwitchChanged(whenNanos, lidOpen);
     }
 
+    /* Notifies that the camera lens cover state has changed. */
+    @Override
+    public void notifyCameraLensCoverSwitchChanged(long whenNanos, boolean lensCovered) {
+        mService.mPolicy.notifyCameraLensCoverSwitchChanged(whenNanos, lensCovered);
+    }
+
     /* Provides an opportunity for the window manager policy to intercept early key
      * processing as soon as the key has been read from the device. */
     @Override
@@ -359,12 +365,13 @@
         return mService.mPolicy.interceptKeyBeforeQueueing(event, policyFlags);
     }
 
-    /* Provides an opportunity for the window manager policy to intercept early
-     * motion event processing when the screen is off since these events are normally
+    /* Provides an opportunity for the window manager policy to intercept early motion event
+     * processing when the device is in a non-interactive state since these events are normally
      * dropped. */
     @Override
-    public int interceptWakeMotionBeforeQueueing(long whenNanos, int policyFlags) {
-        return mService.mPolicy.interceptWakeMotionBeforeQueueing(whenNanos, policyFlags);
+    public int interceptMotionBeforeQueueingNonInteractive(long whenNanos, int policyFlags) {
+        return mService.mPolicy.interceptMotionBeforeQueueingNonInteractive(
+                whenNanos, policyFlags);
     }
 
     /* Provides an opportunity for the window manager policy to process a key before
diff --git a/services/core/java/com/android/server/wm/Session.java b/services/core/java/com/android/server/wm/Session.java
index f2703ad..d737e7f 100644
--- a/services/core/java/com/android/server/wm/Session.java
+++ b/services/core/java/com/android/server/wm/Session.java
@@ -415,6 +415,18 @@
         mService.wallpaperOffsetsComplete(window);
     }
 
+    public void setWallpaperDisplayOffset(IBinder window, int x, int y) {
+        synchronized(mService.mWindowMap) {
+            long ident = Binder.clearCallingIdentity();
+            try {
+                mService.setWindowWallpaperDisplayOffsetLocked(
+                        mService.windowForClientLocked(this, window, true), x, y);
+            } finally {
+                Binder.restoreCallingIdentity(ident);
+            }
+        }
+    }
+
     public Bundle sendWallpaperCommand(IBinder window, String action, int x, int y,
             int z, Bundle extras, boolean sync) {
         synchronized(mService.mWindowMap) {
diff --git a/services/core/java/com/android/server/wm/Task.java b/services/core/java/com/android/server/wm/Task.java
index 09c4e20..9ceac41 100644
--- a/services/core/java/com/android/server/wm/Task.java
+++ b/services/core/java/com/android/server/wm/Task.java
@@ -41,11 +41,11 @@
 
     void addAppToken(int addPos, AppWindowToken wtoken) {
         final int lastPos = mAppTokens.size();
-        if (addPos > lastPos) {
-            // We lost an app token. Don't crash though.
-            Slog.e(TAG, "Task.addAppToken: Out of bounds attempt token=" + wtoken + " addPos="
-                    + addPos + " lastPos=" + lastPos);
-            addPos = lastPos;
+        for (int pos = 0; pos < lastPos && pos < addPos; ++pos) {
+            if (mAppTokens.get(pos).removed) {
+                // addPos assumes removed tokens are actually gone.
+                ++addPos;
+            }
         }
         mAppTokens.add(addPos, wtoken);
         mDeferRemoval = false;
diff --git a/services/core/java/com/android/server/wm/WindowAnimator.java b/services/core/java/com/android/server/wm/WindowAnimator.java
index 4edd5cf..da5cfda 100644
--- a/services/core/java/com/android/server/wm/WindowAnimator.java
+++ b/services/core/java/com/android/server/wm/WindowAnimator.java
@@ -248,6 +248,14 @@
 
         mForceHiding = KEYGUARD_NOT_SHOWN;
 
+        final WindowState imeTarget = mService.mInputMethodTarget;
+        final boolean showImeOverKeyguard = imeTarget != null && imeTarget.isVisibleNow() &&
+                (imeTarget.getAttrs().flags & FLAG_SHOW_WHEN_LOCKED) != 0;
+
+        final WindowState winShowWhenLocked = (WindowState) mPolicy.getWinShowWhenLockedLw();
+        final AppWindowToken appShowWhenLocked = winShowWhenLocked == null ?
+                null : winShowWhenLocked.mAppToken;
+
         for (int i = windows.size() - 1; i >= 0; i--) {
             WindowState win = windows.get(i);
             WindowStateAnimator winAnimator = win.mWinAnimator;
@@ -312,7 +320,8 @@
                             + " hidden=" + win.mRootToken.hidden
                             + " anim=" + win.mWinAnimator.mAnimation);
                 } else if (mPolicy.canBeForceHidden(win, win.mAttrs)) {
-                    final boolean hideWhenLocked = (flags & FLAG_SHOW_WHEN_LOCKED) == 0;
+                    final boolean hideWhenLocked = !((win.mIsImWindow && showImeOverKeyguard) ||
+                            (appShowWhenLocked != null && appShowWhenLocked == win.mAppToken));
                     final boolean changed;
                     if (((mForceHiding == KEYGUARD_ANIMATING_IN)
                                 && (!winAnimator.isAnimating() || hideWhenLocked))
@@ -449,7 +458,10 @@
                     }
                     final int color = winAnimator.mAnimation.getBackgroundColor();
                     if (color != 0) {
-                        win.getStack().setAnimationBackground(winAnimator, color);
+                        final TaskStack stack = win.getStack();
+                        if (stack != null) {
+                            stack.setAnimationBackground(winAnimator, color);
+                        }
                     }
                 }
                 mAnimating = true;
@@ -468,7 +480,10 @@
 
                 final int color = appAnimator.animation.getBackgroundColor();
                 if (color != 0) {
-                    win.getStack().setAnimationBackground(winAnimator, color);
+                    final TaskStack stack = win.getStack();
+                    if (stack != null) {
+                        stack.setAnimationBackground(winAnimator, color);
+                    }
                 }
             }
         } // end forall windows
@@ -563,6 +578,15 @@
                         mBulkUpdateParams |= SET_UPDATE_ROTATION;
                         screenRotationAnimation.kill();
                         displayAnimator.mScreenRotationAnimation = null;
+
+                        //TODO (multidisplay): Accessibility supported only for the default display.
+                        if (mService.mAccessibilityController != null
+                                && displayId == Display.DEFAULT_DISPLAY) {
+                            // We just finished rotation animation which means we did not
+                            // anounce the rotation and waited for it to end, announce now.
+                            mService.mAccessibilityController.onRotationChangedLocked(
+                                    mService.getDefaultDisplayContentLocked(), mService.mRotation);
+                        }
                     }
                 }
 
diff --git a/services/core/java/com/android/server/wm/WindowManagerService.java b/services/core/java/com/android/server/wm/WindowManagerService.java
index 112972f..a3da1e6 100644
--- a/services/core/java/com/android/server/wm/WindowManagerService.java
+++ b/services/core/java/com/android/server/wm/WindowManagerService.java
@@ -20,6 +20,8 @@
 
 import static android.view.WindowManagerPolicy.FINISH_LAYOUT_REDO_WALLPAPER;
 import android.app.AppOpsManager;
+import android.os.Build;
+import android.os.SystemService;
 import android.util.ArraySet;
 import android.util.TimeUtils;
 import android.view.IWindowId;
@@ -51,6 +53,7 @@
 import android.app.admin.DevicePolicyManager;
 import android.animation.ValueAnimator;
 import android.content.BroadcastReceiver;
+import android.content.ContentResolver;
 import android.content.Context;
 import android.content.Intent;
 import android.content.IntentFilter;
@@ -58,6 +61,7 @@
 import android.content.pm.PackageManager;
 import android.content.res.CompatibilityInfo;
 import android.content.res.Configuration;
+import android.database.ContentObserver;
 import android.graphics.Bitmap;
 import android.graphics.Bitmap.Config;
 import android.graphics.Canvas;
@@ -93,7 +97,6 @@
 import android.provider.Settings;
 import android.util.DisplayMetrics;
 import android.util.EventLog;
-import android.util.FloatMath;
 import android.util.Log;
 import android.util.SparseArray;
 import android.util.Pair;
@@ -270,6 +273,12 @@
     // Default input dispatching timeout in nanoseconds.
     static final long DEFAULT_INPUT_DISPATCHING_TIMEOUT_NANOS = 5000 * 1000000L;
 
+    // Poll interval in milliseconds for watching boot animation finished.
+    private static final int BOOT_ANIMATION_POLL_INTERVAL = 200;
+
+    // The name of the boot animation service in init.rc.
+    private static final String BOOT_ANIMATION_SERVICE = "bootanim";
+
     /** Minimum value for attachStack and resizeStack weight value */
     public static final float STACK_WEIGHT_MIN = 0.2f;
 
@@ -294,6 +303,8 @@
     private static final int SYSTEM_UI_FLAGS_LAYOUT_STABLE_FULLSCREEN =
             View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN;
 
+    private static final String PROPERTY_EMULATOR_CIRCULAR = "ro.emulator.circular";
+
     final private KeyguardDisableHandler mKeyguardDisableHandler;
 
     final BroadcastReceiver mBroadcastReceiver = new BroadcastReceiver() {
@@ -322,6 +333,8 @@
 
     final boolean mHaveInputMethods;
 
+    final boolean mHasPermanentDpad;
+
     final boolean mAllowBootMessages;
 
     final boolean mLimitedAlphaCompositing;
@@ -428,7 +441,7 @@
     /**
      * Stores for each user whether screencapture is disabled
      * This array is essentially a cache for all userId for
-     * {@link android.app.admin.DevicePolicyManager#getScreenCaptureDisabled(null, userId)}
+     * {@link android.app.admin.DevicePolicyManager#getScreenCaptureDisabled}
      */
     SparseArray<Boolean> mScreenCaptureDisabled = new SparseArray<Boolean>();
 
@@ -440,6 +453,7 @@
     Watermark mWatermark;
     StrictModeFlash mStrictModeFlash;
     CircularDisplayMask mCircularDisplayMask;
+    EmulatorDisplayOverlay mEmulatorDisplayOverlay;
     FocusedStackFrame mFocusedStackFrame;
 
     int mFocusedStackLayer;
@@ -453,6 +467,7 @@
     boolean mSystemBooted = false;
     boolean mForceDisplayEnabled = false;
     boolean mShowingBootMessages = false;
+    boolean mBootAnimationStopped = false;
 
     String mLastANRState;
 
@@ -539,6 +554,21 @@
     boolean mHardKeyboardAvailable;
     boolean mShowImeWithHardKeyboard;
     OnHardKeyboardStatusChangeListener mHardKeyboardStatusChangeListener;
+    SettingsObserver mSettingsObserver;
+
+    private final class SettingsObserver extends ContentObserver {
+        public SettingsObserver() {
+            super(new Handler());
+            ContentResolver resolver = mContext.getContentResolver();
+            resolver.registerContentObserver(Settings.Secure.getUriFor(
+                    Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD), false, this);
+        }
+
+        @Override
+        public void onChange(boolean selfChange) {
+            updateShowImeWithHardKeyboard();
+        }
+    }
 
     final ArrayList<WindowToken> mWallpaperTokens = new ArrayList<WindowToken>();
 
@@ -556,6 +586,8 @@
     float mLastWallpaperY = -1;
     float mLastWallpaperXStep = -1;
     float mLastWallpaperYStep = -1;
+    int mLastWallpaperDisplayOffsetX = Integer.MIN_VALUE;
+    int mLastWallpaperDisplayOffsetY = Integer.MIN_VALUE;
     // This is set when we are waiting for a wallpaper to tell us it is done
     // changing its scroll position.
     WindowState mWaitingOnWallpaper;
@@ -774,6 +806,8 @@
         mOnlyCore = onlyCore;
         mLimitedAlphaCompositing = context.getResources().getBoolean(
                 com.android.internal.R.bool.config_sf_limitedAlpha);
+        mHasPermanentDpad = context.getResources().getBoolean(
+                com.android.internal.R.bool.config_hasPermanentDpad);
         mInputManager = inputManager; // Must be before createDisplayContentLocked.
         mDisplayManagerInternal = LocalServices.getService(DisplayManagerInternal.class);
         mDisplaySettings = new DisplaySettings(context);
@@ -838,6 +872,9 @@
         filter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED);
         mContext.registerReceiver(mBroadcastReceiver, filter);
 
+        mSettingsObserver = new SettingsObserver();
+        updateShowImeWithHardKeyboard();
+
         mHoldingScreenWakeLock = mPowerManager.newWakeLock(
                 PowerManager.SCREEN_BRIGHT_WAKE_LOCK | PowerManager.ON_AFTER_RELEASE, TAG);
         mHoldingScreenWakeLock.setReferenceCounted(false);
@@ -860,6 +897,7 @@
         }
 
         showCircularDisplayMaskIfNeeded();
+        showEmulatorDisplayOverlayIfNeeded();
     }
 
     public InputMonitor getInputMonitor() {
@@ -1873,6 +1911,12 @@
                 mLastWallpaperY = mWallpaperTarget.mWallpaperY;
                 mLastWallpaperYStep = mWallpaperTarget.mWallpaperYStep;
             }
+            if (mWallpaperTarget.mWallpaperDisplayOffsetX != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetX = mWallpaperTarget.mWallpaperDisplayOffsetX;
+            }
+            if (mWallpaperTarget.mWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetY = mWallpaperTarget.mWallpaperDisplayOffsetY;
+            }
         }
 
         // Start stepping backwards from here, ensuring that our wallpaper windows
@@ -2011,6 +2055,9 @@
         float wpxs = mLastWallpaperXStep >= 0 ? mLastWallpaperXStep : -1.0f;
         int availw = wallpaperWin.mFrame.right-wallpaperWin.mFrame.left-dw;
         int offset = availw > 0 ? -(int)(availw*wpx+.5f) : 0;
+        if (mLastWallpaperDisplayOffsetX != Integer.MIN_VALUE) {
+            offset += mLastWallpaperDisplayOffsetX;
+        }
         changed = wallpaperWin.mXOffset != offset;
         if (changed) {
             if (DEBUG_WALLPAPER) Slog.v(TAG, "Update wallpaper "
@@ -2027,6 +2074,9 @@
         float wpys = mLastWallpaperYStep >= 0 ? mLastWallpaperYStep : -1.0f;
         int availh = wallpaperWin.mFrame.bottom-wallpaperWin.mFrame.top-dh;
         offset = availh > 0 ? -(int)(availh*wpy+.5f) : 0;
+        if (mLastWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+            offset += mLastWallpaperDisplayOffsetY;
+        }
         if (wallpaperWin.mYOffset != offset) {
             if (DEBUG_WALLPAPER) Slog.v(TAG, "Update wallpaper "
                     + wallpaperWin + " y: " + offset);
@@ -2111,6 +2161,16 @@
             } else if (changingTarget.mWallpaperY >= 0) {
                 mLastWallpaperY = changingTarget.mWallpaperY;
             }
+            if (target.mWallpaperDisplayOffsetX != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetX = target.mWallpaperDisplayOffsetX;
+            } else if (changingTarget.mWallpaperDisplayOffsetX != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetX = changingTarget.mWallpaperDisplayOffsetX;
+            }
+            if (target.mWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetY = target.mWallpaperDisplayOffsetY;
+            } else if (changingTarget.mWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+                mLastWallpaperDisplayOffsetY = changingTarget.mWallpaperDisplayOffsetY;
+            }
         }
 
         int curTokenIndex = mWallpaperTokens.size();
@@ -2315,9 +2375,12 @@
                       return WindowManagerGlobal.ADD_BAD_APP_TOKEN;
                 }
             } else if (token.appWindowToken != null) {
-                Slog.i(TAG, "Non-null appWindowToken for system window of type=" + type);
-                // app token should be null for any other window types.
-                token.appWindowToken = null;
+                Slog.w(TAG, "Non-null appWindowToken for system window of type=" + type);
+                // It is not valid to use an app token with other system types; we will
+                // instead make a new token for it (as if null had been passed in for the token).
+                attrs.token = null;
+                token = new WindowToken(this, null, -1, false);
+                addToken = true;
             }
 
             win = new WindowState(this, session, client, token,
@@ -2360,7 +2423,6 @@
             origId = Binder.clearCallingIdentity();
 
             if (addToken) {
-                Slog.w("BadTokenDebug", "addWindow: Adding token=" + token + " attrs.token=" + attrs.token);
                 mTokenMap.put(attrs.token, token);
             }
             win.attach();
@@ -2642,9 +2704,7 @@
                 + token.windows.size());
         if (token.windows.size() == 0) {
             if (!token.explicit) {
-                WindowToken wtoken = mTokenMap.remove(token.token);
-                Slog.w("BadTokenDebug", "removeWindowInnerLocked: Removing token=" + token + " removed=" +
-                        wtoken + " Callers=" + Debug.getCallers(4));
+                mTokenMap.remove(token.token);
             } else if (atoken != null) {
                 atoken.firstWindowDrawn = false;
             }
@@ -2807,6 +2867,14 @@
         }
     }
 
+    public void setWindowWallpaperDisplayOffsetLocked(WindowState window, int x, int y) {
+        if (window.mWallpaperDisplayOffsetX != x || window.mWallpaperDisplayOffsetY != y)  {
+            window.mWallpaperDisplayOffsetX = x;
+            window.mWallpaperDisplayOffsetY = y;
+            updateWallpaperOffsetLocked(window, true);
+        }
+    }
+
     public Bundle sendWindowWallpaperCommandLocked(WindowState window,
             String action, int x, int y, int z, Bundle extras, boolean sync) {
         if (window == mWallpaperTarget || window == mLowerWallpaperTarget
@@ -3430,7 +3498,6 @@
                 return;
             }
             wtoken = new WindowToken(this, token, type, true);
-            Slog.w("BadTokenDebug", "addWindowToken: Adding token=" + token + " wtoken=" + wtoken);
             mTokenMap.put(token, wtoken);
             if (type == TYPE_WALLPAPER) {
                 mWallpaperTokens.add(wtoken);
@@ -3449,8 +3516,6 @@
         synchronized(mWindowMap) {
             DisplayContent displayContent = null;
             WindowToken wtoken = mTokenMap.remove(token);
-            Slog.w("BadTokenDebug", "removeWindowToken: Removing token=" + token + " removed=" + wtoken
-                    + " Callers=" + Debug.getCallers(3));
             if (wtoken != null) {
                 boolean delayed = false;
                 if (!wtoken.hidden) {
@@ -3567,7 +3632,6 @@
                 task.addAppToken(addPos, atoken);
             }
 
-            Slog.w("BadTokenDebug", "addAppToken: Adding token=" + token.asBinder() + " atoken=" + atoken);
             mTokenMap.put(token.asBinder(), atoken);
 
             // Application tokens start out hidden.
@@ -4015,6 +4079,16 @@
     }
 
     @Override
+    public void overridePendingAppTransitionAspectScaledThumb(Bitmap srcThumb, int startX,
+            int startY, int targetWidth, int targetHeight, IRemoteCallback startedCallback,
+            boolean scaleUp) {
+        synchronized(mWindowMap) {
+            mAppTransition.overridePendingAppTransitionAspectScaledThumb(srcThumb, startX,
+                    startY, targetWidth, targetHeight, startedCallback, scaleUp);
+        }
+    }
+
+    @Override
     public void executeAppTransition() {
         if (!checkCallingPermission(android.Manifest.permission.MANAGE_APP_TOKENS,
                 "executeAppTransition()")) {
@@ -4279,24 +4353,28 @@
     }
 
     public void setAppFullscreen(IBinder token, boolean toOpaque) {
-        AppWindowToken atoken = findAppWindowToken(token);
-        if (atoken != null) {
-            atoken.appFullscreen = toOpaque;
-            // When making translucent, wait until windows below have been drawn.
-            if (toOpaque) {
-                // Making opaque so do it now.
-                setWindowOpaque(token, true);
+        synchronized (mWindowMap) {
+            AppWindowToken atoken = findAppWindowToken(token);
+            if (atoken != null) {
+                atoken.appFullscreen = toOpaque;
+                setWindowOpaqueLocked(token, toOpaque);
+                requestTraversalLocked();
             }
-            requestTraversal();
         }
     }
 
     public void setWindowOpaque(IBinder token, boolean isOpaque) {
+        synchronized (mWindowMap) {
+            setWindowOpaqueLocked(token, isOpaque);
+        }
+    }
+
+    public void setWindowOpaqueLocked(IBinder token, boolean isOpaque) {
         AppWindowToken wtoken = findAppWindowToken(token);
         if (wtoken != null) {
             WindowState win = wtoken.findMainWindow();
             if (win != null) {
-                win.mWinAnimator.setOpaque(isOpaque);
+                win.mWinAnimator.setOpaqueLocked(isOpaque);
             }
         }
     }
@@ -4658,7 +4736,6 @@
         final long origId = Binder.clearCallingIdentity();
         synchronized(mWindowMap) {
             WindowToken basewtoken = mTokenMap.remove(token);
-            Slog.w("BadTokenDebug", "removeAppToke: Removing token=" + token + " removed=" + basewtoken);
             if (basewtoken != null && (wtoken=basewtoken.appWindowToken) != null) {
                 if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Removing app token: " + wtoken);
                 delayed = setTokenVisibilityLocked(wtoken, null, false,
@@ -5413,6 +5490,23 @@
         }
     }
 
+    // Called by window manager policy. Not exposed externally.
+    @Override
+    public int getCameraLensCoverState() {
+        int sw = mInputManager.getSwitchState(-1, InputDevice.SOURCE_ANY,
+                InputManagerService.SW_CAMERA_LENS_COVER);
+        if (sw > 0) {
+            // Switch state: AKEY_STATE_DOWN or AKEY_STATE_VIRTUAL.
+            return CAMERA_LENS_COVERED;
+        } else if (sw == 0) {
+            // Switch state: AKEY_STATE_UP.
+            return CAMERA_LENS_UNCOVERED;
+        } else {
+            // Switch state: AKEY_STATE_UNKNOWN.
+            return CAMERA_LENS_COVER_ABSENT;
+        }
+    }
+
     // Called by window manager policy.  Not exposed externally.
     @Override
     public void switchKeyboardLayout(int deviceId, int direction) {
@@ -5525,17 +5619,70 @@
         performEnableScreen();
     }
 
+    private boolean checkWaitingForWindowsLocked() {
+
+        boolean haveBootMsg = false;
+        boolean haveApp = false;
+        // if the wallpaper service is disabled on the device, we're never going to have
+        // wallpaper, don't bother waiting for it
+        boolean haveWallpaper = false;
+        boolean wallpaperEnabled = mContext.getResources().getBoolean(
+                com.android.internal.R.bool.config_enableWallpaperService)
+                && !mOnlyCore;
+        boolean haveKeyguard = true;
+        // TODO(multidisplay): Expand to all displays?
+        final WindowList windows = getDefaultWindowListLocked();
+        final int N = windows.size();
+        for (int i=0; i<N; i++) {
+            WindowState w = windows.get(i);
+            if (w.isVisibleLw() && !w.mObscured && !w.isDrawnLw()) {
+                return true;
+            }
+            if (w.isDrawnLw()) {
+                if (w.mAttrs.type == TYPE_BOOT_PROGRESS) {
+                    haveBootMsg = true;
+                } else if (w.mAttrs.type == TYPE_APPLICATION) {
+                    haveApp = true;
+                } else if (w.mAttrs.type == TYPE_WALLPAPER) {
+                    haveWallpaper = true;
+                } else if (w.mAttrs.type == TYPE_STATUS_BAR) {
+                    haveKeyguard = mPolicy.isKeyguardDrawnLw();
+                }
+            }
+        }
+
+        if (DEBUG_SCREEN_ON || DEBUG_BOOT) {
+            Slog.i(TAG, "******** booted=" + mSystemBooted + " msg=" + mShowingBootMessages
+                    + " haveBoot=" + haveBootMsg + " haveApp=" + haveApp
+                    + " haveWall=" + haveWallpaper + " wallEnabled=" + wallpaperEnabled
+                    + " haveKeyguard=" + haveKeyguard);
+        }
+
+        // If we are turning on the screen to show the boot message,
+        // don't do it until the boot message is actually displayed.
+        if (!mSystemBooted && !haveBootMsg) {
+            return true;
+        }
+
+        // If we are turning on the screen after the boot is completed
+        // normally, don't do so until we have the application and
+        // wallpaper.
+        if (mSystemBooted && ((!haveApp && !haveKeyguard) ||
+                (wallpaperEnabled && !haveWallpaper))) {
+            return true;
+        }
+
+        return false;
+    }
+
     public void performEnableScreen() {
         synchronized(mWindowMap) {
-            if (DEBUG_BOOT) {
-                RuntimeException here = new RuntimeException("here");
-                here.fillInStackTrace();
-                Slog.i(TAG, "performEnableScreen: mDisplayEnabled=" + mDisplayEnabled
-                        + " mForceDisplayEnabled=" + mForceDisplayEnabled
-                        + " mShowingBootMessages=" + mShowingBootMessages
-                        + " mSystemBooted=" + mSystemBooted
-                        + " mOnlyCore=" + mOnlyCore, here);
-            }
+            if (DEBUG_BOOT) Slog.i(TAG, "performEnableScreen: mDisplayEnabled=" + mDisplayEnabled
+                    + " mForceDisplayEnabled=" + mForceDisplayEnabled
+                    + " mShowingBootMessages=" + mShowingBootMessages
+                    + " mSystemBooted=" + mSystemBooted
+                    + " mOnlyCore=" + mOnlyCore,
+                    new RuntimeException("here").fillInStackTrace());
             if (mDisplayEnabled) {
                 return;
             }
@@ -5543,94 +5690,64 @@
                 return;
             }
 
-            if (!mForceDisplayEnabled) {
-                // Don't enable the screen until all existing windows
-                // have been drawn.
-                boolean haveBootMsg = false;
-                boolean haveApp = false;
-                // if the wallpaper service is disabled on the device, we're never going to have
-                // wallpaper, don't bother waiting for it
-                boolean haveWallpaper = false;
-                boolean wallpaperEnabled = mContext.getResources().getBoolean(
-                        com.android.internal.R.bool.config_enableWallpaperService)
-                        && !mOnlyCore;
-                boolean haveKeyguard = true;
-                // TODO(multidisplay): Expand to all displays?
-                final WindowList windows = getDefaultWindowListLocked();
-                final int N = windows.size();
-                for (int i=0; i<N; i++) {
-                    WindowState w = windows.get(i);
-                    if (w.isVisibleLw() && !w.mObscured && !w.isDrawnLw()) {
-                        return;
+            // Don't enable the screen until all existing windows have been drawn.
+            if (!mForceDisplayEnabled && checkWaitingForWindowsLocked()) {
+                return;
+            }
+
+            if (!mBootAnimationStopped) {
+                // Do this one time.
+                try {
+                    IBinder surfaceFlinger = ServiceManager.getService("SurfaceFlinger");
+                    if (surfaceFlinger != null) {
+                        //Slog.i(TAG, "******* TELLING SURFACE FLINGER WE ARE BOOTED!");
+                        Parcel data = Parcel.obtain();
+                        data.writeInterfaceToken("android.ui.ISurfaceComposer");
+                        surfaceFlinger.transact(IBinder.FIRST_CALL_TRANSACTION, // BOOT_FINISHED
+                                data, null, 0);
+                        data.recycle();
                     }
-                    if (w.isDrawnLw()) {
-                        if (w.mAttrs.type == TYPE_BOOT_PROGRESS) {
-                            haveBootMsg = true;
-                        } else if (w.mAttrs.type == TYPE_APPLICATION) {
-                            haveApp = true;
-                        } else if (w.mAttrs.type == TYPE_WALLPAPER) {
-                            haveWallpaper = true;
-                        } else if (w.mAttrs.type == TYPE_STATUS_BAR) {
-                            haveKeyguard = mPolicy.isKeyguardDrawnLw();
-                        }
-                    }
+                } catch (RemoteException ex) {
+                    Slog.e(TAG, "Boot completed: SurfaceFlinger is dead!");
                 }
+                mBootAnimationStopped = true;
+            }
 
-                if (DEBUG_SCREEN_ON || DEBUG_BOOT) {
-                    Slog.i(TAG, "******** booted=" + mSystemBooted + " msg=" + mShowingBootMessages
-                            + " haveBoot=" + haveBootMsg + " haveApp=" + haveApp
-                            + " haveWall=" + haveWallpaper + " wallEnabled=" + wallpaperEnabled
-                            + " haveKeyguard=" + haveKeyguard);
-                }
-
-                // If we are turning on the screen to show the boot message,
-                // don't do it until the boot message is actually displayed.
-                if (!mSystemBooted && !haveBootMsg) {
-                    return;
-                }
-
-                // If we are turning on the screen after the boot is completed
-                // normally, don't do so until we have the application and
-                // wallpaper.
-                if (mSystemBooted && ((!haveApp && !haveKeyguard) ||
-                        (wallpaperEnabled && !haveWallpaper))) {
-                    return;
-                }
+            if (!mForceDisplayEnabled && !checkBootAnimationCompleteLocked()) {
+                if (DEBUG_BOOT) Slog.i(TAG, "performEnableScreen: Waiting for anim complete");
+                return;
             }
 
             mDisplayEnabled = true;
             if (DEBUG_SCREEN_ON || DEBUG_BOOT) Slog.i(TAG, "******************** ENABLING SCREEN!");
-            if (false) {
-                StringWriter sw = new StringWriter();
-                PrintWriter pw = new FastPrintWriter(sw, false, 1024);
-                this.dump(null, pw, null);
-                pw.flush();
-                Slog.i(TAG, sw.toString());
-            }
-            try {
-                IBinder surfaceFlinger = ServiceManager.getService("SurfaceFlinger");
-                if (surfaceFlinger != null) {
-                    //Slog.i(TAG, "******* TELLING SURFACE FLINGER WE ARE BOOTED!");
-                    Parcel data = Parcel.obtain();
-                    data.writeInterfaceToken("android.ui.ISurfaceComposer");
-                    surfaceFlinger.transact(IBinder.FIRST_CALL_TRANSACTION, // BOOT_FINISHED
-                                            data, null, 0);
-                    data.recycle();
-                }
-            } catch (RemoteException ex) {
-                Slog.e(TAG, "Boot completed: SurfaceFlinger is dead!");
-            }
 
             // Enable input dispatch.
             mInputMonitor.setEventDispatchingLw(mEventDispatchingEnabled);
         }
 
+        try {
+            mActivityManager.bootAnimationComplete();
+        } catch (RemoteException e) {
+        }
+
         mPolicy.enableScreenAfterBoot();
 
         // Make sure the last requested orientation has been applied.
         updateRotationUnchecked(false, false);
     }
 
+    private boolean checkBootAnimationCompleteLocked() {
+        if (SystemService.isRunning(BOOT_ANIMATION_SERVICE)) {
+            mH.removeMessages(H.CHECK_IF_BOOT_ANIMATION_FINISHED);
+            mH.sendEmptyMessageDelayed(H.CHECK_IF_BOOT_ANIMATION_FINISHED,
+                    BOOT_ANIMATION_POLL_INTERVAL);
+            if (DEBUG_BOOT) Slog.i(TAG, "checkBootAnimationComplete: Waiting for anim complete");
+            return false;
+        }
+        if (DEBUG_BOOT) Slog.i(TAG, "checkBootAnimationComplete: Animation complete!");
+        return true;
+    }
+
     public void showBootMessage(final CharSequence msg, final boolean always) {
         boolean first = false;
         synchronized(mWindowMap) {
@@ -5690,7 +5807,16 @@
                 com.android.internal.R.bool.config_windowIsRound)
                 && mContext.getResources().getBoolean(
                 com.android.internal.R.bool.config_windowShowCircularMask)) {
-            mH.sendMessage(mH.obtainMessage(H.SHOW_DISPLAY_MASK));
+            mH.sendMessage(mH.obtainMessage(H.SHOW_CIRCULAR_DISPLAY_MASK));
+        }
+    }
+
+    public void showEmulatorDisplayOverlayIfNeeded() {
+        if (mContext.getResources().getBoolean(
+                com.android.internal.R.bool.config_windowEnableCircularEmulatorDisplayOverlay)
+                && SystemProperties.getBoolean(PROPERTY_EMULATOR_CIRCULAR, false)
+                && Build.HARDWARE.contains("goldfish")) {
+            mH.sendMessage(mH.obtainMessage(H.SHOW_EMULATOR_DISPLAY_OVERLAY));
         }
     }
 
@@ -5698,12 +5824,12 @@
         synchronized(mWindowMap) {
 
             if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG,
-                    ">>> OPEN TRANSACTION showDisplayMask");
+                    ">>> OPEN TRANSACTION showCircularMask");
             SurfaceControl.openTransaction();
             try {
                 // TODO(multi-display): support multiple displays
                 if (mCircularDisplayMask == null) {
-                    int screenOffset = (int) mContext.getResources().getDimensionPixelSize(
+                    int screenOffset = mContext.getResources().getDimensionPixelSize(
                             com.android.internal.R.dimen.circular_display_mask_offset);
 
                     mCircularDisplayMask = new CircularDisplayMask(
@@ -5717,7 +5843,32 @@
             } finally {
                 SurfaceControl.closeTransaction();
                 if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG,
-                        "<<< CLOSE TRANSACTION showDisplayMask");
+                        "<<< CLOSE TRANSACTION showCircularMask");
+            }
+        }
+    }
+
+    public void showEmulatorDisplayOverlay() {
+        synchronized(mWindowMap) {
+
+            if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG,
+                    ">>> OPEN TRANSACTION showEmulatorDisplayOverlay");
+            SurfaceControl.openTransaction();
+            try {
+                if (mEmulatorDisplayOverlay == null) {
+                    mEmulatorDisplayOverlay = new EmulatorDisplayOverlay(
+                            mContext,
+                            getDefaultDisplayContentLocked().getDisplay(),
+                            mFxSession,
+                            mPolicy.windowTypeToLayerLw(
+                                    WindowManager.LayoutParams.TYPE_POINTER)
+                                    * TYPE_LAYER_MULTIPLIER + 10);
+                }
+                mEmulatorDisplayOverlay.setVisibility(true);
+            } finally {
+                SurfaceControl.closeTransaction();
+                if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG,
+                        "<<< CLOSE TRANSACTION showEmulatorDisplayOverlay");
             }
         }
     }
@@ -5778,6 +5929,29 @@
         SystemProperties.set(StrictMode.VISUAL_PROPERTY, value);
     }
 
+    private static void convertCropForSurfaceFlinger(Rect crop, int rot, int dw, int dh) {
+        if (rot == Surface.ROTATION_90) {
+            final int tmp = crop.top;
+            crop.top = dw - crop.right;
+            crop.right = crop.bottom;
+            crop.bottom = dw - crop.left;
+            crop.left = tmp;
+        } else if (rot == Surface.ROTATION_180) {
+            int tmp = crop.top;
+            crop.top = dh - crop.bottom;
+            crop.bottom = dh - tmp;
+            tmp = crop.right;
+            crop.right = dw - crop.left;
+            crop.left = dw - tmp;
+        } else if (rot == Surface.ROTATION_270) {
+            final int tmp = crop.top;
+            crop.top = crop.left;
+            crop.left = dh - crop.bottom;
+            crop.bottom = crop.right;
+            crop.right = dh - tmp;
+        }
+    }
+
     /**
      * Takes a snapshot of the screen.  In landscape mode this grabs the whole screen.
      * In portrait mode, it grabs the upper region of the screen based on the vertical dimension
@@ -5792,7 +5966,7 @@
     @Override
     public Bitmap screenshotApplications(IBinder appToken, int displayId, int width,
             int height, boolean force565) {
-        if (!checkCallingPermission(android.Manifest.permission.READ_FRAME_BUFFER,
+        if (!checkCallingPermission(Manifest.permission.READ_FRAME_BUFFER,
                 "screenshotApplications()")) {
             throw new SecurityException("Requires READ_FRAME_BUFFER permission");
         }
@@ -5812,7 +5986,7 @@
             return null;
         }
 
-        Bitmap rawss = null;
+        Bitmap bm = null;
 
         int maxLayer = 0;
         final Rect frame = new Rect();
@@ -5939,21 +6113,29 @@
 
                 // Constrain frame to the screen size.
                 frame.intersect(0, 0, dw, dh);
-                // Constrain thumbnail to smaller of screen width or height. Assumes aspect
-                // of thumbnail is the same as the screen (in landscape) or square.
-                scale = Math.max(width / (float) frame.width(), height / (float) frame.height());
-                dw = (int)(dw * scale);
-                dh = (int)(dh * scale);
+
+                // Tell surface flinger what part of the image to crop. Take the top
+                // right part of the application, and crop the larger dimension to fit.
+                Rect crop = new Rect(frame);
+                if (width / (float) frame.width() < height / (float) frame.height()) {
+                    int cropWidth = (int)((float)width / (float)height * frame.height());
+                    crop.right = crop.left + cropWidth;
+                } else {
+                    int cropHeight = (int)((float)height / (float)width * frame.width());
+                    crop.bottom = crop.top + cropHeight;
+                }
 
                 // The screenshot API does not apply the current screen rotation.
                 rot = getDefaultDisplayContentLocked().getDisplay().getRotation();
+
                 if (rot == Surface.ROTATION_90 || rot == Surface.ROTATION_270) {
-                    final int tmp = dw;
-                    dw = dh;
-                    dh = tmp;
                     rot = (rot == Surface.ROTATION_90) ? Surface.ROTATION_270 : Surface.ROTATION_90;
                 }
 
+                // Surfaceflinger is not aware of orientation, so convert our logical
+                // crop to surfaceflinger's portrait orientation.
+                convertCropForSurfaceFlinger(crop, rot, dw, dh);
+
                 if (DEBUG_SCREENSHOT) {
                     Slog.i(TAG, "Screenshot: " + dw + "x" + dh + " from " + minLayer + " to "
                             + maxLayer + " appToken=" + appToken);
@@ -5972,9 +6154,9 @@
                 if (DEBUG_SCREENSHOT && inRotation) Slog.v(TAG,
                         "Taking screenshot while rotating");
 
-                rawss = SurfaceControl.screenshot(new Rect(), dw, dh, minLayer, maxLayer,
-                        inRotation);
-                if (rawss == null) {
+                bm = SurfaceControl.screenshot(crop, width, height, minLayer, maxLayer,
+                        inRotation, rot);
+                if (bm == null) {
                     Slog.w(TAG, "Screenshot failure taking screenshot for (" + dw + "x" + dh
                             + ") to layer " + maxLayer);
                     return null;
@@ -5984,20 +6166,6 @@
             break;
         }
 
-        Bitmap bm = Bitmap.createBitmap(width, height, force565 ?
-                Config.RGB_565 : rawss.getConfig());
-        if (DEBUG_SCREENSHOT) {
-            bm.eraseColor(0xFF000000);
-        }
-        frame.scale(scale);
-        Matrix matrix = new Matrix();
-        ScreenRotationAnimation.createRotationMatrix(rot, dw, dh, matrix);
-        // TODO: Test for RTL vs. LTR and use frame.right-width instead of -frame.left
-        matrix.postTranslate(-FloatMath.ceil(frame.left), -FloatMath.ceil(frame.top));
-        Canvas canvas = new Canvas(bm);
-        canvas.drawBitmap(rawss, matrix, null);
-        canvas.setBitmap(null);
-
         if (DEBUG_SCREENSHOT) {
             // TEST IF IT's ALL BLACK
             int[] buffer = new int[bm.getWidth() * bm.getHeight()];
@@ -6018,8 +6186,12 @@
             }
         }
 
-        rawss.recycle();
-        return bm;
+        // Copy the screenshot bitmap to another buffer so that the gralloc backed
+        // bitmap will not have a long lifetime. Gralloc memory can be pinned or
+        // duplicated and might have a higher cost than a skia backed buffer.
+        Bitmap ret = bm.copy(bm.getConfig(),true);
+        bm.recycle();
+        return ret;
     }
 
     /**
@@ -6274,9 +6446,12 @@
         }
 
         //TODO (multidisplay): Magnification is supported only for the default display.
-        if (mAccessibilityController != null
+        // Announce rotation only if we will not animate as we already have the
+        // windows in final state. Otherwise, we make this call at the rotation end.
+        if (screenRotationAnimation == null && mAccessibilityController != null
                 && displayContent.getDisplayId() == Display.DEFAULT_DISPLAY) {
-            mAccessibilityController.onRotationChangedLocked(getDefaultDisplayContentLocked(), rotation);
+            mAccessibilityController.onRotationChangedLocked(getDefaultDisplayContentLocked(),
+                    rotation);
         }
 
         return true;
@@ -7011,11 +7186,15 @@
                 }
             }
 
+            if (config.navigation == Configuration.NAVIGATION_NONAV && mHasPermanentDpad) {
+                config.navigation = Configuration.NAVIGATION_DPAD;
+                navigationPresence |= WindowManagerPolicy.PRESENCE_INTERNAL;
+            }
+
             // Determine whether a hard keyboard is available and enabled.
             boolean hardKeyboardAvailable = config.keyboard != Configuration.KEYBOARD_NOKEYS;
             if (hardKeyboardAvailable != mHardKeyboardAvailable) {
                 mHardKeyboardAvailable = hardKeyboardAvailable;
-                mShowImeWithHardKeyboard = !hardKeyboardAvailable;
                 mH.removeMessages(H.REPORT_HARD_KEYBOARD_STATUS_CHANGE);
                 mH.sendEmptyMessage(H.REPORT_HARD_KEYBOARD_STATUS_CHANGE);
             }
@@ -7039,18 +7218,12 @@
         }
     }
 
-    public boolean isShowImeWithHardKeyboardEnabled() {
+    public void updateShowImeWithHardKeyboard() {
+        boolean showImeWithHardKeyboard = Settings.Secure.getIntForUser(
+                mContext.getContentResolver(), Settings.Secure.SHOW_IME_WITH_HARD_KEYBOARD, 0,
+                mCurrentUserId) == 1;
         synchronized (mWindowMap) {
-            return mShowImeWithHardKeyboard;
-        }
-    }
-
-    public void setShowImeWithHardKeyboard(boolean enabled) {
-        synchronized (mWindowMap) {
-            if (mShowImeWithHardKeyboard != enabled) {
-                mShowImeWithHardKeyboard = enabled;
-                mH.sendEmptyMessage(H.SEND_NEW_CONFIGURATION);
-            }
+            mShowImeWithHardKeyboard = showImeWithHardKeyboard;
         }
     }
 
@@ -7062,15 +7235,14 @@
     }
 
     void notifyHardKeyboardStatusChange() {
-        final boolean available, showImeWithHardKeyboard;
+        final boolean available;
         final OnHardKeyboardStatusChangeListener listener;
         synchronized (mWindowMap) {
             listener = mHardKeyboardStatusChangeListener;
             available = mHardKeyboardAvailable;
-            showImeWithHardKeyboard = mShowImeWithHardKeyboard;
         }
         if (listener != null) {
-            listener.onHardKeyboardStatusChange(available, showImeWithHardKeyboard);
+            listener.onHardKeyboardStatusChange(available);
         }
     }
 
@@ -7325,7 +7497,10 @@
 
         public static final int NEW_ANIMATOR_SCALE = 34;
 
-        public static final int SHOW_DISPLAY_MASK = 35;
+        public static final int SHOW_CIRCULAR_DISPLAY_MASK = 35;
+        public static final int SHOW_EMULATOR_DISPLAY_OVERLAY = 36;
+
+        public static final int CHECK_IF_BOOT_ANIMATION_FINISHED = 37;
 
         @Override
         public void handleMessage(Message msg) {
@@ -7721,11 +7896,16 @@
                     break;
                 }
 
-                case SHOW_DISPLAY_MASK: {
+                case SHOW_CIRCULAR_DISPLAY_MASK: {
                     showCircularMask();
                     break;
                 }
 
+                case SHOW_EMULATOR_DISPLAY_OVERLAY: {
+                    showEmulatorDisplayOverlay();
+                    break;
+                }
+
                 case DO_ANIMATION_CALLBACK: {
                     try {
                         ((IRemoteCallback)msg.obj).sendResult(null);
@@ -7806,6 +7986,17 @@
                     }
                 }
                 break;
+                case CHECK_IF_BOOT_ANIMATION_FINISHED: {
+                    final boolean bootAnimationComplete;
+                    synchronized (mWindowMap) {
+                        if (DEBUG_BOOT) Slog.i(TAG, "CHECK_IF_BOOT_ANIMATION_FINISHED:");
+                        bootAnimationComplete = checkBootAnimationCompleteLocked();
+                    }
+                    if (bootAnimationComplete) {
+                        performEnableScreen();
+                    }
+                }
+                break;
             }
             if (DEBUG_WINDOW_TRACE) {
                 Slog.v(TAG, "handleMessage: exit");
@@ -8374,7 +8565,8 @@
                 layerChanged = true;
                 anyLayerChanged = true;
             }
-            if (layerChanged && w.getStack().isDimming(winAnimator)) {
+            final TaskStack stack = w.getStack();
+            if (layerChanged && stack != null && stack.isDimming(winAnimator)) {
                 // Force an animation pass just to update the mDimLayer layer.
                 scheduleAnimationLocked();
             }
@@ -8847,7 +9039,9 @@
             }
 
             AppWindowToken topOpeningApp = null;
+            AppWindowToken topClosingApp = null;
             int topOpeningLayer = 0;
+            int topClosingLayer = 0;
 
             NN = mOpeningApps.size();
             for (i=0; i<NN; i++) {
@@ -8855,8 +9049,8 @@
                 final AppWindowAnimator appAnimator = wtoken.mAppAnimator;
                 if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now opening app" + wtoken);
                 appAnimator.clearThumbnail();
-                wtoken.inPendingTransaction = false;
                 appAnimator.animation = null;
+                wtoken.inPendingTransaction = false;
                 setTokenVisibilityLocked(wtoken, animLp, true, transit, false, voiceInteraction);
                 wtoken.updateReportedVisibilityLocked();
                 wtoken.waitingToShow = false;
@@ -8885,10 +9079,11 @@
             NN = mClosingApps.size();
             for (i=0; i<NN; i++) {
                 AppWindowToken wtoken = mClosingApps.valueAt(i);
+                final AppWindowAnimator appAnimator = wtoken.mAppAnimator;
                 if (DEBUG_APP_TRANSITIONS) Slog.v(TAG, "Now closing app " + wtoken);
-                wtoken.mAppAnimator.clearThumbnail();
+                appAnimator.clearThumbnail();
+                appAnimator.animation = null;
                 wtoken.inPendingTransaction = false;
-                wtoken.mAppAnimator.animation = null;
                 setTokenVisibilityLocked(wtoken, animLp, false, transit, false, voiceInteraction);
                 wtoken.updateReportedVisibilityLocked();
                 wtoken.waitingToHide = false;
@@ -8897,14 +9092,30 @@
                 // gotten drawn.
                 wtoken.allDrawn = true;
                 wtoken.deferClearAllDrawn = false;
+
+                if (animLp != null) {
+                    int layer = -1;
+                    for (int j=0; j<wtoken.windows.size(); j++) {
+                        WindowState win = wtoken.windows.get(j);
+                        if (win.mWinAnimator.mAnimLayer > layer) {
+                            layer = win.mWinAnimator.mAnimLayer;
+                        }
+                    }
+                    if (topClosingApp == null || layer > topClosingLayer) {
+                        topClosingApp = wtoken;
+                        topClosingLayer = layer;
+                    }
+                }
             }
 
-            boolean useAlternateThumbnailAnimation = true;
-            AppWindowAnimator appAnimator =
-                    topOpeningApp == null ? null : topOpeningApp.mAppAnimator;
+            AppWindowAnimator openingAppAnimator = (topOpeningApp == null) ? null :
+                    topOpeningApp.mAppAnimator;
+            AppWindowAnimator closingAppAnimator = (topClosingApp == null) ? null :
+                    topClosingApp.mAppAnimator;
             Bitmap nextAppTransitionThumbnail = mAppTransition.getNextAppTransitionThumbnail();
-            if (!useAlternateThumbnailAnimation && nextAppTransitionThumbnail != null
-                    && appAnimator != null && appAnimator.animation != null) {
+            if (nextAppTransitionThumbnail != null
+                    && openingAppAnimator != null && openingAppAnimator.animation != null &&
+                    nextAppTransitionThumbnail.getConfig() != Config.ALPHA_8) {
                 // This thumbnail animation is very special, we need to have
                 // an extra surface with the thumbnail included with the animation.
                 Rect dirty = new Rect(0, 0, nextAppTransitionThumbnail.getWidth(),
@@ -8913,34 +9124,61 @@
                     // TODO(multi-display): support other displays
                     final DisplayContent displayContent = getDefaultDisplayContentLocked();
                     final Display display = displayContent.getDisplay();
+                    final DisplayInfo displayInfo = displayContent.getDisplayInfo();
+
+                    // Create a new surface for the thumbnail
                     SurfaceControl surfaceControl = new SurfaceControl(mFxSession,
-                            "thumbnail anim",
-                            dirty.width(), dirty.height(),
+                            "thumbnail anim", dirty.width(), dirty.height(),
                             PixelFormat.TRANSLUCENT, SurfaceControl.HIDDEN);
                     surfaceControl.setLayerStack(display.getLayerStack());
-                    appAnimator.thumbnail = surfaceControl;
-                    if (SHOW_TRANSACTIONS) Slog.i(TAG, "  THUMBNAIL " + surfaceControl + ": CREATE");
+                    if (SHOW_TRANSACTIONS) {
+                        Slog.i(TAG, "  THUMBNAIL " + surfaceControl + ": CREATE");
+                    }
+
+                    // Draw the thumbnail onto the surface
                     Surface drawSurface = new Surface();
                     drawSurface.copyFrom(surfaceControl);
                     Canvas c = drawSurface.lockCanvas(dirty);
                     c.drawBitmap(nextAppTransitionThumbnail, 0, 0, null);
                     drawSurface.unlockCanvasAndPost(c);
                     drawSurface.release();
-                    appAnimator.thumbnailLayer = topOpeningLayer;
-                    DisplayInfo displayInfo = getDefaultDisplayInfoLocked();
-                    Animation anim = mAppTransition.createThumbnailScaleAnimationLocked(
-                            displayInfo.appWidth, displayInfo.appHeight, transit);
-                    appAnimator.thumbnailAnimation = anim;
+
+                    // Get the thumbnail animation
+                    Animation anim;
+                    if (mAppTransition.isNextThumbnailTransitionAspectScaled()) {
+                        // For the new aspect-scaled transition, we want it to always show
+                        // above the animating opening/closing window, and we want to
+                        // synchronize its thumbnail surface with the surface for the
+                        // open/close animation (only on the way down)
+                        anim = mAppTransition.createThumbnailAspectScaleAnimationLocked(
+                                displayInfo.appWidth, displayInfo.appHeight,
+                                displayInfo.logicalWidth, transit);
+                        openingAppAnimator.thumbnailForceAboveLayer = Math.max(topOpeningLayer,
+                                topClosingLayer);
+                        openingAppAnimator.deferThumbnailDestruction =
+                                !mAppTransition.isNextThumbnailTransitionScaleUp();
+                        if (openingAppAnimator.deferThumbnailDestruction) {
+                            if (closingAppAnimator != null &&
+                                    closingAppAnimator.animation != null) {
+                                closingAppAnimator.deferredThumbnail = surfaceControl;
+                            }
+                        }
+                    } else {
+                        anim = mAppTransition.createThumbnailScaleAnimationLocked(
+                                displayInfo.appWidth, displayInfo.appHeight, transit);
+                    }
                     anim.restrictDuration(MAX_ANIMATION_DURATION);
                     anim.scaleCurrentDuration(getTransitionAnimationScaleLocked());
-                    Point p = new Point();
-                    mAppTransition.getStartingPoint(p);
-                    appAnimator.thumbnailX = p.x;
-                    appAnimator.thumbnailY = p.y;
+
+                    openingAppAnimator.thumbnail = surfaceControl;
+                    openingAppAnimator.thumbnailLayer = topOpeningLayer;
+                    openingAppAnimator.thumbnailAnimation = anim;
+                    openingAppAnimator.thumbnailX = mAppTransition.getStartingX();
+                    openingAppAnimator.thumbnailY = mAppTransition.getStartingY();
                 } catch (OutOfResourcesException e) {
                     Slog.e(TAG, "Can't allocate thumbnail/Canvas surface w=" + dirty.width()
                             + " h=" + dirty.height(), e);
-                    appAnimator.clearThumbnail();
+                    openingAppAnimator.clearThumbnail();
                 }
             }
 
@@ -9152,6 +9390,9 @@
                 && !w.mExiting) {
             final WindowStateAnimator winAnimator = w.mWinAnimator;
             final TaskStack stack = w.getStack();
+            if (stack == null) {
+                return;
+            }
             stack.setDimmingTag();
             if (!stack.isDimming(winAnimator)) {
                 if (localLOGV) Slog.v(TAG, "Win " + w + " start dimming.");
@@ -9249,6 +9490,9 @@
             if (mCircularDisplayMask != null) {
                 mCircularDisplayMask.positionSurface(defaultDw, defaultDh, mRotation);
             }
+            if (mEmulatorDisplayOverlay != null) {
+                mEmulatorDisplayOverlay.positionSurface(defaultDw, defaultDh, mRotation);
+            }
 
             boolean focusDisplayed = false;
 
@@ -10741,6 +10985,7 @@
         }
         pw.println();
         pw.print("  mCurConfiguration="); pw.println(this.mCurConfiguration);
+        pw.print("  mHasPermanentDpad="); pw.println(mHasPermanentDpad);
         pw.print("  mCurrentFocus="); pw.println(mCurrentFocus);
         if (mLastFocus != mCurrentFocus) {
             pw.print("  mLastFocus="); pw.println(mLastFocus);
@@ -10775,6 +11020,12 @@
             }
             pw.print("  mLastWallpaperX="); pw.print(mLastWallpaperX);
                     pw.print(" mLastWallpaperY="); pw.println(mLastWallpaperY);
+            if (mLastWallpaperDisplayOffsetX != Integer.MIN_VALUE
+                    || mLastWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+                pw.print("  mLastWallpaperDisplayOffsetX="); pw.print(mLastWallpaperDisplayOffsetX);
+                        pw.print(" mLastWallpaperDisplayOffsetY=");
+                        pw.println(mLastWallpaperDisplayOffsetY);
+            }
             if (mInputMethodAnimLayerAdjustment != 0 ||
                     mWallpaperAnimLayerAdjustment != 0) {
                 pw.print("  mInputMethodAnimLayerAdjustment=");
@@ -11053,7 +11304,7 @@
     }
 
     public interface OnHardKeyboardStatusChangeListener {
-        public void onHardKeyboardStatusChange(boolean available, boolean showIme);
+        public void onHardKeyboardStatusChange(boolean available);
     }
 
     void debugLayoutRepeats(final String msg, int pendingLayoutChanges) {
@@ -11310,7 +11561,8 @@
                 final WindowList windows = getDefaultWindowListLocked();
                 for (int winNdx = windows.size() - 1; winNdx >= 0; --winNdx) {
                     final WindowState win = windows.get(winNdx);
-                    if (win.mHasSurface && win.mAppToken != null) {
+                    if (win.mHasSurface
+                            && (win.mAppToken != null || mPolicy.isForceHiding(win.mAttrs))) {
                         win.mWinAnimator.mDrawState = WindowStateAnimator.DRAW_PENDING;
                         // Force add to mResizingWindows.
                         win.mLastContentInsets.set(-1, -1, -1, -1);
diff --git a/services/core/java/com/android/server/wm/WindowState.java b/services/core/java/com/android/server/wm/WindowState.java
index e74de38..0baa2be 100644
--- a/services/core/java/com/android/server/wm/WindowState.java
+++ b/services/core/java/com/android/server/wm/WindowState.java
@@ -247,6 +247,11 @@
     float mWallpaperXStep = -1;
     float mWallpaperYStep = -1;
 
+    // If a window showing a wallpaper: a raw pixel offset to forcibly apply
+    // to its window; if a wallpaper window: not used.
+    int mWallpaperDisplayOffsetX = Integer.MIN_VALUE;
+    int mWallpaperDisplayOffsetY = Integer.MIN_VALUE;
+
     // Wallpaper windows: pixels offset based on above variables.
     int mXOffset;
     int mYOffset;
@@ -1584,6 +1589,13 @@
             pw.print(prefix); pw.print("mWallpaperXStep="); pw.print(mWallpaperXStep);
                     pw.print(" mWallpaperYStep="); pw.println(mWallpaperYStep);
         }
+        if (mWallpaperDisplayOffsetX != Integer.MIN_VALUE
+                || mWallpaperDisplayOffsetY != Integer.MIN_VALUE) {
+            pw.print(prefix); pw.print("mWallpaperDisplayOffsetX=");
+                    pw.print(mWallpaperDisplayOffsetX);
+                    pw.print(" mWallpaperDisplayOffsetY=");
+                    pw.println(mWallpaperDisplayOffsetY);
+        }
     }
 
     String makeInputChannelName() {
diff --git a/services/core/java/com/android/server/wm/WindowStateAnimator.java b/services/core/java/com/android/server/wm/WindowStateAnimator.java
index 7bf090a..ff17d78 100644
--- a/services/core/java/com/android/server/wm/WindowStateAnimator.java
+++ b/services/core/java/com/android/server/wm/WindowStateAnimator.java
@@ -16,6 +16,7 @@
 
 package com.android.server.wm;
 
+import static android.view.WindowManager.LayoutParams.FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS;
 import static android.view.WindowManager.LayoutParams.TYPE_APPLICATION_STARTING;
 import static com.android.server.wm.WindowManagerService.DEBUG_ANIM;
 import static com.android.server.wm.WindowManagerService.DEBUG_LAYERS;
@@ -524,6 +525,7 @@
         private boolean mShown = false;
         private int mLayerStack;
         private boolean mIsOpaque;
+        private float mDsdx, mDtdx, mDsdy, mDtdy;
         private final String mName;
 
         public SurfaceTrace(SurfaceSession s,
@@ -619,6 +621,19 @@
         }
 
         @Override
+        public void setMatrix(float dsdx, float dtdx, float dsdy, float dtdy) {
+            if (dsdx != mDsdx || dtdx != mDtdx || dsdy != mDsdy || dtdy != mDtdy) {
+                Slog.v(SURFACE_TAG, "setMatrix(" + dsdx + "," + dtdx + "," + dsdy + "," + dtdy +
+                        "): OLD:" + this + ". Called by " + Debug.getCallers(3));
+                mDsdx = dsdx;
+                mDtdx = dtdx;
+                mDsdy = dsdy;
+                mDtdy = dtdy;
+            }
+            super.setMatrix(dsdx, dtdx, dsdy, dtdy);
+        }
+
+        @Override
         public void hide() {
             if (mShown) {
                 Slog.v(SURFACE_TAG, "hide: OLD:" + this + ". Called by " + Debug.getCallers(3));
@@ -665,7 +680,8 @@
                     + " alpha=" + mSurfaceTraceAlpha + " " + mPosition.x + "," + mPosition.y
                     + " " + mSize.x + "x" + mSize.y
                     + " crop=" + mWindowCrop.toShortString()
-                    + " opaque=" + mIsOpaque;
+                    + " opaque=" + mIsOpaque
+                    + " (" + mDsdx + "," + mDtdx + "," + mDsdy + "," + mDtdy + ")";
         }
     }
 
@@ -754,7 +770,11 @@
                 final boolean isHwAccelerated = (attrs.flags &
                         WindowManager.LayoutParams.FLAG_HARDWARE_ACCELERATED) != 0;
                 final int format = isHwAccelerated ? PixelFormat.TRANSLUCENT : attrs.format;
-                if (!PixelFormat.formatHasAlpha(attrs.format)) {
+                if (!PixelFormat.formatHasAlpha(attrs.format)
+                        && attrs.surfaceInsets.left == 0
+                        && attrs.surfaceInsets.top == 0
+                        && attrs.surfaceInsets.right == 0
+                        && attrs.surfaceInsets.bottom  == 0) {
                     flags |= SurfaceControl.OPAQUE;
                 }
 
@@ -902,6 +922,11 @@
             mWin.mHasSurface = false;
             mDrawState = NO_SURFACE;
         }
+
+        // Destroy any deferred thumbnail surfaces
+        if (mAppAnimator != null) {
+            mAppAnimator.clearDeferredThumbnail();
+        }
     }
 
     void destroyDeferredSurfaceLocked() {
@@ -1059,6 +1084,14 @@
                     mShownAlpha *= appTransformation.getAlpha();
                     if (appTransformation.hasClipRect()) {
                         mClipRect.set(appTransformation.getClipRect());
+                        if (mWin.mHScale > 0) {
+                            mClipRect.left /= mWin.mHScale;
+                            mClipRect.right /= mWin.mHScale;
+                        }
+                        if (mWin.mVScale > 0) {
+                            mClipRect.top /= mWin.mVScale;
+                            mClipRect.bottom /= mWin.mVScale;
+                        }
                         mHasClipRect = true;
                     }
                 }
@@ -1239,9 +1272,10 @@
             // not always reporting the correct system decor rect. In such
             // cases, we take into account the specified content insets as well.
             if ((w.mSystemUiVisibility & SYSTEM_UI_FLAGS_LAYOUT_STABLE_FULLSCREEN)
-                    == SYSTEM_UI_FLAGS_LAYOUT_STABLE_FULLSCREEN) {
+                    == SYSTEM_UI_FLAGS_LAYOUT_STABLE_FULLSCREEN
+                    || (w.mAttrs.flags & FLAG_DRAWS_SYSTEM_BAR_BACKGROUNDS) != 0) {
                 // Don't apply the workaround to apps explicitly requesting
-                // fullscreen layout.
+                // fullscreen layout or when the bars are transparent.
                 clipRect.intersect(mClipRect);
             } else {
                 final int offsetTop = Math.max(clipRect.top, w.mContentInsets.top);
@@ -1336,7 +1370,10 @@
                 mAnimator.setPendingLayoutChanges(w.getDisplayId(),
                         WindowManagerPolicy.FINISH_LAYOUT_REDO_WALLPAPER);
                 if ((w.mAttrs.flags & LayoutParams.FLAG_DIM_BEHIND) != 0) {
-                    w.getStack().startDimmingIfNeeded(this);
+                    final TaskStack stack = w.getStack();
+                    if (stack != null) {
+                        stack.startDimmingIfNeeded(this);
+                    }
                 }
             } catch (RuntimeException e) {
                 // If something goes wrong with the surface (such
@@ -1409,10 +1446,10 @@
             w.mLastVScale = w.mVScale;
             if (WindowManagerService.SHOW_TRANSACTIONS) WindowManagerService.logSurface(w,
                     "alpha=" + mShownAlpha + " layer=" + mAnimLayer
-                    + " matrix=[" + (mDsDx*w.mHScale)
-                    + "," + (mDtDx*w.mVScale)
-                    + "][" + (mDsDy*w.mHScale)
-                    + "," + (mDtDy*w.mVScale) + "]", null);
+                    + " matrix=[" + mDsDx + "*" + w.mHScale
+                    + "," + mDtDx + "*" + w.mVScale
+                    + "][" + mDsDy + "*" + w.mHScale
+                    + "," + mDtDy + "*" + w.mVScale + "]", null);
             if (mSurfaceControl != null) {
                 try {
                     mSurfaceAlpha = mShownAlpha;
@@ -1494,8 +1531,9 @@
     }
 
     void setWallpaperOffset(RectF shownFrame) {
-        final int left = (int) shownFrame.left;
-        final int top = (int) shownFrame.top;
+        final LayoutParams attrs = mWin.getAttrs();
+        final int left = ((int) shownFrame.left) - attrs.surfaceInsets.left;
+        final int top = ((int) shownFrame.top) - attrs.surfaceInsets.top;
         if (mSurfaceX != left || mSurfaceY != top) {
             mSurfaceX = left;
             mSurfaceY = top;
@@ -1524,11 +1562,11 @@
         }
     }
 
-    void setOpaque(boolean isOpaque) {
+    void setOpaqueLocked(boolean isOpaque) {
         if (mSurfaceControl == null) {
             return;
         }
-        if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, ">>> OPEN TRANSACTION setOpaque");
+        if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, ">>> OPEN TRANSACTION setOpaqueLocked");
         SurfaceControl.openTransaction();
         try {
             if (SHOW_TRANSACTIONS) WindowManagerService.logSurface(mWin, "isOpaque=" + isOpaque,
@@ -1536,7 +1574,7 @@
             mSurfaceControl.setOpaque(isOpaque);
         } finally {
             SurfaceControl.closeTransaction();
-            if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, "<<< CLOSE TRANSACTION setOpaque");
+            if (SHOW_LIGHT_TRANSACTIONS) Slog.i(TAG, "<<< CLOSE TRANSACTION setOpaqueLocked");
         }
     }
 
diff --git a/services/core/jni/Android.mk b/services/core/jni/Android.mk
index 1f377c7..d81cdd9 100644
--- a/services/core/jni/Android.mk
+++ b/services/core/jni/Android.mk
@@ -11,7 +11,6 @@
     $(LOCAL_REL_DIR)/com_android_server_connectivity_Vpn.cpp \
     $(LOCAL_REL_DIR)/com_android_server_ConsumerIrService.cpp \
     $(LOCAL_REL_DIR)/com_android_server_hdmi_HdmiCecController.cpp \
-    $(LOCAL_REL_DIR)/com_android_server_hdmi_HdmiMhlController.cpp \
     $(LOCAL_REL_DIR)/com_android_server_input_InputApplicationHandle.cpp \
     $(LOCAL_REL_DIR)/com_android_server_input_InputManagerService.cpp \
     $(LOCAL_REL_DIR)/com_android_server_input_InputWindowHandle.cpp \
diff --git a/services/core/jni/com_android_server_UsbHostManager.cpp b/services/core/jni/com_android_server_UsbHostManager.cpp
index bc866d3..65a28c0 100644
--- a/services/core/jni/com_android_server_UsbHostManager.cpp
+++ b/services/core/jni/com_android_server_UsbHostManager.cpp
@@ -21,7 +21,6 @@
 #include "JNIHelp.h"
 #include "android_runtime/AndroidRuntime.h"
 #include "android_runtime/Log.h"
-#include "utils/Vector.h"
 
 #include <usbhost/usbhost.h>
 
@@ -68,8 +67,6 @@
 
     JNIEnv* env = AndroidRuntime::getJNIEnv();
     jobject thiz = (jobject)client_data;
-    Vector<int> interfaceValues;
-    Vector<int> endpointValues;
     const usb_device_descriptor* deviceDesc = usb_device_get_device_descriptor(device);
 
     char *manufacturer = usb_device_get_manufacturer_name(device);
diff --git a/services/core/jni/com_android_server_input_InputManagerService.cpp b/services/core/jni/com_android_server_input_InputManagerService.cpp
index 8ed74be..cddca92 100644
--- a/services/core/jni/com_android_server_input_InputManagerService.cpp
+++ b/services/core/jni/com_android_server_input_InputManagerService.cpp
@@ -71,7 +71,7 @@
     jmethodID notifyANR;
     jmethodID filterInputEvent;
     jmethodID interceptKeyBeforeQueueing;
-    jmethodID interceptWakeMotionBeforeQueueing;
+    jmethodID interceptMotionBeforeQueueingNonInteractive;
     jmethodID interceptKeyBeforeDispatching;
     jmethodID dispatchUnhandledKey;
     jmethodID checkInjectEventsPermission;
@@ -854,7 +854,9 @@
 
         handleInterceptActions(wmActions, when, /*byref*/ policyFlags);
     } else {
-        policyFlags |= POLICY_FLAG_PASS_TO_USER;
+        if (mInteractive) {
+            policyFlags |= POLICY_FLAG_PASS_TO_USER;
+        }
     }
 }
 
@@ -870,20 +872,22 @@
     if ((policyFlags & POLICY_FLAG_TRUSTED) && !(policyFlags & POLICY_FLAG_INJECTED)) {
         if (policyFlags & POLICY_FLAG_INTERACTIVE) {
             policyFlags |= POLICY_FLAG_PASS_TO_USER;
-        } else if (policyFlags & POLICY_FLAG_WAKE) {
+        } else {
             JNIEnv* env = jniEnv();
             jint wmActions = env->CallIntMethod(mServiceObj,
-                        gServiceClassInfo.interceptWakeMotionBeforeQueueing,
+                        gServiceClassInfo.interceptMotionBeforeQueueingNonInteractive,
                         when, policyFlags);
             if (checkAndClearExceptionFromCallback(env,
-                    "interceptWakeMotionBeforeQueueing")) {
+                    "interceptMotionBeforeQueueingNonInteractive")) {
                 wmActions = 0;
             }
 
             handleInterceptActions(wmActions, when, /*byref*/ policyFlags);
         }
     } else {
-        policyFlags |= POLICY_FLAG_PASS_TO_USER;
+        if (mInteractive) {
+            policyFlags |= POLICY_FLAG_PASS_TO_USER;
+        }
     }
 }
 
@@ -1441,8 +1445,8 @@
     GET_METHOD_ID(gServiceClassInfo.interceptKeyBeforeQueueing, clazz,
             "interceptKeyBeforeQueueing", "(Landroid/view/KeyEvent;I)I");
 
-    GET_METHOD_ID(gServiceClassInfo.interceptWakeMotionBeforeQueueing, clazz,
-            "interceptWakeMotionBeforeQueueing", "(JI)I");
+    GET_METHOD_ID(gServiceClassInfo.interceptMotionBeforeQueueingNonInteractive, clazz,
+            "interceptMotionBeforeQueueingNonInteractive", "(JI)I");
 
     GET_METHOD_ID(gServiceClassInfo.interceptKeyBeforeDispatching, clazz,
             "interceptKeyBeforeDispatching",
diff --git a/services/core/jni/com_android_server_location_GpsLocationProvider.cpp b/services/core/jni/com_android_server_location_GpsLocationProvider.cpp
index c398908..6958087 100644
--- a/services/core/jni/com_android_server_location_GpsLocationProvider.cpp
+++ b/services/core/jni/com_android_server_location_GpsLocationProvider.cpp
@@ -65,6 +65,7 @@
 static const GpsGeofencingInterface* sGpsGeofencingInterface = NULL;
 static const GpsMeasurementInterface* sGpsMeasurementInterface = NULL;
 static const GpsNavigationMessageInterface* sGpsNavigationMessageInterface = NULL;
+static const GnssConfigurationInterface* sGnssConfigurationInterface = NULL;
 
 // temporary storage for GPS callbacks
 static GpsSvStatus  sGpsSvStatus;
@@ -502,6 +503,9 @@
         sGpsNavigationMessageInterface =
             (const GpsNavigationMessageInterface*)sGpsInterface->get_extension(
                     GPS_NAVIGATION_MESSAGE_INTERFACE);
+        sGnssConfigurationInterface =
+            (const GnssConfigurationInterface*)sGpsInterface->get_extension(
+                    GNSS_CONFIGURATION_INTERFACE);
     }
 }
 
@@ -901,55 +905,57 @@
 
     if (flags & GPS_CLOCK_HAS_LEAP_SECOND) {
         jmethodID setterMethod = env->GetMethodID(gpsClockClass, "setLeapSecond", "(S)V");
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->leap_second);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->leap_second);
    }
 
    jmethodID typeSetterMethod = env->GetMethodID(gpsClockClass, "setType", "(B)V");
-   env->CallObjectMethod(gpsClockObject, typeSetterMethod, clock->type);
+   env->CallVoidMethod(gpsClockObject, typeSetterMethod, clock->type);
 
     jmethodID setterMethod = env->GetMethodID(gpsClockClass, "setTimeInNs", longSignature);
-    env->CallObjectMethod(gpsClockObject, setterMethod, clock->time_ns);
+    env->CallVoidMethod(gpsClockObject, setterMethod, clock->time_ns);
 
     if (flags & GPS_CLOCK_HAS_TIME_UNCERTAINTY) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsClockClass, "setTimeUncertaintyInNs", doubleSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->time_uncertainty_ns);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->time_uncertainty_ns);
     }
 
     if (flags & GPS_CLOCK_HAS_FULL_BIAS) {
         jmethodID setterMethod = env->GetMethodID(gpsClockClass, "setFullBiasInNs", longSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->full_bias_ns);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->full_bias_ns);
     }
 
     if (flags & GPS_CLOCK_HAS_BIAS) {
         jmethodID setterMethod = env->GetMethodID(gpsClockClass, "setBiasInNs", doubleSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->bias_ns);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->bias_ns);
     }
 
     if (flags & GPS_CLOCK_HAS_BIAS_UNCERTAINTY) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsClockClass, "setBiasUncertaintyInNs", doubleSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->bias_uncertainty_ns);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->bias_uncertainty_ns);
     }
 
     if (flags & GPS_CLOCK_HAS_DRIFT) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsClockClass, "setDriftInNsPerSec", doubleSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->drift_nsps);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->drift_nsps);
     }
 
     if (flags & GPS_CLOCK_HAS_DRIFT_UNCERTAINTY) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsClockClass, "setDriftUncertaintyInNsPerSec", doubleSignature);
-        env->CallObjectMethod(gpsClockObject, setterMethod, clock->drift_uncertainty_nsps);
+        env->CallVoidMethod(gpsClockObject, setterMethod, clock->drift_uncertainty_nsps);
     }
 
+    env->DeleteLocalRef(gpsClockClass);
     return gpsClockObject;
 }
 
 static jobject translate_gps_measurement(JNIEnv* env, GpsMeasurement* measurement) {
     const char* byteSignature = "(B)V";
     const char* shortSignature = "(S)V";
+    const char* intSignature = "(I)V";
     const char* longSignature = "(J)V";
     const char* floatSignature = "(F)V";
     const char* doubleSignature = "(D)V";
@@ -961,21 +967,21 @@
     GpsMeasurementFlags flags = measurement->flags;
 
     jmethodID prnSetterMethod = env->GetMethodID(gpsMeasurementClass, "setPrn", byteSignature);
-    env->CallObjectMethod(gpsMeasurementObject, prnSetterMethod, measurement->prn);
+    env->CallVoidMethod(gpsMeasurementObject, prnSetterMethod, measurement->prn);
 
     jmethodID timeOffsetSetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setTimeOffsetInNs", doubleSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             timeOffsetSetterMethod,
             measurement->time_offset_ns);
 
     jmethodID stateSetterMethod = env->GetMethodID(gpsMeasurementClass, "setState", shortSignature);
-    env->CallObjectMethod(gpsMeasurementObject, stateSetterMethod, measurement->state);
+    env->CallVoidMethod(gpsMeasurementObject, stateSetterMethod, measurement->state);
 
     jmethodID receivedGpsTowSetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setReceivedGpsTowInNs", longSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             receivedGpsTowSetterMethod,
             measurement->received_gps_tow_ns);
@@ -991,13 +997,13 @@
 
     jmethodID cn0SetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setCn0InDbHz", doubleSignature);
-    env->CallObjectMethod(gpsMeasurementObject, cn0SetterMethod, measurement->c_n0_dbhz);
+    env->CallVoidMethod(gpsMeasurementObject, cn0SetterMethod, measurement->c_n0_dbhz);
 
     jmethodID pseudorangeRateSetterMethod = env->GetMethodID(
             gpsMeasurementClass,
             "setPseudorangeRateInMetersPerSec",
             doubleSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             pseudorangeRateSetterMethod,
             measurement->pseudorange_rate_mps);
@@ -1006,14 +1012,14 @@
             gpsMeasurementClass,
             "setPseudorangeRateUncertaintyInMetersPerSec",
             doubleSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             pseudorangeRateUncertaintySetterMethod,
             measurement->pseudorange_rate_uncertainty_mps);
 
     jmethodID accumulatedDeltaRangeStateSetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setAccumulatedDeltaRangeState", shortSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             accumulatedDeltaRangeStateSetterMethod,
             measurement->accumulated_delta_range_state);
@@ -1039,7 +1045,7 @@
     if (flags & GPS_MEASUREMENT_HAS_PSEUDORANGE) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setPseudorangeInMeters", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->pseudorange_m);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->pseudorange_m);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_PSEUDORANGE_UNCERTAINTY) {
@@ -1047,7 +1053,7 @@
                 gpsMeasurementClass,
                 "setPseudorangeUncertaintyInMeters",
                 doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->pseudorange_uncertainty_m);
@@ -1056,7 +1062,7 @@
     if (flags & GPS_MEASUREMENT_HAS_CODE_PHASE) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setCodePhaseInChips", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->code_phase_chips);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->code_phase_chips);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_CODE_PHASE_UNCERTAINTY) {
@@ -1064,7 +1070,7 @@
                 gpsMeasurementClass,
                 "setCodePhaseUncertaintyInChips",
                 doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->code_phase_uncertainty_chips);
@@ -1073,7 +1079,7 @@
     if (flags & GPS_MEASUREMENT_HAS_CARRIER_FREQUENCY) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setCarrierFrequencyInHz", floatSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->carrier_frequency_hz);
@@ -1082,13 +1088,13 @@
     if (flags & GPS_MEASUREMENT_HAS_CARRIER_CYCLES) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setCarrierCycles", longSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->carrier_cycles);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->carrier_cycles);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_CARRIER_PHASE) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setCarrierPhase", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->carrier_phase);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->carrier_phase);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_CARRIER_PHASE_UNCERTAINTY) {
@@ -1096,7 +1102,7 @@
                 gpsMeasurementClass,
                 "setCarrierPhaseUncertainty",
                 doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->carrier_phase_uncertainty);
@@ -1104,18 +1110,18 @@
 
     jmethodID lossOfLockSetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setLossOfLock", byteSignature);
-    env->CallObjectMethod(gpsMeasurementObject, lossOfLockSetterMethod, measurement->loss_of_lock);
+    env->CallVoidMethod(gpsMeasurementObject, lossOfLockSetterMethod, measurement->loss_of_lock);
 
     if (flags & GPS_MEASUREMENT_HAS_BIT_NUMBER) {
         jmethodID setterMethod =
-                env->GetMethodID(gpsMeasurementClass, "setBitNumber", shortSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->bit_number);
+                env->GetMethodID(gpsMeasurementClass, "setBitNumber", intSignature);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->bit_number);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_TIME_FROM_LAST_BIT) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setTimeFromLastBitInMs", shortSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->time_from_last_bit_ms);
@@ -1124,7 +1130,7 @@
     if (flags & GPS_MEASUREMENT_HAS_DOPPLER_SHIFT) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setDopplerShiftInHz", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->doppler_shift_hz);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->doppler_shift_hz);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_DOPPLER_SHIFT_UNCERTAINTY) {
@@ -1132,7 +1138,7 @@
                 gpsMeasurementClass,
                 "setDopplerShiftUncertaintyInHz",
                 doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->doppler_shift_uncertainty_hz);
@@ -1140,7 +1146,7 @@
 
     jmethodID multipathIndicatorSetterMethod =
             env->GetMethodID(gpsMeasurementClass, "setMultipathIndicator", byteSignature);
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             multipathIndicatorSetterMethod,
             measurement->multipath_indicator);
@@ -1148,19 +1154,19 @@
     if (flags & GPS_MEASUREMENT_HAS_SNR) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setSnrInDb", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->snr_db);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->snr_db);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_ELEVATION) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setElevationInDeg", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->elevation_deg);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->elevation_deg);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_ELEVATION_UNCERTAINTY) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setElevationUncertaintyInDeg", doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->elevation_uncertainty_deg);
@@ -1169,7 +1175,7 @@
     if (flags & GPS_MEASUREMENT_HAS_AZIMUTH) {
         jmethodID setterMethod =
                 env->GetMethodID(gpsMeasurementClass, "setAzimuthInDeg", doubleSignature);
-        env->CallObjectMethod(gpsMeasurementObject, setterMethod, measurement->azimuth_deg);
+        env->CallVoidMethod(gpsMeasurementObject, setterMethod, measurement->azimuth_deg);
     }
 
     if (flags & GPS_MEASUREMENT_HAS_AZIMUTH_UNCERTAINTY) {
@@ -1177,14 +1183,14 @@
                 gpsMeasurementClass,
                 "setAzimuthUncertaintyInDeg",
                 doubleSignature);
-        env->CallObjectMethod(
+        env->CallVoidMethod(
                 gpsMeasurementObject,
                 setterMethod,
                 measurement->azimuth_uncertainty_deg);
     }
 
     jmethodID usedInFixSetterMethod = env->GetMethodID(gpsMeasurementClass, "setUsedInFix", "(Z)V");
-    env->CallObjectMethod(
+    env->CallVoidMethod(
             gpsMeasurementObject,
             usedInFixSetterMethod,
             (flags & GPS_MEASUREMENT_HAS_USED_IN_FIX) && measurement->used_in_fix);
@@ -1240,6 +1246,11 @@
 
         env->CallVoidMethod(mCallbacksObj, method_reportMeasurementData, gpsMeasurementsEvent);
         checkAndClearExceptionFromCallback(env, __FUNCTION__);
+
+        env->DeleteLocalRef(gpsClock);
+        env->DeleteLocalRef(measurementArray);
+        env->DeleteLocalRef(gpsMeasurementsEventClass);
+        env->DeleteLocalRef(gpsMeasurementsEvent);
     } else {
         ALOGE("Invalid GpsData size found in gps_measurement_callback, size=%d", data->size);
     }
@@ -1318,6 +1329,8 @@
     jmethodID setDataMethod = env->GetMethodID(navigationMessageClass, "setData", "([B)V");
     env->CallVoidMethod(navigationMessageObject, setDataMethod, dataArray);
 
+    env->DeleteLocalRef(navigationMessageClass);
+    env->DeleteLocalRef(dataArray);
     return navigationMessageObject;
 }
 
@@ -1344,6 +1357,10 @@
 
         env->CallVoidMethod(mCallbacksObj, method_reportNavigationMessages, navigationMessageEvent);
         checkAndClearExceptionFromCallback(env, __FUNCTION__);
+
+        env->DeleteLocalRef(navigationMessage);
+        env->DeleteLocalRef(navigationMessageEventClass);
+        env->DeleteLocalRef(navigationMessageEvent);
     } else {
         ALOGE("Invalid GpsNavigationMessage size found: %d", message->size);
     }
@@ -1392,6 +1409,20 @@
     return JNI_TRUE;
 }
 
+static void android_location_GpsLocationProvider_configuration_update(JNIEnv* env, jobject obj,
+        jstring config_content)
+{
+    if (!sGnssConfigurationInterface) {
+        ALOGE("no GPS configuration interface in configuraiton_update");
+        return;
+    }
+    const char *data = env->GetStringUTFChars(config_content, NULL);
+    ALOGD("GPS configuration:\n %s", data);
+    sGnssConfigurationInterface->configuration_update(
+            data, env->GetStringUTFLength(config_content));
+    env->ReleaseStringUTFChars(config_content, data);
+}
+
 static JNINativeMethod sMethods[] = {
      /* name, signature, funcPtr */
     {"class_init_native", "()V", (void *)android_location_GpsLocationProvider_class_init_native},
@@ -1479,6 +1510,9 @@
     {"native_stop_navigation_message_collection",
             "()Z",
             (void*) android_location_GpsLocationProvider_stop_navigation_message_collection},
+    {"native_configuration_update",
+            "(Ljava/lang/String;)V",
+            (void*)android_location_GpsLocationProvider_configuration_update},
 };
 
 int register_android_server_location_GpsLocationProvider(JNIEnv* env)
diff --git a/services/core/jni/onload.cpp b/services/core/jni/onload.cpp
index 39b70a8..7b2e408 100644
--- a/services/core/jni/onload.cpp
+++ b/services/core/jni/onload.cpp
@@ -38,7 +38,6 @@
 int register_android_server_location_FlpHardwareProvider(JNIEnv* env);
 int register_android_server_connectivity_Vpn(JNIEnv* env);
 int register_android_server_hdmi_HdmiCecController(JNIEnv* env);
-int register_android_server_hdmi_HdmiMhlController(JNIEnv* env);
 int register_android_server_tv_TvInputHal(JNIEnv* env);
 int register_android_server_PersistentDataBlockService(JNIEnv* env);
 int register_android_server_fingerprint_FingerprintService(JNIEnv* env);
@@ -76,7 +75,6 @@
     register_android_server_ConsumerIrService(env);
     register_android_server_BatteryStatsService(env);
     register_android_server_hdmi_HdmiCecController(env);
-    register_android_server_hdmi_HdmiMhlController(env);
     register_android_server_tv_TvInputHal(env);
     register_android_server_PersistentDataBlockService(env);
     register_android_server_fingerprint_FingerprintService(env);
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DeviceOwner.java b/services/devicepolicy/java/com/android/server/devicepolicy/DeviceOwner.java
index 4b60c9f..5938819 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DeviceOwner.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DeviceOwner.java
@@ -267,6 +267,9 @@
             if (mDeviceOwner != null) {
                 out.startTag(null, TAG_DEVICE_OWNER);
                 out.attribute(null, ATTR_PACKAGE, mDeviceOwner.packageName);
+                if (mDeviceOwner.name != null) {
+                    out.attribute(null, ATTR_NAME, mDeviceOwner.name);
+                }
                 out.endTag(null, TAG_DEVICE_OWNER);
             }
 
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
index 958cb6d..95332bc 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
@@ -18,18 +18,8 @@
 
 import static android.Manifest.permission.MANAGE_CA_CERTIFICATES;
 
-import android.app.admin.DevicePolicyManagerInternal;
-
-import com.android.internal.R;
-import com.android.internal.os.storage.ExternalStorageFormatter;
-import com.android.internal.util.FastXmlSerializer;
-import com.android.internal.util.JournaledFile;
-import com.android.internal.util.XmlUtils;
-import com.android.internal.widget.LockPatternUtils;
-import com.android.org.conscrypt.TrustedCertificateStore;
-import com.android.server.LocalServices;
-import com.android.server.SystemService;
-
+import android.accessibilityservice.AccessibilityServiceInfo;
+import android.accounts.AccountManager;
 import android.app.Activity;
 import android.app.ActivityManagerNative;
 import android.app.AlarmManager;
@@ -41,6 +31,7 @@
 import android.app.admin.DeviceAdminInfo;
 import android.app.admin.DeviceAdminReceiver;
 import android.app.admin.DevicePolicyManager;
+import android.app.admin.DevicePolicyManagerInternal;
 import android.app.admin.IDevicePolicyManager;
 import android.content.BroadcastReceiver;
 import android.content.ComponentName;
@@ -51,16 +42,16 @@
 import android.content.pm.ApplicationInfo;
 import android.content.pm.IPackageManager;
 import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.pm.ResolveInfo;
 import android.content.pm.UserInfo;
+import android.database.ContentObserver;
+import android.hardware.usb.UsbManager;
 import android.media.AudioManager;
 import android.media.IAudioService;
 import android.net.ConnectivityManager;
-import android.net.Uri;
-import android.content.pm.PackageManager.NameNotFoundException;
-import android.database.ContentObserver;
-import android.hardware.usb.UsbManager;
 import android.net.ProxyInfo;
+import android.net.Uri;
 import android.os.Binder;
 import android.os.Bundle;
 import android.os.Environment;
@@ -88,8 +79,22 @@
 import android.util.Slog;
 import android.util.SparseArray;
 import android.util.Xml;
+import android.view.accessibility.AccessibilityManager;
+import android.view.accessibility.IAccessibilityManager;
+import android.view.inputmethod.InputMethodInfo;
+import android.view.inputmethod.InputMethodManager;
 import android.view.IWindowManager;
 
+import com.android.internal.R;
+import com.android.internal.os.storage.ExternalStorageFormatter;
+import com.android.internal.util.FastXmlSerializer;
+import com.android.internal.util.JournaledFile;
+import com.android.internal.util.XmlUtils;
+import com.android.internal.widget.LockPatternUtils;
+import com.android.org.conscrypt.TrustedCertificateStore;
+import com.android.server.LocalServices;
+import com.android.server.SystemService;
+
 import org.xmlpull.v1.XmlPullParser;
 
 import static org.xmlpull.v1.XmlPullParser.END_DOCUMENT;
@@ -107,6 +112,7 @@
 import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.PrintWriter;
+import java.security.cert.CertificateEncodingException;
 import java.security.cert.CertificateException;
 import java.security.cert.CertificateFactory;
 import java.security.cert.X509Certificate;
@@ -147,10 +153,53 @@
     private static final String ATTR_PERMISSION_PROVIDER = "permission-provider";
     private static final String ATTR_SETUP_COMPLETE = "setup-complete";
 
+    private static final Set<String> DEVICE_OWNER_USER_RESTRICTIONS;
+    static {
+        DEVICE_OWNER_USER_RESTRICTIONS = new HashSet();
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_USB_FILE_TRANSFER);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_CONFIG_TETHERING);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_FACTORY_RESET);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_ADD_USER);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_CONFIG_CELL_BROADCASTS);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_CONFIG_MOBILE_NETWORKS);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_MOUNT_PHYSICAL_MEDIA);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_UNMUTE_MICROPHONE);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_ADJUST_VOLUME);
+        DEVICE_OWNER_USER_RESTRICTIONS.add(UserManager.DISALLOW_SMS);
+    }
+
+    private static final Set<String> SECURE_SETTINGS_WHITELIST;
+    private static final Set<String> SECURE_SETTINGS_DEVICEOWNER_WHITELIST;
+    private static final Set<String> GLOBAL_SETTINGS_WHITELIST;
+    static {
+        SECURE_SETTINGS_WHITELIST = new HashSet();
+        SECURE_SETTINGS_WHITELIST.add(Settings.Secure.DEFAULT_INPUT_METHOD);
+        SECURE_SETTINGS_WHITELIST.add(Settings.Secure.SKIP_FIRST_USE_HINTS);
+
+        SECURE_SETTINGS_DEVICEOWNER_WHITELIST = new HashSet();
+        SECURE_SETTINGS_DEVICEOWNER_WHITELIST.addAll(SECURE_SETTINGS_WHITELIST);
+        SECURE_SETTINGS_DEVICEOWNER_WHITELIST.add(Settings.Secure.LOCATION_MODE);
+
+        GLOBAL_SETTINGS_WHITELIST = new HashSet();
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.ADB_ENABLED);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.AUTO_TIME);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.AUTO_TIME_ZONE);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.BLUETOOTH_ON);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.DATA_ROAMING);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.DEVELOPMENT_SETTINGS_ENABLED);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.MODE_RINGER);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.NETWORK_PREFERENCE);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.USB_MASS_STORAGE_ENABLED);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.WIFI_ON);
+        GLOBAL_SETTINGS_WHITELIST.add(Settings.Global.WIFI_SLEEP_POLICY);
+    }
+
     final Context mContext;
     final UserManager mUserManager;
     final PowerManager.WakeLock mWakeLock;
 
+    final LocalService mLocalService;
+
     IPowerManager mIPowerManager;
     IWindowManager mIWindowManager;
     NotificationManager mNotificationManager;
@@ -265,7 +314,10 @@
         private static final String TAG_DISABLE_CALLER_ID = "disable-caller-id";
         private static final String TAG_DISABLE_SCREEN_CAPTURE = "disable-screen-capture";
         private static final String TAG_DISABLE_ACCOUNT_MANAGEMENT = "disable-account-management";
+        private static final String TAG_REQUIRE_AUTO_TIME = "require_auto_time";
         private static final String TAG_ACCOUNT_TYPE = "account-type";
+        private static final String TAG_PERMITTED_ACCESSIBILITY_SERVICES
+                = "permitted-accessiblity-services";
         private static final String TAG_ENCRYPTION_REQUESTED = "encryption-requested";
         private static final String TAG_MANAGE_TRUST_AGENT_FEATURES = "manage-trust-agent-features";
         private static final String TAG_TRUST_AGENT_FEATURE = "feature";
@@ -275,6 +327,7 @@
         private static final String TAG_GLOBAL_PROXY_EXCLUSION_LIST = "global-proxy-exclusion-list";
         private static final String TAG_GLOBAL_PROXY_SPEC = "global-proxy-spec";
         private static final String TAG_SPECIFIES_GLOBAL_PROXY = "specifies-global-proxy";
+        private static final String TAG_PERMITTED_IMES = "permitted-imes";
         private static final String TAG_MAX_FAILED_PASSWORD_WIPE = "max-failed-password-wipe";
         private static final String TAG_MAX_TIME_TO_UNLOCK = "max-time-to-unlock";
         private static final String TAG_MIN_PASSWORD_NONLETTER = "min-password-nonletter";
@@ -291,6 +344,7 @@
         private static final String TAG_CROSS_PROFILE_WIDGET_PROVIDERS =
                 "cross-profile-widget-providers";
         private static final String TAG_PROVIDER = "provider";
+        private static final String TAG_PACKAGE_LIST_ITEM  = "item";
 
         final DeviceAdminInfo info;
 
@@ -339,9 +393,20 @@
         boolean disableCamera = false;
         boolean disableCallerId = false;
         boolean disableScreenCapture = false; // Can only be set by a device/profile owner.
+        boolean requireAutoTime = false; // Can only be set by a device owner.
 
         Set<String> accountTypesWithManagementDisabled = new HashSet<String>();
 
+        // The list of permitted accessibility services package namesas set by a profile
+        // or device owner. Null means all accessibility services are allowed, empty means
+        // none except system services are allowed.
+        List<String> permittedAccessiblityServices;
+
+        // The list of permitted input methods package names as set by a profile or device owner.
+        // Null means all input methods are allowed, empty means none except system imes are
+        // allowed.
+        List<String> permittedInputMethods;
+
         // TODO: review implementation decisions with frameworks team
         boolean specifiesGlobalProxy = false;
         String globalProxySpec = null;
@@ -465,6 +530,11 @@
                 out.attribute(null, ATTR_VALUE, Boolean.toString(disableScreenCapture));
                 out.endTag(null, TAG_DISABLE_SCREEN_CAPTURE);
             }
+            if (requireAutoTime) {
+                out.startTag(null, TAG_REQUIRE_AUTO_TIME);
+                out.attribute(null, ATTR_VALUE, Boolean.toString(requireAutoTime));
+                out.endTag(null, TAG_REQUIRE_AUTO_TIME);
+            }
             if (disabledKeyguardFeatures != DEF_KEYGUARD_FEATURES_DISABLED) {
                 out.startTag(null, TAG_DISABLE_KEYGUARD_FEATURES);
                 out.attribute(null, ATTR_VALUE, Integer.toString(disabledKeyguardFeatures));
@@ -505,6 +575,25 @@
                 }
                 out.endTag(null, TAG_CROSS_PROFILE_WIDGET_PROVIDERS);
             }
+            writePackageListToXml(out, TAG_PERMITTED_ACCESSIBILITY_SERVICES,
+                    permittedAccessiblityServices);
+            writePackageListToXml(out, TAG_PERMITTED_IMES, permittedInputMethods);
+        }
+
+        void writePackageListToXml(XmlSerializer out, String outerTag,
+                List<String> packageList)
+                throws IllegalArgumentException, IllegalStateException, IOException {
+            if (packageList == null) {
+                return;
+            }
+
+            out.startTag(null, outerTag);
+            for (String packageName : packageList) {
+                out.startTag(null, TAG_PACKAGE_LIST_ITEM);
+                out.attribute(null, ATTR_VALUE, packageName);
+                out.endTag(null, TAG_PACKAGE_LIST_ITEM);
+            }
+            out.endTag(null, outerTag);
         }
 
         void readFromXml(XmlPullParser parser)
@@ -579,6 +668,9 @@
                 } else if (TAG_DISABLE_SCREEN_CAPTURE.equals(tag)) {
                     disableScreenCapture = Boolean.parseBoolean(
                             parser.getAttributeValue(null, ATTR_VALUE));
+                } else if (TAG_REQUIRE_AUTO_TIME.equals(tag)) {
+                    requireAutoTime= Boolean.parseBoolean(
+                            parser.getAttributeValue(null, ATTR_VALUE));
                 } else if (TAG_DISABLE_KEYGUARD_FEATURES.equals(tag)) {
                     disabledKeyguardFeatures = Integer.parseInt(
                             parser.getAttributeValue(null, ATTR_VALUE));
@@ -588,6 +680,10 @@
                     trustAgentFeatures = getAllTrustAgentFeatures(parser, tag);
                 } else if (TAG_CROSS_PROFILE_WIDGET_PROVIDERS.equals(tag)) {
                     crossProfileWidgetProviders = getCrossProfileWidgetProviders(parser, tag);
+                } else if (TAG_PERMITTED_ACCESSIBILITY_SERVICES.equals(tag)) {
+                    permittedAccessiblityServices = readPackageList(parser, tag);
+                } else if (TAG_PERMITTED_IMES.equals(tag)) {
+                    permittedInputMethods = readPackageList(parser, tag);
                 } else {
                     Slog.w(LOG_TAG, "Unknown admin tag: " + tag);
                 }
@@ -595,6 +691,31 @@
             }
         }
 
+        private List<String> readPackageList(XmlPullParser parser,
+                String tag) throws XmlPullParserException, IOException {
+            List<String> result = new ArrayList<String>();
+            int outerDepth = parser.getDepth();
+            int outerType;
+            while ((outerType=parser.next()) != XmlPullParser.END_DOCUMENT
+                    && (outerType != XmlPullParser.END_TAG || parser.getDepth() > outerDepth)) {
+                if (outerType == XmlPullParser.END_TAG || outerType == XmlPullParser.TEXT) {
+                    continue;
+                }
+                String outerTag = parser.getName();
+                if (TAG_PACKAGE_LIST_ITEM.equals(outerTag)) {
+                    String packageName = parser.getAttributeValue(null, ATTR_VALUE);
+                    if (packageName != null) {
+                        result.add(packageName);
+                    } else {
+                        Slog.w(LOG_TAG, "Package name missing under " + outerTag);
+                    }
+                } else {
+                    Slog.w(LOG_TAG, "Unknown tag under " + tag +  ": " + outerTag);
+                }
+            }
+            return result;
+        }
+
         private Set<String> readDisableAccountInfo(XmlPullParser parser, String tag)
                 throws XmlPullParserException, IOException {
             int outerDepthDAM = parser.getDepth();
@@ -734,10 +855,20 @@
                     pw.println(disableCallerId);
             pw.print(prefix); pw.print("disableScreenCapture=");
                     pw.println(disableScreenCapture);
+            pw.print(prefix); pw.print("requireAutoTime=");
+                    pw.println(requireAutoTime);
             pw.print(prefix); pw.print("disabledKeyguardFeatures=");
                     pw.println(disabledKeyguardFeatures);
             pw.print(prefix); pw.print("crossProfileWidgetProviders=");
                     pw.println(crossProfileWidgetProviders);
+            if (!(permittedAccessiblityServices == null)) {
+                pw.print(prefix); pw.print("permittedAccessibilityServices=");
+                        pw.println(permittedAccessiblityServices.toString());
+            }
+            if (!(permittedInputMethods == null)) {
+                pw.print(prefix); pw.print("permittedInputMethods=");
+                        pw.println(permittedInputMethods.toString());
+            }
         }
     }
 
@@ -776,6 +907,7 @@
                 PackageManager.FEATURE_DEVICE_ADMIN);
         mWakeLock = ((PowerManager)context.getSystemService(Context.POWER_SERVICE))
                 .newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "DPM");
+        mLocalService = new LocalService();
         if (!mHasFeature) {
             // Skip the rest of the initialization
             return;
@@ -796,7 +928,7 @@
         filter.addDataScheme("package");
         context.registerReceiverAsUser(mReceiver, UserHandle.ALL, filter, null, mHandler);
 
-        LocalServices.addService(DevicePolicyManagerInternal.class, new LocalService());
+        LocalServices.addService(DevicePolicyManagerInternal.class, mLocalService);
     }
 
     /**
@@ -1517,6 +1649,8 @@
             .setContentIntent(notifyIntent)
             .setPriority(Notification.PRIORITY_HIGH)
             .setShowWhen(false)
+            .setColor(mContext.getResources().getColor(
+                    com.android.internal.R.color.system_notification_accent_color))
             .build();
 
         // If this is a boot intent, this will fire for each user. But if this is a storage changed
@@ -1883,44 +2017,71 @@
 
     @Override
     public boolean addCrossProfileWidgetProvider(ComponentName admin, String packageName) {
-        ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
-                DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
-        if (activeAdmin.crossProfileWidgetProviders == null) {
-            activeAdmin.crossProfileWidgetProviders = new ArrayList<>();
+        final int userId = UserHandle.getCallingUserId();
+        List<String> changedProviders = null;
+
+        synchronized (this) {
+            ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            if (activeAdmin.crossProfileWidgetProviders == null) {
+                activeAdmin.crossProfileWidgetProviders = new ArrayList<>();
+            }
+            List<String> providers = activeAdmin.crossProfileWidgetProviders;
+            if (!providers.contains(packageName)) {
+                providers.add(packageName);
+                changedProviders = new ArrayList<>(providers);
+                saveSettingsLocked(userId);
+            }
         }
-        if (activeAdmin.crossProfileWidgetProviders.add(packageName)) {
-            saveSettingsLocked(UserHandle.getCallingUserId());
+
+        if (changedProviders != null) {
+            mLocalService.notifyCrossProfileProvidersChanged(userId, changedProviders);
             return true;
         }
+
         return false;
     }
 
     @Override
     public boolean removeCrossProfileWidgetProvider(ComponentName admin, String packageName) {
-        ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
-                DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
-        if (activeAdmin.crossProfileWidgetProviders == null) {
-            return false;
+        final int userId = UserHandle.getCallingUserId();
+        List<String> changedProviders = null;
+
+        synchronized (this) {
+            ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            if (activeAdmin.crossProfileWidgetProviders == null) {
+                return false;
+            }
+            List<String> providers = activeAdmin.crossProfileWidgetProviders;
+            if (providers.remove(packageName)) {
+                changedProviders = new ArrayList<>(providers);
+                saveSettingsLocked(userId);
+            }
         }
-        if (activeAdmin.crossProfileWidgetProviders.remove(packageName)) {
-            saveSettingsLocked(UserHandle.getCallingUserId());
+
+        if (changedProviders != null) {
+            mLocalService.notifyCrossProfileProvidersChanged(userId, changedProviders);
             return true;
         }
+
         return false;
     }
 
     @Override
     public List<String> getCrossProfileWidgetProviders(ComponentName admin) {
-        ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
-                DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
-        if (activeAdmin.crossProfileWidgetProviders == null
-                || activeAdmin.crossProfileWidgetProviders.isEmpty()) {
-            return null;
-        }
-        if (Binder.getCallingUid() == Process.myUid()) {
-            return new ArrayList<>(activeAdmin.crossProfileWidgetProviders);
-        } else {
-            return activeAdmin.crossProfileWidgetProviders;
+        synchronized (this) {
+            ActiveAdmin activeAdmin = getActiveAdminForCallerLocked(admin,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            if (activeAdmin.crossProfileWidgetProviders == null
+                    || activeAdmin.crossProfileWidgetProviders.isEmpty()) {
+                return null;
+            }
+            if (Binder.getCallingUid() == Process.myUid()) {
+                return new ArrayList<>(activeAdmin.crossProfileWidgetProviders);
+            } else {
+                return activeAdmin.crossProfileWidgetProviders;
+            }
         }
     }
 
@@ -2594,7 +2755,8 @@
         return !"".equals(state);
     }
 
-    public boolean installCaCert(ComponentName who, byte[] certBuffer) throws RemoteException {
+    @Override
+    public void enforceCanManageCaCerts(ComponentName who) {
         if (who == null) {
             mContext.enforceCallingOrSelfPermission(MANAGE_CA_CERTIFICATES, null);
         } else {
@@ -2602,6 +2764,11 @@
                 getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
             }
         }
+    }
+
+    @Override
+    public boolean installCaCert(ComponentName admin, byte[] certBuffer) throws RemoteException {
+        enforceCanManageCaCerts(admin);
 
         byte[] pemCert;
         try {
@@ -2636,21 +2803,15 @@
         return false;
     }
 
-    private static X509Certificate parseCert(byte[] certBuffer)
-            throws CertificateException, IOException {
+    private static X509Certificate parseCert(byte[] certBuffer) throws CertificateException {
         CertificateFactory certFactory = CertificateFactory.getInstance("X.509");
         return (X509Certificate) certFactory.generateCertificate(new ByteArrayInputStream(
                 certBuffer));
     }
 
-    public void uninstallCaCert(ComponentName who, String alias) {
-        if (who == null) {
-            mContext.enforceCallingOrSelfPermission(MANAGE_CA_CERTIFICATES, null);
-        } else {
-            synchronized (this) {
-                getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
-            }
-        }
+    @Override
+    public void uninstallCaCert(ComponentName admin, String alias) {
+        enforceCanManageCaCerts(admin);
 
         final UserHandle userHandle = new UserHandle(UserHandle.getCallingUserId());
         final long id = Binder.clearCallingIdentity();
@@ -2671,6 +2832,35 @@
         }
     }
 
+    @Override
+    public boolean installKeyPair(ComponentName who, byte[] privKey, byte[] cert, String alias) {
+        if (who == null) {
+            throw new NullPointerException("ComponentName is null");
+        }
+        synchronized (this) {
+            getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+        }
+        final UserHandle userHandle = new UserHandle(UserHandle.getCallingUserId());
+        final long id = Binder.clearCallingIdentity();
+        try {
+          final KeyChainConnection keyChainConnection = KeyChain.bindAsUser(mContext, userHandle);
+          try {
+              IKeyChainService keyChain = keyChainConnection.getService();
+              return keyChain.installKeyPair(privKey, cert, alias);
+          } catch (RemoteException e) {
+              Log.e(LOG_TAG, "Installing certificate", e);
+          } finally {
+              keyChainConnection.close();
+          }
+        } catch (InterruptedException e) {
+            Log.w(LOG_TAG, "Interrupted while installing certificate", e);
+            Thread.currentThread().interrupt();
+        } finally {
+            Binder.restoreCallingIdentity(id);
+        }
+        return false;
+    }
+
     void wipeDataLocked(int flags) {
         // If the SD card is encrypted and non-removable, we have to force a wipe.
         boolean forceExtWipe = !Environment.isExternalStorageRemovable() && isExtStorageEncrypted();
@@ -2843,10 +3033,12 @@
         mContext.enforceCallingOrSelfPermission(
                 android.Manifest.permission.BIND_DEVICE_ADMIN, null);
 
-        synchronized (this) {
-            DevicePolicyData policy = getUserData(userHandle);
-            long ident = Binder.clearCallingIdentity();
-            try {
+        long ident = Binder.clearCallingIdentity();
+        try {
+            boolean wipeData = false;
+            int identifier = 0;
+            synchronized (this) {
+                DevicePolicyData policy = getUserData(userHandle);
                 policy.mFailedPasswordAttempts++;
                 saveSettingsLocked(userHandle);
                 if (mHasFeature) {
@@ -2858,15 +3050,20 @@
                         // Wipe the user/profile associated with the policy that was violated. This
                         // is not necessarily calling user: if the policy that fired was from a
                         // managed profile rather than the main user profile, we wipe former only.
-                        wipeDeviceOrUserLocked(0, strictestAdmin.getUserHandle().getIdentifier());
+                        wipeData = true;
+                        identifier = strictestAdmin.getUserHandle().getIdentifier();
                     }
                     sendAdminCommandToSelfAndProfilesLocked(
                             DeviceAdminReceiver.ACTION_PASSWORD_FAILED,
                             DeviceAdminInfo.USES_POLICY_WATCH_LOGIN, userHandle);
                 }
-            } finally {
-                Binder.restoreCallingIdentity(ident);
             }
+            if (wipeData) {
+                // Call without holding lock.
+                wipeDeviceOrUserLocked(0, identifier);
+            }
+        } finally {
+            Binder.restoreCallingIdentity(ident);
         }
     }
 
@@ -3169,6 +3366,7 @@
         if (!mHasFeature) {
             return;
         }
+        enforceCrossUserPermission(userHandle);
         synchronized (this) {
             if (who == null) {
                 throw new NullPointerException("ComponentName is null");
@@ -3221,6 +3419,51 @@
     }
 
     /**
+     * Set whether auto time is required by the specified admin (must be device owner).
+     */
+    public void setAutoTimeRequired(ComponentName who, int userHandle, boolean required) {
+        if (!mHasFeature) {
+            return;
+        }
+        enforceCrossUserPermission(userHandle);
+        synchronized (this) {
+            if (who == null) {
+                throw new NullPointerException("ComponentName is null");
+            }
+            ActiveAdmin admin = getActiveAdminForCallerLocked(who,
+                    DeviceAdminInfo.USES_POLICY_DEVICE_OWNER);
+            if (admin.requireAutoTime != required) {
+                admin.requireAutoTime = required;
+                saveSettingsLocked(userHandle);
+            }
+        }
+
+        // Turn AUTO_TIME on in settings if it is required
+        if (required) {
+            long ident = Binder.clearCallingIdentity();
+            try {
+                Settings.Global.putInt(mContext.getContentResolver(),
+                        Settings.Global.AUTO_TIME, 1 /* AUTO_TIME on */);
+            } finally {
+                Binder.restoreCallingIdentity(ident);
+            }
+        }
+    }
+
+    /**
+     * Returns whether or not auto time is required by the device owner.
+     */
+    public boolean getAutoTimeRequired() {
+        if (!mHasFeature) {
+            return false;
+        }
+        synchronized (this) {
+            ActiveAdmin deviceOwner = getDeviceOwnerAdmin();
+            return (deviceOwner != null) ? deviceOwner.requireAutoTime : false;
+        }
+    }
+
+    /**
      * The system property used to share the state of the camera. The native camera service
      * is expected to read this property and act accordingly.
      */
@@ -3337,7 +3580,7 @@
                     + " for device owner");
         }
         synchronized (this) {
-            if (isDeviceProvisioned()) {
+            if (!allowedToSetDeviceOwnerOnDevice()) {
                 throw new IllegalStateException(
                         "Trying to set device owner but device is already provisioned.");
             }
@@ -3400,6 +3643,24 @@
         return null;
     }
 
+    // Returns the active device owner or null if there is no device owner.
+    private ActiveAdmin getDeviceOwnerAdmin() {
+        String deviceOwnerPackageName = getDeviceOwner();
+        if (deviceOwnerPackageName == null) {
+            return null;
+        }
+
+        DevicePolicyData policy = getUserData(UserHandle.USER_OWNER);
+        final int n = policy.mAdminList.size();
+        for (int i = 0; i < n; i++) {
+            ActiveAdmin admin = policy.mAdminList.get(i);
+            if (deviceOwnerPackageName.equals(admin.info.getPackageName())) {
+                return admin;
+            }
+        }
+        return null;
+    }
+
     @Override
     public void clearDeviceOwner(String packageName) {
         if (packageName == null) {
@@ -3437,11 +3698,15 @@
         }
         mContext.enforceCallingOrSelfPermission(android.Manifest.permission.MANAGE_USERS, null);
 
-        if (mUserManager.getUserInfo(userHandle) == null) {
+        UserInfo info = mUserManager.getUserInfo(userHandle);
+        if (info == null) {
             // User doesn't exist.
             throw new IllegalArgumentException(
                     "Attempted to set profile owner for invalid userId: " + userHandle);
         }
+        if (info.isGuest()) {
+            throw new IllegalStateException("Cannot set a profile owner on a guest");
+        }
 
         if (who == null
                 || !DeviceOwner.isInstalledForUser(who.getPackageName(), userHandle)) {
@@ -3451,7 +3716,7 @@
         synchronized (this) {
             // Only SYSTEM_UID can override the userSetupComplete
             if (UserHandle.getAppId(Binder.getCallingUid()) != Process.SYSTEM_UID
-                    && isUserSetupComplete(userHandle)) {
+                    && hasUserSetupCompleted(userHandle)) {
                 throw new IllegalStateException(
                         "Trying to set profile owner but user is already set-up.");
             }
@@ -3508,10 +3773,14 @@
 
     @Override
     public boolean hasUserSetupCompleted() {
+        return hasUserSetupCompleted(UserHandle.getCallingUserId());
+    }
+
+    private boolean hasUserSetupCompleted(int userHandle) {
         if (!mHasFeature) {
             return true;
         }
-        DevicePolicyData policy = getUserData(UserHandle.getCallingUserId());
+        DevicePolicyData policy = getUserData(userHandle);
         // If policy is null, return true, else check if the setup has completed.
         return policy == null || policy.mUserSetupComplete;
     }
@@ -3521,6 +3790,7 @@
         if (!mHasFeature) {
             return;
         }
+        final int userHandle = UserHandle.getCallingUserId();
         synchronized (this) {
             // Check for permissions
             if (who == null) {
@@ -3534,7 +3804,7 @@
             try {
                 mUserManager.setUserEnabled(userId);
                 Intent intent = new Intent(Intent.ACTION_MANAGED_PROFILE_ADDED);
-                intent.putExtra(Intent.EXTRA_USER, new UserHandle(UserHandle.getCallingUserId()));
+                intent.putExtra(Intent.EXTRA_USER, new UserHandle(userHandle));
                 intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY |
                         Intent.FLAG_RECEIVER_FOREGROUND);
                 // TODO This should send to parent of profile (which is always owner at the moment).
@@ -3613,14 +3883,17 @@
         return null;
     }
 
-    private boolean isDeviceProvisioned() {
-        return Settings.Global.getInt(mContext.getContentResolver(),
-                Settings.Global.DEVICE_PROVISIONED, 0) > 0;
-    }
-
-    private boolean isUserSetupComplete(int userId) {
-        return Settings.Secure.getIntForUser(mContext.getContentResolver(),
-                Settings.Secure.USER_SETUP_COMPLETE, 0, userId) > 0;
+    /**
+     * Device owner can only be set on an unprovisioned device, unless it was initiated by "adb", in
+     * which case we allow it if no account is associated with the device.
+     */
+    private boolean allowedToSetDeviceOwnerOnDevice() {
+        int callingId = Binder.getCallingUid();
+        if (callingId == Process.SHELL_UID || callingId == Process.ROOT_UID) {
+            return AccountManager.get(mContext).getAccounts().length == 0;
+        } else {
+            return !hasUserSetupCompleted(UserHandle.USER_OWNER);
+        }
     }
 
     private void enforceCrossUserPermission(int userHandle) {
@@ -3721,6 +3994,8 @@
     @Override
     public void addPersistentPreferredActivity(ComponentName who, IntentFilter filter,
             ComponentName activity) {
+        final int userHandle = UserHandle.getCallingUserId();
+
         synchronized (this) {
             if (who == null) {
                 throw new NullPointerException("ComponentName is null");
@@ -3730,7 +4005,7 @@
             IPackageManager pm = AppGlobals.getPackageManager();
             long id = Binder.clearCallingIdentity();
             try {
-                pm.addPersistentPreferredActivity(filter, activity, UserHandle.getCallingUserId());
+                pm.addPersistentPreferredActivity(filter, activity, userHandle);
             } catch (RemoteException re) {
                 // Shouldn't happen
             } finally {
@@ -3741,6 +4016,8 @@
 
     @Override
     public void clearPackagePersistentPreferredActivities(ComponentName who, String packageName) {
+        final int userHandle = UserHandle.getCallingUserId();
+
         synchronized (this) {
             if (who == null) {
                 throw new NullPointerException("ComponentName is null");
@@ -3750,7 +4027,7 @@
             IPackageManager pm = AppGlobals.getPackageManager();
             long id = Binder.clearCallingIdentity();
             try {
-                pm.clearPackagePersistentPreferredActivities(packageName, UserHandle.getCallingUserId());
+                pm.clearPackagePersistentPreferredActivities(packageName, userHandle);
             } catch (RemoteException re) {
                 // Shouldn't happen
             } finally {
@@ -3925,6 +4202,343 @@
         }
     }
 
+    /**
+     * @return true if all packages in enabledPackages are either in the list
+     * permittedList or are a system app.
+     */
+    private boolean checkPackagesInPermittedListOrSystem(List<String> enabledPackages,
+            List<String> permittedList) {
+        int userIdToCheck = UserHandle.getCallingUserId();
+        long id = Binder.clearCallingIdentity();
+        try {
+            // If we have an enabled packages list for a managed profile the packages
+            // we should check are installed for the parent user.
+            UserInfo user = mUserManager.getUserInfo(userIdToCheck);
+            if (user.isManagedProfile()) {
+                userIdToCheck = user.profileGroupId;
+            }
+
+            IPackageManager pm = AppGlobals.getPackageManager();
+            for (String enabledPackage : enabledPackages) {
+                boolean systemService = false;
+                try {
+                    ApplicationInfo applicationInfo = pm.getApplicationInfo(enabledPackage,
+                            PackageManager.GET_UNINSTALLED_PACKAGES, userIdToCheck);
+                    systemService = (applicationInfo.flags
+                            & ApplicationInfo.FLAG_SYSTEM) != 0;
+                } catch (RemoteException e) {
+                    Log.i(LOG_TAG, "Can't talk to package managed", e);
+                }
+                if (!systemService && !permittedList.contains(enabledPackage)) {
+                    return false;
+                }
+            }
+        } finally {
+            restoreCallingIdentity(id);
+        }
+        return true;
+    }
+
+    private AccessibilityManager getAccessibilityManagerForUser(int userId) {
+        // Not using AccessibilityManager.getInstance because that guesses
+        // at the user you require based on callingUid and caches for a given
+        // process.
+        IBinder iBinder = ServiceManager.getService(Context.ACCESSIBILITY_SERVICE);
+        IAccessibilityManager service = iBinder == null
+                ? null : IAccessibilityManager.Stub.asInterface(iBinder);
+        return new AccessibilityManager(mContext, service, userId);
+    }
+
+    @Override
+    public boolean setPermittedAccessibilityServices(ComponentName who, List packageList) {
+        if (!mHasFeature) {
+            return false;
+        }
+        if (who == null) {
+            throw new NullPointerException("ComponentName is null");
+        }
+
+        if (packageList != null) {
+            int userId = UserHandle.getCallingUserId();
+            List<AccessibilityServiceInfo> enabledServices = null;
+            long id = Binder.clearCallingIdentity();
+            try {
+                UserInfo user = mUserManager.getUserInfo(userId);
+                if (user.isManagedProfile()) {
+                    userId = user.profileGroupId;
+                }
+                AccessibilityManager accessibilityManager = getAccessibilityManagerForUser(userId);
+                enabledServices = accessibilityManager.getEnabledAccessibilityServiceList(
+                        AccessibilityServiceInfo.FEEDBACK_ALL_MASK);
+            } finally {
+                restoreCallingIdentity(id);
+            }
+
+            if (enabledServices != null) {
+                List<String> enabledPackages = new ArrayList<String>();
+                for (AccessibilityServiceInfo service : enabledServices) {
+                    enabledPackages.add(service.getResolveInfo().serviceInfo.packageName);
+                }
+                if (!checkPackagesInPermittedListOrSystem(enabledPackages, packageList)) {
+                    Slog.e(LOG_TAG, "Cannot set permitted accessibility services, "
+                            + "because it contains already enabled accesibility services.");
+                    return false;
+                }
+            }
+        }
+
+        synchronized (this) {
+            ActiveAdmin admin = getActiveAdminForCallerLocked(who,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            admin.permittedAccessiblityServices = packageList;
+            saveSettingsLocked(UserHandle.getCallingUserId());
+        }
+        return true;
+    }
+
+    @Override
+    public List getPermittedAccessibilityServices(ComponentName who) {
+        if (!mHasFeature) {
+            return null;
+        }
+
+        if (who == null) {
+            throw new NullPointerException("ComponentName is null");
+        }
+
+        synchronized (this) {
+            ActiveAdmin admin = getActiveAdminForCallerLocked(who,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            return admin.permittedAccessiblityServices;
+        }
+    }
+
+    @Override
+    public List getPermittedAccessibilityServicesForUser(int userId) {
+        if (!mHasFeature) {
+            return null;
+        }
+        synchronized (this) {
+            List<String> result = null;
+            // If we have multiple profiles we return the intersection of the
+            // permitted lists. This can happen in cases where we have a device
+            // and profile owner.
+            List<UserInfo> profiles = mUserManager.getProfiles(userId);
+            final int PROFILES_SIZE = profiles.size();
+            for (int i = 0; i < PROFILES_SIZE; ++i) {
+                // Just loop though all admins, only device or profiles
+                // owners can have permitted lists set.
+                DevicePolicyData policy = getUserData(profiles.get(i).id);
+                final int N = policy.mAdminList.size();
+                for (int j = 0; j < N; j++) {
+                    ActiveAdmin admin = policy.mAdminList.get(j);
+                    List<String> fromAdmin = admin.permittedAccessiblityServices;
+                    if (fromAdmin != null) {
+                        if (result == null) {
+                            result = new ArrayList<String>(fromAdmin);
+                        } else {
+                            result.retainAll(fromAdmin);
+                        }
+                    }
+                }
+            }
+
+            // If we have a permitted list add all system accessibility services.
+            if (result != null) {
+                long id = Binder.clearCallingIdentity();
+                try {
+                    UserInfo user = mUserManager.getUserInfo(userId);
+                    if (user.isManagedProfile()) {
+                        userId = user.profileGroupId;
+                    }
+                    AccessibilityManager accessibilityManager =
+                            getAccessibilityManagerForUser(userId);
+                    List<AccessibilityServiceInfo> installedServices =
+                            accessibilityManager.getInstalledAccessibilityServiceList();
+
+                    IPackageManager pm = AppGlobals.getPackageManager();
+                    if (installedServices != null) {
+                        for (AccessibilityServiceInfo service : installedServices) {
+                            String packageName = service.getResolveInfo().serviceInfo.packageName;
+                            try {
+                                ApplicationInfo applicationInfo = pm.getApplicationInfo(packageName,
+                                        PackageManager.GET_UNINSTALLED_PACKAGES, userId);
+                                if ((applicationInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0) {
+                                    result.add(packageName);
+                                }
+                            } catch (RemoteException e) {
+                                Log.i(LOG_TAG, "Accessibility service in missing package", e);
+                            }
+                        }
+                    }
+                } finally {
+                    restoreCallingIdentity(id);
+                }
+            }
+
+            return result;
+        }
+    }
+
+    private boolean checkCallerIsCurrentUserOrProfile() {
+        int callingUserId = UserHandle.getCallingUserId();
+        long token = Binder.clearCallingIdentity();
+        try {
+            UserInfo currentUser;
+            UserInfo callingUser = mUserManager.getUserInfo(callingUserId);
+            try {
+                currentUser = ActivityManagerNative.getDefault().getCurrentUser();
+            } catch (RemoteException e) {
+                Slog.e(LOG_TAG, "Failed to talk to activity managed.", e);
+                return false;
+            }
+
+            if (callingUser.isManagedProfile() && callingUser.profileGroupId != currentUser.id) {
+                Slog.e(LOG_TAG, "Cannot set permitted input methods for managed profile "
+                        + "of a user that isn't the foreground user.");
+                return false;
+            }
+            if (!callingUser.isManagedProfile() && callingUserId != currentUser.id ) {
+                Slog.e(LOG_TAG, "Cannot set permitted input methods "
+                        + "of a user that isn't the foreground user.");
+                return false;
+            }
+        } finally {
+            Binder.restoreCallingIdentity(token);
+        }
+        return true;
+    }
+
+    @Override
+    public boolean setPermittedInputMethods(ComponentName who, List packageList) {
+        if (!mHasFeature) {
+            return false;
+        }
+        if (who == null) {
+            throw new NullPointerException("ComponentName is null");
+        }
+
+        // TODO When InputMethodManager supports per user calls remove
+        //      this restriction.
+        if (!checkCallerIsCurrentUserOrProfile()) {
+            return false;
+        }
+
+        if (packageList != null) {
+            // InputMethodManager fetches input methods for current user.
+            // So this can only be set when calling user is the current user
+            // or parent is current user in case of managed profiles.
+            InputMethodManager inputMethodManager = (InputMethodManager) mContext
+                    .getSystemService(Context.INPUT_METHOD_SERVICE);
+            List<InputMethodInfo> enabledImes = inputMethodManager.getEnabledInputMethodList();
+
+            if (enabledImes != null) {
+                List<String> enabledPackages = new ArrayList<String>();
+                for (InputMethodInfo ime : enabledImes) {
+                    enabledPackages.add(ime.getPackageName());
+                }
+                if (!checkPackagesInPermittedListOrSystem(enabledPackages, packageList)) {
+                    Slog.e(LOG_TAG, "Cannot set permitted input methods, "
+                            + "because it contains already enabled input method.");
+                    return false;
+                }
+            }
+        }
+
+        synchronized (this) {
+            ActiveAdmin admin = getActiveAdminForCallerLocked(who,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            admin.permittedInputMethods = packageList;
+            saveSettingsLocked(UserHandle.getCallingUserId());
+        }
+        return true;
+    }
+
+    @Override
+    public List getPermittedInputMethods(ComponentName who) {
+        if (!mHasFeature) {
+            return null;
+        }
+
+        if (who == null) {
+            throw new NullPointerException("ComponentName is null");
+        }
+
+        synchronized (this) {
+            ActiveAdmin admin = getActiveAdminForCallerLocked(who,
+                    DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            return admin.permittedInputMethods;
+        }
+    }
+
+    @Override
+    public List getPermittedInputMethodsForCurrentUser() {
+        UserInfo currentUser;
+        try {
+            currentUser = ActivityManagerNative.getDefault().getCurrentUser();
+        } catch (RemoteException e) {
+            Slog.e(LOG_TAG, "Failed to make remote calls to get current user", e);
+            // Activity managed is dead, just allow all IMEs
+            return null;
+        }
+
+        int userId = currentUser.id;
+        synchronized (this) {
+            List<String> result = null;
+            // If we have multiple profiles we return the intersection of the
+            // permitted lists. This can happen in cases where we have a device
+            // and profile owner.
+            List<UserInfo> profiles = mUserManager.getProfiles(userId);
+            final int PROFILES_SIZE = profiles.size();
+            for (int i = 0; i < PROFILES_SIZE; ++i) {
+                // Just loop though all admins, only device or profiles
+                // owners can have permitted lists set.
+                DevicePolicyData policy = getUserData(profiles.get(i).id);
+                final int N = policy.mAdminList.size();
+                for (int j = 0; j < N; j++) {
+                    ActiveAdmin admin = policy.mAdminList.get(j);
+                    List<String> fromAdmin = admin.permittedInputMethods;
+                    if (fromAdmin != null) {
+                        if (result == null) {
+                            result = new ArrayList<String>(fromAdmin);
+                        } else {
+                            result.retainAll(fromAdmin);
+                        }
+                    }
+                }
+            }
+
+            // If we have a permitted list add all system input methods.
+            if (result != null) {
+                InputMethodManager inputMethodManager = (InputMethodManager) mContext
+                        .getSystemService(Context.INPUT_METHOD_SERVICE);
+                List<InputMethodInfo> imes = inputMethodManager.getInputMethodList();
+                long id = Binder.clearCallingIdentity();
+                try {
+                    IPackageManager pm = AppGlobals.getPackageManager();
+                    if (imes != null) {
+                        for (InputMethodInfo ime : imes) {
+                            String packageName = ime.getPackageName();
+                            try {
+                                ApplicationInfo applicationInfo = pm.getApplicationInfo(
+                                        packageName, PackageManager.GET_UNINSTALLED_PACKAGES,
+                                        userId);
+                                if ((applicationInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0) {
+                                    result.add(packageName);
+                                }
+                            } catch (RemoteException e) {
+                                Log.i(LOG_TAG, "Input method for missing package", e);
+                            }
+                        }
+                    }
+                } finally {
+                    restoreCallingIdentity(id);
+                }
+            }
+            return result;
+        }
+    }
+
     @Override
     public UserHandle createUser(ComponentName who, String name) {
         synchronized (this) {
@@ -4038,25 +4652,45 @@
 
     @Override
     public void setUserRestriction(ComponentName who, String key, boolean enabled) {
-        final UserHandle userHandle = new UserHandle(UserHandle.getCallingUserId());
-
+        final UserHandle user = new UserHandle(UserHandle.getCallingUserId());
+        final int userHandle = user.getIdentifier();
         synchronized (this) {
             if (who == null) {
                 throw new NullPointerException("ComponentName is null");
             }
-            getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            ActiveAdmin activeAdmin =
+                    getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            boolean isDeviceOwner = isDeviceOwner(activeAdmin.info.getPackageName());
+            if (!isDeviceOwner && DEVICE_OWNER_USER_RESTRICTIONS.contains(key)) {
+                throw new SecurityException("Profile owners cannot set user restriction " + key);
+            }
+            boolean alreadyRestricted = mUserManager.hasUserRestriction(key, user);
 
+            IAudioService iAudioService = null;
+            if (UserManager.DISALLOW_UNMUTE_MICROPHONE.equals(key)
+                    || UserManager.DISALLOW_ADJUST_VOLUME.equals(key)) {
+                iAudioService = IAudioService.Stub.asInterface(
+                        ServiceManager.getService(Context.AUDIO_SERVICE));
+            }
+
+            if (enabled && !alreadyRestricted) {
+                try {
+                    if (UserManager.DISALLOW_UNMUTE_MICROPHONE.equals(key)) {
+                        iAudioService.setMicrophoneMute(true, who.getPackageName());
+                    } else if (UserManager.DISALLOW_ADJUST_VOLUME.equals(key)) {
+                        iAudioService.setMasterMute(true, 0, who.getPackageName(), null);
+                    }
+                } catch (RemoteException re) {
+                    Slog.e(LOG_TAG, "Failed to talk to AudioService.", re);
+                }
+            }
             long id = Binder.clearCallingIdentity();
             try {
-                AudioManager audioManager =
-                        (AudioManager) mContext.getSystemService(Context.AUDIO_SERVICE);
-                boolean alreadyRestricted = mUserManager.hasUserRestriction(key);
-
                 if (enabled && !alreadyRestricted) {
                     if (UserManager.DISALLOW_CONFIG_WIFI.equals(key)) {
                         Settings.Secure.putIntForUser(mContext.getContentResolver(),
                                 Settings.Secure.WIFI_NETWORKS_AVAILABLE_NOTIFICATION_ON, 0,
-                                userHandle.getIdentifier());
+                                userHandle);
                     } else if (UserManager.DISALLOW_USB_FILE_TRANSFER.equals(key)) {
                         UsbManager manager =
                                 (UsbManager) mContext.getSystemService(Context.USB_SERVICE);
@@ -4064,44 +4698,44 @@
                     } else if (UserManager.DISALLOW_SHARE_LOCATION.equals(key)) {
                         Settings.Secure.putIntForUser(mContext.getContentResolver(),
                                 Settings.Secure.LOCATION_MODE, Settings.Secure.LOCATION_MODE_OFF,
-                                userHandle.getIdentifier());
+                                userHandle);
                         Settings.Secure.putStringForUser(mContext.getContentResolver(),
                                 Settings.Secure.LOCATION_PROVIDERS_ALLOWED, "",
-                                userHandle.getIdentifier());
+                                userHandle);
                     } else if (UserManager.DISALLOW_DEBUGGING_FEATURES.equals(key)) {
-                        Settings.Global.putStringForUser(mContext.getContentResolver(),
-                                Settings.Global.ADB_ENABLED, "0", userHandle.getIdentifier());
+                        // Only disable adb if changing for primary user, since it is global
+                        if (userHandle == UserHandle.USER_OWNER) {
+                            Settings.Global.putStringForUser(mContext.getContentResolver(),
+                                    Settings.Global.ADB_ENABLED, "0", userHandle);
+                        }
                     } else if (UserManager.ENSURE_VERIFY_APPS.equals(key)) {
                         Settings.Global.putStringForUser(mContext.getContentResolver(),
                                 Settings.Global.PACKAGE_VERIFIER_ENABLE, "1",
-                                userHandle.getIdentifier());
+                                userHandle);
                         Settings.Global.putStringForUser(mContext.getContentResolver(),
                                 Settings.Global.PACKAGE_VERIFIER_INCLUDE_ADB, "1",
-                                userHandle.getIdentifier());
+                                userHandle);
                     } else if (UserManager.DISALLOW_INSTALL_UNKNOWN_SOURCES.equals(key)) {
                         Settings.Secure.putIntForUser(mContext.getContentResolver(),
                                 Settings.Secure.INSTALL_NON_MARKET_APPS, 0,
-                                userHandle.getIdentifier());
-                    } else if (UserManager.DISALLOW_UNMUTE_MICROPHONE.equals(key)) {
-                        audioManager.setMicrophoneMute(true);
-                    } else if (UserManager.DISALLOW_ADJUST_VOLUME.equals(key)) {
-                        audioManager.setMasterMute(true);
+                                userHandle);
                     }
                 }
-
-                mUserManager.setUserRestriction(key, enabled, userHandle);
-
-                if (!enabled && alreadyRestricted) {
-                    if (UserManager.DISALLOW_UNMUTE_MICROPHONE.equals(key)) {
-                        audioManager.setMicrophoneMute(false);
-                    } else if (UserManager.DISALLOW_ADJUST_VOLUME.equals(key)) {
-                        audioManager.setMasterMute(false);
-                    }
-                }
-
+                mUserManager.setUserRestriction(key, enabled, user);
             } finally {
                 restoreCallingIdentity(id);
             }
+            if (!enabled && alreadyRestricted) {
+                try {
+                    if (UserManager.DISALLOW_UNMUTE_MICROPHONE.equals(key)) {
+                        iAudioService.setMicrophoneMute(false, who.getPackageName());
+                    } else if (UserManager.DISALLOW_ADJUST_VOLUME.equals(key)) {
+                        iAudioService.setMasterMute(false, 0, who.getPackageName(), null);
+                    }
+                } catch (RemoteException re) {
+                    Slog.e(LOG_TAG, "Failed to talk to AudioService.", re);
+                }
+            }
         }
     }
 
@@ -4130,46 +4764,6 @@
     }
 
     @Override
-    public int setApplicationsHidden(ComponentName who, Intent intent, boolean hidden) {
-        int callingUserId = UserHandle.getCallingUserId();
-        synchronized (this) {
-            if (who == null) {
-                throw new NullPointerException("ComponentName is null");
-            }
-            getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
-
-            long id = Binder.clearCallingIdentity();
-            try {
-                IPackageManager pm = AppGlobals.getPackageManager();
-                List<ResolveInfo> activitiesToEnable = pm.queryIntentActivities(intent,
-                        intent.resolveTypeIfNeeded(mContext.getContentResolver()),
-                        PackageManager.GET_DISABLED_COMPONENTS
-                                | PackageManager.GET_UNINSTALLED_PACKAGES,
-                        callingUserId);
-
-                if (DBG) Slog.d(LOG_TAG, "Enabling activities: " + activitiesToEnable);
-                int numberOfAppsUnhidden = 0;
-                if (activitiesToEnable != null) {
-                    for (ResolveInfo info : activitiesToEnable) {
-                        if (info.activityInfo != null) {
-                            numberOfAppsUnhidden++;
-                            pm.setApplicationHiddenSettingAsUser(info.activityInfo.packageName,
-                                    hidden, callingUserId);
-                        }
-                    }
-                }
-                return numberOfAppsUnhidden;
-            } catch (RemoteException re) {
-                // shouldn't happen
-                Slog.e(LOG_TAG, "Failed to setApplicationsHiddenSettingsWithIntent", re);
-            } finally {
-                restoreCallingIdentity(id);
-            }
-            return 0;
-        }
-    }
-
-    @Override
     public boolean isApplicationHidden(ComponentName who, String packageName) {
         int callingUserId = UserHandle.getCallingUserId();
         synchronized (this) {
@@ -4345,7 +4939,8 @@
     }
 
     @Override
-    public void setBlockUninstall(ComponentName who, String packageName, boolean blockUninstall) {
+    public void setUninstallBlocked(ComponentName who, String packageName,
+            boolean uninstallBlocked) {
         final int userId = UserHandle.getCallingUserId();
 
         synchronized (this) {
@@ -4357,7 +4952,7 @@
             long id = Binder.clearCallingIdentity();
             try {
                 IPackageManager pm = AppGlobals.getPackageManager();
-                pm.setBlockUninstallForUser(packageName, blockUninstall, userId);
+                pm.setBlockUninstallForUser(packageName, uninstallBlocked, userId);
             } catch (RemoteException re) {
                 // Shouldn't happen.
                 Slog.e(LOG_TAG, "Failed to setBlockUninstallForUser", re);
@@ -4368,7 +4963,7 @@
     }
 
     @Override
-    public boolean getBlockUninstall(ComponentName who, String packageName) {
+    public boolean isUninstallBlocked(ComponentName who, String packageName) {
         final int userId = UserHandle.getCallingUserId();
 
         synchronized (this) {
@@ -4539,6 +5134,11 @@
             }
             getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_DEVICE_OWNER);
 
+            if (!GLOBAL_SETTINGS_WHITELIST.contains(setting)) {
+                throw new SecurityException(String.format(
+                        "Permission denial: device owners cannot update %1$s", setting));
+            }
+
             long id = Binder.clearCallingIdentity();
             try {
                 Settings.Global.putString(contentResolver, setting, value);
@@ -4557,7 +5157,18 @@
             if (who == null) {
                 throw new NullPointerException("ComponentName is null");
             }
-            getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+            ActiveAdmin activeAdmin =
+                    getActiveAdminForCallerLocked(who, DeviceAdminInfo.USES_POLICY_PROFILE_OWNER);
+
+            if (isDeviceOwner(activeAdmin.info.getPackageName())) {
+                if (!SECURE_SETTINGS_DEVICEOWNER_WHITELIST.contains(setting)) {
+                    throw new SecurityException(String.format(
+                            "Permission denial: Device owners cannot update %1$s", setting));
+                }
+            } else if (!SECURE_SETTINGS_WHITELIST.contains(setting)) {
+                throw new SecurityException(String.format(
+                        "Permission denial: Profile owners cannot update %1$s", setting));
+            }
 
             long id = Binder.clearCallingIdentity();
             try {
@@ -4653,26 +5264,51 @@
     }
 
     private final class LocalService extends DevicePolicyManagerInternal {
+        private List<OnCrossProfileWidgetProvidersChangeListener> mWidgetProviderListeners;
+
         @Override
         public List<String> getCrossProfileWidgetProviders(int profileId) {
-            ComponentName ownerComponent = mDeviceOwner.getProfileOwnerComponent(profileId);
-            if (ownerComponent == null) {
-                return Collections.emptyList();
+            synchronized (DevicePolicyManagerService.this) {
+                ComponentName ownerComponent = mDeviceOwner.getProfileOwnerComponent(profileId);
+                if (ownerComponent == null) {
+                    return Collections.emptyList();
+                }
+
+                DevicePolicyData policy = getUserData(profileId);
+                ActiveAdmin admin = policy.mAdminMap.get(ownerComponent);
+
+                if (admin == null || admin.crossProfileWidgetProviders == null
+                        || admin.crossProfileWidgetProviders.isEmpty()) {
+                    return Collections.emptyList();
+                }
+
+                return admin.crossProfileWidgetProviders;
             }
+        }
 
-            DevicePolicyData policy = getUserData(profileId);
-            ActiveAdmin admin = policy.mAdminMap.get(ownerComponent);
-
-            if (admin == null) {
-                return Collections.emptyList();
+        @Override
+        public void addOnCrossProfileWidgetProvidersChangeListener(
+                OnCrossProfileWidgetProvidersChangeListener listener) {
+            synchronized (DevicePolicyManagerService.this) {
+                if (mWidgetProviderListeners == null) {
+                    mWidgetProviderListeners = new ArrayList<>();
+                }
+                if (!mWidgetProviderListeners.contains(listener)) {
+                    mWidgetProviderListeners.add(listener);
+                }
             }
+        }
 
-            if (admin.crossProfileWidgetProviders == null
-                    || admin.crossProfileWidgetProviders.isEmpty()) {
-                return Collections.emptyList();
+        private void notifyCrossProfileProvidersChanged(int userId, List<String> packages) {
+            final List<OnCrossProfileWidgetProvidersChangeListener> listeners;
+            synchronized (DevicePolicyManagerService.this) {
+                listeners = new ArrayList<>(mWidgetProviderListeners);
             }
-
-            return admin.crossProfileWidgetProviders;
+            final int listenerCount = listeners.size();
+            for (int i = 0; i < listenerCount; i++) {
+                OnCrossProfileWidgetProvidersChangeListener listener = listeners.get(i);
+                listener.onCrossProfileWidgetProvidersChanged(userId, packages);
+            }
         }
     }
 }
diff --git a/services/java/com/android/server/SystemServer.java b/services/java/com/android/server/SystemServer.java
index a3c10fd..f339dba 100644
--- a/services/java/com/android/server/SystemServer.java
+++ b/services/java/com/android/server/SystemServer.java
@@ -132,8 +132,6 @@
             "com.android.server.usb.UsbService$Lifecycle";
     private static final String WIFI_SERVICE_CLASS =
             "com.android.server.wifi.WifiService";
-    private static final String WIFI_PASSPOINT_SERVICE_CLASS =
-            "com.android.server.wifi.passpoint.WifiPasspointService";
     private static final String WIFI_P2P_SERVICE_CLASS =
             "com.android.server.wifi.p2p.WifiP2pService";
     private static final String ETHERNET_SERVICE_CLASS =
@@ -665,7 +663,6 @@
                 }
 
                 mSystemServiceManager.startService(WIFI_P2P_SERVICE_CLASS);
-                mSystemServiceManager.startService(WIFI_PASSPOINT_SERVICE_CLASS);
                 mSystemServiceManager.startService(WIFI_SERVICE_CLASS);
                 mSystemServiceManager.startService(
                             "com.android.server.wifi.WifiScanningService");
@@ -921,7 +918,7 @@
                 mSystemServiceManager.startService(HdmiControlService.class);
             }
 
-            if (mPackageManager.hasSystemFeature(PackageManager.FEATURE_LEANBACK)) {
+            if (mPackageManager.hasSystemFeature(PackageManager.FEATURE_LIVE_TV)) {
                 mSystemServiceManager.startService(TvInputManagerService.class);
             }
 
diff --git a/services/print/java/com/android/server/print/PrintManagerService.java b/services/print/java/com/android/server/print/PrintManagerService.java
index 7400dde..6785cb8 100644
--- a/services/print/java/com/android/server/print/PrintManagerService.java
+++ b/services/print/java/com/android/server/print/PrintManagerService.java
@@ -17,15 +17,16 @@
 package com.android.server.print;
 
 import android.Manifest;
+import android.app.ActivityManager;
+import android.app.ActivityManagerNative;
 import android.app.Notification;
 import android.app.NotificationManager;
 import android.app.PendingIntent;
-import android.content.BroadcastReceiver;
 import android.content.ComponentName;
 import android.content.Context;
 import android.content.Intent;
-import android.content.IntentFilter;
 import android.content.pm.PackageManager;
+import android.content.pm.PackageManager.NameNotFoundException;
 import android.content.pm.ResolveInfo;
 import android.content.pm.ServiceInfo;
 import android.content.pm.UserInfo;
@@ -81,10 +82,13 @@
     }
 
     @Override
-    public void onBootPhase(int phase) {
-        if (phase == PHASE_THIRD_PARTY_APPS_CAN_START) {
-            mPrintManagerImpl.systemRunning();
-        }
+    public void onStartUser(int userHandle) {
+        mPrintManagerImpl.handleUserStarted(userHandle);
+    }
+
+    @Override
+    public void onStopUser(int userHandle) {
+        mPrintManagerImpl.handleUserStopped(userHandle);
     }
 
     class PrintManagerImpl extends IPrintManager.Stub {
@@ -101,9 +105,7 @@
 
         private final UserManager mUserManager;
 
-        private final SparseArray<UserState> mUserStates = new SparseArray<UserState>();
-
-        private int mCurrentUserId = UserHandle.USER_OWNER;
+        private final SparseArray<UserState> mUserStates = new SparseArray<>();
 
         PrintManagerImpl(Context context) {
             mContext = context;
@@ -112,22 +114,6 @@
             registerBroadcastReceivers();
         }
 
-        public void systemRunning() {
-            BackgroundThread.getHandler().post(new Runnable() {
-                @Override
-                public void run() {
-                    final UserState userState;
-                    synchronized (mLock) {
-                        userState = getCurrentUserStateLocked();
-                    }
-                    // This is the first time we switch to this user after boot, so
-                    // now is the time to remove obsolete print jobs since they
-                    // are from the last boot and no application would query them.
-                    userState.removeObsoletePrintJobs();
-                }
-            });
-        }
-
         @Override
         public Bundle print(String printJobName, IPrintDocumentAdapter adapter,
                 PrintAttributes attributes, String packageName, int appId, int userId) {
@@ -137,7 +123,7 @@
             final String resolvedPackageName;
             synchronized (mLock) {
                 // Only the current group members can start new print jobs.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return null;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -160,7 +146,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can query for state of print jobs.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return null;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -181,7 +167,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can query for state of a print job.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return null;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -202,7 +188,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can cancel a print job.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -223,7 +209,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can restart a print job.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -243,7 +229,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can get enabled services.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return null;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -262,7 +248,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can get installed services.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return null;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -282,7 +268,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can create a discovery session.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -302,7 +288,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can destroy a discovery session.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -322,7 +308,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can start discovery.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -341,7 +327,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can stop discovery.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -360,7 +346,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can validate printers.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -379,7 +365,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can start printer tracking.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -398,7 +384,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can stop printer tracking.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -419,7 +405,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can add a print job listener.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 resolvedAppId = resolveCallingAppEnforcingPermissions(appId);
@@ -440,7 +426,7 @@
             final UserState userState;
             synchronized (mLock) {
                 // Only the current group members can remove a print job listener.
-                if (resolveCallingProfileParentLocked(resolvedUserId) != mCurrentUserId) {
+                if (resolveCallingProfileParentLocked(resolvedUserId) != getCurrentUserId()) {
                     return;
                 }
                 userState = getOrCreateUserStateLocked(resolvedUserId);
@@ -484,11 +470,19 @@
                     Settings.Secure.ENABLED_PRINT_SERVICES);
             ContentObserver observer = new ContentObserver(BackgroundThread.getHandler()) {
                 @Override
-                public void onChange(boolean selfChange, Uri uri) {
+                public void onChange(boolean selfChange, Uri uri, int userId) {
                     if (enabledPrintServicesUri.equals(uri)) {
                         synchronized (mLock) {
-                            UserState userState = getCurrentUserStateLocked();
-                            userState.updateIfNeededLocked();
+                            if (userId != UserHandle.USER_ALL) {
+                                UserState userState = getOrCreateUserStateLocked(userId);
+                                userState.updateIfNeededLocked();
+                            } else {
+                                final int userCount = mUserStates.size();
+                                for (int i = 0; i < userCount; i++) {
+                                    UserState userState = mUserStates.valueAt(i);
+                                    userState.updateIfNeededLocked();
+                                }
+                            }
                         }
                     }
                 }
@@ -622,27 +616,6 @@
             // package changes
             monitor.register(mContext, BackgroundThread.getHandler().getLooper(),
                     UserHandle.ALL, true);
-
-            // user changes
-            IntentFilter intentFilter = new IntentFilter();
-            intentFilter.addAction(Intent.ACTION_USER_SWITCHED);
-            intentFilter.addAction(Intent.ACTION_USER_REMOVED);
-
-            mContext.registerReceiverAsUser(new BroadcastReceiver() {
-                @Override
-                public void onReceive(Context context, Intent intent) {
-                    String action = intent.getAction();
-                    if (Intent.ACTION_USER_SWITCHED.equals(action)) {
-                        switchUser(intent.getIntExtra(Intent.EXTRA_USER_HANDLE, 0));
-                    } else if (Intent.ACTION_USER_REMOVED.equals(action)) {
-                        removeUser(intent.getIntExtra(Intent.EXTRA_USER_HANDLE, 0));
-                    }
-                }
-            }, UserHandle.ALL, intentFilter, null, BackgroundThread.getHandler());
-        }
-
-        private UserState getCurrentUserStateLocked() {
-            return getOrCreateUserStateLocked(mCurrentUserId);
         }
 
         private UserState getOrCreateUserStateLocked(int userId) {
@@ -654,39 +627,44 @@
             return userState;
         }
 
-        private void switchUser(int newUserId) {
-            UserState userState;
-            synchronized (mLock) {
-                if (newUserId == mCurrentUserId) {
-                    return;
+        private void handleUserStarted(final int userId) {
+            // This code will touch the remote print spooler which
+            // must be called off the main thread, so post the work.
+            BackgroundThread.getHandler().post(new Runnable() {
+                @Override
+                public void run() {
+                    UserState userState;
+                    synchronized (mLock) {
+                        userState = getOrCreateUserStateLocked(userId);
+                        userState.updateIfNeededLocked();
+                    }
+                    // This is the first time we switch to this user after boot, so
+                    // now is the time to remove obsolete print jobs since they
+                    // are from the last boot and no application would query them.
+                    userState.removeObsoletePrintJobs();
                 }
-                mCurrentUserId = newUserId;
-                userState = mUserStates.get(mCurrentUserId);
-                if (userState == null) {
-                    userState = getCurrentUserStateLocked();
-                    userState.updateIfNeededLocked();
-                } else {
-                    userState.updateIfNeededLocked();
-                }
-            }
-            // This is the first time we switch to this user after boot, so
-            // now is the time to remove obsolete print jobs since they
-            // are from the last boot and no application would query them.
-            userState.removeObsoletePrintJobs();
+            });
         }
 
-        private void removeUser(int removedUserId) {
-            synchronized (mLock) {
-                UserState userState = mUserStates.get(removedUserId);
-                if (userState != null) {
-                    userState.destroyLocked();
-                    mUserStates.remove(removedUserId);
+        private void handleUserStopped(final int userId) {
+            // This code will touch the remote print spooler which
+            // must be called off the main thread, so post the work.
+            BackgroundThread.getHandler().post(new Runnable() {
+                @Override
+                public void run() {
+                    synchronized (mLock) {
+                        UserState userState = mUserStates.get(userId);
+                        if (userState != null) {
+                            userState.destroyLocked();
+                            mUserStates.remove(userId);
+                        }
+                    }
                 }
-            }
+            });
         }
 
         private int resolveCallingProfileParentLocked(int userId) {
-            if (userId != mCurrentUserId) {
+            if (userId != getCurrentUserId()) {
                 final long identity = Binder.clearCallingIdentity();
                 try {
                     UserInfo parent = mUserManager.getProfileParent(userId);
@@ -723,28 +701,11 @@
         }
 
         private int resolveCallingUserEnforcingPermissions(int userId) {
-            final int callingUid = Binder.getCallingUid();
-            if (callingUid == 0 || callingUid == Process.SYSTEM_UID
-                    || callingUid == Process.SHELL_UID) {
-                return userId;
-            }
-            final int callingUserId = UserHandle.getUserId(callingUid);
-            if (callingUserId == userId) {
-                return userId;
-            }
-            if (mContext.checkCallingPermission(Manifest.permission.INTERACT_ACROSS_USERS_FULL)
-                    != PackageManager.PERMISSION_GRANTED
-                &&  mContext.checkCallingPermission(Manifest.permission.INTERACT_ACROSS_USERS)
-                    != PackageManager.PERMISSION_GRANTED) {
-                if (userId == UserHandle.USER_CURRENT_OR_SELF) {
-                    return callingUserId;
-                }
-                throw new SecurityException("Call from user " + callingUserId + " as user "
-                    + userId + " without permission INTERACT_ACROSS_USERS or "
-                    + "INTERACT_ACROSS_USERS_FULL not allowed.");
-            }
-            if (userId == UserHandle.USER_CURRENT || userId == UserHandle.USER_CURRENT_OR_SELF) {
-                return mCurrentUserId;
+            try {
+                return ActivityManagerNative.getDefault().handleIncomingUser(Binder.getCallingPid(),
+                        Binder.getCallingUid(), userId, true, true, "", null);
+            } catch (RemoteException re) {
+                // Shouldn't happen, local.
             }
             return userId;
         }
@@ -764,6 +725,15 @@
             return null;
         }
 
+        private int getCurrentUserId () {
+            final long identity = Binder.clearCallingIdentity();
+            try {
+                return ActivityManager.getCurrentUser();
+            } finally {
+                Binder.restoreCallingIdentity(identity);
+            }
+        }
+
         private void showEnableInstalledPrintServiceNotification(ComponentName component,
                 String label, int userId) {
             UserHandle userHandle = new UserHandle(userId);
@@ -775,7 +745,14 @@
                     PendingIntent.FLAG_ONE_SHOT | PendingIntent.FLAG_CANCEL_CURRENT, null,
                     userHandle);
 
-            Notification.Builder builder = new Notification.Builder(mContext)
+            Context builderContext = mContext;
+            try {
+                builderContext = mContext.createPackageContextAsUser(mContext.getPackageName(), 0,
+                        userHandle);
+            } catch (NameNotFoundException e) {
+                // Ignore can't find the package the system is running as.
+            }
+            Notification.Builder builder = new Notification.Builder(builderContext)
                     .setSmallIcon(R.drawable.ic_print)
                     .setContentTitle(mContext.getString(R.string.print_service_installed_title,
                             label))
@@ -783,7 +760,9 @@
                     .setContentIntent(pendingIntent)
                     .setWhen(System.currentTimeMillis())
                     .setAutoCancel(true)
-                    .setShowWhen(true);
+                    .setShowWhen(true)
+                    .setColor(mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color));
 
             NotificationManager notificationManager = (NotificationManager) mContext
                     .getSystemService(Context.NOTIFICATION_SERVICE);
diff --git a/services/restrictions/java/com/android/server/restrictions/RestrictionsManagerService.java b/services/restrictions/java/com/android/server/restrictions/RestrictionsManagerService.java
index fb29b6a..218f899 100644
--- a/services/restrictions/java/com/android/server/restrictions/RestrictionsManagerService.java
+++ b/services/restrictions/java/com/android/server/restrictions/RestrictionsManagerService.java
@@ -139,7 +139,7 @@
         }
 
         @Override
-        public Intent getLocalApprovalIntent() throws RemoteException {
+        public Intent createLocalApprovalIntent() throws RemoteException {
             if (DEBUG) {
                 Log.i(LOG_TAG, "requestPermission");
             }
diff --git a/services/tests/servicestests/Android.mk b/services/tests/servicestests/Android.mk
index 4ff3899..f25fc62 100644
--- a/services/tests/servicestests/Android.mk
+++ b/services/tests/servicestests/Android.mk
@@ -8,11 +8,13 @@
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
 
 LOCAL_STATIC_JAVA_LIBRARIES := \
+    services.core \
+    services.devicepolicy \
     easymocklib \
     guava \
     mockito-target
 
-LOCAL_JAVA_LIBRARIES := android.test.runner services
+LOCAL_JAVA_LIBRARIES := android.test.runner
 
 LOCAL_PACKAGE_NAME := FrameworksServicesTests
 
diff --git a/services/tests/servicestests/src/com/android/server/job/JobStoreTest.java b/services/tests/servicestests/src/com/android/server/job/JobStoreTest.java
index 2b693a3..402f0dd 100644
--- a/services/tests/servicestests/src/com/android/server/job/JobStoreTest.java
+++ b/services/tests/servicestests/src/com/android/server/job/JobStoreTest.java
@@ -51,11 +51,11 @@
 
         final JobInfo task = new Builder(taskId, mComponent)
                 .setRequiresCharging(true)
-                .setRequiredNetworkCapabilities(JobInfo.NetworkType.ANY)
-                .setBackoffCriteria(initialBackoff, JobInfo.BackoffPolicy.EXPONENTIAL)
+                .setRequiredNetworkType(JobInfo.NETWORK_TYPE_ANY)
+                .setBackoffCriteria(initialBackoff, JobInfo.BACKOFF_POLICY_EXPONENTIAL)
                 .setOverrideDeadline(runByMillis)
                 .setMinimumLatency(runFromMillis)
-                .setIsPersisted(true)
+                .setPersisted(true)
                 .build();
         final JobStatus ts = new JobStatus(task, SOME_UID);
         mTaskStoreUnderTest.add(ts);
@@ -80,14 +80,14 @@
                 .setRequiresDeviceIdle(true)
                 .setPeriodic(10000L)
                 .setRequiresCharging(true)
-                .setIsPersisted(true)
+                .setPersisted(true)
                 .build();
         final JobInfo task2 = new Builder(12, mComponent)
                 .setMinimumLatency(5000L)
-                .setBackoffCriteria(15000L, JobInfo.BackoffPolicy.LINEAR)
+                .setBackoffCriteria(15000L, JobInfo.BACKOFF_POLICY_LINEAR)
                 .setOverrideDeadline(30000L)
-                .setRequiredNetworkCapabilities(JobInfo.NetworkType.UNMETERED)
-                .setIsPersisted(true)
+                .setRequiredNetworkType(JobInfo.NETWORK_TYPE_UNMETERED)
+                .setPersisted(true)
                 .build();
         final JobStatus taskStatus1 = new JobStatus(task1, SOME_UID);
         final JobStatus taskStatus2 = new JobStatus(task2, SOME_UID);
@@ -121,7 +121,7 @@
                 .setRequiresDeviceIdle(true)
                 .setPeriodic(10000L)
                 .setRequiresCharging(true)
-                .setIsPersisted(true);
+                .setPersisted(true);
 
         PersistableBundle extras = new PersistableBundle();
         extras.putDouble("hello", 3.2);
@@ -159,11 +159,11 @@
         assertEquals("Invalid idle constraint.", first.isRequireDeviceIdle(),
                 second.isRequireDeviceIdle());
         assertEquals("Invalid unmetered constraint.",
-                first.getNetworkCapabilities() == JobInfo.NetworkType.UNMETERED,
-                second.getNetworkCapabilities() == JobInfo.NetworkType.UNMETERED);
+                first.getNetworkType() == JobInfo.NETWORK_TYPE_UNMETERED,
+                second.getNetworkType() == JobInfo.NETWORK_TYPE_UNMETERED);
         assertEquals("Invalid connectivity constraint.",
-                first.getNetworkCapabilities() == JobInfo.NetworkType.ANY,
-                second.getNetworkCapabilities() == JobInfo.NetworkType.ANY);
+                first.getNetworkType() == JobInfo.NETWORK_TYPE_ANY,
+                second.getNetworkType() == JobInfo.NETWORK_TYPE_ANY);
         assertEquals("Invalid deadline constraint.",
                 first.hasLateConstraint(),
                 second.hasLateConstraint());
diff --git a/services/tests/servicestests/src/com/android/server/pm/UserManagerTest.java b/services/tests/servicestests/src/com/android/server/pm/UserManagerTest.java
index 6e13732..a0b8c94 100644
--- a/services/tests/servicestests/src/com/android/server/pm/UserManagerTest.java
+++ b/services/tests/servicestests/src/com/android/server/pm/UserManagerTest.java
@@ -125,7 +125,8 @@
                 UserInfo.FLAG_MANAGED_PROFILE, UserHandle.USER_OWNER);
         assertNotNull(userInfo1);
         assertNull(userInfo2);
-
+        // Verify that current user is not a managed profile
+        assertFalse(mUserManager.isManagedProfile());
         // Cleanup
         removeUser(userInfo1.id);
     }
diff --git a/services/usage/java/com/android/server/usage/IntervalStats.java b/services/usage/java/com/android/server/usage/IntervalStats.java
index 43027ad..5f639ab 100644
--- a/services/usage/java/com/android/server/usage/IntervalStats.java
+++ b/services/usage/java/com/android/server/usage/IntervalStats.java
@@ -15,36 +15,72 @@
  */
 package com.android.server.usage;
 
+import android.app.usage.ConfigurationStats;
 import android.app.usage.TimeSparseArray;
 import android.app.usage.UsageEvents;
 import android.app.usage.UsageStats;
-import android.content.ComponentName;
+import android.content.res.Configuration;
 import android.util.ArrayMap;
+import android.util.ArraySet;
 
 class IntervalStats {
     public long beginTime;
     public long endTime;
     public long lastTimeSaved;
-    public final ArrayMap<String, UsageStats> stats = new ArrayMap<>();
+    public final ArrayMap<String, UsageStats> packageStats = new ArrayMap<>();
+    public final ArrayMap<Configuration, ConfigurationStats> configurations = new ArrayMap<>();
+    public Configuration activeConfiguration;
     public TimeSparseArray<UsageEvents.Event> events;
 
-    // Maps flattened string representations of component names to ComponentName.
-    // This helps save memory from using many duplicate ComponentNames and
-    // parse time when reading XML.
-    private final ArrayMap<String, ComponentName> mComponentNames = new ArrayMap<>();
+    // A string cache. This is important as when we're parsing XML files, we don't want to
+    // keep hundreds of strings that have the same contents. We will read the string
+    // and only keep it if it's not in the cache. The GC will take care of the
+    // strings that had identical copies in the cache.
+    private final ArraySet<String> mStringCache = new ArraySet<>();
 
+    /**
+     * Gets the UsageStats object for the given package, or creates one and adds it internally.
+     */
     UsageStats getOrCreateUsageStats(String packageName) {
-        UsageStats usageStats = stats.get(packageName);
+        UsageStats usageStats = packageStats.get(packageName);
         if (usageStats == null) {
             usageStats = new UsageStats();
-            usageStats.mPackageName = packageName;
+            usageStats.mPackageName = getCachedStringRef(packageName);
             usageStats.mBeginTimeStamp = beginTime;
             usageStats.mEndTimeStamp = endTime;
-            stats.put(packageName, usageStats);
+            packageStats.put(usageStats.mPackageName, usageStats);
         }
         return usageStats;
     }
 
+    /**
+     * Gets the ConfigurationStats object for the given configuration, or creates one and adds it
+     * internally.
+     */
+    ConfigurationStats getOrCreateConfigurationStats(Configuration config) {
+        ConfigurationStats configStats = configurations.get(config);
+        if (configStats == null) {
+            configStats = new ConfigurationStats();
+            configStats.mBeginTimeStamp = beginTime;
+            configStats.mEndTimeStamp = endTime;
+            configStats.mConfiguration = config;
+            configurations.put(config, configStats);
+        }
+        return configStats;
+    }
+
+    /**
+     * Builds a UsageEvents.Event, but does not add it internally.
+     */
+    UsageEvents.Event buildEvent(String packageName, String className) {
+        UsageEvents.Event event = new UsageEvents.Event();
+        event.mPackage = getCachedStringRef(packageName);
+        if (className != null) {
+            event.mClass = getCachedStringRef(className);
+        }
+        return event;
+    }
+
     void update(String packageName, long timeStamp, int eventType) {
         UsageStats usageStats = getOrCreateUsageStats(packageName);
 
@@ -60,22 +96,37 @@
         usageStats.mLastEvent = eventType;
         usageStats.mLastTimeUsed = timeStamp;
         usageStats.mEndTimeStamp = timeStamp;
+
+        if (eventType == UsageEvents.Event.MOVE_TO_FOREGROUND) {
+            usageStats.mLaunchCount += 1;
+        }
+
         endTime = timeStamp;
     }
 
-    /**
-     * Return a ComponentName for the given string representation. This will use a cached
-     * copy of the ComponentName if possible, otherwise it will parse and add it to the
-     * internal cache.
-     */
-    ComponentName getCachedComponentName(String str) {
-        ComponentName name = mComponentNames.get(str);
-        if (name == null) {
-            name = ComponentName.unflattenFromString(str);
-            if (name != null) {
-                mComponentNames.put(str, name);
-            }
+    void updateConfigurationStats(Configuration config, long timeStamp) {
+        if (activeConfiguration != null) {
+            ConfigurationStats activeStats = configurations.get(activeConfiguration);
+            activeStats.mTotalTimeActive += timeStamp - activeStats.mLastTimeActive;
+            activeStats.mLastTimeActive = timeStamp - 1;
         }
-        return name;
+
+        if (config != null) {
+            ConfigurationStats configStats = getOrCreateConfigurationStats(config);
+            configStats.mLastTimeActive = timeStamp;
+            configStats.mActivationCount += 1;
+            activeConfiguration = configStats.mConfiguration;
+        }
+
+        endTime = timeStamp;
+    }
+
+    private String getCachedStringRef(String str) {
+        final int index = mStringCache.indexOf(str);
+        if (index < 0) {
+            mStringCache.add(str);
+            return str;
+        }
+        return mStringCache.valueAt(index);
     }
 }
diff --git a/services/usage/java/com/android/server/usage/UnixCalendar.java b/services/usage/java/com/android/server/usage/UnixCalendar.java
new file mode 100644
index 0000000..ce06a91
--- /dev/null
+++ b/services/usage/java/com/android/server/usage/UnixCalendar.java
@@ -0,0 +1,99 @@
+/**
+ * Copyright (C) 2014 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.server.usage;
+
+import android.app.usage.UsageStatsManager;
+
+/**
+ * A handy calendar object that knows nothing of Locale's or TimeZones. This simplifies
+ * interval book-keeping. It is *NOT* meant to be used as a user-facing calendar, as it has
+ * no concept of Locale or TimeZone.
+ */
+public class UnixCalendar {
+    private static final long DAY_IN_MILLIS = 24 * 60 * 60 * 1000;
+    private static final long WEEK_IN_MILLIS = 7 * DAY_IN_MILLIS;
+    private static final long MONTH_IN_MILLIS = 30 * DAY_IN_MILLIS;
+    private static final long YEAR_IN_MILLIS = 365 * DAY_IN_MILLIS;
+    private long mTime;
+
+    public UnixCalendar(long time) {
+        mTime = time;
+    }
+
+    public void truncateToDay() {
+        mTime -= mTime % DAY_IN_MILLIS;
+    }
+
+    public void truncateToWeek() {
+        mTime -= mTime % WEEK_IN_MILLIS;
+    }
+
+    public void truncateToMonth() {
+        mTime -= mTime % MONTH_IN_MILLIS;
+    }
+
+    public void truncateToYear() {
+        mTime -= mTime % YEAR_IN_MILLIS;
+    }
+
+    public void addDays(int val) {
+        mTime += val * DAY_IN_MILLIS;
+    }
+
+    public void addWeeks(int val) {
+        mTime += val * WEEK_IN_MILLIS;
+    }
+
+    public void addMonths(int val) {
+        mTime += val * MONTH_IN_MILLIS;
+    }
+
+    public void addYears(int val) {
+        mTime += val * YEAR_IN_MILLIS;
+    }
+
+    public void setTimeInMillis(long time) {
+        mTime = time;
+    }
+
+    public long getTimeInMillis() {
+        return mTime;
+    }
+
+    public static void truncateTo(UnixCalendar calendar, int intervalType) {
+        switch (intervalType) {
+            case UsageStatsManager.INTERVAL_YEARLY:
+                calendar.truncateToYear();
+                break;
+
+            case UsageStatsManager.INTERVAL_MONTHLY:
+                calendar.truncateToMonth();
+                break;
+
+            case UsageStatsManager.INTERVAL_WEEKLY:
+                calendar.truncateToWeek();
+                break;
+
+            case UsageStatsManager.INTERVAL_DAILY:
+                calendar.truncateToDay();
+                break;
+
+            default:
+                throw new UnsupportedOperationException("Can't truncate date to interval " +
+                        intervalType);
+        }
+    }
+}
diff --git a/services/usage/java/com/android/server/usage/UsageStatsDatabase.java b/services/usage/java/com/android/server/usage/UsageStatsDatabase.java
index e6ce0fe..972c929 100644
--- a/services/usage/java/com/android/server/usage/UsageStatsDatabase.java
+++ b/services/usage/java/com/android/server/usage/UsageStatsDatabase.java
@@ -17,29 +17,34 @@
 package com.android.server.usage;
 
 import android.app.usage.TimeSparseArray;
-import android.app.usage.UsageStats;
 import android.app.usage.UsageStatsManager;
 import android.util.AtomicFile;
 import android.util.Slog;
 
+import java.io.BufferedReader;
+import java.io.BufferedWriter;
 import java.io.File;
+import java.io.FileReader;
+import java.io.FileWriter;
 import java.io.FilenameFilter;
 import java.io.IOException;
 import java.util.ArrayList;
-import java.util.Calendar;
 import java.util.List;
 
 /**
  * Provides an interface to query for UsageStat data from an XML database.
  */
 class UsageStatsDatabase {
+    private static final int CURRENT_VERSION = 2;
+
     private static final String TAG = "UsageStatsDatabase";
     private static final boolean DEBUG = UsageStatsService.DEBUG;
 
     private final Object mLock = new Object();
     private final File[] mIntervalDirs;
     private final TimeSparseArray<AtomicFile>[] mSortedStatFiles;
-    private final Calendar mCal;
+    private final UnixCalendar mCal;
+    private final File mVersionFile;
 
     public UsageStatsDatabase(File dir) {
         mIntervalDirs = new File[] {
@@ -48,14 +53,15 @@
                 new File(dir, "monthly"),
                 new File(dir, "yearly"),
         };
+        mVersionFile = new File(dir, "version");
         mSortedStatFiles = new TimeSparseArray[mIntervalDirs.length];
-        mCal = Calendar.getInstance();
+        mCal = new UnixCalendar(0);
     }
 
     /**
      * Initialize any directories required and index what stats are available.
      */
-    void init() {
+    public void init(long currentTimeMillis) {
         synchronized (mLock) {
             for (File f : mIntervalDirs) {
                 f.mkdirs();
@@ -65,30 +71,128 @@
                 }
             }
 
-            final FilenameFilter backupFileFilter = new FilenameFilter() {
-                @Override
-                public boolean accept(File dir, String name) {
-                    return !name.endsWith(".bak");
+            checkVersionLocked();
+            indexFilesLocked();
+
+            // Delete files that are in the future.
+            for (TimeSparseArray<AtomicFile> files : mSortedStatFiles) {
+                final int startIndex = files.closestIndexOnOrAfter(currentTimeMillis);
+                if (startIndex < 0) {
+                    continue;
                 }
-            };
 
-            // Index the available usage stat files on disk.
-            for (int i = 0; i < mSortedStatFiles.length; i++) {
+                final int fileCount = files.size();
+                for (int i = startIndex; i < fileCount; i++) {
+                    files.valueAt(i).delete();
+                }
+
+                // Remove in a separate loop because any accesses (valueAt)
+                // will cause a gc in the SparseArray and mess up the order.
+                for (int i = startIndex; i < fileCount; i++) {
+                    files.removeAt(i);
+                }
+            }
+        }
+    }
+
+    private void indexFilesLocked() {
+        final FilenameFilter backupFileFilter = new FilenameFilter() {
+            @Override
+            public boolean accept(File dir, String name) {
+                return !name.endsWith(".bak");
+            }
+        };
+
+        // Index the available usage stat files on disk.
+        for (int i = 0; i < mSortedStatFiles.length; i++) {
+            if (mSortedStatFiles[i] == null) {
                 mSortedStatFiles[i] = new TimeSparseArray<>();
-                File[] files = mIntervalDirs[i].listFiles(backupFileFilter);
-                if (files != null) {
-                    if (DEBUG) {
-                        Slog.d(TAG, "Found " + files.length + " stat files for interval " + i);
-                    }
+            } else {
+                mSortedStatFiles[i].clear();
+            }
+            File[] files = mIntervalDirs[i].listFiles(backupFileFilter);
+            if (files != null) {
+                if (DEBUG) {
+                    Slog.d(TAG, "Found " + files.length + " stat files for interval " + i);
+                }
 
+                for (File f : files) {
+                    final AtomicFile af = new AtomicFile(f);
+                    mSortedStatFiles[i].put(UsageStatsXml.parseBeginTime(af), af);
+                }
+            }
+        }
+    }
+
+    private void checkVersionLocked() {
+        int version;
+        try (BufferedReader reader = new BufferedReader(new FileReader(mVersionFile))) {
+            version = Integer.parseInt(reader.readLine());
+        } catch (NumberFormatException | IOException e) {
+            version = 0;
+        }
+
+        if (version != CURRENT_VERSION) {
+            Slog.i(TAG, "Upgrading from version " + version + " to " + CURRENT_VERSION);
+            doUpgradeLocked(version);
+
+            try (BufferedWriter writer = new BufferedWriter(new FileWriter(mVersionFile))) {
+                writer.write(Integer.toString(CURRENT_VERSION));
+            } catch (IOException e) {
+                Slog.e(TAG, "Failed to write new version");
+                throw new RuntimeException(e);
+            }
+        }
+    }
+
+    private void doUpgradeLocked(int thisVersion) {
+        if (thisVersion < 2) {
+            // Delete all files if we are version 0. This is a pre-release version,
+            // so this is fine.
+            Slog.i(TAG, "Deleting all usage stats files");
+            for (int i = 0; i < mIntervalDirs.length; i++) {
+                File[] files = mIntervalDirs[i].listFiles();
+                if (files != null) {
                     for (File f : files) {
-                        mSortedStatFiles[i].put(Long.parseLong(f.getName()), new AtomicFile(f));
+                        f.delete();
                     }
                 }
             }
         }
     }
 
+    public void onTimeChanged(long timeDiffMillis) {
+        synchronized (mLock) {
+            for (TimeSparseArray<AtomicFile> files : mSortedStatFiles) {
+                final int fileCount = files.size();
+                for (int i = 0; i < fileCount; i++) {
+                    final AtomicFile file = files.valueAt(i);
+                    final long newTime = files.keyAt(i) + timeDiffMillis;
+                    if (newTime < 0) {
+                        Slog.i(TAG, "Deleting file " + file.getBaseFile().getAbsolutePath()
+                                + " for it is in the future now.");
+                        file.delete();
+                    } else {
+                        try {
+                            file.openRead().close();
+                        } catch (IOException e) {
+                            // Ignore, this is just to make sure there are no backups.
+                        }
+                        final File newFile = new File(file.getBaseFile().getParentFile(),
+                                Long.toString(newTime));
+                        Slog.i(TAG, "Moving file " + file.getBaseFile().getAbsolutePath() + " to "
+                                + newFile.getAbsolutePath());
+                        file.getBaseFile().renameTo(newFile);
+                    }
+                }
+                files.clear();
+            }
+
+            // Now re-index the new files.
+            indexFilesLocked();
+        }
+    }
+
     /**
      * Get the latest stats that exist for this interval type.
      */
@@ -133,33 +237,77 @@
     }
 
     /**
-     * Find all {@link UsageStats} for the given range and interval type.
+     * Figures out what to extract from the given IntervalStats object.
      */
-    public List<UsageStats> queryUsageStats(int intervalType, long beginTime, long endTime) {
+    interface StatCombiner<T> {
+
+        /**
+         * Implementations should extract interesting from <code>stats</code> and add it
+         * to the <code>accumulatedResult</code> list.
+         *
+         * If the <code>stats</code> object is mutable, <code>mutable</code> will be true,
+         * which means you should make a copy of the data before adding it to the
+         * <code>accumulatedResult</code> list.
+         *
+         * @param stats The {@link IntervalStats} object selected.
+         * @param mutable Whether or not the data inside the stats object is mutable.
+         * @param accumulatedResult The list to which to add extracted data.
+         */
+        void combine(IntervalStats stats, boolean mutable, List<T> accumulatedResult);
+    }
+
+    /**
+     * Find all {@link IntervalStats} for the given range and interval type.
+     */
+    public <T> List<T> queryUsageStats(int intervalType, long beginTime, long endTime,
+            StatCombiner<T> combiner) {
         synchronized (mLock) {
             if (intervalType < 0 || intervalType >= mIntervalDirs.length) {
                 throw new IllegalArgumentException("Bad interval type " + intervalType);
             }
 
-            if (endTime < beginTime) {
+            final TimeSparseArray<AtomicFile> intervalStats = mSortedStatFiles[intervalType];
+
+            if (endTime <= beginTime) {
+                if (DEBUG) {
+                    Slog.d(TAG, "endTime(" + endTime + ") <= beginTime(" + beginTime + ")");
+                }
                 return null;
             }
 
-            final int startIndex = mSortedStatFiles[intervalType].closestIndexOnOrBefore(beginTime);
+            int startIndex = intervalStats.closestIndexOnOrBefore(beginTime);
             if (startIndex < 0) {
+                // All the stats available have timestamps after beginTime, which means they all
+                // match.
+                startIndex = 0;
+            }
+
+            int endIndex = intervalStats.closestIndexOnOrBefore(endTime);
+            if (endIndex < 0) {
+                // All the stats start after this range ends, so nothing matches.
+                if (DEBUG) {
+                    Slog.d(TAG, "No results for this range. All stats start after.");
+                }
                 return null;
             }
 
-            int endIndex = mSortedStatFiles[intervalType].closestIndexOnOrAfter(endTime);
-            if (endIndex < 0) {
-                endIndex = mSortedStatFiles[intervalType].size() - 1;
+            if (intervalStats.keyAt(endIndex) == endTime) {
+                // The endTime is exclusive, so if we matched exactly take the one before.
+                endIndex--;
+                if (endIndex < 0) {
+                    // All the stats start after this range ends, so nothing matches.
+                    if (DEBUG) {
+                        Slog.d(TAG, "No results for this range. All stats start after.");
+                    }
+                    return null;
+                }
             }
 
             try {
                 IntervalStats stats = new IntervalStats();
-                ArrayList<UsageStats> results = new ArrayList<>();
+                ArrayList<T> results = new ArrayList<>();
                 for (int i = startIndex; i <= endIndex; i++) {
-                    final AtomicFile f = mSortedStatFiles[intervalType].valueAt(i);
+                    final AtomicFile f = intervalStats.valueAt(i);
 
                     if (DEBUG) {
                         Slog.d(TAG, "Reading stat file " + f.getBaseFile().getAbsolutePath());
@@ -167,7 +315,7 @@
 
                     UsageStatsXml.read(f, stats);
                     if (beginTime < stats.endTime) {
-                        results.addAll(stats.stats.values());
+                        combiner.combine(stats, false, results);
                     }
                 }
                 return results;
@@ -206,22 +354,25 @@
     /**
      * Remove any usage stat files that are too old.
      */
-    public void prune() {
+    public void prune(final long currentTimeMillis) {
         synchronized (mLock) {
-            long timeNow = System.currentTimeMillis();
+            mCal.setTimeInMillis(currentTimeMillis);
+            mCal.addYears(-3);
+            pruneFilesOlderThan(mIntervalDirs[UsageStatsManager.INTERVAL_YEARLY],
+                    mCal.getTimeInMillis());
 
-            mCal.setTimeInMillis(timeNow);
-            mCal.add(Calendar.MONTH, -6);
+            mCal.setTimeInMillis(currentTimeMillis);
+            mCal.addMonths(-6);
             pruneFilesOlderThan(mIntervalDirs[UsageStatsManager.INTERVAL_MONTHLY],
                     mCal.getTimeInMillis());
 
-            mCal.setTimeInMillis(timeNow);
-            mCal.add(Calendar.WEEK_OF_YEAR, -4);
+            mCal.setTimeInMillis(currentTimeMillis);
+            mCal.addWeeks(-4);
             pruneFilesOlderThan(mIntervalDirs[UsageStatsManager.INTERVAL_WEEKLY],
                     mCal.getTimeInMillis());
 
-            mCal.setTimeInMillis(timeNow);
-            mCal.add(Calendar.DAY_OF_YEAR, -7);
+            mCal.setTimeInMillis(currentTimeMillis);
+            mCal.addDays(-7);
             pruneFilesOlderThan(mIntervalDirs[UsageStatsManager.INTERVAL_DAILY],
                     mCal.getTimeInMillis());
         }
diff --git a/services/usage/java/com/android/server/usage/UsageStatsService.java b/services/usage/java/com/android/server/usage/UsageStatsService.java
index 82e837d..2ed9745 100644
--- a/services/usage/java/com/android/server/usage/UsageStatsService.java
+++ b/services/usage/java/com/android/server/usage/UsageStatsService.java
@@ -18,6 +18,7 @@
 
 import android.Manifest;
 import android.app.AppOpsManager;
+import android.app.usage.ConfigurationStats;
 import android.app.usage.IUsageStatsManager;
 import android.app.usage.UsageEvents;
 import android.app.usage.UsageStats;
@@ -30,11 +31,15 @@
 import android.content.pm.PackageManager;
 import android.content.pm.ParceledListSlice;
 import android.content.pm.UserInfo;
+import android.content.res.Configuration;
 import android.os.Binder;
+import android.os.Debug;
 import android.os.Environment;
 import android.os.Handler;
 import android.os.Looper;
 import android.os.Message;
+import android.os.RemoteException;
+import android.os.SystemClock;
 import android.os.UserHandle;
 import android.os.UserManager;
 import android.util.ArraySet;
@@ -59,9 +64,8 @@
     static final boolean DEBUG = false;
     private static final long TEN_SECONDS = 10 * 1000;
     private static final long TWENTY_MINUTES = 20 * 60 * 1000;
-    private static final long TWO_MINUTES = 2 * 60 * 1000;
     private static final long FLUSH_INTERVAL = DEBUG ? TEN_SECONDS : TWENTY_MINUTES;
-    private static final long END_TIME_DELAY = DEBUG ? 0 : TWO_MINUTES;
+    private static final long TIME_CHANGE_THRESHOLD_MILLIS = 2 * 1000; // Two seconds.
 
     // Handler message types.
     static final int MSG_REPORT_EVENT = 0;
@@ -75,6 +79,8 @@
 
     private final SparseArray<UserUsageStatsService> mUserState = new SparseArray<>();
     private File mUsageStatsDir;
+    long mRealTimeSnapshot;
+    long mSystemTimeSnapshot;
 
     public UsageStatsService(Context context) {
         super(context);
@@ -101,6 +107,9 @@
             cleanUpRemovedUsersLocked();
         }
 
+        mRealTimeSnapshot = SystemClock.elapsedRealtime();
+        mSystemTimeSnapshot = System.currentTimeMillis();
+
         publishLocalService(UsageStatsManagerInternal.class, new LocalService());
         publishBinderService(Context.USAGE_STATS_SERVICE, new BinderService());
     }
@@ -163,19 +172,48 @@
         }
     }
 
-    private UserUsageStatsService getUserDataAndInitializeIfNeededLocked(int userId) {
+    private UserUsageStatsService getUserDataAndInitializeIfNeededLocked(int userId,
+            long currentTimeMillis) {
         UserUsageStatsService service = mUserState.get(userId);
         if (service == null) {
             service = new UserUsageStatsService(userId,
                     new File(mUsageStatsDir, Integer.toString(userId)), this);
-            service.init();
+            service.init(currentTimeMillis);
             mUserState.put(userId, service);
         }
         return service;
     }
 
     /**
-     * Called by the Bunder stub
+     * This should be the only way to get the time from the system.
+     */
+    private long checkAndGetTimeLocked() {
+        final long actualSystemTime = System.currentTimeMillis();
+        final long actualRealtime = SystemClock.elapsedRealtime();
+        final long expectedSystemTime = (actualRealtime - mRealTimeSnapshot) + mSystemTimeSnapshot;
+        if (Math.abs(actualSystemTime - expectedSystemTime) > TIME_CHANGE_THRESHOLD_MILLIS) {
+            // The time has changed.
+            final int userCount = mUserState.size();
+            for (int i = 0; i < userCount; i++) {
+                final UserUsageStatsService service = mUserState.valueAt(i);
+                service.onTimeChanged(expectedSystemTime, actualSystemTime);
+            }
+            mRealTimeSnapshot = actualRealtime;
+            mSystemTimeSnapshot = actualSystemTime;
+        }
+        return actualSystemTime;
+    }
+
+    /**
+     * Assuming the event's timestamp is measured in milliseconds since boot,
+     * convert it to a system wall time.
+     */
+    private void convertToSystemTimeLocked(UsageEvents.Event event) {
+        event.mTimeStamp = Math.max(0, event.mTimeStamp - mRealTimeSnapshot) + mSystemTimeSnapshot;
+    }
+
+    /**
+     * Called by the Binder stub
      */
     void shutdown() {
         synchronized (mLock) {
@@ -189,7 +227,11 @@
      */
     void reportEvent(UsageEvents.Event event, int userId) {
         synchronized (mLock) {
-            final UserUsageStatsService service = getUserDataAndInitializeIfNeededLocked(userId);
+            final long timeNow = checkAndGetTimeLocked();
+            convertToSystemTimeLocked(event);
+
+            final UserUsageStatsService service =
+                    getUserDataAndInitializeIfNeededLocked(userId, timeNow);
             service.reportEvent(event);
         }
     }
@@ -218,13 +260,14 @@
      * Called by the Binder stub.
      */
     List<UsageStats> queryUsageStats(int userId, int bucketType, long beginTime, long endTime) {
-        final long timeNow = System.currentTimeMillis();
-        if (beginTime > timeNow) {
-            return null;
-        }
-
         synchronized (mLock) {
-            UserUsageStatsService service = getUserDataAndInitializeIfNeededLocked(userId);
+            final long timeNow = checkAndGetTimeLocked();
+            if (!validRange(timeNow, beginTime, endTime)) {
+                return null;
+            }
+
+            final UserUsageStatsService service =
+                    getUserDataAndInitializeIfNeededLocked(userId, timeNow);
             return service.queryUsageStats(bucketType, beginTime, endTime);
         }
     }
@@ -232,24 +275,40 @@
     /**
      * Called by the Binder stub.
      */
-    UsageEvents queryEvents(int userId, long beginTime, long endTime) {
-        final long timeNow = System.currentTimeMillis();
-
-        // Adjust the endTime so that we don't query for the latest events.
-        // This is to prevent apps from making decision based on what app launched them,
-        // etc.
-        endTime = Math.min(endTime, timeNow - END_TIME_DELAY);
-
-        if (beginTime > endTime) {
-            return null;
-        }
-
+    List<ConfigurationStats> queryConfigurationStats(int userId, int bucketType, long beginTime,
+            long endTime) {
         synchronized (mLock) {
-            UserUsageStatsService service = getUserDataAndInitializeIfNeededLocked(userId);
+            final long timeNow = checkAndGetTimeLocked();
+            if (!validRange(timeNow, beginTime, endTime)) {
+                return null;
+            }
+
+            final UserUsageStatsService service =
+                    getUserDataAndInitializeIfNeededLocked(userId, timeNow);
+            return service.queryConfigurationStats(bucketType, beginTime, endTime);
+        }
+    }
+
+    /**
+     * Called by the Binder stub.
+     */
+    UsageEvents queryEvents(int userId, long beginTime, long endTime) {
+        synchronized (mLock) {
+            final long timeNow = checkAndGetTimeLocked();
+            if (!validRange(timeNow, beginTime, endTime)) {
+                return null;
+            }
+
+            final UserUsageStatsService service =
+                    getUserDataAndInitializeIfNeededLocked(userId, timeNow);
             return service.queryEvents(beginTime, endTime);
         }
     }
 
+    private static boolean validRange(long currentTime, long beginTime, long endTime) {
+        return beginTime <= currentTime && beginTime < endTime;
+    }
+
     private void flushToDiskLocked() {
         final int userCount = mUserState.size();
         for (int i = 0; i < userCount; i++) {
@@ -323,6 +382,28 @@
         }
 
         @Override
+        public ParceledListSlice<ConfigurationStats> queryConfigurationStats(int bucketType,
+                long beginTime, long endTime, String callingPackage) throws RemoteException {
+            if (!hasPermission(callingPackage)) {
+                return null;
+            }
+
+            final int userId = UserHandle.getCallingUserId();
+            final long token = Binder.clearCallingIdentity();
+            try {
+                final List<ConfigurationStats> results =
+                        UsageStatsService.this.queryConfigurationStats(userId, bucketType,
+                                beginTime, endTime);
+                if (results != null) {
+                    return new ParceledListSlice<>(results);
+                }
+            } finally {
+                Binder.restoreCallingIdentity(token);
+            }
+            return null;
+        }
+
+        @Override
         public UsageEvents queryEvents(long beginTime, long endTime, String callingPackage) {
             if (!hasPermission(callingPackage)) {
                 return null;
@@ -346,21 +427,42 @@
     private class LocalService extends UsageStatsManagerInternal {
 
         @Override
-        public void reportEvent(ComponentName component, int userId,
-                long timeStamp, int eventType) {
+        public void reportEvent(ComponentName component, int userId, int eventType) {
             if (component == null) {
                 Slog.w(TAG, "Event reported without a component name");
                 return;
             }
 
             UsageEvents.Event event = new UsageEvents.Event();
-            event.mComponent = component;
-            event.mTimeStamp = timeStamp;
+            event.mPackage = component.getPackageName();
+            event.mClass = component.getClassName();
+
+            // This will later be converted to system time.
+            event.mTimeStamp = SystemClock.elapsedRealtime();
+
             event.mEventType = eventType;
             mHandler.obtainMessage(MSG_REPORT_EVENT, userId, 0, event).sendToTarget();
         }
 
         @Override
+        public void reportConfigurationChange(Configuration config, int userId) {
+            if (config == null) {
+                Slog.w(TAG, "Configuration event reported with a null config");
+                return;
+            }
+
+            UsageEvents.Event event = new UsageEvents.Event();
+            event.mPackage = "android";
+
+            // This will later be converted to system time.
+            event.mTimeStamp = SystemClock.elapsedRealtime();
+
+            event.mEventType = UsageEvents.Event.CONFIGURATION_CHANGE;
+            event.mConfiguration = new Configuration(config);
+            mHandler.obtainMessage(MSG_REPORT_EVENT, userId, 0, event).sendToTarget();
+        }
+
+        @Override
         public void prepareShutdown() {
             // This method *WILL* do IO work, but we must block until it is finished or else
             // we might not shutdown cleanly. This is ok to do with the 'am' lock held, because
diff --git a/services/usage/java/com/android/server/usage/UsageStatsUtils.java b/services/usage/java/com/android/server/usage/UsageStatsUtils.java
deleted file mode 100644
index dd5f3b9..0000000
--- a/services/usage/java/com/android/server/usage/UsageStatsUtils.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/**
- * Copyright (C) 2014 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.server.usage;
-
-import android.app.usage.UsageStatsManager;
-
-import java.util.Calendar;
-
-/**
- * A collection of utility methods used by the UsageStatsService and accompanying classes.
- */
-final class UsageStatsUtils {
-    private UsageStatsUtils() {}
-
-    /**
-     * Truncates the date to the given UsageStats bucket. For example, if the bucket is
-     * {@link UsageStatsManager#INTERVAL_YEARLY}, the date is truncated to the 1st day of the year,
-     * with the time set to 00:00:00.
-     *
-     * @param bucket The UsageStats bucket to truncate to.
-     * @param cal The date to truncate.
-     */
-    public static void truncateDateTo(int bucket, Calendar cal) {
-        cal.set(Calendar.HOUR_OF_DAY, 0);
-        cal.set(Calendar.MINUTE, 0);
-        cal.set(Calendar.SECOND, 0);
-        cal.set(Calendar.MILLISECOND, 0);
-
-        switch (bucket) {
-            case UsageStatsManager.INTERVAL_YEARLY:
-                cal.set(Calendar.DAY_OF_YEAR, 0);
-                break;
-
-            case UsageStatsManager.INTERVAL_MONTHLY:
-                cal.set(Calendar.DAY_OF_MONTH, 0);
-                break;
-
-            case UsageStatsManager.INTERVAL_WEEKLY:
-                cal.set(Calendar.DAY_OF_WEEK, 0);
-                break;
-
-            case UsageStatsManager.INTERVAL_DAILY:
-                break;
-
-            default:
-                throw new UnsupportedOperationException("Can't truncate date to bucket " + bucket);
-        }
-    }
-}
diff --git a/services/usage/java/com/android/server/usage/UsageStatsXml.java b/services/usage/java/com/android/server/usage/UsageStatsXml.java
index 48881d0..9ce6d63 100644
--- a/services/usage/java/com/android/server/usage/UsageStatsXml.java
+++ b/services/usage/java/com/android/server/usage/UsageStatsXml.java
@@ -37,10 +37,15 @@
     private static final String USAGESTATS_TAG = "usagestats";
     private static final String VERSION_ATTR = "version";
 
+    public static long parseBeginTime(AtomicFile file) {
+        return Long.parseLong(file.getBaseFile().getName());
+    }
+
     public static void read(AtomicFile file, IntervalStats statsOut) throws IOException {
         try {
             FileInputStream in = file.openRead();
             try {
+                statsOut.beginTime = parseBeginTime(file);
                 read(in, statsOut);
                 statsOut.lastTimeSaved = file.getLastModifiedTime();
             } finally {
diff --git a/services/usage/java/com/android/server/usage/UsageStatsXmlV1.java b/services/usage/java/com/android/server/usage/UsageStatsXmlV1.java
index 916601b..ef95a7b 100644
--- a/services/usage/java/com/android/server/usage/UsageStatsXmlV1.java
+++ b/services/usage/java/com/android/server/usage/UsageStatsXmlV1.java
@@ -15,16 +15,17 @@
  */
 package com.android.server.usage;
 
-import com.android.internal.util.FastXmlSerializer;
 import com.android.internal.util.XmlUtils;
 
 import org.xmlpull.v1.XmlPullParser;
 import org.xmlpull.v1.XmlPullParserException;
+import org.xmlpull.v1.XmlSerializer;
 
+import android.app.usage.ConfigurationStats;
 import android.app.usage.TimeSparseArray;
 import android.app.usage.UsageEvents;
 import android.app.usage.UsageStats;
-import android.content.ComponentName;
+import android.content.res.Configuration;
 
 import java.io.IOException;
 import java.net.ProtocolException;
@@ -33,89 +34,144 @@
  * UsageStats reader/writer for version 1 of the XML format.
  */
 final class UsageStatsXmlV1 {
-    private static final String BEGIN_TIME_ATTR = "beginTime";
-    private static final String END_TIME_ATTR = "endTime";
+    private static final String PACKAGES_TAG = "packages";
     private static final String PACKAGE_TAG = "package";
-    private static final String NAME_ATTR = "name";
-    private static final String TOTAL_TIME_ACTIVE_ATTR = "totalTimeActive";
-    private static final String LAST_TIME_ACTIVE_ATTR = "lastTimeActive";
-    private static final String LAST_EVENT_ATTR = "lastEvent";
+
+    private static final String CONFIGURATIONS_TAG = "configurations";
+    private static final String CONFIG_TAG = "config";
+
     private static final String EVENT_LOG_TAG = "event-log";
+    private static final String EVENT_TAG = "event";
+
+    // Attributes
+    private static final String PACKAGE_ATTR = "package";
+    private static final String CLASS_ATTR = "class";
+    private static final String TOTAL_TIME_ACTIVE_ATTR = "timeActive";
+    private static final String COUNT_ATTR = "count";
+    private static final String ACTIVE_ATTR = "active";
+    private static final String LAST_EVENT_ATTR = "lastEvent";
     private static final String TYPE_ATTR = "type";
+
+    // Time attributes stored as an offset of the beginTime.
+    private static final String LAST_TIME_ACTIVE_ATTR = "lastTimeActive";
+    private static final String END_TIME_ATTR = "endTime";
     private static final String TIME_ATTR = "time";
 
-    private static UsageStats readNextUsageStats(XmlPullParser parser)
+    private static void loadUsageStats(XmlPullParser parser, IntervalStats statsOut)
             throws XmlPullParserException, IOException {
-        if (parser.getEventType() != XmlPullParser.START_TAG) {
-            XmlUtils.nextElement(parser);
+        final String pkg = parser.getAttributeValue(null, PACKAGE_ATTR);
+        if (pkg == null) {
+            throw new ProtocolException("no " + PACKAGE_ATTR + " attribute present");
         }
 
-        if (parser.getEventType() != XmlPullParser.START_TAG ||
-                !parser.getName().equals(PACKAGE_TAG)) {
-            return null;
-        }
+        final UsageStats stats = statsOut.getOrCreateUsageStats(pkg);
 
-        final String name = parser.getAttributeValue(null, NAME_ATTR);
-        if (name == null) {
-            throw new ProtocolException("no " + NAME_ATTR + " attribute present");
-        }
+        // Apply the offset to the beginTime to find the absolute time.
+        stats.mLastTimeUsed = statsOut.beginTime + XmlUtils.readLongAttribute(
+                parser, LAST_TIME_ACTIVE_ATTR);
 
-        UsageStats stats = new UsageStats();
-        stats.mPackageName = name;
         stats.mTotalTimeInForeground = XmlUtils.readLongAttribute(parser, TOTAL_TIME_ACTIVE_ATTR);
-        stats.mLastTimeUsed = XmlUtils.readLongAttribute(parser, LAST_TIME_ACTIVE_ATTR);
         stats.mLastEvent = XmlUtils.readIntAttribute(parser, LAST_EVENT_ATTR);
-        XmlUtils.skipCurrentTag(parser);
-        return stats;
     }
 
-    private static UsageEvents.Event readNextEvent(XmlPullParser parser, IntervalStats statsOut)
+    private static void loadConfigStats(XmlPullParser parser, IntervalStats statsOut)
             throws XmlPullParserException, IOException {
-        if (parser.getEventType() != XmlPullParser.START_TAG) {
-            XmlUtils.nextElement(parser);
+        final Configuration config = new Configuration();
+        Configuration.readXmlAttrs(parser, config);
+
+        final ConfigurationStats configStats = statsOut.getOrCreateConfigurationStats(config);
+
+        // Apply the offset to the beginTime to find the absolute time.
+        configStats.mLastTimeActive = statsOut.beginTime + XmlUtils.readLongAttribute(
+                parser, LAST_TIME_ACTIVE_ATTR);
+
+        configStats.mTotalTimeActive = XmlUtils.readLongAttribute(parser, TOTAL_TIME_ACTIVE_ATTR);
+        configStats.mActivationCount = XmlUtils.readIntAttribute(parser, COUNT_ATTR);
+        if (XmlUtils.readBooleanAttribute(parser, ACTIVE_ATTR)) {
+            statsOut.activeConfiguration = configStats.mConfiguration;
+        }
+    }
+
+    private static void loadEvent(XmlPullParser parser, IntervalStats statsOut)
+            throws XmlPullParserException, IOException {
+        final String packageName = XmlUtils.readStringAttribute(parser, PACKAGE_ATTR);
+        if (packageName == null) {
+            throw new ProtocolException("no " + PACKAGE_ATTR + " attribute present");
         }
 
-        if (parser.getEventType() != XmlPullParser.START_TAG ||
-                !parser.getName().equals(EVENT_LOG_TAG)) {
-            return null;
-        }
+        final String className = XmlUtils.readStringAttribute(parser, CLASS_ATTR);
 
-        final String componentName = XmlUtils.readStringAttribute(parser, NAME_ATTR);
-        if (componentName == null) {
-            throw new ProtocolException("no " + NAME_ATTR + " attribute present");
-        }
+        final UsageEvents.Event event = statsOut.buildEvent(packageName, className);
 
-        ComponentName component = statsOut.getCachedComponentName(componentName);
-        if (component == null) {
-            throw new ProtocolException("ComponentName " + componentName + " is invalid");
-        }
+        // Apply the offset to the beginTime to find the absolute time of this event.
+        event.mTimeStamp = statsOut.beginTime + XmlUtils.readLongAttribute(parser, TIME_ATTR);
 
-        UsageEvents.Event event = new UsageEvents.Event();
-        event.mComponent = component;
         event.mEventType = XmlUtils.readIntAttribute(parser, TYPE_ATTR);
-        event.mTimeStamp = XmlUtils.readLongAttribute(parser, TIME_ATTR);
-        XmlUtils.skipCurrentTag(parser);
-        return event;
+        if (event.mEventType == UsageEvents.Event.CONFIGURATION_CHANGE) {
+            event.mConfiguration = new Configuration();
+            Configuration.readXmlAttrs(parser, event.mConfiguration);
+        }
+
+        if (statsOut.events == null) {
+            statsOut.events = new TimeSparseArray<>();
+        }
+        statsOut.events.put(event.mTimeStamp, event);
     }
 
-    private static void writeUsageStats(FastXmlSerializer serializer, UsageStats stats)
-            throws IOException {
-        serializer.startTag(null, PACKAGE_TAG);
-        serializer.attribute(null, NAME_ATTR, stats.mPackageName);
-        serializer.attribute(null, TOTAL_TIME_ACTIVE_ATTR,
-                Long.toString(stats.mTotalTimeInForeground));
-        serializer.attribute(null, LAST_TIME_ACTIVE_ATTR, Long.toString(stats.mLastTimeUsed));
-        serializer.attribute(null, LAST_EVENT_ATTR, Integer.toString(stats.mLastEvent));
-        serializer.endTag(null, PACKAGE_TAG);
+    private static void writeUsageStats(XmlSerializer xml, final IntervalStats stats,
+            final UsageStats usageStats) throws IOException {
+        xml.startTag(null, PACKAGE_TAG);
+
+        // Write the time offset.
+        XmlUtils.writeLongAttribute(xml, LAST_TIME_ACTIVE_ATTR,
+                usageStats.mLastTimeUsed - stats.beginTime);
+
+        XmlUtils.writeStringAttribute(xml, PACKAGE_ATTR, usageStats.mPackageName);
+        XmlUtils.writeLongAttribute(xml, TOTAL_TIME_ACTIVE_ATTR, usageStats.mTotalTimeInForeground);
+        XmlUtils.writeIntAttribute(xml, LAST_EVENT_ATTR, usageStats.mLastEvent);
+
+        xml.endTag(null, PACKAGE_TAG);
     }
 
-    private static void writeEvent(FastXmlSerializer serializer, UsageEvents.Event event)
-            throws IOException {
-        serializer.startTag(null, EVENT_LOG_TAG);
-        serializer.attribute(null, NAME_ATTR, event.getComponent().flattenToString());
-        serializer.attribute(null, TYPE_ATTR, Integer.toString(event.getEventType()));
-        serializer.attribute(null, TIME_ATTR, Long.toString(event.getTimeStamp()));
-        serializer.endTag(null, EVENT_LOG_TAG);
+    private static void writeConfigStats(XmlSerializer xml, final IntervalStats stats,
+            final ConfigurationStats configStats, boolean isActive) throws IOException {
+        xml.startTag(null, CONFIG_TAG);
+
+        // Write the time offset.
+        XmlUtils.writeLongAttribute(xml, LAST_TIME_ACTIVE_ATTR,
+                configStats.mLastTimeActive - stats.beginTime);
+
+        XmlUtils.writeLongAttribute(xml, TOTAL_TIME_ACTIVE_ATTR, configStats.mTotalTimeActive);
+        XmlUtils.writeIntAttribute(xml, COUNT_ATTR, configStats.mActivationCount);
+        if (isActive) {
+            XmlUtils.writeBooleanAttribute(xml, ACTIVE_ATTR, true);
+        }
+
+        // Now write the attributes representing the configuration object.
+        Configuration.writeXmlAttrs(xml, configStats.mConfiguration);
+
+        xml.endTag(null, CONFIG_TAG);
+    }
+
+    private static void writeEvent(XmlSerializer xml, final IntervalStats stats,
+            final UsageEvents.Event event) throws IOException {
+        xml.startTag(null, EVENT_TAG);
+
+        // Store the time offset.
+        XmlUtils.writeLongAttribute(xml, TIME_ATTR, event.mTimeStamp - stats.beginTime);
+
+        XmlUtils.writeStringAttribute(xml, PACKAGE_ATTR, event.mPackage);
+        if (event.mClass != null) {
+            XmlUtils.writeStringAttribute(xml, CLASS_ATTR, event.mClass);
+        }
+        XmlUtils.writeIntAttribute(xml, TYPE_ATTR, event.mEventType);
+
+        if (event.mEventType == UsageEvents.Event.CONFIGURATION_CHANGE
+                && event.mConfiguration != null) {
+            Configuration.writeXmlAttrs(xml, event.mConfiguration);
+        }
+
+        xml.endTag(null, EVENT_TAG);
     }
 
     /**
@@ -127,55 +183,74 @@
      */
     public static void read(XmlPullParser parser, IntervalStats statsOut)
             throws XmlPullParserException, IOException {
-        statsOut.stats.clear();
+        statsOut.packageStats.clear();
+        statsOut.configurations.clear();
+        statsOut.activeConfiguration = null;
 
         if (statsOut.events != null) {
             statsOut.events.clear();
         }
 
-        statsOut.beginTime = XmlUtils.readLongAttribute(parser, BEGIN_TIME_ATTR);
         statsOut.endTime = XmlUtils.readLongAttribute(parser, END_TIME_ATTR);
-        XmlUtils.nextElement(parser);
 
-        UsageStats pkgStats;
-        while ((pkgStats = readNextUsageStats(parser)) != null) {
-            pkgStats.mBeginTimeStamp = statsOut.beginTime;
-            pkgStats.mEndTimeStamp = statsOut.endTime;
-            statsOut.stats.put(pkgStats.mPackageName, pkgStats);
-        }
-
-        UsageEvents.Event event;
-        while ((event = readNextEvent(parser, statsOut)) != null) {
-            if (statsOut.events == null) {
-                statsOut.events = new TimeSparseArray<>();
+        int eventCode;
+        int outerDepth = parser.getDepth();
+        while ((eventCode = parser.next()) != XmlPullParser.END_DOCUMENT
+                && (eventCode != XmlPullParser.END_TAG || parser.getDepth() > outerDepth)) {
+            if (eventCode != XmlPullParser.START_TAG) {
+                continue;
             }
-            statsOut.events.put(event.getTimeStamp(), event);
+
+            final String tag = parser.getName();
+            switch (tag) {
+                case PACKAGE_TAG:
+                    loadUsageStats(parser, statsOut);
+                    break;
+
+                case CONFIG_TAG:
+                    loadConfigStats(parser, statsOut);
+                    break;
+
+                case EVENT_TAG:
+                    loadEvent(parser, statsOut);
+                    break;
+            }
         }
     }
 
     /**
-     * Writes the stats object to an XML file. The {@link FastXmlSerializer}
+     * Writes the stats object to an XML file. The {@link XmlSerializer}
      * has already written the <code><usagestats></code> tag, but attributes may still
      * be added.
      *
-     * @param serializer The serializer to which to write the stats data.
+     * @param xml The serializer to which to write the packageStats data.
      * @param stats The stats object to write to the XML file.
      */
-    public static void write(FastXmlSerializer serializer, IntervalStats stats) throws IOException {
-        serializer.attribute(null, BEGIN_TIME_ATTR, Long.toString(stats.beginTime));
-        serializer.attribute(null, END_TIME_ATTR, Long.toString(stats.endTime));
+    public static void write(XmlSerializer xml, IntervalStats stats) throws IOException {
+        XmlUtils.writeLongAttribute(xml, END_TIME_ATTR, stats.endTime - stats.beginTime);
 
-        final int statsCount = stats.stats.size();
+        xml.startTag(null, PACKAGES_TAG);
+        final int statsCount = stats.packageStats.size();
         for (int i = 0; i < statsCount; i++) {
-            writeUsageStats(serializer, stats.stats.valueAt(i));
+            writeUsageStats(xml, stats, stats.packageStats.valueAt(i));
         }
+        xml.endTag(null, PACKAGES_TAG);
 
-        if (stats.events != null) {
-            final int eventCount = stats.events.size();
-            for (int i = 0; i < eventCount; i++) {
-                writeEvent(serializer, stats.events.valueAt(i));
-            }
+
+        xml.startTag(null, CONFIGURATIONS_TAG);
+        final int configCount = stats.configurations.size();
+        for (int i = 0; i < configCount; i++) {
+            boolean active = stats.activeConfiguration.equals(stats.configurations.keyAt(i));
+            writeConfigStats(xml, stats, stats.configurations.valueAt(i), active);
         }
+        xml.endTag(null, CONFIGURATIONS_TAG);
+
+        xml.startTag(null, EVENT_LOG_TAG);
+        final int eventCount = stats.events != null ? stats.events.size() : 0;
+        for (int i = 0; i < eventCount; i++) {
+            writeEvent(xml, stats, stats.events.valueAt(i));
+        }
+        xml.endTag(null, EVENT_LOG_TAG);
     }
 
     private UsageStatsXmlV1() {
diff --git a/services/usage/java/com/android/server/usage/UserUsageStatsService.java b/services/usage/java/com/android/server/usage/UserUsageStatsService.java
index e489fb3..4916ec2 100644
--- a/services/usage/java/com/android/server/usage/UserUsageStatsService.java
+++ b/services/usage/java/com/android/server/usage/UserUsageStatsService.java
@@ -16,20 +16,23 @@
 
 package com.android.server.usage;
 
+import android.app.usage.ConfigurationStats;
 import android.app.usage.TimeSparseArray;
 import android.app.usage.UsageEvents;
 import android.app.usage.UsageStats;
 import android.app.usage.UsageStatsManager;
-import android.content.ComponentName;
+import android.content.res.Configuration;
+import android.os.SystemClock;
 import android.util.ArraySet;
 import android.util.Slog;
 
+import com.android.server.usage.UsageStatsDatabase.StatCombiner;
+
 import java.io.File;
 import java.io.IOException;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
 import java.util.Arrays;
-import java.util.Calendar;
 import java.util.List;
 
 /**
@@ -44,7 +47,7 @@
     private final UsageStatsDatabase mDatabase;
     private final IntervalStats[] mCurrentStats;
     private boolean mStatsChanged = false;
-    private final Calendar mDailyExpiryDate;
+    private final UnixCalendar mDailyExpiryDate;
     private final StatsUpdatedListener mListener;
     private final String mLogPrefix;
 
@@ -53,15 +56,15 @@
     }
 
     UserUsageStatsService(int userId, File usageStatsDir, StatsUpdatedListener listener) {
-        mDailyExpiryDate = Calendar.getInstance();
+        mDailyExpiryDate = new UnixCalendar(0);
         mDatabase = new UsageStatsDatabase(usageStatsDir);
         mCurrentStats = new IntervalStats[UsageStatsManager.INTERVAL_COUNT];
         mListener = listener;
         mLogPrefix = "User[" + Integer.toString(userId) + "] ";
     }
 
-    void init() {
-        mDatabase.init();
+    void init(final long currentTimeMillis) {
+        mDatabase.init(currentTimeMillis);
 
         int nullCount = 0;
         for (int i = 0; i < mCurrentStats.length; i++) {
@@ -84,24 +87,25 @@
 
             // By calling loadActiveStats, we will
             // generate new stats for each bucket.
-            loadActiveStats();
+            loadActiveStats(currentTimeMillis, false);
         } else {
             // Set up the expiry date to be one day from the latest daily stat.
             // This may actually be today and we will rollover on the first event
             // that is reported.
             mDailyExpiryDate.setTimeInMillis(
                     mCurrentStats[UsageStatsManager.INTERVAL_DAILY].beginTime);
-            mDailyExpiryDate.add(Calendar.DAY_OF_YEAR, 1);
-            UsageStatsUtils.truncateDateTo(UsageStatsManager.INTERVAL_DAILY, mDailyExpiryDate);
-            Slog.i(TAG, mLogPrefix + "Rollover scheduled for "
-                    + sDateFormat.format(mDailyExpiryDate.getTime()));
+            mDailyExpiryDate.addDays(1);
+            mDailyExpiryDate.truncateToDay();
+            Slog.i(TAG, mLogPrefix + "Rollover scheduled @ " +
+                    sDateFormat.format(mDailyExpiryDate.getTimeInMillis()) +
+                    "(" + mDailyExpiryDate.getTimeInMillis() + ")");
         }
 
         // Now close off any events that were open at the time this was saved.
         for (IntervalStats stat : mCurrentStats) {
-            final int pkgCount = stat.stats.size();
+            final int pkgCount = stat.packageStats.size();
             for (int i = 0; i < pkgCount; i++) {
-                UsageStats pkgStats = stat.stats.valueAt(i);
+                UsageStats pkgStats = stat.packageStats.valueAt(i);
                 if (pkgStats.mLastEvent == UsageEvents.Event.MOVE_TO_FOREGROUND ||
                         pkgStats.mLastEvent == UsageEvents.Event.CONTINUE_PREVIOUS_DAY) {
                     stat.update(pkgStats.mPackageName, stat.lastTimeSaved,
@@ -109,117 +113,208 @@
                     notifyStatsChanged();
                 }
             }
+
+            stat.updateConfigurationStats(null, stat.lastTimeSaved);
         }
     }
 
+    void onTimeChanged(long oldTime, long newTime) {
+        persistActiveStats();
+        mDatabase.onTimeChanged(newTime - oldTime);
+        loadActiveStats(newTime, true);
+    }
+
     void reportEvent(UsageEvents.Event event) {
         if (DEBUG) {
-            Slog.d(TAG, mLogPrefix + "Got usage event for " + event.getComponent().getPackageName()
-                    + "[" + event.getTimeStamp() + "]: "
-                    + eventToString(event.getEventType()));
+            Slog.d(TAG, mLogPrefix + "Got usage event for " + event.mPackage
+                    + "[" + event.mTimeStamp + "]: "
+                    + eventToString(event.mEventType));
         }
 
-        if (event.getTimeStamp() >= mDailyExpiryDate.getTimeInMillis()) {
+        if (event.mTimeStamp >= mDailyExpiryDate.getTimeInMillis()) {
             // Need to rollover
-            rolloverStats();
+            rolloverStats(event.mTimeStamp);
         }
 
-        if (mCurrentStats[UsageStatsManager.INTERVAL_DAILY].events == null) {
-            mCurrentStats[UsageStatsManager.INTERVAL_DAILY].events = new TimeSparseArray<>();
+        final IntervalStats currentDailyStats = mCurrentStats[UsageStatsManager.INTERVAL_DAILY];
+
+        final Configuration newFullConfig = event.mConfiguration;
+        if (event.mEventType == UsageEvents.Event.CONFIGURATION_CHANGE &&
+                currentDailyStats.activeConfiguration != null) {
+            // Make the event configuration a delta.
+            event.mConfiguration = Configuration.generateDelta(
+                    currentDailyStats.activeConfiguration, newFullConfig);
         }
-        mCurrentStats[UsageStatsManager.INTERVAL_DAILY].events.put(event.getTimeStamp(), event);
+
+        // Add the event to the daily list.
+        if (currentDailyStats.events == null) {
+            currentDailyStats.events = new TimeSparseArray<>();
+        }
+        currentDailyStats.events.put(event.mTimeStamp, event);
 
         for (IntervalStats stats : mCurrentStats) {
-            stats.update(event.getComponent().getPackageName(), event.getTimeStamp(),
-                    event.getEventType());
+            if (event.mEventType == UsageEvents.Event.CONFIGURATION_CHANGE) {
+                stats.updateConfigurationStats(newFullConfig, event.mTimeStamp);
+            } else {
+                stats.update(event.mPackage, event.mTimeStamp, event.mEventType);
+            }
         }
 
         notifyStatsChanged();
     }
 
-    List<UsageStats> queryUsageStats(int bucketType, long beginTime, long endTime) {
-        if (bucketType == UsageStatsManager.INTERVAL_BEST) {
-            bucketType = mDatabase.findBestFitBucket(beginTime, endTime);
+    private static final StatCombiner<UsageStats> sUsageStatsCombiner =
+            new StatCombiner<UsageStats>() {
+                @Override
+                public void combine(IntervalStats stats, boolean mutable,
+                        List<UsageStats> accResult) {
+                    if (!mutable) {
+                        accResult.addAll(stats.packageStats.values());
+                        return;
+                    }
+
+                    final int statCount = stats.packageStats.size();
+                    for (int i = 0; i < statCount; i++) {
+                        accResult.add(new UsageStats(stats.packageStats.valueAt(i)));
+                    }
+                }
+            };
+
+    private static final StatCombiner<ConfigurationStats> sConfigStatsCombiner =
+            new StatCombiner<ConfigurationStats>() {
+                @Override
+                public void combine(IntervalStats stats, boolean mutable,
+                        List<ConfigurationStats> accResult) {
+                    if (!mutable) {
+                        accResult.addAll(stats.configurations.values());
+                        return;
+                    }
+
+                    final int configCount = stats.configurations.size();
+                    for (int i = 0; i < configCount; i++) {
+                        accResult.add(new ConfigurationStats(stats.configurations.valueAt(i)));
+                    }
+                }
+            };
+
+    /**
+     * Generic query method that selects the appropriate IntervalStats for the specified time range
+     * and bucket, then calls the {@link com.android.server.usage.UsageStatsDatabase.StatCombiner}
+     * provided to select the stats to use from the IntervalStats object.
+     */
+    private <T> List<T> queryStats(int intervalType, final long beginTime, final long endTime,
+            StatCombiner<T> combiner) {
+        if (intervalType == UsageStatsManager.INTERVAL_BEST) {
+            intervalType = mDatabase.findBestFitBucket(beginTime, endTime);
+            if (intervalType < 0) {
+                // Nothing saved to disk yet, so every stat is just as equal (no rollover has
+                // occurred.
+                intervalType = UsageStatsManager.INTERVAL_DAILY;
+            }
         }
 
-        if (bucketType < 0 || bucketType >= mCurrentStats.length) {
+        if (intervalType < 0 || intervalType >= mCurrentStats.length) {
             if (DEBUG) {
-                Slog.d(TAG, mLogPrefix + "Bad bucketType used " + bucketType);
+                Slog.d(TAG, mLogPrefix + "Bad intervalType used " + intervalType);
             }
             return null;
         }
 
-        if (beginTime >= mCurrentStats[bucketType].endTime) {
-            if (DEBUG) {
-                Slog.d(TAG, mLogPrefix + "Requesting stats after " + beginTime + " but latest is "
-                        + mCurrentStats[bucketType].endTime);
-            }
-            // Nothing newer available.
-            return null;
-
-        } else if (beginTime >= mCurrentStats[bucketType].beginTime) {
-            if (DEBUG) {
-                Slog.d(TAG, mLogPrefix + "Returning in-memory stats for bucket " + bucketType);
-            }
-            // Fast path for retrieving in-memory state.
-            ArrayList<UsageStats> results = new ArrayList<>();
-            final int packageCount = mCurrentStats[bucketType].stats.size();
-            for (int i = 0; i < packageCount; i++) {
-                results.add(new UsageStats(mCurrentStats[bucketType].stats.valueAt(i)));
-            }
-            return results;
-        }
-
-        // Flush any changes that were made to disk before we do a disk query.
-        // If we're not grabbing the ongoing stats, no need to persist.
-        persistActiveStats();
+        final IntervalStats currentStats = mCurrentStats[intervalType];
 
         if (DEBUG) {
-            Slog.d(TAG, mLogPrefix + "SELECT * FROM " + bucketType + " WHERE beginTime >= "
+            Slog.d(TAG, mLogPrefix + "SELECT * FROM " + intervalType + " WHERE beginTime >= "
                     + beginTime + " AND endTime < " + endTime);
         }
 
-        final List<UsageStats> results = mDatabase.queryUsageStats(bucketType, beginTime, endTime);
+        if (beginTime >= currentStats.endTime) {
+            if (DEBUG) {
+                Slog.d(TAG, mLogPrefix + "Requesting stats after " + beginTime + " but latest is "
+                        + currentStats.endTime);
+            }
+            // Nothing newer available.
+            return null;
+        }
+
+        // Truncate the endTime to just before the in-memory stats. Then, we'll append the
+        // in-memory stats to the results (if necessary) so as to avoid writing to disk too
+        // often.
+        final long truncatedEndTime = Math.min(currentStats.beginTime, endTime);
+
+        // Get the stats from disk.
+        List<T> results = mDatabase.queryUsageStats(intervalType, beginTime,
+                truncatedEndTime, combiner);
         if (DEBUG) {
-            Slog.d(TAG, mLogPrefix + "Results: " + (results == null ? 0 : results.size()));
+            Slog.d(TAG, "Got " + (results != null ? results.size() : 0) + " results from disk");
+            Slog.d(TAG, "Current stats beginTime=" + currentStats.beginTime +
+                    " endTime=" + currentStats.endTime);
+        }
+
+        // Now check if the in-memory stats match the range and add them if they do.
+        if (beginTime < currentStats.endTime && endTime > currentStats.beginTime) {
+            if (DEBUG) {
+                Slog.d(TAG, mLogPrefix + "Returning in-memory stats");
+            }
+
+            if (results == null) {
+                results = new ArrayList<>();
+            }
+            combiner.combine(currentStats, true, results);
+        }
+
+        if (DEBUG) {
+            Slog.d(TAG, mLogPrefix + "Results: " + (results != null ? results.size() : 0));
         }
         return results;
     }
 
-    UsageEvents queryEvents(long beginTime, long endTime) {
-        if (endTime > mCurrentStats[UsageStatsManager.INTERVAL_DAILY].beginTime) {
-            if (beginTime > mCurrentStats[UsageStatsManager.INTERVAL_DAILY].endTime) {
-                return null;
-            }
+    List<UsageStats> queryUsageStats(int bucketType, long beginTime, long endTime) {
+        return queryStats(bucketType, beginTime, endTime, sUsageStatsCombiner);
+    }
 
-            TimeSparseArray<UsageEvents.Event> events =
-                    mCurrentStats[UsageStatsManager.INTERVAL_DAILY].events;
-            if (events == null) {
-                return null;
-            }
+    List<ConfigurationStats> queryConfigurationStats(int bucketType, long beginTime, long endTime) {
+        return queryStats(bucketType, beginTime, endTime, sConfigStatsCombiner);
+    }
 
-            final int startIndex = events.closestIndexOnOrAfter(beginTime);
-            if (startIndex < 0) {
-                return null;
-            }
+    UsageEvents queryEvents(final long beginTime, final long endTime) {
+        final ArraySet<String> names = new ArraySet<>();
+        List<UsageEvents.Event> results = queryStats(UsageStatsManager.INTERVAL_DAILY,
+                beginTime, endTime, new StatCombiner<UsageEvents.Event>() {
+                    @Override
+                    public void combine(IntervalStats stats, boolean mutable,
+                            List<UsageEvents.Event> accumulatedResult) {
+                        if (stats.events == null) {
+                            return;
+                        }
 
-            ArraySet<ComponentName> names = new ArraySet<>();
-            ArrayList<UsageEvents.Event> results = new ArrayList<>();
-            final int size = events.size();
-            for (int i = startIndex; i < size; i++) {
-                if (events.keyAt(i) >= endTime) {
-                    break;
-                }
-                names.add(events.valueAt(i).getComponent());
-                results.add(events.valueAt(i));
-            }
-            ComponentName[] table = names.toArray(new ComponentName[names.size()]);
-            Arrays.sort(table);
-            return new UsageEvents(results, table);
+                        final int startIndex = stats.events.closestIndexOnOrAfter(beginTime);
+                        if (startIndex < 0) {
+                            return;
+                        }
+
+                        final int size = stats.events.size();
+                        for (int i = startIndex; i < size; i++) {
+                            if (stats.events.keyAt(i) >= endTime) {
+                                return;
+                            }
+
+                            final UsageEvents.Event event = stats.events.valueAt(i);
+                            names.add(event.mPackage);
+                            if (event.mClass != null) {
+                                names.add(event.mClass);
+                            }
+                            accumulatedResult.add(event);
+                        }
+                    }
+                });
+
+        if (results == null || results.isEmpty()) {
+            return null;
         }
 
-        // TODO(adamlesinski): Query the previous days.
-        return null;
+        String[] table = names.toArray(new String[names.size()]);
+        Arrays.sort(table);
+        return new UsageEvents(results, table);
     }
 
     void persistActiveStats() {
@@ -236,43 +331,48 @@
         }
     }
 
-    private void rolloverStats() {
-        final long startTime = System.currentTimeMillis();
+    private void rolloverStats(final long currentTimeMillis) {
+        final long startTime = SystemClock.elapsedRealtime();
         Slog.i(TAG, mLogPrefix + "Rolling over usage stats");
 
         // Finish any ongoing events with an END_OF_DAY event. Make a note of which components
         // need a new CONTINUE_PREVIOUS_DAY entry.
+        final Configuration previousConfig =
+                mCurrentStats[UsageStatsManager.INTERVAL_DAILY].activeConfiguration;
         ArraySet<String> continuePreviousDay = new ArraySet<>();
         for (IntervalStats stat : mCurrentStats) {
-            final int pkgCount = stat.stats.size();
+            final int pkgCount = stat.packageStats.size();
             for (int i = 0; i < pkgCount; i++) {
-                UsageStats pkgStats = stat.stats.valueAt(i);
+                UsageStats pkgStats = stat.packageStats.valueAt(i);
                 if (pkgStats.mLastEvent == UsageEvents.Event.MOVE_TO_FOREGROUND ||
                         pkgStats.mLastEvent == UsageEvents.Event.CONTINUE_PREVIOUS_DAY) {
                     continuePreviousDay.add(pkgStats.mPackageName);
-                    stat.update(pkgStats.mPackageName,
-                            mDailyExpiryDate.getTimeInMillis() - 1, UsageEvents.Event.END_OF_DAY);
-                    mStatsChanged = true;
+                    stat.update(pkgStats.mPackageName, mDailyExpiryDate.getTimeInMillis() - 1,
+                            UsageEvents.Event.END_OF_DAY);
+                    notifyStatsChanged();
                 }
             }
+
+            stat.updateConfigurationStats(null, mDailyExpiryDate.getTimeInMillis() - 1);
         }
 
         persistActiveStats();
-        mDatabase.prune();
-        loadActiveStats();
+        mDatabase.prune(currentTimeMillis);
+        loadActiveStats(currentTimeMillis, false);
 
         final int continueCount = continuePreviousDay.size();
         for (int i = 0; i < continueCount; i++) {
             String name = continuePreviousDay.valueAt(i);
+            final long beginTime = mCurrentStats[UsageStatsManager.INTERVAL_DAILY].beginTime;
             for (IntervalStats stat : mCurrentStats) {
-                stat.update(name, mCurrentStats[UsageStatsManager.INTERVAL_DAILY].beginTime,
-                        UsageEvents.Event.CONTINUE_PREVIOUS_DAY);
-                mStatsChanged = true;
+                stat.update(name, beginTime, UsageEvents.Event.CONTINUE_PREVIOUS_DAY);
+                stat.updateConfigurationStats(previousConfig, beginTime);
+                notifyStatsChanged();
             }
         }
         persistActiveStats();
 
-        final long totalTime = System.currentTimeMillis() - startTime;
+        final long totalTime = SystemClock.elapsedRealtime() - startTime;
         Slog.i(TAG, mLogPrefix + "Rolling over usage stats complete. Took " + totalTime
                 + " milliseconds");
     }
@@ -284,57 +384,53 @@
         }
     }
 
-    private void loadActiveStats() {
-        final long timeNow = System.currentTimeMillis();
+    /**
+     * @param force To force all in-memory stats to be reloaded.
+     */
+    private void loadActiveStats(final long currentTimeMillis, boolean force) {
+        final UnixCalendar tempCal = mDailyExpiryDate;
+        for (int intervalType = 0; intervalType < mCurrentStats.length; intervalType++) {
+            tempCal.setTimeInMillis(currentTimeMillis);
+            UnixCalendar.truncateTo(tempCal, intervalType);
 
-        Calendar tempCal = mDailyExpiryDate;
-        for (int bucketType = 0; bucketType < mCurrentStats.length; bucketType++) {
-            tempCal.setTimeInMillis(timeNow);
-            UsageStatsUtils.truncateDateTo(bucketType, tempCal);
-
-            if (mCurrentStats[bucketType] != null &&
-                    mCurrentStats[bucketType].beginTime == tempCal.getTimeInMillis()) {
+            if (!force && mCurrentStats[intervalType] != null &&
+                    mCurrentStats[intervalType].beginTime == tempCal.getTimeInMillis()) {
                 // These are the same, no need to load them (in memory stats are always newer
                 // than persisted stats).
                 continue;
             }
 
-            final long lastBeginTime = mDatabase.getLatestUsageStatsBeginTime(bucketType);
+            final long lastBeginTime = mDatabase.getLatestUsageStatsBeginTime(intervalType);
             if (lastBeginTime >= tempCal.getTimeInMillis()) {
                 if (DEBUG) {
-                    Slog.d(TAG, mLogPrefix + "Loading existing stats (" + lastBeginTime +
-                            ") for bucket " + bucketType);
+                    Slog.d(TAG, mLogPrefix + "Loading existing stats @ " +
+                            sDateFormat.format(lastBeginTime) + "(" + lastBeginTime +
+                            ") for interval " + intervalType);
                 }
-                mCurrentStats[bucketType] = mDatabase.getLatestUsageStats(bucketType);
-                if (DEBUG) {
-                    if (mCurrentStats[bucketType] != null) {
-                        Slog.d(TAG, mLogPrefix + "Found " +
-                                (mCurrentStats[bucketType].events == null ?
-                                        0 : mCurrentStats[bucketType].events.size()) +
-                                " events");
-                    }
-                }
+                mCurrentStats[intervalType] = mDatabase.getLatestUsageStats(intervalType);
             } else {
-                mCurrentStats[bucketType] = null;
+                mCurrentStats[intervalType] = null;
             }
 
-            if (mCurrentStats[bucketType] == null) {
+            if (mCurrentStats[intervalType] == null) {
                 if (DEBUG) {
-                    Slog.d(TAG, "Creating new stats (" + tempCal.getTimeInMillis() +
-                            ") for bucket " + bucketType);
+                    Slog.d(TAG, "Creating new stats @ " +
+                            sDateFormat.format(tempCal.getTimeInMillis()) + "(" +
+                            tempCal.getTimeInMillis() + ") for interval " + intervalType);
 
                 }
-                mCurrentStats[bucketType] = new IntervalStats();
-                mCurrentStats[bucketType].beginTime = tempCal.getTimeInMillis();
-                mCurrentStats[bucketType].endTime = timeNow;
+                mCurrentStats[intervalType] = new IntervalStats();
+                mCurrentStats[intervalType].beginTime = tempCal.getTimeInMillis();
+                mCurrentStats[intervalType].endTime = currentTimeMillis;
             }
         }
         mStatsChanged = false;
-        mDailyExpiryDate.setTimeInMillis(timeNow);
-        mDailyExpiryDate.add(Calendar.DAY_OF_YEAR, 1);
-        UsageStatsUtils.truncateDateTo(UsageStatsManager.INTERVAL_DAILY, mDailyExpiryDate);
-        Slog.i(TAG, mLogPrefix + "Rollover scheduled for "
-                + sDateFormat.format(mDailyExpiryDate.getTime()));
+        mDailyExpiryDate.setTimeInMillis(currentTimeMillis);
+        mDailyExpiryDate.addDays(1);
+        mDailyExpiryDate.truncateToDay();
+        Slog.i(TAG, mLogPrefix + "Rollover scheduled @ " +
+                sDateFormat.format(mDailyExpiryDate.getTimeInMillis()) + "(" +
+                tempCal.getTimeInMillis() + ")");
     }
 
 
@@ -350,6 +446,8 @@
                 return "END_OF_DAY";
             case UsageEvents.Event.CONTINUE_PREVIOUS_DAY:
                 return "CONTINUE_PREVIOUS_DAY";
+            case UsageEvents.Event.CONFIGURATION_CHANGE:
+                return "CONFIGURATION_CHANGE";
             default:
                 return "UNKNOWN";
         }
diff --git a/services/usb/java/com/android/server/usb/UsbDeviceManager.java b/services/usb/java/com/android/server/usb/UsbDeviceManager.java
index c0923ca..c63eb18 100644
--- a/services/usb/java/com/android/server/usb/UsbDeviceManager.java
+++ b/services/usb/java/com/android/server/usb/UsbDeviceManager.java
@@ -30,6 +30,7 @@
 import android.database.ContentObserver;
 import android.hardware.usb.UsbAccessory;
 import android.hardware.usb.UsbManager;
+import android.media.AudioManager;
 import android.os.FileUtils;
 import android.os.Handler;
 import android.os.Looper;
@@ -587,7 +588,7 @@
                     UsbManager.USB_FUNCTION_AUDIO_SOURCE);
             if (enabled != mAudioSourceEnabled) {
                 // send a sticky broadcast containing current USB state
-                Intent intent = new Intent(Intent.ACTION_USB_AUDIO_ACCESSORY_PLUG);
+                Intent intent = new Intent(AudioManager.ACTION_USB_AUDIO_ACCESSORY_PLUG);
                 intent.addFlags(Intent.FLAG_RECEIVER_REPLACE_PENDING);
                 intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY);
                 intent.putExtra("state", (enabled ? 1 : 0));
@@ -732,6 +733,8 @@
                                     "com.android.settings.UsbSettings"));
                     PendingIntent pi = PendingIntent.getActivityAsUser(mContext, 0,
                             intent, 0, null, UserHandle.CURRENT);
+                    notification.color = mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color);
                     notification.setLatestEventInfo(mContext, title, message, pi);
                     notification.visibility = Notification.VISIBILITY_PUBLIC;
                     mNotificationManager.notifyAsUser(null, id, notification,
@@ -768,6 +771,8 @@
                                     "com.android.settings.DevelopmentSettings"));
                     PendingIntent pi = PendingIntent.getActivityAsUser(mContext, 0,
                             intent, 0, null, UserHandle.CURRENT);
+                    notification.color = mContext.getResources().getColor(
+                            com.android.internal.R.color.system_notification_accent_color);
                     notification.setLatestEventInfo(mContext, title, message, pi);
                     notification.visibility = Notification.VISIBILITY_PUBLIC;
                     mAdbNotificationShown = true;
diff --git a/services/usb/java/com/android/server/usb/UsbHostManager.java b/services/usb/java/com/android/server/usb/UsbHostManager.java
index 5860fc7..06febb3 100644
--- a/services/usb/java/com/android/server/usb/UsbHostManager.java
+++ b/services/usb/java/com/android/server/usb/UsbHostManager.java
@@ -25,6 +25,7 @@
 import android.hardware.usb.UsbDevice;
 import android.hardware.usb.UsbEndpoint;
 import android.hardware.usb.UsbInterface;
+import android.media.AudioManager;
 import android.os.Bundle;
 import android.os.ParcelFileDescriptor;
 import android.os.Parcelable;
@@ -124,7 +125,7 @@
     private void sendDeviceNotification(int card, int device, boolean enabled,
             boolean hasPlayback, boolean hasCapture, boolean hasMIDI) {
         // send a sticky broadcast containing current USB state
-        Intent intent = new Intent(Intent.ACTION_USB_AUDIO_DEVICE_PLUG);
+        Intent intent = new Intent(AudioManager.ACTION_USB_AUDIO_DEVICE_PLUG);
         intent.addFlags(Intent.FLAG_RECEIVER_REPLACE_PENDING);
         intent.addFlags(Intent.FLAG_RECEIVER_REGISTERED_ONLY);
         intent.putExtra("state", enabled ? 1 : 0);
diff --git a/services/voiceinteraction/java/com/android/server/voiceinteraction/DatabaseHelper.java b/services/voiceinteraction/java/com/android/server/voiceinteraction/DatabaseHelper.java
index cc0d8df..9c15f2b 100644
--- a/services/voiceinteraction/java/com/android/server/voiceinteraction/DatabaseHelper.java
+++ b/services/voiceinteraction/java/com/android/server/voiceinteraction/DatabaseHelper.java
@@ -24,10 +24,10 @@
 import android.hardware.soundtrigger.SoundTrigger;
 import android.hardware.soundtrigger.SoundTrigger.Keyphrase;
 import android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel;
-import android.os.UserManager;
 import android.text.TextUtils;
 import android.util.Slog;
 
+import java.util.Locale;
 import java.util.UUID;
 
 /**
@@ -37,8 +37,7 @@
  */
 public class DatabaseHelper extends SQLiteOpenHelper {
     static final String TAG = "SoundModelDBHelper";
-    // TODO: Set to false.
-    static final boolean DBG = true;
+    static final boolean DBG = false;
 
     private static final String NAME = "sound_model.db";
     private static final int VERSION = 4;
@@ -67,11 +66,8 @@
             + SoundModelContract.KEY_HINT_TEXT + " TEXT,"
             + SoundModelContract.KEY_USERS + " TEXT" + ")";
 
-    private final UserManager mUserManager;
-
     public DatabaseHelper(Context context) {
         super(context, NAME, null, VERSION);
-        mUserManager = (UserManager) context.getSystemService(Context.USER_SERVICE);
     }
 
     @Override
@@ -122,17 +118,20 @@
     /**
      * Deletes the sound model and associated keyphrases.
      */
-    public boolean deleteKeyphraseSoundModel(UUID modelUuid) {
-        if (modelUuid == null) {
-            Slog.w(TAG, "Model UUID must be specified for deletion");
-            return false;
-        }
-
+    public boolean deleteKeyphraseSoundModel(int keyphraseId, int userHandle, String bcp47Locale) {
+        // Sanitize the locale to guard against SQL injection.
+        bcp47Locale = Locale.forLanguageTag(bcp47Locale).toLanguageTag();
         synchronized(this) {
-            SQLiteDatabase db = getWritableDatabase();
-            String soundModelClause = SoundModelContract.KEY_MODEL_UUID + "='"
-                    + modelUuid.toString() + "'";
+            KeyphraseSoundModel soundModel = getKeyphraseSoundModel(keyphraseId, userHandle,
+                    bcp47Locale);
+            if (soundModel == null) {
+                return false;
+            }
 
+            // Delete all sound models for the given keyphrase and specified user.
+            SQLiteDatabase db = getWritableDatabase();
+            String soundModelClause = SoundModelContract.KEY_MODEL_UUID
+                    + "='" + soundModel.uuid.toString() + "'";
             try {
                 return db.delete(SoundModelContract.TABLE, soundModelClause, null) != 0;
             } finally {
@@ -147,11 +146,15 @@
      *
      * TODO: We only support one keyphrase currently.
      */
-    public KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId) {
+    public KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId, int userHandle,
+            String bcp47Locale) {
+        // Sanitize the locale to guard against SQL injection.
+        bcp47Locale = Locale.forLanguageTag(bcp47Locale).toLanguageTag();
         synchronized(this) {
             // Find the corresponding sound model ID for the keyphrase.
             String selectQuery = "SELECT  * FROM " + SoundModelContract.TABLE
-                    + " WHERE " + SoundModelContract.KEY_KEYPHRASE_ID + " = '" + keyphraseId + "'";
+                    + " WHERE " + SoundModelContract.KEY_KEYPHRASE_ID + "= '" + keyphraseId
+                    + "' AND " + SoundModelContract.KEY_LOCALE + "='" + bcp47Locale + "'";
             SQLiteDatabase db = getReadableDatabase();
             Cursor c = db.rawQuery(selectQuery, null);
 
@@ -160,14 +163,16 @@
                     do {
                         int type = c.getInt(c.getColumnIndex(SoundModelContract.KEY_TYPE));
                         if (type != SoundTrigger.SoundModel.TYPE_KEYPHRASE) {
-                            Slog.w(TAG, "Ignoring sound model since it's type is incorrect");
+                            if (DBG) {
+                                Slog.w(TAG, "Ignoring SoundModel since it's type is incorrect");
+                            }
                             continue;
                         }
 
                         String modelUuid = c.getString(
                                 c.getColumnIndex(SoundModelContract.KEY_MODEL_UUID));
                         if (modelUuid == null) {
-                            Slog.w(TAG, "Ignoring sound model since it doesn't specify an ID");
+                            Slog.w(TAG, "Ignoring SoundModel since it doesn't specify an ID");
                             continue;
                         }
 
@@ -176,7 +181,7 @@
                                 c.getColumnIndex(SoundModelContract.KEY_RECOGNITION_MODES));
                         int[] users = getArrayForCommaSeparatedString(
                                 c.getString(c.getColumnIndex(SoundModelContract.KEY_USERS)));
-                        String locale = c.getString(
+                        String modelLocale = c.getString(
                                 c.getColumnIndex(SoundModelContract.KEY_LOCALE));
                         String text = c.getString(
                                 c.getColumnIndex(SoundModelContract.KEY_HINT_TEXT));
@@ -184,28 +189,37 @@
                         // Only add keyphrases meant for the current user.
                         if (users == null) {
                             // No users present in the keyphrase.
-                            Slog.w(TAG, "Ignoring keyphrase since it doesn't specify users");
+                            Slog.w(TAG, "Ignoring SoundModel since it doesn't specify users");
                             continue;
                         }
 
                         boolean isAvailableForCurrentUser = false;
-                        int currentUser = mUserManager.getUserHandle();
                         for (int user : users) {
-                            if (currentUser == user) {
+                            if (userHandle == user) {
                                 isAvailableForCurrentUser = true;
                                 break;
                             }
                         }
                         if (!isAvailableForCurrentUser) {
-                            Slog.w(TAG, "Ignoring keyphrase since it's not for the current user");
+                            if (DBG) {
+                                Slog.w(TAG, "Ignoring SoundModel since user handles don't match");
+                            }
                             continue;
+                        } else {
+                            if (DBG) Slog.d(TAG, "Found a SoundModel for user: " + userHandle);
                         }
 
                         Keyphrase[] keyphrases = new Keyphrase[1];
                         keyphrases[0] = new Keyphrase(
-                                keyphraseId, recognitionModes, locale, text, users);
-                        return new KeyphraseSoundModel(UUID.fromString(modelUuid),
+                                keyphraseId, recognitionModes, modelLocale, text, users);
+                        KeyphraseSoundModel model = new KeyphraseSoundModel(
+                                UUID.fromString(modelUuid),
                                 null /* FIXME use vendor UUID */, data, keyphrases);
+                        if (DBG) {
+                            Slog.d(TAG, "Found SoundModel for the given keyphrase/locale/user: "
+                                    + model);
+                        }
+                        return model;
                     } while (c.moveToNext());
                 }
                 Slog.w(TAG, "No SoundModel available for the given keyphrase");
@@ -218,15 +232,17 @@
     }
 
     private static String getCommaSeparatedString(int[] users) {
-        if (users == null || users.length == 0) {
+        if (users == null) {
             return "";
         }
-        String csv = "";
-        for (int user : users) {
-            csv += String.valueOf(user);
-            csv += ",";
+        StringBuilder sb = new StringBuilder();
+        for (int i = 0; i < users.length; i++) {
+            if (i != 0) {
+                sb.append(',');
+            }
+            sb.append(users[i]);
         }
-        return csv.substring(0, csv.length() - 1);
+        return sb.toString();
     }
 
     private static int[] getArrayForCommaSeparatedString(String text) {
diff --git a/services/voiceinteraction/java/com/android/server/voiceinteraction/SoundTriggerHelper.java b/services/voiceinteraction/java/com/android/server/voiceinteraction/SoundTriggerHelper.java
index 3a64984..8ce7f74 100644
--- a/services/voiceinteraction/java/com/android/server/voiceinteraction/SoundTriggerHelper.java
+++ b/services/voiceinteraction/java/com/android/server/voiceinteraction/SoundTriggerHelper.java
@@ -16,6 +16,10 @@
 
 package com.android.server.voiceinteraction;
 
+import android.content.BroadcastReceiver;
+import android.content.Context;
+import android.content.Intent;
+import android.content.IntentFilter;
 import android.hardware.soundtrigger.IRecognitionStatusCallback;
 import android.hardware.soundtrigger.SoundTrigger;
 import android.hardware.soundtrigger.SoundTrigger.Keyphrase;
@@ -27,6 +31,7 @@
 import android.hardware.soundtrigger.SoundTrigger.RecognitionEvent;
 import android.hardware.soundtrigger.SoundTrigger.SoundModelEvent;
 import android.hardware.soundtrigger.SoundTriggerModule;
+import android.os.PowerManager;
 import android.os.RemoteException;
 import android.telephony.PhoneStateListener;
 import android.telephony.TelephonyManager;
@@ -45,8 +50,7 @@
  */
 public class SoundTriggerHelper implements SoundTrigger.StatusListener {
     static final String TAG = "SoundTriggerHelper";
-    // TODO: Set to false.
-    static final boolean DBG = true;
+    static final boolean DBG = false;
 
     /**
      * Return codes for {@link #startRecognition(int, KeyphraseSoundModel,
@@ -62,10 +66,12 @@
     final ModuleProperties moduleProperties;
 
     /** The properties for the DSP module */
-    private final SoundTriggerModule mModule;
+    private SoundTriggerModule mModule;
     private final Object mLock = new Object();
+    private final Context mContext;
     private final TelephonyManager mTelephonyManager;
     private final PhoneStateListener mPhoneStateListener;
+    private final PowerManager mPowerManager;
 
     // TODO: Since many layers currently only deal with one recognition
     // we simplify things by assuming one listener here too.
@@ -77,15 +83,19 @@
     private RecognitionConfig mRecognitionConfig = null;
     private boolean mRequested = false;
     private boolean mCallActive = false;
+    private boolean mIsPowerSaveMode = false;
     // Indicates if the native sound trigger service is disabled or not.
     // This is an indirect indication of the microphone being open in some other application.
     private boolean mServiceDisabled = false;
     private boolean mStarted = false;
+    private PowerSaveModeListener mPowerSaveModeListener;
 
-    SoundTriggerHelper(TelephonyManager telephonyManager) {
+    SoundTriggerHelper(Context context) {
         ArrayList <ModuleProperties> modules = new ArrayList<>();
         int status = SoundTrigger.listModules(modules);
-        mTelephonyManager = telephonyManager;
+        mContext = context;
+        mTelephonyManager = (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE);
+        mPowerManager = (PowerManager) context.getSystemService(Context.POWER_SERVICE);
         mPhoneStateListener = new MyCallStateListener();
         if (status != SoundTrigger.STATUS_OK || modules.size() == 0) {
             Slog.w(TAG, "listModules status=" + status + ", # of modules=" + modules.size());
@@ -94,7 +104,6 @@
         } else {
             // TODO: Figure out how to determine which module corresponds to the DSP hardware.
             moduleProperties = modules.get(0);
-            mModule = SoundTrigger.attachModule(moduleProperties.id, this, null);
         }
     }
 
@@ -133,15 +142,37 @@
                 mCallActive = mTelephonyManager.getCallState() != TelephonyManager.CALL_STATE_IDLE;
                 // Register for call state changes when the first call to start recognition occurs.
                 mTelephonyManager.listen(mPhoneStateListener, PhoneStateListener.LISTEN_CALL_STATE);
+
+                // Register for power saver mode changes when the first call to start recognition
+                // occurs.
+                if (mPowerSaveModeListener == null) {
+                    mPowerSaveModeListener = new PowerSaveModeListener();
+                    mContext.registerReceiver(mPowerSaveModeListener,
+                            new IntentFilter(PowerManager.ACTION_POWER_SAVE_MODE_CHANGED));
+                }
+                mIsPowerSaveMode = mPowerManager.isPowerSaveMode();
             }
 
-            if (moduleProperties == null || mModule == null) {
+            if (moduleProperties == null) {
                 Slog.w(TAG, "Attempting startRecognition without the capability");
                 return STATUS_ERROR;
             }
+            if (mModule == null) {
+                mModule = SoundTrigger.attachModule(moduleProperties.id, this, null);
+                if (mModule == null) {
+                    Slog.w(TAG, "startRecognition cannot attach to sound trigger module");
+                    return STATUS_ERROR;
+                }
+            }
 
+            // Unload the previous model if the current one isn't invalid
+            // and, it's not the same as the new one, or we are already started
+            // if we are already started, we can get multiple calls to start
+            // if the underlying sound model changes, in which case we should unload and reload.
+            // The model reuse helps only in cases when we trigger and stop internally
+            // without a start recognition call.
             if (mCurrentSoundModelHandle != INVALID_VALUE
-                    && !soundModel.uuid.equals(mCurrentSoundModelUuid)) {
+                    && (!soundModel.uuid.equals(mCurrentSoundModelUuid) || mStarted)) {
                 Slog.w(TAG, "Unloading previous sound model");
                 int status = mModule.unloadSoundModel(mCurrentSoundModelHandle);
                 if (status != SoundTrigger.STATUS_OK) {
@@ -338,16 +369,6 @@
         }
     }
 
-    class MyCallStateListener extends PhoneStateListener {
-        @Override
-        public void onCallStateChanged(int state, String arg1) {
-            if (DBG) Slog.d(TAG, "onCallStateChanged: " + state);
-            synchronized (mLock) {
-                onCallStateChangedLocked(TelephonyManager.CALL_STATE_IDLE != state);
-            }
-        }
-    }
-
     private void onCallStateChangedLocked(boolean callActive) {
         if (mCallActive == callActive) {
             // We consider multiple call states as being active
@@ -358,6 +379,14 @@
         updateRecognitionLocked(true /* notify */);
     }
 
+    private void onPowerSaveModeChangedLocked(boolean isPowerSaveMode) {
+        if (mIsPowerSaveMode == isPowerSaveMode) {
+            return;
+        }
+        mIsPowerSaveMode = isPowerSaveMode;
+        updateRecognitionLocked(true /* notify */);
+    }
+
     private void onSoundModelUpdatedLocked(SoundModelEvent event) {
         // TODO: Handle sound model update here.
     }
@@ -428,6 +457,10 @@
             Slog.w(TAG, "RemoteException in onError", e);
         } finally {
             internalClearStateLocked();
+            if (mModule != null) {
+                mModule.detach();
+                mModule = null;
+            }
         }
     }
 
@@ -438,7 +471,7 @@
             return STATUS_OK;
         }
 
-        boolean start = mRequested && !mCallActive && !mServiceDisabled;
+        boolean start = mRequested && !mCallActive && !mServiceDisabled && !mIsPowerSaveMode;
         if (start == mStarted) {
             // No-op.
             return STATUS_OK;
@@ -509,6 +542,36 @@
 
         // Unregister from call state changes.
         mTelephonyManager.listen(mPhoneStateListener, PhoneStateListener.LISTEN_NONE);
+
+        // Unregister from power save mode changes.
+        if (mPowerSaveModeListener != null) {
+            mContext.unregisterReceiver(mPowerSaveModeListener);
+            mPowerSaveModeListener = null;
+        }
+    }
+
+    class MyCallStateListener extends PhoneStateListener {
+        @Override
+        public void onCallStateChanged(int state, String arg1) {
+            if (DBG) Slog.d(TAG, "onCallStateChanged: " + state);
+            synchronized (mLock) {
+                onCallStateChangedLocked(TelephonyManager.CALL_STATE_IDLE != state);
+            }
+        }
+    }
+
+    class PowerSaveModeListener extends BroadcastReceiver {
+        @Override
+        public void onReceive(Context context, Intent intent) {
+            if (!PowerManager.ACTION_POWER_SAVE_MODE_CHANGED.equals(intent.getAction())) {
+                return;
+            }
+            boolean active = mPowerManager.isPowerSaveMode();
+            if (DBG) Slog.d(TAG, "onPowerSaveModeChanged: " + active);
+            synchronized (mLock) {
+                onPowerSaveModeChangedLocked(active);
+            }
+        }
     }
 
     void dump(FileDescriptor fd, PrintWriter pw, String[] args) {
@@ -525,6 +588,7 @@
             pw.print("  requested="); pw.println(mRequested);
             pw.print("  started="); pw.println(mStarted);
             pw.print("  call active="); pw.println(mCallActive);
+            pw.print("  power save mode active="); pw.println(mIsPowerSaveMode);
             pw.print("  service disabled="); pw.println(mServiceDisabled);
         }
     }
diff --git a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java
index a173a5c..82b7f8b 100644
--- a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java
+++ b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerService.java
@@ -39,6 +39,7 @@
 import android.os.IBinder;
 import android.os.Parcel;
 import android.os.RemoteException;
+import android.os.SystemProperties;
 import android.os.UserHandle;
 import android.provider.Settings;
 import android.service.voice.IVoiceInteractionService;
@@ -46,7 +47,6 @@
 import android.service.voice.VoiceInteractionService;
 import android.service.voice.VoiceInteractionServiceInfo;
 import android.speech.RecognitionService;
-import android.telephony.TelephonyManager;
 import android.text.TextUtils;
 import android.util.Slog;
 
@@ -78,8 +78,7 @@
         mContext = context;
         mResolver = context.getContentResolver();
         mDbHelper = new DatabaseHelper(context);
-        mSoundTriggerHelper = new SoundTriggerHelper(
-                (TelephonyManager) context.getSystemService(Context.TELEPHONY_SERVICE));
+        mSoundTriggerHelper = new SoundTriggerHelper(context);
     }
 
     @Override
@@ -414,6 +413,9 @@
                 final int callingPid = Binder.getCallingPid();
                 final int callingUid = Binder.getCallingUid();
                 final long caller = Binder.clearCallingIdentity();
+                if (!SystemProperties.getBoolean("persist.test.voice_interaction", false)) {
+                    throw new SecurityException("Voice interaction not supported");
+                }
                 try {
                     return mImpl.startVoiceActivityLocked(callingPid, callingUid, token,
                             intent, resolvedType);
@@ -444,7 +446,7 @@
         //----------------- Model management APIs --------------------------------//
 
         @Override
-        public KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId) {
+        public KeyphraseSoundModel getKeyphraseSoundModel(int keyphraseId, String bcp47Locale) {
             synchronized (this) {
                 if (mContext.checkCallingPermission(Manifest.permission.MANAGE_VOICE_KEYPHRASES)
                         != PackageManager.PERMISSION_GRANTED) {
@@ -453,9 +455,14 @@
                 }
             }
 
+            if (bcp47Locale == null) {
+                throw new IllegalArgumentException("Illegal argument(s) in getKeyphraseSoundModel");
+            }
+
+            final int callingUid = UserHandle.getCallingUserId();
             final long caller = Binder.clearCallingIdentity();
             try {
-                return mDbHelper.getKeyphraseSoundModel(keyphraseId);
+                return mDbHelper.getKeyphraseSoundModel(keyphraseId, callingUid, bcp47Locale);
             } finally {
                 Binder.restoreCallingIdentity(caller);
             }
@@ -493,7 +500,7 @@
         }
 
         @Override
-        public int deleteKeyphraseSoundModel(int keyphraseId) {
+        public int deleteKeyphraseSoundModel(int keyphraseId, String bcp47Locale) {
             synchronized (this) {
                 if (mContext.checkCallingPermission(Manifest.permission.MANAGE_VOICE_KEYPHRASES)
                         != PackageManager.PERMISSION_GRANTED) {
@@ -502,13 +509,16 @@
                 }
             }
 
+            if (bcp47Locale == null) {
+                throw new IllegalArgumentException(
+                        "Illegal argument(s) in deleteKeyphraseSoundModel");
+            }
+
+            final int callingUid = UserHandle.getCallingUserId();
             final long caller = Binder.clearCallingIdentity();
             boolean deleted = false;
             try {
-                KeyphraseSoundModel soundModel = mDbHelper.getKeyphraseSoundModel(keyphraseId);
-                if (soundModel != null) {
-                    deleted = mDbHelper.deleteKeyphraseSoundModel(soundModel.uuid);
-                }
+                deleted = mDbHelper.deleteKeyphraseSoundModel(keyphraseId, callingUid, bcp47Locale);
                 return deleted ? SoundTriggerHelper.STATUS_OK : SoundTriggerHelper.STATUS_ERROR;
             } finally {
                 if (deleted) {
@@ -525,7 +535,8 @@
 
         //----------------- SoundTrigger APIs --------------------------------//
         @Override
-        public boolean isEnrolledForKeyphrase(IVoiceInteractionService service, int keyphraseId) {
+        public boolean isEnrolledForKeyphrase(IVoiceInteractionService service, int keyphraseId,
+                String bcp47Locale) {
             synchronized (this) {
                 if (mImpl == null || mImpl.mService == null
                         || service.asBinder() != mImpl.mService.asBinder()) {
@@ -534,9 +545,15 @@
                 }
             }
 
+            if (bcp47Locale == null) {
+                throw new IllegalArgumentException("Illegal argument(s) in isEnrolledForKeyphrase");
+            }
+
+            final int callingUid = UserHandle.getCallingUserId();
             final long caller = Binder.clearCallingIdentity();
             try {
-                KeyphraseSoundModel model = mDbHelper.getKeyphraseSoundModel(keyphraseId);
+                KeyphraseSoundModel model =
+                        mDbHelper.getKeyphraseSoundModel(keyphraseId, callingUid, bcp47Locale);
                 return model != null;
             } finally {
                 Binder.restoreCallingIdentity(caller);
@@ -564,7 +581,8 @@
 
         @Override
         public int startRecognition(IVoiceInteractionService service, int keyphraseId,
-                IRecognitionStatusCallback callback, RecognitionConfig recognitionConfig) {
+                String bcp47Locale, IRecognitionStatusCallback callback,
+                RecognitionConfig recognitionConfig) {
             // Allow the call if this is the current voice interaction service.
             synchronized (this) {
                 if (mImpl == null || mImpl.mService == null
@@ -573,14 +591,16 @@
                             "Caller is not the current voice interaction service");
                 }
 
-                if (callback == null || recognitionConfig == null) {
+                if (callback == null || recognitionConfig == null || bcp47Locale == null) {
                     throw new IllegalArgumentException("Illegal argument(s) in startRecognition");
                 }
             }
 
+            int callingUid = UserHandle.getCallingUserId();
             final long caller = Binder.clearCallingIdentity();
             try {
-                KeyphraseSoundModel soundModel = mDbHelper.getKeyphraseSoundModel(keyphraseId);
+                KeyphraseSoundModel soundModel =
+                        mDbHelper.getKeyphraseSoundModel(keyphraseId, callingUid, bcp47Locale);
                 if (soundModel == null
                         || soundModel.uuid == null
                         || soundModel.keyphrases == null) {
diff --git a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerServiceImpl.java b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerServiceImpl.java
index c0e536a..b36b611 100644
--- a/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerServiceImpl.java
+++ b/services/voiceinteraction/java/com/android/server/voiceinteraction/VoiceInteractionManagerServiceImpl.java
@@ -253,7 +253,7 @@
             intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_MULTIPLE_TASK);
             return mAm.startVoiceActivity(mComponent.getPackageName(), callingPid, callingUid,
                     intent, resolvedType, mActiveSession.mSession, mActiveSession.mInteractor,
-                    0, null, null, null, mUser);
+                    0, null, null, mUser);
         } catch (RemoteException e) {
             throw new IllegalStateException("Unexpected remote error", e);
         }
diff --git a/telecomm/java/android/telecom/AudioState.aidl b/telecomm/java/android/telecom/AudioState.aidl
new file mode 100644
index 0000000..b36e238
--- /dev/null
+++ b/telecomm/java/android/telecom/AudioState.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable AudioState;
diff --git a/telecomm/java/android/telecom/AudioState.java b/telecomm/java/android/telecom/AudioState.java
new file mode 100644
index 0000000..d0e2860
--- /dev/null
+++ b/telecomm/java/android/telecom/AudioState.java
@@ -0,0 +1,161 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+import java.util.Locale;
+
+/**
+ *  Encapsulates all audio states during a call.
+ */
+public final class AudioState implements Parcelable {
+    /** Direct the audio stream through the device's earpiece. */
+    public static final int ROUTE_EARPIECE      = 0x00000001;
+
+    /** Direct the audio stream through Bluetooth. */
+    public static final int ROUTE_BLUETOOTH     = 0x00000002;
+
+    /** Direct the audio stream through a wired headset. */
+    public static final int ROUTE_WIRED_HEADSET = 0x00000004;
+
+    /** Direct the audio stream through the device's speakerphone. */
+    public static final int ROUTE_SPEAKER       = 0x00000008;
+
+    /**
+     * Direct the audio stream through the device's earpiece or wired headset if one is
+     * connected.
+     */
+    public static final int ROUTE_WIRED_OR_EARPIECE = ROUTE_EARPIECE | ROUTE_WIRED_HEADSET;
+
+    /** Bit mask of all possible audio routes.
+     *
+     * @hide
+     */
+    public static final int ROUTE_ALL = ROUTE_EARPIECE | ROUTE_BLUETOOTH | ROUTE_WIRED_HEADSET |
+            ROUTE_SPEAKER;
+
+    /** True if the call is muted, false otherwise. */
+    public final boolean isMuted;
+
+    /** The route to use for the audio stream. */
+    public final int route;
+
+    /** Bit vector of all routes supported by this call. */
+    public final int supportedRouteMask;
+
+    public AudioState(boolean isMuted, int route, int supportedRouteMask) {
+        this.isMuted = isMuted;
+        this.route = route;
+        this.supportedRouteMask = supportedRouteMask;
+    }
+
+    public AudioState(AudioState state) {
+        isMuted = state.isMuted;
+        route = state.route;
+        supportedRouteMask = state.supportedRouteMask;
+    }
+
+    @Override
+    public boolean equals(Object obj) {
+        if (obj == null) {
+            return false;
+        }
+        if (!(obj instanceof AudioState)) {
+            return false;
+        }
+        AudioState state = (AudioState) obj;
+        return isMuted == state.isMuted && route == state.route &&
+                supportedRouteMask == state.supportedRouteMask;
+    }
+
+    @Override
+    public String toString() {
+        return String.format(Locale.US,
+                "[AudioState isMuted: %b, route; %s, supportedRouteMask: %s]",
+                isMuted, audioRouteToString(route), audioRouteToString(supportedRouteMask));
+    }
+
+    /** @hide */
+    public static String audioRouteToString(int route) {
+        if (route == 0 || (route & ~ROUTE_ALL) != 0x0) {
+            return "UNKNOWN";
+        }
+
+        StringBuffer buffer = new StringBuffer();
+        if ((route & ROUTE_EARPIECE) == ROUTE_EARPIECE) {
+            listAppend(buffer, "EARPIECE");
+        }
+        if ((route & ROUTE_BLUETOOTH) == ROUTE_BLUETOOTH) {
+            listAppend(buffer, "BLUETOOTH");
+        }
+        if ((route & ROUTE_WIRED_HEADSET) == ROUTE_WIRED_HEADSET) {
+            listAppend(buffer, "WIRED_HEADSET");
+        }
+        if ((route & ROUTE_SPEAKER) == ROUTE_SPEAKER) {
+            listAppend(buffer, "SPEAKER");
+        }
+
+        return buffer.toString();
+    }
+
+    private static void listAppend(StringBuffer buffer, String str) {
+        if (buffer.length() > 0) {
+            buffer.append(", ");
+        }
+        buffer.append(str);
+    }
+
+    /**
+     * Responsible for creating AudioState objects for deserialized Parcels.
+     */
+    public static final Parcelable.Creator<AudioState> CREATOR =
+            new Parcelable.Creator<AudioState> () {
+
+        @Override
+        public AudioState createFromParcel(Parcel source) {
+            boolean isMuted = source.readByte() == 0 ? false : true;
+            int route = source.readInt();
+            int supportedRouteMask = source.readInt();
+            return new AudioState(isMuted, route, supportedRouteMask);
+        }
+
+        @Override
+        public AudioState[] newArray(int size) {
+            return new AudioState[size];
+        }
+    };
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /**
+     * Writes AudioState object into a serializeable Parcel.
+     */
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeByte((byte) (isMuted ? 1 : 0));
+        destination.writeInt(route);
+        destination.writeInt(supportedRouteMask);
+    }
+}
diff --git a/telecomm/java/android/telecom/Call.java b/telecomm/java/android/telecom/Call.java
new file mode 100644
index 0000000..b0b6fb9
--- /dev/null
+++ b/telecomm/java/android/telecom/Call.java
@@ -0,0 +1,836 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.annotation.SystemApi;
+import android.net.Uri;
+import android.os.Bundle;
+
+import java.lang.String;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.concurrent.CopyOnWriteArrayList;
+
+/**
+ * Represents an ongoing phone call that the in-call app should present to the user.
+ *
+ * {@hide}
+ */
+@SystemApi
+public final class Call {
+    /**
+     * The state of a {@code Call} when newly created.
+     */
+    public static final int STATE_NEW = 0;
+
+    /**
+     * The state of an outgoing {@code Call} when dialing the remote number, but not yet connected.
+     */
+    public static final int STATE_DIALING = 1;
+
+    /**
+     * The state of an incoming {@code Call} when ringing locally, but not yet connected.
+     */
+    public static final int STATE_RINGING = 2;
+
+    /**
+     * The state of a {@code Call} when in a holding state.
+     */
+    public static final int STATE_HOLDING = 3;
+
+    /**
+     * The state of a {@code Call} when actively supporting conversation.
+     */
+    public static final int STATE_ACTIVE = 4;
+
+    /**
+     * The state of a {@code Call} when no further voice or other communication is being
+     * transmitted, the remote side has been or will inevitably be informed that the {@code Call}
+     * is no longer active, and the local data transport has or inevitably will release resources
+     * associated with this {@code Call}.
+     */
+    public static final int STATE_DISCONNECTED = 7;
+
+    /**
+     * The state of an outgoing {@code Call}, but waiting for user input before proceeding.
+     */
+    public static final int STATE_PRE_DIAL_WAIT = 8;
+
+    /**
+     * The initial state of an outgoing {@code Call}.
+     * Common transitions are to {@link #STATE_DIALING} state for a successful call or
+     * {@link #STATE_DISCONNECTED} if it failed.
+     */
+    public static final int STATE_CONNECTING = 9;
+
+    /**
+     * The key to retrieve the optional {@code PhoneAccount}s Telecom can bundle with its Call
+     * extras. Used to pass the phone accounts to display on the front end to the user in order to
+     * select phone accounts to (for example) place a call.
+     *
+     * @hide
+     */
+    public static final String AVAILABLE_PHONE_ACCOUNTS = "selectPhoneAccountAccounts";
+
+    public static class Details {
+        private final Uri mHandle;
+        private final int mHandlePresentation;
+        private final String mCallerDisplayName;
+        private final int mCallerDisplayNamePresentation;
+        private final PhoneAccountHandle mAccountHandle;
+        private final int mCallCapabilities;
+        private final int mCallProperties;
+        private final DisconnectCause mDisconnectCause;
+        private final long mConnectTimeMillis;
+        private final GatewayInfo mGatewayInfo;
+        private final int mVideoState;
+        private final StatusHints mStatusHints;
+        private final Bundle mExtras;
+
+        /**
+         * @return The handle (e.g., phone number) to which the {@code Call} is currently
+         * connected.
+         */
+        public Uri getHandle() {
+            return mHandle;
+        }
+
+        /**
+         * @return The presentation requirements for the handle. See
+         * {@link TelecomManager} for valid values.
+         */
+        public int getHandlePresentation() {
+            return mHandlePresentation;
+        }
+
+        /**
+         * @return The display name for the caller.
+         */
+        public String getCallerDisplayName() {
+            return mCallerDisplayName;
+        }
+
+        /**
+         * @return The presentation requirements for the caller display name. See
+         * {@link TelecomManager} for valid values.
+         */
+        public int getCallerDisplayNamePresentation() {
+            return mCallerDisplayNamePresentation;
+        }
+
+        /**
+         * @return The {@code PhoneAccountHandle} whereby the {@code Call} is currently being
+         * routed.
+         */
+        public PhoneAccountHandle getAccountHandle() {
+            return mAccountHandle;
+        }
+
+        /**
+         * @return A bitmask of the capabilities of the {@code Call}, as defined in
+         *         {@link PhoneCapabilities}.
+         */
+        public int getCallCapabilities() {
+            return mCallCapabilities;
+        }
+
+        /**
+         * @return A bitmask of the properties of the {@code Call}, as defined in
+         *         {@link CallProperties}.
+         */
+        public int getCallProperties() {
+            return mCallProperties;
+        }
+
+        /**
+         * @return For a {@link #STATE_DISCONNECTED} {@code Call}, the disconnect cause expressed
+         * by {@link android.telecomm.DisconnectCause}.
+         */
+        public DisconnectCause getDisconnectCause() {
+            return mDisconnectCause;
+        }
+
+        /**
+         * @return The time the {@code Call} has been connected. This information is updated
+         * periodically, but user interfaces should not rely on this to display any "call time
+         * clock".
+         */
+        public long getConnectTimeMillis() {
+            return mConnectTimeMillis;
+        }
+
+        /**
+         * @return Information about any calling gateway the {@code Call} may be using.
+         */
+        public GatewayInfo getGatewayInfo() {
+            return mGatewayInfo;
+        }
+
+        /**
+         * @return The video state of the {@code Call}.
+         */
+        public int getVideoState() {
+            return mVideoState;
+        }
+
+        /**
+         * @return The current {@link android.telecom.StatusHints}, or {@code null} if none
+         * have been set.
+         */
+        public StatusHints getStatusHints() {
+            return mStatusHints;
+        }
+
+        /**
+         * @return A bundle extras to pass with the call
+         */
+        public Bundle getExtras() {
+            return mExtras;
+        }
+
+        @Override
+        public boolean equals(Object o) {
+            if (o instanceof Details) {
+                Details d = (Details) o;
+                return
+                        Objects.equals(mHandle, d.mHandle) &&
+                        Objects.equals(mHandlePresentation, d.mHandlePresentation) &&
+                        Objects.equals(mCallerDisplayName, d.mCallerDisplayName) &&
+                        Objects.equals(mCallerDisplayNamePresentation,
+                                d.mCallerDisplayNamePresentation) &&
+                        Objects.equals(mAccountHandle, d.mAccountHandle) &&
+                        Objects.equals(mCallCapabilities, d.mCallCapabilities) &&
+                        Objects.equals(mCallProperties, d.mCallProperties) &&
+                        Objects.equals(mDisconnectCause, d.mDisconnectCause) &&
+                        Objects.equals(mConnectTimeMillis, d.mConnectTimeMillis) &&
+                        Objects.equals(mGatewayInfo, d.mGatewayInfo) &&
+                        Objects.equals(mVideoState, d.mVideoState) &&
+                        Objects.equals(mStatusHints, d.mStatusHints) &&
+                        Objects.equals(mExtras, d.mExtras);
+            }
+            return false;
+        }
+
+        @Override
+        public int hashCode() {
+            return
+                    Objects.hashCode(mHandle) +
+                    Objects.hashCode(mHandlePresentation) +
+                    Objects.hashCode(mCallerDisplayName) +
+                    Objects.hashCode(mCallerDisplayNamePresentation) +
+                    Objects.hashCode(mAccountHandle) +
+                    Objects.hashCode(mCallCapabilities) +
+                    Objects.hashCode(mCallProperties) +
+                    Objects.hashCode(mDisconnectCause) +
+                    Objects.hashCode(mConnectTimeMillis) +
+                    Objects.hashCode(mGatewayInfo) +
+                    Objects.hashCode(mVideoState) +
+                    Objects.hashCode(mStatusHints) +
+                    Objects.hashCode(mExtras);
+        }
+
+        /** {@hide} */
+        public Details(
+                Uri handle,
+                int handlePresentation,
+                String callerDisplayName,
+                int callerDisplayNamePresentation,
+                PhoneAccountHandle accountHandle,
+                int capabilities,
+                int properties,
+                DisconnectCause disconnectCause,
+                long connectTimeMillis,
+                GatewayInfo gatewayInfo,
+                int videoState,
+                StatusHints statusHints,
+                Bundle extras) {
+            mHandle = handle;
+            mHandlePresentation = handlePresentation;
+            mCallerDisplayName = callerDisplayName;
+            mCallerDisplayNamePresentation = callerDisplayNamePresentation;
+            mAccountHandle = accountHandle;
+            mCallCapabilities = capabilities;
+            mCallProperties = properties;
+            mDisconnectCause = disconnectCause;
+            mConnectTimeMillis = connectTimeMillis;
+            mGatewayInfo = gatewayInfo;
+            mVideoState = videoState;
+            mStatusHints = statusHints;
+            mExtras = extras;
+        }
+    }
+
+    public static abstract class Listener {
+        /**
+         * Invoked when the state of this {@code Call} has changed. See {@link #getState()}.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param state The new state of the {@code Call}.
+         */
+        public void onStateChanged(Call call, int state) {}
+
+        /**
+         * Invoked when the parent of this {@code Call} has changed. See {@link #getParent()}.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param parent The new parent of the {@code Call}.
+         */
+        public void onParentChanged(Call call, Call parent) {}
+
+        /**
+         * Invoked when the children of this {@code Call} have changed. See {@link #getChildren()}.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param children The new children of the {@code Call}.
+         */
+        public void onChildrenChanged(Call call, List<Call> children) {}
+
+        /**
+         * Invoked when the details of this {@code Call} have changed. See {@link #getDetails()}.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param details A {@code Details} object describing the {@code Call}.
+         */
+        public void onDetailsChanged(Call call, Details details) {}
+
+        /**
+         * Invoked when the text messages that can be used as responses to the incoming
+         * {@code Call} are loaded from the relevant database.
+         * See {@link #getCannedTextResponses()}.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param cannedTextResponses The text messages useable as responses.
+         */
+        public void onCannedTextResponsesLoaded(Call call, List<String> cannedTextResponses) {}
+
+        /**
+         * Invoked when the post-dial sequence in the outgoing {@code Call} has reached a pause
+         * character. This causes the post-dial signals to stop pending user confirmation. An
+         * implementation should present this choice to the user and invoke
+         * {@link #postDialContinue(boolean)} when the user makes the choice.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param remainingPostDialSequence The post-dial characters that remain to be sent.
+         */
+        public void onPostDialWait(Call call, String remainingPostDialSequence) {}
+
+        /**
+         * Invoked when the {@code Call.VideoCall} of the {@code Call} has changed.
+         *
+         * @param call The {@code Call} invoking this method.
+         * @param videoCall The {@code Call.VideoCall} associated with the {@code Call}.
+         * @hide
+         */
+        public void onVideoCallChanged(Call call, InCallService.VideoCall videoCall) {}
+
+        /**
+         * Invoked when the {@code Call} is destroyed. Clients should refrain from cleaning
+         * up their UI for the {@code Call} in response to state transitions. Specifically,
+         * clients should not assume that a {@link #onStateChanged(Call, int)} with a state of
+         * {@link #STATE_DISCONNECTED} is the final notification the {@code Call} will send. Rather,
+         * clients should wait for this method to be invoked.
+         *
+         * @param call The {@code Call} being destroyed.
+         */
+        public void onCallDestroyed(Call call) {}
+
+        /**
+         * Invoked upon changes to the set of {@code Call}s with which this {@code Call} can be
+         * conferenced.
+         *
+         * @param call The {@code Call} being updated.
+         * @param conferenceableCalls The {@code Call}s with which this {@code Call} can be
+         *          conferenced.
+         */
+        public void onConferenceableCallsChanged(Call call, List<Call> conferenceableCalls) {}
+    }
+
+    private final Phone mPhone;
+    private final String mTelecomCallId;
+    private final InCallAdapter mInCallAdapter;
+    private final List<String> mChildrenIds = new ArrayList<>();
+    private final List<Call> mChildren = new ArrayList<>();
+    private final List<Call> mUnmodifiableChildren = Collections.unmodifiableList(mChildren);
+    private final List<Listener> mListeners = new CopyOnWriteArrayList<>();
+    private final List<Call> mConferenceableCalls = new ArrayList<>();
+    private final List<Call> mUnmodifiableConferenceableCalls =
+            Collections.unmodifiableList(mConferenceableCalls);
+
+    private boolean mChildrenCached;
+    private String mParentId = null;
+    private int mState;
+    private List<String> mCannedTextResponses = null;
+    private String mRemainingPostDialSequence;
+    private InCallService.VideoCall mVideoCall;
+    private Details mDetails;
+
+    /**
+     * Obtains the post-dial sequence remaining to be emitted by this {@code Call}, if any.
+     *
+     * @return The remaining post-dial sequence, or {@code null} if there is no post-dial sequence
+     * remaining or this {@code Call} is not in a post-dial state.
+     */
+    public String getRemainingPostDialSequence() {
+        return mRemainingPostDialSequence;
+    }
+
+    /**
+     * Instructs this {@link #STATE_RINGING} {@code Call} to answer.
+     * @param videoState The video state in which to answer the call.
+     */
+    public void answer(int videoState) {
+        mInCallAdapter.answerCall(mTelecomCallId, videoState);
+    }
+
+    /**
+     * Instructs this {@link #STATE_RINGING} {@code Call} to reject.
+     *
+     * @param rejectWithMessage Whether to reject with a text message.
+     * @param textMessage An optional text message with which to respond.
+     */
+    public void reject(boolean rejectWithMessage, String textMessage) {
+        mInCallAdapter.rejectCall(mTelecomCallId, rejectWithMessage, textMessage);
+    }
+
+    /**
+     * Instructs this {@code Call} to disconnect.
+     */
+    public void disconnect() {
+        mInCallAdapter.disconnectCall(mTelecomCallId);
+    }
+
+    /**
+     * Instructs this {@code Call} to go on hold.
+     */
+    public void hold() {
+        mInCallAdapter.holdCall(mTelecomCallId);
+    }
+
+    /**
+     * Instructs this {@link #STATE_HOLDING} call to release from hold.
+     */
+    public void unhold() {
+        mInCallAdapter.unholdCall(mTelecomCallId);
+    }
+
+    /**
+     * Instructs this {@code Call} to play a dual-tone multi-frequency signaling (DTMF) tone.
+     *
+     * Any other currently playing DTMF tone in the specified call is immediately stopped.
+     *
+     * @param digit A character representing the DTMF digit for which to play the tone. This
+     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
+     */
+    public void playDtmfTone(char digit) {
+        mInCallAdapter.playDtmfTone(mTelecomCallId, digit);
+    }
+
+    /**
+     * Instructs this {@code Call} to stop any dual-tone multi-frequency signaling (DTMF) tone
+     * currently playing.
+     *
+     * DTMF tones are played by calling {@link #playDtmfTone(char)}. If no DTMF tone is
+     * currently playing, this method will do nothing.
+     */
+    public void stopDtmfTone() {
+        mInCallAdapter.stopDtmfTone(mTelecomCallId);
+    }
+
+    /**
+     * Instructs this {@code Call} to continue playing a post-dial DTMF string.
+     *
+     * A post-dial DTMF string is a string of digits entered after a phone number, when dialed,
+     * that are immediately sent as DTMF tones to the recipient as soon as the connection is made.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_PAUSE} symbol, this
+     * {@code Call} will temporarily pause playing the tones for a pre-defined period of time.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_WAIT} symbol, this
+     * {@code Call} will pause playing the tones and notify listeners via
+     * {@link Listener#onPostDialWait(Call, String)}. At this point, the in-call app
+     * should display to the user an indication of this state and an affordance to continue
+     * the postdial sequence. When the user decides to continue the postdial sequence, the in-call
+     * app should invoke the {@link #postDialContinue(boolean)} method.
+     *
+     * @param proceed Whether or not to continue with the post-dial sequence.
+     */
+    public void postDialContinue(boolean proceed) {
+        mInCallAdapter.postDialContinue(mTelecomCallId, proceed);
+    }
+
+    /**
+     * Notifies this {@code Call} that an account has been selected and to proceed with placing
+     * an outgoing call.
+     */
+    public void phoneAccountSelected(PhoneAccountHandle accountHandle) {
+        mInCallAdapter.phoneAccountSelected(mTelecomCallId, accountHandle);
+
+    }
+
+    /**
+     * Instructs this {@code Call} to enter a conference.
+     *
+     * @param callToConferenceWith The other call with which to conference.
+     */
+    public void conference(Call callToConferenceWith) {
+        if (callToConferenceWith != null) {
+            mInCallAdapter.conference(mTelecomCallId, callToConferenceWith.mTelecomCallId);
+        }
+    }
+
+    /**
+     * Instructs this {@code Call} to split from any conference call with which it may be
+     * connected.
+     */
+    public void splitFromConference() {
+        mInCallAdapter.splitFromConference(mTelecomCallId);
+    }
+
+    /**
+     * Merges the calls within this conference. See {@link PhoneCapabilities#MERGE_CONFERENCE}.
+     */
+    public void mergeConference() {
+        mInCallAdapter.mergeConference(mTelecomCallId);
+    }
+
+    /**
+     * Swaps the calls within this conference. See {@link PhoneCapabilities#SWAP_CONFERENCE}.
+     */
+    public void swapConference() {
+        mInCallAdapter.swapConference(mTelecomCallId);
+    }
+
+    /**
+     * Obtains the parent of this {@code Call} in a conference, if any.
+     *
+     * @return The parent {@code Call}, or {@code null} if this {@code Call} is not a
+     * child of any conference {@code Call}s.
+     */
+    public Call getParent() {
+        if (mParentId != null) {
+            return mPhone.internalGetCallByTelecomId(mParentId);
+        }
+        return null;
+    }
+
+    /**
+     * Obtains the children of this conference {@code Call}, if any.
+     *
+     * @return The children of this {@code Call} if this {@code Call} is a conference, or an empty
+     * {@code List} otherwise.
+     */
+    public List<Call> getChildren() {
+        if (!mChildrenCached) {
+            mChildrenCached = true;
+            mChildren.clear();
+
+            for(String id : mChildrenIds) {
+                Call call = mPhone.internalGetCallByTelecomId(id);
+                if (call == null) {
+                    // At least one child was still not found, so do not save true for "cached"
+                    mChildrenCached = false;
+                } else {
+                    mChildren.add(call);
+                }
+            }
+        }
+
+        return mUnmodifiableChildren;
+    }
+
+    /**
+     * Returns the list of {@code Call}s with which this {@code Call} is allowed to conference.
+     *
+     * @return The list of conferenceable {@code Call}s.
+     */
+    public List<Call> getConferenceableCalls() {
+        return mUnmodifiableConferenceableCalls;
+    }
+
+    /**
+     * Obtains the state of this {@code Call}.
+     *
+     * @return A state value, chosen from the {@code STATE_*} constants.
+     */
+    public int getState() {
+        return mState;
+    }
+
+    /**
+     * Obtains a list of canned, pre-configured message responses to present to the user as
+     * ways of rejecting this {@code Call} using via a text message.
+     *
+     * @see #reject(boolean, String)
+     *
+     * @return A list of canned text message responses.
+     */
+    public List<String> getCannedTextResponses() {
+        return mCannedTextResponses;
+    }
+
+    /**
+     * Obtains an object that can be used to display video from this {@code Call}.
+     *
+     * @return An {@code Call.VideoCall}.
+     * @hide
+     */
+    public InCallService.VideoCall getVideoCall() {
+        return mVideoCall;
+    }
+
+    /**
+     * Obtains an object containing call details.
+     *
+     * @return A {@link Details} object. Depending on the state of the {@code Call}, the
+     * result may be {@code null}.
+     */
+    public Details getDetails() {
+        return mDetails;
+    }
+
+    /**
+     * Adds a listener to this {@code Call}.
+     *
+     * @param listener A {@code Listener}.
+     */
+    public void addListener(Listener listener) {
+        mListeners.add(listener);
+    }
+
+    /**
+     * Removes a listener from this {@code Call}.
+     *
+     * @param listener A {@code Listener}.
+     */
+    public void removeListener(Listener listener) {
+        if (listener != null) {
+            mListeners.remove(listener);
+        }
+    }
+
+    /** {@hide} */
+    Call(Phone phone, String telecomCallId, InCallAdapter inCallAdapter) {
+        mPhone = phone;
+        mTelecomCallId = telecomCallId;
+        mInCallAdapter = inCallAdapter;
+        mState = STATE_NEW;
+    }
+
+    /** {@hide} */
+    final String internalGetCallId() {
+        return mTelecomCallId;
+    }
+
+    /** {@hide} */
+    final void internalUpdate(ParcelableCall parcelableCall, Map<String, Call> callIdMap) {
+        // First, we update the internal state as far as possible before firing any updates.
+        Details details = new Details(
+                parcelableCall.getHandle(),
+                parcelableCall.getHandlePresentation(),
+                parcelableCall.getCallerDisplayName(),
+                parcelableCall.getCallerDisplayNamePresentation(),
+                parcelableCall.getAccountHandle(),
+                parcelableCall.getCapabilities(),
+                parcelableCall.getProperties(),
+                parcelableCall.getDisconnectCause(),
+                parcelableCall.getConnectTimeMillis(),
+                parcelableCall.getGatewayInfo(),
+                parcelableCall.getVideoState(),
+                parcelableCall.getStatusHints(),
+                parcelableCall.getExtras());
+        boolean detailsChanged = !Objects.equals(mDetails, details);
+        if (detailsChanged) {
+            mDetails = details;
+        }
+
+        boolean cannedTextResponsesChanged = false;
+        if (mCannedTextResponses == null && parcelableCall.getCannedSmsResponses() != null
+                && !parcelableCall.getCannedSmsResponses().isEmpty()) {
+            mCannedTextResponses =
+                    Collections.unmodifiableList(parcelableCall.getCannedSmsResponses());
+        }
+
+        boolean videoCallChanged = !Objects.equals(mVideoCall, parcelableCall.getVideoCall());
+        if (videoCallChanged) {
+            mVideoCall = parcelableCall.getVideoCall();
+        }
+
+        int state = stateFromParcelableCallState(parcelableCall.getState());
+        boolean stateChanged = mState != state;
+        if (stateChanged) {
+            mState = state;
+        }
+
+        String parentId = parcelableCall.getParentCallId();
+        boolean parentChanged = !Objects.equals(mParentId, parentId);
+        if (parentChanged) {
+            mParentId = parentId;
+        }
+
+        List<String> childCallIds = parcelableCall.getChildCallIds();
+        boolean childrenChanged = !Objects.equals(childCallIds, mChildrenIds);
+        if (childrenChanged) {
+            mChildrenIds.clear();
+            mChildrenIds.addAll(parcelableCall.getChildCallIds());
+            mChildrenCached = false;
+        }
+
+        List<String> conferenceableCallIds = parcelableCall.getConferenceableCallIds();
+        List<Call> conferenceableCalls = new ArrayList<Call>(conferenceableCallIds.size());
+        for (String otherId : conferenceableCallIds) {
+            if (callIdMap.containsKey(otherId)) {
+                conferenceableCalls.add(callIdMap.get(otherId));
+            }
+        }
+
+        if (!Objects.equals(mConferenceableCalls, conferenceableCalls)) {
+            mConferenceableCalls.clear();
+            mConferenceableCalls.addAll(conferenceableCalls);
+            fireConferenceableCallsChanged();
+        }
+
+        // Now we fire updates, ensuring that any client who listens to any of these notifications
+        // gets the most up-to-date state.
+
+        if (stateChanged) {
+            fireStateChanged(mState);
+        }
+        if (detailsChanged) {
+            fireDetailsChanged(mDetails);
+        }
+        if (cannedTextResponsesChanged) {
+            fireCannedTextResponsesLoaded(mCannedTextResponses);
+        }
+        if (videoCallChanged) {
+            fireVideoCallChanged(mVideoCall);
+        }
+        if (parentChanged) {
+            fireParentChanged(getParent());
+        }
+        if (childrenChanged) {
+            fireChildrenChanged(getChildren());
+        }
+
+        // If we have transitioned to DISCONNECTED, that means we need to notify clients and
+        // remove ourselves from the Phone. Note that we do this after completing all state updates
+        // so a client can cleanly transition all their UI to the state appropriate for a
+        // DISCONNECTED Call while still relying on the existence of that Call in the Phone's list.
+        if (mState == STATE_DISCONNECTED) {
+            fireCallDestroyed();
+            mPhone.internalRemoveCall(this);
+        }
+    }
+
+    /** {@hide} */
+    final void internalSetPostDialWait(String remaining) {
+        mRemainingPostDialSequence = remaining;
+        firePostDialWait(mRemainingPostDialSequence);
+    }
+
+    /** {@hide} */
+    final void internalSetDisconnected() {
+        if (mState != Call.STATE_DISCONNECTED) {
+            mState = Call.STATE_DISCONNECTED;
+            fireStateChanged(mState);
+            fireCallDestroyed();
+            mPhone.internalRemoveCall(this);
+        }
+    }
+
+    private void fireStateChanged(int newState) {
+        for (Listener listener : mListeners) {
+            listener.onStateChanged(this, newState);
+        }
+    }
+
+    private void fireParentChanged(Call newParent) {
+        for (Listener listener : mListeners) {
+            listener.onParentChanged(this, newParent);
+        }
+    }
+
+    private void fireChildrenChanged(List<Call> children) {
+        for (Listener listener : mListeners) {
+            listener.onChildrenChanged(this, children);
+        }
+    }
+
+    private void fireDetailsChanged(Details details) {
+        for (Listener listener : mListeners) {
+            listener.onDetailsChanged(this, details);
+        }
+    }
+
+    private void fireCannedTextResponsesLoaded(List<String> cannedTextResponses) {
+        for (Listener listener : mListeners) {
+            listener.onCannedTextResponsesLoaded(this, cannedTextResponses);
+        }
+    }
+
+    private void fireVideoCallChanged(InCallService.VideoCall videoCall) {
+        for (Listener listener : mListeners) {
+            listener.onVideoCallChanged(this, videoCall);
+        }
+    }
+
+    private void firePostDialWait(String remainingPostDialSequence) {
+        for (Listener listener : mListeners) {
+            listener.onPostDialWait(this, remainingPostDialSequence);
+        }
+    }
+
+    private void fireCallDestroyed() {
+        for (Listener listener : mListeners) {
+            listener.onCallDestroyed(this);
+        }
+    }
+
+    private void fireConferenceableCallsChanged() {
+        for (Listener listener : mListeners) {
+            listener.onConferenceableCallsChanged(this, mUnmodifiableConferenceableCalls);
+        }
+    }
+
+    private int stateFromParcelableCallState(int parcelableCallState) {
+        switch (parcelableCallState) {
+            case CallState.NEW:
+                return STATE_NEW;
+            case CallState.CONNECTING:
+                return STATE_CONNECTING;
+            case CallState.PRE_DIAL_WAIT:
+                return STATE_PRE_DIAL_WAIT;
+            case CallState.DIALING:
+                return STATE_DIALING;
+            case CallState.RINGING:
+                return STATE_RINGING;
+            case CallState.ACTIVE:
+                return STATE_ACTIVE;
+            case CallState.ON_HOLD:
+                return STATE_HOLDING;
+            case CallState.DISCONNECTED:
+                return STATE_DISCONNECTED;
+            case CallState.ABORTED:
+                return STATE_DISCONNECTED;
+            default:
+                Log.wtf(this, "Unrecognized CallState %s", parcelableCallState);
+                return STATE_NEW;
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/CallProperties.java b/telecomm/java/android/telecom/CallProperties.java
new file mode 100644
index 0000000..b1b82e2
--- /dev/null
+++ b/telecomm/java/android/telecom/CallProperties.java
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+/**
+ * Defines properties of a phone call which may be affected by changes to the call.
+ * @hide
+ */
+public class CallProperties {
+    /** Call is currently in a conference call. */
+    public static final int CONFERENCE                      = 0x00000001;
+}
diff --git a/telecomm/java/android/telecom/CallState.java b/telecomm/java/android/telecom/CallState.java
new file mode 100644
index 0000000..7690847
--- /dev/null
+++ b/telecomm/java/android/telecom/CallState.java
@@ -0,0 +1,127 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import android.annotation.SystemApi;
+
+/**
+ * Defines call-state constants of the different states in which a call can exist. Although states
+ * have the notion of normal transitions, due to the volatile nature of telephony systems, code
+ * that uses these states should be resilient to unexpected state changes outside of what is
+ * considered traditional.
+ *
+ * {@hide}
+ */
+@SystemApi
+public final class CallState {
+
+    private CallState() {}
+
+    /**
+     * Indicates that a call is new and not connected. This is used as the default state internally
+     * within Telecom and should not be used between Telecom and call services. Call services are
+     * not expected to ever interact with NEW calls, but {@link InCallService}s will see calls in
+     * this state.
+     */
+    public static final int NEW = 0;
+
+    /**
+     * The initial state of an outgoing {@code Call}.
+     * Common transitions are to {@link #DIALING} state for a successful call or
+     * {@link #DISCONNECTED} if it failed.
+     */
+    public static final int CONNECTING = 1;
+
+    /**
+     * Indicates that the call is about to go into the outgoing and dialing state but is waiting for
+     * user input before it proceeds. For example, where no default {@link PhoneAccount} is set,
+     * this is the state where the InCallUI is waiting for the user to select a
+     * {@link PhoneAccount} to call from.
+     */
+    public static final int PRE_DIAL_WAIT = 2;
+
+    /**
+     * Indicates that a call is outgoing and in the dialing state. A call transitions to this state
+     * once an outgoing call has begun (e.g., user presses the dial button in Dialer). Calls in this
+     * state usually transition to {@link #ACTIVE} if the call was answered or {@link #DISCONNECTED}
+     * if the call was disconnected somehow (e.g., failure or cancellation of the call by the user).
+     */
+    public static final int DIALING = 3;
+
+    /**
+     * Indicates that a call is incoming and the user still has the option of answering, rejecting,
+     * or doing nothing with the call. This state is usually associated with some type of audible
+     * ringtone. Normal transitions are to {@link #ACTIVE} if answered or {@link #DISCONNECTED}
+     * otherwise.
+     */
+    public static final int RINGING = 4;
+
+    /**
+     * Indicates that a call is currently connected to another party and a communication channel is
+     * open between them. The normal transition to this state is by the user answering a
+     * {@link #DIALING} call or a {@link #RINGING} call being answered by the other party.
+     */
+    public static final int ACTIVE = 5;
+
+    /**
+     * Indicates that the call is currently on hold. In this state, the call is not terminated
+     * but no communication is allowed until the call is no longer on hold. The typical transition
+     * to this state is by the user putting an {@link #ACTIVE} call on hold by explicitly performing
+     * an action, such as clicking the hold button.
+     */
+    public static final int ON_HOLD = 6;
+
+    /**
+     * Indicates that a call is currently disconnected. All states can transition to this state
+     * by the call service giving notice that the connection has been severed. When the user
+     * explicitly ends a call, it will not transition to this state until the call service confirms
+     * the disconnection or communication was lost to the call service currently responsible for
+     * this call (e.g., call service crashes).
+     */
+    public static final int DISCONNECTED = 7;
+
+    /**
+     * Indicates that the call was attempted (mostly in the context of outgoing, at least at the
+     * time of writing) but cancelled before it was successfully connected.
+     */
+    public static final int ABORTED = 8;
+
+    public static String toString(int callState) {
+        switch (callState) {
+            case NEW:
+                return "NEW";
+            case CONNECTING:
+                return "CONNECTING";
+            case PRE_DIAL_WAIT:
+                return "PRE_DIAL_WAIT";
+            case DIALING:
+                return "DIALING";
+            case RINGING:
+                return "RINGING";
+            case ACTIVE:
+                return "ACTIVE";
+            case ON_HOLD:
+                return "ON_HOLD";
+            case DISCONNECTED:
+                return "DISCONNECTED";
+            case ABORTED:
+                return "ABORTED";
+            default:
+                return "UNKNOWN";
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/CameraCapabilities.aidl b/telecomm/java/android/telecom/CameraCapabilities.aidl
new file mode 100644
index 0000000..c8e0c5e
--- /dev/null
+++ b/telecomm/java/android/telecom/CameraCapabilities.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable CameraCapabilities;
diff --git a/telecomm/java/android/telecom/CameraCapabilities.java b/telecomm/java/android/telecom/CameraCapabilities.java
new file mode 100644
index 0000000..f968c13
--- /dev/null
+++ b/telecomm/java/android/telecom/CameraCapabilities.java
@@ -0,0 +1,144 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Represents the camera capabilities important to a Video Telephony provider.
+ * @hide
+ */
+public final class CameraCapabilities implements Parcelable {
+
+    /**
+     * Whether the camera supports zoom.
+     */
+    private final boolean mZoomSupported;
+
+    /**
+     * The maximum zoom supported by the camera.
+     */
+    private final float mMaxZoom;
+
+    /**
+     * The width of the camera video in pixels.
+     */
+    private final int mWidth;
+
+    /**
+     * The height of the camera video in pixels.
+     */
+    private final int mHeight;
+
+    /**
+     * Create a call camera capabilities instance.
+     *
+     * @param zoomSupported True when camera supports zoom.
+     * @param maxZoom Maximum zoom supported by camera.
+     * @param width The width of the camera video (in pixels).
+     * @param height The height of the camera video (in pixels).
+     */
+    public CameraCapabilities(boolean zoomSupported, float maxZoom, int width, int height) {
+        mZoomSupported = zoomSupported;
+        mMaxZoom = maxZoom;
+        mWidth = width;
+        mHeight = height;
+    }
+
+    /**
+     * Responsible for creating CallCameraCapabilities objects from deserialized Parcels.
+     **/
+    public static final Parcelable.Creator<CameraCapabilities> CREATOR =
+            new Parcelable.Creator<CameraCapabilities> () {
+                /**
+                 * Creates a CallCameraCapabilities instances from a parcel.
+                 *
+                 * @param source The parcel.
+                 * @return The CallCameraCapabilities.
+                 */
+                @Override
+                public CameraCapabilities createFromParcel(Parcel source) {
+                    boolean supportsZoom = source.readByte() != 0;
+                    float maxZoom = source.readFloat();
+                    int width = source.readInt();
+                    int height = source.readInt();
+
+                    return new CameraCapabilities(supportsZoom, maxZoom, width, height);
+                }
+
+                @Override
+                public CameraCapabilities[] newArray(int size) {
+                    return new CameraCapabilities[size];
+                }
+            };
+
+    /**
+     * Describe the kinds of special objects contained in this Parcelable's
+     * marshalled representation.
+     *
+     * @return a bitmask indicating the set of special object types marshalled
+     * by the Parcelable.
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /**
+     * Flatten this object in to a Parcel.
+     *
+     * @param dest  The Parcel in which the object should be written.
+     * @param flags Additional flags about how the object should be written.
+     *              May be 0 or {@link #PARCELABLE_WRITE_RETURN_VALUE}.
+     */
+    @Override
+    public void writeToParcel(Parcel dest, int flags) {
+        dest.writeByte((byte) (isZoomSupported() ? 1 : 0));
+        dest.writeFloat(getMaxZoom());
+        dest.writeInt(getWidth());
+        dest.writeInt(getHeight());
+    }
+
+    /**
+     * Whether the camera supports zoom.
+     */
+    public boolean isZoomSupported() {
+        return mZoomSupported;
+    }
+
+    /**
+     * The maximum zoom supported by the camera.
+     */
+    public float getMaxZoom() {
+        return mMaxZoom;
+    }
+
+    /**
+     * The width of the camera video in pixels.
+     */
+    public int getWidth() {
+        return mWidth;
+    }
+
+    /**
+     * The height of the camera video in pixels.
+     */
+    public int getHeight() {
+        return mHeight;
+    }
+}
diff --git a/telecomm/java/android/telecom/Conference.java b/telecomm/java/android/telecom/Conference.java
new file mode 100644
index 0000000..9b350c1
--- /dev/null
+++ b/telecomm/java/android/telecom/Conference.java
@@ -0,0 +1,312 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.CopyOnWriteArraySet;
+
+/**
+ * Represents a conference call which can contain any number of {@link Connection} objects.
+ */
+public abstract class Conference {
+
+    /** @hide */
+    public abstract static class Listener {
+        public void onStateChanged(Conference conference, int oldState, int newState) {}
+        public void onDisconnected(Conference conference, DisconnectCause disconnectCause) {}
+        public void onConnectionAdded(Conference conference, Connection connection) {}
+        public void onConnectionRemoved(Conference conference, Connection connection) {}
+        public void onDestroyed(Conference conference) {}
+        public void onCapabilitiesChanged(Conference conference, int capabilities) {}
+    }
+
+    private final Set<Listener> mListeners = new CopyOnWriteArraySet<>();
+    private final List<Connection> mChildConnections = new CopyOnWriteArrayList<>();
+    private final List<Connection> mUnmodifiableChildConnections =
+            Collections.unmodifiableList(mChildConnections);
+
+    private PhoneAccountHandle mPhoneAccount;
+    private AudioState mAudioState;
+    private int mState = Connection.STATE_NEW;
+    private DisconnectCause mDisconnectCause;
+    private int mCapabilities;
+    private String mDisconnectMessage;
+
+    /**
+     * Constructs a new Conference with a mandatory {@link PhoneAccountHandle}
+     *
+     * @param phoneAccount The {@code PhoneAccountHandle} associated with the conference.
+     */
+    public Conference(PhoneAccountHandle phoneAccount) {
+        mPhoneAccount = phoneAccount;
+    }
+
+    /**
+     * Returns the {@link PhoneAccountHandle} the conference call is being placed through.
+     *
+     * @return A {@code PhoneAccountHandle} object representing the PhoneAccount of the conference.
+     */
+    public final PhoneAccountHandle getPhoneAccountHandle() {
+        return mPhoneAccount;
+    }
+
+    /**
+     * Returns the list of connections currently associated with the conference call.
+     *
+     * @return A list of {@code Connection} objects which represent the children of the conference.
+     */
+    public final List<Connection> getConnections() {
+        return mUnmodifiableChildConnections;
+    }
+
+    /**
+     * Gets the state of the conference call. See {@link Connection} for valid values.
+     *
+     * @return A constant representing the state the conference call is currently in.
+     */
+    public final int getState() {
+        return mState;
+    }
+
+    /**
+     * Returns the capabilities of a conference. See {@link PhoneCapabilities} for valid values.
+     *
+     * @return A bitmask of the {@code PhoneCapabilities} of the conference call.
+     */
+    public final int getCapabilities() {
+        return mCapabilities;
+    }
+
+    /**
+     * @return The audio state of the conference, describing how its audio is currently
+     *         being routed by the system. This is {@code null} if this Conference
+     *         does not directly know about its audio state.
+     */
+    public final AudioState getAudioState() {
+        return mAudioState;
+    }
+
+    /**
+     * Invoked when the Conference and all it's {@link Connection}s should be disconnected.
+     */
+    public void onDisconnect() {}
+
+    /**
+     * Invoked when the specified {@link Connection} should be separated from the conference call.
+     *
+     * @param connection The connection to separate.
+     */
+    public void onSeparate(Connection connection) {}
+
+    /**
+     * Invoked when the conference should be put on hold.
+     */
+    public void onHold() {}
+
+    /**
+     * Invoked when the conference should be moved from hold to active.
+     */
+    public void onUnhold() {}
+
+    /**
+     * Invoked when the child calls should be merged. Only invoked if the conference contains the
+     * capability {@link PhoneCapabilities#MERGE_CONFERENCE}.
+     */
+    public void onMerge() {}
+
+    /**
+     * Invoked when the child calls should be swapped. Only invoked if the conference contains the
+     * capability {@link PhoneCapabilities#SWAP_CONFERENCE}.
+     */
+    public void onSwap() {}
+
+    /**
+     * Notifies this conference of a request to play a DTMF tone.
+     *
+     * @param c A DTMF character.
+     */
+    public void onPlayDtmfTone(char c) {}
+
+    /**
+     * Notifies this conference of a request to stop any currently playing DTMF tones.
+     */
+    public void onStopDtmfTone() {}
+
+    /**
+     * Notifies this conference that the {@link #getAudioState()} property has a new value.
+     *
+     * @param state The new call audio state.
+     */
+    public void onAudioStateChanged(AudioState state) {}
+
+    /**
+     * Sets state to be on hold.
+     */
+    public final void setOnHold() {
+        setState(Connection.STATE_HOLDING);
+    }
+
+    /**
+     * Sets state to be active.
+     */
+    public final void setActive() {
+        setState(Connection.STATE_ACTIVE);
+    }
+
+    /**
+     * Sets state to disconnected.
+     *
+     * @param disconnectCause The reason for the disconnection, as described by
+     *     {@link android.telecom.DisconnectCause}.
+     */
+    public final void setDisconnected(DisconnectCause disconnectCause) {
+        mDisconnectCause = disconnectCause;;
+        setState(Connection.STATE_DISCONNECTED);
+        for (Listener l : mListeners) {
+            l.onDisconnected(this, mDisconnectCause);
+        }
+    }
+
+    /**
+     * Sets the capabilities of a conference. See {@link PhoneCapabilities} for valid values.
+     *
+     * @param capabilities A bitmask of the {@code PhoneCapabilities} of the conference call.
+     */
+    public final void setCapabilities(int capabilities) {
+        if (capabilities != mCapabilities) {
+            mCapabilities = capabilities;
+
+            for (Listener l : mListeners) {
+                l.onCapabilitiesChanged(this, mCapabilities);
+            }
+        }
+    }
+
+    /**
+     * Adds the specified connection as a child of this conference.
+     *
+     * @param connection The connection to add.
+     * @return True if the connection was successfully added.
+     */
+    public final boolean addConnection(Connection connection) {
+        if (connection != null && !mChildConnections.contains(connection)) {
+            if (connection.setConference(this)) {
+                mChildConnections.add(connection);
+                for (Listener l : mListeners) {
+                    l.onConnectionAdded(this, connection);
+                }
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Removes the specified connection as a child of this conference.
+     *
+     * @param connection The connection to remove.
+     */
+    public final void removeConnection(Connection connection) {
+        Log.d(this, "removing %s from %s", connection, mChildConnections);
+        if (connection != null && mChildConnections.remove(connection)) {
+            connection.resetConference();
+            for (Listener l : mListeners) {
+                l.onConnectionRemoved(this, connection);
+            }
+        }
+    }
+
+    /**
+     * Tears down the conference object and any of its current connections.
+     */
+    public final void destroy() {
+        Log.d(this, "destroying conference : %s", this);
+        // Tear down the children.
+        for (Connection connection : mChildConnections) {
+            Log.d(this, "removing connection %s", connection);
+            removeConnection(connection);
+        }
+
+        // If not yet disconnected, set the conference call as disconnected first.
+        if (mState != Connection.STATE_DISCONNECTED) {
+            Log.d(this, "setting to disconnected");
+            setDisconnected(new DisconnectCause(DisconnectCause.LOCAL));
+        }
+
+        // ...and notify.
+        for (Listener l : mListeners) {
+            l.onDestroyed(this);
+        }
+    }
+
+    /**
+     * Add a listener to be notified of a state change.
+     *
+     * @param listener The new listener.
+     * @return This conference.
+     * @hide
+     */
+    public final Conference addListener(Listener listener) {
+        mListeners.add(listener);
+        return this;
+    }
+
+    /**
+     * Removes the specified listener.
+     *
+     * @param listener The listener to remove.
+     * @return This conference.
+     * @hide
+     */
+    public final Conference removeListener(Listener listener) {
+        mListeners.remove(listener);
+        return this;
+    }
+
+    /**
+     * Inform this Conference that the state of its audio output has been changed externally.
+     *
+     * @param state The new audio state.
+     * @hide
+     */
+    final void setAudioState(AudioState state) {
+        Log.d(this, "setAudioState %s", state);
+        mAudioState = state;
+        onAudioStateChanged(state);
+    }
+
+    private void setState(int newState) {
+        if (newState != Connection.STATE_ACTIVE &&
+                newState != Connection.STATE_HOLDING &&
+                newState != Connection.STATE_DISCONNECTED) {
+            Log.w(this, "Unsupported state transition for Conference call.",
+                    Connection.stateToString(newState));
+            return;
+        }
+
+        if (mState != newState) {
+            int oldState = mState;
+            mState = newState;
+            for (Listener l : mListeners) {
+                l.onStateChanged(this, oldState, newState);
+            }
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/Connection.java b/telecomm/java/android/telecom/Connection.java
new file mode 100644
index 0000000..7979e44
--- /dev/null
+++ b/telecomm/java/android/telecom/Connection.java
@@ -0,0 +1,1116 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import com.android.internal.telecom.IVideoCallback;
+import com.android.internal.telecom.IVideoProvider;
+
+import android.net.Uri;
+import android.os.Handler;
+import android.os.IBinder;
+import android.os.Message;
+import android.os.RemoteException;
+import android.view.Surface;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+
+/**
+ * Represents a connection to a remote endpoint that carries voice traffic.
+ * <p>
+ * Implementations create a custom subclass of {@code Connection} and return it to the framework
+ * as the return value of
+ * {@link ConnectionService#onCreateIncomingConnection(PhoneAccountHandle, ConnectionRequest)}
+ * or
+ * {@link ConnectionService#onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
+ * Implementations are then responsible for updating the state of the {@code Connection}, and
+ * must call {@link #destroy()} to signal to the framework that the {@code Connection} is no
+ * longer used and associated resources may be recovered.
+ */
+public abstract class Connection {
+
+    public static final int STATE_INITIALIZING = 0;
+
+    public static final int STATE_NEW = 1;
+
+    public static final int STATE_RINGING = 2;
+
+    public static final int STATE_DIALING = 3;
+
+    public static final int STATE_ACTIVE = 4;
+
+    public static final int STATE_HOLDING = 5;
+
+    public static final int STATE_DISCONNECTED = 6;
+
+    // Flag controlling whether PII is emitted into the logs
+    private static final boolean PII_DEBUG = Log.isLoggable(android.util.Log.DEBUG);
+
+    /** @hide */
+    public abstract static class Listener {
+        public void onStateChanged(Connection c, int state) {}
+        public void onAddressChanged(Connection c, Uri newAddress, int presentation) {}
+        public void onCallerDisplayNameChanged(
+                Connection c, String callerDisplayName, int presentation) {}
+        public void onVideoStateChanged(Connection c, int videoState) {}
+        public void onDisconnected(Connection c, DisconnectCause disconnectCause) {}
+        public void onPostDialWait(Connection c, String remaining) {}
+        public void onRingbackRequested(Connection c, boolean ringback) {}
+        public void onDestroyed(Connection c) {}
+        public void onCallCapabilitiesChanged(Connection c, int callCapabilities) {}
+        public void onVideoProviderChanged(
+                Connection c, VideoProvider videoProvider) {}
+        public void onAudioModeIsVoipChanged(Connection c, boolean isVoip) {}
+        public void onStatusHintsChanged(Connection c, StatusHints statusHints) {}
+        public void onConferenceableConnectionsChanged(
+                Connection c, List<Connection> conferenceableConnections) {}
+        public void onConferenceChanged(Connection c, Conference conference) {}
+    }
+
+    /** @hide */
+    public static abstract class VideoProvider {
+
+        /**
+         * Video is not being received (no protocol pause was issued).
+         */
+        public static final int SESSION_EVENT_RX_PAUSE = 1;
+
+        /**
+         * Video reception has resumed after a SESSION_EVENT_RX_PAUSE.
+         */
+        public static final int SESSION_EVENT_RX_RESUME = 2;
+
+        /**
+         * Video transmission has begun. This occurs after a negotiated start of video transmission
+         * when the underlying protocol has actually begun transmitting video to the remote party.
+         */
+        public static final int SESSION_EVENT_TX_START = 3;
+
+        /**
+         * Video transmission has stopped. This occurs after a negotiated stop of video transmission
+         * when the underlying protocol has actually stopped transmitting video to the remote party.
+         */
+        public static final int SESSION_EVENT_TX_STOP = 4;
+
+        /**
+         * A camera failure has occurred for the selected camera.  The In-Call UI can use this as a
+         * cue to inform the user the camera is not available.
+         */
+        public static final int SESSION_EVENT_CAMERA_FAILURE = 5;
+
+        /**
+         * Issued after {@code SESSION_EVENT_CAMERA_FAILURE} when the camera is once again ready for
+         * operation.  The In-Call UI can use this as a cue to inform the user that the camera has
+         * become available again.
+         */
+        public static final int SESSION_EVENT_CAMERA_READY = 6;
+
+        /**
+         * Session modify request was successful.
+         */
+        public static final int SESSION_MODIFY_REQUEST_SUCCESS = 1;
+
+        /**
+         * Session modify request failed.
+         */
+        public static final int SESSION_MODIFY_REQUEST_FAIL = 2;
+
+        /**
+         * Session modify request ignored due to invalid parameters.
+         */
+        public static final int SESSION_MODIFY_REQUEST_INVALID = 3;
+
+        private static final int MSG_SET_VIDEO_CALLBACK = 1;
+        private static final int MSG_SET_CAMERA = 2;
+        private static final int MSG_SET_PREVIEW_SURFACE = 3;
+        private static final int MSG_SET_DISPLAY_SURFACE = 4;
+        private static final int MSG_SET_DEVICE_ORIENTATION = 5;
+        private static final int MSG_SET_ZOOM = 6;
+        private static final int MSG_SEND_SESSION_MODIFY_REQUEST = 7;
+        private static final int MSG_SEND_SESSION_MODIFY_RESPONSE = 8;
+        private static final int MSG_REQUEST_CAMERA_CAPABILITIES = 9;
+        private static final int MSG_REQUEST_CALL_DATA_USAGE = 10;
+        private static final int MSG_SET_PAUSE_IMAGE = 11;
+
+        private final VideoProvider.VideoProviderHandler
+                mMessageHandler = new VideoProvider.VideoProviderHandler();
+        private final VideoProvider.VideoProviderBinder mBinder;
+        private IVideoCallback mVideoCallback;
+
+        /**
+         * Default handler used to consolidate binder method calls onto a single thread.
+         */
+        private final class VideoProviderHandler extends Handler {
+            @Override
+            public void handleMessage(Message msg) {
+                switch (msg.what) {
+                    case MSG_SET_VIDEO_CALLBACK:
+                        mVideoCallback = IVideoCallback.Stub.asInterface((IBinder) msg.obj);
+                        break;
+                    case MSG_SET_CAMERA:
+                        onSetCamera((String) msg.obj);
+                        break;
+                    case MSG_SET_PREVIEW_SURFACE:
+                        onSetPreviewSurface((Surface) msg.obj);
+                        break;
+                    case MSG_SET_DISPLAY_SURFACE:
+                        onSetDisplaySurface((Surface) msg.obj);
+                        break;
+                    case MSG_SET_DEVICE_ORIENTATION:
+                        onSetDeviceOrientation(msg.arg1);
+                        break;
+                    case MSG_SET_ZOOM:
+                        onSetZoom((Float) msg.obj);
+                        break;
+                    case MSG_SEND_SESSION_MODIFY_REQUEST:
+                        onSendSessionModifyRequest((VideoProfile) msg.obj);
+                        break;
+                    case MSG_SEND_SESSION_MODIFY_RESPONSE:
+                        onSendSessionModifyResponse((VideoProfile) msg.obj);
+                        break;
+                    case MSG_REQUEST_CAMERA_CAPABILITIES:
+                        onRequestCameraCapabilities();
+                        break;
+                    case MSG_REQUEST_CALL_DATA_USAGE:
+                        onRequestCallDataUsage();
+                        break;
+                    case MSG_SET_PAUSE_IMAGE:
+                        onSetPauseImage((String) msg.obj);
+                        break;
+                    default:
+                        break;
+                }
+            }
+        }
+
+        /**
+         * IVideoProvider stub implementation.
+         */
+        private final class VideoProviderBinder extends IVideoProvider.Stub {
+            public void setVideoCallback(IBinder videoCallbackBinder) {
+                mMessageHandler.obtainMessage(
+                        MSG_SET_VIDEO_CALLBACK, videoCallbackBinder).sendToTarget();
+            }
+
+            public void setCamera(String cameraId) {
+                mMessageHandler.obtainMessage(MSG_SET_CAMERA, cameraId).sendToTarget();
+            }
+
+            public void setPreviewSurface(Surface surface) {
+                mMessageHandler.obtainMessage(MSG_SET_PREVIEW_SURFACE, surface).sendToTarget();
+            }
+
+            public void setDisplaySurface(Surface surface) {
+                mMessageHandler.obtainMessage(MSG_SET_DISPLAY_SURFACE, surface).sendToTarget();
+            }
+
+            public void setDeviceOrientation(int rotation) {
+                mMessageHandler.obtainMessage(MSG_SET_DEVICE_ORIENTATION, rotation).sendToTarget();
+            }
+
+            public void setZoom(float value) {
+                mMessageHandler.obtainMessage(MSG_SET_ZOOM, value).sendToTarget();
+            }
+
+            public void sendSessionModifyRequest(VideoProfile requestProfile) {
+                mMessageHandler.obtainMessage(
+                        MSG_SEND_SESSION_MODIFY_REQUEST, requestProfile).sendToTarget();
+            }
+
+            public void sendSessionModifyResponse(VideoProfile responseProfile) {
+                mMessageHandler.obtainMessage(
+                        MSG_SEND_SESSION_MODIFY_RESPONSE, responseProfile).sendToTarget();
+            }
+
+            public void requestCameraCapabilities() {
+                mMessageHandler.obtainMessage(MSG_REQUEST_CAMERA_CAPABILITIES).sendToTarget();
+            }
+
+            public void requestCallDataUsage() {
+                mMessageHandler.obtainMessage(MSG_REQUEST_CALL_DATA_USAGE).sendToTarget();
+            }
+
+            public void setPauseImage(String uri) {
+                mMessageHandler.obtainMessage(MSG_SET_PAUSE_IMAGE, uri).sendToTarget();
+            }
+        }
+
+        public VideoProvider() {
+            mBinder = new VideoProvider.VideoProviderBinder();
+        }
+
+        /**
+         * Returns binder object which can be used across IPC methods.
+         * @hide
+         */
+        public final IVideoProvider getInterface() {
+            return mBinder;
+        }
+
+        /**
+         * Sets the camera to be used for video recording in a video call.
+         *
+         * @param cameraId The id of the camera.
+         */
+        public abstract void onSetCamera(String cameraId);
+
+        /**
+         * Sets the surface to be used for displaying a preview of what the user's camera is
+         * currently capturing.  When video transmission is enabled, this is the video signal which
+         * is sent to the remote device.
+         *
+         * @param surface The surface.
+         */
+        public abstract void onSetPreviewSurface(Surface surface);
+
+        /**
+         * Sets the surface to be used for displaying the video received from the remote device.
+         *
+         * @param surface The surface.
+         */
+        public abstract void onSetDisplaySurface(Surface surface);
+
+        /**
+         * Sets the device orientation, in degrees.  Assumes that a standard portrait orientation of
+         * the device is 0 degrees.
+         *
+         * @param rotation The device orientation, in degrees.
+         */
+        public abstract void onSetDeviceOrientation(int rotation);
+
+        /**
+         * Sets camera zoom ratio.
+         *
+         * @param value The camera zoom ratio.
+         */
+        public abstract void onSetZoom(float value);
+
+        /**
+         * Issues a request to modify the properties of the current session.  The request is
+         * sent to the remote device where it it handled by the In-Call UI.
+         * Some examples of session modification requests: upgrade call from audio to video,
+         * downgrade call from video to audio, pause video.
+         *
+         * @param requestProfile The requested call video properties.
+         */
+        public abstract void onSendSessionModifyRequest(VideoProfile requestProfile);
+
+        /**te
+         * Provides a response to a request to change the current call session video
+         * properties.
+         * This is in response to a request the InCall UI has received via the InCall UI.
+         *
+         * @param responseProfile The response call video properties.
+         */
+        public abstract void onSendSessionModifyResponse(VideoProfile responseProfile);
+
+        /**
+         * Issues a request to the video provider to retrieve the camera capabilities.
+         * Camera capabilities are reported back to the caller via the In-Call UI.
+         */
+        public abstract void onRequestCameraCapabilities();
+
+        /**
+         * Issues a request to the video telephony framework to retrieve the cumulative data usage
+         * for the current call.  Data usage is reported back to the caller via the
+         * InCall UI.
+         */
+        public abstract void onRequestCallDataUsage();
+
+        /**
+         * Provides the video telephony framework with the URI of an image to be displayed to remote
+         * devices when the video signal is paused.
+         *
+         * @param uri URI of image to display.
+         */
+        public abstract void onSetPauseImage(String uri);
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * @param videoProfile The requested video call profile.
+         */
+        public void receiveSessionModifyRequest(VideoProfile videoProfile) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.receiveSessionModifyRequest(videoProfile);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * @param status Status of the session modify request.  Valid values are
+         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_SUCCESS},
+         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_FAIL},
+         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_INVALID}
+         * @param requestedProfile The original request which was sent to the remote device.
+         * @param responseProfile The actual profile changes made by the remote device.
+         */
+        public void receiveSessionModifyResponse(int status,
+                VideoProfile requestedProfile, VideoProfile responseProfile) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.receiveSessionModifyResponse(
+                            status, requestedProfile, responseProfile);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * Valid values are: {@link VideoProvider#SESSION_EVENT_RX_PAUSE},
+         * {@link VideoProvider#SESSION_EVENT_RX_RESUME},
+         * {@link VideoProvider#SESSION_EVENT_TX_START},
+         * {@link VideoProvider#SESSION_EVENT_TX_STOP}
+         *
+         * @param event The event.
+         */
+        public void handleCallSessionEvent(int event) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.handleCallSessionEvent(event);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * @param width  The updated peer video width.
+         * @param height The updated peer video height.
+         */
+        public void changePeerDimensions(int width, int height) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.changePeerDimensions(width, height);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * @param dataUsage The updated data usage.
+         */
+        public void changeCallDataUsage(int dataUsage) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.changeCallDataUsage(dataUsage);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+
+        /**
+         * Invokes callback method defined in In-Call UI.
+         *
+         * @param cameraCapabilities The changed camera capabilities.
+         */
+        public void changeCameraCapabilities(CameraCapabilities cameraCapabilities) {
+            if (mVideoCallback != null) {
+                try {
+                    mVideoCallback.changeCameraCapabilities(cameraCapabilities);
+                } catch (RemoteException ignored) {
+                }
+            }
+        }
+    }
+
+    private final Listener mConnectionDeathListener = new Listener() {
+        @Override
+        public void onDestroyed(Connection c) {
+            if (mConferenceableConnections.remove(c)) {
+                fireOnConferenceableConnectionsChanged();
+            }
+        }
+    };
+
+    /**
+     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
+     * load factor before resizing, 1 means we only expect a single thread to
+     * access the map so make only a single shard
+     */
+    private final Set<Listener> mListeners = Collections.newSetFromMap(
+            new ConcurrentHashMap<Listener, Boolean>(8, 0.9f, 1));
+    private final List<Connection> mConferenceableConnections = new ArrayList<>();
+    private final List<Connection> mUnmodifiableConferenceableConnections =
+            Collections.unmodifiableList(mConferenceableConnections);
+
+    private int mState = STATE_NEW;
+    private AudioState mAudioState;
+    private Uri mAddress;
+    private int mAddressPresentation;
+    private String mCallerDisplayName;
+    private int mCallerDisplayNamePresentation;
+    private boolean mRingbackRequested = false;
+    private int mCallCapabilities;
+    private VideoProvider mVideoProvider;
+    private boolean mAudioModeIsVoip;
+    private StatusHints mStatusHints;
+    private int mVideoState;
+    private DisconnectCause mDisconnectCause;
+    private Conference mConference;
+    private ConnectionService mConnectionService;
+
+    /**
+     * Create a new Connection.
+     */
+    public Connection() {}
+
+    /**
+     * @return The address (e.g., phone number) to which this Connection is currently communicating.
+     */
+    public final Uri getAddress() {
+        return mAddress;
+    }
+
+    /**
+     * @return The presentation requirements for the address.
+     *         See {@link TelecomManager} for valid values.
+     */
+    public final int getAddressPresentation() {
+        return mAddressPresentation;
+    }
+
+    /**
+     * @return The caller display name (CNAP).
+     */
+    public final String getCallerDisplayName() {
+        return mCallerDisplayName;
+    }
+
+    /**
+     * @return The presentation requirements for the handle.
+     *         See {@link TelecomManager} for valid values.
+     */
+    public final int getCallerDisplayNamePresentation() {
+        return mCallerDisplayNamePresentation;
+    }
+
+    /**
+     * @return The state of this Connection.
+     */
+    public final int getState() {
+        return mState;
+    }
+
+    /**
+     * Returns the video state of the call.
+     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#TX_ENABLED},
+     * {@link VideoProfile.VideoState#RX_ENABLED}.
+     *
+     * @return The video state of the call.
+     * @hide
+     */
+    public final int getVideoState() {
+        return mVideoState;
+    }
+
+    /**
+     * @return The audio state of the call, describing how its audio is currently
+     *         being routed by the system. This is {@code null} if this Connection
+     *         does not directly know about its audio state.
+     */
+    public final AudioState getAudioState() {
+        return mAudioState;
+    }
+
+    /**
+     * @return The conference that this connection is a part of.  Null if it is not part of any
+     *         conference.
+     */
+    public final Conference getConference() {
+        return mConference;
+    }
+
+    /**
+     * Returns whether this connection is requesting that the system play a ringback tone
+     * on its behalf.
+     */
+    public final boolean isRingbackRequested() {
+        return mRingbackRequested;
+    }
+
+    /**
+     * @return True if the connection's audio mode is VOIP.
+     */
+    public final boolean getAudioModeIsVoip() {
+        return mAudioModeIsVoip;
+    }
+
+    /**
+     * @return The status hints for this connection.
+     */
+    public final StatusHints getStatusHints() {
+        return mStatusHints;
+    }
+
+    /**
+     * Assign a listener to be notified of state changes.
+     *
+     * @param l A listener.
+     * @return This Connection.
+     *
+     * @hide
+     */
+    public final Connection addConnectionListener(Listener l) {
+        mListeners.add(l);
+        return this;
+    }
+
+    /**
+     * Remove a previously assigned listener that was being notified of state changes.
+     *
+     * @param l A Listener.
+     * @return This Connection.
+     *
+     * @hide
+     */
+    public final Connection removeConnectionListener(Listener l) {
+        if (l != null) {
+            mListeners.remove(l);
+        }
+        return this;
+    }
+
+    /**
+     * @return The {@link DisconnectCause} for this connection.
+     */
+    public final DisconnectCause getDisconnectCause() {
+        return mDisconnectCause;
+    }
+
+    /**
+     * Inform this Connection that the state of its audio output has been changed externally.
+     *
+     * @param state The new audio state.
+     * @hide
+     */
+    final void setAudioState(AudioState state) {
+        Log.d(this, "setAudioState %s", state);
+        mAudioState = state;
+        onAudioStateChanged(state);
+    }
+
+    /**
+     * @param state An integer value of a {@code STATE_*} constant.
+     * @return A string representation of the value.
+     */
+    public static String stateToString(int state) {
+        switch (state) {
+            case STATE_INITIALIZING:
+                return "STATE_INITIALIZING";
+            case STATE_NEW:
+                return "STATE_NEW";
+            case STATE_RINGING:
+                return "STATE_RINGING";
+            case STATE_DIALING:
+                return "STATE_DIALING";
+            case STATE_ACTIVE:
+                return "STATE_ACTIVE";
+            case STATE_HOLDING:
+                return "STATE_HOLDING";
+            case STATE_DISCONNECTED:
+                return "DISCONNECTED";
+            default:
+                Log.wtf(Connection.class, "Unknown state %d", state);
+                return "UNKNOWN";
+        }
+    }
+
+    /**
+     * Returns the connection's {@link PhoneCapabilities}
+     */
+    public final int getCallCapabilities() {
+        return mCallCapabilities;
+    }
+
+    /**
+     * Sets the value of the {@link #getAddress()} property.
+     *
+     * @param address The new address.
+     * @param presentation The presentation requirements for the address.
+     *        See {@link TelecomManager} for valid values.
+     */
+    public final void setAddress(Uri address, int presentation) {
+        Log.d(this, "setAddress %s", address);
+        mAddress = address;
+        mAddressPresentation = presentation;
+        for (Listener l : mListeners) {
+            l.onAddressChanged(this, address, presentation);
+        }
+    }
+
+    /**
+     * Sets the caller display name (CNAP).
+     *
+     * @param callerDisplayName The new display name.
+     * @param presentation The presentation requirements for the handle.
+     *        See {@link TelecomManager} for valid values.
+     */
+    public final void setCallerDisplayName(String callerDisplayName, int presentation) {
+        Log.d(this, "setCallerDisplayName %s", callerDisplayName);
+        mCallerDisplayName = callerDisplayName;
+        mCallerDisplayNamePresentation = presentation;
+        for (Listener l : mListeners) {
+            l.onCallerDisplayNameChanged(this, callerDisplayName, presentation);
+        }
+    }
+
+    /**
+     * Set the video state for the connection.
+     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#TX_ENABLED},
+     * {@link VideoProfile.VideoState#RX_ENABLED}.
+     *
+     * @param videoState The new video state.
+     * @hide
+     */
+    public final void setVideoState(int videoState) {
+        Log.d(this, "setVideoState %d", videoState);
+        mVideoState = videoState;
+        for (Listener l : mListeners) {
+            l.onVideoStateChanged(this, mVideoState);
+        }
+    }
+
+    /**
+     * Sets state to active (e.g., an ongoing call where two or more parties can actively
+     * communicate).
+     */
+    public final void setActive() {
+        setRingbackRequested(false);
+        setState(STATE_ACTIVE);
+    }
+
+    /**
+     * Sets state to ringing (e.g., an inbound ringing call).
+     */
+    public final void setRinging() {
+        setState(STATE_RINGING);
+    }
+
+    /**
+     * Sets state to initializing (this Connection is not yet ready to be used).
+     */
+    public final void setInitializing() {
+        setState(STATE_INITIALIZING);
+    }
+
+    /**
+     * Sets state to initialized (the Connection has been set up and is now ready to be used).
+     */
+    public final void setInitialized() {
+        setState(STATE_NEW);
+    }
+
+    /**
+     * Sets state to dialing (e.g., dialing an outbound call).
+     */
+    public final void setDialing() {
+        setState(STATE_DIALING);
+    }
+
+    /**
+     * Sets state to be on hold.
+     */
+    public final void setOnHold() {
+        setState(STATE_HOLDING);
+    }
+
+    /**
+     * Sets the video call provider.
+     * @param videoProvider The video provider.
+     * @hide
+     */
+    public final void setVideoProvider(VideoProvider videoProvider) {
+        mVideoProvider = videoProvider;
+        for (Listener l : mListeners) {
+            l.onVideoProviderChanged(this, videoProvider);
+        }
+    }
+
+    /** @hide */
+    public final VideoProvider getVideoProvider() {
+        return mVideoProvider;
+    }
+
+    /**
+     * Sets state to disconnected.
+     *
+     * @param disconnectCause The reason for the disconnection, as specified by
+     *         {@link DisconnectCause}.
+     */
+    public final void setDisconnected(DisconnectCause disconnectCause) {
+        mDisconnectCause = disconnectCause;
+        setState(STATE_DISCONNECTED);
+        Log.d(this, "Disconnected with cause %s", disconnectCause);
+        for (Listener l : mListeners) {
+            l.onDisconnected(this, disconnectCause);
+        }
+    }
+
+    /**
+     * TODO: Needs documentation.
+     */
+    public final void setPostDialWait(String remaining) {
+        for (Listener l : mListeners) {
+            l.onPostDialWait(this, remaining);
+        }
+    }
+
+    /**
+     * Requests that the framework play a ringback tone. This is to be invoked by implementations
+     * that do not play a ringback tone themselves in the call's audio stream.
+     *
+     * @param ringback Whether the ringback tone is to be played.
+     */
+    public final void setRingbackRequested(boolean ringback) {
+        if (mRingbackRequested != ringback) {
+            mRingbackRequested = ringback;
+            for (Listener l : mListeners) {
+                l.onRingbackRequested(this, ringback);
+            }
+        }
+    }
+
+    /**
+     * Sets the connection's {@link PhoneCapabilities}.
+     *
+     * @param callCapabilities The new call capabilities.
+     */
+    public final void setCallCapabilities(int callCapabilities) {
+        if (mCallCapabilities != callCapabilities) {
+            mCallCapabilities = callCapabilities;
+            for (Listener l : mListeners) {
+                l.onCallCapabilitiesChanged(this, mCallCapabilities);
+            }
+        }
+    }
+
+    /**
+     * Tears down the Connection object.
+     */
+    public final void destroy() {
+        for (Listener l : mListeners) {
+            l.onDestroyed(this);
+        }
+    }
+
+    /**
+     * Requests that the framework use VOIP audio mode for this connection.
+     *
+     * @param isVoip True if the audio mode is VOIP.
+     */
+    public final void setAudioModeIsVoip(boolean isVoip) {
+        mAudioModeIsVoip = isVoip;
+        for (Listener l : mListeners) {
+            l.onAudioModeIsVoipChanged(this, isVoip);
+        }
+    }
+
+    /**
+     * Sets the label and icon status to display in the in-call UI.
+     *
+     * @param statusHints The status label and icon to set.
+     */
+    public final void setStatusHints(StatusHints statusHints) {
+        mStatusHints = statusHints;
+        for (Listener l : mListeners) {
+            l.onStatusHintsChanged(this, statusHints);
+        }
+    }
+
+    /**
+     * Sets the connections with which this connection can be conferenced.
+     *
+     * @param conferenceableConnections The set of connections this connection can conference with.
+     */
+    public final void setConferenceableConnections(List<Connection> conferenceableConnections) {
+        clearConferenceableList();
+        for (Connection c : conferenceableConnections) {
+            // If statement checks for duplicates in input. It makes it N^2 but we're dealing with a
+            // small amount of items here.
+            if (!mConferenceableConnections.contains(c)) {
+                c.addConnectionListener(mConnectionDeathListener);
+                mConferenceableConnections.add(c);
+            }
+        }
+        fireOnConferenceableConnectionsChanged();
+    }
+
+    /**
+     * Obtains the connections with which this connection can be conferenced.
+     */
+    public final List<Connection> getConferenceableConnections() {
+        return mUnmodifiableConferenceableConnections;
+    }
+
+    /*
+     * @hide
+     */
+    public final void setConnectionService(ConnectionService connectionService) {
+        if (mConnectionService != null) {
+            Log.e(this, new Exception(), "Trying to set ConnectionService on a connection " +
+                    "which is already associated with another ConnectionService.");
+        } else {
+            mConnectionService = connectionService;
+        }
+    }
+
+    /**
+     * @hide
+     */
+    public final void unsetConnectionService(ConnectionService connectionService) {
+        if (mConnectionService != connectionService) {
+            Log.e(this, new Exception(), "Trying to remove ConnectionService from a Connection " +
+                    "that does not belong to the ConnectionService.");
+        } else {
+            mConnectionService = null;
+        }
+    }
+
+    /**
+     * Sets the conference that this connection is a part of. This will fail if the connection is
+     * already part of a conference call. {@link #resetConference} to un-set the conference first.
+     *
+     * @param conference The conference.
+     * @return {@code true} if the conference was successfully set.
+     * @hide
+     */
+    public final boolean setConference(Conference conference) {
+        // We check to see if it is already part of another conference.
+        if (mConference == null) {
+            mConference = conference;
+            if (mConnectionService != null && mConnectionService.containsConference(conference)) {
+                fireConferenceChanged();
+            }
+            return true;
+        }
+        return false;
+    }
+
+    /**
+     * Resets the conference that this connection is a part of.
+     * @hide
+     */
+    public final void resetConference() {
+        if (mConference != null) {
+            Log.d(this, "Conference reset");
+            mConference = null;
+            fireConferenceChanged();
+        }
+    }
+
+    /**
+     * Notifies this Connection that the {@link #getAudioState()} property has a new value.
+     *
+     * @param state The new call audio state.
+     */
+    public void onAudioStateChanged(AudioState state) {}
+
+    /**
+     * Notifies this Connection of an internal state change. This method is called after the
+     * state is changed.
+     *
+     * @param state The new state, one of the {@code STATE_*} constants.
+     */
+    public void onStateChanged(int state) {}
+
+    /**
+     * Notifies this Connection of a request to play a DTMF tone.
+     *
+     * @param c A DTMF character.
+     */
+    public void onPlayDtmfTone(char c) {}
+
+    /**
+     * Notifies this Connection of a request to stop any currently playing DTMF tones.
+     */
+    public void onStopDtmfTone() {}
+
+    /**
+     * Notifies this Connection of a request to disconnect.
+     */
+    public void onDisconnect() {}
+
+    /**
+     * Notifies this Connection of a request to separate from its parent conference.
+     */
+    public void onSeparate() {}
+
+    /**
+     * Notifies this Connection of a request to abort.
+     */
+    public void onAbort() {}
+
+    /**
+     * Notifies this Connection of a request to hold.
+     */
+    public void onHold() {}
+
+    /**
+     * Notifies this Connection of a request to exit a hold state.
+     */
+    public void onUnhold() {}
+
+    /**
+     * Notifies this Connection, which is in {@link #STATE_RINGING}, of
+     * a request to accept.
+     *
+     * @param videoState The video state in which to answer the call.
+     * @hide
+     */
+    public void onAnswer(int videoState) {}
+
+    /**
+     * Notifies this Connection, which is in {@link #STATE_RINGING}, of
+     * a request to accept.
+     */
+    public void onAnswer() {
+        onAnswer(VideoProfile.VideoState.AUDIO_ONLY);
+    }
+
+    /**
+     * Notifies this Connection, which is in {@link #STATE_RINGING}, of
+     * a request to reject.
+     */
+    public void onReject() {}
+
+    /**
+     * Notifies this Connection whether the user wishes to proceed with the post-dial DTMF codes.
+     */
+    public void onPostDialContinue(boolean proceed) {}
+
+    /**
+     * Merge this connection and the specified connection into a conference call.  Once the
+     * connections are merged, the calls should be added to the an existing or new
+     * {@code Conference} instance. For new {@code Conference} instances, use
+     * {@code ConnectionService#addConference}.
+     *
+     * @param otherConnection The connection with which this connection should be conferenced.
+     */
+    public void onConferenceWith(Connection otherConnection) {}
+
+    static String toLogSafePhoneNumber(String number) {
+        // For unknown number, log empty string.
+        if (number == null) {
+            return "";
+        }
+
+        if (PII_DEBUG) {
+            // When PII_DEBUG is true we emit PII.
+            return number;
+        }
+
+        // Do exactly same thing as Uri#toSafeString() does, which will enable us to compare
+        // sanitized phone numbers.
+        StringBuilder builder = new StringBuilder();
+        for (int i = 0; i < number.length(); i++) {
+            char c = number.charAt(i);
+            if (c == '-' || c == '@' || c == '.') {
+                builder.append(c);
+            } else {
+                builder.append('x');
+            }
+        }
+        return builder.toString();
+    }
+
+    private void setState(int state) {
+        if (mState == STATE_DISCONNECTED && mState != state) {
+            Log.d(this, "Connection already DISCONNECTED; cannot transition out of this state.");
+            return;
+        }
+        if (mState != state) {
+            Log.d(this, "setState: %s", stateToString(state));
+            mState = state;
+            onStateChanged(state);
+            for (Listener l : mListeners) {
+                l.onStateChanged(this, state);
+            }
+        }
+    }
+
+    private static class FailureSignalingConnection extends Connection {
+        public FailureSignalingConnection(DisconnectCause disconnectCause) {
+            setDisconnected(disconnectCause);
+        }
+    }
+
+    /**
+     * Return a {@code Connection} which represents a failed connection attempt. The returned
+     * {@code Connection} will have a {@link android.telecom.DisconnectCause} and as specified,
+     * and a {@link #getState()} of {@link #STATE_DISCONNECTED}.
+     * <p>
+     * The returned {@code Connection} can be assumed to {@link #destroy()} itself when appropriate,
+     * so users of this method need not maintain a reference to its return value to destroy it.
+     *
+     * @param disconnectCause The disconnect cause, ({@see android.telecomm.DisconnectCause}).
+     * @return A {@code Connection} which indicates failure.
+     */
+    public static Connection createFailedConnection(DisconnectCause disconnectCause) {
+        return new FailureSignalingConnection(disconnectCause);
+    }
+
+    /**
+     * Return a {@code Connection} which represents a canceled connection attempt. The returned
+     * {@code Connection} will have state {@link #STATE_DISCONNECTED}, and cannot be moved out of
+     * that state. This connection should not be used for anything, and no other
+     * {@code Connection}s should be attempted.
+     * <p>
+     * The returned {@code Connection} can be assumed to {@link #destroy()} itself when appropriate,
+     * so users of this method need not maintain a reference to its return value to destroy it.
+     *
+     * @return A {@code Connection} which indicates that the underlying call should be canceled.
+     */
+    public static Connection createCanceledConnection() {
+        return new FailureSignalingConnection(new DisconnectCause(DisconnectCause.CANCELED));
+    }
+
+    private final void  fireOnConferenceableConnectionsChanged() {
+        for (Listener l : mListeners) {
+            l.onConferenceableConnectionsChanged(this, mConferenceableConnections);
+        }
+    }
+
+    private final void fireConferenceChanged() {
+        for (Listener l : mListeners) {
+            l.onConferenceChanged(this, mConference);
+        }
+    }
+
+    private final void clearConferenceableList() {
+        for (Connection c : mConferenceableConnections) {
+            c.removeConnectionListener(mConnectionDeathListener);
+        }
+        mConferenceableConnections.clear();
+    }
+}
diff --git a/telecomm/java/android/telecom/ConnectionRequest.aidl b/telecomm/java/android/telecom/ConnectionRequest.aidl
new file mode 100644
index 0000000..de39c67
--- /dev/null
+++ b/telecomm/java/android/telecom/ConnectionRequest.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable ConnectionRequest;
diff --git a/telecomm/java/android/telecom/ConnectionRequest.java b/telecomm/java/android/telecom/ConnectionRequest.java
new file mode 100644
index 0000000..71b481b
--- /dev/null
+++ b/telecomm/java/android/telecom/ConnectionRequest.java
@@ -0,0 +1,140 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.net.Uri;
+import android.os.Bundle;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Simple data container encapsulating a request to some entity to
+ * create a new {@link Connection}.
+ */
+public final class ConnectionRequest implements Parcelable {
+
+    // TODO: Token to limit recursive invocations
+    private final PhoneAccountHandle mAccountHandle;
+    private final Uri mAddress;
+    private final Bundle mExtras;
+    private final int mVideoState;
+
+    /**
+     * @param accountHandle The accountHandle which should be used to place the call.
+     * @param handle The handle (e.g., phone number) to which the {@link Connection} is to connect.
+     * @param extras Application-specific extra data.
+     */
+    public ConnectionRequest(
+            PhoneAccountHandle accountHandle,
+            Uri handle,
+            Bundle extras) {
+        this(accountHandle, handle, extras, VideoProfile.VideoState.AUDIO_ONLY);
+    }
+
+    /**
+     * @param accountHandle The accountHandle which should be used to place the call.
+     * @param handle The handle (e.g., phone number) to which the {@link Connection} is to connect.
+     * @param extras Application-specific extra data.
+     * @param videoState Determines the video state for the connection.
+     * @hide
+     */
+    public ConnectionRequest(
+            PhoneAccountHandle accountHandle,
+            Uri handle,
+            Bundle extras,
+            int videoState) {
+        mAccountHandle = accountHandle;
+        mAddress = handle;
+        mExtras = extras;
+        mVideoState = videoState;
+    }
+
+    private ConnectionRequest(Parcel in) {
+        mAccountHandle = in.readParcelable(getClass().getClassLoader());
+        mAddress = in.readParcelable(getClass().getClassLoader());
+        mExtras = in.readParcelable(getClass().getClassLoader());
+        mVideoState = in.readInt();
+    }
+
+    /**
+     * The account which should be used to place the call.
+     */
+    public PhoneAccountHandle getAccountHandle() { return mAccountHandle; }
+
+    /**
+     * The handle (e.g., phone number) to which the {@link Connection} is to connect.
+     */
+    public Uri getAddress() { return mAddress; }
+
+    /**
+     * Application-specific extra data. Used for passing back information from an incoming
+     * call {@code Intent}, and for any proprietary extensions arranged between a client
+     * and servant {@code ConnectionService} which agree on a vocabulary for such data.
+     */
+    public Bundle getExtras() { return mExtras; }
+
+    /**
+     * Describes the video states supported by the client requesting the connection.
+     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#TX_ENABLED},
+     * {@link VideoProfile.VideoState#RX_ENABLED}.
+     *
+     * @return The video state for the connection.
+     * @hide
+     */
+    public int getVideoState() {
+        return mVideoState;
+    }
+
+    @Override
+    public String toString() {
+        return String.format("ConnectionRequest %s %s",
+                mAddress == null
+                        ? Uri.EMPTY
+                        : Connection.toLogSafePhoneNumber(mAddress.toString()),
+                mExtras == null ? "" : mExtras);
+    }
+
+    public static final Creator<ConnectionRequest> CREATOR = new Creator<ConnectionRequest> () {
+        @Override
+        public ConnectionRequest createFromParcel(Parcel source) {
+            return new ConnectionRequest(source);
+        }
+
+        @Override
+        public ConnectionRequest[] newArray(int size) {
+            return new ConnectionRequest[size];
+        }
+    };
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeParcelable(mAccountHandle, 0);
+        destination.writeParcelable(mAddress, 0);
+        destination.writeParcelable(mExtras, 0);
+        destination.writeInt(mVideoState);
+    }
+}
diff --git a/telecomm/java/android/telecom/ConnectionService.java b/telecomm/java/android/telecom/ConnectionService.java
new file mode 100644
index 0000000..3e18bac
--- /dev/null
+++ b/telecomm/java/android/telecom/ConnectionService.java
@@ -0,0 +1,984 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.annotation.SdkConstant;
+import android.app.Service;
+import android.content.ComponentName;
+import android.content.Intent;
+import android.net.Uri;
+import android.os.Handler;
+import android.os.IBinder;
+import android.os.Looper;
+import android.os.Message;
+
+import com.android.internal.os.SomeArgs;
+import com.android.internal.telecom.IConnectionService;
+import com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.RemoteServiceCallback;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.UUID;
+
+/**
+ * A {@link android.app.Service} that provides telephone connections to processes running on an
+ * Android device.
+ */
+public abstract class ConnectionService extends Service {
+    /**
+     * The {@link Intent} that must be declared as handled by the service.
+     */
+    @SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
+    public static final String SERVICE_INTERFACE = "android.telecom.ConnectionService";
+
+    // Flag controlling whether PII is emitted into the logs
+    private static final boolean PII_DEBUG = Log.isLoggable(android.util.Log.DEBUG);
+
+    private static final int MSG_ADD_CONNECTION_SERVICE_ADAPTER = 1;
+    private static final int MSG_CREATE_CONNECTION = 2;
+    private static final int MSG_ABORT = 3;
+    private static final int MSG_ANSWER = 4;
+    private static final int MSG_REJECT = 5;
+    private static final int MSG_DISCONNECT = 6;
+    private static final int MSG_HOLD = 7;
+    private static final int MSG_UNHOLD = 8;
+    private static final int MSG_ON_AUDIO_STATE_CHANGED = 9;
+    private static final int MSG_PLAY_DTMF_TONE = 10;
+    private static final int MSG_STOP_DTMF_TONE = 11;
+    private static final int MSG_CONFERENCE = 12;
+    private static final int MSG_SPLIT_FROM_CONFERENCE = 13;
+    private static final int MSG_ON_POST_DIAL_CONTINUE = 14;
+    private static final int MSG_REMOVE_CONNECTION_SERVICE_ADAPTER = 16;
+    private static final int MSG_ANSWER_VIDEO = 17;
+    private static final int MSG_MERGE_CONFERENCE = 18;
+    private static final int MSG_SWAP_CONFERENCE = 19;
+
+    private static Connection sNullConnection;
+
+    private final Map<String, Connection> mConnectionById = new HashMap<>();
+    private final Map<Connection, String> mIdByConnection = new HashMap<>();
+    private final Map<String, Conference> mConferenceById = new HashMap<>();
+    private final Map<Conference, String> mIdByConference = new HashMap<>();
+    private final RemoteConnectionManager mRemoteConnectionManager =
+            new RemoteConnectionManager(this);
+    private final List<Runnable> mPreInitializationConnectionRequests = new ArrayList<>();
+    private final ConnectionServiceAdapter mAdapter = new ConnectionServiceAdapter();
+
+    private boolean mAreAccountsInitialized = false;
+    private Conference sNullConference;
+
+    private final IBinder mBinder = new IConnectionService.Stub() {
+        @Override
+        public void addConnectionServiceAdapter(IConnectionServiceAdapter adapter) {
+            mHandler.obtainMessage(MSG_ADD_CONNECTION_SERVICE_ADAPTER, adapter).sendToTarget();
+        }
+
+        public void removeConnectionServiceAdapter(IConnectionServiceAdapter adapter) {
+            mHandler.obtainMessage(MSG_REMOVE_CONNECTION_SERVICE_ADAPTER, adapter).sendToTarget();
+        }
+
+        @Override
+        public void createConnection(
+                PhoneAccountHandle connectionManagerPhoneAccount,
+                String id,
+                ConnectionRequest request,
+                boolean isIncoming) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionManagerPhoneAccount;
+            args.arg2 = id;
+            args.arg3 = request;
+            args.argi1 = isIncoming ? 1 : 0;
+            mHandler.obtainMessage(MSG_CREATE_CONNECTION, args).sendToTarget();
+        }
+
+        @Override
+        public void abort(String callId) {
+            mHandler.obtainMessage(MSG_ABORT, callId).sendToTarget();
+        }
+
+        @Override
+        /** @hide */
+        public void answerVideo(String callId, int videoState) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.argi1 = videoState;
+            mHandler.obtainMessage(MSG_ANSWER_VIDEO, args).sendToTarget();
+        }
+
+        @Override
+        public void answer(String callId) {
+            mHandler.obtainMessage(MSG_ANSWER, callId).sendToTarget();
+        }
+
+        @Override
+        public void reject(String callId) {
+            mHandler.obtainMessage(MSG_REJECT, callId).sendToTarget();
+        }
+
+        @Override
+        public void disconnect(String callId) {
+            mHandler.obtainMessage(MSG_DISCONNECT, callId).sendToTarget();
+        }
+
+        @Override
+        public void hold(String callId) {
+            mHandler.obtainMessage(MSG_HOLD, callId).sendToTarget();
+        }
+
+        @Override
+        public void unhold(String callId) {
+            mHandler.obtainMessage(MSG_UNHOLD, callId).sendToTarget();
+        }
+
+        @Override
+        public void onAudioStateChanged(String callId, AudioState audioState) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.arg2 = audioState;
+            mHandler.obtainMessage(MSG_ON_AUDIO_STATE_CHANGED, args).sendToTarget();
+        }
+
+        @Override
+        public void playDtmfTone(String callId, char digit) {
+            mHandler.obtainMessage(MSG_PLAY_DTMF_TONE, digit, 0, callId).sendToTarget();
+        }
+
+        @Override
+        public void stopDtmfTone(String callId) {
+            mHandler.obtainMessage(MSG_STOP_DTMF_TONE, callId).sendToTarget();
+        }
+
+        @Override
+        public void conference(String callId1, String callId2) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId1;
+            args.arg2 = callId2;
+            mHandler.obtainMessage(MSG_CONFERENCE, args).sendToTarget();
+        }
+
+        @Override
+        public void splitFromConference(String callId) {
+            mHandler.obtainMessage(MSG_SPLIT_FROM_CONFERENCE, callId).sendToTarget();
+        }
+
+        @Override
+        public void mergeConference(String callId) {
+            mHandler.obtainMessage(MSG_MERGE_CONFERENCE, callId).sendToTarget();
+        }
+
+        @Override
+        public void swapConference(String callId) {
+            mHandler.obtainMessage(MSG_SWAP_CONFERENCE, callId).sendToTarget();
+        }
+
+        @Override
+        public void onPostDialContinue(String callId, boolean proceed) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.argi1 = proceed ? 1 : 0;
+            mHandler.obtainMessage(MSG_ON_POST_DIAL_CONTINUE, args).sendToTarget();
+        }
+    };
+
+    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
+        @Override
+        public void handleMessage(Message msg) {
+            switch (msg.what) {
+                case MSG_ADD_CONNECTION_SERVICE_ADAPTER:
+                    mAdapter.addAdapter((IConnectionServiceAdapter) msg.obj);
+                    onAdapterAttached();
+                    break;
+                case MSG_REMOVE_CONNECTION_SERVICE_ADAPTER:
+                    mAdapter.removeAdapter((IConnectionServiceAdapter) msg.obj);
+                    break;
+                case MSG_CREATE_CONNECTION: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        final PhoneAccountHandle connectionManagerPhoneAccount =
+                                (PhoneAccountHandle) args.arg1;
+                        final String id = (String) args.arg2;
+                        final ConnectionRequest request = (ConnectionRequest) args.arg3;
+                        final boolean isIncoming = args.argi1 == 1;
+                        if (!mAreAccountsInitialized) {
+                            Log.d(this, "Enqueueing pre-init request %s", id);
+                            mPreInitializationConnectionRequests.add(new Runnable() {
+                                @Override
+                                public void run() {
+                                    createConnection(
+                                            connectionManagerPhoneAccount,
+                                            id,
+                                            request,
+                                            isIncoming);
+                                }
+                            });
+                        } else {
+                            createConnection(
+                                    connectionManagerPhoneAccount,
+                                    id,
+                                    request,
+                                    isIncoming);
+                        }
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_ABORT:
+                    abort((String) msg.obj);
+                    break;
+                case MSG_ANSWER:
+                    answer((String) msg.obj);
+                    break;
+                case MSG_ANSWER_VIDEO: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        String callId = (String) args.arg1;
+                        int videoState = args.argi1;
+                        answerVideo(callId, videoState);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_REJECT:
+                    reject((String) msg.obj);
+                    break;
+                case MSG_DISCONNECT:
+                    disconnect((String) msg.obj);
+                    break;
+                case MSG_HOLD:
+                    hold((String) msg.obj);
+                    break;
+                case MSG_UNHOLD:
+                    unhold((String) msg.obj);
+                    break;
+                case MSG_ON_AUDIO_STATE_CHANGED: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        String callId = (String) args.arg1;
+                        AudioState audioState = (AudioState) args.arg2;
+                        onAudioStateChanged(callId, audioState);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_PLAY_DTMF_TONE:
+                    playDtmfTone((String) msg.obj, (char) msg.arg1);
+                    break;
+                case MSG_STOP_DTMF_TONE:
+                    stopDtmfTone((String) msg.obj);
+                    break;
+                case MSG_CONFERENCE: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        String callId1 = (String) args.arg1;
+                        String callId2 = (String) args.arg2;
+                        conference(callId1, callId2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SPLIT_FROM_CONFERENCE:
+                    splitFromConference((String) msg.obj);
+                    break;
+                case MSG_MERGE_CONFERENCE:
+                    mergeConference((String) msg.obj);
+                    break;
+                case MSG_SWAP_CONFERENCE:
+                    swapConference((String) msg.obj);
+                    break;
+                case MSG_ON_POST_DIAL_CONTINUE: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        String callId = (String) args.arg1;
+                        boolean proceed = (args.argi1 == 1);
+                        onPostDialContinue(callId, proceed);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                default:
+                    break;
+            }
+        }
+    };
+
+    private final Conference.Listener mConferenceListener = new Conference.Listener() {
+        @Override
+        public void onStateChanged(Conference conference, int oldState, int newState) {
+            String id = mIdByConference.get(conference);
+            switch (newState) {
+                case Connection.STATE_ACTIVE:
+                    mAdapter.setActive(id);
+                    break;
+                case Connection.STATE_HOLDING:
+                    mAdapter.setOnHold(id);
+                    break;
+                case Connection.STATE_DISCONNECTED:
+                    // handled by onDisconnected
+                    break;
+            }
+        }
+
+        @Override
+        public void onDisconnected(Conference conference, DisconnectCause disconnectCause) {
+            String id = mIdByConference.get(conference);
+            mAdapter.setDisconnected(id, disconnectCause);
+        }
+
+        @Override
+        public void onConnectionAdded(Conference conference, Connection connection) {
+        }
+
+        @Override
+        public void onConnectionRemoved(Conference conference, Connection connection) {
+        }
+
+        @Override
+        public void onDestroyed(Conference conference) {
+            removeConference(conference);
+        }
+
+        @Override
+        public void onCapabilitiesChanged(Conference conference, int capabilities) {
+            String id = mIdByConference.get(conference);
+            Log.d(this, "call capabilities: conference: %s",
+                    PhoneCapabilities.toString(capabilities));
+            mAdapter.setCallCapabilities(id, capabilities);
+        }
+    };
+
+    private final Connection.Listener mConnectionListener = new Connection.Listener() {
+        @Override
+        public void onStateChanged(Connection c, int state) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "Adapter set state %s %s", id, Connection.stateToString(state));
+            switch (state) {
+                case Connection.STATE_ACTIVE:
+                    mAdapter.setActive(id);
+                    break;
+                case Connection.STATE_DIALING:
+                    mAdapter.setDialing(id);
+                    break;
+                case Connection.STATE_DISCONNECTED:
+                    // Handled in onDisconnected()
+                    break;
+                case Connection.STATE_HOLDING:
+                    mAdapter.setOnHold(id);
+                    break;
+                case Connection.STATE_NEW:
+                    // Nothing to tell Telecom
+                    break;
+                case Connection.STATE_RINGING:
+                    mAdapter.setRinging(id);
+                    break;
+            }
+        }
+
+        @Override
+        public void onDisconnected(Connection c, DisconnectCause disconnectCause) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "Adapter set disconnected %s", disconnectCause);
+            mAdapter.setDisconnected(id, disconnectCause);
+        }
+
+        @Override
+        public void onVideoStateChanged(Connection c, int videoState) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "Adapter set video state %d", videoState);
+            mAdapter.setVideoState(id, videoState);
+        }
+
+        @Override
+        public void onAddressChanged(Connection c, Uri address, int presentation) {
+            String id = mIdByConnection.get(c);
+            mAdapter.setAddress(id, address, presentation);
+        }
+
+        @Override
+        public void onCallerDisplayNameChanged(
+                Connection c, String callerDisplayName, int presentation) {
+            String id = mIdByConnection.get(c);
+            mAdapter.setCallerDisplayName(id, callerDisplayName, presentation);
+        }
+
+        @Override
+        public void onDestroyed(Connection c) {
+            removeConnection(c);
+        }
+
+        @Override
+        public void onPostDialWait(Connection c, String remaining) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "Adapter onPostDialWait %s, %s", c, remaining);
+            mAdapter.onPostDialWait(id, remaining);
+        }
+
+        @Override
+        public void onRingbackRequested(Connection c, boolean ringback) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "Adapter onRingback %b", ringback);
+            mAdapter.setRingbackRequested(id, ringback);
+        }
+
+        @Override
+        public void onCallCapabilitiesChanged(Connection c, int capabilities) {
+            String id = mIdByConnection.get(c);
+            Log.d(this, "capabilities: parcelableconnection: %s",
+                    PhoneCapabilities.toString(capabilities));
+            mAdapter.setCallCapabilities(id, capabilities);
+        }
+
+        @Override
+        public void onVideoProviderChanged(Connection c, Connection.VideoProvider videoProvider) {
+            String id = mIdByConnection.get(c);
+            mAdapter.setVideoProvider(id, videoProvider);
+        }
+
+        @Override
+        public void onAudioModeIsVoipChanged(Connection c, boolean isVoip) {
+            String id = mIdByConnection.get(c);
+            mAdapter.setIsVoipAudioMode(id, isVoip);
+        }
+
+        @Override
+        public void onStatusHintsChanged(Connection c, StatusHints statusHints) {
+            String id = mIdByConnection.get(c);
+            mAdapter.setStatusHints(id, statusHints);
+        }
+
+        @Override
+        public void onConferenceableConnectionsChanged(
+                Connection connection, List<Connection> conferenceableConnections) {
+            mAdapter.setConferenceableConnections(
+                    mIdByConnection.get(connection),
+                    createConnectionIdList(conferenceableConnections));
+        }
+
+        @Override
+        public void onConferenceChanged(Connection connection, Conference conference) {
+            String id = mIdByConnection.get(connection);
+            if (id != null) {
+                String conferenceId = null;
+                if (conference != null) {
+                    conferenceId = mIdByConference.get(conference);
+                }
+                mAdapter.setIsConferenced(id, conferenceId);
+            }
+        }
+    };
+
+    /** {@inheritDoc} */
+    @Override
+    public final IBinder onBind(Intent intent) {
+        return mBinder;
+    }
+
+    /** {@inheritDoc} */
+    @Override
+    public boolean onUnbind(Intent intent) {
+        endAllConnections();
+        return super.onUnbind(intent);
+    }
+
+    /**
+     * This can be used by telecom to either create a new outgoing call or attach to an existing
+     * incoming call. In either case, telecom will cycle through a set of services and call
+     * createConnection util a connection service cancels the process or completes it successfully.
+     */
+    private void createConnection(
+            final PhoneAccountHandle callManagerAccount,
+            final String callId,
+            final ConnectionRequest request,
+            boolean isIncoming) {
+        Log.d(this, "createConnection, callManagerAccount: %s, callId: %s, request: %s, " +
+                "isIncoming: %b", callManagerAccount, callId, request, isIncoming);
+
+        Connection connection = isIncoming
+                ? onCreateIncomingConnection(callManagerAccount, request)
+                : onCreateOutgoingConnection(callManagerAccount, request);
+        Log.d(this, "createConnection, connection: %s", connection);
+        if (connection == null) {
+            connection = Connection.createFailedConnection(
+                    new DisconnectCause(DisconnectCause.ERROR));
+        }
+
+        if (connection.getState() != Connection.STATE_DISCONNECTED) {
+            addConnection(callId, connection);
+        }
+
+        Uri address = connection.getAddress();
+        String number = address == null ? "null" : address.getSchemeSpecificPart();
+        Log.v(this, "createConnection, number: %s, state: %s, capabilities: %s",
+                Connection.toLogSafePhoneNumber(number),
+                Connection.stateToString(connection.getState()),
+                PhoneCapabilities.toString(connection.getCallCapabilities()));
+
+        Log.d(this, "createConnection, calling handleCreateConnectionSuccessful %s", callId);
+        mAdapter.handleCreateConnectionComplete(
+                callId,
+                request,
+                new ParcelableConnection(
+                        request.getAccountHandle(),
+                        connection.getState(),
+                        connection.getCallCapabilities(),
+                        connection.getAddress(),
+                        connection.getAddressPresentation(),
+                        connection.getCallerDisplayName(),
+                        connection.getCallerDisplayNamePresentation(),
+                        connection.getVideoProvider() == null ?
+                                null : connection.getVideoProvider().getInterface(),
+                        connection.getVideoState(),
+                        connection.isRingbackRequested(),
+                        connection.getAudioModeIsVoip(),
+                        connection.getStatusHints(),
+                        connection.getDisconnectCause(),
+                        createConnectionIdList(connection.getConferenceableConnections())));
+    }
+
+    private void abort(String callId) {
+        Log.d(this, "abort %s", callId);
+        findConnectionForAction(callId, "abort").onAbort();
+    }
+
+    private void answerVideo(String callId, int videoState) {
+        Log.d(this, "answerVideo %s", callId);
+        findConnectionForAction(callId, "answer").onAnswer(videoState);
+    }
+
+    private void answer(String callId) {
+        Log.d(this, "answer %s", callId);
+        findConnectionForAction(callId, "answer").onAnswer();
+    }
+
+    private void reject(String callId) {
+        Log.d(this, "reject %s", callId);
+        findConnectionForAction(callId, "reject").onReject();
+    }
+
+    private void disconnect(String callId) {
+        Log.d(this, "disconnect %s", callId);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "disconnect").onDisconnect();
+        } else {
+            findConferenceForAction(callId, "disconnect").onDisconnect();
+        }
+    }
+
+    private void hold(String callId) {
+        Log.d(this, "hold %s", callId);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "hold").onHold();
+        } else {
+            findConferenceForAction(callId, "hold").onHold();
+        }
+    }
+
+    private void unhold(String callId) {
+        Log.d(this, "unhold %s", callId);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "unhold").onUnhold();
+        } else {
+            findConferenceForAction(callId, "unhold").onUnhold();
+        }
+    }
+
+    private void onAudioStateChanged(String callId, AudioState audioState) {
+        Log.d(this, "onAudioStateChanged %s %s", callId, audioState);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "onAudioStateChanged").setAudioState(audioState);
+        } else {
+            findConferenceForAction(callId, "onAudioStateChanged").setAudioState(audioState);
+        }
+    }
+
+    private void playDtmfTone(String callId, char digit) {
+        Log.d(this, "playDtmfTone %s %c", callId, digit);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "playDtmfTone").onPlayDtmfTone(digit);
+        } else {
+            findConferenceForAction(callId, "playDtmfTone").onPlayDtmfTone(digit);
+        }
+    }
+
+    private void stopDtmfTone(String callId) {
+        Log.d(this, "stopDtmfTone %s", callId);
+        if (mConnectionById.containsKey(callId)) {
+            findConnectionForAction(callId, "stopDtmfTone").onStopDtmfTone();
+        } else {
+            findConferenceForAction(callId, "stopDtmfTone").onStopDtmfTone();
+        }
+    }
+
+    private void conference(String callId1, String callId2) {
+        Log.d(this, "conference %s, %s", callId1, callId2);
+
+        Connection connection1 = findConnectionForAction(callId1, "conference");
+        if (connection1 == getNullConnection()) {
+            Log.w(this, "Connection1 missing in conference request %s.", callId1);
+            return;
+        }
+
+        Connection connection2 = findConnectionForAction(callId2, "conference");
+        if (connection2 == getNullConnection()) {
+            Log.w(this, "Connection2 missing in conference request %s.", callId2);
+            return;
+        }
+
+        onConference(connection1, connection2);
+    }
+
+    private void splitFromConference(String callId) {
+        Log.d(this, "splitFromConference(%s)", callId);
+
+        Connection connection = findConnectionForAction(callId, "splitFromConference");
+        if (connection == getNullConnection()) {
+            Log.w(this, "Connection missing in conference request %s.", callId);
+            return;
+        }
+
+        Conference conference = connection.getConference();
+        if (conference != null) {
+            conference.onSeparate(connection);
+        }
+    }
+
+    private void mergeConference(String callId) {
+        Log.d(this, "mergeConference(%s)", callId);
+        Conference conference = findConferenceForAction(callId, "mergeConference");
+        if (conference != null) {
+            conference.onMerge();
+        }
+    }
+
+    private void swapConference(String callId) {
+        Log.d(this, "swapConference(%s)", callId);
+        Conference conference = findConferenceForAction(callId, "swapConference");
+        if (conference != null) {
+            conference.onSwap();
+        }
+    }
+
+    private void onPostDialContinue(String callId, boolean proceed) {
+        Log.d(this, "onPostDialContinue(%s)", callId);
+        findConnectionForAction(callId, "stopDtmfTone").onPostDialContinue(proceed);
+    }
+
+    private void onAdapterAttached() {
+        if (mAreAccountsInitialized) {
+            // No need to query again if we already did it.
+            return;
+        }
+
+        mAdapter.queryRemoteConnectionServices(new RemoteServiceCallback.Stub() {
+            @Override
+            public void onResult(
+                    final List<ComponentName> componentNames,
+                    final List<IBinder> services) {
+                mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        for (int i = 0; i < componentNames.size() && i < services.size(); i++) {
+                            mRemoteConnectionManager.addConnectionService(
+                                    componentNames.get(i),
+                                    IConnectionService.Stub.asInterface(services.get(i)));
+                        }
+                        onAccountsInitialized();
+                        Log.d(this, "remote connection services found: " + services);
+                    }
+                });
+            }
+
+            @Override
+            public void onError() {
+                mHandler.post(new Runnable() {
+                    @Override
+                    public void run() {
+                        mAreAccountsInitialized = true;
+                    }
+                });
+            }
+        });
+    }
+
+    /**
+     * Ask some other {@code ConnectionService} to create a {@code RemoteConnection} given an
+     * incoming request. This is used to attach to existing incoming calls.
+     *
+     * @param connectionManagerPhoneAccount See description at
+     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
+     * @param request Details about the incoming call.
+     * @return The {@code Connection} object to satisfy this call, or {@code null} to
+     *         not handle the call.
+     */
+    public final RemoteConnection createRemoteIncomingConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request) {
+        return mRemoteConnectionManager.createRemoteConnection(
+                connectionManagerPhoneAccount, request, true);
+    }
+
+    /**
+     * Ask some other {@code ConnectionService} to create a {@code RemoteConnection} given an
+     * outgoing request. This is used to initiate new outgoing calls.
+     *
+     * @param connectionManagerPhoneAccount See description at
+     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
+     * @param request Details about the incoming call.
+     * @return The {@code Connection} object to satisfy this call, or {@code null} to
+     *         not handle the call.
+     */
+    public final RemoteConnection createRemoteOutgoingConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request) {
+        return mRemoteConnectionManager.createRemoteConnection(
+                connectionManagerPhoneAccount, request, false);
+    }
+
+    /**
+     * Adds two {@code RemoteConnection}s to some {@code RemoteConference}.
+     */
+    public final void conferenceRemoteConnections(
+            RemoteConnection a,
+            RemoteConnection b) {
+        mRemoteConnectionManager.conferenceRemoteConnections(a, b);
+    }
+
+    /**
+     * Adds a new conference call. When a conference call is created either as a result of an
+     * explicit request via {@link #onConference} or otherwise, the connection service should supply
+     * an instance of {@link Conference} by invoking this method. A conference call provided by this
+     * method will persist until {@link Conference#destroy} is invoked on the conference instance.
+     *
+     * @param conference The new conference object.
+     */
+    public final void addConference(Conference conference) {
+        String id = addConferenceInternal(conference);
+        if (id != null) {
+            List<String> connectionIds = new ArrayList<>(2);
+            for (Connection connection : conference.getConnections()) {
+                if (mIdByConnection.containsKey(connection)) {
+                    connectionIds.add(mIdByConnection.get(connection));
+                }
+            }
+            ParcelableConference parcelableConference = new ParcelableConference(
+                    conference.getPhoneAccountHandle(),
+                    conference.getState(),
+                    conference.getCapabilities(),
+                    connectionIds);
+            mAdapter.addConferenceCall(id, parcelableConference);
+
+            // Go through any child calls and set the parent.
+            for (Connection connection : conference.getConnections()) {
+                String connectionId = mIdByConnection.get(connection);
+                if (connectionId != null) {
+                    mAdapter.setIsConferenced(connectionId, id);
+                }
+            }
+        }
+    }
+
+    /**
+     * Returns all the active {@code Connection}s for which this {@code ConnectionService}
+     * has taken responsibility.
+     *
+     * @return A collection of {@code Connection}s created by this {@code ConnectionService}.
+     */
+    public final Collection<Connection> getAllConnections() {
+        return mConnectionById.values();
+    }
+
+    /**
+     * Create a {@code Connection} given an incoming request. This is used to attach to existing
+     * incoming calls.
+     *
+     * @param connectionManagerPhoneAccount See description at
+     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
+     * @param request Details about the incoming call.
+     * @return The {@code Connection} object to satisfy this call, or {@code null} to
+     *         not handle the call.
+     */
+    public Connection onCreateIncomingConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request) {
+        return null;
+    }
+
+    /**
+     * Create a {@code Connection} given an outgoing request. This is used to initiate new
+     * outgoing calls.
+     *
+     * @param connectionManagerPhoneAccount The connection manager account to use for managing
+     *         this call.
+     *         <p>
+     *         If this parameter is not {@code null}, it means that this {@code ConnectionService}
+     *         has registered one or more {@code PhoneAccount}s having
+     *         {@link PhoneAccount#CAPABILITY_CONNECTION_MANAGER}. This parameter will contain
+     *         one of these {@code PhoneAccount}s, while the {@code request} will contain another
+     *         (usually but not always distinct) {@code PhoneAccount} to be used for actually
+     *         making the connection.
+     *         <p>
+     *         If this parameter is {@code null}, it means that this {@code ConnectionService} is
+     *         being asked to make a direct connection. The
+     *         {@link ConnectionRequest#getAccountHandle()} of parameter {@code request} will be
+     *         a {@code PhoneAccount} registered by this {@code ConnectionService} to use for
+     *         making the connection.
+     * @param request Details about the outgoing call.
+     * @return The {@code Connection} object to satisfy this call, or the result of an invocation
+     *         of {@link Connection#createFailedConnection(DisconnectCause)} to not handle the call.
+     */
+    public Connection onCreateOutgoingConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request) {
+        return null;
+    }
+
+    /**
+     * Conference two specified connections. Invoked when the user has made a request to merge the
+     * specified connections into a conference call. In response, the connection service should
+     * create an instance of {@link Conference} and pass it into {@link #addConference}.
+     *
+     * @param connection1 A connection to merge into a conference call.
+     * @param connection2 A connection to merge into a conference call.
+     */
+    public void onConference(Connection connection1, Connection connection2) {}
+
+    public void onRemoteConferenceAdded(RemoteConference conference) {}
+
+    /**
+     * @hide
+     */
+    public boolean containsConference(Conference conference) {
+        return mIdByConference.containsKey(conference);
+    }
+
+    /** {@hide} */
+    void addRemoteConference(RemoteConference remoteConference) {
+        onRemoteConferenceAdded(remoteConference);
+    }
+
+    private void onAccountsInitialized() {
+        mAreAccountsInitialized = true;
+        for (Runnable r : mPreInitializationConnectionRequests) {
+            r.run();
+        }
+        mPreInitializationConnectionRequests.clear();
+    }
+
+    private void addConnection(String callId, Connection connection) {
+        mConnectionById.put(callId, connection);
+        mIdByConnection.put(connection, callId);
+        connection.addConnectionListener(mConnectionListener);
+        connection.setConnectionService(this);
+    }
+
+    private void removeConnection(Connection connection) {
+        String id = mIdByConnection.get(connection);
+        connection.unsetConnectionService(this);
+        connection.removeConnectionListener(mConnectionListener);
+        mConnectionById.remove(mIdByConnection.get(connection));
+        mIdByConnection.remove(connection);
+        mAdapter.removeCall(id);
+    }
+
+    private String addConferenceInternal(Conference conference) {
+        if (mIdByConference.containsKey(conference)) {
+            Log.w(this, "Re-adding an existing conference: %s.", conference);
+        } else if (conference != null) {
+            String id = UUID.randomUUID().toString();
+            mConferenceById.put(id, conference);
+            mIdByConference.put(conference, id);
+            conference.addListener(mConferenceListener);
+            return id;
+        }
+
+        return null;
+    }
+
+    private void removeConference(Conference conference) {
+        if (mIdByConference.containsKey(conference)) {
+            conference.removeListener(mConferenceListener);
+
+            String id = mIdByConference.get(conference);
+            mConferenceById.remove(id);
+            mIdByConference.remove(conference);
+            mAdapter.removeCall(id);
+        }
+    }
+
+    private Connection findConnectionForAction(String callId, String action) {
+        if (mConnectionById.containsKey(callId)) {
+            return mConnectionById.get(callId);
+        }
+        Log.w(this, "%s - Cannot find Connection %s", action, callId);
+        return getNullConnection();
+    }
+
+    static synchronized Connection getNullConnection() {
+        if (sNullConnection == null) {
+            sNullConnection = new Connection() {};
+        }
+        return sNullConnection;
+    }
+
+    private Conference findConferenceForAction(String conferenceId, String action) {
+        if (mConferenceById.containsKey(conferenceId)) {
+            return mConferenceById.get(conferenceId);
+        }
+        Log.w(this, "%s - Cannot find conference %s", action, conferenceId);
+        return getNullConference();
+    }
+
+    private List<String> createConnectionIdList(List<Connection> connections) {
+        List<String> ids = new ArrayList<>();
+        for (Connection c : connections) {
+            if (mIdByConnection.containsKey(c)) {
+                ids.add(mIdByConnection.get(c));
+            }
+        }
+        Collections.sort(ids);
+        return ids;
+    }
+
+    private Conference getNullConference() {
+        if (sNullConference == null) {
+            sNullConference = new Conference(null) {};
+        }
+        return sNullConference;
+    }
+
+    private void endAllConnections() {
+        // Unbound from telecomm.  We should end all connections and conferences.
+        for (Connection connection : mIdByConnection.keySet()) {
+            // only operate on top-level calls. Conference calls will be removed on their own.
+            if (connection.getConference() == null) {
+                connection.onDisconnect();
+            }
+        }
+        for (Conference conference : mIdByConference.keySet()) {
+            conference.onDisconnect();
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/ConnectionServiceAdapter.java b/telecomm/java/android/telecom/ConnectionServiceAdapter.java
new file mode 100644
index 0000000..c676172
--- /dev/null
+++ b/telecomm/java/android/telecom/ConnectionServiceAdapter.java
@@ -0,0 +1,347 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.net.Uri;
+import android.os.IBinder.DeathRecipient;
+import android.os.RemoteException;
+
+import com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.RemoteServiceCallback;
+
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+
+/**
+ * Provides methods for IConnectionService implementations to interact with the system phone app.
+ *
+ * @hide
+ */
+final class ConnectionServiceAdapter implements DeathRecipient {
+    /**
+     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
+     * load factor before resizing, 1 means we only expect a single thread to
+     * access the map so make only a single shard
+     */
+    private final Set<IConnectionServiceAdapter> mAdapters = Collections.newSetFromMap(
+            new ConcurrentHashMap<IConnectionServiceAdapter, Boolean>(8, 0.9f, 1));
+
+    ConnectionServiceAdapter() {
+    }
+
+    void addAdapter(IConnectionServiceAdapter adapter) {
+        if (mAdapters.add(adapter)) {
+            try {
+                adapter.asBinder().linkToDeath(this, 0);
+            } catch (RemoteException e) {
+                mAdapters.remove(adapter);
+            }
+        }
+    }
+
+    void removeAdapter(IConnectionServiceAdapter adapter) {
+        if (adapter != null && mAdapters.remove(adapter)) {
+            adapter.asBinder().unlinkToDeath(this, 0);
+        }
+    }
+
+    /** ${inheritDoc} */
+    @Override
+    public void binderDied() {
+        Iterator<IConnectionServiceAdapter> it = mAdapters.iterator();
+        while (it.hasNext()) {
+            IConnectionServiceAdapter adapter = it.next();
+            if (!adapter.asBinder().isBinderAlive()) {
+                it.remove();
+                adapter.asBinder().unlinkToDeath(this, 0);
+            }
+        }
+    }
+
+    void handleCreateConnectionComplete(
+            String id,
+            ConnectionRequest request,
+            ParcelableConnection connection) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.handleCreateConnectionComplete(id, request, connection);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets a call's state to active (e.g., an ongoing call where two parties can actively
+     * communicate).
+     *
+     * @param callId The unique ID of the call whose state is changing to active.
+     */
+    void setActive(String callId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setActive(callId);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets a call's state to ringing (e.g., an inbound ringing call).
+     *
+     * @param callId The unique ID of the call whose state is changing to ringing.
+     */
+    void setRinging(String callId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setRinging(callId);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets a call's state to dialing (e.g., dialing an outbound call).
+     *
+     * @param callId The unique ID of the call whose state is changing to dialing.
+     */
+    void setDialing(String callId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setDialing(callId);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets a call's state to disconnected.
+     *
+     * @param callId The unique ID of the call whose state is changing to disconnected.
+     * @param disconnectCause The reason for the disconnection, as described by
+     *            {@link android.telecomm.DisconnectCause}.
+     */
+    void setDisconnected(String callId, DisconnectCause disconnectCause) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setDisconnected(callId, disconnectCause);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets a call's state to be on hold.
+     *
+     * @param callId - The unique ID of the call whose state is changing to be on hold.
+     */
+    void setOnHold(String callId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setOnHold(callId);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Asks Telecom to start or stop a ringback tone for a call.
+     *
+     * @param callId The unique ID of the call whose ringback is being changed.
+     * @param ringback Whether Telecom should start playing a ringback tone.
+     */
+    void setRingbackRequested(String callId, boolean ringback) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setRingbackRequested(callId, ringback);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    void setCallCapabilities(String callId, int capabilities) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setCallCapabilities(callId, capabilities);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    /**
+     * Indicates whether or not the specified call is currently conferenced into the specified
+     * conference call.
+     *
+     * @param callId The unique ID of the call being conferenced.
+     * @param conferenceCallId The unique ID of the conference call. Null if call is not
+     *            conferenced.
+     */
+    void setIsConferenced(String callId, String conferenceCallId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                Log.d(this, "sending connection %s with conference %s", callId, conferenceCallId);
+                adapter.setIsConferenced(callId, conferenceCallId);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    /**
+     * Indicates that the call no longer exists. Can be used with either a call or a conference
+     * call.
+     *
+     * @param callId The unique ID of the call.
+     */
+    void removeCall(String callId) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.removeCall(callId);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    void onPostDialWait(String callId, String remaining) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.onPostDialWait(callId, remaining);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    /**
+     * Indicates that a new conference call has been created.
+     *
+     * @param callId The unique ID of the conference call.
+     */
+    void addConferenceCall(String callId, ParcelableConference parcelableConference) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.addConferenceCall(callId, parcelableConference);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    /**
+     * Retrieves a list of remote connection services usable to place calls.
+     */
+    void queryRemoteConnectionServices(RemoteServiceCallback callback) {
+        // Only supported when there is only one adapter.
+        if (mAdapters.size() == 1) {
+            try {
+                mAdapters.iterator().next().queryRemoteConnectionServices(callback);
+            } catch (RemoteException e) {
+                Log.e(this, e, "Exception trying to query for remote CSs");
+            }
+        }
+    }
+
+    /**
+     * Sets the call video provider for a call.
+     *
+     * @param callId The unique ID of the call to set with the given call video provider.
+     * @param videoProvider The call video provider instance to set on the call.
+     */
+    void setVideoProvider(
+            String callId, Connection.VideoProvider videoProvider) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setVideoProvider(
+                        callId,
+                        videoProvider == null ? null : videoProvider.getInterface());
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Requests that the framework use VOIP audio mode for this connection.
+     *
+     * @param callId The unique ID of the call to set with the given call video provider.
+     * @param isVoip True if the audio mode is VOIP.
+     */
+    void setIsVoipAudioMode(String callId, boolean isVoip) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setIsVoipAudioMode(callId, isVoip);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    void setStatusHints(String callId, StatusHints statusHints) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setStatusHints(callId, statusHints);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    void setAddress(String callId, Uri address, int presentation) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setAddress(callId, address, presentation);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    void setCallerDisplayName(String callId, String callerDisplayName, int presentation) {
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setCallerDisplayName(callId, callerDisplayName, presentation);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    /**
+     * Sets the video state associated with a call.
+     *
+     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#TX_ENABLED},
+     * {@link VideoProfile.VideoState#RX_ENABLED}.
+     *
+     * @param callId The unique ID of the call to set the video state for.
+     * @param videoState The video state.
+     */
+    void setVideoState(String callId, int videoState) {
+        Log.v(this, "setVideoState: %d", videoState);
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setVideoState(callId, videoState);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    void setConferenceableConnections(String callId, List<String> conferenceableCallIds) {
+        Log.v(this, "setConferenceableConnections: %s, %s", callId, conferenceableCallIds);
+        for (IConnectionServiceAdapter adapter : mAdapters) {
+            try {
+                adapter.setConferenceableConnections(callId, conferenceableCallIds);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/ConnectionServiceAdapterServant.java b/telecomm/java/android/telecom/ConnectionServiceAdapterServant.java
new file mode 100644
index 0000000..217dbc3
--- /dev/null
+++ b/telecomm/java/android/telecom/ConnectionServiceAdapterServant.java
@@ -0,0 +1,357 @@
+/*
+ * Copyright (C) 2014 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
+ R* limitations under the License.
+ */
+
+package android.telecom;
+
+import android.net.Uri;
+import android.os.Handler;
+import android.os.Message;
+import android.os.RemoteException;
+
+import com.android.internal.os.SomeArgs;
+import com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.IVideoProvider;
+import com.android.internal.telecom.RemoteServiceCallback;
+
+import java.util.List;
+
+/**
+ * A component that provides an RPC servant implementation of {@link IConnectionServiceAdapter},
+ * posting incoming messages on the main thread on a client-supplied delegate object.
+ *
+ * TODO: Generate this and similar classes using a compiler starting from AIDL interfaces.
+ *
+ * @hide
+ */
+final class ConnectionServiceAdapterServant {
+    private static final int MSG_HANDLE_CREATE_CONNECTION_COMPLETE = 1;
+    private static final int MSG_SET_ACTIVE = 2;
+    private static final int MSG_SET_RINGING = 3;
+    private static final int MSG_SET_DIALING = 4;
+    private static final int MSG_SET_DISCONNECTED = 5;
+    private static final int MSG_SET_ON_HOLD = 6;
+    private static final int MSG_SET_RINGBACK_REQUESTED = 7;
+    private static final int MSG_SET_CALL_CAPABILITIES = 8;
+    private static final int MSG_SET_IS_CONFERENCED = 9;
+    private static final int MSG_ADD_CONFERENCE_CALL = 10;
+    private static final int MSG_REMOVE_CALL = 11;
+    private static final int MSG_ON_POST_DIAL_WAIT = 12;
+    private static final int MSG_QUERY_REMOTE_CALL_SERVICES = 13;
+    private static final int MSG_SET_VIDEO_STATE = 14;
+    private static final int MSG_SET_VIDEO_CALL_PROVIDER = 15;
+    private static final int MSG_SET_IS_VOIP_AUDIO_MODE = 16;
+    private static final int MSG_SET_STATUS_HINTS = 17;
+    private static final int MSG_SET_ADDRESS = 18;
+    private static final int MSG_SET_CALLER_DISPLAY_NAME = 19;
+    private static final int MSG_SET_CONFERENCEABLE_CONNECTIONS = 20;
+
+    private final IConnectionServiceAdapter mDelegate;
+
+    private final Handler mHandler = new Handler() {
+        @Override
+        public void handleMessage(Message msg) {
+            try {
+                internalHandleMessage(msg);
+            } catch (RemoteException e) {
+            }
+        }
+
+        // Internal method defined to centralize handling of RemoteException
+        private void internalHandleMessage(Message msg) throws RemoteException {
+            switch (msg.what) {
+                case MSG_HANDLE_CREATE_CONNECTION_COMPLETE: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.handleCreateConnectionComplete(
+                                (String) args.arg1,
+                                (ConnectionRequest) args.arg2,
+                                (ParcelableConnection) args.arg3);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_ACTIVE:
+                    mDelegate.setActive((String) msg.obj);
+                    break;
+                case MSG_SET_RINGING:
+                    mDelegate.setRinging((String) msg.obj);
+                    break;
+                case MSG_SET_DIALING:
+                    mDelegate.setDialing((String) msg.obj);
+                    break;
+                case MSG_SET_DISCONNECTED: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setDisconnected((String) args.arg1, (DisconnectCause) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_ON_HOLD:
+                    mDelegate.setOnHold((String) msg.obj);
+                    break;
+                case MSG_SET_RINGBACK_REQUESTED:
+                    mDelegate.setRingbackRequested((String) msg.obj, msg.arg1 == 1);
+                    break;
+                case MSG_SET_CALL_CAPABILITIES:
+                    mDelegate.setCallCapabilities((String) msg.obj, msg.arg1);
+                    break;
+                case MSG_SET_IS_CONFERENCED: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setIsConferenced((String) args.arg1, (String) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_ADD_CONFERENCE_CALL: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.addConferenceCall(
+                                (String) args.arg1, (ParcelableConference) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_REMOVE_CALL:
+                    mDelegate.removeCall((String) msg.obj);
+                    break;
+                case MSG_ON_POST_DIAL_WAIT: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.onPostDialWait((String) args.arg1, (String) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_QUERY_REMOTE_CALL_SERVICES:
+                    mDelegate.queryRemoteConnectionServices((RemoteServiceCallback) msg.obj);
+                    break;
+                case MSG_SET_VIDEO_STATE:
+                    mDelegate.setVideoState((String) msg.obj, msg.arg1);
+                    break;
+                case MSG_SET_VIDEO_CALL_PROVIDER: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setVideoProvider((String) args.arg1,
+                                (IVideoProvider) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_IS_VOIP_AUDIO_MODE:
+                    mDelegate.setIsVoipAudioMode((String) msg.obj, msg.arg1 == 1);
+                    break;
+                case MSG_SET_STATUS_HINTS: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setStatusHints((String) args.arg1, (StatusHints) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_ADDRESS: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setAddress((String) args.arg1, (Uri) args.arg2, args.argi1);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_CALLER_DISPLAY_NAME: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setCallerDisplayName(
+                                (String) args.arg1, (String) args.arg2, args.argi1);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_SET_CONFERENCEABLE_CONNECTIONS: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.setConferenceableConnections(
+                                (String) args.arg1, (List<String>) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+            }
+        }
+    };
+
+    private final IConnectionServiceAdapter mStub = new IConnectionServiceAdapter.Stub() {
+        @Override
+        public void handleCreateConnectionComplete(
+                String id,
+                ConnectionRequest request,
+                ParcelableConnection connection) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = id;
+            args.arg2 = request;
+            args.arg3 = connection;
+            mHandler.obtainMessage(MSG_HANDLE_CREATE_CONNECTION_COMPLETE, args).sendToTarget();
+        }
+
+        @Override
+        public void setActive(String connectionId) {
+            mHandler.obtainMessage(MSG_SET_ACTIVE, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void setRinging(String connectionId) {
+            mHandler.obtainMessage(MSG_SET_RINGING, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void setDialing(String connectionId) {
+            mHandler.obtainMessage(MSG_SET_DIALING, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void setDisconnected(
+                String connectionId, DisconnectCause disconnectCause) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = disconnectCause;
+            mHandler.obtainMessage(MSG_SET_DISCONNECTED, args).sendToTarget();
+        }
+
+        @Override
+        public void setOnHold(String connectionId) {
+            mHandler.obtainMessage(MSG_SET_ON_HOLD, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void setRingbackRequested(String connectionId, boolean ringback) {
+            mHandler.obtainMessage(MSG_SET_RINGBACK_REQUESTED, ringback ? 1 : 0, 0, connectionId)
+                    .sendToTarget();
+        }
+
+        @Override
+        public void setCallCapabilities(String connectionId, int callCapabilities) {
+            mHandler.obtainMessage(MSG_SET_CALL_CAPABILITIES, callCapabilities, 0, connectionId)
+                    .sendToTarget();
+        }
+
+        @Override
+        public void setIsConferenced(String callId, String conferenceCallId) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.arg2 = conferenceCallId;
+            mHandler.obtainMessage(MSG_SET_IS_CONFERENCED, args).sendToTarget();
+        }
+
+        @Override
+        public void addConferenceCall(String callId, ParcelableConference parcelableConference) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.arg2 = parcelableConference;
+            mHandler.obtainMessage(MSG_ADD_CONFERENCE_CALL, args).sendToTarget();
+        }
+
+        @Override
+        public void removeCall(String connectionId) {
+            mHandler.obtainMessage(MSG_REMOVE_CALL, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void onPostDialWait(String connectionId, String remainingDigits) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = remainingDigits;
+            mHandler.obtainMessage(MSG_ON_POST_DIAL_WAIT, args).sendToTarget();
+        }
+
+        @Override
+        public void queryRemoteConnectionServices(RemoteServiceCallback callback) {
+            mHandler.obtainMessage(MSG_QUERY_REMOTE_CALL_SERVICES, callback).sendToTarget();
+        }
+
+        @Override
+        public void setVideoState(String connectionId, int videoState) {
+            mHandler.obtainMessage(MSG_SET_VIDEO_STATE, videoState, 0, connectionId).sendToTarget();
+        }
+
+        @Override
+        public void setVideoProvider(String connectionId, IVideoProvider videoProvider) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = videoProvider;
+            mHandler.obtainMessage(MSG_SET_VIDEO_CALL_PROVIDER, args).sendToTarget();
+        }
+
+        @Override
+        public final void setIsVoipAudioMode(String connectionId, boolean isVoip) {
+            mHandler.obtainMessage(MSG_SET_IS_VOIP_AUDIO_MODE, isVoip ? 1 : 0, 0,
+                    connectionId).sendToTarget();
+        }
+
+        @Override
+        public final void setStatusHints(String connectionId, StatusHints statusHints) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = statusHints;
+            mHandler.obtainMessage(MSG_SET_STATUS_HINTS, args).sendToTarget();
+        }
+
+        @Override
+        public final void setAddress(String connectionId, Uri address, int presentation) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = address;
+            args.argi1 = presentation;
+            mHandler.obtainMessage(MSG_SET_ADDRESS, args).sendToTarget();
+        }
+
+        @Override
+        public final void setCallerDisplayName(
+                String connectionId, String callerDisplayName, int presentation) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = callerDisplayName;
+            args.argi1 = presentation;
+            mHandler.obtainMessage(MSG_SET_CALLER_DISPLAY_NAME, args).sendToTarget();
+        }
+
+        @Override
+        public final void setConferenceableConnections(
+                String connectionId, List<String> conferenceableConnectionIds) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = connectionId;
+            args.arg2 = conferenceableConnectionIds;
+            mHandler.obtainMessage(MSG_SET_CONFERENCEABLE_CONNECTIONS, args).sendToTarget();
+        }
+    };
+
+    public ConnectionServiceAdapterServant(IConnectionServiceAdapter delegate) {
+        mDelegate = delegate;
+    }
+
+    public IConnectionServiceAdapter getStub() {
+        return mStub;
+    }
+}
diff --git a/telecomm/java/android/telecom/DisconnectCause.aidl b/telecomm/java/android/telecom/DisconnectCause.aidl
new file mode 100644
index 0000000..26b8652
--- /dev/null
+++ b/telecomm/java/android/telecom/DisconnectCause.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable DisconnectCause;
diff --git a/telecomm/java/android/telecom/DisconnectCause.java b/telecomm/java/android/telecom/DisconnectCause.java
new file mode 100644
index 0000000..cae115d
--- /dev/null
+++ b/telecomm/java/android/telecom/DisconnectCause.java
@@ -0,0 +1,249 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.media.ToneGenerator;
+import android.text.TextUtils;
+
+import java.util.Objects;
+
+/**
+ * Describes the cause of a disconnected call. This always includes a code describing the generic
+ * cause of the disconnect. Optionally, it may include a localized label and/or localized description
+ * to display to the user which is provided by the {@link ConnectionService}. It also may contain a
+ * reason for the the disconnect, which is intended for logging and not for display to the user.
+ */
+public final class DisconnectCause implements Parcelable {
+
+    /** Disconnected because of an unknown or unspecified reason. */
+    public static final int UNKNOWN = 0;
+    /** Disconnected because there was an error, such as a problem with the network. */
+    public static final int ERROR = 1;
+    /** Disconnected because of a local user-initiated action, such as hanging up. */
+    public static final int LOCAL = 2;
+    /**
+     * Disconnected because of a remote user-initiated action, such as the other party hanging up
+     * up.
+     */
+    public static final int REMOTE = 3;
+    /** Disconnected because it has been canceled. */
+    public static final int CANCELED = 4;
+    /** Disconnected because there was no response to an incoming call. */
+    public static final int MISSED = 5;
+    /** Disconnected because the user rejected an incoming call. */
+    public static final int REJECTED = 6;
+    /** Disconnected because the other party was busy. */
+    public static final int BUSY = 7;
+    /**
+     * Disconnected because of a restriction on placing the call, such as dialing in airplane
+     * mode.
+     */
+    public static final int RESTRICTED = 8;
+    /** Disconnected for reason not described by other disconnect codes. */
+    public static final int OTHER = 9;
+
+    private int mDisconnectCode;
+    private CharSequence mDisconnectLabel;
+    private CharSequence mDisconnectDescription;
+    private String mDisconnectReason;
+    private int mToneToPlay;
+
+    /**
+     * Creates a new DisconnectCause.
+     *
+     * @param code The code for the disconnect cause.
+     */
+    public DisconnectCause(int code) {
+        this(code, null, null, null, ToneGenerator.TONE_UNKNOWN);
+    }
+
+    /**
+     * Creates a new DisconnectCause.
+     *
+     * @param code The code for the disconnect cause.
+     * @param reason The reason for the disconnect.
+     */
+    public DisconnectCause(int code, String reason) {
+        this(code, null, null, reason, ToneGenerator.TONE_UNKNOWN);
+    }
+
+    /**
+     * Creates a new DisconnectCause.
+     *
+     * @param code The code for the disconnect cause.
+     * @param label The localized label to show to the user to explain the disconnect.
+     * @param description The localized description to show to the user to explain the disconnect.
+     * @param reason The reason for the disconnect.
+     * @param toneToPlay The tone to play on disconnect, as defined in {@link ToneGenerator}.
+     */
+    public DisconnectCause(int code, CharSequence label, CharSequence description, String reason,
+            int toneToPlay) {
+        mDisconnectCode = code;
+        mDisconnectLabel = label;
+        mDisconnectDescription = description;
+        mDisconnectReason = reason;
+        mToneToPlay = toneToPlay;
+    }
+
+    /**
+     * Returns the code for the reason for this disconnect.
+     *
+     * @return The disconnect code.
+     */
+    public int getCode() {
+        return mDisconnectCode;
+    }
+
+    /**
+     * Returns a short label which explains the reason for the disconnect cause and is for display
+     * in the user interface. The {@link ConnectionService } is responsible for providing and
+     * localizing this label. If there is no string provided, returns null.
+     *
+     * @return The disconnect label.
+     */
+    public CharSequence getLabel() {
+        return mDisconnectLabel;
+    }
+
+    /**
+     * Returns a description which explains the reason for the disconnect cause and is for display
+     * in the user interface. The {@link ConnectionService } is responsible for providing and
+     * localizing this message. If there is no string provided, returns null.
+     *
+     * @return The disconnect description.
+     */
+    public CharSequence getDescription() {
+        return mDisconnectDescription;
+    }
+
+    /**
+     * Returns an explanation of the reason for the disconnect. This is not intended for display to
+     * the user and is used mainly for logging.
+     *
+     * @return The disconnect reason.
+     */
+    public String getReason() {
+        return mDisconnectReason;
+    }
+
+    /**
+     * Returns the tone to play when disconnected.
+     *
+     * @return the tone as defined in {@link ToneGenerator} to play when disconnected.
+     */
+    public int getTone() {
+        return mToneToPlay;
+    }
+
+    public static final Creator<DisconnectCause> CREATOR = new Creator<DisconnectCause>() {
+        @Override
+        public DisconnectCause createFromParcel(Parcel source) {
+            int code = source.readInt();
+            CharSequence label = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(source);
+            CharSequence description = TextUtils.CHAR_SEQUENCE_CREATOR.createFromParcel(source);
+            String reason = source.readString();
+            int tone = source.readInt();
+            return new DisconnectCause(code, label, description, reason, tone);
+        }
+
+        @Override
+        public DisconnectCause[] newArray(int size) {
+            return new DisconnectCause[size];
+        }
+    };
+
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeInt(mDisconnectCode);
+        TextUtils.writeToParcel(mDisconnectLabel, destination, flags);
+        TextUtils.writeToParcel(mDisconnectDescription, destination, flags);
+        destination.writeString(mDisconnectReason);
+        destination.writeInt(mToneToPlay);
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public int hashCode() {
+        return Objects.hashCode(mDisconnectCode)
+                + Objects.hashCode(mDisconnectLabel)
+                + Objects.hashCode(mDisconnectDescription)
+                + Objects.hashCode(mDisconnectReason)
+                + Objects.hashCode(mToneToPlay);
+    }
+
+    @Override
+    public boolean equals(Object o) {
+        if (o instanceof DisconnectCause) {
+            DisconnectCause d = (DisconnectCause) o;
+            return Objects.equals(mDisconnectCode, d.getCode())
+                    && Objects.equals(mDisconnectLabel, d.getLabel())
+                    && Objects.equals(mDisconnectDescription, d.getDescription())
+                    && Objects.equals(mDisconnectReason, d.getReason())
+                    && Objects.equals(mToneToPlay, d.getTone());
+        }
+        return false;
+    }
+
+    @Override
+    public String toString() {
+        String code = "";
+        switch (getCode()) {
+            case ERROR:
+                code = "ERROR";
+                break;
+            case LOCAL:
+                code = "LOCAL";
+                break;
+            case REMOTE:
+                code = "REMOTE";
+                break;
+            case MISSED:
+                code = "MISSED";
+                break;
+            case REJECTED:
+                code = "REJECTED";
+                break;
+            case BUSY:
+                code = "BUSY";
+                break;
+            case RESTRICTED:
+                code = "RESTRICTED";
+                break;
+            case OTHER:
+                code = "OTHER";
+                break;
+            case UNKNOWN:
+            default:
+                code = "UNKNOWN";
+        }
+        String label = mDisconnectLabel == null ? "" : mDisconnectLabel.toString();
+        String description = mDisconnectDescription == null
+                ? "" : mDisconnectDescription.toString();
+        String reason = mDisconnectReason == null ? "" : mDisconnectReason;
+        return "DisconnectCause [ Code: (" + code + ")"
+                + " Label: (" + label + ")"
+                + " Description: (" + description + ")"
+                + " Reason: (" + reason + ")"
+                + " Tone: (" + mToneToPlay + ") ]";
+    }
+}
diff --git a/telecomm/java/android/telecom/GatewayInfo.aidl b/telecomm/java/android/telecom/GatewayInfo.aidl
new file mode 100644
index 0000000..ad9858c
--- /dev/null
+++ b/telecomm/java/android/telecom/GatewayInfo.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable GatewayInfo;
diff --git a/telecomm/java/android/telecom/GatewayInfo.java b/telecomm/java/android/telecom/GatewayInfo.java
new file mode 100644
index 0000000..583c3e2
--- /dev/null
+++ b/telecomm/java/android/telecom/GatewayInfo.java
@@ -0,0 +1,108 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import android.annotation.SystemApi;
+import android.net.Uri;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.text.TextUtils;
+
+/**
+ * When calls are made, they may contain gateway information for services which route phone calls
+ * through their own service/numbers. The data consists of a number to call and the package name of
+ * the service. This data is used in two ways:
+ * <ol>
+ * <li> Call the appropriate routing number
+ * <li> Display information about how the call is being routed to the user
+ * </ol>
+ */
+public class GatewayInfo implements Parcelable {
+
+    private final String mGatewayProviderPackageName;
+    private final Uri mGatewayAddress;
+    private final Uri mOriginalAddress;
+
+    /** @hide */
+    @SystemApi
+    public GatewayInfo(String packageName, Uri gatewayUri, Uri originalAddress) {
+        mGatewayProviderPackageName = packageName;
+        mGatewayAddress = gatewayUri;
+        mOriginalAddress = originalAddress;
+    }
+
+    /**
+     * Package name of the gateway provider service. used to place the call with.
+     */
+    public String getGatewayProviderPackageName() {
+        return mGatewayProviderPackageName;
+    }
+
+    /**
+     * Gateway provider address to use when actually placing the call.
+     */
+    public Uri getGatewayAddress() {
+        return mGatewayAddress;
+    }
+
+    /**
+     * The actual call address that the user is trying to connect to via the gateway.
+     */
+    public Uri getOriginalAddress() {
+        return mOriginalAddress;
+    }
+
+    public boolean isEmpty() {
+        return TextUtils.isEmpty(mGatewayProviderPackageName) || mGatewayAddress == null;
+    }
+
+    /** Implement the Parcelable interface */
+    public static final Parcelable.Creator<GatewayInfo> CREATOR =
+            new Parcelable.Creator<GatewayInfo> () {
+
+        @Override
+        public GatewayInfo createFromParcel(Parcel source) {
+            String gatewayPackageName = source.readString();
+            Uri gatewayUri = Uri.CREATOR.createFromParcel(source);
+            Uri originalAddress = Uri.CREATOR.createFromParcel(source);
+            return new GatewayInfo(gatewayPackageName, gatewayUri, originalAddress);
+        }
+
+        @Override
+        public GatewayInfo[] newArray(int size) {
+            return new GatewayInfo[size];
+        }
+    };
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /**
+     * {@inheritDoc}
+     */
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeString(mGatewayProviderPackageName);
+        mGatewayAddress.writeToParcel(destination, 0);
+        mOriginalAddress.writeToParcel(destination, 0);
+    }
+}
diff --git a/telecomm/java/android/telecom/InCallAdapter.java b/telecomm/java/android/telecom/InCallAdapter.java
new file mode 100644
index 0000000..fd3cf2e
--- /dev/null
+++ b/telecomm/java/android/telecom/InCallAdapter.java
@@ -0,0 +1,274 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.RemoteException;
+
+import com.android.internal.telecom.IInCallAdapter;
+
+/**
+ * Receives commands from {@link InCallService} implementations which should be executed by
+ * Telecom. When Telecom binds to a {@link InCallService}, an instance of this class is given to
+ * the in-call service through which it can manipulate live (active, dialing, ringing) calls. When
+ * the in-call service is notified of new calls, it can use the
+ * given call IDs to execute commands such as {@link #answerCall} for incoming calls or
+ * {@link #disconnectCall} for active calls the user would like to end. Some commands are only
+ * appropriate for calls in certain states; please consult each method for such limitations.
+ * <p>
+ * The adapter will stop functioning when there are no more calls.
+ *
+ * {@hide}
+ */
+public final class InCallAdapter {
+    private final IInCallAdapter mAdapter;
+
+    /**
+     * {@hide}
+     */
+    public InCallAdapter(IInCallAdapter adapter) {
+        mAdapter = adapter;
+    }
+
+    /**
+     * Instructs Telecom to answer the specified call.
+     *
+     * @param callId The identifier of the call to answer.
+     * @param videoState The video state in which to answer the call.
+     */
+    public void answerCall(String callId, int videoState) {
+        try {
+            mAdapter.answerCall(callId, videoState);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to reject the specified call.
+     *
+     * @param callId The identifier of the call to reject.
+     * @param rejectWithMessage Whether to reject with a text message.
+     * @param textMessage An optional text message with which to respond.
+     */
+    public void rejectCall(String callId, boolean rejectWithMessage, String textMessage) {
+        try {
+            mAdapter.rejectCall(callId, rejectWithMessage, textMessage);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to disconnect the specified call.
+     *
+     * @param callId The identifier of the call to disconnect.
+     */
+    public void disconnectCall(String callId) {
+        try {
+            mAdapter.disconnectCall(callId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to put the specified call on hold.
+     *
+     * @param callId The identifier of the call to put on hold.
+     */
+    public void holdCall(String callId) {
+        try {
+            mAdapter.holdCall(callId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to release the specified call from hold.
+     *
+     * @param callId The identifier of the call to release from hold.
+     */
+    public void unholdCall(String callId) {
+        try {
+            mAdapter.unholdCall(callId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Mute the microphone.
+     *
+     * @param shouldMute True if the microphone should be muted.
+     */
+    public void mute(boolean shouldMute) {
+        try {
+            mAdapter.mute(shouldMute);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Sets the audio route (speaker, bluetooth, etc...). See {@link AudioState}.
+     *
+     * @param route The audio route to use.
+     */
+    public void setAudioRoute(int route) {
+        try {
+            mAdapter.setAudioRoute(route);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to play a dual-tone multi-frequency signaling (DTMF) tone in a call.
+     *
+     * Any other currently playing DTMF tone in the specified call is immediately stopped.
+     *
+     * @param callId The unique ID of the call in which the tone will be played.
+     * @param digit A character representing the DTMF digit for which to play the tone. This
+     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
+     */
+    public void playDtmfTone(String callId, char digit) {
+        try {
+            mAdapter.playDtmfTone(callId, digit);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to stop any dual-tone multi-frequency signaling (DTMF) tone currently
+     * playing.
+     *
+     * DTMF tones are played by calling {@link #playDtmfTone(String,char)}. If no DTMF tone is
+     * currently playing, this method will do nothing.
+     *
+     * @param callId The unique ID of the call in which any currently playing tone will be stopped.
+     */
+    public void stopDtmfTone(String callId) {
+        try {
+            mAdapter.stopDtmfTone(callId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to continue playing a post-dial DTMF string.
+     *
+     * A post-dial DTMF string is a string of digits entered after a phone number, when dialed,
+     * that are immediately sent as DTMF tones to the recipient as soon as the connection is made.
+     * While these tones are playing, Telecom will notify the {@link InCallService} that the call
+     * is in the post dial state.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_PAUSE} symbol, Telecom
+     * will temporarily pause playing the tones for a pre-defined period of time.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_WAIT} symbol, Telecom
+     * will pause playing the tones and notify the {@link InCallService} that the call is in the
+     * post dial wait state. When the user decides to continue the postdial sequence, the
+     * {@link InCallService} should invoke the {@link #postDialContinue(String,boolean)} method.
+     *
+     * @param callId The unique ID of the call for which postdial string playing should continue.
+     * @param proceed Whether or not to continue with the post-dial sequence.
+     */
+    public void postDialContinue(String callId, boolean proceed) {
+        try {
+            mAdapter.postDialContinue(callId, proceed);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to add a PhoneAccountHandle to the specified call
+     *
+     * @param callId The identifier of the call
+     * @param accountHandle The PhoneAccountHandle through which to place the call
+     */
+    public void phoneAccountSelected(String callId, PhoneAccountHandle accountHandle) {
+        try {
+            mAdapter.phoneAccountSelected(callId, accountHandle);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to conference the specified call.
+     *
+     * @param callId The unique ID of the call.
+     * @hide
+     */
+    public void conference(String callId, String otherCallId) {
+        try {
+            mAdapter.conference(callId, otherCallId);
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to split the specified call from any conference call with which it may be
+     * connected.
+     *
+     * @param callId The unique ID of the call.
+     * @hide
+     */
+    public void splitFromConference(String callId) {
+        try {
+            mAdapter.splitFromConference(callId);
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to merge child calls of the specified conference call.
+     */
+    public void mergeConference(String callId) {
+        try {
+            mAdapter.mergeConference(callId);
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to swap the child calls of the specified conference call.
+     */
+    public void swapConference(String callId) {
+        try {
+            mAdapter.swapConference(callId);
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to turn the proximity sensor on.
+     */
+    public void turnProximitySensorOn() {
+        try {
+            mAdapter.turnOnProximitySensor();
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs Telecom to turn the proximity sensor off.
+     *
+     * @param screenOnImmediately If true, the screen will be turned on immediately if it was
+     * previously off. Otherwise, the screen will only be turned on after the proximity sensor
+     * is no longer triggered.
+     */
+    public void turnProximitySensorOff(boolean screenOnImmediately) {
+        try {
+            mAdapter.turnOffProximitySensor(screenOnImmediately);
+        } catch (RemoteException ignored) {
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/InCallService.java b/telecomm/java/android/telecom/InCallService.java
new file mode 100644
index 0000000..fa12756
--- /dev/null
+++ b/telecomm/java/android/telecom/InCallService.java
@@ -0,0 +1,365 @@
+/*
+ * 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 android.telecom;
+
+import android.annotation.SystemApi;
+import android.annotation.SdkConstant;
+import android.app.Service;
+import android.content.Intent;
+import android.os.Handler;
+import android.os.IBinder;
+import android.os.Looper;
+import android.os.Message;
+import android.view.Surface;
+
+import com.android.internal.os.SomeArgs;
+import com.android.internal.telecom.IInCallAdapter;
+import com.android.internal.telecom.IInCallService;
+
+import java.lang.String;
+
+/**
+ * This service is implemented by any app that wishes to provide the user-interface for managing
+ * phone calls. Telecom binds to this service while there exists a live (active or incoming) call,
+ * and uses it to notify the in-call app of any live and and recently disconnected calls.
+ *
+ * {@hide}
+ */
+@SystemApi
+public abstract class InCallService extends Service {
+
+    /**
+     * The {@link Intent} that must be declared as handled by the service.
+     */
+    @SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
+    public static final String SERVICE_INTERFACE = "android.telecom.InCallService";
+
+    private static final int MSG_SET_IN_CALL_ADAPTER = 1;
+    private static final int MSG_ADD_CALL = 2;
+    private static final int MSG_UPDATE_CALL = 3;
+    private static final int MSG_SET_POST_DIAL_WAIT = 4;
+    private static final int MSG_ON_AUDIO_STATE_CHANGED = 5;
+    private static final int MSG_BRING_TO_FOREGROUND = 6;
+
+    /** Default Handler used to consolidate binder method calls onto a single thread. */
+    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
+        @Override
+        public void handleMessage(Message msg) {
+            switch (msg.what) {
+                case MSG_SET_IN_CALL_ADAPTER:
+                    mPhone = new Phone(new InCallAdapter((IInCallAdapter) msg.obj));
+                    onPhoneCreated(mPhone);
+                    break;
+                case MSG_ADD_CALL:
+                    mPhone.internalAddCall((ParcelableCall) msg.obj);
+                    break;
+                case MSG_UPDATE_CALL:
+                    mPhone.internalUpdateCall((ParcelableCall) msg.obj);
+                    break;
+                case MSG_SET_POST_DIAL_WAIT: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        String callId = (String) args.arg1;
+                        String remaining = (String) args.arg2;
+                        mPhone.internalSetPostDialWait(callId, remaining);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_ON_AUDIO_STATE_CHANGED:
+                    mPhone.internalAudioStateChanged((AudioState) msg.obj);
+                    break;
+                case MSG_BRING_TO_FOREGROUND:
+                    mPhone.internalBringToForeground(msg.arg1 == 1);
+                    break;
+                default:
+                    break;
+            }
+        }
+    };
+
+    /** Manages the binder calls so that the implementor does not need to deal with it. */
+    private final class InCallServiceBinder extends IInCallService.Stub {
+        @Override
+        public void setInCallAdapter(IInCallAdapter inCallAdapter) {
+            mHandler.obtainMessage(MSG_SET_IN_CALL_ADAPTER, inCallAdapter).sendToTarget();
+        }
+
+        @Override
+        public void addCall(ParcelableCall call) {
+            mHandler.obtainMessage(MSG_ADD_CALL, call).sendToTarget();
+        }
+
+        @Override
+        public void updateCall(ParcelableCall call) {
+            mHandler.obtainMessage(MSG_UPDATE_CALL, call).sendToTarget();
+        }
+
+        @Override
+        public void setPostDial(String callId, String remaining) {
+            // TODO: Unused
+        }
+
+        @Override
+        public void setPostDialWait(String callId, String remaining) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = callId;
+            args.arg2 = remaining;
+            mHandler.obtainMessage(MSG_SET_POST_DIAL_WAIT, args).sendToTarget();
+        }
+
+        @Override
+        public void onAudioStateChanged(AudioState audioState) {
+            mHandler.obtainMessage(MSG_ON_AUDIO_STATE_CHANGED, audioState).sendToTarget();
+        }
+
+        @Override
+        public void bringToForeground(boolean showDialpad) {
+            mHandler.obtainMessage(MSG_BRING_TO_FOREGROUND, showDialpad ? 1 : 0, 0).sendToTarget();
+        }
+    }
+
+    private Phone mPhone;
+
+    public InCallService() {
+    }
+
+    @Override
+    public IBinder onBind(Intent intent) {
+        return new InCallServiceBinder();
+    }
+
+    @Override
+    public boolean onUnbind(Intent intent) {
+        if (mPhone != null) {
+            Phone oldPhone = mPhone;
+            mPhone = null;
+
+            oldPhone.destroy();
+            onPhoneDestroyed(oldPhone);
+        }
+        return false;
+    }
+
+    /**
+     * Obtain the {@code Phone} associated with this {@code InCallService}.
+     *
+     * @return The {@code Phone} object associated with this {@code InCallService}, or {@code null}
+     *         if the {@code InCallService} is not in a state where it has an associated
+     *         {@code Phone}.
+     */
+    public Phone getPhone() {
+        return mPhone;
+    }
+
+    /**
+     * Invoked when the {@code Phone} has been created. This is a signal to the in-call experience
+     * to start displaying in-call information to the user. Each instance of {@code InCallService}
+     * will have only one {@code Phone}, and this method will be called exactly once in the lifetime
+     * of the {@code InCallService}.
+     *
+     * @param phone The {@code Phone} object associated with this {@code InCallService}.
+     */
+    public void onPhoneCreated(Phone phone) {
+    }
+
+    /**
+     * Invoked when a {@code Phone} has been destroyed. This is a signal to the in-call experience
+     * to stop displaying in-call information to the user. This method will be called exactly once
+     * in the lifetime of the {@code InCallService}, and it will always be called after a previous
+     * call to {@link #onPhoneCreated(Phone)}.
+     *
+     * @param phone The {@code Phone} object associated with this {@code InCallService}.
+     */
+    public void onPhoneDestroyed(Phone phone) {
+    }
+
+    /**
+     * Class to invoke functionality related to video calls.
+     * @hide
+     */
+    public static abstract class VideoCall {
+
+        /**
+         * Sets a listener to invoke callback methods in the InCallUI after performing video
+         * telephony actions.
+         *
+         * @param videoCallListener The call video client.
+         */
+        public abstract void setVideoCallListener(VideoCall.Listener videoCallListener);
+
+        /**
+         * Sets the camera to be used for video recording in a video call.
+         *
+         * @param cameraId The id of the camera.
+         */
+        public abstract void setCamera(String cameraId);
+
+        /**
+         * Sets the surface to be used for displaying a preview of what the user's camera is
+         * currently capturing.  When video transmission is enabled, this is the video signal which
+         * is sent to the remote device.
+         *
+         * @param surface The surface.
+         */
+        public abstract void setPreviewSurface(Surface surface);
+
+        /**
+         * Sets the surface to be used for displaying the video received from the remote device.
+         *
+         * @param surface The surface.
+         */
+        public abstract void setDisplaySurface(Surface surface);
+
+        /**
+         * Sets the device orientation, in degrees.  Assumes that a standard portrait orientation of
+         * the device is 0 degrees.
+         *
+         * @param rotation The device orientation, in degrees.
+         */
+        public abstract void setDeviceOrientation(int rotation);
+
+        /**
+         * Sets camera zoom ratio.
+         *
+         * @param value The camera zoom ratio.
+         */
+        public abstract void setZoom(float value);
+
+        /**
+         * Issues a request to modify the properties of the current session.  The request is sent to
+         * the remote device where it it handled by
+         * {@link VideoCall.Listener#onSessionModifyRequestReceived}.
+         * Some examples of session modification requests: upgrade call from audio to video,
+         * downgrade call from video to audio, pause video.
+         *
+         * @param requestProfile The requested call video properties.
+         */
+        public abstract void sendSessionModifyRequest(VideoProfile requestProfile);
+
+        /**
+         * Provides a response to a request to change the current call session video
+         * properties.
+         * This is in response to a request the InCall UI has received via
+         * {@link VideoCall.Listener#onSessionModifyRequestReceived}.
+         * The response is handled on the remove device by
+         * {@link VideoCall.Listener#onSessionModifyResponseReceived}.
+         *
+         * @param responseProfile The response call video properties.
+         */
+        public abstract void sendSessionModifyResponse(VideoProfile responseProfile);
+
+        /**
+         * Issues a request to the video provider to retrieve the camera capabilities.
+         * Camera capabilities are reported back to the caller via
+         * {@link VideoCall.Listener#onCameraCapabilitiesChanged(CameraCapabilities)}.
+         */
+        public abstract void requestCameraCapabilities();
+
+        /**
+         * Issues a request to the video telephony framework to retrieve the cumulative data usage for
+         * the current call.  Data usage is reported back to the caller via
+         * {@link VideoCall.Listener#onCallDataUsageChanged}.
+         */
+        public abstract void requestCallDataUsage();
+
+        /**
+         * Provides the video telephony framework with the URI of an image to be displayed to remote
+         * devices when the video signal is paused.
+         *
+         * @param uri URI of image to display.
+         */
+        public abstract void setPauseImage(String uri);
+
+        /**
+         * Listener class which invokes callbacks after video call actions occur.
+         * @hide
+         */
+        public static abstract class Listener {
+            /**
+             * Called when a session modification request is received from the remote device.
+             * The remote request is sent via
+             * {@link Connection.VideoProvider#onSendSessionModifyRequest}. The InCall UI
+             * is responsible for potentially prompting the user whether they wish to accept the new
+             * call profile (e.g. prompt user if they wish to accept an upgrade from an audio to a
+             * video call) and should call
+             * {@link Connection.VideoProvider#onSendSessionModifyResponse} to indicate
+             * the video settings the user has agreed to.
+             *
+             * @param videoProfile The requested video call profile.
+             */
+            public abstract void onSessionModifyRequestReceived(VideoProfile videoProfile);
+
+            /**
+             * Called when a response to a session modification request is received from the remote
+             * device. The remote InCall UI sends the response using
+             * {@link Connection.VideoProvider#onSendSessionModifyResponse}.
+             *
+             * @param status Status of the session modify request.  Valid values are
+             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_SUCCESS},
+             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_FAIL},
+             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_INVALID}
+             * @param requestedProfile The original request which was sent to the remote device.
+             * @param responseProfile The actual profile changes made by the remote device.
+             */
+            public abstract void onSessionModifyResponseReceived(int status,
+                    VideoProfile requestedProfile, VideoProfile responseProfile);
+
+            /**
+             * Handles events related to the current session which the client may wish to handle.
+             * These are separate from requested changes to the session due to the underlying
+             * protocol or connection.
+             *
+             * Valid values are:
+             * {@link Connection.VideoProvider#SESSION_EVENT_RX_PAUSE},
+             * {@link Connection.VideoProvider#SESSION_EVENT_RX_RESUME},
+             * {@link Connection.VideoProvider#SESSION_EVENT_TX_START},
+             * {@link Connection.VideoProvider#SESSION_EVENT_TX_STOP},
+             * {@link Connection.VideoProvider#SESSION_EVENT_CAMERA_FAILURE},
+             * {@link Connection.VideoProvider#SESSION_EVENT_CAMERA_READY}
+             *
+             * @param event The event.
+             */
+            public abstract void onCallSessionEvent(int event);
+
+            /**
+             * Handles a change to the video dimensions from the remote caller (peer). This could
+             * happen if, for example, the peer changes orientation of their device.
+             *
+             * @param width  The updated peer video width.
+             * @param height The updated peer video height.
+             */
+            public abstract void onPeerDimensionsChanged(int width, int height);
+
+            /**
+             * Handles an update to the total data used for the current session.
+             *
+             * @param dataUsage The updated data usage.
+             */
+            public abstract void onCallDataUsageChanged(int dataUsage);
+
+            /**
+             * Handles a change in camera capabilities.
+             *
+             * @param cameraCapabilities The changed camera capabilities.
+             */
+            public abstract void onCameraCapabilitiesChanged(
+                    CameraCapabilities cameraCapabilities);
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/Log.java b/telecomm/java/android/telecom/Log.java
new file mode 100644
index 0000000..73cc4a5
--- /dev/null
+++ b/telecomm/java/android/telecom/Log.java
@@ -0,0 +1,181 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import java.security.MessageDigest;
+import java.security.NoSuchAlgorithmException;
+import java.util.IllegalFormatException;
+import java.util.Locale;
+
+/**
+ * Manages logging for the entire module.
+ *
+ * @hide
+ */
+final public class Log {
+
+    // Generic tag for all Telecom Framework logging
+    private static final String TAG = "TelecomFramework";
+
+    public static final boolean FORCE_LOGGING = false; /* STOP SHIP if true */
+    public static final boolean DEBUG = isLoggable(android.util.Log.DEBUG);
+    public static final boolean INFO = isLoggable(android.util.Log.INFO);
+    public static final boolean VERBOSE = isLoggable(android.util.Log.VERBOSE);
+    public static final boolean WARN = isLoggable(android.util.Log.WARN);
+    public static final boolean ERROR = isLoggable(android.util.Log.ERROR);
+
+    private Log() {}
+
+    public static boolean isLoggable(int level) {
+        return FORCE_LOGGING || android.util.Log.isLoggable(TAG, level);
+    }
+
+    public static void d(String prefix, String format, Object... args) {
+        if (DEBUG) {
+            android.util.Log.d(TAG, buildMessage(prefix, format, args));
+        }
+    }
+
+    public static void d(Object objectPrefix, String format, Object... args) {
+        if (DEBUG) {
+            android.util.Log.d(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
+        }
+    }
+
+    public static void i(String prefix, String format, Object... args) {
+        if (INFO) {
+            android.util.Log.i(TAG, buildMessage(prefix, format, args));
+        }
+    }
+
+    public static void i(Object objectPrefix, String format, Object... args) {
+        if (INFO) {
+            android.util.Log.i(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
+        }
+    }
+
+    public static void v(String prefix, String format, Object... args) {
+        if (VERBOSE) {
+            android.util.Log.v(TAG, buildMessage(prefix, format, args));
+        }
+    }
+
+    public static void v(Object objectPrefix, String format, Object... args) {
+        if (VERBOSE) {
+            android.util.Log.v(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
+        }
+    }
+
+    public static void w(String prefix, String format, Object... args) {
+        if (WARN) {
+            android.util.Log.w(TAG, buildMessage(prefix, format, args));
+        }
+    }
+
+    public static void w(Object objectPrefix, String format, Object... args) {
+        if (WARN) {
+            android.util.Log.w(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
+        }
+    }
+
+    public static void e(String prefix, Throwable tr, String format, Object... args) {
+        if (ERROR) {
+            android.util.Log.e(TAG, buildMessage(prefix, format, args), tr);
+        }
+    }
+
+    public static void e(Object objectPrefix, Throwable tr, String format, Object... args) {
+        if (ERROR) {
+            android.util.Log.e(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args),
+                    tr);
+        }
+    }
+
+    public static void wtf(String prefix, Throwable tr, String format, Object... args) {
+        android.util.Log.wtf(TAG, buildMessage(prefix, format, args), tr);
+    }
+
+    public static void wtf(Object objectPrefix, Throwable tr, String format, Object... args) {
+        android.util.Log.wtf(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args),
+                tr);
+    }
+
+    public static void wtf(String prefix, String format, Object... args) {
+        String msg = buildMessage(prefix, format, args);
+        android.util.Log.wtf(TAG, msg, new IllegalStateException(msg));
+    }
+
+    public static void wtf(Object objectPrefix, String format, Object... args) {
+        String msg = buildMessage(getPrefixFromObject(objectPrefix), format, args);
+        android.util.Log.wtf(TAG, msg, new IllegalStateException(msg));
+    }
+
+    /**
+     * Redact personally identifiable information for production users.
+     * If we are running in verbose mode, return the original string, otherwise
+     * return a SHA-1 hash of the input string.
+     */
+    public static String pii(Object pii) {
+        if (pii == null || VERBOSE) {
+            return String.valueOf(pii);
+        }
+        return "[" + secureHash(String.valueOf(pii).getBytes()) + "]";
+    }
+
+    private static String secureHash(byte[] input) {
+        MessageDigest messageDigest;
+        try {
+            messageDigest = MessageDigest.getInstance("SHA-1");
+        } catch (NoSuchAlgorithmException e) {
+            return null;
+        }
+        messageDigest.update(input);
+        byte[] result = messageDigest.digest();
+        return encodeHex(result);
+    }
+
+    private static String encodeHex(byte[] bytes) {
+        StringBuffer hex = new StringBuffer(bytes.length * 2);
+
+        for (int i = 0; i < bytes.length; i++) {
+            int byteIntValue = bytes[i] & 0xff;
+            if (byteIntValue < 0x10) {
+                hex.append("0");
+            }
+            hex.append(Integer.toString(byteIntValue, 16));
+        }
+
+        return hex.toString();
+    }
+
+    private static String getPrefixFromObject(Object obj) {
+        return obj == null ? "<null>" : obj.getClass().getSimpleName();
+    }
+
+    private static String buildMessage(String prefix, String format, Object... args) {
+        String msg;
+        try {
+            msg = (args == null || args.length == 0) ? format
+                    : String.format(Locale.US, format, args);
+        } catch (IllegalFormatException ife) {
+            wtf("Log", ife, "IllegalFormatException: formatString='%s' numArgs=%d", format,
+                    args.length);
+            msg = format + " (An error occurred while formatting the message.)";
+        }
+        return String.format(Locale.US, "%s: %s", prefix, msg);
+    }
+}
diff --git a/telecomm/java/android/telecom/ParcelableCall.aidl b/telecomm/java/android/telecom/ParcelableCall.aidl
new file mode 100644
index 0000000..480e82f
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableCall.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable ParcelableCall;
diff --git a/telecomm/java/android/telecom/ParcelableCall.java b/telecomm/java/android/telecom/ParcelableCall.java
new file mode 100644
index 0000000..c5c3d11
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableCall.java
@@ -0,0 +1,330 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import android.net.Uri;
+import android.os.Bundle;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.os.RemoteException;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+import com.android.internal.telecom.IVideoProvider;
+
+/**
+ * Information about a call that is used between InCallService and Telecom.
+ * @hide
+ */
+public final class ParcelableCall implements Parcelable {
+    private final String mId;
+    private final int mState;
+    private final DisconnectCause mDisconnectCause;
+    private final List<String> mCannedSmsResponses;
+    private final int mCapabilities;
+    private final int mProperties;
+    private final long mConnectTimeMillis;
+    private final Uri mHandle;
+    private final int mHandlePresentation;
+    private final String mCallerDisplayName;
+    private final int mCallerDisplayNamePresentation;
+    private final GatewayInfo mGatewayInfo;
+    private final PhoneAccountHandle mAccountHandle;
+    private final IVideoProvider mVideoCallProvider;
+    private InCallService.VideoCall mVideoCall;
+    private final String mParentCallId;
+    private final List<String> mChildCallIds;
+    private final StatusHints mStatusHints;
+    private final int mVideoState;
+    private final List<String> mConferenceableCallIds;
+    private final Bundle mExtras;
+
+    public ParcelableCall(
+            String id,
+            int state,
+            DisconnectCause disconnectCause,
+            List<String> cannedSmsResponses,
+            int capabilities,
+            int properties,
+            long connectTimeMillis,
+            Uri handle,
+            int handlePresentation,
+            String callerDisplayName,
+            int callerDisplayNamePresentation,
+            GatewayInfo gatewayInfo,
+            PhoneAccountHandle accountHandle,
+            IVideoProvider videoCallProvider,
+            String parentCallId,
+            List<String> childCallIds,
+            StatusHints statusHints,
+            int videoState,
+            List<String> conferenceableCallIds,
+            Bundle extras) {
+        mId = id;
+        mState = state;
+        mDisconnectCause = disconnectCause;
+        mCannedSmsResponses = cannedSmsResponses;
+        mCapabilities = capabilities;
+        mProperties = properties;
+        mConnectTimeMillis = connectTimeMillis;
+        mHandle = handle;
+        mHandlePresentation = handlePresentation;
+        mCallerDisplayName = callerDisplayName;
+        mCallerDisplayNamePresentation = callerDisplayNamePresentation;
+        mGatewayInfo = gatewayInfo;
+        mAccountHandle = accountHandle;
+        mVideoCallProvider = videoCallProvider;
+        mParentCallId = parentCallId;
+        mChildCallIds = childCallIds;
+        mStatusHints = statusHints;
+        mVideoState = videoState;
+        mConferenceableCallIds = Collections.unmodifiableList(conferenceableCallIds);
+        mExtras = extras;
+    }
+
+    /** The unique ID of the call. */
+    public String getId() {
+        return mId;
+    }
+
+    /** The current state of the call. */
+    public int getState() {
+        return mState;
+    }
+
+    /**
+     * Reason for disconnection, as described by {@link android.telecomm.DisconnectCause}. Valid
+     * when call state is {@link CallState#DISCONNECTED}.
+     */
+    public DisconnectCause getDisconnectCause() {
+        return mDisconnectCause;
+    }
+
+    /**
+     * The set of possible text message responses when this call is incoming.
+     */
+    public List<String> getCannedSmsResponses() {
+        return mCannedSmsResponses;
+    }
+
+    // Bit mask of actions a call supports, values are defined in {@link CallCapabilities}.
+    public int getCapabilities() {
+        return mCapabilities;
+    }
+
+    /** Bitmask of properties of the call. */
+    public int getProperties() { return mProperties; }
+
+    /** The time that the call switched to the active state. */
+    public long getConnectTimeMillis() {
+        return mConnectTimeMillis;
+    }
+
+    /** The endpoint to which the call is connected. */
+    public Uri getHandle() {
+        return mHandle;
+    }
+
+    /**
+     * The presentation requirements for the handle. See {@link TelecomManager} for valid values.
+     */
+    public int getHandlePresentation() {
+        return mHandlePresentation;
+    }
+
+    /** The endpoint to which the call is connected. */
+    public String getCallerDisplayName() {
+        return mCallerDisplayName;
+    }
+
+    /**
+     * The presentation requirements for the caller display name.
+     * See {@link TelecomManager} for valid values.
+     */
+    public int getCallerDisplayNamePresentation() {
+        return mCallerDisplayNamePresentation;
+    }
+
+    /** Gateway information for the call. */
+    public GatewayInfo getGatewayInfo() {
+        return mGatewayInfo;
+    }
+
+    /** PhoneAccountHandle information for the call. */
+    public PhoneAccountHandle getAccountHandle() {
+        return mAccountHandle;
+    }
+
+    /**
+     * Returns an object for remotely communicating through the video call provider's binder.
+     * @return The video call.
+     */
+    public InCallService.VideoCall getVideoCall() {
+        if (mVideoCall == null && mVideoCallProvider != null) {
+            try {
+                mVideoCall = new VideoCallImpl(mVideoCallProvider);
+            } catch (RemoteException ignored) {
+                // Ignore RemoteException.
+            }
+        }
+
+        return mVideoCall;
+    }
+
+    /**
+     * The conference call to which this call is conferenced. Null if not conferenced.
+     */
+    public String getParentCallId() {
+        return mParentCallId;
+    }
+
+    /**
+     * The child call-IDs if this call is a conference call. Returns an empty list if this is not
+     * a conference call or if the conference call contains no children.
+     */
+    public List<String> getChildCallIds() {
+        return mChildCallIds;
+    }
+
+    public List<String> getConferenceableCallIds() {
+        return mConferenceableCallIds;
+    }
+
+    /**
+     * The status label and icon.
+     *
+     * @return Status hints.
+     */
+    public StatusHints getStatusHints() {
+        return mStatusHints;
+    }
+
+    /**
+     * The video state.
+     * @return The video state of the call.
+     */
+    public int getVideoState() {
+        return mVideoState;
+    }
+
+    /**
+     * Any extras to pass with the call
+     *
+     * @return a bundle of extras
+     */
+    public Bundle getExtras() {
+        return mExtras;
+    }
+
+    /** Responsible for creating ParcelableCall objects for deserialized Parcels. */
+    public static final Parcelable.Creator<ParcelableCall> CREATOR =
+            new Parcelable.Creator<ParcelableCall> () {
+        @Override
+        public ParcelableCall createFromParcel(Parcel source) {
+            ClassLoader classLoader = ParcelableCall.class.getClassLoader();
+            String id = source.readString();
+            int state = source.readInt();
+            DisconnectCause disconnectCause = source.readParcelable(classLoader);
+            List<String> cannedSmsResponses = new ArrayList<>();
+            source.readList(cannedSmsResponses, classLoader);
+            int capabilities = source.readInt();
+            int properties = source.readInt();
+            long connectTimeMillis = source.readLong();
+            Uri handle = source.readParcelable(classLoader);
+            int handlePresentation = source.readInt();
+            String callerDisplayName = source.readString();
+            int callerDisplayNamePresentation = source.readInt();
+            GatewayInfo gatewayInfo = source.readParcelable(classLoader);
+            PhoneAccountHandle accountHandle = source.readParcelable(classLoader);
+            IVideoProvider videoCallProvider =
+                    IVideoProvider.Stub.asInterface(source.readStrongBinder());
+            String parentCallId = source.readString();
+            List<String> childCallIds = new ArrayList<>();
+            source.readList(childCallIds, classLoader);
+            StatusHints statusHints = source.readParcelable(classLoader);
+            int videoState = source.readInt();
+            List<String> conferenceableCallIds = new ArrayList<>();
+            source.readList(conferenceableCallIds, classLoader);
+            Bundle extras = source.readParcelable(classLoader);
+            return new ParcelableCall(
+                    id,
+                    state,
+                    disconnectCause,
+                    cannedSmsResponses,
+                    capabilities,
+                    properties,
+                    connectTimeMillis,
+                    handle,
+                    handlePresentation,
+                    callerDisplayName,
+                    callerDisplayNamePresentation,
+                    gatewayInfo,
+                    accountHandle,
+                    videoCallProvider,
+                    parentCallId,
+                    childCallIds,
+                    statusHints,
+                    videoState,
+                    conferenceableCallIds,
+                    extras);
+        }
+
+        @Override
+        public ParcelableCall[] newArray(int size) {
+            return new ParcelableCall[size];
+        }
+    };
+
+    /** {@inheritDoc} */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /** Writes ParcelableCall object into a Parcel. */
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeString(mId);
+        destination.writeInt(mState);
+        destination.writeParcelable(mDisconnectCause, 0);
+        destination.writeList(mCannedSmsResponses);
+        destination.writeInt(mCapabilities);
+        destination.writeInt(mProperties);
+        destination.writeLong(mConnectTimeMillis);
+        destination.writeParcelable(mHandle, 0);
+        destination.writeInt(mHandlePresentation);
+        destination.writeString(mCallerDisplayName);
+        destination.writeInt(mCallerDisplayNamePresentation);
+        destination.writeParcelable(mGatewayInfo, 0);
+        destination.writeParcelable(mAccountHandle, 0);
+        destination.writeStrongBinder(
+                mVideoCallProvider != null ? mVideoCallProvider.asBinder() : null);
+        destination.writeString(mParentCallId);
+        destination.writeList(mChildCallIds);
+        destination.writeParcelable(mStatusHints, 0);
+        destination.writeInt(mVideoState);
+        destination.writeList(mConferenceableCallIds);
+        destination.writeParcelable(mExtras, 0);
+    }
+
+    @Override
+    public String toString() {
+        return String.format("[%s, parent:%s, children:%s]", mId, mParentCallId, mChildCallIds);
+    }
+}
diff --git a/telecomm/java/android/telecom/ParcelableConference.aidl b/telecomm/java/android/telecom/ParcelableConference.aidl
new file mode 100644
index 0000000..155ba94
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableConference.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+parcelable ParcelableConference;
diff --git a/telecomm/java/android/telecom/ParcelableConference.java b/telecomm/java/android/telecom/ParcelableConference.java
new file mode 100644
index 0000000..97c709c
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableConference.java
@@ -0,0 +1,111 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * A parcelable representation of a conference connection.
+ * @hide
+ */
+public final class ParcelableConference implements Parcelable {
+
+    private PhoneAccountHandle mPhoneAccount;
+    private int mState;
+    private int mCapabilities;
+    private List<String> mConnectionIds;
+
+    public ParcelableConference(
+            PhoneAccountHandle phoneAccount,
+            int state,
+            int capabilities,
+            List<String> connectionIds) {
+        mPhoneAccount = phoneAccount;
+        mState = state;
+        mCapabilities = capabilities;
+        mConnectionIds = connectionIds;
+    }
+
+    @Override
+    public String toString() {
+        return (new StringBuffer())
+                .append("account: ")
+                .append(mPhoneAccount)
+                .append(", state: ")
+                .append(Connection.stateToString(mState))
+                .append(", capabilities: ")
+                .append(PhoneCapabilities.toString(mCapabilities))
+                .append(", children: ")
+                .append(mConnectionIds)
+                .toString();
+    }
+
+    public PhoneAccountHandle getPhoneAccount() {
+        return mPhoneAccount;
+    }
+
+    public int getState() {
+        return mState;
+    }
+
+    public int getCapabilities() {
+        return mCapabilities;
+    }
+
+    public List<String> getConnectionIds() {
+        return mConnectionIds;
+    }
+
+    public static final Parcelable.Creator<ParcelableConference> CREATOR =
+            new Parcelable.Creator<ParcelableConference> () {
+        @Override
+        public ParcelableConference createFromParcel(Parcel source) {
+            ClassLoader classLoader = ParcelableConference.class.getClassLoader();
+            PhoneAccountHandle phoneAccount = source.readParcelable(classLoader);
+            int state = source.readInt();
+            int capabilities = source.readInt();
+            List<String> connectionIds = new ArrayList<>(2);
+            source.readList(connectionIds, classLoader);
+
+            return new ParcelableConference(phoneAccount, state, capabilities, connectionIds);
+        }
+
+        @Override
+        public ParcelableConference[] newArray(int size) {
+            return new ParcelableConference[size];
+        }
+    };
+
+    /** {@inheritDoc} */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /** Writes ParcelableConference object into a Parcel. */
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeParcelable(mPhoneAccount, 0);
+        destination.writeInt(mState);
+        destination.writeInt(mCapabilities);
+        destination.writeList(mConnectionIds);
+    }
+}
diff --git a/telecomm/java/android/telecom/ParcelableConnection.aidl b/telecomm/java/android/telecom/ParcelableConnection.aidl
new file mode 100644
index 0000000..e91ebc3
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableConnection.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable ParcelableConnection;
diff --git a/telecomm/java/android/telecom/ParcelableConnection.java b/telecomm/java/android/telecom/ParcelableConnection.java
new file mode 100644
index 0000000..9004448
--- /dev/null
+++ b/telecomm/java/android/telecom/ParcelableConnection.java
@@ -0,0 +1,222 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+import android.net.Uri;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+import com.android.internal.telecom.IVideoProvider;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Information about a connection that is used between Telecom and the ConnectionService.
+ * This is used to send initial Connection information to Telecom when the connection is
+ * first created.
+ * @hide
+ */
+public final class ParcelableConnection implements Parcelable {
+    private final PhoneAccountHandle mPhoneAccount;
+    private final int mState;
+    private final int mCapabilities;
+    private final Uri mAddress;
+    private final int mAddressPresentation;
+    private final String mCallerDisplayName;
+    private final int mCallerDisplayNamePresentation;
+    private final IVideoProvider mVideoProvider;
+    private final int mVideoState;
+    private final boolean mRingbackRequested;
+    private final boolean mIsVoipAudioMode;
+    private final StatusHints mStatusHints;
+    private final DisconnectCause mDisconnectCause;
+    private final List<String> mConferenceableConnectionIds;
+
+    /** @hide */
+    public ParcelableConnection(
+            PhoneAccountHandle phoneAccount,
+            int state,
+            int capabilities,
+            Uri address,
+            int addressPresentation,
+            String callerDisplayName,
+            int callerDisplayNamePresentation,
+            IVideoProvider videoProvider,
+            int videoState,
+            boolean ringbackRequested,
+            boolean isVoipAudioMode,
+            StatusHints statusHints,
+            DisconnectCause disconnectCause,
+            List<String> conferenceableConnectionIds) {
+        mPhoneAccount = phoneAccount;
+        mState = state;
+        mCapabilities = capabilities;
+        mAddress = address;
+        mAddressPresentation = addressPresentation;
+        mCallerDisplayName = callerDisplayName;
+        mCallerDisplayNamePresentation = callerDisplayNamePresentation;
+        mVideoProvider = videoProvider;
+        mVideoState = videoState;
+        mRingbackRequested = ringbackRequested;
+        mIsVoipAudioMode = isVoipAudioMode;
+        mStatusHints = statusHints;
+        mDisconnectCause = disconnectCause;
+        this.mConferenceableConnectionIds = conferenceableConnectionIds;
+    }
+
+    public PhoneAccountHandle getPhoneAccount() {
+        return mPhoneAccount;
+    }
+
+    public int getState() {
+        return mState;
+    }
+
+    // Bit mask of actions a call supports, values are defined in {@link CallCapabilities}.
+    public int getCapabilities() {
+        return mCapabilities;
+    }
+
+    public Uri getHandle() {
+        return mAddress;
+    }
+
+    public int getHandlePresentation() {
+        return mAddressPresentation;
+    }
+
+    public String getCallerDisplayName() {
+        return mCallerDisplayName;
+    }
+
+    public int getCallerDisplayNamePresentation() {
+        return mCallerDisplayNamePresentation;
+    }
+
+    public IVideoProvider getVideoProvider() {
+        return mVideoProvider;
+    }
+
+    public int getVideoState() {
+        return mVideoState;
+    }
+
+    public boolean isRingbackRequested() {
+        return mRingbackRequested;
+    }
+
+    public boolean getIsVoipAudioMode() {
+        return mIsVoipAudioMode;
+    }
+
+    public final StatusHints getStatusHints() {
+        return mStatusHints;
+    }
+
+    public final DisconnectCause getDisconnectCause() {
+        return mDisconnectCause;
+    }
+
+    public final List<String> getConferenceableConnectionIds() {
+        return mConferenceableConnectionIds;
+    }
+
+    @Override
+    public String toString() {
+        return new StringBuilder()
+                .append("ParcelableConnection [act:")
+                .append(mPhoneAccount)
+                .append(", state:")
+                .append(mState)
+                .append(", capabilities:")
+                .append(PhoneCapabilities.toString(mCapabilities))
+                .toString();
+    }
+
+    public static final Parcelable.Creator<ParcelableConnection> CREATOR =
+            new Parcelable.Creator<ParcelableConnection> () {
+        @Override
+        public ParcelableConnection createFromParcel(Parcel source) {
+            ClassLoader classLoader = ParcelableConnection.class.getClassLoader();
+
+            PhoneAccountHandle phoneAccount = source.readParcelable(classLoader);
+            int state = source.readInt();
+            int capabilities = source.readInt();
+            Uri address = source.readParcelable(classLoader);
+            int addressPresentation = source.readInt();
+            String callerDisplayName = source.readString();
+            int callerDisplayNamePresentation = source.readInt();
+            IVideoProvider videoCallProvider =
+                    IVideoProvider.Stub.asInterface(source.readStrongBinder());
+            int videoState = source.readInt();
+            boolean ringbackRequested = source.readByte() == 1;
+            boolean audioModeIsVoip = source.readByte() == 1;
+            StatusHints statusHints = source.readParcelable(classLoader);
+            DisconnectCause disconnectCause = source.readParcelable(classLoader);
+            List<String> conferenceableConnectionIds = new ArrayList<>();
+            source.readStringList(conferenceableConnectionIds);
+
+            return new ParcelableConnection(
+                    phoneAccount,
+                    state,
+                    capabilities,
+                    address,
+                    addressPresentation,
+                    callerDisplayName,
+                    callerDisplayNamePresentation,
+                    videoCallProvider,
+                    videoState,
+                    ringbackRequested,
+                    audioModeIsVoip,
+                    statusHints,
+                    disconnectCause,
+                    conferenceableConnectionIds);
+        }
+
+        @Override
+        public ParcelableConnection[] newArray(int size) {
+            return new ParcelableConnection[size];
+        }
+    };
+
+    /** {@inheritDoc} */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /** Writes ParcelableConnection object into a Parcel. */
+    @Override
+    public void writeToParcel(Parcel destination, int flags) {
+        destination.writeParcelable(mPhoneAccount, 0);
+        destination.writeInt(mState);
+        destination.writeInt(mCapabilities);
+        destination.writeParcelable(mAddress, 0);
+        destination.writeInt(mAddressPresentation);
+        destination.writeString(mCallerDisplayName);
+        destination.writeInt(mCallerDisplayNamePresentation);
+        destination.writeStrongBinder(
+                mVideoProvider != null ? mVideoProvider.asBinder() : null);
+        destination.writeInt(mVideoState);
+        destination.writeByte((byte) (mRingbackRequested ? 1 : 0));
+        destination.writeByte((byte) (mIsVoipAudioMode ? 1 : 0));
+        destination.writeParcelable(mStatusHints, 0);
+        destination.writeParcelable(mDisconnectCause, 0);
+        destination.writeStringList(mConferenceableConnectionIds);
+    }
+}
diff --git a/telecomm/java/android/telecom/Phone.java b/telecomm/java/android/telecom/Phone.java
new file mode 100644
index 0000000..5131790
--- /dev/null
+++ b/telecomm/java/android/telecom/Phone.java
@@ -0,0 +1,284 @@
+/*
+ * 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 android.telecom;
+
+import android.annotation.SystemApi;
+import android.util.ArrayMap;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Map;
+import java.util.Objects;
+import java.util.concurrent.CopyOnWriteArrayList;
+
+/**
+ * A unified virtual device providing a means of voice (and other) communication on a device.
+ *
+ * {@hide}
+ */
+@SystemApi
+public final class Phone {
+
+    public abstract static class Listener {
+        /**
+         * Called when the audio state changes.
+         *
+         * @param phone The {@code Phone} calling this method.
+         * @param audioState The new {@link AudioState}.
+         */
+        public void onAudioStateChanged(Phone phone, AudioState audioState) { }
+
+        /**
+         * Called to bring the in-call screen to the foreground. The in-call experience should
+         * respond immediately by coming to the foreground to inform the user of the state of
+         * ongoing {@code Call}s.
+         *
+         * @param phone The {@code Phone} calling this method.
+         * @param showDialpad If true, put up the dialpad when the screen is shown.
+         */
+        public void onBringToForeground(Phone phone, boolean showDialpad) { }
+
+        /**
+         * Called when a {@code Call} has been added to this in-call session. The in-call user
+         * experience should add necessary state listeners to the specified {@code Call} and
+         * immediately start to show the user information about the existence
+         * and nature of this {@code Call}. Subsequent invocations of {@link #getCalls()} will
+         * include this {@code Call}.
+         *
+         * @param phone The {@code Phone} calling this method.
+         * @param call A newly added {@code Call}.
+         */
+        public void onCallAdded(Phone phone, Call call) { }
+
+        /**
+         * Called when a {@code Call} has been removed from this in-call session. The in-call user
+         * experience should remove any state listeners from the specified {@code Call} and
+         * immediately stop displaying any information about this {@code Call}.
+         * Subsequent invocations of {@link #getCalls()} will no longer include this {@code Call}.
+         *
+         * @param phone The {@code Phone} calling this method.
+         * @param call A newly removed {@code Call}.
+         */
+        public void onCallRemoved(Phone phone, Call call) { }
+    }
+
+    // A Map allows us to track each Call by its Telecom-specified call ID
+    private final Map<String, Call> mCallByTelecomCallId = new ArrayMap<>();
+
+    // A List allows us to keep the Calls in a stable iteration order so that casually developed
+    // user interface components do not incur any spurious jank
+    private final List<Call> mCalls = new CopyOnWriteArrayList<>();
+
+    // An unmodifiable view of the above List can be safely shared with subclass implementations
+    private final List<Call> mUnmodifiableCalls = Collections.unmodifiableList(mCalls);
+
+    private final InCallAdapter mInCallAdapter;
+
+    private AudioState mAudioState;
+
+    private final List<Listener> mListeners = new CopyOnWriteArrayList<>();
+
+    /** {@hide} */
+    Phone(InCallAdapter adapter) {
+        mInCallAdapter = adapter;
+    }
+
+    /** {@hide} */
+    final void internalAddCall(ParcelableCall parcelableCall) {
+        Call call = new Call(this, parcelableCall.getId(), mInCallAdapter);
+        mCallByTelecomCallId.put(parcelableCall.getId(), call);
+        mCalls.add(call);
+        checkCallTree(parcelableCall);
+        call.internalUpdate(parcelableCall, mCallByTelecomCallId);
+        fireCallAdded(call);
+     }
+
+    /** {@hide} */
+    final void internalRemoveCall(Call call) {
+        mCallByTelecomCallId.remove(call.internalGetCallId());
+        mCalls.remove(call);
+        fireCallRemoved(call);
+    }
+
+    /** {@hide} */
+    final void internalUpdateCall(ParcelableCall parcelableCall) {
+         Call call = mCallByTelecomCallId.get(parcelableCall.getId());
+         if (call != null) {
+             checkCallTree(parcelableCall);
+             call.internalUpdate(parcelableCall, mCallByTelecomCallId);
+         }
+     }
+
+    /** {@hide} */
+    final void internalSetPostDialWait(String telecomId, String remaining) {
+        Call call = mCallByTelecomCallId.get(telecomId);
+        if (call != null) {
+            call.internalSetPostDialWait(remaining);
+        }
+    }
+
+    /** {@hide} */
+    final void internalAudioStateChanged(AudioState audioState) {
+        if (!Objects.equals(mAudioState, audioState)) {
+            mAudioState = audioState;
+            fireAudioStateChanged(audioState);
+        }
+    }
+
+    /** {@hide} */
+    final Call internalGetCallByTelecomId(String telecomId) {
+        return mCallByTelecomCallId.get(telecomId);
+    }
+
+    /** {@hide} */
+    final void internalBringToForeground(boolean showDialpad) {
+        fireBringToForeground(showDialpad);
+    }
+
+    /**
+     * Called to destroy the phone and cleanup any lingering calls.
+     * @hide
+     */
+    final void destroy() {
+        for (Call call : mCalls) {
+            if (call.getState() != Call.STATE_DISCONNECTED) {
+                call.internalSetDisconnected();
+            }
+        }
+    }
+
+    /**
+     * Adds a listener to this {@code Phone}.
+     *
+     * @param listener A {@code Listener} object.
+     */
+    public final void addListener(Listener listener) {
+        mListeners.add(listener);
+    }
+
+    /**
+     * Removes a listener from this {@code Phone}.
+     *
+     * @param listener A {@code Listener} object.
+     */
+    public final void removeListener(Listener listener) {
+        if (listener != null) {
+            mListeners.remove(listener);
+        }
+    }
+
+    /**
+     * Obtains the current list of {@code Call}s to be displayed by this in-call experience.
+     *
+     * @return A list of the relevant {@code Call}s.
+     */
+    public final List<Call> getCalls() {
+        return mUnmodifiableCalls;
+    }
+
+    /**
+     * Sets the microphone mute state. When this request is honored, there will be change to
+     * the {@link #getAudioState()}.
+     *
+     * @param state {@code true} if the microphone should be muted; {@code false} otherwise.
+     */
+    public final void setMuted(boolean state) {
+        mInCallAdapter.mute(state);
+    }
+
+    /**
+     * Sets the audio route (speaker, bluetooth, etc...).  When this request is honored, there will
+     * be change to the {@link #getAudioState()}.
+     *
+     * @param route The audio route to use.
+     */
+    public final void setAudioRoute(int route) {
+        mInCallAdapter.setAudioRoute(route);
+    }
+
+    /**
+     * Turns the proximity sensor on. When this request is made, the proximity sensor will
+     * become active, and the touch screen and display will be turned off when the user's face
+     * is detected to be in close proximity to the screen. This operation is a no-op on devices
+     * that do not have a proximity sensor.
+     */
+    public final void setProximitySensorOn() {
+        mInCallAdapter.turnProximitySensorOn();
+    }
+
+    /**
+     * Turns the proximity sensor off. When this request is made, the proximity sensor will
+     * become inactive, and no longer affect the touch screen and display. This operation is a
+     * no-op on devices that do not have a proximity sensor.
+     *
+     * @param screenOnImmediately If true, the screen will be turned on immediately if it was
+     * previously off. Otherwise, the screen will only be turned on after the proximity sensor
+     * is no longer triggered.
+     */
+    public final void setProximitySensorOff(boolean screenOnImmediately) {
+        mInCallAdapter.turnProximitySensorOff(screenOnImmediately);
+    }
+
+    /**
+     * Obtains the current phone call audio state of the {@code Phone}.
+     *
+     * @return An object encapsulating the audio state.
+     */
+    public final AudioState getAudioState() {
+        return mAudioState;
+    }
+
+    private void fireCallAdded(Call call) {
+        for (Listener listener : mListeners) {
+            listener.onCallAdded(this, call);
+        }
+    }
+
+    private void fireCallRemoved(Call call) {
+        for (Listener listener : mListeners) {
+            listener.onCallRemoved(this, call);
+        }
+    }
+
+    private void fireAudioStateChanged(AudioState audioState) {
+        for (Listener listener : mListeners) {
+            listener.onAudioStateChanged(this, audioState);
+        }
+    }
+
+    private void fireBringToForeground(boolean showDialpad) {
+        for (Listener listener : mListeners) {
+            listener.onBringToForeground(this, showDialpad);
+        }
+    }
+
+    private void checkCallTree(ParcelableCall parcelableCall) {
+        if (parcelableCall.getParentCallId() != null &&
+                !mCallByTelecomCallId.containsKey(parcelableCall.getParentCallId())) {
+            Log.wtf(this, "ParcelableCall %s has nonexistent parent %s",
+                    parcelableCall.getId(), parcelableCall.getParentCallId());
+        }
+        if (parcelableCall.getChildCallIds() != null) {
+            for (int i = 0; i < parcelableCall.getChildCallIds().size(); i++) {
+                if (!mCallByTelecomCallId.containsKey(parcelableCall.getChildCallIds().get(i))) {
+                    Log.wtf(this, "ParcelableCall %s has nonexistent child %s",
+                            parcelableCall.getId(), parcelableCall.getChildCallIds().get(i));
+                }
+            }
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/PhoneAccount.aidl b/telecomm/java/android/telecom/PhoneAccount.aidl
new file mode 100644
index 0000000..d5e6058
--- /dev/null
+++ b/telecomm/java/android/telecom/PhoneAccount.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+/**
+ * {@hide}
+  */
+parcelable PhoneAccount;
diff --git a/telecomm/java/android/telecom/PhoneAccount.java b/telecomm/java/android/telecom/PhoneAccount.java
new file mode 100644
index 0000000..4b059b2
--- /dev/null
+++ b/telecomm/java/android/telecom/PhoneAccount.java
@@ -0,0 +1,449 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.content.Context;
+import android.content.pm.PackageManager;
+import android.content.res.Resources.NotFoundException;
+import android.graphics.drawable.Drawable;
+import android.net.Uri;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.text.TextUtils;
+
+import java.lang.String;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.MissingResourceException;
+
+/**
+ * Describes a distinct account, line of service or call placement method that the system
+ * can use to place phone calls.
+ */
+public class PhoneAccount implements Parcelable {
+
+    /**
+     * Flag indicating that this {@code PhoneAccount} can act as a connection manager for
+     * other connections. The {@link ConnectionService} associated with this {@code PhoneAccount}
+     * will be allowed to manage phone calls including using its own proprietary phone-call
+     * implementation (like VoIP calling) to make calls instead of the telephony stack.
+     * <p>
+     * When a user opts to place a call using the SIM-based telephony stack, the
+     * {@link ConnectionService} associated with this {@code PhoneAccount} will be attempted first
+     * if the user has explicitly selected it to be used as the default connection manager.
+     * <p>
+     * See {@link #getCapabilities}
+     */
+    public static final int CAPABILITY_CONNECTION_MANAGER = 0x1;
+
+    /**
+     * Flag indicating that this {@code PhoneAccount} can make phone calls in place of
+     * traditional SIM-based telephony calls. This account will be treated as a distinct method
+     * for placing calls alongside the traditional SIM-based telephony stack. This flag is
+     * distinct from {@link #CAPABILITY_CONNECTION_MANAGER} in that it is not allowed to manage
+     * calls from or use the built-in telephony stack to place its calls.
+     * <p>
+     * See {@link #getCapabilities}
+     * <p>
+     * {@hide}
+     */
+    public static final int CAPABILITY_CALL_PROVIDER = 0x2;
+
+    /**
+     * Flag indicating that this {@code PhoneAccount} represents a built-in PSTN SIM
+     * subscription.
+     * <p>
+     * Only the Android framework can register a {@code PhoneAccount} having this capability.
+     * <p>
+     * See {@link #getCapabilities}
+     */
+    public static final int CAPABILITY_SIM_SUBSCRIPTION = 0x4;
+
+    /**
+     * Flag indicating that this {@code PhoneAccount} is capable of placing video calls.
+     * <p>
+     * See {@link #getCapabilities}
+     * @hide
+     */
+    public static final int CAPABILITY_VIDEO_CALLING = 0x8;
+
+    /**
+     * Flag indicating that this {@code PhoneAccount} is capable of placing emergency calls.
+     * By default all PSTN {@code PhoneAccount}s are capable of placing emergency calls.
+     * <p>
+     * See {@link #getCapabilities}
+     */
+    public static final int CAPABILITY_PLACE_EMERGENCY_CALLS = 0x10;
+
+    /**
+     * URI scheme for telephone number URIs.
+     */
+    public static final String SCHEME_TEL = "tel";
+
+    /**
+     * URI scheme for voicemail URIs.
+     */
+    public static final String SCHEME_VOICEMAIL = "voicemail";
+
+    /**
+     * URI scheme for SIP URIs.
+     */
+    public static final String SCHEME_SIP = "sip";
+
+    private final PhoneAccountHandle mAccountHandle;
+    private final Uri mAddress;
+    private final Uri mSubscriptionAddress;
+    private final int mCapabilities;
+    private final int mIconResId;
+    private final CharSequence mLabel;
+    private final CharSequence mShortDescription;
+    private final List<String> mSupportedUriSchemes;
+
+    public static class Builder {
+        private PhoneAccountHandle mAccountHandle;
+        private Uri mAddress;
+        private Uri mSubscriptionAddress;
+        private int mCapabilities;
+        private int mIconResId;
+        private CharSequence mLabel;
+        private CharSequence mShortDescription;
+        private List<String> mSupportedUriSchemes = new ArrayList<String>();
+
+        public Builder(PhoneAccountHandle accountHandle, CharSequence label) {
+            this.mAccountHandle = accountHandle;
+            this.mLabel = label;
+        }
+
+        /**
+         * Creates an instance of the {@link PhoneAccount.Builder} from an existing
+         * {@link PhoneAccount}.
+         *
+         * @param phoneAccount The {@link PhoneAccount} used to initialize the builder.
+         */
+        public Builder(PhoneAccount phoneAccount) {
+            mAccountHandle = phoneAccount.getAccountHandle();
+            mAddress = phoneAccount.getAddress();
+            mSubscriptionAddress = phoneAccount.getSubscriptionAddress();
+            mCapabilities = phoneAccount.getCapabilities();
+            mIconResId = phoneAccount.getIconResId();
+            mLabel = phoneAccount.getLabel();
+            mShortDescription = phoneAccount.getShortDescription();
+            mSupportedUriSchemes.addAll(phoneAccount.getSupportedUriSchemes());
+        }
+
+        public Builder setAddress(Uri value) {
+            this.mAddress = value;
+            return this;
+        }
+
+        public Builder setSubscriptionAddress(Uri value) {
+            this.mSubscriptionAddress = value;
+            return this;
+        }
+
+        public Builder setCapabilities(int value) {
+            this.mCapabilities = value;
+            return this;
+        }
+
+        public Builder setIconResId(int value) {
+            this.mIconResId = value;
+            return this;
+        }
+
+        public Builder setShortDescription(CharSequence value) {
+            this.mShortDescription = value;
+            return this;
+        }
+
+        /**
+         * Specifies an additional URI scheme supported by the {@link PhoneAccount}.
+         *
+         * @param uriScheme The URI scheme.
+         * @return The Builder.
+         * @hide
+         */
+        public Builder addSupportedUriScheme(String uriScheme) {
+            if (!TextUtils.isEmpty(uriScheme) && !mSupportedUriSchemes.contains(uriScheme)) {
+                this.mSupportedUriSchemes.add(uriScheme);
+            }
+            return this;
+        }
+
+        /**
+         * Specifies the URI schemes supported by the {@link PhoneAccount}.
+         *
+         * @param uriSchemes The URI schemes.
+         * @return The Builder.
+         */
+        public Builder setSupportedUriSchemes(List<String> uriSchemes) {
+            mSupportedUriSchemes.clear();
+
+            if (uriSchemes != null && !uriSchemes.isEmpty()) {
+                for (String uriScheme : uriSchemes) {
+                    addSupportedUriScheme(uriScheme);
+                }
+            }
+            return this;
+        }
+
+        /**
+         * Creates an instance of a {@link PhoneAccount} based on the current builder settings.
+         *
+         * @return The {@link PhoneAccount}.
+         */
+        public PhoneAccount build() {
+            // If no supported URI schemes were defined, assume "tel" is supported.
+            if (mSupportedUriSchemes.isEmpty()) {
+                addSupportedUriScheme(SCHEME_TEL);
+            }
+
+            return new PhoneAccount(
+                    mAccountHandle,
+                    mAddress,
+                    mSubscriptionAddress,
+                    mCapabilities,
+                    mIconResId,
+                    mLabel,
+                    mShortDescription,
+                    mSupportedUriSchemes);
+        }
+    }
+
+    private PhoneAccount(
+            PhoneAccountHandle account,
+            Uri address,
+            Uri subscriptionAddress,
+            int capabilities,
+            int iconResId,
+            CharSequence label,
+            CharSequence shortDescription,
+            List<String> supportedUriSchemes) {
+        mAccountHandle = account;
+        mAddress = address;
+        mSubscriptionAddress = subscriptionAddress;
+        mCapabilities = capabilities;
+        mIconResId = iconResId;
+        mLabel = label;
+        mShortDescription = shortDescription;
+        mSupportedUriSchemes = Collections.unmodifiableList(supportedUriSchemes);
+    }
+
+    public static Builder builder(
+            PhoneAccountHandle accountHandle,
+            CharSequence label) {
+        return new Builder(accountHandle, label);
+    }
+
+    /**
+     * Returns a builder initialized with the current {@link PhoneAccount} instance.
+     *
+     * @return The builder.
+     * @hide
+     */
+    public Builder toBuilder() { return new Builder(this); }
+
+    /**
+     * The unique identifier of this {@code PhoneAccount}.
+     *
+     * @return A {@code PhoneAccountHandle}.
+     */
+    public PhoneAccountHandle getAccountHandle() {
+        return mAccountHandle;
+    }
+
+    /**
+     * The address (e.g., a phone number) associated with this {@code PhoneAccount}. This
+     * represents the destination from which outgoing calls using this {@code PhoneAccount}
+     * will appear to come, if applicable, and the destination to which incoming calls using this
+     * {@code PhoneAccount} may be addressed.
+     *
+     * @return A address expressed as a {@code Uri}, for example, a phone number.
+     */
+    public Uri getAddress() {
+        return mAddress;
+    }
+
+    /**
+     * The raw callback number used for this {@code PhoneAccount}, as distinct from
+     * {@link #getAddress()}. For the majority of {@code PhoneAccount}s this should be registered
+     * as {@code null}.  It is used by the system for SIM-based {@code PhoneAccount} registration
+     * where {@link android.telephony.TelephonyManager#setLine1NumberForDisplay(String, String)}
+     * has been used to alter the callback number.
+     * <p>
+     *
+     * @return The subscription number, suitable for display to the user.
+     */
+    public Uri getSubscriptionAddress() {
+        return mSubscriptionAddress;
+    }
+
+    /**
+     * The capabilities of this {@code PhoneAccount}.
+     *
+     * @return A bit field of flags describing this {@code PhoneAccount}'s capabilities.
+     */
+    public int getCapabilities() {
+        return mCapabilities;
+    }
+
+    /**
+     * Determines if this {@code PhoneAccount} has a capabilities specified by the passed in
+     * bit mask.
+     *
+     * @param capability The capabilities to check.
+     * @return {@code True} if the phone account has the capability.
+     */
+    public boolean hasCapabilities(int capability) {
+        return (mCapabilities & capability) == capability;
+    }
+
+    /**
+     * A short label describing a {@code PhoneAccount}.
+     *
+     * @return A label for this {@code PhoneAccount}.
+     */
+    public CharSequence getLabel() {
+        return mLabel;
+    }
+
+    /**
+     * A short paragraph describing this {@code PhoneAccount}.
+     *
+     * @return A description for this {@code PhoneAccount}.
+     */
+    public CharSequence getShortDescription() {
+        return mShortDescription;
+    }
+
+    /**
+     * The URI schemes supported by this {@code PhoneAccount}.
+     *
+     * @return The URI schemes.
+     */
+    public List<String> getSupportedUriSchemes() {
+        return mSupportedUriSchemes;
+    }
+
+    /**
+     * Determines if the {@link PhoneAccount} supports calls to/from addresses with a specified URI
+     * scheme.
+     *
+     * @param uriScheme The URI scheme to check.
+     * @return {@code True} if the {@code PhoneAccount} supports calls to/from addresses with the
+     * specified URI scheme.
+     */
+    public boolean supportsUriScheme(String uriScheme) {
+        if (mSupportedUriSchemes == null || uriScheme == null) {
+            return false;
+        }
+
+        for (String scheme : mSupportedUriSchemes) {
+            if (scheme != null && scheme.equals(uriScheme)) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * The icon resource ID for the icon of this {@code PhoneAccount}.
+     *
+     * @return A resource ID.
+     */
+    public int getIconResId() {
+        return mIconResId;
+    }
+
+    /**
+     * An icon to represent this {@code PhoneAccount} in a user interface.
+     *
+     * @return An icon for this {@code PhoneAccount}.
+     */
+    public Drawable getIcon(Context context) {
+        return getIcon(context, mIconResId);
+    }
+
+    private Drawable getIcon(Context context, int resId) {
+        Context packageContext;
+        try {
+            packageContext = context.createPackageContext(
+                    mAccountHandle.getComponentName().getPackageName(), 0);
+        } catch (PackageManager.NameNotFoundException e) {
+            Log.w(this, "Cannot find package %s", mAccountHandle.getComponentName().getPackageName());
+            return null;
+        }
+        try {
+            return packageContext.getDrawable(resId);
+        } catch (NotFoundException|MissingResourceException e) {
+            Log.e(this, e, "Cannot find icon %d in package %s",
+                    resId, mAccountHandle.getComponentName().getPackageName());
+            return null;
+        }
+    }
+
+    //
+    // Parcelable implementation
+    //
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeParcelable(mAccountHandle, 0);
+        out.writeParcelable(mAddress, 0);
+        out.writeParcelable(mSubscriptionAddress, 0);
+        out.writeInt(mCapabilities);
+        out.writeInt(mIconResId);
+        out.writeCharSequence(mLabel);
+        out.writeCharSequence(mShortDescription);
+        out.writeList(mSupportedUriSchemes);
+    }
+
+    public static final Creator<PhoneAccount> CREATOR
+            = new Creator<PhoneAccount>() {
+        @Override
+        public PhoneAccount createFromParcel(Parcel in) {
+            return new PhoneAccount(in);
+        }
+
+        @Override
+        public PhoneAccount[] newArray(int size) {
+            return new PhoneAccount[size];
+        }
+    };
+
+    private PhoneAccount(Parcel in) {
+        ClassLoader classLoader = PhoneAccount.class.getClassLoader();
+
+        mAccountHandle = in.readParcelable(getClass().getClassLoader());
+        mAddress = in.readParcelable(getClass().getClassLoader());
+        mSubscriptionAddress = in.readParcelable(getClass().getClassLoader());
+        mCapabilities = in.readInt();
+        mIconResId = in.readInt();
+        mLabel = in.readCharSequence();
+        mShortDescription = in.readCharSequence();
+
+        List<String> supportedUriSchemes = new ArrayList<>();
+        in.readList(supportedUriSchemes, classLoader);
+        mSupportedUriSchemes = Collections.unmodifiableList(supportedUriSchemes);
+    }
+}
diff --git a/telecomm/java/android/telecom/PhoneAccountHandle.aidl b/telecomm/java/android/telecom/PhoneAccountHandle.aidl
new file mode 100644
index 0000000..f8f9656
--- /dev/null
+++ b/telecomm/java/android/telecom/PhoneAccountHandle.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2008 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 android.telecom;
+
+/**
+ * {@hide}
+  */
+parcelable PhoneAccountHandle;
diff --git a/telecomm/java/android/telecom/PhoneAccountHandle.java b/telecomm/java/android/telecom/PhoneAccountHandle.java
new file mode 100644
index 0000000..e13df76
--- /dev/null
+++ b/telecomm/java/android/telecom/PhoneAccountHandle.java
@@ -0,0 +1,120 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.content.ComponentName;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+import java.util.Objects;
+
+/**
+ * The unique identifier for a {@link PhoneAccount}.
+ */
+public class PhoneAccountHandle implements Parcelable {
+    private ComponentName mComponentName;
+    private String mId;
+
+    public PhoneAccountHandle(
+            ComponentName componentName,
+            String id) {
+        mComponentName = componentName;
+        mId = id;
+    }
+
+    /**
+     * The {@code ComponentName} of the {@link android.telecom.ConnectionService} which is
+     * responsible for making phone calls using this {@code PhoneAccountHandle}.
+     *
+     * @return A suitable {@code ComponentName}.
+     */
+    public ComponentName getComponentName() {
+        return mComponentName;
+    }
+
+    /**
+     * A string that uniquely distinguishes this particular {@code PhoneAccountHandle} from all the
+     * others supported by the {@link ConnectionService} that created it.
+     * <p>
+     * A {@code ConnectionService} must select identifiers that are stable for the lifetime of
+     * their users' relationship with their service, across many Android devices. For example, a
+     * good set of identifiers might be the email addresses with which with users registered for
+     * their accounts with a particular service. Depending on how a service chooses to operate,
+     * a bad set of identifiers might be an increasing series of integers
+     * ({@code 0}, {@code 1}, {@code 2}, ...) that are generated locally on each phone and could
+     * collide with values generated on other phones or after a data wipe of a given phone.
+     *
+     * @return A service-specific unique identifier for this {@code PhoneAccountHandle}.
+     */
+    public String getId() {
+        return mId;
+    }
+
+    @Override
+    public int hashCode() {
+        return Objects.hashCode(mComponentName) + Objects.hashCode(mId);
+    }
+
+    @Override
+    public String toString() {
+        return new StringBuilder().append(mComponentName)
+                    .append(", ")
+                    .append(mId)
+                    .toString();
+    }
+
+    @Override
+    public boolean equals(Object other) {
+        return other != null &&
+                other instanceof PhoneAccountHandle &&
+                Objects.equals(((PhoneAccountHandle) other).getComponentName(),
+                        getComponentName()) &&
+                Objects.equals(((PhoneAccountHandle) other).getId(), getId());
+    }
+
+    //
+    // Parcelable implementation.
+    //
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeParcelable(mComponentName, flags);
+        out.writeString(mId);
+    }
+
+    public static final Creator<PhoneAccountHandle> CREATOR = new Creator<PhoneAccountHandle>() {
+        @Override
+        public PhoneAccountHandle createFromParcel(Parcel in) {
+            return new PhoneAccountHandle(in);
+        }
+
+        @Override
+        public PhoneAccountHandle[] newArray(int size) {
+            return new PhoneAccountHandle[size];
+        }
+    };
+
+    private PhoneAccountHandle(Parcel in) {
+        mComponentName = in.readParcelable(getClass().getClassLoader());
+        mId = in.readString();
+    }
+}
diff --git a/telecomm/java/android/telecom/PhoneCapabilities.java b/telecomm/java/android/telecom/PhoneCapabilities.java
new file mode 100644
index 0000000..e73dfe2
--- /dev/null
+++ b/telecomm/java/android/telecom/PhoneCapabilities.java
@@ -0,0 +1,139 @@
+/*
+ * Copyright 2014, 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 android.telecom;
+
+/**
+ * Defines capabilities a phone call can support, such as conference calling and video telephony.
+ * Also defines properties of a phone call, such as whether it is using VoLTE technology.
+ */
+public final class PhoneCapabilities {
+    /** Call can currently be put on hold or unheld. */
+    public static final int HOLD               = 0x00000001;
+
+    /** Call supports the hold feature. */
+    public static final int SUPPORT_HOLD       = 0x00000002;
+
+    /**
+     * Calls within a conference can be merged. Some connection services create a conference call
+     * only after two calls have been merged.  However, a conference call can also be added the
+     * moment there are more than one call. CDMA calls are implemented in this way because the call
+     * actions are more limited when more than one call exists. This flag allows merge to be exposed
+     * as a capability on the conference call instead of individual calls.
+     */
+    public static final int MERGE_CONFERENCE   = 0x00000004;
+
+    /** Calls withing a conference can be swapped between foreground and background. */
+    public static final int SWAP_CONFERENCE    = 0x00000008;
+
+    /** Call currently supports adding another call to this one. */
+    public static final int ADD_CALL           = 0x00000010;
+
+    /** Call supports responding via text option. */
+    public static final int RESPOND_VIA_TEXT   = 0x00000020;
+
+    /** Call can be muted. */
+    public static final int MUTE               = 0x00000040;
+
+    /**
+     * Call supports conference call management. This capability only applies to conference calls
+     * which can have other calls as children.
+     */
+    public static final int MANAGE_CONFERENCE = 0x00000080;
+
+    /**
+     * Local device supports video telephony.
+     * @hide
+     */
+    public static final int SUPPORTS_VT_LOCAL  = 0x00000100;
+
+    /**
+     * Remote device supports video telephony.
+     * @hide
+     */
+    public static final int SUPPORTS_VT_REMOTE = 0x00000200;
+
+    /**
+     * Call is using voice over LTE.
+     * @hide
+     */
+    public static final int VoLTE = 0x00000400;
+
+    /**
+     * Call is using voice over WIFI.
+     * @hide
+     */
+    public static final int VoWIFI = 0x00000800;
+
+    /**
+     * Call is able to be separated from its parent {@code Conference}, if any.
+     */
+    public static final int SEPARATE_FROM_CONFERENCE = 0x00001000;
+
+    /**
+     * Call is able to be individually disconnected when in a {@code Conference}.
+     */
+    public static final int DISCONNECT_FROM_CONFERENCE = 0x00002000;
+
+    public static final int ALL = HOLD | SUPPORT_HOLD | MERGE_CONFERENCE | SWAP_CONFERENCE
+            | ADD_CALL | RESPOND_VIA_TEXT | MUTE | MANAGE_CONFERENCE | SEPARATE_FROM_CONFERENCE
+            | DISCONNECT_FROM_CONFERENCE;
+
+    public static String toString(int capabilities) {
+        StringBuilder builder = new StringBuilder();
+        builder.append("[Capabilities:");
+        if ((capabilities & HOLD) != 0) {
+            builder.append(" HOLD");
+        }
+        if ((capabilities & SUPPORT_HOLD) != 0) {
+            builder.append(" SUPPORT_HOLD");
+        }
+        if ((capabilities & MERGE_CONFERENCE) != 0) {
+            builder.append(" MERGE_CONFERENCE");
+        }
+        if ((capabilities & SWAP_CONFERENCE) != 0) {
+            builder.append(" SWAP_CONFERENCE");
+        }
+        if ((capabilities & ADD_CALL) != 0) {
+            builder.append(" ADD_CALL");
+        }
+        if ((capabilities & RESPOND_VIA_TEXT) != 0) {
+            builder.append(" RESPOND_VIA_TEXT");
+        }
+        if ((capabilities & MUTE) != 0) {
+            builder.append(" MUTE");
+        }
+        if ((capabilities & MANAGE_CONFERENCE) != 0) {
+            builder.append(" MANAGE_CONFERENCE");
+        }
+        if ((capabilities & SUPPORTS_VT_LOCAL) != 0) {
+            builder.append(" SUPPORTS_VT_LOCAL");
+        }
+        if ((capabilities & SUPPORTS_VT_REMOTE) != 0) {
+            builder.append(" SUPPORTS_VT_REMOTE");
+        }
+        if ((capabilities & VoLTE) != 0) {
+            builder.append(" VoLTE");
+        }
+        if ((capabilities & VoWIFI) != 0) {
+            builder.append(" VoWIFI");
+        }
+        builder.append("]");
+        return builder.toString();
+    }
+
+    private PhoneCapabilities() {}
+}
diff --git a/telecomm/java/android/telecom/RemoteConference.java b/telecomm/java/android/telecom/RemoteConference.java
new file mode 100644
index 0000000..f931bc5
--- /dev/null
+++ b/telecomm/java/android/telecom/RemoteConference.java
@@ -0,0 +1,212 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import com.android.internal.telecom.IConnectionService;
+
+import android.os.RemoteException;
+
+import java.util.Collections;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.CopyOnWriteArrayList;
+import java.util.concurrent.CopyOnWriteArraySet;
+
+/**
+ * Represents a conference call which can contain any number of {@link Connection} objects.
+ */
+public final class RemoteConference {
+
+    public abstract static class Callback {
+        public void onStateChanged(RemoteConference conference, int oldState, int newState) {}
+        public void onDisconnected(RemoteConference conference, DisconnectCause disconnectCause) {}
+        public void onConnectionAdded(RemoteConference conference, RemoteConnection connection) {}
+        public void onConnectionRemoved(RemoteConference conference, RemoteConnection connection) {}
+        public void onCapabilitiesChanged(RemoteConference conference, int capabilities) {}
+        public void onDestroyed(RemoteConference conference) {}
+    }
+
+    private final String mId;
+    private final IConnectionService mConnectionService;
+
+    private final Set<Callback> mCallbacks = new CopyOnWriteArraySet<>();
+    private final List<RemoteConnection> mChildConnections = new CopyOnWriteArrayList<>();
+    private final List<RemoteConnection> mUnmodifiableChildConnections =
+            Collections.unmodifiableList(mChildConnections);
+
+    private int mState = Connection.STATE_NEW;
+    private DisconnectCause mDisconnectCause;
+    private int mCallCapabilities;
+
+    /** {@hide} */
+    RemoteConference(String id, IConnectionService connectionService) {
+        mId = id;
+        mConnectionService = connectionService;
+    }
+
+    /** {@hide} */
+    String getId() {
+        return mId;
+    }
+
+    /** {@hide} */
+    void setDestroyed() {
+        for (RemoteConnection connection : mChildConnections) {
+            connection.setConference(null);
+        }
+        for (Callback c : mCallbacks) {
+            c.onDestroyed(this);
+        }
+    }
+
+    /** {@hide} */
+    void setState(int newState) {
+        if (newState != Connection.STATE_ACTIVE &&
+                newState != Connection.STATE_HOLDING &&
+                newState != Connection.STATE_DISCONNECTED) {
+            Log.w(this, "Unsupported state transition for Conference call.",
+                    Connection.stateToString(newState));
+            return;
+        }
+
+        if (mState != newState) {
+            int oldState = mState;
+            mState = newState;
+            for (Callback c : mCallbacks) {
+                c.onStateChanged(this, oldState, newState);
+            }
+        }
+    }
+
+    /** {@hide} */
+    void addConnection(RemoteConnection connection) {
+        if (!mChildConnections.contains(connection)) {
+            mChildConnections.add(connection);
+            connection.setConference(this);
+            for (Callback c : mCallbacks) {
+                c.onConnectionAdded(this, connection);
+            }
+        }
+    }
+
+    /** {@hide} */
+    void removeConnection(RemoteConnection connection) {
+        if (mChildConnections.contains(connection)) {
+            mChildConnections.remove(connection);
+            connection.setConference(null);
+            for (Callback c : mCallbacks) {
+                c.onConnectionRemoved(this, connection);
+            }
+        }
+    }
+
+    /** {@hide} */
+    void setCallCapabilities(int capabilities) {
+        if (mCallCapabilities != capabilities) {
+            mCallCapabilities = capabilities;
+            for (Callback c : mCallbacks) {
+                c.onCapabilitiesChanged(this, mCallCapabilities);
+            }
+        }
+    }
+
+    /** {@hide} */
+    void setDisconnected(DisconnectCause disconnectCause) {
+        if (mState != Connection.STATE_DISCONNECTED) {
+            mDisconnectCause = disconnectCause;
+            setState(Connection.STATE_DISCONNECTED);
+            for (Callback c : mCallbacks) {
+                c.onDisconnected(this, disconnectCause);
+            }
+        }
+    }
+
+    public final List<RemoteConnection> getConnections() {
+        return mUnmodifiableChildConnections;
+    }
+
+    public final int getState() {
+        return mState;
+    }
+
+    public final int getCallCapabilities() {
+        return mCallCapabilities;
+    }
+
+    public void disconnect() {
+        try {
+            mConnectionService.disconnect(mId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public void separate(RemoteConnection connection) {
+        if (mChildConnections.contains(connection)) {
+            try {
+                mConnectionService.splitFromConference(connection.getId());
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    public void hold() {
+        try {
+            mConnectionService.hold(mId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public void unhold() {
+        try {
+            mConnectionService.unhold(mId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public DisconnectCause getDisconnectCause() {
+        return mDisconnectCause;
+    }
+
+    public void playDtmfTone(char digit) {
+        try {
+            mConnectionService.playDtmfTone(mId, digit);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public void stopDtmfTone() {
+        try {
+            mConnectionService.stopDtmfTone(mId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public void setAudioState(AudioState state) {
+        try {
+            mConnectionService.onAudioStateChanged(mId, state);
+        } catch (RemoteException e) {
+        }
+    }
+
+    public final void registerCallback(Callback callback) {
+        mCallbacks.add(callback);
+    }
+
+    public final void unregisterCallback(Callback callback) {
+        mCallbacks.remove(callback);
+    }
+}
diff --git a/telecomm/java/android/telecom/RemoteConnection.java b/telecomm/java/android/telecom/RemoteConnection.java
new file mode 100644
index 0000000..9a094df
--- /dev/null
+++ b/telecomm/java/android/telecom/RemoteConnection.java
@@ -0,0 +1,898 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import com.android.internal.telecom.IConnectionService;
+import com.android.internal.telecom.IVideoCallback;
+import com.android.internal.telecom.IVideoProvider;
+
+import android.net.Uri;
+import android.os.IBinder;
+import android.os.RemoteException;
+import android.view.Surface;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+
+/**
+ * A connection provided to a {@link ConnectionService} by another {@code ConnectionService}
+ * running in a different process.
+ *
+ * @see ConnectionService#createRemoteOutgoingConnection(PhoneAccountHandle, ConnectionRequest)
+ * @see ConnectionService#createRemoteIncomingConnection(PhoneAccountHandle, ConnectionRequest)
+ */
+public final class RemoteConnection {
+
+    public static abstract class Callback {
+        /**
+         * Invoked when the state of this {@code RemoteConnection} has changed. See
+         * {@link #getState()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param state The new state of the {@code RemoteConnection}.
+         */
+        public void onStateChanged(RemoteConnection connection, int state) {}
+
+        /**
+         * Invoked when this {@code RemoteConnection} is disconnected.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param disconnectCause The ({@see DisconnectCause}) associated with this failed
+         *     connection.
+         */
+        public void onDisconnected(
+                RemoteConnection connection,
+                DisconnectCause disconnectCause) {}
+
+        /**
+         * Invoked when this {@code RemoteConnection} is requesting ringback. See
+         * {@link #isRingbackRequested()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param ringback Whether the {@code RemoteConnection} is requesting ringback.
+         */
+        public void onRingbackRequested(RemoteConnection connection, boolean ringback) {}
+
+        /**
+         * Indicates that the call capabilities of this {@code RemoteConnection} have changed.
+         * See {@link #getCallCapabilities()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param callCapabilities The new call capabilities of the {@code RemoteConnection}.
+         */
+        public void onCallCapabilitiesChanged(RemoteConnection connection, int callCapabilities) {}
+
+        /**
+         * Invoked when the post-dial sequence in the outgoing {@code Connection} has reached a
+         * pause character. This causes the post-dial signals to stop pending user confirmation. An
+         * implementation should present this choice to the user and invoke
+         * {@link RemoteConnection#postDialContinue(boolean)} when the user makes the choice.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param remainingPostDialSequence The post-dial characters that remain to be sent.
+         */
+        public void onPostDialWait(RemoteConnection connection, String remainingPostDialSequence) {}
+
+        /**
+         * Indicates that the VOIP audio status of this {@code RemoteConnection} has changed.
+         * See {@link #isVoipAudioMode()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param isVoip Whether the new audio state of the {@code RemoteConnection} is VOIP.
+         */
+        public void onVoipAudioChanged(RemoteConnection connection, boolean isVoip) {}
+
+        /**
+         * Indicates that the status hints of this {@code RemoteConnection} have changed. See
+         * {@link #getStatusHints()} ()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param statusHints The new status hints of the {@code RemoteConnection}.
+         */
+        public void onStatusHintsChanged(RemoteConnection connection, StatusHints statusHints) {}
+
+        /**
+         * Indicates that the address (e.g., phone number) of this {@code RemoteConnection} has
+         * changed. See {@link #getAddress()} and {@link #getAddressPresentation()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param address The new address of the {@code RemoteConnection}.
+         * @param presentation The presentation requirements for the address.
+         *        See {@link TelecomManager} for valid values.
+         */
+        public void onAddressChanged(RemoteConnection connection, Uri address, int presentation) {}
+
+        /**
+         * Indicates that the caller display name of this {@code RemoteConnection} has changed.
+         * See {@link #getCallerDisplayName()} and {@link #getCallerDisplayNamePresentation()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param callerDisplayName The new caller display name of the {@code RemoteConnection}.
+         * @param presentation The presentation requirements for the handle.
+         *        See {@link TelecomManager} for valid values.
+         */
+        public void onCallerDisplayNameChanged(
+                RemoteConnection connection, String callerDisplayName, int presentation) {}
+
+        /**
+         * Indicates that the video state of this {@code RemoteConnection} has changed.
+         * See {@link #getVideoState()}.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param videoState The new video state of the {@code RemoteConnection}.
+         * @hide
+         */
+        public void onVideoStateChanged(RemoteConnection connection, int videoState) {}
+
+        /**
+         * Indicates that this {@code RemoteConnection} has been destroyed. No further requests
+         * should be made to the {@code RemoteConnection}, and references to it should be cleared.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         */
+        public void onDestroyed(RemoteConnection connection) {}
+
+        /**
+         * Indicates that the {@code RemoteConnection}s with which this {@code RemoteConnection}
+         * may be asked to create a conference has changed.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param conferenceableConnections The {@code RemoteConnection}s with which this
+         *         {@code RemoteConnection} may be asked to create a conference.
+         */
+        public void onConferenceableConnectionsChanged(
+                RemoteConnection connection,
+                List<RemoteConnection> conferenceableConnections) {}
+
+        /**
+         * Indicates that the {@code VideoProvider} associated with this {@code RemoteConnection}
+         * has changed.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param videoProvider The new {@code VideoProvider} associated with this
+         *         {@code RemoteConnection}.
+         * @hide
+         */
+        public void onVideoProviderChanged(
+                RemoteConnection connection, VideoProvider videoProvider) {}
+
+        /**
+         * Indicates that the {@code RemoteConference} that this {@code RemoteConnection} is a part
+         * of has changed.
+         *
+         * @param connection The {@code RemoteConnection} invoking this method.
+         * @param conference The {@code RemoteConference} of which this {@code RemoteConnection} is
+         *         a part, which may be {@code null}.
+         */
+        public void onConferenceChanged(
+                RemoteConnection connection,
+                RemoteConference conference) {}
+    }
+
+    /** {@hide} */
+    public static class VideoProvider {
+
+        public abstract static class Listener {
+            public void onReceiveSessionModifyRequest(
+                    VideoProvider videoProvider,
+                    VideoProfile videoProfile) {}
+
+            public void onReceiveSessionModifyResponse(
+                    VideoProvider videoProvider,
+                    int status,
+                    VideoProfile requestedProfile,
+                    VideoProfile responseProfile) {}
+
+            public void onHandleCallSessionEvent(VideoProvider videoProvider, int event) {}
+
+            public void onPeerDimensionsChanged(VideoProvider videoProvider, int width, int height) {}
+
+            public void onCallDataUsageChanged(VideoProvider videoProvider, int dataUsage) {}
+
+            public void onCameraCapabilitiesChanged(
+                    VideoProvider videoProvider,
+                    CameraCapabilities cameraCapabilities) {}
+        }
+
+        private final IVideoCallback mVideoCallbackDelegate = new IVideoCallback() {
+            @Override
+            public void receiveSessionModifyRequest(VideoProfile videoProfile) {
+                for (Listener l : mListeners) {
+                    l.onReceiveSessionModifyRequest(VideoProvider.this, videoProfile);
+                }
+            }
+
+            @Override
+            public void receiveSessionModifyResponse(int status, VideoProfile requestedProfile,
+                    VideoProfile responseProfile) {
+                for (Listener l : mListeners) {
+                    l.onReceiveSessionModifyResponse(
+                            VideoProvider.this,
+                            status,
+                            requestedProfile,
+                            responseProfile);
+                }
+            }
+
+            @Override
+            public void handleCallSessionEvent(int event) {
+                for (Listener l : mListeners) {
+                    l.onHandleCallSessionEvent(VideoProvider.this, event);
+                }
+            }
+
+            @Override
+            public void changePeerDimensions(int width, int height) {
+                for (Listener l : mListeners) {
+                    l.onPeerDimensionsChanged(VideoProvider.this, width, height);
+                }
+            }
+
+            @Override
+            public void changeCallDataUsage(int dataUsage) {
+                for (Listener l : mListeners) {
+                    l.onCallDataUsageChanged(VideoProvider.this, dataUsage);
+                }
+            }
+
+            @Override
+            public void changeCameraCapabilities(CameraCapabilities cameraCapabilities) {
+                for (Listener l : mListeners) {
+                    l.onCameraCapabilitiesChanged(VideoProvider.this, cameraCapabilities);
+                }
+            }
+
+            @Override
+            public IBinder asBinder() {
+                return null;
+            }
+        };
+
+        private final VideoCallbackServant mVideoCallbackServant =
+                new VideoCallbackServant(mVideoCallbackDelegate);
+
+        private final IVideoProvider mVideoProviderBinder;
+
+        /**
+         * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
+         * load factor before resizing, 1 means we only expect a single thread to
+         * access the map so make only a single shard
+         */
+        private final Set<Listener> mListeners = Collections.newSetFromMap(
+                new ConcurrentHashMap<Listener, Boolean>(8, 0.9f, 1));
+
+        public VideoProvider(IVideoProvider videoProviderBinder) {
+            mVideoProviderBinder = videoProviderBinder;
+            try {
+                mVideoProviderBinder.setVideoCallback(mVideoCallbackServant.getStub().asBinder());
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void addListener(Listener l) {
+            mListeners.add(l);
+        }
+
+        public void removeListener(Listener l) {
+            mListeners.remove(l);
+        }
+
+        public void setCamera(String cameraId) {
+            try {
+                mVideoProviderBinder.setCamera(cameraId);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void setPreviewSurface(Surface surface) {
+            try {
+                mVideoProviderBinder.setPreviewSurface(surface);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void setDisplaySurface(Surface surface) {
+            try {
+                mVideoProviderBinder.setDisplaySurface(surface);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void setDeviceOrientation(int rotation) {
+            try {
+                mVideoProviderBinder.setDeviceOrientation(rotation);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void setZoom(float value) {
+            try {
+                mVideoProviderBinder.setZoom(value);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void sendSessionModifyRequest(VideoProfile reqProfile) {
+            try {
+                mVideoProviderBinder.sendSessionModifyRequest(reqProfile);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void sendSessionModifyResponse(VideoProfile responseProfile) {
+            try {
+                mVideoProviderBinder.sendSessionModifyResponse(responseProfile);
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void requestCameraCapabilities() {
+            try {
+                mVideoProviderBinder.requestCameraCapabilities();
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void requestCallDataUsage() {
+            try {
+                mVideoProviderBinder.requestCallDataUsage();
+            } catch (RemoteException e) {
+            }
+        }
+
+        public void setPauseImage(String uri) {
+            try {
+                mVideoProviderBinder.setPauseImage(uri);
+            } catch (RemoteException e) {
+            }
+        }
+    }
+
+    private IConnectionService mConnectionService;
+    private final String mConnectionId;
+    /**
+     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
+     * load factor before resizing, 1 means we only expect a single thread to
+     * access the map so make only a single shard
+     */
+    private final Set<Callback> mCallbacks = Collections.newSetFromMap(
+            new ConcurrentHashMap<Callback, Boolean>(8, 0.9f, 1));
+    private final List<RemoteConnection> mConferenceableConnections = new ArrayList<>();
+    private final List<RemoteConnection> mUnmodifiableconferenceableConnections =
+            Collections.unmodifiableList(mConferenceableConnections);
+
+    private int mState = Connection.STATE_NEW;
+    private DisconnectCause mDisconnectCause;
+    private boolean mRingbackRequested;
+    private boolean mConnected;
+    private int mCallCapabilities;
+    private int mVideoState;
+    private VideoProvider mVideoProvider;
+    private boolean mIsVoipAudioMode;
+    private StatusHints mStatusHints;
+    private Uri mAddress;
+    private int mAddressPresentation;
+    private String mCallerDisplayName;
+    private int mCallerDisplayNamePresentation;
+    private RemoteConference mConference;
+
+    /**
+     * @hide
+     */
+    RemoteConnection(
+            String id,
+            IConnectionService connectionService,
+            ConnectionRequest request) {
+        mConnectionId = id;
+        mConnectionService = connectionService;
+        mConnected = true;
+        mState = Connection.STATE_INITIALIZING;
+    }
+
+    /**
+     * Create a RemoteConnection which is used for failed connections. Note that using it for any
+     * "real" purpose will almost certainly fail. Callers should note the failure and act
+     * accordingly (moving on to another RemoteConnection, for example)
+     *
+     * @param disconnectCause The reason for the failed connection.
+     * @hide
+     */
+    RemoteConnection(DisconnectCause disconnectCause) {
+        this("NULL", null, null);
+        mConnected = false;
+        mState = Connection.STATE_DISCONNECTED;
+        mDisconnectCause = disconnectCause;
+    }
+
+    /**
+     * Adds a callback to this {@code RemoteConnection}.
+     *
+     * @param callback A {@code Callback}.
+     */
+    public void registerCallback(Callback callback) {
+        mCallbacks.add(callback);
+    }
+
+    /**
+     * Removes a callback from this {@code RemoteConnection}.
+     *
+     * @param callback A {@code Callback}.
+     */
+    public void unregisterCallback(Callback callback) {
+        if (callback != null) {
+            mCallbacks.remove(callback);
+        }
+    }
+
+    /**
+     * Obtains the state of this {@code RemoteConnection}.
+     *
+     * @return A state value, chosen from the {@code STATE_*} constants.
+     */
+    public int getState() {
+        return mState;
+    }
+
+    /**
+     * @return For a {@link Connection#STATE_DISCONNECTED} {@code RemoteConnection}, the
+     * disconnect cause expressed as a code chosen from among those declared in
+     * {@link DisconnectCause}.
+     */
+    public DisconnectCause getDisconnectCause() {
+        return mDisconnectCause;
+    }
+
+    /**
+     * @return A bitmask of the capabilities of the {@code RemoteConnection}, as defined in
+     *         {@link PhoneCapabilities}.
+     */
+    public int getCallCapabilities() {
+        return mCallCapabilities;
+    }
+
+    /**
+     * @return {@code true} if the {@code RemoteConnection}'s current audio mode is VOIP.
+     */
+    public boolean isVoipAudioMode() {
+        return mIsVoipAudioMode;
+    }
+
+    /**
+     * @return The current {@link StatusHints} of this {@code RemoteConnection},
+     * or {@code null} if none have been set.
+     */
+    public StatusHints getStatusHints() {
+        return mStatusHints;
+    }
+
+    /**
+     * @return The address (e.g., phone number) to which the {@code RemoteConnection} is currently
+     * connected.
+     */
+    public Uri getAddress() {
+        return mAddress;
+    }
+
+    /**
+     * @return The presentation requirements for the address. See {@link TelecomManager} for valid
+     * values.
+     */
+    public int getAddressPresentation() {
+        return mAddressPresentation;
+    }
+
+    /**
+     * @return The display name for the caller.
+     */
+    public CharSequence getCallerDisplayName() {
+        return mCallerDisplayName;
+    }
+
+    /**
+     * @return The presentation requirements for the caller display name. See
+     * {@link TelecomManager} for valid values.
+     */
+    public int getCallerDisplayNamePresentation() {
+        return mCallerDisplayNamePresentation;
+    }
+
+    /**
+     * @return The video state of the {@code RemoteConnection}. See
+     * {@link VideoProfile.VideoState}.
+     * @hide
+     */
+    public int getVideoState() {
+        return mVideoState;
+    }
+
+    /**
+     * @return The video provider associated with this {@code RemoteConnection}.
+     * @hide
+     */
+    public final VideoProvider getVideoProvider() {
+        return mVideoProvider;
+    }
+
+    /**
+     * @return Whether the {@code RemoteConnection} is requesting that the framework play a
+     * ringback tone on its behalf.
+     */
+    public boolean isRingbackRequested() {
+        return false;
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to abort.
+     */
+    public void abort() {
+        try {
+            if (mConnected) {
+                mConnectionService.abort(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@link Connection#STATE_RINGING} {@code RemoteConnection} to answer.
+     */
+    public void answer() {
+        try {
+            if (mConnected) {
+                mConnectionService.answer(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@link Connection#STATE_RINGING} {@code RemoteConnection} to answer.
+     * @param videoState The video state in which to answer the call.
+     * @hide
+     */
+    public void answer(int videoState) {
+        try {
+            if (mConnected) {
+                mConnectionService.answerVideo(mConnectionId, videoState);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@link Connection#STATE_RINGING} {@code RemoteConnection} to reject.
+     */
+    public void reject() {
+        try {
+            if (mConnected) {
+                mConnectionService.reject(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to go on hold.
+     */
+    public void hold() {
+        try {
+            if (mConnected) {
+                mConnectionService.hold(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@link Connection#STATE_HOLDING} call to release from hold.
+     */
+    public void unhold() {
+        try {
+            if (mConnected) {
+                mConnectionService.unhold(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to disconnect.
+     */
+    public void disconnect() {
+        try {
+            if (mConnected) {
+                mConnectionService.disconnect(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to play a dual-tone multi-frequency signaling
+     * (DTMF) tone.
+     *
+     * Any other currently playing DTMF tone in the specified call is immediately stopped.
+     *
+     * @param digit A character representing the DTMF digit for which to play the tone. This
+     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
+     */
+    public void playDtmfTone(char digit) {
+        try {
+            if (mConnected) {
+                mConnectionService.playDtmfTone(mConnectionId, digit);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to stop any dual-tone multi-frequency signaling
+     * (DTMF) tone currently playing.
+     *
+     * DTMF tones are played by calling {@link #playDtmfTone(char)}. If no DTMF tone is
+     * currently playing, this method will do nothing.
+     */
+    public void stopDtmfTone() {
+        try {
+            if (mConnected) {
+                mConnectionService.stopDtmfTone(mConnectionId);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Instructs this {@code RemoteConnection} to continue playing a post-dial DTMF string.
+     *
+     * A post-dial DTMF string is a string of digits following the first instance of either
+     * {@link TelecomManager#DTMF_CHARACTER_WAIT} or {@link TelecomManager#DTMF_CHARACTER_PAUSE}.
+     * These digits are immediately sent as DTMF tones to the recipient as soon as the
+     * connection is made.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_PAUSE} symbol, this
+     * {@code RemoteConnection} will temporarily pause playing the tones for a pre-defined period
+     * of time.
+     *
+     * If the DTMF string contains a {@link TelecomManager#DTMF_CHARACTER_WAIT} symbol, this
+     * {@code RemoteConnection} will pause playing the tones and notify callbackss via
+     * {@link Callback#onPostDialWait(RemoteConnection, String)}. At this point, the in-call app
+     * should display to the user an indication of this state and an affordance to continue
+     * the postdial sequence. When the user decides to continue the postdial sequence, the in-call
+     * app should invoke the {@link #postDialContinue(boolean)} method.
+     *
+     * @param proceed Whether or not to continue with the post-dial sequence.
+     */
+    public void postDialContinue(boolean proceed) {
+        try {
+            if (mConnected) {
+                mConnectionService.onPostDialContinue(mConnectionId, proceed);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Set the audio state of this {@code RemoteConnection}.
+     *
+     * @param state The audio state of this {@code RemoteConnection}.
+     */
+    public void setAudioState(AudioState state) {
+        try {
+            if (mConnected) {
+                mConnectionService.onAudioStateChanged(mConnectionId, state);
+            }
+        } catch (RemoteException ignored) {
+        }
+    }
+
+    /**
+     * Obtain the {@code RemoteConnection}s with which this {@code RemoteConnection} may be
+     * successfully asked to create a conference with.
+     *
+     * @return The {@code RemoteConnection}s with which this {@code RemoteConnection} may be
+     *         merged into a {@link RemoteConference}.
+     */
+    public List<RemoteConnection> getConferenceableConnections() {
+        return mUnmodifiableconferenceableConnections;
+    }
+
+    /**
+     * Obtain the {@code RemoteConference} that this {@code RemoteConnection} may be a part
+     * of, or {@code null} if there is no such {@code RemoteConference}.
+     *
+     * @return A {@code RemoteConference} or {@code null};
+     */
+    public RemoteConference getConference() {
+        return mConference;
+    }
+
+    /** {@hide} */
+    String getId() {
+        return mConnectionId;
+    }
+
+    /** {@hide} */
+    IConnectionService getConnectionService() {
+        return mConnectionService;
+    }
+
+    /**
+     * @hide
+     */
+    void setState(int state) {
+        if (mState != state) {
+            mState = state;
+            for (Callback c: mCallbacks) {
+                c.onStateChanged(this, state);
+            }
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setDisconnected(DisconnectCause disconnectCause) {
+        if (mState != Connection.STATE_DISCONNECTED) {
+            mState = Connection.STATE_DISCONNECTED;
+            mDisconnectCause = disconnectCause;
+
+            for (Callback c : mCallbacks) {
+                c.onDisconnected(this, mDisconnectCause);
+            }
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setRingbackRequested(boolean ringback) {
+        if (mRingbackRequested != ringback) {
+            mRingbackRequested = ringback;
+            for (Callback c : mCallbacks) {
+                c.onRingbackRequested(this, ringback);
+            }
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setCallCapabilities(int callCapabilities) {
+        mCallCapabilities = callCapabilities;
+        for (Callback c : mCallbacks) {
+            c.onCallCapabilitiesChanged(this, callCapabilities);
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setDestroyed() {
+        if (!mCallbacks.isEmpty()) {
+            // Make sure that the callbacks are notified that the call is destroyed first.
+            if (mState != Connection.STATE_DISCONNECTED) {
+                setDisconnected(
+                        new DisconnectCause(DisconnectCause.ERROR, "Connection destroyed."));
+            }
+
+            for (Callback c : mCallbacks) {
+                c.onDestroyed(this);
+            }
+            mCallbacks.clear();
+
+            mConnected = false;
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setPostDialWait(String remainingDigits) {
+        for (Callback c : mCallbacks) {
+            c.onPostDialWait(this, remainingDigits);
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setVideoState(int videoState) {
+        mVideoState = videoState;
+        for (Callback c : mCallbacks) {
+            c.onVideoStateChanged(this, videoState);
+        }
+    }
+
+    /**
+     * @hide
+     */
+    void setVideoProvider(VideoProvider videoProvider) {
+        mVideoProvider = videoProvider;
+        for (Callback c : mCallbacks) {
+            c.onVideoProviderChanged(this, videoProvider);
+        }
+    }
+
+    /** @hide */
+    void setIsVoipAudioMode(boolean isVoip) {
+        mIsVoipAudioMode = isVoip;
+        for (Callback c : mCallbacks) {
+            c.onVoipAudioChanged(this, isVoip);
+        }
+    }
+
+    /** @hide */
+    void setStatusHints(StatusHints statusHints) {
+        mStatusHints = statusHints;
+        for (Callback c : mCallbacks) {
+            c.onStatusHintsChanged(this, statusHints);
+        }
+    }
+
+    /** @hide */
+    void setAddress(Uri address, int presentation) {
+        mAddress = address;
+        mAddressPresentation = presentation;
+        for (Callback c : mCallbacks) {
+            c.onAddressChanged(this, address, presentation);
+        }
+    }
+
+    /** @hide */
+    void setCallerDisplayName(String callerDisplayName, int presentation) {
+        mCallerDisplayName = callerDisplayName;
+        mCallerDisplayNamePresentation = presentation;
+        for (Callback c : mCallbacks) {
+            c.onCallerDisplayNameChanged(this, callerDisplayName, presentation);
+        }
+    }
+
+    /** @hide */
+    void setConferenceableConnections(List<RemoteConnection> conferenceableConnections) {
+        mConferenceableConnections.clear();
+        mConferenceableConnections.addAll(conferenceableConnections);
+        for (Callback c : mCallbacks) {
+            c.onConferenceableConnectionsChanged(this, mUnmodifiableconferenceableConnections);
+        }
+    }
+
+    /** @hide */
+    void setConference(RemoteConference conference) {
+        if (mConference != conference) {
+            mConference = conference;
+            for (Callback c : mCallbacks) {
+                c.onConferenceChanged(this, conference);
+            }
+        }
+    }
+
+    /**
+     * Create a RemoteConnection represents a failure, and which will be in
+     * {@link Connection#STATE_DISCONNECTED}. Attempting to use it for anything will almost
+     * certainly result in bad things happening. Do not do this.
+     *
+     * @return a failed {@link RemoteConnection}
+     *
+     * @hide
+     */
+    public static RemoteConnection failure(DisconnectCause disconnectCause) {
+        return new RemoteConnection(disconnectCause);
+    }
+}
diff --git a/telecomm/java/android/telecom/RemoteConnectionManager.java b/telecomm/java/android/telecom/RemoteConnectionManager.java
new file mode 100644
index 0000000..0366509
--- /dev/null
+++ b/telecomm/java/android/telecom/RemoteConnectionManager.java
@@ -0,0 +1,88 @@
+/*
+ * Copyright (C) 2014 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
+ R* limitations under the License.
+ */
+
+package android.telecom;
+
+import android.content.ComponentName;
+import android.os.RemoteException;
+
+import com.android.internal.telecom.IConnectionService;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * @hide
+ */
+public class RemoteConnectionManager {
+    private final Map<ComponentName, RemoteConnectionService> mRemoteConnectionServices =
+            new HashMap<>();
+    private final ConnectionService mOurConnectionServiceImpl;
+
+    public RemoteConnectionManager(ConnectionService ourConnectionServiceImpl) {
+        mOurConnectionServiceImpl = ourConnectionServiceImpl;
+    }
+
+    void addConnectionService(
+            ComponentName componentName,
+            IConnectionService outgoingConnectionServiceRpc) {
+        if (!mRemoteConnectionServices.containsKey(componentName)) {
+            try {
+                RemoteConnectionService remoteConnectionService = new RemoteConnectionService(
+                        outgoingConnectionServiceRpc,
+                        mOurConnectionServiceImpl);
+                mRemoteConnectionServices.put(componentName, remoteConnectionService);
+            } catch (RemoteException ignored) {
+            }
+        }
+    }
+
+    public RemoteConnection createRemoteConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request,
+            boolean isIncoming) {
+        PhoneAccountHandle accountHandle = request.getAccountHandle();
+        if (accountHandle == null) {
+            throw new IllegalArgumentException("accountHandle must be specified.");
+        }
+
+        ComponentName componentName = request.getAccountHandle().getComponentName();
+        if (!mRemoteConnectionServices.containsKey(componentName)) {
+            throw new UnsupportedOperationException("accountHandle not supported: "
+                    + componentName);
+        }
+
+        RemoteConnectionService remoteService = mRemoteConnectionServices.get(componentName);
+        if (remoteService != null) {
+            return remoteService.createRemoteConnection(
+                    connectionManagerPhoneAccount, request, isIncoming);
+        }
+        return null;
+    }
+
+    public void conferenceRemoteConnections(RemoteConnection a, RemoteConnection b) {
+        if (a.getConnectionService() == b.getConnectionService()) {
+            try {
+                a.getConnectionService().conference(a.getId(), b.getId());
+            } catch (RemoteException e) {
+            }
+        } else {
+            Log.w(this, "Request to conference incompatible remote connections (%s,%s) (%s,%s)",
+                    a.getConnectionService(), a.getId(),
+                    b.getConnectionService(), b.getId());
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/RemoteConnectionService.java b/telecomm/java/android/telecom/RemoteConnectionService.java
new file mode 100644
index 0000000..03b38c2
--- /dev/null
+++ b/telecomm/java/android/telecom/RemoteConnectionService.java
@@ -0,0 +1,383 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.net.Uri;
+import android.os.IBinder;
+import android.os.IBinder.DeathRecipient;
+import android.os.RemoteException;
+
+import com.android.internal.telecom.IConnectionService;
+import com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.IVideoProvider;
+import com.android.internal.telecom.RemoteServiceCallback;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+import java.util.List;
+import java.util.UUID;
+
+/**
+ * Remote connection service which other connection services can use to place calls on their behalf.
+ *
+ * @hide
+ */
+final class RemoteConnectionService {
+
+    private static final RemoteConnection NULL_CONNECTION =
+            new RemoteConnection("NULL", null, null);
+
+    private static final RemoteConference NULL_CONFERENCE =
+            new RemoteConference("NULL", null);
+
+    private final IConnectionServiceAdapter mServantDelegate = new IConnectionServiceAdapter() {
+        @Override
+        public void handleCreateConnectionComplete(
+                String id,
+                ConnectionRequest request,
+                ParcelableConnection parcel) {
+            RemoteConnection connection =
+                    findConnectionForAction(id, "handleCreateConnectionSuccessful");
+            if (connection != NULL_CONNECTION && mPendingConnections.contains(connection)) {
+                mPendingConnections.remove(connection);
+                // Unconditionally initialize the connection ...
+                connection.setCallCapabilities(parcel.getCapabilities());
+                connection.setAddress(
+                        parcel.getHandle(), parcel.getHandlePresentation());
+                connection.setCallerDisplayName(
+                        parcel.getCallerDisplayName(),
+                        parcel.getCallerDisplayNamePresentation());
+                // Set state after handle so that the client can identify the connection.
+                connection.setState(parcel.getState());
+                List<RemoteConnection> conferenceable = new ArrayList<>();
+                for (String confId : parcel.getConferenceableConnectionIds()) {
+                    if (mConnectionById.containsKey(confId)) {
+                        conferenceable.add(mConnectionById.get(confId));
+                    }
+                }
+                connection.setConferenceableConnections(conferenceable);
+                connection.setVideoState(parcel.getVideoState());
+                if (connection.getState() == Connection.STATE_DISCONNECTED) {
+                    // ... then, if it was created in a disconnected state, that indicates
+                    // failure on the providing end, so immediately mark it destroyed
+                    connection.setDestroyed();
+                }
+            }
+        }
+
+        @Override
+        public void setActive(String callId) {
+            if (mConnectionById.containsKey(callId)) {
+                findConnectionForAction(callId, "setActive")
+                        .setState(Connection.STATE_ACTIVE);
+            } else {
+                findConferenceForAction(callId, "setActive")
+                        .setState(Connection.STATE_ACTIVE);
+            }
+        }
+
+        @Override
+        public void setRinging(String callId) {
+            findConnectionForAction(callId, "setRinging")
+                    .setState(Connection.STATE_RINGING);
+        }
+
+        @Override
+        public void setDialing(String callId) {
+            findConnectionForAction(callId, "setDialing")
+                    .setState(Connection.STATE_DIALING);
+        }
+
+        @Override
+        public void setDisconnected(String callId, DisconnectCause disconnectCause) {
+            if (mConnectionById.containsKey(callId)) {
+                findConnectionForAction(callId, "setDisconnected")
+                        .setDisconnected(disconnectCause);
+            } else {
+                findConferenceForAction(callId, "setDisconnected")
+                        .setDisconnected(disconnectCause);
+            }
+        }
+
+        @Override
+        public void setOnHold(String callId) {
+            if (mConnectionById.containsKey(callId)) {
+                findConnectionForAction(callId, "setOnHold")
+                        .setState(Connection.STATE_HOLDING);
+            } else {
+                findConferenceForAction(callId, "setOnHold")
+                        .setState(Connection.STATE_HOLDING);
+            }
+        }
+
+        @Override
+        public void setRingbackRequested(String callId, boolean ringing) {
+            findConnectionForAction(callId, "setRingbackRequested")
+                    .setRingbackRequested(ringing);
+        }
+
+        @Override
+        public void setCallCapabilities(String callId, int callCapabilities) {
+            if (mConnectionById.containsKey(callId)) {
+                findConnectionForAction(callId, "setCallCapabilities")
+                        .setCallCapabilities(callCapabilities);
+            } else {
+                findConferenceForAction(callId, "setCallCapabilities")
+                        .setCallCapabilities(callCapabilities);
+            }
+        }
+
+        @Override
+        public void setIsConferenced(String callId, String conferenceCallId) {
+            // Note: callId should not be null; conferenceCallId may be null
+            RemoteConnection connection =
+                    findConnectionForAction(callId, "setIsConferenced");
+            if (connection != NULL_CONNECTION) {
+                if (conferenceCallId == null) {
+                    // 'connection' is being split from its conference
+                    if (connection.getConference() != null) {
+                        connection.getConference().removeConnection(connection);
+                    }
+                } else {
+                    RemoteConference conference =
+                            findConferenceForAction(conferenceCallId, "setIsConferenced");
+                    if (conference != NULL_CONFERENCE) {
+                        conference.addConnection(connection);
+                    }
+                }
+            }
+        }
+
+        @Override
+        public void addConferenceCall(
+                final String callId,
+                ParcelableConference parcel) {
+            RemoteConference conference = new RemoteConference(callId,
+                    mOutgoingConnectionServiceRpc);
+
+            for (String id : parcel.getConnectionIds()) {
+                RemoteConnection c = mConnectionById.get(id);
+                if (c != null) {
+                    conference.addConnection(c);
+                }
+            }
+
+            if (conference.getConnections().size() == 0) {
+                // A conference was created, but none of its connections are ones that have been
+                // created by, and therefore being tracked by, this remote connection service. It
+                // is of no interest to us.
+                return;
+            }
+
+            conference.setState(parcel.getState());
+            conference.setCallCapabilities(parcel.getCapabilities());
+            mConferenceById.put(callId, conference);
+            conference.registerCallback(new RemoteConference.Callback() {
+                @Override
+                public void onDestroyed(RemoteConference c) {
+                    mConferenceById.remove(callId);
+                    maybeDisconnectAdapter();
+                }
+            });
+
+            mOurConnectionServiceImpl.addRemoteConference(conference);
+        }
+
+        @Override
+        public void removeCall(String callId) {
+            if (mConnectionById.containsKey(callId)) {
+                findConnectionForAction(callId, "removeCall")
+                        .setDestroyed();
+            } else {
+                findConferenceForAction(callId, "removeCall")
+                        .setDestroyed();
+            }
+        }
+
+        @Override
+        public void onPostDialWait(String callId, String remaining) {
+            findConnectionForAction(callId, "onPostDialWait")
+                    .setPostDialWait(remaining);
+        }
+
+        @Override
+        public void queryRemoteConnectionServices(RemoteServiceCallback callback) {
+            // Not supported from remote connection service.
+        }
+
+        @Override
+        public void setVideoProvider(String callId, IVideoProvider videoProvider) {
+            findConnectionForAction(callId, "setVideoProvider")
+                    .setVideoProvider(new RemoteConnection.VideoProvider(videoProvider));
+        }
+
+        @Override
+        public void setVideoState(String callId, int videoState) {
+            findConnectionForAction(callId, "setVideoState")
+                    .setVideoState(videoState);
+        }
+
+        @Override
+        public void setIsVoipAudioMode(String callId, boolean isVoip) {
+            findConnectionForAction(callId, "setIsVoipAudioMode")
+                    .setIsVoipAudioMode(isVoip);
+        }
+
+        @Override
+        public void setStatusHints(String callId, StatusHints statusHints) {
+            findConnectionForAction(callId, "setStatusHints")
+                    .setStatusHints(statusHints);
+        }
+
+        @Override
+        public void setAddress(String callId, Uri address, int presentation) {
+            findConnectionForAction(callId, "setAddress")
+                    .setAddress(address, presentation);
+        }
+
+        @Override
+        public void setCallerDisplayName(String callId, String callerDisplayName,
+                int presentation) {
+            findConnectionForAction(callId, "setCallerDisplayName")
+                    .setCallerDisplayName(callerDisplayName, presentation);
+        }
+
+        @Override
+        public IBinder asBinder() {
+            throw new UnsupportedOperationException();
+        }
+
+        @Override
+        public final void setConferenceableConnections(
+                String callId, List<String> conferenceableConnectionIds) {
+            List<RemoteConnection> conferenceable = new ArrayList<>();
+            for (String id : conferenceableConnectionIds) {
+                if (mConnectionById.containsKey(id)) {
+                    conferenceable.add(mConnectionById.get(id));
+                }
+            }
+
+            findConnectionForAction(callId, "setConferenceableConnections")
+                    .setConferenceableConnections(conferenceable);
+        }
+    };
+
+    private final ConnectionServiceAdapterServant mServant =
+            new ConnectionServiceAdapterServant(mServantDelegate);
+
+    private final DeathRecipient mDeathRecipient = new DeathRecipient() {
+        @Override
+        public void binderDied() {
+            for (RemoteConnection c : mConnectionById.values()) {
+                c.setDestroyed();
+            }
+            for (RemoteConference c : mConferenceById.values()) {
+                c.setDestroyed();
+            }
+            mConnectionById.clear();
+            mConferenceById.clear();
+            mPendingConnections.clear();
+            mOutgoingConnectionServiceRpc.asBinder().unlinkToDeath(mDeathRecipient, 0);
+        }
+    };
+
+    private final IConnectionService mOutgoingConnectionServiceRpc;
+    private final ConnectionService mOurConnectionServiceImpl;
+    private final Map<String, RemoteConnection> mConnectionById = new HashMap<>();
+    private final Map<String, RemoteConference> mConferenceById = new HashMap<>();
+    private final Set<RemoteConnection> mPendingConnections = new HashSet<>();
+
+    RemoteConnectionService(
+            IConnectionService outgoingConnectionServiceRpc,
+            ConnectionService ourConnectionServiceImpl) throws RemoteException {
+        mOutgoingConnectionServiceRpc = outgoingConnectionServiceRpc;
+        mOutgoingConnectionServiceRpc.asBinder().linkToDeath(mDeathRecipient, 0);
+        mOurConnectionServiceImpl = ourConnectionServiceImpl;
+    }
+
+    @Override
+    public String toString() {
+        return "[RemoteCS - " + mOutgoingConnectionServiceRpc.asBinder().toString() + "]";
+    }
+
+    final RemoteConnection createRemoteConnection(
+            PhoneAccountHandle connectionManagerPhoneAccount,
+            ConnectionRequest request,
+            boolean isIncoming) {
+        final String id = UUID.randomUUID().toString();
+        final ConnectionRequest newRequest = new ConnectionRequest(
+                request.getAccountHandle(),
+                request.getAddress(),
+                request.getExtras(),
+                request.getVideoState());
+        try {
+            if (mConnectionById.isEmpty()) {
+                mOutgoingConnectionServiceRpc.addConnectionServiceAdapter(mServant.getStub());
+            }
+            RemoteConnection connection =
+                    new RemoteConnection(id, mOutgoingConnectionServiceRpc, newRequest);
+            mPendingConnections.add(connection);
+            mConnectionById.put(id, connection);
+            mOutgoingConnectionServiceRpc.createConnection(
+                    connectionManagerPhoneAccount,
+                    id,
+                    newRequest,
+                    isIncoming);
+            connection.registerCallback(new RemoteConnection.Callback() {
+                @Override
+                public void onDestroyed(RemoteConnection connection) {
+                    mConnectionById.remove(id);
+                    maybeDisconnectAdapter();
+                }
+            });
+            return connection;
+        } catch (RemoteException e) {
+            return RemoteConnection.failure(
+                    new DisconnectCause(DisconnectCause.ERROR, e.toString()));
+        }
+    }
+
+    private RemoteConnection findConnectionForAction(
+            String callId, String action) {
+        if (mConnectionById.containsKey(callId)) {
+            return mConnectionById.get(callId);
+        }
+        Log.w(this, "%s - Cannot find Connection %s", action, callId);
+        return NULL_CONNECTION;
+    }
+
+    private RemoteConference findConferenceForAction(
+            String callId, String action) {
+        if (mConferenceById.containsKey(callId)) {
+            return mConferenceById.get(callId);
+        }
+        Log.w(this, "%s - Cannot find Conference %s", action, callId);
+        return NULL_CONFERENCE;
+    }
+
+    private void maybeDisconnectAdapter() {
+        if (mConnectionById.isEmpty() && mConferenceById.isEmpty()) {
+            try {
+                mOutgoingConnectionServiceRpc.removeConnectionServiceAdapter(mServant.getStub());
+            } catch (RemoteException e) {
+            }
+        }
+    }
+}
diff --git a/telecomm/java/android/telecom/Response.java b/telecomm/java/android/telecom/Response.java
new file mode 100644
index 0000000..ce7a761
--- /dev/null
+++ b/telecomm/java/android/telecom/Response.java
@@ -0,0 +1,40 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+/**
+ * @hide
+ */
+public interface Response<IN, OUT> {
+
+    /**
+     * Provide a set of results.
+     *
+     * @param request The original request.
+     * @param result The results.
+     */
+    void onResult(IN request, OUT... result);
+
+    /**
+     * Indicates the inability to provide results.
+     *
+     * @param request The original request.
+     * @param code An integer code indicating the reason for failure.
+     * @param msg A message explaining the reason for failure.
+     */
+    void onError(IN request, int code, String msg);
+}
diff --git a/telecomm/java/android/telecom/StatusHints.aidl b/telecomm/java/android/telecom/StatusHints.aidl
new file mode 100644
index 0000000..ae7df2e
--- /dev/null
+++ b/telecomm/java/android/telecom/StatusHints.aidl
@@ -0,0 +1,22 @@
+/*
+ * Copyright (C) 2008 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 android.telecom;
+
+/**
+ * {@hide}
+  */
+parcelable StatusHints;
diff --git a/telecomm/java/android/telecom/StatusHints.java b/telecomm/java/android/telecom/StatusHints.java
new file mode 100644
index 0000000..a32eae7
--- /dev/null
+++ b/telecomm/java/android/telecom/StatusHints.java
@@ -0,0 +1,150 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.content.ComponentName;
+import android.content.Context;
+import android.content.pm.PackageManager;
+import android.graphics.drawable.Drawable;
+import android.os.Bundle;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+import java.util.MissingResourceException;
+import java.util.Objects;
+
+/**
+ * Contains status label and icon displayed in the in-call UI.
+ */
+public final class StatusHints implements Parcelable {
+
+    private final ComponentName mPackageName;
+    private final CharSequence mLabel;
+    private final int mIconResId;
+    private final Bundle mExtras;
+
+    public StatusHints(ComponentName packageName, CharSequence label, int iconResId,
+            Bundle extras) {
+        mPackageName = packageName;
+        mLabel = label;
+        mIconResId = iconResId;
+        mExtras = extras;
+    }
+
+    /**
+     * @return A package used to load the icon.
+     */
+    public ComponentName getPackageName() {
+        return mPackageName;
+    }
+
+    /**
+     * @return The label displayed in the in-call UI.
+     */
+    public CharSequence getLabel() {
+        return mLabel;
+    }
+
+    /**
+     * The icon resource ID for the icon to show.
+     *
+     * @return A resource ID.
+     */
+    public int getIconResId() {
+        return mIconResId;
+    }
+
+    /**
+     * @return An icon displayed in the in-call UI.
+     */
+    public Drawable getIcon(Context context) {
+        return getIcon(context, mIconResId);
+    }
+
+    /**
+     * @return Extra data used to display status.
+     */
+    public Bundle getExtras() {
+        return mExtras;
+    }
+
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    @Override
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeParcelable(mPackageName, flags);
+        out.writeCharSequence(mLabel);
+        out.writeInt(mIconResId);
+        out.writeParcelable(mExtras, 0);
+    }
+
+    public static final Creator<StatusHints> CREATOR
+            = new Creator<StatusHints>() {
+        public StatusHints createFromParcel(Parcel in) {
+            return new StatusHints(in);
+        }
+
+        public StatusHints[] newArray(int size) {
+            return new StatusHints[size];
+        }
+    };
+
+    private StatusHints(Parcel in) {
+        mPackageName = in.readParcelable(getClass().getClassLoader());
+        mLabel = in.readCharSequence();
+        mIconResId = in.readInt();
+        mExtras = in.readParcelable(getClass().getClassLoader());
+    }
+
+    private Drawable getIcon(Context context, int resId) {
+        Context packageContext;
+        try {
+            packageContext = context.createPackageContext(mPackageName.getPackageName(), 0);
+        } catch (PackageManager.NameNotFoundException e) {
+            Log.e(this, e, "Cannot find package %s", mPackageName.getPackageName());
+            return null;
+        }
+        try {
+            return packageContext.getDrawable(resId);
+        } catch (MissingResourceException e) {
+            Log.e(this, e, "Cannot find icon %d in package %s",
+                    resId, mPackageName.getPackageName());
+            return null;
+        }
+    }
+
+    @Override
+    public boolean equals(Object other) {
+        if (other != null && other instanceof StatusHints) {
+            StatusHints otherHints = (StatusHints) other;
+            return Objects.equals(otherHints.getPackageName(), getPackageName()) &&
+                    Objects.equals(otherHints.getLabel(), getLabel()) &&
+                    otherHints.getIconResId() == getIconResId() &&
+                    Objects.equals(otherHints.getExtras(), getExtras());
+        }
+        return false;
+    }
+
+    @Override
+    public int hashCode() {
+        return Objects.hashCode(mPackageName) + Objects.hashCode(mLabel) + mIconResId +
+                Objects.hashCode(mExtras);
+    }
+}
diff --git a/telecomm/java/android/telecom/TelecomManager.java b/telecomm/java/android/telecom/TelecomManager.java
new file mode 100644
index 0000000..481e483
--- /dev/null
+++ b/telecomm/java/android/telecom/TelecomManager.java
@@ -0,0 +1,873 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.annotation.SystemApi;
+import android.content.ComponentName;
+import android.content.Context;
+import android.os.Bundle;
+import android.os.RemoteException;
+import android.os.ServiceManager;
+import android.telephony.TelephonyManager;
+import android.util.Log;
+
+import com.android.internal.telecom.ITelecomService;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+/**
+ * Provides access to Telecom-related functionality.
+ * TODO: Move this all into PhoneManager.
+ */
+public class TelecomManager {
+
+    /**
+     * Activity action: Starts the UI for handing an incoming call. This intent starts the in-call
+     * UI by notifying the Telecom system that an incoming call exists for a specific call service
+     * (see {@link android.telecom.ConnectionService}). Telecom reads the Intent extras to find
+     * and bind to the appropriate {@link android.telecom.ConnectionService} which Telecom will
+     * ultimately use to control and get information about the call.
+     * <p>
+     * Input: get*Extra field {@link #EXTRA_PHONE_ACCOUNT_HANDLE} contains the component name of the
+     * {@link android.telecom.ConnectionService} that Telecom should bind to. Telecom will then
+     * ask the connection service for more information about the call prior to showing any UI.
+     *
+     * @hide
+     */
+    public static final String ACTION_INCOMING_CALL = "android.telecom.action.INCOMING_CALL";
+
+    /**
+     * The {@link android.content.Intent} action used to configure a
+     * {@link android.telecom.ConnectionService}.
+     */
+    public static final String ACTION_CONNECTION_SERVICE_CONFIGURE =
+            "android.telecom.action.CONNECTION_SERVICE_CONFIGURE";
+
+    /**
+     * The {@link android.content.Intent} action used to show the call settings page.
+     */
+    public static final String ACTION_SHOW_CALL_SETTINGS =
+            "android.telecom.action.SHOW_CALL_SETTINGS";
+
+    /**
+     * The {@link android.content.Intent} action used to show the settings page used to configure
+     * {@link PhoneAccount} preferences.
+     */
+    public static final String ACTION_CHANGE_PHONE_ACCOUNTS =
+            "android.telecom.action.CHANGE_PHONE_ACCOUNTS";
+
+    /**
+     * Optional extra for {@link android.content.Intent#ACTION_CALL} containing a boolean that
+     * determines whether the speakerphone should be automatically turned on for an outgoing call.
+     */
+    public static final String EXTRA_START_CALL_WITH_SPEAKERPHONE =
+            "android.telecom.extra.START_CALL_WITH_SPEAKERPHONE";
+
+    /**
+     * Optional extra for {@link android.content.Intent#ACTION_CALL} containing an integer that
+     * determines the desired video state for an outgoing call.
+     * Valid options:
+     * {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#RX_ENABLED},
+     * {@link VideoProfile.VideoState#TX_ENABLED}.
+     * @hide
+     */
+    public static final String EXTRA_START_CALL_WITH_VIDEO_STATE =
+            "android.telecom.extra.START_CALL_WITH_VIDEO_STATE";
+
+    /**
+     * The extra used with an {@link android.content.Intent#ACTION_CALL} and
+     * {@link android.content.Intent#ACTION_DIAL} {@code Intent} to specify a
+     * {@link PhoneAccountHandle} to use when making the call.
+     * <p class="note">
+     * Retrieve with {@link android.content.Intent#getParcelableExtra(String)}.
+     */
+    public static final String EXTRA_PHONE_ACCOUNT_HANDLE =
+            "android.telecom.extra.PHONE_ACCOUNT_HANDLE";
+
+    /**
+     * Optional extra for {@link #ACTION_INCOMING_CALL} containing a {@link Bundle} which contains
+     * metadata about the call. This {@link Bundle} will be returned to the
+     * {@link ConnectionService}.
+     *
+     * @hide
+     */
+    public static final String EXTRA_INCOMING_CALL_EXTRAS =
+            "android.telecom.extra.INCOMING_CALL_EXTRAS";
+
+    /**
+     * Optional extra for {@link android.content.Intent#ACTION_CALL} and
+     * {@link android.content.Intent#ACTION_DIAL} {@code Intent} containing a {@link Bundle}
+     * which contains metadata about the call. This {@link Bundle} will be saved into
+     * {@code Call.Details}.
+     *
+     * @hide
+     */
+    public static final String EXTRA_OUTGOING_CALL_EXTRAS =
+            "android.telecom.extra.OUTGOING_CALL_EXTRAS";
+
+    /**
+     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
+     * containing the disconnect code.
+     */
+    public static final String EXTRA_CALL_DISCONNECT_CAUSE =
+            "android.telecom.extra.CALL_DISCONNECT_CAUSE";
+
+    /**
+     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
+     * containing the disconnect message.
+     */
+    public static final String EXTRA_CALL_DISCONNECT_MESSAGE =
+            "android.telecom.extra.CALL_DISCONNECT_MESSAGE";
+
+    /**
+     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
+     * containing the component name of the associated connection service.
+     */
+    public static final String EXTRA_CONNECTION_SERVICE =
+            "android.telecom.extra.CONNECTION_SERVICE";
+
+    /**
+     * An optional {@link android.content.Intent#ACTION_CALL} intent extra denoting the
+     * package name of the app specifying an alternative gateway for the call.
+     * The value is a string.
+     *
+     * (The following comment corresponds to the all GATEWAY_* extras)
+     * An app which sends the {@link android.content.Intent#ACTION_CALL} intent can specify an
+     * alternative address to dial which is different from the one specified and displayed to
+     * the user. This alternative address is referred to as the gateway address.
+     */
+    public static final String GATEWAY_PROVIDER_PACKAGE =
+            "android.telecom.extra.GATEWAY_PROVIDER_PACKAGE";
+
+    /**
+     * An optional {@link android.content.Intent#ACTION_CALL} intent extra corresponding to the
+     * original address to dial for the call. This is used when an alternative gateway address is
+     * provided to recall the original address.
+     * The value is a {@link android.net.Uri}.
+     *
+     * (See {@link #GATEWAY_PROVIDER_PACKAGE} for details)
+     */
+    public static final String GATEWAY_ORIGINAL_ADDRESS =
+            "android.telecom.extra.GATEWAY_ORIGINAL_ADDRESS";
+
+    /**
+     * The number which the party on the other side of the line will see (and use to return the
+     * call).
+     * <p>
+     * {@link ConnectionService}s which interact with {@link RemoteConnection}s should only populate
+     * this if the {@link android.telephony.TelephonyManager#getLine1Number()} value, as that is the
+     * user's expected caller ID.
+     */
+    public static final String EXTRA_CALL_BACK_NUMBER = "android.telecom.extra.CALL_BACK_NUMBER";
+
+    /**
+     * The dual tone multi-frequency signaling character sent to indicate the dialing system should
+     * pause for a predefined period.
+     */
+    public static final char DTMF_CHARACTER_PAUSE = ',';
+
+    /**
+     * The dual-tone multi-frequency signaling character sent to indicate the dialing system should
+     * wait for user confirmation before proceeding.
+     */
+    public static final char DTMF_CHARACTER_WAIT = ';';
+
+    /**
+     * TTY (teletypewriter) mode is off.
+     *
+     * @hide
+     */
+    public static final int TTY_MODE_OFF = 0;
+
+    /**
+     * TTY (teletypewriter) mode is on. The speaker is off and the microphone is muted. The user
+     * will communicate with the remote party by sending and receiving text messages.
+     *
+     * @hide
+     */
+    public static final int TTY_MODE_FULL = 1;
+
+    /**
+     * TTY (teletypewriter) mode is in hearing carryover mode (HCO). The microphone is muted but the
+     * speaker is on. The user will communicate with the remote party by sending text messages and
+     * hearing an audible reply.
+     *
+     * @hide
+     */
+    public static final int TTY_MODE_HCO = 2;
+
+    /**
+     * TTY (teletypewriter) mode is in voice carryover mode (VCO). The speaker is off but the
+     * microphone is still on. User will communicate with the remote party by speaking and receiving
+     * text message replies.
+     *
+     * @hide
+     */
+    public static final int TTY_MODE_VCO = 3;
+
+    /**
+     * Broadcast intent action indicating that the current TTY mode has changed. An intent extra
+     * provides this state as an int.
+     *
+     * @see #EXTRA_CURRENT_TTY_MODE
+     * @hide
+     */
+    public static final String ACTION_CURRENT_TTY_MODE_CHANGED =
+            "android.telecom.action.CURRENT_TTY_MODE_CHANGED";
+
+    /**
+     * The lookup key for an int that indicates the current TTY mode.
+     * Valid modes are:
+     * - {@link #TTY_MODE_OFF}
+     * - {@link #TTY_MODE_FULL}
+     * - {@link #TTY_MODE_HCO}
+     * - {@link #TTY_MODE_VCO}
+     *
+     * @hide
+     */
+    public static final String EXTRA_CURRENT_TTY_MODE =
+            "android.telecom.intent.extra.CURRENT_TTY_MODE";
+
+    /**
+     * Broadcast intent action indicating that the TTY preferred operating mode has changed. An
+     * intent extra provides the new mode as an int.
+     *
+     * @see #EXTRA_TTY_PREFERRED_MODE
+     * @hide
+     */
+    public static final String ACTION_TTY_PREFERRED_MODE_CHANGED =
+            "android.telecom.action.TTY_PREFERRED_MODE_CHANGED";
+
+    /**
+     * The lookup key for an int that indicates preferred TTY mode. Valid modes are: -
+     * {@link #TTY_MODE_OFF} - {@link #TTY_MODE_FULL} - {@link #TTY_MODE_HCO} -
+     * {@link #TTY_MODE_VCO}
+     *
+     * @hide
+     */
+    public static final String EXTRA_TTY_PREFERRED_MODE =
+            "android.telecom.intent.extra.TTY_PREFERRED";
+
+    /**
+     * The following 4 constants define how properties such as phone numbers and names are
+     * displayed to the user.
+     */
+
+    /** Property is displayed normally. */
+    public static final int PRESENTATION_ALLOWED = 1;
+
+    /** Property was blocked. */
+    public static final int PRESENTATION_RESTRICTED = 2;
+
+    /** Presentation was not specified or is unknown. */
+    public static final int PRESENTATION_UNKNOWN = 3;
+
+    /** Property should be displayed as a pay phone. */
+    public static final int PRESENTATION_PAYPHONE = 4;
+
+    private static final String TAG = "TelecomManager";
+
+    private final Context mContext;
+
+    /**
+     * @hide
+     */
+    public static TelecomManager from(Context context) {
+        return (TelecomManager) context.getSystemService(Context.TELECOM_SERVICE);
+    }
+
+    /**
+     * @hide
+     */
+    public TelecomManager(Context context) {
+        Context appContext = context.getApplicationContext();
+        if (appContext != null) {
+            mContext = appContext;
+        } else {
+            mContext = context;
+        }
+    }
+
+    /**
+     * Return the {@link PhoneAccount} which is the user-chosen default for making outgoing phone
+     * calls with a specified URI scheme.
+     * <p>
+     * Apps must be prepared for this method to return {@code null}, indicating that there currently
+     * exists no user-chosen default {@code PhoneAccount}.
+     * <p>
+     * @param uriScheme The URI scheme.
+     * @return The {@link PhoneAccountHandle} corresponding to the user-chosen default for outgoing
+     * phone calls for a specified URI scheme.
+     *
+     * @hide
+     */
+    public PhoneAccountHandle getDefaultOutgoingPhoneAccount(String uriScheme) {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getDefaultOutgoingPhoneAccount(uriScheme);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getDefaultOutgoingPhoneAccount", e);
+        }
+        return null;
+    }
+
+    /**
+     * Return the {@link PhoneAccount} which is the user-chosen default for making outgoing phone
+     * calls. This {@code PhoneAccount} will always be a member of the list which is returned from
+     * calling {@link #getCallCapablePhoneAccounts()}
+     *
+     * Apps must be prepared for this method to return {@code null}, indicating that there currently
+     * exists no user-chosen default {@code PhoneAccount}.
+     *
+     * @return The user outgoing phone account selected by the user.
+     * @hide
+     */
+    public PhoneAccountHandle getUserSelectedOutgoingPhoneAccount() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getUserSelectedOutgoingPhoneAccount();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getUserSelectedOutgoingPhoneAccount", e);
+        }
+        return null;
+    }
+
+    /**
+     * Sets the default account for making outgoing phone calls.
+     * @hide
+     */
+    public void setUserSelectedOutgoingPhoneAccount(PhoneAccountHandle accountHandle) {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().setUserSelectedOutgoingPhoneAccount(accountHandle);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#setUserSelectedOutgoingPhoneAccount");
+        }
+    }
+
+    /**
+     * Returns the current SIM call manager. Apps must be prepared for this method to return
+     * {@code null}, indicating that there currently exists no user-chosen default
+     * {@code PhoneAccount}.
+     * @return The phone account handle of the current sim call manager.
+     * @hide
+     */
+    public PhoneAccountHandle getSimCallManager() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getSimCallManager();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getSimCallManager");
+        }
+        return null;
+    }
+
+    /**
+     * Sets the SIM call manager to the specified phone account.
+     * @param accountHandle The phone account handle of the account to set as the sim call manager.
+     * @hide
+     */
+    public void setSimCallManager(PhoneAccountHandle accountHandle) {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().setSimCallManager(accountHandle);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#setSimCallManager");
+        }
+    }
+
+    /**
+     * Returns the list of registered SIM call managers.
+     * @return List of registered SIM call managers.
+     * @hide
+     */
+    public List<PhoneAccountHandle> getSimCallManagers() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getSimCallManagers();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getSimCallManagers");
+        }
+        return new ArrayList<>();
+    }
+
+    /**
+     * Returns the current connection manager. Apps must be prepared for this method to return
+     * {@code null}, indicating that there currently exists no user-chosen default
+     * {@code PhoneAccount}.
+     *
+     * @return The phone account handle of the current connection manager.
+     */
+    public PhoneAccountHandle getConnectionManager() {
+        return getSimCallManager();
+    }
+
+    /**
+     * Returns a list of the {@link PhoneAccountHandle}s which can be used to make and receive phone
+     * calls which support the specified URI scheme.
+     * <P>
+     * For example, invoking with {@code "tel"} will find all {@link PhoneAccountHandle}s which
+     * support telephone calls (e.g. URIs such as {@code tel:555-555-1212}).  Invoking with
+     * {@code "sip"} will find all {@link PhoneAccountHandle}s which support SIP calls (e.g. URIs
+     * such as {@code sip:example@sipexample.com}).
+     *
+     * @param uriScheme The URI scheme.
+     * @return A list of {@code PhoneAccountHandle} objects supporting the URI scheme.
+     *
+     * @hide
+     */
+    public List<PhoneAccountHandle> getPhoneAccountsSupportingScheme(String uriScheme) {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getPhoneAccountsSupportingScheme(uriScheme);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getPhoneAccountsSupportingScheme", e);
+        }
+        return new ArrayList<>();
+    }
+
+
+    /**
+     * Return a list of {@link PhoneAccountHandle}s which can be used to make and receive phone
+     * calls.
+     *
+     * @see #EXTRA_PHONE_ACCOUNT_HANDLE
+     * @return A list of {@code PhoneAccountHandle} objects.
+     *
+     * @hide
+     */
+    public List<PhoneAccountHandle> getCallCapablePhoneAccounts() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getCallCapablePhoneAccounts();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getCallCapablePhoneAccounts", e);
+        }
+        return new ArrayList<>();
+    }
+
+    /**
+     * Determine whether the device has more than one account registered that can make and receive
+     * phone calls.
+     *
+     * @return {@code true} if the device has more than one account registered and {@code false}
+     * otherwise.
+     */
+    public boolean hasMultipleCallCapableAccounts() {
+        return getCallCapablePhoneAccounts().size() > 1;
+    }
+
+    /**
+     *  Returns a list of all {@link PhoneAccount}s registered for the calling package.
+     *
+     * @return A list of {@code PhoneAccountHandle} objects.
+     */
+    public List<PhoneAccountHandle> getPhoneAccountsForPackage() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getPhoneAccountsForPackage(mContext.getPackageName());
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getPhoneAccountsForPackage", e);
+        }
+        return null;
+    }
+
+    /**
+     * Return the {@link PhoneAccount} for a specified {@link PhoneAccountHandle}. Object includes
+     * resources which can be used in a user interface.
+     *
+     * @param account The {@link PhoneAccountHandle}.
+     * @return The {@link PhoneAccount} object.
+     */
+    public PhoneAccount getPhoneAccount(PhoneAccountHandle account) {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getPhoneAccount(account);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getPhoneAccount", e);
+        }
+        return null;
+    }
+
+    /**
+     * Returns a count of all {@link PhoneAccount}s.
+     *
+     * @return The count of {@link PhoneAccount}s.
+     * @hide
+     */
+    @SystemApi
+    public int getAllPhoneAccountsCount() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getAllPhoneAccountsCount();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccountsCount", e);
+        }
+        return 0;
+    }
+
+    /**
+     * Returns a list of all {@link PhoneAccount}s.
+     *
+     * @return All {@link PhoneAccount}s.
+     * @hide
+     */
+    @SystemApi
+    public List<PhoneAccount> getAllPhoneAccounts() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getAllPhoneAccounts();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccounts", e);
+        }
+        return Collections.EMPTY_LIST;
+    }
+
+    /**
+     * Returns a list of all {@link PhoneAccountHandle}s.
+     *
+     * @return All {@link PhoneAccountHandle}s.
+     * @hide
+     */
+    @SystemApi
+    public List<PhoneAccountHandle> getAllPhoneAccountHandles() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getAllPhoneAccountHandles();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccountHandles", e);
+        }
+        return Collections.EMPTY_LIST;
+    }
+
+    /**
+     * Register a {@link PhoneAccount} for use by the system.
+     *
+     * @param account The complete {@link PhoneAccount}.
+     */
+    public void registerPhoneAccount(PhoneAccount account) {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().registerPhoneAccount(account);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#registerPhoneAccount", e);
+        }
+    }
+
+    /**
+     * Remove a {@link PhoneAccount} registration from the system.
+     *
+     * @param accountHandle A {@link PhoneAccountHandle} for the {@link PhoneAccount} to unregister.
+     */
+    public void unregisterPhoneAccount(PhoneAccountHandle accountHandle) {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().unregisterPhoneAccount(accountHandle);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#unregisterPhoneAccount", e);
+        }
+    }
+
+    /**
+     * Remove all Accounts that belong to the calling package from the system.
+     */
+    @SystemApi
+    public void clearAccounts() {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().clearAccounts(mContext.getPackageName());
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#clearAccounts", e);
+        }
+    }
+
+    /**
+     * @hide
+     */
+    @SystemApi
+    public ComponentName getDefaultPhoneApp() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getDefaultPhoneApp();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException attempting to get the default phone app.", e);
+        }
+        return null;
+    }
+
+    /**
+     * Returns whether there is an ongoing phone call (can be in dialing, ringing, active or holding
+     * states).
+     * <p>
+     * Requires permission: {@link android.Manifest.permission#READ_PHONE_STATE}
+     * </p>
+     */
+    @SystemApi
+    public boolean isInCall() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().isInCall();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException calling isInCall().", e);
+        }
+        return false;
+    }
+
+    /**
+     * Returns one of the following constants that represents the current state of Telecom:
+     *
+     * {@link TelephonyManager#CALL_STATE_RINGING}
+     * {@link TelephonyManager#CALL_STATE_OFFHOOK}
+     * {@link TelephonyManager#CALL_STATE_IDLE}
+     * @hide
+     */
+    @SystemApi
+    public int getCallState() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getCallState();
+            }
+        } catch (RemoteException e) {
+            Log.d(TAG, "RemoteException calling getCallState().", e);
+        }
+        return TelephonyManager.CALL_STATE_IDLE;
+    }
+
+    /**
+     * Returns whether there currently exists is a ringing incoming-call.
+     *
+     * @hide
+     */
+    @SystemApi
+    public boolean isRinging() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().isRinging();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException attempting to get ringing state of phone app.", e);
+        }
+        return false;
+    }
+
+    /**
+     * Ends an ongoing call.
+     * TODO: L-release - need to convert all invocations of ITelecomService#endCall to use this
+     * method (clockwork & gearhead).
+     * @hide
+     */
+    @SystemApi
+    public boolean endCall() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().endCall();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#endCall", e);
+        }
+        return false;
+    }
+
+    /**
+     * If there is a ringing incoming call, this method accepts the call on behalf of the user.
+     * TODO: L-release - need to convert all invocation of ITelecmmService#answerRingingCall to use
+     * this method (clockwork & gearhead).
+     *
+     * @hide
+     */
+    @SystemApi
+    public void acceptRingingCall() {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().acceptRingingCall();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#acceptRingingCall", e);
+        }
+    }
+
+    /**
+     * Silences the ringer if a ringing call exists.
+     *
+     * @hide
+     */
+    @SystemApi
+    public void silenceRinger() {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().silenceRinger();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "Error calling ITelecomService#silenceRinger", e);
+        }
+    }
+
+    /**
+     * Returns whether TTY is supported on this device.
+     *
+     * @hide
+     */
+    @SystemApi
+    public boolean isTtySupported() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().isTtySupported();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException attempting to get TTY supported state.", e);
+        }
+        return false;
+    }
+
+    /**
+     * Returns the current TTY mode of the device. For TTY to be on the user must enable it in
+     * settings and have a wired headset plugged in.
+     * Valid modes are:
+     * - {@link TelecomManager#TTY_MODE_OFF}
+     * - {@link TelecomManager#TTY_MODE_FULL}
+     * - {@link TelecomManager#TTY_MODE_HCO}
+     * - {@link TelecomManager#TTY_MODE_VCO}
+     * @hide
+     */
+    public int getCurrentTtyMode() {
+        try {
+            if (isServiceConnected()) {
+                return getTelecomService().getCurrentTtyMode();
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException attempting to get the current TTY mode.", e);
+        }
+        return TTY_MODE_OFF;
+    }
+
+    /**
+     * Registers a new incoming call. A {@link ConnectionService} should invoke this method when it
+     * has an incoming call. The specified {@link PhoneAccountHandle} must have been registered
+     * with {@link #registerPhoneAccount}. Once invoked, this method will cause the system to bind
+     * to the {@link ConnectionService} associated with the {@link PhoneAccountHandle} and request
+     * additional information about the call (See
+     * {@link ConnectionService#onCreateIncomingConnection}) before starting the incoming call UI.
+     *
+     * @param phoneAccount A {@link PhoneAccountHandle} registered with
+     *            {@link #registerPhoneAccount}.
+     * @param extras A bundle that will be passed through to
+     *            {@link ConnectionService#onCreateIncomingConnection}.
+     */
+    public void addNewIncomingCall(PhoneAccountHandle phoneAccount, Bundle extras) {
+        try {
+            if (isServiceConnected()) {
+                getTelecomService().addNewIncomingCall(
+                        phoneAccount, extras == null ? new Bundle() : extras);
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "RemoteException adding a new incoming call: " + phoneAccount, e);
+        }
+    }
+
+    /**
+     * Processes the specified dial string as an MMI code.
+     * MMI codes are any sequence of characters entered into the dialpad that contain a "*" or "#".
+     * Some of these sequences launch special behavior through handled by Telephony.
+     * <p>
+     * Requires that the method-caller be set as the system dialer app.
+     * </p>
+     *
+     * @param dialString The digits to dial.
+     * @return True if the digits were processed as an MMI code, false otherwise.
+     */
+    public boolean handleMmi(String dialString) {
+        ITelecomService service = getTelecomService();
+        if (service != null) {
+            try {
+                return service.handlePinMmi(dialString);
+            } catch (RemoteException e) {
+                Log.e(TAG, "Error calling ITelecomService#handlePinMmi", e);
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Removes the missed-call notification if one is present.
+     * <p>
+     * Requires that the method-caller be set as the system dialer app.
+     * </p>
+     */
+    public void cancelMissedCallsNotification() {
+        ITelecomService service = getTelecomService();
+        if (service != null) {
+            try {
+                service.cancelMissedCallsNotification();
+            } catch (RemoteException e) {
+                Log.e(TAG, "Error calling ITelecomService#cancelMissedCallsNotification", e);
+            }
+        }
+    }
+
+    /**
+     * Brings the in-call screen to the foreground if there is an ongoing call. If there is
+     * currently no ongoing call, then this method does nothing.
+     * <p>
+     * Requires that the method-caller be set as the system dialer app or have the
+     * {@link android.Manifest.permission#READ_PHONE_STATE} permission.
+     * </p>
+     *
+     * @param showDialpad Brings up the in-call dialpad as part of showing the in-call screen.
+     */
+    public void showInCallScreen(boolean showDialpad) {
+        ITelecomService service = getTelecomService();
+        if (service != null) {
+            try {
+                service.showInCallScreen(showDialpad);
+            } catch (RemoteException e) {
+                Log.e(TAG, "Error calling ITelecomService#showCallScreen", e);
+            }
+        }
+    }
+
+    private ITelecomService getTelecomService() {
+        return ITelecomService.Stub.asInterface(ServiceManager.getService(Context.TELECOM_SERVICE));
+    }
+
+    private boolean isServiceConnected() {
+        boolean isConnected = getTelecomService() != null;
+        if (!isConnected) {
+            Log.w(TAG, "Telecom Service not found.");
+        }
+        return isConnected;
+    }
+}
diff --git a/telecomm/java/android/telecom/VideoCallImpl.java b/telecomm/java/android/telecom/VideoCallImpl.java
new file mode 100644
index 0000000..925058e
--- /dev/null
+++ b/telecomm/java/android/telecom/VideoCallImpl.java
@@ -0,0 +1,247 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.Handler;
+import android.os.IBinder;
+import android.os.Looper;
+import android.os.Message;
+import android.os.RemoteException;
+import android.telecom.InCallService.VideoCall;
+import android.view.Surface;
+
+import com.android.internal.os.SomeArgs;
+import com.android.internal.telecom.IVideoCallback;
+import com.android.internal.telecom.IVideoProvider;
+
+/**
+ * Implementation of a Video Call, which allows InCallUi to communicate commands to the underlying
+ * {@link Connection.VideoProvider}, and direct callbacks from the
+ * {@link Connection.VideoProvider} to the appropriate {@link VideoCall.Listener}.
+ *
+ * {@hide}
+ */
+public class VideoCallImpl extends VideoCall {
+    private static final int MSG_RECEIVE_SESSION_MODIFY_REQUEST = 1;
+    private static final int MSG_RECEIVE_SESSION_MODIFY_RESPONSE = 2;
+    private static final int MSG_HANDLE_CALL_SESSION_EVENT = 3;
+    private static final int MSG_CHANGE_PEER_DIMENSIONS = 4;
+    private static final int MSG_CHANGE_CALL_DATA_USAGE = 5;
+    private static final int MSG_CHANGE_CAMERA_CAPABILITIES = 6;
+
+    private final IVideoProvider mVideoProvider;
+    private final VideoCallListenerBinder mBinder;
+    private VideoCall.Listener mVideoCallListener;
+
+    private IBinder.DeathRecipient mDeathRecipient = new IBinder.DeathRecipient() {
+        @Override
+        public void binderDied() {
+            mVideoProvider.asBinder().unlinkToDeath(this, 0);
+        }
+    };
+
+    /**
+     * IVideoCallback stub implementation.
+     */
+    private final class VideoCallListenerBinder extends IVideoCallback.Stub {
+        @Override
+        public void receiveSessionModifyRequest(VideoProfile videoProfile) {
+            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_REQUEST,
+                    videoProfile).sendToTarget();
+        }
+
+        @Override
+        public void receiveSessionModifyResponse(int status, VideoProfile requestProfile,
+                VideoProfile responseProfile) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = status;
+            args.arg2 = requestProfile;
+            args.arg3 = responseProfile;
+            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_RESPONSE, args).sendToTarget();
+        }
+
+        @Override
+        public void handleCallSessionEvent(int event) {
+            mHandler.obtainMessage(MSG_HANDLE_CALL_SESSION_EVENT, event).sendToTarget();
+        }
+
+        @Override
+        public void changePeerDimensions(int width, int height) {
+            SomeArgs args = SomeArgs.obtain();
+            args.arg1 = width;
+            args.arg2 = height;
+            mHandler.obtainMessage(MSG_CHANGE_PEER_DIMENSIONS, args).sendToTarget();
+        }
+
+        @Override
+        public void changeCallDataUsage(int dataUsage) {
+            mHandler.obtainMessage(MSG_CHANGE_CALL_DATA_USAGE, dataUsage).sendToTarget();
+        }
+
+        @Override
+        public void changeCameraCapabilities(CameraCapabilities cameraCapabilities) {
+            mHandler.obtainMessage(MSG_CHANGE_CAMERA_CAPABILITIES,
+                    cameraCapabilities).sendToTarget();
+        }
+    }
+
+    /** Default handler used to consolidate binder method calls onto a single thread. */
+    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
+        @Override
+        public void handleMessage(Message msg) {
+            if (mVideoCallListener == null) {
+                return;
+            }
+
+            SomeArgs args;
+            switch (msg.what) {
+                case MSG_RECEIVE_SESSION_MODIFY_REQUEST:
+                    mVideoCallListener.onSessionModifyRequestReceived((VideoProfile) msg.obj);
+                    break;
+                case MSG_RECEIVE_SESSION_MODIFY_RESPONSE:
+                    args = (SomeArgs) msg.obj;
+                    try {
+                        int status = (int) args.arg1;
+                        VideoProfile requestProfile = (VideoProfile) args.arg2;
+                        VideoProfile responseProfile = (VideoProfile) args.arg3;
+
+                        mVideoCallListener.onSessionModifyResponseReceived(
+                                status, requestProfile, responseProfile);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                case MSG_HANDLE_CALL_SESSION_EVENT:
+                    mVideoCallListener.onCallSessionEvent((int) msg.obj);
+                    break;
+                case MSG_CHANGE_PEER_DIMENSIONS:
+                    args = (SomeArgs) msg.obj;
+                    try {
+                        int width = (int) args.arg1;
+                        int height = (int) args.arg2;
+                        mVideoCallListener.onPeerDimensionsChanged(width, height);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                case MSG_CHANGE_CALL_DATA_USAGE:
+                    mVideoCallListener.onCallDataUsageChanged(msg.arg1);
+                    break;
+                case MSG_CHANGE_CAMERA_CAPABILITIES:
+                    mVideoCallListener.onCameraCapabilitiesChanged(
+                            (CameraCapabilities) msg.obj);
+                    break;
+                default:
+                    break;
+            }
+        }
+    };
+
+    /** {@hide} */
+    VideoCallImpl(IVideoProvider videoProvider) throws RemoteException {
+        mVideoProvider = videoProvider;
+        mVideoProvider.asBinder().linkToDeath(mDeathRecipient, 0);
+
+        mBinder = new VideoCallListenerBinder();
+        mVideoProvider.setVideoCallback(mBinder);
+    }
+
+    /** {@inheritDoc} */
+    public void setVideoCallListener(VideoCall.Listener videoCallListener) {
+        mVideoCallListener = videoCallListener;
+    }
+
+    /** {@inheritDoc} */
+    public void setCamera(String cameraId) {
+        try {
+            mVideoProvider.setCamera(cameraId);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void setPreviewSurface(Surface surface) {
+        try {
+            mVideoProvider.setPreviewSurface(surface);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void setDisplaySurface(Surface surface) {
+        try {
+            mVideoProvider.setDisplaySurface(surface);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void setDeviceOrientation(int rotation) {
+        try {
+            mVideoProvider.setDeviceOrientation(rotation);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void setZoom(float value) {
+        try {
+            mVideoProvider.setZoom(value);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void sendSessionModifyRequest(VideoProfile requestProfile) {
+        try {
+            mVideoProvider.sendSessionModifyRequest(requestProfile);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void sendSessionModifyResponse(VideoProfile responseProfile) {
+        try {
+            mVideoProvider.sendSessionModifyResponse(responseProfile);
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void requestCameraCapabilities() {
+        try {
+            mVideoProvider.requestCameraCapabilities();
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void requestCallDataUsage() {
+        try {
+            mVideoProvider.requestCallDataUsage();
+        } catch (RemoteException e) {
+        }
+    }
+
+    /** {@inheritDoc} */
+    public void setPauseImage(String uri) {
+        try {
+            mVideoProvider.setPauseImage(uri);
+        } catch (RemoteException e) {
+        }
+    }
+}
\ No newline at end of file
diff --git a/telecomm/java/android/telecom/VideoCallbackServant.java b/telecomm/java/android/telecom/VideoCallbackServant.java
new file mode 100644
index 0000000..d0e3f22
--- /dev/null
+++ b/telecomm/java/android/telecom/VideoCallbackServant.java
@@ -0,0 +1,160 @@
+/*
+ * Copyright (C) 2014 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
+ R* limitations under the License.
+ */
+
+package android.telecom;
+
+import com.android.internal.os.SomeArgs;
+import com.android.internal.telecom.IVideoCallback;
+
+import android.os.Handler;
+import android.os.Message;
+import android.os.RemoteException;
+
+/**
+ * A component that provides an RPC servant implementation of {@link IVideoCallback},
+ * posting incoming messages on the main thread on a client-supplied delegate object.
+ *
+ * TODO: Generate this and similar classes using a compiler starting from AIDL interfaces.
+ *
+ * @hide
+ */
+final class VideoCallbackServant {
+    private static final int MSG_RECEIVE_SESSION_MODIFY_REQUEST = 0;
+    private static final int MSG_RECEIVE_SESSION_MODIFY_RESPONSE = 1;
+    private static final int MSG_HANDLE_CALL_SESSION_EVENT = 2;
+    private static final int MSG_CHANGE_PEER_DIMENSIONS = 3;
+    private static final int MSG_CHANGE_CALL_DATA_USAGE = 4;
+    private static final int MSG_CHANGE_CAMERA_CAPABILITIES = 5;
+
+    private final IVideoCallback mDelegate;
+
+    private final Handler mHandler = new Handler() {
+        @Override
+        public void handleMessage(Message msg) {
+            try {
+                internalHandleMessage(msg);
+            } catch (RemoteException e) {
+            }
+        }
+
+        // Internal method defined to centralize handling of RemoteException
+        private void internalHandleMessage(Message msg) throws RemoteException {
+            switch (msg.what) {
+                case MSG_RECEIVE_SESSION_MODIFY_REQUEST: {
+                    mDelegate.receiveSessionModifyRequest((VideoProfile) msg.obj);
+                    break;
+                }
+                case MSG_RECEIVE_SESSION_MODIFY_RESPONSE: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.receiveSessionModifyResponse(
+                                args.argi1,
+                                (VideoProfile) args.arg1,
+                                (VideoProfile) args.arg2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_HANDLE_CALL_SESSION_EVENT: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.handleCallSessionEvent(args.argi1);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_CHANGE_PEER_DIMENSIONS: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.changePeerDimensions(args.argi1, args.argi2);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_CHANGE_CALL_DATA_USAGE: {
+                    SomeArgs args = (SomeArgs) msg.obj;
+                    try {
+                        mDelegate.changeCallDataUsage(args.argi1);
+                    } finally {
+                        args.recycle();
+                    }
+                    break;
+                }
+                case MSG_CHANGE_CAMERA_CAPABILITIES: {
+                    mDelegate.changeCameraCapabilities((CameraCapabilities) msg.obj);
+                    break;
+                }
+            }
+        }
+    };
+
+    private final IVideoCallback mStub = new IVideoCallback.Stub() {
+        @Override
+        public void receiveSessionModifyRequest(VideoProfile videoProfile) throws RemoteException {
+            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_REQUEST, videoProfile).sendToTarget();
+        }
+
+        @Override
+        public void receiveSessionModifyResponse(int status, VideoProfile requestedProfile,
+                VideoProfile responseProfile) throws RemoteException {
+            SomeArgs args = SomeArgs.obtain();
+            args.argi1 = status;
+            args.arg1 = requestedProfile;
+            args.arg2 = responseProfile;
+            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_RESPONSE, args).sendToTarget();
+        }
+
+        @Override
+        public void handleCallSessionEvent(int event) throws RemoteException {
+            SomeArgs args = SomeArgs.obtain();
+            args.argi1 = event;
+            mHandler.obtainMessage(MSG_HANDLE_CALL_SESSION_EVENT, args).sendToTarget();
+        }
+
+        @Override
+        public void changePeerDimensions(int width, int height) throws RemoteException {
+            SomeArgs args = SomeArgs.obtain();
+            args.argi1 = width;
+            args.argi2 = height;
+            mHandler.obtainMessage(MSG_CHANGE_PEER_DIMENSIONS, args).sendToTarget();
+        }
+
+        @Override
+        public void changeCallDataUsage(int dataUsage) throws RemoteException {
+            SomeArgs args = SomeArgs.obtain();
+            args.argi1 = dataUsage;
+            mHandler.obtainMessage(MSG_CHANGE_CALL_DATA_USAGE, args).sendToTarget();
+        }
+
+        @Override
+        public void changeCameraCapabilities(CameraCapabilities cameraCapabilities)
+                throws RemoteException {
+            mHandler.obtainMessage(MSG_CHANGE_CAMERA_CAPABILITIES, cameraCapabilities)
+                    .sendToTarget();
+        }
+    };
+
+    public VideoCallbackServant(IVideoCallback delegate) {
+        mDelegate = delegate;
+    }
+
+    public IVideoCallback getStub() {
+        return mStub;
+    }
+}
diff --git a/telecomm/java/android/telecom/VideoProfile.aidl b/telecomm/java/android/telecom/VideoProfile.aidl
new file mode 100644
index 0000000..091b569
--- /dev/null
+++ b/telecomm/java/android/telecom/VideoProfile.aidl
@@ -0,0 +1,23 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+/**
+ * {@hide}
+ */
+parcelable VideoProfile;
diff --git a/telecomm/java/android/telecom/VideoProfile.java b/telecomm/java/android/telecom/VideoProfile.java
new file mode 100644
index 0000000..f5cb054
--- /dev/null
+++ b/telecomm/java/android/telecom/VideoProfile.java
@@ -0,0 +1,231 @@
+/*
+ * Copyright (C) 2014 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 android.telecom;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Represents attributes of video calls.
+ *
+ * {@hide}
+ */
+public class VideoProfile implements Parcelable {
+    /**
+     * "High" video quality.
+     */
+    public static final int QUALITY_HIGH = 1;
+
+    /**
+     * "Medium" video quality.
+     */
+    public static final int QUALITY_MEDIUM = 2;
+
+    /**
+     * "Low" video quality.
+     */
+    public static final int QUALITY_LOW = 3;
+
+    /**
+     * Use default video quality.
+     */
+    public static final int QUALITY_DEFAULT = 4;
+
+    private final int mVideoState;
+
+    private final int mQuality;
+
+    /**
+     * Creates an instance of the VideoProfile
+     *
+     * @param videoState The video state.
+     */
+    public VideoProfile(int videoState) {
+        this(videoState, QUALITY_DEFAULT);
+    }
+
+    /**
+     * Creates an instance of the VideoProfile
+     *
+     * @param videoState The video state.
+     * @param quality The video quality.
+     */
+    public VideoProfile(int videoState, int quality) {
+        mVideoState = videoState;
+        mQuality = quality;
+    }
+
+    /**
+     * The video state of the call.
+     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
+     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
+     * {@link VideoProfile.VideoState#TX_ENABLED},
+     * {@link VideoProfile.VideoState#RX_ENABLED},
+     * {@link VideoProfile.VideoState#PAUSED}.
+     */
+    public int getVideoState() {
+        return mVideoState;
+    }
+
+    /**
+     * The desired video quality for the call.
+     * Valid values: {@link VideoProfile#QUALITY_HIGH}, {@link VideoProfile#QUALITY_MEDIUM},
+     * {@link VideoProfile#QUALITY_LOW}, {@link VideoProfile#QUALITY_DEFAULT}.
+     */
+    public int getQuality() {
+        return mQuality;
+    }
+
+    /**
+     * Responsible for creating VideoProfile objects from deserialized Parcels.
+     **/
+    public static final Parcelable.Creator<VideoProfile> CREATOR =
+            new Parcelable.Creator<VideoProfile> () {
+                /**
+                 * Creates a MediaProfile instances from a parcel.
+                 *
+                 * @param source The parcel.
+                 * @return The MediaProfile.
+                 */
+                @Override
+                public VideoProfile createFromParcel(Parcel source) {
+                    int state = source.readInt();
+                    int quality = source.readInt();
+
+                    ClassLoader classLoader = VideoProfile.class.getClassLoader();
+                    return new VideoProfile(state, quality);
+                }
+
+                @Override
+                public VideoProfile[] newArray(int size) {
+                    return new VideoProfile[size];
+                }
+            };
+
+    /**
+     * Describe the kinds of special objects contained in this Parcelable's
+     * marshalled representation.
+     *
+     * @return a bitmask indicating the set of special object types marshalled
+     * by the Parcelable.
+     */
+    @Override
+    public int describeContents() {
+        return 0;
+    }
+
+    /**
+     * Flatten this object in to a Parcel.
+     *
+     * @param dest  The Parcel in which the object should be written.
+     * @param flags Additional flags about how the object should be written.
+     *              May be 0 or {@link #PARCELABLE_WRITE_RETURN_VALUE}.
+     */
+    @Override
+    public void writeToParcel(Parcel dest, int flags) {
+        dest.writeInt(mVideoState);
+        dest.writeInt(mQuality);
+    }
+
+    /**
+    * The video state of the call, stored as a bit-field describing whether video transmission and
+    * receipt it enabled, as well as whether the video is currently muted.
+    */
+    public static class VideoState {
+        /**
+         * Call is currently in an audio-only mode with no video transmission or receipt.
+         */
+        public static final int AUDIO_ONLY = 0x0;
+
+        /**
+         * Video transmission is enabled.
+         */
+        public static final int TX_ENABLED = 0x1;
+
+        /**
+         * Video reception is enabled.
+         */
+        public static final int RX_ENABLED = 0x2;
+
+        /**
+         * Video signal is bi-directional.
+         */
+        public static final int BIDIRECTIONAL = TX_ENABLED | RX_ENABLED;
+
+        /**
+         * Video is paused.
+         */
+        public static final int PAUSED = 0x4;
+
+        /**
+         * Whether the video state is audio only.
+         * @param videoState The video state.
+         * @return Returns true if the video state is audio only.
+         */
+        public static boolean isAudioOnly(int videoState) {
+            return !hasState(videoState, TX_ENABLED) && !hasState(videoState, RX_ENABLED);
+        }
+
+        /**
+         * Whether the video transmission is enabled.
+         * @param videoState The video state.
+         * @return Returns true if the video transmission is enabled.
+         */
+        public static boolean isTransmissionEnabled(int videoState) {
+            return hasState(videoState, TX_ENABLED);
+        }
+
+        /**
+         * Whether the video reception is enabled.
+         * @param videoState The video state.
+         * @return Returns true if the video transmission is enabled.
+         */
+        public static boolean isReceptionEnabled(int videoState) {
+            return hasState(videoState, RX_ENABLED);
+        }
+
+        /**
+         * Whether the video signal is bi-directional.
+         * @param videoState
+         * @return Returns true if the video signal is bi-directional.
+         */
+        public static boolean isBidirectional(int videoState) {
+            return hasState(videoState, BIDIRECTIONAL);
+        }
+
+        /**
+         * Whether the video is paused.
+         * @param videoState The video state.
+         * @return Returns true if the video is paused.
+         */
+        public static boolean isPaused(int videoState) {
+            return hasState(videoState, PAUSED);
+        }
+
+        /**
+         * Determines if a specified state is set in a videoState bit-mask.
+         *
+         * @param videoState The video state bit-mask.
+         * @param state The state to check.
+         * @return {@code True} if the state is set.
+         * {@hide}
+         */
+        private static boolean hasState(int videoState, int state) {
+            return (videoState & state) == state;
+        }
+    }
+}
diff --git a/telecomm/java/android/telecomm/AudioState.aidl b/telecomm/java/android/telecomm/AudioState.aidl
deleted file mode 100644
index 03772b6..0000000
--- a/telecomm/java/android/telecomm/AudioState.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable AudioState;
diff --git a/telecomm/java/android/telecomm/AudioState.java b/telecomm/java/android/telecomm/AudioState.java
deleted file mode 100644
index dc28b16..0000000
--- a/telecomm/java/android/telecomm/AudioState.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import java.util.Locale;
-
-/**
- *  Encapsulates all audio states during a call.
- */
-public final class AudioState implements Parcelable {
-    /** Direct the audio stream through the device's earpiece. */
-    public static int ROUTE_EARPIECE      = 0x00000001;
-
-    /** Direct the audio stream through Bluetooth. */
-    public static int ROUTE_BLUETOOTH     = 0x00000002;
-
-    /** Direct the audio stream through a wired headset. */
-    public static int ROUTE_WIRED_HEADSET = 0x00000004;
-
-    /** Direct the audio stream through the device's spakerphone. */
-    public static int ROUTE_SPEAKER       = 0x00000008;
-
-    /**
-     * Direct the audio stream through the device's earpiece or wired headset if one is
-     * connected.
-     */
-    public static int ROUTE_WIRED_OR_EARPIECE = ROUTE_EARPIECE | ROUTE_WIRED_HEADSET;
-
-    /** Bit mask of all possible audio routes. */
-    public static int ROUTE_ALL = ROUTE_EARPIECE | ROUTE_BLUETOOTH | ROUTE_WIRED_HEADSET |
-            ROUTE_SPEAKER;
-
-    /** True if the call is muted, false otherwise. */
-    public final boolean isMuted;
-
-    /** The route to use for the audio stream. */
-    public final int route;
-
-    /** Bit vector of all routes supported by this call. */
-    public final int supportedRouteMask;
-
-    /** @hide */
-    public AudioState(boolean isMuted, int route, int supportedRouteMask) {
-        this.isMuted = isMuted;
-        this.route = route;
-        this.supportedRouteMask = supportedRouteMask;
-    }
-
-    /** @hide */
-    public AudioState(AudioState state) {
-        isMuted = state.isMuted;
-        route = state.route;
-        supportedRouteMask = state.supportedRouteMask;
-    }
-
-    @Override
-    public boolean equals(Object obj) {
-        if (obj == null) {
-            return false;
-        }
-        if (!(obj instanceof AudioState)) {
-            return false;
-        }
-        AudioState state = (AudioState) obj;
-        return isMuted == state.isMuted && route == state.route &&
-                supportedRouteMask == state.supportedRouteMask;
-    }
-
-    @Override
-    public String toString() {
-        return String.format(Locale.US,
-                "[AudioState isMuted: %b, route; %s, supportedRouteMask: %s]",
-                isMuted, audioRouteToString(route), audioRouteToString(supportedRouteMask));
-    }
-
-    /** @hide */
-    public static String audioRouteToString(int route) {
-        if (route == 0 || (route & ~ROUTE_ALL) != 0x0) {
-            return "UNKNOWN";
-        }
-
-        StringBuffer buffer = new StringBuffer();
-        if ((route & ROUTE_EARPIECE) == ROUTE_EARPIECE) {
-            listAppend(buffer, "EARPIECE");
-        }
-        if ((route & ROUTE_BLUETOOTH) == ROUTE_BLUETOOTH) {
-            listAppend(buffer, "BLUETOOTH");
-        }
-        if ((route & ROUTE_WIRED_HEADSET) == ROUTE_WIRED_HEADSET) {
-            listAppend(buffer, "WIRED_HEADSET");
-        }
-        if ((route & ROUTE_SPEAKER) == ROUTE_SPEAKER) {
-            listAppend(buffer, "SPEAKER");
-        }
-
-        return buffer.toString();
-    }
-
-    private static void listAppend(StringBuffer buffer, String str) {
-        if (buffer.length() > 0) {
-            buffer.append(", ");
-        }
-        buffer.append(str);
-    }
-
-    /**
-     * Responsible for creating AudioState objects for deserialized Parcels.
-     */
-    public static final Parcelable.Creator<AudioState> CREATOR =
-            new Parcelable.Creator<AudioState> () {
-
-        @Override
-        public AudioState createFromParcel(Parcel source) {
-            boolean isMuted = source.readByte() == 0 ? false : true;
-            int route = source.readInt();
-            int supportedRouteMask = source.readInt();
-            return new AudioState(isMuted, route, supportedRouteMask);
-        }
-
-        @Override
-        public AudioState[] newArray(int size) {
-            return new AudioState[size];
-        }
-    };
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /**
-     * Writes AudioState object into a serializeable Parcel.
-     */
-    @Override
-    public void writeToParcel(Parcel destination, int flags) {
-        destination.writeByte((byte) (isMuted ? 1 : 0));
-        destination.writeInt(route);
-        destination.writeInt(supportedRouteMask);
-    }
-}
diff --git a/telecomm/java/android/telecomm/Call.java b/telecomm/java/android/telecomm/Call.java
deleted file mode 100644
index 7223574..0000000
--- a/telecomm/java/android/telecomm/Call.java
+++ /dev/null
@@ -1,799 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.Bundle;
-import android.telephony.DisconnectCause;
-
-import java.lang.String;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-import java.util.Objects;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-/**
- * Represents an ongoing phone call that the in-call app should present to the user.
- *
- * {@hide}
- */
-public final class Call {
-    /**
-     * The state of a {@code Call} when newly created.
-     */
-    public static final int STATE_NEW = 0;
-
-    /**
-     * The state of an outgoing {@code Call} when dialing the remote number, but not yet connected.
-     */
-    public static final int STATE_DIALING = 1;
-
-    /**
-     * The state of an incoming {@code Call} when ringing locally, but not yet connected.
-     */
-    public static final int STATE_RINGING = 2;
-
-    /**
-     * The state of a {@code Call} when in a holding state.
-     */
-    public static final int STATE_HOLDING = 3;
-
-    /**
-     * The state of a {@code Call} when actively supporting conversation.
-     */
-    public static final int STATE_ACTIVE = 4;
-
-    /**
-     * The state of a {@code Call} when no further voice or other communication is being
-     * transmitted, the remote side has been or will inevitably be informed that the {@code Call}
-     * is no longer active, and the local data transport has or inevitably will release resources
-     * associated with this {@code Call}.
-     */
-    public static final int STATE_DISCONNECTED = 7;
-
-    /**
-     * The state of an outgoing {@code Call}, but waiting for user input before proceeding.
-     */
-    public static final int STATE_PRE_DIAL_WAIT = 8;
-
-    /**
-     * The initial state of an outgoing {@code Call}.
-     * Common transitions are to {@link #STATE_DIALING} state for a successful call or
-     * {@link #STATE_DISCONNECTED} if it failed.
-     */
-    public static final int STATE_CONNECTING = 9;
-
-    public static class Details {
-        private final Uri mHandle;
-        private final int mHandlePresentation;
-        private final String mCallerDisplayName;
-        private final int mCallerDisplayNamePresentation;
-        private final PhoneAccountHandle mAccountHandle;
-        private final int mCallCapabilities;
-        private final int mDisconnectCauseCode;
-        private final String mDisconnectCauseMessage;
-        private final long mConnectTimeMillis;
-        private final GatewayInfo mGatewayInfo;
-        private final int mVideoState;
-        private final StatusHints mStatusHints;
-        private final Bundle mExtras;
-
-        /**
-         * @return The handle (e.g., phone number) to which the {@code Call} is currently
-         * connected.
-         */
-        public Uri getHandle() {
-            return mHandle;
-        }
-
-        /**
-         * @return The presentation requirements for the handle. See
-         * {@link PropertyPresentation} for valid values.
-         */
-        public int getHandlePresentation() {
-            return mHandlePresentation;
-        }
-
-        /**
-         * @return The display name for the caller.
-         */
-        public String getCallerDisplayName() {
-            return mCallerDisplayName;
-        }
-
-        /**
-         * @return The presentation requirements for the caller display name. See
-         * {@link PropertyPresentation} for valid values.
-         */
-        public int getCallerDisplayNamePresentation() {
-            return mCallerDisplayNamePresentation;
-        }
-
-        /**
-         * @return The {@code PhoneAccountHandle} whereby the {@code Call} is currently being
-         * routed.
-         */
-        public PhoneAccountHandle getAccountHandle() {
-            return mAccountHandle;
-        }
-
-        /**
-         * @return A bitmask of the capabilities of the {@code Call}, as defined in
-         *         {@link PhoneCapabilities}.
-         */
-        public int getCallCapabilities() {
-            return mCallCapabilities;
-        }
-
-        /**
-         * @return For a {@link #STATE_DISCONNECTED} {@code Call}, the disconnect cause expressed
-         * as a code chosen from among those declared in {@link DisconnectCause}.
-         */
-        public int getDisconnectCauseCode() {
-            return mDisconnectCauseCode;
-        }
-
-        /**
-         * @return For a {@link #STATE_DISCONNECTED} {@code Call}, an optional reason for
-         * disconnection expressed as a free text message.
-         */
-        public String getDisconnectCauseMessage() {
-            return mDisconnectCauseMessage;
-        }
-
-        /**
-         * @return The time the {@code Call} has been connected. This information is updated
-         * periodically, but user interfaces should not rely on this to display any "call time
-         * clock".
-         */
-        public long getConnectTimeMillis() {
-            return mConnectTimeMillis;
-        }
-
-        /**
-         * @return Information about any calling gateway the {@code Call} may be using.
-         */
-        public GatewayInfo getGatewayInfo() {
-            return mGatewayInfo;
-        }
-
-        /**
-         * @return The video state of the {@code Call}.
-         */
-        public int getVideoState() {
-            return mVideoState;
-        }
-
-        /**
-         * @return The current {@link android.telecomm.StatusHints}, or {@code null} if none
-         * have been set.
-         */
-        public StatusHints getStatusHints() {
-            return mStatusHints;
-        }
-
-        /**
-         * @return A bundle extras to pass with the call
-         */
-        public Bundle getExtras() {
-            return mExtras;
-        }
-
-        @Override
-        public boolean equals(Object o) {
-            if (o instanceof Details) {
-                Details d = (Details) o;
-                return
-                        Objects.equals(mHandle, d.mHandle) &&
-                        Objects.equals(mHandlePresentation, d.mHandlePresentation) &&
-                        Objects.equals(mCallerDisplayName, d.mCallerDisplayName) &&
-                        Objects.equals(mCallerDisplayNamePresentation,
-                                d.mCallerDisplayNamePresentation) &&
-                        Objects.equals(mAccountHandle, d.mAccountHandle) &&
-                        Objects.equals(mCallCapabilities, d.mCallCapabilities) &&
-                        Objects.equals(mDisconnectCauseCode, d.mDisconnectCauseCode) &&
-                        Objects.equals(mDisconnectCauseMessage, d.mDisconnectCauseMessage) &&
-                        Objects.equals(mConnectTimeMillis, d.mConnectTimeMillis) &&
-                        Objects.equals(mGatewayInfo, d.mGatewayInfo) &&
-                        Objects.equals(mVideoState, d.mVideoState) &&
-                        Objects.equals(mStatusHints, d.mStatusHints) &&
-                        Objects.equals(mExtras, d.mExtras);
-            }
-            return false;
-        }
-
-        @Override
-        public int hashCode() {
-            return
-                    Objects.hashCode(mHandle) +
-                    Objects.hashCode(mHandlePresentation) +
-                    Objects.hashCode(mCallerDisplayName) +
-                    Objects.hashCode(mCallerDisplayNamePresentation) +
-                    Objects.hashCode(mAccountHandle) +
-                    Objects.hashCode(mCallCapabilities) +
-                    Objects.hashCode(mDisconnectCauseCode) +
-                    Objects.hashCode(mDisconnectCauseMessage) +
-                    Objects.hashCode(mConnectTimeMillis) +
-                    Objects.hashCode(mGatewayInfo) +
-                    Objects.hashCode(mVideoState) +
-                    Objects.hashCode(mStatusHints) +
-                    Objects.hashCode(mExtras);
-        }
-
-        /** {@hide} */
-        public Details(
-                Uri handle,
-                int handlePresentation,
-                String callerDisplayName,
-                int callerDisplayNamePresentation,
-                PhoneAccountHandle accountHandle,
-                int capabilities,
-                int disconnectCauseCode,
-                String disconnectCauseMessage,
-                long connectTimeMillis,
-                GatewayInfo gatewayInfo,
-                int videoState,
-                StatusHints statusHints,
-                Bundle extras) {
-            mHandle = handle;
-            mHandlePresentation = handlePresentation;
-            mCallerDisplayName = callerDisplayName;
-            mCallerDisplayNamePresentation = callerDisplayNamePresentation;
-            mAccountHandle = accountHandle;
-            mCallCapabilities = capabilities;
-            mDisconnectCauseCode = disconnectCauseCode;
-            mDisconnectCauseMessage = disconnectCauseMessage;
-            mConnectTimeMillis = connectTimeMillis;
-            mGatewayInfo = gatewayInfo;
-            mVideoState = videoState;
-            mStatusHints = statusHints;
-            mExtras = extras;
-        }
-    }
-
-    public static abstract class Listener {
-        /**
-         * Invoked when the state of this {@code Call} has changed. See {@link #getState()}.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param state The new state of the {@code Call}.
-         */
-        public void onStateChanged(Call call, int state) {}
-
-        /**
-         * Invoked when the parent of this {@code Call} has changed. See {@link #getParent()}.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param parent The new parent of the {@code Call}.
-         */
-        public void onParentChanged(Call call, Call parent) {}
-
-        /**
-         * Invoked when the children of this {@code Call} have changed. See {@link #getChildren()}.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param children The new children of the {@code Call}.
-         */
-        public void onChildrenChanged(Call call, List<Call> children) {}
-
-        /**
-         * Invoked when the details of this {@code Call} have changed. See {@link #getDetails()}.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param details A {@code Details} object describing the {@code Call}.
-         */
-        public void onDetailsChanged(Call call, Details details) {}
-
-        /**
-         * Invoked when the text messages that can be used as responses to the incoming
-         * {@code Call} are loaded from the relevant database.
-         * See {@link #getCannedTextResponses()}.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param cannedTextResponses The text messages useable as responses.
-         */
-        public void onCannedTextResponsesLoaded(Call call, List<String> cannedTextResponses) {}
-
-        /**
-         * Invoked when the post-dial sequence in the outgoing {@code Call} has reached a pause
-         * character. This causes the post-dial signals to stop pending user confirmation. An
-         * implementation should present this choice to the user and invoke
-         * {@link #postDialContinue(boolean)} when the user makes the choice.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param remainingPostDialSequence The post-dial characters that remain to be sent.
-         */
-        public void onPostDialWait(Call call, String remainingPostDialSequence) {}
-
-        /**
-         * Invoked when the {@code Call.VideoCall} of the {@code Call} has changed.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param videoCall The {@code Call.VideoCall} associated with the {@code Call}.
-         */
-        public void onVideoCallChanged(Call call, InCallService.VideoCall videoCall) {}
-
-        /**
-         * Launches an activity for this connection on top of the in-call UI.
-         *
-         * @param call The {@code Call} invoking this method.
-         * @param intent The intent to use to start the activity.
-         */
-        public void onStartActivity(Call call, PendingIntent intent) {}
-
-        /**
-         * Invoked when the {@code Call} is destroyed. Clients should refrain from cleaning
-         * up their UI for the {@code Call} in response to state transitions. Specifically,
-         * clients should not assume that a {@link #onStateChanged(Call, int)} with a state of
-         * {@link #STATE_DISCONNECTED} is the final notification the {@code Call} will send. Rather,
-         * clients should wait for this method to be invoked.
-         *
-         * @param call The {@code Call} being destroyed.
-         */
-        public void onCallDestroyed(Call call) {}
-
-        /**
-         * Invoked upon changes to the set of {@code Call}s with which this {@code Call} can be
-         * conferenced.
-         *
-         * @param call The {@code Call} being updated.
-         * @param conferenceableCalls The {@code Call}s with which this {@code Call} can be
-         *          conferenced.
-         */
-        public void onConferenceableCallsChanged(Call call, List<Call> conferenceableCalls) {}
-    }
-
-    private final Phone mPhone;
-    private final String mTelecommCallId;
-    private final InCallAdapter mInCallAdapter;
-    private final List<Call> mChildren = new ArrayList<>();
-    private final List<Call> mUnmodifiableChildren = Collections.unmodifiableList(mChildren);
-    private final List<Listener> mListeners = new CopyOnWriteArrayList<>();
-    private final List<Call> mConferenceableCalls = new ArrayList<>();
-    private final List<Call> mUnmodifiableConferenceableCalls =
-            Collections.unmodifiableList(mConferenceableCalls);
-
-    private Call mParent = null;
-    private int mState;
-    private List<String> mCannedTextResponses = null;
-    private String mRemainingPostDialSequence;
-    private InCallService.VideoCall mVideoCall;
-    private Details mDetails;
-
-    /**
-     * Obtains the post-dial sequence remaining to be emitted by this {@code Call}, if any.
-     *
-     * @return The remaining post-dial sequence, or {@code null} if there is no post-dial sequence
-     * remaining or this {@code Call} is not in a post-dial state.
-     */
-    public String getRemainingPostDialSequence() {
-        return mRemainingPostDialSequence;
-    }
-
-    /**
-     * Instructs this {@link #STATE_RINGING} {@code Call} to answer.
-     * @param videoState The video state in which to answer the call.
-     */
-    public void answer(int videoState) {
-        mInCallAdapter.answerCall(mTelecommCallId, videoState);
-    }
-
-    /**
-     * Instructs this {@link #STATE_RINGING} {@code Call} to reject.
-     *
-     * @param rejectWithMessage Whether to reject with a text message.
-     * @param textMessage An optional text message with which to respond.
-     */
-    public void reject(boolean rejectWithMessage, String textMessage) {
-        mInCallAdapter.rejectCall(mTelecommCallId, rejectWithMessage, textMessage);
-    }
-
-    /**
-     * Instructs this {@code Call} to disconnect.
-     */
-    public void disconnect() {
-        mInCallAdapter.disconnectCall(mTelecommCallId);
-    }
-
-    /**
-     * Instructs this {@code Call} to go on hold.
-     */
-    public void hold() {
-        mInCallAdapter.holdCall(mTelecommCallId);
-    }
-
-    /**
-     * Instructs this {@link #STATE_HOLDING} call to release from hold.
-     */
-    public void unhold() {
-        mInCallAdapter.unholdCall(mTelecommCallId);
-    }
-
-    /**
-     * Instructs this {@code Call} to play a dual-tone multi-frequency signaling (DTMF) tone.
-     *
-     * Any other currently playing DTMF tone in the specified call is immediately stopped.
-     *
-     * @param digit A character representing the DTMF digit for which to play the tone. This
-     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
-     */
-    public void playDtmfTone(char digit) {
-        mInCallAdapter.playDtmfTone(mTelecommCallId, digit);
-    }
-
-    /**
-     * Instructs this {@code Call} to stop any dual-tone multi-frequency signaling (DTMF) tone
-     * currently playing.
-     *
-     * DTMF tones are played by calling {@link #playDtmfTone(char)}. If no DTMF tone is
-     * currently playing, this method will do nothing.
-     */
-    public void stopDtmfTone() {
-        mInCallAdapter.stopDtmfTone(mTelecommCallId);
-    }
-
-    /**
-     * Instructs this {@code Call} to continue playing a post-dial DTMF string.
-     *
-     * A post-dial DTMF string is a string of digits entered after a phone number, when dialed,
-     * that are immediately sent as DTMF tones to the recipient as soon as the connection is made.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_PAUSE} symbol, this
-     * {@code Call} will temporarily pause playing the tones for a pre-defined period of time.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_WAIT} symbol, this
-     * {@code Call} will pause playing the tones and notify listeners via
-     * {@link Listener#onPostDialWait(Call, String)}. At this point, the in-call app
-     * should display to the user an indication of this state and an affordance to continue
-     * the postdial sequence. When the user decides to continue the postdial sequence, the in-call
-     * app should invoke the {@link #postDialContinue(boolean)} method.
-     *
-     * @param proceed Whether or not to continue with the post-dial sequence.
-     */
-    public void postDialContinue(boolean proceed) {
-        mInCallAdapter.postDialContinue(mTelecommCallId, proceed);
-    }
-
-    /**
-     * Notifies this {@code Call} that the phone account user interface element was touched.
-     */
-    public void phoneAccountClicked() {
-        mInCallAdapter.phoneAccountClicked(mTelecommCallId);
-    }
-
-    /**
-     * Notifies this {@code Call} that an account has been selected and to proceed with placing
-     * an outgoing call.
-     */
-    public void phoneAccountSelected(PhoneAccountHandle accountHandle) {
-        mInCallAdapter.phoneAccountSelected(mTelecommCallId, accountHandle);
-
-    }
-
-    /**
-     * Instructs this {@code Call} to enter a conference.
-     *
-     * @param callToConferenceWith The other call with which to conference.
-     */
-    public void conference(Call callToConferenceWith) {
-        if (callToConferenceWith != null) {
-            mInCallAdapter.conference(mTelecommCallId, callToConferenceWith.mTelecommCallId);
-        }
-    }
-
-    /**
-     * Instructs this {@code Call} to split from any conference call with which it may be
-     * connected.
-     */
-    public void splitFromConference() {
-        mInCallAdapter.splitFromConference(mTelecommCallId);
-    }
-
-    /**
-     * Obtains the parent of this {@code Call} in a conference, if any.
-     *
-     * @return The parent {@code Call}, or {@code null} if this {@code Call} is not a
-     * child of any conference {@code Call}s.
-     */
-    public Call getParent() {
-        return mParent;
-    }
-
-    /**
-     * Obtains the children of this conference {@code Call}, if any.
-     *
-     * @return The children of this {@code Call} if this {@code Call} is a conference, or an empty
-     * {@code List} otherwise.
-     */
-    public List<Call> getChildren() {
-        return mUnmodifiableChildren;
-    }
-
-    /**
-     * Returns the list of {@code Call}s with which this {@code Call} is allowed to conference.
-     *
-     * @return The list of conferenceable {@code Call}s.
-     */
-    public List<Call> getConferenceableCalls() {
-        return mUnmodifiableConferenceableCalls;
-    }
-
-    /**
-     * Obtains the state of this {@code Call}.
-     *
-     * @return A state value, chosen from the {@code STATE_*} constants.
-     */
-    public int getState() {
-        return mState;
-    }
-
-    /**
-     * Obtains a list of canned, pre-configured message responses to present to the user as
-     * ways of rejecting this {@code Call} using via a text message.
-     *
-     * @see #reject(boolean, String)
-     *
-     * @return A list of canned text message responses.
-     */
-    public List<String> getCannedTextResponses() {
-        return mCannedTextResponses;
-    }
-
-    /**
-     * Obtains an object that can be used to display video from this {@code Call}.
-     *
-     * @return An {@code Call.VideoCall}.
-     */
-    public InCallService.VideoCall getVideoCall() {
-        return mVideoCall;
-    }
-
-    /**
-     * Obtains an object containing call details.
-     *
-     * @return A {@link Details} object. Depending on the state of the {@code Call}, the
-     * result may be {@code null}.
-     */
-    public Details getDetails() {
-        return mDetails;
-    }
-
-    /**
-     * Adds a listener to this {@code Call}.
-     *
-     * @param listener A {@code Listener}.
-     */
-    public void addListener(Listener listener) {
-        mListeners.add(listener);
-    }
-
-    /**
-     * Removes a listener from this {@code Call}.
-     *
-     * @param listener A {@code Listener}.
-     */
-    public void removeListener(Listener listener) {
-        if (listener != null) {
-            mListeners.remove(listener);
-        }
-    }
-
-    /** {@hide} */
-    Call(Phone phone, String telecommCallId, InCallAdapter inCallAdapter) {
-        mPhone = phone;
-        mTelecommCallId = telecommCallId;
-        mInCallAdapter = inCallAdapter;
-        mState = STATE_NEW;
-    }
-
-    /** {@hide} */
-    final String internalGetCallId() {
-        return mTelecommCallId;
-    }
-
-    /** {@hide} */
-    final void internalUpdate(ParcelableCall parcelableCall, Map<String, Call> callIdMap) {
-        // First, we update the internal state as far as possible before firing any updates.
-        Details details = new Details(
-                parcelableCall.getHandle(),
-                parcelableCall.getHandlePresentation(),
-                parcelableCall.getCallerDisplayName(),
-                parcelableCall.getCallerDisplayNamePresentation(),
-                parcelableCall.getAccountHandle(),
-                parcelableCall.getCapabilities(),
-                parcelableCall.getDisconnectCauseCode(),
-                parcelableCall.getDisconnectCauseMsg(),
-                parcelableCall.getConnectTimeMillis(),
-                parcelableCall.getGatewayInfo(),
-                parcelableCall.getVideoState(),
-                parcelableCall.getStatusHints(),
-                parcelableCall.getExtras());
-        boolean detailsChanged = !Objects.equals(mDetails, details);
-        if (detailsChanged) {
-            mDetails = details;
-        }
-
-        boolean cannedTextResponsesChanged = false;
-        if (mCannedTextResponses == null && parcelableCall.getCannedSmsResponses() != null
-                && !parcelableCall.getCannedSmsResponses().isEmpty()) {
-            mCannedTextResponses =
-                    Collections.unmodifiableList(parcelableCall.getCannedSmsResponses());
-        }
-
-        boolean videoCallChanged = !Objects.equals(mVideoCall, parcelableCall.getVideoCall());
-        if (videoCallChanged) {
-            mVideoCall = parcelableCall.getVideoCall();
-        }
-
-        int state = stateFromParcelableCallState(parcelableCall.getState());
-        boolean stateChanged = mState != state;
-        if (stateChanged) {
-            mState = state;
-        }
-
-        if (parcelableCall.getParentCallId() != null) {
-            mParent = mPhone.internalGetCallByTelecommId(parcelableCall.getParentCallId());
-        }
-
-        mChildren.clear();
-        if (parcelableCall.getChildCallIds() != null) {
-            for (int i = 0; i < parcelableCall.getChildCallIds().size(); i++) {
-                mChildren.add(mPhone.internalGetCallByTelecommId(
-                        parcelableCall.getChildCallIds().get(i)));
-            }
-        }
-
-        List<String> conferenceableCallIds = parcelableCall.getConferenceableCallIds();
-        List<Call> conferenceableCalls = new ArrayList<Call>(conferenceableCallIds.size());
-        for (String otherId : conferenceableCallIds) {
-            if (callIdMap.containsKey(otherId)) {
-                conferenceableCalls.add(callIdMap.get(otherId));
-            }
-        }
-
-        if (!Objects.equals(mConferenceableCalls, conferenceableCalls)) {
-            mConferenceableCalls.clear();
-            mConferenceableCalls.addAll(conferenceableCalls);
-            fireConferenceableCallsChanged();
-        }
-
-        // Now we fire updates, ensuring that any client who listens to any of these notifications
-        // gets the most up-to-date state.
-
-        if (stateChanged) {
-            fireStateChanged(mState);
-        }
-        if (detailsChanged) {
-            fireDetailsChanged(mDetails);
-        }
-        if (cannedTextResponsesChanged) {
-            fireCannedTextResponsesLoaded(mCannedTextResponses);
-        }
-        if (videoCallChanged) {
-            fireVideoCallChanged(mVideoCall);
-        }
-
-        // If we have transitioned to DISCONNECTED, that means we need to notify clients and
-        // remove ourselves from the Phone. Note that we do this after completing all state updates
-        // so a client can cleanly transition all their UI to the state appropriate for a
-        // DISCONNECTED Call while still relying on the existence of that Call in the Phone's list.
-        if (mState == STATE_DISCONNECTED) {
-            fireCallDestroyed();
-            mPhone.internalRemoveCall(this);
-        }
-    }
-
-    /** {@hide} */
-    final void internalSetPostDialWait(String remaining) {
-        mRemainingPostDialSequence = remaining;
-        firePostDialWait(mRemainingPostDialSequence);
-    }
-
-    /** {@hide} */
-    final void internalStartActivity(PendingIntent intent) {
-        fireStartActivity(intent);
-    }
-
-    private void fireStateChanged(int newState) {
-        for (Listener listener : mListeners) {
-            listener.onStateChanged(this, newState);
-        }
-    }
-
-    private void fireParentChanged(Call newParent) {
-        for (Listener listener : mListeners) {
-            listener.onParentChanged(this, newParent);
-        }
-    }
-
-    private void fireChildrenChanged(List<Call> children) {
-        for (Listener listener : mListeners) {
-            listener.onChildrenChanged(this, children);
-        }
-    }
-
-    private void fireDetailsChanged(Details details) {
-        for (Listener listener : mListeners) {
-            listener.onDetailsChanged(this, details);
-        }
-    }
-
-    private void fireCannedTextResponsesLoaded(List<String> cannedTextResponses) {
-        for (Listener listener : mListeners) {
-            listener.onCannedTextResponsesLoaded(this, cannedTextResponses);
-        }
-    }
-
-    private void fireVideoCallChanged(InCallService.VideoCall videoCall) {
-        for (Listener listener : mListeners) {
-            listener.onVideoCallChanged(this, videoCall);
-        }
-    }
-
-    private void firePostDialWait(String remainingPostDialSequence) {
-        for (Listener listener : mListeners) {
-            listener.onPostDialWait(this, remainingPostDialSequence);
-        }
-    }
-
-    private void fireStartActivity(PendingIntent intent) {
-        for (Listener listener : mListeners) {
-            listener.onStartActivity(this, intent);
-        }
-    }
-
-    private void fireCallDestroyed() {
-        for (Listener listener : mListeners) {
-            listener.onCallDestroyed(this);
-        }
-    }
-
-    private void fireConferenceableCallsChanged() {
-        for (Listener listener : mListeners) {
-            listener.onConferenceableCallsChanged(this, mUnmodifiableConferenceableCalls);
-        }
-    }
-
-    private int stateFromParcelableCallState(int parcelableCallState) {
-        switch (parcelableCallState) {
-            case CallState.NEW:
-                return STATE_NEW;
-            case CallState.CONNECTING:
-                return STATE_CONNECTING;
-            case CallState.PRE_DIAL_WAIT:
-                return STATE_PRE_DIAL_WAIT;
-            case CallState.DIALING:
-                return STATE_DIALING;
-            case CallState.RINGING:
-                return STATE_RINGING;
-            case CallState.ACTIVE:
-                return STATE_ACTIVE;
-            case CallState.ON_HOLD:
-                return STATE_HOLDING;
-            case CallState.DISCONNECTED:
-                return STATE_DISCONNECTED;
-            case CallState.ABORTED:
-                return STATE_DISCONNECTED;
-            default:
-                Log.wtf(this, "Unrecognized CallState %s", parcelableCallState);
-                return STATE_NEW;
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/CallState.java b/telecomm/java/android/telecomm/CallState.java
deleted file mode 100644
index 73edbe2..0000000
--- a/telecomm/java/android/telecomm/CallState.java
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * Defines call-state constants of the different states in which a call can exist. Although states
- * have the notion of normal transitions, due to the volatile nature of telephony systems, code
- * that uses these states should be resilient to unexpected state changes outside of what is
- * considered traditional.
- *
- * {@hide}
- */
-public final class CallState {
-
-    private CallState() {}
-
-    /**
-     * Indicates that a call is new and not connected. This is used as the default state internally
-     * within Telecomm and should not be used between Telecomm and call services. Call services are
-     * not expected to ever interact with NEW calls, but {@link InCallService}s will see calls in
-     * this state.
-     */
-    public static final int NEW = 0;
-
-    /**
-     * The initial state of an outgoing {@code Call}.
-     * Common transitions are to {@link #DIALING} state for a successful call or
-     * {@link #DISCONNECTED} if it failed.
-     */
-    public static final int CONNECTING = 1;
-
-    /**
-     * Indicates that the call is about to go into the outgoing and dialing state but is waiting for
-     * user input before it proceeds. For example, where no default {@link PhoneAccount} is set,
-     * this is the state where the InCallUI is waiting for the user to select a
-     * {@link PhoneAccount} to call from.
-     */
-    public static final int PRE_DIAL_WAIT = 2;
-
-    /**
-     * Indicates that a call is outgoing and in the dialing state. A call transitions to this state
-     * once an outgoing call has begun (e.g., user presses the dial button in Dialer). Calls in this
-     * state usually transition to {@link #ACTIVE} if the call was answered or {@link #DISCONNECTED}
-     * if the call was disconnected somehow (e.g., failure or cancellation of the call by the user).
-     */
-    public static final int DIALING = 3;
-
-    /**
-     * Indicates that a call is incoming and the user still has the option of answering, rejecting,
-     * or doing nothing with the call. This state is usually associated with some type of audible
-     * ringtone. Normal transitions are to {@link #ACTIVE} if answered or {@link #DISCONNECTED}
-     * otherwise.
-     */
-    public static final int RINGING = 4;
-
-    /**
-     * Indicates that a call is currently connected to another party and a communication channel is
-     * open between them. The normal transition to this state is by the user answering a
-     * {@link #DIALING} call or a {@link #RINGING} call being answered by the other party.
-     */
-    public static final int ACTIVE = 5;
-
-    /**
-     * Indicates that the call is currently on hold. In this state, the call is not terminated
-     * but no communication is allowed until the call is no longer on hold. The typical transition
-     * to this state is by the user putting an {@link #ACTIVE} call on hold by explicitly performing
-     * an action, such as clicking the hold button.
-     */
-    public static final int ON_HOLD = 6;
-
-    /**
-     * Indicates that a call is currently disconnected. All states can transition to this state
-     * by the call service giving notice that the connection has been severed. When the user
-     * explicitly ends a call, it will not transition to this state until the call service confirms
-     * the disconnection or communication was lost to the call service currently responsible for
-     * this call (e.g., call service crashes).
-     */
-    public static final int DISCONNECTED = 7;
-
-    /**
-     * Indicates that the call was attempted (mostly in the context of outgoing, at least at the
-     * time of writing) but cancelled before it was successfully connected.
-     */
-    public static final int ABORTED = 8;
-
-    public static String toString(int callState) {
-        switch (callState) {
-            case NEW:
-                return "NEW";
-            case CONNECTING:
-                return "CONNECTING";
-            case PRE_DIAL_WAIT:
-                return "PRE_DIAL_WAIT";
-            case DIALING:
-                return "DIALING";
-            case RINGING:
-                return "RINGING";
-            case ACTIVE:
-                return "ACTIVE";
-            case ON_HOLD:
-                return "ON_HOLD";
-            case DISCONNECTED:
-                return "DISCONNECTED";
-            case ABORTED:
-                return "ABORTED";
-            default:
-                return "UNKNOWN";
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/CameraCapabilities.aidl b/telecomm/java/android/telecomm/CameraCapabilities.aidl
deleted file mode 100644
index 08e6f43..0000000
--- a/telecomm/java/android/telecomm/CameraCapabilities.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable CameraCapabilities;
diff --git a/telecomm/java/android/telecomm/CameraCapabilities.java b/telecomm/java/android/telecomm/CameraCapabilities.java
deleted file mode 100644
index 7c7dde1..0000000
--- a/telecomm/java/android/telecomm/CameraCapabilities.java
+++ /dev/null
@@ -1,143 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Represents the camera capabilities important to a Video Telephony provider.
- */
-public final class CameraCapabilities implements Parcelable {
-
-    /**
-     * Whether the camera supports zoom.
-     */
-    private final boolean mZoomSupported;
-
-    /**
-     * The maximum zoom supported by the camera.
-     */
-    private final float mMaxZoom;
-
-    /**
-     * The width of the camera video in pixels.
-     */
-    private final int mWidth;
-
-    /**
-     * The height of the camera video in pixels.
-     */
-    private final int mHeight;
-
-    /**
-     * Create a call camera capabilities instance.
-     *
-     * @param zoomSupported True when camera supports zoom.
-     * @param maxZoom Maximum zoom supported by camera.
-     * @param width The width of the camera video (in pixels).
-     * @param height The height of the camera video (in pixels).
-     */
-    public CameraCapabilities(boolean zoomSupported, float maxZoom, int width, int height) {
-        mZoomSupported = zoomSupported;
-        mMaxZoom = maxZoom;
-        mWidth = width;
-        mHeight = height;
-    }
-
-    /**
-     * Responsible for creating CallCameraCapabilities objects from deserialized Parcels.
-     **/
-    public static final Parcelable.Creator<CameraCapabilities> CREATOR =
-            new Parcelable.Creator<CameraCapabilities> () {
-                /**
-                 * Creates a CallCameraCapabilities instances from a parcel.
-                 *
-                 * @param source The parcel.
-                 * @return The CallCameraCapabilities.
-                 */
-                @Override
-                public CameraCapabilities createFromParcel(Parcel source) {
-                    boolean supportsZoom = source.readByte() != 0;
-                    float maxZoom = source.readFloat();
-                    int width = source.readInt();
-                    int height = source.readInt();
-
-                    return new CameraCapabilities(supportsZoom, maxZoom, width, height);
-                }
-
-                @Override
-                public CameraCapabilities[] newArray(int size) {
-                    return new CameraCapabilities[size];
-                }
-            };
-
-    /**
-     * Describe the kinds of special objects contained in this Parcelable's
-     * marshalled representation.
-     *
-     * @return a bitmask indicating the set of special object types marshalled
-     * by the Parcelable.
-     */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /**
-     * Flatten this object in to a Parcel.
-     *
-     * @param dest  The Parcel in which the object should be written.
-     * @param flags Additional flags about how the object should be written.
-     *              May be 0 or {@link #PARCELABLE_WRITE_RETURN_VALUE}.
-     */
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeByte((byte) (isZoomSupported() ? 1 : 0));
-        dest.writeFloat(getMaxZoom());
-        dest.writeInt(getWidth());
-        dest.writeInt(getHeight());
-    }
-
-    /**
-     * Whether the camera supports zoom.
-     */
-    public boolean isZoomSupported() {
-        return mZoomSupported;
-    }
-
-    /**
-     * The maximum zoom supported by the camera.
-     */
-    public float getMaxZoom() {
-        return mMaxZoom;
-    }
-
-    /**
-     * The width of the camera video in pixels.
-     */
-    public int getWidth() {
-        return mWidth;
-    }
-
-    /**
-     * The height of the camera video in pixels.
-     */
-    public int getHeight() {
-        return mHeight;
-    }
-}
diff --git a/telecomm/java/android/telecomm/Connection.java b/telecomm/java/android/telecomm/Connection.java
deleted file mode 100644
index 78c34a1..0000000
--- a/telecomm/java/android/telecomm/Connection.java
+++ /dev/null
@@ -1,1148 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import com.android.internal.telecomm.IVideoCallback;
-import com.android.internal.telecomm.IVideoProvider;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Message;
-import android.os.RemoteException;
-import android.telephony.DisconnectCause;
-import android.view.Surface;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-
-/**
- * Represents a connection to a remote endpoint that carries voice traffic.
- */
-public abstract class Connection {
-
-    public static final int STATE_INITIALIZING = 0;
-
-    public static final int STATE_NEW = 1;
-
-    public static final int STATE_RINGING = 2;
-
-    public static final int STATE_DIALING = 3;
-
-    public static final int STATE_ACTIVE = 4;
-
-    public static final int STATE_HOLDING = 5;
-
-    public static final int STATE_DISCONNECTED = 6;
-
-    public static final int STATE_FAILED = 7;
-
-    public static final int STATE_CANCELED = 8;
-
-    // Flag controlling whether PII is emitted into the logs
-    private static final boolean PII_DEBUG = Log.isLoggable(android.util.Log.DEBUG);
-
-    private static Connection sNullConnection;
-
-    /** @hide */
-    public abstract static class Listener {
-        public void onStateChanged(Connection c, int state) {}
-        public void onHandleChanged(Connection c, Uri newHandle, int presentation) {}
-        public void onCallerDisplayNameChanged(
-                Connection c, String callerDisplayName, int presentation) {}
-        public void onVideoStateChanged(Connection c, int videoState) {}
-        public void onDisconnected(Connection c, int cause, String message) {}
-        public void onPostDialWait(Connection c, String remaining) {}
-        public void onRequestingRingback(Connection c, boolean ringback) {}
-        public void onDestroyed(Connection c) {}
-        public void onCallCapabilitiesChanged(Connection c, int callCapabilities) {}
-        public void onParentConnectionChanged(Connection c, Connection parent) {}
-        public void onVideoProviderChanged(
-                Connection c, VideoProvider videoProvider) {}
-        public void onAudioModeIsVoipChanged(Connection c, boolean isVoip) {}
-        public void onStatusHintsChanged(Connection c, StatusHints statusHints) {}
-        public void onStartActivityFromInCall(Connection c, PendingIntent intent) {}
-        public void onConferenceableConnectionsChanged(
-                Connection c, List<Connection> conferenceableConnections) {}
-    }
-
-    public static abstract class VideoProvider {
-
-        /**
-         * Video is not being received (no protocol pause was issued).
-         */
-        public static final int SESSION_EVENT_RX_PAUSE = 1;
-
-        /**
-         * Video reception has resumed after a SESSION_EVENT_RX_PAUSE.
-         */
-        public static final int SESSION_EVENT_RX_RESUME = 2;
-
-        /**
-         * Video transmission has begun. This occurs after a negotiated start of video transmission
-         * when the underlying protocol has actually begun transmitting video to the remote party.
-         */
-        public static final int SESSION_EVENT_TX_START = 3;
-
-        /**
-         * Video transmission has stopped. This occurs after a negotiated stop of video transmission
-         * when the underlying protocol has actually stopped transmitting video to the remote party.
-         */
-        public static final int SESSION_EVENT_TX_STOP = 4;
-
-        /**
-         * A camera failure has occurred for the selected camera.  The In-Call UI can use this as a
-         * cue to inform the user the camera is not available.
-         */
-        public static final int SESSION_EVENT_CAMERA_FAILURE = 5;
-
-        /**
-         * Issued after {@code SESSION_EVENT_CAMERA_FAILURE} when the camera is once again ready for
-         * operation.  The In-Call UI can use this as a cue to inform the user that the camera has
-         * become available again.
-         */
-        public static final int SESSION_EVENT_CAMERA_READY = 6;
-
-        /**
-         * Session modify request was successful.
-         */
-        public static final int SESSION_MODIFY_REQUEST_SUCCESS = 1;
-
-        /**
-         * Session modify request failed.
-         */
-        public static final int SESSION_MODIFY_REQUEST_FAIL = 2;
-
-        /**
-         * Session modify request ignored due to invalid parameters.
-         */
-        public static final int SESSION_MODIFY_REQUEST_INVALID = 3;
-
-        private static final int MSG_SET_VIDEO_LISTENER = 1;
-        private static final int MSG_SET_CAMERA = 2;
-        private static final int MSG_SET_PREVIEW_SURFACE = 3;
-        private static final int MSG_SET_DISPLAY_SURFACE = 4;
-        private static final int MSG_SET_DEVICE_ORIENTATION = 5;
-        private static final int MSG_SET_ZOOM = 6;
-        private static final int MSG_SEND_SESSION_MODIFY_REQUEST = 7;
-        private static final int MSG_SEND_SESSION_MODIFY_RESPONSE = 8;
-        private static final int MSG_REQUEST_CAMERA_CAPABILITIES = 9;
-        private static final int MSG_REQUEST_CALL_DATA_USAGE = 10;
-        private static final int MSG_SET_PAUSE_IMAGE = 11;
-
-        private final VideoProvider.VideoProviderHandler
-                mMessageHandler = new VideoProvider.VideoProviderHandler();
-        private final VideoProvider.VideoProviderBinder mBinder;
-        private IVideoCallback mVideoListener;
-
-        /**
-         * Default handler used to consolidate binder method calls onto a single thread.
-         */
-        private final class VideoProviderHandler extends Handler {
-            @Override
-            public void handleMessage(Message msg) {
-                switch (msg.what) {
-                    case MSG_SET_VIDEO_LISTENER:
-                        mVideoListener = IVideoCallback.Stub.asInterface((IBinder) msg.obj);
-                        break;
-                    case MSG_SET_CAMERA:
-                        onSetCamera((String) msg.obj);
-                        break;
-                    case MSG_SET_PREVIEW_SURFACE:
-                        onSetPreviewSurface((Surface) msg.obj);
-                        break;
-                    case MSG_SET_DISPLAY_SURFACE:
-                        onSetDisplaySurface((Surface) msg.obj);
-                        break;
-                    case MSG_SET_DEVICE_ORIENTATION:
-                        onSetDeviceOrientation(msg.arg1);
-                        break;
-                    case MSG_SET_ZOOM:
-                        onSetZoom((Float) msg.obj);
-                        break;
-                    case MSG_SEND_SESSION_MODIFY_REQUEST:
-                        onSendSessionModifyRequest((VideoProfile) msg.obj);
-                        break;
-                    case MSG_SEND_SESSION_MODIFY_RESPONSE:
-                        onSendSessionModifyResponse((VideoProfile) msg.obj);
-                        break;
-                    case MSG_REQUEST_CAMERA_CAPABILITIES:
-                        onRequestCameraCapabilities();
-                        break;
-                    case MSG_REQUEST_CALL_DATA_USAGE:
-                        onRequestCallDataUsage();
-                        break;
-                    case MSG_SET_PAUSE_IMAGE:
-                        onSetPauseImage((String) msg.obj);
-                        break;
-                    default:
-                        break;
-                }
-            }
-        }
-
-        /**
-         * IVideoProvider stub implementation.
-         */
-        private final class VideoProviderBinder extends IVideoProvider.Stub {
-            public void setVideoListener(IBinder videoListenerBinder) {
-                mMessageHandler.obtainMessage(
-                        MSG_SET_VIDEO_LISTENER, videoListenerBinder).sendToTarget();
-            }
-
-            public void setCamera(String cameraId) {
-                mMessageHandler.obtainMessage(MSG_SET_CAMERA, cameraId).sendToTarget();
-            }
-
-            public void setPreviewSurface(Surface surface) {
-                mMessageHandler.obtainMessage(MSG_SET_PREVIEW_SURFACE, surface).sendToTarget();
-            }
-
-            public void setDisplaySurface(Surface surface) {
-                mMessageHandler.obtainMessage(MSG_SET_DISPLAY_SURFACE, surface).sendToTarget();
-            }
-
-            public void setDeviceOrientation(int rotation) {
-                mMessageHandler.obtainMessage(MSG_SET_DEVICE_ORIENTATION, rotation).sendToTarget();
-            }
-
-            public void setZoom(float value) {
-                mMessageHandler.obtainMessage(MSG_SET_ZOOM, value).sendToTarget();
-            }
-
-            public void sendSessionModifyRequest(VideoProfile requestProfile) {
-                mMessageHandler.obtainMessage(
-                        MSG_SEND_SESSION_MODIFY_REQUEST, requestProfile).sendToTarget();
-            }
-
-            public void sendSessionModifyResponse(VideoProfile responseProfile) {
-                mMessageHandler.obtainMessage(
-                        MSG_SEND_SESSION_MODIFY_RESPONSE, responseProfile).sendToTarget();
-            }
-
-            public void requestCameraCapabilities() {
-                mMessageHandler.obtainMessage(MSG_REQUEST_CAMERA_CAPABILITIES).sendToTarget();
-            }
-
-            public void requestCallDataUsage() {
-                mMessageHandler.obtainMessage(MSG_REQUEST_CALL_DATA_USAGE).sendToTarget();
-            }
-
-            public void setPauseImage(String uri) {
-                mMessageHandler.obtainMessage(MSG_SET_PAUSE_IMAGE, uri).sendToTarget();
-            }
-        }
-
-        public VideoProvider() {
-            mBinder = new VideoProvider.VideoProviderBinder();
-        }
-
-        /**
-         * Returns binder object which can be used across IPC methods.
-         * @hide
-         */
-        public final IVideoProvider getInterface() {
-            return mBinder;
-        }
-
-        /**
-         * Sets the camera to be used for video recording in a video call.
-         *
-         * @param cameraId The id of the camera.
-         */
-        public abstract void onSetCamera(String cameraId);
-
-        /**
-         * Sets the surface to be used for displaying a preview of what the user's camera is
-         * currently capturing.  When video transmission is enabled, this is the video signal which
-         * is sent to the remote device.
-         *
-         * @param surface The surface.
-         */
-        public abstract void onSetPreviewSurface(Surface surface);
-
-        /**
-         * Sets the surface to be used for displaying the video received from the remote device.
-         *
-         * @param surface The surface.
-         */
-        public abstract void onSetDisplaySurface(Surface surface);
-
-        /**
-         * Sets the device orientation, in degrees.  Assumes that a standard portrait orientation of
-         * the device is 0 degrees.
-         *
-         * @param rotation The device orientation, in degrees.
-         */
-        public abstract void onSetDeviceOrientation(int rotation);
-
-        /**
-         * Sets camera zoom ratio.
-         *
-         * @param value The camera zoom ratio.
-         */
-        public abstract void onSetZoom(float value);
-
-        /**
-         * Issues a request to modify the properties of the current session.  The request is
-         * sent to the remote device where it it handled by the In-Call UI.
-         * Some examples of session modification requests: upgrade call from audio to video,
-         * downgrade call from video to audio, pause video.
-         *
-         * @param requestProfile The requested call video properties.
-         */
-        public abstract void onSendSessionModifyRequest(VideoProfile requestProfile);
-
-        /**te
-         * Provides a response to a request to change the current call session video
-         * properties.
-         * This is in response to a request the InCall UI has received via the InCall UI.
-         *
-         * @param responseProfile The response call video properties.
-         */
-        public abstract void onSendSessionModifyResponse(VideoProfile responseProfile);
-
-        /**
-         * Issues a request to the video provider to retrieve the camera capabilities.
-         * Camera capabilities are reported back to the caller via the In-Call UI.
-         */
-        public abstract void onRequestCameraCapabilities();
-
-        /**
-         * Issues a request to the video telephony framework to retrieve the cumulative data usage
-         * for the current call.  Data usage is reported back to the caller via the
-         * InCall UI.
-         */
-        public abstract void onRequestCallDataUsage();
-
-        /**
-         * Provides the video telephony framework with the URI of an image to be displayed to remote
-         * devices when the video signal is paused.
-         *
-         * @param uri URI of image to display.
-         */
-        public abstract void onSetPauseImage(String uri);
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * @param videoProfile The requested video call profile.
-         */
-        public void receiveSessionModifyRequest(VideoProfile videoProfile) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.receiveSessionModifyRequest(videoProfile);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * @param status Status of the session modify request.  Valid values are
-         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_SUCCESS},
-         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_FAIL},
-         *               {@link VideoProvider#SESSION_MODIFY_REQUEST_INVALID}
-         * @param requestedProfile The original request which was sent to the remote device.
-         * @param responseProfile The actual profile changes made by the remote device.
-         */
-        public void receiveSessionModifyResponse(int status,
-                VideoProfile requestedProfile, VideoProfile responseProfile) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.receiveSessionModifyResponse(
-                            status, requestedProfile, responseProfile);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * Valid values are: {@link VideoProvider#SESSION_EVENT_RX_PAUSE},
-         * {@link VideoProvider#SESSION_EVENT_RX_RESUME},
-         * {@link VideoProvider#SESSION_EVENT_TX_START},
-         * {@link VideoProvider#SESSION_EVENT_TX_STOP}
-         *
-         * @param event The event.
-         */
-        public void handleCallSessionEvent(int event) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.handleCallSessionEvent(event);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * @param width  The updated peer video width.
-         * @param height The updated peer video height.
-         */
-        public void changePeerDimensions(int width, int height) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.changePeerDimensions(width, height);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * @param dataUsage The updated data usage.
-         */
-        public void changeCallDataUsage(int dataUsage) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.changeCallDataUsage(dataUsage);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-
-        /**
-         * Invokes callback method defined in In-Call UI.
-         *
-         * @param cameraCapabilities The changed camera capabilities.
-         */
-        public void changeCameraCapabilities(CameraCapabilities cameraCapabilities) {
-            if (mVideoListener != null) {
-                try {
-                    mVideoListener.changeCameraCapabilities(cameraCapabilities);
-                } catch (RemoteException ignored) {
-                }
-            }
-        }
-    }
-
-    private final Listener mConnectionDeathListener = new Listener() {
-        @Override
-        public void onDestroyed(Connection c) {
-            if (mConferenceableConnections.remove(c)) {
-                fireOnConferenceableConnectionsChanged();
-            }
-        }
-    };
-
-    /**
-     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
-     * load factor before resizing, 1 means we only expect a single thread to
-     * access the map so make only a single shard
-     */
-    private final Set<Listener> mListeners = Collections.newSetFromMap(
-            new ConcurrentHashMap<Listener, Boolean>(8, 0.9f, 1));
-    private final List<Connection> mChildConnections = new ArrayList<>();
-    private final List<Connection> mUnmodifiableChildConnections =
-            Collections.unmodifiableList(mChildConnections);
-    private final List<Connection> mConferenceableConnections = new ArrayList<>();
-    private final List<Connection> mUnmodifiableConferenceableConnections =
-            Collections.unmodifiableList(mConferenceableConnections);
-
-    private int mState = STATE_NEW;
-    private AudioState mAudioState;
-    private Uri mHandle;
-    private int mHandlePresentation;
-    private String mCallerDisplayName;
-    private int mCallerDisplayNamePresentation;
-    private boolean mRequestingRingback = false;
-    private int mCallCapabilities;
-    private Connection mParentConnection;
-    private VideoProvider mVideoProvider;
-    private boolean mAudioModeIsVoip;
-    private StatusHints mStatusHints;
-    private int mVideoState;
-    private int mFailureCode;
-    private String mFailureMessage;
-    private boolean mIsCanceled;
-
-    /**
-     * Create a new Connection.
-     */
-    public Connection() {}
-
-    /**
-     * @return The handle (e.g., phone number) to which this Connection is currently communicating.
-     */
-    public final Uri getHandle() {
-        return mHandle;
-    }
-
-    /**
-     * @return The {@link PropertyPresentation} which controls how the handle is shown.
-     */
-    public final int getHandlePresentation() {
-        return mHandlePresentation;
-    }
-
-    /**
-     * @return The caller display name (CNAP).
-     */
-    public final String getCallerDisplayName() {
-        return mCallerDisplayName;
-    }
-
-    /**
-     * @return The {@link PropertyPresentation} which controls how the caller display name is
-     *         shown.
-     */
-    public final int getCallerDisplayNamePresentation() {
-        return mCallerDisplayNamePresentation;
-    }
-
-    /**
-     * @return The state of this Connection.
-     */
-    public final int getState() {
-        return mState;
-    }
-
-    /**
-     * Returns the video state of the call.
-     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#TX_ENABLED},
-     * {@link VideoProfile.VideoState#RX_ENABLED}.
-     *
-     * @return The video state of the call.
-     */
-    public final int getVideoState() {
-        return mVideoState;
-    }
-
-    /**
-     * @return The audio state of the call, describing how its audio is currently
-     *         being routed by the system. This is {@code null} if this Connection
-     *         does not directly know about its audio state.
-     */
-    public final AudioState getAudioState() {
-        return mAudioState;
-    }
-
-    /**
-     * Returns whether this connection is requesting that the system play a ringback tone
-     * on its behalf.
-     */
-    public final boolean isRequestingRingback() {
-        return mRequestingRingback;
-    }
-
-    /**
-     * Returns whether this connection is a conference connection (has child connections).
-     */
-    public final boolean isConferenceConnection() {
-        return !mChildConnections.isEmpty();
-    }
-
-    /**
-     * @return True if the connection's audio mode is VOIP.
-     */
-    public final boolean getAudioModeIsVoip() {
-        return mAudioModeIsVoip;
-    }
-
-    /**
-     * @return The status hints for this connection.
-     */
-    public final StatusHints getStatusHints() {
-        return mStatusHints;
-    }
-
-    /**
-     * Assign a listener to be notified of state changes.
-     *
-     * @param l A listener.
-     * @return This Connection.
-     *
-     * @hide
-     */
-    public final Connection addConnectionListener(Listener l) {
-        mListeners.add(l);
-        return this;
-    }
-
-    /**
-     * Remove a previously assigned listener that was being notified of state changes.
-     *
-     * @param l A Listener.
-     * @return This Connection.
-     *
-     * @hide
-     */
-    public final Connection removeConnectionListener(Listener l) {
-        if (l != null) {
-            mListeners.remove(l);
-        }
-        return this;
-    }
-
-    /**
-     * @return The failure code ({@see DisconnectCause}) associated with this failed connection.
-     */
-    public final int getFailureCode() {
-        return mFailureCode;
-    }
-
-    /**
-     * @return The reason for the connection failure. This will not be displayed to the user.
-     */
-    public final String getFailureMessage() {
-        return mFailureMessage;
-    }
-
-    /**
-     * Inform this Connection that the state of its audio output has been changed externally.
-     *
-     * @param state The new audio state.
-     * @hide
-     */
-    final void setAudioState(AudioState state) {
-        Log.d(this, "setAudioState %s", state);
-        mAudioState = state;
-        onSetAudioState(state);
-    }
-
-    /**
-     * @param state An integer value of a {@code STATE_*} constant.
-     * @return A string representation of the value.
-     */
-    public static String stateToString(int state) {
-        switch (state) {
-            case STATE_INITIALIZING:
-                return "STATE_INITIALIZING";
-            case STATE_NEW:
-                return "STATE_NEW";
-            case STATE_RINGING:
-                return "STATE_RINGING";
-            case STATE_DIALING:
-                return "STATE_DIALING";
-            case STATE_ACTIVE:
-                return "STATE_ACTIVE";
-            case STATE_HOLDING:
-                return "STATE_HOLDING";
-            case STATE_DISCONNECTED:
-                return "DISCONNECTED";
-            case STATE_FAILED:
-                return "STATE_FAILED";
-            case STATE_CANCELED:
-                return "STATE_CANCELED";
-            default:
-                Log.wtf(Connection.class, "Unknown state %d", state);
-                return "UNKNOWN";
-        }
-    }
-
-    /**
-     * TODO: Needs documentation.
-     */
-    public final void setParentConnection(Connection parentConnection) {
-        Log.d(this, "parenting %s to %s", this, parentConnection);
-        if (mParentConnection != parentConnection) {
-            if (mParentConnection != null) {
-                mParentConnection.removeChild(this);
-            }
-            mParentConnection = parentConnection;
-            if (mParentConnection != null) {
-                mParentConnection.addChild(this);
-                // do something if the child connections goes down to ZERO.
-            }
-            for (Listener l : mListeners) {
-                l.onParentConnectionChanged(this, mParentConnection);
-            }
-        }
-    }
-
-    public final Connection getParentConnection() {
-        return mParentConnection;
-    }
-
-    public final List<Connection> getChildConnections() {
-        return mUnmodifiableChildConnections;
-    }
-
-    /**
-     * Returns the connection's {@link PhoneCapabilities}
-     */
-    public final int getCallCapabilities() {
-        return mCallCapabilities;
-    }
-
-    /**
-     * Sets the value of the {@link #getHandle()} property.
-     *
-     * @param handle The new handle.
-     * @param presentation The {@link PropertyPresentation} which controls how the handle is
-     *         shown.
-     */
-    public final void setHandle(Uri handle, int presentation) {
-        Log.d(this, "setHandle %s", handle);
-        mHandle = handle;
-        mHandlePresentation = presentation;
-        for (Listener l : mListeners) {
-            l.onHandleChanged(this, handle, presentation);
-        }
-    }
-
-    /**
-     * Sets the caller display name (CNAP).
-     *
-     * @param callerDisplayName The new display name.
-     * @param presentation The {@link PropertyPresentation} which controls how the name is
-     *         shown.
-     */
-    public final void setCallerDisplayName(String callerDisplayName, int presentation) {
-        Log.d(this, "setCallerDisplayName %s", callerDisplayName);
-        mCallerDisplayName = callerDisplayName;
-        mCallerDisplayNamePresentation = presentation;
-        for (Listener l : mListeners) {
-            l.onCallerDisplayNameChanged(this, callerDisplayName, presentation);
-        }
-    }
-
-    /**
-     * Cancel the {@link Connection}. Once this is called, the {@link Connection} will not be used,
-     * and no subsequent {@link Connection}s will be attempted.
-     */
-    public final void setCanceled() {
-        Log.d(this, "setCanceled");
-        setState(STATE_CANCELED);
-    }
-
-    /**
-     * Move the {@link Connection} to the {@link #STATE_FAILED} state, with the given code
-     * ({@see DisconnectCause}) and message. This message is not shown to the user, but is useful
-     * for logging and debugging purposes.
-     * <p>
-     * After calling this, the {@link Connection} will not be used.
-     *
-     * @param code The {@link DisconnectCause} indicating why the connection
-     *             failed.
-     * @param message A message explaining why the {@link Connection} failed.
-     */
-    public final void setFailed(int code, String message) {
-        Log.d(this, "setFailed (%d: %s)", code, message);
-        mFailureCode = code;
-        mFailureMessage = message;
-        setState(STATE_FAILED);
-    }
-
-    /**
-     * Set the video state for the connection.
-     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#TX_ENABLED},
-     * {@link VideoProfile.VideoState#RX_ENABLED}.
-     *
-     * @param videoState The new video state.
-     */
-    public final void setVideoState(int videoState) {
-        Log.d(this, "setVideoState %d", videoState);
-        mVideoState = videoState;
-        for (Listener l : mListeners) {
-            l.onVideoStateChanged(this, mVideoState);
-        }
-    }
-
-    /**
-     * Sets state to active (e.g., an ongoing call where two or more parties can actively
-     * communicate).
-     */
-    public final void setActive() {
-        setRequestingRingback(false);
-        setState(STATE_ACTIVE);
-    }
-
-    /**
-     * Sets state to ringing (e.g., an inbound ringing call).
-     */
-    public final void setRinging() {
-        setState(STATE_RINGING);
-    }
-
-    /**
-     * Sets state to initializing (this Connection is not yet ready to be used).
-     */
-    public final void setInitializing() {
-        setState(STATE_INITIALIZING);
-    }
-
-    /**
-     * Sets state to initialized (the Connection has been set up and is now ready to be used).
-     */
-    public final void setInitialized() {
-        setState(STATE_NEW);
-    }
-
-    /**
-     * Sets state to dialing (e.g., dialing an outbound call).
-     */
-    public final void setDialing() {
-        setState(STATE_DIALING);
-    }
-
-    /**
-     * Sets state to be on hold.
-     */
-    public final void setOnHold() {
-        setState(STATE_HOLDING);
-    }
-
-    /**
-     * Sets the video call provider.
-     * @param videoProvider The video provider.
-     */
-    public final void setVideoProvider(VideoProvider videoProvider) {
-        mVideoProvider = videoProvider;
-        for (Listener l : mListeners) {
-            l.onVideoProviderChanged(this, videoProvider);
-        }
-    }
-
-    public final VideoProvider getVideoProvider() {
-        return mVideoProvider;
-    }
-
-    /**
-     * Sets state to disconnected.
-     *
-     * @param cause The reason for the disconnection, any of
-     *         {@link DisconnectCause}.
-     * @param message Optional call-service-provided message about the disconnect.
-     */
-    public final void setDisconnected(int cause, String message) {
-        setState(STATE_DISCONNECTED);
-        Log.d(this, "Disconnected with cause %d message %s", cause, message);
-        for (Listener l : mListeners) {
-            l.onDisconnected(this, cause, message);
-        }
-    }
-
-    /**
-     * TODO: Needs documentation.
-     */
-    public final void setPostDialWait(String remaining) {
-        for (Listener l : mListeners) {
-            l.onPostDialWait(this, remaining);
-        }
-    }
-
-    /**
-     * Requests that the framework play a ringback tone. This is to be invoked by implementations
-     * that do not play a ringback tone themselves in the call's audio stream.
-     *
-     * @param ringback Whether the ringback tone is to be played.
-     */
-    public final void setRequestingRingback(boolean ringback) {
-        if (mRequestingRingback != ringback) {
-            mRequestingRingback = ringback;
-            for (Listener l : mListeners) {
-                l.onRequestingRingback(this, ringback);
-            }
-        }
-    }
-
-    /**
-     * Sets the connection's {@link PhoneCapabilities}.
-     *
-     * @param callCapabilities The new call capabilities.
-     */
-    public final void setCallCapabilities(int callCapabilities) {
-        if (mCallCapabilities != callCapabilities) {
-            mCallCapabilities = callCapabilities;
-            for (Listener l : mListeners) {
-                l.onCallCapabilitiesChanged(this, mCallCapabilities);
-            }
-        }
-    }
-
-    /**
-     * Tears down the Connection object.
-     */
-    public final void destroy() {
-        for (Listener l : mListeners) {
-            l.onDestroyed(this);
-        }
-    }
-
-    /**
-     * Requests that the framework use VOIP audio mode for this connection.
-     *
-     * @param isVoip True if the audio mode is VOIP.
-     */
-    public final void setAudioModeIsVoip(boolean isVoip) {
-        mAudioModeIsVoip = isVoip;
-        for (Listener l : mListeners) {
-            l.onAudioModeIsVoipChanged(this, isVoip);
-        }
-    }
-
-    /**
-     * Sets the label and icon status to display in the in-call UI.
-     *
-     * @param statusHints The status label and icon to set.
-     */
-    public final void setStatusHints(StatusHints statusHints) {
-        mStatusHints = statusHints;
-        for (Listener l : mListeners) {
-            l.onStatusHintsChanged(this, statusHints);
-        }
-    }
-
-    /**
-     * Sets the connections with which this connection can be conferenced.
-     *
-     * @param conferenceableConnections The set of connections this connection can conference with.
-     */
-    public final void setConferenceableConnections(List<Connection> conferenceableConnections) {
-        clearConferenceableList();
-        for (Connection c : conferenceableConnections) {
-            // If statement checks for duplicates in input. It makes it N^2 but we're dealing with a
-            // small amount of items here.
-            if (!mConferenceableConnections.contains(c)) {
-                c.addConnectionListener(mConnectionDeathListener);
-                mConferenceableConnections.add(c);
-            }
-        }
-        fireOnConferenceableConnectionsChanged();
-    }
-
-    /**
-     * Obtains the connections with which this connection can be conferenced.
-     */
-    public final List<Connection> getConferenceableConnections() {
-        return mUnmodifiableConferenceableConnections;
-    }
-
-    /**
-     * Launches an activity for this connection on top of the in-call UI.
-     *
-     * @param intent The intent to use to start the activity.
-     */
-    public final void startActivityFromInCall(PendingIntent intent) {
-        if (!intent.isActivity()) {
-            throw new IllegalArgumentException("Activity intent required.");
-        }
-        for (Listener l : mListeners) {
-            l.onStartActivityFromInCall(this, intent);
-        }
-    }
-
-    /**
-     * Notifies this Connection that the {@link #getAudioState()} property has a new value.
-     *
-     * @param state The new call audio state.
-     */
-    public void onSetAudioState(AudioState state) {}
-
-    /**
-     * Notifies this Connection of an internal state change. This method is called after the
-     * state is changed.
-     *
-     * @param state The new state, one of the {@code STATE_*} constants.
-     */
-    public void onSetState(int state) {}
-
-    /**
-     * Notifies this Connection of a request to play a DTMF tone.
-     *
-     * @param c A DTMF character.
-     */
-    public void onPlayDtmfTone(char c) {}
-
-    /**
-     * Notifies this Connection of a request to stop any currently playing DTMF tones.
-     */
-    public void onStopDtmfTone() {}
-
-    /**
-     * Notifies this Connection of a request to disconnect.
-     */
-    public void onDisconnect() {}
-
-    /**
-     * Notifies this Connection of a request to separate from its parent conference.
-     */
-    public void onSeparate() {}
-
-    /**
-     * Notifies this Connection of a request to abort.
-     */
-    public void onAbort() {}
-
-    /**
-     * Notifies this Connection of a request to hold.
-     */
-    public void onHold() {}
-
-    /**
-     * Notifies this Connection of a request to exit a hold state.
-     */
-    public void onUnhold() {}
-
-    /**
-     * Notifies this Connection, which is in {@link #STATE_RINGING}, of
-     * a request to accept.
-     *
-     * @param videoState The video state in which to answer the call.
-     */
-    public void onAnswer(int videoState) {}
-
-    /**
-     * Notifies this Connection, which is in {@link #STATE_RINGING}, of
-     * a request to reject.
-     */
-    public void onReject() {}
-
-    /**
-     * Notifies this Connection whether the user wishes to proceed with the post-dial DTMF codes.
-     */
-    public void onPostDialContinue(boolean proceed) {}
-
-    /**
-     * TODO: Needs documentation.
-     */
-    public void onChildrenChanged(List<Connection> children) {}
-
-    /**
-     * Called when the phone account UI was clicked.
-     */
-    public void onPhoneAccountClicked() {}
-
-    /**
-     * Merge this connection and the specified connection into a conference call.  Once the
-     * connections are merged, the calls should be added to the an existing or new
-     * {@code Conference} instance. For new {@code Conference} instances, use
-     * {@code ConnectionService#addConference}.
-     *
-     * @param otherConnection The connection with which this connection should be conferenced.
-     */
-    public void onConferenceWith(Connection otherConnection) {}
-
-    static String toLogSafePhoneNumber(String number) {
-        // For unknown number, log empty string.
-        if (number == null) {
-            return "";
-        }
-
-        if (PII_DEBUG) {
-            // When PII_DEBUG is true we emit PII.
-            return number;
-        }
-
-        // Do exactly same thing as Uri#toSafeString() does, which will enable us to compare
-        // sanitized phone numbers.
-        StringBuilder builder = new StringBuilder();
-        for (int i = 0; i < number.length(); i++) {
-            char c = number.charAt(i);
-            if (c == '-' || c == '@' || c == '.') {
-                builder.append(c);
-            } else {
-                builder.append('x');
-            }
-        }
-        return builder.toString();
-    }
-
-    static synchronized Connection getNullConnection() {
-        if (sNullConnection == null) {
-            sNullConnection = new Connection() {};
-        }
-        return sNullConnection;
-    }
-
-    private void addChild(Connection connection) {
-        Log.d(this, "adding child %s", connection);
-        mChildConnections.add(connection);
-        onChildrenChanged(mChildConnections);
-    }
-
-    private void removeChild(Connection connection) {
-        Log.d(this, "removing child %s", connection);
-        mChildConnections.remove(connection);
-        onChildrenChanged(mChildConnections);
-    }
-
-    private void setState(int state) {
-        if (mState == STATE_FAILED || mState == STATE_CANCELED) {
-            Log.d(this, "Connection already %s; cannot transition out of this state.",
-                    stateToString(mState));
-            return;
-        }
-        if (mState != state) {
-            Log.d(this, "setState: %s", stateToString(state));
-            mState = state;
-            for (Listener l : mListeners) {
-                l.onStateChanged(this, state);
-            }
-            onSetState(state);
-        }
-    }
-
-    /**
-     * Return a {@link Connection} which represents a failed connection attempt. The returned
-     * {@link Connection} will have {@link #getFailureCode()}, {@link #getFailureMessage()}, and
-     * {@link #getState()} set appropriately, but the {@link Connection} itself should not be used
-     * for anything.
-     *
-     * @param code The failure code ({@see DisconnectCause}).
-     * @param message A reason for why the connection failed (not intended to be shown to the user).
-     * @return A {@link Connection} which indicates failure.
-     */
-    public static Connection createFailedConnection(final int code, final String message) {
-        return new Connection() {{
-            setFailed(code, message);
-        }};
-    }
-
-    private static final Connection CANCELED_CONNECTION = new Connection() {{
-        setCanceled();
-    }};
-
-    /**
-     * Return a {@link Connection} which represents a canceled a connection attempt. The returned
-     * {@link Connection} will have state {@link #STATE_CANCELED}, and cannot be moved out of that
-     * state. This connection should not be used for anything, and no other {@link Connection}s
-     * should be attempted.
-     *
-     * @return A {@link Connection} which indicates that the underlying call should be canceled.
-     */
-    public static Connection createCanceledConnection() {
-        return CANCELED_CONNECTION;
-    }
-
-    private final void  fireOnConferenceableConnectionsChanged() {
-        for (Listener l : mListeners) {
-            l.onConferenceableConnectionsChanged(this, mConferenceableConnections);
-        }
-    }
-
-    private final void clearConferenceableList() {
-        for (Connection c : mConferenceableConnections) {
-            c.removeConnectionListener(mConnectionDeathListener);
-        }
-        mConferenceableConnections.clear();
-    }
-}
diff --git a/telecomm/java/android/telecomm/ConnectionRequest.aidl b/telecomm/java/android/telecomm/ConnectionRequest.aidl
deleted file mode 100644
index 6081c22..0000000
--- a/telecomm/java/android/telecomm/ConnectionRequest.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable ConnectionRequest;
diff --git a/telecomm/java/android/telecomm/ConnectionRequest.java b/telecomm/java/android/telecomm/ConnectionRequest.java
deleted file mode 100644
index 5ea1d1a..0000000
--- a/telecomm/java/android/telecomm/ConnectionRequest.java
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Simple data container encapsulating a request to some entity to
- * create a new {@link Connection}.
- */
-public final class ConnectionRequest implements Parcelable {
-
-    // TODO: Token to limit recursive invocations
-    private final PhoneAccountHandle mAccountHandle;
-    private final Uri mHandle;
-    private final int mHandlePresentation;
-    private final Bundle mExtras;
-    private final int mVideoState;
-
-    /**
-     * @param accountHandle The accountHandle which should be used to place the call.
-     * @param handle The handle (e.g., phone number) to which the {@link Connection} is to connect.
-     * @param handlePresentation The {@link PropertyPresentation} which controls how the handle
-     *         is shown.
-     * @param extras Application-specific extra data.
-     * @param videoState Determines the video state for the connection.
-     */
-    public ConnectionRequest(
-            PhoneAccountHandle accountHandle,
-            Uri handle,
-            int handlePresentation,
-            Bundle extras,
-            int videoState) {
-        mAccountHandle = accountHandle;
-        mHandle = handle;
-        mHandlePresentation = handlePresentation;
-        mExtras = extras;
-        mVideoState = videoState;
-    }
-
-    private ConnectionRequest(Parcel in) {
-        mAccountHandle = in.readParcelable(getClass().getClassLoader());
-        mHandle = in.readParcelable(getClass().getClassLoader());
-        mHandlePresentation = in.readInt();
-        mExtras = in.readParcelable(getClass().getClassLoader());
-        mVideoState = in.readInt();
-    }
-
-    /**
-     * The account which should be used to place the call.
-     */
-    public PhoneAccountHandle getAccountHandle() { return mAccountHandle; }
-
-    /**
-     * The handle (e.g., phone number) to which the {@link Connection} is to connect.
-     */
-    public Uri getHandle() { return mHandle; }
-
-    /**
-     * The {@link PropertyPresentation} which controls how the handle is shown.
-     */
-    public int getHandlePresentation() { return mHandlePresentation; }
-
-    /**
-     * Application-specific extra data. Used for passing back information from an incoming
-     * call {@code Intent}, and for any proprietary extensions arranged between a client
-     * and servant {@code ConnectionService} which agree on a vocabulary for such data.
-     */
-    public Bundle getExtras() { return mExtras; }
-
-    /**
-     * Describes the video states supported by the client requesting the connection.
-     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#TX_ENABLED},
-     * {@link VideoProfile.VideoState#RX_ENABLED}.
-     *
-     * @return The video state for the connection.
-     */
-    public int getVideoState() {
-        return mVideoState;
-    }
-
-    @Override
-    public String toString() {
-        return String.format("ConnectionRequest %s %s",
-                mHandle == null
-                        ? Uri.EMPTY
-                        : Connection.toLogSafePhoneNumber(mHandle.toString()),
-                mExtras == null ? "" : mExtras);
-    }
-
-    public static final Creator<ConnectionRequest> CREATOR = new Creator<ConnectionRequest> () {
-        @Override
-        public ConnectionRequest createFromParcel(Parcel source) {
-            return new ConnectionRequest(source);
-        }
-
-        @Override
-        public ConnectionRequest[] newArray(int size) {
-            return new ConnectionRequest[size];
-        }
-    };
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel destination, int flags) {
-        destination.writeParcelable(mAccountHandle, 0);
-        destination.writeParcelable(mHandle, 0);
-        destination.writeInt(mHandlePresentation);
-        destination.writeParcelable(mExtras, 0);
-        destination.writeInt(mVideoState);
-    }
-}
diff --git a/telecomm/java/android/telecomm/ConnectionService.java b/telecomm/java/android/telecomm/ConnectionService.java
deleted file mode 100644
index d2d4828..0000000
--- a/telecomm/java/android/telecomm/ConnectionService.java
+++ /dev/null
@@ -1,832 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.annotation.SdkConstant;
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.ComponentName;
-import android.content.Intent;
-import android.net.Uri;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Looper;
-import android.os.Message;
-import android.telephony.DisconnectCause;
-
-import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IConnectionService;
-import com.android.internal.telecomm.IConnectionServiceAdapter;
-import com.android.internal.telecomm.RemoteServiceCallback;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-/**
- * A {@link android.app.Service} that provides telephone connections to processes running on an
- * Android device.
- */
-public abstract class ConnectionService extends Service {
-    /**
-     * The {@link Intent} that must be declared as handled by the service.
-     */
-    @SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
-    public static final String SERVICE_INTERFACE = "android.telecomm.ConnectionService";
-
-    // Flag controlling whether PII is emitted into the logs
-    private static final boolean PII_DEBUG = Log.isLoggable(android.util.Log.DEBUG);
-
-    private static final int MSG_ADD_CONNECTION_SERVICE_ADAPTER = 1;
-    private static final int MSG_CREATE_CONNECTION = 2;
-    private static final int MSG_ABORT = 3;
-    private static final int MSG_ANSWER = 4;
-    private static final int MSG_REJECT = 5;
-    private static final int MSG_DISCONNECT = 6;
-    private static final int MSG_HOLD = 7;
-    private static final int MSG_UNHOLD = 8;
-    private static final int MSG_ON_AUDIO_STATE_CHANGED = 9;
-    private static final int MSG_PLAY_DTMF_TONE = 10;
-    private static final int MSG_STOP_DTMF_TONE = 11;
-    private static final int MSG_CONFERENCE = 12;
-    private static final int MSG_SPLIT_FROM_CONFERENCE = 13;
-    private static final int MSG_ON_POST_DIAL_CONTINUE = 14;
-    private static final int MSG_ON_PHONE_ACCOUNT_CLICKED = 15;
-    private static final int MSG_REMOVE_CONNECTION_SERVICE_ADAPTER = 16;
-
-    private final Map<String, Connection> mConnectionById = new HashMap<>();
-    private final Map<Connection, String> mIdByConnection = new HashMap<>();
-    private final RemoteConnectionManager mRemoteConnectionManager = new RemoteConnectionManager();
-
-    private boolean mAreAccountsInitialized = false;
-    private final List<Runnable> mPreInitializationConnectionRequests = new ArrayList<>();
-    private final ConnectionServiceAdapter mAdapter = new ConnectionServiceAdapter();
-
-    private final IBinder mBinder = new IConnectionService.Stub() {
-        @Override
-        public void addConnectionServiceAdapter(IConnectionServiceAdapter adapter) {
-            mHandler.obtainMessage(MSG_ADD_CONNECTION_SERVICE_ADAPTER, adapter).sendToTarget();
-        }
-
-        public void removeConnectionServiceAdapter(IConnectionServiceAdapter adapter) {
-            mHandler.obtainMessage(MSG_REMOVE_CONNECTION_SERVICE_ADAPTER, adapter).sendToTarget();
-        }
-
-        @Override
-        public void createConnection(
-                PhoneAccountHandle connectionManagerPhoneAccount,
-                String id,
-                ConnectionRequest request,
-                boolean isIncoming) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionManagerPhoneAccount;
-            args.arg2 = id;
-            args.arg3 = request;
-            args.argi1 = isIncoming ? 1 : 0;
-            mHandler.obtainMessage(MSG_CREATE_CONNECTION, args).sendToTarget();
-        }
-
-        @Override
-        public void abort(String callId) {
-            mHandler.obtainMessage(MSG_ABORT, callId).sendToTarget();
-        }
-
-        @Override
-        public void answer(String callId, int videoState) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.argi1 = videoState;
-            mHandler.obtainMessage(MSG_ANSWER, args).sendToTarget();
-        }
-
-        @Override
-        public void reject(String callId) {
-            mHandler.obtainMessage(MSG_REJECT, callId).sendToTarget();
-        }
-
-        @Override
-        public void disconnect(String callId) {
-            mHandler.obtainMessage(MSG_DISCONNECT, callId).sendToTarget();
-        }
-
-        @Override
-        public void hold(String callId) {
-            mHandler.obtainMessage(MSG_HOLD, callId).sendToTarget();
-        }
-
-        @Override
-        public void unhold(String callId) {
-            mHandler.obtainMessage(MSG_UNHOLD, callId).sendToTarget();
-        }
-
-        @Override
-        public void onAudioStateChanged(String callId, AudioState audioState) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.arg2 = audioState;
-            mHandler.obtainMessage(MSG_ON_AUDIO_STATE_CHANGED, args).sendToTarget();
-        }
-
-        @Override
-        public void playDtmfTone(String callId, char digit) {
-            mHandler.obtainMessage(MSG_PLAY_DTMF_TONE, digit, 0, callId).sendToTarget();
-        }
-
-        @Override
-        public void stopDtmfTone(String callId) {
-            mHandler.obtainMessage(MSG_STOP_DTMF_TONE, callId).sendToTarget();
-        }
-
-        @Override
-        public void conference(String conferenceCallId, String callId) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = conferenceCallId;
-            args.arg2 = callId;
-            mHandler.obtainMessage(MSG_CONFERENCE, args).sendToTarget();
-        }
-
-        @Override
-        public void splitFromConference(String callId) {
-            mHandler.obtainMessage(MSG_SPLIT_FROM_CONFERENCE, callId).sendToTarget();
-        }
-
-        @Override
-        public void onPostDialContinue(String callId, boolean proceed) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.argi1 = proceed ? 1 : 0;
-            mHandler.obtainMessage(MSG_ON_POST_DIAL_CONTINUE, args).sendToTarget();
-        }
-
-        @Override
-        public void onPhoneAccountClicked(String callId) {
-            mHandler.obtainMessage(MSG_ON_PHONE_ACCOUNT_CLICKED, callId).sendToTarget();
-        }
-    };
-
-    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
-        @Override
-        public void handleMessage(Message msg) {
-            switch (msg.what) {
-                case MSG_ADD_CONNECTION_SERVICE_ADAPTER:
-                    mAdapter.addAdapter((IConnectionServiceAdapter) msg.obj);
-                    onAdapterAttached();
-                    break;
-                case MSG_REMOVE_CONNECTION_SERVICE_ADAPTER:
-                    mAdapter.removeAdapter((IConnectionServiceAdapter) msg.obj);
-                    break;
-                case MSG_CREATE_CONNECTION: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        final PhoneAccountHandle connectionManagerPhoneAccount =
-                                (PhoneAccountHandle) args.arg1;
-                        final String id = (String) args.arg2;
-                        final ConnectionRequest request = (ConnectionRequest) args.arg3;
-                        final boolean isIncoming = args.argi1 == 1;
-                        if (!mAreAccountsInitialized) {
-                            Log.d(this, "Enqueueing pre-init request %s", id);
-                            mPreInitializationConnectionRequests.add(new Runnable() {
-                                @Override
-                                public void run() {
-                                    createConnection(
-                                            connectionManagerPhoneAccount,
-                                            id,
-                                            request,
-                                            isIncoming);
-                                }
-                            });
-                        } else {
-                            createConnection(
-                                    connectionManagerPhoneAccount,
-                                    id,
-                                    request,
-                                    isIncoming);
-                        }
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_ABORT:
-                    abort((String) msg.obj);
-                    break;
-                case MSG_ANSWER: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        String callId = (String) args.arg1;
-                        int videoState = args.argi1;
-                        answer(callId, videoState);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_REJECT:
-                    reject((String) msg.obj);
-                    break;
-                case MSG_DISCONNECT:
-                    disconnect((String) msg.obj);
-                    break;
-                case MSG_HOLD:
-                    hold((String) msg.obj);
-                    break;
-                case MSG_UNHOLD:
-                    unhold((String) msg.obj);
-                    break;
-                case MSG_ON_AUDIO_STATE_CHANGED: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        String callId = (String) args.arg1;
-                        AudioState audioState = (AudioState) args.arg2;
-                        onAudioStateChanged(callId, audioState);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_PLAY_DTMF_TONE:
-                    playDtmfTone((String) msg.obj, (char) msg.arg1);
-                    break;
-                case MSG_STOP_DTMF_TONE:
-                    stopDtmfTone((String) msg.obj);
-                    break;
-                case MSG_CONFERENCE: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        String conferenceCallId = (String) args.arg1;
-                        String callId = (String) args.arg2;
-                        conference(conferenceCallId, callId);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SPLIT_FROM_CONFERENCE:
-                    splitFromConference((String) msg.obj);
-                    break;
-                case MSG_ON_POST_DIAL_CONTINUE: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        String callId = (String) args.arg1;
-                        boolean proceed = (args.argi1 == 1);
-                        onPostDialContinue(callId, proceed);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_ON_PHONE_ACCOUNT_CLICKED:
-                    onPhoneAccountHandleClicked((String) msg.obj);
-                    break;
-                default:
-                    break;
-            }
-        }
-    };
-
-    private final Connection.Listener mConnectionListener = new Connection.Listener() {
-        @Override
-        public void onStateChanged(Connection c, int state) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "Adapter set state %s %s", id, Connection.stateToString(state));
-            switch (state) {
-                case Connection.STATE_ACTIVE:
-                    mAdapter.setActive(id);
-                    break;
-                case Connection.STATE_DIALING:
-                    mAdapter.setDialing(id);
-                    break;
-                case Connection.STATE_DISCONNECTED:
-                    // Handled in onDisconnected()
-                    break;
-                case Connection.STATE_HOLDING:
-                    mAdapter.setOnHold(id);
-                    break;
-                case Connection.STATE_NEW:
-                    // Nothing to tell Telecomm
-                    break;
-                case Connection.STATE_RINGING:
-                    mAdapter.setRinging(id);
-                    break;
-            }
-        }
-
-        @Override
-        public void onDisconnected(Connection c, int cause, String message) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "Adapter set disconnected %d %s", cause, message);
-            mAdapter.setDisconnected(id, cause, message);
-        }
-
-        @Override
-        public void onVideoStateChanged(Connection c, int videoState) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "Adapter set video state %d", videoState);
-            mAdapter.setVideoState(id, videoState);
-        }
-
-        @Override
-        public void onHandleChanged(Connection c, Uri handle, int presentation) {
-            String id = mIdByConnection.get(c);
-            mAdapter.setHandle(id, handle, presentation);
-        }
-
-        @Override
-        public void onCallerDisplayNameChanged(
-                Connection c, String callerDisplayName, int presentation) {
-            String id = mIdByConnection.get(c);
-            mAdapter.setCallerDisplayName(id, callerDisplayName, presentation);
-        }
-
-        @Override
-        public void onDestroyed(Connection c) {
-            removeConnection(c);
-        }
-
-        @Override
-        public void onPostDialWait(Connection c, String remaining) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "Adapter onPostDialWait %s, %s", c, remaining);
-            mAdapter.onPostDialWait(id, remaining);
-        }
-
-        @Override
-        public void onRequestingRingback(Connection c, boolean ringback) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "Adapter onRingback %b", ringback);
-            mAdapter.setRequestingRingback(id, ringback);
-        }
-
-        @Override
-        public void onCallCapabilitiesChanged(Connection c, int capabilities) {
-            String id = mIdByConnection.get(c);
-            Log.d(this, "capabilities: parcelableconnection: %s",
-                    PhoneCapabilities.toString(capabilities));
-            mAdapter.setCallCapabilities(id, capabilities);
-        }
-
-        @Override
-        public void onParentConnectionChanged(Connection c, Connection parent) {
-            String id = mIdByConnection.get(c);
-            String parentId = parent == null ? null : mIdByConnection.get(parent);
-            mAdapter.setIsConferenced(id, parentId);
-        }
-
-        @Override
-        public void onVideoProviderChanged(Connection c, Connection.VideoProvider videoProvider) {
-            String id = mIdByConnection.get(c);
-            mAdapter.setVideoProvider(id, videoProvider);
-        }
-
-        @Override
-        public void onAudioModeIsVoipChanged(Connection c, boolean isVoip) {
-            String id = mIdByConnection.get(c);
-            mAdapter.setAudioModeIsVoip(id, isVoip);
-        }
-
-        @Override
-        public void onStatusHintsChanged(Connection c, StatusHints statusHints) {
-            String id = mIdByConnection.get(c);
-            mAdapter.setStatusHints(id, statusHints);
-        }
-
-        @Override
-        public void onStartActivityFromInCall(Connection c, PendingIntent intent) {
-            String id = mIdByConnection.get(c);
-            mAdapter.startActivityFromInCall(id, intent);
-        }
-
-        @Override
-        public void onConferenceableConnectionsChanged(
-                Connection connection, List<Connection> conferenceableConnections) {
-            String id = mIdByConnection.get(connection);
-            List<String> conferenceableCallIds = new ArrayList<>(conferenceableConnections.size());
-            for (Connection c : conferenceableConnections) {
-                if (mIdByConnection.containsKey(c)) {
-                    conferenceableCallIds.add(mIdByConnection.get(c));
-                }
-            }
-            Collections.sort(conferenceableCallIds);
-            mAdapter.setConferenceableConnections(id, conferenceableCallIds);
-        }
-    };
-
-    /** {@inheritDoc} */
-    @Override
-    public final IBinder onBind(Intent intent) {
-        return mBinder;
-    }
-
-    /**
-     * This can be used by telecomm to either create a new outgoing call or attach to an existing
-     * incoming call. In either case, telecomm will cycle through a set of services and call
-     * createConnection util a connection service cancels the process or completes it successfully.
-     */
-    private void createConnection(
-            final PhoneAccountHandle callManagerAccount,
-            final String callId,
-            final ConnectionRequest request,
-            boolean isIncoming) {
-        Log.d(this, "call %s", request);
-
-        final Connection createdConnection;
-        if (isIncoming) {
-            createdConnection = onCreateIncomingConnection(callManagerAccount, request);
-        } else {
-            createdConnection = onCreateOutgoingConnection(callManagerAccount, request);
-        }
-
-        if (createdConnection != null) {
-            Log.d(this, "adapter handleCreateConnectionSuccessful %s", callId);
-            if (createdConnection.getState() == Connection.STATE_INITIALIZING) {
-                // Wait for the connection to become initialized.
-                createdConnection.addConnectionListener(new Connection.Listener() {
-                    @Override
-                    public void onStateChanged(Connection c, int state) {
-                        switch (state) {
-                            case Connection.STATE_FAILED:
-                                Log.d(this, "Connection (%s) failed (%d: %s)", request,
-                                        c.getFailureCode(), c.getFailureMessage());
-                                Log.d(this, "adapter handleCreateConnectionFailed %s",
-                                        callId);
-                                mAdapter.handleCreateConnectionFailed(
-                                        callId,
-                                        request,
-                                        c.getFailureCode(),
-                                        c.getFailureMessage());
-                                break;
-                            case Connection.STATE_CANCELED:
-                                Log.d(this, "adapter handleCreateConnectionCanceled %s",
-                                        callId);
-                                mAdapter.handleCreateConnectionCancelled(callId, request);
-                                break;
-                            case Connection.STATE_INITIALIZING:
-                                Log.d(this, "State changed to STATE_INITIALIZING; ignoring");
-                                return; // Don't want to stop listening on this state transition.
-                        }
-                        c.removeConnectionListener(this);
-                    }
-                });
-                Log.d(this, "Connection created in state INITIALIZING");
-                connectionCreated(callId, request, createdConnection);
-            } else if (createdConnection.getState() == Connection.STATE_CANCELED) {
-                // Tell telecomm not to attempt any more services.
-                mAdapter.handleCreateConnectionCancelled(callId, request);
-            } else if (createdConnection.getState() == Connection.STATE_FAILED) {
-                mAdapter.handleCreateConnectionFailed(
-                        callId,
-                        request,
-                        createdConnection.getFailureCode(),
-                        createdConnection.getFailureMessage());
-            } else {
-                connectionCreated(callId, request, createdConnection);
-            }
-        } else {
-            // Tell telecomm to try a different service.
-            Log.d(this, "adapter handleCreateConnectionFailed %s", callId);
-            mAdapter.handleCreateConnectionFailed(
-                    callId,
-                    request,
-                    DisconnectCause.ERROR_UNSPECIFIED,
-                    null);
-        }
-    }
-
-    private void connectionCreated(
-            String callId,
-            ConnectionRequest request,
-            Connection connection) {
-        addConnection(callId, connection);
-        Uri handle = connection.getHandle();
-        String number = handle == null ? "null" : handle.getSchemeSpecificPart();
-        Log.v(this, "connectionCreated, parcelableconnection: %s, %d, %s",
-                Connection.toLogSafePhoneNumber(number),
-                connection.getState(),
-                PhoneCapabilities.toString(connection.getCallCapabilities()));
-
-        Log.d(this, "adapter handleCreateConnectionSuccessful %s", callId);
-        mAdapter.handleCreateConnectionSuccessful(
-                callId,
-                request,
-                new ParcelableConnection(
-                        request.getAccountHandle(),
-                        connection.getState(),
-                        connection.getCallCapabilities(),
-                        connection.getHandle(),
-                        connection.getHandlePresentation(),
-                        connection.getCallerDisplayName(),
-                        connection.getCallerDisplayNamePresentation(),
-                        connection.getVideoProvider() == null ?
-                                null : connection.getVideoProvider().getInterface(),
-                        connection.getVideoState(),
-                        connection.isRequestingRingback(),
-                        connection.getAudioModeIsVoip(),
-                        connection.getStatusHints()));
-    }
-
-    private void abort(String callId) {
-        Log.d(this, "abort %s", callId);
-        findConnectionForAction(callId, "abort").onAbort();
-    }
-
-    private void answer(String callId, int videoState) {
-        Log.d(this, "answer %s", callId);
-        findConnectionForAction(callId, "answer").onAnswer(videoState);
-    }
-
-    private void reject(String callId) {
-        Log.d(this, "reject %s", callId);
-        findConnectionForAction(callId, "reject").onReject();
-    }
-
-    private void disconnect(String callId) {
-        Log.d(this, "disconnect %s", callId);
-        findConnectionForAction(callId, "disconnect").onDisconnect();
-    }
-
-    private void hold(String callId) {
-        Log.d(this, "hold %s", callId);
-        findConnectionForAction(callId, "hold").onHold();
-    }
-
-    private void unhold(String callId) {
-        Log.d(this, "unhold %s", callId);
-        findConnectionForAction(callId, "unhold").onUnhold();
-    }
-
-    private void onAudioStateChanged(String callId, AudioState audioState) {
-        Log.d(this, "onAudioStateChanged %s %s", callId, audioState);
-        findConnectionForAction(callId, "onAudioStateChanged").setAudioState(audioState);
-    }
-
-    private void playDtmfTone(String callId, char digit) {
-        Log.d(this, "playDtmfTone %s %c", callId, digit);
-        findConnectionForAction(callId, "playDtmfTone").onPlayDtmfTone(digit);
-    }
-
-    private void stopDtmfTone(String callId) {
-        Log.d(this, "stopDtmfTone %s", callId);
-        findConnectionForAction(callId, "stopDtmfTone").onStopDtmfTone();
-    }
-
-    private void conference(final String conferenceCallId, String callId) {
-        Log.d(this, "conference %s, %s", conferenceCallId, callId);
-
-        Connection connection = findConnectionForAction(callId, "conference");
-        if (connection == Connection.getNullConnection()) {
-            Log.w(this, "Connection missing in conference request %s.", callId);
-            return;
-        }
-
-        onCreateConferenceConnection(conferenceCallId, connection,
-                new Response<String, Connection>() {
-                    /** ${inheritDoc} */
-                    @Override
-                    public void onResult(String ignored, Connection... result) {
-                        Log.d(this, "onCreateConference.Response %s", (Object[]) result);
-                        if (result != null && result.length == 1) {
-                            Connection conferenceConnection = result[0];
-                            if (!mIdByConnection.containsKey(conferenceConnection)) {
-                                Log.v(this, "sending new conference call %s", conferenceCallId);
-                                mAdapter.addConferenceCall(conferenceCallId);
-                                addConnection(conferenceCallId, conferenceConnection);
-                            }
-                        }
-                    }
-
-                    /** ${inheritDoc} */
-                    @Override
-                    public void onError(String request, int code, String reason) {
-                        // no-op
-                    }
-                }
-        );
-    }
-
-    private void splitFromConference(String callId) {
-        Log.d(this, "splitFromConference(%s)", callId);
-
-        Connection connection = findConnectionForAction(callId, "splitFromConference");
-        if (connection == Connection.getNullConnection()) {
-            Log.w(this, "Connection missing in conference request %s.", callId);
-            return;
-        }
-
-        // TODO: Find existing conference call and invoke split(connection).
-    }
-
-    private void onPostDialContinue(String callId, boolean proceed) {
-        Log.d(this, "onPostDialContinue(%s)", callId);
-        findConnectionForAction(callId, "stopDtmfTone").onPostDialContinue(proceed);
-    }
-
-    private void onPhoneAccountHandleClicked(String callId) {
-        Log.d(this, "onPhoneAccountClicked %s", callId);
-        findConnectionForAction(callId, "onPhoneAccountClicked").onPhoneAccountClicked();
-    }
-
-    private void onAdapterAttached() {
-        if (mAreAccountsInitialized) {
-            // No need to query again if we already did it.
-            return;
-        }
-
-        mAdapter.queryRemoteConnectionServices(new RemoteServiceCallback.Stub() {
-            @Override
-            public void onResult(
-                    final List<ComponentName> componentNames,
-                    final List<IBinder> services) {
-                mHandler.post(new Runnable() {
-                    @Override public void run() {
-                        for (int i = 0; i < componentNames.size() && i < services.size(); i++) {
-                            mRemoteConnectionManager.addConnectionService(
-                                    componentNames.get(i),
-                                    IConnectionService.Stub.asInterface(services.get(i)));
-                        }
-                        onAccountsInitialized();
-                        Log.d(this, "remote connection services found: " + services);
-                    }
-                });
-            }
-
-            @Override
-            public void onError() {
-                mHandler.post(new Runnable() {
-                    @Override public void run() {
-                        mAreAccountsInitialized = true;
-                    }
-                });
-            }
-        });
-    }
-
-    /**
-     * Ask some other {@code ConnectionService} to create a {@code RemoteConnection} given an
-     * incoming request. This is used to attach to existing incoming calls.
-     *
-     * @param connectionManagerPhoneAccount See description at
-     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
-     * @param request Details about the incoming call.
-     * @return The {@code Connection} object to satisfy this call, or {@code null} to
-     *         not handle the call.
-     */
-    public final RemoteConnection createRemoteIncomingConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request) {
-        return mRemoteConnectionManager.createRemoteConnection(
-                connectionManagerPhoneAccount, request, true);
-    }
-
-    /**
-     * Ask some other {@code ConnectionService} to create a {@code RemoteConnection} given an
-     * outgoing request. This is used to initiate new outgoing calls.
-     *
-     * @param connectionManagerPhoneAccount See description at
-     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
-     * @param request Details about the incoming call.
-     * @return The {@code Connection} object to satisfy this call, or {@code null} to
-     *         not handle the call.
-     */
-    public final RemoteConnection createRemoteOutgoingConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request) {
-        return mRemoteConnectionManager.createRemoteConnection(
-                connectionManagerPhoneAccount, request, false);
-    }
-
-    /**
-     * Returns all the active {@code Connection}s for which this {@code ConnectionService}
-     * has taken responsibility.
-     *
-     * @return A collection of {@code Connection}s created by this {@code ConnectionService}.
-     */
-    public final Collection<Connection> getAllConnections() {
-        return mConnectionById.values();
-    }
-
-    /**
-     * Create a {@code Connection} given an incoming request. This is used to attach to existing
-     * incoming calls.
-     *
-     * @param connectionManagerPhoneAccount See description at
-     *         {@link #onCreateOutgoingConnection(PhoneAccountHandle, ConnectionRequest)}.
-     * @param request Details about the incoming call.
-     * @return The {@code Connection} object to satisfy this call, or {@code null} to
-     *         not handle the call.
-     */
-    public Connection onCreateIncomingConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request) {
-        return null;
-    }
-
-    /**
-     * Create a {@code Connection} given an outgoing request. This is used to initiate new
-     * outgoing calls.
-     *
-     * @param connectionManagerPhoneAccount The connection manager account to use for managing
-     *         this call.
-     *         <p>
-     *         If this parameter is not {@code null}, it means that this {@code ConnectionService}
-     *         has registered one or more {@code PhoneAccount}s having
-     *         {@link PhoneAccount#CAPABILITY_CONNECTION_MANAGER}. This parameter will contain
-     *         one of these {@code PhoneAccount}s, while the {@code request} will contain another
-     *         (usually but not always distinct) {@code PhoneAccount} to be used for actually
-     *         making the connection.
-     *         <p>
-     *         If this parameter is {@code null}, it means that this {@code ConnectionService} is
-     *         being asked to make a direct connection. The
-     *         {@link ConnectionRequest#getAccountHandle()} of parameter {@code request} will be
-     *         a {@code PhoneAccount} registered by this {@code ConnectionService} to use for
-     *         making the connection.
-     * @param request Details about the outgoing call.
-     * @return The {@code Connection} object to satisfy this call, or the result of an invocation
-     *         of {@link Connection#createFailedConnection(int, String)} to not handle the call.
-     */
-    public Connection onCreateOutgoingConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request) {
-        return null;
-    }
-
-    /**
-     * Returns a new or existing conference connection when the the user elects to convert the
-     * specified connection into a conference call. The specified connection can be any connection
-     * which had previously specified itself as conference-capable including both simple connections
-     * and connections previously returned from this method.
-     * <p>
-     * TODO: To be refactored out with conference call re-engineering<br/>
-     * TODO: Also remove class {@link Response} once this method is removed
-     *
-     * @param connection The connection from which the user opted to start a conference call.
-     * @param token The token to be passed into the response callback.
-     * @param callback The callback for providing the potentially-new conference connection.
-     */
-    public void onCreateConferenceConnection(
-            String token,
-            Connection connection,
-            Response<String, Connection> callback) {}
-
-    /**
-     * Notifies that a connection has been added to this connection service and sent to Telecomm.
-     *
-     * @param connection The connection which was added.
-     */
-    public void onConnectionAdded(Connection connection) {}
-
-    /**
-     * Notified that a connection has been removed from this connection service.
-     *
-     * @param connection The connection which was removed.
-     */
-    public void onConnectionRemoved(Connection connection) {}
-
-    private void onAccountsInitialized() {
-        mAreAccountsInitialized = true;
-        for (Runnable r : mPreInitializationConnectionRequests) {
-            r.run();
-        }
-        mPreInitializationConnectionRequests.clear();
-    }
-
-    private void addConnection(String callId, Connection connection) {
-        mConnectionById.put(callId, connection);
-        mIdByConnection.put(connection, callId);
-        connection.addConnectionListener(mConnectionListener);
-        onConnectionAdded(connection);
-    }
-
-    private void removeConnection(Connection connection) {
-        String id = mIdByConnection.get(connection);
-        connection.removeConnectionListener(mConnectionListener);
-        mConnectionById.remove(mIdByConnection.get(connection));
-        mIdByConnection.remove(connection);
-        onConnectionRemoved(connection);
-        mAdapter.removeCall(id);
-    }
-
-    private Connection findConnectionForAction(String callId, String action) {
-        if (mConnectionById.containsKey(callId)) {
-            return mConnectionById.get(callId);
-        }
-        Log.w(this, "%s - Cannot find Connection %s", action, callId);
-        return Connection.getNullConnection();
-    }
-}
diff --git a/telecomm/java/android/telecomm/ConnectionServiceAdapter.java b/telecomm/java/android/telecomm/ConnectionServiceAdapter.java
deleted file mode 100644
index 4144b81..0000000
--- a/telecomm/java/android/telecomm/ConnectionServiceAdapter.java
+++ /dev/null
@@ -1,381 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.IBinder.DeathRecipient;
-import android.os.RemoteException;
-
-import com.android.internal.telecomm.IConnectionServiceAdapter;
-import com.android.internal.telecomm.RemoteServiceCallback;
-
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-
-/**
- * Provides methods for IConnectionService implementations to interact with the system phone app.
- *
- * @hide
- */
-final class ConnectionServiceAdapter implements DeathRecipient {
-    /**
-     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
-     * load factor before resizing, 1 means we only expect a single thread to
-     * access the map so make only a single shard
-     */
-    private final Set<IConnectionServiceAdapter> mAdapters = Collections.newSetFromMap(
-            new ConcurrentHashMap<IConnectionServiceAdapter, Boolean>(8, 0.9f, 1));
-
-    ConnectionServiceAdapter() {
-    }
-
-    void addAdapter(IConnectionServiceAdapter adapter) {
-        if (mAdapters.add(adapter)) {
-            try {
-                adapter.asBinder().linkToDeath(this, 0);
-            } catch (RemoteException e) {
-                mAdapters.remove(adapter);
-            }
-        }
-    }
-
-    void removeAdapter(IConnectionServiceAdapter adapter) {
-        if (adapter != null && mAdapters.remove(adapter)) {
-            adapter.asBinder().unlinkToDeath(this, 0);
-        }
-    }
-
-    /** ${inheritDoc} */
-    @Override
-    public void binderDied() {
-        Iterator<IConnectionServiceAdapter> it = mAdapters.iterator();
-        while (it.hasNext()) {
-            IConnectionServiceAdapter adapter = it.next();
-            if (!adapter.asBinder().isBinderAlive()) {
-                it.remove();
-                adapter.asBinder().unlinkToDeath(this, 0);
-            }
-        }
-    }
-
-    void handleCreateConnectionSuccessful(
-            String id,
-            ConnectionRequest request,
-            ParcelableConnection connection) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.handleCreateConnectionSuccessful(id, request, connection);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void handleCreateConnectionFailed(
-            String id,
-            ConnectionRequest request,
-            int errorCode,
-            String errorMsg) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.handleCreateConnectionFailed(id, request, errorCode, errorMsg);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void handleCreateConnectionCancelled(
-            String id,
-            ConnectionRequest request) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.handleCreateConnectionCancelled(id, request);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets a call's state to active (e.g., an ongoing call where two parties can actively
-     * communicate).
-     *
-     * @param callId The unique ID of the call whose state is changing to active.
-     */
-    void setActive(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setActive(callId);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets a call's state to ringing (e.g., an inbound ringing call).
-     *
-     * @param callId The unique ID of the call whose state is changing to ringing.
-     */
-    void setRinging(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setRinging(callId);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets a call's state to dialing (e.g., dialing an outbound call).
-     *
-     * @param callId The unique ID of the call whose state is changing to dialing.
-     */
-    void setDialing(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setDialing(callId);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets a call's state to disconnected.
-     *
-     * @param callId The unique ID of the call whose state is changing to disconnected.
-     * @param disconnectCause The reason for the disconnection, any of
-     *            {@link android.telephony.DisconnectCause}.
-     * @param disconnectMessage Optional call-service-provided message about the disconnect.
-     */
-    void setDisconnected(String callId, int disconnectCause, String disconnectMessage) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setDisconnected(callId, disconnectCause, disconnectMessage);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets a call's state to be on hold.
-     *
-     * @param callId - The unique ID of the call whose state is changing to be on hold.
-     */
-    void setOnHold(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setOnHold(callId);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Asks Telecomm to start or stop a ringback tone for a call.
-     *
-     * @param callId The unique ID of the call whose ringback is being changed.
-     * @param ringback Whether Telecomm should start playing a ringback tone.
-     */
-    void setRequestingRingback(String callId, boolean ringback) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setRequestingRingback(callId, ringback);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void setCallCapabilities(String callId, int capabilities) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setCallCapabilities(callId, capabilities);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    /**
-     * Indicates whether or not the specified call is currently conferenced into the specified
-     * conference call.
-     *
-     * @param callId The unique ID of the call being conferenced.
-     * @param conferenceCallId The unique ID of the conference call. Null if call is not
-     *            conferenced.
-     */
-    void setIsConferenced(String callId, String conferenceCallId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setIsConferenced(callId, conferenceCallId);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    /**
-     * Indicates that the call no longer exists. Can be used with either a call or a conference
-     * call.
-     *
-     * @param callId The unique ID of the call.
-     */
-    void removeCall(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.removeCall(callId);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    void onPostDialWait(String callId, String remaining) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.onPostDialWait(callId, remaining);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    /**
-     * Indicates that a new conference call has been created.
-     *
-     * @param callId The unique ID of the conference call.
-     */
-    void addConferenceCall(String callId) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.addConferenceCall(callId);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    /**
-     * Retrieves a list of remote connection services usable to place calls.
-     */
-    void queryRemoteConnectionServices(RemoteServiceCallback callback) {
-        // Only supported when there is only one adapter.
-        if (mAdapters.size() == 1) {
-            try {
-                mAdapters.iterator().next().queryRemoteConnectionServices(callback);
-            } catch (RemoteException e) {
-                Log.e(this, e, "Exception trying to query for remote CSs");
-            }
-        }
-    }
-
-    /**
-     * Sets the call video provider for a call.
-     *
-     * @param callId The unique ID of the call to set with the given call video provider.
-     * @param videoProvider The call video provider instance to set on the call.
-     */
-    void setVideoProvider(
-            String callId, Connection.VideoProvider videoProvider) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setVideoProvider(
-                        callId,
-                        videoProvider == null ? null : videoProvider.getInterface());
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Requests that the framework use VOIP audio mode for this connection.
-     *
-     * @param callId The unique ID of the call to set with the given call video provider.
-     * @param isVoip True if the audio mode is VOIP.
-     */
-    void setAudioModeIsVoip(String callId, boolean isVoip) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setAudioModeIsVoip(callId, isVoip);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void setStatusHints(String callId, StatusHints statusHints) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setStatusHints(callId, statusHints);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void setHandle(String callId, Uri handle, int presentation) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setHandle(callId, handle, presentation);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    void setCallerDisplayName(String callId, String callerDisplayName, int presentation) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setCallerDisplayName(callId, callerDisplayName, presentation);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-
-    /**
-     * Sets the video state associated with a call.
-     *
-     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#TX_ENABLED},
-     * {@link VideoProfile.VideoState#RX_ENABLED}.
-     *
-     * @param callId The unique ID of the call to set the video state for.
-     * @param videoState The video state.
-     */
-    void setVideoState(String callId, int videoState) {
-        Log.v(this, "setVideoState: %d", videoState);
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setVideoState(callId, videoState);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    void setConferenceableConnections(String callId, List<String> conferenceableCallIds) {
-        Log.v(this, "setConferenceableConnections: %s, %s", callId, conferenceableCallIds);
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.setConferenceableConnections(callId, conferenceableCallIds);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    void startActivityFromInCall(String callId, PendingIntent intent) {
-        for (IConnectionServiceAdapter adapter : mAdapters) {
-            try {
-                adapter.startActivityFromInCall(callId, intent);
-            } catch (RemoteException e) {
-            }
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java b/telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java
deleted file mode 100644
index 2632924..0000000
--- a/telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java
+++ /dev/null
@@ -1,419 +0,0 @@
-/*
- * Copyright (C) 2014 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
- R* limitations under the License.
- */
-
-package android.telecomm;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.Handler;
-import android.os.Message;
-import android.os.RemoteException;
-
-import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IConnectionServiceAdapter;
-import com.android.internal.telecomm.IVideoProvider;
-import com.android.internal.telecomm.RemoteServiceCallback;
-
-import java.util.List;
-
-/**
- * A component that provides an RPC servant implementation of {@link IConnectionServiceAdapter},
- * posting incoming messages on the main thread on a client-supplied delegate object.
- *
- * TODO: Generate this and similar classes using a compiler starting from AIDL interfaces.
- *
- * @hide
- */
-final class ConnectionServiceAdapterServant {
-    private static final int MSG_HANDLE_CREATE_CONNECTION_SUCCESSFUL = 1;
-    private static final int MSG_HANDLE_CREATE_CONNECTION_FAILED = 2;
-    private static final int MSG_HANDLE_CREATE_CONNECTION_CANCELLED = 3;
-    private static final int MSG_SET_ACTIVE = 4;
-    private static final int MSG_SET_RINGING = 5;
-    private static final int MSG_SET_DIALING = 6;
-    private static final int MSG_SET_DISCONNECTED = 7;
-    private static final int MSG_SET_ON_HOLD = 8;
-    private static final int MSG_SET_REQUESTING_RINGBACK = 9;
-    private static final int MSG_SET_CALL_CAPABILITIES = 10;
-    private static final int MSG_SET_IS_CONFERENCED = 11;
-    private static final int MSG_ADD_CONFERENCE_CALL = 12;
-    private static final int MSG_REMOVE_CALL = 13;
-    private static final int MSG_ON_POST_DIAL_WAIT = 14;
-    private static final int MSG_QUERY_REMOTE_CALL_SERVICES = 15;
-    private static final int MSG_SET_VIDEO_STATE = 16;
-    private static final int MSG_SET_VIDEO_CALL_PROVIDER = 17;
-    private static final int MSG_SET_AUDIO_MODE_IS_VOIP = 18;
-    private static final int MSG_SET_STATUS_HINTS = 19;
-    private static final int MSG_SET_HANDLE = 20;
-    private static final int MSG_SET_CALLER_DISPLAY_NAME = 21;
-    private static final int MSG_START_ACTIVITY_FROM_IN_CALL = 22;
-    private static final int MSG_SET_CONFERENCEABLE_CONNECTIONS = 23;
-
-    private final IConnectionServiceAdapter mDelegate;
-
-    private final Handler mHandler = new Handler() {
-        @Override
-        public void handleMessage(Message msg) {
-            try {
-                internalHandleMessage(msg);
-            } catch (RemoteException e) {
-            }
-        }
-
-        // Internal method defined to centralize handling of RemoteException
-        private void internalHandleMessage(Message msg) throws RemoteException {
-            switch (msg.what) {
-                case MSG_HANDLE_CREATE_CONNECTION_SUCCESSFUL: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.handleCreateConnectionSuccessful(
-                                (String) args.arg1,
-                                (ConnectionRequest) args.arg2,
-                                (ParcelableConnection) args.arg3);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_HANDLE_CREATE_CONNECTION_FAILED: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.handleCreateConnectionFailed(
-                                (String) args.arg1,
-                                (ConnectionRequest) args.arg2,
-                                args.argi1,
-                                (String) args.arg3);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_HANDLE_CREATE_CONNECTION_CANCELLED: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.handleCreateConnectionCancelled(
-                                (String) args.arg1,
-                                (ConnectionRequest) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_ACTIVE:
-                    mDelegate.setActive((String) msg.obj);
-                    break;
-                case MSG_SET_RINGING:
-                    mDelegate.setRinging((String) msg.obj);
-                    break;
-                case MSG_SET_DIALING:
-                    mDelegate.setDialing((String) msg.obj);
-                    break;
-                case MSG_SET_DISCONNECTED: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setDisconnected(
-                                (String) args.arg1, args.argi1, (String) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_ON_HOLD:
-                    mDelegate.setOnHold((String) msg.obj);
-                    break;
-                case MSG_SET_REQUESTING_RINGBACK:
-                    mDelegate.setRequestingRingback((String) msg.obj, msg.arg1 == 1);
-                    break;
-                case MSG_SET_CALL_CAPABILITIES:
-                    mDelegate.setCallCapabilities((String) msg.obj, msg.arg1);
-                    break;
-                case MSG_SET_IS_CONFERENCED: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setIsConferenced((String) args.arg1, (String) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_ADD_CONFERENCE_CALL:
-                    mDelegate.addConferenceCall((String) msg.obj);
-                    break;
-                case MSG_REMOVE_CALL:
-                    mDelegate.removeCall((String) msg.obj);
-                    break;
-                case MSG_ON_POST_DIAL_WAIT: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.onPostDialWait((String) args.arg1, (String) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_QUERY_REMOTE_CALL_SERVICES:
-                    mDelegate.queryRemoteConnectionServices((RemoteServiceCallback) msg.obj);
-                    break;
-                case MSG_SET_VIDEO_STATE:
-                    mDelegate.setVideoState((String) msg.obj, msg.arg1);
-                    break;
-                case MSG_SET_VIDEO_CALL_PROVIDER: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setVideoProvider((String) args.arg1,
-                                (IVideoProvider) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_AUDIO_MODE_IS_VOIP:
-                    mDelegate.setAudioModeIsVoip((String) msg.obj, msg.arg1 == 1);
-                    break;
-                case MSG_SET_STATUS_HINTS: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setStatusHints((String) args.arg1, (StatusHints) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_HANDLE: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setHandle((String) args.arg1, (Uri) args.arg2, args.argi1);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_CALLER_DISPLAY_NAME: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setCallerDisplayName(
-                                (String) args.arg1, (String) args.arg2, args.argi1);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_START_ACTIVITY_FROM_IN_CALL: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.startActivityFromInCall(
-                                (String) args.arg1, (PendingIntent) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_SET_CONFERENCEABLE_CONNECTIONS: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mDelegate.setConferenceableConnections(
-                                (String) args.arg1, (List<String>) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-            }
-        }
-    };
-
-    private final IConnectionServiceAdapter mStub = new IConnectionServiceAdapter.Stub() {
-        @Override
-        public void handleCreateConnectionSuccessful(
-                String id,
-                ConnectionRequest request,
-                ParcelableConnection connection) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = id;
-            args.arg2 = request;
-            args.arg3 = connection;
-            mHandler.obtainMessage(MSG_HANDLE_CREATE_CONNECTION_SUCCESSFUL, args).sendToTarget();
-        }
-
-        @Override
-        public void handleCreateConnectionFailed(
-                String id,
-                ConnectionRequest request,
-                int errorCode,
-                String errorMessage) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = id;
-            args.arg2 = request;
-            args.argi1 = errorCode;
-            args.arg3 = errorMessage;
-            mHandler.obtainMessage(MSG_HANDLE_CREATE_CONNECTION_FAILED, args).sendToTarget();
-        }
-
-        @Override
-        public void handleCreateConnectionCancelled(
-                String id,
-                ConnectionRequest request) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = id;
-            args.arg2 = request;
-            mHandler.obtainMessage(MSG_HANDLE_CREATE_CONNECTION_CANCELLED, args).sendToTarget();
-        }
-
-        @Override
-        public void setActive(String connectionId) {
-            mHandler.obtainMessage(MSG_SET_ACTIVE, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void setRinging(String connectionId) {
-            mHandler.obtainMessage(MSG_SET_RINGING, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void setDialing(String connectionId) {
-            mHandler.obtainMessage(MSG_SET_DIALING, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void setDisconnected(
-                String connectionId, int disconnectCause, String disconnectMessage) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = disconnectMessage;
-            args.argi1 = disconnectCause;
-            mHandler.obtainMessage(MSG_SET_DISCONNECTED, args).sendToTarget();
-        }
-
-        @Override
-        public void setOnHold(String connectionId) {
-            mHandler.obtainMessage(MSG_SET_ON_HOLD, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void setRequestingRingback(String connectionId, boolean ringback) {
-            mHandler.obtainMessage(MSG_SET_REQUESTING_RINGBACK, ringback ? 1 : 0, 0, connectionId)
-                    .sendToTarget();
-        }
-
-        @Override
-        public void setCallCapabilities(String connectionId, int callCapabilities) {
-            mHandler.obtainMessage(MSG_SET_CALL_CAPABILITIES, callCapabilities, 0, connectionId)
-                    .sendToTarget();
-        }
-
-        @Override
-        public void setIsConferenced(String callId, String conferenceCallId) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.arg2 = conferenceCallId;
-            mHandler.obtainMessage(MSG_SET_IS_CONFERENCED, args).sendToTarget();
-        }
-
-        @Override
-        public void addConferenceCall(String callId) {
-            mHandler.obtainMessage(MSG_ADD_CONFERENCE_CALL, callId).sendToTarget();
-        }
-
-        @Override
-        public void removeCall(String connectionId) {
-            mHandler.obtainMessage(MSG_REMOVE_CALL, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void onPostDialWait(String connectionId, String remainingDigits) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = remainingDigits;
-            mHandler.obtainMessage(MSG_ON_POST_DIAL_WAIT, args).sendToTarget();
-        }
-
-        @Override
-        public void queryRemoteConnectionServices(RemoteServiceCallback callback) {
-            mHandler.obtainMessage(MSG_QUERY_REMOTE_CALL_SERVICES, callback).sendToTarget();
-        }
-
-        @Override
-        public void setVideoState(String connectionId, int videoState) {
-            mHandler.obtainMessage(MSG_SET_VIDEO_STATE, videoState, 0, connectionId).sendToTarget();
-        }
-
-        @Override
-        public void setVideoProvider(String connectionId, IVideoProvider videoProvider) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = videoProvider;
-            mHandler.obtainMessage(MSG_SET_VIDEO_CALL_PROVIDER, args).sendToTarget();
-        }
-
-        @Override
-        public final void setAudioModeIsVoip(String connectionId, boolean isVoip) {
-            mHandler.obtainMessage(MSG_SET_AUDIO_MODE_IS_VOIP, isVoip ? 1 : 0, 0,
-                    connectionId).sendToTarget();
-        }
-
-        @Override
-        public final void setStatusHints(String connectionId, StatusHints statusHints) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = statusHints;
-            mHandler.obtainMessage(MSG_SET_STATUS_HINTS, args).sendToTarget();
-        }
-
-        @Override
-        public final void setHandle(String connectionId, Uri handle, int presentation) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = handle;
-            args.argi1 = presentation;
-            mHandler.obtainMessage(MSG_SET_HANDLE, args).sendToTarget();
-        }
-
-        @Override
-        public final void setCallerDisplayName(
-                String connectionId, String callerDisplayName, int presentation) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = callerDisplayName;
-            args.argi1 = presentation;
-            mHandler.obtainMessage(MSG_SET_CALLER_DISPLAY_NAME, args).sendToTarget();
-        }
-
-        @Override
-        public final void startActivityFromInCall(String connectionId, PendingIntent intent) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = intent;
-            mHandler.obtainMessage(MSG_START_ACTIVITY_FROM_IN_CALL, args).sendToTarget();
-        }
-
-        @Override
-        public final void setConferenceableConnections(
-                String connectionId, List<String> conferenceableConnectionIds) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = connectionId;
-            args.arg2 = conferenceableConnectionIds;
-            mHandler.obtainMessage(MSG_SET_CONFERENCEABLE_CONNECTIONS, args).sendToTarget();
-        }
-    };
-
-    public ConnectionServiceAdapterServant(IConnectionServiceAdapter delegate) {
-        mDelegate = delegate;
-    }
-
-    public IConnectionServiceAdapter getStub() {
-        return mStub;
-    }
-}
diff --git a/telecomm/java/android/telecomm/GatewayInfo.aidl b/telecomm/java/android/telecomm/GatewayInfo.aidl
deleted file mode 100644
index bd81014..0000000
--- a/telecomm/java/android/telecomm/GatewayInfo.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable GatewayInfo;
diff --git a/telecomm/java/android/telecomm/GatewayInfo.java b/telecomm/java/android/telecomm/GatewayInfo.java
deleted file mode 100644
index b95e6b6..0000000
--- a/telecomm/java/android/telecomm/GatewayInfo.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-import android.net.Uri;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.text.TextUtils;
-
-/**
- * When calls are made, they may contain gateway information for services which route phone calls
- * through their own service/numbers. The data consists of a number to call and the package name of
- * the service. This data is used in two ways:
- * <ol>
- * <li> Call the appropriate routing number
- * <li> Display information about how the call is being routed to the user
- * </ol>
- */
-public class GatewayInfo implements Parcelable {
-
-    private final String mGatewayProviderPackageName;
-    private final Uri mGatewayHandle;
-    private final Uri mOriginalHandle;
-
-    /** @hide */
-    public GatewayInfo(String packageName, Uri gatewayUri, Uri originalHandle) {
-        mGatewayProviderPackageName = packageName;
-        mGatewayHandle = gatewayUri;
-        mOriginalHandle = originalHandle;
-    }
-
-    /**
-     * Package name of the gateway provider service. used to place the call with.
-     */
-    public String getGatewayProviderPackageName() {
-        return mGatewayProviderPackageName;
-    }
-
-    /**
-     * Gateway provider handle to use when actually placing the call.
-     */
-    public Uri getGatewayHandle() {
-        return mGatewayHandle;
-    }
-
-    /**
-     * The actual call handle that the user is trying to connect to via the gateway.
-     */
-    public Uri getOriginalHandle() {
-        return mOriginalHandle;
-    }
-
-    public boolean isEmpty() {
-        return TextUtils.isEmpty(mGatewayProviderPackageName) || mGatewayHandle == null;
-    }
-
-    /** Implement the Parcelable interface */
-    public static final Parcelable.Creator<GatewayInfo> CREATOR =
-            new Parcelable.Creator<GatewayInfo> () {
-
-        @Override
-        public GatewayInfo createFromParcel(Parcel source) {
-            String gatewayPackageName = source.readString();
-            Uri gatewayUri = Uri.CREATOR.createFromParcel(source);
-            Uri originalHandle = Uri.CREATOR.createFromParcel(source);
-            return new GatewayInfo(gatewayPackageName, gatewayUri, originalHandle);
-        }
-
-        @Override
-        public GatewayInfo[] newArray(int size) {
-            return new GatewayInfo[size];
-        }
-    };
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /**
-     * {@inheritDoc}
-     */
-    @Override
-    public void writeToParcel(Parcel destination, int flags) {
-        destination.writeString(mGatewayProviderPackageName);
-        mGatewayHandle.writeToParcel(destination, 0);
-        mOriginalHandle.writeToParcel(destination, 0);
-    }
-}
diff --git a/telecomm/java/android/telecomm/InCallAdapter.java b/telecomm/java/android/telecomm/InCallAdapter.java
deleted file mode 100644
index 80f7b57..0000000
--- a/telecomm/java/android/telecomm/InCallAdapter.java
+++ /dev/null
@@ -1,266 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.os.RemoteException;
-
-import com.android.internal.telecomm.IInCallAdapter;
-
-/**
- * Receives commands from {@link InCallService} implementations which should be executed by
- * Telecomm. When Telecomm binds to a {@link InCallService}, an instance of this class is given to
- * the in-call service through which it can manipulate live (active, dialing, ringing) calls. When
- * the in-call service is notified of new calls, it can use the
- * given call IDs to execute commands such as {@link #answerCall} for incoming calls or
- * {@link #disconnectCall} for active calls the user would like to end. Some commands are only
- * appropriate for calls in certain states; please consult each method for such limitations.
- * <p>
- * The adapter will stop functioning when there are no more calls.
- *
- * {@hide}
- */
-public final class InCallAdapter {
-    private final IInCallAdapter mAdapter;
-
-    /**
-     * {@hide}
-     */
-    public InCallAdapter(IInCallAdapter adapter) {
-        mAdapter = adapter;
-    }
-
-    /**
-     * Instructs Telecomm to answer the specified call.
-     *
-     * @param callId The identifier of the call to answer.
-     * @param videoState The video state in which to answer the call.
-     */
-    public void answerCall(String callId, int videoState) {
-        try {
-            mAdapter.answerCall(callId, videoState);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to reject the specified call.
-     *
-     * @param callId The identifier of the call to reject.
-     * @param rejectWithMessage Whether to reject with a text message.
-     * @param textMessage An optional text message with which to respond.
-     */
-    public void rejectCall(String callId, boolean rejectWithMessage, String textMessage) {
-        try {
-            mAdapter.rejectCall(callId, rejectWithMessage, textMessage);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to disconnect the specified call.
-     *
-     * @param callId The identifier of the call to disconnect.
-     */
-    public void disconnectCall(String callId) {
-        try {
-            mAdapter.disconnectCall(callId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to put the specified call on hold.
-     *
-     * @param callId The identifier of the call to put on hold.
-     */
-    public void holdCall(String callId) {
-        try {
-            mAdapter.holdCall(callId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to release the specified call from hold.
-     *
-     * @param callId The identifier of the call to release from hold.
-     */
-    public void unholdCall(String callId) {
-        try {
-            mAdapter.unholdCall(callId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Mute the microphone.
-     *
-     * @param shouldMute True if the microphone should be muted.
-     */
-    public void mute(boolean shouldMute) {
-        try {
-            mAdapter.mute(shouldMute);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Sets the audio route (speaker, bluetooth, etc...). See {@link AudioState}.
-     *
-     * @param route The audio route to use.
-     */
-    public void setAudioRoute(int route) {
-        try {
-            mAdapter.setAudioRoute(route);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to play a dual-tone multi-frequency signaling (DTMF) tone in a call.
-     *
-     * Any other currently playing DTMF tone in the specified call is immediately stopped.
-     *
-     * @param callId The unique ID of the call in which the tone will be played.
-     * @param digit A character representing the DTMF digit for which to play the tone. This
-     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
-     */
-    public void playDtmfTone(String callId, char digit) {
-        try {
-            mAdapter.playDtmfTone(callId, digit);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to stop any dual-tone multi-frequency signaling (DTMF) tone currently
-     * playing.
-     *
-     * DTMF tones are played by calling {@link #playDtmfTone(String,char)}. If no DTMF tone is
-     * currently playing, this method will do nothing.
-     *
-     * @param callId The unique ID of the call in which any currently playing tone will be stopped.
-     */
-    public void stopDtmfTone(String callId) {
-        try {
-            mAdapter.stopDtmfTone(callId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to continue playing a post-dial DTMF string.
-     *
-     * A post-dial DTMF string is a string of digits entered after a phone number, when dialed,
-     * that are immediately sent as DTMF tones to the recipient as soon as the connection is made.
-     * While these tones are playing, Telecomm will notify the {@link InCallService} that the call
-     * is in the post dial state.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_PAUSE} symbol, Telecomm
-     * will temporarily pause playing the tones for a pre-defined period of time.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_WAIT} symbol, Telecomm
-     * will pause playing the tones and notify the {@link InCallService} that the call is in the
-     * post dial wait state. When the user decides to continue the postdial sequence, the
-     * {@link InCallService} should invoke the {@link #postDialContinue(String,boolean)} method.
-     *
-     * @param callId The unique ID of the call for which postdial string playing should continue.
-     * @param proceed Whether or not to continue with the post-dial sequence.
-     */
-    public void postDialContinue(String callId, boolean proceed) {
-        try {
-            mAdapter.postDialContinue(callId, proceed);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm that the phone account UI was clicked.
-     *
-     * @param callId The identifier of the call.
-     */
-    public void phoneAccountClicked(String callId) {
-        try {
-            mAdapter.phoneAccountClicked(callId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to add a PhoneAccountHandle to the specified call
-     *
-     * @param callId The identifier of the call
-     * @param accountHandle The PhoneAccountHandle through which to place the call
-     */
-    public void phoneAccountSelected(String callId, PhoneAccountHandle accountHandle) {
-        try {
-            mAdapter.phoneAccountSelected(callId, accountHandle);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to conference the specified call.
-     *
-     * @param callId The unique ID of the call.
-     * @hide
-     */
-    public void conference(String callId, String otherCallId) {
-        try {
-            mAdapter.conference(callId, otherCallId);
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to split the specified call from any conference call with which it may be
-     * connected.
-     *
-     * @param callId The unique ID of the call.
-     * @hide
-     */
-    public void splitFromConference(String callId) {
-        try {
-            mAdapter.splitFromConference(callId);
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to turn the proximity sensor on.
-     */
-    public void turnProximitySensorOn() {
-        try {
-            mAdapter.turnOnProximitySensor();
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs Telecomm to turn the proximity sensor off.
-     *
-     * @param screenOnImmediately If true, the screen will be turned on immediately if it was
-     * previously off. Otherwise, the screen will only be turned on after the proximity sensor
-     * is no longer triggered.
-     */
-    public void turnProximitySensorOff(boolean screenOnImmediately) {
-        try {
-            mAdapter.turnOffProximitySensor(screenOnImmediately);
-        } catch (RemoteException ignored) {
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/InCallService.java b/telecomm/java/android/telecomm/InCallService.java
deleted file mode 100644
index de05d1c..0000000
--- a/telecomm/java/android/telecomm/InCallService.java
+++ /dev/null
@@ -1,360 +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 android.telecomm;
-
-import android.app.PendingIntent;
-import android.app.Service;
-import android.content.Intent;
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Looper;
-import android.os.Message;
-import android.view.Surface;
-
-import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IInCallAdapter;
-import com.android.internal.telecomm.IInCallService;
-
-import java.lang.String;
-
-/**
- * This service is implemented by any app that wishes to provide the user-interface for managing
- * phone calls. Telecomm binds to this service while there exists a live (active or incoming) call,
- * and uses it to notify the in-call app of any live and and recently disconnected calls.
- *
- * {@hide}
- */
-public abstract class InCallService extends Service {
-    private static final int MSG_SET_IN_CALL_ADAPTER = 1;
-    private static final int MSG_ADD_CALL = 2;
-    private static final int MSG_UPDATE_CALL = 3;
-    private static final int MSG_SET_POST_DIAL_WAIT = 4;
-    private static final int MSG_ON_AUDIO_STATE_CHANGED = 5;
-    private static final int MSG_BRING_TO_FOREGROUND = 6;
-    private static final int MSG_START_ACTIVITY = 7;
-
-    /** Default Handler used to consolidate binder method calls onto a single thread. */
-    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
-        @Override
-        public void handleMessage(Message msg) {
-            switch (msg.what) {
-                case MSG_SET_IN_CALL_ADAPTER:
-                    mPhone = new Phone(new InCallAdapter((IInCallAdapter) msg.obj));
-                    onPhoneCreated(mPhone);
-                    break;
-                case MSG_ADD_CALL:
-                    mPhone.internalAddCall((ParcelableCall) msg.obj);
-                    break;
-                case MSG_UPDATE_CALL:
-                    mPhone.internalUpdateCall((ParcelableCall) msg.obj);
-                    break;
-                case MSG_SET_POST_DIAL_WAIT: {
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        String callId = (String) args.arg1;
-                        String remaining = (String) args.arg2;
-                        mPhone.internalSetPostDialWait(callId, remaining);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                }
-                case MSG_ON_AUDIO_STATE_CHANGED:
-                    mPhone.internalAudioStateChanged((AudioState) msg.obj);
-                    break;
-                case MSG_BRING_TO_FOREGROUND:
-                    mPhone.internalBringToForeground(msg.arg1 == 1);
-                    break;
-                case MSG_START_ACTIVITY:
-                    SomeArgs args = (SomeArgs) msg.obj;
-                    try {
-                        mPhone.internalStartActivity(
-                                (String) args.arg1, (PendingIntent) args.arg2);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                default:
-                    break;
-            }
-        }
-    };
-
-    /** Manages the binder calls so that the implementor does not need to deal with it. */
-    private final class InCallServiceBinder extends IInCallService.Stub {
-        @Override
-        public void setInCallAdapter(IInCallAdapter inCallAdapter) {
-            mHandler.obtainMessage(MSG_SET_IN_CALL_ADAPTER, inCallAdapter).sendToTarget();
-        }
-
-        @Override
-        public void addCall(ParcelableCall call) {
-            mHandler.obtainMessage(MSG_ADD_CALL, call).sendToTarget();
-        }
-
-        @Override
-        public void updateCall(ParcelableCall call) {
-            mHandler.obtainMessage(MSG_UPDATE_CALL, call).sendToTarget();
-        }
-
-        @Override
-        public void setPostDial(String callId, String remaining) {
-            // TODO: Unused
-        }
-
-        @Override
-        public void setPostDialWait(String callId, String remaining) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.arg2 = remaining;
-            mHandler.obtainMessage(MSG_SET_POST_DIAL_WAIT, args).sendToTarget();
-        }
-
-        @Override
-        public void onAudioStateChanged(AudioState audioState) {
-            mHandler.obtainMessage(MSG_ON_AUDIO_STATE_CHANGED, audioState).sendToTarget();
-        }
-
-        @Override
-        public void bringToForeground(boolean showDialpad) {
-            mHandler.obtainMessage(MSG_BRING_TO_FOREGROUND, showDialpad ? 1 : 0, 0).sendToTarget();
-        }
-
-        @Override
-        public void startActivity(String callId, PendingIntent intent) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = callId;
-            args.arg2 = intent;
-            mHandler.obtainMessage(MSG_START_ACTIVITY, args).sendToTarget();
-        }
-    }
-
-    private Phone mPhone;
-
-    public InCallService() {
-    }
-
-    @Override
-    public IBinder onBind(Intent intent) {
-        return new InCallServiceBinder();
-    }
-
-    /**
-     * Obtain the {@code Phone} associated with this {@code InCallService}.
-     *
-     * @return The {@code Phone} object associated with this {@code InCallService}, or {@code null}
-     *         if the {@code InCallService} is not in a state where it has an associated
-     *         {@code Phone}.
-     */
-    public Phone getPhone() {
-        return mPhone;
-    }
-
-    /**
-     * Invoked when the {@code Phone} has been created. This is a signal to the in-call experience
-     * to start displaying in-call information to the user. Each instance of {@code InCallService}
-     * will have only one {@code Phone}, and this method will be called exactly once in the lifetime
-     * of the {@code InCallService}.
-     *
-     * @param phone The {@code Phone} object associated with this {@code InCallService}.
-     */
-    public void onPhoneCreated(Phone phone) {
-    }
-
-    /**
-     * Invoked when a {@code Phone} has been destroyed. This is a signal to the in-call experience
-     * to stop displaying in-call information to the user. This method will be called exactly once
-     * in the lifetime of the {@code InCallService}, and it will always be called after a previous
-     * call to {@link #onPhoneCreated(Phone)}.
-     *
-     * @param phone The {@code Phone} object associated with this {@code InCallService}.
-     */
-    public void onPhoneDestroyed(Phone phone) {
-    }
-
-    /**
-     * Class to invoke functionality related to video calls.
-     */
-    public static abstract class VideoCall {
-
-        /**
-         * Sets a listener to invoke callback methods in the InCallUI after performing video
-         * telephony actions.
-         *
-         * @param videoCallListener The call video client.
-         */
-        public abstract void setVideoCallListener(VideoCall.Listener videoCallListener);
-
-        /**
-         * Sets the camera to be used for video recording in a video call.
-         *
-         * @param cameraId The id of the camera.
-         */
-        public abstract void setCamera(String cameraId);
-
-        /**
-         * Sets the surface to be used for displaying a preview of what the user's camera is
-         * currently capturing.  When video transmission is enabled, this is the video signal which
-         * is sent to the remote device.
-         *
-         * @param surface The surface.
-         */
-        public abstract void setPreviewSurface(Surface surface);
-
-        /**
-         * Sets the surface to be used for displaying the video received from the remote device.
-         *
-         * @param surface The surface.
-         */
-        public abstract void setDisplaySurface(Surface surface);
-
-        /**
-         * Sets the device orientation, in degrees.  Assumes that a standard portrait orientation of
-         * the device is 0 degrees.
-         *
-         * @param rotation The device orientation, in degrees.
-         */
-        public abstract void setDeviceOrientation(int rotation);
-
-        /**
-         * Sets camera zoom ratio.
-         *
-         * @param value The camera zoom ratio.
-         */
-        public abstract void setZoom(float value);
-
-        /**
-         * Issues a request to modify the properties of the current session.  The request is sent to
-         * the remote device where it it handled by
-         * {@link VideoCall.Listener#onSessionModifyRequestReceived}.
-         * Some examples of session modification requests: upgrade call from audio to video,
-         * downgrade call from video to audio, pause video.
-         *
-         * @param requestProfile The requested call video properties.
-         */
-        public abstract void sendSessionModifyRequest(VideoProfile requestProfile);
-
-        /**
-         * Provides a response to a request to change the current call session video
-         * properties.
-         * This is in response to a request the InCall UI has received via
-         * {@link VideoCall.Listener#onSessionModifyRequestReceived}.
-         * The response is handled on the remove device by
-         * {@link VideoCall.Listener#onSessionModifyResponseReceived}.
-         *
-         * @param responseProfile The response call video properties.
-         */
-        public abstract void sendSessionModifyResponse(VideoProfile responseProfile);
-
-        /**
-         * Issues a request to the video provider to retrieve the camera capabilities.
-         * Camera capabilities are reported back to the caller via
-         * {@link VideoCall.Listener#onCameraCapabilitiesChanged(CameraCapabilities)}.
-         */
-        public abstract void requestCameraCapabilities();
-
-        /**
-         * Issues a request to the video telephony framework to retrieve the cumulative data usage for
-         * the current call.  Data usage is reported back to the caller via
-         * {@link VideoCall.Listener#onCallDataUsageChanged}.
-         */
-        public abstract void requestCallDataUsage();
-
-        /**
-         * Provides the video telephony framework with the URI of an image to be displayed to remote
-         * devices when the video signal is paused.
-         *
-         * @param uri URI of image to display.
-         */
-        public abstract void setPauseImage(String uri);
-
-        /**
-         * Listener class which invokes callbacks after video call actions occur.
-         */
-        public static abstract class Listener {
-            /**
-             * Called when a session modification request is received from the remote device.
-             * The remote request is sent via
-             * {@link Connection.VideoProvider#onSendSessionModifyRequest}. The InCall UI
-             * is responsible for potentially prompting the user whether they wish to accept the new
-             * call profile (e.g. prompt user if they wish to accept an upgrade from an audio to a
-             * video call) and should call
-             * {@link Connection.VideoProvider#onSendSessionModifyResponse} to indicate
-             * the video settings the user has agreed to.
-             *
-             * @param videoProfile The requested video call profile.
-             */
-            public abstract void onSessionModifyRequestReceived(VideoProfile videoProfile);
-
-            /**
-             * Called when a response to a session modification request is received from the remote
-             * device. The remote InCall UI sends the response using
-             * {@link Connection.VideoProvider#onSendSessionModifyResponse}.
-             *
-             * @param status Status of the session modify request.  Valid values are
-             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_SUCCESS},
-             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_FAIL},
-             *               {@link Connection.VideoProvider#SESSION_MODIFY_REQUEST_INVALID}
-             * @param requestedProfile The original request which was sent to the remote device.
-             * @param responseProfile The actual profile changes made by the remote device.
-             */
-            public abstract void onSessionModifyResponseReceived(int status,
-                    VideoProfile requestedProfile, VideoProfile responseProfile);
-
-            /**
-             * Handles events related to the current session which the client may wish to handle.
-             * These are separate from requested changes to the session due to the underlying
-             * protocol or connection.
-             *
-             * Valid values are:
-             * {@link Connection.VideoProvider#SESSION_EVENT_RX_PAUSE},
-             * {@link Connection.VideoProvider#SESSION_EVENT_RX_RESUME},
-             * {@link Connection.VideoProvider#SESSION_EVENT_TX_START},
-             * {@link Connection.VideoProvider#SESSION_EVENT_TX_STOP},
-             * {@link Connection.VideoProvider#SESSION_EVENT_CAMERA_FAILURE},
-             * {@link Connection.VideoProvider#SESSION_EVENT_CAMERA_READY}
-             *
-             * @param event The event.
-             */
-            public abstract void onCallSessionEvent(int event);
-
-            /**
-             * Handles a change to the video dimensions from the remote caller (peer). This could
-             * happen if, for example, the peer changes orientation of their device.
-             *
-             * @param width  The updated peer video width.
-             * @param height The updated peer video height.
-             */
-            public abstract void onPeerDimensionsChanged(int width, int height);
-
-            /**
-             * Handles an update to the total data used for the current session.
-             *
-             * @param dataUsage The updated data usage.
-             */
-            public abstract void onCallDataUsageChanged(int dataUsage);
-
-            /**
-             * Handles a change in camera capabilities.
-             *
-             * @param cameraCapabilities The changed camera capabilities.
-             */
-            public abstract void onCameraCapabilitiesChanged(
-                    CameraCapabilities cameraCapabilities);
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/Log.java b/telecomm/java/android/telecomm/Log.java
deleted file mode 100644
index b8dfb11..0000000
--- a/telecomm/java/android/telecomm/Log.java
+++ /dev/null
@@ -1,181 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-import java.security.MessageDigest;
-import java.security.NoSuchAlgorithmException;
-import java.util.IllegalFormatException;
-import java.util.Locale;
-
-/**
- * Manages logging for the entire module.
- *
- * @hide
- */
-final public class Log {
-
-    // Generic tag for all Telecomm Framework logging
-    private static final String TAG = "TelecommFramework";
-
-    public static final boolean FORCE_LOGGING = true; /* STOP SHIP if true */
-    public static final boolean DEBUG = isLoggable(android.util.Log.DEBUG);
-    public static final boolean INFO = isLoggable(android.util.Log.INFO);
-    public static final boolean VERBOSE = isLoggable(android.util.Log.VERBOSE);
-    public static final boolean WARN = isLoggable(android.util.Log.WARN);
-    public static final boolean ERROR = isLoggable(android.util.Log.ERROR);
-
-    private Log() {}
-
-    public static boolean isLoggable(int level) {
-        return FORCE_LOGGING || android.util.Log.isLoggable(TAG, level);
-    }
-
-    public static void d(String prefix, String format, Object... args) {
-        if (DEBUG) {
-            android.util.Log.d(TAG, buildMessage(prefix, format, args));
-        }
-    }
-
-    public static void d(Object objectPrefix, String format, Object... args) {
-        if (DEBUG) {
-            android.util.Log.d(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
-        }
-    }
-
-    public static void i(String prefix, String format, Object... args) {
-        if (INFO) {
-            android.util.Log.i(TAG, buildMessage(prefix, format, args));
-        }
-    }
-
-    public static void i(Object objectPrefix, String format, Object... args) {
-        if (INFO) {
-            android.util.Log.i(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
-        }
-    }
-
-    public static void v(String prefix, String format, Object... args) {
-        if (VERBOSE) {
-            android.util.Log.v(TAG, buildMessage(prefix, format, args));
-        }
-    }
-
-    public static void v(Object objectPrefix, String format, Object... args) {
-        if (VERBOSE) {
-            android.util.Log.v(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
-        }
-    }
-
-    public static void w(String prefix, String format, Object... args) {
-        if (WARN) {
-            android.util.Log.w(TAG, buildMessage(prefix, format, args));
-        }
-    }
-
-    public static void w(Object objectPrefix, String format, Object... args) {
-        if (WARN) {
-            android.util.Log.w(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args));
-        }
-    }
-
-    public static void e(String prefix, Throwable tr, String format, Object... args) {
-        if (ERROR) {
-            android.util.Log.e(TAG, buildMessage(prefix, format, args), tr);
-        }
-    }
-
-    public static void e(Object objectPrefix, Throwable tr, String format, Object... args) {
-        if (ERROR) {
-            android.util.Log.e(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args),
-                    tr);
-        }
-    }
-
-    public static void wtf(String prefix, Throwable tr, String format, Object... args) {
-        android.util.Log.wtf(TAG, buildMessage(prefix, format, args), tr);
-    }
-
-    public static void wtf(Object objectPrefix, Throwable tr, String format, Object... args) {
-        android.util.Log.wtf(TAG, buildMessage(getPrefixFromObject(objectPrefix), format, args),
-                tr);
-    }
-
-    public static void wtf(String prefix, String format, Object... args) {
-        String msg = buildMessage(prefix, format, args);
-        android.util.Log.wtf(TAG, msg, new IllegalStateException(msg));
-    }
-
-    public static void wtf(Object objectPrefix, String format, Object... args) {
-        String msg = buildMessage(getPrefixFromObject(objectPrefix), format, args);
-        android.util.Log.wtf(TAG, msg, new IllegalStateException(msg));
-    }
-
-    /**
-     * Redact personally identifiable information for production users.
-     * If we are running in verbose mode, return the original string, otherwise
-     * return a SHA-1 hash of the input string.
-     */
-    public static String pii(Object pii) {
-        if (pii == null || VERBOSE) {
-            return String.valueOf(pii);
-        }
-        return "[" + secureHash(String.valueOf(pii).getBytes()) + "]";
-    }
-
-    private static String secureHash(byte[] input) {
-        MessageDigest messageDigest;
-        try {
-            messageDigest = MessageDigest.getInstance("SHA-1");
-        } catch (NoSuchAlgorithmException e) {
-            return null;
-        }
-        messageDigest.update(input);
-        byte[] result = messageDigest.digest();
-        return encodeHex(result);
-    }
-
-    private static String encodeHex(byte[] bytes) {
-        StringBuffer hex = new StringBuffer(bytes.length * 2);
-
-        for (int i = 0; i < bytes.length; i++) {
-            int byteIntValue = bytes[i] & 0xff;
-            if (byteIntValue < 0x10) {
-                hex.append("0");
-            }
-            hex.append(Integer.toString(byteIntValue, 16));
-        }
-
-        return hex.toString();
-    }
-
-    private static String getPrefixFromObject(Object obj) {
-        return obj == null ? "<null>" : obj.getClass().getSimpleName();
-    }
-
-    private static String buildMessage(String prefix, String format, Object... args) {
-        String msg;
-        try {
-            msg = (args == null || args.length == 0) ? format
-                    : String.format(Locale.US, format, args);
-        } catch (IllegalFormatException ife) {
-            wtf("Log", ife, "IllegalFormatException: formatString='%s' numArgs=%d", format,
-                    args.length);
-            msg = format + " (An error occurred while formatting the message.)";
-        }
-        return String.format(Locale.US, "%s: %s", prefix, msg);
-    }
-}
diff --git a/telecomm/java/android/telecomm/ParcelableCall.aidl b/telecomm/java/android/telecomm/ParcelableCall.aidl
deleted file mode 100644
index 18691d2..0000000
--- a/telecomm/java/android/telecomm/ParcelableCall.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable ParcelableCall;
diff --git a/telecomm/java/android/telecomm/ParcelableCall.java b/telecomm/java/android/telecomm/ParcelableCall.java
deleted file mode 100644
index 8098b94..0000000
--- a/telecomm/java/android/telecomm/ParcelableCall.java
+++ /dev/null
@@ -1,315 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.os.RemoteException;
-import android.telephony.DisconnectCause;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-
-import com.android.internal.telecomm.IVideoProvider;
-
-/**
- * Information about a call that is used between InCallService and Telecomm.
- * @hide
- */
-public final class ParcelableCall implements Parcelable {
-    private final String mId;
-    private final int mState;
-    private final int mDisconnectCauseCode;
-    private final String mDisconnectCauseMsg;
-    private final List<String> mCannedSmsResponses;
-    private final int mCapabilities;
-    private final long mConnectTimeMillis;
-    private final Uri mHandle;
-    private final int mHandlePresentation;
-    private final String mCallerDisplayName;
-    private final int mCallerDisplayNamePresentation;
-    private final GatewayInfo mGatewayInfo;
-    private final PhoneAccountHandle mAccountHandle;
-    private final IVideoProvider mVideoCallProvider;
-    private InCallService.VideoCall mVideoCall;
-    private final String mParentCallId;
-    private final List<String> mChildCallIds;
-    private final StatusHints mStatusHints;
-    private final int mVideoState;
-    private final List<String> mConferenceableCallIds;
-    private final Bundle mExtras;
-
-    public ParcelableCall(
-            String id,
-            int state,
-            int disconnectCauseCode,
-            String disconnectCauseMsg,
-            List<String> cannedSmsResponses,
-            int capabilities,
-            long connectTimeMillis,
-            Uri handle,
-            int handlePresentation,
-            String callerDisplayName,
-            int callerDisplayNamePresentation,
-            GatewayInfo gatewayInfo,
-            PhoneAccountHandle accountHandle,
-            IVideoProvider videoCallProvider,
-            String parentCallId,
-            List<String> childCallIds,
-            StatusHints statusHints,
-            int videoState,
-            List<String> conferenceableCallIds,
-            Bundle extras) {
-        mId = id;
-        mState = state;
-        mDisconnectCauseCode = disconnectCauseCode;
-        mDisconnectCauseMsg = disconnectCauseMsg;
-        mCannedSmsResponses = cannedSmsResponses;
-        mCapabilities = capabilities;
-        mConnectTimeMillis = connectTimeMillis;
-        mHandle = handle;
-        mHandlePresentation = handlePresentation;
-        mCallerDisplayName = callerDisplayName;
-        mCallerDisplayNamePresentation = callerDisplayNamePresentation;
-        mGatewayInfo = gatewayInfo;
-        mAccountHandle = accountHandle;
-        mVideoCallProvider = videoCallProvider;
-        mParentCallId = parentCallId;
-        mChildCallIds = childCallIds;
-        mStatusHints = statusHints;
-        mVideoState = videoState;
-        mConferenceableCallIds = Collections.unmodifiableList(conferenceableCallIds);
-        mExtras = extras;
-    }
-
-    /** The unique ID of the call. */
-    public String getId() {
-        return mId;
-    }
-
-    /** The current state of the call. */
-    public int getState() {
-        return mState;
-    }
-
-    /**
-     * Reason for disconnection, values are defined in {@link DisconnectCause}. Valid when call
-     * state is {@link CallState#DISCONNECTED}.
-     */
-    public int getDisconnectCauseCode() {
-        return mDisconnectCauseCode;
-    }
-
-    /**
-     * Further optional textual information about the reason for disconnection. Valid when call
-     * state is {@link CallState#DISCONNECTED}.
-     */
-    public String getDisconnectCauseMsg() {
-        return mDisconnectCauseMsg;
-    }
-
-    /**
-     * The set of possible text message responses when this call is incoming.
-     */
-    public List<String> getCannedSmsResponses() {
-        return mCannedSmsResponses;
-    }
-
-    // Bit mask of actions a call supports, values are defined in {@link CallCapabilities}.
-    public int getCapabilities() {
-        return mCapabilities;
-    }
-
-    /** The time that the call switched to the active state. */
-    public long getConnectTimeMillis() {
-        return mConnectTimeMillis;
-    }
-
-    /** The endpoint to which the call is connected. */
-    public Uri getHandle() {
-        return mHandle;
-    }
-
-    /** The {@link PropertyPresentation} which controls how the handle is shown. */
-    public int getHandlePresentation() {
-        return mHandlePresentation;
-    }
-
-    /** The endpoint to which the call is connected. */
-    public String getCallerDisplayName() {
-        return mCallerDisplayName;
-    }
-
-    /** The {@link PropertyPresentation} which controls how the caller display name is shown. */
-    public int getCallerDisplayNamePresentation() {
-        return mCallerDisplayNamePresentation;
-    }
-
-    /** Gateway information for the call. */
-    public GatewayInfo getGatewayInfo() {
-        return mGatewayInfo;
-    }
-
-    /** PhoneAccountHandle information for the call. */
-    public PhoneAccountHandle getAccountHandle() {
-        return mAccountHandle;
-    }
-
-    /**
-     * Returns an object for remotely communicating through the video call provider's binder.
-     * @return The video call.
-     */
-    public InCallService.VideoCall getVideoCall() {
-        if (mVideoCall == null && mVideoCallProvider != null) {
-            try {
-                mVideoCall = new VideoCallImpl(mVideoCallProvider);
-            } catch (RemoteException ignored) {
-                // Ignore RemoteException.
-            }
-        }
-
-        return mVideoCall;
-    }
-
-    /**
-     * The conference call to which this call is conferenced. Null if not conferenced.
-     */
-    public String getParentCallId() {
-        return mParentCallId;
-    }
-
-    /**
-     * The child call-IDs if this call is a conference call. Returns an empty list if this is not
-     * a conference call or if the conference call contains no children.
-     */
-    public List<String> getChildCallIds() {
-        return mChildCallIds;
-    }
-
-    public List<String> getConferenceableCallIds() {
-        return mConferenceableCallIds;
-    }
-
-    /**
-     * The status label and icon.
-     *
-     * @return Status hints.
-     */
-    public StatusHints getStatusHints() {
-        return mStatusHints;
-    }
-
-    /**
-     * The video state.
-     * @return The video state of the call.
-     */
-    public int getVideoState() {
-        return mVideoState;
-    }
-
-    /**
-     * Any extras to pass with the call
-     *
-     * @return a bundle of extras
-     */
-    public Bundle getExtras() {
-        return mExtras;
-    }
-
-    /** Responsible for creating ParcelableCall objects for deserialized Parcels. */
-    public static final Parcelable.Creator<ParcelableCall> CREATOR =
-            new Parcelable.Creator<ParcelableCall> () {
-        @Override
-        public ParcelableCall createFromParcel(Parcel source) {
-            ClassLoader classLoader = ParcelableCall.class.getClassLoader();
-            String id = source.readString();
-            int state = source.readInt();
-            int disconnectCauseCode = source.readInt();
-            String disconnectCauseMsg = source.readString();
-            List<String> cannedSmsResponses = new ArrayList<>();
-            source.readList(cannedSmsResponses, classLoader);
-            int capabilities = source.readInt();
-            long connectTimeMillis = source.readLong();
-            Uri handle = source.readParcelable(classLoader);
-            int handlePresentation = source.readInt();
-            String callerDisplayName = source.readString();
-            int callerDisplayNamePresentation = source.readInt();
-            GatewayInfo gatewayInfo = source.readParcelable(classLoader);
-            PhoneAccountHandle accountHandle = source.readParcelable(classLoader);
-            IVideoProvider videoCallProvider =
-                    IVideoProvider.Stub.asInterface(source.readStrongBinder());
-            String parentCallId = source.readString();
-            List<String> childCallIds = new ArrayList<>();
-            source.readList(childCallIds, classLoader);
-            StatusHints statusHints = source.readParcelable(classLoader);
-            int videoState = source.readInt();
-            List<String> conferenceableCallIds = new ArrayList<>();
-            source.readList(conferenceableCallIds, classLoader);
-            Bundle extras = source.readParcelable(classLoader);
-            return new ParcelableCall(id, state, disconnectCauseCode, disconnectCauseMsg,
-                    cannedSmsResponses, capabilities, connectTimeMillis, handle, handlePresentation,
-                    callerDisplayName, callerDisplayNamePresentation, gatewayInfo,
-                    accountHandle, videoCallProvider, parentCallId, childCallIds, statusHints,
-                    videoState, conferenceableCallIds, extras);
-        }
-
-        @Override
-        public ParcelableCall[] newArray(int size) {
-            return new ParcelableCall[size];
-        }
-    };
-
-    /** {@inheritDoc} */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Writes ParcelableCall object into a Parcel. */
-    @Override
-    public void writeToParcel(Parcel destination, int flags) {
-        destination.writeString(mId);
-        destination.writeInt(mState);
-        destination.writeInt(mDisconnectCauseCode);
-        destination.writeString(mDisconnectCauseMsg);
-        destination.writeList(mCannedSmsResponses);
-        destination.writeInt(mCapabilities);
-        destination.writeLong(mConnectTimeMillis);
-        destination.writeParcelable(mHandle, 0);
-        destination.writeInt(mHandlePresentation);
-        destination.writeString(mCallerDisplayName);
-        destination.writeInt(mCallerDisplayNamePresentation);
-        destination.writeParcelable(mGatewayInfo, 0);
-        destination.writeParcelable(mAccountHandle, 0);
-        destination.writeStrongBinder(
-                mVideoCallProvider != null ? mVideoCallProvider.asBinder() : null);
-        destination.writeString(mParentCallId);
-        destination.writeList(mChildCallIds);
-        destination.writeParcelable(mStatusHints, 0);
-        destination.writeInt(mVideoState);
-        destination.writeList(mConferenceableCallIds);
-        destination.writeParcelable(mExtras, 0);
-    }
-
-    @Override
-    public String toString() {
-        return String.format("[%s, parent:%s, children:%s]", mId, mParentCallId, mChildCallIds);
-    }
-}
diff --git a/telecomm/java/android/telecomm/ParcelableConnection.aidl b/telecomm/java/android/telecomm/ParcelableConnection.aidl
deleted file mode 100644
index 143c5a6..0000000
--- a/telecomm/java/android/telecomm/ParcelableConnection.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable ParcelableConnection;
diff --git a/telecomm/java/android/telecomm/ParcelableConnection.java b/telecomm/java/android/telecomm/ParcelableConnection.java
deleted file mode 100644
index 7a87b87..0000000
--- a/telecomm/java/android/telecomm/ParcelableConnection.java
+++ /dev/null
@@ -1,198 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-import android.net.Uri;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import com.android.internal.telecomm.IVideoProvider;
-
-/**
- * Information about a connection that is used between Telecomm and the ConnectionService.
- * This is used to send initial Connection information to Telecomm when the connection is
- * first created.
- * @hide
- */
-public final class ParcelableConnection implements Parcelable {
-    private PhoneAccountHandle mPhoneAccount;
-    private int mState;
-    private int mCapabilities;
-    private Uri mHandle;
-    private int mHandlePresentation;
-    private String mCallerDisplayName;
-    private int mCallerDisplayNamePresentation;
-    private IVideoProvider mVideoProvider;
-    private int mVideoState;
-    private boolean mRequestingRingback;
-    private boolean mAudioModeIsVoip;
-    private StatusHints mStatusHints;
-
-    /** @hide */
-    public ParcelableConnection(
-            PhoneAccountHandle phoneAccount,
-            int state,
-            int capabilities,
-            Uri handle,
-            int handlePresentation,
-            String callerDisplayName,
-            int callerDisplayNamePresentation,
-            IVideoProvider videoProvider,
-            int videoState,
-            boolean requestingRingback,
-            boolean audioModeIsVoip,
-            StatusHints statusHints) {
-        mPhoneAccount = phoneAccount;
-        mState = state;
-        mCapabilities = capabilities;
-        mHandle = handle;
-        mHandlePresentation = handlePresentation;
-        mCallerDisplayName = callerDisplayName;
-        mCallerDisplayNamePresentation = callerDisplayNamePresentation;
-        mVideoProvider = videoProvider;
-        mVideoState = videoState;
-        mRequestingRingback = requestingRingback;
-        mAudioModeIsVoip = audioModeIsVoip;
-        mStatusHints = statusHints;
-    }
-
-    public PhoneAccountHandle getPhoneAccount() {
-        return mPhoneAccount;
-    }
-
-    public int getState() {
-        return mState;
-    }
-
-    // Bit mask of actions a call supports, values are defined in {@link CallCapabilities}.
-    public int getCapabilities() {
-        return mCapabilities;
-    }
-
-    public Uri getHandle() {
-        return mHandle;
-    }
-
-    public int getHandlePresentation() {
-        return mHandlePresentation;
-    }
-
-    public String getCallerDisplayName() {
-        return mCallerDisplayName;
-    }
-
-    public int getCallerDisplayNamePresentation() {
-        return mCallerDisplayNamePresentation;
-    }
-
-    public IVideoProvider getVideoProvider() {
-        return mVideoProvider;
-    }
-
-    public int getVideoState() {
-        return mVideoState;
-    }
-
-    public boolean isRequestingRingback() {
-        return mRequestingRingback;
-    }
-
-    public boolean getAudioModeIsVoip() {
-        return mAudioModeIsVoip;
-    }
-
-    public final StatusHints getStatusHints() {
-        return mStatusHints;
-    }
-
-    @Override
-    public String toString() {
-        return new StringBuilder()
-                .append("ParcelableConnection [act:")
-                .append(mPhoneAccount)
-                .append(", state:")
-                .append(mState)
-                .append(", capabilities:")
-                .append(PhoneCapabilities.toString(mCapabilities))
-                .toString();
-    }
-
-    public static final Parcelable.Creator<ParcelableConnection> CREATOR =
-            new Parcelable.Creator<ParcelableConnection> () {
-        @Override
-        public ParcelableConnection createFromParcel(Parcel source) {
-            ClassLoader classLoader = ParcelableConnection.class.getClassLoader();
-
-            PhoneAccountHandle phoneAccount = source.readParcelable(classLoader);
-            int state = source.readInt();
-            int capabilities = source.readInt();
-            Uri handle = source.readParcelable(classLoader);
-            int handlePresentation = source.readInt();
-            String callerDisplayName = source.readString();
-            int callerDisplayNamePresentation = source.readInt();
-            IVideoProvider videoCallProvider =
-                    IVideoProvider.Stub.asInterface(source.readStrongBinder());
-            int videoState = source.readInt();
-            boolean requestingRingback = source.readByte() == 1;
-            boolean audioModeIsVoip = source.readByte() == 1;
-            StatusHints statusHints = source.readParcelable(classLoader);
-
-            return new ParcelableConnection(
-                    phoneAccount,
-                    state,
-                    capabilities,
-                    handle,
-                    handlePresentation,
-                    callerDisplayName,
-                    callerDisplayNamePresentation,
-                    videoCallProvider,
-                    videoState,
-                    requestingRingback,
-                    audioModeIsVoip,
-                    statusHints);
-        }
-
-        @Override
-        public ParcelableConnection[] newArray(int size) {
-            return new ParcelableConnection[size];
-        }
-    };
-
-    /** {@inheritDoc} */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Writes ParcelableConnection object into a Parcel. */
-    @Override
-    public void writeToParcel(Parcel destination, int flags) {
-        destination.writeParcelable(mPhoneAccount, 0);
-        destination.writeInt(mState);
-        destination.writeInt(mCapabilities);
-        destination.writeParcelable(mHandle, 0);
-        destination.writeInt(mHandlePresentation);
-        destination.writeString(mCallerDisplayName);
-        destination.writeInt(mCallerDisplayNamePresentation);
-        destination.writeStrongBinder(
-                mVideoProvider != null ? mVideoProvider.asBinder() : null);
-        destination.writeInt(mVideoState);
-        destination.writeByte((byte) (mRequestingRingback ? 1 : 0));
-        destination.writeByte((byte) (mAudioModeIsVoip ? 1 : 0));
-        destination.writeParcelable(mStatusHints, 0);
-    }
-}
diff --git a/telecomm/java/android/telecomm/Phone.java b/telecomm/java/android/telecomm/Phone.java
deleted file mode 100644
index 03a8676..0000000
--- a/telecomm/java/android/telecomm/Phone.java
+++ /dev/null
@@ -1,280 +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 android.telecomm;
-
-import android.app.PendingIntent;
-import android.util.ArrayMap;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import java.util.Map;
-import java.util.Objects;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-/**
- * A unified virtual device providing a means of voice (and other) communication on a device.
- *
- * {@hide}
- */
-public final class Phone {
-
-    public abstract static class Listener {
-        /**
-         * Called when the audio state changes.
-         *
-         * @param phone The {@code Phone} calling this method.
-         * @param audioState The new {@link AudioState}.
-         */
-        public void onAudioStateChanged(Phone phone, AudioState audioState) { }
-
-        /**
-         * Called to bring the in-call screen to the foreground. The in-call experience should
-         * respond immediately by coming to the foreground to inform the user of the state of
-         * ongoing {@code Call}s.
-         *
-         * @param phone The {@code Phone} calling this method.
-         * @param showDialpad If true, put up the dialpad when the screen is shown.
-         */
-        public void onBringToForeground(Phone phone, boolean showDialpad) { }
-
-        /**
-         * Called when a {@code Call} has been added to this in-call session. The in-call user
-         * experience should add necessary state listeners to the specified {@code Call} and
-         * immediately start to show the user information about the existence
-         * and nature of this {@code Call}. Subsequent invocations of {@link #getCalls()} will
-         * include this {@code Call}.
-         *
-         * @param phone The {@code Phone} calling this method.
-         * @param call A newly added {@code Call}.
-         */
-        public void onCallAdded(Phone phone, Call call) { }
-
-        /**
-         * Called when a {@code Call} has been removed from this in-call session. The in-call user
-         * experience should remove any state listeners from the specified {@code Call} and
-         * immediately stop displaying any information about this {@code Call}.
-         * Subsequent invocations of {@link #getCalls()} will no longer include this {@code Call}.
-         *
-         * @param phone The {@code Phone} calling this method.
-         * @param call A newly removed {@code Call}.
-         */
-        public void onCallRemoved(Phone phone, Call call) { }
-    }
-
-    // A Map allows us to track each Call by its Telecomm-specified call ID
-    private final Map<String, Call> mCallByTelecommCallId = new ArrayMap<>();
-
-    // A List allows us to keep the Calls in a stable iteration order so that casually developed
-    // user interface components do not incur any spurious jank
-    private final List<Call> mCalls = new ArrayList<>();
-
-    // An unmodifiable view of the above List can be safely shared with subclass implementations
-    private final List<Call> mUnmodifiableCalls = Collections.unmodifiableList(mCalls);
-
-    private final InCallAdapter mInCallAdapter;
-
-    private AudioState mAudioState;
-
-    private final List<Listener> mListeners = new CopyOnWriteArrayList<>();
-
-    /** {@hide} */
-    Phone(InCallAdapter adapter) {
-        mInCallAdapter = adapter;
-    }
-
-    /** {@hide} */
-    final void internalAddCall(ParcelableCall parcelableCall) {
-        Call call = new Call(this, parcelableCall.getId(), mInCallAdapter);
-        mCallByTelecommCallId.put(parcelableCall.getId(), call);
-        mCalls.add(call);
-        checkCallTree(parcelableCall);
-        call.internalUpdate(parcelableCall, mCallByTelecommCallId);
-        fireCallAdded(call);
-     }
-
-    /** {@hide} */
-    final void internalRemoveCall(Call call) {
-        mCallByTelecommCallId.remove(call.internalGetCallId());
-        mCalls.remove(call);
-        fireCallRemoved(call);
-    }
-
-    /** {@hide} */
-    final void internalUpdateCall(ParcelableCall parcelableCall) {
-         Call call = mCallByTelecommCallId.get(parcelableCall.getId());
-         if (call != null) {
-             checkCallTree(parcelableCall);
-             call.internalUpdate(parcelableCall, mCallByTelecommCallId);
-         }
-     }
-
-    /** {@hide} */
-    final void internalSetPostDialWait(String telecommId, String remaining) {
-        Call call = mCallByTelecommCallId.get(telecommId);
-        if (call != null) {
-            call.internalSetPostDialWait(remaining);
-        }
-    }
-
-    /** {@hide} */
-    final void internalAudioStateChanged(AudioState audioState) {
-        if (!Objects.equals(mAudioState, audioState)) {
-            mAudioState = audioState;
-            fireAudioStateChanged(audioState);
-        }
-    }
-
-    /** {@hide} */
-    final Call internalGetCallByTelecommId(String telecommId) {
-        return mCallByTelecommCallId.get(telecommId);
-    }
-
-    /** {@hide} */
-    final void internalBringToForeground(boolean showDialpad) {
-        fireBringToForeground(showDialpad);
-    }
-
-    /** {@hide} */
-    final void internalStartActivity(String telecommId, PendingIntent intent) {
-        Call call = mCallByTelecommCallId.get(telecommId);
-        if (call != null) {
-            call.internalStartActivity(intent);
-        }
-    }
-
-    /**
-     * Adds a listener to this {@code Phone}.
-     *
-     * @param listener A {@code Listener} object.
-     */
-    public final void addListener(Listener listener) {
-        mListeners.add(listener);
-    }
-
-    /**
-     * Removes a listener from this {@code Phone}.
-     *
-     * @param listener A {@code Listener} object.
-     */
-    public final void removeListener(Listener listener) {
-        if (listener != null) {
-            mListeners.remove(listener);
-        }
-    }
-
-    /**
-     * Obtains the current list of {@code Call}s to be displayed by this in-call experience.
-     *
-     * @return A list of the relevant {@code Call}s.
-     */
-    public final List<Call> getCalls() {
-        return mUnmodifiableCalls;
-    }
-
-    /**
-     * Sets the microphone mute state. When this request is honored, there will be change to
-     * the {@link #getAudioState()}.
-     *
-     * @param state {@code true} if the microphone should be muted; {@code false} otherwise.
-     */
-    public final void setMuted(boolean state) {
-        mInCallAdapter.mute(state);
-    }
-
-    /**
-     * Sets the audio route (speaker, bluetooth, etc...).  When this request is honored, there will
-     * be change to the {@link #getAudioState()}.
-     *
-     * @param route The audio route to use.
-     */
-    public final void setAudioRoute(int route) {
-        mInCallAdapter.setAudioRoute(route);
-    }
-
-    /**
-     * Turns the proximity sensor on. When this request is made, the proximity sensor will
-     * become active, and the touch screen and display will be turned off when the user's face
-     * is detected to be in close proximity to the screen. This operation is a no-op on devices
-     * that do not have a proximity sensor.
-     */
-    public final void setProximitySensorOn() {
-        mInCallAdapter.turnProximitySensorOn();
-    }
-
-    /**
-     * Turns the proximity sensor off. When this request is made, the proximity sensor will
-     * become inactive, and no longer affect the touch screen and display. This operation is a
-     * no-op on devices that do not have a proximity sensor.
-     *
-     * @param screenOnImmediately If true, the screen will be turned on immediately if it was
-     * previously off. Otherwise, the screen will only be turned on after the proximity sensor
-     * is no longer triggered.
-     */
-    public final void setProximitySensorOff(boolean screenOnImmediately) {
-        mInCallAdapter.turnProximitySensorOff(screenOnImmediately);
-    }
-
-    /**
-     * Obtains the current phone call audio state of the {@code Phone}.
-     *
-     * @return An object encapsulating the audio state.
-     */
-    public final AudioState getAudioState() {
-        return mAudioState;
-    }
-
-    private void fireCallAdded(Call call) {
-        for (Listener listener : mListeners) {
-            listener.onCallAdded(this, call);
-        }
-    }
-
-    private void fireCallRemoved(Call call) {
-        for (Listener listener : mListeners) {
-            listener.onCallRemoved(this, call);
-        }
-    }
-
-    private void fireAudioStateChanged(AudioState audioState) {
-        for (Listener listener : mListeners) {
-            listener.onAudioStateChanged(this, audioState);
-        }
-    }
-
-    private void fireBringToForeground(boolean showDialpad) {
-        for (Listener listener : mListeners) {
-            listener.onBringToForeground(this, showDialpad);
-        }
-    }
-
-    private void checkCallTree(ParcelableCall parcelableCall) {
-        if (parcelableCall.getParentCallId() != null &&
-                !mCallByTelecommCallId.containsKey(parcelableCall.getParentCallId())) {
-            Log.wtf(this, "ParcelableCall %s has nonexistent parent %s",
-                    parcelableCall.getId(), parcelableCall.getParentCallId());
-        }
-        if (parcelableCall.getChildCallIds() != null) {
-            for (int i = 0; i < parcelableCall.getChildCallIds().size(); i++) {
-                if (!mCallByTelecommCallId.containsKey(parcelableCall.getChildCallIds().get(i))) {
-                    Log.wtf(this, "ParcelableCall %s has nonexistent child %s",
-                            parcelableCall.getId(), parcelableCall.getChildCallIds().get(i));
-                }
-            }
-        }
-    }
-}
diff --git a/telecomm/java/android/telecomm/PhoneAccount.aidl b/telecomm/java/android/telecomm/PhoneAccount.aidl
deleted file mode 100644
index 15377df..0000000
--- a/telecomm/java/android/telecomm/PhoneAccount.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-/**
- * {@hide}
-  */
-parcelable PhoneAccount;
diff --git a/telecomm/java/android/telecomm/PhoneAccount.java b/telecomm/java/android/telecomm/PhoneAccount.java
deleted file mode 100644
index 411f48c..0000000
--- a/telecomm/java/android/telecomm/PhoneAccount.java
+++ /dev/null
@@ -1,307 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.content.Context;
-import android.content.pm.PackageManager;
-import android.content.res.Resources.NotFoundException;
-import android.graphics.drawable.Drawable;
-import android.net.Uri;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import java.util.MissingResourceException;
-
-/**
- * Describes a distinct account, line of service or call placement method that the system
- * can use to place phone calls.
- */
-public class PhoneAccount implements Parcelable {
-
-    /**
-     * Flag indicating that this {@code PhoneAccount} can act as a connection manager for
-     * other connections. The {@link ConnectionService} associated with this {@code PhoneAccount}
-     * will be allowed to manage phone calls including using its own proprietary phone-call
-     * implementation (like VoIP calling) to make calls instead of the telephony stack.
-     * <p>
-     * When a user opts to place a call using the SIM-based telephony stack, the
-     * {@link ConnectionService} associated with this {@code PhoneAccount} will be attempted first
-     * if the user has explicitly selected it to be used as the default connection manager.
-     * <p>
-     * See {@link #getCapabilities}
-     */
-    public static final int CAPABILITY_CONNECTION_MANAGER = 0x1;
-
-    /**
-     * Flag indicating that this {@code PhoneAccount} can make phone calls in place of
-     * traditional SIM-based telephony calls. This account will be treated as a distinct method
-     * for placing calls alongside the traditional SIM-based telephony stack. This flag is
-     * distinct from {@link #CAPABILITY_CONNECTION_MANAGER} in that it is not allowed to manage
-     * calls from or use the built-in telephony stack to place its calls.
-     * <p>
-     * See {@link #getCapabilities}
-     * <p>
-     * {@hide}
-     */
-    public static final int CAPABILITY_CALL_PROVIDER = 0x2;
-
-    /**
-     * Flag indicating that this {@code PhoneAccount} represents a built-in PSTN SIM
-     * subscription.
-     * <p>
-     * Only the Android framework can register a {@code PhoneAccount} having this capability.
-     * <p>
-     * See {@link #getCapabilities}
-     */
-    public static final int CAPABILITY_SIM_SUBSCRIPTION = 0x4;
-
-    /**
-     * Flag indicating that this {@code PhoneAccount} is capable of placing video calls.
-     * <p>
-     * See {@link #getCapabilities}
-     */
-    public static final int CAPABILITY_VIDEO_CALLING = 0x8;
-
-    private final PhoneAccountHandle mAccountHandle;
-    private final Uri mHandle;
-    private final String mSubscriptionNumber;
-    private final int mCapabilities;
-    private final int mIconResId;
-    private final CharSequence mLabel;
-    private final CharSequence mShortDescription;
-
-    public static class Builder {
-        private PhoneAccountHandle mAccountHandle;
-        private Uri mHandle;
-        private String mSubscriptionNumber;
-        private int mCapabilities;
-        private int mIconResId;
-        private CharSequence mLabel;
-        private CharSequence mShortDescription;
-
-        private Builder() {}
-
-        public Builder withAccountHandle(PhoneAccountHandle value) {
-            this.mAccountHandle = value;
-            return this;
-        }
-
-        public Builder withHandle(Uri value) {
-            this.mHandle = value;
-            return this;
-        }
-
-        public Builder withSubscriptionNumber(String value) {
-            this.mSubscriptionNumber = value;
-            return this;
-        }
-
-        public Builder withCapabilities(int value) {
-            this.mCapabilities = value;
-            return this;
-        }
-
-        public Builder withIconResId(int value) {
-            this.mIconResId = value;
-            return this;
-        }
-
-        public Builder withLabel(CharSequence value) {
-            this.mLabel = value;
-            return this;
-        }
-
-        public Builder withShortDescription(CharSequence value) {
-            this.mShortDescription = value;
-            return this;
-        }
-
-        public PhoneAccount build() {
-            return new PhoneAccount(
-                    mAccountHandle,
-                    mHandle,
-                    mSubscriptionNumber,
-                    mCapabilities,
-                    mIconResId,
-                    mLabel,
-                    mShortDescription);
-        }
-    }
-
-    private PhoneAccount(
-            PhoneAccountHandle account,
-            Uri handle,
-            String subscriptionNumber,
-            int capabilities,
-            int iconResId,
-            CharSequence label,
-            CharSequence shortDescription) {
-        mAccountHandle = account;
-        mHandle = handle;
-        mSubscriptionNumber = subscriptionNumber;
-        mCapabilities = capabilities;
-        mIconResId = iconResId;
-        mLabel = label;
-        mShortDescription = shortDescription;
-    }
-
-    public static Builder builder() { return new Builder(); }
-
-    /**
-     * The unique identifier of this {@code PhoneAccount}.
-     *
-     * @return A {@code PhoneAccountHandle}.
-     */
-    public PhoneAccountHandle getAccountHandle() {
-        return mAccountHandle;
-    }
-
-    /**
-     * The handle (e.g., a phone number) associated with this {@code PhoneAccount}. This
-     * represents the destination from which outgoing calls using this {@code PhoneAccount}
-     * will appear to come, if applicable, and the destination to which incoming calls using this
-     * {@code PhoneAccount} may be addressed.
-     *
-     * @return A handle expressed as a {@code Uri}, for example, a phone number.
-     */
-    public Uri getHandle() {
-        return mHandle;
-    }
-
-    /**
-     * The raw callback number used for this {@code PhoneAccount}, as distinct from
-     * {@link #getHandle()}. For the majority of {@code PhoneAccount}s this should be registered
-     * as {@code null}.  It is used by the system for SIM-based {@code PhoneAccount} registration
-     * where {@link android.telephony.TelephonyManager#setLine1NumberForDisplay(String, String)}
-     * or {@link android.telephony.TelephonyManager#setLine1NumberForDisplay(long, String, String)}
-     * has been used to alter the callback number.
-     * <p>
-     * TODO: Should this also be a URI, for consistency? Should it be called the
-     * "subscription handle"?
-     *
-     * @return The subscription number, suitable for display to the user.
-     */
-    public String getSubscriptionNumber() {
-        return mSubscriptionNumber;
-    }
-
-    /**
-     * The capabilities of this {@code PhoneAccount}.
-     *
-     * @return A bit field of flags describing this {@code PhoneAccount}'s capabilities.
-     */
-    public int getCapabilities() {
-        return mCapabilities;
-    }
-
-    /**
-     * A short label describing a {@code PhoneAccount}.
-     *
-     * @return A label for this {@code PhoneAccount}.
-     */
-    public CharSequence getLabel() {
-        return mLabel;
-    }
-
-    /**
-     * A short paragraph describing this {@code PhoneAccount}.
-     *
-     * @return A description for this {@code PhoneAccount}.
-     */
-    public CharSequence getShortDescription() {
-        return mShortDescription;
-    }
-
-    /**
-     * The icon resource ID for the icon of this {@code PhoneAccount}.
-     *
-     * @return A resource ID.
-     */
-    public int getIconResId() {
-        return mIconResId;
-    }
-
-    /**
-     * An icon to represent this {@code PhoneAccount} in a user interface.
-     *
-     * @return An icon for this {@code PhoneAccount}.
-     */
-    public Drawable getIcon(Context context) {
-        return getIcon(context, mIconResId);
-    }
-
-    private Drawable getIcon(Context context, int resId) {
-        Context packageContext;
-        try {
-            packageContext = context.createPackageContext(
-                    mAccountHandle.getComponentName().getPackageName(), 0);
-        } catch (PackageManager.NameNotFoundException e) {
-            Log.w(this, "Cannot find package %s", mAccountHandle.getComponentName().getPackageName());
-            return null;
-        }
-        try {
-            return packageContext.getDrawable(resId);
-        } catch (NotFoundException|MissingResourceException e) {
-            Log.e(this, e, "Cannot find icon %d in package %s",
-                    resId, mAccountHandle.getComponentName().getPackageName());
-            return null;
-        }
-    }
-
-    //
-    // Parcelable implementation
-    //
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeParcelable(mAccountHandle, 0);
-        out.writeParcelable(mHandle, 0);
-        out.writeString(mSubscriptionNumber);
-        out.writeInt(mCapabilities);
-        out.writeInt(mIconResId);
-        out.writeCharSequence(mLabel);
-        out.writeCharSequence(mShortDescription);
-    }
-
-    public static final Creator<PhoneAccount> CREATOR
-            = new Creator<PhoneAccount>() {
-        @Override
-        public PhoneAccount createFromParcel(Parcel in) {
-            return new PhoneAccount(in);
-        }
-
-        @Override
-        public PhoneAccount[] newArray(int size) {
-            return new PhoneAccount[size];
-        }
-    };
-
-    private PhoneAccount(Parcel in) {
-        mAccountHandle = in.readParcelable(getClass().getClassLoader());
-        mHandle = in.readParcelable(getClass().getClassLoader());
-        mSubscriptionNumber = in.readString();
-        mCapabilities = in.readInt();
-        mIconResId = in.readInt();
-        mLabel = in.readCharSequence();
-        mShortDescription = in.readCharSequence();
-    }
-}
diff --git a/telecomm/java/android/telecomm/PhoneAccountHandle.aidl b/telecomm/java/android/telecomm/PhoneAccountHandle.aidl
deleted file mode 100644
index 3be5a2e..0000000
--- a/telecomm/java/android/telecomm/PhoneAccountHandle.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2008 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 android.telecomm;
-
-/**
- * {@hide}
-  */
-parcelable PhoneAccountHandle;
diff --git a/telecomm/java/android/telecomm/PhoneAccountHandle.java b/telecomm/java/android/telecomm/PhoneAccountHandle.java
deleted file mode 100644
index 04cd2b0..0000000
--- a/telecomm/java/android/telecomm/PhoneAccountHandle.java
+++ /dev/null
@@ -1,120 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.content.ComponentName;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import java.util.Objects;
-
-/**
- * The unique identifier for a {@link PhoneAccount}.
- */
-public class PhoneAccountHandle implements Parcelable {
-    private ComponentName mComponentName;
-    private String mId;
-
-    public PhoneAccountHandle(
-            ComponentName componentName,
-            String id) {
-        mComponentName = componentName;
-        mId = id;
-    }
-
-    /**
-     * The {@code ComponentName} of the {@link android.telecomm.ConnectionService} which is
-     * responsible for making phone calls using this {@code PhoneAccountHandle}.
-     *
-     * @return A suitable {@code ComponentName}.
-     */
-    public ComponentName getComponentName() {
-        return mComponentName;
-    }
-
-    /**
-     * A string that uniquely distinguishes this particular {@code PhoneAccountHandle} from all the
-     * others supported by the {@link ConnectionService} that created it.
-     * <p>
-     * A {@code ConnectionService} must select identifiers that are stable for the lifetime of
-     * their users' relationship with their service, across many Android devices. For example, a
-     * good set of identifiers might be the email addresses with which with users registered for
-     * their accounts with a particular service. Depending on how a service chooses to operate,
-     * a bad set of identifiers might be an increasing series of integers
-     * ({@code 0}, {@code 1}, {@code 2}, ...) that are generated locally on each phone and could
-     * collide with values generated on other phones or after a data wipe of a given phone.
-     *
-     * @return A service-specific unique identifier for this {@code PhoneAccountHandle}.
-     */
-    public String getId() {
-        return mId;
-    }
-
-    @Override
-    public int hashCode() {
-        return Objects.hashCode(mComponentName) + Objects.hashCode(mId);
-    }
-
-    @Override
-    public String toString() {
-        return new StringBuilder().append(mComponentName)
-                    .append(", ")
-                    .append(mId)
-                    .toString();
-    }
-
-    @Override
-    public boolean equals(Object other) {
-        return other != null &&
-                other instanceof PhoneAccountHandle &&
-                Objects.equals(((PhoneAccountHandle) other).getComponentName(),
-                        getComponentName()) &&
-                Objects.equals(((PhoneAccountHandle) other).getId(), getId());
-    }
-
-    //
-    // Parcelable implementation.
-    //
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeParcelable(mComponentName, flags);
-        out.writeString(mId);
-    }
-
-    public static final Creator<PhoneAccountHandle> CREATOR = new Creator<PhoneAccountHandle>() {
-        @Override
-        public PhoneAccountHandle createFromParcel(Parcel in) {
-            return new PhoneAccountHandle(in);
-        }
-
-        @Override
-        public PhoneAccountHandle[] newArray(int size) {
-            return new PhoneAccountHandle[size];
-        }
-    };
-
-    private PhoneAccountHandle(Parcel in) {
-        mComponentName = in.readParcelable(getClass().getClassLoader());
-        mId = in.readString();
-    }
-}
diff --git a/telecomm/java/android/telecomm/PhoneCapabilities.java b/telecomm/java/android/telecomm/PhoneCapabilities.java
deleted file mode 100644
index 45168d5..0000000
--- a/telecomm/java/android/telecomm/PhoneCapabilities.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * Defines capabilities a phone call can support, such as conference calling and video telephony.
- * Also defines properties of a phone call, such as whether it is using VoLTE technology.
-
- */
-public final class PhoneCapabilities {
-    /** Call can currently be put on hold or unheld. */
-    public static final int HOLD               = 0x00000001;
-
-    /** Call supports the hold feature. */
-    public static final int SUPPORT_HOLD       = 0x00000002;
-
-    /** Call can currently be merged. */
-    public static final int MERGE_CALLS        = 0x00000004;
-
-    /** Call can currently be swapped with another call. */
-    public static final int SWAP_CALLS         = 0x00000008;
-
-    /** Call currently supports adding another call to this one. */
-    public static final int ADD_CALL           = 0x00000010;
-
-    /** Call supports responding via text option. */
-    public static final int RESPOND_VIA_TEXT   = 0x00000020;
-
-    /** Call can be muted. */
-    public static final int MUTE               = 0x00000040;
-
-    /** Call supports generic conference mode. */
-    public static final int GENERIC_CONFERENCE = 0x00000080;
-
-    /** Local device supports video telephony. */
-    public static final int SUPPORTS_VT_LOCAL  = 0x00000100;
-
-    /** Remote device supports video telephony. */
-    public static final int SUPPORTS_VT_REMOTE = 0x00000200;
-
-    public static final int VoLTE = 0x00000400;
-
-    public static final int VoWIFI = 0x00000800;
-
-    public static final int ALL = HOLD | SUPPORT_HOLD | MERGE_CALLS | SWAP_CALLS | ADD_CALL
-            | RESPOND_VIA_TEXT | MUTE | GENERIC_CONFERENCE | VoLTE | VoWIFI;
-
-    public static String toString(int capabilities) {
-        StringBuilder builder = new StringBuilder();
-        builder.append("[Capabilities:");
-        if ((capabilities & HOLD) != 0) {
-            builder.append(" HOLD");
-        }
-        if ((capabilities & SUPPORT_HOLD) != 0) {
-            builder.append(" SUPPORT_HOLD");
-        }
-        if ((capabilities & MERGE_CALLS) != 0) {
-            builder.append(" MERGE_CALLS");
-        }
-        if ((capabilities & SWAP_CALLS) != 0) {
-            builder.append(" SWAP_CALLS");
-        }
-        if ((capabilities & ADD_CALL) != 0) {
-            builder.append(" ADD_CALL");
-        }
-        if ((capabilities & RESPOND_VIA_TEXT) != 0) {
-            builder.append(" RESPOND_VIA_TEXT");
-        }
-        if ((capabilities & MUTE) != 0) {
-            builder.append(" MUTE");
-        }
-        if ((capabilities & GENERIC_CONFERENCE) != 0) {
-            builder.append(" GENERIC_CONFERENCE");
-        }
-        if ((capabilities & SUPPORTS_VT_LOCAL) != 0) {
-            builder.append(" SUPPORTS_VT_LOCAL");
-        }
-        if ((capabilities & SUPPORTS_VT_REMOTE) != 0) {
-            builder.append(" SUPPORTS_VT_REMOTE");
-        }
-        if ((capabilities & VoLTE) != 0) {
-            builder.append(" VoLTE");
-        }
-        if ((capabilities & VoWIFI) != 0) {
-            builder.append(" VoWIFI");
-        }
-        builder.append("]");
-        return builder.toString();
-    }
-
-    private PhoneCapabilities() {}
-}
diff --git a/telecomm/java/android/telecomm/PropertyPresentation.java b/telecomm/java/android/telecomm/PropertyPresentation.java
deleted file mode 100644
index fe97b3d..0000000
--- a/telecomm/java/android/telecomm/PropertyPresentation.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Copyright 2014, 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 android.telecomm;
-
-/**
- * Defines how properties such as phone numbers and names are displayed to the user.
- */
-public class PropertyPresentation {
-    /** Property is displayed normally. */
-    public static final int ALLOWED = 1;
-
-    /** Property was blocked. */
-    public static final int RESTRICTED = 2;
-
-    /** Presentation was not specified or is unknown. */
-    public static final int UNKNOWN = 3;
-
-    /** Property should be displayed as a pay phone. */
-    public static final int PAYPHONE = 4;
-}
diff --git a/telecomm/java/android/telecomm/RemoteConnection.java b/telecomm/java/android/telecomm/RemoteConnection.java
deleted file mode 100644
index f1cee10..0000000
--- a/telecomm/java/android/telecomm/RemoteConnection.java
+++ /dev/null
@@ -1,688 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import com.android.internal.telecomm.IConnectionService;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.RemoteException;
-import android.telephony.DisconnectCause;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-
-/**
- * A connection provided to a {@link ConnectionService} by another {@code ConnectionService}
- * running in a different process.
- *
- * @see ConnectionService#createRemoteOutgoingConnection(PhoneAccountHandle, ConnectionRequest)
- * @see ConnectionService#createRemoteIncomingConnection(PhoneAccountHandle, ConnectionRequest)
- */
-public final class RemoteConnection {
-
-    public static abstract class Listener {
-        /**
-         * Invoked when the state of this {@code RemoteConnection} has changed. See
-         * {@link #getState()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param state The new state of the {@code RemoteConnection}.
-         */
-        public void onStateChanged(RemoteConnection connection, int state) {}
-
-        /**
-         * Invoked when the parent of this {@code RemoteConnection} has changed. See
-         * {@link #getParent()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param parent The new parent of the {@code RemoteConnection}.
-         */
-        public void onParentChanged(RemoteConnection connection, RemoteConnection parent) {}
-
-        /**
-         * Invoked when the children of this {@code RemoteConnection} have changed. See
-         * {@link #getChildren()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param children The new children of the {@code RemoteConnection}.
-         */
-        public void onChildrenChanged(
-                RemoteConnection connection, List<RemoteConnection> children) {}
-
-        /**
-         * Invoked when this {@code RemoteConnection} is disconnected.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param disconnectCauseCode The failure code ({@see DisconnectCause}) associated with this
-         *         failed connection.
-         * @param disconnectCauseMessage The reason for the connection failure. This will not be
-         *         displayed to the user.
-         */
-        public void onDisconnected(
-                RemoteConnection connection,
-                int disconnectCauseCode,
-                String disconnectCauseMessage) {}
-
-        /**
-         * Invoked when this {@code RemoteConnection} is requesting ringback. See
-         * {@link #isRequestingRingback()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param ringback Whether the {@code RemoteConnection} is requesting ringback.
-         */
-        public void onRequestingRingback(RemoteConnection connection, boolean ringback) {}
-
-        /**
-         * Indicates that the call capabilities of this {@code RemoteConnection} have changed.
-         * See {@link #getCallCapabilities()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param callCapabilities The new call capabilities of the {@code RemoteConnection}.
-         */
-        public void onCallCapabilitiesChanged(RemoteConnection connection, int callCapabilities) {}
-
-        /**
-         * Invoked when the post-dial sequence in the outgoing {@code Connection} has reached a
-         * pause character. This causes the post-dial signals to stop pending user confirmation. An
-         * implementation should present this choice to the user and invoke
-         * {@link RemoteConnection#postDialContinue(boolean)} when the user makes the choice.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param remainingPostDialSequence The post-dial characters that remain to be sent.
-         */
-        public void onPostDialWait(RemoteConnection connection, String remainingPostDialSequence) {}
-
-        /**
-         * Indicates that the VOIP audio status of this {@code RemoteConnection} has changed.
-         * See {@link #getAudioModeIsVoip()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param isVoip Whether the new audio state of the {@code RemoteConnection} is VOIP.
-         */
-        public void onAudioModeIsVoipChanged(RemoteConnection connection, boolean isVoip) {}
-
-        /**
-         * Indicates that the status hints of this {@code RemoteConnection} have changed. See
-         * {@link #getStatusHints()} ()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param statusHints The new status hints of the {@code RemoteConnection}.
-         */
-        public void onStatusHintsChanged(RemoteConnection connection, StatusHints statusHints) {}
-
-        /**
-         * Indicates that the handle (e.g., phone number) of this {@code RemoteConnection} has
-         * changed. See {@link #getHandle()} and {@link #getHandlePresentation()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param handle The new handle of the {@code RemoteConnection}.
-         * @param presentation The {@link PropertyPresentation} which controls how the
-         *         handle is shown.
-         */
-        public void onHandleChanged(RemoteConnection connection, Uri handle, int presentation) {}
-
-        /**
-         * Indicates that the caller display name of this {@code RemoteConnection} has changed.
-         * See {@link #getCallerDisplayName()} and {@link #getCallerDisplayNamePresentation()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param callerDisplayName The new caller display name of the {@code RemoteConnection}.
-         * @param presentation The {@link PropertyPresentation} which controls how the
-         *         caller display name is shown.
-         */
-        public void onCallerDisplayNameChanged(
-                RemoteConnection connection, String callerDisplayName, int presentation) {}
-
-        /**
-         * Indicates that the video state of this {@code RemoteConnection} has changed.
-         * See {@link #getVideoState()}.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param videoState The new video state of the {@code RemoteConnection}.
-         */
-        public void onVideoStateChanged(RemoteConnection connection, int videoState) {}
-
-        /**
-         * Indicates that this {@code RemoteConnection} is requesting that the in-call UI
-         * launch the specified activity.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         * @param intent A {@link PendingIntent} that the {@code RemoteConnection} wishes to
-         *         have launched on its behalf.
-         */
-        public void onStartActivityFromInCall(RemoteConnection connection, PendingIntent intent) {}
-
-        /**
-         * Indicates that this {@code RemoteConnection} has been destroyed. No further requests
-         * should be made to the {@code RemoteConnection}, and references to it should be cleared.
-         *
-         * @param connection The {@code RemoteConnection} invoking this method.
-         */
-        public void onDestroyed(RemoteConnection connection) {}
-        public void onConferenceableConnectionsChanged(
-                RemoteConnection connection, List<RemoteConnection> conferenceableConnections) {}
-    }
-
-    private IConnectionService mConnectionService;
-    private final String mConnectionId;
-    /**
-     * ConcurrentHashMap constructor params: 8 is initial table size, 0.9f is
-     * load factor before resizing, 1 means we only expect a single thread to
-     * access the map so make only a single shard
-     */
-    private final Set<Listener> mListeners = Collections.newSetFromMap(
-            new ConcurrentHashMap<Listener, Boolean>(8, 0.9f, 1));
-    private final Set<RemoteConnection> mConferenceableConnections = new HashSet<>();
-
-    private int mState = Connection.STATE_NEW;
-    private int mDisconnectCauseCode = DisconnectCause.NOT_VALID;
-    private String mDisconnectCauseMessage;
-    private boolean mRequestingRingback;
-    private boolean mConnected;
-    private int mCallCapabilities;
-    private int mVideoState;
-    private boolean mAudioModeIsVoip;
-    private StatusHints mStatusHints;
-    private Uri mHandle;
-    private int mHandlePresentation;
-    private String mCallerDisplayName;
-    private int mCallerDisplayNamePresentation;
-    private int mFailureCode;
-    private String mFailureMessage;
-
-    /**
-     * @hide
-     */
-    RemoteConnection(
-            String id,
-            IConnectionService connectionService,
-            ConnectionRequest request) {
-        mConnectionId = id;
-        mConnectionService = connectionService;
-        mConnected = true;
-        mState = Connection.STATE_INITIALIZING;
-    }
-
-    /**
-     * Create a RemoteConnection which is used for failed connections. Note that using it for any
-     * "real" purpose will almost certainly fail. Callers should note the failure and act
-     * accordingly (moving on to another RemoteConnection, for example)
-     *
-     * @param failureCode
-     * @param failureMessage
-     */
-    RemoteConnection(int failureCode, String failureMessage) {
-        this("NULL", null, null);
-        mConnected = false;
-        mState = Connection.STATE_FAILED;
-        mFailureCode = failureCode;
-        mFailureMessage = failureMessage;
-    }
-
-    /**
-     * Adds a listener to this {@code RemoteConnection}.
-     *
-     * @param listener A {@code Listener}.
-     */
-    public void addListener(Listener listener) {
-        mListeners.add(listener);
-    }
-
-    /**
-     * Removes a listener from this {@code RemoteConnection}.
-     *
-     * @param listener A {@code Listener}.
-     */
-    public void removeListener(Listener listener) {
-        if (listener != null) {
-            mListeners.remove(listener);
-        }
-    }
-
-    /**
-     * Obtains the parent of this {@code RemoteConnection} in a conference, if any.
-     *
-     * @return The parent {@code RemoteConnection}, or {@code null} if this {@code RemoteConnection}
-     * is not a child of any conference {@code RemoteConnection}s.
-     */
-    public RemoteConnection getParent() { return null; }
-
-    /**
-     * Obtains the children of this conference {@code RemoteConnection}, if any.
-     *
-     * @return The children of this {@code RemoteConnection} if this {@code RemoteConnection} is
-     * a conference, or an empty {@code List} otherwise.
-     */
-    public List<RemoteConnection> getChildren() { return null; }
-
-    /**
-     * Obtains the state of this {@code RemoteConnection}.
-     *
-     * @return A state value, chosen from the {@code STATE_*} constants.
-     */
-    public int getState() {
-        return mState;
-    }
-
-    /**
-     * @return For a {@link Connection#STATE_DISCONNECTED} {@code RemoteConnection}, the
-     * disconnect cause expressed as a code chosen from among those declared in
-     * {@link DisconnectCause}.
-     */
-    public int getDisconnectCauseCode() {
-        return mDisconnectCauseCode;
-    }
-
-    /**
-     * @return For a {@link Connection#STATE_DISCONNECTED} {@code RemoteConnection}, an optional
-     * reason for disconnection expressed as a free text message.
-     */
-    public String getDisconnectCauseMessage() {
-        return mDisconnectCauseMessage;
-    }
-
-    /**
-     * @return A bitmask of the capabilities of the {@code RemoteConnection}, as defined in
-     *         {@link PhoneCapabilities}.
-     */
-    public int getCallCapabilities() {
-        return mCallCapabilities;
-    }
-
-    /**
-     * @return {@code true} if the {@code RemoteConnection}'s current audio mode is VOIP.
-     */
-    public boolean getAudioModeIsVoip() {
-        return mAudioModeIsVoip;
-    }
-
-    /**
-     * @return The current {@link StatusHints} of this {@code RemoteConnection},
-     * or {@code null} if none have been set.
-     */
-    public StatusHints getStatusHints() {
-        return mStatusHints;
-    }
-
-    /**
-     * @return The handle (e.g., phone number) to which the {@code RemoteConnection} is currently
-     * connected.
-     */
-    public Uri getHandle() {
-        return mHandle;
-    }
-
-    /**
-     * @return The presentation requirements for the handle. See
-     * {@link PropertyPresentation} for valid values.
-     */
-    public int getHandlePresentation() {
-        return mHandlePresentation;
-    }
-
-    /**
-     * @return The display name for the caller.
-     */
-    public String getCallerDisplayName() {
-        return mCallerDisplayName;
-    }
-
-    /**
-     * @return The presentation requirements for the caller display name. See
-     * {@link PropertyPresentation} for valid values.
-     */
-    public int getCallerDisplayNamePresentation() {
-        return mCallerDisplayNamePresentation;
-    }
-
-    /**
-     * @return The video state of the {@code RemoteConnection}. See
-     * {@link VideoProfile.VideoState}.
-     */
-    public int getVideoState() {
-        return mVideoState;
-    }
-
-    /**
-     * @return The failure code ({@see DisconnectCause}) associated with this failed
-     * {@code RemoteConnection}.
-     */
-    public int getFailureCode() {
-        return mFailureCode;
-    }
-
-    /**
-     * @return The reason for the connection failure. This will not be displayed to the user.
-     */
-    public String getFailureMessage() {
-        return mFailureMessage;
-    }
-
-    /**
-     * @return Whether the {@code RemoteConnection} is requesting that the framework play a
-     * ringback tone on its behalf.
-     */
-    public boolean isRequestingRingback() {
-        return false;
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to abort.
-     */
-    public void abort() {
-        try {
-            if (mConnected) {
-                mConnectionService.abort(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@link Connection#STATE_RINGING} {@code RemoteConnection} to answer.
-     * @param videoState The video state in which to answer the call.
-     */
-    public void answer(int videoState) {
-        try {
-            if (mConnected) {
-                mConnectionService.answer(mConnectionId, videoState);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@link Connection#STATE_RINGING} {@code RemoteConnection} to reject.
-     */
-    public void reject() {
-        try {
-            if (mConnected) {
-                mConnectionService.reject(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to go on hold.
-     */
-    public void hold() {
-        try {
-            if (mConnected) {
-                mConnectionService.hold(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@link Connection#STATE_HOLDING} call to release from hold.
-     */
-    public void unhold() {
-        try {
-            if (mConnected) {
-                mConnectionService.unhold(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to disconnect.
-     */
-    public void disconnect() {
-        try {
-            if (mConnected) {
-                mConnectionService.disconnect(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to play a dual-tone multi-frequency signaling
-     * (DTMF) tone.
-     *
-     * Any other currently playing DTMF tone in the specified call is immediately stopped.
-     *
-     * @param digit A character representing the DTMF digit for which to play the tone. This
-     *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
-     */
-    public void playDtmfTone(char digit) {
-        try {
-            if (mConnected) {
-                mConnectionService.playDtmfTone(mConnectionId, digit);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to stop any dual-tone multi-frequency signaling
-     * (DTMF) tone currently playing.
-     *
-     * DTMF tones are played by calling {@link #playDtmfTone(char)}. If no DTMF tone is
-     * currently playing, this method will do nothing.
-     */
-    public void stopDtmfTone() {
-        try {
-            if (mConnected) {
-                mConnectionService.stopDtmfTone(mConnectionId);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Instructs this {@code RemoteConnection} to continue playing a post-dial DTMF string.
-     *
-     * A post-dial DTMF string is a string of digits following the first instance of either
-     * {@link TelecommManager#DTMF_CHARACTER_WAIT} or {@link TelecommManager#DTMF_CHARACTER_PAUSE}.
-     * These digits are immediately sent as DTMF tones to the recipient as soon as the
-     * connection is made.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_PAUSE} symbol, this
-     * {@code RemoteConnection} will temporarily pause playing the tones for a pre-defined period
-     * of time.
-     *
-     * If the DTMF string contains a {@link TelecommManager#DTMF_CHARACTER_WAIT} symbol, this
-     * {@code RemoteConnection} will pause playing the tones and notify listeners via
-     * {@link Listener#onPostDialWait(RemoteConnection, String)}. At this point, the in-call app
-     * should display to the user an indication of this state and an affordance to continue
-     * the postdial sequence. When the user decides to continue the postdial sequence, the in-call
-     * app should invoke the {@link #postDialContinue(boolean)} method.
-     *
-     * @param proceed Whether or not to continue with the post-dial sequence.
-     */
-    public void postDialContinue(boolean proceed) {
-        try {
-            if (mConnected) {
-                mConnectionService.onPostDialContinue(mConnectionId, proceed);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * Set the audio state of this {@code RemoteConnection}.
-     *
-     * @param state The audio state of this {@code RemoteConnection}.
-     */
-    public void setAudioState(AudioState state) {
-        try {
-            if (mConnected) {
-                mConnectionService.onAudioStateChanged(mConnectionId, state);
-            }
-        } catch (RemoteException ignored) {
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setState(int state) {
-        if (mState != state) {
-            mState = state;
-            for (Listener l: mListeners) {
-                l.onStateChanged(this, state);
-            }
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setDisconnected(int cause, String message) {
-        if (mState != Connection.STATE_DISCONNECTED) {
-            mState = Connection.STATE_DISCONNECTED;
-            mDisconnectCauseCode = cause;
-            mDisconnectCauseMessage = message;
-
-            for (Listener l : mListeners) {
-                l.onDisconnected(this, cause, message);
-            }
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setRequestingRingback(boolean ringback) {
-        if (mRequestingRingback != ringback) {
-            mRequestingRingback = ringback;
-            for (Listener l : mListeners) {
-                l.onRequestingRingback(this, ringback);
-            }
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setCallCapabilities(int callCapabilities) {
-        mCallCapabilities = callCapabilities;
-        for (Listener l : mListeners) {
-            l.onCallCapabilitiesChanged(this, callCapabilities);
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setDestroyed() {
-        if (!mListeners.isEmpty()) {
-            // Make sure that the listeners are notified that the call is destroyed first.
-            if (mState != Connection.STATE_DISCONNECTED) {
-                setDisconnected(DisconnectCause.ERROR_UNSPECIFIED, "Connection destroyed.");
-            }
-
-            for (Listener l : mListeners) {
-                l.onDestroyed(this);
-            }
-            mListeners.clear();
-
-            mConnected = false;
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setPostDialWait(String remainingDigits) {
-        for (Listener l : mListeners) {
-            l.onPostDialWait(this, remainingDigits);
-        }
-    }
-
-    /**
-     * @hide
-     */
-    void setVideoState(int videoState) {
-        mVideoState = videoState;
-        for (Listener l : mListeners) {
-            l.onVideoStateChanged(this, videoState);
-        }
-    }
-
-    /** @hide */
-    void setAudioModeIsVoip(boolean isVoip) {
-        mAudioModeIsVoip = isVoip;
-        for (Listener l : mListeners) {
-            l.onAudioModeIsVoipChanged(this, isVoip);
-        }
-    }
-
-    /** @hide */
-    void setStatusHints(StatusHints statusHints) {
-        mStatusHints = statusHints;
-        for (Listener l : mListeners) {
-            l.onStatusHintsChanged(this, statusHints);
-        }
-    }
-
-    /** @hide */
-    void setHandle(Uri handle, int presentation) {
-        mHandle = handle;
-        mHandlePresentation = presentation;
-        for (Listener l : mListeners) {
-            l.onHandleChanged(this, handle, presentation);
-        }
-    }
-
-    /** @hide */
-    void setCallerDisplayName(String callerDisplayName, int presentation) {
-        mCallerDisplayName = callerDisplayName;
-        mCallerDisplayNamePresentation = presentation;
-        for (Listener l : mListeners) {
-            l.onCallerDisplayNameChanged(this, callerDisplayName, presentation);
-        }
-    }
-
-    /** @hide */
-    void startActivityFromInCall(PendingIntent intent) {
-        for (Listener l : mListeners) {
-            l.onStartActivityFromInCall(this, intent);
-        }
-    }
-
-    /** @hide */
-    void setConferenceableConnections(List<RemoteConnection> conferenceableConnections) {
-        mConferenceableConnections.clear();
-        mConferenceableConnections.addAll(conferenceableConnections);
-        for (Listener l : mListeners) {
-            l.onConferenceableConnectionsChanged(
-                    this, new ArrayList<RemoteConnection>(mConferenceableConnections));
-        }
-    }
-
-    /**
-     * Create a RemoteConnection which is in the {@link Connection#STATE_FAILED} state. Attempting
-     * to use it for anything will almost certainly result in bad things happening. Do not do this.
-     *
-     * @return a failed {@link RemoteConnection}
-     *
-     * @hide
-     */
-    public static RemoteConnection failure(int failureCode, String failureMessage) {
-        return new RemoteConnection(failureCode, failureMessage);
-    }
-}
diff --git a/telecomm/java/android/telecomm/RemoteConnectionManager.java b/telecomm/java/android/telecomm/RemoteConnectionManager.java
deleted file mode 100644
index 365ed5b..0000000
--- a/telecomm/java/android/telecomm/RemoteConnectionManager.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2014 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
- R* limitations under the License.
- */
-
-package android.telecomm;
-
-import android.content.ComponentName;
-import android.os.RemoteException;
-
-import com.android.internal.telecomm.IConnectionService;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * @hide
- */
-public class RemoteConnectionManager {
-    private Map<ComponentName, RemoteConnectionService> mRemoteConnectionServices = new HashMap<>();
-
-    void addConnectionService(ComponentName componentName, IConnectionService connectionService) {
-        if (!mRemoteConnectionServices.containsKey(componentName)) {
-            try {
-                RemoteConnectionService remoteConnectionService =
-                        new RemoteConnectionService(connectionService);
-                mRemoteConnectionServices.put(componentName, remoteConnectionService);
-            } catch (RemoteException ignored) {
-            }
-        }
-    }
-
-    public RemoteConnection createRemoteConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request,
-            boolean isIncoming) {
-        PhoneAccountHandle accountHandle = request.getAccountHandle();
-        if (accountHandle == null) {
-            throw new IllegalArgumentException("accountHandle must be specified.");
-        }
-
-        ComponentName componentName = request.getAccountHandle().getComponentName();
-        if (!mRemoteConnectionServices.containsKey(componentName)) {
-            throw new UnsupportedOperationException("accountHandle not supported: "
-                    + componentName);
-        }
-
-        RemoteConnectionService remoteService = mRemoteConnectionServices.get(componentName);
-        if (remoteService != null) {
-            return remoteService.createRemoteConnection(
-                    connectionManagerPhoneAccount, request, isIncoming);
-        }
-        return null;
-    }
-}
diff --git a/telecomm/java/android/telecomm/RemoteConnectionService.java b/telecomm/java/android/telecomm/RemoteConnectionService.java
deleted file mode 100644
index 9a1729f..0000000
--- a/telecomm/java/android/telecomm/RemoteConnectionService.java
+++ /dev/null
@@ -1,299 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.os.IBinder;
-import android.os.IBinder.DeathRecipient;
-import android.os.RemoteException;
-import android.telephony.DisconnectCause;
-
-import com.android.internal.telecomm.IConnectionService;
-import com.android.internal.telecomm.IConnectionServiceAdapter;
-import com.android.internal.telecomm.IVideoProvider;
-import com.android.internal.telecomm.RemoteServiceCallback;
-
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Map;
-import java.util.Set;
-import java.util.Collections;
-import java.util.List;
-import java.util.UUID;
-
-/**
- * Remote connection service which other connection services can use to place calls on their behalf.
- *
- * @hide
- */
-final class RemoteConnectionService {
-
-    private static final RemoteConnection
-            NULL_CONNECTION = new RemoteConnection("NULL", null, null);
-
-    private final IConnectionServiceAdapter mServantDelegate = new IConnectionServiceAdapter() {
-        @Override
-        public void handleCreateConnectionSuccessful(
-                String id,
-                ConnectionRequest request,
-                ParcelableConnection parcel) {
-            RemoteConnection connection =
-                    findConnectionForAction(id, "handleCreateConnectionSuccessful");
-            if (connection != NULL_CONNECTION && mPendingConnections.contains(connection)) {
-                mPendingConnections.remove(connection);
-                connection.setState(parcel.getState());
-                connection.setCallCapabilities(parcel.getCapabilities());
-                connection.setHandle(
-                        parcel.getHandle(), parcel.getHandlePresentation());
-                connection.setCallerDisplayName(
-                        parcel.getCallerDisplayName(),
-                        parcel.getCallerDisplayNamePresentation());
-                // TODO: Do we need to support video providers for remote connections?
-            }
-        }
-
-        @Override
-        public void handleCreateConnectionFailed(
-                String id,
-                ConnectionRequest request,
-                int errorCode,
-                String errorMessage) {
-            // TODO: How do we propagate the failure codes?
-            findConnectionForAction(id, "handleCreateConnectionFailed")
-                    .setDestroyed();
-        }
-
-        @Override
-        public void handleCreateConnectionCancelled(
-                String id,
-                ConnectionRequest request) {
-            findConnectionForAction(id, "handleCreateConnectionCancelled")
-                    .setDestroyed();
-        }
-
-        @Override
-        public void setActive(String callId) {
-            findConnectionForAction(callId, "setActive")
-                    .setState(Connection.STATE_ACTIVE);
-        }
-
-        @Override
-        public void setRinging(String callId) {
-            findConnectionForAction(callId, "setRinging")
-                    .setState(Connection.STATE_RINGING);
-        }
-
-        @Override
-        public void setDialing(String callId) {
-            findConnectionForAction(callId, "setDialing")
-                    .setState(Connection.STATE_DIALING);
-        }
-
-        @Override
-        public void setDisconnected(String callId, int disconnectCause,
-                String disconnectMessage) {
-            findConnectionForAction(callId, "setDisconnected")
-                    .setDisconnected(disconnectCause, disconnectMessage);
-        }
-
-        @Override
-        public void setOnHold(String callId) {
-            findConnectionForAction(callId, "setOnHold")
-                    .setState(Connection.STATE_HOLDING);
-        }
-
-        @Override
-        public void setRequestingRingback(String callId, boolean ringing) {
-            findConnectionForAction(callId, "setRequestingRingback")
-                    .setRequestingRingback(ringing);
-        }
-
-        @Override
-        public void setCallCapabilities(String callId, int callCapabilities) {
-            findConnectionForAction("callId", "setCallCapabilities")
-                    .setCallCapabilities(callCapabilities);
-        }
-
-        @Override
-        public void setIsConferenced(String callId, String conferenceCallId) {
-            // not supported for remote connections.
-        }
-
-        @Override
-        public void addConferenceCall(String callId) {
-            // not supported for remote connections.
-        }
-
-        @Override
-        public void removeCall(String callId) {
-            findConnectionForAction(callId, "removeCall")
-                    .setDestroyed();
-        }
-
-        @Override
-        public void onPostDialWait(String callId, String remaining) {
-            findConnectionForAction(callId, "onPostDialWait")
-                    .setPostDialWait(remaining);
-        }
-
-        @Override
-        public void queryRemoteConnectionServices(RemoteServiceCallback callback) {
-            // Not supported from remote connection service.
-        }
-
-        @Override
-        public void setVideoProvider(String callId, IVideoProvider videoProvider) {
-            // not supported for remote connections.
-        }
-
-        @Override
-        public void setVideoState(String callId, int videoState) {
-            findConnectionForAction(callId, "setVideoState")
-                    .setVideoState(videoState);
-        }
-
-        @Override
-        public void setAudioModeIsVoip(String callId, boolean isVoip) {
-            findConnectionForAction(callId, "setAudioModeIsVoip")
-                    .setAudioModeIsVoip(isVoip);
-        }
-
-        @Override
-        public void setStatusHints(String callId, StatusHints statusHints) {
-            findConnectionForAction(callId, "setStatusHints")
-                    .setStatusHints(statusHints);
-        }
-
-        @Override
-        public void setHandle(String callId, Uri handle, int presentation) {
-            findConnectionForAction(callId, "setHandle")
-                    .setHandle(handle, presentation);
-        }
-
-        @Override
-        public void setCallerDisplayName(String callId, String callerDisplayName,
-                int presentation) {
-            findConnectionForAction(callId, "setCallerDisplayName")
-                    .setCallerDisplayName(callerDisplayName, presentation);
-        }
-
-        @Override
-        public void startActivityFromInCall(String callId, PendingIntent intent) {
-            findConnectionForAction(callId, "startActivityFromInCall")
-                    .startActivityFromInCall(intent);
-        }
-
-        @Override
-        public IBinder asBinder() {
-            throw new UnsupportedOperationException();
-        }
-
-        @Override
-        public final void setConferenceableConnections(
-                String callId, List<String> conferenceableConnectionIds) {
-
-            // TODO: When we support more than 1 remote connection, this should
-            // loop through the incoming list of connection IDs and acquire the list
-            // of remote connections which correspond to the IDs. That list should
-            // be set onto the remote connections.
-            findConnectionForAction(callId, "setConferenceableConnections")
-                    .setConferenceableConnections(Collections.<RemoteConnection>emptyList());
-        }
-    };
-
-    private final ConnectionServiceAdapterServant mServant =
-            new ConnectionServiceAdapterServant(mServantDelegate);
-
-    private final DeathRecipient mDeathRecipient = new DeathRecipient() {
-        @Override
-        public void binderDied() {
-            for (RemoteConnection c : mConnectionById.values()) {
-                c.setDestroyed();
-            }
-            mConnectionById.clear();
-            mPendingConnections.clear();
-            mConnectionService.asBinder().unlinkToDeath(mDeathRecipient, 0);
-        }
-    };
-
-    private final IConnectionService mConnectionService;
-    private final Map<String, RemoteConnection> mConnectionById = new HashMap<>();
-    private final Set<RemoteConnection> mPendingConnections = new HashSet<>();
-
-    RemoteConnectionService(IConnectionService connectionService) throws RemoteException {
-        mConnectionService = connectionService;
-        mConnectionService.asBinder().linkToDeath(mDeathRecipient, 0);
-    }
-
-    @Override
-    public String toString() {
-        return "[RemoteCS - " + mConnectionService.asBinder().toString() + "]";
-    }
-
-    final RemoteConnection createRemoteConnection(
-            PhoneAccountHandle connectionManagerPhoneAccount,
-            ConnectionRequest request,
-            boolean isIncoming) {
-        final String id = UUID.randomUUID().toString();
-        final ConnectionRequest newRequest = new ConnectionRequest(
-                request.getAccountHandle(),
-                request.getHandle(),
-                request.getHandlePresentation(),
-                request.getExtras(),
-                request.getVideoState());
-        try {
-            if (mConnectionById.isEmpty()) {
-                mConnectionService.addConnectionServiceAdapter(mServant.getStub());
-            }
-            RemoteConnection connection =
-                    new RemoteConnection(id, mConnectionService, newRequest);
-            mPendingConnections.add(connection);
-            mConnectionById.put(id, connection);
-            mConnectionService.createConnection(
-                    connectionManagerPhoneAccount,
-                    id,
-                    newRequest,
-                    isIncoming);
-            connection.addListener(new RemoteConnection.Listener() {
-                @Override
-                public void onDestroyed(RemoteConnection connection) {
-                    mConnectionById.remove(id);
-                    if (mConnectionById.isEmpty()) {
-                        try {
-                            mConnectionService.removeConnectionServiceAdapter(mServant.getStub());
-                        } catch (RemoteException e) {
-                        }
-                    }
-                }
-            });
-            return connection;
-        } catch (RemoteException e) {
-            return RemoteConnection
-                    .failure(DisconnectCause.ERROR_UNSPECIFIED, e.toString());
-        }
-    }
-
-    private RemoteConnection findConnectionForAction(
-            String callId, String action) {
-        if (mConnectionById.containsKey(callId)) {
-            return mConnectionById.get(callId);
-        }
-        Log.w(this, "%s - Cannot find Connection %s", action, callId);
-        return NULL_CONNECTION;
-    }
-}
diff --git a/telecomm/java/android/telecomm/Response.java b/telecomm/java/android/telecomm/Response.java
deleted file mode 100644
index f879756..0000000
--- a/telecomm/java/android/telecomm/Response.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-/**
- * <strong>OBSOLETE</strong> Used to inform a client of asynchronously returned results.
- * <p>
- * <strong>TODO:</strong> Remove onCreateConferenceConnection() async method
- * then delete this interface.
- */
-public interface Response<IN, OUT> {
-
-    /**
-     * Provide a set of results.
-     *
-     * @param request The original request.
-     * @param result The results.
-     */
-    void onResult(IN request, OUT... result);
-
-    /**
-     * Indicates the inability to provide results.
-     *
-     * @param request The original request.
-     * @param code An integer code indicating the reason for failure.
-     * @param msg A message explaining the reason for failure.
-     */
-    void onError(IN request, int code, String msg);
-}
diff --git a/telecomm/java/android/telecomm/StatusHints.aidl b/telecomm/java/android/telecomm/StatusHints.aidl
deleted file mode 100644
index 22da293..0000000
--- a/telecomm/java/android/telecomm/StatusHints.aidl
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2008 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 android.telecomm;
-
-/**
- * {@hide}
-  */
-parcelable StatusHints;
diff --git a/telecomm/java/android/telecomm/StatusHints.java b/telecomm/java/android/telecomm/StatusHints.java
deleted file mode 100644
index f7c4f2f..0000000
--- a/telecomm/java/android/telecomm/StatusHints.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.content.ComponentName;
-import android.content.Context;
-import android.content.pm.PackageManager;
-import android.graphics.drawable.Drawable;
-import android.os.Bundle;
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import java.util.MissingResourceException;
-import java.util.Objects;
-
-/**
- * Contains status label and icon displayed in the in-call UI.
- */
-public final class StatusHints implements Parcelable {
-
-    private final ComponentName mComponentName;
-    private final CharSequence mLabel;
-    private final int mIconResId;
-    private final Bundle mExtras;
-
-    public StatusHints(ComponentName componentName, CharSequence label, int iconResId, Bundle extras) {
-        mComponentName = componentName;
-        mLabel = label;
-        mIconResId = iconResId;
-        mExtras = extras;
-    }
-
-    /**
-     * @return A component used to load the icon.
-     */
-    public ComponentName getComponentName() {
-        return mComponentName;
-    }
-
-    /**
-     * @return The label displayed in the in-call UI.
-     */
-    public CharSequence getLabel() {
-        return mLabel;
-    }
-
-    /**
-     * The icon resource ID for the icon to show.
-     *
-     * @return A resource ID.
-     */
-    public int getIconResId() {
-        return mIconResId;
-    }
-
-    /**
-     * @return An icon displayed in the in-call UI.
-     */
-    public Drawable getIcon(Context context) {
-        return getIcon(context, mIconResId);
-    }
-
-    /**
-     * @return Extra data used to display status.
-     */
-    public Bundle getExtras() {
-        return mExtras;
-    }
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeParcelable(mComponentName, flags);
-        out.writeCharSequence(mLabel);
-        out.writeInt(mIconResId);
-        out.writeParcelable(mExtras, 0);
-    }
-
-    public static final Creator<StatusHints> CREATOR
-            = new Creator<StatusHints>() {
-        public StatusHints createFromParcel(Parcel in) {
-            return new StatusHints(in);
-        }
-
-        public StatusHints[] newArray(int size) {
-            return new StatusHints[size];
-        }
-    };
-
-    private StatusHints(Parcel in) {
-        mComponentName = in.readParcelable(getClass().getClassLoader());
-        mLabel = in.readCharSequence();
-        mIconResId = in.readInt();
-        mExtras = in.readParcelable(getClass().getClassLoader());
-    }
-
-    private Drawable getIcon(Context context, int resId) {
-        Context packageContext;
-        try {
-            packageContext = context.createPackageContext(mComponentName.getPackageName(), 0);
-        } catch (PackageManager.NameNotFoundException e) {
-            Log.e(this, e, "Cannot find package %s", mComponentName.getPackageName());
-            return null;
-        }
-        try {
-            return packageContext.getDrawable(resId);
-        } catch (MissingResourceException e) {
-            Log.e(this, e, "Cannot find icon %d in package %s",
-                    resId, mComponentName.getPackageName());
-            return null;
-        }
-    }
-
-    @Override
-    public boolean equals(Object other) {
-        if (other != null && other instanceof StatusHints) {
-            StatusHints otherHints = (StatusHints) other;
-            return Objects.equals(otherHints.getComponentName(), getComponentName()) &&
-                    Objects.equals(otherHints.getLabel(), getLabel()) &&
-                    otherHints.getIconResId() == getIconResId() &&
-                    Objects.equals(otherHints.getExtras(), getExtras());
-        }
-        return false;
-    }
-
-    @Override
-    public int hashCode() {
-        return Objects.hashCode(mComponentName) + Objects.hashCode(mLabel) + mIconResId +
-                Objects.hashCode(mExtras);
-    }
-}
diff --git a/telecomm/java/android/telecomm/TelecommManager.java b/telecomm/java/android/telecomm/TelecommManager.java
deleted file mode 100644
index 5192b0f..0000000
--- a/telecomm/java/android/telecomm/TelecommManager.java
+++ /dev/null
@@ -1,554 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.annotation.SystemApi;
-import android.content.ComponentName;
-import android.content.Context;
-
-import android.os.Bundle;
-import android.os.RemoteException;
-import android.os.ServiceManager;
-import android.util.Log;
-
-import com.android.internal.telecomm.ITelecommService;
-
-import java.util.List;
-
-/**
- * Provides access to Telecomm-related functionality.
- * TODO: Move this all into PhoneManager.
- */
-public class TelecommManager {
-
-    /**
-     * Activity action: Starts the UI for handing an incoming call. This intent starts the in-call
-     * UI by notifying the Telecomm system that an incoming call exists for a specific call service
-     * (see {@link android.telecomm.ConnectionService}). Telecomm reads the Intent extras to find
-     * and bind to the appropriate {@link android.telecomm.ConnectionService} which Telecomm will
-     * ultimately use to control and get information about the call.
-     * <p>
-     * Input: get*Extra field {@link #EXTRA_PHONE_ACCOUNT_HANDLE} contains the component name of the
-     * {@link android.telecomm.ConnectionService} that Telecomm should bind to. Telecomm will then
-     * ask the connection service for more information about the call prior to showing any UI.
-     *
-     * @hide
-     */
-    public static final String ACTION_INCOMING_CALL = "android.intent.action.INCOMING_CALL";
-
-    /**
-     * The {@link android.content.Intent} action used to configure a
-     * {@link android.telecomm.ConnectionService}.
-     */
-    public static final String ACTION_CONNECTION_SERVICE_CONFIGURE =
-            "android.intent.action.CONNECTION_SERVICE_CONFIGURE";
-
-    /**
-     * The {@link android.content.Intent} action used to show the call settings page.
-     */
-    public static final String ACTION_SHOW_CALL_SETTINGS =
-            "android.telecomm.intent.action.SHOW_CALL_SETTINGS";
-
-    /**
-     * Optional extra for {@link android.content.Intent#ACTION_CALL} containing a boolean that
-     * determines whether the speakerphone should be automatically turned on for an outgoing call.
-     */
-    public static final String EXTRA_START_CALL_WITH_SPEAKERPHONE =
-            "android.intent.extra.START_CALL_WITH_SPEAKERPHONE";
-
-    /**
-     * Optional extra for {@link android.content.Intent#ACTION_CALL} containing an integer that
-     * determines the desired video state for an outgoing call.
-     * Valid options:
-     * {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#RX_ENABLED},
-     * {@link VideoProfile.VideoState#TX_ENABLED}.
-     */
-    public static final String EXTRA_START_CALL_WITH_VIDEO_STATE =
-            "android.intent.extra.START_CALL_WITH_VIDEO_STATE";
-
-    /**
-     * The extra used with an {@link android.content.Intent#ACTION_CALL} and
-     * {@link android.content.Intent#ACTION_DIAL} {@code Intent} to specify a
-     * {@link PhoneAccountHandle} to use when making the call.
-     * <p class="note">
-     * Retrieve with {@link android.content.Intent#getParcelableExtra(String)}.
-     */
-    public static final String EXTRA_PHONE_ACCOUNT_HANDLE =
-            "android.intent.extra.PHONE_ACCOUNT_HANDLE";
-
-    /**
-     * Optional extra for {@link #ACTION_INCOMING_CALL} containing a {@link Bundle} which contains
-     * metadata about the call. This {@link Bundle} will be returned to the
-     * {@link ConnectionService}.
-     *
-     * @hide
-     */
-    public static final String EXTRA_INCOMING_CALL_EXTRAS =
-            "android.intent.extra.INCOMING_CALL_EXTRAS";
-
-    /**
-     * Optional extra for {@link android.content.Intent#ACTION_CALL} and
-     * {@link android.content.Intent#ACTION_DIAL} {@code Intent} containing a {@link Bundle}
-     * which contains metadata about the call. This {@link Bundle} will be saved into
-     * {@code Call.Details}.
-     *
-     * @hide
-     */
-    public static final String EXTRA_OUTGOING_CALL_EXTRAS =
-            "android.intent.extra.OUTGOING_CALL_EXTRAS";
-
-    /**
-     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
-     * containing the disconnect code.
-     */
-    public static final String EXTRA_CALL_DISCONNECT_CAUSE =
-            "android.telecomm.extra.CALL_DISCONNECT_CAUSE";
-
-    /**
-     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
-     * containing the disconnect message.
-     */
-    public static final String EXTRA_CALL_DISCONNECT_MESSAGE =
-            "android.telecomm.extra.CALL_DISCONNECT_MESSAGE";
-
-    /**
-     * Optional extra for {@link android.telephony.TelephonyManager#ACTION_PHONE_STATE_CHANGED}
-     * containing the component name of the associated connection service.
-     */
-    public static final String EXTRA_CONNECTION_SERVICE =
-            "android.telecomm.extra.CONNECTION_SERVICE";
-
-    /**
-     * The number which the party on the other side of the line will see (and use to return the
-     * call).
-     * <p>
-     * {@link ConnectionService}s which interact with {@link RemoteConnection}s should only populate
-     * this if the {@link android.telephony.TelephonyManager#getLine1Number()} value, as that is the
-     * user's expected caller ID.
-     */
-    public static final String EXTRA_CALL_BACK_NUMBER = "android.telecomm.extra.CALL_BACK_NUMBER";
-
-    /**
-     * The dual tone multi-frequency signaling character sent to indicate the dialing system should
-     * pause for a predefined period.
-     */
-    public static final char DTMF_CHARACTER_PAUSE = ',';
-
-    /**
-     * The dual-tone multi-frequency signaling character sent to indicate the dialing system should
-     * wait for user confirmation before proceeding.
-     */
-    public static final char DTMF_CHARACTER_WAIT = ';';
-
-    /**
-     * TTY (teletypewriter) mode is off.
-     *
-     * @hide
-     */
-    public static final int TTY_MODE_OFF = 0;
-
-    /**
-     * TTY (teletypewriter) mode is on. The speaker is off and the microphone is muted. The user
-     * will communicate with the remote party by sending and receiving text messages.
-     *
-     * @hide
-     */
-    public static final int TTY_MODE_FULL = 1;
-
-    /**
-     * TTY (teletypewriter) mode is in hearing carryover mode (HCO). The microphone is muted but the
-     * speaker is on. The user will communicate with the remote party by sending text messages and
-     * hearing an audible reply.
-     *
-     * @hide
-     */
-    public static final int TTY_MODE_HCO = 2;
-
-    /**
-     * TTY (teletypewriter) mode is in voice carryover mode (VCO). The speaker is off but the
-     * microphone is still on. User will communicate with the remote party by speaking and receiving
-     * text message replies.
-     *
-     * @hide
-     */
-    public static final int TTY_MODE_VCO = 3;
-
-    /**
-     * Broadcast intent action indicating that the current TTY mode has changed. An intent extra
-     * provides this state as an int.
-     *
-     * @see #EXTRA_CURRENT_TTY_MODE
-     * @hide
-     */
-    public static final String ACTION_CURRENT_TTY_MODE_CHANGED =
-            "android.telecomm.intent.action.CURRENT_TTY_MODE_CHANGED";
-
-    /**
-     * The lookup key for an int that indicates the current TTY mode.
-     * Valid modes are:
-     * - {@link #TTY_MODE_OFF}
-     * - {@link #TTY_MODE_FULL}
-     * - {@link #TTY_MODE_HCO}
-     * - {@link #TTY_MODE_VCO}
-     *
-     * @hide
-     */
-    public static final String EXTRA_CURRENT_TTY_MODE =
-            "android.telecomm.intent.extra.CURRENT_TTY_MODE";
-
-    /**
-     * Broadcast intent action indicating that the TTY preferred operating mode has changed. An
-     * intent extra provides the new mode as an int.
-     *
-     * @see #EXTRA_TTY_PREFERRED_MODE
-     * @hide
-     */
-    public static final String ACTION_TTY_PREFERRED_MODE_CHANGED =
-            "android.telecomm.intent.action.TTY_PREFERRED_MODE_CHANGED";
-
-    /**
-     * The lookup key for an int that indicates preferred TTY mode. Valid modes are: -
-     * {@link #TTY_MODE_OFF} - {@link #TTY_MODE_FULL} - {@link #TTY_MODE_HCO} -
-     * {@link #TTY_MODE_VCO}
-     *
-     * @hide
-     */
-    public static final String EXTRA_TTY_PREFERRED_MODE =
-            "android.telecomm.intent.extra.TTY_PREFERRED";
-
-    private static final String TAG = "TelecommManager";
-
-    private static final String TELECOMM_SERVICE_NAME = "telecomm";
-
-    private final Context mContext;
-
-    /**
-     * @hide
-     */
-    public static TelecommManager from(Context context) {
-        return (TelecommManager) context.getSystemService(Context.TELECOMM_SERVICE);
-    }
-
-    /**
-     * @hide
-     */
-    public TelecommManager(Context context) {
-        Context appContext = context.getApplicationContext();
-        if (appContext != null) {
-            mContext = appContext;
-        } else {
-            mContext = context;
-        }
-    }
-
-    /**
-     * Return the {@link PhoneAccount} which is the user-chosen default for making outgoing phone
-     * calls. This {@code PhoneAccount} will always be a member of the list which is returned from
-     * calling {@link #getEnabledPhoneAccounts()}.
-     * <p>
-     * Apps must be prepared for this method to return {@code null}, indicating that there currently
-     * exists no user-chosen default {@code PhoneAccount}. In this case, apps wishing to initiate a
-     * phone call must either create their {@link android.content .Intent#ACTION_CALL} or
-     * {@link android.content.Intent#ACTION_DIAL} {@code Intent} with no
-     * {@link TelecommManager#EXTRA_PHONE_ACCOUNT_HANDLE}, or present the user with an affordance to
-     * select one of the elements of {@link #getEnabledPhoneAccounts()}.
-     * <p>
-     * An {@link android.content.Intent#ACTION_CALL} or {@link android.content.Intent#ACTION_DIAL}
-     * {@code Intent} with no {@link TelecommManager#EXTRA_PHONE_ACCOUNT_HANDLE} is valid, and
-     * subsequent steps in the phone call flow are responsible for presenting the user with an
-     * affordance, if necessary, to choose a {@code PhoneAccount}.
-     */
-    public PhoneAccountHandle getDefaultOutgoingPhoneAccount() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().getDefaultOutgoingPhoneAccount();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getDefaultOutgoingPhoneAccount", e);
-        }
-        return null;
-    }
-
-    /**
-     * Return a list of {@link PhoneAccountHandle}s which can be used to make and receive phone
-     * calls.
-     *
-     * @see #EXTRA_PHONE_ACCOUNT_HANDLE
-     * @return A list of {@code PhoneAccountHandle} objects.
-     */
-    public List<PhoneAccountHandle> getEnabledPhoneAccounts() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().getOutgoingPhoneAccounts();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getOutgoingPhoneAccounts", e);
-        }
-        return null;
-    }
-
-    /**
-     * Determine whether the device has more than one account registered and enabled.
-     *
-     * @return {@code true} if the device has more than one account registered and enabled and
-     * {@code false} otherwise.
-     */
-    public boolean hasMultipleEnabledAccounts() {
-        return getEnabledPhoneAccounts().size() > 1;
-    }
-
-    /**
-     * Return the {@link PhoneAccount} for a specified {@link PhoneAccountHandle}. Object includes
-     * resources which can be used in a user interface.
-     *
-     * @param account The {@link PhoneAccountHandle}.
-     * @return The {@link PhoneAccount} object.
-     */
-    public PhoneAccount getPhoneAccount(PhoneAccountHandle account) {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().getPhoneAccount(account);
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getPhoneAccount", e);
-        }
-        return null;
-    }
-
-    /**
-     * Register a {@link PhoneAccount} for use by the system.
-     *
-     * @param account The complete {@link PhoneAccount}.
-     */
-    public void registerPhoneAccount(PhoneAccount account) {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().registerPhoneAccount(account);
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#registerPhoneAccount", e);
-        }
-    }
-
-    /**
-     * Remove a {@link PhoneAccount} registration from the system.
-     *
-     * @param accountHandle A {@link PhoneAccountHandle} for the {@link PhoneAccount} to unregister.
-     */
-    public void unregisterPhoneAccount(PhoneAccountHandle accountHandle) {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().unregisterPhoneAccount(accountHandle);
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#unregisterPhoneAccount", e);
-        }
-    }
-
-    /**
-     * Remove all Accounts for a given package from the system.
-     *
-     * @param packageName A package name that may have registered Accounts.
-     */
-    @SystemApi
-    public void clearAccounts(String packageName) {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().clearAccounts(packageName);
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#clearAccounts", e);
-        }
-    }
-
-    /**
-     * @hide
-     */
-    @SystemApi
-    public ComponentName getDefaultPhoneApp() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().getDefaultPhoneApp();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get the default phone app.", e);
-        }
-        return null;
-    }
-
-    /**
-     * Returns whether there is an ongoing phone call (can be in dialing, ringing, active or holding
-     * states).
-     *
-     * @hide
-     */
-    @SystemApi
-    public boolean isInAPhoneCall() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().isInAPhoneCall();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get default phone app.", e);
-        }
-        return false;
-    }
-
-    /**
-     * Returns whether there currently exists is a ringing incoming-call.
-     *
-     * @hide
-     */
-    @SystemApi
-    public boolean isRinging() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().isRinging();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get ringing state of phone app.", e);
-        }
-        return false;
-    }
-
-    /**
-     * Ends an ongoing call.
-     * TODO: L-release - need to convert all invocations of ITelecommService#endCall to use this
-     * method (clockwork & gearhead).
-     * @hide
-     */
-    @SystemApi
-    public boolean endCall() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().endCall();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#endCall", e);
-        }
-        return false;
-    }
-
-    /**
-     * If there is a ringing incoming call, this method accepts the call on behalf of the user.
-     * TODO: L-release - need to convert all invocation of ITelecommService#answerRingingCall to use
-     * this method (clockwork & gearhead).
-     *
-     * @hide
-     */
-    @SystemApi
-    public void acceptRingingCall() {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().acceptRingingCall();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#acceptRingingCall", e);
-        }
-    }
-
-    /**
-     * Silences the ringer if a ringing call exists.
-     *
-     * @hide
-     */
-    @SystemApi
-    public void silenceRinger() {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().silenceRinger();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#silenceRinger", e);
-        }
-    }
-
-    /**
-     * Returns whether TTY is supported on this device.
-     *
-     * @hide
-     */
-    @SystemApi
-    public boolean isTtySupported() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().isTtySupported();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get TTY supported state.", e);
-        }
-        return false;
-    }
-
-    /**
-     * Returns the current TTY mode of the device. For TTY to be on the user must enable it in
-     * settings and have a wired headset plugged in.
-     * Valid modes are:
-     * - {@link TelecommManager#TTY_MODE_OFF}
-     * - {@link TelecommManager#TTY_MODE_FULL}
-     * - {@link TelecommManager#TTY_MODE_HCO}
-     * - {@link TelecommManager#TTY_MODE_VCO}
-     * @hide
-     */
-    public int getCurrentTtyMode() {
-        try {
-            if (isServiceConnected()) {
-                return getTelecommService().getCurrentTtyMode();
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get the current TTY mode.", e);
-        }
-        return TTY_MODE_OFF;
-    }
-
-    /**
-     * Registers a new incoming call. A {@link ConnectionService} should invoke this method when it
-     * has an incoming call. The specified {@link PhoneAccountHandle} must have been registered
-     * with {@link #registerPhoneAccount} and subsequently enabled by the user within the phone's
-     * settings. Once invoked, this method will cause the system to bind to the
-     * {@link ConnectionService} associated with the {@link PhoneAccountHandle} and request
-     * additional information about the call (See
-     * {@link ConnectionService#onCreateIncomingConnection}) before starting the incoming call UI.
-     *
-     * @param phoneAccount A {@link PhoneAccountHandle} registered with
-     *            {@link #registerPhoneAccount}.
-     * @param extras A bundle that will be passed through to
-     *            {@link ConnectionService#onCreateIncomingConnection}.
-     */
-    public void addNewIncomingCall(PhoneAccountHandle phoneAccount, Bundle extras) {
-        try {
-            if (isServiceConnected()) {
-                getTelecommService().addNewIncomingCall(
-                        phoneAccount, extras == null ? new Bundle() : extras);
-            }
-        } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException adding a new incoming call: " + phoneAccount, e);
-        }
-    }
-
-    private ITelecommService getTelecommService() {
-        return ITelecommService.Stub.asInterface(ServiceManager.getService(TELECOMM_SERVICE_NAME));
-    }
-
-    private boolean isServiceConnected() {
-        boolean isConnected = getTelecommService() != null;
-        if (!isConnected) {
-            Log.w(TAG, "Telecomm Service not found.");
-        }
-        return isConnected;
-    }
-}
diff --git a/telecomm/java/android/telecomm/VideoCallImpl.java b/telecomm/java/android/telecomm/VideoCallImpl.java
deleted file mode 100644
index c10865f..0000000
--- a/telecomm/java/android/telecomm/VideoCallImpl.java
+++ /dev/null
@@ -1,247 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.os.Handler;
-import android.os.IBinder;
-import android.os.Looper;
-import android.os.Message;
-import android.os.RemoteException;
-import android.telecomm.InCallService.VideoCall;
-import android.view.Surface;
-
-import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IVideoCallback;
-import com.android.internal.telecomm.IVideoProvider;
-
-/**
- * Implementation of a Video Call, which allows InCallUi to communicate commands to the underlying
- * {@link Connection.VideoProvider}, and direct callbacks from the
- * {@link Connection.VideoProvider} to the appropriate {@link VideoCall.Listener}.
- *
- * {@hide}
- */
-public class VideoCallImpl extends VideoCall {
-    private static final int MSG_RECEIVE_SESSION_MODIFY_REQUEST = 1;
-    private static final int MSG_RECEIVE_SESSION_MODIFY_RESPONSE = 2;
-    private static final int MSG_HANDLE_CALL_SESSION_EVENT = 3;
-    private static final int MSG_CHANGE_PEER_DIMENSIONS = 4;
-    private static final int MSG_CHANGE_CALL_DATA_USAGE = 5;
-    private static final int MSG_CHANGE_CAMERA_CAPABILITIES = 6;
-
-    private final IVideoProvider mVideoProvider;
-    private final VideoCallListenerBinder mBinder;
-    private VideoCall.Listener mVideoCallListener;
-
-    private IBinder.DeathRecipient mDeathRecipient = new IBinder.DeathRecipient() {
-        @Override
-        public void binderDied() {
-            mVideoProvider.asBinder().unlinkToDeath(this, 0);
-        }
-    };
-
-    /**
-     * IVideoCallback stub implementation.
-     */
-    private final class VideoCallListenerBinder extends IVideoCallback.Stub {
-        @Override
-        public void receiveSessionModifyRequest(VideoProfile videoProfile) {
-            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_REQUEST,
-                    videoProfile).sendToTarget();
-        }
-
-        @Override
-        public void receiveSessionModifyResponse(int status, VideoProfile requestProfile,
-                VideoProfile responseProfile) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = status;
-            args.arg2 = requestProfile;
-            args.arg3 = responseProfile;
-            mHandler.obtainMessage(MSG_RECEIVE_SESSION_MODIFY_RESPONSE, args).sendToTarget();
-        }
-
-        @Override
-        public void handleCallSessionEvent(int event) {
-            mHandler.obtainMessage(MSG_HANDLE_CALL_SESSION_EVENT, event).sendToTarget();
-        }
-
-        @Override
-        public void changePeerDimensions(int width, int height) {
-            SomeArgs args = SomeArgs.obtain();
-            args.arg1 = width;
-            args.arg2 = height;
-            mHandler.obtainMessage(MSG_CHANGE_PEER_DIMENSIONS, args).sendToTarget();
-        }
-
-        @Override
-        public void changeCallDataUsage(int dataUsage) {
-            mHandler.obtainMessage(MSG_CHANGE_CALL_DATA_USAGE, dataUsage).sendToTarget();
-        }
-
-        @Override
-        public void changeCameraCapabilities(CameraCapabilities cameraCapabilities) {
-            mHandler.obtainMessage(MSG_CHANGE_CAMERA_CAPABILITIES,
-                    cameraCapabilities).sendToTarget();
-        }
-    }
-
-    /** Default handler used to consolidate binder method calls onto a single thread. */
-    private final Handler mHandler = new Handler(Looper.getMainLooper()) {
-        @Override
-        public void handleMessage(Message msg) {
-            if (mVideoCallListener == null) {
-                return;
-            }
-
-            SomeArgs args;
-            switch (msg.what) {
-                case MSG_RECEIVE_SESSION_MODIFY_REQUEST:
-                    mVideoCallListener.onSessionModifyRequestReceived((VideoProfile) msg.obj);
-                    break;
-                case MSG_RECEIVE_SESSION_MODIFY_RESPONSE:
-                    args = (SomeArgs) msg.obj;
-                    try {
-                        int status = (int) args.arg1;
-                        VideoProfile requestProfile = (VideoProfile) args.arg2;
-                        VideoProfile responseProfile = (VideoProfile) args.arg3;
-
-                        mVideoCallListener.onSessionModifyResponseReceived(
-                                status, requestProfile, responseProfile);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                case MSG_HANDLE_CALL_SESSION_EVENT:
-                    mVideoCallListener.onCallSessionEvent((int) msg.obj);
-                    break;
-                case MSG_CHANGE_PEER_DIMENSIONS:
-                    args = (SomeArgs) msg.obj;
-                    try {
-                        int width = (int) args.arg1;
-                        int height = (int) args.arg2;
-                        mVideoCallListener.onPeerDimensionsChanged(width, height);
-                    } finally {
-                        args.recycle();
-                    }
-                    break;
-                case MSG_CHANGE_CALL_DATA_USAGE:
-                    mVideoCallListener.onCallDataUsageChanged(msg.arg1);
-                    break;
-                case MSG_CHANGE_CAMERA_CAPABILITIES:
-                    mVideoCallListener.onCameraCapabilitiesChanged(
-                            (CameraCapabilities) msg.obj);
-                    break;
-                default:
-                    break;
-            }
-        }
-    };
-
-    /** {@hide} */
-    VideoCallImpl(IVideoProvider videoProvider) throws RemoteException {
-        mVideoProvider = videoProvider;
-        mVideoProvider.asBinder().linkToDeath(mDeathRecipient, 0);
-
-        mBinder = new VideoCallListenerBinder();
-        mVideoProvider.setVideoListener(mBinder);
-    }
-
-    /** {@inheritDoc} */
-    public void setVideoCallListener(VideoCall.Listener videoCallListener) {
-        mVideoCallListener = videoCallListener;
-    }
-
-    /** {@inheritDoc} */
-    public void setCamera(String cameraId) {
-        try {
-            mVideoProvider.setCamera(cameraId);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void setPreviewSurface(Surface surface) {
-        try {
-            mVideoProvider.setPreviewSurface(surface);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void setDisplaySurface(Surface surface) {
-        try {
-            mVideoProvider.setDisplaySurface(surface);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void setDeviceOrientation(int rotation) {
-        try {
-            mVideoProvider.setDeviceOrientation(rotation);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void setZoom(float value) {
-        try {
-            mVideoProvider.setZoom(value);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void sendSessionModifyRequest(VideoProfile requestProfile) {
-        try {
-            mVideoProvider.sendSessionModifyRequest(requestProfile);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void sendSessionModifyResponse(VideoProfile responseProfile) {
-        try {
-            mVideoProvider.sendSessionModifyResponse(responseProfile);
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void requestCameraCapabilities() {
-        try {
-            mVideoProvider.requestCameraCapabilities();
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void requestCallDataUsage() {
-        try {
-            mVideoProvider.requestCallDataUsage();
-        } catch (RemoteException e) {
-        }
-    }
-
-    /** {@inheritDoc} */
-    public void setPauseImage(String uri) {
-        try {
-            mVideoProvider.setPauseImage(uri);
-        } catch (RemoteException e) {
-        }
-    }
-}
\ No newline at end of file
diff --git a/telecomm/java/android/telecomm/VideoProfile.aidl b/telecomm/java/android/telecomm/VideoProfile.aidl
deleted file mode 100644
index e756fa7..0000000
--- a/telecomm/java/android/telecomm/VideoProfile.aidl
+++ /dev/null
@@ -1,23 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-/**
- * {@hide}
- */
-parcelable VideoProfile;
diff --git a/telecomm/java/android/telecomm/VideoProfile.java b/telecomm/java/android/telecomm/VideoProfile.java
deleted file mode 100644
index b147978..0000000
--- a/telecomm/java/android/telecomm/VideoProfile.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.telecomm;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Represents attributes of video calls.
- */
-public class VideoProfile implements Parcelable {
-    /**
-     * "High" video quality.
-     */
-    public static final int QUALITY_HIGH = 1;
-
-    /**
-     * "Medium" video quality.
-     */
-    public static final int QUALITY_MEDIUM = 2;
-
-    /**
-     * "Low" video quality.
-     */
-    public static final int QUALITY_LOW = 3;
-
-    /**
-     * Use default video quality.
-     */
-    public static final int QUALITY_DEFAULT = 4;
-
-    private final int mVideoState;
-
-    private final int mQuality;
-
-    /**
-     * Creates an instance of the VideoProfile
-     *
-     * @param videoState The video state.
-     */
-    public VideoProfile(int videoState) {
-        this(videoState, QUALITY_DEFAULT);
-    }
-
-    /**
-     * Creates an instance of the VideoProfile
-     *
-     * @param videoState The video state.
-     * @param quality The video quality.
-     */
-    public VideoProfile(int videoState, int quality) {
-        mVideoState = videoState;
-        mQuality = quality;
-    }
-
-    /**
-     * The video state of the call.
-     * Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
-     * {@link VideoProfile.VideoState#BIDIRECTIONAL},
-     * {@link VideoProfile.VideoState#TX_ENABLED},
-     * {@link VideoProfile.VideoState#RX_ENABLED},
-     * {@link VideoProfile.VideoState#PAUSED}.
-     */
-    public int getVideoState() {
-        return mVideoState;
-    }
-
-    /**
-     * The desired video quality for the call.
-     * Valid values: {@link VideoProfile#QUALITY_HIGH}, {@link VideoProfile#QUALITY_MEDIUM},
-     * {@link VideoProfile#QUALITY_LOW}, {@link VideoProfile#QUALITY_DEFAULT}.
-     */
-    public int getQuality() {
-        return mQuality;
-    }
-
-    /**
-     * Responsible for creating VideoProfile objects from deserialized Parcels.
-     **/
-    public static final Parcelable.Creator<VideoProfile> CREATOR =
-            new Parcelable.Creator<VideoProfile> () {
-                /**
-                 * Creates a MediaProfile instances from a parcel.
-                 *
-                 * @param source The parcel.
-                 * @return The MediaProfile.
-                 */
-                @Override
-                public VideoProfile createFromParcel(Parcel source) {
-                    int state = source.readInt();
-                    int quality = source.readInt();
-
-                    ClassLoader classLoader = VideoProfile.class.getClassLoader();
-                    return new VideoProfile(state, quality);
-                }
-
-                @Override
-                public VideoProfile[] newArray(int size) {
-                    return new VideoProfile[size];
-                }
-            };
-
-    /**
-     * Describe the kinds of special objects contained in this Parcelable's
-     * marshalled representation.
-     *
-     * @return a bitmask indicating the set of special object types marshalled
-     * by the Parcelable.
-     */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /**
-     * Flatten this object in to a Parcel.
-     *
-     * @param dest  The Parcel in which the object should be written.
-     * @param flags Additional flags about how the object should be written.
-     *              May be 0 or {@link #PARCELABLE_WRITE_RETURN_VALUE}.
-     */
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeInt(mVideoState);
-        dest.writeInt(mQuality);
-    }
-
-    /**
-    * The video state of the call, stored as a bit-field describing whether video transmission and
-    * receipt it enabled, as well as whether the video is currently muted.
-    */
-    public static class VideoState {
-        /**
-         * Call is currently in an audio-only mode with no video transmission or receipt.
-         */
-        public static final int AUDIO_ONLY = 0x0;
-
-        /**
-         * Video transmission is enabled.
-         */
-        public static final int TX_ENABLED = 0x1;
-
-        /**
-         * Video reception is enabled.
-         */
-        public static final int RX_ENABLED = 0x2;
-
-        /**
-         * Video signal is bi-directional.
-         */
-        public static final int BIDIRECTIONAL = TX_ENABLED | RX_ENABLED;
-
-        /**
-         * Video is paused.
-         */
-        public static final int PAUSED = 0x4;
-
-        /**
-         * Whether the video state is audio only.
-         * @param videoState The video state.
-         * @return Returns true if the video state is audio only.
-         */
-        public static boolean isAudioOnly(int videoState) {
-            return !hasState(videoState, TX_ENABLED) && !hasState(videoState, RX_ENABLED);
-        }
-
-        /**
-         * Whether the video transmission is enabled.
-         * @param videoState The video state.
-         * @return Returns true if the video transmission is enabled.
-         */
-        public static boolean isTransmissionEnabled(int videoState) {
-            return hasState(videoState, TX_ENABLED);
-        }
-
-        /**
-         * Whether the video reception is enabled.
-         * @param videoState The video state.
-         * @return Returns true if the video transmission is enabled.
-         */
-        public static boolean isReceptionEnabled(int videoState) {
-            return hasState(videoState, RX_ENABLED);
-        }
-
-        /**
-         * Whether the video signal is bi-directional.
-         * @param videoState
-         * @return Returns true if the video signal is bi-directional.
-         */
-        public static boolean isBidirectional(int videoState) {
-            return hasState(videoState, BIDIRECTIONAL);
-        }
-
-        /**
-         * Whether the video is paused.
-         * @param videoState The video state.
-         * @return Returns true if the video is paused.
-         */
-        public static boolean isPaused(int videoState) {
-            return hasState(videoState, PAUSED);
-        }
-
-        /**
-         * Determines if a specified state is set in a videoState bit-mask.
-         *
-         * @param videoState The video state bit-mask.
-         * @param state The state to check.
-         * @return {@code True} if the state is set.
-         * {@hide}
-         */
-        private static boolean hasState(int videoState, int state) {
-            return (videoState & state) == state;
-        }
-    }
-}
diff --git a/telecomm/java/com/android/internal/telecom/IConnectionService.aidl b/telecomm/java/com/android/internal/telecom/IConnectionService.aidl
new file mode 100644
index 0000000..1059da37
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IConnectionService.aidl
@@ -0,0 +1,73 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.os.Bundle;
+import android.telecom.AudioState;
+import android.telecom.ConnectionRequest;
+import android.telecom.PhoneAccountHandle;
+
+import com.android.internal.telecom.IConnectionServiceAdapter;
+
+/**
+ * Internal remote interface for connection services.
+ *
+ * @see android.telecom.ConnectionService
+ *
+ * @hide
+ */
+oneway interface IConnectionService {
+    void addConnectionServiceAdapter(in IConnectionServiceAdapter adapter);
+
+    void removeConnectionServiceAdapter(in IConnectionServiceAdapter adapter);
+
+    void createConnection(
+            in PhoneAccountHandle connectionManagerPhoneAccount,
+            String callId,
+            in ConnectionRequest request,
+            boolean isIncoming);
+
+    void abort(String callId);
+
+    void answerVideo(String callId, int videoState);
+
+    void answer(String callId);
+
+    void reject(String callId);
+
+    void disconnect(String callId);
+
+    void hold(String callId);
+
+    void unhold(String callId);
+
+    void onAudioStateChanged(String activeCallId, in AudioState audioState);
+
+    void playDtmfTone(String callId, char digit);
+
+    void stopDtmfTone(String callId);
+
+    void conference(String conferenceCallId, String callId);
+
+    void splitFromConference(String callId);
+
+    void mergeConference(String conferenceCallId);
+
+    void swapConference(String conferenceCallId);
+
+    void onPostDialContinue(String callId, boolean proceed);
+}
diff --git a/telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl b/telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl
new file mode 100644
index 0000000..5daa568
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl
@@ -0,0 +1,80 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.app.PendingIntent;
+import android.net.Uri;
+import android.telecom.ConnectionRequest;
+import android.telecom.DisconnectCause;
+import android.telecom.ParcelableConnection;
+import android.telecom.ParcelableConference;
+import android.telecom.StatusHints;
+
+import com.android.internal.telecom.IVideoProvider;
+import com.android.internal.telecom.RemoteServiceCallback;
+
+/**
+ * Internal remote callback interface for connection services.
+ *
+ * @see android.telecom.ConnectionServiceAdapter
+ *
+ * {@hide}
+ */
+oneway interface IConnectionServiceAdapter {
+    void handleCreateConnectionComplete(
+            String callId,
+            in ConnectionRequest request,
+            in ParcelableConnection connection);
+
+    void setActive(String callId);
+
+    void setRinging(String callId);
+
+    void setDialing(String callId);
+
+    void setDisconnected(String callId, in DisconnectCause disconnectCause);
+
+    void setOnHold(String callId);
+
+    void setRingbackRequested(String callId, boolean ringing);
+
+    void setCallCapabilities(String callId, int callCapabilities);
+
+    void setIsConferenced(String callId, String conferenceCallId);
+
+    void addConferenceCall(String callId, in ParcelableConference conference);
+
+    void removeCall(String callId);
+
+    void onPostDialWait(String callId, String remaining);
+
+    void queryRemoteConnectionServices(RemoteServiceCallback callback);
+
+    void setVideoProvider(String callId, IVideoProvider videoProvider);
+
+    void setVideoState(String callId, int videoState);
+
+    void setIsVoipAudioMode(String callId, boolean isVoip);
+
+    void setStatusHints(String callId, in StatusHints statusHints);
+
+    void setAddress(String callId, in Uri address, int presentation);
+
+    void setCallerDisplayName(String callId, String callerDisplayName, int presentation);
+
+    void setConferenceableConnections(String callId, in List<String> conferenceableCallIds);
+}
diff --git a/telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl b/telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl
new file mode 100644
index 0000000..138a877
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl
@@ -0,0 +1,62 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.telecom.PhoneAccountHandle;
+
+/**
+ * Internal remote callback interface for in-call services.
+ *
+ * @see android.telecom.InCallAdapter
+ *
+ * {@hide}
+ */
+oneway interface IInCallAdapter {
+    void answerCall(String callId, int videoState);
+
+    void rejectCall(String callId, boolean rejectWithMessage, String textMessage);
+
+    void disconnectCall(String callId);
+
+    void holdCall(String callId);
+
+    void unholdCall(String callId);
+
+    void mute(boolean shouldMute);
+
+    void setAudioRoute(int route);
+
+    void playDtmfTone(String callId, char digit);
+
+    void stopDtmfTone(String callId);
+
+    void postDialContinue(String callId, boolean proceed);
+
+    void phoneAccountSelected(String callId, in PhoneAccountHandle accountHandle);
+
+    void conference(String callId, String otherCallId);
+
+    void splitFromConference(String callId);
+
+    void mergeConference(String callId);
+
+    void swapConference(String callId);
+
+    void turnOnProximitySensor();
+
+    void turnOffProximitySensor(boolean screenOnImmediately);
+}
diff --git a/telecomm/java/com/android/internal/telecom/IInCallService.aidl b/telecomm/java/com/android/internal/telecom/IInCallService.aidl
new file mode 100644
index 0000000..35f6f65
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IInCallService.aidl
@@ -0,0 +1,46 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.app.PendingIntent;
+import android.telecom.AudioState;
+import android.telecom.ParcelableCall;
+
+import com.android.internal.telecom.IInCallAdapter;
+
+/**
+ * Internal remote interface for in-call services.
+ *
+ * @see android.telecom.InCallService
+ *
+ * {@hide}
+ */
+oneway interface IInCallService {
+    void setInCallAdapter(in IInCallAdapter inCallAdapter);
+
+    void addCall(in ParcelableCall call);
+
+    void updateCall(in ParcelableCall call);
+
+    void setPostDial(String callId, String remaining);
+
+    void setPostDialWait(String callId, String remaining);
+
+    void onAudioStateChanged(in AudioState audioState);
+
+    void bringToForeground(boolean showDialpad);
+}
diff --git a/telecomm/java/com/android/internal/telecom/ITelecomService.aidl b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl
new file mode 100644
index 0000000..feb09d5
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl
@@ -0,0 +1,180 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.content.ComponentName;
+import android.telecom.PhoneAccountHandle;
+import android.os.Bundle;
+import android.telecom.PhoneAccount;
+
+/**
+ * Interface used to interact with Telecom. Mostly this is used by TelephonyManager for passing
+ * commands that were previously handled by ITelephony.
+ * {@hide}
+ */
+interface ITelecomService {
+    /**
+     * Brings the in-call screen to the foreground if there is an active call.
+     *
+     * @param showDialpad if true, make the dialpad visible initially.
+     */
+    void showInCallScreen(boolean showDialpad);
+
+    /**
+     * @see TelecomServiceImpl#getDefaultOutgoingPhoneAccount
+     */
+    PhoneAccountHandle getDefaultOutgoingPhoneAccount(in String uriScheme);
+
+    /**
+     * @see TelecomServiceImpl#getUserSelectedOutgoingPhoneAccount
+     */
+    PhoneAccountHandle getUserSelectedOutgoingPhoneAccount();
+
+    /**
+     * @see TelecomServiceImpl#setUserSelectedOutgoingPhoneAccount
+     */
+    void setUserSelectedOutgoingPhoneAccount(in PhoneAccountHandle account);
+
+    /**
+     * @see TelecomServiceImpl#getCallCapablePhoneAccounts
+     */
+    List<PhoneAccountHandle> getCallCapablePhoneAccounts();
+
+    /**
+     * @see TelecomManager#getPhoneAccountsSupportingScheme
+     */
+    List<PhoneAccountHandle> getPhoneAccountsSupportingScheme(in String uriScheme);
+
+    /**
+     * @see TelecomManager#getPhoneAccountsForPackage
+     */
+    List<PhoneAccountHandle> getPhoneAccountsForPackage(in String packageName);
+
+    /**
+     * @see TelecomManager#getPhoneAccount
+     */
+    PhoneAccount getPhoneAccount(in PhoneAccountHandle account);
+
+    /**
+     * @see TelecomManager#getAllPhoneAccountsCount
+     */
+    int getAllPhoneAccountsCount();
+
+    /**
+     * @see TelecomManager#getAllPhoneAccounts
+     */
+    List<PhoneAccount> getAllPhoneAccounts();
+
+    /**
+     * @see TelecomManager#getAllPhoneAccountHandles
+     */
+    List<PhoneAccountHandle> getAllPhoneAccountHandles();
+
+    /**
+     * @see TelecomServiceImpl#getSimCallManager
+     */
+    PhoneAccountHandle getSimCallManager();
+
+    /**
+     * @see TelecomServiceImpl#setSimCallManager
+     */
+    void setSimCallManager(in PhoneAccountHandle account);
+
+    /**
+     * @see TelecomServiceImpl#getSimCallManagers
+     */
+    List<PhoneAccountHandle> getSimCallManagers();
+
+    /**
+     * @see TelecomServiceImpl#registerPhoneAccount
+     */
+    void registerPhoneAccount(in PhoneAccount metadata);
+
+    /**
+     * @see TelecomServiceImpl#unregisterPhoneAccount
+     */
+    void unregisterPhoneAccount(in PhoneAccountHandle account);
+
+    /**
+     * @see TelecomServiceImpl#clearAccounts
+     */
+    void clearAccounts(String packageName);
+
+    /**
+     * @see TelecomServiceImpl#getDefaultPhoneApp
+     */
+    ComponentName getDefaultPhoneApp();
+
+    //
+    // Internal system apis relating to call management.
+    //
+
+    /**
+     * @see TelecomServiceImpl#silenceRinger
+     */
+    void silenceRinger();
+
+    /**
+     * @see TelecomServiceImpl#isInCall
+     */
+    boolean isInCall();
+
+    /**
+     * @see TelecomServiceImpl#isRinging
+     */
+    boolean isRinging();
+
+    /**
+     * @see TelecomServiceImpl#getCallState
+     */
+    int getCallState();
+
+    /**
+     * @see TelecomServiceImpl#endCall
+     */
+    boolean endCall();
+
+    /**
+     * @see TelecomServiceImpl#acceptRingingCall
+     */
+    void acceptRingingCall();
+
+    /**
+     * @see TelecomServiceImpl#cancelMissedCallsNotification
+     */
+    void cancelMissedCallsNotification();
+
+    /**
+     * @see TelecomServiceImpl#handleMmi
+     */
+    boolean handlePinMmi(String dialString);
+
+    /**
+     * @see TelecomServiceImpl#isTtySupported
+     */
+    boolean isTtySupported();
+
+    /**
+     * @see TelecomServiceImpl#getCurrentTtyMode
+     */
+    int getCurrentTtyMode();
+
+    /**
+     * @see TelecomServiceImpl#addNewIncomingCall
+     */
+    void addNewIncomingCall(in PhoneAccountHandle phoneAccount, in Bundle extras);
+}
diff --git a/telecomm/java/com/android/internal/telecom/IVideoCallback.aidl b/telecomm/java/com/android/internal/telecom/IVideoCallback.aidl
new file mode 100644
index 0000000..f758b60
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IVideoCallback.aidl
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.telecom.CameraCapabilities;
+import android.telecom.VideoProfile;
+
+ /**
+  * Internal definition of a callback interface, used for an InCallUi to respond to video
+  * telephony changes.
+  *
+  * @see android.telecom.InCallService.VideoCall.Listener
+  *
+  * {@hide}
+  */
+oneway interface IVideoCallback {
+    void receiveSessionModifyRequest(in VideoProfile videoProfile);
+
+    void receiveSessionModifyResponse(
+            int status,
+            in VideoProfile requestedProfile,
+            in VideoProfile responseProfile);
+
+    void handleCallSessionEvent(int event);
+
+    void changePeerDimensions(int width, int height);
+
+    void changeCallDataUsage(int dataUsage);
+
+    void changeCameraCapabilities(in CameraCapabilities cameraCapabilities);
+}
diff --git a/telecomm/java/com/android/internal/telecom/IVideoProvider.aidl b/telecomm/java/com/android/internal/telecom/IVideoProvider.aidl
new file mode 100644
index 0000000..e96d9d3
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/IVideoProvider.aidl
@@ -0,0 +1,49 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.view.Surface;
+import android.telecom.VideoProfile;
+
+/**
+ * Internal remote interface for a video call provider.
+ * @see android.telecom.VideoProvider
+ * @hide
+ */
+oneway interface IVideoProvider {
+    void setVideoCallback(IBinder videoCallbackBinder);
+
+    void setCamera(String cameraId);
+
+    void setPreviewSurface(in Surface surface);
+
+    void setDisplaySurface(in Surface surface);
+
+    void setDeviceOrientation(int rotation);
+
+    void setZoom(float value);
+
+    void sendSessionModifyRequest(in VideoProfile reqProfile);
+
+    void sendSessionModifyResponse(in VideoProfile responseProfile);
+
+    void requestCameraCapabilities();
+
+    void requestCallDataUsage();
+
+    void setPauseImage(String uri);
+}
diff --git a/telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl b/telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl
new file mode 100644
index 0000000..441704d
--- /dev/null
+++ b/telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl
@@ -0,0 +1,29 @@
+/*
+ * Copyright (C) 2014 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.internal.telecom;
+
+import android.content.ComponentName;
+
+/**
+ * Simple response callback object.
+ *
+ * {@hide}
+ */
+oneway interface RemoteServiceCallback {
+    void onError();
+    void onResult(in List<ComponentName> components, in List<IBinder> callServices);
+}
diff --git a/telecomm/java/com/android/internal/telecomm/IConnectionService.aidl b/telecomm/java/com/android/internal/telecomm/IConnectionService.aidl
deleted file mode 100644
index c412424..0000000
--- a/telecomm/java/com/android/internal/telecomm/IConnectionService.aidl
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.os.Bundle;
-import android.telecomm.AudioState;
-import android.telecomm.ConnectionRequest;
-import android.telecomm.PhoneAccountHandle;
-
-import com.android.internal.telecomm.IConnectionServiceAdapter;
-
-/**
- * Internal remote interface for connection services.
- *
- * @see android.telecomm.ConnectionService
- *
- * @hide
- */
-oneway interface IConnectionService {
-    void addConnectionServiceAdapter(in IConnectionServiceAdapter adapter);
-
-    void removeConnectionServiceAdapter(in IConnectionServiceAdapter adapter);
-
-    void createConnection(
-            in PhoneAccountHandle connectionManagerPhoneAccount,
-            String callId,
-            in ConnectionRequest request,
-            boolean isIncoming);
-
-    void abort(String callId);
-
-    void answer(String callId, int videoState);
-
-    void reject(String callId);
-
-    void disconnect(String callId);
-
-    void hold(String callId);
-
-    void unhold(String callId);
-
-    void onAudioStateChanged(String activeCallId, in AudioState audioState);
-
-    void playDtmfTone(String callId, char digit);
-
-    void stopDtmfTone(String callId);
-
-    void conference(String conferenceCallId, String callId);
-
-    void splitFromConference(String callId);
-
-    void onPostDialContinue(String callId, boolean proceed);
-
-    void onPhoneAccountClicked(String callId);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl b/telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl
deleted file mode 100644
index fd4e931..0000000
--- a/telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl
+++ /dev/null
@@ -1,89 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.app.PendingIntent;
-import android.net.Uri;
-import android.telecomm.ConnectionRequest;
-import android.telecomm.ParcelableConnection;
-import android.telecomm.StatusHints;
-
-import com.android.internal.telecomm.IVideoProvider;
-import com.android.internal.telecomm.RemoteServiceCallback;
-
-/**
- * Internal remote callback interface for connection services.
- *
- * @see android.telecomm.ConnectionServiceAdapter
- *
- * {@hide}
- */
-oneway interface IConnectionServiceAdapter {
-    void handleCreateConnectionSuccessful(
-            String callId,
-            in ConnectionRequest request,
-            in ParcelableConnection connection);
-
-    void handleCreateConnectionFailed(
-            String callId,
-            in ConnectionRequest request,
-            int errorCode, String errorMessage);
-
-    void handleCreateConnectionCancelled(
-            String callId,
-            in ConnectionRequest request);
-
-    void setActive(String callId);
-
-    void setRinging(String callId);
-
-    void setDialing(String callId);
-
-    void setDisconnected(String callId, int disconnectCause, String disconnectMessage);
-
-    void setOnHold(String callId);
-
-    void setRequestingRingback(String callId, boolean ringing);
-
-    void setCallCapabilities(String callId, int callCapabilities);
-
-    void setIsConferenced(String callId, String conferenceCallId);
-
-    void addConferenceCall(String callId);
-
-    void removeCall(String callId);
-
-    void onPostDialWait(String callId, String remaining);
-
-    void queryRemoteConnectionServices(RemoteServiceCallback callback);
-
-    void setVideoProvider(String callId, IVideoProvider videoProvider);
-
-    void setVideoState(String callId, int videoState);
-
-    void setAudioModeIsVoip(String callId, boolean isVoip);
-
-    void setStatusHints(String callId, in StatusHints statusHints);
-
-    void setHandle(String callId, in Uri handle, int presentation);
-
-    void setCallerDisplayName(String callId, String callerDisplayName, int presentation);
-
-    void setConferenceableConnections(String callId, in List<String> conferenceableCallIds);
-
-    void startActivityFromInCall(String callId, in PendingIntent intent);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl b/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
deleted file mode 100644
index 2ce5c6b..0000000
--- a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.telecomm.PhoneAccountHandle;
-
-/**
- * Internal remote callback interface for in-call services.
- *
- * @see android.telecomm.InCallAdapter
- *
- * {@hide}
- */
-oneway interface IInCallAdapter {
-    void answerCall(String callId, int videoState);
-
-    void rejectCall(String callId, boolean rejectWithMessage, String textMessage);
-
-    void disconnectCall(String callId);
-
-    void holdCall(String callId);
-
-    void unholdCall(String callId);
-
-    void mute(boolean shouldMute);
-
-    void setAudioRoute(int route);
-
-    void playDtmfTone(String callId, char digit);
-
-    void stopDtmfTone(String callId);
-
-    void postDialContinue(String callId, boolean proceed);
-
-    void phoneAccountClicked(String callId);
-
-    void phoneAccountSelected(String callId, in PhoneAccountHandle accountHandle);
-
-    void conference(String callId, String otherCallId);
-
-    void splitFromConference(String callId);
-
-    void turnOnProximitySensor();
-
-    void turnOffProximitySensor(boolean screenOnImmediately);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl b/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
deleted file mode 100644
index 5d4992f..0000000
--- a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.app.PendingIntent;
-import android.telecomm.AudioState;
-import android.telecomm.ParcelableCall;
-
-import com.android.internal.telecomm.IInCallAdapter;
-
-/**
- * Internal remote interface for in-call services.
- *
- * @see android.telecomm.InCallService
- *
- * {@hide}
- */
-oneway interface IInCallService {
-    void setInCallAdapter(in IInCallAdapter inCallAdapter);
-
-    void addCall(in ParcelableCall call);
-
-    void updateCall(in ParcelableCall call);
-
-    void setPostDial(String callId, String remaining);
-
-    void setPostDialWait(String callId, String remaining);
-
-    void onAudioStateChanged(in AudioState audioState);
-
-    void bringToForeground(boolean showDialpad);
-
-    void startActivity(String callId, in PendingIntent intent);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/ITelecommService.aidl b/telecomm/java/com/android/internal/telecomm/ITelecommService.aidl
deleted file mode 100644
index 3c1dea6..0000000
--- a/telecomm/java/com/android/internal/telecomm/ITelecommService.aidl
+++ /dev/null
@@ -1,125 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.content.ComponentName;
-import android.telecomm.PhoneAccountHandle;
-import android.os.Bundle;
-import android.telecomm.PhoneAccount;
-
-/**
- * Interface used to interact with Telecomm. Mostly this is used by TelephonyManager for passing
- * commands that were previously handled by ITelephony.
- * {@hide}
- */
-interface ITelecommService {
-    /**
-     * Brings the in-call screen to the foreground if there is an active call.
-     *
-     * @param showDialpad if true, make the dialpad visible initially.
-     */
-    void showCallScreen(boolean showDialpad);
-
-    /**
-     * @see TelecommManager#getDefaultOutgoingPhoneAccount
-     */
-    PhoneAccountHandle getDefaultOutgoingPhoneAccount();
-
-    /**
-     * @see TelecommManager#getOutgoingPhoneAccounts
-     */
-    List<PhoneAccountHandle> getOutgoingPhoneAccounts();
-
-    /**
-     * @see TelecommManager#getPhoneAccount
-     */
-    PhoneAccount getPhoneAccount(in PhoneAccountHandle account);
-
-    /**
-     * @see TelecommManager#registerPhoneAccount
-     */
-    void registerPhoneAccount(in PhoneAccount metadata);
-
-    /**
-     * @see TelecommManager#unregisterPhoneAccount
-     */
-    void unregisterPhoneAccount(in PhoneAccountHandle account);
-
-    /**
-     * @see TelecommManager#clearAccounts
-     */
-    void clearAccounts(String packageName);
-
-    /**
-     * @see TelecommManager#getDefaultPhoneApp
-     */
-    ComponentName getDefaultPhoneApp();
-
-    //
-    // Internal system apis relating to call management.
-    //
-
-    /**
-     * @see TelecommManager#silenceRinger
-     */
-    void silenceRinger();
-
-    /**
-     * @see TelecommManager#isInAPhoneCall
-     */
-    boolean isInAPhoneCall();
-
-    /**
-     * @see TelecomManager#isRinging
-     */
-    boolean isRinging();
-
-    /**
-     * @see TelecommManager#endCall
-     */
-    boolean endCall();
-
-    /**
-     * @see TelecommManager#acceptRingingCall
-     */
-    void acceptRingingCall();
-
-    /**
-     * @see PhoneManager#cancelMissedCallsNotification
-     */
-    void cancelMissedCallsNotification();
-
-    /**
-     * @see PhoneManager#handlePinMmi
-     */
-    boolean handlePinMmi(String dialString);
-
-    /**
-     * @see TelecomManager#isTtySupported
-     */
-    boolean isTtySupported();
-
-    /**
-     * @see TelecomManager#getCurrentTtyMode
-     */
-    int getCurrentTtyMode();
-
-    /**
-     * @see TelecommManager#addNewIncomingCall
-     */
-    void addNewIncomingCall(in PhoneAccountHandle phoneAccount, in Bundle extras);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl b/telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl
deleted file mode 100644
index 186f083..0000000
--- a/telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.telecomm.CameraCapabilities;
-import android.telecomm.VideoProfile;
-
- /**
-  * Internal definition of a callback interface, used for an InCallUi to respond to video
-  * telephony changes.
-  *
-  * @see android.telecomm.InCallService.VideoCall.Listener
-  *
-  * {@hide}
-  */
-oneway interface IVideoCallback {
-    void receiveSessionModifyRequest(in VideoProfile videoProfile);
-
-    void receiveSessionModifyResponse(
-            int status,
-            in VideoProfile requestedProfile,
-            in VideoProfile responseProfile);
-
-    void handleCallSessionEvent(int event);
-
-    void changePeerDimensions(int width, int height);
-
-    void changeCallDataUsage(int dataUsage);
-
-    void changeCameraCapabilities(in CameraCapabilities cameraCapabilities);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl b/telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl
deleted file mode 100644
index 9d3ad7f..0000000
--- a/telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.view.Surface;
-import android.telecomm.VideoProfile;
-
-/**
- * Internal remote interface for a video call provider.
- * @see android.telecomm.VideoProvider
- * @hide
- */
-oneway interface IVideoProvider {
-    void setVideoListener(IBinder videoListenerBinder);
-
-    void setCamera(String cameraId);
-
-    void setPreviewSurface(in Surface surface);
-
-    void setDisplaySurface(in Surface surface);
-
-    void setDeviceOrientation(int rotation);
-
-    void setZoom(float value);
-
-    void sendSessionModifyRequest(in VideoProfile reqProfile);
-
-    void sendSessionModifyResponse(in VideoProfile responseProfile);
-
-    void requestCameraCapabilities();
-
-    void requestCallDataUsage();
-
-    void setPauseImage(String uri);
-}
diff --git a/telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl b/telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl
deleted file mode 100644
index 42c77d7..0000000
--- a/telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Copyright (C) 2014 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.internal.telecomm;
-
-import android.content.ComponentName;
-
-/**
- * Simple response callback object.
- */
-oneway interface RemoteServiceCallback {
-    void onError();
-    void onResult(in List<ComponentName> components, in List<IBinder> callServices);
-}
diff --git a/telephony/java/android/telephony/DisconnectCause.java b/telephony/java/android/telephony/DisconnectCause.java
index aa6c47c..6fe10dc 100644
--- a/telephony/java/android/telephony/DisconnectCause.java
+++ b/telephony/java/android/telephony/DisconnectCause.java
@@ -18,6 +18,7 @@
 
 /**
  * Contains disconnect call causes generated by the framework and the RIL.
+ * @hide
  */
 public class DisconnectCause {
 
@@ -155,7 +156,7 @@
     public static final int OUTGOING_FAILURE = 43;
 
     /**
-     * The outgoing call was canceled by the {@link android.telecomm.ConnectionService}.
+     * The outgoing call was canceled by the {@link android.telecom.ConnectionService}.
      */
     public static final int OUTGOING_CANCELED = 44;
 
@@ -262,7 +263,7 @@
         case OUTGOING_CANCELED:
             return "OUTGOING_CANCELED";
         default:
-            return "INVALID";
+            return "INVALID: " + cause;
         }
     }
 }
diff --git a/telephony/java/android/telephony/IccOpenLogicalChannelResponse.java b/telephony/java/android/telephony/IccOpenLogicalChannelResponse.java
index e9db030..4621f91 100644
--- a/telephony/java/android/telephony/IccOpenLogicalChannelResponse.java
+++ b/telephony/java/android/telephony/IccOpenLogicalChannelResponse.java
@@ -24,14 +24,23 @@
  * Response to the {@link TelephonyManager#iccOpenLogicalChannel} command.
  */
 public class IccOpenLogicalChannelResponse implements Parcelable {
-    // Indicates an invalid channel.
-    public static int INVALID_CHANNEL = -1;
+    /**
+     * Indicates an invalid channel.
+     */
+    public static final int INVALID_CHANNEL = -1;
 
-    // Possible status values.
-    public static int NO_ERROR = 1;
-    public static int MISSING_RESOURCE = 2;
-    public static int NO_SUCH_ELEMENT = 3;
-    public static int UNKNOWN_ERROR = 4;
+    /**
+     * Possible status values returned by open channel command.
+     *
+     * STATUS_NO_ERROR: Open channel command returned successfully.
+     * STATUS_MISSING_RESOURCE: No logical channels available.
+     * STATUS_NO_SUCH_ELEMENT: AID not found on UICC.
+     * STATUS_UNKNOWN_ERROR: Unknown error in open channel command.
+     */
+    public static final int STATUS_NO_ERROR = 1;
+    public static final int STATUS_MISSING_RESOURCE = 2;
+    public static final int STATUS_NO_SUCH_ELEMENT = 3;
+    public static final int STATUS_UNKNOWN_ERROR = 4;
 
     private final int mChannel;
     private final int mStatus;
diff --git a/telephony/java/android/telephony/PhoneNumberUtils.java b/telephony/java/android/telephony/PhoneNumberUtils.java
index b935d2a..30799f8 100644
--- a/telephony/java/android/telephony/PhoneNumberUtils.java
+++ b/telephony/java/android/telephony/PhoneNumberUtils.java
@@ -38,8 +38,8 @@
 
 import static com.android.internal.telephony.PhoneConstants.SUBSCRIPTION_KEY;
 import static com.android.internal.telephony.TelephonyProperties.PROPERTY_ICC_OPERATOR_ISO_COUNTRY;
-import static com.android.internal.telephony.TelephonyProperties.PROPERTY_IDP_STRING;
 import static com.android.internal.telephony.TelephonyProperties.PROPERTY_OPERATOR_ISO_COUNTRY;
+import static com.android.internal.telephony.TelephonyProperties.PROPERTY_OPERATOR_IDP_STRING;
 
 import java.util.Locale;
 import java.util.regex.Matcher;
@@ -164,14 +164,6 @@
             return uri.getSchemeSpecificPart();
         }
 
-        // TODO: We don't check for SecurityException here (requires
-        // CALL_PRIVILEGED permission).
-        if (scheme.equals("voicemail")) {
-            long subId = intent.getLongExtra(SUBSCRIPTION_KEY,
-                    SubscriptionManager.getDefaultVoiceSubId());
-            return TelephonyManager.getDefault().getCompleteVoiceMailNumber(subId);
-        }
-
         if (context == null) {
             return null;
         }
@@ -1825,7 +1817,7 @@
         int slotId = SubscriptionManager.getSlotId(subId);
         // retrieve the list of emergency numbers
         // check read-write ecclist property first
-        String ecclist = (slotId == 0) ? "ril.ecclist" : ("ril.ecclist" + slotId);
+        String ecclist = (slotId <= 0) ? "ril.ecclist" : ("ril.ecclist" + slotId);
 
         numbers = SystemProperties.get(ecclist);
 
@@ -2223,81 +2215,79 @@
     cdmaCheckAndProcessPlusCodeByNumberFormat(String dialStr,int currFormat,int defaultFormat) {
         String retStr = dialStr;
 
+        boolean useNanp = (currFormat == defaultFormat) && (currFormat == FORMAT_NANP);
+
         // Checks if the plus sign character is in the passed-in dial string
         if (dialStr != null &&
             dialStr.lastIndexOf(PLUS_SIGN_STRING) != -1) {
-            // Format the string based on the rules for the country the number is from,
-            // and the current country the phone is camped on.
-            if ((currFormat == defaultFormat) && (currFormat == FORMAT_NANP)) {
-                // Handle case where default and current telephone numbering plans are NANP.
-                String postDialStr = null;
-                String tempDialStr = dialStr;
 
-                // Sets the retStr to null since the conversion will be performed below.
-                retStr = null;
-                if (DBG) log("checkAndProcessPlusCode,dialStr=" + dialStr);
-                // This routine is to process the plus sign in the dial string by loop through
-                // the network portion, post dial portion 1, post dial portion 2... etc. if
-                // applied
-                do {
-                    String networkDialStr;
+            // Handle case where default and current telephone numbering plans are NANP.
+            String postDialStr = null;
+            String tempDialStr = dialStr;
+
+            // Sets the retStr to null since the conversion will be performed below.
+            retStr = null;
+            if (DBG) log("checkAndProcessPlusCode,dialStr=" + dialStr);
+            // This routine is to process the plus sign in the dial string by loop through
+            // the network portion, post dial portion 1, post dial portion 2... etc. if
+            // applied
+            do {
+                String networkDialStr;
+                // Format the string based on the rules for the country the number is from,
+                // and the current country the phone is camped
+                if (useNanp) {
                     networkDialStr = extractNetworkPortion(tempDialStr);
-                    // Handles the conversion within NANP
-                    networkDialStr = processPlusCodeWithinNanp(networkDialStr);
+                } else  {
+                    networkDialStr = extractNetworkPortionAlt(tempDialStr);
 
-                    // Concatenates the string that is converted from network portion
-                    if (!TextUtils.isEmpty(networkDialStr)) {
-                        if (retStr == null) {
-                            retStr = networkDialStr;
-                        } else {
-                            retStr = retStr.concat(networkDialStr);
-                        }
+                }
+
+                networkDialStr = processPlusCode(networkDialStr, useNanp);
+
+                // Concatenates the string that is converted from network portion
+                if (!TextUtils.isEmpty(networkDialStr)) {
+                    if (retStr == null) {
+                        retStr = networkDialStr;
                     } else {
-                        // This should never happen since we checked the if dialStr is null
-                        // and if it contains the plus sign in the beginning of this function.
-                        // The plus sign is part of the network portion.
-                        Rlog.e("checkAndProcessPlusCode: null newDialStr", networkDialStr);
-                        return dialStr;
+                        retStr = retStr.concat(networkDialStr);
                     }
-                    postDialStr = extractPostDialPortion(tempDialStr);
-                    if (!TextUtils.isEmpty(postDialStr)) {
-                        int dialableIndex = findDialableIndexFromPostDialStr(postDialStr);
+                } else {
+                    // This should never happen since we checked the if dialStr is null
+                    // and if it contains the plus sign in the beginning of this function.
+                    // The plus sign is part of the network portion.
+                    Rlog.e("checkAndProcessPlusCode: null newDialStr", networkDialStr);
+                    return dialStr;
+                }
+                postDialStr = extractPostDialPortion(tempDialStr);
+                if (!TextUtils.isEmpty(postDialStr)) {
+                    int dialableIndex = findDialableIndexFromPostDialStr(postDialStr);
 
-                        // dialableIndex should always be greater than 0
-                        if (dialableIndex >= 1) {
-                            retStr = appendPwCharBackToOrigDialStr(dialableIndex,
-                                     retStr,postDialStr);
-                            // Skips the P/W character, extracts the dialable portion
-                            tempDialStr = postDialStr.substring(dialableIndex);
-                        } else {
-                            // Non-dialable character such as P/W should not be at the end of
-                            // the dial string after P/W processing in CdmaConnection.java
-                            // Set the postDialStr to "" to break out of the loop
-                            if (dialableIndex < 0) {
-                                postDialStr = "";
-                            }
-                            Rlog.e("wrong postDialStr=", postDialStr);
+                    // dialableIndex should always be greater than 0
+                    if (dialableIndex >= 1) {
+                        retStr = appendPwCharBackToOrigDialStr(dialableIndex,
+                                 retStr,postDialStr);
+                        // Skips the P/W character, extracts the dialable portion
+                        tempDialStr = postDialStr.substring(dialableIndex);
+                    } else {
+                        // Non-dialable character such as P/W should not be at the end of
+                        // the dial string after P/W processing in CdmaConnection.java
+                        // Set the postDialStr to "" to break out of the loop
+                        if (dialableIndex < 0) {
+                            postDialStr = "";
                         }
+                        Rlog.e("wrong postDialStr=", postDialStr);
                     }
-                    if (DBG) log("checkAndProcessPlusCode,postDialStr=" + postDialStr);
-                } while (!TextUtils.isEmpty(postDialStr) && !TextUtils.isEmpty(tempDialStr));
-            } else {
-                // TODO: Support NANP international conversion and other telephone numbering plans.
-                // Currently the phone is never used in non-NANP system, so return the original
-                // dial string.
-                Rlog.e("checkAndProcessPlusCode:non-NANP not supported", dialStr);
-            }
+                }
+                if (DBG) log("checkAndProcessPlusCode,postDialStr=" + postDialStr);
+            } while (!TextUtils.isEmpty(postDialStr) && !TextUtils.isEmpty(tempDialStr));
         }
         return retStr;
-     }
+    }
 
-    // This function gets the default international dialing prefix
-    private static String getDefaultIdp( ) {
-        String ps = null;
-        SystemProperties.get(PROPERTY_IDP_STRING, ps);
-        if (TextUtils.isEmpty(ps)) {
-            ps = NANP_IDP_STRING;
-        }
+    private static String getCurrentIdp(boolean useNanp) {
+        // in case, there is no IDD is found, we shouldn't convert it.
+        String ps = SystemProperties.get(
+                PROPERTY_OPERATOR_IDP_STRING, useNanp ? NANP_IDP_STRING : PLUS_SIGN_STRING);
         return ps;
     }
 
@@ -2326,8 +2316,9 @@
     /**
      * This function checks if the passed in string conforms to the NANP format
      * i.e. NXX-NXX-XXXX, N is any digit 2-9 and X is any digit 0-9
+     * @hide
      */
-    private static boolean isNanp (String dialStr) {
+    public static boolean isNanp (String dialStr) {
         boolean retVal = false;
         if (dialStr != null) {
             if (dialStr.length() == NANP_LENGTH) {
@@ -2407,31 +2398,32 @@
     }
 
     /**
-     * This function handles the plus code conversion within NANP CDMA network
+     * This function handles the plus code conversion
      * If the number format is
      * 1)+1NANP,remove +,
      * 2)other than +1NANP, any + numbers,replace + with the current IDP
      */
-    private static String processPlusCodeWithinNanp(String networkDialStr) {
+    private static String processPlusCode(String networkDialStr, boolean useNanp) {
         String retStr = networkDialStr;
 
-        if (DBG) log("processPlusCodeWithinNanp,networkDialStr=" + networkDialStr);
+        if (DBG) log("processPlusCode, networkDialStr = " + networkDialStr
+                + "for NANP = " + useNanp);
         // If there is a plus sign at the beginning of the dial string,
         // Convert the plus sign to the default IDP since it's an international number
         if (networkDialStr != null &&
             networkDialStr.charAt(0) == PLUS_SIGN_CHAR &&
             networkDialStr.length() > 1) {
             String newStr = networkDialStr.substring(1);
-            if (isOneNanp(newStr)) {
+            // TODO: for nonNanp, should the '+' be removed if following number is country code
+            if (useNanp && isOneNanp(newStr)) {
                 // Remove the leading plus sign
                 retStr = newStr;
-             } else {
-                 String idpStr = getDefaultIdp();
-                 // Replaces the plus sign with the default IDP
-                 retStr = networkDialStr.replaceFirst("[+]", idpStr);
+            } else {
+                // Replaces the plus sign with the default IDP
+                retStr = networkDialStr.replaceFirst("[+]", getCurrentIdp(useNanp));
             }
         }
-        if (DBG) log("processPlusCodeWithinNanp,retStr=" + retStr);
+        if (DBG) log("processPlusCode, retStr=" + retStr);
         return retStr;
     }
 
diff --git a/telephony/java/android/telephony/PhoneStateListener.java b/telephony/java/android/telephony/PhoneStateListener.java
index 350c27e..34da1c9 100644
--- a/telephony/java/android/telephony/PhoneStateListener.java
+++ b/telephony/java/android/telephony/PhoneStateListener.java
@@ -221,18 +221,39 @@
 
     private final Handler mHandler;
 
+    /**
+     * Create a PhoneStateListener for the Phone with the default subscription.
+     * This class requires Looper.myLooper() not return null. To supply your
+     * own non-null looper use PhoneStateListener(Looper looper) below.
+     */
     public PhoneStateListener() {
         this(SubscriptionManager.DEFAULT_SUB_ID, Looper.myLooper());
     }
 
     /**
+     * Create a PhoneStateListener for the Phone with the default subscription
+     * using a particular non-null Looper.
+     * @hide
+     */
+    public PhoneStateListener(Looper looper) {
+        this(SubscriptionManager.DEFAULT_SUB_ID, looper);
+    }
+
+    /**
+     * Create a PhoneStateListener for the Phone using the specified subscription.
+     * This class requires Looper.myLooper() not return null. To supply your
+     * own non-null Looper use PhoneStateListener(long subId, Looper looper) below.
      * @hide
      */
     public PhoneStateListener(long subId) {
         this(subId, Looper.myLooper());
     }
 
-    /** @hide */
+    /**
+     * Create a PhoneStateListener for the Phone using the specified subscription
+     * and non-null Looper.
+     * @hide
+     */
     public PhoneStateListener(long subId, Looper looper) {
         if (DBG) log("ctor: subId=" + subId + " looper=" + looper);
         mSubId = subId;
diff --git a/telephony/java/android/telephony/SubInfoRecord.java b/telephony/java/android/telephony/SubInfoRecord.java
index ced8e2f..805f787 100644
--- a/telephony/java/android/telephony/SubInfoRecord.java
+++ b/telephony/java/android/telephony/SubInfoRecord.java
@@ -1,18 +1,18 @@
 /*
-* Copyright (C) 2011-2014 MediaTek Inc.
-*
-* 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.
-*/
+ * Copyright (C) 2014 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 android.telephony;
 
@@ -20,96 +20,148 @@
 import android.os.Parcelable;
 
 /**
- *  A parcelable holder class of byte[] for ISms aidl implementation
- *  @hide
+ * A Parcelable class for Subscription Information.
+ * @hide - to be unhidden
  */
-
 public class SubInfoRecord implements Parcelable {
 
-    public long mSubId;
-    public String mIccId;
-    public int mSlotId;
-    public String mDisplayName;
-    public int mNameSource;
-    public int mColor;
-    public String mNumber;
-    public int mDispalyNumberFormat;
-    public int mDataRoaming;
-    public int[] mSimIconRes;
+    /**
+     * Subscription Identifier, this is a device unique number
+     * and not an index into an array
+     */
+    public long subId;
+    /** The GID for a SIM that maybe associated with this subscription, empty if unknown */
+    public String iccId;
+    /**
+     * The slot identifier for that currently contains the subscription
+     * and not necessarily unique and maybe INVALID_SLOT_ID if unknown
+     */
+    public int slotId;
+    /**
+     * The string displayed to the user that identifies this subscription
+     */
+    public String displayName;
+    /**
+     * The source of the name, NAME_SOURCE_UNDEFINED, NAME_SOURCE_DEFAULT_SOURCE,
+     * NAME_SOURCE_SIM_SOURCE or NAME_SOURCE_USER_INPUT.
+     */
+    public int nameSource;
+    /**
+     * The color to be used for when displaying to the user
+     */
+    public int color;
+    /**
+     * A number presented to the user identify this subscription
+     */
+    public String number;
+    /**
+     * How to display the phone number, DISPLAY_NUMBER_NONE, DISPLAY_NUMBER_FIRST,
+     * DISPLAY_NUMBER_LAST
+     */
+    public int displayNumberFormat;
+    /**
+     * Data roaming state, DATA_RAOMING_ENABLE, DATA_RAOMING_DISABLE
+     */
+    public int dataRoaming;
+    /**
+     * SIM Icon resource identifiers. FIXME: Check with MTK what it really is
+     */
+    public int[] simIconRes;
+    /**
+     * Mobile Country Code
+     */
+    public int mcc;
+    /**
+     * Mobile Network Code
+     */
+    public int mnc;
 
     public SubInfoRecord() {
-        this.mSubId = -1;
-        this.mIccId = "";
-        this.mSlotId = -1;
-        this.mDisplayName = "";
-        this.mNameSource = 0;
-        this.mColor = 0;
-        this.mNumber = "";
-        this.mDispalyNumberFormat = 0;
-        this.mDataRoaming = 0;
-        this.mSimIconRes = new int[2];
+        this.subId = SubscriptionManager.INVALID_SUB_ID;
+        this.iccId = "";
+        this.slotId = SubscriptionManager.INVALID_SLOT_ID;
+        this.displayName = "";
+        this.nameSource = 0;
+        this.color = 0;
+        this.number = "";
+        this.displayNumberFormat = 0;
+        this.dataRoaming = 0;
+        this.simIconRes = new int[2];
+        this.mcc = 0;
+        this.mnc = 0;
     }
 
-
-    public SubInfoRecord(long subId, String iccId, int slotId, String displayname, int nameSource,
-            int mColor, String mNumber, int displayFormat, int roaming, int[] iconRes) {
-        this.mSubId = subId;
-        this.mIccId = iccId;
-        this.mSlotId = slotId;
-        this.mDisplayName = displayname;
-        this.mNameSource = nameSource;
-        this.mColor = mColor;
-        this.mNumber = mNumber;
-        this.mDispalyNumberFormat = displayFormat;
-        this.mDataRoaming = roaming;
-        this.mSimIconRes = iconRes;
+    public SubInfoRecord(long subId, String iccId, int slotId, String displayName, int nameSource,
+            int color, String number, int displayFormat, int roaming, int[] iconRes,
+            int mcc, int mnc) {
+        this.subId = subId;
+        this.iccId = iccId;
+        this.slotId = slotId;
+        this.displayName = displayName;
+        this.nameSource = nameSource;
+        this.color = color;
+        this.number = number;
+        this.displayNumberFormat = displayFormat;
+        this.dataRoaming = roaming;
+        this.simIconRes = iconRes;
+        this.mcc = mcc;
+        this.mnc = mnc;
     }
 
     public static final Parcelable.Creator<SubInfoRecord> CREATOR = new Parcelable.Creator<SubInfoRecord>() {
+        @Override
         public SubInfoRecord createFromParcel(Parcel source) {
-            long mSubId = source.readLong();
-            String mIccId = source.readString();
-            int mSlotId = source.readInt();
-            String mDisplayName = source.readString();
-            int mNameSource = source.readInt();
-            int mColor = source.readInt();
-            String mNumber = source.readString();
-            int mDispalyNumberFormat = source.readInt();
-            int mDataRoaming = source.readInt();
+            long subId = source.readLong();
+            String iccId = source.readString();
+            int slotId = source.readInt();
+            String displayName = source.readString();
+            int nameSource = source.readInt();
+            int color = source.readInt();
+            String number = source.readString();
+            int displayNumberFormat = source.readInt();
+            int dataRoaming = source.readInt();
             int[] iconRes = new int[2];
             source.readIntArray(iconRes);
+            int mcc = source.readInt();
+            int mnc = source.readInt();
 
-            return new SubInfoRecord(mSubId, mIccId, mSlotId, mDisplayName, mNameSource, mColor, mNumber,
-                mDispalyNumberFormat, mDataRoaming, iconRes);
+            return new SubInfoRecord(subId, iccId, slotId, displayName, nameSource, color, number,
+                displayNumberFormat, dataRoaming, iconRes, mcc, mnc);
         }
 
+        @Override
         public SubInfoRecord[] newArray(int size) {
             return new SubInfoRecord[size];
         }
     };
 
+    @Override
     public void writeToParcel(Parcel dest, int flags) {
-        dest.writeLong(mSubId);
-        dest.writeString(mIccId);
-        dest.writeInt(mSlotId);
-        dest.writeString(mDisplayName);
-        dest.writeInt(mNameSource);
-        dest.writeInt(mColor);
-        dest.writeString(mNumber);
-        dest.writeInt(mDispalyNumberFormat);
-        dest.writeInt(mDataRoaming);
-        dest.writeIntArray(mSimIconRes);
+        dest.writeLong(subId);
+        dest.writeString(iccId);
+        dest.writeInt(slotId);
+        dest.writeString(displayName);
+        dest.writeInt(nameSource);
+        dest.writeInt(color);
+        dest.writeString(number);
+        dest.writeInt(displayNumberFormat);
+        dest.writeInt(dataRoaming);
+        dest.writeIntArray(simIconRes);
+        dest.writeInt(mcc);
+        dest.writeInt(mnc);
     }
 
+    @Override
     public int describeContents() {
         return 0;
     }
 
+    @Override
     public String toString() {
-        return "{mSubId=" + mSubId + ", mIccId=" + mIccId + " mSlotId=" + mSlotId
-                + " mDisplayName=" + mDisplayName + " mNameSource=" + mNameSource
-                + " mColor=" + mColor + " mNumber=" + mNumber
-                + " mDispalyNumberFormat=" + mDispalyNumberFormat + " mDataRoaming=" + mDataRoaming
-                + " mSimIconRes=" + mSimIconRes + "}";
+        return "{mSubId=" + subId + ", mIccId=" + iccId + " mSlotId=" + slotId
+                + " mDisplayName=" + displayName + " mNameSource=" + nameSource
+                + " mColor=" + color + " mNumber=" + number
+                + " mDisplayNumberFormat=" + displayNumberFormat + " mDataRoaming=" + dataRoaming
+                + " mSimIconRes=" + simIconRes + " mMcc " + mcc + " mMnc " + mnc + "}";
     }
 }
diff --git a/telephony/java/android/telephony/SubscriptionManager.java b/telephony/java/android/telephony/SubscriptionManager.java
index 79e9fd5..fe68263 100644
--- a/telephony/java/android/telephony/SubscriptionManager.java
+++ b/telephony/java/android/telephony/SubscriptionManager.java
@@ -1,31 +1,24 @@
 /*
-* Copyright (C) 2011-2014 MediaTek Inc.
-*
-* 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.
-*/
+ * Copyright (C) 2014 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 android.telephony;
 
-import static android.Manifest.permission.READ_PHONE_STATE;
-
-import android.app.ActivityManagerNative;
-import android.content.ContentResolver;
-import android.content.ContentUris;
-import android.content.ContentValues;
-import android.content.Context;
+import android.annotation.SdkConstant;
+import android.annotation.SdkConstant.SdkConstantType;
 import android.content.Intent;
-import android.database.Cursor;
-import android.os.UserHandle;
 import android.net.Uri;
 import android.provider.BaseColumns;
 import android.telephony.Rlog;
@@ -34,149 +27,247 @@
 
 import com.android.internal.telephony.ISub;
 import com.android.internal.telephony.PhoneConstants;
-import com.android.internal.telephony.TelephonyIntents;
 
 import java.util.ArrayList;
 import java.util.List;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map.Entry;
 
 /**
- *@hide
+ * SubscriptionManager is the application interface to SubscriptionController
+ * and provides information about the current Telephony Subscriptions.
+ *
+ * The android.Manifest.permission.READ_PHONE_STATE to retrieve the information, except
+ * getActiveSubIdList and getActiveSubIdCount for which no permission is needed.
+ *
+ * @hide - to be unhidden
  */
 public class SubscriptionManager implements BaseColumns {
     private static final String LOG_TAG = "SUB";
     private static final boolean DBG = true;
     private static final boolean VDBG = false;
 
-    // An invalid subscription identifier
-    public static final long INVALID_SUB_ID = Long.MAX_VALUE;
+    /** An invalid phone identifier */
+    /** @hide - to be unhidden */
+    public static final int INVALID_PHONE_ID = -1000;
 
-    // The default subscription identifier
-    public static final long DEFAULT_SUB_ID = Long.MAX_VALUE - 1;
+    /** Indicates the caller wants the default phone id. */
+    /** @hide - to be unhidden */
+    public static final int DEFAULT_PHONE_ID = Integer.MAX_VALUE;
 
+    /** An invalid slot identifier */
+    /** @hide - to be unhidden */
+    public static final int INVALID_SLOT_ID = -1000;
+
+    /** Indicates the caller wants the default slot id. */
+    /** @hide */
+    public static final int DEFAULT_SLOT_ID = Integer.MAX_VALUE;
+
+    /** Indicates the user should be asked which sub to use. */
+    /** @hide */
+    public static final long ASK_USER_SUB_ID = -1001;
+
+    /** An invalid subscription identifier */
+    public static final long INVALID_SUB_ID = -1000;
+
+    /** Indicates the caller wants the default sub id. */
+    /** @hide - to be unhidden */
+    public static final long DEFAULT_SUB_ID = Long.MAX_VALUE;
+
+    /** @hide */
     public static final Uri CONTENT_URI = Uri.parse("content://telephony/siminfo");
 
+    /** @hide */
     public static final int DEFAULT_INT_VALUE = -100;
 
+    /** @hide */
     public static final String DEFAULT_STRING_VALUE = "N/A";
 
+    /** @hide */
     public static final int EXTRA_VALUE_NEW_SIM = 1;
+
+    /** @hide */
     public static final int EXTRA_VALUE_REMOVE_SIM = 2;
+    /** @hide */
     public static final int EXTRA_VALUE_REPOSITION_SIM = 3;
+    /** @hide */
     public static final int EXTRA_VALUE_NOCHANGE = 4;
 
+    /** @hide */
     public static final String INTENT_KEY_DETECT_STATUS = "simDetectStatus";
+    /** @hide */
     public static final String INTENT_KEY_SIM_COUNT = "simCount";
+    /** @hide */
     public static final String INTENT_KEY_NEW_SIM_SLOT = "newSIMSlot";
+    /** @hide */
     public static final String INTENT_KEY_NEW_SIM_STATUS = "newSIMStatus";
 
     /**
      * The ICC ID of a SIM.
      * <P>Type: TEXT (String)</P>
      */
+    /** @hide */
     public static final String ICC_ID = "icc_id";
 
     /**
      * <P>Type: INTEGER (int)</P>
      */
+    /** @hide */
     public static final String SIM_ID = "sim_id";
 
+    /** SIM is not inserted */
+    /** @hide - to be unhidden */
     public static final int SIM_NOT_INSERTED = -1;
 
     /**
-     * The display name of a SIM.
+     * TelephonyProvider column name for user displayed name.
      * <P>Type: TEXT (String)</P>
      */
+    /** @hide */
     public static final String DISPLAY_NAME = "display_name";
 
+    /**
+     * Default name resource
+     * @hide
+     */
     public static final int DEFAULT_NAME_RES = com.android.internal.R.string.unknownName;
 
     /**
-     * The display name source of a SIM.
-     * <P>Type: INT (int)</P>
+     * TelephonyProvider column name for source of the user displayed name.
+     * <P>Type: INT (int)</P> with one of the NAME_SOURCE_XXXX values below
+     *
+     * @hide
      */
     public static final String NAME_SOURCE = "name_source";
 
-    public static final int DEFAULT_SOURCE = 0;
-
-    public static final int SIM_SOURCE = 1;
-
-    public static final int USER_INPUT = 2;
+    /**
+     * The name_source is undefined
+     * @hide
+     */
+    public static final int NAME_SOURCE_UNDEFINDED = -1;
 
     /**
-     * The color of a SIM.
+     * The name_source is the default
+     * @hide
+     */
+    public static final int NAME_SOURCE_DEFAULT_SOURCE = 0;
+
+    /**
+     * The name_source is from the SIM
+     * @hide
+     */
+    public static final int NAME_SOURCE_SIM_SOURCE = 1;
+
+    /**
+     * The name_source is from the user
+     * @hide
+     */
+    public static final int NAME_SOURCE_USER_INPUT = 2;
+
+    /**
+     * TelephonyProvider column name for the color of a SIM.
      * <P>Type: INTEGER (int)</P>
      */
+    /** @hide */
     public static final String COLOR = "color";
 
+    /** @hide */
     public static final int COLOR_1 = 0;
 
+    /** @hide */
     public static final int COLOR_2 = 1;
 
+    /** @hide */
     public static final int COLOR_3 = 2;
 
+    /** @hide */
     public static final int COLOR_4 = 3;
 
+    /** @hide */
     public static final int COLOR_DEFAULT = COLOR_1;
 
     /**
-     * The phone number of a SIM.
+     * TelephonyProvider column name for the phone number of a SIM.
      * <P>Type: TEXT (String)</P>
      */
+    /** @hide */
     public static final String NUMBER = "number";
 
     /**
-     * The number display format of a SIM.
+     * TelephonyProvider column name for the number display format of a SIM.
      * <P>Type: INTEGER (int)</P>
      */
+    /** @hide */
     public static final String DISPLAY_NUMBER_FORMAT = "display_number_format";
 
-    public static final int DISPALY_NUMBER_NONE = 0;
+    /** @hide */
+    public static final int DISPLAY_NUMBER_NONE = 0;
 
+    /** @hide */
     public static final int DISPLAY_NUMBER_FIRST = 1;
 
+    /** @hide */
     public static final int DISPLAY_NUMBER_LAST = 2;
 
+    /** @hide */
     public static final int DISLPAY_NUMBER_DEFAULT = DISPLAY_NUMBER_FIRST;
 
     /**
-     * Permission for data roaming of a SIM.
+     * TelephonyProvider column name for permission for data roaming of a SIM.
      * <P>Type: INTEGER (int)</P>
      */
+    /** @hide */
     public static final String DATA_ROAMING = "data_roaming";
 
+    /** @hide */
     public static final int DATA_ROAMING_ENABLE = 1;
 
+    /** @hide */
     public static final int DATA_ROAMING_DISABLE = 0;
 
+    /** @hide */
     public static final int DATA_ROAMING_DEFAULT = DATA_ROAMING_DISABLE;
 
+    /**
+     * TelephonyProvider column name for the MCC associated with a SIM.
+     * <P>Type: INTEGER (int)</P>
+     */
+    public static final String MCC = "mcc";
+
+    /**
+     * TelephonyProvider column name for the MNC associated with a SIM.
+     * <P>Type: INTEGER (int)</P>
+     */
+    public static final String MNC = "mnc";
+
+
     private static final int RES_TYPE_BACKGROUND_DARK = 0;
 
     private static final int RES_TYPE_BACKGROUND_LIGHT = 1;
 
     private static final int[] sSimBackgroundDarkRes = setSimResource(RES_TYPE_BACKGROUND_DARK);
 
-    private static final int[] sSimBackgroundLightRes = setSimResource(RES_TYPE_BACKGROUND_LIGHT);
+    /**
+     * Broadcast Action: The user has changed one of the default subs related to
+     * data, phone calls, or sms</p>
+     * @hide
+     */
+    @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
+    public static final String SUB_DEFAULT_CHANGED_ACTION =
+        "android.intent.action.SUB_DEFAULT_CHANGED";
 
-    private static HashMap<Integer, Long> mSimInfo = new HashMap<Integer, Long>();
-
+    /** @hide */
     public SubscriptionManager() {
         if (DBG) logd("SubscriptionManager created");
     }
 
     /**
-     * Get the SubInfoRecord according to an index
-     * @param context Context provided by caller
+     * Get the SubInfoRecord associated with the subId
      * @param subId The unique SubInfoRecord index in database
      * @return SubInfoRecord, maybe null
+     * @hide - to be unhidden
      */
-    public static SubInfoRecord getSubInfoUsingSubId(Context context, long subId) {
-        if (VDBG) logd("[getSubInfoUsingSubIdx]+ subId:" + subId);
-        if (subId <= 0) {
-            if (VDBG) logd("[getSubInfoUsingSubIdx]- subId <= 0");
+    public static SubInfoRecord getSubInfoForSubscriber(long subId) {
+        if (!isValidSubId(subId)) {
+            logd("[getSubInfoForSubscriberx]- invalid subId");
             return null;
         }
 
@@ -185,7 +276,7 @@
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
             if (iSub != null) {
-                subInfo = iSub.getSubInfoUsingSubId(subId);
+                subInfo = iSub.getSubInfoForSubscriber(subId);
             }
         } catch (RemoteException ex) {
             // ignore it
@@ -197,11 +288,11 @@
 
     /**
      * Get the SubInfoRecord according to an IccId
-     * @param context Context provided by caller
      * @param iccId the IccId of SIM card
-     * @return SubInfoRecord, maybe null
+     * @return SubInfoRecord List, maybe empty but not null
+     * @hide
      */
-    public static List<SubInfoRecord> getSubInfoUsingIccId(Context context, String iccId) {
+    public static List<SubInfoRecord> getSubInfoUsingIccId(String iccId) {
         if (VDBG) logd("[getSubInfoUsingIccId]+ iccId=" + iccId);
         if (iccId == null) {
             logd("[getSubInfoUsingIccId]- null iccid");
@@ -219,19 +310,23 @@
             // ignore it
         }
 
+
+        if (result == null) {
+            result = new ArrayList<SubInfoRecord>();
+        }
         return result;
     }
 
     /**
      * Get the SubInfoRecord according to slotId
-     * @param context Context provided by caller
      * @param slotId the slot which the SIM is inserted
-     * @return SubInfoRecord, maybe null
+     * @return SubInfoRecord list, maybe empty but not null
+     * @hide - to be unhidden
      */
-    public static List<SubInfoRecord> getSubInfoUsingSlotId(Context context, int slotId) {
-        if (VDBG) logd("[getSubInfoUsingSlotId]- slotId=" + slotId);
-        if (slotId < 0) {
-            logd("[getSubInfoUsingSlotId]- return null, slotId < 0");
+    public static List<SubInfoRecord> getSubInfoUsingSlotId(int slotId) {
+        // FIXME: Consider never returning null
+        if (!isValidSlotId(slotId)) {
+            logd("[getSubInfoUsingSlotId]- invalid slotId");
             return null;
         }
 
@@ -246,15 +341,20 @@
             // ignore it
         }
 
+
+        if (result == null) {
+            result = new ArrayList<SubInfoRecord>();
+        }
         return result;
     }
 
     /**
-     * Get all the SubInfoRecord(s) in subinfo database
-     * @param context Context provided by caller
-     * @return Array list of all SubInfoRecords in database, include thsoe that were inserted before
+     * Get all the SubInfoRecord(s) in subInfo database
+     * @return List of all SubInfoRecords in database, include those that were inserted before
+     * maybe empty but not null.
+     * @hide
      */
-    public static List<SubInfoRecord> getAllSubInfoList(Context context) {
+    public static List<SubInfoRecord> getAllSubInfoList() {
         if (VDBG) logd("[getAllSubInfoList]+");
 
         List<SubInfoRecord> result = null;
@@ -268,37 +368,41 @@
             // ignore it
         }
 
+        if (result == null) {
+            result = new ArrayList<SubInfoRecord>();
+        }
         return result;
     }
 
     /**
      * Get the SubInfoRecord(s) of the currently inserted SIM(s)
-     * @param context Context provided by caller
-     * @return Array list of currently inserted SubInfoRecord(s)
+     * @return Array list of currently inserted SubInfoRecord(s) maybe empty but not null
+     * @hide - to be unhidden
      */
-    public static List<SubInfoRecord> getActivatedSubInfoList(Context context) {
-        if (VDBG) logd("[getActivatedSubInfoList]+");
-
+    public static List<SubInfoRecord> getActiveSubInfoList() {
         List<SubInfoRecord> result = null;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
             if (iSub != null) {
-                result = iSub.getActivatedSubInfoList();
+                result = iSub.getActiveSubInfoList();
             }
         } catch (RemoteException ex) {
             // ignore it
         }
 
+        if (result == null) {
+            result = new ArrayList<SubInfoRecord>();
+        }
         return result;
     }
 
     /**
      * Get the SUB count of all SUB(s) in subinfo database
-     * @param context Context provided by caller
      * @return all SIM count in database, include what was inserted before
+     * @hide
      */
-    public static int getAllSubInfoCount(Context context) {
+    public static int getAllSubInfoCount() {
         if (VDBG) logd("[getAllSubInfoCount]+");
 
         int result = 0;
@@ -316,17 +420,40 @@
     }
 
     /**
+     * Get the count of active SUB(s)
+     * @return active SIM count
+     * @hide
+     */
+    public static int getActiveSubInfoCount() {
+        int result = 0;
+
+        try {
+            ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
+            if (iSub != null) {
+                result = iSub.getActiveSubInfoCount();
+            }
+        } catch (RemoteException ex) {
+            // ignore it
+        }
+
+        return result;
+    }
+
+    /**
      * Add a new SubInfoRecord to subinfo database if needed
-     * @param context Context provided by caller
      * @param iccId the IccId of the SIM card
      * @param slotId the slot which the SIM is inserted
      * @return the URL of the newly created row or the updated row
+     * @hide
      */
-    public static Uri addSubInfoRecord(Context context, String iccId, int slotId) {
+    public static Uri addSubInfoRecord(String iccId, int slotId) {
         if (VDBG) logd("[addSubInfoRecord]+ iccId:" + iccId + " slotId:" + slotId);
         if (iccId == null) {
             logd("[addSubInfoRecord]- null iccId");
         }
+        if (!isValidSlotId(slotId)) {
+            logd("[addSubInfoRecord]- invalid slotId");
+        }
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -345,15 +472,15 @@
 
     /**
      * Set SIM color by simInfo index
-     * @param context Context provided by caller
      * @param color the color of the SIM
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
+     * @hide
      */
-    public static int setColor(Context context, int color, long subId) {
+    public static int setColor(int color, long subId) {
         if (VDBG) logd("[setColor]+ color:" + color + " subId:" + subId);
         int size = sSimBackgroundDarkRes.length;
-        if (subId <= 0 || color < 0 || color >= size) {
+        if (!isValidSubId(subId) || color < 0 || color >= size) {
             logd("[setColor]- fail");
             return -1;
         }
@@ -375,26 +502,30 @@
 
     /**
      * Set display name by simInfo index
-     * @param context Context provided by caller
      * @param displayName the display name of SIM card
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
+     * @hide
      */
-    public static int setDisplayName(Context context, String displayName, long subId) {
-        return setDisplayName(context, displayName, subId, -1);
+    public static int setDisplayName(String displayName, long subId) {
+        return setDisplayName(displayName, subId, NAME_SOURCE_UNDEFINDED);
     }
 
     /**
      * Set display name by simInfo index with name source
-     * @param context Context provided by caller
      * @param displayName the display name of SIM card
      * @param subId the unique SubInfoRecord index in database
-     * @param nameSource, 0: DEFAULT_SOURCE, 1: SIM_SOURCE, 2: USER_INPUT
-     * @return the number of records updated
+     * @param nameSource 0: NAME_SOURCE_DEFAULT_SOURCE, 1: NAME_SOURCE_SIM_SOURCE,
+     *                   2: NAME_SOURCE_USER_INPUT, -1 NAME_SOURCE_UNDEFINED
+     * @return the number of records updated or -1 if invalid subId
+     * @hide
      */
-    public static int setDisplayName(Context context, String displayName, long subId, long nameSource) {
-        if (VDBG) logd("[setDisplayName]+  displayName:" + displayName + " subId:" + subId + " nameSource:" + nameSource);
-        if (subId <= 0) {
+    public static int setDisplayName(String displayName, long subId, long nameSource) {
+        if (VDBG) {
+            logd("[setDisplayName]+  displayName:" + displayName + " subId:" + subId
+                    + " nameSource:" + nameSource);
+        }
+        if (!isValidSubId(subId)) {
             logd("[setDisplayName]- fail");
             return -1;
         }
@@ -416,15 +547,14 @@
 
     /**
      * Set phone number by subId
-     * @param context Context provided by caller
      * @param number the phone number of the SIM
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
+     * @hide
      */
-    public static int setDispalyNumber(Context context, String number, long subId) {
-        if (VDBG) logd("[setDispalyNumber]+ number:" + number + " subId:" + subId);
-        if (number == null || subId <= 0) {
-            logd("[setDispalyNumber]- fail");
+    public static int setDisplayNumber(String number, long subId) {
+        if (number == null || !isValidSubId(subId)) {
+            logd("[setDisplayNumber]- fail");
             return -1;
         }
 
@@ -433,7 +563,7 @@
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
             if (iSub != null) {
-                result = iSub.setDispalyNumber(number, subId);
+                result = iSub.setDisplayNumber(number, subId);
             }
         } catch (RemoteException ex) {
             // ignore it
@@ -445,14 +575,14 @@
 
     /**
      * Set number display format. 0: none, 1: the first four digits, 2: the last four digits
-     * @param context Context provided by caller
      * @param format the display format of phone number
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
+     * @hide
      */
-    public static int setDisplayNumberFormat(Context context, int format, long subId) {
+    public static int setDisplayNumberFormat(int format, long subId) {
         if (VDBG) logd("[setDisplayNumberFormat]+ format:" + format + " subId:" + subId);
-        if (format < 0 || subId <= 0) {
+        if (format < 0 || !isValidSubId(subId)) {
             logd("[setDisplayNumberFormat]- fail, return -1");
             return -1;
         }
@@ -474,14 +604,14 @@
 
     /**
      * Set data roaming by simInfo index
-     * @param context Context provided by caller
      * @param roaming 0:Don't allow data when roaming, 1:Allow data when roaming
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
+     * @hide
      */
-    public static int setDataRoaming(Context context, int roaming, long subId) {
+    public static int setDataRoaming(int roaming, long subId) {
         if (VDBG) logd("[setDataRoaming]+ roaming:" + roaming + " subId:" + subId);
-        if (roaming < 0 || subId <= 0) {
+        if (roaming < 0 || !isValidSubId(subId)) {
             logd("[setDataRoaming]- fail");
             return -1;
         }
@@ -500,10 +630,18 @@
         return result;
     }
 
+    /**
+     * Get slotId associated with the subscription.
+     * @return slotId as a positive integer or a negative value if an error either
+     * SIM_NOT_INSERTED or INVALID_SLOT_ID.
+     * @hide - to be unhidden
+     */
     public static int getSlotId(long subId) {
-        if (VDBG) logd("[getSlotId]+ subId:" + subId);
+        if (!isValidSubId(subId)) {
+            logd("[getSlotId]- fail");
+        }
 
-        int result = 0;
+        int result = INVALID_SLOT_ID;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -518,8 +656,12 @@
 
     }
 
+    /** @hide */
     public static long[] getSubId(int slotId) {
-        if (VDBG) logd("[getSubId]+ slotId:" + slotId);
+        if (!isValidSlotId(slotId)) {
+            logd("[getSubId]- fail");
+            return null;
+        }
 
         long[] subId = null;
 
@@ -535,10 +677,14 @@
         return subId;
     }
 
+    /** @hide */
     public static int getPhoneId(long subId) {
-        if (VDBG) logd("[getPhoneId]+ subId=" + subId);
+        if (!isValidSubId(subId)) {
+            logd("[getPhoneId]- fail");
+            return INVALID_PHONE_ID;
+        }
 
-        int result = 0;
+        int result = INVALID_PHONE_ID;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -549,7 +695,7 @@
             // ignore it
         }
 
-        if (VDBG) logd("[getPhoneId]- phonId=" + result);
+        if (VDBG) logd("[getPhoneId]- phoneId=" + result);
         return result;
 
     }
@@ -583,23 +729,14 @@
         Rlog.d(LOG_TAG, "[SubManager] " + msg);
     }
 
-    public static long normalizeSubId(long subId) {
-        long retVal = (subId == DEFAULT_SUB_ID) ? getDefaultSubId() : subId;
-        Rlog.d(LOG_TAG, "[SubManager] normalizeSubId subId=" + retVal);
-        return retVal;
-    }
-
-    public static boolean validSubId(long subId) {
-        return (subId != DEFAULT_SUB_ID) && (subId != -1);
-    }
-
     /**
      * @return the "system" defaultSubId on a voice capable device this
      * will be getDefaultVoiceSubId() and on a data only device it will be
      * getDefaultDataSubId().
+     * @hide
      */
     public static long getDefaultSubId() {
-        long subId = 1;
+        long subId = INVALID_SUB_ID;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -614,8 +751,9 @@
         return subId;
     }
 
+    /** @hide */
     public static long getDefaultVoiceSubId() {
-        long subId = 1;
+        long subId = INVALID_SUB_ID;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
@@ -626,10 +764,11 @@
             // ignore it
         }
 
-        if (VDBG) logd("getDefaultSubId, sub id = " + subId);
+        if (VDBG) logd("getDefaultVoiceSubId, sub id = " + subId);
         return subId;
     }
 
+    /** @hide */
     public static void setDefaultVoiceSubId(long subId) {
         if (VDBG) logd("setDefaultVoiceSubId sub id = " + subId);
         try {
@@ -638,34 +777,81 @@
                 iSub.setDefaultVoiceSubId(subId);
             }
         } catch (RemoteException ex) {
-         // ignore it
+            // ignore it
         }
     }
 
-    public static long getPreferredSmsSubId() {
-        // FIXME add framework support to get the preferred sub
-        return getDefaultSubId();
+    /** @hide */
+    public static SubInfoRecord getDefaultVoiceSubInfo() {
+        return getSubInfoForSubscriber(getDefaultVoiceSubId());
     }
 
-    public static long getPreferredDataSubId() {
-        // FIXME add framework support to get the preferred sub
-        return getDefaultSubId();
+    /** @hide */
+    public static int getDefaultVoicePhoneId() {
+        return getPhoneId(getDefaultVoiceSubId());
     }
 
-    public static long getDefaultDataSubId() {
+    /**
+     * @return subId of the DefaultSms subscription or the value INVALID_SUB_ID if an error.
+     * @hide - to be unhidden
+     */
+    public static long getDefaultSmsSubId() {
+        long subId = INVALID_SUB_ID;
 
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
             if (iSub != null) {
-                return iSub.getDefaultDataSubId();
-            } else {
-                return -1;
+                subId = iSub.getDefaultSmsSubId();
             }
         } catch (RemoteException ex) {
-            return -1;
+            // ignore it
+        }
+
+        if (VDBG) logd("getDefaultSmsSubId, sub id = " + subId);
+        return subId;
+    }
+
+    /** @hide */
+    public static void setDefaultSmsSubId(long subId) {
+        if (VDBG) logd("setDefaultSmsSubId sub id = " + subId);
+        try {
+            ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
+            if (iSub != null) {
+                iSub.setDefaultSmsSubId(subId);
+            }
+        } catch (RemoteException ex) {
+            // ignore it
         }
     }
 
+    /** @hide */
+    public static SubInfoRecord getDefaultSmsSubInfo() {
+        return getSubInfoForSubscriber(getDefaultSmsSubId());
+    }
+
+    /** @hide */
+    public static int getDefaultSmsPhoneId() {
+        return getPhoneId(getDefaultSmsSubId());
+    }
+
+    /** @hide */
+    public static long getDefaultDataSubId() {
+        long subId = INVALID_SUB_ID;
+
+        try {
+            ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
+            if (iSub != null) {
+                subId = iSub.getDefaultDataSubId();
+            }
+        } catch (RemoteException ex) {
+            // ignore it
+        }
+
+        if (VDBG) logd("getDefaultDataSubId, sub id = " + subId);
+        return subId;
+    }
+
+    /** @hide */
     public static void setDefaultDataSubId(long subId) {
         if (VDBG) logd("setDataSubscription sub id = " + subId);
         try {
@@ -674,14 +860,22 @@
                 iSub.setDefaultDataSubId(subId);
             }
         } catch (RemoteException ex) {
-         // ignore it
+            // ignore it
         }
     }
 
-    public static void clearSubInfo()
-    {
-        if (VDBG) logd("[clearSubInfo]+");
+    /** @hide */
+    public static SubInfoRecord getDefaultDataSubInfo() {
+        return getSubInfoForSubscriber(getDefaultDataSubId());
+    }
 
+    /** @hide */
+    public static int getDefaultDataPhoneId() {
+        return getPhoneId(getDefaultDataSubId());
+    }
+
+    /** @hide */
+    public static void clearSubInfo() {
         try {
             ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
             if (iSub != null) {
@@ -694,19 +888,107 @@
         return;
     }
 
+    //FIXME this is vulnerable to race conditions
+    /** @hide */
+    public static boolean allDefaultsSelected() {
+        if (getDefaultDataSubId() == INVALID_SUB_ID) {
+            return false;
+        }
+        if (getDefaultSmsSubId() == INVALID_SUB_ID) {
+            return false;
+        }
+        if (getDefaultVoiceSubId() == INVALID_SUB_ID) {
+            return false;
+        }
+        return true;
+    }
+
+    /**
+     * If a default is set to subscription which is not active, this will reset that default back to
+     * INVALID_SUB_ID.
+     * @hide
+     */
+    public static void clearDefaultsForInactiveSubIds() {
+        if (VDBG) logd("clearDefaultsForInactiveSubIds");
+        try {
+            ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
+            if (iSub != null) {
+                iSub.clearDefaultsForInactiveSubIds();
+            }
+        } catch (RemoteException ex) {
+            // ignore it
+        }
+    }
+
+    /**
+     * @return true if a valid subId else false
+     * @hide - to be unhidden
+     */
+    public static boolean isValidSubId(long subId) {
+        return subId > INVALID_SUB_ID ;
+    }
+
+    /** @hide */
+    public static boolean isValidSlotId(int slotId) {
+        // We are testing INVALID_SLOT_ID and slotId >= 0 independently because we should
+        // not assume that INVALID_SLOT_ID will always be a negative value.  Any negative
+        // value is invalid.
+        return slotId != INVALID_SLOT_ID && slotId >= 0 &&
+                slotId < TelephonyManager.getDefault().getSimCount();
+    }
+
+    /** @hide */
+    public static boolean isValidPhoneId(int phoneId) {
+        // We are testing INVALID_PHONE_ID and phoneId >= 0 independently because we should
+        // not assume that INVALID_PHONE_ID will always be a negative value.  Any negative
+        // value is invalid.
+        return phoneId != INVALID_PHONE_ID && phoneId >= 0 &&
+                phoneId < TelephonyManager.getDefault().getPhoneCount();
+    }
+
+    /** @hide */
     public static void putPhoneIdAndSubIdExtra(Intent intent, int phoneId) {
-        long [] subId = SubscriptionManager.getSubId(phoneId);
-        if ((subId != null) && (subId.length >= 1)) {
-            putPhoneIdAndSubIdExtra(intent, phoneId, subId[0]);
+        long[] subIds = SubscriptionManager.getSubId(phoneId);
+        if (subIds != null && subIds.length > 0) {
+            putPhoneIdAndSubIdExtra(intent, phoneId, subIds[0]);
         } else {
             logd("putPhoneIdAndSubIdExtra: no valid subs");
         }
     }
 
+    /** @hide */
     public static void putPhoneIdAndSubIdExtra(Intent intent, int phoneId, long subId) {
         if (VDBG) logd("putPhoneIdAndSubIdExtra: phoneId=" + phoneId + " subId=" + subId);
-        intent.putExtra(PhoneConstants.SLOT_KEY, phoneId); //FIXME: RENAME TO PHONE_ID_KEY ??
         intent.putExtra(PhoneConstants.SUBSCRIPTION_KEY, subId);
+        intent.putExtra(PhoneConstants.PHONE_KEY, phoneId);
+        //FIXME this is using phoneId and slotId interchangeably
+        //Eventually, this should be removed as it is not the slot id
+        intent.putExtra(PhoneConstants.SLOT_KEY, phoneId);
+    }
+
+    /**
+     * @return the list of subId's that are active,
+     *         is never null but the length maybe 0.
+     * @hide
+     */
+    public static long[] getActiveSubIdList() {
+        long[] subId = null;
+
+        try {
+            ISub iSub = ISub.Stub.asInterface(ServiceManager.getService("isub"));
+            if (iSub != null) {
+                subId = iSub.getActiveSubIdList();
+            }
+        } catch (RemoteException ex) {
+            // ignore it
+        }
+
+        if (subId == null) {
+            subId = new long[0];
+        }
+
+        return subId;
+
     }
 }
 
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index c50110a..34b1454 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -26,9 +26,8 @@
 import android.os.ServiceManager;
 import android.os.SystemProperties;
 import android.util.Log;
-import android.util.Pair;
 
-import com.android.internal.telecomm.ITelecommService;
+import com.android.internal.telecom.ITelecomService;
 import com.android.internal.telephony.IPhoneSubInfo;
 import com.android.internal.telephony.ITelephony;
 import com.android.internal.telephony.ITelephonyRegistry;
@@ -63,8 +62,6 @@
 public class TelephonyManager {
     private static final String TAG = "TelephonyManager";
 
-    private static final String TELECOMM_SERVICE_NAME = "telecomm";
-
     private static ITelephonyRegistry sRegistry;
 
     /**
@@ -608,7 +605,38 @@
     public String getDeviceId(int slotId) {
         long[] subId = SubscriptionManager.getSubId(slotId);
         try {
-            return getSubscriberInfo().getDeviceIdUsingSubId(subId[0]);
+            return getSubscriberInfo().getDeviceIdForSubscriber(subId[0]);
+        } catch (RemoteException ex) {
+            return null;
+        } catch (NullPointerException ex) {
+            return null;
+        }
+    }
+
+    /**
+     * Returns the IMEI. Return null if IMEI is not available.
+     *
+     * <p>Requires Permission:
+     *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
+     */
+    /** {@hide} */
+    public String getImei() {
+        return getImei(getDefaultSim());
+    }
+
+    /**
+     * Returns the IMEI. Return null if IMEI is not available.
+     *
+     * <p>Requires Permission:
+     *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
+     *
+     * @param slotId of which deviceID is returned
+     */
+    /** {@hide} */
+    public String getImei(int slotId) {
+        long[] subId = SubscriptionManager.getSubId(slotId);
+        try {
+            return getSubscriberInfo().getImeiForSubscriber(subId[0]);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -672,7 +700,7 @@
     /** @hide */
     public void enableLocationUpdates(long subId) {
         try {
-            getITelephony().enableLocationUpdatesUsingSubId(subId);
+            getITelephony().enableLocationUpdatesForSubscriber(subId);
         } catch (RemoteException ex) {
         } catch (NullPointerException ex) {
         }
@@ -694,7 +722,7 @@
     /** @hide */
     public void disableLocationUpdates(long subId) {
         try {
-            getITelephony().disableLocationUpdatesUsingSubId(subId);
+            getITelephony().disableLocationUpdatesForSubscriber(subId);
         } catch (RemoteException ex) {
         } catch (NullPointerException ex) {
         }
@@ -741,6 +769,7 @@
      *
      * {@hide}
      */
+    @SystemApi
     public int getCurrentPhoneType() {
         return getCurrentPhoneType(getDefaultSubscription());
     }
@@ -755,12 +784,13 @@
      * @param subId for which phone type is returned
      */
     /** {@hide} */
+    @SystemApi
     public int getCurrentPhoneType(long subId) {
 
         try{
             ITelephony telephony = getITelephony();
             if (telephony != null) {
-                return telephony.getActivePhoneTypeUsingSubId(subId);
+                return telephony.getActivePhoneTypeForSubscriber(subId);
             } else {
                 // This can happen when the ITelephony interface is not up yet.
                 return getPhoneTypeFromProperty(subId);
@@ -1126,7 +1156,7 @@
        try {
            ITelephony telephony = getITelephony();
            if (telephony != null) {
-               return telephony.getNetworkTypeUsingSubId(subId);
+               return telephony.getNetworkTypeForSubscriber(subId);
            } else {
                // This can happen when the ITelephony interface is not up yet.
                return NETWORK_TYPE_UNKNOWN;
@@ -1180,7 +1210,7 @@
         try{
             ITelephony telephony = getITelephony();
             if (telephony != null) {
-                return telephony.getDataNetworkTypeUsingSubId(subId);
+                return telephony.getDataNetworkTypeForSubscriber(subId);
             } else {
                 // This can happen when the ITelephony interface is not up yet.
                 return NETWORK_TYPE_UNKNOWN;
@@ -1212,7 +1242,7 @@
         try{
             ITelephony telephony = getITelephony();
             if (telephony != null) {
-                return telephony.getVoiceNetworkTypeUsingSubId(subId);
+                return telephony.getVoiceNetworkTypeForSubscriber(subId);
             } else {
                 // This can happen when the ITelephony interface is not up yet.
                 return NETWORK_TYPE_UNKNOWN;
@@ -1539,7 +1569,7 @@
     /** {@hide} */
     public String getSimSerialNumber(long subId) {
         try {
-            return getSubscriberInfo().getIccSerialNumberUsingSubId(subId);
+            return getSubscriberInfo().getIccSerialNumberForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1575,7 +1605,7 @@
     /** {@hide} */
     public int getLteOnCdmaMode(long subId) {
         try {
-            return getITelephony().getLteOnCdmaModeUsingSubId(subId);
+            return getITelephony().getLteOnCdmaModeForSubscriber(subId);
         } catch (RemoteException ex) {
             // Assume no ICC card if remote exception which shouldn't happen
             return PhoneConstants.LTE_ON_CDMA_UNKNOWN;
@@ -1615,7 +1645,7 @@
     /** {@hide} */
     public String getSubscriberId(long subId) {
         try {
-            return getSubscriberInfo().getSubscriberIdUsingSubId(subId);
+            return getSubscriberInfo().getSubscriberIdForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1654,7 +1684,7 @@
     /** {@hide} */
     public String getGroupIdLevel1(long subId) {
         try {
-            return getSubscriberInfo().getGroupIdLevel1UsingSubId(subId);
+            return getSubscriberInfo().getGroupIdLevel1ForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1671,7 +1701,7 @@
      *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
      */
     public String getLine1Number() {
-        return getLine1Number(getDefaultSubscription());
+        return getLine1NumberForSubscriber(getDefaultSubscription());
     }
 
     /**
@@ -1684,7 +1714,7 @@
      * @param subId whose phone number for line 1 is returned
      */
     /** {@hide} */
-    public String getLine1Number(long subId) {
+    public String getLine1NumberForSubscriber(long subId) {
         String number = null;
         try {
             number = getITelephony().getLine1NumberForDisplay(subId);
@@ -1695,7 +1725,7 @@
             return number;
         }
         try {
-            return getSubscriberInfo().getLine1NumberUsingSubId(subId);
+            return getSubscriberInfo().getLine1NumberForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1705,10 +1735,10 @@
     }
 
     /**
-     * Set the phone number string and its alphatag for line 1 for display
-     * purpose only, for example, displayed in Phone Status. It won't change
-     * the actual MSISDN/MDN. This setting won't be persisted during power cycle
-     * and it should be set again after reboot.
+     * Set the line 1 phone number string and its alphatag for the current ICCID
+     * for display purpose only, for example, displayed in Phone Status. It won't
+     * change the actual MSISDN/MDN. To unset alphatag or number, pass in a null
+     * value.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
@@ -1718,14 +1748,14 @@
      * @param number The dialing number
      */
     public void setLine1NumberForDisplay(String alphaTag, String number) {
-        setLine1NumberForDisplay(getDefaultSubscription(), alphaTag, number);
+        setLine1NumberForDisplayForSubscriber(getDefaultSubscription(), alphaTag, number);
     }
 
     /**
-     * Set the phone number string and its alphatag for line 1 for display
-     * purpose only, for example, displayed in Phone Status. It won't change
-     * the actual MSISDN/MDN. This setting won't be persisted during power cycle
-     * and it should be set again after reboot.
+     * Set the line 1 phone number string and its alphatag for the current ICCID
+     * for display purpose only, for example, displayed in Phone Status. It won't
+     * change the actual MSISDN/MDN. To unset alphatag or number, pass in a null
+     * value.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
@@ -1734,10 +1764,11 @@
      * @param subId the subscriber that the alphatag and dialing number belongs to.
      * @param alphaTag alpha-tagging of the dailing nubmer
      * @param number The dialing number
+     * @hide
      */
-    public void setLine1NumberForDisplay(long subId, String alphaTag, String number) {
+    public void setLine1NumberForDisplayForSubscriber(long subId, String alphaTag, String number) {
         try {
-            getITelephony().setLine1NumberForDisplay(subId, alphaTag, number);
+            getITelephony().setLine1NumberForDisplayForSubscriber(subId, alphaTag, number);
         } catch (RemoteException ex) {
         } catch (NullPointerException ex) {
         }
@@ -1753,7 +1784,7 @@
      * nobody seems to call this.
      */
     public String getLine1AlphaTag() {
-        return getLine1AlphaTag(getDefaultSubscription());
+        return getLine1AlphaTagForSubscriber(getDefaultSubscription());
     }
 
     /**
@@ -1767,7 +1798,7 @@
      * nobody seems to call this.
      */
     /** {@hide} */
-    public String getLine1AlphaTag(long subId) {
+    public String getLine1AlphaTagForSubscriber(long subId) {
         String alphaTag = null;
         try {
             alphaTag = getITelephony().getLine1AlphaTagForDisplay(subId);
@@ -1778,7 +1809,7 @@
             return alphaTag;
         }
         try {
-            return getSubscriberInfo().getLine1AlphaTagUsingSubId(subId);
+            return getSubscriberInfo().getLine1AlphaTagForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1812,7 +1843,7 @@
     /** {@hide} */
     public String getMsisdn(long subId) {
         try {
-            return getSubscriberInfo().getMsisdnUsingSubId(subId);
+            return getSubscriberInfo().getMsisdnForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1842,7 +1873,7 @@
     /** {@hide} */
     public String getVoiceMailNumber(long subId) {
         try {
-            return getSubscriberInfo().getVoiceMailNumberUsingSubId(subId);
+            return getSubscriberInfo().getVoiceMailNumberForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1874,7 +1905,7 @@
     /** {@hide} */
     public String getCompleteVoiceMailNumber(long subId) {
         try {
-            return getSubscriberInfo().getCompleteVoiceMailNumberUsingSubId(subId);
+            return getSubscriberInfo().getCompleteVoiceMailNumberForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -1904,7 +1935,7 @@
     /** {@hide} */
     public int getVoiceMessageCount(long subId) {
         try {
-            return getITelephony().getVoiceMessageCountUsingSubId(subId);
+            return getITelephony().getVoiceMessageCountForSubscriber(subId);
         } catch (RemoteException ex) {
             return 0;
         } catch (NullPointerException ex) {
@@ -1936,7 +1967,7 @@
     /** {@hide} */
     public String getVoiceMailAlphaTag(long subId) {
         try {
-            return getSubscriberInfo().getVoiceMailAlphaTagUsingSubId(subId);
+            return getSubscriberInfo().getVoiceMailAlphaTagForSubscriber(subId);
         } catch (RemoteException ex) {
             return null;
         } catch (NullPointerException ex) {
@@ -2014,7 +2045,11 @@
      * Returns a constant indicating the call state (cellular) on the device.
      */
     public int getCallState() {
-        return getCallState(getDefaultSubscription());
+        try {
+            return getTelecomService().getCallState();
+        } catch (RemoteException | NullPointerException e) {
+            return CALL_STATE_IDLE;
+        }
     }
 
     /**
@@ -2026,7 +2061,7 @@
     /** {@hide} */
     public int getCallState(long subId) {
         try {
-            return getITelephony().getCallStateUsingSubId(subId);
+            return getITelephony().getCallStateForSubscriber(subId);
         } catch (RemoteException ex) {
             // the phone process is restarting.
             return CALL_STATE_IDLE;
@@ -2111,8 +2146,8 @@
         return ITelephony.Stub.asInterface(ServiceManager.getService(Context.TELEPHONY_SERVICE));
     }
 
-    private ITelecommService getTelecommService() {
-        return ITelecommService.Stub.asInterface(ServiceManager.getService(TELECOMM_SERVICE_NAME));
+    private ITelecomService getTelecomService() {
+        return ITelecomService.Stub.asInterface(ServiceManager.getService(Context.TELECOM_SERVICE));
     }
 
     //
@@ -2148,7 +2183,7 @@
         String pkgForDebug = mContext != null ? mContext.getPackageName() : "<unknown>";
         try {
             Boolean notifyNow = (getITelephony() != null);
-            sRegistry.listenUsingSubId(listener.mSubId, pkgForDebug, listener.callback, events, notifyNow);
+            sRegistry.listenForSubscriber(listener.mSubId, pkgForDebug, listener.callback, events, notifyNow);
         } catch (RemoteException ex) {
             // system process dead
         } catch (NullPointerException ex) {
@@ -2171,7 +2206,7 @@
     /** {@hide} */
     public int getCdmaEriIconIndex(long subId) {
         try {
-            return getITelephony().getCdmaEriIconIndexUsingSubId(subId);
+            return getITelephony().getCdmaEriIconIndexForSubscriber(subId);
         } catch (RemoteException ex) {
             // the phone process is restarting.
             return -1;
@@ -2199,7 +2234,7 @@
     /** {@hide} */
     public int getCdmaEriIconMode(long subId) {
         try {
-            return getITelephony().getCdmaEriIconModeUsingSubId(subId);
+            return getITelephony().getCdmaEriIconModeForSubscriber(subId);
         } catch (RemoteException ex) {
             // the phone process is restarting.
             return -1;
@@ -2224,7 +2259,7 @@
     /** {@hide} */
     public String getCdmaEriText(long subId) {
         try {
-            return getITelephony().getCdmaEriTextUsingSubId(subId);
+            return getITelephony().getCdmaEriTextForSubscriber(subId);
         } catch (RemoteException ex) {
             // the phone process is restarting.
             return null;
@@ -2459,7 +2494,7 @@
      * @param filePath
      * @return The APDU response.
      */
-    byte[] iccExchangeSimIO(int fileID, int command, int p1, int p2, int p3,
+    public byte[] iccExchangeSimIO(int fileID, int command, int p1, int p2, int p3,
             String filePath) {
         try {
             return getITelephony().iccExchangeSimIO(fileID, command, p1, p2,
@@ -2480,9 +2515,9 @@
      * @param content String containing SAT/USAT response in hexadecimal
      *                format starting with command tag. See TS 102 223 for
      *                details.
-     * @return The APDU response from the ICC card, with the last 4 bytes
-     *         being the status word. If the command fails, returns an empty
-     *         string.
+     * @return The APDU response from the ICC card in hexadecimal format
+     *         with the last 4 bytes being the status word. If the command fails,
+     *         returns an empty string.
      */
     public String sendEnvelopeWithStatus(String content) {
         try {
@@ -2872,27 +2907,6 @@
     }
 
     /**
-     * Get the calculated preferred network type.
-     * Used for debugging incorrect network type.
-     * <p>
-     * Requires Permission:
-     *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
-     *
-     * @return the preferred network type, defined in RILConstants.java or -1 if
-     *         none available.
-     */
-    public int getCalculatedPreferredNetworkType() {
-        try {
-            return getITelephony().getCalculatedPreferredNetworkType();
-        } catch (RemoteException ex) {
-            Rlog.e(TAG, "getCalculatedPreferredNetworkType RemoteException", ex);
-        } catch (NullPointerException ex) {
-            Rlog.e(TAG, "getCalculatedPreferredNetworkType NPE", ex);
-        }
-        return -1;
-    }
-
-    /**
      * Get the preferred network type.
      * Used for device configuration by some CDMA operators.
      * <p>
@@ -2901,6 +2915,7 @@
      * Or the calling app has carrier privileges. @see #hasCarrierPrivileges
      *
      * @return the preferred network type, defined in RILConstants.java.
+     * @hide
      */
     public int getPreferredNetworkType() {
         try {
@@ -2923,6 +2938,7 @@
      *
      * @param networkType the preferred network type, defined in RILConstants.java.
      * @return true on success; false on any failure.
+     * @hide
      */
     public boolean setPreferredNetworkType(int networkType) {
         try {
@@ -2936,25 +2952,17 @@
     }
 
     /**
-     * Set the CDMA subscription source.
-     * Used for device supporting both NV and RUIM for CDMA.
+     * Set the preferred network type to global mode which includes LTE, CDMA, EvDo and GSM/WCDMA.
+     *
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
      * Or the calling app has carrier privileges. @see #hasCarrierPrivileges
      *
-     * @param subscriptionType the subscription type, 0 for RUIM, 1 for NV.
      * @return true on success; false on any failure.
      */
-    public boolean setCdmaSubscription(int subscriptionType) {
-        try {
-            return getITelephony().setCdmaSubscription(subscriptionType);
-        } catch (RemoteException ex) {
-            Rlog.e(TAG, "setCdmaSubscription RemoteException", ex);
-        } catch (NullPointerException ex) {
-            Rlog.e(TAG, "setCdmaSubscription NPE", ex);
-        }
-        return false;
+    public boolean setGlobalPreferredNetworkType() {
+        return setPreferredNetworkType(RILConstants.NETWORK_MODE_LTE_CDMA_EVDO_GSM_WCDMA);
     }
 
     /**
@@ -2992,9 +3000,9 @@
     }
 
     /**
-     * Override the branding for the input ICCID.
+     * Override the branding for the current ICCID.
      *
-     * Once set, whenever the ICCID is inserted into the device, the service
+     * Once set, whenever the SIM is present in the device, the service
      * provider name (SPN) and the operator name will both be replaced by the
      * brand value input. To unset the value, the same function should be
      * called with a null brand value.
@@ -3003,14 +3011,12 @@
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
      *  or has to be carrier app - see #hasCarrierPrivileges.
      *
-     * @param iccId The ICCID of that the branding applies to.
      * @param brand The brand name to display/set.
      * @return true if the operation was executed correctly.
      */
-    public boolean setOperatorBrandOverride(String iccId, String brand) {
-        // TODO: Validate ICCID format.
+    public boolean setOperatorBrandOverride(String brand) {
         try {
-            return getITelephony().setOperatorBrandOverride(iccId, brand);
+            return getITelephony().setOperatorBrandOverride(brand);
         } catch (RemoteException ex) {
             Rlog.e(TAG, "setOperatorBrandOverride RemoteException", ex);
         } catch (NullPointerException ex) {
@@ -3025,6 +3031,42 @@
 
     /** @hide */
     @SystemApi
+    public String getCdmaMdn() {
+        return getCdmaMdn(getDefaultSubscription());
+    }
+
+    /** @hide */
+    @SystemApi
+    public String getCdmaMdn(long subId) {
+        try {
+            return getITelephony().getCdmaMdn(subId);
+        } catch (RemoteException ex) {
+            return null;
+        } catch (NullPointerException ex) {
+            return null;
+        }
+    }
+
+    /** @hide */
+    @SystemApi
+    public String getCdmaMin() {
+        return getCdmaMin(getDefaultSubscription());
+    }
+
+    /** @hide */
+    @SystemApi
+    public String getCdmaMin(long subId) {
+        try {
+            return getITelephony().getCdmaMin(subId);
+        } catch (RemoteException ex) {
+            return null;
+        } catch (NullPointerException ex) {
+            return null;
+        }
+    }
+
+    /** @hide */
+    @SystemApi
     public int checkCarrierPrivilegesForPackage(String pkgname) {
         try {
             return getITelephony().checkCarrierPrivilegesForPackage(pkgname);
@@ -3038,13 +3080,13 @@
 
     /** @hide */
     @SystemApi
-    public List<String> getCarrierPackageNamesForBroadcastIntent(Intent intent) {
+    public List<String> getCarrierPackageNamesForIntent(Intent intent) {
         try {
-            return getITelephony().getCarrierPackageNamesForBroadcastIntent(intent);
+            return getITelephony().getCarrierPackageNamesForIntent(intent);
         } catch (RemoteException ex) {
-            Rlog.e(TAG, "getCarrierPackageNamesForBroadcastIntent RemoteException", ex);
+            Rlog.e(TAG, "getCarrierPackageNamesForIntent RemoteException", ex);
         } catch (NullPointerException ex) {
-            Rlog.e(TAG, "getCarrierPackageNamesForBroadcastIntent NPE", ex);
+            Rlog.e(TAG, "getCarrierPackageNamesForIntent NPE", ex);
         }
         return null;
     }
@@ -3094,9 +3136,9 @@
     @SystemApi
     public void silenceRinger() {
         try {
-            getTelecommService().silenceRinger();
+            getTelecomService().silenceRinger();
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#silenceRinger", e);
+            Log.e(TAG, "Error calling ITelecomService#silenceRinger", e);
         }
     }
 
@@ -3318,22 +3360,23 @@
     }
 
     /**
-     * Set whether Android should display a simplified Mobile Network Settings UI.
-     * The setting won't be persisted during power cycle.
+     * Set whether Android should display a simplified Mobile Network Settings UI
+     * for the current ICCID.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
      * Or the calling app has carrier privileges. @see #hasCarrierPrivileges
      *
      * @param enable true means enabling the simplified UI.
+     * @hide
      */
     public void enableSimplifiedNetworkSettings(boolean enable) {
-        enableSimplifiedNetworkSettings(getDefaultSubscription(), enable);
+        enableSimplifiedNetworkSettingsForSubscriber(getDefaultSubscription(), enable);
     }
 
     /**
-     * Set whether Android should display a simplified Mobile Network Settings UI.
-     * The setting won't be persisted during power cycle.
+     * Set whether Android should display a simplified Mobile Network Settings UI
+     * for the current ICCID.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
@@ -3341,39 +3384,44 @@
      *
      * @param subId for which the simplified UI should be enabled or disabled.
      * @param enable true means enabling the simplified UI.
+     * @hide
      */
-    public void enableSimplifiedNetworkSettings(long subId, boolean enable) {
+    public void enableSimplifiedNetworkSettingsForSubscriber(long subId, boolean enable) {
         try {
-            getITelephony().enableSimplifiedNetworkSettings(subId, enable);
+            getITelephony().enableSimplifiedNetworkSettingsForSubscriber(subId, enable);
         } catch (RemoteException ex) {
         } catch (NullPointerException ex) {
         }
     }
 
     /**
-     * Get whether a simplified Mobile Network Settings UI is enabled.
+     * Get whether a simplified Mobile Network Settings UI is enabled for the
+     * current ICCID.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
      *
      * @return true if the simplified UI is enabled.
+     * @hide
      */
     public boolean getSimplifiedNetworkSettingsEnabled() {
-        return getSimplifiedNetworkSettingsEnabled(getDefaultSubscription());
+        return getSimplifiedNetworkSettingsEnabledForSubscriber(getDefaultSubscription());
     }
 
     /**
-     * Get whether a simplified Mobile Network Settings UI is enabled.
+     * Get whether a simplified Mobile Network Settings UI is enabled for the
+     * current ICCID.
      * <p>
      * Requires Permission:
      *   {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE}
      *
      * @param subId for which the simplified UI should be enabled or disabled.
      * @return true if the simplified UI is enabled.
+     * @hide
      */
-    public boolean getSimplifiedNetworkSettingsEnabled(long subId) {
+    public boolean getSimplifiedNetworkSettingsEnabledForSubscriber(long subId) {
         try {
-            return getITelephony().getSimplifiedNetworkSettingsEnabled(subId);
+            return getITelephony().getSimplifiedNetworkSettingsEnabledForSubscriber(subId);
         } catch (RemoteException ex) {
         } catch (NullPointerException ex) {
         }
diff --git a/telephony/java/com/android/ims/ImsCallProfile.java b/telephony/java/com/android/ims/ImsCallProfile.java
index dcd0b79..8b7901c 100644
--- a/telephony/java/com/android/ims/ImsCallProfile.java
+++ b/telephony/java/com/android/ims/ImsCallProfile.java
@@ -19,7 +19,9 @@
 import android.os.Bundle;
 import android.os.Parcel;
 import android.os.Parcelable;
-import android.telecomm.VideoProfile;
+import android.telecom.VideoProfile;
+
+import com.android.internal.telephony.PhoneConstants;
 
 /**
  * Parcelable object to handle IMS call profile.
@@ -337,6 +339,38 @@
     }
 
     /**
+     * Translate presentation value to OIR value
+     * @param presentation
+     * @return OIR valuse
+     */
+    public static int presentationToOIR(int presentation) {
+        switch (presentation) {
+            case PhoneConstants.PRESENTATION_RESTRICTED:
+                return ImsCallProfile.OIR_PRESENTATION_RESTRICTED;
+            case PhoneConstants.PRESENTATION_ALLOWED:
+                return ImsCallProfile.OIR_PRESENTATION_NOT_RESTRICTED;
+            default:
+                return ImsCallProfile.OIR_DEFAULT;
+        }
+    }
+
+    /**
+     * Translate OIR value to presentation value
+     * @param oir value
+     * @return presentation value
+     */
+    public static int OIRToPresentation(int oir) {
+        switch(oir) {
+            case ImsCallProfile.OIR_PRESENTATION_RESTRICTED:
+                return PhoneConstants.PRESENTATION_RESTRICTED;
+            case ImsCallProfile.OIR_PRESENTATION_NOT_RESTRICTED:
+                return PhoneConstants.PRESENTATION_ALLOWED;
+            default:
+                return PhoneConstants.PRESENTATION_UNKNOWN;
+        }
+    }
+
+    /**
      * Determines if a video state is set in a video state bit-mask.
      *
      * @param videoState The video state bit mask.
diff --git a/telephony/java/com/android/ims/internal/IImsCallSession.aidl b/telephony/java/com/android/ims/internal/IImsCallSession.aidl
index ba4cb01..98b2d8a 100644
--- a/telephony/java/com/android/ims/internal/IImsCallSession.aidl
+++ b/telephony/java/com/android/ims/internal/IImsCallSession.aidl
@@ -16,6 +16,7 @@
 
 package com.android.ims.internal;
 
+import android.os.Message;
 import com.android.ims.ImsCallProfile;
 import com.android.ims.ImsStreamMediaProfile;
 import com.android.ims.internal.IImsCallSessionListener;
@@ -206,10 +207,10 @@
      * event 0 ~ 9 maps to decimal value 0 ~ 9, '*' to 10, '#' to 11, event 'A' ~ 'D' to 12 ~ 15,
      * and event flash to 16. Currently, event flash is not supported.
      *
-     * @param code the DTMF to send. Value 0 to 15 (inclusive) are valid inputs.
-     * @param duration the interval in milli-seconds between the DTMFs
+     * @param c the DTMF to send. '0' ~ '9', 'A' ~ 'D', '*', '#' are valid inputs.
+     * @param result.
      */
-    void sendDtmf(int code, int duration);
+    void sendDtmf(char c, in Message result);
 
     /**
      * Sends an USSD message.
diff --git a/telephony/java/com/android/ims/internal/IImsVideoCallCallback.aidl b/telephony/java/com/android/ims/internal/IImsVideoCallCallback.aidl
index 67bfe41..f867fcb 100644
--- a/telephony/java/com/android/ims/internal/IImsVideoCallCallback.aidl
+++ b/telephony/java/com/android/ims/internal/IImsVideoCallCallback.aidl
@@ -16,8 +16,8 @@
 
 package com.android.ims.internal;
 
-import android.telecomm.CameraCapabilities;
-import android.telecomm.VideoProfile;
+import android.telecom.CameraCapabilities;
+import android.telecom.VideoProfile;
 
 /**
  * Internal remote interface for IMS's video call provider.
@@ -26,8 +26,8 @@
  * separate aidl interface for invoking callbacks in Telephony from the IMS Service to without
  * accessing internal interfaces. See {@link IImsVideoCallProvider} for additional detail.
  *
- * @see android.telecomm.internal.IVideoCallCallback
- * @see android.telecomm.VideoCallImpl
+ * @see android.telecom.internal.IVideoCallCallback
+ * @see android.telecom.VideoCallImpl
  *
  * {@hide}
  */
diff --git a/telephony/java/com/android/ims/internal/IImsVideoCallProvider.aidl b/telephony/java/com/android/ims/internal/IImsVideoCallProvider.aidl
index 4db0d14..1fd88e7 100644
--- a/telephony/java/com/android/ims/internal/IImsVideoCallProvider.aidl
+++ b/telephony/java/com/android/ims/internal/IImsVideoCallProvider.aidl
@@ -17,7 +17,7 @@
 package com.android.ims.internal;
 
 import android.view.Surface;
-import android.telecomm.VideoProfile;
+import android.telecom.VideoProfile;
 
 import com.android.ims.internal.IImsVideoCallCallback;
 
@@ -35,8 +35,8 @@
  * video call provider will not have the benefit of accessing the internal
  * {@link IVideoCallProvider} aidl for interprocess communication.
  *
- * @see android.telecomm.internal.IVideoCallProvider
- * @see android.telecomm.VideoCallProvider
+ * @see android.telecom.internal.IVideoCallProvider
+ * @see android.telecom.VideoCallProvider
  * @hide
  */
 oneway interface IImsVideoCallProvider {
diff --git a/telephony/java/com/android/internal/telephony/CallerInfo.java b/telephony/java/com/android/internal/telephony/CallerInfo.java
index c9c4586..88e5bd6 100644
--- a/telephony/java/com/android/internal/telephony/CallerInfo.java
+++ b/telephony/java/com/android/internal/telephony/CallerInfo.java
@@ -40,8 +40,6 @@
 import com.android.i18n.phonenumbers.Phonenumber.PhoneNumber;
 import android.telephony.SubscriptionManager;
 
-import android.telephony.TelephonyManager;
-
 import java.util.Locale;
 
 
@@ -102,6 +100,7 @@
     public long contactIdOrZero;
     public boolean needUpdate;
     public Uri contactRefUri;
+    public String lookupKey;
 
     /**
      * Contact display photo URI.  If a contact has no display photo but a thumbnail, it'll be
@@ -219,7 +218,7 @@
                 columnIndex = getColumnIndexForPersonId(contactRef, cursor);
                 if (columnIndex != -1) {
                     final long contactId = cursor.getLong(columnIndex);
-                    if (contactId != 0 && !Contacts.isCorpContactId(contactId)) {
+                    if (contactId != 0 && !Contacts.isEnterpriseContactId(contactId)) {
                         info.contactIdOrZero = contactId;
                         if (VDBG) {
                             Rlog.v(TAG, "==> got info.contactIdOrZero: " + info.contactIdOrZero);
@@ -233,6 +232,12 @@
                     // the in-call UI, for example.)
                 }
 
+                // Contact lookupKey
+                columnIndex = cursor.getColumnIndex(PhoneLookup.LOOKUP_KEY);
+                if (columnIndex != -1) {
+                    info.lookupKey = cursor.getString(columnIndex);
+                }
+
                 // Display photo URI.
                 columnIndex = cursor.getColumnIndex(PhoneLookup.PHOTO_URI);
                 if ((columnIndex != -1) && (cursor.getString(columnIndex) != null)) {
diff --git a/telephony/java/com/android/internal/telephony/GsmAlphabet.java b/telephony/java/com/android/internal/telephony/GsmAlphabet.java
index 4cba70d..d1c8ef0 100644
--- a/telephony/java/com/android/internal/telephony/GsmAlphabet.java
+++ b/telephony/java/com/android/internal/telephony/GsmAlphabet.java
@@ -609,16 +609,25 @@
                 }
             } else {
                 if (prevWasEscape) {
-                    char shiftChar = shiftTableToChar.charAt(c);
+                    char shiftChar =
+                            c < shiftTableToChar.length() ? shiftTableToChar.charAt(c) : ' ';
                     if (shiftChar == ' ') {
                         // display character from main table if not present in shift table
-                        ret.append(languageTableToChar.charAt(c));
+                        if (c < languageTableToChar.length()) {
+                            ret.append(languageTableToChar.charAt(c));
+                        } else {
+                            ret.append(' ');
+                        }
                     } else {
                         ret.append(shiftChar);
                     }
                 } else {
                     if (!isMbcs || c < 0x80 || i + 1 >= offset + length) {
-                        ret.append(languageTableToChar.charAt(c));
+                        if (c < languageTableToChar.length()) {
+                            ret.append(languageTableToChar.charAt(c));
+                        } else {
+                            ret.append(' ');
+                        }
                     } else {
                         // isMbcs must be true. So both mbcsBuffer and charset are initialized.
                         mbcsBuffer.clear();
diff --git a/telephony/java/com/android/internal/telephony/IMms.aidl b/telephony/java/com/android/internal/telephony/IMms.aidl
index cbcef25..ebfefd1 100644
--- a/telephony/java/com/android/internal/telephony/IMms.aidl
+++ b/telephony/java/com/android/internal/telephony/IMms.aidl
@@ -19,6 +19,7 @@
 import android.app.PendingIntent;
 import android.content.ContentValues;
 import android.net.Uri;
+import android.os.Bundle;
 
 /**
  * Service interface to handle MMS API requests
@@ -29,7 +30,8 @@
      *
      * @param subId the SIM id
      * @param callingPkg the package name of the calling app
-     * @param pdu the MMS message encoded in standard MMS PDU format
+     * @param contentUri the content uri from which to read MMS message encoded in standard MMS
+     *  PDU format
      * @param locationUrl the optional location url for where this message should be sent to
      * @param configOverrides the carrier-specific messaging configuration values to override for
      *  sending the message. See {@link android.telephony.MessagingConfigurationManager} for the
@@ -37,8 +39,8 @@
      * @param sentIntent if not NULL this <code>PendingIntent</code> is
      *  broadcast when the message is successfully sent, or failed
      */
-    void sendMessage(long subId, String callingPkg, in byte[] pdu, String locationUrl,
-            in ContentValues configOverrides, in PendingIntent sentIntent);
+    void sendMessage(long subId, String callingPkg, in Uri contentUri,
+            String locationUrl, in Bundle configOverrides, in PendingIntent sentIntent);
 
     /**
      * Download an MMS message using known location and transaction id
@@ -47,6 +49,7 @@
      * @param callingPkg the package name of the calling app
      * @param locationUrl the location URL of the MMS message to be downloaded, usually obtained
      *  from the MMS WAP push notification
+     * @param contentUri a contentUri to which the downloaded MMS message will be written
      * @param configOverrides the carrier-specific messaging configuration values to override for
      *  downloading the message. See {@link android.telephony.MessagingConfigurationManager} for the
      *  value names and types.
@@ -54,57 +57,49 @@
      *  broadcast when the message is downloaded, or the download is failed
      */
     void downloadMessage(long subId, String callingPkg, String locationUrl,
-            in ContentValues configOverrides, in PendingIntent downloadedIntent);
+            in Uri contentUri, in Bundle configOverrides,
+            in PendingIntent downloadedIntent);
 
     /**
      * Update the status of a pending (send-by-IP) MMS message handled by the carrier app.
-     * If the carrier app fails to send this message, it would be resent via carrier network.
+     * If the carrier app fails to send this message, it may be resent via carrier network
+     * depending on the status code.
+     *
+     * The caller should have carrier privileges.
+     * @see android.telephony.TelephonyManager.hasCarrierPrivileges
      *
      * @param messageRef the reference number of the MMS message.
-     * @param success True if and only if the message was sent successfully. If its value is
-     *  false, this message should be resent via carrier network
+     * @param pdu non-empty (contains the SendConf PDU) if the message was sent successfully,
+     *   otherwise, this param should be null.
+     * @param status send status. It can be Activity.RESULT_OK or one of the MMS error codes.
+     *   If status is Activity.RESULT_OK, the MMS was sent successfully.
+     *   If status is MMS_ERROR_RETRY, this message would be resent via carrier
+     *   network. The message will not be resent for other MMS error statuses.
      */
-    void updateMmsSendStatus(int messageRef, boolean success);
+    void updateMmsSendStatus(int messageRef, in byte[] pdu, in int status);
 
     /**
      * Update the status of a pending (download-by-IP) MMS message handled by the carrier app.
-     * If the carrier app fails to download this message, it would be re-downloaded via carrier
-     * network.
+     * If the carrier app fails to download this message, it may be re-downloaded via carrier
+     * network depending on the status code.
+     *
+     * The caller should have carrier privileges.
+     * @see android.telephony.TelephonyManager.hasCarrierPrivileges
      *
      * @param messageRef the reference number of the MMS message.
-     * @param pdu non-empty if downloaded successfully, otherwise, it is empty and the message
-     *  will be downloaded via carrier network
+     * @param status download status.  It can be Activity.RESULT_OK or one of the MMS error codes.
+     *   If status is Activity.RESULT_OK, the MMS was downloaded successfully.
+     *   If status is MMS_ERROR_RETRY, this message would be re-downloaded via carrier
+     *   network. The message will not be re-downloaded for other MMS error statuses.
      */
-    void updateMmsDownloadStatus(int messageRef, in byte[] pdu);
+    void updateMmsDownloadStatus(int messageRef, in int status);
 
     /**
-     * Get carrier-dependent configuration value as boolean. For example, if multipart SMS
-     * is supported.
+     * Get carrier-dependent configuration values.
      *
      * @param subId the SIM id
-     * @param name the configuration name
-     * @param defaultValue the default value if fail to find the name
      */
-    boolean getCarrierConfigBoolean(long subId, String name, boolean defaultValue);
-
-    /**
-     * Get carrier-dependent configuration value as int. For example, the MMS message size limit.
-     *
-     * @param subId the SIM id
-     * @param name the configuration name
-     * @param defaultValue the default value if fail to find the name
-     */
-    int getCarrierConfigInt(long subId, String name, int defaultValue);
-
-    /**
-     * Get carrier-dependent configuration value as String. For example, extra HTTP headers for
-     * MMS request.
-     *
-     * @param subId the SIM id
-     * @param name the configuration name
-     * @param defaultValue the default value if fail to find the name
-     */
-    String getCarrierConfigString(long subId, String name, String defaultValue);
+    Bundle getCarrierConfigValues(long subId);
 
     /**
      * Import a text message into system's SMS store
@@ -125,14 +120,14 @@
       * Import a multimedia message into system's MMS store
       *
       * @param callingPkg the package name of the calling app
-      * @param pdu the PDU of the message to import
+      * @param contentUri the content uri from which to read PDU of the message to import
       * @param messageId the optional message id
       * @param timestampSecs the message timestamp in seconds
       * @param seen if the message is seen
       * @param read if the message is read
       * @return the message URI, null if failed
       */
-    Uri importMultimediaMessage(String callingPkg, in byte[] pdu, String messageId,
+    Uri importMultimediaMessage(String callingPkg, in Uri contentUri, String messageId,
             long timestampSecs, boolean seen, boolean read);
 
     /**
@@ -189,10 +184,10 @@
      * Add a multimedia message draft to system MMS store
      *
      * @param callingPkg the package name of the calling app
-     * @param pdu the PDU data of the draft MMS
+     * @param contentUri the content Uri from which to read PDU data of the draft MMS
      * @return the URI of the stored draft message
      */
-    Uri addMultimediaMessageDraft(String callingPkg, in byte[] pdu);
+    Uri addMultimediaMessageDraft(String callingPkg, in Uri contentUri);
 
     /**
      * Send a system stored MMS message
@@ -210,7 +205,7 @@
      *  broadcast when the message is successfully sent, or failed
      */
     void sendStoredMessage(long subId, String callingPkg, in Uri messageUri,
-            in ContentValues configOverrides, in PendingIntent sentIntent);
+            in Bundle configOverrides, in PendingIntent sentIntent);
 
     /**
      * Turns on/off the flag to automatically write sent/received SMS/MMS messages into system
diff --git a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
index 4734965..c203442 100644
--- a/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
+++ b/telephony/java/com/android/internal/telephony/IPhoneSubInfo.aidl
@@ -31,8 +31,12 @@
      * Retrieves the unique device ID of a subId for the device, e.g., IMEI
      * for GSM phones.
      */
-    String getDeviceIdUsingSubId(long subId);
+    String getDeviceIdForSubscriber(long subId);
 
+    /**
+     * Retrieves the IMEI.
+     */
+    String getImeiForSubscriber(long subId);
 
     /**
      * Retrieves the software version number for the device, e.g., IMEI/SV
@@ -48,7 +52,7 @@
     /**
      * Retrieves the unique subscriber ID of a given subId, e.g., IMSI for GSM phones.
      */
-    String getSubscriberIdUsingSubId(long subId);
+    String getSubscriberIdForSubscriber(long subId);
 
     /**
      * Retrieves the Group Identifier Level1 for GSM phones.
@@ -58,7 +62,7 @@
     /**
      * Retrieves the Group Identifier Level1 for GSM phones of a subId.
      */
-    String getGroupIdLevel1UsingSubId(long subId);
+    String getGroupIdLevel1ForSubscriber(long subId);
 
     /**
      * Retrieves the serial number of the ICC, if applicable.
@@ -68,7 +72,7 @@
     /**
      * Retrieves the serial number of a given subId.
      */
-    String getIccSerialNumberUsingSubId(long subId);
+    String getIccSerialNumberForSubscriber(long subId);
 
     /**
      * Retrieves the phone number string for line 1.
@@ -78,7 +82,7 @@
     /**
      * Retrieves the phone number string for line 1 of a subcription.
      */
-    String getLine1NumberUsingSubId(long subId);
+    String getLine1NumberForSubscriber(long subId);
 
 
     /**
@@ -89,7 +93,7 @@
     /**
      * Retrieves the alpha identifier for line 1 of a subId.
      */
-    String getLine1AlphaTagUsingSubId(long subId);
+    String getLine1AlphaTagForSubscriber(long subId);
 
 
     /**
@@ -100,7 +104,7 @@
     /**
      * Retrieves the Msisdn of a subId.
      */
-    String getMsisdnUsingSubId(long subId);
+    String getMsisdnForSubscriber(long subId);
 
     /**
      * Retrieves the voice mail number.
@@ -110,7 +114,7 @@
     /**
      * Retrieves the voice mail number of a given subId.
      */
-    String getVoiceMailNumberUsingSubId(long subId);
+    String getVoiceMailNumberForSubscriber(long subId);
 
     /**
      * Retrieves the complete voice mail number.
@@ -120,7 +124,7 @@
     /**
      * Retrieves the complete voice mail number for particular subId
      */
-    String getCompleteVoiceMailNumberUsingSubId(long subId);
+    String getCompleteVoiceMailNumberForSubscriber(long subId);
 
     /**
      * Retrieves the alpha identifier associated with the voice mail number.
@@ -131,7 +135,7 @@
      * Retrieves the alpha identifier associated with the voice mail number
      * of a subId.
      */
-    String getVoiceMailAlphaTagUsingSubId(long subId);
+    String getVoiceMailAlphaTagForSubscriber(long subId);
 
     /**
      * Returns the IMS private user identity (IMPI) that was loaded from the ISIM.
diff --git a/telephony/java/com/android/internal/telephony/ISms.aidl b/telephony/java/com/android/internal/telephony/ISms.aidl
index abbdc4a..32bb8b4 100644
--- a/telephony/java/com/android/internal/telephony/ISms.aidl
+++ b/telephony/java/com/android/internal/telephony/ISms.aidl
@@ -47,7 +47,7 @@
      * @param subId the subId id.
      * @return list of SmsRawData of all sms on ICC
      */
-    List<SmsRawData> getAllMessagesFromIccEfUsingSubId(in long subId, String callingPkg);
+    List<SmsRawData> getAllMessagesFromIccEfForSubscriber(in long subId, String callingPkg);
 
     /**
      * Update the specified message on the ICC.
@@ -75,7 +75,7 @@
      * @return success or not
      *
      */
-     boolean updateMessageOnIccEfUsingSubId(in long subId, String callingPkg,
+     boolean updateMessageOnIccEfForSubscriber(in long subId, String callingPkg,
              int messageIndex, int newStatus, in byte[] pdu);
 
     /**
@@ -99,7 +99,7 @@
      * @return success or not
      *
      */
-    boolean copyMessageToIccEfUsingSubId(in long subId, String callingPkg, int status,
+    boolean copyMessageToIccEfForSubscriber(in long subId, String callingPkg, int status,
             in byte[] pdu, in byte[] smsc);
 
     /**
@@ -152,7 +152,7 @@
      *  raw pdu of the status report is in the extended data ("pdu").
      * @param subId the subId id.
      */
-    void sendDataUsingSubId(long subId, String callingPkg, in String destAddr,
+    void sendDataForSubscriber(long subId, String callingPkg, in String destAddr,
             in String scAddr, in int destPort, in byte[] data, in PendingIntent sentIntent,
             in PendingIntent deliveryIntent);
 
@@ -206,7 +206,7 @@
      *  raw pdu of the status report is in the extended data ("pdu").
      * @param subId the subId on which the SMS has to be sent.
      */
-    void sendTextUsingSubId(in long subId, String callingPkg, in String destAddr,
+    void sendTextForSubscriber(in long subId, String callingPkg, in String destAddr,
             in String scAddr, in String text, in PendingIntent sentIntent,
             in PendingIntent deliveryIntent);
 
@@ -283,7 +283,7 @@
      *   extended data ("pdu").
      * @param subId the subId on which the SMS has to be sent.
      */
-    void sendMultipartTextUsingSubId(in long subId, String callingPkg,
+    void sendMultipartTextForSubscriber(in long subId, String callingPkg,
             in String destinationAddress, in String scAddress,
             in List<String> parts, in List<PendingIntent> sentIntents,
             in List<PendingIntent> deliveryIntents);
@@ -315,7 +315,7 @@
      *
      * @see #disableCellBroadcast(int)
      */
-    boolean enableCellBroadcastUsingSubId(in long subId, int messageIdentifier);
+    boolean enableCellBroadcastForSubscriber(in long subId, int messageIdentifier);
 
     /**
      * Disable reception of cell broadcast (SMS-CB) messages with the given
@@ -344,7 +344,7 @@
      *
      * @see #enableCellBroadcast(int)
      */
-    boolean disableCellBroadcastUsingSubId(in long subId, int messageIdentifier);
+    boolean disableCellBroadcastForSubscriber(in long subId, int messageIdentifier);
 
     /*
      * Enable reception of cell broadcast (SMS-CB) messages with the given
@@ -377,7 +377,7 @@
      *
      * @see #disableCellBroadcastRange(int, int)
      */
-    boolean enableCellBroadcastRangeUsingSubId(long subId, int startMessageId, int endMessageId);
+    boolean enableCellBroadcastRangeForSubscriber(long subId, int startMessageId, int endMessageId);
 
     /**
      * Disable reception of cell broadcast (SMS-CB) messages with the given
@@ -410,7 +410,7 @@
      *
      * @see #enableCellBroadcastRange(int, int, int)
      */
-    boolean disableCellBroadcastRangeUsingSubId(long subId, int startMessageId,
+    boolean disableCellBroadcastRangeForSubscriber(long subId, int startMessageId,
             int endMessageId);
 
     /**
@@ -423,7 +423,7 @@
      * Returns the premium SMS send permission for the specified package.
      * Requires system permission.
      */
-    int getPremiumSmsPermissionUsingSubId(long subId, String packageName);
+    int getPremiumSmsPermissionForSubscriber(long subId, String packageName);
 
     /**
      * Set the SMS send permission for the specified package.
@@ -439,7 +439,7 @@
      * Set the SMS send permission for the specified package.
      * Requires system permission.
      */
-    void setPremiumSmsPermissionUsingSubId(long subId, String packageName, int permission);
+    void setPremiumSmsPermissionForSubscriber(long subId, String packageName, int permission);
 
     /**
      * SMS over IMS is supported if IMS is registered and SMS is supported
@@ -459,7 +459,7 @@
      *
      * @see #getImsSmsFormat()
      */
-    boolean isImsSmsSupportedUsingSubId(long subId);
+    boolean isImsSmsSupportedForSubscriber(long subId);
 
     /*
      * get user prefered SMS subId
@@ -489,7 +489,7 @@
      *
      * @see #isImsSmsSupported()
      */
-    String getImsSmsFormatUsingSubId(long subId);
+    String getImsSmsFormatForSubscriber(long subId);
 
     /*
      * Get SMS prompt property,  enabled or not
diff --git a/telephony/java/com/android/internal/telephony/ISub.aidl b/telephony/java/com/android/internal/telephony/ISub.aidl
index 6021ccf..b87365e 100755
--- a/telephony/java/com/android/internal/telephony/ISub.aidl
+++ b/telephony/java/com/android/internal/telephony/ISub.aidl
@@ -1,18 +1,18 @@
 /*
-* Copyright (C) 2011-2014 MediaTek Inc.
-*
-* 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.
-*/
+ * Copyright (C) 2014 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.internal.telephony;
 
@@ -22,15 +22,13 @@
 interface ISub {
     /**
      * Get the SubInfoRecord according to an index
-     * @param context Context provided by caller
      * @param subId The unique SubInfoRecord index in database
      * @return SubInfoRecord, maybe null
      */
-    SubInfoRecord getSubInfoUsingSubId(long subId);
+    SubInfoRecord getSubInfoForSubscriber(long subId);
 
     /**
      * Get the SubInfoRecord according to an IccId
-     * @param context Context provided by caller
      * @param iccId the IccId of SIM card
      * @return SubInfoRecord, maybe null
      */
@@ -38,7 +36,6 @@
 
     /**
      * Get the SubInfoRecord according to slotId
-     * @param context Context provided by caller
      * @param slotId the slot which the SIM is inserted
      * @return SubInfoRecord, maybe null
      */
@@ -46,28 +43,30 @@
 
     /**
      * Get all the SubInfoRecord(s) in subinfo database
-     * @param context Context provided by caller
      * @return Array list of all SubInfoRecords in database, include thsoe that were inserted before
      */
     List<SubInfoRecord> getAllSubInfoList();
 
     /**
      * Get the SubInfoRecord(s) of the currently inserted SIM(s)
-     * @param context Context provided by caller
      * @return Array list of currently inserted SubInfoRecord(s)
      */
-    List<SubInfoRecord> getActivatedSubInfoList();
+    List<SubInfoRecord> getActiveSubInfoList();
 
     /**
      * Get the SUB count of all SUB(s) in subinfo database
-     * @param context Context provided by caller
      * @return all SIM count in database, include what was inserted before
      */
     int getAllSubInfoCount();
 
     /**
+     * Get the count of active SUB(s)
+     * @return active SIM count
+     */
+    int getActiveSubInfoCount();
+
+    /**
      * Add a new SubInfoRecord to subinfo database if needed
-     * @param context Context provided by caller
      * @param iccId the IccId of the SIM card
      * @param slotId the slot which the SIM is inserted
      * @return the URL of the newly created row or the updated row
@@ -76,7 +75,6 @@
 
     /**
      * Set SIM color by simInfo index
-     * @param context Context provided by caller
      * @param color the color of the SIM
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
@@ -85,7 +83,6 @@
 
     /**
      * Set display name by simInfo index
-     * @param context Context provided by caller
      * @param displayName the display name of SIM card
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
@@ -94,7 +91,6 @@
 
     /**
      * Set display name by simInfo index with name source
-     * @param context Context provided by caller
      * @param displayName the display name of SIM card
      * @param subId the unique SubInfoRecord index in database
      * @param nameSource, 0: DEFAULT_SOURCE, 1: SIM_SOURCE, 2: USER_INPUT
@@ -104,16 +100,14 @@
 
     /**
      * Set phone number by subId
-     * @param context Context provided by caller
      * @param number the phone number of the SIM
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
      */
-    int setDispalyNumber(String number, long subId);
+    int setDisplayNumber(String number, long subId);
 
     /**
      * Set number display format. 0: none, 1: the first four digits, 2: the last four digits
-     * @param context Context provided by caller
      * @param format the display format of phone number
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
@@ -122,7 +116,6 @@
 
     /**
      * Set data roaming by simInfo index
-     * @param context Context provided by caller
      * @param roaming 0:Don't allow data when roaming, 1:Allow data when roaming
      * @param subId the unique SubInfoRecord index in database
      * @return the number of records updated
@@ -150,4 +143,12 @@
     long getDefaultVoiceSubId();
 
     void setDefaultVoiceSubId(long subId);
+
+    long getDefaultSmsSubId();
+
+    void setDefaultSmsSubId(long subId);
+
+    void clearDefaultsForInactiveSubIds();
+
+    long[] getActiveSubIdList();
 }
diff --git a/telephony/java/com/android/internal/telephony/ITelephony.aidl b/telephony/java/com/android/internal/telephony/ITelephony.aidl
index d256f9d..0868f41 100644
--- a/telephony/java/com/android/internal/telephony/ITelephony.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephony.aidl
@@ -59,7 +59,7 @@
      * @param subId user preferred subId.
      * @return whether it hung up
      */
-    boolean endCallUsingSubId(long subId);
+    boolean endCallForSubscriber(long subId);
 
     /**
      * Answer the currently-ringing call.
@@ -103,7 +103,7 @@
      * @param subId user preferred subId.
      * @return true if the phone state is OFFHOOK.
      */
-    boolean isOffhookUsingSubId(long subId);
+    boolean isOffhookForSubscriber(long subId);
 
     /**
      * Check if an incoming phone call is ringing or call waiting
@@ -112,7 +112,7 @@
      * @param subId user preferred subId.
      * @return true if the phone state is RINGING.
      */
-    boolean isRingingUsingSubId(long subId);
+    boolean isRingingForSubscriber(long subId);
 
     /**
      * Check if an incoming phone call is ringing or call waiting.
@@ -132,7 +132,7 @@
      * @param subId user preferred subId.
      * @return true if the phone state is IDLE.
      */
-    boolean isIdleUsingSubId(long subId);
+    boolean isIdleForSubscriber(long subId);
 
     /**
      * Check to see if the radio is on or not.
@@ -145,7 +145,7 @@
      * @param subId user preferred subId.
      * @return returns true if the radio is on.
      */
-    boolean isRadioOnUsingSubId(long subId);
+    boolean isRadioOnForSubscriber(long subId);
 
     /**
      * Check if the SIM pin lock is enabled.
@@ -167,7 +167,7 @@
      * @param subId user preferred subId.
      * @return whether the operation was a success.
      */
-    boolean supplyPinUsingSubId(long subId, String pin);
+    boolean supplyPinForSubscriber(long subId, String pin);
 
     /**
      * Supply puk to unlock the SIM and set SIM pin to new pin.
@@ -186,7 +186,7 @@
      * @param subId user preferred subId.
      * @return whether the operation was a success.
      */
-    boolean supplyPukUsingSubId(long subId, String puk, String pin);
+    boolean supplyPukForSubscriber(long subId, String puk, String pin);
 
     /**
      * Supply a pin to unlock the SIM.  Blocks until a result is determined.
@@ -204,7 +204,7 @@
      * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code
      *         retValue[1] = number of attempts remaining if known otherwise -1
      */
-    int[] supplyPinReportResultUsingSubId(long subId, String pin);
+    int[] supplyPinReportResultForSubscriber(long subId, String pin);
 
     /**
      * Supply puk to unlock the SIM and set SIM pin to new pin.
@@ -226,7 +226,7 @@
      * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code
      *         retValue[1] = number of attempts remaining if known otherwise -1
      */
-    int[] supplyPukReportResultUsingSubId(long subId, String puk, String pin);
+    int[] supplyPukReportResultForSubscriber(long subId, String puk, String pin);
 
     /**
      * Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated
@@ -245,7 +245,7 @@
      * @param subId user preferred subId.
      * @return true if MMI command is executed.
      */
-    boolean handlePinMmiUsingSubId(long subId, String dialString);
+    boolean handlePinMmiForSubscriber(long subId, String dialString);
 
     /**
      * Toggles the radio on or off.
@@ -256,7 +256,7 @@
      * Toggles the radio on or off on particular subId.
      * @param subId user preferred subId.
      */
-    void toggleRadioOnOffUsingSubId(long subId);
+    void toggleRadioOnOffForSubscriber(long subId);
 
     /**
      * Set the radio to on or off
@@ -267,7 +267,7 @@
      * Set the radio to on or off on particular subId.
      * @param subId user preferred subId.
      */
-    boolean setRadioUsingSubId(long subId, boolean turnOn);
+    boolean setRadioForSubscriber(long subId, boolean turnOn);
 
     /**
      * Set the radio to on or off unconditionally
@@ -283,7 +283,7 @@
      * Request to update location information for a subscrition in service state
      * @param subId user preferred subId.
      */
-    void updateServiceLocationUsingSubId(long subId);
+    void updateServiceLocationForSubscriber(long subId);
 
     /**
      * Enable location update notifications.
@@ -294,7 +294,7 @@
      * Enable location update notifications.
      * @param subId user preferred subId.
      */
-    void enableLocationUpdatesUsingSubId(long subId);
+    void enableLocationUpdatesForSubscriber(long subId);
 
     /**
      * Disable location update notifications.
@@ -305,7 +305,7 @@
      * Disable location update notifications.
      * @param subId user preferred subId.
      */
-    void disableLocationUpdatesUsingSubId(long subId);
+    void disableLocationUpdatesForSubscriber(long subId);
 
     /**
      * Allow mobile data connections.
@@ -334,7 +334,7 @@
     /**
      * Returns the call state for a subId.
      */
-     int getCallStateUsingSubId(long subId);
+     int getCallStateForSubscriber(long subId);
 
      int getDataActivity();
      int getDataState();
@@ -352,7 +352,7 @@
      * and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE
      * @param subId user preferred subId.
      */
-    int getActivePhoneTypeUsingSubId(long subId);
+    int getActivePhoneTypeForSubscriber(long subId);
 
     /**
      * Returns the CDMA ERI icon index to display
@@ -363,7 +363,7 @@
      * Returns the CDMA ERI icon index to display on particular subId.
      * @param subId user preferred subId.
      */
-    int getCdmaEriIconIndexUsingSubId(long subId);
+    int getCdmaEriIconIndexForSubscriber(long subId);
 
     /**
      * Returns the CDMA ERI icon mode,
@@ -378,7 +378,7 @@
      * 1 - FLASHING
      * @param subId user preferred subId.
      */
-    int getCdmaEriIconModeUsingSubId(long subId);
+    int getCdmaEriIconModeForSubscriber(long subId);
 
     /**
      * Returns the CDMA ERI text,
@@ -389,7 +389,7 @@
      * Returns the CDMA ERI text for particular subId,
      * @param subId user preferred subId.
      */
-    String getCdmaEriTextUsingSubId(long subId);
+    String getCdmaEriTextForSubscriber(long subId);
 
     /**
      * Returns true if OTA service provisioning needs to run.
@@ -408,7 +408,7 @@
      * @param subId user preferred subId.
      * Returns the unread count of voicemails
      */
-    int getVoiceMessageCountUsingSubId(long subId);
+    int getVoiceMessageCountForSubscriber(long subId);
 
     /**
       * Returns the network type for data transmission
@@ -420,7 +420,7 @@
      * @param subId user preferred subId.
      * Returns the network type
      */
-    int getNetworkTypeUsingSubId(long subId);
+    int getNetworkTypeForSubscriber(long subId);
 
     /**
       * Returns the network type for data transmission
@@ -432,7 +432,7 @@
       * @param subId user preferred subId.
       * Returns the network type
       */
-    int getDataNetworkTypeUsingSubId(long subId);
+    int getDataNetworkTypeForSubscriber(long subId);
 
     /**
       * Returns the network type for voice
@@ -444,7 +444,7 @@
       * @param subId user preferred subId.
       * Returns the network type
       */
-    int getVoiceNetworkTypeUsingSubId(long subId);
+    int getVoiceNetworkTypeForSubscriber(long subId);
 
     /**
      * Return true if an ICC card is present
@@ -476,7 +476,7 @@
      * @return {@link Phone#LTE_ON_CDMA_UNKNOWN}, {@link Phone#LTE_ON_CDMA_FALSE}
      * or {@link PHone#LTE_ON_CDMA_TRUE}
      */
-    int getLteOnCdmaModeUsingSubId(long subId);
+    int getLteOnCdmaModeForSubscriber(long subId);
 
     /**
      * Returns the all observed cell information of the device.
@@ -643,15 +643,6 @@
     boolean setPreferredNetworkType(int networkType);
 
     /**
-     * Set the CDMA subscription source.
-     * Used for device supporting both NV and RUIM for CDMA.
-     *
-     * @param subscriptionType the subscription type, 0 for RUIM, 1 for NV.
-     * @return true on success; false on any failure.
-     */
-    boolean setCdmaSubscription(int subscriptionType);
-
-    /**
      * User enable/disable Mobile Data.
      *
      * @param enable true to turn on, else false
@@ -677,6 +668,18 @@
     void setImsRegistrationState(boolean registered);
 
     /**
+     * Return MDN string for CDMA phone.
+     * @param subId user preferred subId.
+     */
+    String getCdmaMdn(long subId);
+
+    /**
+     * Return MIN string for CDMA phone.
+     * @param subId user preferred subId.
+     */
+    String getCdmaMin(long subId);
+
+    /**
      * Has the calling application been granted special privileges by the carrier.
      *
      * If any of the packages in the calling UID has carrier privileges, the
@@ -698,41 +701,42 @@
      * Returns the package name of the carrier apps that should handle the input intent.
      *
      * @param packageManager PackageManager for getting receivers.
-     * @param intent Intent that will be broadcast.
+     * @param intent Intent that will be sent.
      * @return list of carrier app package names that can handle the intent.
      *         Returns null if there is an error and an empty list if there
      *         are no matching packages.
      */
-    List<String> getCarrierPackageNamesForBroadcastIntent(in Intent intent);
+    List<String> getCarrierPackageNamesForIntent(in Intent intent);
 
     /**
-     * Set whether Android should display a simplified Mobile Network Settings UI.
-     * The setting won't be persisted during power cycle.
+     * Set whether Android should display a simplified Mobile Network Settings UI
+     * for the current ICCID.
      *
      * @param subId for which the simplified UI should be enabled or disabled.
      * @param enable true means enabling the simplified UI.
      */
-    void enableSimplifiedNetworkSettings(long subId, boolean enable);
+    void enableSimplifiedNetworkSettingsForSubscriber(long subId, boolean enable);
 
     /**
-     * Get whether a simplified Mobile Network Settings UI is enabled.
+     * Get whether a simplified Mobile Network Settings UI is enabled for the
+     * current ICCID.
      *
      * @param subId for which the simplified UI should be enabled or disabled.
      * @return true if the simplified UI is enabled.
      */
-    boolean getSimplifiedNetworkSettingsEnabled(long subId);
+    boolean getSimplifiedNetworkSettingsEnabledForSubscriber(long subId);
 
     /**
-     * Set the phone number string and its alphatag for line 1 for display
-     * purpose only, for example, displayed in Phone Status. It won't change
-     * the actual MSISDN/MDN. This setting won't be persisted during power cycle
-     * and it should be set again after reboot.
+     * Set the line 1 phone number string and its alphatag for the current ICCID
+     * for display purpose only, for example, displayed in Phone Status. It won't
+     * change the actual MSISDN/MDN. To unset alphatag or number, pass in a null
+     * value.
      *
      * @param subId the subscriber that the alphatag and dialing number belongs to.
      * @param alphaTag alpha-tagging of the dailing nubmer
      * @param number The dialing number
      */
-    void setLine1NumberForDisplay(long subId, String alphaTag, String number);
+    void setLine1NumberForDisplayForSubscriber(long subId, String alphaTag, String number);
 
     /**
      * Returns the displayed dialing number string if it was set previously via
@@ -754,9 +758,9 @@
     String getLine1AlphaTagForDisplay(long subId);
 
     /**
-     * Override the operator branding for the input ICCID.
+     * Override the operator branding for the current ICCID.
      *
-     * Once set, whenever the ICCID is inserted into the device, the service
+     * Once set, whenever the SIM is present in the device, the service
      * provider name (SPN) and the operator name will both be replaced by the
      * brand value input. To unset the value, the same function should be
      * called with a null brand value.
@@ -765,11 +769,10 @@
      *   {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}
      *  or has to be carrier app - see #hasCarrierPrivileges.
      *
-     * @param iccid The ICCID of that the branding applies to.
      * @param brand The brand name to display/set.
      * @return true if the operation was executed correctly.
      */
-    boolean setOperatorBrandOverride(String iccId, String brand);
+    boolean setOperatorBrandOverride(String brand);
 
     /**
      * Returns the result and response from RIL for oem request
@@ -781,5 +784,16 @@
      *         positive value success, data length of response
      */
     int invokeOemRilRequestRaw(in byte[] oemReq, out byte[] oemResp);
-}
 
+    /**
+     * Check if any mobile Radios need to be shutdown.
+     *
+     * @return true is any mobile radio needs to be shutdown
+     */
+    boolean needMobileRadioShutdown();
+
+    /**
+     * Shutdown Mobile Radios
+     */
+    void shutdownMobileRadios();
+}
diff --git a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
index fd2d1c7..d776833 100644
--- a/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
+++ b/telephony/java/com/android/internal/telephony/ITelephonyRegistry.aidl
@@ -30,30 +30,30 @@
 
 interface ITelephonyRegistry {
     void listen(String pkg, IPhoneStateListener callback, int events, boolean notifyNow);
-    void listenUsingSubId(in long subId, String pkg, IPhoneStateListener callback, int events,
+    void listenForSubscriber(in long subId, String pkg, IPhoneStateListener callback, int events,
             boolean notifyNow);
     void notifyCallState(int state, String incomingNumber);
-    void notifyCallStateUsingSubId(in long subId, int state, String incomingNumber);
+    void notifyCallStateForSubscriber(in long subId, int state, String incomingNumber);
     void notifyServiceState(in ServiceState state);
-    void notifyServiceStateUsingSubId(in long subId, in ServiceState state);
+    void notifyServiceStateForSubscriber(in long subId, in ServiceState state);
     void notifySignalStrength(in SignalStrength signalStrength);
-    void notifySignalStrengthUsingSubId(in long subId, in SignalStrength signalStrength);
+    void notifySignalStrengthForSubscriber(in long subId, in SignalStrength signalStrength);
     void notifyMessageWaitingChanged(boolean mwi);
-    void notifyMessageWaitingChangedUsingSubId(in long subId, boolean mwi);
+    void notifyMessageWaitingChangedForSubscriber(in long subId, boolean mwi);
     void notifyCallForwardingChanged(boolean cfi);
-    void notifyCallForwardingChangedUsingSubId(in long subId, boolean cfi);
+    void notifyCallForwardingChangedForSubscriber(in long subId, boolean cfi);
     void notifyDataActivity(int state);
-    void notifyDataActivityUsingSubId(in long subId, int state);
+    void notifyDataActivityForSubscriber(in long subId, int state);
     void notifyDataConnection(int state, boolean isDataConnectivityPossible,
             String reason, String apn, String apnType, in LinkProperties linkProperties,
             in NetworkCapabilities networkCapabilities, int networkType, boolean roaming);
-    void notifyDataConnectionUsingSubId(long subId, int state, boolean isDataConnectivityPossible,
+    void notifyDataConnectionForSubscriber(long subId, int state, boolean isDataConnectivityPossible,
             String reason, String apn, String apnType, in LinkProperties linkProperties,
             in NetworkCapabilities networkCapabilities, int networkType, boolean roaming);
     void notifyDataConnectionFailed(String reason, String apnType);
-    void notifyDataConnectionFailedUsingSubId(long subId, String reason, String apnType);
+    void notifyDataConnectionFailedForSubscriber(long subId, String reason, String apnType);
     void notifyCellLocation(in Bundle cellLocation);
-    void notifyCellLocationUsingSubId(in long subId, in Bundle cellLocation);
+    void notifyCellLocationForSubscriber(in long subId, in Bundle cellLocation);
     void notifyOtaspChanged(in int otaspMode);
     void notifyCellInfo(in List<CellInfo> cellInfo);
     void notifyPreciseCallState(int ringingCallState, int foregroundCallState,
@@ -61,7 +61,7 @@
     void notifyDisconnectCause(int disconnectCause, int preciseDisconnectCause);
     void notifyPreciseDataConnectionFailed(String reason, String apnType, String apn,
             String failCause);
-    void notifyCellInfoUsingSubId(in long subId, in List<CellInfo> cellInfo);
+    void notifyCellInfoForSubscriber(in long subId, in List<CellInfo> cellInfo);
     void notifyDataConnectionRealTimeInfo(in DataConnectionRealTimeInfo dcRtInfo);
     void notifyVoLteServiceStateChanged(in VoLteServiceState lteState);
 }
diff --git a/telephony/java/com/android/internal/telephony/PhoneConstants.java b/telephony/java/com/android/internal/telephony/PhoneConstants.java
index b4b1ea5..62b5596 100644
--- a/telephony/java/com/android/internal/telephony/PhoneConstants.java
+++ b/telephony/java/com/android/internal/telephony/PhoneConstants.java
@@ -136,14 +136,6 @@
     /** APN type for IA Emergency PDN */
     public static final String APN_TYPE_EMERGENCY = "emergency";
 
-    // FIXME: This looks to be used as default phoneId, rename
-    // or use SubscriptionManager.DEFAULT_SUB_ID
-    public static final int DEFAULT_SUBSCRIPTION = 0;
-
-    // FIXME: This looks to be used as invalid phoneId, rename
-    // or use SubscriptionManager.INVALID_SUB_ID
-    public static final int INVALID_SUBSCRIPTION = -1;
-
     public static final int RIL_CARD_MAX_APPS    = 8;
 
     public static final int DEFAULT_CARD_INDEX   = 0;
@@ -154,10 +146,14 @@
 
     public static final int MAX_PHONE_COUNT_TRI_SIM = 3;
 
-    public static final String SUBSCRIPTION_KEY  = "subscription";
+    public static final String PHONE_KEY = "phone";
 
     public static final String SLOT_KEY  = "slot";
 
+    // FIXME: This is used to pass a subId via intents, we need to look at its usage, which is
+    // FIXME: extensive, and see if this should be an array of all active subId's or ...?
+    public static final String SUBSCRIPTION_KEY  = "subscription";
+
     public static final String SUB_SETTING  = "subSettings";
 
     public static final int SUB1 = 0;
diff --git a/telephony/java/com/android/internal/telephony/RILConstants.java b/telephony/java/com/android/internal/telephony/RILConstants.java
index a8a9057..e730bde 100644
--- a/telephony/java/com/android/internal/telephony/RILConstants.java
+++ b/telephony/java/com/android/internal/telephony/RILConstants.java
@@ -287,7 +287,10 @@
     int RIL_REQUEST_ALLOW_DATA = 123;
     int RIL_REQUEST_GET_HARDWARE_CONFIG = 124;
     int RIL_REQUEST_SIM_AUTHENTICATION = 125;
+    int RIL_REQUEST_GET_DC_RT_INFO = 126;
+    int RIL_REQUEST_SET_DC_RT_INFO_RATE = 127;
     int RIL_REQUEST_SET_DATA_PROFILE = 128;
+    int RIL_REQUEST_SHUTDOWN = 129;
 
     int RIL_UNSOL_RESPONSE_BASE = 1000;
     int RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED = 1000;
diff --git a/telephony/java/com/android/internal/telephony/TelephonyIntents.java b/telephony/java/com/android/internal/telephony/TelephonyIntents.java
index 5954947..e7aca90 100644
--- a/telephony/java/com/android/internal/telephony/TelephonyIntents.java
+++ b/telephony/java/com/android/internal/telephony/TelephonyIntents.java
@@ -266,7 +266,7 @@
 
     /**
      * Activity Action: Start this activity to invoke the carrier setup app.
-     * To filter the intent, see {@link #CATEGORY_MCCMNC_PREFIX}.
+     * The carrier app must be signed using a certificate that matches the UICC access rules.
      *
      * <p class="note">Callers of this should hold the android.permission.INVOKE_CARRIER_SETUP
      * permission.</p>
@@ -274,13 +274,6 @@
     public static final String ACTION_CARRIER_SETUP = "android.intent.action.ACTION_CARRIER_SETUP";
 
     /**
-     * A <em>prefix</em> for the MCC/MNC filtering used with {@link #ACTION_CARRIER_SETUP}.
-     * The MCC/MNC will be concatenated (zero-padded to 3 digits each) to create a final
-     * string of the form: {@code android.intent.category.MCCMNC_310260}
-     */
-    public static final String CATEGORY_MCCMNC_PREFIX = "android.intent.category.MCCMNC_";
-
-    /**
      * Broadcast Action: A "secret code" has been entered in the dialer. Secret codes are
      * of the form {@code *#*#<code>#*#*}. The intent will have the data URI:
      *
@@ -398,4 +391,14 @@
      */
     public static final String ACTION_DEFAULT_VOICE_SUBSCRIPTION_CHANGED
             = "android.intent.action.ACTION_DEFAULT_VOICE_SUBSCRIPTION_CHANGED";
+
+    /**
+     * Broadcast Action: The default sms subscription has changed.  This has the following
+     * extra values:</p>
+     * <ul>
+     *   <li><em>subscription</em> - A int, the current sms default subscription.</li>
+     * </ul>
+     */
+    public static final String ACTION_DEFAULT_SMS_SUBSCRIPTION_CHANGED
+            = "android.intent.action.ACTION_DEFAULT_SMS_SUBSCRIPTION_CHANGED";
 }
diff --git a/telephony/java/com/android/internal/telephony/TelephonyProperties.java b/telephony/java/com/android/internal/telephony/TelephonyProperties.java
index 5ec4247..c89208d 100644
--- a/telephony/java/com/android/internal/telephony/TelephonyProperties.java
+++ b/telephony/java/com/android/internal/telephony/TelephonyProperties.java
@@ -123,8 +123,8 @@
     /** Indicate the timer value for exiting emergency callback mode */
     static final String PROPERTY_ECM_EXIT_TIMER = "ro.cdma.ecmexittimer";
 
-    /** The international dialing prefix conversion string */
-    static final String PROPERTY_IDP_STRING = "ro.cdma.idpstring";
+    /** the international dialing prefix of current operator network */
+    static final String PROPERTY_OPERATOR_IDP_STRING = "gsm.operator.idpstring";
 
     /**
      * Defines the schema for the carrier specified OTASP number
diff --git a/test-runner/src/android/test/ProviderTestCase.java b/test-runner/src/android/test/ProviderTestCase.java
index 1b323cf..4108f34 100644
--- a/test-runner/src/android/test/ProviderTestCase.java
+++ b/test-runner/src/android/test/ProviderTestCase.java
@@ -67,9 +67,8 @@
                 filenamePrefix);
         mProviderContext = new IsolatedContext(mResolver, targetContextWrapper);
 
-        mProvider = mProviderClass.newInstance();
-        mProvider.attachInfoForTesting(mProviderContext, null);
-        assertNotNull(mProvider);
+        mProvider = ProviderTestCase2.createProviderForTest(
+                mProviderContext, mProviderClass, mProviderAuthority);
         mResolver.addProvider(mProviderAuthority, getProvider());
     }
 
@@ -107,8 +106,7 @@
                 resolver, targetContextWrapper);
         DatabaseUtils.createDbFromSqlStatements(context, databaseName, databaseVersion, sql);
 
-        T provider = providerClass.newInstance();
-        provider.attachInfoForTesting(context, null);
+        T provider = ProviderTestCase2.createProviderForTest(context, providerClass, authority);
         resolver.addProvider(authority, provider);
 
         return resolver;
diff --git a/test-runner/src/android/test/ProviderTestCase2.java b/test-runner/src/android/test/ProviderTestCase2.java
index dcd089da..1fa633e 100644
--- a/test-runner/src/android/test/ProviderTestCase2.java
+++ b/test-runner/src/android/test/ProviderTestCase2.java
@@ -19,6 +19,7 @@
 import android.content.ContentProvider;
 import android.content.ContentResolver;
 import android.content.Context;
+import android.content.pm.ProviderInfo;
 import android.content.res.Resources;
 import android.test.mock.MockContext;
 import android.test.mock.MockContentResolver;
@@ -138,14 +139,24 @@
                 getContext(), // The context that file methods are delegated to
                 filenamePrefix);
         mProviderContext = new IsolatedContext(mResolver, targetContextWrapper);
-
-        mProvider = mProviderClass.newInstance();
-        mProvider.attachInfoForTesting(mProviderContext, null);
-        assertNotNull(mProvider);
+        mProvider = createProviderForTest(mProviderContext, mProviderClass, mProviderAuthority);
         mResolver.addProvider(mProviderAuthority, getProvider());
     }
 
     /**
+     * Creates and sets up a new instance of the provider.
+     */
+    static <T extends ContentProvider> T createProviderForTest(
+            Context context, Class<T> providerClass, String authority)
+            throws IllegalAccessException, InstantiationException {
+        T instance = providerClass.newInstance();
+        ProviderInfo providerInfo = new ProviderInfo();
+        providerInfo.authority = authority;
+        instance.attachInfoForTesting(context, providerInfo);
+        return instance;
+    }
+
+    /**
      * Tears down the environment for the test fixture.
      * <p>
      * Calls {@link android.content.ContentProvider#shutdown()} on the
@@ -218,8 +229,7 @@
         Context context = new IsolatedContext(resolver, targetContextWrapper);
         DatabaseUtils.createDbFromSqlStatements(context, databaseName, databaseVersion, sql);
 
-        T provider = providerClass.newInstance();
-        provider.attachInfoForTesting(context, null);
+        T provider = createProviderForTest(context, providerClass, authority);
         resolver.addProvider(authority, provider);
 
         return resolver;
diff --git a/test-runner/src/android/test/mock/MockPackageManager.java b/test-runner/src/android/test/mock/MockPackageManager.java
index c84f40e..afe1d5d 100644
--- a/test-runner/src/android/test/mock/MockPackageManager.java
+++ b/test-runner/src/android/test/mock/MockPackageManager.java
@@ -46,7 +46,7 @@
 import android.content.pm.VerifierDeviceIdentity;
 import android.content.res.Resources;
 import android.content.res.XmlResourceParser;
-import android.graphics.Bitmap;
+import android.graphics.Rect;
 import android.graphics.drawable.Drawable;
 import android.net.Uri;
 import android.os.UserHandle;
@@ -403,6 +403,29 @@
     }
 
     @Override
+    public Drawable getUserBadgedIcon(Drawable icon, UserHandle user) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public Drawable getUserBadgedDrawableForDensity(Drawable drawable, UserHandle user,
+            Rect badgeLocation,
+            int badgeDensity) {
+        throw new UnsupportedOperationException();
+    }
+
+    /** @hide */
+    @Override
+    public Drawable getUserBadgeForDensity(UserHandle user, int density) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
+    public CharSequence getUserBadgedLabel(CharSequence label, UserHandle user) {
+        throw new UnsupportedOperationException();
+    }
+
+    @Override
     public CharSequence getText(String packageName, int resid, ApplicationInfo appInfo) {
         throw new UnsupportedOperationException();
     }
@@ -617,21 +640,25 @@
         throw new UnsupportedOperationException();
     }
 
+    /** @hide */
     @Override
     public KeySet getKeySetByAlias(String packageName, String alias) {
         throw new UnsupportedOperationException();
     }
 
+    /** @hide */
     @Override
     public KeySet getSigningKeySet(String packageName) {
         throw new UnsupportedOperationException();
     }
 
+    /** @hide */
     @Override
     public boolean isSignedBy(String packageName, KeySet ks) {
         throw new UnsupportedOperationException();
     }
 
+    /** @hide */
     @Override
     public boolean isSignedByExactly(String packageName, KeySet ks) {
         throw new UnsupportedOperationException();
@@ -763,24 +790,6 @@
     /**
      * @hide
      */
-    @Override
-    public void addCrossProfileIntentsForPackage(String packageName, int sourceUserId,
-            int targetUserId) {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * @hide
-     */
-    @Override
-    public void removeCrossProfileIntentsForPackage(String packageName, int sourceUserId,
-            int targetUserId) {
-        throw new UnsupportedOperationException();
-    }
-
-    /**
-     * @hide
-     */
     public Drawable loadItemIcon(PackageItemInfo itemInfo, ApplicationInfo appInfo) {
         throw new UnsupportedOperationException();
     }
diff --git a/tests/ActivityTests/AndroidManifest.xml b/tests/ActivityTests/AndroidManifest.xml
index 15d075c..3fb547d 100644
--- a/tests/ActivityTests/AndroidManifest.xml
+++ b/tests/ActivityTests/AndroidManifest.xml
@@ -23,6 +23,7 @@
     <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS" />
     <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS_FULL" />
     <uses-permission android:name="android.permission.MANAGE_USERS" />
+    <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />
     <application android:label="ActivityTest">
         <activity android:name="ActivityTestMain">
             <intent-filter>
@@ -30,6 +31,11 @@
                 <category android:name="android.intent.category.LAUNCHER" />
             </intent-filter>
         </activity>
+        <activity android:name="SpamActivity" android:label="Spam!"
+                android:documentLaunchMode="always">
+        </activity>
+        <activity android:name="DocActivity" android:label="Some doc">
+        </activity>
         <service android:name="SingleUserService"
             android:singleUser="true" android:exported="true">
         </service>
diff --git a/tests/ActivityTests/res/drawable-hdpi/icon.png b/tests/ActivityTests/res/drawable-hdpi/icon.png
new file mode 100644
index 0000000..2eab6f2
--- /dev/null
+++ b/tests/ActivityTests/res/drawable-hdpi/icon.png
Binary files differ
diff --git a/tests/ActivityTests/res/drawable-mdpi/icon.png b/tests/ActivityTests/res/drawable-mdpi/icon.png
new file mode 100644
index 0000000..63aec6f
--- /dev/null
+++ b/tests/ActivityTests/res/drawable-mdpi/icon.png
Binary files differ
diff --git a/tests/ActivityTests/res/drawable-xhdpi/icon.png b/tests/ActivityTests/res/drawable-xhdpi/icon.png
new file mode 100644
index 0000000..8ea9c48
--- /dev/null
+++ b/tests/ActivityTests/res/drawable-xhdpi/icon.png
Binary files differ
diff --git a/tests/ActivityTests/src/com/google/android/test/activity/ActivityTestMain.java b/tests/ActivityTests/src/com/google/android/test/activity/ActivityTestMain.java
index 0e063d6..6837d22 100644
--- a/tests/ActivityTests/src/com/google/android/test/activity/ActivityTestMain.java
+++ b/tests/ActivityTests/src/com/google/android/test/activity/ActivityTestMain.java
@@ -21,6 +21,7 @@
 
 import android.app.Activity;
 import android.app.ActivityManager;
+import android.app.ActivityOptions;
 import android.app.AlertDialog;
 import android.content.ActivityNotFoundException;
 import android.content.BroadcastReceiver;
@@ -28,8 +29,11 @@
 import android.content.ContentProviderClient;
 import android.content.Intent;
 import android.content.ServiceConnection;
+import android.graphics.BitmapFactory;
 import android.os.Bundle;
+import android.os.Handler;
 import android.os.IBinder;
+import android.os.Message;
 import android.os.RemoteException;
 import android.os.UserHandle;
 import android.os.UserManager;
@@ -58,6 +62,28 @@
 
     ArrayList<ServiceConnection> mConnections = new ArrayList<ServiceConnection>();
 
+    static final int MSG_SPAM = 1;
+
+    final Handler mHandler = new Handler() {
+        @Override
+        public void handleMessage(Message msg) {
+            switch (msg.what) {
+                case MSG_SPAM: {
+                    boolean fg = msg.arg1 != 0;
+                    Intent intent = new Intent(ActivityTestMain.this, SpamActivity.class);
+                    Bundle options = null;
+                    if (fg) {
+                        ActivityOptions opts = ActivityOptions.makeTaskLaunchBehind();
+                        options = opts.toBundle();
+                    }
+                    startActivity(intent, options);
+                    scheduleSpam(!fg);
+                } break;
+            }
+            super.handleMessage(msg);
+        }
+    };
+
     class BroadcastResultReceiver extends BroadcastReceiver {
         @Override
         public void onReceive(Context context, Intent intent) {
@@ -130,12 +156,19 @@
                 mSecondUser = ui.id;
             }
         }
+
+        /*
+        AlertDialog ad = new AlertDialog.Builder(this).setTitle("title").setMessage("message").create();
+        ad.getWindow().getAttributes().type = WindowManager.LayoutParams.TYPE_SYSTEM_ERROR;
+        ad.show();
+        */
     }
 
     @Override
     public boolean onCreateOptionsMenu(Menu menu) {
         menu.add("Animate!").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
-            @Override public boolean onMenuItemClick(MenuItem item) {
+            @Override
+            public boolean onMenuItemClick(MenuItem item) {
                 AlertDialog.Builder builder = new AlertDialog.Builder(ActivityTestMain.this,
                         R.style.SlowDialog);
                 builder.setTitle("This is a title");
@@ -212,7 +245,7 @@
             @Override public boolean onMenuItemClick(MenuItem item) {
                 Intent intent = new Intent(ActivityTestMain.this, UserTarget.class);
                 sendOrderedBroadcastAsUser(intent, new UserHandle(mSecondUser), null,
-                        new BroadcastResultReceiver(), 
+                        new BroadcastResultReceiver(),
                         null, Activity.RESULT_OK, null, null);
                 return true;
             }
@@ -284,6 +317,69 @@
                 return true;
             }
         });
+        menu.add("Add App Recent").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                addAppRecents(1);
+                return true;
+            }
+        });
+        menu.add("Add App 10x Recent").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                addAppRecents(10);
+                return true;
+            }
+        });
+        menu.add("Exclude!").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                setExclude(true);
+                return true;
+            }
+        });
+        menu.add("Include!").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                setExclude(false);
+                return true;
+            }
+        });
+        menu.add("Open Doc").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                ActivityManager.AppTask task = findDocTask();
+                if (task == null) {
+                    Intent intent = new Intent(ActivityTestMain.this, DocActivity.class);
+                    intent.addFlags(Intent.FLAG_ACTIVITY_NEW_DOCUMENT
+                            | Intent.FLAG_ACTIVITY_MULTIPLE_TASK
+                            | Intent.FLAG_ACTIVITY_RETAIN_IN_RECENTS);
+                    startActivity(intent);
+                } else {
+                    task.moveToFront();
+                }
+                return true;
+            }
+        });
+        menu.add("Stack Doc").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                ActivityManager.AppTask task = findDocTask();
+                if (task != null) {
+                    ActivityManager.RecentTaskInfo recent = task.getTaskInfo();
+                    Intent intent = new Intent(ActivityTestMain.this, DocActivity.class);
+                    if (recent.id >= 0) {
+                        // Stack on top.
+                        intent.putExtra(DocActivity.LABEL, "Stacked");
+                    } else {
+                        // Start root activity.
+                        intent.putExtra(DocActivity.LABEL, "New Root");
+                    }
+                    task.startActivity(ActivityTestMain.this, intent, null);
+                }
+                return true;
+            }
+        });
+        menu.add("Spam!").setOnMenuItemClickListener(new MenuItem.OnMenuItemClickListener() {
+            @Override public boolean onMenuItemClick(MenuItem item) {
+                scheduleSpam(false);
+                return true;
+            }
+        });
         return true;
     }
 
@@ -294,6 +390,17 @@
     }
 
     @Override
+    protected void onPause() {
+        super.onPause();
+        Log.i(TAG, "I'm such a slooow poor loser");
+        try {
+            Thread.sleep(500);
+        } catch (InterruptedException e) {
+        }
+        Log.i(TAG, "See?");
+    }
+
+    @Override
     protected void onSaveInstanceState(Bundle outState) {
         super.onSaveInstanceState(outState);
         if (mOverrideConfig != null) {
@@ -310,6 +417,65 @@
         mConnections.clear();
     }
 
+    @Override
+    protected void onDestroy() {
+        super.onDestroy();
+        mHandler.removeMessages(MSG_SPAM);
+    }
+
+    void addAppRecents(int count) {
+        ActivityManager am = (ActivityManager)getSystemService(Context.ACTIVITY_SERVICE);
+        Intent intent = new Intent(Intent.ACTION_MAIN);
+        intent.addCategory(Intent.CATEGORY_LAUNCHER);
+        intent.addFlags(Intent.FLAG_ACTIVITY_NEW_DOCUMENT);
+        intent.setComponent(new ComponentName(this, ActivityTestMain.class));
+        for (int i=0; i<count; i++) {
+            ActivityManager.TaskDescription desc = new ActivityManager.TaskDescription();
+            desc.setLabel("Added #" + i);
+            Bitmap bitmap = BitmapFactory.decodeResource(getResources(), R.drawable.icon);
+            if ((i&1) == 0) {
+                desc.setIcon(bitmap);
+            }
+            int taskId = am.addAppTask(this, intent, desc, bitmap);
+            Log.i(TAG, "Added new task id #" + taskId);
+        }
+    }
+
+    void setExclude(boolean exclude) {
+        ActivityManager am = (ActivityManager)getSystemService(Context.ACTIVITY_SERVICE);
+        List<ActivityManager.AppTask> tasks = am.getAppTasks();
+        int taskId = getTaskId();
+        for (int i=0; i<tasks.size(); i++) {
+            ActivityManager.AppTask task = tasks.get(i);
+            if (task.getTaskInfo().id == taskId) {
+                task.setExcludeFromRecents(exclude);
+            }
+        }
+    }
+
+    ActivityManager.AppTask findDocTask() {
+        ActivityManager am = (ActivityManager)getSystemService(Context.ACTIVITY_SERVICE);
+        List<ActivityManager.AppTask> tasks = am.getAppTasks();
+        if (tasks != null) {
+            for (int i=0; i<tasks.size(); i++) {
+                ActivityManager.AppTask task = tasks.get(i);
+                ActivityManager.RecentTaskInfo recent = task.getTaskInfo();
+                if (recent.baseIntent != null
+                        && recent.baseIntent.getComponent().getClassName().equals(
+                                DocActivity.class.getCanonicalName())) {
+                    return task;
+                }
+            }
+        }
+        return null;
+    }
+
+    void scheduleSpam(boolean fg) {
+        mHandler.removeMessages(MSG_SPAM);
+        Message msg = mHandler.obtainMessage(MSG_SPAM, fg ? 1 : 0, 0);
+        mHandler.sendMessageDelayed(msg, 500);
+    }
+
     private View scrollWrap(View view) {
         ScrollView scroller = new ScrollView(this);
         scroller.addView(view, new ScrollView.LayoutParams(ScrollView.LayoutParams.MATCH_PARENT,
diff --git a/tests/ActivityTests/src/com/google/android/test/activity/DocActivity.java b/tests/ActivityTests/src/com/google/android/test/activity/DocActivity.java
new file mode 100644
index 0000000..6330c79
--- /dev/null
+++ b/tests/ActivityTests/src/com/google/android/test/activity/DocActivity.java
@@ -0,0 +1,35 @@
+/*
+ * Copyright (C) 2014 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.google.android.test.activity;
+
+import android.app.Activity;
+import android.app.ActivityManager;
+import android.os.Bundle;
+
+public class DocActivity extends Activity {
+    static final String LABEL = "label";
+
+    @Override
+    protected void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+        String label = getIntent().getStringExtra(LABEL);
+        if (label != null) {
+            setTaskDescription(new ActivityManager.TaskDescription(label));
+            setTitle(label);
+        }
+    }
+}
diff --git a/tests/ActivityTests/src/com/google/android/test/activity/SpamActivity.java b/tests/ActivityTests/src/com/google/android/test/activity/SpamActivity.java
new file mode 100644
index 0000000..e5de559
--- /dev/null
+++ b/tests/ActivityTests/src/com/google/android/test/activity/SpamActivity.java
@@ -0,0 +1,31 @@
+/*
+ * Copyright (C) 2014 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.google.android.test.activity;
+
+import android.app.Activity;
+import android.os.Bundle;
+
+public class SpamActivity extends Activity {
+    byte[] mBytes;
+
+    @Override
+    protected void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+        // Chew up some RAM -- 8 megs worth.
+        mBytes = new byte[8*1024*1024];
+    }
+}
diff --git a/tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java b/tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java
index a209d6c..8b8d604 100644
--- a/tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java
+++ b/tests/AppLaunch/src/com/android/tests/applaunch/AppLaunch.java
@@ -344,7 +344,7 @@
                 }
 
                 mResult = mAm.startActivityAndWait(null, null, mLaunchIntent, mimeType,
-                        null, null, 0, mLaunchIntent.getFlags(), null, null, null,
+                        null, null, 0, mLaunchIntent.getFlags(), null, null,
                         UserHandle.USER_CURRENT);
             } catch (RemoteException e) {
                 Log.w(TAG, "Error launching app", e);
diff --git a/tests/Camera2Tests/CameraToo/src/com/example/android/camera2/cameratoo/CameraTooActivity.java b/tests/Camera2Tests/CameraToo/src/com/example/android/camera2/cameratoo/CameraTooActivity.java
index c630bad..d513f44 100644
--- a/tests/Camera2Tests/CameraToo/src/com/example/android/camera2/cameratoo/CameraTooActivity.java
+++ b/tests/Camera2Tests/CameraToo/src/com/example/android/camera2/cameratoo/CameraTooActivity.java
@@ -290,14 +290,14 @@
 
                 // Open the camera device
                 try {
-                    mCameraManager.openCamera(mCameraId, mCameraStateListener,
+                    mCameraManager.openCamera(mCameraId, mCameraStateCallback,
                             mBackgroundHandler);
                 } catch (CameraAccessException ex) {
                     Log.e(TAG, "Failed to configure output surface", ex);
                 }
                 mGotSecondCallback = true;
 
-                // Control flow continues in mCameraStateListener.onOpened()
+                // Control flow continues in mCameraStateCallback.onOpened()
             }
         }};
 
@@ -305,8 +305,8 @@
      * Calledbacks invoked upon state changes in our {@code CameraDevice}. <p>These are run on
      * {@code mBackgroundThread}.</p>
      */
-    final CameraDevice.StateListener mCameraStateListener =
-            new CameraDevice.StateListener() {
+    final CameraDevice.StateCallback mCameraStateCallback =
+            new CameraDevice.StateCallback() {
         @Override
         public void onOpened(CameraDevice camera) {
             Log.i(TAG, "Successfully opened camera");
@@ -337,8 +337,8 @@
      * Callbacks invoked upon state changes in our {@code CameraCaptureSession}. <p>These are run on
      * {@code mBackgroundThread}.</p>
      */
-    final CameraCaptureSession.StateListener mCaptureSessionListener =
-            new CameraCaptureSession.StateListener() {
+    final CameraCaptureSession.StateCallback mCaptureSessionListener =
+            new CameraCaptureSession.StateCallback() {
         @Override
         public void onConfigured(CameraCaptureSession session) {
             Log.i(TAG, "Finished configuring camera outputs");
diff --git a/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/samples/simplecamera/Camera2Source.java b/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/samples/simplecamera/Camera2Source.java
index 05057f2..07dfb54 100644
--- a/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/samples/simplecamera/Camera2Source.java
+++ b/tests/Camera2Tests/SmartCamera/SimpleCamera/src/androidx/media/filterfw/samples/simplecamera/Camera2Source.java
@@ -38,7 +38,7 @@
 import android.view.Surface;
 import com.android.ex.camera2.blocking.BlockingCameraManager;
 import com.android.ex.camera2.blocking.BlockingCameraManager.BlockingOpenException;
-import com.android.ex.camera2.blocking.BlockingSessionListener;
+import com.android.ex.camera2.blocking.BlockingSessionCallback;
 import androidx.media.filterfw.Filter;
 import androidx.media.filterfw.Frame;
 import androidx.media.filterfw.FrameImage2D;
@@ -72,7 +72,7 @@
 
     private static final long SESSION_TIMEOUT_MS = 2000;
 
-    class MyCameraListener extends CameraManager.AvailabilityListener {
+    class MyCameraListener extends CameraManager.AvailabilityCallback {
 
         @Override
         public void onCameraAvailable(String cameraId) {
@@ -88,7 +88,7 @@
 
     }
 
-    class MyCaptureListener extends CameraCaptureSession.CaptureListener {
+    class MyCaptureCallback extends CameraCaptureSession.CaptureCallback {
 
         @Override
         public void onCaptureCompleted(CameraCaptureSession camera, CaptureRequest request,
@@ -189,7 +189,7 @@
         surfaces.add(mSurface);
         CaptureRequest.Builder mCaptureRequest = null;
         try {
-            BlockingSessionListener blkSession = new BlockingSessionListener();
+            BlockingSessionCallback blkSession = new BlockingSessionCallback();
 
             mCamera.createCaptureSession(surfaces, blkSession, mHandler);
             mCaptureRequest = mCamera.createCaptureRequest(CameraDevice.TEMPLATE_PREVIEW);
@@ -203,7 +203,7 @@
         }
 
         try {
-            mCameraSession.setRepeatingRequest(mCaptureRequest.build(), new MyCaptureListener(),
+            mCameraSession.setRepeatingRequest(mCaptureRequest.build(), new MyCaptureCallback(),
                     mHandler);
         } catch (CameraAccessException e) {
             e.printStackTrace();
diff --git a/tests/CanvasCompare/src/com/android/test/hwuicompare/ErrorCalculator.java b/tests/CanvasCompare/src/com/android/test/hwuicompare/ErrorCalculator.java
index 08d7667..d402699 100644
--- a/tests/CanvasCompare/src/com/android/test/hwuicompare/ErrorCalculator.java
+++ b/tests/CanvasCompare/src/com/android/test/hwuicompare/ErrorCalculator.java
@@ -54,7 +54,7 @@
         for (int i = 0; i < rowIndices.length; i++)
             rowIndices[i] = i * REGION_SIZE;
 
-        mScript = new ScriptC_errorCalculator(mRS, resources, R.raw.errorcalculator);
+        mScript = new ScriptC_errorCalculator(mRS);
         mScript.set_HEIGHT(height);
         mScript.set_WIDTH(width);
         mScript.set_REGION_SIZE(REGION_SIZE);
diff --git a/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java b/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java
index 5bf59c7..a2e9117 100644
--- a/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java
+++ b/tests/Compatibility/src/com/android/compatibilitytest/AppCompatibility.java
@@ -208,6 +208,12 @@
                 Log.d(TAG, "Found process " + app.processName);
                 return true;
             }
+            for (String relatedPackage : app.pkgList) {
+                if (relatedPackage.equalsIgnoreCase(processName)) {
+                    Log.d(TAG, "Found process " + app.processName);
+                    return true;
+                }
+            }
         }
         Log.d(TAG, "Failed to find process " + processName + " with package name "
                 + packageName);
diff --git a/tests/FrameworkPerf/src/com/android/frameworkperf/FrameworkPerfActivity.java b/tests/FrameworkPerf/src/com/android/frameworkperf/FrameworkPerfActivity.java
index 6633787..78e360b 100644
--- a/tests/FrameworkPerf/src/com/android/frameworkperf/FrameworkPerfActivity.java
+++ b/tests/FrameworkPerf/src/com/android/frameworkperf/FrameworkPerfActivity.java
@@ -20,6 +20,7 @@
 import android.content.ComponentName;
 import android.content.Intent;
 import android.content.ServiceConnection;
+import android.graphics.Color;
 import android.os.Binder;
 import android.os.Bundle;
 import android.os.Handler;
@@ -199,6 +200,7 @@
         mLocalCheckBox = (CheckBox)findViewById(R.id.local);
 
         mLog = (TextView)findViewById(R.id.log);
+        mLog.setTextColor(Color.RED);
 
         PowerManager pm = (PowerManager)getSystemService(POWER_SERVICE);
         mPartialWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "Scheduler");
diff --git a/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java b/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
index a81e063..afd6a8d 100644
--- a/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
+++ b/tests/HwAccelerationTest/src/com/android/test/hwui/CirclePropActivity.java
@@ -16,7 +16,6 @@
 
 package com.android.test.hwui;
 
-import android.animation.TimeInterpolator;
 import android.app.Activity;
 import android.content.Context;
 import android.graphics.Canvas;
@@ -28,11 +27,6 @@
 import android.view.HardwareCanvas;
 import android.view.RenderNodeAnimator;
 import android.view.View;
-import android.view.animation.AccelerateDecelerateInterpolator;
-import android.view.animation.OvershootInterpolator;
-import android.webkit.WebChromeClient;
-import android.webkit.WebView;
-import android.webkit.WebViewClient;
 import android.widget.LinearLayout;
 import android.widget.LinearLayout.LayoutParams;
 import android.widget.ProgressBar;
diff --git a/tests/HwAccelerationTest/src/com/android/test/hwui/RevealActivity.java b/tests/HwAccelerationTest/src/com/android/test/hwui/RevealActivity.java
index 3360e30..256a1d4 100644
--- a/tests/HwAccelerationTest/src/com/android/test/hwui/RevealActivity.java
+++ b/tests/HwAccelerationTest/src/com/android/test/hwui/RevealActivity.java
@@ -17,6 +17,7 @@
 package com.android.test.hwui;
 
 import android.animation.Animator;
+import android.animation.AnimatorSet;
 import android.app.Activity;
 import android.content.Context;
 import android.graphics.Canvas;
@@ -34,6 +35,7 @@
     private static final int DURATION = 800;
 
     private boolean mShouldBlock;
+    private int mIteration = 0;
 
     @Override
     protected void onCreate(Bundle savedInstanceState) {
@@ -57,10 +59,17 @@
         Animator animator = ViewAnimationUtils.createCircularReveal(view,
                 view.getWidth() / 2, view.getHeight() / 2,
                 0, Math.max(view.getWidth(), view.getHeight()));
-        animator.setDuration(DURATION);
-        animator.setAllowRunningAsynchronously(true);
-        animator.start();
+        if (mIteration < 2) {
+            animator.setDuration(DURATION);
+            animator.start();
+        } else {
+            AnimatorSet set = new AnimatorSet();
+            set.playTogether(animator);
+            set.setDuration(DURATION);
+            set.start();
+        }
 
+        mIteration = (mIteration + 1) % 4;
         mShouldBlock = !mShouldBlock;
         if (mShouldBlock) {
             view.post(sBlockThread);
diff --git a/tests/JobSchedulerTestApp/res/layout/activity_main.xml b/tests/JobSchedulerTestApp/res/layout/activity_main.xml
index d3429ff..96e1641 100644
--- a/tests/JobSchedulerTestApp/res/layout/activity_main.xml
+++ b/tests/JobSchedulerTestApp/res/layout/activity_main.xml
@@ -141,6 +141,20 @@
                         android:id="@+id/checkbox_idle"
                         android:text="@string/idle_mode_text"/>
                 </LinearLayout>
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content">
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:text="@string/persisted_caption"
+                        android:layout_marginRight="15dp"/>
+                    <CheckBox
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:id="@+id/checkbox_persisted"
+                        android:text="@string/persisted_mode_text"/>
+                </LinearLayout>
 
             </LinearLayout>
         <Button
diff --git a/tests/JobSchedulerTestApp/res/values/strings.xml b/tests/JobSchedulerTestApp/res/values/strings.xml
index eebfb19..90dd2b6 100644
--- a/tests/JobSchedulerTestApp/res/values/strings.xml
+++ b/tests/JobSchedulerTestApp/res/values/strings.xml
@@ -27,6 +27,7 @@
     <string name="charging_caption">Charging:</string>
     <string name="charging_text">Requires device plugged in.</string>
     <string name="idle_caption">Idle:</string>
+    <string name="persisted_caption">Persisted:</string>
     <string name="constraints">Constraints</string>
     <string name="connectivity">Connectivity:</string>
     <string name="any">Any</string>
@@ -34,4 +35,5 @@
     <string name="timing">Timing:</string>
     <string name="delay">Delay:</string>
     <string name="deadline">Deadline:</string>
+    <string name="persisted_mode_text">Persisted:</string>
 </resources>
diff --git a/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/MainActivity.java b/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/MainActivity.java
index e15929d..b9a2a7e 100644
--- a/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/MainActivity.java
+++ b/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/MainActivity.java
@@ -65,6 +65,8 @@
         mAnyConnectivityRadioButton = (RadioButton) findViewById(R.id.checkbox_any);
         mRequiresChargingCheckBox = (CheckBox) findViewById(R.id.checkbox_charging);
         mRequiresIdleCheckbox = (CheckBox) findViewById(R.id.checkbox_idle);
+        mIsPersistedCheckbox = (CheckBox) findViewById(R.id.checkbox_persisted);
+
         mServiceComponent = new ComponentName(this, TestJobService.class);
         // Start service and provide it a way to communicate with us.
         Intent startServiceIntent = new Intent(this, TestJobService.class);
@@ -85,6 +87,7 @@
     RadioButton mAnyConnectivityRadioButton;
     CheckBox mRequiresChargingCheckBox;
     CheckBox mRequiresIdleCheckbox;
+    CheckBox mIsPersistedCheckbox;
 
     ComponentName mServiceComponent;
     /** Service object to interact scheduled jobs. */
@@ -140,13 +143,13 @@
         boolean requiresUnmetered = mWiFiConnectivityRadioButton.isChecked();
         boolean requiresAnyConnectivity = mAnyConnectivityRadioButton.isChecked();
         if (requiresUnmetered) {
-            builder.setRequiredNetworkCapabilities(JobInfo.NetworkType.UNMETERED);
+            builder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_UNMETERED);
         } else if (requiresAnyConnectivity) {
-            builder.setRequiredNetworkCapabilities(JobInfo.NetworkType.ANY);
+            builder.setRequiredNetworkType(JobInfo.NETWORK_TYPE_ANY);
         }
         builder.setRequiresDeviceIdle(mRequiresIdleCheckbox.isChecked());
         builder.setRequiresCharging(mRequiresChargingCheckBox.isChecked());
-
+        builder.setPersisted(mIsPersistedCheckbox.isChecked());
         mTestService.scheduleJob(builder.build());
 
     }
diff --git a/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/service/TestJobService.java b/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/service/TestJobService.java
index e2c3be0..9df11fe 100644
--- a/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/service/TestJobService.java
+++ b/tests/JobSchedulerTestApp/src/com/android/demo/jobSchedulerApp/service/TestJobService.java
@@ -29,6 +29,7 @@
 import android.os.RemoteException;
 import android.util.Log;
 import android.util.SparseArray;
+import android.widget.Toast;
 
 import com.android.demo.jobSchedulerApp.MainActivity;
 
@@ -84,37 +85,15 @@
         currentId++;
         jobParamsMap.put(currentId, params);
         final int currId = this.currentId;
-        Log.d(TAG, "putting :" + currId + " for " + params.toString());
-        Log.d(TAG, " pulled: " + jobParamsMap.get(currId));
         if (mActivity != null) {
             mActivity.onReceivedStartJob(params);
         }
 
-        // Spin off a new task on a separate thread for a couple seconds.
-        new AsyncTask<Void, Void, Void>() {
-            @Override
-            protected Void doInBackground(Void... voids) {
-                try {
-                    Log.d(TAG, "Sleeping for 3 seconds.");
-                    Thread.sleep(3000L);
-                } catch (InterruptedException e) {}
-                final JobParameters params = jobParamsMap.get(currId);
-                Log.d(TAG, "Pulled :" + currId + " " + params);
-                jobFinished(params, false);
+        Toast.makeText(
+                this, "On start job: '" + params.getJobId() + "' deadline exceeded: " +
+                        params.isOverrideDeadlineExpired(),
+                Toast.LENGTH_LONG).show();
 
-                Log.d(TAG, "Rescheduling new job: " + params.getJobId());
-                scheduleJob(
-                        new JobInfo.Builder(params.getJobId(),
-                                new ComponentName(getBaseContext(), TestJobService.class))
-                                .setMinimumLatency(2000L)
-                                .setOverrideDeadline(3000L)
-                                .setRequiresCharging(true)
-                                .build()
-                );
-
-                return null;
-            }
-        }.execute();
         return true;
     }
 
@@ -125,7 +104,7 @@
         int ind = jobParamsMap.indexOfValue(params);
         jobParamsMap.remove(ind);
         mActivity.onReceivedStopJob();
-        return true;
+        return false; // no reschedule
     }
 
     static int currentId = 0;
@@ -154,6 +133,7 @@
             return false;
         } else {
             jobFinished(params, false);
+            jobParamsMap.removeAt(0);
             return true;
         }
     }
diff --git a/tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java b/tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java
index f582a91..a7e3bec 100644
--- a/tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java
+++ b/tests/MemoryUsage/src/com/android/tests/memoryusage/MemoryUsageTest.java
@@ -318,7 +318,7 @@
                 }
 
                 mAm.startActivityAndWait(null, null, mLaunchIntent, mimeType,
-                        null, null, 0, mLaunchIntent.getFlags(), null, null, null,
+                        null, null, 0, mLaunchIntent.getFlags(), null, null,
                         UserHandle.USER_CURRENT_OR_SELF);
             } catch (RemoteException e) {
                 Log.w(TAG, "Error launching app", e);
diff --git a/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/AppListFragment.java b/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/AppListFragment.java
index 526ea5d..4e18ce9 100644
--- a/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/AppListFragment.java
+++ b/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/AppListFragment.java
@@ -21,7 +21,7 @@
 import android.content.Intent;
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
-import android.media.browse.MediaBrowserService;
+import android.service.media.MediaBrowserService;
 import android.os.Bundle;
 import android.support.v4.app.FragmentActivity;
 import android.support.v4.app.FragmentTransaction;
@@ -94,7 +94,7 @@
 
             // Load the data
             final PackageManager pm = context.getPackageManager();
-            final Intent intent = new Intent(MediaBrowserService.SERVICE_ACTION);
+            final Intent intent = new Intent(MediaBrowserService.SERVICE_INTERFACE);
             final List<ResolveInfo> list = pm.queryIntentServices(intent, 0);
             final int N = list.size();
             mItems = new ArrayList(N);
diff --git a/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/BrowserListFragment.java b/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/BrowserListFragment.java
index 2fc77dc..8cc9b97 100644
--- a/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/BrowserListFragment.java
+++ b/tests/MusicBrowserDemo/src/com/example/android/musicbrowserdemo/BrowserListFragment.java
@@ -22,8 +22,7 @@
 import android.content.pm.PackageManager;
 import android.content.pm.ResolveInfo;
 import android.media.browse.MediaBrowser;
-import android.media.browse.MediaBrowserItem;
-import android.media.browse.MediaBrowserService;
+import android.service.media.MediaBrowserService;
 import android.os.Bundle;
 import android.net.Uri;
 import android.support.v4.app.FragmentActivity;
@@ -48,18 +47,18 @@
 
     // For args
     public static final String ARG_COMPONENT = "component";
-    public static final String ARG_URI = "uri";
+    public static final String ARG_ID = "uri";
 
     private Adapter mAdapter;
     private List<Item> mItems = new ArrayList();
     private ComponentName mComponent;
-    private Uri mUri;
+    private String mNodeId;
     private MediaBrowser mBrowser;
 
     private static class Item {
-        final MediaBrowserItem media;
+        final MediaBrowser.MediaItem media;
 
-        Item(MediaBrowserItem m) {
+        Item(MediaBrowser.MediaItem m) {
             this.media = m;
         }
     }
@@ -77,7 +76,7 @@
         // Get our arguments
         final Bundle args = getArguments();
         mComponent = args.getParcelable(ARG_COMPONENT);
-        mUri = args.getParcelable(ARG_URI);
+        mNodeId = args.getString(ARG_ID);
 
         // A hint about who we are, so the service can customize the results if it wants to.
         final Bundle rootHints = new Bundle();
@@ -103,13 +102,13 @@
         final Item item = mItems.get(position);
 
         Log.i("BrowserListFragment", "Item clicked: " + position + " -- "
-                + mAdapter.getItem(position).media.getUri());
+                + mAdapter.getItem(position).media.getDescription().getIconUri());
 
         final BrowserListFragment fragment = new BrowserListFragment();
 
         final Bundle args = new Bundle();
         args.putParcelable(BrowserListFragment.ARG_COMPONENT, mComponent);
-        args.putParcelable(BrowserListFragment.ARG_URI, item.media.getUri());
+        args.putParcelable(BrowserListFragment.ARG_ID, item.media.getDescription().getIconUri());
         fragment.setArguments(args);
 
         getFragmentManager().beginTransaction()
@@ -125,13 +124,14 @@
         @Override
         public void onConnected() {
             Log.d(TAG, "mConnectionCallbacks.onConnected");
-            if (mUri == null) {
-                mUri = mBrowser.getRoot();
+            if (mNodeId == null) {
+                mNodeId = mBrowser.getRoot();
             }
-            mBrowser.subscribe(mUri, new MediaBrowser.SubscriptionCallback() {
+            mBrowser.subscribe(mNodeId, new MediaBrowser.SubscriptionCallback() {
                     @Override
-                    public void onChildrenLoaded(Uri parentUri, List<MediaBrowserItem> children) {
-                        Log.d(TAG, "onChildrenLoaded parentUri=" + parentUri
+                public void onChildrenLoaded(String parentId,
+                            List<MediaBrowser.MediaItem> children) {
+                    Log.d(TAG, "onChildrenLoaded parentId=" + parentId
                                 + " children= " + children);
                         mItems.clear();
                         final int N = children.size();
@@ -142,8 +142,8 @@
                     }
 
                     @Override
-                    public void onError(Uri parentUri) {
-                        Log.d(TAG, "onError parentUri=" + parentUri);
+                public void onError(String parentId) {
+                    Log.d(TAG, "onError parentId=" + parentId);
                     }
                 });
         }
@@ -197,7 +197,7 @@
 
             final TextView tv = (TextView)convertView;
             final Item item = mItems.get(position);
-            tv.setText(item.media.getTitle());
+            tv.setText(item.media.getDescription().getTitle());
 
             return convertView;
         }
diff --git a/tests/MusicServiceDemo/src/com/example/android/musicservicedemo/BrowserService.java b/tests/MusicServiceDemo/src/com/example/android/musicservicedemo/BrowserService.java
index 937f1e6..4e2e47e 100644
--- a/tests/MusicServiceDemo/src/com/example/android/musicservicedemo/BrowserService.java
+++ b/tests/MusicServiceDemo/src/com/example/android/musicservicedemo/BrowserService.java
@@ -25,13 +25,14 @@
 import android.database.MatrixCursor;
 import android.graphics.Bitmap;
 import android.media.AudioManager;
+import android.media.MediaDescription;
 import android.media.MediaPlayer;
 import android.media.MediaPlayer.OnCompletionListener;
 import android.media.MediaPlayer.OnErrorListener;
 import android.media.MediaPlayer.OnPreparedListener;
-import android.media.browse.MediaBrowserItem;
-import android.media.browse.MediaBrowserService;
-import android.media.browse.MediaBrowserService.BrowserRoot;
+import android.media.browse.MediaBrowser;
+import android.service.media.MediaBrowserService;
+import android.service.media.MediaBrowserService.BrowserRoot;
 import android.media.session.MediaSession;
 import android.net.Uri;
 import android.net.wifi.WifiManager;
@@ -117,22 +118,24 @@
 
     @Override
     public BrowserRoot onGetRoot(String clientPackageName, int clientUid, Bundle rootHints) {
-        return new BrowserRoot(BROWSE_URI, null);
+        return new BrowserRoot(BROWSE_URI.toString(), null);
     }
 
     @Override
-    public void onLoadChildren(final Uri parentUri,
-            final Result<List<MediaBrowserItem>> result) {
+    public void onLoadChildren(final String parentId,
+            final Result<List<MediaBrowser.MediaItem>> result) {
         new Handler().postDelayed(new Runnable() {
                 public void run() {
-                    final ArrayList<MediaBrowserItem> list = new ArrayList();
+                    final ArrayList<MediaBrowser.MediaItem> list = new ArrayList();
 
                     for (int i=0; i<10; i++) {
-                        list.add(new MediaBrowserItem.Builder(
-                                    Uri.withAppendedPath(BASE_URI, Integer.toString(i)),
-                                    MediaBrowserItem.FLAG_BROWSABLE, "Title " + i)
-                                .setSummary("Summary " + i)
-                                .build());
+                        MediaDescription.Builder bob = new MediaDescription.Builder();
+                        bob.setTitle("Title " + i);
+                        bob.setSubtitle("Summary " + i);
+                        bob.setMediaId(Uri.withAppendedPath(BASE_URI,
+                                Integer.toString(i)).toString());
+                        list.add(new MediaBrowser.MediaItem(bob.build(),
+                                MediaBrowser.MediaItem.FLAG_BROWSABLE));
                     }
 
                     result.sendResult(list);
@@ -141,11 +144,6 @@
         result.detach();
     }
 
-    @Override
-    public void onLoadIcon(Uri uri, int width, int height, Result<Bitmap> result) {
-        result.sendResult(null);
-    }
-
     /*
     @Override
     public void query(final Query query, final IMetadataResultHandler metadataResultHandler,
diff --git a/tests/OneMedia/Android.mk b/tests/OneMedia/Android.mk
index 4feac68..4d39728 100644
--- a/tests/OneMedia/Android.mk
+++ b/tests/OneMedia/Android.mk
@@ -9,9 +9,6 @@
 LOCAL_PACKAGE_NAME := OneMedia
 LOCAL_CERTIFICATE := platform
 
-LOCAL_STATIC_JAVA_LIBRARIES := \
-    android-support-media-protocols
-
 LOCAL_PROGUARD_ENABLED := disabled
 
 include $(BUILD_PACKAGE)
diff --git a/tests/OneMedia/AndroidManifest.xml b/tests/OneMedia/AndroidManifest.xml
index 95072a4..beafeb4 100644
--- a/tests/OneMedia/AndroidManifest.xml
+++ b/tests/OneMedia/AndroidManifest.xml
@@ -25,15 +25,6 @@
             android:name="com.android.onemedia.OnePlayerService"
             android:exported="true"
             android:process="com.android.onemedia.service" />
-        <service
-            android:name=".provider.OneMediaRouteProvider"
-            android:permission="android.permission.BIND_MEDIA_ROUTE_SERVICE"
-            android:exported="true"
-            android:process="com.android.onemedia.provider">
-            <intent-filter>
-                <action android:name="android.media.routing.MediaRouteService" />
-            </intent-filter>
-          </service>
     </application>
 
 </manifest>
diff --git a/tests/OneMedia/src/com/android/onemedia/NotificationHelper.java b/tests/OneMedia/src/com/android/onemedia/NotificationHelper.java
index a5bcda5..ceb0937 100644
--- a/tests/OneMedia/src/com/android/onemedia/NotificationHelper.java
+++ b/tests/OneMedia/src/com/android/onemedia/NotificationHelper.java
@@ -12,6 +12,7 @@
 import android.content.Intent;
 import android.content.IntentFilter;
 import android.graphics.Bitmap;
+import android.media.MediaDescription;
 import android.media.MediaMetadata;
 import android.media.session.MediaController;
 import android.media.session.MediaSession;
@@ -75,7 +76,7 @@
      * destroyed before {@link #onStop} is called.
      */
     public void onStart() {
-        mController.addCallback(mCb);
+        mController.registerCallback(mCb);
         IntentFilter filter = new IntentFilter();
         filter.addAction(RequestUtils.ACTION_FFWD);
         filter.addAction(RequestUtils.ACTION_NEXT);
@@ -99,7 +100,7 @@
      */
     public void onStop() {
         mStarted = false;
-        mController.removeCallback(mCb);
+        mController.unregisterCallback(mCb);
         mService.unregisterReceiver(this);
         updateNotification();
     }
@@ -185,10 +186,10 @@
             text = "Empty metadata!";
             art = null;
         } else {
-            MediaMetadata.Description description = mMetadata.getDescription();
+            MediaDescription description = mMetadata.getDescription();
             title = description.getTitle();
             text = description.getSubtitle();
-            art = description.getIcon();
+            art = description.getIconBitmap();
         }
 
         String playPauseLabel = "";
diff --git a/tests/OneMedia/src/com/android/onemedia/PlayerController.java b/tests/OneMedia/src/com/android/onemedia/PlayerController.java
index c8d72ca..7861bcc 100644
--- a/tests/OneMedia/src/com/android/onemedia/PlayerController.java
+++ b/tests/OneMedia/src/com/android/onemedia/PlayerController.java
@@ -159,7 +159,7 @@
         @Override
         public void onServiceDisconnected(ComponentName name) {
             if (mController != null) {
-                mController.removeCallback(mControllerCb);
+                mController.unregisterCallback(mControllerCb);
             }
             mBinder = null;
             mController = null;
@@ -185,7 +185,7 @@
             }
             mController = new MediaController(mContext, token);
             mContext.setMediaController(mController);
-            mController.addCallback(mControllerCb, mHandler);
+            mController.registerCallback(mControllerCb, mHandler);
             mTransportControls = mController.getTransportControls();
             if (mArt != null) {
                 setArt(mArt);
diff --git a/tests/OneMedia/src/com/android/onemedia/PlayerSession.java b/tests/OneMedia/src/com/android/onemedia/PlayerSession.java
index 9afcf24..8b7c883 100644
--- a/tests/OneMedia/src/com/android/onemedia/PlayerSession.java
+++ b/tests/OneMedia/src/com/android/onemedia/PlayerSession.java
@@ -19,24 +19,16 @@
 import android.content.Intent;
 import android.graphics.Bitmap;
 import android.media.MediaMetadata;
-import android.media.routing.MediaRouteSelector;
-import android.media.routing.MediaRouter;
-import android.media.routing.MediaRouter.ConnectionRequest;
-import android.media.routing.MediaRouter.DestinationInfo;
-import android.media.routing.MediaRouter.RouteInfo;
 import android.media.session.MediaSession;
 import android.media.session.MediaSessionManager;
 import android.media.session.PlaybackState;
 import android.os.Bundle;
-import android.support.media.protocols.MediaPlayerProtocol;
-import android.support.media.protocols.MediaPlayerProtocol.MediaStatus;
 import android.os.RemoteException;
 import android.os.SystemClock;
 import android.util.Log;
 import android.view.KeyEvent;
 
 import com.android.onemedia.playback.LocalRenderer;
-import com.android.onemedia.playback.OneMRPRenderer;
 import com.android.onemedia.playback.Renderer;
 import com.android.onemedia.playback.RequestUtils;
 
@@ -47,7 +39,6 @@
     private static final String TAG = "PlayerSession";
 
     protected MediaSession mSession;
-    protected MediaRouter mRouter;
     protected Context mContext;
     protected Renderer mRenderer;
     protected MediaSession.Callback mCallback;
@@ -80,22 +71,11 @@
                 .getSystemService(Context.MEDIA_SESSION_SERVICE);
         Log.d(TAG, "Creating session for package " + mContext.getBasePackageName());
 
-        mRouter = new MediaRouter(mContext);
-        mRouter.addSelector(new MediaRouteSelector.Builder()
-                .addRequiredProtocol(MediaPlayerProtocol.class)
-                .build());
-        mRouter.addSelector(new MediaRouteSelector.Builder()
-                .setRequiredFeatures(MediaRouter.ROUTE_FEATURE_LIVE_AUDIO)
-                .setOptionalFeatures(MediaRouter.ROUTE_FEATURE_LIVE_VIDEO)
-                .build());
-        mRouter.setRoutingCallback(new RoutingCallback(), null);
-
         mSession = new MediaSession(mContext, "OneMedia");
         mSession.setCallback(mCallback);
         mSession.setPlaybackState(mPlaybackState);
         mSession.setFlags(MediaSession.FLAG_HANDLES_TRANSPORT_CONTROLS
                 | MediaSession.FLAG_HANDLES_MEDIA_BUTTONS);
-        mSession.setMediaRouter(mRouter);
         mSession.setActive(true);
         updateMetadata();
     }
@@ -113,10 +93,6 @@
             mSession.release();
             mSession = null;
         }
-        if (mRouter != null) {
-            mRouter.release();
-            mRouter = null;
-        }
     }
 
     public void setListener(Listener listener) {
@@ -266,63 +242,4 @@
             mRenderer.onPause();
         }
     }
-
-    private class RoutingCallback extends MediaRouter.RoutingCallback {
-        @Override
-        public void onConnectionStateChanged(int state) {
-            if (state == MediaRouter.CONNECTION_STATE_CONNECTING) {
-                if (mRenderer != null) {
-                    mRenderer.onStop();
-                }
-                mRenderer = null;
-                updateState(PlaybackState.STATE_CONNECTING);
-                return;
-            }
-
-            MediaRouter.ConnectionInfo connection = mRouter.getConnection();
-            if (connection != null) {
-                MediaPlayerProtocol protocol =
-                        connection.getProtocolObject(MediaPlayerProtocol.class);
-                if (protocol != null) {
-                    Log.d(TAG, "Connected to route using media player protocol");
-
-                    protocol.setCallback(new PlayerCallback(), null);
-                    mRenderer = new OneMRPRenderer(protocol);
-                    updateState(PlaybackState.STATE_NONE);
-                    return;
-                }
-            }
-
-            // Use local route
-            mRenderer = new LocalRenderer(mContext, null);
-            mRenderer.registerListener(mRenderListener);
-            updateState(PlaybackState.STATE_NONE);
-        }
-    }
-
-    private class PlayerCallback extends MediaPlayerProtocol.Callback {
-        @Override
-        public void onStatusUpdated(MediaStatus status, Bundle extras) {
-            if (status != null) {
-                Log.d(TAG, "Received status update: " + status.toBundle());
-                switch (status.getPlayerState()) {
-                    case MediaStatus.PLAYER_STATE_BUFFERING:
-                        updateState(PlaybackState.STATE_BUFFERING);
-                        break;
-                    case MediaStatus.PLAYER_STATE_IDLE:
-                        updateState(PlaybackState.STATE_STOPPED);
-                        break;
-                    case MediaStatus.PLAYER_STATE_PAUSED:
-                        updateState(PlaybackState.STATE_PAUSED);
-                        break;
-                    case MediaStatus.PLAYER_STATE_PLAYING:
-                        updateState(PlaybackState.STATE_PLAYING);
-                        break;
-                    case MediaStatus.PLAYER_STATE_UNKNOWN:
-                        updateState(PlaybackState.STATE_NONE);
-                        break;
-                }
-            }
-        }
-    }
 }
diff --git a/tests/OneMedia/src/com/android/onemedia/playback/OneMRPRenderer.java b/tests/OneMedia/src/com/android/onemedia/playback/OneMRPRenderer.java
deleted file mode 100644
index 55eb92c..0000000
--- a/tests/OneMedia/src/com/android/onemedia/playback/OneMRPRenderer.java
+++ /dev/null
@@ -1,47 +0,0 @@
-package com.android.onemedia.playback;
-
-import android.os.Bundle;
-import android.support.media.protocols.MediaPlayerProtocol;
-import android.support.media.protocols.MediaPlayerProtocol.MediaInfo;
-
-/**
- * Renderer for communicating with the OneMRP route
- */
-public class OneMRPRenderer extends Renderer {
-    private final MediaPlayerProtocol mProtocol;
-
-    public OneMRPRenderer(MediaPlayerProtocol protocol) {
-        super(null, null);
-        mProtocol = protocol;
-    }
-
-    @Override
-    public void setContent(Bundle request) {
-        MediaInfo mediaInfo = new MediaInfo(request.getString(RequestUtils.EXTRA_KEY_SOURCE),
-                MediaInfo.STREAM_TYPE_BUFFERED, "audio/mp3");
-        mProtocol.load(mediaInfo, true, 0, null);
-    }
-
-    @Override
-    public boolean onStop() {
-        mProtocol.stop(null);
-        return true;
-    }
-
-    @Override
-    public boolean onPlay() {
-        mProtocol.play(null);
-        return true;
-    }
-
-    @Override
-    public boolean onPause() {
-        mProtocol.pause(null);
-        return true;
-    }
-
-    @Override
-    public long getSeekPosition() {
-        return -1;
-    }
-}
diff --git a/tests/OneMedia/src/com/android/onemedia/provider/OneMediaRouteProvider.java b/tests/OneMedia/src/com/android/onemedia/provider/OneMediaRouteProvider.java
deleted file mode 100644
index 5845e48..0000000
--- a/tests/OneMedia/src/com/android/onemedia/provider/OneMediaRouteProvider.java
+++ /dev/null
@@ -1,270 +0,0 @@
-/*
- * Copyright (C) 2014 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.onemedia.provider;
-
-import android.media.routing.MediaRouteSelector;
-import android.media.routing.MediaRouteService;
-import android.media.routing.MediaRouter.ConnectionInfo;
-import android.media.routing.MediaRouter.ConnectionRequest;
-import android.media.routing.MediaRouter.DestinationInfo;
-import android.media.routing.MediaRouter.DiscoveryRequest;
-import android.media.routing.MediaRouter.RouteInfo;
-import android.media.session.PlaybackState;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.Process;
-import android.support.media.protocols.MediaPlayerProtocol;
-import android.support.media.protocols.MediaPlayerProtocol.MediaInfo;
-import android.support.media.protocols.MediaPlayerProtocol.MediaStatus;
-import android.os.Looper;
-import android.os.ResultReceiver;
-import android.os.SystemClock;
-import android.util.Log;
-
-import com.android.onemedia.playback.LocalRenderer;
-import com.android.onemedia.playback.Renderer;
-import com.android.onemedia.playback.RequestUtils;
-
-import java.util.ArrayList;
-
-/**
- * Test of MediaRouteProvider. Show a dummy provider with a simple interface for
- * playing music.
- */
-public class OneMediaRouteProvider extends MediaRouteService {
-    private static final String TAG = "OneMRP";
-    private static final boolean DEBUG = true;
-
-    private static final String TEST_DESTINATION_ID = "testDestination";
-    private static final String TEST_ROUTE_ID = "testRoute";
-
-    private Renderer mRenderer;
-    private RenderListener mRenderListener;
-    private PlaybackState mPlaybackState;
-    private Handler mHandler;
-
-    private OneStub mStub;
-
-    @Override
-    public void onCreate() {
-        mHandler = new Handler();
-        mRenderer = new LocalRenderer(this, null);
-        mRenderListener = new RenderListener();
-        PlaybackState.Builder bob = new PlaybackState.Builder();
-        bob.setActions(PlaybackState.ACTION_PAUSE | PlaybackState.ACTION_PLAY);
-        mPlaybackState = bob.build();
-
-        mRenderer.registerListener(mRenderListener);
-    }
-
-    @Override
-    public ClientSession onCreateClientSession(ClientInfo client) {
-        if (client.getUid() != Process.myUid()) {
-            // for testing purposes, only allow connections from this application
-            // since this provider is not fully featured
-            return null;
-        }
-        return new OneSession(client);
-    }
-
-    private final class OneSession extends ClientSession {
-        private final ClientInfo mClient;
-
-        public OneSession(ClientInfo client) {
-            mClient = client;
-        }
-
-        @Override
-        public boolean onStartDiscovery(DiscoveryRequest req, DiscoveryCallback callback) {
-            for (MediaRouteSelector selector : req.getSelectors()) {
-                if (isMatch(selector)) {
-                    DestinationInfo destination = new DestinationInfo.Builder(
-                            TEST_DESTINATION_ID, getServiceMetadata(), "OneMedia")
-                            .setDescription("Test route from OneMedia app.")
-                            .build();
-                    ArrayList<RouteInfo> routes = new ArrayList<RouteInfo>();
-                    routes.add(new RouteInfo.Builder(
-                            TEST_ROUTE_ID, destination, selector).build());
-                    callback.onDestinationFound(destination, routes);
-                    return true;
-                }
-            }
-            return false;
-        }
-
-        @Override
-        public void onStopDiscovery() {
-        }
-
-        @Override
-        public boolean onConnect(ConnectionRequest req, ConnectionCallback callback) {
-            if (req.getRoute().getId().equals(TEST_ROUTE_ID)) {
-                mStub = new OneStub();
-                ConnectionInfo connection = new ConnectionInfo.Builder(req.getRoute())
-                        .setProtocolStub(MediaPlayerProtocol.class, mStub)
-                        .build();
-                callback.onConnected(connection);
-                return true;
-            }
-            return false;
-        }
-
-        @Override
-        public void onDisconnect() {
-            mStub = null;
-        }
-
-        private boolean isMatch(MediaRouteSelector selector) {
-            if (!selector.containsProtocol(MediaPlayerProtocol.class)) {
-                return false;
-            }
-            for (String protocol : selector.getRequiredProtocols()) {
-                if (!protocol.equals(MediaPlayerProtocol.class.getName())) {
-                    return false;
-                }
-            }
-            return true;
-        }
-    }
-
-    private final class OneStub extends MediaPlayerProtocol.Stub {
-        MediaInfo mMediaInfo;
-
-        public OneStub() {
-            super(mHandler);
-        }
-
-        @Override
-        public void onLoad(MediaInfo mediaInfo, boolean autoplay, long playPosition,
-                Bundle extras) {
-            if (DEBUG) {
-                Log.d(TAG, "Attempting to play " + mediaInfo.getContentId());
-            }
-            // look up the route and send a play command to it
-            mMediaInfo = mediaInfo;
-            Bundle bundle = new Bundle();
-            bundle.putString(RequestUtils.EXTRA_KEY_SOURCE, mediaInfo.getContentId());
-            mRenderer.setContent(bundle);
-        }
-
-        @Override
-        public void onPlay(Bundle extras) {
-            mRenderer.onPlay();
-        }
-
-        @Override
-        public void onPause(Bundle extras) {
-            mRenderer.onPause();
-        }
-    }
-
-    private class RenderListener implements Renderer.Listener {
-
-        @Override
-        public void onError(int type, int extra, Bundle extras, Throwable error) {
-            Log.d(TAG, "Sending onError with type " + type + " and extra " + extra);
-            sendStatusUpdate(PlaybackState.STATE_ERROR);
-        }
-
-        @Override
-        public void onStateChanged(int newState) {
-            long position = -1;
-            if (mRenderer != null) {
-                position = mRenderer.getSeekPosition();
-            }
-            int pbState;
-            float rate = 0;
-            String errorMsg = null;
-            switch (newState) {
-                case Renderer.STATE_ENDED:
-                case Renderer.STATE_STOPPED:
-                    pbState = PlaybackState.STATE_STOPPED;
-                    break;
-                case Renderer.STATE_INIT:
-                case Renderer.STATE_PREPARING:
-                    pbState = PlaybackState.STATE_BUFFERING;
-                    break;
-                case Renderer.STATE_ERROR:
-                    pbState = PlaybackState.STATE_ERROR;
-                    break;
-                case Renderer.STATE_PAUSED:
-                    pbState = PlaybackState.STATE_PAUSED;
-                    break;
-                case Renderer.STATE_PLAYING:
-                    pbState = PlaybackState.STATE_PLAYING;
-                    rate = 1;
-                    break;
-                default:
-                    pbState = PlaybackState.STATE_ERROR;
-                    errorMsg = "unknown state";
-                    break;
-            }
-            PlaybackState.Builder bob = new PlaybackState.Builder(mPlaybackState);
-            bob.setState(pbState, position, rate, SystemClock.elapsedRealtime());
-            bob.setErrorMessage(errorMsg);
-            mPlaybackState = bob.build();
-
-            sendStatusUpdate(mPlaybackState.getState());
-        }
-
-        @Override
-        public void onBufferingUpdate(int percent) {
-        }
-
-        @Override
-        public void onFocusLost() {
-            Log.d(TAG, "Focus lost, pausing");
-            // Don't update state here, we'll get a separate call to
-            // onStateChanged when it pauses
-            mRenderer.onPause();
-        }
-
-        @Override
-        public void onNextStarted() {
-        }
-
-        private void sendStatusUpdate(int state) {
-            if (mStub != null) {
-                MediaStatus status = new MediaStatus(1, mStub.mMediaInfo);
-                switch (state) {
-                    case PlaybackState.STATE_BUFFERING:
-                    case PlaybackState.STATE_FAST_FORWARDING:
-                    case PlaybackState.STATE_REWINDING:
-                    case PlaybackState.STATE_SKIPPING_TO_NEXT:
-                    case PlaybackState.STATE_SKIPPING_TO_PREVIOUS:
-                        status.setPlayerState(MediaStatus.PLAYER_STATE_BUFFERING);
-                        break;
-                    case PlaybackState.STATE_CONNECTING:
-                    case PlaybackState.STATE_STOPPED:
-                        status.setPlayerState(MediaStatus.PLAYER_STATE_IDLE);
-                        break;
-                    case PlaybackState.STATE_PAUSED:
-                        status.setPlayerState(MediaStatus.PLAYER_STATE_PAUSED);
-                        break;
-                    case PlaybackState.STATE_PLAYING:
-                        status.setPlayerState(MediaStatus.PLAYER_STATE_PLAYING);
-                        break;
-                    case PlaybackState.STATE_NONE:
-                    case PlaybackState.STATE_ERROR:
-                    default:
-                        status.setPlayerState(MediaStatus.PLAYER_STATE_UNKNOWN);
-                        break;
-                }
-                mStub.sendStatusUpdatedEvent(status, null);
-            }
-        }
-    }
-}
diff --git a/tests/RenderScriptTests/FountainFbo/Android.mk b/tests/RenderScriptTests/FountainFbo/Android.mk
index 4535eb1..c0f3323 100644
--- a/tests/RenderScriptTests/FountainFbo/Android.mk
+++ b/tests/RenderScriptTests/FountainFbo/Android.mk
@@ -25,5 +25,6 @@
 # LOCAL_SDK_VERSION := current
 
 LOCAL_PACKAGE_NAME := RsFountainFbo
+LOCAL_SDK_VERSION := 14
 
 include $(BUILD_PACKAGE)
diff --git a/tests/Split/Android.mk b/tests/Split/Android.mk
index 7884d4d..b068bef 100644
--- a/tests/Split/Android.mk
+++ b/tests/Split/Android.mk
@@ -20,8 +20,7 @@
 LOCAL_SRC_FILES := $(call all-subdir-java-files)
 LOCAL_PACKAGE_NAME := Split
 
-LOCAL_AAPT_FLAGS := --split fr,de
-LOCAL_AAPT_FLAGS += -v
+LOCAL_PACKAGE_SPLITS := mdpi-v4 hdpi-v4 xhdpi-v4 xxhdpi-v4
 
 LOCAL_MODULE_TAGS := tests
 
diff --git a/tests/Split/AndroidManifest.xml b/tests/Split/AndroidManifest.xml
index a4956a7..0de8344 100644
--- a/tests/Split/AndroidManifest.xml
+++ b/tests/Split/AndroidManifest.xml
@@ -16,7 +16,8 @@
 
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
     package="com.android.example.split">
-    <application android:label="@string/app_title">
+    <application android:label="@string/app_title"
+            android:icon="@mipmap/ic_app">
         <activity android:name="ActivityMain">
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
diff --git a/tests/Split/res/drawable-hdpi/image.png b/tests/Split/res/drawable-hdpi/image.png
new file mode 100644
index 0000000..dcf4242
--- /dev/null
+++ b/tests/Split/res/drawable-hdpi/image.png
Binary files differ
diff --git a/tests/Split/res/drawable-mdpi/image.png b/tests/Split/res/drawable-mdpi/image.png
new file mode 100644
index 0000000..3437952
--- /dev/null
+++ b/tests/Split/res/drawable-mdpi/image.png
Binary files differ
diff --git a/tests/Split/res/drawable-xhdpi/image.png b/tests/Split/res/drawable-xhdpi/image.png
new file mode 100644
index 0000000..68b2f8e
--- /dev/null
+++ b/tests/Split/res/drawable-xhdpi/image.png
Binary files differ
diff --git a/tests/Split/res/drawable-xxhdpi/image.png b/tests/Split/res/drawable-xxhdpi/image.png
new file mode 100644
index 0000000..4bff9b9
--- /dev/null
+++ b/tests/Split/res/drawable-xxhdpi/image.png
Binary files differ
diff --git a/tests/Split/res/layout/main.xml b/tests/Split/res/layout/main.xml
index 36992a2..607cdb0 100644
--- a/tests/Split/res/layout/main.xml
+++ b/tests/Split/res/layout/main.xml
@@ -14,6 +14,12 @@
      limitations under the License.
 -->
 
-<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:layout_width="match_parent"
-    android:layout_height="match_parent"/>
+    android:layout_height="match_parent">
+    <ImageView
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_centerInParent="true"
+        android:src="@drawable/image"/>
+</RelativeLayout>
diff --git a/tests/Split/res/mipmap-hdpi/ic_app.png b/tests/Split/res/mipmap-hdpi/ic_app.png
new file mode 100644
index 0000000..ffcb9e5
--- /dev/null
+++ b/tests/Split/res/mipmap-hdpi/ic_app.png
Binary files differ
diff --git a/tests/Split/res/mipmap-mdpi/ic_app.png b/tests/Split/res/mipmap-mdpi/ic_app.png
new file mode 100644
index 0000000..35f5b45
--- /dev/null
+++ b/tests/Split/res/mipmap-mdpi/ic_app.png
Binary files differ
diff --git a/tests/Split/res/mipmap-xhdpi/ic_app.png b/tests/Split/res/mipmap-xhdpi/ic_app.png
new file mode 100644
index 0000000..bfe71fe
--- /dev/null
+++ b/tests/Split/res/mipmap-xhdpi/ic_app.png
Binary files differ
diff --git a/tests/Split/res/mipmap-xxhdpi/ic_app.png b/tests/Split/res/mipmap-xxhdpi/ic_app.png
new file mode 100644
index 0000000..b65532c
--- /dev/null
+++ b/tests/Split/res/mipmap-xxhdpi/ic_app.png
Binary files differ
diff --git a/tests/Split/res/mipmap-xxxhdpi/ic_app.png b/tests/Split/res/mipmap-xxxhdpi/ic_app.png
new file mode 100644
index 0000000..2679b49
--- /dev/null
+++ b/tests/Split/res/mipmap-xxxhdpi/ic_app.png
Binary files differ
diff --git a/tests/Split/res/values-xxhdpi/values.xml b/tests/Split/res/values-xxhdpi/values.xml
new file mode 100644
index 0000000..0b5f2d8
--- /dev/null
+++ b/tests/Split/res/values-xxhdpi/values.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <string name="app_title">Split APK XX-HDPI</string>
+</resources>
diff --git a/tests/Split/src/java/com/android/example/split/ActivityMain.java b/tests/Split/src/java/com/android/example/split/ActivityMain.java
index a15fb3c..63963a2 100644
--- a/tests/Split/src/java/com/android/example/split/ActivityMain.java
+++ b/tests/Split/src/java/com/android/example/split/ActivityMain.java
@@ -24,8 +24,6 @@
     @Override
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
-        TextView text = new TextView(this);
-        text.setText(R.string.test);
-        setContentView(text);
+        setContentView(R.layout.main);
     }
 }
diff --git a/tests/StatusBar/src/com/android/statusbartest/PowerTest.java b/tests/StatusBar/src/com/android/statusbartest/PowerTest.java
index 0cab10d..52527d9 100644
--- a/tests/StatusBar/src/com/android/statusbartest/PowerTest.java
+++ b/tests/StatusBar/src/com/android/statusbartest/PowerTest.java
@@ -77,9 +77,9 @@
                 mProx.release();
             }
         },
-        new Test("Disable proximity (WAIT_FOR_PROXIMITY_NEGATIVE)") {
+        new Test("Disable proximity (RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY") {
             public void run() {
-                mProx.release(PowerManager.WAIT_FOR_PROXIMITY_NEGATIVE);
+                mProx.release(PowerManager.RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY);
             }
         },
         new Test("Enable proximity, wait 5 seconds then disable") {
@@ -93,13 +93,14 @@
                 }, 5000);
             }
         },
-        new Test("Enable proximity, wait 5 seconds then disable  (WAIT_FOR_PROXIMITY_NEGATIVE)") {
+        new Test("Enable proximity, wait 5 seconds then disable " +
+                "(RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY)") {
             public void run() {
                 mProx.acquire();
                 mHandler.postDelayed(new Runnable() {
                     @Override
                     public void run() {
-                        mProx.release(PowerManager.WAIT_FOR_PROXIMITY_NEGATIVE);
+                        mProx.release(PowerManager.RELEASE_FLAG_WAIT_FOR_NO_PROXIMITY);
                     }
                 }, 5000);
             }
diff --git a/tests/UsageStatsTest/Android.mk b/tests/UsageStatsTest/Android.mk
index 69fefeb..5f7467a 100644
--- a/tests/UsageStatsTest/Android.mk
+++ b/tests/UsageStatsTest/Android.mk
@@ -6,6 +6,8 @@
 # Only compile source java files in this apk.
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
 
+LOCAL_STATIC_JAVA_LIBRARIES := android-support-v4
+
 LOCAL_PACKAGE_NAME := UsageStatsTest
 
 include $(BUILD_PACKAGE)
diff --git a/tests/UsageStatsTest/res/layout/config_row_item.xml b/tests/UsageStatsTest/res/layout/config_row_item.xml
new file mode 100644
index 0000000..547de04
--- /dev/null
+++ b/tests/UsageStatsTest/res/layout/config_row_item.xml
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<TextView xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@android:id/text1"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:paddingLeft="16dp"
+    android:paddingRight="16dp"/>
diff --git a/tests/UsageStatsTest/res/layout/row_item.xml b/tests/UsageStatsTest/res/layout/row_item.xml
index da50163..4f2bfe4 100644
--- a/tests/UsageStatsTest/res/layout/row_item.xml
+++ b/tests/UsageStatsTest/res/layout/row_item.xml
@@ -1,5 +1,6 @@
 <?xml version="1.0" encoding="utf-8"?>
-<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:orientation="horizontal"
     android:layout_width="match_parent"
     android:layout_height="match_parent"
     android:paddingLeft="16dp"
@@ -8,13 +9,10 @@
     <TextView android:id="@android:id/text1"
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:layout_alignParentLeft="true"
-        android:layout_centerVertical="true"
+        android:layout_weight="1"
         android:textStyle="bold"/>
 
     <TextView android:id="@android:id/text2"
         android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:layout_alignParentRight="true"
-        android:layout_alignBaseline="@android:id/text1"/>
-</RelativeLayout>
+        android:layout_height="wrap_content"/>
+</LinearLayout>
diff --git a/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageLogActivity.java b/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageLogActivity.java
index 5d8fc9e..d9a3b61 100644
--- a/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageLogActivity.java
+++ b/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageLogActivity.java
@@ -21,6 +21,7 @@
 import android.content.Context;
 import android.os.Bundle;
 import android.os.Handler;
+import android.support.v4.util.CircularArray;
 import android.view.LayoutInflater;
 import android.view.View;
 import android.view.ViewGroup;
@@ -35,11 +36,14 @@
     private UsageStatsManager mUsageStatsManager;
     private Adapter mAdapter;
     private Handler mHandler = new Handler();
+    private long mLastTime;
 
     @Override
     protected void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
         mUsageStatsManager = (UsageStatsManager) getSystemService(Context.USAGE_STATS_SERVICE);
+        mLastTime = System.currentTimeMillis() - USAGE_STATS_PERIOD;
+
         mAdapter = new Adapter();
         setListAdapter(mAdapter);
     }
@@ -59,24 +63,34 @@
     @Override
     public void run() {
         long now = System.currentTimeMillis();
-        long beginTime = now - USAGE_STATS_PERIOD;
-        UsageEvents events = mUsageStatsManager.queryEvents(beginTime, now);
-        mAdapter.update(events);
+        UsageEvents events = mUsageStatsManager.queryEvents(mLastTime, now);
+        long lastEventTime = mAdapter.update(events);
+        if (lastEventTime >= 0) {
+            mLastTime = lastEventTime + 1;
+        }
         mHandler.postDelayed(this, 1000 * 5);
     }
 
     private class Adapter extends BaseAdapter {
+        private static final int MAX_EVENTS = 50;
+        private final CircularArray<UsageEvents.Event> mEvents = new CircularArray<>(MAX_EVENTS);
 
-        private final ArrayList<UsageEvents.Event> mEvents = new ArrayList<>();
-
-        public void update(UsageEvents results) {
-            mEvents.clear();
+        public long update(UsageEvents results) {
+            long lastTimeStamp = -1;
             while (results.hasNextEvent()) {
                 UsageEvents.Event event = new UsageEvents.Event();
                 results.getNextEvent(event);
-                mEvents.add(event);
+                lastTimeStamp = event.getTimeStamp();
+                if (mEvents.size() == MAX_EVENTS) {
+                    mEvents.popLast();
+                }
+                mEvents.addFirst(event);
             }
-            notifyDataSetChanged();
+
+            if (lastTimeStamp != 0) {
+                notifyDataSetChanged();
+            }
+            return lastTimeStamp;
         }
 
         @Override
@@ -85,7 +99,7 @@
         }
 
         @Override
-        public Object getItem(int position) {
+        public UsageEvents.Event getItem(int position) {
             return mEvents.get(position);
         }
 
@@ -95,41 +109,72 @@
         }
 
         @Override
+        public int getItemViewType(int position) {
+            final int eventType = getItem(position).getEventType();
+            if (eventType == UsageEvents.Event.CONFIGURATION_CHANGE) {
+                return 1;
+            }
+            return 0;
+        }
+
+        @Override
         public View getView(int position, View convertView, ViewGroup parent) {
+            final UsageEvents.Event event = getItem(position);
+
             final ViewHolder holder;
             if (convertView == null) {
-                convertView = LayoutInflater.from(UsageLogActivity.this)
-                        .inflate(R.layout.row_item, parent, false);
                 holder = new ViewHolder();
-                holder.packageName = (TextView) convertView.findViewById(android.R.id.text1);
-                holder.state = (TextView) convertView.findViewById(android.R.id.text2);
+
+                if (event.getEventType() == UsageEvents.Event.CONFIGURATION_CHANGE) {
+                    convertView = LayoutInflater.from(UsageLogActivity.this)
+                            .inflate(R.layout.config_row_item, parent, false);
+                    holder.config = (TextView) convertView.findViewById(android.R.id.text1);
+                } else {
+                    convertView = LayoutInflater.from(UsageLogActivity.this)
+                            .inflate(R.layout.row_item, parent, false);
+                    holder.packageName = (TextView) convertView.findViewById(android.R.id.text1);
+                    holder.state = (TextView) convertView.findViewById(android.R.id.text2);
+                }
                 convertView.setTag(holder);
             } else {
                 holder = (ViewHolder) convertView.getTag();
             }
 
-            holder.packageName.setText(mEvents.get(position).getComponent().toShortString());
-            String state;
-            switch (mEvents.get(position).getEventType()) {
+            if (holder.packageName != null) {
+                holder.packageName.setText(event.getPackageName());
+            }
+
+            if (holder.state != null) {
+                holder.state.setText(eventToString(event.getEventType()));
+            }
+
+            if (holder.config != null &&
+                    event.getEventType() == UsageEvents.Event.CONFIGURATION_CHANGE) {
+                holder.config.setText(event.getConfiguration().toString());
+            }
+            return convertView;
+        }
+
+        private String eventToString(int eventType) {
+            switch (eventType) {
                 case UsageEvents.Event.MOVE_TO_FOREGROUND:
-                    state = "Foreground";
-                    break;
+                    return "Foreground";
 
                 case UsageEvents.Event.MOVE_TO_BACKGROUND:
-                    state = "Background";
-                    break;
+                    return "Background";
+
+                case UsageEvents.Event.CONFIGURATION_CHANGE:
+                    return "Config change";
 
                 default:
-                    state = "Unknown: " + mEvents.get(position).getEventType();
-                    break;
+                    return "Unknown: " + eventType;
             }
-            holder.state.setText(state);
-            return convertView;
         }
     }
 
     static class ViewHolder {
         public TextView packageName;
         public TextView state;
+        public TextView config;
     }
 }
diff --git a/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageStatsActivity.java b/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageStatsActivity.java
index b6591bd..c08c1a3 100644
--- a/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageStatsActivity.java
+++ b/tests/UsageStatsTest/src/com/android/tests/usagestats/UsageStatsActivity.java
@@ -23,7 +23,6 @@
 import android.content.Intent;
 import android.os.Bundle;
 import android.text.format.DateUtils;
-import android.util.ArrayMap;
 import android.view.LayoutInflater;
 import android.view.Menu;
 import android.view.MenuInflater;
@@ -36,6 +35,7 @@
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Comparator;
+import java.util.Map;
 
 public class UsageStatsActivity extends ListActivity {
     private static final long USAGE_STATS_PERIOD = 1000 * 60 * 60 * 24 * 14;
@@ -84,7 +84,7 @@
     private void updateAdapter() {
         long now = System.currentTimeMillis();
         long beginTime = now - USAGE_STATS_PERIOD;
-        ArrayMap<String, UsageStats> stats = mUsageStatsManager.queryAndAggregateUsageStats(
+        Map<String, UsageStats> stats = mUsageStatsManager.queryAndAggregateUsageStats(
                 beginTime, now);
         mAdapter.update(stats);
     }
@@ -92,17 +92,13 @@
     private class Adapter extends BaseAdapter {
         private ArrayList<UsageStats> mStats = new ArrayList<>();
 
-        public void update(ArrayMap<String, UsageStats> stats) {
+        public void update(Map<String, UsageStats> stats) {
             mStats.clear();
             if (stats == null) {
                 return;
             }
 
-            final int packageCount = stats.size();
-            for (int i = 0; i < packageCount; i++) {
-                mStats.add(stats.valueAt(i));
-            }
-
+            mStats.addAll(stats.values());
             Collections.sort(mStats, mComparator);
             notifyDataSetChanged();
         }
diff --git a/tests/VectorDrawableTest/res/anim/trim_path_animation06.xml b/tests/VectorDrawableTest/res/anim/trim_path_animation06.xml
new file mode 100644
index 0000000..1a81866
--- /dev/null
+++ b/tests/VectorDrawableTest/res/anim/trim_path_animation06.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2014 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.
+-->
+
+<set xmlns:android="http://schemas.android.com/apk/res/android">
+    <objectAnimator
+        android:duration="9000"
+        android:propertyName="alpha"
+        android:valueFrom="1.0"
+        android:valueTo="0.0"/>
+
+</set>
\ No newline at end of file
diff --git a/tests/VectorDrawableTest/res/drawable/animation_vector_drawable01.xml b/tests/VectorDrawableTest/res/drawable/animation_vector_drawable01.xml
index 19b82ad..8b0ceda 100644
--- a/tests/VectorDrawableTest/res/drawable/animation_vector_drawable01.xml
+++ b/tests/VectorDrawableTest/res/drawable/animation_vector_drawable01.xml
@@ -37,5 +37,8 @@
     <target
         android:name="rotationGroup"
         android:animation="@anim/trim_path_animation04" />
+    <target
+        android:name="rootGroup"
+        android:animation="@anim/trim_path_animation06" />
 
 </animated-vector>
\ No newline at end of file
diff --git a/tests/VectorDrawableTest/res/drawable/vector_drawable05.xml b/tests/VectorDrawableTest/res/drawable/vector_drawable05.xml
index bbf1a17..f94ecba1 100644
--- a/tests/VectorDrawableTest/res/drawable/vector_drawable05.xml
+++ b/tests/VectorDrawableTest/res/drawable/vector_drawable05.xml
@@ -28,7 +28,8 @@
                 l-5.046875,0.0 0.0-1.0Z" />
         <path
             android:name="two"
-            android:fillColor="#00ffff00"
+            android:fillColor="#ffff00"
+            android:fillAlpha="0"
             android:pathData="M 2.534375,9.6875l 4.140625,0.0 0.0,1.0-5.5625,0.0 0.0-1.0q 0.671875-0.6875 1.828125-1.859375
                         q 1.1718752-1.1875 1.4687502-1.53125 0.578125-0.625 0.796875-1.0625
                         q 0.234375-0.453125 0.234375-0.875 0.0-0.703125-0.5-1.140625
diff --git a/tests/VectorDrawableTest/res/drawable/vector_drawable12.xml b/tests/VectorDrawableTest/res/drawable/vector_drawable12.xml
index 2c8b751..69ae62c 100644
--- a/tests/VectorDrawableTest/res/drawable/vector_drawable12.xml
+++ b/tests/VectorDrawableTest/res/drawable/vector_drawable12.xml
@@ -14,10 +14,12 @@
      limitations under the License.
 -->
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:name="rootGroup"
         android:height="64dp"
         android:width="64dp"
         android:viewportHeight="600"
-        android:viewportWidth="600" >
+        android:viewportWidth="600"
+        android:alpha="0.5" >
 
     <group
         android:name="rotationGroup"
diff --git a/tests/VectorDrawableTest/res/drawable/vector_icon_schedule.xml b/tests/VectorDrawableTest/res/drawable/vector_icon_schedule.xml
index 1aad743..3f79968 100644
--- a/tests/VectorDrawableTest/res/drawable/vector_icon_schedule.xml
+++ b/tests/VectorDrawableTest/res/drawable/vector_icon_schedule.xml
@@ -21,10 +21,12 @@
 
     <group>
         <path
-            android:fillColor="#E6000000"
+            android:fillColor="#FF000000"
+            android:fillAlpha="0.9"
             android:pathData="M11.994999,2.0C6.4679985,2.0 2.0,6.4780006 2.0,12.0s4.468,10.0 9.995,10.0S22.0,17.522 22.0,12.0S17.521,2.0 11.994999,2.0zM12.0,20.0c-4.42,0.0 -8.0,-3.582 -8.0,-8.0s3.58,-8.0 8.0,-8.0s8.0,3.582 8.0,8.0S16.419998,20.0 12.0,20.0z" />
         <path
-            android:fillColor="#E6000000"
+            android:fillColor="#FF000000"
+            android:fillAlpha="0.9"
             android:pathData="M12.5,6.0l-1.5,0.0 0.0,7.0 5.3029995,3.1819992 0.75,-1.249999 -4.5529995,-2.7320004z" />
     </group>
 
diff --git a/tests/VectorDrawableTest/src/com/android/test/dynamic/AnimatedVectorDrawableTest.java b/tests/VectorDrawableTest/src/com/android/test/dynamic/AnimatedVectorDrawableTest.java
index f165cde..05bf166 100644
--- a/tests/VectorDrawableTest/src/com/android/test/dynamic/AnimatedVectorDrawableTest.java
+++ b/tests/VectorDrawableTest/src/com/android/test/dynamic/AnimatedVectorDrawableTest.java
@@ -31,6 +31,8 @@
             R.drawable.animation_vector_progress_bar,
             R.drawable.animation_vector_drawable_favorite,
             R.drawable.animation_vector_drawable01,
+            // Duplicate to test constant state.
+            R.drawable.animation_vector_drawable01,
     };
 
     @Override
diff --git a/tests/VoiceInteraction/src/com/android/test/voiceinteraction/MainInteractionService.java b/tests/VoiceInteraction/src/com/android/test/voiceinteraction/MainInteractionService.java
index 77c0c32..4639114 100644
--- a/tests/VoiceInteraction/src/com/android/test/voiceinteraction/MainInteractionService.java
+++ b/tests/VoiceInteraction/src/com/android/test/voiceinteraction/MainInteractionService.java
@@ -25,6 +25,7 @@
 import android.util.Log;
 
 import java.util.Arrays;
+import java.util.Locale;
 
 public class MainInteractionService extends VoiceInteractionService {
     static final String TAG = "MainInteractionService";
@@ -67,7 +68,8 @@
         Log.i(TAG, "Keyphrase enrollment meta-data: "
                 + Arrays.toString(getKeyphraseEnrollmentInfo().listKeyphraseMetadata()));
 
-        mHotwordDetector = createAlwaysOnHotwordDetector("Hello There", "en-US", mHotwordCallback);
+        mHotwordDetector = createAlwaysOnHotwordDetector(
+                "Hello There", Locale.forLanguageTag("en-US"), mHotwordCallback);
     }
 
     @Override
@@ -90,8 +92,7 @@
                 break;
             case AlwaysOnHotwordDetector.STATE_KEYPHRASE_UNENROLLED:
                 Log.i(TAG, "STATE_KEYPHRASE_UNENROLLED");
-                Intent enroll = mHotwordDetector.getManageIntent(
-                        AlwaysOnHotwordDetector.MANAGE_ACTION_ENROLL);
+                Intent enroll = mHotwordDetector.createEnrollIntent();
                 Log.i(TAG, "Need to enroll with " + enroll);
                 break;
             case AlwaysOnHotwordDetector.STATE_KEYPHRASE_ENROLLED:
diff --git a/tests/WallpaperTest/Android.mk b/tests/WallpaperTest/Android.mk
new file mode 100644
index 0000000..b4259cd
--- /dev/null
+++ b/tests/WallpaperTest/Android.mk
@@ -0,0 +1,15 @@
+LOCAL_PATH:= $(call my-dir)
+include $(CLEAR_VARS)
+
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_SRC_FILES := $(call all-java-files-under, src)
+
+LOCAL_RESOURCE_DIR := $(LOCAL_PATH)/res
+
+LOCAL_PACKAGE_NAME := WallpaperTest
+
+LOCAL_PROGUARD_ENABLED := disabled
+
+include $(BUILD_PACKAGE)
+
diff --git a/tests/WallpaperTest/AndroidManifest.xml b/tests/WallpaperTest/AndroidManifest.xml
new file mode 100644
index 0000000..4c914dd
--- /dev/null
+++ b/tests/WallpaperTest/AndroidManifest.xml
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="utf-8"?>
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+    package="com.example.wallpapertest" >
+
+    <uses-permission android:name="android.permission.SET_WALLPAPER_HINTS" />
+
+    <application
+        android:label="@string/app_name"
+        android:theme="@style/AppTheme" >
+        <activity
+            android:name=".MainActivity"
+            android:label="@string/app_name" >
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <category android:name="android.intent.category.LAUNCHER" />
+            </intent-filter>
+        </activity>
+
+        <service
+            android:label="@string/test_wallpaper"
+            android:name=".TestWallpaper"
+            android:permission="android.permission.BIND_WALLPAPER"
+            android:enabled="true">
+            <intent-filter>
+                <action android:name="android.service.wallpaper.WallpaperService" />
+            </intent-filter>
+            <meta-data android:name="android.service.wallpaper"
+                       android:resource="@xml/test_wallpaper" />
+        </service>
+    </application>
+</manifest>
diff --git a/tests/WallpaperTest/res/drawable-hdpi/test_wallpaper_thumb.png b/tests/WallpaperTest/res/drawable-hdpi/test_wallpaper_thumb.png
new file mode 100644
index 0000000..df92eb5
--- /dev/null
+++ b/tests/WallpaperTest/res/drawable-hdpi/test_wallpaper_thumb.png
Binary files differ
diff --git a/tests/WallpaperTest/res/layout/activity_main.xml b/tests/WallpaperTest/res/layout/activity_main.xml
new file mode 100644
index 0000000..d968396
--- /dev/null
+++ b/tests/WallpaperTest/res/layout/activity_main.xml
@@ -0,0 +1,177 @@
+<?xml version="1.0" encoding="utf-8"?>
+<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
+    android:layout_width="match_parent"
+    android:layout_height="match_parent"
+    android:background="@color/window_background">
+
+    <LinearLayout
+        android:layout_width="match_parent"
+        android:layout_height="match_parent"
+        android:orientation="vertical">
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="horizontal">
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="@string/dimens"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/width"/>
+            <EditText
+                android:id="@+id/dimen_width"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberDecimal"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/height"/>
+            <EditText
+                android:id="@+id/dimen_height"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberDecimal"/>
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="horizontal">
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="@string/wallpaper_offset"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/x"/>
+            <EditText
+                android:id="@+id/walloff_x"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberDecimal"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/y"/>
+            <EditText
+                android:id="@+id/walloff_y"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberDecimal"/>
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="horizontal">
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="@string/padding"/>
+            <LinearLayout
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:orientation="vertical">
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:orientation="horizontal">
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="15dp"
+                        android:textSize="17sp"
+                        android:text="@string/left"/>
+                    <EditText
+                        android:id="@+id/padding_left"
+                        android:layout_width="60sp"
+                        android:layout_height="wrap_content"
+                        android:inputType="number"/>
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="15dp"
+                        android:textSize="17sp"
+                        android:text="@string/right"/>
+                    <EditText
+                        android:id="@+id/padding_right"
+                        android:layout_width="60sp"
+                        android:layout_height="wrap_content"
+                        android:inputType="number"/>
+                </LinearLayout>
+                <LinearLayout
+                    android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:orientation="horizontal">
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="15dp"
+                        android:textSize="17sp"
+                        android:text="@string/top"/>
+                    <EditText
+                        android:id="@+id/padding_top"
+                        android:layout_width="60sp"
+                        android:layout_height="wrap_content"
+                        android:inputType="number"/>
+                    <TextView
+                        android:layout_width="wrap_content"
+                        android:layout_height="wrap_content"
+                        android:layout_marginLeft="15dp"
+                        android:textSize="17sp"
+                        android:text="@string/bottom"/>
+                    <EditText
+                        android:id="@+id/padding_bottom"
+                        android:layout_width="60sp"
+                        android:layout_height="wrap_content"
+                        android:inputType="number"/>
+                </LinearLayout>
+            </LinearLayout>
+        </LinearLayout>
+
+        <LinearLayout
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:orientation="horizontal">
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:text="@string/display_offset"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/x"/>
+            <EditText
+                android:id="@+id/dispoff_x"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberSigned"/>
+            <TextView
+                android:layout_width="wrap_content"
+                android:layout_height="wrap_content"
+                android:layout_marginLeft="15dp"
+                android:textSize="17sp"
+                android:text="@string/y"/>
+            <EditText
+                android:id="@+id/dispoff_y"
+                android:layout_width="60sp"
+                android:layout_height="wrap_content"
+                android:inputType="numberSigned"/>
+        </LinearLayout>
+    </LinearLayout>
+</ScrollView>
diff --git a/tests/WallpaperTest/res/values-v11/styles.xml b/tests/WallpaperTest/res/values-v11/styles.xml
new file mode 100644
index 0000000..95000b2
--- /dev/null
+++ b/tests/WallpaperTest/res/values-v11/styles.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Copyright 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.
+-->
+
+<resources>
+
+    <!--
+        Base application theme for API 11+. This theme completely replaces
+        AppBaseTheme from res/values/styles.xml on API 11+ devices.
+    -->
+    <style name="AppBaseTheme" parent="android:Theme.Holo.Wallpaper">
+        <!-- API 11 theme customizations can go here. -->
+    </style>
+
+</resources>
\ No newline at end of file
diff --git a/tests/WallpaperTest/res/values-v21/styles.xml b/tests/WallpaperTest/res/values-v21/styles.xml
new file mode 100644
index 0000000..e42d526
--- /dev/null
+++ b/tests/WallpaperTest/res/values-v21/styles.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Copyright 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.
+-->
+
+<resources>
+
+    <!--
+        Base application theme for API 21+. This theme completely replaces
+        AppBaseTheme from BOTH res/values/styles.xml and
+        res/values-v11/styles.xml on API 14+ devices.
+    -->
+    <style name="AppBaseTheme" parent="android:Theme.Material.Wallpaper">
+        <!-- API 14 theme customizations can go here. -->
+    </style>
+
+</resources>
\ No newline at end of file
diff --git a/tests/WallpaperTest/res/values/colors.xml b/tests/WallpaperTest/res/values/colors.xml
new file mode 100644
index 0000000..8c08249
--- /dev/null
+++ b/tests/WallpaperTest/res/values/colors.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  ~ Copyright (C) 2014 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
+  -->
+<resources>
+    <color name="window_background">#80000000</color>
+</resources>
\ No newline at end of file
diff --git a/tests/WallpaperTest/res/values/strings.xml b/tests/WallpaperTest/res/values/strings.xml
new file mode 100644
index 0000000..fd21259
--- /dev/null
+++ b/tests/WallpaperTest/res/values/strings.xml
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Copyright 2014 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.
+-->
+
+<resources>
+    <string name="app_name">Wallpaper Test</string>
+
+    <string name="test_wallpaper">Test Wallpaper</string>
+    <string name="test_wallpaper_author">Google</string>
+    <string name="test_wallpaper_desc">
+        Test wallpaper for use with the wallpaper test app.
+    </string>
+
+    <string name="dimens">Dimens: </string>
+    <string name="width">Width: </string>
+    <string name="height">Height: </string>
+
+    <string name="wallpaper_offset">Wall off: </string>
+    <string name="x">X: </string>
+    <string name="y">Y: </string>
+
+    <string name="padding">Padding: </string>
+    <string name="left">Left: </string>
+    <string name="right">Right: </string>
+    <string name="top">Top: </string>
+    <string name="bottom">Bottom: </string>
+
+    <string name="display_offset">Disp off: </string>
+</resources>
diff --git a/tests/WallpaperTest/res/values/styles.xml b/tests/WallpaperTest/res/values/styles.xml
new file mode 100644
index 0000000..d2b91d6
--- /dev/null
+++ b/tests/WallpaperTest/res/values/styles.xml
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Copyright 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.
+-->
+
+<resources>
+
+    <!--
+        Base application theme, dependent on API level. This theme is replaced
+        by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
+    -->
+    <style name="AppBaseTheme" parent="android:Theme.Wallpaper">
+        <!--
+            Theme customizations available in newer API levels can go in
+            res/values-vXX/styles.xml, while customizations related to
+            backward-compatibility can go here.
+        -->
+    </style>
+
+    <!-- Application theme. -->
+    <style name="AppTheme" parent="AppBaseTheme">
+        <!-- All customizations that are NOT specific to a particular API-level can go here. -->
+    </style>
+
+</resources>
\ No newline at end of file
diff --git a/tests/WallpaperTest/res/xml/test_wallpaper.xml b/tests/WallpaperTest/res/xml/test_wallpaper.xml
new file mode 100644
index 0000000..9f7d714
--- /dev/null
+++ b/tests/WallpaperTest/res/xml/test_wallpaper.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/**
+ * Copyright (c) 2008, 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.
+ */
+-->
+
+<!-- The attributes in this XML file provide configuration information -->
+<!-- about the polar clock. -->
+
+<wallpaper xmlns:android="http://schemas.android.com/apk/res/android"
+    android:author="@string/test_wallpaper_author"
+    android:description="@string/test_wallpaper_desc"
+    android:thumbnail="@drawable/test_wallpaper_thumb" />
diff --git a/tests/WallpaperTest/src/com/example/wallpapertest/MainActivity.java b/tests/WallpaperTest/src/com/example/wallpapertest/MainActivity.java
new file mode 100644
index 0000000..7880f67
--- /dev/null
+++ b/tests/WallpaperTest/src/com/example/wallpapertest/MainActivity.java
@@ -0,0 +1,176 @@
+/*
+ * Copyright 2014 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.example.wallpapertest;
+
+import android.app.Activity;
+import android.app.WallpaperManager;
+import android.content.Context;
+import android.graphics.Point;
+import android.graphics.Rect;
+import android.os.Bundle;
+import android.os.IBinder;
+import android.text.Editable;
+import android.text.TextUtils;
+import android.text.TextWatcher;
+import android.util.Log;
+import android.view.WindowManager;
+import android.widget.TextView;
+
+public class MainActivity extends Activity {
+    private static final String TAG = "MainActivity";
+
+    WallpaperManager mWallpaperManager;
+    WindowManager mWindowManager;
+
+    TextView mDimenWidthView;
+    TextView mDimenHeightView;
+
+    TextView mWallOffXView;
+    TextView mWallOffYView;
+
+    TextView mPaddingLeftView;
+    TextView mPaddingRightView;
+    TextView mPaddingTopView;
+    TextView mPaddingBottomView;
+
+    TextView mDispOffXView;
+    TextView mDispOffYView;
+
+    @Override
+    public void onCreate(Bundle savedInstanceState) {
+        super.onCreate(savedInstanceState);
+        setContentView(R.layout.activity_main);
+
+        mWallpaperManager = (WallpaperManager)getSystemService(Context.WALLPAPER_SERVICE);
+        mWindowManager = (WindowManager)getSystemService(Context.WINDOW_SERVICE);
+
+        mDimenWidthView = (TextView) findViewById(R.id.dimen_width);
+        mDimenWidthView.addTextChangedListener(mTextWatcher);
+        mDimenHeightView = (TextView) findViewById(R.id.dimen_height);
+        mDimenHeightView.addTextChangedListener(mTextWatcher);
+
+        mWallOffXView = (TextView) findViewById(R.id.walloff_x);
+        mWallOffXView.addTextChangedListener(mTextWatcher);
+        mWallOffYView = (TextView) findViewById(R.id.walloff_y);
+        mWallOffYView.addTextChangedListener(mTextWatcher);
+
+        mPaddingLeftView = (TextView) findViewById(R.id.padding_left);
+        mPaddingLeftView.addTextChangedListener(mTextWatcher);
+        mPaddingRightView = (TextView) findViewById(R.id.padding_right);
+        mPaddingRightView.addTextChangedListener(mTextWatcher);
+        mPaddingTopView = (TextView) findViewById(R.id.padding_top);
+        mPaddingTopView.addTextChangedListener(mTextWatcher);
+        mPaddingBottomView = (TextView) findViewById(R.id.padding_bottom);
+        mPaddingBottomView.addTextChangedListener(mTextWatcher);
+
+        mDispOffXView = (TextView) findViewById(R.id.dispoff_x);
+        mDispOffXView.addTextChangedListener(mTextWatcher);
+        mDispOffYView = (TextView) findViewById(R.id.dispoff_y);
+        mDispOffYView.addTextChangedListener(mTextWatcher);
+
+        updateDimens();
+        updateWallOff();
+        updatePadding();
+        updateDispOff();
+    }
+
+    private int loadPropIntText(TextView view, int baseVal) {
+        String str = view.getText().toString();
+        if (str != null && !TextUtils.isEmpty(str)) {
+            try {
+                float fval = Float.parseFloat(str);
+                return (int)(fval*baseVal);
+            } catch (NumberFormatException e) {
+                Log.i(TAG, "Bad number: " + str, e);
+            }
+        }
+        return baseVal;
+    }
+
+    private float loadFloatText(TextView view) {
+        String str = view.getText().toString();
+        if (str != null && !TextUtils.isEmpty(str)) {
+            try {
+                return Float.parseFloat(str);
+            } catch (NumberFormatException e) {
+                Log.i(TAG, "Bad number: " + str, e);
+            }
+        }
+        return 0;
+    }
+
+    private int loadIntText(TextView view) {
+        String str = view.getText().toString();
+        if (str != null && !TextUtils.isEmpty(str)) {
+            try {
+                return Integer.parseInt(str);
+            } catch (NumberFormatException e) {
+                Log.i(TAG, "Bad number: " + str, e);
+            }
+        }
+        return 0;
+    }
+
+    public void updateDimens() {
+        Point minDims = new Point();
+        Point maxDims = new Point();
+        mWindowManager.getDefaultDisplay().getCurrentSizeRange(minDims, maxDims);
+        mWallpaperManager.suggestDesiredDimensions(
+                loadPropIntText(mDimenWidthView, maxDims.x),
+                loadPropIntText(mDimenHeightView, maxDims.y));
+    }
+
+    public void updateWallOff() {
+        IBinder token = getWindow().getDecorView().getWindowToken();
+        if (token != null) {
+            mWallpaperManager.setWallpaperOffsets(token, loadFloatText(mWallOffXView),
+                    loadFloatText(mWallOffYView));
+        }
+    }
+
+    public void updatePadding() {
+        Rect padding = new Rect();
+        padding.left = loadIntText(mPaddingLeftView);
+        padding.top = loadIntText(mPaddingTopView);
+        padding.right = loadIntText(mPaddingRightView);
+        padding.bottom = loadIntText(mPaddingBottomView);
+        mWallpaperManager.setDisplayPadding(padding);
+    }
+
+    public void updateDispOff() {
+        IBinder token = getWindow().getDecorView().getWindowToken();
+        if (token != null) {
+            mWallpaperManager.setDisplayOffset(token, loadIntText(mDispOffXView),
+                    loadIntText(mDispOffYView));
+        }
+    }
+
+    final TextWatcher mTextWatcher = new TextWatcher() {
+        @Override public void beforeTextChanged(CharSequence s, int start, int count, int after) {
+        }
+
+        @Override public void onTextChanged(CharSequence s, int start, int before, int count) {
+            updateDimens();
+            updateWallOff();
+            updatePadding();
+            updateDispOff();
+        }
+
+        @Override public void afterTextChanged(Editable s) {
+        }
+    };
+}
diff --git a/tests/WallpaperTest/src/com/example/wallpapertest/TestWallpaper.java b/tests/WallpaperTest/src/com/example/wallpapertest/TestWallpaper.java
new file mode 100644
index 0000000..95db6d1
--- /dev/null
+++ b/tests/WallpaperTest/src/com/example/wallpapertest/TestWallpaper.java
@@ -0,0 +1,251 @@
+/*
+ * Copyright (C) 2014 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.example.wallpapertest;
+
+import android.service.wallpaper.WallpaperService;
+import android.graphics.Canvas;
+import android.graphics.Rect;
+import android.graphics.Paint;
+import android.graphics.Color;
+import android.graphics.RectF;
+import android.text.TextPaint;
+import android.view.SurfaceHolder;
+import android.content.res.XmlResourceParser;
+
+import android.os.Handler;
+import android.util.Log;
+
+import android.view.WindowInsets;
+
+public class TestWallpaper extends WallpaperService {
+    private static final String LOG_TAG = "PolarClock";
+    
+    private final Handler mHandler = new Handler();
+
+    @Override
+    public void onCreate() {
+        super.onCreate();
+    }
+
+    @Override
+    public void onDestroy() {
+        super.onDestroy();
+    }
+
+    public Engine onCreateEngine() {
+        return new ClockEngine();
+    }
+
+    class ClockEngine extends Engine {
+        private static final int OUTER_COLOR = 0xffff0000;
+        private static final int INNER_COLOR = 0xff000080;
+        private static final int STABLE_COLOR = 0xa000ff00;
+        private static final int TEXT_COLOR = 0xa0ffffff;
+
+        private final Paint.FontMetrics mTextMetrics = new Paint.FontMetrics();
+
+        private int mPadding;
+
+        private final Rect mMainInsets = new Rect();
+        private final Rect mStableInsets = new Rect();
+        private boolean mRound = false;
+
+        private int mDesiredWidth;
+        private int mDesiredHeight;
+
+        private float mOffsetX;
+        private float mOffsetY;
+        private float mOffsetXStep;
+        private float mOffsetYStep;
+        private int mOffsetXPixels;
+        private int mOffsetYPixels;
+
+        private final Paint mFillPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
+        private final Paint mStrokePaint = new Paint(Paint.ANTI_ALIAS_FLAG);
+        private final TextPaint mTextPaint = new TextPaint(Paint.ANTI_ALIAS_FLAG);
+
+        private final Runnable mDrawClock = new Runnable() {
+            public void run() {
+                drawFrame();
+            }
+        };
+        private boolean mVisible;
+
+        ClockEngine() {
+        }
+
+        @Override
+        public void onCreate(SurfaceHolder surfaceHolder) {
+            super.onCreate(surfaceHolder);
+
+            mDesiredWidth = getDesiredMinimumWidth();
+            mDesiredHeight = getDesiredMinimumHeight();
+
+            Paint paint = mFillPaint;
+            paint.setStyle(Paint.Style.FILL);
+
+            paint = mStrokePaint;
+            paint.setStrokeWidth(3);
+            paint.setStrokeCap(Paint.Cap.ROUND);
+            paint.setStyle(Paint.Style.STROKE);
+
+            TextPaint tpaint = mTextPaint;
+            tpaint.density = getResources().getDisplayMetrics().density;
+            tpaint.setCompatibilityScaling(getResources().getCompatibilityInfo().applicationScale);
+            tpaint.setColor(TEXT_COLOR);
+            tpaint.setTextSize(18 * getResources().getDisplayMetrics().scaledDensity);
+            tpaint.setShadowLayer(4 * getResources().getDisplayMetrics().density, 0, 0, 0xff000000);
+
+            mTextPaint.getFontMetrics(mTextMetrics);
+
+            mPadding = (int)(16 * getResources().getDisplayMetrics().density);
+
+            if (isPreview()) {
+                mOffsetX = 0.5f;
+                mOffsetY = 0.5f;
+            }
+        }
+
+        @Override
+        public void onDestroy() {
+            super.onDestroy();
+            mHandler.removeCallbacks(mDrawClock);
+        }
+
+        @Override
+        public void onVisibilityChanged(boolean visible) {
+            mVisible = visible;
+            if (!visible) {
+                mHandler.removeCallbacks(mDrawClock);
+            }
+            drawFrame();
+        }
+
+        @Override
+        public void onSurfaceChanged(SurfaceHolder holder, int format, int width, int height) {
+            super.onSurfaceChanged(holder, format, width, height);
+            drawFrame();
+        }
+
+        @Override
+        public void onSurfaceCreated(SurfaceHolder holder) {
+            super.onSurfaceCreated(holder);
+        }
+
+        @Override
+        public void onSurfaceDestroyed(SurfaceHolder holder) {
+            super.onSurfaceDestroyed(holder);
+            mVisible = false;
+            mHandler.removeCallbacks(mDrawClock);
+        }
+
+        @Override
+        public void onApplyWindowInsets(WindowInsets insets) {
+            super.onApplyWindowInsets(insets);
+            mMainInsets.set(insets.getSystemWindowInsetLeft(), insets.getSystemWindowInsetTop(),
+                    insets.getSystemWindowInsetRight(), insets.getSystemWindowInsetBottom());
+            mStableInsets.set(insets.getStableInsetLeft(), insets.getStableInsetTop(),
+                    insets.getStableInsetRight(), insets.getStableInsetBottom());
+            mRound = insets.isRound();
+            drawFrame();
+        }
+
+        @Override
+        public void onDesiredSizeChanged(int desiredWidth, int desiredHeight) {
+            super.onDesiredSizeChanged(desiredWidth, desiredHeight);
+            mDesiredWidth = desiredWidth;
+            mDesiredHeight = desiredHeight;
+            drawFrame();
+        }
+
+        @Override
+        public void onOffsetsChanged(float xOffset, float yOffset,
+                float xStep, float yStep, int xPixels, int yPixels) {
+            super.onOffsetsChanged(xOffset, yOffset, xStep, yStep, xPixels, yPixels);
+
+            if (isPreview()) return;
+
+            mOffsetX = xOffset;
+            mOffsetY = yOffset;
+            mOffsetXStep = xStep;
+            mOffsetYStep = yStep;
+            mOffsetXPixels = xPixels;
+            mOffsetYPixels = yPixels;
+
+            drawFrame();
+        }
+
+        void drawFrame() {
+            final SurfaceHolder holder = getSurfaceHolder();
+            final Rect frame = holder.getSurfaceFrame();
+            final int width = frame.width();
+            final int height = frame.height();
+
+            Canvas c = null;
+            try {
+                c = holder.lockCanvas();
+                if (c != null) {
+                    final Paint paint = mFillPaint;
+
+                    paint.setColor(OUTER_COLOR);
+                    c.drawRect(0, 0, width, height, paint);
+
+                    paint.setColor(INNER_COLOR);
+                    c.drawRect(0+mMainInsets.left, 0+mMainInsets.top,
+                            width-mMainInsets.right, height-mMainInsets.bottom, paint);
+
+                    mStrokePaint.setColor(STABLE_COLOR);
+                    c.drawRect(0 + mStableInsets.left, 0 + mStableInsets.top,
+                            width - mStableInsets.right, height - mStableInsets.bottom,
+                            mStrokePaint);
+
+                    final int ascdesc = (int)(-mTextMetrics.ascent + mTextMetrics.descent);
+                    final int linegap = (int)(-mTextMetrics.ascent + mTextMetrics.descent
+                            + mTextMetrics.leading);
+
+                    int x = mStableInsets.left + mPadding;
+                    int y = height - mStableInsets.bottom - mPadding - ascdesc;
+                    c.drawText("Surface Size: " + width + " x " + height,
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("Desired Size: " + mDesiredWidth + " x " + mDesiredHeight,
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("Cur Offset Raw: " + mOffsetX + ", " + mOffsetY,
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("Cur Offset Step: " + mOffsetXStep + ", " + mOffsetYStep,
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("Cur Offset Pixels: " + mOffsetXPixels + ", " + mOffsetYPixels,
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("Stable Insets: (" + mStableInsets.left + ", " + mStableInsets.top
+                            + ") - (" + mStableInsets.right + ", " + mStableInsets.bottom + ")",
+                            x, y, mTextPaint);
+                    y -= linegap;
+                    c.drawText("System Insets: (" + mMainInsets.left + ", " + mMainInsets.top
+                            + ") - (" + mMainInsets.right + ", " + mMainInsets.bottom + ")",
+                            x, y, mTextPaint);
+
+                }
+            } finally {
+                if (c != null) holder.unlockCanvasAndPost(c);
+            }
+        }
+    }
+}
diff --git a/tools/aapt/AaptAssets.cpp b/tools/aapt/AaptAssets.cpp
index eead68c..117fc24 100644
--- a/tools/aapt/AaptAssets.cpp
+++ b/tools/aapt/AaptAssets.cpp
@@ -561,15 +561,17 @@
         return NO_ERROR;
     }
 
-#if 0
-    printf("Error adding file %s: group %s already exists in leaf=%s path=%s\n",
-            file->getSourceFile().string(),
-            file->getGroupEntry().toDirName(String8()).string(),
-            mLeaf.string(), mPath.string());
-#endif
+    // Check if the version is automatically applied. This is a common source of
+    // error.
+    ConfigDescription withoutVersion = file->getGroupEntry().toParams();
+    withoutVersion.version = 0;
+    AaptConfig::applyVersionForCompatibility(&withoutVersion);
 
-    SourcePos(file->getSourceFile(), -1).error("Duplicate file.\n%s: Original is here.",
-                                               getPrintableSource().string());
+    const sp<AaptFile>& originalFile = mFiles.valueAt(index);
+    SourcePos(file->getSourceFile(), -1)
+            .error("Duplicate file.\n%s: Original is here. %s",
+                   originalFile->getPrintableSource().string(),
+                   (withoutVersion.version != 0) ? "The version qualifier may be implied." : "");
     return UNKNOWN_ERROR;
 }
 
@@ -1592,6 +1594,11 @@
     return mIncludedAssets.getResources(false);
 }
 
+AssetManager& AaptAssets::getAssetManager()
+{
+    return mIncludedAssets;
+}
+
 void AaptAssets::print(const String8& prefix) const
 {
     String8 innerPrefix(prefix);
diff --git a/tools/aapt/AaptAssets.h b/tools/aapt/AaptAssets.h
index 0c2576a..3fc9f81 100644
--- a/tools/aapt/AaptAssets.h
+++ b/tools/aapt/AaptAssets.h
@@ -561,6 +561,7 @@
     status_t buildIncludedResources(Bundle* bundle);
     status_t addIncludedResources(const sp<AaptFile>& file);
     const ResTable& getIncludedResources() const;
+    AssetManager& getAssetManager();
 
     void print(const String8& prefix) const;
 
diff --git a/tools/aapt/AaptConfig.cpp b/tools/aapt/AaptConfig.cpp
index 69a9c7f..32a0cd3 100644
--- a/tools/aapt/AaptConfig.cpp
+++ b/tools/aapt/AaptConfig.cpp
@@ -255,6 +255,8 @@
                 != ResTable_config::SCREENLONG_ANY
             || config->density != ResTable_config::DENSITY_DEFAULT) {
         minSdk = SDK_DONUT;
+    } else if ((config->density == ResTable_config::DENSITY_ANY)) {
+        minSdk = SDK_L;
     }
 
     if (minSdk > config->sdkVersion) {
@@ -477,6 +479,11 @@
         return true;
     }
 
+    if (strcmp(name, "anydpi") == 0) {
+        if (out) out->density = ResTable_config::DENSITY_ANY;
+        return true;
+    }
+
     if (strcmp(name, "nodpi") == 0) {
         if (out) out->density = ResTable_config::DENSITY_NONE;
         return true;
diff --git a/tools/aapt/AaptXml.cpp b/tools/aapt/AaptXml.cpp
new file mode 100644
index 0000000..708e405
--- /dev/null
+++ b/tools/aapt/AaptXml.cpp
@@ -0,0 +1,184 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#include <androidfw/ResourceTypes.h>
+#include <utils/String8.h>
+
+#include "AaptXml.h"
+
+using namespace android;
+
+namespace AaptXml {
+
+static String8 getStringAttributeAtIndex(const ResXMLTree& tree, ssize_t attrIndex,
+        String8* outError) {
+    Res_value value;
+    if (tree.getAttributeValue(attrIndex, &value) < 0) {
+        if (outError != NULL) {
+            *outError = "could not find attribute at index";
+        }
+        return String8();
+    }
+
+    if (value.dataType != Res_value::TYPE_STRING) {
+        if (outError != NULL) {
+            *outError = "attribute is not a string value";
+        }
+        return String8();
+    }
+
+    size_t len;
+    const uint16_t* str = tree.getAttributeStringValue(attrIndex, &len);
+    return str ? String8(str, len) : String8();
+}
+
+static int32_t getIntegerAttributeAtIndex(const ResXMLTree& tree, ssize_t attrIndex,
+    int32_t defValue, String8* outError) {
+    Res_value value;
+    if (tree.getAttributeValue(attrIndex, &value) < 0) {
+        if (outError != NULL) {
+            *outError = "could not find attribute at index";
+        }
+        return defValue;
+    }
+
+    if (value.dataType < Res_value::TYPE_FIRST_INT
+            || value.dataType > Res_value::TYPE_LAST_INT) {
+        if (outError != NULL) {
+            *outError = "attribute is not an integer value";
+        }
+        return defValue;
+    }
+    return value.data;
+}
+
+
+ssize_t indexOfAttribute(const ResXMLTree& tree, uint32_t attrRes) {
+    size_t attrCount = tree.getAttributeCount();
+    for (size_t i = 0; i < attrCount; i++) {
+        if (tree.getAttributeNameResID(i) == attrRes) {
+            return (ssize_t)i;
+        }
+    }
+    return -1;
+}
+
+String8 getAttribute(const ResXMLTree& tree, const char* ns,
+        const char* attr, String8* outError) {
+    ssize_t idx = tree.indexOfAttribute(ns, attr);
+    if (idx < 0) {
+        return String8();
+    }
+    return getStringAttributeAtIndex(tree, idx, outError);
+}
+
+String8 getAttribute(const ResXMLTree& tree, uint32_t attrRes, String8* outError) {
+    ssize_t idx = indexOfAttribute(tree, attrRes);
+    if (idx < 0) {
+        return String8();
+    }
+    return getStringAttributeAtIndex(tree, idx, outError);
+}
+
+String8 getResolvedAttribute(const ResTable& resTable, const ResXMLTree& tree,
+        uint32_t attrRes, String8* outError) {
+    ssize_t idx = indexOfAttribute(tree, attrRes);
+    if (idx < 0) {
+        return String8();
+    }
+    Res_value value;
+    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
+        if (value.dataType == Res_value::TYPE_STRING) {
+            size_t len;
+            const uint16_t* str = tree.getAttributeStringValue(idx, &len);
+            return str ? String8(str, len) : String8();
+        }
+        resTable.resolveReference(&value, 0);
+        if (value.dataType != Res_value::TYPE_STRING) {
+            if (outError != NULL) {
+                *outError = "attribute is not a string value";
+            }
+            return String8();
+        }
+    }
+    size_t len;
+    const Res_value* value2 = &value;
+    const char16_t* str = resTable.valueToString(value2, 0, NULL, &len);
+    return str ? String8(str, len) : String8();
+}
+
+int32_t getIntegerAttribute(const ResXMLTree& tree, const char* ns,
+        const char* attr, int32_t defValue, String8* outError) {
+    ssize_t idx = tree.indexOfAttribute(ns, attr);
+    if (idx < 0) {
+        return defValue;
+    }
+    return getIntegerAttributeAtIndex(tree, idx, defValue, outError);
+}
+
+int32_t getIntegerAttribute(const ResXMLTree& tree, uint32_t attrRes, int32_t defValue,
+        String8* outError) {
+    ssize_t idx = indexOfAttribute(tree, attrRes);
+    if (idx < 0) {
+        return defValue;
+    }
+    return getIntegerAttributeAtIndex(tree, idx, defValue, outError);
+}
+
+int32_t getResolvedIntegerAttribute(const ResTable& resTable, const ResXMLTree& tree,
+        uint32_t attrRes, int32_t defValue, String8* outError) {
+    ssize_t idx = indexOfAttribute(tree, attrRes);
+    if (idx < 0) {
+        return defValue;
+    }
+    Res_value value;
+    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
+        if (value.dataType == Res_value::TYPE_REFERENCE) {
+            resTable.resolveReference(&value, 0);
+        }
+        if (value.dataType < Res_value::TYPE_FIRST_INT
+                || value.dataType > Res_value::TYPE_LAST_INT) {
+            if (outError != NULL) {
+                *outError = "attribute is not an integer value";
+            }
+            return defValue;
+        }
+    }
+    return value.data;
+}
+
+void getResolvedResourceAttribute(const ResTable& resTable, const ResXMLTree& tree,
+        uint32_t attrRes, Res_value* outValue, String8* outError) {
+    ssize_t idx = indexOfAttribute(tree, attrRes);
+    if (idx < 0) {
+        if (outError != NULL) {
+            *outError = "attribute could not be found";
+        }
+        return;
+    }
+    if (tree.getAttributeValue(idx, outValue) != NO_ERROR) {
+        if (outValue->dataType == Res_value::TYPE_REFERENCE) {
+            resTable.resolveReference(outValue, 0);
+        }
+        // The attribute was found and was resolved if need be.
+        return;
+    }
+    if (outError != NULL) {
+        *outError = "error getting resolved resource attribute";
+    }
+}
+
+} // namespace AaptXml
diff --git a/tools/aapt/AaptXml.h b/tools/aapt/AaptXml.h
new file mode 100644
index 0000000..16977f3
--- /dev/null
+++ b/tools/aapt/AaptXml.h
@@ -0,0 +1,123 @@
+/*
+ * Copyright (C) 2014 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.
+ */
+
+#ifndef __AAPT_XML_H
+#define __AAPT_XML_H
+
+#include <androidfw/ResourceTypes.h>
+#include <utils/String8.h>
+
+/**
+ * Utility methods for dealing with ResXMLTree.
+ */
+namespace AaptXml {
+
+/**
+ * Returns the index of the attribute, or < 0 if it was not found.
+ */
+ssize_t indexOfAttribute(const android::ResXMLTree& tree, uint32_t attrRes);
+
+/**
+ * Returns the string value for the specified attribute.
+ * The string must be present in the ResXMLTree's string pool (inline in the XML).
+ */
+android::String8 getAttribute(const android::ResXMLTree& tree, const char* ns,
+        const char* attr, android::String8* outError = NULL);
+
+/**
+ * Returns the string value for the specified attribute, or an empty string
+ * if the attribute does not exist.
+ * The string must be present in the ResXMLTree's string pool (inline in the XML).
+ */
+android::String8 getAttribute(const android::ResXMLTree& tree, uint32_t attrRes,
+        android::String8* outError = NULL);
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer must be declared inline in the XML.
+ */
+int32_t getIntegerAttribute(const android::ResXMLTree& tree, const char* ns,
+        const char* attr, int32_t defValue = -1, android::String8* outError = NULL);
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer must be declared inline in the XML.
+ */
+inline int32_t getIntegerAttribute(const android::ResXMLTree& tree, const char* ns,
+        const char* attr, android::String8* outError) {
+    return getIntegerAttribute(tree, ns, attr, -1, outError);
+}
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer must be declared inline in the XML.
+ */
+int32_t getIntegerAttribute(const android::ResXMLTree& tree, uint32_t attrRes,
+        int32_t defValue = -1, android::String8* outError = NULL);
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer must be declared inline in the XML.
+ */
+inline int32_t getIntegerAttribute(const android::ResXMLTree& tree, uint32_t attrRes,
+        android::String8* outError) {
+    return getIntegerAttribute(tree, attrRes, -1, outError);
+}
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer may be a resource in the supplied ResTable.
+ */
+int32_t getResolvedIntegerAttribute(const android::ResTable& resTable,
+        const android::ResXMLTree& tree, uint32_t attrRes, int32_t defValue = -1,
+        android::String8* outError = NULL);
+
+/**
+ * Returns the integer value for the specified attribute, or the default value
+ * if the attribute does not exist.
+ * The integer may be a resource in the supplied ResTable.
+ */
+inline int32_t getResolvedIntegerAttribute(const android::ResTable& resTable,
+        const android::ResXMLTree& tree, uint32_t attrRes,
+        android::String8* outError) {
+    return getResolvedIntegerAttribute(resTable, tree, attrRes, -1, outError);
+}
+
+/**
+ * Returns the string value for the specified attribute, or an empty string
+ * if the attribute does not exist.
+ * The string may be a resource in the supplied ResTable.
+ */
+android::String8 getResolvedAttribute(const android::ResTable& resTable,
+        const android::ResXMLTree& tree, uint32_t attrRes,
+        android::String8* outError = NULL);
+
+/**
+ * Returns the resource for the specified attribute in the outValue parameter.
+ * The resource may be a resource in the supplied ResTable.
+ */
+void getResolvedResourceAttribute(const android::ResTable& resTable,
+        const android::ResXMLTree& tree, uint32_t attrRes, android::Res_value* outValue,
+        android::String8* outError = NULL);
+
+} // namespace AaptXml
+
+#endif // __AAPT_XML_H
diff --git a/tools/aapt/Android.mk b/tools/aapt/Android.mk
index 700afa1..2cbabe1 100644
--- a/tools/aapt/Android.mk
+++ b/tools/aapt/Android.mk
@@ -28,6 +28,7 @@
     AaptAssets.cpp \
     AaptConfig.cpp \
     AaptUtil.cpp \
+    AaptXml.cpp \
     ApkBuilder.cpp \
     Command.cpp \
     CrunchCache.cpp \
@@ -66,6 +67,8 @@
     libexpat \
     libziparchive-host
 
+aaptCFlags := -DAAPT_VERSION=\"$(BUILD_NUMBER)\"
+
 ifeq ($(HOST_OS),linux)
     aaptHostLdLibs += -lrt -ldl -lpthread
 endif
@@ -91,6 +94,7 @@
 
 LOCAL_CFLAGS += -Wno-format-y2k
 LOCAL_CFLAGS += -DSTATIC_ANDROIDFW_FOR_TOOLS
+LOCAL_CFLAGS += $(aaptCFlags)
 ifeq (darwin,$(HOST_OS))
 LOCAL_CFLAGS += -D_DARWIN_UNLIMITED_STREAMS
 endif
@@ -110,7 +114,9 @@
 LOCAL_STATIC_LIBRARIES += \
     libaapt \
     $(aaptHostStaticLibs)
+
 LOCAL_LDLIBS += $(aaptHostLdLibs)
+LOCAL_CFLAGS += $(aaptCFlags)
 
 include $(BUILD_HOST_EXECUTABLE)
 
@@ -128,7 +134,9 @@
 LOCAL_STATIC_LIBRARIES += \
     libaapt \
     $(aaptHostStaticLibs)
+
 LOCAL_LDLIBS += $(aaptHostLdLibs)
+LOCAL_CFLAGS += $(aaptCFlags)
 
 include $(BUILD_HOST_NATIVE_TEST)
 
@@ -159,6 +167,7 @@
     libstlport_static \
     libexpat_static
 
+LOCAL_CFLAGS += $(aaptCFlags)
 LOCAL_CPPFLAGS += -Wno-non-virtual-dtor
 
 include $(BUILD_EXECUTABLE)
diff --git a/tools/aapt/Bundle.h b/tools/aapt/Bundle.h
index 1439f14..9bed899 100644
--- a/tools/aapt/Bundle.h
+++ b/tools/aapt/Bundle.h
@@ -24,6 +24,7 @@
     SDK_HONEYCOMB_MR2 = 13,
     SDK_ICE_CREAM_SANDWICH = 14,
     SDK_ICE_CREAM_SANDWICH_MR1 = 15,
+    SDK_L = 21,
 };
 
 /*
@@ -129,6 +130,10 @@
     void setErrorOnFailedInsert(bool val) { mErrorOnFailedInsert = val; }
     bool getErrorOnMissingConfigEntry() { return mErrorOnMissingConfigEntry; }
     void setErrorOnMissingConfigEntry(bool val) { mErrorOnMissingConfigEntry = val; }
+    const android::String8& getPlatformBuildVersionCode() { return mPlatformVersionCode; }
+    void setPlatformBuildVersionCode(const android::String8& code) { mPlatformVersionCode = code; }
+    const android::String8& getPlatformBuildVersionName() { return mPlatformVersionName; }
+    void setPlatformBuildVersionName(const android::String8& name) { mPlatformVersionName = name; }
 
     bool getUTF16StringsOption() {
         return mWantUTF16 || !isMinSdkAtLeast(SDK_FROYO);
@@ -322,6 +327,8 @@
     const char* mSingleCrunchInputFile;
     const char* mSingleCrunchOutputFile;
     bool        mBuildSharedLibrary;
+    android::String8 mPlatformVersionCode;
+    android::String8 mPlatformVersionName;
 
     /* file specification */
     int         mArgc;
diff --git a/tools/aapt/Command.cpp b/tools/aapt/Command.cpp
index 5d146d6..41d8502 100644
--- a/tools/aapt/Command.cpp
+++ b/tools/aapt/Command.cpp
@@ -3,6 +3,7 @@
 //
 // Android Asset Packaging Tool main entry point.
 //
+#include "AaptXml.h"
 #include "ApkBuilder.h"
 #include "Bundle.h"
 #include "Images.h"
@@ -24,6 +25,10 @@
 
 using namespace android;
 
+#ifndef AAPT_VERSION
+    #define AAPT_VERSION ""
+#endif
+
 /*
  * Show version info.  All the cool kids do it.
  */
@@ -32,7 +37,7 @@
     if (bundle->getFileSpecCount() != 0) {
         printf("(ignoring extra arguments)\n");
     }
-    printf("Android Asset Packaging Tool, v0.2\n");
+    printf("Android Asset Packaging Tool, v0.2-" AAPT_VERSION "\n");
 
     return 0;
 }
@@ -237,162 +242,17 @@
     return result;
 }
 
-static ssize_t indexOfAttribute(const ResXMLTree& tree, uint32_t attrRes)
-{
-    size_t N = tree.getAttributeCount();
-    for (size_t i=0; i<N; i++) {
-        if (tree.getAttributeNameResID(i) == attrRes) {
-            return (ssize_t)i;
-        }
-    }
-    return -1;
-}
-
-String8 getAttribute(const ResXMLTree& tree, const char* ns,
-                            const char* attr, String8* outError)
-{
-    ssize_t idx = tree.indexOfAttribute(ns, attr);
-    if (idx < 0) {
-        return String8();
-    }
-    Res_value value;
-    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
-        if (value.dataType != Res_value::TYPE_STRING) {
-            if (outError != NULL) {
-                *outError = "attribute is not a string value";
-            }
-            return String8();
-        }
-    }
-    size_t len;
-    const uint16_t* str = tree.getAttributeStringValue(idx, &len);
-    return str ? String8(str, len) : String8();
-}
-
-static String8 getAttribute(const ResXMLTree& tree, uint32_t attrRes, String8* outError)
-{
-    ssize_t idx = indexOfAttribute(tree, attrRes);
-    if (idx < 0) {
-        return String8();
-    }
-    Res_value value;
-    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
-        if (value.dataType != Res_value::TYPE_STRING) {
-            if (outError != NULL) {
-                *outError = "attribute is not a string value";
-            }
-            return String8();
-        }
-    }
-    size_t len;
-    const uint16_t* str = tree.getAttributeStringValue(idx, &len);
-    return str ? String8(str, len) : String8();
-}
-
-static int32_t getIntegerAttribute(const ResXMLTree& tree, uint32_t attrRes,
-        String8* outError, int32_t defValue = -1)
-{
-    ssize_t idx = indexOfAttribute(tree, attrRes);
-    if (idx < 0) {
-        return defValue;
-    }
-    Res_value value;
-    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
-        if (value.dataType < Res_value::TYPE_FIRST_INT
-                || value.dataType > Res_value::TYPE_LAST_INT) {
-            if (outError != NULL) {
-                *outError = "attribute is not an integer value";
-            }
-            return defValue;
-        }
-    }
-    return value.data;
-}
-
-static int32_t getResolvedIntegerAttribute(const ResTable* resTable, const ResXMLTree& tree,
-        uint32_t attrRes, String8* outError, int32_t defValue = -1)
-{
-    ssize_t idx = indexOfAttribute(tree, attrRes);
-    if (idx < 0) {
-        return defValue;
-    }
-    Res_value value;
-    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
-        if (value.dataType == Res_value::TYPE_REFERENCE) {
-            resTable->resolveReference(&value, 0);
-        }
-        if (value.dataType < Res_value::TYPE_FIRST_INT
-                || value.dataType > Res_value::TYPE_LAST_INT) {
-            if (outError != NULL) {
-                *outError = "attribute is not an integer value";
-            }
-            return defValue;
-        }
-    }
-    return value.data;
-}
-
-static String8 getResolvedAttribute(const ResTable* resTable, const ResXMLTree& tree,
-        uint32_t attrRes, String8* outError)
-{
-    ssize_t idx = indexOfAttribute(tree, attrRes);
-    if (idx < 0) {
-        return String8();
-    }
-    Res_value value;
-    if (tree.getAttributeValue(idx, &value) != NO_ERROR) {
-        if (value.dataType == Res_value::TYPE_STRING) {
-            size_t len;
-            const uint16_t* str = tree.getAttributeStringValue(idx, &len);
-            return str ? String8(str, len) : String8();
-        }
-        resTable->resolveReference(&value, 0);
-        if (value.dataType != Res_value::TYPE_STRING) {
-            if (outError != NULL) {
-                *outError = "attribute is not a string value";
-            }
-            return String8();
-        }
-    }
-    size_t len;
-    const Res_value* value2 = &value;
-    const char16_t* str = const_cast<ResTable*>(resTable)->valueToString(value2, 0, NULL, &len);
-    return str ? String8(str, len) : String8();
-}
-
-static void getResolvedResourceAttribute(Res_value* value, const ResTable* resTable,
-        const ResXMLTree& tree, uint32_t attrRes, String8* outError)
-{
-    ssize_t idx = indexOfAttribute(tree, attrRes);
-    if (idx < 0) {
-        if (outError != NULL) {
-            *outError = "attribute could not be found";
-        }
-        return;
-    }
-    if (tree.getAttributeValue(idx, value) != NO_ERROR) {
-        if (value->dataType == Res_value::TYPE_REFERENCE) {
-            resTable->resolveReference(value, 0);
-        }
-        // The attribute was found and was resolved if need be.
-        return;
-    }
-    if (outError != NULL) {
-        *outError = "error getting resolved resource attribute";
-    }
-}
-
-static void printResolvedResourceAttribute(const ResTable* resTable, const ResXMLTree& tree,
+static void printResolvedResourceAttribute(const ResTable& resTable, const ResXMLTree& tree,
         uint32_t attrRes, String8 attrLabel, String8* outError)
 {
     Res_value value;
-    getResolvedResourceAttribute(&value, resTable, tree, attrRes, outError);
+    AaptXml::getResolvedResourceAttribute(resTable, tree, attrRes, &value, outError);
     if (*outError != "") {
         *outError = "error print resolved resource attribute";
         return;
     }
     if (value.dataType == Res_value::TYPE_STRING) {
-        String8 result = getResolvedAttribute(resTable, tree, attrRes, outError);
+        String8 result = AaptXml::getResolvedAttribute(resTable, tree, attrRes, outError);
         printf("%s='%s'", attrLabel.string(),
                 ResTable::normalizeForOutput(result.string()).string());
     } else if (Res_value::TYPE_FIRST_INT <= value.dataType &&
@@ -434,6 +294,7 @@
     LARGE_SCREEN_ATTR = 0x01010286,
     XLARGE_SCREEN_ATTR = 0x010102bf,
     REQUIRED_ATTR = 0x0101028e,
+    INSTALL_LOCATION_ATTR = 0x010102b7,
     SCREEN_SIZE_ATTR = 0x010102ca,
     SCREEN_DENSITY_ATTR = 0x010102cb,
     REQUIRES_SMALLEST_WIDTH_DP_ATTR = 0x01010364,
@@ -483,10 +344,10 @@
         }
         String8 tag(ctag16);
         if (tag == "screen") {
-            int32_t screenSize = getIntegerAttribute(tree,
-                    SCREEN_SIZE_ATTR, NULL, -1);
-            int32_t screenDensity = getIntegerAttribute(tree,
-                    SCREEN_DENSITY_ATTR, NULL, -1);
+            int32_t screenSize = AaptXml::getIntegerAttribute(tree,
+                    SCREEN_SIZE_ATTR);
+            int32_t screenDensity = AaptXml::getIntegerAttribute(tree,
+                    SCREEN_DENSITY_ATTR);
             if (screenSize > 0 && screenDensity > 0) {
                 if (!first) {
                     printf(",");
@@ -572,7 +433,7 @@
                 }
             } else if (depth == 2 && withinApduService) {
                 if (tag == "aid-group") {
-                    String8 category = getAttribute(tree, CATEGORY_ATTR, &error);
+                    String8 category = AaptXml::getAttribute(tree, CATEGORY_ATTR, &error);
                     if (error != "") {
                         if (outError != NULL) *outError = error;
                         return Vector<String8>();
@@ -871,11 +732,11 @@
                         fprintf(stderr, "ERROR: manifest does not start with <manifest> tag\n");
                         goto bail;
                     }
-                    String8 pkg = getAttribute(tree, NULL, "package", NULL);
+                    String8 pkg = AaptXml::getAttribute(tree, NULL, "package", NULL);
                     printf("package: %s\n", ResTable::normalizeForOutput(pkg.string()).string());
                 } else if (depth == 2 && tag == "permission") {
                     String8 error;
-                    String8 name = getAttribute(tree, NAME_ATTR, &error);
+                    String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                     if (error != "") {
                         fprintf(stderr, "ERROR: %s\n", error.string());
                         goto bail;
@@ -884,14 +745,14 @@
                             ResTable::normalizeForOutput(name.string()).string());
                 } else if (depth == 2 && tag == "uses-permission") {
                     String8 error;
-                    String8 name = getAttribute(tree, NAME_ATTR, &error);
+                    String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                     if (error != "") {
                         fprintf(stderr, "ERROR: %s\n", error.string());
                         goto bail;
                     }
                     printUsesPermission(name,
-                            getIntegerAttribute(tree, REQUIRED_ATTR, NULL, 1) == 0,
-                            getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR, NULL, -1));
+                            AaptXml::getIntegerAttribute(tree, REQUIRED_ATTR, 1) == 0,
+                            AaptXml::getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR));
                 }
             }
         } else if (strcmp("badging", option) == 0) {
@@ -1146,12 +1007,14 @@
                         fprintf(stderr, "ERROR: manifest does not start with <manifest> tag\n");
                         goto bail;
                     }
-                    pkg = getAttribute(tree, NULL, "package", NULL);
+                    pkg = AaptXml::getAttribute(tree, NULL, "package", NULL);
                     printf("package: name='%s' ",
                             ResTable::normalizeForOutput(pkg.string()).string());
-                    int32_t versionCode = getIntegerAttribute(tree, VERSION_CODE_ATTR, &error);
+                    int32_t versionCode = AaptXml::getIntegerAttribute(tree, VERSION_CODE_ATTR,
+                            &error);
                     if (error != "") {
-                        fprintf(stderr, "ERROR getting 'android:versionCode' attribute: %s\n", error.string());
+                        fprintf(stderr, "ERROR getting 'android:versionCode' attribute: %s\n",
+                                error.string());
                         goto bail;
                     }
                     if (versionCode > 0) {
@@ -1159,20 +1022,53 @@
                     } else {
                         printf("versionCode='' ");
                     }
-                    String8 versionName = getResolvedAttribute(&res, tree, VERSION_NAME_ATTR, &error);
+                    String8 versionName = AaptXml::getResolvedAttribute(res, tree,
+                            VERSION_NAME_ATTR, &error);
                     if (error != "") {
-                        fprintf(stderr, "ERROR getting 'android:versionName' attribute: %s\n", error.string());
+                        fprintf(stderr, "ERROR getting 'android:versionName' attribute: %s\n",
+                                error.string());
                         goto bail;
                     }
                     printf("versionName='%s'",
                             ResTable::normalizeForOutput(versionName.string()).string());
 
-                    String8 splitName = getAttribute(tree, NULL, "split", NULL);
+                    String8 splitName = AaptXml::getAttribute(tree, NULL, "split");
                     if (!splitName.isEmpty()) {
                         printf(" split='%s'", ResTable::normalizeForOutput(
                                     splitName.string()).string());
                     }
+
+                    String8 platformVersionName = AaptXml::getAttribute(tree, NULL,
+                            "platformBuildVersionName");
+                    printf(" platformBuildVersionName='%s'", platformVersionName.string());
                     printf("\n");
+
+                    int32_t installLocation = AaptXml::getResolvedIntegerAttribute(res, tree,
+                            INSTALL_LOCATION_ATTR, &error);
+                    if (error != "") {
+                        fprintf(stderr, "ERROR getting 'android:installLocation' attribute: %s\n",
+                                error.string());
+                        goto bail;
+                    }
+
+                    if (installLocation >= 0) {
+                        printf("install-location:'");
+                        switch (installLocation) {
+                            case 0:
+                                printf("auto");
+                                break;
+                            case 1:
+                                printf("internalOnly");
+                                break;
+                            case 2:
+                                printf("preferExternal");
+                                break;
+                            default:
+                                fprintf(stderr, "Invalid installLocation %d\n", installLocation);
+                                goto bail;
+                        }
+                        printf("'\n");
+                    }
                 } else if (depth == 2) {
                     withinApplication = false;
                     if (tag == "application") {
@@ -1183,7 +1079,8 @@
                         for (size_t i=0; i<NL; i++) {
                             const char* localeStr =  locales[i].string();
                             assets.setLocale(localeStr != NULL ? localeStr : "");
-                            String8 llabel = getResolvedAttribute(&res, tree, LABEL_ATTR, &error);
+                            String8 llabel = AaptXml::getResolvedAttribute(res, tree, LABEL_ATTR,
+                                    &error);
                             if (llabel != "") {
                                 if (localeStr == NULL || strlen(localeStr) == 0) {
                                     label = llabel;
@@ -1204,7 +1101,8 @@
                         for (size_t i=0; i<ND; i++) {
                             tmpConfig.density = densities[i];
                             assets.setConfiguration(tmpConfig);
-                            String8 icon = getResolvedAttribute(&res, tree, ICON_ATTR, &error);
+                            String8 icon = AaptXml::getResolvedAttribute(res, tree, ICON_ATTR,
+                                    &error);
                             if (icon != "") {
                                 printf("application-icon-%d:'%s'\n", densities[i],
                                         ResTable::normalizeForOutput(icon.string()).string());
@@ -1212,14 +1110,17 @@
                         }
                         assets.setConfiguration(config);
 
-                        String8 icon = getResolvedAttribute(&res, tree, ICON_ATTR, &error);
+                        String8 icon = AaptXml::getResolvedAttribute(res, tree, ICON_ATTR, &error);
                         if (error != "") {
-                            fprintf(stderr, "ERROR getting 'android:icon' attribute: %s\n", error.string());
+                            fprintf(stderr, "ERROR getting 'android:icon' attribute: %s\n",
+                                    error.string());
                             goto bail;
                         }
-                        int32_t testOnly = getIntegerAttribute(tree, TEST_ONLY_ATTR, &error, 0);
+                        int32_t testOnly = AaptXml::getIntegerAttribute(tree, TEST_ONLY_ATTR, 0,
+                                &error);
                         if (error != "") {
-                            fprintf(stderr, "ERROR getting 'android:testOnly' attribute: %s\n", error.string());
+                            fprintf(stderr, "ERROR getting 'android:testOnly' attribute: %s\n",
+                                    error.string());
                             goto bail;
                         }
                         printf("application: label='%s' ",
@@ -1229,9 +1130,11 @@
                             printf("testOnly='%d'\n", testOnly);
                         }
 
-                        int32_t debuggable = getResolvedIntegerAttribute(&res, tree, DEBUGGABLE_ATTR, &error, 0);
+                        int32_t debuggable = AaptXml::getResolvedIntegerAttribute(res, tree,
+                                DEBUGGABLE_ATTR, 0, &error);
                         if (error != "") {
-                            fprintf(stderr, "ERROR getting 'android:debuggable' attribute: %s\n", error.string());
+                            fprintf(stderr, "ERROR getting 'android:debuggable' attribute: %s\n",
+                                    error.string());
                             goto bail;
                         }
                         if (debuggable != 0) {
@@ -1252,10 +1155,11 @@
                             }
                         }
                     } else if (tag == "uses-sdk") {
-                        int32_t code = getIntegerAttribute(tree, MIN_SDK_VERSION_ATTR, &error);
+                        int32_t code = AaptXml::getIntegerAttribute(tree, MIN_SDK_VERSION_ATTR, &error);
                         if (error != "") {
                             error = "";
-                            String8 name = getResolvedAttribute(&res, tree, MIN_SDK_VERSION_ATTR, &error);
+                            String8 name = AaptXml::getResolvedAttribute(res, tree,
+                                    MIN_SDK_VERSION_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:minSdkVersion' attribute: %s\n",
                                         error.string());
@@ -1268,14 +1172,15 @@
                             targetSdk = code;
                             printf("sdkVersion:'%d'\n", code);
                         }
-                        code = getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR, NULL, -1);
+                        code = AaptXml::getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR);
                         if (code != -1) {
                             printf("maxSdkVersion:'%d'\n", code);
                         }
-                        code = getIntegerAttribute(tree, TARGET_SDK_VERSION_ATTR, &error);
+                        code = AaptXml::getIntegerAttribute(tree, TARGET_SDK_VERSION_ATTR, &error);
                         if (error != "") {
                             error = "";
-                            String8 name = getResolvedAttribute(&res, tree, TARGET_SDK_VERSION_ATTR, &error);
+                            String8 name = AaptXml::getResolvedAttribute(res, tree,
+                                    TARGET_SDK_VERSION_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:targetSdkVersion' attribute: %s\n",
                                         error.string());
@@ -1291,16 +1196,16 @@
                             printf("targetSdkVersion:'%d'\n", code);
                         }
                     } else if (tag == "uses-configuration") {
-                        int32_t reqTouchScreen = getIntegerAttribute(tree,
-                                REQ_TOUCH_SCREEN_ATTR, NULL, 0);
-                        int32_t reqKeyboardType = getIntegerAttribute(tree,
-                                REQ_KEYBOARD_TYPE_ATTR, NULL, 0);
-                        int32_t reqHardKeyboard = getIntegerAttribute(tree,
-                                REQ_HARD_KEYBOARD_ATTR, NULL, 0);
-                        int32_t reqNavigation = getIntegerAttribute(tree,
-                                REQ_NAVIGATION_ATTR, NULL, 0);
-                        int32_t reqFiveWayNav = getIntegerAttribute(tree,
-                                REQ_FIVE_WAY_NAV_ATTR, NULL, 0);
+                        int32_t reqTouchScreen = AaptXml::getIntegerAttribute(tree,
+                                REQ_TOUCH_SCREEN_ATTR, 0);
+                        int32_t reqKeyboardType = AaptXml::getIntegerAttribute(tree,
+                                REQ_KEYBOARD_TYPE_ATTR, 0);
+                        int32_t reqHardKeyboard = AaptXml::getIntegerAttribute(tree,
+                                REQ_HARD_KEYBOARD_ATTR, 0);
+                        int32_t reqNavigation = AaptXml::getIntegerAttribute(tree,
+                                REQ_NAVIGATION_ATTR, 0);
+                        int32_t reqFiveWayNav = AaptXml::getIntegerAttribute(tree,
+                                REQ_FIVE_WAY_NAV_ATTR, 0);
                         printf("uses-configuration:");
                         if (reqTouchScreen != 0) {
                             printf(" reqTouchScreen='%d'", reqTouchScreen);
@@ -1321,26 +1226,26 @@
                     } else if (tag == "supports-input") {
                         withinSupportsInput = true;
                     } else if (tag == "supports-screens") {
-                        smallScreen = getIntegerAttribute(tree,
-                                SMALL_SCREEN_ATTR, NULL, 1);
-                        normalScreen = getIntegerAttribute(tree,
-                                NORMAL_SCREEN_ATTR, NULL, 1);
-                        largeScreen = getIntegerAttribute(tree,
-                                LARGE_SCREEN_ATTR, NULL, 1);
-                        xlargeScreen = getIntegerAttribute(tree,
-                                XLARGE_SCREEN_ATTR, NULL, 1);
-                        anyDensity = getIntegerAttribute(tree,
-                                ANY_DENSITY_ATTR, NULL, 1);
-                        requiresSmallestWidthDp = getIntegerAttribute(tree,
-                                REQUIRES_SMALLEST_WIDTH_DP_ATTR, NULL, 0);
-                        compatibleWidthLimitDp = getIntegerAttribute(tree,
-                                COMPATIBLE_WIDTH_LIMIT_DP_ATTR, NULL, 0);
-                        largestWidthLimitDp = getIntegerAttribute(tree,
-                                LARGEST_WIDTH_LIMIT_DP_ATTR, NULL, 0);
+                        smallScreen = AaptXml::getIntegerAttribute(tree,
+                                SMALL_SCREEN_ATTR, 1);
+                        normalScreen = AaptXml::getIntegerAttribute(tree,
+                                NORMAL_SCREEN_ATTR, 1);
+                        largeScreen = AaptXml::getIntegerAttribute(tree,
+                                LARGE_SCREEN_ATTR, 1);
+                        xlargeScreen = AaptXml::getIntegerAttribute(tree,
+                                XLARGE_SCREEN_ATTR, 1);
+                        anyDensity = AaptXml::getIntegerAttribute(tree,
+                                ANY_DENSITY_ATTR, 1);
+                        requiresSmallestWidthDp = AaptXml::getIntegerAttribute(tree,
+                                REQUIRES_SMALLEST_WIDTH_DP_ATTR, 0);
+                        compatibleWidthLimitDp = AaptXml::getIntegerAttribute(tree,
+                                COMPATIBLE_WIDTH_LIMIT_DP_ATTR, 0);
+                        largestWidthLimitDp = AaptXml::getIntegerAttribute(tree,
+                                LARGEST_WIDTH_LIMIT_DP_ATTR, 0);
                     } else if (tag == "feature-group") {
                         withinFeatureGroup = true;
                         FeatureGroup group;
-                        group.label = getResolvedAttribute(&res, tree, LABEL_ATTR, &error);
+                        group.label = AaptXml::getResolvedAttribute(res, tree, LABEL_ATTR, &error);
                         if (error != "") {
                             fprintf(stderr, "ERROR getting 'android:label' attribute:"
                                     " %s\n", error.string());
@@ -1349,17 +1254,17 @@
                         featureGroups.add(group);
 
                     } else if (tag == "uses-feature") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
-                            int req = getIntegerAttribute(tree,
-                                    REQUIRED_ATTR, NULL, 1);
+                            int req = AaptXml::getIntegerAttribute(tree,
+                                    REQUIRED_ATTR, 1);
 
                             commonFeatures.features.add(name, req);
                             if (req) {
                                 addParentFeatures(&commonFeatures, name);
                             }
                         } else {
-                            int vers = getIntegerAttribute(tree,
+                            int vers = AaptXml::getIntegerAttribute(tree,
                                     GL_ES_VERSION_ATTR, &error);
                             if (error == "") {
                                 if (vers > commonFeatures.openGLESVersion) {
@@ -1368,7 +1273,7 @@
                             }
                         }
                     } else if (tag == "uses-permission") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
                             if (name == "android.permission.CAMERA") {
                                 addImpliedFeature(&impliedFeatures, "android.hardware.camera",
@@ -1446,15 +1351,15 @@
                             }
 
                             printUsesPermission(name,
-                                    getIntegerAttribute(tree, REQUIRED_ATTR, NULL, 1) == 0,
-                                    getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR, NULL, -1));
+                                    AaptXml::getIntegerAttribute(tree, REQUIRED_ATTR, 1) == 0,
+                                    AaptXml::getIntegerAttribute(tree, MAX_SDK_VERSION_ATTR));
                        } else {
                             fprintf(stderr, "ERROR getting 'android:name' attribute: %s\n",
                                     error.string());
                             goto bail;
                         }
                     } else if (tag == "uses-package") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
                             printf("uses-package:'%s'\n",
                                     ResTable::normalizeForOutput(name.string()).string());
@@ -1464,7 +1369,7 @@
                                 goto bail;
                         }
                     } else if (tag == "original-package") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
                             printf("original-package:'%s'\n",
                                     ResTable::normalizeForOutput(name.string()).string());
@@ -1474,7 +1379,7 @@
                                 goto bail;
                         }
                     } else if (tag == "supports-gl-texture") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
                             printf("supports-gl-texture:'%s'\n",
                                     ResTable::normalizeForOutput(name.string()).string());
@@ -1492,9 +1397,9 @@
                         }
                         depth--;
                     } else if (tag == "package-verifier") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
-                            String8 publicKey = getAttribute(tree, PUBLIC_KEY_ATTR, &error);
+                            String8 publicKey = AaptXml::getAttribute(tree, PUBLIC_KEY_ATTR, &error);
                             if (publicKey != "" && error == "") {
                                 printf("package-verifier: name='%s' publicKey='%s'\n",
                                         ResTable::normalizeForOutput(name.string()).string(),
@@ -1521,35 +1426,38 @@
                     if (withinApplication) {
                         if(tag == "activity") {
                             withinActivity = true;
-                            activityName = getAttribute(tree, NAME_ATTR, &error);
+                            activityName = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:name' attribute: %s\n",
                                         error.string());
                                 goto bail;
                             }
 
-                            activityLabel = getResolvedAttribute(&res, tree, LABEL_ATTR, &error);
+                            activityLabel = AaptXml::getResolvedAttribute(res, tree, LABEL_ATTR,
+                                    &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:label' attribute: %s\n",
                                         error.string());
                                 goto bail;
                             }
 
-                            activityIcon = getResolvedAttribute(&res, tree, ICON_ATTR, &error);
+                            activityIcon = AaptXml::getResolvedAttribute(res, tree, ICON_ATTR,
+                                    &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:icon' attribute: %s\n",
                                         error.string());
                                 goto bail;
                             }
 
-                            activityBanner = getResolvedAttribute(&res, tree, BANNER_ATTR, &error);
+                            activityBanner = AaptXml::getResolvedAttribute(res, tree, BANNER_ATTR,
+                                    &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:banner' attribute: %s\n",
                                         error.string());
                                 goto bail;
                             }
 
-                            int32_t orien = getResolvedIntegerAttribute(&res, tree,
+                            int32_t orien = AaptXml::getResolvedIntegerAttribute(res, tree,
                                     SCREEN_ORIENTATION_ATTR, &error);
                             if (error == "") {
                                 if (orien == 0 || orien == 6 || orien == 8) {
@@ -1563,21 +1471,21 @@
                                 }
                             }
                         } else if (tag == "uses-library") {
-                            String8 libraryName = getAttribute(tree, NAME_ATTR, &error);
+                            String8 libraryName = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr,
                                         "ERROR getting 'android:name' attribute for uses-library"
                                         " %s\n", error.string());
                                 goto bail;
                             }
-                            int req = getIntegerAttribute(tree,
-                                    REQUIRED_ATTR, NULL, 1);
+                            int req = AaptXml::getIntegerAttribute(tree,
+                                    REQUIRED_ATTR, 1);
                             printf("uses-library%s:'%s'\n",
                                     req ? "" : "-not-required", ResTable::normalizeForOutput(
                                             libraryName.string()).string());
                         } else if (tag == "receiver") {
                             withinReceiver = true;
-                            receiverName = getAttribute(tree, NAME_ATTR, &error);
+                            receiverName = AaptXml::getAttribute(tree, NAME_ATTR, &error);
 
                             if (error != "") {
                                 fprintf(stderr,
@@ -1586,7 +1494,8 @@
                                 goto bail;
                             }
 
-                            String8 permission = getAttribute(tree, PERMISSION_ATTR, &error);
+                            String8 permission = AaptXml::getAttribute(tree, PERMISSION_ATTR,
+                                    &error);
                             if (error == "") {
                                 if (permission == "android.permission.BIND_DEVICE_ADMIN") {
                                     hasBindDeviceAdminPermission = true;
@@ -1597,7 +1506,7 @@
                             }
                         } else if (tag == "service") {
                             withinService = true;
-                            serviceName = getAttribute(tree, NAME_ATTR, &error);
+                            serviceName = AaptXml::getAttribute(tree, NAME_ATTR, &error);
 
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:name' attribute for "
@@ -1605,7 +1514,8 @@
                                 goto bail;
                             }
 
-                            String8 permission = getAttribute(tree, PERMISSION_ATTR, &error);
+                            String8 permission = AaptXml::getAttribute(tree, PERMISSION_ATTR,
+                                    &error);
                             if (error == "") {
                                 if (permission == "android.permission.BIND_INPUT_METHOD") {
                                     hasBindInputMethodPermission = true;
@@ -1627,22 +1537,24 @@
                         } else if (tag == "provider") {
                             withinProvider = true;
 
-                            bool exported = getResolvedIntegerAttribute(&res, tree, EXPORTED_ATTR, &error);
+                            bool exported = AaptXml::getResolvedIntegerAttribute(res, tree,
+                                    EXPORTED_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:exported' attribute for provider:"
                                         " %s\n", error.string());
                                 goto bail;
                             }
 
-                            bool grantUriPermissions = getResolvedIntegerAttribute(&res, tree,
-                                    GRANT_URI_PERMISSIONS_ATTR, &error);
+                            bool grantUriPermissions = AaptXml::getResolvedIntegerAttribute(
+                                    res, tree, GRANT_URI_PERMISSIONS_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:grantUriPermissions' attribute for provider:"
                                         " %s\n", error.string());
                                 goto bail;
                             }
 
-                            String8 permission = getResolvedAttribute(&res, tree, PERMISSION_ATTR, &error);
+                            String8 permission = AaptXml::getResolvedAttribute(res, tree,
+                                    PERMISSION_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:permission' attribute for provider:"
                                         " %s\n", error.string());
@@ -1653,7 +1565,8 @@
                                 permission == "android.permission.MANAGE_DOCUMENTS";
 
                         } else if (bundle->getIncludeMetaData() && tag == "meta-data") {
-                            String8 metaDataName = getResolvedAttribute(&res, tree, NAME_ATTR, &error);
+                            String8 metaDataName = AaptXml::getResolvedAttribute(res, tree,
+                                    NAME_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:name' attribute for "
                                         "meta-data:%s\n", error.string());
@@ -1661,12 +1574,12 @@
                             }
                             printf("meta-data: name='%s' ",
                                     ResTable::normalizeForOutput(metaDataName.string()).string());
-                            printResolvedResourceAttribute(&res, tree, VALUE_ATTR, String8("value"),
+                            printResolvedResourceAttribute(res, tree, VALUE_ATTR, String8("value"),
                                     &error);
                             if (error != "") {
                                 // Try looking for a RESOURCE_ATTR
                                 error = "";
-                                printResolvedResourceAttribute(&res, tree, RESOURCE_ATTR,
+                                printResolvedResourceAttribute(res, tree, RESOURCE_ATTR,
                                         String8("resource"), &error);
                                 if (error != "") {
                                     fprintf(stderr, "ERROR getting 'android:value' or "
@@ -1677,7 +1590,7 @@
                             }
                             printf("\n");
                         } else if (withinSupportsInput && tag == "input-type") {
-                            String8 name = getAttribute(tree, NAME_ATTR, &error);
+                            String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                             if (name != "" && error == "") {
                                 supportedInput.add(name);
                             } else {
@@ -1689,12 +1602,13 @@
                     } else if (withinFeatureGroup && tag == "uses-feature") {
                         FeatureGroup& top = featureGroups.editTop();
 
-                        String8 name = getResolvedAttribute(&res, tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getResolvedAttribute(res, tree, NAME_ATTR, &error);
                         if (name != "" && error == "") {
                             top.features.add(name, true);
                             addParentFeatures(&top, name);
                         } else {
-                            int vers = getIntegerAttribute(tree, GL_ES_VERSION_ATTR, &error);
+                            int vers = AaptXml::getIntegerAttribute(tree, GL_ES_VERSION_ATTR,
+                                    &error);
                             if (error == "") {
                                 if (vers > top.openGLESVersion) {
                                     top.openGLESVersion = vers;
@@ -1722,7 +1636,7 @@
                         actCameraSecure = false;
                         catLauncher = false;
                     } else if (withinService && tag == "meta-data") {
-                        String8 name = getAttribute(tree, NAME_ATTR, &error);
+                        String8 name = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (error != "") {
                             fprintf(stderr, "ERROR getting 'android:name' attribute for"
                                     " meta-data tag in service '%s': %s\n", serviceName.string(), error.string());
@@ -1736,7 +1650,8 @@
                                 offHost = false;
                             }
 
-                            String8 xmlPath = getResolvedAttribute(&res, tree, RESOURCE_ATTR, &error);
+                            String8 xmlPath = AaptXml::getResolvedAttribute(res, tree,
+                                    RESOURCE_ATTR, &error);
                             if (error != "") {
                                 fprintf(stderr, "ERROR getting 'android:resource' attribute for"
                                         " meta-data tag in service '%s': %s\n", serviceName.string(), error.string());
@@ -1765,7 +1680,7 @@
                 } else if ((depth == 5) && withinIntentFilter) {
                     String8 action;
                     if (tag == "action") {
-                        action = getAttribute(tree, NAME_ATTR, &error);
+                        action = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (error != "") {
                             fprintf(stderr, "ERROR getting 'android:name' attribute: %s\n",
                                     error.string());
@@ -1817,7 +1732,7 @@
                     }
 
                     if (tag == "category") {
-                        String8 category = getAttribute(tree, NAME_ATTR, &error);
+                        String8 category = AaptXml::getAttribute(tree, NAME_ATTR, &error);
                         if (error != "") {
                             fprintf(stderr, "ERROR getting 'name' attribute: %s\n",
                                     error.string());
@@ -2456,10 +2371,12 @@
         if (bundle->getCustomPackage() == NULL) {
             // Write the R.java file into the appropriate class directory
             // e.g. gen/com/foo/app/R.java
-            err = writeResourceSymbols(bundle, assets, assets->getPackage(), true);
+            err = writeResourceSymbols(bundle, assets, assets->getPackage(), true,
+                    bundle->getBuildSharedLibrary());
         } else {
             const String8 customPkg(bundle->getCustomPackage());
-            err = writeResourceSymbols(bundle, assets, customPkg, true);
+            err = writeResourceSymbols(bundle, assets, customPkg, true,
+                    bundle->getBuildSharedLibrary());
         }
         if (err < 0) {
             goto bail;
@@ -2473,7 +2390,8 @@
             char* packageString = strtok(libs.lockBuffer(libs.length()), ":");
             while (packageString != NULL) {
                 // Write the R.java file out with the correct package name
-                err = writeResourceSymbols(bundle, assets, String8(packageString), true);
+                err = writeResourceSymbols(bundle, assets, String8(packageString), true,
+                        bundle->getBuildSharedLibrary());
                 if (err < 0) {
                     goto bail;
                 }
@@ -2482,11 +2400,11 @@
             libs.unlockBuffer();
         }
     } else {
-        err = writeResourceSymbols(bundle, assets, assets->getPackage(), false);
+        err = writeResourceSymbols(bundle, assets, assets->getPackage(), false, false);
         if (err < 0) {
             goto bail;
         }
-        err = writeResourceSymbols(bundle, assets, assets->getSymbolsPrivatePackage(), true);
+        err = writeResourceSymbols(bundle, assets, assets->getSymbolsPrivatePackage(), true, false);
         if (err < 0) {
             goto bail;
         }
diff --git a/tools/aapt/IndentPrinter.h b/tools/aapt/IndentPrinter.h
new file mode 100644
index 0000000..6fc94bc
--- /dev/null
+++ b/tools/aapt/IndentPrinter.h
@@ -0,0 +1,63 @@
+#ifndef __INDENT_PRINTER_H
+#define __INDENT_PRINTER_H
+
+class IndentPrinter {
+public:
+    IndentPrinter(FILE* stream, int indentSize=2)
+        : mStream(stream)
+        , mIndentSize(indentSize)
+        , mIndent(0)
+        , mNeedsIndent(true) {
+    }
+
+    void indent(int amount = 1) {
+        mIndent += amount;
+        if (mIndent < 0) {
+            mIndent = 0;
+        }
+    }
+
+    void print(const char* fmt, ...) {
+        doIndent();
+        va_list args;
+        va_start(args, fmt);
+        vfprintf(mStream, fmt, args);
+        va_end(args);
+    }
+
+    void println(const char* fmt, ...) {
+        doIndent();
+        va_list args;
+        va_start(args, fmt);
+        vfprintf(mStream, fmt, args);
+        va_end(args);
+        fputs("\n", mStream);
+        mNeedsIndent = true;
+    }
+
+    void println() {
+        doIndent();
+        fputs("\n", mStream);
+        mNeedsIndent = true;
+    }
+
+private:
+    void doIndent() {
+        if (mNeedsIndent) {
+            int numSpaces = mIndent * mIndentSize;
+            while (numSpaces > 0) {
+                fputs(" ", mStream);
+                numSpaces--;
+            }
+            mNeedsIndent = false;
+        }
+    }
+
+    FILE* mStream;
+    const int mIndentSize;
+    int mIndent;
+    bool mNeedsIndent;
+};
+
+#endif // __INDENT_PRINTER_H
+
diff --git a/tools/aapt/Main.h b/tools/aapt/Main.h
index 34c4496..f24a023b 100644
--- a/tools/aapt/Main.h
+++ b/tools/aapt/Main.h
@@ -49,7 +49,8 @@
     const sp<AaptAssets>& assets, sp<ApkBuilder>& builder);
 
 extern android::status_t writeResourceSymbols(Bundle* bundle,
-    const sp<AaptAssets>& assets, const String8& pkgName, bool includePrivate);
+        const sp<AaptAssets>& assets, const String8& pkgName,
+        bool includePrivate, bool emitCallback);
 
 extern android::status_t writeProguardFile(Bundle* bundle, const sp<AaptAssets>& assets);
 
@@ -59,9 +60,6 @@
 
 int dumpResources(Bundle* bundle);
 
-String8 getAttribute(const ResXMLTree& tree, const char* ns,
-                            const char* attr, String8* outError);
-
 status_t writeDependencyPreReqs(Bundle* bundle, const sp<AaptAssets>& assets,
                                 FILE* fp, bool includeRaw);
 #endif // __MAIN_H
diff --git a/tools/aapt/Resource.cpp b/tools/aapt/Resource.cpp
index 0a80805..afec5ed 100644
--- a/tools/aapt/Resource.cpp
+++ b/tools/aapt/Resource.cpp
@@ -3,18 +3,18 @@
 //
 // Build resource files from raw assets.
 //
-#include "Main.h"
 #include "AaptAssets.h"
-#include "StringPool.h"
-#include "XMLNode.h"
-#include "ResourceTable.h"
-#include "Images.h"
-
+#include "AaptXml.h"
+#include "CacheUpdater.h"
 #include "CrunchCache.h"
 #include "FileFinder.h"
-#include "CacheUpdater.h"
-
+#include "Images.h"
+#include "IndentPrinter.h"
+#include "Main.h"
+#include "ResourceTable.h"
+#include "StringPool.h"
 #include "WorkQueue.h"
+#include "XMLNode.h"
 
 #if HAVE_PRINTF_ZD
 #  define ZD "%zd"
@@ -770,7 +770,14 @@
     if (!addTagAttribute(root, RESOURCES_ANDROID_NAMESPACE, "versionCode",
             bundle->getVersionCode(), errorOnFailedInsert, replaceVersion)) {
         return UNKNOWN_ERROR;
+    } else {
+        const XMLNode::attribute_entry* attr = root->getAttribute(
+                String16(RESOURCES_ANDROID_NAMESPACE), String16("versionCode"));
+        if (attr != NULL) {
+            bundle->setVersionCode(strdup(String8(attr->string).string()));
+        }
     }
+
     if (!addTagAttribute(root, RESOURCES_ANDROID_NAMESPACE, "versionName",
             bundle->getVersionName(), errorOnFailedInsert, replaceVersion)) {
         return UNKNOWN_ERROR;
@@ -799,6 +806,20 @@
         }
     }
 
+    if (bundle->getPlatformBuildVersionCode() != "") {
+        if (!addTagAttribute(root, "", "platformBuildVersionCode",
+                    bundle->getPlatformBuildVersionCode(), errorOnFailedInsert, true)) {
+            return UNKNOWN_ERROR;
+        }
+    }
+
+    if (bundle->getPlatformBuildVersionName() != "") {
+        if (!addTagAttribute(root, "", "platformBuildVersionName",
+                    bundle->getPlatformBuildVersionName(), errorOnFailedInsert, true)) {
+            return UNKNOWN_ERROR;
+        }
+    }
+
     if (bundle->getDebugMode()) {
         sp<XMLNode> application = root->getChildElement(String16(), String16("application"));
         if (application != NULL) {
@@ -875,6 +896,106 @@
     return NO_ERROR;
 }
 
+static int32_t getPlatformAssetCookie(const AssetManager& assets) {
+    // Find the system package (0x01). AAPT always generates attributes
+    // with the type 0x01, so we're looking for the first attribute
+    // resource in the system package.
+    const ResTable& table = assets.getResources(true);
+    Res_value val;
+    ssize_t idx = table.getResource(0x01010000, &val, true);
+    if (idx != NO_ERROR) {
+        // Try as a bag.
+        const ResTable::bag_entry* entry;
+        ssize_t cnt = table.lockBag(0x01010000, &entry);
+        if (cnt >= 0) {
+            idx = entry->stringBlock;
+        }
+        table.unlockBag(entry);
+    }
+
+    if (idx < 0) {
+        return 0;
+    }
+    return table.getTableCookie(idx);
+}
+
+enum {
+    VERSION_CODE_ATTR = 0x0101021b,
+    VERSION_NAME_ATTR = 0x0101021c,
+};
+
+static ssize_t extractPlatformBuildVersion(ResXMLTree& tree, Bundle* bundle) {
+    size_t len;
+    ResXMLTree::event_code_t code;
+    while ((code = tree.next()) != ResXMLTree::END_DOCUMENT && code != ResXMLTree::BAD_DOCUMENT) {
+        if (code != ResXMLTree::START_TAG) {
+            continue;
+        }
+
+        const char16_t* ctag16 = tree.getElementName(&len);
+        if (ctag16 == NULL) {
+            fprintf(stderr, "ERROR: failed to get XML element name (bad string pool)\n");
+            return UNKNOWN_ERROR;
+        }
+
+        String8 tag(ctag16, len);
+        if (tag != "manifest") {
+            continue;
+        }
+
+        String8 error;
+        int32_t versionCode = AaptXml::getIntegerAttribute(tree, VERSION_CODE_ATTR, &error);
+        if (error != "") {
+            fprintf(stderr, "ERROR: failed to get platform version code\n");
+            return UNKNOWN_ERROR;
+        }
+
+        if (versionCode >= 0 && bundle->getPlatformBuildVersionCode() == "") {
+            bundle->setPlatformBuildVersionCode(String8::format("%d", versionCode));
+        }
+
+        String8 versionName = AaptXml::getAttribute(tree, VERSION_NAME_ATTR, &error);
+        if (error != "") {
+            fprintf(stderr, "ERROR: failed to get platform version name\n");
+            return UNKNOWN_ERROR;
+        }
+
+        if (versionName != "" && bundle->getPlatformBuildVersionName() == "") {
+            bundle->setPlatformBuildVersionName(versionName);
+        }
+        return NO_ERROR;
+    }
+
+    fprintf(stderr, "ERROR: no <manifest> tag found in platform AndroidManifest.xml\n");
+    return UNKNOWN_ERROR;
+}
+
+static ssize_t extractPlatformBuildVersion(AssetManager& assets, Bundle* bundle) {
+    int32_t cookie = getPlatformAssetCookie(assets);
+    if (cookie == 0) {
+        fprintf(stderr, "ERROR: Platform package not found\n");
+        return UNKNOWN_ERROR;
+    }
+
+    ResXMLTree tree;
+    Asset* asset = assets.openNonAsset(cookie, "AndroidManifest.xml", Asset::ACCESS_STREAMING);
+    if (asset == NULL) {
+        fprintf(stderr, "ERROR: Platform AndroidManifest.xml not found\n");
+        return UNKNOWN_ERROR;
+    }
+
+    ssize_t result = NO_ERROR;
+    if (tree.setTo(asset->getBuffer(true), asset->getLength()) != NO_ERROR) {
+        fprintf(stderr, "ERROR: Platform AndroidManifest.xml is corrupt\n");
+        result = UNKNOWN_ERROR;
+    } else {
+        result = extractPlatformBuildVersion(tree, bundle);
+    }
+
+    delete asset;
+    return result;
+}
+
 #define ASSIGN_IT(n) \
         do { \
             ssize_t index = resources->indexOfKey(String8(#n)); \
@@ -1350,6 +1471,17 @@
         return UNKNOWN_ERROR;
     }
 
+    // If we're not overriding the platform build versions,
+    // extract them from the platform APK.
+    if (packageType != ResourceTable::System &&
+            (bundle->getPlatformBuildVersionCode() == "" ||
+            bundle->getPlatformBuildVersionName() == "")) {
+        err = extractPlatformBuildVersion(assets->getAssetManager(), bundle);
+        if (err != NO_ERROR) {
+            return UNKNOWN_ERROR;
+        }
+    }
+
     const sp<AaptFile> manifestFile(androidManifestFile->getFiles().valueAt(0));
     String8 manifestPath(manifestFile->getPrintableSource());
 
@@ -1392,7 +1524,8 @@
             sp<ApkSplit>& split = splits.editItemAt(i);
             sp<AaptFile> flattenedTable = new AaptFile(String8("resources.arsc"),
                     AaptGroupEntry(), String8());
-            err = table.flatten(bundle, split->getResourceFilter(), flattenedTable);
+            err = table.flatten(bundle, split->getResourceFilter(),
+                    flattenedTable, split->isBase());
             if (err != NO_ERROR) {
                 fprintf(stderr, "Failed to generate resource table for split '%s'\n",
                         split->getPrintableName().string());
@@ -1793,6 +1926,77 @@
     return String16();
 }
 
+static status_t writeResourceLoadedCallbackForLayoutClasses(
+    FILE* fp, const sp<AaptAssets>& assets,
+    const sp<AaptSymbols>& symbols, int indent, bool includePrivate)
+{
+    String16 attr16("attr");
+    String16 package16(assets->getPackage());
+
+    const char* indentStr = getIndentSpace(indent);
+    bool hasErrors = false;
+
+    size_t i;
+    size_t N = symbols->getNestedSymbols().size();
+    for (i=0; i<N; i++) {
+        sp<AaptSymbols> nsymbols = symbols->getNestedSymbols().valueAt(i);
+        String8 realClassName(symbols->getNestedSymbols().keyAt(i));
+        String8 nclassName(flattenSymbol(realClassName));
+
+        fprintf(fp,
+                "%sfor(int i = 0; i < styleable.%s.length; ++i) {\n"
+                "%sstyleable.%s[i] = (styleable.%s[i] & 0x00ffffff) | (packageId << 24);\n"
+                "%s}\n",
+                indentStr, nclassName.string(),
+                getIndentSpace(indent+1), nclassName.string(), nclassName.string(),
+                indentStr);
+    }
+
+    return hasErrors ? UNKNOWN_ERROR : NO_ERROR;
+}
+
+static status_t writeResourceLoadedCallback(
+    FILE* fp, const sp<AaptAssets>& assets, bool includePrivate,
+    const sp<AaptSymbols>& symbols, const String8& className, int indent)
+{
+    size_t i;
+    status_t err = NO_ERROR;
+
+    size_t N = symbols->getSymbols().size();
+    for (i=0; i<N; i++) {
+        const AaptSymbolEntry& sym = symbols->getSymbols().valueAt(i);
+        if (sym.typeCode == AaptSymbolEntry::TYPE_UNKNOWN) {
+            continue;
+        }
+        if (!assets->isJavaSymbol(sym, includePrivate)) {
+            continue;
+        }
+        String8 flat_name(flattenSymbol(sym.name));
+        fprintf(fp,
+                "%s%s.%s = (%s.%s & 0x00ffffff) | (packageId << 24);\n",
+                getIndentSpace(indent), className.string(), flat_name.string(),
+                className.string(), flat_name.string());
+    }
+
+    N = symbols->getNestedSymbols().size();
+    for (i=0; i<N; i++) {
+        sp<AaptSymbols> nsymbols = symbols->getNestedSymbols().valueAt(i);
+        String8 nclassName(symbols->getNestedSymbols().keyAt(i));
+        if (nclassName == "styleable") {
+            err = writeResourceLoadedCallbackForLayoutClasses(
+                    fp, assets, nsymbols, indent, includePrivate);
+        } else {
+            err = writeResourceLoadedCallback(fp, assets, includePrivate, nsymbols,
+                    nclassName, indent);
+        }
+        if (err != NO_ERROR) {
+            return err;
+        }
+    }
+
+    return NO_ERROR;
+}
+
 static status_t writeLayoutClasses(
     FILE* fp, const sp<AaptAssets>& assets,
     const sp<AaptSymbols>& symbols, int indent, bool includePrivate, bool nonConstantId)
@@ -2130,7 +2334,7 @@
 static status_t writeSymbolClass(
     FILE* fp, const sp<AaptAssets>& assets, bool includePrivate,
     const sp<AaptSymbols>& symbols, const String8& className, int indent,
-    bool nonConstantId)
+    bool nonConstantId, bool emitCallback)
 {
     fprintf(fp, "%spublic %sfinal class %s {\n",
             getIndentSpace(indent),
@@ -2230,7 +2434,8 @@
         if (nclassName == "styleable") {
             styleableSymbols = nsymbols;
         } else {
-            err = writeSymbolClass(fp, assets, includePrivate, nsymbols, nclassName, indent, nonConstantId);
+            err = writeSymbolClass(fp, assets, includePrivate, nsymbols, nclassName,
+                    indent, nonConstantId, false);
         }
         if (err != NO_ERROR) {
             return err;
@@ -2244,6 +2449,13 @@
         }
     }
 
+    if (emitCallback) {
+        fprintf(fp, "%spublic static void onResourcesLoaded(int packageId) {\n",
+                getIndentSpace(indent));
+        writeResourceLoadedCallback(fp, assets, includePrivate, symbols, className, indent + 1);
+        fprintf(fp, "%s}\n", getIndentSpace(indent));
+    }
+
     indent--;
     fprintf(fp, "%s}\n", getIndentSpace(indent));
     return NO_ERROR;
@@ -2291,7 +2503,7 @@
 }
 
 status_t writeResourceSymbols(Bundle* bundle, const sp<AaptAssets>& assets,
-    const String8& package, bool includePrivate)
+    const String8& package, bool includePrivate, bool emitCallback)
 {
     if (!bundle->getRClassDir()) {
         return NO_ERROR;
@@ -2347,7 +2559,7 @@
             "package %s;\n\n", package.string());
 
         status_t err = writeSymbolClass(fp, assets, includePrivate, symbols,
-                className, 0, bundle->getNonConstantId());
+                className, 0, bundle->getNonConstantId(), emitCallback);
         fclose(fp);
         if (err != NO_ERROR) {
             return err;
@@ -2518,13 +2730,14 @@
                 fprintf(stderr, "ERROR: manifest does not start with <manifest> tag\n");
                 return -1;
             }
-            pkg = getAttribute(tree, NULL, "package", NULL);
+            pkg = AaptXml::getAttribute(tree, NULL, "package");
         } else if (depth == 2) {
             if (tag == "application") {
                 inApplication = true;
                 keepTag = true;
 
-                String8 agent = getAttribute(tree, "http://schemas.android.com/apk/res/android",
+                String8 agent = AaptXml::getAttribute(tree,
+                        "http://schemas.android.com/apk/res/android",
                         "backupAgent", &error);
                 if (agent.length() > 0) {
                     addProguardKeepRule(keep, agent, pkg.string(),
@@ -2540,8 +2753,8 @@
             }
         }
         if (keepTag) {
-            String8 name = getAttribute(tree, "http://schemas.android.com/apk/res/android",
-                    "name", &error);
+            String8 name = AaptXml::getAttribute(tree,
+                    "http://schemas.android.com/apk/res/android", "name", &error);
             if (error != "") {
                 fprintf(stderr, "ERROR: %s\n", error.string());
                 return -1;
diff --git a/tools/aapt/ResourceFilter.cpp b/tools/aapt/ResourceFilter.cpp
index de8b4fc..fc95e14 100644
--- a/tools/aapt/ResourceFilter.cpp
+++ b/tools/aapt/ResourceFilter.cpp
@@ -56,24 +56,34 @@
         return true;
     }
 
+    uint32_t matchedAxis = 0x0;
     const size_t N = mConfigs.size();
     for (size_t i = 0; i < N; i++) {
         const std::pair<ConfigDescription, uint32_t>& entry = mConfigs[i];
         uint32_t diff = entry.first.diff(config);
         if ((diff & entry.second) == 0) {
-            return true;
+            // Mark the axis that was matched.
+            matchedAxis |= entry.second;
         } else if ((diff & entry.second) == ResTable_config::CONFIG_LOCALE) {
             // If the locales differ, but the languages are the same and
             // the locale we are matching only has a language specified,
             // we match.
-            if (config.language[0] && memcmp(config.language, entry.first.language, sizeof(config.language)) == 0) {
+            if (config.language[0] &&
+                    memcmp(config.language, entry.first.language, sizeof(config.language)) == 0) {
                 if (config.country[0] == 0) {
-                    return true;
+                    matchedAxis |= ResTable_config::CONFIG_LOCALE;
                 }
             }
+        } else if ((diff & entry.second) == ResTable_config::CONFIG_SMALLEST_SCREEN_SIZE) {
+            // Special case if the smallest screen width doesn't match. We check that the
+            // config being matched has a smaller screen width than the filter specified.
+            if (config.smallestScreenWidthDp != 0 &&
+                    config.smallestScreenWidthDp < entry.first.smallestScreenWidthDp) {
+                matchedAxis |= ResTable_config::CONFIG_SMALLEST_SCREEN_SIZE;
+            }
         }
     }
-    return false;
+    return matchedAxis == (mConfigMask & mask);
 }
 
 status_t
diff --git a/tools/aapt/ResourceFilter.h b/tools/aapt/ResourceFilter.h
index f459584..d6430c0 100644
--- a/tools/aapt/ResourceFilter.h
+++ b/tools/aapt/ResourceFilter.h
@@ -24,8 +24,7 @@
 };
 
 /**
- * Implements logic for parsing and handling "-c" and "--preferred-configurations"
- * options.
+ * Implements logic for parsing and handling "-c" options.
  */
 class WeakResourceFilter : public ResourceFilter {
 public:
diff --git a/tools/aapt/ResourceTable.cpp b/tools/aapt/ResourceTable.cpp
index cf1d4fd..8341de6 100644
--- a/tools/aapt/ResourceTable.cpp
+++ b/tools/aapt/ResourceTable.cpp
@@ -484,15 +484,6 @@
                 attr.hasErrors = true;
             }
 
-            // Make sure an id is defined for this enum/flag identifier...
-            if (!attr.hasErrors && !outTable->hasBagOrEntry(itemIdent, &id16, &myPackage)) {
-                err = outTable->startBag(SourcePos(in->getPrintableSource(), block.getLineNumber()),
-                                         myPackage, id16, itemIdent, String16(), NULL);
-                if (err != NO_ERROR) {
-                    attr.hasErrors = true;
-                }
-            }
-
             if (!attr.hasErrors) {
                 if (enumOrFlagsComment.size() == 0) {
                     enumOrFlagsComment.append(mayOrMust(attr.type,
@@ -2083,10 +2074,11 @@
     return mNumLocal > 0;
 }
 
-sp<AaptFile> ResourceTable::flatten(Bundle* bundle, const sp<const ResourceFilter>& filter)
+sp<AaptFile> ResourceTable::flatten(Bundle* bundle, const sp<const ResourceFilter>& filter,
+        const bool isBase)
 {
     sp<AaptFile> data = new AaptFile(String8(), AaptGroupEntry(), String8());
-    status_t err = flatten(bundle, filter, data);
+    status_t err = flatten(bundle, filter, data, isBase);
     return err == NO_ERROR ? data : NULL;
 }
 
@@ -2508,11 +2500,13 @@
         sp<Type> attr = p->getType(String16("attr"), unknown);
 
         // Assign indices...
-        for (ti=0; ti<N; ti++) {
+        const size_t typeCount = p->getOrderedTypes().size();
+        for (size_t ti = 0; ti < typeCount; ti++) {
             sp<Type> t = p->getOrderedTypes().itemAt(ti);
             if (t == NULL) {
                 continue;
             }
+
             err = t->applyPublicEntryOrder();
             if (err != NO_ERROR && firstError == NO_ERROR) {
                 firstError = err;
@@ -2534,7 +2528,7 @@
         }
 
         // Assign resource IDs to keys in bags...
-        for (ti=0; ti<N; ti++) {
+        for (size_t ti = 0; ti < typeCount; ti++) {
             sp<Type> t = p->getOrderedTypes().itemAt(ti);
             if (t == NULL) {
                 continue;
@@ -2580,8 +2574,12 @@
                 continue;
             }
             const size_t N = t->getOrderedConfigs().size();
-            sp<AaptSymbols> typeSymbols;
-            typeSymbols = outSymbols->addNestedSymbol(String8(t->getName()), t->getPos());
+            sp<AaptSymbols> typeSymbols =
+                    outSymbols->addNestedSymbol(String8(t->getName()), t->getPos());
+            if (typeSymbols == NULL) {
+                return UNKNOWN_ERROR;
+            }
+
             for (size_t ci=0; ci<N; ci++) {
                 sp<ConfigList> c = t->getOrderedConfigs().itemAt(ci);
                 if (c == NULL) {
@@ -2706,7 +2704,9 @@
     return err;
 }
 
-status_t ResourceTable::flatten(Bundle* bundle, const sp<const ResourceFilter>& filter, const sp<AaptFile>& dest)
+status_t ResourceTable::flatten(Bundle* bundle, const sp<const ResourceFilter>& filter,
+        const sp<AaptFile>& dest,
+        const bool isBase)
 {
     const ConfigDescription nullConfig;
 
@@ -2719,6 +2719,16 @@
 
     // The libraries this table references.
     Vector<sp<Package> > libraryPackages;
+    const ResTable& table = mAssets->getIncludedResources();
+    const size_t basePackageCount = table.getBasePackageCount();
+    for (size_t i = 0; i < basePackageCount; i++) {
+        size_t packageId = table.getBasePackageId(i);
+        String16 packageName(table.getBasePackageName(i));
+        if (packageId > 0x01 && packageId != 0x7f &&
+                packageName != String16("android")) {
+            libraryPackages.add(sp<Package>(new Package(packageName, packageId)));
+        }
+    }
 
     // Iterate through all data, collecting all values (strings,
     // references, etc).
@@ -2727,22 +2737,7 @@
     for (pi=0; pi<N; pi++) {
         sp<Package> p = mOrderedPackages.itemAt(pi);
         if (p->getTypes().size() == 0) {
-            // Empty, this is an imported package being used as
-            // a shared library. We do not flatten this package.
-            if (p->getAssignedId() != 0x01 && p->getName() != String16("android")) {
-                // This is not the base Android package, and it is a library
-                // so we must add a reference to the library when flattening.
-                libraryPackages.add(p);
-            }
             continue;
-        } else if (p->getAssignedId() == 0x00) {
-            if (mPackageType != SharedLibrary) {
-                fprintf(stderr, "ERROR: Package %s can not have ID=0x00 unless building a shared library.",
-                        String8(p->getName()).string());
-                return UNKNOWN_ERROR;
-            }
-            // If this is a shared library, we also include ourselves as an entry.
-            libraryPackages.add(p);
         }
 
         StringPool typeStrings(useUTF8);
@@ -2780,6 +2775,13 @@
                 configTypeName = "2value";
             }
 
+            // mipmaps don't get filtered, so they will
+            // allways end up in the base. Make sure they
+            // don't end up in a split.
+            if (typeName == mipmap16 && !isBase) {
+                continue;
+            }
+
             const bool filterable = (typeName != mipmap16);
 
             const size_t N = t->getOrderedConfigs().size();
@@ -2883,10 +2885,12 @@
             return amt;
         }
 
-        status_t err = flattenLibraryTable(data, libraryPackages);
-        if (err != NO_ERROR) {
-            fprintf(stderr, "ERROR: failed to write library table\n");
-            return err;
+        if (isBase) {
+            status_t err = flattenLibraryTable(data, libraryPackages);
+            if (err != NO_ERROR) {
+                fprintf(stderr, "ERROR: failed to write library table\n");
+                return err;
+            }
         }
 
         // Build the type chunks inside of this package.
@@ -2902,6 +2906,7 @@
                 continue;
             }
             const bool filterable = (typeName != mipmap16);
+            const bool skipEntireType = (typeName == mipmap16 && !isBase);
 
             const size_t N = t != NULL ? t->getOrderedConfigs().size() : 0;
 
@@ -2939,6 +2944,11 @@
                     if (cl->getPublic()) {
                         typeSpecFlags[ei] |= htodl(ResTable_typeSpec::SPEC_PUBLIC);
                     }
+
+                    if (skipEntireType) {
+                        continue;
+                    }
+
                     const size_t CN = cl->getEntries().size();
                     for (size_t ci=0; ci<CN; ci++) {
                         if (filterable && !filter->match(cl->getEntries().keyAt(ci))) {
@@ -2955,6 +2965,10 @@
                 }
             }
             
+            if (skipEntireType) {
+                continue;
+            }
+
             // We need to write one type chunk for each configuration for
             // which we have entries in this type.
             const size_t NC = t->getUniqueConfigs().size();
@@ -3154,7 +3168,8 @@
 
         const size_t libStart = dest->getSize();
         const size_t count = libs.size();
-        ResTable_lib_header* libHeader = (ResTable_lib_header*) dest->editDataInRange(libStart, sizeof(ResTable_lib_header));
+        ResTable_lib_header* libHeader = (ResTable_lib_header*) dest->editDataInRange(
+                libStart, sizeof(ResTable_lib_header));
 
         memset(libHeader, 0, sizeof(*libHeader));
         libHeader->header.type = htods(RES_TABLE_LIBRARY_TYPE);
@@ -3170,7 +3185,8 @@
                         String8(libPackage->getName()).string(),
                         (uint8_t)libPackage->getAssignedId()));
 
-            ResTable_lib_entry* entry = (ResTable_lib_entry*) dest->editDataInRange(entryStart, sizeof(ResTable_lib_entry));
+            ResTable_lib_entry* entry = (ResTable_lib_entry*) dest->editDataInRange(
+                    entryStart, sizeof(ResTable_lib_entry));
             memset(entry, 0, sizeof(*entry));
             entry->packageId = htodl(libPackage->getAssignedId());
             strcpy16_htod(entry->packageName, libPackage->getName().string());
@@ -3296,11 +3312,16 @@
     Item item(sourcePos, false, value, style);
 
     if (mType == TYPE_BAG) {
-        const Item& item(mBag.valueAt(0));
-        sourcePos.error("Resource entry %s is already defined as a bag.\n"
-                        "%s:%d: Originally defined here.\n",
-                        String8(mName).string(),
-                        item.sourcePos.file.string(), item.sourcePos.line);
+        if (mBag.size() == 0) {
+            sourcePos.error("Resource entry %s is already defined as a bag.",
+                    String8(mName).string());
+        } else {
+            const Item& item(mBag.valueAt(0));
+            sourcePos.error("Resource entry %s is already defined as a bag.\n"
+                            "%s:%d: Originally defined here.\n",
+                            String8(mName).string(),
+                            item.sourcePos.file.string(), item.sourcePos.line);
+        }
         return UNKNOWN_ERROR;
     }
     if ( (mType != TYPE_UNKNOWN) && (overwrite == false) ) {
@@ -3374,6 +3395,9 @@
         if (it.isId) {
             if (!table->hasBagOrEntry(key, &id16, &package)) {
                 String16 value("false");
+                NOISY(fprintf(stderr, "Generating %s:id/%s\n",
+                        String8(package).string(),
+                        String8(key).string()));
                 status_t err = table->addEntry(SourcePos(String8("<generated>"), 0), package,
                                                id16, key, value);
                 if (err != NO_ERROR) {
diff --git a/tools/aapt/ResourceTable.h b/tools/aapt/ResourceTable.h
index d4f47ef..3721de4 100644
--- a/tools/aapt/ResourceTable.h
+++ b/tools/aapt/ResourceTable.h
@@ -165,7 +165,8 @@
     size_t numLocalResources() const;
     bool hasResources() const;
 
-    sp<AaptFile> flatten(Bundle* bundle, const sp<const ResourceFilter>& filter);
+    sp<AaptFile> flatten(Bundle* bundle, const sp<const ResourceFilter>& filter,
+            const bool isBase);
 
     static inline uint32_t makeResId(uint32_t packageId,
                                      uint32_t typeId,
@@ -206,7 +207,8 @@
     void addLocalization(const String16& name, const String8& locale, const SourcePos& src);
     status_t validateLocalizations(void);
 
-    status_t flatten(Bundle* bundle, const sp<const ResourceFilter>& filter, const sp<AaptFile>& dest);
+    status_t flatten(Bundle* bundle, const sp<const ResourceFilter>& filter,
+            const sp<AaptFile>& dest, const bool isBase);
     status_t flattenLibraryTable(const sp<AaptFile>& dest, const Vector<sp<Package> >& libs);
 
     void writePublicDefinitions(const String16& package, FILE* fp);
diff --git a/tools/aapt/tests/ResourceFilter_test.cpp b/tools/aapt/tests/ResourceFilter_test.cpp
index 30697bb..bbc2e02 100644
--- a/tools/aapt/tests/ResourceFilter_test.cpp
+++ b/tools/aapt/tests/ResourceFilter_test.cpp
@@ -75,6 +75,17 @@
     EXPECT_TRUE(filter.match(config));
 }
 
+TEST(WeakResourceFilterTest, MatchesConfigWithOneMatchingAxis) {
+    WeakResourceFilter filter;
+    ASSERT_EQ(NO_ERROR, filter.parse(String8("fr_FR,sw360dp,normal,en_US")));
+
+    ConfigDescription config;
+    config.language[0] = 'e';
+    config.language[1] = 'n';
+
+    EXPECT_TRUE(filter.match(config));
+}
+
 TEST(WeakResourceFilterTest, DoesNotMatchConfigWithDifferentValueAxis) {
     WeakResourceFilter filter;
     ASSERT_EQ(NO_ERROR, filter.parse(String8("fr")));
@@ -86,6 +97,32 @@
     EXPECT_FALSE(filter.match(config));
 }
 
+TEST(WeakResourceFilterTest, DoesNotMatchWhenOneQualifierIsExplicitlyNotMatched) {
+    WeakResourceFilter filter;
+    ASSERT_EQ(NO_ERROR, filter.parse(String8("fr_FR,en_US,normal,large,xxhdpi,sw320dp")));
+
+    ConfigDescription config;
+    config.language[0] = 'f';
+    config.language[1] = 'r';
+    config.smallestScreenWidthDp = 600;
+    config.version = 13;
+
+    EXPECT_FALSE(filter.match(config));
+}
+
+TEST(WeakResourceFilterTest, MatchesSmallestWidthWhenSmaller) {
+    WeakResourceFilter filter;
+    ASSERT_EQ(NO_ERROR, filter.parse(String8("sw600dp")));
+
+    ConfigDescription config;
+    config.language[0] = 'f';
+    config.language[1] = 'r';
+    config.smallestScreenWidthDp = 320;
+    config.version = 13;
+
+    EXPECT_TRUE(filter.match(config));
+}
+
 TEST(WeakResourceFilterTest, MatchesConfigWithSameLanguageButNoRegionSpecified) {
     WeakResourceFilter filter;
     ASSERT_EQ(NO_ERROR, filter.parse(String8("de-rDE")));
@@ -126,3 +163,38 @@
     EXPECT_TRUE(filter.match(config));
 }
 
+TEST(StrongResourceFilterTest, MatchesDensities) {
+    ConfigDescription config;
+    config.density = 160;
+    config.version = 4;
+    std::set<ConfigDescription> configs;
+    configs.insert(config);
+
+    StrongResourceFilter filter(configs);
+
+    ConfigDescription expectedConfig;
+    expectedConfig.density = 160;
+    expectedConfig.version = 4;
+    ASSERT_TRUE(filter.match(expectedConfig));
+}
+
+TEST(StrongResourceFilterTest, MatchOnlyMdpiAndExcludeAllOthers) {
+    std::set<ConfigDescription> configsToMatch;
+    ConfigDescription config;
+    config.density = 160;
+    config.version = 4;
+    configsToMatch.insert(config);
+
+    std::set<ConfigDescription> configsToNotMatch;
+    config.density = 480;
+    configsToNotMatch.insert(config);
+
+    AndResourceFilter filter;
+    filter.addFilter(new InverseResourceFilter(new StrongResourceFilter(configsToNotMatch)));
+    filter.addFilter(new StrongResourceFilter(configsToMatch));
+
+    ConfigDescription expectedConfig;
+    expectedConfig.density = 160;
+    expectedConfig.version = 4;
+    ASSERT_TRUE(filter.match(expectedConfig));
+}
diff --git a/tools/apilint/apilint.py b/tools/apilint/apilint.py
new file mode 100644
index 0000000..393d2ec
--- /dev/null
+++ b/tools/apilint/apilint.py
@@ -0,0 +1,797 @@
+#!/usr/bin/env python
+
+# Copyright (C) 2014 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.
+
+"""
+Enforces common Android public API design patterns.  It ignores lint messages from
+a previous API level, if provided.
+
+Usage: apilint.py current.txt
+Usage: apilint.py current.txt previous.txt
+
+You can also splice in blame details like this:
+$ git blame api/current.txt -t -e > /tmp/currentblame.txt
+$ apilint.py /tmp/currentblame.txt previous.txt --no-color
+"""
+
+import re, sys, collections, traceback
+
+
+BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE = range(8)
+
+def format(fg=None, bg=None, bright=False, bold=False, dim=False, reset=False):
+    # manually derived from http://en.wikipedia.org/wiki/ANSI_escape_code#Codes
+    if "--no-color" in sys.argv: return ""
+    codes = []
+    if reset: codes.append("0")
+    else:
+        if not fg is None: codes.append("3%d" % (fg))
+        if not bg is None:
+            if not bright: codes.append("4%d" % (bg))
+            else: codes.append("10%d" % (bg))
+        if bold: codes.append("1")
+        elif dim: codes.append("2")
+        else: codes.append("22")
+    return "\033[%sm" % (";".join(codes))
+
+
+class Field():
+    def __init__(self, clazz, raw, blame):
+        self.clazz = clazz
+        self.raw = raw.strip(" {;")
+        self.blame = blame
+
+        raw = raw.split()
+        self.split = list(raw)
+
+        for r in ["field", "volatile", "transient", "public", "protected", "static", "final", "deprecated"]:
+            while r in raw: raw.remove(r)
+
+        self.typ = raw[0]
+        self.name = raw[1].strip(";")
+        if len(raw) >= 4 and raw[2] == "=":
+            self.value = raw[3].strip(';"')
+        else:
+            self.value = None
+
+        self.ident = self.raw.replace(" deprecated ", " ")
+
+    def __repr__(self):
+        return self.raw
+
+
+class Method():
+    def __init__(self, clazz, raw, blame):
+        self.clazz = clazz
+        self.raw = raw.strip(" {;")
+        self.blame = blame
+
+        # drop generics for now
+        raw = re.sub("<.+?>", "", raw)
+
+        raw = re.split("[\s(),;]+", raw)
+        for r in ["", ";"]:
+            while r in raw: raw.remove(r)
+        self.split = list(raw)
+
+        for r in ["method", "public", "protected", "static", "final", "deprecated", "abstract"]:
+            while r in raw: raw.remove(r)
+
+        self.typ = raw[0]
+        self.name = raw[1]
+        self.args = []
+        for r in raw[2:]:
+            if r == "throws": break
+            self.args.append(r)
+
+        # identity for compat purposes
+        ident = self.raw
+        ident = ident.replace(" deprecated ", " ")
+        ident = ident.replace(" synchronized ", " ")
+        ident = re.sub("<.+?>", "", ident)
+        if " throws " in ident:
+            ident = ident[:ident.index(" throws ")]
+        self.ident = ident
+
+    def __repr__(self):
+        return self.raw
+
+
+class Class():
+    def __init__(self, pkg, raw, blame):
+        self.pkg = pkg
+        self.raw = raw.strip(" {;")
+        self.blame = blame
+        self.ctors = []
+        self.fields = []
+        self.methods = []
+
+        raw = raw.split()
+        self.split = list(raw)
+        if "class" in raw:
+            self.fullname = raw[raw.index("class")+1]
+        elif "interface" in raw:
+            self.fullname = raw[raw.index("interface")+1]
+        else:
+            raise ValueError("Funky class type %s" % (self.raw))
+
+        if "extends" in raw:
+            self.extends = raw[raw.index("extends")+1]
+        else:
+            self.extends = None
+
+        self.fullname = self.pkg.name + "." + self.fullname
+        self.name = self.fullname[self.fullname.rindex(".")+1:]
+
+    def __repr__(self):
+        return self.raw
+
+
+class Package():
+    def __init__(self, raw, blame):
+        self.raw = raw.strip(" {;")
+        self.blame = blame
+
+        raw = raw.split()
+        self.name = raw[raw.index("package")+1]
+
+    def __repr__(self):
+        return self.raw
+
+
+def parse_api(fn):
+    api = {}
+    pkg = None
+    clazz = None
+    blame = None
+
+    re_blame = re.compile("^([a-z0-9]{7,}) \(<([^>]+)>.+?\) (.+?)$")
+
+    with open(fn) as f:
+        for raw in f.readlines():
+            raw = raw.rstrip()
+            match = re_blame.match(raw)
+            if match is not None:
+                blame = match.groups()[0:2]
+                raw = match.groups()[2]
+            else:
+                blame = None
+
+            if raw.startswith("package"):
+                pkg = Package(raw, blame)
+            elif raw.startswith("  ") and raw.endswith("{"):
+                clazz = Class(pkg, raw, blame)
+                api[clazz.fullname] = clazz
+            elif raw.startswith("    ctor"):
+                clazz.ctors.append(Method(clazz, raw, blame))
+            elif raw.startswith("    method"):
+                clazz.methods.append(Method(clazz, raw, blame))
+            elif raw.startswith("    field"):
+                clazz.fields.append(Field(clazz, raw, blame))
+
+    return api
+
+
+failures = {}
+
+def _fail(clazz, detail, msg):
+    """Records an API failure to be processed later."""
+    global failures
+
+    sig = "%s-%s-%s" % (clazz.fullname, repr(detail), msg)
+    sig = sig.replace(" deprecated ", " ")
+
+    res = msg
+    blame = clazz.blame
+    if detail is not None:
+        res += "\n    in " + repr(detail)
+        blame = detail.blame
+    res += "\n    in " + repr(clazz)
+    res += "\n    in " + repr(clazz.pkg)
+    if blame is not None:
+        res += "\n    last modified by %s in %s" % (blame[1], blame[0])
+    failures[sig] = res
+
+def warn(clazz, detail, msg):
+    _fail(clazz, detail, "%sWarning:%s %s" % (format(fg=YELLOW, bg=BLACK, bold=True), format(reset=True), msg))
+
+def error(clazz, detail, msg):
+    _fail(clazz, detail, "%sError:%s %s" % (format(fg=RED, bg=BLACK, bold=True), format(reset=True), msg))
+
+
+def verify_constants(clazz):
+    """All static final constants must be FOO_NAME style."""
+    if re.match("android\.R\.[a-z]+", clazz.fullname): return
+
+    for f in clazz.fields:
+        if "static" in f.split and "final" in f.split:
+            if re.match("[A-Z0-9_]+", f.name) is None:
+                error(clazz, f, "Constant field names should be FOO_NAME")
+
+
+def verify_enums(clazz):
+    """Enums are bad, mmkay?"""
+    if "extends java.lang.Enum" in clazz.raw:
+        error(clazz, None, "Enums are not allowed")
+
+
+def verify_class_names(clazz):
+    """Try catching malformed class names like myMtp or MTPUser."""
+    if clazz.fullname.startswith("android.opengl"): return
+    if clazz.fullname.startswith("android.renderscript"): return
+    if re.match("android\.R\.[a-z]+", clazz.fullname): return
+
+    if re.search("[A-Z]{2,}", clazz.name) is not None:
+        warn(clazz, None, "Class name style should be Mtp not MTP")
+    if re.match("[^A-Z]", clazz.name):
+        error(clazz, None, "Class must start with uppercase char")
+
+
+def verify_method_names(clazz):
+    """Try catching malformed method names, like Foo() or getMTU()."""
+    if clazz.fullname.startswith("android.opengl"): return
+    if clazz.fullname.startswith("android.renderscript"): return
+    if clazz.fullname == "android.system.OsConstants": return
+
+    for m in clazz.methods:
+        if re.search("[A-Z]{2,}", m.name) is not None:
+            warn(clazz, m, "Method name style should be getMtu() instead of getMTU()")
+        if re.match("[^a-z]", m.name):
+            error(clazz, m, "Method name must start with lowercase char")
+
+
+def verify_callbacks(clazz):
+    """Verify Callback classes.
+    All callback classes must be abstract.
+    All methods must follow onFoo() naming style."""
+    if clazz.fullname == "android.speech.tts.SynthesisCallback": return
+
+    if clazz.name.endswith("Callbacks"):
+        error(clazz, None, "Class name must not be plural")
+    if clazz.name.endswith("Observer"):
+        warn(clazz, None, "Class should be named FooCallback")
+
+    if clazz.name.endswith("Callback"):
+        if "interface" in clazz.split:
+            error(clazz, None, "Callback must be abstract class to enable extension in future API levels")
+
+        for m in clazz.methods:
+            if not re.match("on[A-Z][a-z]*", m.name):
+                error(clazz, m, "Callback method names must be onFoo() style")
+
+
+def verify_listeners(clazz):
+    """Verify Listener classes.
+    All Listener classes must be interface.
+    All methods must follow onFoo() naming style.
+    If only a single method, it must match class name:
+        interface OnFooListener { void onFoo() }"""
+
+    if clazz.name.endswith("Listener"):
+        if " abstract class " in clazz.raw:
+            error(clazz, None, "Listener should be an interface, otherwise renamed Callback")
+
+        for m in clazz.methods:
+            if not re.match("on[A-Z][a-z]*", m.name):
+                error(clazz, m, "Listener method names must be onFoo() style")
+
+        if len(clazz.methods) == 1 and clazz.name.startswith("On"):
+            m = clazz.methods[0]
+            if (m.name + "Listener").lower() != clazz.name.lower():
+                error(clazz, m, "Single listener method name should match class name")
+
+
+def verify_actions(clazz):
+    """Verify intent actions.
+    All action names must be named ACTION_FOO.
+    All action values must be scoped by package and match name:
+        package android.foo {
+            String ACTION_BAR = "android.foo.action.BAR";
+        }"""
+    for f in clazz.fields:
+        if f.value is None: continue
+        if f.name.startswith("EXTRA_"): continue
+        if f.name == "SERVICE_INTERFACE" or f.name == "PROVIDER_INTERFACE": continue
+
+        if "static" in f.split and "final" in f.split and f.typ == "java.lang.String":
+            if "_ACTION" in f.name or "ACTION_" in f.name or ".action." in f.value.lower():
+                if not f.name.startswith("ACTION_"):
+                    error(clazz, f, "Intent action constant name must be ACTION_FOO")
+                else:
+                    if clazz.fullname == "android.content.Intent":
+                        prefix = "android.intent.action"
+                    elif clazz.fullname == "android.provider.Settings":
+                        prefix = "android.settings"
+                    elif clazz.fullname == "android.app.admin.DevicePolicyManager" or clazz.fullname == "android.app.admin.DeviceAdminReceiver":
+                        prefix = "android.app.action"
+                    else:
+                        prefix = clazz.pkg.name + ".action"
+                    expected = prefix + "." + f.name[7:]
+                    if f.value != expected:
+                        error(clazz, f, "Inconsistent action value; expected %s" % (expected))
+
+
+def verify_extras(clazz):
+    """Verify intent extras.
+    All extra names must be named EXTRA_FOO.
+    All extra values must be scoped by package and match name:
+        package android.foo {
+            String EXTRA_BAR = "android.foo.extra.BAR";
+        }"""
+    if clazz.fullname == "android.app.Notification": return
+    if clazz.fullname == "android.appwidget.AppWidgetManager": return
+
+    for f in clazz.fields:
+        if f.value is None: continue
+        if f.name.startswith("ACTION_"): continue
+
+        if "static" in f.split and "final" in f.split and f.typ == "java.lang.String":
+            if "_EXTRA" in f.name or "EXTRA_" in f.name or ".extra" in f.value.lower():
+                if not f.name.startswith("EXTRA_"):
+                    error(clazz, f, "Intent extra must be EXTRA_FOO")
+                else:
+                    if clazz.pkg.name == "android.content" and clazz.name == "Intent":
+                        prefix = "android.intent.extra"
+                    elif clazz.pkg.name == "android.app.admin":
+                        prefix = "android.app.extra"
+                    else:
+                        prefix = clazz.pkg.name + ".extra"
+                    expected = prefix + "." + f.name[6:]
+                    if f.value != expected:
+                        error(clazz, f, "Inconsistent extra value; expected %s" % (expected))
+
+
+def verify_equals(clazz):
+    """Verify that equals() and hashCode() must be overridden together."""
+    methods = [ m.name for m in clazz.methods ]
+    eq = "equals" in methods
+    hc = "hashCode" in methods
+    if eq != hc:
+        error(clazz, None, "Must override both equals and hashCode; missing one")
+
+
+def verify_parcelable(clazz):
+    """Verify that Parcelable objects aren't hiding required bits."""
+    if "implements android.os.Parcelable" in clazz.raw:
+        creator = [ i for i in clazz.fields if i.name == "CREATOR" ]
+        write = [ i for i in clazz.methods if i.name == "writeToParcel" ]
+        describe = [ i for i in clazz.methods if i.name == "describeContents" ]
+
+        if len(creator) == 0 or len(write) == 0 or len(describe) == 0:
+            error(clazz, None, "Parcelable requires CREATOR, writeToParcel, and describeContents; missing one")
+
+
+def verify_protected(clazz):
+    """Verify that no protected methods are allowed."""
+    for m in clazz.methods:
+        if "protected" in m.split:
+            error(clazz, m, "No protected methods; must be public")
+    for f in clazz.fields:
+        if "protected" in f.split:
+            error(clazz, f, "No protected fields; must be public")
+
+
+def verify_fields(clazz):
+    """Verify that all exposed fields are final.
+    Exposed fields must follow myName style.
+    Catch internal mFoo objects being exposed."""
+
+    IGNORE_BARE_FIELDS = [
+        "android.app.ActivityManager.RecentTaskInfo",
+        "android.app.Notification",
+        "android.content.pm.ActivityInfo",
+        "android.content.pm.ApplicationInfo",
+        "android.content.pm.FeatureGroupInfo",
+        "android.content.pm.InstrumentationInfo",
+        "android.content.pm.PackageInfo",
+        "android.content.pm.PackageItemInfo",
+        "android.os.Message",
+        "android.system.StructPollfd",
+    ]
+
+    for f in clazz.fields:
+        if not "final" in f.split:
+            if clazz.fullname in IGNORE_BARE_FIELDS:
+                pass
+            elif clazz.fullname.endswith("LayoutParams"):
+                pass
+            elif clazz.fullname.startswith("android.util.Mutable"):
+                pass
+            else:
+                error(clazz, f, "Bare fields must be marked final; consider adding accessors")
+
+        if not "static" in f.split:
+            if not re.match("[a-z]([a-zA-Z]+)?", f.name):
+                error(clazz, f, "Non-static fields must be named with myField style")
+
+        if re.match("[ms][A-Z]", f.name):
+            error(clazz, f, "Don't expose your internal objects")
+
+        if re.match("[A-Z_]+", f.name):
+            if "static" not in f.split or "final" not in f.split:
+                error(clazz, f, "Constants must be marked static final")
+
+
+def verify_register(clazz):
+    """Verify parity of registration methods.
+    Callback objects use register/unregister methods.
+    Listener objects use add/remove methods."""
+    methods = [ m.name for m in clazz.methods ]
+    for m in clazz.methods:
+        if "Callback" in m.raw:
+            if m.name.startswith("register"):
+                other = "unregister" + m.name[8:]
+                if other not in methods:
+                    error(clazz, m, "Missing unregister method")
+            if m.name.startswith("unregister"):
+                other = "register" + m.name[10:]
+                if other not in methods:
+                    error(clazz, m, "Missing register method")
+
+            if m.name.startswith("add") or m.name.startswith("remove"):
+                error(clazz, m, "Callback methods should be named register/unregister")
+
+        if "Listener" in m.raw:
+            if m.name.startswith("add"):
+                other = "remove" + m.name[3:]
+                if other not in methods:
+                    error(clazz, m, "Missing remove method")
+            if m.name.startswith("remove") and not m.name.startswith("removeAll"):
+                other = "add" + m.name[6:]
+                if other not in methods:
+                    error(clazz, m, "Missing add method")
+
+            if m.name.startswith("register") or m.name.startswith("unregister"):
+                error(clazz, m, "Listener methods should be named add/remove")
+
+
+def verify_sync(clazz):
+    """Verify synchronized methods aren't exposed."""
+    for m in clazz.methods:
+        if "synchronized" in m.split:
+            error(clazz, m, "Internal lock exposed")
+
+
+def verify_intent_builder(clazz):
+    """Verify that Intent builders are createFooIntent() style."""
+    if clazz.name == "Intent": return
+
+    for m in clazz.methods:
+        if m.typ == "android.content.Intent":
+            if m.name.startswith("create") and m.name.endswith("Intent"):
+                pass
+            else:
+                error(clazz, m, "Methods creating an Intent should be named createFooIntent()")
+
+
+def verify_helper_classes(clazz):
+    """Verify that helper classes are named consistently with what they extend.
+    All developer extendable methods should be named onFoo()."""
+    test_methods = False
+    if "extends android.app.Service" in clazz.raw:
+        test_methods = True
+        if not clazz.name.endswith("Service"):
+            error(clazz, None, "Inconsistent class name; should be FooService")
+
+        found = False
+        for f in clazz.fields:
+            if f.name == "SERVICE_INTERFACE":
+                found = True
+                if f.value != clazz.fullname:
+                    error(clazz, f, "Inconsistent interface constant; expected %s" % (clazz.fullname))
+
+        if not found:
+            warn(clazz, None, "Missing SERVICE_INTERFACE constant")
+
+        if "abstract" in clazz.split and not clazz.fullname.startswith("android.service."):
+            warn(clazz, None, "Services extended by developers should be under android.service")
+
+    if "extends android.content.ContentProvider" in clazz.raw:
+        test_methods = True
+        if not clazz.name.endswith("Provider"):
+            error(clazz, None, "Inconsistent class name; should be FooProvider")
+
+        found = False
+        for f in clazz.fields:
+            if f.name == "PROVIDER_INTERFACE":
+                found = True
+                if f.value != clazz.fullname:
+                    error(clazz, f, "Inconsistent interface name; expected %s" % (clazz.fullname))
+
+        if not found:
+            warn(clazz, None, "Missing PROVIDER_INTERFACE constant")
+
+        if "abstract" in clazz.split and not clazz.fullname.startswith("android.provider."):
+            warn(clazz, None, "Providers extended by developers should be under android.provider")
+
+    if "extends android.content.BroadcastReceiver" in clazz.raw:
+        test_methods = True
+        if not clazz.name.endswith("Receiver"):
+            error(clazz, None, "Inconsistent class name; should be FooReceiver")
+
+    if "extends android.app.Activity" in clazz.raw:
+        test_methods = True
+        if not clazz.name.endswith("Activity"):
+            error(clazz, None, "Inconsistent class name; should be FooActivity")
+
+    if test_methods:
+        for m in clazz.methods:
+            if "final" in m.split: continue
+            if not re.match("on[A-Z]", m.name):
+                if "abstract" in m.split:
+                    error(clazz, m, "Methods implemented by developers must be named onFoo()")
+                else:
+                    warn(clazz, m, "If implemented by developer, should be named onFoo(); otherwise consider marking final")
+
+
+def verify_builder(clazz):
+    """Verify builder classes.
+    Methods should return the builder to enable chaining."""
+    if " extends " in clazz.raw: return
+    if not clazz.name.endswith("Builder"): return
+
+    if clazz.name != "Builder":
+        warn(clazz, None, "Builder should be defined as inner class")
+
+    has_build = False
+    for m in clazz.methods:
+        if m.name == "build":
+            has_build = True
+            continue
+
+        if m.name.startswith("get"): continue
+        if m.name.startswith("clear"): continue
+
+        if m.name.startswith("with"):
+            error(clazz, m, "Builder methods names must follow setFoo() style")
+
+        if m.name.startswith("set"):
+            if not m.typ.endswith(clazz.fullname):
+                warn(clazz, m, "Methods should return the builder")
+
+    if not has_build:
+        warn(clazz, None, "Missing build() method")
+
+
+def verify_aidl(clazz):
+    """Catch people exposing raw AIDL."""
+    if "extends android.os.Binder" in clazz.raw or "implements android.os.IInterface" in clazz.raw:
+        error(clazz, None, "Exposing raw AIDL interface")
+
+
+def verify_internal(clazz):
+    """Catch people exposing internal classes."""
+    if clazz.pkg.name.startswith("com.android"):
+        error(clazz, None, "Exposing internal class")
+
+
+def verify_layering(clazz):
+    """Catch package layering violations.
+    For example, something in android.os depending on android.app."""
+    ranking = [
+        ["android.service","android.accessibilityservice","android.inputmethodservice","android.printservice","android.appwidget","android.webkit","android.preference","android.gesture","android.print"],
+        "android.app",
+        "android.widget",
+        "android.view",
+        "android.animation",
+        "android.provider",
+        ["android.content","android.graphics.drawable"],
+        "android.database",
+        "android.graphics",
+        "android.text",
+        "android.os",
+        "android.util"
+    ]
+
+    def rank(p):
+        for i in range(len(ranking)):
+            if isinstance(ranking[i], list):
+                for j in ranking[i]:
+                    if p.startswith(j): return i
+            else:
+                if p.startswith(ranking[i]): return i
+
+    cr = rank(clazz.pkg.name)
+    if cr is None: return
+
+    for f in clazz.fields:
+        ir = rank(f.typ)
+        if ir and ir < cr:
+            warn(clazz, f, "Field type violates package layering")
+
+    for m in clazz.methods:
+        ir = rank(m.typ)
+        if ir and ir < cr:
+            warn(clazz, m, "Method return type violates package layering")
+        for arg in m.args:
+            ir = rank(arg)
+            if ir and ir < cr:
+                warn(clazz, m, "Method argument type violates package layering")
+
+
+def verify_boolean(clazz, api):
+    """Catches people returning boolean from getFoo() style methods.
+    Ignores when matching setFoo() is present."""
+
+    methods = [ m.name for m in clazz.methods ]
+
+    builder = clazz.fullname + ".Builder"
+    builder_methods = []
+    if builder in api:
+        builder_methods = [ m.name for m in api[builder].methods ]
+
+    for m in clazz.methods:
+        if m.typ == "boolean" and m.name.startswith("get") and m.name != "get" and len(m.args) == 0:
+            setter = "set" + m.name[3:]
+            if setter in methods:
+                pass
+            elif builder is not None and setter in builder_methods:
+                pass
+            else:
+                warn(clazz, m, "Methods returning boolean should be named isFoo, hasFoo, areFoo")
+
+
+def verify_collections(clazz):
+    """Verifies that collection types are interfaces."""
+    if clazz.fullname == "android.os.Bundle": return
+
+    bad = ["java.util.Vector", "java.util.LinkedList", "java.util.ArrayList", "java.util.Stack",
+           "java.util.HashMap", "java.util.HashSet", "android.util.ArraySet", "android.util.ArrayMap"]
+    for m in clazz.methods:
+        if m.typ in bad:
+            error(clazz, m, "Return type is concrete collection; should be interface")
+        for arg in m.args:
+            if arg in bad:
+                error(clazz, m, "Argument is concrete collection; should be interface")
+
+
+def verify_flags(clazz):
+    """Verifies that flags are non-overlapping."""
+    known = collections.defaultdict(int)
+    for f in clazz.fields:
+        if "FLAG_" in f.name:
+            try:
+                val = int(f.value)
+            except:
+                continue
+
+            scope = f.name[0:f.name.index("FLAG_")]
+            if val & known[scope]:
+                warn(clazz, f, "Found overlapping flag constant value")
+            known[scope] |= val
+
+
+def verify_style(api):
+    """Find all style issues in the given API level."""
+    global failures
+
+    failures = {}
+    for key in sorted(api.keys()):
+        clazz = api[key]
+
+        if clazz.pkg.name.startswith("java"): continue
+        if clazz.pkg.name.startswith("junit"): continue
+        if clazz.pkg.name.startswith("org.apache"): continue
+        if clazz.pkg.name.startswith("org.xml"): continue
+        if clazz.pkg.name.startswith("org.json"): continue
+        if clazz.pkg.name.startswith("org.w3c"): continue
+
+        verify_constants(clazz)
+        verify_enums(clazz)
+        verify_class_names(clazz)
+        verify_method_names(clazz)
+        verify_callbacks(clazz)
+        verify_listeners(clazz)
+        verify_actions(clazz)
+        verify_extras(clazz)
+        verify_equals(clazz)
+        verify_parcelable(clazz)
+        verify_protected(clazz)
+        verify_fields(clazz)
+        verify_register(clazz)
+        verify_sync(clazz)
+        verify_intent_builder(clazz)
+        verify_helper_classes(clazz)
+        verify_builder(clazz)
+        verify_aidl(clazz)
+        verify_internal(clazz)
+        verify_layering(clazz)
+        verify_boolean(clazz, api)
+        verify_collections(clazz)
+        verify_flags(clazz)
+
+    return failures
+
+
+def verify_compat(cur, prev):
+    """Find any incompatible API changes between two levels."""
+    global failures
+
+    def class_exists(api, test):
+        return test.fullname in api
+
+    def ctor_exists(api, clazz, test):
+        for m in clazz.ctors:
+            if m.ident == test.ident: return True
+        return False
+
+    def all_methods(api, clazz):
+        methods = list(clazz.methods)
+        if clazz.extends is not None:
+            methods.extend(all_methods(api, api[clazz.extends]))
+        return methods
+
+    def method_exists(api, clazz, test):
+        methods = all_methods(api, clazz)
+        for m in methods:
+            if m.ident == test.ident: return True
+        return False
+
+    def field_exists(api, clazz, test):
+        for f in clazz.fields:
+            if f.ident == test.ident: return True
+        return False
+
+    failures = {}
+    for key in sorted(prev.keys()):
+        prev_clazz = prev[key]
+
+        if not class_exists(cur, prev_clazz):
+            error(prev_clazz, None, "Class removed or incompatible change")
+            continue
+
+        cur_clazz = cur[key]
+
+        for test in prev_clazz.ctors:
+            if not ctor_exists(cur, cur_clazz, test):
+                error(prev_clazz, prev_ctor, "Constructor removed or incompatible change")
+
+        methods = all_methods(prev, prev_clazz)
+        for test in methods:
+            if not method_exists(cur, cur_clazz, test):
+                error(prev_clazz, test, "Method removed or incompatible change")
+
+        for test in prev_clazz.fields:
+            if not field_exists(cur, cur_clazz, test):
+                error(prev_clazz, test, "Field removed or incompatible change")
+
+    return failures
+
+
+cur = parse_api(sys.argv[1])
+cur_fail = verify_style(cur)
+
+if len(sys.argv) > 2:
+    prev = parse_api(sys.argv[2])
+    prev_fail = verify_style(prev)
+
+    # ignore errors from previous API level
+    for p in prev_fail:
+        if p in cur_fail:
+            del cur_fail[p]
+
+    # look for compatibility issues
+    compat_fail = verify_compat(cur, prev)
+
+    print "%s API compatibility issues %s\n" % ((format(fg=WHITE, bg=BLUE, bold=True), format(reset=True)))
+    for f in sorted(compat_fail):
+        print compat_fail[f]
+        print
+
+
+print "%s API style issues %s\n" % ((format(fg=WHITE, bg=BLUE, bold=True), format(reset=True)))
+for f in sorted(cur_fail):
+    print cur_fail[f]
+    print
diff --git a/tools/layoutlib/.idea/codeStyleSettings.xml b/tools/layoutlib/.idea/codeStyleSettings.xml
index 33937b3..b324213 100644
--- a/tools/layoutlib/.idea/codeStyleSettings.xml
+++ b/tools/layoutlib/.idea/codeStyleSettings.xml
@@ -27,12 +27,12 @@
             <package name="" withSubpackages="true" static="true" />
           </value>
         </option>
+        <option name="RIGHT_MARGIN" value="100" />
         <option name="WRAP_WHEN_TYPING_REACHES_RIGHT_MARGIN" value="true" />
         <option name="JD_ALIGN_PARAM_COMMENTS" value="false" />
         <option name="JD_ADD_BLANK_AFTER_PARM_COMMENTS" value="true" />
         <option name="JD_ADD_BLANK_AFTER_RETURN" value="true" />
         <option name="JD_DO_NOT_WRAP_ONE_LINE_COMMENTS" value="true" />
-        <option name="RIGHT_MARGIN" value="100" />
         <option name="WRAP_COMMENTS" value="true" />
         <XML>
           <option name="XML_LEGACY_SETTINGS_IMPORTED" value="true" />
diff --git a/tools/layoutlib/.idea/libraries/asm_4_0.xml b/tools/layoutlib/.idea/libraries/asm_4_0.xml
index 578a7bf..7df287f 100644
--- a/tools/layoutlib/.idea/libraries/asm_4_0.xml
+++ b/tools/layoutlib/.idea/libraries/asm_4_0.xml
@@ -1,11 +1,11 @@
 <component name="libraryTable">
   <library name="asm-4.0">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/asm/asm-4.0.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/asm/asm-4.0.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/asm/src.zip!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/asm/src.zip!/" />
     </SOURCES>
   </library>
 </component>
\ No newline at end of file
diff --git a/tools/layoutlib/.idea/libraries/framework_jar.xml b/tools/layoutlib/.idea/libraries/framework_jar.xml
index 11f5b89..6695a36 100644
--- a/tools/layoutlib/.idea/libraries/framework_jar.xml
+++ b/tools/layoutlib/.idea/libraries/framework_jar.xml
@@ -1,13 +1,13 @@
 <component name="libraryTable">
   <library name="framework.jar">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/out/host/common/obj/JAVA_LIBRARIES/temp_layoutlib_intermediates/javalib.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../out/host/common/obj/JAVA_LIBRARIES/temp_layoutlib_intermediates/javalib.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
-      <root url="file://$ANDROID_BUILD_TOP$/frameworks/base/core/java" />
-      <root url="file://$ANDROID_BUILD_TOP$/frameworks/base/graphics/java" />
-      <root url="file://$ANDROID_BUILD_TOP$/libcore/luni/src/main/java" />
+      <root url="file://$PROJECT_DIR$/../../core/java" />
+      <root url="file://$PROJECT_DIR$/../../graphics/java" />
+      <root url="file://$PROJECT_DIR$/../../../../libcore/luni/src/main/java" />
     </SOURCES>
   </library>
 </component>
\ No newline at end of file
diff --git a/tools/layoutlib/.idea/libraries/guava.xml b/tools/layoutlib/.idea/libraries/guava.xml
index de5607e..d47fc06 100644
--- a/tools/layoutlib/.idea/libraries/guava.xml
+++ b/tools/layoutlib/.idea/libraries/guava.xml
@@ -1,11 +1,11 @@
 <component name="libraryTable">
   <library name="guava">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/out/host/common/obj/JAVA_LIBRARIES/guavalib_intermediates/javalib.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../out/host/common/obj/JAVA_LIBRARIES/guavalib_intermediates/javalib.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
-      <root url="file://$ANDROID_BUILD_TOP$/external/guava/guava/src" />
+      <root url="file://$PROJECT_DIR$/../../../../external/guava/guava/src" />
     </SOURCES>
   </library>
 </component>
\ No newline at end of file
diff --git a/tools/layoutlib/.idea/libraries/icu4j.xml b/tools/layoutlib/.idea/libraries/icu4j.xml
index 8d9a318..dbe0bd7 100644
--- a/tools/layoutlib/.idea/libraries/icu4j.xml
+++ b/tools/layoutlib/.idea/libraries/icu4j.xml
@@ -1,7 +1,7 @@
 <component name="libraryTable">
   <library name="icu4j">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/icu4j/icu4j.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/icu4j/icu4j.jar!/" />
     </CLASSES>
     <JAVADOC>
       <root url="http://icu-project.org/apiref/icu4j50rc/" />
diff --git a/tools/layoutlib/.idea/libraries/kxml2_2_3_0.xml b/tools/layoutlib/.idea/libraries/kxml2_2_3_0.xml
index 91feaea..2a65050 100644
--- a/tools/layoutlib/.idea/libraries/kxml2_2_3_0.xml
+++ b/tools/layoutlib/.idea/libraries/kxml2_2_3_0.xml
@@ -1,11 +1,11 @@
 <component name="libraryTable">
   <library name="kxml2-2.3.0">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/kxml2/kxml2-2.3.0.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/kxml2/kxml2-2.3.0.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
-      <root url="file://$ANDROID_BUILD_TOP$/libcore/xml/src/main/java" />
+      <root url="file://$PROJECT_DIR$/../../../../libcore/xml/src/main/java" />
     </SOURCES>
   </library>
 </component>
\ No newline at end of file
diff --git a/tools/layoutlib/.idea/libraries/layoutlib_api_prebuilt.xml b/tools/layoutlib/.idea/libraries/layoutlib_api_prebuilt.xml
index be928da..5952002 100644
--- a/tools/layoutlib/.idea/libraries/layoutlib_api_prebuilt.xml
+++ b/tools/layoutlib/.idea/libraries/layoutlib_api_prebuilt.xml
@@ -1,7 +1,7 @@
 <component name="libraryTable">
   <library name="layoutlib_api-prebuilt">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/layoutlib_api/layoutlib_api-prebuilt.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/layoutlib_api/layoutlib_api-prebuilt.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
diff --git a/tools/layoutlib/.idea/libraries/ninepatch_prebuilt.xml b/tools/layoutlib/.idea/libraries/ninepatch_prebuilt.xml
index 338137b..f34f7dd 100644
--- a/tools/layoutlib/.idea/libraries/ninepatch_prebuilt.xml
+++ b/tools/layoutlib/.idea/libraries/ninepatch_prebuilt.xml
@@ -1,7 +1,7 @@
 <component name="libraryTable">
   <library name="ninepatch-prebuilt">
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/ninepatch/ninepatch-prebuilt.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/ninepatch/ninepatch-prebuilt.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
diff --git a/tools/layoutlib/.idea/libraries/tools_common_prebuilt.xml b/tools/layoutlib/.idea/libraries/tools_common_prebuilt.xml
index 6479886..b325ad4 100644
--- a/tools/layoutlib/.idea/libraries/tools_common_prebuilt.xml
+++ b/tools/layoutlib/.idea/libraries/tools_common_prebuilt.xml
@@ -4,7 +4,7 @@
       <root url="file://$PROJECT_DIR$" />
     </ANNOTATIONS>
     <CLASSES>
-      <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/tools-common/tools-common-prebuilt.jar!/" />
+      <root url="jar://$PROJECT_DIR$/../../../../prebuilts/misc/common/tools-common/tools-common-prebuilt.jar!/" />
     </CLASSES>
     <JAVADOC />
     <SOURCES>
diff --git a/tools/layoutlib/.idea/runConfigurations/All_in_bridge.xml b/tools/layoutlib/.idea/runConfigurations/All_in_bridge.xml
index badbbab..f965ba7 100644
--- a/tools/layoutlib/.idea/runConfigurations/All_in_bridge.xml
+++ b/tools/layoutlib/.idea/runConfigurations/All_in_bridge.xml
@@ -8,7 +8,7 @@
     <option name="MAIN_CLASS_NAME" value="" />
     <option name="METHOD_NAME" value="" />
     <option name="TEST_OBJECT" value="package" />
-    <option name="VM_PARAMETERS" value="-ea -Dplatform.dir=&quot;$ANDROID_BUILD_TOP$/out/host/linux-x86/sdk/sdk/android-sdk_eng.deepanshu_linux-x86/platforms/android-L&quot; -Dtest_res.dir=&quot;$PROJECT_DIR$/bridge/tests/res&quot;" />
+    <option name="VM_PARAMETERS" value="-ea -Dtest_res.dir=&quot;$PROJECT_DIR$/bridge/tests/res&quot;" />
     <option name="PARAMETERS" value="" />
     <option name="WORKING_DIRECTORY" value="file://$PROJECT_DIR$" />
     <option name="ENV_VARIABLES" />
diff --git a/tools/layoutlib/.idea/runConfigurations/Create.xml b/tools/layoutlib/.idea/runConfigurations/Create.xml
index e62925b..fb0b866 100644
--- a/tools/layoutlib/.idea/runConfigurations/Create.xml
+++ b/tools/layoutlib/.idea/runConfigurations/Create.xml
@@ -4,7 +4,7 @@
     <option name="MAIN_CLASS_NAME" value="com.android.tools.layoutlib.create.Main" />
     <option name="VM_PARAMETERS" value="" />
     <option name="PROGRAM_PARAMETERS" value="out/host/common/obj/JAVA_LIBRARIES/temp_layoutlib_intermediates/javalib.jar out/target/common/obj/JAVA_LIBRARIES/core-libart_intermediates/classes.jar out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes.jar out/target/common/obj/JAVA_LIBRARIES/ext_intermediates/classes.jar out/target/common/obj/JAVA_LIBRARIES/ext_intermediates/javalib.jar" />
-    <option name="WORKING_DIRECTORY" value="file://$ANDROID_BUILD_TOP$/" />
+    <option name="WORKING_DIRECTORY" value="file://$PROJECT_DIR$/../../../../" />
     <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
     <option name="ALTERNATIVE_JRE_PATH" value="1.6" />
     <option name="ENABLE_SWING_INSPECTOR" value="false" />
diff --git a/tools/layoutlib/.idea/vcs.xml b/tools/layoutlib/.idea/vcs.xml
index 8114960..9ab281a 100644
--- a/tools/layoutlib/.idea/vcs.xml
+++ b/tools/layoutlib/.idea/vcs.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="VcsDirectoryMappings">
-    <mapping directory="$ANDROID_BUILD_TOP$/frameworks/base" vcs="Git" />
+    <mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
   </component>
 </project>
 
diff --git a/tools/layoutlib/bridge/bridge.iml b/tools/layoutlib/bridge/bridge.iml
index 7553b59..0f96916 100644
--- a/tools/layoutlib/bridge/bridge.iml
+++ b/tools/layoutlib/bridge/bridge.iml
@@ -34,11 +34,11 @@
     <orderEntry type="module-library" scope="TEST">
       <library>
         <CLASSES>
-          <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/sdk-common/sdk-common.jar!/" />
+          <root url="jar://$MODULE_DIR$/../../../../../prebuilts/misc/common/sdk-common/sdk-common.jar!/" />
         </CLASSES>
         <JAVADOC />
         <SOURCES>
-          <root url="jar://$ANDROID_BUILD_TOP$/prebuilts/misc/common/sdk-common/sdk-common-sources.jar!/" />
+          <root url="jar://$MODULE_DIR$/../../../../../prebuilts/misc/common/sdk-common/sdk-common-sources.jar!/" />
         </SOURCES>
       </library>
     </orderEntry>
diff --git a/tools/layoutlib/bridge/resources/bars/hdpi/stat_sys_battery_100.png b/tools/layoutlib/bridge/resources/bars/hdpi/stat_sys_battery_100.png
new file mode 100644
index 0000000..f17189a
--- /dev/null
+++ b/tools/layoutlib/bridge/resources/bars/hdpi/stat_sys_battery_100.png
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/mdpi/stat_sys_battery_100.png b/tools/layoutlib/bridge/resources/bars/mdpi/stat_sys_battery_100.png
new file mode 100644
index 0000000..2a9757d
--- /dev/null
+++ b/tools/layoutlib/bridge/resources/bars/mdpi/stat_sys_battery_100.png
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/status_bar.xml b/tools/layoutlib/bridge/resources/bars/status_bar.xml
index 75bfb6e..04571e1 100644
--- a/tools/layoutlib/bridge/resources/bars/status_bar.xml
+++ b/tools/layoutlib/bridge/resources/bars/status_bar.xml
@@ -1,17 +1,27 @@
 <?xml version="1.0" encoding="utf-8"?>
 <merge xmlns:android="http://schemas.android.com/apk/res/android">
-	<TextView
-			android:layout_width="wrap_content"
-			android:layout_height="wrap_content"
-			android:layout_weight="1"/>
-	<ImageView
-			android:layout_height="wrap_content"
-			android:layout_width="wrap_content"
-			android:layout_marginTop="1dp"/>
-	<ImageView
-			android:layout_height="wrap_content"
-			android:layout_width="wrap_content"
-			android:layout_marginLeft="3dp"
-			android:layout_marginRight="5dp"
-			android:layout_marginTop="2dp"/>
+    <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_weight="1"/>
+    <!-- The exact size of the wifi icon is specified in order to scale it properly.
+    Without scaling, it appeared huge. This is currently, 70% of the actual size. -->
+    <ImageView
+            android:layout_height="22.4dp"
+            android:layout_width="20.65dp"
+            android:layout_marginTop="1dp"/>
+    <ImageView
+            android:layout_height="wrap_content"
+            android:layout_width="wrap_content"
+            android:layout_marginLeft="3dp"
+            android:layout_marginRight="5dp"
+            android:layout_marginTop="4dp"/>
+    <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_marginTop="4dp"
+            android:layout_marginRight="5dp"
+            android:gravity="center_vertical"
+            android:textSize="16dp"
+            android:fontFamily="sans-serif-medium"/>
 </merge>
diff --git a/tools/layoutlib/bridge/resources/bars/v18/hdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v18/hdpi/stat_sys_wifi_signal_4_fully.png
index 931daed..6248cfd 100644
--- a/tools/layoutlib/bridge/resources/bars/v18/hdpi/stat_sys_wifi_signal_4_fully.png
+++ b/tools/layoutlib/bridge/resources/bars/v18/hdpi/stat_sys_wifi_signal_4_fully.png
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v18/mdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v18/mdpi/stat_sys_wifi_signal_4_fully.png
index 6e1ac91..441de0c 100644
--- a/tools/layoutlib/bridge/resources/bars/v18/mdpi/stat_sys_wifi_signal_4_fully.png
+++ b/tools/layoutlib/bridge/resources/bars/v18/mdpi/stat_sys_wifi_signal_4_fully.png
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v18/xhdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v18/xhdpi/stat_sys_wifi_signal_4_fully.png
index 625c61d..459a1a2 100644
--- a/tools/layoutlib/bridge/resources/bars/v18/xhdpi/stat_sys_wifi_signal_4_fully.png
+++ b/tools/layoutlib/bridge/resources/bars/v18/xhdpi/stat_sys_wifi_signal_4_fully.png
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v21/hdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v21/hdpi/stat_sys_wifi_signal_4_fully.png
deleted file mode 100644
index 931daed..0000000
--- a/tools/layoutlib/bridge/resources/bars/v21/hdpi/stat_sys_wifi_signal_4_fully.png
+++ /dev/null
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v21/mdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v21/mdpi/stat_sys_wifi_signal_4_fully.png
deleted file mode 100644
index 6e1ac91..0000000
--- a/tools/layoutlib/bridge/resources/bars/v21/mdpi/stat_sys_wifi_signal_4_fully.png
+++ /dev/null
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.png b/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.png
deleted file mode 100644
index 625c61d..0000000
--- a/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.png
+++ /dev/null
Binary files differ
diff --git a/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.xml b/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.xml
new file mode 100644
index 0000000..0498b6c
--- /dev/null
+++ b/tools/layoutlib/bridge/resources/bars/v21/xhdpi/stat_sys_wifi_signal_4_fully.xml
@@ -0,0 +1,9 @@
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+        android:width="32.0dp"
+        android:height="29.5dp"
+        android:viewportWidth="26.0"
+        android:viewportHeight="24.0">
+    <path
+        android:fillColor="#FFFFFFFF"
+        android:pathData="M13.000000,22.000000L25.600000,6.500000C25.100000,6.100000 20.299999,2.100000 13.000000,2.100000S0.900000,6.100000 0.400000,6.500000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000L13.000000,22.000000z"/>
+</vector>
diff --git a/tools/layoutlib/bridge/resources/bars/xhdpi/stat_sys_battery_100.png b/tools/layoutlib/bridge/resources/bars/xhdpi/stat_sys_battery_100.png
new file mode 100644
index 0000000..555bcd9
--- /dev/null
+++ b/tools/layoutlib/bridge/resources/bars/xhdpi/stat_sys_battery_100.png
Binary files differ
diff --git a/tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java b/tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java
index f939678..aaba545 100644
--- a/tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java
+++ b/tools/layoutlib/bridge/src/android/content/res/BridgeTypedArray.java
@@ -90,9 +90,16 @@
         // fills TypedArray.mIndices which is used to implement getIndexCount/getIndexAt
         // first count the array size
         int count = 0;
-        for (ResourceValue data : mResourceData) {
+        for (int i = 0; i < mResourceData.length; i++) {
+            ResourceValue data = mResourceData[i];
             if (data != null) {
-                count++;
+                if (RenderResources.REFERENCE_NULL.equals(data.getValue())) {
+                    // No need to store this resource value. This saves needless checking for
+                    // "@null" every time  an attribute is requested.
+                    mResourceData[i] = null;
+                } else {
+                    count++;
+                }
             }
         }
 
@@ -214,10 +221,6 @@
 
         String s = mResourceData[index].getValue();
 
-        if (RenderResources.REFERENCE_NULL.equals(s)) {
-            return defValue;
-        }
-
         if (s == null || s.length() == 0) {
             return defValue;
         }
@@ -230,6 +233,20 @@
 
         // Field is not null and is not an integer.
         // Check for possible constants and try to find them.
+        return (int) resolveEnumAttribute(index, defValue);
+    }
+
+    /**
+     * Searches for the string in the attributes (flag or enums) and returns the integer.
+     * If found, it will return an integer matching the value. However, if the value is not found,
+     * it returns {@code defValue} which may be a float.
+     *
+     * @param index Index of attribute to retrieve.
+     * @param defValue Value to return if the attribute is not found.
+     *
+     * @return Attribute int value, or defValue if not defined.
+     */
+    private float resolveEnumAttribute(int index, float defValue) {
         // Get the map of attribute-constant -> IntegerValue
         Map<String, Integer> map = null;
         if (mIsFramework[index]) {
@@ -248,7 +265,7 @@
             int result = 0;
 
             // split the value in case this is a mix of several flags.
-            String[] keywords = s.split("\\|");
+            String[] keywords = mResourceData[index].getValue().split("\\|");
             for (String keyword : keywords) {
                 Integer i = map.get(keyword.trim());
                 if (i != null) {
@@ -257,7 +274,7 @@
                     Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
                             String.format(
                                 "\"%s\" in attribute \"%2$s\" is not a valid value",
-                                keyword, mNames[index]), null /*data*/);
+                                keyword, mNames[index]), null);
                 }
             }
             return result;
@@ -292,7 +309,7 @@
                 Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
                         String.format(
                             "\"%s\" in attribute \"%2$s\" cannot be converted to float.",
-                            s, mNames[index]), null /*data*/);
+                            s, mNames[index]), null);
 
                 // we'll return the default value below.
             }
@@ -357,10 +374,6 @@
             return null;
         }
 
-        if (RenderResources.REFERENCE_NULL.equals(value)) {
-            return null;
-        }
-
         // let the framework inflate the ColorStateList from the XML file.
         File f = new File(value);
         if (f.isFile()) {
@@ -376,13 +389,13 @@
                 }
             } catch (XmlPullParserException e) {
                 Bridge.getLog().error(LayoutLog.TAG_BROKEN,
-                        "Failed to configure parser for " + value, e, null /*data*/);
+                        "Failed to configure parser for " + value, e, null);
                 return null;
             } catch (Exception e) {
                 // this is an error and not warning since the file existence is checked before
                 // attempting to parse it.
                 Bridge.getLog().error(LayoutLog.TAG_RESOURCES_READ,
-                        "Failed to parse file " + value, e, null /*data*/);
+                        "Failed to parse file " + value, e, null);
 
                 return null;
             }
@@ -392,7 +405,7 @@
             int color = ResourceHelper.getColor(value);
             return ColorStateList.valueOf(color);
         } catch (NumberFormatException e) {
-            Bridge.getLog().error(LayoutLog.TAG_RESOURCES_FORMAT, e.getMessage(), e, null /*data*/);
+            Bridge.getLog().error(LayoutLog.TAG_RESOURCES_FORMAT, e.getMessage(), e, null);
         }
 
         return null;
@@ -442,26 +455,15 @@
 
         if (s == null) {
             return defValue;
-        } else if (s.equals(BridgeConstants.MATCH_PARENT) ||
-                s.equals(BridgeConstants.FILL_PARENT)) {
-            return LayoutParams.MATCH_PARENT;
-        } else if (s.equals(BridgeConstants.WRAP_CONTENT)) {
-            return LayoutParams.WRAP_CONTENT;
-        } else if (RenderResources.REFERENCE_NULL.equals(s)) {
-            return defValue;
         }
 
-        if (ResourceHelper.parseFloatAttribute(mNames[index], s, mValue, true /*requireUnit*/)) {
+        if (ResourceHelper.parseFloatAttribute(mNames[index], s, mValue, true)) {
             return mValue.getDimension(mBridgeResources.getDisplayMetrics());
         }
 
-        // looks like we were unable to resolve the dimension value
-        Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
-                String.format(
-                    "\"%1$s\" in attribute \"%2$s\" is not a valid format.",
-                    s, mNames[index]), null /*data*/);
-
-        return defValue;
+        // looks like we were unable to resolve the dimension value. Check if it is an attribute
+        // constant.
+        return resolveEnumAttribute(index, defValue);
     }
 
     /**
@@ -517,7 +519,7 @@
                     Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
                             String.format(
                                 "\"%1$s\" in attribute \"%2$s\" is not a valid format.",
-                                s, mNames[index]), null /*data*/);
+                                s, mNames[index]), null);
                 }
             }
 
@@ -574,11 +576,9 @@
             return LayoutParams.MATCH_PARENT;
         } else if (s.equals(BridgeConstants.WRAP_CONTENT)) {
             return LayoutParams.WRAP_CONTENT;
-        } else if (RenderResources.REFERENCE_NULL.equals(s)) {
-            throw new RuntimeException();
         }
 
-        if (ResourceHelper.parseFloatAttribute(mNames[index], s, mValue, true /*requireUnit*/)) {
+        if (ResourceHelper.parseFloatAttribute(mNames[index], s, mValue, true)) {
             float f = mValue.getDimension(mBridgeResources.getDisplayMetrics());
 
             final int res = (int)(f+0.5f);
@@ -620,16 +620,15 @@
             return defValue;
         }
 
-        if (ResourceHelper.parseFloatAttribute(mNames[index], value, mValue,
-                false /*requireUnit*/)) {
+        if (ResourceHelper.parseFloatAttribute(mNames[index], value, mValue, false)) {
             return mValue.getFraction(base, pbase);
         }
 
         // looks like we were unable to resolve the fraction value
         Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
                 String.format(
-                    "\"%1$s\" in attribute \"%2$s\" cannot be converted to a fraction.",
-                    value, mNames[index]), null /*data*/);
+                        "\"%1$s\" in attribute \"%2$s\" cannot be converted to a fraction.",
+                        value, mNames[index]), null);
 
         return defValue;
     }
@@ -668,10 +667,6 @@
             return mContext.getDynamicIdByStyle((StyleResourceValue)resValue);
         }
 
-        if (RenderResources.REFERENCE_NULL.equals(resValue.getValue())) {
-            return defValue;
-        }
-
         // if the attribute was a reference to a resource, and not a declaration of an id (@+id),
         // then the xml attribute value was "resolved" which leads us to a ResourceValue with a
         // valid getType() and getName() returning a resource name.
@@ -781,7 +776,7 @@
 
         ResourceValue value = mResourceData[index];
         String stringValue = value.getValue();
-        if (stringValue == null || RenderResources.REFERENCE_NULL.equals(stringValue)) {
+        if (stringValue == null) {
             return null;
         }
 
@@ -811,18 +806,9 @@
 
         String value = mResourceData[index].getValue();
         if (value != null) {
-            if (RenderResources.REFERENCE_NULL.equals(value)) {
-                return null;
-            }
-
             return new CharSequence[] { value };
         }
 
-        Bridge.getLog().warning(LayoutLog.TAG_RESOURCES_FORMAT,
-                String.format(
-                    String.format("Unknown value for getTextArray(%d) => %s", //DEBUG
-                    index, mResourceData[index].getName())), null /*data*/);
-
         return null;
     }
 
@@ -861,8 +847,7 @@
 
         String s = mResourceData[index].getValue();
 
-        return ResourceHelper.parseFloatAttribute(mNames[index], s, outValue,
-                false /*requireUnit*/);
+        return ResourceHelper.parseFloatAttribute(mNames[index], s, outValue, false);
     }
 
     /**
diff --git a/tools/layoutlib/bridge/src/android/graphics/FontFamily_Delegate.java b/tools/layoutlib/bridge/src/android/graphics/FontFamily_Delegate.java
index bd80cb8..bef5181 100644
--- a/tools/layoutlib/bridge/src/android/graphics/FontFamily_Delegate.java
+++ b/tools/layoutlib/bridge/src/android/graphics/FontFamily_Delegate.java
@@ -16,6 +16,8 @@
 
 package android.graphics;
 
+import com.android.annotations.NonNull;
+import com.android.annotations.Nullable;
 import com.android.ide.common.rendering.api.LayoutLog;
 import com.android.layoutlib.bridge.Bridge;
 import com.android.layoutlib.bridge.impl.DelegateManager;
@@ -50,10 +52,12 @@
  */
 public class FontFamily_Delegate {
 
+    public static final int DEFAULT_FONT_WEIGHT = 400;
+    public static final int BOLD_FONT_WEIGHT_DELTA = 300;
+    public static final int BOLD_FONT_WEIGHT = 700;
+
     // FONT_SUFFIX_ITALIC will always match FONT_SUFFIX_BOLDITALIC and hence it must be checked
     // separately.
-    private static final String FONT_SUFFIX_BOLDITALIC = "BoldItalic.ttf";
-    private static final String FONT_SUFFIX_BOLD = "Bold.ttf";
     private static final String FONT_SUFFIX_ITALIC = "Italic.ttf";
     private static final String FN_ALL_FONTS_LIST = "fontsInSdk.txt";
 
@@ -61,9 +65,10 @@
      * A class associating {@link Font} with its metadata.
      */
     private static final class FontInfo {
+        @Nullable
         Font mFont;
-        /** Regular, Bold, Italic, or BoldItalic. */
-        int mStyle;
+        int mWeight;
+        boolean mIsItalic;
     }
 
     // ---- delegate manager ----
@@ -79,16 +84,18 @@
 
     // ---- delegate data ----
     private List<FontInfo> mFonts = new ArrayList<FontInfo>();
+
     /**
      * The variant of the Font Family - compact or elegant.
+     * <p/>
      * 0 is unspecified, 1 is compact and 2 is elegant. This needs to be kept in sync with values in
      * android.graphics.FontFamily
      *
      * @see Paint#setElegantTextHeight(boolean)
      */
     private FontVariant mVariant;
-    // Path of fonts that haven't been created since sFontLoader hasn't been initialized.
-    private List<String> mPath = new ArrayList<String>();
+    // List of runnables to process fonts after sFontLoader is initialized.
+    private List<Runnable> mPostInitRunnables = new ArrayList<Runnable>();
     /** @see #isValid() */
     private boolean mValid = false;
 
@@ -139,27 +146,30 @@
         sPostInitDelegate.clear();
     }
 
-    public Font getFont(int style) {
-        FontInfo plainFont = null;
+    @Nullable
+    public Font getFont(int desiredWeight, boolean isItalic) {
+        FontInfo desiredStyle = new FontInfo();
+        desiredStyle.mWeight = desiredWeight;
+        desiredStyle.mIsItalic = isItalic;
+        FontInfo bestFont = null;
+        int bestMatch = Integer.MAX_VALUE;
         for (FontInfo font : mFonts) {
-            if (font.mStyle == style) {
-                return font.mFont;
-            }
-            if (font.mStyle == Font.PLAIN && plainFont == null) {
-                plainFont = font;
+            int match = computeMatch(font, desiredStyle);
+            if (match < bestMatch) {
+                bestMatch = match;
+                bestFont = font;
             }
         }
-
-        // No font with the mentioned style is found. Try to derive one.
-        if (plainFont != null && style > 0 && style < 4) {
-            FontInfo styledFont = new FontInfo();
-            styledFont.mFont = plainFont.mFont.deriveFont(style);
-            styledFont.mStyle = style;
-            // Add the font to the list of fonts so that we don't have to derive it the next time.
-            mFonts.add(styledFont);
-            return styledFont.mFont;
+        if (bestFont == null) {
+            return null;
         }
-        return null;
+        if (bestMatch == 0) {
+            return bestFont.mFont;
+        }
+        // Derive the font as required and add it to the list of Fonts.
+        deriveFont(bestFont, desiredStyle);
+        addFont(desiredStyle);
+        return desiredStyle.mFont;
     }
 
     public FontVariant getVariant() {
@@ -168,27 +178,14 @@
 
     /**
      * Returns if the FontFamily should contain any fonts. If this returns true and
-     * {@link #getFont(int)} returns an empty list, it means that an error occurred while loading
-     * the fonts. However, some fonts are deliberately skipped, for example they are not bundled
-     * with the SDK. In such a case, this method returns false.
+     * {@link #getFont(int, boolean)} returns an empty list, it means that an error occurred while
+     * loading the fonts. However, some fonts are deliberately skipped, for example they are not
+     * bundled with the SDK. In such a case, this method returns false.
      */
     public boolean isValid() {
         return mValid;
     }
 
-    /*package*/ static int getFontStyle(String path) {
-        int style = Font.PLAIN;
-        String fontName = path.substring(path.lastIndexOf('/'));
-        if (fontName.endsWith(FONT_SUFFIX_BOLDITALIC)) {
-            style = Font.BOLD | Font.ITALIC;
-        } else if (fontName.endsWith(FONT_SUFFIX_BOLD)) {
-            style = Font.BOLD;
-        } else if (fontName.endsWith(FONT_SUFFIX_ITALIC)) {
-            style = Font.ITALIC;
-        }
-        return style;
-    }
-
     /*package*/ static Font loadFont(String path) {
         if (path.startsWith(SYSTEM_FONTS) ) {
             String relativePath = path.substring(SYSTEM_FONTS.length());
@@ -242,11 +239,16 @@
     }
 
     @LayoutlibDelegate
-    /*package*/ static boolean nAddFont(long nativeFamily, String path) {
-        FontFamily_Delegate delegate = getDelegate(nativeFamily);
+    /*package*/ static boolean nAddFont(long nativeFamily, final String path) {
+        final FontFamily_Delegate delegate = getDelegate(nativeFamily);
         if (delegate != null) {
             if (sFontLocation == null) {
-                delegate.mPath.add(path);
+                delegate.mPostInitRunnables.add(new Runnable() {
+                    @Override
+                    public void run() {
+                        delegate.addFont(path);
+                    }
+                });
                 return true;
             }
             return delegate.addFont(path);
@@ -255,6 +257,25 @@
     }
 
     @LayoutlibDelegate
+    /*package*/ static boolean nAddFontWeightStyle(long nativeFamily, final String path,
+            final int weight, final boolean isItalic) {
+        final FontFamily_Delegate delegate = getDelegate(nativeFamily);
+        if (delegate != null) {
+            if (sFontLocation == null) {
+                delegate.mPostInitRunnables.add(new Runnable() {
+                    @Override
+                    public void run() {
+                        delegate.addFont(path, weight, isItalic);
+                    }
+                });
+                return true;
+            }
+            return delegate.addFont(path, weight, isItalic);
+        }
+        return false;
+    }
+
+    @LayoutlibDelegate
     /*package*/ static boolean nAddFontFromAsset(long nativeFamily, AssetManager mgr, String path) {
         Bridge.getLog().fidelityWarning(LayoutLog.TAG_UNSUPPORTED,
                 "FontFamily.addFontFromAsset is not supported.", null, null);
@@ -265,15 +286,17 @@
     // ---- private helper methods ----
 
     private void init() {
-        for (String path : mPath) {
-            addFont(path);
+        for (Runnable postInitRunnable : mPostInitRunnables) {
+            postInitRunnable.run();
         }
-        mPath = null;
+        mPostInitRunnables = null;
     }
 
-    private boolean addFont(String path) {
-        // If the font is not in the list of fonts bundled with the SDK, don't try to load it and
-        // mark the FontFamily to be not valid.
+     private boolean addFont(@NonNull String path) {
+         return addFont(path, DEFAULT_FONT_WEIGHT, path.endsWith(FONT_SUFFIX_ITALIC));
+     }
+
+    private boolean addFont(@NonNull String path, int weight, boolean isItalic) {
         if (path.startsWith(SYSTEM_FONTS) &&
                 !SDK_FONTS.contains(path.substring(SYSTEM_FONTS.length()))) {
             return mValid = false;
@@ -286,9 +309,67 @@
         }
         FontInfo fontInfo = new FontInfo();
         fontInfo.mFont = font;
-        fontInfo.mStyle = getFontStyle(path);
-        // TODO ensure that mFonts doesn't have the font with this style already.
+        fontInfo.mWeight = weight;
+        fontInfo.mIsItalic = isItalic;
+        addFont(fontInfo);
+        return true;
+    }
+
+    private boolean addFont(@NonNull FontInfo fontInfo) {
+        int weight = fontInfo.mWeight;
+        boolean isItalic = fontInfo.mIsItalic;
+        // The list is usually just two fonts big. So iterating over all isn't as bad as it looks.
+        // It's biggest for roboto where the size is 12.
+        for (FontInfo font : mFonts) {
+            if (font.mWeight == weight && font.mIsItalic == isItalic) {
+                return false;
+            }
+        }
         mFonts.add(fontInfo);
         return true;
     }
+
+    /**
+     * Compute matching metric between two styles - 0 is an exact match.
+     */
+    private static int computeMatch(@NonNull FontInfo font1, @NonNull FontInfo font2) {
+        int score = Math.abs(font1.mWeight - font2.mWeight);
+        if (font1.mIsItalic != font2.mIsItalic) {
+            score += 200;
+        }
+        return score;
+    }
+
+    /**
+     * Try to derive a font from {@code srcFont} for the style in {@code outFont}.
+     * <p/>
+     * {@code outFont} is updated to reflect the style of the derived font.
+     * @param srcFont the source font
+     * @param outFont contains the desired font style. Updated to contain the derived font and
+     *                its style
+     * @return outFont
+     */
+    @NonNull
+    private FontInfo deriveFont(@NonNull FontInfo srcFont, @NonNull FontInfo outFont) {
+        int desiredWeight = outFont.mWeight;
+        int srcWeight = srcFont.mWeight;
+        Font derivedFont = srcFont.mFont;
+        // Embolden the font if required.
+        if (desiredWeight >= BOLD_FONT_WEIGHT && desiredWeight - srcWeight > BOLD_FONT_WEIGHT_DELTA / 2) {
+            derivedFont = derivedFont.deriveFont(Font.BOLD);
+            srcWeight += BOLD_FONT_WEIGHT_DELTA;
+        }
+        // Italicize the font if required.
+        if (outFont.mIsItalic && !srcFont.mIsItalic) {
+            derivedFont = derivedFont.deriveFont(Font.ITALIC);
+        } else if (outFont.mIsItalic != srcFont.mIsItalic) {
+            // The desired font is plain, but the src font is italics. We can't convert it back. So
+            // we update the value to reflect the true style of the font we're deriving.
+            outFont.mIsItalic = srcFont.mIsItalic;
+        }
+        outFont.mFont = derivedFont;
+        outFont.mWeight = srcWeight;
+        // No need to update mIsItalics, as it's already been handled above.
+        return outFont;
+    }
 }
diff --git a/tools/layoutlib/bridge/src/android/graphics/Shader_Delegate.java b/tools/layoutlib/bridge/src/android/graphics/Shader_Delegate.java
index 832d0a3..14e9960 100644
--- a/tools/layoutlib/bridge/src/android/graphics/Shader_Delegate.java
+++ b/tools/layoutlib/bridge/src/android/graphics/Shader_Delegate.java
@@ -76,22 +76,19 @@
     // ---- native methods ----
 
     @LayoutlibDelegate
-    /*package*/ static void nativeDestructor(long native_shader, long native_with_local_matrix) {
-        // TODO: check what's native_with_local_matrix
+    /*package*/ static void nativeDestructor(long native_shader) {
         sManager.removeJavaReferenceFor(native_shader);
     }
 
     @LayoutlibDelegate
-    /*package*/ static long nativeSetLocalMatrix(long native_shader,
-            long native_with_local_matrix, long matrix_instance) {
+    /*package*/ static void nativeSetLocalMatrix(long native_shader, long matrix_instance) {
         // get the delegate from the native int.
         Shader_Delegate shaderDelegate = sManager.getDelegate(native_shader);
         if (shaderDelegate == null) {
-            return 0;
+            return;
         }
 
         shaderDelegate.mLocalMatrix = Matrix_Delegate.getDelegate(matrix_instance);
-        return 0;
     }
 
     // ---- Private delegate/helper methods ----
diff --git a/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java b/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
index 72fe61c..276e134 100644
--- a/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
+++ b/tools/layoutlib/bridge/src/android/graphics/Typeface_Delegate.java
@@ -55,8 +55,9 @@
 
     @NonNull
     private final FontFamily_Delegate[] mFontFamilies;  // the reference to FontFamily_Delegate.
-    /** @see FontFamily_Delegate.FontInfo#mStyle */
+    /** @see Font#getStyle() */
     private final int mStyle;
+    private final int mWeight;
 
     private static long sDefaultTypeface;
 
@@ -84,11 +85,18 @@
     @NonNull
     public List<Font> getFonts(FontVariant variant) {
         assert variant != FontVariant.NONE;
+
+        // Calculate the required weight based on style and weight of this typeface.
+        int weight = mWeight + ((mStyle & Font.BOLD) == 0 ? 0 : FontFamily_Delegate.BOLD_FONT_WEIGHT_DELTA);
+        if (weight > 900) {
+            weight = 900;
+        }
+        final boolean isItalic = (mStyle & Font.ITALIC) != 0;
         List<Font> fonts = new ArrayList<Font>(mFontFamilies.length);
         for (int i = 0; i < mFontFamilies.length; i++) {
             FontFamily_Delegate ffd = mFontFamilies[i];
             if (ffd != null && ffd.isValid()) {
-                Font font = ffd.getFont(mStyle);
+                Font font = ffd.getFont(weight, isItalic);
                 if (font != null) {
                     FontVariant ffdVariant = ffd.getVariant();
                     if (ffdVariant == FontVariant.NONE) {
@@ -102,7 +110,7 @@
                     FontFamily_Delegate ffd2 = mFontFamilies[++i];
                     assert ffd2 != null;
                     FontVariant ffd2Variant = ffd2.getVariant();
-                    Font font2 = ffd2.getFont(mStyle);
+                    Font font2 = ffd2.getFont(weight, isItalic);
                     assert ffd2Variant != FontVariant.NONE && ffd2Variant != ffdVariant
                             && font2 != null;
                     // Add the font with the matching variant to the list.
@@ -135,7 +143,22 @@
             return 0;
         }
 
-        return sManager.addNewDelegate(new Typeface_Delegate(delegate.mFontFamilies, style));
+        return sManager.addNewDelegate(new Typeface_Delegate(delegate.mFontFamilies, style,
+                delegate.mWeight));
+    }
+
+    @LayoutlibDelegate
+    /*package*/ static long nativeCreateWeightAlias(long native_instance, int weight) {
+        Typeface_Delegate delegate = sManager.getDelegate(native_instance);
+        if (delegate == null) {
+            delegate = sManager.getDelegate(sDefaultTypeface);
+        }
+        if (delegate == null) {
+            return 0;
+        }
+        Typeface_Delegate weightAlias =
+                new Typeface_Delegate(delegate.mFontFamilies, delegate.mStyle, weight);
+        return sManager.addNewDelegate(weightAlias);
     }
 
     @LayoutlibDelegate
@@ -176,7 +199,12 @@
     // ---- Private delegate/helper methods ----
 
     private Typeface_Delegate(@NonNull FontFamily_Delegate[] fontFamilies, int style) {
+        this(fontFamilies, style, FontFamily_Delegate.DEFAULT_FONT_WEIGHT);
+    }
+
+    public Typeface_Delegate(@NonNull FontFamily_Delegate[] fontFamilies, int style, int weight) {
         mFontFamilies = fontFamilies;
         mStyle = style;
+        mWeight = weight;
     }
 }
diff --git a/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java b/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
index f8bc2ae..c403ce6 100644
--- a/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
+++ b/tools/layoutlib/bridge/src/android/view/IWindowManagerImpl.java
@@ -221,6 +221,13 @@
     }
 
     @Override
+    public void overridePendingAppTransitionAspectScaledThumb(Bitmap srcThumb, int startX,
+            int startY, int targetWidth, int targetHeight, IRemoteCallback startedCallback,
+            boolean scaleUp) {
+        // TODO Auto-generated method stub
+    }
+
+    @Override
     public void pauseKeyDispatching(IBinder arg0) throws RemoteException {
         // TODO Auto-generated method stub
 
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
index 17d990b..22265a3 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgePowerManager.java
@@ -38,6 +38,11 @@
     }
 
     @Override
+    public boolean setPowerSaveMode(boolean mode) throws RemoteException {
+        return false;
+    }
+
+    @Override
     public IBinder asBinder() {
         // pass for now.
         return null;
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeWindowSession.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeWindowSession.java
index 130500a..0ed6ab1 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeWindowSession.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeWindowSession.java
@@ -174,6 +174,11 @@
     }
 
     @Override
+    public void setWallpaperDisplayOffset(IBinder windowToken, int x, int y) {
+        // pass for now.
+    }
+
+    @Override
     public Bundle sendWallpaperCommand(IBinder window, String action, int x, int y,
             int z, Bundle extras, boolean sync) {
         // pass for now.
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/Config.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/Config.java
index 9b814f5..16b54f1 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/Config.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/Config.java
@@ -20,10 +20,7 @@
 import java.util.Collections;
 import java.util.List;
 
-import static android.os.Build.VERSION_CODES.GINGERBREAD;
-import static android.os.Build.VERSION_CODES.ICE_CREAM_SANDWICH;
-import static android.os.Build.VERSION_CODES.JELLY_BEAN_MR2;
-import static android.os.Build.VERSION_CODES.KITKAT;
+import static android.os.Build.VERSION_CODES.*;
 
 /**
  * Various helper methods to simulate older versions of platform.
@@ -39,13 +36,16 @@
     private static final List<String> sDefaultResourceDir =
             Collections.singletonList(DEFAULT_RESOURCE_DIR);
 
+    private static final int WHITE = 0xFFFFFFFF;
+    private static final int BLACK = 0xFF000000;
+
     public static boolean showOnScreenNavBar(int platformVersion) {
         return platformVersion == 0 || platformVersion >= ICE_CREAM_SANDWICH;
     }
 
     public static int getStatusBarColor(int platformVersion) {
         // return white for froyo and earlier; black otherwise.
-        return platformVersion == 0 || platformVersion >= GINGERBREAD ? 0xFF000000 : 0xFFFFFFFF;
+        return platformVersion == 0 || platformVersion >= GINGERBREAD ? BLACK : WHITE;
     }
 
     public static List<String> getResourceDirs(int platformVersion) {
@@ -70,4 +70,49 @@
 
         return Collections.unmodifiableList(list);
     }
+
+    public static String getTime(int platformVersion) {
+        if (platformVersion == 0) {
+            // TODO: revisit when the version is selected.
+            return "4:57";
+        }
+        if (platformVersion < GINGERBREAD) {
+            return "2:20";
+        }
+        if (platformVersion < ICE_CREAM_SANDWICH) {
+            return "2:30";
+        }
+        if (platformVersion < JELLY_BEAN) {
+            return "4:00";
+        }
+        if (platformVersion < KITKAT) {
+            return "4:30";
+        }
+        if (platformVersion <= KITKAT_WATCH) {
+            return "4:40";
+        }
+        // Should never happen.
+        return "4:04";
+    }
+
+    public static int getTimeColor(int platformVersion) {
+        if (platformVersion == 0 || platformVersion >= KITKAT ||
+                platformVersion > FROYO && platformVersion < HONEYCOMB) {
+            // Gingerbread and KitKat onwards.
+            return WHITE;
+        }
+        // Black for froyo.
+        if (platformVersion < GINGERBREAD) {
+            return BLACK;
+        } else if (platformVersion < KITKAT) {
+            // Honeycomb to JB-mr2: Holo blue light.
+            return 0xff33b5e5;
+        }
+        // Should never happen.
+        return WHITE;
+    }
+
+    public static String getWifiIconType(int platformVersion) {
+        return platformVersion == 0 ? "xml" : "png";
+    }
 }
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/CustomBar.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/CustomBar.java
index bed232ab..13ddf07 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/CustomBar.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/CustomBar.java
@@ -127,24 +127,25 @@
         }
     }
 
-    protected TextView setText(int index, String stringReference) {
+    protected TextView setText(int index, String string, boolean reference) {
         View child = getChildAt(index);
         if (child instanceof TextView) {
             TextView textView = (TextView) child;
-            setText(textView, stringReference);
+            setText(textView, string, reference);
             return textView;
         }
 
         return null;
     }
 
-    private void setText(TextView textView, String stringReference) {
-        ResourceValue value = getResourceValue(stringReference);
-        if (value != null) {
-            textView.setText(value.getValue());
-        } else {
-            textView.setText(stringReference);
+    private void setText(TextView textView, String string, boolean reference) {
+        if (reference) {
+            ResourceValue value = getResourceValue(string);
+            if (value != null) {
+                string = value.getValue();
+            }
         }
+        textView.setText(string);
     }
 
     protected void setStyle(String themeEntryName) {
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/StatusBar.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/StatusBar.java
index 1795db9..c7c62d6 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/StatusBar.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/StatusBar.java
@@ -16,22 +16,38 @@
 
 package com.android.layoutlib.bridge.bars;
 
+import com.android.ide.common.rendering.api.LayoutLog;
+import com.android.layoutlib.bridge.Bridge;
+import com.android.layoutlib.bridge.android.BridgeContext;
+import com.android.layoutlib.bridge.android.BridgeXmlBlockParser;
+import com.android.layoutlib.bridge.impl.ParserFactory;
 import com.android.resources.Density;
 
 import org.xmlpull.v1.XmlPullParserException;
 
 import android.content.Context;
+import android.graphics.drawable.Drawable;
 import android.view.Gravity;
+import android.view.View;
+import android.widget.ImageView;
 import android.widget.LinearLayout;
 import android.widget.TextView;
 
+import java.io.IOException;
+import java.io.InputStream;
+
 public class StatusBar extends CustomBar {
 
+    private final Context mContext;
+    private final int mSimulatedPlatformVersion;
+
     public StatusBar(Context context, Density density, int direction, boolean RtlEnabled,
             int simulatedPlatformVersion) throws XmlPullParserException {
         // FIXME: if direction is RTL but it's not enabled in application manifest, mirror this bar.
         super(context, LinearLayout.HORIZONTAL, "/bars/status_bar.xml", "status_bar.xml",
                 simulatedPlatformVersion);
+        mContext = context;
+        mSimulatedPlatformVersion = simulatedPlatformVersion;
 
         // FIXME: use FILL_H?
         setGravity(Gravity.START | Gravity.TOP | Gravity.RIGHT);
@@ -41,8 +57,44 @@
         // created for them.
         // We do know the order though.
         // 0 is the spacer
-        loadIcon(1, "stat_sys_wifi_signal_4_fully.png", density);
+        loadIcon(1, "stat_sys_wifi_signal_4_fully."
+                        + Config.getWifiIconType(simulatedPlatformVersion), density);
         loadIcon(2, "stat_sys_battery_100.png", density);
+        setText(3, Config.getTime(simulatedPlatformVersion), false)
+                .setTextColor(Config.getTimeColor(simulatedPlatformVersion));
+    }
+
+    @Override
+    protected void loadIcon(int index, String iconName, Density density) {
+        if (!iconName.endsWith(".xml")) {
+            super.loadIcon(index, iconName, density);
+            return;
+        }
+        View child = getChildAt(index);
+        if (child instanceof ImageView) {
+            ImageView imageView = (ImageView) child;
+            // The xml is stored only in xhdpi.
+            IconLoader iconLoader = new IconLoader(iconName, Density.XHIGH,
+                    mSimulatedPlatformVersion, null);
+            InputStream stream = iconLoader.getIcon();
+
+            if (stream != null) {
+                try {
+                    BridgeXmlBlockParser parser = new BridgeXmlBlockParser(
+                            ParserFactory.create(stream, null), (BridgeContext) mContext, true);
+                    Drawable drawable = Drawable.createFromXml(mContext.getResources(), parser);
+                    if (drawable != null) {
+                        imageView.setImageDrawable(drawable);
+                    }
+                } catch (XmlPullParserException e) {
+                    Bridge.getLog().error(LayoutLog.TAG_BROKEN, "Unable to draw wifi icon", e,
+                            null);
+                } catch (IOException e) {
+                    Bridge.getLog().error(LayoutLog.TAG_BROKEN, "Unable to draw wifi icon", e,
+                            null);
+                }
+            }
+        }
     }
 
     @Override
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/TitleBar.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/TitleBar.java
index ff952bd..10f1383 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/TitleBar.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/TitleBar.java
@@ -34,7 +34,7 @@
         // Cannot access the inside items through id because no R.id values have been
         // created for them.
         // We do know the order though.
-        mTextView = setText(0, label);
+        mTextView = setText(0, label, true);
 
         setStyle("windowTitleBackgroundStyle");
     }
diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/ResourceHelper.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/ResourceHelper.java
index adb0937..99ae7c9 100644
--- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/ResourceHelper.java
+++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/ResourceHelper.java
@@ -63,11 +63,11 @@
      * Returns the color value represented by the given string value
      * @param value the color value
      * @return the color as an int
-     * @throw NumberFormatException if the conversion failed.
+     * @throws NumberFormatException if the conversion failed.
      */
     public static int getColor(String value) {
         if (value != null) {
-            if (value.startsWith("#") == false) {
+            if (!value.startsWith("#")) {
                 throw new NumberFormatException(
                         String.format("Color value '%s' must start with #", value));
             }
@@ -113,7 +113,7 @@
 
     public static ColorStateList getColorStateList(ResourceValue resValue, BridgeContext context) {
         String value = resValue.getValue();
-        if (value != null && RenderResources.REFERENCE_NULL.equals(value) == false) {
+        if (value != null && !RenderResources.REFERENCE_NULL.equals(value)) {
             // first check if the value is a file (xml most likely)
             File f = new File(value);
             if (f.isFile()) {
@@ -360,7 +360,7 @@
      */
     public static boolean parseFloatAttribute(String attribute, String value,
             TypedValue outValue, boolean requireUnit) {
-        assert requireUnit == false || attribute != null;
+        assert !requireUnit || attribute != null;
 
         // remove the space before and after
         value = value.trim();
@@ -379,7 +379,7 @@
         }
 
         // check the first character
-        if (buf[0] < '0' && buf[0] > '9' && buf[0] != '.' && buf[0] != '-') {
+        if ((buf[0] < '0' || buf[0] > '9') && buf[0] != '.' && buf[0] != '-' && buf[0] != '+') {
             return false;
         }
 
@@ -411,7 +411,7 @@
 
             if (end.length() == 0) {
                 if (outValue != null) {
-                    if (requireUnit == false) {
+                    if (!requireUnit) {
                         outValue.type = TypedValue.TYPE_FLOAT;
                         outValue.data = Float.floatToIntBits(f);
                     } else {
@@ -489,6 +489,8 @@
 
     private static void applyUnit(UnitEntry unit, TypedValue outValue, float[] outScale) {
         outValue.type = unit.type;
+        // COMPLEX_UNIT_SHIFT is 0 and hence intelliJ complains about it. Suppress the warning.
+        //noinspection PointlessBitwiseExpression
         outValue.data = unit.unit << TypedValue.COMPLEX_UNIT_SHIFT;
         outScale[0] = unit.scale;
     }
diff --git a/tools/layoutlib/bridge/tests/Android.mk b/tools/layoutlib/bridge/tests/Android.mk
index 7a9e067..11390c3 100644
--- a/tools/layoutlib/bridge/tests/Android.mk
+++ b/tools/layoutlib/bridge/tests/Android.mk
@@ -18,8 +18,8 @@
 
 # Only compile source java files in this lib.
 LOCAL_SRC_FILES := $(call all-java-files-under, src)
-
 LOCAL_JAVA_RESOURCE_DIRS := res
+LOCAL_JAVACFLAGS := -source 6 -target 6
 
 LOCAL_MODULE := layoutlib-tests
 LOCAL_MODULE_TAGS := optional
@@ -34,5 +34,8 @@
 
 include $(BUILD_HOST_JAVA_LIBRARY)
 
+# Copy the jar to DIST_DIR for sdk builds
+$(call dist-for-goals, sdk win_sdk, $(LOCAL_INSTALLED_MODULE))
+
 # Build all sub-directories
 include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/tools/layoutlib/bridge/tests/src/com/android/layoutlib/bridge/intensive/Main.java b/tools/layoutlib/bridge/tests/src/com/android/layoutlib/bridge/intensive/Main.java
index 31b3e25..a2588a6 100644
--- a/tools/layoutlib/bridge/tests/src/com/android/layoutlib/bridge/intensive/Main.java
+++ b/tools/layoutlib/bridge/tests/src/com/android/layoutlib/bridge/intensive/Main.java
@@ -104,9 +104,61 @@
             return platformDir;
         }
         // System Property not set. Try to find the directory in the build directory.
-        String out = System.getenv("ANDROID_HOST_OUT");
-        if (out == null || out.isEmpty() || !new File(out).isDirectory()) {
-            // Can't find the out directory.
+        String androidHostOut = System.getenv("ANDROID_HOST_OUT");
+        if (androidHostOut != null) {
+            platformDir = getPlatformDirFromHostOut(new File(androidHostOut));
+            if (platformDir != null) {
+                return platformDir;
+            }
+        }
+        String workingDirString = System.getProperty("user.dir");
+        File workingDir = new File(workingDirString);
+        // Test if workingDir is android checkout root.
+        platformDir = getPlatformDirFromRoot(workingDir);
+        if (platformDir != null) {
+            return platformDir;
+        }
+        // Test if workingDir is  platform/frameworks/base/tools/layoutlib. That is, root should be
+        // workingDir/../../../../  (4 levels up)
+        File currentDir = workingDir;
+        for (int i = 0; i < 4; i++) {
+            if (currentDir != null) {
+                currentDir = currentDir.getParentFile();
+            }
+        }
+        return currentDir == null ? null : getPlatformDirFromRoot(currentDir);
+    }
+
+    private static String getPlatformDirFromRoot(File root) {
+        if (!root.isDirectory()) {
+            return null;
+        }
+        File out = new File(root, "out");
+        if (!out.isDirectory()) {
+            return null;
+        }
+        File host = new File(out, "host");
+        if (!host.isDirectory()) {
+            return null;
+        }
+        File[] hosts = host.listFiles(new FileFilter() {
+            @Override
+            public boolean accept(File path) {
+                return path.isDirectory() && (path.getName().startsWith("linux-") || path.getName()
+                        .startsWith("darwin-"));
+            }
+        });
+        for (File hostOut : hosts) {
+            String platformDir = getPlatformDirFromHostOut(hostOut);
+            if (platformDir != null) {
+                return platformDir;
+            }
+        }
+        return null;
+    }
+
+    private static String getPlatformDirFromHostOut(File out) {
+        if (!out.isDirectory()) {
             return null;
         }
         File sdkDir = new File(out, "sdk" + File.separator + "sdk");
@@ -117,7 +169,7 @@
         File[] possibleSdks = sdkDir.listFiles(new FileFilter() {
             @Override
             public boolean accept(File path) {
-                return path.isDirectory() && path.getAbsolutePath().contains("android-sdk");
+                return path.isDirectory() && path.getName().contains("android-sdk");
             }
         });
         for (File possibleSdk : possibleSdks) {
diff --git a/tools/layoutlib/create/Android.mk b/tools/layoutlib/create/Android.mk
index 9bd48ab..e6f0bc3 100644
--- a/tools/layoutlib/create/Android.mk
+++ b/tools/layoutlib/create/Android.mk
@@ -26,3 +26,6 @@
 
 include $(BUILD_HOST_JAVA_LIBRARY)
 
+# Build all sub-directories
+include $(call all-makefiles-under,$(LOCAL_PATH))
+
diff --git a/tools/layoutlib/create/tests/Android.mk b/tools/layoutlib/create/tests/Android.mk
new file mode 100644
index 0000000..c197d57
--- /dev/null
+++ b/tools/layoutlib/create/tests/Android.mk
@@ -0,0 +1,35 @@
+# Copyright (C) 2014 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.
+
+LOCAL_PATH := $(call my-dir)
+include $(CLEAR_VARS)
+
+# Only compile source java files in this lib.
+LOCAL_SRC_FILES := $(call all-java-files-under, com)
+
+LOCAL_JAVA_RESOURCE_DIRS := data mock_data
+
+LOCAL_MODULE := layoutlib-create-tests
+LOCAL_MODULE_TAGS := optional
+
+LOCAL_JAVA_LIBRARIES := layoutlib_create junit
+LOCAL_STATIC_JAVA_LIBRARIES := asm-4.0
+
+include $(BUILD_HOST_JAVA_LIBRARY)
+
+# Copy the jar to DIST_DIR for sdk builds
+$(call dist-for-goals, sdk win_sdk, $(LOCAL_INSTALLED_MODULE))
+
+# Build all sub-directories
+include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/wifi/java/android/net/wifi/IWifiManager.aidl b/wifi/java/android/net/wifi/IWifiManager.aidl
index 71b6bee..a752686 100644
--- a/wifi/java/android/net/wifi/IWifiManager.aidl
+++ b/wifi/java/android/net/wifi/IWifiManager.aidl
@@ -18,13 +18,13 @@
 
 import android.net.wifi.BatchedScanResult;
 import android.net.wifi.BatchedScanSettings;
-import android.net.wifi.WifiAdapter;
 import android.net.wifi.WifiConfiguration;
 import android.net.wifi.WifiInfo;
 import android.net.wifi.ScanSettings;
 import android.net.wifi.WifiChannel;
 import android.net.wifi.ScanResult;
 import android.net.wifi.WifiConnectionStatistics;
+import android.net.wifi.WifiActivityEnergyInfo;
 
 import android.net.DhcpInfo;
 
@@ -39,7 +39,9 @@
  */
 interface IWifiManager
 {
-    List<WifiAdapter> getAdaptors();
+    int getSupportedFeatures();
+
+    WifiActivityEnergyInfo reportActivityInfo();
 
     List<WifiConfiguration> getConfiguredNetworks();
 
diff --git a/wifi/java/android/net/wifi/IWifiScanner.aidl b/wifi/java/android/net/wifi/IWifiScanner.aidl
index fef2d11..3984934 100644
--- a/wifi/java/android/net/wifi/IWifiScanner.aidl
+++ b/wifi/java/android/net/wifi/IWifiScanner.aidl
@@ -17,6 +17,7 @@
 package android.net.wifi;
 
 import android.os.Messenger;
+import android.os.Bundle;
 
 /**
  * {@hide}
@@ -24,4 +25,6 @@
 interface IWifiScanner
 {
     Messenger getMessenger();
+
+    Bundle getAvailableChannels(int band);
 }
diff --git a/wifi/java/android/net/wifi/ScanResult.java b/wifi/java/android/net/wifi/ScanResult.java
index a561dc2..e80a8f4 100644
--- a/wifi/java/android/net/wifi/ScanResult.java
+++ b/wifi/java/android/net/wifi/ScanResult.java
@@ -16,10 +16,8 @@
 
 package android.net.wifi;
 
-import android.net.wifi.passpoint.WifiPasspointInfo;
-import android.net.wifi.passpoint.WifiPasspointManager;
-import android.os.Parcelable;
 import android.os.Parcel;
+import android.os.Parcelable;
 
 /**
  * Describes information about a detected access point. In addition
@@ -48,7 +46,10 @@
      */
     public String capabilities;
     /**
-     * The detected signal level in dBm.
+     * The detected signal level in dBm, also known as the RSSI.
+     *
+     * <p>Use {@link android.net.wifi.WifiManager#calculateSignalLevel} to convert this number into
+     * an absolute signal level which can be displayed to a user.
      */
     public int level;
     /**
@@ -103,7 +104,24 @@
      * Status: indicating join status
      * @hide
      */
-    public int status;
+    public int autoJoinStatus;
+
+    /**
+     * @hide
+     * Last time we blacklisted the ScanResult
+     */
+    public long blackListTimestamp;
+
+    /** @hide **/
+    public void setAutoJoinStatus(int status) {
+        if (status < 0) status = 0;
+        if (status == 0) {
+            blackListTimestamp = 0;
+        }  else if (status > autoJoinStatus) {
+            blackListTimestamp = System.currentTimeMillis();
+        }
+        autoJoinStatus = status;
+    }
 
     /**
      * Status: indicating the scan result is not a result
@@ -139,12 +157,6 @@
     public int distanceSdCm;
 
     /**
-     * Passpoint ANQP information. This is not fetched automatically.
-     * Use {@link WifiPasspointManager#requestAnqpInfo} to request ANQP info.
-     */
-    public WifiPasspointInfo passpoint;
-
-    /**
      * {@hide}
      */
     public final static int UNSPECIFIED = -1;
@@ -240,8 +252,7 @@
             distanceCm = source.distanceCm;
             distanceSdCm = source.distanceSdCm;
             seen = source.seen;
-            passpoint = source.passpoint;
-            status = source.status;
+            autoJoinStatus = source.autoJoinStatus;
             untrusted = source.untrusted;
             numConnection = source.numConnection;
             numUsage = source.numUsage;
@@ -278,9 +289,8 @@
         sb.append(", distanceSd: ").append((distanceSdCm != UNSPECIFIED ? distanceSdCm : "?")).
                 append("(cm)");
 
-        sb.append(", passpoint: ").append(passpoint != null ? "yes" : "no");
-        if (status != 0) {
-            sb.append(", status: ").append(status);
+        if (autoJoinStatus != 0) {
+            sb.append(", status: ").append(autoJoinStatus);
         }
         return sb.toString();
     }
@@ -306,16 +316,10 @@
         dest.writeInt(distanceCm);
         dest.writeInt(distanceSdCm);
         dest.writeLong(seen);
-        dest.writeInt(status);
+        dest.writeInt(autoJoinStatus);
         dest.writeInt(untrusted ? 1 : 0);
         dest.writeInt(numConnection);
         dest.writeInt(numUsage);
-        if (passpoint != null) {
-            dest.writeInt(1);
-            passpoint.writeToParcel(dest, flags);
-        } else {
-            dest.writeInt(0);
-        }
         if (informationElements != null) {
             dest.writeInt(informationElements.length);
             for (int i = 0; i < informationElements.length; i++) {
@@ -347,13 +351,10 @@
                     in.readInt()
                 );
                 sr.seen = in.readLong();
-                sr.status = in.readInt();
+                sr.autoJoinStatus = in.readInt();
                 sr.untrusted = in.readInt() != 0;
                 sr.numConnection = in.readInt();
                 sr.numUsage = in.readInt();
-                if (in.readInt() == 1) {
-                    sr.passpoint = WifiPasspointInfo.CREATOR.createFromParcel(in);
-                }
                 int n = in.readInt();
                 if (n != 0) {
                     sr.informationElements = new InformationElement[n];
diff --git a/wifi/java/android/net/wifi/WifiActivityEnergyInfo.aidl b/wifi/java/android/net/wifi/WifiActivityEnergyInfo.aidl
new file mode 100644
index 0000000..007ec94
--- /dev/null
+++ b/wifi/java/android/net/wifi/WifiActivityEnergyInfo.aidl
@@ -0,0 +1,19 @@
+/**
+ * Copyright (c) 2014, 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 android.net.wifi;
+
+parcelable WifiActivityEnergyInfo;
diff --git a/wifi/java/android/net/wifi/WifiActivityEnergyInfo.java b/wifi/java/android/net/wifi/WifiActivityEnergyInfo.java
new file mode 100644
index 0000000..533b8bc
--- /dev/null
+++ b/wifi/java/android/net/wifi/WifiActivityEnergyInfo.java
@@ -0,0 +1,141 @@
+/*
+ * Copyright (C) 2014 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 android.net.wifi;
+
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Record of energy and activity information from controller and
+ * underlying wifi stack state.Timestamp the record with system
+ * time
+ * @hide
+ */
+public final class WifiActivityEnergyInfo implements Parcelable {
+    private final int mStackState;
+    private final int mControllerTxTimeMs;
+    private final int mControllerRxTimeMs;
+    private final int mControllerIdleTimeMs;
+    private final int mControllerEnergyUsed;
+    private final long timestamp;
+
+    public static final int STACK_STATE_INVALID = 0;
+    public static final int STACK_STATE_STATE_ACTIVE = 1;
+    public static final int STACK_STATE_STATE_SCANNING = 2;
+    public static final int STACK_STATE_STATE_IDLE = 3;
+
+    public WifiActivityEnergyInfo(int stackState, int txTime, int rxTime,
+                                  int idleTime, int energyUsed) {
+        mStackState = stackState;
+        mControllerTxTimeMs = txTime;
+        mControllerRxTimeMs = rxTime;
+        mControllerIdleTimeMs = idleTime;
+        mControllerEnergyUsed = energyUsed;
+        timestamp = System.currentTimeMillis();
+    }
+
+    @Override
+    public String toString() {
+        return "WifiActivityEnergyInfo{"
+            + " timestamp=" + timestamp
+            + " mStackState=" + mStackState
+            + " mControllerTxTimeMs=" + mControllerTxTimeMs
+            + " mControllerRxTimeMs=" + mControllerRxTimeMs
+            + " mControllerIdleTimeMs=" + mControllerIdleTimeMs
+            + " mControllerEnergyUsed=" + mControllerEnergyUsed
+            + " }";
+    }
+
+    public static final Parcelable.Creator<WifiActivityEnergyInfo> CREATOR =
+            new Parcelable.Creator<WifiActivityEnergyInfo>() {
+        public WifiActivityEnergyInfo createFromParcel(Parcel in) {
+            int stackState = in.readInt();
+            int txTime = in.readInt();
+            int rxTime = in.readInt();
+            int idleTime = in.readInt();
+            int energyUsed = in.readInt();
+            return new WifiActivityEnergyInfo(stackState, txTime, rxTime,
+                    idleTime, energyUsed);
+        }
+        public WifiActivityEnergyInfo[] newArray(int size) {
+            return new WifiActivityEnergyInfo[size];
+        }
+    };
+
+    public void writeToParcel(Parcel out, int flags) {
+        out.writeInt(mStackState);
+        out.writeInt(mControllerTxTimeMs);
+        out.writeInt(mControllerRxTimeMs);
+        out.writeInt(mControllerIdleTimeMs);
+        out.writeInt(mControllerEnergyUsed);
+    }
+
+    public int describeContents() {
+        return 0;
+    }
+
+    /**
+     * @return bt stack reported state
+     */
+    public int getStackState() {
+        return mStackState;
+    }
+
+    /**
+     * @return tx time in ms
+     */
+    public int getControllerTxTimeMillis() {
+        return (int)mControllerTxTimeMs;
+    }
+
+    /**
+     * @return rx time in ms
+     */
+    public int getControllerRxTimeMillis() {
+        return (int)mControllerRxTimeMs;
+    }
+
+    /**
+     * @return idle time in ms
+     */
+    public int getControllerIdleTimeMillis() {
+        return (int)mControllerIdleTimeMs;
+    }
+
+    /**
+     * product of current(mA), voltage(V) and time(ms)
+     * @return energy used
+     */
+    public int getControllerEnergyUsed() {
+        return mControllerEnergyUsed;
+    }
+    /**
+     * @return timestamp(wall clock) of record creation
+     */
+    public long getTimeStamp() {
+        return timestamp;
+    }
+
+    /**
+     * @return if the record is valid
+     */
+    public boolean isValid() {
+        return ((getControllerTxTimeMillis() !=0) ||
+                (getControllerRxTimeMillis() !=0) ||
+                (getControllerIdleTimeMillis() !=0));
+    }
+}
diff --git a/wifi/java/android/net/wifi/WifiAdapter.aidl b/wifi/java/android/net/wifi/WifiAdapter.aidl
deleted file mode 100644
index 931da92..0000000
--- a/wifi/java/android/net/wifi/WifiAdapter.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2008, 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 android.net.wifi;
-
-parcelable WifiAdapter;
diff --git a/wifi/java/android/net/wifi/WifiAdapter.java b/wifi/java/android/net/wifi/WifiAdapter.java
deleted file mode 100644
index c0211f3..0000000
--- a/wifi/java/android/net/wifi/WifiAdapter.java
+++ /dev/null
@@ -1,211 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/**
- * Represents local wifi adapter. Different devices have different kinds of
- * wifi adapters; each with different capabilities. Use this class to find out
- * which capabilites are supported by the wifi adapter on the device.
- */
-public class WifiAdapter implements Parcelable {
-
-    /* Keep this list in sync with wifi_hal.h */
-    /** @hide */
-    public static final int WIFI_FEATURE_INFRA            = 0x0001;  // Basic infrastructure mode
-    /** @hide */
-    public static final int WIFI_FEATURE_INFRA_5G         = 0x0002;  // Support for 5 GHz Band
-    /** @hide */
-    public static final int WIFI_FEATURE_PASSPOINT        = 0x0004;  // Support for GAS/ANQP
-    /** @hide */
-    public static final int WIFI_FEATURE_P2P              = 0x0008;  // Wifi-Direct
-    /** @hide */
-    public static final int WIFI_FEATURE_MOBILE_HOTSPOT   = 0x0010;  // Soft AP
-    /** @hide */
-    public static final int WIFI_FEATURE_SCANNER          = 0x0020;  // WifiScanner APIs
-    /** @hide */
-    public static final int WIFI_FEATURE_NAN              = 0x0040;  // Neighbor Awareness Networking
-    /** @hide */
-    public static final int WIFI_FEATURE_D2D_RTT          = 0x0080;  // Device-to-device RTT
-    /** @hide */
-    public static final int WIFI_FEATURE_D2AP_RTT         = 0x0100;  // Device-to-AP RTT
-    /** @hide */
-    public static final int WIFI_FEATURE_BATCH_SCAN       = 0x0200;  // Batched Scan (deprecated)
-    /** @hide */
-    public static final int WIFI_FEATURE_PNO              = 0x0400;  // Preferred network offload
-    /** @hide */
-    public static final int WIFI_FEATURE_ADDITIONAL_STA   = 0x0800;  // Support for two STAs
-    /** @hide */
-    public static final int WIFI_FEATURE_TDLS             = 0x1000;  // Tunnel directed link setup
-    /** @hide */
-    public static final int WIFI_FEATURE_TDLS_OFFCHANNEL  = 0x2000;  // Support for TDLS off channel
-    /** @hide */
-    public static final int WIFI_FEATURE_EPR              = 0x4000;  // Enhanced power reporting
-
-    private String name;
-    private int    supportedFeatures;
-
-    /** @hide */
-    public WifiAdapter(String name, int supportedFeatures) {
-        this.name = name;
-        this.supportedFeatures = supportedFeatures;
-    }
-
-    /**
-     * @return name of the adapter
-     */
-    public String getName() {
-        return name;
-    }
-
-    private int getSupportedFeatures() {
-        return supportedFeatures;
-    }
-
-    private boolean isFeatureSupported(int feature) {
-        return (supportedFeatures & feature) == feature;
-    }
-
-    /**
-     * @return true if this adapter supports 5 GHz band
-     */
-    public boolean is5GHzBandSupported() {
-        return isFeatureSupported(WIFI_FEATURE_INFRA_5G);
-    }
-
-    /**
-     * @return true if this adapter supports passpoint
-     */
-    public boolean isPasspointSupported() {
-        return isFeatureSupported(WIFI_FEATURE_PASSPOINT);
-    }
-
-    /**
-     * @return true if this adapter supports WifiP2pManager (Wi-Fi Direct)
-     */
-    public boolean isP2pSupported() {
-        return isFeatureSupported(WIFI_FEATURE_P2P);
-    }
-
-    /**
-     * @return true if this adapter supports portable Wi-Fi hotspot
-     */
-    public boolean isPortableHotspotSupported() {
-        return isFeatureSupported(WIFI_FEATURE_MOBILE_HOTSPOT);
-    }
-
-    /**
-     * @return true if this adapter supports WifiScanner APIs
-     */
-    public boolean isWifiScannerSupported() {
-        return isFeatureSupported(WIFI_FEATURE_SCANNER);
-    }
-
-    /**
-     * @return true if this adapter supports Neighbour Awareness Network APIs
-     * @hide
-     */
-    public boolean isNanSupported() {
-        return isFeatureSupported(WIFI_FEATURE_NAN);
-    }
-
-    /**
-     * @return true if this adapter supports Device-to-device RTT
-     */
-    public boolean isDeviceToDeviceRttSupported() {
-        return isFeatureSupported(WIFI_FEATURE_D2D_RTT);
-    }
-
-    /**
-     * @return true if this adapter supports Device-to-AP RTT
-     */
-    public boolean isDeviceToApRttSupported() {
-        return isFeatureSupported(WIFI_FEATURE_D2AP_RTT);
-    }
-
-    /**
-     * @return true if this adapter supports offloaded connectivity scan
-     */
-    public boolean isPreferredNetworkOffloadSupported() {
-        return isFeatureSupported(WIFI_FEATURE_PNO);
-    }
-
-    /**
-     * @return true if this adapter supports multiple simultaneous connections
-     * @hide
-     */
-    public boolean isAdditionalStaSupported() {
-        return isFeatureSupported(WIFI_FEATURE_ADDITIONAL_STA);
-    }
-
-    /**
-     * @return true if this adapter supports Tunnel Directed Link Setup
-     */
-    public boolean isTdlsSupported() {
-        return isFeatureSupported(WIFI_FEATURE_TDLS);
-    }
-
-    /**
-     * @return true if this adapter supports Off Channel Tunnel Directed Link Setup
-     */
-    public boolean isOffChannelTdlsSupported() {
-        return isFeatureSupported(WIFI_FEATURE_TDLS_OFFCHANNEL);
-    }
-
-    /**
-     * @return true if this adapter supports advanced power/performance counters
-     */
-    public boolean isEnhancedPowerReportingSupported() {
-        return isFeatureSupported(WIFI_FEATURE_EPR);
-    }
-
-    /* Parcelable implementation */
-    /**
-     * Implement the Parcelable interface
-     * {@hide}
-     */
-    public int describeContents() {
-        return 0;
-    }
-
-    /**
-     * Implement the Parcelable interface
-     * {@hide}
-     */
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeString(name);
-        dest.writeInt(supportedFeatures);
-    }
-
-    /**
-     * Implement the Parcelable interface
-     * {@hide}
-     */
-    public static final Creator<WifiAdapter> CREATOR =
-            new Creator<WifiAdapter>() {
-                public WifiAdapter createFromParcel(Parcel in) {
-                    WifiAdapter adaptor = new WifiAdapter(in.readString(), in.readInt());
-                    return adaptor;
-                }
-
-                public WifiAdapter[] newArray(int size) {
-                    return new WifiAdapter[size];
-                }
-            };
-}
diff --git a/wifi/java/android/net/wifi/WifiConfiguration.java b/wifi/java/android/net/wifi/WifiConfiguration.java
index 3c37b94..d27c2f7 100644
--- a/wifi/java/android/net/wifi/WifiConfiguration.java
+++ b/wifi/java/android/net/wifi/WifiConfiguration.java
@@ -21,7 +21,7 @@
 import android.net.IpConfiguration.ProxySettings;
 import android.net.IpConfiguration.IpAssignment;
 import android.net.ProxyInfo;
-import android.net.LinkProperties;
+import android.net.StaticIpConfiguration;
 import android.os.Parcel;
 import android.os.Parcelable;
 import android.text.TextUtils;
@@ -186,6 +186,8 @@
     public static final int DISABLED_AUTH_FAILURE                           = 3;
     /** @hide */
     public static final int DISABLED_ASSOCIATION_REJECT                     = 4;
+    /** @hide */
+    public static final int DISABLED_BY_WIFI_MANAGER                        = 5;
 
     /**
      * The ID number that the supplicant uses to identify this
@@ -341,6 +343,12 @@
 
     /**
      * @hide
+     * last time we connected, this configuration had no internet access
+     */
+    public boolean noInternetAccess;
+
+    /**
+     * @hide
      * Uid of app creating the configuration
      */
     @SystemApi
@@ -361,9 +369,9 @@
 
     /**
      * @hide
-     * Uid of app owning the BSSID
+     * Uid used by autoJoin
      */
-    public int bssidOwnerUid;
+    public String autoJoinBSSID;
 
     /**
      * @hide
@@ -374,10 +382,13 @@
 
     /** The Below RSSI thresholds are used to configure AutoJoin
      *  - GOOD/LOW/BAD thresholds are used so as to calculate link score
-     *  - UNWANTED_SOFT are used by the blacklisting logic so as to handle the unwanted network message coming from CS
-     *  - UNBLACKLIST thresholds are used so as to tweak the speed at which the network is unblacklisted (i.e. if
+     *  - UNWANTED_SOFT are used by the blacklisting logic so as to handle
+     *  the unwanted network message coming from CS
+     *  - UNBLACKLIST thresholds are used so as to tweak the speed at which
+     *  the network is unblacklisted (i.e. if
      *          it is seen with good RSSI, it is blacklisted faster)
-     *  - INITIAL_AUTOJOIN_ATTEMPT, used to determine how close from the network we need to be before autojoin kicks in
+     *  - INITIAL_AUTOJOIN_ATTEMPT, used to determine how close from
+     *  the network we need to be before autojoin kicks in
      */
     /** @hide **/
     public static int INVALID_RSSI = -127;
@@ -432,11 +443,7 @@
 
     /** @hide
      * 5GHz band is prefered low over 2.4 if the 5GHz RSSI is higher than this threshold */
-    public static int A_BAND_PREFERENCE_RSSI_THRESHOLD_LOW = -65;
-
-    /** @hide
-     * 5GHz band is prefered hard over 2.4 if the 5GHz RSSI is higher than this threshold */
-    public static int A_BAND_PREFERENCE_RSSI_THRESHOLD = -55;
+    public static int A_BAND_PREFERENCE_RSSI_THRESHOLD = -65;
 
     /** @hide
      * 5GHz band is penalized if the 5GHz RSSI is lower than this threshold **/
@@ -451,6 +458,12 @@
      ***/
     public static int HOME_NETWORK_RSSI_BOOST = 5;
 
+    /** @hide
+     * RSSI boost for configuration which use autoJoinUseAggressiveJoinAttemptThreshold
+     * To be more aggressive when initially attempting to auto join
+     */
+    public static int MAX_INITIAL_AUTO_JOIN_RSSI_BOOST = 8;
+
     /**
      * @hide
      * A summary of the RSSI and Band status for that configuration
@@ -461,8 +474,10 @@
         public int rssi24;  // strongest 2.4GHz RSSI
         public int num5;    // number of BSSIDs on 5GHz
         public int num24;   // number of BSSIDs on 2.4GHz
-        public long age5;  // timestamp of the strongest 5GHz BSSID (last time it was seen)
-        public long age24;   // timestamp of the strongest 2.4GHz BSSID (last time it was seen)
+        public long age5;   // timestamp of the strongest 5GHz BSSID (last time it was seen)
+        public long age24;  // timestamp of the strongest 2.4GHz BSSID (last time it was seen)
+        public String BSSID24;
+        public String BSSID5;
 
         public Visibility() {
             rssi5 = INVALID_RSSI;
@@ -476,6 +491,8 @@
             age5 = source.age5;
             num24 = source.num24;
             num5 = source.num5;
+            BSSID5 = source.BSSID5;
+            BSSID24 = source.BSSID24;
         }
 
         @Override
@@ -486,6 +503,7 @@
                 sbuf.append(Integer.toString(rssi24));
                 sbuf.append(",");
                 sbuf.append(Integer.toString(num24));
+                if (BSSID24 != null) sbuf.append(",").append(BSSID24);
             } else {
                 sbuf.append("*");
             }
@@ -494,6 +512,7 @@
                 sbuf.append(Integer.toString(rssi5));
                 sbuf.append(",");
                 sbuf.append(Integer.toString(num5));
+                if (BSSID5 != null) sbuf.append(",").append(BSSID5);
             }
             sbuf.append("]");
             return sbuf.toString();
@@ -543,11 +562,13 @@
                 if (result.level > status.rssi5) {
                     status.rssi5 = result.level;
                     status.age5 = result.seen;
+                    status.BSSID5 = result.BSSID;
                 }
             } else if (result.is24GHz()) {
                 if (result.level > status.rssi24) {
                     status.rssi24 = result.level;
                     status.age24 = result.seen;
+                    status.BSSID24 = result.BSSID;
                 }
             }
         }
@@ -580,6 +601,11 @@
     /** @hide */
     public static final int AUTO_JOIN_DISABLED_ON_AUTH_FAILURE  = 128;
     /** @hide */
+    public static final int AUTO_JOIN_DISABLED_NO_CREDENTIALS = 160;
+    /** @hide */
+    public static final int AUTO_JOIN_DISABLED_USER_ACTION = 161;
+
+    /** @hide */
     public static final int AUTO_JOIN_DELETED  = 200;
 
     /**
@@ -650,6 +676,18 @@
 
     /**
      * @hide
+     * Indicate that we didn't auto-join because rssi was too low
+     */
+    public boolean autoJoinBailedDueToLowRssi;
+
+    /**
+     * @hide
+     * AutoJoin even though RSSI is 10dB below threshold
+     */
+    public int autoJoinUseAggressiveJoinAttemptThreshold;
+
+    /**
+     * @hide
      * Number of time the scorer overrode a the priority based choice, when comparing two
      * WifiConfigurations, note that since comparing WifiConfiguration happens very often
      * potentially at every scan, this number might become very large, even on an idle
@@ -673,6 +711,49 @@
     @SystemApi
     public int numAssociation;
 
+    /**
+     * @hide
+     * Number of time user disabled WiFi while associated to this configuration with Low RSSI.
+     */
+    public int numUserTriggeredWifiDisableLowRSSI;
+
+    /**
+     * @hide
+     * Number of time user disabled WiFi while associated to this configuration with Bad RSSI.
+     */
+    public int numUserTriggeredWifiDisableBadRSSI;
+
+    /**
+     * @hide
+     * Number of time user disabled WiFi while associated to this configuration
+     * and RSSI was not HIGH.
+     */
+    public int numUserTriggeredWifiDisableNotHighRSSI;
+
+    /**
+     * @hide
+     * Number of ticks associated to this configuration with Low RSSI.
+     */
+    public int numTicksAtLowRSSI;
+
+    /**
+     * @hide
+     * Number of ticks associated to this configuration with Bad RSSI.
+     */
+    public int numTicksAtBadRSSI;
+
+    /**
+     * @hide
+     * Number of ticks associated to this configuration
+     * and RSSI was not HIGH.
+     */
+    public int numTicksAtNotHighRSSI;
+    /**
+     * @hide
+     * Number of time user (WifiManager) triggered association to this configuration.
+     * TODO: count this only for Wifi Settings uuid, so as to not count 3rd party apps
+     */
+    public int numUserTriggeredJoinAttempts;
 
     /**
      * @hide
@@ -725,6 +806,7 @@
         selfAdded = false;
         didSelfAdd = false;
         ephemeral = false;
+        noInternetAccess = false;
         mIpConfiguration = new IpConfiguration();
     }
 
@@ -823,9 +905,10 @@
         if (this.autoJoinStatus > 0) {
             sbuf.append(" autoJoinStatus ").append(this.numConnectionFailures).append("\n");
         }
-        if (this.didSelfAdd || this.selfAdded) {
-            if (this.didSelfAdd) sbuf.append(" didSelfAdd ");
-            if (this.selfAdded) sbuf.append(" selfAdded ");
+        if (this.didSelfAdd) sbuf.append(" didSelfAdd");
+        if (this.selfAdded) sbuf.append(" selfAdded");
+        if (this.noInternetAccess) sbuf.append(" noInternetAccess");
+        if (this.didSelfAdd || this.selfAdded || this.noInternetAccess) {
             sbuf.append("\n");
         }
         sbuf.append(" KeyMgmt:");
@@ -890,24 +973,84 @@
         if (this.preSharedKey != null) {
             sbuf.append('*');
         }
-
+        sbuf.append("\nEnterprise config:\n");
         sbuf.append(enterpriseConfig);
-        sbuf.append('\n');
 
+        sbuf.append("IP config:\n");
         sbuf.append(mIpConfiguration.toString());
 
-        if (selfAdded)  sbuf.append("selfAdded");
-        if (creatorUid != 0)  sbuf.append("uid=" + Integer.toString(creatorUid));
-
-        if (blackListTimestamp != 0) {
-            long now_ms = System.currentTimeMillis();
-            long diff = now_ms - blackListTimestamp;
+        if (this.creatorUid != 0)  sbuf.append(" uid=" + Integer.toString(creatorUid));
+        if (this.autoJoinBSSID != null) sbuf.append(" autoJoinBSSID=" + autoJoinBSSID);
+        long now_ms = System.currentTimeMillis();
+        if (this.blackListTimestamp != 0) {
+            sbuf.append('\n');
+            long diff = now_ms - this.blackListTimestamp;
             if (diff <= 0) {
-                sbuf.append("blackListed since <incorrect>");
+                sbuf.append(" blackListed since <incorrect>");
             } else {
-                sbuf.append("blackListed since ").append(Long.toString(diff/1000)).append( "sec");
+                sbuf.append(" blackListed: ").append(Long.toString(diff/1000)).append( "sec");
             }
         }
+        if (this.lastConnected != 0) {
+            sbuf.append('\n');
+            long diff = now_ms - this.lastConnected;
+            if (diff <= 0) {
+                sbuf.append("lastConnected since <incorrect>");
+            } else {
+                sbuf.append("lastConnected: ").append(Long.toString(diff/1000)).append( "sec");
+            }
+        }
+        if (this.lastConnectionFailure != 0) {
+            sbuf.append('\n');
+            long diff = now_ms - this.lastConnectionFailure;
+            if (diff <= 0) {
+                sbuf.append("lastConnectionFailure since <incorrect>");
+            } else {
+                sbuf.append("lastConnectionFailure: ").append(Long.toString(diff/1000));
+                sbuf.append( "sec");
+            }
+        }
+        sbuf.append('\n');
+        if (this.linkedConfigurations != null) {
+            for(String key : this.linkedConfigurations.keySet()) {
+                sbuf.append(" linked: ").append(key);
+                sbuf.append('\n');
+            }
+        }
+        if (this.connectChoices != null) {
+            for(String key : this.connectChoices.keySet()) {
+                Integer choice = this.connectChoices.get(key);
+                if (choice != null) {
+                    sbuf.append(" choice: ").append(key);
+                    sbuf.append(" = ").append(choice);
+                    sbuf.append('\n');
+                }
+            }
+        }
+        if (this.scanResultCache != null) {
+            sbuf.append("scan cache:  ");
+            for(ScanResult result : this.scanResultCache.values()) {
+                sbuf.append("{").append(result.BSSID).append(",").append(result.frequency);
+                sbuf.append(",").append(result.level).append(",st=");
+                sbuf.append(result.autoJoinStatus).append("} ");
+            }
+            sbuf.append('\n');
+        }
+        sbuf.append("triggeredLow: ").append(this.numUserTriggeredWifiDisableLowRSSI);
+        sbuf.append(" triggeredBad: ").append(this.numUserTriggeredWifiDisableBadRSSI);
+        sbuf.append(" triggeredNotHigh: ").append(this.numUserTriggeredWifiDisableNotHighRSSI);
+        sbuf.append('\n');
+        sbuf.append("ticksLow: ").append(this.numTicksAtLowRSSI);
+        sbuf.append(" ticksBad: ").append(this.numTicksAtBadRSSI);
+        sbuf.append(" ticksNotHigh: ").append(this.numTicksAtNotHighRSSI);
+        sbuf.append('\n');
+        sbuf.append("triggeredJoin: ").append(this.numUserTriggeredJoinAttempts);
+        sbuf.append('\n');
+        sbuf.append("autoJoinBailedDueToLowRssi: ").append(this.autoJoinBailedDueToLowRssi);
+        sbuf.append('\n');
+        sbuf.append("autoJoinUseAggressiveJoinAttemptThreshold: ");
+        sbuf.append(this.autoJoinUseAggressiveJoinAttemptThreshold);
+        sbuf.append('\n');
 
         return sbuf.toString();
     }
@@ -1096,13 +1239,13 @@
     }
 
     /** @hide */
-    public LinkProperties getLinkProperties() {
-        return mIpConfiguration.linkProperties;
+    public StaticIpConfiguration getStaticIpConfiguration() {
+        return mIpConfiguration.getStaticIpConfiguration();
     }
 
     /** @hide */
-    public void setLinkProperties(LinkProperties linkProperties) {
-        mIpConfiguration.linkProperties = linkProperties;
+    public void setStaticIpConfiguration(StaticIpConfiguration staticIpConfiguration) {
+        mIpConfiguration.setStaticIpConfiguration(staticIpConfiguration);
     }
 
     /** @hide */
@@ -1126,9 +1269,19 @@
     }
 
     /** @hide */
+    public ProxyInfo getHttpProxy() {
+        return mIpConfiguration.httpProxy;
+    }
+
+    /** @hide */
+    public void setHttpProxy(ProxyInfo httpProxy) {
+        mIpConfiguration.httpProxy = httpProxy;
+    }
+
+    /** @hide */
     public void setProxy(ProxySettings settings, ProxyInfo proxy) {
         mIpConfiguration.proxySettings = settings;
-        mIpConfiguration.linkProperties.setHttpProxy(proxy);
+        mIpConfiguration.httpProxy = proxy;
     }
 
     /** Implement the Parcelable interface {@hide} */
@@ -1187,7 +1340,7 @@
             mCachedConfigKey = null; //force null configKey
             autoJoinStatus = source.autoJoinStatus;
             selfAdded = source.selfAdded;
-
+            noInternetAccess = source.noInternetAccess;
             if (source.visibility != null) {
                 visibility = new Visibility(source.visibility);
             }
@@ -1196,7 +1349,6 @@
             didSelfAdd = source.didSelfAdd;
             lastConnectUid = source.lastConnectUid;
             lastUpdateUid = source.lastUpdateUid;
-            bssidOwnerUid = source.bssidOwnerUid;
             creatorUid = source.creatorUid;
             peerWifiConfiguration = source.peerWifiConfiguration;
             blackListTimestamp = source.blackListTimestamp;
@@ -1207,6 +1359,17 @@
             numScorerOverride = source.numScorerOverride;
             numScorerOverrideAndSwitchedNetwork = source.numScorerOverrideAndSwitchedNetwork;
             numAssociation = source.numAssociation;
+            numUserTriggeredWifiDisableLowRSSI = source.numUserTriggeredWifiDisableLowRSSI;
+            numUserTriggeredWifiDisableBadRSSI = source.numUserTriggeredWifiDisableBadRSSI;
+            numUserTriggeredWifiDisableNotHighRSSI = source.numUserTriggeredWifiDisableNotHighRSSI;
+            numTicksAtLowRSSI = source.numTicksAtLowRSSI;
+            numTicksAtBadRSSI = source.numTicksAtBadRSSI;
+            numTicksAtNotHighRSSI = source.numTicksAtNotHighRSSI;
+            numUserTriggeredJoinAttempts = source.numUserTriggeredJoinAttempts;
+            autoJoinBSSID = source.autoJoinBSSID;
+            autoJoinUseAggressiveJoinAttemptThreshold
+                    = source.autoJoinUseAggressiveJoinAttemptThreshold;
+            autoJoinBailedDueToLowRssi = source.autoJoinBailedDueToLowRssi;
         }
     }
 
@@ -1223,6 +1386,7 @@
         dest.writeInt(disableReason);
         dest.writeString(SSID);
         dest.writeString(BSSID);
+        dest.writeString(autoJoinBSSID);
         dest.writeString(FQDN);
         dest.writeString(naiRealm);
         dest.writeString(preSharedKey);
@@ -1249,16 +1413,25 @@
         dest.writeInt(autoJoinStatus);
         dest.writeInt(selfAdded ? 1 : 0);
         dest.writeInt(didSelfAdd ? 1 : 0);
+        dest.writeInt(noInternetAccess ? 1 : 0);
         dest.writeInt(creatorUid);
         dest.writeInt(lastConnectUid);
         dest.writeInt(lastUpdateUid);
-        dest.writeInt(bssidOwnerUid);
         dest.writeLong(blackListTimestamp);
         dest.writeLong(lastConnectionFailure);
         dest.writeInt(numConnectionFailures);
         dest.writeInt(numScorerOverride);
         dest.writeInt(numScorerOverrideAndSwitchedNetwork);
         dest.writeInt(numAssociation);
+        dest.writeInt(numUserTriggeredWifiDisableLowRSSI);
+        dest.writeInt(numUserTriggeredWifiDisableBadRSSI);
+        dest.writeInt(numUserTriggeredWifiDisableNotHighRSSI);
+        dest.writeInt(numTicksAtLowRSSI);
+        dest.writeInt(numTicksAtBadRSSI);
+        dest.writeInt(numTicksAtNotHighRSSI);
+        dest.writeInt(numUserTriggeredJoinAttempts);
+        dest.writeInt(autoJoinUseAggressiveJoinAttemptThreshold);
+        dest.writeInt(autoJoinBailedDueToLowRssi ? 1 : 0);
     }
 
     /** Implement the Parcelable interface {@hide} */
@@ -1271,6 +1444,7 @@
                 config.disableReason = in.readInt();
                 config.SSID = in.readString();
                 config.BSSID = in.readString();
+                config.autoJoinBSSID = in.readString();
                 config.FQDN = in.readString();
                 config.naiRealm = in.readString();
                 config.preSharedKey = in.readString();
@@ -1297,16 +1471,25 @@
                 config.autoJoinStatus = in.readInt();
                 config.selfAdded = in.readInt() != 0;
                 config.didSelfAdd = in.readInt() != 0;
+                config.noInternetAccess = in.readInt() != 0;
                 config.creatorUid = in.readInt();
                 config.lastConnectUid = in.readInt();
                 config.lastUpdateUid = in.readInt();
-                config.bssidOwnerUid = in.readInt();
                 config.blackListTimestamp = in.readLong();
                 config.lastConnectionFailure = in.readLong();
                 config.numConnectionFailures = in.readInt();
                 config.numScorerOverride = in.readInt();
                 config.numScorerOverrideAndSwitchedNetwork = in.readInt();
                 config.numAssociation = in.readInt();
+                config.numUserTriggeredWifiDisableLowRSSI = in.readInt();
+                config.numUserTriggeredWifiDisableBadRSSI = in.readInt();
+                config.numUserTriggeredWifiDisableNotHighRSSI = in.readInt();
+                config.numTicksAtLowRSSI = in.readInt();
+                config.numTicksAtBadRSSI = in.readInt();
+                config.numTicksAtNotHighRSSI = in.readInt();
+                config.numUserTriggeredJoinAttempts = in.readInt();
+                config.autoJoinUseAggressiveJoinAttemptThreshold = in.readInt();
+                config.autoJoinBailedDueToLowRssi = in.readInt() != 0;
                 return config;
             }
 
diff --git a/wifi/java/android/net/wifi/WifiEnterpriseConfig.java b/wifi/java/android/net/wifi/WifiEnterpriseConfig.java
index 1484d49..cf3cba3 100644
--- a/wifi/java/android/net/wifi/WifiEnterpriseConfig.java
+++ b/wifi/java/android/net/wifi/WifiEnterpriseConfig.java
@@ -271,9 +271,11 @@
     public void setEapMethod(int eapMethod) {
         switch (eapMethod) {
             /** Valid methods */
+            case Eap.TLS:
+                setPhase2Method(Phase2.NONE);
+                /* fall through */
             case Eap.PEAP:
             case Eap.PWD:
-            case Eap.TLS:
             case Eap.TTLS:
             case Eap.SIM:
             case Eap.AKA:
diff --git a/wifi/java/android/net/wifi/WifiInfo.java b/wifi/java/android/net/wifi/WifiInfo.java
index e808136..44a7108 100644
--- a/wifi/java/android/net/wifi/WifiInfo.java
+++ b/wifi/java/android/net/wifi/WifiInfo.java
@@ -323,7 +323,11 @@
     /**
      * Returns the received signal strength indicator of the current 802.11
      * network, in dBm.
-     * @return the RSSI, in the range -127 to 200
+     *
+     * <p>Use {@link android.net.wifi.WifiManager#calculateSignalLevel} to convert this number into
+     * an absolute signal level which can be displayed to a user.
+     *
+     * @return the RSSI.
      */
     public int getRssi() {
         return mRssi;
diff --git a/wifi/java/android/net/wifi/WifiLinkLayerStats.java b/wifi/java/android/net/wifi/WifiLinkLayerStats.java
index ae2fa98..7fac7cf 100644
--- a/wifi/java/android/net/wifi/WifiLinkLayerStats.java
+++ b/wifi/java/android/net/wifi/WifiLinkLayerStats.java
@@ -102,6 +102,14 @@
     /** {@hide} */
     public long retries_vo;
 
+    /** {@hide} */
+    public int on_time;
+    /** {@hide} */
+    public int tx_time;
+    /** {@hide} */
+    public int rx_time;
+    /** {@hide} */
+    public int on_time_scan;
 
     /** {@hide} */
     public WifiLinkLayerStats() {
@@ -138,7 +146,10 @@
                 .append(" tx=").append(Long.toString(this.txmpdu_vo))
                 .append(" lost=").append(Long.toString(this.lostmpdu_vo))
                 .append(" retries=").append(Long.toString(this.retries_vo)).append('\n');
-
+        sbuf.append(" on_time : ").append(Integer.toString(this.on_time))
+                .append(" tx_time=").append(Integer.toString(this.tx_time))
+                .append(" rx_time=").append(Integer.toString(this.rx_time))
+                .append(" scan_time=").append(Integer.toString(this.on_time_scan)).append('\n');
         return sbuf.toString();
     }
 
@@ -172,6 +183,10 @@
     public void writeToParcel(Parcel dest, int flags) {
         dest.writeString(SSID);
         dest.writeString(BSSID);
+        dest.writeInt(on_time);
+        dest.writeInt(tx_time);
+        dest.writeInt(rx_time);
+        dest.writeInt(on_time_scan);
     }
 
     /** Implement the Parcelable interface {@hide} */
@@ -181,6 +196,10 @@
                 WifiLinkLayerStats stats = new WifiLinkLayerStats();
                 stats.SSID = in.readString();
                 stats.BSSID = in.readString();
+                stats.on_time = in.readInt();
+                stats.tx_time = in.readInt();
+                stats.rx_time = in.readInt();
+                stats.on_time_scan = in.readInt();
                 return stats;
             };
             public WifiLinkLayerStats[] newArray(int size) {
diff --git a/wifi/java/android/net/wifi/WifiManager.java b/wifi/java/android/net/wifi/WifiManager.java
index e27bd7e..1393bce 100644
--- a/wifi/java/android/net/wifi/WifiManager.java
+++ b/wifi/java/android/net/wifi/WifiManager.java
@@ -576,18 +576,6 @@
     }
 
     /**
-     * Retrieve all wifi adapters available on this device
-     * @return list of adapters
-     */
-    public List<WifiAdapter> getAdapters() {
-        try {
-            return mService.getAdaptors();
-        } catch (RemoteException e) {
-            return null;
-        }
-    }
-
-    /**
      * Return a list of all the networks configured in the supplicant.
      * Not all fields of WifiConfiguration are returned. Only the following
      * fields are filled in:
@@ -820,6 +808,182 @@
         }
     }
 
+    /* Keep this list in sync with wifi_hal.h */
+    /** @hide */
+    public static final int WIFI_FEATURE_INFRA            = 0x0001;  // Basic infrastructure mode
+    /** @hide */
+    public static final int WIFI_FEATURE_INFRA_5G         = 0x0002;  // Support for 5 GHz Band
+    /** @hide */
+    public static final int WIFI_FEATURE_PASSPOINT        = 0x0004;  // Support for GAS/ANQP
+    /** @hide */
+    public static final int WIFI_FEATURE_P2P              = 0x0008;  // Wifi-Direct
+    /** @hide */
+    public static final int WIFI_FEATURE_MOBILE_HOTSPOT   = 0x0010;  // Soft AP
+    /** @hide */
+    public static final int WIFI_FEATURE_SCANNER          = 0x0020;  // WifiScanner APIs
+    /** @hide */
+    public static final int WIFI_FEATURE_NAN              = 0x0040;  // Neighbor Awareness Networking
+    /** @hide */
+    public static final int WIFI_FEATURE_D2D_RTT          = 0x0080;  // Device-to-device RTT
+    /** @hide */
+    public static final int WIFI_FEATURE_D2AP_RTT         = 0x0100;  // Device-to-AP RTT
+    /** @hide */
+    public static final int WIFI_FEATURE_BATCH_SCAN       = 0x0200;  // Batched Scan (deprecated)
+    /** @hide */
+    public static final int WIFI_FEATURE_PNO              = 0x0400;  // Preferred network offload
+    /** @hide */
+    public static final int WIFI_FEATURE_ADDITIONAL_STA   = 0x0800;  // Support for two STAs
+    /** @hide */
+    public static final int WIFI_FEATURE_TDLS             = 0x1000;  // Tunnel directed link setup
+    /** @hide */
+    public static final int WIFI_FEATURE_TDLS_OFFCHANNEL  = 0x2000;  // Support for TDLS off channel
+    /** @hide */
+    public static final int WIFI_FEATURE_EPR              = 0x4000;  // Enhanced power reporting
+
+    private int getSupportedFeatures() {
+        try {
+            return mService.getSupportedFeatures();
+        } catch (RemoteException e) {
+            return 0;
+        }
+    }
+
+    private boolean isFeatureSupported(int feature) {
+        return (getSupportedFeatures() & feature) == feature;
+    }
+    /**
+     * @return true if this adapter supports 5 GHz band
+     */
+    public boolean is5GHzBandSupported() {
+        return isFeatureSupported(WIFI_FEATURE_INFRA_5G);
+    }
+
+    /**
+     * @return true if this adapter supports passpoint
+     * @hide
+     */
+    public boolean isPasspointSupported() {
+        return isFeatureSupported(WIFI_FEATURE_PASSPOINT);
+    }
+
+    /**
+     * @return true if this adapter supports WifiP2pManager (Wi-Fi Direct)
+     */
+    public boolean isP2pSupported() {
+        return isFeatureSupported(WIFI_FEATURE_P2P);
+    }
+
+    /**
+     * @return true if this adapter supports portable Wi-Fi hotspot
+     * @hide
+     */
+    @SystemApi
+    public boolean isPortableHotspotSupported() {
+        return isFeatureSupported(WIFI_FEATURE_MOBILE_HOTSPOT);
+    }
+
+    /**
+     * @return true if this adapter supports WifiScanner APIs
+     * @hide
+     */
+    @SystemApi
+    public boolean isWifiScannerSupported() {
+        return isFeatureSupported(WIFI_FEATURE_SCANNER);
+    }
+
+    /**
+     * @return true if this adapter supports Neighbour Awareness Network APIs
+     * @hide
+     */
+    public boolean isNanSupported() {
+        return isFeatureSupported(WIFI_FEATURE_NAN);
+    }
+
+    /**
+     * @return true if this adapter supports Device-to-device RTT
+     * @hide
+     */
+    @SystemApi
+    public boolean isDeviceToDeviceRttSupported() {
+        return isFeatureSupported(WIFI_FEATURE_D2D_RTT);
+    }
+
+    /**
+     * @return true if this adapter supports Device-to-AP RTT
+     */
+    @SystemApi
+    public boolean isDeviceToApRttSupported() {
+        return isFeatureSupported(WIFI_FEATURE_D2AP_RTT);
+    }
+
+    /**
+     * @return true if this adapter supports offloaded connectivity scan
+     */
+    public boolean isPreferredNetworkOffloadSupported() {
+        return isFeatureSupported(WIFI_FEATURE_PNO);
+    }
+
+    /**
+     * @return true if this adapter supports multiple simultaneous connections
+     * @hide
+     */
+    public boolean isAdditionalStaSupported() {
+        return isFeatureSupported(WIFI_FEATURE_ADDITIONAL_STA);
+    }
+
+    /**
+     * @return true if this adapter supports Tunnel Directed Link Setup
+     */
+    public boolean isTdlsSupported() {
+        return isFeatureSupported(WIFI_FEATURE_TDLS);
+    }
+
+    /**
+     * @return true if this adapter supports Off Channel Tunnel Directed Link Setup
+     * @hide
+     */
+    public boolean isOffChannelTdlsSupported() {
+        return isFeatureSupported(WIFI_FEATURE_TDLS_OFFCHANNEL);
+    }
+
+    /**
+     * @return true if this adapter supports advanced power/performance counters
+     */
+    public boolean isEnhancedPowerReportingSupported() {
+        return isFeatureSupported(WIFI_FEATURE_EPR);
+    }
+
+    /**
+     * Return the record of {@link WifiActivityEnergyInfo} object that
+     * has the activity and energy info. This can be used to ascertain what
+     * the controller has been up to, since the last sample.
+     * @param updateType Type of info, cached vs refreshed.
+     *
+     * @return a record with {@link WifiActivityEnergyInfo} or null if
+     * report is unavailable or unsupported
+     * @hide
+     */
+    public WifiActivityEnergyInfo getControllerActivityEnergyInfo(int updateType) {
+        if (mService == null) return null;
+        try {
+            WifiActivityEnergyInfo record;
+            if (!isEnhancedPowerReportingSupported()) {
+                return null;
+            }
+            synchronized(this) {
+                record = mService.reportActivityInfo();
+                if (record.isValid()) {
+                    return record;
+                } else {
+                    return null;
+                }
+            }
+        } catch (RemoteException e) {
+            Log.e(TAG, "getControllerActivityEnergyInfo: " + e);
+        }
+        return null;
+    }
+
     /**
      * Request a scan for access points. Returns immediately. The availability
      * of the results is made known later by means of an asynchronous event sent
@@ -836,6 +1000,7 @@
     }
 
     /** @hide */
+    @SystemApi
     public boolean startScan(WorkSource workSource) {
         try {
             mService.startScan(null, workSource);
@@ -909,6 +1074,7 @@
      * @return false if not supported.
      * @hide
      */
+    @SystemApi
     public boolean isBatchedScanSupported() {
         try {
             return mService.isBatchedScanSupported();
@@ -935,6 +1101,7 @@
      * {@link BATCHED_SCAN_RESULTS_AVAILABLE_ACTION} is received.
      * @hide
      */
+    @SystemApi
     public List<BatchedScanResult> getBatchedScanResults() {
         try {
             return mService.getBatchedScanResults(mContext.getOpPackageName());
@@ -1453,12 +1620,14 @@
     /**
      * Passed with {@link ActionListener#onFailure}.
      * Indicates that the operation failed due to an internal error.
+     * @hide
      */
     public static final int ERROR                       = 0;
 
     /**
      * Passed with {@link ActionListener#onFailure}.
      * Indicates that the operation is already in progress
+     * @hide
      */
     public static final int IN_PROGRESS                 = 1;
 
@@ -1466,6 +1635,7 @@
      * Passed with {@link ActionListener#onFailure}.
      * Indicates that the operation failed because the framework is busy and
      * unable to service the request
+     * @hide
      */
     public static final int BUSY                        = 2;
 
@@ -1484,18 +1654,21 @@
     /**
      * Passed with {@link ActionListener#onFailure}.
      * Indicates that the operation failed due to invalid inputs
+     * @hide
      */
     public static final int INVALID_ARGS                = 8;
 
     /**
      * Passed with {@link ActionListener#onFailure}.
      * Indicates that the operation failed due to user permissions.
-     *
      * @hide
      */
     public static final int NOT_AUTHORIZED              = 9;
 
-    /** Interface for callback invocation on an application action */
+    /**
+     * Interface for callback invocation on an application action
+     * @hide
+     */
     public interface ActionListener {
         /** The operation succeeded */
         public void onSuccess();
@@ -1508,19 +1681,21 @@
     }
 
     /** Interface for callback invocation on a start WPS action */
-    public interface WpsListener {
+    public static abstract class WpsCallback {
         /** WPS start succeeded */
-        public void onStartSuccess(String pin);
+        public abstract void onStarted(String pin);
 
         /** WPS operation completed succesfully */
-        public void onCompletion();
+        public abstract void onSucceeded();
 
         /**
          * WPS operation failed
          * @param reason The reason for failure could be one of
-         * {@link #IN_PROGRESS}, {@link #WPS_OVERLAP_ERROR},{@link #ERROR} or {@link #BUSY}
+         * {@link #WPS_TKIP_ONLY_PROHIBITED}, {@link #WPS_OVERLAP_ERROR},
+         * {@link #WPS_WEP_PROHIBITED}, {@link #WPS_TIMED_OUT} or {@link #WPS_AUTH_FAILURE}
+         * and some generic errors.
          */
-        public void onFailure(int reason);
+        public abstract void onFailed(int reason);
     }
 
     /** Interface for callback invocation on a TX packet count poll action {@hide} */
@@ -1572,7 +1747,6 @@
                 case WifiManager.CONNECT_NETWORK_FAILED:
                 case WifiManager.FORGET_NETWORK_FAILED:
                 case WifiManager.SAVE_NETWORK_FAILED:
-                case WifiManager.CANCEL_WPS_FAILED:
                 case WifiManager.DISABLE_NETWORK_FAILED:
                     if (listener != null) {
                         ((ActionListener) listener).onFailure(message.arg1);
@@ -1582,7 +1756,6 @@
                 case WifiManager.CONNECT_NETWORK_SUCCEEDED:
                 case WifiManager.FORGET_NETWORK_SUCCEEDED:
                 case WifiManager.SAVE_NETWORK_SUCCEEDED:
-                case WifiManager.CANCEL_WPS_SUCCEDED:
                 case WifiManager.DISABLE_NETWORK_SUCCEEDED:
                     if (listener != null) {
                         ((ActionListener) listener).onSuccess();
@@ -1591,7 +1764,7 @@
                 case WifiManager.START_WPS_SUCCEEDED:
                     if (listener != null) {
                         WpsResult result = (WpsResult) message.obj;
-                        ((WpsListener) listener).onStartSuccess(result.pin);
+                        ((WpsCallback) listener).onStarted(result.pin);
                         //Listener needs to stay until completion or failure
                         synchronized(sListenerMapLock) {
                             sListenerMap.put(message.arg2, listener);
@@ -1600,12 +1773,22 @@
                     break;
                 case WifiManager.WPS_COMPLETED:
                     if (listener != null) {
-                        ((WpsListener) listener).onCompletion();
+                        ((WpsCallback) listener).onSucceeded();
                     }
                     break;
                 case WifiManager.WPS_FAILED:
                     if (listener != null) {
-                        ((WpsListener) listener).onFailure(message.arg1);
+                        ((WpsCallback) listener).onFailed(message.arg1);
+                    }
+                    break;
+                case WifiManager.CANCEL_WPS_SUCCEDED:
+                    if (listener != null) {
+                        ((WpsCallback) listener).onSucceeded();
+                    }
+                    break;
+                case WifiManager.CANCEL_WPS_FAILED:
+                    if (listener != null) {
+                        ((WpsCallback) listener).onFailed(message.arg1);
                     }
                     break;
                 case WifiManager.RSSI_PKTCNT_FETCH_SUCCEEDED:
@@ -1790,7 +1973,7 @@
      * @throws IllegalStateException if the WifiManager instance needs to be
      * initialized again
      */
-    public void startWps(WpsInfo config, WpsListener listener) {
+    public void startWps(WpsInfo config, WpsCallback listener) {
         if (config == null) throw new IllegalArgumentException("config cannot be null");
         validateChannel();
         sAsyncChannel.sendMessage(START_WPS, 0, putListener(listener), config);
@@ -1803,7 +1986,7 @@
      * @throws IllegalStateException if the WifiManager instance needs to be
      * initialized again
      */
-    public void cancelWps(ActionListener listener) {
+    public void cancelWps(WpsCallback listener) {
         validateChannel();
         sAsyncChannel.sendMessage(CANCEL_WPS, 0, putListener(listener));
     }
@@ -2348,4 +2531,7 @@
             return 0;
         }
     }
+
+
+
 }
diff --git a/wifi/java/android/net/wifi/WifiScanner.java b/wifi/java/android/net/wifi/WifiScanner.java
index e7bcb23..aaa2f98 100644
--- a/wifi/java/android/net/wifi/WifiScanner.java
+++ b/wifi/java/android/net/wifi/WifiScanner.java
@@ -18,6 +18,7 @@
 
 import android.annotation.SystemApi;
 import android.content.Context;
+import android.os.Bundle;
 import android.os.Handler;
 import android.os.HandlerThread;
 import android.os.Looper;
@@ -75,6 +76,11 @@
     public static final int REASON_INVALID_LISTENER = -2;
     /** Invalid request */
     public static final int REASON_INVALID_REQUEST = -3;
+    /** Invalid request */
+    public static final int REASON_NOT_AUTHORIZED = -4;
+
+    /** @hide */
+    public static final String GET_AVAILABLE_CHANNELS_EXTRA = "Channels";
 
     /**
      * Generic action callback invocation interface
@@ -92,7 +98,12 @@
      * @hide
      */
     public List<Integer> getAvailableChannels(int band) {
-        return null;
+        try {
+            Bundle bundle =  mService.getAvailableChannels(band);
+            return bundle.getIntegerArrayList(GET_AVAILABLE_CHANNELS_EXTRA);
+        } catch (RemoteException e) {
+            return null;
+        }
     }
 
     /**
diff --git a/wifi/java/android/net/wifi/passpoint/IWifiPasspointManager.aidl b/wifi/java/android/net/wifi/passpoint/IWifiPasspointManager.aidl
deleted file mode 100644
index 50bec33..0000000
--- a/wifi/java/android/net/wifi/passpoint/IWifiPasspointManager.aidl
+++ /dev/null
@@ -1,45 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-import android.net.wifi.ScanResult;
-import android.net.wifi.passpoint.WifiPasspointPolicy;
-import android.net.wifi.passpoint.WifiPasspointCredential;
-import android.os.Messenger;
-
-/**
- * Interface that allows controlling and querying Wifi Passpoint connectivity.
- *
- * {@hide}
- */
-interface IWifiPasspointManager
-{
-    Messenger getMessenger();
-
-    int getPasspointState();
-
-    List<WifiPasspointPolicy> requestCredentialMatch(in List<ScanResult> requested);
-
-    List<WifiPasspointCredential> getCredentials();
-
-    boolean addCredential(in WifiPasspointCredential cred);
-
-    boolean updateCredential(in WifiPasspointCredential cred);
-
-    boolean removeCredential(in WifiPasspointCredential cred);
-}
-
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.aidl b/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.aidl
deleted file mode 100644
index cfd3605..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-parcelable WifiPasspointCredential;
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.java
deleted file mode 100644
index 0a7230f..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointCredential.java
+++ /dev/null
@@ -1,667 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.net.wifi.WifiEnterpriseConfig;
-import android.os.Parcelable;
-import android.os.Parcel;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
-
-/**
- * A class representing a Wi-Fi Passpoint credential.
- * @hide
- */
-public class WifiPasspointCredential implements Parcelable {
-
-    private final static String TAG = "PasspointCredential";
-    private final static boolean DBG = true;
-
-    /** Wi-Fi nodes**/
-    private String mWifiSpFqdn;
-
-    /** PerProviderSubscription nodes **/
-    private String mCredentialName;
-
-    /** SubscriptionUpdate nodes **/
-    private String mSubscriptionUpdateInterval;
-    private String mSubscriptionUpdateMethod;
-    private String mSubscriptionUpdateRestriction;
-    private String mSubscriptionUpdateURI;
-    private String mSubscriptionUpdateUsername;
-    private String mSubscriptionUpdatePassword;
-
-    /** HomeSP nodes **/
-    private String mHomeSpFqdn;
-    private String mFriendlyName;
-    private Collection<WifiPasspointDmTree.HomeOIList> mHomeOIList;
-    private Collection<WifiPasspointDmTree.OtherHomePartners> mOtherHomePartnerList;
-
-    /** SubscriptionParameters nodes**/
-    private String mCreationDate;
-    private String mExpirationDate;
-
-    /** Credential nodes **/
-    private String mType;
-    private String mInnerMethod;
-    private String mCertType;
-    private String mCertSha256Fingerprint;
-    private String mUpdateIdentifier;
-    private String mUsername;
-    private String mPasswd;
-    private String mRealm;
-    private String mImsi;
-    private String mMcc;
-    private String mMnc;
-    private String mCaRootCert;
-    private String mClientCert;
-    private boolean mCheckAaaServerCertStatus;
-
-    /** Policy nodes **/
-    private String mPolicyUpdateUri;
-    private String mPolicyUpdateInterval;
-    private String mPolicyUpdateUsername;
-    private String mPolicyUpdatePassword;
-    private String mPolicyUpdateRestriction;
-    private String mPolicyUpdateMethod;
-    private Collection<WifiPasspointDmTree.PreferredRoamingPartnerList> mPreferredRoamingPartnerList;
-    private Collection<WifiPasspointDmTree.MinBackhaulThresholdNetwork> mMinBackhaulThresholdNetwork;
-    private Collection<WifiPasspointDmTree.SPExclusionList> mSpExclusionList;
-    private Collection<WifiPasspointDmTree.RequiredProtoPortTuple> mRequiredProtoPortTuple;
-    private String mMaxBssLoad;
-
-    /** CrednetialPriority node **/
-    private int mCrednetialPriority;
-
-    /** AAAServerTrustRoot nodes **/
-    private String mAaaCertUrl;
-    private String mAaaSha256Fingerprint;
-
-    /** Others **/
-    private boolean mIsMachineRemediation;
-    private boolean mUserPreferred = false;
-    private String mWifiTreePath;
-    private WifiEnterpriseConfig mEnterpriseConfig;
-
-    /** @hide */
-    public WifiPasspointCredential() {}
-
-    /**
-     * Constructor
-     * @param realm Realm of the passpoint credential
-     * @param fqdn Fully qualified domain name (FQDN) of the credential
-     * @param config Enterprise config, must be either EAP-TLS or EAP-TTLS
-     * @see WifiEnterpriseConfig
-     */
-    public WifiPasspointCredential(String realm, String fqdn, WifiEnterpriseConfig config) {
-        mRealm = realm;
-        switch (config.getEapMethod()) {
-            case WifiEnterpriseConfig.Eap.TLS:
-            case WifiEnterpriseConfig.Eap.TTLS:
-                mEnterpriseConfig = new WifiEnterpriseConfig(config);
-                break;
-            default:
-                // ignore
-        }
-    }
-
-    /** @hide */
-    public WifiPasspointCredential(String type,
-            String caroot,
-            String clientcert,
-            String mcc,
-            String mnc,
-            WifiPasspointDmTree.SpFqdn sp,
-            WifiPasspointDmTree.CredentialInfo credinfo) {
-
-        if (credinfo == null) {
-            return;
-        }
-
-        mType = type;
-        mCaRootCert = caroot;
-        mClientCert = clientcert;
-
-        mWifiSpFqdn = sp.nodeName;
-        mUpdateIdentifier = sp.perProviderSubscription.UpdateIdentifier;
-
-        mCredentialName = credinfo.nodeName;
-        mOtherHomePartnerList = credinfo.homeSP.otherHomePartners.values();
-
-        Set set = credinfo.aAAServerTrustRoot.entrySet();
-        Iterator i = set.iterator();
-        if (i.hasNext()) {
-            Map.Entry entry3 = (Map.Entry) i.next();
-            WifiPasspointDmTree.AAAServerTrustRoot aaa = (WifiPasspointDmTree.AAAServerTrustRoot) entry3.getValue();
-            mAaaCertUrl = aaa.CertURL;
-            mAaaSha256Fingerprint = aaa.CertSHA256Fingerprint;
-        }
-
-        mCertType = credinfo.credential.digitalCertificate.CertificateType;
-        mCertSha256Fingerprint = credinfo.credential.digitalCertificate.CertSHA256Fingerprint;
-        mUsername = credinfo.credential.usernamePassword.Username;
-        mPasswd = credinfo.credential.usernamePassword.Password;
-        mIsMachineRemediation = credinfo.credential.usernamePassword.MachineManaged;
-        mInnerMethod = credinfo.credential.usernamePassword.eAPMethod.InnerMethod;
-        mImsi = credinfo.credential.sim.IMSI;
-        mMcc = mcc;
-        mMnc = mnc;
-        mCreationDate = credinfo.credential.CreationDate;
-        mExpirationDate = credinfo.credential.ExpirationDate;
-        mRealm = credinfo.credential.Realm;
-
-        if (credinfo.credentialPriority == null) {
-            mCrednetialPriority = 128;
-        } else {
-            mCrednetialPriority = Integer.parseInt(credinfo.credentialPriority);
-        }
-
-        mHomeSpFqdn = credinfo.homeSP.FQDN;
-
-        mSubscriptionUpdateInterval = credinfo.subscriptionUpdate.UpdateInterval;
-        mSubscriptionUpdateMethod = credinfo.subscriptionUpdate.UpdateMethod;
-        mSubscriptionUpdateRestriction = credinfo.subscriptionUpdate.Restriction;
-        mSubscriptionUpdateURI = credinfo.subscriptionUpdate.URI;
-        mSubscriptionUpdateUsername = credinfo.subscriptionUpdate.usernamePassword.Username;
-        mSubscriptionUpdatePassword = credinfo.subscriptionUpdate.usernamePassword.Password;
-
-        mPolicyUpdateUri = credinfo.policy.policyUpdate.URI;
-        mPolicyUpdateInterval = credinfo.policy.policyUpdate.UpdateInterval;
-        mPolicyUpdateUsername = credinfo.policy.policyUpdate.usernamePassword.Username;
-        mPolicyUpdatePassword = credinfo.policy.policyUpdate.usernamePassword.Password;
-        mPolicyUpdateRestriction = credinfo.policy.policyUpdate.Restriction;
-        mPolicyUpdateMethod = credinfo.policy.policyUpdate.UpdateMethod;
-        mPreferredRoamingPartnerList = credinfo.policy.preferredRoamingPartnerList.values();
-        mMinBackhaulThresholdNetwork = credinfo.policy.minBackhaulThreshold.values();
-        mRequiredProtoPortTuple = credinfo.policy.requiredProtoPortTuple.values();
-        mMaxBssLoad = credinfo.policy.maximumBSSLoadValue;
-        mSpExclusionList = credinfo.policy.sPExclusionList.values();
-
-        mHomeOIList = credinfo.homeSP.homeOIList.values();
-        mFriendlyName = credinfo.homeSP.FriendlyName;
-        mCheckAaaServerCertStatus = credinfo.credential.CheckAAAServerCertStatus;
-    }
-
-    /** @hide */
-    public String getUpdateIdentifier() {
-        return mUpdateIdentifier;
-    }
-
-    /** @hide */
-    public String getUpdateMethod() {
-        return mSubscriptionUpdateMethod;
-    }
-
-    /** @hide */
-    public void setUpdateMethod(String method) {
-        mSubscriptionUpdateMethod = method;
-    }
-
-    /** @hide */
-    public String getWifiSpFqdn() {
-        return mWifiSpFqdn;
-    }
-
-    /** @hide */
-    public String getCredName() {
-        return mCredentialName;
-    }
-
-    /** @hide */
-    public String getType() {
-        return mType;
-    }
-
-    /**
-     * Get enterprise config of this Passpoint credential.
-     * @return Enterprise config
-     * @see WifiEnterpriseConfig
-     */
-    public WifiEnterpriseConfig getEnterpriseConfig() {
-        return new WifiEnterpriseConfig(mEnterpriseConfig);
-    }
-
-    /**
-     * Set enterprise config of this Passpoint credential.
-     * @param config Enterprise config, must be either EAP-TLS or EAP-TTLS
-     * @see WifiEnterpriseConfig
-     */
-    public void setEnterpriseConfig(WifiEnterpriseConfig config) {
-        // TODO
-    }
-
-    /** @hide */
-    public String getCertType() {
-        return mCertType;
-    }
-
-    /** @hide */
-    public String getCertSha256Fingerprint() {
-        return mCertSha256Fingerprint;
-    }
-
-    /** @hide */
-    public String getUserName() {
-        return mUsername;
-    }
-
-    /** @hide */
-    public String getPassword() {
-        // TODO: guarded by connectivity internal
-        return mPasswd;
-    }
-
-    /** @hide */
-    public String getImsi() {
-        return mImsi;
-    }
-
-    /** @hide */
-    public String getMcc() {
-        return mMcc;
-    }
-
-    /** @hide */
-    public String getMnc() {
-        return mMnc;
-    }
-
-    /** @hide */
-    public String getCaRootCertPath() {
-        return mCaRootCert;
-    }
-
-    /** @hide */
-    public String getClientCertPath() {
-        return mClientCert;
-    }
-
-    /**
-     * Get the realm of this Passpoint credential.
-     * @return Realm
-     */
-    public String getRealm() {
-        return mRealm;
-    }
-
-    /**
-     * Set the ream of this Passpoint credential.
-     * @param realm Realm
-     */
-    public void setRealm(String realm) {
-        mRealm = realm;
-    }
-
-    /** @hide */
-    public int getPriority() {
-        if (mUserPreferred) {
-            return 0;
-        }
-
-        return mCrednetialPriority;
-    }
-
-    /**
-     * Get the fully qualified domain name (FQDN) of this Passpoint credential.
-     * @return FQDN
-     */
-    public String getHomeSpFqdn() {
-        return mHomeSpFqdn;
-    }
-
-    /**
-     * Set the fully qualified domain name (FQDN) of this Passpoint credential.
-     * @param fqdn FQDN
-     */
-    public void setHomeFqdn(String fqdn) {
-        mHomeSpFqdn = fqdn;
-    }
-
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.OtherHomePartners> getOtherHomePartnerList() {
-        return mOtherHomePartnerList;
-    }
-
-    /** @hide */
-    public String getSubscriptionUpdateUsername() {
-        return mSubscriptionUpdateUsername;
-    }
-
-    /** @hide */
-    public String getSubscriptionUpdatePassword() {
-        return mSubscriptionUpdatePassword;
-    }
-
-    /** @hide */
-    public String getPolicyUpdateUri() {
-        return mPolicyUpdateUri;
-    }
-
-    /** @hide */
-    public String getPolicyUpdateInterval() {
-        return mPolicyUpdateInterval;
-    }
-
-    /** @hide */
-    public String getPolicyUpdateUsername() {
-        return mPolicyUpdateUsername;
-    }
-
-    /** @hide */
-    public String getPolicyUpdatePassword() {
-        return mPolicyUpdatePassword;
-    }
-
-    /** @hide */
-    public String getPolicyUpdateRestriction() {
-        return mPolicyUpdateRestriction;
-    }
-
-    /** @hide */
-    public String getPolicyUpdateMethod() {
-        return mPolicyUpdateMethod;
-    }
-
-    /** @hide */
-    public String getCreationDate() {
-        return mCreationDate;
-    }
-
-    /** @hide */
-    public String getExpirationDate() {
-        return mExpirationDate;
-    }
-
-    /** @hide */
-    public void setExpirationDate(String expirationdate) {
-        mExpirationDate = expirationdate;
-    }
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.PreferredRoamingPartnerList> getPreferredRoamingPartnerList() {
-        return mPreferredRoamingPartnerList;
-    }
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.HomeOIList> getHomeOiList() {
-        return mHomeOIList;
-    }
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.MinBackhaulThresholdNetwork> getBackhaulThresholdList() {
-        return mMinBackhaulThresholdNetwork;
-    }
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.RequiredProtoPortTuple> getRequiredProtoPortList() {
-        return mRequiredProtoPortTuple;
-    }
-
-    /** @hide */
-    public Collection<WifiPasspointDmTree.SPExclusionList> getSPExclusionList() {
-        return mSpExclusionList;
-    }
-
-    /** @hide */
-    public boolean getIsMachineRemediation() {
-        return mIsMachineRemediation;
-    }
-
-    /** @hide */
-    public String getAaaCertUrl() {
-        return mAaaCertUrl;
-    }
-
-    /** @hide */
-    public String getAaaSha256Fingerprint() {
-        return mAaaSha256Fingerprint;
-    }
-
-    /** @hide */
-    public String getSubscriptionUpdateRestriction() {
-        return mSubscriptionUpdateRestriction;
-    }
-
-    /** @hide */
-    public String getSubscriptionUpdateURI() {
-        return mSubscriptionUpdateURI;
-    }
-
-    /** @hide */
-    public String getSubscriptionUpdateInterval() {
-        return mSubscriptionUpdateInterval;
-    }
-
-    /** @hide */
-    public String getFriendlyName() {
-        return mFriendlyName;
-    }
-
-    /** @hide */
-    public String getMaxBssLoad() {
-        return mMaxBssLoad;
-    }
-
-    /** @hide */
-    public boolean getUserPreference() {
-        return mUserPreferred;
-    }
-
-    /** @hide */
-    public boolean getCheckAaaServerCertStatus() {
-        return mCheckAaaServerCertStatus;
-    }
-
-    /** @hide */
-    public void setUserPreference(boolean value) {
-        mUserPreferred = value;
-    }
-
-    @Override
-    /** @hide */
-    public boolean equals(Object obj) {
-        boolean result = false;
-        if (obj instanceof WifiPasspointCredential) {
-            final WifiPasspointCredential other = (WifiPasspointCredential) obj;
-            if (this.mType.equals(other.mType)) {
-                if (this.mType.equals("TTLS")) {
-                    result = this.mUsername.equals(other.mUsername) &&
-                            this.mPasswd.equals(other.mPasswd) &&
-                            this.mRealm.equals(other.mRealm) &&
-                            this.mHomeSpFqdn.equals(other.mHomeSpFqdn);
-                }
-                if (this.mType.equals("TLS")) {
-                    result = this.mRealm.equals(other.mRealm) &&
-                            this.mHomeSpFqdn.equals(other.mHomeSpFqdn) &&
-                            this.mClientCert.equals(other.mClientCert);
-                }
-                if (this.mType.equals("SIM")) {
-                    result = this.mMcc.equals(other.mMcc) &&
-                            this.mMnc.equals(other.mMnc) &&
-                            this.mImsi.equals(other.mImsi) &&
-                            this.mHomeSpFqdn.equals(other.mHomeSpFqdn);
-                }
-            }
-        }
-        return result;
-    }
-
-    @Override
-    /** @hide */
-    public String toString() {
-        StringBuffer sb = new StringBuffer();
-        String none = "<none>";
-
-        if (!DBG) {
-            sb.append(none);
-        } else {
-            sb.append(", UpdateIdentifier: ")
-            .append(mUpdateIdentifier == null ? none : mUpdateIdentifier)
-            .append(", SubscriptionUpdateMethod: ")
-            .append(mSubscriptionUpdateMethod == null ? none : mSubscriptionUpdateMethod)
-            .append(", Type: ").append(mType == null ? none : mType)
-            .append(", Username: ").append(mUsername == null ? none : mUsername)
-            .append(", Passwd: ").append(mPasswd == null ? none : mPasswd)
-            .append(", SubDMAccUsername: ")
-            .append(mSubscriptionUpdateUsername == null ? none : mSubscriptionUpdateUsername)
-            .append(", SubDMAccPassword: ")
-            .append(mSubscriptionUpdatePassword == null ? none : mSubscriptionUpdatePassword)
-            .append(", PolDMAccUsername: ")
-            .append(mPolicyUpdateUsername == null ? none : mPolicyUpdateUsername)
-            .append(", PolDMAccPassword: ")
-            .append(mPolicyUpdatePassword == null ? none : mPolicyUpdatePassword)
-            .append(", Imsi: ").append(mImsi == null ? none : mImsi)
-            .append(", Mcc: ").append(mMcc == null ? none : mMcc)
-            .append(", Mnc: ").append(mMnc == null ? none : mMnc)
-            .append(", CaRootCert: ").append(mCaRootCert == null ? none : mCaRootCert)
-            .append(", Realm: ").append(mRealm == null ? none : mRealm)
-            .append(", Priority: ").append(mCrednetialPriority)
-            .append(", Fqdn: ").append(mHomeSpFqdn == null ? none : mHomeSpFqdn)
-            .append(", Otherhomepartners: ")
-            .append(mOtherHomePartnerList == null ? none : mOtherHomePartnerList)
-            .append(", ExpirationDate: ")
-            .append(mExpirationDate == null ? none : mExpirationDate)
-            .append(", MaxBssLoad: ").append(mMaxBssLoad == null ? none : mMaxBssLoad)
-            .append(", SPExclusionList: ").append(mSpExclusionList);
-
-            if (mPreferredRoamingPartnerList != null) {
-                sb.append("PreferredRoamingPartnerList:");
-                for (WifiPasspointDmTree.PreferredRoamingPartnerList prpListItem : mPreferredRoamingPartnerList) {
-                    sb.append("[fqdnmatch:").append(prpListItem.FQDN_Match).
-                            append(", priority:").append(prpListItem.Priority).
-                            append(", country:").append(prpListItem.Country).append("]");
-                }
-            }
-
-            if (mHomeOIList != null) {
-                sb.append("HomeOIList:");
-                for (WifiPasspointDmTree.HomeOIList HomeOIListItem : mHomeOIList) {
-                    sb.append("[HomeOI:").append(HomeOIListItem.HomeOI).
-                            append(", HomeOIRequired:").append(HomeOIListItem.HomeOIRequired).
-                            append("]");
-                }
-            }
-
-            if (mMinBackhaulThresholdNetwork != null) {
-                sb.append("BackHaulThreshold:");
-                for (WifiPasspointDmTree.MinBackhaulThresholdNetwork BhtListItem : mMinBackhaulThresholdNetwork) {
-                    sb.append("[networkType:").append(BhtListItem.NetworkType).
-                            append(", dlBandwidth:").append(BhtListItem.DLBandwidth).
-                            append(", ulBandwidth:").append(BhtListItem.ULBandwidth).
-                            append("]");
-                }
-            }
-
-            if (mRequiredProtoPortTuple != null) {
-                sb.append("WifiMORequiredProtoPortTupleList:");
-                for (WifiPasspointDmTree.RequiredProtoPortTuple RpptListItem : mRequiredProtoPortTuple) {
-                    sb.append("[IPProtocol:").append(RpptListItem.IPProtocol).
-                            append(", PortNumber:").append(RpptListItem.PortNumber).
-                            append("]");
-                }
-            }
-        }
-        return sb.toString();
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public void writeToParcel(Parcel dest, int flags) {
-        dest.writeString(mWifiSpFqdn);
-        dest.writeString(mCredentialName);
-        dest.writeString(mType);
-        dest.writeInt(mCrednetialPriority);
-        dest.writeString(mHomeSpFqdn);
-        dest.writeString(mRealm);
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public void readFromParcel(Parcel in) {
-        mWifiSpFqdn = in.readString();
-        mCredentialName = in.readString();
-        mType = in.readString();
-        mCrednetialPriority = in.readInt();
-        mHomeSpFqdn = in.readString();
-        mRealm = in.readString();
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public static final Creator<WifiPasspointCredential> CREATOR =
-            new Creator<WifiPasspointCredential>() {
-                public WifiPasspointCredential createFromParcel(Parcel in) {
-                    WifiPasspointCredential pc = new WifiPasspointCredential();
-                    pc.mWifiSpFqdn = in.readString();
-                    pc.mCredentialName = in.readString();
-                    pc.mType = in.readString();
-                    pc.mCrednetialPriority = in.readInt();
-                    pc.mHomeSpFqdn = in.readString();
-                    pc.mRealm = in.readString();
-                    return pc;
-                }
-
-                public WifiPasspointCredential[] newArray(int size) {
-                    return new WifiPasspointCredential[size];
-                }
-            };
-
-    /** @hide */
-    public int compareTo(WifiPasspointCredential another) {
-
-        //The smaller the higher
-        if (mCrednetialPriority < another.mCrednetialPriority) {
-            return -1;
-        } else if (mCrednetialPriority == another.mCrednetialPriority) {
-            return this.mType.compareTo(another.mType);
-        } else {
-            return 1;
-        }
-    }
-
-    @Override
-    /** @hide */
-    public int hashCode() {
-        int hash = 208;
-        if (mType != null) {
-            hash += mType.hashCode();
-        }
-        if (mRealm != null) {
-            hash += mRealm.hashCode();
-        }
-        if (mHomeSpFqdn != null) {
-            hash += mHomeSpFqdn.hashCode();
-        }
-        if (mUsername != null) {
-            hash += mUsername.hashCode();
-        }
-        if (mPasswd != null) {
-            hash += mPasswd.hashCode();
-        }
-
-        return hash;
-    }
-}
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.aidl b/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.aidl
deleted file mode 100644
index 6a88b2e..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-parcelable WifiPasspointDmTree;
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.java
deleted file mode 100644
index bbf5fc6..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointDmTree.java
+++ /dev/null
@@ -1,1377 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.os.Parcelable;
-import android.os.Parcel;
-import android.util.Log;
-
-import java.util.HashMap;
-
-/**
- * Required Mobile Device Management Tree Structure
- *
- *                   +----------+
- *                   | ./(Root) |
- *                   +----+-----+
- *                        |
- *  +---------+           |         +---------+  +---------+
- *  | DevInfo |-----------+---------|  Wi-Fi  |--|SP FQDN* |
- *  +---------+           |         +---------+  +---------+
- *  +---------+           |                           |
- *  |DevDetail|-----------+                      +-----------------------+
- *  +---------+                                  |PerproviderSubscription|--<X>+
- *                                               +-----------------------+
- *
- * This class contains all nodes start from Wi-Fi
- * @hide
- **/
-public class WifiPasspointDmTree implements Parcelable {
-    private final static String TAG = "WifiTree";
-    public int PpsMoId;//plugfest used only
-    public HashMap<String, SpFqdn> spFqdn = new HashMap<String, SpFqdn>();//Maps.newHashMap();
-
-    public SpFqdn createSpFqdn(String name) {
-        SpFqdn obj = new SpFqdn(name);
-        spFqdn.put(name, obj);
-        return obj;
-    }
-
-    public static class SpFqdn implements Parcelable {
-        public String nodeName;
-        public PerProviderSubscription perProviderSubscription = new PerProviderSubscription();
-
-        public SpFqdn(String name) {
-            nodeName = name;
-        }
-
-        public SpFqdn() {
-        }
-
-        public SpFqdn(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeParcelable(perProviderSubscription, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                perProviderSubscription = in.readParcelable(PerProviderSubscription.class
-                        .getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<SpFqdn> CREATOR = new Parcelable.Creator<SpFqdn>() {
-            public SpFqdn createFromParcel(Parcel in) {
-                return new SpFqdn(in);
-            }
-
-            public SpFqdn[] newArray(int size) {
-                return new SpFqdn[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription
-     **/
-    public static class PerProviderSubscription implements Parcelable {
-        /**
-         * PerProviderSubscription/UpdateIdentifier
-         **/
-        public String UpdateIdentifier;
-        public HashMap<String, CredentialInfo> credentialInfo = new HashMap<String, CredentialInfo>();
-
-        public CredentialInfo createCredentialInfo(String name) {
-            CredentialInfo obj = new CredentialInfo(name);
-            credentialInfo.put(name, obj);
-            return obj;
-        }
-
-        public PerProviderSubscription() {
-        }
-
-        public PerProviderSubscription(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(UpdateIdentifier);
-            out.writeMap(credentialInfo);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                UpdateIdentifier = in.readString();
-                in.readMap(credentialInfo, CredentialInfo.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<PerProviderSubscription> CREATOR = new Parcelable.Creator<PerProviderSubscription>() {
-            public PerProviderSubscription createFromParcel(Parcel in) {
-                return new PerProviderSubscription(in);
-            }
-
-            public PerProviderSubscription[] newArray(int size) {
-                return new PerProviderSubscription[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>
-     * This interior node contains the Home SP information, subscription policy, management and credential information.
-     **/
-    public static class CredentialInfo implements Parcelable {
-        public String nodeName;
-        public Policy policy = new Policy();
-        public String credentialPriority;
-        public HashMap<String, AAAServerTrustRoot> aAAServerTrustRoot = new HashMap<String, AAAServerTrustRoot>();
-        public SubscriptionUpdate subscriptionUpdate = new SubscriptionUpdate();
-        public HomeSP homeSP = new HomeSP();
-        public SubscriptionParameters subscriptionParameters = new SubscriptionParameters();
-        public Credential credential = new Credential();
-        public Extension extension = new Extension();
-
-        public CredentialInfo(String nn) {
-            nodeName = nn;
-        }
-
-        public AAAServerTrustRoot createAAAServerTrustRoot(String name, String url, String fp) {
-            AAAServerTrustRoot obj = new AAAServerTrustRoot(name, url, fp);
-            aAAServerTrustRoot.put(name, obj);
-            return obj;
-        }
-
-        public CredentialInfo() {
-        }
-
-        public CredentialInfo(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeParcelable(policy, flags);
-            out.writeString(credentialPriority);
-            out.writeMap(aAAServerTrustRoot);
-            out.writeParcelable(subscriptionUpdate, flags);
-            out.writeParcelable(homeSP, flags);
-            out.writeParcelable(subscriptionParameters, flags);
-            out.writeParcelable(credential, flags);
-            //out.writeParcelable(extension, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                policy = in.readParcelable(Policy.class.getClassLoader());
-                credentialPriority = in.readString();
-                in.readMap(aAAServerTrustRoot, AAAServerTrustRoot.class.getClassLoader());
-                subscriptionUpdate = in.readParcelable(SubscriptionUpdate.class.getClassLoader());
-                homeSP = in.readParcelable(HomeSP.class.getClassLoader());
-                subscriptionParameters = in.readParcelable(SubscriptionParameters.class
-                        .getClassLoader());
-                credential = in.readParcelable(Credential.class.getClassLoader());
-                //extension = in.readParcelable(Extension.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<CredentialInfo> CREATOR = new Parcelable.Creator<CredentialInfo>() {
-            public CredentialInfo createFromParcel(Parcel in) {
-                return new CredentialInfo(in);
-            }
-
-            public CredentialInfo[] newArray(int size) {
-                return new CredentialInfo[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy
-     **/
-    public static class Policy implements Parcelable {
-        public HashMap<String, PreferredRoamingPartnerList> preferredRoamingPartnerList = new HashMap<String, PreferredRoamingPartnerList>();
-        public HashMap<String, MinBackhaulThresholdNetwork> minBackhaulThreshold = new HashMap<String, MinBackhaulThresholdNetwork>();
-        public PolicyUpdate policyUpdate = new PolicyUpdate();
-        public HashMap<String, SPExclusionList> sPExclusionList = new HashMap<String, SPExclusionList>();
-        public HashMap<String, RequiredProtoPortTuple> requiredProtoPortTuple = new HashMap<String, RequiredProtoPortTuple>();
-        public String maximumBSSLoadValue;
-
-        public PreferredRoamingPartnerList createPreferredRoamingPartnerList(String name,
-                String fqdn, String priority, String country) {
-            PreferredRoamingPartnerList obj = new PreferredRoamingPartnerList(name, fqdn, priority,
-                    country);
-            preferredRoamingPartnerList.put(name, obj);
-            return obj;
-        }
-
-        public MinBackhaulThresholdNetwork createMinBackhaulThreshold(String name, String type,
-                String dl, String ul) {
-            MinBackhaulThresholdNetwork obj = new MinBackhaulThresholdNetwork(name, type, dl, ul);
-            minBackhaulThreshold.put(name, obj);
-            return obj;
-        }
-
-        public SPExclusionList createSPExclusionList(String name, String ssid) {
-            SPExclusionList obj = new SPExclusionList(name, ssid);
-            sPExclusionList.put(name, obj);
-            return obj;
-        }
-
-        public RequiredProtoPortTuple createRequiredProtoPortTuple(String name, String proto,
-                String port) {
-            RequiredProtoPortTuple obj = new RequiredProtoPortTuple(name, proto, port);
-            requiredProtoPortTuple.put(name, obj);
-            return obj;
-        }
-
-        public Policy() {
-        }
-
-        public Policy(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeMap(preferredRoamingPartnerList);
-            out.writeMap(minBackhaulThreshold);
-            out.writeParcelable(policyUpdate, flags);
-            out.writeMap(sPExclusionList);
-            out.writeMap(requiredProtoPortTuple);
-            out.writeString(maximumBSSLoadValue);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                in.readMap(preferredRoamingPartnerList,
-                        PreferredRoamingPartnerList.class.getClassLoader());
-                in.readMap(minBackhaulThreshold, MinBackhaulThresholdNetwork.class.getClassLoader());
-                policyUpdate = in.readParcelable(PolicyUpdate.class.getClassLoader());
-                in.readMap(sPExclusionList, SPExclusionList.class.getClassLoader());
-                in.readMap(requiredProtoPortTuple, RequiredProtoPortTuple.class.getClassLoader());
-                maximumBSSLoadValue = in.readString();
-
-            }
-        }
-
-        public static final Parcelable.Creator<Policy> CREATOR = new Parcelable.Creator<Policy>() {
-            public Policy createFromParcel(Parcel in) {
-                return new Policy(in);
-            }
-
-            public Policy[] newArray(int size) {
-                return new Policy[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/PreferredRoamingPartnerList/<X+>
-     **/
-    public static class PreferredRoamingPartnerList implements Parcelable {
-        public String nodeName;
-        public String FQDN_Match; //maximum 255 + ",includeSubdomains", equals 273
-        public String Priority;
-        public String Country; // maximum 600 octets
-
-        public PreferredRoamingPartnerList(String nn, String f, String p, String c) {
-            nodeName = nn;
-            FQDN_Match = f;
-            Priority = p;
-            Country = c;
-        }
-
-        public PreferredRoamingPartnerList() {
-        }
-
-        public PreferredRoamingPartnerList(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(FQDN_Match);
-            out.writeString(Priority);
-            out.writeString(Country);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                FQDN_Match = in.readString();
-                Priority = in.readString();
-                Country = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<PreferredRoamingPartnerList> CREATOR = new Parcelable.Creator<PreferredRoamingPartnerList>() {
-            public PreferredRoamingPartnerList createFromParcel(Parcel in) {
-                return new PreferredRoamingPartnerList(in);
-            }
-
-            public PreferredRoamingPartnerList[] newArray(int size) {
-                return new PreferredRoamingPartnerList[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/MinBackhaulThreshold
-     **/
-    public static class MinBackhaulThresholdNetwork implements Parcelable {
-        public String nodeName;
-        public String NetworkType;
-        public String DLBandwidth;
-        public String ULBandwidth;
-
-        public MinBackhaulThresholdNetwork(String nn, String nt, String d, String u) {
-            nodeName = nn;
-            NetworkType = nt;
-            DLBandwidth = d;
-            ULBandwidth = u;
-        }
-
-        public MinBackhaulThresholdNetwork() {
-        }
-
-        public MinBackhaulThresholdNetwork(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(NetworkType);
-            out.writeString(DLBandwidth);
-            out.writeString(ULBandwidth);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                NetworkType = in.readString();
-                DLBandwidth = in.readString();
-                ULBandwidth = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<MinBackhaulThresholdNetwork> CREATOR = new Parcelable.Creator<MinBackhaulThresholdNetwork>() {
-            public MinBackhaulThresholdNetwork createFromParcel(Parcel in) {
-                return new MinBackhaulThresholdNetwork(in);
-            }
-
-            public MinBackhaulThresholdNetwork[] newArray(int size) {
-                return new MinBackhaulThresholdNetwork[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/PolicyUpdate
-     **/
-    public static class PolicyUpdate implements Parcelable {
-        public String UpdateInterval;
-        public String UpdateMethod;
-        public String Restriction;
-        public String URI;
-        public UsernamePassword usernamePassword = new UsernamePassword();
-        public String Other;
-        public TrustRoot trustRoot = new TrustRoot();
-
-        public PolicyUpdate() {
-        }
-
-        public PolicyUpdate(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(UpdateInterval);
-            out.writeString(UpdateMethod);
-            out.writeString(Restriction);
-            out.writeString(URI);
-            out.writeParcelable(usernamePassword, flags);
-            out.writeString(Other);
-            out.writeParcelable(trustRoot, flags);
-
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                UpdateInterval = in.readString();
-                UpdateMethod = in.readString();
-                Restriction = in.readString();
-                URI = in.readString();
-                usernamePassword = in.readParcelable(UsernamePassword.class.getClassLoader());
-                Other = in.readString();
-                trustRoot = in.readParcelable(TrustRoot.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<PolicyUpdate> CREATOR = new Parcelable.Creator<PolicyUpdate>() {
-            public PolicyUpdate createFromParcel(Parcel in) {
-                return new PolicyUpdate(in);
-            }
-
-            public PolicyUpdate[] newArray(int size) {
-                return new PolicyUpdate[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/SPExclusionList
-     **/
-    public static class SPExclusionList implements Parcelable {
-        public String nodeName;
-        public String SSID;
-
-        public SPExclusionList(String nn, String s) {
-            nodeName = nn;
-            SSID = s;
-        }
-
-        public SPExclusionList() {
-        }
-
-        public SPExclusionList(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(SSID);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                SSID = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<SPExclusionList> CREATOR = new Parcelable.Creator<SPExclusionList>() {
-            public SPExclusionList createFromParcel(Parcel in) {
-                return new SPExclusionList(in);
-            }
-
-            public SPExclusionList[] newArray(int size) {
-                return new SPExclusionList[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/RequiredProtoPortTuple
-     **/
-    public static class RequiredProtoPortTuple implements Parcelable {
-        public String nodeName;
-        public String IPProtocol;
-        public String PortNumber;
-
-        public RequiredProtoPortTuple() {
-        }
-
-        public RequiredProtoPortTuple(String nn, String protocol, String port) {
-            nodeName = nn;
-            IPProtocol = protocol;
-            PortNumber = port;
-        }
-
-        public RequiredProtoPortTuple(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(IPProtocol);
-            out.writeString(PortNumber);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                IPProtocol = in.readString();
-                PortNumber = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<RequiredProtoPortTuple> CREATOR = new Parcelable.Creator<RequiredProtoPortTuple>() {
-            public RequiredProtoPortTuple createFromParcel(Parcel in) {
-                return new RequiredProtoPortTuple(in);
-            }
-
-            public RequiredProtoPortTuple[] newArray(int size) {
-                return new RequiredProtoPortTuple[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/AAAServerTrustRoot
-     **/
-    public static class AAAServerTrustRoot implements Parcelable {
-        public String nodeName;
-        public String CertURL;
-        public String CertSHA256Fingerprint;
-
-        public AAAServerTrustRoot(String nn, String url, String fp) {
-            nodeName = nn;
-            CertURL = url;
-            CertSHA256Fingerprint = fp;
-        }
-
-        public AAAServerTrustRoot() {
-        }
-
-        public AAAServerTrustRoot(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(CertURL);
-            out.writeString(CertSHA256Fingerprint);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                CertURL = in.readString();
-                CertSHA256Fingerprint = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<AAAServerTrustRoot> CREATOR = new Parcelable.Creator<AAAServerTrustRoot>() {
-            public AAAServerTrustRoot createFromParcel(Parcel in) {
-                return new AAAServerTrustRoot(in);
-            }
-
-            public AAAServerTrustRoot[] newArray(int size) {
-                return new AAAServerTrustRoot[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/SubscriptionUpdate
-     **/
-    public static class SubscriptionUpdate implements Parcelable {
-        public String UpdateInterval;
-        public String UpdateMethod;
-        public String Restriction;
-        public String URI;
-        public UsernamePassword usernamePassword = new UsernamePassword();
-        public String Other;
-        public TrustRoot trustRoot = new TrustRoot();
-
-        public SubscriptionUpdate() {
-        }
-
-        public SubscriptionUpdate(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(UpdateInterval);
-            out.writeString(UpdateMethod);
-            out.writeString(Restriction);
-            out.writeString(URI);
-            out.writeParcelable(usernamePassword, flags);
-            out.writeString(Other);
-            out.writeParcelable(trustRoot, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                UpdateInterval = in.readString();
-                UpdateMethod = in.readString();
-                Restriction = in.readString();
-                URI = in.readString();
-                usernamePassword = in.readParcelable(UsernamePassword.class.getClassLoader());
-                Other = in.readString();
-                trustRoot = in.readParcelable(TrustRoot.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<SubscriptionUpdate> CREATOR = new Parcelable.Creator<SubscriptionUpdate>() {
-            public SubscriptionUpdate createFromParcel(Parcel in) {
-                return new SubscriptionUpdate(in);
-            }
-
-            public SubscriptionUpdate[] newArray(int size) {
-                return new SubscriptionUpdate[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/PolicyUpdate/TrustRoot
-     * PerProviderSubscription/<X+>/SubscriptionUpdate/TrustRoot
-     * PerProviderSubscription/<X+>/AAAServerTrustRoot/<X+>
-     **/
-    public static class TrustRoot implements Parcelable {
-        public String CertURL;
-        public String CertSHA256Fingerprint;
-
-        public TrustRoot() {
-        }
-
-        public TrustRoot(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(CertURL);
-            out.writeString(CertSHA256Fingerprint);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                CertURL = in.readString();
-                CertSHA256Fingerprint = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<TrustRoot> CREATOR = new Parcelable.Creator<TrustRoot>() {
-            public TrustRoot createFromParcel(Parcel in) {
-                return new TrustRoot(in);
-            }
-
-            public TrustRoot[] newArray(int size) {
-                return new TrustRoot[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Policy/PolicyUpdate/UsernamePassword
-     * PerProviderSubscription/<X+>/SubscriptionUpdate/UsernamePassword
-     * PerProviderSubscription/<X+>/Credential/UsernamePassword
-     **/
-    public static class UsernamePassword implements Parcelable {
-        public String Username;
-        public String Password;
-        //following are Credential node used only
-        public boolean MachineManaged;
-        public String SoftTokenApp;
-        public String AbleToShare;
-        public EAPMethod eAPMethod = new EAPMethod();
-
-        public UsernamePassword() {
-        }
-
-        public UsernamePassword(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(Username);
-            out.writeString(Password);
-            out.writeInt(MachineManaged ? 1 : 0);
-            out.writeString(SoftTokenApp);
-            out.writeString(AbleToShare);
-            out.writeParcelable(eAPMethod, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                Username = in.readString();
-                Password = in.readString();
-                MachineManaged = (in.readInt() == 1) ? true : false;
-                SoftTokenApp = in.readString();
-                AbleToShare = in.readString();
-                eAPMethod = in.readParcelable(EAPMethod.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<UsernamePassword> CREATOR = new Parcelable.Creator<UsernamePassword>() {
-            public UsernamePassword createFromParcel(Parcel in) {
-                return new UsernamePassword(in);
-            }
-
-            public UsernamePassword[] newArray(int size) {
-                return new UsernamePassword[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Credential/UsernamePassword/EAPMethod
-     **/
-    public static class EAPMethod implements Parcelable {
-        public String EAPType;
-        public String VendorId;
-        public String VendorType;
-        public String InnerEAPType;
-        public String InnerVendorId;
-        public String InnerVendorType;
-        public String InnerMethod;
-
-        public EAPMethod() {
-        }
-
-        public EAPMethod(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(EAPType);
-            out.writeString(VendorId);
-            out.writeString(VendorType);
-            out.writeString(InnerEAPType);
-            out.writeString(InnerVendorId);
-            out.writeString(InnerVendorType);
-            out.writeString(InnerMethod);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                EAPType = in.readString();
-                VendorId = in.readString();
-                VendorType = in.readString();
-                InnerEAPType = in.readString();
-                InnerVendorId = in.readString();
-                InnerVendorType = in.readString();
-                InnerMethod = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<EAPMethod> CREATOR = new Parcelable.Creator<EAPMethod>() {
-            public EAPMethod createFromParcel(Parcel in) {
-                return new EAPMethod(in);
-            }
-
-            public EAPMethod[] newArray(int size) {
-                return new EAPMethod[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/HomeSP
-     **/
-    public static class HomeSP implements Parcelable {
-        public HashMap<String, NetworkID> networkID = new HashMap<String, NetworkID>();
-        public String FriendlyName;
-        public String IconURL;
-        public String FQDN;
-        public HashMap<String, HomeOIList> homeOIList = new HashMap<String, HomeOIList>();
-        public HashMap<String, OtherHomePartners> otherHomePartners = new HashMap<String, OtherHomePartners>();
-        public String RoamingConsortiumOI;
-
-        public NetworkID createNetworkID(String name, String ssid, String hessid) {
-            NetworkID obj = new NetworkID(name, ssid, hessid);
-            networkID.put(name, obj);
-            return obj;
-        }
-
-        public HomeOIList createHomeOIList(String name, String homeoi, boolean required) {
-            HomeOIList obj = new HomeOIList(name, homeoi, required);
-            homeOIList.put(name, obj);
-            return obj;
-        }
-
-        public OtherHomePartners createOtherHomePartners(String name, String fqdn) {
-            OtherHomePartners obj = new OtherHomePartners(name, fqdn);
-            otherHomePartners.put(name, obj);
-            return obj;
-        }
-
-        public HomeSP() {
-        }
-
-        public HomeSP(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeMap(networkID);
-            out.writeString(FriendlyName);
-            out.writeString(IconURL);
-            out.writeString(FQDN);
-            out.writeMap(homeOIList);
-            out.writeMap(otherHomePartners);
-            out.writeString(RoamingConsortiumOI);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                in.readMap(networkID, NetworkID.class.getClassLoader());
-                FriendlyName = in.readString();
-                IconURL = in.readString();
-                FQDN = in.readString();
-                in.readMap(homeOIList, HomeOIList.class.getClassLoader());
-                in.readMap(otherHomePartners, OtherHomePartners.class.getClassLoader());
-                RoamingConsortiumOI = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<HomeSP> CREATOR = new Parcelable.Creator<HomeSP>() {
-            public HomeSP createFromParcel(Parcel in) {
-                return new HomeSP(in);
-            }
-
-            public HomeSP[] newArray(int size) {
-                return new HomeSP[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/HomeSP/NetworkID
-     **/
-    public static class NetworkID implements Parcelable {
-        public String nodeName;
-        public String SSID;
-        public String HESSID;
-
-        public NetworkID(String nn, String s, String h) {
-            nodeName = nn;
-            SSID = s;
-            HESSID = h;
-        }
-
-        public NetworkID() {
-        }
-
-        public NetworkID(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(SSID);
-            out.writeString(HESSID);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                SSID = in.readString();
-                HESSID = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<NetworkID> CREATOR = new Parcelable.Creator<NetworkID>() {
-            public NetworkID createFromParcel(Parcel in) {
-                return new NetworkID(in);
-            }
-
-            public NetworkID[] newArray(int size) {
-                return new NetworkID[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/HomeSP/HomeOIList
-     **/
-    public static class HomeOIList implements Parcelable {
-        public String nodeName;
-        public String HomeOI;
-        public boolean HomeOIRequired;
-
-        public HomeOIList(String nn, String h, boolean r) {
-            nodeName = nn;
-            HomeOI = h;
-            HomeOIRequired = r;
-        }
-
-        public HomeOIList() {
-        }
-
-        public HomeOIList(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(HomeOI);
-            out.writeInt(HomeOIRequired ? 1 : 0);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                HomeOI = in.readString();
-                HomeOIRequired = (in.readInt() == 1) ? true : false;
-            }
-        }
-
-        public static final Parcelable.Creator<HomeOIList> CREATOR = new Parcelable.Creator<HomeOIList>() {
-            public HomeOIList createFromParcel(Parcel in) {
-                return new HomeOIList(in);
-            }
-
-            public HomeOIList[] newArray(int size) {
-                return new HomeOIList[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/HomeSP/OtherHomePartners
-     **/
-    public static class OtherHomePartners implements Parcelable {
-        public String nodeName;
-        public String FQDN;
-
-        public OtherHomePartners(String nn, String f) {
-            nodeName = nn;
-            FQDN = f;
-        }
-
-        public OtherHomePartners() {
-        }
-
-        public OtherHomePartners(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(nodeName);
-            out.writeString(FQDN);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                nodeName = in.readString();
-                FQDN = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<OtherHomePartners> CREATOR = new Parcelable.Creator<OtherHomePartners>() {
-            public OtherHomePartners createFromParcel(Parcel in) {
-                return new OtherHomePartners(in);
-            }
-
-            public OtherHomePartners[] newArray(int size) {
-                return new OtherHomePartners[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/SubscriptionParameters
-     **/
-    public static class SubscriptionParameters implements Parcelable {
-        public String CreationDate;
-        public String ExpirationDate;
-        public String TypeOfSubscription;
-        public UsageLimits usageLimits = new UsageLimits();
-
-        public SubscriptionParameters() {
-        }
-
-        public SubscriptionParameters(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(CreationDate);
-            out.writeString(ExpirationDate);
-            out.writeString(TypeOfSubscription);
-            out.writeParcelable(usageLimits, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                CreationDate = in.readString();
-                ExpirationDate = in.readString();
-                TypeOfSubscription = in.readString();
-                usageLimits = in.readParcelable(UsageLimits.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<SubscriptionParameters> CREATOR = new Parcelable.Creator<SubscriptionParameters>() {
-            public SubscriptionParameters createFromParcel(Parcel in) {
-                return new SubscriptionParameters(in);
-            }
-
-            public SubscriptionParameters[] newArray(int size) {
-                return new SubscriptionParameters[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/SubscriptionParameters/UsageLimits
-     **/
-    public static class UsageLimits implements Parcelable {
-        public String DataLimit;
-        public String StartDate;
-        public String TimeLimit;
-        public String UsageTimePeriod;
-
-        public UsageLimits() {
-        }
-
-        public UsageLimits(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(DataLimit);
-            out.writeString(StartDate);
-            out.writeString(TimeLimit);
-            out.writeString(UsageTimePeriod);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                DataLimit = in.readString();
-                StartDate = in.readString();
-                TimeLimit = in.readString();
-                UsageTimePeriod = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<UsageLimits> CREATOR = new Parcelable.Creator<UsageLimits>() {
-            public UsageLimits createFromParcel(Parcel in) {
-                return new UsageLimits(in);
-            }
-
-            public UsageLimits[] newArray(int size) {
-                return new UsageLimits[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Credential
-     **/
-    public static class Credential implements Parcelable {
-        public String CreationDate;
-        public String ExpirationDate;
-        public UsernamePassword usernamePassword = new UsernamePassword();
-        public DigitalCertificate digitalCertificate = new DigitalCertificate();
-        public String Realm;
-        public boolean CheckAAAServerCertStatus;
-        public SIM sim = new SIM();
-
-        public Credential() {
-        }
-
-        public Credential(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(CreationDate);
-            out.writeString(ExpirationDate);
-            out.writeParcelable(usernamePassword, flags);
-            out.writeParcelable(digitalCertificate, flags);
-            out.writeString(Realm);
-            out.writeInt(CheckAAAServerCertStatus ? 1 : 0);
-            out.writeParcelable(sim, flags);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                CreationDate = in.readString();
-                ExpirationDate = in.readString();
-                usernamePassword = in.readParcelable(UsernamePassword.class.getClassLoader());
-                digitalCertificate = in.readParcelable(DigitalCertificate.class.getClassLoader());
-                Realm = in.readString();
-                CheckAAAServerCertStatus = (in.readInt() == 1) ? true : false;
-                sim = in.readParcelable(SIM.class.getClassLoader());
-            }
-        }
-
-        public static final Parcelable.Creator<Credential> CREATOR = new Parcelable.Creator<Credential>() {
-            public Credential createFromParcel(Parcel in) {
-                return new Credential(in);
-            }
-
-            public Credential[] newArray(int size) {
-                return new Credential[size];
-            }
-        };
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Credential/DigitalCertificate
-     **/
-    public static class DigitalCertificate implements Parcelable {
-        public String CertificateType;
-        public String CertSHA256Fingerprint;
-
-        public DigitalCertificate() {
-        }
-
-        public DigitalCertificate(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(CertificateType);
-            out.writeString(CertSHA256Fingerprint);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                CertificateType = in.readString();
-                CertSHA256Fingerprint = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<DigitalCertificate> CREATOR = new Parcelable.Creator<DigitalCertificate>() {
-            public DigitalCertificate createFromParcel(Parcel in) {
-                return new DigitalCertificate(in);
-            }
-
-            public DigitalCertificate[] newArray(int size) {
-                return new DigitalCertificate[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Credential/SIM
-     **/
-    public static class SIM implements Parcelable {
-        public String IMSI;
-        public String EAPType;
-
-        public SIM() {
-        }
-
-        public SIM(Parcel in) {
-            readFromParcel(in);
-        }
-
-        public int describeContents() {
-            return 0;
-        }
-
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(IMSI);
-            out.writeString(EAPType);
-        }
-
-        public void readFromParcel(Parcel in) {
-            if (in == null) {
-                //log here
-            } else {
-                IMSI = in.readString();
-                EAPType = in.readString();
-            }
-        }
-
-        public static final Parcelable.Creator<SIM> CREATOR = new Parcelable.Creator<SIM>() {
-            public SIM createFromParcel(Parcel in) {
-                return new SIM(in);
-            }
-
-            public SIM[] newArray(int size) {
-                return new SIM[size];
-            }
-        };
-
-    }
-
-    /**
-     * PerProviderSubscription/<X+>/Extension
-     **/
-    public static class Extension {
-        public String empty;
-    }
-
-    public WifiPasspointDmTree() {
-    }
-
-    public WifiPasspointDmTree(Parcel in) {
-        readFromParcel(in);
-    }
-
-    public int describeContents() {
-        return 0;
-    }
-
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeMap(spFqdn);
-    }
-
-    public void readFromParcel(Parcel in) {
-        if (in == null) {
-            //log here
-        } else {
-            in.readMap(spFqdn, SpFqdn.class.getClassLoader());
-        }
-    }
-
-    public static final Parcelable.Creator<WifiPasspointDmTree> CREATOR = new Parcelable.Creator<WifiPasspointDmTree>() {
-        public WifiPasspointDmTree createFromParcel(Parcel in) {
-            return new WifiPasspointDmTree(in);
-        }
-
-        public WifiPasspointDmTree[] newArray(int size) {
-            return new WifiPasspointDmTree[size];
-        }
-    };
-
-}
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.aidl b/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.aidl
deleted file mode 100644
index 27f23bc..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-parcelable WifiPasspointInfo;
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.java
deleted file mode 100644
index 32cf773..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointInfo.java
+++ /dev/null
@@ -1,558 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class WifiPasspointInfo implements Parcelable {
-
-    /** TODO doc */
-    public static final int ANQP_CAPABILITY = 1 << 0;
-
-    /** TODO doc */
-    public static final int VENUE_NAME = 1 << 1;
-
-    /** TODO doc */
-    public static final int NETWORK_AUTH_TYPE = 1 << 2;
-
-    /** TODO doc */
-    public static final int ROAMING_CONSORTIUM = 1 << 3;
-
-    /** TODO doc */
-    public static final int IP_ADDR_TYPE_AVAILABILITY = 1 << 4;
-
-    /** TODO doc */
-    public static final int NAI_REALM = 1 << 5;
-
-    /** TODO doc */
-    public static final int CELLULAR_NETWORK = 1 << 6;
-
-    /** TODO doc */
-    public static final int DOMAIN_NAME = 1 << 7;
-
-    /** TODO doc */
-    public static final int HOTSPOT_CAPABILITY = 1 << 8;
-
-    /** TODO doc */
-    public static final int OPERATOR_FRIENDLY_NAME = 1 << 9;
-
-    /** TODO doc */
-    public static final int WAN_METRICS = 1 << 10;
-
-    /** TODO doc */
-    public static final int CONNECTION_CAPABILITY = 1 << 11;
-
-    /** TODO doc */
-    public static final int OSU_PROVIDER = 1 << 12;
-
-    /** TODO doc */
-    public static final int PRESET_CRED_MATCH =
-            ANQP_CAPABILITY |
-                    HOTSPOT_CAPABILITY |
-                    NAI_REALM |
-                    CELLULAR_NETWORK |
-                    DOMAIN_NAME;
-
-    /** TODO doc */
-    public static final int PRESET_ALL =
-            ANQP_CAPABILITY |
-                    VENUE_NAME |
-                    NETWORK_AUTH_TYPE |
-                    ROAMING_CONSORTIUM |
-                    IP_ADDR_TYPE_AVAILABILITY |
-                    NAI_REALM |
-                    CELLULAR_NETWORK |
-                    DOMAIN_NAME |
-                    HOTSPOT_CAPABILITY |
-                    OPERATOR_FRIENDLY_NAME |
-                    WAN_METRICS |
-                    CONNECTION_CAPABILITY |
-                    OSU_PROVIDER;
-
-
-    public static class WanMetrics {
-        public static final int STATUS_RESERVED = 0;
-        public static final int STATUS_UP = 1;
-        public static final int STATUS_DOWN = 2;
-        public static final int STATUS_TEST = 3;
-
-        public int wanInfo;
-        public long downlinkSpeed;
-        public long uplinkSpeed;
-        public int downlinkLoad;
-        public int uplinkLoad;
-        public int lmd;
-
-        public int getLinkStatus() {
-            return wanInfo & 0x3;
-        }
-
-        public boolean getSymmetricLink() {
-            return (wanInfo & (1 << 2)) != 0;
-        }
-
-        public boolean getAtCapacity() {
-            return (wanInfo & (1 << 3)) != 0;
-        }
-
-        @Override
-        public String toString() {
-            return wanInfo + "," + downlinkSpeed + "," + uplinkSpeed + "," +
-                    downlinkLoad + "," + uplinkLoad + "," + lmd;
-        }
-    }
-
-    public static class IpProtoPort {
-        public static final int STATUS_CLOSED = 0;
-        public static final int STATUS_OPEN = 1;
-        public static final int STATUS_UNKNOWN = 2;
-
-        public int proto;
-        public int port;
-        public int status;
-
-        @Override
-        public String toString() {
-            return proto + "," + port + "," + status;
-        }
-    }
-
-    public static class NetworkAuthType {
-        public static final int TYPE_TERMS_AND_CONDITION = 0;
-        public static final int TYPE_ONLINE_ENROLLMENT = 1;
-        public static final int TYPE_HTTP_REDIRECTION = 2;
-        public static final int TYPE_DNS_REDIRECTION = 3;
-
-        public int type;
-        public String redirectUrl;
-
-        @Override
-        public String toString() {
-            return type + "," + redirectUrl;
-        }
-    }
-
-    public static class IpAddressType {
-        public static final int IPV6_NOT_AVAILABLE = 0;
-        public static final int IPV6_AVAILABLE = 1;
-        public static final int IPV6_UNKNOWN = 2;
-
-        public static final int IPV4_NOT_AVAILABLE = 0;
-        public static final int IPV4_PUBLIC = 1;
-        public static final int IPV4_PORT_RESTRICTED = 2;
-        public static final int IPV4_SINGLE_NAT = 3;
-        public static final int IPV4_DOUBLE_NAT = 4;
-        public static final int IPV4_PORT_RESTRICTED_SINGLE_NAT = 5;
-        public static final int IPV4_PORT_RESTRICTED_DOUBLE_NAT = 6;
-        public static final int IPV4_PORT_UNKNOWN = 7;
-
-        private static final int NULL_VALUE = -1;
-
-        public int availability;
-
-        public int getIpv6Availability() {
-            return availability & 0x3;
-        }
-
-        public int getIpv4Availability() {
-            return (availability & 0xFF) >> 2;
-        }
-
-        @Override
-        public String toString() {
-            return getIpv6Availability() + "," + getIpv4Availability();
-        }
-    }
-
-    public static class NaiRealm {
-        public static final int ENCODING_RFC4282 = 0;
-        public static final int ENCODING_UTF8 = 1;
-
-        public int encoding;
-        public String realm;
-
-        @Override
-        public String toString() {
-            return encoding + "," + realm;
-        }
-    }
-
-    public static class CellularNetwork {
-        public String mcc;
-        public String mnc;
-
-        @Override
-        public String toString() {
-            return mcc + "," + mnc;
-        }
-    }
-
-    /** BSSID */
-    public String bssid;
-
-    /** venue name */
-    public String venueName;
-
-    /** list of network authentication types */
-    public List<NetworkAuthType> networkAuthTypeList;
-
-    /** list of roaming consortium OIs */
-    public List<String> roamingConsortiumList;
-
-    /** IP address availability */
-    public IpAddressType ipAddrTypeAvailability;
-
-    /** list of NAI realm */
-    public List<NaiRealm> naiRealmList;
-
-    /** list of 3GPP cellular network */
-    public List<CellularNetwork> cellularNetworkList;
-
-    /** list of fully qualified domain name (FQDN) */
-    public List<String> domainNameList;
-
-    /** HS 2.0 operator friendly name */
-    public String operatorFriendlyName;
-
-    /** HS 2.0 wan metrics */
-    public WanMetrics wanMetrics;
-
-    /** list of HS 2.0 IP proto port */
-    public List<IpProtoPort> connectionCapabilityList;
-
-    /** list of HS 2.0 OSU providers */
-    public List<WifiPasspointOsuProvider> osuProviderList;
-
-    /**
-     * Convert mask to ANQP subtypes, for supplicant command use.
-     *
-     * @param mask The ANQP subtypes mask.
-     * @return String of ANQP subtypes, good for supplicant command use
-     * @hide
-     */
-    public static String toAnqpSubtypes(int mask) {
-        StringBuilder sb = new StringBuilder();
-        if ((mask & ANQP_CAPABILITY) != 0)
-            sb.append("257,");
-        if ((mask & VENUE_NAME) != 0)
-            sb.append("258,");
-        if ((mask & NETWORK_AUTH_TYPE) != 0)
-            sb.append("260,");
-        if ((mask & ROAMING_CONSORTIUM) != 0)
-            sb.append("261,");
-        if ((mask & IP_ADDR_TYPE_AVAILABILITY) != 0)
-            sb.append("262,");
-        if ((mask & NAI_REALM) != 0)
-            sb.append("263,");
-        if ((mask & CELLULAR_NETWORK) != 0)
-            sb.append("264,");
-        if ((mask & DOMAIN_NAME) != 0)
-            sb.append("268,");
-        if ((mask & HOTSPOT_CAPABILITY) != 0)
-            sb.append("hs20:2,");
-        if ((mask & OPERATOR_FRIENDLY_NAME) != 0)
-            sb.append("hs20:3,");
-        if ((mask & WAN_METRICS) != 0)
-            sb.append("hs20:4,");
-        if ((mask & CONNECTION_CAPABILITY) != 0)
-            sb.append("hs20:5,");
-        if ((mask & OSU_PROVIDER) != 0)
-            sb.append("hs20:8,");
-        if (sb.length() > 0)
-            sb.deleteCharAt(sb.length() - 1);
-        return sb.toString();
-    }
-
-    @Override
-    public String toString() {
-        StringBuffer sb = new StringBuffer();
-
-        sb.append("BSSID: ").append("(").append(bssid).append(")");
-
-        if (venueName != null)
-            sb.append(" venueName: ").append("(")
-              .append(venueName.replace("\n", "\\n")).append(")");
-
-        if (networkAuthTypeList != null) {
-            sb.append(" networkAuthType: ");
-            for (NetworkAuthType auth : networkAuthTypeList)
-                sb.append("(").append(auth.toString()).append(")");
-        }
-
-        if (roamingConsortiumList != null) {
-            sb.append(" roamingConsortium: ");
-            for (String oi : roamingConsortiumList)
-                sb.append("(").append(oi).append(")");
-        }
-
-        if (ipAddrTypeAvailability != null) {
-            sb.append(" ipAddrTypeAvaibility: ").append("(")
-              .append(ipAddrTypeAvailability.toString()).append(")");
-        }
-
-        if (naiRealmList != null) {
-            sb.append(" naiRealm: ");
-            for (NaiRealm realm : naiRealmList)
-                sb.append("(").append(realm.toString()).append(")");
-        }
-
-        if (cellularNetworkList != null) {
-            sb.append(" cellularNetwork: ");
-            for (CellularNetwork plmn : cellularNetworkList)
-                sb.append("(").append(plmn.toString()).append(")");
-        }
-
-        if (domainNameList != null) {
-            sb.append(" domainName: ");
-            for (String fqdn : domainNameList)
-                sb.append("(").append(fqdn).append(")");
-        }
-
-        if (operatorFriendlyName != null)
-            sb.append(" operatorFriendlyName: ").append("(")
-              .append(operatorFriendlyName).append(")");
-
-        if (wanMetrics != null)
-            sb.append(" wanMetrics: ").append("(")
-              .append(wanMetrics.toString()).append(")");
-
-        if (connectionCapabilityList != null) {
-            sb.append(" connectionCapability: ");
-            for (IpProtoPort ip : connectionCapabilityList)
-                sb.append("(").append(ip.toString()).append(")");
-        }
-
-        if (osuProviderList != null) {
-            sb.append(" osuProviderList: ");
-            for (WifiPasspointOsuProvider osu : osuProviderList)
-                sb.append("(").append(osu.toString()).append(")");
-        }
-
-        return sb.toString();
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeString(bssid);
-        out.writeString(venueName);
-
-        if (networkAuthTypeList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(networkAuthTypeList.size());
-            for (NetworkAuthType auth : networkAuthTypeList) {
-                out.writeInt(auth.type);
-                out.writeString(auth.redirectUrl);
-            }
-        }
-
-        if (roamingConsortiumList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(roamingConsortiumList.size());
-            for (String oi : roamingConsortiumList)
-                out.writeString(oi);
-        }
-
-        if (ipAddrTypeAvailability == null) {
-            out.writeInt(IpAddressType.NULL_VALUE);
-        } else {
-            out.writeInt(ipAddrTypeAvailability.availability);
-        }
-
-        if (naiRealmList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(naiRealmList.size());
-            for (NaiRealm realm : naiRealmList) {
-                out.writeInt(realm.encoding);
-                out.writeString(realm.realm);
-            }
-        }
-
-        if (cellularNetworkList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(cellularNetworkList.size());
-            for (CellularNetwork plmn : cellularNetworkList) {
-                out.writeString(plmn.mcc);
-                out.writeString(plmn.mnc);
-            }
-        }
-
-
-        if (domainNameList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(domainNameList.size());
-            for (String fqdn : domainNameList)
-                out.writeString(fqdn);
-        }
-
-        out.writeString(operatorFriendlyName);
-
-        if (wanMetrics == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(1);
-            out.writeInt(wanMetrics.wanInfo);
-            out.writeLong(wanMetrics.downlinkSpeed);
-            out.writeLong(wanMetrics.uplinkSpeed);
-            out.writeInt(wanMetrics.downlinkLoad);
-            out.writeInt(wanMetrics.uplinkLoad);
-            out.writeInt(wanMetrics.lmd);
-        }
-
-        if (connectionCapabilityList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(connectionCapabilityList.size());
-            for (IpProtoPort ip : connectionCapabilityList) {
-                out.writeInt(ip.proto);
-                out.writeInt(ip.port);
-                out.writeInt(ip.status);
-            }
-        }
-
-        if (osuProviderList == null) {
-            out.writeInt(0);
-        } else {
-            out.writeInt(osuProviderList.size());
-            for (WifiPasspointOsuProvider osu : osuProviderList)
-                osu.writeToParcel(out, flags);
-        }
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public static final Parcelable.Creator<WifiPasspointInfo> CREATOR =
-            new Parcelable.Creator<WifiPasspointInfo>() {
-                @Override
-                public WifiPasspointInfo createFromParcel(Parcel in) {
-                    WifiPasspointInfo p = new WifiPasspointInfo();
-                    int n;
-
-                    p.bssid = in.readString();
-                    p.venueName = in.readString();
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.networkAuthTypeList = new ArrayList<NetworkAuthType>();
-                        for (int i = 0; i < n; i++) {
-                            NetworkAuthType auth = new NetworkAuthType();
-                            auth.type = in.readInt();
-                            auth.redirectUrl = in.readString();
-                            p.networkAuthTypeList.add(auth);
-                        }
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.roamingConsortiumList = new ArrayList<String>();
-                        for (int i = 0; i < n; i++)
-                            p.roamingConsortiumList.add(in.readString());
-                    }
-
-                    n = in.readInt();
-                    if (n != IpAddressType.NULL_VALUE) {
-                        p.ipAddrTypeAvailability = new IpAddressType();
-                        p.ipAddrTypeAvailability.availability = n;
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.naiRealmList = new ArrayList<NaiRealm>();
-                        for (int i = 0; i < n; i++) {
-                            NaiRealm realm = new NaiRealm();
-                            realm.encoding = in.readInt();
-                            realm.realm = in.readString();
-                            p.naiRealmList.add(realm);
-                        }
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.cellularNetworkList = new ArrayList<CellularNetwork>();
-                        for (int i = 0; i < n; i++) {
-                            CellularNetwork plmn = new CellularNetwork();
-                            plmn.mcc = in.readString();
-                            plmn.mnc = in.readString();
-                            p.cellularNetworkList.add(plmn);
-                        }
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.domainNameList = new ArrayList<String>();
-                        for (int i = 0; i < n; i++)
-                            p.domainNameList.add(in.readString());
-                    }
-
-                    p.operatorFriendlyName = in.readString();
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.wanMetrics = new WanMetrics();
-                        p.wanMetrics.wanInfo = in.readInt();
-                        p.wanMetrics.downlinkSpeed = in.readLong();
-                        p.wanMetrics.uplinkSpeed = in.readLong();
-                        p.wanMetrics.downlinkLoad = in.readInt();
-                        p.wanMetrics.uplinkLoad = in.readInt();
-                        p.wanMetrics.lmd = in.readInt();
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.connectionCapabilityList = new ArrayList<IpProtoPort>();
-                        for (int i = 0; i < n; i++) {
-                            IpProtoPort ip = new IpProtoPort();
-                            ip.proto = in.readInt();
-                            ip.port = in.readInt();
-                            ip.status = in.readInt();
-                            p.connectionCapabilityList.add(ip);
-                        }
-                    }
-
-                    n = in.readInt();
-                    if (n > 0) {
-                        p.osuProviderList = new ArrayList<WifiPasspointOsuProvider>();
-                        for (int i = 0; i < n; i++) {
-                            WifiPasspointOsuProvider osu = WifiPasspointOsuProvider.CREATOR
-                                    .createFromParcel(in);
-                            p.osuProviderList.add(osu);
-                        }
-                    }
-
-                    return p;
-                }
-
-                @Override
-                public WifiPasspointInfo[] newArray(int size) {
-                    return new WifiPasspointInfo[size];
-                }
-            };
-}
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointManager.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointManager.java
deleted file mode 100644
index b2b5310..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointManager.java
+++ /dev/null
@@ -1,420 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.content.Context;
-import android.net.wifi.ScanResult;
-import android.os.Handler;
-import android.os.Looper;
-import android.os.Message;
-import android.os.Messenger;
-import android.os.Parcel;
-import android.os.Parcelable;
-import android.os.RemoteException;
-import android.util.Log;
-
-import com.android.internal.util.AsyncChannel;
-import com.android.internal.util.Protocol;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.LinkedList;
-import java.util.List;
-
-/**
- * Provides APIs for managing Wifi Passpoint credentials.
- */
-public class WifiPasspointManager {
-
-    private static final String TAG = "PasspointManager";
-
-    private static final boolean DBG = true;
-
-    /* Passpoint states values */
-
-    /** Passpoint is in an unknown state. This should only occur in boot time */
-    public static final int PASSPOINT_STATE_UNKNOWN = 0;
-
-    /** Passpoint is disabled. This occurs when wifi is disabled */
-    public static final int PASSPOINT_STATE_DISABLED = 1;
-
-    /** Passpoint is enabled and in discovery state */
-    public static final int PASSPOINT_STATE_DISCOVERY = 2;
-
-    /** Passpoint is enabled and in access state */
-    public static final int PASSPOINT_STATE_ACCESS = 3;
-
-    /** Passpoint is enabled and in provisioning state */
-    public static final int PASSPOINT_STATE_PROVISION = 4;
-
-    /* Passpoint callback error codes */
-
-    /** Indicates that the operation failed due to an internal error */
-    public static final int REASON_ERROR = 0;
-
-    /** Indicates that the operation failed because wifi is disabled */
-    public static final int REASON_WIFI_DISABLED = 1;
-
-    /** Indicates that the operation failed because the framework is busy */
-    public static final int REASON_BUSY = 2;
-
-    /** Indicates that the operation failed because parameter is invalid */
-    public static final int REASON_INVALID_PARAMETER = 3;
-
-    /** Indicates that the operation failed because the server is not trusted */
-    public static final int REASON_NOT_TRUSTED = 4;
-
-    /**
-     * protocol supported for Passpoint
-     */
-    public static final String PROTOCOL_DM = "OMA-DM-ClientInitiated";
-
-    /**
-     * protocol supported for Passpoint
-     */
-    public static final String PROTOCOL_SOAP = "SPP-ClientInitiated";
-
-    /* Passpoint broadcasts */
-
-    /**
-     * Broadcast intent action indicating that the state of Passpoint
-     * connectivity has changed
-     */
-    public static final String PASSPOINT_STATE_CHANGED_ACTION =
-            "android.net.wifi.passpoint.STATE_CHANGE";
-
-    /**
-     * Broadcast intent action indicating that the saved Passpoint credential
-     * list has changed
-     */
-    public static final String PASSPOINT_CRED_CHANGED_ACTION =
-            "android.net.wifi.passpoint.CRED_CHANGE";
-
-    /**
-     * Broadcast intent action indicating that Passpoint online sign up is
-     * avaiable.
-     */
-    public static final String PASSPOINT_OSU_AVAILABLE_ACTION =
-            "android.net.wifi.passpoint.OSU_AVAILABLE";
-
-    /**
-     * Broadcast intent action indicating that user remediation is required
-     */
-    public static final String PASSPOINT_USER_REM_REQ_ACTION =
-            "android.net.wifi.passpoint.USER_REM_REQ";
-
-    /**
-     * Interface for callback invocation when framework channel is lost
-     */
-    public interface ChannelListener {
-        /**
-         * The channel to the framework has been disconnected. Application could
-         * try re-initializing using {@link #initialize}
-         */
-        public void onChannelDisconnected();
-    }
-
-    /**
-     * Interface for callback invocation on an application action
-     */
-    public interface ActionListener {
-        /** The operation succeeded */
-        public void onSuccess();
-
-        /**
-         * The operation failed
-         *
-         * @param reason The reason for failure could be one of
-         *            {@link #REASON_WIFI_DISABLED}, {@link #REASON_ERROR} or {@link #REASON_BUSY}
-         */
-        public void onFailure(int reason);
-    }
-
-    /**
-     * A channel that connects the application to the wifi passpoint framework.
-     * Most passpoint operations require a Channel as an argument.
-     * An instance of Channel is obtained by doing a call on {@link #initialize}
-     */
-    public static class Channel {
-        private final static int INVALID_LISTENER_KEY = 0;
-
-        private ChannelListener mChannelListener;
-
-        private HashMap<Integer, Object> mListenerMap = new HashMap<Integer, Object>();
-        private HashMap<Integer, Integer> mListenerMapCount = new HashMap<Integer, Integer>();
-        private Object mListenerMapLock = new Object();
-        private int mListenerKey = 0;
-
-        private List<ScanResult> mAnqpRequest = new LinkedList<ScanResult>();
-        private Object mAnqpRequestLock = new Object();
-
-        private AsyncChannel mAsyncChannel;
-        private PasspointHandler mHandler;
-        Context mContext;
-
-        Channel(Context context, Looper looper, ChannelListener l) {
-            mAsyncChannel = new AsyncChannel();
-            mHandler = new PasspointHandler(looper);
-            mChannelListener = l;
-            mContext = context;
-        }
-
-        private int putListener(Object listener) {
-            return putListener(listener, 1);
-        }
-
-        private int putListener(Object listener, int count) {
-            if (listener == null || count <= 0)
-                return INVALID_LISTENER_KEY;
-            int key;
-            synchronized (mListenerMapLock) {
-                do {
-                    key = mListenerKey++;
-                } while (key == INVALID_LISTENER_KEY);
-                mListenerMap.put(key, listener);
-                mListenerMapCount.put(key, count);
-            }
-            return key;
-        }
-
-        private Object peekListener(int key) {
-            Log.d(TAG, "peekListener() key=" + key);
-            if (key == INVALID_LISTENER_KEY)
-                return null;
-            synchronized (mListenerMapLock) {
-                return mListenerMap.get(key);
-            }
-        }
-
-
-        private Object getListener(int key, boolean forceRemove) {
-            Log.d(TAG, "getListener() key=" + key + " force=" + forceRemove);
-            if (key == INVALID_LISTENER_KEY)
-                return null;
-            synchronized (mListenerMapLock) {
-                if (!forceRemove) {
-                    int count = mListenerMapCount.get(key);
-                    Log.d(TAG, "count=" + count);
-                    mListenerMapCount.put(key, --count);
-                    if (count > 0)
-                        return null;
-                }
-                Log.d(TAG, "remove key");
-                mListenerMapCount.remove(key);
-                return mListenerMap.remove(key);
-            }
-        }
-
-        private void anqpRequestStart(ScanResult sr) {
-            Log.d(TAG, "anqpRequestStart sr.bssid=" + sr.BSSID);
-            synchronized (mAnqpRequestLock) {
-                mAnqpRequest.add(sr);
-            }
-        }
-
-        private void anqpRequestFinish(WifiPasspointInfo result) {
-            Log.d(TAG, "anqpRequestFinish pi.bssid=" + result.bssid);
-            synchronized (mAnqpRequestLock) {
-                for (ScanResult sr : mAnqpRequest)
-                    if (sr.BSSID.equals(result.bssid)) {
-                        Log.d(TAG, "find hit " + result.bssid);
-                        sr.passpoint = result;
-                        mAnqpRequest.remove(sr);
-                        Log.d(TAG, "mAnqpRequest.len=" + mAnqpRequest.size());
-                        break;
-                    }
-            }
-        }
-
-        private void anqpRequestFinish(ScanResult sr) {
-            Log.d(TAG, "anqpRequestFinish sr.bssid=" + sr.BSSID);
-            synchronized (mAnqpRequestLock) {
-                for (ScanResult sr1 : mAnqpRequest)
-                    if (sr1.BSSID.equals(sr.BSSID)) {
-                        mAnqpRequest.remove(sr1);
-                        break;
-                    }
-            }
-        }
-
-        class PasspointHandler extends Handler {
-            PasspointHandler(Looper looper) {
-                super(looper);
-            }
-
-            @Override
-            public void handleMessage(Message message) {
-                Object listener = null;
-
-                switch (message.what) {
-                    case AsyncChannel.CMD_CHANNEL_DISCONNECTED:
-                        if (mChannelListener != null) {
-                            mChannelListener.onChannelDisconnected();
-                            mChannelListener = null;
-                        }
-                        break;
-
-                    case REQUEST_ANQP_INFO_SUCCEEDED:
-                        WifiPasspointInfo result = (WifiPasspointInfo) message.obj;
-                        anqpRequestFinish(result);
-                        listener = getListener(message.arg2, false);
-                        if (listener != null) {
-                            ((ActionListener) listener).onSuccess();
-                        }
-                        break;
-
-                    case REQUEST_ANQP_INFO_FAILED:
-                        anqpRequestFinish((ScanResult) message.obj);
-                        listener = getListener(message.arg2, false);
-                        if (listener == null)
-                            getListener(message.arg2, true);
-                        if (listener != null) {
-                            ((ActionListener) listener).onFailure(message.arg1);
-                        }
-                        break;
-
-                    default:
-                        Log.d(TAG, "Ignored " + message);
-                        break;
-                }
-            }
-        }
-
-    }
-
-    public static class ParcelableString implements Parcelable {
-        public String string;
-
-        @Override
-        public int describeContents() {
-            return 0;
-        }
-
-        @Override
-        public void writeToParcel(Parcel out, int flags) {
-            out.writeString(string);
-        }
-
-        public static final Parcelable.Creator<ParcelableString> CREATOR =
-                new Parcelable.Creator<ParcelableString>() {
-                    @Override
-                    public ParcelableString createFromParcel(Parcel in) {
-                        ParcelableString ret = new ParcelableString();
-                        ret.string = in.readString();
-                        return ret;
-                    }
-                    @Override
-                    public ParcelableString[] newArray(int size) {
-                        return new ParcelableString[size];
-                    }
-        };
-    }
-
-    private static final int BASE = Protocol.BASE_WIFI_PASSPOINT_MANAGER;
-
-    public static final int REQUEST_ANQP_INFO                   = BASE + 1;
-    public static final int REQUEST_ANQP_INFO_FAILED            = BASE + 2;
-    public static final int REQUEST_ANQP_INFO_SUCCEEDED         = BASE + 3;
-    public static final int REQUEST_OSU_ICON                    = BASE + 4;
-    public static final int REQUEST_OSU_ICON_FAILED             = BASE + 5;
-    public static final int REQUEST_OSU_ICON_SUCCEEDED          = BASE + 6;
-    public static final int START_OSU                           = BASE + 7;
-    public static final int START_OSU_BROWSER                   = BASE + 8;
-    public static final int START_OSU_FAILED                    = BASE + 9;
-    public static final int START_OSU_SUCCEEDED                 = BASE + 10;
-
-    private Context mContext;
-    IWifiPasspointManager mService;
-
-    /**
-     * TODO: doc
-     * @param context
-     * @param service
-     */
-    public WifiPasspointManager(Context context, IWifiPasspointManager service) {
-        mContext = context;
-        mService = service;
-    }
-
-    /**
-     * Registers the application with the framework. This function must be the
-     * first to be called before any async passpoint operations are performed.
-     *
-     * @param srcContext is the context of the source
-     * @param srcLooper is the Looper on which the callbacks are receivied
-     * @param listener for callback at loss of framework communication. Can be
-     *            null.
-     * @return Channel instance that is necessary for performing any further
-     *         passpoint operations
-     *
-     */
-    public Channel initialize(Context srcContext, Looper srcLooper, ChannelListener listener) {
-        Messenger messenger = getMessenger();
-        if (messenger == null)
-            return null;
-
-        Channel c = new Channel(srcContext, srcLooper, listener);
-        if (c.mAsyncChannel.connectSync(srcContext, c.mHandler, messenger)
-                == AsyncChannel.STATUS_SUCCESSFUL) {
-            return c;
-        } else {
-            return null;
-        }
-    }
-
-    /**
-     * STOPSHIP: temp solution, should use supplicant manager instead, check
-     * with b/13931972
-     */
-    public Messenger getMessenger() {
-        try {
-            return mService.getMessenger();
-        } catch (RemoteException e) {
-            return null;
-        }
-    }
-
-    public void requestAnqpInfo(Channel c, List<ScanResult> requested, int mask,
-            ActionListener listener) {
-        Log.d(TAG, "requestAnqpInfo start");
-        Log.d(TAG, "requested.size=" + requested.size());
-        checkChannel(c);
-        List<ScanResult> list = new ArrayList<ScanResult>();
-        for (ScanResult sr : requested)
-            if (sr.capabilities.contains("[HS20]")) {
-                list.add(sr);
-                c.anqpRequestStart(sr);
-                Log.d(TAG, "adding " + sr.BSSID);
-            }
-        int count = list.size();
-        Log.d(TAG, "after filter, count=" + count);
-        if (count == 0) {
-            if (DBG)
-                Log.d(TAG, "ANQP info request contains no HS20 APs, skipped");
-            listener.onSuccess();
-            return;
-        }
-        int key = c.putListener(listener, count);
-        for (ScanResult sr : list)
-            c.mAsyncChannel.sendMessage(REQUEST_ANQP_INFO, mask, key, sr);
-        Log.d(TAG, "requestAnqpInfo end");
-    }
-
-    private static void checkChannel(Channel c) {
-        if (c == null) throw new IllegalArgumentException("Channel needs to be initialized");
-    }
-}
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.aidl b/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.aidl
deleted file mode 100644
index 088136f..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-parcelable WifiPasspointOsuProvider;
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.java
deleted file mode 100644
index b54b70c..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointOsuProvider.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.os.Parcel;
-import android.os.Parcelable;
-
-/** @hide */
-public class WifiPasspointOsuProvider implements Parcelable {
-
-    /** TODO: doc
-     * @hide
-     */
-    public static final int OSU_METHOD_UNKNOWN = -1;
-
-    /** TODO: doc
-     * @hide
-     */
-    public static final int OSU_METHOD_OMADM = 0;
-
-    /** TODO: doc
-     * @hide
-     */
-    public static final int OSU_METHOD_SOAP = 1;
-
-    /** TODO: doc */
-    public String ssid;
-
-    /** TODO: doc */
-    public String friendlyName;
-
-    /** TODO: doc
-     * @hide
-     */
-    public String serverUri;
-
-    /** TODO: doc
-     * @hide
-     */
-    public int osuMethod = OSU_METHOD_UNKNOWN;
-
-    /** TODO: doc */
-    public int iconWidth;
-
-    /** TODO: doc */
-    public int iconHeight;
-
-    /** TODO: doc */
-    public String iconType;
-
-    /** TODO: doc */
-    public String iconFileName;
-
-    /** TODO: doc */
-    public Object icon; // TODO: should change to image format
-
-    /** TODO: doc */
-    public String osuNai;
-
-    /** TODO: doc */
-    public String osuService;
-
-    /** default constructor @hide */
-    public WifiPasspointOsuProvider() {
-        // TODO
-    }
-
-    /** copy constructor @hide */
-    public WifiPasspointOsuProvider(WifiPasspointOsuProvider source) {
-        // TODO
-    }
-
-    @Override
-    public String toString() {
-        StringBuffer sb = new StringBuffer();
-        sb.append("SSID: ").append("<").append(ssid).append(">");
-        if (friendlyName != null)
-            sb.append(" friendlyName: ").append("<").append(friendlyName).append(">");
-        if (serverUri != null)
-            sb.append(" serverUri: ").append("<").append(serverUri).append(">");
-        sb.append(" osuMethod: ").append("<").append(osuMethod).append(">");
-        if (iconFileName != null) {
-            sb.append(" icon: <").append(iconWidth).append("x")
-                    .append(iconHeight).append(" ")
-                    .append(iconType).append(" ")
-                    .append(iconFileName).append(">");
-        }
-        if (osuNai != null)
-            sb.append(" osuNai: ").append("<").append(osuNai).append(">");
-        if (osuService != null)
-            sb.append(" osuService: ").append("<").append(osuService).append(">");
-        return sb.toString();
-    }
-
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    @Override
-    public void writeToParcel(Parcel out, int flags) {
-        out.writeString(ssid);
-        out.writeString(friendlyName);
-        out.writeString(serverUri);
-        out.writeInt(osuMethod);
-        out.writeInt(iconWidth);
-        out.writeInt(iconHeight);
-        out.writeString(iconType);
-        out.writeString(iconFileName);
-        out.writeString(osuNai);
-        out.writeString(osuService);
-        // TODO: icon image?
-    }
-
-    public static final Parcelable.Creator<WifiPasspointOsuProvider> CREATOR =
-            new Parcelable.Creator<WifiPasspointOsuProvider>() {
-                @Override
-                public WifiPasspointOsuProvider createFromParcel(Parcel in) {
-                    WifiPasspointOsuProvider osu = new WifiPasspointOsuProvider();
-                    osu.ssid = in.readString();
-                    osu.friendlyName = in.readString();
-                    osu.serverUri = in.readString();
-                    osu.osuMethod = in.readInt();
-                    osu.iconWidth = in.readInt();
-                    osu.iconHeight = in.readInt();
-                    osu.iconType = in.readString();
-                    osu.iconFileName = in.readString();
-                    osu.osuNai = in.readString();
-                    osu.osuService = in.readString();
-                    return osu;
-                }
-
-                @Override
-                public WifiPasspointOsuProvider[] newArray(int size) {
-                    return new WifiPasspointOsuProvider[size];
-                }
-            };
-}
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.aidl b/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.aidl
deleted file mode 100644
index 1d61da0..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.aidl
+++ /dev/null
@@ -1,19 +0,0 @@
-/**
- * Copyright (c) 2014, 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 android.net.wifi.passpoint;
-
-parcelable WifiPasspointPolicy;
diff --git a/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.java b/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.java
deleted file mode 100644
index f84ac88..0000000
--- a/wifi/java/android/net/wifi/passpoint/WifiPasspointPolicy.java
+++ /dev/null
@@ -1,386 +0,0 @@
-/*
- * Copyright (C) 2014 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 android.net.wifi.passpoint;
-
-import android.net.wifi.WifiConfiguration;
-import android.net.wifi.ScanResult;
-import android.os.Parcelable;
-import android.os.Parcel;
-import android.security.Credentials;
-import android.util.Log;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.Method;
-import java.util.List;
-
-
-/** @hide */
-public class WifiPasspointPolicy implements Parcelable {
-
-    private final static String TAG = "PasspointPolicy";
-
-    /** @hide */
-    public static final int HOME_SP = 0;
-
-    /** @hide */
-    public static final int ROAMING_PARTNER = 1;
-
-    /** @hide */
-    public static final int UNRESTRICTED = 2;
-
-    private String mName;
-    private int mCredentialPriority;
-    private int mRoamingPriority;
-    private String mBssid;
-    private String mSsid;
-    private WifiPasspointCredential mCredential;
-    private int mRestriction;// Permitted values are "HomeSP", "RoamingPartner", or "Unrestricted"
-    private boolean mIsHomeSp;
-
-    private final String INT_PRIVATE_KEY = "private_key";
-    private final String INT_PHASE2 = "phase2";
-    private final String INT_PASSWORD = "password";
-    private final String INT_IDENTITY = "identity";
-    private final String INT_EAP = "eap";
-    private final String INT_CLIENT_CERT = "client_cert";
-    private final String INT_CA_CERT = "ca_cert";
-    private final String INT_ANONYMOUS_IDENTITY = "anonymous_identity";
-    private final String INT_SIM_SLOT = "sim_slot";
-    private final String INT_ENTERPRISEFIELD_NAME ="android.net.wifi.WifiConfiguration$EnterpriseField";
-    private final String ISO8601DATEFORMAT = "yyyy-MM-dd'T'HH:mm:ss'Z'";
-    private final String ENTERPRISE_PHASE2_MSCHAPV2 = "auth=MSCHAPV2";
-    private final String ENTERPRISE_PHASE2_MSCHAP = "auth=MSCHAP";
-
-    /** @hide */
-    public WifiPasspointPolicy(String name, String ssid,
-            String bssid, WifiPasspointCredential pc,
-            int restriction, boolean ishomesp) {
-        mName = name;
-        if (pc != null) {
-            mCredentialPriority = pc.getPriority();
-        }
-        //PerProviderSubscription/<X+>/Policy/PreferredRoamingPartnerList/<X+>/Priority
-        mRoamingPriority = 128; //default priority value of 128
-        mSsid = ssid;
-        mCredential = pc;
-        mBssid = bssid;
-        mRestriction = restriction;
-        mIsHomeSp = ishomesp;
-    }
-
-    public String getSsid() {
-        return mSsid;
-    }
-
-    /** @hide */
-    public void setBssid(String bssid) {
-        mBssid = bssid;
-    }
-
-    public String getBssid() {
-        return mBssid;
-    }
-
-    /** @hide */
-    public void setRestriction(int r) {
-        mRestriction = r;
-    }
-
-    /** @hide */
-    public int getRestriction() {
-        return mRestriction;
-    }
-
-    /** @hide */
-    public void setHomeSp(boolean b) {
-        mIsHomeSp = b;
-    }
-
-    /** @hide */
-    public boolean isHomeSp() {
-        return mIsHomeSp;
-    }
-
-    /** @hide */
-    public void setCredential(WifiPasspointCredential newCredential) {
-        mCredential = newCredential;
-    }
-
-    public WifiPasspointCredential getCredential() {
-        // TODO: return a copy
-        return mCredential;
-    }
-
-    /** @hide */
-    public void setCredentialPriority(int priority) {
-        mCredentialPriority = priority;
-    }
-
-    /** @hide */
-    public void setRoamingPriority(int priority) {
-        mRoamingPriority = priority;
-    }
-
-    public int getCredentialPriority() {
-        return mCredentialPriority;
-    }
-
-    public int getRoamingPriority() {
-        return mRoamingPriority;
-    }
-
-    public WifiConfiguration createWifiConfiguration() {
-        WifiConfiguration wfg = new WifiConfiguration();
-        if (mBssid != null) {
-            Log.d(TAG, "create bssid:" + mBssid);
-            wfg.BSSID = mBssid;
-        }
-
-        if (mSsid != null) {
-            Log.d(TAG, "create ssid:" + mSsid);
-            wfg.SSID = mSsid;
-        }
-        //TODO: 1. add pmf configuration
-        //      2. add ocsp configuration
-        //      3. add eap-sim configuration
-        /*Key management*/
-        wfg.status = WifiConfiguration.Status.ENABLED;
-        wfg.allowedKeyManagement.clear();
-        wfg.allowedKeyManagement.set(WifiConfiguration.KeyMgmt.WPA_EAP);
-        wfg.allowedKeyManagement.set(WifiConfiguration.KeyMgmt.IEEE8021X);
-
-        /*Group Ciphers*/
-        wfg.allowedGroupCiphers.clear();
-        wfg.allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.CCMP);
-        wfg.allowedPairwiseCiphers.set(WifiConfiguration.PairwiseCipher.TKIP);
-
-        /*Protocols*/
-        wfg.allowedProtocols.clear();
-        wfg.allowedProtocols.set(WifiConfiguration.Protocol.RSN);
-        wfg.allowedProtocols.set(WifiConfiguration.Protocol.WPA);
-
-        Class[] enterpriseFieldArray  = WifiConfiguration.class.getClasses();
-        Class<?> enterpriseFieldClass = null;
-
-
-        for(Class<?> myClass : enterpriseFieldArray) {
-            if(myClass.getName().equals(INT_ENTERPRISEFIELD_NAME)) {
-                enterpriseFieldClass = myClass;
-                break;
-            }
-        }
-        Log.d(TAG, "class chosen " + enterpriseFieldClass.getName() );
-
-
-        Field anonymousId = null, caCert = null, clientCert = null,
-              eap = null, identity = null, password = null,
-              phase2 = null, privateKey =  null;
-
-        Field[] fields = WifiConfiguration.class.getFields();
-
-
-        for (Field tempField : fields) {
-            if (tempField.getName().trim().equals(INT_ANONYMOUS_IDENTITY)) {
-                anonymousId = tempField;
-                Log.d(TAG, "field " + anonymousId.getName() );
-            } else if (tempField.getName().trim().equals(INT_CA_CERT)) {
-                caCert = tempField;
-            } else if (tempField.getName().trim().equals(INT_CLIENT_CERT)) {
-                clientCert = tempField;
-                Log.d(TAG, "field " + clientCert.getName() );
-            } else if (tempField.getName().trim().equals(INT_EAP)) {
-                eap = tempField;
-                Log.d(TAG, "field " + eap.getName() );
-            } else if (tempField.getName().trim().equals(INT_IDENTITY)) {
-                identity = tempField;
-                Log.d(TAG, "field " + identity.getName() );
-            } else if (tempField.getName().trim().equals(INT_PASSWORD)) {
-                password = tempField;
-                Log.d(TAG, "field " + password.getName() );
-            } else if (tempField.getName().trim().equals(INT_PHASE2)) {
-                phase2 = tempField;
-                Log.d(TAG, "field " + phase2.getName() );
-
-            } else if (tempField.getName().trim().equals(INT_PRIVATE_KEY)) {
-                privateKey = tempField;
-            }
-        }
-
-
-        Method setValue = null;
-
-        for(Method m: enterpriseFieldClass.getMethods()) {
-            if(m.getName().trim().equals("setValue")) {
-                Log.d(TAG, "method " + m.getName() );
-                setValue = m;
-                break;
-            }
-        }
-
-        try {
-            // EAP
-            String eapmethod = mCredential.getType();
-            Log.d(TAG, "eapmethod:" + eapmethod);
-            setValue.invoke(eap.get(wfg), eapmethod);
-
-            // Username, password, EAP Phase 2
-            if ("TTLS".equals(eapmethod)) {
-                setValue.invoke(phase2.get(wfg), ENTERPRISE_PHASE2_MSCHAPV2);
-                setValue.invoke(identity.get(wfg), mCredential.getUserName());
-                setValue.invoke(password.get(wfg), mCredential.getPassword());
-                setValue.invoke(anonymousId.get(wfg), "anonymous@" + mCredential.getRealm());
-            }
-
-            // EAP CA Certificate
-            String cacertificate = null;
-            String rootCA = mCredential.getCaRootCertPath();
-            if (rootCA == null){
-                cacertificate = null;
-            } else {
-                cacertificate = "keystore://" + Credentials.WIFI + "HS20" + Credentials.CA_CERTIFICATE + rootCA;
-            }
-            Log.d(TAG, "cacertificate:" + cacertificate);
-            setValue.invoke(caCert.get(wfg), cacertificate);
-
-            //User certificate
-            if ("TLS".equals(eapmethod)) {
-                String usercertificate = null;
-                String privatekey = null;
-                String clientCertPath = mCredential.getClientCertPath();
-                if (clientCertPath != null){
-                    privatekey = "keystore://" + Credentials.WIFI + "HS20" + Credentials.USER_PRIVATE_KEY + clientCertPath;
-                    usercertificate = "keystore://" + Credentials.WIFI + "HS20" + Credentials.USER_CERTIFICATE + clientCertPath;
-                }
-                Log.d(TAG, "privatekey:" + privatekey);
-                Log.d(TAG, "usercertificate:" + usercertificate);
-                if (privatekey != null && usercertificate != null) {
-                    setValue.invoke(privateKey.get(wfg), privatekey);
-                    setValue.invoke(clientCert.get(wfg), usercertificate);
-                }
-            }
-        } catch (Exception e) {
-            Log.d(TAG, "createWifiConfiguration err:" + e);
-        }
-
-        return wfg;
-    }
-
-    /** {@inheritDoc} @hide */
-    public int compareTo(WifiPasspointPolicy another) {
-        Log.d(TAG, "this:" + this);
-        Log.d(TAG, "another:" + another);
-
-        if (another == null) {
-            return -1;
-        } else if (this.mIsHomeSp == true && another.isHomeSp() == false) {
-            //home sp priority is higher then roaming
-            Log.d(TAG, "compare HomeSP  first, this is HomeSP, another isn't");
-            return -1;
-        } else if ((this.mIsHomeSp == true && another.isHomeSp() == true)) {
-            Log.d(TAG, "both HomeSP");
-            //if both home sp, compare credential priority
-            if (this.mCredentialPriority < another.getCredentialPriority()) {
-                Log.d(TAG, "this priority is higher");
-                return -1;
-            } else if (this.mCredentialPriority == another.getCredentialPriority()) {
-                Log.d(TAG, "both priorities equal");
-                //if priority still the same, compare name(ssid)
-                if (this.mName.compareTo(another.mName) != 0) {
-                    Log.d(TAG, "compare mName return:" + this.mName.compareTo(another.mName));
-                    return this.mName.compareTo(another.mName);
-                }
-                /**
-                 *if name still the same, compare credential
-                 *the device may has two more credentials(TLS,SIM..etc)
-                 *it can associate to one AP(same ssid). so we should compare by credential
-                 */
-                if (this.mCredential != null && another.mCredential != null) {
-                    if (this.mCredential.compareTo(another.mCredential) != 0) {
-                        Log.d(TAG,
-                                "compare mCredential return:" + this.mName.compareTo(another.mName));
-                        return this.mCredential.compareTo(another.mCredential);
-                    }
-                }
-            } else {
-                return 1;
-            }
-        } else if ((this.mIsHomeSp == false && another.isHomeSp() == false)) {
-            Log.d(TAG, "both RoamingSp");
-            //if both roaming sp, compare roaming priority(preferredRoamingPartnerList/<X+>/priority)
-            if (this.mRoamingPriority < another.getRoamingPriority()) {
-                Log.d(TAG, "this priority is higher");
-                return -1;
-            } else if (this.mRoamingPriority == another.getRoamingPriority()) {//priority equals, compare name
-                Log.d(TAG, "both priorities equal");
-                //if priority still the same, compare name(ssid)
-                if (this.mName.compareTo(another.mName) != 0) {
-                    Log.d(TAG, "compare mName return:" + this.mName.compareTo(another.mName));
-                    return this.mName.compareTo(another.mName);
-                }
-                //if name still the same, compare credential
-                if (this.mCredential != null && another.mCredential != null) {
-                    if (this.mCredential.compareTo(another.mCredential) != 0) {
-                        Log.d(TAG,
-                                "compare mCredential return:"
-                                        + this.mCredential.compareTo(another.mCredential));
-                        return this.mCredential.compareTo(another.mCredential);
-                    }
-                }
-            } else {
-                return 1;
-            }
-        }
-
-        Log.d(TAG, "both policies equal");
-        return 0;
-    }
-
-    @Override
-    /** @hide */
-    public String toString() {
-        return "PasspointPolicy: name=" + mName + " CredentialPriority=" + mCredentialPriority +
-                " mRoamingPriority" + mRoamingPriority +
-                " ssid=" + mSsid + " restriction=" + mRestriction +
-                " ishomesp=" + mIsHomeSp + " Credential=" + mCredential;
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    @Override
-    public int describeContents() {
-        return 0;
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    @Override
-    public void writeToParcel(Parcel dest, int flags) {
-        // TODO
-    }
-
-    /** Implement the Parcelable interface {@hide} */
-    public static final Creator<WifiPasspointPolicy> CREATOR =
-            new Creator<WifiPasspointPolicy>() {
-                @Override
-                public WifiPasspointPolicy createFromParcel(Parcel in) {
-                    return null;
-                }
-
-                @Override
-                public WifiPasspointPolicy[] newArray(int size) {
-                    return new WifiPasspointPolicy[size];
-                }
-            };
-}